@inzumer/ui-library 0.1.2 → 1.0.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/LICENSE +21 -0
- package/dist/chunk-2HCMNEIQ.js +25 -0
- package/dist/chunk-2HCMNEIQ.js.map +1 -0
- package/dist/chunk-5IHM2545.js +40 -0
- package/dist/chunk-5IHM2545.js.map +1 -0
- package/dist/chunk-6LLGTBM6.js +9 -0
- package/dist/chunk-6LLGTBM6.js.map +1 -0
- package/dist/chunk-7HQFLM4A.js +31 -0
- package/dist/chunk-7HQFLM4A.js.map +1 -0
- package/dist/chunk-BKPP4D3Q.js +62 -0
- package/dist/chunk-BKPP4D3Q.js.map +1 -0
- package/dist/chunk-BNEEI7S5.js +28 -0
- package/dist/chunk-BNEEI7S5.js.map +1 -0
- package/dist/chunk-D4I5OF3C.js +43 -0
- package/dist/chunk-D4I5OF3C.js.map +1 -0
- package/dist/chunk-HCLY7B4H.js +90 -0
- package/dist/chunk-HCLY7B4H.js.map +1 -0
- package/dist/chunk-JCJP427C.js +31 -0
- package/dist/chunk-JCJP427C.js.map +1 -0
- package/dist/chunk-K35XIA25.js +81 -0
- package/dist/chunk-K35XIA25.js.map +1 -0
- package/dist/chunk-KWSZ2S34.js +76 -0
- package/dist/chunk-KWSZ2S34.js.map +1 -0
- package/dist/chunk-LK2EJ4H6.js +78 -0
- package/dist/chunk-LK2EJ4H6.js.map +1 -0
- package/dist/chunk-N5CLCKR3.js +71 -0
- package/dist/chunk-N5CLCKR3.js.map +1 -0
- package/dist/chunk-P4CV2EPR.js +72 -0
- package/dist/chunk-P4CV2EPR.js.map +1 -0
- package/dist/chunk-P4Z7HH66.js +14 -0
- package/dist/chunk-P4Z7HH66.js.map +1 -0
- package/dist/chunk-PE6XEC7Y.js +27 -0
- package/dist/chunk-PE6XEC7Y.js.map +1 -0
- package/dist/chunk-PVDRNAYK.js +68 -0
- package/dist/chunk-PVDRNAYK.js.map +1 -0
- package/dist/chunk-UL33H4AD.js +24 -0
- package/dist/chunk-UL33H4AD.js.map +1 -0
- package/dist/chunk-ZABQF65Z.js +74 -0
- package/dist/chunk-ZABQF65Z.js.map +1 -0
- package/dist/components/atoms/Button/index.d.ts +23 -0
- package/dist/components/atoms/Button/index.js +4 -0
- package/dist/components/atoms/Button/index.js.map +1 -0
- package/dist/components/atoms/Icon/index.d.ts +19 -0
- package/dist/components/atoms/Icon/index.js +4 -0
- package/dist/components/atoms/Icon/index.js.map +1 -0
- package/dist/components/atoms/Image/index.d.ts +23 -0
- package/dist/components/atoms/Image/index.js +4 -0
- package/dist/components/atoms/Image/index.js.map +1 -0
- package/dist/components/atoms/Input/index.d.ts +25 -0
- package/dist/components/atoms/Input/index.js +5 -0
- package/dist/components/atoms/Input/index.js.map +1 -0
- package/dist/components/atoms/Link/index.d.ts +21 -0
- package/dist/components/atoms/Link/index.js +4 -0
- package/dist/components/atoms/Link/index.js.map +1 -0
- package/dist/components/atoms/RichText/index.d.ts +25 -0
- package/dist/components/atoms/RichText/index.js +4 -0
- package/dist/components/atoms/RichText/index.js.map +1 -0
- package/dist/components/atoms/Switch/index.d.ts +15 -0
- package/dist/components/atoms/Switch/index.js +5 -0
- package/dist/components/atoms/Switch/index.js.map +1 -0
- package/dist/components/molecules/BottomSheet/index.d.ts +19 -0
- package/dist/components/molecules/BottomSheet/index.js +8 -0
- package/dist/components/molecules/BottomSheet/index.js.map +1 -0
- package/dist/components/molecules/Breadcrumbs/index.d.ts +20 -0
- package/dist/components/molecules/Breadcrumbs/index.js +6 -0
- package/dist/components/molecules/Breadcrumbs/index.js.map +1 -0
- package/dist/components/molecules/Card/index.d.ts +25 -0
- package/dist/components/molecules/Card/index.js +5 -0
- package/dist/components/molecules/Card/index.js.map +1 -0
- package/dist/components/molecules/Language/index.d.ts +19 -0
- package/dist/components/molecules/Language/index.js +4 -0
- package/dist/components/molecules/Language/index.js.map +1 -0
- package/dist/components/molecules/Modal/index.d.ts +19 -0
- package/dist/components/molecules/Modal/index.js +8 -0
- package/dist/components/molecules/Modal/index.js.map +1 -0
- package/dist/components/molecules/Snackbar/index.d.ts +27 -0
- package/dist/components/molecules/Snackbar/index.js +5 -0
- package/dist/components/molecules/Snackbar/index.js.map +1 -0
- package/dist/components/molecules/Timeline/index.d.ts +16 -0
- package/dist/components/molecules/Timeline/index.js +5 -0
- package/dist/components/molecules/Timeline/index.js.map +1 -0
- package/dist/hooks/useDelayedUnmount/index.d.ts +10 -0
- package/dist/hooks/useDelayedUnmount/index.js +3 -0
- package/dist/hooks/useDelayedUnmount/index.js.map +1 -0
- package/dist/hooks/useDismissableLayer/index.d.ts +6 -0
- package/dist/hooks/useDismissableLayer/index.js +3 -0
- package/dist/hooks/useDismissableLayer/index.js.map +1 -0
- package/dist/hooks/useMediaQuery/index.d.ts +3 -0
- package/dist/hooks/useMediaQuery/index.js +3 -0
- package/dist/hooks/useMediaQuery/index.js.map +1 -0
- package/dist/hooks/useMergedRef/index.d.ts +6 -0
- package/dist/hooks/useMergedRef/index.js +3 -0
- package/dist/hooks/useMergedRef/index.js.map +1 -0
- package/dist/index.d.ts +24 -0
- package/dist/index.js +21 -0
- package/dist/index.js.map +1 -0
- package/dist/utils/cn/index.d.ts +5 -0
- package/dist/utils/cn/index.js +3 -0
- package/dist/utils/cn/index.js.map +1 -0
- package/package.json +117 -72
- package/README.md +0 -133
- package/dist/cjs/index.js +0 -2
- package/dist/cjs/index.js.map +0 -1
- package/dist/es/components/atoms/Button/Button.js +0 -54
- package/dist/es/components/atoms/Button/Button.js.map +0 -1
- package/dist/es/components/atoms/Button/Button.styles.js +0 -54
- package/dist/es/components/atoms/Button/Button.styles.js.map +0 -1
- package/dist/es/index.js +0 -17
- package/dist/es/index.js.map +0 -1
- package/dist/es/tokens/colors.js +0 -40
- package/dist/es/tokens/colors.js.map +0 -1
- package/dist/es/tokens/motion.js +0 -15
- package/dist/es/tokens/motion.js.map +0 -1
- package/dist/es/tokens/radius.js +0 -10
- package/dist/es/tokens/radius.js.map +0 -1
- package/dist/es/tokens/spacing.js +0 -12
- package/dist/es/tokens/spacing.js.map +0 -1
- package/dist/es/tokens/typography.js +0 -24
- package/dist/es/tokens/typography.js.map +0 -1
- package/dist/es/tokens/z-index.js +0 -12
- package/dist/es/tokens/z-index.js.map +0 -1
- package/dist/es/utils/cn.js +0 -9
- package/dist/es/utils/cn.js.map +0 -1
- package/dist/globals.css +0 -1
- package/dist/types/index.d.ts +0 -122
package/package.json
CHANGED
|
@@ -1,48 +1,119 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inzumer/ui-library",
|
|
3
|
-
"version": "0.1
|
|
4
|
-
"
|
|
3
|
+
"version": "1.0.1",
|
|
4
|
+
"private": false,
|
|
5
|
+
"description": "React UI component library for the Inzumer design system",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"author": "Nahuel Zamuner <inzumer@gmail.com>",
|
|
8
|
+
"homepage": "https://github.com/inzumer/ui-library/tree/main/packages/ui#readme",
|
|
9
|
+
"bugs": {
|
|
10
|
+
"url": "https://github.com/inzumer/ui-library/issues"
|
|
11
|
+
},
|
|
12
|
+
"repository": {
|
|
13
|
+
"type": "git",
|
|
14
|
+
"url": "https://github.com/inzumer/ui-library.git",
|
|
15
|
+
"directory": "packages/ui"
|
|
16
|
+
},
|
|
5
17
|
"keywords": [
|
|
6
18
|
"react",
|
|
7
|
-
"ui",
|
|
8
19
|
"component-library",
|
|
9
|
-
"accessibility",
|
|
10
20
|
"design-system",
|
|
11
|
-
"
|
|
21
|
+
"ui",
|
|
22
|
+
"tailwindcss",
|
|
23
|
+
"typescript"
|
|
12
24
|
],
|
|
13
|
-
"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"
|
|
25
|
+
"publishConfig": {
|
|
26
|
+
"access": "public"
|
|
27
|
+
},
|
|
28
|
+
"type": "module",
|
|
17
29
|
"sideEffects": false,
|
|
18
30
|
"exports": {
|
|
19
31
|
".": {
|
|
20
|
-
"types": "./dist/
|
|
21
|
-
"import": "./dist/
|
|
22
|
-
|
|
32
|
+
"types": "./dist/index.d.ts",
|
|
33
|
+
"import": "./dist/index.js"
|
|
34
|
+
},
|
|
35
|
+
"./button": {
|
|
36
|
+
"types": "./dist/components/atoms/Button/index.d.ts",
|
|
37
|
+
"import": "./dist/components/atoms/Button/index.js"
|
|
38
|
+
},
|
|
39
|
+
"./icon": {
|
|
40
|
+
"types": "./dist/components/atoms/Icon/index.d.ts",
|
|
41
|
+
"import": "./dist/components/atoms/Icon/index.js"
|
|
42
|
+
},
|
|
43
|
+
"./image": {
|
|
44
|
+
"types": "./dist/components/atoms/Image/index.d.ts",
|
|
45
|
+
"import": "./dist/components/atoms/Image/index.js"
|
|
46
|
+
},
|
|
47
|
+
"./input": {
|
|
48
|
+
"types": "./dist/components/atoms/Input/index.d.ts",
|
|
49
|
+
"import": "./dist/components/atoms/Input/index.js"
|
|
50
|
+
},
|
|
51
|
+
"./link": {
|
|
52
|
+
"types": "./dist/components/atoms/Link/index.d.ts",
|
|
53
|
+
"import": "./dist/components/atoms/Link/index.js"
|
|
54
|
+
},
|
|
55
|
+
"./rich-text": {
|
|
56
|
+
"types": "./dist/components/atoms/RichText/index.d.ts",
|
|
57
|
+
"import": "./dist/components/atoms/RichText/index.js"
|
|
58
|
+
},
|
|
59
|
+
"./switch": {
|
|
60
|
+
"types": "./dist/components/atoms/Switch/index.d.ts",
|
|
61
|
+
"import": "./dist/components/atoms/Switch/index.js"
|
|
62
|
+
},
|
|
63
|
+
"./bottom-sheet": {
|
|
64
|
+
"types": "./dist/components/molecules/BottomSheet/index.d.ts",
|
|
65
|
+
"import": "./dist/components/molecules/BottomSheet/index.js"
|
|
66
|
+
},
|
|
67
|
+
"./breadcrumbs": {
|
|
68
|
+
"types": "./dist/components/molecules/Breadcrumbs/index.d.ts",
|
|
69
|
+
"import": "./dist/components/molecules/Breadcrumbs/index.js"
|
|
70
|
+
},
|
|
71
|
+
"./card": {
|
|
72
|
+
"types": "./dist/components/molecules/Card/index.d.ts",
|
|
73
|
+
"import": "./dist/components/molecules/Card/index.js"
|
|
74
|
+
},
|
|
75
|
+
"./language": {
|
|
76
|
+
"types": "./dist/components/molecules/Language/index.d.ts",
|
|
77
|
+
"import": "./dist/components/molecules/Language/index.js"
|
|
78
|
+
},
|
|
79
|
+
"./modal": {
|
|
80
|
+
"types": "./dist/components/molecules/Modal/index.d.ts",
|
|
81
|
+
"import": "./dist/components/molecules/Modal/index.js"
|
|
82
|
+
},
|
|
83
|
+
"./snackbar": {
|
|
84
|
+
"types": "./dist/components/molecules/Snackbar/index.d.ts",
|
|
85
|
+
"import": "./dist/components/molecules/Snackbar/index.js"
|
|
86
|
+
},
|
|
87
|
+
"./timeline": {
|
|
88
|
+
"types": "./dist/components/molecules/Timeline/index.d.ts",
|
|
89
|
+
"import": "./dist/components/molecules/Timeline/index.js"
|
|
23
90
|
},
|
|
24
|
-
"./
|
|
91
|
+
"./use-delayed-unmount": {
|
|
92
|
+
"types": "./dist/hooks/useDelayedUnmount/index.d.ts",
|
|
93
|
+
"import": "./dist/hooks/useDelayedUnmount/index.js"
|
|
94
|
+
},
|
|
95
|
+
"./use-dismissable-layer": {
|
|
96
|
+
"types": "./dist/hooks/useDismissableLayer/index.d.ts",
|
|
97
|
+
"import": "./dist/hooks/useDismissableLayer/index.js"
|
|
98
|
+
},
|
|
99
|
+
"./use-media-query": {
|
|
100
|
+
"types": "./dist/hooks/useMediaQuery/index.d.ts",
|
|
101
|
+
"import": "./dist/hooks/useMediaQuery/index.js"
|
|
102
|
+
},
|
|
103
|
+
"./use-merged-ref": {
|
|
104
|
+
"types": "./dist/hooks/useMergedRef/index.d.ts",
|
|
105
|
+
"import": "./dist/hooks/useMergedRef/index.js"
|
|
106
|
+
},
|
|
107
|
+
"./cn": {
|
|
108
|
+
"types": "./dist/utils/cn/index.d.ts",
|
|
109
|
+
"import": "./dist/utils/cn/index.js"
|
|
110
|
+
}
|
|
25
111
|
},
|
|
26
112
|
"files": [
|
|
27
113
|
"dist"
|
|
28
114
|
],
|
|
29
|
-
"
|
|
30
|
-
"
|
|
31
|
-
"prebuild": "rm -rf dist",
|
|
32
|
-
"build": "BUILD_FORMAT=es vite build && BUILD_FORMAT=cjs vite build && npx tailwindcss -i ./src/styles/globals.css -o ./dist/globals.css --minify",
|
|
33
|
-
"build:storybook": "storybook build",
|
|
34
|
-
"test": "vitest run",
|
|
35
|
-
"test:watch": "vitest",
|
|
36
|
-
"test:coverage": "vitest run --coverage",
|
|
37
|
-
"typecheck": "tsc --noEmit",
|
|
38
|
-
"lint": "eslint src --ext .ts,.tsx",
|
|
39
|
-
"lint:fix": "eslint src --ext .ts,.tsx --fix",
|
|
40
|
-
"format": "prettier --write \"src/**/*.{ts,tsx}\"",
|
|
41
|
-
"format:check": "prettier --check \"src/**/*.{ts,tsx}\"",
|
|
42
|
-
"pre-publish": "npm run typecheck && npm run test && npm run build",
|
|
43
|
-
"publish:dry": "npm pack --dry-run",
|
|
44
|
-
"publish:local": "npm pack",
|
|
45
|
-
"release": "npm run pre-publish && npm publish --access public"
|
|
115
|
+
"dependencies": {
|
|
116
|
+
"@inzumer/tokens": "1.0.0"
|
|
46
117
|
},
|
|
47
118
|
"peerDependencies": {
|
|
48
119
|
"class-variance-authority": ">=0.7.0",
|
|
@@ -51,59 +122,33 @@
|
|
|
51
122
|
"react-dom": ">=18 || ^19",
|
|
52
123
|
"tailwind-merge": ">=2.0.0"
|
|
53
124
|
},
|
|
54
|
-
"peerDependenciesMeta": {
|
|
55
|
-
"class-variance-authority": {
|
|
56
|
-
"optional": false
|
|
57
|
-
},
|
|
58
|
-
"clsx": {
|
|
59
|
-
"optional": false
|
|
60
|
-
},
|
|
61
|
-
"tailwind-merge": {
|
|
62
|
-
"optional": false
|
|
63
|
-
}
|
|
64
|
-
},
|
|
65
125
|
"devDependencies": {
|
|
66
|
-
"@storybook/addon-a11y": "^8.4.7",
|
|
67
|
-
"@storybook/addon-actions": "8.6.18",
|
|
68
|
-
"@storybook/addon-docs": "8.6.18",
|
|
69
|
-
"@storybook/addon-interactions": "8.6.18",
|
|
70
|
-
"@storybook/addon-themes": "8.6.18",
|
|
71
|
-
"@storybook/addon-viewport": "^8.4.7",
|
|
72
|
-
"@storybook/react": "^8.4.7",
|
|
73
|
-
"@storybook/react-vite": "^8.4.7",
|
|
74
|
-
"@storybook/test": "^8.4.7",
|
|
75
|
-
"@testing-library/dom": "10.4.1",
|
|
76
126
|
"@testing-library/jest-dom": "^6.6.3",
|
|
77
127
|
"@testing-library/react": "^16.1.0",
|
|
78
128
|
"@testing-library/user-event": "^14.5.2",
|
|
79
|
-
"@types/jest-axe": "3.5.9",
|
|
80
129
|
"@types/react": "^18.3.12",
|
|
81
130
|
"@types/react-dom": "^18.3.1",
|
|
82
|
-
"@typescript-eslint/eslint-plugin": "^8.16.0",
|
|
83
|
-
"@typescript-eslint/parser": "^8.16.0",
|
|
84
|
-
"@vitejs/plugin-react": "^4.3.4",
|
|
85
131
|
"@vitest/coverage-v8": "^2.1.6",
|
|
86
|
-
"autoprefixer": "^10.4.20",
|
|
87
132
|
"class-variance-authority": "0.7.1",
|
|
88
133
|
"clsx": "2.1.1",
|
|
89
|
-
"eslint": "^9.
|
|
90
|
-
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
91
|
-
"eslint-plugin-react": "^7.37.3",
|
|
92
|
-
"eslint-plugin-react-hooks": "^5.0.0",
|
|
93
|
-
"eslint-plugin-storybook": "^0.11.1",
|
|
94
|
-
"jest-axe": "^9.0.0",
|
|
134
|
+
"eslint": "^9.39.5",
|
|
95
135
|
"jsdom": "^25.0.1",
|
|
96
|
-
"postcss": "^8.4.49",
|
|
97
|
-
"prettier": "^3.4.2",
|
|
98
|
-
"storybook": "^8.4.7",
|
|
99
136
|
"tailwind-merge": "2.6.1",
|
|
100
|
-
"
|
|
137
|
+
"tsup": "^8.3.5",
|
|
101
138
|
"typescript": "^5.7.2",
|
|
102
|
-
"vite": "^6.
|
|
103
|
-
"
|
|
104
|
-
"
|
|
139
|
+
"vite-tsconfig-paths": "^6.1.1",
|
|
140
|
+
"vitest": "^2.1.6",
|
|
141
|
+
"@inzumer/eslint-config": "0.1.0",
|
|
142
|
+
"@inzumer/tsconfig": "0.1.0"
|
|
105
143
|
},
|
|
106
|
-
"
|
|
107
|
-
"
|
|
144
|
+
"scripts": {
|
|
145
|
+
"build": "tsup",
|
|
146
|
+
"dev": "tsup --watch",
|
|
147
|
+
"typecheck": "tsc --noEmit",
|
|
148
|
+
"test": "vitest run",
|
|
149
|
+
"test:watch": "vitest",
|
|
150
|
+
"test:coverage": "vitest run --coverage",
|
|
151
|
+
"lint": "eslint src",
|
|
152
|
+
"clean": "node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\""
|
|
108
153
|
}
|
|
109
|
-
}
|
|
154
|
+
}
|
package/README.md
DELETED
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
# @inzumer/ui
|
|
2
|
-
|
|
3
|
-
Production-grade React component library for web applications and mobile WebViews.
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
`@inzumer/ui` provides a unified, accessible, and performant design system for TypeScript React projects. It enforces consistent visual language, interaction patterns, and WCAG 2.1 AA accessibility standards across web and WebView platforms.
|
|
10
|
-
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
## Stack
|
|
14
|
-
|
|
15
|
-
| Tool | Purpose |
|
|
16
|
-
|---|---|
|
|
17
|
-
| React 18 | Component model |
|
|
18
|
-
| TypeScript (strict) | Type safety |
|
|
19
|
-
| Vite | Build tooling (library mode) |
|
|
20
|
-
| Tailwind CSS | Token-driven styling |
|
|
21
|
-
| class-variance-authority | Variant management |
|
|
22
|
-
| Vitest + RTL | Unit and accessibility testing |
|
|
23
|
-
| Storybook 8 | Component documentation |
|
|
24
|
-
| ESLint + Prettier | Code quality |
|
|
25
|
-
|
|
26
|
-
---
|
|
27
|
-
|
|
28
|
-
## Setup
|
|
29
|
-
|
|
30
|
-
### Prerequisites
|
|
31
|
-
|
|
32
|
-
- Node.js >=20
|
|
33
|
-
- npm >=10
|
|
34
|
-
|
|
35
|
-
### Install dependencies
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
npm install
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
### Development
|
|
42
|
-
|
|
43
|
-
```bash
|
|
44
|
-
npm run dev
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
Opens Storybook at `http://localhost:6006`.
|
|
48
|
-
|
|
49
|
-
---
|
|
50
|
-
|
|
51
|
-
## Scripts
|
|
52
|
-
|
|
53
|
-
| Command | Description |
|
|
54
|
-
|---|---|
|
|
55
|
-
| `npm run dev` | Start Storybook development server |
|
|
56
|
-
| `npm run build` | Build library for distribution |
|
|
57
|
-
| `npm run build:storybook` | Build static Storybook |
|
|
58
|
-
| `npm test` | Run test suite |
|
|
59
|
-
| `npm run test:watch` | Run tests in watch mode |
|
|
60
|
-
| `npm run test:coverage` | Run tests with coverage report |
|
|
61
|
-
| `npm run typecheck` | TypeScript type check (no emit) |
|
|
62
|
-
| `npm run lint` | Lint source files |
|
|
63
|
-
| `npm run lint:fix` | Lint and auto-fix |
|
|
64
|
-
| `npm run format` | Format source files with Prettier |
|
|
65
|
-
| `npm run format:check` | Check formatting without writing |
|
|
66
|
-
|
|
67
|
-
---
|
|
68
|
-
|
|
69
|
-
## Using the library
|
|
70
|
-
|
|
71
|
-
```tsx
|
|
72
|
-
import { Button } from '@inzumer/ui'
|
|
73
|
-
import '@inzumer/ui/dist/style.css'
|
|
74
|
-
|
|
75
|
-
export function App() {
|
|
76
|
-
return (
|
|
77
|
-
<Button variant="primary" onClick={() => console.log('clicked')}>
|
|
78
|
-
Click me
|
|
79
|
-
</Button>
|
|
80
|
-
)
|
|
81
|
-
}
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
---
|
|
85
|
-
|
|
86
|
-
## Contributing
|
|
87
|
-
|
|
88
|
-
### Architecture rules
|
|
89
|
-
|
|
90
|
-
All agents and architecture rules are defined in `.claude/agents/`. Read them before contributing.
|
|
91
|
-
|
|
92
|
-
### Planning requirement
|
|
93
|
-
|
|
94
|
-
All non-trivial changes require a planning document in `/docs/plans/` before implementation begins.
|
|
95
|
-
See `YYYY-MM-DD-task-name.md` format.
|
|
96
|
-
|
|
97
|
-
### Architectural decisions
|
|
98
|
-
|
|
99
|
-
Significant architecture changes require an ADR in `/docs/adr/`.
|
|
100
|
-
|
|
101
|
-
### Code standards
|
|
102
|
-
|
|
103
|
-
- Zero `any` — strict TypeScript throughout
|
|
104
|
-
- Semantic HTML first — no clickable `div`s
|
|
105
|
-
- Token-only Tailwind — no arbitrary values
|
|
106
|
-
- Every component must: be tested, be accessible, be Storybook-documented, be exported
|
|
107
|
-
|
|
108
|
-
### Commit convention
|
|
109
|
-
|
|
110
|
-
Conventional Commits format:
|
|
111
|
-
|
|
112
|
-
```
|
|
113
|
-
feat(button): add loading state
|
|
114
|
-
fix(button): correct focus ring on Firefox
|
|
115
|
-
docs: update README setup instructions
|
|
116
|
-
```
|
|
117
|
-
|
|
118
|
-
### Pull request checklist
|
|
119
|
-
|
|
120
|
-
- [ ] Planning document exists in `/docs/plans/`
|
|
121
|
-
- [ ] All tests pass (`npm test`)
|
|
122
|
-
- [ ] TypeScript passes (`npm run typecheck`)
|
|
123
|
-
- [ ] Lint passes (`npm run lint`)
|
|
124
|
-
- [ ] Storybook stories cover new states
|
|
125
|
-
- [ ] axe-core violations: zero
|
|
126
|
-
|
|
127
|
-
---
|
|
128
|
-
|
|
129
|
-
## Accessibility commitment
|
|
130
|
-
|
|
131
|
-
This library targets **WCAG 2.1 AA** compliance for every component. Accessibility is not optional and is tested automatically via axe-core on every build.
|
|
132
|
-
|
|
133
|
-
If you find an accessibility issue, please open an issue with the label `a11y`.
|
package/dist/cjs/index.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),d=require("react"),b=require("clsx"),f=require("tailwind-merge"),g=require("class-variance-authority");function p(...t){return f.twMerge(b.clsx(t))}const x=g.cva(["inline-flex items-center justify-center gap-2","font-medium rounded-md","transition-colors duration-base ease-ui","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50","motion-reduce:transition-none","min-h-touch min-w-touch"],{variants:{variant:{primary:["bg-primary-600 text-white","hover:bg-primary-700 active:bg-primary-800","focus-visible:ring-primary-500"],secondary:["bg-neutral-100 text-neutral-900 border border-neutral-300","hover:bg-neutral-200 active:bg-neutral-300","focus-visible:ring-neutral-500","dark:bg-neutral-800 dark:text-neutral-100 dark:border-neutral-600","dark:hover:bg-neutral-700"],ghost:["bg-transparent text-neutral-700","hover:bg-neutral-100 active:bg-neutral-200","focus-visible:ring-neutral-500","dark:text-neutral-300 dark:hover:bg-neutral-800"],danger:["bg-danger-500 text-white","hover:bg-danger-600 active:bg-danger-600","focus-visible:ring-danger-500"]},size:{sm:"h-8 px-3 text-sm",md:"h-10 px-4 text-sm",lg:"h-12 px-6 text-base"}},defaultVariants:{variant:"primary",size:"md"}}),h=()=>e.jsxs("svg",{className:"animate-spin h-4 w-4",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true",children:[e.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),e.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"})]}),s=d.forwardRef(({variant:t,size:n,isLoading:r=!1,loadingText:a,disabled:i,children:o,className:c,...l},u)=>{const m=i||r;return e.jsxs("button",{ref:u,disabled:m,"aria-busy":r,className:p(x({variant:t,size:n}),c),...l,children:[r&&e.jsx(h,{}),r&&a?a:o]})});s.displayName="Button";const v={primary:{50:"#eff6ff",100:"#dbeafe",200:"#bfdbfe",300:"#93c5fd",400:"#60a5fa",500:"#3b82f6",600:"#2563eb",700:"#1d4ed8",800:"#1e40af",900:"#1e3a8a",950:"#172554"},neutral:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#1f2937",900:"#111827",950:"#030712"},danger:{500:"#ef4444",600:"#dc2626"},success:{500:"#22c55e",600:"#16a34a"}},y={xs:"0.25rem",sm:"0.5rem",md:"1rem",lg:"1.5rem",xl:"2rem","2xl":"3rem"},w={sm:"0.25rem",md:"0.375rem",lg:"0.5rem",full:"9999px"},k={fontFamily:{sans:"Inter, system-ui, sans-serif",mono:"JetBrains Mono, monospace"},fontSize:{xs:"0.75rem",sm:"0.875rem",base:"1rem",lg:"1.125rem",xl:"1.25rem"},lineHeight:{xs:"1rem",sm:"1.25rem",base:"1.5rem",lg:"1.75rem",xl:"1.75rem"}},j={dropdown:1e3,sticky:1100,overlay:1200,modal:1300,toast:1400,tooltip:1500},z={duration:{fast:"100ms",base:"200ms",slow:"350ms"},easing:{ui:"cubic-bezier(0.4, 0, 0.2, 1)",spring:"cubic-bezier(0.34, 1.56, 0.64, 1)"}};exports.Button=s;exports.colors=v;exports.motion=z;exports.radius=w;exports.spacing=y;exports.typography=k;exports.zIndex=j;
|
|
2
|
-
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../src/utils/cn.ts","../../src/components/atoms/Button/Button.styles.ts","../../src/components/atoms/Button/Button.tsx","../../src/tokens/colors.ts","../../src/tokens/spacing.ts","../../src/tokens/radius.ts","../../src/tokens/typography.ts","../../src/tokens/z-index.ts","../../src/tokens/motion.ts"],"sourcesContent":["import { clsx, type ClassValue } from 'clsx'\nimport { twMerge } from 'tailwind-merge'\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import { cva } from 'class-variance-authority'\n\nexport const buttonVariants = cva(\n [\n 'inline-flex items-center justify-center gap-2',\n 'font-medium rounded-md',\n 'transition-colors duration-base ease-ui',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n 'motion-reduce:transition-none',\n 'min-h-touch min-w-touch',\n ],\n {\n variants: {\n variant: {\n primary: [\n 'bg-primary-600 text-white',\n 'hover:bg-primary-700 active:bg-primary-800',\n 'focus-visible:ring-primary-500',\n ],\n secondary: [\n 'bg-neutral-100 text-neutral-900 border border-neutral-300',\n 'hover:bg-neutral-200 active:bg-neutral-300',\n 'focus-visible:ring-neutral-500',\n 'dark:bg-neutral-800 dark:text-neutral-100 dark:border-neutral-600',\n 'dark:hover:bg-neutral-700',\n ],\n ghost: [\n 'bg-transparent text-neutral-700',\n 'hover:bg-neutral-100 active:bg-neutral-200',\n 'focus-visible:ring-neutral-500',\n 'dark:text-neutral-300 dark:hover:bg-neutral-800',\n ],\n danger: [\n 'bg-danger-500 text-white',\n 'hover:bg-danger-600 active:bg-danger-600',\n 'focus-visible:ring-danger-500',\n ],\n },\n size: {\n sm: 'h-8 px-3 text-sm',\n md: 'h-10 px-4 text-sm',\n lg: 'h-12 px-6 text-base',\n },\n },\n defaultVariants: {\n variant: 'primary',\n size: 'md',\n },\n },\n)\n","import { forwardRef } from 'react'\nimport { cn } from '@/utils/cn'\nimport { buttonVariants } from './Button.styles'\nimport type { ButtonProps } from './Button.types'\n\nconst Spinner = () => (\n <svg\n className=\"animate-spin h-4 w-4\"\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n aria-hidden=\"true\"\n >\n <circle className=\"opacity-25\" cx=\"12\" cy=\"12\" r=\"10\" stroke=\"currentColor\" strokeWidth=\"4\" />\n <path\n className=\"opacity-75\"\n fill=\"currentColor\"\n d=\"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z\"\n />\n </svg>\n)\n\nexport const Button = forwardRef<HTMLButtonElement, ButtonProps>(\n (\n {\n variant,\n size,\n isLoading = false,\n loadingText,\n disabled,\n children,\n className,\n ...props\n },\n ref,\n ) => {\n const isDisabled = disabled || isLoading\n\n return (\n <button\n ref={ref}\n disabled={isDisabled}\n aria-busy={isLoading}\n className={cn(buttonVariants({ variant, size }), className)}\n {...props}\n >\n {isLoading && <Spinner />}\n {isLoading && loadingText ? loadingText : children}\n </button>\n )\n },\n)\n\nButton.displayName = 'Button'\n","export const colors = {\n primary: {\n 50: '#eff6ff',\n 100: '#dbeafe',\n 200: '#bfdbfe',\n 300: '#93c5fd',\n 400: '#60a5fa',\n 500: '#3b82f6',\n 600: '#2563eb',\n 700: '#1d4ed8',\n 800: '#1e40af',\n 900: '#1e3a8a',\n 950: '#172554',\n },\n neutral: {\n 50: '#f9fafb',\n 100: '#f3f4f6',\n 200: '#e5e7eb',\n 300: '#d1d5db',\n 400: '#9ca3af',\n 500: '#6b7280',\n 600: '#4b5563',\n 700: '#374151',\n 800: '#1f2937',\n 900: '#111827',\n 950: '#030712',\n },\n danger: {\n 500: '#ef4444',\n 600: '#dc2626',\n },\n success: {\n 500: '#22c55e',\n 600: '#16a34a',\n },\n} as const\n","export const spacing = {\n xs: '0.25rem',\n sm: '0.5rem',\n md: '1rem',\n lg: '1.5rem',\n xl: '2rem',\n '2xl': '3rem',\n} as const\n","export const radius = {\n sm: '0.25rem',\n md: '0.375rem',\n lg: '0.5rem',\n full: '9999px',\n} as const\n","export const typography = {\n fontFamily: {\n sans: 'Inter, system-ui, sans-serif',\n mono: 'JetBrains Mono, monospace',\n },\n fontSize: {\n xs: '0.75rem',\n sm: '0.875rem',\n base: '1rem',\n lg: '1.125rem',\n xl: '1.25rem',\n },\n lineHeight: {\n xs: '1rem',\n sm: '1.25rem',\n base: '1.5rem',\n lg: '1.75rem',\n xl: '1.75rem',\n },\n} as const\n","export const zIndex = {\n dropdown: 1000,\n sticky: 1100,\n overlay: 1200,\n modal: 1300,\n toast: 1400,\n tooltip: 1500,\n} as const\n","export const motion = {\n duration: {\n fast: '100ms',\n base: '200ms',\n slow: '350ms',\n },\n easing: {\n ui: 'cubic-bezier(0.4, 0, 0.2, 1)',\n spring: 'cubic-bezier(0.34, 1.56, 0.64, 1)',\n },\n} as const\n"],"names":["cn","inputs","twMerge","clsx","buttonVariants","cva","Spinner","jsxs","jsx","Button","forwardRef","variant","size","isLoading","loadingText","disabled","children","className","props","ref","isDisabled","colors","spacing","radius","typography","zIndex","motion"],"mappings":"4NAGO,SAASA,KAAMC,EAAsB,CAC1C,OAAOC,EAAAA,QAAQC,OAAKF,CAAM,CAAC,CAC7B,CCHO,MAAMG,EAAiBC,EAAAA,IAC5B,CACE,gDACA,yBACA,0CACA,8EACA,mDACA,gCACA,yBAAA,EAEF,CACE,SAAU,CACR,QAAS,CACP,QAAS,CACP,4BACA,6CACA,gCAAA,EAEF,UAAW,CACT,4DACA,6CACA,iCACA,oEACA,2BAAA,EAEF,MAAO,CACL,kCACA,6CACA,iCACA,iDAAA,EAEF,OAAQ,CACN,2BACA,2CACA,+BAAA,CACF,EAEF,KAAM,CACJ,GAAI,mBACJ,GAAI,oBACJ,GAAI,qBAAA,CACN,EAEF,gBAAiB,CACf,QAAS,UACT,KAAM,IAAA,CACR,CAEJ,EC7CMC,EAAU,IACdC,EAAAA,KAAC,MAAA,CACC,UAAU,uBACV,MAAM,6BACN,KAAK,OACL,QAAQ,YACR,cAAY,OAEZ,SAAA,CAAAC,EAAAA,IAAC,SAAA,CAAO,UAAU,aAAa,GAAG,KAAK,GAAG,KAAK,EAAE,KAAK,OAAO,eAAe,YAAY,IAAI,EAC5FA,EAAAA,IAAC,OAAA,CACC,UAAU,aACV,KAAK,eACL,EAAE,6CAAA,CAAA,CACJ,CAAA,CACF,EAGWC,EAASC,EAAAA,WACpB,CACE,CACE,QAAAC,EACA,KAAAC,EACA,UAAAC,EAAY,GACZ,YAAAC,EACA,SAAAC,EACA,SAAAC,EACA,UAAAC,EACA,GAAGC,CAAA,EAELC,IACG,CACH,MAAMC,EAAaL,GAAYF,EAE/B,OACEN,EAAAA,KAAC,SAAA,CACC,IAAAY,EACA,SAAUC,EACV,YAAWP,EACX,UAAWb,EAAGI,EAAe,CAAE,QAAAO,EAAS,KAAAC,CAAA,CAAM,EAAGK,CAAS,EACzD,GAAGC,EAEH,SAAA,CAAAL,SAAcP,EAAA,EAAQ,EACtBO,GAAaC,EAAcA,EAAcE,CAAA,CAAA,CAAA,CAGhD,CACF,EAEAP,EAAO,YAAc,SCrDd,MAAMY,EAAS,CACpB,QAAS,CACP,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SAAA,EAEP,QAAS,CACP,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SAAA,EAEP,OAAQ,CACN,IAAK,UACL,IAAK,SAAA,EAEP,QAAS,CACP,IAAK,UACL,IAAK,SAAA,CAET,ECnCaC,EAAU,CACrB,GAAI,UACJ,GAAI,SACJ,GAAI,OACJ,GAAI,SACJ,GAAI,OACJ,MAAO,MACT,ECPaC,EAAS,CACpB,GAAI,UACJ,GAAI,WACJ,GAAI,SACJ,KAAM,QACR,ECLaC,EAAa,CACxB,WAAY,CACV,KAAM,+BACN,KAAM,2BAAA,EAER,SAAU,CACR,GAAI,UACJ,GAAI,WACJ,KAAM,OACN,GAAI,WACJ,GAAI,SAAA,EAEN,WAAY,CACV,GAAI,OACJ,GAAI,UACJ,KAAM,SACN,GAAI,UACJ,GAAI,SAAA,CAER,ECnBaC,EAAS,CACpB,SAAU,IACV,OAAQ,KACR,QAAS,KACT,MAAO,KACP,MAAO,KACP,QAAS,IACX,ECPaC,EAAS,CACpB,SAAU,CACR,KAAM,QACN,KAAM,QACN,KAAM,OAAA,EAER,OAAQ,CACN,GAAI,+BACJ,OAAQ,mCAAA,CAEZ"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { jsxs as e, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as p } from "react";
|
|
3
|
-
import { cn as f } from "../../../utils/cn.js";
|
|
4
|
-
import { buttonVariants as u } from "./Button.styles.js";
|
|
5
|
-
const d = () => /* @__PURE__ */ e(
|
|
6
|
-
"svg",
|
|
7
|
-
{
|
|
8
|
-
className: "animate-spin h-4 w-4",
|
|
9
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
10
|
-
fill: "none",
|
|
11
|
-
viewBox: "0 0 24 24",
|
|
12
|
-
"aria-hidden": "true",
|
|
13
|
-
children: [
|
|
14
|
-
/* @__PURE__ */ t("circle", { className: "opacity-25", cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }),
|
|
15
|
-
/* @__PURE__ */ t(
|
|
16
|
-
"path",
|
|
17
|
-
{
|
|
18
|
-
className: "opacity-75",
|
|
19
|
-
fill: "currentColor",
|
|
20
|
-
d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"
|
|
21
|
-
}
|
|
22
|
-
)
|
|
23
|
-
]
|
|
24
|
-
}
|
|
25
|
-
), h = p(
|
|
26
|
-
({
|
|
27
|
-
variant: o,
|
|
28
|
-
size: a,
|
|
29
|
-
isLoading: r = !1,
|
|
30
|
-
loadingText: s,
|
|
31
|
-
disabled: i,
|
|
32
|
-
children: c,
|
|
33
|
-
className: l,
|
|
34
|
-
...n
|
|
35
|
-
}, m) => /* @__PURE__ */ e(
|
|
36
|
-
"button",
|
|
37
|
-
{
|
|
38
|
-
ref: m,
|
|
39
|
-
disabled: i || r,
|
|
40
|
-
"aria-busy": r,
|
|
41
|
-
className: f(u({ variant: o, size: a }), l),
|
|
42
|
-
...n,
|
|
43
|
-
children: [
|
|
44
|
-
r && /* @__PURE__ */ t(d, {}),
|
|
45
|
-
r && s ? s : c
|
|
46
|
-
]
|
|
47
|
-
}
|
|
48
|
-
)
|
|
49
|
-
);
|
|
50
|
-
h.displayName = "Button";
|
|
51
|
-
export {
|
|
52
|
-
h as Button
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=Button.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button.js","sources":["../../../../../src/components/atoms/Button/Button.tsx"],"sourcesContent":["import { forwardRef } from 'react'\nimport { cn } from '@/utils/cn'\nimport { buttonVariants } from './Button.styles'\nimport type { ButtonProps } from './Button.types'\n\nconst Spinner = () => (\n <svg\n className=\"animate-spin h-4 w-4\"\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n aria-hidden=\"true\"\n >\n <circle className=\"opacity-25\" cx=\"12\" cy=\"12\" r=\"10\" stroke=\"currentColor\" strokeWidth=\"4\" />\n <path\n className=\"opacity-75\"\n fill=\"currentColor\"\n d=\"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z\"\n />\n </svg>\n)\n\nexport const Button = forwardRef<HTMLButtonElement, ButtonProps>(\n (\n {\n variant,\n size,\n isLoading = false,\n loadingText,\n disabled,\n children,\n className,\n ...props\n },\n ref,\n ) => {\n const isDisabled = disabled || isLoading\n\n return (\n <button\n ref={ref}\n disabled={isDisabled}\n aria-busy={isLoading}\n className={cn(buttonVariants({ variant, size }), className)}\n {...props}\n >\n {isLoading && <Spinner />}\n {isLoading && loadingText ? loadingText : children}\n </button>\n )\n },\n)\n\nButton.displayName = 'Button'\n"],"names":["Spinner","jsxs","jsx","Button","forwardRef","variant","size","isLoading","loadingText","disabled","children","className","props","ref","cn","buttonVariants"],"mappings":";;;;AAKA,MAAMA,IAAU,MACd,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,WAAU;AAAA,IACV,OAAM;AAAA,IACN,MAAK;AAAA,IACL,SAAQ;AAAA,IACR,eAAY;AAAA,IAEZ,UAAA;AAAA,MAAA,gBAAAC,EAAC,UAAA,EAAO,WAAU,cAAa,IAAG,MAAK,IAAG,MAAK,GAAE,MAAK,QAAO,gBAAe,aAAY,KAAI;AAAA,MAC5F,gBAAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,WAAU;AAAA,UACV,MAAK;AAAA,UACL,GAAE;AAAA,QAAA;AAAA,MAAA;AAAA,IACJ;AAAA,EAAA;AACF,GAGWC,IAASC;AAAA,EACpB,CACE;AAAA,IACE,SAAAC;AAAA,IACA,MAAAC;AAAA,IACA,WAAAC,IAAY;AAAA,IACZ,aAAAC;AAAA,IACA,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,WAAAC;AAAA,IACA,GAAGC;AAAA,EAAA,GAELC,MAKE,gBAAAZ;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,KAAAY;AAAA,MACA,UALeJ,KAAYF;AAAA,MAM3B,aAAWA;AAAA,MACX,WAAWO,EAAGC,EAAe,EAAE,SAAAV,GAAS,MAAAC,EAAA,CAAM,GAAGK,CAAS;AAAA,MACzD,GAAGC;AAAA,MAEH,UAAA;AAAA,QAAAL,uBAAcP,GAAA,EAAQ;AAAA,QACtBO,KAAaC,IAAcA,IAAcE;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIlD;AAEAP,EAAO,cAAc;"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { cva as e } from "class-variance-authority";
|
|
2
|
-
const t = e(
|
|
3
|
-
[
|
|
4
|
-
"inline-flex items-center justify-center gap-2",
|
|
5
|
-
"font-medium rounded-md",
|
|
6
|
-
"transition-colors duration-base ease-ui",
|
|
7
|
-
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",
|
|
8
|
-
"disabled:pointer-events-none disabled:opacity-50",
|
|
9
|
-
"motion-reduce:transition-none",
|
|
10
|
-
"min-h-touch min-w-touch"
|
|
11
|
-
],
|
|
12
|
-
{
|
|
13
|
-
variants: {
|
|
14
|
-
variant: {
|
|
15
|
-
primary: [
|
|
16
|
-
"bg-primary-600 text-white",
|
|
17
|
-
"hover:bg-primary-700 active:bg-primary-800",
|
|
18
|
-
"focus-visible:ring-primary-500"
|
|
19
|
-
],
|
|
20
|
-
secondary: [
|
|
21
|
-
"bg-neutral-100 text-neutral-900 border border-neutral-300",
|
|
22
|
-
"hover:bg-neutral-200 active:bg-neutral-300",
|
|
23
|
-
"focus-visible:ring-neutral-500",
|
|
24
|
-
"dark:bg-neutral-800 dark:text-neutral-100 dark:border-neutral-600",
|
|
25
|
-
"dark:hover:bg-neutral-700"
|
|
26
|
-
],
|
|
27
|
-
ghost: [
|
|
28
|
-
"bg-transparent text-neutral-700",
|
|
29
|
-
"hover:bg-neutral-100 active:bg-neutral-200",
|
|
30
|
-
"focus-visible:ring-neutral-500",
|
|
31
|
-
"dark:text-neutral-300 dark:hover:bg-neutral-800"
|
|
32
|
-
],
|
|
33
|
-
danger: [
|
|
34
|
-
"bg-danger-500 text-white",
|
|
35
|
-
"hover:bg-danger-600 active:bg-danger-600",
|
|
36
|
-
"focus-visible:ring-danger-500"
|
|
37
|
-
]
|
|
38
|
-
},
|
|
39
|
-
size: {
|
|
40
|
-
sm: "h-8 px-3 text-sm",
|
|
41
|
-
md: "h-10 px-4 text-sm",
|
|
42
|
-
lg: "h-12 px-6 text-base"
|
|
43
|
-
}
|
|
44
|
-
},
|
|
45
|
-
defaultVariants: {
|
|
46
|
-
variant: "primary",
|
|
47
|
-
size: "md"
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
);
|
|
51
|
-
export {
|
|
52
|
-
t as buttonVariants
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=Button.styles.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button.styles.js","sources":["../../../../../src/components/atoms/Button/Button.styles.ts"],"sourcesContent":["import { cva } from 'class-variance-authority'\n\nexport const buttonVariants = cva(\n [\n 'inline-flex items-center justify-center gap-2',\n 'font-medium rounded-md',\n 'transition-colors duration-base ease-ui',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n 'motion-reduce:transition-none',\n 'min-h-touch min-w-touch',\n ],\n {\n variants: {\n variant: {\n primary: [\n 'bg-primary-600 text-white',\n 'hover:bg-primary-700 active:bg-primary-800',\n 'focus-visible:ring-primary-500',\n ],\n secondary: [\n 'bg-neutral-100 text-neutral-900 border border-neutral-300',\n 'hover:bg-neutral-200 active:bg-neutral-300',\n 'focus-visible:ring-neutral-500',\n 'dark:bg-neutral-800 dark:text-neutral-100 dark:border-neutral-600',\n 'dark:hover:bg-neutral-700',\n ],\n ghost: [\n 'bg-transparent text-neutral-700',\n 'hover:bg-neutral-100 active:bg-neutral-200',\n 'focus-visible:ring-neutral-500',\n 'dark:text-neutral-300 dark:hover:bg-neutral-800',\n ],\n danger: [\n 'bg-danger-500 text-white',\n 'hover:bg-danger-600 active:bg-danger-600',\n 'focus-visible:ring-danger-500',\n ],\n },\n size: {\n sm: 'h-8 px-3 text-sm',\n md: 'h-10 px-4 text-sm',\n lg: 'h-12 px-6 text-base',\n },\n },\n defaultVariants: {\n variant: 'primary',\n size: 'md',\n },\n },\n)\n"],"names":["buttonVariants","cva"],"mappings":";AAEO,MAAMA,IAAiBC;AAAA,EAC5B;AAAA,IACE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EAAA;AAAA,EAEF;AAAA,IACE,UAAU;AAAA,MACR,SAAS;AAAA,QACP,SAAS;AAAA,UACP;AAAA,UACA;AAAA,UACA;AAAA,QAAA;AAAA,QAEF,WAAW;AAAA,UACT;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,QAAA;AAAA,QAEF,OAAO;AAAA,UACL;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,QAAA;AAAA,QAEF,QAAQ;AAAA,UACN;AAAA,UACA;AAAA,UACA;AAAA,QAAA;AAAA,MACF;AAAA,MAEF,MAAM;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,MAAA;AAAA,IACN;AAAA,IAEF,iBAAiB;AAAA,MACf,SAAS;AAAA,MACT,MAAM;AAAA,IAAA;AAAA,EACR;AAEJ;"}
|
package/dist/es/index.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { Button as t } from "./components/atoms/Button/Button.js";
|
|
2
|
-
import { colors as e } from "./tokens/colors.js";
|
|
3
|
-
import { motion as x } from "./tokens/motion.js";
|
|
4
|
-
import { radius as n } from "./tokens/radius.js";
|
|
5
|
-
import { spacing as i } from "./tokens/spacing.js";
|
|
6
|
-
import { typography as c } from "./tokens/typography.js";
|
|
7
|
-
import { zIndex as g } from "./tokens/z-index.js";
|
|
8
|
-
export {
|
|
9
|
-
t as Button,
|
|
10
|
-
e as colors,
|
|
11
|
-
x as motion,
|
|
12
|
-
n as radius,
|
|
13
|
-
i as spacing,
|
|
14
|
-
c as typography,
|
|
15
|
-
g as zIndex
|
|
16
|
-
};
|
|
17
|
-
//# sourceMappingURL=index.js.map
|
package/dist/es/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
|
package/dist/es/tokens/colors.js
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
const f = {
|
|
2
|
-
primary: {
|
|
3
|
-
50: "#eff6ff",
|
|
4
|
-
100: "#dbeafe",
|
|
5
|
-
200: "#bfdbfe",
|
|
6
|
-
300: "#93c5fd",
|
|
7
|
-
400: "#60a5fa",
|
|
8
|
-
500: "#3b82f6",
|
|
9
|
-
600: "#2563eb",
|
|
10
|
-
700: "#1d4ed8",
|
|
11
|
-
800: "#1e40af",
|
|
12
|
-
900: "#1e3a8a",
|
|
13
|
-
950: "#172554"
|
|
14
|
-
},
|
|
15
|
-
neutral: {
|
|
16
|
-
50: "#f9fafb",
|
|
17
|
-
100: "#f3f4f6",
|
|
18
|
-
200: "#e5e7eb",
|
|
19
|
-
300: "#d1d5db",
|
|
20
|
-
400: "#9ca3af",
|
|
21
|
-
500: "#6b7280",
|
|
22
|
-
600: "#4b5563",
|
|
23
|
-
700: "#374151",
|
|
24
|
-
800: "#1f2937",
|
|
25
|
-
900: "#111827",
|
|
26
|
-
950: "#030712"
|
|
27
|
-
},
|
|
28
|
-
danger: {
|
|
29
|
-
500: "#ef4444",
|
|
30
|
-
600: "#dc2626"
|
|
31
|
-
},
|
|
32
|
-
success: {
|
|
33
|
-
500: "#22c55e",
|
|
34
|
-
600: "#16a34a"
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
export {
|
|
38
|
-
f as colors
|
|
39
|
-
};
|
|
40
|
-
//# sourceMappingURL=colors.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"colors.js","sources":["../../../src/tokens/colors.ts"],"sourcesContent":["export const colors = {\n primary: {\n 50: '#eff6ff',\n 100: '#dbeafe',\n 200: '#bfdbfe',\n 300: '#93c5fd',\n 400: '#60a5fa',\n 500: '#3b82f6',\n 600: '#2563eb',\n 700: '#1d4ed8',\n 800: '#1e40af',\n 900: '#1e3a8a',\n 950: '#172554',\n },\n neutral: {\n 50: '#f9fafb',\n 100: '#f3f4f6',\n 200: '#e5e7eb',\n 300: '#d1d5db',\n 400: '#9ca3af',\n 500: '#6b7280',\n 600: '#4b5563',\n 700: '#374151',\n 800: '#1f2937',\n 900: '#111827',\n 950: '#030712',\n },\n danger: {\n 500: '#ef4444',\n 600: '#dc2626',\n },\n success: {\n 500: '#22c55e',\n 600: '#16a34a',\n },\n} as const\n"],"names":["colors"],"mappings":"AAAO,MAAMA,IAAS;AAAA,EACpB,SAAS;AAAA,IACP,IAAI;AAAA,IACJ,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,EAAA;AAAA,EAEP,SAAS;AAAA,IACP,IAAI;AAAA,IACJ,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AAAA,EAAA;AAAA,EAEP,QAAQ;AAAA,IACN,KAAK;AAAA,IACL,KAAK;AAAA,EAAA;AAAA,EAEP,SAAS;AAAA,IACP,KAAK;AAAA,IACL,KAAK;AAAA,EAAA;AAET;"}
|
package/dist/es/tokens/motion.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
const i = {
|
|
2
|
-
duration: {
|
|
3
|
-
fast: "100ms",
|
|
4
|
-
base: "200ms",
|
|
5
|
-
slow: "350ms"
|
|
6
|
-
},
|
|
7
|
-
easing: {
|
|
8
|
-
ui: "cubic-bezier(0.4, 0, 0.2, 1)",
|
|
9
|
-
spring: "cubic-bezier(0.34, 1.56, 0.64, 1)"
|
|
10
|
-
}
|
|
11
|
-
};
|
|
12
|
-
export {
|
|
13
|
-
i as motion
|
|
14
|
-
};
|
|
15
|
-
//# sourceMappingURL=motion.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"motion.js","sources":["../../../src/tokens/motion.ts"],"sourcesContent":["export const motion = {\n duration: {\n fast: '100ms',\n base: '200ms',\n slow: '350ms',\n },\n easing: {\n ui: 'cubic-bezier(0.4, 0, 0.2, 1)',\n spring: 'cubic-bezier(0.34, 1.56, 0.64, 1)',\n },\n} as const\n"],"names":["motion"],"mappings":"AAAO,MAAMA,IAAS;AAAA,EACpB,UAAU;AAAA,IACR,MAAM;AAAA,IACN,MAAM;AAAA,IACN,MAAM;AAAA,EAAA;AAAA,EAER,QAAQ;AAAA,IACN,IAAI;AAAA,IACJ,QAAQ;AAAA,EAAA;AAEZ;"}
|
package/dist/es/tokens/radius.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"radius.js","sources":["../../../src/tokens/radius.ts"],"sourcesContent":["export const radius = {\n sm: '0.25rem',\n md: '0.375rem',\n lg: '0.5rem',\n full: '9999px',\n} as const\n"],"names":["radius"],"mappings":"AAAO,MAAMA,IAAS;AAAA,EACpB,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,MAAM;AACR;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"spacing.js","sources":["../../../src/tokens/spacing.ts"],"sourcesContent":["export const spacing = {\n xs: '0.25rem',\n sm: '0.5rem',\n md: '1rem',\n lg: '1.5rem',\n xl: '2rem',\n '2xl': '3rem',\n} as const\n"],"names":["spacing"],"mappings":"AAAO,MAAMA,IAAU;AAAA,EACrB,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,OAAO;AACT;"}
|