@redneckz/wildless-cms-uni-blocks 0.6.50 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +71 -19
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/bundle/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  5. package/bundle/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  6. package/bundle/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  7. package/bundle/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  8. package/bundle/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  9. package/bundle/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  10. package/bundle/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  11. package/bundle/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  12. package/bundle/utils/style.d.ts +1 -0
  13. package/dist/components/Blocks.js +2 -0
  14. package/dist/components/Blocks.js.map +1 -1
  15. package/dist/components/CarouselCard/CarouselCard.js +2 -2
  16. package/dist/components/CarouselCard/CarouselCard.js.map +1 -1
  17. package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +1 -1
  18. package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  19. package/dist/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  20. package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +12 -9
  21. package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  22. package/dist/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  23. package/dist/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  24. package/dist/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  25. package/dist/components/SwipeListControlBlock/SwipeListControlBlock.js +14 -0
  26. package/dist/components/SwipeListControlBlock/SwipeListControlBlock.js.map +1 -0
  27. package/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  28. package/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.js +2 -0
  29. package/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.js.map +1 -0
  30. package/dist/ui-kit/BlockWrapper.js +1 -1
  31. package/dist/ui-kit/BlockWrapper.js.map +1 -1
  32. package/dist/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  33. package/dist/ui-kit/SwipeListControl/SwipeListContainer.js +8 -5
  34. package/dist/ui-kit/SwipeListControl/SwipeListContainer.js.map +1 -1
  35. package/dist/ui-kit/SwipeListControl/SwipeListControl.js +3 -2
  36. package/dist/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  37. package/dist/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  38. package/dist/ui-kit/SwipeListControl/SwipeListControlDots.js +12 -3
  39. package/dist/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
  40. package/dist/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  41. package/dist/utils/style.d.ts +1 -0
  42. package/dist/utils/style.js +5 -0
  43. package/dist/utils/style.js.map +1 -0
  44. package/lib/common.css +1 -1
  45. package/lib/components/Blocks.js +2 -0
  46. package/lib/components/Blocks.js.map +1 -1
  47. package/lib/components/CarouselCard/CarouselCard.js +2 -2
  48. package/lib/components/CarouselCard/CarouselCard.js.map +1 -1
  49. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +1 -1
  50. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  51. package/lib/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  52. package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +12 -9
  53. package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  54. package/lib/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  55. package/lib/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  56. package/lib/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  57. package/lib/components/SwipeListControlBlock/SwipeListControlBlock.fixture.d.ts +5 -0
  58. package/lib/components/SwipeListControlBlock/SwipeListControlBlock.js +12 -0
  59. package/lib/components/SwipeListControlBlock/SwipeListControlBlock.js.map +1 -0
  60. package/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  61. package/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.js +2 -0
  62. package/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.js.map +1 -0
  63. package/lib/ui-kit/BlockWrapper.js +1 -1
  64. package/lib/ui-kit/BlockWrapper.js.map +1 -1
  65. package/lib/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  66. package/lib/ui-kit/SwipeListControl/SwipeListContainer.js +8 -5
  67. package/lib/ui-kit/SwipeListControl/SwipeListContainer.js.map +1 -1
  68. package/lib/ui-kit/SwipeListControl/SwipeListControl.fixture.mobile.d.ts +1 -0
  69. package/lib/ui-kit/SwipeListControl/SwipeListControl.js +3 -2
  70. package/lib/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  71. package/lib/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  72. package/lib/ui-kit/SwipeListControl/SwipeListControlDots.js +12 -3
  73. package/lib/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
  74. package/lib/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  75. package/lib/utils/style.d.ts +1 -0
  76. package/lib/utils/style.js +2 -0
  77. package/lib/utils/style.js.map +1 -0
  78. package/mobile/bundle/bundle.umd.js +25 -12
  79. package/mobile/bundle/bundle.umd.min.js +1 -1
  80. package/mobile/bundle/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  81. package/mobile/bundle/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  82. package/mobile/bundle/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  83. package/mobile/bundle/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  84. package/mobile/bundle/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  85. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  86. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  87. package/mobile/bundle/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  88. package/mobile/bundle/utils/style.d.ts +1 -0
  89. package/mobile/dist/components/CarouselCard/CarouselCard.js +2 -2
  90. package/mobile/dist/components/CarouselCard/CarouselCard.js.map +1 -1
  91. package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +1 -1
  92. package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  93. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  94. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +12 -9
  95. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  96. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  97. package/mobile/dist/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  98. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  99. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlock.js +14 -0
  100. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlock.js.map +1 -0
  101. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  102. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.js +2 -0
  103. package/mobile/dist/components/SwipeListControlBlock/SwipeListControlBlockContent.js.map +1 -0
  104. package/mobile/dist/ui-kit/BlockWrapper.js +1 -1
  105. package/mobile/dist/ui-kit/BlockWrapper.js.map +1 -1
  106. package/mobile/dist/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  107. package/mobile/dist/ui-kit/SwipeListControl/SwipeListContainer.js +8 -5
  108. package/mobile/dist/ui-kit/SwipeListControl/SwipeListContainer.js.map +1 -1
  109. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControl.js +3 -2
  110. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  111. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  112. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlDots.js +12 -3
  113. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
  114. package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  115. package/mobile/dist/utils/style.d.ts +1 -0
  116. package/mobile/dist/utils/style.js +5 -0
  117. package/mobile/dist/utils/style.js.map +1 -0
  118. package/mobile/lib/components/CarouselCard/CarouselCard.js +2 -2
  119. package/mobile/lib/components/CarouselCard/CarouselCard.js.map +1 -1
  120. package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +1 -1
  121. package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  122. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.d.ts +1 -1
  123. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +12 -9
  124. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  125. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +1 -1
  126. package/mobile/lib/components/LinkDocs/LinkDocsContent.d.ts +4 -0
  127. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlock.d.ts +6 -0
  128. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlock.js +12 -0
  129. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlock.js.map +1 -0
  130. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.d.ts +5 -0
  131. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.js +2 -0
  132. package/mobile/lib/components/SwipeListControlBlock/SwipeListControlBlockContent.js.map +1 -0
  133. package/mobile/lib/ui-kit/BlockWrapper.js +1 -1
  134. package/mobile/lib/ui-kit/BlockWrapper.js.map +1 -1
  135. package/mobile/lib/ui-kit/SwipeListControl/SwipeListContainer.d.ts +2 -1
  136. package/mobile/lib/ui-kit/SwipeListControl/SwipeListContainer.js +8 -5
  137. package/mobile/lib/ui-kit/SwipeListControl/SwipeListContainer.js.map +1 -1
  138. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControl.js +3 -2
  139. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControl.js.map +1 -1
  140. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlDots.d.ts +2 -0
  141. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlDots.js +12 -3
  142. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
  143. package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlProps.d.ts +7 -0
  144. package/mobile/lib/utils/style.d.ts +1 -0
  145. package/mobile/lib/utils/style.js +2 -0
  146. package/mobile/lib/utils/style.js.map +1 -0
  147. package/mobile/src/common.css +11 -0
  148. package/mobile/src/components/Carousel/Carousel.ui.json +8 -0
  149. package/mobile/src/components/CarouselCard/CarouselCard.tsx +11 -5
  150. package/mobile/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +1 -1
  151. package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCard.example.json +11 -3
  152. package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +29 -17
  153. package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCardContent.ts +1 -1
  154. package/mobile/src/components/LinkDocs/LinkDocsContent.ts +4 -0
  155. package/mobile/src/components/SwipeListControlBlock/SwipeListControlBlock.example.json +18 -0
  156. package/mobile/src/components/SwipeListControlBlock/SwipeListControlBlock.tsx +23 -0
  157. package/mobile/src/components/SwipeListControlBlock/SwipeListControlBlock.ui.json +1 -0
  158. package/mobile/src/components/SwipeListControlBlock/SwipeListControlBlockContent.ts +6 -0
  159. package/mobile/src/ui-kit/BlockWrapper.tsx +1 -1
  160. package/mobile/src/ui-kit/SwipeListControl/SwipeListContainer.tsx +19 -10
  161. package/mobile/src/ui-kit/SwipeListControl/SwipeListControl.tsx +6 -2
  162. package/mobile/src/ui-kit/SwipeListControl/SwipeListControlDots.tsx +20 -4
  163. package/mobile/src/ui-kit/SwipeListControl/SwipeListControlProps.ts +8 -0
  164. package/mobile/src/utils/style.ts +2 -0
  165. package/package.json +2 -2
  166. package/src/common.css +11 -0
  167. package/src/components/Blocks.ts +2 -0
  168. package/src/components/Carousel/Carousel.ui.json +8 -0
  169. package/src/components/CarouselCard/CarouselCard.tsx +11 -5
  170. package/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +1 -1
  171. package/src/components/CarouselTariffsCard/CarouselTariffsCard.example.json +11 -3
  172. package/src/components/CarouselTariffsCard/CarouselTariffsCard.fixture.tsx +3 -3
  173. package/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +29 -17
  174. package/src/components/CarouselTariffsCard/CarouselTariffsCardContent.ts +1 -1
  175. package/src/components/LinkDocs/LinkDocsContent.ts +4 -0
  176. package/src/components/SwipeListControlBlock/SwipeListControlBlock.example.json +18 -0
  177. package/src/components/SwipeListControlBlock/SwipeListControlBlock.fixture.tsx +27 -0
  178. package/src/components/SwipeListControlBlock/SwipeListControlBlock.tsx +23 -0
  179. package/src/components/SwipeListControlBlock/SwipeListControlBlock.ui.json +1 -0
  180. package/src/components/SwipeListControlBlock/SwipeListControlBlockContent.ts +6 -0
  181. package/src/icons/IconName.ts +333 -6
  182. package/src/ui-kit/BlockWrapper.tsx +1 -1
  183. package/src/ui-kit/SwipeListControl/SwipeListContainer.tsx +19 -10
  184. package/src/ui-kit/SwipeListControl/SwipeListControl.fixture.mobile.tsx +6 -1
  185. package/src/ui-kit/SwipeListControl/SwipeListControl.tsx +6 -2
  186. package/src/ui-kit/SwipeListControl/SwipeListControlDots.tsx +20 -4
  187. package/src/ui-kit/SwipeListControl/SwipeListControlProps.ts +8 -0
  188. package/src/utils/style.ts +2 -0
@@ -393,7 +393,7 @@
393
393
  return ref;
394
394
  }
395
395
 
396
- const BlockWrapper = JSX(({ className, block, tag = 'section', role, children }) => {
396
+ const BlockWrapper = JSX(({ className = '', block, tag = 'section', role, children }) => {
397
397
  const Tag = tag;
398
398
  const ref = useBlockIntersectionObserver(block);
399
399
  const [isVisible, setVisible] = useState(true);
@@ -1447,6 +1447,8 @@
1447
1447
  return Array.isArray(children) ? children.map(mapper) : mapper(children, 0);
1448
1448
  };
1449
1449
 
1450
+ const style = (...atoms) => atoms.filter(Boolean).join(' ');
1451
+
1450
1452
  const SwipeListItem = JSX(({ className = '', style, idx, activeIndex, observerOptions, children, onIntersection }) => {
1451
1453
  const observerCallback = useCallback((entries) => {
1452
1454
  if (entries.length && onIntersection) {
@@ -1458,7 +1460,7 @@
1458
1460
  });
1459
1461
 
1460
1462
  const childStyleMap = ['min-w-[100%]', 'min-w-[50%]', 'min-w-[33.33%]', 'min-w-[25%]'];
1461
- const SwipeListContainer = JSX(({ className = '', containerRef, activeIndex, visibleItemCount = 0, gap = 0, padding = 0, snapAlign = 'snap-center', children, onVisibleItemsChange, onVisibleIndicesChange, }) => {
1463
+ const SwipeListContainer = JSX(({ className = '', containerRef, activeIndex, visibleItemCount = 0, gap = 0, padding = 0, listType = 'horizontal-list', snapAlign = 'snap-center', children, onVisibleItemsChange, onVisibleIndicesChange, }) => {
1462
1464
  const observerOptions = {
1463
1465
  sensitivity: 1,
1464
1466
  rootRef: containerRef,
@@ -1472,10 +1474,12 @@
1472
1474
  onVisibleIndicesChange && onVisibleIndicesChange(getVisibleIndices(itemsVisibilityList));
1473
1475
  }, [onVisibleItemsChange, onVisibleIndicesChange]);
1474
1476
  const additionPadding = visibleItemCount > 0 ? gap * Number(visibleItemCount) - 1 : 0;
1475
- return (jsx("div", { className: `box-border overflow-auto flex horizontal-list no-scrollbar ${className}`, style: {
1476
- ...getContainerStyle(padding, additionPadding),
1477
- gap: `${gap}px`,
1478
- }, role: "list", ref: containerRef, children: mapChildren((child, idx) => (jsx(SwipeListItem, { className: `${snapAlign} ${visibleItemCount ? childStyleMap[visibleItemCount - 1] : ''}`, style: getContainerStyle(padding / 4), activeIndex: activeIndex, idx: idx, observerOptions: observerOptions, onIntersection: handleIntersection, children: child }, String(idx))))(children) }));
1477
+ const isHorizontalList = listType === 'horizontal-list';
1478
+ const containerStyle = {
1479
+ ...(isHorizontalList ? getContainerStyle(padding, additionPadding) : {}),
1480
+ gap: `${gap}px`,
1481
+ };
1482
+ return (jsx("div", { className: style('box-border overflow-auto no-scrollbar', listType, className), style: containerStyle, role: "list", ref: containerRef, children: mapChildren((child, idx) => (jsx(SwipeListItem, { className: style(snapAlign, visibleItemCount ? childStyleMap[visibleItemCount - 1] : '', listType === 'vertical-list' ? 'h-full' : ''), style: isHorizontalList ? getContainerStyle(padding / 4) : {}, activeIndex: activeIndex, idx: idx, observerOptions: observerOptions, onIntersection: handleIntersection, children: child }, String(idx))))(children) }));
1479
1483
  });
1480
1484
  // Styles used to compensate outer container padding to get rid of clipping effect
1481
1485
  const getContainerStyle = (padding, additionalPadding = 0) => ({
@@ -1582,10 +1586,10 @@
1582
1586
 
1583
1587
  const BLOCK_CLASSES = 'absolute border border-solid border-gray w-full h-full';
1584
1588
  const CARD_WIDTH_MAP = {
1585
- normal: 'min-w-[1007px]',
1589
+ normal: 'min-w-[970px]',
1586
1590
  mini: 'min-w-[355px]',
1587
1591
  };
1588
- const CarouselCard = JSX(({ className = '', button, description, title, version = 'normal' }) => (jsx("section", { className: `flex pb-9 pl-12 ${CARD_WIDTH_MAP[version]} ${className}`, children: jsxs("div", { className: "relative w-full", children: [jsx("div", { className: `${BLOCK_CLASSES} z-10 top-9 right-12 bg-green-dark` }), jsx("div", { className: `${BLOCK_CLASSES} z-10 top-6 right-8 bg-green` }), jsx("div", { className: `${BLOCK_CLASSES} z-10 top-3 right-4 bg-green-light` }), jsxs("div", { className: "relative bg-white z-10 py-6 px-10 border border-solid border-green-light", children: [jsx(Headline, { className: "!p-0", title: title, description: description, headlineVersion: "M" }), button ? jsx("div", { className: "mt-6", children: renderButton({ button }) }) : null] })] }) })));
1592
+ const CarouselCard = JSX(({ className = '', button, description, title, version = 'normal' }) => (jsx("section", { className: `flex pb-9 pl-12 border-box ${CARD_WIDTH_MAP[version]} ${className}`, children: jsxs("div", { className: "relative w-full", children: [jsx("div", { className: `${BLOCK_CLASSES} z-10 top-9 right-12 bg-green-dark` }), jsx("div", { className: `${BLOCK_CLASSES} z-10 top-6 right-8 bg-green` }), jsx("div", { className: `${BLOCK_CLASSES} z-10 top-3 right-4 bg-green-light` }), jsxs("div", { className: "relative bg-white z-10 p-10 border border-solid border-green-light", children: [jsx(Headline, { className: "!p-0", title: title, description: description, headlineVersion: "L", align: "text-left" }), button ? jsx("div", { className: "mt-14", children: renderButton({ button }) }) : null] })] }) })));
1589
1593
 
1590
1594
  const cardStyleMap$2 = {
1591
1595
  black: 'bg-black',
@@ -1700,7 +1704,7 @@
1700
1704
  const renderAdditionalDescription$2 = (additionalDescription, version = 'primary') => additionalDescription ? (jsx("div", { className: "mt-auto", children: jsx(Text, { size: "text-m", font: "font-light", color: descriptionStyleMap[version], children: additionalDescription }) })) : null;
1701
1705
  const renderItems$2 = (items, isDotted, version = 'primary') => items?.length ? (jsx(List, { className: `max-w-[308px] mt-2 text-s ${version === 'primary' ? '!text-secondary-text' : ''}`, itemClassName: "text-left", items: items.filter((item) => item?.text).map((item) => item.text), isDotted: isDotted, version: version })) : null;
1702
1706
 
1703
- const CarouselProgramsCard = JSX(({ className = '', title, icon, list = [], version = 'primary', ...rest }) => (jsxs(BlockWrapper, { className: `font-sans border border-gray flex min-w-[536px] ${VersionStyleMap[version]} ${className}`, ...rest, children: [jsxs("div", { className: "w-[200px] min-w-[200px] self-end", children: [icon?.icon ? jsx(ImgInner, { image: getIconWithVersion(icon), asSVG: true }) : null, icon?.src ? jsx(ImgInner, { image: icon }) : null] }), jsxs("div", { className: "p-8 pl-3 w-full", children: [title ? jsx(Heading, { className: " mb-3.5", headingType: "h5", title: title }) : null, list.length ? jsx("div", { className: "flex flex-col gap-3", children: list?.map(renderList$2) }) : null] })] })));
1707
+ const CarouselProgramsCard = JSX(({ className = '', title, icon, list = [], version = 'primary', ...rest }) => (jsxs(BlockWrapper, { className: `font-sans border border-gray flex min-w-[536px] ${VersionStyleMap[version]} ${className}`, ...rest, children: [jsxs("div", { className: "w-[200px] min-w-[200px] self-center", children: [icon?.icon ? jsx(ImgInner, { image: getIconWithVersion(icon), asSVG: true }) : null, icon?.src ? jsx(ImgInner, { image: icon }) : null] }), jsxs("div", { className: "p-8 pl-3 w-full", children: [title ? jsx(Heading, { className: " mb-3.5", headingType: "h5", title: title }) : null, list.length ? jsx("div", { className: "flex flex-col gap-3", children: list?.map(renderList$2) }) : null] })] })));
1704
1708
  const renderList$2 = (_, i) => (jsxs("div", { className: "break-words", children: [_.title ? jsx("div", { className: `text-h6`, children: _.title }) : null, _.description ? jsx("span", { className: "text-l-light mt-1", children: _.description }) : null] }, String(i)));
1705
1709
 
1706
1710
  const ICONS_MAP = [
@@ -1761,19 +1765,20 @@
1761
1765
  });
1762
1766
  const getOmitVersion = (version) => version === 'gray' ? 'primary' : version;
1763
1767
 
1764
- const VISIBLE_ROWS_COUNT = 1;
1765
- const CarouselTariffsCard = JSX(({ className = '', title, icon, isHighlighting, button, rows = [], ...rest }) => {
1766
- const rowsNode = rows.map(renderCardInfo);
1767
- const visibleRows = rowsNode.slice(0, VISIBLE_ROWS_COUNT);
1768
- const hiddenRows = rowsNode.slice(VISIBLE_ROWS_COUNT);
1769
- return (jsxs(BlockWrapper, { className: `font-sans relative bg-white border border-gray min-w-[322px] p-8
1768
+ const VISIBLE_CELLS_COUNT = 1;
1769
+ const CarouselTariffsCard = JSX(({ className = '', title, icon, isHighlighting, button, cardCells = [], ...rest }) => {
1770
+ const cellsNode = cardCells.map(renderCardInfo);
1771
+ const visibleCells = cellsNode.slice(0, VISIBLE_CELLS_COUNT);
1772
+ const hiddenCells = cellsNode.slice(VISIBLE_CELLS_COUNT);
1773
+ return (jsxs(BlockWrapper, { className: `font-sans relative bg-white border border-gray min-w-[322px] p-8 flex flex-col
1770
1774
  ${getHitStyle(isHighlighting)}
1771
- ${className}`, ...rest, children: [isHighlighting ? renderHitIcon() : null, icon?.src ? jsx(ImgInner, { image: icon }) : null, title ? (jsx(Heading, { className: "text-primary-text text-center pt-2", headingType: "h5", title: title })) : null, button ? jsx(Button, { className: "w-full mt-4", ...button }) : null, rows.length ? (jsx(Foldable, { renderFoldableSection: ({ isUnfolded }) => (jsxs("div", { children: [visibleRows, jsx(FoldableSection, { isUnfolded: isUnfolded, children: hiddenRows })] })), renderFoldButton: rows.length > 1 ? renderFoldButton$1 : null })) : null] }));
1775
+ ${className}`, ...rest, children: [isHighlighting ? renderHitIcon() : null, renderIconBlock(icon), title ? (jsx(Heading, { className: "text-primary-text text-center pt-2", headingType: "h5", title: title })) : null, button ? jsx(Button, { className: "w-full mt-4", ...button }) : null, cardCells.length ? (jsx(Foldable, { renderFoldableSection: ({ isUnfolded }) => (jsxs("div", { children: [visibleCells, jsx(FoldableSection, { isUnfolded: isUnfolded, children: hiddenCells })] })), renderFoldButton: cardCells.length > 1 ? renderFoldButton$1 : null })) : null] }));
1772
1776
  });
1773
- const getHitStyle = (isHighlighting) => isHighlighting ? 'mt-9 pt-[70px]' : 'mt-[70px] pt-9';
1777
+ const renderIconBlock = (icon) => (jsxs("div", { className: "w-[267px] min-w-[267px] self-center", children: [icon?.src ? jsx(ImgInner, { image: icon }) : null, icon?.icon ? jsx(ImgInner, { image: getIconWithVersion(icon), asSVG: true }) : null] }));
1778
+ const getHitStyle = (isHighlighting) => isHighlighting ? 'mt-9 pt-[70px]' : 'mt-[70px] pt-7';
1774
1779
  const renderFoldButton$1 = ({ isUnfolded, onToggle }) => (jsxs("button", { className: "w-full cursor-pointer text-primary-main pt-5 flex justify-between items-center", onClick: onToggle, children: [jsx("div", { children: isUnfolded ? 'Скрыть' : 'Подробнее о тарифе' }), jsx(Icon, { className: "text-primary-text", name: isUnfolded ? 'ArrowUpIcon' : 'ArrowDownIcon', width: "16", height: "16", asSVG: true })] }));
1775
1780
  const renderCardInfo = (cell, i) => (jsxs("div", { className: "py-5 border-b border-main-divider", children: [cell?.title ? (jsx("div", { className: "text-secondary-text text-m-light opacity-80", children: cell.title })) : null, cell?.description ? (jsx("div", { className: "text-primary-text text-h6 mt-1", children: cell.description })) : null] }, String(i)));
1776
- const renderHitIcon = () => (jsxs("div", { className: "absolute -top-7 -right-4 h-[60px] w-[60px] bg-white flex flex-col items-center justify-center shadow-[0_4px_25px_rgba(0,0,0,0.07)]", children: [jsx(Icon, { iconVersion: "black", name: "HeartIcon", width: "23", height: "22", asSVG: true }), jsx("div", { className: "text-center", children: "\u0425\u0438\u0442" })] }));
1781
+ const renderHitIcon = () => (jsxs("div", { className: "absolute -top-7 -right-4 h-[60px] w-[60px] bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]", children: [jsx(Icon, { iconVersion: "black", name: "HeartIcon", width: "23", height: "22", asSVG: true }), jsx(Paragraph, { size: "text-s", font: "font-normal", align: "text-center", color: "text-primary-text", children: "\u0425\u0418\u0422" })] }));
1777
1782
 
1778
1783
  const cardStyleMap$1 = {
1779
1784
  black: 'bg-black',
@@ -3654,6 +3659,52 @@
3654
3659
  const renderStepIcon = (styleMap, version) => ({ icon }, i) => (jsx("div", { className: "flex flex-col items-center text-center", children: jsx("div", { className: `h-[100px] w-[100px] min-w-[100px] min-h-[100px] rounded-full p-[26px] box-border z-10 flex justify-center items-center
3655
3660
  ${styleMap.iconBackground} ${styleMap.title}`, children: checkIsIconRenderable(icon) ? (jsx(ImgInner, { image: getIconWithVersion(icon || {}, version), width: "48", height: "48", asSVG: true })) : (jsx("span", { className: `text-h4 ${styleMap.iconText}`, children: i + 1 })) }) }, String(i)));
3656
3661
 
3662
+ const containerStyles = {
3663
+ 'horizontal-list': 'mx-auto mt-5 w-fit',
3664
+ 'vertical-list': 'absolute flex-col justify-center h-full top-0 left-4',
3665
+ };
3666
+ const activeDotStyles = {
3667
+ 'horizontal-list': 'w-6',
3668
+ 'vertical-list': 'h-6',
3669
+ };
3670
+ const dotStyle = 'cursor-pointer bg-primary-main rounded-full transition-width duration-300';
3671
+ const inactiveDotStyle = 'w-2 h-2 opacity-30';
3672
+ const SwipeListControlDots = JSX(({ containerRef, activeIndex, dotCount = 0, listType = 'horizontal-list' }) => {
3673
+ const handleClick = (idx) => {
3674
+ if (idx !== activeIndex && containerRef?.current) {
3675
+ containerRef.current.children[idx]?.scrollIntoView({
3676
+ behavior: 'smooth',
3677
+ block: 'nearest',
3678
+ });
3679
+ }
3680
+ };
3681
+ return dotCount ? (jsx("div", { className: `flex gap-2 ${containerStyles[listType]}`, children: new Array(dotCount).fill(null).map((_, idx) => (jsx("div", { className: `${dotStyle} ${idx === activeIndex ? activeDotStyles[listType] : inactiveDotStyle}`, role: "button", "aria-hidden": true, onClick: () => handleClick(idx) }, String(idx)))) })) : null;
3682
+ });
3683
+
3684
+ const DEFAULT_GAP = 14;
3685
+ /*
3686
+ Horizontal padding used on a container above SwipeListControl.
3687
+ Same value used on a SwipeListControlChildren container to compensate it
3688
+ and get rid of a clipping effect caused by overflow: hidden.
3689
+ */
3690
+ const DEFAULT_PADDING = 16;
3691
+ const SwipeListControl = JSX(({ className = '', gap = DEFAULT_GAP, padding = DEFAULT_PADDING, showDots = true, children, onVisibleIndicesChange, listType = 'horizontal-list', }) => {
3692
+ const itemCount = Array.isArray(children) ? children.length : 0;
3693
+ const [containerRef, scroll] = useSwipeListScroll({
3694
+ itemCount,
3695
+ onVisibleIndicesChange,
3696
+ });
3697
+ const [activeIndex] = scroll.visibleIndicesRange;
3698
+ return (jsxs("div", { className: style(className, listType === 'vertical-list' ? 'relative h-full' : ''), children: [jsx(SwipeListContainer, { containerRef: containerRef, activeIndex: activeIndex, visibleItemCount: 1, gap: gap, padding: padding, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, listType: listType, children: children }), showDots ? (jsx(SwipeListControlDots, { containerRef: containerRef, activeIndex: activeIndex, dotCount: itemCount, listType: listType })) : null] }));
3699
+ });
3700
+
3701
+ const SwipeListControlBlock = JSX(({ gap, listType, padding, showDots, options, ...rest }) => {
3702
+ return (jsx(BlockWrapper, { ...rest, children: jsx(SwipeListControl, { gap: gap, listType: listType, padding: padding, showDots: showDots, children: renderChildren({ ...rest, options }) }) }));
3703
+ });
3704
+ SwipeListControlBlock.childrenTypes = {
3705
+ exclude: ['SwipeListControlBlock'],
3706
+ };
3707
+
3657
3708
  const LINK_CLASSES = 'h-12 flex-1 flex items-center justify-center cursor-pointer';
3658
3709
  const ACTIVE_LINK_CLASSES = 'bg-primary-main';
3659
3710
  const INACTIVE_LINK_CLASSES = 'group bg-white';
@@ -4017,6 +4068,7 @@
4017
4068
  RollupItem,
4018
4069
  SafeDepositRental,
4019
4070
  StepsBlock,
4071
+ SwipeListControlBlock,
4020
4072
  Tabs,
4021
4073
  TariffsTable,
4022
4074
  TextBlock,
@@ -4150,7 +4202,7 @@
4150
4202
  return (jsx("div", { className: "flex items-end absolute bottom-0 right-0 h-full pointer-events-none", children: jsx(LikeControl, { className: "rounded-tl-lg sticky bottom-0 pointer-events-auto" }) }));
4151
4203
  }
4152
4204
 
4153
- const packageVersion = "0.6.50";
4205
+ const packageVersion = "0.7.1";
4154
4206
 
4155
4207
  exports.Blocks = Blocks;
4156
4208
  exports.ContentPage = ContentPage;