From f4276f72416ab0eb8171b843d475d31f13533a44 Mon Sep 17 00:00:00 2001
From: Henry Jameson <me@hjkos.com>
Date: Mon, 1 Aug 2022 23:20:27 +0300
Subject: made quick settings into their own component, added quick view
 settings, added both to conversation view

---
 .../quick_view_settings/quick_view_settings.vue    | 96 ++++++++++++++++++++++
 1 file changed, 96 insertions(+)
 create mode 100644 src/components/quick_view_settings/quick_view_settings.vue

(limited to 'src/components/quick_view_settings/quick_view_settings.vue')

diff --git a/src/components/quick_view_settings/quick_view_settings.vue b/src/components/quick_view_settings/quick_view_settings.vue
new file mode 100644
index 00000000..78f315f3
--- /dev/null
+++ b/src/components/quick_view_settings/quick_view_settings.vue
@@ -0,0 +1,96 @@
+<template>
+  <Popover
+    trigger="click"
+    class="QuickViewSettings"
+    :bound-to="{ x: 'container' }"
+  >
+    <template #content>
+      <div class="dropdown-menu">
+        <div v-if="loggedIn">
+          <button
+            class="button-default dropdown-item"
+            @click="conversationDisplay = 'tree'"
+          >
+            <span
+              class="menu-checkbox -radio"
+              :class="{ 'menu-checkbox-checked': conversationDisplay === 'tree' }"
+            /><FAIcon icon="folder-tree"/> {{ $t('settings.conversation_display_tree_quick') }}
+          </button>
+          <button
+            class="button-default dropdown-item"
+            @click="conversationDisplay = 'linear'"
+          >
+            <span
+              class="menu-checkbox -radio"
+              :class="{ 'menu-checkbox-checked': conversationDisplay === 'linear' }"
+            /><FAIcon icon="bars"/> {{ $t('settings.conversation_display_linear_quick') }}
+          </button>
+          <div
+            role="separator"
+            class="dropdown-divider"
+          />
+        </div>
+        <button
+          class="button-default dropdown-item"
+          @click="showUserAvatars = !showUserAvatars"
+        >
+          <span
+            class="menu-checkbox"
+            :class="{ 'menu-checkbox-checked': showUserAvatars }"
+          />{{ $t('settings.mention_link_show_avatar_quick') }}
+        </button>
+        <button
+          v-if="!conversation"
+          class="button-default dropdown-item"
+          @click="autoUpdate = !autoUpdate"
+        >
+          <span
+            class="menu-checkbox"
+            :class="{ 'menu-checkbox-checked': autoUpdate }"
+          />{{ $t('settings.auto_update') }}
+        </button>
+        <button
+          v-if="!conversation"
+          class="button-default dropdown-item"
+          @click="collapseWithSubjects = !collapseWithSubjects"
+        >
+          <span
+            class="menu-checkbox"
+            :class="{ 'menu-checkbox-checked': collapseWithSubjects }"
+          />{{ $t('settings.collapse_subject') }}
+        </button>
+        <button
+          class="button-default dropdown-item dropdown-item-icon"
+          @click="openTab('general')"
+        >
+          <FAIcon icon="wrench" />{{ $t('settings.more_settings') }}
+        </button>
+      </div>
+    </template>
+    <template #trigger>
+      <button class="button-unstyled">
+        <FAIcon icon="table-list" />
+      </button>
+    </template>
+  </Popover>
+</template>
+
+<script src="./quick_view_settings.js"></script>
+
+<style lang="scss">
+
+.QuickViewSettings {
+
+  > button {
+    line-height: 100%;
+    height: 100%;
+    width: var(--__panel-heading-height-inner);
+    text-align: center;
+
+    svg {
+      font-size: 1.2em;
+    }
+  }
+}
+
+</style>
-- 
cgit v1.2.3-70-g09d2

