-
Notifications
You must be signed in to change notification settings - Fork 0
/
template.tpl
395 lines (370 loc) · 18.2 KB
/
template.tpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
___TERMS_OF_SERVICE___
By creating or modifying this file you agree to Google Tag Manager's Community
Template Gallery Developer Terms of Service available at
https://developers.google.com/tag-manager/gallery-tos (or such other URL as
Google may provide), as modified from time to time.
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Infoset",
"categories": [
"CHAT",
"EMAIL_MARKETING",
"LEAD_GENERATION",
"MARKETING",
"PERSONALIZATION",
"SALES"
],
"brand": {
"id": "brand_infoset",
"displayName": "Infoset",
"thumbnail": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAABGdBTUEAALGPC/xhBQAAGU9JREFUeNrtndtzVuW9x5fTjvbCaWe84aIz3nnf+kd4964ACoLQSrVrvW/AEANI1e22MZSydbdudnWgzThV2iojFdBdR4cOzJsDEBJOIZAIhEgkASQckhACOX/3/GJoI3JI8p7W4fOd+Qx3DDzr93ze9TzrOThODDNvqR6c6+vRRFILXV/lrqdNCV/bE752JjzVJzy1uL7OuJ66XU8jCU8CyDVWa+M15+uM1eB4LVpN+tpuNWq1ajVrtWs17JAIysnXw4mUlri+NriediV8ddI5IBL46rSattq2Grdap8eHLG6pZrmeFrieKl1fpyhsiNVbmq9T47VvfaBUszBCAPN4Uo+4vipcX80ULcC3BNZsfcP6CKYo5FCvTA+5vopdT3UUJsCU5sjqrM9Y38EgeYik+4qSSrietrmeBilCgBmJa9D6kPUl61OYJdtvU1v0PTepxQz5AHIwZExqsfUxTJOpqMp1v5uSl/DVRnEB5PSLY5v1NetzmGeaKSnRA0W+lrueOigmgLwOFzus71kfxERTyGxfjyV8naR4AAr6xnXS+iJGutPwL6Ufu762UCwAgZrj2mJ9E0NNpLxc33d9rXR99VEgAIGUVp/1Ueur8R7+LdVPEr6OUhQAoRgmHrU+G88tNEmlEp5uUAgAoeKG9d3YiGpRiX7oevqQBw8Q6q+JH1pfjvZbVUo/dT218sABIiGtVuvTUR0C+glfAzxogEjNaw1Y346WrDyt4eECRPpta0009gB6quSBAsRCWpWh3ZO4pFw/GD92mAcJEKch4nbr++F6s/L1I9dXNQ8QIJYLTavNAeGRlafDPDiAWA8PDwdeWvYqyJsVANx80wrs8NAm25izAoBb57QCORHP10AAuNPXQ9ZZAQDrtGa0gp0HAgD3klahV8TbPiK22wDAlLfxFGrv4cSpC2xkBo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mK9y19Om8eOcfe1MeKpPeGqx9Siurx7X0wjCQlh5mmMamag5W3/YMl6LVpO+tluNWq1azVrtWg3Hse/+P12RNnBAZ+zAAAAAAElFTkSuQmCC"
},
"description": "Infoset allows you to manage all your support and sales channels from a single platform. Install Infoset Chat on your website to engage your visitors. For more info, see infoset.app",
"containerContexts": [
"WEB"
]
}
___TEMPLATE_PARAMETERS___
[
{
"type": "TEXT",
"name": "api_key",
"displayName": "Chat Widget API Key",
"simpleValueType": true,
"alwaysInSummary": true,
"help": "Copy-Paste the API Key of your chat widget that is available in the Settings \u003e Chat Settings page.",
"valueValidators": [
{
"type": "NON_EMPTY",
"errorMessage": "This value can\u0027t be empty",
"enablingConditions": []
}
]
},
{
"type": "GROUP",
"name": "advanced",
"displayName": "Advanced settings",
"groupStyle": "ZIPPY_CLOSED",
"subParams": [
{
"type": "TEXT",
"name": "tags",
"displayName": "Tags",
"simpleValueType": true,
"alwaysInSummary": false,
"help": "(Optional) Route chats from this chat widget to a specific chat tag"
},
{
"type": "TEXT",
"name": "horizontal_padding",
"displayName": "Horizontal Padding",
"simpleValueType": true,
"alwaysInSummary": false,
"help": "(Optional) Set the padding from the side"
},
{
"type": "TEXT",
"name": "vertical_padding",
"displayName": "Vertical Padding",
"simpleValueType": true,
"alwaysInSummary": false,
"help": "(Optional) Set the padding from the bottom"
},
{
"type": "SELECT",
"selectItems": [
{
"displayValue": "Right",
"value": "right"
},
{
"displayValue": "Left",
"value": "left"
}
],
"name": "alignment",
"displayName": "Alignment",
"simpleValueType": true,
"alwaysInSummary": false,
"help": "(Optional) Align chat widget to the left or right"
},
{
"type": "TEXT",
"name": "custom_launcher",
"displayName": "Custom Launcher",
"simpleValueType": true,
"alwaysInSummary": false,
"help": "(Optional) Hide the default toggle button and use a custom HTML element to toggle the chat widget, e.g. \"#infoset_chat_launcher\""
}
]
}
]
___SANDBOXED_JS_FOR_WEB_TEMPLATE___
const injectScript = require("injectScript");
const setInWindow = require("setInWindow");
const callInWindow = require("callInWindow");
const copyFromWindow = require("copyFromWindow");
const createQueue = require("createQueue");
const dataLayerPush = createQueue('dataLayer');
const queueOperation = (params) => {
callInWindow('InfosetChat.q.push', params);
};
setInWindow('InfosetChat', function(params){
queueOperation(arguments);
});
setInWindow('InfosetChat.q', []);
var InfosetChat = copyFromWindow("InfosetChat");
InfosetChat("boot", {widget:{apiKey:data.api_key,alignment:data.alignment,horizontalPadding:data.horizontal_padding,verticalPadding:data.vertical_padding,customLauncher:data.custom_launcher}});
InfosetChat("onBoot", function(ev) {
dataLayerPush({
event: "InfosetInteractions",
eventCategory: "chat",
eventAction: "Chat Booted"
});
});
InfosetChat("onShow", function(ev) {
dataLayerPush({
event: "InfosetInteractions",
eventCategory: "chat",
eventAction: "Chat Opened"
});
});
InfosetChat("onHide", function(ev) {
dataLayerPush({
event: "InfosetInteractions",
eventCategory: "chat",
eventAction: "Chat Closed"
});
});
InfosetChat("onTriggerShow", function(ev) {
dataLayerPush({
event: "InfosetInteractions",
eventCategory: "chat",
eventAction: "Trigger Opened"
});
});
InfosetChat("onTriggerHide", function(ev) {
dataLayerPush({
event: "InfosetInteractions",
eventCategory: "chat",
eventAction: "Trigger Closed"
});
});
const url = "https://cdn.infoset.app/chat/icw.js";
injectScript(url, data.gtmOnSuccess, data.gtmOnFailure, url);
___WEB_PERMISSIONS___
[
{
"instance": {
"key": {
"publicId": "access_globals",
"versionId": "1"
},
"param": [
{
"key": "keys",
"value": {
"type": 2,
"listItem": [
{
"type": 3,
"mapKey": [
{
"type": 1,
"string": "key"
},
{
"type": 1,
"string": "read"
},
{
"type": 1,
"string": "write"
},
{
"type": 1,
"string": "execute"
}
],
"mapValue": [
{
"type": 1,
"string": "InfosetChat"
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
}
]
},
{
"type": 3,
"mapKey": [
{
"type": 1,
"string": "key"
},
{
"type": 1,
"string": "read"
},
{
"type": 1,
"string": "write"
},
{
"type": 1,
"string": "execute"
}
],
"mapValue": [
{
"type": 1,
"string": "InfosetChat.q"
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": false
}
]
},
{
"type": 3,
"mapKey": [
{
"type": 1,
"string": "key"
},
{
"type": 1,
"string": "read"
},
{
"type": 1,
"string": "write"
},
{
"type": 1,
"string": "execute"
}
],
"mapValue": [
{
"type": 1,
"string": "InfosetChat.q.push"
},
{
"type": 8,
"boolean": false
},
{
"type": 8,
"boolean": false
},
{
"type": 8,
"boolean": true
}
]
},
{
"type": 3,
"mapKey": [
{
"type": 1,
"string": "key"
},
{
"type": 1,
"string": "read"
},
{
"type": 1,
"string": "write"
},
{
"type": 1,
"string": "execute"
}
],
"mapValue": [
{
"type": 1,
"string": "dataLayer"
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
}
]
}
]
}
}
]
},
"clientAnnotations": {
"isEditedByUser": true
},
"isRequired": true
},
{
"instance": {
"key": {
"publicId": "inject_script",
"versionId": "1"
},
"param": [
{
"key": "urls",
"value": {
"type": 2,
"listItem": [
{
"type": 1,
"string": "https://cdn.infoset.app/"
}
]
}
}
]
},
"clientAnnotations": {
"isEditedByUser": true
},
"isRequired": true
}
]
___TESTS___
scenarios: []
___NOTES___
Created on 2/22/2021, 2:43:21 PM