mirror of
https://github.com/Yidadaa/ChatGPT-Next-Web.git
synced 2025-09-06 16:06:59 +08:00
feat: 1)add font source 2)add validator in ListItem 3)settings page ui optiminize
This commit is contained in:
@@ -153,6 +153,16 @@ export default function ModelSetting(props: {
|
||||
title={Locale.Settings.InputTemplate.Title}
|
||||
subTitle={Locale.Settings.InputTemplate.SubTitle}
|
||||
nextline={isMobileScreen}
|
||||
validator={(v: string) => {
|
||||
if (!v.includes("{{input}}")) {
|
||||
return {
|
||||
error: true,
|
||||
message: Locale.Settings.InputTemplate.Error,
|
||||
};
|
||||
}
|
||||
|
||||
return { error: false };
|
||||
}}
|
||||
>
|
||||
<Input
|
||||
type="text"
|
||||
@@ -160,7 +170,6 @@ export default function ModelSetting(props: {
|
||||
onChange={(e = "") =>
|
||||
props.updateConfig((config) => (config.template = e))
|
||||
}
|
||||
className="text-center"
|
||||
></Input>
|
||||
</ListItem>
|
||||
</>
|
||||
|
Reference in New Issue
Block a user