@quartz-community/obsidian-plugin-excalidraw 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/dist/components/index.js +0 -2
- package/dist/components/index.js.map +1 -1
- package/dist/index.js +8 -4
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -488,8 +488,6 @@ var require_lz_string = __commonJS({
|
|
|
488
488
|
}
|
|
489
489
|
}
|
|
490
490
|
});
|
|
491
|
-
|
|
492
|
-
// node_modules/@quartz-community/utils/dist/path.js
|
|
493
491
|
function isRelativeURL(s4) {
|
|
494
492
|
const validStart = /^\.{1,2}/.test(s4);
|
|
495
493
|
const validEnding = !endsWith(s4, "index");
|
|
@@ -4827,11 +4825,17 @@ var ExcalidrawPage = (opts) => ({
|
|
|
4827
4825
|
}
|
|
4828
4826
|
}
|
|
4829
4827
|
const baseName = filePath.replace(/\.excalidraw\.md$/, "").replace(/\.excalidraw$/, "").split("/").pop() ?? "Excalidraw Drawing";
|
|
4830
|
-
const
|
|
4828
|
+
const slug = slugifyFilePath(filePath);
|
|
4831
4829
|
virtualPages.push({
|
|
4832
|
-
slug
|
|
4830
|
+
slug,
|
|
4833
4831
|
title: baseName,
|
|
4834
4832
|
data: {
|
|
4833
|
+
// The page stands for the drawing file: give it the source paths Quartz's parser
|
|
4834
|
+
// sets on notes (instead of the synthetic `<slug>.md`), so bases list it as that
|
|
4835
|
+
// file (file.ext "excalidraw", or "md" for a drawing stored as Markdown), and
|
|
4836
|
+
// folder listings and the content index see its real path.
|
|
4837
|
+
filePath: joinSegments(ctx.argv.directory, filePath),
|
|
4838
|
+
relativePath: filePath,
|
|
4835
4839
|
frontmatter: { title: baseName, tags: ["excalidraw"] },
|
|
4836
4840
|
excalidrawData: data,
|
|
4837
4841
|
excalidrawOptions: opts,
|