@slidev/cli 0.40.10 → 0.40.12
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/{build-NX2PGO4O.mjs → build-FJEPW676.mjs} +1 -1
- package/dist/{build-NDJOZSTK.js → build-WYIA5JH3.js} +5 -5
- package/dist/{chunk-ENFQSII4.mjs → chunk-5I4574GN.mjs} +14 -14
- package/dist/{chunk-7DDFS6XM.mjs → chunk-EPAQPHV3.mjs} +224 -177
- package/dist/{chunk-4CEI2UPN.js → chunk-FBUSIC7D.js} +226 -179
- package/dist/{chunk-AJJDLJSH.js → chunk-LWVN4G3W.js} +14 -14
- package/dist/cli.js +28 -28
- package/dist/cli.mjs +3 -3
- package/dist/index.js +3 -3
- package/dist/index.mjs +2 -2
- package/package.json +11 -11
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkLWVN4G3Wjs = require('./chunk-LWVN4G3W.js');
|
|
6
6
|
require('./chunk-GE7W2DBE.js');
|
|
7
7
|
|
|
8
8
|
// node/build.ts
|
|
@@ -646,16 +646,16 @@ async function build(options, viteConfig = {}, args) {
|
|
|
646
646
|
let originalIndexHTML;
|
|
647
647
|
if (_fsextra2.default.existsSync(indexPath))
|
|
648
648
|
originalIndexHTML = await _fsextra2.default.readFile(indexPath, "utf-8");
|
|
649
|
-
await _fsextra2.default.writeFile(indexPath, await
|
|
649
|
+
await _fsextra2.default.writeFile(indexPath, await _chunkLWVN4G3Wjs.getIndexHtml.call(void 0, options), "utf-8");
|
|
650
650
|
let config = void 0;
|
|
651
651
|
try {
|
|
652
|
-
const inlineConfig = await
|
|
652
|
+
const inlineConfig = await _chunkLWVN4G3Wjs.mergeViteConfigs.call(void 0,
|
|
653
653
|
options,
|
|
654
654
|
viteConfig,
|
|
655
655
|
{
|
|
656
656
|
root: options.userRoot,
|
|
657
657
|
plugins: [
|
|
658
|
-
await
|
|
658
|
+
await _chunkLWVN4G3Wjs.ViteSlidevPlugin.call(void 0, options, pluginOptions),
|
|
659
659
|
{
|
|
660
660
|
name: "resolve-config",
|
|
661
661
|
configResolved(_config) {
|
|
@@ -676,7 +676,7 @@ async function build(options, viteConfig = {}, args) {
|
|
|
676
676
|
} else {
|
|
677
677
|
console.log(_kolorist.blue.call(void 0, " building for Monaco...\n"));
|
|
678
678
|
await _vite.build.call(void 0,
|
|
679
|
-
await
|
|
679
|
+
await _chunkLWVN4G3Wjs.mergeViteConfigs.call(void 0,
|
|
680
680
|
options,
|
|
681
681
|
inlineConfig,
|
|
682
682
|
{
|
|
@@ -197,6 +197,7 @@ async function createWindiCSSPlugin({ themeRoots, addonRoots, clientRoot, userRo
|
|
|
197
197
|
|
|
198
198
|
// node/plugins/preset.ts
|
|
199
199
|
import { join as join8 } from "path";
|
|
200
|
+
import { existsSync as existsSync6 } from "fs";
|
|
200
201
|
import Vue from "@vitejs/plugin-vue";
|
|
201
202
|
import VueJsx from "@vitejs/plugin-vue-jsx";
|
|
202
203
|
import Icons from "unplugin-icons/vite";
|
|
@@ -270,10 +271,10 @@ var dependencies = {
|
|
|
270
271
|
"@antfu/utils": "^0.7.2",
|
|
271
272
|
"@slidev/parser": "workspace:*",
|
|
272
273
|
"@slidev/types": "workspace:*",
|
|
273
|
-
"@unocss/reset": "^0.51.
|
|
274
|
-
"@vueuse/core": "^
|
|
275
|
-
"@vueuse/head": "^1.1.
|
|
276
|
-
"@vueuse/math": "^
|
|
274
|
+
"@unocss/reset": "^0.51.4",
|
|
275
|
+
"@vueuse/core": "^10.0.2",
|
|
276
|
+
"@vueuse/head": "^1.1.26",
|
|
277
|
+
"@vueuse/math": "^10.0.2",
|
|
277
278
|
"@vueuse/motion": "^2.0.0-beta.27",
|
|
278
279
|
codemirror: "^5.65.5",
|
|
279
280
|
defu: "^6.1.2",
|
|
@@ -282,14 +283,14 @@ var dependencies = {
|
|
|
282
283
|
"fuse.js": "^6.6.2",
|
|
283
284
|
"js-base64": "^3.7.5",
|
|
284
285
|
"js-yaml": "^4.1.0",
|
|
285
|
-
katex: "^0.16.
|
|
286
|
+
katex: "^0.16.6",
|
|
286
287
|
mermaid: "^10.1.0",
|
|
287
288
|
"monaco-editor": "^0.37.1",
|
|
288
289
|
nanoid: "^4.0.2",
|
|
289
290
|
prettier: "^2.8.7",
|
|
290
291
|
recordrtc: "^5.6.2",
|
|
291
292
|
resolve: "^1.22.2",
|
|
292
|
-
unocss: "^0.51.
|
|
293
|
+
unocss: "^0.51.4",
|
|
293
294
|
"vite-plugin-windicss": "^1.8.10",
|
|
294
295
|
vue: "^3.2.47",
|
|
295
296
|
"vue-router": "^4.1.6",
|
|
@@ -1631,6 +1632,7 @@ async function ViteSlidevPlugin(options, pluginOptions, serverOptions = {}) {
|
|
|
1631
1632
|
const VueJsxPlugin = VueJsx(vuejsxOptions);
|
|
1632
1633
|
const MarkdownPlugin = await createMarkdownPlugin(options, pluginOptions);
|
|
1633
1634
|
const drawingData = await loadDrawings(options);
|
|
1635
|
+
const publicRoots = themeRoots.map((i) => join8(i, "public")).filter(existsSync6);
|
|
1634
1636
|
return [
|
|
1635
1637
|
MarkdownPlugin,
|
|
1636
1638
|
VueJsxPlugin,
|
|
@@ -1693,14 +1695,12 @@ async function ViteSlidevPlugin(options, pluginOptions, serverOptions = {}) {
|
|
|
1693
1695
|
writeDrawings(options, patch ?? data);
|
|
1694
1696
|
}
|
|
1695
1697
|
}),
|
|
1696
|
-
viteStaticCopy({
|
|
1697
|
-
targets:
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
})
|
|
1703
|
-
}),
|
|
1698
|
+
publicRoots.length ? viteStaticCopy({
|
|
1699
|
+
targets: publicRoots.map((r) => ({
|
|
1700
|
+
src: `${r}/*`,
|
|
1701
|
+
dest: "theme"
|
|
1702
|
+
}))
|
|
1703
|
+
}) : null,
|
|
1704
1704
|
createConfigPlugin(options),
|
|
1705
1705
|
createClientSetupPlugin(options),
|
|
1706
1706
|
createMonacoTypesLoader(),
|