@yuno-payments/dashboard-design-system 2.3.11 → 2.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 +78 -0
- package/dist/components/atoms/icon/icon-list.d.ts +5 -0
- package/dist/components/atoms/icon/icon-list.js +206 -196
- package/dist/components/atoms/index.d.ts +0 -17
- package/dist/components/{atoms → molecules}/checkbox/checkbox.js +1 -1
- package/dist/components/{atoms → molecules}/dots-menu/dots-menu.js +4 -4
- package/dist/components/{atoms → molecules}/field/field.d.ts +2 -2
- package/dist/components/{atoms → molecules}/field/field.js +3 -3
- package/dist/components/molecules/index.d.ts +13 -0
- package/dist/components/{atoms → molecules}/multi-values-field/multi-values-field.js +2 -2
- package/dist/components/{atoms → molecules}/nav-link/nav-link.js +1 -1
- package/dist/components/molecules/nav-tabs/nav-tabs.js +1 -1
- package/dist/components/{atoms → molecules}/password-field/password-field.d.ts +1 -1
- package/dist/components/{atoms → molecules}/password-field/password-field.js +2 -2
- package/dist/components/{atoms → molecules}/radio-group/radio-group-option.js +1 -1
- package/dist/components/{atoms → molecules}/search-field/search-field.js +2 -2
- package/dist/components/{atoms → molecules}/select/search-select.js +2 -2
- package/dist/components/{atoms → molecules}/select/select.js +2 -2
- package/dist/components/{atoms → molecules}/switch/switch.js +1 -1
- package/dist/components/{atoms → molecules}/textarea/textarea.js +1 -1
- package/dist/components/{atoms → molecules}/time-picker/time-picker.js +1 -1
- package/dist/components/{atoms → organisms}/combobox/combobox.js +5 -5
- package/dist/components/organisms/data-table/components/dialogs/data-table-manage-columns-dialog.js +2 -2
- package/dist/components/organisms/data-table/hooks/use-data-table-columns.js +1 -1
- package/dist/components/organisms/dialog/dialog.d.ts +5 -0
- package/dist/components/organisms/dialog/dialog.js +90 -80
- package/dist/components/{atoms → organisms}/filter/filter-date-range.js +3 -3
- package/dist/components/{atoms → organisms}/filter/filter-multi-input.js +1 -1
- package/dist/components/{atoms → organisms}/filter/filter.js +3 -3
- package/dist/components/{atoms → organisms}/filter-dropdown/filter-dropdown.d.ts +1 -1
- package/dist/components/{atoms → organisms}/filter-dropdown/filter-dropdown.js +1 -1
- package/dist/components/organisms/index.d.ts +4 -0
- package/dist/components/organisms/transfer-list/transfer-list-box.js +1 -1
- package/dist/index.esm.min.js +17993 -17824
- package/dist/index.js +21 -21
- package/dist/index.umd.min.js +29 -29
- package/dist/node_modules/@phosphor-icons/react/dist/csr/ArrowSquareOut.es.js +8 -0
- package/dist/node_modules/@phosphor-icons/react/dist/csr/Lifebuoy.es.js +8 -0
- package/dist/node_modules/@phosphor-icons/react/dist/csr/NotePencil.es.js +8 -0
- package/dist/node_modules/@phosphor-icons/react/dist/csr/SquareHalf.es.js +8 -0
- package/dist/node_modules/@phosphor-icons/react/dist/csr/SquareHalfBottom.es.js +8 -0
- package/dist/node_modules/@phosphor-icons/react/dist/defs/ArrowSquareOut.es.js +36 -0
- package/dist/node_modules/@phosphor-icons/react/dist/defs/Lifebuoy.es.js +36 -0
- package/dist/node_modules/@phosphor-icons/react/dist/defs/NotePencil.es.js +30 -0
- package/dist/node_modules/@phosphor-icons/react/dist/defs/SquareHalf.es.js +36 -0
- package/dist/node_modules/@phosphor-icons/react/dist/defs/SquareHalfBottom.es.js +30 -0
- package/dist/theme.css +17 -4
- package/dist/tokens.css +15 -0
- package/package.json +4 -4
- package/registry/components-registry.json +1916 -1916
- /package/dist/components/{atoms → molecules}/checkbox/checkbox.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/checkbox/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/dots-menu/dots-menu.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/dots-menu/dots-menu.types.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/dots-menu/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/field/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/multi-values-field/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/multi-values-field/multi-values-field.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/multi-values-field/multi-values-field.types.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/nav-link/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/nav-link/nav-link.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/otp-field/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/otp-field/otp-field.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/otp-field/otp-field.js +0 -0
- /package/dist/components/{atoms → molecules}/password-field/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/radio-group/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/radio-group/radio-group-option.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/radio-group/radio-group.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/radio-group/radio-group.js +0 -0
- /package/dist/components/{atoms → molecules}/search-field/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/search-field/search-field.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/search-field/search-field.types.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/select/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/select/search-select.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/select/select.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/switch/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/switch/switch.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/textarea/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/textarea/textarea.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/time-picker/index.d.ts +0 -0
- /package/dist/components/{atoms → molecules}/time-picker/time-picker.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/combobox/combobox.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/combobox/index.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/combobox/types.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter/filter-date-range.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter/filter-multi-input.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter/filter-translations.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter/filter-translations.js +0 -0
- /package/dist/components/{atoms → organisms}/filter/filter.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter/index.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/filter-dropdown/index.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/multi-select/index.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/multi-select/multi-select.d.ts +0 -0
- /package/dist/components/{atoms → organisms}/multi-select/multi-select.js +0 -0
package/README.md
CHANGED
|
@@ -47,6 +47,84 @@ All components use **Tailwind CSS** utility classes for styling. Developers must
|
|
|
47
47
|
|
|
48
48
|
**📚 [Tailwind CSS Documentation](https://tailwindcss.com/docs/installation/using-vite)**
|
|
49
49
|
|
|
50
|
+
## CSS Stylesheets — Integration Guide
|
|
51
|
+
|
|
52
|
+
The design system exports three CSS files for use by consumer MFEs. Each one serves a different integration pattern.
|
|
53
|
+
|
|
54
|
+
### Exported files
|
|
55
|
+
|
|
56
|
+
| Import path | Description |
|
|
57
|
+
|-------------|-------------|
|
|
58
|
+
| `@yuno-payments/dashboard-design-system/tokens.css` | **Self-contained stylesheet.** Includes Tailwind CSS, the full color/font/radius/animation token set, light/dark semantic tokens, and the Tailwind utility bridge. **This is what most MFEs should use.** |
|
|
59
|
+
| `@yuno-payments/dashboard-design-system/theme.css` | **Theme tokens only.** A raw `@theme` block for consumers that run their own Tailwind build and want to merge DS tokens into their pipeline. No Tailwind import, no base styles. |
|
|
60
|
+
| `@yuno-payments/dashboard-design-system/styles.css` | **Component overrides & global utilities.** Compiled from `src/global.css`. Includes everything in `tokens.css` plus base body styles, z-index layers, toast/notification styling, RTL support, and DataTable padding. |
|
|
61
|
+
|
|
62
|
+
### Usage patterns
|
|
63
|
+
|
|
64
|
+
**Pattern A — Most MFEs** (no own Tailwind build):
|
|
65
|
+
|
|
66
|
+
```css
|
|
67
|
+
/* src/index.css */
|
|
68
|
+
@import '@yuno-payments/dashboard-design-system/tokens.css';
|
|
69
|
+
|
|
70
|
+
/* Your local styles below */
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
One import. Done. Tailwind utilities like `bg-background`, `text-foreground`, `border-border` work out of the box.
|
|
74
|
+
|
|
75
|
+
**Pattern B — Container MFE** (own Tailwind build):
|
|
76
|
+
|
|
77
|
+
```css
|
|
78
|
+
/* src/index.css */
|
|
79
|
+
@import 'tailwindcss/theme';
|
|
80
|
+
@import '@yuno-payments/dashboard-design-system/theme.css';
|
|
81
|
+
@import '@yuno-payments/dashboard-design-system/styles.css';
|
|
82
|
+
@import 'tailwindcss/utilities';
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
`theme.css` merges DS tokens into the consumer's Tailwind config. `styles.css` provides the component-level overrides (toasts, z-index, RTL, DataTable, etc.).
|
|
86
|
+
|
|
87
|
+
### What each file contains
|
|
88
|
+
|
|
89
|
+
<details>
|
|
90
|
+
<summary><strong>tokens.css</strong> (source: <code>src/tokens.css</code>)</summary>
|
|
91
|
+
|
|
92
|
+
- `@import "tailwindcss"`
|
|
93
|
+
- `@custom-variant dark` (class-based dark mode)
|
|
94
|
+
- **Static `@theme` block**: font-sans, border-radius, 8 color families × 10 shades (RGB), opacity variants for Badge, animation keyframes
|
|
95
|
+
- **Dynamic semantic tokens** (`:root` / `.dark`): background, foreground, card, popover, primary, secondary, muted, accent, destructive, border, input, surface, ring, success, warning, info
|
|
96
|
+
- **Base override**: `border-color: var(--border)` on all elements
|
|
97
|
+
- **`@theme inline` bridge**: maps CSS vars to `--color-*` so Tailwind generates utilities
|
|
98
|
+
</details>
|
|
99
|
+
|
|
100
|
+
<details>
|
|
101
|
+
<summary><strong>theme.css</strong> (source: <code>src/theme.css</code>)</summary>
|
|
102
|
+
|
|
103
|
+
- A single `@theme` block with the same static tokens as `tokens.css` (fonts, radii, colors, animations)
|
|
104
|
+
- No Tailwind import, no `:root`/`.dark`, no bridge — purely for native `@theme` merging
|
|
105
|
+
</details>
|
|
106
|
+
|
|
107
|
+
<details>
|
|
108
|
+
<summary><strong>styles.css</strong> (source: <code>src/global.css</code>, compiled to <code>dist/index.css</code>)</summary>
|
|
109
|
+
|
|
110
|
+
- Everything in `tokens.css` plus:
|
|
111
|
+
- `@import "tw-animate-css"` (animation plugin)
|
|
112
|
+
- Base body styles: `bg-background text-foreground`, cursor pointer on buttons
|
|
113
|
+
- Z-index utilities: `z-sheet` (1000), `z-dialog` (1000), `z-popover` (10000), `z-tooltip` (100000)
|
|
114
|
+
- `.bg-input` light/dark override
|
|
115
|
+
- Time picker icon positioning fix
|
|
116
|
+
- Notification toast colored borders (success, error, warning, info)
|
|
117
|
+
- Sonner toast icon colors by `data-type`
|
|
118
|
+
- RTL directional icon mirroring (`.rtl-mirror`)
|
|
119
|
+
- DataTable first/last column padding (`.yuno-data-table`)
|
|
120
|
+
</details>
|
|
121
|
+
|
|
122
|
+
### Keeping files in sync
|
|
123
|
+
|
|
124
|
+
The `@theme` block in `tokens.css` and `global.css` must mirror the one in `theme.css`. When adding or changing tokens, update all three source files.
|
|
125
|
+
|
|
126
|
+
---
|
|
127
|
+
|
|
50
128
|
## Vendors Folder
|
|
51
129
|
|
|
52
130
|
The `src/vendor/` folder contains the **base components** that we use to create our custom components:
|
|
@@ -213,6 +213,11 @@ declare const IconList: {
|
|
|
213
213
|
FilePng: import('@phosphor-icons/react').Icon;
|
|
214
214
|
FileJpg: import('@phosphor-icons/react').Icon;
|
|
215
215
|
FilePpt: import('@phosphor-icons/react').Icon;
|
|
216
|
+
ArrowSquareOut: import('@phosphor-icons/react').Icon;
|
|
217
|
+
SquareHalf: import('@phosphor-icons/react').Icon;
|
|
218
|
+
SquareHalfBottom: import('@phosphor-icons/react').Icon;
|
|
219
|
+
NotePencil: import('@phosphor-icons/react').Icon;
|
|
220
|
+
Lifebuoy: import('@phosphor-icons/react').Icon;
|
|
216
221
|
};
|
|
217
222
|
export type IconName = Exclude<keyof typeof IconList, "Icon" | "IconProps" | "IconWeight" | "IconContext">;
|
|
218
223
|
export { IconList };
|