@shrfe/assets 1.0.63 → 1.0.64

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.
@@ -35,6 +35,472 @@
35
35
  border: 2px solid transparent;
36
36
  }
37
37
 
38
+ *,
39
+ *::before,
40
+ *::after {
41
+ box-sizing: border-box;
42
+ }
43
+
44
+ body {
45
+ margin: 0;
46
+ font-size: 1rem;
47
+ font-weight: 400;
48
+ line-height: 1.5;
49
+ color: #212529;
50
+ background-color: #fff;
51
+ -webkit-text-size-adjust: 100%;
52
+ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
53
+ }
54
+
55
+ hr {
56
+ margin: 1rem 0;
57
+ color: inherit;
58
+ border: 0;
59
+ border-top: 1px solid;
60
+ opacity: 0.25;
61
+ }
62
+
63
+ h1,
64
+ h2,
65
+ h3,
66
+ h4,
67
+ h5,
68
+ h6 {
69
+ margin-top: 0;
70
+ margin-bottom: 0.5rem;
71
+ font-weight: 500;
72
+ line-height: 1.2;
73
+ color: inherit;
74
+ }
75
+
76
+ h1 {
77
+ font-size: 2em;
78
+ margin: 0.67em 0;
79
+ }
80
+
81
+ h2 {
82
+ font-size: calc(1.325rem + 0.9vw);
83
+ }
84
+
85
+ h3 {
86
+ font-size: calc(1.3rem + 0.6vw);
87
+ }
88
+
89
+ h4 {
90
+ font-size: calc(1.275rem + 0.3vw);
91
+ }
92
+
93
+ h5 {
94
+ font-size: 1.25rem;
95
+ }
96
+
97
+ h6 {
98
+ font-size: 1rem;
99
+ }
100
+
101
+ @media (min-width: 1200px) {
102
+ h2 {
103
+ font-size: 2rem;
104
+ }
105
+ h3 {
106
+ font-size: 1.75rem;
107
+ }
108
+ h4 {
109
+ font-size: 1.5rem;
110
+ }
111
+ }
112
+ p {
113
+ margin-top: 0;
114
+ margin-bottom: 1rem;
115
+ }
116
+
117
+ abbr[title] {
118
+ text-decoration: underline dotted;
119
+ cursor: help;
120
+ text-decoration-skip-ink: none;
121
+ }
122
+
123
+ address {
124
+ margin-bottom: 1rem;
125
+ font-style: normal;
126
+ line-height: inherit;
127
+ }
128
+
129
+ ol,
130
+ ul {
131
+ padding-left: 2rem;
132
+ }
133
+
134
+ ol,
135
+ ul,
136
+ dl {
137
+ margin-top: 0;
138
+ margin-bottom: 1rem;
139
+ }
140
+
141
+ ol ol,
142
+ ul ul,
143
+ ol ul,
144
+ ul ol {
145
+ margin-bottom: 0;
146
+ }
147
+
148
+ dt {
149
+ font-weight: 700;
150
+ }
151
+
152
+ dd {
153
+ margin-bottom: 0.5rem;
154
+ margin-left: 0;
155
+ }
156
+
157
+ blockquote {
158
+ margin: 0 0 1rem;
159
+ }
160
+
161
+ b,
162
+ strong {
163
+ font-weight: bolder;
164
+ }
165
+
166
+ small {
167
+ font-size: 80%;
168
+ }
169
+
170
+ mark {
171
+ padding: 0.1875em;
172
+ color: #212529;
173
+ background-color: #fff3cd;
174
+ }
175
+
176
+ sub,
177
+ sup {
178
+ position: relative;
179
+ font-size: 75%;
180
+ line-height: 0;
181
+ vertical-align: baseline;
182
+ }
183
+
184
+ sub {
185
+ bottom: -0.25em;
186
+ }
187
+
188
+ sup {
189
+ top: -0.5em;
190
+ }
191
+
192
+ a {
193
+ color: #0d6efd;
194
+ text-decoration: underline;
195
+ background-color: transparent;
196
+ }
197
+
198
+ a:hover {
199
+ color: #0a58ca;
200
+ }
201
+
202
+ a:not([href]):not([class]),
203
+ a:not([href]):not([class]):hover {
204
+ color: inherit;
205
+ text-decoration: none;
206
+ }
207
+
208
+ pre,
209
+ code,
210
+ kbd,
211
+ samp {
212
+ font-family: monospace;
213
+ font-size: 1em;
214
+ }
215
+
216
+ pre {
217
+ display: block;
218
+ margin-top: 0;
219
+ margin-bottom: 1rem;
220
+ overflow: auto;
221
+ }
222
+
223
+ pre code {
224
+ font-size: inherit;
225
+ color: inherit;
226
+ word-break: normal;
227
+ }
228
+
229
+ code {
230
+ color: #d63384;
231
+ word-wrap: break-word;
232
+ }
233
+
234
+ a > code {
235
+ color: inherit;
236
+ }
237
+
238
+ kbd {
239
+ padding: 0.1875rem 0.375rem;
240
+ color: #fff;
241
+ background-color: #212529;
242
+ border-radius: 0.25rem;
243
+ }
244
+
245
+ kbd kbd {
246
+ padding: 0;
247
+ font-size: 1em;
248
+ }
249
+
250
+ figure {
251
+ margin: 0 0 1rem;
252
+ }
253
+
254
+ img,
255
+ svg {
256
+ vertical-align: middle;
257
+ }
258
+
259
+ img {
260
+ border-style: none;
261
+ }
262
+
263
+ table {
264
+ caption-side: bottom;
265
+ border-collapse: collapse;
266
+ }
267
+
268
+ caption {
269
+ padding-top: 0.5rem;
270
+ padding-bottom: 0.5rem;
271
+ color: rgba(33, 37, 41, 0.75);
272
+ text-align: left;
273
+ }
274
+
275
+ th {
276
+ text-align: inherit;
277
+ text-align: -webkit-match-parent;
278
+ }
279
+
280
+ thead,
281
+ tbody,
282
+ tfoot,
283
+ tr,
284
+ td,
285
+ th {
286
+ border-color: inherit;
287
+ border-style: solid;
288
+ border-width: 0;
289
+ }
290
+
291
+ label {
292
+ display: inline-block;
293
+ }
294
+
295
+ button {
296
+ border-radius: 0;
297
+ }
298
+
299
+ button:focus:not(:focus-visible) {
300
+ outline: 0;
301
+ }
302
+
303
+ input,
304
+ button,
305
+ select,
306
+ optgroup,
307
+ textarea {
308
+ margin: 0;
309
+ font-size: 100%;
310
+ line-height: 1.15;
311
+ }
312
+
313
+ button,
314
+ select {
315
+ text-transform: none;
316
+ }
317
+
318
+ [role=button] {
319
+ cursor: pointer;
320
+ }
321
+
322
+ select {
323
+ word-wrap: normal;
324
+ }
325
+
326
+ select:disabled {
327
+ opacity: 1;
328
+ }
329
+
330
+ button,
331
+ [type=button],
332
+ [type=reset],
333
+ [type=submit] {
334
+ -webkit-appearance: button;
335
+ appearance: button;
336
+ }
337
+
338
+ button:not(:disabled),
339
+ [type=button]:not(:disabled),
340
+ [type=reset]:not(:disabled),
341
+ [type=submit]:not(:disabled) {
342
+ cursor: pointer;
343
+ }
344
+
345
+ ::-moz-focus-inner {
346
+ padding: 0;
347
+ border-style: none;
348
+ }
349
+
350
+ button::-moz-focus-inner,
351
+ [type=button]::-moz-focus-inner,
352
+ [type=reset]::-moz-focus-inner,
353
+ [type=submit]::-moz-focus-inner {
354
+ border-style: none;
355
+ padding: 0;
356
+ }
357
+
358
+ button:-moz-focusring,
359
+ [type=button]:-moz-focusring,
360
+ [type=reset]:-moz-focusring,
361
+ [type=submit]:-moz-focusring {
362
+ outline: 1px dotted ButtonText;
363
+ }
364
+
365
+ textarea {
366
+ resize: vertical;
367
+ overflow: auto;
368
+ }
369
+
370
+ [type=checkbox],
371
+ [type=radio] {
372
+ box-sizing: border-box;
373
+ padding: 0;
374
+ }
375
+
376
+ [type=number]::-webkit-inner-spin-button,
377
+ [type=number]::-webkit-outer-spin-button {
378
+ height: auto;
379
+ }
380
+
381
+ fieldset {
382
+ min-width: 0;
383
+ padding: 0.35em 0.75em 0.625em;
384
+ margin: 0;
385
+ border: 0;
386
+ }
387
+
388
+ legend {
389
+ float: left;
390
+ width: 100%;
391
+ padding: 0;
392
+ margin-bottom: 0.5rem;
393
+ font-size: calc(1.275rem + 0.3vw);
394
+ line-height: inherit;
395
+ box-sizing: border-box;
396
+ color: inherit;
397
+ display: table;
398
+ max-width: 100%;
399
+ white-space: normal;
400
+ }
401
+
402
+ @media (min-width: 1200px) {
403
+ legend {
404
+ font-size: 1.5rem;
405
+ }
406
+ }
407
+ legend + * {
408
+ clear: left;
409
+ }
410
+
411
+ ::-webkit-datetime-edit-fields-wrapper,
412
+ ::-webkit-datetime-edit-text,
413
+ ::-webkit-datetime-edit-minute,
414
+ ::-webkit-datetime-edit-hour-field,
415
+ ::-webkit-datetime-edit-day-field,
416
+ ::-webkit-datetime-edit-month-field,
417
+ ::-webkit-datetime-edit-year-field {
418
+ padding: 0;
419
+ }
420
+
421
+ ::-webkit-inner-spin-button {
422
+ height: auto;
423
+ }
424
+
425
+ [type=search] {
426
+ -webkit-appearance: textfield;
427
+ appearance: textfield;
428
+ outline-offset: -2px;
429
+ }
430
+
431
+ [type=search]::-webkit-search-cancel-button,
432
+ [type=search]::-webkit-search-decoration {
433
+ -webkit-appearance: none;
434
+ appearance: none;
435
+ }
436
+
437
+ [list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator {
438
+ display: none !important;
439
+ }
440
+
441
+ ::-webkit-color-swatch-wrapper {
442
+ padding: 0;
443
+ }
444
+
445
+ ::file-selector-button {
446
+ font: inherit;
447
+ -webkit-appearance: button;
448
+ }
449
+
450
+ output {
451
+ display: inline-block;
452
+ }
453
+
454
+ iframe {
455
+ border: 0;
456
+ }
457
+
458
+ summary {
459
+ display: list-item;
460
+ cursor: pointer;
461
+ }
462
+
463
+ progress {
464
+ vertical-align: baseline;
465
+ }
466
+
467
+ main {
468
+ display: block;
469
+ }
470
+
471
+ details {
472
+ display: block;
473
+ }
474
+
475
+ template {
476
+ display: none;
477
+ }
478
+
479
+ [hidden] {
480
+ display: none;
481
+ }
482
+
483
+ textarea:hover,
484
+ input:hover,
485
+ textarea:active,
486
+ input:active,
487
+ textarea:focus,
488
+ input:focus,
489
+ label:focus {
490
+ outline: 0 !important;
491
+ appearance: none !important;
492
+ box-shadow: none !important;
493
+ border-color: #1e5083 !important;
494
+ }
495
+
496
+ button:focus,
497
+ button:active,
498
+ button:hover {
499
+ outline: 0 !important;
500
+ appearance: none !important;
501
+ box-shadow: none !important;
502
+ }
503
+
38
504
  :root {
39
505
  --sfe-stack-level-base: 100;
40
506
  --sfe-stack-level-navs: calc(var(--sfe-stack-level-base) + 100);
@@ -26041,7 +26041,7 @@ class HTTPService extends (/* unused pure expression or super */ null && (HTTPBa
26041
26041
 
26042
26042
  ;// CONCATENATED MODULE: ../../node_modules/@vue/shared/dist/shared.esm-bundler.js
26043
26043
  /**
26044
- * @vue/shared v3.5.42
26044
+ * @vue/shared v3.5.43
26045
26045
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
26046
26046
  * @license MIT
26047
26047
  **/
@@ -26309,10 +26309,10 @@ function normalizeStyle(value) {
26309
26309
  }
26310
26310
  const listDelimiterRE = /;(?![^(]*\))/g;
26311
26311
  const propertyDelimiterRE = /:([^]+)/;
26312
- const styleCommentRE = /\/\*[^]*?\*\//g;
26312
+ const styleCommentRE = /"(?:[^"\\]|\\[^])*"|'(?:[^'\\]|\\[^])*'|\\[^]|\/\*[^]*?\*\//g;
26313
26313
  function parseStringStyle(cssText) {
26314
26314
  const ret = {};
26315
- cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach((item) => {
26315
+ cssText.replace(styleCommentRE, (match) => match.startsWith("/*") ? "" : match).split(listDelimiterRE).forEach((item) => {
26316
26316
  if (item) {
26317
26317
  const tmp = item.split(propertyDelimiterRE);
26318
26318
  tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
@@ -26473,22 +26473,22 @@ function getEscapedCssVarName(key, doubleEscape) {
26473
26473
  );
26474
26474
  }
26475
26475
 
26476
- function looseCompareArrays(a, b) {
26476
+ function looseCompareArrays(a, b, seen) {
26477
26477
  if (a.length !== b.length) return false;
26478
26478
  let equal = true;
26479
26479
  for (let i = 0; equal && i < a.length; i++) {
26480
- equal = looseEqual(a[i], b[i]);
26480
+ equal = looseEqual(a[i], b[i], seen);
26481
26481
  }
26482
26482
  return equal;
26483
26483
  }
26484
- function looseCompareCollections(a, b) {
26484
+ function looseCompareCollections(a, b, seen) {
26485
26485
  if (a.size !== b.size) return false;
26486
26486
  const candidates = Array.from(b);
26487
26487
  const matched = new Uint8Array(candidates.length);
26488
26488
  for (const item of a) {
26489
26489
  let index = -1;
26490
26490
  for (let i = 0; i < candidates.length; i++) {
26491
- if (!matched[i] && looseEqual(item, candidates[i])) {
26491
+ if (!matched[i] && looseEqual(item, candidates[i], seen)) {
26492
26492
  index = i;
26493
26493
  break;
26494
26494
  }
@@ -26498,7 +26498,47 @@ function looseCompareCollections(a, b) {
26498
26498
  }
26499
26499
  return true;
26500
26500
  }
26501
- function looseEqual(a, b) {
26501
+ function looseCompareObjects(a, b, seen) {
26502
+ let aValidType = shared_esm_bundler_isMap(a);
26503
+ let bValidType = shared_esm_bundler_isMap(b);
26504
+ if (aValidType || bValidType) {
26505
+ return aValidType && bValidType ? looseCompareCollections(a, b, seen) : false;
26506
+ }
26507
+ aValidType = shared_esm_bundler_isSet(a);
26508
+ bValidType = shared_esm_bundler_isSet(b);
26509
+ if (aValidType || bValidType) {
26510
+ return aValidType && bValidType ? looseCompareCollections(a, b, seen) : false;
26511
+ }
26512
+ const aKeysCount = Object.keys(a).length;
26513
+ const bKeysCount = Object.keys(b).length;
26514
+ if (aKeysCount !== bKeysCount) {
26515
+ return false;
26516
+ }
26517
+ for (const key in a) {
26518
+ const aHasKey = a.hasOwnProperty(key);
26519
+ const bHasKey = b.hasOwnProperty(key);
26520
+ if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key], seen)) {
26521
+ return false;
26522
+ }
26523
+ }
26524
+ return String(a) === String(b);
26525
+ }
26526
+ function looseCompareNested(a, b, seen, compare) {
26527
+ if (!seen) {
26528
+ seen = [/* @__PURE__ */ new Map(), /* @__PURE__ */ new Map()];
26529
+ }
26530
+ const [seenA, seenB] = seen;
26531
+ if (seenA.has(a) || seenB.has(b)) {
26532
+ return seenA.get(a) === b && seenB.get(b) === a;
26533
+ }
26534
+ seenA.set(a, b);
26535
+ seenB.set(b, a);
26536
+ const equal = compare(a, b, seen);
26537
+ seenA.delete(a);
26538
+ seenB.delete(b);
26539
+ return equal;
26540
+ }
26541
+ function looseEqual(a, b, seen) {
26502
26542
  if (a === b) return true;
26503
26543
  let aValidType = shared_esm_bundler_isDate(a);
26504
26544
  let bValidType = shared_esm_bundler_isDate(b);
@@ -26513,7 +26553,7 @@ function looseEqual(a, b) {
26513
26553
  aValidType = shared_esm_bundler_isArray(a);
26514
26554
  bValidType = shared_esm_bundler_isArray(b);
26515
26555
  if (aValidType || bValidType) {
26516
- return aValidType && bValidType ? looseCompareArrays(a, b) : false;
26556
+ return aValidType && bValidType ? looseCompareNested(a, b, seen, looseCompareArrays) : false;
26517
26557
  }
26518
26558
  aValidType = shared_esm_bundler_isObject(a);
26519
26559
  bValidType = shared_esm_bundler_isObject(b);
@@ -26521,28 +26561,7 @@ function looseEqual(a, b) {
26521
26561
  if (!aValidType || !bValidType) {
26522
26562
  return false;
26523
26563
  }
26524
- aValidType = shared_esm_bundler_isMap(a);
26525
- bValidType = shared_esm_bundler_isMap(b);
26526
- if (aValidType || bValidType) {
26527
- return aValidType && bValidType ? looseCompareCollections(a, b) : false;
26528
- }
26529
- aValidType = shared_esm_bundler_isSet(a);
26530
- bValidType = shared_esm_bundler_isSet(b);
26531
- if (aValidType || bValidType) {
26532
- return aValidType && bValidType ? looseCompareCollections(a, b) : false;
26533
- }
26534
- const aKeysCount = Object.keys(a).length;
26535
- const bKeysCount = Object.keys(b).length;
26536
- if (aKeysCount !== bKeysCount) {
26537
- return false;
26538
- }
26539
- for (const key in a) {
26540
- const aHasKey = a.hasOwnProperty(key);
26541
- const bHasKey = b.hasOwnProperty(key);
26542
- if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
26543
- return false;
26544
- }
26545
- }
26564
+ return looseCompareNested(a, b, seen, looseCompareObjects);
26546
26565
  }
26547
26566
  return String(a) === String(b);
26548
26567
  }
@@ -26606,7 +26625,7 @@ function normalizeCssVarValue(value) {
26606
26625
 
26607
26626
  ;// CONCATENATED MODULE: ../../node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js
26608
26627
  /**
26609
- * @vue/reactivity v3.5.42
26628
+ * @vue/reactivity v3.5.43
26610
26629
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
26611
26630
  * @license MIT
26612
26631
  **/
@@ -27326,7 +27345,9 @@ function reactiveReadArray(array) {
27326
27345
  const raw = toRaw(array);
27327
27346
  if (raw === array) return raw;
27328
27347
  track(raw, "iterate", ARRAY_ITERATE_KEY);
27329
- return isShallow(array) ? raw : raw.map(toReactive);
27348
+ if (isShallow(array)) return raw;
27349
+ if (!isReadonly(array)) return raw.map(toReactive);
27350
+ return isReactive(array) ? raw.map((item) => toReadonly(toReactive(item))) : raw.map(toReadonly);
27330
27351
  }
27331
27352
  function shallowReadArray(arr) {
27332
27353
  track(arr = toRaw(arr), "iterate", ARRAY_ITERATE_KEY);
@@ -28658,7 +28679,7 @@ if (typeof(window) === 'undefined') {
28658
28679
 
28659
28680
  var Config = {
28660
28681
  DEBUG: false,
28661
- LIB_VERSION: '2.82.1'
28682
+ LIB_VERSION: '2.83.0'
28662
28683
  };
28663
28684
 
28664
28685
  // Window global names for async modules
@@ -29896,6 +29917,16 @@ function serializeElementNode(n2, options) {
29896
29917
  attributes.checked = checked;
29897
29918
  }
29898
29919
  }
29920
+ if ((tagName === "input" || tagName === "textarea") && attributes.placeholder) {
29921
+ attributes.placeholder = maskInputValue({
29922
+ element: n2,
29923
+ type: getInputType(n2),
29924
+ tagName: tagName,
29925
+ value: attributes.placeholder,
29926
+ maskInputOptions: maskInputOptions,
29927
+ maskInputFn: maskInputFn
29928
+ });
29929
+ }
29899
29930
  if (tagName === "option") {
29900
29931
  if (n2.selected && !maskInputOptions["select"]) {
29901
29932
  attributes.selected = true;
@@ -39473,7 +39504,7 @@ var mixpanel_module_MutationBuffer = /*#__PURE__*/ function() {
39473
39504
  var target = m.target;
39474
39505
  var attributeName = m.attributeName;
39475
39506
  var value1 = m.target.getAttribute(attributeName);
39476
- if (attributeName === "value") {
39507
+ if (attributeName === "value" || attributeName === "placeholder") {
39477
39508
  var type = getInputType(target);
39478
39509
  value1 = maskInputValue({
39479
39510
  element: target,
@@ -47598,12 +47629,7 @@ var nativeBind = FuncProto.bind,
47598
47629
  nativeIsArray = Array.isArray,
47599
47630
  breaker = {};
47600
47631
 
47601
- var mixpanel_module_ = {
47602
- trim: function(str) {
47603
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/Trim#Polyfill
47604
- return str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, '');
47605
- }
47606
- };
47632
+ var mixpanel_module_ = {};
47607
47633
 
47608
47634
  // Console override
47609
47635
  var console$1 = {
@@ -48486,7 +48512,11 @@ mixpanel_module_.HTTPBuildQuery = function(formdata, arg_separator) {
48486
48512
  mixpanel_module_.getQueryParam = function(url, param) {
48487
48513
  // Expects a raw URL
48488
48514
 
48489
- param = param.replace(/[[]/g, '\\[').replace(/[\]]/g, '\\]');
48515
+ // Escape the RegExp metacharacters the param name may contain before
48516
+ // interpolating it into `regexS`. Backslash is escaped in the same pass as
48517
+ // the brackets (a single character class), so a param name is never able to
48518
+ // introduce an unintended escape sequence (CodeQL js/incomplete-sanitization).
48519
+ param = param.replace(/[[\]\\]/g, '\\$&');
48490
48520
  var regexS = '[\\?&]' + param + '=([^&#]*)',
48491
48521
  regex = new RegExp(regexS),
48492
48522
  results = regex.exec(url);
@@ -51056,7 +51086,7 @@ function getSafeText(el, ev, allowElementCallback, allowSelectors) {
51056
51086
  if (shouldTrackElementDetails(el, ev, allowElementCallback, allowSelectors) && el.childNodes && el.childNodes.length) {
51057
51087
  mixpanel_module_.each(el.childNodes, function(child) {
51058
51088
  if (isTextNode(child) && child.textContent) {
51059
- elText += mixpanel_module_.trim(child.textContent)
51089
+ elText += child.textContent.trim()
51060
51090
  // scrub potentially sensitive values
51061
51091
  .split(/(\s+)/).filter(shouldTrackValue).join('')
51062
51092
  // normalize whitespace
@@ -51067,7 +51097,7 @@ function getSafeText(el, ev, allowElementCallback, allowSelectors) {
51067
51097
  });
51068
51098
  }
51069
51099
 
51070
- return mixpanel_module_.trim(elText);
51100
+ return elText.trim();
51071
51101
  }
51072
51102
 
51073
51103
  function guessRealClickTarget(ev) {
@@ -51319,7 +51349,7 @@ function shouldTrackValue(value) {
51319
51349
  }
51320
51350
 
51321
51351
  if (typeof value === 'string') {
51322
- value = mixpanel_module_.trim(value);
51352
+ value = value.trim();
51323
51353
 
51324
51354
  // check to see if input value looks like a credit card number
51325
51355
  // see: https://www.safaribooksonline.com/library/view/regular-expressions-cookbook/9781449327453/ch04s20.html
@@ -52174,6 +52204,25 @@ function initXhrObserver(cb, win, options) {
52174
52204
  };
52175
52205
  }
52176
52206
 
52207
+ /**
52208
+ * Build the Request used to inspect an outgoing fetch call.
52209
+ *
52210
+ * Constructing a Request from another Request marks the source's body as used, which makes
52211
+ * the caller's own fetch fail with "Cannot construct a Request with a Request object that has
52212
+ * already been used". Clone Request inputs first so the object the caller passed stays intact.
52213
+ *
52214
+ * @param {RequestInfo | URL} input
52215
+ * @param {RequestInit} [init]
52216
+ * @returns {Request}
52217
+ */
52218
+ function buildRecordedRequest(input, init) {
52219
+ if (typeof Request !== 'undefined' && input instanceof Request) {
52220
+ var cloned = input.clone();
52221
+ return init ? new Request(cloned, init) : cloned;
52222
+ }
52223
+ return new Request(input, init);
52224
+ }
52225
+
52177
52226
  /**
52178
52227
  * @param {networkCallback} cb
52179
52228
  * @param {Window} win
@@ -52189,7 +52238,7 @@ function initFetchObserver(cb, win, options) {
52189
52238
 
52190
52239
  var restorePatch = patch(win, 'fetch', function(/** @type {typeof fetch} */ originalFetch) {
52191
52240
  return function() {
52192
- var req = new Request(arguments[0], arguments[1]);
52241
+ var req = buildRecordedRequest(arguments[0], arguments[1]);
52193
52242
  /** @type {Response | undefined} */
52194
52243
  var res;
52195
52244
  /** @type {Partial<NetworkRequest>} */
@@ -53696,6 +53745,260 @@ function requireLogic () {
53696
53745
  var logicExports = requireLogic();
53697
53746
  var mixpanel_module_jsonLogic = /*@__PURE__*/getDefaultExportFromCjs(logicExports);
53698
53747
 
53748
+ // Strict RFC3339 guard for datetime strings. The date and hour fields are captured so the calendar
53749
+ // can be validated separately; the regex only constrains their shape.
53750
+ var RFC3339_REGEX = /^(\d{4})-(\d{2})-(\d{2})[Tt](\d{2}):\d{2}:\d{2}(\.\d+)?([Zz]|[+-]\d{2}:\d{2})$/;
53751
+
53752
+ // SemVer 2.0.0 requires major.minor.patch; partial versions are zero-padded to this.
53753
+ var SEMVER_PARTS = 3;
53754
+
53755
+ // Longest operand the semver regex is allowed to see. A real version never approaches this; the
53756
+ // bound matches MAX_LENGTH in node-semver, and keeps an arbitrarily long property value off the
53757
+ // regex regardless of how the engine schedules backtracking.
53758
+ var MAX_SEMVER_LENGTH = 256;
53759
+
53760
+ // Epoch milliseconds are compared as int64 elsewhere, so anything at or beyond this is out of range.
53761
+ var MAX_EPOCH_MS = 9223372036854775808;
53762
+
53763
+ // Using the official semantic versioning 2.0.0 regular expression to handle cross-platform validation
53764
+ // differences on other SDK's. For example, some platforms allow leading zeros even though it is not valid
53765
+ // as part of the Semver 2.0.0 spec. See https://semver.org/
53766
+ var SEMVER_REGEX = /^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/;
53767
+
53768
+ // Registers custom operators into the JSONLogic engine.
53769
+ // 1. Semantic Versioning 2.0.0 comparison
53770
+ // 2. RFC3339 datetime comparison
53771
+ function registerCustomOperators(jsonLogic) {
53772
+ jsonLogic.add_operation('semver_compare', semverCompare);
53773
+ jsonLogic.add_operation('datetime_compare', datetimeCompare);
53774
+ }
53775
+
53776
+ // Implements a custom operation for semantic versioning comparison that conforms to the semver 2.0.0 standard.
53777
+ // Prior to comparison, any leading version prefix is stripped.
53778
+ function semverCompare() {
53779
+ var ops = operands(arguments);
53780
+ if (!ops) {
53781
+ return false;
53782
+ }
53783
+ if (typeof ops.actual !== 'string' || typeof ops.target !== 'string') {
53784
+ return false;
53785
+ }
53786
+ if (ops.actual.length > MAX_SEMVER_LENGTH || ops.target.length > MAX_SEMVER_LENGTH) {
53787
+ return false;
53788
+ }
53789
+ var actual = normalizeSemver(ops.actual);
53790
+ var target = normalizeSemver(ops.target);
53791
+ if (!SEMVER_REGEX.test(actual) || !SEMVER_REGEX.test(target)) {
53792
+ return false;
53793
+ }
53794
+ var cmp = compareSemver(actual, target);
53795
+ return comparatorMatches(cmp, ops.symbol);
53796
+ }
53797
+
53798
+ // Strip optional build metadata and separate the core version from pre-release identifiers
53799
+ function splitSemver(version) {
53800
+ var plus = version.indexOf('+');
53801
+ if (plus !== -1) {
53802
+ version = version.slice(0, plus);
53803
+ }
53804
+ var dash = version.indexOf('-');
53805
+ if (dash === -1) {
53806
+ return {core: version.split('.'), prerelease: []};
53807
+ }
53808
+ return {core: version.slice(0, dash).split('.'), prerelease: version.slice(dash + 1).split('.')};
53809
+ }
53810
+
53811
+ function isNumericIdentifier(identifier) {
53812
+ return /^[0-9]+$/.test(identifier);
53813
+ }
53814
+
53815
+ // Numeric identifiers carry no leading zeros, so the longer run of digits is the larger number.
53816
+ // Comparing them as digits rather than as numbers keeps versions past Number.MAX_SAFE_INTEGER ordered
53817
+ // correctly.
53818
+ function compareNumeric(a, b) {
53819
+ if (a.length !== b.length) {
53820
+ return a.length < b.length ? -1 : 1;
53821
+ }
53822
+ return a < b ? -1 : (a > b ? 1 : 0);
53823
+ }
53824
+
53825
+ // SemVer 2.0.0 section 11.4: digits compare numerically, a numeric identifier ranks below an
53826
+ // alphanumeric one, and anything else compares by ASCII order.
53827
+ function comparePrereleaseIdentifier(a, b) {
53828
+ var aNumeric = isNumericIdentifier(a);
53829
+ var bNumeric = isNumericIdentifier(b);
53830
+ if (aNumeric && bNumeric) {
53831
+ return compareNumeric(a, b);
53832
+ }
53833
+ if (aNumeric) {
53834
+ return -1;
53835
+ }
53836
+ if (bNumeric) {
53837
+ return 1;
53838
+ }
53839
+ return a < b ? -1 : (a > b ? 1 : 0);
53840
+ }
53841
+
53842
+ // Ordering per SemVer 2.0.0 section 11. Both operands have already been normalized and matched against
53843
+ // the official regex, so the core holds exactly three numeric identifiers and every prerelease field is
53844
+ // well-formed; the split needs no error path.
53845
+ function compareSemver(actualVersion, targetVersion) {
53846
+ var actual = splitSemver(actualVersion);
53847
+ var target = splitSemver(targetVersion);
53848
+ var i, result;
53849
+
53850
+ for (i = 0; i < actual.core.length; i++) {
53851
+ result = compareNumeric(actual.core[i], target.core[i]);
53852
+ if (result !== 0) {
53853
+ return result;
53854
+ }
53855
+ }
53856
+
53857
+ // A prerelease ranks below the release it belongs to (section 11.3).
53858
+ if (!actual.prerelease.length && !target.prerelease.length) {
53859
+ return 0;
53860
+ }
53861
+ if (!actual.prerelease.length) {
53862
+ return 1;
53863
+ }
53864
+ if (!target.prerelease.length) {
53865
+ return -1;
53866
+ }
53867
+
53868
+ var shared = Math.min(actual.prerelease.length, target.prerelease.length);
53869
+ for (i = 0; i < shared; i++) {
53870
+ result = comparePrereleaseIdentifier(actual.prerelease[i], target.prerelease[i]);
53871
+ if (result !== 0) {
53872
+ return result;
53873
+ }
53874
+ }
53875
+ // Every field so far is equal, so the longer list wins (section 11.4.4).
53876
+ if (actual.prerelease.length !== target.prerelease.length) {
53877
+ return actual.prerelease.length < target.prerelease.length ? -1 : 1;
53878
+ }
53879
+ return 0;
53880
+ }
53881
+
53882
+ // Implements a custom operation for datetime comparison.
53883
+ // The target value stored on the feature flag is the millisecond epoch, whereas the actual value provided at evaluation time must be RFC-3339 formatted.
53884
+ function datetimeCompare() {
53885
+ var ops = operands(arguments);
53886
+ if (!ops) {
53887
+ return false;
53888
+ }
53889
+ var actualSec = convertRfc3339ToUnixSeconds(ops.actual);
53890
+ var targetSec = convertUnixMillisecondsToSeconds(ops.target);
53891
+ if (actualSec === null || targetSec === null) {
53892
+ return false;
53893
+ }
53894
+ var cmp = actualSec - targetSec;
53895
+ return comparatorMatches(cmp, ops.symbol);
53896
+ }
53897
+
53898
+ function operands(args) {
53899
+ if (args.length !== 3) {
53900
+ return null;
53901
+ }
53902
+ return { actual: args[0], symbol: args[1], target: args[2] };
53903
+ }
53904
+
53905
+ function comparatorMatches(cmp, symbol) {
53906
+ switch (symbol) {
53907
+ case '===':
53908
+ return cmp === 0;
53909
+ case '!==':
53910
+ return cmp !== 0;
53911
+ case '<':
53912
+ return cmp < 0;
53913
+ case '<=':
53914
+ return cmp <= 0;
53915
+ case '>':
53916
+ return cmp > 0;
53917
+ case '>=':
53918
+ return cmp >= 0;
53919
+ default:
53920
+ return false;
53921
+ }
53922
+ }
53923
+
53924
+ function normalizeSemver(version) {
53925
+ var stripped = version.trim().replace(/^[vV]/, '');
53926
+
53927
+ var suffixStart = stripped.length;
53928
+ var separators = ['-', '+'];
53929
+ for (var i = 0; i < separators.length; i++) {
53930
+ var index = stripped.indexOf(separators[i]);
53931
+ if (index !== -1 && index < suffixStart) {
53932
+ suffixStart = index;
53933
+ }
53934
+ }
53935
+
53936
+ var core = stripped.slice(0, suffixStart);
53937
+ var suffix = stripped.slice(suffixStart);
53938
+
53939
+ var parts = core.split('.');
53940
+ while (parts.length < SEMVER_PARTS) {
53941
+ parts.push('0');
53942
+ }
53943
+ return parts.join('.') + suffix;
53944
+ }
53945
+
53946
+ // The regex constrains each field to two digits, which still admits a date that cannot exist, such as
53947
+ // 2026-02-30 or 29 February in a common year. Writing the fields into a Date and reading them back
53948
+ // settles it: out-of-range fields are normalized into a real instant, so a date that does not exist
53949
+ // comes back carrying different fields than it went in with. The three-argument setUTCFullYear sets
53950
+ // all three at once, which judges 29 February against the year given rather than a placeholder, and
53951
+ // leaves years 0 through 99 alone where Date.UTC would map them into the 1900s. The hour is checked
53952
+ // separately because it is not part of the round trip; RFC 3339 section 5.6 allows hours 00 through 23.
53953
+ function isRealCalendarDate(year, month, day, hour) {
53954
+ if (hour > 23) {
53955
+ return false;
53956
+ }
53957
+ var dt = new Date();
53958
+ dt.setUTCFullYear(year, month - 1, day);
53959
+ return dt.getUTCFullYear() === year && dt.getUTCMonth() === month - 1 && dt.getUTCDate() === day;
53960
+ }
53961
+
53962
+ function convertRfc3339ToUnixSeconds(v) {
53963
+ if (typeof v !== 'string') {
53964
+ return null;
53965
+ }
53966
+ var normalized = v.trim().toUpperCase();
53967
+ var fields = RFC3339_REGEX.exec(normalized);
53968
+ if (!fields) {
53969
+ return null;
53970
+ }
53971
+ if (!isRealCalendarDate(Number(fields[1]), Number(fields[2]), Number(fields[3]), Number(fields[4]))) {
53972
+ return null;
53973
+ }
53974
+ var parsed = new Date(normalized);
53975
+ var ms = parsed.getTime();
53976
+ if (isNaN(ms)) {
53977
+ return null;
53978
+ }
53979
+ return Math.floor(ms / 1000);
53980
+ }
53981
+
53982
+ function convertUnixMillisecondsToSeconds(v) {
53983
+ if (typeof v !== 'number' || !isFinite(v)) {
53984
+ return null;
53985
+ }
53986
+ // A value int64 cannot represent is not a real timestamp; treating one as a bound would let a
53987
+ // nonsense target define a rollout window.
53988
+ if (v >= MAX_EPOCH_MS || v <= -9223372036854776e3) {
53989
+ return null;
53990
+ }
53991
+ return truncate(v / 1000);
53992
+ }
53993
+
53994
+ function truncate(n) {
53995
+ return n < 0 ? Math.ceil(n) : Math.floor(n);
53996
+ }
53997
+
53998
+ // Register typed runtime-targeting operators (semver_compare, datetime_compare) into the JsonLogic engine.
53999
+ // Registration happens lazily, when the async targeting bundle loads.
54000
+ registerCustomOperators(mixpanel_module_jsonLogic);
54001
+
53699
54002
  /**
53700
54003
  * Check if an event matches the given criteria
53701
54004
  * @param {string} eventName - The name of the event being checked
@@ -55264,26 +55567,31 @@ FeatureFlagManager.prototype.getTargeting = function() {
55264
55567
  * When a match is found (event name matches and property filters pass), this method:
55265
55568
  * - Switches the flag to the pending variant
55266
55569
  * - Marks the event as activated for this session
55267
- * - Records the activation via the API (fire-and-forget)
55570
+ * - Records the activation via the API
55571
+ *
55572
+ * @returns {Promise} Resolves once the pending events have been processed and their recording
55573
+ * requests have settled. The promise never rejects, so callers that ignore it cannot produce an
55574
+ * unhandled rejection.
55268
55575
  */
55269
55576
  FeatureFlagManager.prototype.checkFirstTimeEvents = function(eventName, properties) {
55270
55577
  if (!this.pendingFirstTimeEvents || mixpanel_module_.isEmptyObject(this.pendingFirstTimeEvents)) {
55271
- return;
55578
+ return Promise.resolve();
55272
55579
  }
55273
55580
 
55274
55581
  // Check if targeting promise exists (either bundled or async loaded)
55275
55582
  if (mixpanel_module_win[TARGETING_GLOBAL_NAME] && mixpanel_module_.isFunction(mixpanel_module_win[TARGETING_GLOBAL_NAME].then)) {
55276
- mixpanel_module_win[TARGETING_GLOBAL_NAME].then(function(library) {
55277
- this._processFirstTimeEventCheck(eventName, properties, library);
55583
+ // The catch is part of the returned chain so the promise handed back always resolves.
55584
+ return mixpanel_module_win[TARGETING_GLOBAL_NAME].then(function(library) {
55585
+ return this._processFirstTimeEventCheck(eventName, properties, library);
55278
55586
  }.bind(this)).catch(function() {
55279
55587
  // If targeting failed to load, process with null
55280
55588
  // Events without property filters will still match
55281
- this._processFirstTimeEventCheck(eventName, properties, null);
55589
+ return this._processFirstTimeEventCheck(eventName, properties, null);
55282
55590
  }.bind(this));
55283
55591
  } else {
55284
55592
  // No targeting available, process with null
55285
55593
  // Events without property filters will still match
55286
- this._processFirstTimeEventCheck(eventName, properties, null);
55594
+ return this._processFirstTimeEventCheck(eventName, properties, null);
55287
55595
  }
55288
55596
  };
55289
55597
 
@@ -55292,8 +55600,10 @@ FeatureFlagManager.prototype.checkFirstTimeEvents = function(eventName, properti
55292
55600
  * @param {string} eventName - The name of the event being tracked
55293
55601
  * @param {Object} properties - Event properties to evaluate against property filters
55294
55602
  * @param {Object} targeting - The loaded targeting library
55603
+ * @returns {Promise} Resolves once every recording request started here has settled.
55295
55604
  */
55296
55605
  FeatureFlagManager.prototype._processFirstTimeEventCheck = function(eventName, properties, targeting) {
55606
+ var recordings = [];
55297
55607
  mixpanel_module_.each(this.pendingFirstTimeEvents, function(pendingEvent, eventKey) {
55298
55608
  if (this.activatedFirstTimeEvents[eventKey]) {
55299
55609
  return;
@@ -55350,12 +55660,13 @@ FeatureFlagManager.prototype._processFirstTimeEventCheck = function(eventName, p
55350
55660
  this.trackedFeatures.delete(flagKey);
55351
55661
  this.activatedFirstTimeEvents[eventKey] = true;
55352
55662
 
55353
- this.recordFirstTimeEvent(
55663
+ recordings.push(this.recordFirstTimeEvent(
55354
55664
  pendingEvent['flag_id'],
55355
55665
  pendingEvent['project_id'],
55356
55666
  pendingEvent['first_time_event_hash']
55357
- );
55667
+ ));
55358
55668
  }, this);
55669
+ return Promise.all(recordings);
55359
55670
  };
55360
55671
 
55361
55672
  FeatureFlagManager.prototype.getFirstTimeEventApiRoute = function(flagId) {
@@ -55381,8 +55692,9 @@ FeatureFlagManager.prototype.recordFirstTimeEvent = function(flagId, projectId,
55381
55692
 
55382
55693
  logger$1.log('Recording first-time event for flag: ' + flagId);
55383
55694
 
55384
- // Fire-and-forget POST request
55385
- this.fetch.call(mixpanel_module_win, url, {
55695
+ // The caller chains this so it can wait for the recording to settle. The catch below keeps the
55696
+ // returned promise resolved on failure, so a dropped request never rejects the chain.
55697
+ return this.fetch.call(mixpanel_module_win, url, {
55386
55698
  'method': 'POST',
55387
55699
  'headers': {
55388
55700
  'Content-Type': 'application/json',
@@ -55981,7 +56293,7 @@ DomTracker.prototype.track = function(query, event_name, properties, user_callba
55981
56293
  that.event_handler(e, this, options);
55982
56294
 
55983
56295
  // in case the mixpanel servers don't get back to us in time
55984
- window.setTimeout(that.track_callback(user_callback, props, options, true), timeout);
56296
+ mixpanel_module_win.setTimeout(that.track_callback(user_callback, props, options, true), timeout);
55985
56297
 
55986
56298
  // fire the tracking event
55987
56299
  that.mp.track(event_name, props, that.track_callback(user_callback, props, options));
@@ -56061,10 +56373,10 @@ LinkTracker.prototype.event_handler = function(evt, element, options) {
56061
56373
  };
56062
56374
 
56063
56375
  LinkTracker.prototype.after_track_handler = function(props, options) {
56064
- if (options.new_tab) { return; }
56376
+ if (options.new_tab || !options.href) { return; }
56065
56377
 
56066
56378
  setTimeout(function() {
56067
- window.location = options.href;
56379
+ mixpanel_module_win.location = options.href;
56068
56380
  }, 0);
56069
56381
  };
56070
56382
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shrfe/assets",
3
- "version": "1.0.63",
3
+ "version": "1.0.64",
4
4
  "description": "The assets used in SeamlessHR products",
5
5
  "author": "SeamlessHR LTD <oludayo@seamlesshr.com>",
6
6
  "license": "ISC",