fix: connection profiles mapping error

This commit is contained in:
tiny-craft 2023-08-29 15:44:33 +08:00
parent cff70bc23c
commit b580fedade
6 changed files with 25 additions and 28 deletions

View File

@ -21,7 +21,7 @@
"naive-ui": "^2.34.4", "naive-ui": "^2.34.4",
"prettier": "^3.0.2", "prettier": "^3.0.2",
"unplugin-auto-import": "^0.16.6", "unplugin-auto-import": "^0.16.6",
"unplugin-icons": "^0.16.5", "unplugin-icons": "^0.16.6",
"unplugin-vue-components": "^0.25.1", "unplugin-vue-components": "^0.25.1",
"vite": "^4.4.9" "vite": "^4.4.9"
} }
@ -1753,18 +1753,18 @@
} }
}, },
"node_modules/unplugin-icons": { "node_modules/unplugin-icons": {
"version": "0.16.5", "version": "0.16.6",
"resolved": "https://registry.npmmirror.com/unplugin-icons/-/unplugin-icons-0.16.5.tgz", "resolved": "https://registry.npmmirror.com/unplugin-icons/-/unplugin-icons-0.16.6.tgz",
"integrity": "sha512-laCCqMWfng1XZgB9yowGfjBdDhtmz8t8zVnhzRNEMhBNdy26QrVewVmdXk/zsiAQYnEWvIxTjvW1nQXrxdd2+w==", "integrity": "sha512-jL70sAC7twp4hI/MTfm+vyvTRtHqiEIzf3XOjJz7yzhMEEQnk5Ey5YIXRAU03Mc4BF99ITvvnBzfyRZee86OeA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@antfu/install-pkg": "^0.1.1", "@antfu/install-pkg": "^0.1.1",
"@antfu/utils": "^0.7.5", "@antfu/utils": "^0.7.6",
"@iconify/utils": "^2.1.7", "@iconify/utils": "^2.1.9",
"debug": "^4.3.4", "debug": "^4.3.4",
"kolorist": "^1.8.0", "kolorist": "^1.8.0",
"local-pkg": "^0.4.3", "local-pkg": "^0.4.3",
"unplugin": "^1.3.2" "unplugin": "^1.4.0"
}, },
"peerDependencies": { "peerDependencies": {
"@svgr/core": ">=7.0.0", "@svgr/core": ">=7.0.0",
@ -3219,18 +3219,18 @@
} }
}, },
"unplugin-icons": { "unplugin-icons": {
"version": "0.16.5", "version": "0.16.6",
"resolved": "https://registry.npmmirror.com/unplugin-icons/-/unplugin-icons-0.16.5.tgz", "resolved": "https://registry.npmmirror.com/unplugin-icons/-/unplugin-icons-0.16.6.tgz",
"integrity": "sha512-laCCqMWfng1XZgB9yowGfjBdDhtmz8t8zVnhzRNEMhBNdy26QrVewVmdXk/zsiAQYnEWvIxTjvW1nQXrxdd2+w==", "integrity": "sha512-jL70sAC7twp4hI/MTfm+vyvTRtHqiEIzf3XOjJz7yzhMEEQnk5Ey5YIXRAU03Mc4BF99ITvvnBzfyRZee86OeA==",
"dev": true, "dev": true,
"requires": { "requires": {
"@antfu/install-pkg": "^0.1.1", "@antfu/install-pkg": "^0.1.1",
"@antfu/utils": "^0.7.5", "@antfu/utils": "^0.7.6",
"@iconify/utils": "^2.1.7", "@iconify/utils": "^2.1.9",
"debug": "^4.3.4", "debug": "^4.3.4",
"kolorist": "^1.8.0", "kolorist": "^1.8.0",
"local-pkg": "^0.4.3", "local-pkg": "^0.4.3",
"unplugin": "^1.3.2" "unplugin": "^1.4.0"
} }
}, },
"unplugin-vue-components": { "unplugin-vue-components": {

View File

@ -22,7 +22,7 @@
"naive-ui": "^2.34.4", "naive-ui": "^2.34.4",
"prettier": "^3.0.2", "prettier": "^3.0.2",
"unplugin-auto-import": "^0.16.6", "unplugin-auto-import": "^0.16.6",
"unplugin-icons": "^0.16.5", "unplugin-icons": "^0.16.6",
"unplugin-vue-components": "^0.25.1", "unplugin-vue-components": "^0.25.1",
"vite": "^4.4.9" "vite": "^4.4.9"
} }

View File

@ -1 +1 @@
d2a1ae5c33eb997098a10aa64e71ab0c 60ee635e898e51cbe90151ee2530f9cc

View File

@ -1,7 +1,6 @@
<script setup> <script setup>
import { get, isEmpty, map, mapValues, pickBy, split, sum, toArray, toNumber } from 'lodash' import { get, isEmpty, map, mapValues, pickBy, split, sum, toArray, toNumber } from 'lodash'
import { computed, ref } from 'vue' import { computed, ref } from 'vue'
import Help from '@/components/icons/Help.vue'
import IconButton from '@/components/common/IconButton.vue' import IconButton from '@/components/common/IconButton.vue'
import Filter from '@/components/icons/Filter.vue' import Filter from '@/components/icons/Filter.vue'
import Refresh from '@/components/icons/Refresh.vue' import Refresh from '@/components/icons/Refresh.vue'
@ -69,8 +68,6 @@ const totalKeys = computed(() => {
}) })
return sum(toArray(nums)) return sum(toArray(nums))
}) })
const infoList = computed(() => map(props.info, (value, key) => ({ value, key })))
const infoTab = ref('')
const infoFilter = ref('') const infoFilter = ref('')
</script> </script>

View File

@ -150,6 +150,11 @@ const useConnectionStore = defineStore('connections', {
type: ConnectionType.Server, type: ConnectionType.Server,
// isLeaf: false, // isLeaf: false,
}) })
profiles[item.name] = {
defaultFilter: item.defaultFilter,
keySeparator: item.keySeparator,
markColor: item.markColor,
}
} }
conns.push({ conns.push({
key: conn.name + '/', key: conn.name + '/',
@ -157,11 +162,6 @@ const useConnectionStore = defineStore('connections', {
type: ConnectionType.Group, type: ConnectionType.Group,
children, children,
}) })
profiles[conn.name] = {
defaultFilter: conn.defaultFilter,
keySeparator: conn.keySeparator,
markColor: conn.markColor,
}
} }
this.setKeyFilter(conn.name, -1, conn.defaultFilter) this.setKeyFilter(conn.name, -1, conn.defaultFilter)
} }

View File

@ -17,9 +17,9 @@ export const themeOverrides = {
// borderRadius: '3px' // borderRadius: '3px'
}, },
Tabs: { Tabs: {
tabGapSmallCard: '1px', tabGapSmallCard: '2px',
tabGapMediumCard: '1px', tabGapMediumCard: '2px',
tabGapLargeCard: '1px', tabGapLargeCard: '2px',
}, },
Form: { Form: {
labelFontSizeTopSmall: '12px', labelFontSizeTopSmall: '12px',