@blotoutio/providers-shop-gpt-sdk 0.68.1 → 0.69.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/index.cjs.js +11 -18
- package/index.js +11 -18
- package/index.mjs +11 -18
- package/package.json +1 -1
package/index.cjs.js
CHANGED
@@ -277,35 +277,26 @@ const canLog = () => {
|
|
277
277
|
return false;
|
278
278
|
}
|
279
279
|
};
|
280
|
+
const prefix = `[EdgeTag]`;
|
280
281
|
const logger = {
|
281
282
|
log: (...args) => {
|
282
283
|
if (canLog()) {
|
283
|
-
console.log(...args);
|
284
|
+
console.log(prefix, ...args);
|
284
285
|
}
|
285
286
|
},
|
286
287
|
error: (...args) => {
|
287
288
|
if (canLog()) {
|
288
|
-
console.error(...args);
|
289
|
+
console.error(prefix, ...args);
|
289
290
|
}
|
290
291
|
},
|
291
292
|
info: (...args) => {
|
292
293
|
if (canLog()) {
|
293
|
-
console.info(...args);
|
294
|
+
console.info(prefix, ...args);
|
294
295
|
}
|
295
296
|
},
|
296
297
|
trace: (...args) => {
|
297
298
|
if (canLog()) {
|
298
|
-
console.trace(...args);
|
299
|
-
}
|
300
|
-
},
|
301
|
-
table: (...args) => {
|
302
|
-
if (canLog()) {
|
303
|
-
console.table(...args);
|
304
|
-
}
|
305
|
-
},
|
306
|
-
dir: (...args) => {
|
307
|
-
if (canLog()) {
|
308
|
-
console.dir(...args);
|
299
|
+
console.trace(prefix, ...args);
|
309
300
|
}
|
310
301
|
},
|
311
302
|
};
|
@@ -317,6 +308,7 @@ const shopGPTStyles = () => i$2 `
|
|
317
308
|
left: 0;
|
318
309
|
height: 100%;
|
319
310
|
width: 100%;
|
311
|
+
z-index: 2147483647;
|
320
312
|
}
|
321
313
|
|
322
314
|
::-webkit-scrollbar {
|
@@ -1096,6 +1088,10 @@ let ShopGPT = class ShopGPT extends s {
|
|
1096
1088
|
this.chatWindowElement.style.maxHeight = 'calc(100vh - 221px)';
|
1097
1089
|
}
|
1098
1090
|
}
|
1091
|
+
async onSubmit(e) {
|
1092
|
+
var _a;
|
1093
|
+
await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim());
|
1094
|
+
}
|
1099
1095
|
render() {
|
1100
1096
|
return x `
|
1101
1097
|
<div class="container">
|
@@ -1330,10 +1326,7 @@ let ShopGPT = class ShopGPT extends s {
|
|
1330
1326
|
return x `
|
1331
1327
|
<div class="chatbot-section">
|
1332
1328
|
${this.chatWindow()} ${this.predefinedPrompts()}
|
1333
|
-
<form
|
1334
|
-
class="chat-input"
|
1335
|
-
@submit=${async (e) => { var _a; return await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim()); }}
|
1336
|
-
>
|
1329
|
+
<form class="chat-input" @submit=${this.onSubmit}>
|
1337
1330
|
<input
|
1338
1331
|
type="text"
|
1339
1332
|
.value=${this.userMessage}
|
package/index.js
CHANGED
@@ -278,35 +278,26 @@ var ProvidersShopGptSdk = (function () {
|
|
278
278
|
return false;
|
279
279
|
}
|
280
280
|
};
|
281
|
+
const prefix = `[EdgeTag]`;
|
281
282
|
const logger = {
|
282
283
|
log: (...args) => {
|
283
284
|
if (canLog()) {
|
284
|
-
console.log(...args);
|
285
|
+
console.log(prefix, ...args);
|
285
286
|
}
|
286
287
|
},
|
287
288
|
error: (...args) => {
|
288
289
|
if (canLog()) {
|
289
|
-
console.error(...args);
|
290
|
+
console.error(prefix, ...args);
|
290
291
|
}
|
291
292
|
},
|
292
293
|
info: (...args) => {
|
293
294
|
if (canLog()) {
|
294
|
-
console.info(...args);
|
295
|
+
console.info(prefix, ...args);
|
295
296
|
}
|
296
297
|
},
|
297
298
|
trace: (...args) => {
|
298
299
|
if (canLog()) {
|
299
|
-
console.trace(...args);
|
300
|
-
}
|
301
|
-
},
|
302
|
-
table: (...args) => {
|
303
|
-
if (canLog()) {
|
304
|
-
console.table(...args);
|
305
|
-
}
|
306
|
-
},
|
307
|
-
dir: (...args) => {
|
308
|
-
if (canLog()) {
|
309
|
-
console.dir(...args);
|
300
|
+
console.trace(prefix, ...args);
|
310
301
|
}
|
311
302
|
},
|
312
303
|
};
|
@@ -318,6 +309,7 @@ var ProvidersShopGptSdk = (function () {
|
|
318
309
|
left: 0;
|
319
310
|
height: 100%;
|
320
311
|
width: 100%;
|
312
|
+
z-index: 2147483647;
|
321
313
|
}
|
322
314
|
|
323
315
|
::-webkit-scrollbar {
|
@@ -1097,6 +1089,10 @@ var ProvidersShopGptSdk = (function () {
|
|
1097
1089
|
this.chatWindowElement.style.maxHeight = 'calc(100vh - 221px)';
|
1098
1090
|
}
|
1099
1091
|
}
|
1092
|
+
async onSubmit(e) {
|
1093
|
+
var _a;
|
1094
|
+
await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim());
|
1095
|
+
}
|
1100
1096
|
render() {
|
1101
1097
|
return x `
|
1102
1098
|
<div class="container">
|
@@ -1331,10 +1327,7 @@ var ProvidersShopGptSdk = (function () {
|
|
1331
1327
|
return x `
|
1332
1328
|
<div class="chatbot-section">
|
1333
1329
|
${this.chatWindow()} ${this.predefinedPrompts()}
|
1334
|
-
<form
|
1335
|
-
class="chat-input"
|
1336
|
-
@submit=${async (e) => { var _a; return await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim()); }}
|
1337
|
-
>
|
1330
|
+
<form class="chat-input" @submit=${this.onSubmit}>
|
1338
1331
|
<input
|
1339
1332
|
type="text"
|
1340
1333
|
.value=${this.userMessage}
|
package/index.mjs
CHANGED
@@ -275,35 +275,26 @@ const canLog = () => {
|
|
275
275
|
return false;
|
276
276
|
}
|
277
277
|
};
|
278
|
+
const prefix = `[EdgeTag]`;
|
278
279
|
const logger = {
|
279
280
|
log: (...args) => {
|
280
281
|
if (canLog()) {
|
281
|
-
console.log(...args);
|
282
|
+
console.log(prefix, ...args);
|
282
283
|
}
|
283
284
|
},
|
284
285
|
error: (...args) => {
|
285
286
|
if (canLog()) {
|
286
|
-
console.error(...args);
|
287
|
+
console.error(prefix, ...args);
|
287
288
|
}
|
288
289
|
},
|
289
290
|
info: (...args) => {
|
290
291
|
if (canLog()) {
|
291
|
-
console.info(...args);
|
292
|
+
console.info(prefix, ...args);
|
292
293
|
}
|
293
294
|
},
|
294
295
|
trace: (...args) => {
|
295
296
|
if (canLog()) {
|
296
|
-
console.trace(...args);
|
297
|
-
}
|
298
|
-
},
|
299
|
-
table: (...args) => {
|
300
|
-
if (canLog()) {
|
301
|
-
console.table(...args);
|
302
|
-
}
|
303
|
-
},
|
304
|
-
dir: (...args) => {
|
305
|
-
if (canLog()) {
|
306
|
-
console.dir(...args);
|
297
|
+
console.trace(prefix, ...args);
|
307
298
|
}
|
308
299
|
},
|
309
300
|
};
|
@@ -315,6 +306,7 @@ const shopGPTStyles = () => i$2 `
|
|
315
306
|
left: 0;
|
316
307
|
height: 100%;
|
317
308
|
width: 100%;
|
309
|
+
z-index: 2147483647;
|
318
310
|
}
|
319
311
|
|
320
312
|
::-webkit-scrollbar {
|
@@ -1094,6 +1086,10 @@ let ShopGPT = class ShopGPT extends s {
|
|
1094
1086
|
this.chatWindowElement.style.maxHeight = 'calc(100vh - 221px)';
|
1095
1087
|
}
|
1096
1088
|
}
|
1089
|
+
async onSubmit(e) {
|
1090
|
+
var _a;
|
1091
|
+
await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim());
|
1092
|
+
}
|
1097
1093
|
render() {
|
1098
1094
|
return x `
|
1099
1095
|
<div class="container">
|
@@ -1328,10 +1324,7 @@ let ShopGPT = class ShopGPT extends s {
|
|
1328
1324
|
return x `
|
1329
1325
|
<div class="chatbot-section">
|
1330
1326
|
${this.chatWindow()} ${this.predefinedPrompts()}
|
1331
|
-
<form
|
1332
|
-
class="chat-input"
|
1333
|
-
@submit=${async (e) => { var _a; return await this.sendMessageToServer(e, (_a = this.userMessage) === null || _a === void 0 ? void 0 : _a.trim()); }}
|
1334
|
-
>
|
1327
|
+
<form class="chat-input" @submit=${this.onSubmit}>
|
1335
1328
|
<input
|
1336
1329
|
type="text"
|
1337
1330
|
.value=${this.userMessage}
|