@cupra/ui-react 2.0.0-canary.129 → 2.0.0-canary.130
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/README.md +18 -0
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -264,6 +264,24 @@ If `loadFonts` or `loadStyles` are `false`, you must manually include the corres
|
|
|
264
264
|
|
|
265
265
|
---
|
|
266
266
|
|
|
267
|
+
## Icons
|
|
268
|
+
|
|
269
|
+
Icons must always be consumed through the `<Icon>` React component — never by loading SVG files directly from the CDN.
|
|
270
|
+
|
|
271
|
+
SVG icon files are stored per-theme under the CDN and are optimised to work with the `Icon` component (they rely on CSS custom properties injected by the component to resolve color and size). Loading them directly as `<img>` tags or via `fetch` bypasses this mechanism and will produce unstyled, incorrectly-colored, or incorrectly-sized output.
|
|
272
|
+
|
|
273
|
+
```tsx
|
|
274
|
+
// Correct: use Icon
|
|
275
|
+
import { Icon } from '@cupra/ui-react/Icon';
|
|
276
|
+
|
|
277
|
+
<Icon icon-name="arrow-right" />
|
|
278
|
+
|
|
279
|
+
// Wrong: do not load icon SVGs from the CDN directly
|
|
280
|
+
<img src="https://ds-assets.cupra.com/[version]/assets/icons/[theme]/arrow-right.svg" />
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
---
|
|
284
|
+
|
|
267
285
|
## License
|
|
268
286
|
|
|
269
287
|
SEAT S.A. Library EULA 1.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cupra/ui-react",
|
|
3
|
-
"version": "2.0.0-canary.
|
|
3
|
+
"version": "2.0.0-canary.130",
|
|
4
4
|
"description": "React components library",
|
|
5
5
|
"author": "SEAT S.A.",
|
|
6
6
|
"license": "SEAT S.A. Library EULA 1.0",
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"peerDependencies": {
|
|
52
52
|
"react": ">= 18.3.1 < 20",
|
|
53
53
|
"react-dom": ">= 18.3.1 < 20",
|
|
54
|
-
"@cupra/ui-kit": "2.0.0-canary.
|
|
54
|
+
"@cupra/ui-kit": "2.0.0-canary.117",
|
|
55
55
|
"typescript": ">=5.0.0"
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"storybook": "^10.3.3",
|
|
77
77
|
"typescript": "^5.8.2",
|
|
78
78
|
"vite": "^8.0.5",
|
|
79
|
-
"@cupra/ui-kit": "2.0.0-canary.
|
|
79
|
+
"@cupra/ui-kit": "2.0.0-canary.117"
|
|
80
80
|
},
|
|
81
81
|
"scripts": {
|
|
82
82
|
"build": "rm -rf dist && pnpm --filter @cupra/ui-kit build:react && tsc --declaration --emitDeclarationOnly && BUILD_FORMAT=esm vite build --emptyOutDir false && BUILD_FORMAT=cjs vite build --emptyOutDir false",
|