Skip to content

Commit

Permalink
优化细节
Browse files Browse the repository at this point in the history
  • Loading branch information
iwind committed Oct 10, 2021
1 parent a5ee2dd commit 558b5e1
Show file tree
Hide file tree
Showing 13 changed files with 41 additions and 12 deletions.
10 changes: 6 additions & 4 deletions web/public/js/components/common/network-addresses-box.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ Vue.component("network-addresses-box", {
addresses: addresses,
protocol: protocol,
name: name,
from: from,
supportRange: this.vSupportRange
from: from
}
},
watch: {
Expand All @@ -42,7 +41,7 @@ Vue.component("network-addresses-box", {
addAddr: function () {
let that = this
window.UPDATING_ADDR = null
teaweb.popup("/servers/addPortPopup?serverType=" + this.vServerType + "&protocol=" + this.protocol + "&from=" + this.from + "&supportRange=" + (this.supportRange ? 1 : 0), {
teaweb.popup("/servers/addPortPopup?serverType=" + this.vServerType + "&protocol=" + this.protocol + "&from=" + this.from + "&supportRange=" + (this.supportRange() ? 1 : 0), {
height: "18em",
callback: function (resp) {
var addr = resp.data.address
Expand Down Expand Up @@ -73,7 +72,7 @@ Vue.component("network-addresses-box", {
updateAddr: function (index, addr) {
let that = this
window.UPDATING_ADDR = addr
teaweb.popup("/servers/addPortPopup?serverType=" + this.vServerType + "&protocol=" + this.protocol + "&from=" + this.from + "&supportRange=" + (this.supportRange ? 1 : 0), {
teaweb.popup("/servers/addPortPopup?serverType=" + this.vServerType + "&protocol=" + this.protocol + "&from=" + this.from + "&supportRange=" + (this.supportRange() ? 1 : 0), {
height: "18em",
callback: function (resp) {
var addr = resp.data.address
Expand All @@ -92,6 +91,9 @@ Vue.component("network-addresses-box", {

// 发送事件
this.$emit("change", this.addresses)
},
supportRange: function () {
return this.vSupportRange || (this.vServerType == "tcpProxy" || this.vServerType == "udpProxy")
}
},
template: `<div>
Expand Down
4 changes: 4 additions & 0 deletions web/views/@default/@layout.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion web/views/@default/@layout.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions web/views/@default/@layout.less
Original file line number Diff line number Diff line change
Expand Up @@ -837,3 +837,9 @@ td {
input.error {
border: 1px #e0b4b4 solid !important;
}

// textarea
textarea.wide-code {
font-family: Menlo, Monaco, "Courier New", monospace !important;
line-height: 1.6 !important;
}
4 changes: 4 additions & 0 deletions web/views/@default/@layout_popup.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 558b5e1

Please sign in to comment.