A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
web: bring back editor margins toggle in action bar
Abdullah Atta5cb373f730d8
diff --git a/apps/web/src/components/editor/action-bar.tsx b/apps/web/src/components/editor/action-bar.tsxindex b21b50328..997417b22 100644--- a/apps/web/src/components/editor/action-bar.tsx+++ b/apps/web/src/components/editor/action-bar.tsx@@ -21,6 +21,8 @@ import { Button, Flex, Text } from "@theme-ui/components";import { useState } from "react";import {Cross,+ EditorFullWidth,+ EditorNormalWidth,ExitFullscreen,FocusMode,Fullscreen,@@ -44,7 +46,7 @@ import { useStore as useAppStore } from "../../stores/app-store";import { useEditorManager } from "./manager";export function EditorActionBar() {- // const editorMargins = useEditorStore((store) => store.editorMargins);+ const editorMargins = useEditorStore((store) => store.editorMargins);const isFocusMode = useAppStore((store) => store.isFocusMode);const [isFullscreen, setIsFullscreen] = useState(false);const activeSession = useEditorStore((store) =>@@ -55,12 +57,12 @@ export function EditorActionBar() {);const tools = [- // {- // title: editorMargins ? "Disable editor margins" : "Enable editor margins",- // icon: editorMargins ? EditorNormalWidth : EditorFullWidth,- // enabled: true,- // onClick: () => useEditorStore.getState().toggleEditorMargins()- // },+ {+ title: editorMargins ? "Disable editor margins" : "Enable editor margins",+ icon: editorMargins ? EditorNormalWidth : EditorFullWidth,+ enabled: true,+ onClick: () => useEditorStore.getState().toggleEditorMargins()+ },{title: isFocusMode ? "Normal mode" : "Focus mode",icon: isFocusMode ? FocusMode : NormalMode,