@astryx-vue/core 0.16.5 → 0.18.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 (165) hide show
  1. package/dist/AppShell/index.d.ts +1 -1
  2. package/dist/AvatarGroup/index.d.ts +1 -1
  3. package/dist/Banner/index.d.ts +1 -1
  4. package/dist/BottomSheet/index.d.ts +1 -1
  5. package/dist/Button/index.d.ts +1 -1
  6. package/dist/ButtonGroup/index.d.ts +1 -1
  7. package/dist/Calendar/index.d.ts +1 -1
  8. package/dist/Carousel/index.d.ts +1 -1
  9. package/dist/Chat/index.d.ts +1 -1
  10. package/dist/Chat/index.js +1 -1
  11. package/dist/CheckboxInput/index.d.ts +1 -1
  12. package/dist/CheckboxList/index.d.ts +1 -1
  13. package/dist/ClickableCard/index.d.ts +1 -1
  14. package/dist/Code/index.d.ts +1 -1
  15. package/dist/Code/index.js +1 -1
  16. package/dist/Collapsible/index.d.ts +1 -1
  17. package/dist/Collapsible/index.js +1 -1
  18. package/dist/{Collapsible-Dk9BQQbT.js → Collapsible-ExzU7vC0.js} +104 -40
  19. package/dist/CommandPalette/index.d.ts +1 -1
  20. package/dist/CommandPalette/index.js +1 -1
  21. package/dist/{CommandPalette-mNR6dV0B.js → CommandPalette-CECjNvGB.js} +1 -1
  22. package/dist/ComplexSelector/index.js +1 -1
  23. package/dist/{ComplexSelector-CR9XbpTa.js → ComplexSelector-Dmaag1wm.js} +5 -1
  24. package/dist/ContextMenu/index.d.ts +1 -1
  25. package/dist/DateInput/index.d.ts +1 -1
  26. package/dist/DateInput/index.js +1 -1
  27. package/dist/DateRangeInput/index.d.ts +1 -1
  28. package/dist/DateRangeInput/index.js +1 -1
  29. package/dist/DateTimeInput/index.d.ts +1 -1
  30. package/dist/DateTimeInput/index.js +1 -1
  31. package/dist/{DateTimeInput-ChGin5zS.js → DateTimeInput-Cfkuec_h.js} +1 -1
  32. package/dist/Dialog/index.d.ts +1 -1
  33. package/dist/Divider/index.d.ts +1 -1
  34. package/dist/Drawer/index.d.ts +1 -1
  35. package/dist/Field/index.d.ts +1 -1
  36. package/dist/FileInput/index.d.ts +1 -1
  37. package/dist/HoverCard/index.d.ts +1 -1
  38. package/dist/Indicator/index.d.ts +2 -2
  39. package/dist/InfoTip/index.d.ts +1 -1
  40. package/dist/InputGroup/index.d.ts +1 -1
  41. package/dist/InternationalizationProvider/index.d.ts +1 -1
  42. package/dist/InternationalizationProvider/index.js +1 -1
  43. package/dist/{InternationalizationProvider-7rA65NO7.js → InternationalizationProvider-Dr5GE6f0.js} +1 -1
  44. package/dist/Link/index.d.ts +1 -1
  45. package/dist/List/index.d.ts +1 -1
  46. package/dist/Markdown/index.js +1 -1
  47. package/dist/{Markdown-BNVd70jg.js → Markdown-DnnWjJGX.js} +1 -1
  48. package/dist/{MediaTheme-Bkj-_DFN.js → MediaTheme-DfcdEWx-.js} +2 -36
  49. package/dist/MoreMenu/index.d.ts +1 -1
  50. package/dist/MultiSelector/index.d.ts +1 -1
  51. package/dist/MultiSelector/index.js +1 -1
  52. package/dist/{MultiSelector-CXX1Hsty.js → MultiSelector-BK6nZweN.js} +26 -14
  53. package/dist/NavItem/index.d.ts +1 -1
  54. package/dist/NumberInput/index.d.ts +1 -1
  55. package/dist/OverflowList/index.d.ts +1 -1
  56. package/dist/Pagination/index.d.ts +1 -1
  57. package/dist/Pagination/index.js +1 -1
  58. package/dist/{Pagination-BvZFvwso.js → Pagination-DFQNX_Mb.js} +1 -1
  59. package/dist/Popover/index.d.ts +1 -1
  60. package/dist/PowerSearch/index.d.ts +1 -1
  61. package/dist/PowerSearch/index.js +1 -1
  62. package/dist/{PowerSearch-BiupstfT.js → PowerSearch-BAOqpQag.js} +10 -10
  63. package/dist/ProgressBar/index.d.ts +1 -1
  64. package/dist/Radio/index.d.ts +1 -1
  65. package/dist/RadioList/index.d.ts +1 -1
  66. package/dist/ScrollableArea/index.d.ts +1 -1
  67. package/dist/SegmentedControl/index.d.ts +1 -1
  68. package/dist/SelectableCard/index.d.ts +1 -1
  69. package/dist/Selector/index.d.ts +1 -1
  70. package/dist/Selector/index.js +1 -1
  71. package/dist/{Selector-DiSLNzl8.js → Selector-Bo7qkt1P.js} +157 -62
  72. package/dist/SideNav/index.d.ts +1 -1
  73. package/dist/Stepper/index.d.ts +1 -1
  74. package/dist/Switch/index.d.ts +1 -1
  75. package/dist/Table/index.d.ts +1 -1
  76. package/dist/Table/index.js +1 -1
  77. package/dist/{Table-BD8MugZo.js → Table-iemur_3E.js} +378 -7
  78. package/dist/TextArea/index.d.ts +1 -1
  79. package/dist/TextInput/index.d.ts +1 -1
  80. package/dist/Theme/index.d.ts +3 -3
  81. package/dist/Theme/index.js +3 -2
  82. package/dist/{Theme-8bDq2nud.js → Theme-1RJVaRgz.js} +329 -40
  83. package/dist/TimeInput/index.d.ts +1 -1
  84. package/dist/Timer/index.d.ts +1 -1
  85. package/dist/Timestamp/index.d.ts +1 -1
  86. package/dist/Toast/index.js +1 -1
  87. package/dist/{Toast-CzbqvHDN.js → Toast-D4Q6wvYu.js} +1 -1
  88. package/dist/ToggleButton/index.d.ts +1 -1
  89. package/dist/Tokenizer/index.d.ts +1 -1
  90. package/dist/Tokenizer/index.js +1 -1
  91. package/dist/{Tokenizer-mu0Sak58.js → Tokenizer-CsFiYUJ_.js} +171 -103
  92. package/dist/Toolbar/index.d.ts +1 -1
  93. package/dist/Tooltip/index.d.ts +1 -1
  94. package/dist/TopNav/index.d.ts +1 -1
  95. package/dist/TreeList/index.d.ts +1 -1
  96. package/dist/TreeList/index.js +1 -1
  97. package/dist/{TreeList-CNj4KnHH.js → TreeList-ugSF9DWj.js} +117 -2
  98. package/dist/Typeahead/index.d.ts +2 -1
  99. package/dist/Typeahead/index.js +2 -2
  100. package/dist/{Typeahead-Db8Tu27Z.js → Typeahead--kEp21ut.js} +159 -71
  101. package/dist/{useKeyboardHighlight-CGCf1O57.js → assertOptions-CK_gJ0d3.js} +12 -1
  102. package/dist/composables/index.d.ts +4 -3
  103. package/dist/composables/index.js +5 -5
  104. package/dist/composables-BgfubKnk.js +5437 -0
  105. package/dist/handle-BPXdHbkr.js +458 -0
  106. package/dist/{index-sXu15K4j.d.ts → index-B-3EGjfQ.d.ts} +2 -2
  107. package/dist/{index-TXcNH86P.d.ts → index-B1eCxBCY.d.ts} +1 -1
  108. package/dist/{index-9eluGe3a.d.ts → index-BBTU-TKb.d.ts} +1 -1
  109. package/dist/{index-CE74Qsbn.d.ts → index-BKpnfdq1.d.ts} +9 -9
  110. package/dist/{index-D_xBhUV5.d.ts → index-B_PKY-Wn.d.ts} +11 -11
  111. package/dist/{index-Bfm6mF-r.d.ts → index-BfoazhEu.d.ts} +1 -1
  112. package/dist/{index-BWzEt0gT.d.ts → index-BhxqUt3y.d.ts} +1 -1
  113. package/dist/{index-CJdOt5Cc.d.ts → index-BtqvPjAf.d.ts} +3 -3
  114. package/dist/{index-ChqMaV6N.d.ts → index-Bzi3A980.d.ts} +1 -1
  115. package/dist/{index-DBwEz4M9.d.ts → index-BzmcDJau.d.ts} +11 -11
  116. package/dist/{index-CQ1bsxLC.d.ts → index-C1qJlC65.d.ts} +1 -1
  117. package/dist/{index-CMLnSg3T.d.ts → index-C4S65SAW.d.ts} +8 -1
  118. package/dist/{index-D05JGsT3.d.ts → index-C8wfe0Mr.d.ts} +1 -1
  119. package/dist/{index-gmY3A_Iw.d.ts → index-C93nwgTW.d.ts} +1 -1
  120. package/dist/{index-BvWBeoa8.d.ts → index-CEjvYAUZ.d.ts} +1 -1
  121. package/dist/{index-B0R5CLPF.d.ts → index-CsYDrQ9R.d.ts} +1 -1
  122. package/dist/{index-C2cH8OLC.d.ts → index-D31bgBoy.d.ts} +1 -1
  123. package/dist/{index-BxWCX2pJ.d.ts → index-DFLPv9io.d.ts} +3 -3
  124. package/dist/index-DGXCnzOL.d.ts +69 -0
  125. package/dist/{index-BPf_jmME.d.ts → index-DMcf0QeR.d.ts} +3 -3
  126. package/dist/{index-SWw-WMTO.d.ts → index-DPhQZXYw.d.ts} +3 -3
  127. package/dist/{index-B-Jla56c.d.ts → index-DmAEpn5E.d.ts} +1 -1
  128. package/dist/{index-B0yaHi__.d.ts → index-DtZUOyCy.d.ts} +12 -5
  129. package/dist/{index-BQ3cm7mP.d.ts → index-FeZXsFO-.d.ts} +1 -1
  130. package/dist/{index-Byan7Dad.d.ts → index-GmoeIuhl.d.ts} +1 -1
  131. package/dist/{index-ygmRS6Np.d.ts → index-KcCNhdAw.d.ts} +1 -1
  132. package/dist/{index-BPHqOCfp.d.ts → index-PffxihMx.d.ts} +4 -4
  133. package/dist/{index-unAZVFGz.d.ts → index-Qdbssopn.d.ts} +2 -2
  134. package/dist/{index-LHvLg1Pv.d.ts → index-Y4H4X6Vy.d.ts} +88 -82
  135. package/dist/{index-Xc3q9f84.d.ts → index-YKCx03zD.d.ts} +2 -2
  136. package/dist/{index-BXDqyk2_.d.ts → index-gu5EvbE0.d.ts} +170 -2
  137. package/dist/{index-BFZxzCYu.d.ts → index-o00Upzjp.d.ts} +3 -3
  138. package/dist/{index-BEZ4ezJk.d.ts → index-ql9ApSTF.d.ts} +7 -0
  139. package/dist/index.d.ts +39 -37
  140. package/dist/index.js +31 -30
  141. package/dist/landing-Bs0aMIsR.js +2049 -0
  142. package/dist/{loadCatalog-DFyDz_4e.d.ts → loadCatalog-BJwcyX8i.d.ts} +2 -0
  143. package/dist/{loadCatalog-C3MSknfx.js → loadCatalog-C1kms5sO.js} +5 -1
  144. package/dist/locale/index.d.ts +2 -2
  145. package/dist/locale/index.js +3 -3
  146. package/dist/{locale-OCGw4bi6.js → locale-CHhsd9Mq.js} +1 -1
  147. package/dist/motionTokenDefaults-EFzpiAF5.js +38 -0
  148. package/dist/tokenName-0U-WEH09.js +36 -0
  149. package/dist/{typeahead-RkZw0Ktn.js → typeahead-BgfLP7vR.js} +2 -0
  150. package/dist/{index-DbFIQDoa.d.ts → types-C1ydeFiu.d.ts} +43 -65
  151. package/dist/{types-uWxXh1Jm.d.ts → types-fRasDCe4.d.ts} +47 -6
  152. package/dist/useAnimatedLayout-C0koWm4a.d.ts +56 -0
  153. package/dist/{useAsyncSource-Gk0VtE7_.js → useAsyncSource-7GTcK8ep.js} +31 -1
  154. package/dist/{useAsyncSource-aGzrvRkI.d.ts → useAsyncSource-DbG2FSuI.d.ts} +19 -2
  155. package/dist/{useCombobox-D374_pT8.js → useCombobox-DIR9yoEu.js} +150 -3
  156. package/dist/{useTypeaheadAnnouncement-CSikDlpK.js → useTypeaheadMenuConfig--4f7jR6G.js} +264 -20
  157. package/package.json +1 -1
  158. package/styles/motion.css +10 -0
  159. package/styles/selector.css +10 -0
  160. package/styles/table.css +19 -0
  161. package/dist/composables-CCsHfpCS.js +0 -1256
  162. package/dist/{Chat-PEkZTrQE.js → Chat-Wq7e98zS.js} +1 -1
  163. package/dist/{CodeBlock-9Lfec8C8.js → CodeBlock-CLVXVlB7.js} +1 -1
  164. package/dist/{DateInput-kXAc_r5m.js → DateInput-BitZfGEY.js} +1 -1
  165. package/dist/{DateRangeInput-DW7IzFQM.js → DateRangeInput-kxXBsUTU.js} +1 -1
@@ -0,0 +1,458 @@
1
+ //#region src/motion/reducedMotionMark.ts
2
+ /**
3
+ * @file reducedMotionMark.ts
4
+ * @input Whether a theme reduces motion for everyone
5
+ * @output reducedMotionMarkProps and setRootReducedMotionMark, which write the
6
+ * mark, and themeReducesMotion, which reads it
7
+ * @position Owner module of the private reduced-motion attribute: the only
8
+ * file that writes its name. A theme that reduces motion for everyone
9
+ * spreads the mark on its root, and the root theme sets it on `<html>`; the
10
+ * animator and reducedMotionFade read it as the person's Reduce Motion
11
+ * setting. No package entry exports it.
12
+ */
13
+ const REDUCED_MOTION = "data-astryx-reduced-motion";
14
+ /**
15
+ * Whether the theme `element` is in reduces motion for everyone: its root,
16
+ * or `<html>` for the root theme, carries the mark.
17
+ */
18
+ function themeReducesMotion(element) {
19
+ return element?.closest?.(`[${REDUCED_MOTION}]`) != null;
20
+ }
21
+ //#endregion
22
+ //#region src/utils/sharedRealm.ts
23
+ /**
24
+ * 对应原版 Astryx 的 `utils/sharedRealm`。
25
+ *
26
+ * 整个 JavaScript 运行环境里按键共享一份值:页面上同时加载了两份 core(比如包本身和一份复制进项目的副本)时,
27
+ * 两边拿同一个键读到的是同一份值。不碰 DOM,服务端也能用。
28
+ */
29
+ /**
30
+ * 共享值的注册键。版本号表示值的形状:形状变了、旧副本读不懂新值时就升版本,
31
+ * 两边各用各的。
32
+ */
33
+ function sharedKey(name, version) {
34
+ return Symbol.for(`@astryx-vue/core/${name}/v${version}`);
35
+ }
36
+ /**
37
+ * `key` 下的共享值,第一次用时创建。
38
+ * `accepts` 防键撞车:它不认的值原样留着,这一份自己另建一个。
39
+ */
40
+ function realmValue(key, create, accepts = () => true) {
41
+ const realm = globalThis;
42
+ if (Object.hasOwn(realm, key)) {
43
+ const existing = realm[key];
44
+ return accepts(existing) ? existing : create();
45
+ }
46
+ const value = create();
47
+ realm[key] = value;
48
+ return value;
49
+ }
50
+ /**
51
+ * 按注册名在整页共享一份值:计数器、开关,或装着几样东西的对象。
52
+ * 名字写成 `<目录>/<文件>/<绑定名>`(短横线小写),值的形状变了就升版本。
53
+ */
54
+ function sharedState(name, version, create) {
55
+ return realmValue(sharedKey(name, version), create);
56
+ }
57
+ /** 按注册名共享的 Map。 */
58
+ function sharedMap(name, version) {
59
+ return sharedState(name, version, () => /* @__PURE__ */ new Map());
60
+ }
61
+ /** 按注册名共享的 WeakMap,例如按文档存的状态。 */
62
+ function sharedWeakMap(name, version) {
63
+ return sharedState(name, version, () => /* @__PURE__ */ new WeakMap());
64
+ }
65
+ /** 按注册名共享的 WeakSet,例如登记过的值。 */
66
+ function sharedWeakSet(name, version) {
67
+ return sharedState(name, version, () => /* @__PURE__ */ new WeakSet());
68
+ }
69
+ //#endregion
70
+ //#region src/motion/presentation.ts
71
+ const presented = realmValue(sharedKey("motion/presentation", 1), () => ({
72
+ sources: /* @__PURE__ */ new Map(),
73
+ watchers: /* @__PURE__ */ new Set(),
74
+ batchDepth: 0,
75
+ isChanged: false
76
+ }));
77
+ const { sources, watchers } = presented;
78
+ /** Tell every watcher the reported elements changed; one's throw stops none. */
79
+ function notifyWatchers() {
80
+ if (presented.batchDepth > 0) {
81
+ presented.isChanged = true;
82
+ return;
83
+ }
84
+ for (const watcher of [...watchers]) try {
85
+ watcher();
86
+ } catch (error) {
87
+ queueMicrotask(() => {
88
+ throw error;
89
+ });
90
+ }
91
+ }
92
+ /**
93
+ * Runs `apply`, which reports elements or removes reports, and tells the
94
+ * watchers once, at its end, when the reported elements changed. So the
95
+ * moves of one layout change cost one notice.
96
+ */
97
+ function batchPresented(apply) {
98
+ presented.batchDepth += 1;
99
+ try {
100
+ apply();
101
+ } finally {
102
+ presented.batchDepth -= 1;
103
+ if (presented.batchDepth === 0 && presented.isChanged) {
104
+ presented.isChanged = false;
105
+ notifyWatchers();
106
+ }
107
+ }
108
+ }
109
+ /**
110
+ * Report an element drawn away from where the engine hit-tests it. Returns
111
+ * the function that removes the report.
112
+ */
113
+ function registerPresentedOffset(element, source) {
114
+ sources.set(element, source);
115
+ notifyWatchers();
116
+ return () => {
117
+ if (sources.get(element) === source) {
118
+ sources.delete(element);
119
+ notifyWatchers();
120
+ }
121
+ };
122
+ }
123
+ /** The custom property whose writes make WebKit resolve a moving element. */
124
+ const RESOLVE_PROPERTY = "--astryx-presented";
125
+ /**
126
+ * Makes iOS WebKit resolve `element`'s transform again, to the value drawn
127
+ * now: one write of a value the property does not have yet. The animator and
128
+ * the animated layout both write it, so it counts up from the element's own
129
+ * last value.
130
+ */
131
+ function writePresentedResolve(element) {
132
+ const last = Number(element.style.getPropertyValue(RESOLVE_PROPERTY)) || 0;
133
+ element.style.setProperty(RESOLVE_PROPERTY, String(last + 1));
134
+ }
135
+ /** Removes the resolve write from `element`. */
136
+ function clearPresentedResolve(element) {
137
+ element.style.removeProperty(RESOLVE_PROPERTY);
138
+ }
139
+ //#endregion
140
+ //#region src/motion/roleValue.ts
141
+ const ROLE_ID = /^[a-z][A-Za-z0-9]*(?:\.[a-z][A-Za-z0-9]*)+$/;
142
+ /** Whether `id` is a well-formed role name (a dotted table path). */
143
+ function isMotionRoleId(id) {
144
+ return ROLE_ID.test(id);
145
+ }
146
+ /** The CSS custom property for a role: `--motion-` + the path in kebab case. */
147
+ function motionRoleVariable(id) {
148
+ if (!isMotionRoleId(id)) throw new Error(`motion role "${id}" must be a dotted table path such as "springs.sheetPresent"`);
149
+ return `--motion-${id.split(".").map((part) => part.replace(/[A-Z]/g, (c) => `-${c.toLowerCase()}`)).join("-")}`;
150
+ }
151
+ function isSpring(value) {
152
+ if (value === null || typeof value !== "object" || Array.isArray(value)) return false;
153
+ return "response" in value && "dampingRatio" in value || "duration" in value && "bounce" in value || "stiffness" in value && "damping" in value;
154
+ }
155
+ function isCurve(value) {
156
+ return Array.isArray(value) && value.length === 4 && value.every((n) => typeof n === "number");
157
+ }
158
+ //#endregion
159
+ //#region src/motion/roles.ts
160
+ const rolesById = /* @__PURE__ */ new Map();
161
+ /** A table id → the table registered under it. */
162
+ const tablesById = /* @__PURE__ */ new Map();
163
+ /** A spring or curve leaf → its role. */
164
+ const roleOfLeaf = /* @__PURE__ */ new WeakMap();
165
+ /** A table or one of its groups → its path. */
166
+ const pathOfGroup = /* @__PURE__ */ new WeakMap();
167
+ /** A table path → the role id it is registered under, when renamed. */
168
+ const roleIdOfPath = /* @__PURE__ */ new Map();
169
+ /**
170
+ * Registers a motion table: each spring, `…Ms` duration and curve leaf that
171
+ * `roles` lists (its role name, relative to the table) becomes a role named
172
+ * by its path under `id`; the table's other values stay internal constants. A leaf object the table shares between
173
+ * two keys is replaced in the table by an equal copy, so each role has its own
174
+ * object (an animator resolves a role from the object it is handed).
175
+ * `exclude` lists paths, relative to the table, that are not motion;
176
+ * `rename` maps a path, relative to the table, to the role name it is
177
+ * registered under (relative too), so a role is named for its use while the
178
+ * table keeps its source's name. Registering the same table under the same id
179
+ * again does nothing.
180
+ */
181
+ function registerMotionTable(id, table, { roles = [], exclude = [], rename = {} } = {}) {
182
+ if (!/^[a-z][A-Za-z0-9]*$/.test(id)) throw new Error(`motion table id "${id}" must be one camelCase word`);
183
+ if (tablesById.get(id) === table) return;
184
+ tablesById.set(id, table);
185
+ const skip = new Set(exclude.map((path) => `${id}.${path}`));
186
+ const listed = new Set(roles.map((name) => `${id}.${name}`));
187
+ const walk = (group, prefix) => {
188
+ pathOfGroup.set(group, prefix);
189
+ for (const [key, value] of Object.entries(group)) {
190
+ const path = `${prefix}.${key}`;
191
+ if (skip.has(path)) continue;
192
+ let kind = null;
193
+ if (isSpring(value)) kind = "spring";
194
+ else if (isCurve(value)) kind = "curve";
195
+ else if (typeof value === "number" && key.endsWith("Ms")) kind = "duration";
196
+ else if (value !== null && typeof value === "object" && !Array.isArray(value)) {
197
+ walk(value, path);
198
+ continue;
199
+ }
200
+ if (kind == null) continue;
201
+ const relative = path.slice(id.length + 1);
202
+ const roleId = relative in rename ? `${id}.${rename[relative]}` : path;
203
+ if (!listed.has(roleId)) continue;
204
+ if (roleId !== path) roleIdOfPath.set(path, roleId);
205
+ let leaf = value;
206
+ if (typeof leaf === "object") {
207
+ const taken = roleOfLeaf.get(leaf);
208
+ if (taken != null && taken.id !== roleId) {
209
+ leaf = Object.freeze(Array.isArray(leaf) ? [...leaf] : { ...leaf });
210
+ group[key] = leaf;
211
+ }
212
+ }
213
+ const role = {
214
+ id: roleId,
215
+ kind,
216
+ variable: motionRoleVariable(roleId),
217
+ value: leaf
218
+ };
219
+ rolesById.set(roleId, role);
220
+ if (typeof leaf === "object") roleOfLeaf.set(leaf, role);
221
+ }
222
+ };
223
+ walk(table, id);
224
+ }
225
+ /**
226
+ * Registers `leaf` as the spring role `id` (a table path such as
227
+ * `springs.settle`) and returns it, so a table row can register itself. A row
228
+ * that calls it under a pure annotation drops out of a bundle that does not
229
+ * use it, call included. Registering the same leaf under the same id again
230
+ * does nothing.
231
+ */
232
+ function registerSpringRole(id, leaf) {
233
+ if (!isMotionRoleId(id)) throw new Error(`motion role "${id}" must be a dotted table path such as "springs.settle"`);
234
+ if (roleOfLeaf.get(leaf)?.id !== id) {
235
+ const role = {
236
+ id,
237
+ kind: "spring",
238
+ variable: motionRoleVariable(id),
239
+ value: leaf
240
+ };
241
+ rolesById.set(id, role);
242
+ roleOfLeaf.set(leaf, role);
243
+ }
244
+ return leaf;
245
+ }
246
+ /** The role a spring or curve leaf of a registered table plays, if any. */
247
+ function motionRoleOf(leaf) {
248
+ return leaf !== null && typeof leaf === "object" ? roleOfLeaf.get(leaf) : void 0;
249
+ }
250
+ /**
251
+ * The role `group[key]` plays, for a table or one of its groups: the way to
252
+ * name a duration, which is a bare number.
253
+ */
254
+ function motionRoleIn(group, key) {
255
+ const prefix = pathOfGroup.get(group);
256
+ if (prefix == null) return;
257
+ const path = `${prefix}.${key}`;
258
+ return rolesById.get(roleIdOfPath.get(path) ?? path);
259
+ }
260
+ const NUMBER = "(-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:e-?\\d+)?)";
261
+ const SPRING_VALUE = new RegExp(`^${NUMBER}s\\s+${NUMBER}$`);
262
+ const DURATION_VALUE = new RegExp(`^${NUMBER}(ms|s)$`);
263
+ const CURVE_VALUE = new RegExp(`^cubic-bezier\\(\\s*${NUMBER}\\s*,\\s*${NUMBER}\\s*,\\s*${NUMBER}\\s*,\\s*${NUMBER}\\s*\\)$`);
264
+ function parseMotionRoleValue(kind, text) {
265
+ const value = text.trim();
266
+ if (value === "") return null;
267
+ if (kind === "spring") {
268
+ const m = SPRING_VALUE.exec(value);
269
+ if (m == null) return null;
270
+ const duration = Number(m[1]);
271
+ const bounce = Number(m[2]);
272
+ return duration > 0 && bounce > -1 && bounce < 1 ? {
273
+ duration,
274
+ bounce
275
+ } : null;
276
+ }
277
+ if (kind === "duration") {
278
+ const m = DURATION_VALUE.exec(value);
279
+ if (m == null) return null;
280
+ const ms = Number(m[1]) * (m[2] === "s" ? 1e3 : 1);
281
+ return ms >= 0 ? ms : null;
282
+ }
283
+ const m = CURVE_VALUE.exec(value);
284
+ if (m == null) return null;
285
+ const points = [
286
+ m[1],
287
+ m[2],
288
+ m[3],
289
+ m[4]
290
+ ].map(Number);
291
+ return points[0] >= 0 && points[0] <= 1 && points[2] >= 0 && points[2] <= 1 ? points : null;
292
+ }
293
+ /** The CSS easing keywords, as the control points CSS gives them. */
294
+ const EASING_KEYWORDS = {
295
+ "linear": [
296
+ 0,
297
+ 0,
298
+ 1,
299
+ 1
300
+ ],
301
+ "ease": [
302
+ .25,
303
+ .1,
304
+ .25,
305
+ 1
306
+ ],
307
+ "ease-in": [
308
+ .42,
309
+ 0,
310
+ 1,
311
+ 1
312
+ ],
313
+ "ease-out": [
314
+ 0,
315
+ 0,
316
+ .58,
317
+ 1
318
+ ],
319
+ "ease-in-out": [
320
+ .42,
321
+ 0,
322
+ .58,
323
+ 1
324
+ ]
325
+ };
326
+ /**
327
+ * Reads a CSS easing, a keyword or a `cubic-bezier()`, as a curve role's value
328
+ * is read. Returns null for any other easing, such as `steps()`.
329
+ */
330
+ function parseCssEasing(text) {
331
+ const value = text.trim();
332
+ return EASING_KEYWORDS[value] ?? parseMotionRoleValue("curve", value);
333
+ }
334
+ //#endregion
335
+ //#region src/motion/uikit/timing.ts
336
+ /**
337
+ * @file timing.ts
338
+ * @input Nothing; data only
339
+ * @output Exports `timing`: the non-spring clocks and curves UIKit uses
340
+ * (press highlight onset, flash and fade, Core Animation's named Bézier
341
+ * curves, the navigation bar hide/show duration, the keyboard
342
+ * notification duration, the Reduced Motion cross-fade)
343
+ * @position The timing domain of the UIKit constants table (motion/uikit)
344
+ *
345
+ * Every leaf carries one or more `@source` (apple-docs | wwdc | webkit |
346
+ * measured | GUESS); webkit and GUESS values also carry the `@measure` task
347
+ * that will confirm or replace them (MEASUREMENTS.md). uikit.test.ts
348
+ * enforces both.
349
+ *
350
+ * Durations are in ms (the unit of pointer-event timestamps, which these
351
+ * clocks are compared against); curves are cubic-bézier control points
352
+ * [x1, y1, x2, y2].
353
+ */
354
+ /**
355
+ * The Reduce Motion fade, its own export so the animator reads it without
356
+ * the rest of the table (`architecture:component-style-authoring` INV6).
357
+ * `timing` composes it under its table paths, `reducedMotionCrossFadeMs` and
358
+ * `curves.move`, so their roles are unchanged.
359
+ */
360
+ const reducedMotionCrossFade = {
361
+ /**
362
+ * The Reduced Motion cross-fade, in ms, on `curves.move`: under
363
+ * Reduce Motion an entrance, exit, presentation switch or state change
364
+ * becomes an opacity-only cross-fade of this length on a coarse pointer
365
+ * (design:reduced-motion DR2 caps it at 200 ms, by owner decision DEC-1
366
+ * of 2026-10-24, departing from UIKit's own navigation cross-fade,
367
+ * measured below at 0.5 s). Not a role: nothing lengthens it (DR4).
368
+ * @source apple-docs https://developer.apple.com/documentation/uikit/uiaccessibility/preferscrossfadetransitions
369
+ * (the setting)
370
+ * @source measured: UIKit lab (injected host app), iOS 26.2 simulator,
371
+ * iPhone 17 Pro, CAAnimation dump with Reduce Motion and Prefer
372
+ * Cross-Fade Transitions on (opacity CABasicAnimation 0.5 s,
373
+ * (0.42, 0, 0.58, 1)), Oct 23 2026
374
+ */
375
+ durationMs: 200,
376
+ /**
377
+ * `easeInEaseOut`; UIKit's default curve (`UIView.AnimationCurve
378
+ * .easeInOut`, "the default curve for most animations").
379
+ * @source apple-docs https://developer.apple.com/documentation/quartzcore/camediatimingfunctionname/easeineaseout
380
+ * @source measured: UIKit lab (injected host app), iOS 26.2 simulator,
381
+ * iPhone 17 Pro, CAMediaTimingFunction read from UIView.animate,
382
+ * Oct 23 2026
383
+ */
384
+ curve: [
385
+ .42,
386
+ 0,
387
+ .58,
388
+ 1
389
+ ]
390
+ };
391
+ const { durationMs: reducedMotionCrossFadeMs, curve: move } = reducedMotionCrossFade;
392
+ const reducedMotionCrossFadeRoles = { curves: { move } };
393
+ /**
394
+ * Registers only the Reduce Motion fade's curve as its role,
395
+ * `timing.curves.move`, for code that reads the fade without the rest of the
396
+ * table (the animator, reducedMotionFade()). The fade's length is not a role.
397
+ */
398
+ function registerReducedMotionCrossFade() {
399
+ registerMotionTable("timing", reducedMotionCrossFadeRoles, { roles: ["curves.move"] });
400
+ }
401
+ //#endregion
402
+ //#region src/motion/bezier.ts
403
+ /** The timing function for `points`: maps time progress to eased progress. */
404
+ function cubicBezier([x1, y1, x2, y2]) {
405
+ const cx = 3 * x1;
406
+ const bx = 3 * (x2 - x1) - cx;
407
+ const ax = 1 - cx - bx;
408
+ const cy = 3 * y1;
409
+ const by = 3 * (y2 - y1) - cy;
410
+ const ay = 1 - cy - by;
411
+ const sampleX = (t) => ((ax * t + bx) * t + cx) * t;
412
+ const sampleY = (t) => ((ay * t + by) * t + cy) * t;
413
+ const slopeX = (t) => (3 * ax * t + 2 * bx) * t + cx;
414
+ const solveT = (x) => {
415
+ let t = x;
416
+ for (let i = 0; i < 8; i++) {
417
+ const error = sampleX(t) - x;
418
+ if (Math.abs(error) < 1e-7) return t;
419
+ const slope = slopeX(t);
420
+ if (Math.abs(slope) < 1e-6) break;
421
+ t -= error / slope;
422
+ }
423
+ let lo = 0;
424
+ let hi = 1;
425
+ t = x;
426
+ for (let i = 0; i < 60; i++) {
427
+ const value = sampleX(t);
428
+ if (Math.abs(value - x) < 1e-7) break;
429
+ if (value < x) lo = t;
430
+ else hi = t;
431
+ t = (lo + hi) / 2;
432
+ }
433
+ return t;
434
+ };
435
+ return (x) => x <= 0 ? 0 : x >= 1 ? 1 : sampleY(solveT(x));
436
+ }
437
+ //#endregion
438
+ //#region src/motion/layout/handle.ts
439
+ /**
440
+ * @file handle.ts
441
+ * @position Internal to motion/layout; split from upstream motion/animatedLayout.ts
442
+ */
443
+ const AREA = sharedKey("animated-layout/area", 1);
444
+ /** The container a handle reads, or null for a value that is not a handle. */
445
+ function readArea(handle) {
446
+ const read = handle[AREA];
447
+ return typeof read === "function" ? read() : null;
448
+ }
449
+ /** A handle over `area` (the container element, read when a change runs). */
450
+ function createAnimatedLayout(area) {
451
+ return Object.freeze(Object.defineProperty({}, AREA, { value: area }));
452
+ }
453
+ function areaOf(handle, element) {
454
+ const area = readArea(handle);
455
+ return area != null && area !== element && area.contains(element) ? area : null;
456
+ }
457
+ //#endregion
458
+ export { sharedMap as _, registerReducedMotionCrossFade as a, sharedWeakSet as b, parseCssEasing as c, registerSpringRole as d, isSpring as f, writePresentedResolve as g, registerPresentedOffset as h, reducedMotionCrossFade as i, parseMotionRoleValue as l, clearPresentedResolve as m, createAnimatedLayout as n, motionRoleIn as o, batchPresented as p, cubicBezier as r, motionRoleOf as s, areaOf as t, registerMotionTable as u, sharedState as v, themeReducesMotion as x, sharedWeakMap as y };
@@ -84,8 +84,8 @@ interface StepSlots {
84
84
  //#region src/Stepper/Step.vue.d.ts
85
85
  type __VLS_Slots$1 = StepSlots;
86
86
  declare const __VLS_base$1: import("vue").DefineComponent<StepProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<StepProps> & Readonly<{}>, {
87
- isOptional: boolean;
88
87
  isDisabled: boolean;
88
+ isOptional: boolean;
89
89
  indicator: StepIndicator;
90
90
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
91
91
  declare const __VLS_export$1: __VLS_WithSlots$1<typeof __VLS_base$1, __VLS_Slots$1>;
@@ -99,8 +99,8 @@ type __VLS_WithSlots$1<T, S> = T & {
99
99
  //#region src/Stepper/Stepper.vue.d.ts
100
100
  type __VLS_Slots = StepperSlots;
101
101
  declare const __VLS_base: import("vue").DefineComponent<StepperProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<StepperProps> & Readonly<{}>, {
102
- orientation: StepperOrientation;
103
102
  density: StepperDensity;
103
+ orientation: StepperOrientation;
104
104
  indicatorPosition: StepperIndicatorPosition;
105
105
  hasCollapsibleLabels: boolean;
106
106
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
@@ -52,8 +52,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
52
52
  "onUpdate:mobileNavOpen"?: ((value: boolean) => any) | undefined;
53
53
  onMobileNavOpenChange?: ((isOpen: boolean) => any) | undefined;
54
54
  }>, {
55
- variant: AppShellVariant;
56
55
  height: AppShellHeight;
56
+ variant: AppShellVariant;
57
57
  mobileNav: false | AppShellMobileNav;
58
58
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
59
59
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
@@ -44,8 +44,8 @@ interface TimerProps {
44
44
  //#region src/Timer/Timer.vue.d.ts
45
45
  declare const __VLS_export: import("vue").DefineComponent<TimerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TimerProps> & Readonly<{}>, {
46
46
  type: TimerType;
47
- color: TimerColor;
48
47
  format: "clock" | "elapsed";
48
+ color: TimerColor;
49
49
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
50
50
  declare const _default: typeof __VLS_export;
51
51
  //#endregion
@@ -174,33 +174,33 @@ declare const __VLS_base: import("vue").DefineComponent<MultiSelectorProps, {
174
174
  focus: () => void;
175
175
  blur: () => void | undefined;
176
176
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
177
+ search: (query: string) => any;
177
178
  change: (value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any;
178
179
  click: (event: MouseEvent) => any;
180
+ focus: (event: FocusEvent) => any;
179
181
  keydown: (event: KeyboardEvent) => any;
180
182
  openChange: (isOpen: boolean) => any;
181
183
  "update:modelValue": (value: (string | number)[]) => any;
182
- search: (query: string) => any;
183
- focus: (event: FocusEvent) => any;
184
184
  }, string, import("vue").PublicProps, Readonly<MultiSelectorProps> & Readonly<{
185
+ onSearch?: ((query: string) => any) | undefined;
185
186
  onChange?: ((value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any) | undefined;
186
187
  onClick?: ((event: MouseEvent) => any) | undefined;
188
+ onFocus?: ((event: FocusEvent) => any) | undefined;
187
189
  onKeydown?: ((event: KeyboardEvent) => any) | undefined;
188
190
  onOpenChange?: ((isOpen: boolean) => any) | undefined;
189
191
  "onUpdate:modelValue"?: ((value: (string | number)[]) => any) | undefined;
190
- onSearch?: ((query: string) => any) | undefined;
191
- onFocus?: ((event: FocusEvent) => any) | undefined;
192
192
  }>, {
193
193
  required: boolean;
194
- modelValue: readonly (string | number)[];
195
- isLoading: boolean;
196
194
  status: MultiSelectorStatus;
197
- statusVariant: MultiSelectorStatusVariant;
198
195
  variant: MultiSelectorVariant;
196
+ isLoading: boolean;
197
+ modelValue: readonly (string | number)[];
198
+ statusVariant: MultiSelectorStatusVariant;
199
+ presentation: MultiSelectorPresentation;
200
+ isReadOnly: boolean;
199
201
  labelHidden: boolean;
200
202
  disabled: boolean;
201
- isReadOnly: boolean;
202
203
  clearable: boolean;
203
- presentation: MultiSelectorPresentation;
204
204
  hasCreate: boolean;
205
205
  optional: boolean;
206
206
  searchable: boolean;
@@ -1,6 +1,6 @@
1
1
  import { n as SpacingStep } from "./types-BTk0WZ0b.js";
2
2
  import { n as BadgeVariant } from "./types-DIYwbkpe.js";
3
- import { a as SearchableItem, i as SearchSource } from "./useAsyncSource-aGzrvRkI.js";
3
+ import { a as SearchSource, o as SearchableItem } from "./useAsyncSource-DbG2FSuI.js";
4
4
  import { ComputedRef, InjectionKey, MaybeRefOrGetter, Ref, VNode } from "vue";
5
5
  //#region src/Chat/messageTypes.d.ts
6
6
  /** Who sent a message row. `system` is centered and ignores avatar, name, and metadata. */
@@ -536,17 +536,17 @@ declare const __VLS_base$11: import("vue").DefineComponent<ChatComposerProps, {
536
536
  element: Readonly<import("vue").ShallowRef<HTMLDivElement | null>>;
537
537
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
538
538
  change: (value: string) => any;
539
- "update:modelValue": (value: string) => any;
540
- stop: () => any;
541
539
  submit: (value: string) => any;
540
+ stop: () => any;
541
+ "update:modelValue": (value: string) => any;
542
542
  }, string, import("vue").PublicProps, Readonly<ChatComposerProps> & Readonly<{
543
543
  onChange?: ((value: string) => any) | undefined;
544
- "onUpdate:modelValue"?: ((value: string) => any) | undefined;
545
- onStop?: (() => any) | undefined;
546
544
  onSubmit?: ((value: string) => any) | undefined;
545
+ onStop?: (() => any) | undefined;
546
+ "onUpdate:modelValue"?: ((value: string) => any) | undefined;
547
547
  }>, {
548
- elevation: ChatComposerElevation;
549
548
  density: ChatDensity;
549
+ elevation: ChatComposerElevation;
550
550
  statusPosition: "top" | "bottom";
551
551
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
552
552
  declare const __VLS_export$17: __VLS_WithSlots$11<typeof __VLS_base$11, __VLS_Slots$11>;
@@ -584,19 +584,19 @@ type __VLS_WithSlots$10<T, S> = T & {
584
584
  //#region src/Chat/ChatComposerInput.vue.d.ts
585
585
  declare const __VLS_export$15: import("vue").DefineComponent<ChatComposerInputProps, ChatComposerInputHandle, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
586
586
  change: (value: string) => any;
587
+ submit: (value: string) => any;
587
588
  keydown: (event: KeyboardEvent) => any;
588
589
  "update:modelValue": (value: string) => any;
589
- submit: (value: string) => any;
590
590
  files: (files: File[]) => any;
591
591
  }, string, import("vue").PublicProps, Readonly<ChatComposerInputProps> & Readonly<{
592
592
  onChange?: ((value: string) => any) | undefined;
593
+ onSubmit?: ((value: string) => any) | undefined;
593
594
  onKeydown?: ((event: KeyboardEvent) => any) | undefined;
594
595
  "onUpdate:modelValue"?: ((value: string) => any) | undefined;
595
- onSubmit?: ((value: string) => any) | undefined;
596
596
  onFiles?: ((files: File[]) => any) | undefined;
597
597
  }>, {
598
- maxRows: number;
599
598
  debounceMs: number;
599
+ maxRows: number;
600
600
  hasHistory: boolean;
601
601
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
602
602
  declare const _default$15: typeof __VLS_export$15;
@@ -722,12 +722,12 @@ type __VLS_WithSlots$4<T, S> = T & {
722
722
  //#region src/Chat/ChatSendButton.vue.d.ts
723
723
  type __VLS_Slots$3 = ChatSendButtonSlots;
724
724
  declare const __VLS_base$3: import("vue").DefineComponent<ChatSendButtonProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
725
- click: (event: MouseEvent) => any;
726
725
  stop: () => any;
726
+ click: (event: MouseEvent) => any;
727
727
  send: () => any;
728
728
  }, string, import("vue").PublicProps, Readonly<ChatSendButtonProps> & Readonly<{
729
- onClick?: ((event: MouseEvent) => any) | undefined;
730
729
  onStop?: (() => any) | undefined;
730
+ onClick?: ((event: MouseEvent) => any) | undefined;
731
731
  onSend?: (() => any) | undefined;
732
732
  }>, {
733
733
  size: "sm" | "md";
@@ -1,4 +1,4 @@
1
- import { c as ThemeMode, i as MediaThemeProps, l as ThemeProps, n as DefineThemeInput, o as ThemeDefinition, s as ThemeIconVariant } from "./types-uWxXh1Jm.js";
1
+ import { c as ThemeMode, i as MediaThemeProps, l as ThemeProps, n as DefineThemeInput, o as ThemeDefinition, s as ThemeIconVariant } from "./types-fRasDCe4.js";
2
2
  import { ComputedRef } from "vue";
3
3
  //#region src/Theme/dataTokens.d.ts
4
4
  /**
@@ -10,9 +10,9 @@ declare const __VLS_base: import("vue").DefineComponent<ButtonProps, {
10
10
  }>, {
11
11
  type: "button" | "reset" | "submit";
12
12
  isDisabled: boolean;
13
- isLoading: boolean;
14
13
  variant: ButtonVariant;
15
14
  elevation: ButtonElevation;
15
+ isLoading: boolean;
16
16
  isIconOnly: boolean;
17
17
  isInterruptible: boolean;
18
18
  loadingLabel: string;
@@ -83,17 +83,17 @@ declare const __VLS_base: import("vue").DefineComponent<HoverCardProps, {
83
83
  }, string, import("vue").PublicProps, Readonly<HoverCardProps> & Readonly<{
84
84
  onOpenChange?: ((isOpen: boolean) => any) | undefined;
85
85
  }>, {
86
- isOpen: boolean;
87
86
  label: string;
87
+ content: string;
88
+ isOpen: boolean;
88
89
  placement: HoverCardPlacement;
89
90
  alignment: HoverCardAlignment;
90
- content: string;
91
91
  isDefaultOpen: boolean;
92
+ isEnabled: boolean;
92
93
  delay: number;
93
94
  hideDelay: number;
94
95
  focusTrigger: HoverCardFocusTrigger;
95
96
  touchTrigger: HoverCardTouchTrigger;
96
- isEnabled: boolean;
97
97
  hasHoverIndication: HoverCardHoverIndication;
98
98
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
99
99
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
@@ -219,8 +219,8 @@ declare const __VLS_export$1: import("vue").DefineComponent<CodeBlockProps, {
219
219
  onCopy?: (() => any) | undefined;
220
220
  onCopyError?: ((error: unknown) => any) | undefined;
221
221
  }>, {
222
- size: CodeBlockSize;
223
222
  width: string;
223
+ size: CodeBlockSize;
224
224
  container: CodeBlockContainer;
225
225
  language: string;
226
226
  hasLanguageLabel: boolean;