pangea-lib 2.11.302 → 2.11.304

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.
@@ -0,0 +1,7 @@
1
+ declare const _default: {
2
+ es: {
3
+ columnTitleEdit: string;
4
+ columnTitleDelete: string;
5
+ };
6
+ };
7
+ export default _default;
@@ -8,7 +8,7 @@ type SelectorItem = {
8
8
  declare const _default: import('vue').DefineComponent<{
9
9
  modelValue: {
10
10
  required: true;
11
- type: import('vue').PropType<any>;
11
+ type: import('vue').PropType<string>;
12
12
  };
13
13
  items: {
14
14
  type: import('vue').PropType<SelectorItem[]>;
@@ -32,7 +32,7 @@ declare const _default: import('vue').DefineComponent<{
32
32
  }, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
33
33
  modelValue: {
34
34
  required: true;
35
- type: import('vue').PropType<any>;
35
+ type: import('vue').PropType<string>;
36
36
  };
37
37
  items: {
38
38
  type: import('vue').PropType<SelectorItem[]>;
@@ -1,16 +1,28 @@
1
- import { Columns, SearchData, Indentation } from '../../types';
1
+ import { TableItem, Columns, SearchParams, Indentation } from '../../types';
2
2
 
3
3
  declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
4
4
  modelValue: {
5
5
  required: true;
6
- type: import('vue').PropType<SearchData>;
6
+ type: import('vue').PropType<SearchParams>;
7
7
  };
8
8
  columns: {
9
9
  type: import('vue').PropType<Columns>;
10
10
  required: true;
11
11
  };
12
+ createItemBtnText: {
13
+ type: import('vue').PropType<string>;
14
+ };
15
+ withSelectColumn: {
16
+ type: import('vue').PropType<boolean>;
17
+ };
18
+ withEditColumn: {
19
+ type: import('vue').PropType<boolean>;
20
+ };
21
+ confirmDeleteText: {
22
+ type: import('vue').PropType<(item: TableItem) => string>;
23
+ };
12
24
  items: {
13
- type: import('vue').PropType<any[]>;
25
+ type: import('vue').PropType<TableItem[]>;
14
26
  required: true;
15
27
  };
16
28
  totalCount: {
@@ -27,18 +39,33 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
27
39
  type: import('vue').PropType<boolean>;
28
40
  };
29
41
  }, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
42
+ createItem: () => void;
43
+ editItem: (item: TableItem) => void;
44
+ deleteItem: (item: TableItem) => void;
30
45
  refreshList: () => void;
31
46
  }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
32
47
  modelValue: {
33
48
  required: true;
34
- type: import('vue').PropType<SearchData>;
49
+ type: import('vue').PropType<SearchParams>;
35
50
  };
36
51
  columns: {
37
52
  type: import('vue').PropType<Columns>;
38
53
  required: true;
39
54
  };
55
+ createItemBtnText: {
56
+ type: import('vue').PropType<string>;
57
+ };
58
+ withSelectColumn: {
59
+ type: import('vue').PropType<boolean>;
60
+ };
61
+ withEditColumn: {
62
+ type: import('vue').PropType<boolean>;
63
+ };
64
+ confirmDeleteText: {
65
+ type: import('vue').PropType<(item: TableItem) => string>;
66
+ };
40
67
  items: {
41
- type: import('vue').PropType<any[]>;
68
+ type: import('vue').PropType<TableItem[]>;
42
69
  required: true;
43
70
  };
44
71
  totalCount: {
@@ -55,6 +82,9 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
55
82
  type: import('vue').PropType<boolean>;
56
83
  };
57
84
  }>> & {
85
+ onCreateItem?: () => any;
86
+ onEditItem?: (item: TableItem) => any;
87
+ onDeleteItem?: (item: TableItem) => any;
58
88
  onRefreshList?: () => any;
59
89
  }, {}, {}>, Partial<Record<string, (_: {
60
90
  item: any;
@@ -43,6 +43,12 @@ declare const _default: {
43
43
  loginBtn: string;
44
44
  };
45
45
  };
46
+ pgaTable: {
47
+ es: {
48
+ columnTitleEdit: string;
49
+ columnTitleDelete: string;
50
+ };
51
+ };
46
52
  pgaModal: {
47
53
  es: {
48
54
  cancelBtn: string;
@@ -1,4 +1,4 @@
1
- export declare const getLanguage: () => "es", setLanguage: (language: "es") => void, useI18n: <FN extends "notifications" | "alert" | "pgaLogoutButton" | "pgaDisplayNoItems" | "pgaDatePicker" | "pgaInputFile" | "pgaInputGroup" | "pgaLoginForm" | "pgaModal", MP extends void | import('pangea-helpers').ExtractPrefixes<{
1
+ export declare const getLanguage: () => "es", setLanguage: (language: "es") => void, useI18n: <FN extends "notifications" | "alert" | "pgaLogoutButton" | "pgaDisplayNoItems" | "pgaDatePicker" | "pgaInputFile" | "pgaInputGroup" | "pgaLoginForm" | "pgaTable" | "pgaModal", MP extends void | import('pangea-helpers').ExtractPrefixes<{
2
2
  alert: {
3
3
  es: {
4
4
  alertTitle: string;
@@ -43,6 +43,12 @@ export declare const getLanguage: () => "es", setLanguage: (language: "es") => v
43
43
  loginBtn: string;
44
44
  };
45
45
  };
46
+ pgaTable: {
47
+ es: {
48
+ columnTitleEdit: string;
49
+ columnTitleDelete: string;
50
+ };
51
+ };
46
52
  pgaModal: {
47
53
  es: {
48
54
  cancelBtn: string;
@@ -99,6 +105,12 @@ export declare const getLanguage: () => "es", setLanguage: (language: "es") => v
99
105
  loginBtn: string;
100
106
  };
101
107
  };
108
+ pgaTable: {
109
+ es: {
110
+ columnTitleEdit: string;
111
+ columnTitleDelete: string;
112
+ };
113
+ };
102
114
  pgaModal: {
103
115
  es: {
104
116
  cancelBtn: string;
@@ -155,6 +167,12 @@ export declare const getLanguage: () => "es", setLanguage: (language: "es") => v
155
167
  loginBtn: string;
156
168
  };
157
169
  };
170
+ pgaTable: {
171
+ es: {
172
+ columnTitleEdit: string;
173
+ columnTitleDelete: string;
174
+ };
175
+ };
158
176
  pgaModal: {
159
177
  es: {
160
178
  cancelBtn: string;
@@ -8,5 +8,5 @@ export * from './image';
8
8
  export * from './populate';
9
9
  export * from './size';
10
10
  export * from './table';
11
- export type Id = any;
11
+ export type Id = string;
12
12
  export type TextProp = string | (() => string);
@@ -1,5 +1,9 @@
1
- import { TextProp } from '.';
1
+ import { Id, TextProp } from '.';
2
2
 
3
+ export type TableItem = {
4
+ id: Id;
5
+ [key: string]: any;
6
+ };
3
7
  export type ColumnName = string;
4
8
  export type Column = {
5
9
  title: TextProp;
@@ -7,7 +11,7 @@ export type Column = {
7
11
  fitContent?: boolean;
8
12
  };
9
13
  export type Columns = Record<ColumnName, Column>;
10
- export type SearchData = {
14
+ export type SearchParams = {
11
15
  page: number;
12
16
  pageSize: number;
13
17
  search: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pangea-lib",
3
3
  "description": "",
4
- "version": "2.11.302",
4
+ "version": "2.11.304",
5
5
  "author": "Gianfranco Raselli",
6
6
  "license": "ISC",
7
7
  "homepage": "https://github.com/GianfrancoRaselli/pangea#readme",