do11y 0.2.7 → 0.2.9

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.
@@ -58,7 +58,7 @@ export default () => {
58
58
  */
59
59
  if (viteDevServer?.config.command === "serve" || !id.endsWith("lang=css")) {
60
60
  return {
61
- code: `export default \`${await highlightAndFormatCode(path, source)}\`;`,
61
+ code: `export default ${JSON.stringify(await highlightAndFormatCode(path, source))};`,
62
62
  moduleType: "js",
63
63
  };
64
64
  }
@@ -80,7 +80,7 @@ export default () => {
80
80
  .map((stylesheet) => `<style>${stylesheet}</style>`)
81
81
  .join("\n");
82
82
  return {
83
- code: `export default \`${await highlightAndFormatCode(path, sourceWithoutStyles + css)}\`;`,
83
+ code: `export default ${JSON.stringify(await highlightAndFormatCode(path, sourceWithoutStyles + css))};`,
84
84
  moduleType: "js",
85
85
  };
86
86
  }
package/dist/ui/index.js CHANGED
@@ -1 +1 @@
1
- import{createApp as e,createBlock as t,createCommentVNode as n,defineComponent as r,onBeforeMount as i,openBlock as a,renderSlot as o,shallowRef as s,unref as c,withCtx as l}from"vue";import u from"do11y:options";import{createRouter as d,createWebHistory as f}from"vue-router";import p from"do11y:routes";import"do11y:css";var m=r({__name:`Page`,setup(e){let n=s();return i(async()=>{n.value=(await u.Layout?.())?.default}),(e,r)=>n.value?(a(),t(c(n),{key:0},{default:l(()=>[o(e.$slots,`default`)]),_:3})):o(e.$slots,`default`,{key:1})}});(async()=>{let t=d({history:f(`/`),routes:p}),n=e(m);await u.setup?.(n,t),n.use(t),n.mount(`#app`)})();
1
+ import{createApp as e,createBlock as t,createCommentVNode as n,defineComponent as r,onBeforeMount as i,openBlock as a,renderSlot as o,shallowRef as s,unref as c,withCtx as l}from"vue";import u from"do11y:options";import{createRouter as d,createWebHistory as f}from"vue-router";import p from"do11y:routes";import m from"do11y:css";var h=r({__name:`Page`,setup(e){let n=s();return i(async()=>{n.value=(await u.Layout?.())?.default;let e=document.createElement(`style`);e.innerHTML=m,document.head.appendChild(e)}),(e,r)=>n.value?(a(),t(c(n),{key:0},{default:l(()=>[o(e.$slots,`default`)]),_:3})):o(e.$slots,`default`,{key:1})}});(async()=>{let t=d({history:f(`/`),routes:p}),n=e(h);await u.setup?.(n,t),n.use(t),n.mount(`#app`)})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "do11y",
3
- "version": "0.2.7",
3
+ "version": "0.2.9",
4
4
  "description": "A bare-bones tool to document Vue components.",
5
5
  "keywords": [
6
6
  "docs-generator",
package/src/types.d.ts CHANGED
@@ -26,9 +26,8 @@ declare module "do11y:options" {
26
26
  }
27
27
 
28
28
  declare module "do11y:css" {
29
- /**
30
- * The CSS required for dual themes.
31
- */
29
+ const css: string;
30
+ export default string;
32
31
  }
33
32
 
34
33
  declare module "do11y:sandbox" {