Memos is an open-source, self-hosted note-taking app that brings your everyday thoughts together in a personal timeline. Your data stays yours, and you choose what to keep private or share.
Go dockerfossgomarkdownmemomicroblognote-takingnotesopen-sourceown-your-datareactself-hostedsqlitetimeline
feat: remove mobile styles
email8f7445c299eb
diff --git a/web/src/App.tsx b/web/src/App.tsxindex 0f75e7b65..c16d16f4b 100644--- a/web/src/App.tsx+++ b/web/src/App.tsx@@ -1,7 +1,6 @@-import { useContext, useEffect } from "react";+import { useContext } from "react";import appContext from "./stores/appContext";import { appRouterSwitch } from "./routers";-import { globalStateService } from "./services";import "./less/app.less";function App() {@@ -9,20 +8,6 @@ function App() {locationState: { pathname },} = useContext(appContext);- useEffect(() => {- const handleWindowResize = () => {- globalStateService.setIsMobileView(document.body.clientWidth <= 875);- };-- handleWindowResize();-- window.addEventListener("resize", handleWindowResize);-- return () => {- window.removeEventListener("resize", handleWindowResize);- };- }, []);-return <>{appRouterSwitch(pathname)}</>;}diff --git a/web/src/components/MemosHeader.tsx b/web/src/components/MemosHeader.tsxindex 70fdc43e4..7fa8d1926 100644--- a/web/src/components/MemosHeader.tsx+++ b/web/src/components/MemosHeader.tsx@@ -1,8 +1,7 @@import { useCallback, useContext, useEffect, useState } from "react";import appContext from "../stores/appContext";import SearchBar from "./SearchBar";-import { globalStateService, memoService, shortcutService } from "../services";-import Only from "./common/OnlyWhen";+import { memoService, shortcutService } from "../services";import "../less/memos-header.less";let prevRequestTimestamp = Date.now();@@ -14,7 +13,6 @@ const MemosHeader: React.FC<Props> = () => {locationState: {query: { shortcutId },},- globalState: { isMobileView },shortcutState: { shortcuts },} = useContext(appContext);@@ -39,18 +37,9 @@ const MemosHeader: React.FC<Props> = () => {}}, []);- const handleShowSidebarBtnClick = useCallback(() => {- globalStateService.setShowSiderbarInMobileView(true);- }, []);-return (<div className="section-header-container memos-header-container"><div className="title-text" onClick={handleMemoTextClick}>- <Only when={isMobileView}>- <button className="action-btn" onClick={handleShowSidebarBtnClick}>- <img className="icon-img" src="/icons/menu.svg" alt="menu" />- </button>- </Only><span className="normal-text">{titleText}</span></div><SearchBar />diff --git a/web/src/components/Sidebar.tsx b/web/src/components/Sidebar.tsxindex 88df27406..1a8384d7d 100644--- a/web/src/components/Sidebar.tsx+++ b/web/src/components/Sidebar.tsx@@ -1,7 +1,4 @@-import { useContext, useEffect, useMemo, useRef } from "react";-import appContext from "../stores/appContext";-import { SHOW_SIDERBAR_MOBILE_CLASSNAME } from "../helpers/consts";-import { globalStateService } from "../services";+import { useRef } from "react";import UserBanner from "./UserBanner";import ShortcutList from "./ShortcutList";import TagList from "./TagList";@@ -11,57 +8,8 @@ import "../less/siderbar.less";interface Props {}const Sidebar: React.FC<Props> = () => {- const {- locationState,- globalState: { isMobileView, showSiderbarInMobileView },- } = useContext(appContext);const wrapperElRef = useRef<HTMLElement>(null);- const handleClickOutsideOfWrapper = useMemo(() => {- return (event: MouseEvent) => {- const siderbarShown = globalStateService.getState().showSiderbarInMobileView;-- if (!siderbarShown) {- window.removeEventListener("click", handleClickOutsideOfWrapper, {- capture: true,- });- return;- }-- if (!wrapperElRef.current?.contains(event.target as Node)) {- if (wrapperElRef.current?.parentNode?.contains(event.target as Node)) {- if (siderbarShown) {- event.stopPropagation();- }- globalStateService.setShowSiderbarInMobileView(false);- window.removeEventListener("click", handleClickOutsideOfWrapper, {- capture: true,- });- }- }- };- }, []);-- useEffect(() => {- globalStateService.setShowSiderbarInMobileView(false);- }, [locationState]);-- useEffect(() => {- if (showSiderbarInMobileView) {- document.body.classList.add(SHOW_SIDERBAR_MOBILE_CLASSNAME);- } else {- document.body.classList.remove(SHOW_SIDERBAR_MOBILE_CLASSNAME);- }- }, [showSiderbarInMobileView]);-- useEffect(() => {- if (isMobileView && showSiderbarInMobileView) {- window.addEventListener("click", handleClickOutsideOfWrapper, {- capture: true,- });- }- }, [isMobileView, showSiderbarInMobileView]);-return (<aside className="sidebar-wrapper" ref={wrapperElRef}><UserBanner />diff --git a/web/src/components/UsageHeatMap.tsx b/web/src/components/UsageHeatMap.tsxindex 25255be9a..fb144d4a5 100644--- a/web/src/components/UsageHeatMap.tsx+++ b/web/src/components/UsageHeatMap.tsx@@ -1,6 +1,6 @@import { useCallback, useContext, useEffect, useRef, useState } from "react";import appContext from "../stores/appContext";-import { globalStateService, locationService } from "../services";+import { locationService } from "../services";import { DAILY_TIMESTAMP } from "../helpers/consts";import utils from "../helpers/utils";import "../less/usage-heat-map.less";@@ -61,14 +61,9 @@ const UsageHeatMap: React.FC<Props> = () => {return;}- const { isMobileView } = globalStateService.getState();const targetEl = event.target as HTMLElement;- const sidebarEl = document.querySelector(".sidebar-wrapper") as HTMLElement;popupRef.current.style.left = targetEl.offsetLeft - (containerElRef.current?.offsetLeft ?? 0) + "px";- let topValue = targetEl.offsetTop;- if (!isMobileView) {- topValue -= sidebarEl.scrollTop;- }+ const topValue = targetEl.offsetTop;popupRef.current.style.top = topValue + "px";}, []);diff --git a/web/src/helpers/consts.ts b/web/src/helpers/consts.tsindex f0d935abd..95c40d343 100644--- a/web/src/helpers/consts.ts+++ b/web/src/helpers/consts.ts@@ -1,6 +1,3 @@-// mobile style addtion classname-export const SHOW_SIDERBAR_MOBILE_CLASSNAME = "mobile-show-sidebar";-// default animation durationexport const ANIMATION_DURATION = 200;diff --git a/web/src/less/about-site-dialog.less b/web/src/less/about-site-dialog.lessindex d80ee7b67..4c09eacb8 100644--- a/web/src/less/about-site-dialog.less+++ b/web/src/less/about-site-dialog.less@@ -35,9 +35,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.about-site-dialog {- @apply py-6 px-4 pt-16;- }-}diff --git a/web/src/less/change-password-dialog.less b/web/src/less/change-password-dialog.lessindex 1725497f4..b7e7e2275 100644--- a/web/src/less/change-password-dialog.less+++ b/web/src/less/change-password-dialog.less@@ -55,13 +55,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.change-password-dialog {- @apply py-6 px-4 pt-16;-- > .dialog-container {- @apply w-full;- }- }-}diff --git a/web/src/less/confirm-reset-openid-dialog.less b/web/src/less/confirm-reset-openid-dialog.lessindex 651f6456d..2af5311d0 100644--- a/web/src/less/confirm-reset-openid-dialog.less+++ b/web/src/less/confirm-reset-openid-dialog.less@@ -34,13 +34,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.confirm-reset-openid-dialog {- @apply py-6 px-4 pt-16;-- > .dialog-container {- @apply w-full;- }- }-}diff --git a/web/src/less/create-shortcut-dialog.less b/web/src/less/create-shortcut-dialog.lessindex c02500a0a..4cae31f54 100644--- a/web/src/less/create-shortcut-dialog.less+++ b/web/src/less/create-shortcut-dialog.less@@ -153,16 +153,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.create-shortcut-dialog {- padding: 24px 16px;- padding-top: 64px;- justify-content: unset;- overflow-x: hidden;-- &::-webkit-scrollbar {- display: none;- }- }-}diff --git a/web/src/less/daily-memo-diary-dialog.less b/web/src/less/daily-memo-diary-dialog.lessindex 24abb4bd2..6976bc526 100644--- a/web/src/less/daily-memo-diary-dialog.less+++ b/web/src/less/daily-memo-diary-dialog.less@@ -138,27 +138,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.daily-memo-diary-dialog {- padding: 0;- .hide-scroll-bar();-- > .dialog-container {- width: 100%;- height: 100%;- border-radius: 0;- overflow-y: auto;- overflow-x: hidden;- padding-bottom: 16px;-- > .dialog-header-container {- padding-top: 32px;- }-- &::-webkit-scrollbar {- display: none;- }- }- }-}diff --git a/web/src/less/dialog.less b/web/src/less/dialog.lessindex 70432e29f..801145038 100644--- a/web/src/less/dialog.less+++ b/web/src/less/dialog.less@@ -52,13 +52,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper {- @apply w-full px-4;-- > .dialog-container {- @apply max-w-full;- }- }-}diff --git a/web/src/less/global.less b/web/src/less/global.lessindex f78463c6c..26e122bac 100644--- a/web/src/less/global.less+++ b/web/src/less/global.less@@ -75,10 +75,3 @@ a {.hidden {display: none !important;}--@media only screen and (max-width: 875px) {- body,- html {- -webkit-overflow-scrolling: touch;- }-}diff --git a/web/src/less/home.less b/web/src/less/home.lessindex ef09eb168..8837053ca 100644--- a/web/src/less/home.less+++ b/web/src/less/home.less@@ -13,22 +13,3 @@@apply relative flex-grow h-auto;}}--@media only screen and (max-width: 875px) {- body.mobile-show-sidebar {- #page-wrapper {- > .content-wrapper {- @apply translate-x-80;- }- }- }-- #page-wrapper {- .flex(column, flex-start, flex-start);- @apply w-full h-full p-0 translate-x-0;-- > .content-wrapper {- @apply w-full h-full ml-0 pt-0 transition-all;- }- }-}diff --git a/web/src/less/memo-card-dialog.less b/web/src/less/memo-card-dialog.lessindex 2fda20bfb..042fb88bf 100644--- a/web/src/less/memo-card-dialog.less+++ b/web/src/less/memo-card-dialog.less@@ -187,10 +187,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.memo-card-dialog {- padding: 24px 16px;- padding-top: 64px;- }-}diff --git a/web/src/less/memo-content.less b/web/src/less/memo-content.lessindex 01958f6b1..71e9d0e93 100644--- a/web/src/less/memo-content.less+++ b/web/src/less/memo-content.less@@ -69,19 +69,3 @@white-space: pre-wrap;}}--@media only screen and (max-width: 875px) {- .memo-content-text {- > p {- font-size: 15px;- line-height: 26px;- min-height: 26px;- white-space: pre-wrap;- }-- .tag-span {- line-height: 26px;- font-size: 14px;- }- }-}diff --git a/web/src/less/memo-editor.less b/web/src/less/memo-editor.lessindex 41ad0f5f3..06ecced8c 100644--- a/web/src/less/memo-editor.less+++ b/web/src/less/memo-editor.less@@ -53,10 +53,3 @@}}}--@media only screen and (max-width: 875px) {- .memo-editor-wrapper {- width: calc(100% - 24px);- margin: auto;- }-}diff --git a/web/src/less/memo-filter.less b/web/src/less/memo-filter.lessindex 4da21f43c..c2d4aa2aa 100644--- a/web/src/less/memo-filter.less+++ b/web/src/less/memo-filter.less@@ -33,9 +33,3 @@}}}--@media only screen and (max-width: 875px) {- .filter-query-container {- padding-left: 20px;- }-}diff --git a/web/src/less/memo-trash.less b/web/src/less/memo-trash.lessindex b068f74b7..1562a8f57 100644--- a/web/src/less/memo-trash.less+++ b/web/src/less/memo-trash.less@@ -36,9 +36,3 @@.hide-scroll-bar();}}--@media only screen and (max-width: 875px) {- .deleted-memos-container {- padding: 0 12px;- }-}diff --git a/web/src/less/memolist.less b/web/src/less/memolist.lessindex 20ea0703d..352fbe870 100644--- a/web/src/less/memolist.less+++ b/web/src/less/memolist.less@@ -31,9 +31,3 @@padding-bottom: 80px;}}--@media only screen and (max-width: 875px) {- .memolist-wrapper {- padding: 0 12px;- }-}diff --git a/web/src/less/memos-header.less b/web/src/less/memos-header.lessindex 75bb2969f..951f97439 100644--- a/web/src/less/memos-header.less+++ b/web/src/less/memos-header.less@@ -25,10 +25,3 @@.flex(row, flex-end, center);}}--@media only screen and (max-width: 875px) {- .section-header-container,- .memos-header-container {- @apply h-auto mt-4 mb-0 py-0 px-3 pb-2;- }-}diff --git a/web/src/less/menu-btns-popup.less b/web/src/less/menu-btns-popup.lessindex 28b89c258..4aa127244 100644--- a/web/src/less/menu-btns-popup.less+++ b/web/src/less/menu-btns-popup.less@@ -21,9 +21,3 @@}}}--@media only screen and (max-width: 875px) {- .menu-btns-popup {- @apply ml-16;- }-}diff --git a/web/src/less/preview-image-dialog.less b/web/src/less/preview-image-dialog.lessindex cfba5c23a..7a9d264f8 100644--- a/web/src/less/preview-image-dialog.less+++ b/web/src/less/preview-image-dialog.less@@ -84,19 +84,3 @@}}}--@media only screen and (max-width: 875px) {- .preview-image-dialog {- padding: 0;-- > .dialog-container {- max-width: 100%;-- > .img-container {- > img {- padding: 6px;- }- }- }- }-}diff --git a/web/src/less/search-bar.less b/web/src/less/search-bar.lessindex cb92746b1..fafbca411 100644--- a/web/src/less/search-bar.less+++ b/web/src/less/search-bar.less@@ -102,9 +102,3 @@}}}--@media only screen and (max-width: 875px) {- .search-bar-container > .quickly-action-wrapper {- right: 4px;- }-}diff --git a/web/src/less/setting.less b/web/src/less/setting.lessindex 4de4ac162..17bdc1352 100644--- a/web/src/less/setting.less+++ b/web/src/less/setting.less@@ -45,9 +45,3 @@}}}--@media only screen and (max-width: 875px) {- .sections-wrapper {- @apply py-0 px-3;- }-}diff --git a/web/src/less/share-memo-image-dialog.less b/web/src/less/share-memo-image-dialog.lessindex 1280f7459..faa579a59 100644--- a/web/src/less/share-memo-image-dialog.less+++ b/web/src/less/share-memo-image-dialog.less@@ -134,15 +134,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.share-memo-image-dialog {- padding: 24px 16px;- padding-top: 64px;- justify-content: unset;-- &::-webkit-scrollbar {- display: none;- }- }-}diff --git a/web/src/less/shortcut-list.less b/web/src/less/shortcut-list.lessindex 03d4496ed..ca0aa2154 100644--- a/web/src/less/shortcut-list.less+++ b/web/src/less/shortcut-list.less@@ -135,21 +135,3 @@}}}--@media only screen and (max-width: 875px) {- .shortcuts-container {- @apply h-auto;-- &:last-child {- @apply flex-grow;- }-- > .title-text {- @apply text-sm;- }-- > .shortcut-container {- @apply text-base;- }- }-}diff --git a/web/src/less/siderbar.less b/web/src/less/siderbar.lessindex e3bd002c0..a57be0d19 100644--- a/web/src/less/siderbar.less+++ b/web/src/less/siderbar.less@@ -9,23 +9,3 @@@apply shrink-0;}}--@media only screen and (max-width: 875px) {- body.mobile-show-sidebar {- #page-wrapper {- > .sidebar-wrapper {- @apply translate-x-0 shadow;- }- }- }-- .sidebar-wrapper {- .flex(column, flex-start, center);- @apply z-50 absolute top-0 left-0 w-80 h-full p-0 bg-white transition-all -translate-x-80;-- > * {- @apply w-80 shrink-0 pl-8;- max-width: 95%;- }- }-}diff --git a/web/src/less/star-history-dialog.less b/web/src/less/star-history-dialog.lessindex a3d6fcd27..31c257685 100644--- a/web/src/less/star-history-dialog.less+++ b/web/src/less/star-history-dialog.less@@ -9,9 +9,3 @@}}}--@media only screen and (max-width: 875px) {- .dialog-wrapper.star-history-dialog {- @apply py-6 px-4 pt-16;- }-}diff --git a/web/src/less/tag-list.less b/web/src/less/tag-list.lessindex fe81ea748..a30a60fec 100644--- a/web/src/less/tag-list.less+++ b/web/src/less/tag-list.less@@ -85,18 +85,3 @@}}}--@media only screen and (max-width: 875px) {- .tags-wrapper {- @apply bg-white;-- > .tags-container {- @apply h-auto;-- &:last-child {- @apply grow;- flex-grow: 1;- }- }- }-}diff --git a/web/src/less/usage-heat-map.less b/web/src/less/usage-heat-map.lessindex b27082757..2fc5abb9f 100644--- a/web/src/less/usage-heat-map.less+++ b/web/src/less/usage-heat-map.less@@ -84,33 +84,3 @@}}}--@media only screen and (max-width: 875px) {- .usage-heat-map-wrapper {- @apply h-40 py-2 pt-3 pr-0 pl-2 !important;-- > .day-tip-text-container {- @apply visible w-10 pb-1;-- > .tip-text {- @apply pr-1 text-xs;- }- }-- > .usage-heat-map {- @apply w-60;-- > .stat-container {- @apply w-4 h-4 mb-1;- }- }-- > .usage-detail-container {- @apply -mt-9 pl-2 text-xs;-- &::before {- left: calc(50% - 4px);- }- }- }-}diff --git a/web/src/less/user-banner.less b/web/src/less/user-banner.lessindex 34021f62c..a1960c34c 100644--- a/web/src/less/user-banner.less+++ b/web/src/less/user-banner.less@@ -46,27 +46,3 @@}}}--@media only screen and (max-width: 875px) {- .user-banner-container {- @apply pt-4;-- > .userinfo-header-container {- @apply px-4;-- > .username-text {- @apply text-xl;- }- }-- > .status-text-container {- @apply px-4;-- > .status-text {- > .type-text {- @apply text-sm;- }- }- }- }-}diff --git a/web/src/pages/MemoTrash.tsx b/web/src/pages/MemoTrash.tsxindex ba6cd0755..b4a0606f5 100644--- a/web/src/pages/MemoTrash.tsx+++ b/web/src/pages/MemoTrash.tsx@@ -1,11 +1,10 @@import { useCallback, useContext, useEffect, useState } from "react";import appContext from "../stores/appContext";import useLoading from "../hooks/useLoading";-import { globalStateService, locationService, memoService, shortcutService } from "../services";+import { locationService, memoService, shortcutService } from "../services";import { IMAGE_URL_REG, LINK_REG, MEMO_LINK_REG, TAG_REG } from "../helpers/consts";import utils from "../helpers/utils";import { checkShouldShowMemoWithFilters } from "../helpers/filter";-import Only from "../components/common/OnlyWhen";import toastHelper from "../components/Toast";import DeletedMemo from "../components/DeletedMemo";import MemoFilter from "../components/MemoFilter";@@ -16,7 +15,6 @@ interface Props {}const MemoTrash: React.FC<Props> = () => {const {locationState: { query },- globalState: { isMobileView },} = useContext(appContext);const loadingState = useLoading();const [deletedMemos, setDeletedMemos] = useState<Model.Memo[]>([]);@@ -101,19 +99,10 @@ const MemoTrash: React.FC<Props> = () => {setDeletedMemos((deletedMemos) => deletedMemos.filter((memo) => memo.id !== memoId));}, []);- const handleShowSidebarBtnClick = useCallback(() => {- globalStateService.setShowSiderbarInMobileView(true);- }, []);-return (<div className="memo-trash-wrapper"><div className="section-header-container"><div className="title-text">- <Only when={isMobileView}>- <button className="action-btn" onClick={handleShowSidebarBtnClick}>- <img className="icon-img" src="/icons/menu.svg" alt="menu" />- </button>- </Only><span className="normal-text">Recycle Bin</span></div></div>diff --git a/web/src/pages/Setting.tsx b/web/src/pages/Setting.tsxindex 98fc5bd0d..9883b893f 100644--- a/web/src/pages/Setting.tsx+++ b/web/src/pages/Setting.tsx@@ -1,35 +1,20 @@-import { useCallback, useContext, useEffect } from "react";-import appContext from "../stores/appContext";-import { globalStateService, memoService } from "../services";+import { useEffect } from "react";+import { memoService } from "../services";import MyAccountSection from "../components/MyAccountSection";import PreferencesSection from "../components/PreferencesSection";-import Only from "../components/common/OnlyWhen";import "../less/setting.less";interface Props {}const Setting: React.FC<Props> = () => {- const {- globalState: { isMobileView },- } = useContext(appContext);-useEffect(() => {memoService.fetchAllMemos();}, []);- const handleShowSidebarBtnClick = useCallback(() => {- globalStateService.setShowSiderbarInMobileView(true);- }, []);-return (<div className="preference-wrapper"><div className="section-header-container"><div className="title-text">- <Only when={isMobileView}>- <button className="action-btn" onClick={handleShowSidebarBtnClick}>- <img className="icon-img" src="/icons/menu.svg" alt="menu" />- </button>- </Only><span className="normal-text">Settings</span></div></div>diff --git a/web/src/services/globalStateService.ts b/web/src/services/globalStateService.tsindex f38964363..7f232455a 100644--- a/web/src/services/globalStateService.ts+++ b/web/src/services/globalStateService.ts@@ -37,24 +37,6 @@ class GlobalStateService {});};- public setIsMobileView = (isMobileView: boolean) => {- appStore.dispatch({- type: "SET_MOBILE_VIEW",- payload: {- isMobileView,- },- });- };-- public setShowSiderbarInMobileView = (showSiderbarInMobileView: boolean) => {- appStore.dispatch({- type: "SET_SHOW_SIDEBAR_IN_MOBILE_VIEW",- payload: {- showSiderbarInMobileView,- },- });- };-public setAppSetting = (appSetting: Partial<AppSetting>) => {appStore.dispatch({type: "SET_APP_SETTING",diff --git a/web/src/stores/globalStateStore.ts b/web/src/stores/globalStateStore.tsindex ee80c6cdc..1ff4c4786 100644--- a/web/src/stores/globalStateStore.ts+++ b/web/src/stores/globalStateStore.ts@@ -6,8 +6,6 @@ export interface AppSetting {}export interface State extends AppSetting {- isMobileView: boolean;- showSiderbarInMobileView: boolean;markMemoId: string;editMemoId: string;}@@ -26,26 +24,12 @@ interface SetEditMemoIdAction {};}-interface SetMobileViewAction {- type: "SET_MOBILE_VIEW";- payload: {- isMobileView: boolean;- };-}--interface SetShowSidebarAction {- type: "SET_SHOW_SIDEBAR_IN_MOBILE_VIEW";- payload: {- showSiderbarInMobileView: boolean;- };-}-interface SetAppSettingAction {type: "SET_APP_SETTING";payload: Partial<AppSetting>;}-export type Actions = SetMobileViewAction | SetShowSidebarAction | SetEditMemoIdAction | SetMarkMemoIdAction | SetAppSettingAction;+export type Actions = SetEditMemoIdAction | SetMarkMemoIdAction | SetAppSettingAction;export function reducer(state: State, action: Actions) {switch (action.type) {@@ -69,26 +53,6 @@ export function reducer(state: State, action: Actions) {editMemoId: action.payload.editMemoId,};}- case "SET_MOBILE_VIEW": {- if (action.payload.isMobileView === state.isMobileView) {- return state;- }-- return {- ...state,- isMobileView: action.payload.isMobileView,- };- }- case "SET_SHOW_SIDEBAR_IN_MOBILE_VIEW": {- if (action.payload.showSiderbarInMobileView === state.showSiderbarInMobileView) {- return state;- }-- return {- ...state,- showSiderbarInMobileView: action.payload.showSiderbarInMobileView,- };- }case "SET_APP_SETTING": {return {...state,@@ -108,6 +72,4 @@ export const defaultState: State = {shouldHideImageUrl: true,shouldUseMarkdownParser: true,useTinyUndoHistoryCache: false,- isMobileView: false,- showSiderbarInMobileView: false,};