Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3178345
D3928.id12275.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
6 KB
Referenced Files
None
Subscribers
None
D3928.id12275.diff
View Options
diff --git a/web/modals/threads/thread-settings-delete-tab.react.js b/web/modals/threads/thread-settings-delete-tab.react.js
--- a/web/modals/threads/thread-settings-delete-tab.react.js
+++ b/web/modals/threads/thread-settings-delete-tab.react.js
@@ -76,7 +76,7 @@
);
return (
- <>
+ <form method="POST">
<div>
<p className={css.italic}>
Your thread will be permanently deleted. There is no way to reverse
@@ -102,7 +102,7 @@
<Button onClick={onDelete} variant="danger" disabled={inputDisabled}>
Delete
</Button>
- </>
+ </form>
);
}
diff --git a/web/modals/threads/thread-settings-general-tab.react.js b/web/modals/threads/thread-settings-general-tab.react.js
--- a/web/modals/threads/thread-settings-general-tab.react.js
+++ b/web/modals/threads/thread-settings-general-tab.react.js
@@ -130,7 +130,7 @@
);
return (
- <div>
+ <form method="POST">
<div>
<div className={css.form_title}>Thread name</div>
<div className={css.form_content}>
@@ -170,7 +170,7 @@
>
Save
</Button>
- </div>
+ </form>
);
}
diff --git a/web/modals/threads/thread-settings-modal.react.js b/web/modals/threads/thread-settings-modal.react.js
--- a/web/modals/threads/thread-settings-modal.react.js
+++ b/web/modals/threads/thread-settings-modal.react.js
@@ -165,15 +165,10 @@
icon="settings"
>
<div className={css.modal_body}>
- <form method="POST">
- <Tabs.Container
- activeTab={currentTabType}
- setTab={setCurrentTabType}
- >
- {tabs}
- </Tabs.Container>
- <div className={css.modal_form_error}>{errorMessage}</div>
- </form>
+ <Tabs.Container activeTab={currentTabType} setTab={setCurrentTabType}>
+ {tabs}
+ </Tabs.Container>
+ <div className={css.modal_form_error}>{errorMessage}</div>
</div>
</Modal>
);
diff --git a/web/modals/threads/thread-settings-privacy-tab.react.js b/web/modals/threads/thread-settings-privacy-tab.react.js
--- a/web/modals/threads/thread-settings-privacy-tab.react.js
+++ b/web/modals/threads/thread-settings-privacy-tab.react.js
@@ -99,65 +99,67 @@
);
return (
- <div className={css.edit_thread_privacy_container}>
- <div className={css['modal-radio-selector']}>
- <div className={css.form_title}>Thread type</div>
- <div className={css.form_enum_selector}>
- <div className={css.form_enum_container}>
- <input
- type="radio"
- name="edit-thread-type"
- id="edit-thread-open"
- value={COMMUNITY_OPEN_SUBTHREAD}
- checked={
- (queuedChanges.type ?? threadInfo.type) ===
- COMMUNITY_OPEN_SUBTHREAD
- }
- onChange={onChangeThreadType}
- disabled={inputDisabled}
- />
- <div className={css.form_enum_option}>
- <label htmlFor="edit-thread-open">
- Open
- <span className={css.form_enum_description}>
- {threadTypeDescriptions[COMMUNITY_OPEN_SUBTHREAD]}
- </span>
- </label>
+ <form method="POST">
+ <div className={css.edit_thread_privacy_container}>
+ <div className={css['modal-radio-selector']}>
+ <div className={css.form_title}>Thread type</div>
+ <div className={css.form_enum_selector}>
+ <div className={css.form_enum_container}>
+ <input
+ type="radio"
+ name="edit-thread-type"
+ id="edit-thread-open"
+ value={COMMUNITY_OPEN_SUBTHREAD}
+ checked={
+ (queuedChanges.type ?? threadInfo.type) ===
+ COMMUNITY_OPEN_SUBTHREAD
+ }
+ onChange={onChangeThreadType}
+ disabled={inputDisabled}
+ />
+ <div className={css.form_enum_option}>
+ <label htmlFor="edit-thread-open">
+ Open
+ <span className={css.form_enum_description}>
+ {threadTypeDescriptions[COMMUNITY_OPEN_SUBTHREAD]}
+ </span>
+ </label>
+ </div>
</div>
- </div>
- <div className={css.form_enum_container}>
- <input
- type="radio"
- name="edit-thread-type"
- id="edit-thread-closed"
- value={COMMUNITY_SECRET_SUBTHREAD}
- checked={
- (queuedChanges.type ?? threadInfo.type) ===
- COMMUNITY_SECRET_SUBTHREAD
- }
- onChange={onChangeThreadType}
- disabled={inputDisabled}
- />
- <div className={css.form_enum_option}>
- <label htmlFor="edit-thread-closed">
- Secret
- <span className={css.form_enum_description}>
- {threadTypeDescriptions[COMMUNITY_SECRET_SUBTHREAD]}
- </span>
- </label>
+ <div className={css.form_enum_container}>
+ <input
+ type="radio"
+ name="edit-thread-type"
+ id="edit-thread-closed"
+ value={COMMUNITY_SECRET_SUBTHREAD}
+ checked={
+ (queuedChanges.type ?? threadInfo.type) ===
+ COMMUNITY_SECRET_SUBTHREAD
+ }
+ onChange={onChangeThreadType}
+ disabled={inputDisabled}
+ />
+ <div className={css.form_enum_option}>
+ <label htmlFor="edit-thread-closed">
+ Secret
+ <span className={css.form_enum_description}>
+ {threadTypeDescriptions[COMMUNITY_SECRET_SUBTHREAD]}
+ </span>
+ </label>
+ </div>
</div>
</div>
</div>
+ <Button
+ type="submit"
+ onClick={onSubmit}
+ disabled={inputDisabled || !changeQueued}
+ className={css.save_button}
+ >
+ Save
+ </Button>
</div>
- <Button
- type="submit"
- onClick={onSubmit}
- disabled={inputDisabled || !changeQueued}
- className={css.save_button}
- >
- Save
- </Button>
- </div>
+ </form>
);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 9, 1:34 AM (21 h, 43 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2446800
Default Alt Text
D3928.id12275.diff (6 KB)
Attached To
Mode
D3928: [web] Push `<form>` tag down from `ThreadSettingsModal` to child "Tab" components
Attached
Detach File
Event Timeline
Log In to Comment