@exegia/corpora-ui 0.19.0 → 0.20.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.
- package/dist-lib/components/blocks/nav/sidebar/__tests__/use-ai-sidebar.test.d.ts +1 -0
- package/dist-lib/components/blocks/nav/sidebar/ai-sidebar.d.ts +11 -2
- package/dist-lib/components/blocks/nav/sidebar/type.d.ts +83 -1
- package/dist-lib/components/blocks/nav/sidebar/use-ai-sidebar.d.ts +22 -31
- package/dist-lib/components/blocks/nav/sidebar/utils.d.ts +5 -0
- package/dist-lib/components/blocks/scaffold/constants.d.ts +5 -0
- package/dist-lib/components/blocks/scaffold/scaffold-canvas.d.ts +2 -0
- package/dist-lib/components/blocks/scaffold/scaffold-panel.d.ts +1 -1
- package/dist-lib/components/blocks/scaffold/scaffold-tab.d.ts +6 -1
- package/dist-lib/components/blocks/scaffold/type.d.ts +28 -0
- package/dist-lib/components/blocks/scaffold/use-panel-visibility.d.ts +19 -0
- package/dist-lib/components/blocks/scaffold/utils.d.ts +6 -0
- package/dist-lib/components/composed/tree/__tests__/tree.test.d.ts +1 -0
- package/dist-lib/components/composed/tree/__tests__/use-tree.test.d.ts +1 -0
- package/dist-lib/components/composed/tree/constants.d.ts +35 -0
- package/dist-lib/components/composed/tree/index.d.ts +4 -0
- package/dist-lib/components/composed/tree/tree-context.d.ts +4 -0
- package/dist-lib/components/composed/tree/tree-node.d.ts +7 -0
- package/dist-lib/components/composed/tree/tree.d.ts +19 -0
- package/dist-lib/components/composed/tree/type.d.ts +192 -0
- package/dist-lib/components/composed/tree/use-tree-dnd.d.ts +7 -0
- package/dist-lib/components/composed/tree/use-tree.d.ts +20 -0
- package/dist-lib/components/composed/tree/utils.d.ts +28 -0
- package/dist-lib/components/user-avatar/audio-wave.d.ts +2 -0
- package/dist-lib/components/user-avatar/component.d.ts +10 -0
- package/dist-lib/components/user-avatar/fallback.d.ts +5 -0
- package/dist-lib/components/user-avatar/index.d.ts +13 -0
- package/dist-lib/components/user-avatar/type.d.ts +26 -0
- package/dist-lib/components/user-avatar/utils.d.ts +2 -0
- package/dist-lib/index.d.ts +1 -0
- package/dist-lib/index.js +2141 -1139
- package/dist-lib/index.js.map +1 -1
- package/package.json +2 -1
- package/src/components/beste/piece/browser-frame.tsx +9 -6
- package/src/components/blocks/nav/sidebar/__tests__/use-ai-sidebar.test.tsx +310 -0
- package/src/components/blocks/nav/sidebar/ai-sidebar.tsx +90 -60
- package/src/components/blocks/nav/sidebar/type.ts +105 -1
- package/src/components/blocks/nav/sidebar/use-ai-sidebar.ts +293 -116
- package/src/components/blocks/nav/sidebar/utils.ts +28 -0
- package/src/components/blocks/scaffold/__tests__/scaffold.test.tsx +160 -1
- package/src/components/blocks/scaffold/constants.ts +7 -0
- package/src/components/blocks/scaffold/panel-menu-button.tsx +3 -0
- package/src/components/blocks/scaffold/scaffold-canvas.tsx +48 -5
- package/src/components/blocks/scaffold/scaffold-inspector.tsx +3 -2
- package/src/components/blocks/scaffold/scaffold-main.tsx +1 -1
- package/src/components/blocks/scaffold/scaffold-panel.tsx +41 -5
- package/src/components/blocks/scaffold/scaffold-root.tsx +18 -3
- package/src/components/blocks/scaffold/scaffold-sidebar.tsx +1 -1
- package/src/components/blocks/scaffold/scaffold-tab.tsx +45 -7
- package/src/components/blocks/scaffold/type.ts +28 -0
- package/src/components/blocks/scaffold/use-panel-visibility.ts +180 -0
- package/src/components/blocks/scaffold/utils.ts +19 -0
- package/src/components/composed/tree/__tests__/tree.test.tsx +400 -0
- package/src/components/composed/tree/__tests__/use-tree.test.tsx +332 -0
- package/src/components/composed/tree/constants.ts +60 -0
- package/src/components/composed/tree/index.ts +13 -0
- package/src/components/composed/tree/tree-context.ts +13 -0
- package/src/components/composed/tree/tree-node.tsx +451 -0
- package/src/components/composed/tree/tree.tsx +278 -0
- package/src/components/composed/tree/type.ts +212 -0
- package/src/components/composed/tree/use-tree-dnd.ts +148 -0
- package/src/components/composed/tree/use-tree.ts +306 -0
- package/src/components/composed/tree/utils.ts +172 -0
- package/src/components/composed/user-avatar.tsx +4 -1
- package/src/components/docs/component-preview.tsx +11 -11
- package/src/components/user-avatar/audio-wave.tsx +22 -0
- package/src/components/user-avatar/component.tsx +53 -0
- package/src/components/user-avatar/fallback.tsx +26 -0
- package/src/components/user-avatar/index.ts +15 -0
- package/src/components/user-avatar/type.ts +35 -0
- package/src/components/user-avatar/utils.ts +8 -0
- package/src/index.css +211 -153
- package/src/index.ts +1 -0
package/src/index.css
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@import "tailwindcss";
|
|
2
|
-
@import "
|
|
2
|
+
@import "tailwindcss";
|
|
3
|
+
@import "tailwind-animations";
|
|
3
4
|
@import "shadcn/tailwind.css";
|
|
4
5
|
@import "@fontsource-variable/inter";
|
|
5
6
|
@import "@fontsource-variable/figtree";
|
|
@@ -8,149 +9,169 @@
|
|
|
8
9
|
@custom-variant dark (&:is(.dark *));
|
|
9
10
|
|
|
10
11
|
:root {
|
|
11
|
-
|
|
12
|
+
/* Let width/height tween between auto and fixed values (e.g. a button
|
|
12
13
|
toggling to an icon-only size). Progressive enhancement: browsers
|
|
13
14
|
without support keep the instant jump. */
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
15
|
+
interpolate-size: allow-keywords;
|
|
16
|
+
--background: oklch(1 0 0);
|
|
17
|
+
--foreground: oklch(0.145 0 0);
|
|
18
|
+
--card: oklch(1 0 0);
|
|
19
|
+
--card-foreground: oklch(0.145 0 0);
|
|
20
|
+
--popover: oklch(1 0 0);
|
|
21
|
+
--popover-foreground: oklch(0.145 0 0);
|
|
22
|
+
--primary: oklch(0.457 0.24 277.023);
|
|
23
|
+
--primary-foreground: oklch(0.962 0.018 272.314);
|
|
24
|
+
--secondary: oklch(0.967 0.001 286.375);
|
|
25
|
+
--secondary-foreground: oklch(0.21 0.006 285.885);
|
|
26
|
+
--muted: oklch(0.97 0 0);
|
|
27
|
+
--muted-foreground: oklch(0.556 0 0);
|
|
28
|
+
--accent: oklch(0.97 0 0);
|
|
29
|
+
--accent-foreground: oklch(0.205 0 0);
|
|
30
|
+
--destructive: oklch(0.577 0.245 27.325);
|
|
31
|
+
--border: oklch(0.922 0 0);
|
|
32
|
+
--input: oklch(0.922 0 0);
|
|
33
|
+
--ring: oklch(0.708 0 0);
|
|
34
|
+
--chart-1: oklch(0.811 0.111 293.571);
|
|
35
|
+
--chart-2: oklch(0.606 0.25 292.717);
|
|
36
|
+
--chart-3: oklch(0.541 0.281 293.009);
|
|
37
|
+
--chart-4: oklch(0.491 0.27 292.581);
|
|
38
|
+
--chart-5: oklch(0.432 0.232 292.759);
|
|
39
|
+
--radius: 0.875rem;
|
|
40
|
+
--sidebar: oklch(0.985 0 0);
|
|
41
|
+
--sidebar-foreground: oklch(0.145 0 0);
|
|
42
|
+
--sidebar-primary: oklch(0.511 0.262 276.966);
|
|
43
|
+
--sidebar-primary-foreground: oklch(0.962 0.018 272.314);
|
|
44
|
+
--sidebar-accent: oklch(0.97 0 0);
|
|
45
|
+
--sidebar-accent-foreground: oklch(0.205 0 0);
|
|
46
|
+
--sidebar-border: oklch(0.922 0 0);
|
|
47
|
+
--sidebar-ring: oklch(0.708 0 0);
|
|
48
|
+
--destructive-foreground: var(--color-red-700);
|
|
49
|
+
--info: var(--color-blue-500);
|
|
50
|
+
--info-foreground: var(--color-blue-700);
|
|
51
|
+
--success: var(--color-emerald-500);
|
|
52
|
+
--success-foreground: var(--color-emerald-700);
|
|
53
|
+
--warning: var(--color-amber-500);
|
|
54
|
+
--warning-foreground: var(--color-amber-700);
|
|
54
55
|
}
|
|
55
56
|
|
|
56
57
|
.dark {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
58
|
+
--background: oklch(0.145 0 0);
|
|
59
|
+
--foreground: oklch(0.985 0 0);
|
|
60
|
+
--card: oklch(0.205 0 0);
|
|
61
|
+
--card-foreground: oklch(0.985 0 0);
|
|
62
|
+
--popover: oklch(0.205 0 0);
|
|
63
|
+
--popover-foreground: oklch(0.985 0 0);
|
|
64
|
+
--primary: oklch(0.398 0.195 277.366);
|
|
65
|
+
--primary-foreground: oklch(0.962 0.018 272.314);
|
|
66
|
+
--secondary: oklch(0.274 0.006 286.033);
|
|
67
|
+
--secondary-foreground: oklch(0.985 0 0);
|
|
68
|
+
--muted: oklch(0.269 0 0);
|
|
69
|
+
--muted-foreground: oklch(0.708 0 0);
|
|
70
|
+
--accent: oklch(0.269 0 0);
|
|
71
|
+
--accent-foreground: oklch(0.985 0 0);
|
|
72
|
+
--destructive: oklch(0.704 0.191 22.216);
|
|
73
|
+
--border: oklch(1 0 0 / 10%);
|
|
74
|
+
--input: oklch(1 0 0 / 15%);
|
|
75
|
+
--ring: oklch(0.556 0 0);
|
|
76
|
+
--chart-1: oklch(0.811 0.111 293.571);
|
|
77
|
+
--chart-2: oklch(0.606 0.25 292.717);
|
|
78
|
+
--chart-3: oklch(0.541 0.281 293.009);
|
|
79
|
+
--chart-4: oklch(0.491 0.27 292.581);
|
|
80
|
+
--chart-5: oklch(0.432 0.232 292.759);
|
|
81
|
+
--sidebar: oklch(0.205 0 0);
|
|
82
|
+
--sidebar-foreground: oklch(0.985 0 0);
|
|
83
|
+
--sidebar-primary: oklch(0.585 0.233 277.117);
|
|
84
|
+
--sidebar-primary-foreground: oklch(0.962 0.018 272.314);
|
|
85
|
+
--sidebar-accent: oklch(0.269 0 0);
|
|
86
|
+
--sidebar-accent-foreground: oklch(0.985 0 0);
|
|
87
|
+
--sidebar-border: oklch(1 0 0 / 10%);
|
|
88
|
+
--sidebar-ring: oklch(0.556 0 0);
|
|
89
|
+
--destructive-foreground: var(--color-red-400);
|
|
90
|
+
--info: var(--color-blue-500);
|
|
91
|
+
--info-foreground: var(--color-blue-400);
|
|
92
|
+
--success: var(--color-emerald-500);
|
|
93
|
+
--success-foreground: var(--color-emerald-400);
|
|
94
|
+
--warning: var(--color-amber-500);
|
|
95
|
+
--warning-foreground: var(--color-amber-400);
|
|
96
|
+
|
|
97
|
+
.shadow-bezel {
|
|
98
|
+
box-shadow:
|
|
99
|
+
inset 1px 1px 2px rgb(255 255 255 / 0.15),
|
|
100
|
+
inset -2px -2px 4px rgb(0 0 0 / 0.6);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.shadow-debossed {
|
|
104
|
+
box-shadow:
|
|
105
|
+
inset 2px 2px 4px rgb(0 0 0 / 0.6),
|
|
106
|
+
inset -1px -1px 2px rgb(255 255 255 / 0.15);
|
|
107
|
+
}
|
|
95
108
|
}
|
|
96
109
|
|
|
97
110
|
@theme inline {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
111
|
+
/* motion tokens (transitions.dev scale) */
|
|
112
|
+
--ease-smooth-out: cubic-bezier(0.22, 1, 0.36, 1);
|
|
113
|
+
--font-sans: "Inter Variable", sans-serif;
|
|
114
|
+
--font-heading: "Figtree Variable", sans-serif;
|
|
115
|
+
--color-sidebar-ring: var(--sidebar-ring);
|
|
116
|
+
--color-sidebar-border: var(--sidebar-border);
|
|
117
|
+
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
|
|
118
|
+
--color-sidebar-accent: var(--sidebar-accent);
|
|
119
|
+
--color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
|
|
120
|
+
--color-sidebar-primary: var(--sidebar-primary);
|
|
121
|
+
--color-sidebar-foreground: var(--sidebar-foreground);
|
|
122
|
+
--color-sidebar: var(--sidebar);
|
|
123
|
+
--color-chart-5: var(--chart-5);
|
|
124
|
+
--color-chart-4: var(--chart-4);
|
|
125
|
+
--color-chart-3: var(--chart-3);
|
|
126
|
+
--color-chart-2: var(--chart-2);
|
|
127
|
+
--color-chart-1: var(--chart-1);
|
|
128
|
+
--color-ring: var(--ring);
|
|
129
|
+
--color-input: var(--input);
|
|
130
|
+
--color-border: var(--border);
|
|
131
|
+
--color-destructive: var(--destructive);
|
|
132
|
+
--color-accent-foreground: var(--accent-foreground);
|
|
133
|
+
--color-accent: var(--accent);
|
|
134
|
+
--color-muted-foreground: var(--muted-foreground);
|
|
135
|
+
--color-muted: var(--muted);
|
|
136
|
+
--color-secondary-foreground: var(--secondary-foreground);
|
|
137
|
+
--color-secondary: var(--secondary);
|
|
138
|
+
--color-primary-foreground: var(--primary-foreground);
|
|
139
|
+
--color-primary: var(--primary);
|
|
140
|
+
--color-popover-foreground: var(--popover-foreground);
|
|
141
|
+
--color-popover: var(--popover);
|
|
142
|
+
--color-card-foreground: var(--card-foreground);
|
|
143
|
+
--color-card: var(--card);
|
|
144
|
+
--color-foreground: var(--foreground);
|
|
145
|
+
--color-background: var(--background);
|
|
146
|
+
--radius-sm: calc(var(--radius) * 0.6);
|
|
147
|
+
--radius-md: calc(var(--radius) * 0.8);
|
|
148
|
+
--radius-lg: var(--radius);
|
|
149
|
+
--radius-xl: calc(var(--radius) * 1.4);
|
|
150
|
+
--radius-2xl: calc(var(--radius) * 1.8);
|
|
151
|
+
--radius-3xl: calc(var(--radius) * 2.2);
|
|
152
|
+
--radius-4xl: calc(var(--radius) * 2.6);
|
|
153
|
+
--color-destructive-foreground: var(--destructive-foreground);
|
|
141
154
|
@keyframes liquid-drift {
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
}
|
|
148
|
-
100% {
|
|
149
|
-
background-position: 0% 0%, 100% 100%, 0% 0%;
|
|
150
|
-
}
|
|
155
|
+
0% {
|
|
156
|
+
background-position:
|
|
157
|
+
0% 0%,
|
|
158
|
+
100% 100%,
|
|
159
|
+
0% 0%;
|
|
151
160
|
}
|
|
152
|
-
|
|
153
|
-
|
|
161
|
+
50% {
|
|
162
|
+
background-position:
|
|
163
|
+
30% 20%,
|
|
164
|
+
70% 80%,
|
|
165
|
+
0% 0%;
|
|
166
|
+
}
|
|
167
|
+
100% {
|
|
168
|
+
background-position:
|
|
169
|
+
0% 0%,
|
|
170
|
+
100% 100%,
|
|
171
|
+
0% 0%;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
--animate-caret-blink: 1s ease-out infinite caret-blink;
|
|
154
175
|
--animate-input-shake: input-shake 0.4s ease-in-out;
|
|
155
176
|
--animate-skeleton: skeleton 2s -1s infinite linear;
|
|
156
177
|
--color-warning-foreground: var(--warning-foreground);
|
|
@@ -160,35 +181,72 @@
|
|
|
160
181
|
--color-info-foreground: var(--info-foreground);
|
|
161
182
|
--color-info: var(--info);
|
|
162
183
|
@keyframes skeleton {
|
|
163
|
-
to {
|
|
184
|
+
to {
|
|
185
|
+
background-position: -200% 0;
|
|
186
|
+
}
|
|
164
187
|
}
|
|
165
188
|
@keyframes input-shake {
|
|
166
|
-
0%,
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
189
|
+
0%,
|
|
190
|
+
100% {
|
|
191
|
+
translate: 0;
|
|
192
|
+
}
|
|
193
|
+
20% {
|
|
194
|
+
translate: -6px 0;
|
|
195
|
+
}
|
|
196
|
+
40% {
|
|
197
|
+
translate: 6px 0;
|
|
198
|
+
}
|
|
199
|
+
60% {
|
|
200
|
+
translate: -4px 0;
|
|
201
|
+
}
|
|
202
|
+
80% {
|
|
203
|
+
translate: 4px 0;
|
|
204
|
+
}
|
|
171
205
|
}
|
|
172
206
|
@keyframes caret-blink {
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
207
|
+
0%,
|
|
208
|
+
70%,
|
|
209
|
+
to {
|
|
210
|
+
opacity: 1;
|
|
211
|
+
}
|
|
212
|
+
20%,
|
|
213
|
+
50% {
|
|
214
|
+
opacity: 0;
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
180
218
|
|
|
181
219
|
@layer base {
|
|
182
220
|
* {
|
|
183
221
|
@apply border-border outline-ring/50;
|
|
184
|
-
|
|
222
|
+
}
|
|
185
223
|
body {
|
|
186
224
|
@apply bg-background text-foreground;
|
|
187
|
-
|
|
188
|
-
button:not(:disabled),
|
|
225
|
+
}
|
|
226
|
+
button:not(:disabled),
|
|
227
|
+
[role="button"]:not(:disabled) {
|
|
189
228
|
cursor: pointer;
|
|
190
|
-
|
|
229
|
+
}
|
|
191
230
|
html {
|
|
192
231
|
@apply font-sans;
|
|
193
|
-
|
|
194
|
-
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
@utility shadow-bezel {
|
|
236
|
+
/* Inherits light/dark ambient highlights automatically */
|
|
237
|
+
box-shadow:
|
|
238
|
+
inset 1px 1px 2px rgb(255 255 255 / 0.7),
|
|
239
|
+
inset -2px -2px 4px rgb(0 0 0 / 0.25);
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
@utility shadow-debossed {
|
|
243
|
+
box-shadow:
|
|
244
|
+
inset 2px 2px 4px rgb(0 0 0 / 0.25),
|
|
245
|
+
inset -1px -1px 2px rgb(255 255 255 / 0.7);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
@utility shadow-bezel-dynamic {
|
|
249
|
+
box-shadow:
|
|
250
|
+
inset 1px 1px 2px color-mix(in srgb, currentColor 40%, white),
|
|
251
|
+
inset -2px -2px 4px color-mix(in srgb, currentColor 60%, black);
|
|
252
|
+
}
|
package/src/index.ts
CHANGED
|
@@ -26,6 +26,7 @@ export * from "./components/ui/textarea"
|
|
|
26
26
|
// components
|
|
27
27
|
export * from "./components/composed/password-input"
|
|
28
28
|
export * from "./components/composed/social-providers"
|
|
29
|
+
export * from "./components/composed/tree"
|
|
29
30
|
export * from "./components/composed/user-avatar"
|
|
30
31
|
|
|
31
32
|
// blocks
|