@anzusystems/common-admin 1.47.0-beta.359 → 1.47.0-beta.360

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/labs.d.ts CHANGED
@@ -88,6 +88,18 @@ declare type __VLS_PrettifyLocal_3<T> = {
88
88
  [K in keyof T]: T[K];
89
89
  } & {};
90
90
 
91
+ declare type __VLS_PrettifyLocal_4<T> = {
92
+ [K in keyof T]: T[K];
93
+ } & {};
94
+
95
+ declare type __VLS_PrettifyLocal_5<T> = {
96
+ [K in keyof T]: T[K];
97
+ } & {};
98
+
99
+ declare type __VLS_PrettifyLocal_6<T> = {
100
+ [K in keyof T]: T[K];
101
+ } & {};
102
+
91
103
  declare type __VLS_Props = {
92
104
  enableTop?: boolean;
93
105
  hideButtons?: boolean;
@@ -110,6 +122,8 @@ declare type __VLS_Props_11 = {
110
122
  hideRecordsPerPage?: boolean;
111
123
  };
112
124
 
125
+ declare type __VLS_Props_12 = Props_4;
126
+
113
127
  declare type __VLS_Props_2 = {
114
128
  hideButtons?: boolean;
115
129
  formName?: string;
@@ -183,6 +197,10 @@ declare type __VLS_PublicProps_3 = {
183
197
  'modelValue'?: number;
184
198
  } & __VLS_Props_10;
185
199
 
200
+ declare type __VLS_PublicProps_4 = {
201
+ modelValue: boolean;
202
+ } & __VLS_Props_12;
203
+
186
204
  declare function __VLS_template(): {
187
205
  attrs: Partial<{}>;
188
206
  slots: Partial<Record<string, (_: {
@@ -266,6 +284,39 @@ itemsPerPageOptions: number[];
266
284
  hideRecordsPerPage: boolean;
267
285
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
268
286
 
287
+ declare interface AddButtonSlotProps {
288
+ readonly: boolean;
289
+ disabled: boolean;
290
+ props: {
291
+ onClick: () => void;
292
+ };
293
+ actions: {
294
+ add: () => void;
295
+ };
296
+ }
297
+
298
+ declare interface AddButtonSlotProps_2 {
299
+ readonly: boolean;
300
+ disabled: boolean;
301
+ props: {
302
+ onClick: () => void;
303
+ };
304
+ actions: {
305
+ add: () => void;
306
+ };
307
+ }
308
+
309
+ declare interface AddButtonSlotProps_3 {
310
+ readonly: boolean;
311
+ disabled: boolean;
312
+ props: {
313
+ onClick: () => void;
314
+ };
315
+ actions: {
316
+ add: () => void;
317
+ };
318
+ }
319
+
269
320
  export declare const AFilterBooleanSelect: DefineComponent<__VLS_Props_3, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
270
321
  change: () => any;
271
322
  }, string, PublicProps, Readonly<__VLS_Props_3> & Readonly<{
@@ -410,8 +461,158 @@ export declare const AFormRemoteAutocomplete: <T extends string | number>(__VLS_
410
461
  __ctx?: Awaited<typeof __VLS_setup>;
411
462
  };
412
463
 
464
+ export declare const AListEditor: <TItem extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal_4<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
465
+ props: __VLS_PrettifyLocal_4<Pick<Partial<{}> & Omit<{
466
+ readonly onDeleted?: ((item: ListViewItem<TItem>) => any) | undefined;
467
+ readonly onClose?: ((item: ListViewItem<TItem>) => any) | undefined;
468
+ readonly onEdit?: ((item: ListViewItem<TItem>) => any) | undefined;
469
+ readonly onAdd?: ((positionHint: PositionHint | undefined) => any) | undefined;
470
+ readonly "onUpdate:modelValue"?: ((value: TItem[]) => any) | undefined;
471
+ readonly "onUpdate:unsavedKeys"?: ((value: Set<ListEditorKey>) => any) | undefined;
472
+ readonly "onItem-saved"?: ((item: ListViewItem<TItem>) => any) | undefined;
473
+ readonly "onItem-expand"?: ((item: ListViewItem<TItem>, expanded: boolean) => any) | undefined;
474
+ } & VNodeProps & AllowedComponentProps & ComponentCustomProps, never>, "onUpdate:modelValue" | "onClose" | "onEdit" | "onAdd" | "onDeleted" | "onUpdate:unsavedKeys" | "onItem-saved" | "onItem-expand"> & ({
475
+ modelValue: TItem[];
476
+ unsavedKeys?: Set<ListEditorKey>;
477
+ } & Props<TItem>) & Partial<{}>> & PublicProps;
478
+ expose(exposed: ShallowUnwrapRef< {
479
+ addItem: (data: TItem, positionHint?: PositionHint) => TItem[];
480
+ deleteItem: (idOrItem: ListEditorKey | TItem) => TItem[];
481
+ updateItem: (idOrItem: ListEditorKey | TItem, data: TItem) => TItem[];
482
+ moveItem: (fromIndex: number, toIndex: number) => TItem[];
483
+ recalculatePositions: (items: TItem[]) => TItem[];
484
+ viewItems: ComputedRef<ListViewItem<TItem>[]>;
485
+ resetDirtyBaseline: () => void;
486
+ hasUnsavedChanges: ComputedRef<boolean>;
487
+ unsavedCount: ComputedRef<number>;
488
+ clearUnsavedState: (key?: ListEditorKey) => void;
489
+ }>): void;
490
+ attrs: any;
491
+ slots: Readonly<{
492
+ header?: (props: HeaderSlotProps) => unknown;
493
+ empty?: (props: EmptySlotProps) => unknown;
494
+ 'add-button'?: (props: AddButtonSlotProps) => unknown;
495
+ item?: (props: RowSlotProps<TItem>) => unknown;
496
+ 'item-compact'?: (props: RowSlotProps<TItem>) => unknown;
497
+ 'item-readonly'?: (props: RowSlotProps<TItem>) => unknown;
498
+ 'item-status'?: (props: RowSlotProps<TItem>) => unknown;
499
+ 'item-actions'?: (props: RowSlotProps<TItem>) => unknown;
500
+ 'item-footer'?: (props: RowSlotProps<TItem>) => unknown;
501
+ 'before-item'?: (props: RowSlotProps<TItem>) => unknown;
502
+ 'after-item'?: (props: RowSlotProps<TItem>) => unknown;
503
+ }> & {
504
+ header?: (props: HeaderSlotProps) => unknown;
505
+ empty?: (props: EmptySlotProps) => unknown;
506
+ 'add-button'?: (props: AddButtonSlotProps) => unknown;
507
+ item?: (props: RowSlotProps<TItem>) => unknown;
508
+ 'item-compact'?: (props: RowSlotProps<TItem>) => unknown;
509
+ 'item-readonly'?: (props: RowSlotProps<TItem>) => unknown;
510
+ 'item-status'?: (props: RowSlotProps<TItem>) => unknown;
511
+ 'item-actions'?: (props: RowSlotProps<TItem>) => unknown;
512
+ 'item-footer'?: (props: RowSlotProps<TItem>) => unknown;
513
+ 'before-item'?: (props: RowSlotProps<TItem>) => unknown;
514
+ 'after-item'?: (props: RowSlotProps<TItem>) => unknown;
515
+ };
516
+ emit: (((evt: "deleted", item: ListViewItem<TItem>) => void) & ((evt: "close", item: ListViewItem<TItem>) => void) & ((evt: "edit", item: ListViewItem<TItem>) => void) & ((evt: "add", positionHint: PositionHint | undefined) => void) & ((evt: "item-saved", item: ListViewItem<TItem>) => void) & ((evt: "item-expand", item: ListViewItem<TItem>, expanded: boolean) => void)) & (((evt: "update:modelValue", value: TItem[]) => void) & ((evt: "update:unsavedKeys", value: Set<ListEditorKey>) => void));
517
+ }>) => VNode & {
518
+ __ctx?: Awaited<typeof __VLS_setup>;
519
+ };
520
+
413
521
  declare type AllowedFilterValues = number | number[] | string | string[] | null | undefined | boolean;
414
522
 
523
+ export declare const ANestedSortableListEditor: <TItem extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal_6<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
524
+ props: __VLS_PrettifyLocal_6<Pick<Partial<{}> & Omit<{
525
+ readonly onDeleted?: ((item: NestedViewItem<TItem>) => any) | undefined;
526
+ readonly onClose?: ((item: NestedViewItem<TItem>) => any) | undefined;
527
+ readonly onEdit?: ((item: NestedViewItem<TItem>) => any) | undefined;
528
+ readonly onAdd?: ((hint: NestedPositionHint | undefined) => any) | undefined;
529
+ readonly onIndent?: ((item: NestedViewItem<TItem>) => any) | undefined;
530
+ readonly onOutdent?: ((item: NestedViewItem<TItem>) => any) | undefined;
531
+ readonly "onUpdate:modelValue"?: ((value: NestedTree<TItem>) => any) | undefined;
532
+ readonly "onUpdate:mode"?: ((value: ReorderMode_2) => any) | undefined;
533
+ readonly "onUpdate:unsavedKeys"?: ((value: Set<ListEditorKey>) => any) | undefined;
534
+ readonly "onItem-saved"?: ((item: NestedViewItem<TItem>) => any) | undefined;
535
+ readonly "onItem-expand"?: ((item: NestedViewItem<TItem>, expanded: boolean) => any) | undefined;
536
+ readonly "onReorder-start"?: (() => any) | undefined;
537
+ readonly "onReorder-cancel"?: (() => any) | undefined;
538
+ readonly "onReorder-applied"?: ((tree: NestedTree<TItem>) => any) | undefined;
539
+ readonly "onReorder-apply-error"?: ((error: unknown) => any) | undefined;
540
+ readonly "onReorder-end"?: (() => any) | undefined;
541
+ readonly "onAdd-child"?: ((parent: NestedViewItem<TItem>) => any) | undefined;
542
+ } & VNodeProps & AllowedComponentProps & ComponentCustomProps, never>, "onUpdate:modelValue" | "onClose" | "onUpdate:mode" | "onEdit" | "onAdd" | "onDeleted" | "onUpdate:unsavedKeys" | "onItem-saved" | "onItem-expand" | "onReorder-start" | "onReorder-cancel" | "onReorder-applied" | "onReorder-apply-error" | "onReorder-end" | "onIndent" | "onOutdent" | "onAdd-child"> & ({
543
+ modelValue: NestedTree<TItem>;
544
+ mode?: ReorderMode_2;
545
+ unsavedKeys?: Set<ListEditorKey>;
546
+ } & Props_3<TItem>) & Partial<{}>> & PublicProps;
547
+ expose(exposed: ShallowUnwrapRef< {
548
+ addItem: (data: TItem, hint?: PositionHint & {
549
+ parentId?: ListEditorKey | null;
550
+ asFirstChild?: boolean;
551
+ childrenAllowed?: boolean;
552
+ }) => NestedTree<TItem>;
553
+ addAfterId: (targetId: ListEditorKey | null, data: TItem, childrenAllowed: boolean) => NestedTree<TItem>;
554
+ addChildToId: (targetId: ListEditorKey, data: TItem, childrenAllowed: boolean) => NestedTree<TItem>;
555
+ removeById: (id: ListEditorKey) => void;
556
+ updateData: (id: ListEditorKey, data: TItem, _children?: unknown, _position?: unknown, _markUnsaved?: unknown) => void;
557
+ updateItem: (id: ListEditorKey, data: TItem) => NestedTree<TItem>;
558
+ deleteItem: (id: ListEditorKey) => NestedTree<TItem>;
559
+ moveUp: (id: ListEditorKey) => NestedTree<TItem> | null;
560
+ moveDown: (id: ListEditorKey) => NestedTree<TItem> | null;
561
+ moveTop: (id: ListEditorKey) => NestedTree<TItem> | null;
562
+ moveBottom: (id: ListEditorKey) => NestedTree<TItem> | null;
563
+ indent: (id: ListEditorKey) => NestedTree<TItem> | null;
564
+ outdent: (id: ListEditorKey) => NestedTree<TItem> | null;
565
+ moveTo: (id: ListEditorKey, targetParentId: ListEditorKey | null, targetIndex: number) => NestedTree<TItem> | null;
566
+ recalculatePositions: (model: NestedTree<TItem>) => NestedTree<TItem>;
567
+ viewItems: ComputedRef<NestedViewItem<TItem>[]>;
568
+ resetDirtyBaseline: () => void;
569
+ hasUnsavedChanges: ComputedRef<boolean>;
570
+ unsavedCount: ComputedRef<number>;
571
+ clearUnsavedState: (key?: ListEditorKey) => void;
572
+ enterReorderMode: () => void;
573
+ cancelReorderMode: () => void;
574
+ applyReorder: () => Promise<void>;
575
+ expand: (id: ListEditorKey) => Set<ListEditorKey> & Omit<Set<ListEditorKey>, keyof Set<any>>;
576
+ collapse: (id: ListEditorKey) => boolean;
577
+ toggleExpand: (id: ListEditorKey) => void;
578
+ expandDetail: (id: ListEditorKey) => Set<ListEditorKey> & Omit<Set<ListEditorKey>, keyof Set<any>>;
579
+ collapseDetail: (id: ListEditorKey) => boolean;
580
+ }>): void;
581
+ attrs: any;
582
+ slots: Readonly<{
583
+ header?: (props: HeaderSlotProps_3) => unknown;
584
+ 'reorder-toggle'?: (props: ReorderToggleSlotProps_2) => unknown;
585
+ 'reorder-toolbar'?: (props: ToolbarSlotProps_2) => unknown;
586
+ empty?: (props: EmptySlotProps_3) => unknown;
587
+ 'add-button'?: (props: AddButtonSlotProps_3) => unknown;
588
+ item?: (props: RowSlotProps_3<TItem>) => unknown;
589
+ 'item-compact'?: (props: RowSlotProps_3<TItem>) => unknown;
590
+ 'item-readonly'?: (props: RowSlotProps_3<TItem>) => unknown;
591
+ 'item-status'?: (props: RowSlotProps_3<TItem>) => unknown;
592
+ 'item-footer'?: (props: RowSlotProps_3<TItem>) => unknown;
593
+ 'item-actions'?: (props: RowSlotProps_3<TItem>) => unknown;
594
+ 'before-item'?: (props: RowSlotProps_3<TItem>) => unknown;
595
+ 'after-item'?: (props: RowSlotProps_3<TItem>) => unknown;
596
+ }> & {
597
+ header?: (props: HeaderSlotProps_3) => unknown;
598
+ 'reorder-toggle'?: (props: ReorderToggleSlotProps_2) => unknown;
599
+ 'reorder-toolbar'?: (props: ToolbarSlotProps_2) => unknown;
600
+ empty?: (props: EmptySlotProps_3) => unknown;
601
+ 'add-button'?: (props: AddButtonSlotProps_3) => unknown;
602
+ item?: (props: RowSlotProps_3<TItem>) => unknown;
603
+ 'item-compact'?: (props: RowSlotProps_3<TItem>) => unknown;
604
+ 'item-readonly'?: (props: RowSlotProps_3<TItem>) => unknown;
605
+ 'item-status'?: (props: RowSlotProps_3<TItem>) => unknown;
606
+ 'item-footer'?: (props: RowSlotProps_3<TItem>) => unknown;
607
+ 'item-actions'?: (props: RowSlotProps_3<TItem>) => unknown;
608
+ 'before-item'?: (props: RowSlotProps_3<TItem>) => unknown;
609
+ 'after-item'?: (props: RowSlotProps_3<TItem>) => unknown;
610
+ };
611
+ emit: (((evt: "deleted", item: NestedViewItem<TItem>) => void) & ((evt: "close", item: NestedViewItem<TItem>) => void) & ((evt: "edit", item: NestedViewItem<TItem>) => void) & ((evt: "add", hint: NestedPositionHint | undefined) => void) & ((evt: "indent", item: NestedViewItem<TItem>) => void) & ((evt: "outdent", item: NestedViewItem<TItem>) => void) & ((evt: "item-saved", item: NestedViewItem<TItem>) => void) & ((evt: "item-expand", item: NestedViewItem<TItem>, expanded: boolean) => void) & ((evt: "reorder-start") => void) & ((evt: "reorder-cancel") => void) & ((evt: "reorder-applied", tree: NestedTree<TItem>) => void) & ((evt: "reorder-apply-error", error: unknown) => void) & ((evt: "reorder-end") => void) & ((evt: "add-child", parent: NestedViewItem<TItem>) => void)) & (((evt: "update:modelValue", value: NestedTree<TItem>) => void) & ((evt: "update:mode", value: ReorderMode_2) => void) & ((evt: "update:unsavedKeys", value: Set<ListEditorKey>) => void));
612
+ }>) => VNode & {
613
+ __ctx?: Awaited<typeof __VLS_setup>;
614
+ };
615
+
415
616
  declare interface AnzuUserAndTimeTrackingAware extends CreatedByAware {
416
617
  createdAt: DatetimeUTC;
417
618
  modifiedAt: DatetimeUTC;
@@ -422,6 +623,77 @@ declare interface AnzuUserMinimal extends BaseUser {
422
623
  id: IntegerId;
423
624
  }
424
625
 
626
+ export declare const ASortableListEditor: <TItem extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal_5<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
627
+ props: __VLS_PrettifyLocal_5<Pick<Partial<{}> & Omit<{
628
+ readonly onDeleted?: ((item: ListViewItem<TItem>) => any) | undefined;
629
+ readonly onClose?: ((item: ListViewItem<TItem>) => any) | undefined;
630
+ readonly onEdit?: ((item: ListViewItem<TItem>) => any) | undefined;
631
+ readonly onAdd?: ((positionHint: PositionHint | undefined) => any) | undefined;
632
+ readonly "onUpdate:modelValue"?: ((value: TItem[]) => any) | undefined;
633
+ readonly "onUpdate:mode"?: ((value: ReorderMode) => any) | undefined;
634
+ readonly "onUpdate:unsavedKeys"?: ((value: Set<ListEditorKey>) => any) | undefined;
635
+ readonly "onItem-saved"?: ((item: ListViewItem<TItem>) => any) | undefined;
636
+ readonly "onItem-expand"?: ((item: ListViewItem<TItem>, expanded: boolean) => any) | undefined;
637
+ readonly "onReorder-start"?: (() => any) | undefined;
638
+ readonly "onReorder-cancel"?: (() => any) | undefined;
639
+ readonly "onReorder-applied"?: ((items: TItem[]) => any) | undefined;
640
+ readonly "onReorder-apply-error"?: ((error: unknown) => any) | undefined;
641
+ readonly "onReorder-end"?: (() => any) | undefined;
642
+ } & VNodeProps & AllowedComponentProps & ComponentCustomProps, never>, "onUpdate:modelValue" | "onClose" | "onUpdate:mode" | "onEdit" | "onAdd" | "onDeleted" | "onUpdate:unsavedKeys" | "onItem-saved" | "onItem-expand" | "onReorder-start" | "onReorder-cancel" | "onReorder-applied" | "onReorder-apply-error" | "onReorder-end"> & ({
643
+ modelValue: TItem[];
644
+ mode?: ReorderMode;
645
+ unsavedKeys?: Set<ListEditorKey>;
646
+ } & Props_2<TItem>) & Partial<{}>> & PublicProps;
647
+ expose(exposed: ShallowUnwrapRef< {
648
+ addItem: (data: TItem, positionHint?: PositionHint) => TItem[];
649
+ deleteItem: (idOrItem: ListEditorKey | TItem) => TItem[];
650
+ updateItem: (idOrItem: ListEditorKey | TItem, data: TItem) => TItem[];
651
+ moveItem: (fromIndex: number, toIndex: number) => TItem[];
652
+ recalculatePositions: (items: TItem[]) => TItem[];
653
+ viewItems: ComputedRef<ListViewItem<TItem>[]>;
654
+ resetDirtyBaseline: () => void;
655
+ hasUnsavedChanges: ComputedRef<boolean>;
656
+ unsavedCount: ComputedRef<number>;
657
+ clearUnsavedState: (key?: ListEditorKey) => void;
658
+ enterReorderMode: () => void;
659
+ cancelReorderMode: () => void;
660
+ applyReorder: () => Promise<void>;
661
+ }>): void;
662
+ attrs: any;
663
+ slots: Readonly<{
664
+ header?: (props: HeaderSlotProps_2) => unknown;
665
+ 'reorder-toggle'?: (props: ReorderToggleSlotProps) => unknown;
666
+ 'reorder-toolbar'?: (props: ToolbarSlotProps) => unknown;
667
+ empty?: (props: EmptySlotProps_2) => unknown;
668
+ 'add-button'?: (props: AddButtonSlotProps_2) => unknown;
669
+ item?: (props: RowSlotProps_2<TItem>) => unknown;
670
+ 'item-compact'?: (props: RowSlotProps_2<TItem>) => unknown;
671
+ 'item-readonly'?: (props: RowSlotProps_2<TItem>) => unknown;
672
+ 'item-status'?: (props: RowSlotProps_2<TItem>) => unknown;
673
+ 'item-actions'?: (props: RowSlotProps_2<TItem>) => unknown;
674
+ 'item-footer'?: (props: RowSlotProps_2<TItem>) => unknown;
675
+ 'before-item'?: (props: RowSlotProps_2<TItem>) => unknown;
676
+ 'after-item'?: (props: RowSlotProps_2<TItem>) => unknown;
677
+ }> & {
678
+ header?: (props: HeaderSlotProps_2) => unknown;
679
+ 'reorder-toggle'?: (props: ReorderToggleSlotProps) => unknown;
680
+ 'reorder-toolbar'?: (props: ToolbarSlotProps) => unknown;
681
+ empty?: (props: EmptySlotProps_2) => unknown;
682
+ 'add-button'?: (props: AddButtonSlotProps_2) => unknown;
683
+ item?: (props: RowSlotProps_2<TItem>) => unknown;
684
+ 'item-compact'?: (props: RowSlotProps_2<TItem>) => unknown;
685
+ 'item-readonly'?: (props: RowSlotProps_2<TItem>) => unknown;
686
+ 'item-status'?: (props: RowSlotProps_2<TItem>) => unknown;
687
+ 'item-actions'?: (props: RowSlotProps_2<TItem>) => unknown;
688
+ 'item-footer'?: (props: RowSlotProps_2<TItem>) => unknown;
689
+ 'before-item'?: (props: RowSlotProps_2<TItem>) => unknown;
690
+ 'after-item'?: (props: RowSlotProps_2<TItem>) => unknown;
691
+ };
692
+ emit: (((evt: "deleted", item: ListViewItem<TItem>) => void) & ((evt: "close", item: ListViewItem<TItem>) => void) & ((evt: "edit", item: ListViewItem<TItem>) => void) & ((evt: "add", positionHint: PositionHint | undefined) => void) & ((evt: "item-saved", item: ListViewItem<TItem>) => void) & ((evt: "item-expand", item: ListViewItem<TItem>, expanded: boolean) => void) & ((evt: "reorder-start") => void) & ((evt: "reorder-cancel") => void) & ((evt: "reorder-applied", items: TItem[]) => void) & ((evt: "reorder-apply-error", error: unknown) => void) & ((evt: "reorder-end") => void)) & (((evt: "update:modelValue", value: TItem[]) => void) & ((evt: "update:mode", value: ReorderMode) => void) & ((evt: "update:unsavedKeys", value: Set<ListEditorKey>) => void));
693
+ }>) => VNode & {
694
+ __ctx?: Awaited<typeof __VLS_setup>;
695
+ };
696
+
425
697
  export declare const ASubjectSelect: <TItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal_3<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
426
698
  props: __VLS_PrettifyLocal_3<Pick<Partial<{}> & Omit<{
427
699
  readonly "onUpdate:modelValue"?: ((data: boolean) => any) | undefined;
@@ -473,6 +745,19 @@ export declare const ASubjectSelect: <TItem>(__VLS_props: NonNullable<Awaited<ty
473
745
  __ctx?: Awaited<typeof __VLS_setup>;
474
746
  };
475
747
 
748
+ export declare const AUnsavedConfirmDialog: DefineComponent<__VLS_PublicProps_4, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
749
+ "update:modelValue": (value: boolean) => any;
750
+ resolve: (discard: boolean) => any;
751
+ }, string, PublicProps, Readonly<__VLS_PublicProps_4> & Readonly<{
752
+ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
753
+ onResolve?: ((discard: boolean) => any) | undefined;
754
+ }>, {
755
+ title: string;
756
+ body: string;
757
+ stayLabel: string;
758
+ discardLabel: string;
759
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
760
+
476
761
  export declare type AxiosClientFn = () => AxiosInstance;
477
762
 
478
763
  declare interface BaseUser {
@@ -569,11 +854,63 @@ declare type DatetimeUTC = string;
569
854
  */
570
855
  declare type DatetimeUTCNullable = string | null;
571
856
 
857
+ declare interface DecoratedNestedViewItem<T> extends NestedViewItem<T> {
858
+ editing: boolean;
859
+ expanded: boolean;
860
+ childrenExpanded: boolean;
861
+ loading: boolean;
862
+ dirty: boolean;
863
+ moved: boolean;
864
+ unsaved: boolean;
865
+ }
866
+
867
+ declare interface DecoratedViewItem<T> extends ListViewItem<T> {
868
+ editing: boolean;
869
+ expanded: boolean;
870
+ loading: boolean;
871
+ dirty: boolean;
872
+ }
873
+
874
+ declare interface DecoratedViewItem_2<T> extends ListViewItem<T> {
875
+ editing: boolean;
876
+ expanded: boolean;
877
+ loading: boolean;
878
+ dirty: boolean;
879
+ moved: boolean;
880
+ unsaved: boolean;
881
+ canMoveUp: boolean;
882
+ canMoveDown: boolean;
883
+ }
884
+
572
885
  /**
573
886
  * UUID v4 as string.
574
887
  */
575
888
  declare type DocId = string;
576
889
 
890
+ declare interface EmptySlotProps {
891
+ readonly: boolean;
892
+ disabled: boolean;
893
+ actions: {
894
+ add: () => void;
895
+ };
896
+ }
897
+
898
+ declare interface EmptySlotProps_2 {
899
+ readonly: boolean;
900
+ disabled: boolean;
901
+ actions: {
902
+ add: () => void;
903
+ };
904
+ }
905
+
906
+ declare interface EmptySlotProps_3 {
907
+ readonly: boolean;
908
+ disabled: boolean;
909
+ actions: {
910
+ add: () => void;
911
+ };
912
+ }
913
+
577
914
  declare type ExecuteRequestParams<T> = {
578
915
  urlTemplate?: string;
579
916
  urlParams?: UrlParams;
@@ -680,6 +1017,18 @@ declare interface GeneralFilterOptions {
680
1017
 
681
1018
  export declare const generateListQuery: (pagination: Ref<Pagination>, filterData: FilterData<any>, filterConfig: FilterConfig<any>) => string;
682
1019
 
1020
+ declare interface HeaderSlotProps {
1021
+ title: string | null;
1022
+ }
1023
+
1024
+ declare interface HeaderSlotProps_2 extends ReorderToggleSlotProps {
1025
+ title: string | null;
1026
+ }
1027
+
1028
+ declare interface HeaderSlotProps_3 extends ReorderToggleSlotProps_2 {
1029
+ title: string | null;
1030
+ }
1031
+
683
1032
  /**
684
1033
  * Integer ID.
685
1034
  */
@@ -718,6 +1067,37 @@ declare const JobStatus: {
718
1067
 
719
1068
  declare type JobStatusType = (typeof JobStatus)[keyof typeof JobStatus];
720
1069
 
1070
+ export declare interface ListEditorApi<TItem> {
1071
+ viewItems: ComputedRef<ListViewItem<TItem>[]>;
1072
+ addItem: (data: TItem, positionHint?: PositionHint) => TItem[];
1073
+ deleteItem: (idOrItem: ListEditorKey | TItem) => TItem[];
1074
+ updateItem: (idOrItem: ListEditorKey | TItem, data: TItem) => TItem[];
1075
+ moveItem: (fromIndex: number, toIndex: number) => TItem[];
1076
+ recalculatePositions: (items: TItem[]) => TItem[];
1077
+ }
1078
+
1079
+ export declare type ListEditorKey = DocId | IntegerId | string;
1080
+
1081
+ export declare const ListEditorValidationKey: InjectionKey<ListEditorValidationRegistry>;
1082
+
1083
+ export declare interface ListEditorValidationRegistry {
1084
+ register: (key: ListEditorKey, state: Ref<ListEditorValidationState> | ComputedRef<ListEditorValidationState>) => void;
1085
+ unregister: (key: ListEditorKey) => void;
1086
+ }
1087
+
1088
+ export declare type ListEditorValidationState = 'valid' | 'invalid' | 'warning' | null;
1089
+
1090
+ export declare interface ListViewItem<TItem> {
1091
+ key: ListEditorKey;
1092
+ index: number;
1093
+ raw: TItem;
1094
+ position?: number;
1095
+ moved?: boolean;
1096
+ expanded?: boolean;
1097
+ editing?: boolean;
1098
+ validationState?: ListEditorValidationState;
1099
+ }
1100
+
721
1101
  export declare interface MakeFilterOption<TName extends string = string> {
722
1102
  name: TName;
723
1103
  default: AllowedFilterValues;
@@ -733,6 +1113,78 @@ export declare interface MakeFilterOption<TName extends string = string> {
733
1113
  render?: Partial<FilerRenderOptions>;
734
1114
  }
735
1115
 
1116
+ export declare interface NestedListEditorApi<TItem extends Record<string, any>> {
1117
+ viewItems: ComputedRef<NestedViewItem<TItem>[]>;
1118
+ findNode: (id: ListEditorKey) => {
1119
+ node: NestedTreeNode<TItem> | null;
1120
+ parent: NestedTreeNode<TItem> | null;
1121
+ };
1122
+ addItem: (data: TItem, hint?: PositionHint & {
1123
+ parentId?: ListEditorKey | null;
1124
+ asFirstChild?: boolean;
1125
+ childrenAllowed?: boolean;
1126
+ }) => NestedTree<TItem>;
1127
+ deleteItem: (id: ListEditorKey) => NestedTree<TItem>;
1128
+ updateItem: (id: ListEditorKey, data: TItem) => NestedTree<TItem>;
1129
+ moveUp: (id: ListEditorKey) => NestedTree<TItem> | null;
1130
+ moveDown: (id: ListEditorKey) => NestedTree<TItem> | null;
1131
+ moveTop: (id: ListEditorKey) => NestedTree<TItem> | null;
1132
+ moveBottom: (id: ListEditorKey) => NestedTree<TItem> | null;
1133
+ indent: (id: ListEditorKey) => NestedTree<TItem> | null;
1134
+ outdent: (id: ListEditorKey) => NestedTree<TItem> | null;
1135
+ moveTo: (id: ListEditorKey, targetParentId: ListEditorKey | null, targetIndex: number) => NestedTree<TItem> | null;
1136
+ recalculatePositions: (model: NestedTree<TItem>) => NestedTree<TItem>;
1137
+ calculateSubtreeDepth: (node: NestedTreeNode<TItem>) => number;
1138
+ }
1139
+
1140
+ export declare interface NestedPositionHint {
1141
+ parentId?: ListEditorKey | null;
1142
+ afterId?: ListEditorKey;
1143
+ afterIndex?: number;
1144
+ index?: number;
1145
+ asFirstChild?: boolean;
1146
+ childrenAllowed?: boolean;
1147
+ }
1148
+
1149
+ export declare interface NestedTree<TItem = any> {
1150
+ children: NestedTreeNode<TItem>[];
1151
+ meta: {
1152
+ dirty: boolean;
1153
+ };
1154
+ }
1155
+
1156
+ /**
1157
+ * Shape-compatible with legacy SortableNestedItem but without the
1158
+ * `SortableItemWithParentDataAware` constraint — so the nested editor can
1159
+ * accept any record shape that has stable keys addressable via configurable
1160
+ * fields (keyField, positionField, parentField). Admin-cms data types like
1161
+ * `LinkedListItemKind` are assignable to this.
1162
+ */
1163
+ export declare interface NestedTreeNode<TItem = any> {
1164
+ data: TItem;
1165
+ children?: NestedTreeNode<TItem>[];
1166
+ meta: {
1167
+ dirty: boolean;
1168
+ };
1169
+ }
1170
+
1171
+ export declare interface NestedViewItem<TItem> extends ListViewItem<TItem> {
1172
+ node: NestedTreeNode<TItem>;
1173
+ depth: number;
1174
+ parent: TItem | null;
1175
+ parentKey: ListEditorKey | null;
1176
+ childrenCount: number;
1177
+ hasChildren: boolean;
1178
+ childrenAllowed: boolean;
1179
+ siblingIndex: number;
1180
+ siblingCount: number;
1181
+ firstInParent: boolean;
1182
+ lastInParent: boolean;
1183
+ canAddChild: boolean;
1184
+ canIndent: boolean;
1185
+ canOutdent: boolean;
1186
+ }
1187
+
736
1188
  export declare interface Pagination {
737
1189
  sortBy: DatatableSortBy;
738
1190
  page: number;
@@ -747,11 +1199,330 @@ declare interface PaginationOptions {
747
1199
  rowsPerPage: number;
748
1200
  }
749
1201
 
1202
+ export declare interface PositionHint {
1203
+ afterId?: ListEditorKey;
1204
+ afterIndex?: number;
1205
+ index?: number;
1206
+ }
1207
+
1208
+ declare interface Props<TItem extends Record<string, any>> {
1209
+ keyField?: string;
1210
+ positionField?: string;
1211
+ positionMultiplier?: number;
1212
+ updatePosition?: boolean;
1213
+ readonly?: boolean;
1214
+ disabled?: boolean;
1215
+ loading?: boolean;
1216
+ error?: string | null;
1217
+ title?: string | null;
1218
+ compactField?: string | null;
1219
+ statusField?: string | null;
1220
+ twoRows?: 'never' | 'mobile' | 'always';
1221
+ chips?: boolean;
1222
+ showAddButton?: boolean;
1223
+ showDeleteButton?: boolean;
1224
+ showEditButton?: boolean;
1225
+ showAddAfterAction?: boolean;
1226
+ addLabel?: string | null;
1227
+ emptyTitle?: string | null;
1228
+ emptyText?: string | null;
1229
+ disableRowClick?: boolean;
1230
+ disableDeleteConfirm?: boolean;
1231
+ deleteConfirmTitle?: string | null;
1232
+ deleteConfirmText?: string | null;
1233
+ closeVariant?: 'auto' | 'icon' | 'labeled';
1234
+ loadingKeys?: Set<ListEditorKey> | null;
1235
+ getValidationState?: (item: TItem, key: ListEditorKey, index: number) => ListEditorValidationState;
1236
+ onDeleteConfirm?: (item: TItem) => Promise<boolean> | boolean;
1237
+ onDelete?: (item: TItem) => Promise<void> | void;
1238
+ onItemSave?: (item: TItem) => Promise<void> | void;
1239
+ }
1240
+
1241
+ declare interface Props_2<TItem extends Record<string, any>> {
1242
+ keyField?: string;
1243
+ positionField?: string;
1244
+ positionMultiplier?: number;
1245
+ updatePosition?: boolean;
1246
+ readonly?: boolean;
1247
+ disabled?: boolean;
1248
+ loading?: boolean;
1249
+ error?: string | null;
1250
+ title?: string | null;
1251
+ compactField?: string | null;
1252
+ statusField?: string | null;
1253
+ twoRows?: 'never' | 'mobile' | 'always';
1254
+ chips?: boolean;
1255
+ showAddButton?: boolean;
1256
+ showDeleteButton?: boolean;
1257
+ showEditButton?: boolean;
1258
+ showAddAfterAction?: boolean;
1259
+ addLabel?: string | null;
1260
+ emptyTitle?: string | null;
1261
+ emptyText?: string | null;
1262
+ disableRowClick?: boolean;
1263
+ disableDeleteConfirm?: boolean;
1264
+ deleteConfirmTitle?: string | null;
1265
+ deleteConfirmText?: string | null;
1266
+ closeVariant?: 'auto' | 'icon' | 'labeled';
1267
+ loadingKeys?: Set<ListEditorKey> | null;
1268
+ showReorderToggle?: boolean;
1269
+ disableReorder?: boolean;
1270
+ disableDrag?: boolean;
1271
+ showMoveToPosition?: boolean;
1272
+ /**
1273
+ * Embedded mode — this editor is nested inside another editor's `#item`
1274
+ * slot and follows a shared `v-model:mode` from the outer editor. When
1275
+ * set, the editor:
1276
+ * - hides its own Reorder button + Cancel/Apply toolbar
1277
+ * - skips the snapshot/restore (the outer editor's deep snapshot covers
1278
+ * nested data, so cancel at the top reverts everything)
1279
+ * - paints lighter chrome so it visually reads as part of the parent row
1280
+ * Pair with `v-model:mode` bound to the same ref the outer editor uses.
1281
+ */
1282
+ embedded?: boolean;
1283
+ /**
1284
+ * Allow rows to remain inline-editable while the editor is in reorder
1285
+ * mode. By default, entering reorder closes any open inline edit and the
1286
+ * `#item` slot body is hidden — this keeps the visual focus on dragging.
1287
+ * Set this when the open row's body needs to render in reorder mode (e.g.
1288
+ * the parent editor of a shared-reorder pair, where the open question
1289
+ * exposes its embedded answers list for dragging).
1290
+ */
1291
+ allowEditInReorder?: boolean;
1292
+ getValidationState?: (item: TItem, key: ListEditorKey, index: number) => ListEditorValidationState;
1293
+ onDeleteConfirm?: (item: TItem) => Promise<boolean> | boolean;
1294
+ onDelete?: (item: TItem) => Promise<void> | void;
1295
+ onItemSave?: (item: TItem) => Promise<void> | void;
1296
+ onReorderApply?: (items: TItem[]) => Promise<void> | void;
1297
+ }
1298
+
1299
+ declare interface Props_3<TItem extends Record<string, any>> {
1300
+ maxDepth: number;
1301
+ keyField?: string;
1302
+ positionField?: string;
1303
+ parentField?: string;
1304
+ positionMultiplier?: number;
1305
+ readonly?: boolean;
1306
+ disabled?: boolean;
1307
+ loading?: boolean;
1308
+ error?: string | null;
1309
+ title?: string | null;
1310
+ compactField?: string | null;
1311
+ statusField?: string | null;
1312
+ showAddButton?: boolean;
1313
+ showAddChildButton?: boolean;
1314
+ showDeleteButton?: boolean;
1315
+ showEditButton?: boolean;
1316
+ showAddAfterAction?: boolean;
1317
+ showMoveToPosition?: boolean;
1318
+ showChangeParent?: boolean;
1319
+ showExpandToggle?: boolean;
1320
+ getValidationState?: (item: TItem, key: ListEditorKey, index: number) => ListEditorValidationState;
1321
+ addLabel?: string | null;
1322
+ emptyTitle?: string | null;
1323
+ emptyText?: string | null;
1324
+ disableRowClick?: boolean;
1325
+ disableDeleteConfirm?: boolean;
1326
+ deleteConfirmTitle?: string | null;
1327
+ deleteConfirmText?: string | null;
1328
+ closeVariant?: 'auto' | 'icon' | 'labeled';
1329
+ loadingKeys?: Set<ListEditorKey> | null;
1330
+ showReorderToggle?: boolean;
1331
+ disableReorder?: boolean;
1332
+ disableDrag?: boolean;
1333
+ onDeleteConfirm?: (item: TItem) => Promise<boolean> | boolean;
1334
+ onDelete?: (item: TItem) => Promise<void> | void;
1335
+ onItemSave?: (item: TItem) => Promise<void> | void;
1336
+ onReorderApply?: (tree: NestedTree<TItem>) => Promise<void> | void;
1337
+ }
1338
+
1339
+ declare interface Props_4 {
1340
+ title?: string;
1341
+ body?: string;
1342
+ stayLabel?: string;
1343
+ discardLabel?: string;
1344
+ }
1345
+
1346
+ declare type ReorderMode = 'view' | 'reorder';
1347
+
1348
+ declare type ReorderMode_2 = 'view' | 'reorder';
1349
+
1350
+ export declare type ReorderModeValue = 'view' | 'reorder';
1351
+
1352
+ declare interface ReorderToggleSlotProps {
1353
+ mode: ReorderMode;
1354
+ disabled: boolean;
1355
+ hasPendingChanges: boolean;
1356
+ actions: {
1357
+ enterReorderMode: () => void;
1358
+ exitReorderMode: () => void;
1359
+ };
1360
+ }
1361
+
1362
+ declare interface ReorderToggleSlotProps_2 {
1363
+ mode: ReorderMode_2;
1364
+ disabled: boolean;
1365
+ hasPendingChanges: boolean;
1366
+ actions: {
1367
+ enterReorderMode: () => void;
1368
+ exitReorderMode: () => void;
1369
+ };
1370
+ }
1371
+
1372
+ declare interface RowActions<TItem> {
1373
+ edit: () => void;
1374
+ save: () => Promise<void> | void;
1375
+ cancel: () => void;
1376
+ close: () => void;
1377
+ delete: () => Promise<void>;
1378
+ addAfter: () => void;
1379
+ toggleExpand: () => void;
1380
+ update: (data: TItem) => TItem[];
1381
+ }
1382
+
1383
+ declare interface RowActions_2<TItem> {
1384
+ edit: () => void;
1385
+ save: () => Promise<void> | void;
1386
+ cancel: () => void;
1387
+ close: () => void;
1388
+ delete: () => Promise<void>;
1389
+ addAfter: () => void;
1390
+ toggleExpand: () => void;
1391
+ moveUp: () => void;
1392
+ moveDown: () => void;
1393
+ moveTop: () => void;
1394
+ moveBottom: () => void;
1395
+ update: (data: TItem) => TItem[];
1396
+ }
1397
+
1398
+ declare interface RowActions_3<TItem> {
1399
+ edit: () => void;
1400
+ save: () => Promise<void> | void;
1401
+ cancel: () => void;
1402
+ close: () => void;
1403
+ delete: () => Promise<void>;
1404
+ addAfter: () => void;
1405
+ addChild: () => void;
1406
+ toggleExpand: () => void;
1407
+ toggleDetail: () => void;
1408
+ moveUp: () => void;
1409
+ moveDown: () => void;
1410
+ moveTop: () => void;
1411
+ moveBottom: () => void;
1412
+ indent: () => void;
1413
+ outdent: () => void;
1414
+ update: (data: TItem) => NestedTree<TItem>;
1415
+ }
1416
+
1417
+ declare interface RowSlotProps<TItem extends Record<string, any>> {
1418
+ item: DecoratedViewItem<TItem> & {
1419
+ validationState: ListEditorValidationState;
1420
+ };
1421
+ raw: TItem;
1422
+ index: number;
1423
+ key: ListEditorKey;
1424
+ readonly: boolean;
1425
+ disabled: boolean;
1426
+ expanded: boolean;
1427
+ editing: boolean;
1428
+ dirty: boolean;
1429
+ /**
1430
+ * Aliases `dirty` on the flat editor (no reorder mode → no `moved` to OR
1431
+ * with). Mirrors the field name on the sortable + nested variants so a
1432
+ * consumer slot template can use the same name across all three editors.
1433
+ */
1434
+ unsaved: boolean;
1435
+ touch: boolean;
1436
+ actions: RowActions<TItem>;
1437
+ }
1438
+
1439
+ declare interface RowSlotProps_2<TItem extends Record<string, any>> {
1440
+ item: DecoratedViewItem_2<TItem> & {
1441
+ validationState: ListEditorValidationState;
1442
+ };
1443
+ raw: TItem;
1444
+ index: number;
1445
+ key: ListEditorKey;
1446
+ readonly: boolean;
1447
+ disabled: boolean;
1448
+ expanded: boolean;
1449
+ editing: boolean;
1450
+ dirty: boolean;
1451
+ unsaved: boolean;
1452
+ reorderMode: boolean;
1453
+ moved: boolean;
1454
+ canMoveUp: boolean;
1455
+ canMoveDown: boolean;
1456
+ touch: boolean;
1457
+ actions: RowActions_2<TItem>;
1458
+ }
1459
+
1460
+ declare interface RowSlotProps_3<TItem extends Record<string, any>> {
1461
+ item: DecoratedNestedViewItem<TItem> & {
1462
+ validationState: ListEditorValidationState;
1463
+ };
1464
+ raw: TItem;
1465
+ index: number;
1466
+ key: ListEditorKey;
1467
+ depth: number;
1468
+ parent: TItem | null;
1469
+ parentKey: ListEditorKey | null;
1470
+ childrenCount: number;
1471
+ hasChildren: boolean;
1472
+ childrenAllowed: boolean;
1473
+ firstInParent: boolean;
1474
+ lastInParent: boolean;
1475
+ readonly: boolean;
1476
+ disabled: boolean;
1477
+ expanded: boolean;
1478
+ childrenExpanded: boolean;
1479
+ editing: boolean;
1480
+ dirty: boolean;
1481
+ unsaved: boolean;
1482
+ moved: boolean;
1483
+ reorderMode: boolean;
1484
+ canMoveUp: boolean;
1485
+ canMoveDown: boolean;
1486
+ canIndent: boolean;
1487
+ canOutdent: boolean;
1488
+ canAddChild: boolean;
1489
+ touch: boolean;
1490
+ actions: RowActions_3<TItem>;
1491
+ }
1492
+
1493
+ export declare interface SharedReorderRegistry {
1494
+ register: (id: symbol, movedCount: ComputedRef<number>, hasPendingChanges: ComputedRef<boolean>) => void;
1495
+ unregister: (id: symbol) => void;
1496
+ }
1497
+
1498
+ export declare const SharedReorderRegistryKey: InjectionKey<SharedReorderRegistry>;
1499
+
750
1500
  declare interface SortableItemDataAware {
751
1501
  id?: DocId | IntegerId;
752
1502
  position: number;
753
1503
  }
754
1504
 
1505
+ declare interface SortableItemWithParentDataAware {
1506
+ id: DocId | IntegerId;
1507
+ position: number;
1508
+ parent: DocId | IntegerId | null;
1509
+ }
1510
+
1511
+ export declare interface SortableNested<TData extends SortableItemWithParentDataAware = any> {
1512
+ children: Array<SortableNestedItem<TData>>;
1513
+ meta: {
1514
+ dirty: boolean;
1515
+ };
1516
+ }
1517
+
1518
+ export declare interface SortableNestedItem<TData extends SortableItemWithParentDataAware = any> {
1519
+ data: TData;
1520
+ children?: Array<SortableNestedItem> | undefined;
1521
+ meta: {
1522
+ dirty: boolean;
1523
+ };
1524
+ }
1525
+
755
1526
  declare const SortOrder: {
756
1527
  readonly Asc: "asc";
757
1528
  readonly Desc: "desc";
@@ -771,6 +1542,30 @@ declare type TimeIntervalSpecialOptionsType = (typeof TimeIntervalSpecialOptions
771
1542
  /** note: number value represents time interval in minutes, null represent unselected */
772
1543
  export declare type TimeIntervalToolsValue = number | TimeIntervalSpecialOptionsType | null;
773
1544
 
1545
+ declare interface ToolbarSlotProps {
1546
+ applying: boolean;
1547
+ hasPendingChanges: boolean;
1548
+ movedCount: number;
1549
+ error: string | null;
1550
+ actions: {
1551
+ apply: () => Promise<void>;
1552
+ cancel: () => void;
1553
+ };
1554
+ }
1555
+
1556
+ declare interface ToolbarSlotProps_2 {
1557
+ applying: boolean;
1558
+ hasPendingChanges: boolean;
1559
+ movedCount: number;
1560
+ error: string | null;
1561
+ actions: {
1562
+ apply: () => Promise<void>;
1563
+ cancel: () => void;
1564
+ };
1565
+ }
1566
+
1567
+ declare type UnsavedSource = Ref<boolean | Set<unknown> | unknown[] | null | undefined>;
1568
+
774
1569
  declare type UrlParams = {
775
1570
  [key: string]: number | string;
776
1571
  };
@@ -882,6 +1677,92 @@ export declare function useJobApi<JobType extends JobBase = JobBase>(client: ()
882
1677
  deleteJob: (id: number) => Promise<JobType>;
883
1678
  };
884
1679
 
1680
+ /**
1681
+ * Flat list editor core. Pure data behavior shared by AListEditor and
1682
+ * ASortableListEditor. Does not touch the DOM, SortableJS, or emits.
1683
+ *
1684
+ * The caller passes a writable ref (typically `defineModel<TItem[]>`).
1685
+ * Mutators write a new array to `model.value` and also return it.
1686
+ * Input items are never mutated — when positions need to change, a new
1687
+ * item object is produced with `{ ...item, [positionField]: n }`.
1688
+ */
1689
+ export declare function useListEditor<TItem extends Record<string, any>>(model: Ref<TItem[]>, options?: UseListEditorOptions): ListEditorApi<TItem>;
1690
+
1691
+ export declare function useListEditorItemValidation(options: UseListEditorItemValidationOptions): void;
1692
+
1693
+ declare interface UseListEditorItemValidationOptions {
1694
+ /**
1695
+ * Stable identity of the row in the editor's v-model. Pass a getter so the
1696
+ * composable can re-register if the key ever swaps.
1697
+ */
1698
+ key: () => ListEditorKey;
1699
+ /**
1700
+ * Reactive validation state. Common shape: a computed reading vuelidate's
1701
+ * `v$.$dirty && v$.$invalid` and returning 'invalid' or null.
1702
+ */
1703
+ state: Ref<ListEditorValidationState> | ComputedRef<ListEditorValidationState> | (() => ListEditorValidationState);
1704
+ }
1705
+
1706
+ export declare interface UseListEditorOptions {
1707
+ keyField?: string;
1708
+ positionField?: string;
1709
+ positionMultiplier?: number;
1710
+ updatePosition?: boolean;
1711
+ }
1712
+
1713
+ /**
1714
+ * Nested list editor core. Pure data behavior shared by ANestedSortableListEditor.
1715
+ * Works on a tree of `{ data, children, meta }` nodes — shape-compatible with the
1716
+ * legacy `SortableNested` wrapper so migration can pass existing data through
1717
+ * unchanged. Mutators return a cloned tree and also assign it to `model.value`.
1718
+ */
1719
+ export declare function useNestedListEditor<TItem extends Record<string, any>>(model: Ref<NestedTree<TItem>>, options: UseNestedListEditorOptions): NestedListEditorApi<TItem>;
1720
+
1721
+ declare interface UseNestedListEditorOptions {
1722
+ keyField?: string;
1723
+ positionField?: string;
1724
+ parentField?: string;
1725
+ positionMultiplier?: number;
1726
+ maxDepth: number;
1727
+ expandedKeys?: Ref<Set<ListEditorKey>>;
1728
+ }
1729
+
1730
+ /**
1731
+ * Aggregates per-parent child-editor unsaved-keys into one prefix-merged set.
1732
+ * Used by stacked editors (e.g. quiz: questions → answers) so the outer
1733
+ * editor's parent gets a single merged `Set<ListEditorKey>` to thread into a
1734
+ * unsaved-changes guard, without losing per-parent identity.
1735
+ *
1736
+ * Key collision matters: a brand-new question and a brand-new answer both
1737
+ * have `id: 0` from the factory; without the prefix the answers from two
1738
+ * different questions would dedupe into one entry and the count would
1739
+ * under-report. Prefix `${parentKey}:${childKey}` keeps them distinct.
1740
+ *
1741
+ * Usage:
1742
+ * const childSets = useNestedUnsavedKeys()
1743
+ * <ChildEditor
1744
+ * :unsaved-keys="childSets.getForParent(parent.id)"
1745
+ * @update:unsaved-keys="(s) => childSets.setForParent(parent.id, s)"
1746
+ * />
1747
+ * // emit `childSets.merged.value` upward
1748
+ */
1749
+ export declare function useNestedUnsavedKeys(): UseNestedUnsavedKeysApi;
1750
+
1751
+ export declare interface UseNestedUnsavedKeysApi {
1752
+ /** Set of unsaved keys for one parent row — used as the inner editor's `v-model:unsaved-keys`. */
1753
+ getForParent: (parentKey: ListEditorKey) => Set<ListEditorKey>;
1754
+ /** Push a child editor's unsaved-key set up under `parentKey`. */
1755
+ setForParent: (parentKey: ListEditorKey, set: Set<ListEditorKey>) => void;
1756
+ /**
1757
+ * Aggregated set with prefix-merged keys (`${parentKey}:${childKey}`) so two
1758
+ * different parents can't collide on a shared child key (typical for newly
1759
+ * created rows whose `id` is `0` until the API assigns one).
1760
+ */
1761
+ merged: ComputedRef<Set<ListEditorKey>>;
1762
+ /** Total count across all parents — handy for the parent v-model:unsaved-keys. */
1763
+ count: ComputedRef<number>;
1764
+ }
1765
+
885
1766
  export declare function usePagination(sortKey: string | null, sortOrder?: SortOrderType, options?: Partial<PaginationOptions>, externalPaginationRef?: Ref<Pagination>): UsePaginationReturnType;
886
1767
 
887
1768
  declare interface UsePaginationReturnType {
@@ -958,6 +1839,53 @@ export declare function useSubjectSelect<TItem>(datatableConfig: any, datatableH
958
1839
  submitFilter: () => void;
959
1840
  };
960
1841
 
1842
+ export declare function useUnsavedChangesGuard(options: UseUnsavedChangesGuardOptions): UseUnsavedChangesGuardApi;
1843
+
1844
+ declare interface UseUnsavedChangesGuardApi {
1845
+ hasUnsavedChanges: ComputedRef<boolean>;
1846
+ /**
1847
+ * v-model-bound to the confirm dialog. When the guard wants to ask the user
1848
+ * to confirm leaving, it sets this to true. The confirm dialog reads it.
1849
+ */
1850
+ promptOpen: Ref<boolean>;
1851
+ /**
1852
+ * Resolves the confirm prompt with `discard=true` (proceed) or `false`
1853
+ * (stay). Called by the confirm dialog.
1854
+ */
1855
+ resolvePrompt: (discard: boolean) => void;
1856
+ /**
1857
+ * Manually mark the most recent intent as acknowledged so the next
1858
+ * route/dialog/unload attempt proceeds without prompting. Useful right
1859
+ * before a programmatic navigation that the consumer has already
1860
+ * confirmed.
1861
+ */
1862
+ acknowledge: () => void;
1863
+ }
1864
+
1865
+ declare interface UseUnsavedChangesGuardOptions {
1866
+ /**
1867
+ * Reactive sources that signal "unsaved" state. Each source's truthiness is
1868
+ * checked: a Set/array is "dirty" when non-empty, a boolean when true, null
1869
+ * or undefined as not dirty.
1870
+ */
1871
+ sources: UnsavedSource[];
1872
+ /**
1873
+ * Block route navigation via vue-router's onBeforeRouteLeave. Default true.
1874
+ * When omitted/false, the route guard is not registered.
1875
+ */
1876
+ guardRoute?: boolean | Ref<boolean>;
1877
+ /**
1878
+ * Block window/tab unload via beforeunload. Default true.
1879
+ */
1880
+ guardWindowUnload?: boolean | Ref<boolean>;
1881
+ /**
1882
+ * Optional Vuetify dialog v-model. When provided, attempts to close the
1883
+ * dialog while dirty are intercepted: dialog stays open until the user
1884
+ * confirms via the confirm dialog or via `acknowledge()`.
1885
+ */
1886
+ guardDialogModel?: Ref<boolean>;
1887
+ }
1888
+
961
1889
  export declare function useUserAdminConfigApi(client: () => AxiosInstance, system: string, entity?: string, endPoint?: string): {
962
1890
  useFetchUserAdminConfigList: () => UseApiFetchListReturnType<UserAdminConfig<UserAdminConfigDataFilterBookmark | UserAdminConfigDataPinnedWidgets<string>>[]>;
963
1891
  fetchUserAdminConfig: (id: IntegerId) => Promise<UserAdminConfig<UserAdminConfigDataFilterBookmark | UserAdminConfigDataPinnedWidgets<string>>>;