@vkontakte/vkui 7.0.0-dev-efd91c.2 → 7.0.0-dev-efd91c.3
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/dist/components/ActionSheet/ActionSheet.js +2 -2
- package/dist/components/ActionSheet/ActionSheet.js.map +1 -1
- package/dist/components/ActionSheetItem/ActionSheetItem.d.ts +1 -1
- package/dist/components/ActionSheetItem/ActionSheetItem.d.ts.map +1 -1
- package/dist/components/ActionSheetItem/ActionSheetItem.js +2 -3
- package/dist/components/ActionSheetItem/ActionSheetItem.js.map +1 -1
- package/dist/components/AdaptivityProvider/AdaptivityContext.d.ts.map +1 -1
- package/dist/components/AdaptivityProvider/AdaptivityContext.js +1 -0
- package/dist/components/AdaptivityProvider/AdaptivityContext.js.map +1 -1
- package/dist/components/Alert/Alert.js +2 -2
- package/dist/components/Alert/Alert.js.map +1 -1
- package/dist/components/Alert/AlertAction.js +1 -1
- package/dist/components/Alert/AlertAction.js.map +1 -1
- package/dist/components/AppRoot/AppRoot.d.ts +1 -1
- package/dist/components/AppRoot/AppRoot.d.ts.map +1 -1
- package/dist/components/AppRoot/AppRoot.js +6 -43
- package/dist/components/AppRoot/AppRoot.js.map +1 -1
- package/dist/components/AppRoot/AppRootContext.d.ts +1 -3
- package/dist/components/AppRoot/AppRootContext.d.ts.map +1 -1
- package/dist/components/AppRoot/AppRootContext.js +0 -3
- package/dist/components/AppRoot/AppRootContext.js.map +1 -1
- package/dist/components/AppRoot/AppRootPortal.d.ts +5 -5
- package/dist/components/AppRoot/AppRootPortal.d.ts.map +1 -1
- package/dist/components/AppRoot/AppRootPortal.js +12 -29
- package/dist/components/AppRoot/AppRootPortal.js.map +1 -1
- package/dist/components/AppRoot/helpers.d.ts +0 -1
- package/dist/components/AppRoot/helpers.d.ts.map +1 -1
- package/dist/components/AppRoot/helpers.js +0 -1
- package/dist/components/AppRoot/helpers.js.map +1 -1
- package/dist/components/AspectRatio/AspectRatio.d.ts +1 -1
- package/dist/components/AspectRatio/AspectRatio.d.ts.map +1 -1
- package/dist/components/AspectRatio/AspectRatio.js +3 -4
- package/dist/components/AspectRatio/AspectRatio.js.map +1 -1
- package/dist/components/Avatar/Avatar.d.ts +2 -1
- package/dist/components/Avatar/Avatar.d.ts.map +1 -1
- package/dist/components/Avatar/Avatar.js +2 -1
- package/dist/components/Avatar/Avatar.js.map +1 -1
- package/dist/components/Banner/Banner.d.ts +1 -1
- package/dist/components/Banner/Banner.d.ts.map +1 -1
- package/dist/components/Banner/Banner.js +2 -3
- package/dist/components/Banner/Banner.js.map +1 -1
- package/dist/components/Button/Button.d.ts +1 -1
- package/dist/components/Button/Button.d.ts.map +1 -1
- package/dist/components/Button/Button.js +2 -3
- package/dist/components/Button/Button.js.map +1 -1
- package/dist/components/CalendarDay/CalendarDay.d.ts.map +1 -1
- package/dist/components/CalendarDay/CalendarDay.js +2 -3
- package/dist/components/CalendarDay/CalendarDay.js.map +1 -1
- package/dist/components/CalendarHeader/CalendarHeader.js +2 -2
- package/dist/components/CalendarHeader/CalendarHeader.js.map +1 -1
- package/dist/components/ColorSchemeProvider/ColorSchemeProvider.d.ts.map +1 -1
- package/dist/components/ColorSchemeProvider/ColorSchemeProvider.js +2 -0
- package/dist/components/ColorSchemeProvider/ColorSchemeProvider.js.map +1 -1
- package/dist/components/ConfigProvider/ConfigProviderContext.d.ts.map +1 -1
- package/dist/components/ConfigProvider/ConfigProviderContext.js +1 -0
- package/dist/components/ConfigProvider/ConfigProviderContext.js.map +1 -1
- package/dist/components/ContentBadge/ContentBadgeContext.d.ts.map +1 -1
- package/dist/components/ContentBadge/ContentBadgeContext.js +1 -0
- package/dist/components/ContentBadge/ContentBadgeContext.js.map +1 -1
- package/dist/components/Counter/Counter.d.ts.map +1 -1
- package/dist/components/Counter/Counter.js +8 -9
- package/dist/components/Counter/Counter.js.map +1 -1
- package/dist/components/CustomSelectOption/CustomSelectOption.d.ts.map +1 -1
- package/dist/components/CustomSelectOption/CustomSelectOption.js +5 -5
- package/dist/components/CustomSelectOption/CustomSelectOption.js.map +1 -1
- package/dist/components/Flex/Flex.d.ts.map +1 -1
- package/dist/components/Flex/Flex.js +2 -3
- package/dist/components/Flex/Flex.js.map +1 -1
- package/dist/components/Flex/FlexItem/FlexItem.d.ts +1 -1
- package/dist/components/Flex/FlexItem/FlexItem.d.ts.map +1 -1
- package/dist/components/Flex/FlexItem/FlexItem.js +4 -5
- package/dist/components/Flex/FlexItem/FlexItem.js.map +1 -1
- package/dist/components/FloatingArrow/DefaultIcon.d.ts +7 -3
- package/dist/components/FloatingArrow/DefaultIcon.d.ts.map +1 -1
- package/dist/components/FloatingArrow/DefaultIcon.js +10 -6
- package/dist/components/FloatingArrow/DefaultIcon.js.map +1 -1
- package/dist/components/FloatingArrow/FloatingArrow.d.ts +9 -2
- package/dist/components/FloatingArrow/FloatingArrow.d.ts.map +1 -1
- package/dist/components/FloatingArrow/FloatingArrow.js +9 -8
- package/dist/components/FloatingArrow/FloatingArrow.js.map +1 -1
- package/dist/components/HorizontalCell/HorizontalCell.d.ts +11 -1
- package/dist/components/HorizontalCell/HorizontalCell.d.ts.map +1 -1
- package/dist/components/HorizontalCell/HorizontalCell.js +15 -7
- package/dist/components/HorizontalCell/HorizontalCell.js.map +1 -1
- package/dist/components/IconButton/IconButton.d.ts +1 -1
- package/dist/components/IconButton/IconButton.d.ts.map +1 -1
- package/dist/components/IconButton/IconButton.js +3 -4
- package/dist/components/IconButton/IconButton.js.map +1 -1
- package/dist/components/Image/Image.d.ts.map +1 -1
- package/dist/components/Image/Image.js +2 -1
- package/dist/components/Image/Image.js.map +1 -1
- package/dist/components/ImageBase/ImageBase.d.ts.map +1 -1
- package/dist/components/ImageBase/ImageBase.js +3 -4
- package/dist/components/ImageBase/ImageBase.js.map +1 -1
- package/dist/components/Link/Link.d.ts +1 -1
- package/dist/components/Link/Link.d.ts.map +1 -1
- package/dist/components/Link/Link.js +3 -4
- package/dist/components/Link/Link.js.map +1 -1
- package/dist/components/List/List.d.ts +1 -1
- package/dist/components/List/List.d.ts.map +1 -1
- package/dist/components/List/List.js +5 -8
- package/dist/components/List/List.js.map +1 -1
- package/dist/components/MiniInfoCell/MiniInfoCell.d.ts +1 -1
- package/dist/components/MiniInfoCell/MiniInfoCell.d.ts.map +1 -1
- package/dist/components/MiniInfoCell/MiniInfoCell.js +4 -5
- package/dist/components/MiniInfoCell/MiniInfoCell.js.map +1 -1
- package/dist/components/ModalCardBase/ModalCardBase.d.ts +1 -1
- package/dist/components/ModalCardBase/ModalCardBase.d.ts.map +1 -1
- package/dist/components/ModalCardBase/ModalCardBase.js +3 -4
- package/dist/components/ModalCardBase/ModalCardBase.js.map +1 -1
- package/dist/components/ModalDismissButton/ModalDismissButton.d.ts +1 -1
- package/dist/components/ModalDismissButton/ModalDismissButton.d.ts.map +1 -1
- package/dist/components/ModalDismissButton/ModalDismissButton.js +3 -5
- package/dist/components/ModalDismissButton/ModalDismissButton.js.map +1 -1
- package/dist/components/ModalRoot/ModalRoot.d.ts.map +1 -1
- package/dist/components/ModalRoot/ModalRoot.js +3 -2
- package/dist/components/ModalRoot/ModalRoot.js.map +1 -1
- package/dist/components/ModalRoot/ModalRootContext.d.ts.map +1 -1
- package/dist/components/ModalRoot/ModalRootContext.js +1 -0
- package/dist/components/ModalRoot/ModalRootContext.js.map +1 -1
- package/dist/components/ModalRoot/types.d.ts.map +1 -1
- package/dist/components/ModalRoot/types.js.map +1 -1
- package/dist/components/NavIdContext/NavIdContext.d.ts.map +1 -1
- package/dist/components/NavIdContext/NavIdContext.js +1 -0
- package/dist/components/NavIdContext/NavIdContext.js.map +1 -1
- package/dist/components/OnboardingTooltip/OnboardingTooltip.d.ts.map +1 -1
- package/dist/components/OnboardingTooltip/OnboardingTooltip.js +2 -4
- package/dist/components/OnboardingTooltip/OnboardingTooltip.js.map +1 -1
- package/dist/components/PanelHeaderButton/PanelHeaderButton.d.ts +1 -1
- package/dist/components/PanelHeaderButton/PanelHeaderButton.d.ts.map +1 -1
- package/dist/components/PanelHeaderButton/PanelHeaderButton.js +3 -4
- package/dist/components/PanelHeaderButton/PanelHeaderButton.js.map +1 -1
- package/dist/components/Popper/Popper.d.ts +1 -1
- package/dist/components/Popper/Popper.d.ts.map +1 -1
- package/dist/components/Popper/Popper.js +2 -3
- package/dist/components/Popper/Popper.js.map +1 -1
- package/dist/components/Progress/Progress.d.ts +1 -1
- package/dist/components/Progress/Progress.d.ts.map +1 -1
- package/dist/components/Progress/Progress.js +4 -5
- package/dist/components/Progress/Progress.js.map +1 -1
- package/dist/components/RichCell/RichCell.d.ts.map +1 -1
- package/dist/components/RichCell/RichCell.js +2 -3
- package/dist/components/RichCell/RichCell.js.map +1 -1
- package/dist/components/RootComponent/RootComponent.d.ts +2 -1
- package/dist/components/RootComponent/RootComponent.d.ts.map +1 -1
- package/dist/components/RootComponent/RootComponent.js +6 -2
- package/dist/components/RootComponent/RootComponent.js.map +1 -1
- package/dist/components/ScreenSpinner/ScreenSpinner.js +2 -2
- package/dist/components/ScreenSpinner/ScreenSpinner.js.map +1 -1
- package/dist/components/ScreenSpinner/context.d.ts.map +1 -1
- package/dist/components/ScreenSpinner/context.js +1 -0
- package/dist/components/ScreenSpinner/context.js.map +1 -1
- package/dist/components/Separator/Separator.d.ts +1 -1
- package/dist/components/Separator/Separator.d.ts.map +1 -1
- package/dist/components/Separator/Separator.js +2 -3
- package/dist/components/Separator/Separator.js.map +1 -1
- package/dist/components/SimpleCell/SimpleCell.d.ts +1 -1
- package/dist/components/SimpleCell/SimpleCell.d.ts.map +1 -1
- package/dist/components/SimpleCell/SimpleCell.js +2 -3
- package/dist/components/SimpleCell/SimpleCell.js.map +1 -1
- package/dist/components/SimpleGrid/SimpleGrid.d.ts +1 -1
- package/dist/components/SimpleGrid/SimpleGrid.d.ts.map +1 -1
- package/dist/components/SimpleGrid/SimpleGrid.js +2 -3
- package/dist/components/SimpleGrid/SimpleGrid.js.map +1 -1
- package/dist/components/Skeleton/Skeleton.d.ts +1 -1
- package/dist/components/Skeleton/Skeleton.d.ts.map +1 -1
- package/dist/components/Skeleton/Skeleton.js +2 -3
- package/dist/components/Skeleton/Skeleton.js.map +1 -1
- package/dist/components/Snackbar/Snackbar.d.ts.map +1 -1
- package/dist/components/Snackbar/Snackbar.js +2 -3
- package/dist/components/Snackbar/Snackbar.js.map +1 -1
- package/dist/components/Snackbar/utils.d.ts +1 -1
- package/dist/components/Snackbar/utils.d.ts.map +1 -1
- package/dist/components/Snackbar/utils.js +6 -8
- package/dist/components/Snackbar/utils.js.map +1 -1
- package/dist/components/Spacing/Spacing.d.ts +1 -1
- package/dist/components/Spacing/Spacing.d.ts.map +1 -1
- package/dist/components/Spacing/Spacing.js +3 -4
- package/dist/components/Spacing/Spacing.js.map +1 -1
- package/dist/components/SplitCol/SplitCol.d.ts.map +1 -1
- package/dist/components/SplitCol/SplitCol.js +3 -4
- package/dist/components/SplitCol/SplitCol.js.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.d.ts.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.js +1 -5
- package/dist/components/SplitLayout/SplitLayout.js.map +1 -1
- package/dist/components/SubnavigationButton/SubnavigationButton.d.ts +1 -1
- package/dist/components/SubnavigationButton/SubnavigationButton.d.ts.map +1 -1
- package/dist/components/SubnavigationButton/SubnavigationButton.js +3 -4
- package/dist/components/SubnavigationButton/SubnavigationButton.js.map +1 -1
- package/dist/components/TabsItem/TabsItem.d.ts +1 -1
- package/dist/components/TabsItem/TabsItem.d.ts.map +1 -1
- package/dist/components/TabsItem/TabsItem.js +2 -3
- package/dist/components/TabsItem/TabsItem.js.map +1 -1
- package/dist/components/ToolButton/ToolButton.d.ts +1 -1
- package/dist/components/ToolButton/ToolButton.d.ts.map +1 -1
- package/dist/components/ToolButton/ToolButton.js +2 -3
- package/dist/components/ToolButton/ToolButton.js.map +1 -1
- package/dist/components/WriteBarIcon/WriteBarIcon.d.ts +1 -1
- package/dist/components/WriteBarIcon/WriteBarIcon.d.ts.map +1 -1
- package/dist/components/WriteBarIcon/WriteBarIcon.js +2 -3
- package/dist/components/WriteBarIcon/WriteBarIcon.js.map +1 -1
- package/dist/components.css +1 -1
- package/dist/components.css.map +1 -1
- package/dist/cssm/components/ActionSheet/ActionSheet.js +2 -2
- package/dist/cssm/components/ActionSheet/ActionSheet.js.map +1 -1
- package/dist/cssm/components/ActionSheetItem/ActionSheetItem.js +2 -2
- package/dist/cssm/components/ActionSheetItem/ActionSheetItem.js.map +1 -1
- package/dist/cssm/components/AdaptivityProvider/AdaptivityContext.js +1 -0
- package/dist/cssm/components/AdaptivityProvider/AdaptivityContext.js.map +1 -1
- package/dist/cssm/components/Alert/Alert.js +2 -2
- package/dist/cssm/components/Alert/Alert.js.map +1 -1
- package/dist/cssm/components/Alert/AlertAction.js +1 -1
- package/dist/cssm/components/Alert/AlertAction.js.map +1 -1
- package/dist/cssm/components/AppRoot/AppRoot.js +6 -43
- package/dist/cssm/components/AppRoot/AppRoot.js.map +1 -1
- package/dist/cssm/components/AppRoot/AppRootContext.js +0 -3
- package/dist/cssm/components/AppRoot/AppRootContext.js.map +1 -1
- package/dist/cssm/components/AppRoot/AppRootPortal.js +12 -29
- package/dist/cssm/components/AppRoot/AppRootPortal.js.map +1 -1
- package/dist/cssm/components/AppRoot/helpers.js +0 -1
- package/dist/cssm/components/AppRoot/helpers.js.map +1 -1
- package/dist/cssm/components/AspectRatio/AspectRatio.js +2 -5
- package/dist/cssm/components/AspectRatio/AspectRatio.js.map +1 -1
- package/dist/cssm/components/Avatar/Avatar.js +2 -1
- package/dist/cssm/components/Avatar/Avatar.js.map +1 -1
- package/dist/cssm/components/Banner/Banner.js +2 -2
- package/dist/cssm/components/Banner/Banner.js.map +1 -1
- package/dist/cssm/components/Button/Button.js +2 -2
- package/dist/cssm/components/Button/Button.js.map +1 -1
- package/dist/cssm/components/CalendarDay/CalendarDay.js +2 -2
- package/dist/cssm/components/CalendarDay/CalendarDay.js.map +1 -1
- package/dist/cssm/components/CalendarHeader/CalendarHeader.js +2 -2
- package/dist/cssm/components/CalendarHeader/CalendarHeader.js.map +1 -1
- package/dist/cssm/components/ColorSchemeProvider/ColorSchemeProvider.js +2 -0
- package/dist/cssm/components/ColorSchemeProvider/ColorSchemeProvider.js.map +1 -1
- package/dist/cssm/components/ConfigProvider/ConfigProviderContext.js +1 -0
- package/dist/cssm/components/ConfigProvider/ConfigProviderContext.js.map +1 -1
- package/dist/cssm/components/ContentBadge/ContentBadgeContext.js +1 -0
- package/dist/cssm/components/ContentBadge/ContentBadgeContext.js.map +1 -1
- package/dist/cssm/components/Counter/Counter.js +4 -7
- package/dist/cssm/components/Counter/Counter.js.map +1 -1
- package/dist/cssm/components/CustomSelectOption/CustomSelectOption.js +5 -6
- package/dist/cssm/components/CustomSelectOption/CustomSelectOption.js.map +1 -1
- package/dist/cssm/components/Flex/Flex.js +2 -5
- package/dist/cssm/components/Flex/Flex.js.map +1 -1
- package/dist/cssm/components/Flex/FlexItem/FlexItem.js +3 -4
- package/dist/cssm/components/Flex/FlexItem/FlexItem.js.map +1 -1
- package/dist/cssm/components/FloatingArrow/DefaultIcon.js +10 -6
- package/dist/cssm/components/FloatingArrow/DefaultIcon.js.map +1 -1
- package/dist/cssm/components/FloatingArrow/FloatingArrow.js +9 -7
- package/dist/cssm/components/FloatingArrow/FloatingArrow.js.map +1 -1
- package/dist/cssm/components/FloatingArrow/FloatingArrow.module.css +1 -1
- package/dist/cssm/components/HorizontalCell/HorizontalCell.js +12 -9
- package/dist/cssm/components/HorizontalCell/HorizontalCell.js.map +1 -1
- package/dist/cssm/components/HorizontalCell/HorizontalCell.module.css +23 -6
- package/dist/cssm/components/IconButton/IconButton.js +2 -2
- package/dist/cssm/components/IconButton/IconButton.js.map +1 -1
- package/dist/cssm/components/Image/Image.js +2 -4
- package/dist/cssm/components/Image/Image.js.map +1 -1
- package/dist/cssm/components/ImageBase/ImageBase.js +3 -4
- package/dist/cssm/components/ImageBase/ImageBase.js.map +1 -1
- package/dist/cssm/components/Link/Link.js +2 -2
- package/dist/cssm/components/Link/Link.js.map +1 -1
- package/dist/cssm/components/List/List.js +4 -6
- package/dist/cssm/components/List/List.js.map +1 -1
- package/dist/cssm/components/MiniInfoCell/MiniInfoCell.js +3 -3
- package/dist/cssm/components/MiniInfoCell/MiniInfoCell.js.map +1 -1
- package/dist/cssm/components/ModalCardBase/ModalCardBase.js +3 -4
- package/dist/cssm/components/ModalCardBase/ModalCardBase.js.map +1 -1
- package/dist/cssm/components/ModalDismissButton/ModalDismissButton.js +2 -3
- package/dist/cssm/components/ModalDismissButton/ModalDismissButton.js.map +1 -1
- package/dist/cssm/components/ModalOverlay/ModalOverlay.module.css +1 -0
- package/dist/cssm/components/ModalRoot/ModalRoot.js +3 -2
- package/dist/cssm/components/ModalRoot/ModalRoot.js.map +1 -1
- package/dist/cssm/components/ModalRoot/ModalRootContext.js +1 -0
- package/dist/cssm/components/ModalRoot/ModalRootContext.js.map +1 -1
- package/dist/cssm/components/ModalRoot/types.js.map +1 -1
- package/dist/cssm/components/NavIdContext/NavIdContext.js +1 -0
- package/dist/cssm/components/NavIdContext/NavIdContext.js.map +1 -1
- package/dist/cssm/components/OnboardingTooltip/OnboardingTooltip.js +2 -4
- package/dist/cssm/components/OnboardingTooltip/OnboardingTooltip.js.map +1 -1
- package/dist/cssm/components/PanelHeaderButton/PanelHeaderButton.js +2 -2
- package/dist/cssm/components/PanelHeaderButton/PanelHeaderButton.js.map +1 -1
- package/dist/cssm/components/Popper/Popper.js +2 -5
- package/dist/cssm/components/Popper/Popper.js.map +1 -1
- package/dist/cssm/components/Progress/Progress.js +2 -5
- package/dist/cssm/components/Progress/Progress.js.map +1 -1
- package/dist/cssm/components/RichCell/RichCell.js +2 -2
- package/dist/cssm/components/RichCell/RichCell.js.map +1 -1
- package/dist/cssm/components/RootComponent/RootComponent.js +3 -1
- package/dist/cssm/components/RootComponent/RootComponent.js.map +1 -1
- package/dist/cssm/components/ScreenSpinner/ScreenSpinner.js +2 -2
- package/dist/cssm/components/ScreenSpinner/ScreenSpinner.js.map +1 -1
- package/dist/cssm/components/ScreenSpinner/context.js +1 -0
- package/dist/cssm/components/ScreenSpinner/context.js.map +1 -1
- package/dist/cssm/components/Separator/Separator.js +2 -5
- package/dist/cssm/components/Separator/Separator.js.map +1 -1
- package/dist/cssm/components/SimpleCell/SimpleCell.js +2 -2
- package/dist/cssm/components/SimpleCell/SimpleCell.js.map +1 -1
- package/dist/cssm/components/SimpleGrid/SimpleGrid.js +2 -5
- package/dist/cssm/components/SimpleGrid/SimpleGrid.js.map +1 -1
- package/dist/cssm/components/Skeleton/Skeleton.js +2 -5
- package/dist/cssm/components/Skeleton/Skeleton.js.map +1 -1
- package/dist/cssm/components/Snackbar/Snackbar.js +2 -2
- package/dist/cssm/components/Snackbar/Snackbar.js.map +1 -1
- package/dist/cssm/components/Snackbar/utils.js +2 -4
- package/dist/cssm/components/Snackbar/utils.js.map +1 -1
- package/dist/cssm/components/Spacing/Spacing.js +2 -5
- package/dist/cssm/components/Spacing/Spacing.js.map +1 -1
- package/dist/cssm/components/SplitCol/SplitCol.js +3 -4
- package/dist/cssm/components/SplitCol/SplitCol.js.map +1 -1
- package/dist/cssm/components/SplitLayout/SplitLayout.js +1 -5
- package/dist/cssm/components/SplitLayout/SplitLayout.js.map +1 -1
- package/dist/cssm/components/SubnavigationButton/SubnavigationButton.js +2 -2
- package/dist/cssm/components/SubnavigationButton/SubnavigationButton.js.map +1 -1
- package/dist/cssm/components/TabsItem/TabsItem.js +2 -2
- package/dist/cssm/components/TabsItem/TabsItem.js.map +1 -1
- package/dist/cssm/components/ToolButton/ToolButton.js +2 -2
- package/dist/cssm/components/ToolButton/ToolButton.js.map +1 -1
- package/dist/cssm/components/WriteBarIcon/WriteBarIcon.js +2 -2
- package/dist/cssm/components/WriteBarIcon/WriteBarIcon.js.map +1 -1
- package/dist/cssm/helpers/mergeStyle.js +16 -0
- package/dist/cssm/helpers/mergeStyle.js.map +1 -0
- package/dist/cssm/hooks/useBooleanState.js +2 -4
- package/dist/cssm/hooks/useBooleanState.js.map +1 -1
- package/dist/cssm/hooks/useSyncHTMLWithBaseVKUIClasses.js +13 -5
- package/dist/cssm/hooks/useSyncHTMLWithBaseVKUIClasses.js.map +1 -1
- package/dist/cssm/index.js +1 -1
- package/dist/cssm/index.js.map +1 -1
- package/dist/cssm/styles/common.css +5 -0
- package/dist/cssm/styles/themes.css +7 -9
- package/dist/cssm/types.js.map +1 -1
- package/dist/helpers/getMergedSameEventsByProps.d.ts.map +1 -1
- package/dist/helpers/mergeStyle.d.ts +11 -0
- package/dist/helpers/mergeStyle.d.ts.map +1 -0
- package/dist/helpers/mergeStyle.js +14 -0
- package/dist/helpers/mergeStyle.js.map +1 -0
- package/dist/hooks/useBooleanState.js +2 -4
- package/dist/hooks/useBooleanState.js.map +1 -1
- package/dist/hooks/useSyncHTMLWithBaseVKUIClasses.d.ts.map +1 -1
- package/dist/hooks/useSyncHTMLWithBaseVKUIClasses.js +15 -6
- package/dist/hooks/useSyncHTMLWithBaseVKUIClasses.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/dist/vkui.css +1 -1
- package/dist/vkui.css.map +1 -1
- package/package.json +8 -6
- package/src/components/ActionSheet/ActionSheet.tsx +3 -3
- package/src/components/ActionSheetItem/ActionSheetItem.tsx +1 -3
- package/src/components/AdaptivityProvider/AdaptivityContext.tsx +2 -0
- package/src/components/Alert/Alert.tsx +3 -3
- package/src/components/Alert/AlertAction.tsx +1 -1
- package/src/components/AppRoot/AppRoot.tsx +4 -49
- package/src/components/AppRoot/AppRootContext.ts +1 -6
- package/src/components/AppRoot/AppRootPortal.tsx +22 -40
- package/src/components/AppRoot/helpers.ts +0 -3
- package/src/components/AspectRatio/AspectRatio.tsx +2 -7
- package/src/components/Avatar/Avatar.tsx +6 -2
- package/src/components/Banner/Banner.tsx +0 -2
- package/src/components/Button/Button.tsx +1 -3
- package/src/components/CalendarDay/CalendarDay.tsx +1 -2
- package/src/components/CalendarHeader/CalendarHeader.tsx +2 -2
- package/src/components/ColorSchemeProvider/ColorSchemeProvider.tsx +4 -0
- package/src/components/ConfigProvider/ConfigProviderContext.tsx +2 -0
- package/src/components/ContentBadge/ContentBadgeContext.tsx +2 -0
- package/src/components/Counter/Counter.tsx +20 -21
- package/src/components/CustomSelectOption/CustomSelectOption.tsx +6 -6
- package/src/components/Flex/Flex.tsx +1 -2
- package/src/components/Flex/FlexItem/FlexItem.tsx +1 -2
- package/src/components/FloatingArrow/DefaultIcon.tsx +11 -8
- package/src/components/FloatingArrow/FloatingArrow.module.css +1 -1
- package/src/components/FloatingArrow/FloatingArrow.tsx +9 -8
- package/src/components/HorizontalCell/HorizontalCell.module.css +23 -6
- package/src/components/HorizontalCell/HorizontalCell.tsx +38 -6
- package/src/components/IconButton/IconButton.tsx +2 -8
- package/src/components/Image/Image.tsx +4 -2
- package/src/components/ImageBase/ImageBase.tsx +1 -2
- package/src/components/Link/Link.tsx +1 -3
- package/src/components/List/List.tsx +3 -11
- package/src/components/MiniInfoCell/MiniInfoCell.tsx +1 -3
- package/src/components/ModalCardBase/ModalCardBase.tsx +1 -3
- package/src/components/ModalDismissButton/ModalDismissButton.tsx +1 -3
- package/src/components/ModalOverlay/ModalOverlay.module.css +1 -0
- package/src/components/ModalRoot/ModalRoot.tsx +8 -4
- package/src/components/ModalRoot/ModalRootContext.tsx +2 -0
- package/src/components/ModalRoot/types.ts +1 -0
- package/src/components/NavIdContext/NavIdContext.tsx +2 -0
- package/src/components/OnboardingTooltip/OnboardingTooltip.tsx +2 -5
- package/src/components/PanelHeaderButton/PanelHeaderButton.tsx +1 -3
- package/src/components/Popper/Popper.tsx +7 -11
- package/src/components/Progress/Progress.tsx +1 -2
- package/src/components/RichCell/RichCell.tsx +1 -3
- package/src/components/RootComponent/RootComponent.tsx +5 -0
- package/src/components/ScreenSpinner/ScreenSpinner.tsx +3 -3
- package/src/components/ScreenSpinner/context.ts +2 -0
- package/src/components/Separator/Separator.tsx +1 -9
- package/src/components/SimpleCell/SimpleCell.tsx +1 -3
- package/src/components/SimpleGrid/SimpleGrid.tsx +1 -2
- package/src/components/Skeleton/Skeleton.tsx +1 -2
- package/src/components/Snackbar/Snackbar.tsx +1 -2
- package/src/components/Snackbar/utils.ts +3 -4
- package/src/components/Spacing/Spacing.tsx +2 -9
- package/src/components/SplitCol/SplitCol.tsx +1 -3
- package/src/components/SplitLayout/SplitLayout.tsx +1 -7
- package/src/components/SubnavigationButton/SubnavigationButton.tsx +1 -3
- package/src/components/TabsItem/TabsItem.tsx +1 -3
- package/src/components/ToolButton/ToolButton.tsx +1 -3
- package/src/components/WriteBarIcon/WriteBarIcon.tsx +1 -3
- package/src/helpers/mergeStyle.ts +15 -0
- package/src/hooks/useBooleanState.ts +2 -2
- package/src/hooks/useSyncHTMLWithBaseVKUIClasses.ts +10 -5
- package/src/index.ts +3 -3
- package/src/styles/common.css +7 -0
- package/src/types.ts +4 -1
- package/dist/components/AppRoot/ModalPopoutPortal.d.ts +0 -11
- package/dist/components/AppRoot/ModalPopoutPortal.d.ts.map +0 -1
- package/dist/components/AppRoot/ModalPopoutPortal.js +0 -28
- package/dist/components/AppRoot/ModalPopoutPortal.js.map +0 -1
- package/dist/cssm/components/AppRoot/ModalPopoutPortal.js +0 -27
- package/dist/cssm/components/AppRoot/ModalPopoutPortal.js.map +0 -1
- package/src/components/AppRoot/ModalPopoutPortal.tsx +0 -27
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
|
|
3
|
+
export const DEFAULT_ARROW_WIDTH = 20;
|
|
4
|
+
export const DEFAULT_ARROW_HEIGHT = 8;
|
|
5
|
+
export const DEFAULT_ARROW_PADDING = 10;
|
|
6
|
+
|
|
7
|
+
const PLATFORM_HEIGHT = 1;
|
|
8
|
+
const ARROW_HEIGHT_WITH_WHITE_SPACE = DEFAULT_ARROW_HEIGHT + PLATFORM_HEIGHT;
|
|
9
|
+
|
|
3
10
|
/**
|
|
11
|
+
* Стрелка для всплывающих окон.
|
|
12
|
+
*
|
|
4
13
|
* Примечание 1.
|
|
5
14
|
*
|
|
6
15
|
* В компоненте, SVG элемент `<path />` представляет собой стрелку с платформой в виде прямоугольника в 1px. Платформа
|
|
@@ -12,15 +21,9 @@ import * as React from 'react';
|
|
|
12
21
|
* 2. Сместить положение SVG контейнера на высоту платформы – сделано в CSS через `translateY(1px)`.
|
|
13
22
|
*
|
|
14
23
|
* https://github.com/VKCOM/VKUI/issues/2123
|
|
24
|
+
*
|
|
25
|
+
* @since 7.0.0
|
|
15
26
|
*/
|
|
16
|
-
|
|
17
|
-
export const DEFAULT_ARROW_WIDTH = 20;
|
|
18
|
-
export const DEFAULT_ARROW_HEIGHT = 8;
|
|
19
|
-
export const DEFAULT_ARROW_PADDING = 10;
|
|
20
|
-
|
|
21
|
-
const PLATFORM_HEIGHT = 1;
|
|
22
|
-
const ARROW_HEIGHT_WITH_WHITE_SPACE = DEFAULT_ARROW_HEIGHT + PLATFORM_HEIGHT;
|
|
23
|
-
|
|
24
27
|
export const DefaultIcon = (props: React.SVGAttributes<SVGSVGElement>): React.ReactNode => {
|
|
25
28
|
return (
|
|
26
29
|
<svg
|
|
@@ -2,6 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { classNames } from '@vkontakte/vkjs';
|
|
3
3
|
import type { Placement } from '../../lib/floating';
|
|
4
4
|
import type { HasDataAttribute, HTMLAttributesWithRootRef } from '../../types';
|
|
5
|
+
import { RootComponent } from '../RootComponent/RootComponent';
|
|
5
6
|
import { DefaultIcon } from './DefaultIcon';
|
|
6
7
|
import styles from './FloatingArrow.module.css';
|
|
7
8
|
|
|
@@ -10,7 +11,7 @@ export type Coords = {
|
|
|
10
11
|
y?: number;
|
|
11
12
|
};
|
|
12
13
|
|
|
13
|
-
const placementClassNames = {
|
|
14
|
+
export const placementClassNames = {
|
|
14
15
|
right: styles.placementRight,
|
|
15
16
|
bottom: styles.placementBottom,
|
|
16
17
|
left: styles.placementLeft,
|
|
@@ -35,7 +36,9 @@ export interface FloatingArrowProps
|
|
|
35
36
|
}
|
|
36
37
|
|
|
37
38
|
/**
|
|
38
|
-
*
|
|
39
|
+
* Иконка-стрелка для всплывающих окон.
|
|
40
|
+
*
|
|
41
|
+
* @since 7.0.0
|
|
39
42
|
*/
|
|
40
43
|
export const FloatingArrow = ({
|
|
41
44
|
offset,
|
|
@@ -44,7 +47,6 @@ export const FloatingArrow = ({
|
|
|
44
47
|
iconStyle,
|
|
45
48
|
iconClassName,
|
|
46
49
|
placement = 'bottom',
|
|
47
|
-
getRootRef,
|
|
48
50
|
Icon = DefaultIcon,
|
|
49
51
|
...restProps
|
|
50
52
|
}: FloatingArrowProps): React.ReactNode => {
|
|
@@ -56,14 +58,13 @@ export const FloatingArrow = ({
|
|
|
56
58
|
);
|
|
57
59
|
|
|
58
60
|
return (
|
|
59
|
-
<
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
className={classNames(styles.host, arrowPlacement && placementClassNames[arrowPlacement])}
|
|
61
|
+
<RootComponent
|
|
62
|
+
baseStyle={arrowStyles}
|
|
63
|
+
baseClassName={classNames(styles.host, arrowPlacement && placementClassNames[arrowPlacement])}
|
|
63
64
|
{...restProps}
|
|
64
65
|
>
|
|
65
66
|
<Icon className={classNames(styles.in, iconClassName)} style={iconStyle} />
|
|
66
|
-
</
|
|
67
|
+
</RootComponent>
|
|
67
68
|
);
|
|
68
69
|
};
|
|
69
70
|
|
|
@@ -34,13 +34,13 @@
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
.sized {
|
|
37
|
-
--vkui_internal--side_cell_width: calc(
|
|
38
|
-
var(--vkui_internal--cell_width) + var(--vkui_internal--side_cell_gap)
|
|
39
|
-
);
|
|
40
|
-
|
|
41
37
|
max-inline-size: var(--vkui_internal--cell_width);
|
|
42
38
|
}
|
|
43
39
|
|
|
40
|
+
.customSize .body {
|
|
41
|
+
inline-size: var(--vkui_internal--cell_width);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
44
|
.sizeS {
|
|
45
45
|
--vkui_internal--side_cell_gap: calc(
|
|
46
46
|
var(--vkui--size_base_padding_horizontal--regular) - var(--vkui--spacing_size_m)
|
|
@@ -48,6 +48,10 @@
|
|
|
48
48
|
--vkui_internal--cell_width: 72px;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
+
.noPadding {
|
|
52
|
+
--vkui_internal--side_cell_gap: 0px;
|
|
53
|
+
}
|
|
54
|
+
|
|
51
55
|
.image {
|
|
52
56
|
padding-block: 4px;
|
|
53
57
|
padding-inline: var(--vkui--spacing_size_s);
|
|
@@ -59,6 +63,14 @@
|
|
|
59
63
|
text-align: start;
|
|
60
64
|
}
|
|
61
65
|
|
|
66
|
+
.textAlignCenter {
|
|
67
|
+
text-align: center;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.textAlignEnd {
|
|
71
|
+
text-align: end;
|
|
72
|
+
}
|
|
73
|
+
|
|
62
74
|
.sizeS .image {
|
|
63
75
|
padding-block: 4px;
|
|
64
76
|
padding-inline: var(--vkui--spacing_size_m);
|
|
@@ -67,7 +79,6 @@
|
|
|
67
79
|
.sizeS .content {
|
|
68
80
|
padding-block: 2px 8px;
|
|
69
81
|
padding-inline: 4px;
|
|
70
|
-
text-align: center;
|
|
71
82
|
}
|
|
72
83
|
|
|
73
84
|
.sizeM {
|
|
@@ -94,7 +105,13 @@
|
|
|
94
105
|
|
|
95
106
|
.sized:first-child,
|
|
96
107
|
.sized:last-child {
|
|
97
|
-
max-inline-size: var(--vkui_internal--
|
|
108
|
+
max-inline-size: calc(var(--vkui_internal--cell_width) + var(--vkui_internal--side_cell_gap));
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.sized:first-child:last-child {
|
|
112
|
+
max-inline-size: calc(
|
|
113
|
+
var(--vkui_internal--cell_width) + (2 * (var(--vkui_internal--side_cell_gap)))
|
|
114
|
+
);
|
|
98
115
|
}
|
|
99
116
|
|
|
100
117
|
.sized:first-child .body,
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { classNames, hasReactNode } from '@vkontakte/vkjs';
|
|
3
|
-
import
|
|
3
|
+
import { mergeStyle } from '../../helpers/mergeStyle';
|
|
4
|
+
import type {
|
|
5
|
+
CSSCustomProperties,
|
|
6
|
+
HasRef,
|
|
7
|
+
HasRootRef,
|
|
8
|
+
HTMLAttributesWithRootRef,
|
|
9
|
+
LiteralUnion,
|
|
10
|
+
} from '../../types';
|
|
4
11
|
import { Avatar } from '../Avatar/Avatar';
|
|
5
12
|
import { Tappable, type TappableProps } from '../Tappable/Tappable';
|
|
6
13
|
import { Caption } from '../Typography/Caption/Caption';
|
|
@@ -18,6 +25,11 @@ const stylesSize = {
|
|
|
18
25
|
auto: styles.sizeAuto,
|
|
19
26
|
};
|
|
20
27
|
|
|
28
|
+
const textAlignClassNames = {
|
|
29
|
+
center: styles.textAlignCenter,
|
|
30
|
+
end: styles.textAlignEnd,
|
|
31
|
+
};
|
|
32
|
+
|
|
21
33
|
type HorizontalCellSizes = 's' | 'm' | 'l' | 'xl' | 'auto';
|
|
22
34
|
|
|
23
35
|
interface CellTypographyProps extends HTMLAttributesWithRootRef<HTMLDivElement> {
|
|
@@ -56,6 +68,16 @@ export interface HorizontalCellProps
|
|
|
56
68
|
* Дополнительная строка текста под `children` и `subtitle`.
|
|
57
69
|
*/
|
|
58
70
|
extraSubtitle?: React.ReactNode;
|
|
71
|
+
/**
|
|
72
|
+
* Задает выравнивание типографики. По умолчанию `center` для `size=s`, иначе `start`
|
|
73
|
+
*/
|
|
74
|
+
textAlign?: 'start' | 'center' | 'end';
|
|
75
|
+
/**
|
|
76
|
+
* Отключает формирование отступов у крайних элементов
|
|
77
|
+
*
|
|
78
|
+
* Актуально для использования в многострочных списках
|
|
79
|
+
*/
|
|
80
|
+
noPadding?: boolean;
|
|
59
81
|
}
|
|
60
82
|
|
|
61
83
|
/**
|
|
@@ -71,28 +93,38 @@ export const HorizontalCell = ({
|
|
|
71
93
|
getRootRef,
|
|
72
94
|
getRef,
|
|
73
95
|
extraSubtitle,
|
|
96
|
+
textAlign = size === 's' ? 'center' : 'start',
|
|
97
|
+
noPadding = false,
|
|
74
98
|
...restProps
|
|
75
99
|
}: HorizontalCellProps): React.ReactNode => {
|
|
76
100
|
const hasTypography =
|
|
77
101
|
hasReactNode(title) || hasReactNode(subtitle) || hasReactNode(extraSubtitle);
|
|
102
|
+
|
|
103
|
+
const customProperties: CSSCustomProperties | undefined =
|
|
104
|
+
typeof size === 'number' ? { [CUSTOM_CSS_TOKEN_FOR_CELL_WIDTH]: `${size}px` } : undefined;
|
|
105
|
+
|
|
78
106
|
return (
|
|
79
107
|
<div
|
|
80
108
|
ref={getRootRef}
|
|
81
|
-
style={
|
|
82
|
-
...(typeof size === 'number' && { [CUSTOM_CSS_TOKEN_FOR_CELL_WIDTH]: `${size}px` }),
|
|
83
|
-
...style,
|
|
84
|
-
}}
|
|
109
|
+
style={mergeStyle(customProperties, style)}
|
|
85
110
|
className={classNames(
|
|
86
111
|
styles.host,
|
|
87
112
|
typeof size === 'string' && stylesSize[size],
|
|
88
113
|
size !== 'auto' && styles.sized,
|
|
114
|
+
typeof size === 'number' && styles.customSize,
|
|
115
|
+
noPadding && styles.noPadding,
|
|
89
116
|
className,
|
|
90
117
|
)}
|
|
91
118
|
>
|
|
92
119
|
<Tappable className={styles.body} getRootRef={getRef} {...restProps}>
|
|
93
120
|
{hasReactNode(children) && <div className={styles.image}>{children}</div>}
|
|
94
121
|
{hasTypography && (
|
|
95
|
-
<div
|
|
122
|
+
<div
|
|
123
|
+
className={classNames(
|
|
124
|
+
styles.content,
|
|
125
|
+
textAlign !== 'start' && textAlignClassNames[textAlign],
|
|
126
|
+
)}
|
|
127
|
+
>
|
|
96
128
|
{hasReactNode(title) && <CellTypography size={size}>{title}</CellTypography>}
|
|
97
129
|
{hasReactNode(subtitle) && <Footnote className={styles.subtitle}>{subtitle}</Footnote>}
|
|
98
130
|
{hasReactNode(extraSubtitle) && (
|
|
@@ -26,12 +26,7 @@ const warn = warnOnce('IconButton');
|
|
|
26
26
|
/**
|
|
27
27
|
* @see https://vkcom.github.io/VKUI/#/IconButton
|
|
28
28
|
*/
|
|
29
|
-
export const IconButton = ({
|
|
30
|
-
label,
|
|
31
|
-
children,
|
|
32
|
-
className,
|
|
33
|
-
...restProps
|
|
34
|
-
}: IconButtonProps): React.ReactNode => {
|
|
29
|
+
export const IconButton = ({ label, children, ...restProps }: IconButtonProps): React.ReactNode => {
|
|
35
30
|
const platform = usePlatform();
|
|
36
31
|
const { sizeY = 'none' } = useAdaptivity();
|
|
37
32
|
|
|
@@ -53,11 +48,10 @@ export const IconButton = ({
|
|
|
53
48
|
activeMode="background"
|
|
54
49
|
Component={restProps.href ? 'a' : 'button'}
|
|
55
50
|
{...restProps}
|
|
56
|
-
|
|
51
|
+
baseClassName={classNames(
|
|
57
52
|
styles.host,
|
|
58
53
|
sizeY !== 'regular' && sizeYClassNames[sizeY],
|
|
59
54
|
platform === 'ios' && styles.ios,
|
|
60
|
-
className,
|
|
61
55
|
)}
|
|
62
56
|
>
|
|
63
57
|
{label && <VisuallyHidden>{label}</VisuallyHidden>}
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { classNames } from '@vkontakte/vkjs';
|
|
5
|
+
import { mergeStyle } from '../../helpers/mergeStyle';
|
|
6
|
+
import { type CSSCustomProperties } from '../../types';
|
|
5
7
|
import { ImageBase, type ImageBaseOverlayProps, type ImageBaseProps } from '../ImageBase/ImageBase';
|
|
6
8
|
import { ImageBadge, type ImageBadgeProps } from './ImageBadge/ImageBadge';
|
|
7
9
|
import styles from './Image.module.css';
|
|
@@ -118,7 +120,7 @@ export const Image: React.FC<ImageProps> & {
|
|
|
118
120
|
objectFit = 'cover',
|
|
119
121
|
...restProps
|
|
120
122
|
}: ImageProps) => {
|
|
121
|
-
const borderStyles = React.useMemo(
|
|
123
|
+
const borderStyles: CSSCustomProperties<string | undefined> = React.useMemo(
|
|
122
124
|
() => ({
|
|
123
125
|
'--vkui_internal--Image_border_radius': getBorderRadiusBySizeInPx(size, borderRadius),
|
|
124
126
|
'--vkui_internal--Image_border_start_start_radius': getBorderRadiusBySizeInPx(
|
|
@@ -153,7 +155,7 @@ export const Image: React.FC<ImageProps> & {
|
|
|
153
155
|
{...restProps}
|
|
154
156
|
objectFit={objectFit}
|
|
155
157
|
size={size}
|
|
156
|
-
style={
|
|
158
|
+
style={mergeStyle(borderStyles, style)}
|
|
157
159
|
className={classNames(
|
|
158
160
|
className,
|
|
159
161
|
styles.host,
|
|
@@ -142,7 +142,6 @@ export const ImageBase: React.FC<ImageBaseProps> & {
|
|
|
142
142
|
height: heightImg,
|
|
143
143
|
widthSize,
|
|
144
144
|
heightSize,
|
|
145
|
-
style,
|
|
146
145
|
noBorder = false,
|
|
147
146
|
fallbackIcon: fallbackIconProp,
|
|
148
147
|
children,
|
|
@@ -209,7 +208,7 @@ export const ImageBase: React.FC<ImageBaseProps> & {
|
|
|
209
208
|
return (
|
|
210
209
|
<ImageBaseContext.Provider value={{ size }}>
|
|
211
210
|
<Clickable
|
|
212
|
-
|
|
211
|
+
baseStyle={{ width, height }}
|
|
213
212
|
baseClassName={classNames(
|
|
214
213
|
styles.host,
|
|
215
214
|
loaded && styles.loaded,
|
|
@@ -31,7 +31,6 @@ export const Link = ({
|
|
|
31
31
|
noUnderline,
|
|
32
32
|
hasVisited,
|
|
33
33
|
children,
|
|
34
|
-
className,
|
|
35
34
|
...restProps
|
|
36
35
|
}: LinkProps): React.ReactNode => {
|
|
37
36
|
const before = beforeProp ? <span className={styles.before}>{beforeProp}</span> : null;
|
|
@@ -41,11 +40,10 @@ export const Link = ({
|
|
|
41
40
|
<Tappable
|
|
42
41
|
Component={restProps.href ? 'a' : 'button'}
|
|
43
42
|
{...restProps}
|
|
44
|
-
|
|
43
|
+
baseClassName={classNames(
|
|
45
44
|
styles.host,
|
|
46
45
|
hasVisited && styles.hasVisited,
|
|
47
46
|
noUnderline ? undefined : styles.withUnderline,
|
|
48
|
-
className,
|
|
49
47
|
)}
|
|
50
48
|
hasHover={false}
|
|
51
49
|
activeMode="opacity"
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { classNames } from '@vkontakte/vkjs';
|
|
3
2
|
import { DATA_DRAGGABLE_PLACEHOLDER_REACT_PROP } from '../../hooks/useDraggableWithDomApi';
|
|
4
3
|
import type { HTMLAttributesWithRootRef } from '../../types';
|
|
5
4
|
import { RootComponent } from '../RootComponent/RootComponent';
|
|
@@ -15,20 +14,13 @@ export type ListProps = HTMLAttributesWithRootRef<HTMLDivElement> & {
|
|
|
15
14
|
/**
|
|
16
15
|
* @see https://vkcom.github.io/VKUI/#/List
|
|
17
16
|
*/
|
|
18
|
-
export const List = ({
|
|
19
|
-
children,
|
|
20
|
-
gap = 0,
|
|
21
|
-
className,
|
|
22
|
-
style,
|
|
23
|
-
...restProps
|
|
24
|
-
}: ListProps): React.ReactNode => {
|
|
17
|
+
export const List = ({ children, gap = 0, ...restProps }: ListProps): React.ReactNode => {
|
|
25
18
|
return (
|
|
26
19
|
<RootComponent
|
|
27
20
|
role="list"
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
baseClassName={styles.host}
|
|
22
|
+
baseStyle={{
|
|
30
23
|
gridGap: gap,
|
|
31
|
-
...style,
|
|
32
24
|
}}
|
|
33
25
|
{...restProps}
|
|
34
26
|
>
|
|
@@ -67,14 +67,12 @@ export const MiniInfoCell = ({
|
|
|
67
67
|
mode = 'base',
|
|
68
68
|
textWrap = 'nowrap',
|
|
69
69
|
chevron = false,
|
|
70
|
-
className,
|
|
71
70
|
...restProps
|
|
72
71
|
}: MiniInfoCellProps): React.ReactNode => {
|
|
73
72
|
const cellClasses = classNames(
|
|
74
73
|
styles.host,
|
|
75
74
|
stylesTextWrap[textWrap],
|
|
76
75
|
mode !== 'base' && stylesMode[mode],
|
|
77
|
-
className,
|
|
78
76
|
);
|
|
79
77
|
|
|
80
78
|
const cellContent = (
|
|
@@ -91,7 +89,7 @@ export const MiniInfoCell = ({
|
|
|
91
89
|
);
|
|
92
90
|
|
|
93
91
|
return restProps.onClick ? (
|
|
94
|
-
<Tappable Component="div" role="button" {...restProps}
|
|
92
|
+
<Tappable Component="div" role="button" {...restProps} baseClassName={cellClasses}>
|
|
95
93
|
{cellContent}
|
|
96
94
|
</Tappable>
|
|
97
95
|
) : (
|
|
@@ -96,7 +96,6 @@ export const ModalCardBase = ({
|
|
|
96
96
|
actions,
|
|
97
97
|
onClose,
|
|
98
98
|
dismissLabel = 'Скрыть',
|
|
99
|
-
style,
|
|
100
99
|
size: sizeProp,
|
|
101
100
|
modalDismissButtonTestId,
|
|
102
101
|
dismissButtonMode = 'outside',
|
|
@@ -123,9 +122,8 @@ export const ModalCardBase = ({
|
|
|
123
122
|
isDesktop && styles.desktop,
|
|
124
123
|
withSafeZone && styles.withSafeZone,
|
|
125
124
|
)}
|
|
126
|
-
|
|
125
|
+
baseStyle={{
|
|
127
126
|
maxWidth: size,
|
|
128
|
-
...style,
|
|
129
127
|
}}
|
|
130
128
|
>
|
|
131
129
|
<div className={styles.container}>
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { Icon20Cancel } from '@vkontakte/icons';
|
|
3
|
-
import { classNames } from '@vkontakte/vkjs';
|
|
4
3
|
import { Tappable, type TappableProps } from '../Tappable/Tappable';
|
|
5
4
|
import { VisuallyHidden } from '../VisuallyHidden/VisuallyHidden';
|
|
6
5
|
import styles from './ModalDismissButton.module.css';
|
|
@@ -12,12 +11,11 @@ export type ModalDismissButtonProps = Omit<TappableProps, 'mode' | 'onClose'>;
|
|
|
12
11
|
*/
|
|
13
12
|
export const ModalDismissButton = ({
|
|
14
13
|
children = 'Закрыть',
|
|
15
|
-
className,
|
|
16
14
|
...restProps
|
|
17
15
|
}: ModalDismissButtonProps): React.ReactNode => {
|
|
18
16
|
return (
|
|
19
17
|
<Tappable
|
|
20
|
-
|
|
18
|
+
baseClassName={styles.host}
|
|
21
19
|
{...restProps}
|
|
22
20
|
activeMode={styles.active}
|
|
23
21
|
hoverMode={styles.hover}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { noop } from '@vkontakte/vkjs';
|
|
5
5
|
import { warnOnce } from '../../lib/warnOnce';
|
|
6
|
-
import {
|
|
6
|
+
import { AppRootPortal } from '../AppRoot/AppRootPortal';
|
|
7
7
|
import { ModalOverlay } from '../ModalOverlay/ModalOverlay';
|
|
8
8
|
import { ModalRootContext, ModalRootOverlayContext } from './ModalRootContext';
|
|
9
9
|
import type { ModalRootProps } from './types';
|
|
@@ -61,13 +61,17 @@ export const ModalRoot = ({
|
|
|
61
61
|
);
|
|
62
62
|
const modalOverlayRef = React.useRef<HTMLDivElement>(null);
|
|
63
63
|
return (
|
|
64
|
-
<
|
|
64
|
+
<AppRootPortal usePortal={usePortal}>
|
|
65
65
|
<ModalRootContext.Provider value={contextValue}>
|
|
66
66
|
<ModalRootOverlayContext.Provider value={modalOverlayRef}>
|
|
67
|
-
<ModalOverlay
|
|
67
|
+
<ModalOverlay
|
|
68
|
+
position="fixed"
|
|
69
|
+
visible={typeof activeModal === 'string'}
|
|
70
|
+
getRootRef={modalOverlayRef}
|
|
71
|
+
/>
|
|
68
72
|
{children}
|
|
69
73
|
</ModalRootOverlayContext.Provider>
|
|
70
74
|
</ModalRootContext.Provider>
|
|
71
|
-
</
|
|
75
|
+
</AppRootPortal>
|
|
72
76
|
);
|
|
73
77
|
};
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { hasReactNode } from '@vkontakte/vkjs';
|
|
5
|
+
import { mergeStyle } from '../../helpers/mergeStyle';
|
|
5
6
|
import { useExternRef } from '../../hooks/useExternRef';
|
|
6
7
|
import { usePatchChildren } from '../../hooks/usePatchChildren';
|
|
7
8
|
import { createPortal } from '../../lib/createPortal';
|
|
@@ -137,17 +138,13 @@ export const OnboardingTooltip = ({
|
|
|
137
138
|
floatingDataY,
|
|
138
139
|
);
|
|
139
140
|
|
|
140
|
-
if (styleProp) {
|
|
141
|
-
Object.assign(floatingStyle, styleProp);
|
|
142
|
-
}
|
|
143
|
-
|
|
144
141
|
tooltip = createPortal(
|
|
145
142
|
<>
|
|
146
143
|
<TooltipBase
|
|
147
144
|
{...restProps}
|
|
148
145
|
id={tooltipId}
|
|
149
146
|
getRootRef={tooltipRef}
|
|
150
|
-
style={floatingStyle}
|
|
147
|
+
style={mergeStyle(floatingStyle, styleProp)}
|
|
151
148
|
maxWidth={maxWidth}
|
|
152
149
|
arrowProps={
|
|
153
150
|
disableArrow
|
|
@@ -49,7 +49,6 @@ export const PanelHeaderButton = ({
|
|
|
49
49
|
children,
|
|
50
50
|
primary = false,
|
|
51
51
|
label,
|
|
52
|
-
className,
|
|
53
52
|
...restProps
|
|
54
53
|
}: PanelHeaderButtonProps): React.ReactNode => {
|
|
55
54
|
const isPrimitive = isPrimitiveReactNode(children);
|
|
@@ -95,14 +94,13 @@ export const PanelHeaderButton = ({
|
|
|
95
94
|
hoverMode={hoverMode}
|
|
96
95
|
activeEffectDelay={200}
|
|
97
96
|
activeMode={activeMode}
|
|
98
|
-
|
|
97
|
+
baseClassName={classNames(
|
|
99
98
|
styles.host,
|
|
100
99
|
platformClassNames.hasOwnProperty(platform)
|
|
101
100
|
? platformClassNames[platform]
|
|
102
101
|
: platformClassNames.android,
|
|
103
102
|
onlyPrimitive && styles.primitive,
|
|
104
103
|
!isPrimitive && !isPrimitiveLabel && styles.notPrimitive,
|
|
105
|
-
className,
|
|
106
104
|
)}
|
|
107
105
|
>
|
|
108
106
|
{isPrimitive ? <ButtonTypography primary={primary}>{children}</ButtonTypography> : children}
|
|
@@ -112,7 +112,6 @@ export const Popper = ({
|
|
|
112
112
|
getRootRef,
|
|
113
113
|
children,
|
|
114
114
|
usePortal = true,
|
|
115
|
-
style: styleProp,
|
|
116
115
|
onPlacementChange,
|
|
117
116
|
...restProps
|
|
118
117
|
}: PopperProps): React.ReactNode => {
|
|
@@ -165,16 +164,13 @@ export const Popper = ({
|
|
|
165
164
|
{...restProps}
|
|
166
165
|
baseClassName={styles.host}
|
|
167
166
|
getRootRef={handleRootRef}
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
),
|
|
176
|
-
...styleProp,
|
|
177
|
-
}}
|
|
167
|
+
baseStyle={convertFloatingDataToReactCSSProperties(
|
|
168
|
+
floatingPositionStrategy,
|
|
169
|
+
floatingDataX,
|
|
170
|
+
floatingDataY,
|
|
171
|
+
sameWidth ? null : undefined,
|
|
172
|
+
middlewareData,
|
|
173
|
+
)}
|
|
178
174
|
>
|
|
179
175
|
{arrow && (
|
|
180
176
|
<FloatingArrow
|
|
@@ -42,7 +42,6 @@ export const Progress = ({
|
|
|
42
42
|
value = 0,
|
|
43
43
|
appearance = 'accent',
|
|
44
44
|
height,
|
|
45
|
-
style,
|
|
46
45
|
...restProps
|
|
47
46
|
}: ProgressProps): React.ReactNode => {
|
|
48
47
|
const progress = clamp(value, PROGRESS_MIN_VALUE, PROGRESS_MAX_VALUE);
|
|
@@ -53,12 +52,12 @@ export const Progress = ({
|
|
|
53
52
|
<RootComponent
|
|
54
53
|
aria-valuenow={value}
|
|
55
54
|
title={title}
|
|
56
|
-
style={{ ...styleHeight, ...style }}
|
|
57
55
|
{...restProps}
|
|
58
56
|
role="progressbar"
|
|
59
57
|
aria-valuemin={PROGRESS_MIN_VALUE}
|
|
60
58
|
aria-valuemax={PROGRESS_MAX_VALUE}
|
|
61
59
|
baseClassName={classNames(styles.host, stylesAppearance[appearance])}
|
|
60
|
+
baseStyle={styleHeight}
|
|
62
61
|
>
|
|
63
62
|
<div className={styles.in} style={{ width: `${progress}%` }} />
|
|
64
63
|
</RootComponent>
|
|
@@ -89,7 +89,6 @@ export const RichCell: React.FC<RichCellProps> & {
|
|
|
89
89
|
bottom,
|
|
90
90
|
actions,
|
|
91
91
|
multiline,
|
|
92
|
-
className,
|
|
93
92
|
afterAlign = 'start',
|
|
94
93
|
...restProps
|
|
95
94
|
}: RichCellProps) => {
|
|
@@ -110,11 +109,10 @@ export const RichCell: React.FC<RichCellProps> & {
|
|
|
110
109
|
return (
|
|
111
110
|
<Tappable
|
|
112
111
|
{...restProps}
|
|
113
|
-
|
|
112
|
+
baseClassName={classNames(
|
|
114
113
|
styles.host,
|
|
115
114
|
!multiline && styles.textEllipsis,
|
|
116
115
|
sizeY !== 'regular' && sizeYClassNames[sizeY],
|
|
117
|
-
className,
|
|
118
116
|
)}
|
|
119
117
|
>
|
|
120
118
|
{before && <div className={styles.before}>{before}</div>}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { classNames } from '@vkontakte/vkjs';
|
|
3
|
+
import { mergeStyle } from '../../helpers/mergeStyle';
|
|
3
4
|
import type { HasComponent, HasRootRef } from '../../types';
|
|
4
5
|
import styles from './RootComponent.module.css';
|
|
5
6
|
|
|
@@ -8,6 +9,7 @@ export interface RootComponentProps<T>
|
|
|
8
9
|
HasRootRef<T>,
|
|
9
10
|
HasComponent {
|
|
10
11
|
baseClassName?: string | false;
|
|
12
|
+
baseStyle?: React.CSSProperties;
|
|
11
13
|
}
|
|
12
14
|
|
|
13
15
|
/**
|
|
@@ -17,6 +19,8 @@ export const RootComponent = <T,>({
|
|
|
17
19
|
Component = 'div',
|
|
18
20
|
baseClassName,
|
|
19
21
|
className,
|
|
22
|
+
baseStyle,
|
|
23
|
+
style,
|
|
20
24
|
getRootRef,
|
|
21
25
|
...restProps
|
|
22
26
|
}: RootComponentProps<T>): React.ReactNode => (
|
|
@@ -28,6 +32,7 @@ export const RootComponent = <T,>({
|
|
|
28
32
|
styles.host,
|
|
29
33
|
restProps.hidden === true && styles.hidden,
|
|
30
34
|
)}
|
|
35
|
+
style={mergeStyle(baseStyle, style)}
|
|
31
36
|
{...restProps}
|
|
32
37
|
/>
|
|
33
38
|
);
|