From c3ecf06a949a727475d061d6bf76a8ff13dcf7aa Mon Sep 17 00:00:00 2001 From: Christopher Berge Hove Date: Thu, 26 Sep 2024 14:36:40 +0200 Subject: [PATCH] chore: add milestones under feature flag default on (#801) Co-authored-by: Noggling --- .changeset/pr-801-2093607063.md | 5 +++++ .../portal-client/src/lib/portal-framework-config.tsx | 6 ++++++ .../portal-pages/src/pages/project-page/Overview.tsx | 9 ++++----- 3 files changed, 15 insertions(+), 5 deletions(-) create mode 100644 .changeset/pr-801-2093607063.md diff --git a/.changeset/pr-801-2093607063.md b/.changeset/pr-801-2093607063.md new file mode 100644 index 000000000..0143171f6 --- /dev/null +++ b/.changeset/pr-801-2093607063.md @@ -0,0 +1,5 @@ + +--- +"fusion-project-portal": patch +--- +Add milestones under feature flag default on diff --git a/client/packages/portal-client/src/lib/portal-framework-config.tsx b/client/packages/portal-client/src/lib/portal-framework-config.tsx index fa054eaeb..4e75b2752 100644 --- a/client/packages/portal-client/src/lib/portal-framework-config.tsx +++ b/client/packages/portal-client/src/lib/portal-framework-config.tsx @@ -158,6 +158,12 @@ export function createPortalFramework(portalConfig: PortalConfig) { description: 'When enabled you will get your allocated projects on the portal landing page', enabled: true, }, + { + key: 'project-milestones', + title: 'Project Milestones', + description: 'When enabled you will see the project milestones on the project landing page', + enabled: true, + }, { key: 'cc-tab', title: 'New Construction and Commissioning Tab', diff --git a/client/packages/portal-pages/src/pages/project-page/Overview.tsx b/client/packages/portal-pages/src/pages/project-page/Overview.tsx index be9546f03..8868becd3 100644 --- a/client/packages/portal-pages/src/pages/project-page/Overview.tsx +++ b/client/packages/portal-pages/src/pages/project-page/Overview.tsx @@ -10,9 +10,9 @@ import { Milestones } from './components/milestones/Milestones'; import { ContextRelationNavigation } from '../sheared/components/context-relation-navigation/ContextRelationNavigation'; export const Overview = ({ openAllApps }: { openAllApps: () => void }) => { - const { feature } = useFrameworkFeature('app-search'); + const { feature: appSearchFeature } = useFrameworkFeature('app-search'); + const { feature: projectMilestonesFeature } = useFrameworkFeature('project-milestones'); - const { feature: ccTabFeature } = useFrameworkFeature('cc-tab'); return ( @@ -22,9 +22,8 @@ export const Overview = ({ openAllApps }: { openAllApps: () => void }) => { - {/* Todo remove when cc tab is not in feature flag mode */} - {ccTabFeature?.enabled === false && } - {feature?.enabled && } + {projectMilestonesFeature?.enabled && } + {appSearchFeature?.enabled && }