Update Add Link to Existing File and Open.md

This commit is contained in:
zsviczian
2022-03-20 21:24:46 +01:00
committed by GitHub
parent d4e1737758
commit a8d9931477

View File

@@ -45,7 +45,7 @@ ea.style.strokeColor = "rgba(70,130,180,0.05)"
ea.style.strokeWidth = 2;
ea.style.roughness = 0;
if(elements.lenght===1 && elements[0].type !== "text") {
if(elements.length===1 && elements[0].type !== "text") {
ea.copyViewElementsToEAforEditing(elements);
ea.getElements()[0].link = link;
} else {
@@ -62,4 +62,4 @@ if(openInCurrentPane) {
app.workspace.openLinkText(file.path,ea.targetView.file.path,false);
return;
}
ea.openFileInNewOrAdjacentLeaf(file);
ea.openFileInNewOrAdjacentLeaf(file);