@iconify/vue
Advanced tools
Comparing version 4.0.0 to 4.0.1
@@ -5,4 +5,2 @@ import type { AllowedComponentProps } from 'vue'; | ||
import type { DefineComponent } from 'vue'; | ||
import type { EmitsOptions } from 'vue'; | ||
import { ExtractPropTypes } from 'vue'; | ||
import { IconifyIcon } from '@iconify/types'; | ||
@@ -50,2 +48,6 @@ import { IconifyJSON } from '@iconify/types'; | ||
*/ | ||
export declare function calculateSize(size: string, ratio: number, precision?: number): string; | ||
export declare function calculateSize(size: number, ratio: number, precision?: number): number; | ||
export declare function calculateSize(size: string | number, ratio: number, precision?: number): string | number; | ||
@@ -73,19 +75,5 @@ | ||
export declare const Icon: DefineComponent<{}, {}, { | ||
iconMounted: boolean; | ||
counter: number; | ||
}, {}, { | ||
abortLoading(): void; | ||
getIcon(icon: IconifyIcon | string, onload?: IconifyIconOnLoad): IconComponentData | null; | ||
}, ComponentOptionsMixin, ComponentOptionsMixin, EmitsOptions, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}>; | ||
export declare const Icon: DefineComponent<IconProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<IconProps>, {}>; | ||
/** | ||
* Component | ||
*/ | ||
declare interface IconComponentData { | ||
data: IconifyIcon; | ||
classes?: string[]; | ||
} | ||
/** | ||
* Check if icon exists | ||
@@ -92,0 +80,0 @@ */ |
@@ -112,3 +112,3 @@ (function (global, factory) { | ||
const icons = data.icons; | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
const resolved = /* @__PURE__ */ Object.create(null); | ||
@@ -135,3 +135,3 @@ function resolve(name) { | ||
const icons = data.icons; | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
let currentProps = {}; | ||
@@ -206,3 +206,3 @@ function parse(name2) { | ||
} | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
for (const name in aliases) { | ||
@@ -691,3 +691,7 @@ const icon = aliases[name]; | ||
setTimeout(() => { | ||
callback("next", defaultError); | ||
if (data === 404) { | ||
callback("abort", data); | ||
} else { | ||
callback("next", defaultError); | ||
} | ||
}); | ||
@@ -1327,7 +1331,4 @@ return; | ||
params.forEach((item) => { | ||
sendAPIQuery(provider, item, (data, error) => { | ||
sendAPIQuery(provider, item, (data) => { | ||
if (typeof data !== "object") { | ||
if (error !== 404) { | ||
return; | ||
} | ||
item.icons.forEach((name) => { | ||
@@ -1418,3 +1419,7 @@ storage.missing.add(name); | ||
return new Promise((fulfill, reject) => { | ||
const iconObj = typeof icon === "string" ? stringToIcon(icon) : icon; | ||
const iconObj = typeof icon === "string" ? stringToIcon(icon, true) : icon; | ||
if (!iconObj) { | ||
reject(icon); | ||
return; | ||
} | ||
loadIcons([iconObj || icon], (loaded) => { | ||
@@ -1421,0 +1426,0 @@ if (loaded.length && iconObj) { |
@@ -5,4 +5,2 @@ import type { AllowedComponentProps } from 'vue'; | ||
import type { DefineComponent } from 'vue'; | ||
import type { EmitsOptions } from 'vue'; | ||
import { ExtractPropTypes } from 'vue'; | ||
import type { IconifyIcon } from '@iconify/types'; | ||
@@ -32,3 +30,3 @@ import type { IconifyJSON } from '@iconify/types'; | ||
*/ | ||
export declare const Icon: DefineComponent<{}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, EmitsOptions, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}>; | ||
export declare const Icon: DefineComponent<IconProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<IconProps>, {}>; | ||
@@ -35,0 +33,0 @@ /** |
@@ -63,3 +63,3 @@ (function (global, factory) { | ||
const icons = data.icons; | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
const resolved = /* @__PURE__ */ Object.create(null); | ||
@@ -86,3 +86,3 @@ function resolve(name) { | ||
const icons = data.icons; | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
let currentProps = {}; | ||
@@ -159,3 +159,3 @@ function parse(name2) { | ||
} | ||
const aliases = data.aliases || {}; | ||
const aliases = data.aliases || /* @__PURE__ */ Object.create(null); | ||
for (const name in aliases) { | ||
@@ -162,0 +162,0 @@ const icon = aliases[name]; |
@@ -1,5 +0,5 @@ | ||
# @iconify/react/offline | ||
# @iconify/vue/offline | ||
This sub-directory contains `package.json` with entry points for importing `@iconify/react/offline`. | ||
This sub-directory contains `package.json` with entry points for importing `@iconify/vue/offline`. | ||
There is a duplicate entry in `exports` section of `package.json` in the parent directory, but at moment of coding this, TypeScript does not support conditional exports properly, so this directory is used as a duplicate to make everything work with TypeScript. |
@@ -5,3 +5,3 @@ { | ||
"author": "Vjacheslav Trushkin", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"license": "MIT", | ||
@@ -42,4 +42,4 @@ "bugs": "https://github.com/iconify/iconify/issues", | ||
"@babel/preset-env": "^7.19.0", | ||
"@iconify/core": "^2.0.0", | ||
"@iconify/utils": "^2.0.0", | ||
"@iconify/core": "^2.0.1", | ||
"@iconify/utils": "^2.0.2", | ||
"@microsoft/api-extractor": "^7.30.0", | ||
@@ -46,0 +46,0 @@ "@rollup/plugin-node-resolve": "^14.0.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
180207
5549