small fixes
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<v-col cols="12" sm="6" md="4" v-if="optionDetour">
|
||||
<v-select
|
||||
hide-details
|
||||
:label="$t('listen.detourText')"
|
||||
:label="$t('dial.detourText')"
|
||||
:items="outTags"
|
||||
v-model="dial.detour">
|
||||
</v-select>
|
||||
@@ -69,9 +69,6 @@
|
||||
<v-col cols="12" sm="6" md="4">
|
||||
<v-select
|
||||
hide-details
|
||||
clearable
|
||||
@click:clear="delete dial.domain_strategy"
|
||||
width="100"
|
||||
:label="$t('listen.domainStrategy')"
|
||||
:items="['prefer_ipv4','prefer_ipv6','ipv4_only','ipv6_only']"
|
||||
v-model="dial.domain_strategy">
|
||||
|
||||
@@ -72,7 +72,6 @@
|
||||
<v-col cols="12" sm="6" md="4">
|
||||
<v-select
|
||||
hide-details
|
||||
width="100"
|
||||
:label="$t('listen.domainStrategy')"
|
||||
:items="['prefer_ipv4','prefer_ipv6','ipv4_only','ipv6_only']"
|
||||
v-model="inbound.domain_strategy">
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
<v-col cols="12" sm="6" md="4" v-if="tpEnable">
|
||||
<v-select
|
||||
hide-details
|
||||
width="100"
|
||||
:label="$t('type')"
|
||||
:items="Object.keys(trspTypes).map((key,index) => ({title: key, value: Object.values(trspTypes)[index]}))"
|
||||
v-model="transportType">
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
<v-col cols="12" sm="6" md="4">
|
||||
<v-select
|
||||
hide-details
|
||||
width="100"
|
||||
:label="$t('type')"
|
||||
:items="Object.keys(inTypes).map((key,index) => ({title: key, value: Object.values(inTypes)[index]}))"
|
||||
v-model="inbound.type"
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
<v-col cols="12" sm="6" md="4">
|
||||
<v-select
|
||||
hide-details
|
||||
width="100"
|
||||
:label="$t('type')"
|
||||
:items="Object.keys(outTypes).map((key,index) => ({title: key, value: Object.values(outTypes)[index]}))"
|
||||
v-model="outbound.type"
|
||||
|
||||
@@ -233,6 +233,7 @@ export default {
|
||||
connTimeout: "Connection Timeout",
|
||||
fbTimeout: "Fallback Timeout",
|
||||
options: "Dial Options",
|
||||
detourText: "Forward to outbound",
|
||||
},
|
||||
transport: {
|
||||
enable: "Enable Transport",
|
||||
|
||||
@@ -232,6 +232,7 @@ export default {
|
||||
connTimeout: "مهلت ارتباط",
|
||||
fbTimeout: "مهلت فالبک",
|
||||
options: "گزینههای تماس",
|
||||
detourText: "ارسال به خروجی دیگر",
|
||||
},
|
||||
transport: {
|
||||
enable: "فعالسازی انتقال",
|
||||
|
||||
@@ -234,6 +234,7 @@ export default {
|
||||
connTimeout: "Thời gian Chờ Kết nối",
|
||||
fbTimeout: "Thời gian Chờ Fallback",
|
||||
options: "Tùy chọn Gọi",
|
||||
detourText: "Chuyển tiếp tới thư đi",
|
||||
},
|
||||
transport: {
|
||||
enable: "Kích hoạt vận chuyển",
|
||||
|
||||
@@ -234,6 +234,7 @@ export default {
|
||||
connTimeout: "连接超时",
|
||||
fbTimeout: "回退超时",
|
||||
options: "拨号选项",
|
||||
detourText: "转发至出站",
|
||||
},
|
||||
transport: {
|
||||
enable: "启用传输",
|
||||
|
||||
@@ -235,6 +235,7 @@ export default {
|
||||
connTimeout: "連接超時",
|
||||
fbTimeout: "回退超時",
|
||||
options: "撥號選項",
|
||||
detourText: "轉寄至出站",
|
||||
},
|
||||
transport: {
|
||||
enable: "啟用傳輸",
|
||||
|
||||
@@ -152,12 +152,12 @@ const v2rayStats = computed((): V2rayApiStats => {
|
||||
})
|
||||
|
||||
const inbounds = computed((): Inbound[] => {
|
||||
return <Inbound[]> appConfig.value.inbounds
|
||||
return <Inbound[]> appConfig.value?.inbounds
|
||||
})
|
||||
|
||||
const inboundTags = computed((): string[] => {
|
||||
if (!inbounds.value) return []
|
||||
return inbounds.value.filter(i => i.tag != "" && Object.hasOwn(i,'users')).map(i => i.tag)
|
||||
return inbounds.value?.filter(i => i.tag != "" && Object.hasOwn(i,'users')).map(i => i.tag)
|
||||
})
|
||||
|
||||
const modal = ref({
|
||||
|
||||
@@ -120,7 +120,7 @@ const inbounds = computed((): Inbound[] => {
|
||||
})
|
||||
|
||||
const inTags = computed((): string[] => {
|
||||
return inbounds.value.map(i => i.tag)
|
||||
return inbounds.value?.map(i => i.tag)
|
||||
})
|
||||
|
||||
const outTags = computed((): string[] => {
|
||||
@@ -136,7 +136,7 @@ const onlines = computed(() => {
|
||||
})
|
||||
|
||||
const v2rayStats = computed((): V2rayApiStats => {
|
||||
return <V2rayApiStats> appConfig.value.experimental.v2ray_api.stats
|
||||
return <V2rayApiStats> appConfig.value.experimental?.v2ray_api.stats
|
||||
})
|
||||
|
||||
const modal = ref({
|
||||
|
||||
@@ -108,7 +108,7 @@ const outbounds = computed((): Outbound[] => {
|
||||
})
|
||||
|
||||
const outboundTags = computed((): string[] => {
|
||||
return outbounds.value.map((o:Outbound) => o.tag)
|
||||
return outbounds.value?.map((o:Outbound) => o.tag)
|
||||
})
|
||||
|
||||
const onlines = computed(() => {
|
||||
@@ -116,7 +116,7 @@ const onlines = computed(() => {
|
||||
})
|
||||
|
||||
const v2rayStats = computed((): V2rayApiStats => {
|
||||
return <V2rayApiStats> appConfig.value.experimental.v2ray_api.stats
|
||||
return <V2rayApiStats> appConfig.value.experimental?.v2ray_api.stats
|
||||
})
|
||||
|
||||
const modal = ref({
|
||||
|
||||
@@ -164,7 +164,7 @@ const route = computed((): any => {
|
||||
|
||||
const rules = computed((): any[] => {
|
||||
const data = route.value
|
||||
if (!route || !('rules' in data) || !Array.isArray(data.rules)){
|
||||
if (!data || !('rules' in data) || !Array.isArray(data.rules)){
|
||||
return []
|
||||
}
|
||||
return data.rules
|
||||
@@ -172,7 +172,7 @@ const rules = computed((): any[] => {
|
||||
|
||||
const rulesets = computed((): any[] => {
|
||||
const data = route.value
|
||||
if (!route || !('rule_set' in data) || !Array.isArray(data.rule_set)){
|
||||
if (!data || !('rule_set' in data) || !Array.isArray(data.rule_set)){
|
||||
return []
|
||||
}
|
||||
return data.rule_set
|
||||
@@ -183,11 +183,11 @@ const rulesetTags = computed((): any[] => {
|
||||
})
|
||||
|
||||
const outboundTags = computed((): string[] => {
|
||||
return appConfig.value.outbounds.map((o:any) => o.tag)
|
||||
return appConfig.value.outbounds?.map((o:any) => o.tag)
|
||||
})
|
||||
|
||||
const inboundTags = computed((): string[] => {
|
||||
return appConfig.value.inbounds.map((i:any) => i.tag)
|
||||
return appConfig.value.inbounds?.map((i:any) => i.tag)
|
||||
})
|
||||
|
||||
let delRuleOverlay = ref(new Array<boolean>)
|
||||
|
||||
Reference in New Issue
Block a user