@fluentui/react-teaching-popover 0.0.0-nightly-20240423-0406.1
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/CHANGELOG.md +324 -0
- package/LICENSE +15 -0
- package/README.md +66 -0
- package/dist/index.d.ts +715 -0
- package/lib/TeachingPopover.js +1 -0
- package/lib/TeachingPopover.js.map +1 -0
- package/lib/TeachingPopoverBody.js +1 -0
- package/lib/TeachingPopoverBody.js.map +1 -0
- package/lib/TeachingPopoverCarousel.js +1 -0
- package/lib/TeachingPopoverCarousel.js.map +1 -0
- package/lib/TeachingPopoverCarouselCard.js +1 -0
- package/lib/TeachingPopoverCarouselCard.js.map +1 -0
- package/lib/TeachingPopoverCarouselFooter.js +1 -0
- package/lib/TeachingPopoverCarouselFooter.js.map +1 -0
- package/lib/TeachingPopoverCarouselFooterButton.js +1 -0
- package/lib/TeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib/TeachingPopoverCarouselNav.js +1 -0
- package/lib/TeachingPopoverCarouselNav.js.map +1 -0
- package/lib/TeachingPopoverCarouselNavButton.js +1 -0
- package/lib/TeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib/TeachingPopoverCarouselPageCount.js +1 -0
- package/lib/TeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib/TeachingPopoverFooter.js +1 -0
- package/lib/TeachingPopoverFooter.js.map +1 -0
- package/lib/TeachingPopoverHeader.js +1 -0
- package/lib/TeachingPopoverHeader.js.map +1 -0
- package/lib/TeachingPopoverSurface.js +1 -0
- package/lib/TeachingPopoverSurface.js.map +1 -0
- package/lib/TeachingPopoverTitle.js +1 -0
- package/lib/TeachingPopoverTitle.js.map +1 -0
- package/lib/TeachingPopoverTrigger.js +1 -0
- package/lib/TeachingPopoverTrigger.js.map +1 -0
- package/lib/components/TeachingPopover/TeachingPopover.js +10 -0
- package/lib/components/TeachingPopover/TeachingPopover.js.map +1 -0
- package/lib/components/TeachingPopover/TeachingPopover.types.js +1 -0
- package/lib/components/TeachingPopover/TeachingPopover.types.js.map +1 -0
- package/lib/components/TeachingPopover/index.js +4 -0
- package/lib/components/TeachingPopover/index.js.map +1 -0
- package/lib/components/TeachingPopover/renderTeachingPopover.js +4 -0
- package/lib/components/TeachingPopover/renderTeachingPopover.js.map +1 -0
- package/lib/components/TeachingPopover/useTeachingPopover.js +11 -0
- package/lib/components/TeachingPopover/useTeachingPopover.js.map +1 -0
- package/lib/components/TeachingPopoverBody/TeachingPopoverBody.js +17 -0
- package/lib/components/TeachingPopoverBody/TeachingPopoverBody.js.map +1 -0
- package/lib/components/TeachingPopoverBody/TeachingPopoverBody.types.js +1 -0
- package/lib/components/TeachingPopoverBody/TeachingPopoverBody.types.js.map +1 -0
- package/lib/components/TeachingPopoverBody/index.js +5 -0
- package/lib/components/TeachingPopoverBody/index.js.map +1 -0
- package/lib/components/TeachingPopoverBody/renderTeachingPopoverBody.js +13 -0
- package/lib/components/TeachingPopoverBody/renderTeachingPopoverBody.js.map +1 -0
- package/lib/components/TeachingPopoverBody/useTeachingPopoverBody.js +25 -0
- package/lib/components/TeachingPopoverBody/useTeachingPopoverBody.js.map +1 -0
- package/lib/components/TeachingPopoverBody/useTeachingPopoverBodyStyles.styles.js +58 -0
- package/lib/components/TeachingPopoverBody/useTeachingPopoverBodyStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/Carousel.js +123 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/Carousel.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/Carousel.types.js +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/Carousel.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselContext.js +14 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselContext.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types.js +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem.js +11 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/renderCarouselItem.js +8 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/renderCarouselItem.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/useCarouselItem.js +28 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/CarouselItem/useCarouselItem.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/constants.js +2 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/constants.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/createCarouselStore.js +60 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/createCarouselStore.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/useCarouselValues.js +6 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/useCarouselValues.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/useCarouselWalker.js +98 -0
- package/lib/components/TeachingPopoverCarousel/Carousel/useCarouselWalker.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/TeachingPopoverCarousel.js +19 -0
- package/lib/components/TeachingPopoverCarousel/TeachingPopoverCarousel.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/TeachingPopoverCarousel.types.js +1 -0
- package/lib/components/TeachingPopoverCarousel/TeachingPopoverCarousel.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/index.js +6 -0
- package/lib/components/TeachingPopoverCarousel/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/renderTeachingPopoverCarousel.js +12 -0
- package/lib/components/TeachingPopoverCarousel/renderTeachingPopoverCarousel.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarousel.js +32 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarousel.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarouselContextValues.js +12 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarouselContextValues.js.map +1 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarouselStyles.styles.js +15 -0
- package/lib/components/TeachingPopoverCarousel/useTeachingPopoverCarouselStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.js +15 -0
- package/lib/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselCard/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/renderTeachingPopoverCarouselCard.js +8 -0
- package/lib/components/TeachingPopoverCarouselCard/renderTeachingPopoverCarouselCard.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCard.js +25 -0
- package/lib/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCard.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCardStyles.styles.js +14 -0
- package/lib/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCardStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.js +15 -0
- package/lib/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselFooter/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/renderTeachingPopoverCarouselFooter.js +16 -0
- package/lib/components/TeachingPopoverCarouselFooter/renderTeachingPopoverCarouselFooter.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooter.js +37 -0
- package/lib/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooter.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooterStyles.styles.js +39 -0
- package/lib/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooterStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.js +15 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/renderTeachingPopoverCarouselFooterButton.js +8 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/renderTeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButton.js +71 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButtonStyles.styles.js +64 -0
- package/lib/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButtonStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.js +15 -0
- package/lib/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselNav/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/renderTeachingPopoverCarouselNav.js +15 -0
- package/lib/components/TeachingPopoverCarouselNav/renderTeachingPopoverCarouselNav.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNav.js +35 -0
- package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNav.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js +35 -0
- package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNav/valueIdContext.js +8 -0
- package/lib/components/TeachingPopoverCarouselNav/valueIdContext.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.js +14 -0
- package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselNavButton/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/renderTeachingPopoverCarouselNavButton.js +8 -0
- package/lib/components/TeachingPopoverCarouselNavButton/renderTeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js +52 -0
- package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButtonStyles.styles.js +104 -0
- package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButtonStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.js +14 -0
- package/lib/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.types.js +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.types.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/index.js +5 -0
- package/lib/components/TeachingPopoverCarouselPageCount/index.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/renderTeachingPopoverCarouselPageCount.js +8 -0
- package/lib/components/TeachingPopoverCarouselPageCount/renderTeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCount.js +34 -0
- package/lib/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCountStyles.styles.js +25 -0
- package/lib/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCountStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/TeachingPopoverFooter.js +18 -0
- package/lib/components/TeachingPopoverFooter/TeachingPopoverFooter.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/TeachingPopoverFooter.types.js +1 -0
- package/lib/components/TeachingPopoverFooter/TeachingPopoverFooter.types.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/index.js +5 -0
- package/lib/components/TeachingPopoverFooter/index.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/renderTeachingPopoverFooter.js +13 -0
- package/lib/components/TeachingPopoverFooter/renderTeachingPopoverFooter.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/useTeachingPopoverFooter.js +57 -0
- package/lib/components/TeachingPopoverFooter/useTeachingPopoverFooter.js.map +1 -0
- package/lib/components/TeachingPopoverFooter/useTeachingPopoverFooterStyles.styles.js +68 -0
- package/lib/components/TeachingPopoverFooter/useTeachingPopoverFooterStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/TeachingPopoverHeader.js +18 -0
- package/lib/components/TeachingPopoverHeader/TeachingPopoverHeader.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/TeachingPopoverHeader.types.js +1 -0
- package/lib/components/TeachingPopoverHeader/TeachingPopoverHeader.types.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/index.js +5 -0
- package/lib/components/TeachingPopoverHeader/index.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/renderTeachingPopoverHeader.js +14 -0
- package/lib/components/TeachingPopoverHeader/renderTeachingPopoverHeader.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/useTeachingPopoverHeader.js +54 -0
- package/lib/components/TeachingPopoverHeader/useTeachingPopoverHeader.js.map +1 -0
- package/lib/components/TeachingPopoverHeader/useTeachingPopoverHeaderStyles.styles.js +108 -0
- package/lib/components/TeachingPopoverHeader/useTeachingPopoverHeaderStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/TeachingPopoverSurface.js +16 -0
- package/lib/components/TeachingPopoverSurface/TeachingPopoverSurface.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/TeachingPopoverSurface.types.js +1 -0
- package/lib/components/TeachingPopoverSurface/TeachingPopoverSurface.types.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/index.js +5 -0
- package/lib/components/TeachingPopoverSurface/index.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/renderTeachingPopoverSurface.js +9 -0
- package/lib/components/TeachingPopoverSurface/renderTeachingPopoverSurface.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/useTeachingPopoverSurface.js +14 -0
- package/lib/components/TeachingPopoverSurface/useTeachingPopoverSurface.js.map +1 -0
- package/lib/components/TeachingPopoverSurface/useTeachingPopoverSurfaceStyles.styles.js +37 -0
- package/lib/components/TeachingPopoverSurface/useTeachingPopoverSurfaceStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/TeachingPopoverTitle.js +18 -0
- package/lib/components/TeachingPopoverTitle/TeachingPopoverTitle.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/TeachingPopoverTitle.types.js +1 -0
- package/lib/components/TeachingPopoverTitle/TeachingPopoverTitle.types.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/index.js +5 -0
- package/lib/components/TeachingPopoverTitle/index.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/renderTeachingPopoverTitle.js +13 -0
- package/lib/components/TeachingPopoverTitle/renderTeachingPopoverTitle.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/useTeachingPopoverTitle.js +46 -0
- package/lib/components/TeachingPopoverTitle/useTeachingPopoverTitle.js.map +1 -0
- package/lib/components/TeachingPopoverTitle/useTeachingPopoverTitleStyles.styles.js +80 -0
- package/lib/components/TeachingPopoverTitle/useTeachingPopoverTitleStyles.styles.js.map +1 -0
- package/lib/components/TeachingPopoverTrigger/TeachingPopoverTrigger.js +12 -0
- package/lib/components/TeachingPopoverTrigger/TeachingPopoverTrigger.js.map +1 -0
- package/lib/components/TeachingPopoverTrigger/TeachingPopoverTrigger.types.js +1 -0
- package/lib/components/TeachingPopoverTrigger/TeachingPopoverTrigger.types.js.map +1 -0
- package/lib/components/TeachingPopoverTrigger/index.js +4 -0
- package/lib/components/TeachingPopoverTrigger/index.js.map +1 -0
- package/lib/components/TeachingPopoverTrigger/renderTeachingPopoverTrigger.js +5 -0
- package/lib/components/TeachingPopoverTrigger/renderTeachingPopoverTrigger.js.map +1 -0
- package/lib/components/TeachingPopoverTrigger/useTeachingPopoverTrigger.js +9 -0
- package/lib/components/TeachingPopoverTrigger/useTeachingPopoverTrigger.js.map +1 -0
- package/lib/index.js +14 -0
- package/lib/index.js.map +1 -0
- package/lib-commonjs/TeachingPopover.js +6 -0
- package/lib-commonjs/TeachingPopover.js.map +1 -0
- package/lib-commonjs/TeachingPopoverBody.js +6 -0
- package/lib-commonjs/TeachingPopoverBody.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarousel.js +6 -0
- package/lib-commonjs/TeachingPopoverCarousel.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselCard.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselCard.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselFooter.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselFooter.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselFooterButton.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselNav.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselNav.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselNavButton.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib-commonjs/TeachingPopoverCarouselPageCount.js +6 -0
- package/lib-commonjs/TeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib-commonjs/TeachingPopoverFooter.js +6 -0
- package/lib-commonjs/TeachingPopoverFooter.js.map +1 -0
- package/lib-commonjs/TeachingPopoverHeader.js +6 -0
- package/lib-commonjs/TeachingPopoverHeader.js.map +1 -0
- package/lib-commonjs/TeachingPopoverSurface.js +6 -0
- package/lib-commonjs/TeachingPopoverSurface.js.map +1 -0
- package/lib-commonjs/TeachingPopoverTitle.js +6 -0
- package/lib-commonjs/TeachingPopoverTitle.js.map +1 -0
- package/lib-commonjs/TeachingPopoverTrigger.js +6 -0
- package/lib-commonjs/TeachingPopoverTrigger.js.map +1 -0
- package/lib-commonjs/components/TeachingPopover/TeachingPopover.js +19 -0
- package/lib-commonjs/components/TeachingPopover/TeachingPopover.js.map +1 -0
- package/lib-commonjs/components/TeachingPopover/TeachingPopover.types.js +4 -0
- package/lib-commonjs/components/TeachingPopover/TeachingPopover.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopover/index.js +9 -0
- package/lib-commonjs/components/TeachingPopover/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopover/renderTeachingPopover.js +12 -0
- package/lib-commonjs/components/TeachingPopover/renderTeachingPopover.js.map +1 -0
- package/lib-commonjs/components/TeachingPopover/useTeachingPopover.js +21 -0
- package/lib-commonjs/components/TeachingPopover/useTeachingPopover.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/TeachingPopoverBody.js +23 -0
- package/lib-commonjs/components/TeachingPopoverBody/TeachingPopoverBody.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/TeachingPopoverBody.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverBody/TeachingPopoverBody.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverBody/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/renderTeachingPopoverBody.js +21 -0
- package/lib-commonjs/components/TeachingPopoverBody/renderTeachingPopoverBody.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/useTeachingPopoverBody.js +32 -0
- package/lib-commonjs/components/TeachingPopoverBody/useTeachingPopoverBody.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverBody/useTeachingPopoverBodyStyles.styles.js +98 -0
- package/lib-commonjs/components/TeachingPopoverBody/useTeachingPopoverBodyStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/Carousel.js +132 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/Carousel.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/Carousel.types.js +6 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/Carousel.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselContext.js +36 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselContext.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem.js +19 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/renderCarouselItem.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/renderCarouselItem.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/useCarouselItem.js +39 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/CarouselItem/useCarouselItem.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/constants.js +20 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/constants.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/createCarouselStore.js +70 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/createCarouselStore.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/useCarouselValues.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/useCarouselValues.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/useCarouselWalker.js +109 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/Carousel/useCarouselWalker.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/TeachingPopoverCarousel.js +25 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/TeachingPopoverCarousel.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/TeachingPopoverCarousel.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/TeachingPopoverCarousel.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/index.js +11 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/renderTeachingPopoverCarousel.js +20 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/renderTeachingPopoverCarousel.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarousel.js +43 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarousel.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarouselContextValues.js +22 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarouselContextValues.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarouselStyles.styles.js +31 -0
- package/lib-commonjs/components/TeachingPopoverCarousel/useTeachingPopoverCarouselStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/renderTeachingPopoverCarouselCard.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/renderTeachingPopoverCarouselCard.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCard.js +32 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCard.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCardStyles.styles.js +30 -0
- package/lib-commonjs/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCardStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.types.js +6 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/renderTeachingPopoverCarouselFooter.js +24 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/renderTeachingPopoverCarouselFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooter.js +48 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooterStyles.styles.js +60 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooterStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/renderTeachingPopoverCarouselFooterButton.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/renderTeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButton.js +73 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButtonStyles.styles.js +129 -0
- package/lib-commonjs/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButtonStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.types.js +6 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/renderTeachingPopoverCarouselNav.js +23 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/renderTeachingPopoverCarouselNav.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNav.js +42 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNav.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js +84 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/valueIdContext.js +30 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNav/valueIdContext.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/renderTeachingPopoverCarouselNavButton.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/renderTeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js +55 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButtonStyles.styles.js +240 -0
- package/lib-commonjs/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButtonStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.js +21 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.types.js +6 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/TeachingPopoverCarouselPageCount.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/renderTeachingPopoverCarouselPageCount.js +16 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/renderTeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCount.js +37 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCount.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCountStyles.styles.js +42 -0
- package/lib-commonjs/components/TeachingPopoverCarouselPageCount/useTeachingPopoverCarouselPageCountStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/TeachingPopoverFooter.js +21 -0
- package/lib-commonjs/components/TeachingPopoverFooter/TeachingPopoverFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/TeachingPopoverFooter.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverFooter/TeachingPopoverFooter.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverFooter/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/renderTeachingPopoverFooter.js +21 -0
- package/lib-commonjs/components/TeachingPopoverFooter/renderTeachingPopoverFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/useTeachingPopoverFooter.js +64 -0
- package/lib-commonjs/components/TeachingPopoverFooter/useTeachingPopoverFooter.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverFooter/useTeachingPopoverFooterStyles.styles.js +135 -0
- package/lib-commonjs/components/TeachingPopoverFooter/useTeachingPopoverFooterStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/TeachingPopoverHeader.js +23 -0
- package/lib-commonjs/components/TeachingPopoverHeader/TeachingPopoverHeader.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/TeachingPopoverHeader.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverHeader/TeachingPopoverHeader.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverHeader/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/renderTeachingPopoverHeader.js +22 -0
- package/lib-commonjs/components/TeachingPopoverHeader/renderTeachingPopoverHeader.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/useTeachingPopoverHeader.js +61 -0
- package/lib-commonjs/components/TeachingPopoverHeader/useTeachingPopoverHeader.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverHeader/useTeachingPopoverHeaderStyles.styles.js +230 -0
- package/lib-commonjs/components/TeachingPopoverHeader/useTeachingPopoverHeaderStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/TeachingPopoverSurface.js +23 -0
- package/lib-commonjs/components/TeachingPopoverSurface/TeachingPopoverSurface.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/TeachingPopoverSurface.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverSurface/TeachingPopoverSurface.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverSurface/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/renderTeachingPopoverSurface.js +17 -0
- package/lib-commonjs/components/TeachingPopoverSurface/renderTeachingPopoverSurface.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/useTeachingPopoverSurface.js +17 -0
- package/lib-commonjs/components/TeachingPopoverSurface/useTeachingPopoverSurface.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverSurface/useTeachingPopoverSurfaceStyles.styles.js +89 -0
- package/lib-commonjs/components/TeachingPopoverSurface/useTeachingPopoverSurfaceStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/TeachingPopoverTitle.js +23 -0
- package/lib-commonjs/components/TeachingPopoverTitle/TeachingPopoverTitle.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/TeachingPopoverTitle.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverTitle/TeachingPopoverTitle.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/index.js +10 -0
- package/lib-commonjs/components/TeachingPopoverTitle/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/renderTeachingPopoverTitle.js +21 -0
- package/lib-commonjs/components/TeachingPopoverTitle/renderTeachingPopoverTitle.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/useTeachingPopoverTitle.js +53 -0
- package/lib-commonjs/components/TeachingPopoverTitle/useTeachingPopoverTitle.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTitle/useTeachingPopoverTitleStyles.styles.js +185 -0
- package/lib-commonjs/components/TeachingPopoverTitle/useTeachingPopoverTitleStyles.styles.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/TeachingPopoverTrigger.js +21 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/TeachingPopoverTrigger.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/TeachingPopoverTrigger.types.js +4 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/TeachingPopoverTrigger.types.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/index.js +9 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/index.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/renderTeachingPopoverTrigger.js +15 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/renderTeachingPopoverTrigger.js.map +1 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/useTeachingPopoverTrigger.js +15 -0
- package/lib-commonjs/components/TeachingPopoverTrigger/useTeachingPopoverTrigger.js.map +1 -0
- package/lib-commonjs/index.js +224 -0
- package/lib-commonjs/index.js.map +1 -0
- package/package.json +69 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { __styles, mergeClasses, shorthands } from '@griffel/react';
|
|
2
|
+
export const teachingPopoverCarouselFooterClassNames = {
|
|
3
|
+
root: 'fui-TeachingPopoverCarouselFooter',
|
|
4
|
+
previous: 'fui-TeachingPopoverCarouselFooter__previous',
|
|
5
|
+
next: 'fui-TeachingPopoverCarouselFooter__next'
|
|
6
|
+
};
|
|
7
|
+
// Todo: Page change animation & styles
|
|
8
|
+
const useStyles = /*#__PURE__*/__styles({
|
|
9
|
+
root: {
|
|
10
|
+
mc9l5x: "f22iagw",
|
|
11
|
+
Beiy3e4: "f1063pyq"
|
|
12
|
+
},
|
|
13
|
+
rootCentered: {
|
|
14
|
+
Brf1p80: "f1869bpl",
|
|
15
|
+
i8kkvl: "f4px1ci",
|
|
16
|
+
Belr9w4: "fn67r4l"
|
|
17
|
+
},
|
|
18
|
+
rootRightAligned: {
|
|
19
|
+
i8kkvl: "f4px1ci",
|
|
20
|
+
Belr9w4: "fn67r4l",
|
|
21
|
+
Bp34fd5: "f1y65ohq"
|
|
22
|
+
}
|
|
23
|
+
}, {
|
|
24
|
+
d: [".f22iagw{display:flex;}", ".f1063pyq{flex-direction:row;}", ".f1869bpl{justify-content:space-between;}", ".f4px1ci{column-gap:8px;}", ".fn67r4l{row-gap:8px;}", ".f1y65ohq :first-child{-webkit-margin-end:auto;margin-inline-end:auto;}"]
|
|
25
|
+
});
|
|
26
|
+
/** Applies style classnames to slots */
|
|
27
|
+
export const useTeachingPopoverCarouselFooterStyles_unstable = state => {
|
|
28
|
+
const styles = useStyles();
|
|
29
|
+
const {
|
|
30
|
+
layout
|
|
31
|
+
} = state;
|
|
32
|
+
state.root.className = mergeClasses(teachingPopoverCarouselFooterClassNames.root, styles.root, layout === 'centered' ? styles.rootCentered : styles.rootRightAligned, state.root.className);
|
|
33
|
+
if (state.previous) {
|
|
34
|
+
state.previous.className = mergeClasses(teachingPopoverCarouselFooterClassNames.previous, state.previous.className);
|
|
35
|
+
}
|
|
36
|
+
state.next.className = mergeClasses(teachingPopoverCarouselFooterClassNames.next, state.next.className);
|
|
37
|
+
return state;
|
|
38
|
+
};
|
|
39
|
+
//# sourceMappingURL=useTeachingPopoverCarouselFooterStyles.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["__styles","mergeClasses","shorthands","teachingPopoverCarouselFooterClassNames","root","previous","next","useStyles","mc9l5x","Beiy3e4","rootCentered","Brf1p80","i8kkvl","Belr9w4","rootRightAligned","Bp34fd5","d","useTeachingPopoverCarouselFooterStyles_unstable","state","styles","layout","className"],"sources":["useTeachingPopoverCarouselFooterStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nexport const teachingPopoverCarouselFooterClassNames = {\n root: 'fui-TeachingPopoverCarouselFooter',\n previous: 'fui-TeachingPopoverCarouselFooter__previous',\n next: 'fui-TeachingPopoverCarouselFooter__next'\n};\n// Todo: Page change animation & styles\nconst useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'row'\n },\n rootCentered: {\n justifyContent: 'space-between',\n ...shorthands.gap('8px')\n },\n rootRightAligned: {\n ...shorthands.gap('8px'),\n '& :first-child': {\n marginInlineEnd: 'auto'\n }\n }\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverCarouselFooterStyles_unstable = (state)=>{\n const styles = useStyles();\n const { layout } = state;\n state.root.className = mergeClasses(teachingPopoverCarouselFooterClassNames.root, styles.root, layout === 'centered' ? styles.rootCentered : styles.rootRightAligned, state.root.className);\n if (state.previous) {\n state.previous.className = mergeClasses(teachingPopoverCarouselFooterClassNames.previous, state.previous.className);\n }\n state.next.className = mergeClasses(teachingPopoverCarouselFooterClassNames.next, state.next.className);\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,OAAO,MAAMC,uCAAuC,GAAG;EACnDC,IAAI,EAAE,mCAAmC;EACzCC,QAAQ,EAAE,6CAA6C;EACvDC,IAAI,EAAE;AACV,CAAC;AACD;AACA,MAAMC,SAAS,gBAAGP,QAAA;EAAAI,IAAA;IAAAI,MAAA;IAAAC,OAAA;EAAA;EAAAC,YAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAC,gBAAA;IAAAF,MAAA;IAAAC,OAAA;IAAAE,OAAA;EAAA;AAAA;EAAAC,CAAA;AAAA,CAejB,CAAC;AACF;AAAyC,OAAO,MAAMC,+CAA+C,GAAIC,KAAK,IAAG;EAC7G,MAAMC,MAAM,GAAGZ,SAAS,CAAC,CAAC;EAC1B,MAAM;IAAEa;EAAO,CAAC,GAAGF,KAAK;EACxBA,KAAK,CAACd,IAAI,CAACiB,SAAS,GAAGpB,YAAY,CAACE,uCAAuC,CAACC,IAAI,EAAEe,MAAM,CAACf,IAAI,EAAEgB,MAAM,KAAK,UAAU,GAAGD,MAAM,CAACT,YAAY,GAAGS,MAAM,CAACL,gBAAgB,EAAEI,KAAK,CAACd,IAAI,CAACiB,SAAS,CAAC;EAC3L,IAAIH,KAAK,CAACb,QAAQ,EAAE;IAChBa,KAAK,CAACb,QAAQ,CAACgB,SAAS,GAAGpB,YAAY,CAACE,uCAAuC,CAACE,QAAQ,EAAEa,KAAK,CAACb,QAAQ,CAACgB,SAAS,CAAC;EACvH;EACAH,KAAK,CAACZ,IAAI,CAACe,SAAS,GAAGpB,YAAY,CAACE,uCAAuC,CAACG,IAAI,EAAEY,KAAK,CAACZ,IAAI,CAACe,SAAS,CAAC;EACvG,OAAOH,KAAK;AAChB,CAAC"}
|
package/lib/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.js
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useTeachingPopoverCarouselFooterButton_unstable } from './useTeachingPopoverCarouselFooterButton';
|
|
3
|
+
import { renderTeachingPopoverCarouselFooterButton_unstable } from './renderTeachingPopoverCarouselFooterButton';
|
|
4
|
+
import { useTeachingPopoverCarouselFooterButtonStyles_unstable } from './useTeachingPopoverCarouselFooterButtonStyles.styles';
|
|
5
|
+
/**
|
|
6
|
+
* TeachingPopoverCarouselFooterButton component
|
|
7
|
+
*
|
|
8
|
+
* TeachingPopoverCarouselFooterButton extends Button and injects additional styling and onClick functionality
|
|
9
|
+
* to match the context provided by TeachingPopover & TeachingPopoverCarousel
|
|
10
|
+
*/ export const TeachingPopoverCarouselFooterButton = /*#__PURE__*/ React.forwardRef((props, ref)=>{
|
|
11
|
+
const state = useTeachingPopoverCarouselFooterButton_unstable(props, ref);
|
|
12
|
+
useTeachingPopoverCarouselFooterButtonStyles_unstable(state);
|
|
13
|
+
return renderTeachingPopoverCarouselFooterButton_unstable(state);
|
|
14
|
+
});
|
|
15
|
+
TeachingPopoverCarouselFooterButton.displayName = 'TeachingPopoverCarouselFooterButton';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselFooterButton.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useTeachingPopoverCarouselFooterButton_unstable } from './useTeachingPopoverCarouselFooterButton';\nimport { renderTeachingPopoverCarouselFooterButton_unstable } from './renderTeachingPopoverCarouselFooterButton';\nimport { useTeachingPopoverCarouselFooterButtonStyles_unstable } from './useTeachingPopoverCarouselFooterButtonStyles.styles';\nimport type { TeachingPopoverCarouselFooterButtonProps } from './TeachingPopoverCarouselFooterButton.types';\n\n/**\n * TeachingPopoverCarouselFooterButton component\n *\n * TeachingPopoverCarouselFooterButton extends Button and injects additional styling and onClick functionality\n * to match the context provided by TeachingPopover & TeachingPopoverCarousel\n */\nexport const TeachingPopoverCarouselFooterButton: ForwardRefComponent<TeachingPopoverCarouselFooterButtonProps> =\n React.forwardRef((props, ref) => {\n const state = useTeachingPopoverCarouselFooterButton_unstable(props, ref);\n\n useTeachingPopoverCarouselFooterButtonStyles_unstable(state);\n\n return renderTeachingPopoverCarouselFooterButton_unstable(state);\n });\n\nTeachingPopoverCarouselFooterButton.displayName = 'TeachingPopoverCarouselFooterButton';\n"],"names":["React","useTeachingPopoverCarouselFooterButton_unstable","renderTeachingPopoverCarouselFooterButton_unstable","useTeachingPopoverCarouselFooterButtonStyles_unstable","TeachingPopoverCarouselFooterButton","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAE/B,SAASC,+CAA+C,QAAQ,2CAA2C;AAC3G,SAASC,kDAAkD,QAAQ,8CAA8C;AACjH,SAASC,qDAAqD,QAAQ,wDAAwD;AAG9H;;;;;CAKC,GACD,OAAO,MAAMC,oDACXJ,MAAMK,UAAU,CAAC,CAACC,OAAOC;IACvB,MAAMC,QAAQP,gDAAgDK,OAAOC;IAErEJ,sDAAsDK;IAEtD,OAAON,mDAAmDM;AAC5D,GAAG;AAELJ,oCAAoCK,WAAW,GAAG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselFooterButton.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { PopoverContextValue } from '@fluentui/react-popover';\nimport { ButtonProps, ButtonState } from '@fluentui/react-button';\nimport { ARIAButtonSlotProps } from '@fluentui/react-aria';\nimport { ReactNode } from 'react';\n\nexport type TeachingPopoverCarouselFooterButtonSlots = {\n root: NonNullable<Slot<ARIAButtonSlotProps<'a'>>>;\n};\n\n/**\n * TeachingPopoverCarouselFooterButton Props\n */\nexport type TeachingPopoverCarouselFooterButtonProps = ComponentProps<TeachingPopoverCarouselFooterButtonSlots> &\n ButtonProps & {\n /**\n * Defines whether the button should be next or previous type - used for both styling and functionality.\n */\n navType: 'next' | 'prev';\n\n /**\n * The ReactNode provided to the button when it is on it's first (navType 'prev') or last (navType 'next') step\n */\n altText: ReactNode;\n };\n\n/**\n * State used in rendering TeachingPopoverCarouselFooterButton\n */\nexport type TeachingPopoverCarouselFooterButtonState = ButtonState &\n ComponentState<TeachingPopoverCarouselFooterButtonSlots> &\n Pick<TeachingPopoverCarouselFooterButtonProps, 'navType' | 'altText'> & {\n /* Rename popover appearance to prevent conflict with button appearance */\n popoverAppearance: PopoverContextValue['appearance'];\n };\n"],"names":[],"mappings":"AAAA,WAkCI"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export * from './TeachingPopoverCarouselFooterButton';
|
|
2
|
+
export * from './TeachingPopoverCarouselFooterButton.types';
|
|
3
|
+
export * from './renderTeachingPopoverCarouselFooterButton';
|
|
4
|
+
export * from './useTeachingPopoverCarouselFooterButton';
|
|
5
|
+
export * from './useTeachingPopoverCarouselFooterButtonStyles.styles';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["index.ts"],"sourcesContent":["export * from './TeachingPopoverCarouselFooterButton';\nexport * from './TeachingPopoverCarouselFooterButton.types';\nexport * from './renderTeachingPopoverCarouselFooterButton';\nexport * from './useTeachingPopoverCarouselFooterButton';\nexport * from './useTeachingPopoverCarouselFooterButtonStyles.styles';\n"],"names":[],"mappings":"AAAA,cAAc,wCAAwC;AACtD,cAAc,8CAA8C;AAC5D,cAAc,8CAA8C;AAC5D,cAAc,2CAA2C;AACzD,cAAc,wDAAwD"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jsx as _jsx } from "@fluentui/react-jsx-runtime/jsx-runtime";
|
|
2
|
+
import { assertSlots } from '@fluentui/react-utilities';
|
|
3
|
+
/**
|
|
4
|
+
* Render the final JSX of TeachingPopoverCarouselFooterButton
|
|
5
|
+
*/ export const renderTeachingPopoverCarouselFooterButton_unstable = (state)=>{
|
|
6
|
+
assertSlots(state);
|
|
7
|
+
return /*#__PURE__*/ _jsx(state.root, {});
|
|
8
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["renderTeachingPopoverCarouselFooterButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type {\n TeachingPopoverCarouselFooterButtonState,\n TeachingPopoverCarouselFooterButtonSlots,\n} from './TeachingPopoverCarouselFooterButton.types';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselFooterButton\n */\nexport const renderTeachingPopoverCarouselFooterButton_unstable = (state: TeachingPopoverCarouselFooterButtonState) => {\n assertSlots<TeachingPopoverCarouselFooterButtonSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderTeachingPopoverCarouselFooterButton_unstable","state","root"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;AAMxD;;CAEC,GACD,OAAO,MAAMC,qDAAqD,CAACC;IACjEF,YAAsDE;IAEtD,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
|
package/lib/components/TeachingPopoverCarouselFooterButton/useTeachingPopoverCarouselFooterButton.js
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { getIntrinsicElementProps, mergeCallbacks, slot } from '@fluentui/react-utilities';
|
|
3
|
+
import { usePopoverContext_unstable } from '@fluentui/react-popover';
|
|
4
|
+
import { useCarouselContext_unstable } from '../TeachingPopoverCarousel/Carousel/CarouselContext';
|
|
5
|
+
import { useEventCallback } from '@fluentui/react-utilities';
|
|
6
|
+
import { useButton_unstable } from '@fluentui/react-button';
|
|
7
|
+
import { useCarouselValues_unstable } from '../TeachingPopoverCarousel/Carousel/useCarouselValues';
|
|
8
|
+
/**
|
|
9
|
+
* Create the state required to render TeachingPopoverCarouselFooterButton.
|
|
10
|
+
*
|
|
11
|
+
* The returned state can be modified with hooks such as useTeachingPopoverCarouselFooterButtonStyles_unstable,
|
|
12
|
+
* before being passed to renderTeachingPopoverCarouselFooterButton_unstable.
|
|
13
|
+
*
|
|
14
|
+
* @param props - props from this instance of TeachingPopoverCarouselFooterButton
|
|
15
|
+
* @param ref - reference to root HTMLDivElement of TeachingPopoverCarouselFooterButton
|
|
16
|
+
*/ export const useTeachingPopoverCarouselFooterButton_unstable = (props, ref)=>{
|
|
17
|
+
const { navType, altText } = props;
|
|
18
|
+
const popoverAppearance = usePopoverContext_unstable((context)=>context.appearance);
|
|
19
|
+
const selectPageByDirection = useCarouselContext_unstable((c)=>c.selectPageByDirection);
|
|
20
|
+
const values = useCarouselValues_unstable((snapshot)=>snapshot);
|
|
21
|
+
const activeValue = useCarouselContext_unstable((c)=>c.value);
|
|
22
|
+
const handleClick = (event)=>{
|
|
23
|
+
if (event.isDefaultPrevented()) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
selectPageByDirection(event, navType);
|
|
27
|
+
};
|
|
28
|
+
const handleButtonClick = useEventCallback(mergeCallbacks(handleClick, props.onClick));
|
|
29
|
+
const isTrailing = React.useMemo(()=>{
|
|
30
|
+
if (!activeValue) {
|
|
31
|
+
return false;
|
|
32
|
+
}
|
|
33
|
+
if (navType === 'prev') {
|
|
34
|
+
return values.indexOf(activeValue) === 0;
|
|
35
|
+
}
|
|
36
|
+
return values.indexOf(activeValue) === values.length - 1;
|
|
37
|
+
}, [
|
|
38
|
+
navType,
|
|
39
|
+
activeValue,
|
|
40
|
+
values
|
|
41
|
+
]);
|
|
42
|
+
let buttonAppearanceType;
|
|
43
|
+
if (navType === 'next') {
|
|
44
|
+
buttonAppearanceType = popoverAppearance === 'brand' ? undefined : 'primary';
|
|
45
|
+
} else {
|
|
46
|
+
buttonAppearanceType = popoverAppearance === 'brand' ? 'outline' : undefined;
|
|
47
|
+
}
|
|
48
|
+
/* Handle altText on trailing step */ let buttonChild = props.children;
|
|
49
|
+
if (isTrailing) {
|
|
50
|
+
buttonChild = altText;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
...useButton_unstable({
|
|
54
|
+
appearance: buttonAppearanceType,
|
|
55
|
+
...props
|
|
56
|
+
}, ref),
|
|
57
|
+
navType,
|
|
58
|
+
popoverAppearance,
|
|
59
|
+
altText,
|
|
60
|
+
// Override useButton root slot
|
|
61
|
+
root: slot.always(getIntrinsicElementProps('button', {
|
|
62
|
+
ref,
|
|
63
|
+
appearance: buttonAppearanceType,
|
|
64
|
+
...props,
|
|
65
|
+
onClick: handleButtonClick,
|
|
66
|
+
children: buttonChild
|
|
67
|
+
}), {
|
|
68
|
+
elementType: 'button'
|
|
69
|
+
})
|
|
70
|
+
};
|
|
71
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["useTeachingPopoverCarouselFooterButton.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeCallbacks, slot } from '@fluentui/react-utilities';\nimport type {\n TeachingPopoverCarouselFooterButtonProps,\n TeachingPopoverCarouselFooterButtonState,\n} from './TeachingPopoverCarouselFooterButton.types';\nimport { usePopoverContext_unstable } from '@fluentui/react-popover';\nimport { useCarouselContext_unstable } from '../TeachingPopoverCarousel/Carousel/CarouselContext';\nimport { useEventCallback } from '@fluentui/react-utilities';\nimport { useButton_unstable } from '@fluentui/react-button';\nimport { useCarouselValues_unstable } from '../TeachingPopoverCarousel/Carousel/useCarouselValues';\n\n/**\n * Create the state required to render TeachingPopoverCarouselFooterButton.\n *\n * The returned state can be modified with hooks such as useTeachingPopoverCarouselFooterButtonStyles_unstable,\n * before being passed to renderTeachingPopoverCarouselFooterButton_unstable.\n *\n * @param props - props from this instance of TeachingPopoverCarouselFooterButton\n * @param ref - reference to root HTMLDivElement of TeachingPopoverCarouselFooterButton\n */\nexport const useTeachingPopoverCarouselFooterButton_unstable = (\n props: TeachingPopoverCarouselFooterButtonProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): TeachingPopoverCarouselFooterButtonState => {\n const { navType, altText } = props;\n\n const popoverAppearance = usePopoverContext_unstable(context => context.appearance);\n const selectPageByDirection = useCarouselContext_unstable(c => c.selectPageByDirection);\n const values = useCarouselValues_unstable(snapshot => snapshot);\n const activeValue = useCarouselContext_unstable(c => c.value);\n\n const handleClick = (event: React.MouseEvent<HTMLButtonElement & HTMLAnchorElement>) => {\n if (event.isDefaultPrevented()) {\n return;\n }\n\n selectPageByDirection(event, navType);\n };\n\n const handleButtonClick = useEventCallback(mergeCallbacks(handleClick, props.onClick));\n\n const isTrailing = React.useMemo(() => {\n if (!activeValue) {\n return false;\n }\n\n if (navType === 'prev') {\n return values.indexOf(activeValue) === 0;\n }\n\n return values.indexOf(activeValue) === values.length - 1;\n }, [navType, activeValue, values]);\n\n let buttonAppearanceType: 'primary' | 'outline' | undefined;\n\n if (navType === 'next') {\n buttonAppearanceType = popoverAppearance === 'brand' ? undefined : 'primary';\n } else {\n buttonAppearanceType = popoverAppearance === 'brand' ? 'outline' : undefined;\n }\n\n /* Handle altText on trailing step */\n let buttonChild = props.children;\n if (isTrailing) {\n buttonChild = altText;\n }\n\n return {\n ...useButton_unstable({ appearance: buttonAppearanceType, ...props }, ref),\n navType,\n popoverAppearance,\n altText,\n // Override useButton root slot\n root: slot.always(\n getIntrinsicElementProps('button', {\n ref,\n appearance: buttonAppearanceType,\n ...props,\n onClick: handleButtonClick,\n children: buttonChild,\n }),\n { elementType: 'button' },\n ),\n };\n};\n"],"names":["React","getIntrinsicElementProps","mergeCallbacks","slot","usePopoverContext_unstable","useCarouselContext_unstable","useEventCallback","useButton_unstable","useCarouselValues_unstable","useTeachingPopoverCarouselFooterButton_unstable","props","ref","navType","altText","popoverAppearance","context","appearance","selectPageByDirection","c","values","snapshot","activeValue","value","handleClick","event","isDefaultPrevented","handleButtonClick","onClick","isTrailing","useMemo","indexOf","length","buttonAppearanceType","undefined","buttonChild","children","root","always","elementType"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,wBAAwB,EAAEC,cAAc,EAAEC,IAAI,QAAQ,4BAA4B;AAK3F,SAASC,0BAA0B,QAAQ,0BAA0B;AACrE,SAASC,2BAA2B,QAAQ,sDAAsD;AAClG,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SAASC,kBAAkB,QAAQ,yBAAyB;AAC5D,SAASC,0BAA0B,QAAQ,wDAAwD;AAEnG;;;;;;;;CAQC,GACD,OAAO,MAAMC,kDAAkD,CAC7DC,OACAC;IAEA,MAAM,EAAEC,OAAO,EAAEC,OAAO,EAAE,GAAGH;IAE7B,MAAMI,oBAAoBV,2BAA2BW,CAAAA,UAAWA,QAAQC,UAAU;IAClF,MAAMC,wBAAwBZ,4BAA4Ba,CAAAA,IAAKA,EAAED,qBAAqB;IACtF,MAAME,SAASX,2BAA2BY,CAAAA,WAAYA;IACtD,MAAMC,cAAchB,4BAA4Ba,CAAAA,IAAKA,EAAEI,KAAK;IAE5D,MAAMC,cAAc,CAACC;QACnB,IAAIA,MAAMC,kBAAkB,IAAI;YAC9B;QACF;QAEAR,sBAAsBO,OAAOZ;IAC/B;IAEA,MAAMc,oBAAoBpB,iBAAiBJ,eAAeqB,aAAab,MAAMiB,OAAO;IAEpF,MAAMC,aAAa5B,MAAM6B,OAAO,CAAC;QAC/B,IAAI,CAACR,aAAa;YAChB,OAAO;QACT;QAEA,IAAIT,YAAY,QAAQ;YACtB,OAAOO,OAAOW,OAAO,CAACT,iBAAiB;QACzC;QAEA,OAAOF,OAAOW,OAAO,CAACT,iBAAiBF,OAAOY,MAAM,GAAG;IACzD,GAAG;QAACnB;QAASS;QAAaF;KAAO;IAEjC,IAAIa;IAEJ,IAAIpB,YAAY,QAAQ;QACtBoB,uBAAuBlB,sBAAsB,UAAUmB,YAAY;IACrE,OAAO;QACLD,uBAAuBlB,sBAAsB,UAAU,YAAYmB;IACrE;IAEA,mCAAmC,GACnC,IAAIC,cAAcxB,MAAMyB,QAAQ;IAChC,IAAIP,YAAY;QACdM,cAAcrB;IAChB;IAEA,OAAO;QACL,GAAGN,mBAAmB;YAAES,YAAYgB;YAAsB,GAAGtB,KAAK;QAAC,GAAGC,IAAI;QAC1EC;QACAE;QACAD;QACA,+BAA+B;QAC/BuB,MAAMjC,KAAKkC,MAAM,CACfpC,yBAAyB,UAAU;YACjCU;YACAK,YAAYgB;YACZ,GAAGtB,KAAK;YACRiB,SAASD;YACTS,UAAUD;QACZ,IACA;YAAEI,aAAa;QAAS;IAE5B;AACF,EAAE"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { __styles, mergeClasses, shorthands } from '@griffel/react';
|
|
2
|
+
import { tokens } from '@fluentui/react-theme';
|
|
3
|
+
import { useButtonStyles_unstable } from '@fluentui/react-button';
|
|
4
|
+
export const teachingPopoverCarouselFooterButtonClassNames = {
|
|
5
|
+
root: 'fui-TeachingPopoverCarouselFooterButton'
|
|
6
|
+
};
|
|
7
|
+
const useStyles = /*#__PURE__*/__styles({
|
|
8
|
+
root: {
|
|
9
|
+
Bf4jedk: "f14es27b"
|
|
10
|
+
},
|
|
11
|
+
brandNext: {
|
|
12
|
+
sj55zd: "f16muhyy",
|
|
13
|
+
De3pzq: "f10s6wn9",
|
|
14
|
+
g2u3we: "f1iimpp0",
|
|
15
|
+
h3c5rm: ["f19uhqvu", "f1nx14hx"],
|
|
16
|
+
B9xav0g: "fnqa90p",
|
|
17
|
+
zhjwy3: ["f1nx14hx", "f19uhqvu"],
|
|
18
|
+
Bi91k9c: "f3ymbdj",
|
|
19
|
+
Jwef8y: "f1rgtb95",
|
|
20
|
+
B2d53fq: "f1pu27ff",
|
|
21
|
+
iro3zm: "f1d5c7in"
|
|
22
|
+
},
|
|
23
|
+
brandPrevious: {
|
|
24
|
+
sj55zd: "f1phragk",
|
|
25
|
+
De3pzq: "ffp7eso",
|
|
26
|
+
g2u3we: "fm1ebug",
|
|
27
|
+
h3c5rm: ["f28omuz", "f1uhflii"],
|
|
28
|
+
B9xav0g: "f1ixw5o4",
|
|
29
|
+
zhjwy3: ["f1uhflii", "f28omuz"],
|
|
30
|
+
Bi91k9c: "f1rq72xc",
|
|
31
|
+
Bgoe8wy: "f1bg5g8r",
|
|
32
|
+
Bwzppfd: ["f1h9bnsk", "f12x9t0k"],
|
|
33
|
+
oetu4i: "f19ervry",
|
|
34
|
+
gg5e9n: ["f12x9t0k", "f1h9bnsk"],
|
|
35
|
+
Jwef8y: "f15wkkf3",
|
|
36
|
+
B2d53fq: "f1d6v5y2",
|
|
37
|
+
b661bw: "f1565b9n",
|
|
38
|
+
Bk6r4ia: ["fm07gvo", "fwlsg72"],
|
|
39
|
+
B9zn80p: "fzw6fmy",
|
|
40
|
+
Bpld233: ["fwlsg72", "fm07gvo"],
|
|
41
|
+
iro3zm: "fnp9lpt"
|
|
42
|
+
}
|
|
43
|
+
}, {
|
|
44
|
+
d: [".f14es27b{min-width:96px;}", ".f16muhyy{color:var(--colorBrandForeground1);}", ".f10s6wn9{background-color:var(--colorNeutralForegroundOnBrand);}", ".f1iimpp0{border-top-color:var(--colorTransparentBackground);}", ".f19uhqvu{border-right-color:var(--colorTransparentBackground);}", ".f1nx14hx{border-left-color:var(--colorTransparentBackground);}", ".fnqa90p{border-bottom-color:var(--colorTransparentBackground);}", ".f1phragk{color:var(--colorNeutralForegroundOnBrand);}", ".ffp7eso{background-color:var(--colorBrandBackground);}", ".fm1ebug{border-top-color:var(--colorNeutralForegroundOnBrand);}", ".f28omuz{border-right-color:var(--colorNeutralForegroundOnBrand);}", ".f1uhflii{border-left-color:var(--colorNeutralForegroundOnBrand);}", ".f1ixw5o4{border-bottom-color:var(--colorNeutralForegroundOnBrand);}"],
|
|
45
|
+
h: [".f3ymbdj:hover{color:var(--colorCompoundBrandForeground1Hover);}", ".f1rgtb95:hover{background-color:var(--colorNeutralForegroundOnBrand);}", ".f1pu27ff:hover:active{color:var(--colorCompoundBrandForeground1Pressed);}", ".f1d5c7in:hover:active{background-color:var(--colorNeutralForegroundOnBrand);}", ".f1rq72xc:hover{color:var(--colorNeutralForegroundOnBrand);}", ".f1bg5g8r:hover{border-top-color:var(--colorNeutralForegroundOnBrand);}", ".f1h9bnsk:hover{border-right-color:var(--colorNeutralForegroundOnBrand);}", ".f12x9t0k:hover{border-left-color:var(--colorNeutralForegroundOnBrand);}", ".f19ervry:hover{border-bottom-color:var(--colorNeutralForegroundOnBrand);}", ".f15wkkf3:hover{background-color:var(--colorBrandBackgroundHover);}", ".f1d6v5y2:hover:active{color:var(--colorNeutralForegroundOnBrand);}", ".f1565b9n:hover:active{border-top-color:var(--colorNeutralForegroundOnBrand);}", ".fm07gvo:hover:active{border-right-color:var(--colorNeutralForegroundOnBrand);}", ".fwlsg72:hover:active{border-left-color:var(--colorNeutralForegroundOnBrand);}", ".fzw6fmy:hover:active{border-bottom-color:var(--colorNeutralForegroundOnBrand);}", ".fnp9lpt:hover:active{background-color:var(--colorBrandBackgroundPressed);}"]
|
|
46
|
+
});
|
|
47
|
+
/**
|
|
48
|
+
* Apply styling to the TeachingPopoverCarouselFooterButton slots based on the state
|
|
49
|
+
*/
|
|
50
|
+
export const useTeachingPopoverCarouselFooterButtonStyles_unstable = state => {
|
|
51
|
+
const styles = useStyles();
|
|
52
|
+
const {
|
|
53
|
+
navType,
|
|
54
|
+
popoverAppearance
|
|
55
|
+
} = state;
|
|
56
|
+
// Apply underlying fluent Button styles
|
|
57
|
+
state = {
|
|
58
|
+
...state,
|
|
59
|
+
...useButtonStyles_unstable(state)
|
|
60
|
+
};
|
|
61
|
+
state.root.className = mergeClasses(teachingPopoverCarouselFooterButtonClassNames.root, styles.root, navType === 'prev' && popoverAppearance === 'brand' && styles.brandPrevious, navType === 'next' && popoverAppearance === 'brand' && styles.brandNext, state.root.className);
|
|
62
|
+
return state;
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=useTeachingPopoverCarouselFooterButtonStyles.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["__styles","mergeClasses","shorthands","tokens","useButtonStyles_unstable","teachingPopoverCarouselFooterButtonClassNames","root","useStyles","Bf4jedk","brandNext","sj55zd","De3pzq","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bi91k9c","Jwef8y","B2d53fq","iro3zm","brandPrevious","Bgoe8wy","Bwzppfd","oetu4i","gg5e9n","b661bw","Bk6r4ia","B9zn80p","Bpld233","d","h","useTeachingPopoverCarouselFooterButtonStyles_unstable","state","styles","navType","popoverAppearance","className"],"sources":["useTeachingPopoverCarouselFooterButtonStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport { useButtonStyles_unstable } from '@fluentui/react-button';\nexport const teachingPopoverCarouselFooterButtonClassNames = {\n root: 'fui-TeachingPopoverCarouselFooterButton'\n};\nconst useStyles = makeStyles({\n root: {\n minWidth: '96px'\n },\n brandNext: {\n color: tokens.colorBrandForeground1,\n backgroundColor: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorTransparentBackground),\n ':hover': {\n color: tokens.colorCompoundBrandForeground1Hover,\n backgroundColor: tokens.colorNeutralForegroundOnBrand\n },\n ':hover:active': {\n color: tokens.colorCompoundBrandForeground1Pressed,\n backgroundColor: tokens.colorNeutralForegroundOnBrand\n }\n },\n brandPrevious: {\n // In brand, this is always 'NeutralForegroundOnBrand'\n color: tokens.colorNeutralForegroundOnBrand,\n backgroundColor: tokens.colorBrandBackground,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n ':hover': {\n color: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n backgroundColor: tokens.colorBrandBackgroundHover\n },\n ':hover:active': {\n color: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n backgroundColor: tokens.colorBrandBackgroundPressed\n }\n }\n});\n/**\n * Apply styling to the TeachingPopoverCarouselFooterButton slots based on the state\n */ export const useTeachingPopoverCarouselFooterButtonStyles_unstable = (state)=>{\n const styles = useStyles();\n const { navType, popoverAppearance } = state;\n // Apply underlying fluent Button styles\n state = {\n ...state,\n ...useButtonStyles_unstable(state)\n };\n state.root.className = mergeClasses(teachingPopoverCarouselFooterButtonClassNames.root, styles.root, navType === 'prev' && popoverAppearance === 'brand' && styles.brandPrevious, navType === 'next' && popoverAppearance === 'brand' && styles.brandNext, state.root.className);\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,SAASC,wBAAwB,QAAQ,wBAAwB;AACjE,OAAO,MAAMC,6CAA6C,GAAG;EACzDC,IAAI,EAAE;AACV,CAAC;AACD,MAAMC,SAAS,gBAAGP,QAAA;EAAAM,IAAA;IAAAE,OAAA;EAAA;EAAAC,SAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAC,aAAA;IAAAV,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAK,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAP,MAAA;IAAAC,OAAA;IAAAO,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAT,MAAA;EAAA;AAAA;EAAAU,CAAA;EAAAC,CAAA;AAAA,CAiCjB,CAAC;AACF;AACA;AACA;AAAI,OAAO,MAAMC,qDAAqD,GAAIC,KAAK,IAAG;EAC9E,MAAMC,MAAM,GAAG1B,SAAS,CAAC,CAAC;EAC1B,MAAM;IAAE2B,OAAO;IAAEC;EAAkB,CAAC,GAAGH,KAAK;EAC5C;EACAA,KAAK,GAAG;IACJ,GAAGA,KAAK;IACR,GAAG5B,wBAAwB,CAAC4B,KAAK;EACrC,CAAC;EACDA,KAAK,CAAC1B,IAAI,CAAC8B,SAAS,GAAGnC,YAAY,CAACI,6CAA6C,CAACC,IAAI,EAAE2B,MAAM,CAAC3B,IAAI,EAAE4B,OAAO,KAAK,MAAM,IAAIC,iBAAiB,KAAK,OAAO,IAAIF,MAAM,CAACb,aAAa,EAAEc,OAAO,KAAK,MAAM,IAAIC,iBAAiB,KAAK,OAAO,IAAIF,MAAM,CAACxB,SAAS,EAAEuB,KAAK,CAAC1B,IAAI,CAAC8B,SAAS,CAAC;EAChR,OAAOJ,KAAK;AAChB,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useTeachingPopoverCarouselNav_unstable } from './useTeachingPopoverCarouselNav';
|
|
3
|
+
import { renderTeachingPopoverCarouselNav_unstable } from './renderTeachingPopoverCarouselNav';
|
|
4
|
+
import { useTeachingPopoverCarouselNavStyles_unstable } from './useTeachingPopoverCarouselNavStyles.styles';
|
|
5
|
+
/**
|
|
6
|
+
* Define a styled TeachingPopoverCarouselNav, using the `useTeachingPopoverCarouselNav_unstable` and `useTeachingPopoverCarouselNavStyles_unstable`
|
|
7
|
+
* hooks.
|
|
8
|
+
*
|
|
9
|
+
* TeachingPopoverCarouselNav provides an index-based pagination list to jump to any page within the carousel.
|
|
10
|
+
*/ export const TeachingPopoverCarouselNav = /*#__PURE__*/ React.forwardRef((props, ref)=>{
|
|
11
|
+
const state = useTeachingPopoverCarouselNav_unstable(props, ref);
|
|
12
|
+
useTeachingPopoverCarouselNavStyles_unstable(state);
|
|
13
|
+
return renderTeachingPopoverCarouselNav_unstable(state);
|
|
14
|
+
});
|
|
15
|
+
TeachingPopoverCarouselNav.displayName = 'TeachingPopoverCarouselNav';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselNav.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopoverCarouselNav_unstable } from './useTeachingPopoverCarouselNav';\nimport { renderTeachingPopoverCarouselNav_unstable } from './renderTeachingPopoverCarouselNav';\nimport { useTeachingPopoverCarouselNavStyles_unstable } from './useTeachingPopoverCarouselNavStyles.styles';\nimport type { TeachingPopoverCarouselNavProps } from './TeachingPopoverCarouselNav.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * Define a styled TeachingPopoverCarouselNav, using the `useTeachingPopoverCarouselNav_unstable` and `useTeachingPopoverCarouselNavStyles_unstable`\n * hooks.\n *\n * TeachingPopoverCarouselNav provides an index-based pagination list to jump to any page within the carousel.\n */\nexport const TeachingPopoverCarouselNav: ForwardRefComponent<TeachingPopoverCarouselNavProps> = React.forwardRef(\n (props, ref) => {\n const state = useTeachingPopoverCarouselNav_unstable(props, ref);\n\n useTeachingPopoverCarouselNavStyles_unstable(state);\n\n return renderTeachingPopoverCarouselNav_unstable(state);\n },\n);\n\nTeachingPopoverCarouselNav.displayName = 'TeachingPopoverCarouselNav';\n"],"names":["React","useTeachingPopoverCarouselNav_unstable","renderTeachingPopoverCarouselNav_unstable","useTeachingPopoverCarouselNavStyles_unstable","TeachingPopoverCarouselNav","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,sCAAsC,QAAQ,kCAAkC;AACzF,SAASC,yCAAyC,QAAQ,qCAAqC;AAC/F,SAASC,4CAA4C,QAAQ,+CAA+C;AAI5G;;;;;CAKC,GACD,OAAO,MAAMC,2CAAmFJ,MAAMK,UAAU,CAC9G,CAACC,OAAOC;IACN,MAAMC,QAAQP,uCAAuCK,OAAOC;IAE5DJ,6CAA6CK;IAE7C,OAAON,0CAA0CM;AACnD,GACA;AAEFJ,2BAA2BK,WAAW,GAAG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselNav.types.ts"],"sourcesContent":["import * as React from 'react';\nimport { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type TeachingPopoverCarouselNavSlots = {\n /**\n * The element wrapping the carousel pagination. By default this is a div,\n * it may contain icons or text depending on TeachingPopoverCarouselNavStyle\n */\n root: NonNullable<Slot<'div'>>;\n};\n\nexport type NavButtonRenderFunction = (value: string) => React.ReactNode;\n\nexport type TeachingPopoverCarouselNavState = ComponentState<TeachingPopoverCarouselNavSlots> & {\n values: string[];\n\n renderNavButton: NavButtonRenderFunction;\n};\n\nexport type TeachingPopoverCarouselNavProps = Omit<\n ComponentProps<Partial<TeachingPopoverCarouselNavSlots>>,\n 'children'\n> & {\n children: NavButtonRenderFunction;\n};\n"],"names":["React"],"mappings":"AAAA,YAAYA,WAAW,QAAQ"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["index.ts"],"sourcesContent":["export * from './TeachingPopoverCarouselNav';\nexport * from './TeachingPopoverCarouselNav.types';\nexport * from './renderTeachingPopoverCarouselNav';\nexport * from './useTeachingPopoverCarouselNav';\nexport * from './useTeachingPopoverCarouselNavStyles.styles';\n"],"names":[],"mappings":"AAAA,cAAc,+BAA+B;AAC7C,cAAc,qCAAqC;AACnD,cAAc,qCAAqC;AACnD,cAAc,kCAAkC;AAChD,cAAc,+CAA+C"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { jsx as _jsx } from "@fluentui/react-jsx-runtime/jsx-runtime";
|
|
2
|
+
import { assertSlots } from '@fluentui/react-utilities';
|
|
3
|
+
import { ValueIdContextProvider } from './valueIdContext';
|
|
4
|
+
/**
|
|
5
|
+
* Render the final JSX of TeachingPopoverCarouselNav
|
|
6
|
+
*/ export const renderTeachingPopoverCarouselNav_unstable = (state)=>{
|
|
7
|
+
assertSlots(state);
|
|
8
|
+
const { values, renderNavButton } = state;
|
|
9
|
+
return /*#__PURE__*/ _jsx(state.root, {
|
|
10
|
+
children: values.map((value)=>/*#__PURE__*/ _jsx(ValueIdContextProvider, {
|
|
11
|
+
value: value,
|
|
12
|
+
children: renderNavButton(value)
|
|
13
|
+
}, value))
|
|
14
|
+
});
|
|
15
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["renderTeachingPopoverCarouselNav.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\nimport type { TeachingPopoverCarouselNavState } from './TeachingPopoverCarouselNav.types';\nimport { assertSlots } from '@fluentui/react-utilities';\nimport { TeachingPopoverCarouselNavSlots } from './TeachingPopoverCarouselNav.types';\nimport { ValueIdContextProvider } from './valueIdContext';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselNav\n */\nexport const renderTeachingPopoverCarouselNav_unstable = (state: TeachingPopoverCarouselNavState) => {\n assertSlots<TeachingPopoverCarouselNavSlots>(state);\n\n const { values, renderNavButton } = state;\n\n return (\n <state.root>\n {values.map(value => (\n <ValueIdContextProvider value={value} key={value}>\n {renderNavButton(value)}\n </ValueIdContextProvider>\n ))}\n </state.root>\n );\n};\n"],"names":["assertSlots","ValueIdContextProvider","renderTeachingPopoverCarouselNav_unstable","state","values","renderNavButton","root","map","value"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;AAExD,SAASC,sBAAsB,QAAQ,mBAAmB;AAE1D;;CAEC,GACD,OAAO,MAAMC,4CAA4C,CAACC;IACxDH,YAA6CG;IAE7C,MAAM,EAAEC,MAAM,EAAEC,eAAe,EAAE,GAAGF;IAEpC,qBACE,KAACA,MAAMG,IAAI;kBACRF,OAAOG,GAAG,CAACC,CAAAA,sBACV,KAACP;gBAAuBO,OAAOA;0BAC5BH,gBAAgBG;eADwBA;;AAMnD,EAAE"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { useArrowNavigationGroup } from '@fluentui/react-tabster';
|
|
2
|
+
import { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { useCarouselValues_unstable } from '../TeachingPopoverCarousel/Carousel/useCarouselValues';
|
|
5
|
+
/**
|
|
6
|
+
* Returns the props and state required to render the component
|
|
7
|
+
* @param props - TeachingPopoverCarouselNav properties
|
|
8
|
+
* @param ref - reference to root HTMLElement of TeachingPopoverCarouselNav
|
|
9
|
+
*/ export const useTeachingPopoverCarouselNav_unstable = (props, ref)=>{
|
|
10
|
+
const focusableGroupAttr = useArrowNavigationGroup({
|
|
11
|
+
circular: false,
|
|
12
|
+
axis: 'horizontal',
|
|
13
|
+
memorizeCurrent: false,
|
|
14
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
15
|
+
unstable_hasDefault: true
|
|
16
|
+
});
|
|
17
|
+
const values = useCarouselValues_unstable((snapshot)=>snapshot);
|
|
18
|
+
return {
|
|
19
|
+
values,
|
|
20
|
+
renderNavButton: props.children,
|
|
21
|
+
components: {
|
|
22
|
+
root: 'div'
|
|
23
|
+
},
|
|
24
|
+
root: slot.always(getIntrinsicElementProps('div', {
|
|
25
|
+
ref,
|
|
26
|
+
role: 'tablist',
|
|
27
|
+
tabIndex: 0,
|
|
28
|
+
...props,
|
|
29
|
+
...focusableGroupAttr,
|
|
30
|
+
children: null
|
|
31
|
+
}), {
|
|
32
|
+
elementType: 'div'
|
|
33
|
+
})
|
|
34
|
+
};
|
|
35
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["useTeachingPopoverCarouselNav.tsx"],"sourcesContent":["import { useArrowNavigationGroup } from '@fluentui/react-tabster';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport * as React from 'react';\n\nimport type {\n TeachingPopoverCarouselNavProps,\n TeachingPopoverCarouselNavState,\n} from './TeachingPopoverCarouselNav.types';\nimport { useCarouselValues_unstable } from '../TeachingPopoverCarousel/Carousel/useCarouselValues';\n\n/**\n * Returns the props and state required to render the component\n * @param props - TeachingPopoverCarouselNav properties\n * @param ref - reference to root HTMLElement of TeachingPopoverCarouselNav\n */\nexport const useTeachingPopoverCarouselNav_unstable = (\n props: TeachingPopoverCarouselNavProps,\n ref: React.Ref<HTMLDivElement>,\n): TeachingPopoverCarouselNavState => {\n const focusableGroupAttr = useArrowNavigationGroup({\n circular: false,\n axis: 'horizontal',\n memorizeCurrent: false,\n // eslint-disable-next-line @typescript-eslint/naming-convention\n unstable_hasDefault: true,\n });\n const values = useCarouselValues_unstable(snapshot => snapshot);\n\n return {\n values,\n renderNavButton: props.children,\n components: {\n root: 'div',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n role: 'tablist',\n tabIndex: 0,\n ...props,\n ...focusableGroupAttr,\n children: null,\n }),\n { elementType: 'div' },\n ),\n };\n};\n"],"names":["useArrowNavigationGroup","getIntrinsicElementProps","slot","React","useCarouselValues_unstable","useTeachingPopoverCarouselNav_unstable","props","ref","focusableGroupAttr","circular","axis","memorizeCurrent","unstable_hasDefault","values","snapshot","renderNavButton","children","components","root","always","role","tabIndex","elementType"],"mappings":"AAAA,SAASA,uBAAuB,QAAQ,0BAA0B;AAClE,SAASC,wBAAwB,EAAEC,IAAI,QAAQ,4BAA4B;AAC3E,YAAYC,WAAW,QAAQ;AAM/B,SAASC,0BAA0B,QAAQ,wDAAwD;AAEnG;;;;CAIC,GACD,OAAO,MAAMC,yCAAyC,CACpDC,OACAC;IAEA,MAAMC,qBAAqBR,wBAAwB;QACjDS,UAAU;QACVC,MAAM;QACNC,iBAAiB;QACjB,gEAAgE;QAChEC,qBAAqB;IACvB;IACA,MAAMC,SAAST,2BAA2BU,CAAAA,WAAYA;IAEtD,OAAO;QACLD;QACAE,iBAAiBT,MAAMU,QAAQ;QAC/BC,YAAY;YACVC,MAAM;QACR;QACAA,MAAMhB,KAAKiB,MAAM,CACflB,yBAAyB,OAAO;YAC9BM;YACAa,MAAM;YACNC,UAAU;YACV,GAAGf,KAAK;YACR,GAAGE,kBAAkB;YACrBQ,UAAU;QACZ,IACA;YAAEM,aAAa;QAAM;IAEzB;AACF,EAAE"}
|
package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { __styles, mergeClasses, shorthands } from '@griffel/react';
|
|
2
|
+
import { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';
|
|
3
|
+
import { tokens } from '@fluentui/react-theme';
|
|
4
|
+
export const teachingPopoverCarouselNavClassNames = {
|
|
5
|
+
root: 'fui-TeachingPopoverCarouselNav'
|
|
6
|
+
};
|
|
7
|
+
const useStyles = /*#__PURE__*/__styles({
|
|
8
|
+
root: {
|
|
9
|
+
mc9l5x: "f22iagw",
|
|
10
|
+
Beiy3e4: "f1063pyq",
|
|
11
|
+
i8kkvl: "f1ufnopg",
|
|
12
|
+
Bt984gj: "f122n59",
|
|
13
|
+
Brf1p80: "f4d9j23",
|
|
14
|
+
Bn4voq9: "f1p7hgxw",
|
|
15
|
+
g9k6zt: "f9znhxp",
|
|
16
|
+
Bfpq7zp: "fqrak0z",
|
|
17
|
+
kdpuga: ["f1o2ludy", "f1kjnpwc"],
|
|
18
|
+
Bw81rd7: ["f1kjnpwc", "f1o2ludy"],
|
|
19
|
+
B6xbmo0: ["fxmnebo", "f1witrsb"],
|
|
20
|
+
dm238s: ["f1witrsb", "fxmnebo"],
|
|
21
|
+
B8q5s1w: "f8hki3x",
|
|
22
|
+
Bci5o5g: ["f1d2448m", "ffh67wi"],
|
|
23
|
+
n8qw10: "f1bjia2o",
|
|
24
|
+
Bdrgwmp: ["ffh67wi", "f1d2448m"]
|
|
25
|
+
}
|
|
26
|
+
}, {
|
|
27
|
+
d: [".f22iagw{display:flex;}", ".f1063pyq{flex-direction:row;}", ".f1ufnopg{column-gap:var(--spacingHorizontalXS);}", ".f122n59{align-items:center;}", ".f4d9j23{justify-content:center;}", ".f1p7hgxw[data-fui-focus-visible]{outline-width:var(--strokeWidthThick);}", ".f9znhxp[data-fui-focus-visible]{outline-style:solid;}", ".fqrak0z[data-fui-focus-visible]{outline-color:var(--colorStrokeFocus2);}", ".f1o2ludy[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f1kjnpwc[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusMedium);}", ".fxmnebo[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusMedium);}", ".f1witrsb[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusMedium);}", ".f8hki3x[data-fui-focus-visible]{border-top-color:transparent;}", ".f1d2448m[data-fui-focus-visible]{border-right-color:transparent;}", ".ffh67wi[data-fui-focus-visible]{border-left-color:transparent;}", ".f1bjia2o[data-fui-focus-visible]{border-bottom-color:transparent;}"]
|
|
28
|
+
});
|
|
29
|
+
/** Applies style classnames to slots */
|
|
30
|
+
export const useTeachingPopoverCarouselNavStyles_unstable = state => {
|
|
31
|
+
const styles = useStyles();
|
|
32
|
+
state.root.className = mergeClasses(teachingPopoverCarouselNavClassNames.root, styles.root, state.root.className);
|
|
33
|
+
return state;
|
|
34
|
+
};
|
|
35
|
+
//# sourceMappingURL=useTeachingPopoverCarouselNavStyles.styles.js.map
|
package/lib/components/TeachingPopoverCarouselNav/useTeachingPopoverCarouselNavStyles.styles.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["__styles","mergeClasses","shorthands","createCustomFocusIndicatorStyle","tokens","teachingPopoverCarouselNavClassNames","root","useStyles","mc9l5x","Beiy3e4","i8kkvl","Bt984gj","Brf1p80","Bn4voq9","g9k6zt","Bfpq7zp","kdpuga","Bw81rd7","B6xbmo0","dm238s","B8q5s1w","Bci5o5g","n8qw10","Bdrgwmp","d","useTeachingPopoverCarouselNavStyles_unstable","state","styles","className"],"sources":["useTeachingPopoverCarouselNavStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';\nimport { tokens } from '@fluentui/react-theme';\nexport const teachingPopoverCarouselNavClassNames = {\n root: 'fui-TeachingPopoverCarouselNav'\n};\nconst useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'row',\n columnGap: tokens.spacingHorizontalXS,\n alignItems: 'center',\n justifyContent: 'center',\n ...createCustomFocusIndicatorStyle({\n ...shorthands.outline(tokens.strokeWidthThick, 'solid', tokens.colorStrokeFocus2),\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n ...shorthands.borderColor('transparent')\n })\n }\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverCarouselNavStyles_unstable = (state)=>{\n const styles = useStyles();\n state.root.className = mergeClasses(teachingPopoverCarouselNavClassNames.root, styles.root, state.root.className);\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,SAASC,+BAA+B,QAAQ,yBAAyB;AACzE,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,OAAO,MAAMC,oCAAoC,GAAG;EAChDC,IAAI,EAAE;AACV,CAAC;AACD,MAAMC,SAAS,gBAAGP,QAAA;EAAAM,IAAA;IAAAE,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;AAAA;EAAAC,CAAA;AAAA,CAajB,CAAC;AACF;AAAyC,OAAO,MAAMC,4CAA4C,GAAIC,KAAK,IAAG;EAC1G,MAAMC,MAAM,GAAGpB,SAAS,CAAC,CAAC;EAC1BmB,KAAK,CAACpB,IAAI,CAACsB,SAAS,GAAG3B,YAAY,CAACI,oCAAoC,CAACC,IAAI,EAAEqB,MAAM,CAACrB,IAAI,EAAEoB,KAAK,CAACpB,IAAI,CAACsB,SAAS,CAAC;EACjH,OAAOF,KAAK;AAChB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const valueIdContext = React.createContext(undefined);
|
|
3
|
+
export const valueIdContextDefaultValue = '';
|
|
4
|
+
export const useValueIdContext = ()=>{
|
|
5
|
+
var _React_useContext;
|
|
6
|
+
return (_React_useContext = React.useContext(valueIdContext)) !== null && _React_useContext !== void 0 ? _React_useContext : valueIdContextDefaultValue;
|
|
7
|
+
};
|
|
8
|
+
export const ValueIdContextProvider = valueIdContext.Provider;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["valueIdContext.ts"],"sourcesContent":["import * as React from 'react';\n\nconst valueIdContext = React.createContext<string | undefined>(undefined);\n\nexport const valueIdContextDefaultValue = '';\n\nexport const useValueIdContext = () => React.useContext(valueIdContext) ?? valueIdContextDefaultValue;\n\nexport const ValueIdContextProvider = valueIdContext.Provider;\n"],"names":["React","valueIdContext","createContext","undefined","valueIdContextDefaultValue","useValueIdContext","useContext","ValueIdContextProvider","Provider"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAE/B,MAAMC,iBAAiBD,MAAME,aAAa,CAAqBC;AAE/D,OAAO,MAAMC,6BAA6B,GAAG;AAE7C,OAAO,MAAMC,oBAAoB;QAAML;WAAAA,CAAAA,oBAAAA,MAAMM,UAAU,CAACL,6BAAjBD,+BAAAA,oBAAoCI;AAAyB,EAAE;AAEtG,OAAO,MAAMG,yBAAyBN,eAAeO,QAAQ,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useTeachingPopoverCarouselNavButton_unstable } from './useTeachingPopoverCarouselNavButton';
|
|
3
|
+
import { renderTeachingPopoverCarouselNavButton_unstable } from './renderTeachingPopoverCarouselNavButton';
|
|
4
|
+
import { useTeachingPopoverCarouselNavButtonStyles_unstable } from './useTeachingPopoverCarouselNavButtonStyles.styles';
|
|
5
|
+
/**
|
|
6
|
+
* TeachingPopoverCarouselNavButton is a button to jump to a single page within TeachingPopoverCarousel
|
|
7
|
+
*
|
|
8
|
+
* It's value is injected via context and must be wrapped with a ValueIdContextProvider (automatically handled via TeachingPopoverCarouselNav)
|
|
9
|
+
*/ export const TeachingPopoverCarouselNavButton = /*#__PURE__*/ React.forwardRef((props, ref)=>{
|
|
10
|
+
const state = useTeachingPopoverCarouselNavButton_unstable(props, ref);
|
|
11
|
+
useTeachingPopoverCarouselNavButtonStyles_unstable(state);
|
|
12
|
+
return renderTeachingPopoverCarouselNavButton_unstable(state);
|
|
13
|
+
});
|
|
14
|
+
TeachingPopoverCarouselNavButton.displayName = 'TeachingPopoverCarouselNavButton';
|
package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselNavButton.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useTeachingPopoverCarouselNavButton_unstable } from './useTeachingPopoverCarouselNavButton';\nimport { renderTeachingPopoverCarouselNavButton_unstable } from './renderTeachingPopoverCarouselNavButton';\nimport { useTeachingPopoverCarouselNavButtonStyles_unstable } from './useTeachingPopoverCarouselNavButtonStyles.styles';\nimport type { TeachingPopoverCarouselNavButtonProps } from './TeachingPopoverCarouselNavButton.types';\n\n/**\n * TeachingPopoverCarouselNavButton is a button to jump to a single page within TeachingPopoverCarousel\n *\n * It's value is injected via context and must be wrapped with a ValueIdContextProvider (automatically handled via TeachingPopoverCarouselNav)\n */\nexport const TeachingPopoverCarouselNavButton: ForwardRefComponent<TeachingPopoverCarouselNavButtonProps> =\n React.forwardRef((props, ref) => {\n const state = useTeachingPopoverCarouselNavButton_unstable(props, ref);\n\n useTeachingPopoverCarouselNavButtonStyles_unstable(state);\n\n return renderTeachingPopoverCarouselNavButton_unstable(state);\n }) as ForwardRefComponent<TeachingPopoverCarouselNavButtonProps>;\n\nTeachingPopoverCarouselNavButton.displayName = 'TeachingPopoverCarouselNavButton';\n"],"names":["React","useTeachingPopoverCarouselNavButton_unstable","renderTeachingPopoverCarouselNavButton_unstable","useTeachingPopoverCarouselNavButtonStyles_unstable","TeachingPopoverCarouselNavButton","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAE/B,SAASC,4CAA4C,QAAQ,wCAAwC;AACrG,SAASC,+CAA+C,QAAQ,2CAA2C;AAC3G,SAASC,kDAAkD,QAAQ,qDAAqD;AAGxH;;;;CAIC,GACD,OAAO,MAAMC,iDACXJ,MAAMK,UAAU,CAAC,CAACC,OAAOC;IACvB,MAAMC,QAAQP,6CAA6CK,OAAOC;IAElEJ,mDAAmDK;IAEnD,OAAON,gDAAgDM;AACzD,GAAiE;AAEnEJ,iCAAiCK,WAAW,GAAG"}
|
package/lib/components/TeachingPopoverCarouselNavButton/TeachingPopoverCarouselNavButton.types.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["TeachingPopoverCarouselNavButton.types.ts"],"sourcesContent":["import { ARIAButtonSlotProps } from '@fluentui/react-aria';\nimport { PopoverContextValue } from '@fluentui/react-popover';\nimport type { ComponentState, ComponentProps, Slot } from '@fluentui/react-utilities';\n\nexport type TeachingPopoverCarouselNavButtonSlots = {\n /**\n * ARIA compliant nav buttons used to jump to pages\n */\n root: NonNullable<Slot<ARIAButtonSlotProps<'a'>>>;\n};\n\n/**\n * TeachingPopoverCarouselNavButton Props\n */\nexport type TeachingPopoverCarouselNavButtonProps = ComponentProps<TeachingPopoverCarouselNavButtonSlots>;\n\n/**\n * TeachingPopoverCarouselNavButton State\n */\nexport type TeachingPopoverCarouselNavButtonState = ComponentState<TeachingPopoverCarouselNavButtonSlots> & {\n /**\n * Enables selection state control\n */\n isSelected?: boolean;\n} & Pick<PopoverContextValue, 'appearance'>;\n"],"names":[],"mappings":"AAAA,WAwB4C"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export * from './TeachingPopoverCarouselNavButton';
|
|
2
|
+
export * from './TeachingPopoverCarouselNavButton.types';
|
|
3
|
+
export * from './renderTeachingPopoverCarouselNavButton';
|
|
4
|
+
export * from './useTeachingPopoverCarouselNavButton';
|
|
5
|
+
export * from './useTeachingPopoverCarouselNavButtonStyles.styles';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["index.ts"],"sourcesContent":["export * from './TeachingPopoverCarouselNavButton';\nexport * from './TeachingPopoverCarouselNavButton.types';\nexport * from './renderTeachingPopoverCarouselNavButton';\nexport * from './useTeachingPopoverCarouselNavButton';\nexport * from './useTeachingPopoverCarouselNavButtonStyles.styles';\n"],"names":[],"mappings":"AAAA,cAAc,qCAAqC;AACnD,cAAc,2CAA2C;AACzD,cAAc,2CAA2C;AACzD,cAAc,wCAAwC;AACtD,cAAc,qDAAqD"}
|
package/lib/components/TeachingPopoverCarouselNavButton/renderTeachingPopoverCarouselNavButton.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jsx as _jsx } from "@fluentui/react-jsx-runtime/jsx-runtime";
|
|
2
|
+
import { assertSlots } from '@fluentui/react-utilities';
|
|
3
|
+
/**
|
|
4
|
+
* Render the final JSX of TeachingPopoverCarouselNavButton
|
|
5
|
+
*/ export const renderTeachingPopoverCarouselNavButton_unstable = (state)=>{
|
|
6
|
+
assertSlots(state);
|
|
7
|
+
return /*#__PURE__*/ _jsx(state.root, {});
|
|
8
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["renderTeachingPopoverCarouselNavButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type {\n TeachingPopoverCarouselNavButtonState,\n TeachingPopoverCarouselNavButtonSlots,\n} from './TeachingPopoverCarouselNavButton.types';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselNavButton\n */\nexport const renderTeachingPopoverCarouselNavButton_unstable = (state: TeachingPopoverCarouselNavButtonState) => {\n assertSlots<TeachingPopoverCarouselNavButtonSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderTeachingPopoverCarouselNavButton_unstable","state","root"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;AAMxD;;CAEC,GACD,OAAO,MAAMC,kDAAkD,CAACC;IAC9DF,YAAmDE;IAEnD,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
|
package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useARIAButtonProps } from '@fluentui/react-aria';
|
|
3
|
+
import { usePopoverContext_unstable } from '@fluentui/react-popover';
|
|
4
|
+
import { useTabsterAttributes } from '@fluentui/react-tabster';
|
|
5
|
+
import { getIntrinsicElementProps, isHTMLElement, slot, useEventCallback } from '@fluentui/react-utilities';
|
|
6
|
+
import { useCarouselContext_unstable } from '../TeachingPopoverCarousel/Carousel/CarouselContext';
|
|
7
|
+
import { useValueIdContext } from '../TeachingPopoverCarouselNav/valueIdContext';
|
|
8
|
+
/**
|
|
9
|
+
* Create the state required to render TeachingPopoverCarouselNavButton.
|
|
10
|
+
*
|
|
11
|
+
* The returned state can be modified with hooks such as useTeachingPopoverCarouselNavButtonStyles_unstable,
|
|
12
|
+
* before being passed to renderTeachingPopoverCarouselNavButton_unstable.
|
|
13
|
+
*
|
|
14
|
+
* @param props - props from this instance of TeachingPopoverCarouselNavButton
|
|
15
|
+
* @param ref - reference to root HTMLElement of TeachingPopoverCarouselNavButton
|
|
16
|
+
*/ export const useTeachingPopoverCarouselNavButton_unstable = (props, ref)=>{
|
|
17
|
+
const { onClick, as = 'a' } = props;
|
|
18
|
+
const value = useValueIdContext();
|
|
19
|
+
const appearance = usePopoverContext_unstable((context)=>context.appearance);
|
|
20
|
+
const selectPageByValue = useCarouselContext_unstable((c)=>c.selectPageByValue);
|
|
21
|
+
const isSelected = useCarouselContext_unstable((c)=>c.value === value);
|
|
22
|
+
const handleClick = useEventCallback((event)=>{
|
|
23
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(event);
|
|
24
|
+
if (!event.defaultPrevented && isHTMLElement(event.target)) {
|
|
25
|
+
selectPageByValue(event, value);
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
const defaultTabProps = useTabsterAttributes({
|
|
29
|
+
focusable: {
|
|
30
|
+
isDefault: isSelected
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
const _carouselButton = slot.always(getIntrinsicElementProps(as, useARIAButtonProps(props.as, props)), {
|
|
34
|
+
elementType: 'button',
|
|
35
|
+
defaultProps: {
|
|
36
|
+
ref: ref,
|
|
37
|
+
role: 'tab',
|
|
38
|
+
type: 'button',
|
|
39
|
+
...defaultTabProps
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
_carouselButton.onClick = handleClick;
|
|
43
|
+
const state = {
|
|
44
|
+
isSelected,
|
|
45
|
+
appearance,
|
|
46
|
+
components: {
|
|
47
|
+
root: 'button'
|
|
48
|
+
},
|
|
49
|
+
root: _carouselButton
|
|
50
|
+
};
|
|
51
|
+
return state;
|
|
52
|
+
};
|
package/lib/components/TeachingPopoverCarouselNavButton/useTeachingPopoverCarouselNavButton.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["useTeachingPopoverCarouselNavButton.tsx"],"sourcesContent":["import * as React from 'react';\nimport { ARIAButtonSlotProps, useARIAButtonProps } from '@fluentui/react-aria';\nimport { usePopoverContext_unstable } from '@fluentui/react-popover';\nimport { useTabsterAttributes } from '@fluentui/react-tabster';\nimport { getIntrinsicElementProps, isHTMLElement, slot, useEventCallback } from '@fluentui/react-utilities';\n\nimport type {\n TeachingPopoverCarouselNavButtonProps,\n TeachingPopoverCarouselNavButtonState,\n} from './TeachingPopoverCarouselNavButton.types';\nimport { useCarouselContext_unstable } from '../TeachingPopoverCarousel/Carousel/CarouselContext';\nimport { useValueIdContext } from '../TeachingPopoverCarouselNav/valueIdContext';\n\n/**\n * Create the state required to render TeachingPopoverCarouselNavButton.\n *\n * The returned state can be modified with hooks such as useTeachingPopoverCarouselNavButtonStyles_unstable,\n * before being passed to renderTeachingPopoverCarouselNavButton_unstable.\n *\n * @param props - props from this instance of TeachingPopoverCarouselNavButton\n * @param ref - reference to root HTMLElement of TeachingPopoverCarouselNavButton\n */\nexport const useTeachingPopoverCarouselNavButton_unstable = (\n props: TeachingPopoverCarouselNavButtonProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): TeachingPopoverCarouselNavButtonState => {\n const { onClick, as = 'a' } = props;\n\n const value = useValueIdContext();\n\n const appearance = usePopoverContext_unstable(context => context.appearance);\n const selectPageByValue = useCarouselContext_unstable(c => c.selectPageByValue);\n const isSelected = useCarouselContext_unstable(c => c.value === value);\n\n const handleClick: ARIAButtonSlotProps<'a'>['onClick'] = useEventCallback(event => {\n onClick?.(event);\n\n if (!event.defaultPrevented && isHTMLElement(event.target)) {\n selectPageByValue(event, value);\n }\n });\n\n const defaultTabProps = useTabsterAttributes({\n focusable: { isDefault: isSelected },\n });\n\n const _carouselButton = slot.always<ARIAButtonSlotProps<'a'>>(\n getIntrinsicElementProps(as, useARIAButtonProps(props.as, props)),\n {\n elementType: 'button',\n defaultProps: {\n ref: ref as React.Ref<HTMLButtonElement & HTMLAnchorElement>,\n role: 'tab',\n type: 'button',\n ...defaultTabProps,\n },\n },\n );\n\n _carouselButton.onClick = handleClick;\n\n const state: TeachingPopoverCarouselNavButtonState = {\n isSelected,\n appearance,\n components: {\n root: 'button',\n },\n root: _carouselButton,\n };\n\n return state;\n};\n"],"names":["React","useARIAButtonProps","usePopoverContext_unstable","useTabsterAttributes","getIntrinsicElementProps","isHTMLElement","slot","useEventCallback","useCarouselContext_unstable","useValueIdContext","useTeachingPopoverCarouselNavButton_unstable","props","ref","onClick","as","value","appearance","context","selectPageByValue","c","isSelected","handleClick","event","defaultPrevented","target","defaultTabProps","focusable","isDefault","_carouselButton","always","elementType","defaultProps","role","type","state","components","root"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAA8BC,kBAAkB,QAAQ,uBAAuB;AAC/E,SAASC,0BAA0B,QAAQ,0BAA0B;AACrE,SAASC,oBAAoB,QAAQ,0BAA0B;AAC/D,SAASC,wBAAwB,EAAEC,aAAa,EAAEC,IAAI,EAAEC,gBAAgB,QAAQ,4BAA4B;AAM5G,SAASC,2BAA2B,QAAQ,sDAAsD;AAClG,SAASC,iBAAiB,QAAQ,+CAA+C;AAEjF;;;;;;;;CAQC,GACD,OAAO,MAAMC,+CAA+C,CAC1DC,OACAC;IAEA,MAAM,EAAEC,OAAO,EAAEC,KAAK,GAAG,EAAE,GAAGH;IAE9B,MAAMI,QAAQN;IAEd,MAAMO,aAAad,2BAA2Be,CAAAA,UAAWA,QAAQD,UAAU;IAC3E,MAAME,oBAAoBV,4BAA4BW,CAAAA,IAAKA,EAAED,iBAAiB;IAC9E,MAAME,aAAaZ,4BAA4BW,CAAAA,IAAKA,EAAEJ,KAAK,KAAKA;IAEhE,MAAMM,cAAmDd,iBAAiBe,CAAAA;QACxET,oBAAAA,8BAAAA,QAAUS;QAEV,IAAI,CAACA,MAAMC,gBAAgB,IAAIlB,cAAciB,MAAME,MAAM,GAAG;YAC1DN,kBAAkBI,OAAOP;QAC3B;IACF;IAEA,MAAMU,kBAAkBtB,qBAAqB;QAC3CuB,WAAW;YAAEC,WAAWP;QAAW;IACrC;IAEA,MAAMQ,kBAAkBtB,KAAKuB,MAAM,CACjCzB,yBAAyBU,IAAIb,mBAAmBU,MAAMG,EAAE,EAAEH,SAC1D;QACEmB,aAAa;QACbC,cAAc;YACZnB,KAAKA;YACLoB,MAAM;YACNC,MAAM;YACN,GAAGR,eAAe;QACpB;IACF;IAGFG,gBAAgBf,OAAO,GAAGQ;IAE1B,MAAMa,QAA+C;QACnDd;QACAJ;QACAmB,YAAY;YACVC,MAAM;QACR;QACAA,MAAMR;IACR;IAEA,OAAOM;AACT,EAAE"}
|