@vunk/plus 0.2.0 → 1.1.1
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/components/tables-v1/index.css +7 -0
- package/components/tables-v1/index.d.ts +5 -0
- package/components/tables-v1/index.mjs +431 -0
- package/components/tables-v1/src/ctx.d.ts +283 -0
- package/components/tables-v1/src/el-ctx.d.ts +272 -0
- package/components/tables-v1/src/index.vue.d.ts +2997 -0
- package/components/tables-v1/src/types.d.ts +4 -0
- package/components/tables-v1-checkbox/index.d.ts +4 -0
- package/components/tables-v1-checkbox/index.mjs +4115 -0
- package/components/tables-v1-checkbox/src/ctx.d.ts +281 -0
- package/components/tables-v1-checkbox/src/index.vue.d.ts +3759 -0
- package/components/tables-v1-checkbox/src/types.d.ts +1 -0
- package/components/typing-markdown/index.mjs +12 -1
- package/components/typing-markdown/src/ctx.d.ts +9 -0
- package/components/typing-markdown/src/index.vue.d.ts +9 -0
- package/composables/index.d.ts +18 -0
- package/composables/index.mjs +18 -0
- package/index.css +8 -0
- package/package.json +15 -4
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -24,6 +24,13 @@ const props = {
|
|
|
24
24
|
disabled: {
|
|
25
25
|
type: Boolean,
|
|
26
26
|
default: false
|
|
27
|
+
},
|
|
28
|
+
/**
|
|
29
|
+
* @description markdown-it 配置
|
|
30
|
+
*/
|
|
31
|
+
markdownItSetup: {
|
|
32
|
+
type: Function,
|
|
33
|
+
default: null
|
|
27
34
|
}
|
|
28
35
|
};
|
|
29
36
|
const emits = {
|
|
@@ -71,9 +78,13 @@ var _sfc_main = defineComponent({
|
|
|
71
78
|
}
|
|
72
79
|
return props2.source.substring(0, currentIndex.value);
|
|
73
80
|
});
|
|
81
|
+
const theMarkdownIt = markdownItPromise.then((md) => {
|
|
82
|
+
props2.markdownItSetup?.(md);
|
|
83
|
+
return md;
|
|
84
|
+
});
|
|
74
85
|
const htmlText = computedAsync(async () => {
|
|
75
86
|
currentText.value;
|
|
76
|
-
const md = await
|
|
87
|
+
const md = await theMarkdownIt;
|
|
77
88
|
return md.render(currentText.value);
|
|
78
89
|
}, "");
|
|
79
90
|
const isTyping = computed(() => {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type MarkdownIt from "markdown-it";
|
|
2
|
+
import { PropType } from "vue";
|
|
1
3
|
export declare const props: {
|
|
2
4
|
source: {
|
|
3
5
|
type: StringConstructor;
|
|
@@ -18,6 +20,13 @@ export declare const props: {
|
|
|
18
20
|
type: BooleanConstructor;
|
|
19
21
|
default: boolean;
|
|
20
22
|
};
|
|
23
|
+
/**
|
|
24
|
+
* @description markdown-it 配置
|
|
25
|
+
*/
|
|
26
|
+
markdownItSetup: {
|
|
27
|
+
type: PropType<(md: MarkdownIt) => void>;
|
|
28
|
+
default: any;
|
|
29
|
+
};
|
|
21
30
|
};
|
|
22
31
|
export declare const emits: {
|
|
23
32
|
typing: any;
|
|
@@ -15,6 +15,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
15
15
|
type: BooleanConstructor;
|
|
16
16
|
default: boolean;
|
|
17
17
|
};
|
|
18
|
+
markdownItSetup: {
|
|
19
|
+
type: import("vue").PropType<(md: import("markdown-it")) => void>;
|
|
20
|
+
default: any;
|
|
21
|
+
};
|
|
18
22
|
}>, {
|
|
19
23
|
htmlText: import("vue").Ref<string, string>;
|
|
20
24
|
isDebouncedTyping: Readonly<import("vue").Ref<boolean, boolean>>;
|
|
@@ -37,6 +41,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
37
41
|
type: BooleanConstructor;
|
|
38
42
|
default: boolean;
|
|
39
43
|
};
|
|
44
|
+
markdownItSetup: {
|
|
45
|
+
type: import("vue").PropType<(md: import("markdown-it")) => void>;
|
|
46
|
+
default: any;
|
|
47
|
+
};
|
|
40
48
|
}>> & Readonly<{
|
|
41
49
|
onTyping?: (...args: any[] | unknown[]) => any;
|
|
42
50
|
}>, {
|
|
@@ -44,5 +52,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
44
52
|
source: string;
|
|
45
53
|
pause: boolean;
|
|
46
54
|
delay: number;
|
|
55
|
+
markdownItSetup: (md: import("markdown-it")) => void;
|
|
47
56
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
48
57
|
export default _default;
|
package/composables/index.d.ts
CHANGED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const useElBreakpoints: () => {
|
|
2
|
+
breakpoints: Record<"sm" | "md" | "lg" | "xl", import("vue").Ref<boolean, boolean>> & {
|
|
3
|
+
greaterOrEqual: (k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">) => import("vue").Ref<boolean, boolean>;
|
|
4
|
+
smallerOrEqual: (k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">) => import("vue").Ref<boolean, boolean>;
|
|
5
|
+
greater(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): import("vue").Ref<boolean, boolean>;
|
|
6
|
+
smaller(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): import("vue").Ref<boolean, boolean>;
|
|
7
|
+
between(a: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">, b: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): import("vue").Ref<boolean, boolean>;
|
|
8
|
+
isGreater(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): boolean;
|
|
9
|
+
isGreaterOrEqual(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): boolean;
|
|
10
|
+
isSmaller(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): boolean;
|
|
11
|
+
isSmallerOrEqual(k: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): boolean;
|
|
12
|
+
isInBetween(a: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">, b: import("@vueuse/shared").MaybeRefOrGetter<"sm" | "md" | "lg" | "xl">): boolean;
|
|
13
|
+
current: () => import("vue").ComputedRef<string[]>;
|
|
14
|
+
active(): import("vue").ComputedRef<string>;
|
|
15
|
+
};
|
|
16
|
+
isMobile: import("vue").Ref<boolean, boolean>;
|
|
17
|
+
isDesktop: import("vue").Ref<boolean, boolean>;
|
|
18
|
+
};
|
package/composables/index.mjs
CHANGED
|
@@ -1 +1,19 @@
|
|
|
1
|
+
import { useBreakpoints } from '@vueuse/core';
|
|
1
2
|
|
|
3
|
+
const useElBreakpoints = () => {
|
|
4
|
+
const breakpoints = useBreakpoints({
|
|
5
|
+
sm: 768,
|
|
6
|
+
md: 992,
|
|
7
|
+
lg: 1200,
|
|
8
|
+
xl: 1920
|
|
9
|
+
});
|
|
10
|
+
const isMobile = breakpoints.smaller("lg");
|
|
11
|
+
const isDesktop = breakpoints.greaterOrEqual("lg");
|
|
12
|
+
return {
|
|
13
|
+
breakpoints,
|
|
14
|
+
isMobile,
|
|
15
|
+
isDesktop
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export { useElBreakpoints };
|
package/index.css
CHANGED
|
@@ -8,6 +8,14 @@
|
|
|
8
8
|
height: 100%;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
+
.vk-tables-v1-table{
|
|
12
|
+
height: 100%;
|
|
13
|
+
}
|
|
14
|
+
.vk-tables-v1-pagination-x {
|
|
15
|
+
display: flex;
|
|
16
|
+
justify-content: center;
|
|
17
|
+
}
|
|
18
|
+
|
|
11
19
|
.vk-typing-markdown.is-typing .is-last::after{
|
|
12
20
|
animation: blink 0.7s infinite;
|
|
13
21
|
content: '|';
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vunk/plus",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "1.1.1",
|
|
4
4
|
"description": "",
|
|
5
|
+
"author": "",
|
|
6
|
+
"license": "ISC",
|
|
7
|
+
"keywords": [],
|
|
5
8
|
"main": "index.esm.js",
|
|
6
9
|
"scripts": {
|
|
7
10
|
"build": "gulp -f gulpfile.ts"
|
|
8
11
|
},
|
|
9
|
-
"keywords": [],
|
|
10
|
-
"author": "",
|
|
11
|
-
"license": "ISC",
|
|
12
12
|
"module": "index.esm.js",
|
|
13
13
|
"exports": {
|
|
14
14
|
".": {
|
|
@@ -39,6 +39,14 @@
|
|
|
39
39
|
"import": "./components/typing-markdown/index.mjs",
|
|
40
40
|
"types": "./components/typing-markdown/index.d.ts"
|
|
41
41
|
},
|
|
42
|
+
"./components/tables-v1-checkbox": {
|
|
43
|
+
"import": "./components/tables-v1-checkbox/index.mjs",
|
|
44
|
+
"types": "./components/tables-v1-checkbox/index.d.ts"
|
|
45
|
+
},
|
|
46
|
+
"./components/tables-v1": {
|
|
47
|
+
"import": "./components/tables-v1/index.mjs",
|
|
48
|
+
"types": "./components/tables-v1/index.d.ts"
|
|
49
|
+
},
|
|
42
50
|
"./components/table-columns": {
|
|
43
51
|
"import": "./components/table-columns/index.mjs",
|
|
44
52
|
"types": "./components/table-columns/index.d.ts"
|
|
@@ -68,6 +76,9 @@
|
|
|
68
76
|
"./components/typing-markdown/index.css": {
|
|
69
77
|
"import": "./components/typing-markdown/index.css"
|
|
70
78
|
},
|
|
79
|
+
"./components/tables-v1/index.css": {
|
|
80
|
+
"import": "./components/tables-v1/index.css"
|
|
81
|
+
},
|
|
71
82
|
"./components/monaco-editor/index.css": {
|
|
72
83
|
"import": "./components/monaco-editor/index.css"
|
|
73
84
|
},
|