mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-02-28 05:32:52 +00:00
This commit is contained in:
@@ -26,8 +26,10 @@ export const openLink = (protyle: IProtyle, aLink: string, event?: MouseEvent, c
|
||||
/// #else
|
||||
if (isLocalPath(linkAddress)) {
|
||||
if (Constants.SIYUAN_ASSETS_EXTS.includes(pathPosix().extname(linkAddress)) &&
|
||||
(!linkAddress.endsWith(".pdf") ||
|
||||
(linkAddress.endsWith(".pdf") && !linkAddress.startsWith("file://")))
|
||||
(
|
||||
!linkAddress.endsWith(".pdf") ||
|
||||
(linkAddress.endsWith(".pdf") && linkAddress.startsWith("assets/"))
|
||||
)
|
||||
) {
|
||||
if (event && event.altKey) {
|
||||
openAsset(protyle.app, linkAddress, pdfParams);
|
||||
|
||||
Reference in New Issue
Block a user