| | import config from '@automattic/calypso-config'; |
| | import { |
| | START_WRITING_FLOW, |
| | CONNECT_DOMAIN_FLOW, |
| | NEW_HOSTED_SITE_FLOW, |
| | TRANSFERRING_HOSTED_SITE_FLOW, |
| | DOMAIN_TRANSFER, |
| | GOOGLE_TRANSFER, |
| | HUNDRED_YEAR_DOMAIN_TRANSFER, |
| | REBLOGGING_FLOW, |
| | SITE_MIGRATION_FLOW, |
| | ENTREPRENEUR_FLOW, |
| | ONBOARDING_FLOW, |
| | HUNDRED_YEAR_DOMAIN_FLOW, |
| | EXAMPLE_FLOW, |
| | AI_SITE_BUILDER_FLOW, |
| | ONBOARDING_UNIFIED_FLOW, |
| | } from '@automattic/onboarding'; |
| | import type { Flow, FlowV2 } from '../declarative-flow/internals/types'; |
| |
|
| | const availableFlows: Record< string, () => Promise< { default: FlowV2< any > } > > = { |
| | [ NEW_HOSTED_SITE_FLOW ]: () => |
| | import( |
| | './flows/new-hosted-site-flow/new-hosted-site-flow' |
| | ), |
| |
|
| | [ ONBOARDING_FLOW ]: () => |
| | import( './flows/onboarding/onboarding' ), |
| |
|
| | [ SITE_MIGRATION_FLOW ]: () => |
| | import( |
| | './flows/site-migration-flow/site-migration-flow' |
| | ), |
| |
|
| | [ EXAMPLE_FLOW ]: () => |
| | import( './flows/00-example-flow/example' ), |
| |
|
| | [ ONBOARDING_UNIFIED_FLOW ]: () => |
| | import( |
| | './flows/onboarding-unified/onboarding-unified' |
| | ), |
| | }; |
| |
|
| | |
| | |
| | |
| | export const deprecatedV1Flows: Record< string, () => Promise< { default: Flow } > > = { |
| | 'site-setup': () => |
| | import( './flows/site-setup-flow/site-setup-flow' ), |
| |
|
| | 'copy-site': () => |
| | import( './flows/copy-site/copy-site' ), |
| |
|
| | newsletter: () => |
| | import( './flows/newsletter/newsletter' ), |
| |
|
| | [ ENTREPRENEUR_FLOW ]: () => |
| | import( |
| | './flows/entrepreneur-flow/entrepreneur-flow' |
| | ), |
| |
|
| | 'readymade-template': () => |
| | import( |
| | './flows/readymade-template/readymade-template' |
| | ), |
| |
|
| | 'update-design': () => |
| | import( './flows/update-design/update-design' ), |
| |
|
| | 'update-options': () => |
| | import( './flows/update-options/update-options' ), |
| |
|
| | 'domain-upsell': () => |
| | import( './flows/domain-upsell/domain-upsell' ), |
| |
|
| | build: () => import( './flows/build/build' ), |
| |
|
| | write: () => import( './flows/write/write' ), |
| |
|
| | [ START_WRITING_FLOW ]: () => |
| | import( './flows/start-writing/start-writing' ), |
| |
|
| | [ CONNECT_DOMAIN_FLOW ]: () => |
| | import( './flows/connect-domain/connect-domain' ), |
| |
|
| | [ TRANSFERRING_HOSTED_SITE_FLOW ]: () => |
| | import( |
| | './flows/transferring-hosted-site-flow/transferring-hosted-site-flow' |
| | ), |
| |
|
| | [ DOMAIN_TRANSFER ]: () => |
| | import( './flows/domain-transfer/domain-transfer' ), |
| |
|
| | [ GOOGLE_TRANSFER ]: () => |
| | import( './flows/google-transfer/google-transfer' ), |
| |
|
| | [ 'plugin-bundle' ]: () => |
| | import( |
| | './flows/plugin-bundle-flow/plugin-bundle-flow' |
| | ), |
| |
|
| | [ 'hundred-year-plan' ]: () => |
| | import( |
| | './flows/hundred-year-plan/hundred-year-plan' |
| | ), |
| |
|
| | 'domain-user-transfer': () => |
| | import( |
| | './flows/domain-user-transfer/domain-user-transfer' |
| | ), |
| |
|
| | [ REBLOGGING_FLOW ]: () => |
| | import( './flows/reblogging/reblogging' ), |
| | }; |
| |
|
| | const aiSiteBuilderFlows: Record< string, () => Promise< { default: FlowV2< any > } > > = |
| | config.isEnabled( 'calypso/ai-site-builder-flow' ) |
| | ? { |
| | [ AI_SITE_BUILDER_FLOW ]: () => import( './flows/ai-site-builder/ai-site-builder' ), |
| | } |
| | : {}; |
| |
|
| | const hundredYearDomainFlow: Record< string, () => Promise< { default: Flow } > > = { |
| | [ HUNDRED_YEAR_DOMAIN_FLOW ]: () => |
| | import( |
| | './flows/hundred-year-domain/hundred-year-domain' |
| | ), |
| | [ HUNDRED_YEAR_DOMAIN_TRANSFER ]: () => |
| | import( |
| | './flows/hundred-year-domain-transfer/hundred-year-domain-transfer' |
| | ), |
| | }; |
| |
|
| | export default { |
| | ...availableFlows, |
| | ...deprecatedV1Flows, |
| | ...hundredYearDomainFlow, |
| | ...aiSiteBuilderFlows, |
| | }; |
| |
|