@slidev/types 0.49.11 → 0.49.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/client.d.ts +2 -1
- package/dist/index.d.mts +6 -3
- package/package.json +7 -7
package/client.d.ts
CHANGED
|
@@ -42,13 +42,14 @@ declare module '#slidev/custom-nav-controls' {
|
|
|
42
42
|
|
|
43
43
|
declare module '#slidev/shiki' {
|
|
44
44
|
import type { ShikiHighlighterCore } from 'shiki/core'
|
|
45
|
-
import type { BundledLanguage, BundledTheme } from 'shiki'
|
|
45
|
+
import type { BundledLanguage, BundledTheme, CodeToHastOptions } from 'shiki'
|
|
46
46
|
|
|
47
47
|
export { shikiToMonaco } from '@shikijs/monaco'
|
|
48
48
|
|
|
49
49
|
export const langs: BundledLanguage[]
|
|
50
50
|
export const themes: BundledTheme | Record<string, BundledTheme>
|
|
51
51
|
export const shiki: Promise<ShikiHighlighterCore>
|
|
52
|
+
export function getHighlighter(): Promise<(code: string, lang: string, options?: Partial<CodeToHastOptions>) => Promise<string>>
|
|
52
53
|
}
|
|
53
54
|
|
|
54
55
|
declare module '#slidev/setups/monaco' {
|
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RouteMeta, RouteComponent, Router, RouteRecordRaw } from 'vue-router';
|
|
2
2
|
import YAML from 'yaml';
|
|
3
|
-
import { TransitionGroupProps, Component, App, Ref, ComputedRef } from 'vue';
|
|
3
|
+
import { TransitionGroupProps, MaybeRefOrGetter, Component, App, Ref, ComputedRef } from 'vue';
|
|
4
4
|
import { Arrayable, Awaitable, ArgumentsType } from '@antfu/utils';
|
|
5
5
|
import * as monaco from 'monaco-editor';
|
|
6
6
|
import mermaid from 'mermaid';
|
|
@@ -25,6 +25,7 @@ interface ExportArgs extends CommonArgs {
|
|
|
25
25
|
'format'?: string;
|
|
26
26
|
'timeout'?: number;
|
|
27
27
|
'wait'?: number;
|
|
28
|
+
'wait-until'?: string;
|
|
28
29
|
'range'?: string;
|
|
29
30
|
'dark'?: boolean;
|
|
30
31
|
'with-clicks'?: boolean;
|
|
@@ -557,7 +558,7 @@ interface CodeRunnerOutputText {
|
|
|
557
558
|
}
|
|
558
559
|
type CodeRunnerOutputTextArray = CodeRunnerOutputText[];
|
|
559
560
|
type CodeRunnerOutput = CodeRunnerOutputHtml | CodeRunnerOutputError | CodeRunnerOutputText | CodeRunnerOutputTextArray | CodeRunnerOutputDom;
|
|
560
|
-
type CodeRunnerOutputs = Arrayable<CodeRunnerOutput
|
|
561
|
+
type CodeRunnerOutputs = MaybeRefOrGetter<Arrayable<CodeRunnerOutput>>;
|
|
561
562
|
type CodeRunner = (code: string, ctx: CodeRunnerContext) => Awaitable<CodeRunnerOutputs>;
|
|
562
563
|
type CodeRunnerProviders = Record<string, CodeRunner>;
|
|
563
564
|
|
|
@@ -790,14 +791,16 @@ interface ClicksInfo {
|
|
|
790
791
|
interface ClicksContext {
|
|
791
792
|
current: number;
|
|
792
793
|
readonly clicksStart: number;
|
|
793
|
-
readonly
|
|
794
|
+
readonly relativeSizeMap: Map<ClicksElement, number>;
|
|
794
795
|
readonly maxMap: Map<ClicksElement, number>;
|
|
795
796
|
calculateSince: (at: RawSingleAtValue, size?: number) => ClicksInfo | null;
|
|
796
797
|
calculateRange: (at: RawRangeAtValue) => ClicksInfo | null;
|
|
797
798
|
calculate: (at: RawAtValue) => ClicksInfo | null;
|
|
798
799
|
register: (el: ClicksElement, info: Pick<ClicksInfo, 'delta' | 'max'> | null) => void;
|
|
799
800
|
unregister: (el: ClicksElement) => void;
|
|
801
|
+
readonly isMounted: boolean;
|
|
800
802
|
onMounted: () => void;
|
|
803
|
+
onUnmounted: () => void;
|
|
801
804
|
readonly currentOffset: number;
|
|
802
805
|
readonly total: number;
|
|
803
806
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@slidev/types",
|
|
3
|
-
"version": "0.49.
|
|
3
|
+
"version": "0.49.12",
|
|
4
4
|
"description": "Shared types declarations for Slidev",
|
|
5
5
|
"author": "antfu <anthonyfu117@hotmail.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,18 +25,18 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@antfu/utils": "^0.7.8",
|
|
27
27
|
"@vitejs/plugin-vue": "^5.0.5",
|
|
28
|
-
"@vitejs/plugin-vue-jsx": "^
|
|
28
|
+
"@vitejs/plugin-vue-jsx": "^4.0.0",
|
|
29
29
|
"katex": "^0.16.10",
|
|
30
30
|
"mermaid": "^10.9.1",
|
|
31
|
-
"monaco-editor": "^0.
|
|
32
|
-
"shiki": "^1.
|
|
33
|
-
"unocss": "^0.
|
|
31
|
+
"monaco-editor": "^0.50.0",
|
|
32
|
+
"shiki": "^1.9.1",
|
|
33
|
+
"unocss": "^0.61.0",
|
|
34
34
|
"unplugin-icons": "^0.19.0",
|
|
35
35
|
"unplugin-vue-markdown": "^0.26.2",
|
|
36
36
|
"vite-plugin-remote-assets": "^0.4.1",
|
|
37
37
|
"vite-plugin-vue-server-ref": "^0.4.2",
|
|
38
|
-
"vue": "^3.4.
|
|
39
|
-
"vue-router": "^4.
|
|
38
|
+
"vue": "^3.4.30",
|
|
39
|
+
"vue-router": "^4.4.0"
|
|
40
40
|
},
|
|
41
41
|
"scripts": {
|
|
42
42
|
"build": "tsup src/index.ts",
|