aq-fe-framework 0.1.527 → 0.1.528

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.
@@ -1,5 +1,4 @@
1
1
  import {
2
- MyButton,
3
2
  MyDataTable,
4
3
  MyFlexColumn,
5
4
  MyFlexRow
@@ -176,7 +175,7 @@ var getActionConfig2 = (colorScheme) => ({
176
175
  children: "T\xECm"
177
176
  }
178
177
  });
179
- function MyButton2(_a) {
178
+ function MyButton(_a) {
180
179
  var _b = _a, { children, actionType } = _b, rest = __objRest(_b, ["children", "actionType"]);
181
180
  const { colorScheme } = useMantineColorScheme2();
182
181
  if (!actionType) {
@@ -308,7 +307,7 @@ function MyButtonCreateUpdate({
308
307
  })
309
308
  ),
310
309
  /* @__PURE__ */ jsx4(Space, {}),
311
- /* @__PURE__ */ jsx4(MyButton2, { fullWidth: true, actionType: "save" })
310
+ /* @__PURE__ */ jsx4(MyButton, { fullWidth: true, actionType: "save" })
312
311
  ]
313
312
  }
314
313
  )
@@ -347,7 +346,7 @@ function MyButtonModal({
347
346
  onClick: disclosure == null ? void 0 : disclosure[1].open
348
347
  }, actionIconProps)
349
348
  ) : /* @__PURE__ */ jsx6(
350
- MyButton2,
349
+ MyButton,
351
350
  __spreadValues({
352
351
  onClick: disclosure == null ? void 0 : disclosure[1].open
353
352
  }, buttonProps)
@@ -397,7 +396,7 @@ function MyButtonModalForm(_a) {
397
396
  children: /* @__PURE__ */ jsx8("form", { onSubmit: form.onSubmit(onSubmit), children: /* @__PURE__ */ jsxs4(Stack, { children: [
398
397
  children,
399
398
  /* @__PURE__ */ jsx8(
400
- MyButton2,
399
+ MyButton,
401
400
  {
402
401
  actionType: "save",
403
402
  loading: isLoading
@@ -1058,67 +1057,9 @@ function MyFlexEnd2(_a) {
1058
1057
  return /* @__PURE__ */ jsx21(Group5, __spreadProps(__spreadValues({ justify: "end", mt: "md" }, rest), { children }));
1059
1058
  }
1060
1059
 
1061
- // src/core/overlays/MyModalDelete.tsx
1062
- import { Group as Group6, Highlight as Highlight2, Modal as Modal3 } from "@mantine/core";
1063
- import { jsx as jsx22, jsxs as jsxs12 } from "react/jsx-runtime";
1064
- function MyModalDelete(_a) {
1065
- var _b = _a, {
1066
- disclosure,
1067
- contextData,
1068
- onSubmit,
1069
- submitLoading
1070
- } = _b, rest = __objRest(_b, [
1071
- "disclosure",
1072
- "contextData",
1073
- "onSubmit",
1074
- "submitLoading"
1075
- ]);
1076
- return /* @__PURE__ */ jsxs12(
1077
- Modal3,
1078
- __spreadProps(__spreadValues({
1079
- title: "X\xF3a d\u1EEF li\u1EC7u",
1080
- onClose: disclosure[1].close,
1081
- opened: disclosure[0]
1082
- }, rest), {
1083
- children: [
1084
- /* @__PURE__ */ jsx22(
1085
- Highlight2,
1086
- {
1087
- highlight: contextData || [],
1088
- color: "red.6",
1089
- highlightStyles: {
1090
- fontWeight: 700,
1091
- WebkitBackgroundClip: "text",
1092
- WebkitTextFillColor: "transparent"
1093
- },
1094
- children: `B\u1EA1n s\u1EAFp x\xF3a d\u1EEF li\u1EC7u ${contextData || ""}. H\xE0nh \u0111\u1ED9ng n\xE0y kh\xF4ng th\u1EC3 ho\xE0n t\xE1c. B\u1EA1n c\xF3 ch\u1EAFc ch\u1EAFn mu\u1ED1n ti\u1EBFp t\u1EE5c?`
1095
- }
1096
- ),
1097
- /* @__PURE__ */ jsxs12(Group6, { grow: true, children: [
1098
- /* @__PURE__ */ jsx22(
1099
- MyButton,
1100
- {
1101
- crudType: "delete",
1102
- onClick: onSubmit,
1103
- loading: submitLoading
1104
- }
1105
- ),
1106
- /* @__PURE__ */ jsx22(
1107
- MyButton,
1108
- {
1109
- crudType: "cancel",
1110
- onClick: disclosure[1].close
1111
- }
1112
- )
1113
- ] })
1114
- ]
1115
- })
1116
- );
1117
- }
1118
-
1119
1060
  export {
1120
1061
  MyActionIcon,
1121
- MyButton2 as MyButton,
1062
+ MyButton,
1122
1063
  MyFlexColumn2 as MyFlexColumn,
1123
1064
  MyButtonCreateUpdate,
1124
1065
  MyButtonModal,
@@ -1135,6 +1076,5 @@ export {
1135
1076
  MySelectFromAPI,
1136
1077
  MyTextInput,
1137
1078
  MyWeeklySessionSchedulerPicker,
1138
- MyFlexEnd2 as MyFlexEnd,
1139
- MyModalDelete
1079
+ MyFlexEnd2 as MyFlexEnd
1140
1080
  };
@@ -0,0 +1,70 @@
1
+ import {
2
+ MyButton
3
+ } from "./chunk-PFOC2A7E.mjs";
4
+ import {
5
+ __objRest,
6
+ __spreadProps,
7
+ __spreadValues
8
+ } from "./chunk-FWCSY2DS.mjs";
9
+
10
+ // src/core/overlays/MyModalDelete.tsx
11
+ import { Group, Highlight, Modal } from "@mantine/core";
12
+ import { jsx, jsxs } from "react/jsx-runtime";
13
+ function MyModalDelete(_a) {
14
+ var _b = _a, {
15
+ disclosure,
16
+ contextData,
17
+ onSubmit,
18
+ submitLoading
19
+ } = _b, rest = __objRest(_b, [
20
+ "disclosure",
21
+ "contextData",
22
+ "onSubmit",
23
+ "submitLoading"
24
+ ]);
25
+ return /* @__PURE__ */ jsxs(
26
+ Modal,
27
+ __spreadProps(__spreadValues({
28
+ title: "X\xF3a d\u1EEF li\u1EC7u",
29
+ onClose: disclosure[1].close,
30
+ opened: disclosure[0]
31
+ }, rest), {
32
+ children: [
33
+ /* @__PURE__ */ jsx(
34
+ Highlight,
35
+ {
36
+ highlight: contextData || [],
37
+ color: "red.6",
38
+ highlightStyles: {
39
+ fontWeight: 700,
40
+ WebkitBackgroundClip: "text",
41
+ WebkitTextFillColor: "transparent"
42
+ },
43
+ children: `B\u1EA1n s\u1EAFp x\xF3a d\u1EEF li\u1EC7u ${contextData || ""}. H\xE0nh \u0111\u1ED9ng n\xE0y kh\xF4ng th\u1EC3 ho\xE0n t\xE1c. B\u1EA1n c\xF3 ch\u1EAFc ch\u1EAFn mu\u1ED1n ti\u1EBFp t\u1EE5c?`
44
+ }
45
+ ),
46
+ /* @__PURE__ */ jsxs(Group, { grow: true, children: [
47
+ /* @__PURE__ */ jsx(
48
+ MyButton,
49
+ {
50
+ crudType: "delete",
51
+ onClick: onSubmit,
52
+ loading: submitLoading
53
+ }
54
+ ),
55
+ /* @__PURE__ */ jsx(
56
+ MyButton,
57
+ {
58
+ crudType: "cancel",
59
+ onClick: disclosure[1].close
60
+ }
61
+ )
62
+ ] })
63
+ ]
64
+ })
65
+ );
66
+ }
67
+
68
+ export {
69
+ MyModalDelete
70
+ };
@@ -8,7 +8,7 @@ import { useDisclosure, useListState } from '@mantine/hooks';
8
8
  import { UseFormReturnType, useForm } from '@mantine/form';
9
9
  import { I as I_BasicAppShell_LinkItem } from '../BasicAppShell-BOu5-Gvr.mjs';
10
10
  export { a as BasicAppShell, B as BasicAppShell_transformMenuToEnum, f as flattenMenuGroups, g as groupToTwoLevels, u as utils_layout_getItemsWithoutLinks } from '../BasicAppShell-BOu5-Gvr.mjs';
11
- import { I as IUtils_Excel_ColumnConfig, a as IAQFileDetail } from '../utils_file-G8NTHCO-.mjs';
11
+ import { I as IUtils_Excel_ColumnConfig, b as IAQFileDetail } from '../utils_file-Dy33UVzg.mjs';
12
12
  import { MRT_ColumnDef, MRT_RowData, MRT_TableOptions, MRT_TableInstance } from 'mantine-react-table';
13
13
  import { DateInputProps } from '@mantine/dates';
14
14
  import { RichTextEditorProps } from '@mantine/tiptap';
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import { t as type_action } from '../types-DbltiEAP.mjs';
3
- import { ActionIconProps, ButtonProps, ModalProps, ScrollAreaAutosizeProps, TextProps, PaperProps, GroupProps, ThemeIconProps, InputWrapperProps, SelectProps, TextInputProps, FlexProps } from '@mantine/core';
3
+ import { ModalProps, ActionIconProps, ButtonProps, ScrollAreaAutosizeProps, TextProps, PaperProps, GroupProps, ThemeIconProps, InputWrapperProps, SelectProps, TextInputProps, FlexProps } from '@mantine/core';
4
4
  import { ReactNode, ButtonHTMLAttributes } from 'react';
5
5
  import { UseFormReturnType } from '@mantine/form';
6
6
  import { AxiosResponse } from 'axios';
@@ -12,6 +12,14 @@ import { MRT_RowData, MRT_ColumnDef } from 'mantine-react-table';
12
12
  import { RichTextEditorProps, RichTextEditorToolbarProps, RichTextEditorContentProps } from '@mantine/tiptap';
13
13
  import { I as IBaseEntity } from '../IBaseEntity-ChMy9RzQ.mjs';
14
14
 
15
+ interface MyModalDeleteProps extends Omit<ModalProps, "opened" | "onClose"> {
16
+ disclosure: ReturnType<typeof useDisclosure>;
17
+ contextData?: string;
18
+ onSubmit?: () => void;
19
+ submitLoading?: boolean;
20
+ }
21
+ declare function MyModalDelete({ disclosure, contextData, onSubmit, submitLoading, ...rest }: MyModalDeleteProps): react_jsx_runtime.JSX.Element;
22
+
15
23
  interface MyActionIconProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "color" | "style">, ActionIconProps {
16
24
  actionType?: type_action;
17
25
  }
@@ -196,12 +204,4 @@ interface MyFlexEndProps extends GroupProps {
196
204
  }
197
205
  declare function MyFlexEnd({ children, ...rest }: MyFlexEndProps): react_jsx_runtime.JSX.Element;
198
206
 
199
- interface MyModalDeleteProps extends Omit<ModalProps, "opened" | "onClose"> {
200
- disclosure: ReturnType<typeof useDisclosure>;
201
- contextData?: string;
202
- onSubmit?: () => void;
203
- submitLoading?: boolean;
204
- }
205
- declare function MyModalDelete({ disclosure, contextData, onSubmit, submitLoading, ...rest }: MyModalDeleteProps): react_jsx_runtime.JSX.Element;
206
-
207
207
  export { type IWeeklySession, MyActionIcon, type MyActionIconProps, MyButton, MyButtonCreateUpdate, type MyButtonExportStructureProps, MyButtonModal, MyButtonModalForm, type MyButtonModalFormProps, type MyButtonModalProps, MyButtonPrintPDF, type MyButtonPrintPDFProps, type MyButtonProps$1 as MyButtonProps, MyDataTableSelectOne, MyDayOfWeekPicker, MyFlexColumn, MyFlexEnd, MyFlexIconTitle, MyInfoBox, type MyInfoBoxItem, type MyInfoBoxProps, MyLabelValueRow, MyModalDelete, type MyModalDeleteProps, MyRichTextEditor, MySelect, MySelectFromAPI, type MySelectFromAPIProps, type MySelectProps, MyStatsCard, MyTextInput, MyWeeklySessionSchedulerPicker, type WeeklySessionSchedulerProps };
@@ -12,14 +12,16 @@ import {
12
12
  MyFlexIconTitle,
13
13
  MyInfoBox,
14
14
  MyLabelValueRow,
15
- MyModalDelete,
16
15
  MyRichTextEditor,
17
16
  MySelect,
18
17
  MySelectFromAPI,
19
18
  MyStatsCard,
20
19
  MyTextInput,
21
20
  MyWeeklySessionSchedulerPicker
22
- } from "../chunk-FOE3PTQC.mjs";
21
+ } from "../chunk-IMBXTNPQ.mjs";
22
+ import {
23
+ MyModalDelete
24
+ } from "../chunk-LWFI4LKU.mjs";
23
25
  import "../chunk-PFOC2A7E.mjs";
24
26
  import "../chunk-U62R2QKJ.mjs";
25
27
  import "../chunk-5U2JSHSJ.mjs";
@@ -0,0 +1,94 @@
1
+ /* src/components/Layouts/HeaderMegaMenu/css.module.css */
2
+ .header {
3
+ position: sticky;
4
+ top: 0;
5
+ z-index: 1;
6
+ height: calc(3.75rem * var(--mantine-scale));
7
+ background-color: var(--mantine-color-white);
8
+ }
9
+ [data-mantine-color-scheme=dark] .header {
10
+ background-color: var(--mantine-color-dark);
11
+ }
12
+ .header {
13
+ padding-left: var(--mantine-spacing-md);
14
+ padding-right: var(--mantine-spacing-md);
15
+ border-bottom: 1px solid var(--mantine-color-gray-3);
16
+ }
17
+ [data-mantine-color-scheme=dark] .header {
18
+ border-bottom: 1px solid var(--mantine-color-dark-4);
19
+ }
20
+ .link {
21
+ display: flex;
22
+ align-items: center;
23
+ height: 100%;
24
+ padding-left: var(--mantine-spacing-md);
25
+ padding-right: var(--mantine-spacing-md);
26
+ text-decoration: none;
27
+ color: var(--mantine-color-black);
28
+ }
29
+ [data-mantine-color-scheme=dark] .link {
30
+ color: var(--mantine-color-white);
31
+ }
32
+ .link {
33
+ font-weight: 500;
34
+ font-size: var(--mantine-font-size-sm);
35
+ }
36
+ @media (max-width: $mantine-breakpoint-sm) {
37
+ .link {
38
+ height: calc(2.625rem * var(--mantine-scale));
39
+ width: 100%;
40
+ }
41
+ }
42
+ @media (hover: hover) {
43
+ .link:hover {
44
+ background-color: var(--mantine-color-gray-0);
45
+ }
46
+ [data-mantine-color-scheme=dark] .link:hover {
47
+ background-color: var(--mantine-color-dark-6);
48
+ }
49
+ }
50
+ @media (hover: none) {
51
+ .link:active {
52
+ background-color: var(--mantine-color-gray-0);
53
+ }
54
+ [data-mantine-color-scheme=dark] .link:active {
55
+ background-color: var(--mantine-color-dark-6);
56
+ }
57
+ }
58
+ .subLink {
59
+ width: 100%;
60
+ padding: var(--mantine-spacing-xs) var(--mantine-spacing-md);
61
+ border-radius: var(--mantine-radius-md);
62
+ }
63
+ @media (hover: hover) {
64
+ .subLink:hover {
65
+ background-color: var(--mantine-color-gray-0);
66
+ }
67
+ [data-mantine-color-scheme=dark] .subLink:hover {
68
+ background-color: var(--mantine-color-dark-7);
69
+ }
70
+ }
71
+ @media (hover: none) {
72
+ .subLink:active {
73
+ background-color: var(--mantine-color-gray-0);
74
+ }
75
+ [data-mantine-color-scheme=dark] .subLink:active {
76
+ background-color: var(--mantine-color-dark-7);
77
+ }
78
+ }
79
+ .dropdownFooter {
80
+ background-color: var(--mantine-color-gray-0);
81
+ }
82
+ [data-mantine-color-scheme=dark] .dropdownFooter {
83
+ background-color: var(--mantine-color-dark-7);
84
+ }
85
+ .dropdownFooter {
86
+ margin: calc(var(--mantine-spacing-md) * -1);
87
+ margin-top: var(--mantine-spacing-sm);
88
+ padding: var(--mantine-spacing-md) calc(var(--mantine-spacing-md) * 2);
89
+ padding-bottom: var(--mantine-spacing-xl);
90
+ border-top: 1px solid var(--mantine-color-gray-1);
91
+ }
92
+ [data-mantine-color-scheme=dark] .dropdownFooter {
93
+ border-top: 1px solid var(--mantine-color-dark-5);
94
+ }
@@ -0,0 +1,2 @@
1
+
2
+ export { }
@@ -0,0 +1,12 @@
1
+ import "../chunk-LWFI4LKU.mjs";
2
+ import "../chunk-PFOC2A7E.mjs";
3
+ import "../chunk-U62R2QKJ.mjs";
4
+ import "../chunk-5U2JSHSJ.mjs";
5
+ import "../chunk-OMJJAHOC.mjs";
6
+ import "../chunk-DH6RVK5I.mjs";
7
+ import "../chunk-7ZCOFATU.mjs";
8
+ import "../chunk-FWCSY2DS.mjs";
9
+
10
+ // src/coreService/overlays/MyModalDeleteService.tsx
11
+ import { useState } from "react";
12
+ import { jsx } from "react/jsx-runtime";
@@ -16,7 +16,8 @@ import {
16
16
  MyButton as MyButton2,
17
17
  MyDataTableSelectOne,
18
18
  MyTextInput as MyTextInput2
19
- } from "../chunk-FOE3PTQC.mjs";
19
+ } from "../chunk-IMBXTNPQ.mjs";
20
+ import "../chunk-LWFI4LKU.mjs";
20
21
  import {
21
22
  F_authenticate_Logout,
22
23
  MyActionIconDelete,
@@ -1,4 +1,4 @@
1
- export { a as IAQFileDetail, I as IUtils_Excel_ColumnConfig, b as utils_excel_download, u as utils_excel_exportExcel, d as utils_file_AQDocumentTypeToFile, e as utils_file_docxtemplaterDownload, c as utils_file_fileToAQDocumentType } from '../utils_file-G8NTHCO-.mjs';
1
+ export { b as IAQFileDetail, I as IUtils_Excel_ColumnConfig, a as utils_excel_download, u as utils_excel_exportExcel, d as utils_file_AQDocumentTypeToFile, e as utils_file_docxtemplaterDownload, c as utils_file_fileToAQDocumentType } from '../utils_file-Dy33UVzg.mjs';
2
2
  import { I as IBaseEntity } from '../IBaseEntity-ChMy9RzQ.mjs';
3
3
  import { MRT_RowData, MRT_ColumnDef } from 'mantine-react-table';
4
4
  import { DefaultMantineColor } from '@mantine/core';
@@ -33,4 +33,4 @@ declare function utils_file_docxtemplaterDownload({ data, filePath, fileName }:
33
33
  fileName?: string;
34
34
  }): Promise<void>;
35
35
 
36
- export { type IUtils_Excel_ColumnConfig as I, type IAQFileDetail as a, utils_excel_download as b, utils_file_fileToAQDocumentType as c, utils_file_AQDocumentTypeToFile as d, utils_file_docxtemplaterDownload as e, utils_excel_exportExcel as u };
36
+ export { type IUtils_Excel_ColumnConfig as I, utils_excel_download as a, type IAQFileDetail as b, utils_file_fileToAQDocumentType as c, utils_file_AQDocumentTypeToFile as d, utils_file_docxtemplaterDownload as e, utils_excel_exportExcel as u };
package/package.json CHANGED
@@ -40,9 +40,13 @@
40
40
  "./columns": {
41
41
  "import": "./dist/columns/index.mjs",
42
42
  "types": "./dist/columns/index.d.mts"
43
+ },
44
+ "./coreService": {
45
+ "import": "./dist/coreService/index.mjs",
46
+ "types": "./dist/coreService/index.d.mts"
43
47
  }
44
48
  },
45
- "version": "0.1.527",
49
+ "version": "0.1.528",
46
50
  "private": false,
47
51
  "files": [
48
52
  "dist"