Skip to content

Commit

Permalink
feat: add internalMessageBanner feature flag (#4990)
Browse files Browse the repository at this point in the history
  • Loading branch information
nunogois authored Oct 10, 2023
1 parent b0eba10 commit 2222c47
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions frontend/src/interfaces/uiConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ export type UiFlags = {
privateProjects?: boolean;
accessOverview?: boolean;
dependentFeatures?: boolean;
internalMessageBanner?: boolean;
[key: string]: boolean | Variant | undefined;
};

Expand Down
2 changes: 2 additions & 0 deletions src/lib/__snapshots__/create-config.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ exports[`should create default config 1`] = `
"featuresExportImport": true,
"filterInvalidClientMetrics": false,
"googleAuthEnabled": false,
"internalMessageBanner": false,
"lastSeenByEnvironment": false,
"maintenanceMode": false,
"messageBanner": {
Expand Down Expand Up @@ -133,6 +134,7 @@ exports[`should create default config 1`] = `
"featuresExportImport": true,
"filterInvalidClientMetrics": false,
"googleAuthEnabled": false,
"internalMessageBanner": false,
"lastSeenByEnvironment": false,
"maintenanceMode": false,
"messageBanner": {
Expand Down
7 changes: 6 additions & 1 deletion src/lib/types/experimental.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ export type IFlagKey =
| 'datadogJsonTemplate'
| 'disableMetrics'
| 'transactionalDecorator'
| 'useLastSeenRefactor';
| 'useLastSeenRefactor'
| 'internalMessageBanner';

export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>;

Expand Down Expand Up @@ -157,6 +158,10 @@ const flags: IFlags = {
process.env.UNLEASH_EXPERIMENTAL_USE_LAST_SEEN_REFACTOR,
false,
),
internalMessageBanner: parseEnvVarBoolean(
process.env.UNLEASH_EXPERIMENTAL_INTERNAL_MESSAGE_BANNER,
false,
),
};

export const defaultExperimentalOptions: IExperimentalOptions = {
Expand Down

0 comments on commit 2222c47

Please sign in to comment.