@slidev/client 52.1.0 → 52.2.3
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/internals/ContextMenu.vue +23 -21
- package/layouts/two-cols-header.vue +7 -1
- package/package.json +20 -20
- package/setup/context-menu.ts +1 -0
|
@@ -67,31 +67,33 @@ const top = computed(() => {
|
|
|
67
67
|
>
|
|
68
68
|
<template v-for="item, index of currentContextMenu.items.value" :key="index">
|
|
69
69
|
<div v-if="item === 'separator'" :key="index" class="w-full my1 border-t border-main" />
|
|
70
|
-
<
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
<component :is="item.icon" v-else />
|
|
79
|
-
</div>
|
|
80
|
-
<div
|
|
81
|
-
v-else
|
|
82
|
-
class="w-full grid grid-cols-[35px_1fr] p-2 pl-0 cursor-pointer rounded"
|
|
83
|
-
:class="item.disabled ? `op40` : `hover:bg-active`"
|
|
84
|
-
@click="item.action"
|
|
85
|
-
>
|
|
86
|
-
<div class="mx-auto flex">
|
|
70
|
+
<template v-else-if="item.show ?? true">
|
|
71
|
+
<div
|
|
72
|
+
v-if="item.small"
|
|
73
|
+
class="p-2 w-[40px] h-[40px] inline-block text-center cursor-pointer rounded flex"
|
|
74
|
+
:class="item.disabled ? `op40` : `hover:bg-active`"
|
|
75
|
+
:title="(item.label as string)"
|
|
76
|
+
@click="item.action"
|
|
77
|
+
>
|
|
87
78
|
<div v-if="typeof item.icon === 'string'" :class="item.icon" class="text-1.2em ma" />
|
|
88
79
|
<component :is="item.icon" v-else />
|
|
89
80
|
</div>
|
|
90
|
-
<div
|
|
91
|
-
|
|
81
|
+
<div
|
|
82
|
+
v-else
|
|
83
|
+
class="w-full grid grid-cols-[35px_1fr] p-2 pl-0 cursor-pointer rounded"
|
|
84
|
+
:class="item.disabled ? `op40` : `hover:bg-active`"
|
|
85
|
+
@click="item.action"
|
|
86
|
+
>
|
|
87
|
+
<div class="mx-auto flex">
|
|
88
|
+
<div v-if="typeof item.icon === 'string'" :class="item.icon" class="text-1.2em ma" />
|
|
89
|
+
<component :is="item.icon" v-else />
|
|
90
|
+
</div>
|
|
91
|
+
<div v-if="typeof item.label === 'string'">
|
|
92
|
+
{{ item.label }}
|
|
93
|
+
</div>
|
|
94
|
+
<component :is="item.label" v-else />
|
|
92
95
|
</div>
|
|
93
|
-
|
|
94
|
-
</div>
|
|
96
|
+
</template>
|
|
95
97
|
</template>
|
|
96
98
|
<template v-if="!isExplicitEnabled">
|
|
97
99
|
<div class="w-full my1 border-t border-main" />
|
|
@@ -13,6 +13,12 @@ This shows on the left
|
|
|
13
13
|
This shows on the right
|
|
14
14
|
::bottom::
|
|
15
15
|
This shows at the bottom, aligned to the end (bottom) of the grid
|
|
16
|
+
|
|
17
|
+
<style>
|
|
18
|
+
.two-cols-header {
|
|
19
|
+
column-gap: 20px; /* Adjust the gap size as needed */
|
|
20
|
+
}
|
|
21
|
+
</style>
|
|
16
22
|
```
|
|
17
23
|
-->
|
|
18
24
|
|
|
@@ -48,7 +54,7 @@ const props = defineProps({
|
|
|
48
54
|
.two-cols-header {
|
|
49
55
|
display: grid;
|
|
50
56
|
grid-template-columns: repeat(2, 1fr);
|
|
51
|
-
grid-template-rows:
|
|
57
|
+
grid-template-rows: auto 1fr auto;
|
|
52
58
|
}
|
|
53
59
|
|
|
54
60
|
.col-header {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@slidev/client",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "52.
|
|
4
|
+
"version": "52.2.3",
|
|
5
5
|
"description": "Presentation slides for developers",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -29,18 +29,18 @@
|
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@antfu/utils": "^9.2.0",
|
|
32
|
-
"@iconify-json/carbon": "^1.2.
|
|
32
|
+
"@iconify-json/carbon": "^1.2.13",
|
|
33
33
|
"@iconify-json/ph": "^1.2.2",
|
|
34
|
-
"@iconify-json/svg-spinners": "^1.2.
|
|
35
|
-
"@shikijs/engine-javascript": "^3.
|
|
36
|
-
"@shikijs/monaco": "^3.
|
|
37
|
-
"@shikijs/vitepress-twoslash": "^3.
|
|
34
|
+
"@iconify-json/svg-spinners": "^1.2.4",
|
|
35
|
+
"@shikijs/engine-javascript": "^3.13.0",
|
|
36
|
+
"@shikijs/monaco": "^3.13.0",
|
|
37
|
+
"@shikijs/vitepress-twoslash": "^3.13.0",
|
|
38
38
|
"@slidev/rough-notation": "^0.1.0",
|
|
39
39
|
"@typescript/ata": "^0.9.8",
|
|
40
|
-
"@unhead/vue": "^2.0.
|
|
41
|
-
"@unocss/reset": "^66.
|
|
42
|
-
"@vueuse/core": "^13.
|
|
43
|
-
"@vueuse/math": "^13.
|
|
40
|
+
"@unhead/vue": "^2.0.17",
|
|
41
|
+
"@unocss/reset": "^66.5.1",
|
|
42
|
+
"@vueuse/core": "^13.9.0",
|
|
43
|
+
"@vueuse/math": "^13.9.0",
|
|
44
44
|
"@vueuse/motion": "^3.0.3",
|
|
45
45
|
"drauu": "^0.4.3",
|
|
46
46
|
"file-saver": "^2.0.5",
|
|
@@ -48,23 +48,23 @@
|
|
|
48
48
|
"fuse.js": "^7.1.0",
|
|
49
49
|
"katex": "^0.16.22",
|
|
50
50
|
"lz-string": "^1.5.0",
|
|
51
|
-
"mermaid": "^11.
|
|
52
|
-
"monaco-editor": "^0.
|
|
51
|
+
"mermaid": "^11.12.0",
|
|
52
|
+
"monaco-editor": "^0.53.0",
|
|
53
53
|
"nanotar": "^0.2.0",
|
|
54
54
|
"pptxgenjs": "^4.0.1",
|
|
55
55
|
"prettier": "^3.6.2",
|
|
56
56
|
"recordrtc": "^5.6.2",
|
|
57
|
-
"shiki": "^3.
|
|
57
|
+
"shiki": "^3.13.0",
|
|
58
58
|
"shiki-magic-move": "^1.1.0",
|
|
59
|
-
"typescript": "^5.
|
|
60
|
-
"unocss": "^66.
|
|
61
|
-
"vue": "^3.5.
|
|
59
|
+
"typescript": "^5.9.2",
|
|
60
|
+
"unocss": "^66.5.1",
|
|
61
|
+
"vue": "^3.5.21",
|
|
62
62
|
"vue-router": "^4.5.1",
|
|
63
|
-
"yaml": "^2.8.
|
|
64
|
-
"@slidev/
|
|
65
|
-
"@slidev/
|
|
63
|
+
"yaml": "^2.8.1",
|
|
64
|
+
"@slidev/parser": "52.2.3",
|
|
65
|
+
"@slidev/types": "52.2.3"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
|
-
"vite": "^7.
|
|
68
|
+
"vite": "^7.1.6"
|
|
69
69
|
}
|
|
70
70
|
}
|
package/setup/context-menu.ts
CHANGED
|
@@ -73,6 +73,7 @@ export default () => {
|
|
|
73
73
|
icon: 'i-carbon:text-annotation-toggle', // IconTextNotationToggle,
|
|
74
74
|
label: showEditor.value ? 'Hide editor' : 'Show editor',
|
|
75
75
|
action: () => (showEditor.value = !showEditor.value),
|
|
76
|
+
show: __DEV__,
|
|
76
77
|
},
|
|
77
78
|
{
|
|
78
79
|
icon: 'i-carbon:pen',
|