frontend: one header menu for the links, user, settings and alerts popovers
Part of the unification order in the UI sweep issue (step c). The four header menus each kept their own open state, dismiss hook and a copy of the popover CSS, and the copies had drifted (offset, padding, fade-in). A shared HeaderMenu now owns the state, the dismiss rules and the popover look; each menu supplies its button and its rows. The settings popover moves 0.15em lower and the settings and alerts popovers gain the fade-in.
This commit is contained in:
parent
25965341e0
commit
6f73bf0c55
1 changed files with 310 additions and 365 deletions
|
|
@ -1,8 +1,6 @@
|
|||
/* <AlertsMenu> — the header bell (the shared icon button) with a count badge,
|
||||
and a popover shaped like the links menu's. */
|
||||
.alerts-menu {
|
||||
position: relative;
|
||||
}
|
||||
and the shared `HeaderMenu` popover for the list. */
|
||||
@import "@hive/shared/header-menu.css";
|
||||
.alerts-menu .ui-icon-button {
|
||||
position: relative;
|
||||
color: var(--red);
|
||||
|
|
@ -21,23 +19,6 @@
|
|||
line-height: 1.2;
|
||||
text-align: center;
|
||||
}
|
||||
.alerts-menu-popover {
|
||||
position: absolute;
|
||||
top: calc(100% + 0.4em);
|
||||
right: 0;
|
||||
z-index: var(--z-popover);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.4em;
|
||||
width: min(26em, calc(100vw - 2em));
|
||||
max-height: 70vh;
|
||||
padding: 0.4em;
|
||||
overflow-y: auto;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-md);
|
||||
background: var(--bg-elev);
|
||||
box-shadow: var(--shadow-pop);
|
||||
}
|
||||
.alerts-menu-list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
|
@ -65,13 +46,3 @@
|
|||
flex-basis: 100%;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
.alerts-menu-link {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-height: 2.75em;
|
||||
padding: 0.4em 0.6em;
|
||||
border-radius: var(--radius-sm);
|
||||
}
|
||||
.alerts-menu-link:hover {
|
||||
background: var(--bg);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue