@naeil/ui 0.3.0 → 0.5.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 (46) hide show
  1. package/CHANGELOG.md +22 -2
  2. package/DESIGN.md +27 -0
  3. package/README.md +16 -9
  4. package/THIRD_PARTY_NOTICES.md +6 -0
  5. package/dist/chunk-CE73AEJZ.js +667 -0
  6. package/dist/{chunk-QKVN6Q6C.js → chunk-QSTGUEEI.js} +60 -175
  7. package/dist/chunk-S64H3OYQ.js +1512 -0
  8. package/dist/components/index.d.ts +33 -10
  9. package/dist/components/index.js +101 -557
  10. package/dist/components/naeil-header.d.ts +54 -0
  11. package/dist/components/naeil-header.js +14 -0
  12. package/dist/components/ui/index.d.ts +3 -1
  13. package/dist/components/ui/index.js +40 -179
  14. package/dist/navigation-CL10a6Eb.d.ts +48 -0
  15. package/dist/site-footer-B67meCDv.d.ts +21 -0
  16. package/dist/source/components/brand-artwork.generated.d.ts +162 -0
  17. package/dist/source/components/brand-artwork.generated.js +1103 -0
  18. package/dist/source/components/footer.d.ts +13 -4
  19. package/dist/source/components/footer.js +74 -114
  20. package/dist/source/components/index.d.ts +6 -4
  21. package/dist/source/components/locale-switcher.js +1 -1
  22. package/dist/source/components/logo.d.ts +13 -4
  23. package/dist/source/components/logo.js +83 -44
  24. package/dist/source/components/naeil-header-content.d.ts +171 -0
  25. package/dist/source/components/naeil-header-content.js +176 -0
  26. package/dist/source/components/naeil-header.d.ts +52 -0
  27. package/dist/source/components/naeil-header.js +196 -0
  28. package/dist/source/components/nav.d.ts +12 -4
  29. package/dist/source/components/nav.js +51 -384
  30. package/dist/source/components/ui/index.d.ts +2 -0
  31. package/dist/source/components/ui/index.js +4 -0
  32. package/dist/source/components/ui/navigation.d.ts +48 -0
  33. package/dist/source/components/ui/navigation.js +347 -0
  34. package/dist/source/components/ui/site-footer.d.ts +21 -0
  35. package/dist/source/components/ui/site-footer.js +93 -0
  36. package/docs/components/README.md +6 -1
  37. package/docs/components/common.md +1 -1
  38. package/docs/components/naeil-header.md +50 -0
  39. package/docs/components/navigation.md +59 -0
  40. package/docs/design/public-ui-support.md +17 -2
  41. package/docs/design/v2-migration.md +75 -11
  42. package/docs/package-release.md +54 -13
  43. package/licenses/Lato-OFL.txt +93 -0
  44. package/package.json +18 -4
  45. package/src/styles/components.css +292 -0
  46. package/src/styles/theme.css +4 -0
@@ -1,4 +1,296 @@
1
1
  @layer components {
2
+ .ui-navigation {
3
+ position: relative;
4
+ z-index: 40;
5
+ color: var(--foreground);
6
+ background: var(--background);
7
+ border-bottom: 1px solid var(--border);
8
+ }
9
+ /* Branded website chrome is an opt-in composition, independent of app content widths. */
10
+ .naeil-header {
11
+ position: fixed;
12
+ inset-block-start: 0;
13
+ inset-inline: 0;
14
+ width: 100%;
15
+ }
16
+ .naeil-header-frame {
17
+ max-width: 80rem;
18
+ }
19
+ .naeil-header-controls {
20
+ display: flex;
21
+ align-items: center;
22
+ gap: var(--spacing-2-value);
23
+ }
24
+ .ui-navigation-mobile-toolbar > .naeil-header-controls {
25
+ flex-wrap: wrap;
26
+ gap: var(--spacing-4-value);
27
+ }
28
+ .naeil-header-separator {
29
+ flex: none;
30
+ width: 1px;
31
+ height: var(--spacing-4-value);
32
+ background: var(--border);
33
+ }
34
+ .naeil-header-project-icon {
35
+ display: flex;
36
+ align-items: center;
37
+ justify-content: center;
38
+ width: var(--ui-control-height);
39
+ height: var(--ui-control-height);
40
+ border: 1px solid;
41
+ border-radius: var(--radius-lg-value);
42
+ }
43
+ .ui-navigation-frame,
44
+ .ui-site-footer-frame {
45
+ width: 100%;
46
+ margin-inline: auto;
47
+ padding-inline: var(--spacing-6-value);
48
+ }
49
+ .ui-navigation-frame {
50
+ container-type: inline-size;
51
+ }
52
+ .ui-navigation-row {
53
+ display: flex;
54
+ align-items: center;
55
+ gap: var(--spacing-4-value);
56
+ min-height: var(--ui-navigation-height);
57
+ padding-block: var(--spacing-2-value);
58
+ }
59
+ .ui-navigation-brand {
60
+ flex-shrink: 0;
61
+ }
62
+ .ui-navigation-brand a {
63
+ display: inline-flex;
64
+ align-items: center;
65
+ min-height: var(--ui-touch-target);
66
+ }
67
+ .ui-navigation-brand a:focus-visible {
68
+ outline: 2px solid var(--ring);
69
+ outline-offset: 3px;
70
+ }
71
+ .ui-navigation-desktop,
72
+ .ui-navigation-toolbar {
73
+ display: none;
74
+ align-items: center;
75
+ gap: var(--spacing-2-value);
76
+ }
77
+ .ui-navigation-toolbar {
78
+ margin-inline-start: auto;
79
+ }
80
+ .ui-navigation-link {
81
+ display: flex;
82
+ align-items: center;
83
+ gap: var(--spacing-2-value);
84
+ min-height: var(--ui-touch-target);
85
+ min-width: var(--ui-touch-target);
86
+ padding: var(--spacing-2-value) var(--spacing-3-value);
87
+ border-radius: var(--radius-md-value);
88
+ color: var(--foreground);
89
+ font-size: var(--text-base);
90
+ line-height: var(--leading-normal);
91
+ text-align: start;
92
+ text-decoration: none;
93
+ overflow-wrap: anywhere;
94
+ transition: background-color var(--ui-motion-fast);
95
+ }
96
+ .ui-navigation-link:hover {
97
+ background: var(--surface-subtle);
98
+ }
99
+ .ui-navigation-link[aria-current="page"],
100
+ .ui-navigation-link[data-active],
101
+ .ui-navigation-link[data-state="open"] {
102
+ background: var(--surface-selected);
103
+ }
104
+ .ui-navigation-link[aria-current="page"] {
105
+ text-decoration: underline;
106
+ text-underline-offset: 4px;
107
+ }
108
+ .ui-navigation-entry {
109
+ align-items: flex-start;
110
+ gap: var(--spacing-4-value);
111
+ min-height: var(--ui-row-height);
112
+ padding: var(--spacing-3-value);
113
+ }
114
+ .ui-navigation-entry[aria-current="page"] {
115
+ text-decoration: none;
116
+ }
117
+ .ui-navigation-entry[aria-current="page"] .ui-navigation-title {
118
+ font-weight: 600;
119
+ }
120
+ .ui-navigation-title {
121
+ display: flex;
122
+ align-items: center;
123
+ flex-wrap: wrap;
124
+ gap: var(--spacing-2-value);
125
+ font-weight: 500;
126
+ }
127
+ .ui-navigation-copy {
128
+ display: flex;
129
+ flex-direction: column;
130
+ min-width: 0;
131
+ gap: var(--spacing-1-value);
132
+ }
133
+ .ui-navigation-icon {
134
+ flex-shrink: 0;
135
+ }
136
+ .ui-navigation-entry .ui-navigation-icon {
137
+ display: flex;
138
+ align-items: center;
139
+ justify-content: center;
140
+ width: var(--ui-control-height);
141
+ min-height: var(--ui-control-height);
142
+ }
143
+ .ui-navigation-description {
144
+ color: var(--muted-foreground);
145
+ font-size: var(--text-sm);
146
+ }
147
+ .ui-navigation-toggle {
148
+ margin-inline-start: auto;
149
+ justify-content: center;
150
+ }
151
+ .ui-navigation-popover {
152
+ z-index: 50;
153
+ width: var(--ui-navigation-menu-width);
154
+ max-width: min(
155
+ var(--radix-popover-content-available-width),
156
+ calc(100vw - 2 * var(--spacing-4-value))
157
+ );
158
+ max-height: var(--radix-popover-content-available-height);
159
+ overflow-y: auto;
160
+ padding: var(--spacing-4-value);
161
+ color: var(--popover-foreground);
162
+ background: var(--popover);
163
+ border: 1px solid var(--border-strong);
164
+ border-radius: var(--radius-lg-value);
165
+ box-shadow: var(--shadow-md);
166
+ }
167
+ .ui-navigation-popover[data-columns="2"] {
168
+ width: var(--ui-navigation-menu-wide-width);
169
+ }
170
+ .ui-navigation-menu-grid {
171
+ display: grid;
172
+ gap: var(--spacing-2-value);
173
+ }
174
+ .ui-navigation-popover[data-columns="2"] .ui-navigation-menu-grid {
175
+ grid-template-columns: repeat(2, minmax(0, 1fr));
176
+ }
177
+ .ui-navigation-overlay {
178
+ position: fixed;
179
+ inset: 0;
180
+ z-index: 50;
181
+ background: rgb(0 0 0 / 0.6);
182
+ }
183
+ .ui-navigation-sheet {
184
+ position: fixed;
185
+ inset: 0 0 0 auto;
186
+ z-index: 50;
187
+ display: flex;
188
+ flex-direction: column;
189
+ gap: var(--spacing-6-value);
190
+ width: min(100%, var(--ui-width-short-form));
191
+ padding: var(--spacing-6-value);
192
+ overflow-y: auto;
193
+ overscroll-behavior: contain;
194
+ background: var(--background);
195
+ color: var(--foreground);
196
+ }
197
+ .ui-navigation-sheet-heading {
198
+ display: flex;
199
+ align-items: center;
200
+ justify-content: space-between;
201
+ gap: var(--spacing-4-value);
202
+ }
203
+ .ui-navigation-mobile-links {
204
+ display: grid;
205
+ gap: var(--spacing-4-value);
206
+ }
207
+ .ui-navigation-group-label {
208
+ padding: var(--spacing-2-value) var(--spacing-3-value);
209
+ font-size: var(--text-sm);
210
+ font-weight: 600;
211
+ }
212
+ .ui-navigation-mobile-toolbar {
213
+ display: flex;
214
+ flex-wrap: wrap;
215
+ align-items: center;
216
+ gap: var(--spacing-4-value);
217
+ border-top: 1px solid var(--border);
218
+ padding-top: var(--spacing-4-value);
219
+ }
220
+ .ui-navigation-mobile-footer {
221
+ margin-top: auto;
222
+ padding-top: var(--spacing-4-value);
223
+ }
224
+ @container (min-width: 48rem) {
225
+ .ui-navigation-brand {
226
+ width: var(--ui-navigation-brand-width);
227
+ }
228
+ .ui-navigation-desktop,
229
+ .ui-navigation-toolbar {
230
+ display: flex;
231
+ flex-wrap: wrap;
232
+ }
233
+ .ui-navigation-toggle {
234
+ display: none;
235
+ }
236
+ }
237
+ .ui-site-footer {
238
+ border-top: 1px solid var(--border);
239
+ color: var(--foreground);
240
+ background: var(--background);
241
+ }
242
+ .ui-site-footer-frame {
243
+ display: flex;
244
+ flex-wrap: wrap;
245
+ align-items: flex-start;
246
+ gap: var(--spacing-8-value);
247
+ padding-block: var(--spacing-8-value);
248
+ }
249
+ .ui-site-footer-brand {
250
+ display: grid;
251
+ gap: var(--spacing-4-value);
252
+ margin-inline-end: auto;
253
+ }
254
+ .ui-site-footer-description {
255
+ max-width: var(--ui-width-short-form);
256
+ color: var(--muted-foreground);
257
+ font-size: var(--text-sm);
258
+ }
259
+ .ui-site-footer-label {
260
+ font-size: var(--text-sm);
261
+ font-weight: 600;
262
+ margin-bottom: var(--spacing-2-value);
263
+ }
264
+ .ui-site-footer-link {
265
+ display: flex;
266
+ align-items: center;
267
+ min-height: var(--ui-touch-target);
268
+ color: var(--muted-foreground);
269
+ font-size: var(--text-sm);
270
+ text-decoration: none;
271
+ }
272
+ .ui-site-footer-link:hover {
273
+ color: var(--foreground);
274
+ text-decoration: underline;
275
+ }
276
+ .ui-site-footer-meta {
277
+ width: 100%;
278
+ font-size: var(--text-sm);
279
+ color: var(--muted-foreground);
280
+ }
281
+ .ui-site-footer[data-variant="compact"] .ui-site-footer-frame {
282
+ align-items: center;
283
+ padding-block: var(--spacing-4-value);
284
+ gap: var(--spacing-4-value);
285
+ }
286
+ .ui-site-footer[data-variant="compact"] .ui-site-footer-meta {
287
+ width: auto;
288
+ }
289
+ @media (prefers-reduced-motion: reduce) {
290
+ .ui-navigation-link {
291
+ transition: none;
292
+ }
293
+ }
2
294
  .ui-textarea {
3
295
  min-height: var(--ui-control-height);
4
296
  font-size: var(--text-base);
@@ -156,6 +156,10 @@
156
156
  --ui-width-short-form: 480px;
157
157
  --ui-motion-fast: 120ms;
158
158
  --ui-motion-standard: 180ms;
159
+ --ui-navigation-height: 64px;
160
+ --ui-navigation-brand-width: 160px;
161
+ --ui-navigation-menu-width: 320px;
162
+ --ui-navigation-menu-wide-width: 640px;
159
163
  --project-cc: oklch(0.704 0.140 181);
160
164
  --project-sa: oklch(0.723 0.219 149);
161
165
  --project-pkm: oklch(0.627 0.265 303);