@donotdev/ui 0.2.2 → 0.3.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 (199) hide show
  1. package/dist/ChildRowsPicker-63M4EQUQ.js +1 -0
  2. package/dist/ChildRowsPicker-ISP365ON.js +1 -0
  3. package/dist/ChildRowsPicker-PQFE6NCR.js +1 -0
  4. package/dist/ChildRowsPicker-XXFFSMWY.js +1 -0
  5. package/dist/{GoToDialog-CICRYHHG.js → GoToDialog-KSBGOIWO.js} +1 -1
  6. package/dist/{GoToDialog-YGBON6FR.js → GoToDialog-XBK5EZF4.js} +1 -1
  7. package/dist/chunk-3CIZFGST.js +1 -0
  8. package/dist/chunk-LHMKU342.js +1 -0
  9. package/dist/chunk-MS7ZIW5Z.js +1 -0
  10. package/dist/chunk-P2DHZWPY.js +1 -0
  11. package/dist/components/auth/AuthHeader.d.ts.map +1 -1
  12. package/dist/components/auth/AuthHeader.js +0 -2
  13. package/dist/components/auth/AuthMenu.d.ts.map +1 -1
  14. package/dist/components/auth/AuthMenu.js +6 -40
  15. package/dist/components/common/icon.d.ts.map +1 -1
  16. package/dist/components/common/icon.js +2 -1
  17. package/dist/components/common/lucideIconByName.d.ts +9 -0
  18. package/dist/components/common/lucideIconByName.d.ts.map +1 -0
  19. package/dist/components/common/lucideIconByName.js +32 -0
  20. package/dist/components/layout/GameFlow.d.ts.map +1 -1
  21. package/dist/components/layout/components/Breadcrumbs.d.ts.map +1 -1
  22. package/dist/components/layout/components/Breadcrumbs.js +18 -12
  23. package/dist/components/layout/components/header/CacheSettings.d.ts.map +1 -1
  24. package/dist/components/layout/components/header/CacheSettings.js +6 -4
  25. package/dist/components/layout/components/header/SettingsMenu.d.ts.map +1 -1
  26. package/dist/components/layout/components/header/SettingsMenu.js +4 -3
  27. package/dist/components/layout/components/header/ThemeToggle.d.ts.map +1 -1
  28. package/dist/components/layout/components/header/ThemeToggle.js +2 -1
  29. package/dist/crud/components/ChildRowsPicker.d.ts +21 -0
  30. package/dist/crud/components/ChildRowsPicker.d.ts.map +1 -0
  31. package/dist/crud/components/ChildRowsPicker.js +68 -0
  32. package/dist/crud/components/CrudCardLink.d.ts +6 -6
  33. package/dist/crud/components/CrudCardLink.d.ts.map +1 -1
  34. package/dist/crud/components/CrudCardLink.js +3 -9
  35. package/dist/crud/components/EntityCardList.d.ts.map +1 -1
  36. package/dist/crud/components/EntityCardList.js +10 -26
  37. package/dist/crud/components/EntityDisplayRenderer.d.ts.map +1 -1
  38. package/dist/crud/components/EntityDisplayRenderer.js +6 -3
  39. package/dist/crud/components/EntityFormRenderer.d.ts +4 -2
  40. package/dist/crud/components/EntityFormRenderer.d.ts.map +1 -1
  41. package/dist/crud/components/EntityFormRenderer.js +160 -56
  42. package/dist/crud/components/EntityList.d.ts +6 -4
  43. package/dist/crud/components/EntityList.d.ts.map +1 -1
  44. package/dist/crud/components/EntityList.js +437 -92
  45. package/dist/crud/components/EntityRecommendations.js +1 -1
  46. package/dist/crud/components/EntityWorkflow.d.ts.map +1 -1
  47. package/dist/crud/components/EntityWorkflow.js +6 -4
  48. package/dist/crud/components/Form.d.ts +1 -1
  49. package/dist/crud/components/Form.d.ts.map +1 -1
  50. package/dist/crud/components/Form.js +2 -2
  51. package/dist/crud/components/cellEditFor.d.ts +43 -0
  52. package/dist/crud/components/cellEditFor.d.ts.map +1 -0
  53. package/dist/crud/components/cellEditFor.js +74 -0
  54. package/dist/crud/components/entityParent.d.ts +33 -0
  55. package/dist/crud/components/entityParent.d.ts.map +1 -0
  56. package/dist/crud/components/entityParent.js +76 -0
  57. package/dist/crud/components/useRecordBreadcrumb.d.ts +11 -0
  58. package/dist/crud/components/useRecordBreadcrumb.d.ts.map +1 -0
  59. package/dist/crud/components/useRecordBreadcrumb.js +43 -0
  60. package/dist/crud/crudImports.d.ts +12 -1
  61. package/dist/crud/crudImports.d.ts.map +1 -1
  62. package/dist/crud/crudImports.js +11 -0
  63. package/dist/dndev-next.css +782 -193
  64. package/dist/dndev.css +784 -193
  65. package/dist/index.js +4 -4
  66. package/dist/internal/common/RouteErrorFallback.d.ts.map +1 -1
  67. package/dist/internal/common/RouteErrorFallback.js +2 -4
  68. package/dist/internal/devtools/components/ConfigTab.d.ts.map +1 -1
  69. package/dist/internal/devtools/components/ConfigTab.js +1 -1
  70. package/dist/internal/devtools/components/CookieTab.d.ts.map +1 -1
  71. package/dist/internal/devtools/components/CookieTab.js +1 -5
  72. package/dist/internal/devtools/components/DesignTab.d.ts.map +1 -1
  73. package/dist/internal/devtools/components/DesignTab.js +18 -7
  74. package/dist/internal/devtools/components/StoresTab.d.ts.map +1 -1
  75. package/dist/internal/devtools/components/StoresTab.js +17 -3
  76. package/dist/internal/devtools/types.d.ts +3 -3
  77. package/dist/internal/devtools/types.d.ts.map +1 -1
  78. package/dist/internal/devtools/utils/maskSensitive.d.ts +1 -1
  79. package/dist/internal/devtools/utils/maskSensitive.d.ts.map +1 -1
  80. package/dist/internal/initializers/NextJsStoresInitializer.d.ts +3 -0
  81. package/dist/internal/initializers/NextJsStoresInitializer.d.ts.map +1 -1
  82. package/dist/internal/initializers/NextJsStoresInitializer.js +8 -1
  83. package/dist/internal/layout/DnDevLayout.d.ts.map +1 -1
  84. package/dist/internal/layout/DnDevLayout.js +21 -21
  85. package/dist/internal/layout/components/AutoMetaTags.d.ts.map +1 -1
  86. package/dist/internal/layout/components/AutoMetaTags.js +42 -38
  87. package/dist/internal/layout/components/FontPreloadLinks.d.ts +7 -4
  88. package/dist/internal/layout/components/FontPreloadLinks.d.ts.map +1 -1
  89. package/dist/internal/layout/components/FontPreloadLinks.js +12 -25
  90. package/dist/internal/layout/components/footer/FooterCopyright.d.ts +2 -0
  91. package/dist/internal/layout/components/footer/FooterCopyright.d.ts.map +1 -1
  92. package/dist/internal/layout/components/footer/FooterCopyright.js +4 -0
  93. package/dist/internal/layout/components/footer/useLegalLinks.d.ts +2 -1
  94. package/dist/internal/layout/components/footer/useLegalLinks.d.ts.map +1 -1
  95. package/dist/internal/layout/components/footer/useLegalLinks.js +4 -3
  96. package/dist/internal/layout/components/i18nSeoMeta.d.ts.map +1 -1
  97. package/dist/internal/layout/components/i18nSeoMeta.js +1 -0
  98. package/dist/internal/layout/zones/DnDevMergedBar.js +3 -3
  99. package/dist/internal/providers/UIProviders.d.ts +0 -8
  100. package/dist/internal/providers/UIProviders.d.ts.map +1 -1
  101. package/dist/internal/providers/UIProviders.js +45 -2
  102. package/dist/providers/NextJsAppProviders.d.ts +5 -1
  103. package/dist/providers/NextJsAppProviders.d.ts.map +1 -1
  104. package/dist/providers/NextJsAppProviders.js +36 -6
  105. package/dist/providers/ViteAppProviders.d.ts.map +1 -1
  106. package/dist/providers/ViteAppProviders.js +42 -7
  107. package/dist/routing/404.d.ts +8 -1
  108. package/dist/routing/404.d.ts.map +1 -1
  109. package/dist/routing/404.js +9 -5
  110. package/dist/routing/AuthGuardFallback.d.ts.map +1 -1
  111. package/dist/routing/AuthGuardFallback.js +1 -2
  112. package/dist/routing/AuthReturnTo.d.ts.map +1 -1
  113. package/dist/routing/AuthReturnTo.js +9 -2
  114. package/dist/routing/GoTo.d.ts +0 -6
  115. package/dist/routing/GoTo.d.ts.map +1 -1
  116. package/dist/routing/GoTo.js +5 -8
  117. package/dist/routing/Link.d.ts +4 -2
  118. package/dist/routing/Link.d.ts.map +1 -1
  119. package/dist/routing/Link.js +8 -5
  120. package/dist/routing/SignedInRedirect.d.ts +27 -0
  121. package/dist/routing/SignedInRedirect.d.ts.map +1 -0
  122. package/dist/routing/SignedInRedirect.js +47 -0
  123. package/dist/routing/hooks/hooks.next.d.ts +2 -0
  124. package/dist/routing/hooks/hooks.next.d.ts.map +1 -1
  125. package/dist/routing/hooks/hooks.next.js +1 -1
  126. package/dist/routing/hooks/hooks.vite.d.ts +2 -0
  127. package/dist/routing/hooks/hooks.vite.d.ts.map +1 -1
  128. package/dist/routing/hooks/hooks.vite.js +1 -1
  129. package/dist/routing/hooks/useLocation.next.d.ts +12 -0
  130. package/dist/routing/hooks/useLocation.next.d.ts.map +1 -1
  131. package/dist/routing/hooks/useLocation.next.js +17 -4
  132. package/dist/routing/hooks/useMatch.next.d.ts +6 -0
  133. package/dist/routing/hooks/useMatch.next.d.ts.map +1 -1
  134. package/dist/routing/hooks/useMatch.next.js +8 -2
  135. package/dist/routing/hooks/useNavigate.next.d.ts +6 -1
  136. package/dist/routing/hooks/useNavigate.next.d.ts.map +1 -1
  137. package/dist/routing/hooks/useNavigate.next.js +13 -4
  138. package/dist/routing/hooks/useNavigate.vite.d.ts +7 -1
  139. package/dist/routing/hooks/useNavigate.vite.d.ts.map +1 -1
  140. package/dist/routing/hooks/useNavigate.vite.js +20 -4
  141. package/dist/routing/hooks/useRedirectGuard.next.d.ts +3 -1
  142. package/dist/routing/hooks/useRedirectGuard.next.d.ts.map +1 -1
  143. package/dist/routing/hooks/useRedirectGuard.next.js +18 -10
  144. package/dist/routing/hooks/useRedirectGuard.vite.d.ts.map +1 -1
  145. package/dist/routing/hooks/useRedirectGuard.vite.js +7 -1
  146. package/dist/routing/hooks/useRoutePath.next.d.ts +23 -0
  147. package/dist/routing/hooks/useRoutePath.next.d.ts.map +1 -0
  148. package/dist/routing/hooks/useRoutePath.next.js +36 -0
  149. package/dist/routing/hooks/useRoutePath.vite.d.ts +13 -0
  150. package/dist/routing/hooks/useRoutePath.vite.d.ts.map +1 -0
  151. package/dist/routing/hooks/useRoutePath.vite.js +25 -0
  152. package/dist/routing/hooks/useUrlLanguage.next.d.ts +28 -0
  153. package/dist/routing/hooks/useUrlLanguage.next.d.ts.map +1 -0
  154. package/dist/routing/hooks/useUrlLanguage.next.js +50 -0
  155. package/dist/routing/hooks/useUrlLanguage.vite.d.ts +22 -0
  156. package/dist/routing/hooks/useUrlLanguage.vite.d.ts.map +1 -0
  157. package/dist/routing/hooks/useUrlLanguage.vite.js +41 -0
  158. package/dist/routing/index.d.ts +3 -1
  159. package/dist/routing/index.d.ts.map +1 -1
  160. package/dist/routing/index.js +2 -1
  161. package/dist/routing/parentRoute.d.ts +27 -0
  162. package/dist/routing/parentRoute.d.ts.map +1 -0
  163. package/dist/routing/parentRoute.js +43 -0
  164. package/dist/routing/useNavigation.d.ts.map +1 -1
  165. package/dist/routing/useNavigation.js +8 -27
  166. package/dist/routing/useRouteDiscovery.d.ts +2 -2
  167. package/dist/routing/useRouteDiscovery.d.ts.map +1 -1
  168. package/dist/routing/useRouteDiscovery.js +6 -5
  169. package/dist/styles/index.css +781 -192
  170. package/dist/symbol-index.json +1 -1
  171. package/dist/utils/assetResolver.d.ts.map +1 -1
  172. package/dist/utils/assetResolver.js +1 -0
  173. package/dist/utils/index.d.ts +2 -0
  174. package/dist/utils/index.d.ts.map +1 -1
  175. package/dist/utils/index.js +3 -0
  176. package/dist/utils/useDeleteAccountSafe.d.ts +17 -0
  177. package/dist/utils/useDeleteAccountSafe.d.ts.map +1 -0
  178. package/dist/utils/useDeleteAccountSafe.js +52 -0
  179. package/dist/utils/useFormStoreSafe.d.ts.map +1 -1
  180. package/dist/utils/useFormStoreSafe.js +1 -0
  181. package/dist/utils/useSeo.d.ts +10 -2
  182. package/dist/utils/useSeo.d.ts.map +1 -1
  183. package/dist/utils/useSeo.js +44 -9
  184. package/dist/vite-routing/AppRoutes.d.ts.map +1 -1
  185. package/dist/vite-routing/AppRoutes.js +37 -4
  186. package/guidelines/COMPONENTS.md +2 -1
  187. package/guidelines/GOTCHAS.md +2 -0
  188. package/guidelines/LAYOUTS.md +4 -0
  189. package/guidelines/PAGES.md +30 -3
  190. package/guidelines/ROUTING.md +29 -0
  191. package/guidelines/SEO.md +52 -0
  192. package/package.json +9 -9
  193. package/dist/CookieConsent-5NH5DNTP.js +0 -1
  194. package/dist/CookieConsent-W7UE647Y.js +0 -1
  195. package/dist/chunk-DRFM6WXH.js +0 -1
  196. package/dist/chunk-MIPTBUWY.js +0 -1
  197. package/dist/internal/layout/components/NextJsAutoMetaTags.d.ts +0 -57
  198. package/dist/internal/layout/components/NextJsAutoMetaTags.d.ts.map +0 -1
  199. package/dist/internal/layout/components/NextJsAutoMetaTags.js +0 -182
package/dist/dndev.css CHANGED
@@ -63,9 +63,7 @@
63
63
  * applies regardless of density tier.
64
64
  */
65
65
  --gap-none: 0;
66
- --gap-sm: min(0.5rem, 2vw); /* 8px or 2vw, whichever is smaller */
67
- --gap-md: min(1rem, 2vw); /* 16px or 2vw */
68
- --gap-lg: min(2rem, 2vw); /* 32px or 2vw */
66
+ /* --gap-sm / --gap-md / --gap-lg: see DENSITY SYSTEM below */
69
67
 
70
68
  /* ===========================
71
69
  DIALOG SIZE VARIANTS
@@ -192,14 +190,7 @@
192
190
  /* Typography Scale - Musical Scale System (STANDARD density defaults - Major Third 1.25×) */
193
191
  --font-size-xs: 0.75rem; /* 12px - captions, shortcuts, meta */
194
192
  --font-size-sm: 0.875rem; /* 14px - small text, captions */
195
- --font-size-base: 1rem; /* 16px - body text, DEFAULT */
196
- --font-size-lg: 1.25rem; /* 20px - base × 1.25¹ - emphasized text */
197
- --font-size-xl: 1.563rem; /* 25px - base × 1.25² - headings */
198
- --font-size-2xl: 1.953rem; /* 31px - base × 1.25³ - large headings */
199
- --font-size-3xl: 2.441rem; /* 39px - base × 1.25⁴ - hero text */
200
-
201
- /* Line Height - Musical Scale System (matches font scale ratio) */
202
- --line-height: 1.25; /* Major Third - Standard density default */
193
+ /* --font-size-base…3xl and --line-height: see DENSITY SYSTEM below */
203
194
 
204
195
  /* Font Weight - Semantic weights */
205
196
  --font-weight-normal: 400;
@@ -331,12 +322,36 @@
331
322
 
332
323
  /* ===========================
333
324
  DENSITY SYSTEM
334
- Semantic spacing and typography presets based on context
335
- Applied via [data-density] attribute on root or container
325
+ Semantic spacing and typography presets based on context.
326
+
327
+ App density: the layout wrapper (.dndev-layout) carries data-density in the
328
+ server HTML, and the tokens are declared on <html> from it (:has), so they
329
+ resolve on the first paint, before and without hydration.
330
+ Nested density: PageContainer / List set data-density on their own element.
331
+
332
+ The tokens are never declared on .dndev-layout itself: every element of the
333
+ app sits under it, so a declaration there would shadow the app's :root
334
+ overrides (themes.css). The <html> rules carry zero specificity (:where), so
335
+ an app :root override wins whatever the stylesheet order.
336
336
  =========================== */
337
337
 
338
+ /* Base values (standard density), used until a density applies */
339
+ :where(:root) {
340
+ --gap-sm: min(0.5rem, 2vw); /* 8px or 2vw, whichever is smaller */
341
+ --gap-md: min(1rem, 2vw); /* 16px or 2vw */
342
+ --gap-lg: min(2rem, 2vw); /* 32px or 2vw */
343
+ --font-size-base: 1rem; /* 16px - body text, DEFAULT */
344
+ --font-size-lg: 1.25rem; /* 20px - base × 1.25¹ - emphasized text */
345
+ --font-size-xl: 1.563rem; /* 25px - base × 1.25² - headings */
346
+ --font-size-2xl: 1.953rem; /* 31px - base × 1.25³ - large headings */
347
+ --font-size-3xl: 2.441rem; /* 39px - base × 1.25⁴ - hero text */
348
+ /* Line Height - Musical Scale System (matches font scale ratio) */
349
+ --line-height: 1.25; /* Major Third - Standard density default */
350
+ }
351
+
338
352
  /* Compact (Admin/Data) - Dense, information-dense layouts - Minor Third (1.2×) */
339
- [data-density='compact'] {
353
+ :where(:root:has(.dndev-layout[data-density='compact'])),
354
+ [data-density='compact']:where(:not(.dndev-layout)) {
340
355
  /* Base sizes: Fluid responsiveness for all text, zoom-safe */
341
356
  --font-size-base: clamp(
342
357
  0.875rem,
@@ -376,7 +391,8 @@
376
391
  }
377
392
 
378
393
  /* Standard (Docs/SaaS) - DEFAULT, balanced for readability */
379
- [data-density='standard'] {
394
+ :where(:root:has(.dndev-layout[data-density='standard'])),
395
+ [data-density='standard']:where(:not(.dndev-layout)) {
380
396
  /* Base sizes: Fluid responsiveness for all text, zoom-safe */
381
397
  --font-size-base: clamp(
382
398
  1rem,
@@ -416,7 +432,8 @@
416
432
  }
417
433
 
418
434
  /* Expressive (Marketing) - Perfect Fourth (1.333×) + Fluid typography (2025 best practice) */
419
- [data-density='expressive'] {
435
+ :where(:root:has(.dndev-layout[data-density='expressive'])),
436
+ [data-density='expressive']:where(:not(.dndev-layout)) {
420
437
  /* Base sizes: Fluid responsiveness for all text, zoom-safe */
421
438
  --font-size-base: clamp(1rem, 0.875rem + 0.5vw, 1.125rem); /* 16-18px fluid */
422
439
  --font-size-lg: clamp(1.25rem, 1rem + 0.75vw, 1.5rem); /* 20-24px fluid */
@@ -448,9 +465,9 @@
448
465
  }
449
466
 
450
467
  /* Form field text: follows density, never below 16px (iOS focus zoom).
451
- Declared on [data-density] too, so nested densities resolve their own base. */
452
- :root,
453
- [data-density] {
468
+ Declared on nested [data-density] too, so they resolve their own base. */
469
+ :where(:root),
470
+ [data-density]:where(:not(.dndev-layout)) {
454
471
  --font-size-input: max(16px, var(--font-size-base));
455
472
  }
456
473
  /* 2. Theme system - color palette definitions */
@@ -3333,7 +3350,7 @@ em {
3333
3350
  display: inline-flex;
3334
3351
  align-items: center;
3335
3352
  justify-content: center;
3336
- padding: var(--gap-tight) 1px;
3353
+ padding: var(--gap-sm) 1px;
3337
3354
  border-radius: 2px;
3338
3355
  font-variant-numeric: tabular-nums;
3339
3356
  caret-color: transparent;
@@ -3714,6 +3731,50 @@ em {
3714
3731
  background: var(--card);
3715
3732
  }
3716
3733
 
3734
+ /* href: stretched link. The title is the <a href>; its ::after covers the whole
3735
+ card so the tile is clickable, while controls inside stay above it. The body
3736
+ must not be the containing block, or the hit area would stop at the cover. */
3737
+ .dndev-card[data-has-link='true'] > .dndev-card-body {
3738
+ position: static;
3739
+ }
3740
+
3741
+ .dndev-card-link {
3742
+ color: inherit;
3743
+ text-decoration: none;
3744
+ }
3745
+
3746
+ .dndev-card-link::after {
3747
+ content: '';
3748
+ position: absolute;
3749
+ inset: 0;
3750
+ z-index: 1;
3751
+ border-radius: inherit;
3752
+ }
3753
+
3754
+ .dndev-card-link:focus-visible {
3755
+ outline: none;
3756
+ }
3757
+
3758
+ .dndev-card[data-has-link='true']:has(.dndev-card-link:focus-visible) {
3759
+ outline: 2px solid var(--ring);
3760
+ outline-offset: 2px;
3761
+ }
3762
+
3763
+ .dndev-card[data-has-link='true']
3764
+ :is(
3765
+ a,
3766
+ button,
3767
+ input,
3768
+ select,
3769
+ textarea,
3770
+ label,
3771
+ [role='button'],
3772
+ [tabindex]
3773
+ ):not(.dndev-card-link) {
3774
+ position: relative;
3775
+ z-index: 2;
3776
+ }
3777
+
3717
3778
  /* Card body children spacing */
3718
3779
  .dndev-card-header {
3719
3780
  display: flex;
@@ -3778,7 +3839,8 @@ em {
3778
3839
 
3779
3840
  /* Contain: whole image visible on the muted cover background (cut-outs), inset
3780
3841
  proportionally so a packshot never touches the frame. */
3781
- .dndev-card-cover[data-fit='contain'] > img:not(.dndev-card-cover-hover) {
3842
+ .dndev-card-cover[data-fit='contain'] > img:not(.dndev-card-cover-hover),
3843
+ .dndev-card-cover[data-fit='contain'] > picture > img:not(.dndev-card-cover-hover) {
3782
3844
  -o-object-fit: contain;
3783
3845
  object-fit: contain;
3784
3846
  box-sizing: border-box;
@@ -3786,7 +3848,9 @@ em {
3786
3848
  }
3787
3849
 
3788
3850
  /* Hover view: stacked over the cover, crossfades in on hover / keyboard focus. */
3789
- .dndev-card-cover > img.dndev-card-cover-hover {
3851
+ /* An image pair renders <picture><img>: the <img> carries the class either way. */
3852
+ .dndev-card-cover > img.dndev-card-cover-hover,
3853
+ .dndev-card-cover > picture > img.dndev-card-cover-hover {
3790
3854
  position: absolute;
3791
3855
  inset: 0;
3792
3856
  -o-object-fit: cover;
@@ -3809,7 +3873,8 @@ em {
3809
3873
  }
3810
3874
 
3811
3875
  @media (prefers-reduced-motion: reduce) {
3812
- .dndev-card-cover > img.dndev-card-cover-hover {
3876
+ .dndev-card-cover > img.dndev-card-cover-hover,
3877
+ .dndev-card-cover > picture > img.dndev-card-cover-hover {
3813
3878
  transition: none;
3814
3879
  }
3815
3880
  }
@@ -4011,6 +4076,16 @@ em {
4011
4076
  transition: opacity var(--dur-fast) var(--ease-in-out);
4012
4077
  }
4013
4078
 
4079
+ /* <button> the component renders (showIcon, or non-element trigger): strip UA chrome */
4080
+ .dndev-collapsible-trigger--button {
4081
+ background: none;
4082
+ border: none;
4083
+ padding: 0;
4084
+ font: inherit;
4085
+ color: inherit;
4086
+ text-align: start;
4087
+ }
4088
+
4014
4089
  .dndev-collapsible-trigger:hover {
4015
4090
  opacity: var(--opacity-strong);
4016
4091
  }
@@ -4174,7 +4249,7 @@ em {
4174
4249
  height: 100%;
4175
4250
  display: flex;
4176
4251
  align-items: center;
4177
- gap: var(--gap-tight, 4px);
4252
+ gap: 4px; /* 4px: tighter than --gap-sm (8px), the smallest gap token; must match computeTrailingPad() in index.tsx */
4178
4253
  z-index: 1;
4179
4254
  pointer-events: none; /* pass clicks through to input by default */
4180
4255
  }
@@ -4237,10 +4312,10 @@ em {
4237
4312
  display: flex;
4238
4313
  flex-wrap: wrap;
4239
4314
  align-items: center;
4240
- gap: var(--gap-tight, 4px);
4315
+ gap: 4px; /* 4px: tighter than --gap-sm (8px), the smallest gap token */
4241
4316
  border: var(--border-hairline) solid var(--line-2);
4242
4317
  border-radius: var(--radius-interactive);
4243
- padding: var(--gap-tight, 4px);
4318
+ padding: 4px; /* 4px: tighter than --gap-sm (8px), the smallest gap token */
4244
4319
  padding-inline-end: var(--combobox-pad-end);
4245
4320
  min-height: var(--touch-target);
4246
4321
  cursor: text;
@@ -4265,7 +4340,7 @@ em {
4265
4340
  flex: 1 1 80px;
4266
4341
  min-width: 80px;
4267
4342
  height: auto;
4268
- padding: var(--gap-tight, 4px) var(--gap-sm);
4343
+ padding: 4px var(--gap-sm); /* 4px: tighter than --gap-sm (8px), the smallest gap token */
4269
4344
  }
4270
4345
 
4271
4346
  /* ──────────────────────────────────────────────────
@@ -4312,7 +4387,7 @@ em {
4312
4387
  .dndev-combobox-option-content {
4313
4388
  display: flex;
4314
4389
  flex-direction: column;
4315
- gap: var(--gap-tight);
4390
+ gap: var(--gap-sm);
4316
4391
  flex: 1;
4317
4392
  }
4318
4393
 
@@ -4329,7 +4404,7 @@ em {
4329
4404
  .dndev-combobox-option-count {
4330
4405
  font-size: var(--font-size-xs);
4331
4406
  color: var(--muted-foreground);
4332
- margin-inline-start: var(--gap-tight);
4407
+ margin-inline-start: var(--gap-sm);
4333
4408
  flex-shrink: 0;
4334
4409
  }
4335
4410
 
@@ -5439,6 +5514,17 @@ em {
5439
5514
  outline: none;
5440
5515
  }
5441
5516
 
5517
+ /* Gallery pictures are always protected (with blockContextMenu + draggable=false):
5518
+ no drag, no iOS long-press "Save image" callout, no selection. */
5519
+ .image-gallery img,
5520
+ .image-gallery__lightbox-stage img {
5521
+ -webkit-touch-callout: none;
5522
+ -webkit-user-drag: none;
5523
+ -webkit-user-select: none;
5524
+ -moz-user-select: none;
5525
+ user-select: none;
5526
+ }
5527
+
5442
5528
  .image-gallery:focus-visible {
5443
5529
  outline: 2px solid var(--primary);
5444
5530
  outline-offset: 2px;
@@ -5472,13 +5558,57 @@ em {
5472
5558
  cursor: zoom-in;
5473
5559
  }
5474
5560
 
5475
- .image-gallery__main-image {
5561
+ /* Swipeable strip (main view and lightbox): native scrolling, one slide per snap point */
5562
+ .image-gallery__strip {
5563
+ /* Offset parent of the slides: a slide's offsetLeft is its scroll offset */
5564
+ position: relative;
5565
+ display: flex;
5566
+ height: 100%;
5567
+ overflow-x: auto;
5568
+ overflow-y: hidden;
5569
+ scroll-snap-type: x mandatory;
5570
+ overscroll-behavior-x: contain;
5571
+ scrollbar-width: none;
5572
+ }
5573
+
5574
+ .image-gallery__strip::-webkit-scrollbar {
5575
+ display: none;
5576
+ }
5577
+
5578
+ /* Arrow / thumbnail / key navigation glides to a neighbour (never a touch swipe) */
5579
+ @media (prefers-reduced-motion: no-preference) {
5580
+ .image-gallery__strip {
5581
+ scroll-behavior: smooth;
5582
+ }
5583
+ }
5584
+
5585
+ .image-gallery__slide {
5586
+ position: relative;
5587
+ flex: 0 0 100%;
5588
+ height: 100%;
5589
+ scroll-snap-align: start;
5590
+ scroll-snap-stop: always;
5591
+ }
5592
+
5593
+ .image-gallery__slide-img {
5594
+ position: absolute;
5595
+ inset: 0;
5596
+ display: block;
5476
5597
  width: 100%;
5477
5598
  height: 100%;
5478
5599
  -o-object-fit: cover;
5479
5600
  object-fit: cover;
5480
- display: block;
5481
- position: relative;
5601
+ -webkit-user-select: none;
5602
+ -moz-user-select: none;
5603
+ user-select: none;
5604
+ -webkit-user-drag: none;
5605
+ }
5606
+
5607
+ .image-gallery__slide-img[data-fit='contain'] {
5608
+ -o-object-fit: contain;
5609
+ object-fit: contain;
5610
+ box-sizing: border-box;
5611
+ padding: 6%;
5482
5612
  }
5483
5613
 
5484
5614
  /* Navigation arrows */
@@ -5597,38 +5727,186 @@ em {
5597
5727
  }
5598
5728
  }
5599
5729
 
5600
- /* Lightbox (full-size image dialog) */
5730
+ /* Lightbox: full-screen dialog, the viewer owns every gesture */
5601
5731
  .image-gallery__lightbox.dndev-modal-content {
5602
- max-width: min(96vw, 1400px);
5603
- max-height: 96dvh;
5604
- padding: var(--gap-sm);
5732
+ inset: 0;
5733
+ transform: none;
5734
+ width: 100vw;
5735
+ height: 100dvh;
5736
+ max-width: none;
5737
+ max-height: none;
5738
+ display: block;
5739
+ padding: 0;
5740
+ border: none;
5741
+ border-radius: 0;
5742
+ box-shadow: none;
5743
+ background: transparent;
5744
+ /* Fade only: the dialog keyframes translate a centred box */
5745
+ animation-name: overlay-in;
5605
5746
  }
5747
+ .image-gallery__lightbox.dndev-modal-content[data-state='closed'] {
5748
+ animation-name: overlay-out;
5749
+ }
5750
+ .image-gallery__lightbox.dndev-modal-content .dndev-modal-close {
5751
+ z-index: 4;
5752
+ opacity: 1;
5753
+ }
5606
5754
 
5607
5755
  .image-gallery__lightbox .dndev-modal-body {
5756
+ position: absolute;
5757
+ inset: 0;
5608
5758
  padding: 0;
5609
- display: flex;
5610
- align-items: center;
5611
- justify-content: center;
5612
5759
  overflow: hidden;
5613
- min-height: 40dvh;
5614
5760
  }
5615
5761
 
5616
- .image-gallery__lightbox-body {
5617
- position: relative;
5762
+ .image-gallery__lightbox-stage {
5763
+ position: absolute;
5764
+ inset: 0;
5765
+ overflow: hidden;
5766
+ outline: none;
5767
+ -webkit-user-select: none;
5768
+ -moz-user-select: none;
5769
+ user-select: none;
5770
+ }
5771
+
5772
+ /* Opaque layer behind the slides. The close drag fades it with opacity (composited);
5773
+ never animate its colour, that repaints the whole screen every frame. */
5774
+ .image-gallery__lightbox-backdrop {
5775
+ position: absolute;
5776
+ inset: 0;
5777
+ background-color: var(--background);
5778
+ will-change: opacity;
5779
+ }
5780
+
5781
+ /* pan-x: the browser pages; vertical drags and pinches reach the gesture code */
5782
+ .image-gallery__lightbox-strip {
5783
+ touch-action: pan-x;
5784
+ }
5785
+
5786
+ /* Zoomed: no paging, a drag pans the image */
5787
+ .image-gallery__lightbox-stage[data-zoomed] .image-gallery__lightbox-strip {
5788
+ touch-action: none;
5789
+ }
5790
+
5791
+ .image-gallery__lightbox-slide {
5618
5792
  display: flex;
5619
5793
  align-items: center;
5620
5794
  justify-content: center;
5795
+ box-sizing: border-box;
5796
+ padding: var(--gap-md);
5797
+ /* The frame sizes itself against the slide's content box (cq units) */
5798
+ container-type: size;
5799
+ }
5800
+
5801
+ /* Box of one image. Until its aspect ratio is known it fills the slide (the images are
5802
+ `contain`, so they look the same); then it is exactly the fitted image: the zoom, pan,
5803
+ hit-test and open / close morph target. */
5804
+ .image-gallery__lightbox-frame {
5805
+ position: relative;
5806
+ flex: none;
5621
5807
  width: 100%;
5622
- outline: none;
5808
+ height: 100%;
5809
+ cursor: zoom-in;
5623
5810
  }
5624
5811
 
5625
- .image-gallery__lightbox-img {
5626
- max-width: 100%;
5627
- max-height: 85dvh;
5628
- width: auto;
5812
+ .image-gallery__lightbox-frame[data-sized] {
5813
+ width: min(100cqw, 100cqh * var(--image-ratio));
5629
5814
  height: auto;
5815
+ aspect-ratio: var(--image-ratio);
5816
+ }
5817
+
5818
+ /* Full image over its cached thumbnail: never an empty slide while it downloads */
5819
+ .image-gallery__lightbox-frame > img {
5820
+ position: absolute;
5821
+ inset: 0;
5822
+ display: block;
5823
+ width: 100%;
5824
+ height: 100%;
5630
5825
  -o-object-fit: contain;
5631
5826
  object-fit: contain;
5827
+ -webkit-user-drag: none;
5828
+ }
5829
+
5830
+ .image-gallery__lightbox-frame[data-loaded] > .image-gallery__lightbox-placeholder {
5831
+ visibility: hidden;
5832
+ }
5833
+
5834
+ /* Own layer only for what a gesture moves: the dragged slide, the zoomed image */
5835
+ .image-gallery__lightbox-stage[data-closing]
5836
+ .image-gallery__lightbox-slide:not([aria-hidden]) {
5837
+ will-change: translate;
5838
+ }
5839
+
5840
+ .image-gallery__lightbox-stage[data-zoomed]
5841
+ .image-gallery__lightbox-slide:not([aria-hidden])
5842
+ > .image-gallery__lightbox-frame {
5843
+ will-change: transform;
5844
+ cursor: grab;
5845
+ }
5846
+
5847
+ .image-gallery__lightbox-stage[data-zoomed]:active
5848
+ .image-gallery__lightbox-frame {
5849
+ cursor: grabbing;
5850
+ }
5851
+
5852
+ /* Settles (snap back, double-tap / click zoom) are transitions, off during a gesture */
5853
+ @media (prefers-reduced-motion: no-preference) {
5854
+ .image-gallery__lightbox-stage[data-settle]
5855
+ :is(
5856
+ .image-gallery__lightbox-backdrop,
5857
+ .image-gallery__lightbox-slide,
5858
+ .image-gallery__lightbox-frame
5859
+ ) {
5860
+ transition-property: opacity, translate, transform;
5861
+ transition-duration: var(--dur-normal);
5862
+ transition-timing-function: var(--ease-heavy);
5863
+ }
5864
+
5865
+ /* Pan glide after a fling: a long deceleration. GLIDE_MS in lightboxGestures.ts
5866
+ projects the end point from these two tokens; keep them in step. */
5867
+ .image-gallery__lightbox-stage[data-settle='momentum']
5868
+ .image-gallery__lightbox-frame {
5869
+ transition-duration: var(--dur-slow);
5870
+ }
5871
+ }
5872
+
5873
+ /* Open / close morph: the tapped image grows into the lightbox and shrinks back
5874
+ (same-document view transition, run by the browser on the compositor). */
5875
+ ::view-transition-group(image-gallery-image) {
5876
+ animation-duration: var(--dur-normal);
5877
+ animation-timing-function: var(--ease-heavy);
5878
+ }
5879
+
5880
+ ::view-transition-old(image-gallery-image),
5881
+ ::view-transition-new(image-gallery-image) {
5882
+ height: 100%;
5883
+ -o-object-fit: cover;
5884
+ object-fit: cover;
5885
+ overflow: clip;
5886
+ }
5887
+
5888
+ /* With the morph, the view transition animates open / close: the dialog's own
5889
+ fade would run on top of it. Same conditions as `canMorph` in ImageGallery.tsx. */
5890
+ @supports (view-transition-name: none) {
5891
+ @media (prefers-reduced-motion: no-preference) {
5892
+ .image-gallery__lightbox.dndev-modal-content[data-state],
5893
+ .dndev-overlay[data-state]:has(+ .image-gallery__lightbox) {
5894
+ animation: none;
5895
+ }
5896
+ }
5897
+ }
5898
+
5899
+ .image-gallery__lightbox-counter {
5900
+ position: absolute;
5901
+ top: var(--gap-md);
5902
+ inset-inline-start: var(--gap-md);
5903
+ z-index: 3;
5904
+ padding: calc(var(--gap-sm) / 2) var(--gap-sm);
5905
+ border-radius: var(--radius-full);
5906
+ background-color: var(--card);
5907
+ color: var(--foreground);
5908
+ font-size: var(--font-size-sm);
5909
+ font-variant-numeric: tabular-nums;
5632
5910
  }
5633
5911
 
5634
5912
  .image-gallery__lightbox-nav {
@@ -5636,6 +5914,12 @@ em {
5636
5914
  z-index: 3;
5637
5915
  }
5638
5916
 
5917
+ /* Touch: swipe pages, so arrows are noise */
5918
+ @media (pointer: coarse) {
5919
+ .image-gallery__lightbox-nav {
5920
+ display: none;
5921
+ }
5922
+ }
5639
5923
  /* packages/components/src/atomic/Input/Input.css */
5640
5924
 
5641
5925
  /* Hide number input spinners - cleaner UI for price/range inputs */
@@ -5903,13 +6187,56 @@ input[type='number'] {
5903
6187
  cursor: default;
5904
6188
  display: inline-flex;
5905
6189
  align-items: center;
5906
- gap: var(--gap-tight);
6190
+ gap: var(--gap-sm);
5907
6191
  }
5908
6192
 
5909
6193
  .dndev-floating-fieldset[data-disabled='true'] .dndev-floating-legend {
5910
6194
  color: var(--muted-foreground);
5911
6195
  }
5912
6196
 
6197
+ /* Help (i) after the label: the label truncates, the button never does */
6198
+ .dndev-floating-legend[data-info] {
6199
+ display: flex;
6200
+ align-items: center;
6201
+ gap: calc(var(--gap-sm) / 2);
6202
+ }
6203
+
6204
+ .dndev-floating-legend[data-info] > label {
6205
+ display: block;
6206
+ min-width: 0;
6207
+ overflow: hidden;
6208
+ text-overflow: ellipsis;
6209
+ }
6210
+
6211
+ .dndev-field-info {
6212
+ display: inline-flex;
6213
+ flex-shrink: 0;
6214
+ align-items: center;
6215
+ justify-content: center;
6216
+ /* Larger hit area than the icon, without growing the legend */
6217
+ padding: calc(var(--gap-sm) / 2);
6218
+ margin: calc(var(--gap-sm) / -2);
6219
+ border: none;
6220
+ border-radius: var(--radius-full);
6221
+ background: none;
6222
+ color: var(--muted-foreground);
6223
+ cursor: help;
6224
+ }
6225
+
6226
+ .dndev-field-info:hover,
6227
+ .dndev-field-info:focus-visible {
6228
+ color: var(--foreground);
6229
+ }
6230
+
6231
+ .dndev-field-info:focus-visible {
6232
+ outline: var(--border-hairline) solid var(--ring);
6233
+ }
6234
+
6235
+ .dndev-field-info svg {
6236
+ width: 1.25em;
6237
+ height: 1.25em;
6238
+ }
6239
+
5913
6240
  /* Disable truncation when explicitly set to false */
5914
6241
  .dndev-floating-legend[data-truncate='false'] {
5915
6242
  max-width: none;
@@ -6229,7 +6556,7 @@ input[type='number'] {
6229
6556
  /* packages/components/src/atomic/PasswordInput/PasswordInput.css */
6230
6557
 
6231
6558
  .dndev-password-input-with-toggle {
6232
- padding-inline-end: calc(var(--gap-xl) + var(--gap-md)) !important;
6559
+ padding-inline-end: calc(var(--gap-lg) + var(--gap-md)) !important;
6233
6560
  }
6234
6561
 
6235
6562
  /* Eye icon toggle - ALWAYS at end, cannot be overridden */
@@ -6242,7 +6569,7 @@ input[type='number'] {
6242
6569
  background: none !important;
6243
6570
  border: none !important;
6244
6571
  cursor: pointer !important;
6245
- padding: var(--gap-tight) !important;
6572
+ padding: var(--gap-sm) !important;
6246
6573
  display: flex !important;
6247
6574
  align-items: center !important;
6248
6575
  opacity: var(--opacity-muted) !important;
@@ -6303,7 +6630,7 @@ input[type='number'] {
6303
6630
  background: none;
6304
6631
  border: none;
6305
6632
  cursor: pointer;
6306
- padding: var(--gap-tight, 0.25rem);
6633
+ padding: 0.25rem; /* 4px: tighter than --gap-sm (8px), the smallest gap token */
6307
6634
  margin-inline-start: var(--gap-sm, 0.5rem);
6308
6635
  display: inline-flex;
6309
6636
  align-items: center;
@@ -6628,7 +6955,7 @@ input[type='number'] {
6628
6955
  }
6629
6956
 
6630
6957
  .dndev-range-input-separator {
6631
- padding-inline: var(--gap-tight);
6958
+ padding-inline: var(--gap-sm);
6632
6959
  }
6633
6960
 
6634
6961
  /* packages/components/src/atomic/Rating/Rating.css */
@@ -8122,6 +8449,107 @@ input[type='number'] {
8122
8449
  min-width: var(--touch-target);
8123
8450
  }
8124
8451
 
8452
+ .dndev-swipe-action {
8453
+ --swipe-action-width: 5.5rem;
8454
+ display: flex;
8455
+ min-inline-size: 0;
8456
+ }
8457
+
8458
+ .dndev-swipe-action-viewport {
8459
+ display: flex;
8460
+ flex: 1;
8461
+ min-inline-size: 0;
8462
+ overflow-x: auto;
8463
+ overflow-y: hidden;
8464
+ scroll-snap-type: x mandatory;
8465
+ overscroll-behavior-x: contain;
8466
+ scrollbar-width: none;
8467
+ touch-action: pan-x pan-y pinch-zoom;
8468
+ }
8469
+
8470
+ .dndev-swipe-action-viewport::-webkit-scrollbar {
8471
+ display: none;
8472
+ }
8473
+
8474
+ .dndev-swipe-action[data-disabled] .dndev-swipe-action-viewport,
8475
+ .dndev-swipe-action-viewport[data-input-blocked] {
8476
+ overflow-x: hidden;
8477
+ }
8478
+
8479
+ .dndev-swipe-action-content {
8480
+ flex: 0 0 100%;
8481
+ min-inline-size: 0;
8482
+ min-block-size: 44px;
8483
+ scroll-snap-align: start;
8484
+ background: var(--background);
8485
+ }
8486
+
8487
+ /* Scope to descendants, never a focusable cart/list ancestor. Touch-action is
8488
+ resolved before pointerdown, so controls cannot start horizontal scrolling. */
8489
+ .dndev-swipe-action-content :is(
8490
+ button, a, input, textarea, select, label, summary, [tabindex],
8491
+ [contenteditable]:not([contenteditable="false"]), [draggable="true"],
8492
+ [role="button"], [role="link"], [role="checkbox"], [role="switch"],
8493
+ [role="radio"], [role="slider"], [role="spinbutton"], [role="textbox"],
8494
+ [role="combobox"], [role="searchbox"], [role="menuitem"],
8495
+ [role="menuitemcheckbox"], [role="menuitemradio"], [role="option"],
8496
+ [role="tab"], [role="treeitem"]
8497
+ ) {
8498
+ touch-action: pan-y pinch-zoom;
8499
+ }
8500
+
8501
+ .dndev-swipe-action-toggle,
8502
+ .dndev-swipe-action-delete {
8503
+ display: flex;
8504
+ align-items: center;
8505
+ justify-content: center;
8506
+ min-inline-size: 44px;
8507
+ min-block-size: 44px;
8508
+ border: 0;
8509
+ font: inherit;
8510
+ cursor: pointer;
8511
+ touch-action: manipulation;
8512
+ }
8513
+
8514
+ .dndev-swipe-action-toggle {
8515
+ flex-shrink: 0;
8516
+ background: var(--background);
8517
+ color: var(--foreground);
8518
+ }
8519
+
8520
+ /* Native overflow clips the closed action and progressively reveals its paint.
8521
+ Inert/disabled/ARIA state gates interaction until the open endpoint. */
8522
+ .dndev-swipe-action-delete {
8523
+ flex: 0 0 var(--swipe-action-width);
8524
+ scroll-snap-align: end;
8525
+ flex-direction: column;
8526
+ padding: var(--gap-sm);
8527
+ overflow-wrap: anywhere;
8528
+ background: var(--destructive);
8529
+ color: var(--destructive-foreground);
8530
+ }
8531
+
8532
+ .dndev-swipe-action svg {
8533
+ inline-size: var(--icon-md);
8534
+ block-size: var(--icon-md);
8535
+ flex-shrink: 0;
8536
+ }
8537
+
8538
+ .dndev-swipe-action button:focus-visible {
8539
+ outline: 2px solid var(--ring);
8540
+ outline-offset: -3px;
8541
+ }
8542
+
8543
+ .dndev-swipe-action button:disabled {
8544
+ cursor: default;
8545
+ }
8546
+
8547
+ @media (prefers-reduced-motion: reduce) {
8548
+ .dndev-swipe-action-viewport {
8549
+ scroll-behavior: auto;
8550
+ }
8551
+ }
8552
+
8125
8553
  /* packages/components/src/atomic/Switch/Switch.css */
8126
8554
 
8127
8555
  .dndev-switch {
@@ -8200,6 +8628,11 @@ input[type='number'] {
8200
8628
  will-change: transform;
8201
8629
  }
8202
8630
 
8631
+ /* Primary while on: thumb in the primary foreground (as Checkbox), readable on the track */
8632
+ .dndev-switch[data-variant='primary'][data-state='checked'] .dndev-switch-thumb {
8633
+ background-color: var(--primary-foreground);
8634
+ }
8635
+
8203
8636
  .dndev-switch[data-state='checked'] .dndev-switch-thumb {
8204
8637
  transform: translateX(calc(2.75rem - 1.25rem - 0.125rem));
8205
8638
  }
@@ -8255,6 +8688,10 @@ input[type='number'] {
8255
8688
  font-weight: var(--font-weight-normal);
8256
8689
  }
8257
8690
 
8691
+ /* Switch with a label after it: the switch keeps its size, the label wraps */
8692
+ .dndev-switch-field > .dndev-switch {
8693
+ flex-shrink: 0;
8694
+ }
8258
8695
  /* packages/components/src/atomic/Table/Table.css */
8259
8696
 
8260
8697
  .dndev-table-wrapper {
@@ -8284,7 +8721,7 @@ input[type='number'] {
8284
8721
 
8285
8722
  .dndev-table-filter-row .dndev-table-head {
8286
8723
  background-color: var(--muted);
8287
- padding: var(--gap-xs);
8724
+ padding: var(--gap-sm);
8288
8725
  height: auto;
8289
8726
  min-height: auto;
8290
8727
  }
@@ -8489,6 +8926,93 @@ input[type='number'] {
8489
8926
  opacity: var(--opacity-muted);
8490
8927
  }
8491
8928
  }
8929
+
8930
+ /* Editable DataTable --------------------------------------------------- */
8931
+
8932
+ /* Scope for editor lookup (keyboard navigation); adds no box. */
8933
+ .dndev-table-edit-scope {
8934
+ display: contents;
8935
+ }
8936
+
8937
+ .dndev-table-bulk-bar {
8938
+ padding: var(--gap-sm) var(--gap-sm);
8939
+ border: 1px solid var(--border);
8940
+ background-color: var(--muted);
8941
+ }
8942
+
8943
+ /* Cell editor: fills the cell, reads as text until focused. */
8944
+ .dndev-table-cell-editor {
8945
+ width: 100%;
8946
+ min-width: 6rem;
8947
+ font: inherit;
8948
+ color: inherit;
8949
+ background-color: transparent;
8950
+ border: 1px solid transparent;
8951
+ border-radius: var(--radius-sm);
8952
+ padding: var(--gap-sm);
8953
+ }
8954
+
8955
+ .dndev-table-cell-editor:hover {
8956
+ border-color: var(--border);
8957
+ }
8958
+
8959
+ .dndev-table-cell-editor:focus-visible,
8960
+ .dndev-table-cell-editor:focus {
8961
+ outline: 2px solid var(--ring);
8962
+ outline-offset: -1px;
8963
+ background-color: var(--background);
8964
+ }
8965
+
8966
+ .dndev-table-bulk-bar .dndev-table-cell-editor {
8967
+ width: auto;
8968
+ border-color: var(--border);
8969
+ background-color: var(--background);
8970
+ }
8971
+
8972
+ .dndev-table-cell[data-editable='true'] {
8973
+ padding-block: 0;
8974
+ }
8975
+
8976
+ /* Changed, not saved yet */
8977
+ .dndev-table-cell[data-dirty='true'] {
8978
+ background-color: color-mix(in oklab, var(--primary) 12%, transparent);
8979
+ }
8980
+
8981
+ /* Value that does not parse, or breaks a rule (cellErrors): the save will reject it */
8982
+ .dndev-table-cell[data-invalid='true'] .dndev-table-cell-editor {
8983
+ border-color: var(--destructive);
8984
+ }
8985
+
8986
+ /* Message of a rule the cell value breaks (cellErrors) */
8987
+ .dndev-table-cell-error {
8988
+ display: block;
8989
+ margin-block-start: var(--gap-sm);
8990
+ color: var(--destructive);
8991
+ font-size: var(--font-size-xs);
8992
+ line-height: 1.3;
8993
+ }
8994
+
8995
+ /* Open cell: icon link to the row's record (touch-sized hit area) */
8996
+ .dndev-table-open-link {
8997
+ display: inline-flex;
8998
+ align-items: center;
8999
+ justify-content: center;
9000
+ min-width: var(--touch-target);
9001
+ min-height: var(--touch-target);
9002
+ color: var(--muted-foreground);
9003
+ border-radius: var(--radius-sm);
9004
+ }
9005
+
9006
+ .dndev-table-open-link:hover {
9007
+ color: var(--foreground);
9008
+ background-color: var(--muted);
9009
+ }
9010
+
9011
+ .dndev-table-open-link:focus-visible {
9012
+ outline: 2px solid var(--ring);
9013
+ outline-offset: -1px;
9014
+ }
9015
+
8492
9016
  /* packages/components/src/atomic/Tabs/Tabs.css */
8493
9017
 
8494
9018
  /* Tabs list: use flexbox for natural wrapping, not grid */
@@ -8508,100 +9032,51 @@ input[type='number'] {
8508
9032
  word-break: break-word;
8509
9033
  border: var(--border-hairline) solid var(--line-2); /* Show clickable area */
8510
9034
 
8511
- /* Fallback (no variant): inactive = primary, active = foreground/card */
8512
- background-color: var(--primary);
8513
- color: var(--primary-foreground);
9035
+ /*
9036
+ * Inactive = neutral surface, active = filled with the variant colour, so the
9037
+ * selected tab is the one that stands out (the panel sits below with a gap, it
9038
+ * is not a folder tab joined to its content). --card not --background: the tab
9039
+ * surface must be opaque (--background can be transparent in some themes).
9040
+ */
9041
+ background-color: var(--card);
9042
+ color: var(--muted-foreground);
9043
+ --tab-active-bg: var(--primary);
9044
+ --tab-active-fg: var(--primary-foreground);
8514
9045
  }
8515
- .dndev-interactive[data-role='tab-trigger'][data-state='active'] {
8516
- /* --card not --background: active tab surface must be opaque (--background can be transparent in some themes) */
8517
- background-color: var(--card);
9046
+ .dndev-interactive[data-role='tab-trigger']:hover:not([data-state='active']):not(:disabled) {
8518
9047
  color: var(--foreground);
8519
- box-shadow: var(--shadow-sm);
8520
- border-color: var(--primary);
8521
- }
8522
- /* Default/Primary variant: inactive = primary, active = foreground/card */
8523
- .dndev-interactive[data-role='tab-trigger'][data-variant='default'],.dndev-interactive[data-role='tab-trigger'][data-variant='primary'] {
8524
- background-color: var(--primary);
8525
- color: var(--primary-foreground);
8526
9048
  }
8527
- [data-state='active']:is(.dndev-interactive[data-role='tab-trigger'][data-variant='default'],.dndev-interactive[data-role='tab-trigger'][data-variant='primary']) {
8528
- /* --card not --background: active tab surface must be opaque */
8529
- background-color: var(--card);
8530
- color: var(--foreground);
8531
- box-shadow: var(--shadow-sm);
8532
- border-color: var(--primary);
8533
- }
8534
- /* Secondary variant: inactive = secondary, active = foreground/card */
8535
9049
  .dndev-interactive[data-role='tab-trigger'][data-variant='secondary'] {
8536
- background-color: var(--secondary);
8537
- color: var(--secondary-foreground);
9050
+ --tab-active-bg: var(--secondary);
9051
+ --tab-active-fg: var(--secondary-foreground);
8538
9052
  }
8539
- .dndev-interactive[data-role='tab-trigger'][data-variant='secondary'][data-state='active'] {
8540
- /* --card not --background: active tab surface must be opaque */
8541
- background-color: var(--card);
8542
- color: var(--foreground);
8543
- box-shadow: var(--shadow-sm);
8544
- border-color: var(--secondary);
8545
- }
8546
- /* Accent variant: inactive = accent, active = foreground/card */
8547
9053
  .dndev-interactive[data-role='tab-trigger'][data-variant='accent'] {
8548
- background-color: var(--accent);
8549
- color: var(--accent-foreground);
9054
+ --tab-active-bg: var(--accent);
9055
+ --tab-active-fg: var(--accent-foreground);
8550
9056
  }
8551
- .dndev-interactive[data-role='tab-trigger'][data-variant='accent'][data-state='active'] {
8552
- /* --card not --background: active tab surface must be opaque */
8553
- background-color: var(--card);
8554
- color: var(--foreground);
8555
- box-shadow: var(--shadow-sm);
8556
- border-color: var(--accent);
8557
- }
8558
- /* Muted variant: inactive = muted, active = primary (to contrast) */
9057
+ /* Muted: the muted fill would not stand out as the selection, so primary */
8559
9058
  .dndev-interactive[data-role='tab-trigger'][data-variant='muted'] {
8560
- background-color: var(--muted);
8561
- color: var(--muted-foreground);
9059
+ --tab-active-bg: var(--primary);
9060
+ --tab-active-fg: var(--primary-foreground);
8562
9061
  }
8563
- .dndev-interactive[data-role='tab-trigger'][data-variant='muted'][data-state='active'] {
8564
- background-color: var(--primary);
8565
- color: var(--primary-foreground);
8566
- box-shadow: var(--shadow-sm);
8567
- border-color: var(--primary);
8568
- }
8569
- /* Warning variant: inactive = warning, active = foreground/card */
8570
9062
  .dndev-interactive[data-role='tab-trigger'][data-variant='warning'] {
8571
- background-color: var(--warning);
8572
- color: var(--warning-foreground);
9063
+ --tab-active-bg: var(--warning);
9064
+ --tab-active-fg: var(--warning-foreground);
8573
9065
  }
8574
- .dndev-interactive[data-role='tab-trigger'][data-variant='warning'][data-state='active'] {
8575
- /* --card not --background: active tab surface must be opaque */
8576
- background-color: var(--card);
8577
- color: var(--foreground);
8578
- box-shadow: var(--shadow-sm);
8579
- border-color: var(--warning);
8580
- }
8581
- /* Success variant: inactive = success, active = foreground/card */
8582
9066
  .dndev-interactive[data-role='tab-trigger'][data-variant='success'] {
8583
- background-color: var(--success);
8584
- color: var(--success-foreground);
9067
+ --tab-active-bg: var(--success);
9068
+ --tab-active-fg: var(--success-foreground);
8585
9069
  }
8586
- .dndev-interactive[data-role='tab-trigger'][data-variant='success'][data-state='active'] {
8587
- /* --card not --background: active tab surface must be opaque */
8588
- background-color: var(--card);
8589
- color: var(--foreground);
8590
- box-shadow: var(--shadow-sm);
8591
- border-color: var(--success);
8592
- }
8593
- /* Destructive variant: inactive = destructive, active = foreground/card */
8594
9070
  .dndev-interactive[data-role='tab-trigger'][data-variant='destructive'] {
8595
- background-color: var(--destructive);
8596
- color: var(--destructive-foreground);
9071
+ --tab-active-bg: var(--destructive);
9072
+ --tab-active-fg: var(--destructive-foreground);
9073
+ }
9074
+ .dndev-interactive[data-role='tab-trigger'][data-state='active'] {
9075
+ background-color: var(--tab-active-bg);
9076
+ color: var(--tab-active-fg);
9077
+ border-color: var(--tab-active-bg);
9078
+ box-shadow: var(--shadow-sm);
8597
9079
  }
8598
- .dndev-interactive[data-role='tab-trigger'][data-variant='destructive'][data-state='active'] {
8599
- /* --card not --background: active tab surface must be opaque */
8600
- background-color: var(--card);
8601
- color: var(--foreground);
8602
- box-shadow: var(--shadow-sm);
8603
- border-color: var(--destructive);
8604
- }
8605
9080
 
8606
9081
  .dndev-tabs-content {
8607
9082
  margin-top: var(--gap-md);
@@ -8620,41 +9095,117 @@ input[type='number'] {
8620
9095
  display: none;
8621
9096
  }
8622
9097
 
8623
- /* packages/components/src/atomic/QuantityStepper/QuantityStepper.css */
8624
-
8625
- /* One outlined control (e-commerce standard, e.g. Shopify Dawn): borderless − / +
8626
- buttons around a centred, tabular quantity. Same height and radius as buttons. */
9098
+ /* Reserve the complete footprint, even when zero is presented as one large +. */
8627
9099
  .dndev-quantity-stepper {
8628
- display: inline-flex;
8629
- align-items: stretch;
8630
- min-height: var(--touch-target);
9100
+ --quantity-target: max(var(--touch-target), 44px);
9101
+ /* Include both icon states, padding and inherited text BEFORE placing items.
9102
+ Auto rows otherwise grow for the larger collapsed icon, then shrink on expand. */
9103
+ --quantity-cell: max(
9104
+ var(--quantity-target),
9105
+ calc(max(var(--icon-md), var(--quantity-target) * 0.6, 1lh) + 2 * var(--gap-sm))
9106
+ );
9107
+ display: inline-grid;
9108
+ grid-template-columns: var(--quantity-cell) minmax(var(--quantity-cell), 1fr) var(--quantity-cell);
9109
+ grid-template-rows: var(--quantity-cell);
9110
+ inline-size: calc(3 * var(--quantity-cell));
9111
+ min-inline-size: calc(3 * var(--quantity-cell));
8631
9112
  border: var(--border-hairline) solid var(--border);
8632
9113
  border-radius: var(--radius-interactive);
8633
9114
  background: var(--interactive);
8634
9115
  color: var(--foreground);
8635
9116
  }
8636
9117
  .dndev-quantity-stepper[data-full-width] {
8637
- display: flex;
8638
- width: 100%;
9118
+ display: grid;
9119
+ inline-size: 100%;
8639
9120
  }
8640
9121
  .dndev-quantity-stepper[data-disabled] {
8641
9122
  opacity: 0.6;
8642
9123
  }
8643
- .dndev-quantity-stepper > .dndev-interactive {
8644
- flex: 0 0 auto;
8645
- aspect-ratio: 1;
8646
- min-height: 0;
9124
+ .dndev-quantity-stepper > button,.dndev-quantity-stepper > input {
9125
+ min-inline-size: var(--quantity-target);
9126
+ min-block-size: var(--quantity-target);
8647
9127
  border: none;
8648
9128
  border-radius: inherit;
8649
9129
  background: transparent;
9130
+ color: inherit;
9131
+ font: inherit;
9132
+ touch-action: manipulation;
8650
9133
  }
9134
+ :is(.dndev-quantity-stepper > button,.dndev-quantity-stepper > input):focus-visible {
9135
+ outline: none;
9136
+ box-shadow: var(--shadow-focus);
9137
+ z-index: 1;
9138
+ }
9139
+ :is(.dndev-quantity-stepper > button,.dndev-quantity-stepper > input):disabled {
9140
+ cursor: not-allowed;
9141
+ opacity: 0.6;
9142
+ }
9143
+ .dndev-quantity-stepper > button {
9144
+ display: flex;
9145
+ align-items: center;
9146
+ justify-content: center;
9147
+ padding: var(--gap-sm);
9148
+ cursor: pointer;
9149
+ transition: background-color var(--transition-fast);
9150
+ /* Press-and-hold repeats: no text selection or touch callout on long press. */
9151
+ -moz-user-select: none;
9152
+ user-select: none;
9153
+ -webkit-user-select: none;
9154
+ -webkit-touch-callout: none;
9155
+ }
9156
+ :is(.dndev-quantity-stepper > button):hover:not(:disabled) {
9157
+ background: var(--muted);
9158
+ }
9159
+ :is(.dndev-quantity-stepper > button) > svg {
9160
+ inline-size: var(--icon-md);
9161
+ block-size: var(--icon-md);
9162
+ }
9163
+ .dndev-quantity-stepper > .dndev-quantity-stepper-decrement {
9164
+ grid-area: 1 / 1;
9165
+ }
9166
+ .dndev-quantity-stepper > .dndev-quantity-stepper-value {
9167
+ grid-area: 1 / 2;
9168
+ }
9169
+ .dndev-quantity-stepper > .dndev-quantity-stepper-increment {
9170
+ grid-area: 1 / 3;
9171
+ }
9172
+ .dndev-quantity-stepper[data-vertical] {
9173
+ grid-template-columns: minmax(var(--quantity-cell), 1fr);
9174
+ grid-template-rows: repeat(3, var(--quantity-cell));
9175
+ inline-size: var(--quantity-cell);
9176
+ min-inline-size: var(--quantity-cell);
9177
+ }
9178
+ .dndev-quantity-stepper[data-vertical][data-full-width] {
9179
+ inline-size: 100%;
9180
+ }
9181
+ .dndev-quantity-stepper[data-vertical] > .dndev-quantity-stepper-increment {
9182
+ grid-area: 1 / 1;
9183
+ }
9184
+ .dndev-quantity-stepper[data-vertical] > .dndev-quantity-stepper-value {
9185
+ grid-area: 2 / 1;
9186
+ }
9187
+ .dndev-quantity-stepper[data-vertical] > .dndev-quantity-stepper-decrement {
9188
+ grid-area: 3 / 1;
9189
+ }
9190
+ .dndev-quantity-stepper[data-collapsed] > .dndev-quantity-stepper-decrement,.dndev-quantity-stepper[data-collapsed] > .dndev-quantity-stepper-value {
9191
+ visibility: hidden;
9192
+ pointer-events: none;
9193
+ }
9194
+ .dndev-quantity-stepper[data-collapsed] > .dndev-quantity-stepper-increment {
9195
+ grid-area: 1 / 1 / -1 / -1;
9196
+ }
9197
+ :is(.dndev-quantity-stepper[data-collapsed] > .dndev-quantity-stepper-increment) > svg {
9198
+ inline-size: calc(var(--quantity-target) * 0.6);
9199
+ block-size: calc(var(--quantity-target) * 0.6);
9200
+ }
8651
9201
 
8652
9202
  .dndev-quantity-stepper-value {
8653
- flex: 1 1 auto;
9203
+ box-sizing: border-box;
8654
9204
  display: flex;
8655
9205
  align-items: center;
8656
9206
  justify-content: center;
8657
- min-width: 3ch;
9207
+ inline-size: 100%;
9208
+ min-inline-size: 0;
8658
9209
  padding-inline: var(--gap-sm);
8659
9210
  border: none;
8660
9211
  background: none;
@@ -8663,21 +9214,14 @@ input[type='number'] {
8663
9214
  font-weight: var(--font-weight-medium);
8664
9215
  font-variant-numeric: tabular-nums;
8665
9216
  text-align: center;
8666
- }
8667
9217
 
8668
- .dndev-quantity-stepper-value:is(button) {
8669
- cursor: pointer;
8670
- }
8671
-
8672
- .dndev-quantity-stepper-value:is(button):hover {
8673
- text-decoration: underline;
8674
- text-underline-offset: 0.2em;
8675
- }
9218
+ }
8676
9219
 
8677
- .dndev-quantity-stepper-value:is(button):focus-visible {
8678
- outline: none;
8679
- box-shadow: var(--shadow-focus);
9220
+ @media (prefers-reduced-motion: reduce) {
9221
+ .dndev-quantity-stepper > button {
9222
+ transition: none;
8680
9223
  }
9224
+ }
8681
9225
 
8682
9226
  /* packages/components/src/atomic/Tag/Tag.css */
8683
9227
 
@@ -8944,7 +9488,7 @@ input[type='number'] {
8944
9488
  .dndev-toast-viewport {
8945
9489
  position: fixed;
8946
9490
  top: var(--gap-md);
8947
- z-index: 100;
9491
+ z-index: var(--z-toast);
8948
9492
  display: flex;
8949
9493
  flex-direction: column-reverse;
8950
9494
  max-height: 100dvh;
@@ -9297,7 +9841,7 @@ input[type='number'] {
9297
9841
  display: flex;
9298
9842
  align-items: center;
9299
9843
  gap: var(--gap-sm);
9300
- padding: var(--gap-xs) var(--gap-sm);
9844
+ padding: var(--gap-sm) var(--gap-sm);
9301
9845
  border-radius: var(--radius-interactive);
9302
9846
  cursor: pointer;
9303
9847
  transition:
@@ -11683,9 +12227,17 @@ h4[data-variant='code'] {
11683
12227
  /* ===========================
11684
12228
  DEFAULT VALUES (Landing Preset)
11685
12229
  All presets inherit these - only override what's different
12230
+
12231
+ Layout tokens are declared on <html>, never on .dndev-layout: every element of
12232
+ the app sits under the wrapper, so a declaration there would shadow the app's
12233
+ :root overrides (themes.css). Presets read the wrapper's data-layout (in the
12234
+ server HTML) through :has, so they resolve on the first paint. All token rules
12235
+ carry zero specificity (:where): an app :root override wins whatever the
12236
+ stylesheet order. Preset display rules (hide header, sidebar…) stay scoped to
12237
+ [data-layout], which matches the wrapper.
11686
12238
  =========================== */
11687
12239
 
11688
- :root {
12240
+ :where(:root) {
11689
12241
  /* Layout structure dimensions */
11690
12242
  /* Height values include borders (box-sizing: border-box) */
11691
12243
  /* Content heights are multiples of 12px, then add 2px border */
@@ -11887,9 +12439,15 @@ main[role='main'][data-routing-animation='none'] {
11887
12439
  }
11888
12440
 
11889
12441
  /* Header content width adjustments for sidebar layouts */
11890
- [data-layout='moolti'],
11891
- [data-layout='docs'],
11892
- [data-layout='blog'] {
12442
+ :where(
12443
+ :root:has(
12444
+ .dndev-layout:is(
12445
+ [data-layout='moolti'],
12446
+ [data-layout='docs'],
12447
+ [data-layout='blog']
12448
+ )
12449
+ )
12450
+ ) {
11893
12451
  --header-content-width: calc(100% - var(--sidebar-width));
11894
12452
  }
11895
12453
 
@@ -11946,10 +12504,20 @@ main[role='main'][data-routing-animation='none'] {
11946
12504
  grid-template-rows: var(--header-height) 1fr auto;
11947
12505
  }
11948
12506
 
11949
- /* Footer inside main: spacing + sizing (slotted mode only) */
12507
+ /* No footer rendered (app.footer: null): no footer row, main takes the space */
12508
+ .dndev-layout:not(:has(> footer)) {
12509
+ grid-template-areas:
12510
+ 'header header'
12511
+ 'sidebar main';
12512
+ grid-template-rows: var(--header-height) 1fr;
12513
+ }
12514
+
12515
+ /* Footer inside main: spacing + sizing (slotted mode only). The gap sits on the page
12516
+ above it: the footer's own block-start margin is `auto` (pinned to the bottom). */
12517
+ main[role='main'] > :has(+ footer[role='contentinfo']:not([data-custom])) {
12518
+ margin-block-end: var(--gap-lg);
12519
+ }
11950
12520
  main[role='main'] > footer[role='contentinfo']:not([data-custom]) {
11951
- margin-top: var(--gap-lg);
11952
- flex-shrink: 0;
11953
12521
  height: auto;
11954
12522
  }
11955
12523
  main[role='main'] > footer[role='contentinfo']:not([data-custom]) > * {
@@ -12096,7 +12664,7 @@ aside[role='navigation'].sidebar {
12096
12664
  display: none;
12097
12665
  }
12098
12666
  /* Moolti: Sidebar spans full height (no header/footer on desktop) */
12099
- [data-layout='moolti']:root aside.sidebar[role='navigation'] {
12667
+ [data-layout='moolti']:root aside.sidebar[role='navigation'],.dndev-layout[data-layout='moolti'] aside.sidebar[role='navigation'] {
12100
12668
  grid-row: 1 / -1;
12101
12669
  }
12102
12670
 
@@ -12310,11 +12878,20 @@ main[role='main'] {
12310
12878
  padding: 0;
12311
12879
  contain: layout style;
12312
12880
 
12313
- /* First child after breadcrumbs grows to fill space, never shrinks (scroll container owns overflow) */
12881
+ /* The page (first child, or the one after breadcrumbs) grows to fill the space and never
12882
+ shrinks (the scroll container owns overflow). Only the page: a footer rendered inside
12883
+ main keeps its own height. */
12314
12884
  }
12315
- main[role='main'] > *:not(.breadcrumbs-container):first-of-type,main[role='main'] > .breadcrumbs-container + * {
12885
+ main[role='main'] > :first-child:not(.breadcrumbs-container,footer),main[role='main'] > .breadcrumbs-container + :not(footer) {
12316
12886
  flex: 1 0 auto;
12317
12887
  }
12888
+ /* Footer inside main: always at the bottom, even while the page is not there yet
12889
+ (a Suspense boundary streaming in leaves only a hidden placeholder): main stays
12890
+ empty above it, nothing shifts when the page arrives. */
12891
+ main[role='main'] > footer {
12892
+ flex: 0 0 auto;
12893
+ margin-block-start: auto;
12894
+ }
12318
12895
 
12319
12896
  /* Footer: Full width by default, app presets start after sidebar */
12320
12897
  /* box-sizing: border-box ensures borders are included in height */
@@ -12463,14 +13040,14 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
12463
13040
  * Perfect for: Admin panels, dashboards, management interfaces
12464
13041
  * Overrides: Adds sidebar (240px), constrains width (1480px), tighter spacing
12465
13042
  */
12466
- [data-layout='admin'] {
13043
+ :where(:root:has(.dndev-layout[data-layout='admin'])) {
12467
13044
  /* Desktop/Wide (>=1024px) - only overrides */
12468
13045
  --sidebar-width: var(--custom-sidebar-width, 240px);
12469
13046
 
12470
13047
  /* Admin: Mobile/Tablet (<1024px) - only overrides */
12471
13048
  }
12472
13049
  @media (width <=1023px) {
12473
- [data-layout='admin'] {
13050
+ :where(:root:has(.dndev-layout[data-layout='admin'])) {
12474
13051
  --sidebar-width: 0px;
12475
13052
  /* Override: hide sidebar on mobile */
12476
13053
  }
@@ -12481,48 +13058,53 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
12481
13058
  * Perfect for: SaaS applications, productivity tools, focused workflows
12482
13059
  * Overrides: No header/footer (sidebar only), sidebar (256px), balanced spacing
12483
13060
  */
12484
- [data-layout='moolti'] {
13061
+ :where(:root:has(.dndev-layout[data-layout='moolti'])) {
12485
13062
  /* Desktop/Wide (>=1024px) - only overrides */
12486
13063
  --header-height: 0px;
12487
13064
  --sidebar-width: var(--custom-sidebar-width, 256px);
12488
13065
  --footer-height: 0px;
13066
+
13067
+ /* Moolti: Mobile/Tablet (<1024px) - only overrides */
13068
+ }
13069
+ @media (width <=1023px) {
13070
+ :where(:root:has(.dndev-layout[data-layout='moolti'])) {
13071
+ --header-height: 62px;
13072
+ --sidebar-width: 0px;
12489
13073
  }
13074
+ }
13075
+
12490
13076
  [data-layout='moolti'] header[role='banner'] {
12491
13077
  display: none;
12492
13078
  }
13079
+
12493
13080
  [data-layout='moolti'] footer[role='contentinfo'] {
12494
13081
  display: none;
12495
13082
  }
12496
- /* Moolti: Mobile/Tablet (<1024px) - only overrides */
12497
- @media (width <=1023px) {
12498
- [data-layout='moolti'] {
12499
- --header-height: 62px;
12500
- --sidebar-width: 0px;
12501
- }
12502
- }
12503
13083
 
12504
13084
  /**
12505
13085
  * DOCS PRESET
12506
13086
  * Perfect for: Documentation sites, knowledge bases, content platforms
12507
13087
  * Overrides: No header, sidebar (300px), comfortable reading spacing
12508
13088
  */
12509
- [data-layout='docs'] {
13089
+ :where(:root:has(.dndev-layout[data-layout='docs'])) {
12510
13090
  /* Desktop/Wide (>=1024px) - only overrides */
12511
13091
  --header-height: 0px;
12512
13092
  /* Override: no header - maximizes reading space */
12513
13093
  --sidebar-width: var(--custom-sidebar-width, 300px);
13094
+
13095
+ /* Docs: Mobile/Tablet (<1024px) - only overrides */
12514
13096
  }
12515
- [data-layout='docs'] header[role='banner'] {
12516
- display: none;
12517
- }
12518
- /* Docs: Mobile/Tablet (<1024px) - only overrides */
12519
13097
  @media (width <=1023px) {
12520
- [data-layout='docs'] {
13098
+ :where(:root:has(.dndev-layout[data-layout='docs'])) {
12521
13099
  --sidebar-width: 0px;
12522
13100
  /* Override: hide sidebar on mobile */
12523
13101
  }
12524
13102
  }
12525
13103
 
13104
+ [data-layout='docs'] header[role='banner'] {
13105
+ display: none;
13106
+ }
13107
+
12526
13108
  /**
12527
13109
  * LANDING PRESET (Default)
12528
13110
  * Perfect for: Marketing sites, landing pages, public content
@@ -12534,17 +13116,19 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
12534
13116
  * Perfect for: Blogs, news sites, content management
12535
13117
  * Overrides: Sidebar (280px), constrains width (1480px), content-focused spacing
12536
13118
  */
12537
- [data-layout='blog'] {
13119
+ :where(:root:has(.dndev-layout[data-layout='blog'])) {
12538
13120
  --sidebar-width: var(--custom-sidebar-width, 280px);
12539
13121
 
12540
13122
  /* Blog: Mobile/Tablet (<1024px) - only overrides */
12541
13123
  }
12542
13124
  @media (width <=1023px) {
12543
- [data-layout='blog'] {
13125
+ :where(:root:has(.dndev-layout[data-layout='blog'])) {
12544
13126
  --header-height: 0px;
12545
13127
  --sidebar-width: 0px;
12546
13128
  }
13129
+ }
12547
13130
 
13131
+ @media (width <=1023px) {
12548
13132
  [data-layout='blog'] header[role='banner'] {
12549
13133
  display: none;
12550
13134
  }
@@ -12555,17 +13139,20 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
12555
13139
  * Perfect for: Full-screen apps, embedded widgets, clean content
12556
13140
  * Overrides: No header/footer/sidebar, minimal spacing
12557
13141
  */
12558
- [data-layout='plain'] {
13142
+ :where(:root:has(.dndev-layout[data-layout='plain'])) {
12559
13143
  --header-height: 0px;
12560
13144
  --sidebar-width: 0px;
12561
13145
  --footer-height: 0px;
12562
13146
  }
13147
+
12563
13148
  [data-layout='plain'] header[role='banner'] {
12564
13149
  display: none;
12565
13150
  }
13151
+
12566
13152
  [data-layout='plain'] aside.sidebar[role='navigation'] {
12567
13153
  display: none;
12568
13154
  }
13155
+
12569
13156
  [data-layout='plain'] footer[role='contentinfo'] {
12570
13157
  display: none;
12571
13158
  }
@@ -12577,16 +13164,18 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
12577
13164
  * Perfect for: Mobile gaming apps, full-screen experiences, touch interfaces
12578
13165
  * Overrides: Minimal spacing for maximum screen real estate
12579
13166
  */
12580
- [data-layout='game'] {
13167
+ :where(:root:has(.dndev-layout[data-layout='game'])) {
12581
13168
  --header-height: 92px;
12582
13169
 
12583
13170
  /* Game: Mobile/Tablet (<1024px) - only overrides */
12584
13171
  }
12585
13172
  @media (width <=1023px) {
12586
- [data-layout='game'] {
13173
+ :where(:root:has(.dndev-layout[data-layout='game'])) {
12587
13174
  --footer-height: 0px;
12588
13175
  }
13176
+ }
12589
13177
 
13178
+ @media (width <=1023px) {
12590
13179
  [data-layout='game'] footer[role='contentinfo'] {
12591
13180
  display: none;
12592
13181
  }
@@ -13020,7 +13609,9 @@ footer[role='contentinfo']:not([data-custom]) a:not(.dndev-interactive):hover {
13020
13609
  .app-branding[data-display='auto'] .app-branding-title {
13021
13610
  display: inline;
13022
13611
  }
13023
- /* 2. Fonts from @fontsource (bundled; no external fetch, no public/fonts required) */
13612
+ /* 2. Font catalogue from @fontsource (self-hosted, never Google Fonts). Must match
13613
+ FONT_WEIGHTS in packages/core/config/constants.js (a test guards it). The Vite build
13614
+ keeps only the families the app's theme renders text in (FontPreloadPlugin). */
13024
13615
  /* inter-cyrillic-ext-300-normal */
13025
13616
  @font-face {
13026
13617
  font-family: 'Inter';