Skip to content

Commit

Permalink
[web] Fix modal styles
Browse files Browse the repository at this point in the history
Summary:
issue: [[https://linear.app/comm/issue/ENG-8679/scroll-in-pinned-messages-on-web-seems-to-be-broken | ENG-8679]]
The issue was that the pinned messages modal div was not scrollable, but fixing this revealed another issue: contents of Modal were wrapped by `modalContentContainer` which allowed its content to extend it.

Test Plan:
Checked ALL places where Modal component is used. Checked that after these changes they all work correctly. Here are modals that got changed:
{F2568094}

{F2568093}

{F2568092}

{F2568090}

{F2568086}

Here is before and after for the search component (using prod and dev):
{F2568087}

Reviewers: tomek, ashoat

Reviewed By: tomek

Differential Revision: https://phab.comm.dev/D13191
  • Loading branch information
InkaAlicja committed Aug 28, 2024
1 parent 062159e commit 98a7d20
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions web/modals/chat/message-reactions-modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ div.modalContentContainer {
flex-direction: column;
font-size: var(--l-font-18);
overflow-y: auto;
max-height: 100%;
}

div.userRowContainer {
Expand Down
2 changes: 2 additions & 0 deletions web/modals/chat/pinned-messages-modal.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
.container {
height: 80vh;
overflow: scroll;
max-height: 100%;
}

hr.separator {
Expand Down
1 change: 1 addition & 0 deletions web/modals/modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ h2.subtitle {

.modalContentContainer {
padding: 16px 32px 24px;
overflow: hidden;
}

.buttonContainer {
Expand Down
1 change: 1 addition & 0 deletions web/modals/search-modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
display: flex;
flex-direction: column;
overflow: hidden;
max-height: 100%;
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ div.container {
justify-content: flex-start;
height: 80vh;
padding-top: 16px;
max-height: 100%;
}

div.mediaContainer {
Expand Down
2 changes: 2 additions & 0 deletions web/modals/threads/notifications/notifications-modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ div.container {
row-gap: 20px;
min-width: 343px;
width: min-content;
overflow: auto;
max-height: 100%;
}

p.notice {
Expand Down
1 change: 1 addition & 0 deletions web/modals/threads/sidebars/sidebars-modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ div.sidebarListContainer {
flex-direction: column;
line-height: var(--line-height-text);
height: 80vh;
overflow: hidden;
}

div.sidebarList {
Expand Down

0 comments on commit 98a7d20

Please sign in to comment.