@redneckz/wildless-cms-uni-blocks 0.13.4 → 0.13.6
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/bin/migration-scripts/0.13.4.js +30 -0
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +168 -124
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/bundle/components/Carousel/CarouselContent.d.ts +6 -0
- package/bundle/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/bundle/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/bundle/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.d.ts +1 -1
- package/bundle/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/bundle/components/Header/HeaderSubMenu.d.ts +1 -1
- package/bundle/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/bundle/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/bundle/icons/IconName.d.ts +4 -2
- package/bundle/model/HeadlineType.d.ts +1 -1
- package/bundle/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/bundle/ui-kit/Input/InputProps.d.ts +1 -0
- package/bundle/ui-kit/List/ListContent.d.ts +2 -2
- package/bundle/ui-kit/Select/Select.d.ts +1 -0
- package/cosmos-static/icons/CourtHouseIcon.svg +1 -0
- package/dist/components/ApplicationForm/ApplicationFormCredit.js +2 -1
- package/dist/components/ApplicationForm/ApplicationFormCredit.js.map +1 -1
- package/dist/components/ApplicationForm/PhoneInputControl.js +1 -1
- package/dist/components/ApplicationForm/PhoneInputControl.js.map +1 -1
- package/dist/components/ApplicationForm/renderCreditDataOrganization.js +1 -1
- package/dist/components/ApplicationForm/renderCreditDataOrganization.js.map +1 -1
- package/dist/components/ApplicationForm/renderCreditParameters.js +1 -1
- package/dist/components/ApplicationForm/renderCreditParameters.js.map +1 -1
- package/dist/components/ApplicationForm/renderRegion.js +1 -1
- package/dist/components/ApplicationForm/renderRegion.js.map +1 -1
- package/dist/components/ApplicationForm/renderRegionDepartment.js +1 -1
- package/dist/components/ApplicationForm/renderRegionDepartment.js.map +1 -1
- package/dist/components/ButtonsBlock/ButtonsBlock.js +9 -1
- package/dist/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/dist/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/dist/components/Carousel/Carousel.js +2 -2
- package/dist/components/Carousel/Carousel.js.map +1 -1
- package/dist/components/Carousel/CarouselContent.d.ts +6 -0
- package/dist/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/dist/components/Carousel/renderCarouselCards.js +12 -3
- package/dist/components/Carousel/renderCarouselCards.js.map +1 -1
- package/dist/components/CarouselLinks/CarouselLinks.js +1 -1
- package/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/dist/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.d.ts +1 -1
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.js +1 -1
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.js.map +1 -1
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/dist/components/Header/HeaderSubMenu.d.ts +1 -1
- package/dist/components/Header/HeaderSubMenu.js +4 -4
- package/dist/components/Header/HeaderSubMenu.js.map +1 -1
- package/dist/components/Headline/headlineVersionStyles.js +1 -1
- package/dist/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/dist/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/dist/icons/IconName.d.ts +4 -2
- package/dist/icons/IconName.js +2 -0
- package/dist/icons/IconName.js.map +1 -1
- package/dist/model/HeadlineType.d.ts +1 -1
- package/dist/ui-kit/BaseTile/BaseTile.js +1 -1
- package/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/dist/ui-kit/DialogManager/DialogManager.js +9 -29
- package/dist/ui-kit/DialogManager/DialogManager.js.map +1 -1
- package/dist/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/dist/ui-kit/DialogManager/useDialogsList.js +37 -0
- package/dist/ui-kit/DialogManager/useDialogsList.js.map +1 -0
- package/dist/ui-kit/Input/Input.js +2 -2
- package/dist/ui-kit/Input/Input.js.map +1 -1
- package/dist/ui-kit/Input/InputProps.d.ts +1 -0
- package/dist/ui-kit/List/List.js +2 -0
- package/dist/ui-kit/List/List.js.map +1 -1
- package/dist/ui-kit/List/ListContent.d.ts +2 -2
- package/dist/ui-kit/List/ListItem.js +1 -0
- package/dist/ui-kit/List/ListItem.js.map +1 -1
- package/dist/ui-kit/Select/Select.d.ts +1 -0
- package/dist/ui-kit/Select/Select.js +18 -4
- package/dist/ui-kit/Select/Select.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/ApplicationForm/ApplicationFormCredit.js +2 -1
- package/lib/components/ApplicationForm/ApplicationFormCredit.js.map +1 -1
- package/lib/components/ApplicationForm/PhoneInputControl.js +1 -1
- package/lib/components/ApplicationForm/PhoneInputControl.js.map +1 -1
- package/lib/components/ApplicationForm/renderCreditDataOrganization.js +1 -1
- package/lib/components/ApplicationForm/renderCreditDataOrganization.js.map +1 -1
- package/lib/components/ApplicationForm/renderCreditParameters.js +1 -1
- package/lib/components/ApplicationForm/renderCreditParameters.js.map +1 -1
- package/lib/components/ApplicationForm/renderRegion.js +1 -1
- package/lib/components/ApplicationForm/renderRegion.js.map +1 -1
- package/lib/components/ApplicationForm/renderRegionDepartment.js +1 -1
- package/lib/components/ApplicationForm/renderRegionDepartment.js.map +1 -1
- package/lib/components/ButtonsBlock/ButtonsBlock.js +9 -1
- package/lib/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/lib/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/lib/components/Carousel/Carousel.js +2 -2
- package/lib/components/Carousel/Carousel.js.map +1 -1
- package/lib/components/Carousel/CarouselContent.d.ts +6 -0
- package/lib/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/lib/components/Carousel/renderCarouselCards.js +12 -3
- package/lib/components/Carousel/renderCarouselCards.js.map +1 -1
- package/lib/components/CarouselLinks/CarouselLinks.js +1 -1
- package/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/lib/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.d.ts +1 -1
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.js +1 -1
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.js.map +1 -1
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/lib/components/Header/HeaderSubMenu.d.ts +1 -1
- package/lib/components/Header/HeaderSubMenu.js +4 -4
- package/lib/components/Header/HeaderSubMenu.js.map +1 -1
- package/lib/components/Headline/headlineVersionStyles.js +1 -1
- package/lib/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/lib/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/lib/icons/IconName.d.ts +4 -2
- package/lib/icons/IconName.js +2 -0
- package/lib/icons/IconName.js.map +1 -1
- package/lib/model/HeadlineType.d.ts +1 -1
- package/lib/ui-kit/BaseTile/BaseTile.js +1 -1
- package/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/lib/ui-kit/DialogManager/DialogManager.js +9 -29
- package/lib/ui-kit/DialogManager/DialogManager.js.map +1 -1
- package/lib/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/lib/ui-kit/DialogManager/useDialogsList.js +34 -0
- package/lib/ui-kit/DialogManager/useDialogsList.js.map +1 -0
- package/lib/ui-kit/Input/Input.js +2 -2
- package/lib/ui-kit/Input/Input.js.map +1 -1
- package/lib/ui-kit/Input/InputProps.d.ts +1 -0
- package/lib/ui-kit/List/List.js +2 -0
- package/lib/ui-kit/List/List.js.map +1 -1
- package/lib/ui-kit/List/ListContent.d.ts +2 -2
- package/lib/ui-kit/List/ListItem.js +1 -0
- package/lib/ui-kit/List/ListItem.js.map +1 -1
- package/lib/ui-kit/Select/Select.d.ts +1 -0
- package/lib/ui-kit/Select/Select.js +19 -5
- package/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +139 -31
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/mobile/bundle/components/Carousel/CarouselContent.d.ts +6 -0
- package/mobile/bundle/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/mobile/bundle/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/mobile/bundle/components/CarouselRecommendationCard/CarouselRecommendationCard.d.ts +1 -1
- package/mobile/bundle/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/mobile/bundle/components/Header/HeaderSubMenu.d.ts +1 -1
- package/mobile/bundle/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/mobile/bundle/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/mobile/bundle/icons/IconName.d.ts +4 -2
- package/mobile/bundle/model/HeadlineType.d.ts +1 -1
- package/mobile/bundle/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/mobile/bundle/ui-kit/Input/InputProps.d.ts +1 -0
- package/mobile/bundle/ui-kit/List/ListContent.d.ts +2 -2
- package/mobile/bundle/ui-kit/Select/Select.d.ts +1 -0
- package/mobile/dist/components/ApplicationForm/ApplicationFormCredit.js +2 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormCredit.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/PhoneInputControl.js +1 -1
- package/mobile/dist/components/ApplicationForm/PhoneInputControl.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/renderCreditDataOrganization.js +1 -1
- package/mobile/dist/components/ApplicationForm/renderCreditDataOrganization.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/renderCreditParameters.js +1 -1
- package/mobile/dist/components/ApplicationForm/renderCreditParameters.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/renderRegion.js +1 -1
- package/mobile/dist/components/ApplicationForm/renderRegion.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/renderRegionDepartment.js +1 -1
- package/mobile/dist/components/ApplicationForm/renderRegionDepartment.js.map +1 -1
- package/mobile/dist/components/ButtonsBlock/ButtonsBlock.js +9 -1
- package/mobile/dist/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/mobile/dist/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/mobile/dist/components/Carousel/Carousel.js +2 -2
- package/mobile/dist/components/Carousel/Carousel.js.map +1 -1
- package/mobile/dist/components/Carousel/CarouselContent.d.ts +6 -0
- package/mobile/dist/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/mobile/dist/components/Carousel/renderCarouselCards.js +12 -3
- package/mobile/dist/components/Carousel/renderCarouselCards.js.map +1 -1
- package/mobile/dist/components/CarouselLinks/CarouselLinks.js +1 -1
- package/mobile/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/mobile/dist/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.d.ts +1 -1
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/mobile/dist/components/Footer/buttonSizeStyles.js +1 -1
- package/mobile/dist/components/Header/HeaderSubMenu.d.ts +1 -1
- package/mobile/dist/components/Header/HeaderSubMenu.js +4 -4
- package/mobile/dist/components/Header/HeaderSubMenu.js.map +1 -1
- package/mobile/dist/components/Headline/headlineVersionStyles.js +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/mobile/dist/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/mobile/dist/icons/IconName.d.ts +4 -2
- package/mobile/dist/icons/IconName.js +2 -0
- package/mobile/dist/icons/IconName.js.map +1 -1
- package/mobile/dist/model/HeadlineType.d.ts +1 -1
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js +1 -1
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/dist/ui-kit/DialogManager/DialogManager.js +9 -29
- package/mobile/dist/ui-kit/DialogManager/DialogManager.js.map +1 -1
- package/mobile/dist/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/mobile/dist/ui-kit/DialogManager/useDialogsList.js +37 -0
- package/mobile/dist/ui-kit/DialogManager/useDialogsList.js.map +1 -0
- package/mobile/dist/ui-kit/Input/Input.js +2 -2
- package/mobile/dist/ui-kit/Input/Input.js.map +1 -1
- package/mobile/dist/ui-kit/Input/InputProps.d.ts +1 -0
- package/mobile/dist/ui-kit/List/List.js +2 -0
- package/mobile/dist/ui-kit/List/List.js.map +1 -1
- package/mobile/dist/ui-kit/List/ListContent.d.ts +2 -2
- package/mobile/dist/ui-kit/List/ListItem.js +1 -0
- package/mobile/dist/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/dist/ui-kit/Select/Select.d.ts +1 -0
- package/mobile/dist/ui-kit/Select/Select.js +18 -4
- package/mobile/dist/ui-kit/Select/Select.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormCredit.js +2 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormCredit.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/PhoneInputControl.js +1 -1
- package/mobile/lib/components/ApplicationForm/PhoneInputControl.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/renderCreditDataOrganization.js +1 -1
- package/mobile/lib/components/ApplicationForm/renderCreditDataOrganization.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/renderCreditParameters.js +1 -1
- package/mobile/lib/components/ApplicationForm/renderCreditParameters.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/renderRegion.js +1 -1
- package/mobile/lib/components/ApplicationForm/renderRegion.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/renderRegionDepartment.js +1 -1
- package/mobile/lib/components/ApplicationForm/renderRegionDepartment.js.map +1 -1
- package/mobile/lib/components/ButtonsBlock/ButtonsBlock.js +9 -1
- package/mobile/lib/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/mobile/lib/components/ButtonsBlock/ButtonsBlockContent.d.ts +2 -0
- package/mobile/lib/components/Carousel/Carousel.js +2 -2
- package/mobile/lib/components/Carousel/Carousel.js.map +1 -1
- package/mobile/lib/components/Carousel/CarouselContent.d.ts +6 -0
- package/mobile/lib/components/Carousel/renderCarouselCards.d.ts +3 -1
- package/mobile/lib/components/Carousel/renderCarouselCards.js +12 -3
- package/mobile/lib/components/Carousel/renderCarouselCards.js.map +1 -1
- package/mobile/lib/components/CarouselLinks/CarouselLinks.js +1 -1
- package/mobile/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/mobile/lib/components/CarouselProductCard/CarouselProductCardContent.d.ts +2 -4
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.d.ts +1 -1
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCardContent.d.ts +2 -4
- package/mobile/lib/components/Footer/buttonSizeStyles.js +1 -1
- package/mobile/lib/components/Header/HeaderSubMenu.d.ts +1 -1
- package/mobile/lib/components/Header/HeaderSubMenu.js +4 -4
- package/mobile/lib/components/Header/HeaderSubMenu.js.map +1 -1
- package/mobile/lib/components/Headline/headlineVersionStyles.js +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocsContent.d.ts +2 -5
- package/mobile/lib/components/ParagraphBlock/ParagraphBlockContent.d.ts +3 -3
- package/mobile/lib/icons/IconName.d.ts +4 -2
- package/mobile/lib/icons/IconName.js +2 -0
- package/mobile/lib/icons/IconName.js.map +1 -1
- package/mobile/lib/model/HeadlineType.d.ts +1 -1
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js +1 -1
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/lib/ui-kit/DialogManager/DialogManager.js +9 -29
- package/mobile/lib/ui-kit/DialogManager/DialogManager.js.map +1 -1
- package/mobile/lib/ui-kit/DialogManager/useDialogsList.d.ts +7 -0
- package/mobile/lib/ui-kit/DialogManager/useDialogsList.js +34 -0
- package/mobile/lib/ui-kit/DialogManager/useDialogsList.js.map +1 -0
- package/mobile/lib/ui-kit/Input/Input.js +2 -2
- package/mobile/lib/ui-kit/Input/Input.js.map +1 -1
- package/mobile/lib/ui-kit/Input/InputProps.d.ts +1 -0
- package/mobile/lib/ui-kit/List/List.js +2 -0
- package/mobile/lib/ui-kit/List/List.js.map +1 -1
- package/mobile/lib/ui-kit/List/ListContent.d.ts +2 -2
- package/mobile/lib/ui-kit/List/ListItem.js +1 -0
- package/mobile/lib/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/lib/ui-kit/Select/Select.d.ts +1 -0
- package/mobile/lib/ui-kit/Select/Select.js +19 -5
- package/mobile/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/src/components/ApplicationForm/ApplicationFormCredit.tsx +2 -1
- package/mobile/src/components/ApplicationForm/PhoneInputControl.tsx +1 -0
- package/mobile/src/components/ApplicationForm/renderCreditDataOrganization.tsx +1 -1
- package/mobile/src/components/ApplicationForm/renderCreditParameters.tsx +2 -2
- package/mobile/src/components/ApplicationForm/renderRegion.tsx +1 -0
- package/mobile/src/components/ApplicationForm/renderRegionDepartment.tsx +1 -0
- package/mobile/src/components/ButtonsBlock/ButtonsBlock.tsx +22 -5
- package/mobile/src/components/ButtonsBlock/ButtonsBlockContent.ts +2 -0
- package/mobile/src/components/Carousel/Carousel.example.json +2 -1
- package/mobile/src/components/Carousel/Carousel.tsx +2 -1
- package/mobile/src/components/Carousel/CarouselContent.ts +7 -0
- package/mobile/src/components/Carousel/renderCarouselCards.tsx +20 -4
- package/mobile/src/components/CarouselLinks/CarouselLinks.tsx +1 -1
- package/mobile/src/components/CarouselProductCard/CarouselProductCardContent.ts +7 -4
- package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.tsx +7 -7
- package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCardContent.ts +3 -4
- package/mobile/src/components/Footer/buttonSizeStyles.ts +1 -1
- package/mobile/src/components/Header/HeaderSubMenu.tsx +17 -15
- package/mobile/src/components/Headline/Headline.example.json +1 -1
- package/mobile/src/components/Headline/headlineVersionStyles.ts +1 -1
- package/mobile/src/components/LinkDocs/LinkDocsContent.ts +3 -5
- package/mobile/src/components/ParagraphBlock/ParagraphBlockContent.ts +9 -8
- package/mobile/src/icons/CourtHouseIcon.svg +1 -0
- package/mobile/src/icons/IconName.ts +4 -4
- package/mobile/src/model/HeadlineType.ts +1 -1
- package/mobile/src/ui-kit/BaseTile/BaseTile.tsx +1 -1
- package/mobile/src/ui-kit/DialogManager/DialogManager.tsx +9 -34
- package/mobile/src/ui-kit/DialogManager/useDialogsList.ts +50 -0
- package/mobile/src/ui-kit/Input/Input.tsx +2 -0
- package/mobile/src/ui-kit/Input/InputProps.ts +1 -0
- package/mobile/src/ui-kit/List/List.tsx +2 -0
- package/mobile/src/ui-kit/List/ListContent.ts +2 -2
- package/mobile/src/ui-kit/List/ListItem.tsx +1 -0
- package/mobile/src/ui-kit/Select/Select.tsx +46 -12
- package/package.json +1 -1
- package/src/components/ApplicationForm/ApplicationFormCredit.tsx +2 -1
- package/src/components/ApplicationForm/PhoneInputControl.tsx +1 -0
- package/src/components/ApplicationForm/renderCreditDataOrganization.tsx +1 -1
- package/src/components/ApplicationForm/renderCreditParameters.tsx +2 -2
- package/src/components/ApplicationForm/renderRegion.tsx +1 -0
- package/src/components/ApplicationForm/renderRegionDepartment.tsx +1 -0
- package/src/components/ButtonsBlock/ButtonsBlock.tsx +22 -5
- package/src/components/ButtonsBlock/ButtonsBlockContent.ts +2 -0
- package/src/components/Carousel/Carousel.example.json +2 -1
- package/src/components/Carousel/Carousel.fixture.tsx +2 -0
- package/src/components/Carousel/Carousel.tsx +2 -1
- package/src/components/Carousel/CarouselContent.ts +7 -0
- package/src/components/Carousel/renderCarouselCards.tsx +20 -4
- package/src/components/CarouselLinks/CarouselLinks.fixture.tsx +12 -9
- package/src/components/CarouselLinks/CarouselLinks.tsx +1 -1
- package/src/components/CarouselProductCard/CarouselProductCardContent.ts +7 -4
- package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.fixture.mobile.tsx +1 -1
- package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.mobile.tsx +7 -7
- package/src/components/CarouselRecommendationCard/CarouselRecommendationCardContent.ts +3 -4
- package/src/components/Header/HeaderSubMenu.tsx +17 -15
- package/src/components/Headline/Headline.example.json +1 -1
- package/src/components/Headline/headlineVersionStyles.ts +1 -1
- package/src/components/LinkDocs/LinkDocsContent.ts +3 -5
- package/src/components/ParagraphBlock/ParagraphBlockContent.ts +9 -8
- package/src/icons/CourtHouseIcon.svg +1 -0
- package/src/icons/IconName.ts +4 -1
- package/src/model/HeadlineType.ts +1 -1
- package/src/ui-kit/BaseTile/BaseTile.tsx +1 -1
- package/src/ui-kit/DialogManager/DialogManager.tsx +9 -34
- package/src/ui-kit/DialogManager/useDialogsList.ts +50 -0
- package/src/ui-kit/Input/Input.tsx +2 -0
- package/src/ui-kit/Input/InputProps.ts +1 -0
- package/src/ui-kit/List/List.tsx +2 -0
- package/src/ui-kit/List/ListContent.ts +2 -2
- package/src/ui-kit/List/ListItem.tsx +1 -0
- package/src/ui-kit/Select/Select.tsx +46 -12
- package/bundle/components/Footer/buttonSizeStyles.mobile.d.ts +0 -4
- package/dist/components/Footer/buttonSizeStyles.mobile.d.ts +0 -4
- package/dist/components/Footer/buttonSizeStyles.mobile.js +0 -7
- package/dist/components/Footer/buttonSizeStyles.mobile.js.map +0 -1
- package/lib/components/Footer/buttonSizeStyles.mobile.d.ts +0 -4
- package/lib/components/Footer/buttonSizeStyles.mobile.js +0 -5
- package/lib/components/Footer/buttonSizeStyles.mobile.js.map +0 -1
- package/src/components/Footer/buttonSizeStyles.mobile.ts +0 -6
|
@@ -693,7 +693,7 @@
|
|
|
693
693
|
};
|
|
694
694
|
};
|
|
695
695
|
|
|
696
|
-
const Input = JSX(({ key, className = '', inputClassName = '', id, name, type = 'text', label, placeholder, value = '', valid = true, children, onChange, onFocus, onBlur, pattern, }) => {
|
|
696
|
+
const Input = JSX(({ key, className = '', inputClassName = '', id, name, type = 'text', label, placeholder, value = '', valid = true, children, onChange, onFocus, onBlur, pattern, autoFocus = false, }) => {
|
|
697
697
|
const handleChange = useCallback((e) => {
|
|
698
698
|
onChange && onChange(e.target?.value || '');
|
|
699
699
|
}, [onChange]);
|
|
@@ -701,7 +701,7 @@
|
|
|
701
701
|
const validStyle = valid
|
|
702
702
|
? 'border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text'
|
|
703
703
|
: 'border-error';
|
|
704
|
-
return (jsxs("div", { className: style('relative', className), children: [jsxs("label", { children: [label ? (jsx("div", { className: "mb-xs", children: jsx(Text, { size: "text-m", font: "font-light", children: label }) })) : null, jsx("input", { className: style('w-full border rounded-md text-primary-text outline-none p-m', paddingStyle, validStyle, inputClassName), id: id, name: name || id, placeholder: placeholder, type: type, value: value, onInput: handleChange, onFocus: onFocus, onBlur: onBlur, pattern: pattern }, key)] }), children] }));
|
|
704
|
+
return (jsxs("div", { className: style('relative', className), children: [jsxs("label", { children: [label ? (jsx("div", { className: "mb-xs", children: jsx(Text, { size: "text-m", font: "font-light", children: label }) })) : null, jsx("input", { className: style('w-full border rounded-md text-primary-text outline-none p-m', paddingStyle, validStyle, inputClassName), id: id, name: name || id, placeholder: placeholder, type: type, value: value, onInput: handleChange, onFocus: onFocus, onBlur: onBlur, pattern: pattern, autoFocus: autoFocus }, key)] }), children] }));
|
|
705
705
|
});
|
|
706
706
|
|
|
707
707
|
const InputControl = JSX(({ className, label, value = '', error, onChange, onBlur }) => (jsxs("div", { className: className, children: [jsx(Input, { type: "text", "aria-label": label, label: label, valid: Boolean(!error), value: value, onChange: onChange, onBlur: onBlur }), jsx("div", { className: "h-2", children: error ? (jsx(Text, { size: "text-xs", font: "font-light", color: "text-error", children: error })) : null })] })));
|
|
@@ -725,7 +725,7 @@
|
|
|
725
725
|
return (jsx(Input, { onChange: handleChange, onFocus: (event) => handleChange(event?.target?.value || ''), ...inputProps, children: children }));
|
|
726
726
|
});
|
|
727
727
|
|
|
728
|
-
const PhoneInputControl = JSX(({ className, label, value, error, onChange, onBlur }) => (jsxs("div", { className: className, children: [jsx(PhoneInput, { "aria-label": label, label: label, valid: Boolean(!error), value: value, onChange: onChange, onBlur: onBlur }), jsx("div", { className: "h-2", children: error ? (jsx(Text, { size: "text-xs", font: "font-light", color: "text-error", children: error })) : null })] })));
|
|
728
|
+
const PhoneInputControl = JSX(({ className, label, value, error, onChange, onBlur }) => (jsxs("div", { className: className, children: [jsx(PhoneInput, { "aria-label": label, label: label, valid: Boolean(!error), value: value, onChange: onChange, onBlur: onBlur, placeholder: "+7 (___) ___-__-__" }), jsx("div", { className: "h-2", children: error ? (jsx(Text, { size: "text-xs", font: "font-light", color: "text-error", children: error })) : null })] })));
|
|
729
729
|
|
|
730
730
|
const pattern = (regexp) => validator((_) => typeof _ === 'string' && regexp.test(_));
|
|
731
731
|
|
|
@@ -784,6 +784,70 @@
|
|
|
784
784
|
return targetRef;
|
|
785
785
|
}
|
|
786
786
|
|
|
787
|
+
const JARO_WINKLER_P = 0.1;
|
|
788
|
+
const JARO_WINKLER_MAX_L = 4;
|
|
789
|
+
const jaroWinklerDistance = (s1) => (s2) => {
|
|
790
|
+
if (s1 === s2) {
|
|
791
|
+
return 1;
|
|
792
|
+
}
|
|
793
|
+
if (!s1 || !s2) {
|
|
794
|
+
return 0;
|
|
795
|
+
}
|
|
796
|
+
const { m, s1Matches, s2Matches } = computeM(s1, s2);
|
|
797
|
+
if (m === 0) {
|
|
798
|
+
return 0;
|
|
799
|
+
}
|
|
800
|
+
const t = computeT(s1, s2, { s1Matches, s2Matches });
|
|
801
|
+
const jaroWeight = (m / s1.length + m / s2.length + (m - t / 2) / m) / 3;
|
|
802
|
+
const winklerWeight = jaroWeight > 0.7 ? computePrefixL(s1, s2) * JARO_WINKLER_P : 0;
|
|
803
|
+
return jaroWeight + winklerWeight * (1 - jaroWeight);
|
|
804
|
+
};
|
|
805
|
+
function computeM(s1, s2) {
|
|
806
|
+
const range = Math.max(0, Math.floor(Math.max(s1.length, s2.length) / 2) - 1);
|
|
807
|
+
const s1Matches = new Array(s1.length);
|
|
808
|
+
const s2Matches = new Array(s2.length);
|
|
809
|
+
let m = 0;
|
|
810
|
+
for (let i = 0; i < s1.length; i++) {
|
|
811
|
+
const low = Math.max(0, i - range);
|
|
812
|
+
const high = Math.min(i + range, s2.length - 1);
|
|
813
|
+
for (let j = low; j <= high; j++) {
|
|
814
|
+
if (s1Matches[i] || s2Matches[j] || s1[i] !== s2[j]) {
|
|
815
|
+
continue;
|
|
816
|
+
}
|
|
817
|
+
m++;
|
|
818
|
+
s1Matches[i] = true;
|
|
819
|
+
s2Matches[j] = true;
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
return { m, s1Matches, s2Matches };
|
|
823
|
+
}
|
|
824
|
+
function computeT(s1, s2, { s1Matches, s2Matches }) {
|
|
825
|
+
let t = 0;
|
|
826
|
+
for (let i = 0, k = 0; i < s1.length; i++) {
|
|
827
|
+
if (!s1Matches[i]) {
|
|
828
|
+
continue;
|
|
829
|
+
}
|
|
830
|
+
let j = k;
|
|
831
|
+
for (; j < s2.length; j++) {
|
|
832
|
+
if (s2Matches[j]) {
|
|
833
|
+
k = j + 1;
|
|
834
|
+
break;
|
|
835
|
+
}
|
|
836
|
+
}
|
|
837
|
+
if (s1[i] !== s2[j]) {
|
|
838
|
+
t++;
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
return t;
|
|
842
|
+
}
|
|
843
|
+
function computePrefixL(s1, s2) {
|
|
844
|
+
let prefixL = 0;
|
|
845
|
+
while (s1[prefixL] === s2[prefixL] && prefixL < JARO_WINKLER_MAX_L) {
|
|
846
|
+
prefixL++;
|
|
847
|
+
}
|
|
848
|
+
return prefixL;
|
|
849
|
+
}
|
|
850
|
+
|
|
787
851
|
const svgUseStyleMap = {
|
|
788
852
|
normal: '',
|
|
789
853
|
color: 'text-primary-main',
|
|
@@ -804,16 +868,28 @@
|
|
|
804
868
|
const getSvgSize = (width) => (width ? '' : 'w-full h-full');
|
|
805
869
|
const Background = JSX(({ className, children }) => className ? jsx("div", { className: className, children: children }) : children);
|
|
806
870
|
|
|
807
|
-
const Select = JSX(({ className = '', label, options = [], value, valid = true, isBorder = true, placeholder = '', onChange, }) => {
|
|
871
|
+
const Select = JSX(({ className = '', label, options = [], value, valid = true, isBorder = true, placeholder = '', onChange, isSearch = false, }) => {
|
|
808
872
|
const [isOpen, { setFalse: close, toggle }] = useBool();
|
|
809
|
-
const
|
|
810
|
-
const
|
|
873
|
+
const [searchValue, setSearchValue] = useState('');
|
|
874
|
+
const reset = useCallback(() => {
|
|
811
875
|
close();
|
|
876
|
+
setSearchValue('');
|
|
877
|
+
}, []);
|
|
878
|
+
const wrapperRef = useOutsideClick(reset);
|
|
879
|
+
const handleChange = useCallback((option) => {
|
|
880
|
+
reset();
|
|
812
881
|
onChange && onChange(option);
|
|
813
882
|
}, [onChange]);
|
|
814
883
|
const isSelected = (option) => option.key === value?.key;
|
|
815
|
-
return (jsxs("div", { className: className, ref: wrapperRef, children: [
|
|
884
|
+
return (jsxs("div", { className: className, ref: wrapperRef, children: [renderLabel(label), jsxs("div", { className: style('relative', isOpen ? 'z-20' : 'z-10'), children: [jsxs("div", { className: style('text-l flex justify-between items-center text-primary-text cursor-pointer relative z-10', getBorderStyle(isBorder, valid)), onClick: toggle, children: [jsx("p", { className: "p-m pr-3xl h-14 overflow-hidden text-ellipsis whitespace-nowrap", children: formatOption(value) || placeholder }), jsx(Icon, { className: style('absolute right-3', isOpen ? '' : 'rotate-180'), name: "ArrowUpIcon", width: "16", height: "16" })] }), isSearch ? renderSearch(isOpen, searchValue, setSearchValue) : null, options?.length ? (jsx("div", { className: style('h-0', isOpen ? '' : 'overflow-hidden'), children: jsx("div", { className: "bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]", children: getFilteredOptions(options, searchValue).map(renderOption(handleChange, isOpen, isSelected)) }) })) : null] })] }));
|
|
816
885
|
});
|
|
886
|
+
const renderLabel = (label) => label ? (jsx("div", { className: "mb-xs", children: jsx(Text, { size: "text-m", color: "text-primary-text", font: "font-light", children: label }) })) : null;
|
|
887
|
+
const getFilteredOptions = (options, searchValue) => {
|
|
888
|
+
return searchValue
|
|
889
|
+
? options.filter((_) => jaroWinklerDistance(_.text?.toLowerCase())(searchValue.toLowerCase()) >= 0.6)
|
|
890
|
+
: options;
|
|
891
|
+
};
|
|
892
|
+
const renderSearch = (isOpen, searchValue, setSearchValue) => isOpen ? (jsx("div", { className: style('absolute top-0 w-full h-full z-20'), children: jsx(Input, { type: "text", autoFocus: true, value: searchValue, onChange: setSearchValue }) })) : null;
|
|
817
893
|
const renderOption = (handleChange, isOpen, isSelected) => (option, i) => (jsxs("div", { onClick: () => {
|
|
818
894
|
handleChange(option);
|
|
819
895
|
}, className: "flex px-m py-s cursor-pointer hover:bg-main-divider pr-5xl relative", children: [jsx("span", { className: "min-h-6", children: formatOption(option) }), jsx(Icon, { name: "DoneSimpleIcon", width: "16", height: "16", className: style('absolute right-4 pt-3xs', isSelected(option) && isOpen ? '' : 'hidden') })] }, String(i)));
|
|
@@ -875,7 +951,7 @@
|
|
|
875
951
|
|
|
876
952
|
const renderBusinessCardDataOrganization = (field) => (jsxs("div", { className: "sm:flex sm:justify-between sm:gap-lg", children: [jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u041A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u043E\u0435 \u043B\u0438\u0446\u043E", ...withValidator(field('name'), nameValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u0418\u041D\u041D", ...withValidator(field('inn'), innValidator) })] }), jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(PhoneInputControl, { className: "shrink-0 w-full", label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...withValidator(field('phone'), phoneValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u042D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u0430\u044F \u043F\u043E\u0447\u0442\u0430", ...withValidator(field('mail'), defaultValidator) })] })] }));
|
|
877
953
|
|
|
878
|
-
const renderRegion = ({ regions, field }) => (jsx(SelectControl, { className: "w-full", label: "\u0420\u0435\u0433\u0438\u043E\u043D", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0440\u0435\u0433\u0438\u043E\u043D", options: regions.map(({ code = '', name = '' }) => ({ key: code, text: name })), ...withValidator(field('region'), defaultValidator) }));
|
|
954
|
+
const renderRegion = ({ regions, field }) => (jsx(SelectControl, { className: "w-full", label: "\u0420\u0435\u0433\u0438\u043E\u043D", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0440\u0435\u0433\u0438\u043E\u043D", isSearch: true, options: regions.map(({ code = '', name = '' }) => ({ key: code, text: name })), ...withValidator(field('region'), defaultValidator) }));
|
|
879
955
|
|
|
880
956
|
const initialFormState$3 = {
|
|
881
957
|
name: '',
|
|
@@ -927,7 +1003,7 @@
|
|
|
927
1003
|
const MAX_CREDIT_TERM = 180;
|
|
928
1004
|
const ITEMS_CREDIT_TERM = ['От 1 мес', 'До 15 лет'];
|
|
929
1005
|
|
|
930
|
-
const renderCreditDataOrganization = (field) => (jsxs("div", { className: "pb-2xs border-b border-b-main-divider sm:flex sm:justify-between sm:gap-lg sm:border-none sm:pb-0", children: [jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u041D\u0430\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u043D\u0438\u0435 \u043E\u0440\u0433\u0430\u043D\u0438\u0437\u0430\u0446\u0438\u0438", ...field('fullName') }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u0418\u041D\u041D", ...withValidator(field('inn'), innValidator) }), jsx(PhoneInputControl, { className: "shrink-0 w-full", label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...withValidator(field('phone'), phoneValidator) })] }), jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u0413\u043E\u0434\u043E\u0432\u0430\u044F \u0432\u044B\u0440\u0443\u0447\u043A\u0430, \u20BD", ...withValidator(field('annualRevenue'), defaultValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u041A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u043E\u0435 \u043B\u0438\u0446\u043E", ...withValidator(field('name'), nameValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u042D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u0430\u044F \u043F\u043E\u0447\u0442\u0430", ...field('mail') })] })] }));
|
|
1006
|
+
const renderCreditDataOrganization = (field) => (jsxs("div", { className: "pb-2xs border-b border-b-main-divider sm:flex sm:justify-between sm:gap-lg sm:border-none sm:pb-0", children: [jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u041D\u0430\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u043D\u0438\u0435 \u043E\u0440\u0433\u0430\u043D\u0438\u0437\u0430\u0446\u0438\u0438", ...withValidator(field('fullName'), defaultValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u0418\u041D\u041D", ...withValidator(field('inn'), innValidator) }), jsx(PhoneInputControl, { className: "shrink-0 w-full", label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...withValidator(field('phone'), phoneValidator) })] }), jsxs("div", { className: "sm:w-1/2 space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u0413\u043E\u0434\u043E\u0432\u0430\u044F \u0432\u044B\u0440\u0443\u0447\u043A\u0430, \u20BD", ...withValidator(field('annualRevenue'), defaultValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u041A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u043E\u0435 \u043B\u0438\u0446\u043E", ...withValidator(field('name'), nameValidator) }), jsx(InputControl, { className: "shrink-0 w-full", label: "\u042D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u0430\u044F \u043F\u043E\u0447\u0442\u0430", ...field('mail') })] })] }));
|
|
931
1007
|
|
|
932
1008
|
const useNormalizedInput = (props, { normalize, format }) => {
|
|
933
1009
|
const { value, onFocus, onBlur, onChange } = props;
|
|
@@ -990,9 +1066,9 @@
|
|
|
990
1066
|
const closestValue = (list) => (_) => list.reduce((prev, curr) => (Math.abs(curr - _) < Math.abs(prev - _) ? curr : prev));
|
|
991
1067
|
const renderRangeCaption = (items) => (jsx("div", { className: "flex justify-between my-xs", children: items.map((item, i) => (jsx(Text, { size: "text-s", font: "font-light", color: "text-secondary-text", children: item }, String(i)))) }));
|
|
992
1068
|
|
|
993
|
-
const renderCreditParameters = (field) => (jsxs("div", { className: "border-b border-b-main-divider sm:flex sm:justify-between gap-lg sm:border-none", children: [jsxs("div", { className: "sm:w-1/2", children: [jsx("label", { children: jsx(Text, { size: "text-m", font: "font-light", children: "\u0421\u0443\u043C\u043C\u0430
|
|
1069
|
+
const renderCreditParameters = (field) => (jsxs("div", { className: "border-b border-b-main-divider sm:flex sm:justify-between gap-lg sm:border-none", children: [jsxs("div", { className: "sm:w-1/2", children: [jsx("label", { children: jsx(Text, { size: "text-m", font: "font-light", children: "\u0421\u0443\u043C\u043C\u0430, \u20BD" }) }), jsx(InputRange, { items: ITEMS_CREDIT_AMOUNT, min: MIN_CREDIT_AMOUNT, max: MAX_CREDIT_AMOUNT, ...field('amount') })] }), jsxs("div", { className: "sm:w-1/2", children: [jsx("label", { children: jsx(Text, { size: "text-m", font: "font-light", children: "\u0421\u0440\u043E\u043A, \u043C\u0435\u0441\u044F\u0446\u0435\u0432" }) }), jsx(InputRange, { items: ITEMS_CREDIT_TERM, min: MIN_CREDIT_TERM, max: MAX_CREDIT_TERM, ...field('term') })] })] }));
|
|
994
1070
|
|
|
995
|
-
const renderRegionDepartment = ({ regions, branches, field }) => (jsxs("div", { className: "sm:flex sm:justify-between sm:gap-m sm:mb-2xl sm:border-none sm:pb-0", children: [jsx("div", { className: "sm:w-1/2", children: jsx(SelectControl, { label: "\u0420\u0435\u0433\u0438\u043E\u043D", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0440\u0435\u0433\u0438\u043E\u043D", options: regions.map(({ code = '', name = '' }) => ({ key: code, text: name })), ...withValidator(field('region'), defaultValidator) }) }), jsx("div", { className: "sm:w-1/2", children: jsx(SelectControl, { label: "\u0410\u0434\u0440\u0435\u0441", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0430\u0434\u0440\u0435\u0441", options: branches.map(({ branchCode = '', address = '' }) => ({
|
|
1071
|
+
const renderRegionDepartment = ({ regions, branches, field }) => (jsxs("div", { className: "sm:flex sm:justify-between sm:gap-m sm:mb-2xl sm:border-none sm:pb-0", children: [jsx("div", { className: "sm:w-1/2", children: jsx(SelectControl, { label: "\u0420\u0435\u0433\u0438\u043E\u043D", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0440\u0435\u0433\u0438\u043E\u043D", isSearch: true, options: regions.map(({ code = '', name = '' }) => ({ key: code, text: name })), ...withValidator(field('region'), defaultValidator) }) }), jsx("div", { className: "sm:w-1/2", children: jsx(SelectControl, { label: "\u0410\u0434\u0440\u0435\u0441", placeholder: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0430\u0434\u0440\u0435\u0441", options: branches.map(({ branchCode = '', address = '' }) => ({
|
|
996
1072
|
key: branchCode,
|
|
997
1073
|
text: address,
|
|
998
1074
|
})), ...withValidator(field('department'), defaultValidator) }) })] }));
|
|
@@ -1008,6 +1084,7 @@
|
|
|
1008
1084
|
annualRevenue: '',
|
|
1009
1085
|
};
|
|
1010
1086
|
const creditValidator = objectValidator({
|
|
1087
|
+
fullName: defaultValidator,
|
|
1011
1088
|
annualRevenue: defaultValidator,
|
|
1012
1089
|
inn: innValidator,
|
|
1013
1090
|
name: nameValidator,
|
|
@@ -1034,7 +1111,7 @@
|
|
|
1034
1111
|
const [formState, { field, ...formProps }] = useForm(initialFormState$2, handleSubmit);
|
|
1035
1112
|
const regions = useGetRegions();
|
|
1036
1113
|
const branches = useBranches(formState.region?.key).filter((branch) => branch?.address);
|
|
1037
|
-
return (jsxs("form", { className: "container space-y-m", onSubmit: formProps.onSubmit, children: [jsx(Heading, { headingType: "h6", title: "\u041F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u044B
|
|
1114
|
+
return (jsxs("form", { className: "container space-y-m", onSubmit: formProps.onSubmit, children: [jsx(Heading, { headingType: "h6", title: "\u041F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u044B", className: "sm:text-center" }), renderCreditParameters(field), jsx(Heading, { headingType: "h6", title: "\u0414\u0430\u043D\u043D\u044B\u0435 \u043E\u0440\u0433\u0430\u043D\u0438\u0437\u0430\u0446\u0438\u0438", className: "sm:text-center" }), renderCreditDataOrganization(field), jsx(Heading, { headingType: "h6", title: "\u041E\u0444\u0438\u0441 \u0431\u0430\u043D\u043A\u0430", className: "sm:text-center" }), renderRegionDepartment({ regions, branches, field }), renderSubmitButton(button), jsx(Footnote, { link: link })] }));
|
|
1038
1115
|
});
|
|
1039
1116
|
|
|
1040
1117
|
const initialFormState$1 = {
|
|
@@ -1275,7 +1352,7 @@
|
|
|
1275
1352
|
},
|
|
1276
1353
|
XS: {
|
|
1277
1354
|
title: { headingType: 'h5', as: 'h2' },
|
|
1278
|
-
descriptionSize: 'text-
|
|
1355
|
+
descriptionSize: 'text-m',
|
|
1279
1356
|
descriptionWeight: 'font-light',
|
|
1280
1357
|
descriptionStyle: 'mt-xs',
|
|
1281
1358
|
},
|
|
@@ -1491,7 +1568,15 @@
|
|
|
1491
1568
|
const DEFAULT_ICON_W = 24;
|
|
1492
1569
|
const renderButtonIcon = (icon) => icon?.icon || icon?.src ? (jsx(Img, { image: icon, width: String(icon?.size?.width || DEFAULT_ICON_W), height: String(DEFAULT_ICON_W) })) : null;
|
|
1493
1570
|
|
|
1494
|
-
const
|
|
1571
|
+
const alignStyleMap = {
|
|
1572
|
+
start: 'justify-start',
|
|
1573
|
+
center: 'justify-center',
|
|
1574
|
+
end: 'justify-end',
|
|
1575
|
+
};
|
|
1576
|
+
const ButtonsBlock = JSX(({ buttons, className = '', align, ...rest }) => {
|
|
1577
|
+
const alignStyle = align ? style('flex', alignStyleMap[align]) : '';
|
|
1578
|
+
return (jsx(BlockWrapper, { className: style('!bg-transparent', alignStyle, className), defaultPadding: "p-0", ...rest, children: renderButtonsSection(buttons) }));
|
|
1579
|
+
});
|
|
1495
1580
|
|
|
1496
1581
|
const Foldable = JSX(({ className = '', isFoldButtonOnTop = false, unfoldedByDefault = false, renderFoldableSection, renderFoldButton, }) => {
|
|
1497
1582
|
const [isUnfolded, setIsUnfolded] = useState(unfoldedByDefault);
|
|
@@ -2383,13 +2468,21 @@
|
|
|
2383
2468
|
const renderCardHighlight = ({ className, text = 'ХИТ' } = {}) => (jsxs("div", { className: style('w-14 h-14 bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]', className), children: [jsx(Icon, { iconVersion: "black", name: "HeartIcon", width: "24", height: "24" }), jsx(Paragraph, { size: "text-s", font: "font-normal", align: "text-center", color: "text-primary-text", children: text })] }));
|
|
2384
2469
|
|
|
2385
2470
|
const cardBaseStyle = 'relative h-full';
|
|
2386
|
-
const
|
|
2471
|
+
const CARD_SIZE_MAP = {
|
|
2472
|
+
normal: 'sm:min-w-96',
|
|
2473
|
+
big: 'sm:min-w-[515px]',
|
|
2474
|
+
};
|
|
2475
|
+
const renderCarouselCards = ({ noCardBorder, activeIndex, cardSize = 'normal', ...rest }) => {
|
|
2387
2476
|
const { blocks: childBlocks } = rest.block || {};
|
|
2388
2477
|
const someCardsHighlighted = childBlocks?.some(isCardHighlighted);
|
|
2389
2478
|
return renderChildren({
|
|
2390
2479
|
...rest,
|
|
2391
2480
|
renderProps: (block, options, blockIndex) => (jsxs("div", { className: cardWrapperStyle(block, { someCardsHighlighted }), children: [renderBlock(block, options, {
|
|
2392
|
-
className: cardStyle(block, {
|
|
2481
|
+
className: cardStyle(block, {
|
|
2482
|
+
someCardsHighlighted,
|
|
2483
|
+
showBorder: !noCardBorder,
|
|
2484
|
+
cardSize,
|
|
2485
|
+
}),
|
|
2393
2486
|
blockIndex,
|
|
2394
2487
|
isActive: blockIndex === activeIndex,
|
|
2395
2488
|
}), isCardHighlighted(block)
|
|
@@ -2398,11 +2491,12 @@
|
|
|
2398
2491
|
});
|
|
2399
2492
|
};
|
|
2400
2493
|
const cardWrapperStyle = (_, { someCardsHighlighted }) => style(cardBaseStyle, someCardsHighlighted && (isCardHighlighted(_) ? 'pt-3xl' : 'pt-3xl sm:pt-16'));
|
|
2401
|
-
const cardStyle = (_, { someCardsHighlighted, showBorder }) => style(cardBaseStyle, 'min-w-80
|
|
2494
|
+
const cardStyle = (_, { someCardsHighlighted, showBorder, cardSize = 'normal', }) => style(cardBaseStyle, 'min-w-80', CARD_SIZE_MAP[cardSize], // TODO fix для RecommendationCard
|
|
2495
|
+
someCardsHighlighted && (isCardHighlighted(_) ? 'pt-3xl sm:pt-16' : 'pt-3xl'), showBorder &&
|
|
2402
2496
|
'border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider');
|
|
2403
2497
|
const isCardHighlighted = (_) => _?.content && 'isHighlighting' in _.content && _.content.isHighlighting;
|
|
2404
2498
|
|
|
2405
|
-
const Carousel = JSX(({ className, itemCount, visibleItemCount = 0, noCardBorder, isAlignCenter, showDots, arrowsPadded = true, isGap = true, ...rest }) => {
|
|
2499
|
+
const Carousel = JSX(({ className, itemCount, visibleItemCount = 0, noCardBorder, isAlignCenter, showDots, arrowsPadded = true, isGap = true, cardSize = 'normal', ...rest }) => {
|
|
2406
2500
|
const { blocks: childBlocks = [] } = rest.block || {};
|
|
2407
2501
|
const count = itemCount || childBlocks?.length;
|
|
2408
2502
|
const [activeIndex, { inc: increaseActiveIndex, dec: decreaseActiveIndex }] = useCarouselControls({
|
|
@@ -2413,7 +2507,7 @@
|
|
|
2413
2507
|
const [dotsActiveIndex] = scroll.visibleIndicesRange;
|
|
2414
2508
|
// TODO Remove
|
|
2415
2509
|
const isBankHistoryCarousel = childBlocks && childBlocks[0]?.type === 'CarouselBankHistoryCard';
|
|
2416
|
-
return (jsx(BlockWrapper, { className: className, defaultPadding: "p-6xl", ...rest, children: jsxs("div", { className: style(isAlignCenter ? 'flex justify-center' : '', 'relative max-w-full'), children: [jsx(SwipeListContainer, { containerRef: containerRef, visibleItemCount: visibleItemCount, snapAlign: "snap-start", gap: isGap ? ITEMS_GAP : undefined, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: renderCarouselCards({ noCardBorder, activeIndex, ...rest }) }), jsx(CarouselScrollButtons, { scroll: scroll, arrowsPadded: arrowsPadded, onScrollLeft: decreaseActiveIndex, onScrollRight: increaseActiveIndex, hasEdgeBlocks: isBankHistoryCarousel, activeIndex: activeIndex, itemCount: count }), showDots ? (jsx(SwipeListControlDots, { containerRef: containerRef, activeIndex: dotsActiveIndex, dotCount: count, listType: "horizontal-list" })) : null] }) }));
|
|
2510
|
+
return (jsx(BlockWrapper, { className: className, defaultPadding: "p-6xl", ...rest, children: jsxs("div", { className: style(isAlignCenter ? 'flex justify-center' : '', 'relative max-w-full'), children: [jsx(SwipeListContainer, { containerRef: containerRef, visibleItemCount: visibleItemCount, snapAlign: "snap-start", gap: isGap ? ITEMS_GAP : undefined, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: renderCarouselCards({ noCardBorder, activeIndex, cardSize, ...rest }) }), jsx(CarouselScrollButtons, { scroll: scroll, arrowsPadded: arrowsPadded, onScrollLeft: decreaseActiveIndex, onScrollRight: increaseActiveIndex, hasEdgeBlocks: isBankHistoryCarousel, activeIndex: activeIndex, itemCount: count }), showDots ? (jsx(SwipeListControlDots, { containerRef: containerRef, activeIndex: dotsActiveIndex, dotCount: count, listType: "horizontal-list" })) : null] }) }));
|
|
2417
2511
|
});
|
|
2418
2512
|
Carousel.childrenTypes = [
|
|
2419
2513
|
'CarouselCard',
|
|
@@ -2464,15 +2558,18 @@
|
|
|
2464
2558
|
L: 'w-1.5 h-1.5 mr-m',
|
|
2465
2559
|
M: 'w-1.5 h-1.5 mr-s',
|
|
2466
2560
|
S: 'w-1 h-1 mr-xs',
|
|
2561
|
+
XS: 'w-1 h-1 mr-xs',
|
|
2467
2562
|
};
|
|
2468
2563
|
const ListItem = JSX(({ className, isDotted = true, children, size = 'M' }) => (jsxs("div", { className: style('font-sans flex', className), role: "listitem", children: [isDotted ? (jsx("div", { className: "shrink-0", children: jsx("div", { className: style('align-middle inline-block rounded-full bg-primary-text group-data-secondary:bg-white', DOT_SIZE_MAP[size]) }) })) : null, jsx("span", { children: children })] })));
|
|
2469
2564
|
|
|
2470
2565
|
const TEXT_SIZE_MAP = {
|
|
2566
|
+
XS: 'text-m font-light',
|
|
2471
2567
|
S: 'text-l font-light',
|
|
2472
2568
|
M: 'text-h6',
|
|
2473
2569
|
L: 'text-h5',
|
|
2474
2570
|
};
|
|
2475
2571
|
const ITEM_INDENT_MAP = {
|
|
2572
|
+
XS: 'ml-2xs',
|
|
2476
2573
|
S: 'ml-xs',
|
|
2477
2574
|
M: 'ml-s',
|
|
2478
2575
|
L: 'ml-m',
|
|
@@ -2501,7 +2598,7 @@
|
|
|
2501
2598
|
const BaseTile = JSX(({ className, defaultPadding, padding, title = '', insetTitle = '', buttons, leftImage, rightImage, imageAlign, backImage, children, }) => (jsxs("div", { className: style('relative flex flex-col gap-3xl font-sans overflow-hidden', padding || defaultPadding, className), children: [title ? jsx("div", { className: "relative", children: title }) : null, jsxs("div", { className: "grow relative flex flex-wrap @xl:flex-nowrap justify-around @xl:justify-between items-stretch gap-3xl", children: [renderImageContainer(leftImage, { imageAlign }), jsxs("div", { className: style('flex flex-col gap-3xl max-w-[600px] @xl:max-w-[728px]', leftImage ? '' : 'grow'), children: [insetTitle, jsx("div", { className: "grow", children: children }), backImage ? (jsx("div", { className: "mx-auto sm:absolute sm:-z-10 sm:-bottom-4 sm:-right-4", children: backImage })) : null, buttons] }), renderImageContainer(rightImage, { className: '-order-1 @xl:order-1', imageAlign })] })] })));
|
|
2502
2599
|
const renderImageContainer = (image, { className, imageAlign }) => {
|
|
2503
2600
|
//TODO Спорное решение
|
|
2504
|
-
const fullWidth = image?.props?.image
|
|
2601
|
+
const fullWidth = image?.props?.image?.size?.width > 400;
|
|
2505
2602
|
return image ? (jsx("div", { className: style('flex-shrink-0', fullWidth ? 'w-full @xl:w-auto' : '', imageAlign && imageAlignmentMap[imageAlign], className), children: image })) : null;
|
|
2506
2603
|
};
|
|
2507
2604
|
|
|
@@ -2561,7 +2658,7 @@
|
|
|
2561
2658
|
})) }) }) })));
|
|
2562
2659
|
|
|
2563
2660
|
const buttonSizeStyles = {
|
|
2564
|
-
default: 'w-
|
|
2661
|
+
default: 'w-14 h-14',
|
|
2565
2662
|
stretched: 'flex-1 h-14',
|
|
2566
2663
|
};
|
|
2567
2664
|
|
|
@@ -2615,7 +2712,7 @@
|
|
|
2615
2712
|
const SocialMedia = JSX(({ className = '', media, children, buttonSize }) => (jsxs("div", { className: "flex flex-col sm:flex-col-reverse gap-xs", children: [children ? (jsx(Text, { size: "text-s", font: "font-light", color: "text-secondary-text", children: children })) : null, jsx("div", { className: style('flex gap-xs', className), children: media?.map((_, index) => (jsx(MediaButton, { buttonSize: buttonSize, ..._ }, String(index)))) })] })));
|
|
2616
2713
|
|
|
2617
2714
|
const CarouselRecommendationCard = JSX(({ className = '', description, href, icon, items = [], socialMedia = [], target, title, align = 'text-left', ...rest }) => {
|
|
2618
|
-
return (jsx(BlockWrapper, { className: style('relative group-data-gray:bg-main-divider/50
|
|
2715
|
+
return (jsx(BlockWrapper, { className: style('relative group-data-gray:bg-main-divider/50', className), defaultPadding: "p-3xl", ...rest, children: jsxs(LinkWrapper, { href: href, target: target, className: 'space-y-lg', children: [jsx(Headline, { title: title, description: description, headlineVersion: "XS", isEmbedded: true, align: align }), items.length ? (jsx(List, { className: "flex flex-col gap-xs", items: items, listItemSize: "XS" })) : null, renderIcon$1(icon), socialMedia.length ? jsx(SocialMedia, { media: socialMedia }) : null] }) }));
|
|
2619
2716
|
});
|
|
2620
2717
|
const renderIcon$1 = (icon) => icon?.src || icon?.icon ? (jsx("div", { children: jsx(Img, { image: icon }) })) : null;
|
|
2621
2718
|
|
|
@@ -3863,19 +3960,16 @@
|
|
|
3863
3960
|
return [list, { setList, push, pop, remove, clear }];
|
|
3864
3961
|
}
|
|
3865
3962
|
|
|
3866
|
-
const
|
|
3963
|
+
const useDialogsList = ({ onCloseAll, onClose, } = {}) => {
|
|
3867
3964
|
const [dialogs, { push, pop, clear }] = useList();
|
|
3868
3965
|
const closeAll = useCallback(() => {
|
|
3869
|
-
|
|
3870
|
-
_.onClose && _.onClose();
|
|
3871
|
-
}
|
|
3966
|
+
onCloseAll && onCloseAll(dialogs);
|
|
3872
3967
|
clear();
|
|
3873
|
-
}, [dialogs]);
|
|
3968
|
+
}, [dialogs, onCloseAll]);
|
|
3874
3969
|
const close = useCallback(() => {
|
|
3875
|
-
|
|
3876
|
-
_?.onClose && _.onClose();
|
|
3970
|
+
onClose && onClose(dialogs[dialogs.length - 1]);
|
|
3877
3971
|
pop();
|
|
3878
|
-
}, [dialogs]);
|
|
3972
|
+
}, [dialogs, onClose]);
|
|
3879
3973
|
useEffect(() => defaultEventBus.subscribe('dialog', (action) => {
|
|
3880
3974
|
switch (action.type) {
|
|
3881
3975
|
case 'open':
|
|
@@ -3893,6 +3987,20 @@
|
|
|
3893
3987
|
assertUnreachable(action);
|
|
3894
3988
|
}
|
|
3895
3989
|
}), [closeAll, close]);
|
|
3990
|
+
return dialogs;
|
|
3991
|
+
};
|
|
3992
|
+
|
|
3993
|
+
const DialogManager = JSX(() => {
|
|
3994
|
+
const handleCloseAll = useCallback((dialogs) => {
|
|
3995
|
+
for (const _ of dialogs) {
|
|
3996
|
+
_?.onClose && _.onClose();
|
|
3997
|
+
}
|
|
3998
|
+
}, []);
|
|
3999
|
+
const handleClose = useCallback((_) => {
|
|
4000
|
+
_?.onClose && _.onClose();
|
|
4001
|
+
}, []);
|
|
4002
|
+
const dialogs = useDialogsList({ onCloseAll: handleCloseAll, onClose: handleClose });
|
|
4003
|
+
const { close } = useDialogManager();
|
|
3896
4004
|
useEffect(() => {
|
|
3897
4005
|
const handleEscape = ({ key }) => {
|
|
3898
4006
|
if (key === 'Escape') {
|
|
@@ -3976,7 +4084,7 @@
|
|
|
3976
4084
|
|
|
3977
4085
|
const joinList = (sep) => (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: `sep-${i}` }, el) : [el]), []);
|
|
3978
4086
|
|
|
3979
|
-
const packageVersion = "0.13.
|
|
4087
|
+
const packageVersion = "0.13.6";
|
|
3980
4088
|
|
|
3981
4089
|
exports.Blocks = Blocks;
|
|
3982
4090
|
exports.ContentPage = ContentPage;
|