@cyberalien/svg-utils 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/classname/{toggle.mjs → toggle.js} +1 -1
- package/lib/components/export/{exports.d.mts → exports.d.ts} +1 -1
- package/lib/components/export/{file.d.mts → file.d.ts} +3 -3
- package/lib/components/export/{file.mjs → file.js} +1 -1
- package/lib/components/export/{filename.d.mts → filename.d.ts} +2 -2
- package/lib/components/export/{fs.d.mts → fs.d.ts} +1 -1
- package/lib/components/export/{merge.d.mts → merge.d.ts} +1 -1
- package/lib/components/helpers/content/{ratio.d.mts → ratio.d.ts} +1 -1
- package/lib/components/helpers/content/{size.d.mts → size.d.ts} +2 -2
- package/lib/components/helpers/content/{size.mjs → size.js} +1 -1
- package/lib/components/helpers/content/{stringify.d.mts → stringify.d.ts} +2 -2
- package/lib/components/helpers/content/{stringify.mjs → stringify.js} +1 -1
- package/lib/components/helpers/css/{generate.d.mts → generate.d.ts} +4 -4
- package/lib/components/helpers/css/{generate.mjs → generate.js} +3 -3
- package/lib/components/helpers/css/{name.mjs → name.js} +1 -1
- package/lib/components/helpers/filenames/{asset.d.mts → asset.d.ts} +1 -1
- package/lib/components/helpers/filenames/{css.d.mts → css.d.ts} +1 -1
- package/lib/components/helpers/filenames/{css.mjs → css.js} +1 -1
- package/lib/components/helpers/filenames/{path.d.mts → path.d.ts} +1 -1
- package/lib/components/helpers/filenames/{types.d.mts → types.d.ts} +3 -3
- package/lib/components/helpers/filenames/{types.mjs → types.js} +3 -3
- package/lib/components/helpers/functions/{size.d.mts → size.d.ts} +3 -3
- package/lib/components/helpers/functions/{size.mjs → size.js} +1 -1
- package/lib/components/helpers/imports/{add.d.mts → add.d.ts} +1 -1
- package/lib/components/helpers/imports/{create.d.mts → create.d.ts} +1 -1
- package/lib/components/helpers/imports/{stringify.d.mts → stringify.d.ts} +1 -1
- package/lib/components/helpers/props/{object.d.mts → object.d.ts} +1 -1
- package/lib/components/helpers/props/{object.mjs → object.js} +1 -1
- package/lib/components/helpers/props/{stringify.d.mts → stringify.d.ts} +1 -1
- package/lib/components/helpers/props/{ts.d.mts → ts.d.ts} +1 -1
- package/lib/components/helpers/ts/jsx.d.ts +13 -0
- package/lib/components/helpers/ts/{jsx.mjs → jsx.js} +1 -1
- package/lib/components/helpers/ts/svelte.d.ts +9 -0
- package/lib/components/helpers/ts/{svelte.mjs → svelte.js} +1 -1
- package/lib/components/helpers/ts/vue.d.ts +9 -0
- package/lib/components/helpers/ts/{vue.mjs → vue.js} +1 -1
- package/lib/components/helpers/ts/wrapper.d.ts +9 -0
- package/lib/components/helpers/ts/{wrapper.mjs → wrapper.js} +2 -2
- package/lib/components/{jsx.d.mts → jsx.d.ts} +4 -4
- package/lib/components/{jsx.mjs → jsx.js} +13 -13
- package/lib/components/prepare/{iconify.d.mts → iconify.d.ts} +4 -4
- package/lib/components/prepare/{iconify.mjs → iconify.js} +3 -3
- package/lib/components/prepare/{options.d.mts → options.d.ts} +1 -1
- package/lib/components/prepare/{options.mjs → options.js} +2 -2
- package/lib/components/raw.d.ts +8 -0
- package/lib/components/{raw.mjs → raw.js} +8 -8
- package/lib/components/{svelte.d.mts → svelte.d.ts} +3 -3
- package/lib/components/{svelte.mjs → svelte.js} +13 -13
- package/lib/components/types/{data.d.mts → data.d.ts} +2 -2
- package/lib/components/types/{options.d.mts → options.d.ts} +2 -2
- package/lib/components/types/{source.d.mts → source.d.ts} +2 -2
- package/lib/components/vue-func.d.ts +8 -0
- package/lib/components/{vue-func.mjs → vue-func.js} +13 -13
- package/lib/components/{vue.d.mts → vue.d.ts} +3 -3
- package/lib/components/{vue.mjs → vue.js} +13 -13
- package/lib/css/{hash.d.mts → hash.d.ts} +1 -1
- package/lib/css/{hash.mjs → hash.js} +2 -2
- package/lib/css/{stringify.d.mts → stringify.d.ts} +1 -1
- package/lib/css/{types.d.mts → types.d.ts} +1 -1
- package/lib/helpers/hash/{context.d.mts → context.d.ts} +1 -1
- package/lib/helpers/hash/{unique.d.mts → unique.d.ts} +1 -1
- package/lib/helpers/hash/{unique.mjs → unique.js} +3 -3
- package/lib/helpers/misc/{compare.mjs → compare.js} +1 -1
- package/lib/helpers/misc/{keys.mjs → keys.js} +1 -1
- package/lib/helpers/misc/{promises.d.mts → promises.d.ts} +1 -1
- package/lib/helpers/misc/{promises.mjs → promises.js} +1 -1
- package/lib/iconify/icon/{nornalise.d.mts → nornalise.d.ts} +1 -1
- package/lib/iconify/icon/{nornalise.mjs → nornalise.js} +1 -1
- package/lib/iconify/icon/types.d.ts +6 -0
- package/lib/iconify/icon-set/{icon.mjs → icon.js} +1 -1
- package/lib/iconify/icon-set/{parse.d.mts → parse.d.ts} +1 -1
- package/lib/iconify/icon-set/{parse.mjs → parse.js} +1 -1
- package/lib/{index.d.mts → index.d.ts} +27 -27
- package/lib/index.js +25 -0
- package/lib/svg/ids/{change.d.mts → change.d.ts} +2 -2
- package/lib/svg/ids/{change.mjs → change.js} +3 -3
- package/lib/svg/ids/{duplicate.d.mts → duplicate.d.ts} +2 -2
- package/lib/svg/ids/{duplicate.mjs → duplicate.js} +1 -1
- package/lib/svg/ids/{types.d.mts → types.d.ts} +2 -2
- package/lib/svg/ids/{unique.d.mts → unique.d.ts} +2 -2
- package/lib/svg/ids/{unique.mjs → unique.js} +2 -2
- package/lib/svg/ids/{unused.d.mts → unused.d.ts} +2 -2
- package/lib/svg/ids/{unused.mjs → unused.js} +1 -1
- package/lib/svg/viewbox/{minify.d.mts → minify.d.ts} +1 -1
- package/lib/svg/viewbox/{parse.d.mts → parse.d.ts} +1 -1
- package/lib/svg/viewbox/{square.d.mts → square.d.ts} +1 -1
- package/lib/svg/viewbox/{value.d.mts → value.d.ts} +1 -1
- package/lib/svg-css/{content.d.mts → content.d.ts} +1 -1
- package/lib/svg-css/{content.mjs → content.js} +3 -3
- package/lib/svg-css/props/{props.d.mts → props.d.ts} +2 -2
- package/lib/svg-css/props/{props.mjs → props.js} +3 -3
- package/lib/svg-css/props/{types.d.mts → types.d.ts} +1 -1
- package/lib/svg-css/{root.d.mts → root.d.ts} +3 -3
- package/lib/svg-css/{root.mjs → root.js} +4 -4
- package/lib/svg-css/{types.d.mts → types.d.ts} +2 -2
- package/lib/xml/{iterate.d.mts → iterate.d.ts} +1 -1
- package/lib/xml/{parse.d.mts → parse.d.ts} +1 -1
- package/lib/xml/{stringify.d.mts → stringify.d.ts} +1 -1
- package/package.json +1 -1
- package/lib/components/helpers/ts/jsx.d.mts +0 -13
- package/lib/components/helpers/ts/svelte.d.mts +0 -9
- package/lib/components/helpers/ts/vue.d.mts +0 -9
- package/lib/components/helpers/ts/wrapper.d.mts +0 -9
- package/lib/components/raw.d.mts +0 -8
- package/lib/components/vue-func.d.mts +0 -8
- package/lib/iconify/icon/types.d.mts +0 -6
- package/lib/index.mjs +0 -25
- /package/lib/classname/{const.d.mts → const.d.ts} +0 -0
- /package/lib/classname/{const.mjs → const.js} +0 -0
- /package/lib/classname/{toggle.d.mts → toggle.d.ts} +0 -0
- /package/lib/components/export/{exports.mjs → exports.js} +0 -0
- /package/lib/components/export/{filename.mjs → filename.js} +0 -0
- /package/lib/components/export/{fs.mjs → fs.js} +0 -0
- /package/lib/components/export/{merge.mjs → merge.js} +0 -0
- /package/lib/components/helpers/code/{lines.d.mts → lines.d.ts} +0 -0
- /package/lib/components/helpers/code/{lines.mjs → lines.js} +0 -0
- /package/lib/components/helpers/content/{ratio.mjs → ratio.js} +0 -0
- /package/lib/components/helpers/css/{name.d.mts → name.d.ts} +0 -0
- /package/lib/components/helpers/filenames/{asset.mjs → asset.js} +0 -0
- /package/lib/components/helpers/filenames/{path.mjs → path.js} +0 -0
- /package/lib/components/helpers/imports/{add.mjs → add.js} +0 -0
- /package/lib/components/helpers/imports/{create.mjs → create.js} +0 -0
- /package/lib/components/helpers/imports/{stringify.mjs → stringify.js} +0 -0
- /package/lib/components/helpers/imports/{types.d.mts → types.d.ts} +0 -0
- /package/lib/components/helpers/imports/{types.mjs → types.js} +0 -0
- /package/lib/components/helpers/props/{stringify.mjs → stringify.js} +0 -0
- /package/lib/components/helpers/props/{ts.mjs → ts.js} +0 -0
- /package/lib/components/helpers/props/{types.d.mts → types.d.ts} +0 -0
- /package/lib/components/helpers/props/{types.mjs → types.js} +0 -0
- /package/lib/components/types/{component.d.mts → component.d.ts} +0 -0
- /package/lib/components/types/{component.mjs → component.js} +0 -0
- /package/lib/components/types/{css.d.mts → css.d.ts} +0 -0
- /package/lib/components/types/{css.mjs → css.js} +0 -0
- /package/lib/components/types/{data.mjs → data.js} +0 -0
- /package/lib/components/types/{jsx.d.mts → jsx.d.ts} +0 -0
- /package/lib/components/types/{jsx.mjs → jsx.js} +0 -0
- /package/lib/components/types/{options.mjs → options.js} +0 -0
- /package/lib/components/types/{source.mjs → source.js} +0 -0
- /package/lib/css/{stringify.mjs → stringify.js} +0 -0
- /package/lib/css/{types.mjs → types.js} +0 -0
- /package/lib/helpers/hash/{context.mjs → context.js} +0 -0
- /package/lib/helpers/hash/{hash.d.mts → hash.d.ts} +0 -0
- /package/lib/helpers/hash/{hash.mjs → hash.js} +0 -0
- /package/lib/helpers/hash/{stringify.d.mts → stringify.d.ts} +0 -0
- /package/lib/helpers/hash/{stringify.mjs → stringify.js} +0 -0
- /package/lib/helpers/hash/{types.d.mts → types.d.ts} +0 -0
- /package/lib/helpers/hash/{types.mjs → types.js} +0 -0
- /package/lib/helpers/misc/{clone.d.mts → clone.d.ts} +0 -0
- /package/lib/helpers/misc/{clone.mjs → clone.js} +0 -0
- /package/lib/helpers/misc/{compare.d.mts → compare.d.ts} +0 -0
- /package/lib/helpers/misc/{keys.d.mts → keys.d.ts} +0 -0
- /package/lib/helpers/misc/{sort-object.d.mts → sort-object.d.ts} +0 -0
- /package/lib/helpers/misc/{sort-object.mjs → sort-object.js} +0 -0
- /package/lib/helpers/misc/{strings.d.mts → strings.d.ts} +0 -0
- /package/lib/helpers/misc/{strings.mjs → strings.js} +0 -0
- /package/lib/iconify/icon/{types.mjs → types.js} +0 -0
- /package/lib/iconify/icon-set/{defaults.d.mts → defaults.d.ts} +0 -0
- /package/lib/iconify/icon-set/{defaults.mjs → defaults.js} +0 -0
- /package/lib/iconify/icon-set/{icon.d.mts → icon.d.ts} +0 -0
- /package/lib/iconify/icon-set/{types.d.mts → types.d.ts} +0 -0
- /package/lib/iconify/icon-set/{types.mjs → types.js} +0 -0
- /package/lib/svg/content/{defs.d.mts → defs.d.ts} +0 -0
- /package/lib/svg/content/{defs.mjs → defs.js} +0 -0
- /package/lib/svg/ids/{string.d.mts → string.d.ts} +0 -0
- /package/lib/svg/ids/{string.mjs → string.js} +0 -0
- /package/lib/svg/ids/{types.mjs → types.js} +0 -0
- /package/lib/svg/props/{size.d.mts → size.d.ts} +0 -0
- /package/lib/svg/props/{size.mjs → size.js} +0 -0
- /package/lib/svg/props/{stringify.d.mts → stringify.d.ts} +0 -0
- /package/lib/svg/props/{stringify.mjs → stringify.js} +0 -0
- /package/lib/svg/viewbox/{minify.mjs → minify.js} +0 -0
- /package/lib/svg/viewbox/{parse.mjs → parse.js} +0 -0
- /package/lib/svg/viewbox/{square.mjs → square.js} +0 -0
- /package/lib/svg/viewbox/{types.d.mts → types.d.ts} +0 -0
- /package/lib/svg/viewbox/{types.mjs → types.js} +0 -0
- /package/lib/svg/viewbox/{value.mjs → value.js} +0 -0
- /package/lib/svg-css/props/{prop.d.mts → prop.d.ts} +0 -0
- /package/lib/svg-css/props/{prop.mjs → prop.js} +0 -0
- /package/lib/svg-css/props/{tags.d.mts → tags.d.ts} +0 -0
- /package/lib/svg-css/props/{tags.mjs → tags.js} +0 -0
- /package/lib/svg-css/props/{types.mjs → types.js} +0 -0
- /package/lib/svg-css/{types.mjs → types.js} +0 -0
- /package/lib/xml/{iterate.mjs → iterate.js} +0 -0
- /package/lib/xml/{parse.mjs → parse.js} +0 -0
- /package/lib/xml/{stringify.mjs → stringify.js} +0 -0
- /package/lib/xml/{types.d.mts → types.d.ts} +0 -0
- /package/lib/xml/{types.mjs → types.js} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FactoryComponent, FactoryGeneratedComponent } from "../types/component.
|
|
2
|
-
import { FactoryIconData } from "../types/data.
|
|
3
|
-
import { ComponentFactoryFileSystemOptions } from "../types/options.
|
|
1
|
+
import { FactoryComponent, FactoryGeneratedComponent } from "../types/component.js";
|
|
2
|
+
import { FactoryIconData } from "../types/data.js";
|
|
3
|
+
import { ComponentFactoryFileSystemOptions } from "../types/options.js";
|
|
4
4
|
interface Options extends Pick<ComponentFactoryFileSystemOptions, 'doubleDirsForComponents' | 'prefixDirsForComponents'> {
|
|
5
5
|
includePrefix?: boolean;
|
|
6
6
|
extension: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FactoryIconData } from "../types/data.
|
|
2
|
-
import { ComponentFactoryFileSystemOptions } from "../types/options.
|
|
1
|
+
import { FactoryIconData } from "../types/data.js";
|
|
2
|
+
import { ComponentFactoryFileSystemOptions } from "../types/options.js";
|
|
3
3
|
/**
|
|
4
4
|
* Generate component filename based on options
|
|
5
5
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { IconViewBox } from "../../../svg/viewbox/types.
|
|
2
|
-
import { ComponentFactoryRenderingOptions } from "../../types/options.
|
|
1
|
+
import { IconViewBox } from "../../../svg/viewbox/types.js";
|
|
2
|
+
import { ComponentFactoryRenderingOptions } from "../../types/options.js";
|
|
3
3
|
interface SizeResult {
|
|
4
4
|
width: string;
|
|
5
5
|
height: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ComponentFactorySource } from "../../types/source.
|
|
2
|
-
import { ComponentFactoryRenderingOptions } from "../../types/options.
|
|
1
|
+
import { ComponentFactorySource } from "../../types/source.js";
|
|
2
|
+
import { ComponentFactoryRenderingOptions } from "../../types/options.js";
|
|
3
3
|
/**
|
|
4
4
|
* Convert icon content to a string literal
|
|
5
5
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { GeneratedAssetFile } from "../../types/component.
|
|
2
|
-
import { ComponentFactorySource } from "../../types/source.
|
|
3
|
-
import { ComponentFactoryOptions } from "../../types/options.
|
|
4
|
-
import { FactoryComponentImports } from "../imports/types.
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { ComponentFactorySource } from "../../types/source.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
4
|
+
import { FactoryComponentImports } from "../imports/types.js";
|
|
5
5
|
interface Options extends Pick<ComponentFactoryOptions, 'cssMode' | 'cssPath' | 'doubleDirsForCSS' | 'mergeCSS'> {
|
|
6
6
|
componentType?: 'svelte';
|
|
7
7
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { stringifyCSSKeyframes, stringifyCSSSelector } from "../../../css/stringify.
|
|
2
|
-
import { generateCSSDefaultImportName } from "./name.
|
|
3
|
-
import { getGeneratedCSSFilename } from "../filenames/css.
|
|
1
|
+
import { stringifyCSSKeyframes, stringifyCSSSelector } from "../../../css/stringify.js";
|
|
2
|
+
import { generateCSSDefaultImportName } from "./name.js";
|
|
3
|
+
import { getGeneratedCSSFilename } from "../filenames/css.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Generate CSS files for component
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { UniqueHashPartialOptions } from "../../../helpers/hash/types.
|
|
2
|
-
import { FactoryIconData } from "../../types/data.
|
|
3
|
-
import { ComponentFactoryFileSystemOptions, GeneratedAssetPath } from "../../types/options.
|
|
1
|
+
import { UniqueHashPartialOptions } from "../../../helpers/hash/types.js";
|
|
2
|
+
import { FactoryIconData } from "../../types/data.js";
|
|
3
|
+
import { ComponentFactoryFileSystemOptions, GeneratedAssetPath } from "../../types/options.js";
|
|
4
4
|
interface Options extends Pick<UniqueHashPartialOptions, 'context'>, Pick<ComponentFactoryFileSystemOptions, 'rootPath' | 'doubleDirsForComponents' | 'prefixDirsForComponents' | 'sharedTypes'> {}
|
|
5
5
|
/**
|
|
6
6
|
* Generate component types filename based on options
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getUniqueHash } from "../../../helpers/hash/unique.
|
|
2
|
-
import { getGeneratedAssetFilename } from "./asset.
|
|
3
|
-
import { getGeneratedComponentFilename } from "../../export/filename.
|
|
1
|
+
import { getUniqueHash } from "../../../helpers/hash/unique.js";
|
|
2
|
+
import { getGeneratedAssetFilename } from "./asset.js";
|
|
3
|
+
import { getGeneratedComponentFilename } from "../../export/filename.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Generate component types filename based on options
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { GeneratedAssetFile } from "../../types/component.
|
|
2
|
-
import { ComponentFactoryOptions } from "../../types/options.
|
|
3
|
-
import { FactoryComponentImports } from "../imports/types.
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
3
|
+
import { FactoryComponentImports } from "../imports/types.js";
|
|
4
4
|
/**
|
|
5
5
|
* Adds getSizeProps() function to assets
|
|
6
6
|
*/
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { FactoryIconData } from "../../types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
4
|
+
import { FactoryComponentProps } from "../props/types.js";
|
|
5
|
+
import { JSXMode } from "../../types/jsx.js";
|
|
6
|
+
interface Options extends ComponentFactoryOptions {
|
|
7
|
+
jsx: JSXMode;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Add JSX component types
|
|
11
|
+
*/
|
|
12
|
+
declare function addJSXComponentTypes(data: FactoryIconData, options: Options, assets: GeneratedAssetFile[], props: FactoryComponentProps): string;
|
|
13
|
+
export { addJSXComponentTypes };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { FactoryIconData } from "../../types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
4
|
+
import { FactoryComponentProps } from "../props/types.js";
|
|
5
|
+
/**
|
|
6
|
+
* Add Svelte component types
|
|
7
|
+
*/
|
|
8
|
+
declare const addSvelteComponentTypes: (data: FactoryIconData, options: ComponentFactoryOptions, assets: GeneratedAssetFile[], props: FactoryComponentProps) => string;
|
|
9
|
+
export { addSvelteComponentTypes };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { FactoryIconData } from "../../types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
4
|
+
import { FactoryComponentProps } from "../props/types.js";
|
|
5
|
+
/**
|
|
6
|
+
* Add Vue component types
|
|
7
|
+
*/
|
|
8
|
+
declare const addVueComponentTypes: (data: FactoryIconData, options: ComponentFactoryOptions, assets: GeneratedAssetFile[], props: FactoryComponentProps) => string;
|
|
9
|
+
export { addVueComponentTypes };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { GeneratedAssetFile } from "../../types/component.js";
|
|
2
|
+
import { FactoryIconData } from "../../types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "../../types/options.js";
|
|
4
|
+
import { FactoryComponentProps } from "../props/types.js";
|
|
5
|
+
/**
|
|
6
|
+
* Add component types
|
|
7
|
+
*/
|
|
8
|
+
declare function addComponentTypes(template: string, data: FactoryIconData, options: ComponentFactoryOptions, assets: GeneratedAssetFile[], props: FactoryComponentProps): string;
|
|
9
|
+
export { addComponentTypes };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { stringifyFactoryPropTypes } from "../props/ts.
|
|
2
|
-
import { getGeneratedComponentTypesFilename } from "../filenames/types.
|
|
1
|
+
import { stringifyFactoryPropTypes } from "../props/ts.js";
|
|
2
|
+
import { getGeneratedComponentTypesFilename } from "../filenames/types.js";
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Add component types
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { FactoryGeneratedComponent } from "./types/component.
|
|
2
|
-
import { FactoryIconData } from "./types/data.
|
|
3
|
-
import { ComponentFactoryOptions } from "./types/options.
|
|
4
|
-
import { JSXMode } from "./types/jsx.
|
|
1
|
+
import { FactoryGeneratedComponent } from "./types/component.js";
|
|
2
|
+
import { FactoryIconData } from "./types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "./types/options.js";
|
|
4
|
+
import { JSXMode } from "./types/jsx.js";
|
|
5
5
|
interface Options extends ComponentFactoryOptions {
|
|
6
6
|
jsx: JSXMode;
|
|
7
7
|
fallbackPackage?: string;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { getComponentSizeValues } from "./helpers/content/size.
|
|
2
|
-
import { stringifyFactoryIconContent } from "./helpers/content/stringify.
|
|
3
|
-
import { stringifyIconViewBox } from "../svg/viewbox/value.
|
|
4
|
-
import { createFactoryImports } from "./helpers/imports/create.
|
|
5
|
-
import { generateCSSFilesForComponent } from "./helpers/css/generate.
|
|
6
|
-
import { addSizeFunctionAsset } from "./helpers/functions/size.
|
|
7
|
-
import { stringifyFactoryPropsAsJSON } from "./helpers/props/object.
|
|
8
|
-
import { stringifyFactoryImports } from "./helpers/imports/stringify.
|
|
9
|
-
import { makeSquareViewBox } from "../svg/viewbox/square.
|
|
10
|
-
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.
|
|
11
|
-
import { minifyViewBox } from "../svg/viewbox/minify.
|
|
12
|
-
import { getViewBoxRatio } from "./helpers/content/ratio.
|
|
13
|
-
import { addJSXComponentTypes } from "./helpers/ts/jsx.
|
|
1
|
+
import { getComponentSizeValues } from "./helpers/content/size.js";
|
|
2
|
+
import { stringifyFactoryIconContent } from "./helpers/content/stringify.js";
|
|
3
|
+
import { stringifyIconViewBox } from "../svg/viewbox/value.js";
|
|
4
|
+
import { createFactoryImports } from "./helpers/imports/create.js";
|
|
5
|
+
import { generateCSSFilesForComponent } from "./helpers/css/generate.js";
|
|
6
|
+
import { addSizeFunctionAsset } from "./helpers/functions/size.js";
|
|
7
|
+
import { stringifyFactoryPropsAsJSON } from "./helpers/props/object.js";
|
|
8
|
+
import { stringifyFactoryImports } from "./helpers/imports/stringify.js";
|
|
9
|
+
import { makeSquareViewBox } from "../svg/viewbox/square.js";
|
|
10
|
+
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.js";
|
|
11
|
+
import { minifyViewBox } from "../svg/viewbox/minify.js";
|
|
12
|
+
import { getViewBoxRatio } from "./helpers/content/ratio.js";
|
|
13
|
+
import { addJSXComponentTypes } from "./helpers/ts/jsx.js";
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Create functional Vue component code
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { GeneratedAssetFile } from "../types/component.
|
|
2
|
-
import { ConvertSVGContentOptions } from "../../svg-css/types.
|
|
3
|
-
import { FactoryIconData } from "../types/data.
|
|
4
|
-
import { GeneratedAssetPath } from "../types/options.
|
|
1
|
+
import { GeneratedAssetFile } from "../types/component.js";
|
|
2
|
+
import { ConvertSVGContentOptions } from "../../svg-css/types.js";
|
|
3
|
+
import { FactoryIconData } from "../types/data.js";
|
|
4
|
+
import { GeneratedAssetPath } from "../types/options.js";
|
|
5
5
|
import { IconifyIcon, IconifyJSON } from "@iconify/types";
|
|
6
6
|
interface Options extends ConvertSVGContentOptions {
|
|
7
7
|
fallback?: string | boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { convertSVGContentToCSSRules } from "../../svg-css/content.
|
|
2
|
-
import { getGeneratedAssetFilename } from "../helpers/filenames/asset.
|
|
3
|
-
import { normaliseIconifyIcon } from "../../iconify/icon/nornalise.
|
|
1
|
+
import { convertSVGContentToCSSRules } from "../../svg-css/content.js";
|
|
2
|
+
import { getGeneratedAssetFilename } from "../helpers/filenames/asset.js";
|
|
3
|
+
import { normaliseIconifyIcon } from "../../iconify/icon/nornalise.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Convert IconifyIcon data to FactoryIconData
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { getGeneratedAssetFilename } from "../helpers/filenames/asset.
|
|
2
|
-
import { getFactoryRelativeRootPath } from "../helpers/filenames/path.
|
|
1
|
+
import { getGeneratedAssetFilename } from "../helpers/filenames/asset.js";
|
|
2
|
+
import { getFactoryRelativeRootPath } from "../helpers/filenames/path.js";
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Generate file system options
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FactoryGeneratedComponent } from "./types/component.js";
|
|
2
|
+
import { FactoryIconData } from "./types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "./types/options.js";
|
|
4
|
+
/**
|
|
5
|
+
* Create raw component code
|
|
6
|
+
*/
|
|
7
|
+
declare function createRawComponent(data: FactoryIconData, options: ComponentFactoryOptions): FactoryGeneratedComponent;
|
|
8
|
+
export { createRawComponent };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { getComponentSizeValues } from "./helpers/content/size.
|
|
2
|
-
import { stringifyFactoryIconContent } from "./helpers/content/stringify.
|
|
3
|
-
import { stringifyIconViewBox } from "../svg/viewbox/value.
|
|
4
|
-
import { createFactoryImports } from "./helpers/imports/create.
|
|
5
|
-
import { generateCSSFilesForComponent } from "./helpers/css/generate.
|
|
6
|
-
import { factoryPropTemplate, stringifyFactoryProps } from "./helpers/props/stringify.
|
|
7
|
-
import { stringifyFactoryImports } from "./helpers/imports/stringify.
|
|
8
|
-
import { getGeneratedComponentTypesFilename } from "./helpers/filenames/types.
|
|
1
|
+
import { getComponentSizeValues } from "./helpers/content/size.js";
|
|
2
|
+
import { stringifyFactoryIconContent } from "./helpers/content/stringify.js";
|
|
3
|
+
import { stringifyIconViewBox } from "../svg/viewbox/value.js";
|
|
4
|
+
import { createFactoryImports } from "./helpers/imports/create.js";
|
|
5
|
+
import { generateCSSFilesForComponent } from "./helpers/css/generate.js";
|
|
6
|
+
import { factoryPropTemplate, stringifyFactoryProps } from "./helpers/props/stringify.js";
|
|
7
|
+
import { stringifyFactoryImports } from "./helpers/imports/stringify.js";
|
|
8
|
+
import { getGeneratedComponentTypesFilename } from "./helpers/filenames/types.js";
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Create raw component code
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FactoryGeneratedComponent } from "./types/component.
|
|
2
|
-
import { FactoryIconData } from "./types/data.
|
|
3
|
-
import { ComponentFactoryOptions } from "./types/options.
|
|
1
|
+
import { FactoryGeneratedComponent } from "./types/component.js";
|
|
2
|
+
import { FactoryIconData } from "./types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "./types/options.js";
|
|
4
4
|
interface SvelteOptions extends ComponentFactoryOptions {
|
|
5
5
|
ts?: boolean;
|
|
6
6
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { getComponentSizeValues } from "./helpers/content/size.
|
|
2
|
-
import { stringifyFactoryIconContent } from "./helpers/content/stringify.
|
|
3
|
-
import { stringifyIconViewBox } from "../svg/viewbox/value.
|
|
4
|
-
import { createFactoryImports } from "./helpers/imports/create.
|
|
5
|
-
import { generateCSSFilesForComponent } from "./helpers/css/generate.
|
|
6
|
-
import { addSizeFunctionAsset } from "./helpers/functions/size.
|
|
7
|
-
import { stringifyFactoryProps } from "./helpers/props/stringify.
|
|
8
|
-
import { stringifyFactoryImports } from "./helpers/imports/stringify.
|
|
9
|
-
import { makeSquareViewBox } from "../svg/viewbox/square.
|
|
10
|
-
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.
|
|
11
|
-
import { minifyViewBox } from "../svg/viewbox/minify.
|
|
12
|
-
import { getViewBoxRatio } from "./helpers/content/ratio.
|
|
13
|
-
import { addSvelteComponentTypes } from "./helpers/ts/svelte.
|
|
1
|
+
import { getComponentSizeValues } from "./helpers/content/size.js";
|
|
2
|
+
import { stringifyFactoryIconContent } from "./helpers/content/stringify.js";
|
|
3
|
+
import { stringifyIconViewBox } from "../svg/viewbox/value.js";
|
|
4
|
+
import { createFactoryImports } from "./helpers/imports/create.js";
|
|
5
|
+
import { generateCSSFilesForComponent } from "./helpers/css/generate.js";
|
|
6
|
+
import { addSizeFunctionAsset } from "./helpers/functions/size.js";
|
|
7
|
+
import { stringifyFactoryProps } from "./helpers/props/stringify.js";
|
|
8
|
+
import { stringifyFactoryImports } from "./helpers/imports/stringify.js";
|
|
9
|
+
import { makeSquareViewBox } from "../svg/viewbox/square.js";
|
|
10
|
+
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.js";
|
|
11
|
+
import { minifyViewBox } from "../svg/viewbox/minify.js";
|
|
12
|
+
import { getViewBoxRatio } from "./helpers/content/ratio.js";
|
|
13
|
+
import { addSvelteComponentTypes } from "./helpers/ts/svelte.js";
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Create Svelte component code
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UniqueHashPartialOptions } from "../../helpers/hash/types.
|
|
2
|
-
import { CSSExportMode } from "./css.
|
|
1
|
+
import { UniqueHashPartialOptions } from "../../helpers/hash/types.js";
|
|
2
|
+
import { CSSExportMode } from "./css.js";
|
|
3
3
|
/**
|
|
4
4
|
* Asset path, generated from configuration
|
|
5
5
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { CSSKeyframes, CSSRules } from "../../css/types.
|
|
2
|
-
import { ConvertedSVGContent } from "../../svg-css/types.
|
|
1
|
+
import { CSSKeyframes, CSSRules } from "../../css/types.js";
|
|
2
|
+
import { ConvertedSVGContent } from "../../svg-css/types.js";
|
|
3
3
|
/**
|
|
4
4
|
* Content for component factory
|
|
5
5
|
*/
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FactoryGeneratedComponent } from "./types/component.js";
|
|
2
|
+
import { FactoryIconData } from "./types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "./types/options.js";
|
|
4
|
+
/**
|
|
5
|
+
* Create functional Vue component code
|
|
6
|
+
*/
|
|
7
|
+
declare function createVueFunctionalComponent(data: FactoryIconData, options: ComponentFactoryOptions): FactoryGeneratedComponent;
|
|
8
|
+
export { createVueFunctionalComponent };
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { getComponentSizeValues } from "./helpers/content/size.
|
|
2
|
-
import { stringifyFactoryIconContent } from "./helpers/content/stringify.
|
|
3
|
-
import { stringifyIconViewBox } from "../svg/viewbox/value.
|
|
4
|
-
import { createFactoryImports } from "./helpers/imports/create.
|
|
5
|
-
import { generateCSSFilesForComponent } from "./helpers/css/generate.
|
|
6
|
-
import { addSizeFunctionAsset } from "./helpers/functions/size.
|
|
7
|
-
import { stringifyFactoryPropsAsJSON } from "./helpers/props/object.
|
|
8
|
-
import { stringifyFactoryImports } from "./helpers/imports/stringify.
|
|
9
|
-
import { makeSquareViewBox } from "../svg/viewbox/square.
|
|
10
|
-
import { getUsedFactoryProps } from "./helpers/props/ts.
|
|
11
|
-
import { minifyViewBox } from "../svg/viewbox/minify.
|
|
12
|
-
import { getViewBoxRatio } from "./helpers/content/ratio.
|
|
13
|
-
import { addVueComponentTypes } from "./helpers/ts/vue.
|
|
1
|
+
import { getComponentSizeValues } from "./helpers/content/size.js";
|
|
2
|
+
import { stringifyFactoryIconContent } from "./helpers/content/stringify.js";
|
|
3
|
+
import { stringifyIconViewBox } from "../svg/viewbox/value.js";
|
|
4
|
+
import { createFactoryImports } from "./helpers/imports/create.js";
|
|
5
|
+
import { generateCSSFilesForComponent } from "./helpers/css/generate.js";
|
|
6
|
+
import { addSizeFunctionAsset } from "./helpers/functions/size.js";
|
|
7
|
+
import { stringifyFactoryPropsAsJSON } from "./helpers/props/object.js";
|
|
8
|
+
import { stringifyFactoryImports } from "./helpers/imports/stringify.js";
|
|
9
|
+
import { makeSquareViewBox } from "../svg/viewbox/square.js";
|
|
10
|
+
import { getUsedFactoryProps } from "./helpers/props/ts.js";
|
|
11
|
+
import { minifyViewBox } from "../svg/viewbox/minify.js";
|
|
12
|
+
import { getViewBoxRatio } from "./helpers/content/ratio.js";
|
|
13
|
+
import { addVueComponentTypes } from "./helpers/ts/vue.js";
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Create functional Vue component code
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FactoryGeneratedComponent } from "./types/component.
|
|
2
|
-
import { FactoryIconData } from "./types/data.
|
|
3
|
-
import { ComponentFactoryOptions } from "./types/options.
|
|
1
|
+
import { FactoryGeneratedComponent } from "./types/component.js";
|
|
2
|
+
import { FactoryIconData } from "./types/data.js";
|
|
3
|
+
import { ComponentFactoryOptions } from "./types/options.js";
|
|
4
4
|
interface VueOptions extends ComponentFactoryOptions {
|
|
5
5
|
ts?: boolean;
|
|
6
6
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { getComponentSizeValues } from "./helpers/content/size.
|
|
2
|
-
import { stringifyFactoryIconContent } from "./helpers/content/stringify.
|
|
3
|
-
import { stringifyIconViewBox } from "../svg/viewbox/value.
|
|
4
|
-
import { createFactoryImports } from "./helpers/imports/create.
|
|
5
|
-
import { generateCSSFilesForComponent } from "./helpers/css/generate.
|
|
6
|
-
import { addSizeFunctionAsset } from "./helpers/functions/size.
|
|
7
|
-
import { stringifyFactoryProps } from "./helpers/props/stringify.
|
|
8
|
-
import { stringifyFactoryImports } from "./helpers/imports/stringify.
|
|
9
|
-
import { makeSquareViewBox } from "../svg/viewbox/square.
|
|
10
|
-
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.
|
|
11
|
-
import { minifyViewBox } from "../svg/viewbox/minify.
|
|
12
|
-
import { getViewBoxRatio } from "./helpers/content/ratio.
|
|
13
|
-
import { addVueComponentTypes } from "./helpers/ts/vue.
|
|
1
|
+
import { getComponentSizeValues } from "./helpers/content/size.js";
|
|
2
|
+
import { stringifyFactoryIconContent } from "./helpers/content/stringify.js";
|
|
3
|
+
import { stringifyIconViewBox } from "../svg/viewbox/value.js";
|
|
4
|
+
import { createFactoryImports } from "./helpers/imports/create.js";
|
|
5
|
+
import { generateCSSFilesForComponent } from "./helpers/css/generate.js";
|
|
6
|
+
import { addSizeFunctionAsset } from "./helpers/functions/size.js";
|
|
7
|
+
import { stringifyFactoryProps } from "./helpers/props/stringify.js";
|
|
8
|
+
import { stringifyFactoryImports } from "./helpers/imports/stringify.js";
|
|
9
|
+
import { makeSquareViewBox } from "../svg/viewbox/square.js";
|
|
10
|
+
import { getUsedFactoryProps, stringifyFactoryPropTypes } from "./helpers/props/ts.js";
|
|
11
|
+
import { minifyViewBox } from "../svg/viewbox/minify.js";
|
|
12
|
+
import { getViewBoxRatio } from "./helpers/content/ratio.js";
|
|
13
|
+
import { addVueComponentTypes } from "./helpers/ts/vue.js";
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Create Vue component code
|