@astryx-vue/core 0.17.0 → 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.
- package/dist/AppShell/index.d.ts +1 -1
- package/dist/AvatarGroup/index.d.ts +1 -1
- package/dist/Banner/index.d.ts +1 -1
- package/dist/BottomSheet/index.d.ts +1 -1
- package/dist/Button/index.d.ts +1 -1
- package/dist/ButtonGroup/index.d.ts +1 -1
- package/dist/Calendar/index.d.ts +1 -1
- package/dist/Card/index.d.ts +1 -1
- package/dist/Carousel/index.d.ts +1 -1
- package/dist/Chat/index.d.ts +1 -1
- package/dist/CheckboxInput/index.d.ts +1 -1
- package/dist/CheckboxList/index.d.ts +1 -1
- package/dist/ClickableCard/index.d.ts +1 -1
- package/dist/Code/index.d.ts +1 -1
- package/dist/Collapsible/index.d.ts +1 -1
- package/dist/Collapsible/index.js +1 -1
- package/dist/{Collapsible-Dk9BQQbT.js → Collapsible-ExzU7vC0.js} +104 -40
- package/dist/ComplexSelector/index.d.ts +1 -1
- package/dist/ContextMenu/index.d.ts +1 -1
- package/dist/DateInput/index.d.ts +1 -1
- package/dist/DateRangeInput/index.d.ts +1 -1
- package/dist/DateTimeInput/index.d.ts +1 -1
- package/dist/Dialog/index.d.ts +1 -1
- package/dist/Divider/index.d.ts +1 -1
- package/dist/Drawer/index.d.ts +1 -1
- package/dist/FileInput/index.d.ts +1 -1
- package/dist/Heading/index.d.ts +1 -1
- package/dist/HoverCard/index.d.ts +1 -1
- package/dist/InfoTip/index.d.ts +1 -1
- package/dist/Link/index.d.ts +1 -1
- package/dist/List/index.d.ts +1 -1
- package/dist/{MediaTheme-Bkj-_DFN.js → MediaTheme-DfcdEWx-.js} +2 -36
- package/dist/MoreMenu/index.d.ts +1 -1
- package/dist/MultiSelector/index.d.ts +1 -1
- package/dist/NavItem/index.d.ts +1 -1
- package/dist/NumberInput/index.d.ts +1 -1
- package/dist/OverflowList/index.d.ts +1 -1
- package/dist/Pagination/index.d.ts +1 -1
- package/dist/Popover/index.d.ts +1 -1
- package/dist/PowerSearch/index.d.ts +1 -1
- package/dist/ProgressBar/index.d.ts +1 -1
- package/dist/Radio/index.d.ts +1 -1
- package/dist/RadioList/index.d.ts +1 -1
- package/dist/Resizable/index.d.ts +1 -1
- package/dist/ScrollableArea/index.d.ts +1 -1
- package/dist/SelectableCard/index.d.ts +1 -1
- package/dist/Selector/index.d.ts +1 -1
- package/dist/SideNav/index.d.ts +1 -1
- package/dist/Stepper/index.d.ts +1 -1
- package/dist/Switch/index.d.ts +1 -1
- package/dist/TabList/index.d.ts +1 -1
- package/dist/Table/index.d.ts +1 -1
- package/dist/Table/index.js +1 -1
- package/dist/{Table-CRKljXg4.js → Table-iemur_3E.js} +372 -1
- package/dist/Text/index.d.ts +1 -1
- package/dist/TextArea/index.d.ts +1 -1
- package/dist/TextInput/index.d.ts +1 -1
- package/dist/Theme/index.js +3 -2
- package/dist/{Theme-iqi6AvU_.js → Theme-1RJVaRgz.js} +3 -38
- package/dist/TimeInput/index.d.ts +1 -1
- package/dist/Timer/index.d.ts +1 -1
- package/dist/Timestamp/index.d.ts +1 -1
- package/dist/Toast/index.js +1 -1
- package/dist/{Toast-CzbqvHDN.js → Toast-D4Q6wvYu.js} +1 -1
- package/dist/ToggleButton/index.d.ts +1 -1
- package/dist/Token/index.d.ts +1 -1
- package/dist/Tokenizer/index.d.ts +1 -1
- package/dist/Toolbar/index.d.ts +1 -1
- package/dist/Tooltip/index.d.ts +1 -1
- package/dist/TopNav/index.d.ts +1 -1
- package/dist/TreeList/index.d.ts +1 -1
- package/dist/TreeList/index.js +1 -1
- package/dist/{TreeList-CNj4KnHH.js → TreeList-ugSF9DWj.js} +117 -2
- package/dist/composables/index.d.ts +3 -2
- package/dist/composables/index.js +2 -2
- package/dist/{composables-BKHcPgN0.js → composables-BgfubKnk.js} +39 -332
- package/dist/handle-BPXdHbkr.js +458 -0
- package/dist/{index-CO9GW-ik.d.ts → index-B-3EGjfQ.d.ts} +1 -1
- package/dist/{index-TXcNH86P.d.ts → index-B1eCxBCY.d.ts} +1 -1
- package/dist/{index-9eluGe3a.d.ts → index-BBTU-TKb.d.ts} +1 -1
- package/dist/{index-85RFPeV0.d.ts → index-BKpnfdq1.d.ts} +4 -4
- package/dist/{index-CyMStZq4.d.ts → index-B_PKY-Wn.d.ts} +5 -5
- package/dist/{index-CTjkJP4x.d.ts → index-Bgk1Rj2A.d.ts} +1 -1
- package/dist/{index-CuW4AQ7M.d.ts → index-BhxqUt3y.d.ts} +2 -2
- package/dist/{index-DofC9Rll.d.ts → index-BtqvPjAf.d.ts} +1 -1
- package/dist/{index-ChqMaV6N.d.ts → index-Bzi3A980.d.ts} +1 -1
- package/dist/{index-DK0Wdo9N.d.ts → index-BzmcDJau.d.ts} +4 -4
- package/dist/{index-CMLnSg3T.d.ts → index-C4S65SAW.d.ts} +8 -1
- package/dist/{index-dWlCpnua.d.ts → index-C5e2rZML.d.ts} +2 -2
- package/dist/{index-waTkqxTz.d.ts → index-C89cIh4E.d.ts} +1 -1
- package/dist/{index-D05JGsT3.d.ts → index-C8wfe0Mr.d.ts} +1 -1
- package/dist/{index-rdwI-mcm.d.ts → index-CtYlR9Cu.d.ts} +1 -1
- package/dist/{index-QnlWyUxN.d.ts → index-DE1genab.d.ts} +2 -2
- package/dist/{index-BxWCX2pJ.d.ts → index-DFLPv9io.d.ts} +3 -3
- package/dist/{index-BL4mH8aK.d.ts → index-DMN_JVEt.d.ts} +1 -1
- package/dist/{index-Cy1rEWC-.d.ts → index-DMcf0QeR.d.ts} +2 -2
- package/dist/{index-DYabo8TI.d.ts → index-DPhQZXYw.d.ts} +1 -1
- package/dist/{index-B0iRA00v.d.ts → index-DmAEpn5E.d.ts} +2 -2
- package/dist/{index-CH-xSiJz.d.ts → index-DtZUOyCy.d.ts} +2 -2
- package/dist/{index-CbA8rR_b.d.ts → index-FeZXsFO-.d.ts} +2 -2
- package/dist/{index-C1zwvxPH.d.ts → index-KcCNhdAw.d.ts} +2 -2
- package/dist/{index-lmd9LZKB.d.ts → index-PffxihMx.d.ts} +1 -1
- package/dist/{index-B95VIgRl.d.ts → index-Y4H4X6Vy.d.ts} +63 -57
- package/dist/{index-COgrQZIL.d.ts → index-YKCx03zD.d.ts} +2 -2
- package/dist/{index-tuNsmJxw.d.ts → index-gu5EvbE0.d.ts} +1 -0
- package/dist/{index-9tZJgo0R.d.ts → index-o00Upzjp.d.ts} +1 -1
- package/dist/{index-wY6dKz6c.d.ts → index-ql9ApSTF.d.ts} +9 -2
- package/dist/index.d.ts +33 -32
- package/dist/index.js +9 -8
- package/dist/landing-Bs0aMIsR.js +2049 -0
- package/dist/motionTokenDefaults-EFzpiAF5.js +38 -0
- package/dist/tokenName-0U-WEH09.js +36 -0
- package/dist/useAnimatedLayout-C0koWm4a.d.ts +56 -0
- package/package.json +1 -1
- package/styles/table.css +19 -0
- package/dist/{index-D8lv2BiD.d.ts → index-BqhgeAT4.d.ts} +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 };
|
|
@@ -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
|
|
@@ -175,25 +175,25 @@ declare const __VLS_base: import("vue").DefineComponent<MultiSelectorProps, {
|
|
|
175
175
|
blur: () => void | undefined;
|
|
176
176
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
177
177
|
search: (query: string) => any;
|
|
178
|
+
change: (value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any;
|
|
178
179
|
click: (event: MouseEvent) => any;
|
|
179
180
|
focus: (event: FocusEvent) => any;
|
|
180
|
-
change: (value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any;
|
|
181
181
|
keydown: (event: KeyboardEvent) => any;
|
|
182
182
|
openChange: (isOpen: boolean) => any;
|
|
183
183
|
"update:modelValue": (value: (string | number)[]) => any;
|
|
184
184
|
}, string, import("vue").PublicProps, Readonly<MultiSelectorProps> & Readonly<{
|
|
185
185
|
onSearch?: ((query: string) => any) | undefined;
|
|
186
|
+
onChange?: ((value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any) | undefined;
|
|
186
187
|
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
187
188
|
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
188
|
-
onChange?: ((value: (string | number)[], change?: MultiSelectorCreateChange | undefined) => any) | undefined;
|
|
189
189
|
onKeydown?: ((event: KeyboardEvent) => any) | undefined;
|
|
190
190
|
onOpenChange?: ((isOpen: boolean) => any) | undefined;
|
|
191
191
|
"onUpdate:modelValue"?: ((value: (string | number)[]) => any) | undefined;
|
|
192
192
|
}>, {
|
|
193
193
|
required: boolean;
|
|
194
|
-
isLoading: boolean;
|
|
195
|
-
variant: MultiSelectorVariant;
|
|
196
194
|
status: MultiSelectorStatus;
|
|
195
|
+
variant: MultiSelectorVariant;
|
|
196
|
+
isLoading: boolean;
|
|
197
197
|
modelValue: readonly (string | number)[];
|
|
198
198
|
statusVariant: MultiSelectorStatusVariant;
|
|
199
199
|
presentation: MultiSelectorPresentation;
|
|
@@ -535,18 +535,18 @@ type __VLS_Slots$11 = ChatComposerSlots;
|
|
|
535
535
|
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
|
+
change: (value: string) => any;
|
|
538
539
|
submit: (value: string) => any;
|
|
539
540
|
stop: () => any;
|
|
540
|
-
change: (value: string) => any;
|
|
541
541
|
"update:modelValue": (value: string) => any;
|
|
542
542
|
}, string, import("vue").PublicProps, Readonly<ChatComposerProps> & Readonly<{
|
|
543
|
+
onChange?: ((value: string) => any) | undefined;
|
|
543
544
|
onSubmit?: ((value: string) => any) | undefined;
|
|
544
545
|
onStop?: (() => any) | undefined;
|
|
545
|
-
onChange?: ((value: string) => any) | undefined;
|
|
546
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>;
|
|
@@ -583,14 +583,14 @@ type __VLS_WithSlots$10<T, S> = T & {
|
|
|
583
583
|
//#endregion
|
|
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
|
-
submit: (value: string) => any;
|
|
587
586
|
change: (value: string) => any;
|
|
587
|
+
submit: (value: string) => any;
|
|
588
588
|
keydown: (event: KeyboardEvent) => any;
|
|
589
589
|
"update:modelValue": (value: string) => any;
|
|
590
590
|
files: (files: File[]) => any;
|
|
591
591
|
}, string, import("vue").PublicProps, Readonly<ChatComposerInputProps> & Readonly<{
|
|
592
|
-
onSubmit?: ((value: string) => any) | undefined;
|
|
593
592
|
onChange?: ((value: string) => any) | undefined;
|
|
593
|
+
onSubmit?: ((value: string) => any) | undefined;
|
|
594
594
|
onKeydown?: ((event: KeyboardEvent) => any) | undefined;
|
|
595
595
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
596
596
|
onFiles?: ((files: File[]) => any) | undefined;
|
|
@@ -111,8 +111,8 @@ type __VLS_Slots = CardSlots;
|
|
|
111
111
|
declare const __VLS_base: import("vue").DefineComponent<CardProps, {
|
|
112
112
|
element: Readonly<import("vue").ShallowRef<HTMLDivElement | null>>;
|
|
113
113
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CardProps> & Readonly<{}>, {
|
|
114
|
-
elevation: CardElevation;
|
|
115
114
|
variant: keyof CardVariantMap;
|
|
115
|
+
elevation: CardElevation;
|
|
116
116
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
117
117
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
118
118
|
declare const _default: typeof __VLS_export;
|
|
@@ -9,13 +9,13 @@ declare const __VLS_base: import("vue").DefineComponent<ButtonProps, {
|
|
|
9
9
|
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
10
10
|
}>, {
|
|
11
11
|
type: "button" | "reset" | "submit";
|
|
12
|
-
elevation: ButtonElevation;
|
|
13
12
|
isDisabled: boolean;
|
|
13
|
+
variant: ButtonVariant;
|
|
14
|
+
elevation: ButtonElevation;
|
|
14
15
|
isLoading: boolean;
|
|
15
16
|
isIconOnly: boolean;
|
|
16
17
|
isInterruptible: boolean;
|
|
17
18
|
loadingLabel: string;
|
|
18
|
-
variant: ButtonVariant;
|
|
19
19
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
20
20
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
21
21
|
declare const _default: typeof __VLS_export;
|
|
@@ -89,11 +89,11 @@ declare const __VLS_base: import("vue").DefineComponent<HoverCardProps, {
|
|
|
89
89
|
placement: HoverCardPlacement;
|
|
90
90
|
alignment: HoverCardAlignment;
|
|
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;
|
|
@@ -161,24 +161,24 @@ interface SelectorSlots {
|
|
|
161
161
|
type __VLS_Slots = SelectorSlots;
|
|
162
162
|
declare const __VLS_base: import("vue").DefineComponent<SelectorProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
163
163
|
search: (query: string) => any;
|
|
164
|
+
change: (value: string | number | null) => any;
|
|
164
165
|
click: (event: MouseEvent) => any;
|
|
165
166
|
focus: (event: FocusEvent) => any;
|
|
166
|
-
change: (value: string | number | null) => any;
|
|
167
167
|
keydown: (event: KeyboardEvent) => any;
|
|
168
168
|
"update:modelValue": (value: string | number | null) => any;
|
|
169
169
|
}, string, import("vue").PublicProps, Readonly<SelectorProps> & Readonly<{
|
|
170
170
|
onSearch?: ((query: string) => any) | undefined;
|
|
171
|
+
onChange?: ((value: string | number | null) => any) | undefined;
|
|
171
172
|
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
172
173
|
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
173
|
-
onChange?: ((value: string | number | null) => any) | undefined;
|
|
174
174
|
onKeydown?: ((event: KeyboardEvent) => any) | undefined;
|
|
175
175
|
"onUpdate:modelValue"?: ((value: string | number | null) => any) | undefined;
|
|
176
176
|
}>, {
|
|
177
|
-
isLoading: boolean;
|
|
178
|
-
variant: SelectorVariant;
|
|
179
177
|
status: SelectorStatusInput;
|
|
180
178
|
isOptional: boolean;
|
|
181
179
|
indicatorPosition: SelectorIndicatorPosition;
|
|
180
|
+
variant: SelectorVariant;
|
|
181
|
+
isLoading: boolean;
|
|
182
182
|
modelValue: string | number | null;
|
|
183
183
|
isLabelHidden: boolean;
|
|
184
184
|
isRequired: boolean;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { r as AnimatedLayout } from "./useAnimatedLayout-C0koWm4a.js";
|
|
1
2
|
import { CSSProperties, Component, Ref, VNode, VNodeChild } from "vue";
|
|
2
3
|
//#region src/TreeList/types.d.ts
|
|
3
4
|
type TreeListDensity = 'compact' | 'balanced' | 'spacious';
|
|
@@ -36,6 +37,12 @@ interface TreeListItemData {
|
|
|
36
37
|
}
|
|
37
38
|
interface TreeListProps {
|
|
38
39
|
items: TreeListItemData[];
|
|
40
|
+
/**
|
|
41
|
+
* The handle from `useAnimatedLayout({ containerRef })`. With it, expanding
|
|
42
|
+
* or collapsing a row glides the rows and content after it, up to that
|
|
43
|
+
* container, instead of jumping, and the chevron turns on the same timing.
|
|
44
|
+
*/
|
|
45
|
+
animatedLayout?: AnimatedLayout;
|
|
39
46
|
/** @default 'balanced' */
|
|
40
47
|
density?: TreeListDensity;
|
|
41
48
|
/** @default 'lineGuides' */
|
|
@@ -56,8 +63,8 @@ interface TreeListSlots {
|
|
|
56
63
|
//#region src/TreeList/TreeList.vue.d.ts
|
|
57
64
|
type __VLS_Slots = TreeListSlots;
|
|
58
65
|
declare const __VLS_base: import("vue").DefineComponent<TreeListProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TreeListProps> & Readonly<{}>, {
|
|
59
|
-
variant: TreeListVariant;
|
|
60
66
|
density: TreeListDensity;
|
|
67
|
+
variant: TreeListVariant;
|
|
61
68
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
62
69
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
63
70
|
declare const _default: typeof __VLS_export;
|