mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 18:12:29 +08:00
fix(mobile): position of editing toolbar
This commit is contained in:
parent
7dfeb20678
commit
1d6e3af9aa
@ -31,7 +31,7 @@ const TPL = `\
|
|||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0;
|
bottom: calc(var(--tab-bar-height) + var(--launcher-pane-height) + var(--mobile-bottom-offset));
|
||||||
right: 0;
|
right: 0;
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
z-index: 500;
|
z-index: 500;
|
||||||
|
@ -230,14 +230,7 @@ export default class EditableTextTypeWidget extends AbstractTextTypeWidget {
|
|||||||
$classicToolbarWidget[0].appendChild(editor.ui.view.toolbar.element);
|
$classicToolbarWidget[0].appendChild(editor.ui.view.toolbar.element);
|
||||||
|
|
||||||
if (utils.isMobile()) {
|
if (utils.isMobile()) {
|
||||||
this.$editor.on("focus", (e) => {
|
$classicToolbarWidget.addClass("visible");
|
||||||
$classicToolbarWidget.addClass("visible");
|
|
||||||
});
|
|
||||||
|
|
||||||
// Hide the formatting toolbar
|
|
||||||
this.$editor.on("focusout", (e) => {
|
|
||||||
this.$editor[0].focus();
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,6 +45,8 @@ body {
|
|||||||
--native-titlebar-foreground: var(--main-text-color);
|
--native-titlebar-foreground: var(--main-text-color);
|
||||||
--native-titlebar-darwin-x-offset: 10;
|
--native-titlebar-darwin-x-offset: 10;
|
||||||
--native-titlebar-darwin-y-offset: 12;
|
--native-titlebar-darwin-y-offset: 12;
|
||||||
|
--launcher-pane-height: 53px;
|
||||||
|
--tab-bar-height: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
body.mobile .desktop-only {
|
body.mobile .desktop-only {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user