@fusion.dev/helix 0.146.0 → 0.147.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 (243) hide show
  1. package/custom-elements.json +5556 -539
  2. package/dist/accordion/item/accordion-item.css.js +4 -96
  3. package/dist/accordion/root/accordion-root.css.js +2 -28
  4. package/dist/announcement/root/announcement-root.css.js +10 -154
  5. package/dist/announcement/root/announcement-root.d.ts +3 -0
  6. package/dist/app-header/root/app-header-root.css.js +2 -118
  7. package/dist/area-chart/root/area-chart-root.css.js +4 -94
  8. package/dist/area-chart/root/area-chart-root.d.ts +1 -0
  9. package/dist/aura/root/aura-root.css.js +2 -57
  10. package/dist/avatar/group/avatar-group.css.js +5 -36
  11. package/dist/avatar/group/avatar-group.d.ts +3 -0
  12. package/dist/avatar/root/avatar-root.css.js +1 -53
  13. package/dist/avatar/root/avatar-root.d.ts +2 -0
  14. package/dist/badge/root/badge-root.css.js +12 -207
  15. package/dist/badge/root/badge-root.d.ts +2 -0
  16. package/dist/bar-chart/root/bar-chart-root.css.js +8 -292
  17. package/dist/blockquote/root/blockquote-root.css.js +1 -43
  18. package/dist/breadcrumbs/breadcrumb/breadcrumb.css.js +13 -98
  19. package/dist/breadcrumbs/root/breadcrumbs-root.css.js +5 -42
  20. package/dist/breadcrumbs/root/breadcrumbs-root.d.ts +17 -0
  21. package/dist/breadcrumbs/root/breadcrumbs-root.js +4 -0
  22. package/dist/button/root/button-root.css.js +16 -197
  23. package/dist/button/root/button-root.d.ts +1 -0
  24. package/dist/button-group/root/button-group-root.css.js +2 -52
  25. package/dist/callout/root/callout-root.css.js +5 -138
  26. package/dist/callout/root/callout-root.d.ts +4 -2
  27. package/dist/canvas/node/canvas-node.css.js +10 -367
  28. package/dist/canvas/root/canvas-root.css.js +7 -270
  29. package/dist/card/root/card-root.css.js +5 -134
  30. package/dist/carousel/root/carousel-root.css.js +20 -386
  31. package/dist/chat/composer/chat-composer.css.js +4 -105
  32. package/dist/chat/message/chat-message.css.js +5 -239
  33. package/dist/chat/message/chat-message.d.ts +5 -0
  34. package/dist/chat/root/chat-root.css.js +5 -162
  35. package/dist/chat/typing.css.js +9 -46
  36. package/dist/checkbox/root/checkbox-root.css.js +12 -177
  37. package/dist/checkbox-group/root/checkbox-group-root.css.js +1 -27
  38. package/dist/code/root/code-root.css.js +3 -25
  39. package/dist/code-block/root/code-block-root.css.js +9 -274
  40. package/dist/color-input/root/color-input-root.css.js +5 -114
  41. package/dist/color-picker/root/color-picker-root.css.js +39 -337
  42. package/dist/color-picker/root/color-picker-root.d.ts +2 -0
  43. package/dist/combobox/root/combobox-root.css.js +8 -147
  44. package/dist/command/root/command-root.css.js +3 -74
  45. package/dist/copy-button/root/copy-button-root.css.js +3 -43
  46. package/dist/data-table/root/data-table-root.css.js +21 -245
  47. package/dist/data-table/root/data-table-root.d.ts +7 -0
  48. package/dist/date-input/root/date-input-root.css.js +8 -103
  49. package/dist/date-picker/root/date-picker-root.css.js +16 -278
  50. package/dist/date-picker/root/date-picker-root.d.ts +1 -0
  51. package/dist/description-list/item/description-list-item.css.js +1 -41
  52. package/dist/description-list/item/description-list-item.d.ts +7 -0
  53. package/dist/description-list/root/description-list-root.css.js +1 -34
  54. package/dist/description-list/root/description-list-root.d.ts +1 -0
  55. package/dist/dialog/root/dialog-root.css.js +7 -221
  56. package/dist/dialog/root/dialog-root.d.ts +3 -0
  57. package/dist/divider/root/divider-root.css.js +6 -81
  58. package/dist/donut-chart/root/donut-chart-root.css.js +7 -193
  59. package/dist/drawer/root/drawer-root.css.js +11 -237
  60. package/dist/drilldown/item/drilldown-item.css.js +4 -51
  61. package/dist/drilldown/item/drilldown-item.d.ts +1 -0
  62. package/dist/drilldown/root/drilldown-root.css.js +6 -120
  63. package/dist/element-events.generated.js +4 -1
  64. package/dist/empty/root/empty-root.css.js +2 -42
  65. package/dist/file-input/root/file-input-root.css.js +7 -173
  66. package/dist/file-input/root/file-input-root.d.ts +4 -0
  67. package/dist/filter-input/chip/filter-chip.css.js +2 -84
  68. package/dist/filter-input/field/filter-field.css.js +1 -3
  69. package/dist/filter-input/menu/filter-menu.css.js +1 -3
  70. package/dist/filter-input/operator/filter-operator.css.js +1 -3
  71. package/dist/filter-input/root/filter-input-root.css.js +6 -113
  72. package/dist/flex/root/flex-root.css.js +4 -207
  73. package/dist/flex/root/flex-root.d.ts +2 -2
  74. package/dist/format-date/root/format-date-root.css.js +1 -13
  75. package/dist/graph/root/graph-root.css.js +9 -444
  76. package/dist/grid/root/grid-root.css.js +1 -171
  77. package/dist/heatmap/root/heatmap-root.css.js +8 -156
  78. package/dist/heatmap/root/heatmap-root.d.ts +2 -0
  79. package/dist/icon/index.d.ts +1 -1
  80. package/dist/icon/root/icon-root.css.js +1 -18
  81. package/dist/icon/root/index.d.ts +1 -1
  82. package/dist/icon-button/root/icon-button-root.css.js +25 -203
  83. package/dist/icon-button/root/icon-button-root.d.ts +1 -0
  84. package/dist/image/root/image-root.css.js +7 -65
  85. package/dist/image/root/image-root.d.ts +3 -0
  86. package/dist/input/root/input-root.css.js +6 -79
  87. package/dist/kbd/root/kbd-root.css.js +2 -71
  88. package/dist/kbd/root/kbd-root.d.ts +7 -0
  89. package/dist/legend/root/legend-root.css.js +9 -106
  90. package/dist/legend/root/legend-root.d.ts +2 -0
  91. package/dist/lightbox/item/lightbox-item.css.js +1 -37
  92. package/dist/lightbox/root/lightbox-root.css.js +38 -183
  93. package/dist/line-chart/root/line-chart-root.css.js +4 -170
  94. package/dist/line-chart/root/line-chart-root.d.ts +1 -0
  95. package/dist/list/item/list-item.css.js +2 -94
  96. package/dist/list/root/list-root.css.js +4 -88
  97. package/dist/listbox/root/listbox-root.css.js +4 -111
  98. package/dist/loader/root/loader-root.css.js +5 -171
  99. package/dist/map/area/map-area.css.js +1 -23
  100. package/dist/map/buildings/map-buildings.css.js +1 -26
  101. package/dist/map/contours/map-contours.css.js +2 -5
  102. package/dist/map/landcover/map-landcover.css.js +1 -4
  103. package/dist/map/marker/map-marker.css.js +14 -327
  104. package/dist/map/points/map-points.css.js +1 -86
  105. package/dist/map/position/map-position.css.js +8 -227
  106. package/dist/map/raster/map-raster.css.js +1 -3
  107. package/dist/map/root/map-root.css.js +10 -352
  108. package/dist/map/route/map-route.css.js +1 -24
  109. package/dist/map/terrain/map-terrain.css.js +3 -7
  110. package/dist/megamenu/root/megamenu-root.css.js +11 -162
  111. package/dist/megamenu/root/megamenu-root.d.ts +8 -0
  112. package/dist/menu/item/menu-item.css.js +7 -130
  113. package/dist/menu/root/menu-root.css.js +1 -110
  114. package/dist/menu/section/menu-section.css.js +1 -13
  115. package/dist/meter/root/meter-root.css.js +17 -207
  116. package/dist/meter/root/meter-root.d.ts +3 -0
  117. package/dist/navigation/root/navigation-root.css.js +2 -54
  118. package/dist/notifications/group/notification-group.css.js +1 -61
  119. package/dist/notifications/notification/notification.css.js +17 -264
  120. package/dist/notifications/root/notifications-root.css.js +7 -125
  121. package/dist/notifications/root/notifications-root.d.ts +3 -1
  122. package/dist/number-input/root/number-input-root.css.js +10 -103
  123. package/dist/object-inspector/root/object-inspector-root.css.js +11 -162
  124. package/dist/option/group/option-group.css.js +1 -22
  125. package/dist/option/index.d.ts +1 -0
  126. package/dist/option/index.js +1 -0
  127. package/dist/option/root/option-root.css.js +3 -85
  128. package/dist/option/separator/option-separator.css.d.ts +1 -0
  129. package/dist/option/separator/option-separator.css.js +3 -0
  130. package/dist/option/separator/option-separator.d.ts +26 -0
  131. package/dist/option/separator/option-separator.js +16 -0
  132. package/dist/orb/root/orb-root.css.js +1 -41
  133. package/dist/outline/root/outline-root.css.js +24 -122
  134. package/dist/outline/root/outline-root.d.ts +17 -4
  135. package/dist/pagination/root/pagination-root.css.js +9 -105
  136. package/dist/pagination/size/pagination-size.css.js +1 -22
  137. package/dist/pagination/summary/pagination-summary.css.js +1 -7
  138. package/dist/pin-input/root/pin-input-root.css.js +2 -73
  139. package/dist/pin-input/root/pin-input-root.d.ts +9 -3
  140. package/dist/popover/root/popover-root.css.js +6 -127
  141. package/dist/progress/root/progress-root.css.js +7 -230
  142. package/dist/progress/root/progress-root.d.ts +4 -0
  143. package/dist/qr-code/root/qr-code-root.css.js +1 -68
  144. package/dist/quote/root/quote-root.css.js +1 -20
  145. package/dist/radio/group/radio-group.css.js +1 -21
  146. package/dist/radio/root/radio-root.css.js +5 -208
  147. package/dist/rating/root/rating-root.css.js +4 -117
  148. package/dist/sandbox/frame.d.ts +2 -1
  149. package/dist/sandbox/frame.js +1 -1
  150. package/dist/sandbox/index.d.ts +1 -1
  151. package/dist/sandbox/preview/sandbox-preview.css.js +1 -12
  152. package/dist/sandbox/preview/sandbox-preview.d.ts +19 -3
  153. package/dist/sandbox/preview/sandbox-preview.js +17 -11
  154. package/dist/sandbox/root/sandbox-root.css.js +3 -70
  155. package/dist/sandbox/root/sandbox-root.d.ts +16 -4
  156. package/dist/sandbox/root/sandbox-root.js +29 -50
  157. package/dist/sandbox/source/sandbox-source.css.js +3 -95
  158. package/dist/sandbox/source/sandbox-source.d.ts +31 -25
  159. package/dist/sandbox/source/sandbox-source.js +12 -5
  160. package/dist/sandbox/status-bar/sandbox-status-bar.css.js +1 -21
  161. package/dist/sandbox/terminal/sandbox-terminal.css.js +5 -106
  162. package/dist/sandbox/terminal/sandbox-terminal.d.ts +4 -0
  163. package/dist/sandbox/terminal/sandbox-terminal.js +2 -1
  164. package/dist/sandbox/tokens.d.ts +2 -2
  165. package/dist/sandbox/toolbar/sandbox-toolbar.css.js +1 -36
  166. package/dist/scatter-chart/root/scatter-chart-root.css.js +11 -146
  167. package/dist/scatter-chart/root/scatter-chart-root.d.ts +1 -0
  168. package/dist/scroll-area/root/scroll-area-root.css.js +14 -181
  169. package/dist/select/root/select-root.css.js +4 -124
  170. package/dist/shared/chart/series.css.js +1 -36
  171. package/dist/shared/chart/terminus.css.js +1 -47
  172. package/dist/shared/chart/tooltip.css.js +1 -68
  173. package/dist/shared/collection/state.css.js +1 -9
  174. package/dist/shared/field/field-frame.css.js +3 -33
  175. package/dist/shared/field/field-inline.css.js +1 -4
  176. package/dist/shared/field/field-segments.css.js +1 -39
  177. package/dist/shared/field/field-stacked.css.js +1 -5
  178. package/dist/shared/field/field.css.js +3 -57
  179. package/dist/shared/floating/entrance.css.js +3 -34
  180. package/dist/shared/floating/panel.css.js +2 -17
  181. package/dist/shared/glyph/glyph.css.js +1 -5
  182. package/dist/shared/live/live.css.js +1 -8
  183. package/dist/shared/tags/tags.css.js +1 -39
  184. package/dist/shared/viewport/viewport.css.js +8 -135
  185. package/dist/skeleton/root/skeleton-root.css.js +12 -120
  186. package/dist/skip-link/root/skip-link-root.css.js +2 -47
  187. package/dist/slider/root/slider-root.css.js +19 -330
  188. package/dist/slider/root/slider-root.d.ts +2 -0
  189. package/dist/sparkline/root/sparkline-root.css.js +8 -143
  190. package/dist/sparkline/root/sparkline-root.d.ts +2 -0
  191. package/dist/speed-dial/item/speed-dial-item.css.js +4 -73
  192. package/dist/speed-dial/root/speed-dial-root.css.js +3 -149
  193. package/dist/splitter/root/splitter-root.css.js +11 -176
  194. package/dist/stat/group/stat-group.css.js +1 -36
  195. package/dist/stat/root/stat-root.css.js +3 -62
  196. package/dist/steps/root/steps-root.css.js +7 -92
  197. package/dist/steps/step/step.css.js +5 -156
  198. package/dist/switch/root/switch-root.css.js +2 -110
  199. package/dist/table/cell/table-cell.css.js +1 -33
  200. package/dist/table/column/table-column.css.js +7 -105
  201. package/dist/table/root/table-root.css.js +1 -43
  202. package/dist/table/row/table-row.css.js +6 -18
  203. package/dist/table/row/table-row.d.ts +2 -0
  204. package/dist/tabs/panel/tab-panel.css.js +2 -17
  205. package/dist/tabs/root/tabs-root.css.js +6 -177
  206. package/dist/tabs/tab/tab.css.js +6 -54
  207. package/dist/tag/group/tag-group.css.js +1 -11
  208. package/dist/tag/root/tag-root.css.js +1 -166
  209. package/dist/tag/root/tag-root.d.ts +2 -0
  210. package/dist/text/root/text-root.css.js +11 -200
  211. package/dist/textarea/root/textarea-root.css.js +3 -71
  212. package/dist/time-input/root/time-input-root.css.js +7 -118
  213. package/dist/time-picker/root/time-picker-root.css.js +10 -134
  214. package/dist/time-picker/root/time-picker-root.d.ts +1 -0
  215. package/dist/timeline/group/timeline-group.css.js +1 -31
  216. package/dist/timeline/item/timeline-item.css.js +3 -134
  217. package/dist/timeline/root/timeline-root.css.js +1 -66
  218. package/dist/toast/item/toast-item.css.js +8 -250
  219. package/dist/toast/root/toast-root.css.js +1 -85
  220. package/dist/toast/root/toast-root.js +2 -1
  221. package/dist/toggle/group/toggle-group.css.js +7 -126
  222. package/dist/toggle/root/toggle-root.css.js +1 -23
  223. package/dist/toolbar/root/toolbar-root.css.js +1 -36
  224. package/dist/toolbar/root/toolbar-root.d.ts +2 -0
  225. package/dist/tooltip/root/tooltip-root.css.js +5 -101
  226. package/dist/tooltip/root/tooltip-root.d.ts +2 -0
  227. package/dist/tour/root/tour-root.css.js +2 -28
  228. package/dist/tour/stop/tour-stop.css.js +2 -109
  229. package/dist/tree/item/tree-item.css.js +12 -238
  230. package/dist/tree/root/tree-root.css.js +1 -40
  231. package/dist/trend/root/trend-root.css.js +5 -53
  232. package/dist/video/root/video-root.css.js +16 -398
  233. package/dist/video-playlist/item/video-playlist-item.css.js +12 -86
  234. package/dist/video-playlist/item/video-playlist-item.d.ts +12 -0
  235. package/dist/video-playlist/menu/video-playlist-menu.css.js +1 -41
  236. package/dist/video-playlist/root/video-playlist-root.css.js +1 -19
  237. package/dist/video-playlist/root/video-playlist-root.d.ts +2 -0
  238. package/dist/virtual-list/root/virtual-list-root.css.js +3 -40
  239. package/lint.json +1 -1
  240. package/package.json +6 -6
  241. package/types/jsx.d.ts +2804 -619
  242. package/types/svelte.d.ts +1 -0
  243. package/types/vue.d.ts +810 -169
@@ -1,213 +1,10 @@
1
1
  import { createSheet } from '@fusion.dev/helix-core';
2
- export const styles = createSheet(`:host {
3
- --_radio-size: var(--radio-size, var(--helix-size-checkbox));
4
- display: block;
5
- }
6
-
7
- [part="item"] {
8
- all: unset;
9
- align-items: center;
10
- box-sizing: border-box;
11
- cursor: pointer;
12
- display: inline-flex;
13
- gap: var(--helix-space-xs);
14
- }
15
-
16
- :host([disabled]) [part="item"] {
17
- cursor: default;
18
- }
19
-
20
- :host([disabled]) {
21
- opacity: 0.5;
22
- }
23
-
24
- [part="box"] {
25
-
26
- background-color: var(--radio-background-color, var(--helix-color-background));
27
- block-size: var(--_radio-size);
28
- border: var(--helix-border-thin) solid var(--radio-border-color, var(--helix-color-border));
29
-
30
- border-radius: var(--helix-radii-full);
31
- display: grid;
32
- flex: 0 0 auto;
33
- inline-size: var(--_radio-size);
34
- place-items: center;
35
- transition: border-color var(--helix-duration-fast) var(--helix-easing-standard);
36
- }
37
-
38
- :host(:not([disabled])) [part="item"]:hover [part="box"] {
39
- border-color: var(--radio-border-color, var(--helix-color-foreground-muted));
40
- }
41
-
42
- :host(:state(selected)) [part="box"] {
43
- border-color: var(--radio-border-color, var(--helix-color-foreground));
44
- }
45
-
46
- [part="box"]::after {
47
- background-color: var(--radio-mark-color, var(--helix-color-foreground));
48
- block-size: calc(var(--_radio-size) * 0.4);
49
- border-radius: var(--helix-radii-full);
50
- content: "";
51
- inline-size: calc(var(--_radio-size) * 0.4);
52
-
53
- scale: 0;
54
- transition: scale var(--helix-duration-fast) var(--helix-easing-emphasized);
55
- }
56
-
57
- :host(:state(selected)) [part="box"]::after {
58
- scale: 1;
59
- }
60
-
61
- :host(:state(has-indicator)) [part="box"]::after {
62
- content: none;
63
- }
64
-
65
- slot[name="indicator"]::slotted(*) {
66
- block-size: var(--radio-indicator-size, calc(var(--_radio-size) * 0.75));
67
- color: var(--radio-mark-color, var(--helix-color-foreground));
68
- inline-size: var(--radio-indicator-size, calc(var(--_radio-size) * 0.75));
69
- scale: 0;
70
- transition: scale var(--helix-duration-fast) var(--helix-easing-emphasized);
71
- }
72
-
73
- :host(:state(selected)) slot[name="indicator"]::slotted(*) {
74
- scale: 1;
75
- }
76
-
77
- [part="item"]:focus-visible [part="box"] {
78
- outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);
79
- outline-offset: var(--helix-size-focus-offset);
80
- }
81
-
82
- [part="label"] {
83
- color: var(--helix-color-foreground);
84
- font-family: var(--helix-font-sans);
85
- font-size: var(--helix-text-sm);
86
- font-weight: var(--helix-weight-medium);
87
- line-height: var(--helix-leading-tight);
88
- }
89
-
90
- :host(:is([separation="filled"], [separation="outlined"])) {
91
- display: block;
92
- }
93
-
94
- :host(:is([separation="filled"], [separation="outlined"])) [part="item"] {
95
- align-items: start;
96
- background-color: var(--radio-card-background-color, var(--helix-color-surface));
97
- border: var(--helix-border-thin) solid var(--radio-card-border-color, var(--helix-color-border));
98
- border-radius: var(--helix-radii-sm);
99
- display: flex;
100
- gap: var(--helix-space-sm);
101
- inline-size: 100%;
102
- padding: var(--radio-card-padding, var(--helix-space-md));
103
- transition:
2
+ export const styles = createSheet(`:host {--_radio-size: var(--radio-size, var(--helix-size-checkbox));display: block;}[part="item"] {all: unset;align-items: center;box-sizing: border-box;cursor: pointer;display: inline-flex;gap: var(--helix-space-xs);}:host([disabled]) [part="item"] {cursor: default;}:host([disabled]) {opacity: 0.5;}[part="box"] {background-color: var(--radio-background-color, var(--helix-color-background));block-size: var(--_radio-size);border: var(--helix-border-thin) solid var(--radio-border-color, var(--helix-color-border));border-radius: var(--helix-radii-full);display: grid;flex: 0 0 auto;inline-size: var(--_radio-size);place-items: center;transition: border-color var(--helix-duration-fast) var(--helix-easing-standard);}:host(:not([disabled])) [part="item"]:hover [part="box"] {border-color: var(--radio-border-color, var(--helix-color-foreground-muted));}:host(:state(selected)) [part="box"] {border-color: var(--radio-border-color, var(--helix-color-foreground));}[part="box"]::after {background-color: var(--radio-mark-color, var(--helix-color-foreground));block-size: calc(var(--_radio-size) * 0.4);border-radius: var(--helix-radii-full);content: "";inline-size: calc(var(--_radio-size) * 0.4);scale: 0;transition: scale var(--helix-duration-fast) var(--helix-easing-emphasized);}:host(:state(selected)) [part="box"]::after {scale: 1;}:host(:state(has-indicator)) [part="box"]::after {content: none;}slot[name="indicator"]::slotted(*) {block-size: var(--radio-indicator-size, calc(var(--_radio-size) * 0.75));color: var(--radio-mark-color, var(--helix-color-foreground));inline-size: var(--radio-indicator-size, calc(var(--_radio-size) * 0.75));scale: 0;transition: scale var(--helix-duration-fast) var(--helix-easing-emphasized);}:host(:state(selected)) slot[name="indicator"]::slotted(*) {scale: 1;}[part="item"]:focus-visible [part="box"] {outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);outline-offset: var(--helix-size-focus-offset);}[part="label"] {color: var(--helix-color-foreground);font-family: var(--helix-font-sans);font-size: var(--helix-text-sm);font-weight: var(--helix-weight-medium);line-height: var(--helix-leading-tight);}:host(:is([separation="filled"], [separation="outlined"])) {display: block;}:host(:is([separation="filled"], [separation="outlined"])) [part="item"] {align-items: start;background-color: var(--radio-card-background-color, var(--helix-color-surface));border: var(--helix-border-thin) solid var(--radio-card-border-color, var(--helix-color-border));border-radius: var(--helix-radii-sm);display: flex;gap: var(--helix-space-sm);inline-size: 100%;padding: var(--radio-card-padding, var(--helix-space-md));transition:
104
3
  background-color var(--helix-duration-fast) var(--helix-easing-standard),
105
- border-color var(--helix-duration-fast) var(--helix-easing-standard);
106
- }
107
-
108
- :host([separation="filled"]) [part="item"] {
109
- border-color: transparent;
110
- }
111
-
112
- :host(:not([disabled]):is([separation="filled"], [separation="outlined"])) [part="item"]:hover {
113
- border-color: var(--helix-color-foreground-muted);
114
- }
115
-
116
- :host(:is([separation="filled"], [separation="outlined"]):state(selected)) [part="item"] {
117
- background-color: var(--helix-color-surface-raised);
118
- border-color: var(--helix-color-primary);
119
- box-shadow: 0 0 0 var(--helix-border-thick) var(--helix-color-primary);
120
- }
121
-
122
- :host(:is([separation="filled"], [separation="outlined"])) [part="item"]:focus-visible {
123
- outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);
124
- outline-offset: var(--helix-size-focus-offset);
125
- }
126
-
127
- :host(:is([separation="filled"], [separation="outlined"]))
4
+ border-color var(--helix-duration-fast) var(--helix-easing-standard);}:host([separation="filled"]) [part="item"] {border-color: transparent;}:host(:not([disabled]):is([separation="filled"], [separation="outlined"])) [part="item"]:hover {border-color: var(--helix-color-foreground-muted);}:host(:is([separation="filled"], [separation="outlined"]):state(selected)) [part="item"] {background-color: var(--helix-color-surface-raised);border-color: var(--helix-color-primary);box-shadow: 0 0 0 var(--helix-border-thick) var(--helix-color-primary);}:host(:is([separation="filled"], [separation="outlined"])) [part="item"]:focus-visible {outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);outline-offset: var(--helix-size-focus-offset);}:host(:is([separation="filled"], [separation="outlined"]))
128
5
  [part="item"]:focus-visible
129
- [part="box"] {
130
- outline: none;
131
- }
132
-
133
- :host(:is([separation="filled"], [separation="outlined"])) [part="label"] {
134
- font-size: var(--helix-text-md);
135
- line-height: var(--helix-leading-normal);
136
- }
137
-
138
- :host(:is([separation="filled"], [separation="outlined"])) [part="box"] {
139
- font-size: var(--helix-text-md);
140
- line-height: var(--helix-leading-normal);
141
- margin-block-start: calc((1lh - var(--_radio-size)) / 2);
142
- }
143
-
144
- :host(:is([separation="filled"], [separation="outlined"])[hide-control]) [part="box"] {
145
- display: none;
146
- }
147
-
148
- :host([variant="chip"]) [part="box"] {
149
- display: none;
150
- }
151
-
152
- :host([variant="chip"]) [part="item"] {
153
-
154
- --_radio-chip-lift: 2px;
155
-
156
- align-items: center;
157
- background-color: var(--helix-color-surface-sunken);
158
- block-size: var(--radio-chip-size, var(--helix-size-control));
159
- border-radius: var(--helix-radii-full);
160
- color: var(--helix-color-foreground-muted);
161
- cursor: pointer;
162
- display: inline-flex;
163
- inline-size: var(--radio-chip-size, var(--helix-size-control));
164
- justify-content: center;
165
- padding: 0;
166
- transition:
6
+ [part="box"] {outline: none;}:host(:is([separation="filled"], [separation="outlined"])) [part="label"] {font-size: var(--helix-text-md);line-height: var(--helix-leading-normal);}:host(:is([separation="filled"], [separation="outlined"])) [part="box"] {font-size: var(--helix-text-md);line-height: var(--helix-leading-normal);margin-block-start: calc((1lh - var(--_radio-size)) / 2);}:host(:is([separation="filled"], [separation="outlined"])[hide-control]) [part="box"] {display: none;}:host([variant="chip"]) [part="box"] {display: none;}:host([variant="chip"]) [part="item"] {--_radio-chip-lift: 2px;align-items: center;background-color: var(--helix-color-surface-sunken);block-size: var(--radio-chip-size, var(--helix-size-control));border-radius: var(--helix-radii-full);color: var(--helix-color-foreground-muted);cursor: pointer;display: inline-flex;inline-size: var(--radio-chip-size, var(--helix-size-control));justify-content: center;padding: 0;transition:
167
7
  background-color var(--helix-duration-fast) var(--helix-easing-standard),
168
8
  box-shadow var(--helix-duration-fast) var(--helix-easing-standard),
169
- translate var(--helix-duration-fast) var(--helix-easing-standard);
170
- }
171
-
172
- :host([variant="chip"]:state(selected)) [part="item"] {
173
- background-color: var(--helix-color-surface-inverse);
174
- box-shadow: var(--helix-shadow-md);
175
- color: var(--helix-color-foreground-inverse);
176
- translate: 0 calc(var(--_radio-chip-lift) * -1);
177
- }
178
-
179
- :host(:not([disabled])[variant="chip"]) [part="item"]:hover {
180
- translate: 0 calc(var(--_radio-chip-lift) / -2);
181
- }
182
-
183
- :host([variant="chip"]) [part="item"]:focus-visible {
184
- outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);
185
- outline-offset: var(--helix-size-focus-offset);
186
- }
187
-
188
- :host([variant="chip"]) [part="label"] {
189
- clip-path: inset(50%);
190
- block-size: 1px;
191
- inline-size: 1px;
192
- overflow: hidden;
193
- position: absolute;
194
- white-space: nowrap;
195
- }
196
-
197
- @media (prefers-reduced-motion: reduce) {
198
- :host([variant="chip"]) [part="item"] {
199
- transition: none;
200
- }
201
-
202
- :host([variant="chip"]:state(selected)) [part="item"],
203
- :host(:not([disabled])[variant="chip"]) [part="item"]:hover {
204
- translate: none;
205
- }
206
- }
207
-
208
- @media print {
209
- :host {
210
- box-shadow: none;
211
- print-color-adjust: exact;
212
- }
213
- }`);
9
+ translate var(--helix-duration-fast) var(--helix-easing-standard);}:host([variant="chip"]:state(selected)) [part="item"] {background-color: var(--helix-color-surface-inverse);box-shadow: var(--helix-shadow-md);color: var(--helix-color-foreground-inverse);translate: 0 calc(var(--_radio-chip-lift) * -1);}:host(:not([disabled])[variant="chip"]) [part="item"]:hover {translate: 0 calc(var(--_radio-chip-lift) / -2);}:host([variant="chip"]) [part="item"]:focus-visible {outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);outline-offset: var(--helix-size-focus-offset);}:host([variant="chip"]) [part="label"] {clip-path: inset(50%);block-size: 1px;inline-size: 1px;overflow: hidden;position: absolute;white-space: nowrap;}@media (prefers-reduced-motion: reduce) {:host([variant="chip"]) [part="item"] {transition: none;}:host([variant="chip"]:state(selected)) [part="item"],
10
+ :host(:not([disabled])[variant="chip"]) [part="item"]:hover {translate: none;}}@media print {:host {box-shadow: none;print-color-adjust: exact;}}`);
@@ -1,126 +1,13 @@
1
1
  import { createSheet } from '@fusion.dev/helix-core';
2
- export const styles = createSheet(`:host {
3
-
4
- --_rating-mark-size: var(--rating-size, var(--helix-size-icon-md));
5
- --_rating-mark-gap: var(--rating-gap, var(--helix-space-2xs));
6
-
7
- display: inline-flex;
8
- flex-direction: column;
9
- gap: var(--helix-space-2xs);
10
- }
11
-
12
- [part="field"] {
13
- align-items: center;
14
- display: inline-flex;
15
- gap: var(--helix-space-xs);
16
- }
17
-
18
- [part="marks"] {
19
- display: inline-flex;
20
- position: relative;
21
-
22
- touch-action: pan-y;
23
- }
24
-
25
- [part="track"],
26
- [part="fill"] {
27
- display: inline-flex;
28
- gap: var(--_rating-mark-gap);
29
- }
30
-
31
- [part="track"] {
32
- color: var(--rating-empty-color, var(--helix-color-border));
33
- }
34
-
35
- [part="fill"] {
36
- color: var(--rating-color, var(--helix-color-warning));
37
- inline-size: calc(
2
+ export const styles = createSheet(`:host {--_rating-mark-size: var(--rating-size, var(--helix-size-icon-md));--_rating-mark-gap: var(--rating-gap, var(--helix-space-2xs));display: inline-flex;flex-direction: column;gap: var(--helix-space-2xs);}[part="field"] {align-items: center;display: inline-flex;gap: var(--helix-space-xs);}[part="marks"] {display: inline-flex;position: relative;touch-action: pan-y;}[part="track"],
3
+ [part="fill"] {display: inline-flex;gap: var(--_rating-mark-gap);}[part="track"] {color: var(--rating-empty-color, var(--helix-color-border));}[part="fill"] {color: var(--rating-color, var(--helix-color-warning));inline-size: calc(
38
4
  var(--rating-full, 0) *
39
5
  (var(--_rating-mark-size) + var(--_rating-mark-gap)) +
40
6
  var(--rating-part, 0) *
41
7
  var(--_rating-mark-size)
42
- );
43
- inset-block: 0;
44
- inset-inline-start: 0;
45
- overflow: hidden;
46
- position: absolute;
47
- }
48
-
49
- [part="mark"] {
50
- --_rating-star: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2.6l2.9 5.9 6.5.9-4.7 4.6 1.1 6.5-5.8-3-5.8 3 1.1-6.5L2.6 9.4l6.5-.9z"/></svg>');
51
-
52
- background-color: currentcolor;
53
- block-size: var(--_rating-mark-size);
54
- flex: 0 0 auto;
55
- inline-size: var(--_rating-mark-size);
56
- mask-image: var(--rating-mark, var(--_rating-star));
57
- mask-position: center;
58
- mask-repeat: no-repeat;
59
- mask-size: contain;
60
- }
61
-
62
- [part="option"] {
63
- all: unset;
64
- box-sizing: border-box;
65
-
66
- cursor: pointer;
67
- inset-block: 0;
68
- position: absolute;
69
- }
70
-
71
- [part="option"] {
72
- --_rating-pitch: calc((100% + var(--_rating-mark-gap)) / var(--rating-steps, 1));
73
-
74
- inline-size: var(--_rating-pitch);
75
- inset-inline-start: calc(
8
+ );inset-block: 0;inset-inline-start: 0;overflow: hidden;position: absolute;}[part="mark"] {--_rating-star: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2.6l2.9 5.9 6.5.9-4.7 4.6 1.1 6.5-5.8-3-5.8 3 1.1-6.5L2.6 9.4l6.5-.9z"/></svg>');background-color: currentcolor;block-size: var(--_rating-mark-size);flex: 0 0 auto;inline-size: var(--_rating-mark-size);mask-image: var(--rating-mark, var(--_rating-star));mask-position: center;mask-repeat: no-repeat;mask-size: contain;}[part="option"] {all: unset;box-sizing: border-box;cursor: pointer;inset-block: 0;position: absolute;}[part="option"] {--_rating-pitch: calc((100% + var(--_rating-mark-gap)) / var(--rating-steps, 1));inline-size: var(--_rating-pitch);inset-inline-start: calc(
76
9
  (var(--rating-step, 1) - 1) *
77
10
  var(--_rating-pitch) -
78
11
  var(--_rating-mark-gap) /
79
12
  2
80
- );
81
- }
82
-
83
- [part="value"] {
84
- color: var(--helix-color-foreground-muted);
85
- font-size: var(--helix-text-sm);
86
- font-variant-numeric: tabular-nums;
87
- line-height: 1;
88
- }
89
-
90
- :host([shape="dots"]) {
91
- --_rating-mark-size: var(--rating-size, var(--helix-size-icon-sm));
92
- }
93
-
94
- :host([shape="dots"]) [part="mark"] {
95
- border-radius: var(--helix-radii-full);
96
- mask-image: none;
97
- }
98
-
99
- [part="option"]:focus-visible {
100
- border-radius: var(--helix-radii-sm);
101
- outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);
102
- outline-offset: var(--helix-size-focus-offset);
103
- }
104
-
105
- :host(:disabled) [part="option"] {
106
- cursor: not-allowed;
107
- }
108
-
109
- :host(:disabled) [part="marks"] {
110
- opacity: 0.5;
111
- }
112
-
113
- :host([readonly]) [part="marks"] {
114
- cursor: default;
115
- }
116
-
117
- [data-slotted] [part="mark"] {
118
- background-color: transparent;
119
- mask-image: none;
120
- }
121
-
122
- @media print {
123
- :host {
124
- print-color-adjust: exact;
125
- }
126
- }`);
13
+ );}[part="value"] {color: var(--helix-color-foreground-muted);font-size: var(--helix-text-sm);font-variant-numeric: tabular-nums;line-height: 1;}:host([shape="dots"]) {--_rating-mark-size: var(--rating-size, var(--helix-size-icon-sm));}:host([shape="dots"]) [part="mark"] {border-radius: var(--helix-radii-full);mask-image: none;}[part="option"]:focus-visible {border-radius: var(--helix-radii-sm);outline: var(--helix-size-focus-ring) solid var(--helix-color-focus-ring);outline-offset: var(--helix-size-focus-offset);}:host(:disabled) [part="option"] {cursor: not-allowed;}:host(:disabled) [part="marks"] {opacity: 0.5;}:host([readonly]) [part="marks"] {cursor: default;}[data-slotted] [part="mark"] {background-color: transparent;mask-image: none;}@media print {:host {print-color-adjust: exact;}}`);
@@ -51,7 +51,8 @@ export declare const loggedText: (value: unknown) => string;
51
51
  * - Writes each `helix-preview-render` into the root: the markup, the
52
52
  * stylesheet, the direction, the layout and the color mode. Scripts in the
53
53
  * markup run.
54
- * - Posts every console call and uncaught error as `helix-preview-console`.
54
+ * - Posts every console call and uncaught error as `helix-preview-console`,
55
+ * an uncaught one marked `uncaught`, which marks the preview `failed`.
55
56
  * - Posts `helix-preview-size` whenever what was drawn changes height.
56
57
  * - Posts `helix-preview-press` on every press, so menus outside close.
57
58
  *
@@ -71,7 +71,7 @@ export const servePreview = (options = {}) => {
71
71
  };
72
72
  }
73
73
  const failed = (event) => {
74
- post({ level: 'error', text: event.message, type: 'helix-preview-console' });
74
+ post({ level: 'error', text: event.message, type: 'helix-preview-console', uncaught: true });
75
75
  };
76
76
  const measure = () => {
77
77
  const boxes = [...root.children].flatMap(drawn);
@@ -18,5 +18,5 @@ export * from './root/sandbox-root.js';
18
18
  export * from './source/sandbox-source.js';
19
19
  export * from './status-bar/sandbox-status-bar.js';
20
20
  export * from './terminal/sandbox-terminal.js';
21
- export type { SandboxHighlight, SandboxToken } from './tokens.js';
21
+ export type { SandboxToken, SandboxTokenizer } from './tokens.js';
22
22
  export * from './toolbar/sandbox-toolbar.js';
@@ -1,13 +1,2 @@
1
1
  import { createSheet } from '@fusion.dev/helix-core';
2
- export const styles = createSheet(`:host {
3
- display: block;
4
- min-block-size: 0;
5
- }
6
-
7
- [part="frame"] {
8
- background-color: var(--helix-color-background);
9
- block-size: 100%;
10
- border: none;
11
- display: block;
12
- inline-size: 100%;
13
- }`);
2
+ export const styles = createSheet(`:host {display: block;min-block-size: 0;}[part="frame"] {background-color: var(--helix-color-background);block-size: 100%;border: none;display: block;inline-size: 100%;}`);
@@ -19,6 +19,8 @@ export interface PreviewConsole {
19
19
  level: 'log' | 'info' | 'warn' | 'error';
20
20
  text: string;
21
21
  type: 'helix-preview-console';
22
+ /** Set for an error the example threw and did not catch, which marks the preview `failed`. */
23
+ uncaught?: boolean;
22
24
  }
23
25
  /**
24
26
  * A press inside the frame, which is the one event the page cannot see for
@@ -57,6 +59,13 @@ export type PreviewMessage = PreviewConsole | PreviewPress | PreviewReady | Prev
57
59
  * let a document on the same origin remove its own sandbox, which is the same
58
60
  * as having none.
59
61
  *
62
+ * **A preview says where it is.** It is `:state(loading)` from the moment it
63
+ * has a `src` until that document can take the example, and again through
64
+ * `reload()`. It is `:state(failed)` once the example throws an error it does
65
+ * not catch, until the next source is sent, which a frame on `servePreview`
66
+ * reports. A page draws its own spinner or message from either, such as a
67
+ * sibling shown by `helix-sandbox-preview:state(failed) + .message`.
68
+ *
60
69
  * @since 0.1.0
61
70
  * @status stable
62
71
  * @aliases Result, Output
@@ -66,6 +75,9 @@ export type PreviewMessage = PreviewConsole | PreviewPress | PreviewReady | Prev
66
75
  * @event {HelixResizeEvent} helix-resize - Fired when the height of the frame's content changes, with the new height.
67
76
  *
68
77
  * @csspart frame - The iframe.
78
+ *
79
+ * @cssstate failed - Since the example threw an error it did not catch, until the next source is sent.
80
+ * @cssstate loading - While the frame's document loads, until it can take the example.
69
81
  */
70
82
  export declare class HelixSandboxPreview extends HelixElement {
71
83
  /**
@@ -127,7 +139,9 @@ export declare class HelixSandboxPreview extends HelixElement {
127
139
  private ready;
128
140
  private get frame();
129
141
  /**
130
- * The frame's document has finished loading, so its listener exists.
142
+ * The frame's document has finished loading, so its listener exists, the
143
+ * example is sent and the preview is no longer `loading`. The frame saying
144
+ * `helix-preview-ready` lands here too.
131
145
  *
132
146
  * **The announcement is one shot and the parent can miss it.** The frame posts
133
147
  * `helix-preview-ready` at the end of its own module evaluation and never
@@ -180,8 +194,8 @@ export declare class HelixSandboxPreview extends HelixElement {
180
194
  * thing on the page already entitled to both.
181
195
  */
182
196
  private static readonly target;
183
- /** Set while a coalesced send is waiting, so only one is ever queued. */
184
- private pending;
197
+ /** Holds a coalesced send, so only one is ever queued, and drops it on disconnect. */
198
+ private readonly settle;
185
199
  /**
186
200
  * Sends once the typing stops, replacing anything already waiting.
187
201
  *
@@ -211,6 +225,8 @@ export declare class HelixSandboxPreview extends HelixElement {
211
225
  * new document announces itself the same way the first one did.
212
226
  */
213
227
  reload(): void;
228
+ /** A new document is on its way, so nothing is sent until it listens, and nothing has failed in it. */
229
+ private unready;
214
230
  protected updated(changed: PropertyValues): void;
215
231
  protected render(): TemplateResult;
216
232
  static styles: CSSResultGroup;
@@ -5,7 +5,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
7
  var HelixSandboxPreview_1;
8
- import { customElement, HelixConsoleEvent, HelixElement, HelixResizeEvent, } from '@fusion.dev/helix-core';
8
+ import { customElement, DelayController, HelixConsoleEvent, HelixElement, HelixResizeEvent, } from '@fusion.dev/helix-core';
9
9
  const SETTLE = 120;
10
10
  import { html } from 'lit';
11
11
  import { property } from 'lit/decorators.js';
@@ -20,6 +20,7 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
20
20
  this.ready = false;
21
21
  this.handleFrameLoad = () => {
22
22
  this.ready = true;
23
+ this.toggleState('loading', false);
23
24
  this.send();
24
25
  };
25
26
  this.handleMessage = (event) => {
@@ -27,12 +28,14 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
27
28
  return;
28
29
  }
29
30
  if (event.data?.type === 'helix-preview-ready') {
30
- this.ready = true;
31
- this.send();
31
+ this.handleFrameLoad();
32
32
  return;
33
33
  }
34
34
  if (event.data?.type === 'helix-preview-console') {
35
35
  this.dispatchEvent(new HelixConsoleEvent({ level: event.data.level, text: event.data.text }));
36
+ if (event.data.uncaught) {
37
+ this.toggleState('failed', true);
38
+ }
36
39
  }
37
40
  if (event.data?.type === 'helix-preview-press') {
38
41
  this.dispatchEvent(new PointerEvent('pointerdown', { bubbles: true, composed: true }));
@@ -41,6 +44,7 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
41
44
  this.dispatchEvent(new HelixResizeEvent({ size: event.data.size }));
42
45
  }
43
46
  };
47
+ this.settle = new DelayController(this);
44
48
  }
45
49
  static { HelixSandboxPreview_1 = this; }
46
50
  get frame() {
@@ -48,11 +52,10 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
48
52
  }
49
53
  static { this.target = '*'; }
50
54
  scheduleSend() {
51
- clearTimeout(this.pending);
52
- this.pending = setTimeout(() => {
53
- this.pending = undefined;
55
+ this.settle.start(SETTLE, () => {
56
+ this.toggleState('failed', false);
54
57
  this.send();
55
- }, SETTLE);
58
+ });
56
59
  }
57
60
  send() {
58
61
  if (!this.ready) {
@@ -74,8 +77,6 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
74
77
  }
75
78
  disconnectedCallback() {
76
79
  super.disconnectedCallback();
77
- clearTimeout(this.pending);
78
- this.pending = undefined;
79
80
  window.removeEventListener('message', this.handleMessage);
80
81
  }
81
82
  reload() {
@@ -83,13 +84,18 @@ let HelixSandboxPreview = class HelixSandboxPreview extends HelixElement {
83
84
  if (!frame) {
84
85
  return;
85
86
  }
86
- this.ready = false;
87
+ this.unready();
87
88
  frame.src = this.src;
88
89
  }
90
+ unready() {
91
+ this.ready = false;
92
+ this.toggleState('failed', false);
93
+ this.toggleState('loading', this.src !== '');
94
+ }
89
95
  updated(changed) {
90
96
  super.updated(changed);
91
97
  if (changed.has('src')) {
92
- this.ready = false;
98
+ this.unready();
93
99
  return;
94
100
  }
95
101
  if (changed.has('source') || changed.has('styles')) {
@@ -1,71 +1,4 @@
1
1
  import { createSheet } from '@fusion.dev/helix-core';
2
- export const styles = createSheet(`:host {
3
- background-color: var(--helix-color-background);
4
- display: grid;
5
- grid-template-rows: auto minmax(0, 1fr) auto;
6
- min-block-size: var(--sandbox-min-block-size, 20rem);
7
- overflow: hidden;
8
- }
9
-
10
- ::slotted([slot="toolbar"]) {
11
- grid-row: 1;
12
- }
13
-
14
- [part="body"] {
15
- grid-row: 2;
16
- }
17
-
18
- ::slotted([slot="status"]) {
19
- grid-row: 3;
20
- }
21
-
22
- [part="body"],
23
- [part="panes"] {
24
- --splitter-color: var(--sandbox-separator-color, var(--helix-color-border));
25
- --splitter-target: calc(var(--sandbox-grab, var(--helix-space-2xs)) * 2);
26
- min-block-size: 0;
27
- min-inline-size: 0;
28
- }
29
-
30
- [part="panes"] {
31
- block-size: 100%;
32
- }
33
-
34
- [part="body"]:not([data-panel])::part(separator) {
35
- display: none;
36
- }
37
-
38
- [part="body"]:not([data-panel])::part(corner) {
39
- display: none;
40
- }
41
-
42
- [part="pane"] {
43
- block-size: 100%;
44
- min-block-size: 0;
45
- min-inline-size: 0;
46
- overflow: hidden;
47
- }
48
-
49
- [part="panel"] {
50
- block-size: 100%;
51
- min-block-size: 0;
52
- overflow: hidden;
53
- }
54
-
55
- ::slotted([slot="panel"]) {
56
- block-size: 100%;
57
- min-block-size: 0;
58
- }
59
-
60
- ::slotted(helix-sandbox-preview) {
61
- background-color: var(--helix-color-background);
62
- block-size: 100%;
63
- color: var(--helix-color-foreground);
64
- display: block;
65
- }
66
-
67
- @media print {
68
- :host {
69
- display: none;
70
- }
71
- }`);
2
+ export const styles = createSheet(`:host {background-color: var(--helix-color-background);display: grid;grid-template-rows: auto minmax(0, 1fr) auto;min-block-size: var(--sandbox-min-block-size, 20rem);overflow: hidden;}::slotted([slot="toolbar"]) {grid-row: 1;}[part="body"] {grid-row: 2;}::slotted([slot="status"]) {grid-row: 3;}[part="body"],
3
+ [part="panes"] {--splitter-color: var(--sandbox-separator-color, var(--helix-color-border));--splitter-target: calc(var(--sandbox-grab, var(--helix-space-2xs)) * 2);min-block-size: 0;min-inline-size: 0;}[part="panes"] {block-size: 100%;}[part="body"]:not([data-panel])::part(corner),
4
+ [part="body"]:not([data-panel])::part(separator) {display: none;}[part="pane"] {block-size: 100%;min-block-size: 0;min-inline-size: 0;overflow: hidden;}[part="panel"] {block-size: 100%;min-block-size: 0;overflow: hidden;}::slotted([slot="panel"]) {block-size: 100%;min-block-size: 0;}::slotted(helix-sandbox-preview) {background-color: var(--helix-color-background);block-size: 100%;color: var(--helix-color-foreground);display: block;}@media print {:host {display: none;}}`);
@@ -41,16 +41,18 @@ import type { CSSResultGroup, PropertyValues, TemplateResult } from 'lit';
41
41
  * @event {HelixResizeEvent} helix-resize - Fired by the preview pane when the height of the frame's content changes, with the new height.
42
42
  * @event {HelixSplitEvent} helix-split - Fired after the panes' divider settled somewhere new, with the lead pane's share.
43
43
  *
44
- * @csspart body - The splitter holding the panes above the panel.
44
+ * @csspart body - The splitter holding the panes above the panel. `::part(body):state(dragging)` matches while its divider is held.
45
45
  * @csspart corner - The handle where the two dividers cross.
46
46
  * @csspart pane - Either pane.
47
47
  * @csspart panel - The box that holds the slotted panel.
48
- * @csspart panes - The splitter holding the source and preview panes.
48
+ * @csspart panes - The splitter holding the source and preview panes. `::part(panes):state(dragging)` matches while its divider is held.
49
49
  * @csspart separator - Either divider.
50
50
  *
51
51
  * @cssproperty --sandbox-grab - The invisible width of a divider's drag target.
52
52
  * @cssproperty --sandbox-min-block-size - Minimum height of the sandbox.
53
53
  * @cssproperty --sandbox-separator-color - Color of the divider.
54
+ *
55
+ * @cssstate panel-collapsed - While there is a panel and it is no taller than `panel-collapsed-size`.
54
56
  */
55
57
  export declare class HelixSandbox extends HelixElement {
56
58
  /**
@@ -176,8 +178,12 @@ export declare class HelixSandbox extends HelixElement {
176
178
  * back into the position that answered it.
177
179
  */
178
180
  private readonly watch;
179
- /** The panel as a share of the body, which is what the splitter takes. */
180
- private get panelShare();
181
+ /**
182
+ * A panel height as a share of the body, which is what the splitter takes,
183
+ * held to what the panel may have. A height that is no number is the
184
+ * default one.
185
+ */
186
+ private shareOf;
181
187
  /**
182
188
  * Where the outer divider goes: everything the panel is not.
183
189
  *
@@ -305,6 +311,12 @@ export declare class HelixSandbox extends HelixElement {
305
311
  private requestSplit;
306
312
  /** As `requestSplit`, for the panel, whose value is pixels rather than a share. */
307
313
  private requestPanelSize;
314
+ /**
315
+ * Takes a request a splitter of this sandbox made for itself, stopped and
316
+ * refused, and gives its value. Gives nothing for one that came up from
317
+ * something slotted into a pane, which passes through untouched.
318
+ */
319
+ private claim;
308
320
  /**
309
321
  * Answers a divider that has asked to move.
310
322
  *