stone-kit 0.0.1105 → 0.0.1107
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.
- package/README.md +30 -0
- package/dist/App.d.ts +2 -0
- package/dist/App.js +10 -0
- package/dist/Option-DmDx_xOt.js +99 -0
- package/dist/PinTrans-D6OZq76b.js +10 -0
- package/dist/Router.d.ts +2 -0
- package/dist/Router.js +103 -0
- package/dist/SmallFilter-C-VKnbkP.js +10 -0
- package/dist/chunk-4WY6JWTD-BeveLKf_.js +1582 -0
- package/dist/components/Button/ui/Button.d.ts +1 -2
- package/dist/components/Button/ui/Button.js +74 -67
- package/dist/components/Button/ui/Button.types.d.ts +7 -5
- package/dist/components/Button/ui/Button.types.js +5 -3
- package/dist/components/CheckBox/CheckBox.d.ts +2 -0
- package/dist/components/CheckBox/CheckBox.js +84 -0
- package/dist/components/CheckBox/CheckBox.types.d.ts +17 -0
- package/dist/components/CheckBox/CheckBox.types.js +1 -0
- package/dist/components/CheckBox/index.d.ts +2 -0
- package/dist/components/CheckBox/index.js +4 -0
- package/dist/components/CheckBoxNew/CheckBox.types.d.ts +16 -0
- package/dist/components/CheckBoxNew/CheckBox.types.js +6 -0
- package/dist/components/CheckBoxNew/CheckBoxNew.d.ts +11 -0
- package/dist/components/CheckBoxNew/CheckBoxNew.js +45 -0
- package/dist/components/CheckboxSelect/index.d.ts +1 -0
- package/dist/components/CheckboxSelect/index.js +4 -0
- package/dist/components/CheckboxSelect/ui/CheckboxSelect.d.ts +18 -0
- package/dist/components/CheckboxSelect/ui/CheckboxSelect.js +57 -0
- package/dist/components/CommercialLotCard/CommercialLotCard.d.ts +2 -0
- package/dist/components/CommercialLotCard/CommercialLotCard.js +81 -0
- package/dist/components/CommercialLotCard/components/PaymentLink/PaymentLink.d.ts +6 -0
- package/dist/components/CommercialLotCard/components/PaymentLink/PaymentLink.js +21 -0
- package/dist/components/CommercialLotCard/components/Price/Price.d.ts +9 -0
- package/dist/components/CommercialLotCard/components/Price/Price.js +39 -0
- package/dist/components/CommercialLotCard/components/Snippets/Snippets.d.ts +6 -0
- package/dist/components/CommercialLotCard/components/Snippets/Snippets.js +100 -0
- package/dist/components/CommercialLotCard/components/Tags/Tags.d.ts +7 -0
- package/dist/components/CommercialLotCard/components/Tags/Tags.js +37 -0
- package/dist/components/CommercialLotCard/types/CommercialLotCard.types.d.ts +10 -0
- package/dist/components/CommercialLotCard/types/CommercialLotCard.types.js +1 -0
- package/dist/components/CommercialLotCard/types/LotCard.d.ts +386 -0
- package/dist/components/CommercialLotCard/types/LotCard.js +1 -0
- package/dist/components/CommercialLotCard/utils/formatPrice.d.ts +1 -0
- package/dist/components/CommercialLotCard/utils/formatPrice.js +8 -0
- package/dist/components/CommercialLotCard/utils/getTagsFeatures.d.ts +4 -0
- package/dist/components/CommercialLotCard/utils/getTagsFeatures.js +13 -0
- package/dist/components/DestinationTab/ui/DestinationTab.d.ts +0 -1
- package/dist/components/DestinationTab/ui/DestinationTab.js +41 -41
- package/dist/components/DestinationTab/ui/DestinationTab.types.d.ts +0 -1
- package/dist/components/FavoriteIcon/FavoriteIcon.d.ts +7 -0
- package/dist/components/FavoriteIcon/FavoriteIcon.js +66 -0
- package/dist/components/FavoriteIcon/Heart.d.ts +3 -0
- package/dist/components/FavoriteIcon/Heart.js +24 -0
- package/dist/components/FavoriteIcon/HeartFilled.d.ts +5 -0
- package/dist/components/FavoriteIcon/HeartFilled.js +27 -0
- package/dist/components/FieldInput/ui/FieldInput.d.ts +1 -2
- package/dist/components/FieldInput/ui/FieldInput.js +28 -7
- package/dist/components/FieldInput/ui/FieldInput.types.d.ts +3 -1
- package/dist/components/FilterWithSave/hooks/useFilterWithSave.d.ts +43 -0
- package/dist/components/FilterWithSave/hooks/useFilterWithSave.js +56 -0
- package/dist/components/FilterWithSave/ui/FilterWithSave.d.ts +29 -0
- package/dist/components/FilterWithSave/ui/FilterWithSave.js +325 -0
- package/dist/components/Flex/ui/Flex.d.ts +0 -1
- package/dist/components/Flex/ui/Flex.js +1 -1
- package/dist/components/Flex/ui/Flex.types.d.ts +0 -1
- package/dist/components/FormModal/ui/ModalForm.d.ts +60 -0
- package/dist/components/FormModal/ui/ModalForm.js +1518 -0
- package/dist/components/FormModal/utils/reg.d.ts +4 -0
- package/dist/components/FormModal/utils/reg.js +6 -0
- package/dist/components/GroupedInput/ui/GroupedInputs.d.ts +0 -1
- package/dist/components/GroupedInput/ui/GroupedInputs.js +5 -5
- package/dist/components/GroupedInput/ui/GroupedInputs.types.d.ts +0 -1
- package/dist/components/Input/ui/Input.d.ts +28 -0
- package/dist/components/Input/ui/Input.js +3247 -49
- package/dist/components/Input/ui/Input.types.d.ts +0 -23
- package/dist/components/Input/ui/Input.types.js +1 -7
- package/dist/components/Logo/ui/Logo.d.ts +1 -2
- package/dist/components/Logo/ui/Logo.js +58 -33
- package/dist/components/Logo/ui/Logo.types.d.ts +13 -1
- package/dist/components/Logo/ui/Logo.types.js +14 -1
- package/dist/components/LotCard/hooks/useLotCard.d.ts +25 -0
- package/dist/components/LotCard/hooks/useLotCard.js +13 -0
- package/dist/components/LotCard/ui/LotCard.d.ts +1 -2
- package/dist/components/LotCard/ui/LotCard.js +203 -104
- package/dist/components/LotCard/ui/LotCard.types.d.ts +234 -75
- package/dist/components/LotCard/utils/checkBedroomsCount.js +2 -2
- package/dist/components/LotCard/utils/const.d.ts +8 -0
- package/dist/components/LotCard/utils/const.js +11 -0
- package/dist/components/LotCard/utils/formatPrice.d.ts +1 -1
- package/dist/components/LotCard/utils/formatPrice.js +5 -6
- package/dist/components/LotCard/utils/getTagsFeatures.d.ts +4 -0
- package/dist/components/LotCard/utils/getTagsFeatures.js +13 -0
- package/dist/components/LotCard/utils/monthlyPayment.d.ts +1 -0
- package/dist/components/LotCard/utils/monthlyPayment.js +4 -0
- package/dist/components/LotCardSkeleton/index.d.ts +1 -0
- package/dist/components/LotCardSkeleton/index.js +4 -0
- package/dist/components/LotCardSkeleton/ui/LotCardSkeleton.d.ts +5 -0
- package/dist/components/LotCardSkeleton/ui/LotCardSkeleton.js +83 -0
- package/dist/components/MetroLabel/ui/MetroLabel.d.ts +0 -1
- package/dist/components/MetroLabel/ui/MetroLabel.js +19 -19
- package/dist/components/MetroLabel/ui/MetroLabel.types.d.ts +0 -1
- package/dist/components/MetroTag/ui/MetroTag.d.ts +1 -2
- package/dist/components/MetroTag/ui/MetroTag.js +121 -25
- package/dist/components/MetroTag/ui/MetroTag.types.d.ts +21 -6
- package/dist/components/Modal/ui/Modal.d.ts +2 -17
- package/dist/components/Modal/ui/Modal.js +63 -19594
- package/dist/components/Modal/ui/Modal.types.d.ts +21 -0
- package/dist/components/ModalSuccess/ModalSuccess.d.ts +2 -0
- package/dist/components/ModalSuccess/ModalSuccess.js +60 -0
- package/dist/components/ModalSuccess/ModalSuccess.types.d.ts +8 -0
- package/dist/components/ModalSuccess/ModalSuccess.types.js +1 -0
- package/dist/components/ModalSuccess/index.d.ts +1 -0
- package/dist/components/ModalSuccess/index.js +4 -0
- package/dist/components/NewIcon/icons/PinTrans.d.ts +3 -0
- package/dist/components/NewIcon/icons/PinTrans.js +6 -0
- package/dist/components/NewIcon/icons/SmallFilter.d.ts +3 -0
- package/dist/components/NewIcon/icons/SmallFilter.js +6 -0
- package/dist/components/NewIcon/index.d.ts +1 -1
- package/dist/components/NewIcon/index.js +3 -2
- package/dist/components/NewIcon/ui/NewIcon.d.ts +2 -2
- package/dist/components/NewIcon/ui/NewIcon.js +204 -99
- package/dist/components/NewIcon/ui/NewIcon.types.d.ts +0 -1
- package/dist/components/NewIcon/ui/iconTypes.d.ts +3 -0
- package/dist/components/NewIcon/ui/iconTypes.js +60 -0
- package/dist/components/ProjectCardSkeleton/index.d.ts +1 -0
- package/dist/components/ProjectCardSkeleton/index.js +4 -0
- package/dist/components/ProjectCardSkeleton/ui/ProjectCardSkeleton.d.ts +1 -0
- package/dist/components/ProjectCardSkeleton/ui/ProjectCardSkeleton.js +32 -0
- package/dist/components/RoundButton/ui/RoundButton.d.ts +1 -2
- package/dist/components/RoundButton/ui/RoundButton.js +56 -45
- package/dist/components/RoundButton/ui/RoundButton.types.d.ts +10 -2
- package/dist/components/RoundButton/ui/RoundButton.types.js +13 -6
- package/dist/components/Select/model/selectMode.d.ts +16 -0
- package/dist/components/Select/model/selectMode.js +64 -0
- package/dist/components/Select/ui/Category.d.ts +13 -0
- package/dist/components/Select/ui/Category.js +79 -0
- package/dist/components/Select/ui/Option.d.ts +15 -0
- package/dist/components/Select/ui/Option.js +7 -0
- package/dist/components/Select/ui/Select.d.ts +1 -3
- package/dist/components/Select/ui/Select.js +196 -79
- package/dist/components/Select/ui/Select.types.d.ts +62 -6
- package/dist/components/SliderNavigation/index.d.ts +0 -1
- package/dist/components/SliderNavigation/ui/SliderNavigation.d.ts +1 -2
- package/dist/components/SliderNavigation/ui/SliderNavigation.js +45 -32
- package/dist/components/SliderNavigation/ui/SliderNavigation.types.d.ts +7 -0
- package/dist/components/SortSelect/hooks/useSortSelect.d.ts +5 -4
- package/dist/components/SortSelect/hooks/useSortSelect.js +2 -2
- package/dist/components/SortSelect/ui/SortSelect.d.ts +0 -1
- package/dist/components/SortSelect/ui/SortSelect.js +67 -56
- package/dist/components/SortSelect/ui/SortSelect.types.d.ts +9 -2
- package/dist/components/SummarySelect/index.d.ts +1 -0
- package/dist/components/SummarySelect/index.js +4 -0
- package/dist/components/SummarySelect/ui/SummarySelect.d.ts +15 -0
- package/dist/components/SummarySelect/ui/SummarySelect.js +172 -0
- package/dist/components/Switcher/ui/Switcher.d.ts +1 -2
- package/dist/components/Switcher/ui/Switcher.js +45 -30
- package/dist/components/Switcher/ui/Switcher.types.d.ts +3 -1
- package/dist/components/TabSelect/index.d.ts +1 -0
- package/dist/components/TabSelect/index.js +4 -0
- package/dist/components/TabSelect/ui/TabSelect.d.ts +32 -0
- package/dist/components/TabSelect/ui/TabSelect.js +64 -0
- package/dist/components/TabSelect/ui/TabSelect.types.d.ts +0 -0
- package/dist/components/TabSelect/ui/TabSelect.types.js +1 -0
- package/dist/components/TabSwitcher/ui/TabSwitcher.d.ts +4 -4
- package/dist/components/TabSwitcher/ui/TabSwitcher.js +114 -34
- package/dist/components/TabSwitcher/ui/TabSwitcher.types.d.ts +23 -4
- package/dist/components/Tag/ui/Tag.d.ts +1 -2
- package/dist/components/Tag/ui/Tag.js +96 -44
- package/dist/components/Tag/ui/Tag.types.d.ts +22 -2
- package/dist/components/Tag/ui/Tag.types.js +20 -3
- package/dist/components/Text/ui/Text.d.ts +1 -2
- package/dist/components/Text/ui/Text.js +20 -27
- package/dist/components/Text/ui/Text.types.d.ts +0 -1
- package/dist/components/TextArea/TextArea.d.ts +8 -0
- package/dist/components/TextArea/TextArea.js +25 -0
- package/dist/components/ZoomControls/index.d.ts +1 -0
- package/dist/components/ZoomControls/index.js +4 -0
- package/dist/components/ZoomControls/ui/ZoomControls.d.ts +2 -0
- package/dist/components/ZoomControls/ui/ZoomControls.js +33 -0
- package/dist/components/ZoomControls/ui/ZoomControls.types.d.ts +6 -0
- package/dist/components/ZoomControls/ui/ZoomControls.types.js +1 -0
- package/dist/components/mobileButton/ui/MobileButton.d.ts +0 -1
- package/dist/components/mobileButton/ui/MobileButton.js +38 -38
- package/dist/components/mobileButton/ui/MobileButton.types.d.ts +0 -1
- package/dist/index-BJwl9stn.js +33872 -0
- package/dist/index-YnD2EP-S.js +43 -0
- package/dist/layout/Layout.d.ts +5 -0
- package/dist/layout/Layout.js +11 -0
- package/dist/layout/components/Header/Header.d.ts +1 -0
- package/dist/layout/components/Header/Header.js +141 -0
- package/dist/layout/components/Menu.d.ts +1 -0
- package/dist/layout/components/Menu.js +109 -0
- package/dist/main.d.ts +14 -0
- package/dist/main.js +70 -42
- package/dist/pages/ButtonsPage/Buttons.d.ts +1 -0
- package/dist/pages/ButtonsPage/Buttons.js +106 -0
- package/dist/pages/CheckboxPage/CheckboxPage.d.ts +1 -0
- package/dist/pages/CheckboxPage/CheckboxPage.js +224 -0
- package/dist/pages/FormsPage/FormsPage.d.ts +2 -0
- package/dist/pages/FormsPage/FormsPage.js +58 -0
- package/dist/pages/HomePage/HomePage.d.ts +2 -0
- package/dist/pages/HomePage/HomePage.js +7 -0
- package/dist/pages/IconsPage/IconsPage.d.ts +1 -0
- package/dist/pages/IconsPage/IconsPage.js +19 -0
- package/dist/pages/InputPage/InputPage.d.ts +1 -0
- package/dist/pages/InputPage/InputPage.js +13 -0
- package/dist/pages/LogoPage/LogoPage.d.ts +1 -0
- package/dist/pages/LogoPage/LogoPage.js +16 -0
- package/dist/pages/LotsPage/LotsPage.d.ts +1 -0
- package/dist/pages/LotsPage/LotsPage.js +74 -0
- package/dist/pages/LotsPage/const.d.ts +4 -0
- package/dist/pages/LotsPage/const.js +678 -0
- package/dist/pages/ModalsPage/ModalPage.d.ts +2 -0
- package/dist/pages/ModalsPage/ModalPage.js +110 -0
- package/dist/pages/SelectPage/SelectPage.d.ts +1 -0
- package/dist/pages/SelectPage/SelectPage.js +211 -0
- package/dist/pages/SelectPage/const.d.ts +13 -0
- package/dist/pages/SelectPage/const.js +35 -0
- package/dist/pages/TabsPage/TabsPage.d.ts +2 -0
- package/dist/pages/TabsPage/TabsPage.js +168 -0
- package/dist/pages/TagsPage/TagsPage.d.ts +1 -0
- package/dist/pages/TagsPage/TagsPage.js +64 -0
- package/dist/shared/checkLargeOffice.d.ts +2 -0
- package/dist/shared/checkLargeOffice.js +4 -0
- package/dist/shared/deepEqual.d.ts +1 -0
- package/dist/shared/deepEqual.js +16 -0
- package/dist/shared/fmtNumber.d.ts +1 -0
- package/dist/shared/fmtNumber.js +4 -0
- package/dist/shared/mlnRound.d.ts +1 -0
- package/dist/shared/mlnRound.js +8 -0
- package/dist/shared/useClientWidth.d.ts +2 -0
- package/dist/shared/useClientWidth.js +6 -6
- package/dist/stone-kit.css +1 -0
- package/dist/stories/entities/CommercialLotCard/CommercialLotCard.stories.js +166 -0
- package/dist/stories/entities/index.js +4 -0
- package/dist/stories/shared/ui/Button/Button.stories.js +118 -0
- package/dist/stories/shared/ui/CheckBox/CheckBox.stories.js +71 -0
- package/dist/stories/shared/ui/CheckBox/CheckBoxNew.stories.js +45 -0
- package/dist/stories/shared/ui/CheckboxSelect/CheckboxSelect.stories.js +114 -0
- package/dist/stories/shared/ui/DestinationTab/DestinationTab.stories.js +89 -0
- package/dist/stories/shared/ui/FieldInput/FieldInput.stories.js +31 -0
- package/dist/stories/shared/ui/FilterWithSave/FilterWithSave.stories.js +44 -0
- package/dist/stories/shared/ui/Flex/Flex.stories.js +74 -0
- package/dist/stories/shared/ui/FormModal/FormModal.stories.js +65 -0
- package/dist/stories/shared/ui/GroupedInput/GroupedInput.stories.js +68 -0
- package/dist/stories/shared/ui/Input/Input.stories.js +82 -0
- package/dist/stories/shared/ui/Logo/Logo.stories.js +75 -0
- package/dist/stories/shared/ui/MetroLabel/MetroLabel.stories.js +91 -0
- package/dist/stories/shared/ui/MetroTag/MetroTag.stories.js +96 -0
- package/dist/stories/shared/ui/MobileButton/MobileButton.stories.js +77 -0
- package/dist/stories/shared/ui/Modal/Modal.stories.js +77 -0
- package/dist/stories/shared/ui/ModalSuccess/ModalSuccess.stories.js +34 -0
- package/dist/stories/shared/ui/NewIcon/NewIcon.stories.js +38 -0
- package/dist/stories/shared/ui/RoundButton/RoundButton.stories.js +83 -0
- package/dist/stories/shared/ui/Select/Select.stories.js +81 -0
- package/dist/stories/shared/ui/SliderNavigation/SliderNavigation.stories.js +82 -0
- package/dist/stories/shared/ui/SortSelect/SortSelect.stories.js +87 -0
- package/dist/stories/shared/ui/SummarySelect/SummarySelect.stories.js +85 -0
- package/dist/stories/shared/ui/Switcher/Switcher.stories.js +77 -0
- package/dist/stories/shared/ui/TabSelect/TabSelect.stories.js +76 -0
- package/dist/stories/shared/ui/TabSwitcher/TabSwitcher.stories.js +76 -0
- package/dist/stories/shared/ui/Tag/Tag.stories.js +51 -0
- package/dist/stories/shared/ui/Text/Text.stories.js +22 -0
- package/dist/stories/shared/ui/TextArea/TextArea.stories.js +37 -0
- package/dist/stories/shared/ui/ZoomControls/ZoomControls.stories.js +91 -0
- package/dist/stories/shared/ui/index.js +62 -0
- package/dist/useLotCard-D-gK4J_o.js +186 -0
- package/dist/useSortSelect-IeonkD5d.js +79 -0
- package/package.json +39 -30
- package/dist/index-DIxK0V-G.js +0 -44
- package/dist/style.css +0 -1
- package/dist/useSortSelect-A7A_pNcU.js +0 -76
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { c as
|
|
3
|
-
const
|
|
4
|
-
destination:
|
|
1
|
+
import { jsxs as s, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { c as z } from "../../../index-YnD2EP-S.js";
|
|
3
|
+
const N = "_destination_1c7de_1", x = "_destinationName_1c7de_40", w = "_routeText_1c7de_45", g = "_whiteStroke_1c7de_65", k = "_routeWrapper_1c7de_78", e = {
|
|
4
|
+
destination: N,
|
|
5
5
|
"auto-width": "_auto-width_1c7de_29",
|
|
6
6
|
"full-width": "_full-width_1c7de_33",
|
|
7
7
|
"medium-size": "_medium-size_1c7de_37",
|
|
8
|
-
destinationName:
|
|
8
|
+
destinationName: x,
|
|
9
9
|
routeText: w,
|
|
10
10
|
"large-size": "_large-size_1c7de_51",
|
|
11
11
|
whiteStroke: g,
|
|
@@ -14,58 +14,58 @@ const x = "_destination_1c7de_1", n = "_destinationName_1c7de_40", w = "_routeTe
|
|
|
14
14
|
"large-size_m": "_large-size_m_1c7de_122",
|
|
15
15
|
"medium-size_l": "_medium-size_l_1c7de_137",
|
|
16
16
|
"large-size_l": "_large-size_l_1c7de_150"
|
|
17
|
-
}, b =
|
|
18
|
-
size:
|
|
19
|
-
size_m:
|
|
20
|
-
size_l:
|
|
21
|
-
destination:
|
|
22
|
-
variant:
|
|
23
|
-
width:
|
|
24
|
-
routes:
|
|
25
|
-
checked:
|
|
26
|
-
onChange:
|
|
27
|
-
additionalClass:
|
|
28
|
-
...
|
|
29
|
-
}) => /* @__PURE__ */
|
|
17
|
+
}, b = z.bind(e), f = ({
|
|
18
|
+
size: a = "medium",
|
|
19
|
+
size_m: d,
|
|
20
|
+
size_l: r,
|
|
21
|
+
destination: t = { destName: "", color: "" },
|
|
22
|
+
variant: m = "whiteStroke",
|
|
23
|
+
width: o = "auto",
|
|
24
|
+
routes: c = [],
|
|
25
|
+
checked: l,
|
|
26
|
+
onChange: n,
|
|
27
|
+
additionalClass: u = "",
|
|
28
|
+
...p
|
|
29
|
+
}) => /* @__PURE__ */ s(
|
|
30
30
|
"label",
|
|
31
31
|
{
|
|
32
32
|
className: b(
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
33
|
+
e.destination,
|
|
34
|
+
e[`${a}-size`],
|
|
35
|
+
e[`${d}-size_m`],
|
|
36
|
+
e[`${r}-size_l`],
|
|
37
|
+
e[`${m}`],
|
|
38
|
+
e[`${o}-width`],
|
|
39
|
+
u
|
|
40
40
|
),
|
|
41
|
-
...
|
|
42
|
-
htmlFor:
|
|
41
|
+
...p,
|
|
42
|
+
htmlFor: t.destName,
|
|
43
43
|
children: [
|
|
44
|
-
/* @__PURE__ */
|
|
44
|
+
/* @__PURE__ */ i(
|
|
45
45
|
"input",
|
|
46
46
|
{
|
|
47
|
-
id:
|
|
48
|
-
checked:
|
|
49
|
-
onChange:
|
|
47
|
+
id: t.destName,
|
|
48
|
+
checked: l,
|
|
49
|
+
onChange: n,
|
|
50
50
|
type: "checkbox",
|
|
51
|
-
name:
|
|
52
|
-
value:
|
|
51
|
+
name: t.destName,
|
|
52
|
+
value: t.destName
|
|
53
53
|
}
|
|
54
54
|
),
|
|
55
|
-
/* @__PURE__ */
|
|
56
|
-
|
|
57
|
-
|
|
55
|
+
/* @__PURE__ */ s("div", { className: e.destination, children: [
|
|
56
|
+
t?.color && /* @__PURE__ */ i("span", { style: { background: t?.color ?? "" } }),
|
|
57
|
+
t.destName
|
|
58
58
|
] }),
|
|
59
|
-
|
|
59
|
+
c.map((_, h) => /* @__PURE__ */ s(
|
|
60
60
|
"div",
|
|
61
61
|
{
|
|
62
|
-
className:
|
|
62
|
+
className: e.routeWrapper,
|
|
63
63
|
children: [
|
|
64
|
-
|
|
65
|
-
/* @__PURE__ */
|
|
64
|
+
_.type,
|
|
65
|
+
/* @__PURE__ */ i("div", { className: e.routeText, children: _.text })
|
|
66
66
|
]
|
|
67
67
|
},
|
|
68
|
-
|
|
68
|
+
h
|
|
69
69
|
))
|
|
70
70
|
]
|
|
71
71
|
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
interface IFavoriteIcon {
|
|
2
|
+
handleClickFavorite: (e: React.MouseEvent<HTMLDivElement>) => void;
|
|
3
|
+
isFavorite?: boolean;
|
|
4
|
+
uniqueId?: string;
|
|
5
|
+
}
|
|
6
|
+
export declare const FavoriteIcon: ({ handleClickFavorite, isFavorite, uniqueId }: IFavoriteIcon) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { jsxs as a, Fragment as _, jsx as c } from "react/jsx-runtime";
|
|
2
|
+
import { useState as u, useRef as d, useEffect as h } from "react";
|
|
3
|
+
import { createPortal as T } from "react-dom";
|
|
4
|
+
import x from "./Heart.js";
|
|
5
|
+
import y from "./HeartFilled.js";
|
|
6
|
+
const C = "_root_vcwe4_1", R = "_popup_vcwe4_28", g = {
|
|
7
|
+
root: C,
|
|
8
|
+
popup: R
|
|
9
|
+
}, b = ({ handleClickFavorite: l, isFavorite: t, uniqueId: w }) => {
|
|
10
|
+
const [P, i] = u(!1), [s, n] = u(!1), [f, S] = u({ top: 0, left: 0 }), o = d(null), p = d(null), e = `favorite_popup_${w}`, I = (r) => {
|
|
11
|
+
r.stopPropagation(), r.preventDefault(), t && sessionStorage.setItem(e, "true"), i(!0), setTimeout(() => {
|
|
12
|
+
i(!1), l && l(r);
|
|
13
|
+
}, 200);
|
|
14
|
+
};
|
|
15
|
+
return h(() => {
|
|
16
|
+
if (sessionStorage.getItem(e) === "true" && !t && p.current) {
|
|
17
|
+
o.current && clearTimeout(o.current);
|
|
18
|
+
const m = p.current.getBoundingClientRect();
|
|
19
|
+
S({
|
|
20
|
+
top: m.top + window.scrollY - 60,
|
|
21
|
+
left: m.right + window.scrollX - 200
|
|
22
|
+
}), n(!0), sessionStorage.removeItem(e), o.current = setTimeout(() => {
|
|
23
|
+
n(!1);
|
|
24
|
+
}, 2e3);
|
|
25
|
+
}
|
|
26
|
+
return t && sessionStorage.removeItem(e), () => {
|
|
27
|
+
o.current && clearTimeout(o.current);
|
|
28
|
+
};
|
|
29
|
+
}, [t, e]), h(() => {
|
|
30
|
+
t && s && (n(!1), o.current && (clearTimeout(o.current), o.current = null));
|
|
31
|
+
}, [t, s]), /* @__PURE__ */ a(_, { children: [
|
|
32
|
+
/* @__PURE__ */ a(
|
|
33
|
+
"div",
|
|
34
|
+
{
|
|
35
|
+
ref: p,
|
|
36
|
+
className: g.root,
|
|
37
|
+
onClick: I,
|
|
38
|
+
style: {
|
|
39
|
+
transform: P ? "scale(0.9)" : "scale(1)",
|
|
40
|
+
transition: "transform 0.1s ease-in-out"
|
|
41
|
+
},
|
|
42
|
+
children: [
|
|
43
|
+
!t && /* @__PURE__ */ c(x, { width: 24, height: 24, color: "#353945" }),
|
|
44
|
+
t && /* @__PURE__ */ c(y, { width: 24, height: 24, color: "#015FF9" })
|
|
45
|
+
]
|
|
46
|
+
}
|
|
47
|
+
),
|
|
48
|
+
s && T(
|
|
49
|
+
/* @__PURE__ */ c(
|
|
50
|
+
"div",
|
|
51
|
+
{
|
|
52
|
+
className: g.popup,
|
|
53
|
+
style: {
|
|
54
|
+
top: `${f.top}px`,
|
|
55
|
+
left: `${f.left}px`
|
|
56
|
+
},
|
|
57
|
+
children: "Удалено из избранного"
|
|
58
|
+
}
|
|
59
|
+
),
|
|
60
|
+
document.body
|
|
61
|
+
)
|
|
62
|
+
] });
|
|
63
|
+
};
|
|
64
|
+
export {
|
|
65
|
+
b as FavoriteIcon
|
|
66
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
const t = (o) => /* @__PURE__ */ e(
|
|
3
|
+
"svg",
|
|
4
|
+
{
|
|
5
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6
|
+
width: 24,
|
|
7
|
+
height: 24,
|
|
8
|
+
fill: "none",
|
|
9
|
+
...o,
|
|
10
|
+
children: /* @__PURE__ */ e(
|
|
11
|
+
"path",
|
|
12
|
+
{
|
|
13
|
+
stroke: "currentColor",
|
|
14
|
+
strokeLinecap: "round",
|
|
15
|
+
strokeLinejoin: "round",
|
|
16
|
+
d: "M11.995 7.437c-1.4-1.573-3.733-1.996-5.487-.556-1.753 1.44-2 3.849-.623 5.552 1.145 1.416 4.61 4.403 5.745 5.37.127.108.191.162.265.183a.368.368 0 0 0 .2 0c.074-.021.138-.075.265-.183 1.136-.967 4.6-3.954 5.745-5.37 1.378-1.703 1.16-4.127-.623-5.552-1.784-1.425-4.087-1.017-5.487.556Z",
|
|
17
|
+
clipRule: "evenodd"
|
|
18
|
+
}
|
|
19
|
+
)
|
|
20
|
+
}
|
|
21
|
+
);
|
|
22
|
+
export {
|
|
23
|
+
t as default
|
|
24
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
const r = (e) => /* @__PURE__ */ o(
|
|
3
|
+
"svg",
|
|
4
|
+
{
|
|
5
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6
|
+
width: 24,
|
|
7
|
+
height: 24,
|
|
8
|
+
fill: "none",
|
|
9
|
+
style: { transform: e.deg ? `rotate(${e.deg}deg)` : void 0 },
|
|
10
|
+
...e,
|
|
11
|
+
children: /* @__PURE__ */ o(
|
|
12
|
+
"path",
|
|
13
|
+
{
|
|
14
|
+
fill: "currentColor",
|
|
15
|
+
fillRule: "evenodd",
|
|
16
|
+
stroke: "currentColor",
|
|
17
|
+
strokeLinecap: "round",
|
|
18
|
+
strokeLinejoin: "round",
|
|
19
|
+
d: "M11.995 7.437c-1.4-1.573-3.733-1.996-5.487-.556-1.753 1.44-2 3.849-.623 5.552 1.145 1.416 4.61 4.403 5.745 5.37.127.108.191.162.265.183a.368.368 0 0 0 .2 0c.074-.021.138-.075.265-.183 1.136-.967 4.6-3.954 5.745-5.37 1.378-1.703 1.16-4.127-.623-5.552-1.784-1.425-4.087-1.017-5.487.556Z",
|
|
20
|
+
clipRule: "evenodd"
|
|
21
|
+
}
|
|
22
|
+
)
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
export {
|
|
26
|
+
r as default
|
|
27
|
+
};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { ComponentProps } from './FieldInput.types';
|
|
3
|
-
|
|
4
|
-
export declare const FieldInput: ({ label, children }: React.PropsWithChildren<ComponentProps>) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export declare const FieldInput: ({ label, handleClear, isShowClear, children, labelSize, }: React.PropsWithChildren<ComponentProps>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,10 +1,31 @@
|
|
|
1
|
-
import { jsxs as l, jsx as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { jsxs as l, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { c as t } from "../../../index-YnD2EP-S.js";
|
|
3
|
+
const i = "_fieldInputWrapper_1l9b5_1", m = "_clearBtn_1l9b5_9", _ = "_nameWrapper_1l9b5_24", d = "_label_1l9b5_32", o = "_large_1l9b5_40", e = {
|
|
4
|
+
fieldInputWrapper: i,
|
|
5
|
+
clearBtn: m,
|
|
6
|
+
nameWrapper: _,
|
|
7
|
+
label: d,
|
|
8
|
+
large: o
|
|
9
|
+
}, u = ({
|
|
10
|
+
label: r,
|
|
11
|
+
handleClear: n,
|
|
12
|
+
isShowClear: p,
|
|
13
|
+
children: s,
|
|
14
|
+
labelSize: c = "medium"
|
|
15
|
+
}) => /* @__PURE__ */ l("div", { className: e.fieldInputWrapper, children: [
|
|
16
|
+
/* @__PURE__ */ l("div", { className: t(e.nameWrapper, { [e.large]: c === "large" }), children: [
|
|
17
|
+
/* @__PURE__ */ a("label", { className: e.label, children: r }),
|
|
18
|
+
p && /* @__PURE__ */ a(
|
|
19
|
+
"div",
|
|
20
|
+
{
|
|
21
|
+
className: e.clearBtn,
|
|
22
|
+
onClick: n,
|
|
23
|
+
children: "Очистить"
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
] }),
|
|
27
|
+
s
|
|
7
28
|
] });
|
|
8
29
|
export {
|
|
9
|
-
|
|
30
|
+
u as FieldInput
|
|
10
31
|
};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { default as React, ReactNode } from 'react';
|
|
2
|
-
|
|
3
2
|
interface InputProps {
|
|
4
3
|
label: string;
|
|
4
|
+
handleClear?: () => void;
|
|
5
5
|
children?: ReactNode;
|
|
6
|
+
isShowClear?: boolean;
|
|
7
|
+
labelSize?: 'medium' | 'large';
|
|
6
8
|
}
|
|
7
9
|
export type ComponentProps = InputProps & React.InputHTMLAttributes<HTMLInputElement>;
|
|
8
10
|
export {};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { TOption } from '../../Select/ui/Select.types';
|
|
2
|
+
interface IuseFilterWithSave {
|
|
3
|
+
selectOptions?: TOption[];
|
|
4
|
+
disabledOptions?: TOption[];
|
|
5
|
+
selectedValues?: TOption[];
|
|
6
|
+
tabs?: {
|
|
7
|
+
value: string;
|
|
8
|
+
state: boolean;
|
|
9
|
+
}[];
|
|
10
|
+
selectedTabs?: {
|
|
11
|
+
value: string;
|
|
12
|
+
state: boolean;
|
|
13
|
+
}[];
|
|
14
|
+
setSelectedTabs?: React.Dispatch<React.SetStateAction<{
|
|
15
|
+
value: string;
|
|
16
|
+
state: boolean;
|
|
17
|
+
}[]>>;
|
|
18
|
+
onChange?: (selectedOptions: TOption[]) => unknown;
|
|
19
|
+
onClickItem?: (option: TOption | TOption[]) => void;
|
|
20
|
+
onSaveClick: () => void;
|
|
21
|
+
onClearClick: () => void;
|
|
22
|
+
}
|
|
23
|
+
export declare const useFilterWithSave: ({ selectedTabs, selectedValues, onClickItem, disabledOptions, tabs, onChange, setSelectedTabs, onSaveClick, onClearClick, }: IuseFilterWithSave) => {
|
|
24
|
+
isMobile: boolean;
|
|
25
|
+
handleClearClick: () => void;
|
|
26
|
+
handleCloseModal: () => void;
|
|
27
|
+
handleOptionClick: (option: TOption) => void;
|
|
28
|
+
handleSaveClick: import('react').MouseEventHandler<HTMLButtonElement>;
|
|
29
|
+
localSelectedTabs: {
|
|
30
|
+
value: string;
|
|
31
|
+
state: boolean;
|
|
32
|
+
}[];
|
|
33
|
+
selectedOptions: TOption[];
|
|
34
|
+
setSelectedOptions: import('react').Dispatch<import('react').SetStateAction<TOption[]>>;
|
|
35
|
+
isModalOpen: boolean;
|
|
36
|
+
setIsModalOpen: import('react').Dispatch<import('react').SetStateAction<boolean>>;
|
|
37
|
+
setLocalSelectedTabs: import('react').Dispatch<import('react').SetStateAction<{
|
|
38
|
+
value: string;
|
|
39
|
+
state: boolean;
|
|
40
|
+
}[]>>;
|
|
41
|
+
containerRef: import('react').RefObject<HTMLDivElement | null>;
|
|
42
|
+
};
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { useState as c, useRef as w, useEffect as p } from "react";
|
|
2
|
+
import { useClientWidth as x } from "../../../shared/useClientWidth.js";
|
|
3
|
+
const I = ({
|
|
4
|
+
selectedTabs: n = [],
|
|
5
|
+
selectedValues: v = [],
|
|
6
|
+
onClickItem: m,
|
|
7
|
+
disabledOptions: h = [],
|
|
8
|
+
tabs: a = [],
|
|
9
|
+
onChange: s,
|
|
10
|
+
setSelectedTabs: S,
|
|
11
|
+
onSaveClick: C,
|
|
12
|
+
onClearClick: E
|
|
13
|
+
}) => {
|
|
14
|
+
const { isMobile: L } = x(), [i, u] = c(!1), f = w(null), [M, g] = c(n), [R] = c(v), [O, r] = c(M), [l, o] = c(R), y = (e) => {
|
|
15
|
+
if (m && m(e), h.some((t) => t.value === e.value))
|
|
16
|
+
return;
|
|
17
|
+
const d = l.some((t) => t.value === e.value) ? l.filter((t) => t.value !== e.value) : [...l, e];
|
|
18
|
+
o(d);
|
|
19
|
+
}, J = () => {
|
|
20
|
+
g(a), r(a), o([]), E(), s && (s([]), S?.(a));
|
|
21
|
+
}, N = () => {
|
|
22
|
+
o(v), r(n);
|
|
23
|
+
}, k = () => {
|
|
24
|
+
N(), u(!1);
|
|
25
|
+
}, W = (e) => {
|
|
26
|
+
e.stopPropagation(), C(), s && (S?.(O), s(l)), u(!1);
|
|
27
|
+
};
|
|
28
|
+
return p(() => {
|
|
29
|
+
i || r((e) => JSON.stringify(e) !== JSON.stringify(n) ? n : e);
|
|
30
|
+
}, [i, n]), p(() => {
|
|
31
|
+
const e = (d) => {
|
|
32
|
+
if (!f.current) return;
|
|
33
|
+
const t = d.target;
|
|
34
|
+
f.current.contains(t) || t.closest("svg") || k();
|
|
35
|
+
};
|
|
36
|
+
return i ? document.addEventListener("click", e) : document.removeEventListener("click", e), () => {
|
|
37
|
+
document.removeEventListener("click", e);
|
|
38
|
+
};
|
|
39
|
+
}, [i]), {
|
|
40
|
+
isMobile: L,
|
|
41
|
+
handleClearClick: J,
|
|
42
|
+
handleCloseModal: k,
|
|
43
|
+
handleOptionClick: y,
|
|
44
|
+
handleSaveClick: W,
|
|
45
|
+
localSelectedTabs: O,
|
|
46
|
+
selectedOptions: l,
|
|
47
|
+
setSelectedOptions: o,
|
|
48
|
+
isModalOpen: i,
|
|
49
|
+
setIsModalOpen: u,
|
|
50
|
+
setLocalSelectedTabs: r,
|
|
51
|
+
containerRef: f
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
export {
|
|
55
|
+
I as useFilterWithSave
|
|
56
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { TOption } from '../../Select/ui/Select.types';
|
|
2
|
+
interface IFilterWithSave {
|
|
3
|
+
selectOptions?: TOption[];
|
|
4
|
+
disabledOptions?: TOption[];
|
|
5
|
+
selectedValues?: TOption[];
|
|
6
|
+
onSaveClick?: () => void;
|
|
7
|
+
onClearClick?: () => void;
|
|
8
|
+
onTabClick?: () => void;
|
|
9
|
+
tabs?: {
|
|
10
|
+
value: string;
|
|
11
|
+
state: boolean;
|
|
12
|
+
}[];
|
|
13
|
+
selectedTabs?: {
|
|
14
|
+
value: string;
|
|
15
|
+
state: boolean;
|
|
16
|
+
}[];
|
|
17
|
+
setSelectedTabs?: React.Dispatch<React.SetStateAction<{
|
|
18
|
+
value: string;
|
|
19
|
+
state: boolean;
|
|
20
|
+
}[]>>;
|
|
21
|
+
onChange?: (selectedOptions: TOption[]) => unknown;
|
|
22
|
+
onClickItem?: (option: TOption | TOption[]) => void;
|
|
23
|
+
onCLickSelect?: () => void;
|
|
24
|
+
onClick?: () => void;
|
|
25
|
+
dataTestId?: string;
|
|
26
|
+
btnName?: string;
|
|
27
|
+
}
|
|
28
|
+
export declare const FilterWithSave: ({ disabledOptions, tabs, selectOptions, onChange, onClick, selectedValues, setSelectedTabs, selectedTabs, onClickItem, onCLickSelect, dataTestId, onSaveClick, onClearClick, onTabClick, btnName, }: IFilterWithSave) => import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export {};
|