@xelto.npm/xc2-lib 0.0.32 → 0.0.33

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/cjs/index.js CHANGED
@@ -6951,7 +6951,7 @@ if (process.env.NODE_ENV !== 'production') {
6951
6951
  }
6952
6952
  var ThemeContext$1 = ThemeContext;
6953
6953
 
6954
- function useTheme$4() {
6954
+ function useTheme$3() {
6955
6955
  const theme = React__namespace.useContext(ThemeContext$1);
6956
6956
  if (process.env.NODE_ENV !== 'production') {
6957
6957
  // eslint-disable-next-line react-hooks/rules-of-hooks
@@ -6986,7 +6986,7 @@ function ThemeProvider$1(props) {
6986
6986
  children,
6987
6987
  theme: localTheme
6988
6988
  } = props;
6989
- const outerTheme = useTheme$4();
6989
+ const outerTheme = useTheme$3();
6990
6990
  if (process.env.NODE_ENV !== 'production') {
6991
6991
  if (outerTheme === null && typeof localTheme === 'function') {
6992
6992
  console.error(['MUI: You are providing a theme function prop to the ThemeProvider component:', '<ThemeProvider theme={outerTheme => outerTheme} />', '', 'However, no outer theme is present.', 'Make sure a theme is already injected higher in the React tree ' + 'or provide a theme object.'].join('\n'));
@@ -7021,14 +7021,14 @@ if (process.env.NODE_ENV !== 'production') {
7021
7021
  function isObjectEmpty(obj) {
7022
7022
  return Object.keys(obj).length === 0;
7023
7023
  }
7024
- function useTheme$3(defaultTheme = null) {
7025
- const contextTheme = useTheme$4();
7024
+ function useTheme$2(defaultTheme = null) {
7025
+ const contextTheme = useTheme$3();
7026
7026
  return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;
7027
7027
  }
7028
7028
 
7029
7029
  const systemDefaultTheme$1 = createTheme$1();
7030
- function useTheme$2(defaultTheme = systemDefaultTheme$1) {
7031
- return useTheme$3(defaultTheme);
7030
+ function useTheme$1(defaultTheme = systemDefaultTheme$1) {
7031
+ return useTheme$2(defaultTheme);
7032
7032
  }
7033
7033
 
7034
7034
  const _excluded$2A = ["className", "component"];
@@ -7043,7 +7043,7 @@ function createBox(options = {}) {
7043
7043
  shouldForwardProp: prop => prop !== 'theme' && prop !== 'sx' && prop !== 'as'
7044
7044
  })(styleFunctionSx$1);
7045
7045
  const Box = /*#__PURE__*/React__namespace.forwardRef(function Box(inProps, ref) {
7046
- const theme = useTheme$2(defaultTheme);
7046
+ const theme = useTheme$1(defaultTheme);
7047
7047
  const _extendSxProp = extendSxProp(inProps),
7048
7048
  {
7049
7049
  className,
@@ -7322,7 +7322,7 @@ function useThemeProps$1({
7322
7322
  name,
7323
7323
  defaultTheme
7324
7324
  }) {
7325
- const theme = useTheme$2(defaultTheme);
7325
+ const theme = useTheme$1(defaultTheme);
7326
7326
  const mergedProps = getThemeProps({
7327
7327
  theme,
7328
7328
  name,
@@ -7638,7 +7638,7 @@ function private_safeEmphasize(color, coefficient, warning) {
7638
7638
 
7639
7639
  const EMPTY_THEME = {};
7640
7640
  function InnerThemeProvider(props) {
7641
- const theme = useTheme$2();
7641
+ const theme = useTheme$1();
7642
7642
  return /*#__PURE__*/jsxRuntime.exports.jsx(ThemeContext$2.Provider, {
7643
7643
  value: typeof theme === 'object' ? theme : EMPTY_THEME,
7644
7644
  children: props.children
@@ -8115,7 +8115,7 @@ function createCssVarsProvider(options) {
8115
8115
  disableStyleSheetGeneration = false
8116
8116
  }) {
8117
8117
  const hasMounted = React__namespace.useRef(false);
8118
- const upperTheme = useTheme$4();
8118
+ const upperTheme = useTheme$3();
8119
8119
  const ctx = React__namespace.useContext(ColorSchemeContext);
8120
8120
  const nested = !!ctx && !disableNestedContext;
8121
8121
  const {
@@ -8881,7 +8881,7 @@ function createGrid(options = {}) {
8881
8881
  const GridRoot = createStyledComponent(generateGridColumnsStyles, generateGridColumnSpacingStyles, generateGridRowSpacingStyles, generateGridSizeStyles, generateGridDirectionStyles, generateGridStyles, generateGridOffsetStyles);
8882
8882
  const Grid = /*#__PURE__*/React__namespace.forwardRef(function Grid(inProps, ref) {
8883
8883
  var _inProps$columns, _inProps$spacing, _ref, _inProps$rowSpacing, _ref2, _inProps$columnSpacin, _ref3, _disableEqualOverflow;
8884
- const theme = useTheme$2();
8884
+ const theme = useTheme$1();
8885
8885
  const themeProps = useThemeProps(inProps);
8886
8886
  const props = extendSxProp(themeProps); // `color` type conflicts with html color attribute.
8887
8887
  const nested = React__namespace.useContext(NestedContext);
@@ -10035,8 +10035,8 @@ function toUnitless(length) {
10035
10035
 
10036
10036
  const defaultTheme$2 = createTheme();
10037
10037
 
10038
- function useTheme$1() {
10039
- const theme = useTheme$2(defaultTheme$2);
10038
+ function useTheme() {
10039
+ const theme = useTheme$1(defaultTheme$2);
10040
10040
  if (process.env.NODE_ENV !== 'production') {
10041
10041
  // eslint-disable-next-line react-hooks/rules-of-hooks
10042
10042
  React__namespace.useDebugValue(theme);
@@ -39519,7 +39519,7 @@ const Paper = /*#__PURE__*/React__namespace.forwardRef(function Paper(inProps, r
39519
39519
  const classes = useUtilityClasses$1M(ownerState);
39520
39520
  if (process.env.NODE_ENV !== 'production') {
39521
39521
  // eslint-disable-next-line react-hooks/rules-of-hooks
39522
- const theme = useTheme$1();
39522
+ const theme = useTheme();
39523
39523
  if (theme.shadows[elevation] === undefined) {
39524
39524
  console.error([`MUI: The elevation provided <Paper elevation={${elevation}}> is not available in the theme.`, `Please make sure that \`theme.shadows[${elevation}]\` is defined.`].join('\n'));
39525
39525
  }
@@ -39646,7 +39646,7 @@ const Grow = /*#__PURE__*/React__namespace.forwardRef(function Grow(props, ref)
39646
39646
  other = _objectWithoutPropertiesLoose(props, _excluded$1Z);
39647
39647
  const timer = React__namespace.useRef();
39648
39648
  const autoTimeout = React__namespace.useRef();
39649
- const theme = useTheme$1();
39649
+ const theme = useTheme();
39650
39650
  const nodeRef = React__namespace.useRef(null);
39651
39651
  const handleRef = useForkRef(nodeRef, children.ref, ref);
39652
39652
  const normalizedTransitionCallback = callback => maybeIsAppearing => {
@@ -39861,7 +39861,7 @@ const styles$2 = {
39861
39861
  * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.
39862
39862
  */
39863
39863
  const Fade = /*#__PURE__*/React__namespace.forwardRef(function Fade(props, ref) {
39864
- const theme = useTheme$1();
39864
+ const theme = useTheme();
39865
39865
  const defaultTimeout = {
39866
39866
  enter: theme.transitions.duration.enteringScreen,
39867
39867
  exit: theme.transitions.duration.leavingScreen
@@ -41025,7 +41025,7 @@ const Menu = /*#__PURE__*/React__namespace.forwardRef(function Menu(inProps, ref
41025
41025
  } = props,
41026
41026
  TransitionProps = _objectWithoutPropertiesLoose(props.TransitionProps, _excluded$1U),
41027
41027
  other = _objectWithoutPropertiesLoose(props, _excluded2$7);
41028
- const theme = useTheme$1();
41028
+ const theme = useTheme();
41029
41029
  const isRtl = theme.direction === 'rtl';
41030
41030
  const ownerState = _extends$1b({}, props, {
41031
41031
  autoFocus,
@@ -51765,7 +51765,7 @@ function useMediaQueryNew(query, defaultMatches, matchMedia, ssrMatchMedia) {
51765
51765
  return match;
51766
51766
  }
51767
51767
  function useMediaQuery(queryInput, options = {}) {
51768
- const theme = useTheme$3();
51768
+ const theme = useTheme$2();
51769
51769
  // Wait for jsdom to support the match media feature.
51770
51770
  // All the browsers MUI support have this built-in.
51771
51771
  // This defensive check is here for simplicity.
@@ -52064,7 +52064,7 @@ const Collapse = /*#__PURE__*/React__namespace.forwardRef(function Collapse(inPr
52064
52064
  collapsedSize: collapsedSizeProp
52065
52065
  });
52066
52066
  const classes = useUtilityClasses$1E(ownerState);
52067
- const theme = useTheme$1();
52067
+ const theme = useTheme();
52068
52068
  const timer = React__namespace.useRef();
52069
52069
  const wrapperRef = React__namespace.useRef(null);
52070
52070
  const autoTransitionDuration = React__namespace.useRef();
@@ -53686,7 +53686,7 @@ const PopperRoot = styled(PopperUnstyled$1, {
53686
53686
  */
53687
53687
  const Popper = /*#__PURE__*/React__namespace.forwardRef(function Popper(inProps, ref) {
53688
53688
  var _slots$root;
53689
- const theme = useTheme$3();
53689
+ const theme = useTheme$2();
53690
53690
  const _useThemeProps = useThemeProps({
53691
53691
  props: inProps,
53692
53692
  name: 'MuiPopper'
@@ -58191,7 +58191,7 @@ const Dialog = /*#__PURE__*/React__namespace.forwardRef(function Dialog(inProps,
58191
58191
  props: inProps,
58192
58192
  name: 'MuiDialog'
58193
58193
  });
58194
- const theme = useTheme$1();
58194
+ const theme = useTheme();
58195
58195
  const defaultTransitionDuration = {
58196
58196
  enter: theme.transitions.duration.enteringScreen,
58197
58197
  exit: theme.transitions.duration.leavingScreen
@@ -59042,7 +59042,7 @@ function setTranslateValue(direction, node, containerProp) {
59042
59042
  * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.
59043
59043
  */
59044
59044
  const Slide = /*#__PURE__*/React__namespace.forwardRef(function Slide(props, ref) {
59045
- const theme = useTheme$1();
59045
+ const theme = useTheme();
59046
59046
  const defaultEasing = {
59047
59047
  enter: theme.transitions.easing.easeOut,
59048
59048
  exit: theme.transitions.easing.sharp
@@ -59413,7 +59413,7 @@ const Drawer = /*#__PURE__*/React__namespace.forwardRef(function Drawer(inProps,
59413
59413
  props: inProps,
59414
59414
  name: 'MuiDrawer'
59415
59415
  });
59416
- const theme = useTheme$1();
59416
+ const theme = useTheme();
59417
59417
  const defaultTransitionDuration = {
59418
59418
  enter: theme.transitions.duration.enteringScreen,
59419
59419
  exit: theme.transitions.duration.leavingScreen
@@ -60181,7 +60181,7 @@ const Grid = /*#__PURE__*/React__namespace.forwardRef(function Grid(inProps, ref
60181
60181
  });
60182
60182
  const {
60183
60183
  breakpoints
60184
- } = useTheme$1();
60184
+ } = useTheme();
60185
60185
  const props = extendSxProp(themeProps);
60186
60186
  const {
60187
60187
  className,
@@ -60444,7 +60444,7 @@ const withWidth = (options = {}) => Component => {
60444
60444
  initialWidth: initialWidthOption
60445
60445
  } = options;
60446
60446
  function WithWidth(props) {
60447
- const contextTheme = useTheme$1();
60447
+ const contextTheme = useTheme();
60448
60448
  const theme = props.theme || contextTheme;
60449
60449
  const _getThemeProps = getThemeProps({
60450
60450
  theme,
@@ -60521,7 +60521,7 @@ function HiddenJs(props) {
60521
60521
  only,
60522
60522
  width
60523
60523
  } = props;
60524
- const theme = useTheme$1();
60524
+ const theme = useTheme();
60525
60525
  let visible = true;
60526
60526
 
60527
60527
  // `only` check is faster to get out sooner if used.
@@ -61880,7 +61880,7 @@ const LinearProgress = /*#__PURE__*/React__namespace.forwardRef(function LinearP
61880
61880
  variant
61881
61881
  });
61882
61882
  const classes = useUtilityClasses$10(ownerState);
61883
- const theme = useTheme$1();
61883
+ const theme = useTheme();
61884
61884
  const rootProps = {};
61885
61885
  const inlineStyles = {
61886
61886
  bar1: {},
@@ -64136,7 +64136,7 @@ const PaginationItem = /*#__PURE__*/React__namespace.forwardRef(function Paginat
64136
64136
  type,
64137
64137
  variant
64138
64138
  });
64139
- const theme = useTheme$1();
64139
+ const theme = useTheme();
64140
64140
  const classes = useUtilityClasses$R(ownerState);
64141
64141
  const normalizedIcons = theme.direction === 'rtl' ? {
64142
64142
  previous: slots.next || components.next || NavigateNextIcon,
@@ -65165,7 +65165,7 @@ const Rating = /*#__PURE__*/React__namespace.forwardRef(function Rating(inProps,
65165
65165
  name: 'Rating'
65166
65166
  });
65167
65167
  const valueRounded = roundValueToPrecision(valueDerived, precision);
65168
- const theme = useTheme$1();
65168
+ const theme = useTheme();
65169
65169
  const [{
65170
65170
  hover,
65171
65171
  focus
@@ -66214,7 +66214,7 @@ const Slider = /*#__PURE__*/React__namespace.forwardRef(function Slider(inputPro
66214
66214
  props: inputProps,
66215
66215
  name: 'MuiSlider'
66216
66216
  });
66217
- const theme = useTheme$1();
66217
+ const theme = useTheme();
66218
66218
  const isRtl = theme.direction === 'rtl';
66219
66219
  const {
66220
66220
  // eslint-disable-next-line react/prop-types
@@ -66759,7 +66759,7 @@ const Snackbar = /*#__PURE__*/React__namespace.forwardRef(function Snackbar(inPr
66759
66759
  props: inProps,
66760
66760
  name: 'MuiSnackbar'
66761
66761
  });
66762
- const theme = useTheme$1();
66762
+ const theme = useTheme();
66763
66763
  const defaultTransitionDuration = {
66764
66764
  enter: theme.transitions.duration.enteringScreen,
66765
66765
  exit: theme.transitions.duration.leavingScreen
@@ -67103,7 +67103,7 @@ const styles$1 = {
67103
67103
  * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.
67104
67104
  */
67105
67105
  const Zoom = /*#__PURE__*/React__namespace.forwardRef(function Zoom(props, ref) {
67106
- const theme = useTheme$1();
67106
+ const theme = useTheme();
67107
67107
  const defaultTimeout = {
67108
67108
  enter: theme.transitions.duration.enteringScreen,
67109
67109
  exit: theme.transitions.duration.leavingScreen
@@ -67397,7 +67397,7 @@ const SpeedDial = /*#__PURE__*/React__namespace.forwardRef(function SpeedDial(in
67397
67397
  props: inProps,
67398
67398
  name: 'MuiSpeedDial'
67399
67399
  });
67400
- const theme = useTheme$1();
67400
+ const theme = useTheme();
67401
67401
  const defaultTransitionDuration = {
67402
67402
  enter: theme.transitions.duration.enteringScreen,
67403
67403
  exit: theme.transitions.duration.leavingScreen
@@ -67994,7 +67994,7 @@ const Tooltip = /*#__PURE__*/React__namespace.forwardRef(function Tooltip(inProp
67994
67994
  TransitionProps
67995
67995
  } = props,
67996
67996
  other = _objectWithoutPropertiesLoose(props, _excluded$M);
67997
- const theme = useTheme$1();
67997
+ const theme = useTheme();
67998
67998
  const isRtl = theme.direction === 'rtl';
67999
67999
  const [childNode, setChildNode] = React__namespace.useState();
68000
68000
  const [arrowRef, setArrowRef] = React__namespace.useState(null);
@@ -70281,7 +70281,7 @@ const SwipeableDrawer = /*#__PURE__*/React__namespace.forwardRef(function Swipea
70281
70281
  name: 'MuiSwipeableDrawer',
70282
70282
  props: inProps
70283
70283
  });
70284
- const theme = useTheme$1();
70284
+ const theme = useTheme();
70285
70285
  const transitionDurationDefault = {
70286
70286
  enter: theme.transitions.duration.enteringScreen,
70287
70287
  exit: theme.transitions.duration.leavingScreen
@@ -72070,7 +72070,7 @@ const TablePaginationActions = /*#__PURE__*/React__namespace.forwardRef(function
72070
72070
  showLastButton
72071
72071
  } = props,
72072
72072
  other = _objectWithoutPropertiesLoose(props, _excluded$q);
72073
- const theme = useTheme$1();
72073
+ const theme = useTheme();
72074
72074
  const handleFirstPageButtonClick = event => {
72075
72075
  onPageChange(event, 0);
72076
72076
  };
@@ -72963,7 +72963,7 @@ const TabScrollButton = /*#__PURE__*/React__namespace.forwardRef(function TabScr
72963
72963
  direction
72964
72964
  } = props,
72965
72965
  other = _objectWithoutPropertiesLoose(props, _excluded$l);
72966
- const theme = useTheme$1();
72966
+ const theme = useTheme();
72967
72967
  const isRtl = theme.direction === 'rtl';
72968
72968
  const ownerState = _extends$1b({
72969
72969
  isRtl
@@ -73213,7 +73213,7 @@ const Tabs = /*#__PURE__*/React__namespace.forwardRef(function Tabs(inProps, ref
73213
73213
  props: inProps,
73214
73214
  name: 'MuiTabs'
73215
73215
  });
73216
- const theme = useTheme$1();
73216
+ const theme = useTheme();
73217
73217
  const isRtl = theme.direction === 'rtl';
73218
73218
  const {
73219
73219
  'aria-label': ariaLabel,
@@ -75725,7 +75725,7 @@ const PickersArrowSwitcher = /*#__PURE__*/React__namespace.forwardRef(function P
75725
75725
  } = props,
75726
75726
  other = _objectWithoutPropertiesLoose(props, _excluded$c);
75727
75727
 
75728
- const theme = useTheme$1();
75728
+ const theme = useTheme();
75729
75729
  const isRtl = theme.direction === 'rtl';
75730
75730
  const leftArrowButtonProps = (componentsProps == null ? void 0 : componentsProps.leftArrowButton) || {};
75731
75731
  const LeftArrowIcon = (components == null ? void 0 : components.LeftArrowIcon) || ArrowLeft;
@@ -76502,7 +76502,7 @@ const MonthPicker = /*#__PURE__*/React__namespace.forwardRef(function MonthPicke
76502
76502
 
76503
76503
  const ownerState = props;
76504
76504
  const classes = useUtilityClasses$9(ownerState);
76505
- const theme = useTheme$2();
76505
+ const theme = useTheme$1();
76506
76506
  const selectedDateOrToday = date != null ? date : now;
76507
76507
  const selectedMonth = React__namespace.useMemo(() => {
76508
76508
  if (date != null) {
@@ -77522,7 +77522,7 @@ function DayPicker(inProps) {
77522
77522
  changeHasFocus(true);
77523
77523
  }
77524
77524
  }, [isDateDisabled, onFocusedDayChange, changeHasFocus]);
77525
- const theme = useTheme$1();
77525
+ const theme = useTheme();
77526
77526
 
77527
77527
  function handleKeyDown(event, day) {
77528
77528
  switch (event.key) {
@@ -78075,7 +78075,7 @@ const YearPickerRoot = styled('div', {
78075
78075
  });
78076
78076
  const YearPicker = /*#__PURE__*/React__namespace.forwardRef(function YearPicker(inProps, ref) {
78077
78077
  const now = useNow();
78078
- const theme = useTheme$1();
78078
+ const theme = useTheme();
78079
78079
  const utils = useUtils();
78080
78080
  const props = useYearPickerDefaultizedProps(inProps, 'MuiYearPicker');
78081
78081
  const {
@@ -81302,7 +81302,6 @@ var pickerStyles = function (theme) { return ({
81302
81302
  var PickerIcon = React__namespace.forwardRef(function (props, ref) { return jsxRuntime.exports.jsx(Icon$1, __assign({}, props, { iconName: "icon_wf_calendar", color: props.disabled ? 'disabled' : 'red-navy', forwardedRef: ref, style: { display: 'flex' } })); });
81303
81303
  var DatePicker = function (_a) {
81304
81304
  var value = _a.value, onChange = _a.onChange, _b = _a.label, label = _b === void 0 ? 'Date Picker' : _b, _c = _a.fluid, fluid = _c === void 0 ? false : _c, _d = _a.disabled, disabled = _d === void 0 ? false : _d, forwardedRef = _a.forwardedRef, props = __rest(_a, ["value", "onChange", "label", "fluid", "disabled", "forwardedRef"]);
81305
- var theme = useTheme();
81306
81305
  return (jsxRuntime.exports.jsx(LocalizationProvider, __assign({ dateAdapter: AdapterDateFns }, { children: jsxRuntime.exports.jsx(StyledDatePicker, { label: label, value: value, desktopModeMediaQuery: '@media (min-width: 1020px)', disabled: disabled, inputProps: props, inputRef: forwardedRef, fluid: fluid === true ? 'true' : 'false', onChange: onChange, components: {
81307
81306
  OpenPickerIcon: function (props) { return jsxRuntime.exports.jsx(PickerIcon, __assign({}, props, { disabled: disabled })); },
81308
81307
  SwitchViewButton: '',