aq-fe-framework 0.1.318 → 0.1.320
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/chunk-2SBUKAGS.mjs +20 -0
- package/dist/chunk-BZMQOGL6.mjs +13 -0
- package/dist/{chunk-FUHOV7NB.mjs → chunk-FAG4PGP2.mjs} +330 -477
- package/dist/{chunk-VECMRDKG.mjs → chunk-FBGCXKGK.mjs} +0 -36
- package/dist/chunk-GEYCGM75.mjs +178 -0
- package/dist/{chunk-ZZ7S4EA4.mjs → chunk-HEW5D3R4.mjs} +65 -25
- package/dist/chunk-I2XIN2R3.mjs +38 -0
- package/dist/{chunk-YJ32RSH2.mjs → chunk-YQPDRFRL.mjs} +1 -1
- package/dist/columns/index.d.mts +6 -0
- package/dist/columns/index.mjs +8 -0
- package/dist/components/index.d.mts +3 -1
- package/dist/components/index.mjs +5 -5
- package/dist/const/index.mjs +12 -2
- package/dist/core/index.d.mts +10 -1
- package/dist/core/index.mjs +6 -4
- package/dist/hooks/index.d.mts +2 -2
- package/dist/hooks/index.mjs +1 -1
- package/dist/interfaces/index.d.mts +8 -446
- package/dist/modules-features/index.d.mts +54 -55
- package/dist/modules-features/index.mjs +247 -339
- package/dist/utils/index.mjs +7 -5
- package/package.json +5 -1
- package/dist/chunk-GFEMKKFH.mjs +0 -25
- package/dist/chunk-HHJFKKE7.mjs +0 -26
@@ -1,10 +1,14 @@
|
|
1
|
+
import {
|
2
|
+
createGenericStore
|
3
|
+
} from "./chunk-Y3YGC5IH.mjs";
|
1
4
|
import {
|
2
5
|
utils_pdf_download
|
3
6
|
} from "./chunk-5U2JSHSJ.mjs";
|
4
7
|
import {
|
8
|
+
MyDataTable,
|
5
9
|
MyFlexColumn,
|
6
10
|
MyFlexRow
|
7
|
-
} from "./chunk-
|
11
|
+
} from "./chunk-GEYCGM75.mjs";
|
8
12
|
import {
|
9
13
|
const_object_colors
|
10
14
|
} from "./chunk-NWBLJ3W3.mjs";
|
@@ -12,13 +16,10 @@ import {
|
|
12
16
|
baseAxios_default,
|
13
17
|
useMyReactMutation,
|
14
18
|
useQ_AQ_GetAQModule
|
15
|
-
} from "./chunk-
|
19
|
+
} from "./chunk-YQPDRFRL.mjs";
|
16
20
|
import {
|
17
21
|
utils_notification_show
|
18
22
|
} from "./chunk-7ZCOFATU.mjs";
|
19
|
-
import {
|
20
|
-
createGenericStore
|
21
|
-
} from "./chunk-Y3YGC5IH.mjs";
|
22
23
|
import {
|
23
24
|
__objRest,
|
24
25
|
__spreadProps,
|
@@ -1219,7 +1220,7 @@ function MyButtonDeleteList(_a) {
|
|
1219
1220
|
}
|
1220
1221
|
|
1221
1222
|
// src/components/Button/ButtonImport/MyButtonImport.tsx
|
1222
|
-
import { Button as
|
1223
|
+
import { Button as Button7, Modal as Modal8, useModalsStack as useModalsStack3 } from "@mantine/core";
|
1223
1224
|
import { IconFileImport as IconFileImport2 } from "@tabler/icons-react";
|
1224
1225
|
|
1225
1226
|
// src/components/Combobox/Select/MySelect.tsx
|
@@ -1495,168 +1496,21 @@ function SelectFieldModal({ stack, onImport }) {
|
|
1495
1496
|
] }));
|
1496
1497
|
}
|
1497
1498
|
|
1498
|
-
// src/components/DataDisplay/DataTable/MyDataTable.tsx
|
1499
|
-
import { Alert, Button as Button6, Center as Center2, Group as Group8, Portal, Text as Text6 } from "@mantine/core";
|
1500
|
-
import { IconBug, IconDownload as IconDownload3 } from "@tabler/icons-react";
|
1501
|
-
import { download, generateCsv, mkConfig } from "export-to-csv";
|
1502
|
-
import {
|
1503
|
-
MantineReactTable,
|
1504
|
-
useMantineReactTable
|
1505
|
-
} from "mantine-react-table";
|
1506
|
-
import { MRT_Localization_VI } from "mantine-react-table/locales/vi/index.cjs";
|
1507
|
-
import { useEffect as useEffect5 } from "react";
|
1508
|
-
import { Fragment as Fragment7, jsx as jsx25, jsxs as jsxs14 } from "react/jsx-runtime";
|
1509
|
-
function formatData(data, formats) {
|
1510
|
-
return data.map((row) => {
|
1511
|
-
const transformedRow = {};
|
1512
|
-
Object.entries(row).forEach(([key, value]) => {
|
1513
|
-
const formatFn = formats[key];
|
1514
|
-
if (value instanceof Date) {
|
1515
|
-
transformedRow[key] = formatFn ? formatFn(value.toISOString()) : value.toISOString();
|
1516
|
-
} else if (value !== null && typeof value === "object") {
|
1517
|
-
transformedRow[key] = formatFn ? formatFn(JSON.stringify(value)) : JSON.stringify(value);
|
1518
|
-
} else {
|
1519
|
-
transformedRow[key] = formatFn ? formatFn(value) : value;
|
1520
|
-
}
|
1521
|
-
});
|
1522
|
-
return transformedRow;
|
1523
|
-
});
|
1524
|
-
}
|
1525
|
-
function MyDataTable(_a) {
|
1526
|
-
var _b = _a, {
|
1527
|
-
formats = {},
|
1528
|
-
exportAble = false,
|
1529
|
-
csvConfigProps,
|
1530
|
-
rowActionSize,
|
1531
|
-
columns,
|
1532
|
-
data,
|
1533
|
-
renderTopToolbarCustomActions,
|
1534
|
-
setSelectedRow,
|
1535
|
-
isError,
|
1536
|
-
isLoading,
|
1537
|
-
pagination
|
1538
|
-
} = _b, rest = __objRest(_b, [
|
1539
|
-
"formats",
|
1540
|
-
"exportAble",
|
1541
|
-
"csvConfigProps",
|
1542
|
-
"rowActionSize",
|
1543
|
-
"columns",
|
1544
|
-
"data",
|
1545
|
-
"renderTopToolbarCustomActions",
|
1546
|
-
"setSelectedRow",
|
1547
|
-
"isError",
|
1548
|
-
"isLoading",
|
1549
|
-
"pagination"
|
1550
|
-
]);
|
1551
|
-
const { renderRowActions } = __spreadValues({}, rest);
|
1552
|
-
const csvConfig = mkConfig(__spreadValues({
|
1553
|
-
fieldSeparator: ",",
|
1554
|
-
decimalSeparator: ".",
|
1555
|
-
useKeysAsHeaders: (csvConfigProps == null ? void 0 : csvConfigProps.columnHeaders) ? false : true
|
1556
|
-
}, csvConfigProps));
|
1557
|
-
const handleExport = (rows) => {
|
1558
|
-
if (rows.length == 0) {
|
1559
|
-
const transformedData = formatData(data, formats);
|
1560
|
-
const csv2 = generateCsv(csvConfig)(transformedData);
|
1561
|
-
download(csvConfig)(csv2);
|
1562
|
-
return;
|
1563
|
-
}
|
1564
|
-
const rowData = rows.map((row) => row.original);
|
1565
|
-
const transformedRows = formatData(rowData, formats);
|
1566
|
-
const csv = generateCsv(csvConfig)(transformedRows);
|
1567
|
-
download(csvConfig)(csv);
|
1568
|
-
};
|
1569
|
-
const table = useMantineReactTable(__spreadValues({
|
1570
|
-
columns,
|
1571
|
-
data,
|
1572
|
-
renderTopToolbarCustomActions: ({ table: table2 }) => {
|
1573
|
-
return /* @__PURE__ */ jsxs14(Group8, { children: [
|
1574
|
-
renderTopToolbarCustomActions && renderTopToolbarCustomActions({ table: table2 }),
|
1575
|
-
exportAble && /* @__PURE__ */ jsx25(Fragment7, { children: /* @__PURE__ */ jsx25(
|
1576
|
-
Button6,
|
1577
|
-
{
|
1578
|
-
color: "green.8",
|
1579
|
-
onClick: () => handleExport(table2.getSelectedRowModel().rows),
|
1580
|
-
leftSection: /* @__PURE__ */ jsx25(IconDownload3, {}),
|
1581
|
-
variant: "filled",
|
1582
|
-
children: "Export"
|
1583
|
-
}
|
1584
|
-
) })
|
1585
|
-
] });
|
1586
|
-
},
|
1587
|
-
manualPagination: true,
|
1588
|
-
enableRowNumbers: true,
|
1589
|
-
enableRowSelection: exportAble,
|
1590
|
-
enableEditing: renderRowActions ? true : false,
|
1591
|
-
positionActionsColumn: "last",
|
1592
|
-
enableColumnResizing: true,
|
1593
|
-
layoutMode: "semantic",
|
1594
|
-
displayColumnDefOptions: {
|
1595
|
-
"mrt-row-actions": {
|
1596
|
-
header: "Thao t\xE1c",
|
1597
|
-
size: rowActionSize
|
1598
|
-
},
|
1599
|
-
"mrt-row-numbers": {
|
1600
|
-
Header: "STT",
|
1601
|
-
size: 1
|
1602
|
-
}
|
1603
|
-
},
|
1604
|
-
enableColumnPinning: true,
|
1605
|
-
initialState: {
|
1606
|
-
// pagination: pagination ? pagination : { pageIndex: 0, pageSize: 10 },
|
1607
|
-
density: "md",
|
1608
|
-
columnPinning: { right: ["mrt-row-actions"] },
|
1609
|
-
columnVisibility: {
|
1610
|
-
modifiedWhen: false,
|
1611
|
-
modifiedFullName: false
|
1612
|
-
}
|
1613
|
-
},
|
1614
|
-
mantineTableHeadCellProps: {
|
1615
|
-
style: {
|
1616
|
-
verticalAlign: "middle",
|
1617
|
-
paddingTop: "2px",
|
1618
|
-
paddingBottom: "2px"
|
1619
|
-
}
|
1620
|
-
},
|
1621
|
-
mantineTableBodyCellProps: {
|
1622
|
-
style: {
|
1623
|
-
paddingTop: "2px",
|
1624
|
-
paddingBottom: "2px"
|
1625
|
-
}
|
1626
|
-
},
|
1627
|
-
localization: MRT_Localization_VI,
|
1628
|
-
renderEmptyRowsFallback: () => isError ? /* @__PURE__ */ jsx25(Alert, { icon: /* @__PURE__ */ jsx25(IconBug, {}), color: "red", title: "C\xF3 l\u1ED7i x\u1EA3y ra!", m: "md" }) : /* @__PURE__ */ jsxs14(Center2, { p: "md", children: [
|
1629
|
-
" ",
|
1630
|
-
/* @__PURE__ */ jsx25(Text6, { c: "gray", fw: "600", size: "15px", fs: "italic", children: "Kh\xF4ng c\xF3 d\u1EEF li\u1EC7u!" })
|
1631
|
-
] }),
|
1632
|
-
state: __spreadValues({
|
1633
|
-
showSkeletons: isLoading
|
1634
|
-
}, pagination ? { pagination } : {}),
|
1635
|
-
mantineTableContainerProps: { style: { maxHeight: "65vh" } },
|
1636
|
-
enableStickyHeader: true
|
1637
|
-
}, rest));
|
1638
|
-
useEffect5(() => {
|
1639
|
-
setSelectedRow && setSelectedRow(table.getSelectedRowModel().rows.map((row) => row.original));
|
1640
|
-
}, [table.getState().rowSelection]);
|
1641
|
-
if (data == void 0) return;
|
1642
|
-
return /* @__PURE__ */ jsx25("main", { style: { position: "relative", zIndex: 1 }, children: table.getState().isFullScreen ? /* @__PURE__ */ jsx25(Portal, { children: /* @__PURE__ */ jsx25(MantineReactTable, { table }) }) : /* @__PURE__ */ jsx25(MantineReactTable, { table }) });
|
1643
|
-
}
|
1644
|
-
|
1645
1499
|
// src/components/Button/ButtonImport/SelectFileModal.tsx
|
1646
|
-
import { Button as
|
1500
|
+
import { Button as Button6, Fieldset as Fieldset2, FileInput as FileInput2, Modal as Modal7, NumberInput, Select as Select2, SimpleGrid as SimpleGrid2 } from "@mantine/core";
|
1647
1501
|
import { IconArrowBigRight as IconArrowBigRight2, IconSquareRoundedX as IconSquareRoundedX2 } from "@tabler/icons-react";
|
1648
|
-
import { jsx as
|
1502
|
+
import { jsx as jsx25, jsxs as jsxs14 } from "react/jsx-runtime";
|
1649
1503
|
function SelectFileModal({ onExportStructure, stack }) {
|
1650
1504
|
var _a;
|
1651
1505
|
const store = useS_ButtonImport();
|
1652
|
-
return /* @__PURE__ */
|
1506
|
+
return /* @__PURE__ */ jsxs14(
|
1653
1507
|
Modal7,
|
1654
1508
|
__spreadProps(__spreadValues({
|
1655
1509
|
title: "Import",
|
1656
1510
|
fullScreen: true
|
1657
1511
|
}, stack.register("select-file-page")), {
|
1658
1512
|
children: [
|
1659
|
-
/* @__PURE__ */
|
1513
|
+
/* @__PURE__ */ jsx25(
|
1660
1514
|
FileInput2,
|
1661
1515
|
{
|
1662
1516
|
value: store.state.file,
|
@@ -1666,8 +1520,8 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1666
1520
|
clearable: true
|
1667
1521
|
}
|
1668
1522
|
),
|
1669
|
-
/* @__PURE__ */
|
1670
|
-
/* @__PURE__ */
|
1523
|
+
/* @__PURE__ */ jsxs14(SimpleGrid2, { cols: { base: 1, md: 2, lg: 2, xl: 4 }, children: [
|
1524
|
+
/* @__PURE__ */ jsx25(
|
1671
1525
|
NumberInput,
|
1672
1526
|
{
|
1673
1527
|
label: "D\xF2ng ti\xEAu \u0111\u1EC1 b\u1EAFt \u0111\u1EA7u t\u1EEB",
|
@@ -1675,7 +1529,7 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1675
1529
|
onChange: (e4) => store.setProperty("startTitleIndex", e4)
|
1676
1530
|
}
|
1677
1531
|
),
|
1678
|
-
/* @__PURE__ */
|
1532
|
+
/* @__PURE__ */ jsx25(
|
1679
1533
|
NumberInput,
|
1680
1534
|
{
|
1681
1535
|
label: "D\xF2ng d\u1EEF li\u1EC7u b\u1EAFt \u0111\u1EA7u t\u1EEB",
|
@@ -1683,7 +1537,7 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1683
1537
|
onChange: (e4) => store.setProperty("startDataIndex", e4)
|
1684
1538
|
}
|
1685
1539
|
),
|
1686
|
-
/* @__PURE__ */
|
1540
|
+
/* @__PURE__ */ jsx25(
|
1687
1541
|
Select2,
|
1688
1542
|
{
|
1689
1543
|
readOnly: true,
|
@@ -1692,7 +1546,7 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1692
1546
|
defaultValue: "100.000"
|
1693
1547
|
}
|
1694
1548
|
),
|
1695
|
-
/* @__PURE__ */
|
1549
|
+
/* @__PURE__ */ jsx25(
|
1696
1550
|
Select2,
|
1697
1551
|
{
|
1698
1552
|
readOnly: true,
|
@@ -1702,37 +1556,37 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1702
1556
|
}
|
1703
1557
|
)
|
1704
1558
|
] }),
|
1705
|
-
/* @__PURE__ */
|
1559
|
+
/* @__PURE__ */ jsx25(Fieldset2, { legend: "Danh s\xE1ch tr\u01B0\u1EDDng th\xF4ng tin trong file d\u1EEF li\u1EC7u", children: store.state.data && /* @__PURE__ */ jsx25(
|
1706
1560
|
MyDataTable,
|
1707
1561
|
{
|
1708
1562
|
columns: store.columns,
|
1709
1563
|
data: store.state.data
|
1710
1564
|
}
|
1711
1565
|
) }),
|
1712
|
-
/* @__PURE__ */
|
1713
|
-
/* @__PURE__ */
|
1714
|
-
|
1566
|
+
/* @__PURE__ */ jsxs14(MyFlexEnd, { children: [
|
1567
|
+
/* @__PURE__ */ jsx25(
|
1568
|
+
Button6,
|
1715
1569
|
{
|
1716
1570
|
color: "teal.8",
|
1717
1571
|
onClick: onExportStructure,
|
1718
1572
|
children: "Xu\u1EA5t file c\u1EA5u tr\xFAc"
|
1719
1573
|
}
|
1720
1574
|
),
|
1721
|
-
/* @__PURE__ */
|
1722
|
-
|
1575
|
+
/* @__PURE__ */ jsx25(
|
1576
|
+
Button6,
|
1723
1577
|
{
|
1724
1578
|
disabled: ((_a = store.state.data) == null ? void 0 : _a.length) == 0,
|
1725
1579
|
color: "blue.8",
|
1726
|
-
leftSection: /* @__PURE__ */
|
1580
|
+
leftSection: /* @__PURE__ */ jsx25(IconArrowBigRight2, {}),
|
1727
1581
|
onClick: () => stack.open("select-field-page"),
|
1728
1582
|
children: "Ti\u1EBFp t\u1EE5c"
|
1729
1583
|
}
|
1730
1584
|
),
|
1731
|
-
/* @__PURE__ */
|
1732
|
-
|
1585
|
+
/* @__PURE__ */ jsx25(
|
1586
|
+
Button6,
|
1733
1587
|
{
|
1734
1588
|
color: "red.6",
|
1735
|
-
leftSection: /* @__PURE__ */
|
1589
|
+
leftSection: /* @__PURE__ */ jsx25(IconSquareRoundedX2, {}),
|
1736
1590
|
onClick: stack.closeAll,
|
1737
1591
|
children: "\u0110\xF3ng"
|
1738
1592
|
}
|
@@ -1744,26 +1598,26 @@ function SelectFileModal({ onExportStructure, stack }) {
|
|
1744
1598
|
}
|
1745
1599
|
|
1746
1600
|
// src/components/Button/ButtonImport/MyButtonImport.tsx
|
1747
|
-
import { Fragment as
|
1601
|
+
import { Fragment as Fragment7, jsx as jsx26, jsxs as jsxs15 } from "react/jsx-runtime";
|
1748
1602
|
function MyButtonImport({
|
1749
1603
|
onExportStructure,
|
1750
1604
|
onImport
|
1751
1605
|
}) {
|
1752
1606
|
const stack = useModalsStack3(["select-file-page", "select-field-page", "implement-page"]);
|
1753
1607
|
const store = useS_ButtonImport();
|
1754
|
-
return /* @__PURE__ */
|
1755
|
-
/* @__PURE__ */
|
1756
|
-
/* @__PURE__ */
|
1757
|
-
/* @__PURE__ */
|
1758
|
-
/* @__PURE__ */
|
1608
|
+
return /* @__PURE__ */ jsxs15(Fragment7, { children: [
|
1609
|
+
/* @__PURE__ */ jsx26(Button7, { color: "teal.8", onClick: () => stack.open("select-file-page"), leftSection: /* @__PURE__ */ jsx26(IconFileImport2, {}), title: "Import", children: "Import" }),
|
1610
|
+
/* @__PURE__ */ jsxs15(Modal8.Stack, { children: [
|
1611
|
+
/* @__PURE__ */ jsx26(SelectFileModal, { stack, onExportStructure }),
|
1612
|
+
/* @__PURE__ */ jsx26(SelectFieldModal, { stack, onImport: () => onImport(store.getDataFinal()) })
|
1759
1613
|
] })
|
1760
1614
|
] });
|
1761
1615
|
}
|
1762
1616
|
|
1763
1617
|
// src/components/Button/ButtonModal/AQSelectTableByOpenModal.tsx
|
1764
|
-
import { Button as
|
1618
|
+
import { Button as Button8, Fieldset as Fieldset3, Modal as Modal9 } from "@mantine/core";
|
1765
1619
|
import { useDisclosure as useDisclosure9 } from "@mantine/hooks";
|
1766
|
-
import { Fragment as
|
1620
|
+
import { Fragment as Fragment8, jsx as jsx27, jsxs as jsxs16 } from "react/jsx-runtime";
|
1767
1621
|
function AQSelectTableByOpenModal(_a) {
|
1768
1622
|
var _b = _a, {
|
1769
1623
|
setSelectedData,
|
@@ -1791,16 +1645,16 @@ function AQSelectTableByOpenModal(_a) {
|
|
1791
1645
|
"closeAfterSelect"
|
1792
1646
|
]);
|
1793
1647
|
const disclosure = useDisclosure9(false);
|
1794
|
-
return /* @__PURE__ */
|
1795
|
-
/* @__PURE__ */
|
1796
|
-
|
1648
|
+
return /* @__PURE__ */ jsxs16(Fragment8, { children: [
|
1649
|
+
/* @__PURE__ */ jsx27(
|
1650
|
+
Button8,
|
1797
1651
|
__spreadProps(__spreadValues({
|
1798
1652
|
onClick: disclosure[1].open
|
1799
1653
|
}, rest), {
|
1800
1654
|
children: label ? label : `Ch\u1ECDn t\u1EEB danh s\xE1ch`
|
1801
1655
|
})
|
1802
1656
|
),
|
1803
|
-
/* @__PURE__ */
|
1657
|
+
/* @__PURE__ */ jsx27(
|
1804
1658
|
Modal9,
|
1805
1659
|
{
|
1806
1660
|
fullScreen,
|
@@ -1808,11 +1662,11 @@ function AQSelectTableByOpenModal(_a) {
|
|
1808
1662
|
title,
|
1809
1663
|
opened: disclosure == null ? void 0 : disclosure[0],
|
1810
1664
|
onClose: disclosure[1].close,
|
1811
|
-
children: /* @__PURE__ */
|
1665
|
+
children: /* @__PURE__ */ jsx27(MyFlexColumn, { children: /* @__PURE__ */ jsx27(Fieldset3, { legend: listLabel ? listLabel : "Danh s\xE1ch", children: /* @__PURE__ */ jsx27(
|
1812
1666
|
MyDataTable,
|
1813
1667
|
__spreadValues({
|
1814
1668
|
renderTopToolbarCustomActions: ({ table }) => {
|
1815
|
-
return /* @__PURE__ */
|
1669
|
+
return /* @__PURE__ */ jsx27(Button8, { onClick: () => {
|
1816
1670
|
setSelectedData(table.getSelectedRowModel().rows.map((row) => row.original));
|
1817
1671
|
closeAfterSelect && disclosure[1].close();
|
1818
1672
|
}, children: "Ch\u1ECDn" });
|
@@ -1829,10 +1683,10 @@ function AQSelectTableByOpenModal(_a) {
|
|
1829
1683
|
|
1830
1684
|
// src/components/Button/ButtonPrintPDF/MyButtonPrintPDF.tsx
|
1831
1685
|
import { useRef as useRef2 } from "react";
|
1832
|
-
import { Button as
|
1686
|
+
import { Button as Button9 } from "@mantine/core";
|
1833
1687
|
import { IconPrinter as IconPrinter2 } from "@tabler/icons-react";
|
1834
1688
|
import { useReactToPrint } from "react-to-print";
|
1835
|
-
import { Fragment as
|
1689
|
+
import { Fragment as Fragment9, jsx as jsx28, jsxs as jsxs17 } from "react/jsx-runtime";
|
1836
1690
|
function MyButtonPrintPDF(_a) {
|
1837
1691
|
var _b = _a, { contentToPrint, children } = _b, rest = __objRest(_b, ["contentToPrint", "children"]);
|
1838
1692
|
const printRef = useRef2(null);
|
@@ -1846,16 +1700,16 @@ function MyButtonPrintPDF(_a) {
|
|
1846
1700
|
if (!contentToPrint) return;
|
1847
1701
|
handlePrint();
|
1848
1702
|
}
|
1849
|
-
return /* @__PURE__ */
|
1850
|
-
/* @__PURE__ */
|
1851
|
-
/* @__PURE__ */
|
1703
|
+
return /* @__PURE__ */ jsxs17(Fragment9, { children: [
|
1704
|
+
/* @__PURE__ */ jsx28("div", { style: { display: "none" }, children: /* @__PURE__ */ jsx28("div", { ref: printRef, children: contentToPrint }) }),
|
1705
|
+
/* @__PURE__ */ jsx28(Button9, __spreadProps(__spreadValues({ color: "orange", onClick: handleClick, leftSection: /* @__PURE__ */ jsx28(IconPrinter2, {}) }, rest), { children }))
|
1852
1706
|
] });
|
1853
1707
|
}
|
1854
1708
|
|
1855
1709
|
// src/components/Layouts/HtmlWrapper/MyHtmlWrapper.tsx
|
1856
1710
|
import { ScrollArea, TypographyStylesProvider } from "@mantine/core";
|
1857
1711
|
import pako from "pako";
|
1858
|
-
import { jsx as
|
1712
|
+
import { jsx as jsx29 } from "react/jsx-runtime";
|
1859
1713
|
function MyHtmlWrapper(_a) {
|
1860
1714
|
var _b = _a, { html, mah, zip = false } = _b, rest = __objRest(_b, ["html", "mah", "zip"]);
|
1861
1715
|
const extractHtmlFromZip = () => {
|
@@ -1864,7 +1718,7 @@ function MyHtmlWrapper(_a) {
|
|
1864
1718
|
const cleanedHtml = decompressedData == null ? void 0 : decompressedData.replaceAll(" font-family:'Times New Roman'; font-size:1em;", "");
|
1865
1719
|
return cleanedHtml.replaceAll(" font-family:'Times New Roman'; font-size:1em;", "");
|
1866
1720
|
};
|
1867
|
-
return /* @__PURE__ */
|
1721
|
+
return /* @__PURE__ */ jsx29(ScrollArea.Autosize, { mah, children: /* @__PURE__ */ jsx29(TypographyStylesProvider, __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ jsx29(
|
1868
1722
|
"div",
|
1869
1723
|
{
|
1870
1724
|
dangerouslySetInnerHTML: {
|
@@ -1876,7 +1730,7 @@ function MyHtmlWrapper(_a) {
|
|
1876
1730
|
|
1877
1731
|
// src/components/Button/ButtonPrintPDFTable/MyButtonPrintTablePDF.tsx
|
1878
1732
|
import { Box, Table as Table2 } from "@mantine/core";
|
1879
|
-
import { jsx as
|
1733
|
+
import { jsx as jsx30, jsxs as jsxs18 } from "react/jsx-runtime";
|
1880
1734
|
function MyButtonPrintTablePDF(_a) {
|
1881
1735
|
var _b = _a, {
|
1882
1736
|
printConfig,
|
@@ -1902,8 +1756,8 @@ function MyButtonPrintTablePDF(_a) {
|
|
1902
1756
|
};
|
1903
1757
|
const rows = data == null ? void 0 : data.map((item, index) => {
|
1904
1758
|
if (!(printConfig == null ? void 0 : printConfig.fields)) return null;
|
1905
|
-
return /* @__PURE__ */
|
1906
|
-
printConfig.showRowNumbers && /* @__PURE__ */
|
1759
|
+
return /* @__PURE__ */ jsxs18(Table2.Tr, { children: [
|
1760
|
+
printConfig.showRowNumbers && /* @__PURE__ */ jsx30(Table2.Td, { ta: "center", px: "xs", style: { border: "1px solid lightgray" }, children: index + 1 }),
|
1907
1761
|
printConfig.fields.map((field) => {
|
1908
1762
|
let value = item[field.fieldName];
|
1909
1763
|
if (field.formatFunction) {
|
@@ -1913,30 +1767,30 @@ function MyButtonPrintTablePDF(_a) {
|
|
1913
1767
|
}
|
1914
1768
|
const alignment = field.isCenter === false ? "left" : "center";
|
1915
1769
|
if (typeof value === "string" && (value.includes("<") || value.includes("<"))) {
|
1916
|
-
return /* @__PURE__ */
|
1770
|
+
return /* @__PURE__ */ jsx30(
|
1917
1771
|
Table2.Td,
|
1918
1772
|
{
|
1919
1773
|
px: "xs",
|
1920
1774
|
ta: alignment,
|
1921
1775
|
style: { border: "1px solid lightgray" },
|
1922
|
-
children: /* @__PURE__ */
|
1776
|
+
children: /* @__PURE__ */ jsx30(MyHtmlWrapper, { html: value })
|
1923
1777
|
},
|
1924
1778
|
field.fieldName
|
1925
1779
|
);
|
1926
1780
|
}
|
1927
1781
|
if (value === "true" || value === "false") {
|
1928
|
-
return /* @__PURE__ */
|
1782
|
+
return /* @__PURE__ */ jsx30(
|
1929
1783
|
Table2.Td,
|
1930
1784
|
{
|
1931
1785
|
ta: alignment,
|
1932
1786
|
px: "xs",
|
1933
1787
|
style: { border: "1px solid lightgray" },
|
1934
|
-
children: /* @__PURE__ */
|
1788
|
+
children: /* @__PURE__ */ jsx30("input", { type: "checkbox", checked: value === "true", readOnly: true })
|
1935
1789
|
},
|
1936
1790
|
field.fieldName
|
1937
1791
|
);
|
1938
1792
|
}
|
1939
|
-
return /* @__PURE__ */
|
1793
|
+
return /* @__PURE__ */ jsx30(
|
1940
1794
|
Table2.Td,
|
1941
1795
|
{
|
1942
1796
|
ta: alignment,
|
@@ -1960,18 +1814,18 @@ function MyButtonPrintTablePDF(_a) {
|
|
1960
1814
|
minute: "2-digit"
|
1961
1815
|
});
|
1962
1816
|
const tableTitle = (printConfig == null ? void 0 : printConfig.title) || "B\u1EA3ng d\u1EEF li\u1EC7u";
|
1963
|
-
return /* @__PURE__ */
|
1964
|
-
/* @__PURE__ */
|
1817
|
+
return /* @__PURE__ */ jsxs18(Box, { p: "lg", children: [
|
1818
|
+
/* @__PURE__ */ jsxs18("div", { style: { textAlign: "center", marginTop: "10px", fontStyle: "italic", color: "#666" }, children: [
|
1965
1819
|
"Ng\xE0y in: ",
|
1966
1820
|
formattedDate
|
1967
1821
|
] }),
|
1968
|
-
/* @__PURE__ */
|
1969
|
-
/* @__PURE__ */
|
1970
|
-
/* @__PURE__ */
|
1971
|
-
printConfig.showRowNumbers && /* @__PURE__ */
|
1822
|
+
/* @__PURE__ */ jsx30("h2", { style: { textAlign: "center", fontSize: "24px", fontWeight: "bold", marginBottom: "20px" }, children: tableTitle }),
|
1823
|
+
/* @__PURE__ */ jsxs18(Table2, { withColumnBorders: true, highlightOnHover: true, style: { border: "1px solid lightgray" }, children: [
|
1824
|
+
/* @__PURE__ */ jsx30(Table2.Thead, { children: /* @__PURE__ */ jsxs18(Table2.Tr, { children: [
|
1825
|
+
printConfig.showRowNumbers && /* @__PURE__ */ jsx30(Table2.Th, { style: { border: "1px solid lightgray" }, w: "10%", ta: "center", px: "xs", children: "STT" }),
|
1972
1826
|
printConfig.fields.map((field) => {
|
1973
1827
|
const alignment = field.isCenter === false ? "left" : "center";
|
1974
|
-
return /* @__PURE__ */
|
1828
|
+
return /* @__PURE__ */ jsx30(
|
1975
1829
|
Table2.Th,
|
1976
1830
|
{
|
1977
1831
|
style: { border: "1px solid lightgray" },
|
@@ -1983,11 +1837,11 @@ function MyButtonPrintTablePDF(_a) {
|
|
1983
1837
|
);
|
1984
1838
|
})
|
1985
1839
|
] }) }),
|
1986
|
-
/* @__PURE__ */
|
1840
|
+
/* @__PURE__ */ jsx30(Table2.Tbody, { children: rows })
|
1987
1841
|
] })
|
1988
1842
|
] });
|
1989
1843
|
};
|
1990
|
-
return /* @__PURE__ */
|
1844
|
+
return /* @__PURE__ */ jsx30(
|
1991
1845
|
MyButtonPrintPDF,
|
1992
1846
|
__spreadValues({
|
1993
1847
|
contentToPrint: renderContent()
|
@@ -1999,11 +1853,11 @@ function MyButtonPrintTablePDF(_a) {
|
|
1999
1853
|
import { ActionIcon as ActionIcon9 } from "@mantine/core";
|
2000
1854
|
import { IconArrowBack } from "@tabler/icons-react";
|
2001
1855
|
import { useRouter as useRouter2 } from "next/navigation";
|
2002
|
-
import { jsx as
|
1856
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
2003
1857
|
function MyButtonRouterBack(_a) {
|
2004
1858
|
var _b = _a, { url, label } = _b, rest = __objRest(_b, ["url", "label"]);
|
2005
1859
|
const router = useRouter2();
|
2006
|
-
return /* @__PURE__ */
|
1860
|
+
return /* @__PURE__ */ jsx31(
|
2007
1861
|
ActionIcon9,
|
2008
1862
|
__spreadProps(__spreadValues({
|
2009
1863
|
size: "xl",
|
@@ -2016,7 +1870,7 @@ function MyButtonRouterBack(_a) {
|
|
2016
1870
|
router.back();
|
2017
1871
|
}
|
2018
1872
|
}, rest), {
|
2019
|
-
children: /* @__PURE__ */
|
1873
|
+
children: /* @__PURE__ */ jsx31(IconArrowBack, { stroke: 2 })
|
2020
1874
|
})
|
2021
1875
|
);
|
2022
1876
|
}
|
@@ -2024,19 +1878,19 @@ function MyButtonRouterBack(_a) {
|
|
2024
1878
|
// src/components/Button/ButtonViewPDF/MyButtonViewPDF.tsx
|
2025
1879
|
import {
|
2026
1880
|
ActionIcon as ActionIcon10,
|
2027
|
-
Button as
|
2028
|
-
Group as
|
1881
|
+
Button as Button10,
|
1882
|
+
Group as Group8,
|
2029
1883
|
LoadingOverlay,
|
2030
1884
|
Modal as Modal10,
|
2031
1885
|
Paper as Paper3,
|
2032
|
-
Text as
|
1886
|
+
Text as Text6,
|
2033
1887
|
Tooltip as Tooltip4
|
2034
1888
|
} from "@mantine/core";
|
2035
1889
|
import { useDisclosure as useDisclosure10 } from "@mantine/hooks";
|
2036
1890
|
import { IconLivePhoto as IconLivePhoto2, IconMaximize as IconMaximize3, IconMinimize as IconMinimize3 } from "@tabler/icons-react";
|
2037
1891
|
import { useQuery } from "@tanstack/react-query";
|
2038
1892
|
import { useState as useState8 } from "react";
|
2039
|
-
import { Fragment as
|
1893
|
+
import { Fragment as Fragment10, jsx as jsx32, jsxs as jsxs19 } from "react/jsx-runtime";
|
2040
1894
|
function MyButtonViewPDF({
|
2041
1895
|
id,
|
2042
1896
|
modalSize = "80%",
|
@@ -2061,57 +1915,57 @@ function MyButtonViewPDF({
|
|
2061
1915
|
},
|
2062
1916
|
enabled: disc[0] == true
|
2063
1917
|
});
|
2064
|
-
return /* @__PURE__ */
|
2065
|
-
/* @__PURE__ */
|
1918
|
+
return /* @__PURE__ */ jsxs19(Fragment10, { children: [
|
1919
|
+
/* @__PURE__ */ jsx32(Tooltip4, { label: "Xem t\xE0i li\u1EC7u tr\u1EF1c ti\u1EBFp", children: isActionIcon ? /* @__PURE__ */ jsx32(
|
2066
1920
|
ActionIcon10,
|
2067
1921
|
{
|
2068
1922
|
onClick: () => {
|
2069
1923
|
disc[1].open();
|
2070
1924
|
},
|
2071
|
-
children: /* @__PURE__ */
|
1925
|
+
children: /* @__PURE__ */ jsx32(IconLivePhoto2, {})
|
2072
1926
|
}
|
2073
|
-
) : /* @__PURE__ */
|
2074
|
-
|
1927
|
+
) : /* @__PURE__ */ jsx32(
|
1928
|
+
Button10,
|
2075
1929
|
{
|
2076
1930
|
color: "cyan",
|
2077
1931
|
onClick: () => {
|
2078
1932
|
disc[1].open();
|
2079
1933
|
},
|
2080
|
-
leftSection: /* @__PURE__ */
|
1934
|
+
leftSection: /* @__PURE__ */ jsx32(IconLivePhoto2, {}),
|
2081
1935
|
children: label
|
2082
1936
|
}
|
2083
1937
|
) }),
|
2084
|
-
/* @__PURE__ */
|
1938
|
+
/* @__PURE__ */ jsx32(
|
2085
1939
|
Modal10,
|
2086
1940
|
{
|
2087
1941
|
fullScreen: fullScreen[0],
|
2088
1942
|
opened: disc[0],
|
2089
1943
|
onClose: disc[1].close,
|
2090
1944
|
size: modalSize,
|
2091
|
-
title: /* @__PURE__ */
|
2092
|
-
/* @__PURE__ */
|
2093
|
-
fullScreen[0] ? /* @__PURE__ */
|
1945
|
+
title: /* @__PURE__ */ jsxs19(Group8, { children: [
|
1946
|
+
/* @__PURE__ */ jsx32(Text6, { children: "Xem t\xE0i li\u1EC7u tr\u1EF1c ti\u1EBFp" }),
|
1947
|
+
fullScreen[0] ? /* @__PURE__ */ jsx32(
|
2094
1948
|
ActionIcon10,
|
2095
1949
|
{
|
2096
1950
|
onClick: () => {
|
2097
1951
|
fullScreen[1](false);
|
2098
1952
|
hSize[1]("80vh");
|
2099
1953
|
},
|
2100
|
-
children: /* @__PURE__ */
|
1954
|
+
children: /* @__PURE__ */ jsx32(IconMinimize3, {})
|
2101
1955
|
}
|
2102
|
-
) : /* @__PURE__ */
|
1956
|
+
) : /* @__PURE__ */ jsx32(
|
2103
1957
|
ActionIcon10,
|
2104
1958
|
{
|
2105
1959
|
onClick: () => {
|
2106
1960
|
fullScreen[1](true);
|
2107
1961
|
hSize[1]("90vh");
|
2108
1962
|
},
|
2109
|
-
children: /* @__PURE__ */
|
1963
|
+
children: /* @__PURE__ */ jsx32(IconMaximize3, {})
|
2110
1964
|
}
|
2111
1965
|
)
|
2112
1966
|
] }),
|
2113
|
-
children: /* @__PURE__ */
|
2114
|
-
/* @__PURE__ */
|
1967
|
+
children: /* @__PURE__ */ jsxs19(Paper3, { h: hSize[0], p: "lg", pos: "relative", children: [
|
1968
|
+
/* @__PURE__ */ jsx32(
|
2115
1969
|
LoadingOverlay,
|
2116
1970
|
{
|
2117
1971
|
visible: query.isLoading,
|
@@ -2119,14 +1973,14 @@ function MyButtonViewPDF({
|
|
2119
1973
|
overlayProps: { radius: "sm", blur: 2 }
|
2120
1974
|
}
|
2121
1975
|
),
|
2122
|
-
query.data ? /* @__PURE__ */
|
1976
|
+
query.data ? /* @__PURE__ */ jsx32(
|
2123
1977
|
"iframe",
|
2124
1978
|
{
|
2125
1979
|
src: `data:application/pdf;base64, ${filePath ? (_a = query.data) == null ? void 0 : _a.fileBase64String : (_c = (_b = query.data) == null ? void 0 : _b.fileDetail) == null ? void 0 : _c.fileBase64String}`,
|
2126
1980
|
width: "100%",
|
2127
1981
|
height: "100%"
|
2128
1982
|
}
|
2129
|
-
) : /* @__PURE__ */
|
1983
|
+
) : /* @__PURE__ */ jsx32("iframe", { src, width: "100%", height: "100%" })
|
2130
1984
|
] })
|
2131
1985
|
}
|
2132
1986
|
)
|
@@ -6478,10 +6332,10 @@ var createViewMonthAgenda = () => createPreactView(config);
|
|
6478
6332
|
import { createEventModalPlugin } from "@schedule-x/event-modal";
|
6479
6333
|
import { createEventsServicePlugin } from "@schedule-x/events-service";
|
6480
6334
|
import { ScheduleXCalendar, useNextCalendarApp } from "@schedule-x/react";
|
6481
|
-
import { Paper as Paper4, Text as
|
6335
|
+
import { Paper as Paper4, Text as Text7 } from "@mantine/core";
|
6482
6336
|
import "@schedule-x/theme-default/dist/index.css";
|
6483
|
-
import { useEffect as
|
6484
|
-
import { jsx as
|
6337
|
+
import { useEffect as useEffect5 } from "react";
|
6338
|
+
import { jsx as jsx33, jsxs as jsxs20 } from "react/jsx-runtime";
|
6485
6339
|
function MyCalendar() {
|
6486
6340
|
const plugins = [createEventsServicePlugin(), createEventModalPlugin()];
|
6487
6341
|
const calendar = useNextCalendarApp({
|
@@ -6552,19 +6406,19 @@ function MyCalendar() {
|
|
6552
6406
|
}
|
6553
6407
|
]
|
6554
6408
|
}, plugins);
|
6555
|
-
|
6409
|
+
useEffect5(() => {
|
6556
6410
|
calendar == null ? void 0 : calendar.events.getAll();
|
6557
6411
|
}, []);
|
6558
|
-
return /* @__PURE__ */
|
6412
|
+
return /* @__PURE__ */ jsx33("div", { children: /* @__PURE__ */ jsx33(ScheduleXCalendar, { calendarApp: calendar, customComponents: {
|
6559
6413
|
timeGridEvent: ({ calendarEvent }) => {
|
6560
6414
|
console.log(calendarEvent);
|
6561
|
-
return /* @__PURE__ */
|
6562
|
-
/* @__PURE__ */
|
6415
|
+
return /* @__PURE__ */ jsx33(Paper4, { h: "100%", bg: calendarEvent.laLichThi ? "violet.2" : "blue.2", p: 4, children: /* @__PURE__ */ jsxs20(MyFlexColumn, { gap: 1, children: [
|
6416
|
+
/* @__PURE__ */ jsxs20(Text7, { size: "sm", fw: "bold", children: [
|
6563
6417
|
calendarEvent.laLichThi ? "(Thi) " : "(H\u1ECDc) ",
|
6564
6418
|
calendarEvent.title
|
6565
6419
|
] }),
|
6566
|
-
calendarEvent.laLichThi == false && /* @__PURE__ */
|
6567
|
-
/* @__PURE__ */
|
6420
|
+
calendarEvent.laLichThi == false && /* @__PURE__ */ jsx33(Text7, { size: "sm", children: calendarEvent.giangvien }),
|
6421
|
+
/* @__PURE__ */ jsx33(Text7, { size: "sm", children: calendarEvent.location })
|
6568
6422
|
] }) });
|
6569
6423
|
}
|
6570
6424
|
// eventModal: ({ calendarEvent }) => {
|
@@ -6578,24 +6432,24 @@ function MyCalendar() {
|
|
6578
6432
|
}
|
6579
6433
|
|
6580
6434
|
// src/components/CenterFull/MyCenterFull.tsx
|
6581
|
-
import { Center as
|
6582
|
-
import { jsx as
|
6435
|
+
import { Center as Center2, Group as Group9 } from "@mantine/core";
|
6436
|
+
import { jsx as jsx34 } from "react/jsx-runtime";
|
6583
6437
|
function MyCenterFull({ children }) {
|
6584
|
-
return /* @__PURE__ */
|
6438
|
+
return /* @__PURE__ */ jsx34(Center2, { w: "100%", children: /* @__PURE__ */ jsx34(Group9, { children }) });
|
6585
6439
|
}
|
6586
6440
|
|
6587
6441
|
// src/components/Checkbox/MyCheckbox.tsx
|
6588
6442
|
import { Checkbox as Checkbox2 } from "@mantine/core";
|
6589
|
-
import { jsx as
|
6443
|
+
import { jsx as jsx35 } from "react/jsx-runtime";
|
6590
6444
|
function MyCheckbox(_a) {
|
6591
6445
|
var rest = __objRest(_a, []);
|
6592
|
-
return /* @__PURE__ */
|
6446
|
+
return /* @__PURE__ */ jsx35(Checkbox2, __spreadValues({}, rest));
|
6593
6447
|
}
|
6594
6448
|
|
6595
6449
|
// src/components/DataDisplay/Card/AQCard.tsx
|
6596
|
-
import { Badge as Badge2, Card, Center as
|
6450
|
+
import { Badge as Badge2, Card, Center as Center3, Image, Text as Text8 } from "@mantine/core";
|
6597
6451
|
import Link from "next/link";
|
6598
|
-
import { jsx as
|
6452
|
+
import { jsx as jsx36, jsxs as jsxs21 } from "react/jsx-runtime";
|
6599
6453
|
function AQCard({
|
6600
6454
|
imgSrc = "https://raw.githubusercontent.com/mantinedev/mantine/master/.demo/images/bg-8.png",
|
6601
6455
|
title,
|
@@ -6605,8 +6459,8 @@ function AQCard({
|
|
6605
6459
|
status,
|
6606
6460
|
href = ""
|
6607
6461
|
}) {
|
6608
|
-
return /* @__PURE__ */
|
6609
|
-
/* @__PURE__ */
|
6462
|
+
return /* @__PURE__ */ jsxs21(Card, { shadow: "sm", padding: "lg", radius: "md", withBorder: true, component: Link, href, children: [
|
6463
|
+
/* @__PURE__ */ jsx36(Card.Section, { children: /* @__PURE__ */ jsx36(Center3, { children: /* @__PURE__ */ jsx36(
|
6610
6464
|
Image,
|
6611
6465
|
{
|
6612
6466
|
src: imgSrc,
|
@@ -6616,19 +6470,19 @@ function AQCard({
|
|
6616
6470
|
alt: "Norway"
|
6617
6471
|
}
|
6618
6472
|
) }) }),
|
6619
|
-
/* @__PURE__ */
|
6620
|
-
/* @__PURE__ */
|
6621
|
-
status && /* @__PURE__ */
|
6473
|
+
/* @__PURE__ */ jsxs21(MyFlexRow, { justify: "space-between", mt: "md", mb: "xs", children: [
|
6474
|
+
/* @__PURE__ */ jsx36(Text8, { fw: 500, children: title }),
|
6475
|
+
status && /* @__PURE__ */ jsx36(Badge2, { color: "violet.5", w: "150px", children: status })
|
6622
6476
|
] }),
|
6623
|
-
/* @__PURE__ */
|
6477
|
+
/* @__PURE__ */ jsx36(Text8, { size: "sm", c: "dimmed", lineClamp: 2, children: description }),
|
6624
6478
|
children
|
6625
6479
|
] });
|
6626
6480
|
}
|
6627
6481
|
|
6628
6482
|
// src/components/DataDisplay/CardInformation/MyCardInformation.tsx
|
6629
|
-
import { Box as Box2, Flex, Group as
|
6483
|
+
import { Box as Box2, Flex, Group as Group10, Paper as Paper5, Text as Text9 } from "@mantine/core";
|
6630
6484
|
import { IconArrowDownRight, IconArrowUpRight } from "@tabler/icons-react";
|
6631
|
-
import { jsx as
|
6485
|
+
import { jsx as jsx37, jsxs as jsxs22 } from "react/jsx-runtime";
|
6632
6486
|
function MyCardInformation({
|
6633
6487
|
title,
|
6634
6488
|
value,
|
@@ -6638,17 +6492,17 @@ function MyCardInformation({
|
|
6638
6492
|
diff = 0,
|
6639
6493
|
extraControl
|
6640
6494
|
}) {
|
6641
|
-
return /* @__PURE__ */
|
6495
|
+
return /* @__PURE__ */ jsxs22(
|
6642
6496
|
Paper5,
|
6643
6497
|
{
|
6644
6498
|
withBorder: true,
|
6645
6499
|
p: "md",
|
6646
6500
|
radius: "md",
|
6647
6501
|
children: [
|
6648
|
-
/* @__PURE__ */
|
6649
|
-
/* @__PURE__ */
|
6650
|
-
/* @__PURE__ */
|
6651
|
-
|
6502
|
+
/* @__PURE__ */ jsxs22(Group10, { justify: "space-between", children: [
|
6503
|
+
/* @__PURE__ */ jsxs22(Flex, { direction: "column", children: [
|
6504
|
+
/* @__PURE__ */ jsx37(
|
6505
|
+
Text9,
|
6652
6506
|
{
|
6653
6507
|
tt: "uppercase",
|
6654
6508
|
size: "lg",
|
@@ -6656,52 +6510,52 @@ function MyCardInformation({
|
|
6656
6510
|
children: title
|
6657
6511
|
}
|
6658
6512
|
),
|
6659
|
-
unit == "" ? /* @__PURE__ */
|
6513
|
+
unit == "" ? /* @__PURE__ */ jsxs22(Text9, { size: "xs", style: { visibility: "hidden" }, children: [
|
6660
6514
|
"\u0110\u01A1n v\u1ECB: ",
|
6661
|
-
/* @__PURE__ */
|
6662
|
-
] }) : /* @__PURE__ */
|
6515
|
+
/* @__PURE__ */ jsx37("strong", { children: unit })
|
6516
|
+
] }) : /* @__PURE__ */ jsxs22(Text9, { size: "xs", children: [
|
6663
6517
|
"\u0110\u01A1n v\u1ECB: ",
|
6664
|
-
/* @__PURE__ */
|
6518
|
+
/* @__PURE__ */ jsx37("strong", { children: unit })
|
6665
6519
|
] })
|
6666
6520
|
] }),
|
6667
|
-
/* @__PURE__ */
|
6521
|
+
/* @__PURE__ */ jsx37(Box2, { children: icon })
|
6668
6522
|
] }),
|
6669
|
-
/* @__PURE__ */
|
6670
|
-
|
6523
|
+
/* @__PURE__ */ jsxs22(
|
6524
|
+
Group10,
|
6671
6525
|
{
|
6672
6526
|
mt: "5",
|
6673
6527
|
align: "flex-end",
|
6674
6528
|
gap: "xs",
|
6675
6529
|
children: [
|
6676
|
-
/* @__PURE__ */
|
6677
|
-
|
6530
|
+
/* @__PURE__ */ jsx37(
|
6531
|
+
Text9,
|
6678
6532
|
{
|
6679
6533
|
fw: 700,
|
6680
6534
|
fz: "h1",
|
6681
6535
|
children: value
|
6682
6536
|
}
|
6683
6537
|
),
|
6684
|
-
/* @__PURE__ */
|
6685
|
-
|
6538
|
+
/* @__PURE__ */ jsxs22(
|
6539
|
+
Text9,
|
6686
6540
|
{
|
6687
6541
|
mb: "2",
|
6688
6542
|
c: diff > 0 ? "teal" : "red",
|
6689
6543
|
fz: "h2",
|
6690
6544
|
fw: 500,
|
6691
6545
|
children: [
|
6692
|
-
/* @__PURE__ */
|
6546
|
+
/* @__PURE__ */ jsxs22("span", { children: [
|
6693
6547
|
diff,
|
6694
6548
|
"%"
|
6695
6549
|
] }),
|
6696
|
-
diff > 0 ? /* @__PURE__ */
|
6550
|
+
diff > 0 ? /* @__PURE__ */ jsx37(IconArrowUpRight, {}) : /* @__PURE__ */ jsx37(IconArrowDownRight, {})
|
6697
6551
|
]
|
6698
6552
|
}
|
6699
6553
|
)
|
6700
6554
|
]
|
6701
6555
|
}
|
6702
6556
|
),
|
6703
|
-
/* @__PURE__ */
|
6704
|
-
/* @__PURE__ */
|
6557
|
+
/* @__PURE__ */ jsxs22(Group10, { justify: "space-between", children: [
|
6558
|
+
/* @__PURE__ */ jsx37(Text9, { tt: "uppercase", fz: "xs", c: "dimmed", children: description }),
|
6705
6559
|
extraControl
|
6706
6560
|
] })
|
6707
6561
|
]
|
@@ -6711,52 +6565,52 @@ function MyCardInformation({
|
|
6711
6565
|
}
|
6712
6566
|
|
6713
6567
|
// src/components/DataDisplay/IconText/MyIconText.tsx
|
6714
|
-
import { Group as
|
6715
|
-
import { jsx as
|
6568
|
+
import { Group as Group11, Text as Text10 } from "@mantine/core";
|
6569
|
+
import { jsx as jsx38, jsxs as jsxs23 } from "react/jsx-runtime";
|
6716
6570
|
function MyIconText({ icon: Icon, text }) {
|
6717
|
-
return /* @__PURE__ */
|
6718
|
-
Icon && /* @__PURE__ */
|
6719
|
-
/* @__PURE__ */
|
6571
|
+
return /* @__PURE__ */ jsxs23(Group11, { wrap: "nowrap", gap: 10, mt: 3, children: [
|
6572
|
+
Icon && /* @__PURE__ */ jsx38(Icon, { stroke: 1.5, size: 16 }),
|
6573
|
+
/* @__PURE__ */ jsx38(Text10, { fz: "lg", c: "dimmed", children: text })
|
6720
6574
|
] });
|
6721
6575
|
}
|
6722
6576
|
|
6723
6577
|
// src/components/DataDisplay/KeyLabel/MyKeyLabel.tsx
|
6724
|
-
import { Group as
|
6725
|
-
import { jsx as
|
6578
|
+
import { Group as Group12, Text as Text11 } from "@mantine/core";
|
6579
|
+
import { jsx as jsx39, jsxs as jsxs24 } from "react/jsx-runtime";
|
6726
6580
|
function MyKeyLabel({ keyLabel, label }) {
|
6727
|
-
return /* @__PURE__ */
|
6728
|
-
/* @__PURE__ */
|
6581
|
+
return /* @__PURE__ */ jsxs24(Group12, { gap: 5, children: [
|
6582
|
+
/* @__PURE__ */ jsxs24(Text11, { fw: "bold", children: [
|
6729
6583
|
keyLabel,
|
6730
6584
|
":"
|
6731
6585
|
] }),
|
6732
|
-
/* @__PURE__ */
|
6586
|
+
/* @__PURE__ */ jsx39(Text11, { children: label })
|
6733
6587
|
] });
|
6734
6588
|
}
|
6735
6589
|
|
6736
6590
|
// src/components/DataDisplay/NumberFormatter/MyNumberFormatter.tsx
|
6737
6591
|
import { NumberFormatter } from "@mantine/core";
|
6738
|
-
import { jsx as
|
6592
|
+
import { jsx as jsx40 } from "react/jsx-runtime";
|
6739
6593
|
function MyNumberFormatter(_a) {
|
6740
6594
|
var rest = __objRest(_a, []);
|
6741
|
-
return /* @__PURE__ */
|
6595
|
+
return /* @__PURE__ */ jsx40(NumberFormatter, __spreadValues({ thousandSeparator: true, suffix: " VN\u0110" }, rest));
|
6742
6596
|
}
|
6743
6597
|
|
6744
6598
|
// src/components/DataDisplay/StatCard/AQStatCard1.tsx
|
6745
|
-
import { Box as Box3, Button as
|
6599
|
+
import { Box as Box3, Button as Button12, Flex as Flex2, Group as Group13, Paper as Paper6, Text as Text12 } from "@mantine/core";
|
6746
6600
|
import { IconArrowDownRight as IconArrowDownRight2, IconArrowUpRight as IconArrowUpRight2 } from "@tabler/icons-react";
|
6747
|
-
import { Fragment as
|
6601
|
+
import { Fragment as Fragment11, jsx as jsx41, jsxs as jsxs25 } from "react/jsx-runtime";
|
6748
6602
|
function AQStatCard1({ title, value, unit = "", description, icons, diff }) {
|
6749
|
-
return /* @__PURE__ */
|
6603
|
+
return /* @__PURE__ */ jsx41(Fragment11, { children: /* @__PURE__ */ jsxs25(
|
6750
6604
|
Paper6,
|
6751
6605
|
{
|
6752
6606
|
withBorder: true,
|
6753
6607
|
p: "md",
|
6754
6608
|
radius: "md",
|
6755
6609
|
children: [
|
6756
|
-
/* @__PURE__ */
|
6757
|
-
/* @__PURE__ */
|
6758
|
-
/* @__PURE__ */
|
6759
|
-
|
6610
|
+
/* @__PURE__ */ jsxs25(Group13, { justify: "space-between", children: [
|
6611
|
+
/* @__PURE__ */ jsxs25(Flex2, { direction: "column", children: [
|
6612
|
+
/* @__PURE__ */ jsx41(
|
6613
|
+
Text12,
|
6760
6614
|
{
|
6761
6615
|
tt: "uppercase",
|
6762
6616
|
size: "lg",
|
@@ -6764,54 +6618,54 @@ function AQStatCard1({ title, value, unit = "", description, icons, diff }) {
|
|
6764
6618
|
children: title
|
6765
6619
|
}
|
6766
6620
|
),
|
6767
|
-
unit == "" ? /* @__PURE__ */
|
6621
|
+
unit == "" ? /* @__PURE__ */ jsxs25(Text12, { size: "xs", style: { visibility: "hidden" }, children: [
|
6768
6622
|
"\u0110\u01A1n v\u1ECB: ",
|
6769
|
-
/* @__PURE__ */
|
6770
|
-
] }) : /* @__PURE__ */
|
6623
|
+
/* @__PURE__ */ jsx41("strong", { children: unit })
|
6624
|
+
] }) : /* @__PURE__ */ jsxs25(Text12, { size: "xs", children: [
|
6771
6625
|
"\u0110\u01A1n v\u1ECB: ",
|
6772
|
-
/* @__PURE__ */
|
6626
|
+
/* @__PURE__ */ jsx41("strong", { children: unit })
|
6773
6627
|
] })
|
6774
6628
|
] }),
|
6775
|
-
/* @__PURE__ */
|
6629
|
+
/* @__PURE__ */ jsx41(Box3, { children: icons })
|
6776
6630
|
] }),
|
6777
|
-
/* @__PURE__ */
|
6778
|
-
|
6631
|
+
/* @__PURE__ */ jsxs25(
|
6632
|
+
Group13,
|
6779
6633
|
{
|
6780
6634
|
mt: "5",
|
6781
6635
|
align: "flex-end",
|
6782
6636
|
gap: "xs",
|
6783
6637
|
children: [
|
6784
|
-
/* @__PURE__ */
|
6785
|
-
|
6638
|
+
/* @__PURE__ */ jsx41(
|
6639
|
+
Text12,
|
6786
6640
|
{
|
6787
6641
|
fw: 700,
|
6788
6642
|
fz: "h1",
|
6789
6643
|
children: value
|
6790
6644
|
}
|
6791
6645
|
),
|
6792
|
-
/* @__PURE__ */
|
6793
|
-
|
6646
|
+
/* @__PURE__ */ jsxs25(
|
6647
|
+
Text12,
|
6794
6648
|
{
|
6795
6649
|
mb: "2",
|
6796
6650
|
c: diff > 0 ? "teal" : "red",
|
6797
6651
|
fz: "h2",
|
6798
6652
|
fw: 500,
|
6799
6653
|
children: [
|
6800
|
-
/* @__PURE__ */
|
6654
|
+
/* @__PURE__ */ jsxs25("span", { children: [
|
6801
6655
|
diff,
|
6802
6656
|
"%"
|
6803
6657
|
] }),
|
6804
|
-
diff > 0 ? /* @__PURE__ */
|
6658
|
+
diff > 0 ? /* @__PURE__ */ jsx41(IconArrowUpRight2, {}) : /* @__PURE__ */ jsx41(IconArrowDownRight2, {})
|
6805
6659
|
]
|
6806
6660
|
}
|
6807
6661
|
)
|
6808
6662
|
]
|
6809
6663
|
}
|
6810
6664
|
),
|
6811
|
-
/* @__PURE__ */
|
6812
|
-
/* @__PURE__ */
|
6813
|
-
/* @__PURE__ */
|
6814
|
-
|
6665
|
+
/* @__PURE__ */ jsxs25(Group13, { justify: "space-between", children: [
|
6666
|
+
/* @__PURE__ */ jsx41(Text12, { tt: "uppercase", fz: "xs", c: "dimmed", children: description }),
|
6667
|
+
/* @__PURE__ */ jsx41(
|
6668
|
+
Button12,
|
6815
6669
|
{
|
6816
6670
|
variant: "light",
|
6817
6671
|
size: "xs",
|
@@ -6826,7 +6680,7 @@ function AQStatCard1({ title, value, unit = "", description, icons, diff }) {
|
|
6826
6680
|
}
|
6827
6681
|
|
6828
6682
|
// src/components/FaviconSetter/FaviconSetter.tsx
|
6829
|
-
import { useEffect as
|
6683
|
+
import { useEffect as useEffect6 } from "react";
|
6830
6684
|
|
6831
6685
|
// src/components/Layouts/BasicAppShell/useS_BasicAppShell.ts
|
6832
6686
|
var useStore2 = createGenericStore({
|
@@ -6878,7 +6732,7 @@ function useS_BasicAppShell() {
|
|
6878
6732
|
function FaviconSetter() {
|
6879
6733
|
var _a;
|
6880
6734
|
const store = useS_BasicAppShell();
|
6881
|
-
|
6735
|
+
useEffect6(() => {
|
6882
6736
|
var _a2, _b, _c;
|
6883
6737
|
if (!((_a2 = store.state.faviconFileDetail) == null ? void 0 : _a2.fileBase64String)) return;
|
6884
6738
|
try {
|
@@ -6901,20 +6755,20 @@ function FaviconSetter() {
|
|
6901
6755
|
|
6902
6756
|
// src/components/Inputs/DateInput/MyDateInput.tsx
|
6903
6757
|
import { DateInput } from "@mantine/dates";
|
6904
|
-
import { jsx as
|
6758
|
+
import { jsx as jsx42 } from "react/jsx-runtime";
|
6905
6759
|
function MyDateInput(_a) {
|
6906
6760
|
var _b = _a, { label } = _b, rest = __objRest(_b, ["label"]);
|
6907
|
-
return /* @__PURE__ */
|
6761
|
+
return /* @__PURE__ */ jsx42(DateInput, __spreadValues({ label, placeholder: label ? `Ch\u1ECDn ${label == null ? void 0 : label.toLowerCase()}` : "" }, rest));
|
6908
6762
|
}
|
6909
6763
|
|
6910
6764
|
// src/components/Inputs/Fieldset/MyFieldset.tsx
|
6911
6765
|
import {
|
6912
6766
|
Fieldset as Fieldset4,
|
6913
|
-
Group as
|
6914
|
-
Text as
|
6767
|
+
Group as Group14,
|
6768
|
+
Text as Text13,
|
6915
6769
|
useMantineColorScheme as useMantineColorScheme2
|
6916
6770
|
} from "@mantine/core";
|
6917
|
-
import { jsx as
|
6771
|
+
import { jsx as jsx43, jsxs as jsxs26 } from "react/jsx-runtime";
|
6918
6772
|
function MyFieldset(_a) {
|
6919
6773
|
var _b = _a, {
|
6920
6774
|
children,
|
@@ -6943,10 +6797,10 @@ function MyFieldset(_a) {
|
|
6943
6797
|
const mergedStyles = typeof styles === "function" ? styles : __spreadProps(__spreadValues({}, styles), {
|
6944
6798
|
legend: __spreadValues(__spreadValues({}, defaultLegendStyles), styles == null ? void 0 : styles.legend)
|
6945
6799
|
});
|
6946
|
-
return /* @__PURE__ */
|
6800
|
+
return /* @__PURE__ */ jsx43(
|
6947
6801
|
Fieldset4,
|
6948
6802
|
__spreadProps(__spreadValues({
|
6949
|
-
legend: customLegend != null ? customLegend : /* @__PURE__ */
|
6803
|
+
legend: customLegend != null ? customLegend : /* @__PURE__ */ jsx43(Group14, { gap: "xs", children: /* @__PURE__ */ jsxs26(Text13, { fw: 600, children: [
|
6950
6804
|
" ",
|
6951
6805
|
title,
|
6952
6806
|
" "
|
@@ -6961,13 +6815,13 @@ function MyFieldset(_a) {
|
|
6961
6815
|
// src/components/Inputs/FileInput/MyFileInput.tsx
|
6962
6816
|
import { FileInput as FileInput3 } from "@mantine/core";
|
6963
6817
|
import { IconFile } from "@tabler/icons-react";
|
6964
|
-
import { jsx as
|
6818
|
+
import { jsx as jsx44 } from "react/jsx-runtime";
|
6965
6819
|
function MyFileInput(_a) {
|
6966
6820
|
var _b = _a, { label } = _b, rest = __objRest(_b, ["label"]);
|
6967
|
-
return /* @__PURE__ */
|
6821
|
+
return /* @__PURE__ */ jsx44(
|
6968
6822
|
FileInput3,
|
6969
6823
|
__spreadValues({
|
6970
|
-
rightSection: /* @__PURE__ */
|
6824
|
+
rightSection: /* @__PURE__ */ jsx44(IconFile, {}),
|
6971
6825
|
label,
|
6972
6826
|
placeholder: label ? `Ch\u1ECDn ${label == null ? void 0 : label.toLowerCase()}` : ""
|
6973
6827
|
}, rest)
|
@@ -6977,26 +6831,26 @@ function MyFileInput(_a) {
|
|
6977
6831
|
// src/components/Inputs/NumberInput/MyNumberInput.tsx
|
6978
6832
|
import { NumberInput as NumberInput2 } from "@mantine/core";
|
6979
6833
|
import { IconNumbers } from "@tabler/icons-react";
|
6980
|
-
import { jsx as
|
6834
|
+
import { jsx as jsx45 } from "react/jsx-runtime";
|
6981
6835
|
function MyNumberInput(_a) {
|
6982
6836
|
var _b = _a, { minValue, label } = _b, rest = __objRest(_b, ["minValue", "label"]);
|
6983
|
-
return /* @__PURE__ */
|
6837
|
+
return /* @__PURE__ */ jsx45(
|
6984
6838
|
NumberInput2,
|
6985
6839
|
__spreadValues({
|
6986
6840
|
label,
|
6987
6841
|
min: minValue ? minValue : 0,
|
6988
6842
|
placeholder: label ? `Nh\u1EADp ${label == null ? void 0 : label.toLowerCase()}` : "",
|
6989
|
-
rightSection: /* @__PURE__ */
|
6843
|
+
rightSection: /* @__PURE__ */ jsx45(IconNumbers, {})
|
6990
6844
|
}, rest)
|
6991
6845
|
);
|
6992
6846
|
}
|
6993
6847
|
|
6994
6848
|
// src/components/Inputs/TextArea/MyTextArea.tsx
|
6995
6849
|
import { Textarea } from "@mantine/core";
|
6996
|
-
import { jsx as
|
6850
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
6997
6851
|
function MyTextArea(_a) {
|
6998
6852
|
var _b = _a, { label } = _b, rest = __objRest(_b, ["label"]);
|
6999
|
-
return /* @__PURE__ */
|
6853
|
+
return /* @__PURE__ */ jsx46(Textarea, __spreadValues({ label, placeholder: label ? `Nh\u1EADp ${label == null ? void 0 : label.toLowerCase()}` : "" }, rest));
|
7000
6854
|
}
|
7001
6855
|
|
7002
6856
|
// src/components/Inputs/TextEditor/MyTextEditor.tsx
|
@@ -7011,8 +6865,8 @@ import TextAlign from "@tiptap/extension-text-align";
|
|
7011
6865
|
import Underline from "@tiptap/extension-underline";
|
7012
6866
|
import { useEditor } from "@tiptap/react";
|
7013
6867
|
import StarterKit from "@tiptap/starter-kit";
|
7014
|
-
import { useEffect as
|
7015
|
-
import { jsx as
|
6868
|
+
import { useEffect as useEffect7, useState as useState9 } from "react";
|
6869
|
+
import { jsx as jsx47, jsxs as jsxs27 } from "react/jsx-runtime";
|
7016
6870
|
function MyTextEditor(_a) {
|
7017
6871
|
var _b = _a, {
|
7018
6872
|
autoHiddenToolBar = false,
|
@@ -7113,48 +6967,48 @@ function MyTextEditor(_a) {
|
|
7113
6967
|
}
|
7114
6968
|
}
|
7115
6969
|
}, rest));
|
7116
|
-
|
6970
|
+
useEffect7(() => {
|
7117
6971
|
if (editor && value !== editor.getHTML()) {
|
7118
6972
|
editor.commands.setContent(value);
|
7119
6973
|
}
|
7120
6974
|
}, [value, editor]);
|
7121
|
-
return /* @__PURE__ */
|
7122
|
-
/* @__PURE__ */
|
7123
|
-
/* @__PURE__ */
|
7124
|
-
/* @__PURE__ */
|
7125
|
-
/* @__PURE__ */
|
7126
|
-
/* @__PURE__ */
|
7127
|
-
/* @__PURE__ */
|
7128
|
-
/* @__PURE__ */
|
7129
|
-
/* @__PURE__ */
|
7130
|
-
/* @__PURE__ */
|
6975
|
+
return /* @__PURE__ */ jsx47(Input.Wrapper, __spreadProps(__spreadValues({ label, flex: 1, error, withAsterisk }, inputWrapperProps), { children: /* @__PURE__ */ jsxs27(RichTextEditor, __spreadProps(__spreadValues({ editor, style: { border: error && "1px solid #e03131" } }, richTextEditorProps), { children: [
|
6976
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.Toolbar, { hidden: hiddenToolBar, sticky: true, stickyOffset: 60, children: [
|
6977
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.ControlsGroup, { children: [
|
6978
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Bold, {}),
|
6979
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Italic, {}),
|
6980
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Underline, {}),
|
6981
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Strikethrough, {}),
|
6982
|
+
/* @__PURE__ */ jsx47(RichTextEditor.ClearFormatting, {}),
|
6983
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Highlight, {}),
|
6984
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Code, {})
|
7131
6985
|
] }),
|
7132
|
-
/* @__PURE__ */
|
7133
|
-
/* @__PURE__ */
|
7134
|
-
/* @__PURE__ */
|
7135
|
-
/* @__PURE__ */
|
7136
|
-
/* @__PURE__ */
|
6986
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.ControlsGroup, { children: [
|
6987
|
+
/* @__PURE__ */ jsx47(RichTextEditor.H1, {}),
|
6988
|
+
/* @__PURE__ */ jsx47(RichTextEditor.H2, {}),
|
6989
|
+
/* @__PURE__ */ jsx47(RichTextEditor.H3, {}),
|
6990
|
+
/* @__PURE__ */ jsx47(RichTextEditor.H4, {})
|
7137
6991
|
] }),
|
7138
|
-
/* @__PURE__ */
|
7139
|
-
/* @__PURE__ */
|
7140
|
-
/* @__PURE__ */
|
7141
|
-
/* @__PURE__ */
|
7142
|
-
/* @__PURE__ */
|
7143
|
-
/* @__PURE__ */
|
7144
|
-
/* @__PURE__ */
|
6992
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.ControlsGroup, { children: [
|
6993
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Blockquote, {}),
|
6994
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Hr, {}),
|
6995
|
+
/* @__PURE__ */ jsx47(RichTextEditor.BulletList, {}),
|
6996
|
+
/* @__PURE__ */ jsx47(RichTextEditor.OrderedList, {}),
|
6997
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Subscript, {}),
|
6998
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Superscript, {})
|
7145
6999
|
] }),
|
7146
|
-
/* @__PURE__ */
|
7147
|
-
/* @__PURE__ */
|
7148
|
-
/* @__PURE__ */
|
7000
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.ControlsGroup, { children: [
|
7001
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Link, {}),
|
7002
|
+
/* @__PURE__ */ jsx47(RichTextEditor.Unlink, {})
|
7149
7003
|
] }),
|
7150
|
-
/* @__PURE__ */
|
7151
|
-
/* @__PURE__ */
|
7152
|
-
/* @__PURE__ */
|
7153
|
-
/* @__PURE__ */
|
7154
|
-
/* @__PURE__ */
|
7004
|
+
/* @__PURE__ */ jsxs27(RichTextEditor.ControlsGroup, { children: [
|
7005
|
+
/* @__PURE__ */ jsx47(RichTextEditor.AlignLeft, {}),
|
7006
|
+
/* @__PURE__ */ jsx47(RichTextEditor.AlignCenter, {}),
|
7007
|
+
/* @__PURE__ */ jsx47(RichTextEditor.AlignJustify, {}),
|
7008
|
+
/* @__PURE__ */ jsx47(RichTextEditor.AlignRight, {})
|
7155
7009
|
] })
|
7156
7010
|
] }),
|
7157
|
-
/* @__PURE__ */
|
7011
|
+
/* @__PURE__ */ jsx47(
|
7158
7012
|
ScrollArea2.Autosize,
|
7159
7013
|
{
|
7160
7014
|
onMouseDown: () => {
|
@@ -7169,14 +7023,14 @@ function MyTextEditor(_a) {
|
|
7169
7023
|
setHiddenToolBar(false);
|
7170
7024
|
},
|
7171
7025
|
style: { cursor: "text", maxHeight: "400px" },
|
7172
|
-
children: /* @__PURE__ */
|
7026
|
+
children: /* @__PURE__ */ jsx47(RichTextEditor.Content, { mih: contentHeight })
|
7173
7027
|
}
|
7174
7028
|
)
|
7175
7029
|
] })) }));
|
7176
7030
|
}
|
7177
7031
|
|
7178
7032
|
// src/modules-features/authenticate/F_authenticate_Logout.tsx
|
7179
|
-
import { Button as
|
7033
|
+
import { Button as Button13 } from "@mantine/core";
|
7180
7034
|
import { IconLogout } from "@tabler/icons-react";
|
7181
7035
|
import { useRouter as useRouter3 } from "next/navigation";
|
7182
7036
|
|
@@ -7191,14 +7045,14 @@ function useS_authenticate() {
|
|
7191
7045
|
}
|
7192
7046
|
|
7193
7047
|
// src/modules-features/authenticate/F_authenticate_Logout.tsx
|
7194
|
-
import { jsx as
|
7048
|
+
import { jsx as jsx48 } from "react/jsx-runtime";
|
7195
7049
|
function F_authenticate_Logout({ redirectURL = "/auth/login" }) {
|
7196
7050
|
const router = useRouter3();
|
7197
7051
|
const S_Authenticate = useS_authenticate();
|
7198
|
-
return /* @__PURE__ */
|
7052
|
+
return /* @__PURE__ */ jsx48(Button13, { onClick: () => {
|
7199
7053
|
S_Authenticate.setProperty("token", "");
|
7200
7054
|
router.replace(redirectURL);
|
7201
|
-
}, leftSection: /* @__PURE__ */
|
7055
|
+
}, leftSection: /* @__PURE__ */ jsx48(IconLogout, {}), fullWidth: true, justify: "start", variant: "subtle", children: "\u0110\u0103ng xu\u1EA5t" });
|
7202
7056
|
}
|
7203
7057
|
|
7204
7058
|
// src/components/Layouts/BasicAppShell/BasicAppShell.tsx
|
@@ -7207,11 +7061,11 @@ import {
|
|
7207
7061
|
AppShell,
|
7208
7062
|
Badge as Badge3,
|
7209
7063
|
Divider as Divider2,
|
7210
|
-
Group as
|
7064
|
+
Group as Group15,
|
7211
7065
|
Image as Image3,
|
7212
7066
|
NavLink,
|
7213
7067
|
ScrollArea as ScrollArea3,
|
7214
|
-
Text as
|
7068
|
+
Text as Text14,
|
7215
7069
|
Tooltip as Tooltip5
|
7216
7070
|
} from "@mantine/core";
|
7217
7071
|
import { useFavicon, useMediaQuery } from "@mantine/hooks";
|
@@ -7222,8 +7076,8 @@ import {
|
|
7222
7076
|
} from "@tabler/icons-react";
|
7223
7077
|
import Link3 from "next/link";
|
7224
7078
|
import { usePathname as usePathname2 } from "next/navigation";
|
7225
|
-
import { useEffect as
|
7226
|
-
import { Fragment as
|
7079
|
+
import { useEffect as useEffect8, useMemo as useMemo3, useState as useState10 } from "react";
|
7080
|
+
import { Fragment as Fragment12, jsx as jsx49, jsxs as jsxs28 } from "react/jsx-runtime";
|
7227
7081
|
function findBreadcrumbPath(items, currentPath, parents = []) {
|
7228
7082
|
for (const item of items) {
|
7229
7083
|
if (item.link === currentPath) {
|
@@ -7238,13 +7092,13 @@ function findBreadcrumbPath(items, currentPath, parents = []) {
|
|
7238
7092
|
}
|
7239
7093
|
function getRightSection(status) {
|
7240
7094
|
if (status === "Prototype")
|
7241
|
-
return /* @__PURE__ */
|
7095
|
+
return /* @__PURE__ */ jsx49(Badge3, { styles: { root: { cursor: "pointer" } }, radius: "xs", color: "pink", circle: true, children: "P" });
|
7242
7096
|
if (status === "New")
|
7243
|
-
return /* @__PURE__ */
|
7097
|
+
return /* @__PURE__ */ jsx49(Badge3, { styles: { root: { cursor: "pointer" } }, radius: "xs", circle: true, children: "N" });
|
7244
7098
|
if (status === "Menu")
|
7245
|
-
return /* @__PURE__ */
|
7099
|
+
return /* @__PURE__ */ jsx49(Badge3, { styles: { root: { cursor: "pointer" } }, radius: "xs", color: "gray", circle: true, children: "M" });
|
7246
7100
|
if (status === "Change")
|
7247
|
-
return /* @__PURE__ */
|
7101
|
+
return /* @__PURE__ */ jsx49(Badge3, { styles: { root: { cursor: "pointer" } }, radius: "xs", color: "green", circle: true, children: "C" });
|
7248
7102
|
return null;
|
7249
7103
|
}
|
7250
7104
|
function RenderNavLinks({
|
@@ -7254,14 +7108,14 @@ function RenderNavLinks({
|
|
7254
7108
|
const pathName = usePathname2();
|
7255
7109
|
const index = pathName.split("/", 2).join("/").length;
|
7256
7110
|
const extractPathName = pathName.slice(index).replace("/", "");
|
7257
|
-
return /* @__PURE__ */
|
7111
|
+
return /* @__PURE__ */ jsx49(Fragment12, { children: items.map((item, index2) => /* @__PURE__ */ jsx49(
|
7258
7112
|
NavLink,
|
7259
7113
|
{
|
7260
7114
|
active: extractPathName === item.link,
|
7261
7115
|
component: Link3,
|
7262
7116
|
opened: basicAppShellStore.state.groupMenuOpenId.includes(item.label),
|
7263
7117
|
href: `/${pathName.split("/")[1]}/${item.link}` || "#",
|
7264
|
-
label: /* @__PURE__ */
|
7118
|
+
label: /* @__PURE__ */ jsxs28(MyFlexRow, { justify: "space-between", children: [
|
7265
7119
|
item.label,
|
7266
7120
|
" ",
|
7267
7121
|
getRightSection(item.status)
|
@@ -7273,7 +7127,7 @@ function RenderNavLinks({
|
|
7273
7127
|
return;
|
7274
7128
|
}
|
7275
7129
|
},
|
7276
|
-
children: item.links && /* @__PURE__ */
|
7130
|
+
children: item.links && /* @__PURE__ */ jsx49(RenderNavLinks, { items: item.links })
|
7277
7131
|
},
|
7278
7132
|
index2
|
7279
7133
|
)) });
|
@@ -7360,7 +7214,7 @@ function BasicAppShell({ children, menu, extraTopRight, title }) {
|
|
7360
7214
|
return result;
|
7361
7215
|
}, [menu]);
|
7362
7216
|
useFavicon(faviconUrl);
|
7363
|
-
|
7217
|
+
useEffect8(() => {
|
7364
7218
|
var _a2;
|
7365
7219
|
const data = GetAQModule_query.data;
|
7366
7220
|
if (!data) return;
|
@@ -7382,12 +7236,12 @@ function BasicAppShell({ children, menu, extraTopRight, title }) {
|
|
7382
7236
|
};
|
7383
7237
|
}
|
7384
7238
|
}, [GetAQModule_query.data]);
|
7385
|
-
|
7239
|
+
useEffect8(() => {
|
7386
7240
|
const data = GetAQModule_query.data;
|
7387
7241
|
if (!data) return;
|
7388
7242
|
document.title = data.name || "";
|
7389
7243
|
}, [GetAQModule_query.data]);
|
7390
|
-
|
7244
|
+
useEffect8(() => {
|
7391
7245
|
const linkItem = allChildItems.find((item) => pathName.includes(item.link));
|
7392
7246
|
const breadcrumb = findBreadcrumbPath(menu, linkItem == null ? void 0 : linkItem.link);
|
7393
7247
|
basicAppShellStore.setProperty("breadcrumb", breadcrumb);
|
@@ -7396,7 +7250,7 @@ function BasicAppShell({ children, menu, extraTopRight, title }) {
|
|
7396
7250
|
basicAppShellStore.setProperty("note", linkItem == null ? void 0 : linkItem.note);
|
7397
7251
|
basicAppShellStore.setProperty("status", linkItem == null ? void 0 : linkItem.status);
|
7398
7252
|
}, [pathName]);
|
7399
|
-
return /* @__PURE__ */
|
7253
|
+
return /* @__PURE__ */ jsxs28(
|
7400
7254
|
AppShell,
|
7401
7255
|
{
|
7402
7256
|
header: { height: 60 },
|
@@ -7410,80 +7264,80 @@ function BasicAppShell({ children, menu, extraTopRight, title }) {
|
|
7410
7264
|
},
|
7411
7265
|
padding: "md",
|
7412
7266
|
children: [
|
7413
|
-
/* @__PURE__ */
|
7414
|
-
/* @__PURE__ */
|
7415
|
-
/* @__PURE__ */
|
7267
|
+
/* @__PURE__ */ jsx49(AppShell.Header, { children: media ? /* @__PURE__ */ jsxs28(Group15, { h: "100%", px: "md", justify: "space-between", align: "center", children: [
|
7268
|
+
/* @__PURE__ */ jsxs28(Group15, { h: "100%", children: [
|
7269
|
+
/* @__PURE__ */ jsx49(
|
7416
7270
|
Tooltip5,
|
7417
7271
|
{
|
7418
7272
|
label: basicAppShellStore.state.opened ? "\u1EA8n thanh menu" : "Hi\u1EC7n thanh menu",
|
7419
|
-
children: /* @__PURE__ */
|
7273
|
+
children: /* @__PURE__ */ jsx49(
|
7420
7274
|
ActionIcon11,
|
7421
7275
|
{
|
7422
7276
|
size: "lg",
|
7423
7277
|
radius: "md",
|
7424
7278
|
variant: "default",
|
7425
7279
|
onClick: basicAppShellStore.toggle,
|
7426
|
-
children: basicAppShellStore.state.opened ? /* @__PURE__ */
|
7280
|
+
children: basicAppShellStore.state.opened ? /* @__PURE__ */ jsx49(IconLayoutSidebarLeftExpand, {}) : /* @__PURE__ */ jsx49(IconLayoutSidebarLeftCollapse, {})
|
7427
7281
|
}
|
7428
7282
|
)
|
7429
7283
|
}
|
7430
7284
|
),
|
7431
|
-
/* @__PURE__ */
|
7285
|
+
/* @__PURE__ */ jsx49(Tooltip5, { label: "\u0110\xF3ng t\u1EA5t c\u1EA3 menu", children: /* @__PURE__ */ jsx49(
|
7432
7286
|
ActionIcon11,
|
7433
7287
|
{
|
7434
7288
|
size: "lg",
|
7435
7289
|
radius: "md",
|
7436
7290
|
variant: "default",
|
7437
7291
|
onClick: () => basicAppShellStore.clearGroupMenuOpenId(),
|
7438
|
-
children: /* @__PURE__ */
|
7292
|
+
children: /* @__PURE__ */ jsx49(IconLibraryMinus, {})
|
7439
7293
|
}
|
7440
7294
|
) })
|
7441
7295
|
] }),
|
7442
|
-
/* @__PURE__ */
|
7443
|
-
|
7296
|
+
/* @__PURE__ */ jsx49(
|
7297
|
+
Group15,
|
7444
7298
|
{
|
7445
7299
|
style: {
|
7446
7300
|
position: "absolute",
|
7447
7301
|
left: "50%",
|
7448
7302
|
transform: "translateX(-50%)"
|
7449
7303
|
},
|
7450
|
-
children: /* @__PURE__ */
|
7304
|
+
children: /* @__PURE__ */ jsx49(Text14, { c: "green", fw: "bold", size: "sm", children: title ? title : `${basicAppShellStore.state.moduleCode} - ${basicAppShellStore.state.moduleName}` })
|
7451
7305
|
}
|
7452
7306
|
),
|
7453
|
-
/* @__PURE__ */
|
7307
|
+
/* @__PURE__ */ jsxs28(Group15, { children: [
|
7454
7308
|
extraTopRight,
|
7455
|
-
/* @__PURE__ */
|
7309
|
+
/* @__PURE__ */ jsx49(MySwitchTheme, {})
|
7456
7310
|
] })
|
7457
7311
|
] }) : (
|
7458
7312
|
// For mobile screens - simplified layout
|
7459
|
-
/* @__PURE__ */
|
7460
|
-
/* @__PURE__ */
|
7313
|
+
/* @__PURE__ */ jsxs28(Group15, { h: "100%", px: "md", justify: "space-between", children: [
|
7314
|
+
/* @__PURE__ */ jsx49(
|
7461
7315
|
ActionIcon11,
|
7462
7316
|
{
|
7463
7317
|
size: "lg",
|
7464
7318
|
radius: "md",
|
7465
7319
|
variant: "default",
|
7466
7320
|
onClick: basicAppShellStore.toggle,
|
7467
|
-
children: basicAppShellStore.state.opened ? /* @__PURE__ */
|
7321
|
+
children: basicAppShellStore.state.opened ? /* @__PURE__ */ jsx49(IconLayoutSidebarLeftExpand, {}) : /* @__PURE__ */ jsx49(IconLayoutSidebarLeftCollapse, {})
|
7468
7322
|
}
|
7469
7323
|
),
|
7470
|
-
/* @__PURE__ */
|
7471
|
-
/* @__PURE__ */
|
7324
|
+
/* @__PURE__ */ jsx49(Text14, { c: "green", fw: "bold", size: "sm", children: title ? title : `${basicAppShellStore.state.moduleCode} - ${basicAppShellStore.state.moduleName}` }),
|
7325
|
+
/* @__PURE__ */ jsxs28(Group15, { children: [
|
7472
7326
|
extraTopRight,
|
7473
|
-
/* @__PURE__ */
|
7327
|
+
/* @__PURE__ */ jsx49(MySwitchTheme, {})
|
7474
7328
|
] })
|
7475
7329
|
] })
|
7476
7330
|
) }),
|
7477
|
-
/* @__PURE__ */
|
7478
|
-
/* @__PURE__ */
|
7479
|
-
/* @__PURE__ */
|
7480
|
-
/* @__PURE__ */
|
7481
|
-
/* @__PURE__ */
|
7482
|
-
/* @__PURE__ */
|
7331
|
+
/* @__PURE__ */ jsxs28(AppShell.Navbar, { children: [
|
7332
|
+
/* @__PURE__ */ jsx49(MyAppSpotlight, { menu }),
|
7333
|
+
/* @__PURE__ */ jsxs28(AppShell.Section, { grow: true, component: ScrollArea3, p: 5, children: [
|
7334
|
+
/* @__PURE__ */ jsx49(RenderNavLinks, { items: menu }),
|
7335
|
+
/* @__PURE__ */ jsx49(Divider2, {}),
|
7336
|
+
/* @__PURE__ */ jsx49(F_authenticate_Logout, {})
|
7483
7337
|
] }),
|
7484
|
-
/* @__PURE__ */
|
7485
|
-
/* @__PURE__ */
|
7486
|
-
/* @__PURE__ */
|
7338
|
+
/* @__PURE__ */ jsxs28(AppShell.Section, { p: "md", children: [
|
7339
|
+
/* @__PURE__ */ jsx49(Divider2, {}),
|
7340
|
+
/* @__PURE__ */ jsx49(
|
7487
7341
|
Image3,
|
7488
7342
|
{
|
7489
7343
|
fit: "contain",
|
@@ -7497,7 +7351,7 @@ function BasicAppShell({ children, menu, extraTopRight, title }) {
|
|
7497
7351
|
)
|
7498
7352
|
] })
|
7499
7353
|
] }),
|
7500
|
-
/* @__PURE__ */
|
7354
|
+
/* @__PURE__ */ jsx49(
|
7501
7355
|
AppShell.Main,
|
7502
7356
|
{
|
7503
7357
|
bg: "light-dark(var(--mantine-color-gray-1), var(--mantine-color-dark-8))",
|
@@ -7552,24 +7406,24 @@ function utils_layout_getItemsWithoutLinks(menu) {
|
|
7552
7406
|
|
7553
7407
|
// src/components/Layouts/Container/MyContainer.tsx
|
7554
7408
|
import { Container, Flex as Flex3 } from "@mantine/core";
|
7555
|
-
import { jsx as
|
7409
|
+
import { jsx as jsx50 } from "react/jsx-runtime";
|
7556
7410
|
function MyContainer(_a) {
|
7557
7411
|
var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
|
7558
|
-
return /* @__PURE__ */
|
7412
|
+
return /* @__PURE__ */ jsx50(Container, __spreadProps(__spreadValues({ fluid: true }, rest), { children: /* @__PURE__ */ jsx50(Flex3, { direction: "column", children }) }));
|
7559
7413
|
}
|
7560
7414
|
|
7561
7415
|
// src/components/Layouts/HeaderMegaMenu/HeaderMegaMenu.tsx
|
7562
7416
|
import {
|
7563
7417
|
Box as Box4,
|
7564
7418
|
Burger,
|
7565
|
-
Button as
|
7419
|
+
Button as Button14,
|
7566
7420
|
Container as Container2,
|
7567
7421
|
Divider as Divider3,
|
7568
7422
|
Drawer,
|
7569
|
-
Group as
|
7423
|
+
Group as Group16,
|
7570
7424
|
Image as Image4,
|
7571
7425
|
ScrollArea as ScrollArea4,
|
7572
|
-
Text as
|
7426
|
+
Text as Text15,
|
7573
7427
|
TextInput as TextInput3,
|
7574
7428
|
ThemeIcon,
|
7575
7429
|
UnstyledButton,
|
@@ -7601,7 +7455,7 @@ function useHeaderMegaMenuStore() {
|
|
7601
7455
|
}
|
7602
7456
|
|
7603
7457
|
// src/components/Layouts/HeaderMegaMenu/HeaderMegaMenu.tsx
|
7604
|
-
import { jsx as
|
7458
|
+
import { jsx as jsx51, jsxs as jsxs29 } from "react/jsx-runtime";
|
7605
7459
|
var mockdata = [
|
7606
7460
|
{
|
7607
7461
|
icon: IconCode,
|
@@ -7639,27 +7493,27 @@ function HeaderMegaMenu({ children, menus }) {
|
|
7639
7493
|
const [linksOpened, { toggle: toggleLinks }] = useDisclosure11(false);
|
7640
7494
|
const HeaderMegaMenuStore = useHeaderMegaMenuStore();
|
7641
7495
|
const theme = useMantineTheme();
|
7642
|
-
const links = mockdata.map((item) => /* @__PURE__ */
|
7643
|
-
/* @__PURE__ */
|
7644
|
-
/* @__PURE__ */
|
7645
|
-
/* @__PURE__ */
|
7646
|
-
/* @__PURE__ */
|
7496
|
+
const links = mockdata.map((item) => /* @__PURE__ */ jsx51(UnstyledButton, { className: css_default.subLink, children: /* @__PURE__ */ jsxs29(Group16, { wrap: "nowrap", align: "flex-start", children: [
|
7497
|
+
/* @__PURE__ */ jsx51(ThemeIcon, { size: 34, variant: "default", radius: "md", children: /* @__PURE__ */ jsx51(item.icon, { size: 22, color: theme.colors.blue[6] }) }),
|
7498
|
+
/* @__PURE__ */ jsxs29("div", { children: [
|
7499
|
+
/* @__PURE__ */ jsx51(Text15, { size: "sm", fw: 500, children: item.title }),
|
7500
|
+
/* @__PURE__ */ jsx51(Text15, { size: "xs", c: "dimmed", children: item.description })
|
7647
7501
|
] })
|
7648
7502
|
] }) }, item.title));
|
7649
|
-
return /* @__PURE__ */
|
7650
|
-
/* @__PURE__ */
|
7651
|
-
/* @__PURE__ */
|
7652
|
-
/* @__PURE__ */
|
7653
|
-
/* @__PURE__ */
|
7503
|
+
return /* @__PURE__ */ jsxs29(Box4, { children: [
|
7504
|
+
/* @__PURE__ */ jsx51("header", { className: css_default.header, children: /* @__PURE__ */ jsxs29(Group16, { justify: "space-between", h: "100%", children: [
|
7505
|
+
/* @__PURE__ */ jsxs29(Group16, { children: [
|
7506
|
+
/* @__PURE__ */ jsx51(Image4, { src: "/imgs/0/IMG0LogoAQTech.png", h: 30, alt: "", w: "auto" }),
|
7507
|
+
/* @__PURE__ */ jsx51(Group16, { h: "100%", gap: 5, visibleFrom: "sm", children: menus == null ? void 0 : menus.map((item, idx) => /* @__PURE__ */ jsx51(Button14, { component: Link4, href: item.href, variant: HeaderMegaMenuStore.state.name == item.label ? "light" : "subtle", onClick: () => HeaderMegaMenuStore.setState({ name: item.label }), children: item.label }, idx)) })
|
7654
7508
|
] }),
|
7655
|
-
/* @__PURE__ */
|
7656
|
-
/* @__PURE__ */
|
7657
|
-
/* @__PURE__ */
|
7509
|
+
/* @__PURE__ */ jsxs29(Group16, { children: [
|
7510
|
+
/* @__PURE__ */ jsx51(TextInput3, { placeholder: "T\xECm ki\u1EBFm", leftSection: /* @__PURE__ */ jsx51(IconSearch2, {}), radius: "xl", w: "250px" }),
|
7511
|
+
/* @__PURE__ */ jsx51(MySwitchTheme, {})
|
7658
7512
|
] }),
|
7659
|
-
/* @__PURE__ */
|
7513
|
+
/* @__PURE__ */ jsx51(Burger, { opened: drawerOpened, onClick: toggleDrawer, hiddenFrom: "sm" })
|
7660
7514
|
] }) }),
|
7661
|
-
/* @__PURE__ */
|
7662
|
-
/* @__PURE__ */
|
7515
|
+
/* @__PURE__ */ jsx51(Container2, { fluid: true, pt: "sm", pb: "md", bg: const_object_colors.mantineBackgroundSecondary, mih: "93vh", children }),
|
7516
|
+
/* @__PURE__ */ jsx51(
|
7663
7517
|
Drawer,
|
7664
7518
|
{
|
7665
7519
|
opened: drawerOpened,
|
@@ -7669,10 +7523,10 @@ function HeaderMegaMenu({ children, menus }) {
|
|
7669
7523
|
title: "Navigation",
|
7670
7524
|
hiddenFrom: "sm",
|
7671
7525
|
zIndex: 1e6,
|
7672
|
-
children: /* @__PURE__ */
|
7673
|
-
/* @__PURE__ */
|
7674
|
-
/* @__PURE__ */
|
7675
|
-
/* @__PURE__ */
|
7526
|
+
children: /* @__PURE__ */ jsxs29(ScrollArea4, { h: "calc(100vh - 80px", mx: "-md", children: [
|
7527
|
+
/* @__PURE__ */ jsx51(Divider3, { my: "sm" }),
|
7528
|
+
/* @__PURE__ */ jsx51(MyFlexColumn, { h: "100%", gap: 0, children: menus == null ? void 0 : menus.map((item, idx) => /* @__PURE__ */ jsx51(Button14, { component: Link4, href: item.href, variant: HeaderMegaMenuStore.state.name == item.label ? "light" : "subtle", onClick: () => HeaderMegaMenuStore.setState({ name: item.label }), children: item.label }, idx)) }),
|
7529
|
+
/* @__PURE__ */ jsx51(Divider3, { my: "sm" })
|
7676
7530
|
] })
|
7677
7531
|
}
|
7678
7532
|
)
|
@@ -7680,8 +7534,8 @@ function HeaderMegaMenu({ children, menus }) {
|
|
7680
7534
|
}
|
7681
7535
|
|
7682
7536
|
// src/components/Layouts/PageContent/MyPageContent.tsx
|
7683
|
-
import { Badge as Badge4, Breadcrumbs, Code, Container as Container3, Divider as Divider4, Group as
|
7684
|
-
import { jsx as
|
7537
|
+
import { Badge as Badge4, Breadcrumbs, Code, Container as Container3, Divider as Divider4, Group as Group17, Text as Text16, Title } from "@mantine/core";
|
7538
|
+
import { jsx as jsx52, jsxs as jsxs30 } from "react/jsx-runtime";
|
7685
7539
|
var getStatusColor = (status) => {
|
7686
7540
|
switch (status) {
|
7687
7541
|
case "Prototype":
|
@@ -7692,10 +7546,10 @@ var getStatusColor = (status) => {
|
|
7692
7546
|
};
|
7693
7547
|
function PageTitle({ title, status, note }) {
|
7694
7548
|
const color = getStatusColor(status);
|
7695
|
-
return /* @__PURE__ */
|
7696
|
-
/* @__PURE__ */
|
7697
|
-
/* @__PURE__ */
|
7698
|
-
status && /* @__PURE__ */
|
7549
|
+
return /* @__PURE__ */ jsx52(Group17, { children: /* @__PURE__ */ jsxs30(MyFlexColumn, { gap: 0, children: [
|
7550
|
+
/* @__PURE__ */ jsxs30(Group17, { align: "center", children: [
|
7551
|
+
/* @__PURE__ */ jsx52(Title, { order: 3, children: title }),
|
7552
|
+
status && /* @__PURE__ */ jsx52(
|
7699
7553
|
Badge4,
|
7700
7554
|
{
|
7701
7555
|
variant: "gradient",
|
@@ -7706,7 +7560,7 @@ function PageTitle({ title, status, note }) {
|
|
7706
7560
|
}
|
7707
7561
|
)
|
7708
7562
|
] }),
|
7709
|
-
/* @__PURE__ */
|
7563
|
+
/* @__PURE__ */ jsx52(Text16, { size: "lg", c: "dimmed", fs: "italic", children: note })
|
7710
7564
|
] }) });
|
7711
7565
|
}
|
7712
7566
|
function MyPageContent({
|
@@ -7719,11 +7573,11 @@ function MyPageContent({
|
|
7719
7573
|
var _a;
|
7720
7574
|
const basicAppShellStore = useS_BasicAppShell();
|
7721
7575
|
const finalTitle = title || basicAppShellStore.state.title;
|
7722
|
-
return /* @__PURE__ */
|
7723
|
-
/* @__PURE__ */
|
7724
|
-
/* @__PURE__ */
|
7725
|
-
/* @__PURE__ */
|
7726
|
-
/* @__PURE__ */
|
7576
|
+
return /* @__PURE__ */ jsxs30(Container3, { p: 0, fluid: true, children: [
|
7577
|
+
/* @__PURE__ */ jsxs30(Group17, { justify: "space-between", children: [
|
7578
|
+
/* @__PURE__ */ jsxs30(Group17, { children: [
|
7579
|
+
/* @__PURE__ */ jsx52(MyButtonRouterBack, {}),
|
7580
|
+
/* @__PURE__ */ jsx52(
|
7727
7581
|
PageTitle,
|
7728
7582
|
{
|
7729
7583
|
title: finalTitle,
|
@@ -7733,64 +7587,64 @@ function MyPageContent({
|
|
7733
7587
|
),
|
7734
7588
|
leftTopBar
|
7735
7589
|
] }),
|
7736
|
-
/* @__PURE__ */
|
7590
|
+
/* @__PURE__ */ jsxs30(Group17, { p: "md", children: [
|
7737
7591
|
rightTopBar,
|
7738
|
-
/* @__PURE__ */
|
7592
|
+
/* @__PURE__ */ jsx52(Breadcrumbs, { separatorMargin: "7", children: (_a = basicAppShellStore.state.breadcrumb) == null ? void 0 : _a.map((item, idx) => /* @__PURE__ */ jsx52(Text16, { fw: "600", c: "blue", children: item }, idx)) })
|
7739
7593
|
] })
|
7740
7594
|
] }),
|
7741
|
-
/* @__PURE__ */
|
7595
|
+
/* @__PURE__ */ jsx52(Divider4, { my: "xs" }),
|
7742
7596
|
children,
|
7743
|
-
/* @__PURE__ */
|
7744
|
-
/* @__PURE__ */
|
7597
|
+
/* @__PURE__ */ jsx52(Divider4, { my: "xs" }),
|
7598
|
+
/* @__PURE__ */ jsx52(MyFlexEnd, { children: /* @__PURE__ */ jsx52(Code, { color: "var(--mantine-color-blue-light)", children: basicAppShellStore.state.menuCode }) })
|
7745
7599
|
] });
|
7746
7600
|
}
|
7747
7601
|
|
7748
7602
|
// src/components/Layouts/Tab/MyTab.tsx
|
7749
7603
|
import { rem, Space as Space3, Tabs } from "@mantine/core";
|
7750
|
-
import { jsx as
|
7604
|
+
import { jsx as jsx53, jsxs as jsxs31 } from "react/jsx-runtime";
|
7751
7605
|
function MyTab(_a) {
|
7752
7606
|
var _b = _a, { tabList, children } = _b, rest = __objRest(_b, ["tabList", "children"]);
|
7753
7607
|
const iconStyle = { width: rem(20), height: rem(20) };
|
7754
|
-
return /* @__PURE__ */
|
7755
|
-
/* @__PURE__ */
|
7756
|
-
return /* @__PURE__ */
|
7608
|
+
return /* @__PURE__ */ jsxs31(Tabs, __spreadProps(__spreadValues({ defaultValue: tabList[0].label }, rest), { children: [
|
7609
|
+
/* @__PURE__ */ jsx53(Tabs.List, { children: tabList.map((item, idx) => {
|
7610
|
+
return /* @__PURE__ */ jsx53(Tabs.Tab, { value: item.label, leftSection: item.icon && /* @__PURE__ */ jsx53(item.icon, { style: iconStyle }), children: item.label }, idx);
|
7757
7611
|
}) }),
|
7758
|
-
/* @__PURE__ */
|
7612
|
+
/* @__PURE__ */ jsx53(Space3, { my: "md" }),
|
7759
7613
|
children
|
7760
7614
|
] }));
|
7761
7615
|
}
|
7762
7616
|
|
7763
7617
|
// src/components/RESTAPIComponents/DataTableSelect/MyDataTableSelect.tsx
|
7764
|
-
import { ActionIcon as ActionIcon12, Button as
|
7618
|
+
import { ActionIcon as ActionIcon12, Button as Button15, Fieldset as Fieldset5, Group as Group18, Modal as Modal11 } from "@mantine/core";
|
7765
7619
|
import { useDisclosure as useDisclosure12 } from "@mantine/hooks";
|
7766
7620
|
import { IconX as IconX2 } from "@tabler/icons-react";
|
7767
|
-
import { jsx as
|
7621
|
+
import { jsx as jsx54, jsxs as jsxs32 } from "react/jsx-runtime";
|
7768
7622
|
function MyDataTableSelect(_a) {
|
7769
7623
|
var _b = _a, { modalSize, renderTopToolbarCustomActions, data, selectButtonlabel, listState, columns, listLabel } = _b, rest = __objRest(_b, ["modalSize", "renderTopToolbarCustomActions", "data", "selectButtonlabel", "listState", "columns", "listLabel"]);
|
7770
7624
|
const disc = useDisclosure12(false);
|
7771
7625
|
if (data == void 0) return "\u0110ang t\u1EA3i...";
|
7772
|
-
return /* @__PURE__ */
|
7773
|
-
/* @__PURE__ */
|
7626
|
+
return /* @__PURE__ */ jsxs32(Fieldset5, { legend: listLabel ? listLabel : "Danh s\xE1ch", children: [
|
7627
|
+
/* @__PURE__ */ jsx54(
|
7774
7628
|
MyDataTable,
|
7775
7629
|
__spreadValues({
|
7776
7630
|
renderTopToolbarCustomActions: ({ table }) => {
|
7777
|
-
return /* @__PURE__ */
|
7631
|
+
return /* @__PURE__ */ jsxs32(Group18, { children: [
|
7778
7632
|
renderTopToolbarCustomActions && renderTopToolbarCustomActions({ table }),
|
7779
|
-
/* @__PURE__ */
|
7633
|
+
/* @__PURE__ */ jsx54(Button15, { onClick: disc[1].open, children: selectButtonlabel || "Ch\u1ECDn t\u1EEB danh s\xE1ch" })
|
7780
7634
|
] });
|
7781
7635
|
},
|
7782
7636
|
columns,
|
7783
7637
|
data: listState[0],
|
7784
7638
|
renderRowActions: ({ row }) => {
|
7785
|
-
return /* @__PURE__ */
|
7639
|
+
return /* @__PURE__ */ jsx54(MyCenterFull, { children: /* @__PURE__ */ jsx54(ActionIcon12, { color: "red", onClick: () => listState[1].remove(row.index), children: /* @__PURE__ */ jsx54(IconX2, {}) }) });
|
7786
7640
|
}
|
7787
7641
|
}, rest)
|
7788
7642
|
),
|
7789
|
-
/* @__PURE__ */
|
7643
|
+
/* @__PURE__ */ jsx54(Modal11, { opened: disc[0], onClose: disc[1].close, size: modalSize || "80%", children: /* @__PURE__ */ jsx54(
|
7790
7644
|
MyDataTable,
|
7791
7645
|
__spreadValues({
|
7792
7646
|
renderTopToolbarCustomActions: ({ table }) => {
|
7793
|
-
return /* @__PURE__ */
|
7647
|
+
return /* @__PURE__ */ jsx54(Button15, { onClick: () => {
|
7794
7648
|
table.getSelectedRowModel().rows.map((item) => listState[1].append(item.original));
|
7795
7649
|
disc[1].close();
|
7796
7650
|
}, children: "Ch\u1ECDn" });
|
@@ -7806,7 +7660,7 @@ function MyDataTableSelect(_a) {
|
|
7806
7660
|
// src/components/RESTAPIComponents/SelectAPIGet/MySelectAPIGet.tsx
|
7807
7661
|
import { Select as Select3 } from "@mantine/core";
|
7808
7662
|
import { useQuery as useQuery2 } from "@tanstack/react-query";
|
7809
|
-
import { jsx as
|
7663
|
+
import { jsx as jsx55 } from "react/jsx-runtime";
|
7810
7664
|
function MySelectAPIGet(_a) {
|
7811
7665
|
var _b = _a, { apiGet, label = "", dataMapper } = _b, rest = __objRest(_b, ["apiGet", "label", "dataMapper"]);
|
7812
7666
|
var _a2;
|
@@ -7825,7 +7679,7 @@ function MySelectAPIGet(_a) {
|
|
7825
7679
|
label: `${item.code}-${item.name}`
|
7826
7680
|
};
|
7827
7681
|
});
|
7828
|
-
return /* @__PURE__ */
|
7682
|
+
return /* @__PURE__ */ jsx55(
|
7829
7683
|
Select3,
|
7830
7684
|
__spreadValues({
|
7831
7685
|
label,
|
@@ -7840,7 +7694,7 @@ import { useNextCalendarApp as useNextCalendarApp2, ScheduleXCalendar as Schedul
|
|
7840
7694
|
import { createEventsServicePlugin as createEventsServicePlugin2 } from "@schedule-x/events-service";
|
7841
7695
|
import { useState as useState11 } from "react";
|
7842
7696
|
import { createEventModalPlugin as createEventModalPlugin2 } from "@schedule-x/event-modal";
|
7843
|
-
import { jsx as
|
7697
|
+
import { jsx as jsx56 } from "react/jsx-runtime";
|
7844
7698
|
function MyScheduleX({
|
7845
7699
|
values,
|
7846
7700
|
timeGridEvent,
|
@@ -7865,7 +7719,7 @@ function MyScheduleX({
|
|
7865
7719
|
events: values,
|
7866
7720
|
plugins: [eventsService, eventModalPlugin]
|
7867
7721
|
});
|
7868
|
-
return /* @__PURE__ */
|
7722
|
+
return /* @__PURE__ */ jsx56(
|
7869
7723
|
ScheduleXCalendar2,
|
7870
7724
|
{
|
7871
7725
|
calendarApp: calendar,
|
@@ -7879,9 +7733,9 @@ function MyScheduleX({
|
|
7879
7733
|
|
7880
7734
|
// src/components/Skeletons/SkeletonTable/MySkeletonTable.tsx
|
7881
7735
|
import { Skeleton } from "@mantine/core";
|
7882
|
-
import { jsx as
|
7736
|
+
import { jsx as jsx57 } from "react/jsx-runtime";
|
7883
7737
|
function MySkeletonTable({ h: h4 = 500 }) {
|
7884
|
-
return /* @__PURE__ */
|
7738
|
+
return /* @__PURE__ */ jsx57(Skeleton, { h: h4 });
|
7885
7739
|
}
|
7886
7740
|
|
7887
7741
|
export {
|
@@ -7911,7 +7765,6 @@ export {
|
|
7911
7765
|
MyFlexEnd,
|
7912
7766
|
useS_ButtonImport,
|
7913
7767
|
SelectFieldModal,
|
7914
|
-
MyDataTable,
|
7915
7768
|
SelectFileModal,
|
7916
7769
|
MyButtonImport,
|
7917
7770
|
AQSelectTableByOpenModal,
|