@vireocodedev/ui 0.2.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.
Files changed (3) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +83 -0
  3. package/package.json +197 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 vireocodedev
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,83 @@
1
+ # @vireocodedev/ui
2
+
3
+ The **MUI-based Vireo component library** for the vireocodedev **starter** product,
4
+ including TanStack-bound forms, responsive tables, overlays, page layout,
5
+ typed integrations, foundational providers, hooks, and formatters.
6
+
7
+ > This package takes `@mui/*` as **peer dependencies** — it is tied to the
8
+ > starter design system, not a generic component kit.
9
+
10
+ ## Install
11
+
12
+ ```bash
13
+ npm install @vireocodedev/ui
14
+ ```
15
+
16
+ The package is published publicly on npm; installation requires no registry
17
+ authentication.
18
+
19
+ Peers: `react`, `react-dom`, `@mui/material`, `@mui/icons-material`,
20
+ `@mui/x-date-pickers`, `@emotion/react`, `@emotion/styled`,
21
+ `@tanstack/react-query`, `i18next`,
22
+ `react-i18next`, `zod`, `sonner`, `dayjs`. Depends on
23
+ `@vireocodedev/localization`, which owns the `platform` and `history`
24
+ translation namespaces this package renders.
25
+
26
+ The package ships unbundled: `dist` mirrors `src` file-for-file. Supported
27
+ consumer entry points are nevertheless limited to the package root and the
28
+ subpaths declared in `package.json`; undeclared implementation paths are not a
29
+ compatibility contract.
30
+
31
+ TypeScript declarations are verified from the packed artifact with TypeScript
32
+ 6, `moduleResolution: "Bundler"`, and `skipLibCheck: false`. This file-for-file
33
+ package intentionally omits source maps; its public source remains available in
34
+ the repository.
35
+
36
+ ## What's included
37
+
38
+ - **Components** — Vireo form fields and layout primitives, responsive cards,
39
+ tables, overlays, navigation, feedback, and data-display components.
40
+ - **Forms** — `useVireoForm`, its bound `form.*` and `field.*` APIs, and
41
+ `VireoResponsiveFormOverlay`.
42
+ - **Tables** — `VireoResponsiveTable`, the typed container-aware desktop table
43
+ and mobile accordion contract with controlled sorting, pagination, loading,
44
+ filtering surfaces, incremental mobile loading, and scroll restoration.
45
+ - **Providers** — `VireoConfirmationProvider`, `VireoIconRegistryProvider`,
46
+ `VireoProviderComposer`, and `VireoThemeColorMeta`.
47
+ - **Localization integrations** — temporal picker localization under
48
+ `/localization` and namespace-bound React hooks under `/react-i18next`.
49
+ - **Hooks** — `useVireoDebouncedCallback`, `useVireoFullscreen`,
50
+ `useVireoTransitionPresence`, `useAppPageContentLayout`,
51
+ `usePageOverlayModes`, and `useDelayedOverlayMount`.
52
+ - **Overlays** — responsive side-panel/drawer frames, page-overlay controller,
53
+ delayed mounting, and guarded mode switching.
54
+ - **Layout** — `AppPageContentLayoutContext`, layout utils + shell breakpoints,
55
+ `PageBody`, and measured page-content mode.
56
+ - **Unsaved changes** — scoped registration, confirmation, and route-leave
57
+ guard primitives for app composition roots.
58
+ - **Utils** — currency/date formatters, `downloadFile`.
59
+
60
+ ## Notes
61
+
62
+ - Everything is a **named export** off the package root.
63
+ - The app retains only composition roots that supply app-specific policy and
64
+ routing; the reusable form, overlay, table, and unsaved-change behavior lives
65
+ in this package.
66
+
67
+ ## Architecture and authoring
68
+
69
+ The architecture guides describe the required destination for the ongoing
70
+ source migration. Existing legacy paths are tracked explicitly; new and moved
71
+ code must follow the target structure.
72
+
73
+ - [Source structure](./docs/architecture/source-structure.md)
74
+ - [Capability structure](./docs/architecture/capability-structure.md)
75
+ - [Component folder categories](./docs/architecture/component-folder-categories.md)
76
+ - [Migration and current-source inventory](./docs/architecture/migration.md)
77
+ - [Vireo component authoring](./docs/component-authoring/component-files.md)
78
+ - [Vireo story coverage rulebook](./docs/component-authoring/story-coverage-rulebook.md)
79
+ - [Motion and interaction language](./docs/storybook/MotionGuide.mdx)
80
+
81
+ ## Versioning contract
82
+
83
+ The exported surface is a contract (add = minor, remove/rename = major).
package/package.json ADDED
@@ -0,0 +1,197 @@
1
+ {
2
+ "name": "@vireocodedev/ui",
3
+ "version": "0.2.0",
4
+ "description": "MUI-based UI component library (responsive cards, mobile tables, overlays, providers, hooks, formatters) for the vireocodedev starter product.",
5
+ "type": "module",
6
+ "sideEffects": [
7
+ "**/*.css"
8
+ ],
9
+ "license": "MIT",
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "git+https://github.com/vireocodedev/starter.git",
13
+ "directory": "packages/ui"
14
+ },
15
+ "keywords": [
16
+ "ui",
17
+ "mui",
18
+ "react",
19
+ "components",
20
+ "starter"
21
+ ],
22
+ "exports": {
23
+ ".": {
24
+ "types": "./dist/index.d.ts",
25
+ "import": "./dist/index.js",
26
+ "default": "./dist/index.js"
27
+ },
28
+ "./country": {
29
+ "types": "./dist/capabilities/country/public.d.ts",
30
+ "import": "./dist/capabilities/country/public.js",
31
+ "default": "./dist/capabilities/country/public.js"
32
+ },
33
+ "./event-source": {
34
+ "types": "./dist/integrations/event-source/public.d.ts",
35
+ "import": "./dist/integrations/event-source/public.js",
36
+ "default": "./dist/integrations/event-source/public.js"
37
+ },
38
+ "./forms": {
39
+ "types": "./dist/capabilities/forms/public.d.ts",
40
+ "import": "./dist/capabilities/forms/public.js",
41
+ "default": "./dist/capabilities/forms/public.js"
42
+ },
43
+ "./hello-pangea-dnd": {
44
+ "types": "./dist/integrations/hello-pangea-dnd/public.d.ts",
45
+ "import": "./dist/integrations/hello-pangea-dnd/public.js",
46
+ "default": "./dist/integrations/hello-pangea-dnd/public.js"
47
+ },
48
+ "./localization": {
49
+ "types": "./dist/integrations/localization/public.d.ts",
50
+ "import": "./dist/integrations/localization/public.js",
51
+ "default": "./dist/integrations/localization/public.js"
52
+ },
53
+ "./react-i18next": {
54
+ "types": "./dist/integrations/react-i18next/public.d.ts",
55
+ "import": "./dist/integrations/react-i18next/public.js",
56
+ "default": "./dist/integrations/react-i18next/public.js"
57
+ },
58
+ "./sonner": {
59
+ "types": "./dist/integrations/sonner/public.d.ts",
60
+ "import": "./dist/integrations/sonner/public.js",
61
+ "default": "./dist/integrations/sonner/public.js"
62
+ },
63
+ "./tanstack-query": {
64
+ "types": "./dist/integrations/tanstack-query/public.d.ts",
65
+ "import": "./dist/integrations/tanstack-query/public.js",
66
+ "default": "./dist/integrations/tanstack-query/public.js"
67
+ },
68
+ "./storybook": {
69
+ "types": "./dist/storybook/index.d.ts",
70
+ "import": "./dist/storybook/index.js",
71
+ "default": "./dist/storybook/index.js"
72
+ },
73
+ "./storybook/VireoIconContainer": {
74
+ "types": "./dist/storybook/VireoIconContainer/index.d.ts",
75
+ "import": "./dist/storybook/VireoIconContainer/index.js",
76
+ "default": "./dist/storybook/VireoIconContainer/index.js"
77
+ },
78
+ "./storybook/VireoDockedSidePanel": {
79
+ "types": "./dist/storybook/VireoDockedSidePanel/index.d.ts",
80
+ "import": "./dist/storybook/VireoDockedSidePanel/index.js",
81
+ "default": "./dist/storybook/VireoDockedSidePanel/index.js"
82
+ },
83
+ "./storybook/VireoResponsiveOverlayFrame": {
84
+ "types": "./dist/storybook/VireoResponsiveOverlayFrame/index.d.ts",
85
+ "import": "./dist/storybook/VireoResponsiveOverlayFrame/index.js",
86
+ "default": "./dist/storybook/VireoResponsiveOverlayFrame/index.js"
87
+ }
88
+ },
89
+ "main": "./dist/index.js",
90
+ "module": "./dist/index.js",
91
+ "types": "./dist/index.d.ts",
92
+ "files": [
93
+ "dist"
94
+ ],
95
+ "scripts": {
96
+ "clean": "rimraf dist",
97
+ "build:css": "copyfiles -u 1 \"src/**/*.css\" dist",
98
+ "build": "corepack npm run clean && corepack npm run build:types && concurrently --kill-others-on-fail -n storybook,css \"corepack npm run build:storybook-types:emit\" \"corepack npm run build:css\" && tsc-alias -p tsconfig.build.json && tsc-alias -p tsconfig.storybook.build.json",
99
+ "build:types": "tsc -p tsconfig.build.json --noCheck",
100
+ "build:storybook-types": "corepack npm run build:types && corepack npm run build:storybook-types:emit",
101
+ "build:storybook-types:emit": "tsc -p tsconfig.storybook.build.json --noCheck",
102
+ "build:storybook-exports": "corepack npm run build:storybook-types && tsc-alias -p tsconfig.storybook.build.json",
103
+ "dev": "concurrently -k -n tsc,aliases,css \"npm run dev:tsc\" \"npm run dev:aliases\" \"npm run dev:css\"",
104
+ "dev:tsc": "tsc -w -p tsconfig.build.json",
105
+ "dev:aliases": "tsc-alias -w -p tsconfig.build.json",
106
+ "dev:css": "chokidar \"src/**/*.css\" -c \"npm run build:css\" --initial",
107
+ "typecheck": "tsc --noEmit -p tsconfig.json",
108
+ "test": "vitest run",
109
+ "storybook": "storybook dev -p 6006 -c .storybook-vireo",
110
+ "build-storybook": "storybook build -c .storybook-vireo"
111
+ },
112
+ "dependencies": {
113
+ "@vireocodedev/history": "^0.2.0",
114
+ "@vireocodedev/infrastructure": "^0.2.0",
115
+ "@vireocodedev/localization": "^0.2.0",
116
+ "@vireocodedev/query": "^0.2.0",
117
+ "country-flag-icons": "1.6.20",
118
+ "react-error-boundary": "^6.1.3"
119
+ },
120
+ "peerDependencies": {
121
+ "@hello-pangea/dnd": ">=18 <19",
122
+ "@emotion/react": ">=11.14 <12",
123
+ "@emotion/styled": ">=11.14 <12",
124
+ "@mui/icons-material": ">=9 <10",
125
+ "@mui/material": ">=9 <10",
126
+ "@mui/x-date-pickers": ">=9 <10",
127
+ "@tanstack/react-form": ">=1.33 <2",
128
+ "@tanstack/react-query": ">=5.80 <6",
129
+ "dayjs": ">=1.11",
130
+ "i18next": ">=26 <27",
131
+ "react": ">=19.2 <20",
132
+ "react-dom": ">=19.2 <20",
133
+ "react-i18next": ">=17 <18",
134
+ "sonner": ">=2",
135
+ "zod": ">=4.4 <5"
136
+ },
137
+ "peerDependenciesMeta": {
138
+ "@hello-pangea/dnd": {
139
+ "optional": true
140
+ },
141
+ "@tanstack/react-form": {
142
+ "optional": true
143
+ },
144
+ "@tanstack/react-query": {
145
+ "optional": true
146
+ },
147
+ "i18next": {
148
+ "optional": true
149
+ },
150
+ "react-i18next": {
151
+ "optional": true
152
+ },
153
+ "sonner": {
154
+ "optional": true
155
+ }
156
+ },
157
+ "devDependencies": {
158
+ "@hello-pangea/dnd": "^18.0.1",
159
+ "@emotion/react": "^11.14.0",
160
+ "@emotion/styled": "^11.14.0",
161
+ "@mui/icons-material": "^9.3.1",
162
+ "@mui/material": "^9.3.1",
163
+ "@mui/x-date-pickers": "^9.12.0",
164
+ "@storybook/addon-docs": "^10.5.10",
165
+ "@storybook/icons": "^2.1.0",
166
+ "@storybook/react-vite": "^10.5.10",
167
+ "@tanstack/react-form": "1.33.5",
168
+ "@tanstack/react-query": "^5.102.1",
169
+ "@testing-library/jest-dom": "^7.0.1",
170
+ "@testing-library/react": "^16.3.2",
171
+ "@types/node": "^24.13.3",
172
+ "@types/react": "^19.2.18",
173
+ "@types/react-dom": "^19.2.4",
174
+ "chokidar-cli": "^3.0.0",
175
+ "concurrently": "^10.0.5",
176
+ "copyfiles": "^2.4.1",
177
+ "dayjs": "^1.11.23",
178
+ "i18next": "^26.4.0",
179
+ "jsdom": "^30.0.1",
180
+ "react": "^19.2.8",
181
+ "react-dom": "^19.2.8",
182
+ "react-i18next": "^17.0.12",
183
+ "rimraf": "^6.0.1",
184
+ "sonner": "^2.0.8",
185
+ "storybook": "^10.5.10",
186
+ "tsc-alias": "^1.9.2",
187
+ "typescript": "npm:@typescript/typescript6@^6.0.2",
188
+ "vite": "^8.2.2",
189
+ "vitest": "^4.1.11",
190
+ "zod": "^4.4.3"
191
+ },
192
+ "publishConfig": {
193
+ "access": "public",
194
+ "provenance": true,
195
+ "registry": "https://registry.npmjs.org"
196
+ }
197
+ }