@common-origin/design-system 3.2.0 → 3.3.0
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/dist/client.js +34 -10
- package/dist/client.js.map +1 -1
- package/dist/components/atoms/Icon/Icon.d.mts +1 -1
- package/dist/components/atoms/Icon/Icon.d.ts +1 -1
- package/dist/components/atoms/Icon/Icon.mjs +35 -10
- package/dist/data.js +2460 -7
- package/dist/data.js.map +1 -1
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -0
- package/dist/index.mjs.map +1 -1
- package/dist/lib/statusShapes.mjs +1 -1
- package/dist/lib/statusShapes.mjs.map +1 -1
- package/dist/styles/iconSet.json.mjs +2442 -0
- package/dist/styles/iconSet.json.mjs.map +1 -0
- package/dist/types/iconSet.d.mts +6 -0
- package/dist/types/iconSet.d.ts +6 -0
- package/dist/types/iconSet.mjs +12 -0
- package/dist/types/iconSet.mjs.map +1 -0
- package/dist/types/icons.d.mts +58 -6
- package/dist/types/icons.d.ts +58 -6
- package/dist/types/icons.mjs +5 -0
- package/dist/types/icons.mjs.map +1 -1
- package/dist/types/index.d.mts +1 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +5 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"iconSet.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import iconSetJson from '../styles/iconSet.json.mjs';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Every icon `Icon` draws, keyed by `IconName`, with its metadata, its source and its shapes
|
|
5
|
+
* (decision 0058). Read it to list icons or to draw one outside `Icon`.
|
|
6
|
+
*/
|
|
7
|
+
// Cast through unknown: JSON imports infer arrays, not the element tuples. iconSet.test.ts checks
|
|
8
|
+
// the data really has this shape. Typed so emitted .d.ts files don't import JSON.
|
|
9
|
+
var iconSet = iconSetJson;
|
|
10
|
+
|
|
11
|
+
export { iconSet };
|
|
12
|
+
//# sourceMappingURL=iconSet.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"iconSet.mjs","sources":["../../src/types/iconSet.ts"],"sourcesContent":["import iconSetJson from '../styles/iconSet.json'\nimport type { IconSet } from './icons'\n\n/**\n * Every icon `Icon` draws, keyed by `IconName`, with its metadata, its source and its shapes\n * (decision 0058). Read it to list icons or to draw one outside `Icon`.\n */\n// Cast through unknown: JSON imports infer arrays, not the element tuples. iconSet.test.ts checks\n// the data really has this shape. Typed so emitted .d.ts files don't import JSON.\nexport const iconSet = iconSetJson as unknown as IconSet\n"],"names":["iconSet","iconSetJson"],"mappings":";;AAGA;;;AAGG;AACH;AACA;AACO,IAAMA,OAAO,GAAGC;;;;"}
|
package/dist/types/icons.d.mts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Every icon `Icon` can draw: the keys of `iconSet` (decision 0058). Generated by
|
|
3
|
+
* `npm run icon:add` from `iconSet.json`; don't edit it by hand.
|
|
4
|
+
*/
|
|
5
|
+
export type IconName = 'add' | 'addRing' | 'ai' | 'arrowDown' | 'arrowLeft' | 'arrowRight' | 'arrowUp' | 'back' | 'bell' | 'cancel' | 'caret' | 'caretDown' | 'caretUp' | 'check' | 'checkRing' | 'close' | 'copy' | 'creditCard' | 'crossCircle' | 'directionRight' | 'directionUp' | 'edit' | 'export' | 'fileDocSearch' | 'filter' | 'home' | 'info' | 'kebab' | 'lamp' | 'lineOut' | 'link' | 'meatballs' | 'menu' | 'message' | 'mic' | 'move' | 'order' | 'paper' | 'pause' | 'play' | 'playBack' | 'refresh' | 'remove' | 'search' | 'sidebar' | 'star' | 'starFilled' | 'statusCancelled' | 'statusError' | 'statusInProgress' | 'statusInfo' | 'statusNotStarted' | 'statusPending' | 'statusScheduled' | 'statusSerious' | 'statusSuccess' | 'statusWarning' | 'stop' | 'table' | 'trash' | 'userBox' | 'view' | 'viewHide' | 'wallet';
|
|
2
6
|
/** Semantic category for grouping icons by purpose */
|
|
3
7
|
export type IconCategory = 'action' | 'communication' | 'content' | 'feedback' | 'media' | 'navigation' | 'object' | 'status' | 'user';
|
|
4
|
-
/**
|
|
5
|
-
export interface
|
|
6
|
-
/** SVG path data */
|
|
7
|
-
path: string;
|
|
8
|
+
/** Metadata every icon carries, whatever its format */
|
|
9
|
+
export interface IconDescription {
|
|
8
10
|
/** Display name of the icon */
|
|
9
11
|
name: string;
|
|
10
12
|
/** What the icon visually depicts */
|
|
@@ -20,6 +22,56 @@ export interface IconMetadata {
|
|
|
20
22
|
/** Suggested accessible label when the icon conveys meaning */
|
|
21
23
|
ariaLabelDefault: string;
|
|
22
24
|
}
|
|
23
|
-
/** The
|
|
25
|
+
/** The SVG shapes an icon is drawn from */
|
|
26
|
+
export type IconElementTag = 'path' | 'circle' | 'ellipse' | 'rect' | 'line' | 'polyline' | 'polygon';
|
|
27
|
+
/**
|
|
28
|
+
* One shape of an icon: its tag and its geometry attributes (`d`, `cx`, `points`…), on a 24px
|
|
29
|
+
* grid, plus `fill: 'currentColor'` for a filled dot. Lucide's own format, so icons copy across
|
|
30
|
+
* unchanged.
|
|
31
|
+
*/
|
|
32
|
+
export type IconElement = [tag: IconElementTag, attributes: Record<string, string>];
|
|
33
|
+
/**
|
|
34
|
+
* How an icon is painted, always in `currentColor`:
|
|
35
|
+
* - `stroke`: 2px lines with round caps and joins, no fill (Lucide icons)
|
|
36
|
+
* - `fill`: solid shapes, no line
|
|
37
|
+
* - `both`: lines and a fill, such as a filled star
|
|
38
|
+
*/
|
|
39
|
+
export type IconPaint = 'stroke' | 'fill' | 'both';
|
|
40
|
+
/**
|
|
41
|
+
* Where an icon comes from (decision 0058): copied from Lucide, with its Lucide name, or
|
|
42
|
+
* maintained in this repository. Icons carried over from 3.2.0 are `common-origin` until they move
|
|
43
|
+
* to Lucide.
|
|
44
|
+
*/
|
|
45
|
+
export type IconSource = {
|
|
46
|
+
library: 'lucide';
|
|
47
|
+
name: string;
|
|
48
|
+
} | {
|
|
49
|
+
library: 'common-origin';
|
|
50
|
+
};
|
|
51
|
+
/** An icon in `iconSet`: its metadata, where it comes from, and how to draw it */
|
|
52
|
+
export interface IconDefinition extends IconDescription {
|
|
53
|
+
source: IconSource;
|
|
54
|
+
paint: IconPaint;
|
|
55
|
+
elements: IconElement[];
|
|
56
|
+
}
|
|
57
|
+
/** The icon set keyed by IconName */
|
|
58
|
+
export type IconSet = Record<IconName, IconDefinition>;
|
|
59
|
+
/**
|
|
60
|
+
* An entry in the frozen `iconsData`: one filled path and its metadata.
|
|
61
|
+
* @deprecated Use `IconDefinition` and `iconSet`. Removed in 4.0 (decision 0058).
|
|
62
|
+
*/
|
|
63
|
+
export interface IconMetadata extends IconDescription {
|
|
64
|
+
/** SVG path data */
|
|
65
|
+
path: string;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* The type of the frozen `iconsData`.
|
|
69
|
+
* @deprecated Use `IconSet` and `iconSet`. Removed in 4.0 (decision 0058).
|
|
70
|
+
*/
|
|
24
71
|
export type IconRegistry = Record<IconName, IconMetadata>;
|
|
72
|
+
/**
|
|
73
|
+
* The 64 icons as they were in 3.2.0, each one filled path. Frozen: icons added since have no
|
|
74
|
+
* entry here, and `Icon` no longer reads it.
|
|
75
|
+
* @deprecated Use `iconSet`, which holds every icon `Icon` draws. Removed in 4.0 (decision 0058).
|
|
76
|
+
*/
|
|
25
77
|
export declare const iconsData: IconRegistry;
|
package/dist/types/icons.d.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Every icon `Icon` can draw: the keys of `iconSet` (decision 0058). Generated by
|
|
3
|
+
* `npm run icon:add` from `iconSet.json`; don't edit it by hand.
|
|
4
|
+
*/
|
|
5
|
+
export type IconName = 'add' | 'addRing' | 'ai' | 'arrowDown' | 'arrowLeft' | 'arrowRight' | 'arrowUp' | 'back' | 'bell' | 'cancel' | 'caret' | 'caretDown' | 'caretUp' | 'check' | 'checkRing' | 'close' | 'copy' | 'creditCard' | 'crossCircle' | 'directionRight' | 'directionUp' | 'edit' | 'export' | 'fileDocSearch' | 'filter' | 'home' | 'info' | 'kebab' | 'lamp' | 'lineOut' | 'link' | 'meatballs' | 'menu' | 'message' | 'mic' | 'move' | 'order' | 'paper' | 'pause' | 'play' | 'playBack' | 'refresh' | 'remove' | 'search' | 'sidebar' | 'star' | 'starFilled' | 'statusCancelled' | 'statusError' | 'statusInProgress' | 'statusInfo' | 'statusNotStarted' | 'statusPending' | 'statusScheduled' | 'statusSerious' | 'statusSuccess' | 'statusWarning' | 'stop' | 'table' | 'trash' | 'userBox' | 'view' | 'viewHide' | 'wallet';
|
|
2
6
|
/** Semantic category for grouping icons by purpose */
|
|
3
7
|
export type IconCategory = 'action' | 'communication' | 'content' | 'feedback' | 'media' | 'navigation' | 'object' | 'status' | 'user';
|
|
4
|
-
/**
|
|
5
|
-
export interface
|
|
6
|
-
/** SVG path data */
|
|
7
|
-
path: string;
|
|
8
|
+
/** Metadata every icon carries, whatever its format */
|
|
9
|
+
export interface IconDescription {
|
|
8
10
|
/** Display name of the icon */
|
|
9
11
|
name: string;
|
|
10
12
|
/** What the icon visually depicts */
|
|
@@ -20,6 +22,56 @@ export interface IconMetadata {
|
|
|
20
22
|
/** Suggested accessible label when the icon conveys meaning */
|
|
21
23
|
ariaLabelDefault: string;
|
|
22
24
|
}
|
|
23
|
-
/** The
|
|
25
|
+
/** The SVG shapes an icon is drawn from */
|
|
26
|
+
export type IconElementTag = 'path' | 'circle' | 'ellipse' | 'rect' | 'line' | 'polyline' | 'polygon';
|
|
27
|
+
/**
|
|
28
|
+
* One shape of an icon: its tag and its geometry attributes (`d`, `cx`, `points`…), on a 24px
|
|
29
|
+
* grid, plus `fill: 'currentColor'` for a filled dot. Lucide's own format, so icons copy across
|
|
30
|
+
* unchanged.
|
|
31
|
+
*/
|
|
32
|
+
export type IconElement = [tag: IconElementTag, attributes: Record<string, string>];
|
|
33
|
+
/**
|
|
34
|
+
* How an icon is painted, always in `currentColor`:
|
|
35
|
+
* - `stroke`: 2px lines with round caps and joins, no fill (Lucide icons)
|
|
36
|
+
* - `fill`: solid shapes, no line
|
|
37
|
+
* - `both`: lines and a fill, such as a filled star
|
|
38
|
+
*/
|
|
39
|
+
export type IconPaint = 'stroke' | 'fill' | 'both';
|
|
40
|
+
/**
|
|
41
|
+
* Where an icon comes from (decision 0058): copied from Lucide, with its Lucide name, or
|
|
42
|
+
* maintained in this repository. Icons carried over from 3.2.0 are `common-origin` until they move
|
|
43
|
+
* to Lucide.
|
|
44
|
+
*/
|
|
45
|
+
export type IconSource = {
|
|
46
|
+
library: 'lucide';
|
|
47
|
+
name: string;
|
|
48
|
+
} | {
|
|
49
|
+
library: 'common-origin';
|
|
50
|
+
};
|
|
51
|
+
/** An icon in `iconSet`: its metadata, where it comes from, and how to draw it */
|
|
52
|
+
export interface IconDefinition extends IconDescription {
|
|
53
|
+
source: IconSource;
|
|
54
|
+
paint: IconPaint;
|
|
55
|
+
elements: IconElement[];
|
|
56
|
+
}
|
|
57
|
+
/** The icon set keyed by IconName */
|
|
58
|
+
export type IconSet = Record<IconName, IconDefinition>;
|
|
59
|
+
/**
|
|
60
|
+
* An entry in the frozen `iconsData`: one filled path and its metadata.
|
|
61
|
+
* @deprecated Use `IconDefinition` and `iconSet`. Removed in 4.0 (decision 0058).
|
|
62
|
+
*/
|
|
63
|
+
export interface IconMetadata extends IconDescription {
|
|
64
|
+
/** SVG path data */
|
|
65
|
+
path: string;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* The type of the frozen `iconsData`.
|
|
69
|
+
* @deprecated Use `IconSet` and `iconSet`. Removed in 4.0 (decision 0058).
|
|
70
|
+
*/
|
|
24
71
|
export type IconRegistry = Record<IconName, IconMetadata>;
|
|
72
|
+
/**
|
|
73
|
+
* The 64 icons as they were in 3.2.0, each one filled path. Frozen: icons added since have no
|
|
74
|
+
* entry here, and `Icon` no longer reads it.
|
|
75
|
+
* @deprecated Use `iconSet`, which holds every icon `Icon` draws. Removed in 4.0 (decision 0058).
|
|
76
|
+
*/
|
|
25
77
|
export declare const iconsData: IconRegistry;
|
package/dist/types/icons.mjs
CHANGED
|
@@ -3,6 +3,11 @@ import iconsJson from '../styles/icons.json.mjs';
|
|
|
3
3
|
// Icon type definitions for external consumption
|
|
4
4
|
// This is a self-contained type that doesn't depend on JSON imports
|
|
5
5
|
// to ensure it works correctly in consuming projects
|
|
6
|
+
/**
|
|
7
|
+
* The 64 icons as they were in 3.2.0, each one filled path. Frozen: icons added since have no
|
|
8
|
+
* entry here, and `Icon` no longer reads it.
|
|
9
|
+
* @deprecated Use `iconSet`, which holds every icon `Icon` draws. Removed in 4.0 (decision 0058).
|
|
10
|
+
*/
|
|
6
11
|
// Typed as IconRegistry so emitted .d.ts files don't import JSON (needs `resolveJsonModule` in consumers).
|
|
7
12
|
var iconsData = iconsJson;
|
|
8
13
|
|
package/dist/types/icons.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icons.mjs","sources":["../../src/types/icons.ts"],"sourcesContent":["// Icon type definitions for external consumption\n// This is a self-contained type that doesn't depend on JSON imports\n// to ensure it works correctly in consuming projects\n\nimport iconsJson from '../styles/icons.json'\n\nexport type IconName =\n | 'add'\n | '
|
|
1
|
+
{"version":3,"file":"icons.mjs","sources":["../../src/types/icons.ts"],"sourcesContent":["// Icon type definitions for external consumption\n// This is a self-contained type that doesn't depend on JSON imports\n// to ensure it works correctly in consuming projects\n\nimport iconsJson from '../styles/icons.json'\n\n/**\n * Every icon `Icon` can draw: the keys of `iconSet` (decision 0058). Generated by\n * `npm run icon:add` from `iconSet.json`; don't edit it by hand.\n */\nexport type IconName =\n | 'add'\n | 'addRing'\n | 'ai'\n | 'arrowDown'\n | 'arrowLeft'\n | 'arrowRight'\n | 'arrowUp'\n | 'back'\n | 'bell'\n | 'cancel'\n | 'caret'\n | 'caretDown'\n | 'caretUp'\n | 'check'\n | 'checkRing'\n | 'close'\n | 'copy'\n | 'creditCard'\n | 'crossCircle'\n | 'directionRight'\n | 'directionUp'\n | 'edit'\n | 'export'\n | 'fileDocSearch'\n | 'filter'\n | 'home'\n | 'info'\n | 'kebab'\n | 'lamp'\n | 'lineOut'\n | 'link'\n | 'meatballs'\n | 'menu'\n | 'message'\n | 'mic'\n | 'move'\n | 'order'\n | 'paper'\n | 'pause'\n | 'play'\n | 'playBack'\n | 'refresh'\n | 'remove'\n | 'search'\n | 'sidebar'\n | 'star'\n | 'starFilled'\n | 'statusCancelled'\n | 'statusError'\n | 'statusInProgress'\n | 'statusInfo'\n | 'statusNotStarted'\n | 'statusPending'\n | 'statusScheduled'\n | 'statusSerious'\n | 'statusSuccess'\n | 'statusWarning'\n | 'stop'\n | 'table'\n | 'trash'\n | 'userBox'\n | 'view'\n | 'viewHide'\n | 'wallet'\n\n/** Semantic category for grouping icons by purpose */\nexport type IconCategory =\n | 'action'\n | 'communication'\n | 'content'\n | 'feedback'\n | 'media'\n | 'navigation'\n | 'object'\n | 'status'\n | 'user'\n\n/** Metadata every icon carries, whatever its format */\nexport interface IconDescription {\n /** Display name of the icon */\n name: string\n /** What the icon visually depicts */\n description: string\n /** Semantic category for grouping */\n category: IconCategory\n /** Alternative names and search terms */\n aliases: string[]\n /** When and why to use this icon */\n intent: string\n /** Whether the icon is typically decorative (true) or informative (false) */\n decorativeDefault: boolean\n /** Suggested accessible label when the icon conveys meaning */\n ariaLabelDefault: string\n}\n\n/** The SVG shapes an icon is drawn from */\nexport type IconElementTag = 'path' | 'circle' | 'ellipse' | 'rect' | 'line' | 'polyline' | 'polygon'\n\n/**\n * One shape of an icon: its tag and its geometry attributes (`d`, `cx`, `points`…), on a 24px\n * grid, plus `fill: 'currentColor'` for a filled dot. Lucide's own format, so icons copy across\n * unchanged.\n */\nexport type IconElement = [tag: IconElementTag, attributes: Record<string, string>]\n\n/**\n * How an icon is painted, always in `currentColor`:\n * - `stroke`: 2px lines with round caps and joins, no fill (Lucide icons)\n * - `fill`: solid shapes, no line\n * - `both`: lines and a fill, such as a filled star\n */\nexport type IconPaint = 'stroke' | 'fill' | 'both'\n\n/**\n * Where an icon comes from (decision 0058): copied from Lucide, with its Lucide name, or\n * maintained in this repository. Icons carried over from 3.2.0 are `common-origin` until they move\n * to Lucide.\n */\nexport type IconSource = { library: 'lucide'; name: string } | { library: 'common-origin' }\n\n/** An icon in `iconSet`: its metadata, where it comes from, and how to draw it */\nexport interface IconDefinition extends IconDescription {\n source: IconSource\n paint: IconPaint\n elements: IconElement[]\n}\n\n/** The icon set keyed by IconName */\nexport type IconSet = Record<IconName, IconDefinition>\n\n/**\n * An entry in the frozen `iconsData`: one filled path and its metadata.\n * @deprecated Use `IconDefinition` and `iconSet`. Removed in 4.0 (decision 0058).\n */\nexport interface IconMetadata extends IconDescription {\n /** SVG path data */\n path: string\n}\n\n/**\n * The type of the frozen `iconsData`.\n * @deprecated Use `IconSet` and `iconSet`. Removed in 4.0 (decision 0058).\n */\nexport type IconRegistry = Record<IconName, IconMetadata>\n\n/**\n * The 64 icons as they were in 3.2.0, each one filled path. Frozen: icons added since have no\n * entry here, and `Icon` no longer reads it.\n * @deprecated Use `iconSet`, which holds every icon `Icon` draws. Removed in 4.0 (decision 0058).\n */\n// Typed as IconRegistry so emitted .d.ts files don't import JSON (needs `resolveJsonModule` in consumers).\nexport const iconsData = iconsJson as IconRegistry\n"],"names":["iconsData","iconsJson"],"mappings":";;AAAA;AACA;AACA;AA0JA;;;;AAIG;AACH;AACO,IAAMA,SAAS,GAAGC;;;;"}
|
package/dist/types/index.d.mts
CHANGED
package/dist/types/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@common-origin/design-system",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.3.0",
|
|
4
4
|
"description": "Common Origin Design System - Framework-agnostic atomic design components with comprehensive WCAG 2.2 AA testing",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"test:coverage": "jest --coverage",
|
|
66
66
|
"test:e2e": "playwright test",
|
|
67
67
|
"typecheck": "tsc --noEmit",
|
|
68
|
-
"lint": "eslint . --max-warnings
|
|
68
|
+
"lint": "eslint . --max-warnings 156",
|
|
69
69
|
"docs:dev": "npm run build:tokens && npm run dev",
|
|
70
70
|
"verify:types": "node scripts/verify-types.cjs",
|
|
71
71
|
"verify:no-nextjs": "node scripts/verify-no-nextjs-deps.cjs",
|
|
@@ -81,7 +81,8 @@
|
|
|
81
81
|
"release:tag": "./scripts/release.sh tag",
|
|
82
82
|
"tokens:golden": "node scripts/tokens-golden.cjs",
|
|
83
83
|
"tokens:palette": "node scripts/generate-palette.mjs && npm run build:tokens",
|
|
84
|
-
"verify:size": "node scripts/verify-size.mjs"
|
|
84
|
+
"verify:size": "node scripts/verify-size.mjs",
|
|
85
|
+
"icon:add": "node scripts/icon-add.mjs"
|
|
85
86
|
},
|
|
86
87
|
"peerDependencies": {
|
|
87
88
|
"react": "^18.0.0 || ^19.0.0",
|
|
@@ -127,6 +128,7 @@
|
|
|
127
128
|
"jest": "^30.0.2",
|
|
128
129
|
"jest-axe": "^9.0.0",
|
|
129
130
|
"jest-environment-jsdom": "^30.0.2",
|
|
131
|
+
"lucide-static": "1.66.0",
|
|
130
132
|
"next": "^16.3.6",
|
|
131
133
|
"publint": "^0.3.24",
|
|
132
134
|
"react": "^19.2.0",
|