mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-22 06:54:08 +01:00
PWA support (desktop & mobile) (#8012)
* 🎨 Improve return to feature of the auth page * 🎨 PWA support * Update manifest.webmanifest * 🎨 add `service-worker.js` * Update service-worker.js * Update service-worker.js * Update service-worker.js
This commit is contained in:
parent
e1d3789ced
commit
93e4bb1adf
17 changed files with 816 additions and 30 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import {BlockPanel} from "./Panel";
|
||||
import {hasClosestBlock, hasClosestByAttribute, hasClosestByClassName} from "../protyle/util/hasClosest";
|
||||
import {fetchSyncPost} from "../util/fetch";
|
||||
import {getIdFromSiyuanUrl} from "../util/functions";
|
||||
import {hideTooltip, showTooltip} from "../dialog/tooltip";
|
||||
|
||||
let popoverTargetElement: HTMLElement;
|
||||
|
|
@ -199,7 +200,7 @@ export const showPopover = async () => {
|
|||
}
|
||||
} else if (popoverTargetElement.getAttribute("data-type")?.split(" ").includes("a")) {
|
||||
// 以思源协议开头的链接
|
||||
ids = [popoverTargetElement.getAttribute("data-href").substr(16, 22)];
|
||||
ids = [getIdFromSiyuanUrl(popoverTargetElement.getAttribute("data-href"))];
|
||||
} else {
|
||||
// pdf
|
||||
let targetId;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue