@openreplay/tracker 11.0.3 → 11.0.5
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/CHANGELOG.md +9 -0
- package/cjs/app/canvas.d.ts +3 -0
- package/cjs/app/canvas.js +23 -7
- package/cjs/app/index.d.ts +2 -0
- package/cjs/app/index.js +15 -6
- package/cjs/app/nodes.d.ts +1 -0
- package/cjs/app/nodes.js +3 -0
- package/cjs/index.d.ts +1 -0
- package/cjs/index.js +7 -1
- package/coverage/clover.xml +840 -739
- package/coverage/coverage-final.json +13 -12
- package/coverage/lcov-report/index.html +33 -33
- package/coverage/lcov-report/main/app/canvas.ts.html +23 -14
- package/coverage/lcov-report/main/app/guards.ts.html +1 -1
- package/coverage/lcov-report/main/app/index.html +16 -16
- package/coverage/lcov-report/main/app/index.ts.html +478 -82
- package/coverage/lcov-report/main/app/logger.ts.html +25 -91
- package/coverage/lcov-report/main/app/messages.gen.ts.html +62 -5
- package/coverage/lcov-report/main/app/nodes.ts.html +1 -1
- package/coverage/lcov-report/main/app/observer/iframe_observer.ts.html +2 -2
- package/coverage/lcov-report/main/app/observer/iframe_offsets.ts.html +1 -1
- package/coverage/lcov-report/main/app/observer/index.html +1 -1
- package/coverage/lcov-report/main/app/observer/shadow_root_observer.ts.html +2 -2
- package/coverage/lcov-report/main/app/observer/top_observer.ts.html +1 -1
- package/coverage/lcov-report/main/app/sanitizer.ts.html +1 -1
- package/coverage/lcov-report/main/app/session.ts.html +1 -1
- package/coverage/lcov-report/main/app/ticker.ts.html +1 -1
- package/coverage/lcov-report/main/index.html +9 -9
- package/coverage/lcov-report/main/index.ts.html +182 -11
- package/coverage/lcov-report/main/modules/Network/beaconProxy.ts.html +1 -1
- package/coverage/lcov-report/main/modules/Network/fetchProxy.ts.html +21 -6
- package/coverage/lcov-report/main/modules/Network/index.html +6 -6
- package/coverage/lcov-report/main/modules/Network/index.ts.html +1 -1
- package/coverage/lcov-report/main/modules/Network/networkMessage.ts.html +1 -1
- package/coverage/lcov-report/main/modules/Network/utils.ts.html +1 -1
- package/coverage/lcov-report/main/modules/Network/xhrProxy.ts.html +3 -3
- package/coverage/lcov-report/main/modules/attributeSender.ts.html +1 -1
- package/coverage/lcov-report/main/modules/axiosSpy.ts.html +1 -1
- package/coverage/lcov-report/main/modules/conditionsManager.ts.html +112 -67
- package/coverage/lcov-report/main/modules/connection.ts.html +1 -1
- package/coverage/lcov-report/main/modules/console.ts.html +1 -1
- package/coverage/lcov-report/main/modules/constructedStyleSheets.ts.html +1 -1
- package/coverage/lcov-report/main/modules/cssrules.ts.html +1 -1
- package/coverage/lcov-report/main/modules/exception.ts.html +1 -1
- package/coverage/lcov-report/main/modules/featureFlags.ts.html +1 -1
- package/coverage/lcov-report/main/modules/focus.ts.html +1 -1
- package/coverage/lcov-report/main/modules/fonts.ts.html +1 -1
- package/coverage/lcov-report/main/modules/img.ts.html +1 -1
- package/coverage/lcov-report/main/modules/index.html +34 -19
- package/coverage/lcov-report/main/modules/input.ts.html +1 -1
- package/coverage/lcov-report/main/modules/mouse.ts.html +1 -1
- package/coverage/lcov-report/main/modules/network.ts.html +1 -1
- package/coverage/lcov-report/main/modules/performance.ts.html +1 -1
- package/coverage/lcov-report/main/modules/scroll.ts.html +1 -1
- package/coverage/lcov-report/main/modules/selection.ts.html +1 -1
- package/coverage/lcov-report/main/modules/tabs.ts.html +1 -1
- package/coverage/lcov-report/main/modules/tagWatcher.ts.html +307 -0
- package/coverage/lcov-report/main/modules/timing.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/SignalManager.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/dnd.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/index.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/index.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/recorder.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/styles.ts.html +1 -1
- package/coverage/lcov-report/main/modules/userTesting/utils.ts.html +1 -1
- package/coverage/lcov-report/main/modules/viewport.ts.html +1 -1
- package/coverage/lcov-report/main/utils.ts.html +1 -1
- package/coverage/lcov-report/webworker/BatchWriter.ts.html +23 -5
- package/coverage/lcov-report/webworker/MessageEncoder.gen.ts.html +17 -5
- package/coverage/lcov-report/webworker/PrimitiveEncoder.ts.html +1 -1
- package/coverage/lcov-report/webworker/QueueSender.ts.html +18 -6
- package/coverage/lcov-report/webworker/index.html +19 -19
- package/coverage/lcov-report/webworker/index.ts.html +15 -12
- package/coverage/lcov.info +1576 -1355
- package/lib/app/canvas.d.ts +3 -0
- package/lib/app/canvas.js +23 -7
- package/lib/app/index.d.ts +2 -0
- package/lib/app/index.js +15 -6
- package/lib/app/nodes.d.ts +1 -0
- package/lib/app/nodes.js +3 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.js +7 -1
- package/package.json +1 -1
|
@@ -25,28 +25,28 @@
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
26
|
<span class="strong">0% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>0/
|
|
28
|
+
<span class='fraction'>0/486</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
<div class='fl pad1y space-right2'>
|
|
33
33
|
<span class="strong">0% </span>
|
|
34
34
|
<span class="quiet">Branches</span>
|
|
35
|
-
<span class='fraction'>0/
|
|
35
|
+
<span class='fraction'>0/257</span>
|
|
36
36
|
</div>
|
|
37
37
|
|
|
38
38
|
|
|
39
39
|
<div class='fl pad1y space-right2'>
|
|
40
40
|
<span class="strong">0% </span>
|
|
41
41
|
<span class="quiet">Functions</span>
|
|
42
|
-
<span class='fraction'>0/
|
|
42
|
+
<span class='fraction'>0/86</span>
|
|
43
43
|
</div>
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
47
|
<span class="strong">0% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>0/
|
|
49
|
+
<span class='fraction'>0/472</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -1172,10 +1172,150 @@
|
|
|
1172
1172
|
<a name='L1107'></a><a href='#L1107'>1107</a>
|
|
1173
1173
|
<a name='L1108'></a><a href='#L1108'>1108</a>
|
|
1174
1174
|
<a name='L1109'></a><a href='#L1109'>1109</a>
|
|
1175
|
-
<a name='L1110'></a><a href='#L1110'>1110</a
|
|
1175
|
+
<a name='L1110'></a><a href='#L1110'>1110</a>
|
|
1176
|
+
<a name='L1111'></a><a href='#L1111'>1111</a>
|
|
1177
|
+
<a name='L1112'></a><a href='#L1112'>1112</a>
|
|
1178
|
+
<a name='L1113'></a><a href='#L1113'>1113</a>
|
|
1179
|
+
<a name='L1114'></a><a href='#L1114'>1114</a>
|
|
1180
|
+
<a name='L1115'></a><a href='#L1115'>1115</a>
|
|
1181
|
+
<a name='L1116'></a><a href='#L1116'>1116</a>
|
|
1182
|
+
<a name='L1117'></a><a href='#L1117'>1117</a>
|
|
1183
|
+
<a name='L1118'></a><a href='#L1118'>1118</a>
|
|
1184
|
+
<a name='L1119'></a><a href='#L1119'>1119</a>
|
|
1185
|
+
<a name='L1120'></a><a href='#L1120'>1120</a>
|
|
1186
|
+
<a name='L1121'></a><a href='#L1121'>1121</a>
|
|
1187
|
+
<a name='L1122'></a><a href='#L1122'>1122</a>
|
|
1188
|
+
<a name='L1123'></a><a href='#L1123'>1123</a>
|
|
1189
|
+
<a name='L1124'></a><a href='#L1124'>1124</a>
|
|
1190
|
+
<a name='L1125'></a><a href='#L1125'>1125</a>
|
|
1191
|
+
<a name='L1126'></a><a href='#L1126'>1126</a>
|
|
1192
|
+
<a name='L1127'></a><a href='#L1127'>1127</a>
|
|
1193
|
+
<a name='L1128'></a><a href='#L1128'>1128</a>
|
|
1194
|
+
<a name='L1129'></a><a href='#L1129'>1129</a>
|
|
1195
|
+
<a name='L1130'></a><a href='#L1130'>1130</a>
|
|
1196
|
+
<a name='L1131'></a><a href='#L1131'>1131</a>
|
|
1197
|
+
<a name='L1132'></a><a href='#L1132'>1132</a>
|
|
1198
|
+
<a name='L1133'></a><a href='#L1133'>1133</a>
|
|
1199
|
+
<a name='L1134'></a><a href='#L1134'>1134</a>
|
|
1200
|
+
<a name='L1135'></a><a href='#L1135'>1135</a>
|
|
1201
|
+
<a name='L1136'></a><a href='#L1136'>1136</a>
|
|
1202
|
+
<a name='L1137'></a><a href='#L1137'>1137</a>
|
|
1203
|
+
<a name='L1138'></a><a href='#L1138'>1138</a>
|
|
1204
|
+
<a name='L1139'></a><a href='#L1139'>1139</a>
|
|
1205
|
+
<a name='L1140'></a><a href='#L1140'>1140</a>
|
|
1206
|
+
<a name='L1141'></a><a href='#L1141'>1141</a>
|
|
1207
|
+
<a name='L1142'></a><a href='#L1142'>1142</a>
|
|
1208
|
+
<a name='L1143'></a><a href='#L1143'>1143</a>
|
|
1209
|
+
<a name='L1144'></a><a href='#L1144'>1144</a>
|
|
1210
|
+
<a name='L1145'></a><a href='#L1145'>1145</a>
|
|
1211
|
+
<a name='L1146'></a><a href='#L1146'>1146</a>
|
|
1212
|
+
<a name='L1147'></a><a href='#L1147'>1147</a>
|
|
1213
|
+
<a name='L1148'></a><a href='#L1148'>1148</a>
|
|
1214
|
+
<a name='L1149'></a><a href='#L1149'>1149</a>
|
|
1215
|
+
<a name='L1150'></a><a href='#L1150'>1150</a>
|
|
1216
|
+
<a name='L1151'></a><a href='#L1151'>1151</a>
|
|
1217
|
+
<a name='L1152'></a><a href='#L1152'>1152</a>
|
|
1218
|
+
<a name='L1153'></a><a href='#L1153'>1153</a>
|
|
1219
|
+
<a name='L1154'></a><a href='#L1154'>1154</a>
|
|
1220
|
+
<a name='L1155'></a><a href='#L1155'>1155</a>
|
|
1221
|
+
<a name='L1156'></a><a href='#L1156'>1156</a>
|
|
1222
|
+
<a name='L1157'></a><a href='#L1157'>1157</a>
|
|
1223
|
+
<a name='L1158'></a><a href='#L1158'>1158</a>
|
|
1224
|
+
<a name='L1159'></a><a href='#L1159'>1159</a>
|
|
1225
|
+
<a name='L1160'></a><a href='#L1160'>1160</a>
|
|
1226
|
+
<a name='L1161'></a><a href='#L1161'>1161</a>
|
|
1227
|
+
<a name='L1162'></a><a href='#L1162'>1162</a>
|
|
1228
|
+
<a name='L1163'></a><a href='#L1163'>1163</a>
|
|
1229
|
+
<a name='L1164'></a><a href='#L1164'>1164</a>
|
|
1230
|
+
<a name='L1165'></a><a href='#L1165'>1165</a>
|
|
1231
|
+
<a name='L1166'></a><a href='#L1166'>1166</a>
|
|
1232
|
+
<a name='L1167'></a><a href='#L1167'>1167</a>
|
|
1233
|
+
<a name='L1168'></a><a href='#L1168'>1168</a>
|
|
1234
|
+
<a name='L1169'></a><a href='#L1169'>1169</a>
|
|
1235
|
+
<a name='L1170'></a><a href='#L1170'>1170</a>
|
|
1236
|
+
<a name='L1171'></a><a href='#L1171'>1171</a>
|
|
1237
|
+
<a name='L1172'></a><a href='#L1172'>1172</a>
|
|
1238
|
+
<a name='L1173'></a><a href='#L1173'>1173</a>
|
|
1239
|
+
<a name='L1174'></a><a href='#L1174'>1174</a>
|
|
1240
|
+
<a name='L1175'></a><a href='#L1175'>1175</a>
|
|
1241
|
+
<a name='L1176'></a><a href='#L1176'>1176</a>
|
|
1242
|
+
<a name='L1177'></a><a href='#L1177'>1177</a>
|
|
1243
|
+
<a name='L1178'></a><a href='#L1178'>1178</a>
|
|
1244
|
+
<a name='L1179'></a><a href='#L1179'>1179</a>
|
|
1245
|
+
<a name='L1180'></a><a href='#L1180'>1180</a>
|
|
1246
|
+
<a name='L1181'></a><a href='#L1181'>1181</a>
|
|
1247
|
+
<a name='L1182'></a><a href='#L1182'>1182</a>
|
|
1248
|
+
<a name='L1183'></a><a href='#L1183'>1183</a>
|
|
1249
|
+
<a name='L1184'></a><a href='#L1184'>1184</a>
|
|
1250
|
+
<a name='L1185'></a><a href='#L1185'>1185</a>
|
|
1251
|
+
<a name='L1186'></a><a href='#L1186'>1186</a>
|
|
1252
|
+
<a name='L1187'></a><a href='#L1187'>1187</a>
|
|
1253
|
+
<a name='L1188'></a><a href='#L1188'>1188</a>
|
|
1254
|
+
<a name='L1189'></a><a href='#L1189'>1189</a>
|
|
1255
|
+
<a name='L1190'></a><a href='#L1190'>1190</a>
|
|
1256
|
+
<a name='L1191'></a><a href='#L1191'>1191</a>
|
|
1257
|
+
<a name='L1192'></a><a href='#L1192'>1192</a>
|
|
1258
|
+
<a name='L1193'></a><a href='#L1193'>1193</a>
|
|
1259
|
+
<a name='L1194'></a><a href='#L1194'>1194</a>
|
|
1260
|
+
<a name='L1195'></a><a href='#L1195'>1195</a>
|
|
1261
|
+
<a name='L1196'></a><a href='#L1196'>1196</a>
|
|
1262
|
+
<a name='L1197'></a><a href='#L1197'>1197</a>
|
|
1263
|
+
<a name='L1198'></a><a href='#L1198'>1198</a>
|
|
1264
|
+
<a name='L1199'></a><a href='#L1199'>1199</a>
|
|
1265
|
+
<a name='L1200'></a><a href='#L1200'>1200</a>
|
|
1266
|
+
<a name='L1201'></a><a href='#L1201'>1201</a>
|
|
1267
|
+
<a name='L1202'></a><a href='#L1202'>1202</a>
|
|
1268
|
+
<a name='L1203'></a><a href='#L1203'>1203</a>
|
|
1269
|
+
<a name='L1204'></a><a href='#L1204'>1204</a>
|
|
1270
|
+
<a name='L1205'></a><a href='#L1205'>1205</a>
|
|
1271
|
+
<a name='L1206'></a><a href='#L1206'>1206</a>
|
|
1272
|
+
<a name='L1207'></a><a href='#L1207'>1207</a>
|
|
1273
|
+
<a name='L1208'></a><a href='#L1208'>1208</a>
|
|
1274
|
+
<a name='L1209'></a><a href='#L1209'>1209</a>
|
|
1275
|
+
<a name='L1210'></a><a href='#L1210'>1210</a>
|
|
1276
|
+
<a name='L1211'></a><a href='#L1211'>1211</a>
|
|
1277
|
+
<a name='L1212'></a><a href='#L1212'>1212</a>
|
|
1278
|
+
<a name='L1213'></a><a href='#L1213'>1213</a>
|
|
1279
|
+
<a name='L1214'></a><a href='#L1214'>1214</a>
|
|
1280
|
+
<a name='L1215'></a><a href='#L1215'>1215</a>
|
|
1281
|
+
<a name='L1216'></a><a href='#L1216'>1216</a>
|
|
1282
|
+
<a name='L1217'></a><a href='#L1217'>1217</a>
|
|
1283
|
+
<a name='L1218'></a><a href='#L1218'>1218</a>
|
|
1284
|
+
<a name='L1219'></a><a href='#L1219'>1219</a>
|
|
1285
|
+
<a name='L1220'></a><a href='#L1220'>1220</a>
|
|
1286
|
+
<a name='L1221'></a><a href='#L1221'>1221</a>
|
|
1287
|
+
<a name='L1222'></a><a href='#L1222'>1222</a>
|
|
1288
|
+
<a name='L1223'></a><a href='#L1223'>1223</a>
|
|
1289
|
+
<a name='L1224'></a><a href='#L1224'>1224</a>
|
|
1290
|
+
<a name='L1225'></a><a href='#L1225'>1225</a>
|
|
1291
|
+
<a name='L1226'></a><a href='#L1226'>1226</a>
|
|
1292
|
+
<a name='L1227'></a><a href='#L1227'>1227</a>
|
|
1293
|
+
<a name='L1228'></a><a href='#L1228'>1228</a>
|
|
1294
|
+
<a name='L1229'></a><a href='#L1229'>1229</a>
|
|
1295
|
+
<a name='L1230'></a><a href='#L1230'>1230</a>
|
|
1296
|
+
<a name='L1231'></a><a href='#L1231'>1231</a>
|
|
1297
|
+
<a name='L1232'></a><a href='#L1232'>1232</a>
|
|
1298
|
+
<a name='L1233'></a><a href='#L1233'>1233</a>
|
|
1299
|
+
<a name='L1234'></a><a href='#L1234'>1234</a>
|
|
1300
|
+
<a name='L1235'></a><a href='#L1235'>1235</a>
|
|
1301
|
+
<a name='L1236'></a><a href='#L1236'>1236</a>
|
|
1302
|
+
<a name='L1237'></a><a href='#L1237'>1237</a>
|
|
1303
|
+
<a name='L1238'></a><a href='#L1238'>1238</a>
|
|
1304
|
+
<a name='L1239'></a><a href='#L1239'>1239</a>
|
|
1305
|
+
<a name='L1240'></a><a href='#L1240'>1240</a>
|
|
1306
|
+
<a name='L1241'></a><a href='#L1241'>1241</a>
|
|
1307
|
+
<a name='L1242'></a><a href='#L1242'>1242</a></td><td class="line-coverage quiet"><span class="cline-any cline-no"> </span>
|
|
1176
1308
|
<span class="cline-any cline-no"> </span>
|
|
1177
1309
|
<span class="cline-any cline-neutral"> </span>
|
|
1178
1310
|
<span class="cline-any cline-no"> </span>
|
|
1311
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1312
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1313
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1314
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1315
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1316
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1317
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1318
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1179
1319
|
<span class="cline-any cline-no"> </span>
|
|
1180
1320
|
<span class="cline-any cline-neutral"> </span>
|
|
1181
1321
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1198,7 +1338,7 @@
|
|
|
1198
1338
|
<span class="cline-any cline-neutral"> </span>
|
|
1199
1339
|
<span class="cline-any cline-neutral"> </span>
|
|
1200
1340
|
<span class="cline-any cline-neutral"> </span>
|
|
1201
|
-
<span class="cline-any cline-
|
|
1341
|
+
<span class="cline-any cline-no"> </span>
|
|
1202
1342
|
<span class="cline-any cline-no"> </span>
|
|
1203
1343
|
<span class="cline-any cline-no"> </span>
|
|
1204
1344
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1297,8 +1437,6 @@
|
|
|
1297
1437
|
<span class="cline-any cline-neutral"> </span>
|
|
1298
1438
|
<span class="cline-any cline-neutral"> </span>
|
|
1299
1439
|
<span class="cline-any cline-neutral"> </span>
|
|
1300
|
-
<span class="cline-any cline-neutral"> </span>
|
|
1301
|
-
<span class="cline-any cline-neutral"> </span>
|
|
1302
1440
|
<span class="cline-any cline-no"> </span>
|
|
1303
1441
|
<span class="cline-any cline-neutral"> </span>
|
|
1304
1442
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1352,6 +1490,7 @@
|
|
|
1352
1490
|
<span class="cline-any cline-neutral"> </span>
|
|
1353
1491
|
<span class="cline-any cline-neutral"> </span>
|
|
1354
1492
|
<span class="cline-any cline-neutral"> </span>
|
|
1493
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1355
1494
|
<span class="cline-any cline-no"> </span>
|
|
1356
1495
|
<span class="cline-any cline-neutral"> </span>
|
|
1357
1496
|
<span class="cline-any cline-no"> </span>
|
|
@@ -1399,6 +1538,8 @@
|
|
|
1399
1538
|
<span class="cline-any cline-no"> </span>
|
|
1400
1539
|
<span class="cline-any cline-no"> </span>
|
|
1401
1540
|
<span class="cline-any cline-no"> </span>
|
|
1541
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1542
|
+
<span class="cline-any cline-no"> </span>
|
|
1402
1543
|
<span class="cline-any cline-no"> </span>
|
|
1403
1544
|
<span class="cline-any cline-neutral"> </span>
|
|
1404
1545
|
<span class="cline-any cline-no"> </span>
|
|
@@ -1440,14 +1581,17 @@
|
|
|
1440
1581
|
<span class="cline-any cline-no"> </span>
|
|
1441
1582
|
<span class="cline-any cline-no"> </span>
|
|
1442
1583
|
<span class="cline-any cline-no"> </span>
|
|
1443
|
-
<span class="cline-any cline-
|
|
1584
|
+
<span class="cline-any cline-no"> </span>
|
|
1444
1585
|
<span class="cline-any cline-neutral"> </span>
|
|
1445
1586
|
<span class="cline-any cline-neutral"> </span>
|
|
1446
1587
|
<span class="cline-any cline-no"> </span>
|
|
1447
1588
|
<span class="cline-any cline-neutral"> </span>
|
|
1448
1589
|
<span class="cline-any cline-neutral"> </span>
|
|
1590
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1449
1591
|
<span class="cline-any cline-no"> </span>
|
|
1450
1592
|
<span class="cline-any cline-neutral"> </span>
|
|
1593
|
+
<span class="cline-any cline-no"> </span>
|
|
1594
|
+
<span class="cline-any cline-no"> </span>
|
|
1451
1595
|
<span class="cline-any cline-neutral"> </span>
|
|
1452
1596
|
<span class="cline-any cline-neutral"> </span>
|
|
1453
1597
|
<span class="cline-any cline-no"> </span>
|
|
@@ -1881,6 +2025,7 @@
|
|
|
1881
2025
|
<span class="cline-any cline-neutral"> </span>
|
|
1882
2026
|
<span class="cline-any cline-neutral"> </span>
|
|
1883
2027
|
<span class="cline-any cline-no"> </span>
|
|
2028
|
+
<span class="cline-any cline-no"> </span>
|
|
1884
2029
|
<span class="cline-any cline-neutral"> </span>
|
|
1885
2030
|
<span class="cline-any cline-no"> </span>
|
|
1886
2031
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1893,6 +2038,15 @@
|
|
|
1893
2038
|
<span class="cline-any cline-no"> </span>
|
|
1894
2039
|
<span class="cline-any cline-neutral"> </span>
|
|
1895
2040
|
<span class="cline-any cline-neutral"> </span>
|
|
2041
|
+
<span class="cline-any cline-no"> </span>
|
|
2042
|
+
<span class="cline-any cline-no"> </span>
|
|
2043
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2044
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2045
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2046
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2047
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2048
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2049
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1896
2050
|
<span class="cline-any cline-neutral"> </span>
|
|
1897
2051
|
<span class="cline-any cline-no"> </span>
|
|
1898
2052
|
<span class="cline-any cline-no"> </span>
|
|
@@ -1921,12 +2075,20 @@
|
|
|
1921
2075
|
<span class="cline-any cline-neutral"> </span>
|
|
1922
2076
|
<span class="cline-any cline-neutral"> </span>
|
|
1923
2077
|
<span class="cline-any cline-no"> </span>
|
|
2078
|
+
<span class="cline-any cline-no"> </span>
|
|
2079
|
+
<span class="cline-any cline-no"> </span>
|
|
1924
2080
|
<span class="cline-any cline-neutral"> </span>
|
|
1925
2081
|
<span class="cline-any cline-no"> </span>
|
|
1926
2082
|
<span class="cline-any cline-neutral"> </span>
|
|
1927
2083
|
<span class="cline-any cline-no"> </span>
|
|
1928
2084
|
<span class="cline-any cline-no"> </span>
|
|
1929
2085
|
<span class="cline-any cline-neutral"> </span>
|
|
2086
|
+
<span class="cline-any cline-no"> </span>
|
|
2087
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2088
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2089
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2090
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2091
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1930
2092
|
<span class="cline-any cline-neutral"> </span>
|
|
1931
2093
|
<span class="cline-any cline-neutral"> </span>
|
|
1932
2094
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1945,10 +2107,88 @@
|
|
|
1945
2107
|
<span class="cline-any cline-neutral"> </span>
|
|
1946
2108
|
<span class="cline-any cline-no"> </span>
|
|
1947
2109
|
<span class="cline-any cline-neutral"> </span>
|
|
2110
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2111
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2112
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2113
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2114
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1948
2115
|
<span class="cline-any cline-no"> </span>
|
|
1949
2116
|
<span class="cline-any cline-neutral"> </span>
|
|
1950
2117
|
<span class="cline-any cline-neutral"> </span>
|
|
1951
2118
|
<span class="cline-any cline-neutral"> </span>
|
|
2119
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2120
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2121
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2122
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2123
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2124
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2125
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2126
|
+
<span class="cline-any cline-no"> </span>
|
|
2127
|
+
<span class="cline-any cline-no"> </span>
|
|
2128
|
+
<span class="cline-any cline-no"> </span>
|
|
2129
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2130
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2131
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2132
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2133
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2134
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2135
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2136
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2137
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2138
|
+
<span class="cline-any cline-no"> </span>
|
|
2139
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2140
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2141
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2142
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2143
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2144
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2145
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2146
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2147
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2148
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2149
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2150
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2151
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2152
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2153
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2154
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2155
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2156
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2157
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2158
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2159
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2160
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2161
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2162
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2163
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2164
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2165
|
+
<span class="cline-any cline-no"> </span>
|
|
2166
|
+
<span class="cline-any cline-no"> </span>
|
|
2167
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2168
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2169
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2170
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2171
|
+
<span class="cline-any cline-no"> </span>
|
|
2172
|
+
<span class="cline-any cline-no"> </span>
|
|
2173
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2174
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2175
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2176
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2177
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2178
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2179
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2180
|
+
<span class="cline-any cline-no"> </span>
|
|
2181
|
+
<span class="cline-any cline-no"> </span>
|
|
2182
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2183
|
+
<span class="cline-any cline-no"> </span>
|
|
2184
|
+
<span class="cline-any cline-no"> </span>
|
|
2185
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2186
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2187
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2188
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2189
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2190
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2191
|
+
<span class="cline-any cline-neutral"> </span>
|
|
1952
2192
|
<span class="cline-any cline-no"> </span>
|
|
1953
2193
|
<span class="cline-any cline-no"> </span>
|
|
1954
2194
|
<span class="cline-any cline-no"> </span>
|
|
@@ -2039,7 +2279,7 @@
|
|
|
2039
2279
|
<span class="cline-any cline-neutral"> </span>
|
|
2040
2280
|
<span class="cline-any cline-neutral"> </span>
|
|
2041
2281
|
<span class="cline-any cline-neutral"> </span>
|
|
2042
|
-
<span class="cline-any cline-
|
|
2282
|
+
<span class="cline-any cline-no"> </span>
|
|
2043
2283
|
<span class="cline-any cline-no"> </span>
|
|
2044
2284
|
<span class="cline-any cline-no"> </span>
|
|
2045
2285
|
<span class="cline-any cline-no"> </span>
|
|
@@ -2096,16 +2336,6 @@
|
|
|
2096
2336
|
<span class="cline-any cline-neutral"> </span>
|
|
2097
2337
|
<span class="cline-any cline-neutral"> </span>
|
|
2098
2338
|
<span class="cline-any cline-neutral"> </span>
|
|
2099
|
-
<span class="cline-any cline-no"> </span>
|
|
2100
|
-
<span class="cline-any cline-no"> </span>
|
|
2101
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2102
|
-
<span class="cline-any cline-no"> </span>
|
|
2103
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2104
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2105
|
-
<span class="cline-any cline-no"> </span>
|
|
2106
|
-
<span class="cline-any cline-no"> </span>
|
|
2107
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2108
|
-
<span class="cline-any cline-no"> </span>
|
|
2109
2339
|
<span class="cline-any cline-neutral"> </span>
|
|
2110
2340
|
<span class="cline-any cline-no"> </span>
|
|
2111
2341
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -2117,23 +2347,21 @@
|
|
|
2117
2347
|
<span class="cline-any cline-no"> </span>
|
|
2118
2348
|
<span class="cline-any cline-neutral"> </span>
|
|
2119
2349
|
<span class="cline-any cline-no"> </span>
|
|
2120
|
-
<span class="cline-any cline-
|
|
2121
|
-
<span class="cline-any cline-
|
|
2122
|
-
<span class="cline-any cline-no"> </span>
|
|
2123
|
-
<span class="cline-any cline-no"> </span>
|
|
2350
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2351
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2124
2352
|
<span class="cline-any cline-no"> </span>
|
|
2125
2353
|
<span class="cline-any cline-no"> </span>
|
|
2126
2354
|
<span class="cline-any cline-neutral"> </span>
|
|
2127
2355
|
<span class="cline-any cline-no"> </span>
|
|
2128
2356
|
<span class="cline-any cline-neutral"> </span>
|
|
2129
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2130
2357
|
<span class="cline-any cline-no"> </span>
|
|
2131
|
-
<span class="cline-any cline-
|
|
2358
|
+
<span class="cline-any cline-no"> </span>
|
|
2132
2359
|
<span class="cline-any cline-neutral"> </span>
|
|
2133
2360
|
<span class="cline-any cline-no"> </span>
|
|
2134
2361
|
<span class="cline-any cline-no"> </span>
|
|
2135
|
-
<span class="cline-any cline-neutral"> </span>
|
|
2136
2362
|
<span class="cline-any cline-no"> </span>
|
|
2363
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2364
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2137
2365
|
<span class="cline-any cline-no"> </span>
|
|
2138
2366
|
<span class="cline-any cline-neutral"> </span>
|
|
2139
2367
|
<span class="cline-any cline-no"> </span>
|
|
@@ -2157,7 +2385,6 @@
|
|
|
2157
2385
|
<span class="cline-any cline-no"> </span>
|
|
2158
2386
|
<span class="cline-any cline-neutral"> </span>
|
|
2159
2387
|
<span class="cline-any cline-neutral"> </span>
|
|
2160
|
-
<span class="cline-any cline-no"> </span>
|
|
2161
2388
|
<span class="cline-any cline-neutral"> </span>
|
|
2162
2389
|
<span class="cline-any cline-no"> </span>
|
|
2163
2390
|
<span class="cline-any cline-no"> </span>
|
|
@@ -2207,6 +2434,22 @@
|
|
|
2207
2434
|
<span class="cline-any cline-no"> </span>
|
|
2208
2435
|
<span class="cline-any cline-no"> </span>
|
|
2209
2436
|
<span class="cline-any cline-no"> </span>
|
|
2437
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2438
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2439
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2440
|
+
<span class="cline-any cline-no"> </span>
|
|
2441
|
+
<span class="cline-any cline-no"> </span>
|
|
2442
|
+
<span class="cline-any cline-no"> </span>
|
|
2443
|
+
<span class="cline-any cline-no"> </span>
|
|
2444
|
+
<span class="cline-any cline-no"> </span>
|
|
2445
|
+
<span class="cline-any cline-no"> </span>
|
|
2446
|
+
<span class="cline-any cline-no"> </span>
|
|
2447
|
+
<span class="cline-any cline-no"> </span>
|
|
2448
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2449
|
+
<span class="cline-any cline-no"> </span>
|
|
2450
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2451
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2452
|
+
<span class="cline-any cline-no"> </span>
|
|
2210
2453
|
<span class="cline-any cline-no"> </span>
|
|
2211
2454
|
<span class="cline-any cline-neutral"> </span>
|
|
2212
2455
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -2262,6 +2505,27 @@
|
|
|
2262
2505
|
<span class="cline-any cline-neutral"> </span>
|
|
2263
2506
|
<span class="cline-any cline-neutral"> </span>
|
|
2264
2507
|
<span class="cline-any cline-neutral"> </span>
|
|
2508
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2509
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2510
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2511
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2512
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2513
|
+
<span class="cline-any cline-no"> </span>
|
|
2514
|
+
<span class="cline-any cline-no"> </span>
|
|
2515
|
+
<span class="cline-any cline-no"> </span>
|
|
2516
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2517
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2518
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2519
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2520
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2521
|
+
<span class="cline-any cline-no"> </span>
|
|
2522
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2523
|
+
<span class="cline-any cline-no"> </span>
|
|
2524
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2525
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2526
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2527
|
+
<span class="cline-any cline-neutral"> </span>
|
|
2528
|
+
<span class="cline-any cline-no"> </span>
|
|
2265
2529
|
<span class="cline-any cline-no"> </span>
|
|
2266
2530
|
<span class="cline-any cline-no"> </span>
|
|
2267
2531
|
<span class="cline-any cline-no"> </span>
|
|
@@ -2284,7 +2548,15 @@
|
|
|
2284
2548
|
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js"><span class="cstat-no" title="statement not covered" >import ConditionsManager from '../modules/conditionsManager.js'</span>
|
|
2285
2549
|
<span class="cstat-no" title="statement not covered" >import FeatureFlags from '../modules/featureFlags.js'</span>
|
|
2286
2550
|
import type Message from './messages.gen.js'
|
|
2287
|
-
<span class="cstat-no" title="statement not covered" >import {
|
|
2551
|
+
<span class="cstat-no" title="statement not covered" >import {</span>
|
|
2552
|
+
Timestamp,
|
|
2553
|
+
Metadata,
|
|
2554
|
+
UserID,
|
|
2555
|
+
Type as MType,
|
|
2556
|
+
TabChange,
|
|
2557
|
+
TabData,
|
|
2558
|
+
WSChannel,
|
|
2559
|
+
} from './messages.gen.js'
|
|
2288
2560
|
<span class="cstat-no" title="statement not covered" >import {</span>
|
|
2289
2561
|
now,
|
|
2290
2562
|
adjustTimeOrigin,
|
|
@@ -2298,18 +2570,18 @@ import type Message from './messages.gen.js'
|
|
|
2298
2570
|
<span class="cstat-no" title="statement not covered" >import Observer from './observer/top_observer.js'</span>
|
|
2299
2571
|
<span class="cstat-no" title="statement not covered" >import Sanitizer from './sanitizer.js'</span>
|
|
2300
2572
|
<span class="cstat-no" title="statement not covered" >import Ticker from './ticker.js'</span>
|
|
2301
|
-
<span class="cstat-no" title="statement not covered" >import Logger, { LogLevel } from './logger.js'</span>
|
|
2573
|
+
<span class="cstat-no" title="statement not covered" >import Logger, { LogLevel, ILogLevel } from './logger.js'</span>
|
|
2302
2574
|
<span class="cstat-no" title="statement not covered" >import Session from './session.js'</span>
|
|
2303
2575
|
<span class="cstat-no" title="statement not covered" >import { gzip } from 'fflate'</span>
|
|
2304
2576
|
<span class="cstat-no" title="statement not covered" >import { deviceMemory, jsHeapSizeLimit } from '../modules/performance.js'</span>
|
|
2305
2577
|
<span class="cstat-no" title="statement not covered" >import AttributeSender from '../modules/attributeSender.js'</span>
|
|
2306
2578
|
import type { Options as ObserverOptions } from './observer/top_observer.js'
|
|
2307
2579
|
import type { Options as SanitizerOptions } from './sanitizer.js'
|
|
2308
|
-
import type { Options as LoggerOptions } from './logger.js'
|
|
2309
2580
|
import type { Options as SessOptions } from './session.js'
|
|
2310
2581
|
import type { Options as NetworkOptions } from '../modules/network.js'
|
|
2311
2582
|
<span class="cstat-no" title="statement not covered" >import CanvasRecorder from './canvas.js'</span>
|
|
2312
2583
|
<span class="cstat-no" title="statement not covered" >import UserTestManager from '../modules/userTesting/index.js'</span>
|
|
2584
|
+
<span class="cstat-no" title="statement not covered" >import TagWatcher from '../modules/tagWatcher.js'</span>
|
|
2313
2585
|
|
|
2314
2586
|
import type {
|
|
2315
2587
|
Options as WebworkerOptions,
|
|
@@ -2388,18 +2660,16 @@ type AppOptions = {
|
|
|
2388
2660
|
local_uuid_key: string
|
|
2389
2661
|
ingestPoint: string
|
|
2390
2662
|
resourceBaseHref: string | null // resourceHref?
|
|
2391
|
-
//resourceURLRewriter: (url: string) => string | boolean,
|
|
2392
|
-
verbose: boolean
|
|
2393
2663
|
__is_snippet: boolean
|
|
2394
2664
|
__debug_report_edp: string | null
|
|
2395
|
-
__debug__?:
|
|
2665
|
+
__debug__?: ILogLevel
|
|
2396
2666
|
localStorage: Storage | null
|
|
2397
2667
|
sessionStorage: Storage | null
|
|
2398
2668
|
forceSingleTab?: boolean
|
|
2399
2669
|
disableStringDict?: boolean
|
|
2400
2670
|
assistSocketHost?: string
|
|
2401
2671
|
|
|
2402
|
-
|
|
2672
|
+
/** @deprecated */
|
|
2403
2673
|
onStart?: StartCallback
|
|
2404
2674
|
network?: NetworkOptions
|
|
2405
2675
|
} & WebworkerOptions &
|
|
@@ -2430,7 +2700,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2430
2700
|
readonly sessionStorage: Storage
|
|
2431
2701
|
private readonly <span class="cstat-no" title="statement not covered" >messages: Array<Message> = []</span>
|
|
2432
2702
|
/**
|
|
2433
|
-
* we need 2 buffers so we don't lose anything
|
|
2703
|
+
* we need 2 buffers, so we don't lose anything
|
|
2434
2704
|
* @read coldStart implementation
|
|
2435
2705
|
* */
|
|
2436
2706
|
private <span class="cstat-no" title="statement not covered" >bufferedMessages1: Array<Message> = []</span>
|
|
@@ -2456,6 +2726,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2456
2726
|
private uxtManager: UserTestManager
|
|
2457
2727
|
private <span class="cstat-no" title="statement not covered" >conditionsManager: ConditionsManager | null = null</span>
|
|
2458
2728
|
public featureFlags: FeatureFlags
|
|
2729
|
+
private tagWatcher: TagWatcher
|
|
2459
2730
|
|
|
2460
2731
|
<span class="fstat-no" title="function not covered" > constructor(</span>
|
|
2461
2732
|
projectKey: string,
|
|
@@ -2477,9 +2748,9 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2477
2748
|
local_uuid_key: '__openreplay_uuid',
|
|
2478
2749
|
ingestPoint: DEFAULT_INGEST_POINT,
|
|
2479
2750
|
resourceBaseHref: null,
|
|
2480
|
-
verbose: false,
|
|
2481
2751
|
__is_snippet: false,
|
|
2482
2752
|
__debug_report_edp: null,
|
|
2753
|
+
__debug__: LogLevel.Silent,
|
|
2483
2754
|
localStorage: null,
|
|
2484
2755
|
sessionStorage: null,
|
|
2485
2756
|
disableStringDict: false,
|
|
@@ -2503,10 +2774,12 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2503
2774
|
<span class="cstat-no" title="statement not covered" > this.ticker = new Ticker(this)</span>
|
|
2504
2775
|
<span class="cstat-no" title="statement not covered" > this.ticker.attach(<span class="fstat-no" title="function not covered" >() =</span>> <span class="cstat-no" title="statement not covered" >this.commit())</span></span>
|
|
2505
2776
|
<span class="cstat-no" title="statement not covered" > this.debug = new Logger(this.options.__debug__)</span>
|
|
2506
|
-
<span class="cstat-no" title="statement not covered" > this.notify = new Logger(this.options.verbose ? LogLevel.Warnings : LogLevel.Silent)</span>
|
|
2507
2777
|
<span class="cstat-no" title="statement not covered" > this.session = new Session(this, this.options)</span>
|
|
2508
2778
|
<span class="cstat-no" title="statement not covered" > this.attributeSender = new AttributeSender(this, Boolean(this.options.disableStringDict))</span>
|
|
2509
2779
|
<span class="cstat-no" title="statement not covered" > this.featureFlags = new FeatureFlags(this)</span>
|
|
2780
|
+
<span class="cstat-no" title="statement not covered" > this.tagWatcher = new TagWatcher(this.sessionStorage, this.debug.error, <span class="fstat-no" title="function not covered" >(t</span>ag) =></span>
|
|
2781
|
+
<span class="cstat-no" title="statement not covered" > console.log(`Tag ${tag} has been rendered`),</span>
|
|
2782
|
+
)
|
|
2510
2783
|
<span class="cstat-no" title="statement not covered" > this.session.attachUpdateCallback(<span class="fstat-no" title="function not covered" >({</span> userID, metadata }) => {</span>
|
|
2511
2784
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (userID != null) {</span>
|
|
2512
2785
|
// TODO: nullable userID
|
|
@@ -2534,29 +2807,32 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2534
2807
|
<span class="cstat-no" title="statement not covered" > this.stop(false)</span>
|
|
2535
2808
|
<span class="cstat-no" title="statement not covered" > void this.start({}, true)</span>
|
|
2536
2809
|
} else <span class="cstat-no" title="statement not covered" >if (data === 'not_init') {</span>
|
|
2537
|
-
<span class="cstat-no" title="statement not covered" >
|
|
2810
|
+
<span class="cstat-no" title="statement not covered" > this.debug.warn('OR WebWorker: writer not initialised. Restarting tracker')</span>
|
|
2538
2811
|
} else <span class="cstat-no" title="statement not covered" >if (data.type === 'failure') {</span>
|
|
2539
2812
|
<span class="cstat-no" title="statement not covered" > this.stop(false)</span>
|
|
2813
|
+
<span class="cstat-no" title="statement not covered" > this.debug.error('worker_failed', data.reason)</span>
|
|
2540
2814
|
<span class="cstat-no" title="statement not covered" > this._debug('worker_failed', data.reason)</span>
|
|
2541
|
-
} else <span class="cstat-no" title="statement not covered"
|
|
2815
|
+
} else <span class="cstat-no" title="statement not covered" >if (data.type === 'compress') {</span>
|
|
2542
2816
|
const batch = <span class="cstat-no" title="statement not covered" >data.batch</span>
|
|
2543
2817
|
const batchSize = <span class="cstat-no" title="statement not covered" >batch.byteLength</span>
|
|
2544
2818
|
<span class="cstat-no" title="statement not covered" > if (batchSize > this.compressionThreshold) {</span>
|
|
2545
2819
|
<span class="cstat-no" title="statement not covered" > gzip(data.batch, { mtime: 0 }, <span class="fstat-no" title="function not covered" >(e</span>rr, result) => {</span>
|
|
2546
|
-
<span class="cstat-no" title="statement not covered" >
|
|
2547
|
-
<span class="cstat-no" title="statement not covered" >
|
|
2820
|
+
<span class="cstat-no" title="statement not covered" > if (err) {</span>
|
|
2821
|
+
<span class="cstat-no" title="statement not covered" > this.debug.error('Openreplay compression error:', err)</span>
|
|
2548
2822
|
<span class="cstat-no" title="statement not covered" > this.stop(false)</span>
|
|
2549
2823
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (this.restartAttempts < 3) {</span>
|
|
2550
2824
|
<span class="cstat-no" title="statement not covered" > this.restartAttempts += 1</span>
|
|
2551
2825
|
<span class="cstat-no" title="statement not covered" > void this.start({}, true)</span>
|
|
2552
2826
|
}
|
|
2827
|
+
} else {
|
|
2828
|
+
<span class="cstat-no" title="statement not covered" > this.worker?.postMessage({ type: 'compressed', batch: result })</span>
|
|
2553
2829
|
}
|
|
2554
|
-
// @ts-ignore
|
|
2555
|
-
<span class="cstat-no" title="statement not covered" > this.worker?.postMessage({ type: 'compressed', batch: result })</span>
|
|
2556
2830
|
})
|
|
2557
2831
|
} else {
|
|
2558
2832
|
<span class="cstat-no" title="statement not covered" > this.worker?.postMessage({ type: 'uncompressed', batch: batch })</span>
|
|
2559
2833
|
}
|
|
2834
|
+
} else <span class="cstat-no" title="statement not covered" ><span class="missing-if-branch" title="if path not taken" >I</span>if (data.type === 'queue_empty') {</span>
|
|
2835
|
+
<span class="cstat-no" title="statement not covered" > this.onSessionSent()</span>
|
|
2560
2836
|
}
|
|
2561
2837
|
}
|
|
2562
2838
|
const alertWorker = <span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >() =</span>> {</span>
|
|
@@ -2666,7 +2942,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2666
2942
|
// Clarify where urgent can be used for;
|
|
2667
2943
|
// Clarify workflow for each type of message in case it was sent before start
|
|
2668
2944
|
// (like Fetch before start; maybe add an option "preCapture: boolean" or sth alike)
|
|
2669
|
-
// Careful: `this.delay` is equal to zero before start
|
|
2945
|
+
// Careful: `this.delay` is equal to zero before start so all Timestamp-s will have to be updated on start
|
|
2670
2946
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (this.activityState === ActivityState.Active && urgent) {</span>
|
|
2671
2947
|
<span class="cstat-no" title="statement not covered" > this.commit()</span>
|
|
2672
2948
|
}
|
|
@@ -2990,6 +3266,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
2990
3266
|
metadata: startOpts.metadata,
|
|
2991
3267
|
})
|
|
2992
3268
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (!isNewSession) {</span>
|
|
3269
|
+
<span class="cstat-no" title="statement not covered" > this.debug.log('continuing session on new tab', this.session.getTabId())</span>
|
|
2993
3270
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
|
2994
3271
|
<span class="cstat-no" title="statement not covered" > this.send(TabChange(this.session.getTabId()))</span>
|
|
2995
3272
|
}
|
|
@@ -3002,16 +3279,25 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3002
3279
|
<span class="cstat-no" title="statement not covered" > cycle()</span>
|
|
3003
3280
|
}
|
|
3004
3281
|
|
|
3005
|
-
|
|
3282
|
+
<span class="cstat-no" title="statement not covered" > onSessionSent = <span class="fstat-no" title="function not covered" >() =</span>> {</span>
|
|
3283
|
+
<span class="cstat-no" title="statement not covered" > return</span>
|
|
3284
|
+
}
|
|
3285
|
+
|
|
3286
|
+
/**
|
|
3287
|
+
* Starts offline session recording
|
|
3288
|
+
* @param {Object} startOpts - options for session start, same as .start()
|
|
3289
|
+
* @param {Function} onSessionSent - callback that will be called once session is fully sent
|
|
3290
|
+
* */
|
|
3291
|
+
public <span class="fstat-no" title="function not covered" >offlineRecording(</span>startOpts: StartOptions = <span class="branch-0 cbranch-no" title="branch not covered" >{},</span> onSessionSent: () => void) {
|
|
3292
|
+
<span class="cstat-no" title="statement not covered" > this.onSessionSent = onSessionSent</span>
|
|
3006
3293
|
<span class="cstat-no" title="statement not covered" > this.singleBuffer = true</span>
|
|
3007
3294
|
const isNewSession = <span class="cstat-no" title="statement not covered" >this.checkSessionToken(startOpts.forceNew)</span>
|
|
3008
3295
|
<span class="cstat-no" title="statement not covered" > adjustTimeOrigin()</span>
|
|
3009
3296
|
<span class="cstat-no" title="statement not covered" > this.coldStartTs = now()</span>
|
|
3010
|
-
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1.length = 0</span>
|
|
3011
3297
|
const saverBuffer = <span class="cstat-no" title="statement not covered" >this.localStorage.getItem(bufferStorageKey)</span>
|
|
3012
3298
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (saverBuffer) {</span>
|
|
3013
3299
|
const data = <span class="cstat-no" title="statement not covered" >JSON.parse(saverBuffer)</span>
|
|
3014
|
-
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1 = Array.isArray(data) ? data :
|
|
3300
|
+
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1 = Array.isArray(data) ? data : this.bufferedMessages1</span>
|
|
3015
3301
|
<span class="cstat-no" title="statement not covered" > this.localStorage.removeItem(bufferStorageKey)</span>
|
|
3016
3302
|
}
|
|
3017
3303
|
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1.push(Timestamp(this.timestamp()))</span>
|
|
@@ -3029,12 +3315,20 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3029
3315
|
userID: startOpts.userID,
|
|
3030
3316
|
metadata: startOpts.metadata,
|
|
3031
3317
|
})
|
|
3318
|
+
const onStartInfo = <span class="cstat-no" title="statement not covered" >{ sessionToken: '', userUUID: '', sessionID: '' }</span>
|
|
3319
|
+
<span class="cstat-no" title="statement not covered" > this.startCallbacks.forEach(<span class="fstat-no" title="function not covered" >(c</span>b) => <span class="cstat-no" title="statement not covered" >cb(onStartInfo))</span></span>
|
|
3032
3320
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (!isNewSession) {</span>
|
|
3033
3321
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
|
3034
3322
|
<span class="cstat-no" title="statement not covered" > this.send(TabChange(this.session.getTabId()))</span>
|
|
3035
3323
|
}
|
|
3036
3324
|
<span class="cstat-no" title="statement not covered" > this.observer.observe()</span>
|
|
3037
3325
|
<span class="cstat-no" title="statement not covered" > this.ticker.start()</span>
|
|
3326
|
+
|
|
3327
|
+
<span class="cstat-no" title="statement not covered" > return {</span>
|
|
3328
|
+
saveBuffer: this.saveBuffer,
|
|
3329
|
+
getBuffer: this.getBuffer,
|
|
3330
|
+
setBuffer: this.setBuffer,
|
|
3331
|
+
}
|
|
3038
3332
|
}
|
|
3039
3333
|
|
|
3040
3334
|
/**
|
|
@@ -3049,15 +3343,93 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3049
3343
|
}
|
|
3050
3344
|
|
|
3051
3345
|
/**
|
|
3052
|
-
*
|
|
3346
|
+
* @returns buffer with stored messages for offline recording
|
|
3053
3347
|
* */
|
|
3054
|
-
public <span class="fstat-no" title="function not covered" >
|
|
3348
|
+
public <span class="fstat-no" title="function not covered" >getBuffer(</span>) {
|
|
3349
|
+
<span class="cstat-no" title="statement not covered" > return this.bufferedMessages1</span>
|
|
3350
|
+
}
|
|
3351
|
+
|
|
3352
|
+
/**
|
|
3353
|
+
* Used to set a buffer with messages array
|
|
3354
|
+
* */
|
|
3355
|
+
public <span class="fstat-no" title="function not covered" >setBuffer(</span>buffer: Message[]) {
|
|
3356
|
+
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1 = buffer</span>
|
|
3357
|
+
}
|
|
3358
|
+
|
|
3359
|
+
/**
|
|
3360
|
+
* Uploads the stored session buffer to backend
|
|
3361
|
+
* @returns promise that resolves once messages are loaded, it has to be awaited
|
|
3362
|
+
* so the session can be uploaded properly
|
|
3363
|
+
* @resolve {boolean} - if messages were loaded successfully
|
|
3364
|
+
* @reject {string} - error message
|
|
3365
|
+
* */
|
|
3366
|
+
public async <span class="fstat-no" title="function not covered" >uploadOfflineRecording(</span>) {
|
|
3055
3367
|
<span class="cstat-no" title="statement not covered" > this.stop(false)</span>
|
|
3056
|
-
|
|
3368
|
+
const timestamp = <span class="cstat-no" title="statement not covered" >now()</span>
|
|
3369
|
+
<span class="cstat-no" title="statement not covered" > this.worker?.postMessage({</span>
|
|
3370
|
+
type: 'start',
|
|
3371
|
+
pageNo: this.session.incPageNo(),
|
|
3372
|
+
ingestPoint: this.options.ingestPoint,
|
|
3373
|
+
timestamp: this.coldStartTs,
|
|
3374
|
+
url: document.URL,
|
|
3375
|
+
connAttemptCount: this.options.connAttemptCount,
|
|
3376
|
+
connAttemptGap: this.options.connAttemptGap,
|
|
3377
|
+
tabId: this.session.getTabId(),
|
|
3378
|
+
})
|
|
3379
|
+
const r = <span class="cstat-no" title="statement not covered" >await fetch(this.options.ingestPoint + '/v1/web/start', {</span>
|
|
3380
|
+
method: 'POST',
|
|
3381
|
+
headers: {
|
|
3382
|
+
'Content-Type': 'application/json',
|
|
3383
|
+
},
|
|
3384
|
+
body: JSON.stringify({
|
|
3385
|
+
...this.getTrackerInfo(),
|
|
3386
|
+
timestamp: timestamp,
|
|
3387
|
+
doNotRecord: false,
|
|
3388
|
+
bufferDiff: timestamp - this.coldStartTs,
|
|
3389
|
+
userID: this.session.getInfo().userID,
|
|
3390
|
+
token: undefined,
|
|
3391
|
+
deviceMemory,
|
|
3392
|
+
jsHeapSizeLimit,
|
|
3393
|
+
timezone: getTimezone(),
|
|
3394
|
+
}),
|
|
3395
|
+
})
|
|
3396
|
+
const {
|
|
3397
|
+
token,
|
|
3398
|
+
userBrowser,
|
|
3399
|
+
userCity,
|
|
3400
|
+
userCountry,
|
|
3401
|
+
userDevice,
|
|
3402
|
+
userOS,
|
|
3403
|
+
userState,
|
|
3404
|
+
beaconSizeLimit,
|
|
3405
|
+
projectID,
|
|
3406
|
+
} = <span class="cstat-no" title="statement not covered" >await r.json()</span>
|
|
3407
|
+
<span class="cstat-no" title="statement not covered" > this.worker?.postMessage({</span>
|
|
3408
|
+
type: 'auth',
|
|
3409
|
+
token,
|
|
3410
|
+
beaconSizeLimit,
|
|
3411
|
+
})
|
|
3412
|
+
<span class="cstat-no" title="statement not covered" > this.session.assign({ projectID })</span>
|
|
3413
|
+
<span class="cstat-no" title="statement not covered" > this.session.setUserInfo({</span>
|
|
3414
|
+
userBrowser,
|
|
3415
|
+
userCity,
|
|
3416
|
+
userCountry,
|
|
3417
|
+
userDevice,
|
|
3418
|
+
userOS,
|
|
3419
|
+
userState,
|
|
3420
|
+
})
|
|
3421
|
+
<span class="cstat-no" title="statement not covered" > while (this.bufferedMessages1.length > 0) {</span>
|
|
3422
|
+
<span class="cstat-no" title="statement not covered" > await this.flushBuffer(this.bufferedMessages1)</span>
|
|
3423
|
+
}
|
|
3424
|
+
<span class="cstat-no" title="statement not covered" > this.postToWorker([['q_end']] as unknown as Message[])</span>
|
|
3057
3425
|
<span class="cstat-no" title="statement not covered" > this.clearBuffers()</span>
|
|
3058
3426
|
}
|
|
3059
3427
|
|
|
3060
|
-
private <span class="fstat-no" title="function not covered" >_start(</span>
|
|
3428
|
+
private <span class="fstat-no" title="function not covered" >_start(</span>
|
|
3429
|
+
startOpts: StartOptions = <span class="branch-0 cbranch-no" title="branch not covered" >{},</span>
|
|
3430
|
+
resetByWorker = <span class="branch-0 cbranch-no" title="branch not covered" >false,</span>
|
|
3431
|
+
conditionName?: string,
|
|
3432
|
+
): Promise<StartPromiseReturn> {
|
|
3061
3433
|
const isColdStart = <span class="cstat-no" title="statement not covered" >this.activityState === ActivityState.ColdStart</span>
|
|
3062
3434
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (isColdStart && this.coldInterval) {</span>
|
|
3063
3435
|
<span class="cstat-no" title="statement not covered" > clearInterval(this.coldInterval)</span>
|
|
@@ -3099,7 +3471,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3099
3471
|
type: 'start',
|
|
3100
3472
|
pageNo: this.session.incPageNo(),
|
|
3101
3473
|
ingestPoint: this.options.ingestPoint,
|
|
3102
|
-
timestamp,
|
|
3474
|
+
timestamp: isColdStart ? this.coldStartTs : timestamp,
|
|
3103
3475
|
url: document.URL,
|
|
3104
3476
|
connAttemptCount: this.options.connAttemptCount,
|
|
3105
3477
|
connAttemptGap: this.options.connAttemptGap,
|
|
@@ -3148,7 +3520,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3148
3520
|
)
|
|
3149
3521
|
}
|
|
3150
3522
|
})
|
|
3151
|
-
.then(<span class="fstat-no" title="function not covered" >(r</span>) =>
|
|
3523
|
+
.then(<span class="fstat-no" title="function not covered" >async (r</span>) =><span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" > {</span></span>
|
|
3152
3524
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (!this.worker) {</span>
|
|
3153
3525
|
const reason = <span class="cstat-no" title="statement not covered" >'no worker found after start request (this might not happen)'</span>
|
|
3154
3526
|
<span class="cstat-no" title="statement not covered" > this.signalError(reason, [])</span>
|
|
@@ -3205,6 +3577,13 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3205
3577
|
timestamp: startTimestamp || timestamp,
|
|
3206
3578
|
projectID,
|
|
3207
3579
|
})
|
|
3580
|
+
|
|
3581
|
+
<span class="cstat-no" title="statement not covered" > this.worker.postMessage({</span>
|
|
3582
|
+
type: 'auth',
|
|
3583
|
+
token,
|
|
3584
|
+
beaconSizeLimit,
|
|
3585
|
+
})
|
|
3586
|
+
|
|
3208
3587
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (!isNewSession && token === sessionToken) {</span>
|
|
3209
3588
|
<span class="cstat-no" title="statement not covered" > this.debug.log('continuing session on new tab', this.session.getTabId())</span>
|
|
3210
3589
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
|
@@ -3216,40 +3595,21 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3216
3595
|
)
|
|
3217
3596
|
<span class="cstat-no" title="statement not covered" > this.localStorage.setItem(this.options.local_uuid_key, userUUID)</span>
|
|
3218
3597
|
|
|
3219
|
-
<span class="cstat-no" title="statement not covered" > this.worker.postMessage({</span>
|
|
3220
|
-
type: 'auth',
|
|
3221
|
-
token,
|
|
3222
|
-
beaconSizeLimit,
|
|
3223
|
-
})
|
|
3224
|
-
|
|
3225
3598
|
<span class="cstat-no" title="statement not covered" > this.compressionThreshold = compressionThreshold</span>
|
|
3226
3599
|
const onStartInfo = <span class="cstat-no" title="statement not covered" >{ sessionToken: token, userUUID, sessionID }</span>
|
|
3227
|
-
|
|
3228
|
-
const flushBuffer = <span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >(b</span>uffer: Message[]) => {</span>
|
|
3229
|
-
let ended = <span class="cstat-no" title="statement not covered" >false</span>
|
|
3230
|
-
const messagesBatch: Message[] = <span class="cstat-no" title="statement not covered" >[buffer.shift() as unknown as Message]</span>
|
|
3231
|
-
<span class="cstat-no" title="statement not covered" > while (!ended) {</span>
|
|
3232
|
-
const nextMsg = <span class="cstat-no" title="statement not covered" >buffer[0]</span>
|
|
3233
|
-
<span class="cstat-no" title="statement not covered" > if (!nextMsg || nextMsg[0] === MType.Timestamp) {</span>
|
|
3234
|
-
<span class="cstat-no" title="statement not covered" > ended = true</span>
|
|
3235
|
-
} else {
|
|
3236
|
-
<span class="cstat-no" title="statement not covered" > messagesBatch.push(buffer.shift() as unknown as Message)</span>
|
|
3237
|
-
}
|
|
3238
|
-
}
|
|
3239
|
-
<span class="cstat-no" title="statement not covered" > this.postToWorker(messagesBatch)</span>
|
|
3240
|
-
}
|
|
3241
3600
|
// TODO: start as early as possible (before receiving the token)
|
|
3242
3601
|
<span class="cstat-no" title="statement not covered" > this.startCallbacks.forEach(<span class="fstat-no" title="function not covered" >(c</span>b) => <span class="cstat-no" title="statement not covered" >cb(onStartInfo))</span> /</span>/ MBTODO: callbacks after DOM "mounted" (observed)
|
|
3243
3602
|
<span class="cstat-no" title="statement not covered" > void this.featureFlags.reloadFlags()</span>
|
|
3244
|
-
/** --------------- COLD START BUFFER ------------------*/
|
|
3245
3603
|
<span class="cstat-no" title="statement not covered" > this.activityState = ActivityState.Active</span>
|
|
3604
|
+
|
|
3605
|
+
/** --------------- COLD START BUFFER ------------------*/
|
|
3246
3606
|
<span class="cstat-no" title="statement not covered" > if (isColdStart) {</span>
|
|
3247
|
-
const
|
|
3607
|
+
const biggestBuffer =
|
|
3248
3608
|
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1.length > this.bufferedMessages2.length</span>
|
|
3249
3609
|
? this.bufferedMessages1
|
|
3250
3610
|
: this.bufferedMessages2
|
|
3251
|
-
<span class="cstat-no" title="statement not covered" > while (
|
|
3252
|
-
<span class="cstat-no" title="statement not covered" > flushBuffer(
|
|
3611
|
+
<span class="cstat-no" title="statement not covered" > while (biggestBuffer.length > 0) {</span>
|
|
3612
|
+
<span class="cstat-no" title="statement not covered" > await this.flushBuffer(biggestBuffer)</span>
|
|
3253
3613
|
}
|
|
3254
3614
|
<span class="cstat-no" title="statement not covered" > this.clearBuffers()</span>
|
|
3255
3615
|
<span class="cstat-no" title="statement not covered" > this.commit()</span>
|
|
@@ -3266,7 +3626,6 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3266
3626
|
<span class="cstat-no" title="statement not covered" > this.canvasRecorder.startTracking()</span>
|
|
3267
3627
|
}
|
|
3268
3628
|
|
|
3269
|
-
<span class="cstat-no" title="statement not covered" > this.notify.log('OpenReplay tracking started.')</span>
|
|
3270
3629
|
// get rid of onStart ?
|
|
3271
3630
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (typeof this.options.onStart === 'function') {</span>
|
|
3272
3631
|
<span class="cstat-no" title="statement not covered" > this.options.onStart(onStartInfo)</span>
|
|
@@ -3313,13 +3672,29 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3313
3672
|
<span class="cstat-no" title="statement not covered" > return UnsuccessfulStart(CANCELED)</span>
|
|
3314
3673
|
}
|
|
3315
3674
|
|
|
3316
|
-
<span class="cstat-no" title="statement not covered" > this.notify.log('OpenReplay was unable to start. ', reason)</span>
|
|
3317
3675
|
<span class="cstat-no" title="statement not covered" > this._debug('session_start', reason)</span>
|
|
3318
3676
|
<span class="cstat-no" title="statement not covered" > this.signalError(START_ERROR, [])</span>
|
|
3319
3677
|
<span class="cstat-no" title="statement not covered" > return UnsuccessfulStart(START_ERROR)</span>
|
|
3320
3678
|
})
|
|
3321
3679
|
}
|
|
3322
3680
|
|
|
3681
|
+
<span class="cstat-no" title="statement not covered" > flushBuffer = <span class="fstat-no" title="function not covered" >async (b</span>uffer: Message[]) =><span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" > {</span></span></span>
|
|
3682
|
+
<span class="cstat-no" title="statement not covered" > return new Promise(<span class="fstat-no" title="function not covered" >(r</span>es) => {</span>
|
|
3683
|
+
let ended = <span class="cstat-no" title="statement not covered" >false</span>
|
|
3684
|
+
const messagesBatch: Message[] = <span class="cstat-no" title="statement not covered" >[buffer.shift() as unknown as Message]</span>
|
|
3685
|
+
<span class="cstat-no" title="statement not covered" > while (!ended) {</span>
|
|
3686
|
+
const nextMsg = <span class="cstat-no" title="statement not covered" >buffer[0]</span>
|
|
3687
|
+
<span class="cstat-no" title="statement not covered" > if (!nextMsg || nextMsg[0] === MType.Timestamp) {</span>
|
|
3688
|
+
<span class="cstat-no" title="statement not covered" > ended = true</span>
|
|
3689
|
+
} else {
|
|
3690
|
+
<span class="cstat-no" title="statement not covered" > messagesBatch.push(buffer.shift() as unknown as Message)</span>
|
|
3691
|
+
}
|
|
3692
|
+
}
|
|
3693
|
+
<span class="cstat-no" title="statement not covered" > this.postToWorker(messagesBatch)</span>
|
|
3694
|
+
<span class="cstat-no" title="statement not covered" > res(null)</span>
|
|
3695
|
+
})
|
|
3696
|
+
}
|
|
3697
|
+
|
|
3323
3698
|
<span class="cstat-no" title="statement not covered" > onUxtCb = []</span>
|
|
3324
3699
|
|
|
3325
3700
|
<span class="fstat-no" title="function not covered" > addOnUxtCb(</span>cb: (id: number) => void) {
|
|
@@ -3369,6 +3744,26 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3369
3744
|
<span class="cstat-no" title="statement not covered" > this.bufferedMessages1.length = 0</span>
|
|
3370
3745
|
<span class="cstat-no" title="statement not covered" > this.bufferedMessages2.length = 0</span>
|
|
3371
3746
|
}
|
|
3747
|
+
|
|
3748
|
+
/**
|
|
3749
|
+
* Creates a named hook that expects event name, data string and msg direction (up/down),
|
|
3750
|
+
* it will skip any message bigger than 5 mb or event name bigger than 255 symbols
|
|
3751
|
+
* @returns {(msgType: string, data: string, dir: 'up' | 'down') => void}
|
|
3752
|
+
* */
|
|
3753
|
+
<span class="fstat-no" title="function not covered" > trackWs(</span>channelName: string): (msgType: string, data: string, dir: 'up' | 'down') => void {
|
|
3754
|
+
const channel = <span class="cstat-no" title="statement not covered" >channelName</span>
|
|
3755
|
+
<span class="cstat-no" title="statement not covered" > return <span class="fstat-no" title="function not covered" >(m</span>sgType: string, data: string, dir: 'up' | 'down' = <span class="branch-0 cbranch-no" title="branch not covered" >'down')</span> => {</span>
|
|
3756
|
+
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (</span>
|
|
3757
|
+
typeof msgType !== 'string' ||
|
|
3758
|
+
typeof data !== 'string' ||
|
|
3759
|
+
data.length > 5 * 1024 * 1024 ||
|
|
3760
|
+
msgType.length > 255
|
|
3761
|
+
) {
|
|
3762
|
+
<span class="cstat-no" title="statement not covered" > return</span>
|
|
3763
|
+
}
|
|
3764
|
+
<span class="cstat-no" title="statement not covered" > this.send(WSChannel('websocket', channel, data, this.timestamp(), dir, msgType))</span>
|
|
3765
|
+
}
|
|
3766
|
+
}
|
|
3372
3767
|
|
|
3373
3768
|
<span class="fstat-no" title="function not covered" > stop(</span>stopWorker = <span class="branch-0 cbranch-no" title="branch not covered" >true)</span>: void {
|
|
3374
3769
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (this.activityState !== ActivityState.NotActive) {</span>
|
|
@@ -3379,7 +3774,8 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3379
3774
|
<span class="cstat-no" title="statement not covered" > this.nodes.clear()</span>
|
|
3380
3775
|
<span class="cstat-no" title="statement not covered" > this.ticker.stop()</span>
|
|
3381
3776
|
<span class="cstat-no" title="statement not covered" > this.stopCallbacks.forEach(<span class="fstat-no" title="function not covered" >(c</span>b) => <span class="cstat-no" title="statement not covered" >cb())</span></span>
|
|
3382
|
-
<span class="cstat-no" title="statement not covered" > this.
|
|
3777
|
+
<span class="cstat-no" title="statement not covered" > this.debug.log('OpenReplay tracking stopped.')</span>
|
|
3778
|
+
<span class="cstat-no" title="statement not covered" > this.tagWatcher.clear()</span>
|
|
3383
3779
|
<span class="cstat-no" title="statement not covered" > <span class="missing-if-branch" title="if path not taken" >I</span>if (this.worker && stopWorker) {</span>
|
|
3384
3780
|
<span class="cstat-no" title="statement not covered" > this.worker.postMessage('stop')</span>
|
|
3385
3781
|
}
|
|
@@ -3397,7 +3793,7 @@ function <span class="fstat-no" title="function not covered" >getTimezone(</span
|
|
|
3397
3793
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
3398
3794
|
Code coverage generated by
|
|
3399
3795
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
3400
|
-
at
|
|
3796
|
+
at 2024-01-09T16:51:30.347Z
|
|
3401
3797
|
</div>
|
|
3402
3798
|
<script src="../../prettify.js"></script>
|
|
3403
3799
|
<script>
|