From 85b67ae330492801a3e88cfe2e0817f0da8cf0aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20G=C3=B3is?= Date: Wed, 18 Sep 2024 08:55:50 +0100 Subject: [PATCH] chore: add eventTimeline feature flag (#8159) https://linear.app/unleash/issue/2-2658/create-eventtimeline-feature-flag Adds a new `eventTimeline` feature flag for the new event timeline feature. I think `eventTimeline` is an appropriate name given the feature description and the way it is evolving, but I'm open to suggestions. ~~This also assumes that this feature will target OSS.~~ Confirmed that this will be a premium feature. --- frontend/src/interfaces/uiConfig.ts | 1 + src/lib/types/experimental.ts | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/frontend/src/interfaces/uiConfig.ts b/frontend/src/interfaces/uiConfig.ts index 65070583ec..9c62909e2e 100644 --- a/frontend/src/interfaces/uiConfig.ts +++ b/frontend/src/interfaces/uiConfig.ts @@ -90,6 +90,7 @@ export type UiFlags = { archiveProjects?: boolean; projectListImprovements?: boolean; onboardingUI?: boolean; + eventTimeline?: boolean; }; export interface IVersionInfo { diff --git a/src/lib/types/experimental.ts b/src/lib/types/experimental.ts index 09e56e2bc3..f72544ea73 100644 --- a/src/lib/types/experimental.ts +++ b/src/lib/types/experimental.ts @@ -63,7 +63,8 @@ export type IFlagKey = | 'addonUsageMetrics' | 'onboardingMetrics' | 'onboardingUI' - | 'projectRoleAssignment'; + | 'projectRoleAssignment' + | 'eventTimeline'; export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>; @@ -312,6 +313,10 @@ const flags: IFlags = { process.env.UNLEASH_EXPERIMENTAL_PROJECT_ROLE_ASSIGNMENT, false, ), + eventTimeline: parseEnvVarBoolean( + process.env.UNLEASH_EXPERIMENTAL_EVENT_TIMELINE, + false, + ), }; export const defaultExperimentalOptions: IExperimentalOptions = {