Skip to content

Commit

Permalink
🐛 fix: Setting form submit
Browse files Browse the repository at this point in the history
  • Loading branch information
kaalibro committed Dec 26, 2023
1 parent 453670c commit 340ca92
Show file tree
Hide file tree
Showing 6 changed files with 63 additions and 64 deletions.
121 changes: 58 additions & 63 deletions javascript/main.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/features/Setting/Form/Appearance.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ const SettingForm = memo(() => {

return (
<Form
id="theme_settings"
initialValues={setting}
items={[theme]}
onFinish={onFinish}
Expand Down
1 change: 1 addition & 0 deletions src/features/Setting/Form/Experimental.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ const SettingForm = memo(() => {

return (
<Form
id="theme_settings"
initialValues={setting}
items={[experimental, promptTextarea]}
onFinish={onFinish}
Expand Down
2 changes: 1 addition & 1 deletion src/features/Setting/Form/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const Footer = memo(() => {
{t('setting.button.reset')}
</Button>
</Popconfirm>
<Button htmlType="submit" style={buttonStyle} type="primary">
<Button form="theme_settings" htmlType="submit" style={buttonStyle} type="primary">
{t('setting.button.submit')}
</Button>
</Flexbox>
Expand Down
1 change: 1 addition & 0 deletions src/features/Setting/Form/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ const SettingForm = memo(() => {

return (
<Form
id="theme_settings"
initialValues={setting}
items={[layout, promptTextarea]}
onFinish={onFinish}
Expand Down
1 change: 1 addition & 0 deletions src/features/Setting/Form/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ const SettingForm = memo(() => {

return (
<Form
id="theme_settings"
initialValues={setting}
items={[quickSettingSidebar, extraNetworkSidebar]}
onFinish={onFinish}
Expand Down

0 comments on commit 340ca92

Please sign in to comment.