mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-11 01:34:20 +01:00
💄 The menu no longer extends beyond the window
fix https://github.com/siyuan-note/siyuan/issues/15400
This commit is contained in:
parent
c7c0906082
commit
e828496584
2 changed files with 2 additions and 1 deletions
|
|
@ -169,7 +169,7 @@
|
|||
}
|
||||
|
||||
&__items {
|
||||
max-height: 80vh;
|
||||
max-height: min(80vh, calc(100vh - 20px - var(--b3-menu-position-top, 0px))); // 20px 是 .b3-menu 的上下 padding
|
||||
overflow: auto;
|
||||
padding: 0 8px;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -146,6 +146,7 @@ export class Menu {
|
|||
this.element.style.zIndex = (++window.siyuan.zIndex).toString();
|
||||
this.element.classList.remove("fn__none");
|
||||
setPosition(this.element, options.x - (options.isLeft ? this.element.clientWidth : 0), options.y, options.h, options.w);
|
||||
this.element.style.setProperty("--b3-menu-position-top", this.element.style.top);
|
||||
}
|
||||
|
||||
public fullscreen(position: "bottom" | "all" = "all") {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue