@ -18,6 +18,7 @@ import { Opportunities } from '~/pages/opportunities/Opportunities';
|
||||
import { People } from '~/pages/people/People';
|
||||
import { PersonShow } from '~/pages/people/PersonShow';
|
||||
import { SettingsExperience } from '~/pages/settings/SettingsExperience';
|
||||
import { SettingsNewObject } from '~/pages/settings/SettingsNewObject';
|
||||
import { SettingsObjectDetail } from '~/pages/settings/SettingsObjectDetail';
|
||||
import { SettingsObjectEdit } from '~/pages/settings/SettingsObjectEdit';
|
||||
import { SettingsObjects } from '~/pages/settings/SettingsObjects';
|
||||
@ -85,6 +86,10 @@ export const App = () => {
|
||||
path={SettingsPath.ObjectEdit}
|
||||
element={<SettingsObjectEdit />}
|
||||
/>
|
||||
<Route
|
||||
path={SettingsPath.NewObject}
|
||||
element={<SettingsNewObject />}
|
||||
/>
|
||||
</Routes>
|
||||
}
|
||||
/>
|
||||
|
||||
@ -4,6 +4,7 @@ export enum SettingsPath {
|
||||
Objects = 'objects',
|
||||
ObjectDetail = 'objects/:pluralObjectName',
|
||||
ObjectEdit = 'objects/:pluralObjectName/edit',
|
||||
NewObject = 'objects/new',
|
||||
WorkspaceMembersPage = 'workspace-members',
|
||||
Workspace = 'workspace',
|
||||
}
|
||||
|
||||
25
front/src/pages/settings/SettingsNewObject.tsx
Normal file
25
front/src/pages/settings/SettingsNewObject.tsx
Normal file
@ -0,0 +1,25 @@
|
||||
import styled from '@emotion/styled';
|
||||
|
||||
import { Breadcrumb } from '@/ui/breadcrumb/components/Breadcrumb';
|
||||
import { IconSettings } from '@/ui/icon';
|
||||
import { SubMenuTopBarContainer } from '@/ui/layout/components/SubMenuTopBarContainer';
|
||||
|
||||
import { objectSettingsWidth } from './constants/objectSettings';
|
||||
|
||||
const StyledContainer = styled.div`
|
||||
padding: ${({ theme }) => theme.spacing(8)};
|
||||
width: ${objectSettingsWidth};
|
||||
`;
|
||||
|
||||
export const SettingsNewObject = () => (
|
||||
<SubMenuTopBarContainer Icon={IconSettings} title="Settings">
|
||||
<StyledContainer>
|
||||
<Breadcrumb
|
||||
links={[
|
||||
{ children: 'Objects', href: '/settings/objects' },
|
||||
{ children: 'New' },
|
||||
]}
|
||||
/>
|
||||
</StyledContainer>
|
||||
</SubMenuTopBarContainer>
|
||||
);
|
||||
@ -0,0 +1,28 @@
|
||||
import { Meta, StoryObj } from '@storybook/react';
|
||||
|
||||
import {
|
||||
PageDecorator,
|
||||
PageDecoratorArgs,
|
||||
} from '~/testing/decorators/PageDecorator';
|
||||
import { graphqlMocks } from '~/testing/graphqlMocks';
|
||||
|
||||
import { SettingsNewObject } from '../SettingsNewObject';
|
||||
|
||||
const meta: Meta<PageDecoratorArgs> = {
|
||||
title: 'Pages/Settings/SettingsNewObject',
|
||||
component: SettingsNewObject,
|
||||
decorators: [PageDecorator],
|
||||
args: {
|
||||
routePath: '/settings/objects/new',
|
||||
},
|
||||
parameters: {
|
||||
docs: { story: 'inline', iframeHeight: '500px' },
|
||||
msw: graphqlMocks,
|
||||
},
|
||||
};
|
||||
|
||||
export default meta;
|
||||
|
||||
export type Story = StoryObj<typeof SettingsNewObject>;
|
||||
|
||||
export const Default: Story = {};
|
||||
Reference in New Issue
Block a user