@neetechs/ui 0.0.1 → 0.0.3
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/README.md +10 -0
- package/dist/ai/ai-action-button/ai-action-button.css +269 -269
- package/dist/ai/ai-approval-card/ai-approval-card.css +320 -320
- package/dist/ai/ai-conversation-panel/ai-conversation-panel.css +403 -403
- package/dist/ai/ai-prompt-input/ai-prompt-input.css +377 -377
- package/dist/ai/ai-proposal-card/ai-proposal-card.css +358 -358
- package/dist/ai/ai-suggestion-card/ai-suggestion-card.css +293 -293
- package/dist/ai/ai-tool-call/ai-tool-call.css +255 -255
- package/dist/ai/index.css +1 -1
- package/dist/appearance/cache.d.ts +50 -0
- package/dist/appearance/cache.d.ts.map +1 -0
- package/dist/appearance/cache.js +126 -0
- package/dist/appearance/cache.js.map +1 -0
- package/dist/appearance/cookie.d.ts +18 -0
- package/dist/appearance/cookie.d.ts.map +1 -0
- package/dist/appearance/cookie.js +56 -0
- package/dist/appearance/cookie.js.map +1 -0
- package/dist/appearance/index.d.ts +8 -0
- package/dist/appearance/index.d.ts.map +1 -0
- package/dist/appearance/index.js +5 -0
- package/dist/appearance/index.js.map +1 -0
- package/dist/appearance/preference.d.ts +13 -0
- package/dist/appearance/preference.d.ts.map +1 -0
- package/dist/appearance/preference.js +26 -0
- package/dist/appearance/preference.js.map +1 -0
- package/dist/appearance/theme-controller.d.ts +80 -0
- package/dist/appearance/theme-controller.d.ts.map +1 -0
- package/dist/appearance/theme-controller.js +235 -0
- package/dist/appearance/theme-controller.js.map +1 -0
- package/dist/appearance/types.d.ts +21 -0
- package/dist/appearance/types.d.ts.map +1 -0
- package/dist/appearance/types.js +2 -0
- package/dist/appearance/types.js.map +1 -0
- package/dist/components/alert/alert.css +216 -216
- package/dist/components/avatar/avatar.css +218 -218
- package/dist/components/badge/badge.css +174 -174
- package/dist/components/breadcrumb/breadcrumb.css +204 -204
- package/dist/components/button/button.css +166 -166
- package/dist/components/card/card.css +219 -219
- package/dist/components/checkbox/checkbox.css +186 -186
- package/dist/components/chip/chip.css +267 -267
- package/dist/components/data-grid/data-grid.css +368 -368
- package/dist/components/dialog/dialog.css +274 -274
- package/dist/components/drawer/drawer.css +402 -402
- package/dist/components/dropdown/dropdown.css +297 -297
- package/dist/components/icon-button/icon-button.css +157 -157
- package/dist/components/input/input.css +162 -162
- package/dist/components/menu/menu.css +313 -313
- package/dist/components/modal/modal.css +317 -317
- package/dist/components/pagination/pagination.css +249 -249
- package/dist/components/panel/panel.css +282 -282
- package/dist/components/progress/progress.css +247 -247
- package/dist/components/radio/radio.css +163 -163
- package/dist/components/segmented-control/segmented-control.css +204 -204
- package/dist/components/select/select.css +102 -102
- package/dist/components/skeleton/skeleton.css +262 -262
- package/dist/components/split-button/split-button.css +284 -284
- package/dist/components/switch/switch.css +180 -180
- package/dist/components/tabs/tabs.css +288 -288
- package/dist/components/textarea/textarea.css +85 -85
- package/dist/components/toast/toast.css +322 -322
- package/dist/components/tooltip/tooltip.css +254 -254
- package/dist/domain/billing/index.css +497 -497
- package/dist/domain/calendar/day-slice/day-slice.css +382 -382
- package/dist/domain/calendar/day-timeline/day-timeline.css +323 -323
- package/dist/domain/calendar/event-card/event-card.css +336 -336
- package/dist/domain/calendar/month-grid/month-grid.css +419 -419
- package/dist/domain/calendar/week-grid/week-grid.css +469 -469
- package/dist/domain/companies/index.css +525 -525
- package/dist/index.css +5 -5
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/patterns/command-palette/command-palette.css +438 -438
- package/dist/patterns/company-switcher/company-switcher.css +362 -362
- package/dist/patterns/empty-state/empty-state.css +258 -258
- package/dist/patterns/error-state/error-state.css +271 -271
- package/dist/patterns/loading-state/loading-state.css +287 -287
- package/dist/patterns/notification-center/notification-center.css +437 -437
- package/dist/patterns/profile-menu/profile-menu.css +296 -296
- package/dist/patterns/search-bar/search-bar.css +443 -443
- package/dist/patterns/workspace-switcher/workspace-switcher.css +379 -379
- package/dist/shell/app-shell/app-shell.css +67 -67
- package/dist/shell/content-frame/content-frame.css +93 -93
- package/dist/shell/header/header.css +177 -177
- package/dist/shell/index.css +5 -5
- package/dist/shell/mobile-nav/mobile-nav.css +170 -170
- package/dist/shell/right-drawer/right-drawer.css +107 -107
- package/dist/shell/sidebar/sidebar.css +145 -145
- package/dist/styles/animations/motion.css +161 -161
- package/dist/styles/base.css +81 -81
- package/dist/styles/reset.css +50 -50
- package/dist/styles/themes/dark.css +119 -119
- package/dist/styles/themes/high-contrast.css +118 -118
- package/dist/styles/themes/light.css +118 -118
- package/dist/styles/tokens/breakpoints.css +14 -14
- package/dist/styles/tokens/color.css +96 -96
- package/dist/styles/tokens/elevation.css +31 -31
- package/dist/styles/tokens/motion.css +35 -35
- package/dist/styles/tokens/radius.css +20 -20
- package/dist/styles/tokens/spacing.css +49 -49
- package/dist/styles/tokens/typography.css +83 -83
- package/dist/styles/tokens/z-index.css +14 -14
- package/dist/styles/utilities/layout.css +134 -134
- package/dist/styles/utilities/text.css +151 -151
- package/dist/styles/utilities/visibility.css +47 -47
- package/docs/theming.md +227 -0
- package/package.json +24 -17
- package/src/ai/ai-action-button/ai-action-button.css +269 -269
- package/src/ai/ai-approval-card/ai-approval-card.css +320 -320
- package/src/ai/ai-conversation-panel/ai-conversation-panel.css +403 -403
- package/src/ai/ai-prompt-input/ai-prompt-input.css +377 -377
- package/src/ai/ai-proposal-card/ai-proposal-card.css +358 -358
- package/src/ai/ai-suggestion-card/ai-suggestion-card.css +293 -293
- package/src/ai/ai-tool-call/ai-tool-call.css +255 -255
- package/src/ai/index.css +1 -1
- package/src/appearance/cache.ts +160 -0
- package/src/appearance/cookie.ts +68 -0
- package/src/appearance/index.ts +38 -0
- package/src/appearance/preference.ts +35 -0
- package/src/appearance/theme-controller.ts +383 -0
- package/src/appearance/types.ts +23 -0
- package/src/behaviors/dialog.ts +167 -167
- package/src/behaviors/drawer.ts +176 -176
- package/src/behaviors/dropdown.ts +280 -280
- package/src/behaviors/focus-trap.ts +260 -260
- package/src/behaviors/ids.ts +47 -47
- package/src/behaviors/index.ts +6 -6
- package/src/behaviors/keyboard.ts +302 -302
- package/src/behaviors/overlay.ts +230 -230
- package/src/components/alert/alert.css +216 -216
- package/src/components/avatar/avatar.css +218 -218
- package/src/components/badge/badge.css +174 -174
- package/src/components/breadcrumb/breadcrumb.css +204 -204
- package/src/components/button/button.css +166 -166
- package/src/components/card/card.css +219 -219
- package/src/components/checkbox/checkbox.css +186 -186
- package/src/components/chip/chip.css +267 -267
- package/src/components/data-grid/data-grid.css +368 -368
- package/src/components/dialog/dialog.css +274 -274
- package/src/components/drawer/drawer.css +402 -402
- package/src/components/dropdown/dropdown.css +297 -297
- package/src/components/icon-button/icon-button.css +157 -157
- package/src/components/input/input.css +162 -162
- package/src/components/menu/menu.css +313 -313
- package/src/components/modal/modal.css +317 -317
- package/src/components/pagination/pagination.css +249 -249
- package/src/components/panel/panel.css +282 -282
- package/src/components/progress/progress.css +247 -247
- package/src/components/radio/radio.css +163 -163
- package/src/components/segmented-control/segmented-control.css +204 -204
- package/src/components/select/select.css +102 -102
- package/src/components/skeleton/skeleton.css +262 -262
- package/src/components/split-button/split-button.css +284 -284
- package/src/components/switch/switch.css +180 -180
- package/src/components/tabs/tabs.css +288 -288
- package/src/components/textarea/textarea.css +85 -85
- package/src/components/toast/toast.css +322 -322
- package/src/components/tooltip/tooltip.css +254 -254
- package/src/domain/billing/index.css +497 -497
- package/src/domain/calendar/day-slice/day-slice.css +382 -382
- package/src/domain/calendar/day-timeline/day-timeline.css +323 -323
- package/src/domain/calendar/event-card/event-card.css +336 -336
- package/src/domain/calendar/month-grid/month-grid.css +419 -419
- package/src/domain/calendar/week-grid/week-grid.css +469 -469
- package/src/domain/companies/index.css +525 -525
- package/src/index.css +5 -5
- package/src/index.ts +6 -5
- package/src/patterns/command-palette/command-palette.css +438 -438
- package/src/patterns/company-switcher/company-switcher.css +362 -362
- package/src/patterns/empty-state/empty-state.css +258 -258
- package/src/patterns/error-state/error-state.css +271 -271
- package/src/patterns/loading-state/loading-state.css +287 -287
- package/src/patterns/notification-center/notification-center.css +437 -437
- package/src/patterns/profile-menu/profile-menu.css +296 -296
- package/src/patterns/search-bar/search-bar.css +443 -443
- package/src/patterns/workspace-switcher/workspace-switcher.css +379 -379
- package/src/shell/app-shell/app-shell.css +67 -67
- package/src/shell/content-frame/content-frame.css +93 -93
- package/src/shell/header/header.css +177 -177
- package/src/shell/index.css +5 -5
- package/src/shell/mobile-nav/mobile-nav.css +170 -170
- package/src/shell/right-drawer/right-drawer.css +107 -107
- package/src/shell/sidebar/sidebar.css +145 -145
- package/src/styles/animations/motion.css +161 -161
- package/src/styles/base.css +81 -81
- package/src/styles/reset.css +50 -50
- package/src/styles/themes/dark.css +119 -119
- package/src/styles/themes/high-contrast.css +118 -118
- package/src/styles/themes/light.css +118 -118
- package/src/styles/tokens/breakpoints.css +14 -14
- package/src/styles/tokens/color.css +96 -96
- package/src/styles/tokens/elevation.css +31 -31
- package/src/styles/tokens/motion.css +35 -35
- package/src/styles/tokens/radius.css +20 -20
- package/src/styles/tokens/spacing.css +49 -49
- package/src/styles/tokens/typography.css +83 -83
- package/src/styles/tokens/z-index.css +14 -14
- package/src/styles/utilities/layout.css +134 -134
- package/src/styles/utilities/text.css +151 -151
- package/src/styles/utilities/visibility.css +47 -47
package/docs/theming.md
CHANGED
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
# Theming & the shared appearance system
|
|
2
|
+
|
|
3
|
+
`@neetechs/ui/appearance` is the single appearance system for every
|
|
4
|
+
`*.neetechs.com` application. It bootstraps, resolves and applies the
|
|
5
|
+
account appearance preference. It is framework-neutral (no Angular, no
|
|
6
|
+
React), SSR-safe, and touches no browser global at module import time.
|
|
7
|
+
|
|
8
|
+
> **The database is the source of truth.**
|
|
9
|
+
> **The cookie and local cache only reduce theme flashing.**
|
|
10
|
+
|
|
11
|
+
## Source-of-truth order
|
|
12
|
+
|
|
13
|
+
1. **Backend account preference** — stored by the Django backend, edited in
|
|
14
|
+
MyAccount, applied via `setPreference(..., { source: 'backend' })`.
|
|
15
|
+
2. **Shared-domain bootstrap cookie** — `nt_theme`, set by the backend.
|
|
16
|
+
3. **Optional local cache** — `nt_theme_preference` in `localStorage`.
|
|
17
|
+
4. **System preference** — `(prefers-color-scheme: dark)`.
|
|
18
|
+
5. **Default fallback** — `dark` (matches the package `:root` tokens).
|
|
19
|
+
|
|
20
|
+
The cookie and cache are bootstrap mechanisms only. They must never become
|
|
21
|
+
independent per-application settings, and this package never persists the
|
|
22
|
+
preference to the backend — MyAccount and Django own persistence.
|
|
23
|
+
|
|
24
|
+
## Values
|
|
25
|
+
|
|
26
|
+
| Stored preference (`ThemePreference`) | Resolved theme (`ResolvedTheme`) |
|
|
27
|
+
| ------------------------------------- | -------------------------------- |
|
|
28
|
+
| `system`, `light`, `dark` | `light`, `dark` |
|
|
29
|
+
|
|
30
|
+
`ResolvedThemeState` carries `{ preference, resolved, source }`, where
|
|
31
|
+
`source` is one of `backend | cookie | cache | system | default`.
|
|
32
|
+
|
|
33
|
+
The `high-contrast` theme remains available by setting
|
|
34
|
+
`data-nt-theme="high-contrast"` manually; it is outside the stored
|
|
35
|
+
preference contract for now.
|
|
36
|
+
|
|
37
|
+
## DOM contract
|
|
38
|
+
|
|
39
|
+
The document root is canonical. The controller sets:
|
|
40
|
+
|
|
41
|
+
```html
|
|
42
|
+
<html data-nt-theme="dark" data-nt-theme-preference="system">
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
- `data-nt-theme="light|dark"` — the attribute the theme CSS renders from.
|
|
46
|
+
- `data-nt-theme-preference="system|light|dark"` — informational.
|
|
47
|
+
|
|
48
|
+
Applications must not set theme attributes on `body` or app roots
|
|
49
|
+
independently. The theme token files
|
|
50
|
+
(`src/styles/themes/{dark,light,high-contrast}.css`) already select on
|
|
51
|
+
`[data-nt-theme='…']`; `:root` defaults to the dark token set.
|
|
52
|
+
|
|
53
|
+
## Cookie contract
|
|
54
|
+
|
|
55
|
+
The backend may set the bootstrap cookie:
|
|
56
|
+
|
|
57
|
+
```text
|
|
58
|
+
nt_theme=system | light | dark
|
|
59
|
+
Domain=.neetechs.com; Secure; SameSite=Lax (production)
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
`readThemeCookie(cookieString?)` reads only this cookie, tolerates
|
|
63
|
+
malformed values, and rejects anything but the three allowed values. Pass
|
|
64
|
+
the request `Cookie` header explicitly during SSR; without an argument it
|
|
65
|
+
reads `document.cookie` when a document exists. The frontend never writes
|
|
66
|
+
this cookie.
|
|
67
|
+
|
|
68
|
+
## Cache contract
|
|
69
|
+
|
|
70
|
+
- Key: `nt_theme_preference` (`NT_THEME_CACHE_KEY`).
|
|
71
|
+
- Values: `system | light | dark`; invalid values are deleted on read.
|
|
72
|
+
- Read only when no cookie value exists; overridden by backend and cookie.
|
|
73
|
+
- All storage access is guarded — storage errors never throw.
|
|
74
|
+
- Disable with `useCache: false`.
|
|
75
|
+
|
|
76
|
+
Legacy app keys (`themeMode`, `selectedTheme`, `aiTheme`, `billingTheme`)
|
|
77
|
+
are not read by the controller. Migrate them once at startup:
|
|
78
|
+
|
|
79
|
+
```ts
|
|
80
|
+
import { migrateLegacyThemeCache } from '@neetechs/ui/appearance';
|
|
81
|
+
|
|
82
|
+
migrateLegacyThemeCache(); // adopts a legacy value only if no canonical
|
|
83
|
+
// cache exists, then deletes the legacy keys
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
Migration only touches the local cache; it can never overwrite a backend
|
|
87
|
+
or cookie preference because the cache sits below both.
|
|
88
|
+
|
|
89
|
+
## Early bootstrap (anti-flash)
|
|
90
|
+
|
|
91
|
+
Run before framework rendering — `main.ts`, `main.tsx`, an inline script,
|
|
92
|
+
or an Angular initializer:
|
|
93
|
+
|
|
94
|
+
```ts
|
|
95
|
+
import { bootstrapNeetechsTheme } from '@neetechs/ui/appearance';
|
|
96
|
+
|
|
97
|
+
bootstrapNeetechsTheme(); // cookie → cache → system → default, applies data-nt-theme
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
No network requests, no listeners, no framework dependency. During SSR it
|
|
101
|
+
resolves from an explicit cookie string and no-ops on the DOM:
|
|
102
|
+
|
|
103
|
+
```ts
|
|
104
|
+
bootstrapNeetechsTheme({ cookieString: request.headers.cookie ?? '' });
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
## The controller
|
|
108
|
+
|
|
109
|
+
Create exactly one controller per application:
|
|
110
|
+
|
|
111
|
+
```ts
|
|
112
|
+
import { createThemeController } from '@neetechs/ui/appearance';
|
|
113
|
+
|
|
114
|
+
const themeController = createThemeController();
|
|
115
|
+
|
|
116
|
+
themeController.initialize(); // bootstrap sources + system listener
|
|
117
|
+
themeController.getState(); // { preference, resolved, source }
|
|
118
|
+
themeController.subscribe(state => { /* react to changes */ });
|
|
119
|
+
|
|
120
|
+
// After the app fetches account settings (the app owns the API call):
|
|
121
|
+
themeController.setPreference(settings.appearance, {
|
|
122
|
+
source: 'backend',
|
|
123
|
+
updateCache: true,
|
|
124
|
+
});
|
|
125
|
+
|
|
126
|
+
themeController.destroy(); // removes listeners; re-initializable
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
### System mode
|
|
130
|
+
|
|
131
|
+
When the preference is `system`, the controller listens to
|
|
132
|
+
`(prefers-color-scheme: dark)` via `addEventListener` (with an
|
|
133
|
+
`addListener` fallback for older engines) and re-applies the resolved
|
|
134
|
+
theme immediately on change. The stored preference stays `system` — the
|
|
135
|
+
resolved value is never written back as the preference or to the cache. A
|
|
136
|
+
non-`system` preference ignores system changes. `initialize()` is
|
|
137
|
+
idempotent; `destroy()` removes the listener.
|
|
138
|
+
|
|
139
|
+
## Angular SSR integration
|
|
140
|
+
|
|
141
|
+
```ts
|
|
142
|
+
// app.config.ts (application, not this package)
|
|
143
|
+
import { APP_INITIALIZER, ApplicationConfig } from '@angular/core';
|
|
144
|
+
import {
|
|
145
|
+
bootstrapNeetechsTheme,
|
|
146
|
+
createThemeController,
|
|
147
|
+
type ThemeController,
|
|
148
|
+
} from '@neetechs/ui/appearance';
|
|
149
|
+
|
|
150
|
+
export const NT_THEME_CONTROLLER = new InjectionToken<ThemeController>('nt-theme');
|
|
151
|
+
|
|
152
|
+
export const appConfig: ApplicationConfig = {
|
|
153
|
+
providers: [
|
|
154
|
+
{ provide: NT_THEME_CONTROLLER, useFactory: () => createThemeController() },
|
|
155
|
+
{
|
|
156
|
+
provide: APP_INITIALIZER,
|
|
157
|
+
multi: true,
|
|
158
|
+
deps: [NT_THEME_CONTROLLER],
|
|
159
|
+
useFactory: (controller: ThemeController) => () => {
|
|
160
|
+
controller.initialize(); // SSR-safe: no-ops without document/window
|
|
161
|
+
},
|
|
162
|
+
},
|
|
163
|
+
],
|
|
164
|
+
};
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
- On the server, pass the request cookie so the rendered HTML already
|
|
168
|
+
carries the right attribute: `createThemeController({ cookieString:
|
|
169
|
+
requestCookieHeader })` (or call `bootstrapNeetechsTheme` with it).
|
|
170
|
+
- Hydration is safe because client bootstrap reads the same `nt_theme`
|
|
171
|
+
cookie and sets the same root attribute the server rendered.
|
|
172
|
+
- After the app's own settings service loads the account, call
|
|
173
|
+
`controller.setPreference(appearance, { source: 'backend' })`.
|
|
174
|
+
- Wrap the controller in an app-local injectable exposing signals if
|
|
175
|
+
desired; the design-system package intentionally ships no Angular code.
|
|
176
|
+
|
|
177
|
+
## React / Vite integration
|
|
178
|
+
|
|
179
|
+
```tsx
|
|
180
|
+
// main.tsx (application, not this package)
|
|
181
|
+
import { bootstrapNeetechsTheme, createThemeController } from '@neetechs/ui/appearance';
|
|
182
|
+
|
|
183
|
+
bootstrapNeetechsTheme(); // before createRoot — prevents flash
|
|
184
|
+
|
|
185
|
+
const themeController = createThemeController();
|
|
186
|
+
themeController.initialize();
|
|
187
|
+
|
|
188
|
+
createRoot(document.getElementById('root')!).render(<App />);
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
In components, subscribe with `useSyncExternalStore` so Strict Mode
|
|
192
|
+
mount/unmount cycles cannot leak listeners (the controller also tolerates
|
|
193
|
+
repeated `initialize()`/`destroy()`):
|
|
194
|
+
|
|
195
|
+
```tsx
|
|
196
|
+
function useNeetechsTheme() {
|
|
197
|
+
const state = useSyncExternalStore(
|
|
198
|
+
themeController.subscribe,
|
|
199
|
+
themeController.getState,
|
|
200
|
+
themeController.getState,
|
|
201
|
+
);
|
|
202
|
+
return { ...state, applyBackendPreference: (p) =>
|
|
203
|
+
themeController.setPreference(p, { source: 'backend' }) };
|
|
204
|
+
}
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
## Migrating existing app code
|
|
208
|
+
|
|
209
|
+
| Replace | With |
|
|
210
|
+
| -------------------------------------------------------------- | ------------------------------------------------------- |
|
|
211
|
+
| `localStorage.getItem('themeMode')` (and similar keys) | `migrateLegacyThemeCache()` once, then the controller |
|
|
212
|
+
| `document.body.setAttribute('data-nt-theme', mode)` | `bootstrapNeetechsTheme()` / controller (root `<html>`) |
|
|
213
|
+
| `document.querySelector('app-root')?.setAttribute(...)` | same — the document root is canonical |
|
|
214
|
+
| per-app `matchMedia('(prefers-color-scheme: dark)')` listeners | the controller's built-in system listener |
|
|
215
|
+
| per-app resolved-theme persistence (`dark`/`light` written back) | keep `system` stored; only the DOM attribute resolves |
|
|
216
|
+
|
|
217
|
+
Old `body`/`app-root` attribute selectors keep working while the CSS
|
|
218
|
+
matches `[data-nt-theme]` on any element, but they are deprecated:
|
|
219
|
+
migrate to the document root and remove app-local theme stores. Duplicate
|
|
220
|
+
APIs will not be preserved once all apps are migrated.
|
|
221
|
+
|
|
222
|
+
## What this package deliberately does not do
|
|
223
|
+
|
|
224
|
+
- No calls to `/api/v1/account/settings/` or any endpoint.
|
|
225
|
+
- No knowledge of authentication, users, or companies.
|
|
226
|
+
- No writing of the shared-domain cookie.
|
|
227
|
+
- No JavaScript color mapping — colors live only in the CSS token files.
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
{
|
|
2
2
|
"name": "@neetechs/ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "Official framework-agnostic Neetechs UI design system.",
|
|
5
|
-
"license": "
|
|
5
|
+
"license": "MIT",
|
|
6
6
|
"author": "Neetechs",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"sideEffects": [
|
|
@@ -21,49 +21,44 @@
|
|
|
21
21
|
"scripts": {
|
|
22
22
|
"clean": "rimraf dist",
|
|
23
23
|
"build": "tsc -p tsconfig.json && node scripts/copy-assets.mjs",
|
|
24
|
-
"
|
|
24
|
+
"test": "npm run build && node --test \"tests/**/*.test.mjs\"",
|
|
25
|
+
"pack:local": "npm run build && npm pack",
|
|
26
|
+
"release": "semantic-release"
|
|
25
27
|
},
|
|
26
28
|
"exports": {
|
|
27
29
|
".": {
|
|
28
30
|
"types": "./dist/index.d.ts",
|
|
29
31
|
"import": "./dist/index.js"
|
|
30
32
|
},
|
|
31
|
-
|
|
32
33
|
"./styles": "./src/index.css",
|
|
33
34
|
"./styles.css": "./src/index.css",
|
|
34
|
-
|
|
35
35
|
"./base.css": "./src/styles/index.css",
|
|
36
36
|
"./tokens.css": "./src/styles/tokens/index.css",
|
|
37
37
|
"./reset.css": "./src/styles/reset.css",
|
|
38
|
-
|
|
39
38
|
"./themes/dark.css": "./src/styles/themes/dark.css",
|
|
40
39
|
"./themes/light.css": "./src/styles/themes/light.css",
|
|
41
40
|
"./themes/high-contrast.css": "./src/styles/themes/high-contrast.css",
|
|
42
|
-
|
|
43
41
|
"./utilities/layout.css": "./src/styles/utilities/layout.css",
|
|
44
42
|
"./utilities/text.css": "./src/styles/utilities/text.css",
|
|
45
43
|
"./utilities/visibility.css": "./src/styles/utilities/visibility.css",
|
|
46
|
-
|
|
47
44
|
"./animations/motion.css": "./src/styles/animations/motion.css",
|
|
48
|
-
|
|
49
45
|
"./shell.css": "./src/shell/index.css",
|
|
50
46
|
"./shell/*.css": "./src/shell/*/*.css",
|
|
51
|
-
|
|
52
47
|
"./components.css": "./src/components/index.css",
|
|
53
48
|
"./components/*.css": "./src/components/*/*.css",
|
|
54
|
-
|
|
55
49
|
"./patterns.css": "./src/patterns/index.css",
|
|
56
50
|
"./patterns/*.css": "./src/patterns/*/*.css",
|
|
57
|
-
|
|
58
51
|
"./ai.css": "./src/ai/index.css",
|
|
59
52
|
"./ai/*.css": "./src/ai/*/*.css",
|
|
60
|
-
|
|
61
53
|
"./domain.css": "./src/domain/index.css",
|
|
62
54
|
"./domain/calendar.css": "./src/domain/calendar/index.css",
|
|
63
55
|
"./domain/calendar/*.css": "./src/domain/calendar/*/*.css",
|
|
64
56
|
"./domain/billing.css": "./src/domain/billing/index.css",
|
|
65
57
|
"./domain/companies.css": "./src/domain/companies/index.css",
|
|
66
|
-
|
|
58
|
+
"./appearance": {
|
|
59
|
+
"types": "./dist/appearance/index.d.ts",
|
|
60
|
+
"import": "./dist/appearance/index.js"
|
|
61
|
+
},
|
|
67
62
|
"./behaviors": {
|
|
68
63
|
"types": "./dist/behaviors/index.d.ts",
|
|
69
64
|
"import": "./dist/behaviors/index.js"
|
|
@@ -72,14 +67,26 @@
|
|
|
72
67
|
"types": "./dist/behaviors/*.d.ts",
|
|
73
68
|
"import": "./dist/behaviors/*.js"
|
|
74
69
|
},
|
|
75
|
-
|
|
76
70
|
"./types": {
|
|
77
71
|
"types": "./dist/types/index.d.ts",
|
|
78
72
|
"import": "./dist/types/index.js"
|
|
79
73
|
}
|
|
80
74
|
},
|
|
81
75
|
"devDependencies": {
|
|
76
|
+
"@semantic-release/commit-analyzer": "^13.0.1",
|
|
77
|
+
"@semantic-release/github": "^12.0.9",
|
|
78
|
+
"@semantic-release/npm": "^13.1.5",
|
|
79
|
+
"@semantic-release/release-notes-generator": "^14.1.1",
|
|
82
80
|
"rimraf": "^6.0.1",
|
|
81
|
+
"semantic-release": "^25.0.7",
|
|
83
82
|
"typescript": "^5.8.3"
|
|
83
|
+
},
|
|
84
|
+
"repository": {
|
|
85
|
+
"type": "git",
|
|
86
|
+
"url": "git+https://github.com/jihadelsayed/Neetechs_Design_System.git"
|
|
87
|
+
},
|
|
88
|
+
"publishConfig": {
|
|
89
|
+
"access": "public",
|
|
90
|
+
"registry": "https://registry.npmjs.org/"
|
|
84
91
|
}
|
|
85
|
-
}
|
|
92
|
+
}
|