Skip to content

armgit / papra

Public Imported from GitHub
0

The minimalistic document archiving platform.

refactor(mobile): added hanmburger in organization settings (#1235)

Corentin Thomassetae421028a034
diff --git a/.changeset/new-months-dance.md b/.changeset/new-months-dance.md
new file mode 100644
index 00000000..7f83358c
--- /dev/null
+++ b/.changeset/new-months-dance.md
@@ -0,0 +1,5 @@
+---
+'@papra/app': patch
+---
+
+Added mobile friendly hamburger menu in organization settings.
diff --git a/apps/papra-client/src/modules/intake-emails/pages/intake-emails.page.tsx b/apps/papra-client/src/modules/intake-emails/pages/intake-emails.page.tsx
index 96f92ae7..ad1e3ca0 100644
--- a/apps/papra-client/src/modules/intake-emails/pages/intake-emails.page.tsx
+++ b/apps/papra-client/src/modules/intake-emails/pages/intake-emails.page.tsx
@@ -185,7 +185,7 @@ export const IntakeEmailsPage: Component = () => {
if (!config.intakeEmails.isEnabled) {
return (
- <div class="p-6 max-w-screen-md mx-auto mt-10">
+ <div class="p-6 max-w-screen-md mx-auto">
<h1 class="text-xl font-semibold">{t('intake-emails.title')}</h1>
<p class="text-muted-foreground mt-1">{t('intake-emails.description')}</p>
diff --git a/apps/papra-client/src/modules/organizations/pages/organization-usage.page.tsx b/apps/papra-client/src/modules/organizations/pages/organization-usage.page.tsx
index 1d2d0f41..5f24dd10 100644
--- a/apps/papra-client/src/modules/organizations/pages/organization-usage.page.tsx
+++ b/apps/papra-client/src/modules/organizations/pages/organization-usage.page.tsx
@@ -50,7 +50,7 @@ export const OrganizationUsagePage: Component = () => {
}));
return (
- <div class="p-6 mt-10 pb-32 mx-auto max-w-screen-md w-full">
+ <div class="p-6 pb-32 mx-auto max-w-screen-md w-full">
<Suspense>
<Show when={query.data}>
{(getData) => (
diff --git a/apps/papra-client/src/modules/organizations/pages/organizations-auto-tagging-settings.page.tsx b/apps/papra-client/src/modules/organizations/pages/organizations-auto-tagging-settings.page.tsx
index 124c6967..809a2b14 100644
--- a/apps/papra-client/src/modules/organizations/pages/organizations-auto-tagging-settings.page.tsx
+++ b/apps/papra-client/src/modules/organizations/pages/organizations-auto-tagging-settings.page.tsx
@@ -169,7 +169,7 @@ export const OrganizationsAutoTaggingSettingsPage: Component = () => {
const getIsAutoTaggingAvailableForOrganization = () => config.autoTagging.isEnabled;
return (
- <div class="p-6 mt-10 pb-32 mx-auto max-w-screen-md w-full">
+ <div class="p-6 pb-32 mx-auto max-w-screen-md w-full">
<Suspense>
<Show when={organizationSettingsQuery.data?.organizationSettings}>
{(getOrganizationSettings) => (
diff --git a/apps/papra-client/src/modules/organizations/pages/organizations-settings.page.tsx b/apps/papra-client/src/modules/organizations/pages/organizations-settings.page.tsx
index bb0a57fe..1c9940f3 100644
--- a/apps/papra-client/src/modules/organizations/pages/organizations-settings.page.tsx
+++ b/apps/papra-client/src/modules/organizations/pages/organizations-settings.page.tsx
@@ -267,7 +267,7 @@ export const OrganizationsSettingsPage: Component = () => {
}));
return (
- <div class="p-6 mt-10 pb-32 mx-auto max-w-screen-md w-full">
+ <div class="p-6 pb-32 mx-auto max-w-screen-md w-full">
<Suspense>
<Show when={query.data?.organization}>
{(getOrganization) => (
diff --git a/apps/papra-client/src/modules/ui/layouts/organization-settings.layout.tsx b/apps/papra-client/src/modules/ui/layouts/organization-settings.layout.tsx
index 6a8f94c8..332a0a67 100644
--- a/apps/papra-client/src/modules/ui/layouts/organization-settings.layout.tsx
+++ b/apps/papra-client/src/modules/ui/layouts/organization-settings.layout.tsx
@@ -3,6 +3,8 @@ import { A, useParams } from '@solidjs/router';
import { useI18n } from '@/modules/i18n/i18n.provider';
import { SideNav } from '@/modules/ui/components/sidenav';
import { Button } from '../components/button';
+import { SidenavLayout } from './sidenav.layout';
+import { UserSettingsDropdown } from '@/modules/users/components/user-settings.component';
export const OrganizationSettingsLayout: ParentComponent = (props) => {
const params = useParams();
@@ -41,8 +43,8 @@ export const OrganizationSettingsLayout: ParentComponent = (props) => {
];
return (
- <div class="flex flex-row h-screen min-h-0">
- <div class="w-280px border-r border-r-border flex-shrink-0 hidden md:block bg-card">
+ <SidenavLayout
+ sideNav={() => (
<SideNav
mainMenu={getNavigationItems()}
header={() => (
@@ -60,8 +62,13 @@ export const OrganizationSettingsLayout: ParentComponent = (props) => {
</div>
)}
/>
- </div>
- <div class="flex-1 min-h-0 flex flex-col">{props.children}</div>
- </div>
+ )}
+ children={props.children}
+ header={() => (
+ <div class="flex items-center justify-end w-full flex-1">
+ <UserSettingsDropdown />
+ </div>
+ )}
+ />
);
};
diff --git a/apps/papra-client/src/modules/webhooks/pages/create-webhook.page.tsx b/apps/papra-client/src/modules/webhooks/pages/create-webhook.page.tsx
index 6262ccce..2b3fe8dc 100644
--- a/apps/papra-client/src/modules/webhooks/pages/create-webhook.page.tsx
+++ b/apps/papra-client/src/modules/webhooks/pages/create-webhook.page.tsx
@@ -80,7 +80,7 @@ export const CreateWebhookPage: Component = () => {
});
return (
- <div class="p-6 mt-12 pb-32 mx-auto max-w-xl w-full">
+ <div class="p-6 pb-32 mx-auto max-w-xl w-full">
<div class="border-b pb-4 mb-6">
<h1 class="text-2xl font-bold">{t('webhooks.create.title')}</h1>
<p class="text-sm text-muted-foreground">{t('webhooks.create.description')}</p>
diff --git a/apps/papra-client/src/modules/webhooks/pages/edit-webhook.page.tsx b/apps/papra-client/src/modules/webhooks/pages/edit-webhook.page.tsx
index fe5ef580..57264f18 100644
--- a/apps/papra-client/src/modules/webhooks/pages/edit-webhook.page.tsx
+++ b/apps/papra-client/src/modules/webhooks/pages/edit-webhook.page.tsx
@@ -211,7 +211,7 @@ export const EditWebhookPage: Component = () => {
}));
return (
- <div class="p-6 mt-12 pb-32 mx-auto max-w-xl w-full">
+ <div class="p-6 pb-32 mx-auto max-w-xl w-full">
<div class="border-b pb-4 mb-6">
<h1 class="text-2xl font-bold">{t('webhooks.update.title')}</h1>
<p class="text-sm text-muted-foreground">{t('webhooks.update.description')}</p>
diff --git a/apps/papra-client/src/modules/webhooks/pages/webhooks.page.tsx b/apps/papra-client/src/modules/webhooks/pages/webhooks.page.tsx
index a431c31c..042eba1c 100644
--- a/apps/papra-client/src/modules/webhooks/pages/webhooks.page.tsx
+++ b/apps/papra-client/src/modules/webhooks/pages/webhooks.page.tsx
@@ -102,7 +102,7 @@ export const WebhooksPage: Component = () => {
}));
return (
- <div class="p-6 mt-10 pb-32 mx-auto max-w-screen-md w-full">
+ <div class="p-6 pb-32 mx-auto max-w-screen-md w-full">
<div class="flex gap-4 items-center justify-between">
<div>
<h1 class="text-xl font-semibold mb-2">{t('webhooks.list.title')}</h1>