Skip to content

Commit b547cc0

Browse files
author
Romain Jamet
committed
feat(okms): add <OkmsChangelogButton /> button
ref: #MANAGER-19653 Signed-off-by: Romain Jamet <[email protected]>
1 parent 1088e8f commit b547cc0

File tree

22 files changed

+62
-34
lines changed

22 files changed

+62
-34
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
export * from './Link/Link.component';
2+
export * from './RadioCard/RadioCard.component';
3+
export * from './confirmationModal/ConfirmationModal';
4+
export * from './drawer/DrawerInnerComponents.component';
5+
export * from './okmsChangelogButton/OkmsChangelogButton.component';
6+
export * from './okmsDatagrid/OkmsDatagrid.component';
7+
export * from './tabNavigation/TabNavigation.component';
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import React from 'react';
2+
import {
3+
ChangelogButton,
4+
ChangelogLinks,
5+
} from '@ovh-ux/manager-react-components';
6+
7+
const changelogLinks: ChangelogLinks = {
8+
changelog:
9+
'https://github.com/orgs/ovh/projects/16/views/6?sliceBy%5Bvalue%5D=Key+Management+Service',
10+
roadmap:
11+
'https://github.com/orgs/ovh/projects/16/views/1?sliceBy%5Bvalue%5D=Key+Management+Service',
12+
'feature-request':
13+
'https://github.com/ovh/management-security-operations-roadmap/issues/new',
14+
};
15+
16+
export const OkmsChangelogButton = () => {
17+
return <ChangelogButton links={changelogLinks} />;
18+
};

packages/manager/apps/key-management-service/src/common/components/okmsDatagrid/ListingCells.component.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import { OKMS } from '@/types/okms.type';
1717
import { OkmsServiceState } from '@/components/layout-helpers/Dashboard/okmsServiceState/OkmsServiceState.component';
1818
import { KMS_ROUTES_URLS } from '@/routes/routes.constants';
1919
import { OkmsDatagridType } from './okmsDatagrid.type';
20-
import { Link } from '@/common/components/Link/Link.component';
20+
import { Link } from '../Link/Link.component';
2121

2222
export const DatagridCellId = (okms: OKMS) => {
2323
return <Clipboard className="w-full" value={okms.id} />;
Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,3 @@
1-
import { ChangelogLinks } from '@ovh-ux/manager-react-components';
2-
3-
export const CHANGELOG_LINKS: ChangelogLinks = {
4-
changelog:
5-
'https://github.com/orgs/ovh/projects/16/views/6?sliceBy%5Bvalue%5D=KMS',
6-
roadmap:
7-
'https://github.com/orgs/ovh/projects/16/views/1?sliceBy%5Bvalue%5D=KMS&pane=info',
8-
'feature-request':
9-
'https://github.com/ovh/management-security-operations-roadmap/issues/new',
10-
};
11-
121
export const SERVICE_KEYS_LABEL = 'Service Keys';
132
export const URN_LABEL = 'URN';
143
export const PATH_LABEL = 'Path';

packages/manager/apps/key-management-service/src/modules/secret-manager/components/regionSelector/RegionSelector.component.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
OdsText,
99
} from '@ovhcloud/ods-components/react';
1010
import { NAMESPACES } from '@ovh-ux/manager-common-translations';
11-
import { Link } from '@/common/components/Link/Link.component';
11+
import { Link } from '@/common/components';
1212
import { useRegionSelector } from '@/modules/secret-manager/hooks/useRegionSelector';
1313

1414
export const RegionSelector = () => {

packages/manager/apps/key-management-service/src/modules/secret-manager/pages/create/Create.page.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { OdsBreadcrumb } from '@ovhcloud/ods-components/react';
66
import { RootBreadcrumbItem } from '@secret-manager/components/breadcrumb';
77
import { DomainManagement } from './DomainManagement.component';
88
import { SecretForm } from './SecretForm.component';
9+
import { OkmsChangelogButton } from '@/common/components';
910
import { OrderOkmsModalProvider } from '@/common/pages/OrderOkmsModal/OrderOkmsModalContext';
1011

1112
export default function SecretCreatePage() {
@@ -18,7 +19,10 @@ export default function SecretCreatePage() {
1819
return (
1920
<OrderOkmsModalProvider>
2021
<BaseLayout
21-
header={{ title: t('create_a_secret') }}
22+
header={{
23+
title: t('create_a_secret'),
24+
changelogButton: <OkmsChangelogButton />,
25+
}}
2226
breadcrumb={
2327
<OdsBreadcrumb>
2428
<RootBreadcrumbItem />

packages/manager/apps/key-management-service/src/modules/secret-manager/pages/create/DomainSelector.component.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { OdsSkeleton, OdsText } from '@ovhcloud/ods-components/react';
55
import { ODS_BADGE_SIZE } from '@ovhcloud/ods-components';
66
import { OKMS } from '@/types/okms.type';
77
import { OkmsServiceState } from '@/components/layout-helpers/Dashboard/okmsServiceState/OkmsServiceState.component';
8-
import { RadioCard } from '@/common/components/RadioCard/RadioCard.component';
8+
import { RadioCard } from '@/common/components';
99
import { ActivateRegion } from './ActivateRegion.component';
1010

1111
const DomainStatus = ({ id }: { id: string }) => {

packages/manager/apps/key-management-service/src/modules/secret-manager/pages/create/RegionSelector.component.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import React from 'react';
22
import { useTranslation } from 'react-i18next';
33
import { OdsText } from '@ovhcloud/ods-components/react';
44
import { Region } from '@ovh-ux/manager-react-components';
5-
import { RadioCard } from '@/common/components/RadioCard/RadioCard.component';
5+
import { RadioCard } from '@/common/components';
66

77
type RegionSelectorProps = {
88
regions: string[];

packages/manager/apps/key-management-service/src/modules/secret-manager/pages/dashboard/Dashboard.page.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,10 @@ import {
2424
import { decodeSecretPath } from '@/modules/secret-manager/utils/secretPath';
2525
import Loading from '@/components/Loading/Loading';
2626
import {
27+
OkmsChangelogButton,
2728
TabNavigation,
2829
TabNavigationItem,
29-
} from '@/common/components/tabNavigation/TabNavigation.component';
30+
} from '@/common/components';
3031

3132
export default function SecretDashboardPage() {
3233
const { domainId, secretPath } = useParams<LocationPathParams>();
@@ -63,6 +64,7 @@ export default function SecretDashboardPage() {
6364

6465
const headerProps: HeadersProps = {
6566
title: secretPathDecoded,
67+
changelogButton: <OkmsChangelogButton />,
6668
};
6769

6870
if (isSecretPending) {

packages/manager/apps/key-management-service/src/modules/secret-manager/pages/dashboard/generalInformation/ActionsTile.component.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
SECRET_MANAGER_ROUTES_URLS,
88
} from '@secret-manager/routes/routes.constants';
99
import { useParams } from 'react-router-dom';
10-
import { Link } from '@/common/components/Link/Link.component';
10+
import { Link } from '@/common/components';
1111

1212
type ActionsTileParams = {
1313
secret: Secret;

0 commit comments

Comments
 (0)