mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-04 15:58:49 +01:00
This commit is contained in:
parent
36a8d52f8f
commit
99e4614dc2
1 changed files with 2 additions and 2 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import {hasClosestByClassName} from "../util/hasClosest";
|
||||
import {getRandom, isMobile} from "../../util/functions";
|
||||
import {getRandom, isMobile, isTouchDevice} from "../../util/functions";
|
||||
import {hideElements} from "../ui/hideElements";
|
||||
import {uploadFiles} from "../upload";
|
||||
import {fetchPost} from "../../util/fetch";
|
||||
|
|
@ -52,7 +52,7 @@ export class Background {
|
|||
this.tagsElement = this.element.querySelector(".b3-chips") as HTMLElement;
|
||||
this.iconElement = this.element.querySelector(".protyle-background__icon") as HTMLElement;
|
||||
this.imgElement = this.element.firstElementChild.firstElementChild as HTMLImageElement;
|
||||
if (isMobile()) {
|
||||
if (isTouchDevice()) {
|
||||
this.imgElement.addEventListener("touchstart", (event: TouchEvent & { target: HTMLElement }) => {
|
||||
event.preventDefault();
|
||||
if (!this.element.firstElementChild.querySelector(".protyle-icons").classList.contains("fn__none")) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue