Compare commits

...

2 Commits

Author SHA1 Message Date
Lykin 70354c14ec perf: disable auto decode for list/hash/set/zset (#175 #250) 2024-05-06 11:26:17 +08:00
Lykin d472836d5f fix: styling discrepancies on macOS 11.x below (#245) 2024-04-30 17:13:32 +08:00
5 changed files with 23 additions and 28 deletions

View File

@ -1,5 +1,5 @@
<script setup>
import { computed, h, nextTick, reactive, ref } from 'vue'
import { computed, h, reactive, ref } from 'vue'
import { useI18n } from 'vue-i18n'
import AddLink from '@/components/icons/AddLink.vue'
import { NButton, NIcon, useThemeVars } from 'naive-ui'
@ -89,7 +89,7 @@ const fieldColumn = computed(() => ({
},
scrollable: true,
},
lineClamp: 10,
lineClamp: 1,
},
filterOptionValue: fieldFilterOption.value,
className: inEdit.value ? 'clickable' : '',
@ -121,6 +121,7 @@ const valueColumn = computed(() => ({
},
scrollable: true,
},
lineClamp: 1,
},
// filterOptionValue: valueFilterOption.value,
className: inEdit.value ? 'clickable' : '',
@ -185,9 +186,9 @@ const resetEdit = () => {
currentEditRow.no = 0
currentEditRow.key = ''
currentEditRow.value = null
if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
}
// if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
// nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
// }
// currentEditRow.format = formatTypes.RAW
// currentEditRow.decode = decodeTypes.NONE
}

View File

@ -1,5 +1,5 @@
<script setup>
import { computed, h, nextTick, reactive, ref } from 'vue'
import { computed, h, reactive, ref } from 'vue'
import { useI18n } from 'vue-i18n'
import AddLink from '@/components/icons/AddLink.vue'
import { NButton, NIcon, useThemeVars } from 'naive-ui'
@ -96,6 +96,7 @@ const valueColumn = computed(() => ({
},
scrollable: true,
},
lineClamp: 1,
},
filterOptionValue: valueFilterOption.value,
className: inEdit.value ? 'clickable' : '',
@ -162,9 +163,9 @@ const saveEdit = async (pos, value, decode, format) => {
const resetEdit = () => {
currentEditRow.no = 0
currentEditRow.value = null
if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
}
// if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
// nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
// }
}
const actionColumn = {

View File

@ -1,5 +1,5 @@
<script setup>
import { computed, h, nextTick, reactive, ref } from 'vue'
import { computed, h, reactive, ref } from 'vue'
import { useI18n } from 'vue-i18n'
import AddLink from '@/components/icons/AddLink.vue'
import { NButton, NIcon, useThemeVars } from 'naive-ui'
@ -95,6 +95,7 @@ const valueColumn = computed(() => ({
},
scrollable: true,
},
lineClamp: 1,
},
filterOptionValue: valueFilterOption.value,
className: inEdit.value ? 'clickable' : '',
@ -159,9 +160,9 @@ const saveEdit = async (pos, value, decode, format) => {
const resetEdit = () => {
currentEditRow.no = 0
currentEditRow.value = null
if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
}
// if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
// nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
// }
}
const actionColumn = {

View File

@ -1,5 +1,5 @@
<script setup>
import { computed, h, nextTick, reactive, ref } from 'vue'
import { computed, h, reactive, ref } from 'vue'
import { useI18n } from 'vue-i18n'
import AddLink from '@/components/icons/AddLink.vue'
import { NButton, NIcon, useThemeVars } from 'naive-ui'
@ -144,6 +144,7 @@ const valueColumn = computed(() => ({
},
scrollable: true,
},
lineClamp: 1,
},
filterOptionValue: valueFilterOption.value,
className: inEdit.value ? 'clickable' : '',
@ -206,9 +207,9 @@ const resetEdit = () => {
currentEditRow.no = 0
currentEditRow.score = 0
currentEditRow.value = null
if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
}
// if (currentEditRow.format !== props.format || currentEditRow.decode !== props.decode) {
// nextTick(() => onFormatChanged(currentEditRow.decode, currentEditRow.format))
// }
}
const actionColumn = {

View File

@ -172,7 +172,6 @@ const exThemeVars = computed(() => {
:options="preferencesOptions"
:render-icon="({ icon }) => render.renderIcon(icon)"
:render-label="({ label }) => render.renderLabel($t(label), { class: 'context-menu-item' })"
content-class="nav-menu-button"
trigger="click"
@select="onSelectPreferenceMenu">
<icon-button :icon="Config" :size="iconSize" :stroke-width="3" />
@ -182,7 +181,6 @@ const exThemeVars = computed(() => {
:icon="QRCode"
:size="iconSize"
:tooltip-delay="100"
class="nav-menu-button"
t-tooltip="ribbon.wechat_official"
@click="openWechatOfficial" />
<icon-button
@ -191,14 +189,12 @@ const exThemeVars = computed(() => {
:icon="Twitter"
:size="iconSize"
:tooltip-delay="100"
class="nav-menu-button"
t-tooltip="ribbon.follow_x"
@click="openX" />
<icon-button
:icon="Github"
:size="iconSize"
:tooltip-delay="100"
class="nav-menu-button"
t-tooltip="ribbon.github"
@click="openGithub" />
</div>
@ -280,15 +276,10 @@ const exThemeVars = computed(() => {
.nav-menu-item {
align-items: center;
padding: 10px 0 15px;
gap: 20px;
--wails-draggable: none;
.nav-menu-button {
margin-bottom: 6px;
:hover {
color: v-bind('themeVars.primaryColor');
}
button {
margin: 10px 0;
}
}
}