mirror of
https://github.com/MetaCubeX/metacubexd.git
synced 2024-11-10 05:15:35 +08:00
feat: add allow-lan (#478)
This commit is contained in:
parent
1e736e7ed7
commit
aa4d1d9e51
@ -103,6 +103,7 @@ export default {
|
||||
version: 'Version',
|
||||
expire: 'Expire',
|
||||
noExpire: 'Null',
|
||||
allowLan: 'Allow Lan',
|
||||
enableTunDevice: 'Enable TUN Device',
|
||||
tunModeStack: 'TUN Mode Stack',
|
||||
tunDeviceName: 'TUN Device Name',
|
||||
|
@ -105,6 +105,7 @@ export default {
|
||||
version: '版本',
|
||||
expire: '到期时间',
|
||||
noExpire: '不限时',
|
||||
allowLan: '允许局域网访问',
|
||||
enableTunDevice: '开启 TUN 转发',
|
||||
tunModeStack: 'TUN 模式堆栈',
|
||||
tunDeviceName: 'TUN 设备名称',
|
||||
|
@ -223,6 +223,26 @@ const ConfigForm: Component<{ backendVersion: Accessor<string> }> = ({
|
||||
</form>
|
||||
|
||||
<div class="grid grid-cols-2 gap-2 sm:grid-cols-4">
|
||||
<div class="form-control">
|
||||
<label for="enable-allow-lan" class="label gap-2">
|
||||
<span class="label-text">{t('allowLan')}</span>
|
||||
</label>
|
||||
|
||||
<input
|
||||
id="enable-allow-lan"
|
||||
type="checkbox"
|
||||
class="toggle"
|
||||
checked={configsData()?.['allow-lan']}
|
||||
onChange={(e) =>
|
||||
void updateBackendConfigAPI(
|
||||
'allow-lan',
|
||||
e.target.checked,
|
||||
refetch,
|
||||
)
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div class="form-control">
|
||||
<label for="enable-tun-device" class="label gap-2">
|
||||
<span class="label-text">{t('enableTunDevice')}</span>
|
||||
|
Loading…
Reference in New Issue
Block a user