@cypress-design/vue-icon 0.24.0 → 0.24.2
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/.turbo/turbo-build.log +4 -4
- package/CHANGELOG.md +15 -0
- package/Icon.ts +18 -17
- package/IconVue.cy.tsx +25 -5
- package/_TreeShakableIcons.ts +222 -222
- package/compileProperties.ts +10 -5
- package/dist/Icon.d.ts +140 -4
- package/dist/Icon.d.ts.map +1 -1
- package/dist/_TreeShakableIcons.d.ts +221 -221
- package/dist/_TreeShakableIcons.d.ts.map +1 -1
- package/dist/compileProperties.d.ts +1 -0
- package/dist/compileProperties.d.ts.map +1 -1
- package/dist/index.es.mjs +10 -13
- package/dist/index.es.mjs.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/generate-icons.js +5 -5
- package/package.json +2 -2
package/generate-icons.js
CHANGED
|
@@ -10,7 +10,7 @@ const iconsComponents = Object.keys(iconsMetadata).map((name) => {
|
|
|
10
10
|
const pascalCaseName = pascalCase(name)
|
|
11
11
|
const iconMetadata = iconsMetadata[name]
|
|
12
12
|
const availableIds = iconMetadata.availableSizes.map(
|
|
13
|
-
(size) => `${camelCase(name)}X${size}
|
|
13
|
+
(size) => `${camelCase(name)}X${size}`,
|
|
14
14
|
)
|
|
15
15
|
|
|
16
16
|
const iconBodies = iconSet.reduce((acc, icon) => {
|
|
@@ -28,12 +28,12 @@ const iconsComponents = Object.keys(iconsMetadata).map((name) => {
|
|
|
28
28
|
|
|
29
29
|
return dedent`
|
|
30
30
|
export const Icon${pascalCaseName} = defineComponent((props: Omit<iconsRegistry.Icon${pascalCaseName}Props, 'name'> & {
|
|
31
|
-
class?:
|
|
31
|
+
class?: any
|
|
32
32
|
}, { attrs }: { attrs: Omit<SVGAttributes, 'name' | 'class'> }) => {
|
|
33
33
|
const iconPropsStep = useIconProps(props, ${JSON.stringify(
|
|
34
34
|
iconBodies,
|
|
35
35
|
null,
|
|
36
|
-
2
|
|
36
|
+
2,
|
|
37
37
|
)}, ${JSON.stringify(iconMetadata.availableSizes)}, ${JSON.stringify(name)})
|
|
38
38
|
|
|
39
39
|
const { componentProps, defs } = compileVueIconProperties(iconPropsStep)
|
|
@@ -90,7 +90,7 @@ function hyperSVG(
|
|
|
90
90
|
defs: ComputedRef<string | undefined>,
|
|
91
91
|
shouldRenderDefs: Ref<boolean>,
|
|
92
92
|
attrs: SVGAttributes,
|
|
93
|
-
className?:
|
|
93
|
+
className?: any,
|
|
94
94
|
) {
|
|
95
95
|
|
|
96
96
|
return shouldRenderDefs.value && defs.value
|
|
@@ -125,6 +125,6 @@ async function writeFile(fileContents) {
|
|
|
125
125
|
await fs.writeFile(
|
|
126
126
|
path.resolve(__dirname, './_TreeShakableIcons.ts'),
|
|
127
127
|
fileContents,
|
|
128
|
-
'utf-8'
|
|
128
|
+
'utf-8',
|
|
129
129
|
)
|
|
130
130
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cypress-design/vue-icon",
|
|
3
|
-
"version": "0.24.
|
|
3
|
+
"version": "0.24.2",
|
|
4
4
|
"files": [
|
|
5
5
|
"*"
|
|
6
6
|
],
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"build:types": "yarn tsc --project ./tsconfig.build.json"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@cypress-design/icon-registry": "^0.
|
|
24
|
+
"@cypress-design/icon-registry": "^0.26.0"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
27
|
"@cypress-design/rollup-plugin-tailwind-keep": "*",
|