@digitalpromise/design 1.0.1-next.2 → 2.0.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/README.md CHANGED
@@ -1,209 +1,25 @@
1
- # React + TypeScript + Vite
1
+ # Digital Promise Design Library
2
2
 
3
- This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
3
+ This is a React + Typescript + Tailwind + Vite component library for the development and maintenance of UI components aligned to the [Digital Promise Design System](https://app.gitbook.com/o/B4hdkVOolIXfg1cru4Mb/s/GC8UP51P947pbKSUyr6H/).
4
4
 
5
- Currently, two official plugins are available:
5
+ ## Getting Started
6
6
 
7
- - [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
8
- - [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
7
+ ### Installation
9
8
 
10
- ## Expanding the ESLint configuration
9
+ [NVM](https://github.com/nvm-sh/nvm) is recommended for the installation and management of Node.js. With NVM installed, you can view and develop components locally following these steps:
11
10
 
12
- If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:
11
+ - `nvm use` # Install or switch to specific version of Node
12
+ - `corepack enable` # Enabling tooling for switching Node package managers
13
+ - `corepack use pnpm` # Use the package manager pnpm
14
+ - `pnpm install` # Install dependencies
15
+ - `pnpm storybook` # Start Storybook
13
16
 
14
- - Configure the top-level `parserOptions` property like this:
17
+ This will install all project dependencies and start a local Storybook server.
15
18
 
16
- ```js
17
- parserOptions: {
18
- ecmaVersion: 'latest',
19
- sourceType: 'module',
20
- project: ['./tsconfig.json', './tsconfig.node.json'],
21
- tsconfigRootDir: __dirname,
22
- },
23
- ```
19
+ ### Style Dictionary
24
20
 
25
- - Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
26
- - Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
27
- - Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list
21
+ Design tokens are defined in the [tokens](./tokens/) directory and exported using [Style Dictionary](https://styledictionary.com/). These design tokens provide the fundamental style definitions for colors and spacing used to generate this component library's [Tailwind CSS](https://tailwindcss.com/) theme. Source and output options are specified in [config.json](./config.json).
28
22
 
29
- ## Basic Style Dictionary
23
+ ### Linting and Testing
30
24
 
31
- This example code is bare-bones to show you what this framework can do. If you have the style-dictionary module installed globally, you can `cd` into this directory and run:
32
- ```bash
33
- style-dictionary build
34
- ```
35
-
36
- You should see something like this output:
37
- ```
38
- Copying starter files...
39
-
40
- Source style dictionary starter files created!
41
-
42
- Running `style-dictionary build` for the first time to generate build artifacts.
43
-
44
-
45
- scss
46
- ✔︎ build/scss/_variables.scss
47
-
48
- android
49
- ✔︎ build/android/font_dimens.xml
50
- ✔︎ build/android/colors.xml
51
-
52
- compose
53
- ✔︎ build/compose/StyleDictionaryColor.kt
54
- ✔︎ build/compose/StyleDictionarySize.kt
55
-
56
- ios
57
- ✔︎ build/ios/StyleDictionaryColor.h
58
- ✔︎ build/ios/StyleDictionaryColor.m
59
- ✔︎ build/ios/StyleDictionarySize.h
60
- ✔︎ build/ios/StyleDictionarySize.m
61
-
62
- ios-swift
63
- ✔︎ build/ios-swift/StyleDictionary.swift
64
-
65
- ios-swift-separate-enums
66
- ✔︎ build/ios-swift/StyleDictionaryColor.swift
67
- ✔︎ build/ios-swift/StyleDictionarySize.swift
68
- ```
69
-
70
- Good for you! You have now built your first style dictionary! Moving on, take a look at what we have built. This should have created a build directory and it should look like this:
71
- ```
72
- ├── README.md
73
- ├── config.json
74
- ├── tokens/
75
- │ ├── color/
76
- │ ├── base.json
77
- │ ├── font.json
78
- │ ├── size/
79
- │ ├── font.json
80
- ├── build/
81
- │ ├── android/
82
- │ ├── font_dimens.xml
83
- │ ├── colors.xml
84
- │ ├── compose/
85
- │ ├── StyleDictionaryColor.kt
86
- │ ├── StyleDictionarySize.kt
87
- │ ├── scss/
88
- │ ├── _variables.scss
89
- │ ├── ios/
90
- │ ├── StyleDictionaryColor.h
91
- │ ├── StyleDictionaryColor.m
92
- │ ├── StyleDictionarySize.h
93
- │ ├── StyleDictionarySize.m
94
- │ ├── ios-swift/
95
- │ ├── StyleDictionary.swift
96
- │ ├── StyleDictionaryColor.swift
97
- │ ├── StyleDictionarySize.swift
98
- ```
99
-
100
- If you open `config.json` you will see there are 5 platforms defined: scss, android, compose, ios, and ios-swift. Each platform has a transformGroup, buildPath, and files. The buildPath and files of the platform should match up to the files what were built. The files built should look like these:
101
-
102
- **Android**
103
- ```xml
104
- <!-- font_dimens.xml -->
105
- <resources>
106
- <dimen name="size_font_small">12.00sp</dimen>
107
- <dimen name="size_font_medium">16.00sp</dimen>
108
- <dimen name="size_font_large">32.00sp</dimen>
109
- <dimen name="size_font_base">16.00sp</dimen>
110
- </resources>
111
-
112
- <!-- colors.xml -->
113
- <resources>
114
- <color name="color_base_gray_light">#ffcccccc</color>
115
- <color name="color_base_gray_medium">#ff999999</color>
116
- <color name="color_base_gray_dark">#ff111111</color>
117
- <color name="color_base_red">#ffff0000</color>
118
- <color name="color_base_green">#ff00ff00</color>
119
- <color name="color_font_base">#ffff0000</color>
120
- <color name="color_font_secondary">#ff00ff00</color>
121
- <color name="color_font_tertiary">#ffcccccc</color>
122
- </resources>
123
- ```
124
-
125
- **Compose**
126
- ```kotlin
127
- object StyleDictionaryColor {
128
- val colorBaseGrayDark = Color(0xff111111)
129
- val colorBaseGrayLight = Color(0xffcccccc)
130
- val colorBaseGrayMedium = Color(0xff999999)
131
- val colorBaseGreen = Color(0xff00ff00)
132
- val colorBaseRed = Color(0xffff0000)
133
- val colorFontBase = Color(0xffff0000)
134
- val colorFontSecondary = Color(0xff00ff00)
135
- val colorFontTertiary = Color(0xffcccccc)
136
- }
137
-
138
- object StyleDictionarySize {
139
- /** the base size of the font */
140
- val sizeFontBase = 16.00.sp
141
- /** the large size of the font */
142
- val sizeFontLarge = 32.00.sp
143
- /** the medium size of the font */
144
- val sizeFontMedium = 16.00.sp
145
- /** the small size of the font */
146
- val sizeFontSmall = 12.00.sp
147
- }
148
- ```
149
-
150
- **SCSS**
151
- ```scss
152
- // variables.scss
153
- $color-base-gray-light: #cccccc;
154
- $color-base-gray-medium: #999999;
155
- $color-base-gray-dark: #111111;
156
- $color-base-red: #ff0000;
157
- $color-base-green: #00ff00;
158
- $color-font-base: #ff0000;
159
- $color-font-secondary: #00ff00;
160
- $color-font-tertiary: #cccccc;
161
- $size-font-small: 0.75rem;
162
- $size-font-medium: 1rem;
163
- $size-font-large: 2rem;
164
- $size-font-base: 1rem;
165
- ```
166
-
167
- **iOS**
168
- ```objc
169
- #import "StyleDictionaryColor.h"
170
-
171
- @implementation StyleDictionaryColor
172
-
173
- + (UIColor *)color:(StyleDictionaryColorName)colorEnum{
174
- return [[self values] objectAtIndex:colorEnum];
175
- }
176
-
177
- + (NSArray *)values {
178
- static NSArray* colorArray;
179
- static dispatch_once_t onceToken;
180
-
181
- dispatch_once(&onceToken, ^{
182
- colorArray = @[
183
- [UIColor colorWithRed:0.800f green:0.800f blue:0.800f alpha:1.000f],
184
- [UIColor colorWithRed:0.600f green:0.600f blue:0.600f alpha:1.000f],
185
- [UIColor colorWithRed:0.067f green:0.067f blue:0.067f alpha:1.000f],
186
- [UIColor colorWithRed:1.000f green:0.000f blue:0.000f alpha:1.000f],
187
- [UIColor colorWithRed:0.000f green:1.000f blue:0.000f alpha:1.000f],
188
- [UIColor colorWithRed:1.000f green:0.000f blue:0.000f alpha:1.000f],
189
- [UIColor colorWithRed:0.000f green:1.000f blue:0.000f alpha:1.000f],
190
- [UIColor colorWithRed:0.800f green:0.800f blue:0.800f alpha:1.000f]
191
- ];
192
- });
193
-
194
- return colorArray;
195
- }
196
-
197
- @end
198
- ```
199
-
200
- Pretty nifty! This shows a few things happening:
201
- 1. The build system does a deep merge of all the token JSON files defined in the `source` attribute of `config.json`. This allows you to split up the token JSON files however you want. There are 2 JSON files with `color` as the top level key, but they get merged properly.
202
- 1. The build system resolves references to other design tokens. `{size.font.medium.value}` gets resolved properly.
203
- 1. The build system handles references to token values in other files as well as you can see in `tokens/color/font.json`.
204
-
205
- Now let's make a change and see how that affects things. Open up `tokens/color/base.json` and change `"#111111"` to `"#000000"`. After you make that change, save the file and re-run the build command `style-dictionary build`. Open up the build files and take a look.
206
-
207
- **Huzzah!**
208
-
209
- Now go forth and create! Take a look at all the built-in [transforms](https://amzn.github.io/style-dictionary/#/transforms?id=pre-defined-transforms) and [formats](https://amzn.github.io/style-dictionary/#/formats?id=pre-defined-formats).
25
+ Use `pnpm lint` to run static analysis on files in the `src` directory. Use `pnpm test` to run specs defined for components using [Vitest](https://vitest.dev/). See [vite.config.ts](./vite.config.ts) and the [testing setup script](./src/testing.ts) for further information about how those tests are configured to run.
@@ -1,7 +1,10 @@
1
1
  import type { ButtonHTMLAttributes } from "react";
2
+ declare const variants: readonly ["primary", "secondary", "tertiary"];
3
+ declare const states: readonly ["default", "danger", "inverse", "decolor"];
2
4
  type ButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & {
3
- state?: "inverse" | "danger" | "decolor";
5
+ variant?: (typeof variants)[number];
6
+ state?: (typeof states)[number];
4
7
  };
5
- export default function Button({ className, state, ...props }: ButtonProps): import("react/jsx-runtime").JSX.Element;
6
- export {};
8
+ export { variants, states };
9
+ export default function Button({ className, variant, state, ...props }: ButtonProps): import("react/jsx-runtime").JSX.Element;
7
10
  //# sourceMappingURL=button.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../src/components/button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAA;AAEjD,KAAK,WAAW,GAAG,oBAAoB,CAAC,iBAAiB,CAAC,GAAG;IACzD,KAAK,CAAC,EAAE,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAC;CAC5C,CAAA;AAED,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAC3B,SAAS,EACT,KAAK,EACL,GAAG,KAAK,EACX,EAAE,WAAW,2CAQb"}
1
+ {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../src/components/button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAElD,QAAA,MAAM,QAAQ,+CAAgD,CAAC;AAC/D,QAAA,MAAM,MAAM,sDAAuD,CAAC;AAEpE,KAAK,WAAW,GAAG,oBAAoB,CAAC,iBAAiB,CAAC,GAAG;IAC3D,OAAO,CAAC,EAAE,CAAC,OAAO,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC;IACpC,KAAK,CAAC,EAAE,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;CACjC,CAAC;AAEF,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,CAAC;AAE5B,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAC7B,SAAS,EACT,OAAmB,EACnB,KAAiB,EACjB,GAAG,KAAK,EACT,EAAE,WAAW,2CAKb"}
package/dist/index.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime");function s({className:u,state:t,...e}){return n.jsx("button",{"data-state":t,className:"btn",...e})}exports.Button=s;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime");function s({className:t,variant:e="primary",state:n="default",...o}){const r=[e,n].map(u=>"btn-"+u).join(" ");return i.jsx("button",{className:`btn ${r} ${t??""}`.trim(),...o})}exports.Button=s;
package/dist/index.js CHANGED
@@ -1,18 +1,13 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- function e({
3
- className: o,
4
- state: t,
5
- ...a
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ function s({
3
+ className: t,
4
+ variant: n = "primary",
5
+ state: o = "default",
6
+ ...r
6
7
  }) {
7
- return /* @__PURE__ */ n(
8
- "button",
9
- {
10
- "data-state": t,
11
- className: "btn",
12
- ...a
13
- }
14
- );
8
+ const m = [n, o].map((a) => "btn-" + a).join(" ");
9
+ return /* @__PURE__ */ e("button", { className: `btn ${m} ${t ?? ""}`.trim(), ...r });
15
10
  }
16
11
  export {
17
- e as Button
12
+ s as Button
18
13
  };
package/dist/main.css CHANGED
@@ -1 +1 @@
1
- @theme{--color-*: initial; --text-*: initial; --spacing-*: initial;}@theme{ --color-gray-1: #f4f4f4; --color-gray-2: #e6e6e6; --color-gray-3: #a3a3a3; --color-gray-4: #777777; --color-gray-5: #454545; --color-blue-1: #ebf4fa; --color-blue-2: #cce3f2; --color-blue-3: #348ec7; --color-blue-4: #2a7aac; --color-blue-5: #246289; --color-indigo-1: #eef2f9; --color-indigo-2: #d2d8ec; --color-indigo-3: #5a71b9; --color-indigo-4: #465da5; --color-indigo-5: #3a4d88; --color-purple-1: #f1eef6; --color-purple-2: #ddd5e9; --color-purple-3: #8164af; --color-purple-4: #6d509b; --color-purple-5: #5a4280; --color-violet-1: #f5eef6; --color-violet-2: #e6d5ea; --color-violet-3: #9a55aa; --color-violet-4: #81488e; --color-violet-5: #693a73; --color-magenta-1: #f6eef4; --color-magenta-2: #ead5e3; --color-magenta-3: #aa558e; --color-magenta-4: #8f4777; --color-magenta-5: #743a61; --color-red-1: #fcede8; --color-red-2: #f8d2c7; --color-red-3: #e45a2f; --color-red-4: #d0451b; --color-red-5: #ab3916; --color-orange-1: #fcf2e8; --color-orange-2: #f8dfc6; --color-orange-3: #e3811c; --color-orange-4: #c86400; --color-orange-5: #9e5000; --color-green-1: #f5f9eb; --color-green-2: #e6f1cd; --color-green-3: #82a82f; --color-green-4: #698826; --color-green-5: #50681d; --color-jade-1: #eef7f1; --color-jade-2: #d4eadd; --color-jade-3: #4e9d6d; --color-jade-4: #40815a; --color-jade-5: #336647; --color-teal-1: #eaf8fb; --color-teal-2: #caeef4; --color-teal-3: #259cb2; --color-teal-4: #1e7e90; --color-teal-5: #17616e; --color-neutral-1: #ffffff; --color-neutral-2: rgba(0, 0, 0, .08); --color-neutral-3: rgba(0, 0, 0, .15); --color-neutral-4: rgba(0, 0, 0, .45); --color-neutral-5: #000000; --color-primary: #2a7aac; --color-primary-hover: #ebf4fa; --color-danger: #d0451b; --color-danger-hover: #ab3916; --color-disabled: #a3a3a3; --text-small: .875rem; --text-medium: 1rem; --text-medium-large: 1.25rem; --text-large: 1.5rem; --text-x-large: 2rem; --text-xx-large: 3rem; --text-xxx-large: 4rem; --text-base: 1rem; --spacing-0: 0; --spacing-1: .25rem; --spacing-2: .5rem; --spacing-3: .75rem; --spacing-4: 1rem; --spacing-5: 1.5rem; --spacing-6: 2rem; --spacing-7: 3rem; --spacing-8: 4rem; --spacing-9: 5rem; --spacing-10: 6rem; --spacing-11: 15rem; --spacing-12: 22.5rem; }@utility btn{@apply font-bold transition border border-transparent text-neutral-1 px-5 py-3 rounded-3xl bg-blue-4 hover:bg-blue-3 data-[state="danger"]:bg-danger data-[state="danger"]:hover:bg-danger-hover data-[state="inverse"]:bg-neutral-1 data-[state="inverse"]:text-blue-3 data-[state="inverse"]:border-blue-3 data-[state="inverse"]:hover:bg-blue-2 data-[state="decolor"]:bg-gray-5 data-[state="decolor"]:hover:bg-gray-4;}
1
+ @theme{--color-*: initial; --text-*: initial; --spacing-*: initial;}@theme{ --color-gray-1: #f4f4f4; --color-gray-2: #e6e6e6; --color-gray-3: #a3a3a3; --color-gray-4: #777777; --color-gray-5: #454545; --color-blue-1: #ebf4fa; --color-blue-2: #cce3f2; --color-blue-3: #348ec7; --color-blue-4: #2a7aac; --color-blue-5: #246289; --color-indigo-1: #eef2f9; --color-indigo-2: #d2d8ec; --color-indigo-3: #5a71b9; --color-indigo-4: #465da5; --color-indigo-5: #3a4d88; --color-purple-1: #f1eef6; --color-purple-2: #ddd5e9; --color-purple-3: #8164af; --color-purple-4: #6d509b; --color-purple-5: #5a4280; --color-violet-1: #f5eef6; --color-violet-2: #e6d5ea; --color-violet-3: #9a55aa; --color-violet-4: #81488e; --color-violet-5: #693a73; --color-magenta-1: #f6eef4; --color-magenta-2: #ead5e3; --color-magenta-3: #aa558e; --color-magenta-4: #8f4777; --color-magenta-5: #743a61; --color-red-1: #fcede8; --color-red-2: #f8d2c7; --color-red-3: #e45a2f; --color-red-4: #d0451b; --color-red-5: #ab3916; --color-orange-1: #fcf2e8; --color-orange-2: #f8dfc6; --color-orange-3: #e3811c; --color-orange-4: #c86400; --color-orange-5: #9e5000; --color-green-1: #f5f9eb; --color-green-2: #e6f1cd; --color-green-3: #82a82f; --color-green-4: #698826; --color-green-5: #50681d; --color-jade-1: #eef7f1; --color-jade-2: #d4eadd; --color-jade-3: #4e9d6d; --color-jade-4: #40815a; --color-jade-5: #336647; --color-teal-1: #eaf8fb; --color-teal-2: #caeef4; --color-teal-3: #259cb2; --color-teal-4: #1e7e90; --color-teal-5: #17616e; --color-neutral-1: #ffffff; --color-neutral-2: rgba(0, 0, 0, .08); --color-neutral-3: rgba(0, 0, 0, .15); --color-neutral-4: rgba(0, 0, 0, .45); --color-neutral-5: #000000; --color-primary: #2a7aac; --color-primary-hover: #ebf4fa; --color-danger: #d0451b; --color-danger-hover: #ab3916; --color-disabled: #a3a3a3; --text-small: .875rem; --text-medium: 1rem; --text-medium-large: 1.25rem; --text-large: 1.5rem; --text-x-large: 2rem; --text-xx-large: 3rem; --text-xxx-large: 4rem; --text-base: 1rem; --spacing-0: 0; --spacing-1: .25rem; --spacing-2: .5rem; --spacing-3: .75rem; --spacing-4: 1rem; --spacing-5: 1.5rem; --spacing-6: 2rem; --spacing-7: 3rem; --spacing-8: 4rem; --spacing-9: 5rem; --spacing-10: 6rem; --spacing-11: 15rem; --spacing-12: 22.5rem; }@layer components{.btn{@apply transition cursor-pointer font-semibold px-[1.375rem] py-[.625rem] rounded-3xl disabled:opacity-50;}.btn-primary{@apply bg-blue-3 border-2 border-blue-3 leading-5 text-neutral-1 hover:border-blue-4 hover:bg-blue-4 disabled:border-blue-3 disabled:bg-blue-3;}.btn-primary.btn-danger{@apply border-red-3 bg-red-3 text-neutral-1 hover:border-red-4 hover:bg-red-4;}.btn-primary.btn-inverse{@apply bg-neutral-1 text-blue-4 hover:bg-blue-1 hover:border-blue-5 hover:text-blue-5;}.btn-primary.btn-decolor{@apply border-gray-5 bg-gray-5 text-neutral-1 hover:border-neutral-5 hover:bg-neutral-5;}.btn-secondary{@apply bg-neutral-1 border-2 border-blue-3 text-blue-4 hover:border-blue-4 hover:bg-blue-1 hover:text-blue-5;}.btn-secondary.btn-danger{@apply border-red-3 text-red-3 hover:border-red-4 hover:text-red-4 hover:bg-red-1;}.btn-secondary.btn-inverse{@apply border-neutral-1 text-neutral-1 bg-indigo-3 hover:bg-indigo-4;}.btn-secondary.btn-decolor{@apply text-gray-5 border-gray-5 hover:text-neutral-5 hover:border-neutral-5 hover:bg-gray-1;}.btn-tertiary{@apply px-0 py-3 text-blue-4 underline hover:text-blue-5;}.btn-tertiary.btn-danger{@apply text-red-4 hover:text-red-5;}.btn-tertiary.btn-inverse{@apply text-neutral-1 hover:text-gray-1;}.btn-tertiary.btn-decolor{@apply text-gray-5 hover:text-neutral-5;}}
package/package.json CHANGED
@@ -1,22 +1,16 @@
1
1
  {
2
2
  "name": "@digitalpromise/design",
3
3
  "private": false,
4
- "version": "1.0.1-next.2",
4
+ "version": "2.0.0",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
8
8
  "files": [
9
9
  "dist"
10
10
  ],
11
- "exports": {
12
- ".": {
13
- "types": "./dist/index.d.ts",
14
- "import": "./dist/index.js",
15
- "require": "./dist/index.cjs"
16
- }
17
- },
18
11
  "devDependencies": {
19
12
  "@chromatic-com/storybook": "^4.1.1",
13
+ "@eslint/js": "^9.35.0",
20
14
  "@storybook/addon-docs": "^9.1.5",
21
15
  "@storybook/addon-links": "^9.1.5",
22
16
  "@storybook/react-vite": "^9.1.5",
@@ -31,7 +25,6 @@
31
25
  "@vitejs/plugin-react-swc": "^4.0.1",
32
26
  "eslint": "^9.35.0",
33
27
  "eslint-plugin-react-hooks": "^5.2.0",
34
- "eslint-plugin-react-refresh": "^0.4.20",
35
28
  "eslint-plugin-storybook": "^9.1.5",
36
29
  "jsdom": "^26.1.0",
37
30
  "react": "^19.1.1",
@@ -40,6 +33,7 @@
40
33
  "style-dictionary": "^5.0.4",
41
34
  "tailwindcss": "^4.1.13",
42
35
  "typescript": "^5.9.2",
36
+ "typescript-eslint": "^8.43.0",
43
37
  "vite": "^7.1.5",
44
38
  "vitest": "^3.2.4"
45
39
  },
@@ -51,12 +45,12 @@
51
45
  "scripts": {
52
46
  "postinstall": "npm run build",
53
47
  "style-dictionary": "style-dictionary build",
54
- "postbuild": "style-dictionary build",
55
48
  "prestorybook": "style-dictionary build",
56
49
  "prebuild-storybook": "style-dictionary build",
50
+ "prebuild": "style-dictionary build",
57
51
  "dev": "vite",
58
52
  "build": "vite build && tsc",
59
- "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
53
+ "lint": "eslint ./src --ext ts,tsx",
60
54
  "preview": "vite preview",
61
55
  "storybook": "storybook dev -p 6006",
62
56
  "build-storybook": "storybook build",
package/dist/tokens.d.ts DELETED
@@ -1,134 +0,0 @@
1
- /**
2
- * Do not edit directly, this file was auto-generated.
3
- */
4
-
5
- export default tokens;
6
-
7
- declare interface DesignToken {
8
- $value?: any;
9
- $type?: string;
10
- $description?: string;
11
- name?: string;
12
- themeable?: boolean;
13
- attributes?: Record<string, unknown>;
14
- [key: string]: any;
15
- }
16
-
17
- declare const tokens: {
18
- color: {
19
- gray: {
20
- "1": DesignToken;
21
- "2": DesignToken;
22
- "3": DesignToken;
23
- "4": DesignToken;
24
- "5": DesignToken;
25
- };
26
- blue: {
27
- "1": DesignToken;
28
- "2": DesignToken;
29
- "3": DesignToken;
30
- "4": DesignToken;
31
- "5": DesignToken;
32
- };
33
- indigo: {
34
- "1": DesignToken;
35
- "2": DesignToken;
36
- "3": DesignToken;
37
- "4": DesignToken;
38
- "5": DesignToken;
39
- };
40
- purple: {
41
- "1": DesignToken;
42
- "2": DesignToken;
43
- "3": DesignToken;
44
- "4": DesignToken;
45
- "5": DesignToken;
46
- };
47
- violet: {
48
- "1": DesignToken;
49
- "2": DesignToken;
50
- "3": DesignToken;
51
- "4": DesignToken;
52
- "5": DesignToken;
53
- };
54
- magenta: {
55
- "1": DesignToken;
56
- "2": DesignToken;
57
- "3": DesignToken;
58
- "4": DesignToken;
59
- "5": DesignToken;
60
- };
61
- red: {
62
- "1": DesignToken;
63
- "2": DesignToken;
64
- "3": DesignToken;
65
- "4": DesignToken;
66
- "5": DesignToken;
67
- };
68
- orange: {
69
- "1": DesignToken;
70
- "2": DesignToken;
71
- "3": DesignToken;
72
- "4": DesignToken;
73
- "5": DesignToken;
74
- };
75
- green: {
76
- "1": DesignToken;
77
- "2": DesignToken;
78
- "3": DesignToken;
79
- "4": DesignToken;
80
- "5": DesignToken;
81
- };
82
- jade: {
83
- "1": DesignToken;
84
- "2": DesignToken;
85
- "3": DesignToken;
86
- "4": DesignToken;
87
- "5": DesignToken;
88
- };
89
- teal: {
90
- "1": DesignToken;
91
- "2": DesignToken;
92
- "3": DesignToken;
93
- "4": DesignToken;
94
- "5": DesignToken;
95
- };
96
- neutral: {
97
- "1": DesignToken;
98
- "2": DesignToken;
99
- "3": DesignToken;
100
- "4": DesignToken;
101
- "5": DesignToken;
102
- };
103
- primary: DesignToken;
104
- "primary-hover": DesignToken;
105
- danger: DesignToken;
106
- "danger-hover": DesignToken;
107
- disabled: DesignToken;
108
- };
109
- text: {
110
- small: DesignToken;
111
- medium: DesignToken;
112
- "medium-large": DesignToken;
113
- large: DesignToken;
114
- "x-large": DesignToken;
115
- "xx-large": DesignToken;
116
- "xxx-large": DesignToken;
117
- base: DesignToken;
118
- };
119
- spacing: {
120
- "0": DesignToken;
121
- "1": DesignToken;
122
- "2": DesignToken;
123
- "3": DesignToken;
124
- "4": DesignToken;
125
- "5": DesignToken;
126
- "6": DesignToken;
127
- "7": DesignToken;
128
- "8": DesignToken;
129
- "9": DesignToken;
130
- "10": DesignToken;
131
- "11": DesignToken;
132
- "12": DesignToken;
133
- };
134
- };