diff --git a/frontend/src/components/content_value/ContentSearchInput.vue b/frontend/src/components/content_value/ContentSearchInput.vue index 658a41e..4ecd0a8 100644 --- a/frontend/src/components/content_value/ContentSearchInput.vue +++ b/frontend/src/components/content_value/ContentSearchInput.vue @@ -90,6 +90,7 @@ defineExpose({ v-model:value="inputData.filter" :placeholder="$t('interface.filter')" :size="props.small ? 'small' : ''" + :theme-overrides="{ paddingSmall: '0 3px', paddingMedium: '0 6px' }" clearable @clear="onClearFilter" @input="onInput" diff --git a/frontend/src/components/sidebar/BrowserTree.vue b/frontend/src/components/sidebar/BrowserTree.vue index 94b87b5..91e477d 100644 --- a/frontend/src/components/sidebar/BrowserTree.vue +++ b/frontend/src/components/sidebar/BrowserTree.vue @@ -367,13 +367,7 @@ const renderPrefix = ({ option }) => { case ConnectionType.RedisValue: if (prefStore.keyIconType === typesIconStyle.ICON) { - return h( - NIcon, - { size: 20 }, - { - default: () => h(!!option.redisKeyCode ? Binary : Key), - }, - ) + return h(NIcon, { size: 20 }, () => h(Key)) } const loading = isEmpty(option.redisType) || option.redisType === 'loading' if (loading) { @@ -506,10 +500,8 @@ const calcValueMenu = () => { // render menu function icon const renderSuffix = ({ option }) => { - if ( - (option.type === ConnectionType.RedisDB && option.opened) || - (includes(selectedKeys.value, option.key) && !props.checkMode) - ) { + const selected = includes(selectedKeys.value, option.key) + if (selected && !props.checkMode) { switch (option.type) { case ConnectionType.RedisDB: return renderIconMenu(calcDBMenu(option.opened, option.loading, option.fullLoaded)) @@ -518,6 +510,9 @@ const renderSuffix = ({ option }) => { case ConnectionType.RedisValue: return renderIconMenu(calcValueMenu()) } + } else if (!selected && !!option.redisKeyCode && option.type === ConnectionType.RedisValue) { + // render binary icon + return renderIconMenu(h(NIcon, { size: 20 }, () => h(Binary))) } return null } diff --git a/frontend/src/utils/theme.js b/frontend/src/utils/theme.js index aa7f15c..86e35af 100644 --- a/frontend/src/utils/theme.js +++ b/frontend/src/utils/theme.js @@ -23,7 +23,7 @@ export const themeOverrides = { paddingMedium: '0 12px', }, Tag: { - // borderRadius: '3px' + borderRadius: '4px', heightLarge: '32px', }, Input: {