+
mailUiStore.deleteSelectedMessages()
}
.mail-list-panel {
- width: 320px;
+ flex: 0 0 var(--mail-list-width, 35%);
+ width: var(--mail-list-width, 35%);
min-width: 280px;
- max-width: 450px;
+ max-width: 70%;
border-right: 1px solid rgb(var(--v-border-color));
overflow-y: auto;
display: flex;
@@ -477,6 +484,7 @@ const handleMessageSelectionDelete = () => mailUiStore.deleteSelectedMessages()
}
.mail-list-panel {
+ flex: 0 0 auto;
width: 100%;
max-width: 100%;
border-right: none;
diff --git a/src/stores/mailSettingsStore.ts b/src/stores/mailSettingsStore.ts
index 35e1af6..53e0ccb 100644
--- a/src/stores/mailSettingsStore.ts
+++ b/src/stores/mailSettingsStore.ts
@@ -6,11 +6,13 @@ const MESSAGE_READ_ENABLED_KEY = 'mail.behaviour.messageReadEnabled'
const MESSAGE_READ_DELAY_KEY = 'mail.behaviour.messageReadDelay'
const FOLDER_VIEW_MODE_KEY = 'mail.folderViewMode'
const MESSAGE_LIST_DENSITY_KEY = 'mail.messageListDensity'
+const MESSAGE_LIST_WIDTH_KEY = 'mail.messageListWidth'
const DEFAULT_MESSAGE_READ_ENABLED = false
const DEFAULT_MESSAGE_READ_DELAY = 5
const DEFAULT_FOLDER_VIEW_MODE = 'tree'
const DEFAULT_MESSAGE_LIST_DENSITY = 'cozy'
+const DEFAULT_MESSAGE_LIST_WIDTH = 35
export type FolderViewMode = 'tree' | 'page'
@@ -33,6 +35,16 @@ export const messageListDensityConfig: Record {
const userStore = useUserStore()
@@ -99,9 +115,18 @@ export const useMailSettingsStore = defineStore('mailSettingsStore', () => {
),
})
+ const messageListWidth = computed({
+ get: () => normalizeMessageListWidth(userStore.getSetting(MESSAGE_LIST_WIDTH_KEY), DEFAULT_MESSAGE_LIST_WIDTH),
+ set: (value: MessageListWidth) => userStore.setSetting(
+ MESSAGE_LIST_WIDTH_KEY,
+ normalizeMessageListWidth(value, DEFAULT_MESSAGE_LIST_WIDTH),
+ ),
+ })
+
return {
folderViewMode,
messageListDensity,
+ messageListWidth,
messageReadEnabled,
messageReadDelay,
}