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.

modals: Rename modal__body -> modal__content in user profile modal.

Sayam Samald03a0fb38f58
diff --git a/web/src/user_profile.ts b/web/src/user_profile.ts
index 5df5bfd3dc5..a8fe717e1fe 100644
--- a/web/src/user_profile.ts
+++ b/web/src/user_profile.ts
@@ -408,7 +408,7 @@ function render_user_stream_list(streams: StreamSubscription[], user: User): voi
return item?.name.toLocaleLowerCase().includes(value);
},
},
- $simplebar_container: $("#user-profile-modal .modal__body"),
+ $simplebar_container: $("#user-profile-modal .modal__content"),
});
}
@@ -453,7 +453,7 @@ function render_user_group_list(groups: UserGroup[], user: User): void {
return item?.name.toLocaleLowerCase().includes(value);
},
},
- $simplebar_container: $("#user-profile-modal .modal__body"),
+ $simplebar_container: $("#user-profile-modal .modal__content"),
});
}
@@ -461,7 +461,7 @@ function render_manage_profile_content(user: User): void {
// Since we want the height of the profile modal to remain consistent when switching tabs,
// we need to restrict the height of the main body. This will ensure that the footer of
// the "Manage User" tab can adjust within the provided height without expanding the modal.
- $("#user-profile-modal .modal__body").addClass("modal__body__manage_profile_height");
+ $("#user-profile-modal .modal__content").addClass("modal__content__manage_profile_height");
$("#user-profile-modal .manage-profile-tab-footer").addClass("modal__footer_wrapper");
const $container = $("#manage-profile-tab");
$container.empty();
@@ -775,7 +775,9 @@ export function show_user_profile(user: User, default_tab_key = "profile-tab"):
$(".tabcontent").hide();
$(`#${CSS.escape(key)}`).show();
$("#user-profile-modal .modal__footer").hide();
- $("#user-profile-modal .modal__body").removeClass("modal__body__manage_profile_height");
+ $("#user-profile-modal .modal__content").removeClass(
+ "modal__content__manage_profile_height",
+ );
$("#user-profile-modal .manage-profile-tab-footer").removeClass(
"modal__footer_wrapper",
);
diff --git a/web/styles/popovers.css b/web/styles/popovers.css
index 8f1d460105d..1d1ae24c112 100644
--- a/web/styles/popovers.css
+++ b/web/styles/popovers.css
@@ -417,7 +417,7 @@ ul.popover-group-menu-member-list {
}
#user-profile-modal {
- .modal__body {
+ .modal__content {
box-sizing: border-box;
height: var(--user-profile-modal-body-height);
padding-left: 16px;
@@ -430,7 +430,7 @@ ul.popover-group-menu-member-list {
the height of the main body to 52vh - 1px (border radius of the footer)
and add a footer of 8vh.
*/
- &.modal__body__manage_profile_height {
+ &.modal__content__manage_profile_height {
height: calc(52vh - 1px);
}
}
diff --git a/web/templates/user_profile_modal.hbs b/web/templates/user_profile_modal.hbs
index 26b87d9c570..99f0c459ca0 100644
--- a/web/templates/user_profile_modal.hbs
+++ b/web/templates/user_profile_modal.hbs
@@ -40,7 +40,7 @@
{{> components/icon_button icon="close" intent="neutral" custom_classes="modal__close" aria-label=(t 'Close modal') data-micromodal-close=true }}
</div>
<div id="tab-toggle"></div>
- <main class="modal__body" id="body" data-simplebar data-simplebar-tab-index="-1" data-simplebar-auto-hide="false">
+ <main class="modal__content" data-simplebar data-simplebar-tab-index="-1" data-simplebar-auto-hide="false">
<div class="tab-data">
<div class="tabcontent active" id="profile-tab">
<div class="top">