@fangzhongya/icons 0.0.15 → 0.0.17

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.
Files changed (38) hide show
  1. package/dist/{vue.cjs → async.cjs} +23 -23
  2. package/dist/{vue.d.cts → async.d.cts} +20 -20
  3. package/dist/{vue.d.ts → async.d.ts} +20 -20
  4. package/dist/{vue.js → async.js} +23 -23
  5. package/dist/chunk-BKYM5ZD6.js +909 -0
  6. package/dist/{chunk-Y2JUP3JH.js → chunk-CDXRU53D.js} +4 -123
  7. package/dist/chunk-HSJ3RNOH.js +124 -0
  8. package/dist/chunk-OSHAEKZL.cjs +124 -0
  9. package/dist/{chunk-6UMRW5ES.cjs → chunk-P3DB3N7Y.cjs} +5 -124
  10. package/dist/chunk-V6F7B2R3.cjs +909 -0
  11. package/dist/iconify.cjs +2 -4
  12. package/dist/iconify.d.cts +1 -100
  13. package/dist/iconify.d.ts +1 -100
  14. package/dist/iconify.js +3 -5
  15. package/dist/index.cjs +17 -17
  16. package/dist/index.js +19 -19
  17. package/dist/index.json +1 -1
  18. package/dist/json.cjs +7 -0
  19. package/dist/json.d.cts +110 -0
  20. package/dist/json.d.ts +110 -0
  21. package/dist/json.js +7 -0
  22. package/dist/vite/index.cjs +293 -988
  23. package/dist/vite/index.d.cts +20 -1
  24. package/dist/vite/index.d.ts +20 -1
  25. package/dist/vite/index.js +298 -993
  26. package/dist/vite/index2.cjs +31 -9
  27. package/dist/vite/index2.d.cts +8 -7
  28. package/dist/vite/index2.d.ts +8 -7
  29. package/dist/vite/index2.js +32 -10
  30. package/dist/vite/index3.cjs +130 -0
  31. package/dist/vite/index3.d.cts +12 -0
  32. package/dist/vite/index3.d.ts +12 -0
  33. package/dist/vite/index3.js +130 -0
  34. package/dist/vue/index.cjs +16 -16
  35. package/dist/vue/index.js +19 -19
  36. package/package.json +2 -2
  37. package/dist/{chunk-3YRVWHZK.js → chunk-54HT4HDM.js} +18 -18
  38. package/dist/{chunk-BWFROGEZ.cjs → chunk-KXZN54UH.cjs} +15 -15
@@ -1,12 +1,31 @@
1
1
  import { Plugin } from 'vite';
2
2
 
3
+ type IconReplacement = (iconName: string, attributes: ComponentAttributes) => {
4
+ text: string;
5
+ imptext: string;
6
+ };
3
7
  interface PluginOptions {
4
8
  name?: string;
5
9
  type?: string;
6
10
  directory?: string;
11
+ customReplacement?: IconReplacement;
12
+ virtual?: boolean;
13
+ replaced?: boolean;
7
14
  mobile?: boolean;
8
15
  dynamic?: boolean;
9
16
  }
17
+ interface ComponentAttributes {
18
+ name: string;
19
+ [key: string]: string | boolean | number;
20
+ }
21
+ interface ComponentMatchInfo {
22
+ componentName: string;
23
+ fullMatch: string;
24
+ start: number;
25
+ end: number;
26
+ attributes: ComponentAttributes;
27
+ isSelfClosing: boolean;
28
+ }
10
29
  declare function simpleFangIcon(options?: PluginOptions): Plugin;
11
30
 
12
- export { simpleFangIcon };
31
+ export { type ComponentAttributes, type ComponentMatchInfo, type IconReplacement, type PluginOptions, simpleFangIcon };
@@ -1,12 +1,31 @@
1
1
  import { Plugin } from 'vite';
2
2
 
3
+ type IconReplacement = (iconName: string, attributes: ComponentAttributes) => {
4
+ text: string;
5
+ imptext: string;
6
+ };
3
7
  interface PluginOptions {
4
8
  name?: string;
5
9
  type?: string;
6
10
  directory?: string;
11
+ customReplacement?: IconReplacement;
12
+ virtual?: boolean;
13
+ replaced?: boolean;
7
14
  mobile?: boolean;
8
15
  dynamic?: boolean;
9
16
  }
17
+ interface ComponentAttributes {
18
+ name: string;
19
+ [key: string]: string | boolean | number;
20
+ }
21
+ interface ComponentMatchInfo {
22
+ componentName: string;
23
+ fullMatch: string;
24
+ start: number;
25
+ end: number;
26
+ attributes: ComponentAttributes;
27
+ isSelfClosing: boolean;
28
+ }
10
29
  declare function simpleFangIcon(options?: PluginOptions): Plugin;
11
30
 
12
- export { simpleFangIcon };
31
+ export { type ComponentAttributes, type ComponentMatchInfo, type IconReplacement, type PluginOptions, simpleFangIcon };