@foldkit/ui 0.135.0 → 0.137.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/anchor.d.ts +7 -1
- package/dist/anchor.d.ts.map +1 -1
- package/dist/anchor.js +77 -26
- package/dist/animation/index.d.ts +5 -5
- package/dist/animation/index.d.ts.map +1 -1
- package/dist/animation/index.js +4 -4
- package/dist/animation/public.d.ts +1 -1
- package/dist/animation/public.d.ts.map +1 -1
- package/dist/animation/public.js +1 -1
- package/dist/animation/schema.d.ts +2 -2
- package/dist/animation/schema.d.ts.map +1 -1
- package/dist/animation/schema.js +2 -2
- package/dist/animation/update.d.ts +3 -3
- package/dist/animation/update.d.ts.map +1 -1
- package/dist/animation/update.js +17 -10
- package/dist/calendar/index.d.ts.map +1 -1
- package/dist/calendar/index.js +41 -37
- package/dist/combobox/multi.d.ts +1 -1
- package/dist/combobox/shared.d.ts +4 -3
- package/dist/combobox/shared.d.ts.map +1 -1
- package/dist/combobox/shared.js +85 -55
- package/dist/combobox/single.d.ts +1 -1
- package/dist/datePicker/index.d.ts +2 -2
- package/dist/dialog/index.d.ts +2 -2
- package/dist/dialog/index.d.ts.map +1 -1
- package/dist/dialog/index.js +23 -11
- package/dist/dragAndDrop/index.d.ts +7 -7
- package/dist/dragAndDrop/index.d.ts.map +1 -1
- package/dist/dragAndDrop/index.js +73 -64
- package/dist/dragAndDrop/public.d.ts +1 -1
- package/dist/dragAndDrop/public.d.ts.map +1 -1
- package/dist/dragAndDrop/public.js +1 -1
- package/dist/internal/selectors.d.ts +10 -0
- package/dist/internal/selectors.d.ts.map +1 -1
- package/dist/internal/selectors.js +10 -0
- package/dist/listbox/multi.d.ts +2 -2
- package/dist/listbox/public.d.ts +1 -1
- package/dist/listbox/public.d.ts.map +1 -1
- package/dist/listbox/public.js +1 -1
- package/dist/listbox/shared.d.ts +9 -8
- package/dist/listbox/shared.d.ts.map +1 -1
- package/dist/listbox/shared.js +91 -51
- package/dist/listbox/single.d.ts +2 -2
- package/dist/menu/index.d.ts +7 -6
- package/dist/menu/index.d.ts.map +1 -1
- package/dist/menu/index.js +86 -46
- package/dist/menu/public.d.ts +1 -1
- package/dist/menu/public.d.ts.map +1 -1
- package/dist/menu/public.js +1 -1
- package/dist/popover/index.d.ts +4 -3
- package/dist/popover/index.d.ts.map +1 -1
- package/dist/popover/index.js +48 -22
- package/dist/slider/index.d.ts.map +1 -1
- package/dist/slider/index.js +2 -1
- package/dist/tabs/index.d.ts.map +1 -1
- package/dist/tabs/index.js +16 -12
- package/dist/test/apps/disabledButton.d.ts +2 -2
- package/dist/toast/index.d.ts +19 -18
- package/dist/toast/index.d.ts.map +1 -1
- package/dist/toast/index.js +5 -4
- package/dist/toast/public.d.ts +1 -1
- package/dist/toast/public.d.ts.map +1 -1
- package/dist/toast/public.js +1 -1
- package/dist/toast/schema.d.ts +5 -5
- package/dist/toast/schema.d.ts.map +1 -1
- package/dist/toast/schema.js +2 -2
- package/dist/toast/test.d.ts +6 -5
- package/dist/toast/test.d.ts.map +1 -1
- package/dist/toast/test.js +8 -7
- package/dist/toast/update.d.ts +14 -14
- package/dist/toast/update.d.ts.map +1 -1
- package/dist/toast/update.js +26 -22
- package/dist/tooltip/index.d.ts +2 -177
- package/dist/tooltip/index.d.ts.map +1 -1
- package/dist/tooltip/index.js +2 -256
- package/dist/tooltip/message.d.ts +53 -0
- package/dist/tooltip/message.d.ts.map +1 -0
- package/dist/tooltip/message.js +45 -0
- package/dist/tooltip/public.d.ts +1 -1
- package/dist/tooltip/public.d.ts.map +1 -1
- package/dist/tooltip/public.js +1 -1
- package/dist/tooltip/tooltip.d.ts +130 -0
- package/dist/tooltip/tooltip.d.ts.map +1 -0
- package/dist/tooltip/tooltip.js +226 -0
- package/dist/virtualList/index.d.ts.map +1 -1
- package/dist/virtualList/index.js +22 -18
- package/package.json +2 -2
package/dist/listbox/shared.js
CHANGED
|
@@ -81,7 +81,9 @@ export const Searched = m('Searched', {
|
|
|
81
81
|
maybeTargetIndex: S.Option(S.Number),
|
|
82
82
|
});
|
|
83
83
|
/** Sent after the search debounce period to clear the accumulated query. */
|
|
84
|
-
export const
|
|
84
|
+
export const CompletedDelayClearSearch = m('CompletedDelayClearSearch', {
|
|
85
|
+
version: S.Number,
|
|
86
|
+
});
|
|
85
87
|
/** Sent when the pointer moves over a listbox item, carrying screen coordinates for tracked-pointer comparison. */
|
|
86
88
|
export const MovedPointerOverItem = m('MovedPointerOverItem', {
|
|
87
89
|
index: S.Number,
|
|
@@ -132,7 +134,7 @@ export const Message = S.Union([
|
|
|
132
134
|
MovedPointerOverItem,
|
|
133
135
|
RequestedItemClick,
|
|
134
136
|
Searched,
|
|
135
|
-
|
|
137
|
+
CompletedDelayClearSearch,
|
|
136
138
|
CompletedLockScroll,
|
|
137
139
|
CompletedUnlockScroll,
|
|
138
140
|
CompletedInertOthers,
|
|
@@ -180,30 +182,68 @@ export const closedModel = (model) => __foldkitBrandViewResult((constrainedEvo(m
|
|
|
180
182
|
maybeLastButtonPointerType: () => __foldkitBrandViewResult((Option.none()), "@foldkit/ui/listbox/shared.js#maybeLastButtonPointerType"),
|
|
181
183
|
})), "@foldkit/ui/listbox/shared.js#closedModel");
|
|
182
184
|
/** Prevents page scrolling while the listbox is open in modal mode. */
|
|
183
|
-
export const LockScroll = Command.define('LockScroll',
|
|
185
|
+
export const LockScroll = Command.define('LockScroll', {
|
|
186
|
+
messages: [CompletedLockScroll],
|
|
187
|
+
execute: Dom.lockScroll.pipe(Effect.as(CompletedLockScroll())),
|
|
188
|
+
});
|
|
184
189
|
/** Re-enables page scrolling after the listbox closes. */
|
|
185
|
-
export const UnlockScroll = Command.define('UnlockScroll',
|
|
190
|
+
export const UnlockScroll = Command.define('UnlockScroll', {
|
|
191
|
+
messages: [CompletedUnlockScroll],
|
|
192
|
+
execute: Dom.unlockScroll.pipe(Effect.as(CompletedUnlockScroll())),
|
|
193
|
+
});
|
|
186
194
|
/** Marks all elements outside the listbox as inert for modal behavior. */
|
|
187
|
-
export const InertOthers = Command.define('InertOthers', {
|
|
195
|
+
export const InertOthers = Command.define('InertOthers', {
|
|
196
|
+
args: { id: S.String },
|
|
197
|
+
messages: [CompletedInertOthers],
|
|
198
|
+
execute: ({ id }) => __foldkitBrandViewResult((Dom.inertOthers(id, [buttonSelector(id), itemsSelector(id)]).pipe(Effect.as(CompletedInertOthers()))), "@foldkit/ui/listbox/shared.js#execute"),
|
|
199
|
+
});
|
|
188
200
|
/** Removes the inert attribute from elements outside the listbox. */
|
|
189
|
-
export const RestoreInert = Command.define('RestoreInert', {
|
|
201
|
+
export const RestoreInert = Command.define('RestoreInert', {
|
|
202
|
+
args: { id: S.String },
|
|
203
|
+
messages: [CompletedRestoreInert],
|
|
204
|
+
execute: ({ id }) => __foldkitBrandViewResult((Dom.restoreInert(id).pipe(Effect.as(CompletedRestoreInert()))), "@foldkit/ui/listbox/shared.js#execute~2"),
|
|
205
|
+
});
|
|
190
206
|
/** Moves focus back to the listbox button after closing. */
|
|
191
|
-
export const FocusButton = Command.define('FocusButton', {
|
|
207
|
+
export const FocusButton = Command.define('FocusButton', {
|
|
208
|
+
args: { id: S.String },
|
|
209
|
+
messages: [CompletedFocusButton],
|
|
210
|
+
execute: ({ id }) => __foldkitBrandViewResult((Dom.focus(buttonSelector(id)).pipe(Effect.ignore, Effect.as(CompletedFocusButton()))), "@foldkit/ui/listbox/shared.js#execute~3"),
|
|
211
|
+
});
|
|
192
212
|
/** Moves focus to the listbox items container after opening. */
|
|
193
|
-
export const FocusItems = Command.define('FocusItems', {
|
|
213
|
+
export const FocusItems = Command.define('FocusItems', {
|
|
214
|
+
args: { id: S.String },
|
|
215
|
+
messages: [CompletedFocusItems],
|
|
216
|
+
execute: ({ id }) => __foldkitBrandViewResult((Dom.focus(itemsSelector(id)).pipe(Effect.ignore, Effect.as(CompletedFocusItems()))), "@foldkit/ui/listbox/shared.js#execute~4"),
|
|
217
|
+
});
|
|
194
218
|
/** Scrolls the active listbox item into view after keyboard navigation. */
|
|
195
|
-
export const ScrollIntoView = Command.define('ScrollIntoView', {
|
|
219
|
+
export const ScrollIntoView = Command.define('ScrollIntoView', {
|
|
220
|
+
args: { id: S.String, index: S.Number },
|
|
221
|
+
messages: [CompletedScrollIntoView],
|
|
222
|
+
execute: ({ id, index }) => __foldkitBrandViewResult((Dom.scrollIntoView(itemSelector(id, index)).pipe(Effect.ignore, Effect.as(CompletedScrollIntoView()))), "@foldkit/ui/listbox/shared.js#execute~5"),
|
|
223
|
+
});
|
|
196
224
|
/** Programmatically clicks the active listbox item's DOM element. */
|
|
197
|
-
export const ClickItem = Command.define('ClickItem', {
|
|
225
|
+
export const ClickItem = Command.define('ClickItem', {
|
|
226
|
+
args: { id: S.String, index: S.Number },
|
|
227
|
+
messages: [CompletedClickItem],
|
|
228
|
+
execute: ({ id, index }) => __foldkitBrandViewResult((Dom.clickElement(itemSelector(id, index)).pipe(Effect.ignore, Effect.as(CompletedClickItem()))), "@foldkit/ui/listbox/shared.js#execute~6"),
|
|
229
|
+
});
|
|
198
230
|
/** Waits for the typeahead search debounce period before clearing the query. */
|
|
199
|
-
export const DelayClearSearch = Command.define('DelayClearSearch', {
|
|
231
|
+
export const DelayClearSearch = Command.define('DelayClearSearch', {
|
|
232
|
+
args: { version: S.Number },
|
|
233
|
+
messages: [CompletedDelayClearSearch],
|
|
234
|
+
execute: ({ version }) => __foldkitBrandViewResult((Effect.sleep(SEARCH_DEBOUNCE_MILLISECONDS).pipe(Effect.as(CompletedDelayClearSearch({ version })))), "@foldkit/ui/listbox/shared.js#execute~7"),
|
|
235
|
+
});
|
|
200
236
|
/** Detects whether the listbox button moved or the leave animation ended. Whichever comes first; both outcomes signal the Animation submodel that leave is complete. */
|
|
201
|
-
export const DetectMovementOrAnimationEnd = Command.define('DetectMovementOrAnimationEnd', {
|
|
237
|
+
export const DetectMovementOrAnimationEnd = Command.define('DetectMovementOrAnimationEnd', {
|
|
238
|
+
args: { id: S.String },
|
|
239
|
+
messages: [GotAnimationMessage],
|
|
240
|
+
execute: ({ id }) => __foldkitBrandViewResult((Effect.raceFirst(Dom.detectElementMovement(buttonSelector(id)).pipe(Effect.as(GotAnimationMessage({ message: AnimationEndedAnimation() }))), Dom.waitForAnimationSettled(itemsSelector(id)).pipe(Effect.as(GotAnimationMessage({ message: AnimationEndedAnimation() }))))), "@foldkit/ui/listbox/shared.js#execute~8"),
|
|
241
|
+
});
|
|
202
242
|
export const makeUpdate = (handleSelectedItem) => {
|
|
203
243
|
const withUpdateReturn = M.withReturnType();
|
|
204
244
|
const delegateToAnimation = (model, animationMessage) => {
|
|
205
245
|
const [nextAnimation, animationCommands, maybeOutMessage] = animationUpdate(model.animation, animationMessage);
|
|
206
|
-
const mappedCommands = Command.mapMessages(animationCommands, message => __foldkitBrandViewResult((GotAnimationMessage({ message })), "@foldkit/ui/listbox/shared.js#anonymous
|
|
246
|
+
const mappedCommands = Command.mapMessages(animationCommands, message => __foldkitBrandViewResult((GotAnimationMessage({ message })), "@foldkit/ui/listbox/shared.js#anonymous"));
|
|
207
247
|
const additionalCommands = Option.match(maybeOutMessage, {
|
|
208
248
|
onNone: () => __foldkitBrandViewResult(([]), "@foldkit/ui/listbox/shared.js#onNone"),
|
|
209
249
|
onSome: M.type().pipe(M.tagsExhaustive({
|
|
@@ -261,7 +301,7 @@ export const makeUpdate = (handleSelectedItem) => {
|
|
|
261
301
|
maybeUnlockScroll,
|
|
262
302
|
maybeRestoreInert,
|
|
263
303
|
]);
|
|
264
|
-
return __foldkitBrandViewResult((M.value(message).pipe(withUpdateReturn, M.tag('CompletedLockScroll', 'CompletedUnlockScroll', 'CompletedInertOthers', 'CompletedRestoreInert', 'CompletedFocusButton', 'CompletedFocusItems', 'CompletedScrollIntoView', 'CompletedClickItem', 'SuppressedSpaceScroll', 'CompletedAnchorListbox', 'CompletedPortalListboxBackdrop', () => __foldkitBrandViewResult(([model, [], Option.none()]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
304
|
+
return __foldkitBrandViewResult((M.value(message).pipe(withUpdateReturn, M.tag('CompletedLockScroll', 'CompletedUnlockScroll', 'CompletedInertOthers', 'CompletedRestoreInert', 'CompletedFocusButton', 'CompletedFocusItems', 'CompletedScrollIntoView', 'CompletedClickItem', 'SuppressedSpaceScroll', 'CompletedAnchorListbox', 'CompletedPortalListboxBackdrop', () => __foldkitBrandViewResult(([model, [], Option.none()]), "@foldkit/ui/listbox/shared.js#anonymous~2")), M.tagsExhaustive({
|
|
265
305
|
Opened: ({ maybeActiveItemIndex }) => __foldkitBrandViewResult((openListbox(constrainedEvo(model, {
|
|
266
306
|
maybeActiveItemIndex: () => __foldkitBrandViewResult((maybeActiveItemIndex), "@foldkit/ui/listbox/shared.js#maybeActiveItemIndex~2"),
|
|
267
307
|
activationTrigger: () => __foldkitBrandViewResult((Option.match(maybeActiveItemIndex, {
|
|
@@ -290,7 +330,7 @@ export const makeUpdate = (handleSelectedItem) => {
|
|
|
290
330
|
Option.none(),
|
|
291
331
|
]), "@foldkit/ui/listbox/shared.js#ActivatedItem"),
|
|
292
332
|
MovedPointerOverItem: ({ index, screenX, screenY }) => {
|
|
293
|
-
const isSamePosition = Option.exists(model.maybeLastPointerPosition, position => __foldkitBrandViewResult((position.screenX === screenX && position.screenY === screenY), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
333
|
+
const isSamePosition = Option.exists(model.maybeLastPointerPosition, position => __foldkitBrandViewResult((position.screenX === screenX && position.screenY === screenY), "@foldkit/ui/listbox/shared.js#anonymous~3"));
|
|
294
334
|
if (isSamePosition) {
|
|
295
335
|
return __foldkitBrandViewResult(([model, [], Option.none()]), "@foldkit/ui/listbox/shared.js#MovedPointerOverItem");
|
|
296
336
|
}
|
|
@@ -329,21 +369,21 @@ export const makeUpdate = (handleSelectedItem) => {
|
|
|
329
369
|
constrainedEvo(model, {
|
|
330
370
|
searchQuery: () => __foldkitBrandViewResult((nextSearchQuery), "@foldkit/ui/listbox/shared.js#searchQuery~3"),
|
|
331
371
|
searchVersion: () => __foldkitBrandViewResult((nextSearchVersion), "@foldkit/ui/listbox/shared.js#searchVersion~3"),
|
|
332
|
-
maybeActiveItemIndex: () => __foldkitBrandViewResult((Option.orElse(maybeTargetIndex, () => __foldkitBrandViewResult((model.maybeActiveItemIndex), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
372
|
+
maybeActiveItemIndex: () => __foldkitBrandViewResult((Option.orElse(maybeTargetIndex, () => __foldkitBrandViewResult((model.maybeActiveItemIndex), "@foldkit/ui/listbox/shared.js#anonymous~4"))), "@foldkit/ui/listbox/shared.js#maybeActiveItemIndex~6"),
|
|
333
373
|
}),
|
|
334
374
|
[DelayClearSearch({ version: nextSearchVersion })],
|
|
335
375
|
Option.none(),
|
|
336
376
|
]), "@foldkit/ui/listbox/shared.js#Searched");
|
|
337
377
|
},
|
|
338
|
-
|
|
378
|
+
CompletedDelayClearSearch: ({ version }) => {
|
|
339
379
|
if (version !== model.searchVersion) {
|
|
340
|
-
return __foldkitBrandViewResult(([model, [], Option.none()]), "@foldkit/ui/listbox/shared.js#
|
|
380
|
+
return __foldkitBrandViewResult(([model, [], Option.none()]), "@foldkit/ui/listbox/shared.js#CompletedDelayClearSearch");
|
|
341
381
|
}
|
|
342
382
|
return __foldkitBrandViewResult(([
|
|
343
383
|
constrainedEvo(model, { searchQuery: () => __foldkitBrandViewResult((''), "@foldkit/ui/listbox/shared.js#searchQuery~4") }),
|
|
344
384
|
[],
|
|
345
385
|
Option.none(),
|
|
346
|
-
]), "@foldkit/ui/listbox/shared.js#
|
|
386
|
+
]), "@foldkit/ui/listbox/shared.js#CompletedDelayClearSearch");
|
|
347
387
|
},
|
|
348
388
|
GotAnimationMessage: ({ message: animationMessage }) => __foldkitBrandViewResult((delegateToAnimation(model, animationMessage)), "@foldkit/ui/listbox/shared.js#GotAnimationMessage"),
|
|
349
389
|
PressedPointerOnButton: ({ pointerType, button }) => {
|
|
@@ -389,42 +429,42 @@ export const makeUpdate = (handleSelectedItem) => {
|
|
|
389
429
|
* so Scene tests can call
|
|
390
430
|
* `Scene.Mount.resolve(AnchorListbox, CompletedAnchorListbox())`. */
|
|
391
431
|
export const AnchorListbox = Mount.define('AnchorListbox', { buttonId: S.String, anchor: AnchorConfig }, CompletedAnchorListbox)(({ buttonId, anchor }) => __foldkitBrandViewResult((element => __foldkitBrandViewResult((Effect.gen(function* () {
|
|
392
|
-
yield* Effect.acquireRelease(Effect.sync(() => __foldkitBrandViewResult((anchorSetup({ buttonId, anchor })(element)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
393
|
-
return __foldkitBrandViewResult((CompletedAnchorListbox()), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
394
|
-
})), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
432
|
+
yield* Effect.acquireRelease(Effect.sync(() => __foldkitBrandViewResult((anchorSetup({ buttonId, anchor })(element)), "@foldkit/ui/listbox/shared.js#anonymous~8")), cleanup => __foldkitBrandViewResult((Effect.sync(cleanup)), "@foldkit/ui/listbox/shared.js#anonymous~9"));
|
|
433
|
+
return __foldkitBrandViewResult((CompletedAnchorListbox()), "@foldkit/ui/listbox/shared.js#anonymous~7");
|
|
434
|
+
})), "@foldkit/ui/listbox/shared.js#anonymous~6")), "@foldkit/ui/listbox/shared.js#anonymous~5"));
|
|
395
435
|
/** The backdrop-portaling Mount this Listbox renders. Exposed so Scene tests can
|
|
396
436
|
* call `Scene.Mount.resolve(PortalListboxBackdrop, CompletedPortalListboxBackdrop())` to
|
|
397
437
|
* acknowledge the mount produced by the rendered backdrop. */
|
|
398
438
|
export const PortalListboxBackdrop = Mount.define('PortalListboxBackdrop', CompletedPortalListboxBackdrop)(element => __foldkitBrandViewResult((Effect.gen(function* () {
|
|
399
|
-
yield* Effect.acquireRelease(Effect.sync(() => __foldkitBrandViewResult((portalToContainingRoot(element)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
400
|
-
return __foldkitBrandViewResult((CompletedPortalListboxBackdrop()), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
401
|
-
})), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
439
|
+
yield* Effect.acquireRelease(Effect.sync(() => __foldkitBrandViewResult((portalToContainingRoot(element)), "@foldkit/ui/listbox/shared.js#anonymous~12")), cleanup => __foldkitBrandViewResult((Effect.sync(cleanup)), "@foldkit/ui/listbox/shared.js#anonymous~13"));
|
|
440
|
+
return __foldkitBrandViewResult((CompletedPortalListboxBackdrop()), "@foldkit/ui/listbox/shared.js#anonymous~11");
|
|
441
|
+
})), "@foldkit/ui/listbox/shared.js#anonymous~10"));
|
|
402
442
|
export const makeView = (behavior) => {
|
|
403
443
|
const impl = defineView((model, viewInputs, h) => {
|
|
404
444
|
const { id, isOpen, orientation, animation: { transitionState }, maybeActiveItemIndex, searchQuery, maybeLastButtonPointerType, } = model;
|
|
405
445
|
const { items, itemToConfig, isItemDisabled, isButtonDisabled, buttonContent, buttonClassName, buttonAttributes = [], itemsClassName, itemsAttributes = [], itemsScrollClassName, itemsScrollAttributes = [], backdropClassName, backdropAttributes = [], className, attributes = [], itemGroupKey, groupToHeading, groupClassName, groupAttributes = [], separatorClassName, separatorAttributes = [], anchor = {}, name, form, isDisabled, isInvalid, ariaLabel, ariaLabelledBy, selectedValues, } = viewInputs;
|
|
406
|
-
const itemToValue = viewInputs.itemToValue ?? ((item) => __foldkitBrandViewResult((String(item)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
446
|
+
const itemToValue = viewInputs.itemToValue ?? ((item) => __foldkitBrandViewResult((String(item)), "@foldkit/ui/listbox/shared.js#anonymous~15"));
|
|
407
447
|
const isValueSelected = (itemValue) => __foldkitBrandViewResult((Array.contains(selectedValues, itemValue)), "@foldkit/ui/listbox/shared.js#isValueSelected");
|
|
408
|
-
const itemToSearchText = viewInputs.itemToSearchText ?? ((item) => __foldkitBrandViewResult((itemToValue(item)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
448
|
+
const itemToSearchText = viewInputs.itemToSearchText ?? ((item) => __foldkitBrandViewResult((itemToValue(item)), "@foldkit/ui/listbox/shared.js#anonymous~16"));
|
|
409
449
|
const isLeaving = transitionState === 'LeaveStart' || transitionState === 'LeaveAnimating';
|
|
410
450
|
const isVisible = isOpen || isLeaving;
|
|
411
451
|
const animationAttributes = M.value(transitionState).pipe(M.when('EnterStart', () => __foldkitBrandViewResult(([
|
|
412
452
|
h.DataAttribute('closed', ''),
|
|
413
453
|
h.DataAttribute('enter', ''),
|
|
414
454
|
h.DataAttribute('transition', ''),
|
|
415
|
-
]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
455
|
+
]), "@foldkit/ui/listbox/shared.js#anonymous~17")), M.when('EnterAnimating', () => __foldkitBrandViewResult(([
|
|
416
456
|
h.DataAttribute('enter', ''),
|
|
417
457
|
h.DataAttribute('transition', ''),
|
|
418
|
-
]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
458
|
+
]), "@foldkit/ui/listbox/shared.js#anonymous~18")), M.when('LeaveStart', () => __foldkitBrandViewResult(([
|
|
419
459
|
h.DataAttribute('leave', ''),
|
|
420
460
|
h.DataAttribute('transition', ''),
|
|
421
|
-
]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
461
|
+
]), "@foldkit/ui/listbox/shared.js#anonymous~19")), M.when('LeaveAnimating', () => __foldkitBrandViewResult(([
|
|
422
462
|
h.DataAttribute('closed', ''),
|
|
423
463
|
h.DataAttribute('leave', ''),
|
|
424
464
|
h.DataAttribute('transition', ''),
|
|
425
|
-
]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
465
|
+
]), "@foldkit/ui/listbox/shared.js#anonymous~20")), M.orElse(() => __foldkitBrandViewResult(([]), "@foldkit/ui/listbox/shared.js#anonymous~21")));
|
|
426
466
|
const isItemDisabledByIndex = (index) => __foldkitBrandViewResult((Predicate.isNotUndefined(isItemDisabled) &&
|
|
427
|
-
pipe(items, Array.get(index), Option.exists(item => __foldkitBrandViewResult((isItemDisabled(item, index)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
467
|
+
pipe(items, Array.get(index), Option.exists(item => __foldkitBrandViewResult((isItemDisabled(item, index)), "@foldkit/ui/listbox/shared.js#anonymous~22")))), "@foldkit/ui/listbox/shared.js#isItemDisabledByIndex");
|
|
428
468
|
const isButtonEffectivelyDisabled = isDisabled || isButtonDisabled;
|
|
429
469
|
const nextKey = orientation === 'Horizontal' ? 'ArrowRight' : 'ArrowDown';
|
|
430
470
|
const previousKey = orientation === 'Horizontal' ? 'ArrowLeft' : 'ArrowUp';
|
|
@@ -439,20 +479,20 @@ export const makeView = (behavior) => {
|
|
|
439
479
|
const isNavigationKey = (key) => __foldkitBrandViewResult((Array.contains(navigationKeys, key)), "@foldkit/ui/listbox/shared.js#isNavigationKey");
|
|
440
480
|
const firstEnabledIndex = findFirstEnabledIndex(items.length, 0, isItemDisabledByIndex)(0, 1);
|
|
441
481
|
const lastEnabledIndex = findFirstEnabledIndex(items.length, 0, isItemDisabledByIndex)(items.length - 1, -1);
|
|
442
|
-
const selectedItemIndex = pipe(selectedValues, Array.head, Option.flatMap(selectedValue => __foldkitBrandViewResult((Array.findFirstIndex(items, item => __foldkitBrandViewResult((itemToValue(item) === selectedValue), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
482
|
+
const selectedItemIndex = pipe(selectedValues, Array.head, Option.flatMap(selectedValue => __foldkitBrandViewResult((Array.findFirstIndex(items, item => __foldkitBrandViewResult((itemToValue(item) === selectedValue), "@foldkit/ui/listbox/shared.js#anonymous~24"))), "@foldkit/ui/listbox/shared.js#anonymous~23")));
|
|
443
483
|
const handleButtonKeyDown = (key) => {
|
|
444
484
|
if (isOpen) {
|
|
445
485
|
return __foldkitBrandViewResult((handleItemsKeyDown(key)), "@foldkit/ui/listbox/shared.js#handleButtonKeyDown");
|
|
446
486
|
}
|
|
447
487
|
return __foldkitBrandViewResult((M.value(key).pipe(M.whenOr('Enter', ' ', 'ArrowDown', () => __foldkitBrandViewResult((Option.some(Opened({
|
|
448
|
-
maybeActiveItemIndex: Option.orElse(selectedItemIndex, () => __foldkitBrandViewResult((Option.some(firstEnabledIndex)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
449
|
-
}))), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
450
|
-
maybeActiveItemIndex: Option.orElse(selectedItemIndex, () => __foldkitBrandViewResult((Option.some(lastEnabledIndex)), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
451
|
-
}))), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
488
|
+
maybeActiveItemIndex: Option.orElse(selectedItemIndex, () => __foldkitBrandViewResult((Option.some(firstEnabledIndex)), "@foldkit/ui/listbox/shared.js#anonymous~26")),
|
|
489
|
+
}))), "@foldkit/ui/listbox/shared.js#anonymous~25")), M.when('ArrowUp', () => __foldkitBrandViewResult((Option.some(Opened({
|
|
490
|
+
maybeActiveItemIndex: Option.orElse(selectedItemIndex, () => __foldkitBrandViewResult((Option.some(lastEnabledIndex)), "@foldkit/ui/listbox/shared.js#anonymous~28")),
|
|
491
|
+
}))), "@foldkit/ui/listbox/shared.js#anonymous~27")), M.orElse(() => __foldkitBrandViewResult((Option.none()), "@foldkit/ui/listbox/shared.js#anonymous~29")))), "@foldkit/ui/listbox/shared.js#handleButtonKeyDown");
|
|
452
492
|
};
|
|
453
493
|
const handleButtonPointerDown = (pointerType, button) => __foldkitBrandViewResult((Option.some(PressedPointerOnButton({ pointerType, button }))), "@foldkit/ui/listbox/shared.js#handleButtonPointerDown");
|
|
454
494
|
const handleButtonClick = () => {
|
|
455
|
-
const isMouse = Option.exists(maybeLastButtonPointerType, type => __foldkitBrandViewResult((type === 'mouse'), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
495
|
+
const isMouse = Option.exists(maybeLastButtonPointerType, type => __foldkitBrandViewResult((type === 'mouse'), "@foldkit/ui/listbox/shared.js#anonymous~30"));
|
|
456
496
|
if (isMouse) {
|
|
457
497
|
return __foldkitBrandViewResult((IgnoredMouseClick()), "@foldkit/ui/listbox/shared.js#handleButtonClick");
|
|
458
498
|
}
|
|
@@ -465,7 +505,7 @@ export const makeView = (behavior) => {
|
|
|
465
505
|
};
|
|
466
506
|
const handleSpaceKeyUp = (key) => __foldkitBrandViewResult((OptionExt.when(key === ' ', SuppressedSpaceScroll())), "@foldkit/ui/listbox/shared.js#handleSpaceKeyUp");
|
|
467
507
|
const resolveActiveIndex = (key) => __foldkitBrandViewResult((Option.match(maybeActiveItemIndex, {
|
|
468
|
-
onNone: () => __foldkitBrandViewResult((M.value(key).pipe(M.whenOr(previousKey, 'End', 'PageDown', () => __foldkitBrandViewResult((lastEnabledIndex), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
508
|
+
onNone: () => __foldkitBrandViewResult((M.value(key).pipe(M.whenOr(previousKey, 'End', 'PageDown', () => __foldkitBrandViewResult((lastEnabledIndex), "@foldkit/ui/listbox/shared.js#anonymous~31")), M.orElse(() => __foldkitBrandViewResult((firstEnabledIndex), "@foldkit/ui/listbox/shared.js#anonymous~32")))), "@foldkit/ui/listbox/shared.js#onNone~3"),
|
|
469
509
|
onSome: activeIndex => __foldkitBrandViewResult((keyToIndex(nextKey, previousKey, items.length, activeIndex, isItemDisabledByIndex)(key)), "@foldkit/ui/listbox/shared.js#onSome~2"),
|
|
470
510
|
})), "@foldkit/ui/listbox/shared.js#resolveActiveIndex");
|
|
471
511
|
const searchForKey = (key) => {
|
|
@@ -473,12 +513,12 @@ export const makeView = (behavior) => {
|
|
|
473
513
|
const maybeTargetIndex = resolveTypeaheadMatch(items, nextQuery, maybeActiveItemIndex, isItemDisabledByIndex, itemToSearchText, Str.isNonEmpty(searchQuery));
|
|
474
514
|
return __foldkitBrandViewResult((Option.some(Searched({ key, maybeTargetIndex }))), "@foldkit/ui/listbox/shared.js#searchForKey");
|
|
475
515
|
};
|
|
476
|
-
const handleItemsKeyDown = (key) => __foldkitBrandViewResult((M.value(key).pipe(M.when('Escape', () => __foldkitBrandViewResult((Option.some(Closed())), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
516
|
+
const handleItemsKeyDown = (key) => __foldkitBrandViewResult((M.value(key).pipe(M.when('Escape', () => __foldkitBrandViewResult((Option.some(Closed())), "@foldkit/ui/listbox/shared.js#anonymous~33")), M.when('Enter', () => __foldkitBrandViewResult((Option.map(maybeActiveItemIndex, index => __foldkitBrandViewResult((RequestedItemClick({ index })), "@foldkit/ui/listbox/shared.js#anonymous~35"))), "@foldkit/ui/listbox/shared.js#anonymous~34")), M.when(' ', () => __foldkitBrandViewResult((Str.isNonEmpty(searchQuery)
|
|
477
517
|
? searchForKey(' ')
|
|
478
|
-
: Option.map(maybeActiveItemIndex, index => __foldkitBrandViewResult((RequestedItemClick({ index })), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
518
|
+
: Option.map(maybeActiveItemIndex, index => __foldkitBrandViewResult((RequestedItemClick({ index })), "@foldkit/ui/listbox/shared.js#anonymous~37"))), "@foldkit/ui/listbox/shared.js#anonymous~36")), M.when(isNavigationKey, () => __foldkitBrandViewResult((Option.some(ActivatedItem({
|
|
479
519
|
index: resolveActiveIndex(key),
|
|
480
520
|
activationTrigger: 'Keyboard',
|
|
481
|
-
}))), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
521
|
+
}))), "@foldkit/ui/listbox/shared.js#anonymous~38")), M.when(isPrintableKey, () => __foldkitBrandViewResult((searchForKey(key)), "@foldkit/ui/listbox/shared.js#anonymous~39")), M.orElse(() => __foldkitBrandViewResult((Option.none()), "@foldkit/ui/listbox/shared.js#anonymous~40")))), "@foldkit/ui/listbox/shared.js#handleItemsKeyDown");
|
|
482
522
|
const resolveButtonLabel = () => {
|
|
483
523
|
if (Predicate.isNotUndefined(ariaLabel)) {
|
|
484
524
|
return __foldkitBrandViewResult(([h.AriaLabel(ariaLabel)]), "@foldkit/ui/listbox/shared.js#resolveButtonLabel");
|
|
@@ -549,7 +589,7 @@ export const makeView = (behavior) => {
|
|
|
549
589
|
...itemsAttributes,
|
|
550
590
|
];
|
|
551
591
|
const listboxItems = Array.map(items, (item, index) => {
|
|
552
|
-
const isActiveItem = Option.exists(maybeActiveItemIndex, activeIndex => __foldkitBrandViewResult((activeIndex === index), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
592
|
+
const isActiveItem = Option.exists(maybeActiveItemIndex, activeIndex => __foldkitBrandViewResult((activeIndex === index), "@foldkit/ui/listbox/shared.js#anonymous~42"));
|
|
553
593
|
const isDisabledItem = isItemDisabledByIndex(index);
|
|
554
594
|
const isSelectedItem = isValueSelected(itemToValue(item));
|
|
555
595
|
const itemConfig = itemToConfig(item, {
|
|
@@ -577,13 +617,13 @@ export const makeView = (behavior) => {
|
|
|
577
617
|
index,
|
|
578
618
|
screenX,
|
|
579
619
|
screenY,
|
|
580
|
-
}))), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
620
|
+
}))), "@foldkit/ui/listbox/shared.js#anonymous~43")),
|
|
581
621
|
]),
|
|
582
|
-
h.OnPointerLeave(pointerType => __foldkitBrandViewResult((OptionExt.when(pointerType !== 'touch', DeactivatedItem())), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
622
|
+
h.OnPointerLeave(pointerType => __foldkitBrandViewResult((OptionExt.when(pointerType !== 'touch', DeactivatedItem())), "@foldkit/ui/listbox/shared.js#anonymous~44")),
|
|
583
623
|
]
|
|
584
624
|
: []),
|
|
585
625
|
...(itemConfig.className ? [h.Class(itemConfig.className)] : []),
|
|
586
|
-
], [itemConfig.content])), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
626
|
+
], [itemConfig.content])), "@foldkit/ui/listbox/shared.js#anonymous~41");
|
|
587
627
|
});
|
|
588
628
|
const renderGroupedItems = () => {
|
|
589
629
|
if (!itemGroupKey) {
|
|
@@ -592,7 +632,7 @@ export const makeView = (behavior) => {
|
|
|
592
632
|
const segments = groupContiguous(listboxItems, (_, index) => __foldkitBrandViewResult((Array.get(items, index).pipe(Option.match({
|
|
593
633
|
onNone: () => __foldkitBrandViewResult((''), "@foldkit/ui/listbox/shared.js#onNone~5"),
|
|
594
634
|
onSome: item => __foldkitBrandViewResult((itemGroupKey(item, index)), "@foldkit/ui/listbox/shared.js#onSome~4"),
|
|
595
|
-
}))), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
635
|
+
}))), "@foldkit/ui/listbox/shared.js#anonymous~45"));
|
|
596
636
|
return __foldkitBrandViewResult((Array.flatMap(segments, (segment, segmentIndex) => {
|
|
597
637
|
const maybeHeading = Option.fromNullishOr(groupToHeading?.(segment.key));
|
|
598
638
|
const headingId = `${id}-heading-${segment.key}`;
|
|
@@ -628,7 +668,7 @@ export const makeView = (behavior) => {
|
|
|
628
668
|
], []),
|
|
629
669
|
]
|
|
630
670
|
: [];
|
|
631
|
-
return __foldkitBrandViewResult(([...separator, groupElement]), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
671
|
+
return __foldkitBrandViewResult(([...separator, groupElement]), "@foldkit/ui/listbox/shared.js#anonymous~46");
|
|
632
672
|
})), "@foldkit/ui/listbox/shared.js#renderGroupedItems");
|
|
633
673
|
};
|
|
634
674
|
const backdrop = h.keyed('div')(`${id}-backdrop`, [
|
|
@@ -664,7 +704,7 @@ export const makeView = (behavior) => {
|
|
|
664
704
|
h.Name(name),
|
|
665
705
|
h.Value(selectedValue),
|
|
666
706
|
...formAttribute,
|
|
667
|
-
])), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
707
|
+
])), "@foldkit/ui/listbox/shared.js#anonymous~47")),
|
|
668
708
|
})
|
|
669
709
|
: [];
|
|
670
710
|
const wrapperAttributes = [
|
|
@@ -680,9 +720,9 @@ export const makeView = (behavior) => {
|
|
|
680
720
|
]),
|
|
681
721
|
...hiddenInputs,
|
|
682
722
|
...(isVisible ? visibleContent : []),
|
|
683
|
-
])), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
723
|
+
])), "@foldkit/ui/listbox/shared.js#anonymous~14");
|
|
684
724
|
});
|
|
685
725
|
return __foldkitBrandViewResult((() =>
|
|
686
726
|
/* eslint-disable-next-line @typescript-eslint/consistent-type-assertions */
|
|
687
|
-
__foldkitBrandViewResult((impl), "@foldkit/ui/listbox/shared.js#anonymous~
|
|
727
|
+
__foldkitBrandViewResult((impl), "@foldkit/ui/listbox/shared.js#anonymous~48")), "@foldkit/ui/listbox/shared.js#makeView");
|
|
688
728
|
};
|
package/dist/listbox/single.d.ts
CHANGED
|
@@ -121,7 +121,7 @@ export declare const update: (model: {
|
|
|
121
121
|
readonly key: string;
|
|
122
122
|
readonly maybeTargetIndex: Option.Option<number>;
|
|
123
123
|
} | {
|
|
124
|
-
readonly _tag: "
|
|
124
|
+
readonly _tag: "CompletedDelayClearSearch";
|
|
125
125
|
readonly version: number;
|
|
126
126
|
} | {
|
|
127
127
|
readonly _tag: "PressedPointerOnButton";
|
|
@@ -140,7 +140,7 @@ export declare const update: (model: {
|
|
|
140
140
|
} | {
|
|
141
141
|
readonly _tag: "Hid";
|
|
142
142
|
} | {
|
|
143
|
-
readonly _tag: "
|
|
143
|
+
readonly _tag: "CompletedWaitForPaint";
|
|
144
144
|
} | {
|
|
145
145
|
readonly _tag: "EndedAnimation";
|
|
146
146
|
};
|
package/dist/menu/index.d.ts
CHANGED
|
@@ -66,7 +66,7 @@ export declare const Searched: import("foldkit/schema").CallableTaggedStruct<"Se
|
|
|
66
66
|
maybeTargetIndex: S.Option<S.Number>;
|
|
67
67
|
}>;
|
|
68
68
|
/** Sent after the search debounce period to clear the accumulated query. */
|
|
69
|
-
export declare const
|
|
69
|
+
export declare const CompletedDelayClearSearch: import("foldkit/schema").CallableTaggedStruct<"CompletedDelayClearSearch", {
|
|
70
70
|
version: S.Number;
|
|
71
71
|
}>;
|
|
72
72
|
/** Sent when the pointer moves over a menu item, carrying screen coordinates for tracked-pointer comparison. */
|
|
@@ -101,7 +101,7 @@ export declare const CompletedAnchorMenu: import("foldkit/schema").CallableTagge
|
|
|
101
101
|
export declare const CompletedPortalMenuBackdrop: import("foldkit/schema").CallableTaggedStruct<"CompletedPortalMenuBackdrop", {}>;
|
|
102
102
|
/** Wraps an Animation submodel message for delegation. */
|
|
103
103
|
export declare const GotAnimationMessage: import("foldkit/schema").CallableTaggedStruct<"GotAnimationMessage", {
|
|
104
|
-
message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"
|
|
104
|
+
message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"CompletedWaitForPaint", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
|
|
105
105
|
}>;
|
|
106
106
|
/** Sent when the user presses a pointer device on the menu button. Records pointer type and toggles for mouse. */
|
|
107
107
|
export declare const PressedPointerOnButton: import("foldkit/schema").CallableTaggedStruct<"PressedPointerOnButton", {
|
|
@@ -128,7 +128,7 @@ export declare const Message: S.Union<[
|
|
|
128
128
|
typeof MovedPointerOverItem,
|
|
129
129
|
typeof RequestedItemClick,
|
|
130
130
|
typeof Searched,
|
|
131
|
-
typeof
|
|
131
|
+
typeof CompletedDelayClearSearch,
|
|
132
132
|
typeof CompletedFocusItems,
|
|
133
133
|
typeof CompletedFocusButton,
|
|
134
134
|
typeof CompletedLockScroll,
|
|
@@ -174,7 +174,7 @@ export type SelectedItem = typeof SelectedItem.Type;
|
|
|
174
174
|
export type MovedPointerOverItem = typeof MovedPointerOverItem.Type;
|
|
175
175
|
export type RequestedItemClick = typeof RequestedItemClick.Type;
|
|
176
176
|
export type Searched = typeof Searched.Type;
|
|
177
|
-
export type
|
|
177
|
+
export type CompletedDelayClearSearch = typeof CompletedDelayClearSearch.Type;
|
|
178
178
|
export type IgnoredMouseClick = typeof IgnoredMouseClick.Type;
|
|
179
179
|
export type SuppressedSpaceScroll = typeof SuppressedSpaceScroll.Type;
|
|
180
180
|
export type PressedPointerOnButton = typeof PressedPointerOnButton.Type;
|
|
@@ -247,7 +247,7 @@ export declare const ClickItem: Command.CommandDefinitionWithArgs<"ClickItem", {
|
|
|
247
247
|
export declare const DelayClearSearch: Command.CommandDefinitionWithArgs<"DelayClearSearch", {
|
|
248
248
|
version: S.Number;
|
|
249
249
|
}, Effect.Effect<{
|
|
250
|
-
readonly _tag: "
|
|
250
|
+
readonly _tag: "CompletedDelayClearSearch";
|
|
251
251
|
readonly version: number;
|
|
252
252
|
}, never, never>>;
|
|
253
253
|
/** Detects whether the menu button moved or the leave animation ended. Whichever comes first; both outcomes signal the Animation submodel that leave is complete. */
|
|
@@ -260,7 +260,7 @@ export declare const DetectMovementOrAnimationEnd: Command.CommandDefinitionWith
|
|
|
260
260
|
} | {
|
|
261
261
|
readonly _tag: "Hid";
|
|
262
262
|
} | {
|
|
263
|
-
readonly _tag: "
|
|
263
|
+
readonly _tag: "CompletedWaitForPaint";
|
|
264
264
|
} | {
|
|
265
265
|
readonly _tag: "EndedAnimation";
|
|
266
266
|
};
|
|
@@ -280,6 +280,7 @@ export declare const AnchorMenu: Mount.MountDefinitionWithArgs<"AnchorMenu", {
|
|
|
280
280
|
readonly offset: S.optional<S.Number>;
|
|
281
281
|
readonly padding: S.optional<S.Number>;
|
|
282
282
|
readonly portal: S.optional<S.Boolean>;
|
|
283
|
+
readonly isPlacementLocked: S.optional<S.Boolean>;
|
|
283
284
|
}>;
|
|
284
285
|
}, {
|
|
285
286
|
readonly _tag: "CompletedAnchorMenu";
|
package/dist/menu/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/menu/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,MAAM,EAGN,MAAM,EAEN,MAAM,IAAI,CAAC,EAGZ,MAAM,QAAQ,CAAA;AACf,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAE1C,OAAO,KAAK,EAAE,cAAc,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAExD,OAA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