fastapi-rtk 0.2.47 → 0.2.49
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/.bundled/jsonforms/cjs/packages/jsonforms/src/JsonFormsWithCustomizer/JsonFormsWithCustomizer.cjs +2 -1
- package/dist/.bundled/jsonforms/esm/packages/jsonforms/src/JsonFormsWithCustomizer/JsonFormsWithCustomizer.mjs +3 -2
- package/dist/.external/cjs/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.cjs +0 -73
- package/dist/.external/esm/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.mjs +2 -75
- package/dist/core/cjs/ActionIcons/Add/Add.cjs +1 -1
- package/dist/core/cjs/ActionIcons/Delete/Delete.cjs +1 -1
- package/dist/core/cjs/ActionIcons/Download/Download.cjs +1 -1
- package/dist/core/cjs/ActionIcons/Edit/Edit.cjs +1 -1
- package/dist/core/cjs/ActionIcons/Refresh/Refresh.cjs +1 -1
- package/dist/core/cjs/ActionIcons/View/View.cjs +1 -1
- package/dist/core/cjs/Dialogs/AddDialog.cjs +2 -2
- package/dist/core/cjs/Dialogs/DeleteDialog.cjs +1 -1
- package/dist/core/cjs/Dialogs/EditDialog.cjs +2 -2
- package/dist/core/cjs/Modals/CommonModal.cjs +1 -1
- package/dist/core/cjs/Tables/DataGrid/ErrorDialog.cjs +1 -1
- package/dist/core/cjs/Tables/DataGrid/Toolbar/Filter/FilterMenu.cjs +1 -1
- package/dist/core/cjs/Tables/NextGenDataGrid/NextGenDataGrid.cjs +2 -1
- package/dist/core/cjs/Tables/NextGenDataGrid/hooks/useColumns/ColumnHeaderFilterInput/ColumnHeaderFilterInput.cjs +1 -1
- package/dist/core/cjs/Tables/NextGenDataGrid/hooks/useColumns/ColumnHeaderFilterInput/HeaderInputs/HeaderBetweenInput.cjs +1 -1
- package/dist/core/cjs/Tables/NextGenDataGrid/hooks/useColumns/HeaderAdvancedFiltersMenuButton.cjs +1 -1
- package/dist/core/cjs/Tables/NextGenDataGrid/hooks/useSize.cjs +4 -2
- package/dist/core/cjs/Tables/NextGenDataGrid/patch/MRT_TableContainer.cjs +81 -0
- package/dist/core/cjs/Tables/NextGenDataGrid/patch/MRT_TableContainer.module.css.cjs +10 -0
- package/dist/core/cjs/Tables/NextGenDataGrid/patch/MRT_TablePaper.cjs +66 -0
- package/dist/core/cjs/Tables/NextGenDataGrid/patch/MRT_TablePaper.module.css.cjs +8 -0
- package/dist/core/cjs/Tables/NextGenDataGrid/patch/MantineReactTable.cjs +16 -0
- package/dist/core/cjs/Wrappers/ApiProvider/hooks/useProvideForm.cjs +1 -1
- package/dist/core/cjs/Wrappers/Provider/Contexts/LangContext.cjs +3 -3
- package/dist/core/cjs/Wrappers/Provider/hooks/useProvideLang.cjs +1 -1
- package/dist/core/cjs/index.cjs +1 -1
- package/dist/core/esm/ActionIcons/Add/Add.mjs +1 -1
- package/dist/core/esm/ActionIcons/Delete/Delete.mjs +1 -1
- package/dist/core/esm/ActionIcons/Download/Download.mjs +1 -1
- package/dist/core/esm/ActionIcons/Edit/Edit.mjs +1 -1
- package/dist/core/esm/ActionIcons/Refresh/Refresh.mjs +1 -1
- package/dist/core/esm/ActionIcons/View/View.mjs +1 -1
- package/dist/core/esm/Dialogs/AddDialog.mjs +2 -2
- package/dist/core/esm/Dialogs/DeleteDialog.mjs +1 -1
- package/dist/core/esm/Dialogs/EditDialog.mjs +2 -2
- package/dist/core/esm/Modals/CommonModal.mjs +1 -1
- package/dist/core/esm/Tables/DataGrid/ErrorDialog.mjs +1 -1
- package/dist/core/esm/Tables/DataGrid/Toolbar/Filter/FilterMenu.mjs +1 -1
- package/dist/core/esm/Tables/NextGenDataGrid/NextGenDataGrid.mjs +2 -1
- package/dist/core/esm/Tables/NextGenDataGrid/hooks/useColumns/ColumnHeaderFilterInput/ColumnHeaderFilterInput.mjs +1 -1
- package/dist/core/esm/Tables/NextGenDataGrid/hooks/useColumns/ColumnHeaderFilterInput/HeaderInputs/HeaderBetweenInput.mjs +1 -1
- package/dist/core/esm/Tables/NextGenDataGrid/hooks/useColumns/HeaderAdvancedFiltersMenuButton.mjs +1 -1
- package/dist/core/esm/Tables/NextGenDataGrid/hooks/useSize.mjs +4 -2
- package/dist/core/esm/Tables/NextGenDataGrid/patch/MRT_TableContainer.mjs +81 -0
- package/dist/core/esm/Tables/NextGenDataGrid/patch/MRT_TableContainer.module.css.mjs +10 -0
- package/dist/core/esm/Tables/NextGenDataGrid/patch/MRT_TablePaper.mjs +66 -0
- package/dist/core/esm/Tables/NextGenDataGrid/patch/MRT_TablePaper.module.css.mjs +8 -0
- package/dist/core/esm/Tables/NextGenDataGrid/patch/MantineReactTable.mjs +16 -0
- package/dist/core/esm/Wrappers/ApiProvider/hooks/useProvideForm.mjs +1 -1
- package/dist/core/esm/Wrappers/Provider/Contexts/LangContext.mjs +3 -3
- package/dist/core/esm/Wrappers/Provider/hooks/useProvideLang.mjs +1 -1
- package/dist/core/esm/index.mjs +1 -1
- package/dist/core/lib/Tables/NextGenDataGrid/hooks/useSize.d.ts +3 -0
- package/dist/core/lib/Tables/NextGenDataGrid/patch/MRT_TableContainer.d.ts +4 -0
- package/dist/core/lib/Tables/NextGenDataGrid/patch/MRT_TablePaper.d.ts +4 -0
- package/dist/core/lib/Tables/NextGenDataGrid/patch/MantineReactTable.d.ts +1 -0
- package/dist/core/styles.css +91 -0
- package/dist/jsonforms/cjs/JsonFormsWithCustomizer/JsonFormsWithCustomizer.cjs +2 -1
- package/dist/jsonforms/esm/JsonFormsWithCustomizer/JsonFormsWithCustomizer.mjs +3 -2
- package/dist/zustand/cjs/useProxy/useProxy.cjs +1 -1
- package/dist/zustand/esm/useProxy/useProxy.mjs +1 -1
- package/package.json +1 -1
- /package/dist/.external/cjs/{i18next@25.5.2_typescript@5.9.2 → i18next@25.5.3_typescript@5.9.3}/i18next/dist/esm/i18next.cjs +0 -0
- /package/dist/.external/cjs/{mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.2_yup@1.7.1 → mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.3_yup@1.7.1}/mantine-form-yup-resolver/dist/esm/index.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/I18nextProvider.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/context.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/defaults.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/i18nInstance.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/initReactI18next.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/unescape.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/useTranslation.cjs +0 -0
- /package/dist/.external/cjs/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/utils.cjs +0 -0
- /package/dist/.external/cjs/{zustand@5.0.8_@types_react@18.3.24_react@18.3.1 → zustand@5.0.8_@types_react@18.3.25_react@18.3.1}/zustand/esm/react.cjs +0 -0
- /package/dist/.external/cjs/{zustand@5.0.8_@types_react@18.3.24_react@18.3.1 → zustand@5.0.8_@types_react@18.3.25_react@18.3.1}/zustand/esm/vanilla.cjs +0 -0
- /package/dist/.external/esm/{i18next@25.5.2_typescript@5.9.2 → i18next@25.5.3_typescript@5.9.3}/i18next/dist/esm/i18next.mjs +0 -0
- /package/dist/.external/esm/{mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.2_yup@1.7.1 → mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.3_yup@1.7.1}/mantine-form-yup-resolver/dist/esm/index.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/I18nextProvider.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/context.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/defaults.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/i18nInstance.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/initReactI18next.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/unescape.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/useTranslation.mjs +0 -0
- /package/dist/.external/esm/{react-i18next@15.7.3_i18next@25.5.2_react-dom@18.3.1_react@18.3.1_typescript@5.9.2 → react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3}/react-i18next/dist/es/utils.mjs +0 -0
- /package/dist/.external/esm/{zustand@5.0.8_@types_react@18.3.24_react@18.3.1 → zustand@5.0.8_@types_react@18.3.25_react@18.3.1}/zustand/esm/react.mjs +0 -0
- /package/dist/.external/esm/{zustand@5.0.8_@types_react@18.3.24_react@18.3.1 → zustand@5.0.8_@types_react@18.3.25_react@18.3.1}/zustand/esm/vanilla.mjs +0 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
4
|
+
const utils = require("fastapi-rtk/utils");
|
|
5
|
+
const core = require("@mantine/core");
|
|
6
|
+
const clsx = require("../../../../../.external/cjs/clsx@2.1.1/clsx/dist/clsx.cjs");
|
|
7
|
+
const index_esm = require("../../../../../.external/cjs/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.cjs");
|
|
8
|
+
const MRT_TableContainer = require("./MRT_TableContainer.cjs");
|
|
9
|
+
const MRT_TablePaper_module = require("./MRT_TablePaper.module.css.cjs");
|
|
10
|
+
const MRT_TablePaper = ({ table, ...rest }) => {
|
|
11
|
+
const {
|
|
12
|
+
getState,
|
|
13
|
+
options: { enableBottomToolbar, enableTopToolbar, mantinePaperProps, renderBottomToolbar, renderTopToolbar },
|
|
14
|
+
refs: { tablePaperRef }
|
|
15
|
+
} = table;
|
|
16
|
+
const { isFullScreen } = getState();
|
|
17
|
+
const tablePaperProps = {
|
|
18
|
+
...utils.parseFromValuesOrFunc(mantinePaperProps, { table }),
|
|
19
|
+
...rest
|
|
20
|
+
};
|
|
21
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
22
|
+
core.Paper,
|
|
23
|
+
{
|
|
24
|
+
shadow: "xs",
|
|
25
|
+
withBorder: true,
|
|
26
|
+
...tablePaperProps,
|
|
27
|
+
className: clsx.clsx(
|
|
28
|
+
"mrt-table-paper",
|
|
29
|
+
MRT_TablePaper_module.default.root,
|
|
30
|
+
isFullScreen && "mrt-table-paper-fullscreen",
|
|
31
|
+
tablePaperProps == null ? void 0 : tablePaperProps.className
|
|
32
|
+
),
|
|
33
|
+
ref: (ref) => {
|
|
34
|
+
tablePaperRef.current = ref;
|
|
35
|
+
if (tablePaperProps == null ? void 0 : tablePaperProps.ref) {
|
|
36
|
+
tablePaperProps.ref.current = ref;
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
style: (theme) => ({
|
|
40
|
+
zIndex: isFullScreen ? 200 : void 0,
|
|
41
|
+
...utils.parseFromValuesOrFunc(tablePaperProps == null ? void 0 : tablePaperProps.style, theme),
|
|
42
|
+
...isFullScreen ? {
|
|
43
|
+
border: 0,
|
|
44
|
+
borderRadius: 0,
|
|
45
|
+
bottom: 0,
|
|
46
|
+
height: "100vh",
|
|
47
|
+
left: 0,
|
|
48
|
+
margin: 0,
|
|
49
|
+
maxHeight: "100vh",
|
|
50
|
+
maxWidth: "100vw",
|
|
51
|
+
padding: 0,
|
|
52
|
+
position: "fixed",
|
|
53
|
+
right: 0,
|
|
54
|
+
top: 0,
|
|
55
|
+
width: "100vw"
|
|
56
|
+
} : null
|
|
57
|
+
}),
|
|
58
|
+
children: [
|
|
59
|
+
enableTopToolbar && (utils.parseFromValuesOrFunc(renderTopToolbar, { table }) ?? /* @__PURE__ */ jsxRuntime.jsx(index_esm.MRT_TopToolbar, { table })),
|
|
60
|
+
/* @__PURE__ */ jsxRuntime.jsx(MRT_TableContainer.MRT_TableContainer, { table }),
|
|
61
|
+
enableBottomToolbar && (utils.parseFromValuesOrFunc(renderBottomToolbar, { table }) ?? /* @__PURE__ */ jsxRuntime.jsx(index_esm.MRT_BottomToolbar, { table }))
|
|
62
|
+
]
|
|
63
|
+
}
|
|
64
|
+
);
|
|
65
|
+
};
|
|
66
|
+
exports.MRT_TablePaper = MRT_TablePaper;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
4
|
+
const index_esm = require("../../../../../.external/cjs/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.cjs");
|
|
5
|
+
const MRT_TablePaper = require("./MRT_TablePaper.cjs");
|
|
6
|
+
const isTableInstanceProp = (props) => props.table !== void 0;
|
|
7
|
+
const MantineReactTable = (props) => {
|
|
8
|
+
let table;
|
|
9
|
+
if (isTableInstanceProp(props)) {
|
|
10
|
+
table = props.table;
|
|
11
|
+
} else {
|
|
12
|
+
table = index_esm.useMantineReactTable(props);
|
|
13
|
+
}
|
|
14
|
+
return /* @__PURE__ */ jsxRuntime.jsx(MRT_TablePaper.MRT_TablePaper, { table });
|
|
15
|
+
};
|
|
16
|
+
exports.MantineReactTable = MantineReactTable;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const constants = require("fastapi-rtk/constants");
|
|
4
4
|
const React = require("react");
|
|
5
|
-
const react = require("../../../../../.external/cjs/zustand@5.0.8_@types_react@18.3.
|
|
5
|
+
const react = require("../../../../../.external/cjs/zustand@5.0.8_@types_react@18.3.25_react@18.3.1/zustand/esm/react.cjs");
|
|
6
6
|
const useProvideForm = () => {
|
|
7
7
|
const [storeAdd] = React.useState(
|
|
8
8
|
() => react.create((set, get) => ({
|
|
@@ -5,12 +5,12 @@ const constants = require("fastapi-rtk/constants");
|
|
|
5
5
|
const utils = require("fastapi-rtk/utils");
|
|
6
6
|
const zustand = require("fastapi-rtk/zustand");
|
|
7
7
|
const hooks = require("@mantine/hooks");
|
|
8
|
-
const i18next = require("../../../../../.external/cjs/i18next@25.5.
|
|
8
|
+
const i18next = require("../../../../../.external/cjs/i18next@25.5.3_typescript@5.9.3/i18next/dist/esm/i18next.cjs");
|
|
9
9
|
const React = require("react");
|
|
10
10
|
const de = require("../../../translations/de.cjs");
|
|
11
11
|
const useProvideLang = require("../hooks/useProvideLang.cjs");
|
|
12
|
-
const I18nextProvider = require("../../../../../.external/cjs/react-i18next@15.7.
|
|
13
|
-
const initReactI18next = require("../../../../../.external/cjs/react-i18next@15.7.
|
|
12
|
+
const I18nextProvider = require("../../../../../.external/cjs/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/I18nextProvider.cjs");
|
|
13
|
+
const initReactI18next = require("../../../../../.external/cjs/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/initReactI18next.cjs");
|
|
14
14
|
const getI18n = ({ initProps, callback, translations } = {}) => {
|
|
15
15
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
16
16
|
const i18n = i18next.createInstance();
|
|
@@ -4,7 +4,7 @@ const constants = require("fastapi-rtk/constants");
|
|
|
4
4
|
const utils = require("fastapi-rtk/utils");
|
|
5
5
|
const hooks = require("@mantine/hooks");
|
|
6
6
|
const React = require("react");
|
|
7
|
-
const useTranslation = require("../../../../../.external/cjs/react-i18next@15.7.
|
|
7
|
+
const useTranslation = require("../../../../../.external/cjs/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.cjs");
|
|
8
8
|
const useProvideLang = (baseMRTLocalization = {}) => {
|
|
9
9
|
const translation = useTranslation.useTranslation();
|
|
10
10
|
const [localStorageLanguage, setLocalStorageLanguage] = hooks.useLocalStorage(constants.LANG_LOCAL_STORAGE_PROPS);
|
package/dist/core/cjs/index.cjs
CHANGED
|
@@ -35,7 +35,7 @@ const hooks = require("fastapi-rtk/hooks");
|
|
|
35
35
|
const utils = require("fastapi-rtk/utils");
|
|
36
36
|
const zustand = require("fastapi-rtk/zustand");
|
|
37
37
|
const Filter = require("./Tables/DataGrid/Toolbar/Filter/Filter.cjs");
|
|
38
|
-
const useTranslation = require("../../.external/cjs/react-i18next@15.7.
|
|
38
|
+
const useTranslation = require("../../.external/cjs/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.cjs");
|
|
39
39
|
exports.Actions = Actions.Actions;
|
|
40
40
|
exports.Add = Add.Add;
|
|
41
41
|
exports.Delete = Delete.Delete;
|
|
@@ -4,7 +4,7 @@ import { Tooltip, ActionIcon } from "@mantine/core";
|
|
|
4
4
|
import { memo } from "react";
|
|
5
5
|
import { useForms } from "../../hooks/api/useForms.mjs";
|
|
6
6
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
7
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
7
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
8
8
|
import IconPlus from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconPlus.mjs";
|
|
9
9
|
const Add = memo(({ tooltipProps, ...props }) => {
|
|
10
10
|
const { t } = useTranslation();
|
|
@@ -4,7 +4,7 @@ import { Tooltip, ActionIcon } from "@mantine/core";
|
|
|
4
4
|
import { memo } from "react";
|
|
5
5
|
import { useForms } from "../../hooks/api/useForms.mjs";
|
|
6
6
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
7
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
7
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
8
8
|
import IconTrash from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconTrash.mjs";
|
|
9
9
|
const Delete = memo(({ id, ...props }) => {
|
|
10
10
|
const { t } = useTranslation();
|
|
@@ -6,7 +6,7 @@ import { useDisclosure, useDebouncedState } from "@mantine/hooks";
|
|
|
6
6
|
import { memo, useState } from "react";
|
|
7
7
|
import { useApi } from "../../hooks/api/useApi.mjs";
|
|
8
8
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
9
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
9
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
10
10
|
import IconSeparatorVertical from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconSeparatorVertical.mjs";
|
|
11
11
|
import IconDownload from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconDownload.mjs";
|
|
12
12
|
const Download = memo(({ tooltipProps, ...props }) => {
|
|
@@ -7,7 +7,7 @@ import { memo } from "react";
|
|
|
7
7
|
import { useApi } from "../../hooks/api/useApi.mjs";
|
|
8
8
|
import { useForms } from "../../hooks/api/useForms.mjs";
|
|
9
9
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
10
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
10
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
11
11
|
import IconPencil from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconPencil.mjs";
|
|
12
12
|
const Edit = memo(({ id, ...props }) => {
|
|
13
13
|
const { getEntry } = useApi();
|
|
@@ -4,7 +4,7 @@ import { ThemeIcon, Loader, Tooltip, ActionIcon } from "@mantine/core";
|
|
|
4
4
|
import { memo, useState } from "react";
|
|
5
5
|
import { useApi } from "../../hooks/api/useApi.mjs";
|
|
6
6
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
7
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
7
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
8
8
|
import IconRefresh from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconRefresh.mjs";
|
|
9
9
|
const Refresh = memo(({ tooltipProps, ...props }) => {
|
|
10
10
|
const { t } = useTranslation();
|
|
@@ -7,7 +7,7 @@ import { memo } from "react";
|
|
|
7
7
|
import { useApi } from "../../hooks/api/useApi.mjs";
|
|
8
8
|
import { useForms } from "../../hooks/api/useForms.mjs";
|
|
9
9
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
10
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
10
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
11
11
|
import IconEye from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconEye.mjs";
|
|
12
12
|
const View = memo(({ id, ...props }) => {
|
|
13
13
|
const { getEntry } = useApi();
|
|
@@ -5,7 +5,7 @@ import { deepMerge } from "fastapi-rtk/utils";
|
|
|
5
5
|
import { useProps, Stack } from "@mantine/core";
|
|
6
6
|
import { useForm } from "@mantine/form";
|
|
7
7
|
import { useDebouncedState } from "@mantine/hooks";
|
|
8
|
-
import { yupResolver } from "../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.
|
|
8
|
+
import { yupResolver } from "../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.3_yup@1.7.1/mantine-form-yup-resolver/dist/esm/index.mjs";
|
|
9
9
|
import { useMemo, useCallback, useEffect } from "react";
|
|
10
10
|
import { useApi } from "../hooks/api/useApi.mjs";
|
|
11
11
|
import { useForms } from "../hooks/api/useForms.mjs";
|
|
@@ -15,7 +15,7 @@ import { CommonModal } from "../Modals/CommonModal.mjs";
|
|
|
15
15
|
import { normalProps } from "../Modals/normalProps.mjs";
|
|
16
16
|
import { overlayProps } from "../Modals/overlayProps.mjs";
|
|
17
17
|
import { FormField } from "../Tables/DataGrid/FormField/FormField.mjs";
|
|
18
|
-
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.
|
|
18
|
+
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
19
19
|
function AddDialog({
|
|
20
20
|
jsonForms: __jsonForms,
|
|
21
21
|
onSuccess,
|
|
@@ -8,7 +8,7 @@ import { overlayProps } from "../Modals/overlayProps.mjs";
|
|
|
8
8
|
import { useApi } from "../hooks/api/useApi.mjs";
|
|
9
9
|
import { useForms } from "../hooks/api/useForms.mjs";
|
|
10
10
|
import "../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
11
|
-
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.
|
|
11
|
+
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
12
12
|
const DeleteDialog = ({ deleteText, onSuccess, onError, ...props }) => {
|
|
13
13
|
const { refetch, refetchInfo, deleteEntry } = useApi();
|
|
14
14
|
const { t } = useTranslation();
|
|
@@ -6,7 +6,7 @@ import { useProps, Stack } from "@mantine/core";
|
|
|
6
6
|
import { useForm } from "@mantine/form";
|
|
7
7
|
import { useDebouncedState } from "@mantine/hooks";
|
|
8
8
|
import { l as lodashExports } from "../_virtual/lodash.mjs";
|
|
9
|
-
import { yupResolver } from "../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.
|
|
9
|
+
import { yupResolver } from "../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.3_yup@1.7.1/mantine-form-yup-resolver/dist/esm/index.mjs";
|
|
10
10
|
import { useMemo, useRef, useEffect, useCallback } from "react";
|
|
11
11
|
import { convertToFormInputs as convertToFormInputs$1 } from "../ActionIcons/utils/convertToFormInputs.mjs";
|
|
12
12
|
import { convertToFormInputs } from "../fab-react-toolkit-patch/utils/convertToFormInputs.mjs";
|
|
@@ -18,7 +18,7 @@ import { CommonModal } from "../Modals/CommonModal.mjs";
|
|
|
18
18
|
import { normalProps } from "../Modals/normalProps.mjs";
|
|
19
19
|
import { overlayProps } from "../Modals/overlayProps.mjs";
|
|
20
20
|
import { FormField } from "../Tables/DataGrid/FormField/FormField.mjs";
|
|
21
|
-
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.
|
|
21
|
+
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
22
22
|
function EditDialog({
|
|
23
23
|
jsonForms: __jsonForms,
|
|
24
24
|
onSuccess,
|
|
@@ -5,7 +5,7 @@ import { Icon } from "../../../.external/esm/@iconify_react@6.0.2_react@18.3.1/@
|
|
|
5
5
|
import { Modal, Box, Group, Button, CloseButton } from "@mantine/core";
|
|
6
6
|
import { useInfo } from "../hooks/auth/useInfo.mjs";
|
|
7
7
|
import "../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
8
|
-
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.
|
|
8
|
+
import { useTranslation } from "../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
9
9
|
function CommonModal({
|
|
10
10
|
children,
|
|
11
11
|
view,
|
|
@@ -2,7 +2,7 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { Modal, Text, Group } from "@mantine/core";
|
|
3
3
|
import { useApi } from "../../hooks/api/useApi.mjs";
|
|
4
4
|
import "../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
5
|
-
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.
|
|
5
|
+
import { useTranslation } from "../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
6
6
|
import IconAlertCircle from "../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconAlertCircle.mjs";
|
|
7
7
|
function ErrorDialog() {
|
|
8
8
|
const { error, resetError } = useApi();
|
|
@@ -2,7 +2,7 @@ import { jsxs, jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useProps, Box, Flex, ActionIcon, Divider, Text, ScrollArea, Button, Group } from "@mantine/core";
|
|
3
3
|
import { useForm } from "@mantine/form";
|
|
4
4
|
import { randomId } from "@mantine/hooks";
|
|
5
|
-
import { yupResolver } from "../../../../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.
|
|
5
|
+
import { yupResolver } from "../../../../../../.external/esm/mantine-form-yup-resolver@2.0.0_@mantine_form@8.3.3_yup@1.7.1/mantine-form-yup-resolver/dist/esm/index.mjs";
|
|
6
6
|
import { useEffect } from "react";
|
|
7
7
|
import { object as create$3, array as create$2, mixed as create$8, string as create$6 } from "../../../../../../.external/esm/yup@1.7.1/yup/index.esm.mjs";
|
|
8
8
|
import { useApi } from "../../../../hooks/api/useApi.mjs";
|
|
@@ -3,7 +3,7 @@ import { jsxs, jsx } from "react/jsx-runtime";
|
|
|
3
3
|
/* empty css */
|
|
4
4
|
import { deepMerge, mergeProps, getItemId } from "fastapi-rtk/utils";
|
|
5
5
|
import { useProps, Box } from "@mantine/core";
|
|
6
|
-
import { useMantineReactTable
|
|
6
|
+
import { useMantineReactTable } from "../../../../.external/esm/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.mjs";
|
|
7
7
|
import { forwardRef, useMemo, useEffect } from "react";
|
|
8
8
|
import { AddDialog } from "../../Dialogs/AddDialog.mjs";
|
|
9
9
|
import { DeleteDialog } from "../../Dialogs/DeleteDialog.mjs";
|
|
@@ -26,6 +26,7 @@ import { useSize } from "./hooks/useSize.mjs";
|
|
|
26
26
|
import { useSorting } from "./hooks/useSorting.mjs";
|
|
27
27
|
import { useToolbar } from "./hooks/useToolbar/useToolbar.mjs";
|
|
28
28
|
import { useToolbarAlertBanner } from "./hooks/useToolbarAlertBanner/useToolbarAlertBanner.mjs";
|
|
29
|
+
import { MantineReactTable } from "./patch/MantineReactTable.mjs";
|
|
29
30
|
const baseProps = { enableStickyHeader: true, enableColumnPinning: true };
|
|
30
31
|
const NextGenDataGrid = forwardRef((props, ref) => {
|
|
31
32
|
var _a, _b, _c, _d, _e;
|
|
@@ -11,7 +11,7 @@ import { useApi } from "../../../../../hooks/api/useApi.mjs";
|
|
|
11
11
|
import "../../../../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
12
12
|
import { getBasicInput } from "../utils.mjs";
|
|
13
13
|
import { HeaderInput } from "./HeaderInput.mjs";
|
|
14
|
-
import { useTranslation } from "../../../../../../../.external/esm/react-i18next@15.7.
|
|
14
|
+
import { useTranslation } from "../../../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
15
15
|
const getLocalStorageValue = (key, defaultValue) => {
|
|
16
16
|
const value = localStorage.getItem(key);
|
|
17
17
|
if (value === null) {
|
|
@@ -2,7 +2,7 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { ActionIcon, Group, NumberInput } from "@mantine/core";
|
|
3
3
|
import { forwardRef, useState, useEffect, useCallback } from "react";
|
|
4
4
|
import "../../../../../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
5
|
-
import { useTranslation } from "../../../../../../../../.external/esm/react-i18next@15.7.
|
|
5
|
+
import { useTranslation } from "../../../../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
6
6
|
import IconX from "../../../../../../../../.external/esm/@tabler_icons-react@3.18.0_react@18.3.1/@tabler/icons-react/dist/esm/icons/IconX.mjs";
|
|
7
7
|
const criteria = (v) => v !== void 0 && v !== null && v !== "";
|
|
8
8
|
const HeaderBetweenInput = forwardRef(({ clearIcon: _, mrtprops: { textinputprops }, ...props }, ref) => {
|
package/dist/core/esm/Tables/NextGenDataGrid/hooks/useColumns/HeaderAdvancedFiltersMenuButton.mjs
CHANGED
|
@@ -6,7 +6,7 @@ import { useAuth } from "../../../../hooks/auth/useAuth.mjs";
|
|
|
6
6
|
import "../../../../Wrappers/Provider/Contexts/LangContext.mjs";
|
|
7
7
|
import { AdvancedFilters } from "./AdvancedFilters.mjs";
|
|
8
8
|
import { FilterMenuButton } from "./FilterMenuButton.mjs";
|
|
9
|
-
import { useTranslation } from "../../../../../../.external/esm/react-i18next@15.7.
|
|
9
|
+
import { useTranslation } from "../../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
10
10
|
const HeaderAdvancedFiltersMenuButton = ({ filters, mrtProps }) => {
|
|
11
11
|
const { t } = useTranslation();
|
|
12
12
|
const { table, column } = mrtProps;
|
|
@@ -15,7 +15,8 @@ function useSize(withBorder) {
|
|
|
15
15
|
() => ({ ref: bottomToolbarRef, pos: "sticky", bottom: 0 }),
|
|
16
16
|
[bottomToolbarRef]
|
|
17
17
|
);
|
|
18
|
-
const mantineTableContainerProps = useMemo(
|
|
18
|
+
const mantineTableContainerProps = useMemo(() => ({ h: "100%" }), []);
|
|
19
|
+
const mantineTableContainerWrapperProps = useMemo(
|
|
19
20
|
() => ({
|
|
20
21
|
h: `calc(100% - ${topToolbarHeight + bottomToolbarHeight}px)`
|
|
21
22
|
}),
|
|
@@ -25,7 +26,8 @@ function useSize(withBorder) {
|
|
|
25
26
|
mantinePaperProps,
|
|
26
27
|
mantineTopToolbarProps,
|
|
27
28
|
mantineBottomToolbarProps,
|
|
28
|
-
mantineTableContainerProps
|
|
29
|
+
mantineTableContainerProps,
|
|
30
|
+
mantineTableContainerWrapperProps
|
|
29
31
|
};
|
|
30
32
|
}
|
|
31
33
|
export {
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { parseFromValuesOrFunc } from "fastapi-rtk/utils";
|
|
3
|
+
import { Box, LoadingOverlay } from "@mantine/core";
|
|
4
|
+
import { clsx } from "../../../../../.external/esm/clsx@2.1.1/clsx/dist/clsx.mjs";
|
|
5
|
+
import { MRT_Table, MRT_EditRowModal } from "../../../../../.external/esm/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.mjs";
|
|
6
|
+
import { useState, useLayoutEffect, useEffect } from "react";
|
|
7
|
+
import classes from "./MRT_TableContainer.module.css.mjs";
|
|
8
|
+
const useIsomorphicLayoutEffect = typeof window !== "undefined" ? useLayoutEffect : useEffect;
|
|
9
|
+
const MRT_TableContainer = ({ table, ...rest }) => {
|
|
10
|
+
const {
|
|
11
|
+
getState,
|
|
12
|
+
options: {
|
|
13
|
+
createDisplayMode,
|
|
14
|
+
editDisplayMode,
|
|
15
|
+
enableStickyHeader,
|
|
16
|
+
mantineLoadingOverlayProps,
|
|
17
|
+
mantineTableContainerProps,
|
|
18
|
+
mantineTableContainerWrapperProps
|
|
19
|
+
},
|
|
20
|
+
refs: { bottomToolbarRef, tableContainerRef, topToolbarRef }
|
|
21
|
+
} = table;
|
|
22
|
+
const { creatingRow, editingRow, isFullScreen, isLoading, showLoadingOverlay } = getState();
|
|
23
|
+
const [totalToolbarHeight, setTotalToolbarHeight] = useState(0);
|
|
24
|
+
const tableContainerProps = {
|
|
25
|
+
...parseFromValuesOrFunc(mantineTableContainerProps, { table }),
|
|
26
|
+
...rest
|
|
27
|
+
};
|
|
28
|
+
const loadingOverlayProps = parseFromValuesOrFunc(mantineLoadingOverlayProps, { table });
|
|
29
|
+
useIsomorphicLayoutEffect(() => {
|
|
30
|
+
var _a, _b;
|
|
31
|
+
const topToolbarHeight = typeof document !== "undefined" ? ((_a = topToolbarRef.current) == null ? void 0 : _a.offsetHeight) ?? 0 : 0;
|
|
32
|
+
const bottomToolbarHeight = typeof document !== "undefined" ? ((_b = bottomToolbarRef == null ? void 0 : bottomToolbarRef.current) == null ? void 0 : _b.offsetHeight) ?? 0 : 0;
|
|
33
|
+
setTotalToolbarHeight(topToolbarHeight + bottomToolbarHeight);
|
|
34
|
+
});
|
|
35
|
+
const createModalOpen = createDisplayMode === "modal" && creatingRow;
|
|
36
|
+
const editModalOpen = editDisplayMode === "modal" && editingRow;
|
|
37
|
+
const tableContainerWrapperProps = parseFromValuesOrFunc(mantineTableContainerWrapperProps, { table });
|
|
38
|
+
return /* @__PURE__ */ jsxs(
|
|
39
|
+
Box,
|
|
40
|
+
{
|
|
41
|
+
pos: "relative",
|
|
42
|
+
...tableContainerWrapperProps,
|
|
43
|
+
className: clsx("mrt-table-container-wrapper", tableContainerWrapperProps == null ? void 0 : tableContainerWrapperProps.className),
|
|
44
|
+
children: [
|
|
45
|
+
/* @__PURE__ */ jsx(LoadingOverlay, { visible: isLoading || showLoadingOverlay, zIndex: 2, ...loadingOverlayProps }),
|
|
46
|
+
/* @__PURE__ */ jsxs(
|
|
47
|
+
Box,
|
|
48
|
+
{
|
|
49
|
+
...tableContainerProps,
|
|
50
|
+
__vars: {
|
|
51
|
+
"--mrt-top-toolbar-height": `${totalToolbarHeight}`,
|
|
52
|
+
...tableContainerProps == null ? void 0 : tableContainerProps.__vars
|
|
53
|
+
},
|
|
54
|
+
className: clsx(
|
|
55
|
+
"mrt-table-container",
|
|
56
|
+
classes.root,
|
|
57
|
+
enableStickyHeader && classes["root-sticky"],
|
|
58
|
+
isFullScreen && classes["root-fullscreen"],
|
|
59
|
+
tableContainerProps == null ? void 0 : tableContainerProps.className
|
|
60
|
+
),
|
|
61
|
+
ref: (node) => {
|
|
62
|
+
if (node) {
|
|
63
|
+
tableContainerRef.current = node;
|
|
64
|
+
if (tableContainerProps == null ? void 0 : tableContainerProps.ref) {
|
|
65
|
+
tableContainerProps.ref.current = node;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
children: [
|
|
70
|
+
/* @__PURE__ */ jsx(MRT_Table, { table }),
|
|
71
|
+
(createModalOpen || editModalOpen) && /* @__PURE__ */ jsx(MRT_EditRowModal, { open: true, table })
|
|
72
|
+
]
|
|
73
|
+
}
|
|
74
|
+
)
|
|
75
|
+
]
|
|
76
|
+
}
|
|
77
|
+
);
|
|
78
|
+
};
|
|
79
|
+
export {
|
|
80
|
+
MRT_TableContainer
|
|
81
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { parseFromValuesOrFunc } from "fastapi-rtk/utils";
|
|
3
|
+
import { Paper } from "@mantine/core";
|
|
4
|
+
import { clsx } from "../../../../../.external/esm/clsx@2.1.1/clsx/dist/clsx.mjs";
|
|
5
|
+
import { MRT_TopToolbar, MRT_BottomToolbar } from "../../../../../.external/esm/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.mjs";
|
|
6
|
+
import { MRT_TableContainer } from "./MRT_TableContainer.mjs";
|
|
7
|
+
import classes from "./MRT_TablePaper.module.css.mjs";
|
|
8
|
+
const MRT_TablePaper = ({ table, ...rest }) => {
|
|
9
|
+
const {
|
|
10
|
+
getState,
|
|
11
|
+
options: { enableBottomToolbar, enableTopToolbar, mantinePaperProps, renderBottomToolbar, renderTopToolbar },
|
|
12
|
+
refs: { tablePaperRef }
|
|
13
|
+
} = table;
|
|
14
|
+
const { isFullScreen } = getState();
|
|
15
|
+
const tablePaperProps = {
|
|
16
|
+
...parseFromValuesOrFunc(mantinePaperProps, { table }),
|
|
17
|
+
...rest
|
|
18
|
+
};
|
|
19
|
+
return /* @__PURE__ */ jsxs(
|
|
20
|
+
Paper,
|
|
21
|
+
{
|
|
22
|
+
shadow: "xs",
|
|
23
|
+
withBorder: true,
|
|
24
|
+
...tablePaperProps,
|
|
25
|
+
className: clsx(
|
|
26
|
+
"mrt-table-paper",
|
|
27
|
+
classes.root,
|
|
28
|
+
isFullScreen && "mrt-table-paper-fullscreen",
|
|
29
|
+
tablePaperProps == null ? void 0 : tablePaperProps.className
|
|
30
|
+
),
|
|
31
|
+
ref: (ref) => {
|
|
32
|
+
tablePaperRef.current = ref;
|
|
33
|
+
if (tablePaperProps == null ? void 0 : tablePaperProps.ref) {
|
|
34
|
+
tablePaperProps.ref.current = ref;
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
style: (theme) => ({
|
|
38
|
+
zIndex: isFullScreen ? 200 : void 0,
|
|
39
|
+
...parseFromValuesOrFunc(tablePaperProps == null ? void 0 : tablePaperProps.style, theme),
|
|
40
|
+
...isFullScreen ? {
|
|
41
|
+
border: 0,
|
|
42
|
+
borderRadius: 0,
|
|
43
|
+
bottom: 0,
|
|
44
|
+
height: "100vh",
|
|
45
|
+
left: 0,
|
|
46
|
+
margin: 0,
|
|
47
|
+
maxHeight: "100vh",
|
|
48
|
+
maxWidth: "100vw",
|
|
49
|
+
padding: 0,
|
|
50
|
+
position: "fixed",
|
|
51
|
+
right: 0,
|
|
52
|
+
top: 0,
|
|
53
|
+
width: "100vw"
|
|
54
|
+
} : null
|
|
55
|
+
}),
|
|
56
|
+
children: [
|
|
57
|
+
enableTopToolbar && (parseFromValuesOrFunc(renderTopToolbar, { table }) ?? /* @__PURE__ */ jsx(MRT_TopToolbar, { table })),
|
|
58
|
+
/* @__PURE__ */ jsx(MRT_TableContainer, { table }),
|
|
59
|
+
enableBottomToolbar && (parseFromValuesOrFunc(renderBottomToolbar, { table }) ?? /* @__PURE__ */ jsx(MRT_BottomToolbar, { table }))
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
);
|
|
63
|
+
};
|
|
64
|
+
export {
|
|
65
|
+
MRT_TablePaper
|
|
66
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMantineReactTable } from "../../../../../.external/esm/mantine-react-table@2.0.0-beta.9_@mantine_core@7.17.8_@mantine_dates@7.17.8_@mantine_hooks@7._v6brefjjgmgbqbolvm3v6bkbsa/mantine-react-table/dist/index.esm.mjs";
|
|
3
|
+
import { MRT_TablePaper } from "./MRT_TablePaper.mjs";
|
|
4
|
+
const isTableInstanceProp = (props) => props.table !== void 0;
|
|
5
|
+
const MantineReactTable = (props) => {
|
|
6
|
+
let table;
|
|
7
|
+
if (isTableInstanceProp(props)) {
|
|
8
|
+
table = props.table;
|
|
9
|
+
} else {
|
|
10
|
+
table = useMantineReactTable(props);
|
|
11
|
+
}
|
|
12
|
+
return /* @__PURE__ */ jsx(MRT_TablePaper, { table });
|
|
13
|
+
};
|
|
14
|
+
export {
|
|
15
|
+
MantineReactTable
|
|
16
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { initialState, VIEW_MODE } from "fastapi-rtk/constants";
|
|
2
2
|
import { useState } from "react";
|
|
3
|
-
import { create } from "../../../../../.external/esm/zustand@5.0.8_@types_react@18.3.
|
|
3
|
+
import { create } from "../../../../../.external/esm/zustand@5.0.8_@types_react@18.3.25_react@18.3.1/zustand/esm/react.mjs";
|
|
4
4
|
const useProvideForm = () => {
|
|
5
5
|
const [storeAdd] = useState(
|
|
6
6
|
() => create((set, get) => ({
|
|
@@ -3,12 +3,12 @@ import { LANG_LOCAL_STORAGE_PROPS } from "fastapi-rtk/constants";
|
|
|
3
3
|
import { createSafeContext, parseFromValuesOrFunc } from "fastapi-rtk/utils";
|
|
4
4
|
import { useProxy } from "fastapi-rtk/zustand";
|
|
5
5
|
import { useLocalStorage } from "@mantine/hooks";
|
|
6
|
-
import { createInstance } from "../../../../../.external/esm/i18next@25.5.
|
|
6
|
+
import { createInstance } from "../../../../../.external/esm/i18next@25.5.3_typescript@5.9.3/i18next/dist/esm/i18next.mjs";
|
|
7
7
|
import { useRef, useMemo, useEffect } from "react";
|
|
8
8
|
import de from "../../../translations/de.mjs";
|
|
9
9
|
import { useProvideLang } from "../hooks/useProvideLang.mjs";
|
|
10
|
-
import { I18nextProvider } from "../../../../../.external/esm/react-i18next@15.7.
|
|
11
|
-
import { initReactI18next } from "../../../../../.external/esm/react-i18next@15.7.
|
|
10
|
+
import { I18nextProvider } from "../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/I18nextProvider.mjs";
|
|
11
|
+
import { initReactI18next } from "../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/initReactI18next.mjs";
|
|
12
12
|
const getI18n = ({ initProps, callback, translations } = {}) => {
|
|
13
13
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
14
14
|
const i18n = createInstance();
|
|
@@ -2,7 +2,7 @@ import { LANG_LOCAL_STORAGE_PROPS, MRT_LOCALIZATION_IMPORT_MAP } from "fastapi-r
|
|
|
2
2
|
import { FastAPIRTKLogger } from "fastapi-rtk/utils";
|
|
3
3
|
import { useLocalStorage, useSetState } from "@mantine/hooks";
|
|
4
4
|
import { useCallback, useEffect } from "react";
|
|
5
|
-
import { useTranslation } from "../../../../../.external/esm/react-i18next@15.7.
|
|
5
|
+
import { useTranslation } from "../../../../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
6
6
|
const useProvideLang = (baseMRTLocalization = {}) => {
|
|
7
7
|
const translation = useTranslation();
|
|
8
8
|
const [localStorageLanguage, setLocalStorageLanguage] = useLocalStorage(LANG_LOCAL_STORAGE_PROPS);
|
package/dist/core/esm/index.mjs
CHANGED
|
@@ -33,7 +33,7 @@ export * from "fastapi-rtk/hooks";
|
|
|
33
33
|
export * from "fastapi-rtk/utils";
|
|
34
34
|
export * from "fastapi-rtk/zustand";
|
|
35
35
|
import { Filter } from "./Tables/DataGrid/Toolbar/Filter/Filter.mjs";
|
|
36
|
-
import { useTranslation } from "../../.external/esm/react-i18next@15.7.
|
|
36
|
+
import { useTranslation } from "../../.external/esm/react-i18next@15.7.4_i18next@25.5.3_react-dom@18.3.1_react@18.3.1_typescript@5.9.3/react-i18next/dist/es/useTranslation.mjs";
|
|
37
37
|
export {
|
|
38
38
|
Actions,
|
|
39
39
|
Add,
|