Skip to content

armgit / memos

Public Imported from GitHub
0

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.

chore: update header

Stevendca90fb5d2bf
diff --git a/web/src/components/MobileHeader.tsx b/web/src/components/MobileHeader.tsx
index 6ac8e1eca..a28d02ec0 100644
--- a/web/src/components/MobileHeader.tsx
+++ b/web/src/components/MobileHeader.tsx
@@ -7,7 +7,7 @@ interface Props {
}
const MobileHeader = (props: Props) => {
- const { showSearch = true } = props;
+ const { showSearch } = props;
const [titleText] = useState("MEMOS");
return (
@@ -21,9 +21,7 @@ const MobileHeader = (props: Props) => {
{titleText}
</span>
</div>
- <div className={`${showSearch ? "flex" : "hidden"} flex-row justify-end items-center pr-1`}>
- <HomeSidebarDrawer />
- </div>
+ <div className={`flex flex-row justify-end items-center pr-1`}>{showSearch && <HomeSidebarDrawer />}</div>
</div>
);
};
diff --git a/web/src/pages/Archived.tsx b/web/src/pages/Archived.tsx
index 2f56bd4d5..f423938ad 100644
--- a/web/src/pages/Archived.tsx
+++ b/web/src/pages/Archived.tsx
@@ -36,7 +36,7 @@ const Archived = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-start px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<MemoFilter />
{loadingState.isLoading ? (
<div className="w-full h-32 flex flex-col justify-center items-center">
diff --git a/web/src/pages/DailyReview.tsx b/web/src/pages/DailyReview.tsx
index 66ff44cc7..b2e991c6c 100644
--- a/web/src/pages/DailyReview.tsx
+++ b/web/src/pages/DailyReview.tsx
@@ -65,7 +65,7 @@ const DailyReview = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-center px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<div className="w-full shadow flex flex-col justify-start items-start px-4 py-3 rounded-xl bg-white dark:bg-zinc-700 text-black dark:text-gray-300">
<div className="relative w-full flex flex-row justify-start items-center">
<p
diff --git a/web/src/pages/Explore.tsx b/web/src/pages/Explore.tsx
index 5efe822a8..ce96eb094 100644
--- a/web/src/pages/Explore.tsx
+++ b/web/src/pages/Explore.tsx
@@ -75,7 +75,7 @@ const Explore = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-center px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<div className="relative w-full h-auto flex flex-col justify-start items-start">
<MemoFilter />
{sortedMemos.map((memo) => (
diff --git a/web/src/pages/Home.tsx b/web/src/pages/Home.tsx
index 57058f941..0e593b110 100644
--- a/web/src/pages/Home.tsx
+++ b/web/src/pages/Home.tsx
@@ -7,7 +7,7 @@ const Home = () => {
return (
<div className="w-full flex flex-row justify-start items-start">
<div className="w-full px-4 md:max-w-[calc(100%-14rem)] sm:px-2 sm:pt-4">
- <MobileHeader />
+ <MobileHeader showSearch={true} />
<MemoEditor className="mb-2" cacheKey="home-memo-editor" />
<MemoList />
</div>
diff --git a/web/src/pages/Inboxes.tsx b/web/src/pages/Inboxes.tsx
index c72c8dbad..501516cb9 100644
--- a/web/src/pages/Inboxes.tsx
+++ b/web/src/pages/Inboxes.tsx
@@ -21,7 +21,7 @@ const Inboxes = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-center px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<div className="w-full shadow flex flex-col justify-start items-start px-4 py-3 rounded-xl bg-white dark:bg-zinc-700 text-black dark:text-gray-300">
<div className="relative w-full flex flex-row justify-between items-center">
<p className="px-2 py-1 flex flex-row justify-start items-center select-none opacity-80">
diff --git a/web/src/pages/Resources.tsx b/web/src/pages/Resources.tsx
index a5c4763a4..3cd00a1ee 100644
--- a/web/src/pages/Resources.tsx
+++ b/web/src/pages/Resources.tsx
@@ -63,7 +63,7 @@ const Resources = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-center px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<div className="w-full shadow flex flex-col justify-start items-start px-4 py-3 rounded-xl bg-white dark:bg-zinc-700 text-black dark:text-gray-300">
<div className="relative w-full flex flex-row justify-between items-center">
<p className="px-2 py-1 flex flex-row justify-start items-center select-none opacity-80">
diff --git a/web/src/pages/Setting.tsx b/web/src/pages/Setting.tsx
index dc8819cbf..646bfbe06 100644
--- a/web/src/pages/Setting.tsx
+++ b/web/src/pages/Setting.tsx
@@ -44,7 +44,7 @@ const Setting = () => {
return (
<section className="@container w-full max-w-3xl min-h-full flex flex-col justify-start items-start px-4 sm:px-2 sm:pt-4 pb-8 bg-zinc-100 dark:bg-zinc-800">
- <MobileHeader showSearch={false} />
+ <MobileHeader />
<div className="setting-page-wrapper">
<div className="section-selector-container">
<span className="section-title">{t("common.basic")}</span>