@owodesign/owoui 0.1.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.
@@ -0,0 +1,221 @@
1
+ const catalog = {
2
+ "groups": [
3
+ {
4
+ "id": "actions",
5
+ "label": "Actions",
6
+ "items": [
7
+ {
8
+ "group": "actions",
9
+ "componentId": "button",
10
+ "componentName": "Button",
11
+ "description": "Primary action trigger. Supports variants, sizes, icons, loading, and disabled states."
12
+ },
13
+ {
14
+ "group": "actions",
15
+ "componentId": "icon-button",
16
+ "componentName": "IconButton",
17
+ "description": "Icon-only action button. Supports ghost/subtle variants, sm/md sizes."
18
+ },
19
+ {
20
+ "group": "actions",
21
+ "componentId": "dropdown-menu",
22
+ "componentName": "DropdownMenu",
23
+ "description": "Industrial dropdown primitive for action menus, grouped pickers, and nested submenus."
24
+ }
25
+ ]
26
+ },
27
+ {
28
+ "id": "forms",
29
+ "label": "Forms",
30
+ "items": [
31
+ {
32
+ "group": "forms",
33
+ "componentId": "input",
34
+ "componentName": "Input",
35
+ "description": "Unified input element. Renders as input or textarea via the `as` prop. For dropdown selection, use the Select component."
36
+ },
37
+ {
38
+ "group": "forms",
39
+ "componentId": "field",
40
+ "componentName": "Field",
41
+ "description": "Form field wrapper with label and optional help text."
42
+ },
43
+ {
44
+ "group": "forms",
45
+ "componentId": "select",
46
+ "componentName": "Select",
47
+ "description": "Custom dropdown select with keyboard navigation and design-system styling."
48
+ },
49
+ {
50
+ "group": "forms",
51
+ "componentId": "segmented-control",
52
+ "componentName": "SegmentedControl",
53
+ "description": "Tab-like toggle for mutually exclusive options."
54
+ },
55
+ {
56
+ "group": "forms",
57
+ "componentId": "switch",
58
+ "componentName": "Switch",
59
+ "description": "Toggle switch for boolean settings."
60
+ }
61
+ ]
62
+ },
63
+ {
64
+ "id": "feedback",
65
+ "label": "Feedback",
66
+ "items": [
67
+ {
68
+ "group": "feedback",
69
+ "componentId": "badge",
70
+ "componentName": "Badge",
71
+ "description": "Inline label for status, categories, or counts. Token-driven: --badge-bg, --badge-text, --badge-border."
72
+ },
73
+ {
74
+ "group": "feedback",
75
+ "componentId": "status-notice",
76
+ "componentName": "StatusNotice",
77
+ "description": "Block-level feedback banner. Supports neutral plus semantic tones, with optional icon slot."
78
+ },
79
+ {
80
+ "group": "feedback",
81
+ "componentId": "empty-state",
82
+ "componentName": "EmptyState",
83
+ "description": "Placeholder for empty lists or missing content. Token-driven: --empty-state-bg, --empty-state-border, --empty-state-title, --empty-state-text, --empty-state-icon."
84
+ },
85
+ {
86
+ "group": "feedback",
87
+ "componentId": "spinner",
88
+ "componentName": "Spinner",
89
+ "description": "Animated loading indicator with multiple icon styles. Used standalone or composed into other components (e.g. Button loading state)."
90
+ },
91
+ {
92
+ "group": "feedback",
93
+ "componentId": "skeleton",
94
+ "componentName": "Skeleton",
95
+ "description": "Loading placeholder with `scan` or `pulse` animation and configurable speed."
96
+ },
97
+ {
98
+ "group": "feedback",
99
+ "componentId": "dialog",
100
+ "componentName": "Dialog",
101
+ "description": "Modal dialog for confirmations and focused tasks. Supports declarative usage via <Dialog> and imperative usage via `useConfirm()` hook. The imperative API requires `<ConfirmProvider>` in an ancestor (mounted in admin layout)."
102
+ },
103
+ {
104
+ "group": "feedback",
105
+ "componentId": "toast",
106
+ "componentName": "Toast",
107
+ "description": "Transient notification messages triggered via `useToast()` hook. Requires `<ToastProvider>` wrapper."
108
+ },
109
+ {
110
+ "group": "feedback",
111
+ "componentId": "avatar",
112
+ "componentName": "Avatar",
113
+ "description": "User avatar with image or initials fallback. Token-driven: --avatar-bg, --avatar-text, --avatar-border."
114
+ },
115
+ {
116
+ "group": "feedback",
117
+ "componentId": "tooltip",
118
+ "componentName": "Tooltip",
119
+ "description": "Hover/focus-triggered floating label. Token-driven: --tooltip-bg, --tooltip-border, --tooltip-text, --tooltip-shadow, --tooltip-arrow-color."
120
+ }
121
+ ]
122
+ },
123
+ {
124
+ "id": "layout",
125
+ "label": "Layout",
126
+ "items": [
127
+ {
128
+ "group": "layout",
129
+ "componentId": "drawer",
130
+ "componentName": "Drawer",
131
+ "description": "Sliding overlay container for left/right drawers with optional backdrop. Token-driven: --drawer-surface, --drawer-border, --drawer-shadow, --drawer-backdrop."
132
+ },
133
+ {
134
+ "group": "layout",
135
+ "componentId": "panel",
136
+ "componentName": "Panel",
137
+ "description": "Container card driven by surface hierarchy and structured sections (header/body/footer), not by blanket shadow elevation."
138
+ }
139
+ ]
140
+ }
141
+ ],
142
+ "paths": [
143
+ {
144
+ "group": "actions",
145
+ "componentId": "button"
146
+ },
147
+ {
148
+ "group": "actions",
149
+ "componentId": "dropdown-menu"
150
+ },
151
+ {
152
+ "group": "actions",
153
+ "componentId": "icon-button"
154
+ },
155
+ {
156
+ "group": "forms",
157
+ "componentId": "input"
158
+ },
159
+ {
160
+ "group": "forms",
161
+ "componentId": "field"
162
+ },
163
+ {
164
+ "group": "forms",
165
+ "componentId": "select"
166
+ },
167
+ {
168
+ "group": "forms",
169
+ "componentId": "segmented-control"
170
+ },
171
+ {
172
+ "group": "forms",
173
+ "componentId": "switch"
174
+ },
175
+ {
176
+ "group": "feedback",
177
+ "componentId": "badge"
178
+ },
179
+ {
180
+ "group": "feedback",
181
+ "componentId": "status-notice"
182
+ },
183
+ {
184
+ "group": "feedback",
185
+ "componentId": "empty-state"
186
+ },
187
+ {
188
+ "group": "feedback",
189
+ "componentId": "spinner"
190
+ },
191
+ {
192
+ "group": "feedback",
193
+ "componentId": "skeleton"
194
+ },
195
+ {
196
+ "group": "feedback",
197
+ "componentId": "dialog"
198
+ },
199
+ {
200
+ "group": "feedback",
201
+ "componentId": "toast"
202
+ },
203
+ {
204
+ "group": "feedback",
205
+ "componentId": "avatar"
206
+ },
207
+ {
208
+ "group": "feedback",
209
+ "componentId": "tooltip"
210
+ },
211
+ {
212
+ "group": "layout",
213
+ "componentId": "drawer"
214
+ },
215
+ {
216
+ "group": "layout",
217
+ "componentId": "panel"
218
+ }
219
+ ]
220
+ };
221
+ export default catalog;
@@ -0,0 +1,220 @@
1
+ {
2
+ "groups": [
3
+ {
4
+ "id": "actions",
5
+ "label": "Actions",
6
+ "items": [
7
+ {
8
+ "group": "actions",
9
+ "componentId": "button",
10
+ "componentName": "Button",
11
+ "description": "Primary action trigger. Supports variants, sizes, icons, loading, and disabled states."
12
+ },
13
+ {
14
+ "group": "actions",
15
+ "componentId": "icon-button",
16
+ "componentName": "IconButton",
17
+ "description": "Icon-only action button. Supports ghost/subtle variants, sm/md sizes."
18
+ },
19
+ {
20
+ "group": "actions",
21
+ "componentId": "dropdown-menu",
22
+ "componentName": "DropdownMenu",
23
+ "description": "Industrial dropdown primitive for action menus, grouped pickers, and nested submenus."
24
+ }
25
+ ]
26
+ },
27
+ {
28
+ "id": "forms",
29
+ "label": "Forms",
30
+ "items": [
31
+ {
32
+ "group": "forms",
33
+ "componentId": "input",
34
+ "componentName": "Input",
35
+ "description": "Unified input element. Renders as input or textarea via the `as` prop. For dropdown selection, use the Select component."
36
+ },
37
+ {
38
+ "group": "forms",
39
+ "componentId": "field",
40
+ "componentName": "Field",
41
+ "description": "Form field wrapper with label and optional help text."
42
+ },
43
+ {
44
+ "group": "forms",
45
+ "componentId": "select",
46
+ "componentName": "Select",
47
+ "description": "Custom dropdown select with keyboard navigation and design-system styling."
48
+ },
49
+ {
50
+ "group": "forms",
51
+ "componentId": "segmented-control",
52
+ "componentName": "SegmentedControl",
53
+ "description": "Tab-like toggle for mutually exclusive options."
54
+ },
55
+ {
56
+ "group": "forms",
57
+ "componentId": "switch",
58
+ "componentName": "Switch",
59
+ "description": "Toggle switch for boolean settings."
60
+ }
61
+ ]
62
+ },
63
+ {
64
+ "id": "feedback",
65
+ "label": "Feedback",
66
+ "items": [
67
+ {
68
+ "group": "feedback",
69
+ "componentId": "badge",
70
+ "componentName": "Badge",
71
+ "description": "Inline label for status, categories, or counts. Token-driven: --badge-bg, --badge-text, --badge-border."
72
+ },
73
+ {
74
+ "group": "feedback",
75
+ "componentId": "status-notice",
76
+ "componentName": "StatusNotice",
77
+ "description": "Block-level feedback banner. Supports neutral plus semantic tones, with optional icon slot."
78
+ },
79
+ {
80
+ "group": "feedback",
81
+ "componentId": "empty-state",
82
+ "componentName": "EmptyState",
83
+ "description": "Placeholder for empty lists or missing content. Token-driven: --empty-state-bg, --empty-state-border, --empty-state-title, --empty-state-text, --empty-state-icon."
84
+ },
85
+ {
86
+ "group": "feedback",
87
+ "componentId": "spinner",
88
+ "componentName": "Spinner",
89
+ "description": "Animated loading indicator with multiple icon styles. Used standalone or composed into other components (e.g. Button loading state)."
90
+ },
91
+ {
92
+ "group": "feedback",
93
+ "componentId": "skeleton",
94
+ "componentName": "Skeleton",
95
+ "description": "Loading placeholder with `scan` or `pulse` animation and configurable speed."
96
+ },
97
+ {
98
+ "group": "feedback",
99
+ "componentId": "dialog",
100
+ "componentName": "Dialog",
101
+ "description": "Modal dialog for confirmations and focused tasks. Supports declarative usage via <Dialog> and imperative usage via `useConfirm()` hook. The imperative API requires `<ConfirmProvider>` in an ancestor (mounted in admin layout)."
102
+ },
103
+ {
104
+ "group": "feedback",
105
+ "componentId": "toast",
106
+ "componentName": "Toast",
107
+ "description": "Transient notification messages triggered via `useToast()` hook. Requires `<ToastProvider>` wrapper."
108
+ },
109
+ {
110
+ "group": "feedback",
111
+ "componentId": "avatar",
112
+ "componentName": "Avatar",
113
+ "description": "User avatar with image or initials fallback. Token-driven: --avatar-bg, --avatar-text, --avatar-border."
114
+ },
115
+ {
116
+ "group": "feedback",
117
+ "componentId": "tooltip",
118
+ "componentName": "Tooltip",
119
+ "description": "Hover/focus-triggered floating label. Token-driven: --tooltip-bg, --tooltip-border, --tooltip-text, --tooltip-shadow, --tooltip-arrow-color."
120
+ }
121
+ ]
122
+ },
123
+ {
124
+ "id": "layout",
125
+ "label": "Layout",
126
+ "items": [
127
+ {
128
+ "group": "layout",
129
+ "componentId": "drawer",
130
+ "componentName": "Drawer",
131
+ "description": "Sliding overlay container for left/right drawers with optional backdrop. Token-driven: --drawer-surface, --drawer-border, --drawer-shadow, --drawer-backdrop."
132
+ },
133
+ {
134
+ "group": "layout",
135
+ "componentId": "panel",
136
+ "componentName": "Panel",
137
+ "description": "Container card driven by surface hierarchy and structured sections (header/body/footer), not by blanket shadow elevation."
138
+ }
139
+ ]
140
+ }
141
+ ],
142
+ "paths": [
143
+ {
144
+ "group": "actions",
145
+ "componentId": "button"
146
+ },
147
+ {
148
+ "group": "actions",
149
+ "componentId": "dropdown-menu"
150
+ },
151
+ {
152
+ "group": "actions",
153
+ "componentId": "icon-button"
154
+ },
155
+ {
156
+ "group": "forms",
157
+ "componentId": "input"
158
+ },
159
+ {
160
+ "group": "forms",
161
+ "componentId": "field"
162
+ },
163
+ {
164
+ "group": "forms",
165
+ "componentId": "select"
166
+ },
167
+ {
168
+ "group": "forms",
169
+ "componentId": "segmented-control"
170
+ },
171
+ {
172
+ "group": "forms",
173
+ "componentId": "switch"
174
+ },
175
+ {
176
+ "group": "feedback",
177
+ "componentId": "badge"
178
+ },
179
+ {
180
+ "group": "feedback",
181
+ "componentId": "status-notice"
182
+ },
183
+ {
184
+ "group": "feedback",
185
+ "componentId": "empty-state"
186
+ },
187
+ {
188
+ "group": "feedback",
189
+ "componentId": "spinner"
190
+ },
191
+ {
192
+ "group": "feedback",
193
+ "componentId": "skeleton"
194
+ },
195
+ {
196
+ "group": "feedback",
197
+ "componentId": "dialog"
198
+ },
199
+ {
200
+ "group": "feedback",
201
+ "componentId": "toast"
202
+ },
203
+ {
204
+ "group": "feedback",
205
+ "componentId": "avatar"
206
+ },
207
+ {
208
+ "group": "feedback",
209
+ "componentId": "tooltip"
210
+ },
211
+ {
212
+ "group": "layout",
213
+ "componentId": "drawer"
214
+ },
215
+ {
216
+ "group": "layout",
217
+ "componentId": "panel"
218
+ }
219
+ ]
220
+ }
@@ -0,0 +1,37 @@
1
+ import { ReactNode } from 'react';
2
+
3
+ type StorybookGroup = 'actions' | 'forms' | 'feedback' | 'layout';
4
+ interface StoryDefinition {
5
+ id: string;
6
+ title: string;
7
+ description?: string;
8
+ source?: string;
9
+ render: () => ReactNode;
10
+ }
11
+ interface PropSummary {
12
+ name: string;
13
+ type: string;
14
+ default?: string;
15
+ description?: string;
16
+ }
17
+ interface ComponentStoriesDefinition {
18
+ group: StorybookGroup;
19
+ componentId: string;
20
+ componentName: string;
21
+ description?: string;
22
+ props?: PropSummary[];
23
+ renderPlayground?: (props: Record<string, unknown>, update: (name: string, value: unknown) => void) => ReactNode;
24
+ stories: StoryDefinition[];
25
+ }
26
+ interface StorybookStoryPath {
27
+ group: StorybookGroup;
28
+ componentId: string;
29
+ }
30
+ declare const storybookStoryPaths: StorybookStoryPath[];
31
+ declare function registerStories(def: ComponentStoriesDefinition): void;
32
+ declare function getStoriesByGroupAndComponent(group: string, componentId: string): ComponentStoriesDefinition | undefined;
33
+ declare function getGroupedStories(): Record<StorybookGroup, ComponentStoriesDefinition[]>;
34
+ declare const groupLabels: Record<StorybookGroup, string>;
35
+ declare const groupOrder: StorybookGroup[];
36
+
37
+ export { type ComponentStoriesDefinition, type PropSummary, type StoryDefinition, type StorybookGroup, type StorybookStoryPath, getGroupedStories, getStoriesByGroupAndComponent, groupLabels, groupOrder, registerStories, storybookStoryPaths };