Skip to content

Commit

Permalink
Исправляет стили выпадающего меню (doka-guide#1306)
Browse files Browse the repository at this point in the history
* Показывает хоткей начиная с 1024px

* Устраняет наползание меню на заголовок

* Подстраивает иконку закрытия поиска

* Учитывает сжатие хэдера

* Ровняет хоткеи наждачкой

---------

Co-authored-by: Svetlana Korobtseva <[email protected]>
  • Loading branch information
vitya-ne and skorobaeus committed Sep 30, 2024
1 parent 929e69d commit eea70ea
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/styles/blocks/header-button.css
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@

@media (width >= 1366px) {
.header-button-icon--close {
width: 37px;
height: 37px;
width: 36px;
height: 36px;
}
}

Expand Down
29 changes: 28 additions & 1 deletion src/styles/blocks/header.css
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,36 @@
@media (width >= 1024px) {
.header--open .header__menu {
position: fixed;
top: 75px;
}

.header--open .header__controls--shrink + .header__menu {
top: 55px;
}
}

@media (width >= 1366px) {
.header--open .header__menu {
position: fixed;
top: 76px;
}

.header--open .header__controls--shrink + .header__menu {
top: 56px;
}
}

@media (width >= 1680px) {
.header--open .header__menu {
position: fixed;
top: 83px;
}

.header--open .header__controls--shrink + .header__menu {
top: 63px;
}
}

/* содержимое главного меню (без дропдауна) */
.header__controls {
--letter-spacing: -0.06em;
Expand Down Expand Up @@ -100,6 +126,7 @@

.header--open .header__controls {
background-color: var(--color-background);
transition: none;
}

.header__divider {
Expand All @@ -123,7 +150,7 @@
}

@media (width >= 1680px) {
.header__controls .header__search {
.header__controls .header__search, .header__controls .header__buttons {
position: relative;
top: -2px;
}
Expand Down
2 changes: 1 addition & 1 deletion src/styles/blocks/hotkey.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}
}

@media not all and (width >= 768px) {
@media not all and (width >= 1024px) {
.hotkey {
display: none;
}
Expand Down

0 comments on commit eea70ea

Please sign in to comment.