fix(ui): tippy menu styles too broad, affecting switch in PR review (#10969)

The custom styles for tippy-enabled menus had too broad selectors, conflicting with styles of other .item elements in tippy boxes.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/10969
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
Co-authored-by: 0ko <0ko@noreply.codeberg.org>
Co-committed-by: 0ko <0ko@noreply.codeberg.org>
This commit is contained in:
0ko 2026-01-22 23:38:09 +01:00 committed by Beowulf
parent 125a621f79
commit 2f8ae54b0f
3 changed files with 80 additions and 38 deletions

View file

@ -1,3 +1,8 @@
/* Copyright 2017-2022 atomiks. All rights reserved.
* Copyright 2022-2024 The Gitea Authors. All rights reserved.
* Copyright 2024 The Forgejo Authors. All rights reserved.
* SPDX-License-Identifier: MIT */
/* styles are based on node_modules/tippy.js/dist/tippy.css */
/* class to hide tippy target elements on page load */
@ -73,7 +78,9 @@
fill: var(--color-menu);
}
.tippy-box[data-theme="menu"] .item {
/* Ellipsis, overflow menus */
.tippy-box[data-theme="menu"] .tippy-target > .item {
display: flex;
align-items: center;
padding: 9px 18px;
@ -82,11 +89,11 @@
gap: 10px;
}
.tippy-box[data-theme="menu"] .item:hover {
.tippy-box[data-theme="menu"] .tippy-target > .item:hover {
background: var(--color-hover);
}
.tippy-box[data-theme="menu"] .item:focus {
.tippy-box[data-theme="menu"] .tippy-target > .item:focus {
background: var(--color-active);
}