blocfeed 0.19.0 → 0.20.0

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 CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.20.0 — 2026-05-07
4
+
5
+ ### Signal accuracy
6
+
7
+ - **rage-click now emits exactly one event per burst.** The previous behaviour fired an immediate `final: false` event at threshold-crossing and a follow-up `final: true` after the streak idled out, so a single rage produced two server-side rows the dashboard had to reconcile. The detector now emits a single event with `final: true` and the full `click_count` once the streak ends (`streakIdleMs`, default 1500). On `pagehide`, in-progress bursts that crossed the threshold are flushed via the same code path so we don't lose data when the user closes the tab mid-rage.
8
+
9
+ ### New: stable element keys
10
+
11
+ - New `stable_key: string | null` field on every `BehavioralEvent`. Built by walking up to four ancestors and emitting the first of `data-blocfeed-component` (→ `bf:component:<value>`), a `data-testid` family attribute (→ `bf:testid:<value>`), or `id` (→ `bf:id:<value>`). Lets the backend dedupe and aggregate events for the "same logical element" across re-renders even when the CSS selector path shifts.
12
+ - The `rage_click` and `dead_click` detectors now key their internal grouping maps on `stable_key ?? selector`, so bursts and rate-limit budgets follow the logical element, not its current selector path.
13
+ - New exported helper `buildStableElementKey(el, maxDepth?)` from `blocfeed/shared/dom`.
14
+
15
+ ---
16
+
3
17
  ## 0.19.0 — 2026-05-07
4
18
 
5
19
  ### Signal accuracy fixes