Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

settings: Convert `form` to `div` in `Full name` input.

Ganesh Pawar5b75fcd3e737
diff --git a/frontend_tests/puppeteer_tests/settings.ts b/frontend_tests/puppeteer_tests/settings.ts
index 1b4ec7910ce..5ca4307f133 100644
--- a/frontend_tests/puppeteer_tests/settings.ts
+++ b/frontend_tests/puppeteer_tests/settings.ts
@@ -40,7 +40,7 @@ async function test_change_full_name(page: Page): Promise<void> {
await common.clear_and_type(page, full_name_input_selector, "New name");
await page.click("#settings_content .profile-settings-form");
- await page.waitForSelector(".full-name-change-form .alert-success", {visible: true});
+ await page.waitForSelector(".full-name-change-container .alert-success", {visible: true});
await page.waitForFunction(
() => document.querySelector<HTMLInputElement>("#full_name")?.value === "New name",
);
diff --git a/static/js/settings_account.js b/static/js/settings_account.js
index 5ead762aff7..df7d36fd370 100644
--- a/static/js/settings_account.js
+++ b/static/js/settings_account.js
@@ -41,7 +41,7 @@ export function update_full_name(new_full_name) {
// Arguably, this should work more like how the `update_email`
// flow works, where we update the name in the modal on open,
// rather than updating it here, but this works.
- const $full_name_input = $(".full-name-change-form input[name='full_name']");
+ const $full_name_input = $(".full-name-change-container input[name='full_name']");
if ($full_name_input) {
$full_name_input.val(new_full_name);
}
diff --git a/static/styles/settings.css b/static/styles/settings.css
index bed99707777..b9d54762dd9 100644
--- a/static/styles/settings.css
+++ b/static/styles/settings.css
@@ -564,7 +564,7 @@ input[type="checkbox"] {
#profile-settings {
.custom-profile-fields-form .custom_user_field label,
- .full-name-change-form label,
+ .full-name-change-container label,
.timezone-setting-form label {
min-width: fit-content;
}
diff --git a/static/templates/settings/profile_settings.hbs b/static/templates/settings/profile_settings.hbs
index d4e47665b62..aac6ad0c998 100644
--- a/static/templates/settings/profile_settings.hbs
+++ b/static/templates/settings/profile_settings.hbs
@@ -3,7 +3,7 @@
<div class="profile-main-panel inline-block">
<h3 class="inline-block hide" id="user-profile-header">{{t "Profile" }}</h3>
<div id="user_details_section">
- <form class="form-horizontal full-name-change-form">
+ <div class="full-name-change-container">
<div class="input-group inline-block grid user-name-parent">
<div class="user-name-section inline-block">
<label for="full_name" class="title inline-block">{{t "Full name" }}</label>
@@ -17,7 +17,7 @@
</div>
</div>
</div>
- </form>
+ </div>
<form class="form-horizontal timezone-setting-form">
<div class="input-group grid">