@artemdev04/design-system 0.2.1 → 0.4.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/README.md +94 -94
- package/dist/design-system.css +1 -1
- package/dist/index.d.ts +52 -1
- package/dist/index.mjs +497 -394
- package/dist/index.umd.js +1 -1
- package/package.json +10 -3
- package/tailwind.preset.d.ts +4 -0
- package/tailwind.preset.js +75 -74
package/README.md
CHANGED
|
@@ -1,94 +1,94 @@
|
|
|
1
|
-
# @artemdev04/design-system
|
|
2
|
-
|
|
3
|
-
A modern, accessible, and strongly typed React Design System built with **Vite**, **TypeScript**, and **Storybook**.
|
|
4
|
-
|
|
5
|
-

|
|
6
|
-

|
|
7
|
-
|
|
8
|
-
### 🚀 Features
|
|
9
|
-
|
|
10
|
-
- ⚛️ **React 19+** ready (compatible with React 18).
|
|
11
|
-
- 📘 **TypeScript** first approach with full type definitions.
|
|
12
|
-
- ⚡ **Vite** powered build for blazing fast performance.
|
|
13
|
-
- 🎨 **Storybook** included for component isolation and documentation.
|
|
14
|
-
- 🌳 **Tree-shakable** exports (ESM & UMD support).
|
|
15
|
-
|
|
16
|
-
### 📦 Installation
|
|
17
|
-
|
|
18
|
-
```bash
|
|
19
|
-
# Using npm
|
|
20
|
-
npm install @artemdev04/design-system
|
|
21
|
-
|
|
22
|
-
# Using yarn
|
|
23
|
-
yarn add @artemdev04/design-system
|
|
24
|
-
|
|
25
|
-
# Using pnpm
|
|
26
|
-
pnpm add @artemdev04/design-system
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
### 🔨 Usage
|
|
30
|
-
|
|
31
|
-
Import components directly into your React application:
|
|
32
|
-
|
|
33
|
-
```tsx
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
export default
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
### 🛠 Development
|
|
74
|
-
|
|
75
|
-
Clone the repository and install dependencies:
|
|
76
|
-
|
|
77
|
-
```bash
|
|
78
|
-
git clone [https://github.com/azakhardev/design-system.git](https://github.com/azakhardev/design-system.git)
|
|
79
|
-
cd design-system
|
|
80
|
-
npm install
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
### Commands
|
|
84
|
-
|
|
85
|
-
| **Command** | **Description** |
|
|
86
|
-
| ------------------- | -------------------------------------------------- |
|
|
87
|
-
| `npm run dev` | Starts Vite in development mode. |
|
|
88
|
-
| `npm run storybook` | Starts the Storybook documentation server locally. |
|
|
89
|
-
| `npm run build` | Builds the library for production (`dist` folder). |
|
|
90
|
-
| `npm run lint` | Runs ESLint to check code quality. |
|
|
91
|
-
|
|
92
|
-
### Concepts in Figma
|
|
93
|
-
|
|
94
|
-
Link to figma: [Artem's Design System](https://www.figma.com/design/NRVDKidwFggutZuAZS52ek/DesignSystem?node-id=1-3&t=ZpQ49tFkM3Rlm043-1)
|
|
1
|
+
# @artemdev04/design-system
|
|
2
|
+
|
|
3
|
+
A modern, accessible, and strongly typed React Design System built with **Vite**, **TypeScript**, and **Storybook**.
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+

|
|
7
|
+
|
|
8
|
+
### 🚀 Features
|
|
9
|
+
|
|
10
|
+
- ⚛️ **React 19+** ready (compatible with React 18).
|
|
11
|
+
- 📘 **TypeScript** first approach with full type definitions.
|
|
12
|
+
- ⚡ **Vite** powered build for blazing fast performance.
|
|
13
|
+
- 🎨 **Storybook** included for component isolation and documentation.
|
|
14
|
+
- 🌳 **Tree-shakable** exports (ESM & UMD support).
|
|
15
|
+
|
|
16
|
+
### 📦 Installation
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
# Using npm
|
|
20
|
+
npm install @artemdev04/design-system
|
|
21
|
+
|
|
22
|
+
# Using yarn
|
|
23
|
+
yarn add @artemdev04/design-system
|
|
24
|
+
|
|
25
|
+
# Using pnpm
|
|
26
|
+
pnpm add @artemdev04/design-system
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
### 🔨 Usage
|
|
30
|
+
|
|
31
|
+
Import components directly into your React application:
|
|
32
|
+
|
|
33
|
+
```tsx
|
|
34
|
+
//Your imports
|
|
35
|
+
|
|
36
|
+
//!IMPORTANT: Import my Stylesheet
|
|
37
|
+
import "@artemdev04/design-system/style.css";
|
|
38
|
+
//And now you are ready to use my comopnents
|
|
39
|
+
import { Button } from "@artemdev04/design-system";
|
|
40
|
+
|
|
41
|
+
function App() {
|
|
42
|
+
return (
|
|
43
|
+
<Button variant="primary" onClick={() => console.log("Clicked!")}>
|
|
44
|
+
Click me
|
|
45
|
+
</Button>
|
|
46
|
+
);
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
#### 🖌️ Tailwind Styles Usage
|
|
51
|
+
|
|
52
|
+
To use tailwind variables edit your `tailwind.config` file:
|
|
53
|
+
|
|
54
|
+
```js
|
|
55
|
+
/** @type {import('tailwindcss').Config} **/
|
|
56
|
+
|
|
57
|
+
//Import my tailwind preset
|
|
58
|
+
import designSystemPreset from "@artemdev04/design-system/tailwind.preset";
|
|
59
|
+
|
|
60
|
+
export default {
|
|
61
|
+
//Insert it into the presets array
|
|
62
|
+
presets: [designSystemPreset],
|
|
63
|
+
content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx}"],
|
|
64
|
+
theme: {
|
|
65
|
+
extend: {
|
|
66
|
+
//Feel free to use your own styles
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
plugins: [],
|
|
70
|
+
};
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
### 🛠 Development
|
|
74
|
+
|
|
75
|
+
Clone the repository and install dependencies:
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
git clone [https://github.com/azakhardev/design-system.git](https://github.com/azakhardev/design-system.git)
|
|
79
|
+
cd design-system
|
|
80
|
+
npm install
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Commands
|
|
84
|
+
|
|
85
|
+
| **Command** | **Description** |
|
|
86
|
+
| ------------------- | -------------------------------------------------- |
|
|
87
|
+
| `npm run dev` | Starts Vite in development mode. |
|
|
88
|
+
| `npm run storybook` | Starts the Storybook documentation server locally. |
|
|
89
|
+
| `npm run build` | Builds the library for production (`dist` folder). |
|
|
90
|
+
| `npm run lint` | Runs ESLint to check code quality. |
|
|
91
|
+
|
|
92
|
+
### Concepts in Figma
|
|
93
|
+
|
|
94
|
+
Link to figma: [Artem's Design System](https://www.figma.com/design/NRVDKidwFggutZuAZS52ek/DesignSystem?node-id=1-3&t=ZpQ49tFkM3Rlm043-1)
|
package/dist/design-system.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:Inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:JetBrains Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}body{background-color:var(--app-background);color:var(--text-main);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.2s}.static{position:static}.m-0{margin:0}.flex{display:flex}.grid{display:grid}.w-full{width:100%}.max-w-\[500px\]{max-width:500px}.cursor-pointer{cursor:pointer}.flex-col{flex-direction:column}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.overflow-hidden{overflow:hidden}.rounded{border-radius:.25rem}.rounded-xl{border-radius:.75rem}.border{border-width:1px}.border-2{border-width:2px}.border-dashed{border-style:dashed}.border-border{border-color:var(--border-main)}.border-slate-300{--tw-border-opacity: 1;border-color:rgb(203 213 225 / var(--tw-border-opacity, 1))}.bg-background{background-color:var(--app-background)}.bg-primary{background-color:var(--primary)}.bg-surface{background-color:var(--surface)}.p-4{padding:1rem}.p-8{padding:2rem}.px-3{padding-left:.75rem;padding-right:.75rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.text-justify{text-align:justify}.font-sans{font-family:Inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.italic{font-style:italic}.leading-normal{line-height:1.5}.text-error-text{color:var(--error-text)}.text-info-text{color:var(--info-text)}.text-on-primary{color:var(--on-primary)}.text-success-text{color:var(--success-text)}.text-text{color:var(--text-main)}.text-text-secondary{color:var(--text-secondary)}.text-warning-text{color:var(--warning-text)}.underline{text-decoration-line:underline}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}:root{--app-background: #f8fafc;--surface: #ffffff;--surface-secondary: #f1f5f9;--primary: #0ea5e9;--primary-focus: #0284c7;--secondary: #6366f1;--secondary-focus: #4f46e5;--text-main: #0f172a;--text-secondary: #64748b;--border-main: #e2e8f0;--border-subtle: #f1f5f9;--border-strong: #cbd5e1;--input-background: #ffffff;--accent: #0d9488;--overlay: #0f172a;--on-primary: #ffffff;--on-secondary: #ffffff;--on-surface: #0f172a;--disabled-surface: #e2e8f0;--disabled-text: #94a3b8;--disabled-border: #cbd5e1;--info-surface: #f0f9ff;--info-border: #bae6fd;--info-text: #075985;--info-main: #0ea5e9;--success-surface: #ecfdf5;--success-border: #a7f3d0;--success-text: #065f46;--success-main: #10b981;--warning-surface: #fffbeb;--warning-border: #fde68a;--warning-text: #92400e;--warning-main: #f59e0b;--error-surface: #fef2f2;--error-border: #fecaca;--error-text: #991b1b;--error-main: #ef4444}.dark{--app-background: #0b1120;--surface: #1e293b;--surface-secondary: #334155;--primary: #38bdf8;--primary-focus: #7dd3fc;--secondary: #818cf8;--secondary-focus: #a5b4fc;--text-main: #f8fafc;--text-secondary: #94a3b8;--border-main: #334155;--border-subtle: #1e293b;--border-strong: #475569;--input-background: #0f172a;--accent: #5eead4;--overlay: #0f172a;--on-primary: #0f172a;--on-secondary: #0f172a;--on-surface: #f8fafc;--disabled-surface: #1e293b;--disabled-text: #475569;--disabled-border: #334155;--info-surface: #082f49;--info-border: #075985;--info-text: #bae6fd;--info-main: #38bdf8;--success-surface: #064e3b;--success-border: #065f46;--success-text: #a7f3d0;--success-main: #34d399;--warning-surface: #451a03;--warning-border: #92400e;--warning-text: #fde68a;--warning-main: #fbbf24;--error-surface: #450a0a;--error-border: #991b1b;--error-text: #fecaca;--error-main: #f87171}.hover\:bg-primary-focus:hover{background-color:var(--primary-focus)}.hover\:underline:hover{text-decoration-line:underline}@media(min-width:768px){.md\:text-3xl{font-size:1.875rem;line-height:2.25rem}.md\:text-4xl{font-size:2.25rem;line-height:2.5rem}.md\:text-5xl{font-size:3rem;line-height:1}}@media(prefers-color-scheme:dark){.dark\:text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}}
|
|
1
|
+
*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:Inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:JetBrains Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}body{background-color:var(--app-background);color:var(--text-main);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.2s}.container{width:100%}@media(min-width:640px){.container{max-width:640px}}@media(min-width:768px){.container{max-width:768px}}@media(min-width:1024px){.container{max-width:1024px}}@media(min-width:1280px){.container{max-width:1280px}}@media(min-width:1536px){.container{max-width:1536px}}.m-0{margin:0}.mt-2{margin-top:.5rem}.inline{display:inline}.flex{display:flex}.grid{display:grid}.h-\[1px\]{height:1px}.h-\[2px\]{height:2px}.w-\[400px\]{width:400px}.w-\[500px\]{width:500px}.w-full{width:100%}.max-w-\[400px\]{max-width:400px}.max-w-\[500px\]{max-width:500px}.cursor-pointer{cursor:pointer}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.rounded{border-radius:.25rem}.rounded-full{border-radius:9999px}.rounded-md{border-radius:.375rem}.border{border-width:1px}.border-2{border-width:2px}.border-dashed{border-style:dashed}.border-border{border-color:var(--border-main)}.border-error-border{border-color:var(--error-border)}.border-info{border-color:var(--info-main)}.border-slate-300{--tw-border-opacity: 1;border-color:rgb(203 213 225 / var(--tw-border-opacity, 1))}.border-success-border{border-color:var(--success-border)}.border-transparent{border-color:transparent}.bg-background{background-color:var(--app-background)}.bg-border{background-color:var(--border-main)}.bg-border-strong{background-color:var(--border-strong)}.bg-error{background-color:var(--error-main)}.bg-primary{background-color:var(--primary)}.bg-secondary{background-color:var(--secondary)}.bg-success{background-color:var(--success-main)}.bg-surface{background-color:var(--surface)}.p-4{padding:1rem}.p-8{padding:2rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pt-0{padding-top:0}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.text-justify{text-align:justify}.font-sans{font-family:Inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.italic{font-style:italic}.leading-none{line-height:1}.leading-normal{line-height:1.5}.tracking-tight{letter-spacing:-.025em}.text-error-text{color:var(--error-text)}.text-info{color:var(--info-main)}.text-info-text{color:var(--info-text)}.text-on-primary{color:var(--on-primary)}.text-success-text{color:var(--success-text)}.text-text{color:var(--text-main)}.text-text-secondary{color:var(--text-secondary)}.text-warning-text{color:var(--warning-text)}.underline{text-decoration-line:underline}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline{outline-style:solid}.ring{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}:root{--app-background: #f8fafc;--surface: #ffffff;--surface-secondary: #f1f5f9;--primary: #0ea5e9;--primary-focus: #0284c7;--secondary: #6366f1;--secondary-focus: #4f46e5;--text-main: #0f172a;--text-secondary: #64748b;--border-main: #e2e8f0;--border-subtle: #f1f5f9;--border-strong: #cbd5e1;--input-background: #ffffff;--accent: #0d9488;--overlay: #0f172a;--on-primary: #ffffff;--on-secondary: #ffffff;--on-surface: #0f172a;--disabled-surface: #e2e8f0;--disabled-text: #94a3b8;--disabled-border: #cbd5e1;--info-surface: #f0f9ff;--info-border: #bae6fd;--info-text: #075985;--info-main: #0ea5e9;--success-surface: #ecfdf5;--success-border: #a7f3d0;--success-text: #065f46;--success-main: #10b981;--warning-surface: #fffbeb;--warning-border: #fde68a;--warning-text: #92400e;--warning-main: #f59e0b;--error-surface: #fef2f2;--error-border: #fecaca;--error-text: #991b1b;--error-main: #ef4444}.dark{--app-background: #0b1120;--surface: #1e293b;--surface-secondary: #334155;--primary: #38bdf8;--primary-focus: #7dd3fc;--secondary: #818cf8;--secondary-focus: #a5b4fc;--text-main: #f8fafc;--text-secondary: #94a3b8;--border-main: #334155;--border-subtle: #1e293b;--border-strong: #475569;--input-background: #0f172a;--accent: #5eead4;--overlay: #0f172a;--on-primary: #0f172a;--on-secondary: #0f172a;--on-surface: #f8fafc;--disabled-surface: #1e293b;--disabled-text: #475569;--disabled-border: #334155;--info-surface: #082f49;--info-border: #075985;--info-text: #bae6fd;--info-main: #38bdf8;--success-surface: #064e3b;--success-border: #065f46;--success-text: #a7f3d0;--success-main: #34d399;--warning-surface: #451a03;--warning-border: #92400e;--warning-text: #fde68a;--warning-main: #fbbf24;--error-surface: #450a0a;--error-border: #991b1b;--error-text: #fecaca;--error-main: #f87171}.hover\:scale-\[1\.10\]:hover{--tw-scale-x: 1.1;--tw-scale-y: 1.1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:bg-info-surface:hover{background-color:var(--info-surface)}.hover\:bg-primary-focus:hover{background-color:var(--primary-focus)}.hover\:bg-secondary-focus:hover{background-color:var(--secondary-focus)}.hover\:underline:hover{text-decoration-line:underline}.active\:scale-\[0\.95\]:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\:cursor-default:disabled{cursor:default}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:border-none:disabled{border-style:none}.disabled\:border-disabled-border:disabled{border-color:var(--disabled-border)}.disabled\:bg-disabled-surface:disabled{background-color:var(--disabled-surface)}.disabled\:bg-transparent:disabled{background-color:transparent}.disabled\:text-disabled-text:disabled{color:var(--disabled-text)}.disabled\:hover\:scale-100:hover:disabled{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\:active\:scale-100:active:disabled{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.dark\:border-2:is(.dark *){border-width:2px}.dark\:border-error:is(.dark *){border-color:var(--error-main)}.dark\:bg-transparent:is(.dark *){background-color:transparent}.dark\:font-bold:is(.dark *){font-weight:700}.dark\:text-error:is(.dark *){color:var(--error-main)}.dark\:text-slate-400:is(.dark *){--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.dark\:disabled\:border-disabled-border:disabled:is(.dark *){border-color:var(--disabled-border)}.dark\:disabled\:text-disabled-text:disabled:is(.dark *){color:var(--disabled-text)}@media(min-width:768px){.md\:text-3xl{font-size:1.875rem;line-height:2.25rem}.md\:text-4xl{font-size:2.25rem;line-height:2.5rem}.md\:text-5xl{font-size:3rem;line-height:1}}@property --angle{syntax: "<angle>"; initial-value: 0deg; inherits: false;}._animatedButton_10ydq_7{position:relative;isolation:isolate;background:transparent}._animatedButton_10ydq_7:before{content:"";position:absolute;top:-2px;right:-2px;bottom:-2px;left:-2px;z-index:-2;background:conic-gradient(from var(--angle),blue,red,blue);animation:3s _spin_10ydq_1 linear infinite;border-radius:inherit;filter:blur(.2rem)}._animatedButton_10ydq_7:after{content:"";position:absolute;top:0;right:0;bottom:0;left:0;z-index:-1;background:var(--surface);border-radius:inherit}._animatedButton_10ydq_7:hover:after{background:var(--surface-secondary)}._animatedButton_10ydq_7:disabled:before,._animatedButton_10ydq_7:disabled:after{display:none}._animatedButton_10ydq_7:disabled{background:var(--disabled-surface);color:var(--disabled-text);border:2px solid var(--disabled-border, transparent);transform:none}@keyframes _spin_10ydq_1{0%{--angle: 0deg}to{--angle: 360deg}}
|
package/dist/index.d.ts
CHANGED
|
@@ -1 +1,52 @@
|
|
|
1
|
-
|
|
1
|
+
import { ClassProp } from 'class-variance-authority/types';
|
|
2
|
+
import { default as default_2 } from 'react';
|
|
3
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
4
|
+
import * as React_2 from 'react';
|
|
5
|
+
import { RefAttributes } from 'react';
|
|
6
|
+
import { VariantProps } from 'class-variance-authority';
|
|
7
|
+
|
|
8
|
+
export declare const Button: ForwardRefExoticComponent<Omit<ButtonProps, "ref"> & RefAttributes<HTMLButtonElement>>;
|
|
9
|
+
|
|
10
|
+
export declare interface ButtonProps extends React.ComponentProps<"button">, ButtonVariants {
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
declare type ButtonVariants = VariantProps<typeof buttonVariants>;
|
|
14
|
+
|
|
15
|
+
declare const buttonVariants: (props?: ({
|
|
16
|
+
variant?: "primary" | "secondary" | "danger" | "confirm" | "info" | "ghost" | "animated" | null | undefined;
|
|
17
|
+
} & ClassProp) | undefined) => string;
|
|
18
|
+
|
|
19
|
+
export declare const Card: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLDivElement> & React_2.RefAttributes<HTMLDivElement>>;
|
|
20
|
+
|
|
21
|
+
export declare const CardContent: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLDivElement> & React_2.RefAttributes<HTMLDivElement>>;
|
|
22
|
+
|
|
23
|
+
export declare const CardDescription: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLParagraphElement> & React_2.RefAttributes<HTMLParagraphElement>>;
|
|
24
|
+
|
|
25
|
+
export declare const CardFooter: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLDivElement> & React_2.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
|
|
27
|
+
export declare const CardHeader: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLDivElement> & React_2.RefAttributes<HTMLDivElement>>;
|
|
28
|
+
|
|
29
|
+
export declare const CardTitle: React_2.ForwardRefExoticComponent<React_2.HTMLAttributes<HTMLHeadingElement> & React_2.RefAttributes<HTMLParagraphElement>>;
|
|
30
|
+
|
|
31
|
+
declare const Text_2: default_2.ForwardRefExoticComponent<Omit<TextProps<default_2.ElementType<any, keyof default_2.JSX.IntrinsicElements>>, "ref"> & default_2.RefAttributes<any>>;
|
|
32
|
+
export { Text_2 as Text }
|
|
33
|
+
|
|
34
|
+
export declare type TextProps<C extends default_2.ElementType> = {
|
|
35
|
+
as?: C;
|
|
36
|
+
className?: string;
|
|
37
|
+
children?: default_2.ReactNode;
|
|
38
|
+
} & TextVariantsProps & //extends props of the CVA Variants, so developer cant use unsupported variants
|
|
39
|
+
default_2.ComponentPropsWithoutRef<C>;
|
|
40
|
+
|
|
41
|
+
declare const textVariants: (props?: ({
|
|
42
|
+
size?: "base" | "xs" | "sm" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | null | undefined;
|
|
43
|
+
weight?: "bold" | "normal" | "medium" | "semibold" | null | undefined;
|
|
44
|
+
color?: "info" | "default" | "muted" | "success" | "error" | "warning" | null | undefined;
|
|
45
|
+
align?: "center" | "left" | "right" | "justify" | null | undefined;
|
|
46
|
+
italic?: boolean | null | undefined;
|
|
47
|
+
unfrtline?: boolean | "ture" | null | undefined;
|
|
48
|
+
} & ClassProp) | undefined) => string;
|
|
49
|
+
|
|
50
|
+
declare type TextVariantsProps = VariantProps<typeof textVariants>;
|
|
51
|
+
|
|
52
|
+
export { }
|