@product7/feedback-sdk 1.3.8 → 1.3.9
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/dist/feedback-sdk.js +2824 -2371
- package/dist/feedback-sdk.js.map +1 -1
- package/dist/feedback-sdk.min.js +1 -1
- package/dist/feedback-sdk.min.js.map +1 -1
- package/package.json +1 -1
- package/src/api/services/MessengerService.js +5 -5
- package/src/core/APIService.js +33 -14
- package/src/index.js +1 -1
- package/src/styles/base.js +1 -1
- package/src/styles/changelog.js +58 -40
- package/src/styles/components.js +19 -2
- package/src/styles/design-tokens.js +4 -4
- package/src/styles/feedback.js +3 -8
- package/src/styles/messenger-components.js +473 -0
- package/src/styles/messenger-core.js +37 -268
- package/src/styles/messenger-features.js +89 -267
- package/src/styles/messenger-views.js +391 -325
- package/src/styles/messenger.js +17 -558
- package/src/styles/styles.js +21 -24
- package/src/styles/{surveys.js → survey.js} +55 -20
- package/src/widgets/BaseWidget.js +1 -1
- package/src/widgets/ButtonWidget.js +1 -1
- package/src/widgets/ChangelogWidget.js +1 -1
- package/src/widgets/InlineWidget.js +1 -1
- package/src/widgets/MessengerWidget.js +15 -9
- package/src/widgets/SurveyWidget.js +1 -1
- package/src/widgets/TabWidget.js +1 -1
- package/src/widgets/messenger/MessengerState.js +5 -2
- package/src/widgets/messenger/components/MessengerLauncher.js +22 -18
- package/src/widgets/messenger/components/MessengerPanel.js +1 -1
- package/src/widgets/messenger/components/NavigationTabs.js +36 -15
- package/src/widgets/messenger/views/ChangelogView.js +8 -32
- package/src/widgets/messenger/views/ChatView.js +96 -60
- package/src/widgets/messenger/views/ConversationsView.js +67 -45
- package/src/widgets/messenger/views/HelpView.js +22 -32
- package/src/widgets/messenger/views/HomeView.js +58 -40
- package/src/widgets/messenger/views/PreChatFormView.js +12 -5
- package/src/styles/messenger-help.js +0 -298
- package/src/styles/messenger-themes.js +0 -500
|
@@ -2,115 +2,99 @@ export const messengerCoreStyles = `
|
|
|
2
2
|
|
|
3
3
|
.messenger-launcher {
|
|
4
4
|
position: fixed;
|
|
5
|
-
z-index:
|
|
5
|
+
z-index: var(--z-modal);
|
|
6
6
|
}
|
|
7
7
|
|
|
8
8
|
.messenger-launcher-bottom-right {
|
|
9
|
-
bottom:
|
|
10
|
-
right:
|
|
9
|
+
bottom: var(--spacing-5);
|
|
10
|
+
right: var(--spacing-5);
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
.messenger-launcher-bottom-left {
|
|
14
|
-
bottom:
|
|
15
|
-
left:
|
|
14
|
+
bottom: var(--spacing-5);
|
|
15
|
+
left: var(--spacing-5);
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
.messenger-launcher-btn {
|
|
19
19
|
width: 60px;
|
|
20
20
|
height: 60px;
|
|
21
|
-
border-radius:
|
|
21
|
+
border-radius: var(--radius-full);
|
|
22
22
|
border: none;
|
|
23
|
-
background:
|
|
24
|
-
color: white;
|
|
23
|
+
background: var(--color-primary);
|
|
24
|
+
color: var(--color-white);
|
|
25
25
|
cursor: pointer;
|
|
26
26
|
display: flex;
|
|
27
27
|
align-items: center;
|
|
28
28
|
justify-content: center;
|
|
29
|
-
box-shadow:
|
|
30
|
-
transition: all
|
|
29
|
+
box-shadow: var(--shadow-lg);
|
|
30
|
+
transition: all var(--transition-slow);
|
|
31
31
|
position: relative;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
.messenger-launcher-btn:hover {
|
|
35
|
-
transform:
|
|
36
|
-
box-shadow:
|
|
35
|
+
transform: translateY(-2px);
|
|
36
|
+
box-shadow: var(--shadow-xl);
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
.messenger-launcher-btn:active {
|
|
40
40
|
transform: scale(0.95);
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
.messenger-launcher-icon {
|
|
44
|
-
display: flex;
|
|
45
|
-
align-items: center;
|
|
46
|
-
justify-content: center;
|
|
47
|
-
transition: opacity 0.2s ease, transform 0.2s ease;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
.messenger-launcher-open .messenger-launcher-icon-chat {
|
|
51
|
-
opacity: 0;
|
|
52
|
-
transform: rotate(-90deg);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.messenger-launcher-open .messenger-launcher-icon-close {
|
|
56
|
-
opacity: 1;
|
|
57
|
-
transform: rotate(0deg);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
43
|
.messenger-launcher-badge {
|
|
61
44
|
position: absolute;
|
|
62
45
|
top: -4px;
|
|
63
46
|
right: -4px;
|
|
64
47
|
min-width: 20px;
|
|
65
48
|
height: 20px;
|
|
66
|
-
background:
|
|
67
|
-
color: white;
|
|
68
|
-
font-size:
|
|
69
|
-
font-weight:
|
|
70
|
-
border-radius:
|
|
49
|
+
background: var(--color-error);
|
|
50
|
+
color: var(--color-white);
|
|
51
|
+
font-size: var(--font-size-xs);
|
|
52
|
+
font-weight: var(--font-weight-semibold);
|
|
53
|
+
border-radius: var(--radius-full);
|
|
71
54
|
display: flex;
|
|
72
55
|
align-items: center;
|
|
73
56
|
justify-content: center;
|
|
74
57
|
padding: 0 6px;
|
|
75
|
-
border: 2px solid white;
|
|
58
|
+
border: 2px solid var(--color-white);
|
|
76
59
|
}
|
|
77
60
|
|
|
78
|
-
|
|
79
61
|
.messenger-panel {
|
|
80
62
|
position: fixed;
|
|
81
|
-
z-index:
|
|
82
|
-
width:
|
|
83
|
-
height:
|
|
63
|
+
z-index: var(--z-popover);
|
|
64
|
+
width: 440px;
|
|
65
|
+
height: 720px;
|
|
84
66
|
max-height: calc(100vh - 100px);
|
|
85
67
|
display: none;
|
|
86
68
|
opacity: 0;
|
|
87
69
|
transform: translateY(20px) scale(0.95);
|
|
88
|
-
transition: all
|
|
70
|
+
transition: all var(--transition-slow);
|
|
89
71
|
}
|
|
90
72
|
|
|
91
73
|
.messenger-panel.open {
|
|
74
|
+
display: block;
|
|
92
75
|
opacity: 1;
|
|
93
76
|
transform: translateY(0) scale(1);
|
|
94
77
|
}
|
|
95
78
|
|
|
96
79
|
.messenger-panel-bottom-right {
|
|
97
80
|
bottom: 90px;
|
|
98
|
-
right:
|
|
81
|
+
right: var(--spacing-5);
|
|
99
82
|
}
|
|
100
83
|
|
|
101
84
|
.messenger-panel-bottom-left {
|
|
102
85
|
bottom: 90px;
|
|
103
|
-
left:
|
|
86
|
+
left: var(--spacing-5);
|
|
104
87
|
}
|
|
105
88
|
|
|
106
89
|
.messenger-panel-content {
|
|
107
|
-
background:
|
|
90
|
+
background: var(--color-white);
|
|
108
91
|
height: 100%;
|
|
109
|
-
border-radius:
|
|
92
|
+
border-radius: var(--radius-2xl);
|
|
110
93
|
overflow: hidden;
|
|
111
94
|
display: flex;
|
|
112
95
|
flex-direction: column;
|
|
113
|
-
box-shadow: 0
|
|
96
|
+
box-shadow: rgba(50, 50, 93, 0.25) 0px 2px 5px -1px, rgba(0, 0, 0, 0.3) 0px 1px 3px -1px;
|
|
97
|
+
border: 1px solid var(--color-border);
|
|
114
98
|
}
|
|
115
99
|
|
|
116
100
|
.messenger-panel-views {
|
|
@@ -127,242 +111,27 @@ export const messengerCoreStyles = `
|
|
|
127
111
|
overflow: hidden;
|
|
128
112
|
}
|
|
129
113
|
|
|
130
|
-
|
|
131
|
-
.messenger-close-btn,
|
|
132
|
-
.messenger-back-btn {
|
|
133
|
-
background: none;
|
|
134
|
-
border: none;
|
|
135
|
-
padding: 8px;
|
|
136
|
-
cursor: pointer;
|
|
137
|
-
color: rgba(255, 255, 255, 0.6);
|
|
138
|
-
border-radius: 8px;
|
|
139
|
-
display: flex;
|
|
140
|
-
align-items: center;
|
|
141
|
-
justify-content: center;
|
|
142
|
-
transition: all 0.2s ease;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.messenger-close-btn:hover,
|
|
146
|
-
.messenger-back-btn:hover {
|
|
147
|
-
background: rgba(255, 255, 255, 0.1);
|
|
148
|
-
color: white;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
/* Avatar Stack */
|
|
152
114
|
.messenger-avatar-stack {
|
|
153
115
|
display: flex;
|
|
154
116
|
align-items: center;
|
|
155
117
|
}
|
|
156
118
|
|
|
157
|
-
.messenger-avatar {
|
|
158
|
-
width: 32px;
|
|
159
|
-
height: 32px;
|
|
160
|
-
border-radius: 50%;
|
|
161
|
-
border: 2px solid #1c1c1e;
|
|
162
|
-
background: #5856d6;
|
|
163
|
-
color: white;
|
|
164
|
-
font-size: 13px;
|
|
165
|
-
font-weight: 600;
|
|
166
|
-
display: flex;
|
|
167
|
-
align-items: center;
|
|
168
|
-
justify-content: center;
|
|
119
|
+
.messenger-avatar-stack .sdk-avatar {
|
|
169
120
|
margin-left: -8px;
|
|
170
|
-
object-fit: cover;
|
|
171
121
|
}
|
|
172
122
|
|
|
173
|
-
.messenger-avatar:first-child {
|
|
123
|
+
.messenger-avatar-stack .sdk-avatar:first-child {
|
|
174
124
|
margin-left: 0;
|
|
175
125
|
}
|
|
176
126
|
|
|
177
|
-
.messenger-avatar-
|
|
178
|
-
width: 28px;
|
|
179
|
-
height: 28px;
|
|
180
|
-
font-size: 11px;
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
.messenger-avatar-medium {
|
|
184
|
-
width: 40px;
|
|
185
|
-
height: 40px;
|
|
186
|
-
font-size: 15px;
|
|
187
|
-
font-weight: 600;
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
.messenger-avatar-tiny {
|
|
191
|
-
width: 20px;
|
|
192
|
-
height: 20px;
|
|
193
|
-
font-size: 9px;
|
|
194
|
-
border-width: 1.5px;
|
|
127
|
+
.messenger-avatar-stack-tiny .sdk-avatar {
|
|
195
128
|
margin-left: -6px;
|
|
196
129
|
}
|
|
197
130
|
|
|
198
|
-
.messenger-avatar-tiny:first-child {
|
|
131
|
+
.messenger-avatar-stack-tiny .sdk-avatar:first-child {
|
|
199
132
|
margin-left: 0;
|
|
200
133
|
}
|
|
201
134
|
|
|
202
|
-
.messenger-panel-nav {
|
|
203
|
-
border-top: 1px solid rgba(255, 255, 255, 0.1);
|
|
204
|
-
background: #1c1c1e;
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
.messenger-nav {
|
|
208
|
-
display: flex;
|
|
209
|
-
padding: 4px 8px;
|
|
210
|
-
gap: 4px;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
.messenger-nav-tab {
|
|
214
|
-
flex: 1;
|
|
215
|
-
display: flex;
|
|
216
|
-
flex-direction: column;
|
|
217
|
-
align-items: center;
|
|
218
|
-
gap: 4px;
|
|
219
|
-
padding: 8px 4px;
|
|
220
|
-
background: none;
|
|
221
|
-
border: none;
|
|
222
|
-
cursor: pointer;
|
|
223
|
-
border-radius: 8px;
|
|
224
|
-
transition: all 0.2s ease;
|
|
225
|
-
position: relative;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
.messenger-nav-tab:hover {
|
|
229
|
-
background: rgba(255, 255, 255, 0.05);
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
.messenger-nav-icon {
|
|
233
|
-
color: rgba(255, 255, 255, 0.5);
|
|
234
|
-
transition: color 0.2s ease;
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
.messenger-nav-home-icon {
|
|
238
|
-
position: relative;
|
|
239
|
-
display: inline-flex;
|
|
240
|
-
align-items: center;
|
|
241
|
-
justify-content: center;
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
.messenger-nav-home-icon > i:first-child {
|
|
245
|
-
position: relative;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
.messenger-nav-home-icon > i:last-child {
|
|
249
|
-
position: absolute;
|
|
250
|
-
top: 8px;
|
|
251
|
-
left: 50%;
|
|
252
|
-
transform: translateX(-50%);
|
|
253
|
-
transition: color 0.2s ease, filter 0.2s ease;
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
.messenger-nav-tab:hover .messenger-nav-home-icon > i:last-child {
|
|
257
|
-
color: #ffd700;
|
|
258
|
-
filter: drop-shadow(0 0 4px #ffd700);
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
.messenger-nav-label {
|
|
262
|
-
font-size: 11px;
|
|
263
|
-
font-weight: 500;
|
|
264
|
-
color: rgba(255, 255, 255, 0.5);
|
|
265
|
-
transition: color 0.2s ease;
|
|
266
|
-
}
|
|
267
|
-
|
|
268
|
-
.messenger-nav-tab.active .messenger-nav-icon {
|
|
269
|
-
color: white;
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
.messenger-nav-tab.active .messenger-nav-label {
|
|
273
|
-
color: white;
|
|
274
|
-
font-weight: 400;
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
.messenger-nav-badge {
|
|
278
|
-
position: absolute;
|
|
279
|
-
top: 4px;
|
|
280
|
-
right: calc(50% - 16px);
|
|
281
|
-
min-width: 16px;
|
|
282
|
-
height: 16px;
|
|
283
|
-
background: #ef4444;
|
|
284
|
-
color: white;
|
|
285
|
-
font-size: 10px;
|
|
286
|
-
font-weight: 600;
|
|
287
|
-
border-radius: 8px;
|
|
288
|
-
display: flex;
|
|
289
|
-
align-items: center;
|
|
290
|
-
justify-content: center;
|
|
291
|
-
padding: 0 4px;
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
.messenger-home-availability,
|
|
295
|
-
.messenger-chat-availability {
|
|
296
|
-
display: flex;
|
|
297
|
-
align-items: center;
|
|
298
|
-
gap: 6px;
|
|
299
|
-
margin-top: 8px;
|
|
300
|
-
font-size: 13px;
|
|
301
|
-
color: rgba(255, 255, 255, 0.7);
|
|
302
|
-
}
|
|
303
|
-
|
|
304
|
-
.messenger-availability-dot {
|
|
305
|
-
width: 8px;
|
|
306
|
-
height: 8px;
|
|
307
|
-
border-radius: 50%;
|
|
308
|
-
flex-shrink: 0;
|
|
309
|
-
}
|
|
310
|
-
|
|
311
|
-
.messenger-availability-online {
|
|
312
|
-
background: #22c55e;
|
|
313
|
-
box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
.messenger-availability-away {
|
|
317
|
-
background: #9ca3af;
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
.messenger-availability-text {
|
|
321
|
-
opacity: 0.9;
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
.messenger-typing-indicator {
|
|
325
|
-
display: flex;
|
|
326
|
-
align-items: center;
|
|
327
|
-
gap: 8px;
|
|
328
|
-
padding: 8px 12px;
|
|
329
|
-
margin: 4px 0;
|
|
330
|
-
}
|
|
331
|
-
|
|
332
|
-
.messenger-typing-dots {
|
|
333
|
-
display: flex;
|
|
334
|
-
align-items: center;
|
|
335
|
-
gap: 4px;
|
|
336
|
-
background: #374151;
|
|
337
|
-
padding: 8px 12px;
|
|
338
|
-
border-radius: 16px;
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
.messenger-typing-dots span {
|
|
342
|
-
width: 6px;
|
|
343
|
-
height: 6px;
|
|
344
|
-
background: #9ca3af;
|
|
345
|
-
border-radius: 50%;
|
|
346
|
-
animation: messenger-typing-bounce 1.4s infinite ease-in-out;
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
.messenger-typing-dots span:nth-child(1) {
|
|
350
|
-
animation-delay: -0.32s;
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
.messenger-typing-dots span:nth-child(2) {
|
|
354
|
-
animation-delay: -0.16s;
|
|
355
|
-
}
|
|
356
|
-
|
|
357
|
-
.messenger-typing-dots span:nth-child(3) {
|
|
358
|
-
animation-delay: 0s;
|
|
359
|
-
}
|
|
360
|
-
|
|
361
|
-
.messenger-typing-text {
|
|
362
|
-
font-size: 12px;
|
|
363
|
-
color: #9ca3af;
|
|
364
|
-
}
|
|
365
|
-
|
|
366
135
|
@media (max-width: 480px) {
|
|
367
136
|
.messenger-panel {
|
|
368
137
|
width: 100%;
|
|
@@ -379,12 +148,12 @@ export const messengerCoreStyles = `
|
|
|
379
148
|
}
|
|
380
149
|
|
|
381
150
|
.messenger-launcher {
|
|
382
|
-
bottom:
|
|
383
|
-
right:
|
|
151
|
+
bottom: var(--spacing-4);
|
|
152
|
+
right: var(--spacing-4);
|
|
384
153
|
}
|
|
385
154
|
|
|
386
155
|
.messenger-launcher-bottom-left {
|
|
387
|
-
left:
|
|
156
|
+
left: var(--spacing-4);
|
|
388
157
|
}
|
|
389
158
|
}
|
|
390
|
-
`;
|
|
159
|
+
`;
|