@foldkit/ui 0.112.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 (201) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +67 -0
  3. package/dist/anchor.d.ts +38 -0
  4. package/dist/anchor.d.ts.map +1 -0
  5. package/dist/anchor.js +142 -0
  6. package/dist/animation/index.d.ts +49 -0
  7. package/dist/animation/index.d.ts.map +1 -0
  8. package/dist/animation/index.js +75 -0
  9. package/dist/animation/public.d.ts +3 -0
  10. package/dist/animation/public.d.ts.map +1 -0
  11. package/dist/animation/public.js +1 -0
  12. package/dist/animation/schema.d.ts +43 -0
  13. package/dist/animation/schema.d.ts.map +1 -0
  14. package/dist/animation/schema.js +41 -0
  15. package/dist/animation/update.d.ts +24 -0
  16. package/dist/animation/update.d.ts.map +1 -0
  17. package/dist/animation/update.js +67 -0
  18. package/dist/button/index.d.ts +17 -0
  19. package/dist/button/index.d.ts.map +1 -0
  20. package/dist/button/index.js +22 -0
  21. package/dist/button/public.d.ts +3 -0
  22. package/dist/button/public.d.ts.map +1 -0
  23. package/dist/button/public.js +1 -0
  24. package/dist/calendar/index.d.ts +462 -0
  25. package/dist/calendar/index.d.ts.map +1 -0
  26. package/dist/calendar/index.js +825 -0
  27. package/dist/calendar/public.d.ts +3 -0
  28. package/dist/calendar/public.d.ts.map +1 -0
  29. package/dist/calendar/public.js +1 -0
  30. package/dist/checkbox/index.d.ts +119 -0
  31. package/dist/checkbox/index.d.ts.map +1 -0
  32. package/dist/checkbox/index.js +111 -0
  33. package/dist/checkbox/public.d.ts +3 -0
  34. package/dist/checkbox/public.d.ts.map +1 -0
  35. package/dist/checkbox/public.js +1 -0
  36. package/dist/combobox/multi.d.ts +183 -0
  37. package/dist/combobox/multi.d.ts.map +1 -0
  38. package/dist/combobox/multi.js +81 -0
  39. package/dist/combobox/multiPublic.d.ts +3 -0
  40. package/dist/combobox/multiPublic.d.ts.map +1 -0
  41. package/dist/combobox/multiPublic.js +1 -0
  42. package/dist/combobox/public.d.ts +7 -0
  43. package/dist/combobox/public.d.ts.map +1 -0
  44. package/dist/combobox/public.js +3 -0
  45. package/dist/combobox/shared.d.ts +423 -0
  46. package/dist/combobox/shared.d.ts.map +1 -0
  47. package/dist/combobox/shared.js +708 -0
  48. package/dist/combobox/single.d.ts +198 -0
  49. package/dist/combobox/single.d.ts.map +1 -0
  50. package/dist/combobox/single.js +106 -0
  51. package/dist/datePicker/index.d.ts +457 -0
  52. package/dist/datePicker/index.d.ts.map +1 -0
  53. package/dist/datePicker/index.js +318 -0
  54. package/dist/datePicker/public.d.ts +3 -0
  55. package/dist/datePicker/public.d.ts.map +1 -0
  56. package/dist/datePicker/public.js +1 -0
  57. package/dist/dialog/index.d.ts +160 -0
  58. package/dist/dialog/index.d.ts.map +1 -0
  59. package/dist/dialog/index.js +211 -0
  60. package/dist/dialog/public.d.ts +3 -0
  61. package/dist/dialog/public.d.ts.map +1 -0
  62. package/dist/dialog/public.js +1 -0
  63. package/dist/disclosure/index.d.ts +110 -0
  64. package/dist/disclosure/index.d.ts.map +1 -0
  65. package/dist/disclosure/index.js +111 -0
  66. package/dist/disclosure/public.d.ts +3 -0
  67. package/dist/disclosure/public.d.ts.map +1 -0
  68. package/dist/disclosure/public.js +1 -0
  69. package/dist/dragAndDrop/index.d.ts +540 -0
  70. package/dist/dragAndDrop/index.d.ts.map +1 -0
  71. package/dist/dragAndDrop/index.js +535 -0
  72. package/dist/dragAndDrop/public.d.ts +3 -0
  73. package/dist/dragAndDrop/public.d.ts.map +1 -0
  74. package/dist/dragAndDrop/public.js +1 -0
  75. package/dist/fieldset/index.d.ts +21 -0
  76. package/dist/fieldset/index.d.ts.map +1 -0
  77. package/dist/fieldset/index.js +25 -0
  78. package/dist/fieldset/public.d.ts +3 -0
  79. package/dist/fieldset/public.d.ts.map +1 -0
  80. package/dist/fieldset/public.js +1 -0
  81. package/dist/fileDrop/index.d.ts +109 -0
  82. package/dist/fileDrop/index.d.ts.map +1 -0
  83. package/dist/fileDrop/index.js +127 -0
  84. package/dist/fileDrop/public.d.ts +3 -0
  85. package/dist/fileDrop/public.d.ts.map +1 -0
  86. package/dist/fileDrop/public.js +1 -0
  87. package/dist/group.d.ts +8 -0
  88. package/dist/group.d.ts.map +1 -0
  89. package/dist/group.js +13 -0
  90. package/dist/index.d.ts +25 -0
  91. package/dist/index.d.ts.map +1 -0
  92. package/dist/index.js +24 -0
  93. package/dist/input/index.d.ts +26 -0
  94. package/dist/input/index.d.ts.map +1 -0
  95. package/dist/input/index.js +43 -0
  96. package/dist/input/public.d.ts +3 -0
  97. package/dist/input/public.d.ts.map +1 -0
  98. package/dist/input/public.js +1 -0
  99. package/dist/internal/optionExtensions.d.ts +6 -0
  100. package/dist/internal/optionExtensions.d.ts.map +1 -0
  101. package/dist/internal/optionExtensions.js +2 -0
  102. package/dist/keyboard.d.ts +6 -0
  103. package/dist/keyboard.d.ts.map +1 -0
  104. package/dist/keyboard.js +9 -0
  105. package/dist/listbox/multi.d.ts +189 -0
  106. package/dist/listbox/multi.d.ts.map +1 -0
  107. package/dist/listbox/multi.js +65 -0
  108. package/dist/listbox/multiPublic.d.ts +3 -0
  109. package/dist/listbox/multiPublic.d.ts.map +1 -0
  110. package/dist/listbox/multiPublic.js +1 -0
  111. package/dist/listbox/public.d.ts +7 -0
  112. package/dist/listbox/public.d.ts.map +1 -0
  113. package/dist/listbox/public.js +3 -0
  114. package/dist/listbox/shared.d.ts +432 -0
  115. package/dist/listbox/shared.d.ts.map +1 -0
  116. package/dist/listbox/shared.js +670 -0
  117. package/dist/listbox/single.d.ts +207 -0
  118. package/dist/listbox/single.d.ts.map +1 -0
  119. package/dist/listbox/single.js +73 -0
  120. package/dist/menu/index.d.ts +368 -0
  121. package/dist/menu/index.d.ts.map +1 -0
  122. package/dist/menu/index.js +682 -0
  123. package/dist/menu/public.d.ts +4 -0
  124. package/dist/menu/public.d.ts.map +1 -0
  125. package/dist/menu/public.js +1 -0
  126. package/dist/popover/index.d.ts +267 -0
  127. package/dist/popover/index.d.ts.map +1 -0
  128. package/dist/popover/index.js +346 -0
  129. package/dist/popover/public.d.ts +4 -0
  130. package/dist/popover/public.d.ts.map +1 -0
  131. package/dist/popover/public.js +1 -0
  132. package/dist/radioGroup/index.d.ts +169 -0
  133. package/dist/radioGroup/index.d.ts.map +1 -0
  134. package/dist/radioGroup/index.js +197 -0
  135. package/dist/radioGroup/public.d.ts +3 -0
  136. package/dist/radioGroup/public.d.ts.map +1 -0
  137. package/dist/radioGroup/public.js +1 -0
  138. package/dist/select/index.d.ts +24 -0
  139. package/dist/select/index.d.ts.map +1 -0
  140. package/dist/select/index.js +40 -0
  141. package/dist/select/public.d.ts +3 -0
  142. package/dist/select/public.d.ts.map +1 -0
  143. package/dist/select/public.js +1 -0
  144. package/dist/slider/index.d.ts +318 -0
  145. package/dist/slider/index.d.ts.map +1 -0
  146. package/dist/slider/index.js +337 -0
  147. package/dist/slider/public.d.ts +3 -0
  148. package/dist/slider/public.d.ts.map +1 -0
  149. package/dist/slider/public.js +1 -0
  150. package/dist/switch/index.d.ts +99 -0
  151. package/dist/switch/index.d.ts.map +1 -0
  152. package/dist/switch/index.js +107 -0
  153. package/dist/switch/public.d.ts +3 -0
  154. package/dist/switch/public.d.ts.map +1 -0
  155. package/dist/switch/public.js +1 -0
  156. package/dist/tabs/index.d.ts +155 -0
  157. package/dist/tabs/index.d.ts.map +1 -0
  158. package/dist/tabs/index.js +185 -0
  159. package/dist/tabs/public.d.ts +3 -0
  160. package/dist/tabs/public.d.ts.map +1 -0
  161. package/dist/tabs/public.js +1 -0
  162. package/dist/test/apps/disabledButton.d.ts +38 -0
  163. package/dist/test/apps/disabledButton.d.ts.map +1 -0
  164. package/dist/test/apps/disabledButton.js +71 -0
  165. package/dist/textarea/index.d.ts +26 -0
  166. package/dist/textarea/index.d.ts.map +1 -0
  167. package/dist/textarea/index.js +44 -0
  168. package/dist/textarea/public.d.ts +3 -0
  169. package/dist/textarea/public.d.ts.map +1 -0
  170. package/dist/textarea/public.js +1 -0
  171. package/dist/toast/index.d.ts +608 -0
  172. package/dist/toast/index.d.ts.map +1 -0
  173. package/dist/toast/index.js +146 -0
  174. package/dist/toast/public.d.ts +4 -0
  175. package/dist/toast/public.d.ts.map +1 -0
  176. package/dist/toast/public.js +1 -0
  177. package/dist/toast/schema.d.ts +154 -0
  178. package/dist/toast/schema.d.ts.map +1 -0
  179. package/dist/toast/schema.js +93 -0
  180. package/dist/toast/update.d.ts +510 -0
  181. package/dist/toast/update.d.ts.map +1 -0
  182. package/dist/toast/update.js +225 -0
  183. package/dist/tooltip/index.d.ts +170 -0
  184. package/dist/tooltip/index.d.ts.map +1 -0
  185. package/dist/tooltip/index.js +253 -0
  186. package/dist/tooltip/public.d.ts +4 -0
  187. package/dist/tooltip/public.d.ts.map +1 -0
  188. package/dist/tooltip/public.js +1 -0
  189. package/dist/typeahead.d.ts +4 -0
  190. package/dist/typeahead.d.ts.map +1 -0
  191. package/dist/typeahead.js +14 -0
  192. package/dist/virtualList/index.d.ts +203 -0
  193. package/dist/virtualList/index.d.ts.map +1 -0
  194. package/dist/virtualList/index.js +392 -0
  195. package/dist/virtualList/public.d.ts +3 -0
  196. package/dist/virtualList/public.d.ts.map +1 -0
  197. package/dist/virtualList/public.js +1 -0
  198. package/dist/vitest-setup.d.ts +2 -0
  199. package/dist/vitest-setup.d.ts.map +1 -0
  200. package/dist/vitest-setup.js +2 -0
  201. package/package.json +161 -0
@@ -0,0 +1,432 @@
1
+ import { Effect, Option, Schema as S } from 'effect';
2
+ import * as Command from 'foldkit/command';
3
+ import { type ChildAttribute, type Html } from 'foldkit/html';
4
+ import * as Mount from 'foldkit/mount';
5
+ import { type View as SubmodelView } from 'foldkit/submodel';
6
+ import { AnchorConfig } from '../anchor.js';
7
+ import { resolveTypeaheadMatch } from '../typeahead.js';
8
+ export { resolveTypeaheadMatch };
9
+ /** Schema for the activation trigger: whether the user interacted via mouse or keyboard. */
10
+ export declare const ActivationTrigger: S.Literals<readonly ["Pointer", "Keyboard"]>;
11
+ export type ActivationTrigger = typeof ActivationTrigger.Type;
12
+ /** Schema for the listbox orientation: whether items flow vertically or horizontally. */
13
+ export declare const Orientation: S.Literals<readonly ["Vertical", "Horizontal"]>;
14
+ export type Orientation = typeof Orientation.Type;
15
+ /** Schema fields shared by all listbox variants (single-select and multi-select). Spread into each variant's `S.Struct` to avoid duplicating field definitions. */
16
+ export declare const BaseModel: S.Struct<{
17
+ readonly id: S.String;
18
+ readonly isOpen: S.Boolean;
19
+ readonly isAnimated: S.Boolean;
20
+ readonly isModal: S.Boolean;
21
+ readonly orientation: S.Literals<readonly ["Vertical", "Horizontal"]>;
22
+ readonly animation: S.Struct<{
23
+ readonly id: S.String;
24
+ readonly isShowing: S.Boolean;
25
+ readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
26
+ }>;
27
+ readonly maybeActiveItemIndex: S.Option<S.Number>;
28
+ readonly activationTrigger: S.Literals<readonly ["Pointer", "Keyboard"]>;
29
+ readonly searchQuery: S.String;
30
+ readonly searchVersion: S.Number;
31
+ readonly maybeLastPointerPosition: S.Option<S.Struct<{
32
+ readonly screenX: S.Number;
33
+ readonly screenY: S.Number;
34
+ }>>;
35
+ readonly maybeLastButtonPointerType: S.Option<S.String>;
36
+ }>;
37
+ export type BaseModel = typeof BaseModel.Type;
38
+ /** Configuration fields shared by all listbox variant `init` functions. */
39
+ export type BaseInitConfig = Readonly<{
40
+ id: string;
41
+ isAnimated?: boolean;
42
+ isModal?: boolean;
43
+ orientation?: typeof Orientation.Type;
44
+ }>;
45
+ /** Creates the shared base fields for a listbox model from a config. Each variant spreads this and adds its selection field. */
46
+ export declare const baseInit: (config: BaseInitConfig) => BaseModel;
47
+ /** Sent when the listbox opens via button click or keyboard. Contains an optional initial active item index: None for pointer, Some for keyboard. */
48
+ export declare const Opened: import("foldkit/schema").CallableTaggedStruct<"Opened", {
49
+ maybeActiveItemIndex: S.Option<S.Number>;
50
+ }>;
51
+ /** Sent when the listbox closes via Escape key or backdrop click. */
52
+ export declare const Closed: import("foldkit/schema").CallableTaggedStruct<"Closed", {}>;
53
+ /** Sent when the listbox items container loses focus. */
54
+ export declare const BlurredItems: import("foldkit/schema").CallableTaggedStruct<"BlurredItems", {}>;
55
+ /** Sent when an item is highlighted via arrow keys or mouse hover. Includes activation trigger. */
56
+ export declare const ActivatedItem: import("foldkit/schema").CallableTaggedStruct<"ActivatedItem", {
57
+ index: S.Number;
58
+ activationTrigger: S.Literals<readonly ["Pointer", "Keyboard"]>;
59
+ }>;
60
+ /** Sent when the mouse leaves an enabled item. */
61
+ export declare const DeactivatedItem: import("foldkit/schema").CallableTaggedStruct<"DeactivatedItem", {}>;
62
+ /** Sent when an item is selected via Enter, Space, or click. Contains the item's string value. */
63
+ export declare const SelectedItem: import("foldkit/schema").CallableTaggedStruct<"SelectedItem", {
64
+ item: S.String;
65
+ }>;
66
+ /** Sent when Enter or Space is pressed on the active item, triggering a programmatic click on the DOM element. */
67
+ export declare const RequestedItemClick: import("foldkit/schema").CallableTaggedStruct<"RequestedItemClick", {
68
+ index: S.Number;
69
+ }>;
70
+ /** Sent when a printable character is typed for typeahead search. */
71
+ export declare const Searched: import("foldkit/schema").CallableTaggedStruct<"Searched", {
72
+ key: S.String;
73
+ maybeTargetIndex: S.Option<S.Number>;
74
+ }>;
75
+ /** Sent after the search debounce period to clear the accumulated query. */
76
+ export declare const ClearedSearch: import("foldkit/schema").CallableTaggedStruct<"ClearedSearch", {
77
+ version: S.Number;
78
+ }>;
79
+ /** Sent when the pointer moves over a listbox item, carrying screen coordinates for tracked-pointer comparison. */
80
+ export declare const MovedPointerOverItem: import("foldkit/schema").CallableTaggedStruct<"MovedPointerOverItem", {
81
+ index: S.Number;
82
+ screenX: S.Number;
83
+ screenY: S.Number;
84
+ }>;
85
+ /** Sent when the scroll lock command completes. */
86
+ export declare const CompletedLockScroll: import("foldkit/schema").CallableTaggedStruct<"CompletedLockScroll", {}>;
87
+ /** Sent when the scroll unlock command completes. */
88
+ export declare const CompletedUnlockScroll: import("foldkit/schema").CallableTaggedStruct<"CompletedUnlockScroll", {}>;
89
+ /** Sent when the inert-others command completes. */
90
+ export declare const CompletedInertOthers: import("foldkit/schema").CallableTaggedStruct<"CompletedInertOthers", {}>;
91
+ /** Sent when the restore-inert command completes. */
92
+ export declare const CompletedRestoreInert: import("foldkit/schema").CallableTaggedStruct<"CompletedRestoreInert", {}>;
93
+ /** Sent when the focus-button command completes after closing. */
94
+ export declare const CompletedFocusButton: import("foldkit/schema").CallableTaggedStruct<"CompletedFocusButton", {}>;
95
+ /** Sent when the focus-items command completes after opening. */
96
+ export declare const CompletedFocusItems: import("foldkit/schema").CallableTaggedStruct<"CompletedFocusItems", {}>;
97
+ /** Sent when the scroll-into-view command completes after keyboard activation. */
98
+ export declare const CompletedScrollIntoView: import("foldkit/schema").CallableTaggedStruct<"CompletedScrollIntoView", {}>;
99
+ /** Sent when the programmatic item click command completes. */
100
+ export declare const CompletedClickItem: import("foldkit/schema").CallableTaggedStruct<"CompletedClickItem", {}>;
101
+ /** Sent when a mouse click on the button is ignored because pointer-down already handled the toggle. */
102
+ export declare const IgnoredMouseClick: import("foldkit/schema").CallableTaggedStruct<"IgnoredMouseClick", {}>;
103
+ /** Sent when a Space key-up is captured to prevent page scrolling. */
104
+ export declare const SuppressedSpaceScroll: import("foldkit/schema").CallableTaggedStruct<"SuppressedSpaceScroll", {}>;
105
+ /** Sent when the listbox items panel mounts and Floating UI has positioned it. Update no-ops; surfaces the positioning side effect for DevTools. */
106
+ export declare const CompletedAnchorListbox: import("foldkit/schema").CallableTaggedStruct<"CompletedAnchorListbox", {}>;
107
+ /** Sent when the listbox backdrop mounts and is portaled to the document body. Update no-ops; surfaces the portal side effect for DevTools. */
108
+ export declare const CompletedPortalListboxBackdrop: import("foldkit/schema").CallableTaggedStruct<"CompletedPortalListboxBackdrop", {}>;
109
+ /** Wraps an Animation submodel message for delegation. */
110
+ export declare const GotAnimationMessage: import("foldkit/schema").CallableTaggedStruct<"GotAnimationMessage", {
111
+ message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
112
+ }>;
113
+ /** Sent when the user presses a pointer device on the listbox button. Records pointer type for click handling. */
114
+ export declare const PressedPointerOnButton: import("foldkit/schema").CallableTaggedStruct<"PressedPointerOnButton", {
115
+ pointerType: S.String;
116
+ button: S.Number;
117
+ }>;
118
+ /** Union of all messages the listbox component can produce. */
119
+ export declare const Message: S.Union<[
120
+ typeof Opened,
121
+ typeof Closed,
122
+ typeof BlurredItems,
123
+ typeof ActivatedItem,
124
+ typeof DeactivatedItem,
125
+ typeof SelectedItem,
126
+ typeof MovedPointerOverItem,
127
+ typeof RequestedItemClick,
128
+ typeof Searched,
129
+ typeof ClearedSearch,
130
+ typeof CompletedLockScroll,
131
+ typeof CompletedUnlockScroll,
132
+ typeof CompletedInertOthers,
133
+ typeof CompletedRestoreInert,
134
+ typeof CompletedFocusButton,
135
+ typeof CompletedFocusItems,
136
+ typeof CompletedScrollIntoView,
137
+ typeof CompletedClickItem,
138
+ typeof IgnoredMouseClick,
139
+ typeof SuppressedSpaceScroll,
140
+ typeof CompletedAnchorListbox,
141
+ typeof CompletedPortalListboxBackdrop,
142
+ typeof GotAnimationMessage,
143
+ typeof PressedPointerOnButton
144
+ ]>;
145
+ export type Opened = typeof Opened.Type;
146
+ export type Closed = typeof Closed.Type;
147
+ export type BlurredItems = typeof BlurredItems.Type;
148
+ export type ActivatedItem = typeof ActivatedItem.Type;
149
+ export type DeactivatedItem = typeof DeactivatedItem.Type;
150
+ export type SelectedItem = typeof SelectedItem.Type;
151
+ export type MovedPointerOverItem = typeof MovedPointerOverItem.Type;
152
+ export type RequestedItemClick = typeof RequestedItemClick.Type;
153
+ export type Searched = typeof Searched.Type;
154
+ export type ClearedSearch = typeof ClearedSearch.Type;
155
+ export type IgnoredMouseClick = typeof IgnoredMouseClick.Type;
156
+ export type SuppressedSpaceScroll = typeof SuppressedSpaceScroll.Type;
157
+ export type PressedPointerOnButton = typeof PressedPointerOnButton.Type;
158
+ export type Message = typeof Message.Type;
159
+ /** Sent when a single-select listbox commits a selection, or when a multi-select listbox toggles an item. Generic over `Value extends string`: the runtime schema stores `value: string`, but the type-level OutMessage exposes `value: Value` so consumers who supply `items: ReadonlyArray<MyUnion>` receive `value: MyUnion` from `update<MyUnion>` without casting. The cast is fenced inside this module's `update` return, sound because the value was extracted from the items array the consumer supplied. */
160
+ export declare const Selected: import("foldkit/schema").CallableTaggedStruct<"Selected", {
161
+ value: S.String;
162
+ wasAdded: S.Boolean;
163
+ }>;
164
+ export type Selected<Value extends string = string> = Readonly<{
165
+ readonly _tag: 'Selected';
166
+ readonly value: Value;
167
+ readonly wasAdded: boolean;
168
+ }>;
169
+ /** Union of out-messages the listbox component can produce. Single-select listboxes always emit `wasAdded: true`. Multi-select listboxes emit `wasAdded: true` when adding to the selection and `wasAdded: false` when toggling off. */
170
+ export declare const OutMessage: S.Union<readonly [import("foldkit/schema").CallableTaggedStruct<"Selected", {
171
+ value: S.String;
172
+ wasAdded: S.Boolean;
173
+ }>]>;
174
+ /** Generic over `Value extends string` so consumers who create the listbox
175
+ * via `Listbox.create<MyUnion>()` receive `value: MyUnion` in the
176
+ * `Selected` OutMessage from the factory's `update`, instead of
177
+ * `value: string`. Defaults to `string`. */
178
+ export type OutMessage<Value extends string = string> = Selected<Value>;
179
+ export declare const SEARCH_DEBOUNCE_MILLISECONDS = 350;
180
+ export declare const LEFT_MOUSE_BUTTON = 0;
181
+ export declare const buttonSelector: (id: string) => string;
182
+ export declare const itemsSelector: (id: string) => string;
183
+ export declare const itemSelector: (id: string, index: number) => string;
184
+ export declare const itemId: (id: string, index: number) => string;
185
+ export declare const closedModel: <Model extends BaseModel>(model: Model) => Model;
186
+ type SelectedItemContext<Model extends BaseModel> = Readonly<{
187
+ closeWithFocus: (model: Model, maybeOutMessage?: Option.Option<OutMessage>) => readonly [
188
+ Model,
189
+ ReadonlyArray<Command.Command<Message>>,
190
+ Option.Option<OutMessage>
191
+ ];
192
+ closeWithoutFocus: (model: Model, maybeOutMessage?: Option.Option<OutMessage>) => readonly [
193
+ Model,
194
+ ReadonlyArray<Command.Command<Message>>,
195
+ Option.Option<OutMessage>
196
+ ];
197
+ }>;
198
+ /** Prevents page scrolling while the listbox is open in modal mode. */
199
+ export declare const LockScroll: Command.CommandDefinitionNoArgs<"LockScroll", Effect.Effect<{
200
+ readonly _tag: "CompletedLockScroll";
201
+ }, never, never>>;
202
+ /** Re-enables page scrolling after the listbox closes. */
203
+ export declare const UnlockScroll: Command.CommandDefinitionNoArgs<"UnlockScroll", Effect.Effect<{
204
+ readonly _tag: "CompletedUnlockScroll";
205
+ }, never, never>>;
206
+ /** Marks all elements outside the listbox as inert for modal behavior. */
207
+ export declare const InertOthers: Command.CommandDefinitionWithArgs<"InertOthers", {
208
+ id: S.String;
209
+ }, Effect.Effect<{
210
+ readonly _tag: "CompletedInertOthers";
211
+ }, never, never>>;
212
+ /** Removes the inert attribute from elements outside the listbox. */
213
+ export declare const RestoreInert: Command.CommandDefinitionWithArgs<"RestoreInert", {
214
+ id: S.String;
215
+ }, Effect.Effect<{
216
+ readonly _tag: "CompletedRestoreInert";
217
+ }, never, never>>;
218
+ /** Moves focus back to the listbox button after closing. */
219
+ export declare const FocusButton: Command.CommandDefinitionWithArgs<"FocusButton", {
220
+ id: S.String;
221
+ }, Effect.Effect<{
222
+ readonly _tag: "CompletedFocusButton";
223
+ }, never, never>>;
224
+ /** Moves focus to the listbox items container after opening. */
225
+ export declare const FocusItems: Command.CommandDefinitionWithArgs<"FocusItems", {
226
+ id: S.String;
227
+ }, Effect.Effect<{
228
+ readonly _tag: "CompletedFocusItems";
229
+ }, never, never>>;
230
+ /** Scrolls the active listbox item into view after keyboard navigation. */
231
+ export declare const ScrollIntoView: Command.CommandDefinitionWithArgs<"ScrollIntoView", {
232
+ id: S.String;
233
+ index: S.Number;
234
+ }, Effect.Effect<{
235
+ readonly _tag: "CompletedScrollIntoView";
236
+ }, never, never>>;
237
+ /** Programmatically clicks the active listbox item's DOM element. */
238
+ export declare const ClickItem: Command.CommandDefinitionWithArgs<"ClickItem", {
239
+ id: S.String;
240
+ index: S.Number;
241
+ }, Effect.Effect<{
242
+ readonly _tag: "CompletedClickItem";
243
+ }, never, never>>;
244
+ /** Waits for the typeahead search debounce period before clearing the query. */
245
+ export declare const DelayClearSearch: Command.CommandDefinitionWithArgs<"DelayClearSearch", {
246
+ version: S.Number;
247
+ }, Effect.Effect<{
248
+ readonly _tag: "ClearedSearch";
249
+ readonly version: number;
250
+ }, never, never>>;
251
+ /** Detects whether the listbox button moved or the leave animation ended. Whichever comes first; both outcomes signal the Animation submodel that leave is complete. */
252
+ export declare const DetectMovementOrAnimationEnd: Command.CommandDefinitionWithArgs<"DetectMovementOrAnimationEnd", {
253
+ id: S.String;
254
+ }, Effect.Effect<{
255
+ readonly _tag: "GotAnimationMessage";
256
+ readonly message: {
257
+ readonly _tag: "Showed";
258
+ } | {
259
+ readonly _tag: "Hid";
260
+ } | {
261
+ readonly _tag: "AdvancedAnimationFrame";
262
+ } | {
263
+ readonly _tag: "EndedAnimation";
264
+ };
265
+ }, never, never>>;
266
+ export declare const makeUpdate: <Model extends BaseModel>(handleSelectedItem: (model: Model, item: string, context: SelectedItemContext<Model>) => readonly [Model, ReadonlyArray<Command.Command<Message>>, Option.Option<OutMessage>]) => (model: Model, message: Message) => readonly [Model, readonly Readonly<{
267
+ name: string;
268
+ args?: Record<string, unknown>;
269
+ effect: Effect.Effect<{
270
+ readonly _tag: "CompletedFocusButton";
271
+ } | {
272
+ readonly _tag: "CompletedLockScroll";
273
+ } | {
274
+ readonly _tag: "CompletedUnlockScroll";
275
+ } | {
276
+ readonly _tag: "CompletedInertOthers";
277
+ } | {
278
+ readonly _tag: "CompletedRestoreInert";
279
+ } | {
280
+ readonly _tag: "IgnoredMouseClick";
281
+ } | {
282
+ readonly _tag: "SuppressedSpaceScroll";
283
+ } | {
284
+ readonly _tag: "Closed";
285
+ } | {
286
+ readonly _tag: "DeactivatedItem";
287
+ } | {
288
+ readonly _tag: "CompletedScrollIntoView";
289
+ } | {
290
+ readonly _tag: "CompletedClickItem";
291
+ } | {
292
+ readonly _tag: "Opened";
293
+ readonly maybeActiveItemIndex: Option.Option<number>;
294
+ } | {
295
+ readonly _tag: "BlurredItems";
296
+ } | {
297
+ readonly _tag: "ActivatedItem";
298
+ readonly index: number;
299
+ readonly activationTrigger: "Pointer" | "Keyboard";
300
+ } | {
301
+ readonly _tag: "SelectedItem";
302
+ readonly item: string;
303
+ } | {
304
+ readonly _tag: "RequestedItemClick";
305
+ readonly index: number;
306
+ } | {
307
+ readonly _tag: "Searched";
308
+ readonly key: string;
309
+ readonly maybeTargetIndex: Option.Option<number>;
310
+ } | {
311
+ readonly _tag: "ClearedSearch";
312
+ readonly version: number;
313
+ } | {
314
+ readonly _tag: "MovedPointerOverItem";
315
+ readonly index: number;
316
+ readonly screenX: number;
317
+ readonly screenY: number;
318
+ } | {
319
+ readonly _tag: "CompletedFocusItems";
320
+ } | {
321
+ readonly _tag: "CompletedAnchorListbox";
322
+ } | {
323
+ readonly _tag: "CompletedPortalListboxBackdrop";
324
+ } | {
325
+ readonly _tag: "GotAnimationMessage";
326
+ readonly message: {
327
+ readonly _tag: "Showed";
328
+ } | {
329
+ readonly _tag: "Hid";
330
+ } | {
331
+ readonly _tag: "AdvancedAnimationFrame";
332
+ } | {
333
+ readonly _tag: "EndedAnimation";
334
+ };
335
+ } | {
336
+ readonly _tag: "PressedPointerOnButton";
337
+ readonly pointerType: string;
338
+ readonly button: number;
339
+ }, never, never>;
340
+ }>[], Option.Option<Readonly<{
341
+ readonly _tag: "Selected";
342
+ readonly value: string;
343
+ readonly wasAdded: boolean;
344
+ }>>];
345
+ /** The anchor-positioning Mount this Listbox renders on its items panel.
346
+ * The panel is always anchored to the button via Floating UI and portaled
347
+ * to the document body (opt out of portaling with `anchor.portal: false`),
348
+ * so it escapes ancestor stacking contexts and overflow clipping. Exposed
349
+ * so Scene tests can call
350
+ * `Scene.Mount.resolve(AnchorListbox, CompletedAnchorListbox())`. */
351
+ export declare const AnchorListbox: Mount.MountDefinitionWithArgs<"AnchorListbox", {
352
+ buttonId: S.String;
353
+ anchor: S.Struct<{
354
+ readonly placement: S.optional<S.Literals<readonly ["top", "right", "bottom", "left", "top-start", "top-end", "right-start", "right-end", "bottom-start", "bottom-end", "left-start", "left-end"]>>;
355
+ readonly gap: S.optional<S.Number>;
356
+ readonly offset: S.optional<S.Number>;
357
+ readonly padding: S.optional<S.Number>;
358
+ readonly portal: S.optional<S.Boolean>;
359
+ }>;
360
+ }, {
361
+ readonly _tag: "CompletedAnchorListbox";
362
+ }>;
363
+ /** The backdrop-portaling Mount this Listbox renders. Exposed so Scene tests can
364
+ * call `Scene.Mount.resolve(PortalListboxBackdrop, CompletedPortalListboxBackdrop())` to
365
+ * acknowledge the mount produced by the rendered backdrop. */
366
+ export declare const PortalListboxBackdrop: Mount.MountDefinitionNoArgs<"PortalListboxBackdrop", {
367
+ readonly _tag: "CompletedPortalListboxBackdrop";
368
+ }>;
369
+ /** Configuration for an individual listbox item's appearance. */
370
+ export type ItemConfig = Readonly<{
371
+ className?: string;
372
+ content: Html;
373
+ }>;
374
+ /** Configuration for a group heading rendered above a group of items. */
375
+ export type GroupHeading = Readonly<{
376
+ content: Html;
377
+ className?: string;
378
+ }>;
379
+ /** Per-render view inputs passed to `view` via `h.submodel`'s `viewInputs` field.
380
+ *
381
+ * The Listbox emits a `Selected({ value, wasAdded })` OutMessage on
382
+ * commit (single-select always `wasAdded: true`, multi-select toggles).
383
+ * Consumers pattern-match this in their `GotListboxMessage` handler. */
384
+ type BaseViewInputsCommon<Item> = Readonly<{
385
+ items: ReadonlyArray<Item>;
386
+ itemToConfig: (item: Item, context: Readonly<{
387
+ isActive: boolean;
388
+ isDisabled: boolean;
389
+ isSelected: boolean;
390
+ }>) => ItemConfig;
391
+ isItemDisabled?: (item: Item, index: number) => boolean;
392
+ itemToSearchText?: (item: Item, index: number) => string;
393
+ isButtonDisabled?: boolean;
394
+ buttonContent: Html;
395
+ buttonClassName?: string;
396
+ buttonAttributes?: ReadonlyArray<ChildAttribute>;
397
+ itemsClassName?: string;
398
+ itemsAttributes?: ReadonlyArray<ChildAttribute>;
399
+ itemsScrollClassName?: string;
400
+ itemsScrollAttributes?: ReadonlyArray<ChildAttribute>;
401
+ backdropClassName?: string;
402
+ backdropAttributes?: ReadonlyArray<ChildAttribute>;
403
+ className?: string;
404
+ attributes?: ReadonlyArray<ChildAttribute>;
405
+ itemGroupKey?: (item: Item, index: number) => string;
406
+ groupToHeading?: (groupKey: string) => GroupHeading | undefined;
407
+ groupClassName?: string;
408
+ groupAttributes?: ReadonlyArray<ChildAttribute>;
409
+ separatorClassName?: string;
410
+ separatorAttributes?: ReadonlyArray<ChildAttribute>;
411
+ anchor?: AnchorConfig;
412
+ name?: string;
413
+ form?: string;
414
+ isDisabled?: boolean;
415
+ isInvalid?: boolean;
416
+ }>;
417
+ /** Per-render view inputs for a Listbox view. The `itemToValue` extractor
418
+ * is optional when `Item` is itself a string (the default returns the
419
+ * item unchanged) and required when items are objects, so the OutMessage
420
+ * payload type can't drift from what the consumer actually emits. */
421
+ export type BaseViewInputs<Item, Value extends string = string> = BaseViewInputsCommon<Item> & ([Item] extends [string] ? Readonly<{
422
+ itemToValue?: (item: Item) => Value;
423
+ }> : Readonly<{
424
+ itemToValue: (item: Item) => Value;
425
+ }>);
426
+ type ViewBehavior<Model extends BaseModel> = Readonly<{
427
+ isItemSelected: (model: Model, itemValue: string) => boolean;
428
+ selectedItemIndex: <Item>(model: Model, items: ReadonlyArray<Item>, itemToValue: (item: Item) => string) => Option.Option<number>;
429
+ ariaMultiSelectable: boolean;
430
+ }>;
431
+ export declare const makeView: <Model extends BaseModel>(behavior: ViewBehavior<Model>) => <Item, Value extends string = string>() => SubmodelView<Model, Message, BaseViewInputs<Item, Value>>;
432
+ //# sourceMappingURL=shared.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/listbox/shared.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,EAAE,KAAK,cAAc,EAAE,KAAK,IAAI,EAAQ,MAAM,cAAc,CAAA;AAEnE,OAAO,KAAK,KAAK,MAAM,eAAe,CAAA;AAEtC,OAAO,EAAE,KAAK,IAAI,IAAI,YAAY,EAAc,MAAM,kBAAkB,CAAA;AAExE,OAAO,EAAE,YAAY,EAA6B,MAAM,cAAc,CAAA;AAqBtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAA;AAEvD,OAAO,EAAE,qBAAqB,EAAE,CAAA;AAIhC,4FAA4F;AAC5F,eAAO,MAAM,iBAAiB,8CAAsC,CAAA;AACpE,MAAM,MAAM,iBAAiB,GAAG,OAAO,iBAAiB,CAAC,IAAI,CAAA;AAE7D,yFAAyF;AACzF,eAAO,MAAM,WAAW,iDAAyC,CAAA;AACjE,MAAM,MAAM,WAAW,GAAG,OAAO,WAAW,CAAC,IAAI,CAAA;AAEjD,mKAAmK;AACnK,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;EAepB,CAAA;AACF,MAAM,MAAM,SAAS,GAAG,OAAO,SAAS,CAAC,IAAI,CAAA;AAE7C,2EAA2E;AAC3E,MAAM,MAAM,cAAc,GAAG,QAAQ,CAAC;IACpC,EAAE,EAAE,MAAM,CAAA;IACV,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,OAAO,CAAC,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