Skip to content

Commit f166db9

Browse files
scottnonnenberg-signallukas
andauthored
[#7242] Allow collapsing archive sidebar
Co-authored-by: lukas <[email protected]>
1 parent ef4cee6 commit f166db9

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

stylesheets/_modules.scss

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5767,6 +5767,10 @@ button.module-calling-participants-list__contact {
57675767
}
57685768
}
57695769
}
5770+
5771+
.NavSidebar--narrow & {
5772+
margin-inline-start: 0;
5773+
}
57705774
}
57715775

57725776
&__text {
@@ -5781,6 +5785,14 @@ button.module-calling-participants-list__contact {
57815785
@include mixins.dark-theme {
57825786
color: variables.$color-gray-05;
57835787
}
5788+
5789+
.NavSidebar--narrow & {
5790+
@include mixins.sr-only;
5791+
}
5792+
}
5793+
5794+
.NavSidebar--narrow & {
5795+
justify-content: center;
57845796
}
57855797
}
57865798

@@ -5861,6 +5873,10 @@ button.module-calling-participants-list__contact {
58615873
color: variables.$color-gray-25;
58625874
background-color: variables.$color-gray-75;
58635875
}
5876+
5877+
.NavSidebar--narrow & {
5878+
display: none;
5879+
}
58645880
}
58655881
.module-left-pane__no-search-results__unread-header {
58665882
margin-bottom: 50px;

ts/components/leftPane/LeftPaneArchiveHelper.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,11 @@ export class LeftPaneArchiveHelper extends LeftPaneHelper<LeftPaneArchivePropsTy
207207
);
208208
}
209209

210+
override requiresFullWidth(): boolean {
211+
const hasNoConversations = !this.#archivedConversations.length;
212+
return hasNoConversations;
213+
}
214+
210215
shouldRecomputeRowHeights(old: Readonly<LeftPaneArchivePropsType>): boolean {
211216
const hasSearchingChanged =
212217
'conversationResults' in old !== Boolean(this.#searchHelper);

0 commit comments

Comments
 (0)