diff --git a/frontend/src/components/protocols/Selector.vue b/frontend/src/components/protocols/Selector.vue index db7e424..0dca67a 100644 --- a/frontend/src/components/protocols/Selector.vue +++ b/frontend/src/components/protocols/Selector.vue @@ -2,10 +2,24 @@ - + - + @@ -17,15 +31,16 @@ \ No newline at end of file diff --git a/frontend/src/components/protocols/UrlTest.vue b/frontend/src/components/protocols/UrlTest.vue index 4a63183..b72fdac 100644 --- a/frontend/src/components/protocols/UrlTest.vue +++ b/frontend/src/components/protocols/UrlTest.vue @@ -2,12 +2,19 @@ - + - + @@ -74,7 +81,7 @@ \ No newline at end of file diff --git a/frontend/src/layouts/modals/Outbound.vue b/frontend/src/layouts/modals/Outbound.vue index f9d13ad..c333d77 100644 --- a/frontend/src/layouts/modals/Outbound.vue +++ b/frontend/src/layouts/modals/Outbound.vue @@ -53,15 +53,14 @@ - - + + -
{{ outbound }}
@@ -109,7 +108,7 @@ import Ssh from '@/components/protocols/Ssh.vue' import Selector from '@/components/protocols/Selector.vue' import UrlTest from '@/components/protocols/UrlTest.vue' export default { - props: ['visible', 'data', 'id', 'stats'], + props: ['visible', 'data', 'id', 'stats', 'tags'], emits: ['close', 'save'], data() { return { diff --git a/frontend/src/views/Outbounds.vue b/frontend/src/views/Outbounds.vue index d29db6e..9d05233 100644 --- a/frontend/src/views/Outbounds.vue +++ b/frontend/src/views/Outbounds.vue @@ -5,6 +5,7 @@ :id="modal.id" :stats="modal.stats" :data="modal.data" + :tags="outboundTags" @close="closeModal" @save="saveModal" /> @@ -30,9 +31,30 @@ - Server + {{ $t('in.addr') }} - {{ (item.server ?? '') + ' ' + (item.server_port ?? '') }} + {{ item.server?? '-' }} + + + + {{ $t('in.port') }} + + {{ item.server_port?? '-' }} + + + + {{ $t('in.tls') }} + + {{ Object.hasOwn(item,'tls') ? $t(item.tls?.enabled ? 'enable' : 'disable') : '-' }} + + + + {{ $t('online') }} + + + @@ -83,6 +105,14 @@ const outbounds = computed((): Outbound[] => { return appConfig.value.outbounds }) +const outboundTags = computed((): string[] => { + return outbounds.value.map((o:Outbound) => o.tag) +}) + +const onlines = computed(() => { + return Data().onlines.outbound ? outbounds.value.map(i => Data().onlines.outbound.includes(i.tag)) : [] +}) + const v2rayStats = computed((): V2rayApiStats => { return appConfig.value.experimental.v2ray_api.stats })