lkt-vue-kernel 1.0.6 → 1.0.8

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/index.d.ts CHANGED
@@ -163,10 +163,26 @@ interface FieldConfig {
163
163
  prop?: LktObject;
164
164
  }
165
165
 
166
+ declare enum ModalCallbackAction {
167
+ Refresh = "refresh",
168
+ Close = "close",
169
+ ReOpen = "reOpen",
170
+ Exec = "exec",
171
+ Open = "open"
172
+ }
173
+
166
174
  type EmptyModalKey = '_';
167
175
 
168
176
  type ValidModalKey = string | Function | EmptyModalKey;
169
177
 
178
+ interface ModalCallbackConfig {
179
+ modalName: ValidModalName;
180
+ modalKey?: ValidModalKey;
181
+ action: ModalCallbackAction;
182
+ method?: string;
183
+ args?: LktObject;
184
+ }
185
+
170
186
  type BeforeCloseModalData = {
171
187
  modalName: ValidModalKey;
172
188
  modalKey: ValidModalKey;
@@ -319,6 +335,24 @@ interface ModalConfig extends LktObject {
319
335
  cancelButton?: Partial<ButtonConfig>;
320
336
  }
321
337
 
338
+ declare enum PaginatorType {
339
+ Pages = "pages",
340
+ PrevNext = "prev-next",
341
+ PagesPrevNext = "pages-prev-next",
342
+ PagesPrevNextFirstLast = "pages-prev-next-first-last",
343
+ LoadMore = "load-more",
344
+ Infinite = "infinite"
345
+ }
346
+
347
+ interface PaginatorConfig {
348
+ type: PaginatorType;
349
+ modelValue: number;
350
+ class: string;
351
+ resource: string;
352
+ readOnly: boolean;
353
+ filters: LktObject;
354
+ }
355
+
322
356
  declare enum TooltipLocationY {
323
357
  Top = "top",
324
358
  Bottom = "bottom",
@@ -665,7 +699,6 @@ interface TableConfig {
665
699
  slotItemVar?: string;
666
700
  modal?: string;
667
701
  modalData?: LktObject;
668
- itemMode?: boolean;
669
702
  }
670
703
 
671
704
  declare class LktStrictItem extends LktItem {
@@ -713,6 +746,18 @@ declare class Modal extends LktItem implements ModalConfig {
713
746
  constructor(data?: Partial<ModalConfig>);
714
747
  }
715
748
 
749
+ declare class Paginator extends LktItem implements PaginatorConfig {
750
+ static lktAllowUndefinedProps: string[];
751
+ static lktDefaultValues: (keyof PaginatorConfig)[];
752
+ type: PaginatorType;
753
+ modelValue: number;
754
+ class: string;
755
+ resource: string;
756
+ readOnly: boolean;
757
+ filters: LktObject;
758
+ constructor(data?: Partial<PaginatorConfig>);
759
+ }
760
+
716
761
  declare class Table extends LktItem implements TableConfig {
717
762
  static lktDefaultValues: (keyof TableConfig)[];
718
763
  modelValue: LktObject[];
@@ -802,4 +847,4 @@ declare function getDefaultValues<T>(cls: {
802
847
  lktDefaultValues: (keyof T)[];
803
848
  }): Partial<T>;
804
849
 
805
- export { Anchor, type AnchorConfig, AnchorType, type BeforeCloseModalData, Button, type ButtonConfig, ButtonType, Column, type ColumnConfig, ColumnType, type DragConfig, type EmptyModalKey, Field, FieldAutoValidationTrigger, type FieldConfig, FieldType, LktItem, type LktObject, LktStrictItem, Modal, type ModalConfig, ModalType, MultipleOptionsDisplay, Option, type OptionConfig, SafeString, type ScanPropTarget, SortDirection, Table, type TableConfig, TablePermission, TableRowType, TableType, ToggleMode, Tooltip, type TooltipConfig, TooltipLocationX, TooltipLocationY, TooltipPositionEngine, type ValidBeforeCloseModal, type ValidColSpan, type ValidFieldMinMax, type ValidFieldValue, type ValidModalKey, type ValidModalName, type ValidOptionValue, type ValidSafeStringValue, type ValidScanPropTarget, type ValidTabIndex, type ValidTablePermission, type ValidTableRowTypeValue, extractPropValue, getDefaultValues };
850
+ export { Anchor, type AnchorConfig, AnchorType, type BeforeCloseModalData, Button, type ButtonConfig, ButtonType, Column, type ColumnConfig, ColumnType, type DragConfig, type EmptyModalKey, Field, FieldAutoValidationTrigger, type FieldConfig, FieldType, LktItem, type LktObject, LktStrictItem, Modal, ModalCallbackAction, type ModalCallbackConfig, type ModalConfig, ModalType, MultipleOptionsDisplay, Option, type OptionConfig, Paginator, type PaginatorConfig, PaginatorType, SafeString, type ScanPropTarget, SortDirection, Table, type TableConfig, TablePermission, TableRowType, TableType, ToggleMode, Tooltip, type TooltipConfig, TooltipLocationX, TooltipLocationY, TooltipPositionEngine, type ValidBeforeCloseModal, type ValidColSpan, type ValidFieldMinMax, type ValidFieldValue, type ValidModalKey, type ValidModalName, type ValidOptionValue, type ValidSafeStringValue, type ValidScanPropTarget, type ValidTabIndex, type ValidTablePermission, type ValidTableRowTypeValue, extractPropValue, getDefaultValues };
package/dist/index.js CHANGED
@@ -590,6 +590,40 @@ var Modal = class extends LktItem {
590
590
  }
591
591
  };
592
592
 
593
+ // src/enums/PaginatorType.ts
594
+ var PaginatorType = /* @__PURE__ */ ((PaginatorType2) => {
595
+ PaginatorType2["Pages"] = "pages";
596
+ PaginatorType2["PrevNext"] = "prev-next";
597
+ PaginatorType2["PagesPrevNext"] = "pages-prev-next";
598
+ PaginatorType2["PagesPrevNextFirstLast"] = "pages-prev-next-first-last";
599
+ PaginatorType2["LoadMore"] = "load-more";
600
+ PaginatorType2["Infinite"] = "infinite";
601
+ return PaginatorType2;
602
+ })(PaginatorType || {});
603
+
604
+ // src/instances/Paginator.ts
605
+ var Paginator = class extends LktItem {
606
+ static lktAllowUndefinedProps = [];
607
+ static lktDefaultValues = [
608
+ "type",
609
+ "modelValue",
610
+ "class",
611
+ "resource",
612
+ "readOnly",
613
+ "filters"
614
+ ];
615
+ type = "pages-prev-next" /* PagesPrevNext */;
616
+ modelValue = 1;
617
+ class = "";
618
+ resource = "";
619
+ readOnly = false;
620
+ filters = {};
621
+ constructor(data = {}) {
622
+ super();
623
+ this.feed(data);
624
+ }
625
+ };
626
+
593
627
  // src/enums/TableType.ts
594
628
  var TableType = /* @__PURE__ */ ((TableType2) => {
595
629
  TableType2["Table"] = "table";
@@ -753,6 +787,16 @@ var Table = class extends LktItem {
753
787
  }
754
788
  };
755
789
 
790
+ // src/enums/ModalCallbackAction.ts
791
+ var ModalCallbackAction = /* @__PURE__ */ ((ModalCallbackAction2) => {
792
+ ModalCallbackAction2["Refresh"] = "refresh";
793
+ ModalCallbackAction2["Close"] = "close";
794
+ ModalCallbackAction2["ReOpen"] = "reOpen";
795
+ ModalCallbackAction2["Exec"] = "exec";
796
+ ModalCallbackAction2["Open"] = "open";
797
+ return ModalCallbackAction2;
798
+ })(ModalCallbackAction || {});
799
+
756
800
  // src/enums/ModalType.ts
757
801
  var ModalType = /* @__PURE__ */ ((ModalType2) => {
758
802
  ModalType2["Modal"] = "modal";
@@ -823,9 +867,12 @@ export {
823
867
  LktItem,
824
868
  LktStrictItem,
825
869
  Modal,
870
+ ModalCallbackAction,
826
871
  ModalType,
827
872
  MultipleOptionsDisplay,
828
873
  Option,
874
+ Paginator,
875
+ PaginatorType,
829
876
  SafeString,
830
877
  SortDirection,
831
878
  Table,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lkt-vue-kernel",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "description": "LKT Vue Kernel",
5
5
  "keywords": [
6
6
  "lkt",