agilebuilder-ui 1.1.45 → 1.1.47
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/lib/{401-1bde8dc9.js → 401-24b6b525.js} +1 -1
- package/lib/{404-48d76996.js → 404-55dbc936.js} +1 -1
- package/lib/{iframe-page-77e184a0.js → iframe-page-effbb33c.js} +1 -1
- package/lib/index-f3ef09a5.js +92745 -0
- package/lib/super-ui.css +1 -1
- package/lib/super-ui.js +33 -32
- package/lib/super-ui.umd.cjs +172 -133
- package/lib/{tab-content-iframe-index-39745d49.js → tab-content-iframe-index-4c557db3.js} +1 -1
- package/lib/{tab-content-index-65696e56.js → tab-content-index-a7350229.js} +1 -1
- package/lib/{tache-subprocess-history-ef943f95.js → tache-subprocess-history-f19dd95f.js} +1 -1
- package/package.json +7 -2
- package/packages/chat-embed/index.ts +6 -0
- package/packages/chat-embed/src/chat-embed-message.ts +79 -0
- package/packages/chat-embed/src/chat-embed.css +117 -0
- package/packages/chat-embed/src/chat-sender.vue +240 -0
- package/packages/chat-embed/src/header.vue +50 -0
- package/packages/chat-embed/src/index.vue +425 -0
- package/packages/chat-embed/src/recommendation-message.vue +37 -0
- package/packages/chat-embed/src/util.ts +33 -0
- package/packages/index.js +16 -13
- package/packages/json-view/index.ts +3 -0
- package/packages/json-view/json-view-dialog.vue +53 -0
- package/packages/json-view/json-view.vue +126 -0
- package/packages/super-grid/src/apis.js +11 -0
- package/packages/super-grid/src/dynamic-input.vue +18 -4
- package/packages/super-grid/src/normal-column.vue +8 -1
- package/packages/super-grid/src/super-grid.vue +21 -8
- package/src/assets/chat-embed/avatar.png +0 -0
- package/src/i18n/langs/cn.js +14 -2
- package/src/i18n/langs/en.js +13 -1
- package/src/store/modules/chat-ai-store.ts +78 -0
- package/src/store/modules/tab-content.js +9 -3
- package/src/styles/element-ui.scss +8 -7
- package/src/styles/index.scss +19 -0
- package/src/utils/chat-ai-util.ts +31 -0
- package/src/utils/common-util.js +56 -8
- package/src/utils/insert_css.js +14 -1
- package/lib/index-465b0d69.js +0 -73558
package/src/utils/common-util.js
CHANGED
|
@@ -231,8 +231,12 @@ export function isPlateSys(systemCode) {
|
|
|
231
231
|
export function getServerConfigUtil(http) {
|
|
232
232
|
return new Promise((resolve, reject) => {
|
|
233
233
|
let timestamp = '1'
|
|
234
|
-
|
|
235
|
-
|
|
234
|
+
try {
|
|
235
|
+
if(__BUILD_TIME__) {
|
|
236
|
+
timestamp = __BUILD_TIME__
|
|
237
|
+
}
|
|
238
|
+
} catch (error) {
|
|
239
|
+
console.log('__BUILD_TIME__ not define')
|
|
236
240
|
}
|
|
237
241
|
http.get('./server-config.json?t='+timestamp).then((result) => {
|
|
238
242
|
const config = result
|
|
@@ -247,16 +251,60 @@ export function getServerConfigUtil(http) {
|
|
|
247
251
|
)
|
|
248
252
|
localStorage.setItem('_baseAPI_', window.$vueApp.config.globalProperties.baseAPI)
|
|
249
253
|
localStorage.setItem('_amb_projectModel_', window.$vueApp.config.globalProperties.projectModel)
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
window.insertCssFile(`${config.fontIconAddress}-color/iconfont.css?t=${timestamp}`)
|
|
255
|
-
}
|
|
254
|
+
// 插入图标css样式文件
|
|
255
|
+
insertFontIconCss(config)
|
|
256
|
+
// 第3方集成js
|
|
257
|
+
insertThirdLoginJs(config)
|
|
256
258
|
resolve()
|
|
257
259
|
})
|
|
258
260
|
})
|
|
259
261
|
}
|
|
262
|
+
|
|
263
|
+
export function insertFontIconCss(config){
|
|
264
|
+
if(!window.insertCssFile){
|
|
265
|
+
return
|
|
266
|
+
}
|
|
267
|
+
if(!config){
|
|
268
|
+
config = window.$vueApp.config.globalProperties
|
|
269
|
+
}
|
|
270
|
+
let timestamp = '1'
|
|
271
|
+
try {
|
|
272
|
+
if(__BUILD_TIME__) {
|
|
273
|
+
timestamp = __BUILD_TIME__
|
|
274
|
+
}
|
|
275
|
+
} catch (error) {
|
|
276
|
+
console.log('__BUILD_TIME__ not define')
|
|
277
|
+
}
|
|
278
|
+
if (config.fontIconAddress && window.insertCssFile) {
|
|
279
|
+
window.insertCssFile(`${config.fontIconAddress}/iconfont.css?t=${timestamp}`)
|
|
280
|
+
}
|
|
281
|
+
if (config.fontIconAddress && window.insertCssFile) {
|
|
282
|
+
window.insertCssFile(`${config.fontIconAddress}-color/iconfont.css?t=${timestamp}`)
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
export function insertThirdLoginJs(config){
|
|
287
|
+
if(!window.insertJsFile ){
|
|
288
|
+
return
|
|
289
|
+
}
|
|
290
|
+
if(!config){
|
|
291
|
+
config = window.$vueApp.config.globalProperties
|
|
292
|
+
}
|
|
293
|
+
if(!config || (config.systemCode !== 'portal' && config.systemCode !== 'devp')){
|
|
294
|
+
return
|
|
295
|
+
}
|
|
296
|
+
// 只有portal和devp需要动态添加这些js
|
|
297
|
+
// userName,dingtalk,feishu,qiwei
|
|
298
|
+
if (!config.loginMethod || config.loginMethod.indexOf('dingtalk')>=0) {
|
|
299
|
+
window.insertJsFile(`https://g.alicdn.com/dingding/h5-dingtalk-login/0.21.0/ddlogin.js`)
|
|
300
|
+
}
|
|
301
|
+
if (!config.loginMethod || config.loginMethod.indexOf('feishu')>=0) {
|
|
302
|
+
window.insertJsFile(`https://lf-package-cn.feishucdn.com/obj/feishu-static/lark/passport/qrcode/LarkSSOSDKWebQRCode-1.0.3.js`)
|
|
303
|
+
}
|
|
304
|
+
if (!config.loginMethod || config.loginMethod.indexOf('qiwei')>=0) {
|
|
305
|
+
window.insertJsFile(`https://wwcdn.weixin.qq.com/node/open/js/wecom-jssdk-2.3.1.js`)
|
|
306
|
+
}
|
|
307
|
+
}
|
|
260
308
|
/**
|
|
261
309
|
* postmessage跨域传message时获得orign路径使用
|
|
262
310
|
* @returns orign路径
|
package/src/utils/insert_css.js
CHANGED
|
@@ -15,7 +15,6 @@ if (!window.insertCssFile) {
|
|
|
15
15
|
if (!cssUrl || window.insertedCssFiles.has(cssUrl)) {
|
|
16
16
|
return;
|
|
17
17
|
}
|
|
18
|
-
const timestamp = new Date().getTime();
|
|
19
18
|
const link = document.createElement('link');
|
|
20
19
|
link.rel = 'stylesheet';
|
|
21
20
|
link.href = cssUrl;
|
|
@@ -29,6 +28,20 @@ if (!window.insertCssFile) {
|
|
|
29
28
|
}
|
|
30
29
|
}
|
|
31
30
|
|
|
31
|
+
|
|
32
|
+
if (!window.insertJsFile) {
|
|
33
|
+
window.insertJsFile = (jsUrl) => {
|
|
34
|
+
if (!jsUrl || window.insertedCssFiles.has(jsUrl)) {
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
const link = document.createElement('script');
|
|
38
|
+
link.src = jsUrl;
|
|
39
|
+
link.onload = function () {
|
|
40
|
+
window.insertedCssFiles.add(jsUrl);
|
|
41
|
+
};
|
|
42
|
+
document.head.appendChild(link);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
32
45
|
// if (window.insertCssFile) {
|
|
33
46
|
// window.insertCssFile(window.defaultCssUrl);
|
|
34
47
|
// }
|