react-better-html 1.1.276 → 1.1.277

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.mjs CHANGED
@@ -3093,7 +3093,18 @@ var useBetterHtmlContext = () => {
3093
3093
  throw new Error(
3094
3094
  "`useBetterHtmlContext()` must be used within a `<BetterHtmlProvider>`. Make sure to add one at the root of your component tree."
3095
3095
  );
3096
- const { alerts, setAlerts, setSideMenuIsCollapsed, setSideMenuIsOpenMobile, plugins, componentsState, ...rest } = context;
3096
+ const {
3097
+ alerts,
3098
+ setAlerts,
3099
+ setLanguage,
3100
+ languages,
3101
+ setLanguages,
3102
+ setSideMenuIsCollapsed,
3103
+ setSideMenuIsOpenMobile,
3104
+ plugins,
3105
+ componentsState,
3106
+ ...rest
3107
+ } = context;
3097
3108
  return {
3098
3109
  ...coreContext,
3099
3110
  ...rest
@@ -3160,6 +3171,8 @@ function BetterHtmlProviderInternalContent({ children }) {
3160
3171
  function BetterHtmlProviderInternal({ config, plugins, children }) {
3161
3172
  const betterCoreContext = useBetterCoreContext5();
3162
3173
  const [alerts, setAlerts] = useState4([]);
3174
+ const [language, setLanguage] = useState4(localStorage.getItem("language") ?? "");
3175
+ const [languages, setLanguages] = useState4({});
3163
3176
  const [sideMenuIsCollapsed, setSideMenuIsCollapsed] = useBooleanState3();
3164
3177
  const [sideMenuIsOpenMobile, setSideMenuIsOpenMobile] = useBooleanState3();
3165
3178
  const [tabGroups, setTabGroups] = useState4([]);
@@ -3172,6 +3185,10 @@ function BetterHtmlProviderInternal({ config, plugins, children }) {
3172
3185
  },
3173
3186
  alerts,
3174
3187
  setAlerts,
3188
+ language,
3189
+ setLanguage,
3190
+ languages,
3191
+ setLanguages,
3175
3192
  sideMenuIsCollapsed,
3176
3193
  setSideMenuIsCollapsed,
3177
3194
  sideMenuIsOpenMobile,
@@ -3189,7 +3206,17 @@ function BetterHtmlProviderInternal({ config, plugins, children }) {
3189
3206
  }
3190
3207
  }
3191
3208
  }),
3192
- [config, alerts, sideMenuIsCollapsed, sideMenuIsOpenMobile, plugins, tabGroups, tabsWithDots]
3209
+ [
3210
+ config,
3211
+ alerts,
3212
+ language,
3213
+ languages,
3214
+ sideMenuIsCollapsed,
3215
+ sideMenuIsOpenMobile,
3216
+ plugins,
3217
+ tabGroups,
3218
+ tabsWithDots
3219
+ ]
3193
3220
  );
3194
3221
  useEffect6(() => {
3195
3222
  if (!plugins) return;
@@ -3417,14 +3444,72 @@ function generateLocalStorage() {
3417
3444
  };
3418
3445
  }
3419
3446
 
3447
+ // src/utils/i18n.tsx
3448
+ import { Fragment as Fragment3 } from "react";
3449
+ import { Fragment as Fragment4, jsx as jsx13 } from "react/jsx-runtime";
3450
+ var missingTranslation = "MISSING_TRANSLATION";
3451
+ function generateI18n(config) {
3452
+ setTimeout(() => {
3453
+ externalBetterHtmlContextValue?.setLanguages(config.languages);
3454
+ const cachedLanguage = localStorage.getItem("language");
3455
+ const language = !cachedLanguage || !Object.keys(config.languages).includes(cachedLanguage) ? config.defaultLanguage : cachedLanguage;
3456
+ setLanguage(language);
3457
+ }, 1);
3458
+ function setLanguage(language) {
3459
+ externalBetterHtmlContextValue?.setLanguage(language);
3460
+ localStorage.setItem("language", language);
3461
+ }
3462
+ function internalI18n(language) {
3463
+ function translate(getString, template) {
3464
+ const words = config.languages[language]?.words;
3465
+ try {
3466
+ const readyString = words ? getString?.(words) ?? missingTranslation : missingTranslation;
3467
+ if (!template) return readyString;
3468
+ const matches = Array.from(readyString.matchAll(/{([^}]+)}/g));
3469
+ if (matches.length === 0) return readyString;
3470
+ const parts = [];
3471
+ let lastIndex = 0;
3472
+ matches.forEach((match, index) => {
3473
+ const [fullMatch, key] = match;
3474
+ const startIndex = match.index;
3475
+ if (startIndex > lastIndex) parts.push(readyString.substring(lastIndex, startIndex));
3476
+ const readyKey = words.templates[key.trim()] ?? fullMatch;
3477
+ const handler = template[key.trim()];
3478
+ parts.push(handler ? /* @__PURE__ */ jsx13(Fragment3, { children: handler(readyKey, index) }, fullMatch) : fullMatch);
3479
+ lastIndex = startIndex + fullMatch.length;
3480
+ });
3481
+ if (lastIndex < readyString.length) parts.push(readyString.substring(lastIndex));
3482
+ return parts;
3483
+ } catch (error) {
3484
+ return /* @__PURE__ */ jsx13(Fragment4, { children: missingTranslation });
3485
+ }
3486
+ }
3487
+ return {
3488
+ t: translate,
3489
+ language,
3490
+ setLanguage
3491
+ };
3492
+ }
3493
+ return {
3494
+ useI18n: () => {
3495
+ const { language } = useBetterHtmlContext();
3496
+ return {
3497
+ ...internalI18n(language ?? config.defaultLanguage)
3498
+ };
3499
+ },
3500
+ ...internalI18n(externalBetterHtmlContextValue?.language ?? config.defaultLanguage),
3501
+ ...config
3502
+ };
3503
+ }
3504
+
3420
3505
  // src/components/PageHolder.tsx
3421
3506
  import { forwardRef as forwardRef8, memo as memo13 } from "react";
3422
3507
  import { useTheme as useTheme14 } from "react-better-core";
3423
- import { jsx as jsx13, jsxs as jsxs9 } from "react/jsx-runtime";
3508
+ import { jsx as jsx14, jsxs as jsxs9 } from "react/jsx-runtime";
3424
3509
  var PageHolderComponent = forwardRef8(function PageHolder({ noMaxContentWidth, children, ...props }, ref) {
3425
3510
  const theme2 = useTheme14();
3426
3511
  const { app } = useBetterHtmlContextInternal();
3427
- return /* @__PURE__ */ jsx13(
3512
+ return /* @__PURE__ */ jsx14(
3428
3513
  Div_default,
3429
3514
  {
3430
3515
  as: "main",
@@ -3468,7 +3553,7 @@ PageHolderComponent.center = forwardRef8(function Center({
3468
3553
  backgroundColor: pageBackgroundColor,
3469
3554
  backgroundImage: pageBackgroundImage,
3470
3555
  children: [
3471
- behindComponent && /* @__PURE__ */ jsx13(
3556
+ behindComponent && /* @__PURE__ */ jsx14(
3472
3557
  Div_default,
3473
3558
  {
3474
3559
  position: "fixed",
@@ -3481,8 +3566,8 @@ PageHolderComponent.center = forwardRef8(function Center({
3481
3566
  children: behindComponent
3482
3567
  }
3483
3568
  ),
3484
- sideComponentPosition === "left" && withSideComponent && /* @__PURE__ */ jsx13(Div_default, { width: "50%" }),
3485
- /* @__PURE__ */ jsx13(Div_default.column, { position: "relative", width: `${withSideComponent ? 50 : 100}%`, alignItems: "center", zIndex: 2, children: /* @__PURE__ */ jsx13(
3569
+ sideComponentPosition === "left" && withSideComponent && /* @__PURE__ */ jsx14(Div_default, { width: "50%" }),
3570
+ /* @__PURE__ */ jsx14(Div_default.column, { position: "relative", width: `${withSideComponent ? 50 : 100}%`, alignItems: "center", zIndex: 2, children: /* @__PURE__ */ jsx14(
3486
3571
  ContentTag,
3487
3572
  {
3488
3573
  width: `calc(100% - ${((props.margin ?? props.marginInline) !== void 0 ? parseFloat((props.margin ?? props.marginInline)?.toString() ?? "") : theme2.styles.space) * 2}px)`,
@@ -3495,8 +3580,8 @@ PageHolderComponent.center = forwardRef8(function Center({
3495
3580
  children
3496
3581
  }
3497
3582
  ) }),
3498
- sideComponentPosition === "right" && withSideComponent && /* @__PURE__ */ jsx13(Div_default, { width: "50%" }),
3499
- withSideComponent && /* @__PURE__ */ jsx13(
3583
+ sideComponentPosition === "right" && withSideComponent && /* @__PURE__ */ jsx14(Div_default, { width: "50%" }),
3584
+ withSideComponent && /* @__PURE__ */ jsx14(
3500
3585
  Div_default,
3501
3586
  {
3502
3587
  position: "fixed",
@@ -3519,7 +3604,7 @@ var PageHolder_default = PageHolder2;
3519
3604
  // src/components/Chip.tsx
3520
3605
  import { forwardRef as forwardRef9, memo as memo14, useCallback as useCallback7 } from "react";
3521
3606
  import { darkenColor, lightenColor, useBetterCoreContext as useBetterCoreContext6, useTheme as useTheme15 } from "react-better-core";
3522
- import { jsx as jsx14, jsxs as jsxs10 } from "react/jsx-runtime";
3607
+ import { jsx as jsx15, jsxs as jsxs10 } from "react/jsx-runtime";
3523
3608
  var borderRadiusOffset = 1.3;
3524
3609
  var ChipComponent = forwardRef9(function Chip({
3525
3610
  text,
@@ -3542,7 +3627,7 @@ var ChipComponent = forwardRef9(function Chip({
3542
3627
  },
3543
3628
  [onClick, onClickWithValue, value]
3544
3629
  );
3545
- return /* @__PURE__ */ jsx14(
3630
+ return /* @__PURE__ */ jsx15(
3546
3631
  Div_default,
3547
3632
  {
3548
3633
  width: "fit-content",
@@ -3557,7 +3642,7 @@ var ChipComponent = forwardRef9(function Chip({
3557
3642
  ref,
3558
3643
  children: /* @__PURE__ */ jsxs10(Div_default.row, { height: "100%", alignItems: "center", gap: theme2.styles.gap, children: [
3559
3644
  beforeText,
3560
- typeof text === "string" ? /* @__PURE__ */ jsx14(Text_default, { color: color ?? theme2.colors.textPrimary, children: text }) : text,
3645
+ typeof text === "string" ? /* @__PURE__ */ jsx15(Text_default, { color: color ?? theme2.colors.textPrimary, children: text }) : text,
3561
3646
  afterText
3562
3647
  ] })
3563
3648
  }
@@ -3567,7 +3652,7 @@ ChipComponent.colored = forwardRef9(function Colored({ color, withWhiteBackgroun
3567
3652
  const theme2 = useTheme15();
3568
3653
  const { colorTheme } = useBetterCoreContext6();
3569
3654
  const readyColor = color ?? theme2.colors.textSecondary;
3570
- const chip = /* @__PURE__ */ jsx14(
3655
+ const chip = /* @__PURE__ */ jsx15(
3571
3656
  ChipComponent,
3572
3657
  {
3573
3658
  color: colorTheme === "light" ? darkenColor(readyColor, 0.7) : lightenColor(readyColor, 0.7),
@@ -3577,7 +3662,7 @@ ChipComponent.colored = forwardRef9(function Colored({ color, withWhiteBackgroun
3577
3662
  ...props
3578
3663
  }
3579
3664
  );
3580
- return withWhiteBackground ? /* @__PURE__ */ jsx14(
3665
+ return withWhiteBackground ? /* @__PURE__ */ jsx15(
3581
3666
  Div_default,
3582
3667
  {
3583
3668
  width: "fit-content",
@@ -3659,7 +3744,7 @@ function Label(labelProps) {
3659
3744
  var Label_default = memo15(Label);
3660
3745
 
3661
3746
  // src/components/Dropdown.tsx
3662
- import { forwardRef as forwardRef10, Fragment as Fragment3, memo as memo16, useCallback as useCallback8, useEffect as useEffect7, useMemo as useMemo4, useRef as useRef4, useState as useState5 } from "react";
3747
+ import { forwardRef as forwardRef10, Fragment as Fragment5, memo as memo16, useCallback as useCallback8, useEffect as useEffect7, useMemo as useMemo4, useRef as useRef4, useState as useState5 } from "react";
3663
3748
  import {
3664
3749
  getPluralWord,
3665
3750
  useBooleanState as useBooleanState4,
@@ -3667,7 +3752,7 @@ import {
3667
3752
  countries,
3668
3753
  useTheme as useTheme17
3669
3754
  } from "react-better-core";
3670
- import { Fragment as Fragment4, jsx as jsx15, jsxs as jsxs12 } from "react/jsx-runtime";
3755
+ import { Fragment as Fragment6, jsx as jsx16, jsxs as jsxs12 } from "react/jsx-runtime";
3671
3756
  import { createElement as createElement2 } from "react";
3672
3757
  var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3673
3758
  const betterHtmlContextInternal = useBetterHtmlContextInternal();
@@ -3695,6 +3780,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3695
3780
  debounceDelay = 0.5,
3696
3781
  debounceIsLoading,
3697
3782
  debounceMinimumSymbolsRequired,
3783
+ withoutArrow,
3698
3784
  withoutClearButton,
3699
3785
  withoutRenderingOptionsWhenClosed,
3700
3786
  onChange,
@@ -3703,6 +3789,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3703
3789
  renderOptionDivider,
3704
3790
  withMultiselect,
3705
3791
  id,
3792
+ textAlign,
3706
3793
  ...props
3707
3794
  } = useComponentsPropsMerger(
3708
3795
  betterHtmlContextInternal.components.dropdown?.style?.default,
@@ -3829,14 +3916,14 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3829
3916
  [options, value]
3830
3917
  );
3831
3918
  const renderedOptions = useMemo4(
3832
- () => /* @__PURE__ */ jsxs12(Fragment4, { children: [
3919
+ () => /* @__PURE__ */ jsxs12(Fragment6, { children: [
3833
3920
  renderOptionDivider ? renderOptionDivider(void 0, filteredOptions[0], -1, 0) : void 0,
3834
3921
  filteredOptions.map((option, index) => {
3835
3922
  const isSelected = withMultiselect ? Array.isArray(value) ? value.includes(option.value) : false : option.value === value;
3836
3923
  const isDisabled = option.disabled;
3837
3924
  const isFocused2 = index === focusedOptionIndex;
3838
- return /* @__PURE__ */ jsxs12(Fragment3, { children: [
3839
- /* @__PURE__ */ jsx15(
3925
+ return /* @__PURE__ */ jsxs12(Fragment5, { children: [
3926
+ /* @__PURE__ */ jsx16(
3840
3927
  Div_default,
3841
3928
  {
3842
3929
  color: isDisabled ? theme2.colors.textSecondary + "80" : isSelected ? theme2.colors.base : theme2.colors.textPrimary,
@@ -3851,7 +3938,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3851
3938
  role: "option",
3852
3939
  "aria-selected": isSelected,
3853
3940
  "aria-disabled": isDisabled,
3854
- children: renderOption ? renderOption(option, index, isSelected) : /* @__PURE__ */ jsx15(Fragment4, { children: !option.renderType || option.renderType === "default" ? /* @__PURE__ */ jsx15(Text_default, { children: option.label }) : option.renderType === "chip" ? /* @__PURE__ */ jsx15(Chip_default, { text: option.label, ...option.chipProps }) : option.renderType === "chip.colored" ? /* @__PURE__ */ jsx15(Chip_default.colored, { text: option.label, withWhiteBackground: true, ...option.chipProps }) : void 0 })
3941
+ children: renderOption ? renderOption(option, index, isSelected) : /* @__PURE__ */ jsx16(Fragment6, { children: !option.renderType || option.renderType === "default" ? /* @__PURE__ */ jsx16(Text_default, { children: option.label }) : option.renderType === "chip" ? /* @__PURE__ */ jsx16(Chip_default, { text: option.label, ...option.chipProps }) : option.renderType === "chip.colored" ? /* @__PURE__ */ jsx16(Chip_default.colored, { text: option.label, withWhiteBackground: true, ...option.chipProps }) : void 0 })
3855
3942
  }
3856
3943
  ),
3857
3944
  renderOptionDivider ? renderOptionDivider(
@@ -3913,7 +4000,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3913
4000
  const displayValue = (withSearch && isFocused ? searchQuery : !Array.isArray(selectedOption) ? selectedOption?.label : void 0) ?? "";
3914
4001
  const withClearButton = isOpen && (Array.isArray(selectedOption) ? selectedOption.length > 0 : selectedOption);
3915
4002
  const readyPlaceholder = placeholder ?? `Select ${!withMultiselect ? "an " : ""}${label?.toLowerCase() ?? getPluralWord("option", withMultiselect ? 2 : 1)}`;
3916
- return /* @__PURE__ */ jsx15(Div_default.column, { width: "100%", position: "relative", userSelect: "none", ...props, children: /* @__PURE__ */ jsx15(
4003
+ return /* @__PURE__ */ jsx16(Div_default.column, { width: "100%", position: "relative", userSelect: "none", ...props, children: /* @__PURE__ */ jsx16(
3917
4004
  InputField_default,
3918
4005
  {
3919
4006
  label,
@@ -3926,6 +4013,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3926
4013
  errorText,
3927
4014
  infoText,
3928
4015
  required: withMultiselect ? (Array.isArray(value) ? value.length > 0 : value !== void 0) ? false : required : required,
4016
+ textAlign,
3929
4017
  name,
3930
4018
  disabled,
3931
4019
  readOnly: !withSearch,
@@ -3935,13 +4023,13 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3935
4023
  placeholder: withSearch ? selectedOption && !Array.isArray(selectedOption) ? selectedOption.label : readyPlaceholder : readyPlaceholder,
3936
4024
  leftIcon,
3937
4025
  autoComplete: "off",
3938
- className: `react-better-html-dropdown${Array.isArray(selectedOption) && selectedOption.length > 0 ? " react-better-html-dropdown-multiselect" : ""}${isOpen ? " react-better-html-dropdown-open" : ""}${isOpenLate ? " react-better-html-dropdown-open-late" : ""}${inputFieldClassName ? ` ${inputFieldClassName}` : ""}`,
4026
+ className: `react-better-html-dropdown${withoutArrow ? " react-better-html-dropdown-without-arrow" : ""}${Array.isArray(selectedOption) && selectedOption.length > 0 ? " react-better-html-dropdown-multiselect" : ""}${isOpen ? " react-better-html-dropdown-open" : ""}${isOpenLate ? " react-better-html-dropdown-open-late" : ""}${inputFieldClassName ? ` ${inputFieldClassName}` : ""}`,
3939
4027
  onClick: !disabled ? withMultiselect ? setIsOpen.setTrue : setIsOpen.toggle : void 0,
3940
4028
  onFocus: setIsFocused.setTrue,
3941
4029
  onBlur: setIsFocused.setFalse,
3942
4030
  onKeyDown: onKeyDownInputField,
3943
4031
  onChangeValue: withSearch ? onChangeValue : void 0,
3944
- insideInputFieldBeforeComponent: Array.isArray(selectedOption) && selectedOption.length > 0 ? /* @__PURE__ */ jsx15(
4032
+ insideInputFieldBeforeComponent: Array.isArray(selectedOption) && selectedOption.length > 0 ? /* @__PURE__ */ jsx16(
3945
4033
  Div_default,
3946
4034
  {
3947
4035
  width: "100%",
@@ -3954,14 +4042,14 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3954
4042
  paddingBlock: theme2.styles.gap,
3955
4043
  paddingInline: (theme2.styles.space + theme2.styles.gap) / 2,
3956
4044
  transition: theme2.styles.transition,
3957
- children: /* @__PURE__ */ jsx15(Div_default.row, { width: "100%", flexWrap: "wrap", gap: theme2.styles.gap, children: selectedOption.map((option) => {
4045
+ children: /* @__PURE__ */ jsx16(Div_default.row, { width: "100%", flexWrap: "wrap", gap: theme2.styles.gap, children: selectedOption.map((option) => {
3958
4046
  const ChipComponentTag = !option.renderType || option.renderType === "default" || option.renderType === "chip" ? Chip_default : option.renderType === "chip.colored" ? Chip_default.colored : Chip_default;
3959
4047
  const withXButton = isFocused || isOpen;
3960
4048
  return /* @__PURE__ */ createElement2(
3961
4049
  ChipComponentTag,
3962
4050
  {
3963
4051
  text: option.label,
3964
- afterText: withXButton && /* @__PURE__ */ jsx15(
4052
+ afterText: withXButton && /* @__PURE__ */ jsx16(
3965
4053
  Button_default.icon,
3966
4054
  {
3967
4055
  icon: "XMark",
@@ -3983,8 +4071,8 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
3983
4071
  }) })
3984
4072
  }
3985
4073
  ) : void 0,
3986
- insideInputFieldAfterComponent: /* @__PURE__ */ jsxs12(Fragment4, { children: [
3987
- /* @__PURE__ */ jsx15(
4074
+ insideInputFieldAfterComponent: /* @__PURE__ */ jsxs12(Fragment6, { children: [
4075
+ /* @__PURE__ */ jsx16(
3988
4076
  Div_default,
3989
4077
  {
3990
4078
  position: "absolute",
@@ -4006,7 +4094,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
4006
4094
  transition: theme2.styles.transition,
4007
4095
  role: "listbox",
4008
4096
  "aria-label": label,
4009
- children: isLoadingDebouncedSearchQuery || debounceIsLoading ? /* @__PURE__ */ jsx15(Div_default, { padding: `${theme2.styles.space / 2}px ${theme2.styles.space + theme2.styles.gap}px`, children: /* @__PURE__ */ jsx15(Loader_default.text, {}) }) : filteredOptions.length ? /* @__PURE__ */ jsx15(Fragment4, { children: (withoutRenderingOptionsWhenClosed ? isOpen || isOpenLate : true) ? renderedOptions : void 0 }) : /* @__PURE__ */ jsx15(Div_default, { padding: `${theme2.styles.space / 2}px ${theme2.styles.space + theme2.styles.gap}px`, children: /* @__PURE__ */ jsx15(Text_default.unknown, { textAlign: "left", children: debounceMinimumSymbolsRequired !== void 0 && searchQuery.length < debounceMinimumSymbolsRequired ? `Enter at least ${debounceMinimumSymbolsRequired} characters` : "No options" }) })
4097
+ children: isLoadingDebouncedSearchQuery || debounceIsLoading ? /* @__PURE__ */ jsx16(Div_default, { padding: `${theme2.styles.space / 2}px ${theme2.styles.space + theme2.styles.gap}px`, children: /* @__PURE__ */ jsx16(Loader_default.text, {}) }) : filteredOptions.length ? /* @__PURE__ */ jsx16(Fragment6, { children: (withoutRenderingOptionsWhenClosed ? isOpen || isOpenLate : true) ? renderedOptions : void 0 }) : /* @__PURE__ */ jsx16(Div_default, { padding: `${theme2.styles.space / 2}px ${theme2.styles.space + theme2.styles.gap}px`, children: /* @__PURE__ */ jsx16(Text_default.unknown, { textAlign: "left", children: debounceMinimumSymbolsRequired !== void 0 && searchQuery.length < debounceMinimumSymbolsRequired ? `Enter at least ${debounceMinimumSymbolsRequired} characters` : "No options" }) })
4010
4098
  }
4011
4099
  ),
4012
4100
  /* @__PURE__ */ jsxs12(
@@ -4024,7 +4112,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
4024
4112
  zIndex: isOpen || isOpenLate ? 1001 : void 0,
4025
4113
  ref: buttonsRef,
4026
4114
  children: [
4027
- !withoutClearButton && /* @__PURE__ */ jsx15(
4115
+ !withoutClearButton && /* @__PURE__ */ jsx16(
4028
4116
  Button_default.icon,
4029
4117
  {
4030
4118
  icon: "XMark",
@@ -4037,7 +4125,7 @@ var DropdownComponent = forwardRef10(function Dropdown(dropdownProps, ref) {
4037
4125
  disabled: !withClearButton
4038
4126
  }
4039
4127
  ),
4040
- /* @__PURE__ */ jsx15(
4128
+ !withoutArrow && /* @__PURE__ */ jsx16(
4041
4129
  Icon_default,
4042
4130
  {
4043
4131
  name: "chevronDown",
@@ -4074,8 +4162,8 @@ DropdownComponent.countries = forwardRef10(function Countries(dropdownProps, ref
4074
4162
  const theme2 = useTheme17();
4075
4163
  const renderOption = useCallback8(
4076
4164
  (option, index, isSelected) => /* @__PURE__ */ jsxs12(Div_default.row, { alignItems: "center", gap: theme2.styles.gap, children: [
4077
- /* @__PURE__ */ jsx15(Image_default, { src: `https://flagcdn.com/w80/${option.data?.code.toString().toLowerCase()}.webp`, width: 20 }),
4078
- /* @__PURE__ */ jsx15(Text_default, { children: option.label })
4165
+ /* @__PURE__ */ jsx16(Image_default, { src: `https://flagcdn.com/w80/${option.data?.code.toString().toLowerCase()}.webp`, width: 20 }),
4166
+ /* @__PURE__ */ jsx16(Text_default, { children: option.label })
4079
4167
  ] }),
4080
4168
  []
4081
4169
  );
@@ -4090,7 +4178,7 @@ DropdownComponent.countries = forwardRef10(function Countries(dropdownProps, ref
4090
4178
  ),
4091
4179
  []
4092
4180
  );
4093
- return /* @__PURE__ */ jsx15(
4181
+ return /* @__PURE__ */ jsx16(
4094
4182
  DropdownComponent,
4095
4183
  {
4096
4184
  placeholder: "Select a country",
@@ -4102,15 +4190,63 @@ DropdownComponent.countries = forwardRef10(function Countries(dropdownProps, ref
4102
4190
  }
4103
4191
  );
4104
4192
  });
4193
+ DropdownComponent.language = forwardRef10(function Countries2({ isSmall, ...dropdownProps }, ref) {
4194
+ const betterHtmlContextInternal = useBetterHtmlContextInternal();
4195
+ const { inputFieldClassName, ...props } = useComponentsPropsMerger(
4196
+ betterHtmlContextInternal.components.dropdown?.style?.language,
4197
+ dropdownProps
4198
+ );
4199
+ const theme2 = useTheme17();
4200
+ const renderOption = useCallback8(
4201
+ (option, index, isSelected) => /* @__PURE__ */ jsxs12(Div_default.row, { alignItems: "center", justifyContent: isSmall ? "center" : void 0, gap: theme2.styles.gap, children: [
4202
+ /* @__PURE__ */ jsx16(Image_default, { src: `https://flagcdn.com/w80/${option.data?.flagCode.toString().toLowerCase()}.webp`, width: 20 }),
4203
+ !isSmall && /* @__PURE__ */ jsx16(Text_default, { children: option.label })
4204
+ ] }),
4205
+ [isSmall]
4206
+ );
4207
+ const onChange = useCallback8((value) => {
4208
+ betterHtmlContextInternal.setLanguage(value);
4209
+ localStorage.setItem("language", value);
4210
+ }, []);
4211
+ const options = useMemo4(
4212
+ () => Object.values(betterHtmlContextInternal.languages).map(
4213
+ (data) => ({
4214
+ value: data.code,
4215
+ label: isSmall ? data.code.toUpperCase() : data.name,
4216
+ data,
4217
+ searchValues: [data.code]
4218
+ })
4219
+ ),
4220
+ []
4221
+ );
4222
+ return /* @__PURE__ */ jsx16(
4223
+ DropdownComponent,
4224
+ {
4225
+ placeholder: isSmall ? "lang" : "Select a language",
4226
+ withoutClearButton: true,
4227
+ withoutArrow: isSmall,
4228
+ width: isSmall ? 60 : void 0,
4229
+ textAlign: isSmall ? "center" : void 0,
4230
+ inputFieldClassName: `${inputFieldClassName}${isSmall ? " react-better-html-dropdown-no-horizontal-padding" : ""}`,
4231
+ options,
4232
+ renderOption,
4233
+ value: betterHtmlContextInternal.language,
4234
+ onChange,
4235
+ ref,
4236
+ ...props
4237
+ }
4238
+ );
4239
+ });
4105
4240
  var Dropdown2 = memo16(DropdownComponent);
4106
4241
  Dropdown2.countries = DropdownComponent.countries;
4242
+ Dropdown2.language = DropdownComponent.language;
4107
4243
  var Dropdown_default = Dropdown2;
4108
4244
 
4109
4245
  // src/components/Calendar.tsx
4110
4246
  import { useCallback as useCallback9, useMemo as useMemo5, useState as useState6, memo as memo17, useEffect as useEffect8, useId } from "react";
4111
4247
  import { useTheme as useTheme18 } from "react-better-core";
4112
4248
  import styled9 from "styled-components";
4113
- import { jsx as jsx16, jsxs as jsxs13 } from "react/jsx-runtime";
4249
+ import { jsx as jsx17, jsxs as jsxs13 } from "react/jsx-runtime";
4114
4250
  var getMonthName = (month, short = false) => {
4115
4251
  return [
4116
4252
  short ? "Jan" : "January",
@@ -4226,28 +4362,28 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4226
4362
  }, [value]);
4227
4363
  return /* @__PURE__ */ jsxs13(Div_default.column, { width: "100%", maxWidth: 320, gap: theme2.styles.gap, padding: theme2.styles.space / 2, userSelect: "none", children: [
4228
4364
  /* @__PURE__ */ jsxs13(Div_default.row, { width: "100%", justifyContent: "space-between", alignItems: "center", children: [
4229
- /* @__PURE__ */ jsx16(Button_default.icon, { icon: "chevronLeft", onClick: onClickPreviousMonthButton }),
4365
+ /* @__PURE__ */ jsx17(Button_default.icon, { icon: "chevronLeft", onClick: onClickPreviousMonthButton }),
4230
4366
  /* @__PURE__ */ jsxs13(Div_default.row, { alignItems: "center", gap: 4, children: [
4231
- /* @__PURE__ */ jsx16(Text_default, { fontWeight: 700, children: getMonthName(currentMonth) }),
4232
- /* @__PURE__ */ jsx16(SelectWrapperComponent, { children: /* @__PURE__ */ jsxs13(Div_default.row, { position: "relative", alignItems: "center", gap: 2, children: [
4233
- /* @__PURE__ */ jsx16(Text_default, { fontWeight: 700, children: currentYear }),
4234
- /* @__PURE__ */ jsx16(Icon_default, { name: "chevronDown", size: 12 }),
4235
- /* @__PURE__ */ jsx16(
4367
+ /* @__PURE__ */ jsx17(Text_default, { fontWeight: 700, children: getMonthName(currentMonth) }),
4368
+ /* @__PURE__ */ jsx17(SelectWrapperComponent, { children: /* @__PURE__ */ jsxs13(Div_default.row, { position: "relative", alignItems: "center", gap: 2, children: [
4369
+ /* @__PURE__ */ jsx17(Text_default, { fontWeight: 700, children: currentYear }),
4370
+ /* @__PURE__ */ jsx17(Icon_default, { name: "chevronDown", size: 12 }),
4371
+ /* @__PURE__ */ jsx17(
4236
4372
  SelectComponent,
4237
4373
  {
4238
4374
  theme: theme2,
4239
4375
  value: currentYear,
4240
4376
  onChange: onChangeYearSelect,
4241
4377
  id: internalYearSelectId,
4242
- children: yearsRange.map((year) => /* @__PURE__ */ jsx16("option", { value: year, children: year }, year))
4378
+ children: yearsRange.map((year) => /* @__PURE__ */ jsx17("option", { value: year, children: year }, year))
4243
4379
  }
4244
4380
  )
4245
4381
  ] }) })
4246
4382
  ] }),
4247
- /* @__PURE__ */ jsx16(Button_default.icon, { icon: "chevronRight", onClick: onClickNextMonthButton })
4383
+ /* @__PURE__ */ jsx17(Button_default.icon, { icon: "chevronRight", onClick: onClickNextMonthButton })
4248
4384
  ] }),
4249
4385
  /* @__PURE__ */ jsxs13(Div_default.grid, { width: "100%", gridTemplateColumns: "repeat(7, 1fr)", gap: theme2.styles.gap / 2, children: [
4250
- weekDaysIndex.map((day) => /* @__PURE__ */ jsx16(Div_default.row, { alignItems: "center", justifyContent: "center", children: /* @__PURE__ */ jsx16(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", children: getWeekDayName(day, true) }) }, day)),
4386
+ weekDaysIndex.map((day) => /* @__PURE__ */ jsx17(Div_default.row, { alignItems: "center", justifyContent: "center", children: /* @__PURE__ */ jsx17(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", children: getWeekDayName(day, true) }) }, day)),
4251
4387
  days.map((day, index) => {
4252
4388
  const thisDayDate = new Date(currentYear, currentMonth, day);
4253
4389
  const isSelected = day !== void 0 && day === currentDate?.getDate() && currentMonth === currentDate.getMonth() && currentYear === currentDate.getFullYear();
@@ -4271,7 +4407,7 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4271
4407
  value: day,
4272
4408
  onClickWithValue: !isDisabled ? onClickDay : void 0,
4273
4409
  children: [
4274
- day && /* @__PURE__ */ jsx16(
4410
+ day && /* @__PURE__ */ jsx17(
4275
4411
  Text_default,
4276
4412
  {
4277
4413
  fontSize: 14,
@@ -4280,7 +4416,7 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4280
4416
  children: day
4281
4417
  }
4282
4418
  ),
4283
- isDisabled && /* @__PURE__ */ jsx16(
4419
+ isDisabled && /* @__PURE__ */ jsx17(
4284
4420
  Div_default,
4285
4421
  {
4286
4422
  position: "absolute",
@@ -4300,7 +4436,7 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4300
4436
  })
4301
4437
  ] }),
4302
4438
  /* @__PURE__ */ jsxs13(Div_default.row, { width: "100%", justifyContent: "space-between", alignItems: "center", children: [
4303
- /* @__PURE__ */ jsx16(Div_default, { isTabAccessed: true, cursor: "pointer", onClick: onClickClear, children: /* @__PURE__ */ jsx16(
4439
+ /* @__PURE__ */ jsx17(Div_default, { isTabAccessed: true, cursor: "pointer", onClick: onClickClear, children: /* @__PURE__ */ jsx17(
4304
4440
  Text_default,
4305
4441
  {
4306
4442
  fontSize: 14,
@@ -4310,7 +4446,7 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4310
4446
  children: "Clear"
4311
4447
  }
4312
4448
  ) }),
4313
- /* @__PURE__ */ jsx16(Div_default, { isTabAccessed: true, cursor: "pointer", onClick: onClickToday, children: /* @__PURE__ */ jsx16(
4449
+ /* @__PURE__ */ jsx17(Div_default, { isTabAccessed: true, cursor: "pointer", onClick: onClickToday, children: /* @__PURE__ */ jsx17(
4314
4450
  Text_default,
4315
4451
  {
4316
4452
  fontSize: 14,
@@ -4326,7 +4462,7 @@ function Calendar({ value, minDate, maxDate, onChange }) {
4326
4462
  var Calendar_default = memo17(Calendar);
4327
4463
 
4328
4464
  // src/components/InputField.tsx
4329
- import { jsx as jsx17, jsxs as jsxs14 } from "react/jsx-runtime";
4465
+ import { jsx as jsx18, jsxs as jsxs14 } from "react/jsx-runtime";
4330
4466
  var buttonWidth = 50;
4331
4467
  var colorPickerSpacing = 4;
4332
4468
  var colorPickerColorWidth = 12 + 27 + colorPickerSpacing;
@@ -4436,6 +4572,15 @@ var InputElement = styled10.input.withConfig({
4436
4572
  &.react-better-html-dropdown {
4437
4573
  padding-right: ${(props) => props.theme.styles.space + 16 + props.theme.styles.space - props.theme.styles.borderWidth}px;
4438
4574
 
4575
+ &.react-better-html-dropdown-without-arrow {
4576
+ padding-right: ${(props) => props.theme.styles.space}px;
4577
+ }
4578
+
4579
+ &.react-better-html-dropdown-no-horizontal-padding {
4580
+ padding-left: 0px;
4581
+ padding-right: 0px;
4582
+ }
4583
+
4439
4584
  &.react-better-html-dropdown-multiselect {
4440
4585
  border-top: none;
4441
4586
  border-top-left-radius: 0px;
@@ -4573,7 +4718,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4573
4718
  }, [withDebounce, onChangeValue, debouncedValue]);
4574
4719
  const readyId = id ?? internalId;
4575
4720
  return /* @__PURE__ */ jsxs14(Div_default.column, { width: "100%", gap: labelGap ?? theme2.styles.gap / 2, ...excludeStyle, children: [
4576
- label && /* @__PURE__ */ jsx17(
4721
+ label && /* @__PURE__ */ jsx18(
4577
4722
  Label_default,
4578
4723
  {
4579
4724
  text: label,
@@ -4588,7 +4733,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4588
4733
  }
4589
4734
  ),
4590
4735
  /* @__PURE__ */ jsxs14(Div_default.row, { alignItems: "stretch", width: "100%", children: [
4591
- prefix && /* @__PURE__ */ jsx17(
4736
+ prefix && /* @__PURE__ */ jsx18(
4592
4737
  Div_default.row,
4593
4738
  {
4594
4739
  alignItems: "center",
@@ -4605,7 +4750,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4605
4750
  /* @__PURE__ */ jsxs14(Div_default, { position: "relative", width: "100%", height: "fit-content", ref: holderRef, children: [
4606
4751
  insideInputFieldBeforeComponent,
4607
4752
  /* @__PURE__ */ jsxs14(Div_default, { position: "relative", width: "100%", height: "fit-content", children: [
4608
- leftIcon && /* @__PURE__ */ jsx17(
4753
+ leftIcon && /* @__PURE__ */ jsx18(
4609
4754
  Icon_default,
4610
4755
  {
4611
4756
  name: leftIcon,
@@ -4617,7 +4762,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4617
4762
  zIndex: leftIconZIndex
4618
4763
  }
4619
4764
  ),
4620
- /* @__PURE__ */ jsx17(
4765
+ /* @__PURE__ */ jsx18(
4621
4766
  InputElement,
4622
4767
  {
4623
4768
  theme: theme2,
@@ -4639,7 +4784,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4639
4784
  ref
4640
4785
  }
4641
4786
  ),
4642
- rightIcon ? onClickRightIcon ? /* @__PURE__ */ jsx17(
4787
+ rightIcon ? onClickRightIcon ? /* @__PURE__ */ jsx18(
4643
4788
  Button_default.icon,
4644
4789
  {
4645
4790
  icon: rightIcon,
@@ -4649,7 +4794,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4649
4794
  transform: "translateY(-50%)",
4650
4795
  onClick: onClickRightIcon
4651
4796
  }
4652
- ) : /* @__PURE__ */ jsx17(
4797
+ ) : /* @__PURE__ */ jsx18(
4653
4798
  Icon_default,
4654
4799
  {
4655
4800
  name: rightIcon,
@@ -4663,7 +4808,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4663
4808
  insideInputFieldAfterComponent
4664
4809
  ] })
4665
4810
  ] }),
4666
- suffix && /* @__PURE__ */ jsx17(
4811
+ suffix && /* @__PURE__ */ jsx18(
4667
4812
  Div_default.row,
4668
4813
  {
4669
4814
  alignItems: "center",
@@ -4678,7 +4823,7 @@ var InputFieldComponent = forwardRef11(function InputField(inputFieldProps, ref)
4678
4823
  }
4679
4824
  )
4680
4825
  ] }),
4681
- (errorText || infoText) && /* @__PURE__ */ jsx17(
4826
+ (errorText || infoText) && /* @__PURE__ */ jsx18(
4682
4827
  Text_default,
4683
4828
  {
4684
4829
  as: "span",
@@ -4730,7 +4875,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4730
4875
  );
4731
4876
  const readyId = id ?? internalId;
4732
4877
  return /* @__PURE__ */ jsxs14(Div_default.column, { gap: labelGap ?? theme2.styles.gap / 2, children: [
4733
- label && /* @__PURE__ */ jsx17(
4878
+ label && /* @__PURE__ */ jsx18(
4734
4879
  Label_default,
4735
4880
  {
4736
4881
  text: label,
@@ -4745,7 +4890,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4745
4890
  }
4746
4891
  ),
4747
4892
  /* @__PURE__ */ jsxs14(Div_default, { position: "relative", width: "100%", children: [
4748
- leftIcon && /* @__PURE__ */ jsx17(
4893
+ leftIcon && /* @__PURE__ */ jsx18(
4749
4894
  Icon_default,
4750
4895
  {
4751
4896
  name: leftIcon,
@@ -4756,7 +4901,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4756
4901
  pointerEvents: "none"
4757
4902
  }
4758
4903
  ),
4759
- /* @__PURE__ */ jsx17(
4904
+ /* @__PURE__ */ jsx18(
4760
4905
  TextareaElement,
4761
4906
  {
4762
4907
  theme: theme2,
@@ -4776,7 +4921,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4776
4921
  ref
4777
4922
  }
4778
4923
  ),
4779
- rightIcon ? onClickRightIcon ? /* @__PURE__ */ jsx17(
4924
+ rightIcon ? onClickRightIcon ? /* @__PURE__ */ jsx18(
4780
4925
  Button_default.icon,
4781
4926
  {
4782
4927
  icon: rightIcon,
@@ -4786,7 +4931,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4786
4931
  transform: "translateY(-50%)",
4787
4932
  onClick: onClickRightIcon
4788
4933
  }
4789
- ) : /* @__PURE__ */ jsx17(
4934
+ ) : /* @__PURE__ */ jsx18(
4790
4935
  Icon_default,
4791
4936
  {
4792
4937
  name: rightIcon,
@@ -4798,7 +4943,7 @@ InputFieldComponent.multiline = forwardRef11(function Multiline(inputFieldProps,
4798
4943
  }
4799
4944
  ) : void 0
4800
4945
  ] }),
4801
- (errorText || infoText) && /* @__PURE__ */ jsx17(
4946
+ (errorText || infoText) && /* @__PURE__ */ jsx18(
4802
4947
  Text_default,
4803
4948
  {
4804
4949
  as: "span",
@@ -4817,7 +4962,7 @@ InputFieldComponent.email = forwardRef11(function Email(inputFieldProps, ref) {
4817
4962
  betterHtmlContextInternal.components.inputField?.style?.email,
4818
4963
  inputFieldProps
4819
4964
  );
4820
- return /* @__PURE__ */ jsx17(
4965
+ return /* @__PURE__ */ jsx18(
4821
4966
  InputFieldComponent,
4822
4967
  {
4823
4968
  type: "email",
@@ -4837,7 +4982,7 @@ InputFieldComponent.password = forwardRef11(function Password(inputFieldProps, r
4837
4982
  inputFieldProps
4838
4983
  );
4839
4984
  const [isPassword, setIsPassword] = useBooleanState5(true);
4840
- return /* @__PURE__ */ jsx17(
4985
+ return /* @__PURE__ */ jsx18(
4841
4986
  InputFieldComponent,
4842
4987
  {
4843
4988
  type: isPassword ? "password" : "text",
@@ -4884,7 +5029,7 @@ InputFieldComponent.search = forwardRef11(function Search(inputFieldProps, ref)
4884
5029
  const onClickRightIcon = useCallback10(() => {
4885
5030
  onChangeValueElement("");
4886
5031
  }, [onChangeValueElement]);
4887
- return /* @__PURE__ */ jsx17(
5032
+ return /* @__PURE__ */ jsx18(
4888
5033
  InputFieldComponent,
4889
5034
  {
4890
5035
  leftIcon: "magnifyingGlass",
@@ -4920,8 +5065,8 @@ InputFieldComponent.phoneNumber = forwardRef11(function PhoneNumber(inputFieldPr
4920
5065
  const [inputFieldValue, setInputFieldValue] = useState7(value?.toString() ?? "");
4921
5066
  const renderOption = useCallback10(
4922
5067
  (option, index, isSelected) => /* @__PURE__ */ jsxs14(Div_default.row, { alignItems: "center", gap: theme2.styles.gap, children: [
4923
- /* @__PURE__ */ jsx17(Image_default, { src: `https://flagcdn.com/w80/${option.data?.code.toString().toLowerCase()}.webp`, width: 20 }),
4924
- /* @__PURE__ */ jsx17(Text_default, { children: option.label })
5068
+ /* @__PURE__ */ jsx18(Image_default, { src: `https://flagcdn.com/w80/${option.data?.code.toString().toLowerCase()}.webp`, width: 20 }),
5069
+ /* @__PURE__ */ jsx18(Text_default, { children: option.label })
4925
5070
  ] }),
4926
5071
  []
4927
5072
  );
@@ -4973,7 +5118,7 @@ InputFieldComponent.phoneNumber = forwardRef11(function PhoneNumber(inputFieldPr
4973
5118
  const readyId = id ?? internalId;
4974
5119
  const readyLabel = betterHtmlContextInternal.components.inputField?.style?.phoneNumber?.label ?? label;
4975
5120
  return /* @__PURE__ */ jsxs14(Div_default.column, { width: "100%", gap: theme2.styles.gap / 2, children: [
4976
- readyLabel && /* @__PURE__ */ jsx17(
5121
+ readyLabel && /* @__PURE__ */ jsx18(
4977
5122
  Label_default,
4978
5123
  {
4979
5124
  text: readyLabel,
@@ -4988,7 +5133,7 @@ InputFieldComponent.phoneNumber = forwardRef11(function PhoneNumber(inputFieldPr
4988
5133
  }
4989
5134
  ),
4990
5135
  /* @__PURE__ */ jsxs14(Div_default.row, { children: [
4991
- /* @__PURE__ */ jsx17(
5136
+ /* @__PURE__ */ jsx18(
4992
5137
  Dropdown_default,
4993
5138
  {
4994
5139
  options,
@@ -5006,7 +5151,7 @@ InputFieldComponent.phoneNumber = forwardRef11(function PhoneNumber(inputFieldPr
5006
5151
  withoutRenderingOptionsWhenClosed: true
5007
5152
  }
5008
5153
  ),
5009
- /* @__PURE__ */ jsx17(
5154
+ /* @__PURE__ */ jsx18(
5010
5155
  InputFieldComponent,
5011
5156
  {
5012
5157
  ...betterHtmlContextInternal.components.inputField?.style?.phoneNumber,
@@ -5046,7 +5191,7 @@ InputFieldComponent.date = forwardRef11(function Date2({ minDate, maxDate, dropd
5046
5191
  },
5047
5192
  [restInputFieldProps.onChangeValue]
5048
5193
  );
5049
- return /* @__PURE__ */ jsx17(
5194
+ return /* @__PURE__ */ jsx18(
5050
5195
  InputFieldComponent,
5051
5196
  {
5052
5197
  ...betterHtmlContextInternal.components.inputField?.style?.date,
@@ -5066,7 +5211,7 @@ InputFieldComponent.date = forwardRef11(function Date2({ minDate, maxDate, dropd
5066
5211
  userSelect: "none",
5067
5212
  ...insideInputFieldComponentProps,
5068
5213
  children: [
5069
- /* @__PURE__ */ jsx17(
5214
+ /* @__PURE__ */ jsx18(
5070
5215
  Div_default,
5071
5216
  {
5072
5217
  position: "absolute",
@@ -5079,7 +5224,7 @@ InputFieldComponent.date = forwardRef11(function Date2({ minDate, maxDate, dropd
5079
5224
  transition: theme2.styles.transition
5080
5225
  }
5081
5226
  ),
5082
- /* @__PURE__ */ jsx17(Calendar_default, { value: internalValue, minDate, maxDate, onChange })
5227
+ /* @__PURE__ */ jsx18(Calendar_default, { value: internalValue, minDate, maxDate, onChange })
5083
5228
  ]
5084
5229
  }
5085
5230
  ) : void 0,
@@ -5189,7 +5334,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5189
5334
  const valueHour = parseInt(internalValue?.toString().split("T")?.[1]?.split(":")?.[0]).toString();
5190
5335
  const valueMinute = parseInt(internalValue?.toString().split("T")?.[1]?.split(":")?.[1]).toString();
5191
5336
  const topSpacing = 32 + theme2.styles.space / 2 + theme2.styles.gap;
5192
- return /* @__PURE__ */ jsx17(
5337
+ return /* @__PURE__ */ jsx18(
5193
5338
  InputFieldComponent,
5194
5339
  {
5195
5340
  ...betterHtmlContextInternal.components.inputField?.style?.dateTime,
@@ -5210,7 +5355,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5210
5355
  userSelect: "none",
5211
5356
  ...insideInputFieldComponentProps,
5212
5357
  children: [
5213
- /* @__PURE__ */ jsx17(
5358
+ /* @__PURE__ */ jsx18(
5214
5359
  Div_default,
5215
5360
  {
5216
5361
  position: "absolute",
@@ -5224,7 +5369,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5224
5369
  }
5225
5370
  ),
5226
5371
  /* @__PURE__ */ jsxs14(Div_default.row, { gap: theme2.styles.space, children: [
5227
- /* @__PURE__ */ jsx17(Calendar_default, { value: internalValue, minDate, maxDate, onChange }),
5372
+ /* @__PURE__ */ jsx18(Calendar_default, { value: internalValue, minDate, maxDate, onChange }),
5228
5373
  /* @__PURE__ */ jsxs14(
5229
5374
  Div_default.row,
5230
5375
  {
@@ -5235,8 +5380,8 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5235
5380
  paddingRight: theme2.styles.space / 2,
5236
5381
  children: [
5237
5382
  /* @__PURE__ */ jsxs14(Div_default, { height: "100%", children: [
5238
- /* @__PURE__ */ jsx17(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", marginBottom: theme2.styles.gap / 2, children: "H" }),
5239
- /* @__PURE__ */ jsx17(
5383
+ /* @__PURE__ */ jsx18(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", marginBottom: theme2.styles.gap / 2, children: "H" }),
5384
+ /* @__PURE__ */ jsx18(
5240
5385
  Div_default,
5241
5386
  {
5242
5387
  className: "react-better-html-no-scrollbar",
@@ -5246,7 +5391,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5246
5391
  tabIndex: -1,
5247
5392
  children: readyHours.map((hour) => {
5248
5393
  const isSelected = hour.toString() === valueHour;
5249
- return /* @__PURE__ */ jsx17(
5394
+ return /* @__PURE__ */ jsx18(
5250
5395
  Div_default.row,
5251
5396
  {
5252
5397
  alignItems: "center",
@@ -5260,7 +5405,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5260
5405
  value: hour,
5261
5406
  onClickWithValue: onClickHour,
5262
5407
  ref: isSelected ? selectedHourRef : void 0,
5263
- children: /* @__PURE__ */ jsx17(Text_default, { textAlign: "center", children: hour.toString().padStart(2, "0") })
5408
+ children: /* @__PURE__ */ jsx18(Text_default, { textAlign: "center", children: hour.toString().padStart(2, "0") })
5264
5409
  },
5265
5410
  hour
5266
5411
  );
@@ -5269,8 +5414,8 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5269
5414
  )
5270
5415
  ] }),
5271
5416
  /* @__PURE__ */ jsxs14(Div_default, { height: "100%", children: [
5272
- /* @__PURE__ */ jsx17(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", marginBottom: theme2.styles.gap / 2, children: "M" }),
5273
- /* @__PURE__ */ jsx17(
5417
+ /* @__PURE__ */ jsx18(Text_default, { fontSize: 14, fontWeight: 700, textAlign: "center", marginBottom: theme2.styles.gap / 2, children: "M" }),
5418
+ /* @__PURE__ */ jsx18(
5274
5419
  Div_default,
5275
5420
  {
5276
5421
  className: "react-better-html-no-scrollbar",
@@ -5280,7 +5425,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5280
5425
  tabIndex: -1,
5281
5426
  children: readyMinutes.map((minute) => {
5282
5427
  const isSelected = minute.toString() === valueMinute;
5283
- return /* @__PURE__ */ jsx17(
5428
+ return /* @__PURE__ */ jsx18(
5284
5429
  Div_default.row,
5285
5430
  {
5286
5431
  alignItems: "center",
@@ -5294,7 +5439,7 @@ InputFieldComponent.dateTime = forwardRef11(function DateTime({
5294
5439
  value: minute,
5295
5440
  onClickWithValue: onClickMinute,
5296
5441
  ref: isSelected ? selectedMinuteRef : void 0,
5297
- children: /* @__PURE__ */ jsx17(Text_default, { textAlign: "center", children: minute.toString().padStart(2, "0") })
5442
+ children: /* @__PURE__ */ jsx18(Text_default, { textAlign: "center", children: minute.toString().padStart(2, "0") })
5298
5443
  },
5299
5444
  minute
5300
5445
  );
@@ -5400,7 +5545,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5400
5545
  }, [isOpen]);
5401
5546
  const valueHour = parseInt(internalValue?.toString().split(":")?.[0]).toString();
5402
5547
  const valueMinute = parseInt(internalValue?.toString().split(":")?.[1]).toString();
5403
- return /* @__PURE__ */ jsx17(
5548
+ return /* @__PURE__ */ jsx18(
5404
5549
  InputFieldComponent,
5405
5550
  {
5406
5551
  ...betterHtmlContextInternal.components.inputField?.style?.time,
@@ -5422,7 +5567,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5422
5567
  userSelect: "none",
5423
5568
  ...insideInputFieldComponentProps,
5424
5569
  children: [
5425
- /* @__PURE__ */ jsx17(
5570
+ /* @__PURE__ */ jsx18(
5426
5571
  Div_default,
5427
5572
  {
5428
5573
  position: "absolute",
@@ -5436,7 +5581,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5436
5581
  }
5437
5582
  ),
5438
5583
  /* @__PURE__ */ jsxs14(Div_default.row, { height: "100%", children: [
5439
- /* @__PURE__ */ jsx17(
5584
+ /* @__PURE__ */ jsx18(
5440
5585
  Div_default,
5441
5586
  {
5442
5587
  className: "react-better-html-no-scrollbar",
@@ -5447,7 +5592,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5447
5592
  children: readyHours.map((hour) => {
5448
5593
  const isSelected = hour.toString() === valueHour;
5449
5594
  const isDisabled = minHours && hour < minHours || maxHours && hour > maxHours;
5450
- return /* @__PURE__ */ jsx17(
5595
+ return /* @__PURE__ */ jsx18(
5451
5596
  Div_default.row,
5452
5597
  {
5453
5598
  alignItems: "center",
@@ -5461,14 +5606,14 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5461
5606
  value: hour,
5462
5607
  onClickWithValue: !isDisabled ? onClickHour : void 0,
5463
5608
  ref: isSelected ? selectedHourRef : void 0,
5464
- children: /* @__PURE__ */ jsx17(Text_default, { textAlign: "center", children: hour.toString().padStart(2, "0") })
5609
+ children: /* @__PURE__ */ jsx18(Text_default, { textAlign: "center", children: hour.toString().padStart(2, "0") })
5465
5610
  },
5466
5611
  hour
5467
5612
  );
5468
5613
  })
5469
5614
  }
5470
5615
  ),
5471
- /* @__PURE__ */ jsx17(
5616
+ /* @__PURE__ */ jsx18(
5472
5617
  Div_default,
5473
5618
  {
5474
5619
  className: "react-better-html-no-scrollbar",
@@ -5480,7 +5625,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5480
5625
  const isSelected = minute.toString() === valueMinute;
5481
5626
  const currentHour = parseInt(valueHour);
5482
5627
  const isDisabled = minHours !== void 0 && minMinutes !== void 0 && currentHour === minHours && minute < minMinutes || maxHours !== void 0 && maxMinutes !== void 0 && currentHour === maxHours && minute > maxMinutes;
5483
- return /* @__PURE__ */ jsx17(
5628
+ return /* @__PURE__ */ jsx18(
5484
5629
  Div_default.row,
5485
5630
  {
5486
5631
  alignItems: "center",
@@ -5494,7 +5639,7 @@ InputFieldComponent.time = forwardRef11(function Time({ hoursToRender, minutesTo
5494
5639
  value: minute,
5495
5640
  onClickWithValue: !isDisabled ? onClickMinute : void 0,
5496
5641
  ref: isSelected ? selectedMinuteRef : void 0,
5497
- children: /* @__PURE__ */ jsx17(Text_default, { textAlign: "center", children: minute.toString().padStart(2, "0") })
5642
+ children: /* @__PURE__ */ jsx18(Text_default, { textAlign: "center", children: minute.toString().padStart(2, "0") })
5498
5643
  },
5499
5644
  minute
5500
5645
  );
@@ -5532,12 +5677,12 @@ InputFieldComponent.color = forwardRef11(function Color4({ ...inputFieldProps },
5532
5677
  if (value === void 0) return;
5533
5678
  setInputFieldValue(value);
5534
5679
  }, [value]);
5535
- return /* @__PURE__ */ jsx17(
5680
+ return /* @__PURE__ */ jsx18(
5536
5681
  InputFieldComponent,
5537
5682
  {
5538
5683
  ...betterHtmlContextInternal.components.inputField?.style?.color,
5539
5684
  type: "color",
5540
- insideInputFieldAfterComponent: /* @__PURE__ */ jsx17(
5685
+ insideInputFieldAfterComponent: /* @__PURE__ */ jsx18(
5541
5686
  Div_default.row,
5542
5687
  {
5543
5688
  position: "absolute",
@@ -5549,7 +5694,7 @@ InputFieldComponent.color = forwardRef11(function Color4({ ...inputFieldProps },
5549
5694
  pointerEvents: "none",
5550
5695
  userSelect: "none",
5551
5696
  paddingLeft: colorPickerColorWidth,
5552
- children: /* @__PURE__ */ jsx17(Text_default, { children: inputFieldValue })
5697
+ children: /* @__PURE__ */ jsx18(Text_default, { children: inputFieldValue })
5553
5698
  }
5554
5699
  ),
5555
5700
  value: inputFieldValue,
@@ -5575,7 +5720,7 @@ var InputField_default = InputField2;
5575
5720
  import { forwardRef as forwardRef12, useCallback as useCallback11, useId as useId3, useState as useState8 } from "react";
5576
5721
  import { useBetterCoreContext as useBetterCoreContext8, useBooleanState as useBooleanState6, useTheme as useTheme20 } from "react-better-core";
5577
5722
  import styled11, { css as css4 } from "styled-components";
5578
- import { jsx as jsx18, jsxs as jsxs15 } from "react/jsx-runtime";
5723
+ import { jsx as jsx19, jsxs as jsxs15 } from "react/jsx-runtime";
5579
5724
  var componentSize = 26;
5580
5725
  var switchComponentBallGap = 3;
5581
5726
  var switchComponentMouseDownDifference = 4;
@@ -5720,7 +5865,7 @@ var ToggleInputComponent = forwardRef12(function ToggleInput({
5720
5865
  }, [checked, controlledChecked, onChange, value]);
5721
5866
  const readyId = id ?? internalId;
5722
5867
  return /* @__PURE__ */ jsxs15(Div_default.column, { gap: labelGap ?? theme2.styles.gap, ...excludeStyle, children: [
5723
- label && /* @__PURE__ */ jsx18(
5868
+ label && /* @__PURE__ */ jsx19(
5724
5869
  Label_default,
5725
5870
  {
5726
5871
  text: label,
@@ -5736,7 +5881,7 @@ var ToggleInputComponent = forwardRef12(function ToggleInput({
5736
5881
  ),
5737
5882
  /* @__PURE__ */ jsxs15(Div_default.row, { alignItems: "center", gap: theme2.styles.gap, children: [
5738
5883
  /* @__PURE__ */ jsxs15(Div_default.row, { position: "relative", alignItems: "center", children: [
5739
- /* @__PURE__ */ jsx18(
5884
+ /* @__PURE__ */ jsx19(
5740
5885
  InputElement2,
5741
5886
  {
5742
5887
  theme: theme2,
@@ -5754,7 +5899,7 @@ var ToggleInputComponent = forwardRef12(function ToggleInput({
5754
5899
  ...ariaProps
5755
5900
  }
5756
5901
  ),
5757
- props.type === "checkbox" ? /* @__PURE__ */ jsx18(
5902
+ props.type === "checkbox" ? /* @__PURE__ */ jsx19(
5758
5903
  Icon_default,
5759
5904
  {
5760
5905
  name: "check",
@@ -5768,7 +5913,7 @@ var ToggleInputComponent = forwardRef12(function ToggleInput({
5768
5913
  pointerEvents: "none",
5769
5914
  transition: theme2.styles.transition
5770
5915
  }
5771
- ) : props.type === "radio" ? /* @__PURE__ */ jsx18(
5916
+ ) : props.type === "radio" ? /* @__PURE__ */ jsx19(
5772
5917
  Div_default,
5773
5918
  {
5774
5919
  position: "absolute",
@@ -5811,7 +5956,7 @@ var ToggleInputComponent = forwardRef12(function ToggleInput({
5811
5956
  ] })
5812
5957
  ] }) : void 0
5813
5958
  ] }),
5814
- (errorText || infoText) && /* @__PURE__ */ jsx18(
5959
+ (errorText || infoText) && /* @__PURE__ */ jsx19(
5815
5960
  Text_default,
5816
5961
  {
5817
5962
  as: "span",
@@ -5830,7 +5975,7 @@ var ToggleInput_default = {
5830
5975
  betterHtmlContextInternal.components.toggleInput?.style?.checkbox,
5831
5976
  checkboxProps
5832
5977
  );
5833
- return /* @__PURE__ */ jsx18(ToggleInputComponent, { type: "checkbox", ref, ...props });
5978
+ return /* @__PURE__ */ jsx19(ToggleInputComponent, { type: "checkbox", ref, ...props });
5834
5979
  }),
5835
5980
  radiobutton: forwardRef12(function RadioButton(radiobuttonProps, ref) {
5836
5981
  const betterHtmlContextInternal = useBetterHtmlContextInternal();
@@ -5838,7 +5983,7 @@ var ToggleInput_default = {
5838
5983
  betterHtmlContextInternal.components.toggleInput?.style?.radiobutton,
5839
5984
  radiobuttonProps
5840
5985
  );
5841
- return /* @__PURE__ */ jsx18(ToggleInputComponent, { type: "radio", ref, ...props });
5986
+ return /* @__PURE__ */ jsx19(ToggleInputComponent, { type: "radio", ref, ...props });
5842
5987
  }),
5843
5988
  switch: forwardRef12(function Switch(switchProps, ref) {
5844
5989
  const betterHtmlContextInternal = useBetterHtmlContextInternal();
@@ -5878,7 +6023,7 @@ var ToggleInput_default = {
5878
6023
  }, [disabled, checked, onChange, controlledChecked, value]);
5879
6024
  const readyId = id ?? internalId;
5880
6025
  return /* @__PURE__ */ jsxs15(Div_default.column, { width: "fit-content", gap: theme2.styles.gap, ...excludeStyle, children: [
5881
- label && /* @__PURE__ */ jsx18(
6026
+ label && /* @__PURE__ */ jsx19(
5882
6027
  Label_default,
5883
6028
  {
5884
6029
  text: label,
@@ -5892,7 +6037,7 @@ var ToggleInput_default = {
5892
6037
  htmlFor: readyId
5893
6038
  }
5894
6039
  ),
5895
- /* @__PURE__ */ jsx18(
6040
+ /* @__PURE__ */ jsx19(
5896
6041
  Div_default.row,
5897
6042
  {
5898
6043
  alignItems: "center",
@@ -5906,7 +6051,7 @@ var ToggleInput_default = {
5906
6051
  onTouchStart: setIsMouseDown.setTrue,
5907
6052
  onTouchEnd: setIsMouseDown.setFalse,
5908
6053
  onTouchCancel: setIsMouseDown.setFalse,
5909
- children: /* @__PURE__ */ jsx18(
6054
+ children: /* @__PURE__ */ jsx19(
5910
6055
  SwitchElement,
5911
6056
  {
5912
6057
  theme: theme2,
@@ -5926,7 +6071,7 @@ var ToggleInput_default = {
5926
6071
  )
5927
6072
  }
5928
6073
  ),
5929
- (errorText || infoText) && /* @__PURE__ */ jsx18(
6074
+ (errorText || infoText) && /* @__PURE__ */ jsx19(
5930
6075
  Text_default,
5931
6076
  {
5932
6077
  as: "span",
@@ -5941,9 +6086,9 @@ var ToggleInput_default = {
5941
6086
  };
5942
6087
 
5943
6088
  // src/components/Form.tsx
5944
- import { Children, forwardRef as forwardRef13, Fragment as Fragment5, memo as memo19, useMemo as useMemo7 } from "react";
6089
+ import { Children, forwardRef as forwardRef13, Fragment as Fragment7, memo as memo19, useMemo as useMemo7 } from "react";
5945
6090
  import { useTheme as useTheme21 } from "react-better-core";
5946
- import { jsx as jsx19, jsxs as jsxs16 } from "react/jsx-runtime";
6091
+ import { jsx as jsx20, jsxs as jsxs16 } from "react/jsx-runtime";
5947
6092
  var FormComponent = forwardRef13(function Form({
5948
6093
  form,
5949
6094
  name,
@@ -5977,10 +6122,10 @@ var FormComponent = forwardRef13(function Form({
5977
6122
  }, [form]);
5978
6123
  const SubmitButtonTag = isDestructive ? Button_default.destructive : Button_default;
5979
6124
  const submitButtonIsDisabledFinal = submitButtonIsDisabled || submitButtonIsDisabledInternal;
5980
- return /* @__PURE__ */ jsx19(Div_default, { width: "100%", ...props, children: /* @__PURE__ */ jsxs16("form", { name, onSubmit: onSubmit ?? form?.onSubmit, id, ref, children: [
5981
- gap !== void 0 || withDividers ? /* @__PURE__ */ jsx19(Div_default.column, { gap: gap ?? (withDividers ? theme2.styles.space : theme2.styles.gap), children: withDividers ? Children.toArray(children).map((child, index) => /* @__PURE__ */ jsxs16(Fragment5, { children: [
6125
+ return /* @__PURE__ */ jsx20(Div_default, { width: "100%", ...props, children: /* @__PURE__ */ jsxs16("form", { name, onSubmit: onSubmit ?? form?.onSubmit, id, ref, children: [
6126
+ gap !== void 0 || withDividers ? /* @__PURE__ */ jsx20(Div_default.column, { gap: gap ?? (withDividers ? theme2.styles.space : theme2.styles.gap), children: withDividers ? Children.toArray(children).map((child, index) => /* @__PURE__ */ jsxs16(Fragment7, { children: [
5982
6127
  child,
5983
- index < Children.toArray(children).length - 1 && /* @__PURE__ */ jsx19(
6128
+ index < Children.toArray(children).length - 1 && /* @__PURE__ */ jsx20(
5984
6129
  Divider_default.horizontal,
5985
6130
  {
5986
6131
  width: theme2.styles.borderWidth === 0 ? 1 : theme2.styles.borderWidth
@@ -5996,7 +6141,7 @@ var FormComponent = forwardRef13(function Form({
5996
6141
  marginTop: theme2.styles.space,
5997
6142
  children: [
5998
6143
  renderActionButtons,
5999
- onClickCancel && /* @__PURE__ */ jsx19(
6144
+ onClickCancel && /* @__PURE__ */ jsx20(
6000
6145
  Button_default.secondary,
6001
6146
  {
6002
6147
  text: cancelButtonText ?? "Cancel",
@@ -6007,7 +6152,7 @@ var FormComponent = forwardRef13(function Form({
6007
6152
  onClick: onClickCancel
6008
6153
  }
6009
6154
  ),
6010
- /* @__PURE__ */ jsx19(
6155
+ /* @__PURE__ */ jsx20(
6011
6156
  SubmitButtonTag,
6012
6157
  {
6013
6158
  text: submitButtonText,
@@ -6029,7 +6174,7 @@ var Form_default = Form2;
6029
6174
  // src/components/FormRow.tsx
6030
6175
  import { forwardRef as forwardRef14, memo as memo20 } from "react";
6031
6176
  import { useTheme as useTheme22 } from "react-better-core";
6032
- import { jsx as jsx20, jsxs as jsxs17 } from "react/jsx-runtime";
6177
+ import { jsx as jsx21, jsxs as jsxs17 } from "react/jsx-runtime";
6033
6178
  var FormRowComponent = forwardRef14(function FormRow({ oneItemOnly, noBreakingPoint, asColumn, gap, children, ...props }, ref) {
6034
6179
  const theme2 = useTheme22();
6035
6180
  const mediaQuery = useMediaQuery();
@@ -6037,7 +6182,7 @@ var FormRowComponent = forwardRef14(function FormRow({ oneItemOnly, noBreakingPo
6037
6182
  const readyGap = breakingPoint || noBreakingPoint && mediaQuery.size900 ? theme2.styles.gap : theme2.styles.space * 2;
6038
6183
  return /* @__PURE__ */ jsxs17(Div_default.row, { alignItems: "center", gap: gap ?? readyGap, invertFlexDirection: breakingPoint, ...props, ref, children: [
6039
6184
  children,
6040
- oneItemOnly && /* @__PURE__ */ jsx20(Div_default, { width: "100%" })
6185
+ oneItemOnly && /* @__PURE__ */ jsx21(Div_default, { width: "100%" })
6041
6186
  ] });
6042
6187
  });
6043
6188
  FormRowComponent.withTitle = forwardRef14(function WithTitle({
@@ -6063,7 +6208,7 @@ FormRowComponent.withTitle = forwardRef14(function WithTitle({
6063
6208
  const titleGap = theme2.styles.space;
6064
6209
  return /* @__PURE__ */ jsxs17(FormRowComponent, { ...props, ref, children: [
6065
6210
  /* @__PURE__ */ jsxs17(Div_default.row, { width: "100%", alignItems: "center", gap: titleGap, children: [
6066
- icon && /* @__PURE__ */ jsx20(Icon_default, { name: icon }),
6211
+ icon && /* @__PURE__ */ jsx21(Icon_default, { name: icon }),
6067
6212
  /* @__PURE__ */ jsxs17(Div_default.column, { flex: 1, gap: theme2.styles.gap / 2, children: [
6068
6213
  /* @__PURE__ */ jsxs17(Text_default, { as: titleAs, fontSize: titleFontSize, children: [
6069
6214
  title,
@@ -6072,9 +6217,9 @@ FormRowComponent.withTitle = forwardRef14(function WithTitle({
6072
6217
  "*"
6073
6218
  ] })
6074
6219
  ] }),
6075
- description && /* @__PURE__ */ jsx20(Text_default, { fontSize: descriptionFontSize ?? theme2.styles.fontSize, color: theme2.colors.textSecondary, children: description })
6220
+ description && /* @__PURE__ */ jsx21(Text_default, { fontSize: descriptionFontSize ?? theme2.styles.fontSize, color: theme2.colors.textSecondary, children: description })
6076
6221
  ] }),
6077
- isLoading && /* @__PURE__ */ jsx20(Div_default, { width: 26 - titleGap })
6222
+ isLoading && /* @__PURE__ */ jsx21(Div_default, { width: 26 - titleGap })
6078
6223
  ] }),
6079
6224
  /* @__PURE__ */ jsxs17(
6080
6225
  Div_default.row,
@@ -6085,7 +6230,7 @@ FormRowComponent.withTitle = forwardRef14(function WithTitle({
6085
6230
  justifyContent: alignChildren,
6086
6231
  gap: theme2.styles.gap,
6087
6232
  children: [
6088
- /* @__PURE__ */ jsx20(
6233
+ /* @__PURE__ */ jsx21(
6089
6234
  Div_default,
6090
6235
  {
6091
6236
  position: "absolute",
@@ -6094,13 +6239,13 @@ FormRowComponent.withTitle = forwardRef14(function WithTitle({
6094
6239
  transform: "translateY(-50%)",
6095
6240
  opacity: !isLoading ? 0 : void 0,
6096
6241
  pointerEvents: !isLoading ? "none" : void 0,
6097
- children: /* @__PURE__ */ jsx20(Loader_default, {})
6242
+ children: /* @__PURE__ */ jsx21(Loader_default, {})
6098
6243
  }
6099
6244
  ),
6100
6245
  children,
6101
6246
  withActions && /* @__PURE__ */ jsxs17(Div_default.row, { alignItems: "center", gap: theme2.styles.gap, children: [
6102
- onClickReset && /* @__PURE__ */ jsx20(Button_default.icon, { icon: "XMark", loaderName: resetButtonLoaderName, onClick: onClickReset }),
6103
- /* @__PURE__ */ jsx20(Button_default.icon, { icon: "check", loaderName: saveButtonLoaderName, onClick: onClickSave })
6247
+ onClickReset && /* @__PURE__ */ jsx21(Button_default.icon, { icon: "XMark", loaderName: resetButtonLoaderName, onClick: onClickReset }),
6248
+ /* @__PURE__ */ jsx21(Button_default.icon, { icon: "check", loaderName: saveButtonLoaderName, onClick: onClickSave })
6104
6249
  ] })
6105
6250
  ]
6106
6251
  }
@@ -6114,7 +6259,7 @@ var FormRow_default = FormRow2;
6114
6259
  // src/components/ColorThemeSwitch.tsx
6115
6260
  import { memo as memo21, useCallback as useCallback12, useEffect as useEffect10, useState as useState9 } from "react";
6116
6261
  import { useTheme as useTheme23 } from "react-better-core";
6117
- import { jsx as jsx21, jsxs as jsxs18 } from "react/jsx-runtime";
6262
+ import { jsx as jsx22, jsxs as jsxs18 } from "react/jsx-runtime";
6118
6263
  var ColorThemeSwitchComponent = function ColorThemeSwitch({
6119
6264
  withMoon,
6120
6265
  className,
@@ -6143,7 +6288,7 @@ var ColorThemeSwitchComponent = function ColorThemeSwitch({
6143
6288
  observer.disconnect();
6144
6289
  };
6145
6290
  }, []);
6146
- return /* @__PURE__ */ jsx21(
6291
+ return /* @__PURE__ */ jsx22(
6147
6292
  ToggleInput_default.switch,
6148
6293
  {
6149
6294
  className: `react-better-html-color-theme-switch ${withMoon ? ` react-better-html-color-theme-switch-with-moon` : ""}${className ? ` ${className}` : ""}`,
@@ -6156,9 +6301,9 @@ var ColorThemeSwitchComponent = function ColorThemeSwitch({
6156
6301
  ColorThemeSwitchComponent.withText = function WithText({ withMoon, className, ...props }) {
6157
6302
  const theme2 = useTheme23();
6158
6303
  return /* @__PURE__ */ jsxs18(Div_default.row, { width: "fit-content", alignItems: "center", gap: theme2.styles.gap, userSelect: "none", ...props, children: [
6159
- /* @__PURE__ */ jsx21(Text_default, { children: "Light" }),
6160
- /* @__PURE__ */ jsx21(ColorThemeSwitchComponent, { withMoon, className }),
6161
- /* @__PURE__ */ jsx21(Text_default, { children: "Dark" })
6304
+ /* @__PURE__ */ jsx22(Text_default, { children: "Light" }),
6305
+ /* @__PURE__ */ jsx22(ColorThemeSwitchComponent, { withMoon, className }),
6306
+ /* @__PURE__ */ jsx22(Text_default, { children: "Dark" })
6162
6307
  ] });
6163
6308
  };
6164
6309
  var ColorThemeSwitch2 = memo21(ColorThemeSwitchComponent);
@@ -6175,7 +6320,7 @@ import {
6175
6320
  useImperativeHandle as useImperativeHandle2,
6176
6321
  useRef as useRef6,
6177
6322
  useEffect as useEffect12,
6178
- Fragment as Fragment6
6323
+ Fragment as Fragment8
6179
6324
  } from "react";
6180
6325
  import { darkenColor as darkenColor3, useBetterCoreContext as useBetterCoreContext9, useTheme as useTheme25 } from "react-better-core";
6181
6326
  import styled12, { css as css5 } from "styled-components";
@@ -6183,7 +6328,7 @@ import styled12, { css as css5 } from "styled-components";
6183
6328
  // src/components/Pagination.tsx
6184
6329
  import { memo as memo22, useCallback as useCallback13, useEffect as useEffect11, useMemo as useMemo8, useState as useState10 } from "react";
6185
6330
  import { useTheme as useTheme24 } from "react-better-core";
6186
- import { jsx as jsx22, jsxs as jsxs19 } from "react/jsx-runtime";
6331
+ import { jsx as jsx23, jsxs as jsxs19 } from "react/jsx-runtime";
6187
6332
  var PaginationComponent = function Pagination({
6188
6333
  currentPage = 1,
6189
6334
  itemsLength = 0,
@@ -6231,7 +6376,7 @@ var PaginationComponent = function Pagination({
6231
6376
  }, [currentPage]);
6232
6377
  const mobileFooterBreakingPoint = mediaQuery.size700 && pageCountInternal > maximumVisiblePages2 / 1.4;
6233
6378
  return /* @__PURE__ */ jsxs19(Div_default.row, { alignItems: "center", justifyContent: "center", gap: theme2.styles.gap * 2, children: [
6234
- pageCountInternal > maximumVisiblePages2 && /* @__PURE__ */ jsx22(
6379
+ pageCountInternal > maximumVisiblePages2 && /* @__PURE__ */ jsx23(
6235
6380
  Button_default.icon,
6236
6381
  {
6237
6382
  icon: "doubleChevronLeft",
@@ -6240,8 +6385,8 @@ var PaginationComponent = function Pagination({
6240
6385
  onClickWithValue: setCurrentPage
6241
6386
  }
6242
6387
  ),
6243
- /* @__PURE__ */ jsx22(Button_default.icon, { icon: "chevronLeft", disabled: currentPageInternal === 1, onClick: onClickPreviousPageElement }),
6244
- /* @__PURE__ */ jsx22(
6388
+ /* @__PURE__ */ jsx23(Button_default.icon, { icon: "chevronLeft", disabled: currentPageInternal === 1, onClick: onClickPreviousPageElement }),
6389
+ /* @__PURE__ */ jsx23(
6245
6390
  Div_default.row,
6246
6391
  {
6247
6392
  alignItems: "center",
@@ -6250,14 +6395,14 @@ var PaginationComponent = function Pagination({
6250
6395
  gap: theme2.styles.gap,
6251
6396
  children: paginationItems.map((pageIndex) => {
6252
6397
  const isActive = currentPageInternal === pageIndex;
6253
- return /* @__PURE__ */ jsx22(
6398
+ return /* @__PURE__ */ jsx23(
6254
6399
  Div_default,
6255
6400
  {
6256
6401
  cursor: "pointer",
6257
6402
  userSelect: "none",
6258
6403
  value: pageIndex,
6259
6404
  onClickWithValue: setCurrentPage,
6260
- children: /* @__PURE__ */ jsx22(
6405
+ children: /* @__PURE__ */ jsx23(
6261
6406
  Text_default,
6262
6407
  {
6263
6408
  fontWeight: isActive ? 700 : 400,
@@ -6272,7 +6417,7 @@ var PaginationComponent = function Pagination({
6272
6417
  })
6273
6418
  }
6274
6419
  ),
6275
- /* @__PURE__ */ jsx22(
6420
+ /* @__PURE__ */ jsx23(
6276
6421
  Button_default.icon,
6277
6422
  {
6278
6423
  icon: "chevronRight",
@@ -6280,7 +6425,7 @@ var PaginationComponent = function Pagination({
6280
6425
  onClick: onClickNextPageElement
6281
6426
  }
6282
6427
  ),
6283
- pageCountInternal > maximumVisiblePages2 && /* @__PURE__ */ jsx22(
6428
+ pageCountInternal > maximumVisiblePages2 && /* @__PURE__ */ jsx23(
6284
6429
  Button_default.icon,
6285
6430
  {
6286
6431
  icon: "doubleChevronRight",
@@ -6295,7 +6440,7 @@ var Pagination2 = memo22(PaginationComponent);
6295
6440
  var Pagination_default = Pagination2;
6296
6441
 
6297
6442
  // src/components/Table.tsx
6298
- import { Fragment as Fragment7, jsx as jsx23, jsxs as jsxs20 } from "react/jsx-runtime";
6443
+ import { Fragment as Fragment9, jsx as jsx24, jsxs as jsxs20 } from "react/jsx-runtime";
6299
6444
  var defaultImageWidth = 160;
6300
6445
  var maximumVisiblePages = 11;
6301
6446
  var TableStyledComponent = styled12.table.withConfig({
@@ -6522,19 +6667,19 @@ var TableComponent = forwardRef15(function Table({
6522
6667
  case "text": {
6523
6668
  const value = column.keyName ? item[column.keyName] : void 0;
6524
6669
  const textProps = (typeof column.getTextProps === "function" ? column.getTextProps?.(item, itemIndex) : column.getTextProps) ?? {};
6525
- return /* @__PURE__ */ jsx23(Text_default, { ...textProps, children: column.format?.(item, itemIndex) ?? String(value ?? "") });
6670
+ return /* @__PURE__ */ jsx24(Text_default, { ...textProps, children: column.format?.(item, itemIndex) ?? String(value ?? "") });
6526
6671
  }
6527
6672
  case "element": {
6528
- return column.render?.(item, itemIndex) ?? /* @__PURE__ */ jsx23(Fragment7, {});
6673
+ return column.render?.(item, itemIndex) ?? /* @__PURE__ */ jsx24(Fragment9, {});
6529
6674
  }
6530
6675
  case "image": {
6531
6676
  const imageProps = (typeof column.getImageProps === "function" ? column.getImageProps?.(item, itemIndex) : column.getImageProps) ?? {};
6532
- return /* @__PURE__ */ jsx23(Image_default, { width: "100%", borderRadius: theme2.styles.borderRadius / 2, ...imageProps });
6677
+ return /* @__PURE__ */ jsx24(Image_default, { width: "100%", borderRadius: theme2.styles.borderRadius / 2, ...imageProps });
6533
6678
  }
6534
6679
  case "checkbox": {
6535
6680
  const { onChange, ...toggleInputProps } = (typeof column.getToggleInputProps === "function" ? column.getToggleInputProps?.(item, itemIndex) : column.getToggleInputProps) ?? {};
6536
6681
  const checkedValue = checkedItems[itemIndex];
6537
- return /* @__PURE__ */ jsx23(
6682
+ return /* @__PURE__ */ jsx24(
6538
6683
  ToggleInput_default.checkbox,
6539
6684
  {
6540
6685
  checked: checkedValue,
@@ -6555,7 +6700,7 @@ var TableComponent = forwardRef15(function Table({
6555
6700
  );
6556
6701
  }
6557
6702
  case "expand": {
6558
- return /* @__PURE__ */ jsx23(Div_default, { isTabAccessed: true, children: /* @__PURE__ */ jsx23(
6703
+ return /* @__PURE__ */ jsx24(Div_default, { isTabAccessed: true, children: /* @__PURE__ */ jsx24(
6559
6704
  Icon_default,
6560
6705
  {
6561
6706
  name: "chevronDown",
@@ -6565,7 +6710,7 @@ var TableComponent = forwardRef15(function Table({
6565
6710
  ) });
6566
6711
  }
6567
6712
  default: {
6568
- return /* @__PURE__ */ jsx23(Fragment7, {});
6713
+ return /* @__PURE__ */ jsx24(Fragment9, {});
6569
6714
  }
6570
6715
  }
6571
6716
  },
@@ -6818,8 +6963,8 @@ var TableComponent = forwardRef15(function Table({
6818
6963
  }, [currentPage, setCurrentPage, pageCountInternal, setCheckedItems]);
6819
6964
  const withFooter = pageSize !== void 0 && pageCountInternal > 1;
6820
6965
  const mobileFooterBreakingPoint = mediaQuery.size700 && pageCountInternal > maximumVisiblePages / 1.4;
6821
- return /* @__PURE__ */ jsxs20(Fragment7, { children: [
6822
- /* @__PURE__ */ jsx23(
6966
+ return /* @__PURE__ */ jsxs20(Fragment9, { children: [
6967
+ /* @__PURE__ */ jsx24(
6823
6968
  Div_default,
6824
6969
  {
6825
6970
  border: `${theme2.styles.borderWidth}px solid ${theme2.colors.border}`,
@@ -6838,7 +6983,7 @@ var TableComponent = forwardRef15(function Table({
6838
6983
  containsOverflowComponents,
6839
6984
  withFooter,
6840
6985
  children: [
6841
- /* @__PURE__ */ jsx23("thead", { children: /* @__PURE__ */ jsx23("tr", { className: "isHeader", children: readyColumns.map((column, index) => /* @__PURE__ */ jsx23(
6986
+ /* @__PURE__ */ jsx24("thead", { children: /* @__PURE__ */ jsx24("tr", { className: "isHeader", children: readyColumns.map((column, index) => /* @__PURE__ */ jsx24(
6842
6987
  ThStyledComponent,
6843
6988
  {
6844
6989
  width: column.width ?? (column.type === "image" ? defaultImageWidth : column.type === "checkbox" ? 26 : column.type === "expand" ? 16 : void 0),
@@ -6853,15 +6998,15 @@ var TableComponent = forwardRef15(function Table({
6853
6998
  justifyContent: column.filter ? "space-between" : column.align === "center" ? "center" : column.align === "right" ? "flex-end" : "flex-start",
6854
6999
  gap: theme2.styles.gap,
6855
7000
  children: [
6856
- column.type === "checkbox" && onClickAllCheckboxes ? /* @__PURE__ */ jsx23(
7001
+ column.type === "checkbox" && onClickAllCheckboxes ? /* @__PURE__ */ jsx24(
6857
7002
  ToggleInput_default.checkbox,
6858
7003
  {
6859
7004
  checked: everythingIsChecked,
6860
7005
  disabled: data.length === 0,
6861
7006
  onChange: onClickAllCheckboxesElement
6862
7007
  }
6863
- ) : column.label ? column.renderLabel ? column.renderLabel(column.label) : /* @__PURE__ */ jsx23(Text_default, { children: column.label }) : void 0,
6864
- column.filter && /* @__PURE__ */ jsx23(
7008
+ ) : column.label ? column.renderLabel ? column.renderLabel(column.label) : /* @__PURE__ */ jsx24(Text_default, { children: column.label }) : void 0,
7009
+ column.filter && /* @__PURE__ */ jsx24(
6865
7010
  Button_default.icon,
6866
7011
  {
6867
7012
  icon: "filter",
@@ -6876,16 +7021,16 @@ var TableComponent = forwardRef15(function Table({
6876
7021
  },
6877
7022
  column.type + column.label + index
6878
7023
  )) }) }),
6879
- /* @__PURE__ */ jsx23("tbody", { children: isLoading ? /* @__PURE__ */ jsx23("tr", { className: "withoutHover", children: /* @__PURE__ */ jsx23("td", { className: "noData", colSpan: readyColumns.length, children: /* @__PURE__ */ jsx23(Loader_default.box, {}) }) }) : dataAfterPagination.length > 0 ? dataAfterPagination.map((item, rowIndex) => {
7024
+ /* @__PURE__ */ jsx24("tbody", { children: isLoading ? /* @__PURE__ */ jsx24("tr", { className: "withoutHover", children: /* @__PURE__ */ jsx24("td", { className: "noData", colSpan: readyColumns.length, children: /* @__PURE__ */ jsx24(Loader_default.box, {}) }) }) : dataAfterPagination.length > 0 ? dataAfterPagination.map((item, rowIndex) => {
6880
7025
  const realRowIndex = rowIndex + (pageSize ? (currentPage - 1) * pageSize : 0);
6881
- return /* @__PURE__ */ jsxs20(Fragment6, { children: [
6882
- /* @__PURE__ */ jsx23(
7026
+ return /* @__PURE__ */ jsxs20(Fragment8, { children: [
7027
+ /* @__PURE__ */ jsx24(
6883
7028
  "tr",
6884
7029
  {
6885
7030
  className: isInsideTableExpandRow && onClickRow === void 0 && expandColumn === void 0 ? "withoutHover" : void 0,
6886
7031
  style: getRowStyle?.(item, realRowIndex),
6887
7032
  onClick: () => onClickRowElement(item, realRowIndex),
6888
- children: readyColumns.map((column, colIndex) => /* @__PURE__ */ jsx23(
7033
+ children: readyColumns.map((column, colIndex) => /* @__PURE__ */ jsx24(
6889
7034
  TdStyledComponent,
6890
7035
  {
6891
7036
  textAlign: column.align,
@@ -6898,10 +7043,10 @@ var TableComponent = forwardRef15(function Table({
6898
7043
  ))
6899
7044
  }
6900
7045
  ),
6901
- expandedRows[realRowIndex] && /* @__PURE__ */ jsx23("tr", { className: "withoutHover isExpandRow", children: /* @__PURE__ */ jsx23("td", { colSpan: readyColumns.length, children: renderExpandedRow(item, realRowIndex) }) })
7046
+ expandedRows[realRowIndex] && /* @__PURE__ */ jsx24("tr", { className: "withoutHover isExpandRow", children: /* @__PURE__ */ jsx24("td", { colSpan: readyColumns.length, children: renderExpandedRow(item, realRowIndex) }) })
6902
7047
  ] }, JSON.stringify(item) + realRowIndex);
6903
- }) : /* @__PURE__ */ jsx23("tr", { className: "withoutHover", children: /* @__PURE__ */ jsx23("td", { className: "noData", colSpan: readyColumns.length, children: /* @__PURE__ */ jsx23(Text_default.unknown, { children: noDataItemsMessage }) }) }) }),
6904
- withFooter && /* @__PURE__ */ jsx23("tfoot", { children: /* @__PURE__ */ jsx23("tr", { className: "isFooter", children: /* @__PURE__ */ jsx23("td", { colSpan: readyColumns.length, children: /* @__PURE__ */ jsxs20(
7048
+ }) : /* @__PURE__ */ jsx24("tr", { className: "withoutHover", children: /* @__PURE__ */ jsx24("td", { className: "noData", colSpan: readyColumns.length, children: /* @__PURE__ */ jsx24(Text_default.unknown, { children: noDataItemsMessage }) }) }) }),
7049
+ withFooter && /* @__PURE__ */ jsx24("tfoot", { children: /* @__PURE__ */ jsx24("tr", { className: "isFooter", children: /* @__PURE__ */ jsx24("td", { colSpan: readyColumns.length, children: /* @__PURE__ */ jsxs20(
6905
7050
  Div_default.column,
6906
7051
  {
6907
7052
  position: "relative",
@@ -6925,7 +7070,7 @@ var TableComponent = forwardRef15(function Table({
6925
7070
  ]
6926
7071
  }
6927
7072
  ),
6928
- /* @__PURE__ */ jsx23(
7073
+ /* @__PURE__ */ jsx24(
6929
7074
  Pagination_default,
6930
7075
  {
6931
7076
  currentPage,
@@ -6944,14 +7089,14 @@ var TableComponent = forwardRef15(function Table({
6944
7089
  )
6945
7090
  }
6946
7091
  ),
6947
- /* @__PURE__ */ jsx23(
7092
+ /* @__PURE__ */ jsx24(
6948
7093
  Modal_default,
6949
7094
  {
6950
7095
  title: `Filter ${openedFilterColumn?.label ?? ""}`,
6951
7096
  description: openedFilterColumn?.filter === "number" ? "Enter minimum and maximum values to filter" : openedFilterColumn?.filter === "date" || openedFilterColumn?.filter === "date-time" ? "Enter minimum and maximum dates to filter" : openedFilterColumn?.filter === "list" ? "Select values to filter from the list bellow" : "",
6952
7097
  onClose: onCloseFilterModal,
6953
7098
  ref: filterModalRef,
6954
- children: openedFilterColumn ? openedFilterColumn.filter === "number" ? /* @__PURE__ */ jsx23(
7099
+ children: openedFilterColumn ? openedFilterColumn.filter === "number" ? /* @__PURE__ */ jsx24(
6955
7100
  Form_default,
6956
7101
  {
6957
7102
  form: filterForm,
@@ -6959,8 +7104,8 @@ var TableComponent = forwardRef15(function Table({
6959
7104
  cancelButtonText: "Clear",
6960
7105
  onClickCancel: openedFilterData ? onClickCancelFormFilter : void 0,
6961
7106
  children: /* @__PURE__ */ jsxs20(FormRow_default, { children: [
6962
- /* @__PURE__ */ jsx23(InputField_default, { type: "number", label: "Min", ...filterForm.getInputFieldProps("min") }),
6963
- /* @__PURE__ */ jsx23(InputField_default, { type: "number", label: "Max", ...filterForm.getInputFieldProps("max") })
7107
+ /* @__PURE__ */ jsx24(InputField_default, { type: "number", label: "Min", ...filterForm.getInputFieldProps("min") }),
7108
+ /* @__PURE__ */ jsx24(InputField_default, { type: "number", label: "Max", ...filterForm.getInputFieldProps("max") })
6964
7109
  ] })
6965
7110
  }
6966
7111
  ) : openedFilterColumn.filter === "date" || openedFilterColumn.filter === "date-time" ? /* @__PURE__ */ jsxs20(
@@ -6972,16 +7117,16 @@ var TableComponent = forwardRef15(function Table({
6972
7117
  cancelButtonText: "Clear",
6973
7118
  onClickCancel: openedFilterData ? onClickCancelFormFilter : void 0,
6974
7119
  children: [
6975
- /* @__PURE__ */ jsx23(FormRow_default, { children: openedFilterColumn.filter === "date" ? /* @__PURE__ */ jsxs20(Fragment7, { children: [
6976
- /* @__PURE__ */ jsx23(InputField_default.date, { label: "Min", ...filterForm.getInputFieldProps("min") }),
6977
- /* @__PURE__ */ jsx23(InputField_default.date, { label: "Max", ...filterForm.getInputFieldProps("max") })
6978
- ] }) : /* @__PURE__ */ jsxs20(Fragment7, { children: [
6979
- /* @__PURE__ */ jsx23(InputField_default.dateTime, { label: "Min", ...filterForm.getInputFieldProps("min") }),
6980
- /* @__PURE__ */ jsx23(InputField_default.dateTime, { label: "Max", ...filterForm.getInputFieldProps("max") })
7120
+ /* @__PURE__ */ jsx24(FormRow_default, { children: openedFilterColumn.filter === "date" ? /* @__PURE__ */ jsxs20(Fragment9, { children: [
7121
+ /* @__PURE__ */ jsx24(InputField_default.date, { label: "Min", ...filterForm.getInputFieldProps("min") }),
7122
+ /* @__PURE__ */ jsx24(InputField_default.date, { label: "Max", ...filterForm.getInputFieldProps("max") })
7123
+ ] }) : /* @__PURE__ */ jsxs20(Fragment9, { children: [
7124
+ /* @__PURE__ */ jsx24(InputField_default.dateTime, { label: "Min", ...filterForm.getInputFieldProps("min") }),
7125
+ /* @__PURE__ */ jsx24(InputField_default.dateTime, { label: "Max", ...filterForm.getInputFieldProps("max") })
6981
7126
  ] }) }),
6982
7127
  openedFilterColumn.presets && /* @__PURE__ */ jsxs20(Div_default.column, { gap: theme2.styles.gap / 2, children: [
6983
- /* @__PURE__ */ jsx23(Label_default, { text: "Presets" }),
6984
- /* @__PURE__ */ jsx23(Div_default.row, { alignItems: "center", flexWrap: "wrap", gap: theme2.styles.gap, children: openedFilterColumn.presets.map((preset) => /* @__PURE__ */ jsx23(
7128
+ /* @__PURE__ */ jsx24(Label_default, { text: "Presets" }),
7129
+ /* @__PURE__ */ jsx24(Div_default.row, { alignItems: "center", flexWrap: "wrap", gap: theme2.styles.gap, children: openedFilterColumn.presets.map((preset) => /* @__PURE__ */ jsx24(
6985
7130
  Button_default.secondary,
6986
7131
  {
6987
7132
  text: filterPresetsText[preset],
@@ -7001,7 +7146,7 @@ var TableComponent = forwardRef15(function Table({
7001
7146
  submitButtonText: "Filter",
7002
7147
  cancelButtonText: "Clear",
7003
7148
  renderActionButtons: /* @__PURE__ */ jsxs20(Div_default.row, { marginRight: "auto", alignItems: "center", gap: theme2.styles.gap, children: [
7004
- /* @__PURE__ */ jsx23(
7149
+ /* @__PURE__ */ jsx24(
7005
7150
  Button_default.secondary,
7006
7151
  {
7007
7152
  text: "Select All",
@@ -7010,7 +7155,7 @@ var TableComponent = forwardRef15(function Table({
7010
7155
  onClick: onClickSelectAllFilterListItems
7011
7156
  }
7012
7157
  ),
7013
- /* @__PURE__ */ jsx23(
7158
+ /* @__PURE__ */ jsx24(
7014
7159
  Button_default.secondary,
7015
7160
  {
7016
7161
  text: "Deselect All",
@@ -7023,7 +7168,7 @@ var TableComponent = forwardRef15(function Table({
7023
7168
  onClickCancel: openedFilterData ? onClickCancelFormFilter : void 0,
7024
7169
  onSubmit: filterForm.onSubmit,
7025
7170
  children: [
7026
- openedFilterColumn?.withSearch && /* @__PURE__ */ jsx23(FormRow_default, { oneItemOnly: true, children: /* @__PURE__ */ jsx23(
7171
+ openedFilterColumn?.withSearch && /* @__PURE__ */ jsx24(FormRow_default, { oneItemOnly: true, children: /* @__PURE__ */ jsx24(
7027
7172
  InputField_default.search,
7028
7173
  {
7029
7174
  label: "Search",
@@ -7032,17 +7177,17 @@ var TableComponent = forwardRef15(function Table({
7032
7177
  }
7033
7178
  ) }),
7034
7179
  /* @__PURE__ */ jsxs20(Div_default.column, { gap: theme2.styles.gap / 2, children: [
7035
- /* @__PURE__ */ jsx23(Label_default, { text: "Possible values" }),
7036
- /* @__PURE__ */ jsx23(Div_default.row, { flexWrap: "wrap", gap: theme2.styles.gap, children: possibleFilterListValues.length > 0 ? possibleFilterListValues.map((value) => {
7180
+ /* @__PURE__ */ jsx24(Label_default, { text: "Possible values" }),
7181
+ /* @__PURE__ */ jsx24(Div_default.row, { flexWrap: "wrap", gap: theme2.styles.gap, children: possibleFilterListValues.length > 0 ? possibleFilterListValues.map((value) => {
7037
7182
  const isActive = filterListSelectedItems?.includes(value.value);
7038
- return /* @__PURE__ */ jsx23(
7183
+ return /* @__PURE__ */ jsx24(
7039
7184
  Div_default.box,
7040
7185
  {
7041
7186
  isActive,
7042
7187
  value: value.value,
7043
7188
  onClickWithValue: onClickFilterListItem,
7044
7189
  children: /* @__PURE__ */ jsxs20(Div_default.row, { alignItems: "center", gap: theme2.styles.gap / 2, children: [
7045
- /* @__PURE__ */ jsx23(Text_default, { children: value.label || value.value }),
7190
+ /* @__PURE__ */ jsx24(Text_default, { children: value.label || value.value }),
7046
7191
  openedFilterColumn.withTotalNumber && /* @__PURE__ */ jsxs20(
7047
7192
  Text_default,
7048
7193
  {
@@ -7059,12 +7204,12 @@ var TableComponent = forwardRef15(function Table({
7059
7204
  },
7060
7205
  value.value.toString()
7061
7206
  );
7062
- }) : /* @__PURE__ */ jsx23(Text_default.unknown, { children: "No values" }) })
7207
+ }) : /* @__PURE__ */ jsx24(Text_default.unknown, { children: "No values" }) })
7063
7208
  ] }),
7064
- /* @__PURE__ */ jsx23(Div_default, {})
7209
+ /* @__PURE__ */ jsx24(Div_default, {})
7065
7210
  ]
7066
7211
  }
7067
- ) : /* @__PURE__ */ jsx23(Text_default.unknown, { children: "Unknown filter" }) : /* @__PURE__ */ jsx23(Loader_default.box, {})
7212
+ ) : /* @__PURE__ */ jsx24(Text_default.unknown, { children: "Unknown filter" }) : /* @__PURE__ */ jsx24(Loader_default.box, {})
7068
7213
  }
7069
7214
  )
7070
7215
  ] });
@@ -7076,7 +7221,7 @@ var Table_default = Table2;
7076
7221
  import { memo as memo24, useCallback as useCallback15, useRef as useRef7, useState as useState12, useEffect as useEffect13, forwardRef as forwardRef16, useImperativeHandle as useImperativeHandle3, useMemo as useMemo10 } from "react";
7077
7222
  import { useTheme as useTheme26 } from "react-better-core";
7078
7223
  import styled13, { css as css6 } from "styled-components";
7079
- import { jsx as jsx24, jsxs as jsxs21 } from "react/jsx-runtime";
7224
+ import { jsx as jsx25, jsxs as jsxs21 } from "react/jsx-runtime";
7080
7225
  var tooltipContainerStyle = (props) => ({
7081
7226
  top: css6`
7082
7227
  bottom: calc(100% + ${props.gap}px + ${props.arrowSize}px);
@@ -7189,7 +7334,7 @@ var Arrow = memo24(function Arrow2(props) {
7189
7334
  [props, theme2]
7190
7335
  );
7191
7336
  const borderWidth = theme2.styles.borderWidth;
7192
- return /* @__PURE__ */ jsx24(
7337
+ return /* @__PURE__ */ jsx25(
7193
7338
  Div_default,
7194
7339
  {
7195
7340
  position: "absolute",
@@ -7197,7 +7342,7 @@ var Arrow = memo24(function Arrow2(props) {
7197
7342
  height: 0,
7198
7343
  border: `${size}px solid transparent`,
7199
7344
  ...arrowStyle(outerProps)[position],
7200
- children: /* @__PURE__ */ jsx24(
7345
+ children: /* @__PURE__ */ jsx25(
7201
7346
  Div_default,
7202
7347
  {
7203
7348
  position: "absolute",
@@ -7327,7 +7472,7 @@ var TooltipComponent = forwardRef16(function Tooltip({
7327
7472
  onMouseEnter,
7328
7473
  onMouseLeave,
7329
7474
  children: [
7330
- /* @__PURE__ */ jsx24(
7475
+ /* @__PURE__ */ jsx25(
7331
7476
  Div_default,
7332
7477
  {
7333
7478
  width: childrenWrapperWidth,
@@ -7337,7 +7482,7 @@ var TooltipComponent = forwardRef16(function Tooltip({
7337
7482
  children
7338
7483
  }
7339
7484
  ),
7340
- /* @__PURE__ */ jsx24(
7485
+ /* @__PURE__ */ jsx25(
7341
7486
  TooltipContainer,
7342
7487
  {
7343
7488
  theme: theme2,
@@ -7351,7 +7496,7 @@ var TooltipComponent = forwardRef16(function Tooltip({
7351
7496
  role: "tooltip",
7352
7497
  ref: tooltipContainerRef,
7353
7498
  children: (isOpen || isOpenLate) && /* @__PURE__ */ jsxs21(Div_default, { position: "relative", ref: contentRef, children: [
7354
- /* @__PURE__ */ jsx24(
7499
+ /* @__PURE__ */ jsx25(
7355
7500
  Div_default.box,
7356
7501
  {
7357
7502
  position: "relative",
@@ -7365,7 +7510,7 @@ var TooltipComponent = forwardRef16(function Tooltip({
7365
7510
  children: content
7366
7511
  }
7367
7512
  ),
7368
- /* @__PURE__ */ jsx24(
7513
+ /* @__PURE__ */ jsx25(
7369
7514
  Div_default,
7370
7515
  {
7371
7516
  position: "absolute",
@@ -7379,7 +7524,7 @@ var TooltipComponent = forwardRef16(function Tooltip({
7379
7524
  borderTopRightRadius: 999
7380
7525
  }
7381
7526
  ),
7382
- withArrow && /* @__PURE__ */ jsx24(
7527
+ withArrow && /* @__PURE__ */ jsx25(
7383
7528
  Arrow,
7384
7529
  {
7385
7530
  position,
@@ -7429,10 +7574,10 @@ TooltipComponent.item = forwardRef16(function Item({
7429
7574
  onClickWithValue: !disabled ? onClickWithValue : void 0,
7430
7575
  ref,
7431
7576
  children: [
7432
- icon && /* @__PURE__ */ jsx24(Icon_default, { name: icon, color: iconColor ?? (!isActive ? theme2.colors.textSecondary : void 0) }),
7577
+ icon && /* @__PURE__ */ jsx25(Icon_default, { name: icon, color: iconColor ?? (!isActive ? theme2.colors.textSecondary : void 0) }),
7433
7578
  /* @__PURE__ */ jsxs21(Div_default.column, { flex: 1, gap: theme2.styles.gap / 2, children: [
7434
- /* @__PURE__ */ jsx24(Text_default, { fontWeight: isActive ? 700 : void 0, color: textColor ?? theme2.colors.textPrimary, children: text }),
7435
- description && /* @__PURE__ */ jsx24(Text_default, { fontSize: 14, color: theme2.colors.textSecondary, children: description })
7579
+ /* @__PURE__ */ jsx25(Text_default, { fontWeight: isActive ? 700 : void 0, color: textColor ?? theme2.colors.textPrimary, children: text }),
7580
+ description && /* @__PURE__ */ jsx25(Text_default, { fontSize: 14, color: theme2.colors.textSecondary, children: description })
7436
7581
  ] })
7437
7582
  ]
7438
7583
  }
@@ -7440,7 +7585,7 @@ TooltipComponent.item = forwardRef16(function Item({
7440
7585
  });
7441
7586
  TooltipComponent.divider = forwardRef16(function DividerComponent(props, ref) {
7442
7587
  const theme2 = useTheme26();
7443
- return /* @__PURE__ */ jsx24(
7588
+ return /* @__PURE__ */ jsx25(
7444
7589
  Divider_default.horizontal,
7445
7590
  {
7446
7591
  width: theme2.styles.borderWidth === 0 ? 1 : theme2.styles.borderWidth,
@@ -7452,7 +7597,7 @@ TooltipComponent.divider = forwardRef16(function DividerComponent(props, ref) {
7452
7597
  });
7453
7598
  TooltipComponent.sectionTitle = forwardRef16(function SectionTitle({ text, ...props }, ref) {
7454
7599
  const theme2 = useTheme26();
7455
- return /* @__PURE__ */ jsx24(
7600
+ return /* @__PURE__ */ jsx25(
7456
7601
  Text_default,
7457
7602
  {
7458
7603
  fontSize: 12,
@@ -7475,7 +7620,7 @@ var Tooltip_default = Tooltip2;
7475
7620
  // src/components/Tabs.tsx
7476
7621
  import { forwardRef as forwardRef17, memo as memo25, useCallback as useCallback16, useEffect as useEffect14, useImperativeHandle as useImperativeHandle4, useMemo as useMemo11, useRef as useRef8, useState as useState13 } from "react";
7477
7622
  import { useTheme as useTheme27 } from "react-better-core";
7478
- import { jsx as jsx25, jsxs as jsxs22 } from "react/jsx-runtime";
7623
+ import { jsx as jsx26, jsxs as jsxs22 } from "react/jsx-runtime";
7479
7624
  var tabBottomLineWidth = 2;
7480
7625
  var tabDotSize = 6;
7481
7626
  var defaultTabName = "tab";
@@ -7494,7 +7639,7 @@ var TabsComponent = forwardRef17(function Tabs({
7494
7639
  const reactRouterDomPlugin2 = usePlugin("react-router-dom");
7495
7640
  const theme2 = useTheme27();
7496
7641
  const urlQuery = reactRouterDomPlugin2 ? useUrlQuery() : void 0;
7497
- const { componentsState } = useBetterHtmlContextInternal();
7642
+ const { language, componentsState } = useBetterHtmlContextInternal();
7498
7643
  const firstRenderPassedRef = useRef8(false);
7499
7644
  const tabsRef = useRef8({});
7500
7645
  const tabsGap = gap ?? (style === "box" ? theme2.styles.gap / 2 : 0);
@@ -7536,7 +7681,7 @@ var TabsComponent = forwardRef17(function Tabs({
7536
7681
  if (index < selectedTabIndex) spacing += (tab?.getBoundingClientRect().width ?? 0) + tabsGap;
7537
7682
  });
7538
7683
  return spacing;
7539
- }, [selectedTabId, tabs, tabsGap]);
7684
+ }, [rerenderState, selectedTabId, tabs, tabsGap]);
7540
7685
  useEffect14(() => {
7541
7686
  const timeout = setTimeout(() => {
7542
7687
  setRerenderState(Math.random());
@@ -7545,7 +7690,7 @@ var TabsComponent = forwardRef17(function Tabs({
7545
7690
  return () => {
7546
7691
  clearTimeout(timeout);
7547
7692
  };
7548
- }, []);
7693
+ }, [language]);
7549
7694
  useEffect14(() => {
7550
7695
  componentsState.tabs.setTabGroups((oldValue) => {
7551
7696
  const thisTabGroup = oldValue.find((item) => item.name === (name ?? defaultTabName));
@@ -7591,7 +7736,7 @@ var TabsComponent = forwardRef17(function Tabs({
7591
7736
  }, [selectedTabId, onClickTab]);
7592
7737
  return /* @__PURE__ */ jsxs22(Div_default.column, { width: "100%", gap: theme2.styles.space, ...props, children: [
7593
7738
  /* @__PURE__ */ jsxs22(Div_default, { position: "relative", className: "react-better-html-no-scrollbar", overflowY: "auto", children: [
7594
- /* @__PURE__ */ jsx25(Div_default.row, { position: "relative", width: "fit-content", gap: tabsGap, userSelect: "none", children: tabs.map((tab) => {
7739
+ /* @__PURE__ */ jsx26(Div_default.row, { position: "relative", width: "fit-content", gap: tabsGap, userSelect: "none", children: tabs.map((tab) => {
7595
7740
  const selected = tab.id === selectedTabId;
7596
7741
  return /* @__PURE__ */ jsxs22(
7597
7742
  Div_default,
@@ -7616,7 +7761,7 @@ var TabsComponent = forwardRef17(function Tabs({
7616
7761
  tabsRef.current[tab.id] = ref2;
7617
7762
  },
7618
7763
  children: [
7619
- componentsState.tabs.tabsWithDots.includes(tab.id) && /* @__PURE__ */ jsx25(
7764
+ componentsState.tabs.tabsWithDots.includes(tab.id) && /* @__PURE__ */ jsx26(
7620
7765
  Div_default,
7621
7766
  {
7622
7767
  position: "absolute",
@@ -7629,7 +7774,7 @@ var TabsComponent = forwardRef17(function Tabs({
7629
7774
  transition: theme2.styles.transition
7630
7775
  }
7631
7776
  ),
7632
- /* @__PURE__ */ jsx25(
7777
+ /* @__PURE__ */ jsx26(
7633
7778
  Text_default,
7634
7779
  {
7635
7780
  fontWeight: 700,
@@ -7644,7 +7789,7 @@ var TabsComponent = forwardRef17(function Tabs({
7644
7789
  tab.id
7645
7790
  );
7646
7791
  }) }),
7647
- style !== "box" && !noBottomLine && /* @__PURE__ */ jsx25(
7792
+ style !== "box" && !noBottomLine && /* @__PURE__ */ jsx26(
7648
7793
  Div_default,
7649
7794
  {
7650
7795
  position: "absolute",
@@ -7657,7 +7802,7 @@ var TabsComponent = forwardRef17(function Tabs({
7657
7802
  }
7658
7803
  )
7659
7804
  ] }),
7660
- children && /* @__PURE__ */ jsx25(Div_default, { width: "100%", children })
7805
+ children && /* @__PURE__ */ jsx26(Div_default, { width: "100%", children })
7661
7806
  ] });
7662
7807
  });
7663
7808
  TabsComponent.content = function Content({ tabId, tabWithDot, tabsGroupName, isInitialTab, children }) {
@@ -7677,7 +7822,7 @@ TabsComponent.content = function Content({ tabId, tabWithDot, tabsGroupName, isI
7677
7822
  );
7678
7823
  }
7679
7824
  }, [tabWithDot]);
7680
- return (thisTabGroupData ? thisTabGroupData.selectedTab === tabId : isInitialTab) ? /* @__PURE__ */ jsx25(Div_default, { width: "100%", children }) : void 0;
7825
+ return (thisTabGroupData ? thisTabGroupData.selectedTab === tabId : isInitialTab) ? /* @__PURE__ */ jsx26(Div_default, { width: "100%", children }) : void 0;
7681
7826
  };
7682
7827
  var Tabs2 = memo25(TabsComponent);
7683
7828
  Tabs2.content = TabsComponent.content;
@@ -7686,7 +7831,7 @@ var Tabs_default = Tabs2;
7686
7831
  // src/components/Foldable.tsx
7687
7832
  import { forwardRef as forwardRef18, memo as memo26, useCallback as useCallback17, useEffect as useEffect15, useImperativeHandle as useImperativeHandle5, useRef as useRef9, useState as useState14 } from "react";
7688
7833
  import { useBooleanState as useBooleanState7, useTheme as useTheme28 } from "react-better-core";
7689
- import { jsx as jsx26, jsxs as jsxs23 } from "react/jsx-runtime";
7834
+ import { jsx as jsx27, jsxs as jsxs23 } from "react/jsx-runtime";
7690
7835
  var animationDurationClose = 0.15;
7691
7836
  var animationDurationOpen = animationDurationClose * 2;
7692
7837
  var FoldableComponent = forwardRef18(function Foldable({
@@ -7766,7 +7911,7 @@ var FoldableComponent = forwardRef18(function Foldable({
7766
7911
  isOpen
7767
7912
  };
7768
7913
  }, [open, close, toggleOpen, isOpen]);
7769
- const arrow = /* @__PURE__ */ jsx26(Icon_default, { name: "chevronDown", transform: `rotate(${isOpen ? 180 : 0}deg)`, transition: theme2.styles.transition });
7914
+ const arrow = /* @__PURE__ */ jsx27(Icon_default, { name: "chevronDown", transform: `rotate(${isOpen ? 180 : 0}deg)`, transition: theme2.styles.transition });
7770
7915
  return /* @__PURE__ */ jsxs23(Div_default.column, { width: "100%", ...props, children: [
7771
7916
  renderHeader ? renderHeader(isOpen, toggleOpen) : /* @__PURE__ */ jsxs23(
7772
7917
  Div_default.row,
@@ -7781,7 +7926,7 @@ var FoldableComponent = forwardRef18(function Foldable({
7781
7926
  userSelect: "none",
7782
7927
  children: [
7783
7928
  arrowPosition === "left" && arrow,
7784
- /* @__PURE__ */ jsx26(Div_default, { flex: 1, children: /* @__PURE__ */ jsx26(
7929
+ /* @__PURE__ */ jsx27(Div_default, { flex: 1, children: /* @__PURE__ */ jsx27(
7785
7930
  PageHeader_default,
7786
7931
  {
7787
7932
  icon,
@@ -7809,8 +7954,8 @@ var FoldableComponent = forwardRef18(function Foldable({
7809
7954
  ]
7810
7955
  }
7811
7956
  ),
7812
- /* @__PURE__ */ jsx26(Div_default, { height: isOpen ? 1 : 0, opacity: isOpen ? 1 : 0, transition: theme2.styles.transition, children: /* @__PURE__ */ jsx26(Divider_default.horizontal, { width: theme2.styles.borderWidth === 0 ? 1 : theme2.styles.borderWidth }) }),
7813
- /* @__PURE__ */ jsx26(
7957
+ /* @__PURE__ */ jsx27(Div_default, { height: isOpen ? 1 : 0, opacity: isOpen ? 1 : 0, transition: theme2.styles.transition, children: /* @__PURE__ */ jsx27(Divider_default.horizontal, { width: theme2.styles.borderWidth === 0 ? 1 : theme2.styles.borderWidth }) }),
7958
+ /* @__PURE__ */ jsx27(
7814
7959
  Div_default,
7815
7960
  {
7816
7961
  maxHeight: isOpen ? bodyVirtualHeight : 0,
@@ -7819,14 +7964,14 @@ var FoldableComponent = forwardRef18(function Foldable({
7819
7964
  overflow: !isOpen ? "hidden" : void 0,
7820
7965
  pointerEvents: !isOpen ? "none" : void 0,
7821
7966
  ref: bodyRef,
7822
- children: /* @__PURE__ */ jsx26(Div_default, { paddingBlock: theme2.styles.gap, paddingInline: headerPaddingInline, children })
7967
+ children: /* @__PURE__ */ jsx27(Div_default, { paddingBlock: theme2.styles.gap, paddingInline: headerPaddingInline, children })
7823
7968
  }
7824
7969
  )
7825
7970
  ] });
7826
7971
  });
7827
7972
  FoldableComponent.box = forwardRef18(function Box3({ ...props }, ref) {
7828
7973
  const theme2 = useTheme28();
7829
- return /* @__PURE__ */ jsx26(
7974
+ return /* @__PURE__ */ jsx27(
7830
7975
  FoldableComponent,
7831
7976
  {
7832
7977
  backgroundColor: theme2.colors.backgroundContent,
@@ -7852,7 +7997,7 @@ import {
7852
7997
  useBooleanState as useBooleanState8,
7853
7998
  useTheme as useTheme29
7854
7999
  } from "react-better-core";
7855
- import { Fragment as Fragment8, jsx as jsx27, jsxs as jsxs24 } from "react/jsx-runtime";
8000
+ import { Fragment as Fragment10, jsx as jsx28, jsxs as jsxs24 } from "react/jsx-runtime";
7856
8001
  var tabDotSize2 = 6;
7857
8002
  var sideMenuContext = createContext2(void 0);
7858
8003
  var SideMenuContextProvider = sideMenuContext.Provider;
@@ -7904,12 +8049,12 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
7904
8049
  const lineWidth = 2;
7905
8050
  const lineEndRadius = iconSize / 2 + iconGap * 2;
7906
8051
  const backgroundColorContrast = activeItemColor ? calculateColorContrast(activeItemColor, theme2.colors.primary) : 21;
7907
- const content = /* @__PURE__ */ jsx27(
8052
+ const content = /* @__PURE__ */ jsx28(
7908
8053
  Tooltip_default,
7909
8054
  {
7910
8055
  content: /* @__PURE__ */ jsxs24(Div_default.row, { alignItems: "center", gap: theme2.styles.gap, children: [
7911
- /* @__PURE__ */ jsx27(Text_default, { whiteSpace: "nowrap", children: item.text }),
7912
- item.children && /* @__PURE__ */ jsx27(Icon_default, { name: "chevronDown", color: theme2.colors.textSecondary, size: 14 })
8056
+ /* @__PURE__ */ jsx28(Text_default, { whiteSpace: "nowrap", children: item.text }),
8057
+ item.children && /* @__PURE__ */ jsx28(Icon_default, { name: "chevronDown", color: theme2.colors.textSecondary, size: 14 })
7913
8058
  ] }),
7914
8059
  contentPointerEvents: "none",
7915
8060
  withArrow: true,
@@ -7934,7 +8079,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
7934
8079
  opacity: item.disabled ? 0.6 : void 0,
7935
8080
  onClick: onClickElement,
7936
8081
  children: [
7937
- /* @__PURE__ */ jsx27(
8082
+ /* @__PURE__ */ jsx28(
7938
8083
  Icon_default,
7939
8084
  {
7940
8085
  name: item.iconName,
@@ -7943,7 +8088,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
7943
8088
  flexShrink: 0
7944
8089
  }
7945
8090
  ),
7946
- /* @__PURE__ */ jsx27(
8091
+ /* @__PURE__ */ jsx28(
7947
8092
  Text_default,
7948
8093
  {
7949
8094
  flex: 1,
@@ -7954,7 +8099,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
7954
8099
  children: item.text
7955
8100
  }
7956
8101
  ),
7957
- item.children && /* @__PURE__ */ jsx27(
8102
+ item.children && /* @__PURE__ */ jsx28(
7958
8103
  Icon_default,
7959
8104
  {
7960
8105
  name: "chevronDown",
@@ -7964,7 +8109,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
7964
8109
  transition: theme2.styles.transition
7965
8110
  }
7966
8111
  ),
7967
- /* @__PURE__ */ jsx27(
8112
+ /* @__PURE__ */ jsx28(
7968
8113
  Div_default,
7969
8114
  {
7970
8115
  position: "absolute",
@@ -8006,8 +8151,8 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
8006
8151
  setIsOpened.setFalse();
8007
8152
  }, [isCollapsed]);
8008
8153
  const LinkComponentTag = components.button?.tagReplacement?.linkComponent ?? "a";
8009
- return /* @__PURE__ */ jsxs24(Fragment8, { children: [
8010
- item.href ? /* @__PURE__ */ jsx27(LinkComponentTag, { to: item.href, href: item.href, onClick: onClickElement, children: content }) : content,
8154
+ return /* @__PURE__ */ jsxs24(Fragment10, { children: [
8155
+ item.href ? /* @__PURE__ */ jsx28(LinkComponentTag, { to: item.href, href: item.href, onClick: onClickElement, children: content }) : content,
8011
8156
  item.children && /* @__PURE__ */ jsxs24(
8012
8157
  Div_default.column,
8013
8158
  {
@@ -8019,7 +8164,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
8019
8164
  overflow: "hidden",
8020
8165
  transition: `max-height ${theme2.styles.transition}, margin-top ${theme2.styles.transition}`,
8021
8166
  children: [
8022
- item.children.map((child) => /* @__PURE__ */ jsx27(
8167
+ item.children.map((child) => /* @__PURE__ */ jsx28(
8023
8168
  MenuItemComponent,
8024
8169
  {
8025
8170
  item: child,
@@ -8038,7 +8183,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
8038
8183
  left: paddingLeft + iconSize / 2,
8039
8184
  zIndex: -1,
8040
8185
  children: [
8041
- /* @__PURE__ */ jsx27(
8186
+ /* @__PURE__ */ jsx28(
8042
8187
  Div_default,
8043
8188
  {
8044
8189
  position: "relative",
@@ -8048,7 +8193,7 @@ var MenuItemTypeItem = memo27(function MenuItemTypeItem2({
8048
8193
  zIndex: 1
8049
8194
  }
8050
8195
  ),
8051
- /* @__PURE__ */ jsx27(
8196
+ /* @__PURE__ */ jsx28(
8052
8197
  Div_default,
8053
8198
  {
8054
8199
  position: "absolute",
@@ -8078,7 +8223,7 @@ var MenuItemTypeDivider = memo27(function MenuItemTypeDivider2({ item }) {
8078
8223
  const { items } = useSideMenuContext();
8079
8224
  const isCollapsed = sideMenuIsCollapsed && !item.shortText;
8080
8225
  const isFirst = items[0]?.type === item.type && items[0]?.text === item.text;
8081
- return /* @__PURE__ */ jsx27(
8226
+ return /* @__PURE__ */ jsx28(
8082
8227
  Div_default.row,
8083
8228
  {
8084
8229
  maxHeight: !isCollapsed ? 30 : theme2.styles.gap + 1,
@@ -8086,7 +8231,7 @@ var MenuItemTypeDivider = memo27(function MenuItemTypeDivider2({ item }) {
8086
8231
  paddingInline: theme2.styles.gap,
8087
8232
  overflow: "hidden",
8088
8233
  transition: `max-height ${theme2.styles.transition}, padding-top ${theme2.styles.transition}`,
8089
- children: sideMenuIsCollapsed && item.shortText || !sideMenuIsCollapsed ? /* @__PURE__ */ jsx27(
8234
+ children: sideMenuIsCollapsed && item.shortText || !sideMenuIsCollapsed ? /* @__PURE__ */ jsx28(
8090
8235
  Text_default,
8091
8236
  {
8092
8237
  width: "100%",
@@ -8098,12 +8243,12 @@ var MenuItemTypeDivider = memo27(function MenuItemTypeDivider2({ item }) {
8098
8243
  whiteSpace: "nowrap",
8099
8244
  children: sideMenuIsCollapsed ? item.shortText : item.text
8100
8245
  }
8101
- ) : !isFirst ? /* @__PURE__ */ jsx27(Divider_default.horizontal, {}) : void 0
8246
+ ) : !isFirst ? /* @__PURE__ */ jsx28(Divider_default.horizontal, {}) : void 0
8102
8247
  }
8103
8248
  );
8104
8249
  });
8105
8250
  var MenuItemComponent = memo27(function MenuItemComponent2({ item, ...props }) {
8106
- return /* @__PURE__ */ jsx27(Div_default, { width: "100%", children: item.type === "item" ? /* @__PURE__ */ jsx27(MenuItemTypeItem, { item, ...props }) : item.type === "divider" ? /* @__PURE__ */ jsx27(MenuItemTypeDivider, { item }) : void 0 });
8251
+ return /* @__PURE__ */ jsx28(Div_default, { width: "100%", children: item.type === "item" ? /* @__PURE__ */ jsx28(MenuItemTypeItem, { item, ...props }) : item.type === "divider" ? /* @__PURE__ */ jsx28(MenuItemTypeDivider, { item }) : void 0 });
8107
8252
  });
8108
8253
  var SideMenuComponent = function SideMenu({
8109
8254
  items,
@@ -8165,7 +8310,7 @@ var SideMenuComponent = function SideMenu({
8165
8310
  useEffect16(() => {
8166
8311
  setBottomItemsState(bottomItems);
8167
8312
  }, [bottomItems]);
8168
- const itemsComponent = /* @__PURE__ */ jsx27(
8313
+ const itemsComponent = /* @__PURE__ */ jsx28(
8169
8314
  Div_default.column,
8170
8315
  {
8171
8316
  width: "100%",
@@ -8173,7 +8318,7 @@ var SideMenuComponent = function SideMenu({
8173
8318
  overflowY: !isCollapsed ? "auto" : void 0,
8174
8319
  paddingInline: !renderItemsHolder ? theme2.styles.space : void 0,
8175
8320
  paddingBottom: !renderItemsHolder ? !isCollapsable && !readyBottomItems ? theme2.styles.space : void 0 : void 0,
8176
- children: /* @__PURE__ */ jsx27(Div_default.column, { gap: theme2.styles.gap / 2, children: readyItems.map((item) => /* @__PURE__ */ jsx27(
8321
+ children: /* @__PURE__ */ jsx28(Div_default.column, { gap: theme2.styles.gap / 2, children: readyItems.map((item) => /* @__PURE__ */ jsx28(
8177
8322
  MenuItemComponent,
8178
8323
  {
8179
8324
  item,
@@ -8183,11 +8328,11 @@ var SideMenuComponent = function SideMenu({
8183
8328
  location,
8184
8329
  onClick: onClickXButton
8185
8330
  },
8186
- item.text
8331
+ item.type + item.text
8187
8332
  )) })
8188
8333
  }
8189
8334
  );
8190
- const bottomItemsComponent = /* @__PURE__ */ jsx27(
8335
+ const bottomItemsComponent = /* @__PURE__ */ jsx28(
8191
8336
  Div_default.column,
8192
8337
  {
8193
8338
  borderTop: mediaQuery.size1000 ? `solid ${theme2.styles.borderWidth}px ${theme2.colors.border}` : void 0,
@@ -8196,7 +8341,7 @@ var SideMenuComponent = function SideMenu({
8196
8341
  paddingTop: mediaQuery.size1000 ? theme2.styles.space : void 0,
8197
8342
  paddingInline: !renderItemsHolder ? theme2.styles.space : void 0,
8198
8343
  paddingBottom: !renderItemsHolder ? !isCollapsable ? theme2.styles.space : void 0 : void 0,
8199
- children: readyBottomItems?.map((item) => /* @__PURE__ */ jsx27(
8344
+ children: readyBottomItems?.map((item) => /* @__PURE__ */ jsx28(
8200
8345
  MenuItemComponent,
8201
8346
  {
8202
8347
  item,
@@ -8206,11 +8351,11 @@ var SideMenuComponent = function SideMenu({
8206
8351
  location,
8207
8352
  onClick: onClickXButton
8208
8353
  },
8209
- item.text
8354
+ item.type + item.text
8210
8355
  ))
8211
8356
  }
8212
8357
  );
8213
- return /* @__PURE__ */ jsx27(SideMenuContextProvider, { value: contextValue, children: /* @__PURE__ */ jsxs24(
8358
+ return /* @__PURE__ */ jsx28(SideMenuContextProvider, { value: contextValue, children: /* @__PURE__ */ jsxs24(
8214
8359
  Div_default.column,
8215
8360
  {
8216
8361
  as: "aside",
@@ -8230,7 +8375,7 @@ var SideMenuComponent = function SideMenu({
8230
8375
  children: [
8231
8376
  /* @__PURE__ */ jsxs24(Div_default.column, { width: "100%", height: "100%", gap: gap ?? theme2.styles.space, children: [
8232
8377
  (logoAssetName || logoUrl || withCloseButton && mediaQuery.size1000) && /* @__PURE__ */ jsxs24(Div_default.row, { alignItems: "center", paddingInline: theme2.styles.space, children: [
8233
- (logoAssetName || logoUrl) && /* @__PURE__ */ jsx27(LinkComponentTag, { to: "/", href: "/", onClick: onClickXButton, children: /* @__PURE__ */ jsxs24(
8378
+ (logoAssetName || logoUrl) && /* @__PURE__ */ jsx28(LinkComponentTag, { to: "/", href: "/", onClick: onClickXButton, children: /* @__PURE__ */ jsxs24(
8234
8379
  Div_default.row,
8235
8380
  {
8236
8381
  alignItems: "center",
@@ -8239,7 +8384,7 @@ var SideMenuComponent = function SideMenu({
8239
8384
  whiteSpace: "nowrap",
8240
8385
  gap: theme2.styles.gap,
8241
8386
  children: [
8242
- /* @__PURE__ */ jsx27(
8387
+ /* @__PURE__ */ jsx28(
8243
8388
  Image_default,
8244
8389
  {
8245
8390
  name: logoAssetName,
@@ -8249,7 +8394,7 @@ var SideMenuComponent = function SideMenu({
8249
8394
  objectFit: "contain"
8250
8395
  }
8251
8396
  ),
8252
- logoText && /* @__PURE__ */ jsx27(
8397
+ logoText && /* @__PURE__ */ jsx28(
8253
8398
  Text_default,
8254
8399
  {
8255
8400
  fontFamily: logoFontFamily,
@@ -8264,23 +8409,23 @@ var SideMenuComponent = function SideMenu({
8264
8409
  ]
8265
8410
  }
8266
8411
  ) }),
8267
- withCloseButton && mediaQuery.size1000 && /* @__PURE__ */ jsx27(Button_default.icon, { icon: "XMark", marginLeft: "auto", onClick: onClickXButton })
8412
+ withCloseButton && mediaQuery.size1000 && /* @__PURE__ */ jsx28(Button_default.icon, { icon: "XMark", marginLeft: "auto", onClick: onClickXButton })
8268
8413
  ] }),
8269
8414
  itemsAdditionalComponent,
8270
- !isLoading ? /* @__PURE__ */ jsxs24(Fragment8, { children: [
8415
+ !isLoading ? /* @__PURE__ */ jsxs24(Fragment10, { children: [
8271
8416
  renderItemsHolder ? renderItemsHolder(itemsComponent) : itemsComponent,
8272
8417
  betweenItemsAdditionalComponent,
8273
- readyBottomItems && /* @__PURE__ */ jsx27(Fragment8, { children: renderBottomItemsHolder ? renderBottomItemsHolder(bottomItemsComponent) : bottomItemsComponent })
8274
- ] }) : /* @__PURE__ */ jsx27(Div_default, { flex: 1, children: /* @__PURE__ */ jsx27(Loader_default.box, { text: isCollapsed ? "" : void 0 }) }),
8418
+ readyBottomItems && /* @__PURE__ */ jsx28(Fragment10, { children: renderBottomItemsHolder ? renderBottomItemsHolder(bottomItemsComponent) : bottomItemsComponent })
8419
+ ] }) : /* @__PURE__ */ jsx28(Div_default, { flex: 1, children: /* @__PURE__ */ jsx28(Loader_default.box, { text: isCollapsed ? "" : void 0 }) }),
8275
8420
  bottomItemsAdditionalComponent,
8276
- isCollapsable && /* @__PURE__ */ jsx27(
8421
+ isCollapsable && /* @__PURE__ */ jsx28(
8277
8422
  Div_default,
8278
8423
  {
8279
8424
  borderTop: `solid ${theme2.styles.borderWidth}px ${theme2.colors.border}`,
8280
8425
  marginTop: !readyBottomItems ? "auto" : void 0,
8281
8426
  paddingInline: theme2.styles.space,
8282
8427
  paddingBlock: theme2.styles.space,
8283
- children: /* @__PURE__ */ jsx27(
8428
+ children: /* @__PURE__ */ jsx28(
8284
8429
  Div_default.row,
8285
8430
  {
8286
8431
  alignItems: "center",
@@ -8292,7 +8437,7 @@ var SideMenuComponent = function SideMenu({
8292
8437
  isTabAccessed: true,
8293
8438
  paddingBlock: theme2.styles.gap,
8294
8439
  onClick: setSideMenuIsCollapsed.toggle,
8295
- children: /* @__PURE__ */ jsx27(
8440
+ children: /* @__PURE__ */ jsx28(
8296
8441
  Icon_default,
8297
8442
  {
8298
8443
  name: "chevronRight",
@@ -8307,7 +8452,7 @@ var SideMenuComponent = function SideMenu({
8307
8452
  }
8308
8453
  )
8309
8454
  ] }),
8310
- widthMobileHandle && /* @__PURE__ */ jsx27(
8455
+ widthMobileHandle && /* @__PURE__ */ jsx28(
8311
8456
  Div_default.row,
8312
8457
  {
8313
8458
  position: "absolute",
@@ -8327,7 +8472,7 @@ var SideMenuComponent = function SideMenu({
8327
8472
  transform: !mediaQuery.size1000 ? "translateX(-100%)" : void 0,
8328
8473
  transition: theme2.styles.transition,
8329
8474
  onClick: setSideMenuIsOpenMobile.toggle,
8330
- children: /* @__PURE__ */ jsx27(
8475
+ children: /* @__PURE__ */ jsx28(
8331
8476
  Icon_default,
8332
8477
  {
8333
8478
  name: "chevronRight",
@@ -8339,7 +8484,7 @@ var SideMenuComponent = function SideMenu({
8339
8484
  )
8340
8485
  }
8341
8486
  ),
8342
- absoluteComponent && /* @__PURE__ */ jsx27(Div_default, { position: "absolute", top: 0, left: 0, pointerEvents: "none", zIndex: 2, children: /* @__PURE__ */ jsx27(Div_default, { pointerEvents: "all", children: absoluteComponent }) })
8487
+ absoluteComponent && /* @__PURE__ */ jsx28(Div_default, { position: "absolute", top: 0, left: 0, pointerEvents: "none", zIndex: 2, children: /* @__PURE__ */ jsx28(Div_default, { pointerEvents: "all", children: absoluteComponent }) })
8343
8488
  ]
8344
8489
  }
8345
8490
  ) });
@@ -8363,7 +8508,7 @@ SideMenuComponent.pageHolder = function SideMenuPageHolder({
8363
8508
  transition: theme2.styles.transition,
8364
8509
  children: [
8365
8510
  additionalTopComponent,
8366
- /* @__PURE__ */ jsx27(PageHolder_default, { ...props }),
8511
+ /* @__PURE__ */ jsx28(PageHolder_default, { ...props }),
8367
8512
  additionalBottomComponent
8368
8513
  ]
8369
8514
  }
@@ -8390,7 +8535,7 @@ SideMenuComponent.burgerButton = function BurgerButton({ position = "left", onCl
8390
8535
  onMouseOut: setIsHovered.setFalse,
8391
8536
  onClick: onClickElement,
8392
8537
  children: [
8393
- /* @__PURE__ */ jsx27(
8538
+ /* @__PURE__ */ jsx28(
8394
8539
  Div_default,
8395
8540
  {
8396
8541
  position: "absolute",
@@ -8405,7 +8550,7 @@ SideMenuComponent.burgerButton = function BurgerButton({ position = "left", onCl
8405
8550
  transition: theme2.styles.transition
8406
8551
  }
8407
8552
  ),
8408
- /* @__PURE__ */ jsx27(
8553
+ /* @__PURE__ */ jsx28(
8409
8554
  Div_default,
8410
8555
  {
8411
8556
  position: "absolute",
@@ -8421,7 +8566,7 @@ SideMenuComponent.burgerButton = function BurgerButton({ position = "left", onCl
8421
8566
  transition: theme2.styles.transition
8422
8567
  }
8423
8568
  ),
8424
- /* @__PURE__ */ jsx27(
8569
+ /* @__PURE__ */ jsx28(
8425
8570
  Div_default,
8426
8571
  {
8427
8572
  position: "absolute",
@@ -8487,6 +8632,7 @@ export {
8487
8632
  formatPhoneNumber,
8488
8633
  generateApi,
8489
8634
  generateEventEmitter,
8635
+ generateI18n,
8490
8636
  generateLocalStorage,
8491
8637
  generateRandomString,
8492
8638
  getBrowser,