АДРЕСНЫЙ РЕЖИМ - авторан история - базовая версия + доп кля + конфиг дизапйна
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -4,18 +4,22 @@ interface PanelFrameProps {
|
||||
title: string;
|
||||
subtitle?: string;
|
||||
actions?: ReactNode;
|
||||
className?: string;
|
||||
hideHeader?: boolean;
|
||||
}
|
||||
|
||||
export function PanelFrame({ title, subtitle, actions, children }: PropsWithChildren<PanelFrameProps>) {
|
||||
export function PanelFrame({ title, subtitle, actions, className, hideHeader, children }: PropsWithChildren<PanelFrameProps>) {
|
||||
return (
|
||||
<section className="panel-frame">
|
||||
<header className="panel-header">
|
||||
<div>
|
||||
<h2>{title}</h2>
|
||||
{subtitle ? <p>{subtitle}</p> : null}
|
||||
</div>
|
||||
{actions ? <div className="panel-actions">{actions}</div> : null}
|
||||
</header>
|
||||
<section className={className ? `panel-frame ${className}` : "panel-frame"}>
|
||||
{!hideHeader ? (
|
||||
<header className="panel-header">
|
||||
<div>
|
||||
<h2>{title}</h2>
|
||||
{subtitle ? <p>{subtitle}</p> : null}
|
||||
</div>
|
||||
{actions ? <div className="panel-actions">{actions}</div> : null}
|
||||
</header>
|
||||
) : null}
|
||||
<div className="panel-body">{children}</div>
|
||||
</section>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user