md-components-mdigial-azamat 0.0.109 → 0.0.113

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 (166) hide show
  1. package/dist/ActionCardList/ActionCardList.js +32 -7
  2. package/dist/ActionCardList/index.js +1 -1
  3. package/dist/ActionCardList/info.js +1 -1
  4. package/dist/ActionCardSecondaryList/ActionCardSecondaryList.js +32 -0
  5. package/dist/ActionCardSecondaryList/index.js +6 -0
  6. package/dist/ActionCardSecondaryList/info.js +11 -0
  7. package/dist/ActionCardSecondaryList/schema.js +51 -0
  8. package/dist/ActionCardSecondaryList/types.js +4 -0
  9. package/dist/ActionIconList/ActionIconList.js +29 -4
  10. package/dist/AllComponents.js +35 -9
  11. package/dist/AllComponentsInfo.js +107 -89
  12. package/dist/AnimatedSwiper/index.js +40 -38
  13. package/dist/ButtonsList/ButtonsList.js +25 -19
  14. package/dist/CardImageList/CardImageList.js +130 -73
  15. package/dist/CardImageList/info.js +1 -1
  16. package/dist/CardImageList/schema.js +62 -0
  17. package/dist/Cards/ActionSecondaryCard/ActionSecondaryCard.js +77 -0
  18. package/dist/Cards/ActionSecondaryCard/index.js +6 -0
  19. package/dist/Cards/ActionSecondaryCard/info.js +11 -0
  20. package/dist/Cards/ActionSecondaryCard/types.js +4 -0
  21. package/dist/Cards/CardImage/CardImage.js +100 -55
  22. package/dist/Cards/CardImage/index.js +6 -1
  23. package/dist/Cards/CardImage/info.js +1 -1
  24. package/dist/Cards/CardImage/schema.js +32 -0
  25. package/dist/Cards/CardImage/types.js +3 -2
  26. package/dist/Cards/InfoCard/InfoCard.js +114 -0
  27. package/dist/Cards/InfoCard/index.js +9 -0
  28. package/dist/Cards/InfoCard/info.js +11 -0
  29. package/dist/Cards/InfoCard/schema.js +60 -0
  30. package/dist/Cards/InfoCard/types.js +4 -0
  31. package/dist/Cards/PostCard/PostCard.js +60 -0
  32. package/dist/Cards/PostCard/index.js +6 -0
  33. package/dist/Cards/PostCard/info.js +11 -0
  34. package/dist/Cards/PostCard/types.js +4 -0
  35. package/dist/Cards/WarningCard/WarningCard.js +31 -6
  36. package/dist/Cards/WarningCard/index.js +1 -1
  37. package/dist/Cards/WarningCard/info.js +1 -1
  38. package/dist/Cards/WarningCard/model.js +1 -1
  39. package/dist/CurrencyRates/CurrencyRates.js +78 -0
  40. package/dist/CurrencyRates/components/Calculator.js +101 -0
  41. package/dist/CurrencyRates/components/RateCell.js +15 -0
  42. package/dist/CurrencyRates/components/RatesTable.js +134 -0
  43. package/dist/CurrencyRates/components/index.js +6 -0
  44. package/dist/CurrencyRates/index.js +8 -0
  45. package/dist/CurrencyRates/info.js +11 -0
  46. package/dist/CurrencyRates/schema.js +63 -0
  47. package/dist/CurrencyRates/types.js +4 -0
  48. package/dist/DownloadFile/components/DownloadFileBanner/DownloadFileBanner.js +1 -1
  49. package/dist/DownloadFile/components/DownloadFileFull/DownloadFileFull.js +1 -1
  50. package/dist/DownloadFile/components/DownloadFileHalf/DownloadFileHalf.js +1 -1
  51. package/dist/DownloadFile/components/DownloadFileMini/DownloadFileMini.js +1 -1
  52. package/dist/DownloadFile/components/FileBannerSecondary/FileBannerSecondary.js +1 -1
  53. package/dist/Faq/Faq.js +1 -1
  54. package/dist/Faq/components/FeedbackForm/FeedbackForm.js +55 -6
  55. package/dist/Faq/components/FeedbackForm/index.js +1 -1
  56. package/dist/FieldInput-ef2a18d4.js +2743 -0
  57. package/dist/Flex-86aee720.js +78 -0
  58. package/dist/Footer/Footer.js +5 -5
  59. package/dist/Forms/FormDefault/FormDefault.js +12 -0
  60. package/dist/Forms/FormDefault/components/FieldCustom.js +11 -0
  61. package/dist/Forms/FormDefault/components/FieldInput.js +11 -0
  62. package/dist/Forms/FormDefault/components/FieldSection.js +10 -0
  63. package/dist/Forms/FormDefault/components/FormContent.js +10 -0
  64. package/dist/Forms/FormDefault/components/FormFields.js +7 -0
  65. package/dist/Forms/FormDefault/components/FormSuccessMessage.js +49 -0
  66. package/dist/Forms/FormDefault/components/index.js +6 -0
  67. package/dist/Forms/FormDefault/hooks/index.js +10 -0
  68. package/dist/Forms/FormDefault/hooks/useFieldOptions.js +32 -0
  69. package/dist/Forms/FormDefault/hooks/useFieldValidation.js +33 -0
  70. package/dist/Forms/FormDefault/hooks/useFieldVisibility.js +24 -0
  71. package/dist/Forms/FormDefault/hooks/useFormSubmission.js +64 -0
  72. package/dist/Forms/FormDefault/index.js +6 -12
  73. package/dist/Forms/FormDefault/info.js +3 -113
  74. package/dist/Forms/FormDefault/model/componentRegistry.js +134 -0
  75. package/dist/Forms/FormDefault/model/fieldTypes.js +18 -0
  76. package/dist/Forms/FormDefault/model/formElementTypes.js +18 -0
  77. package/dist/Forms/FormDefault/model/index.js +13 -0
  78. package/dist/Forms/FormDefault/model/requestForm.js +4 -0
  79. package/dist/Forms/{model/components.js → FormDefault/schema.js} +36 -7
  80. package/dist/Forms/FormDefault/utils.js +20 -0
  81. package/dist/Grid-331af266.js +80 -0
  82. package/dist/Header/Header.js +54 -42
  83. package/dist/Header/components/HeaderMainMobile/HeaderMainMobile.js +26 -24
  84. package/dist/Header/components/HeaderMobile/HeaderMobile.js +67 -52
  85. package/dist/Header/components/HeaderSearch/HeaderSearch.js +1 -1
  86. package/dist/Header/components/HeaderTab/HeaderTab.js +17 -15
  87. package/dist/Header/components/HeaderTabsMobile/HeaderTabsMobile.js +10 -9
  88. package/dist/Header/components/HeaderWeb/HeaderWeb.js +134 -114
  89. package/dist/Header/components/TabsOutlined/TabsOutlined.js +8 -7
  90. package/dist/HeroIconsBanner/HeroIconsBanner.js +71 -54
  91. package/dist/IconList/IconList.js +59 -33
  92. package/dist/InfoCardList/InfoCardList.js +100 -0
  93. package/dist/InfoCardList/index.js +6 -0
  94. package/dist/InfoCardList/info.js +11 -0
  95. package/dist/InfoCardList/schema.js +39 -0
  96. package/dist/InfoCardList/types.js +1 -0
  97. package/dist/ModalBody/index.js +1 -1
  98. package/dist/PageViewer/renderComponents.js +1 -1
  99. package/dist/PostsList/PostsList.js +78 -0
  100. package/dist/PostsList/index.js +4 -0
  101. package/dist/PostsList/info.js +11 -0
  102. package/dist/PostsList/schema.js +49 -0
  103. package/dist/PostsList/types.js +1 -0
  104. package/dist/PostsSlider/PostsSlider.js +78 -0
  105. package/dist/PostsSlider/index.js +4 -0
  106. package/dist/PostsSlider/info.js +11 -0
  107. package/dist/PostsSlider/schema.js +49 -0
  108. package/dist/PostsSlider/types.js +1 -0
  109. package/dist/PreviewList/PreviewList.js +19 -19
  110. package/dist/PreviewList/components/PreviewCard/PreviewCard.js +29 -29
  111. package/dist/RenderAllComponents/RenderAllComponents.js +1 -1
  112. package/dist/RenderAllComponents/const.js +1 -1
  113. package/dist/SearchBlock/SearchBlock.js +101 -0
  114. package/dist/SearchBlock/index.js +4 -0
  115. package/dist/SearchBlock/info.js +11 -0
  116. package/dist/SearchBlock/schema.js +36 -0
  117. package/dist/SegmentedContent/SegmentedContent.js +160 -0
  118. package/dist/SegmentedContent/components/ContentCard.js +50 -0
  119. package/dist/SegmentedContent/components/index.js +4 -0
  120. package/dist/SegmentedContent/index.js +8 -0
  121. package/dist/SegmentedContent/info.js +12 -0
  122. package/dist/SegmentedContent/schema.js +108 -0
  123. package/dist/SegmentedContent/types.js +1 -0
  124. package/dist/Segments/Segments.js +36 -28
  125. package/dist/Segments/index.js +8 -2
  126. package/dist/Segments/info.js +1 -1
  127. package/dist/Segments/schema.js +21 -0
  128. package/dist/Segments/types.js +4 -1
  129. package/dist/SegmentsIcons/SegmentsIcons.js +92 -0
  130. package/dist/SegmentsIcons/index.js +8 -0
  131. package/dist/SegmentsIcons/info.js +11 -0
  132. package/dist/SegmentsIcons/schema.js +14 -0
  133. package/dist/SegmentsIcons/types.js +1 -0
  134. package/dist/SwiperList/SwiperList.js +13 -11
  135. package/dist/assets/index.css +1 -1
  136. package/dist/{clientApi-642fea4b.js → clientApi-ccb08ba6.js} +7 -7
  137. package/dist/{componentsMap-855b1df7.js → componentsMap-29ccdfcc.js} +6 -3
  138. package/dist/{data.mock-182979d1.js → data.mock-bb32e8ee.js} +485 -133
  139. package/dist/index-0791c17f.js +56 -0
  140. package/dist/index-2ec92a04.js +32 -0
  141. package/dist/{index-497f59a8.js → index-b795390d.js} +23 -20
  142. package/dist/index.esm-0558519f.js +1171 -0
  143. package/dist/{index.module-c8833286.js → index.module-8835bf96.js} +1 -1
  144. package/dist/info-72904479.js +791 -0
  145. package/dist/main.js +151 -116
  146. package/dist/{mousewheel-865ae601.js → mousewheel-afbc6d42.js} +1 -1
  147. package/dist/navigation-266856e7.js +136 -0
  148. package/dist/navigation-cd786a0d.js +133 -0
  149. package/dist/{palette-c2fe86ec.js → palette-256cf77a.js} +3 -1
  150. package/dist/{swiper-react-90953710.js → swiper-react-3c2710e8.js} +695 -825
  151. package/dist/trash/HeroLargeCards/index.js +7 -6
  152. package/dist/types-c3843cc0.js +4 -0
  153. package/dist/useDraggableScroll-440da9b7.js +29 -0
  154. package/dist/useTranslation-d7a3ca6f.js +298 -0
  155. package/package.json +1 -1
  156. package/dist/FileLoader/fileLoader.js +0 -22
  157. package/dist/FileLoader/index.js +0 -8
  158. package/dist/Forms/FormDefault/componentTypes.js +0 -31
  159. package/dist/Forms/FormDefault/fieldTypesList.js +0 -45
  160. package/dist/Forms/helpers/renderFormFields.js +0 -7
  161. package/dist/Forms/model/requestForm.js +0 -4
  162. package/dist/index-6686852d.js +0 -1794
  163. package/dist/index-a0ed2e4a.js +0 -1221
  164. package/dist/info-34fbb2a8.js +0 -1534
  165. package/dist/navigation-b894d0cd.js +0 -183
  166. /package/dist/Forms/{types/formItems.js → FormDefault/model/types.js} +0 -0
@@ -0,0 +1,36 @@
1
+ import { FieldTypes as a } from "../Types/FiledTypes.js";
2
+ const e = [
3
+ "title",
4
+ "placeholder",
5
+ {
6
+ type: "data",
7
+ label: "Стили",
8
+ dataType: "object",
9
+ data: {
10
+ keys: {
11
+ background: a.STRING
12
+ }
13
+ }
14
+ },
15
+ {
16
+ type: "data",
17
+ label: "Теги",
18
+ dataType: "object",
19
+ data: {
20
+ keys: {
21
+ tags: {
22
+ label: "Список тегов",
23
+ dataType: "array",
24
+ type: "items",
25
+ data: {
26
+ label: a.STRING,
27
+ action: a.STRING
28
+ }
29
+ }
30
+ }
31
+ }
32
+ }
33
+ ];
34
+ export {
35
+ e as propsToEdit
36
+ };
@@ -0,0 +1,160 @@
1
+ import { jsx as e, jsxs as i } from "react/jsx-runtime";
2
+ import { useState as d, useEffect as v } from "react";
3
+ import { actionsGenerator as k } from "../Actions/actionsGenerator.js";
4
+ import { SegmentsIcons as S } from "../SegmentsIcons/SegmentsIcons.js";
5
+ import "../SegmentsIcons/schema.js";
6
+ import "../SegmentsIcons/info.js";
7
+ import { Bullet as _ } from "../SwiperList/components/Bullet/Bullet.js";
8
+ import { a as N, b as x } from "../swiper-react-3c2710e8.js";
9
+ import { B as L } from "../index-875e92ce.js";
10
+ import { C as B } from "../ComponentContainer-dca711c6.js";
11
+ import { F as f } from "../Flex-86aee720.js";
12
+ import { G as I } from "../Grid-331af266.js";
13
+ import { c as M } from "../cn-6a4bf187.js";
14
+ import { ContentCard as r } from "./components/ContentCard.js";
15
+ import { propsToEdit as G } from "./schema.js";
16
+ import '../assets/swiper.css';/* empty css */const R = ({
17
+ gradient: c = "",
18
+ color: n,
19
+ className: a,
20
+ size: o = 24
21
+ }) => /* @__PURE__ */ e(
22
+ "div",
23
+ {
24
+ className: M(a),
25
+ style: {
26
+ width: o,
27
+ height: o,
28
+ background: n || c,
29
+ WebkitMaskImage: `url("data:image/svg+xml;utf8, <svg xmlns='http://www.w3.org/2000/svg' width='12' height='22' viewBox='0 0 12 22'> <path fill='black' d='M8.58579 10L0 1.41421L1.41421 0L10 8.58579C10.0128 8.59862 10.0257 8.61144 10.0385 8.62425C10.3384 8.92405 10.6299 9.21542 10.8379 9.48809C11.0724 9.79548 11.2929 10.1934 11.2929 10.7071C11.2929 11.2208 11.0724 11.6187 10.8379 11.9261C10.6299 12.1988 10.3384 12.4901 10.0385 12.7899C10.0257 12.8027 10.0128 12.8156 10 12.8284L1.41421 21.4142L0 20L8.58579 11.4142C8.93911 11.0609 9.13147 10.8655 9.24787 10.713C9.24939 10.711 9.25087 10.709 9.25231 10.7071C9.25087 10.7052 9.24939 10.7032 9.24787 10.7013C9.13147 10.5487 8.93911 10.3533 8.58579 10Z'/> </svg>")`,
30
+ WebkitMaskRepeat: "no-repeat",
31
+ WebkitMaskSize: "contain",
32
+ WebkitMaskPosition: "center"
33
+ }
34
+ }
35
+ ), W = ({ title: c, items: n }) => {
36
+ var p, m, g, h;
37
+ const [a, o] = d(0), [w, u] = d(0), [l, b] = d(null), t = n == null ? void 0 : n[a], C = (n == null ? void 0 : n.map((s) => s.segment)) || [];
38
+ return v(() => {
39
+ l && l.slideTo(0);
40
+ }, [a, l]), n != null && n.length ? /* @__PURE__ */ e(B, { children: /* @__PURE__ */ i(
41
+ f,
42
+ {
43
+ vertical: !0,
44
+ align: "center",
45
+ className: "gap-12 max-tablet:gap-6",
46
+ children: [
47
+ /* @__PURE__ */ e("h2", { className: "text-center text-white max-tablet:text-[32px] max-tablet:leading-10 max-tablet:font-bold text-[56px] leading-[52px] font-extrabold", children: c }),
48
+ /* @__PURE__ */ e(
49
+ S,
50
+ {
51
+ data: C,
52
+ activeSegment: a,
53
+ onChange: o
54
+ }
55
+ ),
56
+ /* @__PURE__ */ i(
57
+ I,
58
+ {
59
+ gap: 20,
60
+ cols: 2,
61
+ className: "w-full max-tablet:hidden",
62
+ children: [
63
+ /* @__PURE__ */ e(
64
+ r,
65
+ {
66
+ title: t.content.left_card.title,
67
+ description: t.content.left_card.description,
68
+ image: t.content.left_card.image,
69
+ imageHeight: "h-[340px]"
70
+ }
71
+ ),
72
+ /* @__PURE__ */ i(
73
+ f,
74
+ {
75
+ vertical: !0,
76
+ gap: 16,
77
+ children: [
78
+ /* @__PURE__ */ e(
79
+ r,
80
+ {
81
+ title: t.content.right_card.title,
82
+ description: t.content.right_card.description,
83
+ image: t.content.right_card.image,
84
+ imageHeight: "h-[316px]"
85
+ }
86
+ ),
87
+ /* @__PURE__ */ e(
88
+ L,
89
+ {
90
+ className: "text-white/90 w-full text-2xl font-bold justify-between h-20 p-6",
91
+ style: { background: t.segment.activeColor },
92
+ title: (m = (p = t == null ? void 0 : t.content) == null ? void 0 : p.button) == null ? void 0 : m.text,
93
+ ...k((h = (g = t == null ? void 0 : t.content) == null ? void 0 : g.button) == null ? void 0 : h.actions),
94
+ iconRight: /* @__PURE__ */ e("div", { className: "p-3 rounded-2xl bg-white", children: /* @__PURE__ */ e(
95
+ R,
96
+ {
97
+ gradient: t.segment.activeColor
98
+ }
99
+ ) })
100
+ }
101
+ )
102
+ ]
103
+ }
104
+ )
105
+ ]
106
+ }
107
+ ),
108
+ /* @__PURE__ */ i("div", { className: "w-full hidden max-tablet:block", children: [
109
+ /* @__PURE__ */ i(
110
+ N,
111
+ {
112
+ spaceBetween: 12,
113
+ slidesPerView: "auto",
114
+ breakpoints: {
115
+ 640: {
116
+ slidesPerView: 2
117
+ }
118
+ },
119
+ onSwiper: b,
120
+ onSlideChange: (s) => u(s.realIndex),
121
+ className: "w-full",
122
+ children: [
123
+ /* @__PURE__ */ e(x, { className: "!h-auto !w-[280px] sm:!w-[calc(50%-6px)]", children: /* @__PURE__ */ e(
124
+ r,
125
+ {
126
+ title: t.content.left_card.title,
127
+ description: t.content.left_card.description,
128
+ image: t.content.left_card.image
129
+ }
130
+ ) }),
131
+ /* @__PURE__ */ e(x, { className: "!h-auto !w-[280px] sm:!w-[calc(50%-6px)]", children: /* @__PURE__ */ e(
132
+ r,
133
+ {
134
+ title: t.content.right_card.title,
135
+ description: t.content.right_card.description,
136
+ image: t.content.right_card.image
137
+ }
138
+ ) })
139
+ ]
140
+ }
141
+ ),
142
+ /* @__PURE__ */ e(
143
+ _,
144
+ {
145
+ count: 2,
146
+ active: w,
147
+ activeColor: "white",
148
+ anActiveColor: "rgba(255, 255, 255, 0.8)",
149
+ className: "mt-6 sm:hidden"
150
+ }
151
+ )
152
+ ] })
153
+ ]
154
+ }
155
+ ) }) : null;
156
+ };
157
+ W.propsToEdit = G;
158
+ export {
159
+ W as SegmentedContent
160
+ };
@@ -0,0 +1,50 @@
1
+ import { jsxs as a, jsx as t } from "react/jsx-runtime";
2
+ import { F as l } from "../../Flex-86aee720.js";
3
+ import { I as p } from "../../index-9384c6d6.js";
4
+ import { c as x } from "../../cn-6a4bf187.js";
5
+ const h = ({
6
+ title: e,
7
+ description: r,
8
+ image: m,
9
+ imageHeight: i,
10
+ className: n,
11
+ children: o
12
+ }) => /* @__PURE__ */ a(
13
+ l,
14
+ {
15
+ vertical: !0,
16
+ justify: "between",
17
+ align: "center",
18
+ className: x(
19
+ "w-full max-tablet:min-h-[266px] max-tablet:min-w-[280px] flex-1 rounded-xl max-tablet:rounded-3xl max-tablet:gap-[22px] max-tablet:h-full bg-white/15 border border-white/15 backdrop-blur-[15px]",
20
+ n
21
+ ),
22
+ children: [
23
+ /* @__PURE__ */ a(
24
+ l,
25
+ {
26
+ vertical: !0,
27
+ gap: 20,
28
+ className: "w-full px-12 pt-8 pb-6 min-h-[208px] max-tablet:min-h-fit max-tablet:p-4",
29
+ children: [
30
+ /* @__PURE__ */ t("h3", { className: "text-white text-[32px] leading-10 font-bold max-tablet:text-base", children: e }),
31
+ /* @__PURE__ */ t("p", { className: "text-white/80 text-lg leading-[26px] max-tablet:hidden", children: r })
32
+ ]
33
+ }
34
+ ),
35
+ /* @__PURE__ */ t(
36
+ p,
37
+ {
38
+ src: m,
39
+ alt: e,
40
+ className: x("w-full", i, "max-tablet:h-[162px]"),
41
+ imageStyles: "h-auto object-contain"
42
+ }
43
+ ),
44
+ o
45
+ ]
46
+ }
47
+ );
48
+ export {
49
+ h as ContentCard
50
+ };
@@ -0,0 +1,4 @@
1
+ import { ContentCard as t } from "./ContentCard.js";
2
+ export {
3
+ t as ContentCard
4
+ };
@@ -0,0 +1,8 @@
1
+ import { SegmentedContent as t } from "./SegmentedContent.js";
2
+ import { segmentedContentInfo as r } from "./info.js";
3
+ import { propsToEdit as p } from "./schema.js";
4
+ export {
5
+ t as SegmentedContent,
6
+ p as propsToEdit,
7
+ r as segmentedContentInfo
8
+ };
@@ -0,0 +1,12 @@
1
+ import { C as o } from "../types-c3843cc0.js";
2
+ import { propsToEdit as t } from "./schema.js";
3
+ const p = {
4
+ title: "Сегментированный контент",
5
+ description: "Блок с переключением контента по сегментам",
6
+ group: "Бизнес компоненты",
7
+ key: o.SegmentedContent,
8
+ propsToEdit: t
9
+ };
10
+ export {
11
+ p as segmentedContentInfo
12
+ };
@@ -0,0 +1,108 @@
1
+ import { AllActionsObject as t } from "../Actions/types.js";
2
+ import { FieldTypes as e } from "../Types/FiledTypes.js";
3
+ const y = {
4
+ title: {
5
+ type: e.TITLE,
6
+ label: "Заголовок",
7
+ key: "title"
8
+ },
9
+ items: {
10
+ type: e.ARRAY,
11
+ label: "Сервисы",
12
+ key: "items",
13
+ props: {
14
+ segment: {
15
+ type: e.OBJECT,
16
+ label: "Сегмент",
17
+ key: "segment",
18
+ props: {
19
+ title: {
20
+ type: e.TITLE,
21
+ label: "Название таба",
22
+ key: "title"
23
+ },
24
+ icon: {
25
+ type: e.FILE,
26
+ label: "Иконка",
27
+ key: "icon"
28
+ },
29
+ activeColor: {
30
+ type: e.COLOR,
31
+ label: "Активный цвет (градиент)",
32
+ key: "activeColor"
33
+ }
34
+ }
35
+ },
36
+ content: {
37
+ type: e.OBJECT,
38
+ label: "Контент",
39
+ key: "content",
40
+ props: {
41
+ left_card: {
42
+ type: e.OBJECT,
43
+ label: "Левая карточка",
44
+ key: "left_card",
45
+ props: {
46
+ title: {
47
+ type: e.TITLE,
48
+ label: "Заголовок",
49
+ key: "title"
50
+ },
51
+ description: {
52
+ type: e.STRING,
53
+ label: "Описание",
54
+ key: "description"
55
+ },
56
+ image: {
57
+ type: e.FILE,
58
+ label: "Изображение",
59
+ key: "image"
60
+ }
61
+ }
62
+ },
63
+ right_card: {
64
+ type: e.OBJECT,
65
+ label: "Правая карточка",
66
+ key: "right_card",
67
+ props: {
68
+ title: {
69
+ type: e.TITLE,
70
+ label: "Заголовок",
71
+ key: "title"
72
+ },
73
+ description: {
74
+ type: e.STRING,
75
+ label: "Описание",
76
+ key: "description"
77
+ },
78
+ image: {
79
+ type: e.FILE,
80
+ label: "Изображение",
81
+ key: "image"
82
+ }
83
+ }
84
+ },
85
+ button: {
86
+ type: e.OBJECT,
87
+ label: "Кнопка",
88
+ key: "button",
89
+ props: {
90
+ text: {
91
+ type: e.TITLE,
92
+ label: "Текст кнопки",
93
+ key: "text"
94
+ },
95
+ actions: {
96
+ ...t,
97
+ key: "actions"
98
+ }
99
+ }
100
+ }
101
+ }
102
+ }
103
+ }
104
+ }
105
+ };
106
+ export {
107
+ y as propsToEdit
108
+ };
@@ -0,0 +1 @@
1
+
@@ -1,34 +1,43 @@
1
- import { jsx as o } from "react/jsx-runtime";
2
- import { useState as x } from "react";
3
- import { FieldTypes as i } from "../Types/FiledTypes.js";
4
- import { c as r } from "../cn-6a4bf187.js";
5
- const c = {
6
- type: "data",
7
- label: "Сегменты",
8
- dataType: "array",
9
- data: {
10
- title: i.TITLE
1
+ import { jsx as n } from "react/jsx-runtime";
2
+ import { useState as b } from "react";
3
+ import { F as d } from "../Flex-86aee720.js";
4
+ import { c as i } from "../cn-6a4bf187.js";
5
+ import { propsToEdit as u } from "./schema.js";
6
+ import { SegmentsVariant as e } from "./types.js";
7
+ const p = {
8
+ [e.PRIMARY]: {
9
+ container: "rounded-[20px] bg-[#E3E4E8] p-1",
10
+ item: "rounded-[19px] text-gray-800 font-semibold max-tablet:text-[16px] max-tablet:leading-[27px] max-tablet:px-4 max-tablet:py-2 text-[20px] leading-[30px] px-8 py-4 w-[275px]",
11
+ activeItem: "bg-white"
12
+ },
13
+ [e.SECONDARY]: {
14
+ container: "rounded-xl bg-white/15 border border-white/15 backdrop-blur-[15px]",
15
+ item: "text-white rounded-[13px] text-sm leading-5 py-[14px] w-[180px] max-tablet:pr-5 max-tablet:pl-4",
16
+ activeItem: "bg-white text-black font-medium"
11
17
  }
12
- }, m = [c, "activeSegment"], d = ({ data: e, activeSegment: p = 0 }) => {
13
- const [l, n] = x(p), s = (t) => {
14
- n(t);
15
- };
16
- return /* @__PURE__ */ o(
17
- "div",
18
+ }, g = ({
19
+ data: r,
20
+ activeSegment: x = 0,
21
+ variant: l = e.PRIMARY
22
+ }) => {
23
+ const [m, c] = b(x), s = (t) => {
24
+ c(t);
25
+ }, o = p[l] || p[e.PRIMARY];
26
+ return /* @__PURE__ */ n(
27
+ d,
18
28
  {
19
- className: r(
20
- "rounded-[20px] bg-[#E3E4E8] p-1 flex gap-4 w-fit mx-auto max-tablet:w-full"
29
+ className: i(
30
+ "w-fit mx-auto max-tablet:w-full overflow-x-auto no-scrollbar cursor-grab active:cursor-grabbing",
31
+ o.container
21
32
  ),
22
- children: e == null ? void 0 : e.map((t, a) => /* @__PURE__ */ o(
33
+ children: r == null ? void 0 : r.map((t, a) => /* @__PURE__ */ n(
23
34
  "div",
24
35
  {
25
36
  onClick: () => s(a),
26
- className: r(
27
- "rounded-[19px] text-gray-800 font-semibold cursor-pointer text-center whitespace-nowrap",
28
- "transition-colors duration-200",
29
- "max-tablet:text-[16px] max-tablet:leading-[27px] max-tablet:w-full max-tablet:px-4 max-tablet:py-2",
30
- "text-[20px] leading-[30px] px-8 py-4 w-[275px]",
31
- a === l ? "bg-white" : "bg-transparent"
37
+ className: i(
38
+ "bg-transparent cursor-pointer text-center whitespace-nowrap transition-colors duration-200 max-tablet:min-w-min max-tablet:flex-1",
39
+ o.item,
40
+ a === m && o.activeItem
32
41
  ),
33
42
  children: t == null ? void 0 : t.title
34
43
  },
@@ -37,8 +46,7 @@ const c = {
37
46
  }
38
47
  );
39
48
  };
40
- d.propsToEdit = m;
49
+ g.propsToEdit = u;
41
50
  export {
42
- d as Segments,
43
- m as propsToEdit
51
+ g as Segments
44
52
  };
@@ -1,4 +1,10 @@
1
- import { Segments as o } from "./Segments.js";
1
+ import { Segments as r } from "./Segments.js";
2
+ import { SegmentsVariant as m } from "./types.js";
3
+ import { segmentsInfo as f } from "./info.js";
4
+ import { propsToEdit as s } from "./schema.js";
2
5
  export {
3
- o as Segments
6
+ r as Segments,
7
+ m as SegmentsVariant,
8
+ s as propsToEdit,
9
+ f as segmentsInfo
4
10
  };
@@ -1,5 +1,5 @@
1
1
  import { C as o } from "../index-0a5f313c.js";
2
- import { propsToEdit as t } from "./Segments.js";
2
+ import { propsToEdit as t } from "./schema.js";
3
3
  const n = {
4
4
  title: "Сегменты",
5
5
  description: "Компонент для навигации и переключения между разделами с помощью сегментированных кнопок. Используется для организации контента и улучшения навигации по странице.",
@@ -0,0 +1,21 @@
1
+ import { SegmentsVariant as a } from "./types.js";
2
+ import { FieldTypes as t } from "../Types/FiledTypes.js";
3
+ const e = {
4
+ type: "data",
5
+ label: "Сегменты",
6
+ dataType: "array",
7
+ data: {
8
+ title: t.TITLE
9
+ }
10
+ }, r = {
11
+ type: t.VARIANT,
12
+ label: "Вариант",
13
+ key: "variant",
14
+ options: [
15
+ { label: "Primary", value: a.PRIMARY },
16
+ { label: "Secondary", value: a.SECONDARY }
17
+ ]
18
+ }, i = [e, "activeSegment", r];
19
+ export {
20
+ i as propsToEdit
21
+ };
@@ -1 +1,4 @@
1
-
1
+ var R = /* @__PURE__ */ ((r) => (r.PRIMARY = "primary", r.SECONDARY = "secondary", r))(R || {});
2
+ export {
3
+ R as SegmentsVariant
4
+ };
@@ -0,0 +1,92 @@
1
+ import { jsxs as m, jsx as a } from "react/jsx-runtime";
2
+ import { useState as f, useRef as y, useEffect as u } from "react";
3
+ import { u as E } from "../useDraggableScroll-440da9b7.js";
4
+ import { F as p } from "../Flex-86aee720.js";
5
+ import { I as j } from "../index-9384c6d6.js";
6
+ import { c as b } from "../cn-6a4bf187.js";
7
+ import { propsToEdit as I } from "./schema.js";
8
+ const N = ({
9
+ data: r,
10
+ activeSegment: o = 0,
11
+ onChange: s
12
+ }) => {
13
+ var d;
14
+ const [i, l] = f(o), [n, x] = f({
15
+ left: 0,
16
+ width: 0
17
+ }), c = y([]), { ref: w, events: h } = E();
18
+ u(() => {
19
+ l(o);
20
+ }, [o]), u(() => {
21
+ const t = () => {
22
+ const e = c.current[i];
23
+ e && x({
24
+ left: e.offsetLeft,
25
+ width: e.offsetWidth
26
+ });
27
+ };
28
+ return t(), window.addEventListener("resize", t), () => {
29
+ window.removeEventListener("resize", t);
30
+ };
31
+ }, [i, r]);
32
+ const v = (t) => {
33
+ l(t), s == null || s(t);
34
+ };
35
+ return /* @__PURE__ */ m(
36
+ p,
37
+ {
38
+ ref: w,
39
+ ...h,
40
+ className: b(
41
+ "w-full mx-auto overflow-x-auto no-scrollbar cursor-grab active:cursor-grabbing relative",
42
+ "rounded-2xl bg-white/15 backdrop-blur-[15px] border border-white/15"
43
+ ),
44
+ children: [
45
+ /* @__PURE__ */ a(
46
+ "div",
47
+ {
48
+ className: "absolute top-0 bottom-0 my-auto rounded-2xl transition-all duration-300 ease-in-out",
49
+ style: {
50
+ left: n.left,
51
+ width: n.width,
52
+ background: ((d = r[i]) == null ? void 0 : d.activeColor) || "transparent",
53
+ height: "100%"
54
+ }
55
+ }
56
+ ),
57
+ r == null ? void 0 : r.map((t, e) => /* @__PURE__ */ m(
58
+ p,
59
+ {
60
+ ref: (g) => c.current[e] = g,
61
+ align: "center",
62
+ gap: 8,
63
+ onClick: () => v(e),
64
+ className: b(
65
+ "justify-start max-tablet:justify-center cursor-pointer whitespace-nowrap transition-all duration-300 ease-in-out p-4 flex-1 rounded-2xl max-tablet:pl-3 max-tablet:pr-4 relative z-10",
66
+ "min-w-[186px] max-tablet:min-w-min"
67
+ ),
68
+ children: [
69
+ t.icon && /* @__PURE__ */ a(
70
+ j,
71
+ {
72
+ src: t.icon,
73
+ alt: t.title,
74
+ width: 40,
75
+ height: 40,
76
+ className: "h-10 w-10 object-contain max-tablet:hidden",
77
+ draggable: !1
78
+ }
79
+ ),
80
+ /* @__PURE__ */ a("span", { className: "text-white text-sm font-extrabold leading-5 select-none", children: t.title })
81
+ ]
82
+ },
83
+ e
84
+ ))
85
+ ]
86
+ }
87
+ );
88
+ };
89
+ N.propsToEdit = I;
90
+ export {
91
+ N as SegmentsIcons
92
+ };
@@ -0,0 +1,8 @@
1
+ import { SegmentsIcons as r } from "./SegmentsIcons.js";
2
+ import { propsToEdit as t } from "./schema.js";
3
+ import { segmentsIconsInfo as n } from "./info.js";
4
+ export {
5
+ r as SegmentsIcons,
6
+ t as propsToEdit,
7
+ n as segmentsIconsInfo
8
+ };
@@ -0,0 +1,11 @@
1
+ import { C as o } from "../index-0a5f313c.js";
2
+ import { propsToEdit as t } from "./schema.js";
3
+ const n = {
4
+ title: "Сегменты с иконками",
5
+ description: "Компонент для навигации с иконками и индивидуальным цветом для каждого сегмента.",
6
+ types: [o.navigation],
7
+ propsToEdit: t
8
+ };
9
+ export {
10
+ n as segmentsIconsInfo
11
+ };
@@ -0,0 +1,14 @@
1
+ import { FieldTypes as t } from "../Types/FiledTypes.js";
2
+ const a = {
3
+ type: "data",
4
+ label: "Сегменты с иконками",
5
+ dataType: "array",
6
+ data: {
7
+ title: t.TITLE,
8
+ icon: t.FILE,
9
+ activeColor: t.COLOR
10
+ }
11
+ }, o = [a, "activeSegment"];
12
+ export {
13
+ o as propsToEdit
14
+ };
@@ -0,0 +1 @@
1
+