@redneckz/wildless-cms-uni-blocks 0.14.534 → 0.14.536

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 (234) hide show
  1. package/bin/migration-scripts/0.14.530.js +38 -0
  2. package/bundle/blocks.schema.json +1 -1
  3. package/bundle/bundle.umd.js +94 -51
  4. package/bundle/bundle.umd.min.js +1 -1
  5. package/bundle/components/Carousel/CarouselContent.d.ts +2 -0
  6. package/bundle/components/Carousel/renderCarouselCards.d.ts +2 -1
  7. package/bundle/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  8. package/bundle/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  9. package/bundle/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  10. package/bundle/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  11. package/bundle/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  12. package/bundle/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  13. package/bundle/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  14. package/bundle/ui-kit/SwipeListControl/renderDotButton.d.ts +3 -0
  15. package/bundle/ui-kit/SwipeListControl/renderNavButton.d.ts +3 -0
  16. package/dist/components/ApplicationForm/ApplicationForm.js +1 -1
  17. package/dist/components/ApplicationForm/ApplicationForm.js.map +1 -1
  18. package/dist/components/ApplicationForm/getField.js +1 -1
  19. package/dist/components/ApplicationForm/getField.js.map +1 -1
  20. package/dist/components/Carousel/Carousel.js +8 -3
  21. package/dist/components/Carousel/Carousel.js.map +1 -1
  22. package/dist/components/Carousel/CarouselContent.d.ts +2 -0
  23. package/dist/components/Carousel/renderCarouselCards.d.ts +2 -1
  24. package/dist/components/Carousel/renderCarouselCards.js +3 -1
  25. package/dist/components/Carousel/renderCarouselCards.js.map +1 -1
  26. package/dist/components/ProductBlock/ProductBlock.js +1 -1
  27. package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
  28. package/dist/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  29. package/dist/ui-kit/LinkButton/ButtonInner.js +2 -2
  30. package/dist/ui-kit/LinkButton/ButtonInner.js.map +1 -1
  31. package/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  32. package/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js +7 -2
  33. package/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js.map +1 -1
  34. package/dist/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  35. package/dist/ui-kit/ResponseTypeDialog/useResponseTypeDialog.js.map +1 -1
  36. package/dist/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  37. package/dist/ui-kit/SwipeListControl/NavButtonProp.js +2 -0
  38. package/dist/ui-kit/SwipeListControl/NavButtonProp.js.map +1 -0
  39. package/dist/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  40. package/dist/ui-kit/SwipeListControl/SwipeListControl.js +2 -2
  41. package/dist/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  42. package/dist/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  43. package/dist/ui-kit/SwipeListControl/SwipeListDots.js +32 -16
  44. package/dist/ui-kit/SwipeListControl/SwipeListDots.js.map +1 -1
  45. package/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  46. package/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.js +4 -3
  47. package/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.js.map +1 -1
  48. package/dist/ui-kit/SwipeListControl/renderDotButton.d.ts +3 -0
  49. package/dist/ui-kit/SwipeListControl/renderDotButton.js +13 -0
  50. package/dist/ui-kit/SwipeListControl/renderDotButton.js.map +1 -0
  51. package/dist/ui-kit/SwipeListControl/renderNavButton.d.ts +3 -0
  52. package/dist/ui-kit/SwipeListControl/renderNavButton.js +17 -0
  53. package/dist/ui-kit/SwipeListControl/renderNavButton.js.map +1 -0
  54. package/dist/ui-kit/SwipeListControl/useSwipeListScroll.js +1 -1
  55. package/dist/ui-kit/SwipeListControl/useSwipeListScroll.js.map +1 -1
  56. package/lib/common.css +1 -1
  57. package/lib/components/ApplicationForm/ApplicationForm.js +1 -1
  58. package/lib/components/ApplicationForm/ApplicationForm.js.map +1 -1
  59. package/lib/components/ApplicationForm/getField.js +1 -1
  60. package/lib/components/ApplicationForm/getField.js.map +1 -1
  61. package/lib/components/Carousel/Carousel.fixture.d.ts +1 -0
  62. package/lib/components/Carousel/Carousel.fixture.mobile.d.ts +1 -0
  63. package/lib/components/Carousel/Carousel.js +8 -3
  64. package/lib/components/Carousel/Carousel.js.map +1 -1
  65. package/lib/components/Carousel/CarouselContent.d.ts +2 -0
  66. package/lib/components/Carousel/renderCarouselCards.d.ts +2 -1
  67. package/lib/components/Carousel/renderCarouselCards.js +3 -1
  68. package/lib/components/Carousel/renderCarouselCards.js.map +1 -1
  69. package/lib/components/ProductBlock/ProductBlock.js +1 -1
  70. package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
  71. package/lib/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  72. package/lib/ui-kit/LinkButton/ButtonInner.js +2 -2
  73. package/lib/ui-kit/LinkButton/ButtonInner.js.map +1 -1
  74. package/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  75. package/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js +7 -2
  76. package/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js.map +1 -1
  77. package/lib/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  78. package/lib/ui-kit/ResponseTypeDialog/useResponseTypeDialog.js.map +1 -1
  79. package/lib/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  80. package/lib/ui-kit/SwipeListControl/NavButtonProp.js +2 -0
  81. package/lib/ui-kit/SwipeListControl/NavButtonProp.js.map +1 -0
  82. package/lib/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  83. package/lib/ui-kit/SwipeListControl/SwipeListControl.js +2 -2
  84. package/lib/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  85. package/lib/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  86. package/lib/ui-kit/SwipeListControl/SwipeListDots.js +32 -16
  87. package/lib/ui-kit/SwipeListControl/SwipeListDots.js.map +1 -1
  88. package/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  89. package/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.js +4 -3
  90. package/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.js.map +1 -1
  91. package/lib/ui-kit/SwipeListControl/renderDotButton.d.ts +2 -0
  92. package/lib/ui-kit/SwipeListControl/renderDotButton.js +10 -0
  93. package/lib/ui-kit/SwipeListControl/renderDotButton.js.map +1 -0
  94. package/lib/ui-kit/SwipeListControl/renderNavButton.d.ts +2 -0
  95. package/lib/ui-kit/SwipeListControl/renderNavButton.js +14 -0
  96. package/lib/ui-kit/SwipeListControl/renderNavButton.js.map +1 -0
  97. package/lib/ui-kit/SwipeListControl/useSwipeListScroll.js +1 -1
  98. package/lib/ui-kit/SwipeListControl/useSwipeListScroll.js.map +1 -1
  99. package/mobile/bundle/bundle.umd.js +94 -51
  100. package/mobile/bundle/bundle.umd.min.js +1 -1
  101. package/mobile/bundle/components/Carousel/CarouselContent.d.ts +2 -0
  102. package/mobile/bundle/components/Carousel/renderCarouselCards.d.ts +2 -1
  103. package/mobile/bundle/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  104. package/mobile/bundle/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  105. package/mobile/bundle/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  106. package/mobile/bundle/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  107. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  108. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  109. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  110. package/mobile/bundle/ui-kit/SwipeListControl/renderDotButton.d.ts +3 -0
  111. package/mobile/bundle/ui-kit/SwipeListControl/renderNavButton.d.ts +3 -0
  112. package/mobile/dist/components/ApplicationForm/ApplicationForm.js +1 -1
  113. package/mobile/dist/components/ApplicationForm/ApplicationForm.js.map +1 -1
  114. package/mobile/dist/components/ApplicationForm/getField.js +1 -1
  115. package/mobile/dist/components/ApplicationForm/getField.js.map +1 -1
  116. package/mobile/dist/components/Carousel/Carousel.js +8 -3
  117. package/mobile/dist/components/Carousel/Carousel.js.map +1 -1
  118. package/mobile/dist/components/Carousel/CarouselContent.d.ts +2 -0
  119. package/mobile/dist/components/Carousel/renderCarouselCards.d.ts +2 -1
  120. package/mobile/dist/components/Carousel/renderCarouselCards.js +3 -1
  121. package/mobile/dist/components/Carousel/renderCarouselCards.js.map +1 -1
  122. package/mobile/dist/components/ProductBlock/ProductBlock.js +1 -1
  123. package/mobile/dist/components/ProductBlock/ProductBlock.js.map +1 -1
  124. package/mobile/dist/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  125. package/mobile/dist/ui-kit/LinkButton/ButtonInner.js +2 -2
  126. package/mobile/dist/ui-kit/LinkButton/ButtonInner.js.map +1 -1
  127. package/mobile/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  128. package/mobile/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js +7 -2
  129. package/mobile/dist/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js.map +1 -1
  130. package/mobile/dist/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  131. package/mobile/dist/ui-kit/ResponseTypeDialog/useResponseTypeDialog.js.map +1 -1
  132. package/mobile/dist/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  133. package/mobile/dist/ui-kit/SwipeListControl/NavButtonProp.js +2 -0
  134. package/mobile/dist/ui-kit/SwipeListControl/NavButtonProp.js.map +1 -0
  135. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  136. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControl.js +2 -2
  137. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  138. package/mobile/dist/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  139. package/mobile/dist/ui-kit/SwipeListControl/SwipeListDots.js +32 -16
  140. package/mobile/dist/ui-kit/SwipeListControl/SwipeListDots.js.map +1 -1
  141. package/mobile/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  142. package/mobile/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.js +4 -3
  143. package/mobile/dist/ui-kit/SwipeListControl/SwipeListScrollButtons.js.map +1 -1
  144. package/mobile/dist/ui-kit/SwipeListControl/renderDotButton.d.ts +3 -0
  145. package/mobile/dist/ui-kit/SwipeListControl/renderDotButton.js +13 -0
  146. package/mobile/dist/ui-kit/SwipeListControl/renderDotButton.js.map +1 -0
  147. package/mobile/dist/ui-kit/SwipeListControl/renderNavButton.d.ts +3 -0
  148. package/mobile/dist/ui-kit/SwipeListControl/renderNavButton.js +17 -0
  149. package/mobile/dist/ui-kit/SwipeListControl/renderNavButton.js.map +1 -0
  150. package/mobile/dist/ui-kit/SwipeListControl/useSwipeListScroll.js +1 -1
  151. package/mobile/dist/ui-kit/SwipeListControl/useSwipeListScroll.js.map +1 -1
  152. package/mobile/lib/common.css +1 -1
  153. package/mobile/lib/components/ApplicationForm/ApplicationForm.js +1 -1
  154. package/mobile/lib/components/ApplicationForm/ApplicationForm.js.map +1 -1
  155. package/mobile/lib/components/ApplicationForm/getField.js +1 -1
  156. package/mobile/lib/components/ApplicationForm/getField.js.map +1 -1
  157. package/mobile/lib/components/Carousel/Carousel.js +8 -3
  158. package/mobile/lib/components/Carousel/Carousel.js.map +1 -1
  159. package/mobile/lib/components/Carousel/CarouselContent.d.ts +2 -0
  160. package/mobile/lib/components/Carousel/renderCarouselCards.d.ts +2 -1
  161. package/mobile/lib/components/Carousel/renderCarouselCards.js +3 -1
  162. package/mobile/lib/components/Carousel/renderCarouselCards.js.map +1 -1
  163. package/mobile/lib/components/ProductBlock/ProductBlock.js +1 -1
  164. package/mobile/lib/components/ProductBlock/ProductBlock.js.map +1 -1
  165. package/mobile/lib/components/ProductBlock/ProductBlockContent.d.ts +2 -1
  166. package/mobile/lib/ui-kit/LinkButton/ButtonInner.js +2 -2
  167. package/mobile/lib/ui-kit/LinkButton/ButtonInner.js.map +1 -1
  168. package/mobile/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.d.ts +1 -0
  169. package/mobile/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js +7 -2
  170. package/mobile/lib/ui-kit/ResponseTypeDialog/ResponseTypeDialog.js.map +1 -1
  171. package/mobile/lib/ui-kit/ResponseTypeDialog/useResponseTypeDialog.d.ts +1 -0
  172. package/mobile/lib/ui-kit/ResponseTypeDialog/useResponseTypeDialog.js.map +1 -1
  173. package/mobile/lib/ui-kit/SwipeListControl/NavButtonProp.d.ts +9 -0
  174. package/mobile/lib/ui-kit/SwipeListControl/NavButtonProp.js +2 -0
  175. package/mobile/lib/ui-kit/SwipeListControl/NavButtonProp.js.map +1 -0
  176. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControl.d.ts +2 -0
  177. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControl.js +2 -2
  178. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  179. package/mobile/lib/ui-kit/SwipeListControl/SwipeListDots.d.ts +8 -3
  180. package/mobile/lib/ui-kit/SwipeListControl/SwipeListDots.js +32 -16
  181. package/mobile/lib/ui-kit/SwipeListControl/SwipeListDots.js.map +1 -1
  182. package/mobile/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.d.ts +1 -0
  183. package/mobile/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.js +4 -3
  184. package/mobile/lib/ui-kit/SwipeListControl/SwipeListScrollButtons.js.map +1 -1
  185. package/mobile/lib/ui-kit/SwipeListControl/renderDotButton.d.ts +3 -0
  186. package/mobile/lib/ui-kit/SwipeListControl/renderDotButton.js +10 -0
  187. package/mobile/lib/ui-kit/SwipeListControl/renderDotButton.js.map +1 -0
  188. package/mobile/lib/ui-kit/SwipeListControl/renderNavButton.d.ts +3 -0
  189. package/mobile/lib/ui-kit/SwipeListControl/renderNavButton.js +14 -0
  190. package/mobile/lib/ui-kit/SwipeListControl/renderNavButton.js.map +1 -0
  191. package/mobile/lib/ui-kit/SwipeListControl/useSwipeListScroll.js +1 -1
  192. package/mobile/lib/ui-kit/SwipeListControl/useSwipeListScroll.js.map +1 -1
  193. package/mobile/src/components/ApplicationForm/ApplicationForm.example.json +5 -0
  194. package/mobile/src/components/ApplicationForm/ApplicationForm.tsx +1 -1
  195. package/mobile/src/components/ApplicationForm/getField.tsx +1 -0
  196. package/mobile/src/components/Carousel/Carousel.tsx +28 -17
  197. package/mobile/src/components/Carousel/CarouselContent.ts +2 -0
  198. package/mobile/src/components/Carousel/renderCarouselCards.tsx +8 -1
  199. package/mobile/src/components/ProductBlock/ProductBlock.tsx +7 -2
  200. package/mobile/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  201. package/mobile/src/ui-kit/LinkButton/ButtonInner.tsx +2 -2
  202. package/mobile/src/ui-kit/ResponseTypeDialog/ResponseTypeDialog.tsx +12 -4
  203. package/mobile/src/ui-kit/ResponseTypeDialog/useResponseTypeDialog.tsx +1 -0
  204. package/mobile/src/ui-kit/SwipeListControl/NavButtonProp.ts +11 -0
  205. package/mobile/src/ui-kit/SwipeListControl/SwipeListControl.tsx +7 -1
  206. package/mobile/src/ui-kit/SwipeListControl/SwipeListDots.tsx +69 -46
  207. package/mobile/src/ui-kit/SwipeListControl/SwipeListScrollButtons.tsx +9 -5
  208. package/mobile/src/ui-kit/SwipeListControl/renderDotButton.tsx +29 -0
  209. package/mobile/src/ui-kit/SwipeListControl/renderNavButton.tsx +33 -0
  210. package/mobile/src/ui-kit/SwipeListControl/useSwipeListScroll.ts +1 -1
  211. package/package.json +2 -2
  212. package/src/components/ApplicationForm/ApplicationForm.example.json +5 -0
  213. package/src/components/ApplicationForm/ApplicationForm.fixture.mobile.tsx +5 -0
  214. package/src/components/ApplicationForm/ApplicationForm.fixture.tsx +5 -0
  215. package/src/components/ApplicationForm/ApplicationForm.tsx +1 -1
  216. package/src/components/ApplicationForm/getField.tsx +1 -0
  217. package/src/components/Carousel/Carousel.fixture.mobile.tsx +57 -0
  218. package/src/components/Carousel/Carousel.fixture.tsx +56 -0
  219. package/src/components/Carousel/Carousel.tsx +28 -17
  220. package/src/components/Carousel/CarouselContent.ts +2 -0
  221. package/src/components/Carousel/renderCarouselCards.tsx +8 -1
  222. package/src/components/ProductBlock/ProductBlock.tsx +7 -2
  223. package/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  224. package/src/components/ProductGallery/ProductGallery.fixture.tsx +17 -84
  225. package/src/ui-kit/LinkButton/ButtonInner.tsx +2 -2
  226. package/src/ui-kit/ResponseTypeDialog/ResponseTypeDialog.tsx +12 -4
  227. package/src/ui-kit/ResponseTypeDialog/useResponseTypeDialog.tsx +1 -0
  228. package/src/ui-kit/SwipeListControl/NavButtonProp.ts +11 -0
  229. package/src/ui-kit/SwipeListControl/SwipeListControl.tsx +7 -1
  230. package/src/ui-kit/SwipeListControl/SwipeListDots.tsx +69 -46
  231. package/src/ui-kit/SwipeListControl/SwipeListScrollButtons.tsx +9 -5
  232. package/src/ui-kit/SwipeListControl/renderDotButton.tsx +29 -0
  233. package/src/ui-kit/SwipeListControl/renderNavButton.tsx +33 -0
  234. package/src/ui-kit/SwipeListControl/useSwipeListScroll.ts +1 -1
@@ -6,13 +6,18 @@ import { Button } from '../Button/Button.js';
6
6
  import { Dialog } from '../DialogManager/Dialog.js';
7
7
  import { useDialogManager } from '../DialogManager/useDialogManager.js';
8
8
  import { Img } from '../Img/Img.js';
9
- export const ResponseTypeDialog = JSX(function ({ responseType }) {
9
+ export const ResponseTypeDialog = JSX(function ({ responseType, typeForm, }) {
10
10
  const responseOK = responseType === 'OK';
11
11
  const statusIcon = responseOK ? 'ResponseOKIcon' : 'ResponseFailIcon';
12
12
  const { close } = useDialogManager();
13
13
  const handleClose = useCallback(() => {
14
14
  close();
15
15
  }, []);
16
- return (_jsx(Dialog, { className: "my-6xl max-w-lg w-full min-h-fit mx-auto ", children: _jsxs("div", { className: "flex flex-col gap-lg items-center rounded-md space-x-m", children: [_jsx(Img, { image: { icon: statusIcon, iconVersion: 'normal' }, width: "136", height: "136" }), _jsx(Headline, { className: "w-full", title: responseOK ? 'Ваша заявка отправлена' : 'Не удалось отправить заявку', description: responseOK ? 'Совсем скоро мы с вами свяжемся' : 'Пожалуйста, повторите позднее', headlineVersion: "XS", isEmbedded: true }), _jsx(Button, { type: "button", onClick: handleClose, children: "\u0425\u043E\u0440\u043E\u0448\u043E" })] }) }));
16
+ const responseOKDescription = typeForm === 'ANTIFRAUD'
17
+ ? `Сообщение отправлено. Для уточнения информации с Вами могут связаться работники Банка либо Вы
18
+ можете самостоятельно позвонить по номеру контакт-центра +78001000100. Будьте внимательны, работники Банка
19
+ не звонят с использованием мессенджеров.`
20
+ : 'Совсем скоро мы с вами свяжемся';
21
+ return (_jsx(Dialog, { className: "my-6xl max-w-lg w-full min-h-fit mx-auto ", children: _jsxs("div", { className: "flex flex-col gap-lg items-center rounded-md space-x-m", children: [_jsx(Img, { image: { icon: statusIcon, iconVersion: 'normal' }, width: "136", height: "136" }), _jsx(Headline, { className: "w-full", title: responseOK ? 'Ваша заявка отправлена' : 'Не удалось отправить заявку', description: responseOK ? responseOKDescription : 'Пожалуйста, повторите позднее', headlineVersion: "XS", isEmbedded: true }), _jsx(Button, { type: "button", onClick: handleClose, children: "\u0425\u043E\u0440\u043E\u0448\u043E" })] }) }));
17
22
  });
18
23
  //# sourceMappingURL=ResponseTypeDialog.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ResponseTypeDialog.js","sourceRoot":"","sources":["../../../src/ui-kit/ResponseTypeDialog/ResponseTypeDialog.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AAC9D,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AACrE,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAKjC,MAAM,CAAC,MAAM,kBAAkB,GAAG,GAAG,CAA4B,UAAU,EAAE,YAAY,EAAE;IACzF,MAAM,UAAU,GAAG,YAAY,KAAK,IAAI,CAAC;IACzC,MAAM,UAAU,GAAG,UAAU,CAAC,CAAC,CAAC,gBAAgB,CAAC,CAAC,CAAC,kBAAkB,CAAC;IACtE,MAAM,EAAE,KAAK,EAAE,GAAG,gBAAgB,EAAE,CAAC;IACrC,MAAM,WAAW,GAAG,WAAW,CAAC,GAAG,EAAE;QACnC,KAAK,EAAE,CAAC;IACV,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACL,KAAC,MAAM,IAAC,SAAS,EAAC,2CAA2C,YAC3D,eAAK,SAAS,EAAC,wDAAwD,aACrE,KAAC,GAAG,IAAC,KAAK,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,WAAW,EAAE,QAAQ,EAAE,EAAE,KAAK,EAAC,KAAK,EAAC,MAAM,EAAC,KAAK,GAAG,EACpF,KAAC,QAAQ,IACP,SAAS,EAAC,QAAQ,EAClB,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,wBAAwB,CAA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C;IAExC,OAAO,CACL,KAAC,MAAM,IAAC,SAAS,EAAC,2CAA2C,YAC3D,eAAK,SAAS,EAAC,wDAAwD,aACrE,KAAC,GAAG,IAAC,KAAK,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,WAAW,EAAE,QAAQ,EAAE,EAAE,KAAK,EAAC,KAAK,EAAC,MAAM,EAAC,KAAK,GAAG,EACpF,KAAC,QAAQ,IACP,SAAS,EAAC,QAAQ,EAClB,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,wBAAwB,CAAC,CAAC,CAAC,6BAA6B,EAC5E,WAAW,EAAE,UAAU,CAAC,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,+BAA+B,EACjF,eAAe,EAAC,IAAI,EACpB,UAAU,EAAE,IAAI,GAChB,EACF,KAAC,MAAM,IAAC,IAAI,EAAC,QAAQ,EAAC,OAAO,EAAE,WAAW,qDAEjC,IACL,GACC,CACV,CAAC;AACJ,CAAC,CAAC,CAAC"}
@@ -1,6 +1,7 @@
1
1
  import { type DialogOptions } from '../DialogManager/useDialogManager';
2
2
  export interface ResponseTypeDialogProps {
3
3
  responseType?: 'OK' | 'Fail';
4
+ typeForm?: string;
4
5
  }
5
6
  export declare const useResponseTypeDialog: (props: ResponseTypeDialogProps) => {
6
7
  open: (options?: DialogOptions) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"useResponseTypeDialog.js","sourceRoot":"","sources":["../../../src/ui-kit/ResponseTypeDialog/useResponseTypeDialog.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,gBAAgB,EAAsB,MAAM,mCAAmC,CAAC;AACzF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAM1D,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,KAA8B,EAAE,EAAE;IACtE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,gBAAgB,EAAE,CAAC;IAE3C,OAAO;QACL,IAAI,EAAE,CAAC,UAAyB,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,KAAC,kBAAkB,OAAK,KAAK,GAAI,EAAE,OAAO,CAAC;QACvF,KAAK;KACN,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"file":"useResponseTypeDialog.js","sourceRoot":"","sources":["../../../src/ui-kit/ResponseTypeDialog/useResponseTypeDialog.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,gBAAgB,EAAsB,MAAM,mCAAmC,CAAC;AACzF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAO1D,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,KAA8B,EAAE,EAAE;IACtE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,gBAAgB,EAAE,CAAC;IAE3C,OAAO;QACL,IAAI,EAAE,CAAC,UAAyB,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,KAAC,kBAAkB,OAAK,KAAK,GAAI,EAAE,OAAO,CAAC;QACvF,KAAK;KACN,CAAC;AACJ,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { type DescriptionProps, type TitleProps } from '../../model/HeadlineType';
2
+ import type { SwipeListControlType } from './SwipeListControlContent';
3
+ export interface DotProp {
4
+ activeIndex?: number;
5
+ onClick: (i: number) => void;
6
+ listType?: SwipeListControlType;
7
+ }
8
+ /** @title Кнопка под слайдом */
9
+ export declare type NavButtonProp = TitleProps & DescriptionProps;
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=NavButtonProp.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NavButtonProp.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/NavButtonProp.ts"],"names":[],"mappings":""}
@@ -1,4 +1,5 @@
1
1
  import { type BlockVersion } from '../../model/BlockVersion';
2
+ import { type NavButtonProp } from './NavButtonProp';
2
3
  import { type SnapAlign } from './SwipeListContainer';
3
4
  import { type SwipeListControlContent } from './SwipeListControlContent';
4
5
  interface SwipeListControlProps extends SwipeListControlContent {
@@ -9,6 +10,7 @@ interface SwipeListControlProps extends SwipeListControlContent {
9
10
  snapAlign?: SnapAlign;
10
11
  hasBlur?: boolean;
11
12
  onVisibleIndicesChange?: (indices: number[]) => void;
13
+ navButtons?: NavButtonProp[];
12
14
  }
13
15
  export declare const SwipeListControl: import("@redneckz/uni-jsx").UNIComponent<SwipeListControlProps, any, any>;
14
16
  export {};
@@ -12,13 +12,13 @@ const DEFAULT_GAP = 14;
12
12
  and get rid of a clipping effect caused by overflow: hidden.
13
13
  */
14
14
  const DEFAULT_PADDING = 16;
15
- export const SwipeListControl = JSX(({ className, version, gap = DEFAULT_GAP, padding = DEFAULT_PADDING, visibleItemCount = 1, listType = 'horizontal-list', snapAlign, minHeight, showArrows, hasBlur, arrowsPadded, showDots, children, onVisibleIndicesChange, }) => {
15
+ export const SwipeListControl = JSX(({ className, version, gap = DEFAULT_GAP, padding = DEFAULT_PADDING, visibleItemCount = 1, listType = 'horizontal-list', snapAlign, minHeight, showArrows, hasBlur, arrowsPadded, showDots, children, onVisibleIndicesChange, navButtons, }) => {
16
16
  const itemCount = Array.isArray(children) ? children.length : 0;
17
17
  const [containerRef, scroll] = useSwipeListScroll({
18
18
  itemCount,
19
19
  onVisibleIndicesChange,
20
20
  });
21
21
  const [activeIndex] = scroll.visibleIndicesRange;
22
- return (_jsxs("div", { className: style(className, listType === 'vertical-list' ? 'relative h-full' : ''), children: [_jsx(SwipeListContainer, { containerRef: containerRef, activeIndex: activeIndex, visibleItemCount: visibleItemCount, gap: gap, padding: padding, listType: listType, snapAlign: snapAlign, minHeight: minHeight, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: children }), _jsx(SwipeListScrollButtons, { className: style(!showArrows && 'hidden lg:block'), scroll: scroll, hasBlur: hasBlur, arrowsPadded: arrowsPadded }), _jsx(SwipeListDots, { className: style(!showDots && 'lg:hidden'), containerRef: containerRef, activeIndex: activeIndex, dotCount: itemCount, listType: listType, version: version })] }));
22
+ return (_jsxs("div", { className: style(className, listType === 'vertical-list' ? 'relative h-full' : ''), children: [_jsx(SwipeListContainer, { containerRef: containerRef, activeIndex: activeIndex, visibleItemCount: visibleItemCount, gap: gap, padding: padding, listType: listType, snapAlign: snapAlign, minHeight: minHeight, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: children }), _jsx(SwipeListScrollButtons, { className: style(!showArrows && 'hidden lg:block'), scroll: scroll, hasBlur: hasBlur, arrowsPadded: arrowsPadded, isBottom: Boolean(navButtons?.length) }), _jsx(SwipeListDots, { className: style(!showDots && 'lg:hidden'), activeIndex: activeIndex, dotCount: itemCount, listType: listType, version: version, navButtons: navButtons, containerRef: containerRef, containerScroll: scroll })] }));
23
23
  });
24
24
  //# sourceMappingURL=SwipeListControl.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SwipeListControl.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/SwipeListControl.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,kBAAkB,EAAkB,MAAM,sBAAsB,CAAC;AAE1E,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,MAAM,WAAW,GAAG,EAAE,CAAC;AAEvB;;;;GAIG;AACH,MAAM,eAAe,GAAG,EAAE,CAAC;AAY3B,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CACjC,CAAC,EACC,SAAS,EACT,OAAO,EACP,GAAG,GAAG,WAAW,EACjB,OAAO,GAAG,eAAe,EACzB,gBAAgB,GAAG,CAAC,EACpB,QAAQ,GAAG,iBAAiB,EAC5B,SAAS,EACT,SAAS,EACT,UAAU,EACV,OAAO,EACP,YAAY,EACZ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B,WAAW,EAAE,WAAW,EACxB,gBAAgB,EAAE,gBAAgB,EAClC,GAAG,EAAE,GAAG,EACR,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,SAAS,EACpB,SAAS,EAAE,SAAS,EACpB,sBAAsB,EAAE,MAAM,CAAC,0BAA0B,YAExD,QAAQ,GACU,EACrB,KAAC,sBAAsB,IACrB,SAAS,EAAE,KAAK,CAAC,CAAC,UAAU,IAAI,iBAAiB,CAAC,EAClD,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,YAAY,EAC1B,QAAQ,EAAE,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,GACrC,EACF,KAAC,aAAa,IACZ,SAAS,EAAE,KAAK,CAAC,CAAC,QAAQ,IAAI,WAAW,CAAC,EAC1C,WAAW,EAAE,WAAW,EACxB,QAAQ,EAAE,SAAS,EACnB,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,EAC1B,eAAe,EAAE,MAAM,GACvB,IACE,CACP,CAAC;AACJ,CAAC,CACF,CAAC"}
@@ -1,14 +1,19 @@
1
1
  import { type BlockVersion } from '../../model/BlockVersion';
2
+ import { type NavButtonProp } from './NavButtonProp';
2
3
  import { type SwipeListControlType } from './SwipeListControlContent';
4
+ import { type SwipeListScroll } from './useSwipeListScroll';
3
5
  interface SwipeListDotsProps {
4
6
  className?: string;
5
- containerRef?: {
6
- current: HTMLDivElement | null;
7
- };
8
7
  activeIndex?: number;
9
8
  dotCount?: number;
10
9
  listType?: SwipeListControlType;
11
10
  version?: BlockVersion;
11
+ navButtons?: NavButtonProp[];
12
+ onVisibleIndicesChange?: (indices: number[]) => void;
13
+ containerRef?: {
14
+ current: HTMLDivElement | null;
15
+ };
16
+ containerScroll?: SwipeListScroll;
12
17
  }
13
18
  export declare const SwipeListDots: import("@redneckz/uni-jsx").UNIComponent<SwipeListDotsProps, any, any>;
14
19
  export {};
@@ -1,27 +1,43 @@
1
1
  import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
+ import { useCallback, useEffect } from '@redneckz/uni-jsx/lib/hooks';
4
+ import { useMobileMode } from '../../hooks/useMobileMode.js';
3
5
  import { style } from '../../utils/style.js';
6
+ import { renderDotButton } from './renderDotButton.js';
7
+ import { renderNavButton } from './renderNavButton.js';
8
+ import { SwipeListContainer } from './SwipeListContainer.js';
9
+ import { useSwipeListScroll } from './useSwipeListScroll.js';
4
10
  const containerStyles = {
5
11
  'horizontal-list': 'mx-auto mt-lg w-fit',
6
12
  'vertical-list': 'absolute flex-col justify-center h-full top-0 left-4',
7
13
  };
8
- const activeDotStyles = {
9
- 'horizontal-list': 'w-6',
10
- 'vertical-list': 'h-6',
11
- };
12
- const dotStyle = 'cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white';
13
- const inactiveDotStyle = 'w-2 h-2 opacity-30';
14
- export const SwipeListDots = JSX(({ className = '', containerRef, activeIndex, dotCount = 0, listType = 'horizontal-list', version, }) => {
15
- const handleClick = (idx) => {
14
+ export const SwipeListDots = JSX(({ className = '', activeIndex = 0, dotCount = 0, listType = 'horizontal-list', version, navButtons = [], containerRef, containerScroll, }) => {
15
+ const isMobileMode = useMobileMode();
16
+ const [navRef, navScroll] = useSwipeListScroll({
17
+ itemCount: navButtons.length,
18
+ });
19
+ const scrollOption = getOptions(Boolean(navButtons?.length));
20
+ useEffect(() => {
21
+ if (navButtons?.length && activeIndex >= 0 && navRef?.current) {
22
+ navScroll.scrollTo(activeIndex, scrollOption);
23
+ }
24
+ }, [activeIndex]);
25
+ const onChangeActiveIndex = useCallback((idx) => {
16
26
  if (idx !== activeIndex && containerRef?.current) {
17
- containerRef.current.children[idx]?.scrollIntoView({
18
- behavior: 'smooth',
19
- block: 'nearest',
20
- });
27
+ containerScroll?.scrollTo(idx, scrollOption);
21
28
  }
22
- };
23
- return dotCount ? (_jsx("div", { className: style('flex gap-xs', containerStyles[listType], version ? 'group' : '', className), "data-ver": version, children: Array.from({ length: dotCount })
24
- .fill(null)
25
- .map((_, idx) => (_jsx("div", { className: `${dotStyle} ${idx === activeIndex ? activeDotStyles[listType] : inactiveDotStyle}`, role: "button", "aria-hidden": true, onClick: () => handleClick(idx) }, String(idx)))) })) : null;
29
+ }, [containerRef?.current]);
30
+ if (navButtons?.length && !isMobileMode) {
31
+ return (_jsx(SwipeListContainer, { containerRef: navRef, snapAlign: "snap-start", itemClassName: "h-36 flex items-stretch w-screen", gap: 8, children: navButtons.map(renderNavButton({ activeIndex, onClick: onChangeActiveIndex })) }));
32
+ }
33
+ else if (dotCount) {
34
+ return (_jsx("div", { className: style('flex gap-xs', containerStyles[listType], version ? 'group' : '', className, { 'pb-xl': navButtons?.length && isMobileMode }), "data-ver": version, children: Array.from({ length: dotCount })
35
+ .fill(null)
36
+ .map(renderDotButton({ activeIndex, onClick: onChangeActiveIndex, listType })) }));
37
+ }
38
+ return null;
39
+ });
40
+ const getOptions = (isAuto = false) => ({
41
+ behavior: isAuto ? 'auto' : 'smooth',
26
42
  });
27
43
  //# sourceMappingURL=SwipeListDots.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SwipeListDots.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/SwipeListDots.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAG1C,MAAM,eAAe,GAAyC;IAC5D,iBAAiB,EAAE,qBAAqB;IACxC,eAAe,EAAE,sDAAsD;CACxE,CAAC;AAEF,MAAM,eAAe,GAAyC;IAC5D,iBAAiB,EAAE,KAAK;IACxB,eAAe,EAAE,KAAK;CACvB,CAAC;AAEF,MAAM,QAAQ,GACZ,yGAAyG,CAAC;AAE5G,MAAM,gBAAg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C,CAAC,CAAC,QAAQ;CACrC,CAAC,CAAC"}
@@ -4,5 +4,6 @@ export interface SwipeListScrollButtonsProps extends SwipeListScrollButtonsConte
4
4
  className?: string;
5
5
  scroll: SwipeListScroll;
6
6
  hasBlur?: boolean;
7
+ isBottom?: boolean;
7
8
  }
8
9
  export declare const SwipeListScrollButtons: import("@redneckz/uni-jsx").UNIComponent<SwipeListScrollButtonsProps, any, any>;
@@ -2,11 +2,12 @@ import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
3
  import { style } from '../../utils/style.js';
4
4
  import { ScrollLeftButton, ScrollRightButton } from '../LinkButton/ArrowButton.js';
5
- const scrollButtonStyle = 'absolute top-[calc(50%-24px)] z-40';
6
5
  const blurBaseStyle = 'absolute top-0 bottom-0 z-40 hidden @lg:block w-20 pointer-events-none';
7
- export const SwipeListScrollButtons = JSX(({ className, scroll, hasBlur, arrowsPadded }) => {
6
+ export const SwipeListScrollButtons = JSX(({ className, scroll, hasBlur, arrowsPadded, isBottom }) => {
8
7
  const { canScrollLeft, canScrollRight, scrollLeft, scrollRight } = scroll;
9
- return (_jsxs("div", { className: style(className), children: [hasBlur ? renderBlur(scroll) : null, canScrollLeft ? (_jsx(ScrollLeftButton, { className: style(scrollButtonStyle, arrowsPadded ? 'left-1' : 'left-0'), onClick: scrollLeft })) : null, canScrollRight ? (_jsx(ScrollRightButton, { className: style(scrollButtonStyle, arrowsPadded ? 'right-1' : 'right-0'), onClick: scrollRight })) : null] }));
8
+ const isArrowPadded = arrowsPadded && !isBottom;
9
+ return (_jsxs("div", { className: className, children: [hasBlur ? renderBlur(scroll) : null, canScrollLeft ? (_jsx(ScrollLeftButton, { className: style(buttonStyle(isBottom), isArrowPadded ? 'left-1' : 'left-0'), onClick: scrollLeft })) : null, canScrollRight ? (_jsx(ScrollRightButton, { className: style(buttonStyle(isBottom), isArrowPadded ? 'right-1' : 'right-0'), onClick: scrollRight })) : null] }));
10
10
  });
11
11
  const renderBlur = (scroll) => (_jsxs("div", { children: [scroll.canScrollLeft ? (_jsx("div", { className: style(blurBaseStyle, 'left-0 bg-opacity-from-white group-data-secondary:bg-none') })) : null, scroll.canScrollRight ? (_jsx("div", { className: style(blurBaseStyle, 'right-0 bg-opacity-to-white group-data-secondary:bg-none') })) : null] }));
12
+ const buttonStyle = (isBottom = false) => style('absolute z-40', isBottom ? 'bottom-[56px]' : 'top-[calc(50%-24px)]');
12
13
  //# sourceMappingURL=SwipeListScrollButtons.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SwipeListScrollButtons.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/SwipeListScrollButtons.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAIhF,MAAM,iBAAiB,GAAG,oCAAoC,CAAC;AAC/D,MAAM,aAAa,GAAG,wEAAwE,CAAC;AAQ/F,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,CACvC,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE;IAC/C,MAAM,EAAE,aAAa,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,MAAM,CAAC;IAE1E,OAAO,CACL,eAAK,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,aAC7B,OAAO,CAAC,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,IAAI,EACnC,aAAa,CAAC,CAAC,CAAC,CACf,KAAC,gBAAgB,IACf,SAAS,EAAE,KAAK,CAAC,iBAAiB,EAAE,YAAY,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,EACvE,OAAO,EAAE,UAAU,GACnB,CACH,CAAC,CAAC,CAAC,IAAI,EACP,cAAc,CAAC,CAAC,CAAC,CAChB,KAAC,iBAAiB,IAChB,SAAS,EAAE,KAAK,CAAC,iBAAiB,EAAE,YAAY,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,EACzE,OAAO,EAAE,WAAW,GACpB,CACH,CAAC,CAAC,CAAC,IAAI,IACJ,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,MAAM,UAAU,GAAG,CAAC,MAAuB,EAAE,EAAE,CAAC,CAC9C,0BACG,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC,CACtB,cACE,SAAS,EAAE,KAAK,CACd,aAAa,EACb,2DAA2D,CAC5D,GACD,CACH,CAAC,CAAC,CAAC,IAAI,EACP,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC,CACvB,cACE,SAAS,EAAE,KAAK,CAAC,aAAa,EAAE,0DAA0D,CAAC,GAC3F,CACH,CAAC,CAAC,CAAC,IAAI,IACJ,CACP,CAAC"}
1
+ {"version":3,"file":"SwipeListScrollButtons.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/SwipeListScrollButtons.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAIhF,MAAM,aAAa,GAAG,wEAAwE,CAAC;AAS/F,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,CACvC,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,EAAE;IACzD,MAAM,EAAE,aAAa,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,MAAM,CAAC;IAC1E,MAAM,aAAa,GAAG,YAAY,IAAI,CA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, onClick, listType }: DotProp) => (_: any, idx: number) => JSX.Element;
@@ -0,0 +1,10 @@
1
+ import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
+ import { style } from '../../utils/style.js';
3
+ const activeDotStyles = {
4
+ 'horizontal-list': 'w-6',
5
+ 'vertical-list': 'h-6',
6
+ };
7
+ const dotStyle = 'cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white';
8
+ const inactiveDotStyle = 'w-2 h-2 opacity-30';
9
+ export const renderDotButton = ({ activeIndex, onClick, listType = 'horizontal-list' }) => (_, idx) => (_jsx("div", { className: style(dotStyle, idx === activeIndex ? activeDotStyles[listType] : inactiveDotStyle), role: "button", "aria-hidden": true, onClick: () => onClick(idx) }, String(idx)));
10
+ //# sourceMappingURL=renderDotButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renderDotButton.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/renderDotButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAI1C,MAAM,eAAe,GAAyC;IAC5D,iBAAiB,EAAE,KAAK;IACxB,eAAe,EAAE,KAAK;CACvB,CAAC;AAEF,MAAM,QAAQ,GACZ,yGAAyG,CAAC;AAE5G,MAAM,gBAAgB,GAAG,oBAAoB,CAAC;AAE9C,MAAM,CAAC,MAAM,eAAe,GAC1B,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,GAAG,iBAAiB,EAAW,EAAE,EAAE,CACpE,CAAC,CAAM,EAAE,GAAW,EAAE,EAAE,CACtB,CACE,cAEE,SAAS,EAAE,KAAK,CACd,QAAQ,EACR,GAAG,KAAK,WAAW,CAAC,CAAC,CAAC,eAAe,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,gBAAgB,CACnE,EACD,IAAI,EAAC,QAAQ,uBAEb,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,IAPtB,MAAM,CAAC,GAAG,CAAC,CAQhB,CACH,CAAC"}
@@ -0,0 +1,2 @@
1
+ import { type DotProp, type NavButtonProp } from './NavButtonProp';
2
+ export declare const renderNavButton: ({ activeIndex, onClick }: DotProp) => (nav: NavButtonProp, i: number) => JSX.Element;
@@ -0,0 +1,14 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
2
+ import { style } from '../../utils/style.js';
3
+ export const renderNavButton = ({ activeIndex, onClick }) => (nav, i) => {
4
+ const isActive = i === activeIndex;
5
+ const btnClassName = isActive
6
+ ? 'min-w-[350px] bg-white shadow-dark-blue border-none p-6'
7
+ : 'min-w-72 ease-in duration-300 bg-white/10 px-xl py-lg hover:backdrop-blur';
8
+ const btnTitleClassName = isActive
9
+ ? 'text-primary-text text-h6 py-xs'
10
+ : 'text-l pb-2xs text-secondary-text group-data-secondary:text-white';
11
+ const btnDescClassName = isActive ? 'text-l' : 'text-m group-data-secondary:text-white/80';
12
+ return (_jsxs("button", { type: "button", onClick: () => onClick(i), "aria-label": nav?.title, className: style('max-h-28 mt-xs ml-xs relative px-xl box-border overflow-hidden text-left grow basis-0 border border-gray group-data-secondary:border-white/50 whitespace-nowrap', btnClassName), children: [_jsx("div", { className: btnTitleClassName, children: nav?.title }), _jsx("div", { className: style('text-secondary-text font-light', btnDescClassName), children: nav?.description })] }, String(i)));
13
+ };
14
+ //# sourceMappingURL=renderNavButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renderNavButton.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/renderNavButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAG1C,MAAM,CAAC,MAAM,eAAe,GAC1B,CAAC,EAAE,WAAW,EAAE,OAAO,EAAW,EAAE,EAAE,CACtC,CAAC,GAAkB,EAAE,CAAS,EAAE,EAAE;IAChC,MAAM,QAAQ,GAAG,CAAC,KAAK,WAAW,CAAC;IACnC,MAAM,YAAY,GAAG,QAAQ;QAC3B,CAAC,CAAC,yDAAyD;QAC3D,CAAC,CAAC,2EAA2E,CAAC;IAChF,MAAM,iBAAiB,GAAG,QAAQ;QAChC,CAAC,CAAC,iCAAiC;QACnC,CAAC,CAAC,mEAAmE,CAAC;IACxE,MAAM,gBAAgB,GAAG,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,2CAA2C,CAAC;IAE3F,OAAO,CACL,kBACE,IAAI,EAAC,QAAQ,EAEb,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC,gBACb,GAAG,EAAE,KAAK,EACtB,SAAS,EAAE,KAAK,CACd,iKAAiK,EACjK,YAAY,CACb,aAED,cAAK,SAAS,EAAE,iBAAiB,YAAG,GAAG,EAAE,KAAK,GAAO,EACrD,cAAK,SAAS,EAAE,KAAK,CAAC,gCAAgC,EAAE,gBAAgB,CAAC,YACtE,GAAG,EAAE,WAAW,GACb,KAXD,MAAM,CAAC,CAAC,CAAC,CAYP,CACV,CAAC;AACJ,CAAC,CAAC"}
@@ -11,7 +11,7 @@ export const useSwipeListScroll = ({ itemCount, onVisibleIndicesChange, }) => {
11
11
  const handleVisibleIndicesChange = useCallback((indices) => {
12
12
  setVisibleIndices((prevIndices) => areArraysEqual(prevIndices, indices) ? prevIndices : indices);
13
13
  onVisibleIndicesChange && onVisibleIndicesChange(indices);
14
- }, [itemCount]);
14
+ }, [onVisibleIndicesChange]);
15
15
  const [minIndex, maxIndex] = visibleIndices.length
16
16
  ? [minBy()(visibleIndices), maxBy()(visibleIndices)]
17
17
  : [-1, -1];
@@ -1 +1 @@
1
- {"version":3,"file":"useSwipeListScroll.js","sourceRoot":"","sources":["../../../src/ui-kit/SwipeListControl/useSwipeListScroll.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAC5E,OAAO,EAAE,cAA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