@automattic/onboarding 1.0.0 → 1.0.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/.storybook/index.scss +16 -0
- package/.storybook/main.ts +15 -0
- package/.storybook/preview.ts +5 -0
- package/CHANGELOG.md +5 -0
- package/dist/cjs/action-buttons/index.js +1 -13
- package/dist/cjs/action-buttons/index.js.map +1 -1
- package/dist/cjs/action-buttons/style.scss +4 -40
- package/dist/cjs/cart/create-cart-manager-client.js +3 -3
- package/dist/cjs/cart/create-cart-manager-client.js.map +1 -1
- package/dist/cjs/cart/index.js +45 -67
- package/dist/cjs/cart/index.js.map +1 -1
- package/dist/cjs/confetti/index.js +1 -1
- package/dist/cjs/confetti/index.js.map +1 -1
- package/dist/cjs/flow-progress/use-flow-progress.js +0 -57
- package/dist/cjs/flow-progress/use-flow-progress.js.map +1 -1
- package/dist/cjs/hooks/use-persisted-state.js +61 -0
- package/dist/cjs/hooks/use-persisted-state.js.map +1 -0
- package/dist/cjs/hooray/index.js +1 -1
- package/dist/cjs/index.js +11 -10
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/mshots-image/index.js +34 -15
- package/dist/cjs/mshots-image/index.js.map +1 -1
- package/dist/cjs/mshots-image/style.scss +1 -0
- package/dist/cjs/navigator/hooks/index.js +2 -1
- package/dist/cjs/navigator/hooks/index.js.map +1 -1
- package/dist/cjs/navigator/navigator-buttons/index.js +2 -2
- package/dist/cjs/navigator/navigator-buttons/index.js.map +1 -1
- package/dist/cjs/navigator/navigator-header/index.js.map +1 -1
- package/dist/cjs/navigator/navigator-screens/hooks/index.js +3 -2
- package/dist/cjs/navigator/navigator-screens/hooks/index.js.map +1 -1
- package/dist/cjs/navigator/navigator-screens/hooks/use-navigator-screens.js +1 -1
- package/dist/cjs/navigator/navigator-screens/hooks/use-navigator-screens.js.map +1 -1
- package/dist/cjs/navigator/navigator-screens/navigator-screens.js +7 -2
- package/dist/cjs/navigator/navigator-screens/navigator-screens.js.map +1 -1
- package/dist/cjs/select-card-checkbox/index.js +4 -3
- package/dist/cjs/select-card-checkbox/index.js.map +1 -1
- package/dist/cjs/select-card-checkbox/style.scss +11 -14
- package/dist/cjs/select-card-checkbox-v2/index.js +15 -0
- package/dist/cjs/select-card-checkbox-v2/index.js.map +1 -0
- package/dist/cjs/select-card-checkbox-v2/style.scss +25 -0
- package/dist/cjs/select-items/index.js +2 -1
- package/dist/cjs/select-items/index.js.map +1 -1
- package/dist/cjs/select-items/style.scss +2 -1
- package/dist/cjs/setup-tailored-site-after-creation.js +9 -37
- package/dist/cjs/setup-tailored-site-after-creation.js.map +1 -1
- package/dist/cjs/step-container/index.js +10 -12
- package/dist/cjs/step-container/index.js.map +1 -1
- package/dist/cjs/step-container/style.scss +35 -77
- package/dist/cjs/step-container-v2/components/ContentRow/ContentRow.js +14 -0
- package/dist/cjs/step-container-v2/components/ContentRow/ContentRow.js.map +1 -0
- package/dist/cjs/step-container-v2/components/ContentRow/style.scss +26 -0
- package/dist/cjs/step-container-v2/components/ContentWrapper/ContentWrapper.js +19 -0
- package/dist/cjs/step-container-v2/components/ContentWrapper/ContentWrapper.js.map +1 -0
- package/dist/cjs/step-container-v2/components/ContentWrapper/style.scss +70 -0
- package/dist/cjs/step-container-v2/components/Heading/Heading.js +17 -0
- package/dist/cjs/step-container-v2/components/Heading/Heading.js.map +1 -0
- package/dist/cjs/step-container-v2/components/Heading/style.scss +47 -0
- package/dist/cjs/step-container-v2/components/StepContainerV2/StepContainerV2.js +36 -0
- package/dist/cjs/step-container-v2/components/StepContainerV2/StepContainerV2.js.map +1 -0
- package/dist/cjs/step-container-v2/components/StepContainerV2/context.js +13 -0
- package/dist/cjs/step-container-v2/components/StepContainerV2/context.js.map +1 -0
- package/dist/cjs/step-container-v2/components/StepContainerV2/style.scss +21 -0
- package/dist/cjs/step-container-v2/components/StepCounter/StepCounter.js +17 -0
- package/dist/cjs/step-container-v2/components/StepCounter/StepCounter.js.map +1 -0
- package/dist/cjs/step-container-v2/components/StepCounter/style.scss +4 -0
- package/dist/cjs/step-container-v2/components/StickyBottomBar/StickyBottomBar.js +17 -0
- package/dist/cjs/step-container-v2/components/StickyBottomBar/StickyBottomBar.js.map +1 -0
- package/dist/cjs/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.js +31 -0
- package/dist/cjs/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.js.map +1 -0
- package/dist/cjs/step-container-v2/components/StickyBottomBar/style.scss +56 -0
- package/dist/cjs/step-container-v2/components/TopBar/TopBar.js +55 -0
- package/dist/cjs/step-container-v2/components/TopBar/TopBar.js.map +1 -0
- package/dist/cjs/step-container-v2/components/TopBar/TopBarRenderer.js +32 -0
- package/dist/cjs/step-container-v2/components/TopBar/TopBarRenderer.js.map +1 -0
- package/dist/cjs/step-container-v2/components/TopBar/style.scss +75 -0
- package/dist/cjs/step-container-v2/components/buttons/BackButton/BackButton.js +29 -0
- package/dist/cjs/step-container-v2/components/buttons/BackButton/BackButton.js.map +1 -0
- package/dist/cjs/step-container-v2/components/buttons/BackButton/style.scss +16 -0
- package/dist/cjs/step-container-v2/components/buttons/LinkButton/LinkButton.js +18 -0
- package/dist/cjs/step-container-v2/components/buttons/LinkButton/LinkButton.js.map +1 -0
- package/dist/cjs/step-container-v2/components/buttons/LinkButton/style.scss +6 -0
- package/dist/cjs/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.js +18 -0
- package/dist/cjs/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.js.map +1 -0
- package/dist/cjs/step-container-v2/components/buttons/PrimaryButton/style.scss +6 -0
- package/dist/cjs/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.js +18 -0
- package/dist/cjs/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.js.map +1 -0
- package/dist/cjs/step-container-v2/components/buttons/SecondaryButton/style.scss +6 -0
- package/dist/cjs/step-container-v2/components/buttons/SkipButton/SkipButton.js +28 -0
- package/dist/cjs/step-container-v2/components/buttons/SkipButton/SkipButton.js.map +1 -0
- package/dist/cjs/step-container-v2/contexts/StepContainerV2Context.js +17 -0
- package/dist/cjs/step-container-v2/contexts/StepContainerV2Context.js.map +1 -0
- package/dist/cjs/step-container-v2/helpers/decorateButtonWithTracksEventRecording.js +18 -0
- package/dist/cjs/step-container-v2/helpers/decorateButtonWithTracksEventRecording.js.map +1 -0
- package/dist/cjs/step-container-v2/helpers/normalizeButtonProps.js +13 -0
- package/dist/cjs/step-container-v2/helpers/normalizeButtonProps.js.map +1 -0
- package/dist/cjs/step-container-v2/helpers/wireframe-placeholder.js +18 -0
- package/dist/cjs/step-container-v2/helpers/wireframe-placeholder.js.map +1 -0
- package/dist/cjs/step-container-v2/helpers/withStepContainerV2ContextDecorator.js +15 -0
- package/dist/cjs/step-container-v2/helpers/withStepContainerV2ContextDecorator.js.map +1 -0
- package/dist/cjs/step-container-v2/index.js +41 -0
- package/dist/cjs/step-container-v2/index.js.map +1 -0
- package/dist/cjs/step-container-v2/types.js +3 -0
- package/dist/cjs/step-container-v2/types.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.js +26 -0
- package/dist/cjs/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.js +52 -0
- package/dist/cjs/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.js +26 -0
- package/dist/cjs/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.js +25 -0
- package/dist/cjs/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/style.scss +14 -0
- package/dist/cjs/step-container-v2/wireframes/Loading/Loading.js +30 -0
- package/dist/cjs/step-container-v2/wireframes/Loading/Loading.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/Loading/Loading.stories.js +29 -0
- package/dist/cjs/step-container-v2/wireframes/Loading/Loading.stories.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/Loading/style.scss +22 -0
- package/dist/cjs/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.js +17 -0
- package/dist/cjs/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.js +17 -0
- package/dist/cjs/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/PlaygroundLayout/style.scss +5 -0
- package/dist/cjs/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.js +38 -0
- package/dist/cjs/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.js +28 -0
- package/dist/cjs/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/TwoColumnLayout/style.scss +15 -0
- package/dist/cjs/step-container-v2/wireframes/WideLayout/WideLayout.js +17 -0
- package/dist/cjs/step-container-v2/wireframes/WideLayout/WideLayout.js.map +1 -0
- package/dist/cjs/step-container-v2/wireframes/WideLayout/WideLayout.stories.js +41 -0
- package/dist/cjs/step-container-v2/wireframes/WideLayout/WideLayout.stories.js.map +1 -0
- package/dist/cjs/step-navigation-link/index.js +2 -2
- package/dist/cjs/step-navigation-link/index.js.map +1 -1
- package/dist/cjs/step-navigation-link/style.scss +5 -3
- package/dist/cjs/titles/styles.scss +2 -2
- package/dist/cjs/upload-and-set-site-logo.js +4 -5
- package/dist/cjs/upload-and-set-site-logo.js.map +1 -1
- package/dist/cjs/utils/contrastChecker.js +1 -22
- package/dist/cjs/utils/contrastChecker.js.map +1 -1
- package/dist/cjs/utils/flows.js +73 -117
- package/dist/cjs/utils/flows.js.map +1 -1
- package/dist/cjs/utils/is-domain.js +1 -2
- package/dist/cjs/utils/is-domain.js.map +1 -1
- package/dist/cjs/utils/use-data-loss-warning.js +1 -2
- package/dist/cjs/utils/use-data-loss-warning.js.map +1 -1
- package/dist/cjs/wpcom-request.js +24 -0
- package/dist/cjs/wpcom-request.js.map +1 -0
- package/dist/esm/action-buttons/index.js +1 -11
- package/dist/esm/action-buttons/index.js.map +1 -1
- package/dist/esm/action-buttons/style.scss +4 -40
- package/dist/esm/cart/create-cart-manager-client.js +1 -1
- package/dist/esm/cart/create-cart-manager-client.js.map +1 -1
- package/dist/esm/cart/index.js +40 -61
- package/dist/esm/cart/index.js.map +1 -1
- package/dist/esm/confetti/index.js +1 -1
- package/dist/esm/confetti/index.js.map +1 -1
- package/dist/esm/flow-progress/use-flow-progress.js +1 -58
- package/dist/esm/flow-progress/use-flow-progress.js.map +1 -1
- package/dist/esm/hooks/use-persisted-state.js +57 -0
- package/dist/esm/hooks/use-persisted-state.js.map +1 -0
- package/dist/esm/hooray/index.js +1 -1
- package/dist/esm/index.js +6 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/mshots-image/index.js +33 -13
- package/dist/esm/mshots-image/index.js.map +1 -1
- package/dist/esm/mshots-image/style.scss +1 -0
- package/dist/esm/navigator/navigator-buttons/index.js.map +1 -1
- package/dist/esm/navigator/navigator-header/index.js.map +1 -1
- package/dist/esm/navigator/navigator-screens/hooks/use-navigator-screens.js +1 -1
- package/dist/esm/navigator/navigator-screens/hooks/use-navigator-screens.js.map +1 -1
- package/dist/esm/navigator/navigator-screens/navigator-screens.js +8 -3
- package/dist/esm/navigator/navigator-screens/navigator-screens.js.map +1 -1
- package/dist/esm/select-card-checkbox/index.js +4 -3
- package/dist/esm/select-card-checkbox/index.js.map +1 -1
- package/dist/esm/select-card-checkbox/style.scss +11 -14
- package/dist/esm/select-card-checkbox-v2/index.js +12 -0
- package/dist/esm/select-card-checkbox-v2/index.js.map +1 -0
- package/dist/esm/select-card-checkbox-v2/style.scss +25 -0
- package/dist/esm/select-items/index.js +3 -2
- package/dist/esm/select-items/index.js.map +1 -1
- package/dist/esm/select-items/style.scss +2 -1
- package/dist/esm/setup-tailored-site-after-creation.js +9 -37
- package/dist/esm/setup-tailored-site-after-creation.js.map +1 -1
- package/dist/esm/step-container/index.js +11 -13
- package/dist/esm/step-container/index.js.map +1 -1
- package/dist/esm/step-container/style.scss +35 -77
- package/dist/esm/step-container-v2/components/ContentRow/ContentRow.js +9 -0
- package/dist/esm/step-container-v2/components/ContentRow/ContentRow.js.map +1 -0
- package/dist/esm/step-container-v2/components/ContentRow/style.scss +26 -0
- package/dist/esm/step-container-v2/components/ContentWrapper/ContentWrapper.js +14 -0
- package/dist/esm/step-container-v2/components/ContentWrapper/ContentWrapper.js.map +1 -0
- package/dist/esm/step-container-v2/components/ContentWrapper/style.scss +70 -0
- package/dist/esm/step-container-v2/components/Heading/Heading.js +12 -0
- package/dist/esm/step-container-v2/components/Heading/Heading.js.map +1 -0
- package/dist/esm/step-container-v2/components/Heading/style.scss +47 -0
- package/dist/esm/step-container-v2/components/StepContainerV2/StepContainerV2.js +32 -0
- package/dist/esm/step-container-v2/components/StepContainerV2/StepContainerV2.js.map +1 -0
- package/dist/esm/step-container-v2/components/StepContainerV2/context.js +10 -0
- package/dist/esm/step-container-v2/components/StepContainerV2/context.js.map +1 -0
- package/dist/esm/step-container-v2/components/StepContainerV2/style.scss +21 -0
- package/dist/esm/step-container-v2/components/StepCounter/StepCounter.js +13 -0
- package/dist/esm/step-container-v2/components/StepCounter/StepCounter.js.map +1 -0
- package/dist/esm/step-container-v2/components/StepCounter/style.scss +4 -0
- package/dist/esm/step-container-v2/components/StickyBottomBar/StickyBottomBar.js +12 -0
- package/dist/esm/step-container-v2/components/StickyBottomBar/StickyBottomBar.js.map +1 -0
- package/dist/esm/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.js +27 -0
- package/dist/esm/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.js.map +1 -0
- package/dist/esm/step-container-v2/components/StickyBottomBar/style.scss +56 -0
- package/dist/esm/step-container-v2/components/TopBar/TopBar.js +49 -0
- package/dist/esm/step-container-v2/components/TopBar/TopBar.js.map +1 -0
- package/dist/esm/step-container-v2/components/TopBar/TopBarRenderer.js +27 -0
- package/dist/esm/step-container-v2/components/TopBar/TopBarRenderer.js.map +1 -0
- package/dist/esm/step-container-v2/components/TopBar/style.scss +75 -0
- package/dist/esm/step-container-v2/components/buttons/BackButton/BackButton.js +25 -0
- package/dist/esm/step-container-v2/components/buttons/BackButton/BackButton.js.map +1 -0
- package/dist/esm/step-container-v2/components/buttons/BackButton/style.scss +16 -0
- package/dist/esm/step-container-v2/components/buttons/LinkButton/LinkButton.js +14 -0
- package/dist/esm/step-container-v2/components/buttons/LinkButton/LinkButton.js.map +1 -0
- package/dist/esm/step-container-v2/components/buttons/LinkButton/style.scss +6 -0
- package/dist/esm/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.js +14 -0
- package/dist/esm/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.js.map +1 -0
- package/dist/esm/step-container-v2/components/buttons/PrimaryButton/style.scss +6 -0
- package/dist/esm/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.js +14 -0
- package/dist/esm/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.js.map +1 -0
- package/dist/esm/step-container-v2/components/buttons/SecondaryButton/style.scss +6 -0
- package/dist/esm/step-container-v2/components/buttons/SkipButton/SkipButton.js +24 -0
- package/dist/esm/step-container-v2/components/buttons/SkipButton/SkipButton.js.map +1 -0
- package/dist/esm/step-container-v2/contexts/StepContainerV2Context.js +13 -0
- package/dist/esm/step-container-v2/contexts/StepContainerV2Context.js.map +1 -0
- package/dist/esm/step-container-v2/helpers/decorateButtonWithTracksEventRecording.js +14 -0
- package/dist/esm/step-container-v2/helpers/decorateButtonWithTracksEventRecording.js.map +1 -0
- package/dist/esm/step-container-v2/helpers/normalizeButtonProps.js +8 -0
- package/dist/esm/step-container-v2/helpers/normalizeButtonProps.js.map +1 -0
- package/dist/esm/step-container-v2/helpers/wireframe-placeholder.js +15 -0
- package/dist/esm/step-container-v2/helpers/wireframe-placeholder.js.map +1 -0
- package/dist/esm/step-container-v2/helpers/withStepContainerV2ContextDecorator.js +11 -0
- package/dist/esm/step-container-v2/helpers/withStepContainerV2ContextDecorator.js.map +1 -0
- package/dist/esm/step-container-v2/index.js +22 -0
- package/dist/esm/step-container-v2/index.js.map +1 -0
- package/dist/esm/step-container-v2/types.js +2 -0
- package/dist/esm/step-container-v2/types.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.js +22 -0
- package/dist/esm/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.js +45 -0
- package/dist/esm/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.js +23 -0
- package/dist/esm/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.js +21 -0
- package/dist/esm/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/style.scss +14 -0
- package/dist/esm/step-container-v2/wireframes/Loading/Loading.js +26 -0
- package/dist/esm/step-container-v2/wireframes/Loading/Loading.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/Loading/Loading.stories.js +22 -0
- package/dist/esm/step-container-v2/wireframes/Loading/Loading.stories.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/Loading/style.scss +22 -0
- package/dist/esm/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.js +12 -0
- package/dist/esm/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.js +13 -0
- package/dist/esm/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/PlaygroundLayout/style.scss +5 -0
- package/dist/esm/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.js +33 -0
- package/dist/esm/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.js +22 -0
- package/dist/esm/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/TwoColumnLayout/style.scss +15 -0
- package/dist/esm/step-container-v2/wireframes/WideLayout/WideLayout.js +13 -0
- package/dist/esm/step-container-v2/wireframes/WideLayout/WideLayout.js.map +1 -0
- package/dist/esm/step-container-v2/wireframes/WideLayout/WideLayout.stories.js +36 -0
- package/dist/esm/step-container-v2/wireframes/WideLayout/WideLayout.stories.js.map +1 -0
- package/dist/esm/step-navigation-link/index.js +2 -2
- package/dist/esm/step-navigation-link/index.js.map +1 -1
- package/dist/esm/step-navigation-link/style.scss +5 -3
- package/dist/esm/titles/styles.scss +2 -2
- package/dist/esm/upload-and-set-site-logo.js +1 -1
- package/dist/esm/upload-and-set-site-logo.js.map +1 -1
- package/dist/esm/utils/contrastChecker.js +0 -20
- package/dist/esm/utils/contrastChecker.js.map +1 -1
- package/dist/esm/utils/flows.js +57 -96
- package/dist/esm/utils/flows.js.map +1 -1
- package/dist/esm/wpcom-request.js +18 -0
- package/dist/esm/wpcom-request.js.map +1 -0
- package/dist/styles/mixins.scss +4 -4
- package/dist/styles/variables.scss +2 -2
- package/dist/tsconfig-cjs.tsbuildinfo +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/action-buttons/index.d.ts +0 -4
- package/dist/types/action-buttons/index.d.ts.map +1 -1
- package/dist/types/cart/index.d.ts +7 -4
- package/dist/types/cart/index.d.ts.map +1 -1
- package/dist/types/flow-progress/use-flow-progress.d.ts.map +1 -1
- package/dist/types/hooks/use-persisted-state.d.ts +26 -0
- package/dist/types/hooks/use-persisted-state.d.ts.map +1 -0
- package/dist/types/index.d.ts +6 -5
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/intent-screen/index.d.ts.map +1 -1
- package/dist/types/mshots-image/index.d.ts +2 -1
- package/dist/types/mshots-image/index.d.ts.map +1 -1
- package/dist/types/navigator/hooks/use-navigator-listener.d.ts.map +1 -1
- package/dist/types/navigator/navigator-buttons/index.d.ts +1 -1
- package/dist/types/navigator/navigator-buttons/index.d.ts.map +1 -1
- package/dist/types/navigator/navigator-header/index.d.ts +1 -1
- package/dist/types/navigator/navigator-header/index.d.ts.map +1 -1
- package/dist/types/navigator/navigator-item-group/index.d.ts +0 -1
- package/dist/types/navigator/navigator-item-group/index.d.ts.map +1 -1
- package/dist/types/navigator/navigator-listener/index.d.ts.map +1 -1
- package/dist/types/navigator/navigator-screen/index.d.ts.map +1 -1
- package/dist/types/navigator/navigator-screens/hooks/use-navigator-buttons.d.ts.map +1 -1
- package/dist/types/navigator/navigator-screens/hooks/use-navigator-screens.d.ts.map +1 -1
- package/dist/types/navigator/navigator-screens/navigator-screens.d.ts +4 -2
- package/dist/types/navigator/navigator-screens/navigator-screens.d.ts.map +1 -1
- package/dist/types/navigator/navigator-screens/types.d.ts +1 -1
- package/dist/types/navigator/navigator-screens/types.d.ts.map +1 -1
- package/dist/types/progress/index.d.ts.map +1 -1
- package/dist/types/select-card-checkbox/index.d.ts +3 -1
- package/dist/types/select-card-checkbox/index.d.ts.map +1 -1
- package/dist/types/select-card-checkbox-v2/index.d.ts +12 -0
- package/dist/types/select-card-checkbox-v2/index.d.ts.map +1 -0
- package/dist/types/select-items/index.d.ts +1 -1
- package/dist/types/select-items/index.d.ts.map +1 -1
- package/dist/types/setup-tailored-site-after-creation.d.ts +1 -1
- package/dist/types/setup-tailored-site-after-creation.d.ts.map +1 -1
- package/dist/types/step-container/index.d.ts +3 -4
- package/dist/types/step-container/index.d.ts.map +1 -1
- package/dist/types/step-container-v2/components/ContentRow/ContentRow.d.ts +9 -0
- package/dist/types/step-container-v2/components/ContentRow/ContentRow.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/ContentWrapper/ContentWrapper.d.ts +15 -0
- package/dist/types/step-container-v2/components/ContentWrapper/ContentWrapper.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/Heading/Heading.d.ts +11 -0
- package/dist/types/step-container-v2/components/Heading/Heading.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/StepContainerV2/StepContainerV2.d.ts +7 -0
- package/dist/types/step-container-v2/components/StepContainerV2/StepContainerV2.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/StepContainerV2/context.d.ts +12 -0
- package/dist/types/step-container-v2/components/StepContainerV2/context.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/StepCounter/StepCounter.d.ts +7 -0
- package/dist/types/step-container-v2/components/StepCounter/StepCounter.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/StickyBottomBar/StickyBottomBar.d.ts +14 -0
- package/dist/types/step-container-v2/components/StickyBottomBar/StickyBottomBar.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.d.ts +5 -0
- package/dist/types/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/TopBar/TopBar.d.ts +25 -0
- package/dist/types/step-container-v2/components/TopBar/TopBar.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/TopBar/TopBarRenderer.d.ts +6 -0
- package/dist/types/step-container-v2/components/TopBar/TopBarRenderer.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/buttons/BackButton/BackButton.d.ts +6 -0
- package/dist/types/step-container-v2/components/buttons/BackButton/BackButton.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/buttons/LinkButton/LinkButton.d.ts +4 -0
- package/dist/types/step-container-v2/components/buttons/LinkButton/LinkButton.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.d.ts +4 -0
- package/dist/types/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.d.ts +4 -0
- package/dist/types/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.d.ts.map +1 -0
- package/dist/types/step-container-v2/components/buttons/SkipButton/SkipButton.d.ts +9 -0
- package/dist/types/step-container-v2/components/buttons/SkipButton/SkipButton.d.ts.map +1 -0
- package/dist/types/step-container-v2/contexts/StepContainerV2Context.d.ts +10 -0
- package/dist/types/step-container-v2/contexts/StepContainerV2Context.d.ts.map +1 -0
- package/dist/types/step-container-v2/helpers/decorateButtonWithTracksEventRecording.d.ts +8 -0
- package/dist/types/step-container-v2/helpers/decorateButtonWithTracksEventRecording.d.ts.map +1 -0
- package/dist/types/step-container-v2/helpers/normalizeButtonProps.d.ts +5 -0
- package/dist/types/step-container-v2/helpers/normalizeButtonProps.d.ts.map +1 -0
- package/dist/types/step-container-v2/helpers/wireframe-placeholder.d.ts +7 -0
- package/dist/types/step-container-v2/helpers/wireframe-placeholder.d.ts.map +1 -0
- package/dist/types/step-container-v2/helpers/withStepContainerV2ContextDecorator.d.ts +2 -0
- package/dist/types/step-container-v2/helpers/withStepContainerV2ContextDecorator.d.ts.map +1 -0
- package/dist/types/step-container-v2/index.d.ts +22 -0
- package/dist/types/step-container-v2/index.d.ts.map +1 -0
- package/dist/types/step-container-v2/types.d.ts +4 -0
- package/dist/types/step-container-v2/types.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.d.ts +16 -0
- package/dist/types/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.d.ts +9 -0
- package/dist/types/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.d.ts +18 -0
- package/dist/types/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.d.ts +6 -0
- package/dist/types/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/Loading/Loading.d.ts +12 -0
- package/dist/types/step-container-v2/wireframes/Loading/Loading.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/Loading/Loading.stories.d.ts +9 -0
- package/dist/types/step-container-v2/wireframes/Loading/Loading.stories.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.d.ts +10 -0
- package/dist/types/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.d.ts +6 -0
- package/dist/types/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.d.ts +20 -0
- package/dist/types/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.d.ts +8 -0
- package/dist/types/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/WideLayout/WideLayout.d.ts +13 -0
- package/dist/types/step-container-v2/wireframes/WideLayout/WideLayout.d.ts.map +1 -0
- package/dist/types/step-container-v2/wireframes/WideLayout/WideLayout.stories.d.ts +9 -0
- package/dist/types/step-container-v2/wireframes/WideLayout/WideLayout.stories.d.ts.map +1 -0
- package/dist/types/step-navigation-link/index.d.ts +1 -1
- package/dist/types/step-navigation-link/index.d.ts.map +1 -1
- package/dist/types/upload-and-set-site-logo.d.ts +1 -1
- package/dist/types/upload-and-set-site-logo.d.ts.map +1 -1
- package/dist/types/utils/contrastChecker.d.ts +0 -10
- package/dist/types/utils/contrastChecker.d.ts.map +1 -1
- package/dist/types/utils/domain-suggester.d.ts.map +1 -1
- package/dist/types/utils/flows.d.ts +37 -46
- package/dist/types/utils/flows.d.ts.map +1 -1
- package/dist/types/wpcom-request.d.ts +7 -0
- package/dist/types/wpcom-request.d.ts.map +1 -0
- package/jest.config.js +0 -1
- package/package.json +44 -23
- package/src/action-buttons/index.tsx +0 -40
- package/src/action-buttons/style.scss +4 -40
- package/src/cart/create-cart-manager-client.ts +1 -1
- package/src/cart/index.tsx +60 -103
- package/src/cart/test/index.ts +14 -14
- package/src/confetti/index.tsx +1 -1
- package/src/flow-progress/use-flow-progress.ts +1 -66
- package/src/hooks/test/index.ts +54 -0
- package/src/hooks/use-persisted-state.ts +85 -0
- package/src/hooray/index.tsx +1 -1
- package/src/index.ts +7 -12
- package/src/intent-screen/test/index.tsx +10 -7
- package/src/mshots-image/index.tsx +52 -21
- package/src/mshots-image/style.scss +1 -0
- package/src/navigator/navigator-buttons/index.tsx +1 -0
- package/src/navigator/navigator-header/index.tsx +1 -0
- package/src/navigator/navigator-screens/hooks/use-navigator-screens.tsx +5 -1
- package/src/navigator/navigator-screens/navigator-screens.tsx +17 -0
- package/src/navigator/navigator-screens/types.ts +1 -0
- package/src/select-card-checkbox/index.tsx +10 -4
- package/src/select-card-checkbox/style.scss +11 -14
- package/src/select-card-checkbox-v2/index.tsx +51 -0
- package/src/select-card-checkbox-v2/style.scss +25 -0
- package/src/select-card-checkbox-v2/test/index.test.tsx +49 -0
- package/src/select-items/index.tsx +10 -4
- package/src/select-items/style.scss +2 -1
- package/src/setup-tailored-site-after-creation.ts +16 -60
- package/src/step-container/index.tsx +21 -42
- package/src/step-container/style.scss +35 -77
- package/src/step-container-v2/README.md +235 -0
- package/src/step-container-v2/components/ContentRow/ContentRow.tsx +27 -0
- package/src/step-container-v2/components/ContentRow/style.scss +26 -0
- package/src/step-container-v2/components/ContentWrapper/ContentWrapper.tsx +41 -0
- package/src/step-container-v2/components/ContentWrapper/style.scss +70 -0
- package/src/step-container-v2/components/Heading/Heading.tsx +31 -0
- package/src/step-container-v2/components/Heading/style.scss +47 -0
- package/src/step-container-v2/components/StepContainerV2/StepContainerV2.tsx +55 -0
- package/src/step-container-v2/components/StepContainerV2/context.ts +25 -0
- package/src/step-container-v2/components/StepContainerV2/style.scss +21 -0
- package/src/step-container-v2/components/StepCounter/StepCounter.tsx +32 -0
- package/src/step-container-v2/components/StepCounter/style.scss +4 -0
- package/src/step-container-v2/components/StickyBottomBar/StickyBottomBar.tsx +46 -0
- package/src/step-container-v2/components/StickyBottomBar/StickyBottomBarRenderer.tsx +41 -0
- package/src/step-container-v2/components/StickyBottomBar/style.scss +56 -0
- package/src/step-container-v2/components/TopBar/TopBar.tsx +116 -0
- package/src/step-container-v2/components/TopBar/TopBarRenderer.tsx +43 -0
- package/src/step-container-v2/components/TopBar/style.scss +75 -0
- package/src/step-container-v2/components/buttons/BackButton/BackButton.tsx +32 -0
- package/src/step-container-v2/components/buttons/BackButton/style.scss +16 -0
- package/src/step-container-v2/components/buttons/LinkButton/LinkButton.tsx +17 -0
- package/src/step-container-v2/components/buttons/LinkButton/style.scss +6 -0
- package/src/step-container-v2/components/buttons/PrimaryButton/PrimaryButton.tsx +17 -0
- package/src/step-container-v2/components/buttons/PrimaryButton/style.scss +6 -0
- package/src/step-container-v2/components/buttons/SecondaryButton/SecondaryButton.tsx +17 -0
- package/src/step-container-v2/components/buttons/SecondaryButton/style.scss +6 -0
- package/src/step-container-v2/components/buttons/SkipButton/SkipButton.tsx +30 -0
- package/src/step-container-v2/contexts/StepContainerV2Context.ts +23 -0
- package/src/step-container-v2/helpers/decorateButtonWithTracksEventRecording.ts +28 -0
- package/src/step-container-v2/helpers/normalizeButtonProps.ts +14 -0
- package/src/step-container-v2/helpers/wireframe-placeholder.tsx +28 -0
- package/src/step-container-v2/helpers/withStepContainerV2ContextDecorator.tsx +16 -0
- package/src/step-container-v2/index.tsx +24 -0
- package/src/step-container-v2/types.ts +4 -0
- package/src/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.stories.tsx +122 -0
- package/src/step-container-v2/wireframes/CenteredColumnLayout/CenteredColumnLayout.tsx +66 -0
- package/src/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.stories.tsx +51 -0
- package/src/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/FixedColumnOnTheLeftLayout.tsx +69 -0
- package/src/step-container-v2/wireframes/FixedColumnOnTheLeftLayout/style.scss +14 -0
- package/src/step-container-v2/wireframes/Loading/Loading.stories.tsx +27 -0
- package/src/step-container-v2/wireframes/Loading/Loading.tsx +52 -0
- package/src/step-container-v2/wireframes/Loading/style.scss +22 -0
- package/src/step-container-v2/wireframes/Loading/test/Loading.test.tsx +42 -0
- package/src/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.stories.tsx +21 -0
- package/src/step-container-v2/wireframes/PlaygroundLayout/PlaygroundLayout.tsx +31 -0
- package/src/step-container-v2/wireframes/PlaygroundLayout/style.scss +5 -0
- package/src/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.stories.tsx +93 -0
- package/src/step-container-v2/wireframes/TwoColumnLayout/TwoColumnLayout.tsx +93 -0
- package/src/step-container-v2/wireframes/TwoColumnLayout/style.scss +15 -0
- package/src/step-container-v2/wireframes/WideLayout/WideLayout.stories.tsx +83 -0
- package/src/step-container-v2/wireframes/WideLayout/WideLayout.tsx +44 -0
- package/src/step-navigation-link/index.tsx +3 -0
- package/src/step-navigation-link/style.scss +5 -3
- package/src/style-imports.d.ts +3 -0
- package/src/titles/styles.scss +2 -2
- package/src/upload-and-set-site-logo.ts +1 -1
- package/src/utils/contrastChecker.ts +0 -35
- package/src/utils/flows.ts +67 -123
- package/src/wpcom-request.ts +26 -0
- package/styles/mixins.scss +4 -4
- package/styles/variables.scss +2 -2
- package/tsconfig.json +1 -0
- package/dist/cjs/feature-icon/index.js +0 -19
- package/dist/cjs/feature-icon/index.js.map +0 -1
- package/dist/cjs/flow-progress/index.js +0 -14
- package/dist/cjs/flow-progress/index.js.map +0 -1
- package/dist/cjs/flow-progress/style.scss +0 -5
- package/dist/cjs/notice/index.js +0 -12
- package/dist/cjs/notice/index.js.map +0 -1
- package/dist/cjs/notice/style.scss +0 -19
- package/dist/cjs/select-card-radio/index.js +0 -21
- package/dist/cjs/select-card-radio/index.js.map +0 -1
- package/dist/cjs/select-card-radio/style.scss +0 -44
- package/dist/cjs/sensei-logo/index.js +0 -8
- package/dist/cjs/sensei-logo/index.js.map +0 -1
- package/dist/cjs/videopress-logo/index.js +0 -8
- package/dist/cjs/videopress-logo/index.js.map +0 -1
- package/dist/esm/feature-icon/index.js +0 -16
- package/dist/esm/feature-icon/index.js.map +0 -1
- package/dist/esm/flow-progress/index.js +0 -12
- package/dist/esm/flow-progress/index.js.map +0 -1
- package/dist/esm/flow-progress/style.scss +0 -5
- package/dist/esm/notice/index.js +0 -9
- package/dist/esm/notice/index.js.map +0 -1
- package/dist/esm/notice/style.scss +0 -19
- package/dist/esm/select-card-radio/index.js +0 -15
- package/dist/esm/select-card-radio/index.js.map +0 -1
- package/dist/esm/select-card-radio/style.scss +0 -44
- package/dist/esm/sensei-logo/index.js +0 -6
- package/dist/esm/sensei-logo/index.js.map +0 -1
- package/dist/esm/videopress-logo/index.js +0 -6
- package/dist/esm/videopress-logo/index.js.map +0 -1
- package/dist/types/feature-icon/index.d.ts +0 -9
- package/dist/types/feature-icon/index.d.ts.map +0 -1
- package/dist/types/flow-progress/index.d.ts +0 -9
- package/dist/types/flow-progress/index.d.ts.map +0 -1
- package/dist/types/notice/index.d.ts +0 -7
- package/dist/types/notice/index.d.ts.map +0 -1
- package/dist/types/select-card-radio/index.d.ts +0 -22
- package/dist/types/select-card-radio/index.d.ts.map +0 -1
- package/dist/types/sensei-logo/index.d.ts +0 -8
- package/dist/types/sensei-logo/index.d.ts.map +0 -1
- package/dist/types/videopress-logo/index.d.ts +0 -8
- package/dist/types/videopress-logo/index.d.ts.map +0 -1
- package/src/feature-icon/index.tsx +0 -102
- package/src/flow-progress/index.tsx +0 -22
- package/src/flow-progress/style.scss +0 -5
- package/src/notice/index.tsx +0 -16
- package/src/notice/style.scss +0 -19
- package/src/select-card-radio/index.tsx +0 -64
- package/src/select-card-radio/style.scss +0 -44
- package/src/select-card-radio/test/index.tsx +0 -50
- package/src/sensei-logo/index.tsx +0 -30
- package/src/videopress-logo/index.tsx +0 -36
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { CheckboxControl, __experimentalHStack as HStack, Spinner } from '@wordpress/components';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import { useId } from 'react';
|
|
4
|
+
import './style.scss';
|
|
5
|
+
|
|
6
|
+
type SelectCardCheckboxProps = {
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
className?: string;
|
|
9
|
+
checked?: boolean;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
isBusy?: boolean;
|
|
12
|
+
onChange: ( checked: boolean ) => void;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
const SelectCardCheckboxV2 = ( {
|
|
16
|
+
children,
|
|
17
|
+
className,
|
|
18
|
+
onChange,
|
|
19
|
+
disabled = false,
|
|
20
|
+
checked = false,
|
|
21
|
+
isBusy = false,
|
|
22
|
+
}: SelectCardCheckboxProps ) => {
|
|
23
|
+
const instanceId = useId();
|
|
24
|
+
const id = `select-card-checkbox-v2-${ instanceId }`;
|
|
25
|
+
|
|
26
|
+
return (
|
|
27
|
+
<HStack
|
|
28
|
+
spacing={ 2 }
|
|
29
|
+
as="label"
|
|
30
|
+
className={ clsx( 'select-card-checkbox-v2', className, { 'is-busy': isBusy } ) }
|
|
31
|
+
htmlFor={ id }
|
|
32
|
+
alignment="left"
|
|
33
|
+
aria-checked={ checked }
|
|
34
|
+
aria-labelledby={ `select-card-checkbox-v2-label-${ instanceId }` }
|
|
35
|
+
>
|
|
36
|
+
<HStack alignment="left" spacing={ 2 } as="span">
|
|
37
|
+
<CheckboxControl
|
|
38
|
+
__nextHasNoMarginBottom
|
|
39
|
+
checked={ checked }
|
|
40
|
+
id={ id }
|
|
41
|
+
onChange={ onChange }
|
|
42
|
+
disabled={ disabled || isBusy }
|
|
43
|
+
/>
|
|
44
|
+
<span id={ `select-card-checkbox-v2-label-${ instanceId }` }>{ children }</span>
|
|
45
|
+
</HStack>
|
|
46
|
+
{ isBusy && <Spinner /> }
|
|
47
|
+
</HStack>
|
|
48
|
+
);
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export default SelectCardCheckboxV2;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
@import "@wordpress/base-styles/mixins";
|
|
2
|
+
|
|
3
|
+
.select-card-checkbox-v2 {
|
|
4
|
+
border: 1px solid var(--color-surface-backdrop);
|
|
5
|
+
background: var(--color-surface-backdrop);
|
|
6
|
+
border-radius: 4px;
|
|
7
|
+
padding: 16px;
|
|
8
|
+
font-size: 0.875rem;
|
|
9
|
+
cursor: pointer;
|
|
10
|
+
|
|
11
|
+
&.is-busy {
|
|
12
|
+
cursor: progress;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
&:has(:checked) {
|
|
16
|
+
background: var(--color-accent-5);
|
|
17
|
+
border-color: var(--color-accent);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
&:has(:focus-visible) {
|
|
21
|
+
@include button-style__focus();
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jest-environment jsdom
|
|
3
|
+
*/
|
|
4
|
+
import '@testing-library/jest-dom';
|
|
5
|
+
import { fireEvent, render, screen } from '@testing-library/react';
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import SelectCardCheckboxV2 from '../index';
|
|
8
|
+
|
|
9
|
+
describe( 'SelectCardCheckboxV2', () => {
|
|
10
|
+
it( 'renders the elements and labels', () => {
|
|
11
|
+
render( <SelectCardCheckboxV2 onChange={ jest.fn() }>Hello</SelectCardCheckboxV2> );
|
|
12
|
+
expect( screen.getByRole( 'checkbox', { name: 'Hello' } ) ).toBeInTheDocument();
|
|
13
|
+
} );
|
|
14
|
+
|
|
15
|
+
it( 'renders the checked state', () => {
|
|
16
|
+
render(
|
|
17
|
+
<SelectCardCheckboxV2 onChange={ jest.fn() } checked>
|
|
18
|
+
Hello
|
|
19
|
+
</SelectCardCheckboxV2>
|
|
20
|
+
);
|
|
21
|
+
expect( screen.getByRole( 'checkbox', { name: 'Hello' } ) ).toBeChecked();
|
|
22
|
+
} );
|
|
23
|
+
|
|
24
|
+
it( 'renders the disabled state', () => {
|
|
25
|
+
render(
|
|
26
|
+
<SelectCardCheckboxV2 onChange={ jest.fn() } disabled>
|
|
27
|
+
Hello
|
|
28
|
+
</SelectCardCheckboxV2>
|
|
29
|
+
);
|
|
30
|
+
expect( screen.getByRole( 'checkbox', { name: 'Hello' } ) ).toBeDisabled();
|
|
31
|
+
} );
|
|
32
|
+
|
|
33
|
+
it( 'calls onChange when the checkbox is clicked', () => {
|
|
34
|
+
const onChange = jest.fn();
|
|
35
|
+
render( <SelectCardCheckboxV2 onChange={ onChange }>Hello</SelectCardCheckboxV2> );
|
|
36
|
+
fireEvent.click( screen.getByRole( 'checkbox', { name: 'Hello' } ) );
|
|
37
|
+
|
|
38
|
+
expect( onChange ).toHaveBeenCalledTimes( 1 );
|
|
39
|
+
expect( onChange ).toHaveBeenCalledWith( true );
|
|
40
|
+
} );
|
|
41
|
+
it( 'disables the checkbox when isBusy is true', () => {
|
|
42
|
+
render(
|
|
43
|
+
<SelectCardCheckboxV2 onChange={ jest.fn() } isBusy>
|
|
44
|
+
Hello
|
|
45
|
+
</SelectCardCheckboxV2>
|
|
46
|
+
);
|
|
47
|
+
expect( screen.getByRole( 'checkbox', { name: 'Hello' } ) ).toBeDisabled();
|
|
48
|
+
} );
|
|
49
|
+
} );
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Badge
|
|
1
|
+
import { Badge } from '@automattic/components';
|
|
2
|
+
import { Button } from '@wordpress/components';
|
|
2
3
|
import { Icon } from '@wordpress/icons';
|
|
3
4
|
import clsx from 'clsx';
|
|
4
5
|
import './style.scss';
|
|
@@ -16,6 +17,7 @@ export interface SelectItem< T > {
|
|
|
16
17
|
hidden?: boolean;
|
|
17
18
|
isPrimary?: boolean;
|
|
18
19
|
allItemClickable?: boolean;
|
|
20
|
+
'aria-label'?: string;
|
|
19
21
|
}
|
|
20
22
|
|
|
21
23
|
interface Props< T > {
|
|
@@ -38,15 +40,15 @@ function SelectItems< T >( { className, items, onSelect, preventWidows }: Props<
|
|
|
38
40
|
titleIcon,
|
|
39
41
|
actionText,
|
|
40
42
|
value,
|
|
41
|
-
isPrimary,
|
|
42
43
|
allItemClickable,
|
|
44
|
+
'aria-label': ariaLabel,
|
|
43
45
|
} ) => (
|
|
44
46
|
<div key={ key } className="select-items__item">
|
|
45
47
|
{ ! titleIcon && (
|
|
46
48
|
<Icon className="select-items__item-icon" icon={ icon } size={ 24 } />
|
|
47
49
|
) }
|
|
48
50
|
<div className="select-items__item-info-wrapper">
|
|
49
|
-
<div className="select-items__item-info">
|
|
51
|
+
<div className="select-items__item-info" aria-hidden="true">
|
|
50
52
|
<h2 className="select-items__item-title">
|
|
51
53
|
{ titleIcon && (
|
|
52
54
|
<Icon className="select-items__item-icon" icon={ titleIcon } size={ 24 } />
|
|
@@ -66,9 +68,12 @@ function SelectItems< T >( { className, items, onSelect, preventWidows }: Props<
|
|
|
66
68
|
</div>
|
|
67
69
|
{ actionText && (
|
|
68
70
|
<Button
|
|
69
|
-
|
|
71
|
+
label={ `${ title }. ${ actionText }` }
|
|
72
|
+
variant="secondary"
|
|
70
73
|
className="select-items__item-button"
|
|
71
74
|
onClick={ () => onSelect( value ) }
|
|
75
|
+
aria-hidden={ allItemClickable ? 'true' : 'false' }
|
|
76
|
+
tabIndex={ allItemClickable ? -1 : 0 }
|
|
72
77
|
>
|
|
73
78
|
{ actionText }
|
|
74
79
|
</Button>
|
|
@@ -78,6 +83,7 @@ function SelectItems< T >( { className, items, onSelect, preventWidows }: Props<
|
|
|
78
83
|
<button
|
|
79
84
|
className="select-items__item-clickable"
|
|
80
85
|
onClick={ () => onSelect( value ) }
|
|
86
|
+
aria-label={ ariaLabel || `${ title }. ${ description }` }
|
|
81
87
|
/>
|
|
82
88
|
) }
|
|
83
89
|
</div>
|
|
@@ -76,10 +76,11 @@
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
.select-items__item-button {
|
|
80
80
|
margin-top: 24px;
|
|
81
81
|
border-radius: 4px;
|
|
82
82
|
min-width: 130px;
|
|
83
|
+
background-color: var(--color-surface);
|
|
83
84
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
|
|
84
85
|
border: 1px solid rgb(195, 196, 199);
|
|
85
86
|
color: #101517;
|
|
@@ -1,26 +1,14 @@
|
|
|
1
1
|
import { recordTracksEvent } from '@automattic/calypso-analytics';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
SiteActions,
|
|
7
|
-
updateLaunchpadSettings,
|
|
8
|
-
} from '@automattic/data-stores';
|
|
9
|
-
import { select, dispatch } from '@wordpress/data';
|
|
10
|
-
import wpcomRequest from 'wpcom-proxy-request';
|
|
11
|
-
import {
|
|
12
|
-
isLinkInBioFlow,
|
|
13
|
-
isNewsletterFlow,
|
|
14
|
-
isNewsletterOrLinkInBioFlow,
|
|
15
|
-
LINK_IN_BIO_FLOW,
|
|
16
|
-
FREE_FLOW,
|
|
17
|
-
isFreeFlow,
|
|
18
|
-
} from './utils';
|
|
19
|
-
import type { ActiveTheme } from '@automattic/data-stores';
|
|
2
|
+
import { Onboard, OnboardSelect, Site } from '@automattic/data-stores';
|
|
3
|
+
import { select } from '@wordpress/data';
|
|
4
|
+
import { isNewsletterFlow } from './utils';
|
|
5
|
+
import wpcomRequest from './wpcom-request';
|
|
20
6
|
|
|
21
7
|
const ONBOARD_STORE = Onboard.register();
|
|
8
|
+
|
|
9
|
+
// TODO: This store registration should live somewhere else or just be called more centrally.
|
|
22
10
|
// `client_id` and `client_secret` are only needed when signing up users.
|
|
23
|
-
|
|
11
|
+
Site.register( { client_id: '', client_secret: '' } );
|
|
24
12
|
|
|
25
13
|
export const base64ImageToBlob = ( base64String: string ) => {
|
|
26
14
|
// extract content type and base64 payload from original string
|
|
@@ -51,11 +39,12 @@ interface SetupOnboardingSiteOptions {
|
|
|
51
39
|
|
|
52
40
|
export function setupSiteAfterCreation( { siteId, flowName }: SetupOnboardingSiteOptions ) {
|
|
53
41
|
// const { resetOnboardStore } = dispatch( ONBOARD_STORE );
|
|
54
|
-
const goals = ( select( ONBOARD_STORE ) as OnboardSelect ).getGoals();
|
|
55
|
-
const
|
|
56
|
-
const
|
|
57
|
-
|
|
58
|
-
|
|
42
|
+
const goals = ( select( ONBOARD_STORE ) as unknown as OnboardSelect ).getGoals();
|
|
43
|
+
const siteTitle = ( select( ONBOARD_STORE ) as unknown as OnboardSelect ).getSelectedSiteTitle();
|
|
44
|
+
const siteDescription = (
|
|
45
|
+
select( ONBOARD_STORE ) as unknown as OnboardSelect
|
|
46
|
+
).getSelectedSiteDescription();
|
|
47
|
+
const siteLogo = ( select( ONBOARD_STORE ) as unknown as OnboardSelect ).getSelectedSiteLogo();
|
|
59
48
|
|
|
60
49
|
if ( siteId && flowName ) {
|
|
61
50
|
const formData: ( string | File )[][] = [];
|
|
@@ -72,30 +61,8 @@ export function setupSiteAfterCreation( { siteId, flowName }: SetupOnboardingSit
|
|
|
72
61
|
|
|
73
62
|
const promises = [];
|
|
74
63
|
|
|
75
|
-
if (
|
|
76
|
-
|
|
77
|
-
if ( isLinkInBioFlow( flowName ) || isFreeFlow( flowName ) ) {
|
|
78
|
-
settings.site_intent = isLinkInBioFlow( flowName ) ? LINK_IN_BIO_FLOW : FREE_FLOW;
|
|
79
|
-
if ( selectedDesign && selectedDesign.is_virtual ) {
|
|
80
|
-
const { assembleSite } = dispatch( SITE_STORE ) as SiteActions;
|
|
81
|
-
promises.push(
|
|
82
|
-
wpcomRequest< ActiveTheme[] >( {
|
|
83
|
-
path: `/sites/${ encodeURIComponent( siteId ) }/themes?status=active`,
|
|
84
|
-
apiNamespace: 'wp/v2',
|
|
85
|
-
} ).then( ( activeThemes ) => {
|
|
86
|
-
assembleSite( String( siteId ), activeThemes[ 0 ].stylesheet, {
|
|
87
|
-
homeHtml: selectedDesign.recipe?.pattern_html,
|
|
88
|
-
headerHtml: selectedDesign.recipe?.header_html,
|
|
89
|
-
footerHtml: selectedDesign.recipe?.footer_html,
|
|
90
|
-
siteSetupOption: 'assembler-virtual-theme',
|
|
91
|
-
} );
|
|
92
|
-
} )
|
|
93
|
-
);
|
|
94
|
-
}
|
|
95
|
-
} else {
|
|
96
|
-
settings.site_intent = flowName;
|
|
97
|
-
}
|
|
98
|
-
|
|
64
|
+
if ( isNewsletterFlow( flowName ) ) {
|
|
65
|
+
settings.site_intent = flowName;
|
|
99
66
|
settings.launchpad_screen = 'full';
|
|
100
67
|
}
|
|
101
68
|
|
|
@@ -116,9 +83,8 @@ export function setupSiteAfterCreation( { siteId, flowName }: SetupOnboardingSit
|
|
|
116
83
|
promises.push(
|
|
117
84
|
wpcomRequest< { updated: object } >( {
|
|
118
85
|
path: `/sites/${ siteId }/onboarding-customization`,
|
|
119
|
-
method: 'POST',
|
|
120
86
|
apiNamespace: 'wpcom/v2',
|
|
121
|
-
|
|
87
|
+
method: 'POST',
|
|
122
88
|
formData,
|
|
123
89
|
} ).then( () => {
|
|
124
90
|
recordTracksEvent( 'calypso_signup_site_options_submit', {
|
|
@@ -134,16 +100,6 @@ export function setupSiteAfterCreation( { siteId, flowName }: SetupOnboardingSit
|
|
|
134
100
|
} )
|
|
135
101
|
);
|
|
136
102
|
|
|
137
|
-
if ( isFreeFlow( flowName ) ) {
|
|
138
|
-
if ( siteTitle || siteDescription || siteLogo ) {
|
|
139
|
-
promises.push(
|
|
140
|
-
updateLaunchpadSettings( siteId, {
|
|
141
|
-
checklist_statuses: { setup_free: true },
|
|
142
|
-
} )
|
|
143
|
-
);
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
|
|
147
103
|
return Promise.all( promises );
|
|
148
104
|
}
|
|
149
105
|
}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { JetpackLogo, WooCommerceWooLogo } from '@automattic/components';
|
|
2
2
|
import clsx from 'clsx';
|
|
3
3
|
import { TranslateResult, useTranslate } from 'i18n-calypso';
|
|
4
4
|
import { ReactElement } from 'react';
|
|
5
5
|
import ActionButtons from '../action-buttons';
|
|
6
|
-
import SenseiLogo from '../sensei-logo';
|
|
7
6
|
import StepNavigationLink from '../step-navigation-link';
|
|
8
|
-
import VideoPressLogo from '../videopress-logo';
|
|
9
7
|
import './style.scss';
|
|
10
8
|
|
|
11
9
|
interface Props {
|
|
@@ -13,7 +11,6 @@ interface Props {
|
|
|
13
11
|
stepSectionName?: string;
|
|
14
12
|
stepContent: ReactElement;
|
|
15
13
|
shouldHideNavButtons?: boolean;
|
|
16
|
-
shouldStickyNavButtons?: boolean;
|
|
17
14
|
hasStickyNavButtonsPadding?: boolean;
|
|
18
15
|
hideBack?: boolean;
|
|
19
16
|
hideSkip?: boolean;
|
|
@@ -23,6 +20,7 @@ interface Props {
|
|
|
23
20
|
backLabelText?: TranslateResult;
|
|
24
21
|
skipLabelText?: TranslateResult;
|
|
25
22
|
nextLabelText?: TranslateResult;
|
|
23
|
+
notice?: ReactElement;
|
|
26
24
|
formattedHeader?: ReactElement;
|
|
27
25
|
hideFormattedHeader?: boolean;
|
|
28
26
|
headerImageUrl?: string;
|
|
@@ -37,23 +35,21 @@ interface Props {
|
|
|
37
35
|
isFullLayout?: boolean;
|
|
38
36
|
isHorizontalLayout?: boolean;
|
|
39
37
|
goBack?: () => void;
|
|
38
|
+
onSkip?: () => void;
|
|
40
39
|
goNext?: () => void;
|
|
41
40
|
flowName?: string;
|
|
42
41
|
intent?: string;
|
|
43
42
|
recordTracksEvent: ( eventName: string, eventProperties: object ) => void;
|
|
44
43
|
showHeaderJetpackPowered?: boolean;
|
|
45
44
|
showJetpackPowered?: boolean;
|
|
46
|
-
showHeaderWooCommercePowered?: boolean;
|
|
47
45
|
showFooterWooCommercePowered?: boolean;
|
|
48
|
-
|
|
49
|
-
showVideoPressPowered?: boolean;
|
|
46
|
+
backUrl?: string;
|
|
50
47
|
}
|
|
51
48
|
|
|
52
49
|
const StepContainer: React.FC< Props > = ( {
|
|
53
50
|
stepContent,
|
|
54
51
|
stepName,
|
|
55
52
|
shouldHideNavButtons,
|
|
56
|
-
shouldStickyNavButtons,
|
|
57
53
|
hasStickyNavButtonsPadding,
|
|
58
54
|
hideBack,
|
|
59
55
|
backLabelText,
|
|
@@ -63,6 +59,7 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
63
59
|
skipHeadingText,
|
|
64
60
|
hideNext = true,
|
|
65
61
|
nextLabelText,
|
|
62
|
+
notice,
|
|
66
63
|
formattedHeader,
|
|
67
64
|
headerImageUrl,
|
|
68
65
|
headerButton,
|
|
@@ -75,17 +72,16 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
75
72
|
isExternalBackUrl,
|
|
76
73
|
isLargeSkipLayout,
|
|
77
74
|
customizedActionButtons,
|
|
75
|
+
backUrl,
|
|
78
76
|
goBack,
|
|
77
|
+
onSkip,
|
|
79
78
|
goNext,
|
|
80
79
|
flowName,
|
|
81
80
|
intent,
|
|
82
81
|
stepSectionName,
|
|
83
82
|
recordTracksEvent,
|
|
84
83
|
showHeaderJetpackPowered,
|
|
85
|
-
showHeaderWooCommercePowered,
|
|
86
84
|
showJetpackPowered,
|
|
87
|
-
showSenseiPowered,
|
|
88
|
-
showVideoPressPowered,
|
|
89
85
|
showFooterWooCommercePowered,
|
|
90
86
|
} ) => {
|
|
91
87
|
const translate = useTranslate();
|
|
@@ -107,15 +103,16 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
107
103
|
}
|
|
108
104
|
};
|
|
109
105
|
|
|
110
|
-
function
|
|
106
|
+
function renderBackButton() {
|
|
111
107
|
// Hide back button if goBack is falsy, it won't do anything in that case.
|
|
112
|
-
if ( shouldHideNavButtons || ! goBack ) {
|
|
108
|
+
if ( shouldHideNavButtons || ( ! goBack && ! backUrl ) ) {
|
|
113
109
|
return null;
|
|
114
110
|
}
|
|
115
111
|
return (
|
|
116
112
|
<StepNavigationLink
|
|
117
113
|
direction="back"
|
|
118
114
|
handleClick={ goBack }
|
|
115
|
+
backUrl={ backUrl }
|
|
119
116
|
label={ backLabelText }
|
|
120
117
|
hasBackIcon
|
|
121
118
|
rel={ isExternalBackUrl ? 'external' : '' }
|
|
@@ -124,8 +121,10 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
124
121
|
);
|
|
125
122
|
}
|
|
126
123
|
|
|
127
|
-
function
|
|
128
|
-
|
|
124
|
+
function renderSkipButton() {
|
|
125
|
+
const skipAction = onSkip ?? goNext;
|
|
126
|
+
|
|
127
|
+
if ( shouldHideNavButtons || ! skipAction ) {
|
|
129
128
|
return null;
|
|
130
129
|
}
|
|
131
130
|
|
|
@@ -136,7 +135,7 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
136
135
|
) }
|
|
137
136
|
<StepNavigationLink
|
|
138
137
|
direction="forward"
|
|
139
|
-
handleClick={
|
|
138
|
+
handleClick={ skipAction }
|
|
140
139
|
label={ skipLabelText }
|
|
141
140
|
cssClass={ clsx( 'step-container__navigation-link', 'has-underline', {
|
|
142
141
|
'has-skip-heading': skipHeadingText,
|
|
@@ -148,7 +147,7 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
148
147
|
);
|
|
149
148
|
}
|
|
150
149
|
|
|
151
|
-
function
|
|
150
|
+
function renderNextButton() {
|
|
152
151
|
if ( shouldHideNavButtons || ! goNext ) {
|
|
153
152
|
return null;
|
|
154
153
|
}
|
|
@@ -179,20 +178,17 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
179
178
|
<ActionButtons
|
|
180
179
|
className={ clsx( 'step-container__navigation', {
|
|
181
180
|
'should-hide-nav-buttons': shouldHideNavButtons,
|
|
182
|
-
'should-sticky-nav-buttons': shouldStickyNavButtons,
|
|
183
181
|
'has-sticky-nav-buttons-padding': hasStickyNavButtonsPadding,
|
|
184
182
|
} ) }
|
|
185
183
|
>
|
|
186
|
-
{
|
|
187
|
-
|
|
188
|
-
) }
|
|
189
|
-
{ ! hideBack && <BackButton /> }
|
|
190
|
-
{ ! hideSkip && skipButtonAlign === 'top' && <SkipButton /> }
|
|
191
|
-
{ ! hideNext && <NextButton /> }
|
|
184
|
+
{ ! hideBack && renderBackButton() }
|
|
185
|
+
{ ! hideSkip && skipButtonAlign === 'top' && renderSkipButton() }
|
|
186
|
+
{ ! hideNext && renderNextButton() }
|
|
192
187
|
{ customizedActionButtons }
|
|
193
188
|
</ActionButtons>
|
|
194
189
|
{ ! hideFormattedHeader && (
|
|
195
190
|
<div className="step-container__header">
|
|
191
|
+
{ notice }
|
|
196
192
|
{ formattedHeader }
|
|
197
193
|
{ headerImageUrl && (
|
|
198
194
|
<div className="step-container__header-image">
|
|
@@ -205,11 +201,6 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
205
201
|
<JetpackLogo monochrome size={ 18 } /> <span>{ translate( 'Jetpack powered' ) }</span>
|
|
206
202
|
</div>
|
|
207
203
|
) }
|
|
208
|
-
{ showHeaderWooCommercePowered && (
|
|
209
|
-
<div className="step-container__header-woocommerce-powered">
|
|
210
|
-
<WooCommerceWooLogo /> <span>{ translate( 'WooCommerce powered' ) }</span>
|
|
211
|
-
</div>
|
|
212
|
-
) }
|
|
213
204
|
</div>
|
|
214
205
|
) }
|
|
215
206
|
|
|
@@ -218,7 +209,7 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
218
209
|
{ ! hideSkip && skipButtonAlign === 'bottom' && (
|
|
219
210
|
<div className="step-container__buttons">
|
|
220
211
|
{ isLargeSkipLayout && <hr className="step-container__skip-hr" /> }
|
|
221
|
-
|
|
212
|
+
{ renderSkipButton() }
|
|
222
213
|
</div>
|
|
223
214
|
) }
|
|
224
215
|
{ showJetpackPowered && (
|
|
@@ -232,18 +223,6 @@ const StepContainer: React.FC< Props > = ( {
|
|
|
232
223
|
<WooCommerceWooLogo /> <span>{ translate( 'WooCommerce powered' ) }</span>
|
|
233
224
|
</div>
|
|
234
225
|
) }
|
|
235
|
-
|
|
236
|
-
{ showSenseiPowered && (
|
|
237
|
-
<div className="step-container__sensei-powered">
|
|
238
|
-
<SenseiLogo /> <span>{ translate( 'Powered by Sensei' ) }</span>
|
|
239
|
-
</div>
|
|
240
|
-
) }
|
|
241
|
-
|
|
242
|
-
{ showVideoPressPowered && (
|
|
243
|
-
<div className="step-container__videopress-powered">
|
|
244
|
-
<VideoPressLogo size={ 24 } /> <span>{ translate( 'Powered by VideoPress' ) }</span>
|
|
245
|
-
</div>
|
|
246
|
-
) }
|
|
247
226
|
</div>
|
|
248
227
|
);
|
|
249
228
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
@import "@wordpress/base-styles/breakpoints";
|
|
2
2
|
@import "@wordpress/base-styles/mixins";
|
|
3
|
-
@import "../../styles/mixins
|
|
3
|
+
@import "../../styles/mixins";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* General
|
|
@@ -41,6 +41,12 @@
|
|
|
41
41
|
padding-inline-end: 20px;
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
|
+
|
|
45
|
+
@include break-xlarge {
|
|
46
|
+
.step-container__header .formatted-header {
|
|
47
|
+
margin-top: 0;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
44
50
|
}
|
|
45
51
|
|
|
46
52
|
.step-container__buttons {
|
|
@@ -71,44 +77,34 @@
|
|
|
71
77
|
* Header
|
|
72
78
|
*/
|
|
73
79
|
.step-container__header {
|
|
74
|
-
margin-
|
|
75
|
-
margin-
|
|
80
|
+
margin-top: 32px;
|
|
81
|
+
margin-bottom: 48px;
|
|
76
82
|
display: block;
|
|
77
83
|
justify-content: space-between;
|
|
78
84
|
align-items: center;
|
|
79
85
|
|
|
80
86
|
.formatted-header {
|
|
81
87
|
margin: 0;
|
|
82
|
-
|
|
88
|
+
|
|
89
|
+
@include break-xlarge {
|
|
90
|
+
margin-top: 88px; // 56px + 32px
|
|
91
|
+
}
|
|
83
92
|
|
|
84
93
|
.formatted-header__title {
|
|
85
|
-
@include onboarding-font-recoleta;
|
|
86
|
-
color: var(--studio-gray-100);
|
|
87
|
-
letter-spacing: 0.2px;
|
|
88
|
-
font-size: 2.15rem; /* stylelint-disable-line scales/font-sizes */
|
|
89
|
-
font-weight: 400;
|
|
90
|
-
padding: 0;
|
|
91
94
|
margin: 0;
|
|
92
95
|
|
|
96
|
+
@include onboarding-font-recoleta;
|
|
97
|
+
color: var(--color-neutral-100);
|
|
98
|
+
font-size: 2rem;
|
|
99
|
+
|
|
93
100
|
@include break-xlarge {
|
|
94
101
|
font-size: 2.75rem;
|
|
95
102
|
}
|
|
96
103
|
}
|
|
97
104
|
|
|
98
105
|
.formatted-header__subtitle {
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
color: var(--studio-gray-60);
|
|
102
|
-
font-size: 1rem;
|
|
103
|
-
margin-top: 16px;
|
|
104
|
-
line-height: 24px;
|
|
105
|
-
|
|
106
|
-
&.is-center-align {
|
|
107
|
-
text-align: center;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
@include break-small {
|
|
111
|
-
margin-top: 8px;
|
|
106
|
+
@include break-xlarge {
|
|
107
|
+
font-size: 1rem;
|
|
112
108
|
}
|
|
113
109
|
}
|
|
114
110
|
}
|
|
@@ -133,11 +129,6 @@
|
|
|
133
129
|
}
|
|
134
130
|
}
|
|
135
131
|
}
|
|
136
|
-
|
|
137
|
-
@include break-small {
|
|
138
|
-
flex-wrap: wrap;
|
|
139
|
-
margin-top: 24px;
|
|
140
|
-
}
|
|
141
132
|
}
|
|
142
133
|
|
|
143
134
|
/**
|
|
@@ -150,21 +141,28 @@
|
|
|
150
141
|
}
|
|
151
142
|
}
|
|
152
143
|
.step-container__navigation.action-buttons {
|
|
153
|
-
background-color: $white;
|
|
154
144
|
height: 60px;
|
|
155
145
|
align-items: center;
|
|
156
146
|
justify-content: space-between;
|
|
157
147
|
display: flex;
|
|
158
148
|
font-size: 0.875rem;
|
|
159
|
-
position: fixed;
|
|
160
|
-
z-index: 30;
|
|
161
|
-
inset-inline-start: 0;
|
|
162
|
-
inset-inline-end: 0;
|
|
163
149
|
bottom: 0;
|
|
164
|
-
padding: 0 20px;
|
|
165
150
|
margin: 0;
|
|
166
151
|
border-top: none;
|
|
167
|
-
|
|
152
|
+
|
|
153
|
+
position: absolute;
|
|
154
|
+
top: 8px;
|
|
155
|
+
inset-inline-start: 72px;
|
|
156
|
+
inset-inline-end: 24px;
|
|
157
|
+
// Align with wordpress logo in signup-header
|
|
158
|
+
padding: 1px 0 0;
|
|
159
|
+
background-color: transparent;
|
|
160
|
+
border: none;
|
|
161
|
+
box-shadow: none;
|
|
162
|
+
|
|
163
|
+
&.has-sticky-nav-buttons-padding {
|
|
164
|
+
padding-bottom: 48px;
|
|
165
|
+
}
|
|
168
166
|
|
|
169
167
|
&:empty {
|
|
170
168
|
display: none;
|
|
@@ -215,31 +213,6 @@
|
|
|
215
213
|
display: block;
|
|
216
214
|
}
|
|
217
215
|
}
|
|
218
|
-
|
|
219
|
-
@include break-small {
|
|
220
|
-
position: absolute;
|
|
221
|
-
top: 8px;
|
|
222
|
-
inset-inline-start: 72px;
|
|
223
|
-
inset-inline-end: 24px;
|
|
224
|
-
// Align with wordpress logo in signup-header
|
|
225
|
-
padding: 1px 0 0;
|
|
226
|
-
background-color: transparent;
|
|
227
|
-
border: none;
|
|
228
|
-
box-shadow: none;
|
|
229
|
-
|
|
230
|
-
&.should-sticky-nav-buttons {
|
|
231
|
-
position: fixed;
|
|
232
|
-
inset-inline-start: 0;
|
|
233
|
-
inset-inline-end: 0;
|
|
234
|
-
padding-inline-start: 24px;
|
|
235
|
-
padding-inline-end: 24px;
|
|
236
|
-
background-color: $white;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
&.has-sticky-nav-buttons-padding {
|
|
240
|
-
padding-bottom: 48px;
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
216
|
}
|
|
244
217
|
|
|
245
218
|
/**
|
|
@@ -248,22 +221,15 @@
|
|
|
248
221
|
.step-container__content {
|
|
249
222
|
margin-top: 0;
|
|
250
223
|
display: block;
|
|
251
|
-
min-height: 65vh;
|
|
252
|
-
|
|
253
|
-
@supports ( min-height: 65svh ) {
|
|
254
|
-
min-height: calc(65svh - 50px);
|
|
255
|
-
}
|
|
256
224
|
}
|
|
257
225
|
|
|
258
226
|
/**
|
|
259
|
-
* Jetpack
|
|
227
|
+
* Jetpack and WooCommerce Powered
|
|
260
228
|
*/
|
|
261
229
|
.step-container__jetpack-powered,
|
|
262
230
|
.step-container__header-jetpack-powered,
|
|
263
231
|
.step-container__woocommerce-powered,
|
|
264
|
-
.step-container__header-woocommerce-powered
|
|
265
|
-
.step-container__sensei-powered,
|
|
266
|
-
.step-container__videopress-powered {
|
|
232
|
+
.step-container__header-woocommerce-powered {
|
|
267
233
|
display: flex;
|
|
268
234
|
justify-content: center;
|
|
269
235
|
align-items: center;
|
|
@@ -293,12 +259,4 @@
|
|
|
293
259
|
visibility: visible;
|
|
294
260
|
}
|
|
295
261
|
}
|
|
296
|
-
|
|
297
|
-
.step-container__sensei-powered {
|
|
298
|
-
padding-bottom: 24px;
|
|
299
|
-
|
|
300
|
-
svg {
|
|
301
|
-
margin-inline-end: 8px;
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
262
|
}
|