Skip to content

Commit d444241

Browse files
committed
Fix position of search bar
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
1 parent 4de981b commit d444241

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

core/src/components/HeaderMenu.vue

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,14 @@ export default {
163163
</script>
164164

165165
<style lang="scss" scoped>
166+
/* Hack when there is 4 elements in the right header, display the
167+
carret more to the left. */
168+
#unified-search:first-child:nth-last-child(4),
169+
#unified-search:first-child:nth-last-child(4) ~ #unified-search {
170+
.header-menu__carret {
171+
right: 175px;
172+
}
173+
}
166174
.header-menu {
167175
&__trigger {
168176
display: flex;
@@ -184,10 +192,10 @@ export default {
184192
}
185193
186194
&__wrapper {
187-
position: absolute;
195+
position: fixed;
188196
z-index: 2000;
189197
top: 50px;
190-
right: -150px;
198+
right: 0;
191199
box-sizing: border-box;
192200
margin: 0;
193201
border-radius: 0 0 var(--border-radius) var(--border-radius);
@@ -198,7 +206,7 @@ export default {
198206
199207
&__carret {
200208
position: absolute;
201-
right: 165px;
209+
right: 128px;
202210
bottom: 100%;
203211
width: 0;
204212
height: 0;
@@ -211,7 +219,7 @@ export default {
211219
&__content {
212220
overflow: auto;
213221
width: 350px;
214-
max-width: 350px;
222+
max-width: 100vw;
215223
min-height: calc(44px * 1.5);
216224
max-height: calc(100vh - 50px * 2);
217225
}

0 commit comments

Comments
 (0)