fix(whiteboard): iOS callout issues

This commit is contained in:
Peng Xiao
2022-11-09 23:07:25 +08:00
committed by Tienson Qin
parent 1a86daa53f
commit 1d83f00017
4 changed files with 15 additions and 1 deletions

View File

@@ -25,7 +25,7 @@ const HistoryStack = observer(function HistoryStack() {
}, [])
React.useEffect(() => {
requestIdleCallback(() => {
requestAnimationFrame(() => {
anchorRef.current
?.querySelector(`[data-item-index="${app.history.pointer}"]`)
?.scrollIntoView()

View File

@@ -878,6 +878,7 @@ export class LogseqPortalShape extends TLBoxShape<LogseqPortalShapeProps> {
>
{isBinding && <BindingIndicator mode="html" strokeWidth={strokeWidth} size={size} />}
<div
data-inner-events={!tlEventsEnabled}
onWheelCapture={stop}
onPointerDown={stop}
onPointerUp={stop}

View File

@@ -25,6 +25,11 @@
--shadow-large: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
backface-visibility: hidden;
* {
-webkit-touch-callout: none;
-webkit-user-drag: none;
}
}
.dark-theme,
@@ -651,6 +656,7 @@ button.tl-select-input-trigger {
padding: 8px 16px;
cursor: pointer;
gap: 0.5em;
user-select: none;
&[data-focused='true'] {
background-color: var(--ls-menu-hover-color, #f4f5f7);
@@ -676,6 +682,10 @@ button.tl-select-input-trigger {
opacity: 0.5;
}
[data-inner-events=false] * {
user-select: none;
}
.tl-logseq-portal-container {
@apply flex flex-col rounded-lg absolute;

View File

@@ -119,6 +119,9 @@ const tlcss = css`
cursor: var(--tl-cursor) !important;
box-sizing: border-box;
color: var(--tl-foreground);
-webkit-user-select: none;
-webkit-touch-callout: none;
-webkit-user-drag: none;
}
.tl-overlay {