mirror of
https://github.com/sipeed/NanoKVM-USB.git
synced 2026-09-12 22:49:56 -05:00
optimize(desktop): use same style with browser
This commit is contained in:
@@ -14,7 +14,6 @@ export const DeviceModal = (): ReactElement => {
|
||||
<Modal open={true} title={t('modal.title')} footer={null} closable={false} destroyOnClose>
|
||||
<div className="flex flex-col items-center justify-center space-y-5 py-10">
|
||||
<Video setErrMsg={setErrMsg} />
|
||||
|
||||
<SerialPort setErrMsg={setErrMsg} />
|
||||
|
||||
{errMsg && <span className="text-xs text-red-500">{errMsg}</span>}
|
||||
|
||||
@@ -116,10 +116,10 @@ export const SerialPort = ({ setErrMsg }: SerialPortProps): ReactElement => {
|
||||
}
|
||||
|
||||
return (
|
||||
<Space direction="vertical" size="small" style={{ width: '100%', alignItems: 'center' }}>
|
||||
<Space direction="vertical" size="small" className="p-2">
|
||||
<Select
|
||||
value={serialPort || undefined}
|
||||
style={{ width: 280 }}
|
||||
className="w-[250px]"
|
||||
options={options}
|
||||
loading={serialPortState === 'connecting'}
|
||||
status={isFailed ? 'error' : undefined}
|
||||
@@ -129,7 +129,7 @@ export const SerialPort = ({ setErrMsg }: SerialPortProps): ReactElement => {
|
||||
/>
|
||||
<Select
|
||||
value={baudRate}
|
||||
style={{ width: 280 }}
|
||||
className="w-[250px]"
|
||||
options={baudRateOptions}
|
||||
placeholder={t('modal.selectBaudRate')}
|
||||
onChange={handleBaudRateChange}
|
||||
|
||||
@@ -104,7 +104,7 @@ export const Video = ({ setErrMsg }: VideoProps): ReactElement => {
|
||||
return (
|
||||
<Select
|
||||
value={videoDeviceId || undefined}
|
||||
style={{ width: 280 }}
|
||||
style={{ width: 250 }}
|
||||
options={devices}
|
||||
fieldNames={{
|
||||
value: 'videoId',
|
||||
|
||||
Reference in New Issue
Block a user