@aceshooting/lyra-ui 27.0.0 → 28.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (397) hide show
  1. package/CHANGELOG.md +67 -63
  2. package/README.md +7 -3
  3. package/dist/cli/css-declarations.mjs +1 -0
  4. package/dist/cli/lyra-rename-ledger.mjs +1 -1
  5. package/dist/cli/migrate-wa.mjs +9 -4
  6. package/dist/cli/migration-contract.json +1 -1
  7. package/dist/cli/migration-renames.mjs +2 -2
  8. package/dist/cli/migration-theme-scopes.mjs +3 -0
  9. package/dist/cli/theme-scope-vocabulary.generated.mjs +1 -0
  10. package/dist/components/agent-tools/activity-feed/activity-feed.class.js +1 -1
  11. package/dist/components/agent-tools/agent-eval-dashboard/agent-eval-dashboard.class.js +1 -1
  12. package/dist/components/agent-tools/agent-question/agent-question.class.js +1 -1
  13. package/dist/components/agent-tools/agent-run/agent-run.class.js +1 -1
  14. package/dist/components/agent-tools/agent-trace/agent-trace.class.js +1 -1
  15. package/dist/components/agent-tools/approval-queue/approval-queue.class.js +1 -1
  16. package/dist/components/agent-tools/artifact-panel/artifact-panel.class.js +1 -1
  17. package/dist/components/agent-tools/background-runs/background-runs.class.js +1 -1
  18. package/dist/components/agent-tools/browser-frame/browser-frame.class.js +1 -1
  19. package/dist/components/agent-tools/budget-meter/budget-meter.class.js +1 -1
  20. package/dist/components/agent-tools/change-review/change-review.class.js +1 -1
  21. package/dist/components/agent-tools/commit-card/commit-card.class.js +1 -1
  22. package/dist/components/agent-tools/compare-panel/compare-panel.class.js +1 -1
  23. package/dist/components/agent-tools/confirm-bar/confirm-bar.class.js +1 -1
  24. package/dist/components/agent-tools/connector-manager/connector-manager.class.js +1 -1
  25. package/dist/components/agent-tools/context-inspector/context-inspector.class.js +1 -1
  26. package/dist/components/agent-tools/eval-dataset/eval-dataset.class.js +1 -1
  27. package/dist/components/agent-tools/eval-result/eval-result.class.js +1 -1
  28. package/dist/components/agent-tools/evaluation-run/evaluation-run.class.js +1 -1
  29. package/dist/components/agent-tools/mcp-app/mcp-app.class.js +1 -1
  30. package/dist/components/agent-tools/permission-grant/permission-grant.class.js +1 -1
  31. package/dist/components/agent-tools/permission-rules/permission-rules.class.js +1 -1
  32. package/dist/components/agent-tools/policy-summary/policy-summary.class.js +1 -1
  33. package/dist/components/agent-tools/prompt-studio/prompt-studio.class.js +1 -1
  34. package/dist/components/agent-tools/result-card/result-field.class.js +1 -1
  35. package/dist/components/agent-tools/schema-viewer/schema-viewer.class.js +1 -1
  36. package/dist/components/agent-tools/span-waterfall/span-waterfall.class.js +1 -1
  37. package/dist/components/agent-tools/stack-trace/stack-trace.class.js +1 -1
  38. package/dist/components/agent-tools/subagent-panel/subagent-panel.class.js +2 -2
  39. package/dist/components/agent-tools/task-list/task-list.class.js +2 -2
  40. package/dist/components/agent-tools/terminal/terminal.class.js +1 -1
  41. package/dist/components/agent-tools/test-results/test-results.class.js +1 -1
  42. package/dist/components/agent-tools/thinking-panel/thinking-panel.class.js +1 -1
  43. package/dist/components/agent-tools/tool-approval-dialog/tool-approval-dialog.class.js +1 -1
  44. package/dist/components/agent-tools/tool-call-block/tool-call-block.class.js +1 -1
  45. package/dist/components/agent-tools/tool-call-chip/tool-call-chip.class.js +1 -1
  46. package/dist/components/agent-tools/tool-param-form/tool-param-form.class.js +1 -1
  47. package/dist/components/agent-tools/tool-result-dialog/tool-result-dialog.class.js +1 -1
  48. package/dist/components/agent-tools/tool-result-view/tool-result-view.class.js +1 -1
  49. package/dist/components/agent-tools/tool-select-dialog/tool-select-dialog.class.js +1 -1
  50. package/dist/components/agent-tools/tool-timeline/tool-timeline.class.js +1 -1
  51. package/dist/components/agent-tools/trace-tree/trace-tree.class.js +2 -2
  52. package/dist/components/charts/chart/box-plot.class.d.ts +4 -2
  53. package/dist/components/charts/chart/box-plot.class.js +6 -5
  54. package/dist/components/charts/chart/chart-token-cache.js +2 -2
  55. package/dist/components/charts/chart/chart.class.d.ts +6 -4
  56. package/dist/components/charts/chart/chart.class.js +8 -7
  57. package/dist/components/charts/chart/histogram.class.js +1 -1
  58. package/dist/components/charts/chart/lite-chart.class.js +1 -1
  59. package/dist/components/conversation/agent-workspace/agent-workspace.class.js +1 -1
  60. package/dist/components/conversation/audio-visualizer/audio-visualizer.class.js +1 -1
  61. package/dist/components/conversation/branch-picker/branch-picker.class.js +1 -1
  62. package/dist/components/conversation/chat-composer/chat-composer.class.js +1 -1
  63. package/dist/components/conversation/chat-message/chat-message.class.js +1 -1
  64. package/dist/components/conversation/chat-viewport/chat-viewport.class.js +1 -1
  65. package/dist/components/conversation/checkpoint/checkpoint.class.js +1 -1
  66. package/dist/components/conversation/code-block/code-block-base.class.js +1 -1
  67. package/dist/components/conversation/code-block/code-block-core.class.js +1 -1
  68. package/dist/components/conversation/code-block/code-block.class.js +1 -1
  69. package/dist/components/conversation/conversation-item/conversation-item.class.js +1 -1
  70. package/dist/components/conversation/generation-metrics/generation-metrics.class.js +1 -1
  71. package/dist/components/conversation/handoff-divider/handoff-divider.class.js +1 -1
  72. package/dist/components/conversation/markdown/markdown-base.class.js +1 -1
  73. package/dist/components/conversation/markdown/markdown-core.class.js +1 -1
  74. package/dist/components/conversation/markdown/markdown.class.js +1 -1
  75. package/dist/components/conversation/message-actions/message-actions.class.js +1 -1
  76. package/dist/components/conversation/message-feedback/message-feedback.class.js +1 -1
  77. package/dist/components/conversation/message-parts/message-parts.class.js +1 -1
  78. package/dist/components/conversation/model-select/model-select.class.js +1 -1
  79. package/dist/components/conversation/model-settings-panel/model-settings-panel.class.js +1 -1
  80. package/dist/components/conversation/prompt-input/prompt-input.class.js +1 -1
  81. package/dist/components/conversation/prompt-queue/prompt-queue.class.js +1 -1
  82. package/dist/components/conversation/push-to-talk/push-to-talk.class.js +1 -1
  83. package/dist/components/conversation/realtime-session/realtime-session.class.js +1 -1
  84. package/dist/components/conversation/selection-toolbar/selection-toolbar.class.js +1 -1
  85. package/dist/components/conversation/stream-status/stream-status.class.js +1 -1
  86. package/dist/components/conversation/suggestion-chips/suggestion-chips.class.js +1 -1
  87. package/dist/components/conversation/thread-list/thread-list.class.js +1 -1
  88. package/dist/components/conversation/transcript-feed/transcript-feed.class.js +1 -1
  89. package/dist/components/conversation/typing-indicator/typing-indicator.class.js +1 -1
  90. package/dist/components/conversation/usage-badge/usage-badge.class.js +1 -1
  91. package/dist/components/conversation/voice-picker/voice-picker.class.js +1 -1
  92. package/dist/components/data/calendar/calendar.class.js +1 -1
  93. package/dist/components/data/condition-builder/condition-builder.class.js +1 -1
  94. package/dist/components/data/context-meter/context-meter.class.js +1 -1
  95. package/dist/components/data/data-grid/data-grid.class.d.ts +2 -2
  96. package/dist/components/data/data-grid/data-grid.class.js +3 -3
  97. package/dist/components/data/document-library/document-library.class.js +1 -1
  98. package/dist/components/data/env-list/env-list.class.js +1 -1
  99. package/dist/components/data/file-tree/file-tree.class.d.ts +2 -2
  100. package/dist/components/data/file-tree/file-tree.class.js +1 -1
  101. package/dist/components/data/flow-canvas/flow-canvas.class.js +1 -1
  102. package/dist/components/data/flow-controls/flow-controls.class.js +1 -1
  103. package/dist/components/data/flow-minimap/flow-minimap.class.js +1 -1
  104. package/dist/components/data/flow-node/flow-node.class.js +1 -1
  105. package/dist/components/data/flow-run-status/flow-run-status.class.js +1 -1
  106. package/dist/components/data/funnel/funnel.class.js +1 -1
  107. package/dist/components/data/gauge/gauge.class.js +1 -1
  108. package/dist/components/data/graph-query-builder/graph-query-builder.class.js +1 -1
  109. package/dist/components/data/heatmap/heatmap.class.d.ts +2 -1
  110. package/dist/components/data/heatmap/heatmap.class.js +2 -2
  111. package/dist/components/data/heatmap/heatmap.styles.js +1 -1
  112. package/dist/components/data/pagination/pagination.class.d.ts +2 -0
  113. package/dist/components/data/pagination/pagination.class.js +1 -1
  114. package/dist/components/data/pagination/pagination.styles.js +1 -1
  115. package/dist/components/data/sequence-strip/sequence-strip.class.js +1 -1
  116. package/dist/components/data/sparkline/sparkline.class.js +1 -1
  117. package/dist/components/data/stat/stat.class.js +1 -1
  118. package/dist/components/data/table/table.class.d.ts +23 -2
  119. package/dist/components/data/table/table.class.js +5 -3
  120. package/dist/components/data/table/table.styles.js +1 -1
  121. package/dist/components/data/timeline/timeline.class.js +1 -1
  122. package/dist/components/data/tree/tree.class.js +1 -1
  123. package/dist/components/data/word-cloud/word-cloud.class.js +1 -1
  124. package/dist/components/forms/button/button.class.js +1 -1
  125. package/dist/components/forms/checkbox/checkbox.class.js +1 -1
  126. package/dist/components/forms/checkbox-group/checkbox-group.class.js +1 -1
  127. package/dist/components/forms/code-editor/code-editor.class.js +1 -1
  128. package/dist/components/forms/color-picker/color-picker.class.d.ts +8 -4
  129. package/dist/components/forms/color-picker/color-picker.class.js +2 -2
  130. package/dist/components/forms/combobox/combobox.class.js +1 -1
  131. package/dist/components/forms/country-picker/country-picker.class.js +1 -1
  132. package/dist/components/forms/currency-picker/currency-picker.class.js +1 -1
  133. package/dist/components/forms/date-picker/date-input.class.js +1 -1
  134. package/dist/components/forms/date-picker/date-picker.class.js +1 -1
  135. package/dist/components/forms/emoji-picker/emoji-data-loader.js +1 -1
  136. package/dist/components/forms/emoji-picker/emoji-picker.class.d.ts +7 -4
  137. package/dist/components/forms/emoji-picker/emoji-picker.class.js +5 -5
  138. package/dist/components/forms/icon-button/icon-button.class.d.ts +4 -0
  139. package/dist/components/forms/icon-button/icon-button.class.js +1 -1
  140. package/dist/components/forms/icon-button/icon-button.styles.js +1 -1
  141. package/dist/components/forms/input/input-shared.js +1 -1
  142. package/dist/components/forms/input/input.class.js +1 -1
  143. package/dist/components/forms/input/native-time-input.class.js +1 -1
  144. package/dist/components/forms/input/number-input.class.js +1 -1
  145. package/dist/components/forms/input/time-input.class.js +1 -1
  146. package/dist/components/forms/locale-picker/locale-picker.class.js +1 -1
  147. package/dist/components/forms/otp-input/otp-input.class.js +1 -1
  148. package/dist/components/forms/phone-input/phone-input.class.js +1 -1
  149. package/dist/components/forms/radio/radio-group.class.js +1 -1
  150. package/dist/components/forms/radio/radio.class.js +1 -1
  151. package/dist/components/forms/rubric-form/rubric-form.class.js +4 -4
  152. package/dist/components/forms/select/select.class.js +1 -1
  153. package/dist/components/forms/signature-pad/signature-pad.class.js +1 -1
  154. package/dist/components/forms/slider/slider.class.js +1 -1
  155. package/dist/components/forms/switch/switch.class.js +1 -1
  156. package/dist/components/forms/textarea/textarea.class.js +1 -1
  157. package/dist/components/forms/time-range/time-range.class.js +1 -1
  158. package/dist/components/forms/time-zone-picker/time-zone-picker.class.js +1 -1
  159. package/dist/components/forms/token-input/token-input.class.js +1 -1
  160. package/dist/components/forms/unit-picker/unit-picker.class.js +1 -1
  161. package/dist/components/layout/app-rail/app-rail-item.class.js +1 -1
  162. package/dist/components/layout/app-rail/app-rail.class.d.ts +70 -7
  163. package/dist/components/layout/app-rail/app-rail.class.js +16 -4
  164. package/dist/components/layout/app-rail/app-rail.styles.js +1 -1
  165. package/dist/components/layout/app-rail-group/app-rail-group.class.js +1 -1
  166. package/dist/components/layout/breadcrumb/breadcrumb.class.js +1 -1
  167. package/dist/components/layout/card/card.class.js +1 -1
  168. package/dist/components/layout/carousel/carousel.class.js +1 -1
  169. package/dist/components/layout/command-palette/command-palette.class.js +1 -1
  170. package/dist/components/layout/dashboard-grid/dashboard-grid.class.js +1 -1
  171. package/dist/components/layout/details/accordion-item.class.js +1 -1
  172. package/dist/components/layout/details/details.class.js +1 -1
  173. package/dist/components/layout/dock-panel/dock-panel.class.js +1 -1
  174. package/dist/components/layout/drilldown-panel/drilldown-panel.class.js +1 -1
  175. package/dist/components/layout/filter-bar/filter-bar.class.js +1 -1
  176. package/dist/components/layout/menu/menu.class.js +1 -1
  177. package/dist/components/layout/menubar/menubar.class.js +1 -1
  178. package/dist/components/layout/multi-split/multi-split.class.js +1 -1
  179. package/dist/components/layout/navigation-menu/navigation-menu.class.js +1 -1
  180. package/dist/components/layout/page/page.class.js +1 -1
  181. package/dist/components/layout/reorder-list/reorder-item.class.js +1 -1
  182. package/dist/components/layout/reorder-list/reorder-list.class.js +1 -1
  183. package/dist/components/layout/responsive-panel/responsive-panel.class.js +1 -1
  184. package/dist/components/layout/scroller/scroller.class.js +1 -1
  185. package/dist/components/layout/segmented/segmented.class.d.ts +7 -4
  186. package/dist/components/layout/segmented/segmented.styles.js +1 -1
  187. package/dist/components/layout/split-panel/split-panel.class.js +1 -1
  188. package/dist/components/layout/tab-group/tab-group.class.js +1 -1
  189. package/dist/components/layout/tab-group/tab.class.js +1 -1
  190. package/dist/components/layout/virtual-list/virtual-list.styles.js +1 -1
  191. package/dist/components/layout/widget/widget.class.js +1 -1
  192. package/dist/components/media/animated-image/animated-image.class.js +1 -1
  193. package/dist/components/media/attachment-chip/attachment-chip.class.js +1 -1
  194. package/dist/components/media/attachment-trigger/attachment-trigger.class.js +2 -2
  195. package/dist/components/media/av-player/av-player.class.js +1 -1
  196. package/dist/components/media/avatar-group/avatar-group.class.js +1 -1
  197. package/dist/components/media/drop-zone/drop-zone.class.js +1 -1
  198. package/dist/components/media/file-icon/file-icon.class.js +1 -1
  199. package/dist/components/media/file-input/file-input.class.js +1 -1
  200. package/dist/components/media/flag/flag.class.js +1 -1
  201. package/dist/components/media/image-comparer/image-comparer.class.js +1 -1
  202. package/dist/components/media/image-viewer/image-viewer.class.d.ts +2 -1
  203. package/dist/components/media/image-viewer/image-viewer.class.js +4 -2
  204. package/dist/components/media/image-viewer/image-viewer.styles.js +1 -1
  205. package/dist/components/media/lightbox/lightbox.class.js +1 -1
  206. package/dist/components/media/map/map.class.js +1 -1
  207. package/dist/components/media/media-card/media-card.class.js +1 -1
  208. package/dist/components/media/pan-zoom/pan-zoom.class.js +1 -1
  209. package/dist/components/media/qr-code/qr-code.class.d.ts +2 -2
  210. package/dist/components/media/qr-code/qr-code.class.js +1 -1
  211. package/dist/components/media/sequence-playback/sequence-playback.class.js +1 -1
  212. package/dist/components/media/video/video.class.js +1 -1
  213. package/dist/components/media/video-playlist/video-playlist.class.js +1 -1
  214. package/dist/components/media/zoomable-frame/zoomable-frame.class.js +1 -1
  215. package/dist/components/overlays/alert/alert.class.js +1 -1
  216. package/dist/components/overlays/badge/tag.class.js +1 -1
  217. package/dist/components/overlays/callout/callout.class.js +1 -1
  218. package/dist/components/overlays/chip/chip-group.class.js +1 -1
  219. package/dist/components/overlays/chip/chip.class.js +1 -1
  220. package/dist/components/overlays/context-menu/context-menu.class.js +1 -1
  221. package/dist/components/overlays/dialog/confirm.js +1 -1
  222. package/dist/components/overlays/dialog/dialog.class.js +1 -1
  223. package/dist/components/overlays/kbd/kbd.class.js +1 -1
  224. package/dist/components/overlays/overlay/popover.class.js +1 -1
  225. package/dist/components/overlays/overlay/tooltip.class.js +1 -1
  226. package/dist/components/overlays/progress/progress-bar.class.js +1 -1
  227. package/dist/components/overlays/progress/progress-ring.class.js +1 -1
  228. package/dist/components/overlays/rating/rating.class.js +1 -1
  229. package/dist/components/overlays/skeleton/skeleton.class.js +1 -1
  230. package/dist/components/overlays/spinner/spinner.class.js +1 -1
  231. package/dist/components/overlays/toast/toast-item.class.js +1 -1
  232. package/dist/components/overlays/toast/toast.class.js +1 -1
  233. package/dist/components/retrieval/chunk-inspector/chunk-inspector.class.js +1 -1
  234. package/dist/components/retrieval/citation-badge/citation-badge.class.js +1 -1
  235. package/dist/components/retrieval/claim-evidence/claim-evidence.class.js +1 -1
  236. package/dist/components/retrieval/community-card/community-card.class.js +1 -1
  237. package/dist/components/retrieval/embedding-explorer/embedding-explorer.class.js +1 -1
  238. package/dist/components/retrieval/entity-card/entity-card.class.js +1 -1
  239. package/dist/components/retrieval/entity-chip/entity-chip.class.js +1 -1
  240. package/dist/components/retrieval/entity-dossier/entity-dossier.class.js +1 -1
  241. package/dist/components/retrieval/graph/graph.class.js +1 -1
  242. package/dist/components/retrieval/graph-legend/graph-legend.class.js +1 -1
  243. package/dist/components/retrieval/grounding-summary/grounding-summary.class.js +2 -2
  244. package/dist/components/retrieval/ingestion-queue/ingestion-queue.class.js +1 -1
  245. package/dist/components/retrieval/knowledge-base/knowledge-base.class.js +1 -1
  246. package/dist/components/retrieval/knowledge-base-admin/knowledge-base-admin.class.js +1 -1
  247. package/dist/components/retrieval/knowledge-graph-explorer/knowledge-graph-explorer.class.js +1 -1
  248. package/dist/components/retrieval/memory-panel/memory-panel.class.js +1 -1
  249. package/dist/components/retrieval/mind-map/mind-map.class.js +1 -1
  250. package/dist/components/retrieval/neighbor-list/neighbor-list.class.js +1 -1
  251. package/dist/components/retrieval/node-palette/node-palette.class.js +1 -1
  252. package/dist/components/retrieval/path-strip/path-strip.class.js +1 -1
  253. package/dist/components/retrieval/provenance-panel/provenance-panel.class.js +1 -1
  254. package/dist/components/retrieval/rag-answer/rag-answer.class.js +1 -1
  255. package/dist/components/retrieval/rag-eval-dashboard/rag-eval-dashboard.class.js +1 -1
  256. package/dist/components/retrieval/research-progress/research-progress.class.js +1 -1
  257. package/dist/components/retrieval/retrieval-compare/retrieval-compare.class.js +1 -1
  258. package/dist/components/retrieval/retrieval-results/retrieval-results.class.js +1 -1
  259. package/dist/components/retrieval/retrieval-search/retrieval-search.class.js +1 -1
  260. package/dist/components/retrieval/retrieval-trace/retrieval-trace.class.js +1 -1
  261. package/dist/components/retrieval/source-card/source-card.class.js +1 -1
  262. package/dist/components/retrieval/source-list/source-list.class.js +1 -1
  263. package/dist/components/retrieval/source-picker/source-picker.class.js +1 -1
  264. package/dist/components/utility/copy-button/copy-button.class.js +1 -1
  265. package/dist/components/utility/diff-view/diff-view.class.js +1 -1
  266. package/dist/components/utility/export-button/export-button.class.js +1 -1
  267. package/dist/components/utility/icon/icon.class.js +1 -1
  268. package/dist/components/utility/json-viewer/json-viewer.class.js +1 -1
  269. package/dist/components/utility/known-date/known-date.class.js +1 -1
  270. package/dist/components/utility/mention-popover/mention-popover.class.js +1 -1
  271. package/dist/components/utility/poll-status/poll-status.class.js +1 -1
  272. package/dist/components/utility/random-content/random-content.class.js +1 -1
  273. package/dist/components/utility/tour/tour.class.js +1 -1
  274. package/dist/components/viewers/archive-viewer/archive-viewer.class.js +1 -1
  275. package/dist/components/viewers/calendar-viewer/calendar-viewer.class.js +1 -1
  276. package/dist/components/viewers/contact-viewer/contact-viewer.class.js +1 -1
  277. package/dist/components/viewers/csv-viewer/csv-viewer.class.js +1 -1
  278. package/dist/components/viewers/dataset-viewer/dataset-viewer.class.js +2 -2
  279. package/dist/components/viewers/document-compare/document-compare.class.js +1 -1
  280. package/dist/components/viewers/document-preview/document-preview.class.js +1 -1
  281. package/dist/components/viewers/document-viewer/document-viewer.class.js +1 -1
  282. package/dist/components/viewers/docx-viewer/docx-viewer.class.js +1 -1
  283. package/dist/components/viewers/ebook-viewer/ebook-viewer.class.js +1 -1
  284. package/dist/components/viewers/email-viewer/email-viewer.class.js +1 -1
  285. package/dist/components/viewers/geojson-view/geojson-view.class.js +1 -1
  286. package/dist/components/viewers/geojson-view/geojson-viewer.class.js +1 -1
  287. package/dist/components/viewers/highlight-layer/highlight-layer.class.js +1 -1
  288. package/dist/components/viewers/html-viewer/html-viewer.class.js +1 -1
  289. package/dist/components/viewers/include/include.class.js +1 -1
  290. package/dist/components/viewers/notebook-viewer/notebook-viewer.class.js +1 -1
  291. package/dist/components/viewers/page-rail/page-rail.class.d.ts +1 -1
  292. package/dist/components/viewers/page-rail/page-rail.class.js +3 -3
  293. package/dist/components/viewers/pdf-viewer/pdf-viewer.class.d.ts +2 -2
  294. package/dist/components/viewers/pdf-viewer/pdf-viewer.class.js +2 -2
  295. package/dist/components/viewers/pptx-viewer/pptx-viewer.class.js +1 -1
  296. package/dist/components/viewers/spreadsheet-viewer/spreadsheet-viewer.class.js +1 -1
  297. package/dist/components/viewers/svg-viewer/svg-viewer.class.js +1 -1
  298. package/dist/components/viewers/xml-viewer/xml-viewer.class.js +1 -1
  299. package/dist/events.d.ts +6 -1
  300. package/dist/framework-types.d.ts +1 -1
  301. package/dist/internal/accessibility-visibility.js +1 -1
  302. package/dist/internal/collection-snapshot.js +1 -1
  303. package/dist/internal/default-strings/agent-tools.generated.js +1 -0
  304. package/dist/internal/default-strings/charts.generated.js +1 -0
  305. package/dist/internal/default-strings/conversation.generated.js +1 -0
  306. package/dist/internal/default-strings/data.generated.js +1 -0
  307. package/dist/internal/default-strings/forms.generated.js +1 -0
  308. package/dist/internal/default-strings/layout.generated.js +1 -0
  309. package/dist/internal/default-strings/media.generated.js +1 -0
  310. package/dist/internal/default-strings/overlays.generated.js +1 -0
  311. package/dist/internal/default-strings/retrieval.generated.js +1 -0
  312. package/dist/internal/default-strings/shared.generated.js +1 -0
  313. package/dist/internal/default-strings/utility.generated.js +1 -0
  314. package/dist/internal/default-strings/viewers.generated.js +5 -0
  315. package/dist/internal/dev-mode-attribute-warning.development.js +1 -1
  316. package/dist/internal/dev-mode-attribute-warning.production.js +1 -1
  317. package/dist/internal/document-tokens.d.ts +11 -0
  318. package/dist/internal/document-tokens.generated.js +15 -0
  319. package/dist/internal/document-tokens.js +3 -0
  320. package/dist/internal/form-associated.d.ts +1 -1
  321. package/dist/internal/form-associated.js +1 -1
  322. package/dist/internal/glass-surface.styles.js +1 -1
  323. package/dist/internal/host-tokens.styles.js +1 -0
  324. package/dist/internal/image-zoom.js +1 -0
  325. package/dist/internal/intl-cache.js +1 -1
  326. package/dist/internal/localization-types.d.ts +1 -1
  327. package/dist/internal/localization.js +2 -2
  328. package/dist/internal/lyra-element.d.ts +4 -2
  329. package/dist/internal/lyra-element.js +2 -2
  330. package/dist/internal/nonmodal-overlay-manager.js +1 -1
  331. package/dist/internal/opaque-content-border.styles.js +1 -1
  332. package/dist/internal/open-overlay-ancestors.js +1 -0
  333. package/dist/internal/open-overlay-raise.styles.js +1 -0
  334. package/dist/internal/optional-peer-failure.js +1 -0
  335. package/dist/internal/package-metadata.js +1 -1
  336. package/dist/internal/prefix.js +1 -1
  337. package/dist/internal/specialist-host-tokens.styles.js +1 -0
  338. package/dist/internal/specialist-tokens.generated.js +2 -0
  339. package/dist/internal/step-value.js +1 -1
  340. package/dist/internal/theme-observation.js +1 -1
  341. package/dist/internal/theme-scopes.d.ts +11 -0
  342. package/dist/internal/theme-scopes.js +1 -0
  343. package/dist/looks/shadcn.css +1 -1
  344. package/dist/lyra.d.ts +1 -1
  345. package/dist/lyra.js +1 -1
  346. package/dist/styles/design-tokens.css +1 -1
  347. package/dist/styles/tokens-root.css +1 -1
  348. package/dist/surfaces/glass.css +1 -1
  349. package/dist/testing/happy-dom-shims.d.ts +22 -1
  350. package/dist/testing/happy-dom-shims.js +1 -1
  351. package/dist/testing/index.d.ts +1 -1
  352. package/dist/testing/index.js +1 -1
  353. package/dist/testing/interaction-drivers.d.ts +66 -7
  354. package/dist/testing/interaction-drivers.js +1 -1
  355. package/dist/testing/jsdom-shims.d.ts +70 -0
  356. package/dist/testing/jsdom-shims.js +1 -0
  357. package/dist/theme/look-inputs.d.ts +1 -1
  358. package/dist/theme/look-inputs.js +37 -41
  359. package/dist/theme/theme.d.ts +13 -0
  360. package/dist/theme/theme.js +1 -1
  361. package/dist/theme.css +1 -1
  362. package/dist/utilities/index.d.ts +1 -1
  363. package/dist/utilities/index.js +1 -1
  364. package/dist/utilities/scoped-registry.d.ts +3 -0
  365. package/dist/utilities/scoped-registry.js +1 -1
  366. package/dist/utilities/theme-scopes.d.ts +1 -0
  367. package/dist/utilities/theme-scopes.js +1 -0
  368. package/dist/utilities/tokens.d.ts +1 -0
  369. package/dist/utilities/tokens.js +1 -0
  370. package/llms/components/lr-app-rail.md +51 -4
  371. package/llms/components/lr-box-plot.md +5 -0
  372. package/llms/components/lr-chart.md +6 -0
  373. package/llms/components/lr-emoji-picker.md +13 -8
  374. package/llms/components/lr-heatmap.md +10 -2
  375. package/llms/components/lr-icon-button.md +13 -1
  376. package/llms/components/lr-image-viewer.md +8 -0
  377. package/llms/components/lr-pagination.md +4 -2
  378. package/llms/components/lr-segmented.md +7 -3
  379. package/llms/components/lr-table.md +14 -12
  380. package/llms/components/lr-thread-list.md +4 -3
  381. package/llms/migration.md +9 -0
  382. package/llms/peers.md +1 -1
  383. package/llms/shared/events-and-types.md +41 -0
  384. package/llms/shared/frameworks-and-ssr.md +16 -0
  385. package/llms/shared/imports-and-registration.md +4 -3
  386. package/llms/shared/native-styles-and-utilities.md +38 -3
  387. package/llms/shared/styles-and-tokens.md +242 -102
  388. package/llms/shared/testing-and-utilities.md +104 -7
  389. package/llms/shared.md +445 -115
  390. package/llms/tokens.md +31 -49
  391. package/locales.json +138 -138
  392. package/package.json +16 -8
  393. package/registrations.json +1 -1
  394. package/dist/internal/default-strings.generated.js +0 -5
  395. package/dist/internal/specialist-tokens.styles.js +0 -1
  396. package/dist/internal/tokens/palette.styles.js +0 -1
  397. package/dist/internal/tokens.styles.js +0 -1
@@ -61,17 +61,18 @@ Three layers, and **which one you set decides how far the override reaches**:
61
61
  3. **`--lr-<component>-*`** — per-component properties, for one element at a time. Listed in each
62
62
  component's own section.
63
63
 
64
- **Layer 2 (`--lr-*`) is declared only on each `lr-*` element's own shadow `:host`.** It never
65
- reaches plain application CSS, and it never reaches your own custom elements, since neither is a
66
- descendant of an `lr-*` shadow root — `body { color: var(--lr-color-text) }` in application CSS
67
- resolves to nothing, silently, not an error. Retheme through layer 1 (`--lr-theme-*`), which
68
- `theme.css` supplies at document scope and which inherits normally into every nested shadow root.
69
- To _read_ (not retheme) the resolved values from your own components, import the opt-in
70
- [`tokens-root.css`](#reading-the-resolved-tokens-from-your-own-components--tokens-rootcss), which
71
- declares a curated subset of layer 2 at `:root`.
64
+ **Layer 2 (`--lr-*`) is declared once per document, not on each component** (since 28.0.0). The
65
+ _document token layer_ declares every shared output on `:root` and re-derives it only at
66
+ [theme scopes](#theme-scopes). `theme.css` carries it, so a page that imports `theme.css` has it from
67
+ first paint; on a page without `theme.css`, registering the first `lr-*` element adopts the same text
68
+ as a constructed stylesheet. Components inherit the result, and so do your own elements —
69
+ `body { color: var(--lr-color-text) }` resolves everywhere the layer applies.
70
+ [`tokens-root.css`](#reading-the-resolved-tokens-from-your-own-components--tokens-rootcss) is the
71
+ layer alone, for pages that do not use `theme.css`. Retheme through layer 1 (`--lr-theme-*`) **on a theme scope**: `:root`, a
72
+ mode scope, a style-axis boundary, or any element marked `data-lr-theme-scope`.
72
73
  See [Where an override actually reaches](#where-an-override-actually-reaches) below for the full
73
- inheritance rules, including the one documented exception (per-component `--lr-<component>-*`
74
- hooks, layer 3, which do inherit through wrappers).
74
+ inheritance rules, including per-component `--lr-<component>-*` hooks (layer 3), which inherit
75
+ through wrappers.
75
76
 
76
77
  ### Lyra signature starter
77
78
 
@@ -85,7 +86,6 @@ mode; `accent: null` explicitly clears the accent, while `resetLyraStyle()` rest
85
86
  @layer lr-base, lr-theme, lr-theme-preset, lr-utilities, lr-overrides;
86
87
  @layer lr-theme-preset.look, lr-theme-preset.density, lr-theme-preset.surface, lr-theme-preset.accent, lr-theme-preset.mode;
87
88
  @import "@aceshooting/lyra-ui/theme.css";
88
- @import "@aceshooting/lyra-ui/tokens-root.css";
89
89
  ```
90
90
 
91
91
  Keep both layer-order statements before these imports. Bundlers can hoist statements from imported
@@ -265,20 +265,35 @@ design launcher. Keep these layout rules shared across application headers and a
265
265
 
266
266
  ### Reading the resolved tokens from your own components — `tokens-root.css`
267
267
 
268
- The paragraph above is a real problem for any application that has custom elements of its own: they
269
- are not descendants of an `lr-*` shadow root either, so `var(--lr-color-border)` inside **your**
270
- component resolves to nothing, and `var(--lr-space-m, 0.5rem)` quietly runs on its literal fallback
271
- forever. Both failures are invisible without reading computed styles in a browser.
272
-
273
- Import one optional stylesheet and the curated part of layer 2 exists at document scope:
268
+ Since 28.0.0 the resolved layer lives in the document, so your own elements read it like any
269
+ component does: `var(--lr-color-border)` inside **your** component resolves wherever the layer
270
+ applies. `theme.css` carries the layer, so importing `theme.css` is enough, including for
271
+ server-rendered pages and for application elements that paint before any Lyra element exists.
272
+ `tokens-root.css` is the same layer alone, as a static stylesheet, for pages that do not use
273
+ `theme.css`:
274
+
275
+ - **Server-rendered pages.** Declarative shadow roots no longer carry the layer, so link
276
+ `theme.css` (or `tokens-root.css`) for a correct first paint before hydration (see
277
+ [Theme scopes](#theme-scopes) for application shadow roots).
278
+ - **Application elements that paint before the first Lyra element is registered**, for example
279
+ ahead of a lazily loaded route; otherwise they change value when the layer is adopted.
280
+ - **Large pages that load Lyra late.** Without a static copy, the layer is adopted when the first
281
+ Lyra element is registered, which usually happens while the document is still small. A route that
282
+ imports Lyra only after the page already holds a large DOM pays a one-off, whole-document style
283
+ invalidation then. A document whose root already resolves the layer (it links `theme.css` or
284
+ `tokens-root.css`) keeps the static copy and adopts no constructed one.
285
+
286
+ Link one of the two, not both: the second copy changes no value, but every scope matches the layer
287
+ twice.
274
288
 
275
289
  ```css
276
- @import "@aceshooting/lyra-ui/theme.css"; /* the --lr-theme-* input layer */
277
- @import "@aceshooting/lyra-ui/tokens-root.css"; /* the resolved --lr-* layer, at :root */
290
+ @import "@aceshooting/lyra-ui/theme.css"; /* the --lr-theme-* inputs, Lyra's layer order, and the resolved --lr-* layer */
291
+ /* or, without theme.css: */
292
+ @import "@aceshooting/lyra-ui/tokens-root.css"; /* the resolved --lr-* layer alone */
278
293
  ```
279
294
 
280
295
  ```css
281
- /* Now valid in your own component's stylesheet, in plain application CSS, anywhere. */
296
+ /* Valid in your own component's stylesheet, in plain application CSS, anywhere. */
282
297
  .app-panel {
283
298
  padding: var(--lr-space-m);
284
299
  border: var(--lr-border-width-thin) solid var(--lr-color-border);
@@ -293,10 +308,9 @@ Import one optional stylesheet and the curated part of layer 2 exists at documen
293
308
  }
294
309
  ```
295
310
 
296
- **It is opt-in, and it is a curated subset — not all of layer 2.** `--lr-*` is internal precisely so
297
- it can change without a major version; publishing all of it at `:root` would freeze several hundred
298
- internal decisions as permanent API. What ships is what an application's own component needs to sit
299
- inside a Lyra UI without looking foreign:
311
+ **Every output is visible on `:root`; only a subset is public API.** `--lr-*` is internal precisely
312
+ so it can change without a major version. The stable subset is what an application's own component
313
+ needs to sit inside a Lyra UI without looking foreign, and the file's header lists it:
300
314
 
301
315
  | Family | Names |
302
316
  | --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
@@ -309,53 +323,122 @@ inside a Lyra UI without looking foreign:
309
323
  | Typography | `--lr-font`, `--lr-font-mono`, the ten `--lr-font-size-*` steps, the four `--lr-font-weight-*` steps |
310
324
  | State and motion | `--lr-focus-ring`, `--lr-focus-ring-color`, `--lr-focus-ring-width`, `--lr-focus-ring-offset`, `--lr-opacity-disabled`, `--lr-opacity-muted`, `--lr-duration-fast`, `--lr-duration-base`, `--lr-easing-standard`, `--lr-easing-emphasized`, `--lr-transition-fast`, `--lr-transition-base`, `--lr-transition-interactive` |
311
325
 
312
- The grid ships whole because its contrast guarantee is **per tier** — a `fill-quiet` background is
313
- only guaranteed legible under the matching `on-quiet` foreground — so shipping the flat aliases
314
- alone would hand you a pairing with nothing behind it.
326
+ The grid is stable as a whole because its contrast guarantee is **per tier** — a `fill-quiet`
327
+ background is only guaranteed legible under the matching `on-quiet` foreground.
315
328
 
316
- **Deliberately not published**, and each for a reason that makes reading it a bug rather than a
317
- convenience: `--lr-ramp-*` (tooling-only numeric inputs, absent from component host styles),
318
- `--lr-size-*` (value-named geometry constants, frozen internals), the chart, graph and terminal
319
- palettes (generated ramps that move with the palette tooling), `--lr-layer-*` (stacking order is
320
- your decision), `--lr-color-mix-*` and `--lr-hover-brightness` (inputs to the library's own
321
- interaction recipe), `--lr-line-height-*`, the per-control internals (`--lr-icon-button-size`,
329
+ **Visible but internal** (read them at your own risk; they may change in any release): `--lr-size-*`,
330
+ `--lr-layer-*`, `--lr-color-mix-*`, `--lr-hover-brightness`, `--lr-line-height-*`,
322
331
  `--lr-otp-input-segment-size`, `--lr-scroll-fade-size`, `--lr-popover-viewport-clamp`,
323
- `--lr-safe-area-*`, `--lr-mask-opaque`, `--lr-color-no-data`), and the nine variant-following slots
324
- (`--lr-color-fill-loud` and friends), which mean "the variant _this_ element is set to" and are
325
- meaningless on `:root`. If you need one of these, ask for it to be added rather than reading it out
326
- of a component's shadow root.
332
+ `--lr-mask-opaque`, `--lr-color-no-data`, and the private `--_lr-*` names. **Not in the layer at all:**
333
+ `--lr-ramp-*` (tooling-only), the chart, graph and terminal palettes (per host, on the components that
334
+ draw with them), the form-control ladder, and the per-element names `--lr-icon-button-size`,
335
+ `--lr-radius-button` and `--lr-safe-area-*`. If you need one of these, ask for it to be added to the
336
+ stable subset rather than reading it from the document.
327
337
 
328
338
  **Stability promise.** Every name in the table is public API from the release that introduced it: it
329
339
  will not be renamed or removed outside a major version, and its meaning will not change. Its _value_
330
340
  may change in a minor exactly as it may inside a component — a palette retune moves your elements
331
- and the kit's together, which is the point. Names absent from the file stay internal and may change
332
- in any release.
333
-
334
- **Modes follow the inherited style context.** Standalone `tokens-root.css` follows the OS at the
335
- root and accepts `.lr-light` / `.lr-dark`, `data-lr-theme` and `data-lr-mode` scopes. When `theme.css`
336
- is also installed, its requested mode owns the switches instead. Shared outputs re-resolve on style
337
- and contrast/motion preference boundaries; forced-colors and reduced-motion overrides use those
338
- same boundaries, including under a dark OS. Each output reads the local `--lr-theme-*` input before
339
- its built-in fallback. A preference-only boundary never overwrites inherited theme inputs.
340
-
341
- **One caveat, and it is the same shape as layer 2's rule everywhere else.** A `--lr-theme-*` input
342
- set on a mid-tree element retunes every `lr-*` component below it, because each component re-derives
343
- the resolved layer on its own `:host`. The document-scope copy cannot: it is substituted where it is
344
- declared, and what inherits past that point is the finished value. So if an application element
345
- carries a subtree override and expects its **own** descendants to follow, give that element a mode
346
- scope too — `data-lr-mode`, `data-lr-theme-scope`, or the compatibility `lr-light`/`lr-dark`
347
- classes — so the whole subset resolves again there:
341
+ and the kit's together, which is the point.
342
+
343
+ **Modes follow the nearest mode scope.** The layer follows the OS preference at the root and accepts
344
+ `.lr-light` / `.lr-dark`, `data-lr-theme` and `data-lr-mode` scopes, in every engine, with or without
345
+ `theme.css`. When `theme.css` is installed its requested mode owns the switches. A mode-neutral
346
+ scope keeps its ancestor's mode. Forced colours, increased contrast and reduced motion apply at every
347
+ scope and again on every component host.
348
+
349
+ Public outputs sit in the `lr-theme` cascade layer (the fallback mode switches in `lr-base`), so any
350
+ unlayered application rule beats them regardless of load order, and the file declares custom
351
+ properties only — notably not `color-scheme` — so importing it paints nothing by itself.
352
+
353
+ ### Theme scopes
354
+
355
+ A **theme scope** is an element that re-derives the whole token layer from the `--lr-theme-*` inputs
356
+ and the mode it sees. The list is closed: `:root`; the mode scopes `.lr-light`, `.lr-dark` and
357
+ `[data-lr-theme]` (any value); the style-axis boundaries `[data-lr-mode]`, `[data-lr-look]`,
358
+ `[data-lr-accent]`, `[data-lr-density]`, `[data-lr-contrast]`, `[data-lr-motion]`; a look's scoped
359
+ `.light` / `.dark` aliases; the design-token fixture scopes `.lr-token-light`, `.lr-token-dark`,
360
+ `[data-lr-design-token-mode]`; and the mode-neutral marker **`data-lr-theme-scope`**.
348
361
 
349
362
  ```html
350
- <!-- Both the lr-* components and the app's own elements below follow the override. -->
351
- <section class="lr-light" style="--lr-theme-color-brand-fill-loud: #7c3aed">…</section>
363
+ <!-- Re-theme one region: mark it, then set inputs on it. -->
364
+ <section data-lr-theme-scope style="--lr-theme-color-brand-fill-loud: #7c3aed">
365
+ <lr-button variant="brand">Save</lr-button>
366
+ </section>
367
+
368
+ <!-- Mode scopes are already scopes; a marked region inside one keeps its mode. -->
369
+ <aside class="lr-dark"><div data-lr-theme-scope style="--lr-theme-space-m: 1rem">…</div></aside>
370
+
371
+ <!-- A single re-themed component. -->
372
+ <lr-button data-lr-theme-scope style="--lr-theme-color-brand-fill-loud: #7c3aed">Save</lr-button>
352
373
  ```
353
374
 
354
- Public outputs sit in the `lr-theme` cascade layer, like `theme.css`, so any unlayered application rule
355
- beats it regardless of load order, and the file declares custom properties only — notably not
356
- `color-scheme` — so importing it paints nothing by itself. `--lr-focus-ring` and its three parts are
357
- also declared at document scope by `theme.css`; both spell the same chain, so importing both is a
358
- no-op either way round.
375
+ - **The marker follows HTML presence semantics:** `data-lr-theme-scope="false"` still marks. React
376
+ renders `data-*={false}` as `"false"`, so write `data-lr-theme-scope=""` (or omit the attribute);
377
+ the development build warns on the literal `"false"`.
378
+ - **Nesting** works like inheritance: a scope re-derives from what it inherits plus what it sets, and
379
+ its descendants inherit the result until the next scope. The marker only re-derives the `--lr-*`
380
+ outputs, so an input set on `:root` (inline, in your stylesheet, or by `setLyraStyle()`) or on an
381
+ outer scope reaches a marked region exactly as it reaches an unmarked one, and adding a marker
382
+ where nothing needs it changes nothing. With `theme.css`, mode scopes and the style-axis
383
+ boundaries also re-resolve the inputs from the selected look, accent and mode, so an input set
384
+ above one of them stops there (set it on that boundary, or below it). A scope costs a little less
385
+ than one component did before 28.0.0, so put inputs on a common ancestor rather than marking every
386
+ row of a list.
387
+ - **`applyLyraStyleScope()`** writes the marker whenever it writes inline inputs.
388
+ - **Brand regions in the default look.** The marker re-derives outputs but is not a style boundary,
389
+ so the roles that follow brand in the default Shadcn look (the neutral loud tier) keep the brand
390
+ of the nearest boundary inside the first example above. For a brand region call
391
+ `applyLyraStyleScope(el, { accent: '#7c3aed' })`, which writes the `data-lr-accent="custom"`
392
+ boundary, or set the `--lr-theme-color-neutral-*-loud` inputs on the region too.
393
+ - **Which inputs need a scope.** Only the `--lr-theme-*` inputs the layer consumes (listed in
394
+ `llms/tokens.md`). Inputs read on the host itself keep working on any element: the chart,
395
+ graph and terminal palettes, the form-control heights and radius, the icon-button size, the
396
+ button radius, scrollbar and progress-ring inputs.
397
+
398
+ **Application shadow roots.** Custom properties inherit across shadow boundaries; selectors do not.
399
+ A scope _inside_ your own component's shadow root therefore needs the layer adopted in that root.
400
+ Lyra does that on demand: when a Lyra element connects inside an application shadow root and it is,
401
+ or sits below, a scope in that root, an unlayered copy of the layer with zero-specificity
402
+ (`:where()`) selectors is appended to the root's `adoptedStyleSheets`, so your component's own rules
403
+ there still win (unless you put them in a cascade layer).
404
+ "Below" follows the flat tree, so a Lyra element slotted into your component (directly, or through
405
+ forwarded slots) counts as below the scopes around its slot, also when your component renders its
406
+ slots right after connecting, as Lit does. A Lyra element inside a slotted non-Lyra wrapper does not
407
+ trigger it. Library components' own shadow roots never receive it. Call
408
+ `adoptLyraTokens(root)` (from `@aceshooting/lyra-ui/utilities/tokens.js`, or the package root) for a
409
+ root whose scopes appear after its Lyra elements connected, a root that has scopes but no Lyra
410
+ element yet, or an iframe that holds application elements only. Server-rendered application roots
411
+ that contain scopes include `<link rel="stylesheet" href="…/tokens-root.css">`.
412
+
413
+ ```js
414
+ // An application component whose shadow root holds scopes before any Lyra element connects in it.
415
+ import { adoptLyraTokens } from "@aceshooting/lyra-ui/utilities/tokens.js";
416
+ adoptLyraTokens(this.shadowRoot); // adoptLyraTokens(root: Document | ShadowRoot): void, idempotent
417
+ ```
418
+
419
+ **Append, never replace.** Lyra appends its sheet to `document.adoptedStyleSheets` and to an
420
+ application root's. An application that later assigns a new array wholesale removes it until the next
421
+ Lyra element connects there; append to the existing array instead.
422
+ In Chromium, Lyra also appends a one-rule sheet to `document.adoptedStyleSheets`: a private root
423
+ property (`--_lr-root-inputs`) that follows every theme input. It lets Chromium skip a full
424
+ custom-property comparison per element when the root is re-themed (an accent or spacing input
425
+ written on `<html>` with dark islands or other scopes on the page costs about half as much). Firefox
426
+ and Safari do not get it; they already stop at unchanged scopes, which the property would defeat.
427
+ When `theme.css` or `tokens-root.css` provides the layer, that sheet goes in only at the first
428
+ attribute change on `<html>` (an inline input, a mode or look attribute, a class), so a route that registers Lyra late on a large page does not restyle every element for it.
429
+
430
+ **Layer order.** On a page with no Lyra stylesheet, the adopted sheet's layer statement is the last
431
+ the browser sees, so Lyra's layers sort after yours. Declare Lyra's order first (import `theme.css`,
432
+ or repeat `@layer lr-base, lr-theme, lr-theme-preset, lr-utilities, lr-overrides;` before your own
433
+ layers), or leave application overrides of `--lr-*` outputs unlayered.
434
+
435
+ **Finding unscoped inputs.** `findUnscopedThemeInputs(root?)` (from
436
+ `@aceshooting/lyra-ui/utilities/theme-scopes.js`; `findUnscopedThemeInputs(root?: Document |
437
+ DocumentFragment | Element): Element[]`) returns, without logging, every element under `root`
438
+ (through open shadow roots) whose inline style sets a layer-consumed input and that is not a scope. `lyra-ui-migrate --rule=theme-scopes`
439
+ adds the marker in HTML, Lit and JSX templates and reports dynamic inputs and stylesheet rules;
440
+ `lyra-ui-migrate --origin=lyra-v26` runs the same rule together with the other Lyra 27 moves (relocated
441
+ locale and editor-data specifiers, `ToolStatus`) and reports removed localization keys.
359
442
 
360
443
  ### The colour ramp and the semantic grid
361
444
 
@@ -396,8 +479,9 @@ These guarantees apply in both modes.
396
479
  rethemed without forking anything beneath it:
397
480
 
398
481
  ```css
399
- /* Both the grid slot and the flat alias below now resolve to this. */
400
- .invoice-panel {
482
+ /* Both the grid slot and the flat alias below now resolve to this, for every component inside
483
+ the panel (mark the panel <div class="invoice-panel" data-lr-theme-scope>, or use :root). */
484
+ .invoice-panel[data-lr-theme-scope] {
401
485
  --lr-theme-color-brand-fill-loud: #7c3aed;
402
486
  }
403
487
  ```
@@ -572,6 +656,13 @@ first statement the browser sees is appended at the end, so an older four-name s
572
656
  `lr-theme-preset`) would rank an imported look preset above `lr-overrides` and your own layer. Every Lyra stylesheet that declares an order repeats the same five names for exactly this
573
657
  reason.
574
658
 
659
+ The same rule decides application **fallback fills**. A page that keeps plain `background` rules
660
+ for dialogs or panels (so it also renders without the component bundle) and uses an unlayered rule
661
+ on an `.lr-surface-chrome` element overrides the Glass fill; declare a low-priority layer before
662
+ Lyra's names (`@layer app-base, lr-base, lr-theme, lr-theme-preset, lr-utilities, lr-overrides;`)
663
+ for those fallbacks, or set `--lr-surface-background`. See
664
+ [Application fallback fills and cascade layers](native-styles-and-utilities.md#application-fallback-fills-and-cascade-layers).
665
+
575
666
  <a id="the-shadcn-look--themesshadcncss"></a>
576
667
 
577
668
  ### The shadcn look — looks/shadcn.css
@@ -618,25 +709,33 @@ compatibility aliases above.
618
709
 
619
710
  ### Where an override actually reaches
620
711
 
621
- **Shared computed `--lr-*` design-token outputs are declared on every `lr-*` element's `:host`.**
622
- That includes palette, spacing, radius, typography, and motion outputs such as
623
- `--lr-color-brand`, `--lr-space-m`, and `--lr-radius`. A value for one of those shared outputs set
624
- on an ancestor is re-declared — and lost — at the first `lr-*` element between that ancestor and
625
- the component you meant to style. It never reaches anything nested inside another component.
626
-
627
- **`--lr-theme-*` inputs are never redeclared inside a component's shadow styles.** `theme.css`
628
- supplies them on its root and light/dark mode selectors, so an application override inherits normally
629
- through every nested shadow root. **Setting a `--lr-theme-*` input on a wrapper element is the
630
- supported way to retheme one subtree.** Setting a `--lr-*` token there only works for that wrapper's
631
- direct children.
712
+ **Shared computed `--lr-*` outputs are resolved at theme scopes and inherited everywhere else.** That
713
+ includes palette, spacing, radius, typography and motion outputs such as `--lr-color-brand`,
714
+ `--lr-space-m` and `--lr-radius`. No component re-declares them on its host (since 28.0.0), so:
715
+
716
+ - **A `--lr-theme-*` input** retunes everything below it **when it is set on a theme scope**. Set on a
717
+ plain wrapper, a component's inline style, or an application component's own `:host` rule, it no
718
+ longer re-derives the components below; add `data-lr-theme-scope` to that element.
719
+ - **A `--lr-*` output** set on an ancestor now reaches every component below it, until the next theme
720
+ scope (which re-derives every output). The outputs _derived_ from it (`--lr-focus-ring` from
721
+ `--lr-focus-ring-color`, `--lr-color-brand` from `--lr-color-brand-fill-loud`,
722
+ `--lr-transition-interactive` from `--lr-transition-fast`) keep the scope's values unless the
723
+ element is itself a scope.
724
+ - **Border outputs stop at an opaque content interior.** The bodies of `lr-card`, `lr-details` and
725
+ `lr-accordion-item` restore the nearest scope's unqualified `--lr-color-border` and
726
+ `--lr-color-border-strong` for their content (inside a glass surface the surface would otherwise
727
+ hand its translucency-qualified borders to opaque content). A `--lr-color-border` set on such a
728
+ component, or above it, still applies to the chrome that reads it, but not to the content; set
729
+ `--lr-theme-color-surface-border` on a theme scope, or a component hook such as
730
+ `--lr-input-border-color`, to reach the content.
632
731
 
633
732
  ```css
634
- /* Reaches everything in the subtree, however deeply nested. */
635
- .invoice-panel {
733
+ /* Reaches everything in the subtree, however deeply nested: the element is a theme scope. */
734
+ .invoice-panel[data-lr-theme-scope] {
636
735
  --lr-theme-color-brand-fill-loud: #7c3aed;
637
736
  }
638
737
 
639
- /* A shared computed output reaches direct lr-* children only — shadowed at the first nested host. */
738
+ /* An output reaches the subtree down to the next scope; its dependants do not follow it. */
640
739
  .invoice-panel {
641
740
  --lr-color-brand: #7c3aed;
642
741
  }
@@ -659,8 +758,9 @@ reliable way to theme a group of matching components:
659
758
  State and size selectors change only the private fallback. An inherited or direct public value
660
759
  continues to win in every state and size tier.
661
760
 
662
- **Diagnostic:** if a shared design-token output has no effect on a nested component, check which
663
- layer you set before assuming the component is at fault. If a documented component-specific hook
761
+ **Diagnostic:** if a `--lr-theme-*` input has no effect on a nested component, check that the element
762
+ carrying it is a theme scope (the development build warns once per page about an inline input on an
763
+ element that is not, and `findUnscopedThemeInputs()` lists them). If a documented component-specific hook
664
764
  fails when inherited from a wrapper, that is a component bug; setting the same hook directly on
665
765
  every host should not be necessary.
666
766
 
@@ -770,28 +870,16 @@ consult it rather than guessing a token name.
770
870
  }
771
871
  ```
772
872
 
773
- With `theme.css` imported, switch modes by putting `class="lr-light"`/`class="lr-dark"` (or
774
- `data-lr-theme="light"`/`"dark"`) on any ancestor; it also sets `color-scheme`. Without it, the token
775
- layer still ships a `prefers-color-scheme: dark` fallback that re-points the hardcoded defaults at a
776
- dark palette. Two things switch that fallback off:
777
-
778
- - **A real `--lr-theme-*` value**, which the fallback only substitutes for.
779
- - **`data-lr-theme="light"` on the component itself**, which pins light mode regardless of the OS.
780
- Both layers honour it now: the palette layer always did, and the token layer — the hardcoded
781
- surface/text/border defaults — does too, so `<lr-card data-lr-theme="light">` on a dark machine is
782
- light throughout rather than light chrome over a dark colour grid. The mirror-image
783
- `data-lr-theme="dark"` pins dark on a light machine the same way, and a `.lr-dark` /
784
- `data-lr-theme="dark"` _ancestor_ is followed as well (through `:host-context()` where the engine
785
- has it, and through `theme.css`'s inheriting custom properties everywhere else).
786
-
787
- Note the asymmetry: the _light_ pin is read on the component itself (`:host([data-lr-theme='light'])`),
788
- while a _dark_ ancestor is followed through `:host-context()`. Putting `data-lr-theme="light"` on
789
- `<html>` — what `setLyraStyle({ mode: 'light' })` does — pins the page through
790
- `theme.css`'s real `--lr-theme-*` values, which inherit into every shadow root. Without `theme.css`
791
- there are no such values to inherit, so put the attribute on the components you actually need
792
- pinned.
793
-
794
- The token layer also sets `:host([hidden]) { display: none !important; }` and an inherited
873
+ Switch modes by putting `class="lr-light"`/`class="lr-dark"` (or `data-lr-theme="light"`/`"dark"`,
874
+ or `data-lr-mode`) on any element, including a component itself; with `theme.css` imported it also
875
+ sets `color-scheme`. **Every engine follows the nearest mode scope, with or without `theme.css`:** the
876
+ document layer carries mode to every scope through two inherited private switches, so a `.lr-light`
877
+ island inside a `.lr-dark` region is light, a mode-neutral scope keeps its ancestor's mode, and the
878
+ OS preference decides the root unless the root carries an explicit mode. A real `--lr-theme-*` value
879
+ still wins over the built-in light or dark default. (Before 28.0.0 an ancestor mode reached
880
+ components without `theme.css` only in Chromium, through `:host-context()`.)
881
+
882
+ Each component host also keeps `:host([hidden]) { display: none !important; }` and an inherited
795
883
  `box-sizing: border-box` reset.
796
884
 
797
885
  ### Style runtime — @aceshooting/lyra-ui/theme.js
@@ -804,8 +892,11 @@ import {
804
892
  getLyraStyle,
805
893
  resetLyraStyle,
806
894
  setLyraStyle,
895
+ startLyraStyle,
807
896
  } from "@aceshooting/lyra-ui/theme.js";
808
897
 
898
+ startLyraStyle(); // adopt the saved style and follow the OS without writing storage
899
+
809
900
  setLyraStyle({ mode: "dark" }); // unspecified axes keep their current value
810
901
  setLyraStyle({ accent: "sapphire" }); // named palette accent
811
902
  setLyraStyle({ accent: "#7c3aed" }); // absolute CSS color
@@ -876,6 +967,27 @@ initial snapshot; it does not install a live system-mode listener. This option c
876
967
  the bootstrap. Later runtime calls such as `setLyraStyle()` follow their own style and persistence
877
968
  policy, so choose that policy explicitly if the application initializes the runtime afterward.
878
969
 
970
+ **Starting the runtime after the bootstrap — `startLyraStyle()`.** A page that inlines only the
971
+ bootstrap and loads `theme.js` later in a deferred bundle calls `startLyraStyle()` once. It adopts
972
+ the saved style (the defaults when nothing is saved) on the document root and, while the mode is
973
+ System, attaches the live `prefers-color-scheme` listener. It never writes storage: no record is
974
+ created, a v1 record is not migrated, and an operating-system flip afterwards repaints without
975
+ saving. Repeated calls do not stack listeners. The call emits no `lr-style-change`; a later
976
+ operating-system flip emits `changed: ["resolvedMode"]`. The first `setLyraStyle()` takes over the
977
+ same listener. Do not call `setLyraStyle({})` for this: it persists the current record.
978
+
979
+ ~~~ts
980
+ // deferred bundle, after <script>lyraThemeBootstrap</script> in <head>
981
+ import { startLyraStyle } from "@aceshooting/lyra-ui/theme.js";
982
+
983
+ startLyraStyle(); // adopts the saved style, follows the OS while mode is System, never writes
984
+ ~~~
985
+
986
+ `startLyraStyle()` always reads the runtime's own `localStorage['lyra-theme']` record and applies
987
+ the whole profile in it. A page whose bootstrap uses `data-lr-theme-restore="mode"` or an
988
+ application-owned storage key does not pair with it: the start would apply axes or a record the
989
+ bootstrap deliberately ignored. Such pages call `setLyraStyle()` with the policy they want.
990
+
879
991
  **Migrating the retired theme facade.** New code uses setLyraStyle() and getLyraStyle(). Map old auto mode to system, an old surface reference color to accentBackground, and an old token map to overrides; review custom CSS colors that share a gemstone name before choosing a named accent. Replace preset definitions with a LyraLook plus explicit style choices. Replace selectors for data-lr-theme-preset with the actual axis they need, such as data-lr-look="shadcn". Import theme.css in place of the removed fixed themes/shadcn.css facade and select the look with setLyraStyle({ look: "shadcn" }) or a scoped data-lr-look attribute. Listen for lr-style-change and read event.detail.style and event.detail.changed; the old theme and preset events are no longer emitted. For the complete project-by-project sequence, see [Upgrading from v23 to v24](v23-to-v24-migration.md).
880
992
 
881
993
  Historical v1 stored records remain readable by the runtime and bootstrap. The removed JavaScript functions, preset subpaths, preset event, root marker, and fixed stylesheet are not available in the current API.
@@ -1155,7 +1267,35 @@ of the backdrop; the default foreground qualification covers 60%, while a custom
1155
1267
  cannot guarantee contrast against every backdrop. Solid and accessibility preferences retain
1156
1268
  opaque fills regardless of this input.
1157
1269
  Dark Glass deepens the selected fill at opacity below 70% so light foregrounds remain readable
1158
- against bright backdrops; at 70% and above, the selected fill keeps its original color.
1270
+ against bright backdrops; at 70% and above, the selected fill keeps its original color. The
1271
+ deepening blends toward a darkened `--lr-color-surface` (10% of the surface, the rest black), not
1272
+ pure black, so a lifted dark palette (for example a neutral grey `--lr-theme-color-surface-default`
1273
+ and overlay tokens) lifts its Glass chrome with it. That share is small on purpose: the stock
1274
+ palettes are qualified for 4.5:1 text over a pure white backdrop at 60% opacity, which caps how
1275
+ light the pane can get. To paint a lifted palette's own overlay colour, set `--lr-theme-surface-opacity`
1276
+ to 0.7 or higher.
1277
+
1278
+ `--lr-theme-surface-glass-dark-share` is the public input for that share. It is a percentage,
1279
+ default `10%`, read in dark mode only, below 70% opacity. It sets how much of `--lr-color-surface`
1280
+ the deepening anchor keeps (the rest is black), so raising it lifts dark Glass chrome toward the
1281
+ surface. It inherits, so set it on `:root` for the whole app or on any container for that subtree;
1282
+ values outside 0% to 100% clamp. It is deliberately not registered with `@property` (a registered
1283
+ inherited property slows every re-theme in Chromium), so a value that is not a percentage voids the
1284
+ dark fill; the development build warns about one set on `:root`. The default paints exactly as before. For a softer grey dark mode:
1285
+
1286
+ ```css
1287
+ :root {
1288
+ --lr-theme-color-surface-default: #1f2023;
1289
+ --lr-theme-color-surface-raised: #1f2023;
1290
+ --lr-theme-color-surface-overlay: #1f2023;
1291
+ --lr-theme-surface-glass-dark-share: 60%;
1292
+ }
1293
+ ```
1294
+
1295
+ The trade-off is contrast: the 4.5:1 qualification over a white backdrop at 60% opacity holds for
1296
+ the stock palettes only at the 10% default, and a lighter pane lowers light-text contrast over bright
1297
+ backdrops. After raising the share, re-measure your own text colours, or raise
1298
+ `--lr-theme-surface-opacity` to 0.7 or higher, where the fill keeps the palette's own colour.
1159
1299
  Necessary control borders use the effective painted opacity: their glass adjustment grows as
1160
1300
  transparency increases and disappears at 100% opacity. Ordinary and strong borders share this
1161
1301
  adjustment; decorative borders and explicit component border overrides keep their own tokens.