chore: cleanup

This commit is contained in:
Tom Moor committed 2025-02-22 21:57:07 -05:00
1 parent 978773ee27
commit 90f7a4272e
6 files changed
-16

No files matched your search

-2
View File
@@ -13,13 +13,11 @@ export default function attachmentMenuItems(
name: "replaceAttachment",
tooltip: dictionary.replaceAttachment,
icon: <ReplaceIcon />,
visible: true,
},
{
name: "deleteAttachment",
tooltip: dictionary.deleteAttachment,
icon: <TrashIcon />,
visible: true,
},
{
name: "separator",
-7
View File
@@ -33,14 +33,12 @@ export default function imageMenuItems(
name: "alignLeft",
tooltip: dictionary.alignLeft,
icon: <AlignImageLeftIcon />,
visible: true,
active: isLeftAligned,
},
{
name: "alignCenter",
tooltip: dictionary.alignCenter,
icon: <AlignImageCenterIcon />,
visible: true,
active: (state) =>
isNodeActive(schema.nodes.image)(state) &&
!isLeftAligned(state) &&
@@ -51,19 +49,16 @@ export default function imageMenuItems(
name: "alignRight",
tooltip: dictionary.alignRight,
icon: <AlignImageRightIcon />,
visible: true,
active: isRightAligned,
},
{
name: "alignFullWidth",
tooltip: dictionary.alignFullWidth,
icon: <AlignFullWidthIcon />,
visible: true,
active: isFullWidthAligned,
},
{
name: "separator",
visible: true,
},
{
name: "downloadImage",
@@ -75,13 +70,11 @@ export default function imageMenuItems(
name: "replaceImage",
tooltip: dictionary.replaceImage,
icon: <ReplaceIcon />,
visible: true,
},
{
name: "deleteImage",
tooltip: dictionary.deleteImage,
icon: <TrashIcon />,
visible: true,
},
];
}
-4
View File
@@ -39,28 +39,24 @@ export default function noticeMenuItems(
name: NoticeTypes.Info,
icon: <InfoIcon />,
label: dictionary.infoNotice,
visible: true,
active: () => currentStyle === NoticeTypes.Info,
},
{
name: NoticeTypes.Success,
icon: <DoneIcon />,
label: dictionary.successNotice,
visible: true,
active: () => currentStyle === NoticeTypes.Success,
},
{
name: NoticeTypes.Warning,
icon: <WarningIcon />,
label: dictionary.warningNotice,
visible: true,
active: () => currentStyle === NoticeTypes.Warning,
},
{
name: NoticeTypes.Tip,
icon: <StarredIcon />,
label: dictionary.tipNotice,
visible: true,
active: () => currentStyle === NoticeTypes.Tip,
},
],
-1
View File
@@ -24,7 +24,6 @@ const NotificationMenu: React.FC = () => {
{
type: "button",
title: t("Notification settings"),
visible: true,
onClick: () => performAction(navigateToNotificationSettings, context),
},
],
-1
View File
@@ -28,7 +28,6 @@ function TableOfContentsMenu() {
const i = [
{
type: "heading",
visible: true,
title: t("Contents"),
},
...headings.map((heading) => ({
-1
View File
@@ -322,7 +322,6 @@ const embeds: EmbedDescriptor[] = [
regexMatch: [new RegExp("^https?://www\\.google\\.com/maps/embed\\?(.*)$")],
transformMatch: (matches: RegExpMatchArray) => matches[0],
icon: <Img src="/images/google-maps.png" alt="Google Maps" />,
visible: true,
}),
new EmbedDescriptor({
title: "Google Drawings",