@foldkit/ui 0.131.0 → 0.133.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 (36) hide show
  1. package/dist/animation/index.d.ts +13 -13
  2. package/dist/calendar/index.d.ts +76 -76
  3. package/dist/combobox/multi.d.ts +110 -102
  4. package/dist/combobox/multi.d.ts.map +1 -1
  5. package/dist/combobox/shared.d.ts +92 -84
  6. package/dist/combobox/shared.d.ts.map +1 -1
  7. package/dist/combobox/single.d.ts +110 -102
  8. package/dist/combobox/single.d.ts.map +1 -1
  9. package/dist/datePicker/index.d.ts +152 -98
  10. package/dist/datePicker/index.d.ts.map +1 -1
  11. package/dist/dialog/index.d.ts +34 -26
  12. package/dist/dialog/index.d.ts.map +1 -1
  13. package/dist/dragAndDrop/index.d.ts +346 -326
  14. package/dist/dragAndDrop/index.d.ts.map +1 -1
  15. package/dist/fileDrop/index.d.ts +13 -13
  16. package/dist/listbox/multi.d.ts +110 -102
  17. package/dist/listbox/multi.d.ts.map +1 -1
  18. package/dist/listbox/shared.d.ts +86 -78
  19. package/dist/listbox/shared.d.ts.map +1 -1
  20. package/dist/listbox/single.d.ts +110 -102
  21. package/dist/listbox/single.d.ts.map +1 -1
  22. package/dist/menu/index.d.ts +15 -15
  23. package/dist/menu/index.d.ts.map +1 -1
  24. package/dist/popover/index.d.ts +69 -61
  25. package/dist/popover/index.d.ts.map +1 -1
  26. package/dist/slider/index.d.ts +164 -149
  27. package/dist/slider/index.d.ts.map +1 -1
  28. package/dist/toast/index.d.ts +462 -414
  29. package/dist/toast/index.d.ts.map +1 -1
  30. package/dist/toast/update.d.ts +388 -348
  31. package/dist/toast/update.d.ts.map +1 -1
  32. package/dist/tooltip/index.d.ts +31 -31
  33. package/dist/tooltip/index.d.ts.map +1 -1
  34. package/dist/virtualList/index.d.ts +30 -24
  35. package/dist/virtualList/index.d.ts.map +1 -1
  36. package/package.json +6 -6
@@ -44,72 +44,80 @@ export type EntryHandlers = Readonly<{
44
44
  * ```
45
45
  */
46
46
  export declare const make: <A, I>(payloadSchema: S.Codec<A, I>) => {
47
- readonly view: import("foldkit/submodel").View<S.Struct.ReadonlySide<{
48
- readonly id: S.String;
49
- readonly defaultDuration: S.DurationFromMillis;
50
- readonly entries: S.$Array<S.Struct<{
51
- readonly id: S.String;
52
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
53
- readonly animation: S.Struct<{
54
- readonly id: S.String;
55
- readonly isShowing: S.Boolean;
56
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
57
- }>;
58
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
59
- readonly pendingDismissVersion: S.Number;
60
- readonly isHovered: S.Boolean;
61
- readonly payload: S.Codec<A, I, never, never>;
62
- }>>;
63
- readonly nextEntryKey: S.Number;
64
- }, "Type">, S.Struct.ReadonlySide<{
65
- readonly _tag: S.tag<"Dismissed">;
66
- entryId: S.String;
67
- }, "Type"> | S.Struct.ReadonlySide<{
68
- readonly _tag: S.tag<"DismissedAll">;
69
- }, "Type"> | S.Struct.ReadonlySide<{
70
- readonly _tag: S.tag<"ElapsedDuration">;
71
- entryId: S.String;
72
- version: S.Number;
73
- }, "Type"> | S.Struct.ReadonlySide<{
74
- readonly _tag: S.tag<"HoveredEntry">;
75
- entryId: S.String;
76
- }, "Type"> | S.Struct.ReadonlySide<{
77
- readonly _tag: S.tag<"LeftEntry">;
78
- entryId: S.String;
79
- }, "Type"> | S.Struct.ReadonlySide<{
80
- readonly _tag: S.tag<"GotAnimationMessage">;
81
- entryId: S.String;
82
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
83
- }, "Type"> | S.Struct.ReadonlySide<{
84
- readonly _tag: S.tag<"Added">;
85
- entry: S.Struct<{
86
- readonly id: S.String;
87
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
88
- readonly animation: S.Struct<{
89
- readonly id: S.String;
90
- readonly isShowing: S.Boolean;
91
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
92
- }>;
93
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
94
- readonly pendingDismissVersion: S.Number;
95
- readonly isHovered: S.Boolean;
96
- readonly payload: S.Codec<A, I, never, never>;
97
- }>;
98
- }, "Type">, Readonly<{
47
+ readonly view: import("foldkit/submodel").View<{
48
+ readonly id: string;
49
+ readonly defaultDuration: import("effect/Duration").Duration;
50
+ readonly entries: readonly {
51
+ readonly id: string;
52
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
53
+ readonly animation: {
54
+ readonly id: string;
55
+ readonly isShowing: boolean;
56
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
57
+ };
58
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
59
+ readonly pendingDismissVersion: number;
60
+ readonly isHovered: boolean;
61
+ readonly payload: A;
62
+ }[];
63
+ readonly nextEntryKey: number;
64
+ }, {
65
+ readonly _tag: "Dismissed";
66
+ readonly entryId: string;
67
+ } | {
68
+ readonly _tag: "DismissedAll";
69
+ } | {
70
+ readonly _tag: "ElapsedDuration";
71
+ readonly entryId: string;
72
+ readonly version: number;
73
+ } | {
74
+ readonly _tag: "HoveredEntry";
75
+ readonly entryId: string;
76
+ } | {
77
+ readonly _tag: "LeftEntry";
78
+ readonly entryId: string;
79
+ } | {
80
+ readonly _tag: "GotAnimationMessage";
81
+ readonly entryId: string;
82
+ readonly message: {
83
+ readonly _tag: "Showed";
84
+ } | {
85
+ readonly _tag: "Hid";
86
+ } | {
87
+ readonly _tag: "AdvancedAnimationFrame";
88
+ } | {
89
+ readonly _tag: "EndedAnimation";
90
+ };
91
+ } | {
92
+ readonly _tag: "Added";
93
+ readonly entry: {
94
+ readonly id: string;
95
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
96
+ readonly animation: {
97
+ readonly id: string;
98
+ readonly isShowing: boolean;
99
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
100
+ };
101
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
102
+ readonly pendingDismissVersion: number;
103
+ readonly isHovered: boolean;
104
+ readonly payload: A;
105
+ };
106
+ }, Readonly<{
99
107
  position: Position;
100
- entryToView: (entry: S.Struct.ReadonlySide<{
101
- readonly id: S.String;
102
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
103
- readonly animation: S.Struct<{
104
- readonly id: S.String;
105
- readonly isShowing: S.Boolean;
106
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
107
- }>;
108
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
109
- readonly pendingDismissVersion: S.Number;
110
- readonly isHovered: S.Boolean;
111
- readonly payload: S.Codec<A, I, never, never>;
112
- }, "Type">, handlers: EntryHandlers) => Html;
108
+ entryToView: (entry: {
109
+ readonly id: string;
110
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
111
+ readonly animation: {
112
+ readonly id: string;
113
+ readonly isShowing: boolean;
114
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
115
+ };
116
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
117
+ readonly pendingDismissVersion: number;
118
+ readonly isHovered: boolean;
119
+ readonly payload: A;
120
+ }, handlers: EntryHandlers) => Html;
113
121
  ariaLabel?: string;
114
122
  containerClassName?: string;
115
123
  entryClassName?: string;
@@ -196,370 +204,410 @@ export declare const make: <A, I>(payloadSchema: S.Codec<A, I>) => {
196
204
  readonly init: (config: Readonly<{
197
205
  id: string;
198
206
  defaultDuration?: import("effect/Duration").Input;
199
- }>) => S.Struct.ReadonlySide<{
200
- readonly id: S.String;
201
- readonly defaultDuration: S.DurationFromMillis;
202
- readonly entries: S.$Array<S.Struct<{
203
- readonly id: S.String;
204
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
205
- readonly animation: S.Struct<{
206
- readonly id: S.String;
207
- readonly isShowing: S.Boolean;
208
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
209
- }>;
210
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
211
- readonly pendingDismissVersion: S.Number;
212
- readonly isHovered: S.Boolean;
213
- readonly payload: S.Codec<A, I, never, never>;
214
- }>>;
215
- readonly nextEntryKey: S.Number;
216
- }, "Type">;
217
- readonly update: (model: S.Struct.ReadonlySide<{
218
- readonly id: S.String;
219
- readonly defaultDuration: S.DurationFromMillis;
220
- readonly entries: S.$Array<S.Struct<{
221
- readonly id: S.String;
222
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
223
- readonly animation: S.Struct<{
224
- readonly id: S.String;
225
- readonly isShowing: S.Boolean;
226
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
227
- }>;
228
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
229
- readonly pendingDismissVersion: S.Number;
230
- readonly isHovered: S.Boolean;
231
- readonly payload: S.Codec<A, I, never, never>;
232
- }>>;
233
- readonly nextEntryKey: S.Number;
234
- }, "Type">, message: S.Struct.ReadonlySide<{
235
- readonly _tag: S.tag<"Dismissed">;
236
- entryId: S.String;
237
- }, "Type"> | S.Struct.ReadonlySide<{
238
- readonly _tag: S.tag<"DismissedAll">;
239
- }, "Type"> | S.Struct.ReadonlySide<{
240
- readonly _tag: S.tag<"ElapsedDuration">;
241
- entryId: S.String;
242
- version: S.Number;
243
- }, "Type"> | S.Struct.ReadonlySide<{
244
- readonly _tag: S.tag<"HoveredEntry">;
245
- entryId: S.String;
246
- }, "Type"> | S.Struct.ReadonlySide<{
247
- readonly _tag: S.tag<"LeftEntry">;
248
- entryId: S.String;
249
- }, "Type"> | S.Struct.ReadonlySide<{
250
- readonly _tag: S.tag<"GotAnimationMessage">;
251
- entryId: S.String;
252
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
253
- }, "Type"> | S.Struct.ReadonlySide<{
254
- readonly _tag: S.tag<"Added">;
255
- entry: S.Struct<{
256
- readonly id: S.String;
257
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
258
- readonly animation: S.Struct<{
259
- readonly id: S.String;
260
- readonly isShowing: S.Boolean;
261
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
262
- }>;
263
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
264
- readonly pendingDismissVersion: S.Number;
265
- readonly isHovered: S.Boolean;
266
- readonly payload: S.Codec<A, I, never, never>;
267
- }>;
268
- }, "Type">) => readonly [S.Struct.ReadonlySide<{
269
- readonly id: S.String;
270
- readonly defaultDuration: S.DurationFromMillis;
271
- readonly entries: S.$Array<S.Struct<{
272
- readonly id: S.String;
273
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
274
- readonly animation: S.Struct<{
275
- readonly id: S.String;
276
- readonly isShowing: S.Boolean;
277
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
278
- }>;
279
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
280
- readonly pendingDismissVersion: S.Number;
281
- readonly isHovered: S.Boolean;
282
- readonly payload: S.Codec<A, I, never, never>;
283
- }>>;
284
- readonly nextEntryKey: S.Number;
285
- }, "Type">, readonly Readonly<{
207
+ }>) => {
208
+ readonly id: string;
209
+ readonly defaultDuration: import("effect/Duration").Duration;
210
+ readonly entries: readonly {
211
+ readonly id: string;
212
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
213
+ readonly animation: {
214
+ readonly id: string;
215
+ readonly isShowing: boolean;
216
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
217
+ };
218
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
219
+ readonly pendingDismissVersion: number;
220
+ readonly isHovered: boolean;
221
+ readonly payload: A;
222
+ }[];
223
+ readonly nextEntryKey: number;
224
+ };
225
+ readonly update: (model: {
226
+ readonly id: string;
227
+ readonly defaultDuration: import("effect/Duration").Duration;
228
+ readonly entries: readonly {
229
+ readonly id: string;
230
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
231
+ readonly animation: {
232
+ readonly id: string;
233
+ readonly isShowing: boolean;
234
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
235
+ };
236
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
237
+ readonly pendingDismissVersion: number;
238
+ readonly isHovered: boolean;
239
+ readonly payload: A;
240
+ }[];
241
+ readonly nextEntryKey: number;
242
+ }, message: {
243
+ readonly _tag: "Dismissed";
244
+ readonly entryId: string;
245
+ } | {
246
+ readonly _tag: "DismissedAll";
247
+ } | {
248
+ readonly _tag: "ElapsedDuration";
249
+ readonly entryId: string;
250
+ readonly version: number;
251
+ } | {
252
+ readonly _tag: "HoveredEntry";
253
+ readonly entryId: string;
254
+ } | {
255
+ readonly _tag: "LeftEntry";
256
+ readonly entryId: string;
257
+ } | {
258
+ readonly _tag: "GotAnimationMessage";
259
+ readonly entryId: string;
260
+ readonly message: {
261
+ readonly _tag: "Showed";
262
+ } | {
263
+ readonly _tag: "Hid";
264
+ } | {
265
+ readonly _tag: "AdvancedAnimationFrame";
266
+ } | {
267
+ readonly _tag: "EndedAnimation";
268
+ };
269
+ } | {
270
+ readonly _tag: "Added";
271
+ readonly entry: {
272
+ readonly id: string;
273
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
274
+ readonly animation: {
275
+ readonly id: string;
276
+ readonly isShowing: boolean;
277
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
278
+ };
279
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
280
+ readonly pendingDismissVersion: number;
281
+ readonly isHovered: boolean;
282
+ readonly payload: A;
283
+ };
284
+ }) => readonly [{
285
+ readonly id: string;
286
+ readonly defaultDuration: import("effect/Duration").Duration;
287
+ readonly entries: readonly {
288
+ readonly id: string;
289
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
290
+ readonly animation: {
291
+ readonly id: string;
292
+ readonly isShowing: boolean;
293
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
294
+ };
295
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
296
+ readonly pendingDismissVersion: number;
297
+ readonly isHovered: boolean;
298
+ readonly payload: A;
299
+ }[];
300
+ readonly nextEntryKey: number;
301
+ }, readonly Readonly<{
286
302
  name: string;
287
303
  args?: Record<string, unknown>;
288
304
  key?: string;
289
- effect: import("effect/Effect").Effect<S.Struct.ReadonlySide<{
290
- readonly _tag: S.tag<"Dismissed">;
291
- entryId: S.String;
292
- }, "Type"> | S.Struct.ReadonlySide<{
293
- readonly _tag: S.tag<"DismissedAll">;
294
- }, "Type"> | S.Struct.ReadonlySide<{
295
- readonly _tag: S.tag<"ElapsedDuration">;
296
- entryId: S.String;
297
- version: S.Number;
298
- }, "Type"> | S.Struct.ReadonlySide<{
299
- readonly _tag: S.tag<"HoveredEntry">;
300
- entryId: S.String;
301
- }, "Type"> | S.Struct.ReadonlySide<{
302
- readonly _tag: S.tag<"LeftEntry">;
303
- entryId: S.String;
304
- }, "Type"> | S.Struct.ReadonlySide<{
305
- readonly _tag: S.tag<"GotAnimationMessage">;
306
- entryId: S.String;
307
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
308
- }, "Type"> | S.Struct.ReadonlySide<{
309
- readonly _tag: S.tag<"Added">;
310
- entry: S.Struct<{
311
- readonly id: S.String;
312
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
313
- readonly animation: S.Struct<{
314
- readonly id: S.String;
315
- readonly isShowing: S.Boolean;
316
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
317
- }>;
318
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
319
- readonly pendingDismissVersion: S.Number;
320
- readonly isHovered: S.Boolean;
321
- readonly payload: S.Codec<A, I, never, never>;
322
- }>;
323
- }, "Type">, never, never>;
324
- }>[], import("effect/Option").Option<S.Struct.ReadonlySide<{
325
- readonly _tag: S.tag<"DismissedToast">;
326
- payload: S.Codec<A, I, never, never>;
327
- }, "Type">>];
328
- readonly show: (model: S.Struct.ReadonlySide<{
329
- readonly id: S.String;
330
- readonly defaultDuration: S.DurationFromMillis;
331
- readonly entries: S.$Array<S.Struct<{
332
- readonly id: S.String;
333
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
334
- readonly animation: S.Struct<{
335
- readonly id: S.String;
336
- readonly isShowing: S.Boolean;
337
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
338
- }>;
339
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
340
- readonly pendingDismissVersion: S.Number;
341
- readonly isHovered: S.Boolean;
342
- readonly payload: S.Codec<A, I, never, never>;
343
- }>>;
344
- readonly nextEntryKey: S.Number;
345
- }, "Type">, input: Readonly<{
305
+ effect: import("effect/Effect").Effect<{
306
+ readonly _tag: "Dismissed";
307
+ readonly entryId: string;
308
+ } | {
309
+ readonly _tag: "DismissedAll";
310
+ } | {
311
+ readonly _tag: "ElapsedDuration";
312
+ readonly entryId: string;
313
+ readonly version: number;
314
+ } | {
315
+ readonly _tag: "HoveredEntry";
316
+ readonly entryId: string;
317
+ } | {
318
+ readonly _tag: "LeftEntry";
319
+ readonly entryId: string;
320
+ } | {
321
+ readonly _tag: "GotAnimationMessage";
322
+ readonly entryId: string;
323
+ readonly message: {
324
+ readonly _tag: "Showed";
325
+ } | {
326
+ readonly _tag: "Hid";
327
+ } | {
328
+ readonly _tag: "AdvancedAnimationFrame";
329
+ } | {
330
+ readonly _tag: "EndedAnimation";
331
+ };
332
+ } | {
333
+ readonly _tag: "Added";
334
+ readonly entry: {
335
+ readonly id: string;
336
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
337
+ readonly animation: {
338
+ readonly id: string;
339
+ readonly isShowing: boolean;
340
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
341
+ };
342
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
343
+ readonly pendingDismissVersion: number;
344
+ readonly isHovered: boolean;
345
+ readonly payload: A;
346
+ };
347
+ }, never, never>;
348
+ }>[], import("effect/Option").Option<{
349
+ readonly _tag: "DismissedToast";
350
+ readonly payload: A;
351
+ }>];
352
+ readonly show: (model: {
353
+ readonly id: string;
354
+ readonly defaultDuration: import("effect/Duration").Duration;
355
+ readonly entries: readonly {
356
+ readonly id: string;
357
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
358
+ readonly animation: {
359
+ readonly id: string;
360
+ readonly isShowing: boolean;
361
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
362
+ };
363
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
364
+ readonly pendingDismissVersion: number;
365
+ readonly isHovered: boolean;
366
+ readonly payload: A;
367
+ }[];
368
+ readonly nextEntryKey: number;
369
+ }, input: Readonly<{
346
370
  payload: A;
347
371
  variant?: Variant;
348
372
  duration?: import("effect/Duration").Input;
349
373
  sticky?: boolean;
350
- }>) => readonly [S.Struct.ReadonlySide<{
351
- readonly id: S.String;
352
- readonly defaultDuration: S.DurationFromMillis;
353
- readonly entries: S.$Array<S.Struct<{
354
- readonly id: S.String;
355
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
356
- readonly animation: S.Struct<{
357
- readonly id: S.String;
358
- readonly isShowing: S.Boolean;
359
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
360
- }>;
361
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
362
- readonly pendingDismissVersion: S.Number;
363
- readonly isHovered: S.Boolean;
364
- readonly payload: S.Codec<A, I, never, never>;
365
- }>>;
366
- readonly nextEntryKey: S.Number;
367
- }, "Type">, readonly Readonly<{
374
+ }>) => readonly [{
375
+ readonly id: string;
376
+ readonly defaultDuration: import("effect/Duration").Duration;
377
+ readonly entries: readonly {
378
+ readonly id: string;
379
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
380
+ readonly animation: {
381
+ readonly id: string;
382
+ readonly isShowing: boolean;
383
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
384
+ };
385
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
386
+ readonly pendingDismissVersion: number;
387
+ readonly isHovered: boolean;
388
+ readonly payload: A;
389
+ }[];
390
+ readonly nextEntryKey: number;
391
+ }, readonly Readonly<{
368
392
  name: string;
369
393
  args?: Record<string, unknown>;
370
394
  key?: string;
371
- effect: import("effect/Effect").Effect<S.Struct.ReadonlySide<{
372
- readonly _tag: S.tag<"Dismissed">;
373
- entryId: S.String;
374
- }, "Type"> | S.Struct.ReadonlySide<{
375
- readonly _tag: S.tag<"DismissedAll">;
376
- }, "Type"> | S.Struct.ReadonlySide<{
377
- readonly _tag: S.tag<"ElapsedDuration">;
378
- entryId: S.String;
379
- version: S.Number;
380
- }, "Type"> | S.Struct.ReadonlySide<{
381
- readonly _tag: S.tag<"HoveredEntry">;
382
- entryId: S.String;
383
- }, "Type"> | S.Struct.ReadonlySide<{
384
- readonly _tag: S.tag<"LeftEntry">;
385
- entryId: S.String;
386
- }, "Type"> | S.Struct.ReadonlySide<{
387
- readonly _tag: S.tag<"GotAnimationMessage">;
388
- entryId: S.String;
389
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
390
- }, "Type"> | S.Struct.ReadonlySide<{
391
- readonly _tag: S.tag<"Added">;
392
- entry: S.Struct<{
393
- readonly id: S.String;
394
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
395
- readonly animation: S.Struct<{
396
- readonly id: S.String;
397
- readonly isShowing: S.Boolean;
398
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
399
- }>;
400
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
401
- readonly pendingDismissVersion: S.Number;
402
- readonly isHovered: S.Boolean;
403
- readonly payload: S.Codec<A, I, never, never>;
404
- }>;
405
- }, "Type">, never, never>;
406
- }>[], import("effect/Option").Option<S.Struct.ReadonlySide<{
407
- readonly _tag: S.tag<"DismissedToast">;
408
- payload: S.Codec<A, I, never, never>;
409
- }, "Type">>];
410
- readonly dismiss: (model: S.Struct.ReadonlySide<{
411
- readonly id: S.String;
412
- readonly defaultDuration: S.DurationFromMillis;
413
- readonly entries: S.$Array<S.Struct<{
414
- readonly id: S.String;
415
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
416
- readonly animation: S.Struct<{
417
- readonly id: S.String;
418
- readonly isShowing: S.Boolean;
419
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
420
- }>;
421
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
422
- readonly pendingDismissVersion: S.Number;
423
- readonly isHovered: S.Boolean;
424
- readonly payload: S.Codec<A, I, never, never>;
425
- }>>;
426
- readonly nextEntryKey: S.Number;
427
- }, "Type">, entryId: string) => readonly [S.Struct.ReadonlySide<{
428
- readonly id: S.String;
429
- readonly defaultDuration: S.DurationFromMillis;
430
- readonly entries: S.$Array<S.Struct<{
431
- readonly id: S.String;
432
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
433
- readonly animation: S.Struct<{
434
- readonly id: S.String;
435
- readonly isShowing: S.Boolean;
436
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
437
- }>;
438
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
439
- readonly pendingDismissVersion: S.Number;
440
- readonly isHovered: S.Boolean;
441
- readonly payload: S.Codec<A, I, never, never>;
442
- }>>;
443
- readonly nextEntryKey: S.Number;
444
- }, "Type">, readonly Readonly<{
395
+ effect: import("effect/Effect").Effect<{
396
+ readonly _tag: "Dismissed";
397
+ readonly entryId: string;
398
+ } | {
399
+ readonly _tag: "DismissedAll";
400
+ } | {
401
+ readonly _tag: "ElapsedDuration";
402
+ readonly entryId: string;
403
+ readonly version: number;
404
+ } | {
405
+ readonly _tag: "HoveredEntry";
406
+ readonly entryId: string;
407
+ } | {
408
+ readonly _tag: "LeftEntry";
409
+ readonly entryId: string;
410
+ } | {
411
+ readonly _tag: "GotAnimationMessage";
412
+ readonly entryId: string;
413
+ readonly message: {
414
+ readonly _tag: "Showed";
415
+ } | {
416
+ readonly _tag: "Hid";
417
+ } | {
418
+ readonly _tag: "AdvancedAnimationFrame";
419
+ } | {
420
+ readonly _tag: "EndedAnimation";
421
+ };
422
+ } | {
423
+ readonly _tag: "Added";
424
+ readonly entry: {
425
+ readonly id: string;
426
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
427
+ readonly animation: {
428
+ readonly id: string;
429
+ readonly isShowing: boolean;
430
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
431
+ };
432
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
433
+ readonly pendingDismissVersion: number;
434
+ readonly isHovered: boolean;
435
+ readonly payload: A;
436
+ };
437
+ }, never, never>;
438
+ }>[], import("effect/Option").Option<{
439
+ readonly _tag: "DismissedToast";
440
+ readonly payload: A;
441
+ }>];
442
+ readonly dismiss: (model: {
443
+ readonly id: string;
444
+ readonly defaultDuration: import("effect/Duration").Duration;
445
+ readonly entries: readonly {
446
+ readonly id: string;
447
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
448
+ readonly animation: {
449
+ readonly id: string;
450
+ readonly isShowing: boolean;
451
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
452
+ };
453
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
454
+ readonly pendingDismissVersion: number;
455
+ readonly isHovered: boolean;
456
+ readonly payload: A;
457
+ }[];
458
+ readonly nextEntryKey: number;
459
+ }, entryId: string) => readonly [{
460
+ readonly id: string;
461
+ readonly defaultDuration: import("effect/Duration").Duration;
462
+ readonly entries: readonly {
463
+ readonly id: string;
464
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
465
+ readonly animation: {
466
+ readonly id: string;
467
+ readonly isShowing: boolean;
468
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
469
+ };
470
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
471
+ readonly pendingDismissVersion: number;
472
+ readonly isHovered: boolean;
473
+ readonly payload: A;
474
+ }[];
475
+ readonly nextEntryKey: number;
476
+ }, readonly Readonly<{
445
477
  name: string;
446
478
  args?: Record<string, unknown>;
447
479
  key?: string;
448
- effect: import("effect/Effect").Effect<S.Struct.ReadonlySide<{
449
- readonly _tag: S.tag<"Dismissed">;
450
- entryId: S.String;
451
- }, "Type"> | S.Struct.ReadonlySide<{
452
- readonly _tag: S.tag<"DismissedAll">;
453
- }, "Type"> | S.Struct.ReadonlySide<{
454
- readonly _tag: S.tag<"ElapsedDuration">;
455
- entryId: S.String;
456
- version: S.Number;
457
- }, "Type"> | S.Struct.ReadonlySide<{
458
- readonly _tag: S.tag<"HoveredEntry">;
459
- entryId: S.String;
460
- }, "Type"> | S.Struct.ReadonlySide<{
461
- readonly _tag: S.tag<"LeftEntry">;
462
- entryId: S.String;
463
- }, "Type"> | S.Struct.ReadonlySide<{
464
- readonly _tag: S.tag<"GotAnimationMessage">;
465
- entryId: S.String;
466
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
467
- }, "Type"> | S.Struct.ReadonlySide<{
468
- readonly _tag: S.tag<"Added">;
469
- entry: S.Struct<{
470
- readonly id: S.String;
471
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
472
- readonly animation: S.Struct<{
473
- readonly id: S.String;
474
- readonly isShowing: S.Boolean;
475
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
476
- }>;
477
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
478
- readonly pendingDismissVersion: S.Number;
479
- readonly isHovered: S.Boolean;
480
- readonly payload: S.Codec<A, I, never, never>;
481
- }>;
482
- }, "Type">, never, never>;
483
- }>[], import("effect/Option").Option<S.Struct.ReadonlySide<{
484
- readonly _tag: S.tag<"DismissedToast">;
485
- payload: S.Codec<A, I, never, never>;
486
- }, "Type">>];
487
- readonly dismissAll: (model: S.Struct.ReadonlySide<{
488
- readonly id: S.String;
489
- readonly defaultDuration: S.DurationFromMillis;
490
- readonly entries: S.$Array<S.Struct<{
491
- readonly id: S.String;
492
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
493
- readonly animation: S.Struct<{
494
- readonly id: S.String;
495
- readonly isShowing: S.Boolean;
496
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
497
- }>;
498
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
499
- readonly pendingDismissVersion: S.Number;
500
- readonly isHovered: S.Boolean;
501
- readonly payload: S.Codec<A, I, never, never>;
502
- }>>;
503
- readonly nextEntryKey: S.Number;
504
- }, "Type">) => readonly [S.Struct.ReadonlySide<{
505
- readonly id: S.String;
506
- readonly defaultDuration: S.DurationFromMillis;
507
- readonly entries: S.$Array<S.Struct<{
508
- readonly id: S.String;
509
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
510
- readonly animation: S.Struct<{
511
- readonly id: S.String;
512
- readonly isShowing: S.Boolean;
513
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
514
- }>;
515
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
516
- readonly pendingDismissVersion: S.Number;
517
- readonly isHovered: S.Boolean;
518
- readonly payload: S.Codec<A, I, never, never>;
519
- }>>;
520
- readonly nextEntryKey: S.Number;
521
- }, "Type">, readonly Readonly<{
480
+ effect: import("effect/Effect").Effect<{
481
+ readonly _tag: "Dismissed";
482
+ readonly entryId: string;
483
+ } | {
484
+ readonly _tag: "DismissedAll";
485
+ } | {
486
+ readonly _tag: "ElapsedDuration";
487
+ readonly entryId: string;
488
+ readonly version: number;
489
+ } | {
490
+ readonly _tag: "HoveredEntry";
491
+ readonly entryId: string;
492
+ } | {
493
+ readonly _tag: "LeftEntry";
494
+ readonly entryId: string;
495
+ } | {
496
+ readonly _tag: "GotAnimationMessage";
497
+ readonly entryId: string;
498
+ readonly message: {
499
+ readonly _tag: "Showed";
500
+ } | {
501
+ readonly _tag: "Hid";
502
+ } | {
503
+ readonly _tag: "AdvancedAnimationFrame";
504
+ } | {
505
+ readonly _tag: "EndedAnimation";
506
+ };
507
+ } | {
508
+ readonly _tag: "Added";
509
+ readonly entry: {
510
+ readonly id: string;
511
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
512
+ readonly animation: {
513
+ readonly id: string;
514
+ readonly isShowing: boolean;
515
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
516
+ };
517
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
518
+ readonly pendingDismissVersion: number;
519
+ readonly isHovered: boolean;
520
+ readonly payload: A;
521
+ };
522
+ }, never, never>;
523
+ }>[], import("effect/Option").Option<{
524
+ readonly _tag: "DismissedToast";
525
+ readonly payload: A;
526
+ }>];
527
+ readonly dismissAll: (model: {
528
+ readonly id: string;
529
+ readonly defaultDuration: import("effect/Duration").Duration;
530
+ readonly entries: readonly {
531
+ readonly id: string;
532
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
533
+ readonly animation: {
534
+ readonly id: string;
535
+ readonly isShowing: boolean;
536
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
537
+ };
538
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
539
+ readonly pendingDismissVersion: number;
540
+ readonly isHovered: boolean;
541
+ readonly payload: A;
542
+ }[];
543
+ readonly nextEntryKey: number;
544
+ }) => readonly [{
545
+ readonly id: string;
546
+ readonly defaultDuration: import("effect/Duration").Duration;
547
+ readonly entries: readonly {
548
+ readonly id: string;
549
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
550
+ readonly animation: {
551
+ readonly id: string;
552
+ readonly isShowing: boolean;
553
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
554
+ };
555
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
556
+ readonly pendingDismissVersion: number;
557
+ readonly isHovered: boolean;
558
+ readonly payload: A;
559
+ }[];
560
+ readonly nextEntryKey: number;
561
+ }, readonly Readonly<{
522
562
  name: string;
523
563
  args?: Record<string, unknown>;
524
564
  key?: string;
525
- effect: import("effect/Effect").Effect<S.Struct.ReadonlySide<{
526
- readonly _tag: S.tag<"Dismissed">;
527
- entryId: S.String;
528
- }, "Type"> | S.Struct.ReadonlySide<{
529
- readonly _tag: S.tag<"DismissedAll">;
530
- }, "Type"> | S.Struct.ReadonlySide<{
531
- readonly _tag: S.tag<"ElapsedDuration">;
532
- entryId: S.String;
533
- version: S.Number;
534
- }, "Type"> | S.Struct.ReadonlySide<{
535
- readonly _tag: S.tag<"HoveredEntry">;
536
- entryId: S.String;
537
- }, "Type"> | S.Struct.ReadonlySide<{
538
- readonly _tag: S.tag<"LeftEntry">;
539
- entryId: S.String;
540
- }, "Type"> | S.Struct.ReadonlySide<{
541
- readonly _tag: S.tag<"GotAnimationMessage">;
542
- entryId: S.String;
543
- message: S.Union<[import("foldkit/schema").CallableTaggedStruct<"Showed", {}>, import("foldkit/schema").CallableTaggedStruct<"Hid", {}>, import("foldkit/schema").CallableTaggedStruct<"AdvancedAnimationFrame", {}>, import("foldkit/schema").CallableTaggedStruct<"EndedAnimation", {}>]>;
544
- }, "Type"> | S.Struct.ReadonlySide<{
545
- readonly _tag: S.tag<"Added">;
546
- entry: S.Struct<{
547
- readonly id: S.String;
548
- readonly variant: S.Literals<readonly ["Info", "Success", "Warning", "Error"]>;
549
- readonly animation: S.Struct<{
550
- readonly id: S.String;
551
- readonly isShowing: S.Boolean;
552
- readonly transitionState: S.Literals<readonly ["Idle", "EnterStart", "EnterAnimating", "LeaveStart", "LeaveAnimating"]>;
553
- }>;
554
- readonly maybeDuration: S.Option<S.DurationFromMillis>;
555
- readonly pendingDismissVersion: S.Number;
556
- readonly isHovered: S.Boolean;
557
- readonly payload: S.Codec<A, I, never, never>;
558
- }>;
559
- }, "Type">, never, never>;
560
- }>[], import("effect/Option").Option<S.Struct.ReadonlySide<{
561
- readonly _tag: S.tag<"DismissedToast">;
562
- payload: S.Codec<A, I, never, never>;
563
- }, "Type">>];
565
+ effect: import("effect/Effect").Effect<{
566
+ readonly _tag: "Dismissed";
567
+ readonly entryId: string;
568
+ } | {
569
+ readonly _tag: "DismissedAll";
570
+ } | {
571
+ readonly _tag: "ElapsedDuration";
572
+ readonly entryId: string;
573
+ readonly version: number;
574
+ } | {
575
+ readonly _tag: "HoveredEntry";
576
+ readonly entryId: string;
577
+ } | {
578
+ readonly _tag: "LeftEntry";
579
+ readonly entryId: string;
580
+ } | {
581
+ readonly _tag: "GotAnimationMessage";
582
+ readonly entryId: string;
583
+ readonly message: {
584
+ readonly _tag: "Showed";
585
+ } | {
586
+ readonly _tag: "Hid";
587
+ } | {
588
+ readonly _tag: "AdvancedAnimationFrame";
589
+ } | {
590
+ readonly _tag: "EndedAnimation";
591
+ };
592
+ } | {
593
+ readonly _tag: "Added";
594
+ readonly entry: {
595
+ readonly id: string;
596
+ readonly variant: "Error" | "Info" | "Success" | "Warning";
597
+ readonly animation: {
598
+ readonly id: string;
599
+ readonly isShowing: boolean;
600
+ readonly transitionState: "Idle" | "EnterStart" | "EnterAnimating" | "LeaveStart" | "LeaveAnimating";
601
+ };
602
+ readonly maybeDuration: import("effect/Option").Option<import("effect/Duration").Duration>;
603
+ readonly pendingDismissVersion: number;
604
+ readonly isHovered: boolean;
605
+ readonly payload: A;
606
+ };
607
+ }, never, never>;
608
+ }>[], import("effect/Option").Option<{
609
+ readonly _tag: "DismissedToast";
610
+ readonly payload: A;
611
+ }>];
564
612
  };
565
613
  //# sourceMappingURL=index.d.ts.map