@centreon/ui 23.10.24 → 23.10.25-feature-MON-19319.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +8 -1
- package/src/Dashboard/DashboardLayout.stories.tsx +3 -5
- package/src/Dashboard/Layout.tsx +4 -4
- package/src/Dashboard/utils.ts +28 -28
- package/src/ThemeProvider/index.tsx +6 -5
- package/src/ThemeProvider/palettes.ts +234 -208
- package/src/components/Button/Button.styles.ts +7 -2
- package/src/components/Header/Header.styles.ts +0 -27
- package/src/components/Header/PageHeader/PageHeader.stories.tsx +83 -0
- package/src/components/Header/PageHeader/PageHeader.styles.ts +105 -0
- package/src/components/Header/PageHeader/PageHeader.tsx +15 -0
- package/src/components/Header/PageHeader/PageHeaderActions.tsx +17 -0
- package/src/components/Header/PageHeader/PageHeaderMain.tsx +15 -0
- package/src/components/Header/PageHeader/PageHeaderMenu.tsx +15 -0
- package/src/components/Header/PageHeader/PageHeaderTitle.tsx +44 -0
- package/src/components/Header/PageHeader/index.ts +12 -0
- package/src/components/Header/index.ts +1 -1
- package/src/components/Layout/AreaIndicator.styles.ts +33 -0
- package/src/components/Layout/AreaIndicator.tsx +35 -0
- package/src/components/Layout/PageLayout/PageLayout.stories.tsx +81 -0
- package/src/components/Layout/PageLayout/PageLayout.styles.ts +30 -0
- package/src/components/Layout/PageLayout/PageLayout.tsx +21 -0
- package/src/components/Layout/PageLayout/PageLayoutActions.tsx +15 -0
- package/src/components/Layout/PageLayout/PageLayoutBody.tsx +24 -0
- package/src/components/Layout/PageLayout/PageLayoutHeader.tsx +15 -0
- package/src/components/Layout/PageLayout/index.ts +10 -0
- package/src/components/Layout/index.ts +1 -0
- package/src/components/Menu/Menu.tsx +0 -0
- package/src/components/Tooltip/TextOverflowTooltip/TextOverflowTooltip.stories.tsx +71 -0
- package/src/components/Tooltip/TextOverflowTooltip/TextOverflowTooltip.styles.ts +5 -0
- package/src/components/Tooltip/TextOverflowTooltip/TextOverflowTooltip.tsx +115 -0
- package/src/components/Tooltip/TextOverflowTooltip/index.tsx +1 -0
- package/src/components/Tooltip/Tooltip.stories.tsx +41 -0
- package/src/components/Tooltip/Tooltip.styles.ts +5 -0
- package/src/components/Tooltip/Tooltip.tsx +46 -0
- package/src/components/Tooltip/index.ts +1 -0
- package/src/components/index.ts +2 -0
- package/src/index.ts +0 -2
- package/src/screens/dashboard/DashboardsOverview.stories.tsx +109 -101
- package/src/utils/useResizeObserver.ts +6 -0
- package/test/setupTests.js +23 -20
- package/src/components/Header/Header.stories.tsx +0 -27
- package/src/components/Header/Header.tsx +0 -23
- package/src/layout/TiledListingPage/TiledListingActions.tsx +0 -15
- package/src/layout/TiledListingPage/TiledListingContent.tsx +0 -21
- package/src/layout/TiledListingPage/TiledListingList.tsx +0 -11
- package/src/layout/TiledListingPage/TiledListingPage.styles.ts +0 -16
- package/src/layout/TiledListingPage/TiledListingPage.tsx +0 -15
- package/src/layout/TiledListingPage/index.ts +0 -4
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
|
|
3
|
-
import { Settings as SettingsIcon } from '@mui/icons-material';
|
|
4
|
-
|
|
5
|
-
import { IconButton } from '../Button';
|
|
6
|
-
|
|
7
|
-
import { Header } from './Header';
|
|
8
|
-
|
|
9
|
-
const meta: Meta<typeof Header> = {
|
|
10
|
-
component: Header
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export default meta;
|
|
14
|
-
type Story = StoryObj<typeof Header>;
|
|
15
|
-
|
|
16
|
-
export const Default: Story = {
|
|
17
|
-
args: {
|
|
18
|
-
title: 'Header'
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
export const WithNav: Story = {
|
|
23
|
-
args: {
|
|
24
|
-
nav: <IconButton icon={<SettingsIcon />} size="small" variant="ghost" />,
|
|
25
|
-
title: 'Header with nav'
|
|
26
|
-
}
|
|
27
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ReactElement, ReactNode } from 'react';
|
|
2
|
-
|
|
3
|
-
import { Typography as MuiTypography } from '@mui/material';
|
|
4
|
-
|
|
5
|
-
import { useStyles } from './Header.styles';
|
|
6
|
-
|
|
7
|
-
type HeaderProps = {
|
|
8
|
-
nav?: ReactNode;
|
|
9
|
-
title: string;
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
const Header = ({ title, nav }: HeaderProps): ReactElement => {
|
|
13
|
-
const { classes } = useStyles();
|
|
14
|
-
|
|
15
|
-
return (
|
|
16
|
-
<header className={classes.header}>
|
|
17
|
-
<MuiTypography variant="h1">{title}</MuiTypography>
|
|
18
|
-
{nav && <nav>{nav}</nav>}
|
|
19
|
-
</header>
|
|
20
|
-
);
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
export { Header };
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
|
|
3
|
-
import { useTiledListingActionsStyles } from './TiledListingPage.styles';
|
|
4
|
-
|
|
5
|
-
interface TiledListingActionsProps {
|
|
6
|
-
children: Array<ReactNode> | ReactNode;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
export const TiledListingActions = ({
|
|
10
|
-
children
|
|
11
|
-
}: TiledListingActionsProps): JSX.Element => {
|
|
12
|
-
const { classes } = useTiledListingActionsStyles();
|
|
13
|
-
|
|
14
|
-
return <div className={classes.actions}>{children}</div>;
|
|
15
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
|
|
3
|
-
import Responsive from '../../Responsive';
|
|
4
|
-
|
|
5
|
-
import { useTiledListingActionsStyles } from './TiledListingPage.styles';
|
|
6
|
-
|
|
7
|
-
interface TiledListingContentProps {
|
|
8
|
-
children: ReactNode;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export const TiledListingContent = ({
|
|
12
|
-
children
|
|
13
|
-
}: TiledListingContentProps): JSX.Element => {
|
|
14
|
-
const { classes } = useTiledListingActionsStyles();
|
|
15
|
-
|
|
16
|
-
return (
|
|
17
|
-
<Responsive>
|
|
18
|
-
<div className={classes.actions}>{children}</div>
|
|
19
|
-
</Responsive>
|
|
20
|
-
);
|
|
21
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { makeStyles } from 'tss-react/mui';
|
|
2
|
-
|
|
3
|
-
export const useTiledListPageStyles = makeStyles()((theme) => ({
|
|
4
|
-
listPage: {
|
|
5
|
-
display: 'flex',
|
|
6
|
-
flexDirection: 'column',
|
|
7
|
-
height: '100%',
|
|
8
|
-
padding: theme.spacing(1.5)
|
|
9
|
-
}
|
|
10
|
-
}));
|
|
11
|
-
|
|
12
|
-
export const useTiledListingActionsStyles = makeStyles()((theme) => ({
|
|
13
|
-
actions: {
|
|
14
|
-
paddingBottom: theme.spacing(2.5)
|
|
15
|
-
}
|
|
16
|
-
}));
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
|
|
3
|
-
import { useTiledListPageStyles } from './TiledListingPage.styles';
|
|
4
|
-
|
|
5
|
-
interface TiledListingPageProps {
|
|
6
|
-
children: Array<ReactNode>;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
export const TiledListingPage = ({
|
|
10
|
-
children
|
|
11
|
-
}: TiledListingPageProps): JSX.Element => {
|
|
12
|
-
const { classes } = useTiledListPageStyles();
|
|
13
|
-
|
|
14
|
-
return <div className={classes.listPage}>{children}</div>;
|
|
15
|
-
};
|