@hortiview/shared-components 2.18.0 → 2.18.1

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 (219) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/{AlertBanner-aW6joVUm.js → AlertBanner-BFzaGOer.js} +3 -3
  3. package/dist/{GenericCard-IWX-Bmb_.js → GenericCard-grpa3KJR.js} +3 -3
  4. package/dist/{ListAreaService-Fsm3-gDM.js → ListAreaService-DfxJ7jFs.js} +5 -5
  5. package/dist/{_Map-D8db_GOu.js → _Map-BYxTn6ob.js} +1 -1
  6. package/dist/{_commonjsHelpers-B4e78b8K.js → _commonjsHelpers-ByX85dGu.js} +18 -13
  7. package/dist/animationframe-CqXArbwZ.js +32 -0
  8. package/dist/component-By6nyiBU.js +70 -0
  9. package/dist/{component-DEJuY56h.js → component-DYpB_4EP.js} +1 -111
  10. package/dist/components/AlertBanner/AlertBanner.js +4 -4
  11. package/dist/components/AlertBanner/LinkBanner.js +3 -3
  12. package/dist/components/AllowedButton/AllowedButton.js +1 -1
  13. package/dist/components/AllowedIconButton/AllowedIconButton.js +1 -1
  14. package/dist/components/BaseView/BaseView.js +14 -14
  15. package/dist/components/BasicHeading/BasicHeading.js +5 -5
  16. package/dist/components/BlockView/BlockView.js +2 -2
  17. package/dist/components/ButtonCard/ButtonCard.js +6 -6
  18. package/dist/components/ChipCard/ChipCard.js +13 -255
  19. package/dist/components/ConfirmationModal/ConfirmationModal.js +8 -8
  20. package/dist/components/ContextMenu/ContextMenu.js +12 -12
  21. package/dist/components/DeleteModal/DeleteModal.js +25 -25
  22. package/dist/components/DetailContentWrapper/DetailContentWrapper.js +1 -1
  23. package/dist/components/Disclaimer/Disclaimer.js +3 -3
  24. package/dist/components/EmptyView/EmptyView.js +3 -3
  25. package/dist/components/Filter/Filter.js +15 -15
  26. package/dist/components/FormComponents/FormCheckBox/FormCheckBox.js +1 -1
  27. package/dist/components/FormComponents/FormDatePicker/FormDatePicker.js +7 -22
  28. package/dist/components/FormComponents/FormNumber/CustomTextField.js +3 -3
  29. package/dist/components/FormComponents/FormNumber/FormNumber.js +1 -1
  30. package/dist/components/FormComponents/FormRadio/FormRadio.js +1 -1
  31. package/dist/components/FormComponents/FormSelect/FormSelect.js +4 -4
  32. package/dist/components/FormComponents/FormSelect/SelectTooltipText.js +2 -2
  33. package/dist/components/FormComponents/FormSlider/FormSlider.js +10 -98
  34. package/dist/components/FormComponents/FormText/FormText.js +2 -2
  35. package/dist/components/FormComponents/FormToggle/FormToggle.js +4 -4
  36. package/dist/components/FormattedNumberDisplay/FormattedNumberDisplay.js +1 -1
  37. package/dist/components/GenericTable/GenericTable.js +36 -172
  38. package/dist/components/GenericTable/Mobile/GenericCard.js +4 -4
  39. package/dist/components/GenericTable/Mobile/GenericCardList.js +4 -4
  40. package/dist/components/HashTabView/HashTabView.js +10 -428
  41. package/dist/components/HeaderFilter/HeaderFilter.js +1 -1
  42. package/dist/components/Iconify/Iconify.js +2 -2
  43. package/dist/components/InfoCard/InfoCard.js +4 -4
  44. package/dist/components/InfoGroup/InfoGroup.js +4 -4
  45. package/dist/components/ListArea/ListArea.js +6 -6
  46. package/dist/components/ListArea/ListAreaService.js +6 -6
  47. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.js +13 -5
  48. package/dist/components/LoadingSpinner/Default/LoadingSpinner.js +8 -74
  49. package/dist/components/Modal/Modal.js +12 -122
  50. package/dist/components/ModulePadding/ModulePadding.js +11 -11
  51. package/dist/components/OfflineView/OfflineView.js +45 -7
  52. package/dist/components/OnboardingBanner/OnboardingBanner.js +8 -8
  53. package/dist/components/OverflowTooltip/OverflowTooltip.js +2 -2
  54. package/dist/components/SearchBar/SearchBar.js +2 -2
  55. package/dist/components/Select/Select.js +2 -2
  56. package/dist/components/Stepper/Stepper.js +1 -1
  57. package/dist/components/Stepper/components/StepperButton.js +1 -1
  58. package/dist/components/Stepper/components/StepperHeader.js +3 -3
  59. package/dist/components/Stepper/components/StepperItem.js +2 -2
  60. package/dist/{correct-is-regexp-logic-Y0ToWEjF.js → correct-is-regexp-logic-BJ-OWRrn.js} +1 -1
  61. package/dist/{defineProperty-BTsGZ3c1.js → defineProperty-B7N9EBBI.js} +3 -3
  62. package/dist/{es.string.iterator-UszlTFwY.js → es.string.iterator-DBx2A42F.js} +2 -2
  63. package/dist/{find-CHg-_ooq.js → find-eU9ab_u7.js} +4 -4
  64. package/dist/{get-DxjPG00Z.js → get-BLvvbtML.js} +3 -3
  65. package/dist/get-CBFiuc3f.js +7 -0
  66. package/dist/hooks/useBreakpoints.js +37 -3
  67. package/dist/hooks/useHelperText.js +1 -1
  68. package/dist/{identity-BVIVr9qu.js → identity-B0bbReND.js} +4 -4
  69. package/dist/{index-BcGujPyk.js → index-Df2FYN-K.js} +5 -26
  70. package/dist/{index.es-B8p8KCdj.js → index.es-B19PQgzU.js} +4 -4
  71. package/dist/{index.es-BYcQTTL8.js → index.es-B9BUXRQn.js} +9 -339
  72. package/dist/{index.es-BPv5dCFQ.js → index.es-BOG3_7IM.js} +12 -12
  73. package/dist/{index.es-DGoBge9W.js → index.es-BOvO8moE.js} +4 -4
  74. package/dist/{index.es-BoUnovl_.js → index.es-BcnmoCEg.js} +8 -74
  75. package/dist/{index.es-C32E1Lcb.js → index.es-BwafUoK3.js} +82 -147
  76. package/dist/{index.es-B1h6DPYp.js → index.es-C27R5Xae.js} +2 -2
  77. package/dist/{index.es-nwjKmW7-.js → index.es-C2IOpX7R.js} +34 -111
  78. package/dist/{index.es-Da7ok-B-.js → index.es-C6I3L4U4.js} +2 -2
  79. package/dist/{index.es-BHvm4m-B.js → index.es-Cg57snrN.js} +19 -261
  80. package/dist/{index.es-DUTChZks.js → index.es-Ci3O23C_.js} +6 -72
  81. package/dist/{index.es-t87yNd9Y.js → index.es-CkB4776y.js} +6 -72
  82. package/dist/{index.es-CeQB6igi.js → index.es-Cr1PSTyq.js} +3 -3
  83. package/dist/{index.es--C-VLspF.js → index.es-D1iB_QlE.js} +8 -140
  84. package/dist/{index.es-Dgxrk6xW.js → index.es-DEBGoIKX.js} +2 -2
  85. package/dist/{index.es-CWyjqoEE.js → index.es-DHnCVuQ8.js} +7 -73
  86. package/dist/{index.es-Bo-d_yTV.js → index.es-DHoIQ8lu.js} +2 -2
  87. package/dist/{index.es-SjZ_-d7U.js → index.es-DUrjyxNI.js} +5 -5
  88. package/dist/{index.es-Cfv794DG.js → index.es-DdeCB7LW.js} +1 -1
  89. package/dist/{index.es-BanVdXEd.js → index.es-DgncYOqO.js} +2 -2
  90. package/dist/{index.es-DOnQ26kT.js → index.es-DhlgTSuU.js} +3 -3
  91. package/dist/{index.es-oxil0uFe.js → index.es-Z0aF-7Cn.js} +3 -6
  92. package/dist/{index.es-DmRhbgqK.js → index.es-l_3PNohs.js} +2 -68
  93. package/dist/{isArray-B457bpaW.js → isArray-Ce1Q96lU.js} +1 -1
  94. package/dist/isArray-olhCpv2e.js +7 -0
  95. package/dist/{isEmpty-BnfHn4bl.js → isEmpty-l2xQKl4x.js} +3 -3
  96. package/dist/{isString-DVA49FEo.js → isString-BNdV0Jpg.js} +3 -3
  97. package/dist/{isTypedArray-DziahYkI.js → isTypedArray-D39qzPYE.js} +2 -2
  98. package/dist/{keyboard-DiKJoabs.js → keyboard-DbG3oyPU.js} +3 -25
  99. package/dist/main.js +15 -15
  100. package/dist/{map-BprzXv4m.js → map-ZSVweMI1.js} +5 -5
  101. package/dist/{omit-CYY_mIYv.js → omit-BWQrFyQ-.js} +7 -7
  102. package/dist/{orderBy-DLBJlgdL.js → orderBy-Ce85KqD6.js} +7 -7
  103. package/dist/{parse-int-D-3oah_F.js → parse-int-CGpIXMGa.js} +2 -2
  104. package/dist/{react-number-format.es-DzkMiF8j.js → react-number-format.es-pczkQ4lQ.js} +0 -1
  105. package/dist/{react-tooltip.min-CVsI--2Y.js → react-tooltip.min-Dkz5ltCC.js} +1 -12
  106. package/dist/{react.esm-Bm0cAgpZ.js → react.esm-DF7i80eN.js} +2471 -2582
  107. package/dist/services/UtilService.js +9 -9
  108. package/dist/{slicedToArray-ByMQIs5x.js → slicedToArray-DC6VAZtW.js} +4 -4
  109. package/dist/test-utils.js +1 -1
  110. package/dist/{toString-B7FIT8FE.js → toString-D5bEU-DN.js} +1 -1
  111. package/dist/{uniqueId-BNVTeImh.js → uniqueId-CJo-XRQb.js} +2 -2
  112. package/dist/{util-DA21pZXj.js → util-CBo-ipCE.js} +0 -22
  113. package/package.json +2 -2
  114. package/dist/BigLoadingSpinner-DGj9_Z5J.js +0 -16
  115. package/dist/OfflineView-CIwV08EQ.js +0 -48
  116. package/dist/animationframe-BVKDmEXe.js +0 -54
  117. package/dist/component-Bz_dtX1r.js +0 -114
  118. package/dist/components/AlertBanner/AlertBanner.test.d.ts +0 -1
  119. package/dist/components/AlertBanner/AlertBanner.test.js +0 -34
  120. package/dist/components/AlertBanner/LinkBanner.test.d.ts +0 -1
  121. package/dist/components/AlertBanner/LinkBanner.test.js +0 -17
  122. package/dist/components/Allowed/Allowed.test.d.ts +0 -1
  123. package/dist/components/Allowed/Allowed.test.js +0 -49
  124. package/dist/components/AllowedButton/AllowedButton.test.d.ts +0 -1
  125. package/dist/components/AllowedButton/AllowedButton.test.js +0 -126
  126. package/dist/components/AllowedIconButton/AllowedIconButton.test.d.ts +0 -1
  127. package/dist/components/AllowedIconButton/AllowedIconButton.test.js +0 -121
  128. package/dist/components/BaseView/BaseView.test.d.ts +0 -1
  129. package/dist/components/BaseView/BaseView.test.js +0 -180
  130. package/dist/components/BasicHeading/BasicHeading.test.d.ts +0 -1
  131. package/dist/components/BasicHeading/BasicHeading.test.js +0 -36
  132. package/dist/components/BlockView/BlockView.test.d.ts +0 -1
  133. package/dist/components/BlockView/BlockView.test.js +0 -47
  134. package/dist/components/ButtonCard/ButtonCard.test.d.ts +0 -1
  135. package/dist/components/ButtonCard/ButtonCard.test.js +0 -92
  136. package/dist/components/ChipCard/ChipCard.test.d.ts +0 -1
  137. package/dist/components/ChipCard/ChipCard.test.js +0 -25
  138. package/dist/components/ConfirmationModal/ConfirmationModal.test.d.ts +0 -1
  139. package/dist/components/ConfirmationModal/ConfirmationModal.test.js +0 -221
  140. package/dist/components/ContextMenu/ContextMenu.test.d.ts +0 -1
  141. package/dist/components/ContextMenu/ContextMenu.test.js +0 -96
  142. package/dist/components/DeleteModal/DeleteModal.test.d.ts +0 -1
  143. package/dist/components/DeleteModal/DeleteModal.test.js +0 -132
  144. package/dist/components/Disclaimer/Disclaimer.test.d.ts +0 -1
  145. package/dist/components/Disclaimer/Disclaimer.test.js +0 -13
  146. package/dist/components/EmptyView/EmptyView.test.d.ts +0 -1
  147. package/dist/components/EmptyView/EmptyView.test.js +0 -50
  148. package/dist/components/Filter/Filter.test.d.ts +0 -1
  149. package/dist/components/Filter/Filter.test.js +0 -166
  150. package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.d.ts +0 -1
  151. package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.js +0 -56
  152. package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.d.ts +0 -1
  153. package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.js +0 -56
  154. package/dist/components/FormComponents/FormNumber/FormNumber.test.d.ts +0 -1
  155. package/dist/components/FormComponents/FormNumber/FormNumber.test.js +0 -51
  156. package/dist/components/FormComponents/FormRadio/FormRadio.test.d.ts +0 -1
  157. package/dist/components/FormComponents/FormRadio/FormRadio.test.js +0 -73
  158. package/dist/components/FormComponents/FormSelect/FormSelect.test.d.ts +0 -1
  159. package/dist/components/FormComponents/FormSelect/FormSelect.test.js +0 -226
  160. package/dist/components/FormComponents/FormSlider/FormSlider.test.d.ts +0 -1
  161. package/dist/components/FormComponents/FormSlider/FormSlider.test.js +0 -49
  162. package/dist/components/FormComponents/FormText/FormText.test.d.ts +0 -1
  163. package/dist/components/FormComponents/FormText/FormText.test.js +0 -113
  164. package/dist/components/FormComponents/FormToggle/FormToggle.test.d.ts +0 -1
  165. package/dist/components/FormComponents/FormToggle/FormToggle.test.js +0 -54
  166. package/dist/components/GenericTable/GenericTable.test.d.ts +0 -1
  167. package/dist/components/GenericTable/GenericTable.test.js +0 -115
  168. package/dist/components/GenericTable/Mobile/GenericCard.test.d.ts +0 -1
  169. package/dist/components/GenericTable/Mobile/GenericCard.test.js +0 -76
  170. package/dist/components/GenericTable/Mobile/GenericCardList.test.d.ts +0 -1
  171. package/dist/components/GenericTable/Mobile/GenericCardList.test.js +0 -75
  172. package/dist/components/HashTabView/HashTabView.test.d.ts +0 -1
  173. package/dist/components/HashTabView/HashTabView.test.js +0 -31
  174. package/dist/components/HeaderFilter/HeaderFilter.test.d.ts +0 -1
  175. package/dist/components/HeaderFilter/HeaderFilter.test.js +0 -46
  176. package/dist/components/Iconify/Iconify.test.d.ts +0 -1
  177. package/dist/components/Iconify/Iconify.test.js +0 -28
  178. package/dist/components/InfoCard/InfoCard.test.d.ts +0 -1
  179. package/dist/components/InfoCard/InfoCard.test.js +0 -48
  180. package/dist/components/InfoGroup/InfoGroup.test.d.ts +0 -1
  181. package/dist/components/InfoGroup/InfoGroup.test.js +0 -40
  182. package/dist/components/ListArea/ListArea.test.d.ts +0 -1
  183. package/dist/components/ListArea/ListArea.test.js +0 -110
  184. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.d.ts +0 -1
  185. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.js +0 -15
  186. package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.d.ts +0 -1
  187. package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.js +0 -20
  188. package/dist/components/ModulePadding/ModulePadding.test.d.ts +0 -1
  189. package/dist/components/ModulePadding/ModulePadding.test.js +0 -22
  190. package/dist/components/OfflineView/OfflineView.test.d.ts +0 -1
  191. package/dist/components/OfflineView/OfflineView.test.js +0 -24
  192. package/dist/components/OnboardingBanner/OnboardingBanner.test.d.ts +0 -1
  193. package/dist/components/OnboardingBanner/OnboardingBanner.test.js +0 -72
  194. package/dist/components/OverflowTooltip/OverflowTooltip.test.d.ts +0 -1
  195. package/dist/components/OverflowTooltip/OverflowTooltip.test.js +0 -37
  196. package/dist/components/PermissionChecks/PermissionService.test.d.ts +0 -1
  197. package/dist/components/PermissionChecks/PermissionService.test.js +0 -91
  198. package/dist/components/SafeForm/SafeForm.test.d.ts +0 -1
  199. package/dist/components/SafeForm/SafeForm.test.js +0 -91
  200. package/dist/components/Scrollbar/scrollbar.test.d.ts +0 -1
  201. package/dist/components/Scrollbar/scrollbar.test.js +0 -15
  202. package/dist/components/SearchBar/SearchBar.test.d.ts +0 -1
  203. package/dist/components/SearchBar/SearchBar.test.js +0 -23
  204. package/dist/components/Select/Select.test.d.ts +0 -1
  205. package/dist/components/Select/Select.test.js +0 -28
  206. package/dist/components/Stepper/Stepper.test.d.ts +0 -1
  207. package/dist/components/Stepper/Stepper.test.js +0 -342
  208. package/dist/components/VerticalDivider/VerticalDivider.test.d.ts +0 -1
  209. package/dist/components/VerticalDivider/VerticalDivider.test.js +0 -15
  210. package/dist/get-D8IXqiys.js +0 -7
  211. package/dist/hooks/useBreakpoints.test.d.ts +0 -1
  212. package/dist/hooks/useBreakpoints.test.js +0 -11
  213. package/dist/index-BLPBqbdx.js +0 -11025
  214. package/dist/isArray-BjSPDQ4v.js +0 -7
  215. package/dist/magic-string.es-uPKorP4O.js +0 -663
  216. package/dist/services/services.test.d.ts +0 -1
  217. package/dist/services/services.test.js +0 -106
  218. package/dist/useBreakpoints-MzTZ0tCT.js +0 -45
  219. package/dist/vi.bdSIJ99Y-B308Q-4w.js +0 -11963
@@ -1,19 +1,19 @@
1
- import { i as n } from "../isArray-BjSPDQ4v.js";
2
- import { i as p, a as s } from "../isString-DVA49FEo.js";
1
+ import { i as n } from "../isArray-olhCpv2e.js";
2
+ import { i as p, a as s } from "../isString-BNdV0Jpg.js";
3
3
  import { AVAILABLE_LOCALES as a, LANGUAGE_CODES_MAPPER as e } from "../types/Languages.js";
4
4
  import "react/jsx-runtime";
5
- import "../isEmpty-BnfHn4bl.js";
5
+ import "../isEmpty-l2xQKl4x.js";
6
6
  import "react";
7
- import "../react-tooltip.min-CVsI--2Y.js";
8
- import "../orderBy-DLBJlgdL.js";
7
+ import "../react-tooltip.min-Dkz5ltCC.js";
8
+ import "../orderBy-Ce85KqD6.js";
9
9
  import "../index-CuHybtft.js";
10
10
  import "../components/SharedComponentsPermissionProvider/PermissionContext.js";
11
- import "../uniqueId-BNVTeImh.js";
11
+ import "../uniqueId-CJo-XRQb.js";
12
12
  import "react-hook-form";
13
- import "../get-D8IXqiys.js";
14
- import "../omit-CYY_mIYv.js";
13
+ import "../get-CBFiuc3f.js";
14
+ import "../omit-BWQrFyQ-.js";
15
15
  import { DATE_FORMAT as c } from "../types/Time.js";
16
- import "../react.esm-Bm0cAgpZ.js";
16
+ import "../react.esm-DF7i80eN.js";
17
17
  const d = (t) => t.split(" ").map((r) => r.charAt(0).toUpperCase() + r.slice(1).toLowerCase()).join(" "), f = (t) => Object.fromEntries(
18
18
  Object.entries(t).map(([r, i]) => [r, o(i)])
19
19
  ), o = (t) => n(t) ? t.map(o) : p(t) ? f(t) : s(t) ? t.trim() : t, P = (t, r, i = 2) => {
@@ -1,7 +1,7 @@
1
- import { g as S } from "./_commonjsHelpers-B4e78b8K.js";
2
- import { q as ue } from "./index.es-Da7ok-B-.js";
3
- import { b as Yr, c as se, d as Zr, e as fe, _ as ve } from "./es.string.iterator-UszlTFwY.js";
4
- import { r as _, Q as ce, R as re, S as he, T as le, N as ee, y as de, j as ur, k as te, l as sr, o as ye, s as ae, t as ne, i as qe, U as pe, m as Ie, V as oe, e as $e, L as ge, q as ie, C as fr, B as vr, G as Ae, h as me, A as Re, z as Se } from "./index-BcGujPyk.js";
1
+ import { g as S } from "./_commonjsHelpers-ByX85dGu.js";
2
+ import { q as ue } from "./index.es-C6I3L4U4.js";
3
+ import { b as Yr, c as se, d as Zr, e as fe, _ as ve } from "./es.string.iterator-DBx2A42F.js";
4
+ import { r as _, Q as ce, R as re, S as he, T as le, N as ee, y as de, j as ur, k as te, l as sr, o as ye, s as ae, t as ne, i as qe, U as pe, m as Ie, V as oe, e as $e, L as ge, q as ie, C as fr, B as vr, G as Ae, h as me, A as Re, z as Se } from "./index-Df2FYN-K.js";
5
5
  var E, hr;
6
6
  function Oe() {
7
7
  if (hr) return E;
@@ -1,5 +1,5 @@
1
1
  import { jsx as i } from "react/jsx-runtime";
2
- import { a as t } from "./react.esm-Bm0cAgpZ.js";
2
+ import { r as t } from "./react.esm-DF7i80eN.js";
3
3
  import { SharedComponentsPermissionProvider as n } from "./components/SharedComponentsPermissionProvider/SharedComponentsPermissionProvider.js";
4
4
  const a = (r, {
5
5
  userPermissions: e = {},
@@ -1,4 +1,4 @@
1
- import { a as q, b as p, c as T, r as _ } from "./isArray-B457bpaW.js";
1
+ import { a as q, b as p, c as T, r as _ } from "./isArray-Ce1Q96lU.js";
2
2
  var s, g;
3
3
  function d() {
4
4
  if (g) return s;
@@ -1,5 +1,5 @@
1
- import { g as a } from "./_commonjsHelpers-B4e78b8K.js";
2
- import { r as d } from "./toString-B7FIT8FE.js";
1
+ import { g as a } from "./_commonjsHelpers-ByX85dGu.js";
2
+ import { r as d } from "./toString-D5bEU-DN.js";
3
3
  var r, u;
4
4
  function q() {
5
5
  if (u) return r;
@@ -1,25 +1,3 @@
1
- /**
2
- * @license
3
- * Copyright 2016 Google Inc.
4
- *
5
- * Permission is hereby granted, free of charge, to any person obtaining a copy
6
- * of this software and associated documentation files (the "Software"), to deal
7
- * in the Software without restriction, including without limitation the rights
8
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- * copies of the Software, and to permit persons to whom the Software is
10
- * furnished to do so, subject to the following conditions:
11
- *
12
- * The above copyright notice and this permission notice shall be included in
13
- * all copies or substantial portions of the Software.
14
- *
15
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- * THE SOFTWARE.
22
- */
23
1
  var d = {
24
2
  animation: {
25
3
  prefixed: "-webkit-animation",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@hortiview/shared-components",
3
3
  "description": "This is a shared component library. It should used in the HortiView platform and its modules.",
4
- "version": "2.18.0",
4
+ "version": "2.18.1",
5
5
  "type": "module",
6
6
  "repository": "https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared",
7
7
  "author": "Falk Menge <falk.menge.ext@bayer.com>",
@@ -97,7 +97,7 @@
97
97
  "semantic-release-ado": "^1.4.0",
98
98
  "storybook": "^8.5.3",
99
99
  "typescript": "^5.2.2",
100
- "vite": "^6.4.1",
100
+ "vite": "^7.3.1",
101
101
  "vite-plugin-dts": "^3.7.3",
102
102
  "vite-plugin-lib-inject-css": "^2.2.2",
103
103
  "vite-plugin-svgr": "^4.5.0",
@@ -1,16 +0,0 @@
1
- import { jsx as i, jsxs as n } from "react/jsx-runtime";
2
- import { T as r } from "./index.es-SjZ_-d7U.js";
3
- import { Iconify as d } from "./components/Iconify/Iconify.js";
4
- import './assets/BigLoadingSpinner.css';const e = "_loadingBigOverlay_7dxo1_1", s = "_bigLoadSpinnerCard_7dxo1_12", g = "_bigLoadSpinnerCardText_7dxo1_27", t = "_logo_7dxo1_33", o = {
5
- loadingBigOverlay: e,
6
- bigLoadSpinnerCard: s,
7
- bigLoadSpinnerCardText: g,
8
- logo: t
9
- }, l = ({ text: a }) => /* @__PURE__ */ n("div", { className: o.bigLoadSpinnerCard, role: "progressbar", "data-testid": "loading-spinner", children: [
10
- /* @__PURE__ */ i(d, { icon: "hortiview", className: o.logo, "data-testid": "logo-icon" }),
11
- /* @__PURE__ */ i(r, { tag: "p", bold: !0, level: 1, className: o.bigLoadSpinnerCardText, children: a })
12
- ] }), b = (a) => /* @__PURE__ */ i("div", { "data-testid": "big-loading-spinner", className: o.loadingBigOverlay, children: /* @__PURE__ */ i(l, { ...a }) });
13
- export {
14
- b as B,
15
- o as s
16
- };
@@ -1,48 +0,0 @@
1
- import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
- import { G as o } from "./index.es-oxil0uFe.js";
3
- import { Iconify as _ } from "./components/Iconify/Iconify.js";
4
- import { b as m, d as y, T as h } from "./index.es-SjZ_-d7U.js";
5
- import { B as A } from "./index.es-B8p8KCdj.js";
6
- import './assets/OfflineView.css';const T = "_gapAndTextAlign_10nts_1", v = "_container_10nts_6", x = "_bgWhite_10nts_12", G = "_bgGrey_10nts_17", W = "_subtitle_10nts_22", t = {
7
- gapAndTextAlign: T,
8
- container: v,
9
- bgWhite: x,
10
- bgGrey: G,
11
- subtitle: W
12
- }, j = ({
13
- title: i = "You’re currently offline",
14
- subtitle: n = "This feature is unavailable until you reconnect",
15
- icon: l = "cloud_off",
16
- size: c = "large",
17
- variant: d = "basic",
18
- "data-testid": g = "offline-view-container",
19
- buttonLabel: a,
20
- fullWidth: f = !1,
21
- className: b,
22
- onClick: p
23
- }) => {
24
- const s = c === "large", u = d === "filled";
25
- return /* @__PURE__ */ r(
26
- o,
27
- {
28
- className: `${b} ${t.container} ${u ? t.bgGrey : t.bgWhite}`,
29
- gap: "standard",
30
- direction: "vertical",
31
- "data-testid": g,
32
- secondaryAlign: "center",
33
- fullWidth: f,
34
- children: [
35
- /* @__PURE__ */ r(o, { direction: "vertical", secondaryAlign: "center", className: t.gapAndTextAlign, children: [
36
- /* @__PURE__ */ e(_, { icon: l, iconSize: s ? "xlarge" : "medium" }),
37
- s ? /* @__PURE__ */ e(m, { level: 6, children: i }) : /* @__PURE__ */ e(y, { level: 1, bold: !0, children: i })
38
- ] }),
39
- n && /* @__PURE__ */ e(h, { className: t.subtitle, level: 2, children: n }),
40
- a && /* @__PURE__ */ e(A, { "data-testid": "offline-view-action-button", label: a, onClick: p })
41
- ]
42
- }
43
- );
44
- };
45
- export {
46
- j as O,
47
- t as s
48
- };
@@ -1,54 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright 2020 Google Inc.
4
- *
5
- * Permission is hereby granted, free of charge, to any person obtaining a copy
6
- * of this software and associated documentation files (the "Software"), to deal
7
- * in the Software without restriction, including without limitation the rights
8
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- * copies of the Software, and to permit persons to whom the Software is
10
- * furnished to do so, subject to the following conditions:
11
- *
12
- * The above copyright notice and this permission notice shall be included in
13
- * all copies or substantial portions of the Software.
14
- *
15
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- * THE SOFTWARE.
22
- */
23
- var o = (
24
- /** @class */
25
- (function() {
26
- function a() {
27
- this.rafIDs = /* @__PURE__ */ new Map();
28
- }
29
- return a.prototype.request = function(t, n) {
30
- var e = this;
31
- this.cancel(t);
32
- var r = requestAnimationFrame(function(i) {
33
- e.rafIDs.delete(t), n(i);
34
- });
35
- this.rafIDs.set(t, r);
36
- }, a.prototype.cancel = function(t) {
37
- var n = this.rafIDs.get(t);
38
- n && (cancelAnimationFrame(n), this.rafIDs.delete(t));
39
- }, a.prototype.cancelAll = function() {
40
- var t = this;
41
- this.rafIDs.forEach(function(n, e) {
42
- t.cancel(e);
43
- });
44
- }, a.prototype.getQueue = function() {
45
- var t = [];
46
- return this.rafIDs.forEach(function(n, e) {
47
- t.push(e);
48
- }), t;
49
- }, a;
50
- })()
51
- );
52
- export {
53
- o as A
54
- };
@@ -1,114 +0,0 @@
1
- import { _ as r, a as u } from "./tslib.es6-BDCynO9F.js";
2
- /**
3
- * @license
4
- * Copyright 2016 Google Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in
14
- * all copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22
- * THE SOFTWARE.
23
- */
24
- var a = (
25
- /** @class */
26
- (function() {
27
- function t(e) {
28
- e === void 0 && (e = {}), this.adapter = e;
29
- }
30
- return Object.defineProperty(t, "cssClasses", {
31
- get: function() {
32
- return {};
33
- },
34
- enumerable: !1,
35
- configurable: !0
36
- }), Object.defineProperty(t, "strings", {
37
- get: function() {
38
- return {};
39
- },
40
- enumerable: !1,
41
- configurable: !0
42
- }), Object.defineProperty(t, "numbers", {
43
- get: function() {
44
- return {};
45
- },
46
- enumerable: !1,
47
- configurable: !0
48
- }), Object.defineProperty(t, "defaultAdapter", {
49
- get: function() {
50
- return {};
51
- },
52
- enumerable: !1,
53
- configurable: !0
54
- }), t.prototype.init = function() {
55
- }, t.prototype.destroy = function() {
56
- }, t;
57
- })()
58
- );
59
- /**
60
- * @license
61
- * Copyright 2016 Google Inc.
62
- *
63
- * Permission is hereby granted, free of charge, to any person obtaining a copy
64
- * of this software and associated documentation files (the "Software"), to deal
65
- * in the Software without restriction, including without limitation the rights
66
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
67
- * copies of the Software, and to permit persons to whom the Software is
68
- * furnished to do so, subject to the following conditions:
69
- *
70
- * The above copyright notice and this permission notice shall be included in
71
- * all copies or substantial portions of the Software.
72
- *
73
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
74
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
75
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
76
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
77
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
78
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
79
- * THE SOFTWARE.
80
- */
81
- var f = (
82
- /** @class */
83
- (function() {
84
- function t(e, o) {
85
- for (var n = [], i = 2; i < arguments.length; i++)
86
- n[i - 2] = arguments[i];
87
- this.root = e, this.initialize.apply(this, r([], u(n))), this.foundation = o === void 0 ? this.getDefaultFoundation() : o, this.foundation.init(), this.initialSyncWithDOM();
88
- }
89
- return t.attachTo = function(e) {
90
- return new t(e, new a({}));
91
- }, t.prototype.initialize = function() {
92
- }, t.prototype.getDefaultFoundation = function() {
93
- throw new Error("Subclasses must override getDefaultFoundation to return a properly configured foundation class");
94
- }, t.prototype.initialSyncWithDOM = function() {
95
- }, t.prototype.destroy = function() {
96
- this.foundation.destroy();
97
- }, t.prototype.listen = function(e, o, n) {
98
- this.root.addEventListener(e, o, n);
99
- }, t.prototype.unlisten = function(e, o, n) {
100
- this.root.removeEventListener(e, o, n);
101
- }, t.prototype.emit = function(e, o, n) {
102
- n === void 0 && (n = !1);
103
- var i;
104
- typeof CustomEvent == "function" ? i = new CustomEvent(e, {
105
- bubbles: n,
106
- detail: o
107
- }) : (i = document.createEvent("CustomEvent"), i.initCustomEvent(e, n, !1, o)), this.root.dispatchEvent(i);
108
- }, t;
109
- })()
110
- );
111
- export {
112
- a as M,
113
- f as a
114
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,34 +0,0 @@
1
- import { jsx as e, Fragment as m } from "react/jsx-runtime";
2
- import { a as t, s } from "../../react.esm-Bm0cAgpZ.js";
3
- import { a as i } from "../../useBreakpoints-MzTZ0tCT.js";
4
- import { A as n } from "../../AlertBanner-aW6joVUm.js";
5
- import { d as p, b as c, t as r, g as a, a as o } from "../../vi.bdSIJ99Y-B308Q-4w.js";
6
- p("AlertBanner Test", () => {
7
- c(() => {
8
- o.spyOn(i, "useBreakpoints").mockReturnValue({
9
- isMobile: !1,
10
- isTablet: !1,
11
- isDesktop: !0,
12
- isDesktopNavbar: !0
13
- });
14
- }), r("render AlertBanner with text", () => {
15
- t(/* @__PURE__ */ e(n, { text: "Test" })), a(s.getByText("Test")).toBeInTheDocument();
16
- }), r("render AlertBanner with element", () => {
17
- t(/* @__PURE__ */ e(n, { text: /* @__PURE__ */ e(m, { children: "Element" }) })), a(s.getByText("Element")).toBeInTheDocument();
18
- }), r("renders AlertBanner with vertical style (flex-direction: column) when screen is small", () => {
19
- o.spyOn(i, "useBreakpoints").mockReturnValue({
20
- isMobile: !0,
21
- isTablet: !1,
22
- isDesktop: !1,
23
- isDesktopNavbar: !1
24
- }), t(/* @__PURE__ */ e(n, { text: "Test" }));
25
- const l = s.getByText("Test").closest(".lmnt.lmnt-group");
26
- a(l).toHaveStyle(
27
- "display: flex; flex-direction: row; justify-content: space-between; align-items: baseline; gap: 8px;"
28
- );
29
- }), r("renders nothing when isOpen is false", () => {
30
- t(/* @__PURE__ */ e(n, { text: "Test", isOpen: !1 })), a(s.queryByText("Test")).not.toBeInTheDocument();
31
- }), r("renders AlertBanner with id", () => {
32
- t(/* @__PURE__ */ e(n, { text: "Test", id: "test-id" })), a(s.getByTestId("alert-banner")).toHaveAttribute("id", "test-id");
33
- });
34
- });
@@ -1 +0,0 @@
1
- export {};
@@ -1,17 +0,0 @@
1
- import { jsx as s } from "react/jsx-runtime";
2
- import { a as r, s as e } from "../../react.esm-Bm0cAgpZ.js";
3
- import { a as o } from "../../useBreakpoints-MzTZ0tCT.js";
4
- import { LinkBanner as a } from "./LinkBanner.js";
5
- import { d as n, b as i, t as m, g as t, a as p } from "../../vi.bdSIJ99Y-B308Q-4w.js";
6
- n("LinkBanner Test", () => {
7
- i(() => {
8
- p.spyOn(o, "useBreakpoints").mockReturnValue({
9
- isMobile: !1,
10
- isTablet: !1,
11
- isDesktop: !0,
12
- isDesktopNavbar: !0
13
- });
14
- }), m("render LinkBanner with text", () => {
15
- r(/* @__PURE__ */ s(a, { text: "Test", url: "#" })), t(e.getByText("Test")).toBeInTheDocument(), t(e.getByText("open_in_new")).toBeInTheDocument(), t(e.getByRole("link")).toHaveAttribute("href", "#");
16
- });
17
- });
@@ -1 +0,0 @@
1
- export {};
@@ -1,49 +0,0 @@
1
- import { jsx as e } from "react/jsx-runtime";
2
- import { s as n } from "../../react.esm-Bm0cAgpZ.js";
3
- import { renderWithPermissions as s } from "../../test-utils.js";
4
- import { HVMainPermissions as o } from "../../types/Permission.js";
5
- import { Allowed as i } from "./Allowed.js";
6
- import { d as l, t as d, g as t } from "../../vi.bdSIJ99Y-B308Q-4w.js";
7
- l("Test Allowed", () => {
8
- d("should return the children if allowed to see them", () => {
9
- const r = /* @__PURE__ */ e("div", { children: "Allowed to see children" });
10
- s(
11
- /* @__PURE__ */ e(i, { neededPermissions: [o.CurrentUserRead], entityIds: "General", children: r }),
12
- {
13
- userPermissions: {
14
- General: [o.CurrentUserRead]
15
- }
16
- }
17
- ), t(n.getByText("Allowed to see children")).toBeInTheDocument();
18
- }), d("should return empty wrapper when not allowed to see children", () => {
19
- const r = /* @__PURE__ */ e("div", { children: "Allowed to see children" });
20
- s(
21
- /* @__PURE__ */ e(i, { neededPermissions: [o.CurrentUserRead], entityIds: "General", children: r }),
22
- {
23
- userPermissions: {
24
- General: []
25
- }
26
- }
27
- ), t(n.queryByText("Allowed to see children")).not.toBeInTheDocument();
28
- }), d("should return disclaimer when defined & not allowed to see children", () => {
29
- const r = /* @__PURE__ */ e("div", { children: "Allowed to see children" });
30
- s(
31
- /* @__PURE__ */ e(
32
- i,
33
- {
34
- disclaimer: !0,
35
- neededPermissions: [o.CurrentUserRead],
36
- entityIds: "General",
37
- children: r
38
- }
39
- ),
40
- {
41
- userPermissions: {
42
- General: []
43
- }
44
- }
45
- ), t(n.queryByText("Allowed to see children")).not.toBeInTheDocument(), t(
46
- n.getByText("You are not allowed to see the content of this section.")
47
- ).toBeInTheDocument();
48
- });
49
- });
@@ -1 +0,0 @@
1
- export {};
@@ -1,126 +0,0 @@
1
- import { jsx as o } from "react/jsx-runtime";
2
- import { s as e, f as u } from "../../react.esm-Bm0cAgpZ.js";
3
- import { renderWithPermissions as n } from "../../test-utils.js";
4
- import { HVMainPermissions as i } from "../../types/Permission.js";
5
- import { AllowedButton as d } from "./AllowedButton.js";
6
- import { u as b } from "../../useBreakpoints-MzTZ0tCT.js";
7
- import { v as l, d as m, b as c, t as r, g as t } from "../../vi.bdSIJ99Y-B308Q-4w.js";
8
- l.mock("../../hooks/useBreakpoints", () => ({
9
- useBreakpoints: l.fn()
10
- }));
11
- m("AllowedButton Test", () => {
12
- c(() => {
13
- l.mocked(b).mockReturnValue({
14
- isDesktop: !0,
15
- isMobile: !1,
16
- isTablet: !1,
17
- isDesktopNavbar: !0
18
- });
19
- }), r("renders button with no permissions required", () => {
20
- n(
21
- /* @__PURE__ */ o(d, { "data-testid": "test", label: "Add", permissions: [], entityIds: "General" })
22
- ), t(e.getByText("Add")).toBeInTheDocument();
23
- }), r("renders outlined button variant", () => {
24
- n(
25
- /* @__PURE__ */ o(
26
- d,
27
- {
28
- "data-testid": "regular-outlined-button",
29
- label: "Add",
30
- variant: "outlined",
31
- permissions: [],
32
- entityIds: "General"
33
- }
34
- )
35
- );
36
- const s = e.getAllByRole("button")[0];
37
- t(s).toHaveClass("mdc-button--outlined"), t(e.getByTestId("allowed-button-regular-outlined-button")).toBeInTheDocument();
38
- }), r("renders full-width button", () => {
39
- n(
40
- /* @__PURE__ */ o(
41
- d,
42
- {
43
- "data-testid": "regular-button",
44
- label: "Add",
45
- fullWidth: !0,
46
- permissions: [],
47
- entityIds: "General"
48
- }
49
- )
50
- );
51
- const s = e.getAllByRole("button")[0];
52
- t(s).toHaveClass("lmnt-button--full-width"), t(e.getByTestId("allowed-button-regular-button")).toBeInTheDocument();
53
- }), r("calls onClick when clicked", () => {
54
- const s = l.fn();
55
- n(
56
- /* @__PURE__ */ o(
57
- d,
58
- {
59
- "data-testid": "test-onclick-button",
60
- label: "Add",
61
- onClick: s,
62
- permissions: [],
63
- entityIds: "General"
64
- }
65
- )
66
- );
67
- const a = e.getAllByRole("button")[0];
68
- u.click(a), t(s).toHaveBeenCalled(), t(e.getByTestId("allowed-button-test-onclick-button")).toBeInTheDocument();
69
- }), r("renders disabled button when prop is used", () => {
70
- n(
71
- /* @__PURE__ */ o(
72
- d,
73
- {
74
- "data-testid": "disabled-button",
75
- label: "Add",
76
- permissions: [i.SuperUser],
77
- entityIds: "farm-123",
78
- disabled: !0
79
- }
80
- ),
81
- {
82
- userPermissions: {
83
- "farm-123": [i.SuperUser]
84
- }
85
- }
86
- ), t(e.getByText("Add")).toBeInTheDocument(), t(e.getByTestId("allowed-button-disabled-button")).toBeInTheDocument();
87
- const s = e.getAllByRole("button")[0];
88
- t(s).toHaveAttribute("disabled");
89
- }), r("hides button when permission is missing", () => {
90
- n(
91
- /* @__PURE__ */ o(
92
- d,
93
- {
94
- "data-testid": "missing",
95
- label: "Add",
96
- permissions: [i.SuperUser],
97
- entityIds: "farm-123"
98
- }
99
- ),
100
- {
101
- userPermissions: {
102
- "farm-123": [i.FarmsUpdate, i.FarmsRead]
103
- }
104
- }
105
- ), t(e.queryByText("Add")).not.toBeInTheDocument(), t(e.queryByTestId("allowed-button-missing")).not.toBeInTheDocument();
106
- }), r("renders button when permission exists", () => {
107
- n(
108
- /* @__PURE__ */ o(
109
- d,
110
- {
111
- "data-testid": "enabled",
112
- label: "Add",
113
- permissions: [i.SuperUser],
114
- entityIds: "farm-123"
115
- }
116
- ),
117
- {
118
- userPermissions: {
119
- "farm-123": [i.SuperUser]
120
- }
121
- }
122
- ), t(e.getByText("Add")).toBeInTheDocument(), t(e.getByTestId("allowed-button-enabled")).toBeInTheDocument();
123
- const s = e.getAllByRole("button")[0];
124
- t(s).not.toHaveAttribute("disabled");
125
- });
126
- });