Shorten
This commit is contained in:
@@ -13,7 +13,7 @@ interface TitlebarProps {
|
||||
actionButton?: JSX.Element;
|
||||
}
|
||||
|
||||
// TODO: Deprecated in favor of NestedSidebarDrawerTitlebar where possible (will
|
||||
// TODO: Deprecated in favor of SidebarDrawerTitlebarProps where possible (will
|
||||
// revisit the remaining use cases once those have migrated).
|
||||
export const Titlebar: React.FC<TitlebarProps> = ({
|
||||
title,
|
||||
|
||||
@@ -81,7 +81,7 @@ import Close from "@mui/icons-material/Close";
|
||||
import { Box, IconButton, Typography } from "@mui/material";
|
||||
import React from "react";
|
||||
|
||||
type NestedSidebarDrawerTitlebarProps = Pick<
|
||||
type SidebarDrawerTitlebarProps = Pick<
|
||||
NestedSidebarDrawerVisibilityProps,
|
||||
"onClose" | "onRootClose"
|
||||
> & {
|
||||
@@ -98,11 +98,15 @@ type NestedSidebarDrawerTitlebarProps = Pick<
|
||||
|
||||
/**
|
||||
* A bar with a title and back / close buttons, suitable for being used in
|
||||
* tandem with a {@link SidebarDrawer}.
|
||||
* tandem with a {@link NestedSidebarDrawer}.
|
||||
*/
|
||||
export const NestedSidebarDrawerTitlebar: React.FC<
|
||||
NestedSidebarDrawerTitlebarProps
|
||||
> = ({ title, caption, onClose, onRootClose, actionButton }) => {
|
||||
export const SidebarDrawerTitlebar: React.FC<SidebarDrawerTitlebarProps> = ({
|
||||
title,
|
||||
caption,
|
||||
onClose,
|
||||
onRootClose,
|
||||
actionButton,
|
||||
}) => {
|
||||
return (
|
||||
<>
|
||||
<FlexWrapper
|
||||
|
||||
Reference in New Issue
Block a user