@mantine-vue/code-highlight 2.4.0 → 3.1.0
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/cjs/index.cjs +511 -576
- package/cjs/index.cjs.map +1 -1
- package/esm/index.mjs +511 -576
- package/esm/index.mjs.map +1 -1
- package/lib/CodeHighlight/CodeHighlight.d.ts +46 -496
- package/lib/CodeHighlight/CodeHighlight.types.d.ts +80 -0
- package/lib/CodeHighlight/CodeHighlight.vue.d.ts +17 -0
- package/lib/CodeHighlight/CodeHighlightControl/CodeHighlightControl.d.ts +2 -68
- package/lib/CodeHighlight/CodeHighlightControl/CodeHighlightControl.types.d.ts +20 -0
- package/lib/CodeHighlight/CodeHighlightControl/CodeHighlightControl.vue.d.ts +15 -0
- package/lib/CodeHighlight/CopyCodeButton/CopyCodeButton.d.ts +1 -32
- package/lib/CodeHighlight/CopyCodeButton/CopyCodeButton.vue.d.ts +8 -0
- package/lib/CodeHighlight/CopyCodeButton/CopyIcon.d.ts +1 -13
- package/lib/CodeHighlight/CopyCodeButton/CopyIcon.vue.d.ts +6 -0
- package/lib/CodeHighlight/ExpandCodeButton/ExpandCodeButton.d.ts +1 -41
- package/lib/CodeHighlight/ExpandCodeButton/ExpandCodeButton.vue.d.ts +15 -0
- package/lib/CodeHighlight/ExpandCodeButton/ExpandIcon.d.ts +1 -13
- package/lib/CodeHighlight/ExpandCodeButton/ExpandIcon.vue.d.ts +6 -0
- package/lib/CodeHighlight/InlineCodeHighlight.d.ts +16 -107
- package/lib/CodeHighlight/InlineCodeHighlight.types.d.ts +30 -0
- package/lib/CodeHighlight/InlineCodeHighlight.vue.d.ts +5 -0
- package/lib/CodeHighlightProvider/CodeHighlightAdapterProvider.vue.d.ts +14 -0
- package/lib/CodeHighlightProvider/CodeHighlightProvider.d.ts +19 -32
- package/lib/CodeHighlightProvider/CodeHighlightProvider.types.d.ts +25 -0
- package/lib/CodeHighlightTabs/CodeHighlightTabs.d.ts +43 -262
- package/lib/CodeHighlightTabs/CodeHighlightTabs.types.d.ts +47 -0
- package/lib/CodeHighlightTabs/CodeHighlightTabs.vue.d.ts +21 -0
- package/lib/CodeHighlightTabs/FileIcon.d.ts +1 -40
- package/lib/CodeHighlightTabs/FileIcon.vue.d.ts +21 -0
- package/lib/index.d.mts +3 -3
- package/lib/index.d.ts +3 -3
- package/package.json +3 -3
|
@@ -1,262 +1,43 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
default: undefined;
|
|
45
|
-
};
|
|
46
|
-
activeTab: {
|
|
47
|
-
type: NumberConstructor;
|
|
48
|
-
default: undefined;
|
|
49
|
-
};
|
|
50
|
-
onTabChange: {
|
|
51
|
-
type: PropType<(tab: number) => void>;
|
|
52
|
-
default: undefined;
|
|
53
|
-
};
|
|
54
|
-
defaultExpanded: {
|
|
55
|
-
type: BooleanConstructor;
|
|
56
|
-
default: undefined;
|
|
57
|
-
};
|
|
58
|
-
expanded: {
|
|
59
|
-
type: BooleanConstructor;
|
|
60
|
-
default: undefined;
|
|
61
|
-
};
|
|
62
|
-
onExpandedChange: {
|
|
63
|
-
type: PropType<(expanded: boolean) => void>;
|
|
64
|
-
default: undefined;
|
|
65
|
-
};
|
|
66
|
-
withCopyButton: {
|
|
67
|
-
type: BooleanConstructor;
|
|
68
|
-
default: undefined;
|
|
69
|
-
};
|
|
70
|
-
withExpandButton: {
|
|
71
|
-
type: BooleanConstructor;
|
|
72
|
-
default: boolean;
|
|
73
|
-
};
|
|
74
|
-
withBorder: {
|
|
75
|
-
type: BooleanConstructor;
|
|
76
|
-
default: boolean;
|
|
77
|
-
};
|
|
78
|
-
radius: {
|
|
79
|
-
type: PropType<string | number>;
|
|
80
|
-
default: undefined;
|
|
81
|
-
};
|
|
82
|
-
maxCollapsedHeight: {
|
|
83
|
-
type: PropType<string | number>;
|
|
84
|
-
default: undefined;
|
|
85
|
-
};
|
|
86
|
-
copyLabel: {
|
|
87
|
-
type: StringConstructor;
|
|
88
|
-
default: undefined;
|
|
89
|
-
};
|
|
90
|
-
copiedLabel: {
|
|
91
|
-
type: StringConstructor;
|
|
92
|
-
default: undefined;
|
|
93
|
-
};
|
|
94
|
-
expandCodeLabel: {
|
|
95
|
-
type: StringConstructor;
|
|
96
|
-
default: undefined;
|
|
97
|
-
};
|
|
98
|
-
collapseCodeLabel: {
|
|
99
|
-
type: StringConstructor;
|
|
100
|
-
default: undefined;
|
|
101
|
-
};
|
|
102
|
-
background: {
|
|
103
|
-
type: StringConstructor;
|
|
104
|
-
default: undefined;
|
|
105
|
-
};
|
|
106
|
-
controls: {
|
|
107
|
-
type: PropType<CodeHighlightSettings["controls"]>;
|
|
108
|
-
default: undefined;
|
|
109
|
-
};
|
|
110
|
-
codeColorScheme: {
|
|
111
|
-
type: PropType<CodeHighlightSettings["codeColorScheme"]>;
|
|
112
|
-
default: undefined;
|
|
113
|
-
};
|
|
114
|
-
withLineNumbers: {
|
|
115
|
-
type: BooleanConstructor;
|
|
116
|
-
default: boolean;
|
|
117
|
-
};
|
|
118
|
-
classNames: {
|
|
119
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
120
|
-
default: undefined;
|
|
121
|
-
};
|
|
122
|
-
styles: {
|
|
123
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
124
|
-
default: undefined;
|
|
125
|
-
};
|
|
126
|
-
vars: {
|
|
127
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
128
|
-
default: undefined;
|
|
129
|
-
};
|
|
130
|
-
unstyled: {
|
|
131
|
-
type: BooleanConstructor;
|
|
132
|
-
default: boolean;
|
|
133
|
-
};
|
|
134
|
-
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
135
|
-
[key: string]: any;
|
|
136
|
-
}> | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
137
|
-
code: {
|
|
138
|
-
type: PropType<CodeHighlightTabsCode[]>;
|
|
139
|
-
required: true;
|
|
140
|
-
};
|
|
141
|
-
getFileIcon: {
|
|
142
|
-
type: PropType<(fileName: string) => VNodeChild>;
|
|
143
|
-
default: undefined;
|
|
144
|
-
};
|
|
145
|
-
defaultActiveTab: {
|
|
146
|
-
type: NumberConstructor;
|
|
147
|
-
default: undefined;
|
|
148
|
-
};
|
|
149
|
-
activeTab: {
|
|
150
|
-
type: NumberConstructor;
|
|
151
|
-
default: undefined;
|
|
152
|
-
};
|
|
153
|
-
onTabChange: {
|
|
154
|
-
type: PropType<(tab: number) => void>;
|
|
155
|
-
default: undefined;
|
|
156
|
-
};
|
|
157
|
-
defaultExpanded: {
|
|
158
|
-
type: BooleanConstructor;
|
|
159
|
-
default: undefined;
|
|
160
|
-
};
|
|
161
|
-
expanded: {
|
|
162
|
-
type: BooleanConstructor;
|
|
163
|
-
default: undefined;
|
|
164
|
-
};
|
|
165
|
-
onExpandedChange: {
|
|
166
|
-
type: PropType<(expanded: boolean) => void>;
|
|
167
|
-
default: undefined;
|
|
168
|
-
};
|
|
169
|
-
withCopyButton: {
|
|
170
|
-
type: BooleanConstructor;
|
|
171
|
-
default: undefined;
|
|
172
|
-
};
|
|
173
|
-
withExpandButton: {
|
|
174
|
-
type: BooleanConstructor;
|
|
175
|
-
default: boolean;
|
|
176
|
-
};
|
|
177
|
-
withBorder: {
|
|
178
|
-
type: BooleanConstructor;
|
|
179
|
-
default: boolean;
|
|
180
|
-
};
|
|
181
|
-
radius: {
|
|
182
|
-
type: PropType<string | number>;
|
|
183
|
-
default: undefined;
|
|
184
|
-
};
|
|
185
|
-
maxCollapsedHeight: {
|
|
186
|
-
type: PropType<string | number>;
|
|
187
|
-
default: undefined;
|
|
188
|
-
};
|
|
189
|
-
copyLabel: {
|
|
190
|
-
type: StringConstructor;
|
|
191
|
-
default: undefined;
|
|
192
|
-
};
|
|
193
|
-
copiedLabel: {
|
|
194
|
-
type: StringConstructor;
|
|
195
|
-
default: undefined;
|
|
196
|
-
};
|
|
197
|
-
expandCodeLabel: {
|
|
198
|
-
type: StringConstructor;
|
|
199
|
-
default: undefined;
|
|
200
|
-
};
|
|
201
|
-
collapseCodeLabel: {
|
|
202
|
-
type: StringConstructor;
|
|
203
|
-
default: undefined;
|
|
204
|
-
};
|
|
205
|
-
background: {
|
|
206
|
-
type: StringConstructor;
|
|
207
|
-
default: undefined;
|
|
208
|
-
};
|
|
209
|
-
controls: {
|
|
210
|
-
type: PropType<CodeHighlightSettings["controls"]>;
|
|
211
|
-
default: undefined;
|
|
212
|
-
};
|
|
213
|
-
codeColorScheme: {
|
|
214
|
-
type: PropType<CodeHighlightSettings["codeColorScheme"]>;
|
|
215
|
-
default: undefined;
|
|
216
|
-
};
|
|
217
|
-
withLineNumbers: {
|
|
218
|
-
type: BooleanConstructor;
|
|
219
|
-
default: boolean;
|
|
220
|
-
};
|
|
221
|
-
classNames: {
|
|
222
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
223
|
-
default: undefined;
|
|
224
|
-
};
|
|
225
|
-
styles: {
|
|
226
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
227
|
-
default: undefined;
|
|
228
|
-
};
|
|
229
|
-
vars: {
|
|
230
|
-
type: (ObjectConstructor | FunctionConstructor)[];
|
|
231
|
-
default: undefined;
|
|
232
|
-
};
|
|
233
|
-
unstyled: {
|
|
234
|
-
type: BooleanConstructor;
|
|
235
|
-
default: boolean;
|
|
236
|
-
};
|
|
237
|
-
}>> & Readonly<{}>, {
|
|
238
|
-
radius: string | number;
|
|
239
|
-
classNames: Function | Record<string, any>;
|
|
240
|
-
styles: Function | Record<string, any>;
|
|
241
|
-
expanded: boolean;
|
|
242
|
-
background: string;
|
|
243
|
-
vars: Function | Record<string, any>;
|
|
244
|
-
unstyled: boolean;
|
|
245
|
-
withBorder: boolean;
|
|
246
|
-
defaultExpanded: boolean;
|
|
247
|
-
onExpandedChange: (expanded: boolean) => void;
|
|
248
|
-
controls: VNodeChild[] | (() => VNodeChild) | undefined;
|
|
249
|
-
copiedLabel: string;
|
|
250
|
-
copyLabel: string;
|
|
251
|
-
collapseCodeLabel: string;
|
|
252
|
-
expandCodeLabel: string;
|
|
253
|
-
maxCollapsedHeight: string | number;
|
|
254
|
-
withCopyButton: boolean;
|
|
255
|
-
withExpandButton: boolean;
|
|
256
|
-
withLineNumbers: boolean;
|
|
257
|
-
codeColorScheme: "light" | "dark" | (string & {}) | undefined;
|
|
258
|
-
getFileIcon: (fileName: string) => VNodeChild;
|
|
259
|
-
defaultActiveTab: number;
|
|
260
|
-
activeTab: number;
|
|
261
|
-
onTabChange: (tab: number) => void;
|
|
262
|
-
}, SlotsType<CodeHighlightTabsSlots>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
1
|
+
export declare const CodeHighlightTabs: {
|
|
2
|
+
new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{}> & Readonly<{
|
|
3
|
+
"onUpdate:expanded"?: ((expanded: boolean) => any) | undefined;
|
|
4
|
+
"onExpanded-change"?: ((expanded: boolean) => any) | undefined;
|
|
5
|
+
"onUpdate:activeTab"?: ((tab: number) => any) | undefined;
|
|
6
|
+
"onTab-change"?: ((tab: number) => any) | undefined;
|
|
7
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
|
+
"update:expanded": (expanded: boolean) => any;
|
|
9
|
+
"expanded-change": (expanded: boolean) => any;
|
|
10
|
+
"update:activeTab": (tab: number) => any;
|
|
11
|
+
"tab-change": (tab: number) => any;
|
|
12
|
+
}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
|
|
13
|
+
P: {};
|
|
14
|
+
B: {};
|
|
15
|
+
D: {};
|
|
16
|
+
C: {};
|
|
17
|
+
M: {};
|
|
18
|
+
Defaults: {};
|
|
19
|
+
}, Readonly<{}> & Readonly<{
|
|
20
|
+
"onUpdate:expanded"?: ((expanded: boolean) => any) | undefined;
|
|
21
|
+
"onExpanded-change"?: ((expanded: boolean) => any) | undefined;
|
|
22
|
+
"onUpdate:activeTab"?: ((tab: number) => any) | undefined;
|
|
23
|
+
"onTab-change"?: ((tab: number) => any) | undefined;
|
|
24
|
+
}>, {}, {}, {}, {}, {}>;
|
|
25
|
+
__isFragment?: never;
|
|
26
|
+
__isTeleport?: never;
|
|
27
|
+
__isSuspense?: never;
|
|
28
|
+
} & import("vue").ComponentOptionsBase<Readonly<{}> & Readonly<{
|
|
29
|
+
"onUpdate:expanded"?: ((expanded: boolean) => any) | undefined;
|
|
30
|
+
"onExpanded-change"?: ((expanded: boolean) => any) | undefined;
|
|
31
|
+
"onUpdate:activeTab"?: ((tab: number) => any) | undefined;
|
|
32
|
+
"onTab-change"?: ((tab: number) => any) | undefined;
|
|
33
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
34
|
+
"update:expanded": (expanded: boolean) => any;
|
|
35
|
+
"expanded-change": (expanded: boolean) => any;
|
|
36
|
+
"update:activeTab": (tab: number) => any;
|
|
37
|
+
"tab-change": (tab: number) => any;
|
|
38
|
+
}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
39
|
+
$slots: import("./CodeHighlightTabs.types").CodeHighlightTabsSlots;
|
|
40
|
+
}) & {
|
|
41
|
+
classes: Record<string, string>;
|
|
42
|
+
};
|
|
43
|
+
export type * from './CodeHighlightTabs.types';
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { VNodeChild } from 'vue';
|
|
2
|
+
import type { CodeHighlightExpandEmits, CodeHighlightSettings, CodeHighlightStylesNames } from '../CodeHighlight/CodeHighlight.types';
|
|
3
|
+
/** Available shiki languages for default Mantine shiki instance. Should be used only with *.mantine.dev projects. */
|
|
4
|
+
export type CodeHighlightDefaultLanguage = 'tsx' | 'scss' | 'html' | 'bash' | 'json';
|
|
5
|
+
export interface CodeHighlightTabsCode {
|
|
6
|
+
language?: CodeHighlightDefaultLanguage | (string & {});
|
|
7
|
+
code: string;
|
|
8
|
+
fileName?: string;
|
|
9
|
+
icon?: VNodeChild;
|
|
10
|
+
}
|
|
11
|
+
export type CodeHighlightTabsStylesNames = 'root' | 'files' | 'file' | 'fileIcon' | 'filesScrollarea' | CodeHighlightStylesNames;
|
|
12
|
+
export interface CodeHighlightTabsProps extends CodeHighlightSettings {
|
|
13
|
+
/** Code to highlight with meta data (file name and icon). */
|
|
14
|
+
code: CodeHighlightTabsCode[];
|
|
15
|
+
/** Function that returns icon based on file name. */
|
|
16
|
+
getFileIcon?: (fileName: string) => VNodeChild;
|
|
17
|
+
/** Default active tab index. */
|
|
18
|
+
defaultActiveTab?: number;
|
|
19
|
+
/** Index of controlled active tab state. */
|
|
20
|
+
activeTab?: number;
|
|
21
|
+
/** CSS classes applied to component elements. */
|
|
22
|
+
classNames?: any;
|
|
23
|
+
/** Inline styles applied to component elements. */
|
|
24
|
+
styles?: any;
|
|
25
|
+
/** CSS variables applied to component elements. */
|
|
26
|
+
vars?: any;
|
|
27
|
+
/** If set, all Mantine classes are removed from component elements. @default false */
|
|
28
|
+
unstyled?: boolean;
|
|
29
|
+
[key: string]: any;
|
|
30
|
+
}
|
|
31
|
+
export interface CodeHighlightTabsFactory {
|
|
32
|
+
props: CodeHighlightTabsProps;
|
|
33
|
+
stylesNames: CodeHighlightTabsStylesNames;
|
|
34
|
+
}
|
|
35
|
+
export interface CodeHighlightTabsSlots {
|
|
36
|
+
getFileIcon?: (input: {
|
|
37
|
+
fileName: string;
|
|
38
|
+
}) => VNodeChild;
|
|
39
|
+
controls?: () => VNodeChild;
|
|
40
|
+
}
|
|
41
|
+
/** Events emitted by `CodeHighlightTabs`. */
|
|
42
|
+
export interface CodeHighlightTabsEmits extends CodeHighlightExpandEmits {
|
|
43
|
+
/** Emitted when the active tab changes. */
|
|
44
|
+
'update:activeTab': [tab: number];
|
|
45
|
+
/** Emitted when the active tab changes. */
|
|
46
|
+
'tab-change': [tab: number];
|
|
47
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { CodeHighlightTabsSlots } from './CodeHighlightTabs.types';
|
|
2
|
+
type __VLS_Slots = CodeHighlightTabsSlots;
|
|
3
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
4
|
+
"update:expanded": (expanded: boolean) => any;
|
|
5
|
+
"expanded-change": (expanded: boolean) => any;
|
|
6
|
+
"update:activeTab": (tab: number) => any;
|
|
7
|
+
"tab-change": (tab: number) => any;
|
|
8
|
+
}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{
|
|
9
|
+
"onUpdate:expanded"?: ((expanded: boolean) => any) | undefined;
|
|
10
|
+
"onExpanded-change"?: ((expanded: boolean) => any) | undefined;
|
|
11
|
+
"onUpdate:activeTab"?: ((tab: number) => any) | undefined;
|
|
12
|
+
"onTab-change"?: ((tab: number) => any) | undefined;
|
|
13
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
15
|
+
declare const _default: typeof __VLS_export;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -1,40 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export interface FileIconSlots {
|
|
3
|
-
fileIcon?: () => VNodeChild;
|
|
4
|
-
getFileIcon?: (input: {
|
|
5
|
-
fileName: string;
|
|
6
|
-
}) => VNodeChild;
|
|
7
|
-
}
|
|
8
|
-
export declare const FileIcon: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
9
|
-
fileName: {
|
|
10
|
-
type: StringConstructor;
|
|
11
|
-
default: undefined;
|
|
12
|
-
};
|
|
13
|
-
getFileIcon: {
|
|
14
|
-
type: PropType<(fileName: string) => VNodeChild>;
|
|
15
|
-
default: undefined;
|
|
16
|
-
};
|
|
17
|
-
fileIcon: {
|
|
18
|
-
type: PropType<VNodeChild>;
|
|
19
|
-
default: undefined;
|
|
20
|
-
};
|
|
21
|
-
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
22
|
-
[key: string]: any;
|
|
23
|
-
}> | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
|
-
fileName: {
|
|
25
|
-
type: StringConstructor;
|
|
26
|
-
default: undefined;
|
|
27
|
-
};
|
|
28
|
-
getFileIcon: {
|
|
29
|
-
type: PropType<(fileName: string) => VNodeChild>;
|
|
30
|
-
default: undefined;
|
|
31
|
-
};
|
|
32
|
-
fileIcon: {
|
|
33
|
-
type: PropType<VNodeChild>;
|
|
34
|
-
default: undefined;
|
|
35
|
-
};
|
|
36
|
-
}>> & Readonly<{}>, {
|
|
37
|
-
fileName: string;
|
|
38
|
-
getFileIcon: (fileName: string) => VNodeChild;
|
|
39
|
-
fileIcon: VNodeChild;
|
|
40
|
-
}, SlotsType<FileIconSlots>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
1
|
+
export { default as FileIcon } from './FileIcon.vue';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { VNodeChild } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
fileName?: string;
|
|
4
|
+
getFileIcon?: (fileName: string) => VNodeChild;
|
|
5
|
+
fileIcon?: VNodeChild;
|
|
6
|
+
};
|
|
7
|
+
type __VLS_Slots = {
|
|
8
|
+
fileIcon?: () => VNodeChild;
|
|
9
|
+
getFileIcon?: (input: {
|
|
10
|
+
fileName: string;
|
|
11
|
+
}) => VNodeChild;
|
|
12
|
+
};
|
|
13
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
15
|
+
declare const _default: typeof __VLS_export;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
package/lib/index.d.mts
CHANGED
|
@@ -8,8 +8,8 @@ export { createHighlightJsAdapter } from './CodeHighlightProvider/adapters/highl
|
|
|
8
8
|
export { createShikiAdapter, stripShikiCodeBlocks, } from './CodeHighlightProvider/adapters/shiki-adapter';
|
|
9
9
|
export { plainTextAdapter } from './CodeHighlightProvider/adapters/plain-text-adapter';
|
|
10
10
|
export type { CodeHighlightAdapter, Highlighter, HighlighterInput, } from './CodeHighlightProvider/CodeHighlightProvider';
|
|
11
|
-
export type { CodeHighlightCssVariables, CodeHighlightFactory, CodeHighlightProps, CodeHighlightSettings, CodeHighlightSlots, CodeHighlightStylesNames, } from './CodeHighlight/CodeHighlight';
|
|
11
|
+
export type { CodeHighlightCssVariables, CodeHighlightEmits, CodeHighlightExpandEmits, CodeHighlightFactory, CodeHighlightProps, CodeHighlightSettings, CodeHighlightSlots, CodeHighlightStylesNames, } from './CodeHighlight/CodeHighlight';
|
|
12
12
|
export type { CodeHighlightContextValue } from './CodeHighlight/CodeHighlight.context';
|
|
13
|
-
export type { CodeHighlightControlProps } from './CodeHighlight/CodeHighlightControl/CodeHighlightControl';
|
|
13
|
+
export type { CodeHighlightControlEmits, CodeHighlightControlProps, } from './CodeHighlight/CodeHighlightControl/CodeHighlightControl';
|
|
14
14
|
export type { InlineCodeHighlightCssVariables, InlineCodeHighlightFactory, InlineCodeHighlightProps, InlineCodeHighlightStylesNames, } from './CodeHighlight/InlineCodeHighlight';
|
|
15
|
-
export type { CodeHighlightDefaultLanguage, CodeHighlightTabsCode, CodeHighlightTabsFactory, CodeHighlightTabsProps, CodeHighlightTabsSlots, CodeHighlightTabsStylesNames, } from './CodeHighlightTabs/CodeHighlightTabs';
|
|
15
|
+
export type { CodeHighlightDefaultLanguage, CodeHighlightTabsCode, CodeHighlightTabsEmits, CodeHighlightTabsFactory, CodeHighlightTabsProps, CodeHighlightTabsSlots, CodeHighlightTabsStylesNames, } from './CodeHighlightTabs/CodeHighlightTabs';
|
package/lib/index.d.ts
CHANGED
|
@@ -8,8 +8,8 @@ export { createHighlightJsAdapter } from './CodeHighlightProvider/adapters/highl
|
|
|
8
8
|
export { createShikiAdapter, stripShikiCodeBlocks, } from './CodeHighlightProvider/adapters/shiki-adapter';
|
|
9
9
|
export { plainTextAdapter } from './CodeHighlightProvider/adapters/plain-text-adapter';
|
|
10
10
|
export type { CodeHighlightAdapter, Highlighter, HighlighterInput, } from './CodeHighlightProvider/CodeHighlightProvider';
|
|
11
|
-
export type { CodeHighlightCssVariables, CodeHighlightFactory, CodeHighlightProps, CodeHighlightSettings, CodeHighlightSlots, CodeHighlightStylesNames, } from './CodeHighlight/CodeHighlight';
|
|
11
|
+
export type { CodeHighlightCssVariables, CodeHighlightEmits, CodeHighlightExpandEmits, CodeHighlightFactory, CodeHighlightProps, CodeHighlightSettings, CodeHighlightSlots, CodeHighlightStylesNames, } from './CodeHighlight/CodeHighlight';
|
|
12
12
|
export type { CodeHighlightContextValue } from './CodeHighlight/CodeHighlight.context';
|
|
13
|
-
export type { CodeHighlightControlProps } from './CodeHighlight/CodeHighlightControl/CodeHighlightControl';
|
|
13
|
+
export type { CodeHighlightControlEmits, CodeHighlightControlProps, } from './CodeHighlight/CodeHighlightControl/CodeHighlightControl';
|
|
14
14
|
export type { InlineCodeHighlightCssVariables, InlineCodeHighlightFactory, InlineCodeHighlightProps, InlineCodeHighlightStylesNames, } from './CodeHighlight/InlineCodeHighlight';
|
|
15
|
-
export type { CodeHighlightDefaultLanguage, CodeHighlightTabsCode, CodeHighlightTabsFactory, CodeHighlightTabsProps, CodeHighlightTabsSlots, CodeHighlightTabsStylesNames, } from './CodeHighlightTabs/CodeHighlightTabs';
|
|
15
|
+
export type { CodeHighlightDefaultLanguage, CodeHighlightTabsCode, CodeHighlightTabsEmits, CodeHighlightTabsFactory, CodeHighlightTabsProps, CodeHighlightTabsSlots, CodeHighlightTabsStylesNames, } from './CodeHighlightTabs/CodeHighlightTabs';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mantine-vue/code-highlight",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Vue code highlight components equivalent to @mantine/code-highlight",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"vue": "^3.5.0"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
|
42
|
-
"@mantine-vue/core": "
|
|
43
|
-
"@mantine-vue/hooks": "
|
|
42
|
+
"@mantine-vue/core": "3.1.0",
|
|
43
|
+
"@mantine-vue/hooks": "3.1.0",
|
|
44
44
|
"vue": "^3.5.0"
|
|
45
45
|
}
|
|
46
46
|
}
|