@treelocator/runtime 0.4.0 → 0.4.1

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.
@@ -493,11 +493,10 @@ export function createDejitterRecorder() {
493
493
  }
494
494
  return findings;
495
495
  }
496
- function detectShiverFindings(propStats, elements, existingFindings) {
496
+ function detectShiverFindings(propStats, elements) {
497
497
  const findings = [];
498
498
  for (const p of propStats.props) {
499
499
  if (p.raw < 10) continue;
500
- if (existingFindings.some(f => f.elem === p.elem && f.prop === p.prop)) continue;
501
500
  const timeline = getTimeline(p.elem, p.prop);
502
501
  if (timeline.length < 10) continue;
503
502
  const numeric = [];
@@ -539,11 +538,10 @@ export function createDejitterRecorder() {
539
538
  }
540
539
  return findings;
541
540
  }
542
- function detectJumpFindings(propStats, elements, existingFindings) {
541
+ function detectJumpFindings(propStats, elements) {
543
542
  const findings = [];
544
543
  for (const p of propStats.props) {
545
544
  if (p.raw < 3) continue;
546
- if (existingFindings.some(f => f.elem === p.elem && f.prop === p.prop)) continue;
547
545
  const timeline = getTimeline(p.elem, p.prop);
548
546
  if (timeline.length < 3) continue;
549
547
  const deltas = [];
@@ -581,12 +579,11 @@ export function createDejitterRecorder() {
581
579
  }
582
580
  return findings;
583
581
  }
584
- function detectStutterFindings(propStats, elements, existingFindings) {
582
+ function detectStutterFindings(propStats, elements) {
585
583
  const findings = [];
586
584
  const st = config.thresholds.stutter;
587
585
  for (const p of propStats.props) {
588
586
  if (p.raw < 6) continue;
589
- if (existingFindings.some(f => f.elem === p.elem && f.prop === p.prop)) continue;
590
587
  const timeline = getTimeline(p.elem, p.prop);
591
588
  if (timeline.length < 6) continue;
592
589
  const numeric = [];
@@ -672,12 +669,11 @@ export function createDejitterRecorder() {
672
669
  }
673
670
  return findings;
674
671
  }
675
- function detectStuckFindings(propStats, elements, existingFindings) {
672
+ function detectStuckFindings(propStats, elements) {
676
673
  const findings = [];
677
674
  const sk = config.thresholds.stuck;
678
675
  for (const p of propStats.props) {
679
676
  if (p.raw < 6) continue;
680
- if (existingFindings.some(f => f.elem === p.elem && f.prop === p.prop)) continue;
681
677
  const timeline = getTimeline(p.elem, p.prop);
682
678
  if (timeline.length < 6) continue;
683
679
  const numeric = [];
@@ -770,10 +766,10 @@ export function createDejitterRecorder() {
770
766
  const propStats = buildPropStats();
771
767
  const elements = buildElementMap();
772
768
  let findings = detectOutlierFindings(propStats, elements);
773
- findings = findings.concat(detectShiverFindings(propStats, elements, findings));
774
- findings = findings.concat(detectJumpFindings(propStats, elements, findings));
775
- findings = findings.concat(detectStutterFindings(propStats, elements, findings));
776
- findings = findings.concat(detectStuckFindings(propStats, elements, findings));
769
+ findings = findings.concat(detectShiverFindings(propStats, elements));
770
+ findings = findings.concat(detectJumpFindings(propStats, elements));
771
+ findings = findings.concat(detectStutterFindings(propStats, elements));
772
+ findings = findings.concat(detectStuckFindings(propStats, elements));
777
773
  findings = deduplicateShivers(findings);
778
774
  const sevOrder = {
779
775
  high: 0,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@treelocator/runtime",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "TreeLocatorJS runtime for component ancestry tracking. Alt+click any element to copy its component tree to clipboard. Exposes window.__treelocator__ API for browser automation (Playwright, Puppeteer, Selenium, Cypress).",
5
5
  "keywords": [
6
6
  "locator",
@@ -485,12 +485,11 @@ export function createDejitterRecorder(): DejitterAPI {
485
485
  return findings;
486
486
  }
487
487
 
488
- function detectShiverFindings(propStats: any, elements: any, existingFindings: DejitterFinding[]): DejitterFinding[] {
488
+ function detectShiverFindings(propStats: any, elements: any): DejitterFinding[] {
489
489
  const findings: DejitterFinding[] = [];
490
490
 
491
491
  for (const p of propStats.props) {
492
492
  if (p.raw < 10) continue;
493
- if (existingFindings.some((f) => f.elem === p.elem && f.prop === p.prop)) continue;
494
493
 
495
494
  const timeline = getTimeline(p.elem, p.prop);
496
495
  if (timeline.length < 10) continue;
@@ -542,12 +541,11 @@ export function createDejitterRecorder(): DejitterAPI {
542
541
  return findings;
543
542
  }
544
543
 
545
- function detectJumpFindings(propStats: any, elements: any, existingFindings: DejitterFinding[]): DejitterFinding[] {
544
+ function detectJumpFindings(propStats: any, elements: any): DejitterFinding[] {
546
545
  const findings: DejitterFinding[] = [];
547
546
 
548
547
  for (const p of propStats.props) {
549
548
  if (p.raw < 3) continue;
550
- if (existingFindings.some((f) => f.elem === p.elem && f.prop === p.prop)) continue;
551
549
 
552
550
  const timeline = getTimeline(p.elem, p.prop);
553
551
  if (timeline.length < 3) continue;
@@ -598,13 +596,12 @@ export function createDejitterRecorder(): DejitterAPI {
598
596
  return findings;
599
597
  }
600
598
 
601
- function detectStutterFindings(propStats: any, elements: any, existingFindings: DejitterFinding[]): DejitterFinding[] {
599
+ function detectStutterFindings(propStats: any, elements: any): DejitterFinding[] {
602
600
  const findings: DejitterFinding[] = [];
603
601
  const st = config.thresholds.stutter;
604
602
 
605
603
  for (const p of propStats.props) {
606
604
  if (p.raw < 6) continue;
607
- if (existingFindings.some((f) => f.elem === p.elem && f.prop === p.prop)) continue;
608
605
 
609
606
  const timeline = getTimeline(p.elem, p.prop);
610
607
  if (timeline.length < 6) continue;
@@ -701,13 +698,12 @@ export function createDejitterRecorder(): DejitterAPI {
701
698
  return findings;
702
699
  }
703
700
 
704
- function detectStuckFindings(propStats: any, elements: any, existingFindings: DejitterFinding[]): DejitterFinding[] {
701
+ function detectStuckFindings(propStats: any, elements: any): DejitterFinding[] {
705
702
  const findings: DejitterFinding[] = [];
706
703
  const sk = config.thresholds.stuck;
707
704
 
708
705
  for (const p of propStats.props) {
709
706
  if (p.raw < 6) continue;
710
- if (existingFindings.some((f) => f.elem === p.elem && f.prop === p.prop)) continue;
711
707
 
712
708
  const timeline = getTimeline(p.elem, p.prop);
713
709
  if (timeline.length < 6) continue;
@@ -815,10 +811,10 @@ export function createDejitterRecorder(): DejitterAPI {
815
811
  const elements = buildElementMap();
816
812
 
817
813
  let findings = detectOutlierFindings(propStats, elements);
818
- findings = findings.concat(detectShiverFindings(propStats, elements, findings));
819
- findings = findings.concat(detectJumpFindings(propStats, elements, findings));
820
- findings = findings.concat(detectStutterFindings(propStats, elements, findings));
821
- findings = findings.concat(detectStuckFindings(propStats, elements, findings));
814
+ findings = findings.concat(detectShiverFindings(propStats, elements));
815
+ findings = findings.concat(detectJumpFindings(propStats, elements));
816
+ findings = findings.concat(detectStutterFindings(propStats, elements));
817
+ findings = findings.concat(detectStuckFindings(propStats, elements));
822
818
  findings = deduplicateShivers(findings);
823
819
 
824
820
  const sevOrder: Record<string, number> = { high: 0, medium: 1, low: 2, info: 3 };