@tencentcloud/ai-desk-customer-vue 0.1.4 → 0.1.6
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/adapter-vue-web.ts +19 -41
- package/excluded-list.txt +3 -4
- package/package.json +12 -23
package/adapter-vue-web.ts
CHANGED
|
@@ -1,12 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import * as VueApi from '@vue/composition-api';
|
|
1
|
+
import * as Vue from 'vue';
|
|
2
|
+
import { TUIGlobal } from '@tencentcloud/universal-api';
|
|
4
3
|
|
|
5
|
-
let VueBasic: any = {
|
|
6
|
-
default: {},
|
|
7
|
-
};
|
|
8
|
-
VueBasic = _Vue ? _Vue : VueBasic;
|
|
9
4
|
let vueVersion: number;
|
|
5
|
+
let framework = 'vue2';
|
|
10
6
|
let createVNode = (
|
|
11
7
|
arg1: any,
|
|
12
8
|
arg2: any,
|
|
@@ -17,57 +13,39 @@ let render = (arg1: any, arg2: any) => {
|
|
|
17
13
|
return;
|
|
18
14
|
};
|
|
19
15
|
|
|
20
|
-
let defineProps = () => {
|
|
21
|
-
return;
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
let defineEmits = () => {
|
|
25
|
-
return;
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
let withDefaults = (arg: any) => {
|
|
29
|
-
return arg;
|
|
30
|
-
};
|
|
31
|
-
|
|
32
16
|
try {
|
|
33
17
|
if (
|
|
34
|
-
(
|
|
35
|
-
&& (
|
|
18
|
+
(Vue as any)?.default?.version
|
|
19
|
+
&& (Vue as any)?.default?.version?.startsWith('2.7.')
|
|
36
20
|
) {
|
|
37
21
|
// >= Vue 2.7.0
|
|
38
22
|
vueVersion = 2.7;
|
|
23
|
+
TUIGlobal.Vue = (Vue as any)?.getCurrentInstance()?.appContext?.app;
|
|
39
24
|
} else if (
|
|
40
|
-
(
|
|
41
|
-
&& (
|
|
25
|
+
(Vue as any)?.default?.version
|
|
26
|
+
&& (Vue as any)?.default?.version?.startsWith('2.')
|
|
42
27
|
) {
|
|
43
28
|
// < Vue 2.7.0
|
|
44
29
|
vueVersion = 2;
|
|
30
|
+
TUIGlobal.Vue = (Vue as any).default;
|
|
45
31
|
} else {
|
|
46
32
|
// >= Vue 3.0.0
|
|
47
33
|
vueVersion = 3;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
withDefaults = (VueBasic as any)?.withDefaults;
|
|
34
|
+
framework = 'vue3';
|
|
35
|
+
createVNode = (Vue as any)?.createVNode;
|
|
36
|
+
render = (Vue as any)?.render;
|
|
37
|
+
TUIGlobal.Vue = (Vue as any)?.getCurrentInstance()?.appContext?.app;
|
|
53
38
|
// exportedAPIOrigin = Vue;
|
|
54
39
|
}
|
|
55
40
|
} catch (error: any) {
|
|
56
41
|
// >= Vue 3.0.0
|
|
57
42
|
vueVersion = 3;
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
withDefaults = (VueBasic as any)?.withDefaults;
|
|
43
|
+
framework = 'vue3';
|
|
44
|
+
createVNode = (Vue as any)?.createVNode;
|
|
45
|
+
render = (Vue as any)?.render;
|
|
46
|
+
TUIGlobal.Vue = (Vue as any)?.getCurrentInstance()?.appContext?.app;
|
|
63
47
|
}
|
|
64
48
|
console.warn(`[adapter-vue]: vue version is ${vueVersion}`);
|
|
49
|
+
export { vueVersion, framework, render, createVNode };
|
|
65
50
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
if (vueVersion === 2) {
|
|
69
|
-
vue = VueApi;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
export { vueVersion, render, createVNode, defineProps, defineEmits, withDefaults };
|
|
73
|
-
export { vue };
|
|
51
|
+
export * from 'vue';
|
package/excluded-list.txt
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
.\node_modules\@tencentcloud\
|
|
2
|
-
.\node_modules\@tencentcloud\
|
|
3
|
-
.\node_modules\@tencentcloud\
|
|
4
|
-
.\node_modules\@tencentcloud\tui-customer-service-plugin\script
|
|
1
|
+
.\node_modules\@tencentcloud\ai-desk-customer-vue\node_modules
|
|
2
|
+
.\node_modules\@tencentcloud\ai-desk-customer-vue\package.json
|
|
3
|
+
.\node_modules\@tencentcloud\ai-desk-customer-vue\excluded-list.txt
|
|
5
4
|
|
|
6
5
|
|
package/package.json
CHANGED
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tencentcloud/ai-desk-customer-vue",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "chat uikit ai-desk-customer",
|
|
5
5
|
"main": "index",
|
|
6
6
|
"keywords": [
|
|
7
|
-
"
|
|
8
|
-
"
|
|
9
|
-
"
|
|
7
|
+
"customer service",
|
|
8
|
+
"ai",
|
|
9
|
+
"chatbot",
|
|
10
|
+
"vue",
|
|
10
11
|
"tencentcloud",
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"ai-desk-customer",
|
|
16
|
-
"customer-service"
|
|
12
|
+
"客服",
|
|
13
|
+
"智能客服",
|
|
14
|
+
"人工客服",
|
|
15
|
+
"智能机器人"
|
|
17
16
|
],
|
|
18
17
|
"scripts": {
|
|
19
18
|
"sync": "node ./script/fileCopy.js",
|
|
@@ -22,10 +21,10 @@
|
|
|
22
21
|
"publish:uniapp": "cd ../tui-customer-service-plugin-uniapp && ls && npm publish --access public"
|
|
23
22
|
},
|
|
24
23
|
"dependencies": {
|
|
25
|
-
"@tencentcloud/chat-uikit-engine": "
|
|
26
|
-
"@tencentcloud/tui-core": "
|
|
24
|
+
"@tencentcloud/chat-uikit-engine": "latest",
|
|
25
|
+
"@tencentcloud/tui-core": "latest",
|
|
27
26
|
"@tencentcloud/tui-emoji-plugin": "latest",
|
|
28
|
-
"@tencentcloud/universal-api": "
|
|
27
|
+
"@tencentcloud/universal-api": "latest",
|
|
29
28
|
"@tiptap/core": "2.0.0-beta.220",
|
|
30
29
|
"@tiptap/extension-document": "2.0.0-beta.220",
|
|
31
30
|
"@tiptap/extension-image": "2.0.0-beta.220",
|
|
@@ -36,22 +35,12 @@
|
|
|
36
35
|
"@tiptap/pm": "2.0.0-beta.220",
|
|
37
36
|
"@tiptap/suggestion": "2.0.0-beta.220",
|
|
38
37
|
"@types/lodash": "^4.14.202",
|
|
39
|
-
"@vue/composition-api": "^1.0.0-rc.1",
|
|
40
38
|
"dayjs": "^1.11.10",
|
|
41
39
|
"lodash": "^4.17.21",
|
|
42
40
|
"marked": "4.0.10",
|
|
43
41
|
"mp-html": "^2.5.0",
|
|
44
42
|
"vue-clipboard3": "2.0.0"
|
|
45
43
|
},
|
|
46
|
-
"peerDependencies": {
|
|
47
|
-
"@vue/composition-api": "^1.0.0-rc.1",
|
|
48
|
-
"vue": "^2.0.0 || >=3.0.0"
|
|
49
|
-
},
|
|
50
|
-
"peerDependenciesMeta": {
|
|
51
|
-
"@vue/composition-api": {
|
|
52
|
-
"optional": true
|
|
53
|
-
}
|
|
54
|
-
},
|
|
55
44
|
"publishConfig": {
|
|
56
45
|
"access": "public",
|
|
57
46
|
"registry": "https://registry.npmjs.org/"
|