diff --git a/apps/audius-client/packages/common/src/services/remote-config/feature-flags.ts b/apps/audius-client/packages/common/src/services/remote-config/feature-flags.ts index 7766260c466..8e194004cb7 100644 --- a/apps/audius-client/packages/common/src/services/remote-config/feature-flags.ts +++ b/apps/audius-client/packages/common/src/services/remote-config/feature-flags.ts @@ -49,7 +49,8 @@ export enum FeatureFlags { PLAYLIST_UPDATES_POST_QA = 'playlist_updates_post_qa', AI_ATTRIBUTION = 'ai_attribution', WRITE_METADATA_THROUGH_CHAIN = 'write_metadata_through_chain', - DEVELOPER_APPS_PAGE = 'developer_apps_page' + DEVELOPER_APPS_PAGE = 'developer_apps_page', + UPLOAD_REDESIGN_ENABLED = 'upload_redesign_enabled' } type FlagDefaults = Record @@ -114,5 +115,6 @@ export const flagDefaults: FlagDefaults = { [FeatureFlags.PLAYLIST_UPDATES_POST_QA]: false, [FeatureFlags.AI_ATTRIBUTION]: false, [FeatureFlags.WRITE_METADATA_THROUGH_CHAIN]: false, - [FeatureFlags.DEVELOPER_APPS_PAGE]: false + [FeatureFlags.DEVELOPER_APPS_PAGE]: false, + [FeatureFlags.UPLOAD_REDESIGN_ENABLED]: false } diff --git a/apps/audius-client/packages/web/src/pages/upload-page/UploadPage.tsx b/apps/audius-client/packages/web/src/pages/upload-page/UploadPage.tsx new file mode 100644 index 00000000000..32f25f624d0 --- /dev/null +++ b/apps/audius-client/packages/web/src/pages/upload-page/UploadPage.tsx @@ -0,0 +1,20 @@ +import { FeatureFlags } from '@audius/common' + +import { useFlag } from 'hooks/useRemoteConfig' + +import UploadPageLegacy from './UploadPageLegacy' +import UploadPageNew from './UploadPageNew' + +export const UploadPage = (props: any) => { + const { isEnabled: isRedesignEnabled } = useFlag( + FeatureFlags.UPLOAD_REDESIGN_ENABLED + ) + + return isRedesignEnabled ? ( + + ) : ( + + ) +} + +export default UploadPage diff --git a/apps/audius-client/packages/web/src/pages/upload-page/UploadPage.js b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageLegacy.js similarity index 99% rename from apps/audius-client/packages/web/src/pages/upload-page/UploadPage.js rename to apps/audius-client/packages/web/src/pages/upload-page/UploadPageLegacy.js index 25a80e4bfed..eb0aceef0cb 100644 --- a/apps/audius-client/packages/web/src/pages/upload-page/UploadPage.js +++ b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageLegacy.js @@ -39,7 +39,7 @@ const Pages = Object.freeze({ const SHOW_FIRST_UPLOAD_MODAL_DELAY = 3000 -const UploadPage = (props) => { +const UploadPageLegacy = (props) => { const { children, page } = props return ( @@ -451,7 +451,7 @@ class Upload extends Component { contentClassName={styles.upload} header={header} > - {currentPage} + {currentPage} ) } diff --git a/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.module.css b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.module.css new file mode 100644 index 00000000000..6c879ced47a --- /dev/null +++ b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.module.css @@ -0,0 +1,9 @@ +.upload { + text-align: left; +} + +.header { + display: flex; + align-items: center; + justify-content: center; +} diff --git a/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.tsx b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.tsx new file mode 100644 index 00000000000..48c31cd2966 --- /dev/null +++ b/apps/audius-client/packages/web/src/pages/upload-page/UploadPageNew.tsx @@ -0,0 +1,25 @@ +import { UploadType } from '@audius/common' + +import Header from 'components/header/desktop/Header' +import Page from 'components/page/Page' + +import styles from './UploadPage.module.css' + +type UploadPageProps = { + uploadType: UploadType +} + +export const UploadPageNew = (props: UploadPageProps) => { + return ( + } + > + This is the new upload page + + ) +} + +export default UploadPageNew