inspector-ng 0.0.10 → 0.0.12
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/README.md +5 -17
- package/esm2022/lib/checkpoint-search.mjs +4 -6
- package/esm2022/lib/checkpoints.mjs +25 -8
- package/esm2022/lib/inspector.component.mjs +139 -101
- package/esm2022/lib/utils.mjs +32 -1
- package/fesm2022/inspector-ng.mjs +194 -111
- package/fesm2022/inspector-ng.mjs.map +1 -1
- package/lib/checkpoints.d.ts +3 -0
- package/lib/inspector.component.d.ts +22 -6
- package/lib/utils.d.ts +2 -0
- package/package.json +1 -1
package/lib/checkpoints.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ export interface InspectorCheckpointRecord {
|
|
|
8
8
|
name: string;
|
|
9
9
|
route: string;
|
|
10
10
|
createdAt: string;
|
|
11
|
+
lastUsedAt?: string;
|
|
11
12
|
state: unknown;
|
|
12
13
|
}
|
|
13
14
|
export declare const INSPECTOR_CHECKPOINT_REPOSITORY: InjectionToken<InspectorCheckpointRepository>;
|
|
@@ -56,3 +57,5 @@ export declare class InspectorCheckpointService {
|
|
|
56
57
|
}
|
|
57
58
|
export declare function provideInspectorCheckpoints(): EnvironmentProviders;
|
|
58
59
|
export declare function nextAutomaticName(route: string, names: string[]): string;
|
|
60
|
+
export declare function checkpointActivityAt(checkpoint: InspectorCheckpointRecord): string;
|
|
61
|
+
export declare function recentActivityFirst(a: InspectorCheckpointRecord, b: InspectorCheckpointRecord): number;
|
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import { ElementRef, OnDestroy } from '@angular/core';
|
|
2
2
|
import { DistanceOverlay, Guide, GuideOrientation, InspectMeasurement, Rect, TextBlockAnnotation, ToolMode } from './types';
|
|
3
|
-
import { InspectorCheckpointRecord, InspectorCheckpointService } from './checkpoints';
|
|
3
|
+
import { checkpointActivityAt, InspectorCheckpointRecord, InspectorCheckpointService } from './checkpoints';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
|
+
type InspectorCommandActionId = 'select' | 'type' | 'save' | 'vertical' | 'horizontal' | 'off';
|
|
6
|
+
interface InspectorCommandAction {
|
|
7
|
+
readonly id: InspectorCommandActionId;
|
|
8
|
+
readonly label: string;
|
|
9
|
+
readonly ariaLabel: string;
|
|
10
|
+
readonly keywords: string;
|
|
11
|
+
}
|
|
5
12
|
export declare class inspectorComponent implements OnDestroy {
|
|
6
13
|
readonly Math: Math;
|
|
14
|
+
readonly checkpointActivityAt: typeof checkpointActivityAt;
|
|
7
15
|
readonly formatValue: (value: number) => number;
|
|
16
|
+
readonly formatRelativeTime: (iso: string, now?: number) => string;
|
|
8
17
|
readonly guideHitboxSize = 14;
|
|
9
18
|
readonly overlayRoot: import("@angular/core").Signal<ElementRef<HTMLElement> | undefined>;
|
|
10
19
|
readonly checkpointDialog: import("@angular/core").Signal<ElementRef<HTMLDialogElement> | undefined>;
|
|
@@ -16,13 +25,16 @@ export declare class inspectorComponent implements OnDestroy {
|
|
|
16
25
|
readonly checkpointService: InspectorCheckpointService | null;
|
|
17
26
|
readonly commandBarOpen: import("@angular/core").WritableSignal<boolean>;
|
|
18
27
|
readonly checkpointQuery: import("@angular/core").WritableSignal<string>;
|
|
19
|
-
readonly
|
|
28
|
+
readonly activeCommandIndex: import("@angular/core").WritableSignal<number>;
|
|
20
29
|
readonly editingCheckpointId: import("@angular/core").WritableSignal<string | null>;
|
|
21
30
|
readonly deletingCheckpointId: import("@angular/core").WritableSignal<string | null>;
|
|
22
31
|
readonly renameDraft: import("@angular/core").WritableSignal<string>;
|
|
23
32
|
readonly checkpointToast: import("@angular/core").WritableSignal<string | null>;
|
|
24
33
|
readonly checkpointToastIsError: import("@angular/core").WritableSignal<boolean>;
|
|
25
34
|
readonly filteredCheckpoints: import("@angular/core").Signal<InspectorCheckpointRecord[]>;
|
|
35
|
+
readonly filteredInspectorActions: import("@angular/core").Signal<readonly InspectorCommandAction[]>;
|
|
36
|
+
readonly commandResultCount: import("@angular/core").Signal<number>;
|
|
37
|
+
readonly activeCommandResultId: import("@angular/core").Signal<string | null>;
|
|
26
38
|
readonly enabled: import("@angular/core").WritableSignal<boolean>;
|
|
27
39
|
readonly toolMode: import("@angular/core").WritableSignal<ToolMode>;
|
|
28
40
|
readonly guideOrientation: import("@angular/core").WritableSignal<GuideOrientation>;
|
|
@@ -60,6 +72,9 @@ export declare class inspectorComponent implements OnDestroy {
|
|
|
60
72
|
closeCheckpointCommandBar(): void;
|
|
61
73
|
updateCheckpointQuery(event: Event): void;
|
|
62
74
|
setActiveCheckpoint(index: number): void;
|
|
75
|
+
shouldShowCheckpointRoute(checkpoint: InspectorCheckpointRecord): boolean;
|
|
76
|
+
setActiveInspectorAction(index: number): void;
|
|
77
|
+
executeInspectorAction(action: InspectorCommandAction): Promise<void>;
|
|
63
78
|
restoreCheckpoint(checkpoint: InspectorCheckpointRecord): Promise<void>;
|
|
64
79
|
beginRename(checkpoint: InspectorCheckpointRecord, event?: Event): void;
|
|
65
80
|
updateRenameDraft(event: Event): void;
|
|
@@ -77,7 +92,8 @@ export declare class inspectorComponent implements OnDestroy {
|
|
|
77
92
|
formatEdges(edges: InspectMeasurement['padding']): string;
|
|
78
93
|
formatGap(selected: InspectMeasurement): string;
|
|
79
94
|
handleKeydown(event: KeyboardEvent): void;
|
|
80
|
-
|
|
95
|
+
private clearInspectorCanvas;
|
|
96
|
+
private normalizeCheckpointLabel;
|
|
81
97
|
handlePointerMove(event: PointerEvent): void;
|
|
82
98
|
handlePointerUp(): void;
|
|
83
99
|
handleClick(event: MouseEvent): void;
|
|
@@ -85,9 +101,8 @@ export declare class inspectorComponent implements OnDestroy {
|
|
|
85
101
|
private canInspectClick;
|
|
86
102
|
private setInspectorEnabled;
|
|
87
103
|
private handleCommandBarKeydown;
|
|
88
|
-
private
|
|
89
|
-
private
|
|
90
|
-
private scrollActiveCheckpointIntoView;
|
|
104
|
+
private clampActiveCommand;
|
|
105
|
+
private scrollActiveCommandIntoView;
|
|
91
106
|
private showCheckpointToast;
|
|
92
107
|
private selectElementAtPoint;
|
|
93
108
|
private updateDistanceOverlay;
|
|
@@ -104,3 +119,4 @@ export declare class inspectorComponent implements OnDestroy {
|
|
|
104
119
|
static ɵfac: i0.ɵɵFactoryDeclaration<inspectorComponent, never>;
|
|
105
120
|
static ɵcmp: i0.ɵɵComponentDeclaration<inspectorComponent, "inspector-overlay", never, { "highlightColor": { "alias": "highlightColor"; "required": false; }; "guideColor": { "alias": "guideColor"; "required": false; }; "hoverHighlightEnabled": { "alias": "hoverHighlightEnabled"; "required": false; }; "persistOnReload": { "alias": "persistOnReload"; "required": false; }; }, {}, never, never, true, never>;
|
|
106
121
|
}
|
|
122
|
+
export {};
|
package/lib/utils.d.ts
CHANGED