mirror of
https://github.com/woodchen-ink/clash-and-dashboard.git
synced 2025-07-18 05:51:56 +08:00
Chore: disable change port on clashx
This commit is contained in:
parent
3acae645af
commit
f730bc7380
@ -10,6 +10,7 @@ interface InputProps extends BaseComponentProps {
|
||||
inside?: boolean
|
||||
autoFocus?: boolean
|
||||
type?: string
|
||||
disabled?: boolean
|
||||
onChange?: (value: string, event?: React.ChangeEvent<HTMLInputElement>) => void
|
||||
onBlur?: (event?: React.FocusEvent<HTMLInputElement>) => void
|
||||
}
|
||||
@ -23,6 +24,7 @@ export function Input (props: InputProps) {
|
||||
inside = false,
|
||||
autoFocus = false,
|
||||
type = 'text',
|
||||
disabled = false,
|
||||
onChange = noop,
|
||||
onBlur = noop
|
||||
} = props
|
||||
@ -30,6 +32,7 @@ export function Input (props: InputProps) {
|
||||
|
||||
return (
|
||||
<input
|
||||
disabled={disabled}
|
||||
className={classname}
|
||||
style={style}
|
||||
value={value}
|
||||
|
@ -152,6 +152,7 @@ export default function Settings () {
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<Input
|
||||
disabled={clashXData.isClashX}
|
||||
value={info.socks5ProxyPort}
|
||||
onChange={socks5ProxyPort => set('socks5ProxyPort', +socks5ProxyPort)}
|
||||
onBlur={handleSocksPortSave}
|
||||
@ -166,6 +167,7 @@ export default function Settings () {
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<Input
|
||||
disabled={clashXData.isClashX}
|
||||
value={info.httpProxyPort}
|
||||
onChange={httpProxyPort => set('httpProxyPort', +httpProxyPort)}
|
||||
onBlur={handleHttpPortSave}
|
||||
|
Loading…
x
Reference in New Issue
Block a user