starlight-cannoli-plugins 2.1.5 → 2.1.6

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.
@@ -154,10 +154,14 @@ function syncDocsToPublic(options) {
154
154
  "astro:config:setup": ({ injectScript }) => {
155
155
  validateOptions(options);
156
156
  if (exposePageSrcButton) {
157
+ const currentFile = fileURLToPath(import.meta.url);
157
158
  const scriptPath = fileURLToPath(
158
- import.meta.url.endsWith(".ts") ? new URL("./page-script.ts", import.meta.url) : new URL(
159
+ currentFile.endsWith(".ts") ? new URL("./page-script.ts", import.meta.url) : currentFile.endsWith("astro-sync-docs-to-public.js") ? new URL(
159
160
  "./astro-sync-docs-to-public/page-script.js",
160
161
  import.meta.url
162
+ ) : new URL(
163
+ "./plugins/astro-sync-docs-to-public/page-script.js",
164
+ import.meta.url
161
165
  )
162
166
  );
163
167
  injectScript("page", `import ${JSON.stringify(scriptPath)};`);
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ import {
13
13
  } from "./chunk-AZPHBHBE.js";
14
14
  import {
15
15
  syncDocsToPublic
16
- } from "./chunk-2A5FZT5N.js";
16
+ } from "./chunk-YT5STVTC.js";
17
17
  import "./chunk-3ATSZG6H.js";
18
18
  import "./chunk-TTQY54Q6.js";
19
19
  import "./chunk-QGM4M3NI.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  starlightSyncDocsToPublic,
3
3
  syncDocsToPublic
4
- } from "../chunk-2A5FZT5N.js";
4
+ } from "../chunk-YT5STVTC.js";
5
5
  import "../chunk-3ATSZG6H.js";
6
6
  import "../chunk-QGM4M3NI.js";
7
7
  export {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "starlight-cannoli-plugins",
3
3
  "type": "module",
4
- "version": "2.1.5",
4
+ "version": "2.1.6",
5
5
  "description": "Starlight plugins for automatic sidebar generation and link validation",
6
6
  "license": "ISC",
7
7
  "main": "./dist/index.js",