Skip to content

Commit

Permalink
minor fix in outbound (#946)
Browse files Browse the repository at this point in the history
* Update outbound.html

* Update outbound.js

* Update outbound.html

* Update outbound.html

* Update outbound.html
  • Loading branch information
shahin-io authored Feb 16, 2024
1 parent 6249528 commit c277fd2
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 11 deletions.
2 changes: 1 addition & 1 deletion web/assets/js/model/outbound.js
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ class Outbound extends CommonClass {
}

canEnableTls() {
if (![Protocols.VMess, Protocols.VLESS, Protocols.Trojan].includes(this.protocol)) return false;
if (![Protocols.VMess, Protocols.VLESS, Protocols.Trojan, Protocols.Shadowsocks].includes(this.protocol)) return false;
return ["tcp", "ws", "http", "quic", "grpc"].includes(this.stream.network);
}

Expand Down
29 changes: 19 additions & 10 deletions web/html/xui/form/outbound.html
Original file line number Diff line number Diff line change
Expand Up @@ -195,15 +195,24 @@
</template>
<!-- shadowsocks -->
<template v-if="outbound.protocol === Protocols.Shadowsocks">
<a-form-item label='{{ i18n "encryption" }}'>
<a-select v-model="outbound.settings.method" :dropdown-class-name="themeSwitcher.currentTheme">
<a-select-option v-for="(method,method_name) in SSMethods" :value="method">[[ method_name ]]</a-select-option>
</a-select>
</a-form-item>
<a-form-item label='UDP over TCP'>
<a-switch v-model="outbound.settings.uot"></a-switch>
</a-form-item>
</template>
<a-form-item label='{{ i18n "password" }}'>
<a-input v-model.trim="outbound.settings.password"></a-input>
</a-form-item>
<a-form-item label='{{ i18n "encryption" }}'>
<a-select v-model="outbound.settings.method" :dropdown-class-name="themeSwitcher.currentTheme">
<a-select-option v-for="(method, method_name) in SSMethods" :value="method">[[ method_name ]]</a-select-option>
</a-select>
</a-form-item>
<a-form-item label='UDP over TCP'>
<a-switch v-model="outbound.settings.uot"></a-switch>
</a-form-item>
</template>
<!-- trojan -->
<template v-if="outbound.protocol === Protocols.Trojan">
<a-form-item label='{{ i18n "password" }}'>
<a-input v-model.trim="outbound.settings.password"></a-input>
</a-form-item>
</template>
</template>

<!-- stream settings -->
Expand Down Expand Up @@ -365,7 +374,7 @@

<!-- reality settings -->
<template v-if="outbound.stream.isReality">
<a-form-item label='{{ i18n "domainName" }}'>
<a-form-item label="SNI">
<a-input v-model.trim="outbound.stream.reality.serverName"></a-input>
</a-form-item>
<a-form-item label="uTLS">
Expand Down

0 comments on commit c277fd2

Please sign in to comment.