diff options
Diffstat (limited to 'web/html/settings/xray')
| -rw-r--r-- | web/html/settings/xray/balancers.html | 8 | ||||
| -rw-r--r-- | web/html/settings/xray/basics.html | 105 | ||||
| -rw-r--r-- | web/html/settings/xray/dns.html | 3 | ||||
| -rw-r--r-- | web/html/settings/xray/outbounds.html | 51 |
4 files changed, 58 insertions, 109 deletions
diff --git a/web/html/settings/xray/balancers.html b/web/html/settings/xray/balancers.html index af7def75..5a193cdf 100644 --- a/web/html/settings/xray/balancers.html +++ b/web/html/settings/xray/balancers.html @@ -5,7 +5,8 @@ <span>{{ i18n "pages.xray.balancer.addBalancer"}}</span> </a-button> <a-table :columns="balancerColumns" bordered :row-key="r => r.key" :data-source="balancersData" - :scroll="isMobile ? {} : { x: 200 }" :pagination="false" :indent-size="0" :locale='{ filterConfirm: `{{ i18n "confirm" }}`, filterReset: `{{ i18n "reset" }}` }'> + :scroll="isMobile ? {} : { x: 200 }" :pagination="false" :indent-size="0" + :locale='{ filterConfirm: `{{ i18n "confirm" }}`, filterReset: `{{ i18n "reset" }}` }'> <template slot="action" slot-scope="text, balancer, index"> <span>[[ index+1 ]]</span> <a-dropdown :trigger="['click']"> @@ -18,7 +19,7 @@ </a-menu-item> <a-menu-item @click="deleteBalancer(index)"> <span :style="{ color: '#FF4D4F' }"> - <a-icon type="delete"></a-icon> + <a-icon type="delete"></a-icon> <span>{{ i18n "delete"}}</span> </span> </a-menu-item> @@ -32,7 +33,8 @@ <a-tag :style="{ margin: '0' }" v-if="balancer.strategy=='leastPing'" color="green">Least Ping</a-tag> </template> <template slot="selector" slot-scope="text, balancer, index"> - <a-tag class="info-large-tag" :style="{ margin: '1' }" v-for="sel in balancer.selector">[[ sel ]]</a-tag> + <a-tag class="info-large-tag" :style="{ margin: '1' }" v-for="sel in balancer.selector">[[ sel + ]]</a-tag> </template> </a-table> <a-radio-group v-if="observatoryEnable || burstObservatoryEnable" v-model="obsSettings" @change="changeObsCode" diff --git a/web/html/settings/xray/basics.html b/web/html/settings/xray/basics.html index c637e30a..3ac2349a 100644 --- a/web/html/settings/xray/basics.html +++ b/web/html/settings/xray/basics.html @@ -4,8 +4,7 @@ <a-row :xs="24" :sm="24" :lg="12"> <a-alert type="warning" :style="{ textAlign: 'center' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.generalConfigsDesc" }}</span> </template> </a-alert> @@ -15,11 +14,9 @@ <template #description>{{ i18n "pages.xray.FreedomStrategyDesc" }}</template> <template #control> - <a-select v-model="freedomStrategy" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="freedomStrategy" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> - <a-select-option v-for="s in OutboundDomainStrategies" - :value="s"> + <a-select-option v-for="s in OutboundDomainStrategies" :value="s"> <span>[[ s ]]</span> </a-select-option> </a-select> @@ -30,11 +27,9 @@ <template #description>{{ i18n "pages.xray.RoutingStrategyDesc" }}</template> <template #control> - <a-select v-model="routingStrategy" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="routingStrategy" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> - <a-select-option v-for="s in routingDomainStrategies" - :value="s"> + <a-select-option v-for="s in routingDomainStrategies" :value="s"> <span>[[ s ]]</span> </a-select-option> </a-select> @@ -45,8 +40,7 @@ <template #description>{{ i18n "pages.xray.outboundTestUrlDesc" }}</template> <template #control> - <a-input v-model="outboundTestUrl" - :placeholder="'https://www.google.com/generate_204'" + <a-input v-model="outboundTestUrl" :placeholder="'https://www.google.com/generate_204'" :style="{ width: '100%' }"></a-input> </template> </a-setting-list-item> @@ -93,8 +87,7 @@ <a-row :xs="24" :sm="24" :lg="12"> <a-alert type="warning" :style="{ textAlign: 'center' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.logConfigsDesc" }}</span> </template> </a-alert> @@ -104,8 +97,7 @@ <template #description>{{ i18n "pages.xray.logLevelDesc" }}</template> <template #control> - <a-select v-model="logLevel" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="logLevel" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> <a-select-option v-for="s in log.loglevel" :value="s"> <span>[[ s ]]</span> @@ -118,8 +110,7 @@ <template #description>{{ i18n "pages.xray.accessLogDesc" }}</template> <template #control> - <a-select v-model="accessLog" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="accessLog" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> <a-select-option value> <span>Empty</span> @@ -135,8 +126,7 @@ <template #description>{{ i18n "pages.xray.errorLogDesc" }}</template> <template #control> - <a-select v-model="errorLog" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="errorLog" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> <a-select-option value> <span>Empty</span> @@ -152,8 +142,7 @@ <template #description>{{ i18n "pages.xray.maskAddressDesc" }}</template> <template #control> - <a-select v-model="maskAddressLog" - :dropdown-class-name="themeSwitcher.currentTheme" + <a-select v-model="maskAddressLog" :dropdown-class-name="themeSwitcher.currentTheme" :style="{ width: '100%' }"> <a-select-option value> <span>Empty</span> @@ -176,8 +165,7 @@ <a-row :xs="24" :sm="24" :lg="12"> <a-alert type="warning" :style="{ textAlign: 'center' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.blockConfigsDesc" }}</span> </template> </a-alert> @@ -191,8 +179,7 @@ <a-row :xs="24" :sm="24" :lg="12"> <a-alert type="warning" :style="{ textAlign: 'center' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.blockConnectionsConfigsDesc" }}</span> </template> @@ -201,11 +188,9 @@ <a-setting-list-item paddings="small"> <template #title>{{ i18n "pages.xray.blockips" }}</template> <template #control> - <a-select mode="tags" v-model="blockedIPs" - :style="{ width: '100%' }" + <a-select mode="tags" v-model="blockedIPs" :style="{ width: '100%' }" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.IPsOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.IPsOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> @@ -214,22 +199,18 @@ <a-setting-list-item paddings="small"> <template #title>{{ i18n "pages.xray.blockdomains" }}</template> <template #control> - <a-select mode="tags" v-model="blockedDomains" - :style="{ width: '100%' }" + <a-select mode="tags" v-model="blockedDomains" :style="{ width: '100%' }" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.BlockDomainsOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.BlockDomainsOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> </template> </a-setting-list-item> <a-row :xs="24" :sm="24" :lg="12"> - <a-alert type="warning" - :style="{ textAlign: 'center', marginTop: '20px' }"> + <a-alert type="warning" :style="{ textAlign: 'center', marginTop: '20px' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.directConnectionsConfigsDesc" }}</span> </template> @@ -238,11 +219,9 @@ <a-setting-list-item paddings="small"> <template #title>{{ i18n "pages.xray.directips" }}</template> <template #control> - <a-select mode="tags" :style="{ width: '100%' }" - v-model="directIPs" + <a-select mode="tags" :style="{ width: '100%' }" v-model="directIPs" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.IPsOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.IPsOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> @@ -251,22 +230,18 @@ <a-setting-list-item paddings="small"> <template #title>{{ i18n "pages.xray.directdomains" }}</template> <template #control> - <a-select mode="tags" :style="{ width: '100%' }" - v-model="directDomains" + <a-select mode="tags" :style="{ width: '100%' }" v-model="directDomains" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.DomainsOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.DomainsOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> </template> </a-setting-list-item> <a-row :xs="24" :sm="24" :lg="12"> - <a-alert type="warning" - :style="{ textAlign: 'center', marginTop: '20px' }"> + <a-alert type="warning" :style="{ textAlign: 'center', marginTop: '20px' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> <span>{{ i18n "pages.xray.ipv4RoutingDesc" }}</span> </template> </a-alert> @@ -274,22 +249,18 @@ <a-setting-list-item paddings="small"> <template #title>{{ i18n "pages.xray.ipv4Routing" }}</template> <template #control> - <a-select mode="tags" :style="{ width: '100%' }" - v-model="ipv4Domains" + <a-select mode="tags" :style="{ width: '100%' }" v-model="ipv4Domains" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.ServicesOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.ServicesOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> </template> </a-setting-list-item> <a-row :xs="24" :sm="24" :lg="12"> - <a-alert type="warning" - :style="{ textAlign: 'center', marginTop: '20px' }"> + <a-alert type="warning" :style="{ textAlign: 'center', marginTop: '20px' }"> <template slot="message"> - <a-icon type="exclamation-circle" theme="filled" - :style="{ color: '#FFA031' }"></a-icon> + <a-icon type="exclamation-circle" theme="filled" :style="{ color: '#FFA031' }"></a-icon> {{ i18n "pages.xray.warpRoutingDesc" }} </template> </a-alert> @@ -298,18 +269,15 @@ <template #title>{{ i18n "pages.xray.warpRouting" }}</template> <template #control> <template v-if="WarpExist"> - <a-select mode="tags" :style="{ width: '100%' }" - v-model="warpDomains" + <a-select mode="tags" :style="{ width: '100%' }" v-model="warpDomains" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.ServicesOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.ServicesOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> </template> <template v-else> - <a-button type="primary" icon="cloud" - @click="showWarp()">WARP</a-button> + <a-button type="primary" icon="cloud" @click="showWarp()">WARP</a-button> </template> </template> </a-setting-list-item> @@ -317,11 +285,9 @@ <template #title>{{ i18n "pages.xray.nordRouting" }}</template> <template #control> <template v-if="NordExist"> - <a-select mode="tags" :style="{ width: '100%' }" - v-model="nordDomains" + <a-select mode="tags" :style="{ width: '100%' }" v-model="nordDomains" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="p.value" :label="p.label" - v-for="p in settingsData.ServicesOptions"> + <a-select-option :value="p.value" :label="p.label" v-for="p in settingsData.ServicesOptions"> <span>[[ p.label ]]</span> </a-select-option> </a-select> @@ -333,8 +299,7 @@ </template> </a-setting-list-item> </a-collapse-panel> - <a-collapse-panel key="6" - header='{{ i18n "pages.settings.resetDefaultConfig"}}'> + <a-collapse-panel key="6" header='{{ i18n "pages.settings.resetDefaultConfig"}}'> <a-space direction="horizontal" :style="{ padding: '0 20px' }"> <a-button type="danger" @click="resetXrayConfigToDefault"> <span>{{ i18n "pages.settings.resetDefaultConfig" }}</span> diff --git a/web/html/settings/xray/dns.html b/web/html/settings/xray/dns.html index 8a18bbb4..7935be52 100644 --- a/web/html/settings/xray/dns.html +++ b/web/html/settings/xray/dns.html @@ -29,7 +29,8 @@ <template #control> <a-select v-model="dnsStrategy" :style="{ width: '100%' }" :dropdown-class-name="themeSwitcher.currentTheme"> - <a-select-option :value="l" :label="l" v-for="l in ['UseSystem', 'UseIP', 'UseIPv4', 'UseIPv6']"> + <a-select-option :value="l" :label="l" + v-for="l in ['UseSystem', 'UseIP', 'UseIPv4', 'UseIPv6']"> <span>[[ l ]]</span> </a-select-option> </a-select> diff --git a/web/html/settings/xray/outbounds.html b/web/html/settings/xray/outbounds.html index 232fe55e..f5e83a99 100644 --- a/web/html/settings/xray/outbounds.html +++ b/web/html/settings/xray/outbounds.html @@ -7,21 +7,16 @@ <span v-if="!isMobile">{{ i18n "pages.xray.outbound.addOutbound" }}</span> </a-button> - <a-button type="primary" icon="cloud" - @click="showWarp()">WARP</a-button> - <a-button type="primary" icon="api" - @click="showNord()">NordVPN</a-button> + <a-button type="primary" icon="cloud" @click="showWarp()">WARP</a-button> + <a-button type="primary" icon="api" @click="showNord()">NordVPN</a-button> </a-space> </a-col> <a-col :xs="12" :sm="12" :lg="12" :style="{ textAlign: 'right' }"> <a-button-group> - <a-button icon="sync" @click="refreshOutboundTraffic()" - :loading="refreshing"></a-button> - <a-popconfirm placement="topRight" - @confirm="resetOutboundTraffic(-1)" + <a-button icon="sync" @click="refreshOutboundTraffic()" :loading="refreshing"></a-button> + <a-popconfirm placement="topRight" @confirm="resetOutboundTraffic(-1)" title='{{ i18n "pages.inbounds.resetTrafficContent"}}' - :overlay-class-name="themeSwitcher.currentTheme" - ok-text='{{ i18n "reset"}}' + :overlay-class-name="themeSwitcher.currentTheme" ok-text='{{ i18n "reset"}}' cancel-text='{{ i18n "cancel"}}'> <a-icon slot="icon" type="question-circle-o" :style="{ color: themeSwitcher.isDarkTheme ? '#008771' : '#008771' }"></a-icon> @@ -30,10 +25,8 @@ </a-button-group> </a-col> </a-row> - <a-table :columns="outboundColumns" bordered :row-key="r => r.key" - :data-source="outboundData" - :scroll="isMobile ? {} : { x: 800 }" :pagination="false" - :indent-size="0" + <a-table :columns="outboundColumns" bordered :row-key="r => r.key" :data-source="outboundData" + :scroll="isMobile ? {} : { x: 800 }" :pagination="false" :indent-size="0" :locale='{ filterConfirm: `{{ i18n "confirm" }}`, filterReset: `{{ i18n "reset" }}` }'> <template slot="action" slot-scope="text, outbound, index"> <span>[[ index+1 ]]</span> @@ -41,8 +34,7 @@ <a-icon @click="e => e.preventDefault()" type="more" :style="{ fontSize: '16px', textDecoration: 'bold' }"></a-icon> <a-menu slot="overlay" :theme="themeSwitcher.currentTheme"> - <a-menu-item v-if="index>0" - @click="setFirstOutbound(index)"> + <a-menu-item v-if="index>0" @click="setFirstOutbound(index)"> <a-icon type="vertical-align-top"></a-icon> <span>{{ i18n "pages.xray.rules.first"}}</span> </a-menu-item> @@ -66,8 +58,7 @@ </a-dropdown> </template> <template slot="address" slot-scope="text, outbound, index"> - <p :style="{ margin: '0 5px' }" - v-for="addr in findOutboundAddress(outbound)">[[ addr ]]</p> + <p :style="{ margin: '0 5px' }" v-for="addr in findOutboundAddress(outbound)">[[ addr ]]</p> </template> <template slot="protocol" slot-scope="text, outbound, index"> <a-tag :style="{ margin: '0' }" color="purple">[[ outbound.protocol @@ -76,11 +67,8 @@ v-if="[Protocols.VMess, Protocols.VLESS, Protocols.Trojan, Protocols.Shadowsocks].includes(outbound.protocol)"> <a-tag :style="{ margin: '0' }" color="blue">[[ outbound.streamSettings.network ]]</a-tag> - <a-tag :style="{ margin: '0' }" - v-if="outbound.streamSettings.security=='tls'" - color="green">tls</a-tag> - <a-tag :style="{ margin: '0' }" - v-if="outbound.streamSettings.security=='reality'" + <a-tag :style="{ margin: '0' }" v-if="outbound.streamSettings.security=='tls'" color="green">tls</a-tag> + <a-tag :style="{ margin: '0' }" v-if="outbound.streamSettings.security=='reality'" color="green">reality</a-tag> </template> </template> @@ -91,10 +79,7 @@ <a-tooltip> <template slot="title">{{ i18n "pages.xray.outbound.test" }}</template> - <a-button - type="primary" - shape="circle" - icon="thunderbolt" + <a-button type="primary" shape="circle" icon="thunderbolt" :loading="outboundTestStates[index] && outboundTestStates[index].testing" @click="testOutbound(index)" :disabled="(outbound.protocol === 'blackhole' || outbound.tag === 'blocked') || (outboundTestStates[index] && outboundTestStates[index].testing)"> @@ -102,24 +87,20 @@ </a-tooltip> </template> <template slot="testResult" slot-scope="text, outbound, index"> - <div - v-if="outboundTestStates[index] && outboundTestStates[index].result"> - <a-tag v-if="outboundTestStates[index].result.success" - color="green"> + <div v-if="outboundTestStates[index] && outboundTestStates[index].result"> + <a-tag v-if="outboundTestStates[index].result.success" color="green"> [[ outboundTestStates[index].result.delay ]]ms <span v-if="outboundTestStates[index].result.statusCode"> ([[ outboundTestStates[index].result.statusCode ]])</span> </a-tag> - <a-tooltip v-else - :title="outboundTestStates[index].result.error"> + <a-tooltip v-else :title="outboundTestStates[index].result.error"> <a-tag color="red"> Failed </a-tag> </a-tooltip> </div> - <span - v-else-if="outboundTestStates[index] && outboundTestStates[index].testing"> + <span v-else-if="outboundTestStates[index] && outboundTestStates[index].testing"> <a-icon type="loading" /> </span> <span v-else>-</span> |
