@nuxtjs/mdc 0.13.3 → 0.13.4

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/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nuxtjs/mdc",
3
3
  "configKey": "mdc",
4
- "version": "0.13.3",
4
+ "version": "0.13.4",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.8.4",
7
7
  "unbuild": "2.0.0"
@@ -11,6 +11,9 @@ export const unsafeLinkPrefix = [
11
11
  function isAnchorLinkAllowed(value) {
12
12
  const decodedUrl = decodeURIComponent(value);
13
13
  const urlSanitized = decodedUrl.replace(/&#x([0-9a-f]+);?/gi, "").replace(/&#(\d+);?/g, "").replace(/&[a-z]+;?/gi, "");
14
+ if (urlSanitized.startsWith("/") || urlSanitized.startsWith("./") || urlSanitized.startsWith("../")) {
15
+ return true;
16
+ }
14
17
  try {
15
18
  const url = new URL(urlSanitized);
16
19
  if (unsafeLinkPrefix.some((prefix) => url.protocol.toLowerCase().startsWith(prefix))) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nuxtjs/mdc",
3
- "version": "0.13.3",
3
+ "version": "0.13.4",
4
4
  "description": "Nuxt MDC module",
5
5
  "repository": "nuxt-modules/mdc",
6
6
  "license": "MIT",