aq-fe-framework 0.1.966 → 0.1.967

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.
@@ -50,4 +50,4 @@ interface MyDataTableProps<TData extends MRT_RowData> extends MRT_TableOptions<T
50
50
  }
51
51
  declare function MyDataTable<TData extends MRT_RowData>({ rowActionSize, columns, data, setSelectedRow, isError, isLoading, pagination, idSelectionOne, setIdSelectionOne, renderTopToolbarCustomActions, visibleFields, ...rest }: MyDataTableProps<TData>): react_jsx_runtime.JSX.Element;
52
52
 
53
- export { type MyActionIconProps as M, type PaginationState as P, type MyButtonProps as a, type MyButtonModalProps as b, type MyDataTableProps as c, MyActionIcon as d, MyButton as e, MyButtonModal as f, type MyDataTableInternalProps as g, MyDataTable as h };
53
+ export { type MyActionIconProps as M, type PaginationState as P, type MyButtonProps as a, type MyButtonModalProps as b, type MyDataTableProps as c, MyButtonModal as d, MyActionIcon as e, MyButton as f, type MyDataTableInternalProps as g, MyDataTable as h };
@@ -24,13 +24,13 @@ import {
24
24
  import {
25
25
  createGenericStore2 as createGenericStore
26
26
  } from "./chunk-YGWSHSTG.mjs";
27
- import {
28
- enum_daysOfWeek
29
- } from "./chunk-K6S7R6LU.mjs";
30
27
  import {
31
28
  const_object_colors,
32
29
  const_object_documentTypes
33
30
  } from "./chunk-SPG47QW7.mjs";
31
+ import {
32
+ enum_daysOfWeek
33
+ } from "./chunk-K6S7R6LU.mjs";
34
34
  import {
35
35
  createBaseApi,
36
36
  useConfig,
@@ -78,7 +78,20 @@ function CustomSwitchTheme() {
78
78
  );
79
79
  }
80
80
 
81
- // src/core/button/MyActionIcon.tsx
81
+ // src/core/button/MyButtonCreateUpdate.tsx
82
+ import { Modal, ScrollArea, Space, Tooltip, useMantineColorScheme as useMantineColorScheme4 } from "@mantine/core";
83
+ import { useDisclosure } from "@mantine/hooks";
84
+ import { notifications } from "@mantine/notifications";
85
+
86
+ // src/core/layout/MyFlexColumn.tsx
87
+ import { Flex } from "@mantine/core";
88
+ import { jsx as jsx2 } from "react/jsx-runtime";
89
+ function MyFlexColumn(_a) {
90
+ var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
91
+ return /* @__PURE__ */ jsx2(Flex, __spreadProps(__spreadValues({ direction: "column", gap: "md" }, rest), { children }));
92
+ }
93
+
94
+ // src/core/button/MyActionIcon/MyActionIcon.tsx
82
95
  import { ActionIcon as ActionIcon2, useMantineColorScheme as useMantineColorScheme2 } from "@mantine/core";
83
96
  import {
84
97
  IconBook,
@@ -94,71 +107,71 @@ import {
94
107
  IconTrash,
95
108
  IconX
96
109
  } from "@tabler/icons-react";
97
- import { jsx as jsx2 } from "react/jsx-runtime";
110
+ import { jsx as jsx3 } from "react/jsx-runtime";
98
111
  var getActionConfig = (colorScheme) => ({
99
112
  default: {},
100
113
  create: {
101
114
  color: "indigo",
102
115
  type: "submit",
103
- children: /* @__PURE__ */ jsx2(IconPlus, {})
116
+ children: /* @__PURE__ */ jsx3(IconPlus, {})
104
117
  },
105
118
  createMultiple: {
106
119
  color: "green",
107
120
  type: "submit",
108
- children: /* @__PURE__ */ jsx2(IconPlus, {})
121
+ children: /* @__PURE__ */ jsx3(IconPlus, {})
109
122
  },
110
123
  delete: {
111
124
  color: "red",
112
- children: /* @__PURE__ */ jsx2(IconTrash, {})
125
+ children: /* @__PURE__ */ jsx3(IconTrash, {})
113
126
  },
114
127
  update: {
115
128
  color: "yellow",
116
129
  type: "submit",
117
- children: /* @__PURE__ */ jsx2(IconEdit, {})
130
+ children: /* @__PURE__ */ jsx3(IconEdit, {})
118
131
  },
119
132
  save: {
120
133
  color: "blue",
121
134
  type: "submit",
122
- children: /* @__PURE__ */ jsx2(IconDeviceFloppy, {})
135
+ children: /* @__PURE__ */ jsx3(IconDeviceFloppy, {})
123
136
  },
124
137
  import: {
125
138
  color: "green.8",
126
- children: /* @__PURE__ */ jsx2(IconFileImport, {})
139
+ children: /* @__PURE__ */ jsx3(IconFileImport, {})
127
140
  },
128
141
  print: {
129
142
  color: "orange.7",
130
- children: /* @__PURE__ */ jsx2(IconPrinter, {})
143
+ children: /* @__PURE__ */ jsx3(IconPrinter, {})
131
144
  },
132
145
  export: {
133
146
  color: "green.8",
134
- children: /* @__PURE__ */ jsx2(IconFileExport, {})
147
+ children: /* @__PURE__ */ jsx3(IconFileExport, {})
135
148
  },
136
149
  cancel: {
137
150
  color: "gray",
138
- children: /* @__PURE__ */ jsx2(IconX, {})
151
+ children: /* @__PURE__ */ jsx3(IconX, {})
139
152
  },
140
153
  select: {},
141
154
  check: {},
142
155
  find: {},
143
156
  tempDelete: {
144
157
  color: "red",
145
- children: /* @__PURE__ */ jsx2(IconX, {})
158
+ children: /* @__PURE__ */ jsx3(IconX, {})
146
159
  },
147
160
  tempUpdate: {
148
161
  color: "yellow",
149
- children: /* @__PURE__ */ jsx2(IconPencil, {})
162
+ children: /* @__PURE__ */ jsx3(IconPencil, {})
150
163
  },
151
164
  viewFile: {
152
165
  color: "green",
153
- children: /* @__PURE__ */ jsx2(IconBook, {})
166
+ children: /* @__PURE__ */ jsx3(IconBook, {})
154
167
  },
155
168
  view: {
156
169
  color: "cyan",
157
- children: /* @__PURE__ */ jsx2(IconEye, {})
170
+ children: /* @__PURE__ */ jsx3(IconEye, {})
158
171
  },
159
172
  sendMail: {
160
173
  color: "grape",
161
- children: /* @__PURE__ */ jsx2(IconMail, {})
174
+ children: /* @__PURE__ */ jsx3(IconMail, {})
162
175
  },
163
176
  validate: {}
164
177
  });
@@ -167,7 +180,7 @@ function MyActionIcon(_a) {
167
180
  const permissionStore = useStore_Permission();
168
181
  const { colorScheme } = useMantineColorScheme2();
169
182
  if (!actionType2) {
170
- return /* @__PURE__ */ jsx2(ActionIcon2, __spreadProps(__spreadValues({}, rest), { children }));
183
+ return /* @__PURE__ */ jsx3(ActionIcon2, __spreadProps(__spreadValues({}, rest), { children }));
171
184
  }
172
185
  const config4 = actionType2 ? getActionConfig(colorScheme)[actionType2] : {};
173
186
  const shouldHide = (() => {
@@ -175,7 +188,7 @@ function MyActionIcon(_a) {
175
188
  return false;
176
189
  return actionType2 === "create" && permissionStore.state.currentPermissionPage.isCreate === false || actionType2 === "update" && permissionStore.state.currentPermissionPage.isUpdate === false || actionType2 === "delete" && permissionStore.state.currentPermissionPage.isDelete === false || actionType2 === "print" && permissionStore.state.currentPermissionPage.isPrint === false || actionType2 === "export" && permissionStore.state.currentPermissionPage.isExport === false;
177
190
  })();
178
- return /* @__PURE__ */ jsx2(
191
+ return /* @__PURE__ */ jsx3(
179
192
  ActionIcon2,
180
193
  __spreadProps(__spreadValues(__spreadValues({
181
194
  hidden: shouldHide
@@ -185,7 +198,7 @@ function MyActionIcon(_a) {
185
198
  );
186
199
  }
187
200
 
188
- // src/core/button/MyButton.tsx
201
+ // src/core/button/MyButton/MyButton.tsx
189
202
  import { Button, useMantineColorScheme as useMantineColorScheme3 } from "@mantine/core";
190
203
  import {
191
204
  IconChecklist,
@@ -202,7 +215,7 @@ import {
202
215
  IconUpload,
203
216
  IconX as IconX2
204
217
  } from "@tabler/icons-react";
205
- import { jsx as jsx3 } from "react/jsx-runtime";
218
+ import { jsx as jsx4 } from "react/jsx-runtime";
206
219
  var getActionConfig2 = (colorScheme) => ({
207
220
  default: {
208
221
  children: ""
@@ -210,47 +223,47 @@ var getActionConfig2 = (colorScheme) => ({
210
223
  create: {
211
224
  color: colorScheme == "light" ? "blue" : "blue.3",
212
225
  type: "submit",
213
- leftSection: /* @__PURE__ */ jsx3(IconPlus2, {}),
226
+ leftSection: /* @__PURE__ */ jsx4(IconPlus2, {}),
214
227
  children: "Th\xEAm"
215
228
  },
216
229
  createMultiple: {},
217
230
  delete: {
218
231
  color: "red",
219
- leftSection: /* @__PURE__ */ jsx3(IconTrash2, {}),
232
+ leftSection: /* @__PURE__ */ jsx4(IconTrash2, {}),
220
233
  children: "X\xF3a"
221
234
  },
222
235
  update: {
223
236
  color: "yellow",
224
237
  type: "submit",
225
- leftSection: /* @__PURE__ */ jsx3(IconEdit2, {}),
238
+ leftSection: /* @__PURE__ */ jsx4(IconEdit2, {}),
226
239
  children: "Ch\u1EC9nh s\u1EEDa"
227
240
  },
228
241
  save: {
229
242
  color: "blue",
230
243
  type: "submit",
231
- leftSection: /* @__PURE__ */ jsx3(IconDeviceFloppy2, {}),
244
+ leftSection: /* @__PURE__ */ jsx4(IconDeviceFloppy2, {}),
232
245
  children: "L\u01B0u"
233
246
  },
234
247
  import: {
235
248
  color: colorScheme == "light" ? "green" : "green.3",
236
- leftSection: /* @__PURE__ */ jsx3(IconUpload, {}),
249
+ leftSection: /* @__PURE__ */ jsx4(IconUpload, {}),
237
250
  children: "Import",
238
251
  variant: "light"
239
252
  },
240
253
  export: {
241
254
  color: colorScheme == "light" ? "violet" : "violet.3",
242
- leftSection: /* @__PURE__ */ jsx3(IconDownload, {}),
255
+ leftSection: /* @__PURE__ */ jsx4(IconDownload, {}),
243
256
  children: "Export",
244
257
  variant: "light"
245
258
  },
246
259
  print: {
247
260
  color: "orange.7",
248
- leftSection: /* @__PURE__ */ jsx3(IconPrinter2, {}),
261
+ leftSection: /* @__PURE__ */ jsx4(IconPrinter2, {}),
249
262
  children: "In"
250
263
  },
251
264
  cancel: {
252
265
  color: "gray",
253
- leftSection: /* @__PURE__ */ jsx3(IconX2, {}),
266
+ leftSection: /* @__PURE__ */ jsx4(IconX2, {}),
254
267
  children: "H\u1EE7y thao t\xE1c"
255
268
  },
256
269
  select: {
@@ -261,22 +274,22 @@ var getActionConfig2 = (colorScheme) => ({
261
274
  },
262
275
  find: {
263
276
  color: "green",
264
- leftSection: /* @__PURE__ */ jsx3(IconSearch, {}),
277
+ leftSection: /* @__PURE__ */ jsx4(IconSearch, {}),
265
278
  children: "T\xECm"
266
279
  },
267
280
  tempDelete: {},
268
281
  tempUpdate: {
269
282
  color: "yellow",
270
- leftSection: /* @__PURE__ */ jsx3(IconPencil2, {})
283
+ leftSection: /* @__PURE__ */ jsx4(IconPencil2, {})
271
284
  },
272
285
  viewFile: {
273
286
  color: "cyan",
274
- leftSection: /* @__PURE__ */ jsx3(IconLivePhoto, {}),
287
+ leftSection: /* @__PURE__ */ jsx4(IconLivePhoto, {}),
275
288
  children: "Xem file"
276
289
  },
277
290
  sendMail: {
278
291
  color: "grape",
279
- leftSection: /* @__PURE__ */ jsx3(IconMail2, {}),
292
+ leftSection: /* @__PURE__ */ jsx4(IconMail2, {}),
280
293
  children: "G\u1EEDi mail"
281
294
  },
282
295
  view: {},
@@ -284,7 +297,7 @@ var getActionConfig2 = (colorScheme) => ({
284
297
  color: "indigo",
285
298
  variant: "outline",
286
299
  children: "Ki\u1EC3m tra",
287
- leftSection: /* @__PURE__ */ jsx3(IconChecklist, {})
300
+ leftSection: /* @__PURE__ */ jsx4(IconChecklist, {})
288
301
  }
289
302
  });
290
303
  function MyButton(_a) {
@@ -292,7 +305,7 @@ function MyButton(_a) {
292
305
  const permissionStore = useStore_Permission();
293
306
  const { colorScheme } = useMantineColorScheme3();
294
307
  if (!actionType2) {
295
- return /* @__PURE__ */ jsx3(Button, __spreadProps(__spreadValues({}, rest), { children }));
308
+ return /* @__PURE__ */ jsx4(Button, __spreadProps(__spreadValues({}, rest), { children }));
296
309
  }
297
310
  const config4 = actionType2 ? getActionConfig2(colorScheme)[actionType2] : {};
298
311
  const shouldHide = (() => {
@@ -300,20 +313,7 @@ function MyButton(_a) {
300
313
  return false;
301
314
  return actionType2 === "create" && permissionStore.state.currentPermissionPage.isCreate === false || actionType2 === "update" && permissionStore.state.currentPermissionPage.isUpdate === false || actionType2 === "delete" && permissionStore.state.currentPermissionPage.isDelete === false || actionType2 === "print" && permissionStore.state.currentPermissionPage.isPrint === false || actionType2 === "export" && permissionStore.state.currentPermissionPage.isExport === false;
302
315
  })();
303
- return /* @__PURE__ */ jsx3(Button, __spreadProps(__spreadValues(__spreadValues({ hidden: shouldHide }, config4), rest), { children: children ? children : config4.children }));
304
- }
305
-
306
- // src/core/button/MyButtonCreateUpdate.tsx
307
- import { Modal, ScrollArea, Space, Tooltip, useMantineColorScheme as useMantineColorScheme4 } from "@mantine/core";
308
- import { useDisclosure } from "@mantine/hooks";
309
- import { notifications } from "@mantine/notifications";
310
-
311
- // src/core/layout/MyFlexColumn.tsx
312
- import { Flex } from "@mantine/core";
313
- import { jsx as jsx4 } from "react/jsx-runtime";
314
- function MyFlexColumn(_a) {
315
- var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
316
- return /* @__PURE__ */ jsx4(Flex, __spreadProps(__spreadValues({ direction: "column", gap: "md" }, rest), { children }));
316
+ return /* @__PURE__ */ jsx4(Button, __spreadProps(__spreadValues(__spreadValues({ hidden: shouldHide }, config4), rest), { children: children ? children : config4.children }));
317
317
  }
318
318
 
319
319
  // src/core/button/MyButtonCreateUpdate.tsx
@@ -18586,9 +18586,9 @@ export {
18586
18586
  MyButtonModal2 as MyButtonModal,
18587
18587
  AQButtonCreateByImportFile,
18588
18588
  CustomSwitchTheme,
18589
+ MyFlexColumn as MyFlexColumn2,
18589
18590
  MyActionIcon as MyActionIcon2,
18590
18591
  MyButton as MyButton2,
18591
- MyFlexColumn as MyFlexColumn2,
18592
18592
  MyButtonCreateUpdate,
18593
18593
  MyButtonModal as MyButtonModal2,
18594
18594
  MyButtonModalForm,
@@ -8,8 +8,8 @@ import { type_mantineSize } from '../types/index.mjs';
8
8
  import { useDisclosure, useListState } from '@mantine/hooks';
9
9
  import { UseFormReturnType, useForm } from '@mantine/form';
10
10
  import { I as I_BasicAppShell_LinkItem, B as BasicAppShellProps } from '../types-km2g-xx5.mjs';
11
- import { f as MyButtonModal$1 } from '../MyDataTable-Rd5T597g.mjs';
12
- export { h as MyDataTable, g as MyDataTableInternalProps, c as MyDataTableProps, P as PaginationState } from '../MyDataTable-Rd5T597g.mjs';
11
+ import { d as MyButtonModal$1 } from '../MyDataTable-Ra7SXzdJ.mjs';
12
+ export { h as MyDataTable, g as MyDataTableInternalProps, c as MyDataTableProps, P as PaginationState } from '../MyDataTable-Ra7SXzdJ.mjs';
13
13
  import { I as IUtils_Excel_ColumnConfig } from '../utils_excel-BfUQ3dS3.mjs';
14
14
  import { MRT_ColumnDef, MRT_RowData, MRT_TableOptions, MRT_TableInstance } from 'mantine-react-table';
15
15
  import { DateInputProps } from '@mantine/dates';
@@ -68,13 +68,13 @@ import {
68
68
  useHeaderMegaMenuStore,
69
69
  useS_ButtonImport,
70
70
  useStore_BasicAppShell
71
- } from "../chunk-AMXMIGSV.mjs";
71
+ } from "../chunk-5AAOMULT.mjs";
72
72
  import "../chunk-BJAYNNOF.mjs";
73
73
  import "../chunk-KGBXMHKR.mjs";
74
74
  import "../chunk-ZDINCHBS.mjs";
75
75
  import "../chunk-YGWSHSTG.mjs";
76
- import "../chunk-K6S7R6LU.mjs";
77
76
  import "../chunk-SPG47QW7.mjs";
77
+ import "../chunk-K6S7R6LU.mjs";
78
78
  import "../chunk-G2IMUVMM.mjs";
79
79
  import "../chunk-WZ6PXGGC.mjs";
80
80
  import "../chunk-YWANA62C.mjs";
@@ -1,12 +1,12 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { M as MyActionIconProps, a as MyButtonProps, b as MyButtonModalProps, c as MyDataTableProps } from '../MyDataTable-Rd5T597g.mjs';
3
- export { d as MyActionIcon, e as MyButton, f as MyButtonModal } from '../MyDataTable-Rd5T597g.mjs';
4
2
  import { ReactNode, ComponentProps } from 'react';
5
3
  import { useDisclosure } from '@mantine/hooks';
6
4
  import { UseFormReturnType } from '@mantine/form';
7
5
  import { AxiosResponse } from 'axios';
8
6
  import { M as MyApiResponse, a as MyReactMutationProps } from '../useMyReactMutation-D8XdiELk.mjs';
9
7
  import { ModalProps, ScrollAreaAutosizeProps, TooltipProps, ButtonProps, BadgeProps, TextProps, PaperProps, GroupProps, ThemeIconProps, AutocompleteProps, NumberInputProps, TextInputProps, FileInputProps, InputWrapperProps, FlexProps } from '@mantine/core';
8
+ import { M as MyActionIconProps, a as MyButtonProps, b as MyButtonModalProps, c as MyDataTableProps } from '../MyDataTable-Ra7SXzdJ.mjs';
9
+ export { e as MyActionIcon, f as MyButton, d as MyButtonModal } from '../MyDataTable-Ra7SXzdJ.mjs';
10
10
  import { UseReactToPrintOptions } from 'react-to-print';
11
11
  import { I as IAQFileDetail } from '../utils_file-JlhzjLGS.mjs';
12
12
  import { TablerIcon } from '@tabler/icons-react';
@@ -17,8 +17,8 @@ import { UseEditorOptions } from '@tiptap/react';
17
17
  import { M as MySelectProps } from '../MySelect-CEgpggSF.mjs';
18
18
  export { a as MySelect } from '../MySelect-CEgpggSF.mjs';
19
19
  import { I as IBaseEntity } from '../IBaseEntity-Am9Cgybw.mjs';
20
- import '../type_action-Bt__6lee.mjs';
21
20
  import '../type_mutation-CCtnyeP3.mjs';
21
+ import '../type_action-Bt__6lee.mjs';
22
22
 
23
23
  declare function CustomSwitchTheme(): react_jsx_runtime.JSX.Element | null;
24
24
 
@@ -31,13 +31,13 @@ import {
31
31
  MyStatsCard,
32
32
  MyTextInput2 as MyTextInput,
33
33
  MyWeeklySessionSchedulerPicker
34
- } from "../chunk-AMXMIGSV.mjs";
34
+ } from "../chunk-5AAOMULT.mjs";
35
35
  import "../chunk-BJAYNNOF.mjs";
36
36
  import "../chunk-KGBXMHKR.mjs";
37
37
  import "../chunk-ZDINCHBS.mjs";
38
38
  import "../chunk-YGWSHSTG.mjs";
39
- import "../chunk-K6S7R6LU.mjs";
40
39
  import "../chunk-SPG47QW7.mjs";
40
+ import "../chunk-K6S7R6LU.mjs";
41
41
  import "../chunk-G2IMUVMM.mjs";
42
42
  import "../chunk-WZ6PXGGC.mjs";
43
43
  import "../chunk-YWANA62C.mjs";
@@ -102,13 +102,13 @@ import {
102
102
  MailTemplateDeleteButton,
103
103
  useS_moduleConfig,
104
104
  useStore_Authenticate
105
- } from "../chunk-AMXMIGSV.mjs";
105
+ } from "../chunk-5AAOMULT.mjs";
106
106
  import "../chunk-BJAYNNOF.mjs";
107
107
  import "../chunk-KGBXMHKR.mjs";
108
108
  import "../chunk-ZDINCHBS.mjs";
109
109
  import "../chunk-YGWSHSTG.mjs";
110
- import "../chunk-K6S7R6LU.mjs";
111
110
  import "../chunk-SPG47QW7.mjs";
111
+ import "../chunk-K6S7R6LU.mjs";
112
112
  import "../chunk-G2IMUVMM.mjs";
113
113
  import "../chunk-WZ6PXGGC.mjs";
114
114
  import "../chunk-YWANA62C.mjs";
@@ -4,15 +4,15 @@ import {
4
4
  } from "../chunk-RGUQWALX.mjs";
5
5
  import {
6
6
  MySelect
7
- } from "../chunk-AMXMIGSV.mjs";
7
+ } from "../chunk-5AAOMULT.mjs";
8
8
  import "../chunk-BJAYNNOF.mjs";
9
9
  import "../chunk-KGBXMHKR.mjs";
10
10
  import {
11
11
  utils_converter
12
12
  } from "../chunk-ZDINCHBS.mjs";
13
13
  import "../chunk-YGWSHSTG.mjs";
14
- import "../chunk-K6S7R6LU.mjs";
15
14
  import "../chunk-SPG47QW7.mjs";
15
+ import "../chunk-K6S7R6LU.mjs";
16
16
  import "../chunk-G2IMUVMM.mjs";
17
17
  import "../chunk-WZ6PXGGC.mjs";
18
18
  import "../chunk-YWANA62C.mjs";
package/package.json CHANGED
@@ -54,7 +54,7 @@
54
54
  "types": "./dist/build-object/index.d.mts"
55
55
  }
56
56
  },
57
- "version": "0.1.966",
57
+ "version": "0.1.967",
58
58
  "private": false,
59
59
  "files": [
60
60
  "dist"