Skip to content

Commit 8896500

Browse files
committed
moved and refactored the burger menue for the sidebar
Signed-off-by: Kai Wagner <kai.wagner@percona.com>
1 parent 2077e10 commit 8896500

7 files changed

Lines changed: 4 additions & 64 deletions

File tree

app/assets/stylesheets/components/navigation.css

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@
2222
position: relative;
2323
}
2424

25+
body.has-sidebar .nav-burger {
26+
display: inline-flex;
27+
}
28+
2529
.nav-burger {
2630
display: none;
2731
align-items: center;
@@ -351,10 +355,6 @@
351355
margin-left: 0;
352356
}
353357

354-
body.has-sidebar .nav-burger {
355-
display: inline-flex;
356-
}
357-
358358
.mobile-nav-dropdown {
359359
display: inline-flex;
360360
}

app/assets/stylesheets/components/sidebar.css

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -14,51 +14,6 @@
1414
justify-content: center;
1515
}
1616

17-
.topics-table th.topic-title .sidebar-burger-button,
18-
.topic-title-with-star .sidebar-burger-button {
19-
display: none;
20-
margin-right: var(--spacing-2);
21-
}
22-
23-
.sidebar-toggle-bar {
24-
display: flex;
25-
justify-content: flex-end;
26-
padding: var(--spacing-2) var(--spacing-3);
27-
position: sticky;
28-
top: var(--nav-height);
29-
z-index: 10;
30-
background: var(--color-bg-sidebar);
31-
border-bottom: var(--border-width) solid var(--color-border);
32-
}
33-
34-
.sidebar-burger-button {
35-
border: none;
36-
background: var(--color-bg-card);
37-
color: var(--color-text-secondary);
38-
width: 32px;
39-
height: 32px;
40-
border-radius: 999px;
41-
box-shadow: var(--shadow-sm);
42-
cursor: pointer;
43-
display: inline-flex;
44-
align-items: center;
45-
justify-content: center;
46-
font-size: 14px;
47-
transition: transform var(--transition-fast), background-color var(--transition-fast);
48-
z-index: 1;
49-
}
50-
51-
.sidebar-burger-button:hover {
52-
background: var(--color-bg-hover);
53-
transform: scale(1.05);
54-
}
55-
56-
57-
@media (max-width: 900px) {
58-
.sidebar-toggle-bar {
59-
display: none;
60-
}
61-
}
6217

6318
@media (max-width: 720px) {
6419
.layout-sidebar-resizer {

app/assets/stylesheets/components/topics.css

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -86,10 +86,6 @@
8686
font-size: var(--font-size-base);
8787
}
8888

89-
body.sidebar-collapsed .topics-table th.topic-title .sidebar-burger-button {
90-
display: inline-flex;
91-
}
92-
9389
.topics-table {
9490
& table {
9591
width: 100%;

app/assets/stylesheets/layouts/topic-view.css

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@
1313
margin-top: var(--spacing-4);
1414
}
1515

16-
body.sidebar-collapsed .topic-title-with-star .sidebar-burger-button {
17-
display: inline-flex;
18-
}
19-
2016
.topic-title-section {
2117
margin-bottom: var(--spacing-5);
2218

app/views/layouts/application.html.slim

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,9 +132,6 @@ html data-theme="light"
132132
- if content_for?(:sidebar)
133133
.page-layout.with-sidebar data-sidebar-target="layout"
134134
.layout-sidebar#layout-sidebar data-sidebar-target="sidebar" data-action="click->sidebar#closeOnNavigate"
135-
.sidebar-toggle-bar
136-
button.sidebar-burger-button type="button" aria-label="Toggle sidebar" data-action="click->sidebar#toggle"
137-
i.fa-solid.fa-bars aria-hidden="true"
138135
= yield :sidebar
139136
.layout-sidebar-resizer data-sidebar-target="resizer" role="separator" aria-orientation="vertical" aria-label="Resize sidebar" data-action="mousedown->sidebar#startResize touchstart->sidebar#startResize"
140137
.layout-sidebar-overlay data-sidebar-target="overlay" data-action="click->sidebar#closeMobile"

app/views/topics/index.html.slim

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
thead
88
tr
99
th.topic-title
10-
button.sidebar-burger-button type="button" aria-label="Expand sidebar" data-action="click->sidebar#toggle"
11-
i.fa-solid.fa-bars aria-hidden="true"
1210
| Topic
1311
th.mailing-lists-header Mailing Lists
1412
th.activity-header Activity

app/views/topics/show.html.slim

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,6 @@
169169
.topic-header
170170
.topic-title-section
171171
.topic-title-with-star
172-
button.sidebar-burger-button type="button" aria-label="Expand sidebar" data-action="click->sidebar#toggle"
173-
i.fa-solid.fa-bars aria-hidden="true"
174172
- if user_signed_in?
175173
= render "star_button", topic: @topic, starred: @is_starred
176174
h1 = @topic.title

0 commit comments

Comments
 (0)