@lanaco/lnc-react-ui 4.0.99 → 4.0.101

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 (240) hide show
  1. package/dist/Accordion.cjs +1 -1
  2. package/dist/Accordion.js +1 -1
  3. package/dist/AccordionSummary.cjs +1 -1
  4. package/dist/AccordionSummary.js +1 -1
  5. package/dist/ActionsToolbar.cjs +1 -1
  6. package/dist/ActionsToolbar.js +1 -1
  7. package/dist/Alert.cjs +1 -1
  8. package/dist/Alert.js +1 -1
  9. package/dist/Avatar.cjs +1 -1
  10. package/dist/Avatar.js +1 -1
  11. package/dist/Badge.cjs +1 -1
  12. package/dist/Badge.js +1 -1
  13. package/dist/BannerSectionCarousel.cjs +1 -1
  14. package/dist/BannerSectionCarousel.js +1 -1
  15. package/dist/BannerSectionWithList.cjs +1 -1
  16. package/dist/BannerSectionWithList.js +1 -1
  17. package/dist/BlogCardsSponsoredSection.cjs +1 -1
  18. package/dist/BlogCardsSponsoredSection.js +3 -3
  19. package/dist/BlogCategoryCardsSection.cjs +1 -1
  20. package/dist/BlogCategoryCardsSection.js +1 -1
  21. package/dist/BlogListSection.cjs +1 -1
  22. package/dist/BlogListSection.js +3 -3
  23. package/dist/BlogProductCardsSection.cjs +1 -1
  24. package/dist/BlogProductCardsSection.js +2 -2
  25. package/dist/BlogShopCardsSection.cjs +1 -1
  26. package/dist/BlogShopCardsSection.js +1 -1
  27. package/dist/BlogSingleSection.cjs +1 -1
  28. package/dist/BlogSingleSection.js +2 -2
  29. package/dist/BlogsSectionDetailed.cjs +1 -1
  30. package/dist/BlogsSectionDetailed.js +3 -3
  31. package/dist/BlogsSectionLarge.cjs +1 -1
  32. package/dist/BlogsSectionLarge.js +2 -2
  33. package/dist/BlogsSectionSimple.cjs +1 -1
  34. package/dist/BlogsSectionSimple.js +3 -3
  35. package/dist/BlogsSectionSimpleCentered.cjs +1 -1
  36. package/dist/BlogsSectionSimpleCentered.js +2 -2
  37. package/dist/BlogsSectionWithFilters.cjs +1 -1
  38. package/dist/BlogsSectionWithFilters.js +4 -4
  39. package/dist/BrandHitsSection.cjs +1 -1
  40. package/dist/BrandHitsSection.js +1 -1
  41. package/dist/Breadcrumbs.cjs +1 -1
  42. package/dist/Breadcrumbs.js +1 -1
  43. package/dist/Button.cjs +8 -8
  44. package/dist/Button.js +98 -97
  45. package/dist/ButtonGroup.cjs +1 -1
  46. package/dist/ButtonGroup.js +1 -1
  47. package/dist/CalorieCalculatorSection.cjs +1 -1
  48. package/dist/CalorieCalculatorSection.js +1 -1
  49. package/dist/CheckBoxInput.cjs +1 -1
  50. package/dist/CheckBoxInput.js +1 -1
  51. package/dist/Chip.cjs +1 -1
  52. package/dist/Chip.js +1 -1
  53. package/dist/ColorInput.cjs +1 -1
  54. package/dist/ColorInput.js +1 -1
  55. package/dist/ConfirmationForm.cjs +1 -1
  56. package/dist/ConfirmationForm.js +1 -1
  57. package/dist/CustomLoanMapSection.cjs +1 -1
  58. package/dist/CustomLoanMapSection.js +1 -1
  59. package/dist/{CustomStyles-9CHBrzIM.js → CustomStyles-DYULk9y7.js} +1 -1
  60. package/dist/{CustomStyles-BoYYyJVV.cjs → CustomStyles-Uqkz9jDo.cjs} +1 -1
  61. package/dist/DateInput.cjs +1 -1
  62. package/dist/DateInput.js +1 -1
  63. package/dist/DecimalInput.cjs +1 -1
  64. package/dist/DecimalInput.js +1 -1
  65. package/dist/DecimalInputV2.cjs +1 -1
  66. package/dist/DecimalInputV2.js +1 -1
  67. package/dist/DetailedProductsSection.cjs +1 -1
  68. package/dist/DetailedProductsSection.js +4 -4
  69. package/dist/DetailsView.cjs +1 -1
  70. package/dist/DetailsView.js +1 -1
  71. package/dist/DoubleRangeSlider.cjs +1 -1
  72. package/dist/DoubleRangeSlider.js +1 -1
  73. package/dist/DragAndDropFile.cjs +1 -1
  74. package/dist/DragAndDropFile.js +1 -1
  75. package/dist/DragDropFiles.cjs +1 -1
  76. package/dist/DragDropFiles.js +1 -1
  77. package/dist/Drawer.cjs +1 -1
  78. package/dist/Drawer.js +1 -1
  79. package/dist/Dropdown.cjs +1 -1
  80. package/dist/Dropdown.js +2 -2
  81. package/dist/DropdownItem.cjs +1 -1
  82. package/dist/DropdownItem.js +1 -1
  83. package/dist/DropdownLookup.cjs +1 -1
  84. package/dist/DropdownLookup.js +1 -1
  85. package/dist/DropdownMenu.cjs +1 -1
  86. package/dist/DropdownMenu.js +1 -1
  87. package/dist/EditableTable.cjs +1 -1
  88. package/dist/EditableTable.js +1 -1
  89. package/dist/FeedbackSection.cjs +1 -1
  90. package/dist/FeedbackSection.js +1 -1
  91. package/dist/FieldOfInterestsMasonrySection.cjs +1 -1
  92. package/dist/FieldOfInterestsMasonrySection.js +1 -1
  93. package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +1 -1
  94. package/dist/FieldOfInterestsWithAvatarsCardsSection.js +2 -2
  95. package/dist/FieldOfInterestsWithTagsCardsSection.cjs +1 -1
  96. package/dist/FieldOfInterestsWithTagsCardsSection.js +1 -1
  97. package/dist/FileInput.cjs +1 -1
  98. package/dist/FileInput.js +1 -1
  99. package/dist/FlexGridItem.cjs +1 -1
  100. package/dist/FlexGridItem.js +1 -1
  101. package/dist/FormField.cjs +1 -1
  102. package/dist/FormField.js +1 -1
  103. package/dist/FormView.cjs +1 -1
  104. package/dist/FormView.js +1 -1
  105. package/dist/GeneralWithTagsCardsSection.cjs +1 -1
  106. package/dist/GeneralWithTagsCardsSection.js +1 -1
  107. package/dist/GiftCardsSection.cjs +1 -1
  108. package/dist/GiftCardsSection.js +2 -2
  109. package/dist/Icon.cjs +1 -1
  110. package/dist/Icon.js +1 -1
  111. package/dist/IconButton.cjs +1 -1
  112. package/dist/IconButton.js +1 -1
  113. package/dist/Kanban.cjs +1 -1
  114. package/dist/Kanban.js +1 -1
  115. package/dist/KanbanActionsToolbar.cjs +1 -1
  116. package/dist/KanbanActionsToolbar.js +1 -1
  117. package/dist/KanbanView.cjs +1 -1
  118. package/dist/KanbanView.js +1 -1
  119. package/dist/Link.cjs +1 -1
  120. package/dist/Link.js +1 -1
  121. package/dist/LoanCalculatorSection.cjs +1 -1
  122. package/dist/LoanCalculatorSection.js +1 -1
  123. package/dist/LocationFinderSection.cjs +1 -1
  124. package/dist/LocationFinderSection.js +1 -1
  125. package/dist/LocationSearchSection.cjs +1 -1
  126. package/dist/LocationSearchSection.js +1 -1
  127. package/dist/MasonryGeneralCardsSection.cjs +1 -1
  128. package/dist/MasonryGeneralCardsSection.js +1 -1
  129. package/dist/MenuItem.cjs +1 -1
  130. package/dist/MenuItem.js +1 -1
  131. package/dist/Modal.cjs +1 -1
  132. package/dist/Modal.js +1 -1
  133. package/dist/MultiSelectDropdown.cjs +1 -1
  134. package/dist/MultiSelectDropdown.js +1 -1
  135. package/dist/MultiSelectDropdownLookup.cjs +1 -1
  136. package/dist/MultiSelectDropdownLookup.js +1 -1
  137. package/dist/NestedDropdownItem.cjs +1 -1
  138. package/dist/NestedDropdownItem.js +1 -1
  139. package/dist/NestedMenuItem.cjs +1 -1
  140. package/dist/NestedMenuItem.js +1 -1
  141. package/dist/NotificationContainer.cjs +1 -1
  142. package/dist/NotificationContainer.js +1 -1
  143. package/dist/NotificationMessage.cjs +1 -1
  144. package/dist/NotificationMessage.js +1 -1
  145. package/dist/NumberInput.cjs +1 -1
  146. package/dist/NumberInput.js +1 -1
  147. package/dist/OverlayGeneralCardsSection.cjs +1 -1
  148. package/dist/OverlayGeneralCardsSection.js +2 -2
  149. package/dist/PasswordInput.cjs +1 -1
  150. package/dist/PasswordInput.js +1 -1
  151. package/dist/PopoverContent.cjs +1 -1
  152. package/dist/PopoverContent.js +1 -1
  153. package/dist/ProductsWithBannerSection.cjs +1 -1
  154. package/dist/ProductsWithBannerSection.js +3 -3
  155. package/dist/ProgressBar.cjs +1 -1
  156. package/dist/ProgressBar.js +1 -1
  157. package/dist/QuattroCardsSection.cjs +1 -1
  158. package/dist/QuattroCardsSection.js +1 -1
  159. package/dist/QuizSection.cjs +1 -1
  160. package/dist/QuizSection.js +1 -1
  161. package/dist/RadioInput.cjs +1 -1
  162. package/dist/RadioInput.js +1 -1
  163. package/dist/RangeSlider.cjs +1 -1
  164. package/dist/RangeSlider.js +1 -1
  165. package/dist/ReviewsSection.cjs +1 -1
  166. package/dist/ReviewsSection.js +2 -2
  167. package/dist/SalesCampaignsSection.cjs +91 -164
  168. package/dist/SalesCampaignsSection.js +413 -657
  169. package/dist/Separator.cjs +1 -1
  170. package/dist/Separator.js +1 -1
  171. package/dist/ShopCardsSection.cjs +1 -1
  172. package/dist/ShopCardsSection.js +2 -2
  173. package/dist/Sidebar.cjs +1 -1
  174. package/dist/Sidebar.js +1 -1
  175. package/dist/SimpleCategoriesSection.cjs +1 -1
  176. package/dist/SimpleCategoriesSection.js +3 -3
  177. package/dist/SimpleProductsSection.cjs +1 -1
  178. package/dist/SimpleProductsSection.js +2 -2
  179. package/dist/Spinner.cjs +1 -1
  180. package/dist/Spinner.js +1 -1
  181. package/dist/Surface.cjs +1 -1
  182. package/dist/Surface.js +1 -1
  183. package/dist/SwipeableDrawer.cjs +1 -1
  184. package/dist/SwipeableDrawer.js +1 -1
  185. package/dist/TabItem.cjs +1 -1
  186. package/dist/TabItem.js +1 -1
  187. package/dist/Table.cjs +1 -1
  188. package/dist/Table.js +67 -67
  189. package/dist/TableView.cjs +1 -1
  190. package/dist/TableView.js +1 -1
  191. package/dist/TextAreaInput.cjs +1 -1
  192. package/dist/TextAreaInput.js +1 -1
  193. package/dist/TextInput.cjs +1 -1
  194. package/dist/TextInput.js +1 -1
  195. package/dist/ThemeProvider.cjs +1 -1
  196. package/dist/ThemeProvider.js +1 -1
  197. package/dist/TimeInput.cjs +1 -1
  198. package/dist/TimeInput.js +1 -1
  199. package/dist/Toggle.cjs +1 -1
  200. package/dist/Toggle.js +1 -1
  201. package/dist/TreeMenuSeparator.cjs +1 -1
  202. package/dist/TreeMenuSeparator.js +1 -1
  203. package/dist/UploadedFile.cjs +1 -1
  204. package/dist/UploadedFile.js +1 -1
  205. package/dist/UrgentSaleProductsSection.cjs +1 -1
  206. package/dist/UrgentSaleProductsSection.js +1 -1
  207. package/dist/index-BPgWhA1t.js +384 -0
  208. package/dist/{index-XrPpEvxt.cjs → index-BRgZcjpI.cjs} +1 -1
  209. package/dist/{index-DyMv0g-E.cjs → index-C4gGt12B.cjs} +1 -1
  210. package/dist/index-C_T-BQ5p.cjs +98 -0
  211. package/dist/{index-yrKiIPH4.js → index-Cru8Sd2q.js} +2 -2
  212. package/dist/{index-DQyZFR-C.js → index-D86vS9UF.js} +1 -1
  213. package/dist/{index-DkzN10w_.cjs → index-DMysapsB.cjs} +1 -1
  214. package/dist/{index-C1a0CtEE.cjs → index-DZDz9qZP.cjs} +1 -1
  215. package/dist/{index-DtlD7gBK.js → index-Dcw6ecHw.js} +2 -2
  216. package/dist/{index-4fcFA8kU.js → index-Kx8irvHH.js} +1 -1
  217. package/dist/index.cjs +1 -1
  218. package/dist/index.js +1 -1
  219. package/dist/{skeleton-DdxUz868.cjs → skeleton-BcaMeKFQ.cjs} +1 -1
  220. package/dist/{skeleton-DLOaT8ip.js → skeleton-BrUEdt6Z.js} +2 -2
  221. package/dist/{skeleton-C2HxO51q.cjs → skeleton-DwZzdFei.cjs} +1 -1
  222. package/dist/{skeleton-BSnQLxpv.js → skeleton-TrselJrj.js} +1 -1
  223. package/dist/{style-Ce-JyTaX.cjs → style-Bjk6yHcP.cjs} +1 -1
  224. package/dist/{style-DU0BlP5D.js → style-LEmcTrN9.js} +1 -1
  225. package/dist/{suspense-categories-card-simple-CkULM0Bi.cjs → suspense-categories-card-simple-B2swGa6t.cjs} +1 -1
  226. package/dist/{suspense-categories-card-simple-BKWKpuwr.js → suspense-categories-card-simple-BCn3U1cz.js} +1 -1
  227. package/dist/{suspense-large-ZUb9b6MG.cjs → suspense-large-DMhn-lIG.cjs} +1 -1
  228. package/dist/{suspense-large-C-YSgzDe.js → suspense-large-DgzTM-qh.js} +1 -1
  229. package/dist/{suspense-product-card-detailed-Bez9UFMR.js → suspense-product-card-detailed-BDkww9pS.js} +2 -2
  230. package/dist/{suspense-product-card-detailed-Yjo62f1v.cjs → suspense-product-card-detailed-BNOhu3Z4.cjs} +1 -1
  231. package/dist/{suspense-product-card-simple-CVbhvQWo.cjs → suspense-product-card-simple-BxDjW7gR.cjs} +1 -1
  232. package/dist/{suspense-product-card-simple-DF6bMLDk.js → suspense-product-card-simple-CQ1qPZOa.js} +1 -1
  233. package/dist/utils-BWzf4vLl.cjs +51 -0
  234. package/dist/{utils-WHYrEnYF.js → utils-BXCGNjIy.js} +52 -65
  235. package/package.json +1 -1
  236. package/dist/index-BKeVVABC.js +0 -345
  237. package/dist/index-CHDRU86t.cjs +0 -4
  238. package/dist/index-Ce6e4efi.cjs +0 -95
  239. package/dist/index-Dhf4jQmS.js +0 -47
  240. package/dist/utils-BOtq2mcF.cjs +0 -51
@@ -1,40 +1,16 @@
1
- import { jsx as t, jsxs as w, Fragment as G } from "react/jsx-runtime";
2
- import { useState as B, useEffect as U, useMemo as te, createElement as ce, forwardRef as V, useRef as Y, useImperativeHandle as de, Suspense as he, memo as ge } from "react";
3
- import { s as b } from "./emotion-styled.browser.esm-BNN1dTl3.js";
4
- import { z as fe, A as ue, B as pe, a as O, l as J, o as oe } from "./utils-WHYrEnYF.js";
5
- import { M as E } from "./consts-BuFChS64.js";
6
- import { m as me } from "./motion-Ckekul_K.js";
7
- import { P as i } from "./index-S5Cd7WrG.js";
8
- import we from "./Icon.js";
9
- import be from "./Badge.js";
10
- import { u as Z } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
11
- import { u as ie } from "./useDetectMobile-Bkvj0VMa.js";
12
- import ve from "./FlexBox.js";
13
- import { I as K } from "./index-Dhf4jQmS.js";
14
- import j from "./IconButton.js";
15
- var xe = function(e) {
16
- return e === void 0 && (e = { laptopL: 1440, laptop: 1024, tablet: 768 }), function() {
17
- var o = B(fe ? window.innerWidth : 0), a = o[0], s = o[1];
18
- U(function() {
19
- var n = function() {
20
- s(window.innerWidth);
21
- };
22
- return n(), ue(window, "resize", n), function() {
23
- pe(window, "resize", n);
24
- };
25
- });
26
- var u = te(function() {
27
- return Object.entries(e).sort(function(n, h) {
28
- return n[1] >= h[1] ? 1 : -1;
29
- });
30
- }, [e]), l = u.reduce(function(n, h) {
31
- var v = h[0], p = h[1];
32
- return a >= p ? v : n;
33
- }, u[0][0]);
34
- return l;
35
- };
36
- };
37
- const ye = b.div`
1
+ import { jsx as a, jsxs as f, Fragment as ae } from "react/jsx-runtime";
2
+ import { createElement as te, forwardRef as P, Suspense as oe, useState as E, useEffect as ne, memo as ie, useMemo as se } from "react";
3
+ import { s as d } from "./emotion-styled.browser.esm-BNN1dTl3.js";
4
+ import { a as N, o as G, k as O } from "./utils-BXCGNjIy.js";
5
+ import { M as k } from "./consts-BuFChS64.js";
6
+ import { m as Z } from "./motion-Ckekul_K.js";
7
+ import { P as n } from "./index-S5Cd7WrG.js";
8
+ import q from "./Icon.js";
9
+ import le from "./Badge.js";
10
+ import { u as A } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
11
+ import L from "./IconButton.js";
12
+ import { u as H } from "./useDetectMobile-Bkvj0VMa.js";
13
+ const ce = d.div`
38
14
  cursor: pointer;
39
15
  display: flex;
40
16
  gap: 1rem;
@@ -42,15 +18,15 @@ const ye = b.div`
42
18
  border-radius: 20px;
43
19
  border: 1px solid var(--gray-95008, #14161a14);
44
20
 
45
- @media (max-width: ${E + "px"}) {
21
+ @media (max-width: ${k + "px"}) {
46
22
  flex-direction: column;
47
23
  padding: 0;
48
24
  gap: 0;
49
25
  border: none;
50
26
  border-radius: 0;
51
27
  }
52
- `, $e = b.div`
53
- border-radius: ${(e) => O(e.theme, "edged")};
28
+ `, de = d.div`
29
+ border-radius: ${(e) => N(e.theme, "edged")};
54
30
  height: 15rem;
55
31
  width: 15rem;
56
32
  min-width: 15rem;
@@ -73,12 +49,12 @@ const ye = b.div`
73
49
  }
74
50
  }
75
51
 
76
- @media (max-width: ${E + "px"}) {
52
+ @media (max-width: ${k + "px"}) {
77
53
  width: 100%;
78
54
  max-width: 100dvh;
79
55
  height: 23.438rem;
80
56
  }
81
- `, De = b.div`
57
+ `, me = d.div`
82
58
  flex: 1;
83
59
  display: flex;
84
60
  flex-direction: column;
@@ -127,7 +103,7 @@ const ye = b.div`
127
103
  background-color: transparent;
128
104
  }
129
105
 
130
- @media (max-width: ${E + "px"}) {
106
+ @media (max-width: ${k + "px"}) {
131
107
  padding: 1.25rem;
132
108
 
133
109
  & .campaign-title {
@@ -141,7 +117,7 @@ const ye = b.div`
141
117
  gap: 0.25rem;
142
118
  }
143
119
  }
144
- `, ke = {
120
+ `, ge = {
145
121
  "#ADE3EB": "#76D0DB",
146
122
  "#DDD6FE": "#C4B5FD",
147
123
  "#FDE68A": "#FCD34D",
@@ -153,13 +129,13 @@ const ye = b.div`
153
129
  "#E7E5E4": "#D6D3D1",
154
130
  "#FED7AA": "#FDBA74",
155
131
  default: "#C4C8CF"
156
- }, Q = (e = !1, o = !1, a = !1) => `
132
+ }, W = (e = !1, t = !1, i = !1) => `
157
133
  display: flex;
158
- ${o ? "flex-wrap: wrap;" : ""}
159
- ${o ? "" : "flex-wrap: nowrap;"}
134
+ ${t ? "flex-wrap: wrap;" : ""}
135
+ ${t ? "" : "flex-wrap: nowrap;"}
160
136
  ${e ? "align-items: center;" : ""}
161
- ${a ? "justify-content: center;" : ""}
162
- `, Se = b(me.div)`
137
+ ${i ? "justify-content: center;" : ""}
138
+ `, he = d(Z.div)`
163
139
  text-decoration: none;
164
140
  ${(e) => e.hasPermission === !0 && "cursor: pointer"};
165
141
 
@@ -176,22 +152,22 @@ const ye = b.div`
176
152
  text-decoration: none;
177
153
  }
178
154
 
179
- ${Q(!0)}
155
+ ${W(!0)}
180
156
  gap: 0.5rem;
181
157
  padding: 0.5rem;
182
158
  color: ${(e) => e.isActive === !1 ? "var(--gray-900)" : "var(--primary-600)"};
183
159
  font-weight: 500;
184
160
  font-size: 0.875rem;
185
161
  line-height: 1.25rem;
186
- border-radius: ${(e) => O(e.theme, "slight")};
162
+ border-radius: ${(e) => N(e.theme, "slight")};
187
163
  transition: all 0.25s ease;
188
164
 
189
165
  & .logo-wrapper {
190
- ${Q(!0, !1, !0)}
166
+ ${W(!0, !1, !0)}
191
167
  flex-shrink: 0;
192
168
  border-radius: 999px;
193
169
  border: 3px solid
194
- ${(e) => e.isActive === !1 ? "var(--gray-300, #c4c8cf)" : ke[e.themeColor] ?? "var(--gray-300, #c4c8cf)"};
170
+ ${(e) => e.isActive === !1 ? "var(--gray-300, #c4c8cf)" : ge[e.themeColor] ?? "var(--gray-300, #c4c8cf)"};
195
171
 
196
172
  & img,
197
173
  .img-placeholder {
@@ -233,15 +209,15 @@ const ye = b.div`
233
209
  background-color: var(--gray-95080, #14161acc);
234
210
  color: var(--gray-600, #676e79);
235
211
  }
236
- `, Ce = b.div`
212
+ `, fe = d.div`
237
213
  position: absolute;
238
214
  top: 0.5rem;
239
215
  ${(e) => e.alignToLeft === !0 ? "left: 0.5rem;" : "right: 0.5rem;"}
240
216
  display: flex;
241
217
  gap: 0.25rem;
242
- `, Ne = (e) => `var(--${e}-700)`, Te = b.div`
243
- border-radius: ${(e) => O(e.theme, e.borderRadius || "slight")};
244
- background-color: ${(e) => Ne(e == null ? void 0 : e.color)};
218
+ `, ue = (e) => `var(--${e}-700)`, pe = d.div`
219
+ border-radius: ${(e) => N(e.theme, e.borderRadius || "slight")};
220
+ background-color: ${(e) => ue(e == null ? void 0 : e.color)};
245
221
  color: white;
246
222
  height: 1.5rem;
247
223
  min-width: 1.5rem;
@@ -255,70 +231,59 @@ const ye = b.div`
255
231
  & i {
256
232
  font-size: 0.813rem;
257
233
  }
258
- `, ne = (e) => {
234
+ `, J = (e) => {
259
235
  const {
260
- uuid: o,
261
- hasPermission: a = !0,
262
- isUser: s,
236
+ uuid: t,
237
+ hasPermission: i = !0,
238
+ isUser: h,
263
239
  image: u,
264
- name: l,
265
- notifications: n = 0,
266
- color: h = "primary",
267
- size: v = "large",
268
- style: p,
269
- disabled: y,
270
- onClick: c = () => {
240
+ name: m,
241
+ notifications: v = 0,
242
+ color: c = "primary",
243
+ size: w = "large",
244
+ style: s,
245
+ disabled: C,
246
+ onClick: l = () => {
271
247
  },
272
- isActive: $,
273
- className: m,
248
+ isActive: y,
249
+ className: p,
274
250
  // new
275
251
  themeData: x
276
- } = e, D = {
277
- theme: Z(),
278
- color: h,
279
- size: v,
280
- style: p,
281
- disabled: y
252
+ } = e, $ = {
253
+ theme: A(),
254
+ color: c,
255
+ size: w,
256
+ style: s,
257
+ disabled: C
282
258
  };
283
- return /* @__PURE__ */ ce(
284
- Se,
259
+ return /* @__PURE__ */ te(
260
+ he,
285
261
  {
286
- onClick: (k) => {
287
- k.stopPropagation(), a === !0 && (c == null || c());
288
- },
289
- ...D,
290
- key: l,
291
- animate: {
292
- y: 0,
293
- opacity: 1
262
+ onClick: (_) => {
263
+ _.stopPropagation(), i === !0 && (l == null || l());
294
264
  },
295
- className: `profile-item ${m}`,
296
- exit: {
297
- opacity: 0
298
- },
299
- hasPermission: a,
300
- initial: {
301
- y: -10,
302
- opacity: 0
303
- },
304
- isActive: $,
265
+ ...$,
266
+ key: m,
267
+ className: `profile-item ${p}`,
268
+ hasPermission: i,
269
+ isActive: y,
305
270
  themeColor: (x == null ? void 0 : x.code) || "transparent"
306
271
  },
307
- /* @__PURE__ */ t("div", { className: "logo-wrapper", children: u }),
308
- /* @__PURE__ */ t("div", { className: "name", children: l }),
309
- n > 0 && /* @__PURE__ */ t("div", { className: "notifications-number", children: /* @__PURE__ */ t(be, { className: "badge", color: "danger", size: "small", children: n > 99 ? "99+" : n }) })
272
+ /* @__PURE__ */ a("div", { className: "logo-wrapper", children: u }),
273
+ /* @__PURE__ */ a("div", { className: "name", children: m }),
274
+ v > 0 && /* @__PURE__ */ a("div", { className: "notifications-number", children: /* @__PURE__ */ a(le, { className: "badge", color: "danger", size: "small", children: v > 99 ? "99+" : v }) })
310
275
  );
311
276
  };
312
- ne.propTypes = {
313
- id: i.any,
314
- isUserProfile: i.bool,
315
- themeColor: i.string,
316
- image: i.any,
317
- name: i.string,
318
- notifications: i.number,
319
- style: i.object,
320
- className: i.string,
321
- color: i.oneOf([
277
+ J.propTypes = {
278
+ id: n.any,
279
+ isUserProfile: n.bool,
280
+ themeColor: n.string,
281
+ image: n.any,
282
+ name: n.string,
283
+ notifications: n.number,
284
+ style: n.object,
285
+ className: n.string,
286
+ color: n.oneOf([
322
287
  "primary",
323
288
  "secondary",
324
289
  "success",
@@ -327,91 +292,91 @@ ne.propTypes = {
327
292
  "information",
328
293
  "neutral"
329
294
  ]),
330
- size: i.oneOf(["large"]),
331
- onSelect: i.func,
332
- hasPermission: i.bool
295
+ size: n.oneOf(["large"]),
296
+ onSelect: n.func,
297
+ hasPermission: n.bool
333
298
  };
334
- const ee = (e, o) => {
335
- if (!e || !o) return null;
336
- let a = Math.floor((e == null ? void 0 : e.getTime()) - (o == null ? void 0 : o.getTime())), s = 1e3 * 60 * 60 * 24;
337
- return Math.ceil(a / s);
338
- }, ae = V((e, o) => {
339
- const a = Z(), {
340
- uuid: s,
299
+ const V = (e, t) => {
300
+ if (!e || !t) return null;
301
+ let i = Math.floor((e == null ? void 0 : e.getTime()) - (t == null ? void 0 : t.getTime())), h = 1e3 * 60 * 60 * 24;
302
+ return Math.ceil(i / h);
303
+ }, K = P((e, t) => {
304
+ const i = A(), {
305
+ uuid: h,
341
306
  shopUuid: u,
342
- title: l = "",
343
- description: n,
344
- badges: h,
345
- coverPhoto: v,
346
- onSelect: p,
347
- status: y,
348
- startDate: c,
349
- endDate: $,
350
- salesPackages: m,
307
+ title: m = "",
308
+ description: v,
309
+ badges: c,
310
+ coverPhoto: w,
311
+ onSelect: s,
312
+ status: C,
313
+ startDate: l,
314
+ endDate: y,
315
+ salesPackages: p,
351
316
  shopName: x,
352
- shopImage: g,
353
- className: D,
354
- onSelectCard: k = () => {
317
+ shopImage: b,
318
+ className: $,
319
+ onSelectCard: _ = () => {
355
320
  },
356
- onSelectShop: I = () => {
321
+ onSelectShop: S = () => {
357
322
  },
358
- campaignSingleText: P,
359
- salesCampaignTypes: S = [],
360
- startsInPrefixTextPlural: d,
361
- startsinSuffixTextPlural: T,
362
- startsInPrefixTextSingular: C,
363
- startsinSuffixTextSingular: r,
364
- themeData: _,
365
- ...X
366
- } = e, M = c ? new Date(c) <= /* @__PURE__ */ new Date() : !1;
367
- ee(
368
- $ ? new Date($) : null,
369
- c ? new Date(c) : null
323
+ campaignSingleText: D,
324
+ salesCampaignTypes: r = [],
325
+ startsInPrefixTextPlural: T,
326
+ startsinSuffixTextPlural: B,
327
+ startsInPrefixTextSingular: M,
328
+ startsinSuffixTextSingular: o,
329
+ themeData: g,
330
+ ...Y
331
+ } = e, ee = l ? new Date(l) <= /* @__PURE__ */ new Date() : !1;
332
+ V(
333
+ y ? new Date(y) : null,
334
+ l ? new Date(l) : null
370
335
  );
371
- const f = ee(
372
- c ? new Date(c) : null,
336
+ const I = V(
337
+ l ? new Date(l) : null,
373
338
  /* @__PURE__ */ new Date()
374
339
  );
375
- return /* @__PURE__ */ w(
376
- ye,
340
+ return /* @__PURE__ */ f(
341
+ ce,
377
342
  {
378
- ref: o,
379
- theme: a,
380
- className: D,
381
- onClick: k,
382
- ...X,
343
+ ref: t,
344
+ theme: i,
345
+ className: $,
346
+ onClick: _,
347
+ ...Y,
383
348
  children: [
384
- /* @__PURE__ */ w($e, { theme: a, onClick: () => p == null ? void 0 : p(), children: [
385
- /* @__PURE__ */ t("img", { src: v }),
386
- /* @__PURE__ */ t(Ce, { children: m == null ? void 0 : m.map((N, z) => {
387
- var F, R;
388
- return /* @__PURE__ */ t(
389
- Te,
349
+ /* @__PURE__ */ f(de, { theme: i, onClick: () => s == null ? void 0 : s(), children: [
350
+ /* @__PURE__ */ a("img", { src: w }),
351
+ /* @__PURE__ */ a(fe, { children: p == null ? void 0 : p.map((U, re) => {
352
+ var R, j;
353
+ return /* @__PURE__ */ a(
354
+ pe,
390
355
  {
391
- color: (F = S == null ? void 0 : S.find((L) => L.value === N)) == null ? void 0 : F.color,
392
- theme: a,
393
- children: /* @__PURE__ */ t(
394
- we,
356
+ color: (R = r == null ? void 0 : r.find((z) => z.value === U)) == null ? void 0 : R.color,
357
+ theme: i,
358
+ children: /* @__PURE__ */ a(
359
+ q,
395
360
  {
396
- icon: (R = S == null ? void 0 : S.find((L) => L.value === N)) == null ? void 0 : R.icon
361
+ icon: (j = r == null ? void 0 : r.find((z) => z.value === U)) == null ? void 0 : j.icon
397
362
  }
398
363
  )
399
364
  },
400
- `package__${z}`
365
+ `package__${re}`
401
366
  );
402
367
  }) })
403
368
  ] }),
404
- /* @__PURE__ */ w(De, { theme: a, children: [
405
- /* @__PURE__ */ w("div", { className: "text-block-wrapper", children: [
406
- /* @__PURE__ */ w("div", { className: "title-block-wrapper", children: [
407
- /* @__PURE__ */ t("div", { className: "campaign-title", children: P }),
408
- /* @__PURE__ */ t("div", { className: "campaign-title-text", children: l }),
409
- /* @__PURE__ */ t("div", { className: "timestamp-text", children: M ? "" : f === 1 ? `${C} ${f} ${r}` : `${d} ${f} ${T}` })
369
+ /* @__PURE__ */ f(me, { theme: i, children: [
370
+ /* @__PURE__ */ f("div", { className: "text-block-wrapper", children: [
371
+ /* @__PURE__ */ f("div", { className: "title-block-wrapper", children: [
372
+ /* @__PURE__ */ a("div", { className: "campaign-title", children: D }),
373
+ /* @__PURE__ */ a("div", { className: "campaign-title-text", children: m }),
374
+ /* @__PURE__ */ a("div", { className: "timestamp-text", children: ee ? "" : I === 1 ? `${M} ${I} ${o}` : `${T} ${I} ${B}` })
410
375
  ] }),
411
- /* @__PURE__ */ t("div", { children: n })
376
+ /* @__PURE__ */ a("div", { children: v })
412
377
  ] }),
413
- /* @__PURE__ */ t(
414
- ne,
378
+ /* @__PURE__ */ a(
379
+ J,
415
380
  {
416
381
  hasPermission: !0,
417
382
  image: (
@@ -421,19 +386,19 @@ const ee = (e, o) => {
421
386
  // size={ImageSize.SMALL}
422
387
  // className={`${shopImage ? "" : "no-image"}`}
423
388
  // />
424
- /* @__PURE__ */ t(
389
+ /* @__PURE__ */ a(
425
390
  "img",
426
391
  {
427
- src: g,
428
- className: `${g ? "" : "no-image"}`
392
+ src: b,
393
+ className: `${b ? "" : "no-image"}`
429
394
  }
430
395
  )
431
396
  ),
432
- themeData: _,
397
+ themeData: g,
433
398
  isActive: !0,
434
399
  isUser: !1,
435
400
  name: x,
436
- onClick: () => I(u)
401
+ onClick: () => S(u)
437
402
  }
438
403
  )
439
404
  ] })
@@ -441,363 +406,13 @@ const ee = (e, o) => {
441
406
  }
442
407
  );
443
408
  });
444
- ae.propTypes = {
445
- title: i.oneOfType([i.string, i.element]),
446
- numberOfListings: i.number,
447
- dropdown: i.any,
448
- color: i.string
449
- };
450
- const Ae = b.div`
451
- display: flex;
452
- flex-direction: column;
453
- gap: 1.5rem;
454
- position: relative;
455
-
456
- & .hover-left-arrow {
457
- display: none;
458
- position: absolute;
459
- top: 50%;
460
- left: 1.5rem;
461
- z-index: ${(e) => J(e.arrowsZIndex) ? e.arrowsZIndex : 20};
462
- }
463
-
464
- & .hover-right-arrow {
465
- display: none;
466
- position: absolute;
467
- top: 50%;
468
- right: 1.5rem;
469
- z-index: ${(e) => J(e.arrowsZIndex) ? e.arrowsZIndex : 20};
470
- }
471
-
472
- & .clip-loader-wrapper {
473
- margin: auto;
474
- padding: 0 1rem;
475
- }
476
-
477
- @media (max-width: ${E + "px"}) {
478
- gap: 1.25rem;
479
- & .hover-left-arrow,
480
- .hover-right-arrow {
481
- display: flex;
482
- }
483
- }
484
- `, _e = b.div`
485
- display: flex;
486
- align-items: center;
487
-
488
- justify-content: space-between;
489
- gap: 1rem;
490
-
491
- font-weight: 600;
492
- font-size: 1.5rem;
493
-
494
- & .btns-group {
495
- display: flex;
496
- gap: 0.375rem;
497
- }
498
-
499
- @media (max-width: ${E + "px"}) {
500
- padding: 0 1rem;
501
- & .btns-group {
502
- display: none;
503
- }
504
- }
505
- `, Fe = b.div`
506
- position: relative;
507
- padding: ${(e) => e.padding};
508
-
509
- & button {
510
- white-space: nowrap;
511
- }
512
-
513
- & .badge-button {
514
- ${(e) => e.showTimesBtn === !0 && "padding-left: 0.5rem; padding-right: 0.5rem;"}
515
- }
516
-
517
- & .gradient {
518
- position: absolute;
519
- top: 50%;
520
- transform: translate(0, -50%);
521
- z-index: 4;
522
- transition: ${"0.3s"};
523
- right: ${(e) => e.noArrows !== !0 ? "6rem" : "0"};
524
- width: 2rem;
525
- background: #fff;
526
- height: 100%;
527
- -webkit-mask-image: linear-gradient(to left, black 10%, transparent 50%);
528
- mask-image: linear-gradient(to left, black 10%, transparent 50%);
529
- }
530
-
531
- & .scrollable-container {
532
- scroll-behavior: smooth;
533
- overflow: hidden;
534
- -webkit-overflow-scrolling: touch;
535
- ::-webkit-scrollbar {
536
- -webkit-appearance: none;
537
- }
538
- -ms-overflow-style: none;
539
- /* Internet Explorer 10+ */
540
- scrollbar-width: none;
541
- /* Firefox */
542
-
543
- &::-webkit-scrollbar {
544
- display: none;
545
- /* Safari and Chrome */
546
- }
547
- }
548
- & .scroll-arrow-right,
549
- & .scroll-arrow-left {
550
- position: absolute;
551
- top: 50%;
552
- transform: translate(0, -50%);
553
- display: flex;
554
- justify-content: center;
555
- align-items: center;
556
- cursor: pointer;
557
-
558
- visibility: ${(e) => e.arrowsVisibleOnHover === !1 && e.hasOverflow ? "visible" : "hidden"};
559
- z-index: 4;
560
- transition: ${"0.3s"};
561
- }
562
- & .scroll-arrow-right {
563
- ${(e) => e.rightAlignArrows === !0 ? "right: 0" : "right: 0.7rem"};
564
- }
565
- & .scroll-arrow-left {
566
- ${(e) => e.rightAlignArrows === !0 ? "right: 2.625rem" : "left: 0.7rem"};
567
- }
568
- & .scrollable-container:hover > .scroll-arrow-left,
569
- & .scrollable-container:hover > .scroll-arrow-right {
570
- visibility: ${(e) => e.hasOverflow ? "visible" : "hidden"};
571
- }
572
-
573
- @media (max-width: ${E + "px"}) {
574
- & .scroll-arrow-left,
575
- & .scroll-arrow-right {
576
- display: none;
577
- }
578
-
579
- & .gradient {
580
- right: 0;
581
- }
582
- }
583
- `, Be = (e, o) => {
584
- const [a, s] = B({
585
- trigger: null,
586
- direction: null
587
- }), u = (l) => l.touches || l.originalEvent.touches;
588
- return U(() => {
589
- const l = typeof e == "string" || e instanceof String ? document.getElementById(e) : e.current;
590
- let n = null, h = null;
591
- if (l) {
592
- const v = (y) => {
593
- const c = u(y)[0];
594
- n = c.clientX, h = c.clientY;
595
- }, p = (y) => {
596
- if (!n || !h)
597
- return;
598
- const c = y.touches[0].clientX, $ = y.touches[0].clientY, m = n - c, x = h - $;
599
- Math.abs(m) > Math.abs(x) ? m > 0 ? s((g) => ({
600
- trigger: !g.trigger,
601
- direction: W.LEFT
602
- })) : s((g) => ({
603
- trigger: !g.trigger,
604
- direction: W.RIGHT
605
- })) : x > 0 ? s((g) => ({
606
- trigger: !g.trigger,
607
- direction: W.UP
608
- })) : s((g) => ({
609
- trigger: !g.trigger,
610
- direction: W.DOWN
611
- })), n = null, h = null;
612
- };
613
- return l.addEventListener("touchstart", v), l.addEventListener("touchmove", p), () => {
614
- l.removeEventListener("touchstart", v), l.addEventListener("touchmove", p);
615
- };
616
- }
617
- }, []), a;
618
- }, W = {
619
- UP: "up",
620
- DOWN: "down",
621
- RIGHT: "right",
622
- LEFT: "left"
623
- }, se = V(
624
- ({
625
- title: e,
626
- columnGap: o = "2rem",
627
- rowGap: a = "1.25rem",
628
- scrollBySize: s = 300,
629
- wrapForMobile: u = !1,
630
- wrap: l = !1,
631
- children: n,
632
- methodsRef: h,
633
- arrowsVisibleOnHover: v = !0,
634
- rightAlignArrows: p = !1,
635
- padding: y = "0",
636
- showTimesBtn: c,
637
- noArrows: $,
638
- onShowEnd: m,
639
- arrowsZIndex: x,
640
- showArrows: g,
641
- elementsCount: D,
642
- minElementsCount: k = 2,
643
- ...I
644
- }, P) => {
645
- const S = ie(), d = Z(), [T, C] = B(
646
- D < k
647
- ), [r, _] = B(!1), [X, M] = B(!0), f = Y(), N = Be(f);
648
- U(() => {
649
- (N == null ? void 0 : N.direction) === W.RIGHT && r !== !0 ? F() : (N == null ? void 0 : N.direction) === W.LEFT && T !== !0 && z();
650
- }, [N]);
651
- const z = () => {
652
- var A;
653
- (A = f.current) == null || A.scrollBy(s, 0);
654
- }, F = () => {
655
- var A;
656
- (A = f.current) == null || A.scrollBy(-s, 0);
657
- }, [R, L] = B(!1);
658
- U(() => {
659
- var A, q;
660
- L(
661
- ((A = f == null ? void 0 : f.current) == null ? void 0 : A.scrollWidth) > ((q = f == null ? void 0 : f.current) == null ? void 0 : q.clientWidth)
662
- );
663
- }, [n]), de(h, () => ({
664
- scrollToEnd() {
665
- le();
666
- },
667
- scrollLeft() {
668
- F();
669
- },
670
- scrollRight() {
671
- z();
672
- }
673
- }));
674
- const le = () => {
675
- f.current.scrollLeft = f.current.scrollWidth;
676
- };
677
- return /* @__PURE__ */ w(Ae, { arrowsZIndex: x, children: [
678
- /* @__PURE__ */ w(_e, { children: [
679
- /* @__PURE__ */ t("div", { children: e }),
680
- g && /* @__PURE__ */ w("div", { className: "btns-group", children: [
681
- /* @__PURE__ */ t(
682
- j,
683
- {
684
- borderRadius: "curved",
685
- btnType: "tinted",
686
- className: "scroll-arrow-left",
687
- color: "neutral",
688
- disabled: r,
689
- icon: "angle-left",
690
- onClick: F
691
- }
692
- ),
693
- /* @__PURE__ */ t(
694
- j,
695
- {
696
- borderRadius: "curved",
697
- btnType: "tinted",
698
- className: "scroll-arrow-right",
699
- color: "neutral",
700
- disabled: T,
701
- icon: "angle-right",
702
- onClick: z
703
- }
704
- )
705
- ] })
706
- ] }),
707
- g && /* @__PURE__ */ w(G, { children: [
708
- /* @__PURE__ */ t(
709
- j,
710
- {
711
- borderRadius: "curved",
712
- btnType: "tinted",
713
- className: "hover-left-arrow scroll-arrow-left",
714
- color: "neutral",
715
- disabled: r,
716
- icon: "angle-left",
717
- onClick: F
718
- }
719
- ),
720
- /* @__PURE__ */ t(
721
- j,
722
- {
723
- borderRadius: "curved",
724
- btnType: "tinted",
725
- className: "hover-right-arrow scroll-arrow-right",
726
- color: "neutral",
727
- disabled: T,
728
- icon: "angle-right",
729
- onClick: z
730
- }
731
- )
732
- ] }),
733
- /* @__PURE__ */ t(
734
- Fe,
735
- {
736
- ref: P,
737
- arrowsVisibleOnHover: v,
738
- hasOverflow: R,
739
- noArrows: $,
740
- padding: y,
741
- rightAlignArrows: p,
742
- showTimesBtn: c,
743
- theme: d,
744
- ...I,
745
- children: /* @__PURE__ */ w(
746
- ve,
747
- {
748
- ref: f,
749
- className: "scrollable-container",
750
- columnGap: o,
751
- rowGap: a,
752
- wrap: l || u && S ? "Wrap" : "NoWrap",
753
- children: [
754
- /* @__PURE__ */ t(
755
- K,
756
- {
757
- isHorizontal: !0,
758
- onIsNotVisible: () => {
759
- r === !0 && _(!1);
760
- },
761
- onIsVisible: () => {
762
- r === !1 && _(!0);
763
- }
764
- }
765
- ),
766
- n,
767
- /* @__PURE__ */ t(
768
- K,
769
- {
770
- isHorizontal: !0,
771
- onIsNotVisible: () => {
772
- T === !0 && C(!1), M(!0);
773
- },
774
- onIsVisible: () => {
775
- T === !1 && C(!0), M(!1), m == null || m();
776
- }
777
- }
778
- ),
779
- X && R && /* @__PURE__ */ t("div", { className: "gradient" })
780
- ]
781
- }
782
- )
783
- }
784
- )
785
- ] });
786
- }
787
- );
788
- se.propTypes = {
789
- title: i.string,
790
- rowGap: i.string,
791
- columnGap: i.string,
792
- scrollBySize: i.number,
793
- wrapForMobile: i.bool,
794
- wrap: i.bool,
795
- methodsRef: i.any,
796
- arrowsVisibleOnHover: i.bool,
797
- rightAlignArrows: i.bool,
798
- padding: i.string
409
+ K.propTypes = {
410
+ title: n.oneOfType([n.string, n.element]),
411
+ numberOfListings: n.number,
412
+ dropdown: n.any,
413
+ color: n.string
799
414
  };
800
- const Ee = b.div`
415
+ d.div`
801
416
  display: flex;
802
417
  flex-direction: column;
803
418
  gap: 1.5rem;
@@ -828,26 +443,27 @@ const Ee = b.div`
828
443
  }
829
444
  }
830
445
 
831
- @media (max-width: ${E + "px"}) {
446
+ @media (max-width: ${k + "px"}) {
832
447
  & .campaign-item {
833
448
  min-width: 100%;
834
449
  width: 100%;
835
450
  margin-right: 0;
836
451
  }
837
452
  }
838
- `, H = b.div`
453
+ `;
454
+ const F = d.div`
839
455
  width: ${(e) => e.width || "100%"};
840
456
  height: ${(e) => (e.heightCoeff || 1) * 1.125}rem;
841
457
  background-color: var(--gray-200, #dddfe4);
842
458
 
843
- ${oe("-90deg")}
844
- `, Ie = b.div`
459
+ ${G("-90deg")}
460
+ `, xe = d.div`
845
461
  display: flex;
846
462
  flex-direction: ${(e) => e != null && e.row ? "row" : "column"};
847
463
  gap: ${(e) => (e == null ? void 0 : e.gap) ?? "0.5rem"};
848
464
  width: ${(e) => (e == null ? void 0 : e.width) ?? "100%"};
849
- `, re = b.div`
850
- border-radius: ${(e) => O(e.theme, (e == null ? void 0 : e.borderRadius) ?? "regular")};
465
+ `, X = d.div`
466
+ border-radius: ${(e) => N(e.theme, (e == null ? void 0 : e.borderRadius) ?? "regular")};
851
467
  background: var(--gray-200, #dddfe4);
852
468
  position: relative;
853
469
  max-height: ${(e) => (e == null ? void 0 : e.height) ?? "5rem"};
@@ -856,10 +472,10 @@ const Ee = b.div`
856
472
  width: ${(e) => (e == null ? void 0 : e.width) ?? "5rem"};
857
473
  flex-shrink: 0;
858
474
 
859
- ${oe()}
860
- `, Pe = b.div`
475
+ ${G()}
476
+ `, ve = d.div`
861
477
  background: var(--white, #fff);
862
- border-radius: ${(e) => O(e.theme, "edged")};
478
+ border-radius: ${(e) => N(e.theme, "edged")};
863
479
  box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1), 0px 1px 2px rgba(0, 0, 0, 0.06);
864
480
  border: 1px solid var(--gray-95012, #14161a1f);
865
481
 
@@ -885,148 +501,288 @@ const Ee = b.div`
885
501
  align-items: center;
886
502
  gap: 0.5rem;
887
503
  }
888
- `, ze = V(({}, e) => {
889
- const o = Z();
890
- return /* @__PURE__ */ w(Pe, { ref: e, theme: o, children: [
891
- /* @__PURE__ */ t("div", { className: "campaign__left-section", children: /* @__PURE__ */ t(
892
- re,
504
+
505
+ @media (max-width: ${k + "px"}) {
506
+ flex-direction: column;
507
+
508
+ & .campaign__user {
509
+ margin-top: 1rem;
510
+ }
511
+ }
512
+ `, be = d.div`
513
+ display: flex;
514
+ gap: 1.5rem;
515
+ `, we = P(({}, e) => {
516
+ const t = A();
517
+ return /* @__PURE__ */ f(ve, { ref: e, theme: t, children: [
518
+ /* @__PURE__ */ a("div", { className: "campaign__left-section", children: /* @__PURE__ */ a(
519
+ X,
893
520
  {
894
- theme: o,
521
+ theme: t,
895
522
  width: "15rem",
896
523
  height: "15rem",
897
524
  borderRadius: "edged"
898
525
  }
899
526
  ) }),
900
- /* @__PURE__ */ w("div", { className: "campaign__right-section", children: [
901
- /* @__PURE__ */ w(Ie, { theme: o, children: [
902
- /* @__PURE__ */ t(H, { heightCoeff: 0.75, theme: o, width: "35%" }),
903
- /* @__PURE__ */ t(H, { heightCoeff: 1.25, theme: o }),
904
- /* @__PURE__ */ t(H, { heightCoeff: 3, theme: o })
527
+ /* @__PURE__ */ f("div", { className: "campaign__right-section", children: [
528
+ /* @__PURE__ */ f(xe, { theme: t, children: [
529
+ /* @__PURE__ */ a(F, { heightCoeff: 0.75, theme: t, width: "35%" }),
530
+ /* @__PURE__ */ a(F, { heightCoeff: 1.25, theme: t }),
531
+ /* @__PURE__ */ a(F, { heightCoeff: 3, theme: t })
905
532
  ] }),
906
- /* @__PURE__ */ w("div", { className: "campaign__user", children: [
907
- /* @__PURE__ */ t(
908
- re,
533
+ /* @__PURE__ */ f("div", { className: "campaign__user", children: [
534
+ /* @__PURE__ */ a(
535
+ X,
909
536
  {
910
- theme: o,
537
+ theme: t,
911
538
  width: "2.5rem",
912
539
  height: "2.5rem",
913
540
  borderRadius: "curved"
914
541
  }
915
542
  ),
916
- /* @__PURE__ */ t(H, { theme: o, width: "75%" })
543
+ /* @__PURE__ */ a(F, { theme: t, width: "75%" })
917
544
  ] })
918
545
  ] })
919
546
  ] });
920
- }), We = ({ itemsCount: e = 5, keyPrefix: o }) => /* @__PURE__ */ t(G, { children: Array.from({ length: e }, (a, s) => /* @__PURE__ */ t(
921
- ze,
547
+ }), ye = ({ itemsCount: e = 5, keyPrefix: t }) => /* @__PURE__ */ a(be, { children: Array.from({ length: e }, (i, h) => /* @__PURE__ */ a(
548
+ we,
922
549
  {},
923
- `${o}-skeleton-campaign-card-${s}`
924
- )) }), Re = ({
550
+ `${t}-skeleton-campaign-card-${h}`
551
+ )) }), $e = ({
925
552
  children: e,
926
- fallbackComponent: o = /* @__PURE__ */ t(G, {}),
927
- isLoading: a = !1,
928
- itemsCount: s = 5,
553
+ fallbackComponent: t = /* @__PURE__ */ a(ae, {}),
554
+ isLoading: i = !1,
555
+ itemsCount: h = 5,
929
556
  keyPrefix: u
930
- }) => /* @__PURE__ */ t(he, { fallback: o, children: a === !0 ? /* @__PURE__ */ t(We, { itemsCount: s, keyPrefix: u }) : e }), Le = xe(), Ue = ge(ae), rr = V(
557
+ }) => /* @__PURE__ */ a(oe, { fallback: t, children: i === !0 ? /* @__PURE__ */ a(ye, { itemsCount: h, keyPrefix: u }) : e }), _e = d.div`
558
+ margin: 0 auto;
559
+ display: flex;
560
+ flex-direction: column;
561
+ align-items: flex-start;
562
+ gap: 1.5rem;
563
+ align-self: stretch;
564
+ position: relative;
565
+
566
+ & .scrollable-section__header {
567
+ display: flex;
568
+ justify-content: space-between;
569
+ align-items: center;
570
+ align-self: stretch;
571
+
572
+ & .scrollable-section__title {
573
+ display: flex;
574
+ align-items: center;
575
+ gap: 0.5rem;
576
+
577
+ & .title__icon {
578
+ }
579
+
580
+ & .title__text {
581
+ color: var(--gray-950, #14161a);
582
+ font-size: 1.5rem;
583
+ font-style: normal;
584
+ font-weight: 600;
585
+ line-height: 2rem;
586
+ }
587
+ }
588
+ }
589
+
590
+ & .scrollable-section__navigation {
591
+ display: flex;
592
+ align-items: flex-start;
593
+ gap: 0.5rem;
594
+ position: absolute;
595
+ top: 0;
596
+ right: 0;
597
+ }
598
+ `, Ce = d(Z.div)`
599
+ display: grid;
600
+ grid-template-columns: repeat(${(e) => e == null ? void 0 : e.numOfColumns}, 1fr);
601
+ gap: 1.5rem;
602
+
603
+ @media (max-width: ${k + "px"}) {
604
+ grid-template-columns: repeat(${(e) => e == null ? void 0 : e.numOfColumnsForMobile}, 1fr);
605
+ }
606
+ `, Q = P(
607
+ ({
608
+ icon: e,
609
+ title: t,
610
+ numOfSlides: i = 2,
611
+ numOfSlidesForMobile: h = 1,
612
+ showNavigation: u = !0,
613
+ children: m
614
+ }, v) => {
615
+ const [c, w] = E(0), [s, C] = E(1), [l, y] = E(null), [p, x] = E(null), b = H(), $ = 50, _ = (m == null ? void 0 : m.length) ?? 1;
616
+ ne(() => {
617
+ const o = () => {
618
+ C(b ? h : i);
619
+ };
620
+ return window.addEventListener("resize", o), o(), () => window.removeEventListener("resize", o);
621
+ }, []);
622
+ const S = m == null ? void 0 : m.slice(c, c + s), D = (o) => {
623
+ var g;
624
+ (g = o == null ? void 0 : o.target) == null || g.blur(), c + s < _ && w(c + s);
625
+ }, r = (o) => {
626
+ var g;
627
+ (g = o == null ? void 0 : o.target) == null || g.blur(), c - s >= 0 && w(c - s);
628
+ };
629
+ return /* @__PURE__ */ f(
630
+ _e,
631
+ {
632
+ ref: v,
633
+ ...b ? { onTouchStart: (o) => {
634
+ var g;
635
+ x(null), y((g = o == null ? void 0 : o.targetTouches["0"]) == null ? void 0 : g.clientX);
636
+ }, onTouchMove: (o) => {
637
+ var g;
638
+ x((g = o == null ? void 0 : o.targetTouches["0"]) == null ? void 0 : g.clientX);
639
+ }, onTouchEnd: () => {
640
+ if (!l || !p) return;
641
+ const o = l - p;
642
+ o > $ && D(), o < -$ && r();
643
+ } } : {},
644
+ children: [
645
+ /* @__PURE__ */ a("div", { className: "scrollable-section__header", children: /* @__PURE__ */ f("div", { className: "scrollable-section__title", children: [
646
+ O(e) && /* @__PURE__ */ a(
647
+ q,
648
+ {
649
+ icon: e,
650
+ color: "primary",
651
+ sizeInUnits: "1.5rem",
652
+ className: "title__icon"
653
+ }
654
+ ),
655
+ O(t) && /* @__PURE__ */ a("div", { className: "title__text", children: t })
656
+ ] }) }),
657
+ /* @__PURE__ */ a(
658
+ Ce,
659
+ {
660
+ numOfColumns: i,
661
+ numOfColumnsForMobile: h,
662
+ animate: {
663
+ x: 0,
664
+ opacity: 1
665
+ },
666
+ initial: {
667
+ x: 10,
668
+ opacity: 0
669
+ },
670
+ children: S
671
+ },
672
+ `scrollable-section__content-${c}`
673
+ ),
674
+ u && _ > s && !b && /* @__PURE__ */ f("div", { className: "scrollable-section__navigation", children: [
675
+ /* @__PURE__ */ a(
676
+ L,
677
+ {
678
+ icon: "angle-left",
679
+ borderRadius: "curved",
680
+ btnType: "tinted",
681
+ color: "neutral",
682
+ className: "navigation__arrow",
683
+ disabled: c === 0,
684
+ onClick: r
685
+ }
686
+ ),
687
+ /* @__PURE__ */ a(
688
+ L,
689
+ {
690
+ icon: "angle-right",
691
+ borderRadius: "curved",
692
+ btnType: "tinted",
693
+ color: "neutral",
694
+ className: "navigation__arrow",
695
+ disabled: c + s >= _,
696
+ onClick: D
697
+ }
698
+ )
699
+ ] })
700
+ ]
701
+ }
702
+ );
703
+ }
704
+ );
705
+ Q.propTypes = {
706
+ icon: n.string,
707
+ title: n.string,
708
+ numOfSlides: n.number,
709
+ numOfSlidesForMobile: n.number,
710
+ showNavigation: n.bool
711
+ };
712
+ const De = ie(K), Ue = P(
931
713
  ({
932
714
  sellerType: e = "Shop",
933
- items: o = [],
934
- title: a,
935
- isLoading: s,
936
- onSelectCard: u = () => {
715
+ items: t = [],
716
+ title: i,
717
+ icon: h,
718
+ isLoading: u,
719
+ onSelectCard: m = () => {
937
720
  },
938
- onSelectShop: l = () => {
721
+ onSelectShop: v = () => {
939
722
  },
940
- getImage: n = () => {
723
+ getImage: c = () => {
941
724
  },
942
- // new
943
- customScrollSize: h,
944
- campaignSingleText: v,
945
- salesCampaignTypes: p = [],
946
- startsInPrefixTextPlural: y,
947
- startsinSuffixTextPlural: c,
948
- startsInPrefixTextSingular: $,
949
- startsinSuffixTextSingular: m
950
- }, x) => {
951
- const g = Y(), D = Y(), k = Le(), I = ie(), [P, S] = B(0), d = te(() => {
952
- var C;
953
- return (C = o == null ? void 0 : o.slice(0, 6)) == null ? void 0 : C.map((r, _) => /* @__PURE__ */ t(
954
- Ue,
955
- {
956
- className: "campaign-item",
957
- ref: _ === 0 ? D : null,
958
- coverPhoto: n(
959
- r == null ? void 0 : r.coverPhoto,
960
- (r == null ? void 0 : r.uuid) || (r == null ? void 0 : r.campaignUuid)
961
- ),
962
- description: r == null ? void 0 : r.description,
963
- endDate: r == null ? void 0 : r.endDate,
964
- salesPackages: r == null ? void 0 : r.salesPackages,
965
- sellerType: e,
966
- shopImage: r == null ? void 0 : r.profileImage,
967
- shopName: r == null ? void 0 : r.shopName,
968
- shopUuid: r == null ? void 0 : r.shopUuid,
969
- startDate: r == null ? void 0 : r.startDate,
970
- title: r == null ? void 0 : r.name,
971
- uuid: r == null ? void 0 : r.campaignUuid,
972
- onSelectCard: () => u(r == null ? void 0 : r.campaignUuid, r == null ? void 0 : r.shopUuid),
973
- onSelectShop: () => l(r == null ? void 0 : r.shopUuid),
974
- campaignSingleText: v,
975
- salesCampaignTypes: p,
976
- startsInPrefixTextPlural: y,
977
- startsinSuffixTextPlural: c,
978
- startsInPrefixTextSingular: $,
979
- startsinSuffixTextSingular: m,
980
- themeData: r == null ? void 0 : r.themeData
981
- },
982
- `campaign__item__${_}__${r == null ? void 0 : r.startDate}___${r == null ? void 0 : r.endDate}__${k}`
983
- ));
984
- }, [k, o]);
985
- U(() => {
986
- var C;
987
- S(h ?? ((C = D == null ? void 0 : D.current) == null ? void 0 : C.offsetWidth));
988
- }, [d, k]);
989
- const T = I ? (d == null ? void 0 : d.length) > 1 : (d == null ? void 0 : d.length) > 2;
990
- return /* @__PURE__ */ t(G, { children: (d == null ? void 0 : d.length) > 0 && /* @__PURE__ */ t(
991
- Ee,
725
+ campaignSingleText: w,
726
+ salesCampaignTypes: s = [],
727
+ startsInPrefixTextPlural: C,
728
+ startsinSuffixTextPlural: l,
729
+ startsInPrefixTextSingular: y,
730
+ startsinSuffixTextSingular: p,
731
+ numOfSlides: x = 2,
732
+ numOfSlidesForMobile: b = 1,
733
+ showNavigation: $ = !0
734
+ }, _) => {
735
+ const S = H(), D = se(() => t == null ? void 0 : t.map((r, T) => /* @__PURE__ */ a(
736
+ De,
737
+ {
738
+ className: "campaign-item",
739
+ coverPhoto: c(
740
+ r == null ? void 0 : r.coverPhoto,
741
+ (r == null ? void 0 : r.uuid) || (r == null ? void 0 : r.campaignUuid)
742
+ ),
743
+ description: r == null ? void 0 : r.description,
744
+ endDate: r == null ? void 0 : r.endDate,
745
+ salesPackages: r == null ? void 0 : r.salesPackages,
746
+ sellerType: e,
747
+ shopImage: r == null ? void 0 : r.profileImage,
748
+ shopName: r == null ? void 0 : r.shopName,
749
+ shopUuid: r == null ? void 0 : r.shopUuid,
750
+ startDate: r == null ? void 0 : r.startDate,
751
+ title: r == null ? void 0 : r.name,
752
+ uuid: r == null ? void 0 : r.campaignUuid,
753
+ onSelectCard: () => m(r == null ? void 0 : r.campaignUuid, r == null ? void 0 : r.shopUuid),
754
+ onSelectShop: () => v(r == null ? void 0 : r.shopUuid),
755
+ campaignSingleText: w,
756
+ salesCampaignTypes: s,
757
+ startsInPrefixTextPlural: C,
758
+ startsinSuffixTextPlural: l,
759
+ startsInPrefixTextSingular: y,
760
+ startsinSuffixTextSingular: p,
761
+ themeData: r == null ? void 0 : r.themeData
762
+ },
763
+ `campaign__item__${T}__${r == null ? void 0 : r.startDate}___${r == null ? void 0 : r.endDate}`
764
+ )), [t]);
765
+ return /* @__PURE__ */ a(
766
+ $e,
992
767
  {
993
- ref: x,
994
- className: "row-section-scroll",
995
- lastItemIdx: (d == null ? void 0 : d.length) + 1,
996
- children: /* @__PURE__ */ t(
997
- se,
768
+ isLoading: u,
769
+ itemsCount: S ? 1 : 2,
770
+ keyPrefix: "sales-camp",
771
+ children: /* @__PURE__ */ a(
772
+ Q,
998
773
  {
999
- arrowsVisibleOnHover: !1,
1000
- columnGap: "0",
1001
- methodsRef: g,
1002
- mobileHoverScrollButtons: !0,
1003
- noArrows: !0,
1004
- padding: "0.25rem 0",
1005
- rightAlignArrows: !0,
1006
- elementsCount: o == null ? void 0 : o.length,
1007
- scrollBySize: I ? P + 1 : P * 2 + 24,
1008
- showTimesBtn: !1,
1009
- title: a,
1010
- onShowEnd: () => {
1011
- },
1012
- arrowsZIndex: 11,
1013
- showArrows: T,
1014
- children: /* @__PURE__ */ t(
1015
- Re,
1016
- {
1017
- isLoading: s,
1018
- itemsCount: 2,
1019
- keyPrefix: "sales-camp",
1020
- children: d
1021
- }
1022
- )
1023
- },
1024
- `scroll-${k}`
774
+ icon: h,
775
+ title: i,
776
+ numOfSlides: x,
777
+ numOfSlidesForMobile: b,
778
+ showNavigation: $,
779
+ children: D
780
+ }
1025
781
  )
1026
782
  }
1027
- ) });
783
+ );
1028
784
  }
1029
785
  );
1030
786
  export {
1031
- rr as default
787
+ Ue as default
1032
788
  };