diff --git a/dist/index.js b/dist/index.js index dcae65ff..88be1576 100644 --- a/dist/index.js +++ b/dist/index.js @@ -665,6 +665,11 @@ this.color.value = newColor; this.chatModel.setColor(newColor); }; + remove = () => { + this.close(); + this.chatModel.delete(); + this.chatListViewModel.restoreChats(); + }; // restore restorePageSelection = () => { const path = storageKeys.chatLastUsedPage(this.chatModel.id); @@ -748,6 +753,7 @@ }; // restore restoreChats = () => { + this.chatViewModels.clear(); for (const chatModel of this.chatListModel.chatModels.values()) { const chatViewModel = this.createChatViewModel(chatModel); this.chatViewModels.add(chatViewModel); @@ -859,7 +865,8 @@ addSecondaryChannelButtonAudioLabel: "add secondary channel", encryptionKeyLabel: "Encryption key", setEncryptionKeyButtonAudioLabel: "set encryption key", - showEncryptionKey: "Show encryption key" + showEncryptionKey: "Show encryption key", + deleteChatButton: "Delete entire chat" } } }; @@ -971,7 +978,7 @@ "on:click": setColor } ); - })))); + })), /* @__PURE__ */ createElement("hr", null), /* @__PURE__ */ createElement("button", { class: "danger width-input flex-no", "on:click": chatViewModel.remove }, translations.chatPage.settings.deleteChatButton, /* @__PURE__ */ createElement("span", { class: "icon" }, "delete_forever")))); } // src/View/chatPage.tsx diff --git a/dist/styles.css b/dist/styles.css index 187f9ff6..70a696e2 100644 --- a/dist/styles.css +++ b/dist/styles.css @@ -798,6 +798,10 @@ header button { max-height: 100% !important; } +button:not(.tile):not(header *), +footer, +input:not([type="checkbox"]):not([type="radio"]), +select, .modal > div > :is(button, div.flex-row) { min-height: var(--control-height); } diff --git a/src/View/ChatPages/settingsPage.tsx b/src/View/ChatPages/settingsPage.tsx index 93f861fd..fd8accf9 100644 --- a/src/View/ChatPages/settingsPage.tsx +++ b/src/View/ChatPages/settingsPage.tsx @@ -135,6 +135,13 @@ export function SettingsPage(chatViewModel: ChatViewModel) { ); })} + +