@paulirish/trace_engine 0.0.12 → 0.0.14
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/core/platform/{array-utilities.js → ArrayUtilities.js} +1 -1
- package/core/platform/ArrayUtilities.js.map +1 -0
- package/core/platform/{brand.js → Brand.js} +1 -1
- package/core/platform/{brand.js.map → Brand.js.map} +1 -1
- package/core/platform/{dom-utilities.js → DOMUtilities.js} +1 -1
- package/core/platform/DOMUtilities.js.map +1 -0
- package/core/platform/{date-utilities.js → DateUtilities.js} +1 -1
- package/core/platform/DateUtilities.js.map +1 -0
- package/core/platform/DevToolsPath.d.ts +1 -1
- package/core/platform/DevToolsPath.js.map +1 -1
- package/core/platform/{keyboard-utilities.js → KeyboardUtilities.js} +1 -1
- package/core/platform/KeyboardUtilities.js.map +1 -0
- package/core/platform/{map-utilities.js → MapUtilities.js} +1 -1
- package/core/platform/MapUtilities.js.map +1 -0
- package/core/platform/{number-utilities.js → NumberUtilities.js} +1 -1
- package/core/platform/NumberUtilities.js.map +1 -0
- package/core/platform/{promise-utilities.js → PromiseUtilities.js} +1 -1
- package/core/platform/PromiseUtilities.js.map +1 -0
- package/core/platform/{set-utilities.js → SetUtilities.js} +1 -1
- package/core/platform/SetUtilities.js.map +1 -0
- package/core/platform/{string-utilities.js → StringUtilities.js} +4 -4
- package/core/platform/StringUtilities.js.map +1 -0
- package/core/platform/Timing.d.ts +1 -1
- package/core/platform/Timing.js.map +1 -1
- package/core/platform/{typescript-utilities.js → TypescriptUtilities.js} +1 -1
- package/core/platform/TypescriptUtilities.js.map +1 -0
- package/core/platform/UIString.d.ts +1 -1
- package/core/platform/UIString.js.map +1 -1
- package/core/platform/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/core/platform/platform-tsconfig.json +12 -18
- package/core/platform/platform.d.ts +12 -13
- package/core/platform/platform.js +16 -17
- package/core/platform/platform.js.map +1 -1
- package/generated/protocol.d.ts +90 -29
- package/models/cpu_profile/cpu_profile-tsconfig.json +1 -2
- package/models/cpu_profile/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/EntriesFilter.d.ts +4 -0
- package/models/trace/EntriesFilter.js +29 -6
- package/models/trace/EntriesFilter.js.map +1 -1
- package/models/trace/ModelImpl.d.ts +3 -0
- package/models/trace/ModelImpl.js +10 -2
- package/models/trace/ModelImpl.js.map +1 -1
- package/models/trace/Processor.d.ts +3 -1
- package/models/trace/Processor.js +50 -5
- package/models/trace/Processor.js.map +1 -1
- package/models/trace/TracingManager.js.map +1 -1
- package/models/trace/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/extras/FetchNodes.d.ts +10 -3
- package/models/trace/extras/FetchNodes.js +14 -1
- package/models/trace/extras/FetchNodes.js.map +1 -1
- package/models/trace/extras/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/extras/extras-tsconfig.json +1 -2
- package/models/trace/handlers/NetworkRequestsHandler.js +5 -0
- package/models/trace/handlers/NetworkRequestsHandler.js.map +1 -1
- package/models/trace/handlers/RendererHandler.js +2 -1
- package/models/trace/handlers/RendererHandler.js.map +1 -1
- package/models/trace/handlers/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/handlers/handlers-tsconfig.json +1 -2
- package/models/trace/helpers/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/helpers/helpers-tsconfig.json +1 -2
- package/models/trace/insights/InsightRunners.d.ts +1 -0
- package/models/trace/insights/InsightRunners.js +5 -0
- package/models/trace/insights/InsightRunners.js.map +1 -0
- package/models/trace/insights/RenderBlocking.d.ts +6 -0
- package/models/trace/insights/RenderBlocking.js +42 -0
- package/models/trace/insights/RenderBlocking.js.map +1 -0
- package/models/trace/insights/bundle-tsconfig.json +1 -0
- package/models/trace/insights/devtools_entrypoint-bundle-typescript-tsconfig.json +43 -0
- package/models/trace/insights/insights-tsconfig.json +45 -0
- package/models/trace/insights/insights.d.ts +2 -0
- package/models/trace/insights/insights.js +6 -0
- package/models/trace/insights/insights.js.map +1 -0
- package/models/trace/insights/types.d.ts +45 -0
- package/models/trace/insights/types.js +8 -0
- package/models/trace/insights/types.js.map +1 -0
- package/models/trace/root-causes/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/root-causes/root-causes-tsconfig.json +1 -2
- package/models/trace/trace-tsconfig.json +4 -2
- package/models/trace/trace.d.ts +2 -1
- package/models/trace/trace.js +2 -1
- package/models/trace/trace.js.map +1 -1
- package/models/trace/types/Timing.js +0 -3
- package/models/trace/types/Timing.js.map +1 -1
- package/models/trace/types/TraceEvents.d.ts +24 -0
- package/models/trace/types/TraceEvents.js.map +1 -1
- package/models/trace/types/devtools_entrypoint-bundle-typescript-tsconfig.json +1 -2
- package/models/trace/types/types-tsconfig.json +1 -2
- package/package.json +6 -8
- package/LICENSE +0 -27
- package/PAUL.readme.md +0 -5
- package/README.md +0 -156
- package/analyze-trace.mjs +0 -184
- package/core/platform/array-utilities.js.map +0 -1
- package/core/platform/date-utilities.js.map +0 -1
- package/core/platform/dcheck-tsconfig.json +0 -8
- package/core/platform/dcheck.d.ts +0 -4
- package/core/platform/dcheck.js +0 -5
- package/core/platform/dom-utilities.js.map +0 -1
- package/core/platform/keyboard-utilities.js.map +0 -1
- package/core/platform/map-utilities.js.map +0 -1
- package/core/platform/number-utilities.js.map +0 -1
- package/core/platform/promise-utilities.js.map +0 -1
- package/core/platform/set-utilities.js.map +0 -1
- package/core/platform/string-utilities.js.map +0 -1
- package/core/platform/typescript-utilities.js.map +0 -1
- package/test/invalid-animation-events.json.gz +0 -0
- package/test/test-trace-engine.mjs +0 -52
- /package/core/platform/{array-utilities.d.ts → ArrayUtilities.d.ts} +0 -0
- /package/core/platform/{brand.d.ts → Brand.d.ts} +0 -0
- /package/core/platform/{dom-utilities.d.ts → DOMUtilities.d.ts} +0 -0
- /package/core/platform/{date-utilities.d.ts → DateUtilities.d.ts} +0 -0
- /package/core/platform/{keyboard-utilities.d.ts → KeyboardUtilities.d.ts} +0 -0
- /package/core/platform/{map-utilities.d.ts → MapUtilities.d.ts} +0 -0
- /package/core/platform/{number-utilities.d.ts → NumberUtilities.d.ts} +0 -0
- /package/core/platform/{promise-utilities.d.ts → PromiseUtilities.d.ts} +0 -0
- /package/core/platform/{set-utilities.d.ts → SetUtilities.d.ts} +0 -0
- /package/core/platform/{string-utilities.d.ts → StringUtilities.d.ts} +0 -0
- /package/core/platform/{typescript-utilities.d.ts → TypescriptUtilities.d.ts} +0 -0
package/generated/protocol.d.ts
CHANGED
|
@@ -293,7 +293,7 @@ export declare namespace Accessibility {
|
|
|
293
293
|
depth?: integer;
|
|
294
294
|
/**
|
|
295
295
|
* The frame for whose document the AX tree should be retrieved.
|
|
296
|
-
* If
|
|
296
|
+
* If omitted, the root frame is used.
|
|
297
297
|
*/
|
|
298
298
|
frameId?: Page.FrameId;
|
|
299
299
|
}
|
|
@@ -928,7 +928,12 @@ export declare namespace Audits {
|
|
|
928
928
|
InvalidRegisterOsTriggerHeader = "InvalidRegisterOsTriggerHeader",
|
|
929
929
|
WebAndOsHeaders = "WebAndOsHeaders",
|
|
930
930
|
NoWebOrOsSupport = "NoWebOrOsSupport",
|
|
931
|
-
NavigationRegistrationWithoutTransientUserActivation = "NavigationRegistrationWithoutTransientUserActivation"
|
|
931
|
+
NavigationRegistrationWithoutTransientUserActivation = "NavigationRegistrationWithoutTransientUserActivation",
|
|
932
|
+
InvalidInfoHeader = "InvalidInfoHeader",
|
|
933
|
+
NoRegisterSourceHeader = "NoRegisterSourceHeader",
|
|
934
|
+
NoRegisterTriggerHeader = "NoRegisterTriggerHeader",
|
|
935
|
+
NoRegisterOsSourceHeader = "NoRegisterOsSourceHeader",
|
|
936
|
+
NoRegisterOsTriggerHeader = "NoRegisterOsTriggerHeader"
|
|
932
937
|
}
|
|
933
938
|
/**
|
|
934
939
|
* Details for issues around "Attribution Reporting API" usage.
|
|
@@ -1334,7 +1339,7 @@ export declare namespace Autofill {
|
|
|
1334
1339
|
*/
|
|
1335
1340
|
interface AddressUI {
|
|
1336
1341
|
/**
|
|
1337
|
-
* A two dimension array containing the
|
|
1342
|
+
* A two dimension array containing the representation of values from an address profile.
|
|
1338
1343
|
*/
|
|
1339
1344
|
addressFields: AddressFields[];
|
|
1340
1345
|
}
|
|
@@ -1370,6 +1375,10 @@ export declare namespace Autofill {
|
|
|
1370
1375
|
* The filling strategy
|
|
1371
1376
|
*/
|
|
1372
1377
|
fillingStrategy: FillingStrategy;
|
|
1378
|
+
/**
|
|
1379
|
+
* The frame the field belongs to
|
|
1380
|
+
*/
|
|
1381
|
+
frameId: Page.FrameId;
|
|
1373
1382
|
/**
|
|
1374
1383
|
* The form field's DOM node
|
|
1375
1384
|
*/
|
|
@@ -1556,6 +1565,7 @@ export declare namespace Browser {
|
|
|
1556
1565
|
ProtectedMediaIdentifier = "protectedMediaIdentifier",
|
|
1557
1566
|
Sensors = "sensors",
|
|
1558
1567
|
StorageAccess = "storageAccess",
|
|
1568
|
+
SpeakerSelection = "speakerSelection",
|
|
1559
1569
|
TopLevelStorageAccess = "topLevelStorageAccess",
|
|
1560
1570
|
VideoCapture = "videoCapture",
|
|
1561
1571
|
VideoCapturePanTiltZoom = "videoCapturePanTiltZoom",
|
|
@@ -1686,7 +1696,7 @@ export declare namespace Browser {
|
|
|
1686
1696
|
/**
|
|
1687
1697
|
* Whether to allow all or deny all download requests, or use default Chrome behavior if
|
|
1688
1698
|
* available (otherwise deny). |allowAndName| allows download and names files according to
|
|
1689
|
-
* their
|
|
1699
|
+
* their download guids.
|
|
1690
1700
|
*/
|
|
1691
1701
|
behavior: SetDownloadBehaviorRequestBehavior;
|
|
1692
1702
|
/**
|
|
@@ -2013,7 +2023,7 @@ export declare namespace CSS {
|
|
|
2013
2023
|
frameId: Page.FrameId;
|
|
2014
2024
|
/**
|
|
2015
2025
|
* Stylesheet resource URL. Empty if this is a constructed stylesheet created using
|
|
2016
|
-
* new CSSStyleSheet() (but non-empty if this is a constructed
|
|
2026
|
+
* new CSSStyleSheet() (but non-empty if this is a constructed stylesheet imported
|
|
2017
2027
|
* as a CSS module script).
|
|
2018
2028
|
*/
|
|
2019
2029
|
sourceURL: string;
|
|
@@ -3720,7 +3730,7 @@ export declare namespace DOM {
|
|
|
3720
3730
|
}
|
|
3721
3731
|
interface GetAttributesRequest {
|
|
3722
3732
|
/**
|
|
3723
|
-
* Id of the node to retrieve
|
|
3733
|
+
* Id of the node to retrieve attributes for.
|
|
3724
3734
|
*/
|
|
3725
3735
|
nodeId: NodeId;
|
|
3726
3736
|
}
|
|
@@ -5305,14 +5315,14 @@ export declare namespace Emulation {
|
|
|
5305
5315
|
PauseIfNetworkFetchesPending = "pauseIfNetworkFetchesPending"
|
|
5306
5316
|
}
|
|
5307
5317
|
/**
|
|
5308
|
-
* Used to specify User Agent
|
|
5318
|
+
* Used to specify User Agent Client Hints to emulate. See https://wicg.github.io/ua-client-hints
|
|
5309
5319
|
*/
|
|
5310
5320
|
interface UserAgentBrandVersion {
|
|
5311
5321
|
brand: string;
|
|
5312
5322
|
version: string;
|
|
5313
5323
|
}
|
|
5314
5324
|
/**
|
|
5315
|
-
* Used to specify User Agent
|
|
5325
|
+
* Used to specify User Agent Client Hints to emulate. See https://wicg.github.io/ua-client-hints
|
|
5316
5326
|
* Missing optional values will be filled in by the target with what it would normally use.
|
|
5317
5327
|
*/
|
|
5318
5328
|
interface UserAgentMetadata {
|
|
@@ -5624,8 +5634,9 @@ export declare namespace Emulation {
|
|
|
5624
5634
|
}
|
|
5625
5635
|
interface SetTimezoneOverrideRequest {
|
|
5626
5636
|
/**
|
|
5627
|
-
* The timezone identifier.
|
|
5628
|
-
*
|
|
5637
|
+
* The timezone identifier. List of supported timezones:
|
|
5638
|
+
* https://source.chromium.org/chromium/chromium/deps/icu.git/+/faee8bc70570192d82d2978a71e2a615788597d1:source/data/misc/metaZones.txt
|
|
5639
|
+
* If empty, disables the override and restores default host system timezone.
|
|
5629
5640
|
*/
|
|
5630
5641
|
timezoneId: string;
|
|
5631
5642
|
}
|
|
@@ -5759,7 +5770,7 @@ export declare namespace IO {
|
|
|
5759
5770
|
*/
|
|
5760
5771
|
handle: StreamHandle;
|
|
5761
5772
|
/**
|
|
5762
|
-
* Seek to the specified offset before reading (if not
|
|
5773
|
+
* Seek to the specified offset before reading (if not specified, proceed with offset
|
|
5763
5774
|
* following the last read). Some types of streams may only support sequential reads.
|
|
5764
5775
|
*/
|
|
5765
5776
|
offset?: integer;
|
|
@@ -6903,7 +6914,7 @@ export declare namespace LayerTree {
|
|
|
6903
6914
|
}
|
|
6904
6915
|
interface LayerTreeDidChangeEvent {
|
|
6905
6916
|
/**
|
|
6906
|
-
* Layer tree, absent if not in the
|
|
6917
|
+
* Layer tree, absent if not in the compositing mode.
|
|
6907
6918
|
*/
|
|
6908
6919
|
layers?: Layer[];
|
|
6909
6920
|
}
|
|
@@ -7389,7 +7400,7 @@ export declare namespace Network {
|
|
|
7389
7400
|
trustTokenParams?: TrustTokenParams;
|
|
7390
7401
|
/**
|
|
7391
7402
|
* True if this resource request is considered to be the 'same site' as the
|
|
7392
|
-
* request
|
|
7403
|
+
* request corresponding to the main frame.
|
|
7393
7404
|
*/
|
|
7394
7405
|
isSameSite?: boolean;
|
|
7395
7406
|
}
|
|
@@ -7615,8 +7626,18 @@ export declare namespace Network {
|
|
|
7615
7626
|
DnsAlpnH3JobWonRace = "dnsAlpnH3JobWonRace",
|
|
7616
7627
|
UnspecifiedReason = "unspecifiedReason"
|
|
7617
7628
|
}
|
|
7629
|
+
/**
|
|
7630
|
+
* Source of service worker router.
|
|
7631
|
+
*/
|
|
7632
|
+
const enum ServiceWorkerRouterSource {
|
|
7633
|
+
Network = "network",
|
|
7634
|
+
Cache = "cache",
|
|
7635
|
+
FetchEvent = "fetch-event",
|
|
7636
|
+
RaceNetworkAndFetchHandler = "race-network-and-fetch-handler"
|
|
7637
|
+
}
|
|
7618
7638
|
interface ServiceWorkerRouterInfo {
|
|
7619
7639
|
ruleIdMatched: integer;
|
|
7640
|
+
matchedSourceType: ServiceWorkerRouterSource;
|
|
7620
7641
|
}
|
|
7621
7642
|
/**
|
|
7622
7643
|
* HTTP response data.
|
|
@@ -7687,7 +7708,7 @@ export declare namespace Network {
|
|
|
7687
7708
|
*/
|
|
7688
7709
|
fromPrefetchCache?: boolean;
|
|
7689
7710
|
/**
|
|
7690
|
-
*
|
|
7711
|
+
* Information about how Service Worker Static Router was used.
|
|
7691
7712
|
*/
|
|
7692
7713
|
serviceWorkerRouterInfo?: ServiceWorkerRouterInfo;
|
|
7693
7714
|
/**
|
|
@@ -8287,7 +8308,7 @@ export declare namespace Network {
|
|
|
8287
8308
|
*/
|
|
8288
8309
|
securityDetails?: SecurityDetails;
|
|
8289
8310
|
/**
|
|
8290
|
-
* Errors occurred while handling the signed
|
|
8311
|
+
* Errors occurred while handling the signed exchange.
|
|
8291
8312
|
*/
|
|
8292
8313
|
errors?: SignedExchangeError[];
|
|
8293
8314
|
}
|
|
@@ -8917,7 +8938,7 @@ export declare namespace Network {
|
|
|
8917
8938
|
*/
|
|
8918
8939
|
type: ResourceType;
|
|
8919
8940
|
/**
|
|
8920
|
-
*
|
|
8941
|
+
* Error message. List of network errors: https://cs.chromium.org/chromium/src/net/base/net_error_list.h
|
|
8921
8942
|
*/
|
|
8922
8943
|
errorText: string;
|
|
8923
8944
|
/**
|
|
@@ -9379,7 +9400,7 @@ export declare namespace Network {
|
|
|
9379
9400
|
*/
|
|
9380
9401
|
cookiePartitionKey?: string;
|
|
9381
9402
|
/**
|
|
9382
|
-
* True if partitioned cookies are enabled, but the partition key is not
|
|
9403
|
+
* True if partitioned cookies are enabled, but the partition key is not serializable to string.
|
|
9383
9404
|
*/
|
|
9384
9405
|
cookiePartitionKeyOpaque?: boolean;
|
|
9385
9406
|
/**
|
|
@@ -9528,7 +9549,7 @@ export declare namespace Overlay {
|
|
|
9528
9549
|
*/
|
|
9529
9550
|
interface SourceOrderConfig {
|
|
9530
9551
|
/**
|
|
9531
|
-
* the color to outline the
|
|
9552
|
+
* the color to outline the given element in.
|
|
9532
9553
|
*/
|
|
9533
9554
|
parentOutlineColor: DOM.RGBA;
|
|
9534
9555
|
/**
|
|
@@ -9874,7 +9895,7 @@ export declare namespace Overlay {
|
|
|
9874
9895
|
*/
|
|
9875
9896
|
showCSS: boolean;
|
|
9876
9897
|
/**
|
|
9877
|
-
*
|
|
9898
|
+
* Selected platforms to show the overlay.
|
|
9878
9899
|
*/
|
|
9879
9900
|
selectedPlatform: string;
|
|
9880
9901
|
/**
|
|
@@ -10358,6 +10379,7 @@ export declare namespace Page {
|
|
|
10358
10379
|
SharedStorage = "shared-storage",
|
|
10359
10380
|
SharedStorageSelectUrl = "shared-storage-select-url",
|
|
10360
10381
|
SmartCard = "smart-card",
|
|
10382
|
+
SpeakerSelection = "speaker-selection",
|
|
10361
10383
|
StorageAccess = "storage-access",
|
|
10362
10384
|
SubApps = "sub-apps",
|
|
10363
10385
|
SyncXhr = "sync-xhr",
|
|
@@ -10667,7 +10689,7 @@ export declare namespace Page {
|
|
|
10667
10689
|
*/
|
|
10668
10690
|
message: string;
|
|
10669
10691
|
/**
|
|
10670
|
-
* If
|
|
10692
|
+
* If critical, this is a non-recoverable parse error.
|
|
10671
10693
|
*/
|
|
10672
10694
|
critical: integer;
|
|
10673
10695
|
/**
|
|
@@ -10897,7 +10919,7 @@ export declare namespace Page {
|
|
|
10897
10919
|
eager?: boolean;
|
|
10898
10920
|
}
|
|
10899
10921
|
/**
|
|
10900
|
-
* Enum of possible auto-
|
|
10922
|
+
* Enum of possible auto-response for permission / prompt dialogs.
|
|
10901
10923
|
*/
|
|
10902
10924
|
const enum AutoResponseMode {
|
|
10903
10925
|
None = "none",
|
|
@@ -10981,7 +11003,6 @@ export declare namespace Page {
|
|
|
10981
11003
|
SubresourceHasCacheControlNoCache = "SubresourceHasCacheControlNoCache",
|
|
10982
11004
|
ContainsPlugins = "ContainsPlugins",
|
|
10983
11005
|
DocumentLoaded = "DocumentLoaded",
|
|
10984
|
-
DedicatedWorkerOrWorklet = "DedicatedWorkerOrWorklet",
|
|
10985
11006
|
OutstandingNetworkRequestOthers = "OutstandingNetworkRequestOthers",
|
|
10986
11007
|
RequestedMIDIPermission = "RequestedMIDIPermission",
|
|
10987
11008
|
RequestedAudioCapturePermission = "RequestedAudioCapturePermission",
|
|
@@ -11022,6 +11043,7 @@ export declare namespace Page {
|
|
|
11022
11043
|
SmartCard = "SmartCard",
|
|
11023
11044
|
LiveMediaStreamTrack = "LiveMediaStreamTrack",
|
|
11024
11045
|
UnloadHandler = "UnloadHandler",
|
|
11046
|
+
ParserAborted = "ParserAborted",
|
|
11025
11047
|
ContentSecurityHandler = "ContentSecurityHandler",
|
|
11026
11048
|
ContentWebAuthenticationAPI = "ContentWebAuthenticationAPI",
|
|
11027
11049
|
ContentFileChooser = "ContentFileChooser",
|
|
@@ -12028,7 +12050,7 @@ export declare namespace Page {
|
|
|
12028
12050
|
*/
|
|
12029
12051
|
interface BackForwardCacheNotUsedEvent {
|
|
12030
12052
|
/**
|
|
12031
|
-
* The loader id for the associated
|
|
12053
|
+
* The loader id for the associated navigation.
|
|
12032
12054
|
*/
|
|
12033
12055
|
loaderId: Network.LoaderId;
|
|
12034
12056
|
/**
|
|
@@ -12223,7 +12245,7 @@ export declare namespace PerformanceTimeline {
|
|
|
12223
12245
|
frameId: Page.FrameId;
|
|
12224
12246
|
/**
|
|
12225
12247
|
* The event type, as specified in https://w3c.github.io/performance-timeline/#dom-performanceentry-entrytype
|
|
12226
|
-
* This determines which of the optional "details"
|
|
12248
|
+
* This determines which of the optional "details" fields is present.
|
|
12227
12249
|
*/
|
|
12228
12250
|
type: string;
|
|
12229
12251
|
/**
|
|
@@ -12335,7 +12357,7 @@ export declare namespace Security {
|
|
|
12335
12357
|
*/
|
|
12336
12358
|
certificateNetworkError?: string;
|
|
12337
12359
|
/**
|
|
12338
|
-
* True if the certificate uses a weak signature
|
|
12360
|
+
* True if the certificate uses a weak signature algorithm.
|
|
12339
12361
|
*/
|
|
12340
12362
|
certificateHasWeakSignature: boolean;
|
|
12341
12363
|
/**
|
|
@@ -12789,9 +12811,23 @@ export declare namespace Storage {
|
|
|
12789
12811
|
* Details for an origin's shared storage.
|
|
12790
12812
|
*/
|
|
12791
12813
|
interface SharedStorageMetadata {
|
|
12814
|
+
/**
|
|
12815
|
+
* Time when the origin's shared storage was last created.
|
|
12816
|
+
*/
|
|
12792
12817
|
creationTime: Network.TimeSinceEpoch;
|
|
12818
|
+
/**
|
|
12819
|
+
* Number of key-value pairs stored in origin's shared storage.
|
|
12820
|
+
*/
|
|
12793
12821
|
length: integer;
|
|
12822
|
+
/**
|
|
12823
|
+
* Current amount of bits of entropy remaining in the navigation budget.
|
|
12824
|
+
*/
|
|
12794
12825
|
remainingBudget: number;
|
|
12826
|
+
/**
|
|
12827
|
+
* Total number of bytes stored as key-value pairs in origin's shared
|
|
12828
|
+
* storage.
|
|
12829
|
+
*/
|
|
12830
|
+
bytesUsed: integer;
|
|
12795
12831
|
}
|
|
12796
12832
|
/**
|
|
12797
12833
|
* Pair of reporting metadata details for a candidate URL for `selectURL()`.
|
|
@@ -12976,7 +13012,7 @@ export declare namespace Storage {
|
|
|
12976
13012
|
Include = "include",
|
|
12977
13013
|
Exclude = "exclude"
|
|
12978
13014
|
}
|
|
12979
|
-
interface
|
|
13015
|
+
interface AttributionReportingAggregatableValueDictEntry {
|
|
12980
13016
|
key: string;
|
|
12981
13017
|
/**
|
|
12982
13018
|
* number instead of integer because not all uint32 can be represented by
|
|
@@ -12984,6 +13020,10 @@ export declare namespace Storage {
|
|
|
12984
13020
|
*/
|
|
12985
13021
|
value: number;
|
|
12986
13022
|
}
|
|
13023
|
+
interface AttributionReportingAggregatableValueEntry {
|
|
13024
|
+
values: AttributionReportingAggregatableValueDictEntry[];
|
|
13025
|
+
filters: AttributionReportingFilterPair;
|
|
13026
|
+
}
|
|
12987
13027
|
interface AttributionReportingEventTriggerData {
|
|
12988
13028
|
data: UnsignedInt64AsBase10;
|
|
12989
13029
|
priority: SignedInt64AsBase10;
|
|
@@ -13428,7 +13468,7 @@ export declare namespace Storage {
|
|
|
13428
13468
|
*/
|
|
13429
13469
|
ownerOrigin: string;
|
|
13430
13470
|
/**
|
|
13431
|
-
* The sub-parameters
|
|
13471
|
+
* The sub-parameters wrapped by `params` are all optional and their
|
|
13432
13472
|
* presence/absence depends on `type`.
|
|
13433
13473
|
*/
|
|
13434
13474
|
params: SharedStorageAccessParams;
|
|
@@ -13676,6 +13716,9 @@ export declare namespace Target {
|
|
|
13676
13716
|
type SessionID = OpaqueIdentifier<string, 'Protocol.Target.SessionID'>;
|
|
13677
13717
|
interface TargetInfo {
|
|
13678
13718
|
targetId: TargetID;
|
|
13719
|
+
/**
|
|
13720
|
+
* List of types: https://source.chromium.org/chromium/chromium/src/+/main:content/browser/devtools/devtools_agent_host_impl.cc?ss=chromium&q=f:devtools%20-f:out%20%22::kTypeTab%5B%5D%22
|
|
13721
|
+
*/
|
|
13679
13722
|
type: string;
|
|
13680
13723
|
title: string;
|
|
13681
13724
|
url: string;
|
|
@@ -13707,7 +13750,7 @@ export declare namespace Target {
|
|
|
13707
13750
|
*/
|
|
13708
13751
|
interface FilterEntry {
|
|
13709
13752
|
/**
|
|
13710
|
-
* If set, causes exclusion of
|
|
13753
|
+
* If set, causes exclusion of matching targets from the list.
|
|
13711
13754
|
*/
|
|
13712
13755
|
exclude?: boolean;
|
|
13713
13756
|
/**
|
|
@@ -14913,6 +14956,18 @@ export declare namespace WebAuthn {
|
|
|
14913
14956
|
* See https://w3c.github.io/webauthn/#sctn-large-blob-extension
|
|
14914
14957
|
*/
|
|
14915
14958
|
largeBlob?: binary;
|
|
14959
|
+
/**
|
|
14960
|
+
* Assertions returned by this credential will have the backup eligibility
|
|
14961
|
+
* (BE) flag set to this value. Defaults to the authenticator's
|
|
14962
|
+
* defaultBackupEligibility value.
|
|
14963
|
+
*/
|
|
14964
|
+
backupEligibility?: boolean;
|
|
14965
|
+
/**
|
|
14966
|
+
* Assertions returned by this credential will have the backup state (BS)
|
|
14967
|
+
* flag set to this value. Defaults to the authenticator's
|
|
14968
|
+
* defaultBackupState value.
|
|
14969
|
+
*/
|
|
14970
|
+
backupState?: boolean;
|
|
14916
14971
|
}
|
|
14917
14972
|
interface EnableRequest {
|
|
14918
14973
|
/**
|
|
@@ -14983,6 +15038,12 @@ export declare namespace WebAuthn {
|
|
|
14983
15038
|
authenticatorId: AuthenticatorId;
|
|
14984
15039
|
enabled: boolean;
|
|
14985
15040
|
}
|
|
15041
|
+
interface SetCredentialPropertiesRequest {
|
|
15042
|
+
authenticatorId: AuthenticatorId;
|
|
15043
|
+
credentialId: binary;
|
|
15044
|
+
backupEligibility?: boolean;
|
|
15045
|
+
backupState?: boolean;
|
|
15046
|
+
}
|
|
14986
15047
|
/**
|
|
14987
15048
|
* Triggered when a credential is added to an authenticator.
|
|
14988
15049
|
*/
|
|
@@ -15241,7 +15302,7 @@ export declare namespace Preload {
|
|
|
15241
15302
|
* that had a speculation rule that triggered the attempt, and the
|
|
15242
15303
|
* BackendNodeIds of <a href> or <area href> elements that triggered the
|
|
15243
15304
|
* attempt (in the case of attempts triggered by a document rule). It is
|
|
15244
|
-
* possible for
|
|
15305
|
+
* possible for multiple rule sets and links to trigger a single attempt.
|
|
15245
15306
|
*/
|
|
15246
15307
|
interface PreloadingAttemptSource {
|
|
15247
15308
|
key: PreloadingAttemptKey;
|
|
@@ -34,8 +34,7 @@
|
|
|
34
34
|
"../../../../../../front_end/legacy/legacy-defs.d.ts",
|
|
35
35
|
"../../../../../../front_end/global_typings/global_defs.d.ts",
|
|
36
36
|
"../../../../../../front_end/global_typings/request_idle_callback.d.ts",
|
|
37
|
-
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
38
|
-
"../../../../../../node_modules/@webgpu/types/dist/index.d.ts"
|
|
37
|
+
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
39
38
|
],
|
|
40
39
|
"references": [
|
|
41
40
|
{
|
|
@@ -33,8 +33,7 @@
|
|
|
33
33
|
"../../../../../../front_end/legacy/legacy-defs.d.ts",
|
|
34
34
|
"../../../../../../front_end/global_typings/global_defs.d.ts",
|
|
35
35
|
"../../../../../../front_end/global_typings/request_idle_callback.d.ts",
|
|
36
|
-
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
37
|
-
"../../../../../../node_modules/@webgpu/types/dist/index.d.ts"
|
|
36
|
+
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
38
37
|
],
|
|
39
38
|
"references": [
|
|
40
39
|
{
|
|
@@ -45,6 +45,10 @@ export declare class EntriesFilter {
|
|
|
45
45
|
* Returns the set of entries that are invisible given the set of applied actions.
|
|
46
46
|
**/
|
|
47
47
|
invisibleEntries(): Types.TraceEvents.TraceEventData[];
|
|
48
|
+
/**
|
|
49
|
+
* Returns the array of entries that have a sign indicating that entries below are hidden.
|
|
50
|
+
**/
|
|
51
|
+
modifiedEntries(): Types.TraceEvents.TraceEventData[];
|
|
48
52
|
/**
|
|
49
53
|
* Applies an action to hide entries or removes entries
|
|
50
54
|
* from hidden entries array depending on the action.
|
|
@@ -77,6 +77,12 @@ export class EntriesFilter {
|
|
|
77
77
|
invisibleEntries() {
|
|
78
78
|
return this.#invisibleEntries;
|
|
79
79
|
}
|
|
80
|
+
/**
|
|
81
|
+
* Returns the array of entries that have a sign indicating that entries below are hidden.
|
|
82
|
+
**/
|
|
83
|
+
modifiedEntries() {
|
|
84
|
+
return this.#modifiedVisibleEntries;
|
|
85
|
+
}
|
|
80
86
|
/**
|
|
81
87
|
* Applies an action to hide entries or removes entries
|
|
82
88
|
* from hidden entries array depending on the action.
|
|
@@ -98,7 +104,7 @@ export class EntriesFilter {
|
|
|
98
104
|
const actionNode = this.#entryToNode.get(action.entry) || null;
|
|
99
105
|
const parentNode = actionNode && this.#findNextVisibleParent(actionNode);
|
|
100
106
|
if (parentNode) {
|
|
101
|
-
this.#
|
|
107
|
+
this.#addModifiedEntry(parentNode.entry);
|
|
102
108
|
}
|
|
103
109
|
break;
|
|
104
110
|
}
|
|
@@ -111,10 +117,7 @@ export class EntriesFilter {
|
|
|
111
117
|
}
|
|
112
118
|
const allDescendants = this.#findAllDescendantsOfNode(entryNode);
|
|
113
119
|
allDescendants.forEach(descendant => entriesToHide.add(descendant));
|
|
114
|
-
|
|
115
|
-
if (entriesToHide.size > 0) {
|
|
116
|
-
this.#modifiedVisibleEntries.push(action.entry);
|
|
117
|
-
}
|
|
120
|
+
this.#addModifiedEntry(action.entry);
|
|
118
121
|
break;
|
|
119
122
|
}
|
|
120
123
|
case "COLLAPSE_REPEATING_DESCENDANTS" /* FilterAction.COLLAPSE_REPEATING_DESCENDANTS */: {
|
|
@@ -126,7 +129,7 @@ export class EntriesFilter {
|
|
|
126
129
|
const allRepeatingDescendants = this.#findAllRepeatingDescendantsOfNext(entryNode);
|
|
127
130
|
allRepeatingDescendants.forEach(descendant => entriesToHide.add(descendant));
|
|
128
131
|
if (entriesToHide.size > 0) {
|
|
129
|
-
this.#
|
|
132
|
+
this.#addModifiedEntry(action.entry);
|
|
130
133
|
}
|
|
131
134
|
break;
|
|
132
135
|
}
|
|
@@ -145,6 +148,26 @@ export class EntriesFilter {
|
|
|
145
148
|
this.#invisibleEntries.push(...entriesToHide);
|
|
146
149
|
return this.#invisibleEntries;
|
|
147
150
|
}
|
|
151
|
+
/**
|
|
152
|
+
* Add an entry to the array of entries that have a sign indicating that entries below are hidden.
|
|
153
|
+
* Also, remove all of the child entries of the new modified entry from the modified array. Do that because
|
|
154
|
+
* to draw the initiator from the closest visible entry, we need to get the closest entry that is
|
|
155
|
+
* marked as modified and we do not want to get some that are hidden.
|
|
156
|
+
*/
|
|
157
|
+
#addModifiedEntry(entry) {
|
|
158
|
+
this.#modifiedVisibleEntries.push(entry);
|
|
159
|
+
const entryNode = this.#entryToNode.get(entry);
|
|
160
|
+
if (!entryNode) {
|
|
161
|
+
// Invalid node was given, just ignore and move on.
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
164
|
+
const allDescendants = this.#findAllDescendantsOfNode(entryNode);
|
|
165
|
+
if (allDescendants.length > 0) {
|
|
166
|
+
this.#modifiedVisibleEntries = this.#modifiedVisibleEntries.filter(entry => {
|
|
167
|
+
return !allDescendants.includes(entry);
|
|
168
|
+
});
|
|
169
|
+
}
|
|
170
|
+
}
|
|
148
171
|
// The direct parent might be hidden by other actions, therefore we look for the next visible parent.
|
|
149
172
|
#findNextVisibleParent(node) {
|
|
150
173
|
let parent = node.parent;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntriesFilter.js","sourceRoot":"","sources":["../../../../../../front_end/models/trace/EntriesFilter.ts"],"names":[],"mappings":"AAAA,4DAA4D;AAC5D,yEAAyE;AACzE,6BAA6B;AAC7B,OAAO,KAAK,QAAQ,MAAM,iCAAiC,CAAC;AAC5D,OAAO,KAAK,OAAO,MAAM,sBAAsB,CAAC;AAChD,OAAO,KAAK,KAAK,MAAM,kBAAkB,CAAC;AA0B1C;;;;;;;;;IASI;AACJ,MAAM,OAAO,aAAa;IACxB,sEAAsE;IACtE,0EAA0E;IAC1E,oCAAoC;IACpC,YAAY,CAAiB;IAE7B,sCAAsC;IACtC,iBAAiB,GAAuC,EAAE,CAAC;IAC3D,oEAAoE;IACpE,yEAAyE;IACzE,uBAAuB,GAAuC,EAAE,CAAC;IACjE,kFAAkF;IAClF,oFAAoF;IACpF,sBAAsB,GAAgF,IAAI,GAAG,EAAE,CAAC;IAEhH,YAAY,WAA2B;QACrC,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC;IAClC,CAAC;IAED;;;QAGI;IACJ,mBAAmB,CAAC,KAA4C;QAC9D,MAAM,SAAS,GAAG,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;QAC/C,IAAI,CAAC,SAAS,EAAE;YACd,sDAAsD;YACtD,OAAO;gBACL,oDAA6B,EAAE,KAAK;gBACpC,0D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;YACd,mDAAmD;YACnD,OAAO;SACR;QACD,MAAM,WAAW,GAAG,IAAI,CAAC,yBAAyB,CAAC,SAAS,CAAC,CAAC;QAE9D;;;YAGI;QACJ,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE;YAC7D,IAAI,WAAW,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;gBAC/B,OAAO,KAAK,CAAC;aACd;YACD,OAAO,IAAI,CAAC;QACd,CAAC,CAAC,CAAC;QAEH;;;YAGI;QACJ,IAAI,CAAC,uBAAuB,GAAG,IAAI,CAAC,uBAAuB,CAAC,MAAM,CAAC,SAAS,CAAC,EAAE;YAC7E,IAAI,WAAW,CAAC,QAAQ,CAAC,SAAS,CAAC,IAAI,SAAS,KAAK,KAAK,EAAE;gBAC1D,OAAO,KAAK,CAAC;aACd;YACD,OAAO,IAAI,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC;IAED,eAAe,CAAC,KAAuC;QACrD,OAAO,IAAI,CAAC,uBAAuB,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IACtD,CAAC;CACF","sourcesContent":["// Copyright 2023 The Chromium Authors. All rights reserved.\n// Use of this source code is governed by a BSD-style license that can be\n// found in the LICENSE file.\nimport * as Platform from '../../core/platform/platform.js';\nimport * as Helpers from './helpers/helpers.js';\nimport * as Types from './types/types.js';\n\ntype EntryToNodeMap = Map<Types.TraceEvents.SyntheticTraceEntry, Helpers.TreeHelpers.TraceEntryNode>;\n\nexport const enum FilterAction {\n MERGE_FUNCTION = 'MERGE_FUNCTION',\n COLLAPSE_FUNCTION = 'COLLAPSE_FUNCTION',\n COLLAPSE_REPEATING_DESCENDANTS = 'COLLAPSE_REPEATING_DESCENDANTS',\n RESET_CHILDREN = 'RESET_CHILDREN',\n UNDO_ALL_ACTIONS = 'UNDO_ALL_ACTIONS',\n}\n\nexport interface UserFilterAction {\n type: FilterAction;\n entry: Types.TraceEvents.SyntheticTraceEntry;\n}\n\n// Object used to indicate to the Context Menu if an action is possible on the selected entry.\nexport interface PossibleFilterActions {\n [FilterAction.MERGE_FUNCTION]: boolean;\n [FilterAction.COLLAPSE_FUNCTION]: boolean;\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: boolean;\n [FilterAction.RESET_CHILDREN]: boolean;\n [FilterAction.UNDO_ALL_ACTIONS]: boolean;\n}\n\n/**\n * This class can take in a thread that has been generated by the\n * RendererHandler and apply certain actions to it in order to modify what is\n * shown to the user. These actions can be automatically applied by DevTools or\n * applied by the user.\n *\n * Once actions are applied, the invisibleEntries() method will return the\n * entries that are invisible, and this is the list of entries that should be\n * removed before rendering the resulting thread on the timeline.\n **/\nexport class EntriesFilter {\n // Maps from an individual TraceEvent entry to its representation as a\n // RendererEntryNode. We need this so we can then parse the tree structure\n // generated by the RendererHandler.\n #entryToNode: EntryToNodeMap;\n\n // Track the set of invisible entries.\n #invisibleEntries: Types.TraceEvents.TraceEventData[] = [];\n // List of entries whose children are modified. This list is used to\n // keep track of entries that should be identified in the UI as modified.\n #modifiedVisibleEntries: Types.TraceEvents.TraceEventData[] = [];\n // Cache for descendants of entry that have already been gathered. The descendants\n // will never change so we can avoid running the potentially expensive search again.\n #entryToDescendantsMap: Map<Helpers.TreeHelpers.TraceEntryNode, Types.TraceEvents.TraceEventData[]> = new Map();\n\n constructor(entryToNode: EntryToNodeMap) {\n this.#entryToNode = entryToNode;\n }\n\n /**\n * Checks which actions can be applied on an entry. This allows us to only show possible actions in the Context Menu.\n * For example, if an entry has no children, COLLAPSE_FUNCTION will not change the FlameChart, therefore there is no need to show this action as an option.\n **/\n findPossibleActions(entry: Types.TraceEvents.SyntheticTraceEntry): PossibleFilterActions {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n // Invalid node was given, return no possible actions.\n return {\n [FilterAction.MERGE_FUNCTION]: false,\n [FilterAction.COLLAPSE_FUNCTION]: false,\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: false,\n [FilterAction.RESET_CHILDREN]: false,\n [FilterAction.UNDO_ALL_ACTIONS]: false,\n };\n }\n const entryParent = entryNode.parent;\n const allVisibleDescendants =\n this.#findAllDescendantsOfNode(entryNode).filter(descendant => !this.#invisibleEntries.includes(descendant));\n const allVisibleRepeatingDescendants = this.#findAllRepeatingDescendantsOfNext(entryNode).filter(\n descendant => !this.#invisibleEntries.includes(descendant));\n const allInVisibleDescendants =\n this.#findAllDescendantsOfNode(entryNode).filter(descendant => this.#invisibleEntries.includes(descendant));\n\n // If there are children to hide, indicate action as possible\n const possibleActions: PossibleFilterActions = {\n [FilterAction.MERGE_FUNCTION]: entryParent !== null,\n [FilterAction.COLLAPSE_FUNCTION]: allVisibleDescendants.length > 0,\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: allVisibleRepeatingDescendants.length > 0,\n [FilterAction.RESET_CHILDREN]: allInVisibleDescendants.length > 0,\n [FilterAction.UNDO_ALL_ACTIONS]: this.#invisibleEntries.length > 0,\n };\n return possibleActions;\n }\n\n /**\n * Returns the amount of entry descendants that belong to the hidden entries array.\n * **/\n findHiddenDescendantsAmount(entry: Types.TraceEvents.SyntheticTraceEntry): number {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n return 0;\n }\n const allDescendants = this.#findAllDescendantsOfNode(entryNode);\n return allDescendants.filter(descendant => this.invisibleEntries().includes(descendant)).length;\n }\n\n /**\n * Returns the set of entries that are invisible given the set of applied actions.\n **/\n invisibleEntries(): Types.TraceEvents.TraceEventData[] {\n return this.#invisibleEntries;\n }\n\n /**\n * Applies an action to hide entries or removes entries\n * from hidden entries array depending on the action.\n **/\n applyFilterAction(action: UserFilterAction): Types.TraceEvents.TraceEventData[] {\n // We apply new user action to the set of all entries, and mark\n // any that should be hidden by adding them to this set.\n // Another approach would be to use splice() to remove items from the\n // array, but doing this would be a mutation of the arry for every hidden\n // event. Instead, we add entries to this set and return it as an array at the end.\n const entriesToHide = new Set<Types.TraceEvents.TraceEventData>();\n\n switch (action.type) {\n case FilterAction.MERGE_FUNCTION: {\n // The entry that was clicked on is merged into its parent. All its\n // children remain visible, so we just have to hide the entry that was\n // selected.\n entriesToHide.add(action.entry);\n // If parent node exists, add it to modifiedVisibleEntries, so it would be possible to uncollapse its' children.\n const actionNode = this.#entryToNode.get(action.entry) || null;\n const parentNode = actionNode && this.#findNextVisibleParent(actionNode);\n if (parentNode) {\n this.#modifiedVisibleEntries.push(parentNode?.entry);\n }\n break;\n }\n case FilterAction.COLLAPSE_FUNCTION: {\n // The entry itself remains visible, but all of its descendants are hidden.\n const entryNode = this.#entryToNode.get(action.entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n break;\n }\n const allDescendants = this.#findAllDescendantsOfNode(entryNode);\n allDescendants.forEach(descendant => entriesToHide.add(descendant));\n // If there are any children to hide, add selected entry to modifiedVisibleEntries array to identify in the UI that children of the selected entry are modified.\n if (entriesToHide.size > 0) {\n this.#modifiedVisibleEntries.push(action.entry);\n }\n break;\n }\n case FilterAction.COLLAPSE_REPEATING_DESCENDANTS: {\n const entryNode = this.#entryToNode.get(action.entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n break;\n }\n const allRepeatingDescendants = this.#findAllRepeatingDescendantsOfNext(entryNode);\n allRepeatingDescendants.forEach(descendant => entriesToHide.add(descendant));\n if (entriesToHide.size > 0) {\n this.#modifiedVisibleEntries.push(action.entry);\n }\n break;\n }\n case FilterAction.UNDO_ALL_ACTIONS: {\n this.#invisibleEntries = [];\n this.#modifiedVisibleEntries = [];\n break;\n }\n case FilterAction.RESET_CHILDREN: {\n this.#makeEntryChildrenVisible(action.entry);\n break;\n }\n default:\n Platform.assertNever(action.type, `Unknown EntriesFilter action: ${action.type}`);\n }\n\n this.#invisibleEntries.push(...entriesToHide);\n\n return this.#invisibleEntries;\n }\n\n // The direct parent might be hidden by other actions, therefore we look for the next visible parent.\n #findNextVisibleParent(node: Helpers.TreeHelpers.TraceEntryNode): Helpers.TreeHelpers.TraceEntryNode|null {\n let parent = node.parent;\n while (parent && this.#invisibleEntries.includes(parent.entry)) {\n parent = parent.parent;\n }\n return parent;\n }\n\n #findAllDescendantsOfNode(root: Helpers.TreeHelpers.TraceEntryNode): Types.TraceEvents.TraceEventData[] {\n const cachedDescendants = this.#entryToDescendantsMap.get(root);\n if (cachedDescendants) {\n return cachedDescendants;\n }\n\n const descendants: Types.TraceEvents.TraceEventData[] = [];\n\n // Walk through all the descendants, starting at the root node.\n const children: Helpers.TreeHelpers.TraceEntryNode[] = [...root.children];\n while (children.length > 0) {\n const childNode = children.shift();\n if (childNode) {\n descendants.push(childNode.entry);\n const childNodeCachedDescendants = this.#entryToDescendantsMap.get(childNode);\n // If the descendants of a child are cached, get them from the cache instead of iterating through them again\n if (childNodeCachedDescendants) {\n descendants.push(...childNodeCachedDescendants);\n } else {\n children.push(...childNode.children);\n }\n }\n }\n\n this.#entryToDescendantsMap.set(root, descendants);\n return descendants;\n }\n\n #findAllRepeatingDescendantsOfNext(root: Helpers.TreeHelpers.TraceEntryNode):\n Types.TraceEvents.SyntheticTraceEntry[] {\n // Walk through all the ancestors, starting at the root node.\n const children: Helpers.TreeHelpers.TraceEntryNode[] = [...root.children];\n const repeatingNodes: Types.TraceEvents.SyntheticTraceEntry[] = [];\n const rootIsProfileCall = Types.TraceEvents.isProfileCall(root.entry);\n\n while (children.length > 0) {\n const childNode = children.shift();\n if (childNode) {\n const childIsProfileCall = Types.TraceEvents.isProfileCall(childNode.entry);\n if (/* Handle SyntheticProfileCalls */ rootIsProfileCall && childIsProfileCall) {\n const rootNodeEntry = root.entry as Types.TraceEvents.SyntheticProfileCall;\n const childNodeEntry = childNode.entry as Types.TraceEvents.SyntheticProfileCall;\n\n if (Helpers.SamplesIntegrator.SamplesIntegrator.framesAreEqual(\n rootNodeEntry.callFrame, childNodeEntry.callFrame)) {\n repeatingNodes.push(childNode.entry);\n }\n } /* Handle SyntheticRendererEvents */ else if (!rootIsProfileCall && !childIsProfileCall) {\n if (root.entry.name === childNode.entry.name) {\n repeatingNodes.push(childNode.entry);\n }\n }\n children.push(...childNode.children);\n }\n }\n\n return repeatingNodes;\n }\n\n /**\n * Removes all of the entry children from the\n * invisible entries array to make them visible.\n **/\n #makeEntryChildrenVisible(entry: Types.TraceEvents.SyntheticTraceEntry): void {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n return;\n }\n const descendants = this.#findAllDescendantsOfNode(entryNode);\n\n /**\n * Filter out all descendant of the node\n * from the invisible entries list.\n **/\n this.#invisibleEntries = this.#invisibleEntries.filter(entry => {\n if (descendants.includes(entry)) {\n return false;\n }\n return true;\n });\n\n /**\n * Filter out all descentants and entry from modified entries\n * list to not show that some entries below those are hidden.\n **/\n this.#modifiedVisibleEntries = this.#modifiedVisibleEntries.filter(iterEntry => {\n if (descendants.includes(iterEntry) || iterEntry === entry) {\n return false;\n }\n return true;\n });\n }\n\n isEntryModified(event: Types.TraceEvents.TraceEventData): boolean {\n return this.#modifiedVisibleEntries.includes(event);\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"EntriesFilter.js","sourceRoot":"","sources":["../../../../../../front_end/models/trace/EntriesFilter.ts"],"names":[],"mappings":"AAAA,4DAA4D;AAC5D,yEAAyE;AACzE,6BAA6B;AAC7B,OAAO,KAAK,QAAQ,MAAM,iCAAiC,CAAC;AAC5D,OAAO,KAAK,OAAO,MAAM,sBAAsB,CAAC;AAChD,OAAO,KAAK,KAAK,MAAM,kBAAkB,CAAC;AA0B1C;;;;;;;;;IASI;AACJ,MAAM,OAAO,aAAa;IACxB,sEAAsE;IACtE,0EAA0E;IAC1E,oCAAoC;IACpC,YAAY,CAAiB;IAE7B,sCAAsC;IACtC,iBAAiB,GAAuC,EAAE,CAAC;IAC3D,oEAAoE;IACpE,yEAAyE;IACzE,uBAAuB,GAAuC,EAAE,CAAC;IACjE,kFAAkF;IAClF,oFAAoF;IACpF,sBAAsB,GAAgF,IAAI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AAC,MAAM,CAAC,SAAS,CAAC,EAAE;YAC7E,IAAI,WAAW,CAAC,QAAQ,CAAC,SAAS,CAAC,IAAI,SAAS,KAAK,KAAK,EAAE;gBAC1D,OAAO,KAAK,CAAC;aACd;YACD,OAAO,IAAI,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC;IAED,eAAe,CAAC,KAAuC;QACrD,OAAO,IAAI,CAAC,uBAAuB,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IACtD,CAAC;CACF","sourcesContent":["// Copyright 2023 The Chromium Authors. All rights reserved.\n// Use of this source code is governed by a BSD-style license that can be\n// found in the LICENSE file.\nimport * as Platform from '../../core/platform/platform.js';\nimport * as Helpers from './helpers/helpers.js';\nimport * as Types from './types/types.js';\n\ntype EntryToNodeMap = Map<Types.TraceEvents.SyntheticTraceEntry, Helpers.TreeHelpers.TraceEntryNode>;\n\nexport const enum FilterAction {\n MERGE_FUNCTION = 'MERGE_FUNCTION',\n COLLAPSE_FUNCTION = 'COLLAPSE_FUNCTION',\n COLLAPSE_REPEATING_DESCENDANTS = 'COLLAPSE_REPEATING_DESCENDANTS',\n RESET_CHILDREN = 'RESET_CHILDREN',\n UNDO_ALL_ACTIONS = 'UNDO_ALL_ACTIONS',\n}\n\nexport interface UserFilterAction {\n type: FilterAction;\n entry: Types.TraceEvents.SyntheticTraceEntry;\n}\n\n// Object used to indicate to the Context Menu if an action is possible on the selected entry.\nexport interface PossibleFilterActions {\n [FilterAction.MERGE_FUNCTION]: boolean;\n [FilterAction.COLLAPSE_FUNCTION]: boolean;\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: boolean;\n [FilterAction.RESET_CHILDREN]: boolean;\n [FilterAction.UNDO_ALL_ACTIONS]: boolean;\n}\n\n/**\n * This class can take in a thread that has been generated by the\n * RendererHandler and apply certain actions to it in order to modify what is\n * shown to the user. These actions can be automatically applied by DevTools or\n * applied by the user.\n *\n * Once actions are applied, the invisibleEntries() method will return the\n * entries that are invisible, and this is the list of entries that should be\n * removed before rendering the resulting thread on the timeline.\n **/\nexport class EntriesFilter {\n // Maps from an individual TraceEvent entry to its representation as a\n // RendererEntryNode. We need this so we can then parse the tree structure\n // generated by the RendererHandler.\n #entryToNode: EntryToNodeMap;\n\n // Track the set of invisible entries.\n #invisibleEntries: Types.TraceEvents.TraceEventData[] = [];\n // List of entries whose children are modified. This list is used to\n // keep track of entries that should be identified in the UI as modified.\n #modifiedVisibleEntries: Types.TraceEvents.TraceEventData[] = [];\n // Cache for descendants of entry that have already been gathered. The descendants\n // will never change so we can avoid running the potentially expensive search again.\n #entryToDescendantsMap: Map<Helpers.TreeHelpers.TraceEntryNode, Types.TraceEvents.TraceEventData[]> = new Map();\n\n constructor(entryToNode: EntryToNodeMap) {\n this.#entryToNode = entryToNode;\n }\n\n /**\n * Checks which actions can be applied on an entry. This allows us to only show possible actions in the Context Menu.\n * For example, if an entry has no children, COLLAPSE_FUNCTION will not change the FlameChart, therefore there is no need to show this action as an option.\n **/\n findPossibleActions(entry: Types.TraceEvents.SyntheticTraceEntry): PossibleFilterActions {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n // Invalid node was given, return no possible actions.\n return {\n [FilterAction.MERGE_FUNCTION]: false,\n [FilterAction.COLLAPSE_FUNCTION]: false,\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: false,\n [FilterAction.RESET_CHILDREN]: false,\n [FilterAction.UNDO_ALL_ACTIONS]: false,\n };\n }\n const entryParent = entryNode.parent;\n const allVisibleDescendants =\n this.#findAllDescendantsOfNode(entryNode).filter(descendant => !this.#invisibleEntries.includes(descendant));\n const allVisibleRepeatingDescendants = this.#findAllRepeatingDescendantsOfNext(entryNode).filter(\n descendant => !this.#invisibleEntries.includes(descendant));\n const allInVisibleDescendants =\n this.#findAllDescendantsOfNode(entryNode).filter(descendant => this.#invisibleEntries.includes(descendant));\n\n // If there are children to hide, indicate action as possible\n const possibleActions: PossibleFilterActions = {\n [FilterAction.MERGE_FUNCTION]: entryParent !== null,\n [FilterAction.COLLAPSE_FUNCTION]: allVisibleDescendants.length > 0,\n [FilterAction.COLLAPSE_REPEATING_DESCENDANTS]: allVisibleRepeatingDescendants.length > 0,\n [FilterAction.RESET_CHILDREN]: allInVisibleDescendants.length > 0,\n [FilterAction.UNDO_ALL_ACTIONS]: this.#invisibleEntries.length > 0,\n };\n return possibleActions;\n }\n\n /**\n * Returns the amount of entry descendants that belong to the hidden entries array.\n * **/\n findHiddenDescendantsAmount(entry: Types.TraceEvents.SyntheticTraceEntry): number {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n return 0;\n }\n const allDescendants = this.#findAllDescendantsOfNode(entryNode);\n return allDescendants.filter(descendant => this.invisibleEntries().includes(descendant)).length;\n }\n\n /**\n * Returns the set of entries that are invisible given the set of applied actions.\n **/\n invisibleEntries(): Types.TraceEvents.TraceEventData[] {\n return this.#invisibleEntries;\n }\n\n /**\n * Returns the array of entries that have a sign indicating that entries below are hidden.\n **/\n modifiedEntries(): Types.TraceEvents.TraceEventData[] {\n return this.#modifiedVisibleEntries;\n }\n\n /**\n * Applies an action to hide entries or removes entries\n * from hidden entries array depending on the action.\n **/\n applyFilterAction(action: UserFilterAction): Types.TraceEvents.TraceEventData[] {\n // We apply new user action to the set of all entries, and mark\n // any that should be hidden by adding them to this set.\n // Another approach would be to use splice() to remove items from the\n // array, but doing this would be a mutation of the arry for every hidden\n // event. Instead, we add entries to this set and return it as an array at the end.\n const entriesToHide = new Set<Types.TraceEvents.TraceEventData>();\n\n switch (action.type) {\n case FilterAction.MERGE_FUNCTION: {\n // The entry that was clicked on is merged into its parent. All its\n // children remain visible, so we just have to hide the entry that was\n // selected.\n entriesToHide.add(action.entry);\n // If parent node exists, add it to modifiedVisibleEntries, so it would be possible to uncollapse its' children.\n const actionNode = this.#entryToNode.get(action.entry) || null;\n const parentNode = actionNode && this.#findNextVisibleParent(actionNode);\n if (parentNode) {\n this.#addModifiedEntry(parentNode.entry);\n }\n break;\n }\n case FilterAction.COLLAPSE_FUNCTION: {\n // The entry itself remains visible, but all of its descendants are hidden.\n const entryNode = this.#entryToNode.get(action.entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n break;\n }\n const allDescendants = this.#findAllDescendantsOfNode(entryNode);\n allDescendants.forEach(descendant => entriesToHide.add(descendant));\n this.#addModifiedEntry(action.entry);\n break;\n }\n case FilterAction.COLLAPSE_REPEATING_DESCENDANTS: {\n const entryNode = this.#entryToNode.get(action.entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n break;\n }\n const allRepeatingDescendants = this.#findAllRepeatingDescendantsOfNext(entryNode);\n allRepeatingDescendants.forEach(descendant => entriesToHide.add(descendant));\n if (entriesToHide.size > 0) {\n this.#addModifiedEntry(action.entry);\n }\n break;\n }\n case FilterAction.UNDO_ALL_ACTIONS: {\n this.#invisibleEntries = [];\n this.#modifiedVisibleEntries = [];\n break;\n }\n case FilterAction.RESET_CHILDREN: {\n this.#makeEntryChildrenVisible(action.entry);\n break;\n }\n default:\n Platform.assertNever(action.type, `Unknown EntriesFilter action: ${action.type}`);\n }\n\n this.#invisibleEntries.push(...entriesToHide);\n\n return this.#invisibleEntries;\n }\n\n /**\n * Add an entry to the array of entries that have a sign indicating that entries below are hidden.\n * Also, remove all of the child entries of the new modified entry from the modified array. Do that because\n * to draw the initiator from the closest visible entry, we need to get the closest entry that is\n * marked as modified and we do not want to get some that are hidden.\n */\n #addModifiedEntry(entry: Types.TraceEvents.TraceEventData): void {\n this.#modifiedVisibleEntries.push(entry);\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n return;\n }\n const allDescendants = this.#findAllDescendantsOfNode(entryNode);\n if (allDescendants.length > 0) {\n this.#modifiedVisibleEntries = this.#modifiedVisibleEntries.filter(entry => {\n return !allDescendants.includes(entry);\n });\n }\n }\n\n // The direct parent might be hidden by other actions, therefore we look for the next visible parent.\n #findNextVisibleParent(node: Helpers.TreeHelpers.TraceEntryNode): Helpers.TreeHelpers.TraceEntryNode|null {\n let parent = node.parent;\n while (parent && this.#invisibleEntries.includes(parent.entry)) {\n parent = parent.parent;\n }\n return parent;\n }\n\n #findAllDescendantsOfNode(root: Helpers.TreeHelpers.TraceEntryNode): Types.TraceEvents.TraceEventData[] {\n const cachedDescendants = this.#entryToDescendantsMap.get(root);\n if (cachedDescendants) {\n return cachedDescendants;\n }\n\n const descendants: Types.TraceEvents.TraceEventData[] = [];\n\n // Walk through all the descendants, starting at the root node.\n const children: Helpers.TreeHelpers.TraceEntryNode[] = [...root.children];\n while (children.length > 0) {\n const childNode = children.shift();\n if (childNode) {\n descendants.push(childNode.entry);\n const childNodeCachedDescendants = this.#entryToDescendantsMap.get(childNode);\n // If the descendants of a child are cached, get them from the cache instead of iterating through them again\n if (childNodeCachedDescendants) {\n descendants.push(...childNodeCachedDescendants);\n } else {\n children.push(...childNode.children);\n }\n }\n }\n\n this.#entryToDescendantsMap.set(root, descendants);\n return descendants;\n }\n\n #findAllRepeatingDescendantsOfNext(root: Helpers.TreeHelpers.TraceEntryNode):\n Types.TraceEvents.SyntheticTraceEntry[] {\n // Walk through all the ancestors, starting at the root node.\n const children: Helpers.TreeHelpers.TraceEntryNode[] = [...root.children];\n const repeatingNodes: Types.TraceEvents.SyntheticTraceEntry[] = [];\n const rootIsProfileCall = Types.TraceEvents.isProfileCall(root.entry);\n\n while (children.length > 0) {\n const childNode = children.shift();\n if (childNode) {\n const childIsProfileCall = Types.TraceEvents.isProfileCall(childNode.entry);\n if (/* Handle SyntheticProfileCalls */ rootIsProfileCall && childIsProfileCall) {\n const rootNodeEntry = root.entry as Types.TraceEvents.SyntheticProfileCall;\n const childNodeEntry = childNode.entry as Types.TraceEvents.SyntheticProfileCall;\n\n if (Helpers.SamplesIntegrator.SamplesIntegrator.framesAreEqual(\n rootNodeEntry.callFrame, childNodeEntry.callFrame)) {\n repeatingNodes.push(childNode.entry);\n }\n } /* Handle SyntheticRendererEvents */ else if (!rootIsProfileCall && !childIsProfileCall) {\n if (root.entry.name === childNode.entry.name) {\n repeatingNodes.push(childNode.entry);\n }\n }\n children.push(...childNode.children);\n }\n }\n\n return repeatingNodes;\n }\n\n /**\n * Removes all of the entry children from the\n * invisible entries array to make them visible.\n **/\n #makeEntryChildrenVisible(entry: Types.TraceEvents.SyntheticTraceEntry): void {\n const entryNode = this.#entryToNode.get(entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n return;\n }\n const descendants = this.#findAllDescendantsOfNode(entryNode);\n\n /**\n * Filter out all descendant of the node\n * from the invisible entries list.\n **/\n this.#invisibleEntries = this.#invisibleEntries.filter(entry => {\n if (descendants.includes(entry)) {\n return false;\n }\n return true;\n });\n\n /**\n * Filter out all descentants and entry from modified entries\n * list to not show that some entries below those are hidden.\n **/\n this.#modifiedVisibleEntries = this.#modifiedVisibleEntries.filter(iterEntry => {\n if (descendants.includes(iterEntry) || iterEntry === entry) {\n return false;\n }\n return true;\n });\n }\n\n isEntryModified(event: Types.TraceEvents.TraceEventData): boolean {\n return this.#modifiedVisibleEntries.includes(event);\n }\n}\n"]}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as Handlers from './handlers/handlers.js';
|
|
2
|
+
import type * as Insights from './insights/insights.js';
|
|
2
3
|
import * as Types from './types/types.js';
|
|
3
4
|
export interface ParseConfig {
|
|
4
5
|
metadata?: Types.File.MetaData;
|
|
@@ -62,6 +63,7 @@ export declare class Model<EnabledModelHandlers extends {
|
|
|
62
63
|
* If no index is given, the last stored parsed data is returned.
|
|
63
64
|
*/
|
|
64
65
|
traceParsedData(index?: number): Handlers.Types.EnabledHandlerDataWithMeta<EnabledModelHandlers> | null;
|
|
66
|
+
traceInsights(index?: number): Insights.Types.TraceInsightData<EnabledModelHandlers> | null;
|
|
65
67
|
metadata(index: number): Types.File.MetaData | null;
|
|
66
68
|
traceEvents(index: number): readonly Types.TraceEvents.TraceEventData[] | null;
|
|
67
69
|
size(): number;
|
|
@@ -78,6 +80,7 @@ export type ParsedTraceFile<Handlers extends {
|
|
|
78
80
|
[key: string]: Handlers.Types.TraceEventHandler;
|
|
79
81
|
}> = Types.File.TraceFile & {
|
|
80
82
|
traceParsedData: Handlers.Types.EnabledHandlerDataWithMeta<Handlers> | null;
|
|
83
|
+
traceInsights: Insights.Types.TraceInsightData<Handlers> | null;
|
|
81
84
|
};
|
|
82
85
|
export declare const enum ModelUpdateType {
|
|
83
86
|
COMPLETE = "COMPLETE",
|
|
@@ -87,12 +87,13 @@ export class Model extends EventTarget {
|
|
|
87
87
|
traceEvents,
|
|
88
88
|
metadata,
|
|
89
89
|
traceParsedData: null,
|
|
90
|
+
traceInsights: null,
|
|
90
91
|
};
|
|
91
92
|
try {
|
|
92
93
|
// Wait for all outstanding promises before finishing the async execution,
|
|
93
94
|
// but perform all tasks in parallel.
|
|
94
95
|
await this.#processor.parse(traceEvents, isFreshRecording);
|
|
95
|
-
this.#storeParsedFileData(file, this.#processor.
|
|
96
|
+
this.#storeParsedFileData(file, this.#processor.traceParsedData, this.#processor.insights);
|
|
96
97
|
// We only push the file onto this.#traces here once we know it's valid
|
|
97
98
|
// and there's been no errors in the parsing.
|
|
98
99
|
this.#traces.push(file);
|
|
@@ -107,8 +108,9 @@ export class Model extends EventTarget {
|
|
|
107
108
|
this.dispatchEvent(new ModelUpdateEvent({ type: "COMPLETE" /* ModelUpdateType.COMPLETE */, data: 'done' }));
|
|
108
109
|
}
|
|
109
110
|
}
|
|
110
|
-
#storeParsedFileData(file, data) {
|
|
111
|
+
#storeParsedFileData(file, data, insights) {
|
|
111
112
|
file.traceParsedData = data;
|
|
113
|
+
file.traceInsights = insights;
|
|
112
114
|
this.#lastRecordingIndex++;
|
|
113
115
|
let recordingName = `Trace ${this.#lastRecordingIndex}`;
|
|
114
116
|
let origin = null;
|
|
@@ -132,6 +134,12 @@ export class Model extends EventTarget {
|
|
|
132
134
|
}
|
|
133
135
|
return this.#traces[index].traceParsedData;
|
|
134
136
|
}
|
|
137
|
+
traceInsights(index = this.#traces.length - 1) {
|
|
138
|
+
if (!this.#traces[index]) {
|
|
139
|
+
return null;
|
|
140
|
+
}
|
|
141
|
+
return this.#traces[index].traceInsights;
|
|
142
|
+
}
|
|
135
143
|
metadata(index) {
|
|
136
144
|
if (!this.#traces[index]) {
|
|
137
145
|
return null;
|