@owp/core 2.2.5 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (238) hide show
  1. package/dist/_virtual/index11.js +2 -2
  2. package/dist/_virtual/index12.js +2 -2
  3. package/dist/_virtual/index13.js +2 -2
  4. package/dist/_virtual/index14.js +2 -2
  5. package/dist/_virtual/index16.js +5 -2
  6. package/dist/_virtual/index16.js.map +1 -1
  7. package/dist/_virtual/index17.js +2 -2
  8. package/dist/_virtual/index5.js +2 -5
  9. package/dist/_virtual/index5.js.map +1 -1
  10. package/dist/_virtual/index6.js +2 -2
  11. package/dist/_virtual/index7.js +2 -2
  12. package/dist/components/OwpDialog/OwpDialog.js +48 -46
  13. package/dist/components/OwpDialog/OwpDialog.js.map +1 -1
  14. package/dist/components/OwpErrorStatusPage/OwpErrorStatusPage.js +24 -24
  15. package/dist/components/OwpErrorStatusPage/OwpErrorStatusPage.js.map +1 -1
  16. package/dist/components/OwpLayout/OwpLayout.js +29 -30
  17. package/dist/components/OwpLayout/OwpLayout.js.map +1 -1
  18. package/dist/components/OwpMrtTable/OwpMrtTable.js +2 -2
  19. package/dist/components/OwpMrtTable/OwpMrtTable.js.map +1 -1
  20. package/dist/components/OwpMrtTable/{OwpMrtTableNoDataOverlay.js → internal/OwpMrtTableNoDataOverlay.js} +1 -1
  21. package/dist/components/OwpMrtTable/internal/OwpMrtTableNoDataOverlay.js.map +1 -0
  22. package/dist/components/OwpMrtTable/{OwpMrtTableTopToolbar.js → internal/OwpMrtTableTopToolbar.js} +3 -3
  23. package/dist/components/OwpMrtTable/internal/OwpMrtTableTopToolbar.js.map +1 -0
  24. package/dist/components/OwpPageCarded/OwpPageCarded.js +81 -77
  25. package/dist/components/OwpPageCarded/OwpPageCarded.js.map +1 -1
  26. package/dist/components/OwpPageCarded/{OwpPageCardedHeader.js → internal/OwpPageCardedHeader.js} +2 -2
  27. package/dist/components/OwpPageCarded/internal/OwpPageCardedHeader.js.map +1 -0
  28. package/dist/components/OwpPageCarded/{OwpPageCardedSidebar.js → internal/OwpPageCardedSidebar.js} +3 -3
  29. package/dist/components/OwpPageCarded/internal/OwpPageCardedSidebar.js.map +1 -0
  30. package/dist/components/OwpPageCarded/{OwpPageCardedSidebarContent.js → internal/OwpPageCardedSidebarContent.js} +2 -2
  31. package/dist/components/OwpPageCarded/internal/OwpPageCardedSidebarContent.js.map +1 -0
  32. package/dist/components/OwpPicker/OwpDatePicker.js +90 -83
  33. package/dist/components/OwpPicker/OwpDatePicker.js.map +1 -1
  34. package/dist/components/OwpPicker/OwpDateRangePicker.js +57 -50
  35. package/dist/components/OwpPicker/OwpDateRangePicker.js.map +1 -1
  36. package/dist/components/OwpPicker/OwpTimePicker.js +65 -61
  37. package/dist/components/OwpPicker/OwpTimePicker.js.map +1 -1
  38. package/dist/components/OwpPicker/OwpWeekDatePicker.js +58 -52
  39. package/dist/components/OwpPicker/OwpWeekDatePicker.js.map +1 -1
  40. package/dist/components/OwpPicker/OwpYearRangePicker.js +68 -62
  41. package/dist/components/OwpPicker/OwpYearRangePicker.js.map +1 -1
  42. package/dist/components/OwpPicker/{constants.js → constants/index.js} +1 -1
  43. package/dist/components/OwpPicker/constants/index.js.map +1 -0
  44. package/dist/components/OwpPicker/{AnimatedCalendarContainer.js → internal/AnimatedCalendarContainer.js} +2 -2
  45. package/dist/components/OwpPicker/internal/AnimatedCalendarContainer.js.map +1 -0
  46. package/dist/components/OwpPicker/{CalendarContainer.js → internal/CalendarContainer.js} +2 -2
  47. package/dist/components/OwpPicker/internal/CalendarContainer.js.map +1 -0
  48. package/dist/components/OwpPicker/{DatePickerInput.js → internal/DatePickerInput.js} +4 -4
  49. package/dist/components/OwpPicker/internal/DatePickerInput.js.map +1 -0
  50. package/dist/components/OwpQuerySelector/OwpQuerySelector.js +205 -171
  51. package/dist/components/OwpQuerySelector/OwpQuerySelector.js.map +1 -1
  52. package/dist/components/OwpScrollbars/OwpScrollbars.js +16 -17
  53. package/dist/components/OwpScrollbars/OwpScrollbars.js.map +1 -1
  54. package/dist/components/OwpSelectorBase/OwpSelectorAutocomplete.js +112 -103
  55. package/dist/components/OwpSelectorBase/OwpSelectorAutocomplete.js.map +1 -1
  56. package/dist/components/OwpStyleProvider/OwpStyleProvider.js +86 -39
  57. package/dist/components/OwpStyleProvider/OwpStyleProvider.js.map +1 -1
  58. package/dist/components/OwpSuspense/OwpSuspense.js.map +1 -1
  59. package/dist/components/OwpTable/OwpTable.js +50 -51
  60. package/dist/components/OwpTable/OwpTable.js.map +1 -1
  61. package/dist/components/OwpTreeGrid/OwpTreeGrid.js +163 -308
  62. package/dist/components/OwpTreeGrid/OwpTreeGrid.js.map +1 -1
  63. package/dist/components/OwpTreeGrid/hooks/useOwpTreeGridOverlayFrame.js +1 -1
  64. package/dist/components/OwpTreeGrid/hooks/useOwpTreeGridOverlayFrame.js.map +1 -1
  65. package/dist/components/OwpTreeGrid/{OwpTreeGridLoadingOverlay.js → internal/OwpTreeGridLoadingOverlay.js} +2 -2
  66. package/dist/components/OwpTreeGrid/internal/OwpTreeGridLoadingOverlay.js.map +1 -0
  67. package/dist/components/OwpTreeGrid/{OwpTreeGridNoDataOverlay.js → internal/OwpTreeGridNoDataOverlay.js} +2 -2
  68. package/dist/components/OwpTreeGrid/internal/OwpTreeGridNoDataOverlay.js.map +1 -0
  69. package/dist/components/OwpTreeGrid/{utils/index.js → internal/treeGridLayout.js} +1 -1
  70. package/dist/components/OwpTreeGrid/internal/treeGridLayout.js.map +1 -0
  71. package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js +182 -0
  72. package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js.map +1 -0
  73. package/dist/components/OwpTreeGrid/utils/perf.js.map +1 -0
  74. package/dist/components/OwpZoomImageSlider/OwpZoomImageSlider.js +1 -1
  75. package/dist/components/OwpZoomImageSlider/OwpZoomImageSlider.js.map +1 -1
  76. package/dist/components/OwpZoomImageSlider/{ZoomImage.js → internal/ZoomImage.js} +1 -1
  77. package/dist/components/OwpZoomImageSlider/internal/ZoomImage.js.map +1 -0
  78. package/dist/contexts/OwpCoreProvider.js +22 -36
  79. package/dist/contexts/OwpCoreProvider.js.map +1 -1
  80. package/dist/contexts/OwpStoreProvider.js +9 -9
  81. package/dist/contexts/OwpStoreProvider.js.map +1 -1
  82. package/dist/hooks/useNavbar.js +24 -0
  83. package/dist/hooks/useNavbar.js.map +1 -0
  84. package/dist/hooks/useOwpSettings.js +21 -0
  85. package/dist/hooks/useOwpSettings.js.map +1 -0
  86. package/dist/hooks.js +75 -62
  87. package/dist/hooks.js.map +1 -1
  88. package/dist/index.js +98 -104
  89. package/dist/index.js.map +1 -1
  90. package/dist/layout/Layout.js +28 -29
  91. package/dist/layout/Layout.js.map +1 -1
  92. package/dist/layout/components/layouts/FooterLayout.js +15 -16
  93. package/dist/layout/components/layouts/FooterLayout.js.map +1 -1
  94. package/dist/layout/components/layouts/NavbarToggleFabLayout.js +21 -18
  95. package/dist/layout/components/layouts/NavbarToggleFabLayout.js.map +1 -1
  96. package/dist/layout/components/layouts/NavbarWrapperLayout.js +20 -21
  97. package/dist/layout/components/layouts/NavbarWrapperLayout.js.map +1 -1
  98. package/dist/layout/components/navbar/NavbarPinToggleButton.js +10 -11
  99. package/dist/layout/components/navbar/NavbarPinToggleButton.js.map +1 -1
  100. package/dist/layout/components/navbar/NavbarToggleButton.js +31 -32
  101. package/dist/layout/components/navbar/NavbarToggleButton.js.map +1 -1
  102. package/dist/layout/components/navbar/style/NavbarStyle.js +36 -37
  103. package/dist/layout/components/navbar/style/NavbarStyle.js.map +1 -1
  104. package/dist/layout/components/navbar/style/NavbarStyleContent.js +29 -30
  105. package/dist/layout/components/navbar/style/NavbarStyleContent.js.map +1 -1
  106. package/dist/layout/components/navigation/Navigation.js +18 -22
  107. package/dist/layout/components/navigation/Navigation.js.map +1 -1
  108. package/dist/layout/components/toggles/NavigationSearchToggle.js +55 -60
  109. package/dist/layout/components/toggles/NavigationSearchToggle.js.map +1 -1
  110. package/dist/layout/components/toggles/NavigationShortcutsToggle.js +44 -49
  111. package/dist/layout/components/toggles/NavigationShortcutsToggle.js.map +1 -1
  112. package/dist/layout/components/toolbar/ToolbarLayout.js +26 -27
  113. package/dist/layout/components/toolbar/ToolbarLayout.js.map +1 -1
  114. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/constants.js +1 -1
  115. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/index.js +1 -1
  116. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE39/index.js +1 -1
  117. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/constants.js +1 -1
  118. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/index.js +1 -1
  119. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/constants.js +1 -1
  120. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/index.js +1 -1
  121. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/GenericBarcode/index.js +1 -1
  122. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/constants.js +1 -1
  123. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/index.js +1 -1
  124. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/MSI/index.js +1 -1
  125. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/codabar/index.js +1 -1
  126. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/pharmacode/index.js +1 -1
  127. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/renderers/index.js +1 -1
  128. package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.js +1 -1
  129. package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/utils.js +1 -1
  130. package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/utils.js +1 -1
  131. package/dist/node_modules/.pnpm/react-imask@7.6.1_react@19.2.4/node_modules/react-imask/esm/mixin.js +1 -1
  132. package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js +1 -1
  133. package/dist/node_modules/.pnpm/react-overlays@5.2.1_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/react-overlays/esm/Portal.js +1 -1
  134. package/dist/owp-app.css +1 -1
  135. package/dist/store/atoms/navbarAtoms.js +84 -0
  136. package/dist/store/atoms/navbarAtoms.js.map +1 -0
  137. package/dist/store/atoms/owpSettingsAtoms.js +140 -0
  138. package/dist/store/atoms/owpSettingsAtoms.js.map +1 -0
  139. package/dist/store/atoms/owpStore.js +29 -0
  140. package/dist/store/atoms/owpStore.js.map +1 -0
  141. package/dist/store.js +44 -39
  142. package/dist/store.js.map +1 -1
  143. package/dist/types/components/OwpPageCarded/OwpPageCarded.d.ts +12 -41
  144. package/dist/types/components/OwpPageSkeleton/index.d.ts +1 -0
  145. package/dist/types/components/OwpPicker/OwpWeekDatePicker.d.ts +0 -1
  146. package/dist/types/components/OwpPicker/OwpYearRangePicker.d.ts +0 -1
  147. package/dist/types/components/OwpPicker/{DatePickerInput.d.ts → internal/DatePickerInput.d.ts} +1 -1
  148. package/dist/types/components/OwpQuerySelector/OwpQuerySelector.d.ts +1 -1
  149. package/dist/types/components/OwpQuerySelector/types/types.d.ts +2 -0
  150. package/dist/types/components/OwpTable/OwpTable.d.ts +1 -1
  151. package/dist/types/components/OwpTabs/OwpTab.d.ts +1 -1
  152. package/dist/types/components/OwpTabs/OwpTabs.d.ts +1 -1
  153. package/dist/types/components/OwpTreeGrid/OwpTreeGrid.d.ts +3 -1
  154. package/dist/types/components/OwpTreeGrid/{OwpTreeGridLoadingOverlay.d.ts → internal/OwpTreeGridLoadingOverlay.d.ts} +1 -1
  155. package/dist/types/components/OwpTreeGrid/{OwpTreeGridNoDataOverlay.d.ts → internal/OwpTreeGridNoDataOverlay.d.ts} +1 -1
  156. package/dist/types/components/OwpTreeGrid/{utils/index.d.ts → internal/treeGridLayout.d.ts} +0 -2
  157. package/dist/types/components/OwpTreeGrid/internal/treeGridRuntime.d.ts +75 -0
  158. package/dist/types/contexts/OwpCoreProvider.d.ts +2 -2
  159. package/dist/types/contexts/OwpStoreProvider.d.ts +4 -4
  160. package/dist/types/hooks/index.d.ts +2 -1
  161. package/dist/types/hooks/useNavbar.d.ts +19 -0
  162. package/dist/types/hooks/useOwpSettings.d.ts +79 -0
  163. package/dist/types/index.d.ts +1 -4
  164. package/dist/types/layout/components/navigation/Navigation.d.ts +6 -2
  165. package/dist/types/layout/components/toggles/NavigationSearchToggle.d.ts +5 -2
  166. package/dist/types/layout/components/toggles/NavigationShortcutsToggle.d.ts +5 -2
  167. package/dist/types/store/atoms/index.d.ts +3 -0
  168. package/dist/types/store/atoms/internal/types.d.ts +29 -0
  169. package/dist/types/store/atoms/navbarAtoms.d.ts +48 -0
  170. package/dist/types/store/atoms/owpSettingsAtoms.d.ts +89 -0
  171. package/dist/types/store/atoms/owpStore.d.ts +13 -0
  172. package/dist/types/store/index.d.ts +1 -3
  173. package/dist/types/types/OwpNavigationTypes.d.ts +14 -0
  174. package/dist/types/types/index.d.ts +1 -1
  175. package/dist/types/utils/index.d.ts +1 -0
  176. package/dist/types/utils/navigationUtils.d.ts +6 -2
  177. package/dist/types/utils/normalizeTimeToHourMinute.d.ts +11 -0
  178. package/dist/utils/navigationUtils.js.map +1 -1
  179. package/dist/utils/normalizeTimeToHourMinute.js +34 -0
  180. package/dist/utils/normalizeTimeToHourMinute.js.map +1 -0
  181. package/dist/utils/treeGridUtil.js +1 -1
  182. package/dist/utils/treeGridUtil.js.map +1 -1
  183. package/dist/utils.js +78 -75
  184. package/dist/utils.js.map +1 -1
  185. package/package.json +2 -6
  186. package/dist/components/OwpMrtTable/OwpMrtTableNoDataOverlay.js.map +0 -1
  187. package/dist/components/OwpMrtTable/OwpMrtTableTopToolbar.js.map +0 -1
  188. package/dist/components/OwpPageCarded/OwpPageCardedHeader.js.map +0 -1
  189. package/dist/components/OwpPageCarded/OwpPageCardedSidebar.js.map +0 -1
  190. package/dist/components/OwpPageCarded/OwpPageCardedSidebarContent.js.map +0 -1
  191. package/dist/components/OwpPicker/AnimatedCalendarContainer.js.map +0 -1
  192. package/dist/components/OwpPicker/CalendarContainer.js.map +0 -1
  193. package/dist/components/OwpPicker/DatePickerInput.js.map +0 -1
  194. package/dist/components/OwpPicker/constants.js.map +0 -1
  195. package/dist/components/OwpTreeGrid/OwpTreeGridLoadingOverlay.js.map +0 -1
  196. package/dist/components/OwpTreeGrid/OwpTreeGridNoDataOverlay.js.map +0 -1
  197. package/dist/components/OwpTreeGrid/perf.js.map +0 -1
  198. package/dist/components/OwpTreeGrid/utils/index.js.map +0 -1
  199. package/dist/components/OwpZoomImageSlider/ZoomImage.js.map +0 -1
  200. package/dist/hooks/useAppStore.js +0 -8
  201. package/dist/hooks/useAppStore.js.map +0 -1
  202. package/dist/node_modules/.pnpm/react-datepicker@8.7.0_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/react-datepicker/dist/react-datepicker.css +0 -1
  203. package/dist/store/generateReducersFromSlices.js +0 -18
  204. package/dist/store/generateReducersFromSlices.js.map +0 -1
  205. package/dist/store/lazyLoadedSlices.js +0 -16
  206. package/dist/store/lazyLoadedSlices.js.map +0 -1
  207. package/dist/store/middleware.js +0 -9
  208. package/dist/store/middleware.js.map +0 -1
  209. package/dist/store/navbarSlice.js +0 -71
  210. package/dist/store/navbarSlice.js.map +0 -1
  211. package/dist/store/navigationSlice.js +0 -46
  212. package/dist/store/navigationSlice.js.map +0 -1
  213. package/dist/store/owpSettingsSlice.js +0 -195
  214. package/dist/store/owpSettingsSlice.js.map +0 -1
  215. package/dist/store/store.js +0 -17
  216. package/dist/store/store.js.map +0 -1
  217. package/dist/store/withSlices.js +0 -27
  218. package/dist/store/withSlices.js.map +0 -1
  219. package/dist/types/hooks/useAppStore.d.ts +0 -7
  220. package/dist/types/store/generateReducersFromSlices.d.ts +0 -6
  221. package/dist/types/store/lazyLoadedSlices.d.ts +0 -9
  222. package/dist/types/store/middleware.d.ts +0 -17
  223. package/dist/types/store/navbarSlice.d.ts +0 -22
  224. package/dist/types/store/navigationSlice.d.ts +0 -92
  225. package/dist/types/store/owpSettingsSlice.d.ts +0 -112
  226. package/dist/types/store/store.d.ts +0 -13
  227. package/dist/types/store/withSlices.d.ts +0 -11
  228. /package/dist/components/OwpTreeGrid/{perf.js → utils/perf.js} +0 -0
  229. /package/dist/types/components/OwpMrtTable/{OwpMrtTableNoDataOverlay.d.ts → internal/OwpMrtTableNoDataOverlay.d.ts} +0 -0
  230. /package/dist/types/components/OwpMrtTable/{OwpMrtTableTopToolbar.d.ts → internal/OwpMrtTableTopToolbar.d.ts} +0 -0
  231. /package/dist/types/components/OwpPageCarded/{OwpPageCardedHeader.d.ts → internal/OwpPageCardedHeader.d.ts} +0 -0
  232. /package/dist/types/components/OwpPageCarded/{OwpPageCardedSidebar.d.ts → internal/OwpPageCardedSidebar.d.ts} +0 -0
  233. /package/dist/types/components/OwpPageCarded/{OwpPageCardedSidebarContent.d.ts → internal/OwpPageCardedSidebarContent.d.ts} +0 -0
  234. /package/dist/types/components/OwpPicker/{constants.d.ts → constants/index.d.ts} +0 -0
  235. /package/dist/types/components/OwpPicker/{AnimatedCalendarContainer.d.ts → internal/AnimatedCalendarContainer.d.ts} +0 -0
  236. /package/dist/types/components/OwpPicker/{CalendarContainer.d.ts → internal/CalendarContainer.d.ts} +0 -0
  237. /package/dist/types/components/OwpTreeGrid/{perf.d.ts → utils/perf.d.ts} +0 -0
  238. /package/dist/types/components/OwpZoomImageSlider/{ZoomImage.d.ts → internal/ZoomImage.d.ts} +0 -0
@@ -1,18 +1,17 @@
1
1
  var j = Object.defineProperty;
2
2
  var u = (t, o) => j(t, "name", { value: o, configurable: !0 });
3
3
  import { jsx as k } from "../../node_modules/.pnpm/@emotion_react@11.14.0_@types_react@19.2.14_react@19.2.4/node_modules/@emotion/react/jsx-runtime/dist/emotion-react-jsx-runtime.browser.esm.js";
4
- import { selectCustomScrollbarsEnabled as B } from "../../store/owpSettingsSlice.js";
5
- import { useAppSelector as M } from "../../hooks/useAppStore.js";
6
- import { styled as U } from "@mui/material/styles";
7
- import X from "../../_virtual/mobile-detect.js";
8
- import Y from "../../node_modules/.pnpm/perfect-scrollbar@1.5.6/node_modules/perfect-scrollbar/dist/perfect-scrollbar.esm.js";
4
+ import { useGetCustomScrollbarsEnabled as B } from "../../hooks/useOwpSettings.js";
5
+ import { styled as M } from "@mui/material/styles";
6
+ import U from "../../_virtual/mobile-detect.js";
7
+ import X from "../../node_modules/.pnpm/perfect-scrollbar@1.5.6/node_modules/perfect-scrollbar/dist/perfect-scrollbar.esm.js";
9
8
  /* empty css */
10
- import { forwardRef as A, useRef as f, useState as D, useCallback as p, useEffect as a } from "react";
9
+ import { forwardRef as Y, useRef as f, useState as D, useCallback as p, useEffect as a } from "react";
11
10
  import { useLocation as H } from "react-router-dom";
12
- const N = U("div")(() => ({
11
+ const N = M("div")(() => ({
13
12
  overscrollBehavior: "contain",
14
13
  minHeight: "100%"
15
- })), P = new X(window.navigator.userAgent), y = P.mobile(), g = Object.freeze({
14
+ })), P = new U(window.navigator.userAgent), y = P.mobile(), g = Object.freeze({
16
15
  "ps-scroll-y": "onScrollY",
17
16
  "ps-scroll-x": "onScrollX",
18
17
  "ps-scroll-up": "onScrollUp",
@@ -23,18 +22,18 @@ const N = U("div")(() => ({
23
22
  "ps-y-reach-end": "onYReachEnd",
24
23
  "ps-x-reach-start": "onXReachStart",
25
24
  "ps-x-reach-end": "onXReachEnd"
26
- }), Z = A((t, o) => {
25
+ }), V = Y((t, o) => {
27
26
  const {
28
27
  className: T = "",
29
- children: m,
28
+ children: h,
30
29
  id: x = "",
31
- scrollToTopOnChildChange: h = !0,
30
+ scrollToTopOnChildChange: m = !0,
32
31
  scrollToTopOnRouteChange: d = !1,
33
32
  enable: S = !0,
34
33
  option: b = {
35
34
  wheelPropagation: !0
36
35
  }
37
- } = t, r = f(null), n = f(null), i = f(/* @__PURE__ */ new Map()), [C, v] = D({}), c = M(B), O = H(), { pathname: L } = O, E = p(() => {
36
+ } = t, r = f(null), n = f(null), i = f(/* @__PURE__ */ new Map()), [C, v] = D({}), c = B(), O = H(), { pathname: L } = O, E = p(() => {
38
37
  Object.keys(g).forEach((e) => {
39
38
  const s = t[g[e]];
40
39
  if (s) {
@@ -47,15 +46,15 @@ const N = U("div")(() => ({
47
46
  r.current && r.current.removeEventListener(s, e, !1);
48
47
  }), i.current.clear();
49
48
  }, []);
50
- a(() => (c && r.current && !y && (n.current = new Y(r.current, b), E()), () => {
49
+ a(() => (c && r.current && !y && (n.current = new X(r.current, b), E()), () => {
51
50
  n.current && (n.current.destroy(), n.current = null, w());
52
51
  }), [c, E, b, w]);
53
52
  const l = p(() => {
54
53
  r.current && (r.current.scrollTop = 0);
55
54
  }, []);
56
55
  return a(() => {
57
- h && l();
58
- }, [l, m, h]), a(() => {
56
+ m && l();
57
+ }, [l, h, m]), a(() => {
59
58
  d && l();
60
59
  }, [L, l, d]), a(() => {
61
60
  v(c && S && !y ? {
@@ -71,11 +70,11 @@ const N = U("div")(() => ({
71
70
  ref: /* @__PURE__ */ u((e) => {
72
71
  r.current = e, typeof o == "function" ? o(e) : o && (o.current = e);
73
72
  }, "ref"),
74
- children: m
73
+ children: h
75
74
  }
76
75
  );
77
76
  });
78
77
  export {
79
- Z as OwpScrollbars
78
+ V as OwpScrollbars
80
79
  };
81
80
  //# sourceMappingURL=OwpScrollbars.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"OwpScrollbars.js","sources":["../../../src/components/OwpScrollbars/OwpScrollbars.tsx"],"sourcesContent":["import { selectCustomScrollbarsEnabled } from '@/store/owpSettingsSlice';\nimport { useAppSelector } from '@/hooks/useAppStore';\nimport { styled } from '@mui/material/styles';\nimport MobileDetect from 'mobile-detect';\nimport PerfectScrollbar from 'perfect-scrollbar';\nimport 'perfect-scrollbar/css/perfect-scrollbar.css';\nimport { forwardRef, ReactNode, useCallback, useEffect, useRef, useState } from 'react';\nimport { useLocation } from 'react-router-dom';\n\nconst Root = styled('div')(() => ({\n overscrollBehavior: 'contain',\n minHeight: '100%',\n}));\n\nconst md = new MobileDetect(window.navigator.userAgent);\nconst isMobile = md.mobile();\n\nconst handlerNameByEvent = Object.freeze({\n 'ps-scroll-y': 'onScrollY',\n 'ps-scroll-x': 'onScrollX',\n 'ps-scroll-up': 'onScrollUp',\n 'ps-scroll-down': 'onScrollDown',\n 'ps-scroll-left': 'onScrollLeft',\n 'ps-scroll-right': 'onScrollRight',\n 'ps-y-reach-start': 'onYReachStart',\n 'ps-y-reach-end': 'onYReachEnd',\n 'ps-x-reach-start': 'onXReachStart',\n 'ps-x-reach-end': 'onXReachEnd',\n});\n\ntype OwpScrollbarsProps = {\n id?: string;\n className?: string;\n children: ReactNode;\n enable?: boolean;\n scrollToTopOnChildChange?: boolean;\n scrollToTopOnRouteChange?: boolean;\n option?: {\n wheelPropagation?: boolean;\n suppressScrollX?: boolean;\n };\n};\n\n/**\n * OwpScrollbars 컴포넌트\n * @param props 컴포넌트 props\n * @param ref forwardRef 참조\n */\nconst OwpScrollbars = forwardRef<HTMLDivElement, OwpScrollbarsProps>((props, ref) => {\n const {\n className = '',\n children,\n id = '',\n scrollToTopOnChildChange = true,\n scrollToTopOnRouteChange = false,\n enable = true,\n option = {\n wheelPropagation: true,\n },\n } = props;\n\n const containerRef = useRef<HTMLDivElement>(null);\n const psRef = useRef<PerfectScrollbar | null>(null);\n const handlerByEvent = useRef<Map<string, EventListener>>(new Map());\n const [style, setStyle] = useState({});\n const customScrollbars = useAppSelector(selectCustomScrollbarsEnabled);\n const location = useLocation();\n const { pathname } = location;\n\n const hookUpEvents = useCallback(() => {\n Object.keys(handlerNameByEvent).forEach((key) => {\n const callback = props[handlerNameByEvent[key] as keyof OwpScrollbarsProps] as (\n T: HTMLDivElement,\n ) => void;\n\n if (callback) {\n const handler: EventListener = () => callback(containerRef.current);\n handlerByEvent.current.set(key, handler);\n\n if (containerRef.current) {\n containerRef.current.addEventListener(key, handler, false);\n }\n }\n });\n }, [props]);\n\n const unHookUpEvents = useCallback(() => {\n handlerByEvent.current.forEach((value, key) => {\n if (containerRef.current) {\n containerRef.current.removeEventListener(key, value, false);\n }\n });\n handlerByEvent.current.clear();\n }, []);\n\n useEffect(() => {\n if (customScrollbars && containerRef.current && !isMobile) {\n psRef.current = new PerfectScrollbar(containerRef.current, option);\n hookUpEvents();\n }\n\n return () => {\n if (psRef.current) {\n psRef.current.destroy();\n psRef.current = null;\n unHookUpEvents();\n }\n };\n }, [customScrollbars, hookUpEvents, option, unHookUpEvents]);\n\n const scrollToTop = useCallback(() => {\n if (containerRef.current) {\n containerRef.current.scrollTop = 0;\n }\n }, []);\n\n useEffect(() => {\n if (scrollToTopOnChildChange) {\n scrollToTop();\n }\n }, [scrollToTop, children, scrollToTopOnChildChange]);\n\n useEffect(() => {\n if (scrollToTopOnRouteChange) {\n scrollToTop();\n }\n }, [pathname, scrollToTop, scrollToTopOnRouteChange]);\n\n useEffect(() => {\n if (customScrollbars && enable && !isMobile) {\n setStyle({\n position: 'relative',\n overflow: 'hidden!important',\n });\n } else {\n setStyle({});\n }\n }, [customScrollbars, enable]);\n\n return (\n <Root\n id={id}\n className={className}\n style={style}\n ref={(el) => {\n containerRef.current = el;\n\n if (typeof ref === 'function') {\n ref(el);\n } else if (ref) {\n ref.current = el;\n }\n }}\n >\n {children}\n </Root>\n );\n});\n\nexport { OwpScrollbars };\n"],"names":["Root","styled","md","MobileDetect","isMobile","handlerNameByEvent","OwpScrollbars","forwardRef","props","ref","className","children","id","scrollToTopOnChildChange","scrollToTopOnRouteChange","enable","option","containerRef","useRef","psRef","handlerByEvent","style","setStyle","useState","customScrollbars","useAppSelector","selectCustomScrollbarsEnabled","location","useLocation","pathname","hookUpEvents","useCallback","key","callback","handler","__name","unHookUpEvents","value","useEffect","PerfectScrollbar","scrollToTop","jsx","el"],"mappings":"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"}
1
+ {"version":3,"file":"OwpScrollbars.js","sources":["../../../src/components/OwpScrollbars/OwpScrollbars.tsx"],"sourcesContent":["import { useGetCustomScrollbarsEnabled } from '@/hooks/useOwpSettings';\nimport { styled } from '@mui/material/styles';\nimport MobileDetect from 'mobile-detect';\nimport PerfectScrollbar from 'perfect-scrollbar';\nimport 'perfect-scrollbar/css/perfect-scrollbar.css';\nimport { forwardRef, ReactNode, useCallback, useEffect, useRef, useState } from 'react';\nimport { useLocation } from 'react-router-dom';\n\nconst Root = styled('div')(() => ({\n overscrollBehavior: 'contain',\n minHeight: '100%',\n}));\n\nconst md = new MobileDetect(window.navigator.userAgent);\nconst isMobile = md.mobile();\n\nconst handlerNameByEvent = Object.freeze({\n 'ps-scroll-y': 'onScrollY',\n 'ps-scroll-x': 'onScrollX',\n 'ps-scroll-up': 'onScrollUp',\n 'ps-scroll-down': 'onScrollDown',\n 'ps-scroll-left': 'onScrollLeft',\n 'ps-scroll-right': 'onScrollRight',\n 'ps-y-reach-start': 'onYReachStart',\n 'ps-y-reach-end': 'onYReachEnd',\n 'ps-x-reach-start': 'onXReachStart',\n 'ps-x-reach-end': 'onXReachEnd',\n});\n\ntype OwpScrollbarsProps = {\n id?: string;\n className?: string;\n children: ReactNode;\n enable?: boolean;\n scrollToTopOnChildChange?: boolean;\n scrollToTopOnRouteChange?: boolean;\n option?: {\n wheelPropagation?: boolean;\n suppressScrollX?: boolean;\n };\n};\n\n/**\n * OwpScrollbars 컴포넌트\n * @param props 컴포넌트 props\n * @param ref forwardRef 참조\n */\nconst OwpScrollbars = forwardRef<HTMLDivElement, OwpScrollbarsProps>((props, ref) => {\n const {\n className = '',\n children,\n id = '',\n scrollToTopOnChildChange = true,\n scrollToTopOnRouteChange = false,\n enable = true,\n option = {\n wheelPropagation: true,\n },\n } = props;\n\n const containerRef = useRef<HTMLDivElement>(null);\n const psRef = useRef<PerfectScrollbar | null>(null);\n const handlerByEvent = useRef<Map<string, EventListener>>(new Map());\n const [style, setStyle] = useState({});\n const customScrollbars = useGetCustomScrollbarsEnabled();\n const location = useLocation();\n const { pathname } = location;\n\n const hookUpEvents = useCallback(() => {\n Object.keys(handlerNameByEvent).forEach((key) => {\n const callback = props[handlerNameByEvent[key] as keyof OwpScrollbarsProps] as (\n T: HTMLDivElement,\n ) => void;\n\n if (callback) {\n const handler: EventListener = () => callback(containerRef.current);\n handlerByEvent.current.set(key, handler);\n\n if (containerRef.current) {\n containerRef.current.addEventListener(key, handler, false);\n }\n }\n });\n }, [props]);\n\n const unHookUpEvents = useCallback(() => {\n handlerByEvent.current.forEach((value, key) => {\n if (containerRef.current) {\n containerRef.current.removeEventListener(key, value, false);\n }\n });\n handlerByEvent.current.clear();\n }, []);\n\n useEffect(() => {\n if (customScrollbars && containerRef.current && !isMobile) {\n psRef.current = new PerfectScrollbar(containerRef.current, option);\n hookUpEvents();\n }\n\n return () => {\n if (psRef.current) {\n psRef.current.destroy();\n psRef.current = null;\n unHookUpEvents();\n }\n };\n }, [customScrollbars, hookUpEvents, option, unHookUpEvents]);\n\n const scrollToTop = useCallback(() => {\n if (containerRef.current) {\n containerRef.current.scrollTop = 0;\n }\n }, []);\n\n useEffect(() => {\n if (scrollToTopOnChildChange) {\n scrollToTop();\n }\n }, [scrollToTop, children, scrollToTopOnChildChange]);\n\n useEffect(() => {\n if (scrollToTopOnRouteChange) {\n scrollToTop();\n }\n }, [pathname, scrollToTop, scrollToTopOnRouteChange]);\n\n useEffect(() => {\n if (customScrollbars && enable && !isMobile) {\n setStyle({\n position: 'relative',\n overflow: 'hidden!important',\n });\n } else {\n setStyle({});\n }\n }, [customScrollbars, enable]);\n\n return (\n <Root\n id={id}\n className={className}\n style={style}\n ref={(el) => {\n containerRef.current = el;\n\n if (typeof ref === 'function') {\n ref(el);\n } else if (ref) {\n ref.current = el;\n }\n }}\n >\n {children}\n </Root>\n );\n});\n\nexport { OwpScrollbars };\n"],"names":["Root","styled","md","MobileDetect","isMobile","handlerNameByEvent","OwpScrollbars","forwardRef","props","ref","className","children","id","scrollToTopOnChildChange","scrollToTopOnRouteChange","enable","option","containerRef","useRef","psRef","handlerByEvent","style","setStyle","useState","customScrollbars","useGetCustomScrollbarsEnabled","location","useLocation","pathname","hookUpEvents","useCallback","key","callback","handler","__name","unHookUpEvents","value","useEffect","PerfectScrollbar","scrollToTop","jsx","el"],"mappings":"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"}
@@ -1,56 +1,56 @@
1
- var ge = Object.defineProperty;
2
- var n = (a, s) => ge(a, "name", { value: s, configurable: !0 });
3
- import { jsxs as C, jsx as r, Fragment as M } from "../../node_modules/.pnpm/@emotion_react@11.14.0_@types_react@19.2.14_react@19.2.4/node_modules/@emotion/react/jsx-runtime/dist/emotion-react-jsx-runtime.browser.esm.js";
4
- import { createElement as xe } from "@emotion/react";
5
- import { useOwpTranslation as be } from "../../hooks/useOwpTranslation.js";
1
+ var xe = Object.defineProperty;
2
+ var n = (a, s) => xe(a, "name", { value: s, configurable: !0 });
3
+ import { jsxs as x, jsx as i, Fragment as M } from "../../node_modules/.pnpm/@emotion_react@11.14.0_@types_react@19.2.14_react@19.2.4/node_modules/@emotion/react/jsx-runtime/dist/emotion-react-jsx-runtime.browser.esm.js";
4
+ import { createElement as be } from "@emotion/react";
5
+ import { useOwpTranslation as ye } from "../../hooks/useOwpTranslation.js";
6
6
  import Y from "../../node_modules/.pnpm/@mui_icons-material@7.3.9_@mui_material@7.3.9_@emotion_react@11.14.0_@types_react@19.2._dc2be6bc014bebdac88a574e3e02c144/node_modules/@mui/icons-material/esm/ArrowDropDown.js";
7
7
  import F from "../../node_modules/.pnpm/@mui_icons-material@7.3.9_@mui_material@7.3.9_@emotion_react@11.14.0_@types_react@19.2._dc2be6bc014bebdac88a574e3e02c144/node_modules/@mui/icons-material/esm/Clear.js";
8
- import { Box as ve, Chip as E, Checkbox as Ae, TextField as ee, CircularProgress as te, Autocomplete as oe, ClickAwayListener as ye, Paper as Se, Popper as Me } from "@mui/material";
9
- import { alpha as g } from "@mui/material/styles";
8
+ import { Box as Ae, Chip as E, Checkbox as ve, TextField as ee, CircularProgress as te, Autocomplete as oe, ClickAwayListener as Se, Paper as Me, Popper as Ee } from "@mui/material";
9
+ import { alpha as b } from "@mui/material/styles";
10
10
  import { clsx as ne } from "../../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js";
11
- import { useMemo as le, useState as Ee, useRef as re, useEffect as ie } from "react";
12
- import { isSelectorAllOption as h } from "./utils/querySelectorUtils.js";
13
- const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
11
+ import { useMemo as le, useState as we, useRef as re, useEffect as ie } from "react";
12
+ import { isSelectorAllOption as O } from "./utils/querySelectorUtils.js";
13
+ const ae = 2, ke = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
14
14
  const u = a.target;
15
15
  return u instanceof HTMLInputElement ? u.value : s ?? "";
16
- }, "getCurrentAutocompleteInputValue"), ce = /* @__PURE__ */ n((a) => typeof a == "string" || typeof a == "number" ? `${a}` : "", "getAutocompleteOptionLabel"), Be = /* @__PURE__ */ n(({ hookResult: a, props: s }) => {
17
- const { t: u } = be(), {
16
+ }, "getCurrentAutocompleteInputValue"), ce = /* @__PURE__ */ n((a) => typeof a == "string" || typeof a == "number" ? `${a}` : "", "getAutocompleteOptionLabel"), Ue = /* @__PURE__ */ n(({ hookResult: a, props: s }) => {
17
+ const { t: u } = ye(), {
18
18
  autocompleteInputValue: d,
19
19
  className: w,
20
20
  disableAllValueItem: f,
21
21
  disableClientFilter: k,
22
- disabled: I,
22
+ disabled: T,
23
23
  error: L,
24
- fullWidth: O,
24
+ fullWidth: C,
25
25
  helperText: D,
26
- label: V,
27
- loading: T,
28
- loadingText: N,
29
- multiple: z,
26
+ label: P,
27
+ loading: g,
28
+ loadingText: V,
29
+ multiple: N,
30
30
  noOptionsText: me,
31
31
  onAutocompleteInputChange: c,
32
- placeholder: R,
33
- required: P,
32
+ placeholder: z,
33
+ required: R,
34
34
  textFieldProps: o
35
35
  } = s, {
36
- allOption: x,
36
+ allOption: y,
37
37
  clearSelection: _,
38
38
  isAllSelected: m,
39
39
  resolvedOptions: H,
40
40
  restoreAllSelection: W,
41
41
  selectAll: B,
42
42
  selectedOption: de,
43
- selectedOptions: b,
43
+ selectedOptions: A,
44
44
  selectMultipleValues: U,
45
45
  selectSingleValue: $
46
- } = a, q = f ? H : [x, ...H], v = le(
47
- () => b.filter((e) => !h(e)),
48
- [b]
46
+ } = a, q = f ? H : [y, ...H], v = le(
47
+ () => A.filter((e) => !O(e)),
48
+ [A]
49
49
  ), K = le(
50
50
  () => m ? [] : v.slice(ae),
51
51
  [v, m]
52
- ), p = K.length, [j, A] = Ee(null), Z = re(null), G = me ?? u("Message.검색 결과 없음"), J = re(
53
- z && !f && ((s.value ?? s.defaultValue) == null || (s.value ?? s.defaultValue) === "")
52
+ ), p = K.length, [j, S] = we(null), Z = re(null), G = me ?? u("Message.검색 결과 없음"), J = re(
53
+ N && !f && ((s.value ?? s.defaultValue) == null || (s.value ?? s.defaultValue) === "")
54
54
  ), Q = {
55
55
  clearIndicator: {
56
56
  className: "m-0 p-0",
@@ -71,7 +71,7 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
71
71
  size: "small"
72
72
  }
73
73
  }, X = {
74
- minWidth: we,
74
+ minWidth: ke,
75
75
  "& .MuiAutocomplete-endAdornment": {
76
76
  "& .MuiAutocomplete-clearIndicator + .MuiAutocomplete-popupIndicator": {
77
77
  ml: 0
@@ -95,7 +95,7 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
95
95
  }
96
96
  };
97
97
  ie(() => {
98
- p || A(null);
98
+ p || S(null);
99
99
  }, [p]), ie(() => {
100
100
  var l;
101
101
  if (!J.current)
@@ -113,11 +113,11 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
113
113
  };
114
114
  }, [W]);
115
115
  const he = /* @__PURE__ */ n(() => {
116
- A(null);
116
+ S(null);
117
117
  }, "handleHiddenChipPopperClose"), Ie = /* @__PURE__ */ n((e) => {
118
118
  e.preventDefault();
119
119
  }, "handleHiddenChipSummaryMouseDown"), Oe = /* @__PURE__ */ n((e) => {
120
- e.preventDefault(), e.stopPropagation(), A(
120
+ e.preventDefault(), e.stopPropagation(), S(
121
121
  (t) => t === e.currentTarget ? null : e.currentTarget
122
122
  );
123
123
  }, "handleHiddenChipSummaryClick"), Te = /* @__PURE__ */ n((e) => {
@@ -129,37 +129,37 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
129
129
  const t = pe(e, d);
130
130
  (m || p > 0) && t === "" && (e.key === "Backspace" || e.key === "Delete") && (e.defaultMuiPrevented = !0, e.preventDefault(), e.stopPropagation()), (l = o == null ? void 0 : o.onKeyDown) == null || l.call(o, e);
131
131
  }, "handleMultipleRootKeyDown");
132
- return z ? /* @__PURE__ */ C(M, { children: [
133
- /* @__PURE__ */ r(
132
+ return N ? /* @__PURE__ */ x(M, { children: [
133
+ /* @__PURE__ */ i(
134
134
  oe,
135
135
  {
136
136
  ref: Z,
137
137
  className: ne("min-w-128", w),
138
138
  disableCloseOnSelect: !0,
139
- disabled: I,
139
+ disabled: T,
140
140
  filterOptions: k ? (e) => e : void 0,
141
- fullWidth: O,
141
+ fullWidth: C,
142
142
  inputValue: d,
143
- loading: T,
143
+ loading: g,
144
144
  multiple: !0,
145
145
  options: q,
146
146
  clearText: "",
147
147
  closeText: "",
148
- clearIcon: /* @__PURE__ */ r(F, { sx: { fontSize: ue } }),
148
+ clearIcon: /* @__PURE__ */ i(F, { sx: { fontSize: ue } }),
149
149
  openText: "",
150
- popupIcon: /* @__PURE__ */ r(Y, {}),
150
+ popupIcon: /* @__PURE__ */ i(Y, {}),
151
151
  sx: fe,
152
- value: b,
152
+ value: A,
153
153
  getOptionLabel: /* @__PURE__ */ n((e) => ce(e.label), "getOptionLabel"),
154
154
  isOptionEqualToValue: /* @__PURE__ */ n((e, t) => e.value === t.value, "isOptionEqualToValue"),
155
- loadingText: N ?? u("Common.로딩 중..."),
155
+ loadingText: V ?? u("Common.로딩 중..."),
156
156
  noOptionsText: G,
157
- onChange: /* @__PURE__ */ n((e, t, l, i) => {
158
- const y = e.type === "keydown" ? pe(
157
+ onChange: /* @__PURE__ */ n((e, t, l, r) => {
158
+ const h = e.type === "keydown" ? pe(
159
159
  e,
160
160
  d
161
161
  ) : d ?? "";
162
- if (l === "removeOption" && e.type === "keydown" && y === "" && (m || p > 0)) {
162
+ if (l === "removeOption" && e.type === "keydown" && h === "" && (m || p > 0)) {
163
163
  e.preventDefault(), e.stopPropagation();
164
164
  return;
165
165
  }
@@ -171,7 +171,7 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
171
171
  _();
172
172
  return;
173
173
  }
174
- if (!f && (i != null && i.option) && h(i.option)) {
174
+ if (!f && (r != null && r.option) && O(r.option)) {
175
175
  if (m) {
176
176
  _();
177
177
  return;
@@ -180,7 +180,7 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
180
180
  return;
181
181
  }
182
182
  U(
183
- t.filter((S) => !h(S)).map((S) => S.value)
183
+ t.filter((I) => !O(I)).map((I) => I.value)
184
184
  );
185
185
  }, "onChange"),
186
186
  onInputChange: /* @__PURE__ */ n((e, t, l) => {
@@ -190,25 +190,25 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
190
190
  slotProps: Q,
191
191
  renderInput: /* @__PURE__ */ n((e) => {
192
192
  var t;
193
- return /* @__PURE__ */ r(
193
+ return /* @__PURE__ */ i(
194
194
  ee,
195
195
  {
196
196
  ...e,
197
197
  ...o,
198
- disabled: I,
198
+ disabled: T,
199
199
  error: L,
200
- fullWidth: O,
200
+ fullWidth: C,
201
201
  helperText: D,
202
- label: V,
203
- placeholder: R ?? u("Common.검색"),
204
- required: P,
202
+ label: P,
203
+ placeholder: z ?? u("Common.검색"),
204
+ required: R,
205
205
  slotProps: {
206
206
  ...o == null ? void 0 : o.slotProps,
207
207
  input: {
208
208
  ...e.InputProps,
209
209
  ...(t = o == null ? void 0 : o.slotProps) == null ? void 0 : t.input,
210
- endAdornment: /* @__PURE__ */ C(M, { children: [
211
- T ? /* @__PURE__ */ r(te, { color: "inherit", size: 16, sx: { mr: 0.5 } }) : null,
210
+ endAdornment: /* @__PURE__ */ x(M, { children: [
211
+ g ? /* @__PURE__ */ i(te, { color: "inherit", size: 16, sx: { mr: 0.5 } }) : null,
212
212
  e.InputProps.endAdornment
213
213
  ] })
214
214
  }
@@ -217,33 +217,39 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
217
217
  }
218
218
  );
219
219
  }, "renderInput"),
220
- renderOption: /* @__PURE__ */ n((e, t, l) => /* @__PURE__ */ C("li", { ...e, children: [
221
- /* @__PURE__ */ r(Ae, { checked: l.selected, className: "!mr-8 !p-0", size: "small" }),
222
- t.label
223
- ] }), "renderOption"),
220
+ renderOption: /* @__PURE__ */ n((e, t, l) => {
221
+ const { key: r, ...h } = e;
222
+ return /* @__PURE__ */ x("li", { ...h, children: [
223
+ /* @__PURE__ */ i(ve, { checked: l.selected, className: "!mr-8 !p-0", size: "small" }),
224
+ t.label
225
+ ] }, r);
226
+ }, "renderOption"),
224
227
  renderValue: /* @__PURE__ */ n((e, t) => !f && m ? [
225
- /* @__PURE__ */ r(
226
- ve,
228
+ /* @__PURE__ */ i(
229
+ Ae,
227
230
  {
228
231
  component: "span",
229
232
  sx: { color: "text.primary", fontWeight: 500, mr: 0.5 },
230
- children: x.label
233
+ children: y.label
231
234
  },
232
- x.value
235
+ y.value
233
236
  )
234
237
  ] : [
235
- ...e.filter((i) => !h(i)).slice(0, ae).map((i, y) => /* @__PURE__ */ xe(
236
- E,
237
- {
238
- ...t({ index: y }),
239
- key: i.value,
240
- label: i.label,
241
- size: "small",
242
- sx: { borderRadius: 1, mr: 0.5 }
243
- }
244
- )),
238
+ ...e.filter((r) => !O(r)).slice(0, ae).map((r, h) => {
239
+ const { key: I, ...ge } = t({ index: h });
240
+ return /* @__PURE__ */ be(
241
+ E,
242
+ {
243
+ ...ge,
244
+ key: I,
245
+ label: r.label,
246
+ size: "small",
247
+ sx: { borderRadius: 1, mr: 0.5 }
248
+ }
249
+ );
250
+ }),
245
251
  ...p > 0 ? [
246
- /* @__PURE__ */ r(
252
+ /* @__PURE__ */ i(
247
253
  E,
248
254
  {
249
255
  clickable: !0,
@@ -251,15 +257,15 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
251
257
  onClick: Oe,
252
258
  onMouseDown: Ie,
253
259
  size: "small",
254
- sx: /* @__PURE__ */ n((i) => ({
255
- backgroundColor: g(i.palette.primary.main, 0.14),
256
- border: `1px solid ${g(i.palette.primary.main, 0.22)}`,
260
+ sx: /* @__PURE__ */ n((r) => ({
261
+ backgroundColor: b(r.palette.primary.main, 0.14),
262
+ border: `1px solid ${b(r.palette.primary.main, 0.22)}`,
257
263
  borderRadius: 1,
258
- color: i.palette.primary.dark,
264
+ color: r.palette.primary.dark,
259
265
  fontWeight: 600,
260
266
  mr: 0.5,
261
267
  "&:hover": {
262
- backgroundColor: g(i.palette.primary.main, 0.2)
268
+ backgroundColor: b(r.palette.primary.main, 0.2)
263
269
  }
264
270
  }), "sx")
265
271
  },
@@ -269,26 +275,26 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
269
275
  ], "renderValue")
270
276
  }
271
277
  ),
272
- /* @__PURE__ */ r(
273
- Me,
278
+ /* @__PURE__ */ i(
279
+ Ee,
274
280
  {
275
281
  anchorEl: j,
276
282
  open: !!j && p > 0,
277
283
  placement: "bottom-start",
278
284
  sx: { zIndex: /* @__PURE__ */ n((e) => e.zIndex.modal, "zIndex") },
279
- children: /* @__PURE__ */ r(ye, { onClickAway: he, children: /* @__PURE__ */ r(
280
- Se,
285
+ children: /* @__PURE__ */ i(Se, { onClickAway: he, children: /* @__PURE__ */ i(
286
+ Me,
281
287
  {
282
288
  className: "mt-4",
283
289
  sx: {
284
- border: /* @__PURE__ */ n((e) => `1px solid ${g(e.palette.common.black, 0.12)}`, "border"),
290
+ border: /* @__PURE__ */ n((e) => `1px solid ${b(e.palette.common.black, 0.12)}`, "border"),
285
291
  display: "flex",
286
292
  flexWrap: "wrap",
287
293
  gap: 0.75,
288
294
  maxWidth: 280,
289
295
  p: 1
290
296
  },
291
- children: K.map((e) => /* @__PURE__ */ r(
297
+ children: K.map((e) => /* @__PURE__ */ i(
292
298
  E,
293
299
  {
294
300
  label: e.label,
@@ -302,29 +308,29 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
302
308
  ) })
303
309
  }
304
310
  )
305
- ] }) : /* @__PURE__ */ r(
311
+ ] }) : /* @__PURE__ */ i(
306
312
  oe,
307
313
  {
308
314
  className: ne("min-w-128", w),
309
- disabled: I,
315
+ disabled: T,
310
316
  filterOptions: k ? (e) => e : void 0,
311
- fullWidth: O,
317
+ fullWidth: C,
312
318
  inputValue: d,
313
- loading: T,
319
+ loading: g,
314
320
  options: q,
315
321
  clearText: "",
316
322
  closeText: "",
317
- clearIcon: /* @__PURE__ */ r(F, { sx: { fontSize: ue } }),
323
+ clearIcon: /* @__PURE__ */ i(F, { sx: { fontSize: ue } }),
318
324
  openText: "",
319
- popupIcon: /* @__PURE__ */ r(Y, {}),
325
+ popupIcon: /* @__PURE__ */ i(Y, {}),
320
326
  sx: X,
321
327
  value: de,
322
328
  getOptionLabel: /* @__PURE__ */ n((e) => ce(e.label), "getOptionLabel"),
323
329
  isOptionEqualToValue: /* @__PURE__ */ n((e, t) => e.value === t.value, "isOptionEqualToValue"),
324
- loadingText: N ?? u("Common.로딩 중..."),
330
+ loadingText: V ?? u("Common.로딩 중..."),
325
331
  noOptionsText: G,
326
332
  onChange: /* @__PURE__ */ n((e, t) => {
327
- if (!t || !f && h(t)) {
333
+ if (!t || !f && O(t)) {
328
334
  $("");
329
335
  return;
330
336
  }
@@ -335,19 +341,19 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
335
341
  }, "onInputChange"),
336
342
  slotProps: Q,
337
343
  renderInput: /* @__PURE__ */ n((e) => {
338
- var t, l, i;
339
- return /* @__PURE__ */ r(
344
+ var t, l, r;
345
+ return /* @__PURE__ */ i(
340
346
  ee,
341
347
  {
342
348
  ...e,
343
349
  ...o,
344
- disabled: I,
350
+ disabled: T,
345
351
  error: L,
346
- fullWidth: O,
352
+ fullWidth: C,
347
353
  helperText: D,
348
- label: V,
349
- placeholder: R,
350
- required: P,
354
+ label: P,
355
+ placeholder: z,
356
+ required: R,
351
357
  slotProps: {
352
358
  ...o == null ? void 0 : o.slotProps,
353
359
  input: {
@@ -358,10 +364,10 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
358
364
  paddingLeft: "11px !important"
359
365
  },
360
366
  ...e.InputProps.sx ?? {},
361
- ...((i = (l = o == null ? void 0 : o.slotProps) == null ? void 0 : l.input) == null ? void 0 : i.sx) ?? {}
367
+ ...((r = (l = o == null ? void 0 : o.slotProps) == null ? void 0 : l.input) == null ? void 0 : r.sx) ?? {}
362
368
  },
363
- endAdornment: /* @__PURE__ */ C(M, { children: [
364
- T ? /* @__PURE__ */ r(te, { color: "inherit", size: 16, sx: { mr: 0.5 } }) : null,
369
+ endAdornment: /* @__PURE__ */ x(M, { children: [
370
+ g ? /* @__PURE__ */ i(te, { color: "inherit", size: 16, sx: { mr: 0.5 } }) : null,
365
371
  e.InputProps.endAdornment
366
372
  ] })
367
373
  }
@@ -371,11 +377,14 @@ const ae = 2, we = 152, se = 72, ue = 18.57, pe = /* @__PURE__ */ n((a, s) => {
371
377
  );
372
378
  }, "renderInput"),
373
379
  selectOnFocus: !0,
374
- renderOption: /* @__PURE__ */ n((e, t) => /* @__PURE__ */ r("li", { ...e, children: t.label }), "renderOption")
380
+ renderOption: /* @__PURE__ */ n((e, t) => {
381
+ const { key: l, ...r } = e;
382
+ return /* @__PURE__ */ i("li", { ...r, children: t.label }, l);
383
+ }, "renderOption")
375
384
  }
376
385
  );
377
386
  }, "OwpSelectorAutocomplete");
378
387
  export {
379
- Be as OwpSelectorAutocomplete
388
+ Ue as OwpSelectorAutocomplete
380
389
  };
381
390
  //# sourceMappingURL=OwpSelectorAutocomplete.js.map