@telus-uds/components-web 4.19.1 → 5.0.0-alpha.0
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/.eslintrc.cjs +12 -0
- package/CHANGELOG.md +16 -1
- package/lib/cjs/Badge/Badge.js +26 -27
- package/lib/cjs/BlockQuote/BlockQuote.js +24 -25
- package/lib/cjs/Breadcrumbs/{Item/Item.js → BreadcrumbItem.js} +36 -37
- package/lib/cjs/Breadcrumbs/Breadcrumbs.js +8 -10
- package/lib/cjs/Callout/Callout.js +24 -25
- package/lib/cjs/Card/Card.js +79 -89
- package/lib/cjs/Card/CardContent.js +53 -29
- package/lib/cjs/Card/CardFooter.js +28 -18
- package/lib/cjs/Countdown/Countdown.js +7 -8
- package/lib/cjs/Countdown/Segment.js +10 -11
- package/lib/cjs/Countdown/dictionary.js +2 -2
- package/lib/cjs/Countdown/types.js +2 -6
- package/lib/cjs/Countdown/useCountdown.js +2 -2
- package/lib/cjs/DatePicker/CalendarContainer.js +66 -67
- package/lib/cjs/DatePicker/DatePicker.js +27 -28
- package/lib/cjs/DatePicker/dictionary.js +3 -4
- package/lib/cjs/DatePicker/reactDatesCss.js +2 -3
- package/lib/cjs/Disclaimer/Disclaimer.js +28 -13
- package/lib/cjs/Footnote/Footnote.js +108 -109
- package/lib/cjs/Footnote/FootnoteLink.js +28 -19
- package/lib/cjs/Footnote/dictionary.js +2 -2
- package/lib/cjs/IconButton/IconButton.js +3 -4
- package/lib/cjs/Image/Image.js +9 -3
- package/lib/cjs/Image/server.js +4 -6
- package/lib/cjs/List/List.js +7 -3
- package/lib/cjs/List/ListItem.js +3 -4
- package/lib/cjs/NavigationBar/NavigationBar.js +8 -9
- package/lib/cjs/NavigationBar/NavigationItem.js +10 -11
- package/lib/cjs/NavigationBar/NavigationSubMenu.js +10 -11
- package/lib/cjs/NavigationBar/collapseItems.js +2 -2
- package/lib/cjs/NavigationBar/resolveItemSelection.js +2 -2
- package/lib/cjs/OptimizeImage/OptimizeImage.js +6 -8
- package/lib/cjs/OptimizeImage/utils/getFallbackUrl.js +3 -4
- package/lib/cjs/OptimizeImage/utils/getImageUrls.js +9 -10
- package/lib/cjs/OptimizeImage/utils/getOptimizedUrl.js +3 -4
- package/lib/cjs/OptimizeImage/utils/hasWebpSupport.js +1 -1
- package/lib/cjs/OptimizeImage/utils/index.js +8 -9
- package/lib/cjs/OptimizeImage/utils/isSvgUrl.js +1 -1
- package/lib/cjs/OrderedList/OrderedList.js +6 -9
- package/lib/cjs/OrderedList/OrderedListBase.js +4 -7
- package/lib/cjs/OrderedList/{Item.js → OrderedListItem.js} +46 -39
- package/lib/cjs/OrderedList/{ItemBase.js → OrderedListItemBase.js} +7 -7
- package/lib/cjs/OrderedList/constants.js +0 -1
- package/lib/cjs/Paragraph/Paragraph.js +10 -11
- package/lib/cjs/PreviewCard/PreviewCard.js +18 -27
- package/lib/cjs/PreviewCard/{AuthorDate.js → PreviewCardAuthorDate.js} +6 -6
- package/lib/cjs/PriceLockup/PriceLockup.js +61 -60
- package/lib/cjs/PriceLockup/dictionary.js +2 -2
- package/lib/cjs/PriceLockup/tokens.js +3 -3
- package/lib/cjs/Progress/ProgressBar.js +14 -17
- package/lib/cjs/QuantitySelector/QuantitySelector.js +8 -9
- package/lib/cjs/QuantitySelector/{SideButton.js → QuantitySelectorSideButton.js} +5 -6
- package/lib/cjs/QuantitySelector/dictionary.js +2 -2
- package/lib/cjs/ResponsiveImage/ResponsiveImage.js +3 -4
- package/lib/cjs/Ribbon/Ribbon.js +56 -65
- package/lib/cjs/SkeletonProvider/SkeletonImage.js +3 -4
- package/lib/cjs/SkeletonProvider/SkeletonProvider.js +10 -10
- package/lib/cjs/SkeletonProvider/SkeletonTypography.js +3 -4
- package/lib/cjs/Span/Span.js +6 -7
- package/lib/cjs/Spinner/Spinner.js +29 -29
- package/lib/cjs/Spinner/SpinnerContent.js +6 -7
- package/lib/cjs/StoryCard/StoryCard.js +17 -22
- package/lib/cjs/Table/Table.js +32 -25
- package/lib/cjs/Table/{Body.js → TableBody.js} +5 -6
- package/lib/cjs/Table/{Cell.js → TableCell.js} +59 -61
- package/lib/cjs/Table/{Header.js → TableHeader.js} +7 -8
- package/lib/cjs/Table/{Row.js → TableRow.js} +18 -19
- package/lib/cjs/Table/{SubHeading.js → TableSubHeading.js} +7 -8
- package/lib/cjs/TermsAndConditions/ExpandCollapse.js +18 -19
- package/lib/cjs/TermsAndConditions/TermsAndConditions.js +44 -44
- package/lib/cjs/TermsAndConditions/dictionary.js +2 -2
- package/lib/cjs/Testimonial/Testimonial.js +24 -31
- package/lib/cjs/Toast/Toast.js +28 -30
- package/lib/cjs/Video/ControlBar/ControlBar.js +48 -47
- package/lib/cjs/Video/ControlBar/Controls/VideoButton/VideoButton.js +6 -6
- package/lib/cjs/Video/ControlBar/Controls/VideoMenu/VideoMenu.js +30 -32
- package/lib/cjs/Video/ControlBar/Controls/VideoProgressBar/VideoProgressBar.js +35 -35
- package/lib/cjs/Video/ControlBar/Controls/VolumeSlider/VolumeSlider.js +42 -42
- package/lib/cjs/Video/MiddleControlButton/MiddleControlButton.js +15 -15
- package/lib/cjs/Video/Video.js +27 -29
- package/lib/cjs/Video/videoText.js +3 -4
- package/lib/cjs/VideoPicker/VideoPicker.js +37 -33
- package/lib/cjs/VideoPicker/VideoPickerPlayer.js +5 -6
- package/lib/cjs/VideoPicker/VideoPickerThumbnail.js +28 -25
- package/lib/cjs/VideoPicker/VideoSlider.js +3 -4
- package/lib/cjs/WaffleGrid/WaffleGrid.js +51 -50
- package/lib/cjs/WebVideo/WebVideo.js +7 -8
- package/lib/cjs/baseExports.js +84 -0
- package/lib/cjs/index.js +179 -105
- package/lib/cjs/server.js +2 -3
- package/lib/cjs/shared/ConditionalWrapper/ConditionalWrapper.js +3 -3
- package/lib/cjs/shared/FullBleedContent/FullBleedContent.js +28 -22
- package/lib/cjs/shared/FullBleedContent/getFullBleedBorderRadius.js +2 -2
- package/lib/cjs/shared/FullBleedContent/index.js +11 -10
- package/lib/cjs/shared/FullBleedContent/useFullBleedContentProps.js +2 -2
- package/lib/cjs/shared/VideoSplash/SplashButton/SplashButton.js +9 -9
- package/lib/cjs/shared/VideoSplash/SplashButtonWithDetails/SplashButtonWithDetails.js +50 -50
- package/lib/cjs/shared/VideoSplash/VideoSplash.js +12 -12
- package/lib/cjs/shared/VideoSplash/helpers.js +2 -3
- package/lib/cjs/utils/index.js +14 -15
- package/lib/cjs/utils/isElementFocusable.js +2 -2
- package/lib/cjs/utils/logger.js +2 -6
- package/lib/cjs/utils/media.js +1 -1
- package/lib/cjs/utils/renderStructuredContent.js +3 -4
- package/lib/cjs/utils/scrollToAnchor.js +2 -2
- package/lib/cjs/utils/ssr.js +2 -2
- package/lib/cjs/utils/theming/get-theme-from-server.js +2 -3
- package/lib/cjs/utils/theming/with-client-theme.js +2 -2
- package/lib/cjs/utils/theming/with-server-theme.js +4 -4
- package/lib/cjs/utils/transforms.js +2 -5
- package/lib/cjs/utils/useOverlaidPosition.js +2 -2
- package/lib/cjs/utils/useTypographyTheme.js +2 -2
- package/lib/esm/Badge/Badge.js +25 -26
- package/lib/esm/BlockQuote/BlockQuote.js +23 -24
- package/lib/esm/Breadcrumbs/{Item/Item.js → BreadcrumbItem.js} +35 -36
- package/lib/esm/Breadcrumbs/Breadcrumbs.js +6 -7
- package/lib/esm/Callout/Callout.js +23 -24
- package/lib/esm/Card/Card.js +63 -71
- package/lib/esm/Card/CardContent.js +52 -28
- package/lib/esm/Card/CardFooter.js +27 -18
- package/lib/esm/Countdown/Countdown.js +4 -5
- package/lib/esm/Countdown/Segment.js +8 -9
- package/lib/esm/Countdown/dictionary.js +1 -1
- package/lib/esm/Countdown/types.js +1 -5
- package/lib/esm/Countdown/useCountdown.js +2 -3
- package/lib/esm/DatePicker/CalendarContainer.js +64 -65
- package/lib/esm/DatePicker/DatePicker.js +18 -19
- package/lib/esm/DatePicker/dictionary.js +2 -3
- package/lib/esm/DatePicker/reactDatesCss.js +1 -2
- package/lib/esm/Disclaimer/Disclaimer.js +27 -12
- package/lib/esm/Footnote/Footnote.js +104 -104
- package/lib/esm/Footnote/FootnoteLink.js +26 -17
- package/lib/esm/Footnote/dictionary.js +1 -1
- package/lib/esm/IconButton/IconButton.js +2 -3
- package/lib/esm/Image/Image.js +10 -1
- package/lib/esm/Image/server.js +4 -4
- package/lib/esm/List/List.js +2 -2
- package/lib/esm/List/ListItem.js +2 -3
- package/lib/esm/NavigationBar/NavigationBar.js +5 -6
- package/lib/esm/NavigationBar/NavigationItem.js +9 -10
- package/lib/esm/NavigationBar/NavigationSubMenu.js +7 -8
- package/lib/esm/NavigationBar/collapseItems.js +2 -3
- package/lib/esm/NavigationBar/resolveItemSelection.js +2 -3
- package/lib/esm/OptimizeImage/OptimizeImage.js +4 -6
- package/lib/esm/OptimizeImage/utils/getFallbackUrl.js +2 -2
- package/lib/esm/OptimizeImage/utils/getImageUrls.js +3 -3
- package/lib/esm/OptimizeImage/utils/getOptimizedUrl.js +2 -2
- package/lib/esm/OptimizeImage/utils/hasWebpSupport.js +1 -1
- package/lib/esm/OptimizeImage/utils/index.js +4 -4
- package/lib/esm/OptimizeImage/utils/isSvgUrl.js +1 -1
- package/lib/esm/OrderedList/OrderedList.js +4 -7
- package/lib/esm/OrderedList/OrderedListBase.js +3 -6
- package/lib/esm/OrderedList/{Item.js → OrderedListItem.js} +45 -38
- package/lib/esm/OrderedList/{ItemBase.js → OrderedListItemBase.js} +5 -6
- package/lib/esm/OrderedList/constants.js +0 -1
- package/lib/esm/Paragraph/Paragraph.js +9 -10
- package/lib/esm/PreviewCard/PreviewCard.js +16 -21
- package/lib/esm/PreviewCard/{AuthorDate.js → PreviewCardAuthorDate.js} +4 -5
- package/lib/esm/PriceLockup/PriceLockup.js +57 -56
- package/lib/esm/PriceLockup/dictionary.js +1 -1
- package/lib/esm/PriceLockup/tokens.js +1 -1
- package/lib/esm/Progress/ProgressBar.js +13 -16
- package/lib/esm/QuantitySelector/QuantitySelector.js +6 -7
- package/lib/esm/QuantitySelector/{SideButton.js → QuantitySelectorSideButton.js} +4 -5
- package/lib/esm/QuantitySelector/dictionary.js +1 -1
- package/lib/esm/ResponsiveImage/ResponsiveImage.js +2 -3
- package/lib/esm/Ribbon/Ribbon.js +55 -64
- package/lib/esm/SkeletonProvider/SkeletonImage.js +2 -3
- package/lib/esm/SkeletonProvider/SkeletonProvider.js +6 -7
- package/lib/esm/SkeletonProvider/SkeletonTypography.js +2 -3
- package/lib/esm/Span/Span.js +5 -6
- package/lib/esm/Spinner/Spinner.js +24 -24
- package/lib/esm/Spinner/SpinnerContent.js +5 -6
- package/lib/esm/StoryCard/StoryCard.js +15 -16
- package/lib/esm/Table/Table.js +31 -24
- package/lib/esm/Table/{Body.js → TableBody.js} +4 -5
- package/lib/esm/Table/{Cell.js → TableCell.js} +57 -58
- package/lib/esm/Table/{Header.js → TableHeader.js} +6 -7
- package/lib/esm/Table/{Row.js → TableRow.js} +17 -18
- package/lib/esm/Table/{SubHeading.js → TableSubHeading.js} +6 -7
- package/lib/esm/TermsAndConditions/ExpandCollapse.js +18 -19
- package/lib/esm/TermsAndConditions/TermsAndConditions.js +40 -40
- package/lib/esm/TermsAndConditions/dictionary.js +1 -1
- package/lib/esm/Testimonial/Testimonial.js +22 -29
- package/lib/esm/Toast/Toast.js +26 -27
- package/lib/esm/Video/ControlBar/ControlBar.js +33 -33
- package/lib/esm/Video/ControlBar/Controls/VideoButton/VideoButton.js +5 -6
- package/lib/esm/Video/ControlBar/Controls/VideoMenu/VideoMenu.js +28 -31
- package/lib/esm/Video/ControlBar/Controls/VideoProgressBar/VideoProgressBar.js +33 -34
- package/lib/esm/Video/ControlBar/Controls/VolumeSlider/VolumeSlider.js +38 -39
- package/lib/esm/Video/MiddleControlButton/MiddleControlButton.js +14 -15
- package/lib/esm/Video/Video.js +19 -21
- package/lib/esm/Video/videoText.js +2 -3
- package/lib/esm/VideoPicker/VideoPicker.js +32 -27
- package/lib/esm/VideoPicker/VideoPickerPlayer.js +3 -4
- package/lib/esm/VideoPicker/VideoPickerThumbnail.js +26 -23
- package/lib/esm/VideoPicker/VideoSlider.js +2 -3
- package/lib/esm/WaffleGrid/WaffleGrid.js +49 -46
- package/lib/esm/WebVideo/WebVideo.js +5 -6
- package/lib/esm/baseExports.js +1 -1
- package/lib/esm/index.js +46 -37
- package/lib/esm/server.js +1 -2
- package/lib/esm/shared/ConditionalWrapper/ConditionalWrapper.js +2 -3
- package/lib/esm/shared/FullBleedContent/FullBleedContent.js +25 -20
- package/lib/esm/shared/FullBleedContent/getFullBleedBorderRadius.js +2 -3
- package/lib/esm/shared/FullBleedContent/index.js +3 -4
- package/lib/esm/shared/FullBleedContent/useFullBleedContentProps.js +3 -5
- package/lib/esm/shared/VideoSplash/SplashButton/SplashButton.js +8 -9
- package/lib/esm/shared/VideoSplash/SplashButtonWithDetails/SplashButtonWithDetails.js +48 -49
- package/lib/esm/shared/VideoSplash/VideoSplash.js +8 -9
- package/lib/esm/shared/VideoSplash/helpers.js +1 -1
- package/lib/esm/utils/index.js +7 -7
- package/lib/esm/utils/isElementFocusable.js +2 -3
- package/lib/esm/utils/logger.js +0 -4
- package/lib/esm/utils/media.js +1 -1
- package/lib/esm/utils/renderStructuredContent.js +2 -3
- package/lib/esm/utils/scrollToAnchor.js +2 -3
- package/lib/esm/utils/ssr.js +2 -3
- package/lib/esm/utils/theming/get-theme-from-server.js +1 -1
- package/lib/esm/utils/theming/with-client-theme.js +2 -3
- package/lib/esm/utils/theming/with-server-theme.js +3 -4
- package/lib/esm/utils/transforms.js +1 -4
- package/lib/esm/utils/useOverlaidPosition.js +2 -3
- package/lib/esm/utils/useTypographyTheme.js +2 -3
- package/package.json +13 -22
- package/src/Badge/Badge.jsx +18 -20
- package/src/BlockQuote/BlockQuote.jsx +16 -18
- package/src/Breadcrumbs/{Item/Item.jsx → BreadcrumbItem.jsx} +20 -21
- package/src/Breadcrumbs/Breadcrumbs.jsx +6 -9
- package/src/Callout/Callout.jsx +16 -18
- package/src/Card/Card.jsx +59 -80
- package/src/Card/CardContent.jsx +52 -28
- package/src/Card/CardFooter.jsx +26 -12
- package/src/Countdown/Countdown.jsx +3 -5
- package/src/Countdown/Segment.jsx +6 -8
- package/src/Countdown/dictionary.js +1 -1
- package/src/Countdown/types.js +0 -2
- package/src/Countdown/useCountdown.js +1 -3
- package/src/DatePicker/CalendarContainer.jsx +65 -67
- package/src/DatePicker/DatePicker.jsx +17 -19
- package/src/DatePicker/dictionary.js +1 -3
- package/src/DatePicker/reactDatesCss.js +1 -3
- package/src/Disclaimer/Disclaimer.jsx +15 -8
- package/src/Footnote/Footnote.jsx +104 -93
- package/src/Footnote/FootnoteLink.jsx +16 -13
- package/src/Footnote/dictionary.js +1 -1
- package/src/IconButton/IconButton.jsx +1 -3
- package/src/Image/Image.jsx +9 -1
- package/src/Image/server.js +4 -4
- package/src/List/List.jsx +2 -2
- package/src/List/ListItem.jsx +1 -3
- package/src/NavigationBar/NavigationBar.jsx +4 -6
- package/src/NavigationBar/NavigationItem.jsx +6 -8
- package/src/NavigationBar/NavigationSubMenu.jsx +7 -8
- package/src/NavigationBar/collapseItems.js +1 -3
- package/src/NavigationBar/resolveItemSelection.js +1 -3
- package/src/OptimizeImage/OptimizeImage.jsx +3 -6
- package/src/OptimizeImage/utils/getFallbackUrl.js +2 -2
- package/src/OptimizeImage/utils/getImageUrls.js +3 -3
- package/src/OptimizeImage/utils/getOptimizedUrl.js +2 -9
- package/src/OptimizeImage/utils/hasWebpSupport.js +1 -1
- package/src/OptimizeImage/utils/index.js +4 -4
- package/src/OptimizeImage/utils/isSvgUrl.js +1 -1
- package/src/OrderedList/OrderedList.jsx +3 -8
- package/src/OrderedList/OrderedListBase.jsx +2 -7
- package/src/OrderedList/{Item.jsx → OrderedListItem.jsx} +44 -32
- package/src/OrderedList/{ItemBase.jsx → OrderedListItemBase.jsx} +4 -4
- package/src/OrderedList/constants.js +0 -1
- package/src/Paragraph/Paragraph.jsx +7 -9
- package/src/PreviewCard/PreviewCard.jsx +16 -32
- package/src/PreviewCard/{AuthorDate.jsx → PreviewCardAuthorDate.jsx} +3 -5
- package/src/PriceLockup/PriceLockup.jsx +33 -31
- package/src/PriceLockup/dictionary.js +1 -1
- package/src/PriceLockup/tokens.js +1 -1
- package/src/Progress/ProgressBar.jsx +33 -30
- package/src/QuantitySelector/QuantitySelector.jsx +5 -7
- package/src/QuantitySelector/{SideButton.jsx → QuantitySelectorSideButton.jsx} +3 -4
- package/src/QuantitySelector/dictionary.js +1 -1
- package/src/ResponsiveImage/ResponsiveImage.jsx +1 -3
- package/src/Ribbon/Ribbon.jsx +35 -44
- package/src/SkeletonProvider/SkeletonImage.jsx +1 -3
- package/src/SkeletonProvider/SkeletonProvider.jsx +5 -9
- package/src/SkeletonProvider/SkeletonTypography.jsx +1 -3
- package/src/Span/Span.jsx +11 -11
- package/src/Spinner/Spinner.jsx +17 -19
- package/src/Spinner/SpinnerContent.jsx +4 -6
- package/src/StoryCard/StoryCard.jsx +15 -16
- package/src/Table/Table.jsx +81 -75
- package/src/Table/{Body.jsx → TableBody.jsx} +3 -5
- package/src/Table/{Cell.jsx → TableCell.jsx} +69 -65
- package/src/Table/{Header.jsx → TableHeader.jsx} +6 -8
- package/src/Table/{Row.jsx → TableRow.jsx} +11 -12
- package/src/Table/{SubHeading.jsx → TableSubHeading.jsx} +6 -8
- package/src/TermsAndConditions/ExpandCollapse.jsx +18 -19
- package/src/TermsAndConditions/TermsAndConditions.jsx +37 -37
- package/src/TermsAndConditions/dictionary.js +1 -1
- package/src/Testimonial/Testimonial.jsx +20 -28
- package/src/Toast/Toast.jsx +36 -35
- package/src/Video/ControlBar/ControlBar.jsx +28 -25
- package/src/Video/ControlBar/Controls/VideoButton/VideoButton.jsx +4 -6
- package/src/Video/ControlBar/Controls/VideoMenu/VideoMenu.jsx +26 -30
- package/src/Video/ControlBar/Controls/VideoProgressBar/VideoProgressBar.jsx +31 -33
- package/src/Video/ControlBar/Controls/VolumeSlider/VolumeSlider.jsx +40 -40
- package/src/Video/MiddleControlButton/MiddleControlButton.jsx +10 -12
- package/src/Video/Video.jsx +697 -683
- package/src/Video/videoText.js +1 -3
- package/src/VideoPicker/VideoPicker.jsx +37 -25
- package/src/VideoPicker/VideoPickerPlayer.jsx +2 -4
- package/src/VideoPicker/VideoPickerThumbnail.jsx +26 -15
- package/src/VideoPicker/VideoSlider.jsx +1 -3
- package/src/WaffleGrid/WaffleGrid.jsx +31 -27
- package/src/WebVideo/WebVideo.jsx +4 -6
- package/src/baseExports.js +27 -13
- package/src/index.js +46 -37
- package/src/server.js +1 -2
- package/src/shared/ConditionalWrapper/ConditionalWrapper.jsx +1 -3
- package/src/shared/FullBleedContent/FullBleedContent.jsx +26 -19
- package/src/shared/FullBleedContent/getFullBleedBorderRadius.js +1 -3
- package/src/shared/FullBleedContent/index.js +3 -8
- package/src/shared/FullBleedContent/useFullBleedContentProps.js +2 -5
- package/src/shared/VideoSplash/SplashButton/SplashButton.jsx +5 -7
- package/src/shared/VideoSplash/SplashButtonWithDetails/SplashButtonWithDetails.jsx +25 -25
- package/src/shared/VideoSplash/VideoSplash.jsx +7 -9
- package/src/shared/VideoSplash/helpers.js +1 -1
- package/src/utils/index.js +7 -7
- package/src/utils/isElementFocusable.js +1 -3
- package/src/utils/logger.js +0 -5
- package/src/utils/media.js +1 -1
- package/src/utils/renderStructuredContent.jsx +1 -3
- package/src/utils/scrollToAnchor.js +1 -3
- package/src/utils/ssr.js +1 -3
- package/src/utils/theming/get-theme-from-server.js +1 -1
- package/src/utils/theming/with-client-theme.jsx +1 -3
- package/src/utils/theming/with-server-theme.jsx +2 -4
- package/src/utils/transforms.js +0 -2
- package/src/utils/useOverlaidPosition.js +1 -3
- package/src/utils/useTypographyTheme.js +1 -3
- package/types/Autocomplete.d.ts +1 -3
- package/types/Badge.d.ts +1 -3
- package/types/BaseProvider.d.ts +1 -3
- package/types/BlockQuote.d.ts +1 -3
- package/types/Box.d.ts +1 -3
- package/types/BreadcrumbItem.d.ts +1 -3
- package/types/Breadcrumbs.d.ts +2 -4
- package/types/Callout.d.ts +1 -3
- package/types/Card.d.ts +1 -3
- package/types/Cell.d.ts +1 -3
- package/types/ControlBar.d.ts +1 -3
- package/types/Countdown.d.ts +1 -3
- package/types/DatePicker.d.ts +1 -3
- package/types/FileUpload.d.ts +1 -3
- package/types/Footnote.d.ts +1 -3
- package/types/FootnoteLink.d.ts +1 -3
- package/types/Listbox.d.ts +1 -3
- package/types/MiddleControlButton.d.ts +1 -3
- package/types/MultiSelectFilter.d.ts +1 -3
- package/types/PriceLockup.d.ts +1 -3
- package/types/QuantitySelector.d.ts +1 -3
- package/types/Ribbon.d.ts +1 -3
- package/types/Spinner.d.ts +1 -3
- package/types/Table.d.ts +1 -3
- package/types/Tooltip.d.ts +1 -3
- package/types/TooltipButton.d.ts +1 -3
- package/types/Typography.d.ts +1 -3
- package/types/Video.d.ts +1 -3
- package/types/VideoButton.d.ts +1 -3
- package/types/VideoMenu.d.ts +1 -3
- package/types/VideoProgressBar.d.ts +1 -3
- package/types/VolumeSlider.d.ts +1 -3
- package/types/WebVideo.d.ts +1 -3
- package/lib/cjs/Badge/index.js +0 -9
- package/lib/cjs/BlockQuote/index.js +0 -9
- package/lib/cjs/Breadcrumbs/index.js +0 -13
- package/lib/cjs/Callout/index.js +0 -9
- package/lib/cjs/Card/index.js +0 -9
- package/lib/cjs/Countdown/index.js +0 -9
- package/lib/cjs/DatePicker/index.js +0 -9
- package/lib/cjs/Disclaimer/index.js +0 -13
- package/lib/cjs/Footnote/index.js +0 -11
- package/lib/cjs/IconButton/index.js +0 -9
- package/lib/cjs/Image/index.js +0 -20
- package/lib/cjs/List/index.js +0 -17
- package/lib/cjs/NavigationBar/index.js +0 -11
- package/lib/cjs/OptimizeImage/index.js +0 -9
- package/lib/cjs/OrderedList/index.js +0 -17
- package/lib/cjs/Paragraph/index.js +0 -9
- package/lib/cjs/PreviewCard/index.js +0 -9
- package/lib/cjs/PriceLockup/index.js +0 -9
- package/lib/cjs/Progress/index.js +0 -11
- package/lib/cjs/QuantitySelector/index.js +0 -9
- package/lib/cjs/ResponsiveImage/index.js +0 -9
- package/lib/cjs/Ribbon/index.js +0 -9
- package/lib/cjs/SkeletonProvider/index.js +0 -9
- package/lib/cjs/Span/index.js +0 -9
- package/lib/cjs/Spinner/index.js +0 -9
- package/lib/cjs/StoryCard/index.js +0 -9
- package/lib/cjs/Table/index.js +0 -24
- package/lib/cjs/TermsAndConditions/index.js +0 -13
- package/lib/cjs/Testimonial/index.js +0 -9
- package/lib/cjs/Toast/index.js +0 -9
- package/lib/cjs/Video/index.js +0 -9
- package/lib/cjs/VideoPicker/index.js +0 -9
- package/lib/cjs/WaffleGrid/index.js +0 -9
- package/lib/cjs/WebVideo/index.js +0 -9
- package/lib/cjs/shared/ConditionalWrapper/index.js +0 -9
- package/lib/esm/Badge/index.js +0 -2
- package/lib/esm/BlockQuote/index.js +0 -2
- package/lib/esm/Breadcrumbs/index.js +0 -1
- package/lib/esm/Callout/index.js +0 -2
- package/lib/esm/Card/index.js +0 -2
- package/lib/esm/Countdown/index.js +0 -2
- package/lib/esm/DatePicker/index.js +0 -2
- package/lib/esm/Disclaimer/index.js +0 -1
- package/lib/esm/Footnote/index.js +0 -4
- package/lib/esm/IconButton/index.js +0 -2
- package/lib/esm/Image/index.js +0 -9
- package/lib/esm/List/index.js +0 -5
- package/lib/esm/NavigationBar/index.js +0 -4
- package/lib/esm/OptimizeImage/index.js +0 -2
- package/lib/esm/OrderedList/index.js +0 -5
- package/lib/esm/Paragraph/index.js +0 -2
- package/lib/esm/PreviewCard/index.js +0 -2
- package/lib/esm/PriceLockup/index.js +0 -2
- package/lib/esm/Progress/index.js +0 -4
- package/lib/esm/QuantitySelector/index.js +0 -2
- package/lib/esm/ResponsiveImage/index.js +0 -2
- package/lib/esm/Ribbon/index.js +0 -2
- package/lib/esm/SkeletonProvider/index.js +0 -2
- package/lib/esm/Span/index.js +0 -2
- package/lib/esm/Spinner/index.js +0 -2
- package/lib/esm/StoryCard/index.js +0 -2
- package/lib/esm/Table/index.js +0 -17
- package/lib/esm/TermsAndConditions/index.js +0 -1
- package/lib/esm/Testimonial/index.js +0 -2
- package/lib/esm/Toast/index.js +0 -2
- package/lib/esm/Video/index.js +0 -2
- package/lib/esm/VideoPicker/index.js +0 -2
- package/lib/esm/WaffleGrid/index.js +0 -2
- package/lib/esm/WebVideo/index.js +0 -2
- package/lib/esm/shared/ConditionalWrapper/index.js +0 -2
- package/src/Badge/index.js +0 -3
- package/src/BlockQuote/index.js +0 -3
- package/src/Breadcrumbs/index.js +0 -1
- package/src/Callout/index.js +0 -3
- package/src/Card/index.js +0 -3
- package/src/Countdown/index.js +0 -3
- package/src/DatePicker/index.js +0 -3
- package/src/Disclaimer/index.js +0 -1
- package/src/Footnote/index.js +0 -6
- package/src/IconButton/index.js +0 -3
- package/src/Image/index.js +0 -10
- package/src/List/index.js +0 -8
- package/src/NavigationBar/index.js +0 -6
- package/src/OptimizeImage/index.js +0 -3
- package/src/OrderedList/index.js +0 -8
- package/src/Paragraph/index.js +0 -3
- package/src/PreviewCard/index.js +0 -3
- package/src/PriceLockup/index.js +0 -3
- package/src/Progress/index.js +0 -6
- package/src/QuantitySelector/index.js +0 -3
- package/src/ResponsiveImage/index.js +0 -3
- package/src/Ribbon/index.js +0 -3
- package/src/SkeletonProvider/index.js +0 -3
- package/src/Span/index.js +0 -3
- package/src/Spinner/index.js +0 -3
- package/src/StoryCard/index.js +0 -3
- package/src/Table/index.js +0 -20
- package/src/TermsAndConditions/index.js +0 -1
- package/src/Testimonial/index.js +0 -3
- package/src/Toast/index.js +0 -3
- package/src/Video/index.js +0 -3
- package/src/VideoPicker/index.js +0 -3
- package/src/WaffleGrid/index.js +0 -3
- package/src/WebVideo/index.js +0 -3
- package/src/shared/ConditionalWrapper/index.js +0 -3
|
@@ -15,56 +15,58 @@ import {
|
|
|
15
15
|
StyleSheet
|
|
16
16
|
} from '@telus-uds/components-base'
|
|
17
17
|
import styled from 'styled-components'
|
|
18
|
-
import ExpandCollapse from './ExpandCollapse'
|
|
19
|
-
import OrderedListBase from '../OrderedList/OrderedListBase'
|
|
18
|
+
import { ExpandCollapse } from './ExpandCollapse'
|
|
19
|
+
import { OrderedListBase } from '../OrderedList/OrderedListBase'
|
|
20
|
+
import { OrderedListItemBase } from '../OrderedList/OrderedListItemBase'
|
|
21
|
+
|
|
20
22
|
import { htmlAttrs, media, renderStructuredContent } from '../utils'
|
|
21
|
-
import defaultDictionary from './dictionary'
|
|
23
|
+
import { dictionary as defaultDictionary } from './dictionary'
|
|
22
24
|
|
|
23
25
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([htmlAttrs])
|
|
24
26
|
|
|
25
|
-
const ContentContainer = styled.div(({ tokens }) => ({
|
|
26
|
-
paddingBottom: tokens.contentPaddingBottom,
|
|
27
|
-
paddingLeft: tokens.contentPaddingLeft,
|
|
27
|
+
const ContentContainer = styled.div(({ $tokens }) => ({
|
|
28
|
+
paddingBottom: $tokens.contentPaddingBottom,
|
|
29
|
+
paddingLeft: $tokens.contentPaddingLeft,
|
|
28
30
|
...media().from('md').css({
|
|
29
|
-
paddingBottom: tokens.mdContentPaddingBottom,
|
|
30
|
-
paddingLeft: tokens.mdContentPaddingLeft
|
|
31
|
+
paddingBottom: $tokens.mdContentPaddingBottom,
|
|
32
|
+
paddingLeft: $tokens.mdContentPaddingLeft
|
|
31
33
|
})
|
|
32
34
|
}))
|
|
33
35
|
|
|
34
|
-
const Ordered = styled(OrderedListBase)(({ tokens }) => ({
|
|
36
|
+
const Ordered = styled(OrderedListBase)(({ $tokens }) => ({
|
|
35
37
|
listStylePosition: 'outside',
|
|
36
|
-
padding: tokens.orderedPadding
|
|
38
|
+
padding: $tokens.orderedPadding
|
|
37
39
|
}))
|
|
38
40
|
|
|
39
|
-
const Unordered = styled.ul(({ tokens }) => ({
|
|
41
|
+
const Unordered = styled.ul(({ $tokens }) => ({
|
|
40
42
|
listStyleType: 'none',
|
|
41
43
|
margin: 0,
|
|
42
44
|
padding: 0,
|
|
43
|
-
paddingTop: tokens.unorderedPadding
|
|
45
|
+
paddingTop: $tokens.unorderedPadding
|
|
44
46
|
}))
|
|
45
47
|
|
|
46
|
-
const ListItem = styled(
|
|
48
|
+
const ListItem = styled(OrderedListItemBase)(({ $tokens }) => ({
|
|
47
49
|
display: 'list-item',
|
|
48
50
|
'&::marker': {
|
|
49
|
-
fontFamily: `${tokens.listFontName}${tokens.listFontWeight}normal`,
|
|
50
|
-
fontSize: tokens.listFontSize,
|
|
51
|
-
lineHeight: tokens.listLineHeight,
|
|
51
|
+
fontFamily: `${$tokens.listFontName}${$tokens.listFontWeight}normal`,
|
|
52
|
+
fontSize: $tokens.listFontSize,
|
|
53
|
+
lineHeight: $tokens.listLineHeight,
|
|
52
54
|
textAlign: 'end !important'
|
|
53
55
|
},
|
|
54
|
-
color: tokens.listColor,
|
|
55
|
-
fontFamily: `${tokens.listFontName}${tokens.listFontWeight}normal`,
|
|
56
|
-
fontSize: tokens.listFontSize,
|
|
57
|
-
lineHeight: tokens.listLineHeight,
|
|
58
|
-
marginBottom: tokens.listMarginBottom,
|
|
59
|
-
marginLeft: tokens.listMarginLeft,
|
|
56
|
+
color: $tokens.listColor,
|
|
57
|
+
fontFamily: `${$tokens.listFontName}${$tokens.listFontWeight}normal`,
|
|
58
|
+
fontSize: $tokens.listFontSize,
|
|
59
|
+
lineHeight: $tokens.listLineHeight,
|
|
60
|
+
marginBottom: $tokens.listMarginBottom,
|
|
61
|
+
marginLeft: $tokens.listMarginLeft,
|
|
60
62
|
wordBreak: 'break-word'
|
|
61
63
|
}))
|
|
62
64
|
|
|
63
|
-
const NonIndexedContentTitle = styled.div(({ tokens }) => ({
|
|
64
|
-
color: tokens.titleColor,
|
|
65
|
-
fontSize: tokens.titleFontSize,
|
|
66
|
-
lineHeight: tokens.titleLineHeight,
|
|
67
|
-
paddingLeft: tokens.titlePaddingLeft
|
|
65
|
+
const NonIndexedContentTitle = styled.div(({ $tokens }) => ({
|
|
66
|
+
color: $tokens.titleColor,
|
|
67
|
+
fontSize: $tokens.titleFontSize,
|
|
68
|
+
lineHeight: $tokens.titleLineHeight,
|
|
69
|
+
paddingLeft: $tokens.titlePaddingLeft
|
|
68
70
|
}))
|
|
69
71
|
|
|
70
72
|
/**
|
|
@@ -76,7 +78,7 @@ const NonIndexedContentTitle = styled.div(({ tokens }) => ({
|
|
|
76
78
|
* - Responsive display based on breakpoints
|
|
77
79
|
* - Use `copy` to set language, ‘en’ for English or ‘fr’ for French
|
|
78
80
|
*/
|
|
79
|
-
const TermsAndConditions = React.forwardRef(
|
|
81
|
+
export const TermsAndConditions = React.forwardRef(
|
|
80
82
|
(
|
|
81
83
|
{
|
|
82
84
|
copy = 'en',
|
|
@@ -164,12 +166,12 @@ const TermsAndConditions = React.forwardRef(
|
|
|
164
166
|
expandLabel={getCopy('expandLabel')}
|
|
165
167
|
ref={ref}
|
|
166
168
|
>
|
|
167
|
-
<ContentContainer tokens={themeTokens}>
|
|
169
|
+
<ContentContainer $tokens={themeTokens}>
|
|
168
170
|
{hasIndexedContent && (
|
|
169
|
-
<Ordered tokens={themeTokens}>
|
|
171
|
+
<Ordered $tokens={themeTokens}>
|
|
170
172
|
{indexedContent.map((contentItem, idx) => (
|
|
171
173
|
// eslint-disable-next-line react/no-array-index-key
|
|
172
|
-
<ListItem tokens={listItemStyles} key={idx} media={listItemMediaIds}>
|
|
174
|
+
<ListItem $tokens={listItemStyles} key={idx} data-media={listItemMediaIds}>
|
|
173
175
|
{renderStructuredContent(contentItem)}
|
|
174
176
|
</ListItem>
|
|
175
177
|
))}
|
|
@@ -178,8 +180,8 @@ const TermsAndConditions = React.forwardRef(
|
|
|
178
180
|
{hasNonIndexedContent && (
|
|
179
181
|
<Box between={3}>
|
|
180
182
|
<NonIndexedContentTitle
|
|
181
|
-
tokens={nonIndexedContentStyles}
|
|
182
|
-
media={nonIndexedContentMediaIds}
|
|
183
|
+
$tokens={nonIndexedContentStyles}
|
|
184
|
+
data-media={nonIndexedContentMediaIds}
|
|
183
185
|
>
|
|
184
186
|
<Typography
|
|
185
187
|
block
|
|
@@ -194,10 +196,10 @@ const TermsAndConditions = React.forwardRef(
|
|
|
194
196
|
{getCopy('nonIndexedTitle')}
|
|
195
197
|
</Typography>
|
|
196
198
|
</NonIndexedContentTitle>
|
|
197
|
-
<Unordered tokens={themeTokens}>
|
|
199
|
+
<Unordered $tokens={themeTokens}>
|
|
198
200
|
{nonIndexedContent.map((contentItem, idx) => (
|
|
199
201
|
// eslint-disable-next-line react/no-array-index-key
|
|
200
|
-
<ListItem tokens={listItemStyles} key={idx} media={listItemMediaIds}>
|
|
202
|
+
<ListItem $tokens={listItemStyles} key={idx} data-media={listItemMediaIds}>
|
|
201
203
|
{renderStructuredContent(contentItem)}
|
|
202
204
|
</ListItem>
|
|
203
205
|
))}
|
|
@@ -260,5 +262,3 @@ TermsAndConditions.propTypes = {
|
|
|
260
262
|
fr: dictionaryContentShape
|
|
261
263
|
})
|
|
262
264
|
}
|
|
263
|
-
|
|
264
|
-
export default TermsAndConditions
|
|
@@ -9,27 +9,27 @@ import {
|
|
|
9
9
|
getTokensPropType
|
|
10
10
|
} from '@telus-uds/components-base'
|
|
11
11
|
import styled from 'styled-components'
|
|
12
|
-
import Image from '../Image'
|
|
12
|
+
import { Image } from '../Image/Image'
|
|
13
13
|
import { htmlAttrs } from '../utils'
|
|
14
14
|
|
|
15
15
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([htmlAttrs])
|
|
16
16
|
|
|
17
|
-
const TestimonialContainer = styled.figure(({ testimonialContainerGap }) => ({
|
|
17
|
+
const TestimonialContainer = styled.figure(({ $testimonialContainerGap }) => ({
|
|
18
18
|
display: 'flex',
|
|
19
19
|
flexDirection: 'column',
|
|
20
|
-
gap: testimonialContainerGap,
|
|
20
|
+
gap: $testimonialContainerGap,
|
|
21
21
|
margin: 0
|
|
22
22
|
}))
|
|
23
23
|
|
|
24
|
-
const QuoteContainer = styled.div(({ quoteContainerGap }) => ({
|
|
24
|
+
const QuoteContainer = styled.div(({ $quoteContainerGap }) => ({
|
|
25
25
|
display: 'flex',
|
|
26
26
|
alignItems: 'center',
|
|
27
|
-
gap: quoteContainerGap
|
|
27
|
+
gap: $quoteContainerGap
|
|
28
28
|
}))
|
|
29
29
|
|
|
30
|
-
const Divider = styled.div(({ dividerBorder, dividerBackgroundColor }) => ({
|
|
31
|
-
height: dividerBorder,
|
|
32
|
-
background: dividerBackgroundColor,
|
|
30
|
+
const Divider = styled.div(({ $dividerBorder, $dividerBackgroundColor }) => ({
|
|
31
|
+
height: $dividerBorder,
|
|
32
|
+
background: $dividerBackgroundColor,
|
|
33
33
|
width: '100%'
|
|
34
34
|
}))
|
|
35
35
|
|
|
@@ -42,20 +42,19 @@ const AuthorInfoContainer = styled.div({
|
|
|
42
42
|
flexDirection: 'column'
|
|
43
43
|
})
|
|
44
44
|
|
|
45
|
-
const Figcaption = styled.figcaption(({ figcaptionGap }) => ({
|
|
45
|
+
const Figcaption = styled.figcaption(({ $figcaptionGap }) => ({
|
|
46
46
|
display: 'flex',
|
|
47
47
|
alignItems: 'center',
|
|
48
|
-
gap: figcaptionGap
|
|
48
|
+
gap: $figcaptionGap
|
|
49
49
|
}))
|
|
50
50
|
|
|
51
|
-
const Testimonial = React.forwardRef(
|
|
51
|
+
export const Testimonial = React.forwardRef(
|
|
52
52
|
(
|
|
53
53
|
{
|
|
54
54
|
showDivider,
|
|
55
55
|
testimonial,
|
|
56
56
|
title,
|
|
57
|
-
|
|
58
|
-
image = imageSrc,
|
|
57
|
+
image,
|
|
59
58
|
additionalInfo,
|
|
60
59
|
testimonialStyle = 'large',
|
|
61
60
|
tokens,
|
|
@@ -105,11 +104,11 @@ const Testimonial = React.forwardRef(
|
|
|
105
104
|
|
|
106
105
|
return (
|
|
107
106
|
<TestimonialContainer
|
|
108
|
-
testimonialContainerGap={testimonialContainerGap}
|
|
107
|
+
$testimonialContainerGap={testimonialContainerGap}
|
|
109
108
|
ref={ref}
|
|
110
109
|
{...selectProps(rest)}
|
|
111
110
|
>
|
|
112
|
-
<QuoteContainer quoteContainerGap={quoteContainerGap}>
|
|
111
|
+
<QuoteContainer $quoteContainerGap={quoteContainerGap}>
|
|
113
112
|
<Icon
|
|
114
113
|
tokens={{ color: iconColor }}
|
|
115
114
|
variant={{ size: 'micro' }}
|
|
@@ -117,8 +116,8 @@ const Testimonial = React.forwardRef(
|
|
|
117
116
|
/>
|
|
118
117
|
{showDivider && (
|
|
119
118
|
<Divider
|
|
120
|
-
dividerBackgroundColor={dividerBackgroundColor}
|
|
121
|
-
dividerBorder={dividerBorder}
|
|
119
|
+
$dividerBackgroundColor={dividerBackgroundColor}
|
|
120
|
+
$dividerBorder={dividerBorder}
|
|
122
121
|
role="separator"
|
|
123
122
|
/>
|
|
124
123
|
)}
|
|
@@ -147,7 +146,7 @@ const Testimonial = React.forwardRef(
|
|
|
147
146
|
</Typography>
|
|
148
147
|
</BlockQuote>
|
|
149
148
|
{(image || title || additionalInfo) && (
|
|
150
|
-
<Figcaption figcaptionGap={figcaptionGap}>
|
|
149
|
+
<Figcaption $figcaptionGap={figcaptionGap}>
|
|
151
150
|
{image &&
|
|
152
151
|
(typeof image === 'string' ? (
|
|
153
152
|
<Image
|
|
@@ -196,8 +195,8 @@ const Testimonial = React.forwardRef(
|
|
|
196
195
|
)}
|
|
197
196
|
{showDivider && (
|
|
198
197
|
<Divider
|
|
199
|
-
dividerBackgroundColor={dividerBackgroundColor}
|
|
200
|
-
dividerBorder={dividerBorder}
|
|
198
|
+
$dividerBackgroundColor={dividerBackgroundColor}
|
|
199
|
+
$dividerBorder={dividerBorder}
|
|
201
200
|
role="separator"
|
|
202
201
|
/>
|
|
203
202
|
)}
|
|
@@ -234,12 +233,5 @@ Testimonial.propTypes = {
|
|
|
234
233
|
/**
|
|
235
234
|
* The src attribute for the Image component or custom JSX content to render instead
|
|
236
235
|
*/
|
|
237
|
-
image: PropTypes.oneOfType([PropTypes.string, PropTypes.node])
|
|
238
|
-
/**
|
|
239
|
-
* The src attribute for the `Image` component to be displayed on the testimonial
|
|
240
|
-
* @deprecated please use the `image` prop instead
|
|
241
|
-
*/
|
|
242
|
-
imageSrc: PropTypes.string
|
|
236
|
+
image: PropTypes.oneOfType([PropTypes.string, PropTypes.node])
|
|
243
237
|
}
|
|
244
|
-
|
|
245
|
-
export default Testimonial
|
package/src/Toast/Toast.jsx
CHANGED
|
@@ -42,36 +42,39 @@ const slideDown =
|
|
|
42
42
|
|
|
43
43
|
const animation = (props) => css`
|
|
44
44
|
${slideDown('height')(
|
|
45
|
-
`${props
|
|
46
|
-
`${props
|
|
45
|
+
`${props.$animationHeightBefore}px`,
|
|
46
|
+
`${props.$animationHeightAfter}px`,
|
|
47
47
|
'auto'
|
|
48
48
|
)} 1s ease-in-out 2s forwards,
|
|
49
49
|
${transform('padding-bottom')(
|
|
50
|
-
`${props
|
|
51
|
-
`${props
|
|
50
|
+
`${props.$animationPaddingBottomBefore}px`,
|
|
51
|
+
`${props.$animationPaddingBottomAfter}px`
|
|
52
52
|
)} 1s ease-in-out 2s forwards,
|
|
53
53
|
${transform('padding-top')(
|
|
54
|
-
`${props
|
|
55
|
-
`${props
|
|
54
|
+
`${props.$animationPaddingTopBefore}px`,
|
|
55
|
+
`${props.$animationPaddingTopAfter}px`
|
|
56
56
|
)} 1s ease-in-out 2s forwards,
|
|
57
57
|
${transform('background')(
|
|
58
|
-
props
|
|
59
|
-
props
|
|
58
|
+
props.$animationBackgroundColorBefore,
|
|
59
|
+
props.$animationBackgroundColorAfter
|
|
60
60
|
)} 1s ease-in-out 3.2s forwards;
|
|
61
61
|
& * {
|
|
62
|
-
animation: ${transform('color')(props
|
|
62
|
+
animation: ${transform('color')(props.$animationColorBefore, props.$animationColorAfter)} 1s
|
|
63
63
|
ease-in-out 3s forwards;
|
|
64
64
|
}
|
|
65
65
|
& > a div {
|
|
66
|
-
animation: ${transform('color')(props
|
|
67
|
-
ease-in-out 3s forwards;
|
|
66
|
+
animation: ${transform('color')(props.$animationDivColorBefore, props.$animationDivColorAfter)}
|
|
67
|
+
1s ease-in-out 3s forwards;
|
|
68
68
|
}
|
|
69
69
|
& > a svg {
|
|
70
|
-
animation: ${transform('fill')(props
|
|
70
|
+
animation: ${transform('fill')(props.$animationFillColorBefore, props.$animationFillColorAfter)}
|
|
71
71
|
1s ease-in-out 3s forwards;
|
|
72
72
|
}
|
|
73
73
|
& > a div {
|
|
74
|
-
animation: ${transform('color')(
|
|
74
|
+
animation: ${transform('color')(
|
|
75
|
+
props.$animationFillColorBefore,
|
|
76
|
+
props.$animationFillColorAfter
|
|
77
|
+
)}
|
|
75
78
|
1s ease-in-out 3s forwards;
|
|
76
79
|
}
|
|
77
80
|
`
|
|
@@ -81,16 +84,16 @@ const ToastContainer = styled.div`
|
|
|
81
84
|
justify-content: center;
|
|
82
85
|
align-items: center;
|
|
83
86
|
flex-wrap: wrap;
|
|
84
|
-
padding-left: ${({ padding }) => padding}px;
|
|
85
|
-
padding-right: ${({ padding }) => padding}px;
|
|
86
|
-
background: ${({ containerBackgroundColor }) => containerBackgroundColor};
|
|
87
|
-
gap: ${({ containerGap }) => containerGap};
|
|
87
|
+
padding-left: ${({ $padding }) => $padding}px;
|
|
88
|
+
padding-right: ${({ $padding }) => $padding}px;
|
|
89
|
+
background: ${({ $containerBackgroundColor }) => $containerBackgroundColor};
|
|
90
|
+
gap: ${({ $containerGap }) => $containerGap};
|
|
88
91
|
height: 0;
|
|
89
92
|
overflow: hidden;
|
|
90
93
|
animation: ${animation};
|
|
91
94
|
`
|
|
92
95
|
|
|
93
|
-
const Toast = React.forwardRef(
|
|
96
|
+
export const Toast = React.forwardRef(
|
|
94
97
|
({ toast, copy, headline, link, tokens, variant = {}, ...rest }, ref) => {
|
|
95
98
|
// viewport hook added to work adjust the padding to different sizes
|
|
96
99
|
const viewport = useViewport()
|
|
@@ -122,22 +125,22 @@ const Toast = React.forwardRef(
|
|
|
122
125
|
|
|
123
126
|
return (
|
|
124
127
|
<ToastContainer
|
|
125
|
-
containerBackgroundColor={containerBackgroundColor}
|
|
126
|
-
containerGap={containerGap}
|
|
127
|
-
animationHeightBefore={animationHeightBefore}
|
|
128
|
-
animationHeightAfter={animationHeightAfter}
|
|
129
|
-
animationPaddingBottomBefore={animationPaddingBottomBefore}
|
|
130
|
-
animationPaddingBottomAfter={animationPaddingBottomAfter}
|
|
131
|
-
animationPaddingTopBefore={animationPaddingTopBefore}
|
|
132
|
-
animationPaddingTopAfter={animationPaddingTopAfter}
|
|
133
|
-
animationBackgroundColorBefore={animationBackgroundColorBefore}
|
|
134
|
-
animationBackgroundColorAfter={animationBackgroundColorAfter}
|
|
135
|
-
animationColorBefore={animationColorBefore}
|
|
136
|
-
animationColorAfter={animationColorAfter}
|
|
137
|
-
animationFillColorBefore={chevronInverseColor}
|
|
138
|
-
animationFillColorAfter={chevronDefaultColor}
|
|
128
|
+
$containerBackgroundColor={containerBackgroundColor}
|
|
129
|
+
$containerGap={containerGap}
|
|
130
|
+
$animationHeightBefore={animationHeightBefore}
|
|
131
|
+
$animationHeightAfter={animationHeightAfter}
|
|
132
|
+
$animationPaddingBottomBefore={animationPaddingBottomBefore}
|
|
133
|
+
$animationPaddingBottomAfter={animationPaddingBottomAfter}
|
|
134
|
+
$animationPaddingTopBefore={animationPaddingTopBefore}
|
|
135
|
+
$animationPaddingTopAfter={animationPaddingTopAfter}
|
|
136
|
+
$animationBackgroundColorBefore={animationBackgroundColorBefore}
|
|
137
|
+
$animationBackgroundColorAfter={animationBackgroundColorAfter}
|
|
138
|
+
$animationColorBefore={animationColorBefore}
|
|
139
|
+
$animationColorAfter={animationColorAfter}
|
|
140
|
+
$animationFillColorBefore={chevronInverseColor}
|
|
141
|
+
$animationFillColorAfter={chevronDefaultColor}
|
|
142
|
+
$padding={extraTokens.padding}
|
|
139
143
|
ref={ref}
|
|
140
|
-
{...extraTokens}
|
|
141
144
|
{...selectProps(rest)}
|
|
142
145
|
>
|
|
143
146
|
{headline && <Typography variant={{ bold: true, inverse: true }}>{headline}</Typography>}
|
|
@@ -189,5 +192,3 @@ Toast.propTypes = {
|
|
|
189
192
|
linkRouterProps: withLinkRouter.propTypes?.linkRouterProps
|
|
190
193
|
})
|
|
191
194
|
}
|
|
192
|
-
|
|
193
|
-
export default Toast
|
|
@@ -9,31 +9,31 @@ import {
|
|
|
9
9
|
} from '@telus-uds/components-base'
|
|
10
10
|
|
|
11
11
|
import styled from 'styled-components'
|
|
12
|
-
import VideoProgressBar from './Controls/VideoProgressBar/VideoProgressBar'
|
|
13
|
-
import VolumeSlider from './Controls/VolumeSlider/VolumeSlider'
|
|
14
|
-
import VideoButton from './Controls/VideoButton/VideoButton'
|
|
15
|
-
import VideoMenu from './Controls/VideoMenu/VideoMenu'
|
|
16
|
-
import videoText from '../videoText'
|
|
12
|
+
import { VideoProgressBar } from './Controls/VideoProgressBar/VideoProgressBar'
|
|
13
|
+
import { VolumeSlider } from './Controls/VolumeSlider/VolumeSlider'
|
|
14
|
+
import { VideoButton } from './Controls/VideoButton/VideoButton'
|
|
15
|
+
import { VideoMenu } from './Controls/VideoMenu/VideoMenu'
|
|
16
|
+
import { videoText } from '../videoText'
|
|
17
17
|
import { htmlAttrs } from '../../utils'
|
|
18
18
|
|
|
19
19
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([htmlAttrs])
|
|
20
20
|
|
|
21
21
|
const getIcon = (icon) => <Icon icon={icon} />
|
|
22
22
|
|
|
23
|
-
const ControlBarContainer = styled.div(({ isHidden, isMobile }) => ({
|
|
23
|
+
const ControlBarContainer = styled.div(({ $isHidden, $isMobile }) => ({
|
|
24
24
|
width: '100%',
|
|
25
25
|
position: 'relative',
|
|
26
26
|
transition: 'opacity 0.4s',
|
|
27
|
-
opacity: isHidden ? 0 : 1,
|
|
28
|
-
display: isMobile ? 'none' : undefined
|
|
27
|
+
opacity: $isHidden ? 0 : 1,
|
|
28
|
+
display: $isMobile ? 'none' : undefined
|
|
29
29
|
}))
|
|
30
30
|
|
|
31
|
-
const StyledControlBar = styled.div(({ padding, height }) => ({
|
|
31
|
+
const StyledControlBar = styled.div(({ $padding, $height }) => ({
|
|
32
32
|
boxSizing: 'border-box',
|
|
33
33
|
position: 'absolute',
|
|
34
34
|
width: '100%',
|
|
35
|
-
height,
|
|
36
|
-
padding,
|
|
35
|
+
height: $height,
|
|
36
|
+
padding: $padding,
|
|
37
37
|
bottom: 0,
|
|
38
38
|
backgroundColor: 'rgba(42, 44, 46, 0.85)', // TODO: replace with opaque greyThunder
|
|
39
39
|
margin: 'auto',
|
|
@@ -47,15 +47,15 @@ const VideoProgressBarContainer = styled.div({
|
|
|
47
47
|
flexGrow: 1
|
|
48
48
|
})
|
|
49
49
|
|
|
50
|
-
const MenuContainer = styled.div(({ isOpen, menuBottom, menuRight, menuMarginLeft }) => ({
|
|
50
|
+
const MenuContainer = styled.div(({ $isOpen, $menuBottom, $menuRight, $menuMarginLeft }) => ({
|
|
51
51
|
position: 'absolute',
|
|
52
|
-
bottom: menuBottom,
|
|
53
|
-
right: menuRight,
|
|
54
|
-
display: isOpen ? 'block' : 'none',
|
|
55
|
-
marginLeft: menuMarginLeft
|
|
52
|
+
bottom: $menuBottom,
|
|
53
|
+
right: $menuRight,
|
|
54
|
+
display: $isOpen ? 'block' : 'none',
|
|
55
|
+
marginLeft: $menuMarginLeft
|
|
56
56
|
}))
|
|
57
57
|
|
|
58
|
-
const ControlBar = ({
|
|
58
|
+
export const ControlBar = ({
|
|
59
59
|
videoPlayer,
|
|
60
60
|
videoPlayerContainer,
|
|
61
61
|
sources,
|
|
@@ -126,13 +126,18 @@ const ControlBar = ({
|
|
|
126
126
|
return parsed
|
|
127
127
|
}
|
|
128
128
|
|
|
129
|
-
const menuContainerStyleProps = {
|
|
129
|
+
const menuContainerStyleProps = {
|
|
130
|
+
$isOpen: false,
|
|
131
|
+
$menuBottom: menuBottom,
|
|
132
|
+
$menuRight: menuRight,
|
|
133
|
+
$menuMarginLeft: menuMarginLeft
|
|
134
|
+
}
|
|
130
135
|
|
|
131
136
|
return (
|
|
132
|
-
<ControlBarContainer isHidden={isHidden} isMobile={isMobile} {...selectProps(rest)}>
|
|
137
|
+
<ControlBarContainer $isHidden={isHidden} $isMobile={isMobile} {...selectProps(rest)}>
|
|
133
138
|
<StyledControlBar
|
|
134
|
-
padding={`${paddingTop}px ${paddingRight}px ${paddingBottom}px ${paddingLeft}px`}
|
|
135
|
-
height={`${height}px`}
|
|
139
|
+
$padding={`${paddingTop}px ${paddingRight}px ${paddingBottom}px ${paddingLeft}px`}
|
|
140
|
+
$height={`${height}px`}
|
|
136
141
|
>
|
|
137
142
|
<VideoProgressBarContainer>
|
|
138
143
|
<VideoProgressBar
|
|
@@ -197,7 +202,7 @@ const ControlBar = ({
|
|
|
197
202
|
/>
|
|
198
203
|
</StackView>
|
|
199
204
|
{captionsMenuOpen && (
|
|
200
|
-
<MenuContainer isOpen={captionsMenuOpen}
|
|
205
|
+
<MenuContainer {...menuContainerStyleProps} $isOpen={captionsMenuOpen}>
|
|
201
206
|
<VideoMenu
|
|
202
207
|
menuLabel={videoText[copy].captionsDialogue}
|
|
203
208
|
menuOptions={parseTracks()}
|
|
@@ -208,7 +213,7 @@ const ControlBar = ({
|
|
|
208
213
|
</MenuContainer>
|
|
209
214
|
)}
|
|
210
215
|
{qualityMenuOpen && (
|
|
211
|
-
<MenuContainer isOpen={qualityMenuOpen}
|
|
216
|
+
<MenuContainer {...menuContainerStyleProps} $isOpen={qualityMenuOpen}>
|
|
212
217
|
<VideoMenu
|
|
213
218
|
menuLabel={videoText[copy].qualityDialogue}
|
|
214
219
|
menuOptions={parseVideoQuality()}
|
|
@@ -259,5 +264,3 @@ ControlBar.propTypes = {
|
|
|
259
264
|
compactModeThreshold: PropTypes.number.isRequired,
|
|
260
265
|
videoPlayerWidth: PropTypes.number.isRequired
|
|
261
266
|
}
|
|
262
|
-
|
|
263
|
-
export default ControlBar
|
|
@@ -6,7 +6,7 @@ import { htmlAttrs } from '../../../../utils'
|
|
|
6
6
|
|
|
7
7
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([htmlAttrs])
|
|
8
8
|
|
|
9
|
-
const StyledButton = styled.button(({ color }) => ({
|
|
9
|
+
const StyledButton = styled.button(({ $color }) => ({
|
|
10
10
|
background: 'none',
|
|
11
11
|
border: 'none',
|
|
12
12
|
padding: 0,
|
|
@@ -14,11 +14,11 @@ const StyledButton = styled.button(({ color }) => ({
|
|
|
14
14
|
display: 'inline-flex',
|
|
15
15
|
alignItems: 'stretch',
|
|
16
16
|
'svg path': {
|
|
17
|
-
fill: color
|
|
17
|
+
fill: $color
|
|
18
18
|
}
|
|
19
19
|
}))
|
|
20
20
|
|
|
21
|
-
const VideoButton = ({ icon, label, disableFocus, children, tokens, variant, ...rest }) => {
|
|
21
|
+
export const VideoButton = ({ icon, label, disableFocus, children, tokens, variant, ...rest }) => {
|
|
22
22
|
const { color } = useThemeTokens('VideoButton', tokens, variant)
|
|
23
23
|
|
|
24
24
|
const handleOnKeyDown = (event) => {
|
|
@@ -39,7 +39,7 @@ const VideoButton = ({ icon, label, disableFocus, children, tokens, variant, ...
|
|
|
39
39
|
aria-label={label}
|
|
40
40
|
onKeyDown={handleOnKeyDown}
|
|
41
41
|
tabIndex={disableFocus ? '-1' : undefined}
|
|
42
|
-
color={color}
|
|
42
|
+
$color={color}
|
|
43
43
|
{...selectProps(rest)}
|
|
44
44
|
onClick={handleClick}
|
|
45
45
|
>
|
|
@@ -56,5 +56,3 @@ VideoButton.propTypes = {
|
|
|
56
56
|
disableFocus: PropTypes.bool.isRequired,
|
|
57
57
|
children: PropTypes.node
|
|
58
58
|
}
|
|
59
|
-
|
|
60
|
-
export default VideoButton
|
|
@@ -8,15 +8,15 @@ import {
|
|
|
8
8
|
Icon
|
|
9
9
|
} from '@telus-uds/components-base'
|
|
10
10
|
import styled from 'styled-components'
|
|
11
|
-
import videoText from '../../../videoText'
|
|
11
|
+
import { videoText } from '../../../videoText'
|
|
12
12
|
import { htmlAttrs } from '../../../../utils'
|
|
13
13
|
|
|
14
14
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([htmlAttrs])
|
|
15
15
|
|
|
16
|
-
const MenuContainer = styled.div(({ padding, background }) => ({
|
|
16
|
+
const MenuContainer = styled.div(({ $padding, $background }) => ({
|
|
17
17
|
width: 114,
|
|
18
|
-
padding,
|
|
19
|
-
backgroundColor: background,
|
|
18
|
+
padding: $padding,
|
|
19
|
+
backgroundColor: $background,
|
|
20
20
|
borderRadius: 5
|
|
21
21
|
}))
|
|
22
22
|
|
|
@@ -34,32 +34,32 @@ const MenuButton = styled.button({
|
|
|
34
34
|
|
|
35
35
|
const CheckmarkContainer = styled.div(
|
|
36
36
|
({
|
|
37
|
-
isSelectedItem,
|
|
38
|
-
checkMarkWidth,
|
|
39
|
-
checkMarkHeight,
|
|
40
|
-
checkMarkSelectedColor,
|
|
41
|
-
checkMarkHoverColor,
|
|
42
|
-
checkMarkFocusColor,
|
|
43
|
-
checkMarkUnselectedColor
|
|
37
|
+
$isSelectedItem,
|
|
38
|
+
$checkMarkWidth,
|
|
39
|
+
$checkMarkHeight,
|
|
40
|
+
$checkMarkSelectedColor,
|
|
41
|
+
$checkMarkHoverColor,
|
|
42
|
+
$checkMarkFocusColor,
|
|
43
|
+
$checkMarkUnselectedColor
|
|
44
44
|
}) => ({
|
|
45
|
-
width: checkMarkWidth,
|
|
46
|
-
height: checkMarkHeight,
|
|
45
|
+
width: $checkMarkWidth,
|
|
46
|
+
height: $checkMarkHeight,
|
|
47
47
|
marginTop: 2,
|
|
48
48
|
outline: 'none',
|
|
49
49
|
|
|
50
50
|
[`${MenuButton} && svg`]: {
|
|
51
|
-
fill: isSelectedItem ? checkMarkSelectedColor : checkMarkUnselectedColor
|
|
51
|
+
fill: $isSelectedItem ? $checkMarkSelectedColor : $checkMarkUnselectedColor
|
|
52
52
|
},
|
|
53
53
|
[`${MenuButton}:hover && svg`]: {
|
|
54
|
-
fill: isSelectedItem ? checkMarkSelectedColor : checkMarkHoverColor
|
|
54
|
+
fill: $isSelectedItem ? $checkMarkSelectedColor : $checkMarkHoverColor
|
|
55
55
|
},
|
|
56
56
|
[`${MenuButton}:focus && svg`]: {
|
|
57
|
-
fill: isSelectedItem ? checkMarkSelectedColor : checkMarkFocusColor
|
|
57
|
+
fill: $isSelectedItem ? $checkMarkSelectedColor : $checkMarkFocusColor
|
|
58
58
|
}
|
|
59
59
|
})
|
|
60
60
|
)
|
|
61
61
|
|
|
62
|
-
const VideoMenu = ({
|
|
62
|
+
export const VideoMenu = ({
|
|
63
63
|
menuLabel,
|
|
64
64
|
menuOptions,
|
|
65
65
|
setSelection,
|
|
@@ -93,8 +93,6 @@ const VideoMenu = ({
|
|
|
93
93
|
? videoText[copy].itemSelected
|
|
94
94
|
: videoText[copy].itemUnselected
|
|
95
95
|
}`}
|
|
96
|
-
selectedItem={selectedItem}
|
|
97
|
-
itemValue={option.value}
|
|
98
96
|
onClick={() => {
|
|
99
97
|
if (selectedItem !== option.value) {
|
|
100
98
|
setSelection(option.value)
|
|
@@ -104,13 +102,13 @@ const VideoMenu = ({
|
|
|
104
102
|
>
|
|
105
103
|
<Typography variant={{ bold: true, inverse: true }}>{option.name}</Typography>
|
|
106
104
|
<CheckmarkContainer
|
|
107
|
-
isSelectedItem={option.value === selectedItem}
|
|
108
|
-
checkMarkWidth={checkMarkWidth}
|
|
109
|
-
checkMarkHeight={checkMarkHeight}
|
|
110
|
-
checkMarkSelectedColor={checkMarkSelectedColor}
|
|
111
|
-
checkMarkHoverColor={checkMarkHoverColor}
|
|
112
|
-
checkMarkFocusColor={checkMarkFocusColor}
|
|
113
|
-
checkMarkUnselectedColor={checkMarkUnselectedColor}
|
|
105
|
+
$isSelectedItem={option.value === selectedItem}
|
|
106
|
+
$checkMarkWidth={checkMarkWidth}
|
|
107
|
+
$checkMarkHeight={checkMarkHeight}
|
|
108
|
+
$checkMarkSelectedColor={checkMarkSelectedColor}
|
|
109
|
+
$checkMarkHoverColor={checkMarkHoverColor}
|
|
110
|
+
$checkMarkFocusColor={checkMarkFocusColor}
|
|
111
|
+
$checkMarkUnselectedColor={checkMarkUnselectedColor}
|
|
114
112
|
>
|
|
115
113
|
<Icon icon={checkMarkIcon} />
|
|
116
114
|
</CheckmarkContainer>
|
|
@@ -133,8 +131,8 @@ const VideoMenu = ({
|
|
|
133
131
|
return (
|
|
134
132
|
<MenuContainer
|
|
135
133
|
onKeyDown={handleOnKeyDown}
|
|
136
|
-
padding={padding}
|
|
137
|
-
background={background}
|
|
134
|
+
$padding={padding}
|
|
135
|
+
$background={background}
|
|
138
136
|
{...selectProps(rest)}
|
|
139
137
|
>
|
|
140
138
|
<StackView space={2} divider>
|
|
@@ -153,5 +151,3 @@ VideoMenu.propTypes = {
|
|
|
153
151
|
selectedItem: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired,
|
|
154
152
|
copy: PropTypes.oneOf(['en', 'fr']).isRequired
|
|
155
153
|
}
|
|
156
|
-
|
|
157
|
-
export default VideoMenu
|