disable WebUI Option of WebGPU Mode (webgpu not supported yet)

This commit is contained in:
josc146 2023-11-08 23:05:59 +08:00
parent d249a4c29a
commit 0594290b92

View File

@ -442,15 +442,16 @@ const Configs: FC = observer(() => {
</div> </div>
<div className="flex flex-row-reverse sm:fixed bottom-2 right-2"> <div className="flex flex-row-reverse sm:fixed bottom-2 right-2">
<div className="flex gap-2"> <div className="flex gap-2">
<Checkbox className="select-none" {selectedConfig.modelParameters.device !== 'WebGPU'
size="large" label={t('Enable WebUI')} && <Checkbox className="select-none"
checked={selectedConfig.enableWebUI} size="large" label={t('Enable WebUI')}
onChange={(_, data) => { checked={selectedConfig.enableWebUI}
setSelectedConfig({ onChange={(_, data) => {
...selectedConfig, setSelectedConfig({
enableWebUI: data.checked as boolean ...selectedConfig,
}); enableWebUI: data.checked as boolean
}} /> });
}} />}
<RunButton onClickRun={onClickSave} /> <RunButton onClickRun={onClickSave} />
</div> </div>
</div> </div>