@adminforth/text-complete 1.2.0 → 1.3.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/README.md +7 -0
- package/build.log +2 -2
- package/custom/completionInput.vue +62 -6
- package/custom/package-lock.json +130 -140
- package/custom/package.json +2 -2
- package/dist/custom/completionInput.vue +62 -6
- package/dist/custom/package-lock.json +130 -140
- package/dist/custom/package.json +2 -2
- package/dist/index.js +12 -1
- package/index.ts +14 -1
- package/package.json +2 -1
package/README.md
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# AdminForth TextComplete Plugin
|
|
2
|
+
|
|
3
|
+
<img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT" /> <img src="https://woodpecker.devforth.io/api/badges/3848/status.svg" alt="Build Status" /> <a href="https://www.npmjs.com/package/@adminforth/text-complete"> <img src="https://img.shields.io/npm/dt/@adminforth/text-complete" alt="npm downloads" /></a> <a href="https://www.npmjs.com/package/@adminforth/text-complete"><img src="https://img.shields.io/npm/v/@adminforth/text-complete" alt="npm version" /></a> <a href="https://www.npmjs.com/package/@adminforth/text-complete">
|
|
4
|
+
|
|
5
|
+
Allow to add an auto-complete text and string feature to adminforth fields using OpenAI Chat GPT models.
|
|
6
|
+
|
|
7
|
+
## For usage, see [AdminForth TextComplete Documentation](https://adminforth.dev/docs/tutorial/Plugins/text-complete/)
|
package/build.log
CHANGED
|
@@ -9,5 +9,5 @@ custom/package-lock.json
|
|
|
9
9
|
custom/package.json
|
|
10
10
|
custom/tsconfig.json
|
|
11
11
|
|
|
12
|
-
sent
|
|
13
|
-
total size is
|
|
12
|
+
sent 18,678 bytes received 96 bytes 37,548.00 bytes/sec
|
|
13
|
+
total size is 18,320 speedup is 0.98
|
|
@@ -1,24 +1,57 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
<div class="flex bg-gray-50 border border-gray-300 rounded-lg focus:ring-blue-500
|
|
3
|
+
focus:border-blue-500 w-full p-2.5 dark:bg-gray-700 dark:border-gray-600
|
|
4
|
+
dark:focus:ring-blue-500 dark:focus:border-blue-500 relative max-w-full">
|
|
5
|
+
<SuggestionInput
|
|
6
|
+
ref="suggestionInputRef"
|
|
7
|
+
class="w-full !border-none text-gray-900 text-sm dark:placeholder-gray-400 dark:text-white whitespace-normal mr-14"
|
|
7
8
|
v-model="currentValue"
|
|
8
9
|
:type="column.type"
|
|
9
10
|
:completionRequest="complete"
|
|
10
11
|
:debounceTime="meta.debounceTime"
|
|
11
12
|
/>
|
|
13
|
+
<div class="absolute right-2 bottom-1">
|
|
14
|
+
<Tooltip v-if="isUntouched">
|
|
15
|
+
<button
|
|
16
|
+
@click.stop="handleFocus"
|
|
17
|
+
@mousedown.prevent
|
|
18
|
+
class="text-white bg-gradient-to-r from-purple-500 via-purple-600 to-purple-700 hover:bg-gradient-to-br focus:ring-4 focus:outline-none focus:ring-purple-300 dark:focus:ring-purple-800
|
|
19
|
+
font-medium rounded-lg text-sm w-6 h-6 flex items-center justify-center">
|
|
20
|
+
<IconMagic class="w-4 h-4"/>
|
|
21
|
+
</button>
|
|
22
|
+
<template #tooltip>
|
|
23
|
+
Start completion
|
|
24
|
+
</template>
|
|
25
|
+
</Tooltip>
|
|
26
|
+
|
|
27
|
+
<Spinner v-else-if="isLoading" class="w-6 h-6" lightFill="#000000" darkFill="#ffffff" />
|
|
28
|
+
<Tooltip v-else>
|
|
29
|
+
<button
|
|
30
|
+
@click.stop="approveCompletion"
|
|
31
|
+
@mousedown.prevent
|
|
32
|
+
class="text-white bg-gradient-to-r from-purple-500 via-purple-600 to-purple-700 hover:bg-gradient-to-br focus:ring-4 focus:outline-none focus:ring-purple-300 dark:focus:ring-purple-800
|
|
33
|
+
font-medium rounded-lg text-xs w-14 h-6 flex items-center justify-center">
|
|
34
|
+
<IconArrowRightThin class="w-5 h-5"/>
|
|
35
|
+
<span class="scale-75 border border-white rounded-sm px-0.5 bg-white/25">TAB</span>
|
|
36
|
+
</button>
|
|
37
|
+
<template #tooltip>
|
|
38
|
+
Approve completion
|
|
39
|
+
</template>
|
|
40
|
+
</Tooltip>
|
|
41
|
+
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
12
44
|
</template>
|
|
13
45
|
|
|
14
46
|
<script setup lang="ts">
|
|
15
47
|
import { ref, onMounted, watch, Ref } from 'vue';
|
|
16
48
|
import { callAdminForthApi } from '@/utils';
|
|
17
49
|
import { AdminForthColumnCommon } from '@/types/Common';
|
|
50
|
+
import { Spinner, Tooltip } from '@/afcl';
|
|
51
|
+
import { IconMagic, IconCheck, IconArrowRightThin } from '@iconify-prerendered/vue-mdi';
|
|
18
52
|
import SuggestionInput from 'vue-suggestion-input';
|
|
19
53
|
import 'vue-suggestion-input/dist/style.css';
|
|
20
54
|
|
|
21
|
-
|
|
22
55
|
const props = defineProps<{
|
|
23
56
|
column: AdminForthColumnCommon,
|
|
24
57
|
record: any,
|
|
@@ -29,7 +62,10 @@ const emit = defineEmits([
|
|
|
29
62
|
'update:value',
|
|
30
63
|
]);
|
|
31
64
|
|
|
65
|
+
const isLoading = ref<boolean>(false);
|
|
66
|
+
const isUntouched = ref<boolean>(true);
|
|
32
67
|
const currentValue: Ref<string> = ref('');
|
|
68
|
+
const suggestionInputRef = ref<InstanceType<typeof SuggestionInput> | null>(null);
|
|
33
69
|
|
|
34
70
|
onMounted(() => {
|
|
35
71
|
currentValue.value = props.record[props.column.name] || '';
|
|
@@ -44,6 +80,8 @@ watch(() => props.record, (value) => {
|
|
|
44
80
|
});
|
|
45
81
|
|
|
46
82
|
async function complete(textBeforeCursor: string) {
|
|
83
|
+
isLoading.value = true;
|
|
84
|
+
isUntouched.value = false;
|
|
47
85
|
const res = await callAdminForthApi({
|
|
48
86
|
path: `/plugin/${props.meta.pluginInstanceId}/doComplete`,
|
|
49
87
|
method: 'POST',
|
|
@@ -52,9 +90,27 @@ async function complete(textBeforeCursor: string) {
|
|
|
52
90
|
},
|
|
53
91
|
});
|
|
54
92
|
|
|
93
|
+
isLoading.value = false;
|
|
94
|
+
|
|
55
95
|
return res.completion;
|
|
56
96
|
}
|
|
57
97
|
|
|
98
|
+
const approveCompletion = async () => {
|
|
99
|
+
if (suggestionInputRef.value) {
|
|
100
|
+
console.log('✋ approveCompletion', suggestionInputRef.value);
|
|
101
|
+
await suggestionInputRef.value.approveCompletion('all');
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
function handleFocus() {
|
|
106
|
+
if (suggestionInputRef.value) {
|
|
107
|
+
const editor = suggestionInputRef.value.$el.querySelector('.ql-editor');
|
|
108
|
+
if (editor) {
|
|
109
|
+
editor.focus();
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
58
114
|
</script>
|
|
59
115
|
|
|
60
116
|
<style>
|
package/custom/package-lock.json
CHANGED
|
@@ -8,35 +8,35 @@
|
|
|
8
8
|
"name": "custom",
|
|
9
9
|
"version": "1.0.0",
|
|
10
10
|
"license": "ISC",
|
|
11
|
-
"
|
|
12
|
-
"vue-suggestion-input": "^
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"vue-suggestion-input": "^1.0.9"
|
|
13
13
|
}
|
|
14
14
|
},
|
|
15
15
|
"node_modules/@babel/helper-string-parser": {
|
|
16
|
-
"version": "7.
|
|
17
|
-
"resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.
|
|
18
|
-
"integrity": "sha512-
|
|
19
|
-
"
|
|
16
|
+
"version": "7.25.9",
|
|
17
|
+
"resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.25.9.tgz",
|
|
18
|
+
"integrity": "sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==",
|
|
19
|
+
"license": "MIT",
|
|
20
20
|
"engines": {
|
|
21
21
|
"node": ">=6.9.0"
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"node_modules/@babel/helper-validator-identifier": {
|
|
25
|
-
"version": "7.
|
|
26
|
-
"resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.
|
|
27
|
-
"integrity": "sha512-
|
|
28
|
-
"
|
|
25
|
+
"version": "7.25.9",
|
|
26
|
+
"resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz",
|
|
27
|
+
"integrity": "sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==",
|
|
28
|
+
"license": "MIT",
|
|
29
29
|
"engines": {
|
|
30
30
|
"node": ">=6.9.0"
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
33
|
"node_modules/@babel/parser": {
|
|
34
|
-
"version": "7.
|
|
35
|
-
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.
|
|
36
|
-
"integrity": "sha512-
|
|
37
|
-
"
|
|
34
|
+
"version": "7.27.0",
|
|
35
|
+
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.27.0.tgz",
|
|
36
|
+
"integrity": "sha512-iaepho73/2Pz7w2eMS0Q5f83+0RKI7i4xmiYeBmDzfRVbQtTOG7Ts0S4HzJVsTMGI9keU8rNfuZr8DKfSt7Yyg==",
|
|
37
|
+
"license": "MIT",
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@babel/types": "^7.
|
|
39
|
+
"@babel/types": "^7.27.0"
|
|
40
40
|
},
|
|
41
41
|
"bin": {
|
|
42
42
|
"parser": "bin/babel-parser.js"
|
|
@@ -46,14 +46,13 @@
|
|
|
46
46
|
}
|
|
47
47
|
},
|
|
48
48
|
"node_modules/@babel/types": {
|
|
49
|
-
"version": "7.
|
|
50
|
-
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.
|
|
51
|
-
"integrity": "sha512-
|
|
52
|
-
"
|
|
49
|
+
"version": "7.27.0",
|
|
50
|
+
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.27.0.tgz",
|
|
51
|
+
"integrity": "sha512-H45s8fVLYjbhFH62dIJ3WtmJ6RSPt/3DRO0ZcT2SUiYiQyz3BLVb9ADEnLl91m74aQPS3AzzeajZHYOalWe3bg==",
|
|
52
|
+
"license": "MIT",
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@babel/helper-string-parser": "^7.
|
|
55
|
-
"@babel/helper-validator-identifier": "^7.
|
|
56
|
-
"to-fast-properties": "^2.0.0"
|
|
54
|
+
"@babel/helper-string-parser": "^7.25.9",
|
|
55
|
+
"@babel/helper-validator-identifier": "^7.25.9"
|
|
57
56
|
},
|
|
58
57
|
"engines": {
|
|
59
58
|
"node": ">=6.9.0"
|
|
@@ -63,119 +62,119 @@
|
|
|
63
62
|
"version": "1.5.0",
|
|
64
63
|
"resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz",
|
|
65
64
|
"integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==",
|
|
66
|
-
"
|
|
65
|
+
"license": "MIT"
|
|
67
66
|
},
|
|
68
67
|
"node_modules/@vue/compiler-core": {
|
|
69
|
-
"version": "3.
|
|
70
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.
|
|
71
|
-
"integrity": "sha512-
|
|
72
|
-
"
|
|
68
|
+
"version": "3.5.13",
|
|
69
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.5.13.tgz",
|
|
70
|
+
"integrity": "sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==",
|
|
71
|
+
"license": "MIT",
|
|
73
72
|
"dependencies": {
|
|
74
|
-
"@babel/parser": "^7.
|
|
75
|
-
"@vue/shared": "3.
|
|
73
|
+
"@babel/parser": "^7.25.3",
|
|
74
|
+
"@vue/shared": "3.5.13",
|
|
76
75
|
"entities": "^4.5.0",
|
|
77
76
|
"estree-walker": "^2.0.2",
|
|
78
77
|
"source-map-js": "^1.2.0"
|
|
79
78
|
}
|
|
80
79
|
},
|
|
81
80
|
"node_modules/@vue/compiler-dom": {
|
|
82
|
-
"version": "3.
|
|
83
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.
|
|
84
|
-
"integrity": "sha512-
|
|
85
|
-
"
|
|
81
|
+
"version": "3.5.13",
|
|
82
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.5.13.tgz",
|
|
83
|
+
"integrity": "sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==",
|
|
84
|
+
"license": "MIT",
|
|
86
85
|
"dependencies": {
|
|
87
|
-
"@vue/compiler-core": "3.
|
|
88
|
-
"@vue/shared": "3.
|
|
86
|
+
"@vue/compiler-core": "3.5.13",
|
|
87
|
+
"@vue/shared": "3.5.13"
|
|
89
88
|
}
|
|
90
89
|
},
|
|
91
90
|
"node_modules/@vue/compiler-sfc": {
|
|
92
|
-
"version": "3.
|
|
93
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.
|
|
94
|
-
"integrity": "sha512-
|
|
95
|
-
"
|
|
91
|
+
"version": "3.5.13",
|
|
92
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.5.13.tgz",
|
|
93
|
+
"integrity": "sha512-6VdaljMpD82w6c2749Zhf5T9u5uLBWKnVue6XWxprDobftnletJ8+oel7sexFfM3qIxNmVE7LSFGTpv6obNyaQ==",
|
|
94
|
+
"license": "MIT",
|
|
96
95
|
"dependencies": {
|
|
97
|
-
"@babel/parser": "^7.
|
|
98
|
-
"@vue/compiler-core": "3.
|
|
99
|
-
"@vue/compiler-dom": "3.
|
|
100
|
-
"@vue/compiler-ssr": "3.
|
|
101
|
-
"@vue/shared": "3.
|
|
96
|
+
"@babel/parser": "^7.25.3",
|
|
97
|
+
"@vue/compiler-core": "3.5.13",
|
|
98
|
+
"@vue/compiler-dom": "3.5.13",
|
|
99
|
+
"@vue/compiler-ssr": "3.5.13",
|
|
100
|
+
"@vue/shared": "3.5.13",
|
|
102
101
|
"estree-walker": "^2.0.2",
|
|
103
|
-
"magic-string": "^0.30.
|
|
104
|
-
"postcss": "^8.4.
|
|
102
|
+
"magic-string": "^0.30.11",
|
|
103
|
+
"postcss": "^8.4.48",
|
|
105
104
|
"source-map-js": "^1.2.0"
|
|
106
105
|
}
|
|
107
106
|
},
|
|
108
107
|
"node_modules/@vue/compiler-ssr": {
|
|
109
|
-
"version": "3.
|
|
110
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.
|
|
111
|
-
"integrity": "sha512-
|
|
112
|
-
"
|
|
108
|
+
"version": "3.5.13",
|
|
109
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.5.13.tgz",
|
|
110
|
+
"integrity": "sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==",
|
|
111
|
+
"license": "MIT",
|
|
113
112
|
"dependencies": {
|
|
114
|
-
"@vue/compiler-dom": "3.
|
|
115
|
-
"@vue/shared": "3.
|
|
113
|
+
"@vue/compiler-dom": "3.5.13",
|
|
114
|
+
"@vue/shared": "3.5.13"
|
|
116
115
|
}
|
|
117
116
|
},
|
|
118
117
|
"node_modules/@vue/reactivity": {
|
|
119
|
-
"version": "3.
|
|
120
|
-
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.
|
|
121
|
-
"integrity": "sha512-
|
|
122
|
-
"
|
|
118
|
+
"version": "3.5.13",
|
|
119
|
+
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.5.13.tgz",
|
|
120
|
+
"integrity": "sha512-NaCwtw8o48B9I6L1zl2p41OHo/2Z4wqYGGIK1Khu5T7yxrn+ATOixn/Udn2m+6kZKB/J7cuT9DbWWhRxqixACg==",
|
|
121
|
+
"license": "MIT",
|
|
123
122
|
"dependencies": {
|
|
124
|
-
"@vue/shared": "3.
|
|
123
|
+
"@vue/shared": "3.5.13"
|
|
125
124
|
}
|
|
126
125
|
},
|
|
127
126
|
"node_modules/@vue/runtime-core": {
|
|
128
|
-
"version": "3.
|
|
129
|
-
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.
|
|
130
|
-
"integrity": "sha512-
|
|
131
|
-
"
|
|
127
|
+
"version": "3.5.13",
|
|
128
|
+
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.5.13.tgz",
|
|
129
|
+
"integrity": "sha512-Fj4YRQ3Az0WTZw1sFe+QDb0aXCerigEpw418pw1HBUKFtnQHWzwojaukAs2X/c9DQz4MQ4bsXTGlcpGxU/RCIw==",
|
|
130
|
+
"license": "MIT",
|
|
132
131
|
"dependencies": {
|
|
133
|
-
"@vue/reactivity": "3.
|
|
134
|
-
"@vue/shared": "3.
|
|
132
|
+
"@vue/reactivity": "3.5.13",
|
|
133
|
+
"@vue/shared": "3.5.13"
|
|
135
134
|
}
|
|
136
135
|
},
|
|
137
136
|
"node_modules/@vue/runtime-dom": {
|
|
138
|
-
"version": "3.
|
|
139
|
-
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.
|
|
140
|
-
"integrity": "sha512-
|
|
141
|
-
"
|
|
137
|
+
"version": "3.5.13",
|
|
138
|
+
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.5.13.tgz",
|
|
139
|
+
"integrity": "sha512-dLaj94s93NYLqjLiyFzVs9X6dWhTdAlEAciC3Moq7gzAc13VJUdCnjjRurNM6uTLFATRHexHCTu/Xp3eW6yoog==",
|
|
140
|
+
"license": "MIT",
|
|
142
141
|
"dependencies": {
|
|
143
|
-
"@vue/reactivity": "3.
|
|
144
|
-
"@vue/runtime-core": "3.
|
|
145
|
-
"@vue/shared": "3.
|
|
142
|
+
"@vue/reactivity": "3.5.13",
|
|
143
|
+
"@vue/runtime-core": "3.5.13",
|
|
144
|
+
"@vue/shared": "3.5.13",
|
|
146
145
|
"csstype": "^3.1.3"
|
|
147
146
|
}
|
|
148
147
|
},
|
|
149
148
|
"node_modules/@vue/server-renderer": {
|
|
150
|
-
"version": "3.
|
|
151
|
-
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.
|
|
152
|
-
"integrity": "sha512-
|
|
153
|
-
"
|
|
149
|
+
"version": "3.5.13",
|
|
150
|
+
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.5.13.tgz",
|
|
151
|
+
"integrity": "sha512-wAi4IRJV/2SAW3htkTlB+dHeRmpTiVIK1OGLWV1yeStVSebSQQOwGwIq0D3ZIoBj2C2qpgz5+vX9iEBkTdk5YA==",
|
|
152
|
+
"license": "MIT",
|
|
154
153
|
"dependencies": {
|
|
155
|
-
"@vue/compiler-ssr": "3.
|
|
156
|
-
"@vue/shared": "3.
|
|
154
|
+
"@vue/compiler-ssr": "3.5.13",
|
|
155
|
+
"@vue/shared": "3.5.13"
|
|
157
156
|
},
|
|
158
157
|
"peerDependencies": {
|
|
159
|
-
"vue": "3.
|
|
158
|
+
"vue": "3.5.13"
|
|
160
159
|
}
|
|
161
160
|
},
|
|
162
161
|
"node_modules/@vue/shared": {
|
|
163
|
-
"version": "3.
|
|
164
|
-
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.
|
|
165
|
-
"integrity": "sha512
|
|
166
|
-
"
|
|
162
|
+
"version": "3.5.13",
|
|
163
|
+
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.5.13.tgz",
|
|
164
|
+
"integrity": "sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==",
|
|
165
|
+
"license": "MIT"
|
|
167
166
|
},
|
|
168
167
|
"node_modules/csstype": {
|
|
169
168
|
"version": "3.1.3",
|
|
170
169
|
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz",
|
|
171
170
|
"integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==",
|
|
172
|
-
"
|
|
171
|
+
"license": "MIT"
|
|
173
172
|
},
|
|
174
173
|
"node_modules/entities": {
|
|
175
174
|
"version": "4.5.0",
|
|
176
175
|
"resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz",
|
|
177
176
|
"integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==",
|
|
178
|
-
"
|
|
177
|
+
"license": "BSD-2-Clause",
|
|
179
178
|
"engines": {
|
|
180
179
|
"node": ">=0.12"
|
|
181
180
|
},
|
|
@@ -187,58 +186,59 @@
|
|
|
187
186
|
"version": "2.0.2",
|
|
188
187
|
"resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz",
|
|
189
188
|
"integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==",
|
|
190
|
-
"
|
|
189
|
+
"license": "MIT"
|
|
191
190
|
},
|
|
192
191
|
"node_modules/eventemitter3": {
|
|
193
192
|
"version": "5.0.1",
|
|
194
193
|
"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz",
|
|
195
194
|
"integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==",
|
|
196
|
-
"
|
|
195
|
+
"license": "MIT"
|
|
197
196
|
},
|
|
198
197
|
"node_modules/fast-diff": {
|
|
199
198
|
"version": "1.3.0",
|
|
200
199
|
"resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz",
|
|
201
200
|
"integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==",
|
|
202
|
-
"
|
|
201
|
+
"license": "Apache-2.0"
|
|
203
202
|
},
|
|
204
203
|
"node_modules/lodash-es": {
|
|
205
204
|
"version": "4.17.21",
|
|
206
205
|
"resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.21.tgz",
|
|
207
206
|
"integrity": "sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==",
|
|
208
|
-
"
|
|
207
|
+
"license": "MIT"
|
|
209
208
|
},
|
|
210
209
|
"node_modules/lodash.clonedeep": {
|
|
211
210
|
"version": "4.5.0",
|
|
212
211
|
"resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz",
|
|
213
212
|
"integrity": "sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==",
|
|
214
|
-
"
|
|
213
|
+
"license": "MIT"
|
|
215
214
|
},
|
|
216
215
|
"node_modules/lodash.isequal": {
|
|
217
216
|
"version": "4.5.0",
|
|
218
217
|
"resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz",
|
|
219
218
|
"integrity": "sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==",
|
|
220
|
-
"
|
|
219
|
+
"deprecated": "This package is deprecated. Use require('node:util').isDeepStrictEqual instead.",
|
|
220
|
+
"license": "MIT"
|
|
221
221
|
},
|
|
222
222
|
"node_modules/magic-string": {
|
|
223
|
-
"version": "0.30.
|
|
224
|
-
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.
|
|
225
|
-
"integrity": "sha512
|
|
226
|
-
"
|
|
223
|
+
"version": "0.30.17",
|
|
224
|
+
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.17.tgz",
|
|
225
|
+
"integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==",
|
|
226
|
+
"license": "MIT",
|
|
227
227
|
"dependencies": {
|
|
228
228
|
"@jridgewell/sourcemap-codec": "^1.5.0"
|
|
229
229
|
}
|
|
230
230
|
},
|
|
231
231
|
"node_modules/nanoid": {
|
|
232
|
-
"version": "3.3.
|
|
233
|
-
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.
|
|
234
|
-
"integrity": "sha512-
|
|
235
|
-
"dev": true,
|
|
232
|
+
"version": "3.3.11",
|
|
233
|
+
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz",
|
|
234
|
+
"integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==",
|
|
236
235
|
"funding": [
|
|
237
236
|
{
|
|
238
237
|
"type": "github",
|
|
239
238
|
"url": "https://github.com/sponsors/ai"
|
|
240
239
|
}
|
|
241
240
|
],
|
|
241
|
+
"license": "MIT",
|
|
242
242
|
"bin": {
|
|
243
243
|
"nanoid": "bin/nanoid.cjs"
|
|
244
244
|
},
|
|
@@ -250,19 +250,18 @@
|
|
|
250
250
|
"version": "3.0.0",
|
|
251
251
|
"resolved": "https://registry.npmjs.org/parchment/-/parchment-3.0.0.tgz",
|
|
252
252
|
"integrity": "sha512-HUrJFQ/StvgmXRcQ1ftY6VEZUq3jA2t9ncFN4F84J/vN0/FPpQF+8FKXb3l6fLces6q0uOHj6NJn+2xvZnxO6A==",
|
|
253
|
-
"
|
|
253
|
+
"license": "BSD-3-Clause"
|
|
254
254
|
},
|
|
255
255
|
"node_modules/picocolors": {
|
|
256
|
-
"version": "1.
|
|
257
|
-
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.
|
|
258
|
-
"integrity": "sha512-
|
|
259
|
-
"
|
|
256
|
+
"version": "1.1.1",
|
|
257
|
+
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
|
258
|
+
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
|
|
259
|
+
"license": "ISC"
|
|
260
260
|
},
|
|
261
261
|
"node_modules/postcss": {
|
|
262
|
-
"version": "8.
|
|
263
|
-
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.
|
|
264
|
-
"integrity": "sha512-
|
|
265
|
-
"dev": true,
|
|
262
|
+
"version": "8.5.3",
|
|
263
|
+
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz",
|
|
264
|
+
"integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==",
|
|
266
265
|
"funding": [
|
|
267
266
|
{
|
|
268
267
|
"type": "opencollective",
|
|
@@ -277,20 +276,21 @@
|
|
|
277
276
|
"url": "https://github.com/sponsors/ai"
|
|
278
277
|
}
|
|
279
278
|
],
|
|
279
|
+
"license": "MIT",
|
|
280
280
|
"dependencies": {
|
|
281
|
-
"nanoid": "^3.3.
|
|
282
|
-
"picocolors": "^1.
|
|
283
|
-
"source-map-js": "^1.2.
|
|
281
|
+
"nanoid": "^3.3.8",
|
|
282
|
+
"picocolors": "^1.1.1",
|
|
283
|
+
"source-map-js": "^1.2.1"
|
|
284
284
|
},
|
|
285
285
|
"engines": {
|
|
286
286
|
"node": "^10 || ^12 || >=14"
|
|
287
287
|
}
|
|
288
288
|
},
|
|
289
289
|
"node_modules/quill": {
|
|
290
|
-
"version": "2.0.
|
|
291
|
-
"resolved": "https://registry.npmjs.org/quill/-/quill-2.0.
|
|
292
|
-
"integrity": "sha512-
|
|
293
|
-
"
|
|
290
|
+
"version": "2.0.3",
|
|
291
|
+
"resolved": "https://registry.npmjs.org/quill/-/quill-2.0.3.tgz",
|
|
292
|
+
"integrity": "sha512-xEYQBqfYx/sfb33VJiKnSJp8ehloavImQ2A6564GAbqG55PGw1dAWUn1MUbQB62t0azawUS2CZZhWCjO8gRvTw==",
|
|
293
|
+
"license": "BSD-3-Clause",
|
|
294
294
|
"dependencies": {
|
|
295
295
|
"eventemitter3": "^5.0.1",
|
|
296
296
|
"lodash-es": "^4.17.21",
|
|
@@ -305,7 +305,7 @@
|
|
|
305
305
|
"version": "5.1.0",
|
|
306
306
|
"resolved": "https://registry.npmjs.org/quill-delta/-/quill-delta-5.1.0.tgz",
|
|
307
307
|
"integrity": "sha512-X74oCeRI4/p0ucjb5Ma8adTXd9Scumz367kkMK5V/IatcX6A0vlgLgKbzXWy5nZmCGeNJm2oQX0d2Eqj+ZIlCA==",
|
|
308
|
-
"
|
|
308
|
+
"license": "MIT",
|
|
309
309
|
"dependencies": {
|
|
310
310
|
"fast-diff": "^1.3.0",
|
|
311
311
|
"lodash.clonedeep": "^4.5.0",
|
|
@@ -316,34 +316,25 @@
|
|
|
316
316
|
}
|
|
317
317
|
},
|
|
318
318
|
"node_modules/source-map-js": {
|
|
319
|
-
"version": "1.2.
|
|
320
|
-
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.
|
|
321
|
-
"integrity": "sha512-
|
|
322
|
-
"
|
|
319
|
+
"version": "1.2.1",
|
|
320
|
+
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
|
321
|
+
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
|
322
|
+
"license": "BSD-3-Clause",
|
|
323
323
|
"engines": {
|
|
324
324
|
"node": ">=0.10.0"
|
|
325
325
|
}
|
|
326
326
|
},
|
|
327
|
-
"node_modules/to-fast-properties": {
|
|
328
|
-
"version": "2.0.0",
|
|
329
|
-
"resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz",
|
|
330
|
-
"integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==",
|
|
331
|
-
"dev": true,
|
|
332
|
-
"engines": {
|
|
333
|
-
"node": ">=4"
|
|
334
|
-
}
|
|
335
|
-
},
|
|
336
327
|
"node_modules/vue": {
|
|
337
|
-
"version": "3.
|
|
338
|
-
"resolved": "https://registry.npmjs.org/vue/-/vue-3.
|
|
339
|
-
"integrity": "sha512
|
|
340
|
-
"
|
|
328
|
+
"version": "3.5.13",
|
|
329
|
+
"resolved": "https://registry.npmjs.org/vue/-/vue-3.5.13.tgz",
|
|
330
|
+
"integrity": "sha512-wmeiSMxkZCSc+PM2w2VRsOYAZC8GdipNFRTsLSfodVqI9mbejKeXEGr8SckuLnrQPGe3oJN5c3K0vpoU9q/wCQ==",
|
|
331
|
+
"license": "MIT",
|
|
341
332
|
"dependencies": {
|
|
342
|
-
"@vue/compiler-dom": "3.
|
|
343
|
-
"@vue/compiler-sfc": "3.
|
|
344
|
-
"@vue/runtime-dom": "3.
|
|
345
|
-
"@vue/server-renderer": "3.
|
|
346
|
-
"@vue/shared": "3.
|
|
333
|
+
"@vue/compiler-dom": "3.5.13",
|
|
334
|
+
"@vue/compiler-sfc": "3.5.13",
|
|
335
|
+
"@vue/runtime-dom": "3.5.13",
|
|
336
|
+
"@vue/server-renderer": "3.5.13",
|
|
337
|
+
"@vue/shared": "3.5.13"
|
|
347
338
|
},
|
|
348
339
|
"peerDependencies": {
|
|
349
340
|
"typescript": "*"
|
|
@@ -355,10 +346,9 @@
|
|
|
355
346
|
}
|
|
356
347
|
},
|
|
357
348
|
"node_modules/vue-suggestion-input": {
|
|
358
|
-
"version": "
|
|
359
|
-
"resolved": "https://registry.npmjs.org/vue-suggestion-input/-/vue-suggestion-input-
|
|
360
|
-
"integrity": "sha512-
|
|
361
|
-
"dev": true,
|
|
349
|
+
"version": "1.0.9",
|
|
350
|
+
"resolved": "https://registry.npmjs.org/vue-suggestion-input/-/vue-suggestion-input-1.0.9.tgz",
|
|
351
|
+
"integrity": "sha512-arnk/TT1KGrnD1hHoRpBM/upp22RNswdgUHvmTFnwW/Wdej5au2U5ogXRdLKgcBb/erxs2curZMjWiqbxpYo8g==",
|
|
362
352
|
"dependencies": {
|
|
363
353
|
"quill": "^2.0.2",
|
|
364
354
|
"vue": "^3.4.31"
|
package/custom/package.json
CHANGED
|
@@ -1,24 +1,57 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
<div class="flex bg-gray-50 border border-gray-300 rounded-lg focus:ring-blue-500
|
|
3
|
+
focus:border-blue-500 w-full p-2.5 dark:bg-gray-700 dark:border-gray-600
|
|
4
|
+
dark:focus:ring-blue-500 dark:focus:border-blue-500 relative max-w-full">
|
|
5
|
+
<SuggestionInput
|
|
6
|
+
ref="suggestionInputRef"
|
|
7
|
+
class="w-full !border-none text-gray-900 text-sm dark:placeholder-gray-400 dark:text-white whitespace-normal mr-14"
|
|
7
8
|
v-model="currentValue"
|
|
8
9
|
:type="column.type"
|
|
9
10
|
:completionRequest="complete"
|
|
10
11
|
:debounceTime="meta.debounceTime"
|
|
11
12
|
/>
|
|
13
|
+
<div class="absolute right-2 bottom-1">
|
|
14
|
+
<Tooltip v-if="isUntouched">
|
|
15
|
+
<button
|
|
16
|
+
@click.stop="handleFocus"
|
|
17
|
+
@mousedown.prevent
|
|
18
|
+
class="text-white bg-gradient-to-r from-purple-500 via-purple-600 to-purple-700 hover:bg-gradient-to-br focus:ring-4 focus:outline-none focus:ring-purple-300 dark:focus:ring-purple-800
|
|
19
|
+
font-medium rounded-lg text-sm w-6 h-6 flex items-center justify-center">
|
|
20
|
+
<IconMagic class="w-4 h-4"/>
|
|
21
|
+
</button>
|
|
22
|
+
<template #tooltip>
|
|
23
|
+
Start completion
|
|
24
|
+
</template>
|
|
25
|
+
</Tooltip>
|
|
26
|
+
|
|
27
|
+
<Spinner v-else-if="isLoading" class="w-6 h-6" lightFill="#000000" darkFill="#ffffff" />
|
|
28
|
+
<Tooltip v-else>
|
|
29
|
+
<button
|
|
30
|
+
@click.stop="approveCompletion"
|
|
31
|
+
@mousedown.prevent
|
|
32
|
+
class="text-white bg-gradient-to-r from-purple-500 via-purple-600 to-purple-700 hover:bg-gradient-to-br focus:ring-4 focus:outline-none focus:ring-purple-300 dark:focus:ring-purple-800
|
|
33
|
+
font-medium rounded-lg text-xs w-14 h-6 flex items-center justify-center">
|
|
34
|
+
<IconArrowRightThin class="w-5 h-5"/>
|
|
35
|
+
<span class="scale-75 border border-white rounded-sm px-0.5 bg-white/25">TAB</span>
|
|
36
|
+
</button>
|
|
37
|
+
<template #tooltip>
|
|
38
|
+
Approve completion
|
|
39
|
+
</template>
|
|
40
|
+
</Tooltip>
|
|
41
|
+
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
12
44
|
</template>
|
|
13
45
|
|
|
14
46
|
<script setup lang="ts">
|
|
15
47
|
import { ref, onMounted, watch, Ref } from 'vue';
|
|
16
48
|
import { callAdminForthApi } from '@/utils';
|
|
17
49
|
import { AdminForthColumnCommon } from '@/types/Common';
|
|
50
|
+
import { Spinner, Tooltip } from '@/afcl';
|
|
51
|
+
import { IconMagic, IconCheck, IconArrowRightThin } from '@iconify-prerendered/vue-mdi';
|
|
18
52
|
import SuggestionInput from 'vue-suggestion-input';
|
|
19
53
|
import 'vue-suggestion-input/dist/style.css';
|
|
20
54
|
|
|
21
|
-
|
|
22
55
|
const props = defineProps<{
|
|
23
56
|
column: AdminForthColumnCommon,
|
|
24
57
|
record: any,
|
|
@@ -29,7 +62,10 @@ const emit = defineEmits([
|
|
|
29
62
|
'update:value',
|
|
30
63
|
]);
|
|
31
64
|
|
|
65
|
+
const isLoading = ref<boolean>(false);
|
|
66
|
+
const isUntouched = ref<boolean>(true);
|
|
32
67
|
const currentValue: Ref<string> = ref('');
|
|
68
|
+
const suggestionInputRef = ref<InstanceType<typeof SuggestionInput> | null>(null);
|
|
33
69
|
|
|
34
70
|
onMounted(() => {
|
|
35
71
|
currentValue.value = props.record[props.column.name] || '';
|
|
@@ -44,6 +80,8 @@ watch(() => props.record, (value) => {
|
|
|
44
80
|
});
|
|
45
81
|
|
|
46
82
|
async function complete(textBeforeCursor: string) {
|
|
83
|
+
isLoading.value = true;
|
|
84
|
+
isUntouched.value = false;
|
|
47
85
|
const res = await callAdminForthApi({
|
|
48
86
|
path: `/plugin/${props.meta.pluginInstanceId}/doComplete`,
|
|
49
87
|
method: 'POST',
|
|
@@ -52,9 +90,27 @@ async function complete(textBeforeCursor: string) {
|
|
|
52
90
|
},
|
|
53
91
|
});
|
|
54
92
|
|
|
93
|
+
isLoading.value = false;
|
|
94
|
+
|
|
55
95
|
return res.completion;
|
|
56
96
|
}
|
|
57
97
|
|
|
98
|
+
const approveCompletion = async () => {
|
|
99
|
+
if (suggestionInputRef.value) {
|
|
100
|
+
console.log('✋ approveCompletion', suggestionInputRef.value);
|
|
101
|
+
await suggestionInputRef.value.approveCompletion('all');
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
function handleFocus() {
|
|
106
|
+
if (suggestionInputRef.value) {
|
|
107
|
+
const editor = suggestionInputRef.value.$el.querySelector('.ql-editor');
|
|
108
|
+
if (editor) {
|
|
109
|
+
editor.focus();
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
58
114
|
</script>
|
|
59
115
|
|
|
60
116
|
<style>
|
|
@@ -8,35 +8,35 @@
|
|
|
8
8
|
"name": "custom",
|
|
9
9
|
"version": "1.0.0",
|
|
10
10
|
"license": "ISC",
|
|
11
|
-
"
|
|
12
|
-
"vue-suggestion-input": "^
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"vue-suggestion-input": "^1.0.9"
|
|
13
13
|
}
|
|
14
14
|
},
|
|
15
15
|
"node_modules/@babel/helper-string-parser": {
|
|
16
|
-
"version": "7.
|
|
17
|
-
"resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.
|
|
18
|
-
"integrity": "sha512-
|
|
19
|
-
"
|
|
16
|
+
"version": "7.25.9",
|
|
17
|
+
"resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.25.9.tgz",
|
|
18
|
+
"integrity": "sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==",
|
|
19
|
+
"license": "MIT",
|
|
20
20
|
"engines": {
|
|
21
21
|
"node": ">=6.9.0"
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"node_modules/@babel/helper-validator-identifier": {
|
|
25
|
-
"version": "7.
|
|
26
|
-
"resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.
|
|
27
|
-
"integrity": "sha512-
|
|
28
|
-
"
|
|
25
|
+
"version": "7.25.9",
|
|
26
|
+
"resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz",
|
|
27
|
+
"integrity": "sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==",
|
|
28
|
+
"license": "MIT",
|
|
29
29
|
"engines": {
|
|
30
30
|
"node": ">=6.9.0"
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
33
|
"node_modules/@babel/parser": {
|
|
34
|
-
"version": "7.
|
|
35
|
-
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.
|
|
36
|
-
"integrity": "sha512-
|
|
37
|
-
"
|
|
34
|
+
"version": "7.27.0",
|
|
35
|
+
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.27.0.tgz",
|
|
36
|
+
"integrity": "sha512-iaepho73/2Pz7w2eMS0Q5f83+0RKI7i4xmiYeBmDzfRVbQtTOG7Ts0S4HzJVsTMGI9keU8rNfuZr8DKfSt7Yyg==",
|
|
37
|
+
"license": "MIT",
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@babel/types": "^7.
|
|
39
|
+
"@babel/types": "^7.27.0"
|
|
40
40
|
},
|
|
41
41
|
"bin": {
|
|
42
42
|
"parser": "bin/babel-parser.js"
|
|
@@ -46,14 +46,13 @@
|
|
|
46
46
|
}
|
|
47
47
|
},
|
|
48
48
|
"node_modules/@babel/types": {
|
|
49
|
-
"version": "7.
|
|
50
|
-
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.
|
|
51
|
-
"integrity": "sha512-
|
|
52
|
-
"
|
|
49
|
+
"version": "7.27.0",
|
|
50
|
+
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.27.0.tgz",
|
|
51
|
+
"integrity": "sha512-H45s8fVLYjbhFH62dIJ3WtmJ6RSPt/3DRO0ZcT2SUiYiQyz3BLVb9ADEnLl91m74aQPS3AzzeajZHYOalWe3bg==",
|
|
52
|
+
"license": "MIT",
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@babel/helper-string-parser": "^7.
|
|
55
|
-
"@babel/helper-validator-identifier": "^7.
|
|
56
|
-
"to-fast-properties": "^2.0.0"
|
|
54
|
+
"@babel/helper-string-parser": "^7.25.9",
|
|
55
|
+
"@babel/helper-validator-identifier": "^7.25.9"
|
|
57
56
|
},
|
|
58
57
|
"engines": {
|
|
59
58
|
"node": ">=6.9.0"
|
|
@@ -63,119 +62,119 @@
|
|
|
63
62
|
"version": "1.5.0",
|
|
64
63
|
"resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz",
|
|
65
64
|
"integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==",
|
|
66
|
-
"
|
|
65
|
+
"license": "MIT"
|
|
67
66
|
},
|
|
68
67
|
"node_modules/@vue/compiler-core": {
|
|
69
|
-
"version": "3.
|
|
70
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.
|
|
71
|
-
"integrity": "sha512-
|
|
72
|
-
"
|
|
68
|
+
"version": "3.5.13",
|
|
69
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.5.13.tgz",
|
|
70
|
+
"integrity": "sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==",
|
|
71
|
+
"license": "MIT",
|
|
73
72
|
"dependencies": {
|
|
74
|
-
"@babel/parser": "^7.
|
|
75
|
-
"@vue/shared": "3.
|
|
73
|
+
"@babel/parser": "^7.25.3",
|
|
74
|
+
"@vue/shared": "3.5.13",
|
|
76
75
|
"entities": "^4.5.0",
|
|
77
76
|
"estree-walker": "^2.0.2",
|
|
78
77
|
"source-map-js": "^1.2.0"
|
|
79
78
|
}
|
|
80
79
|
},
|
|
81
80
|
"node_modules/@vue/compiler-dom": {
|
|
82
|
-
"version": "3.
|
|
83
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.
|
|
84
|
-
"integrity": "sha512-
|
|
85
|
-
"
|
|
81
|
+
"version": "3.5.13",
|
|
82
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.5.13.tgz",
|
|
83
|
+
"integrity": "sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==",
|
|
84
|
+
"license": "MIT",
|
|
86
85
|
"dependencies": {
|
|
87
|
-
"@vue/compiler-core": "3.
|
|
88
|
-
"@vue/shared": "3.
|
|
86
|
+
"@vue/compiler-core": "3.5.13",
|
|
87
|
+
"@vue/shared": "3.5.13"
|
|
89
88
|
}
|
|
90
89
|
},
|
|
91
90
|
"node_modules/@vue/compiler-sfc": {
|
|
92
|
-
"version": "3.
|
|
93
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.
|
|
94
|
-
"integrity": "sha512-
|
|
95
|
-
"
|
|
91
|
+
"version": "3.5.13",
|
|
92
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.5.13.tgz",
|
|
93
|
+
"integrity": "sha512-6VdaljMpD82w6c2749Zhf5T9u5uLBWKnVue6XWxprDobftnletJ8+oel7sexFfM3qIxNmVE7LSFGTpv6obNyaQ==",
|
|
94
|
+
"license": "MIT",
|
|
96
95
|
"dependencies": {
|
|
97
|
-
"@babel/parser": "^7.
|
|
98
|
-
"@vue/compiler-core": "3.
|
|
99
|
-
"@vue/compiler-dom": "3.
|
|
100
|
-
"@vue/compiler-ssr": "3.
|
|
101
|
-
"@vue/shared": "3.
|
|
96
|
+
"@babel/parser": "^7.25.3",
|
|
97
|
+
"@vue/compiler-core": "3.5.13",
|
|
98
|
+
"@vue/compiler-dom": "3.5.13",
|
|
99
|
+
"@vue/compiler-ssr": "3.5.13",
|
|
100
|
+
"@vue/shared": "3.5.13",
|
|
102
101
|
"estree-walker": "^2.0.2",
|
|
103
|
-
"magic-string": "^0.30.
|
|
104
|
-
"postcss": "^8.4.
|
|
102
|
+
"magic-string": "^0.30.11",
|
|
103
|
+
"postcss": "^8.4.48",
|
|
105
104
|
"source-map-js": "^1.2.0"
|
|
106
105
|
}
|
|
107
106
|
},
|
|
108
107
|
"node_modules/@vue/compiler-ssr": {
|
|
109
|
-
"version": "3.
|
|
110
|
-
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.
|
|
111
|
-
"integrity": "sha512-
|
|
112
|
-
"
|
|
108
|
+
"version": "3.5.13",
|
|
109
|
+
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.5.13.tgz",
|
|
110
|
+
"integrity": "sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==",
|
|
111
|
+
"license": "MIT",
|
|
113
112
|
"dependencies": {
|
|
114
|
-
"@vue/compiler-dom": "3.
|
|
115
|
-
"@vue/shared": "3.
|
|
113
|
+
"@vue/compiler-dom": "3.5.13",
|
|
114
|
+
"@vue/shared": "3.5.13"
|
|
116
115
|
}
|
|
117
116
|
},
|
|
118
117
|
"node_modules/@vue/reactivity": {
|
|
119
|
-
"version": "3.
|
|
120
|
-
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.
|
|
121
|
-
"integrity": "sha512-
|
|
122
|
-
"
|
|
118
|
+
"version": "3.5.13",
|
|
119
|
+
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.5.13.tgz",
|
|
120
|
+
"integrity": "sha512-NaCwtw8o48B9I6L1zl2p41OHo/2Z4wqYGGIK1Khu5T7yxrn+ATOixn/Udn2m+6kZKB/J7cuT9DbWWhRxqixACg==",
|
|
121
|
+
"license": "MIT",
|
|
123
122
|
"dependencies": {
|
|
124
|
-
"@vue/shared": "3.
|
|
123
|
+
"@vue/shared": "3.5.13"
|
|
125
124
|
}
|
|
126
125
|
},
|
|
127
126
|
"node_modules/@vue/runtime-core": {
|
|
128
|
-
"version": "3.
|
|
129
|
-
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.
|
|
130
|
-
"integrity": "sha512-
|
|
131
|
-
"
|
|
127
|
+
"version": "3.5.13",
|
|
128
|
+
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.5.13.tgz",
|
|
129
|
+
"integrity": "sha512-Fj4YRQ3Az0WTZw1sFe+QDb0aXCerigEpw418pw1HBUKFtnQHWzwojaukAs2X/c9DQz4MQ4bsXTGlcpGxU/RCIw==",
|
|
130
|
+
"license": "MIT",
|
|
132
131
|
"dependencies": {
|
|
133
|
-
"@vue/reactivity": "3.
|
|
134
|
-
"@vue/shared": "3.
|
|
132
|
+
"@vue/reactivity": "3.5.13",
|
|
133
|
+
"@vue/shared": "3.5.13"
|
|
135
134
|
}
|
|
136
135
|
},
|
|
137
136
|
"node_modules/@vue/runtime-dom": {
|
|
138
|
-
"version": "3.
|
|
139
|
-
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.
|
|
140
|
-
"integrity": "sha512-
|
|
141
|
-
"
|
|
137
|
+
"version": "3.5.13",
|
|
138
|
+
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.5.13.tgz",
|
|
139
|
+
"integrity": "sha512-dLaj94s93NYLqjLiyFzVs9X6dWhTdAlEAciC3Moq7gzAc13VJUdCnjjRurNM6uTLFATRHexHCTu/Xp3eW6yoog==",
|
|
140
|
+
"license": "MIT",
|
|
142
141
|
"dependencies": {
|
|
143
|
-
"@vue/reactivity": "3.
|
|
144
|
-
"@vue/runtime-core": "3.
|
|
145
|
-
"@vue/shared": "3.
|
|
142
|
+
"@vue/reactivity": "3.5.13",
|
|
143
|
+
"@vue/runtime-core": "3.5.13",
|
|
144
|
+
"@vue/shared": "3.5.13",
|
|
146
145
|
"csstype": "^3.1.3"
|
|
147
146
|
}
|
|
148
147
|
},
|
|
149
148
|
"node_modules/@vue/server-renderer": {
|
|
150
|
-
"version": "3.
|
|
151
|
-
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.
|
|
152
|
-
"integrity": "sha512-
|
|
153
|
-
"
|
|
149
|
+
"version": "3.5.13",
|
|
150
|
+
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.5.13.tgz",
|
|
151
|
+
"integrity": "sha512-wAi4IRJV/2SAW3htkTlB+dHeRmpTiVIK1OGLWV1yeStVSebSQQOwGwIq0D3ZIoBj2C2qpgz5+vX9iEBkTdk5YA==",
|
|
152
|
+
"license": "MIT",
|
|
154
153
|
"dependencies": {
|
|
155
|
-
"@vue/compiler-ssr": "3.
|
|
156
|
-
"@vue/shared": "3.
|
|
154
|
+
"@vue/compiler-ssr": "3.5.13",
|
|
155
|
+
"@vue/shared": "3.5.13"
|
|
157
156
|
},
|
|
158
157
|
"peerDependencies": {
|
|
159
|
-
"vue": "3.
|
|
158
|
+
"vue": "3.5.13"
|
|
160
159
|
}
|
|
161
160
|
},
|
|
162
161
|
"node_modules/@vue/shared": {
|
|
163
|
-
"version": "3.
|
|
164
|
-
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.
|
|
165
|
-
"integrity": "sha512
|
|
166
|
-
"
|
|
162
|
+
"version": "3.5.13",
|
|
163
|
+
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.5.13.tgz",
|
|
164
|
+
"integrity": "sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==",
|
|
165
|
+
"license": "MIT"
|
|
167
166
|
},
|
|
168
167
|
"node_modules/csstype": {
|
|
169
168
|
"version": "3.1.3",
|
|
170
169
|
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz",
|
|
171
170
|
"integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==",
|
|
172
|
-
"
|
|
171
|
+
"license": "MIT"
|
|
173
172
|
},
|
|
174
173
|
"node_modules/entities": {
|
|
175
174
|
"version": "4.5.0",
|
|
176
175
|
"resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz",
|
|
177
176
|
"integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==",
|
|
178
|
-
"
|
|
177
|
+
"license": "BSD-2-Clause",
|
|
179
178
|
"engines": {
|
|
180
179
|
"node": ">=0.12"
|
|
181
180
|
},
|
|
@@ -187,58 +186,59 @@
|
|
|
187
186
|
"version": "2.0.2",
|
|
188
187
|
"resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz",
|
|
189
188
|
"integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==",
|
|
190
|
-
"
|
|
189
|
+
"license": "MIT"
|
|
191
190
|
},
|
|
192
191
|
"node_modules/eventemitter3": {
|
|
193
192
|
"version": "5.0.1",
|
|
194
193
|
"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz",
|
|
195
194
|
"integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==",
|
|
196
|
-
"
|
|
195
|
+
"license": "MIT"
|
|
197
196
|
},
|
|
198
197
|
"node_modules/fast-diff": {
|
|
199
198
|
"version": "1.3.0",
|
|
200
199
|
"resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz",
|
|
201
200
|
"integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==",
|
|
202
|
-
"
|
|
201
|
+
"license": "Apache-2.0"
|
|
203
202
|
},
|
|
204
203
|
"node_modules/lodash-es": {
|
|
205
204
|
"version": "4.17.21",
|
|
206
205
|
"resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.21.tgz",
|
|
207
206
|
"integrity": "sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==",
|
|
208
|
-
"
|
|
207
|
+
"license": "MIT"
|
|
209
208
|
},
|
|
210
209
|
"node_modules/lodash.clonedeep": {
|
|
211
210
|
"version": "4.5.0",
|
|
212
211
|
"resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz",
|
|
213
212
|
"integrity": "sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==",
|
|
214
|
-
"
|
|
213
|
+
"license": "MIT"
|
|
215
214
|
},
|
|
216
215
|
"node_modules/lodash.isequal": {
|
|
217
216
|
"version": "4.5.0",
|
|
218
217
|
"resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz",
|
|
219
218
|
"integrity": "sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==",
|
|
220
|
-
"
|
|
219
|
+
"deprecated": "This package is deprecated. Use require('node:util').isDeepStrictEqual instead.",
|
|
220
|
+
"license": "MIT"
|
|
221
221
|
},
|
|
222
222
|
"node_modules/magic-string": {
|
|
223
|
-
"version": "0.30.
|
|
224
|
-
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.
|
|
225
|
-
"integrity": "sha512
|
|
226
|
-
"
|
|
223
|
+
"version": "0.30.17",
|
|
224
|
+
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.17.tgz",
|
|
225
|
+
"integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==",
|
|
226
|
+
"license": "MIT",
|
|
227
227
|
"dependencies": {
|
|
228
228
|
"@jridgewell/sourcemap-codec": "^1.5.0"
|
|
229
229
|
}
|
|
230
230
|
},
|
|
231
231
|
"node_modules/nanoid": {
|
|
232
|
-
"version": "3.3.
|
|
233
|
-
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.
|
|
234
|
-
"integrity": "sha512-
|
|
235
|
-
"dev": true,
|
|
232
|
+
"version": "3.3.11",
|
|
233
|
+
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz",
|
|
234
|
+
"integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==",
|
|
236
235
|
"funding": [
|
|
237
236
|
{
|
|
238
237
|
"type": "github",
|
|
239
238
|
"url": "https://github.com/sponsors/ai"
|
|
240
239
|
}
|
|
241
240
|
],
|
|
241
|
+
"license": "MIT",
|
|
242
242
|
"bin": {
|
|
243
243
|
"nanoid": "bin/nanoid.cjs"
|
|
244
244
|
},
|
|
@@ -250,19 +250,18 @@
|
|
|
250
250
|
"version": "3.0.0",
|
|
251
251
|
"resolved": "https://registry.npmjs.org/parchment/-/parchment-3.0.0.tgz",
|
|
252
252
|
"integrity": "sha512-HUrJFQ/StvgmXRcQ1ftY6VEZUq3jA2t9ncFN4F84J/vN0/FPpQF+8FKXb3l6fLces6q0uOHj6NJn+2xvZnxO6A==",
|
|
253
|
-
"
|
|
253
|
+
"license": "BSD-3-Clause"
|
|
254
254
|
},
|
|
255
255
|
"node_modules/picocolors": {
|
|
256
|
-
"version": "1.
|
|
257
|
-
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.
|
|
258
|
-
"integrity": "sha512-
|
|
259
|
-
"
|
|
256
|
+
"version": "1.1.1",
|
|
257
|
+
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
|
258
|
+
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
|
|
259
|
+
"license": "ISC"
|
|
260
260
|
},
|
|
261
261
|
"node_modules/postcss": {
|
|
262
|
-
"version": "8.
|
|
263
|
-
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.
|
|
264
|
-
"integrity": "sha512-
|
|
265
|
-
"dev": true,
|
|
262
|
+
"version": "8.5.3",
|
|
263
|
+
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz",
|
|
264
|
+
"integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==",
|
|
266
265
|
"funding": [
|
|
267
266
|
{
|
|
268
267
|
"type": "opencollective",
|
|
@@ -277,20 +276,21 @@
|
|
|
277
276
|
"url": "https://github.com/sponsors/ai"
|
|
278
277
|
}
|
|
279
278
|
],
|
|
279
|
+
"license": "MIT",
|
|
280
280
|
"dependencies": {
|
|
281
|
-
"nanoid": "^3.3.
|
|
282
|
-
"picocolors": "^1.
|
|
283
|
-
"source-map-js": "^1.2.
|
|
281
|
+
"nanoid": "^3.3.8",
|
|
282
|
+
"picocolors": "^1.1.1",
|
|
283
|
+
"source-map-js": "^1.2.1"
|
|
284
284
|
},
|
|
285
285
|
"engines": {
|
|
286
286
|
"node": "^10 || ^12 || >=14"
|
|
287
287
|
}
|
|
288
288
|
},
|
|
289
289
|
"node_modules/quill": {
|
|
290
|
-
"version": "2.0.
|
|
291
|
-
"resolved": "https://registry.npmjs.org/quill/-/quill-2.0.
|
|
292
|
-
"integrity": "sha512-
|
|
293
|
-
"
|
|
290
|
+
"version": "2.0.3",
|
|
291
|
+
"resolved": "https://registry.npmjs.org/quill/-/quill-2.0.3.tgz",
|
|
292
|
+
"integrity": "sha512-xEYQBqfYx/sfb33VJiKnSJp8ehloavImQ2A6564GAbqG55PGw1dAWUn1MUbQB62t0azawUS2CZZhWCjO8gRvTw==",
|
|
293
|
+
"license": "BSD-3-Clause",
|
|
294
294
|
"dependencies": {
|
|
295
295
|
"eventemitter3": "^5.0.1",
|
|
296
296
|
"lodash-es": "^4.17.21",
|
|
@@ -305,7 +305,7 @@
|
|
|
305
305
|
"version": "5.1.0",
|
|
306
306
|
"resolved": "https://registry.npmjs.org/quill-delta/-/quill-delta-5.1.0.tgz",
|
|
307
307
|
"integrity": "sha512-X74oCeRI4/p0ucjb5Ma8adTXd9Scumz367kkMK5V/IatcX6A0vlgLgKbzXWy5nZmCGeNJm2oQX0d2Eqj+ZIlCA==",
|
|
308
|
-
"
|
|
308
|
+
"license": "MIT",
|
|
309
309
|
"dependencies": {
|
|
310
310
|
"fast-diff": "^1.3.0",
|
|
311
311
|
"lodash.clonedeep": "^4.5.0",
|
|
@@ -316,34 +316,25 @@
|
|
|
316
316
|
}
|
|
317
317
|
},
|
|
318
318
|
"node_modules/source-map-js": {
|
|
319
|
-
"version": "1.2.
|
|
320
|
-
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.
|
|
321
|
-
"integrity": "sha512-
|
|
322
|
-
"
|
|
319
|
+
"version": "1.2.1",
|
|
320
|
+
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
|
321
|
+
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
|
322
|
+
"license": "BSD-3-Clause",
|
|
323
323
|
"engines": {
|
|
324
324
|
"node": ">=0.10.0"
|
|
325
325
|
}
|
|
326
326
|
},
|
|
327
|
-
"node_modules/to-fast-properties": {
|
|
328
|
-
"version": "2.0.0",
|
|
329
|
-
"resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz",
|
|
330
|
-
"integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==",
|
|
331
|
-
"dev": true,
|
|
332
|
-
"engines": {
|
|
333
|
-
"node": ">=4"
|
|
334
|
-
}
|
|
335
|
-
},
|
|
336
327
|
"node_modules/vue": {
|
|
337
|
-
"version": "3.
|
|
338
|
-
"resolved": "https://registry.npmjs.org/vue/-/vue-3.
|
|
339
|
-
"integrity": "sha512
|
|
340
|
-
"
|
|
328
|
+
"version": "3.5.13",
|
|
329
|
+
"resolved": "https://registry.npmjs.org/vue/-/vue-3.5.13.tgz",
|
|
330
|
+
"integrity": "sha512-wmeiSMxkZCSc+PM2w2VRsOYAZC8GdipNFRTsLSfodVqI9mbejKeXEGr8SckuLnrQPGe3oJN5c3K0vpoU9q/wCQ==",
|
|
331
|
+
"license": "MIT",
|
|
341
332
|
"dependencies": {
|
|
342
|
-
"@vue/compiler-dom": "3.
|
|
343
|
-
"@vue/compiler-sfc": "3.
|
|
344
|
-
"@vue/runtime-dom": "3.
|
|
345
|
-
"@vue/server-renderer": "3.
|
|
346
|
-
"@vue/shared": "3.
|
|
333
|
+
"@vue/compiler-dom": "3.5.13",
|
|
334
|
+
"@vue/compiler-sfc": "3.5.13",
|
|
335
|
+
"@vue/runtime-dom": "3.5.13",
|
|
336
|
+
"@vue/server-renderer": "3.5.13",
|
|
337
|
+
"@vue/shared": "3.5.13"
|
|
347
338
|
},
|
|
348
339
|
"peerDependencies": {
|
|
349
340
|
"typescript": "*"
|
|
@@ -355,10 +346,9 @@
|
|
|
355
346
|
}
|
|
356
347
|
},
|
|
357
348
|
"node_modules/vue-suggestion-input": {
|
|
358
|
-
"version": "
|
|
359
|
-
"resolved": "https://registry.npmjs.org/vue-suggestion-input/-/vue-suggestion-input-
|
|
360
|
-
"integrity": "sha512-
|
|
361
|
-
"dev": true,
|
|
349
|
+
"version": "1.0.9",
|
|
350
|
+
"resolved": "https://registry.npmjs.org/vue-suggestion-input/-/vue-suggestion-input-1.0.9.tgz",
|
|
351
|
+
"integrity": "sha512-arnk/TT1KGrnD1hHoRpBM/upp22RNswdgUHvmTFnwW/Wdej5au2U5ogXRdLKgcBb/erxs2curZMjWiqbxpYo8g==",
|
|
362
352
|
"dependencies": {
|
|
363
353
|
"quill": "^2.0.2",
|
|
364
354
|
"vue": "^3.4.31"
|
package/dist/custom/package.json
CHANGED
package/dist/index.js
CHANGED
|
@@ -92,7 +92,18 @@ export default class TextCompletePlugin extends AdminForthPlugin {
|
|
|
92
92
|
}
|
|
93
93
|
else {
|
|
94
94
|
if (this.options.initialPrompt) {
|
|
95
|
-
|
|
95
|
+
// initial prompt might have mustache syntax for current record value (several fields)
|
|
96
|
+
// use regex to replace it with current record value
|
|
97
|
+
const regex = /{{([^}]+)}}/g;
|
|
98
|
+
const interpretedPrompt = this.options.initialPrompt.replace(regex, (match, p1) => {
|
|
99
|
+
const fieldName = p1.trim();
|
|
100
|
+
const fieldValue = record[fieldName];
|
|
101
|
+
if (fieldValue) {
|
|
102
|
+
return fieldValue;
|
|
103
|
+
}
|
|
104
|
+
return match;
|
|
105
|
+
});
|
|
106
|
+
content = `${interpretedPrompt}\n` +
|
|
96
107
|
"No quotes. Don't talk to me. Just write text\n";
|
|
97
108
|
}
|
|
98
109
|
else {
|
package/index.ts
CHANGED
|
@@ -121,7 +121,20 @@ export default class TextCompletePlugin extends AdminForthPlugin {
|
|
|
121
121
|
} else {
|
|
122
122
|
|
|
123
123
|
if (this.options.initialPrompt) {
|
|
124
|
-
|
|
124
|
+
// initial prompt might have mustache syntax for current record value (several fields)
|
|
125
|
+
// use regex to replace it with current record value
|
|
126
|
+
const regex = /{{([^}]+)}}/g;
|
|
127
|
+
const interpretedPrompt = this.options.initialPrompt.replace(regex, (match, p1) => {
|
|
128
|
+
const fieldName = p1.trim();
|
|
129
|
+
const fieldValue = record[fieldName];
|
|
130
|
+
if (fieldValue) {
|
|
131
|
+
return fieldValue;
|
|
132
|
+
}
|
|
133
|
+
return match;
|
|
134
|
+
});
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
content = `${interpretedPrompt}\n` +
|
|
125
138
|
"No quotes. Don't talk to me. Just write text\n";
|
|
126
139
|
} else {
|
|
127
140
|
content = `Fill text/string field "${this.options.fieldName}" in the table "${resLabel}"\n` +
|
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adminforth/text-complete",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "Text completion plugin for adminforth",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
|
+
"homepage": "https://adminforth.dev/docs/tutorial/Plugins/text-complete/",
|
|
8
9
|
"scripts": {
|
|
9
10
|
"build": "tsc && rsync -av --exclude 'node_modules' custom dist/",
|
|
10
11
|
"prepare": "npm link adminforth"
|