Add layout screen component

Each section of styles in the sidebar should have its screen component.
[MAILPOET-5640]
This commit is contained in:
Jan Lysý
2024-03-01 17:56:57 +01:00
committed by Rostislav Wolný
parent 97d31c0dbf
commit 5c46bbda30
2 changed files with 8 additions and 2 deletions

View File

@@ -0,0 +1,6 @@
import { __ } from '@wordpress/i18n';
import { ScreenHeader } from './screen-header';
export function ScreenLayout(): JSX.Element {
return <ScreenHeader title={__('Layout', 'mailpoet')} />;
}

View File

@@ -9,6 +9,7 @@ import { ComplementaryArea } from '@wordpress/interface';
import { ComponentProps } from 'react';
import { styles } from '@wordpress/icons';
import { storeName, stylesSidebarId } from '../../store';
import { ScreenLayout } from './screen-layout';
import { ScreenRoot } from './screen-root';
type Props = ComponentProps<typeof ComplementaryArea>;
@@ -41,8 +42,7 @@ export function StylesSidebar(props: Props): JSX.Element {
</NavigatorScreen>
<NavigatorScreen path="/layout">
<NavigatorToParentButton>Back</NavigatorToParentButton>
<div>TODO: Typography screen</div>
<ScreenLayout />
</NavigatorScreen>
</NavigatorProvider>
</Panel>