Skip to content

Commit

Permalink
feat: release plans nav menu item and icon suggestion (#8469)
Browse files Browse the repository at this point in the history
  • Loading branch information
daveleek authored Oct 18, 2024
1 parent 54a6b03 commit d9646ed
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import BillingIcon from '@mui/icons-material/CreditCardOutlined';
import EventLogIcon from '@mui/icons-material/EventNoteOutlined';
import GitHubIcon from '@mui/icons-material/GitHub';
import LibraryBooksIcon from '@mui/icons-material/LibraryBooks';
import LaunchIcon from '@mui/icons-material/Launch';
import type { FC } from 'react';

// TODO: move to routes
Expand Down Expand Up @@ -56,6 +57,7 @@ const icons: Record<string, typeof SvgIcon> = {
'/admin/cors': CorsIcon,
'/admin/billing': BillingIcon,
'/history': EventLogIcon,
'/releases-management': LaunchIcon,
GitHub: GitHubIcon,
Documentation: LibraryBooksIcon,
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,20 @@ exports[`returns all baseRoutes 1`] = `
"title": "Strategy types",
"type": "protected",
},
{
"component": [Function],
"enterprise": true,
"flag": "releasePlans",
"menu": {
"advanced": true,
"mode": [
"enterprise",
],
},
"path": "/releases-management",
"title": "Release management",
"type": "protected",
},
{
"component": [Function],
"menu": {},
Expand Down
10 changes: 10 additions & 0 deletions frontend/src/component/menu/routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ import { Application } from 'component/application/Application';
import { Signals } from 'component/signals/Signals';
import { LazyCreateProject } from '../project/Project/CreateProject/LazyCreateProject';
import { PersonalDashboard } from '../personalDashboard/PersonalDashboard';
import { ReleaseManagement } from 'component/releases/ReleaseManagement';

export const routes: IRoute[] = [
// Splash
Expand Down Expand Up @@ -246,6 +247,15 @@ export const routes: IRoute[] = [
type: 'protected',
menu: { mobile: true, advanced: true },
},
{
path: '/releases-management',
title: 'Release management',
component: ReleaseManagement,
type: 'protected',
menu: { advanced: true, mode: ['enterprise'] },
flag: 'releasePlans',
enterprise: true,
},
{
path: '/environments/create',
title: 'Environments',
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/component/releases/ReleaseManagement.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export const ReleaseManagement = () => {
return null;
};
1 change: 1 addition & 0 deletions frontend/src/interfaces/uiConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ export type UiFlags = {
personalDashboardUI?: boolean;
purchaseAdditionalEnvironments?: boolean;
unleashAI?: boolean;
releasePlans?: boolean;
};

export interface IVersionInfo {
Expand Down
2 changes: 1 addition & 1 deletion src/server-dev.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ process.nextTick(async () => {
unleashAI: true,
webhookDomainLogging: true,
addonUsageMetrics: true,
releasePlans: true,
releasePlans: false,
},
},
authentication: {
Expand Down

0 comments on commit d9646ed

Please sign in to comment.