实现源站端口跟随功能

This commit is contained in:
刘祥超
2022-06-29 21:56:44 +08:00
parent 633684f576
commit c454cd75b3
16 changed files with 215 additions and 120 deletions

View File

@@ -29,11 +29,14 @@ Vue.component("combo-box", {
}
// 设定菜单宽度
let inputWidth = this.$refs.searchBox.offsetWidth
if (inputWidth != null && inputWidth > 0) {
this.$refs.menu.style.width = inputWidth + "px"
} else if (this.styleWidth.length > 0) {
this.$refs.menu.style.width = this.styleWidth
let searchBox = this.$refs.searchBox
if (searchBox != null) {
let inputWidth = searchBox.offsetWidth
if (inputWidth != null && inputWidth > 0) {
this.$refs.menu.style.width = inputWidth + "px"
} else if (this.styleWidth.length > 0) {
this.$refs.menu.style.width = this.styleWidth
}
}
},
data: function () {