@4alldigital/foundation-ui--core 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.txt +21 -0
- package/package.json +35 -0
- package/src/__mocks__/_examples/cnbc.ts +146 -0
- package/src/__mocks__/_examples/nrg.ts +222 -0
- package/src/__mocks__/empty-module.js +0 -0
- package/src/__mocks__/fileMock.js +3 -0
- package/src/__mocks__/fileTransformer.js +8 -0
- package/src/__mocks__/mockSearchData.js +511 -0
- package/src/__mocks__/nrglogo.svg +74 -0
- package/src/__mocks__/styleMock.js +3 -0
- package/src/__mocks__/tempPolyFills.js +5 -0
- package/src/components/Accordion/Accordion.stories.tsx +33 -0
- package/src/components/Accordion/Accordion.tsx +53 -0
- package/src/components/Accordion/Accordion.types.ts +8 -0
- package/src/components/Accordion/index.ts +1 -0
- package/src/components/AnimationCounter/AnimationCounter.stories.tsx +22 -0
- package/src/components/AnimationCounter/AnimationCounter.tsx +51 -0
- package/src/components/AnimationCounter/AnimationCounter.types.ts +10 -0
- package/src/components/AnimationCounter/index.ts +1 -0
- package/src/components/AnimationSet1/AnimationSet1.stories.tsx +36 -0
- package/src/components/AnimationSet1/AnimationSet1.tsx +107 -0
- package/src/components/AnimationSet1/AnimationSet1.types.ts +12 -0
- package/src/components/AnimationSet1/index.ts +1 -0
- package/src/components/Authenticator/Authenticator.stories.tsx +37 -0
- package/src/components/Authenticator/Authenticator.tsx +84 -0
- package/src/components/Authenticator/Authenticator.types.ts +7 -0
- package/src/components/Authenticator/index.ts +1 -0
- package/src/components/Avatar/Avatar.stories.tsx +26 -0
- package/src/components/Avatar/Avatar.tsx +88 -0
- package/src/components/Avatar/Avatar.types.ts +8 -0
- package/src/components/Avatar/index.ts +1 -0
- package/src/components/Banner/Banner.stories.tsx +59 -0
- package/src/components/Banner/Banner.tsx +60 -0
- package/src/components/Banner/Banner.types.ts +9 -0
- package/src/components/Banner/index.ts +1 -0
- package/src/components/Blockquote/Blockquote.stories.tsx +20 -0
- package/src/components/Blockquote/Blockquote.tsx +32 -0
- package/src/components/Blockquote/Blockquote.types.ts +8 -0
- package/src/components/Blockquote/index.ts +1 -0
- package/src/components/Button/Button.stories.tsx +50 -0
- package/src/components/Button/Button.tsx +117 -0
- package/src/components/Button/Button.types.ts +43 -0
- package/src/components/Button/index.ts +1 -0
- package/src/components/ButtonGroup/ButtonGroup.stories.tsx +59 -0
- package/src/components/ButtonGroup/ButtonGroup.tsx +35 -0
- package/src/components/ButtonGroup/ButtonGroup.types.ts +5 -0
- package/src/components/ButtonGroup/index.ts +1 -0
- package/src/components/Calendar/Calendar.stories.tsx +100 -0
- package/src/components/Calendar/Calendar.tsx +91 -0
- package/src/components/Calendar/Calendar.types.ts +10 -0
- package/src/components/Calendar/index.ts +2 -0
- package/src/components/Card/Card.stories.tsx +487 -0
- package/src/components/Card/Card.tsx +32 -0
- package/src/components/Card/Card.types.ts +79 -0
- package/src/components/Card/constants/index.ts +8 -0
- package/src/components/Card/index.ts +1 -0
- package/src/components/Card/types/CardBasic/CardBasic.tsx +262 -0
- package/src/components/Card/types/CardBasic/CardBasic.types.ts +7 -0
- package/src/components/Card/types/CardBasic/index.ts +1 -0
- package/src/components/Card/types/CardData/CardData.tsx +68 -0
- package/src/components/Card/types/CardData/CardData.types.ts +21 -0
- package/src/components/Card/types/CardData/index.ts +1 -0
- package/src/components/Card/types/CardHorz/CardHorz.tsx +80 -0
- package/src/components/Card/types/CardHorz/CardHorz.types.ts +8 -0
- package/src/components/Card/types/CardHorz/index.ts +1 -0
- package/src/components/Card/types/CardIcon/CardIcon.tsx +76 -0
- package/src/components/Card/types/CardIcon/CardIcon.types.ts +8 -0
- package/src/components/Card/types/CardIcon/index.ts +1 -0
- package/src/components/Card/types/CardMedia/CardMedia.tsx +277 -0
- package/src/components/Card/types/CardMedia/CardMedia.types.ts +5 -0
- package/src/components/Card/types/CardMedia/index.ts +1 -0
- package/src/components/Card/types/CardVideo/CardVideo.tsx +262 -0
- package/src/components/Card/types/CardVideo/CardVideo.types.ts +11 -0
- package/src/components/Card/types/CardVideo/index.ts +1 -0
- package/src/components/CardGrid/CardGrid.stories.tsx +122 -0
- package/src/components/CardGrid/CardGrid.tsx +25 -0
- package/src/components/CardGrid/CardGrid.types.ts +7 -0
- package/src/components/CardGrid/index.ts +1 -0
- package/src/components/Carousel/Carousel.stories.tsx +351 -0
- package/src/components/Carousel/Carousel.tsx +174 -0
- package/src/components/Carousel/Carousel.types.ts +32 -0
- package/src/components/Carousel/MIGRATION.md +156 -0
- package/src/components/Carousel/index.ts +1 -0
- package/src/components/Cart/Cart.stories.tsx +92 -0
- package/src/components/Cart/Cart.tsx +194 -0
- package/src/components/Cart/Cart.types.ts +4 -0
- package/src/components/Cart/index.ts +1 -0
- package/src/components/Checkbox/Checkbox.stories.tsx +18 -0
- package/src/components/Checkbox/Checkbox.tsx +38 -0
- package/src/components/Checkbox/Checkbox.types.ts +15 -0
- package/src/components/Checkbox/index.ts +1 -0
- package/src/components/Chip/Chip.stories.tsx +37 -0
- package/src/components/Chip/Chip.tsx +104 -0
- package/src/components/Chip/Chip.types.ts +13 -0
- package/src/components/Chip/index.ts +1 -0
- package/src/components/Collapsible/Collapsible.stories.tsx +139 -0
- package/src/components/Collapsible/Collapsible.tsx +75 -0
- package/src/components/Collapsible/Collapsible.types.ts +14 -0
- package/src/components/Collapsible/index.ts +3 -0
- package/src/components/Container/Container.stories.tsx +17 -0
- package/src/components/Container/Container.tsx +51 -0
- package/src/components/Container/Container.types.ts +17 -0
- package/src/components/Container/index.ts +1 -0
- package/src/components/ContentPageLayout/ContentPageLayout.stories.tsx +17 -0
- package/src/components/ContentPageLayout/ContentPageLayout.tsx +38 -0
- package/src/components/ContentPageLayout/ContentPageLayout.types.ts +17 -0
- package/src/components/ContentPageLayout/index.ts +1 -0
- package/src/components/ContentRowsLayout/ContentRowsLayout.stories.tsx +19 -0
- package/src/components/ContentRowsLayout/ContentRowsLayout.tsx +30 -0
- package/src/components/ContentRowsLayout/ContentRowsLayout.types.ts +15 -0
- package/src/components/ContentRowsLayout/index.ts +1 -0
- package/src/components/Copy/Copy.stories.tsx +28 -0
- package/src/components/Copy/Copy.tsx +43 -0
- package/src/components/Copy/Copy.types.tsx +53 -0
- package/src/components/Copy/index.tsx +1 -0
- package/src/components/DisplayHeading/DisplayHeading.stories.tsx +17 -0
- package/src/components/DisplayHeading/DisplayHeading.tsx +43 -0
- package/src/components/DisplayHeading/DisplayHeading.types.ts +8 -0
- package/src/components/DisplayHeading/index.ts +1 -0
- package/src/components/FileUpload/FileUpload.stories.tsx +18 -0
- package/src/components/FileUpload/FileUpload.tsx +41 -0
- package/src/components/FileUpload/FileUpload.types.ts +9 -0
- package/src/components/FileUpload/index.ts +1 -0
- package/src/components/Footer/Footer.stories.tsx +17 -0
- package/src/components/Footer/Footer.tsx +78 -0
- package/src/components/Footer/Footer.types.ts +4 -0
- package/src/components/Footer/index.ts +1 -0
- package/src/components/Form/Form.stories.tsx +81 -0
- package/src/components/Form/Form.tsx +98 -0
- package/src/components/Form/Form.types.ts +34 -0
- package/src/components/Form/index.ts +1 -0
- package/src/components/FormField/FormField.stories.tsx +205 -0
- package/src/components/FormField/FormField.tsx +258 -0
- package/src/components/FormField/FormField.types.ts +89 -0
- package/src/components/FormField/index.ts +1 -0
- package/src/components/FormSelect/FormSelect.stories.tsx +27 -0
- package/src/components/FormSelect/FormSelect.tsx +46 -0
- package/src/components/FormSelect/FormSelect.types.ts +45 -0
- package/src/components/FormSelect/index.ts +1 -0
- package/src/components/FullContentBackgroundImage/FullContentBackgroundImage.stories.tsx +18 -0
- package/src/components/FullContentBackgroundImage/FullContentBackgroundImage.tsx +26 -0
- package/src/components/FullContentBackgroundImage/FullContentBackgroundImage.types.ts +6 -0
- package/src/components/FullContentBackgroundImage/index.ts +1 -0
- package/src/components/FullScreenVideoModal/FullScreenVideoModal.stories.tsx +34 -0
- package/src/components/FullScreenVideoModal/FullScreenVideoModal.tsx +41 -0
- package/src/components/FullScreenVideoModal/FullScreenVideoModal.types.ts +9 -0
- package/src/components/FullScreenVideoModal/index.ts +1 -0
- package/src/components/Header/Header.stories.tsx +51 -0
- package/src/components/Header/Header.tsx +170 -0
- package/src/components/Header/Header.types.ts +11 -0
- package/src/components/Header/index.ts +1 -0
- package/src/components/Heading/Heading.stories.tsx +57 -0
- package/src/components/Heading/Heading.tsx +47 -0
- package/src/components/Heading/Heading.types.ts +35 -0
- package/src/components/Heading/index.ts +1 -0
- package/src/components/Hero/Hero.stories.tsx +17 -0
- package/src/components/Hero/Hero.tsx +28 -0
- package/src/components/Hero/Hero.types.ts +17 -0
- package/src/components/Hero/index.ts +1 -0
- package/src/components/Hr/Hr.stories.tsx +13 -0
- package/src/components/Hr/Hr.tsx +16 -0
- package/src/components/Hr/Hr.types.ts +3 -0
- package/src/components/Hr/index.ts +1 -0
- package/src/components/HtmlContent/HtmlContent.stories.tsx +29 -0
- package/src/components/HtmlContent/HtmlContent.tsx +36 -0
- package/src/components/HtmlContent/HtmlContent.types.ts +6 -0
- package/src/components/HtmlContent/index.ts +1 -0
- package/src/components/Icon/Icon.stories.tsx +26 -0
- package/src/components/Icon/Icon.tsx +24 -0
- package/src/components/Icon/Icon.types.ts +8 -0
- package/src/components/Icon/index.ts +2 -0
- package/src/components/Image/Image.stories.tsx +32 -0
- package/src/components/Image/Image.tsx +71 -0
- package/src/components/Image/Image.types.ts +20 -0
- package/src/components/Image/index.ts +1 -0
- package/src/components/Label/Label.stories.tsx +18 -0
- package/src/components/Label/Label.tsx +17 -0
- package/src/components/Label/Label.types.ts +9 -0
- package/src/components/Label/index.ts +1 -0
- package/src/components/Link/Link.stories.tsx +25 -0
- package/src/components/Link/Link.tsx +85 -0
- package/src/components/Link/Link.types.ts +14 -0
- package/src/components/Link/index.ts +1 -0
- package/src/components/List/List.stories.tsx +38 -0
- package/src/components/List/List.tsx +17 -0
- package/src/components/List/List.types.ts +27 -0
- package/src/components/List/index.ts +1 -0
- package/src/components/ListItem/ListItem.stories.tsx +61 -0
- package/src/components/ListItem/ListItem.tsx +53 -0
- package/src/components/ListItem/ListItem.types.ts +10 -0
- package/src/components/ListItem/index.ts +1 -0
- package/src/components/Loader/Loader.stories.tsx +17 -0
- package/src/components/Loader/Loader.tsx +34 -0
- package/src/components/Loader/Loader.types.ts +5 -0
- package/src/components/Loader/index.ts +1 -0
- package/src/components/Logo/Logo.stories.tsx +17 -0
- package/src/components/Logo/Logo.tsx +17 -0
- package/src/components/Logo/Logo.types.ts +6 -0
- package/src/components/Logo/index.ts +1 -0
- package/src/components/Menu/Menu.stories.tsx +37 -0
- package/src/components/Menu/Menu.tsx +45 -0
- package/src/components/Menu/Menu.types.ts +15 -0
- package/src/components/Menu/index.ts +1 -0
- package/src/components/Notice/Notice.stories.tsx +49 -0
- package/src/components/Notice/Notice.tsx +63 -0
- package/src/components/Notice/Notice.types.ts +11 -0
- package/src/components/Notice/index.ts +1 -0
- package/src/components/OTPInput/OTPInput.stories.tsx +18 -0
- package/src/components/OTPInput/OTPInput.tsx +80 -0
- package/src/components/OTPInput/OTPInput.types.ts +8 -0
- package/src/components/OTPInput/index.ts +1 -0
- package/src/components/PanelCards/PanelCards.stories.tsx +125 -0
- package/src/components/PanelCards/PanelCards.tsx +81 -0
- package/src/components/PanelCards/PanelCards.types.ts +11 -0
- package/src/components/PanelCards/index.ts +1 -0
- package/src/components/PanelCustom/PanelCustom.stories.tsx +18 -0
- package/src/components/PanelCustom/PanelCustom.tsx +39 -0
- package/src/components/PanelCustom/PanelCustom.types.ts +20 -0
- package/src/components/PanelCustom/index.ts +1 -0
- package/src/components/PanelFeature/PanelFeature.stories.tsx +46 -0
- package/src/components/PanelFeature/PanelFeature.tsx +83 -0
- package/src/components/PanelFeature/PanelFeature.types.ts +27 -0
- package/src/components/PanelFeature/index.ts +1 -0
- package/src/components/PanelHero/PanelHero.stories.tsx +126 -0
- package/src/components/PanelHero/PanelHero.tsx +184 -0
- package/src/components/PanelHero/PanelHero.types.ts +19 -0
- package/src/components/PanelHero/index.ts +1 -0
- package/src/components/PanelIntro/PanelIntro.stories.tsx +38 -0
- package/src/components/PanelIntro/PanelIntro.tsx +139 -0
- package/src/components/PanelIntro/PanelIntro.types.ts +19 -0
- package/src/components/PanelIntro/index.ts +1 -0
- package/src/components/PanelProduct/PanelProduct.stories.tsx +24 -0
- package/src/components/PanelProduct/PanelProduct.tsx +87 -0
- package/src/components/PanelProduct/PanelProduct.types.ts +14 -0
- package/src/components/PanelProduct/index.ts +1 -0
- package/src/components/PanelScroller/PanelScroller.stories.tsx +81 -0
- package/src/components/PanelScroller/PanelScroller.tsx +58 -0
- package/src/components/PanelScroller/PanelScroller.types.ts +8 -0
- package/src/components/PanelScroller/index.ts +1 -0
- package/src/components/PanelVideo/PanelVideo.stories.tsx +42 -0
- package/src/components/PanelVideo/PanelVideo.tsx +81 -0
- package/src/components/PanelVideo/PanelVideo.types.ts +11 -0
- package/src/components/PanelVideo/index.ts +1 -0
- package/src/components/Radio/Radio.stories.tsx +24 -0
- package/src/components/Radio/Radio.tsx +44 -0
- package/src/components/Radio/Radio.types.ts +13 -0
- package/src/components/Radio/index.ts +1 -0
- package/src/components/Schedule/Schedule.stories.tsx +96 -0
- package/src/components/Schedule/Schedule.tsx +118 -0
- package/src/components/Schedule/Schedule.types.ts +64 -0
- package/src/components/Schedule/index.ts +1 -0
- package/src/components/ScheduleItem/ScheduleItem.stories.tsx +21 -0
- package/src/components/ScheduleItem/ScheduleItem.tsx +77 -0
- package/src/components/ScheduleItem/ScheduleItem.types.ts +8 -0
- package/src/components/ScheduleItem/index.ts +1 -0
- package/src/components/Screen/Screen.stories.tsx +27 -0
- package/src/components/Screen/Screen.tsx +63 -0
- package/src/components/Screen/Screen.types.ts +16 -0
- package/src/components/Screen/index.ts +1 -0
- package/src/components/ShadcnButton/ShadcnButton.tsx +57 -0
- package/src/components/ShadcnButton/index.ts +2 -0
- package/src/components/ShadcnCarousel/ShadcnCarousel.tsx +261 -0
- package/src/components/ShadcnCarousel/index.ts +9 -0
- package/src/components/Share/Share.stories.tsx +17 -0
- package/src/components/Share/Share.tsx +60 -0
- package/src/components/Share/Share.types.ts +12 -0
- package/src/components/Share/index.ts +1 -0
- package/src/components/SubscriptionManager/SubscriptionManager.stories.tsx +177 -0
- package/src/components/SubscriptionManager/SubscriptionManager.tsx +369 -0
- package/src/components/SubscriptionManager/SubscriptionManager.types.ts +36 -0
- package/src/components/SubscriptionManager/index.ts +1 -0
- package/src/components/Switch/Switch.stories.tsx +20 -0
- package/src/components/Switch/Switch.tsx +30 -0
- package/src/components/Switch/Switch.types.ts +7 -0
- package/src/components/Switch/index.ts +1 -0
- package/src/components/Tabs/Tabs.stories.tsx +34 -0
- package/src/components/Tabs/Tabs.tsx +42 -0
- package/src/components/Tabs/Tabs.types.ts +8 -0
- package/src/components/Tabs/index.ts +1 -0
- package/src/components/TextInput/TextInput.stories.tsx +18 -0
- package/src/components/TextInput/TextInput.tsx +78 -0
- package/src/components/TextInput/TextInput.types.ts +81 -0
- package/src/components/TextInput/index.ts +1 -0
- package/src/components/Video/Video.stories.tsx +75 -0
- package/src/components/Video/Video.tsx +280 -0
- package/src/components/Video/Video.types.ts +147 -0
- package/src/components/Video/index.ts +1 -0
- package/src/components/VisitUs/VisitUs.stories.tsx +32 -0
- package/src/components/VisitUs/VisitUs.tsx +56 -0
- package/src/components/VisitUs/VisitUs.types.ts +13 -0
- package/src/components/VisitUs/index.ts +1 -0
- package/src/components/index.ts +143 -0
- package/src/constants/index.ts +6 -0
- package/src/context/Amplify/index.tsx +65 -0
- package/src/context/App/index.tsx +93 -0
- package/src/context/Cart/index.tsx +64 -0
- package/src/context/ExampleContext/index.tsx +34 -0
- package/src/context/Theme/index.tsx +37 -0
- package/src/context/index.ts +18 -0
- package/src/features/Search/Search.stories.tsx +395 -0
- package/src/features/Search/Search.tsx +204 -0
- package/src/features/Search/Search.types.ts +41 -0
- package/src/features/Search/config/config-helper.ts +219 -0
- package/src/features/Search/index.ts +1 -0
- package/src/features/Search/view-helpers/appendClassName.ts +14 -0
- package/src/features/Search/view-helpers/formatResult.ts +97 -0
- package/src/features/Search/view-helpers/getFilterValueDisplay.ts +10 -0
- package/src/features/Search/view-helpers/getUrlSanitizer.ts +23 -0
- package/src/features/Search/view-helpers/index.ts +4 -0
- package/src/features/Search/views/Layout/Layout.tsx +50 -0
- package/src/features/Search/views/Layout/Layout.types.ts +13 -0
- package/src/features/Search/views/Layout/index.ts +1 -0
- package/src/features/Search/views/MultiCheckboxFacet/MultiCheckboxFacet.tsx +85 -0
- package/src/features/Search/views/MultiCheckboxFacet/MultiCheckboxFacet.types.ts +5 -0
- package/src/features/Search/views/MultiCheckboxFacet/index.ts +1 -0
- package/src/features/Search/views/Paging/Paging.tsx +35 -0
- package/src/features/Search/views/Paging/Paging.types.ts +24 -0
- package/src/features/Search/views/Paging/index.ts +1 -0
- package/src/features/Search/views/PagingInfo/PagingInfo.tsx +34 -0
- package/src/features/Search/views/PagingInfo/PagingInfo.types.ts +26 -0
- package/src/features/Search/views/PagingInfo/index.ts +1 -0
- package/src/features/Search/views/Result/Result.tsx +84 -0
- package/src/features/Search/views/Result/Result.types.ts +47 -0
- package/src/features/Search/views/Result/index.ts +1 -0
- package/src/features/Search/views/Results/Results.tsx +16 -0
- package/src/features/Search/views/Results/Results.types.ts +24 -0
- package/src/features/Search/views/Results/index.ts +1 -0
- package/src/features/Search/views/ResultsPerPage/ResultsPerPage.tsx +32 -0
- package/src/features/Search/views/ResultsPerPage/ResultsPerPage.types.ts +26 -0
- package/src/features/Search/views/ResultsPerPage/index.ts +1 -0
- package/src/features/Search/views/SearchBox/SearchBox.tsx +51 -0
- package/src/features/Search/views/SearchBox/SearchBox.types.ts +10 -0
- package/src/features/Search/views/SearchBox/index.ts +1 -0
- package/src/features/Search/views/Sidebar/Sidebar.tsx +14 -0
- package/src/features/Search/views/Sidebar/Sidebar.types.ts +3 -0
- package/src/features/Search/views/Sidebar/index.ts +1 -0
- package/src/features/Search/views/SingleLinksFacet/SingleLinksFacet.tsx +62 -0
- package/src/features/Search/views/SingleLinksFacet/SingleLinksFacet.types.ts +5 -0
- package/src/features/Search/views/SingleLinksFacet/index.ts +1 -0
- package/src/features/Search/views/SingleSelectFacet/SingleSelectFacet.tsx +34 -0
- package/src/features/Search/views/SingleSelectFacet/SingleSelectFacet.types.ts +5 -0
- package/src/features/Search/views/SingleSelectFacet/index.ts +1 -0
- package/src/features/Search/views/Sorting/Sorting.tsx +24 -0
- package/src/features/Search/views/Sorting/Sorting.types.ts +25 -0
- package/src/features/Search/views/Sorting/index.ts +1 -0
- package/src/features/index.ts +11 -0
- package/src/forms/ForgotPasswordForm/ForgotPasswordForm.stories.tsx +19 -0
- package/src/forms/ForgotPasswordForm/ForgotPasswordForm.tsx +28 -0
- package/src/forms/ForgotPasswordForm/ForgotPasswordForm.types.ts +3 -0
- package/src/forms/ForgotPasswordForm/index.ts +1 -0
- package/src/forms/LoginForm/LoginForm.stories.tsx +67 -0
- package/src/forms/LoginForm/LoginForm.tsx +112 -0
- package/src/forms/LoginForm/LoginForm.types.ts +7 -0
- package/src/forms/LoginForm/index.ts +1 -0
- package/src/forms/ProfileForm/ProfileForm.stories.tsx +23 -0
- package/src/forms/ProfileForm/ProfileForm.tsx +40 -0
- package/src/forms/ProfileForm/ProfileForm.types.ts +6 -0
- package/src/forms/ProfileForm/index.ts +1 -0
- package/src/forms/PromoCodeForm/PromoCodeForm.stories.tsx +19 -0
- package/src/forms/PromoCodeForm/PromoCodeForm.tsx +22 -0
- package/src/forms/PromoCodeForm/PromoCodeForm.types.ts +4 -0
- package/src/forms/PromoCodeForm/index.ts +1 -0
- package/src/forms/RegisterForm/RegisterForm.stories.tsx +85 -0
- package/src/forms/RegisterForm/RegisterForm.tsx +108 -0
- package/src/forms/RegisterForm/RegisterForm.types.ts +6 -0
- package/src/forms/RegisterForm/index.ts +1 -0
- package/src/forms/ResetPasswordAuthForm/ResetPasswordAuthForm.stories.tsx +23 -0
- package/src/forms/ResetPasswordAuthForm/ResetPasswordAuthForm.tsx +39 -0
- package/src/forms/ResetPasswordAuthForm/ResetPasswordAuthForm.types.ts +3 -0
- package/src/forms/ResetPasswordAuthForm/index.ts +1 -0
- package/src/forms/ResetPasswordForm/ResetPasswordForm.stories.tsx +23 -0
- package/src/forms/ResetPasswordForm/ResetPasswordForm.tsx +30 -0
- package/src/forms/ResetPasswordForm/ResetPasswordForm.types.ts +3 -0
- package/src/forms/ResetPasswordForm/index.ts +1 -0
- package/src/forms/SubscriptionForm/SubscriptionForm.stories.tsx +31 -0
- package/src/forms/SubscriptionForm/SubscriptionForm.tsx +46 -0
- package/src/forms/SubscriptionForm/SubscriptionForm.types.ts +6 -0
- package/src/forms/SubscriptionForm/index.ts +1 -0
- package/src/forms/constants/index.ts +13 -0
- package/src/forms/index.ts +17 -0
- package/src/forms/validations/index.ts +39 -0
- package/src/hooks/index.ts +2 -0
- package/src/hooks/useLanguage.ts +18 -0
- package/src/hooks/useTheme.ts +6 -0
- package/src/index.ts +8 -0
- package/src/react-app-env.d.ts +1 -0
- package/src/setupTests.ts +5 -0
- package/src/templates/AccountScreen/AccountScreen.stories.tsx +67 -0
- package/src/templates/AccountScreen/AccountScreen.tsx +78 -0
- package/src/templates/AccountScreen/AccountScreen.types.ts +31 -0
- package/src/templates/AccountScreen/index.ts +1 -0
- package/src/templates/AuthScreen/AuthScreen.stories.tsx +33 -0
- package/src/templates/AuthScreen/AuthScreen.tsx +21 -0
- package/src/templates/AuthScreen/AuthScreen.types.ts +8 -0
- package/src/templates/AuthScreen/index.ts +1 -0
- package/src/templates/CardGridScreen/CardGridScreen.stories.tsx +95 -0
- package/src/templates/CardGridScreen/CardGridScreen.tsx +43 -0
- package/src/templates/CardGridScreen/CardGridScreen.types.ts +11 -0
- package/src/templates/CardGridScreen/index.ts +1 -0
- package/src/templates/CatalogueScreen/CatalogueScreen.stories.tsx +31 -0
- package/src/templates/CatalogueScreen/CatalogueScreen.tsx +21 -0
- package/src/templates/CatalogueScreen/CatalogueScreen.types.ts +8 -0
- package/src/templates/CatalogueScreen/index.ts +1 -0
- package/src/templates/ChallengeLibraryScreen/ChallengeLibraryScreen.stories.tsx +171 -0
- package/src/templates/ChallengeLibraryScreen/ChallengeLibraryScreen.tsx +36 -0
- package/src/templates/ChallengeLibraryScreen/ChallengeLibraryScreen.types.ts +9 -0
- package/src/templates/ChallengeLibraryScreen/index.ts +1 -0
- package/src/templates/ChallengeScreen/ChallengeScreen.stories.tsx +65 -0
- package/src/templates/ChallengeScreen/ChallengeScreen.tsx +88 -0
- package/src/templates/ChallengeScreen/ChallengeScreen.types.ts +22 -0
- package/src/templates/ChallengeScreen/index.ts +1 -0
- package/src/templates/ContentScreen/ContentScreen.stories.tsx +71 -0
- package/src/templates/ContentScreen/ContentScreen.tsx +55 -0
- package/src/templates/ContentScreen/ContentScreen.types.ts +9 -0
- package/src/templates/ContentScreen/index.ts +1 -0
- package/src/templates/DashboardScreen/DashboardScreen.stories.tsx +490 -0
- package/src/templates/DashboardScreen/DashboardScreen.tsx +156 -0
- package/src/templates/DashboardScreen/DashboardScreen.types.ts +28 -0
- package/src/templates/DashboardScreen/index.ts +1 -0
- package/src/templates/FAQScreen/FAQScreen.stories.tsx +278 -0
- package/src/templates/FAQScreen/FAQScreen.tsx +32 -0
- package/src/templates/FAQScreen/FAQScreen.types.ts +14 -0
- package/src/templates/FAQScreen/index.ts +1 -0
- package/src/templates/HomeScreen/HomeScreen.stories.tsx +315 -0
- package/src/templates/HomeScreen/HomeScreen.tsx +50 -0
- package/src/templates/HomeScreen/HomeScreen.types.ts +23 -0
- package/src/templates/HomeScreen/index.ts +1 -0
- package/src/templates/LogoutScreen/LogoutScreen.stories.tsx +20 -0
- package/src/templates/LogoutScreen/LogoutScreen.tsx +25 -0
- package/src/templates/LogoutScreen/LogoutScreen.types.ts +4 -0
- package/src/templates/LogoutScreen/index.ts +1 -0
- package/src/templates/MenuScreen/MenuScreen.stories.tsx +36 -0
- package/src/templates/MenuScreen/MenuScreen.tsx +32 -0
- package/src/templates/MenuScreen/MenuScreen.types.ts +11 -0
- package/src/templates/MenuScreen/index.ts +1 -0
- package/src/templates/NotFoundScreen/NotFoundScreen.stories.tsx +20 -0
- package/src/templates/NotFoundScreen/NotFoundScreen.tsx +31 -0
- package/src/templates/NotFoundScreen/NotFoundScreen.types.ts +5 -0
- package/src/templates/NotFoundScreen/index.ts +1 -0
- package/src/templates/PasswordResetAuthScreen/PasswordResetAuthScreen.stories.tsx +27 -0
- package/src/templates/PasswordResetAuthScreen/PasswordResetAuthScreen.tsx +20 -0
- package/src/templates/PasswordResetAuthScreen/PasswordResetAuthScreen.types.ts +6 -0
- package/src/templates/PasswordResetAuthScreen/index.ts +1 -0
- package/src/templates/PasswordResetScreen/PasswordResetScreen.stories.tsx +22 -0
- package/src/templates/PasswordResetScreen/PasswordResetScreen.tsx +19 -0
- package/src/templates/PasswordResetScreen/PasswordResetScreen.types.ts +6 -0
- package/src/templates/PasswordResetScreen/index.ts +1 -0
- package/src/templates/ProfileScreen/ProfileScreen.stories.tsx +41 -0
- package/src/templates/ProfileScreen/ProfileScreen.tsx +30 -0
- package/src/templates/ProfileScreen/ProfileScreen.types.ts +24 -0
- package/src/templates/ProfileScreen/index.ts +1 -0
- package/src/templates/ScheduleScreen/ScheduleScreen.stories.tsx +174 -0
- package/src/templates/ScheduleScreen/ScheduleScreen.tsx +29 -0
- package/src/templates/ScheduleScreen/ScheduleScreen.types.ts +9 -0
- package/src/templates/ScheduleScreen/index.ts +1 -0
- package/src/templates/SubscriptionScreen/SubscriptionScreen.stories.tsx +98 -0
- package/src/templates/SubscriptionScreen/SubscriptionScreen.tsx +49 -0
- package/src/templates/SubscriptionScreen/SubscriptionScreen.types.ts +28 -0
- package/src/templates/SubscriptionScreen/index.ts +1 -0
- package/src/templates/WorkoutScreen/WorkoutScreen.stories.tsx +173 -0
- package/src/templates/WorkoutScreen/WorkoutScreen.tsx +230 -0
- package/src/templates/WorkoutScreen/WorkoutScreen.types.ts +34 -0
- package/src/templates/WorkoutScreen/index.ts +1 -0
- package/src/templates/index.ts +40 -0
- package/src/translations/en.ts +777 -0
- package/src/translations/fr.ts +182 -0
- package/src/translations/index.ts +2 -0
- package/src/utils/htmlParser/index.tsx +22 -0
- package/src/utils/index.ts +38 -0
- package/src/utils/parseDuration/index.ts +94 -0
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/nextjs';
|
|
2
|
+
import FAQScreen from '.';
|
|
3
|
+
import { formatFaqs } from '@techstuff-dev/foundation-api-utils';
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof FAQScreen> = {
|
|
6
|
+
title: 'TEMPLATES/FAQScreen',
|
|
7
|
+
component: FAQScreen,
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
type Story = StoryObj<typeof FAQScreen>;
|
|
11
|
+
|
|
12
|
+
const ESFAQS = [
|
|
13
|
+
{
|
|
14
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
15
|
+
_id: 'entity:node/354:en',
|
|
16
|
+
_score: null,
|
|
17
|
+
_source: {
|
|
18
|
+
_language: 'en',
|
|
19
|
+
answer: [
|
|
20
|
+
'Video On Demand Classes have been pre-recorded, whereas Live Streamed classes are real-time classes live streamed straight to you.',
|
|
21
|
+
],
|
|
22
|
+
created: [1619874383],
|
|
23
|
+
title: ['How are videos on-demand different from live streamed classes?'],
|
|
24
|
+
updated: [1684101872],
|
|
25
|
+
uuid: ['c63e11dc-c4c7-444f-97a7-bbedf6afce26'],
|
|
26
|
+
},
|
|
27
|
+
sort: [1684101872000],
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
31
|
+
_id: 'entity:node/355:en',
|
|
32
|
+
_score: null,
|
|
33
|
+
_source: {
|
|
34
|
+
_language: 'en',
|
|
35
|
+
answer: [
|
|
36
|
+
'Not at all! Our NRG barrebody classes are low impact, and safe for all fitness levels. Simply listen to your body and go for it.',
|
|
37
|
+
],
|
|
38
|
+
created: [1619874477],
|
|
39
|
+
title: ['Do I need any ballet or Pilates experience to join the classes?'],
|
|
40
|
+
updated: [1641655486],
|
|
41
|
+
uuid: ['444571a9-a3fd-4e7d-aae5-92ed18130e8f'],
|
|
42
|
+
},
|
|
43
|
+
sort: [1641655486000],
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
47
|
+
_id: 'entity:node/357:en',
|
|
48
|
+
_score: null,
|
|
49
|
+
_source: {
|
|
50
|
+
_language: 'en',
|
|
51
|
+
answer: [
|
|
52
|
+
'Comfortable clothing. A low impact sports bra should provide adequate support as all our classes are low-impact. We recommend you stay barefoot or wear grippy socks. Some classes such as dance cardio and cardio can be done wearing trainers of you wish.',
|
|
53
|
+
],
|
|
54
|
+
created: [1619874677],
|
|
55
|
+
title: ['What shall I wear?'],
|
|
56
|
+
updated: [1641655486],
|
|
57
|
+
uuid: ['806da26b-7406-43d2-8459-5474073e7aec'],
|
|
58
|
+
},
|
|
59
|
+
sort: [1641655486000],
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
63
|
+
_id: 'entity:node/360:en',
|
|
64
|
+
_score: null,
|
|
65
|
+
_source: {
|
|
66
|
+
_language: 'en',
|
|
67
|
+
answer: ['You need to subscribed to the app and you are ready to go. Just pick your class and get started.'],
|
|
68
|
+
created: [1619874835],
|
|
69
|
+
title: ['How do I get access to on-demand barre classes on the platform?'],
|
|
70
|
+
updated: [1641655486],
|
|
71
|
+
uuid: ['987c5322-984e-44b8-88e1-b4e80dd88e0c'],
|
|
72
|
+
},
|
|
73
|
+
sort: [1641655486000],
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
77
|
+
_id: 'entity:node/361:en',
|
|
78
|
+
_score: null,
|
|
79
|
+
_source: {
|
|
80
|
+
_language: 'en',
|
|
81
|
+
answer: ['The videos on our platform allow you to pick to play the class with or without music.'],
|
|
82
|
+
created: [1619874869],
|
|
83
|
+
title: ['What about music?'],
|
|
84
|
+
updated: [1641655486],
|
|
85
|
+
uuid: ['9421bd0c-b255-4cca-a9c2-b8692bd0a505'],
|
|
86
|
+
},
|
|
87
|
+
sort: [1641655486000],
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
91
|
+
_id: 'entity:node/358:en',
|
|
92
|
+
_score: null,
|
|
93
|
+
_source: {
|
|
94
|
+
_language: 'en',
|
|
95
|
+
answer: [
|
|
96
|
+
'The length of our On Demand workouts range from 5 minutes to a full hour. The most popular format is the 30mn blast session.',
|
|
97
|
+
],
|
|
98
|
+
created: [1619874764],
|
|
99
|
+
title: ['How long are the classes?'],
|
|
100
|
+
updated: [1641655486],
|
|
101
|
+
uuid: ['8436eb10-a5a6-4f5e-a07f-281e9ea77bce'],
|
|
102
|
+
},
|
|
103
|
+
sort: [1641655486000],
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
107
|
+
_id: 'entity:node/356:en',
|
|
108
|
+
_score: null,
|
|
109
|
+
_ignored: ['answer.keyword'],
|
|
110
|
+
_source: {
|
|
111
|
+
_language: 'en',
|
|
112
|
+
answer: [
|
|
113
|
+
'All our classes can be done without any equipment at all, although some of the workouts will be more beneficial with props, but you will need: - Mat / carpeted floor - Barre / chair / table / wall Depending on the class you wish to follow, it will say which of the followings you need: - Pilates ball - Resistance loop band / theraband - set of small weights - yoga block',
|
|
114
|
+
],
|
|
115
|
+
created: [1619874505],
|
|
116
|
+
title: ['Do I need any equipment?'],
|
|
117
|
+
updated: [1641655486],
|
|
118
|
+
uuid: ['6c3023f7-7281-46e9-9801-77eb7c1ac282'],
|
|
119
|
+
},
|
|
120
|
+
sort: [1641655486000],
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
124
|
+
_id: 'entity:node/359:en',
|
|
125
|
+
_score: null,
|
|
126
|
+
_source: {
|
|
127
|
+
_language: 'en',
|
|
128
|
+
answer: [
|
|
129
|
+
'The live streamed class is PS4.85 per class, the subscription to the on-demand platform is PS4.50 per month.',
|
|
130
|
+
],
|
|
131
|
+
created: [1619874798],
|
|
132
|
+
title: ['What is the cost of the live streamed class / on-demand subscription?'],
|
|
133
|
+
updated: [1641655486],
|
|
134
|
+
uuid: ['73de1ff1-5ef0-4c66-99aa-d983101e512c'],
|
|
135
|
+
},
|
|
136
|
+
sort: [1641655486000],
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
140
|
+
_id: 'entity:node/354:en',
|
|
141
|
+
_score: null,
|
|
142
|
+
_source: {
|
|
143
|
+
_language: 'en',
|
|
144
|
+
answer: [
|
|
145
|
+
'Video On Demand Classes have been pre-recorded, whereas Live Streamed classes are real-time classes live streamed straight to you.',
|
|
146
|
+
],
|
|
147
|
+
created: [1619874383],
|
|
148
|
+
title: ['How are videos on-demand different from live streamed classes?'],
|
|
149
|
+
updated: [1684101872],
|
|
150
|
+
uuid: ['c63e11dc-c4c7-444f-97a7-bbedf6afce26'],
|
|
151
|
+
},
|
|
152
|
+
sort: [1684101872000],
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
156
|
+
_id: 'entity:node/355:en',
|
|
157
|
+
_score: null,
|
|
158
|
+
_source: {
|
|
159
|
+
_language: 'en',
|
|
160
|
+
answer: [
|
|
161
|
+
'Not at all! Our NRG barrebody classes are low impact, and safe for all fitness levels. Simply listen to your body and go for it.',
|
|
162
|
+
],
|
|
163
|
+
created: [1619874477],
|
|
164
|
+
title: ['Do I need any ballet or Pilates experience to join the classes?'],
|
|
165
|
+
updated: [1641655486],
|
|
166
|
+
uuid: ['444571a9-a3fd-4e7d-aae5-92ed18130e8f'],
|
|
167
|
+
},
|
|
168
|
+
sort: [1641655486000],
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
172
|
+
_id: 'entity:node/357:en',
|
|
173
|
+
_score: null,
|
|
174
|
+
_source: {
|
|
175
|
+
_language: 'en',
|
|
176
|
+
answer: [
|
|
177
|
+
'Comfortable clothing. A low impact sports bra should provide adequate support as all our classes are low-impact. We recommend you stay barefoot or wear grippy socks. Some classes such as dance cardio and cardio can be done wearing trainers of you wish.',
|
|
178
|
+
],
|
|
179
|
+
created: [1619874677],
|
|
180
|
+
title: ['What shall I wear?'],
|
|
181
|
+
updated: [1641655486],
|
|
182
|
+
uuid: ['806da26b-7406-43d2-8459-5474073e7aec'],
|
|
183
|
+
},
|
|
184
|
+
sort: [1641655486000],
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
188
|
+
_id: 'entity:node/360:en',
|
|
189
|
+
_score: null,
|
|
190
|
+
_source: {
|
|
191
|
+
_language: 'en',
|
|
192
|
+
answer: ['You need to subscribed to the app and you are ready to go. Just pick your class and get started.'],
|
|
193
|
+
created: [1619874835],
|
|
194
|
+
title: ['How do I get access to on-demand barre classes on the platform?'],
|
|
195
|
+
updated: [1641655486],
|
|
196
|
+
uuid: ['987c5322-984e-44b8-88e1-b4e80dd88e0c'],
|
|
197
|
+
},
|
|
198
|
+
sort: [1641655486000],
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
202
|
+
_id: 'entity:node/361:en',
|
|
203
|
+
_score: null,
|
|
204
|
+
_source: {
|
|
205
|
+
_language: 'en',
|
|
206
|
+
answer: ['The videos on our platform allow you to pick to play the class with or without music.'],
|
|
207
|
+
created: [1619874869],
|
|
208
|
+
title: ['What about music?'],
|
|
209
|
+
updated: [1641655486],
|
|
210
|
+
uuid: ['9421bd0c-b255-4cca-a9c2-b8692bd0a505'],
|
|
211
|
+
},
|
|
212
|
+
sort: [1641655486000],
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
216
|
+
_id: 'entity:node/358:en',
|
|
217
|
+
_score: null,
|
|
218
|
+
_source: {
|
|
219
|
+
_language: 'en',
|
|
220
|
+
answer: [
|
|
221
|
+
'The length of our On Demand workouts range from 5 minutes to a full hour. The most popular format is the 30mn blast session.',
|
|
222
|
+
],
|
|
223
|
+
created: [1619874764],
|
|
224
|
+
title: ['How long are the classes?'],
|
|
225
|
+
updated: [1641655486],
|
|
226
|
+
uuid: ['8436eb10-a5a6-4f5e-a07f-281e9ea77bce'],
|
|
227
|
+
},
|
|
228
|
+
sort: [1641655486000],
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
232
|
+
_id: 'entity:node/356:en',
|
|
233
|
+
_score: null,
|
|
234
|
+
_ignored: ['answer.keyword'],
|
|
235
|
+
_source: {
|
|
236
|
+
_language: 'en',
|
|
237
|
+
answer: [
|
|
238
|
+
'All our classes can be done without any equipment at all, although some of the workouts will be more beneficial with props, but you will need: - Mat / carpeted floor - Barre / chair / table / wall Depending on the class you wish to follow, it will say which of the followings you need: - Pilates ball - Resistance loop band / theraband - set of small weights - yoga block',
|
|
239
|
+
],
|
|
240
|
+
created: [1619874505],
|
|
241
|
+
title: ['Do I need any equipment?'],
|
|
242
|
+
updated: [1641655486],
|
|
243
|
+
uuid: ['6c3023f7-7281-46e9-9801-77eb7c1ac282'],
|
|
244
|
+
},
|
|
245
|
+
sort: [1641655486000],
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
_index: 'elasticsearch_index_nrgprodcms_faqs',
|
|
249
|
+
_id: 'entity:node/359:en',
|
|
250
|
+
_score: null,
|
|
251
|
+
_source: {
|
|
252
|
+
_language: 'en',
|
|
253
|
+
answer: [
|
|
254
|
+
'The live streamed class is PS4.85 per class, the subscription to the on-demand platform is PS4.50 per month.',
|
|
255
|
+
],
|
|
256
|
+
created: [1619874798],
|
|
257
|
+
title: ['What is the cost of the live streamed class / on-demand subscription?'],
|
|
258
|
+
updated: [1641655486],
|
|
259
|
+
uuid: ['73de1ff1-5ef0-4c66-99aa-d983101e512c'],
|
|
260
|
+
},
|
|
261
|
+
sort: [1641655486000],
|
|
262
|
+
},
|
|
263
|
+
];
|
|
264
|
+
|
|
265
|
+
const formattedFAQS = formatFaqs(ESFAQS);
|
|
266
|
+
|
|
267
|
+
export const Default: Story = {
|
|
268
|
+
parameters: {
|
|
269
|
+
layout: 'fullscreen',
|
|
270
|
+
},
|
|
271
|
+
args: {
|
|
272
|
+
title: 'Frequently Asked Questions',
|
|
273
|
+
image: 'https://picsum.photos/600/400',
|
|
274
|
+
data: formattedFAQS,
|
|
275
|
+
},
|
|
276
|
+
};
|
|
277
|
+
|
|
278
|
+
export default meta;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import Screen from '../../components/Screen';
|
|
3
|
+
import { Props } from './FAQScreen.types';
|
|
4
|
+
import DisplayHeading from '../../components/DisplayHeading';
|
|
5
|
+
import Loader from '../../components/Loader';
|
|
6
|
+
import Accordion from '../../components/Accordion';
|
|
7
|
+
|
|
8
|
+
const FAQScreen = ({ testID, title, image, data, isLoading }: Props) => {
|
|
9
|
+
return (
|
|
10
|
+
<Screen data-testid={testID || 'FAQScreen'} image={image}>
|
|
11
|
+
{title && <DisplayHeading text={title} />}
|
|
12
|
+
{!data && isLoading && (
|
|
13
|
+
<div className="flex flex-1 min-h-[125px] items-center justify-center">
|
|
14
|
+
<Loader />
|
|
15
|
+
</div>
|
|
16
|
+
)}
|
|
17
|
+
{data && (
|
|
18
|
+
<Accordion
|
|
19
|
+
data={data?.map(item => ({
|
|
20
|
+
title: item.title || '',
|
|
21
|
+
content: item.answer || '',
|
|
22
|
+
}))}
|
|
23
|
+
/>
|
|
24
|
+
)}
|
|
25
|
+
</Screen>
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
FAQScreen.displayName = 'FAQScreen';
|
|
30
|
+
|
|
31
|
+
export default FAQScreen;
|
|
32
|
+
export type { Props };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './FAQScreen';
|
|
@@ -0,0 +1,315 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/nextjs';
|
|
2
|
+
import HomeScreen from '.';
|
|
3
|
+
import { isMobileOnly } from 'react-device-detect';
|
|
4
|
+
import { BTN_SIZES, BTN_VARIANTS, CardVariant, COPY_ALIGN, VideoProps } from '../../components';
|
|
5
|
+
import { SPACING } from '../../components/Hero/Hero.types';
|
|
6
|
+
import { Easing } from 'framer-motion';
|
|
7
|
+
|
|
8
|
+
const meta: Meta<typeof HomeScreen> = {
|
|
9
|
+
title: 'TEMPLATES/HomeScreen',
|
|
10
|
+
component: HomeScreen,
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
type Story = StoryObj<typeof HomeScreen>;
|
|
14
|
+
|
|
15
|
+
const panelVideoProps = {
|
|
16
|
+
title: 'Elegant workouts, real results',
|
|
17
|
+
description: 'Achieve the elegance of a ballerina and the strength of an athlete with NRG at home.',
|
|
18
|
+
videoProps: {
|
|
19
|
+
sources: [
|
|
20
|
+
{
|
|
21
|
+
src: isMobileOnly ? '/assets/SquareMobileVideo.mov' : '/assets/BannerVideo.mov',
|
|
22
|
+
type: 'video/mp4',
|
|
23
|
+
},
|
|
24
|
+
],
|
|
25
|
+
options: {
|
|
26
|
+
aspectRatio: undefined,
|
|
27
|
+
},
|
|
28
|
+
aspectRatioValue: isMobileOnly ? '1/1' : ('16/9' as VideoProps['aspectRatioValue']),
|
|
29
|
+
},
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
const panelFeatureProps = {
|
|
33
|
+
title: 'Barre at home',
|
|
34
|
+
description:
|
|
35
|
+
'NRG at home is a barre platform that will help you get in shape and stay healthy. Our workouts are designed to be fun and effective.',
|
|
36
|
+
assets: {
|
|
37
|
+
bgAsset: {
|
|
38
|
+
src: '/assets/circle-tertiary.png',
|
|
39
|
+
alt: 'splash-1',
|
|
40
|
+
},
|
|
41
|
+
focalAsset1: {
|
|
42
|
+
src: '/assets/iphone-angled-1.png',
|
|
43
|
+
alt: 'phone-2',
|
|
44
|
+
},
|
|
45
|
+
focalAsset2: {
|
|
46
|
+
src: '/assets/iphone-flat-2.png',
|
|
47
|
+
alt: 'phone-1',
|
|
48
|
+
},
|
|
49
|
+
focalAsset3: {
|
|
50
|
+
src: '/assets/supported-panel.png',
|
|
51
|
+
alt: 'brand-1',
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
buttonData: {
|
|
55
|
+
children: 'Get Started',
|
|
56
|
+
variant: BTN_VARIANTS.PRIMARY,
|
|
57
|
+
size: BTN_SIZES.LARGE,
|
|
58
|
+
onClick: () => (window.location.href = 'https://www.bbc.com'),
|
|
59
|
+
},
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
const panelCardsProps = {
|
|
63
|
+
title: 'Why choose us?',
|
|
64
|
+
description:
|
|
65
|
+
'unlimited access to expertly crafted barre workouts, personalized live classes, and a vibrant community—all available at your fingertips with our seamless mobile apps.',
|
|
66
|
+
cardData: [
|
|
67
|
+
{
|
|
68
|
+
variant: CardVariant.ICON,
|
|
69
|
+
data: {
|
|
70
|
+
id: '1',
|
|
71
|
+
icon: 'mdi:heart-cog',
|
|
72
|
+
title: 'On-Demand Classes',
|
|
73
|
+
moreTitle: 'Learn more',
|
|
74
|
+
description:
|
|
75
|
+
'Explore our on-demand catalog with 500+ barre workouts, anytime, anywhere—your personalized fitness journey starts here.',
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
variant: CardVariant.ICON,
|
|
80
|
+
data: {
|
|
81
|
+
id: '2',
|
|
82
|
+
icon: 'mdi:account-group',
|
|
83
|
+
title: 'Live Sessions',
|
|
84
|
+
moreTitle: 'Learn more',
|
|
85
|
+
description:
|
|
86
|
+
'Join 25+ live barre sessions monthly—experience real-time coaching and connect with our vibrant community.',
|
|
87
|
+
},
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
variant: CardVariant.ICON,
|
|
91
|
+
data: {
|
|
92
|
+
id: '3',
|
|
93
|
+
icon: 'mdi:yoga',
|
|
94
|
+
title: 'All-in-one barre platform',
|
|
95
|
+
moreTitle: 'Learn more',
|
|
96
|
+
description:
|
|
97
|
+
'Experience a holistic fitness journey with seamless web and mobile apps, delivering workouts tailored for your convenience.',
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
],
|
|
101
|
+
spacing: isMobileOnly ? SPACING.ATOM : SPACING.ELEMENT,
|
|
102
|
+
};
|
|
103
|
+
|
|
104
|
+
const panelSubscriptionsProps = {
|
|
105
|
+
title: 'Choose Your Perfect Plan',
|
|
106
|
+
description:
|
|
107
|
+
'Select from our flexible subscription options to find the plan that best fits your fitness goals and lifestyle (7-day free trail & pause anytime).',
|
|
108
|
+
cardData: [
|
|
109
|
+
{
|
|
110
|
+
variant: CardVariant.ICON,
|
|
111
|
+
data: {
|
|
112
|
+
id: '1',
|
|
113
|
+
icon: 'mdi:rotate-360',
|
|
114
|
+
title: 'Premium (Monthly)',
|
|
115
|
+
subtitle: '£4.50',
|
|
116
|
+
align: COPY_ALIGN.CENTER,
|
|
117
|
+
description: 'Unlimited Catalogue Access',
|
|
118
|
+
},
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
variant: CardVariant.ICON,
|
|
122
|
+
data: {
|
|
123
|
+
id: '2',
|
|
124
|
+
icon: 'mdi:camera-flip',
|
|
125
|
+
title: 'Premium+ (Monthly)',
|
|
126
|
+
subtitle: '£19.50',
|
|
127
|
+
align: COPY_ALIGN.CENTER,
|
|
128
|
+
description: 'Unlimited On-Demand and Live',
|
|
129
|
+
},
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
variant: CardVariant.ICON,
|
|
133
|
+
data: {
|
|
134
|
+
id: '3',
|
|
135
|
+
icon: 'mdi:calendar-refresh-outline',
|
|
136
|
+
title: 'Premium (Annual)',
|
|
137
|
+
subtitle: '£49.50',
|
|
138
|
+
align: COPY_ALIGN.CENTER,
|
|
139
|
+
description: 'Unlimited Catalogue Access',
|
|
140
|
+
},
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
variant: CardVariant.ICON,
|
|
144
|
+
data: {
|
|
145
|
+
id: '3',
|
|
146
|
+
icon: 'mdi:yoga',
|
|
147
|
+
title: 'Premium+ (Annual)',
|
|
148
|
+
subtitle: '£214.50',
|
|
149
|
+
align: COPY_ALIGN.CENTER,
|
|
150
|
+
description: 'Unlimited On-Demand and Live',
|
|
151
|
+
},
|
|
152
|
+
},
|
|
153
|
+
],
|
|
154
|
+
spacing: isMobileOnly ? SPACING.ATOM : SPACING.ELEMENT,
|
|
155
|
+
};
|
|
156
|
+
|
|
157
|
+
const panelTestimonialsProps = {
|
|
158
|
+
title: 'What you think',
|
|
159
|
+
description:
|
|
160
|
+
'Don’t just take our word for it—here’s what our community has to say about their transformative experiences with us',
|
|
161
|
+
cardData: [
|
|
162
|
+
{
|
|
163
|
+
variant: CardVariant.ICON,
|
|
164
|
+
data: {
|
|
165
|
+
id: '1',
|
|
166
|
+
icon: 'mdi:account-outline',
|
|
167
|
+
align: COPY_ALIGN.CENTER,
|
|
168
|
+
title: 'Elsa',
|
|
169
|
+
description:
|
|
170
|
+
"Nathalie's classes are incredible. The application allows you to choose targeted classes and always very varied depending on the shape of the moment. We are perfectly guided for the realization of the movements, Nathalie transmits a great energy. Following her classes live or in replay is a real pleasure that I can no longer do without!!",
|
|
171
|
+
},
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
variant: CardVariant.ICON,
|
|
175
|
+
data: {
|
|
176
|
+
id: '2',
|
|
177
|
+
icon: 'mdi:account',
|
|
178
|
+
align: COPY_ALIGN.CENTER,
|
|
179
|
+
title: 'Katharine',
|
|
180
|
+
description:
|
|
181
|
+
"This has completely changed and has been a game changer for my running, I'm stronger and faster. I've never looked so toned and the barre classes are a really good way to get in the strength training that I need at my age (53 next week!)",
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
],
|
|
185
|
+
spacing: isMobileOnly ? SPACING.ATOM : SPACING.ELEMENT,
|
|
186
|
+
};
|
|
187
|
+
|
|
188
|
+
const panelHerosProps = [
|
|
189
|
+
{
|
|
190
|
+
title: 'Access the LIVE CLASSES',
|
|
191
|
+
description:
|
|
192
|
+
'<p>Join the LIVE CLASSES daily and access their recordings. Check the schedule of Live Classes. 25 classes per month, Monday-Saturday.</p>',
|
|
193
|
+
image: 'https://d9r66csa6956h.cloudfront.net/styles/full_16_9/s3/2022-03/day5.jpg?itok=EbeIXNcD',
|
|
194
|
+
inversed: false,
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
title: 'Short on time?',
|
|
198
|
+
description:
|
|
199
|
+
'<p>When 10 minutes is all you have!</p><p>Check you these series of short workouts. Take your pick between some quick full body workouts or some more focused sessions.</p>',
|
|
200
|
+
image:
|
|
201
|
+
'https://assets.nrgbarrebody.app/styles/full_16_9/s3/2023-08/Screenshot%202023-08-29%20at%2016.14.29.png?itok=qjfeucKp',
|
|
202
|
+
inversed: true,
|
|
203
|
+
},
|
|
204
|
+
];
|
|
205
|
+
|
|
206
|
+
const panelDataCardsProps = {
|
|
207
|
+
withSeparators: !isMobileOnly,
|
|
208
|
+
spacing: isMobileOnly ? SPACING.DEFAULT : SPACING.ELEMENT,
|
|
209
|
+
cardData: [
|
|
210
|
+
{
|
|
211
|
+
variant: CardVariant.DATA,
|
|
212
|
+
data: {
|
|
213
|
+
id: '1',
|
|
214
|
+
data: {
|
|
215
|
+
item: '1000s',
|
|
216
|
+
label: 'Thriving community barre enthusiasts',
|
|
217
|
+
numberData: {
|
|
218
|
+
from: 0,
|
|
219
|
+
to: 10,
|
|
220
|
+
animationOptions: {
|
|
221
|
+
ease: 'easeInOut' as Easing | Easing[],
|
|
222
|
+
},
|
|
223
|
+
},
|
|
224
|
+
},
|
|
225
|
+
raised: false,
|
|
226
|
+
padded: true,
|
|
227
|
+
},
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
variant: CardVariant.DATA,
|
|
231
|
+
data: {
|
|
232
|
+
id: '2',
|
|
233
|
+
data: {
|
|
234
|
+
item: '+',
|
|
235
|
+
label: 'On-demand workouts',
|
|
236
|
+
numberData: {
|
|
237
|
+
from: 0,
|
|
238
|
+
to: 500,
|
|
239
|
+
animationOptions: {
|
|
240
|
+
ease: 'easeInOut' as Easing | Easing[],
|
|
241
|
+
},
|
|
242
|
+
},
|
|
243
|
+
animateNumber: true,
|
|
244
|
+
},
|
|
245
|
+
raised: false,
|
|
246
|
+
padded: true,
|
|
247
|
+
},
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
variant: CardVariant.DATA,
|
|
251
|
+
data: {
|
|
252
|
+
id: '3',
|
|
253
|
+
data: {
|
|
254
|
+
item: '+',
|
|
255
|
+
label: 'Live sessions per month',
|
|
256
|
+
numberData: {
|
|
257
|
+
from: 0,
|
|
258
|
+
to: 25,
|
|
259
|
+
animationOptions: {
|
|
260
|
+
ease: 'easeInOut' as Easing | Easing[],
|
|
261
|
+
},
|
|
262
|
+
},
|
|
263
|
+
animateNumber: true,
|
|
264
|
+
},
|
|
265
|
+
raised: false,
|
|
266
|
+
padded: true,
|
|
267
|
+
},
|
|
268
|
+
},
|
|
269
|
+
],
|
|
270
|
+
};
|
|
271
|
+
|
|
272
|
+
const panelProductProps = {
|
|
273
|
+
image1: '/assets/iphone-flat-1.png',
|
|
274
|
+
image2: '/assets/iphone-flat-2.png',
|
|
275
|
+
title: 'Grace meets strength with NRG at home.',
|
|
276
|
+
description:
|
|
277
|
+
"Unlock the benefits of ballet barre training with our convenient subscription app. Featuring classes led by professional dancers, our app offers an engaging way to tone your muscles, enhance your flexibility, and boost your overall fitness. Whether you're looking to try something new or deepen your practice, our app provides the tools you need. Start your free trial now!",
|
|
278
|
+
iosLink: 'https://apps.apple.com/us/app/nrg-at-home/id1561480000',
|
|
279
|
+
androidLink: 'https://play.google.com/store/apps/details?id=com.nrgathome',
|
|
280
|
+
spacing: isMobileOnly ? SPACING.DEFAULT : SPACING.MODULE,
|
|
281
|
+
};
|
|
282
|
+
|
|
283
|
+
const panelIntroProps = {
|
|
284
|
+
title: 'The "Barre Outside" Series',
|
|
285
|
+
withBg: true,
|
|
286
|
+
description:
|
|
287
|
+
"<p>You want to start working out! You wish to increase muscle strength, improve mobility and posture but you are very busy, you work all day and don't really know how or where to start. In this section I recommend 5 workouts that you can start with and try your best to complete within the space of a week ( 7 days). You will find yourself getting stronger, more toned with increasingly more energy too.</p>",
|
|
288
|
+
buttonData: {
|
|
289
|
+
variant: BTN_VARIANTS.PRIMARY,
|
|
290
|
+
size: BTN_SIZES.LARGE,
|
|
291
|
+
children: 'New Classes',
|
|
292
|
+
},
|
|
293
|
+
image:
|
|
294
|
+
'https://assets.nrgbarrebody.app/styles/full_16_9/s3/2024-05/WhatsApp%20Image%202024-05-05%20at%2012.26.48.jpeg?itok=oxJt0m9N',
|
|
295
|
+
};
|
|
296
|
+
|
|
297
|
+
export const Default: Story = {
|
|
298
|
+
parameters: {
|
|
299
|
+
layout: 'fullscreen',
|
|
300
|
+
},
|
|
301
|
+
args: {
|
|
302
|
+
title: 'Home Screen',
|
|
303
|
+
panelIntroProps: panelIntroProps,
|
|
304
|
+
panelVideoProps: panelVideoProps,
|
|
305
|
+
panelFeatureProps: panelFeatureProps,
|
|
306
|
+
panelCardsProps: panelCardsProps,
|
|
307
|
+
panelHerosProps: panelHerosProps,
|
|
308
|
+
panelSubscriptionsProps: panelSubscriptionsProps,
|
|
309
|
+
panelTestimonialsProps: panelTestimonialsProps,
|
|
310
|
+
panelDataCardsProps: panelDataCardsProps,
|
|
311
|
+
panelProductProps: panelProductProps,
|
|
312
|
+
},
|
|
313
|
+
};
|
|
314
|
+
|
|
315
|
+
export default meta;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import Screen from '../../components/Screen';
|
|
3
|
+
import { Props } from './HomeScreen.types';
|
|
4
|
+
import Container from '../../components/Container';
|
|
5
|
+
import PanelCards from '../../components/PanelCards';
|
|
6
|
+
import PanelCustom from '../../components/PanelCustom';
|
|
7
|
+
import PanelFeature from '../../components/PanelFeature';
|
|
8
|
+
import PanelHero from '../../components/PanelHero';
|
|
9
|
+
import PanelIntro from '../../components/PanelIntro';
|
|
10
|
+
import PanelProduct from '../../components/PanelProduct';
|
|
11
|
+
import PanelVideo from '../../components/PanelVideo';
|
|
12
|
+
|
|
13
|
+
const HomeScreen = ({
|
|
14
|
+
testID,
|
|
15
|
+
image,
|
|
16
|
+
panelIntroProps,
|
|
17
|
+
panelVideoProps,
|
|
18
|
+
panelFeatureProps,
|
|
19
|
+
panelCardsProps,
|
|
20
|
+
panelHerosProps,
|
|
21
|
+
panelSubscriptionsProps,
|
|
22
|
+
panelTestimonialsProps,
|
|
23
|
+
panelDataCardsProps,
|
|
24
|
+
panelProductProps,
|
|
25
|
+
panelCustomProps,
|
|
26
|
+
isFlush = true,
|
|
27
|
+
}: Props) => {
|
|
28
|
+
return (
|
|
29
|
+
<Screen data-testid={testID || 'HomeScreen'} image={image} isFlush={isFlush}>
|
|
30
|
+
{panelVideoProps && <PanelVideo {...panelVideoProps} />}
|
|
31
|
+
<Container>
|
|
32
|
+
{panelIntroProps && <PanelIntro {...panelIntroProps} />}
|
|
33
|
+
{panelFeatureProps && <PanelFeature {...panelFeatureProps} />}
|
|
34
|
+
{panelCardsProps && <PanelCards {...panelCardsProps} />}
|
|
35
|
+
{panelHerosProps?.[0] && <PanelHero {...panelHerosProps?.[0]} />}
|
|
36
|
+
{panelSubscriptionsProps && <PanelCards {...panelSubscriptionsProps} />}
|
|
37
|
+
{panelTestimonialsProps && <PanelCards {...panelTestimonialsProps} />}
|
|
38
|
+
{panelHerosProps?.slice(1).map(panelHeroProps => <PanelHero key={panelHeroProps.title} {...panelHeroProps} />)}
|
|
39
|
+
{panelDataCardsProps && <PanelCards {...panelDataCardsProps} />}
|
|
40
|
+
{panelProductProps && <PanelProduct {...panelProductProps} />}
|
|
41
|
+
{panelCustomProps && <PanelCustom {...panelCustomProps} />}
|
|
42
|
+
</Container>
|
|
43
|
+
</Screen>
|
|
44
|
+
);
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
HomeScreen.displayName = 'HomeScreen';
|
|
48
|
+
|
|
49
|
+
export default HomeScreen;
|
|
50
|
+
export type { Props };
|