@openreplay/tracker 11.0.0 → 11.0.2

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.
Files changed (92) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/cjs/app/index.d.ts +3 -0
  3. package/cjs/app/index.js +27 -4
  4. package/cjs/index.d.ts +1 -0
  5. package/cjs/index.js +7 -1
  6. package/cjs/modules/Network/fetchProxy.js +4 -2
  7. package/cjs/modules/userTesting/SignalManager.d.ts +29 -0
  8. package/cjs/modules/userTesting/SignalManager.js +83 -0
  9. package/cjs/modules/userTesting/index.d.ts +5 -5
  10. package/cjs/modules/userTesting/index.js +156 -189
  11. package/cjs/modules/userTesting/styles.d.ts +28 -11
  12. package/cjs/modules/userTesting/styles.js +51 -29
  13. package/cjs/modules/userTesting/utils.d.ts +9 -0
  14. package/cjs/modules/userTesting/utils.js +87 -0
  15. package/coverage/clover.xml +1331 -562
  16. package/coverage/coverage-final.json +13 -6
  17. package/coverage/lcov-report/index.html +49 -34
  18. package/coverage/lcov-report/main/app/canvas.ts.html +1 -1
  19. package/coverage/lcov-report/main/app/guards.ts.html +42 -42
  20. package/coverage/lcov-report/main/app/index.html +24 -24
  21. package/coverage/lcov-report/main/app/index.ts.html +1046 -56
  22. package/coverage/lcov-report/main/app/logger.ts.html +1 -1
  23. package/coverage/lcov-report/main/app/messages.gen.ts.html +1 -1
  24. package/coverage/lcov-report/main/app/nodes.ts.html +1 -1
  25. package/coverage/lcov-report/main/app/observer/iframe_observer.ts.html +1 -1
  26. package/coverage/lcov-report/main/app/observer/iframe_offsets.ts.html +1 -1
  27. package/coverage/lcov-report/main/app/observer/index.html +1 -1
  28. package/coverage/lcov-report/main/app/observer/shadow_root_observer.ts.html +1 -1
  29. package/coverage/lcov-report/main/app/observer/top_observer.ts.html +1 -1
  30. package/coverage/lcov-report/main/app/sanitizer.ts.html +1 -1
  31. package/coverage/lcov-report/main/app/session.ts.html +1 -1
  32. package/coverage/lcov-report/main/app/ticker.ts.html +1 -1
  33. package/coverage/lcov-report/main/index.html +11 -11
  34. package/coverage/lcov-report/main/index.ts.html +274 -100
  35. package/coverage/lcov-report/main/modules/Network/beaconProxy.ts.html +1 -1
  36. package/coverage/lcov-report/main/modules/Network/fetchProxy.ts.html +1 -1
  37. package/coverage/lcov-report/main/modules/Network/index.html +1 -1
  38. package/coverage/lcov-report/main/modules/Network/index.ts.html +1 -1
  39. package/coverage/lcov-report/main/modules/Network/networkMessage.ts.html +1 -1
  40. package/coverage/lcov-report/main/modules/Network/utils.ts.html +1 -1
  41. package/coverage/lcov-report/main/modules/Network/xhrProxy.ts.html +1 -1
  42. package/coverage/lcov-report/main/modules/attributeSender.ts.html +1 -1
  43. package/coverage/lcov-report/main/modules/axiosSpy.ts.html +1 -1
  44. package/coverage/lcov-report/main/modules/conditionsManager.ts.html +799 -0
  45. package/coverage/lcov-report/main/modules/connection.ts.html +1 -1
  46. package/coverage/lcov-report/main/modules/console.ts.html +1 -1
  47. package/coverage/lcov-report/main/modules/constructedStyleSheets.ts.html +1 -1
  48. package/coverage/lcov-report/main/modules/cssrules.ts.html +1 -1
  49. package/coverage/lcov-report/main/modules/exception.ts.html +1 -1
  50. package/coverage/lcov-report/main/modules/featureFlags.ts.html +10 -7
  51. package/coverage/lcov-report/main/modules/focus.ts.html +1 -1
  52. package/coverage/lcov-report/main/modules/fonts.ts.html +1 -1
  53. package/coverage/lcov-report/main/modules/img.ts.html +1 -1
  54. package/coverage/lcov-report/main/modules/index.html +27 -12
  55. package/coverage/lcov-report/main/modules/input.ts.html +1 -1
  56. package/coverage/lcov-report/main/modules/mouse.ts.html +1 -1
  57. package/coverage/lcov-report/main/modules/network.ts.html +1 -1
  58. package/coverage/lcov-report/main/modules/performance.ts.html +1 -1
  59. package/coverage/lcov-report/main/modules/scroll.ts.html +1 -1
  60. package/coverage/lcov-report/main/modules/selection.ts.html +1 -1
  61. package/coverage/lcov-report/main/modules/tabs.ts.html +1 -1
  62. package/coverage/lcov-report/main/modules/timing.ts.html +1 -1
  63. package/coverage/lcov-report/main/modules/userTesting/SignalManager.ts.html +370 -0
  64. package/coverage/lcov-report/main/modules/userTesting/dnd.ts.html +10 -22
  65. package/coverage/lcov-report/main/modules/userTesting/index.html +57 -27
  66. package/coverage/lcov-report/main/modules/userTesting/index.ts.html +814 -115
  67. package/coverage/lcov-report/main/modules/userTesting/recorder.ts.html +136 -67
  68. package/coverage/lcov-report/main/modules/userTesting/styles.ts.html +111 -39
  69. package/coverage/lcov-report/main/modules/userTesting/utils.ts.html +364 -0
  70. package/coverage/lcov-report/main/modules/viewport.ts.html +1 -1
  71. package/coverage/lcov-report/main/utils.ts.html +48 -6
  72. package/coverage/lcov-report/webworker/BatchWriter.ts.html +1 -1
  73. package/coverage/lcov-report/webworker/MessageEncoder.gen.ts.html +1 -1
  74. package/coverage/lcov-report/webworker/PrimitiveEncoder.ts.html +1 -1
  75. package/coverage/lcov-report/webworker/QueueSender.ts.html +1 -1
  76. package/coverage/lcov-report/webworker/index.html +5 -5
  77. package/coverage/lcov-report/webworker/index.ts.html +15 -9
  78. package/coverage/lcov.info +2306 -900
  79. package/lib/app/index.d.ts +3 -0
  80. package/lib/app/index.js +27 -4
  81. package/lib/index.d.ts +1 -0
  82. package/lib/index.js +7 -1
  83. package/lib/modules/Network/fetchProxy.js +4 -2
  84. package/lib/modules/userTesting/SignalManager.d.ts +29 -0
  85. package/lib/modules/userTesting/SignalManager.js +80 -0
  86. package/lib/modules/userTesting/index.d.ts +5 -5
  87. package/lib/modules/userTesting/index.js +128 -161
  88. package/lib/modules/userTesting/styles.d.ts +28 -11
  89. package/lib/modules/userTesting/styles.js +50 -28
  90. package/lib/modules/userTesting/utils.d.ts +9 -0
  91. package/lib/modules/userTesting/utils.js +79 -0
  92. package/package.json +1 -1
@@ -9,6 +9,7 @@ export declare const bgStyle: {
9
9
  alignItems: string;
10
10
  justifyContent: string;
11
11
  zIndex: number;
12
+ fontFamily: string;
12
13
  };
13
14
  export declare const containerStyle: {
14
15
  display: string;
@@ -27,6 +28,7 @@ export declare const containerWidgetStyle: {
27
28
  gap: string;
28
29
  'align-items': string;
29
30
  padding: string;
31
+ fontFamily: string;
30
32
  'border-radius': string;
31
33
  border: string;
32
34
  background: string;
@@ -50,6 +52,7 @@ export declare const descriptionStyle: {
50
52
  fontStyle: string;
51
53
  fontWeight: string;
52
54
  lineHeight: string;
55
+ whiteSpace: string;
53
56
  };
54
57
  export declare const noticeStyle: {
55
58
  color: string;
@@ -93,6 +96,8 @@ export declare const contentStyle: {
93
96
  flexDirection: string;
94
97
  alignItems: string;
95
98
  gap: string;
99
+ fontSize: string;
100
+ lineHeight: string;
96
101
  };
97
102
  export declare const titleWidgetStyle: {
98
103
  padding: string;
@@ -114,17 +119,14 @@ export declare const descriptionWidgetStyle: {
114
119
  boxSizing: string;
115
120
  display: string;
116
121
  width: string;
117
- borderRadius: string;
118
- border: string;
122
+ borderBottom: string;
119
123
  background: string;
120
124
  padding: string;
121
125
  alignSelf: string;
122
126
  color: string;
123
127
  fontFamily: string;
124
- fontSize: string;
125
128
  fontStyle: string;
126
129
  fontWeight: string;
127
- lineHeight: string;
128
130
  };
129
131
  export declare const endSectionStyle: {
130
132
  display: string;
@@ -133,17 +135,14 @@ export declare const endSectionStyle: {
133
135
  gap: string;
134
136
  boxSizing: string;
135
137
  width: string;
136
- borderRadius: string;
137
- border: string;
138
+ borderBottom: string;
138
139
  background: string;
139
140
  padding: string;
140
141
  alignSelf: string;
141
142
  color: string;
142
143
  fontFamily: string;
143
- fontSize: string;
144
144
  fontStyle: string;
145
145
  fontWeight: string;
146
- lineHeight: string;
147
146
  };
148
147
  export declare const symbolIcon: {
149
148
  fontSize: string;
@@ -174,9 +173,12 @@ export declare const buttonWidgetStyle: {
174
173
  };
175
174
  export declare const stopWidgetStyle: {
176
175
  marginTop: string;
176
+ marginBottom: string;
177
177
  cursor: string;
178
178
  display: string;
179
179
  fontWeight: string;
180
+ fontSize: string;
181
+ lineHeight: string;
180
182
  };
181
183
  export declare const paginationStyle: {
182
184
  display: string;
@@ -189,21 +191,27 @@ export declare const paginationStyle: {
189
191
  };
190
192
  export declare const taskNumberActive: {
191
193
  display: string;
192
- padding: string;
193
194
  flexDirection: string;
194
195
  alignItems: string;
196
+ justifyContent: string;
195
197
  borderRadius: string;
196
198
  outline: string;
199
+ fontSize: string;
200
+ height: string;
201
+ width: string;
197
202
  };
198
203
  export declare const taskNumberDone: {
199
204
  display: string;
200
- padding: string;
201
205
  flexDirection: string;
202
206
  alignItems: string;
207
+ justifyContent: string;
203
208
  borderRadius: string;
204
209
  outline: string;
205
210
  boxShadow: string;
206
211
  background: string;
212
+ fontSize: string;
213
+ height: string;
214
+ width: string;
207
215
  };
208
216
  export declare const taskDescriptionCard: {
209
217
  borderRadius: string;
@@ -220,7 +228,8 @@ export declare const taskTextStyle: {
220
228
  fontWeight: string;
221
229
  };
222
230
  export declare const taskDescriptionStyle: {
223
- color: string;
231
+ fontSize: string;
232
+ lineHeight: string;
224
233
  };
225
234
  export declare const taskButtonStyle: {
226
235
  marginRight: string;
@@ -258,3 +267,11 @@ export declare const taskButtonsRow: {
258
267
  width: string;
259
268
  boxSizing: string;
260
269
  };
270
+ export declare const spinnerStyles: {
271
+ border: string;
272
+ width: string;
273
+ height: string;
274
+ borderRadius: string;
275
+ borderLeftColor: string;
276
+ animation: string;
277
+ };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.taskButtonsRow = exports.taskButtonBorderedStyle = exports.taskButtonStyle = exports.taskDescriptionStyle = exports.taskTextStyle = exports.taskDescriptionCard = exports.taskNumberDone = exports.taskNumberActive = exports.paginationStyle = exports.stopWidgetStyle = exports.buttonWidgetStyle = exports.symbolIcon = exports.endSectionStyle = exports.descriptionWidgetStyle = exports.titleWidgetStyle = exports.contentStyle = exports.sectionTitleStyle = exports.buttonStyle = exports.noticeStyle = exports.descriptionStyle = exports.titleStyle = exports.containerWidgetStyle = exports.containerStyle = exports.bgStyle = void 0;
3
+ exports.spinnerStyles = exports.taskButtonsRow = exports.taskButtonBorderedStyle = exports.taskButtonStyle = exports.taskDescriptionStyle = exports.taskTextStyle = exports.taskDescriptionCard = exports.taskNumberDone = exports.taskNumberActive = exports.paginationStyle = exports.stopWidgetStyle = exports.buttonWidgetStyle = exports.symbolIcon = exports.endSectionStyle = exports.descriptionWidgetStyle = exports.titleWidgetStyle = exports.contentStyle = exports.sectionTitleStyle = exports.buttonStyle = exports.noticeStyle = exports.descriptionStyle = exports.titleStyle = exports.containerWidgetStyle = exports.containerStyle = exports.bgStyle = void 0;
4
4
  exports.bgStyle = {
5
5
  position: 'fixed',
6
6
  top: 0,
@@ -12,28 +12,30 @@ exports.bgStyle = {
12
12
  alignItems: 'center',
13
13
  justifyContent: 'center',
14
14
  zIndex: 999999,
15
+ fontFamily: `-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"`,
15
16
  };
16
17
  exports.containerStyle = {
17
18
  display: 'flex',
18
19
  flexDirection: 'column',
19
- gap: '8px',
20
+ gap: '2rem',
20
21
  alignItems: 'center',
21
22
  padding: '1.5rem',
22
- borderRadius: '0.375rem',
23
+ borderRadius: '2px',
23
24
  border: '1px solid #D9D9D9',
24
25
  background: '#FFF',
25
- width: '29rem',
26
+ width: '22rem',
26
27
  };
27
28
  exports.containerWidgetStyle = {
28
29
  display: 'flex',
29
30
  'flex-direction': 'column',
30
- gap: '8px',
31
+ gap: 'unset',
31
32
  'align-items': 'center',
32
- padding: '1rem',
33
- 'border-radius': '0.375rem',
33
+ padding: 'unset',
34
+ fontFamily: `-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"`,
35
+ 'border-radius': '2px',
34
36
  border: '1px solid #D9D9D9',
35
- background: '#FFF',
36
- width: '29rem',
37
+ background: 'rgba(255, 255, 255, 0.75)',
38
+ width: '22rem',
37
39
  };
38
40
  exports.titleStyle = {
39
41
  fontFamily: 'Verdana, sans-serif',
@@ -49,10 +51,11 @@ exports.descriptionStyle = {
49
51
  padding: '1.25rem 0rem',
50
52
  color: 'rgba(0, 0, 0, 0.85)',
51
53
  fontFamily: 'Verdana, sans-serif',
52
- fontSize: '1rem',
54
+ fontSize: '13px',
53
55
  fontStyle: 'normal',
54
56
  fontWeight: '400',
55
- lineHeight: '1.5rem',
57
+ lineHeight: 'auto',
58
+ whiteSpace: 'pre-wrap',
56
59
  };
57
60
  exports.noticeStyle = {
58
61
  color: 'rgba(0, 0, 0, 0.85)',
@@ -83,9 +86,9 @@ exports.buttonStyle = {
83
86
  };
84
87
  exports.sectionTitleStyle = {
85
88
  fontFamily: 'Verdana, sans-serif',
86
- fontSize: '0.875rem',
89
+ fontSize: '13px',
87
90
  fontWeight: '500',
88
- lineHeight: '1.375rem',
91
+ lineHeight: 'auto',
89
92
  display: 'flex',
90
93
  justifyContent: 'space-between',
91
94
  width: '100%',
@@ -96,39 +99,40 @@ exports.contentStyle = {
96
99
  flexDirection: 'column',
97
100
  alignItems: 'flex-start',
98
101
  gap: '0.625rem',
102
+ fontSize: '13px',
103
+ lineHeight: 'auto',
99
104
  };
100
105
  // New widget styles
101
106
  exports.titleWidgetStyle = {
102
107
  padding: '0.5rem',
103
108
  gap: '0.5rem',
104
109
  fontFamily: 'Verdana, sans-serif',
105
- fontSize: '1.25rem',
110
+ fontSize: '16px',
106
111
  fontStyle: 'normal',
107
112
  fontWeight: '500',
108
- lineHeight: '1.75rem',
113
+ lineHeight: 'auto',
109
114
  color: 'white',
110
115
  display: 'flex',
111
116
  alignItems: 'center',
112
117
  width: '100%',
113
- borderRadius: '0.375rem',
114
- background: 'rgba(0, 0, 0, 0.60)',
118
+ borderRadius: '2px',
119
+ background: 'rgba(0, 0, 0, 0.75)',
115
120
  boxSizing: 'border-box',
116
121
  };
117
122
  exports.descriptionWidgetStyle = {
118
123
  boxSizing: 'border-box',
119
124
  display: 'block',
120
125
  width: '100%',
121
- borderRadius: '0.375rem',
122
- border: '1px solid #D9D9D9',
126
+ borderBottom: '1px solid #D9D9D9',
123
127
  background: '#FFF',
124
- padding: '0.625rem 1rem',
128
+ padding: '0.65rem',
125
129
  alignSelf: 'stretch',
126
130
  color: '#000',
127
131
  fontFamily: 'Verdana, sans-serif',
128
- fontSize: '0.875rem',
132
+ // fontSize: '0.875rem',
129
133
  fontStyle: 'normal',
130
134
  fontWeight: '400',
131
- lineHeight: '1.375rem',
135
+ // lineHeight: '1.375rem',
132
136
  };
133
137
  exports.endSectionStyle = Object.assign(Object.assign({}, exports.descriptionWidgetStyle), { display: 'flex', flexDirection: 'column', alignItems: 'center', gap: '0.625rem' });
134
138
  exports.symbolIcon = {
@@ -159,10 +163,13 @@ exports.buttonWidgetStyle = {
159
163
  cursor: 'pointer',
160
164
  };
161
165
  exports.stopWidgetStyle = {
162
- marginTop: '2rem',
166
+ marginTop: '1rem',
167
+ marginBottom: '1rem',
163
168
  cursor: 'pointer',
164
169
  display: 'block',
165
- fontWeight: '600',
170
+ fontWeight: '500',
171
+ fontSize: '13px!important',
172
+ lineHeight: 'auto',
166
173
  };
167
174
  exports.paginationStyle = {
168
175
  display: 'flex',
@@ -175,21 +182,27 @@ exports.paginationStyle = {
175
182
  };
176
183
  exports.taskNumberActive = {
177
184
  display: 'flex',
178
- padding: '0.0625rem 0.5rem',
179
185
  flexDirection: 'column',
180
186
  alignItems: 'center',
187
+ justifyContent: 'center',
181
188
  borderRadius: '6.25em',
182
189
  outline: '1px solid #394EFF',
190
+ fontSize: '13px',
191
+ height: '24px',
192
+ width: '24px',
183
193
  };
184
194
  exports.taskNumberDone = {
185
195
  display: 'flex',
186
- padding: '0.0625rem 0.5rem',
187
196
  flexDirection: 'column',
188
197
  alignItems: 'center',
198
+ justifyContent: 'center',
189
199
  borderRadius: '6.25em',
190
200
  outline: '1px solid #D2DFFF',
191
201
  boxShadow: '0px 2px 0px 0px rgba(0, 0, 0, 0.04)',
192
202
  background: '#D2DFFF',
203
+ fontSize: '13px',
204
+ height: '24px',
205
+ width: '24px',
193
206
  };
194
207
  exports.taskDescriptionCard = {
195
208
  borderRadius: '0.375rem',
@@ -206,7 +219,8 @@ exports.taskTextStyle = {
206
219
  fontWeight: 'bold',
207
220
  };
208
221
  exports.taskDescriptionStyle = {
209
- color: '#8C8C8C',
222
+ fontSize: '13px',
223
+ lineHeight: 'auto',
210
224
  };
211
225
  exports.taskButtonStyle = {
212
226
  marginRight: '0.5rem',
@@ -214,10 +228,10 @@ exports.taskButtonStyle = {
214
228
  color: '#394EFF',
215
229
  textAlign: 'center',
216
230
  fontFamily: 'Verdana, sans-serif',
217
- fontSize: '0.875rem',
231
+ fontSize: '13px',
218
232
  fontStyle: 'normal',
219
233
  fontWeight: '500',
220
- lineHeight: '1.375rem',
234
+ lineHeight: 'auto',
221
235
  };
222
236
  exports.taskButtonBorderedStyle = Object.assign(Object.assign({}, exports.taskButtonStyle), { display: 'flex', padding: '0.25rem 0.9375rem', justifyContent: 'center', alignItems: 'center', gap: '0.5rem', borderRadius: '0.25rem', border: '1px solid #394EFF' });
223
237
  exports.taskButtonsRow = {
@@ -227,3 +241,11 @@ exports.taskButtonsRow = {
227
241
  width: '100%',
228
242
  boxSizing: 'border-box',
229
243
  };
244
+ exports.spinnerStyles = {
245
+ border: '4px solid rgba(255, 255, 255, 0.4)',
246
+ width: '16px',
247
+ height: '16px',
248
+ borderRadius: '50%',
249
+ borderLeftColor: '#fff',
250
+ animation: 'spin 0.5s linear infinite',
251
+ };
@@ -0,0 +1,9 @@
1
+ export declare function generateGrid(): HTMLDivElement;
2
+ export declare function generateChevron(): HTMLDivElement;
3
+ export declare function addKeyframes(): void;
4
+ export declare function createSpinner(): HTMLDivElement;
5
+ export declare function createElement(tag: string, className: string, styles: any, textContent?: string, id?: string): HTMLElement;
6
+ export declare const TEST_START = "or_uxt_test_start";
7
+ export declare const TASK_IND = "or_uxt_task_index";
8
+ export declare const SESSION_ID = "or_uxt_session_id";
9
+ export declare const TEST_ID = "or_uxt_test_id";
@@ -0,0 +1,87 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TEST_ID = exports.SESSION_ID = exports.TASK_IND = exports.TEST_START = exports.createElement = exports.createSpinner = exports.addKeyframes = exports.generateChevron = exports.generateGrid = void 0;
4
+ const styles_js_1 = require("./styles.js");
5
+ function generateGrid() {
6
+ const grid = document.createElement('div');
7
+ grid.className = 'grid';
8
+ for (let i = 0; i < 16; i++) {
9
+ const cell = document.createElement('div');
10
+ Object.assign(cell.style, {
11
+ width: '2px',
12
+ height: '2px',
13
+ borderRadius: '10px',
14
+ background: 'white',
15
+ });
16
+ cell.className = 'cell';
17
+ grid.appendChild(cell);
18
+ }
19
+ Object.assign(grid.style, {
20
+ display: 'grid',
21
+ gridTemplateColumns: 'repeat(4, 1fr)',
22
+ gridTemplateRows: 'repeat(4, 1fr)',
23
+ gap: '2px',
24
+ cursor: 'grab',
25
+ });
26
+ return grid;
27
+ }
28
+ exports.generateGrid = generateGrid;
29
+ function generateChevron() {
30
+ const triangle = document.createElement('div');
31
+ Object.assign(triangle.style, {
32
+ width: '0',
33
+ height: '0',
34
+ borderLeft: '7px solid transparent',
35
+ borderRight: '7px solid transparent',
36
+ borderBottom: '7px solid white',
37
+ });
38
+ const container = document.createElement('div');
39
+ container.appendChild(triangle);
40
+ Object.assign(container.style, {
41
+ display: 'flex',
42
+ alignItems: 'center',
43
+ justifyContent: 'center',
44
+ width: '16px',
45
+ height: '16px',
46
+ cursor: 'pointer',
47
+ marginLeft: 'auto',
48
+ transform: 'rotate(180deg)',
49
+ });
50
+ return container;
51
+ }
52
+ exports.generateChevron = generateChevron;
53
+ function addKeyframes() {
54
+ const styleSheet = document.createElement('style');
55
+ styleSheet.type = 'text/css';
56
+ styleSheet.innerText = `@keyframes spin {
57
+ 0% { transform: rotate(0deg); }
58
+ 100% { transform: rotate(360deg); }
59
+ }`;
60
+ document.head.appendChild(styleSheet);
61
+ }
62
+ exports.addKeyframes = addKeyframes;
63
+ function createSpinner() {
64
+ addKeyframes();
65
+ const spinner = document.createElement('div');
66
+ spinner.classList.add('spinner');
67
+ Object.assign(spinner.style, styles_js_1.spinnerStyles);
68
+ return spinner;
69
+ }
70
+ exports.createSpinner = createSpinner;
71
+ function createElement(tag, className, styles, textContent, id) {
72
+ const element = document.createElement(tag);
73
+ element.className = className;
74
+ Object.assign(element.style, styles);
75
+ if (textContent) {
76
+ element.textContent = textContent;
77
+ }
78
+ if (id) {
79
+ element.id = id;
80
+ }
81
+ return element;
82
+ }
83
+ exports.createElement = createElement;
84
+ exports.TEST_START = 'or_uxt_test_start';
85
+ exports.TASK_IND = 'or_uxt_task_index';
86
+ exports.SESSION_ID = 'or_uxt_session_id';
87
+ exports.TEST_ID = 'or_uxt_test_id';