@flemo/devtools 0.6.0 → 0.7.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/dist/__tests__/swipeProbe.test.d.ts +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.mjs +367 -310
- package/dist/noop.d.ts +4 -0
- package/dist/noop.mjs +2 -2
- package/dist/swipeProbe.d.ts +52 -0
- package/package.json +6 -6
package/dist/noop.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { DevtoolsHudHandle, DevtoolsHudOptions } from './hud';
|
|
2
2
|
import { DevtoolsPanelHandle, DevtoolsPanelOptions } from './panel';
|
|
3
|
+
import { SwipeProbeHandle, SwipeProbeOptions } from './swipeProbe';
|
|
3
4
|
import { FlightRecorderHandle, FlightRecorderOptions } from './types';
|
|
4
5
|
export * from './anomalies';
|
|
5
6
|
export * from './blindSpots';
|
|
@@ -15,8 +16,11 @@ export declare const REPORT_SCHEMA_VERSION = "3";
|
|
|
15
16
|
export declare const attachFlightRecorder: (_options?: FlightRecorderOptions) => FlightRecorderHandle;
|
|
16
17
|
export declare const attachDevtoolsPanel: (_options?: DevtoolsPanelOptions) => DevtoolsPanelHandle;
|
|
17
18
|
export declare const attachDevtoolsHud: (_options?: DevtoolsHudOptions) => DevtoolsHudHandle;
|
|
19
|
+
export declare const SWIPE_PROBE_MS = 1200;
|
|
20
|
+
export declare const attachSwipeProbe: (_options?: SwipeProbeOptions) => SwipeProbeHandle;
|
|
18
21
|
export type { FlemoGlobal } from './recorder';
|
|
19
22
|
export type { DevtoolsHudHandle, DevtoolsHudOptions } from './hud';
|
|
20
23
|
export type { DevtoolsPanelHandle, DevtoolsPanelOptions } from './panel';
|
|
24
|
+
export type { SwipeProbeHandle, SwipeProbeOptions, SwipeReleaseAudit, SwipeSample } from './swipeProbe';
|
|
21
25
|
export type { DriverEvidence } from './frameProbe';
|
|
22
26
|
export type { BucketSummary, EnvironmentFingerprint, FlemoReport, FlightDriver, FlightHolds, FlightKind, FlightParticipants, FlightRecord, FlightRecorderHandle, FlightRecorderOptions, FlightTimestamp, FramePhaseStats, FrameSampleStats, ImageActivity, InputEvidence, LandingAudit, LongTaskSpan, MorphActivity, MotionProgress, ObservationCapabilities, OverridesSection, Precondition, PreconditionStatus, PreviousSession, TripwireHit, UaBrand } from './types';
|
package/dist/noop.mjs
CHANGED
|
@@ -637,6 +637,6 @@ var e = 30, t = 1e4, n = 50, r = 120, i = 100, a = 48, o = (e) => {
|
|
|
637
637
|
detach: Q,
|
|
638
638
|
report: ce,
|
|
639
639
|
mark: () => null
|
|
640
|
-
}), $ = (e) => ({ detach: Q }), ue = (e) => ({ detach: Q });
|
|
640
|
+
}), $ = (e) => ({ detach: Q }), ue = (e) => ({ detach: Q }), de = 1200, fe = (e) => ({ detach: Q });
|
|
641
641
|
//#endregion
|
|
642
|
-
export { c as BLIND_SPOTS, S as CORE_FLAGS, x as DEVTOOLS_OWNED_FLAGS, C as FLAG_REGISTRY, y as JUDGING_PROTOCOL, e as LONG_GAP_MS, j as MAX_PERSISTED_BYTES, A as MAX_PERSISTED_FLIGHTS, i as MID_FLIGHT_TASK_MS, n as OPENING_WINDOW_LEAD_MS, r as OPENING_WINDOW_TAIL_MS, b as PANEL_HEIGHT_KEY, se as REPORT_SCHEMA_VERSION, w as RETIRED_FLAGS, T as RETIRED_MARKER, a as STALL_MS, t as STUCK_STATUS_MS, k as TRACE_KEY, ue as attachDevtoolsHud, $ as attachDevtoolsPanel, le as attachFlightRecorder, v as captureEnvironment, Y as classifyDriver, P as clearTrace, J as computeFrameStats, q as computePhaseStats, o as deriveFlightAnomalies, O as deriveOverrideWarnings, G as derivePreconditions, s as deriveReportAnomalies, oe as deriveVerdict, f as detectEngine, g as developmentHints, p as isEmulationSuspected, X as kindFromStatus, F as loadTrace, ie as parseTranslateX, m as sampleRafCadence, N as saveTrace, ne as snapshotOverrides, u as summariseBuckets };
|
|
642
|
+
export { c as BLIND_SPOTS, S as CORE_FLAGS, x as DEVTOOLS_OWNED_FLAGS, C as FLAG_REGISTRY, y as JUDGING_PROTOCOL, e as LONG_GAP_MS, j as MAX_PERSISTED_BYTES, A as MAX_PERSISTED_FLIGHTS, i as MID_FLIGHT_TASK_MS, n as OPENING_WINDOW_LEAD_MS, r as OPENING_WINDOW_TAIL_MS, b as PANEL_HEIGHT_KEY, se as REPORT_SCHEMA_VERSION, w as RETIRED_FLAGS, T as RETIRED_MARKER, a as STALL_MS, t as STUCK_STATUS_MS, de as SWIPE_PROBE_MS, k as TRACE_KEY, ue as attachDevtoolsHud, $ as attachDevtoolsPanel, le as attachFlightRecorder, fe as attachSwipeProbe, v as captureEnvironment, Y as classifyDriver, P as clearTrace, J as computeFrameStats, q as computePhaseStats, o as deriveFlightAnomalies, O as deriveOverrideWarnings, G as derivePreconditions, s as deriveReportAnomalies, oe as deriveVerdict, f as detectEngine, g as developmentHints, p as isEmulationSuspected, X as kindFromStatus, F as loadTrace, ie as parseTranslateX, m as sampleRafCadence, N as saveTrace, ne as snapshotOverrides, u as summariseBuckets };
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/** How long after a release the probe keeps watching. Longer than any settle. */
|
|
2
|
+
export declare const SWIPE_PROBE_MS = 1200;
|
|
3
|
+
/** One screen's pose on one frame after a release. */
|
|
4
|
+
export interface SwipeSample {
|
|
5
|
+
/** Milliseconds since the release. */
|
|
6
|
+
readonly t: number;
|
|
7
|
+
/** Each screen's horizontal translate, in document order. */
|
|
8
|
+
readonly x: readonly number[];
|
|
9
|
+
/**
|
|
10
|
+
* The animations found on those screens, as `name|state|ct|rate`. An empty
|
|
11
|
+
* list is the finding, not a gap: nothing was driving the screens that frame.
|
|
12
|
+
*/
|
|
13
|
+
readonly animations: readonly string[];
|
|
14
|
+
}
|
|
15
|
+
export interface SwipeReleaseAudit {
|
|
16
|
+
/** Frames captured from the release onward. */
|
|
17
|
+
readonly samples: readonly SwipeSample[];
|
|
18
|
+
/** How far the furthest screen still had to travel when the finger left. */
|
|
19
|
+
readonly travelAtReleasePx: number;
|
|
20
|
+
/** The largest distance any screen covered between two frames. */
|
|
21
|
+
readonly biggestStepPx: number;
|
|
22
|
+
/** The mean of the first three steps, and of the last three. */
|
|
23
|
+
readonly openingStepPx: number;
|
|
24
|
+
readonly closingStepPx: number;
|
|
25
|
+
/**
|
|
26
|
+
* A landing decelerates: its closing frames are a fraction of its opening
|
|
27
|
+
* ones. A release handed back as a constant rate makes these equal, which is
|
|
28
|
+
* the defect this probe was built for and reads as no transition at all.
|
|
29
|
+
*/
|
|
30
|
+
readonly eased: boolean;
|
|
31
|
+
/** A release that put a screen home in one frame. */
|
|
32
|
+
readonly teleported: boolean;
|
|
33
|
+
}
|
|
34
|
+
export interface SwipeProbeOptions {
|
|
35
|
+
/** Called once the watch window closes, with what the release did. */
|
|
36
|
+
readonly onRelease: (audit: SwipeReleaseAudit) => void;
|
|
37
|
+
/** Test seam for the clock. */
|
|
38
|
+
readonly now?: () => number;
|
|
39
|
+
/** Test seam for the frame source. */
|
|
40
|
+
readonly schedule?: (run: () => void) => void;
|
|
41
|
+
}
|
|
42
|
+
export interface SwipeProbeHandle {
|
|
43
|
+
readonly detach: () => void;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Watch every pointer release and report what the screens did next.
|
|
47
|
+
*
|
|
48
|
+
* Passive and capture-phase, like the tripwires: it observes the gesture
|
|
49
|
+
* without taking part in it, and its loop starts at the release rather than
|
|
50
|
+
* running all the time.
|
|
51
|
+
*/
|
|
52
|
+
export declare const attachSwipeProbe: (options: SwipeProbeOptions) => SwipeProbeHandle;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@flemo/devtools",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Zero-config flight recorder, on-device readout and visual panel for flemo screen transitions: captures per-flight driver routing, frame pacing, long tasks, shared-element pairing, landing residues and judging preconditions into one JSON report readable by humans and coding agents.",
|
|
5
5
|
"main": "./dist/index.mjs",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -34,21 +34,21 @@
|
|
|
34
34
|
"homepage": "https://flemo.dev",
|
|
35
35
|
"license": "MIT",
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@flemo/core": "2.
|
|
37
|
+
"@flemo/core": "2.5.0",
|
|
38
38
|
"@flemo/eslint-config": "0.0.0",
|
|
39
39
|
"@flemo/tsconfig": "0.0.0",
|
|
40
40
|
"@testing-library/react": "^16.3.3",
|
|
41
41
|
"@types/node": "^24.13.1",
|
|
42
42
|
"@types/react": "^19.2.18",
|
|
43
|
-
"@vitest/coverage-v8": "^
|
|
43
|
+
"@vitest/coverage-v8": "^5.0.0",
|
|
44
44
|
"eslint": "^9.39.5",
|
|
45
|
-
"jsdom": "^
|
|
45
|
+
"jsdom": "^30.0.1",
|
|
46
46
|
"react": "^19.2.8",
|
|
47
47
|
"react-dom": "^19.2.8",
|
|
48
48
|
"typescript": "^6.0.3",
|
|
49
49
|
"vite": "^8.2.2",
|
|
50
|
-
"vite-plugin-dts": "^5.0
|
|
51
|
-
"vitest": "^
|
|
50
|
+
"vite-plugin-dts": "^5.1.0",
|
|
51
|
+
"vitest": "^5.0.0"
|
|
52
52
|
},
|
|
53
53
|
"publishConfig": {
|
|
54
54
|
"access": "public"
|