@digipair/skill-web-chatbot 0.32.7 → 0.33.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/index.cjs2.js +23 -8
- package/index.esm2.js +23 -8
- package/libs/engine/src/lib/alias.interface.d.ts +9 -0
- package/libs/engine/src/lib/engine.d.ts +1 -1
- package/package.json +1 -1
- package/schema.en.json +0 -89
package/index.cjs2.js
CHANGED
|
@@ -52659,14 +52659,14 @@ function indent(str, spaces) {
|
|
|
52659
52659
|
var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
|
|
52660
52660
|
// match is required
|
|
52661
52661
|
if (!match) {
|
|
52662
|
-
return
|
|
52662
|
+
return i = i1, nextMatch = nextMatch1, tokens = tokens1, {
|
|
52663
52663
|
v: nextMatch1
|
|
52664
52664
|
};
|
|
52665
52665
|
}
|
|
52666
52666
|
var token = match.token, offset = match.offset;
|
|
52667
52667
|
i1 += offset;
|
|
52668
52668
|
if (token === " ") {
|
|
52669
|
-
return
|
|
52669
|
+
return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
|
|
52670
52670
|
}
|
|
52671
52671
|
tokens1 = _to_consumable_array$9(tokens1).concat([
|
|
52672
52672
|
token
|
|
@@ -52685,7 +52685,7 @@ function indent(str, spaces) {
|
|
|
52685
52685
|
if (contextKeys.some(function(el) {
|
|
52686
52686
|
return el.startsWith(name);
|
|
52687
52687
|
})) {
|
|
52688
|
-
return
|
|
52688
|
+
return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
|
|
52689
52689
|
}
|
|
52690
52690
|
if (dateTimeIdentifiers.some(function(el) {
|
|
52691
52691
|
return el === name;
|
|
@@ -52704,9 +52704,9 @@ function indent(str, spaces) {
|
|
|
52704
52704
|
if (dateTimeIdentifiers.some(function(el) {
|
|
52705
52705
|
return el.startsWith(name);
|
|
52706
52706
|
})) {
|
|
52707
|
-
return
|
|
52707
|
+
return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
|
|
52708
52708
|
}
|
|
52709
|
-
return
|
|
52709
|
+
return i = i1, nextMatch = nextMatch1, tokens = tokens1, {
|
|
52710
52710
|
v: nextMatch1
|
|
52711
52711
|
};
|
|
52712
52712
|
};
|
|
@@ -56496,7 +56496,8 @@ const globalInstance = typeof window === 'undefined' ? global : window;
|
|
|
56496
56496
|
var _globalInstance___DIGIPAIR_CONFIG__;
|
|
56497
56497
|
const _config$1 = globalInstance.__DIGIPAIR_CONFIG__ = (_globalInstance___DIGIPAIR_CONFIG__ = globalInstance.__DIGIPAIR_CONFIG__) != null ? _globalInstance___DIGIPAIR_CONFIG__ : {
|
|
56498
56498
|
LIBRARIES: {},
|
|
56499
|
-
BASE_URL: 'https://cdn.jsdelivr.net/npm'
|
|
56499
|
+
BASE_URL: 'https://cdn.jsdelivr.net/npm',
|
|
56500
|
+
ALIAS: []
|
|
56500
56501
|
};
|
|
56501
56502
|
const isRemoteVersion = /^https?:\/\/[^\s/$.?#].[^\s]*$/;
|
|
56502
56503
|
const isPinsSettings = (value)=>{
|
|
@@ -56538,7 +56539,15 @@ const applyTemplate = (value, context)=>{
|
|
|
56538
56539
|
};
|
|
56539
56540
|
const executePins = async (settingsOrigin, context = {})=>{
|
|
56540
56541
|
var _settings_conditions, _settings_conditions1;
|
|
56541
|
-
|
|
56542
|
+
let settings = await preparePinsSettings(settingsOrigin, context);
|
|
56543
|
+
const alias = _config$1.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
|
|
56544
|
+
if (alias) {
|
|
56545
|
+
settings = await preparePinsSettings(_extends({}, settings, alias), {
|
|
56546
|
+
settings: _extends({}, settings, {
|
|
56547
|
+
library: settings.library.substring(alias.name.length + 1)
|
|
56548
|
+
})
|
|
56549
|
+
});
|
|
56550
|
+
}
|
|
56542
56551
|
if ((_settings_conditions = settings.conditions) == null ? void 0 : _settings_conditions.each) {
|
|
56543
56552
|
const results = [];
|
|
56544
56553
|
for(let index = 0; index < settings.conditions.each.length; index++){
|
|
@@ -56611,7 +56620,13 @@ const executePinsList = async (pinsSettingsList, context)=>{
|
|
|
56611
56620
|
};
|
|
56612
56621
|
const generateElementFromPins = async (pinsSettings, parent, context)=>{
|
|
56613
56622
|
var _settings_conditions, _settings_conditions1;
|
|
56614
|
-
|
|
56623
|
+
let settings = await preparePinsSettings(pinsSettings, context);
|
|
56624
|
+
const alias = _config$1.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
|
|
56625
|
+
if (alias) {
|
|
56626
|
+
settings = await preparePinsSettings(_extends({}, settings, alias), {
|
|
56627
|
+
settings
|
|
56628
|
+
});
|
|
56629
|
+
}
|
|
56615
56630
|
if ((_settings_conditions = settings.conditions) == null ? void 0 : _settings_conditions.each) {
|
|
56616
56631
|
for(let index = 0; index < settings.conditions.each.length; index++){
|
|
56617
56632
|
const item = settings.conditions.each[index];
|
package/index.esm2.js
CHANGED
|
@@ -52639,14 +52639,14 @@ function indent(str, spaces) {
|
|
|
52639
52639
|
var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
|
|
52640
52640
|
// match is required
|
|
52641
52641
|
if (!match) {
|
|
52642
|
-
return
|
|
52642
|
+
return tokens = tokens1, i = i1, nextMatch = nextMatch1, {
|
|
52643
52643
|
v: nextMatch1
|
|
52644
52644
|
};
|
|
52645
52645
|
}
|
|
52646
52646
|
var token = match.token, offset = match.offset;
|
|
52647
52647
|
i1 += offset;
|
|
52648
52648
|
if (token === " ") {
|
|
52649
|
-
return
|
|
52649
|
+
return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
|
|
52650
52650
|
}
|
|
52651
52651
|
tokens1 = _to_consumable_array$9(tokens1).concat([
|
|
52652
52652
|
token
|
|
@@ -52665,7 +52665,7 @@ function indent(str, spaces) {
|
|
|
52665
52665
|
if (contextKeys.some(function(el) {
|
|
52666
52666
|
return el.startsWith(name);
|
|
52667
52667
|
})) {
|
|
52668
|
-
return
|
|
52668
|
+
return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
|
|
52669
52669
|
}
|
|
52670
52670
|
if (dateTimeIdentifiers.some(function(el) {
|
|
52671
52671
|
return el === name;
|
|
@@ -52684,9 +52684,9 @@ function indent(str, spaces) {
|
|
|
52684
52684
|
if (dateTimeIdentifiers.some(function(el) {
|
|
52685
52685
|
return el.startsWith(name);
|
|
52686
52686
|
})) {
|
|
52687
|
-
return
|
|
52687
|
+
return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
|
|
52688
52688
|
}
|
|
52689
|
-
return
|
|
52689
|
+
return tokens = tokens1, i = i1, nextMatch = nextMatch1, {
|
|
52690
52690
|
v: nextMatch1
|
|
52691
52691
|
};
|
|
52692
52692
|
};
|
|
@@ -56476,7 +56476,8 @@ const globalInstance = typeof window === 'undefined' ? global : window;
|
|
|
56476
56476
|
var _globalInstance___DIGIPAIR_CONFIG__;
|
|
56477
56477
|
const _config$1 = globalInstance.__DIGIPAIR_CONFIG__ = (_globalInstance___DIGIPAIR_CONFIG__ = globalInstance.__DIGIPAIR_CONFIG__) != null ? _globalInstance___DIGIPAIR_CONFIG__ : {
|
|
56478
56478
|
LIBRARIES: {},
|
|
56479
|
-
BASE_URL: 'https://cdn.jsdelivr.net/npm'
|
|
56479
|
+
BASE_URL: 'https://cdn.jsdelivr.net/npm',
|
|
56480
|
+
ALIAS: []
|
|
56480
56481
|
};
|
|
56481
56482
|
const isRemoteVersion = /^https?:\/\/[^\s/$.?#].[^\s]*$/;
|
|
56482
56483
|
const isPinsSettings = (value)=>{
|
|
@@ -56518,7 +56519,15 @@ const applyTemplate = (value, context)=>{
|
|
|
56518
56519
|
};
|
|
56519
56520
|
const executePins = async (settingsOrigin, context = {})=>{
|
|
56520
56521
|
var _settings_conditions, _settings_conditions1;
|
|
56521
|
-
|
|
56522
|
+
let settings = await preparePinsSettings(settingsOrigin, context);
|
|
56523
|
+
const alias = _config$1.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
|
|
56524
|
+
if (alias) {
|
|
56525
|
+
settings = await preparePinsSettings(_extends({}, settings, alias), {
|
|
56526
|
+
settings: _extends({}, settings, {
|
|
56527
|
+
library: settings.library.substring(alias.name.length + 1)
|
|
56528
|
+
})
|
|
56529
|
+
});
|
|
56530
|
+
}
|
|
56522
56531
|
if ((_settings_conditions = settings.conditions) == null ? void 0 : _settings_conditions.each) {
|
|
56523
56532
|
const results = [];
|
|
56524
56533
|
for(let index = 0; index < settings.conditions.each.length; index++){
|
|
@@ -56591,7 +56600,13 @@ const executePinsList = async (pinsSettingsList, context)=>{
|
|
|
56591
56600
|
};
|
|
56592
56601
|
const generateElementFromPins = async (pinsSettings, parent, context)=>{
|
|
56593
56602
|
var _settings_conditions, _settings_conditions1;
|
|
56594
|
-
|
|
56603
|
+
let settings = await preparePinsSettings(pinsSettings, context);
|
|
56604
|
+
const alias = _config$1.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
|
|
56605
|
+
if (alias) {
|
|
56606
|
+
settings = await preparePinsSettings(_extends({}, settings, alias), {
|
|
56607
|
+
settings
|
|
56608
|
+
});
|
|
56609
|
+
}
|
|
56595
56610
|
if ((_settings_conditions = settings.conditions) == null ? void 0 : _settings_conditions.each) {
|
|
56596
56611
|
for(let index = 0; index < settings.conditions.each.length; index++){
|
|
56597
56612
|
const item = settings.conditions.each[index];
|
package/package.json
CHANGED
package/schema.en.json
DELETED
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"openapi": "3.0.0",
|
|
3
|
-
"info": {
|
|
4
|
-
"title": "@digipair/skill-web-chatbot",
|
|
5
|
-
"summary": "Display of chatbots",
|
|
6
|
-
"description": "Integration of an interactive chatbot on a web page to enhance engagement and communication with users.",
|
|
7
|
-
"version": "0.1.0",
|
|
8
|
-
"x-icon": "🤖"
|
|
9
|
-
},
|
|
10
|
-
"paths": {
|
|
11
|
-
"/digipair-chatbot-full": {
|
|
12
|
-
"post": {
|
|
13
|
-
"tags": ["web"],
|
|
14
|
-
"summary": "Full-page chatbot",
|
|
15
|
-
"description": "Displays a conversation with a chatbot in full-page mode",
|
|
16
|
-
"parameters": [
|
|
17
|
-
{
|
|
18
|
-
"name": "code",
|
|
19
|
-
"summary": "Digipair",
|
|
20
|
-
"required": true,
|
|
21
|
-
"description": "Digipair to display",
|
|
22
|
-
"schema": {
|
|
23
|
-
"type": "string"
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
"name": "apiUrl",
|
|
28
|
-
"summary": "Factory address",
|
|
29
|
-
"required": false,
|
|
30
|
-
"description": "URL address of the factory",
|
|
31
|
-
"schema": {
|
|
32
|
-
"type": "string"
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
"name": "userId",
|
|
37
|
-
"summary": "User ID",
|
|
38
|
-
"required": false,
|
|
39
|
-
"description": "Unique identifier of the user",
|
|
40
|
-
"schema": {
|
|
41
|
-
"type": "string"
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
],
|
|
45
|
-
"x-events": []
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
"/digipair-chatbot": {
|
|
49
|
-
"post": {
|
|
50
|
-
"tags": ["web"],
|
|
51
|
-
"summary": "Chatbot",
|
|
52
|
-
"description": "Displays a chatbot on a web page",
|
|
53
|
-
"parameters": [
|
|
54
|
-
{
|
|
55
|
-
"name": "code",
|
|
56
|
-
"summary": "Digipair",
|
|
57
|
-
"required": true,
|
|
58
|
-
"description": "Digipair to display",
|
|
59
|
-
"schema": {
|
|
60
|
-
"type": "string"
|
|
61
|
-
}
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
"name": "apiUrl",
|
|
65
|
-
"summary": "Factory address",
|
|
66
|
-
"required": false,
|
|
67
|
-
"description": "URL address of the factory",
|
|
68
|
-
"schema": {
|
|
69
|
-
"type": "string"
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
"name": "userId",
|
|
74
|
-
"summary": "User ID",
|
|
75
|
-
"required": false,
|
|
76
|
-
"description": "Unique identifier of the user",
|
|
77
|
-
"schema": {
|
|
78
|
-
"type": "string"
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
],
|
|
82
|
-
"x-events": []
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
},
|
|
86
|
-
"components": {
|
|
87
|
-
"schemas": {}
|
|
88
|
-
}
|
|
89
|
-
}
|