wcz-test 2.8.0 → 2.10.0

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/index.js CHANGED
@@ -1038,9 +1038,32 @@ var TypographyWithIcon = ({ startIcon, endIcon, children, sx, gutterBottom, ...p
1038
1038
  ] });
1039
1039
  };
1040
1040
 
1041
+ // src/index.ts
1042
+ import { PageHeader } from "@toolpad/core/PageContainer";
1043
+
1044
+ // src/components/core/PageContainer.tsx
1045
+ import { Container } from "@mui/material";
1046
+ import { jsx as jsx2 } from "react/jsx-runtime";
1047
+ var PageContainer = (props) => {
1048
+ return /* @__PURE__ */ jsx2(
1049
+ Container,
1050
+ {
1051
+ sx: {
1052
+ display: "flex",
1053
+ flexDirection: "column",
1054
+ height: "100vh",
1055
+ my: 1,
1056
+ ...props.sx
1057
+ },
1058
+ ...props,
1059
+ children: props.children
1060
+ }
1061
+ );
1062
+ };
1063
+
1041
1064
  // src/components/data-grid/ChipInputCell.tsx
1042
1065
  import { Chip, Stack as Stack2 } from "@mui/material";
1043
- import { jsx as jsx2 } from "react/jsx-runtime";
1066
+ import { jsx as jsx3 } from "react/jsx-runtime";
1044
1067
  var isArray = (value) => Array.isArray(value);
1045
1068
  var ChipInputCell = ({ params, slotProps, getLabel }) => {
1046
1069
  if (!params.value) return null;
@@ -1049,103 +1072,100 @@ var ChipInputCell = ({ params, slotProps, getLabel }) => {
1049
1072
  return value;
1050
1073
  };
1051
1074
  if (isArray(params.value))
1052
- return /* @__PURE__ */ jsx2(Stack2, { direction: "row", alignItems: "center", gap: 1, sx: { overflowX: "auto", height: "100%", width: params.colDef.computedWidth }, children: params.value.map(
1053
- (value, index) => /* @__PURE__ */ jsx2(Chip, { label: getLabelValue(value), ...slotProps }, `${index + 1}-chip-input-cell`)
1075
+ return /* @__PURE__ */ jsx3(Stack2, { direction: "row", alignItems: "center", gap: 1, sx: { overflowX: "auto", height: "100%", width: params.colDef.computedWidth }, children: params.value.map(
1076
+ (value, index) => /* @__PURE__ */ jsx3(Chip, { label: getLabelValue(value), ...slotProps }, `${index + 1}-chip-input-cell`)
1054
1077
  ) });
1055
- return /* @__PURE__ */ jsx2(Chip, { label: getLabelValue(params.value), ...slotProps });
1078
+ return /* @__PURE__ */ jsx3(Chip, { label: getLabelValue(params.value), ...slotProps });
1056
1079
  };
1057
1080
 
1058
1081
  // src/components/data-grid/EditableColumnHeader.tsx
1059
1082
  import { Edit } from "@mui/icons-material";
1060
- import { jsx as jsx3 } from "react/jsx-runtime";
1083
+ import { jsx as jsx4 } from "react/jsx-runtime";
1061
1084
  var EditableColumnHeader = ({ colDef }) => {
1062
- return /* @__PURE__ */ jsx3(TypographyWithIcon, { endIcon: /* @__PURE__ */ jsx3(Edit, { color: "disabled", fontSize: "small" }), variant: "body2", className: "MuiDataGrid-columnHeaderTitle", children: colDef.headerName });
1085
+ return /* @__PURE__ */ jsx4(TypographyWithIcon, { endIcon: /* @__PURE__ */ jsx4(Edit, { color: "disabled", fontSize: "small" }), variant: "body2", className: "MuiDataGrid-columnHeaderTitle", children: colDef.headerName });
1063
1086
  };
1064
1087
 
1065
1088
  // src/components/router/RouterButton.tsx
1066
1089
  import { Button } from "@mui/material";
1067
1090
  import { createLink } from "@tanstack/react-router";
1068
1091
  import React from "react";
1069
- import { jsx as jsx4 } from "react/jsx-runtime";
1070
- var Component = React.forwardRef((props, ref) => /* @__PURE__ */ jsx4(Button, { ref, component: "a", ...props }));
1092
+ import { jsx as jsx5 } from "react/jsx-runtime";
1093
+ var Component = React.forwardRef((props, ref) => /* @__PURE__ */ jsx5(Button, { ref, component: "a", ...props }));
1071
1094
  var CreatedComponent = createLink(Component);
1072
1095
  var RouterButton = (props) => {
1073
- return /* @__PURE__ */ jsx4(CreatedComponent, { preload: "intent", ...props });
1096
+ return /* @__PURE__ */ jsx5(CreatedComponent, { preload: "intent", ...props });
1074
1097
  };
1075
1098
 
1076
1099
  // src/components/router/RouterGridActionsCellItem.tsx
1077
1100
  import { GridActionsCellItem } from "@mui/x-data-grid-premium";
1078
1101
  import { createLink as createLink2 } from "@tanstack/react-router";
1079
1102
  import React2 from "react";
1080
- import { jsx as jsx5 } from "react/jsx-runtime";
1103
+ import { jsx as jsx6 } from "react/jsx-runtime";
1081
1104
  var Component2 = React2.forwardRef(
1082
- (props, ref) => /* @__PURE__ */ jsx5(GridActionsCellItem, { ref, component: "a", ...props })
1105
+ (props, ref) => /* @__PURE__ */ jsx6(GridActionsCellItem, { ref, component: "a", ...props })
1083
1106
  );
1084
1107
  var CreatedComponent2 = createLink2(Component2);
1085
1108
  var RouterGridActionsCellItem = (props) => {
1086
- return /* @__PURE__ */ jsx5(CreatedComponent2, { preload: "intent", ...props });
1109
+ return /* @__PURE__ */ jsx6(CreatedComponent2, { preload: "intent", ...props });
1087
1110
  };
1088
1111
 
1089
1112
  // src/components/router/RouterIconButton.tsx
1090
1113
  import { IconButton } from "@mui/material";
1091
1114
  import { createLink as createLink3 } from "@tanstack/react-router";
1092
1115
  import React3 from "react";
1093
- import { jsx as jsx6 } from "react/jsx-runtime";
1094
- var Component3 = React3.forwardRef((props, ref) => /* @__PURE__ */ jsx6(IconButton, { ref, component: "a", ...props }));
1116
+ import { jsx as jsx7 } from "react/jsx-runtime";
1117
+ var Component3 = React3.forwardRef((props, ref) => /* @__PURE__ */ jsx7(IconButton, { ref, component: "a", ...props }));
1095
1118
  var CreatedComponent3 = createLink3(Component3);
1096
1119
  var RouterIconButton = (props) => {
1097
- return /* @__PURE__ */ jsx6(CreatedComponent3, { preload: "intent", ...props });
1120
+ return /* @__PURE__ */ jsx7(CreatedComponent3, { preload: "intent", ...props });
1098
1121
  };
1099
1122
 
1100
1123
  // src/components/router/RouterLink.tsx
1101
1124
  import { Link } from "@mui/material";
1102
1125
  import { createLink as createLink4 } from "@tanstack/react-router";
1103
1126
  import React4 from "react";
1104
- import { jsx as jsx7 } from "react/jsx-runtime";
1105
- var Component4 = React4.forwardRef((props, ref) => /* @__PURE__ */ jsx7(Link, { ref, ...props }));
1127
+ import { jsx as jsx8 } from "react/jsx-runtime";
1128
+ var Component4 = React4.forwardRef((props, ref) => /* @__PURE__ */ jsx8(Link, { ref, ...props }));
1106
1129
  var CreatedComponent4 = createLink4(Component4);
1107
1130
  var RouterLink = (props) => {
1108
- return /* @__PURE__ */ jsx7(CreatedComponent4, { preload: "intent", ...props });
1131
+ return /* @__PURE__ */ jsx8(CreatedComponent4, { preload: "intent", ...props });
1109
1132
  };
1110
1133
 
1111
1134
  // src/components/router/RouterTab.tsx
1112
1135
  import { Tab } from "@mui/material";
1113
1136
  import { createLink as createLink5 } from "@tanstack/react-router";
1114
1137
  import React5 from "react";
1115
- import { jsx as jsx8 } from "react/jsx-runtime";
1116
- var Component5 = React5.forwardRef((props, ref) => /* @__PURE__ */ jsx8(Tab, { ref, component: "a", ...props }));
1138
+ import { jsx as jsx9 } from "react/jsx-runtime";
1139
+ var Component5 = React5.forwardRef((props, ref) => /* @__PURE__ */ jsx9(Tab, { ref, component: "a", ...props }));
1117
1140
  var CreatedComponent5 = createLink5(Component5);
1118
1141
  var RouterTab = (props) => {
1119
- return /* @__PURE__ */ jsx8(CreatedComponent5, { preload: "intent", ...props });
1142
+ return /* @__PURE__ */ jsx9(CreatedComponent5, { preload: "intent", ...props });
1120
1143
  };
1121
1144
 
1122
1145
  // src/components/router/RouterNotFound.tsx
1123
1146
  import { Box, Divider, Typography as Typography2 } from "@mui/material";
1124
1147
  import { useTranslation } from "react-i18next";
1125
- import { jsx as jsx9, jsxs as jsxs2 } from "react/jsx-runtime";
1148
+ import { jsx as jsx10, jsxs as jsxs2 } from "react/jsx-runtime";
1126
1149
  function RouterNotFound() {
1127
1150
  const { t } = useTranslation();
1128
- return /* @__PURE__ */ jsx9(Box, { height: "100vh", display: "flex", flexDirection: "column", alignItems: "center", justifyContent: "center", textAlign: "center", px: 2, children: /* @__PURE__ */ jsxs2(Box, { display: "flex", alignItems: "center", mb: 4, children: [
1129
- /* @__PURE__ */ jsx9(Typography2, { variant: "h3", component: "span", fontWeight: 500, sx: { lineHeight: 1 }, children: "404" }),
1130
- /* @__PURE__ */ jsx9(Divider, { orientation: "vertical", flexItem: true, sx: { mx: 3 } }),
1131
- /* @__PURE__ */ jsx9(Typography2, { variant: "h5", component: "span", children: t("Layout.ThisPageCouldNotBeFound") })
1151
+ return /* @__PURE__ */ jsx10(Box, { height: "100vh", display: "flex", flexDirection: "column", alignItems: "center", justifyContent: "center", textAlign: "center", px: 2, children: /* @__PURE__ */ jsxs2(Box, { display: "flex", alignItems: "center", mb: 4, children: [
1152
+ /* @__PURE__ */ jsx10(Typography2, { variant: "h3", component: "span", fontWeight: 500, sx: { lineHeight: 1 }, children: "404" }),
1153
+ /* @__PURE__ */ jsx10(Divider, { orientation: "vertical", flexItem: true, sx: { mx: 3 } }),
1154
+ /* @__PURE__ */ jsx10(Typography2, { variant: "h5", component: "span", children: t("Layout.ThisPageCouldNotBeFound") })
1132
1155
  ] }) });
1133
1156
  }
1134
1157
 
1135
1158
  // src/components/router/RouterError.tsx
1136
1159
  import { Box as Box2, Divider as Divider2, Typography as Typography3 } from "@mui/material";
1137
- import { jsx as jsx10, jsxs as jsxs3 } from "react/jsx-runtime";
1160
+ import { jsx as jsx11, jsxs as jsxs3 } from "react/jsx-runtime";
1138
1161
  var RouterError = ({ error }) => {
1139
- return /* @__PURE__ */ jsx10(Box2, { height: "100vh", display: "flex", flexDirection: "column", alignItems: "center", justifyContent: "center", textAlign: "center", px: 2, children: /* @__PURE__ */ jsxs3(Box2, { display: "flex", alignItems: "center", mb: 4, children: [
1140
- /* @__PURE__ */ jsx10(Typography3, { variant: "h3", component: "span", fontWeight: 500, sx: { lineHeight: 1 }, children: "500" }),
1141
- /* @__PURE__ */ jsx10(Divider2, { orientation: "vertical", flexItem: true, sx: { mx: 3 } }),
1142
- /* @__PURE__ */ jsx10(Typography3, { variant: "h5", component: "span", children: error.message })
1162
+ return /* @__PURE__ */ jsx11(Box2, { height: "100vh", display: "flex", flexDirection: "column", alignItems: "center", justifyContent: "center", textAlign: "center", px: 2, children: /* @__PURE__ */ jsxs3(Box2, { display: "flex", alignItems: "center", mb: 4, children: [
1163
+ /* @__PURE__ */ jsx11(Typography3, { variant: "h3", component: "span", fontWeight: 500, sx: { lineHeight: 1 }, children: "500" }),
1164
+ /* @__PURE__ */ jsx11(Divider2, { orientation: "vertical", flexItem: true, sx: { mx: 3 } }),
1165
+ /* @__PURE__ */ jsx11(Typography3, { variant: "h5", component: "span", children: error.message })
1143
1166
  ] }) });
1144
1167
  };
1145
1168
 
1146
- // src/index.ts
1147
- import { PageContainer, PageHeader } from "@toolpad/core/PageContainer";
1148
-
1149
1169
  // src/providers/LayoutProvider.tsx
1150
1170
  import { LinearProgress, useMediaQuery } from "@mui/material";
1151
1171
 
@@ -1178,9 +1198,7 @@ import { useThemeProps } from "@mui/material/styles";
1178
1198
  import { jsx as _jsx } from "react/jsx-runtime";
1179
1199
  var _excluded = ["localeText"];
1180
1200
  var MuiPickersAdapterContext = /* @__PURE__ */ React6.createContext(null);
1181
- if (process.env.NODE_ENV !== "production") {
1182
- MuiPickersAdapterContext.displayName = "MuiPickersAdapterContext";
1183
- }
1201
+ if (process.env.NODE_ENV !== "production") MuiPickersAdapterContext.displayName = "MuiPickersAdapterContext";
1184
1202
  var LocalizationProvider = function LocalizationProvider2(inProps) {
1185
1203
  const {
1186
1204
  localeText: inLocaleText
@@ -1246,6 +1264,7 @@ var LocalizationProvider = function LocalizationProvider2(inProps) {
1246
1264
  children
1247
1265
  });
1248
1266
  };
1267
+ if (process.env.NODE_ENV !== "production") LocalizationProvider.displayName = "LocalizationProvider";
1249
1268
  process.env.NODE_ENV !== "production" ? LocalizationProvider.propTypes = {
1250
1269
  // ----------------------------- Warning --------------------------------
1251
1270
  // | These PropTypes are generated from the TypeScript type definitions |
@@ -1826,12 +1845,12 @@ var LayoutContext = createContext2({});
1826
1845
  var useLayout = () => useContext2(LayoutContext);
1827
1846
 
1828
1847
  // src/components/core/AppTitle.tsx
1829
- import { jsx as jsx11, jsxs as jsxs4 } from "react/jsx-runtime";
1848
+ import { jsx as jsx12, jsxs as jsxs4 } from "react/jsx-runtime";
1830
1849
  var AppTitle = () => {
1831
1850
  const { appTitle } = useLayout();
1832
1851
  return /* @__PURE__ */ jsxs4(Stack3, { direction: "row", alignItems: "center", spacing: 2, children: [
1833
- /* @__PURE__ */ jsx11("img", { src: "/favicon-32x32.png", alt: "app-logo", loading: "lazy" }),
1834
- /* @__PURE__ */ jsx11(Typography4, { variant: "h6", children: appTitle })
1852
+ /* @__PURE__ */ jsx12("img", { src: "/favicon-32x32.png", alt: "app-logo", loading: "lazy" }),
1853
+ /* @__PURE__ */ jsx12(Typography4, { variant: "h6", children: appTitle })
1835
1854
  ] });
1836
1855
  };
1837
1856
 
@@ -1840,12 +1859,12 @@ import { Close } from "@mui/icons-material";
1840
1859
  import { Fade, Grid, IconButton as IconButton2, Paper, Typography as Typography5 } from "@mui/material";
1841
1860
  import { useState } from "react";
1842
1861
  import { useTranslation as useTranslation2 } from "react-i18next";
1843
- import { jsx as jsx12, jsxs as jsxs5 } from "react/jsx-runtime";
1862
+ import { jsx as jsx13, jsxs as jsxs5 } from "react/jsx-runtime";
1844
1863
  var DevelopmentBanner = ({ hasNavigationRoutes }) => {
1845
1864
  const { t } = useTranslation2();
1846
1865
  const [bannerOpen, setBannerOpen] = useState(true);
1847
1866
  const closeBanner = () => setBannerOpen(false);
1848
- return /* @__PURE__ */ jsx12(Fade, { appear: false, in: bannerOpen, children: /* @__PURE__ */ jsx12(Paper, { square: true, elevation: 3, tabIndex: -1, sx: {
1867
+ return /* @__PURE__ */ jsx13(Fade, { appear: false, in: bannerOpen, children: /* @__PURE__ */ jsx13(Paper, { square: true, elevation: 3, tabIndex: -1, sx: {
1849
1868
  position: "fixed",
1850
1869
  bottom: 0,
1851
1870
  left: { xs: 0, sm: hasNavigationRoutes ? 83.3 : 0 },
@@ -1856,10 +1875,10 @@ var DevelopmentBanner = ({ hasNavigationRoutes }) => {
1856
1875
  borderTopWidth: 1
1857
1876
  }, children: /* @__PURE__ */ jsxs5(Grid, { container: true, justifyContent: "space-between", alignItems: "center", children: [
1858
1877
  /* @__PURE__ */ jsxs5(Grid, { size: 10, children: [
1859
- /* @__PURE__ */ jsx12(Typography5, { fontWeight: "bold", children: t("Layout.DevelopmentDialogTitle") }),
1860
- /* @__PURE__ */ jsx12(Typography5, { variant: "body2", children: t("Layout.DevelopmentDialogContent") })
1878
+ /* @__PURE__ */ jsx13(Typography5, { fontWeight: "bold", children: t("Layout.DevelopmentDialogTitle") }),
1879
+ /* @__PURE__ */ jsx13(Typography5, { variant: "body2", children: t("Layout.DevelopmentDialogContent") })
1861
1880
  ] }),
1862
- /* @__PURE__ */ jsx12(Grid, { size: 2, sx: { p: 1, textAlign: "right" }, children: /* @__PURE__ */ jsx12(IconButton2, { size: "small", onClick: closeBanner, children: /* @__PURE__ */ jsx12(Close, {}) }) })
1881
+ /* @__PURE__ */ jsx13(Grid, { size: 2, sx: { p: 1, textAlign: "right" }, children: /* @__PURE__ */ jsx13(IconButton2, { size: "small", onClick: closeBanner, children: /* @__PURE__ */ jsx13(Close, {}) }) })
1863
1882
  ] }) }) });
1864
1883
  };
1865
1884
 
@@ -1868,7 +1887,7 @@ import { AccountCircle, ArrowBack, Brightness4, ChevronRight, DarkMode, LightMod
1868
1887
  import { Avatar, Box as Box3, IconButton as IconButton3, List, ListItem, ListItemButton, ListItemIcon, ListItemText, ListSubheader, Menu, Typography as Typography6, useColorScheme } from "@mui/material";
1869
1888
  import { Fragment, useState as useState2 } from "react";
1870
1889
  import { useTranslation as useTranslation3 } from "react-i18next";
1871
- import { jsx as jsx13, jsxs as jsxs6 } from "react/jsx-runtime";
1890
+ import { jsx as jsx14, jsxs as jsxs6 } from "react/jsx-runtime";
1872
1891
  var user = {
1873
1892
  name: "Dalibor Homola",
1874
1893
  employeeId: "C2503017",
@@ -1912,63 +1931,63 @@ var ToolbarAccount = () => {
1912
1931
  setAnchorEl(null);
1913
1932
  setTimeout(() => setTab("settings"), 300);
1914
1933
  };
1915
- const login2 = () => user.login();
1916
- const logout2 = () => user.logout();
1934
+ const login = () => user.login();
1935
+ const logout = () => user.logout();
1917
1936
  const changeTab = (newTab) => () => setTab(newTab);
1918
- const settings = /* @__PURE__ */ jsxs6(List, { component: "nav", subheader: /* @__PURE__ */ jsx13(ListSubheader, { sx: { backgroundColor: "transparent" }, children: t("Layout.Settings") }), children: [
1937
+ const settings = /* @__PURE__ */ jsxs6(List, { component: "nav", subheader: /* @__PURE__ */ jsx14(ListSubheader, { sx: { backgroundColor: "transparent" }, children: t("Layout.Settings") }), children: [
1919
1938
  /* @__PURE__ */ jsxs6(ListItemButton, { onClick: changeTab("theme"), sx: { py: 0.3 }, children: [
1920
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(Brightness4, {}) }),
1921
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.Appearance"), secondary: getModeText() }),
1922
- /* @__PURE__ */ jsx13(ChevronRight, {})
1939
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(Brightness4, {}) }),
1940
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.Appearance"), secondary: getModeText() }),
1941
+ /* @__PURE__ */ jsx14(ChevronRight, {})
1923
1942
  ] }),
1924
1943
  /* @__PURE__ */ jsxs6(ListItemButton, { onClick: changeTab("language"), sx: { py: 0.3 }, children: [
1925
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(Translate, {}) }),
1926
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.Language"), secondary: i18n2.resolvedLanguage === "en" ? "English" : "\u010Ce\u0161tina" }),
1927
- /* @__PURE__ */ jsx13(ChevronRight, {})
1944
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(Translate, {}) }),
1945
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.Language"), secondary: i18n2.resolvedLanguage === "en" ? "English" : "\u010Ce\u0161tina" }),
1946
+ /* @__PURE__ */ jsx14(ChevronRight, {})
1928
1947
  ] })
1929
1948
  ] });
1930
1949
  const theme = /* @__PURE__ */ jsxs6(List, { subheader: /* @__PURE__ */ jsxs6(ListSubheader, { onClick: changeTab("settings"), sx: { backgroundColor: "transparent", display: "flex", alignItems: "center", px: 1, cursor: "pointer" }, children: [
1931
- /* @__PURE__ */ jsx13(IconButton3, { size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx13(ArrowBack, { fontSize: "small" }) }),
1950
+ /* @__PURE__ */ jsx14(IconButton3, { size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx14(ArrowBack, { fontSize: "small" }) }),
1932
1951
  " ",
1933
1952
  t("Layout.Appearance")
1934
1953
  ] }), children: [
1935
1954
  /* @__PURE__ */ jsxs6(ListItemButton, { onClick: changeMode("light"), disabled: mode === "light", children: [
1936
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(LightMode, {}) }),
1937
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.Light") })
1955
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(LightMode, {}) }),
1956
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.Light") })
1938
1957
  ] }),
1939
1958
  /* @__PURE__ */ jsxs6(ListItemButton, { onClick: changeMode("dark"), disabled: mode === "dark", children: [
1940
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(DarkMode, {}) }),
1941
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.Dark") })
1959
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(DarkMode, {}) }),
1960
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.Dark") })
1942
1961
  ] }),
1943
1962
  /* @__PURE__ */ jsxs6(ListItemButton, { onClick: changeMode("system"), disabled: mode === "system", children: [
1944
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(SettingsBrightness, {}) }),
1945
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.System") })
1963
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(SettingsBrightness, {}) }),
1964
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.System") })
1946
1965
  ] })
1947
1966
  ] });
1948
1967
  const language = /* @__PURE__ */ jsxs6(List, { subheader: /* @__PURE__ */ jsxs6(ListSubheader, { onClick: changeTab("settings"), sx: { backgroundColor: "transparent", display: "flex", alignItems: "center", px: 1, cursor: "pointer" }, children: [
1949
- /* @__PURE__ */ jsx13(IconButton3, { size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx13(ArrowBack, { fontSize: "small" }) }),
1968
+ /* @__PURE__ */ jsx14(IconButton3, { size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx14(ArrowBack, { fontSize: "small" }) }),
1950
1969
  " ",
1951
1970
  t("Layout.Language")
1952
1971
  ] }), children: [
1953
- /* @__PURE__ */ jsx13(ListItemButton, { onClick: changeLanguage("en"), disabled: i18n2.resolvedLanguage === "en", children: /* @__PURE__ */ jsx13(ListItemText, { primary: "English" }) }),
1954
- /* @__PURE__ */ jsx13(ListItemButton, { onClick: changeLanguage("cs"), disabled: i18n2.resolvedLanguage === "cs", children: /* @__PURE__ */ jsx13(ListItemText, { primary: "\u010Ce\u0161tina" }) })
1972
+ /* @__PURE__ */ jsx14(ListItemButton, { onClick: changeLanguage("en"), disabled: i18n2.resolvedLanguage === "en", children: /* @__PURE__ */ jsx14(ListItemText, { primary: "English" }) }),
1973
+ /* @__PURE__ */ jsx14(ListItemButton, { onClick: changeLanguage("cs"), disabled: i18n2.resolvedLanguage === "cs", children: /* @__PURE__ */ jsx14(ListItemText, { primary: "\u010Ce\u0161tina" }) })
1955
1974
  ] });
1956
1975
  return /* @__PURE__ */ jsxs6(Fragment, { children: [
1957
- /* @__PURE__ */ jsx13(IconButton3, { size: "small", onClick: openMenu, children: user.name ? /* @__PURE__ */ jsx13(Avatar, { sx: { width: { xs: 32, sm: 40 }, height: { xs: 32, sm: 40 }, bgcolor: "primary.main" }, children: /* @__PURE__ */ jsx13(Typography6, { variant: "subtitle2", sx: { fontWeight: "bold", lineHeight: 0 }, children: usernameInitials() }) }) : /* @__PURE__ */ jsx13(AccountCircle, {}) }),
1958
- /* @__PURE__ */ jsx13(Menu, { anchorEl, open, onClose: closeMenu, children: /* @__PURE__ */ jsxs6(Box3, { sx: { width: 240 }, children: [
1959
- /* @__PURE__ */ jsx13(List, { children: user.name ? /* @__PURE__ */ jsxs6(Fragment, { children: [
1960
- /* @__PURE__ */ jsx13(ListItem, { children: /* @__PURE__ */ jsx13(ListItemText, { primary: user.name, secondary: /* @__PURE__ */ jsxs6("span", { children: [
1961
- /* @__PURE__ */ jsx13("span", { children: user.employeeId }),
1962
- /* @__PURE__ */ jsx13("br", {}),
1963
- /* @__PURE__ */ jsx13("span", { children: user.department })
1976
+ /* @__PURE__ */ jsx14(IconButton3, { size: "small", onClick: openMenu, children: user.name ? /* @__PURE__ */ jsx14(Avatar, { sx: { width: { xs: 32, sm: 40 }, height: { xs: 32, sm: 40 }, bgcolor: "primary.main" }, children: /* @__PURE__ */ jsx14(Typography6, { variant: "subtitle2", sx: { fontWeight: "bold", lineHeight: 0 }, children: usernameInitials() }) }) : /* @__PURE__ */ jsx14(AccountCircle, {}) }),
1977
+ /* @__PURE__ */ jsx14(Menu, { anchorEl, open, onClose: closeMenu, children: /* @__PURE__ */ jsxs6(Box3, { sx: { width: 240 }, children: [
1978
+ /* @__PURE__ */ jsx14(List, { children: user.name ? /* @__PURE__ */ jsxs6(Fragment, { children: [
1979
+ /* @__PURE__ */ jsx14(ListItem, { children: /* @__PURE__ */ jsx14(ListItemText, { primary: user.name, secondary: /* @__PURE__ */ jsxs6("span", { children: [
1980
+ /* @__PURE__ */ jsx14("span", { children: user.employeeId }),
1981
+ /* @__PURE__ */ jsx14("br", {}),
1982
+ /* @__PURE__ */ jsx14("span", { children: user.department })
1964
1983
  ] }) }) }),
1965
- /* @__PURE__ */ jsxs6(ListItemButton, { onClick: logout2, children: [
1966
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(Logout, { color: "error" }) }),
1967
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.Logout") })
1984
+ /* @__PURE__ */ jsxs6(ListItemButton, { onClick: logout, children: [
1985
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(Logout, { color: "error" }) }),
1986
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.Logout") })
1968
1987
  ] })
1969
- ] }) : /* @__PURE__ */ jsxs6(ListItemButton, { onClick: login2, children: [
1970
- /* @__PURE__ */ jsx13(ListItemIcon, { children: /* @__PURE__ */ jsx13(Login, { color: "success" }) }),
1971
- /* @__PURE__ */ jsx13(ListItemText, { primary: t("Layout.LogIn") })
1988
+ ] }) : /* @__PURE__ */ jsxs6(ListItemButton, { onClick: login, children: [
1989
+ /* @__PURE__ */ jsx14(ListItemIcon, { children: /* @__PURE__ */ jsx14(Login, { color: "success" }) }),
1990
+ /* @__PURE__ */ jsx14(ListItemText, { primary: t("Layout.LogIn") })
1972
1991
  ] }) }),
1973
1992
  tab === "settings" && settings,
1974
1993
  tab === "theme" && theme,
@@ -1988,83 +2007,6 @@ import { useTranslation as useTranslation4 } from "react-i18next";
1988
2007
  // src/utils/ClientUtils.ts
1989
2008
  import { useQueryClient } from "@tanstack/react-query";
1990
2009
  import axios from "axios";
1991
-
1992
- // src/services/UserService.ts
1993
- import Keycloak from "keycloak-js";
1994
- var keycloakConfig = {
1995
- url: import.meta.env.VITE_KEYCLOAK_URL,
1996
- realm: import.meta.env.VITE_KEYCLOAK_REALM,
1997
- clientId: import.meta.env.VITE_KEYCLOAK_CLIENT_ID,
1998
- idpHint: import.meta.env.VITE_KEYCLOAK_IDP_HINT,
1999
- confidentialClientId: import.meta.env.VITE_KEYCLOAK_CONFIDENTIAL_CLIENT_ID,
2000
- confidentialClientSecret: import.meta.env.VITE_KEYCLOAK_CONFIDENTIAL_CLIENT_SECRET
2001
- };
2002
- var _kc = new Keycloak({
2003
- url: keycloakConfig.url,
2004
- realm: keycloakConfig.realm,
2005
- clientId: keycloakConfig.clientId
2006
- });
2007
- var initKeycloak = async () => {
2008
- if (typeof window === "undefined") return;
2009
- const authenticated = await _kc.init({ onLoad: "check-sso" });
2010
- if (authenticated) {
2011
- return await loadUserInfo();
2012
- } else {
2013
- await _kc.login({ idpHint: keycloakConfig.idpHint });
2014
- return await loadUserInfo();
2015
- }
2016
- };
2017
- var login = _kc.login;
2018
- var logout = _kc.logout;
2019
- var getToken = () => {
2020
- if (_kc.token) {
2021
- return _kc.token;
2022
- } else {
2023
- return getConfidentialToken();
2024
- }
2025
- };
2026
- var getConfidentialToken = async () => {
2027
- const { confidentialClientId, confidentialClientSecret, url, realm } = keycloakConfig;
2028
- if (!confidentialClientId || !confidentialClientSecret)
2029
- throw new Error("Confidential client id or secret is missing");
2030
- const credentials = btoa(`${confidentialClientId}:${confidentialClientSecret}`);
2031
- const urlencoded = new URLSearchParams({ grant_type: "client_credentials" });
2032
- const response = await fetch(`${url}/realms/${realm}/protocol/openid-connect/token`, {
2033
- method: "POST",
2034
- headers: {
2035
- "Content-Type": "application/x-www-form-urlencoded",
2036
- "Authorization": `Basic ${credentials}`
2037
- },
2038
- body: urlencoded
2039
- });
2040
- if (!response.ok)
2041
- throw new Error("Failed to obtain confidential token");
2042
- const data = await response.json();
2043
- return data.access_token;
2044
- };
2045
- var updateToken = () => _kc.updateToken(30).catch(login);
2046
- var hasRole = (roles) => roles.some((role) => _kc.hasRealmRole(role) || _kc.hasResourceRole(role));
2047
- var loadUserInfo = async () => {
2048
- const user2 = await _kc.loadUserInfo();
2049
- return {
2050
- name: user2.name,
2051
- employeeId: user2.employeeId?.toUpperCase() ?? "",
2052
- department: user2.department ?? "",
2053
- email: user2.email,
2054
- company: user2.company,
2055
- category: user2.category
2056
- };
2057
- };
2058
- var UserService = {
2059
- initKeycloak,
2060
- login,
2061
- logout,
2062
- getToken,
2063
- updateToken,
2064
- hasRole
2065
- };
2066
-
2067
- // src/utils/ClientUtils.ts
2068
2010
  var Platform = class {
2069
2011
  static isAndroid = /android/i.test(navigator.userAgent);
2070
2012
  static isIOS = /iPad|iPhone|iPod/.test(navigator.userAgent);
@@ -2097,9 +2039,6 @@ var rootRouteHead = ({ title, themeColor }) => () => ({
2097
2039
  });
2098
2040
  var wczApiClient = axios.create();
2099
2041
  wczApiClient.interceptors.request.use(async (config) => {
2100
- await UserService.updateToken();
2101
- const token = await UserService.getToken();
2102
- config.headers.Authorization = `Bearer ${token}`;
2103
2042
  return config;
2104
2043
  });
2105
2044
  var WISTRON_PRIMARY_COLOR = "#00506E";
@@ -2163,10 +2102,7 @@ var useGetTheme = (theme) => {
2163
2102
  MuiTableContainer: {
2164
2103
  styleOverrides: {
2165
2104
  root: ({ theme: theme2 }) => ({
2166
- height: "calc(100vh - 56px)",
2167
- [theme2.breakpoints.up("sm")]: {
2168
- height: "calc(100vh - 64px)"
2169
- },
2105
+ flexGrow: 1,
2170
2106
  "& .MuiDataGrid-cell--editing": {
2171
2107
  "& .MuiInputBase-root": {
2172
2108
  height: "100%"
@@ -2193,6 +2129,11 @@ var useGetTheme = (theme) => {
2193
2129
  fullWidth: true
2194
2130
  }
2195
2131
  },
2132
+ MuiContainer: {
2133
+ defaultProps: {
2134
+ maxWidth: false
2135
+ }
2136
+ },
2196
2137
  ...theme?.components
2197
2138
  }
2198
2139
  },
@@ -2206,10 +2147,10 @@ var useGetTheme = (theme) => {
2206
2147
  import { useLocation, useNavigate, useSearch, Link as TanstackRouterLink } from "@tanstack/react-router";
2207
2148
  import { AppProvider } from "@toolpad/core/AppProvider";
2208
2149
  import { useCallback, useMemo as useMemo2, forwardRef } from "react";
2209
- import { jsx as jsx14 } from "react/jsx-runtime";
2150
+ import { jsx as jsx15 } from "react/jsx-runtime";
2210
2151
  var Link2 = forwardRef((props, ref) => {
2211
2152
  const { href, history, ...rest } = props;
2212
- return /* @__PURE__ */ jsx14(TanstackRouterLink, { ref, to: href, replace: history === "replace", ...rest });
2153
+ return /* @__PURE__ */ jsx15(TanstackRouterLink, { ref, to: href, replace: history === "replace", ...rest });
2213
2154
  });
2214
2155
  var TanstackRouterAppProvider = (props) => {
2215
2156
  const { pathname } = useLocation();
@@ -2222,11 +2163,11 @@ var TanstackRouterAppProvider = (props) => {
2222
2163
  [_navigate]
2223
2164
  );
2224
2165
  const router = useMemo2(() => ({ pathname, searchParams: new URLSearchParams(searchParams), navigate, Link: Link2 }), [pathname, searchParams, navigate]);
2225
- return /* @__PURE__ */ jsx14(AppProvider, { router, ...props });
2166
+ return /* @__PURE__ */ jsx15(AppProvider, { router, ...props });
2226
2167
  };
2227
2168
 
2228
2169
  // src/providers/LayoutProvider.tsx
2229
- import { jsx as jsx15, jsxs as jsxs7 } from "react/jsx-runtime";
2170
+ import { jsx as jsx16, jsxs as jsxs7 } from "react/jsx-runtime";
2230
2171
  i18n.use(HttpBackend).use(LanguageDetector).use(initReactI18next).init({
2231
2172
  fallbackLng: "en",
2232
2173
  interpolation: {
@@ -2248,11 +2189,11 @@ var LayoutProvider = (props) => {
2248
2189
  const appTitle = rootRouterState.meta?.find((meta) => meta?.title)?.title;
2249
2190
  if (!appTitle)
2250
2191
  throw new Error("Title is not defined in the RootRoute head.");
2251
- return /* @__PURE__ */ jsx15(LocalizationProvider, { dateAdapter: AdapterDayjs, adapterLocale: i18n2.resolvedLanguage, children: /* @__PURE__ */ jsx15(TanstackRouterAppProvider, { navigation, theme, localeText: {
2192
+ return /* @__PURE__ */ jsx16(LocalizationProvider, { dateAdapter: AdapterDayjs, adapterLocale: i18n2.resolvedLanguage, children: /* @__PURE__ */ jsx16(TanstackRouterAppProvider, { navigation, theme, localeText: {
2252
2193
  confirm: t("Layout.Confirm"),
2253
2194
  cancel: t("Layout.Cancel"),
2254
2195
  alert: t("Layout.Alert")
2255
- }, children: /* @__PURE__ */ jsx15(NotificationsProvider, { slotProps: { snackbar: { anchorOrigin: { vertical: isLargeScreen ? "top" : "bottom", horizontal: "center" } } }, children: /* @__PURE__ */ jsx15(LayoutContext.Provider, { value: { appTitle }, children: /* @__PURE__ */ jsxs7(
2196
+ }, children: /* @__PURE__ */ jsx16(NotificationsProvider, { slotProps: { snackbar: { anchorOrigin: { vertical: isLargeScreen ? "top" : "bottom", horizontal: "center" } } }, children: /* @__PURE__ */ jsx16(LayoutContext.Provider, { value: { appTitle }, children: /* @__PURE__ */ jsxs7(
2256
2197
  DashboardLayout,
2257
2198
  {
2258
2199
  defaultSidebarCollapsed: true,
@@ -2264,8 +2205,8 @@ var LayoutProvider = (props) => {
2264
2205
  },
2265
2206
  children: [
2266
2207
  props.children,
2267
- /* @__PURE__ */ jsx15(DevelopmentBanner, { hasNavigationRoutes: !!navigation.length }),
2268
- (isFetching || isMutating) && /* @__PURE__ */ jsx15(LinearProgress, { sx: { position: "fixed", top: { xs: 56, sm: 64 }, left: 0, right: 0 } })
2208
+ /* @__PURE__ */ jsx16(DevelopmentBanner, { hasNavigationRoutes: !!navigation.length }),
2209
+ (isFetching || isMutating) && /* @__PURE__ */ jsx16(LinearProgress, { sx: { position: "fixed", top: { xs: 56, sm: 64 }, left: 0, right: 0 } })
2269
2210
  ]
2270
2211
  }
2271
2212
  ) }) }) }) });
@@ -2290,11 +2231,11 @@ var getFieldStatus = (field) => {
2290
2231
  };
2291
2232
 
2292
2233
  // src/components/form/FormAutocomplete.tsx
2293
- import { jsx as jsx16 } from "react/jsx-runtime";
2234
+ import { jsx as jsx17 } from "react/jsx-runtime";
2294
2235
  var FormAutocomplete = ({ textFieldProps, ...autocompleteProps }) => {
2295
2236
  const field = useFieldContext();
2296
2237
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2297
- return /* @__PURE__ */ jsx16(
2238
+ return /* @__PURE__ */ jsx17(
2298
2239
  Autocomplete,
2299
2240
  {
2300
2241
  value: field.state.value,
@@ -2303,7 +2244,7 @@ var FormAutocomplete = ({ textFieldProps, ...autocompleteProps }) => {
2303
2244
  onBlur: field.handleBlur,
2304
2245
  "aria-label": field.name,
2305
2246
  ...autocompleteProps,
2306
- renderInput: (params) => /* @__PURE__ */ jsx16(
2247
+ renderInput: (params) => /* @__PURE__ */ jsx17(
2307
2248
  TextField,
2308
2249
  {
2309
2250
  ...params,
@@ -2319,15 +2260,15 @@ var FormAutocomplete = ({ textFieldProps, ...autocompleteProps }) => {
2319
2260
 
2320
2261
  // src/components/form/FormCheckbox.tsx
2321
2262
  import { Checkbox, FormControl, FormControlLabel, FormHelperText } from "@mui/material";
2322
- import { jsx as jsx17, jsxs as jsxs8 } from "react/jsx-runtime";
2263
+ import { jsx as jsx18, jsxs as jsxs8 } from "react/jsx-runtime";
2323
2264
  var FormCheckbox = (props) => {
2324
2265
  const field = useFieldContext();
2325
2266
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2326
2267
  return /* @__PURE__ */ jsxs8(FormControl, { component: "fieldset", children: [
2327
- /* @__PURE__ */ jsx17(
2268
+ /* @__PURE__ */ jsx18(
2328
2269
  FormControlLabel,
2329
2270
  {
2330
- control: /* @__PURE__ */ jsx17(
2271
+ control: /* @__PURE__ */ jsx18(
2331
2272
  Checkbox,
2332
2273
  {
2333
2274
  name: field.name,
@@ -2341,18 +2282,18 @@ var FormCheckbox = (props) => {
2341
2282
  label: props.label ?? ""
2342
2283
  }
2343
2284
  ),
2344
- isTouched && hasError && /* @__PURE__ */ jsx17(FormHelperText, { error: hasError, children: helperText })
2285
+ isTouched && hasError && /* @__PURE__ */ jsx18(FormHelperText, { error: hasError, children: helperText })
2345
2286
  ] });
2346
2287
  };
2347
2288
 
2348
2289
  // src/components/form/FormDatePicker.tsx
2349
2290
  import { DatePicker } from "@mui/x-date-pickers-pro";
2350
2291
  import dayjs from "dayjs";
2351
- import { jsx as jsx18 } from "react/jsx-runtime";
2292
+ import { jsx as jsx19 } from "react/jsx-runtime";
2352
2293
  var FormDatePicker = (props) => {
2353
2294
  const field = useFieldContext();
2354
2295
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2355
- return /* @__PURE__ */ jsx18(
2296
+ return /* @__PURE__ */ jsx19(
2356
2297
  DatePicker,
2357
2298
  {
2358
2299
  name: field.name,
@@ -2376,11 +2317,11 @@ var FormDatePicker = (props) => {
2376
2317
  // src/components/form/FormDateTimePicker.tsx
2377
2318
  import { DateTimePicker } from "@mui/x-date-pickers-pro";
2378
2319
  import dayjs2 from "dayjs";
2379
- import { jsx as jsx19 } from "react/jsx-runtime";
2320
+ import { jsx as jsx20 } from "react/jsx-runtime";
2380
2321
  var FormDateTimePicker = (props) => {
2381
2322
  const field = useFieldContext();
2382
2323
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2383
- return /* @__PURE__ */ jsx19(
2324
+ return /* @__PURE__ */ jsx20(
2384
2325
  DateTimePicker,
2385
2326
  {
2386
2327
  name: field.name,
@@ -2404,11 +2345,11 @@ var FormDateTimePicker = (props) => {
2404
2345
  // src/components/form/FormNumberField.tsx
2405
2346
  import { TextField as TextField2 } from "@mui/material";
2406
2347
  import { NumericFormat } from "react-number-format";
2407
- import { jsx as jsx20 } from "react/jsx-runtime";
2348
+ import { jsx as jsx21 } from "react/jsx-runtime";
2408
2349
  var FormNumberField = ({ options, ...props }) => {
2409
2350
  const field = useFieldContext();
2410
2351
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2411
- return /* @__PURE__ */ jsx20(
2352
+ return /* @__PURE__ */ jsx21(
2412
2353
  NumericFormat,
2413
2354
  {
2414
2355
  customInput: TextField2,
@@ -2427,13 +2368,13 @@ var FormNumberField = ({ options, ...props }) => {
2427
2368
 
2428
2369
  // src/components/form/FormRadioGroup.tsx
2429
2370
  import { FormControl as FormControl2, FormControlLabel as FormControlLabel2, FormHelperText as FormHelperText2, FormLabel, Radio, RadioGroup } from "@mui/material";
2430
- import { jsx as jsx21, jsxs as jsxs9 } from "react/jsx-runtime";
2371
+ import { jsx as jsx22, jsxs as jsxs9 } from "react/jsx-runtime";
2431
2372
  var FormRadioGroup = ({ label, options, ...props }) => {
2432
2373
  const field = useFieldContext();
2433
2374
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2434
2375
  return /* @__PURE__ */ jsxs9(FormControl2, { component: "fieldset", children: [
2435
- label && /* @__PURE__ */ jsx21(FormLabel, { component: "legend", children: label }),
2436
- /* @__PURE__ */ jsx21(
2376
+ label && /* @__PURE__ */ jsx22(FormLabel, { component: "legend", children: label }),
2377
+ /* @__PURE__ */ jsx22(
2437
2378
  RadioGroup,
2438
2379
  {
2439
2380
  name: field.name,
@@ -2442,30 +2383,30 @@ var FormRadioGroup = ({ label, options, ...props }) => {
2442
2383
  onBlur: field.handleBlur,
2443
2384
  "aria-label": field.name,
2444
2385
  ...props,
2445
- children: options.map((option) => /* @__PURE__ */ jsx21(
2386
+ children: options.map((option) => /* @__PURE__ */ jsx22(
2446
2387
  FormControlLabel2,
2447
2388
  {
2448
2389
  value: option.value,
2449
- control: /* @__PURE__ */ jsx21(Radio, {}),
2390
+ control: /* @__PURE__ */ jsx22(Radio, {}),
2450
2391
  label: option.label
2451
2392
  },
2452
2393
  option.value
2453
2394
  ))
2454
2395
  }
2455
2396
  ),
2456
- isTouched && hasError && /* @__PURE__ */ jsx21(FormHelperText2, { error: hasError, children: helperText })
2397
+ isTouched && hasError && /* @__PURE__ */ jsx22(FormHelperText2, { error: hasError, children: helperText })
2457
2398
  ] });
2458
2399
  };
2459
2400
 
2460
2401
  // src/components/form/FormSlider.tsx
2461
2402
  import { FormControl as FormControl3, FormHelperText as FormHelperText3, FormLabel as FormLabel2, Slider } from "@mui/material";
2462
- import { jsx as jsx22, jsxs as jsxs10 } from "react/jsx-runtime";
2403
+ import { jsx as jsx23, jsxs as jsxs10 } from "react/jsx-runtime";
2463
2404
  var FormSlider = ({ label, ...props }) => {
2464
2405
  const field = useFieldContext();
2465
2406
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2466
2407
  return /* @__PURE__ */ jsxs10(FormControl3, { component: "fieldset", children: [
2467
- label && /* @__PURE__ */ jsx22(FormLabel2, { children: label }),
2468
- /* @__PURE__ */ jsx22(
2408
+ label && /* @__PURE__ */ jsx23(FormLabel2, { children: label }),
2409
+ /* @__PURE__ */ jsx23(
2469
2410
  Slider,
2470
2411
  {
2471
2412
  name: field.name,
@@ -2476,13 +2417,13 @@ var FormSlider = ({ label, ...props }) => {
2476
2417
  ...props
2477
2418
  }
2478
2419
  ),
2479
- isTouched && hasError && /* @__PURE__ */ jsx22(FormHelperText3, { error: hasError, children: helperText })
2420
+ isTouched && hasError && /* @__PURE__ */ jsx23(FormHelperText3, { error: hasError, children: helperText })
2480
2421
  ] });
2481
2422
  };
2482
2423
 
2483
2424
  // src/components/form/FormSubmitButton.tsx
2484
2425
  import { Button as Button2 } from "@mui/material";
2485
- import { jsx as jsx23 } from "react/jsx-runtime";
2426
+ import { jsx as jsx24 } from "react/jsx-runtime";
2486
2427
  var FormSubmitButton = (props) => {
2487
2428
  const form = useFormContext();
2488
2429
  const handleClick = (e) => {
@@ -2490,7 +2431,7 @@ var FormSubmitButton = (props) => {
2490
2431
  e.stopPropagation();
2491
2432
  form.handleSubmit();
2492
2433
  };
2493
- return /* @__PURE__ */ jsx23(form.Subscribe, { selector: (state) => [state.canSubmit, state.isSubmitting], children: ([canSubmit, isSubmitting]) => /* @__PURE__ */ jsx23(
2434
+ return /* @__PURE__ */ jsx24(form.Subscribe, { selector: (state) => [state.canSubmit, state.isSubmitting], children: ([canSubmit, isSubmitting]) => /* @__PURE__ */ jsx24(
2494
2435
  Button2,
2495
2436
  {
2496
2437
  loading: isSubmitting,
@@ -2505,15 +2446,15 @@ var FormSubmitButton = (props) => {
2505
2446
 
2506
2447
  // src/components/form/FormSwitch.tsx
2507
2448
  import { FormControl as FormControl4, FormControlLabel as FormControlLabel3, FormHelperText as FormHelperText4, Switch } from "@mui/material";
2508
- import { jsx as jsx24, jsxs as jsxs11 } from "react/jsx-runtime";
2449
+ import { jsx as jsx25, jsxs as jsxs11 } from "react/jsx-runtime";
2509
2450
  var FormSwitch = (props) => {
2510
2451
  const field = useFieldContext();
2511
2452
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2512
2453
  return /* @__PURE__ */ jsxs11(FormControl4, { component: "fieldset", children: [
2513
- /* @__PURE__ */ jsx24(
2454
+ /* @__PURE__ */ jsx25(
2514
2455
  FormControlLabel3,
2515
2456
  {
2516
- control: /* @__PURE__ */ jsx24(
2457
+ control: /* @__PURE__ */ jsx25(
2517
2458
  Switch,
2518
2459
  {
2519
2460
  name: field.name,
@@ -2527,17 +2468,17 @@ var FormSwitch = (props) => {
2527
2468
  label: props.label ?? ""
2528
2469
  }
2529
2470
  ),
2530
- isTouched && hasError && /* @__PURE__ */ jsx24(FormHelperText4, { error: hasError, children: helperText })
2471
+ isTouched && hasError && /* @__PURE__ */ jsx25(FormHelperText4, { error: hasError, children: helperText })
2531
2472
  ] });
2532
2473
  };
2533
2474
 
2534
2475
  // src/components/form/FormTextField.tsx
2535
2476
  import { TextField as TextField3 } from "@mui/material";
2536
- import { jsx as jsx25 } from "react/jsx-runtime";
2477
+ import { jsx as jsx26 } from "react/jsx-runtime";
2537
2478
  var FormTextField = (props) => {
2538
2479
  const field = useFieldContext();
2539
2480
  const { isTouched, hasError, helperText } = getFieldStatus(field);
2540
- return /* @__PURE__ */ jsx25(
2481
+ return /* @__PURE__ */ jsx26(
2541
2482
  TextField3,
2542
2483
  {
2543
2484
  name: field.name,
@@ -2658,7 +2599,9 @@ var useOpenFile = (options) => {
2658
2599
  method: "GET",
2659
2600
  responseType: "blob"
2660
2601
  }),
2661
- onSuccess: (data) => window.open(URL.createObjectURL(data))
2602
+ onSuccess: (data) => {
2603
+ window.open(URL.createObjectURL(data));
2604
+ }
2662
2605
  });
2663
2606
  };
2664
2607
  var useUpdateFileMeta = (options) => {