@paulirish/trace_engine 0.0.11 → 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 +1 -1
- package/package.json +1 -1
- package/core/platform/devtools_entrypoint-bundle-tsconfig-tsconfig.json +0 -40
- package/core/platform/platform.js.compressed +0 -0
- package/core/platform/platform.js.hash +0 -1
- package/core/platform/platform.prebundle.d.ts +0 -15
- package/core/platform/platform.prebundle.js +0 -50
- package/core/platform/platform.prebundle.js.map +0 -1
- package/core/platform/platform.prebundle.ts +0 -64
- package/models/trace/SDKServices.js +0 -104
- package/models/trace/SDKServices.js.map +0 -7
- package/models/trace/TraceProcessor.js +0 -133
- package/models/trace/TraceProcessor.js.map +0 -7
- package/models/trace/TreeManipulator.js +0 -85
- package/models/trace/TreeManipulator.js.map +0 -7
- package/models/trace/devtools_entrypoint-legacy-typescript-tsconfig.json +0 -43
- package/models/trace/frames/TimelineFrameModel.js +0 -392
- package/models/trace/frames/TimelineFrameModel.js.map +0 -7
- package/models/trace/frames/bundle-tsconfig.json +0 -1
- package/models/trace/frames/devtools_entrypoint-bundle-typescript-tsconfig.json +0 -43
- package/models/trace/frames/frames-tsconfig.json +0 -58
- package/models/trace/frames/frames.js +0 -5
- package/models/trace/frames/frames.js.map +0 -7
- package/models/trace/handlers/Migration.js +0 -27
- package/models/trace/handlers/Migration.js.map +0 -7
- package/models/trace/handlers/UberFramesHandler.js +0 -293
- package/models/trace/handlers/UberFramesHandler.js.map +0 -7
- package/models/trace/legacy-tsconfig.json +0 -1
- package/models/trace/sdk_services/DOMNodeLookup.js +0 -41
- package/models/trace/sdk_services/DOMNodeLookup.js.map +0 -7
- package/models/trace/sdk_services/LayoutShifts.js +0 -68
- package/models/trace/sdk_services/LayoutShifts.js.map +0 -7
- package/models/trace/sdk_services/bundle-tsconfig.json +0 -1
- package/models/trace/sdk_services/devtools_entrypoint-bundle-typescript-tsconfig.json +0 -41
- package/models/trace/sdk_services/sdk_services-tsconfig.json +0 -57
- package/models/trace/sdk_services/sdk_services.js +0 -7
- package/models/trace/sdk_services/sdk_services.js.map +0 -7
- package/models/trace/trace-legacy.js +0 -16
- package/models/trace/trace-legacy.js.map +0 -7
- package/models/trace/worker/Processor.js +0 -143
- package/models/trace/worker/Processor.js.map +0 -7
- package/models/trace/worker/Types.js +0 -1
- package/models/trace/worker/Types.js.map +0 -7
- package/models/trace/worker/bundle-tsconfig.json +0 -1
- package/models/trace/worker/devtools_entrypoint-bundle-typescript-tsconfig.json +0 -41
- package/models/trace/worker/devtools_entrypoint-worker_entrypoint-typescript-tsconfig.json +0 -41
- package/models/trace/worker/processor-tsconfig.json +0 -45
- package/models/trace/worker/worker.js +0 -7
- package/models/trace/worker/worker.js.map +0 -7
- package/models/trace/worker/worker_entrypoint-tsconfig.json +0 -1
- package/models/trace/worker/worker_entrypoint.js +0 -36
- package/models/trace/worker/worker_entrypoint.js.map +0 -7
package/README.md
CHANGED
package/package.json
CHANGED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"allowJs": true,
|
|
4
|
-
"checkJs": true,
|
|
5
|
-
"composite": true,
|
|
6
|
-
"declaration": true,
|
|
7
|
-
"forceConsistentCasingInFileNames": true,
|
|
8
|
-
"inlineSources": true,
|
|
9
|
-
"lib": [
|
|
10
|
-
"esnext",
|
|
11
|
-
"dom",
|
|
12
|
-
"dom.iterable"
|
|
13
|
-
],
|
|
14
|
-
"module": "esnext",
|
|
15
|
-
"noEmitOnError": true,
|
|
16
|
-
"noFallthroughCasesInSwitch": true,
|
|
17
|
-
"noImplicitReturns": true,
|
|
18
|
-
"outDir": ".",
|
|
19
|
-
"rootDir": ".",
|
|
20
|
-
"skipLibCheck": true,
|
|
21
|
-
"sourceMap": true,
|
|
22
|
-
"strict": true,
|
|
23
|
-
"target": "esnext",
|
|
24
|
-
"tsBuildInfoFile": "devtools_entrypoint-bundle-tsconfig-tsconfig.json.tsbuildinfo",
|
|
25
|
-
"typeRoots": [],
|
|
26
|
-
"useUnknownInCatchVariables": false
|
|
27
|
-
},
|
|
28
|
-
"files": [
|
|
29
|
-
"platform.prebundle.ts",
|
|
30
|
-
"../../../../../../front_end/legacy/legacy-defs.d.ts",
|
|
31
|
-
"../../../../../../front_end/global_typings/global_defs.d.ts",
|
|
32
|
-
"../../../../../../front_end/global_typings/request_idle_callback.d.ts",
|
|
33
|
-
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
34
|
-
],
|
|
35
|
-
"references": [
|
|
36
|
-
{
|
|
37
|
-
"path": "./platform-tsconfig.json"
|
|
38
|
-
}
|
|
39
|
-
]
|
|
40
|
-
}
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
da7fcbc6595ae828a8f968354a0793bbe528d175
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as ArrayUtilities from './array-utilities.js';
|
|
2
|
-
import * as DateUtilities from './date-utilities.js';
|
|
3
|
-
import * as DevToolsPath from './DevToolsPath.js';
|
|
4
|
-
import * as DOMUtilities from './dom-utilities.js';
|
|
5
|
-
import * as KeyboardUtilities from './keyboard-utilities.js';
|
|
6
|
-
import * as MapUtilities from './map-utilities.js';
|
|
7
|
-
import * as NumberUtilities from './number-utilities.js';
|
|
8
|
-
import * as SetUtilities from './set-utilities.js';
|
|
9
|
-
import * as StringUtilities from './string-utilities.js';
|
|
10
|
-
import * as TypeScriptUtilities from './typescript-utilities.js';
|
|
11
|
-
import * as UIString from './UIString.js';
|
|
12
|
-
import * as UserVisibleError from './UserVisibleError.js';
|
|
13
|
-
export { DCHECK } from './dcheck.js';
|
|
14
|
-
export { assertNever, assertNotNullOrUndefined, assertUnhandled } from './typescript-utilities.js';
|
|
15
|
-
export { ArrayUtilities, DateUtilities, DevToolsPath, DOMUtilities, KeyboardUtilities, MapUtilities, NumberUtilities, SetUtilities, StringUtilities, TypeScriptUtilities, UIString, UserVisibleError, };
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2019 Google Inc. All rights reserved.
|
|
3
|
-
*
|
|
4
|
-
* Redistribution and use in source and binary forms, with or without
|
|
5
|
-
* modification, are permitted provided that the following conditions are
|
|
6
|
-
* met:
|
|
7
|
-
*
|
|
8
|
-
* * Redistributions of source code must retain the above copyright
|
|
9
|
-
* notice, this list of conditions and the following disclaimer.
|
|
10
|
-
* * Redistributions in binary form must reproduce the above
|
|
11
|
-
* copyright notice, this list of conditions and the following disclaimer
|
|
12
|
-
* in the documentation and/or other materials provided with the
|
|
13
|
-
* distribution.
|
|
14
|
-
* * Neither the name of Google Inc. nor the names of its
|
|
15
|
-
* contributors may be used to endorse or promote products derived from
|
|
16
|
-
* this software without specific prior written permission.
|
|
17
|
-
*
|
|
18
|
-
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
19
|
-
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
20
|
-
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
21
|
-
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
22
|
-
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
23
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
24
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
25
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
26
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
27
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
28
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
29
|
-
*/
|
|
30
|
-
import * as ArrayUtilities from './array-utilities.js';
|
|
31
|
-
import * as DateUtilities from './date-utilities.js';
|
|
32
|
-
import * as DevToolsPath from './DevToolsPath.js';
|
|
33
|
-
import * as DOMUtilities from './dom-utilities.js';
|
|
34
|
-
import * as KeyboardUtilities from './keyboard-utilities.js';
|
|
35
|
-
import * as MapUtilities from './map-utilities.js';
|
|
36
|
-
import * as NumberUtilities from './number-utilities.js';
|
|
37
|
-
import * as SetUtilities from './set-utilities.js';
|
|
38
|
-
import * as StringUtilities from './string-utilities.js';
|
|
39
|
-
import * as TypeScriptUtilities from './typescript-utilities.js';
|
|
40
|
-
import * as UIString from './UIString.js';
|
|
41
|
-
import * as UserVisibleError from './UserVisibleError.js';
|
|
42
|
-
export { DCHECK } from './dcheck.js';
|
|
43
|
-
/* `assertNotNull` also need to be exposed, as TypeScript does not
|
|
44
|
-
* allow `asserts` functions to be used with qualified access
|
|
45
|
-
* (e.g. `Platform.TypeScriptUtilities.assertNotNull` causes a
|
|
46
|
-
* compiler error)
|
|
47
|
-
*/
|
|
48
|
-
export { assertNever, assertNotNullOrUndefined, assertUnhandled } from './typescript-utilities.js';
|
|
49
|
-
export { ArrayUtilities, DateUtilities, DevToolsPath, DOMUtilities, KeyboardUtilities, MapUtilities, NumberUtilities, SetUtilities, StringUtilities, TypeScriptUtilities, UIString, UserVisibleError, };
|
|
50
|
-
//# sourceMappingURL=platform.prebundle.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"platform.prebundle.js","sourceRoot":"","sources":["platform.prebundle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,KAAK,cAAc,MAAM,sBAAsB,CAAC;AACvD,OAAO,KAAK,aAAa,MAAM,qBAAqB,CAAC;AACrD,OAAO,KAAK,YAAY,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,YAAY,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,iBAAiB,MAAM,yBAAyB,CAAC;AAC7D,OAAO,KAAK,YAAY,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,YAAY,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,mBAAmB,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAC1C,OAAO,KAAK,gBAAgB,MAAM,uBAAuB,CAAC;AAE1D,OAAO,EAAC,MAAM,EAAC,MAAM,aAAa,CAAC;AACnC;;;;GAIG;AACH,OAAO,EAAC,WAAW,EAAE,wBAAwB,EAAE,eAAe,EAAC,MAAM,2BAA2B,CAAC;AACjG,OAAO,EACL,cAAc,EACd,aAAa,EACb,YAAY,EACZ,YAAY,EACZ,iBAAiB,EACjB,YAAY,EACZ,eAAe,EACf,YAAY,EACZ,eAAe,EACf,mBAAmB,EACnB,QAAQ,EACR,gBAAgB,GACjB,CAAC","sourcesContent":["/*\n * Copyright (C) 2019 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are\n * met:\n *\n * * Redistributions of source code must retain the above copyright\n * notice, this list of conditions and the following disclaimer.\n * * Redistributions in binary form must reproduce the above\n * copyright notice, this list of conditions and the following disclaimer\n * in the documentation and/or other materials provided with the\n * distribution.\n * * Neither the name of Google Inc. nor the names of its\n * contributors may be used to endorse or promote products derived from\n * this software without specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n * \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nimport * as ArrayUtilities from './array-utilities.js';\nimport * as DateUtilities from './date-utilities.js';\nimport * as DevToolsPath from './DevToolsPath.js';\nimport * as DOMUtilities from './dom-utilities.js';\nimport * as KeyboardUtilities from './keyboard-utilities.js';\nimport * as MapUtilities from './map-utilities.js';\nimport * as NumberUtilities from './number-utilities.js';\nimport * as SetUtilities from './set-utilities.js';\nimport * as StringUtilities from './string-utilities.js';\nimport * as TypeScriptUtilities from './typescript-utilities.js';\nimport * as UIString from './UIString.js';\nimport * as UserVisibleError from './UserVisibleError.js';\n\nexport {DCHECK} from './dcheck.js';\n/* `assertNotNull` also need to be exposed, as TypeScript does not\n * allow `asserts` functions to be used with qualified access\n * (e.g. `Platform.TypeScriptUtilities.assertNotNull` causes a\n * compiler error)\n */\nexport {assertNever, assertNotNullOrUndefined, assertUnhandled} from './typescript-utilities.js';\nexport {\n ArrayUtilities,\n DateUtilities,\n DevToolsPath,\n DOMUtilities,\n KeyboardUtilities,\n MapUtilities,\n NumberUtilities,\n SetUtilities,\n StringUtilities,\n TypeScriptUtilities,\n UIString,\n UserVisibleError,\n};\n"]}
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2019 Google Inc. All rights reserved.
|
|
3
|
-
*
|
|
4
|
-
* Redistribution and use in source and binary forms, with or without
|
|
5
|
-
* modification, are permitted provided that the following conditions are
|
|
6
|
-
* met:
|
|
7
|
-
*
|
|
8
|
-
* * Redistributions of source code must retain the above copyright
|
|
9
|
-
* notice, this list of conditions and the following disclaimer.
|
|
10
|
-
* * Redistributions in binary form must reproduce the above
|
|
11
|
-
* copyright notice, this list of conditions and the following disclaimer
|
|
12
|
-
* in the documentation and/or other materials provided with the
|
|
13
|
-
* distribution.
|
|
14
|
-
* * Neither the name of Google Inc. nor the names of its
|
|
15
|
-
* contributors may be used to endorse or promote products derived from
|
|
16
|
-
* this software without specific prior written permission.
|
|
17
|
-
*
|
|
18
|
-
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
19
|
-
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
20
|
-
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
21
|
-
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
22
|
-
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
23
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
24
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
25
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
26
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
27
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
28
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
29
|
-
*/
|
|
30
|
-
|
|
31
|
-
import * as ArrayUtilities from './array-utilities.js';
|
|
32
|
-
import * as DateUtilities from './date-utilities.js';
|
|
33
|
-
import * as DevToolsPath from './DevToolsPath.js';
|
|
34
|
-
import * as DOMUtilities from './dom-utilities.js';
|
|
35
|
-
import * as KeyboardUtilities from './keyboard-utilities.js';
|
|
36
|
-
import * as MapUtilities from './map-utilities.js';
|
|
37
|
-
import * as NumberUtilities from './number-utilities.js';
|
|
38
|
-
import * as SetUtilities from './set-utilities.js';
|
|
39
|
-
import * as StringUtilities from './string-utilities.js';
|
|
40
|
-
import * as TypeScriptUtilities from './typescript-utilities.js';
|
|
41
|
-
import * as UIString from './UIString.js';
|
|
42
|
-
import * as UserVisibleError from './UserVisibleError.js';
|
|
43
|
-
|
|
44
|
-
export {DCHECK} from './dcheck.js';
|
|
45
|
-
/* `assertNotNull` also need to be exposed, as TypeScript does not
|
|
46
|
-
* allow `asserts` functions to be used with qualified access
|
|
47
|
-
* (e.g. `Platform.TypeScriptUtilities.assertNotNull` causes a
|
|
48
|
-
* compiler error)
|
|
49
|
-
*/
|
|
50
|
-
export {assertNever, assertNotNullOrUndefined, assertUnhandled} from './typescript-utilities.js';
|
|
51
|
-
export {
|
|
52
|
-
ArrayUtilities,
|
|
53
|
-
DateUtilities,
|
|
54
|
-
DevToolsPath,
|
|
55
|
-
DOMUtilities,
|
|
56
|
-
KeyboardUtilities,
|
|
57
|
-
MapUtilities,
|
|
58
|
-
NumberUtilities,
|
|
59
|
-
SetUtilities,
|
|
60
|
-
StringUtilities,
|
|
61
|
-
TypeScriptUtilities,
|
|
62
|
-
UIString,
|
|
63
|
-
UserVisibleError,
|
|
64
|
-
};
|
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import * as SDK from "../../core/sdk/sdk.js";
|
|
2
|
-
const domLookUpSingleNodeCache = /* @__PURE__ */ new Map();
|
|
3
|
-
const domLookUpBatchNodesCache = /* @__PURE__ */ new Map();
|
|
4
|
-
export function _TEST_clearCache() {
|
|
5
|
-
domLookUpSingleNodeCache.clear();
|
|
6
|
-
domLookUpBatchNodesCache.clear();
|
|
7
|
-
layoutShiftSourcesCache.clear();
|
|
8
|
-
normalizedLayoutShiftNodesCache.clear();
|
|
9
|
-
}
|
|
10
|
-
export async function domNodeForBackendNodeID(modelData, nodeId) {
|
|
11
|
-
const fromCache = domLookUpSingleNodeCache.get(modelData)?.get(nodeId);
|
|
12
|
-
if (fromCache !== void 0) {
|
|
13
|
-
return fromCache;
|
|
14
|
-
}
|
|
15
|
-
const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();
|
|
16
|
-
const domModel = target?.model(SDK.DOMModel.DOMModel);
|
|
17
|
-
if (!domModel) {
|
|
18
|
-
return null;
|
|
19
|
-
}
|
|
20
|
-
const domNodesMap = await domModel.pushNodesByBackendIdsToFrontend(/* @__PURE__ */ new Set([nodeId]));
|
|
21
|
-
const result = domNodesMap?.get(nodeId) || null;
|
|
22
|
-
const cacheForModel = domLookUpSingleNodeCache.get(modelData) || /* @__PURE__ */ new Map();
|
|
23
|
-
cacheForModel.set(nodeId, result);
|
|
24
|
-
domLookUpSingleNodeCache.set(modelData, cacheForModel);
|
|
25
|
-
return result;
|
|
26
|
-
}
|
|
27
|
-
export async function domNodesForMultipleBackendNodeIds(modelData, nodeIds) {
|
|
28
|
-
const fromCache = domLookUpBatchNodesCache.get(modelData)?.get(nodeIds);
|
|
29
|
-
if (fromCache) {
|
|
30
|
-
return fromCache;
|
|
31
|
-
}
|
|
32
|
-
const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();
|
|
33
|
-
const domModel = target?.model(SDK.DOMModel.DOMModel);
|
|
34
|
-
if (!domModel) {
|
|
35
|
-
return /* @__PURE__ */ new Map();
|
|
36
|
-
}
|
|
37
|
-
const domNodesMap = await domModel.pushNodesByBackendIdsToFrontend(nodeIds) || /* @__PURE__ */ new Map();
|
|
38
|
-
const cacheForModel = domLookUpBatchNodesCache.get(modelData) || /* @__PURE__ */ new Map();
|
|
39
|
-
cacheForModel.set(nodeIds, domNodesMap);
|
|
40
|
-
domLookUpBatchNodesCache.set(modelData, cacheForModel);
|
|
41
|
-
return domNodesMap;
|
|
42
|
-
}
|
|
43
|
-
const layoutShiftSourcesCache = /* @__PURE__ */ new Map();
|
|
44
|
-
const normalizedLayoutShiftNodesCache = /* @__PURE__ */ new Map();
|
|
45
|
-
export async function sourcesForLayoutShift(modelData, event) {
|
|
46
|
-
const fromCache = layoutShiftSourcesCache.get(modelData)?.get(event);
|
|
47
|
-
if (fromCache) {
|
|
48
|
-
return fromCache;
|
|
49
|
-
}
|
|
50
|
-
const impactedNodes = event.args.data?.impacted_nodes;
|
|
51
|
-
if (!impactedNodes) {
|
|
52
|
-
return [];
|
|
53
|
-
}
|
|
54
|
-
const sources = [];
|
|
55
|
-
await Promise.all(impactedNodes.map(async (node) => {
|
|
56
|
-
const domNode = await domNodeForBackendNodeID(modelData, node.node_id);
|
|
57
|
-
if (domNode) {
|
|
58
|
-
sources.push({
|
|
59
|
-
previousRect: new DOMRect(node.old_rect[0], node.old_rect[1], node.old_rect[2], node.old_rect[3]),
|
|
60
|
-
currentRect: new DOMRect(node.new_rect[0], node.new_rect[1], node.new_rect[2], node.new_rect[3]),
|
|
61
|
-
node: domNode
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
}));
|
|
65
|
-
const cacheForModel = layoutShiftSourcesCache.get(modelData) || /* @__PURE__ */ new Map();
|
|
66
|
-
cacheForModel.set(event, sources);
|
|
67
|
-
layoutShiftSourcesCache.set(modelData, cacheForModel);
|
|
68
|
-
return sources;
|
|
69
|
-
}
|
|
70
|
-
export async function normalizedImpactedNodesForLayoutShift(modelData, event) {
|
|
71
|
-
const fromCache = normalizedLayoutShiftNodesCache.get(modelData)?.get(event);
|
|
72
|
-
if (fromCache) {
|
|
73
|
-
return fromCache;
|
|
74
|
-
}
|
|
75
|
-
const impactedNodes = event.args?.data?.impacted_nodes;
|
|
76
|
-
if (!impactedNodes) {
|
|
77
|
-
return [];
|
|
78
|
-
}
|
|
79
|
-
let viewportScale = null;
|
|
80
|
-
const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();
|
|
81
|
-
const evaluateResult = await target?.runtimeAgent().invoke_evaluate({ expression: "window.devicePixelRatio" });
|
|
82
|
-
if (evaluateResult?.result.type === "number") {
|
|
83
|
-
viewportScale = evaluateResult?.result.value ?? null;
|
|
84
|
-
}
|
|
85
|
-
if (!viewportScale) {
|
|
86
|
-
return impactedNodes;
|
|
87
|
-
}
|
|
88
|
-
const normalizedNodes = [];
|
|
89
|
-
for (const impactedNode of impactedNodes) {
|
|
90
|
-
const newNode = { ...impactedNode };
|
|
91
|
-
for (let i = 0; i < impactedNode.old_rect.length; i++) {
|
|
92
|
-
newNode.old_rect[i] /= viewportScale;
|
|
93
|
-
}
|
|
94
|
-
for (let i = 0; i < impactedNode.new_rect.length; i++) {
|
|
95
|
-
newNode.new_rect[i] /= viewportScale;
|
|
96
|
-
}
|
|
97
|
-
normalizedNodes.push(newNode);
|
|
98
|
-
}
|
|
99
|
-
const cacheForModel = normalizedLayoutShiftNodesCache.get(modelData) || /* @__PURE__ */ new Map();
|
|
100
|
-
cacheForModel.set(event, normalizedNodes);
|
|
101
|
-
normalizedLayoutShiftNodesCache.set(modelData, cacheForModel);
|
|
102
|
-
return normalizedNodes;
|
|
103
|
-
}
|
|
104
|
-
//# sourceMappingURL=SDKServices.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../front_end/models/trace/SDKServices.ts"],
|
|
4
|
-
"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.\n\nimport type * as Protocol from '../../generated/protocol.js';\nimport * as SDK from '../../core/sdk/sdk.js';\nimport type * as Handlers from './handlers/handlers.js';\nimport type * as Types from './types/types.js';\n\nconst domLookUpSingleNodeCache =\n new Map<Handlers.Types.TraceParseData, Map<Protocol.DOM.BackendNodeId, SDK.DOMModel.DOMNode|null>>();\nconst domLookUpBatchNodesCache = new Map<\n Handlers.Types.TraceParseData,\n Map<Set<Protocol.DOM.BackendNodeId>, Map<Protocol.DOM.BackendNodeId, SDK.DOMModel.DOMNode|null>>>();\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function _TEST_clearCache(): void {\n domLookUpSingleNodeCache.clear();\n domLookUpBatchNodesCache.clear();\n layoutShiftSourcesCache.clear();\n normalizedLayoutShiftNodesCache.clear();\n}\n\n/**\n * Looks up the DOM Node on the page for the given BackendNodeId. Uses the\n * provided TraceParseData as the cache and will cache the result after the\n * first lookup.\n */\nexport async function domNodeForBackendNodeID(\n modelData: Handlers.Types.TraceParseData, nodeId: Protocol.DOM.BackendNodeId): Promise<SDK.DOMModel.DOMNode|null> {\n const fromCache = domLookUpSingleNodeCache.get(modelData)?.get(nodeId);\n if (fromCache !== undefined) {\n return fromCache;\n }\n\n const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();\n const domModel = target?.model(SDK.DOMModel.DOMModel);\n if (!domModel) {\n return null;\n }\n\n const domNodesMap = await domModel.pushNodesByBackendIdsToFrontend(new Set([nodeId]));\n const result = domNodesMap?.get(nodeId) || null;\n\n const cacheForModel =\n domLookUpSingleNodeCache.get(modelData) || new Map<Protocol.DOM.BackendNodeId, SDK.DOMModel.DOMNode|null>();\n cacheForModel.set(nodeId, result);\n domLookUpSingleNodeCache.set(modelData, cacheForModel);\n\n return result;\n}\n\n/**\n * Takes a set of Protocol.DOM.BackendNodeId ids and will return a map of NodeId=>DOMNode.\n * Results are cached based on 1) the provided TraceParseData and 2) the provided set of IDs.\n */\nexport async function domNodesForMultipleBackendNodeIds(\n modelData: Handlers.Types.TraceParseData,\n nodeIds: Set<Protocol.DOM.BackendNodeId>): Promise<Map<Protocol.DOM.BackendNodeId, SDK.DOMModel.DOMNode|null>> {\n const fromCache = domLookUpBatchNodesCache.get(modelData)?.get(nodeIds);\n if (fromCache) {\n return fromCache;\n }\n const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();\n const domModel = target?.model(SDK.DOMModel.DOMModel);\n if (!domModel) {\n return new Map();\n }\n\n const domNodesMap = await domModel.pushNodesByBackendIdsToFrontend(nodeIds) || new Map();\n\n const cacheForModel = domLookUpBatchNodesCache.get(modelData) ||\n new Map<Set<Protocol.DOM.BackendNodeId>, Map<Protocol.DOM.BackendNodeId, SDK.DOMModel.DOMNode|null>>();\n cacheForModel.set(nodeIds, domNodesMap);\n domLookUpBatchNodesCache.set(modelData, cacheForModel);\n\n return domNodesMap;\n}\n\nconst layoutShiftSourcesCache = new Map<\n Handlers.Types.TraceParseData, Map<Types.TraceEvents.TraceEventLayoutShift, readonly LayoutShiftSource[]>>();\n\nconst normalizedLayoutShiftNodesCache = new Map<\n Handlers.Types.TraceParseData,\n Map<Types.TraceEvents.TraceEventLayoutShift, readonly Types.TraceEvents.TraceImpactedNode[]>>();\n\nexport interface LayoutShiftSource {\n previousRect: DOMRect;\n currentRect: DOMRect;\n node: SDK.DOMModel.DOMNode;\n}\n\n/**\n * Calculates and returns a list of sources for a LayoutShift.\n * Here, a source is considered as a node that moved and contributed to the\n * given LayoutShift existing and the score it was given. Each source returned\n * contains a reference to the DOM Node, and its dimensions (as a DOMRect), both\n * before and now, so we can see how this node changed and how that impacted the\n * layout shift.\n *\n * This data is cached based on the provided model data and the given layout\n * shift, so it is is safe to call multiple times with the same input.\n */\nexport async function sourcesForLayoutShift(\n modelData: Handlers.Types.TraceParseData,\n event: Types.TraceEvents.TraceEventLayoutShift): Promise<readonly LayoutShiftSource[]> {\n const fromCache = layoutShiftSourcesCache.get(modelData)?.get(event);\n if (fromCache) {\n return fromCache;\n }\n const impactedNodes = event.args.data?.impacted_nodes;\n if (!impactedNodes) {\n return [];\n }\n const sources: LayoutShiftSource[] = [];\n await Promise.all(impactedNodes.map(async node => {\n const domNode = await domNodeForBackendNodeID(modelData, node.node_id);\n if (domNode) {\n sources.push({\n previousRect: new DOMRect(node.old_rect[0], node.old_rect[1], node.old_rect[2], node.old_rect[3]),\n currentRect: new DOMRect(node.new_rect[0], node.new_rect[1], node.new_rect[2], node.new_rect[3]),\n node: domNode,\n });\n }\n }));\n const cacheForModel =\n layoutShiftSourcesCache.get(modelData) || new Map<Types.TraceEvents.TraceEventLayoutShift, LayoutShiftSource[]>();\n cacheForModel.set(event, sources);\n layoutShiftSourcesCache.set(modelData, cacheForModel);\n return sources;\n}\n\n/**\n * Takes a LayoutShift and normalizes its node dimensions based on the device\n * pixel ratio (DPR) of the user's display.\n * This is required because the Layout Instability API is not based on CSS\n * pixels, but physical pixels. Therefore we need to map these to normalized CSS\n * pixels if we can. For example, if the user is on a device with a DPR of 2,\n * the values of the node dimensions reported by the Instability API need to be\n * divided by 2 to be accurate.\n * This function is safe to call multiple times as results are cached based on\n * the provided model data.\n * See https://crbug.com/1300309 for details.\n */\nexport async function normalizedImpactedNodesForLayoutShift(\n modelData: Handlers.Types.TraceParseData,\n event: Types.TraceEvents.TraceEventLayoutShift): Promise<readonly Types.TraceEvents.TraceImpactedNode[]> {\n const fromCache = normalizedLayoutShiftNodesCache.get(modelData)?.get(event);\n if (fromCache) {\n return fromCache;\n }\n const impactedNodes = event.args?.data?.impacted_nodes;\n if (!impactedNodes) {\n return [];\n }\n\n let viewportScale: number|null = null;\n const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();\n // Get the CSS-to-physical pixel ratio of the device the inspected\n // target is running at.\n const evaluateResult = await target?.runtimeAgent().invoke_evaluate({expression: 'window.devicePixelRatio'});\n if (evaluateResult?.result.type === 'number') {\n viewportScale = evaluateResult?.result.value as number ?? null;\n }\n\n if (!viewportScale) {\n // Bail and return the nodes as is.\n return impactedNodes;\n }\n\n const normalizedNodes: Types.TraceEvents.TraceImpactedNode[] = [];\n for (const impactedNode of impactedNodes) {\n const newNode = {...impactedNode};\n for (let i = 0; i < impactedNode.old_rect.length; i++) {\n newNode.old_rect[i] /= viewportScale;\n }\n for (let i = 0; i < impactedNode.new_rect.length; i++) {\n newNode.new_rect[i] /= viewportScale;\n }\n normalizedNodes.push(newNode);\n }\n\n const cacheForModel = normalizedLayoutShiftNodesCache.get(modelData) ||\n new Map<Types.TraceEvents.TraceEventLayoutShift, readonly Types.TraceEvents.TraceImpactedNode[]>();\n cacheForModel.set(event, normalizedNodes);\n normalizedLayoutShiftNodesCache.set(modelData, cacheForModel);\n\n return normalizedNodes;\n}\n"],
|
|
5
|
-
"mappings": "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",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
import { TraceParseEvent } from "./ModelImpl.js";
|
|
2
|
-
var Status = /* @__PURE__ */ ((Status2) => {
|
|
3
|
-
Status2[Status2["IDLE"] = 0] = "IDLE";
|
|
4
|
-
Status2[Status2["PARSING"] = 1] = "PARSING";
|
|
5
|
-
Status2[Status2["FINISHED_PARSING"] = 2] = "FINISHED_PARSING";
|
|
6
|
-
Status2[Status2["ERRORED_WHILE_PARSING"] = 3] = "ERRORED_WHILE_PARSING";
|
|
7
|
-
return Status2;
|
|
8
|
-
})(Status || {});
|
|
9
|
-
export class TraceProcessor extends EventTarget {
|
|
10
|
-
#traceHandlers;
|
|
11
|
-
#pauseDuration;
|
|
12
|
-
#pauseFrequencyMs;
|
|
13
|
-
#status = 0 /* IDLE */;
|
|
14
|
-
constructor(traceHandlers, { pauseDuration = 20, pauseFrequencyMs = 100 } = {}) {
|
|
15
|
-
super();
|
|
16
|
-
this.#traceHandlers = traceHandlers;
|
|
17
|
-
this.#pauseDuration = pauseDuration;
|
|
18
|
-
this.#pauseFrequencyMs = pauseFrequencyMs;
|
|
19
|
-
}
|
|
20
|
-
reset() {
|
|
21
|
-
if (this.#status === 1 /* PARSING */) {
|
|
22
|
-
throw new Error("Trace processor can't reset while parsing.");
|
|
23
|
-
}
|
|
24
|
-
const handlers = Object.values(this.#traceHandlers);
|
|
25
|
-
for (const handler of handlers) {
|
|
26
|
-
handler.reset();
|
|
27
|
-
}
|
|
28
|
-
this.#status = 0 /* IDLE */;
|
|
29
|
-
}
|
|
30
|
-
async parse(traceEvents, freshRecording = false) {
|
|
31
|
-
if (this.#status !== 0 /* IDLE */) {
|
|
32
|
-
throw new Error("Trace processor can't start parsing when not idle.");
|
|
33
|
-
}
|
|
34
|
-
try {
|
|
35
|
-
this.#status = 1 /* PARSING */;
|
|
36
|
-
await this.#parse(traceEvents, freshRecording);
|
|
37
|
-
this.#status = 2 /* FINISHED_PARSING */;
|
|
38
|
-
} catch (e) {
|
|
39
|
-
this.#status = 3 /* ERRORED_WHILE_PARSING */;
|
|
40
|
-
throw e;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
async #parse(traceEvents, freshRecording) {
|
|
44
|
-
const traceEventIterator = new TraceEventIterator(traceEvents, this.#pauseDuration, this.#pauseFrequencyMs);
|
|
45
|
-
const sortedHandlers = [...sortHandlers(this.#traceHandlers).values()];
|
|
46
|
-
for (const handler of sortedHandlers) {
|
|
47
|
-
handler.reset();
|
|
48
|
-
}
|
|
49
|
-
for (const handler of sortedHandlers) {
|
|
50
|
-
handler.initialize?.(freshRecording);
|
|
51
|
-
}
|
|
52
|
-
for await (const item of traceEventIterator) {
|
|
53
|
-
if (item.kind === IteratorItemType.STATUS_UPDATE) {
|
|
54
|
-
this.dispatchEvent(new TraceParseEvent(item.data));
|
|
55
|
-
continue;
|
|
56
|
-
}
|
|
57
|
-
for (const handler of sortedHandlers) {
|
|
58
|
-
handler.handleEvent(item.data);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
for (const handler of sortedHandlers) {
|
|
62
|
-
await handler.finalize?.();
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
get data() {
|
|
66
|
-
if (this.#status !== 2 /* FINISHED_PARSING */) {
|
|
67
|
-
return null;
|
|
68
|
-
}
|
|
69
|
-
const data = {};
|
|
70
|
-
for (const [name, handler] of Object.entries(this.#traceHandlers)) {
|
|
71
|
-
Object.assign(data, { [name]: handler.data() });
|
|
72
|
-
}
|
|
73
|
-
return data;
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
export function sortHandlers(traceHandlers) {
|
|
77
|
-
const sortedMap = /* @__PURE__ */ new Map();
|
|
78
|
-
const visited = /* @__PURE__ */ new Set();
|
|
79
|
-
const visitHandler = (handlerName) => {
|
|
80
|
-
if (sortedMap.has(handlerName)) {
|
|
81
|
-
return;
|
|
82
|
-
}
|
|
83
|
-
if (visited.has(handlerName)) {
|
|
84
|
-
let stackPath = "";
|
|
85
|
-
for (const handler2 of visited) {
|
|
86
|
-
if (stackPath || handler2 === handlerName) {
|
|
87
|
-
stackPath += `${handler2}->`;
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
stackPath += handlerName;
|
|
91
|
-
throw new Error(`Found dependency cycle in trace event handlers: ${stackPath}`);
|
|
92
|
-
}
|
|
93
|
-
visited.add(handlerName);
|
|
94
|
-
const handler = traceHandlers[handlerName];
|
|
95
|
-
if (!handler) {
|
|
96
|
-
return;
|
|
97
|
-
}
|
|
98
|
-
const deps = handler.deps?.();
|
|
99
|
-
if (deps) {
|
|
100
|
-
deps.forEach(visitHandler);
|
|
101
|
-
}
|
|
102
|
-
sortedMap.set(handlerName, handler);
|
|
103
|
-
};
|
|
104
|
-
for (const handlerName of Object.keys(traceHandlers)) {
|
|
105
|
-
visitHandler(handlerName);
|
|
106
|
-
}
|
|
107
|
-
return sortedMap;
|
|
108
|
-
}
|
|
109
|
-
var IteratorItemType = /* @__PURE__ */ ((IteratorItemType2) => {
|
|
110
|
-
IteratorItemType2[IteratorItemType2["TRACE_EVENT"] = 1] = "TRACE_EVENT";
|
|
111
|
-
IteratorItemType2[IteratorItemType2["STATUS_UPDATE"] = 2] = "STATUS_UPDATE";
|
|
112
|
-
return IteratorItemType2;
|
|
113
|
-
})(IteratorItemType || {});
|
|
114
|
-
class TraceEventIterator {
|
|
115
|
-
constructor(traceEvents, pauseDuration, pauseFrequencyMs) {
|
|
116
|
-
this.traceEvents = traceEvents;
|
|
117
|
-
this.pauseDuration = pauseDuration;
|
|
118
|
-
this.pauseFrequencyMs = pauseFrequencyMs;
|
|
119
|
-
this.#time = performance.now();
|
|
120
|
-
}
|
|
121
|
-
#time;
|
|
122
|
-
async *[Symbol.asyncIterator]() {
|
|
123
|
-
for (let i = 0, length = this.traceEvents.length; i < length; i++) {
|
|
124
|
-
if (performance.now() - this.#time > this.pauseFrequencyMs) {
|
|
125
|
-
this.#time = performance.now();
|
|
126
|
-
yield { kind: 2 /* STATUS_UPDATE */, data: { index: i, total: length } };
|
|
127
|
-
await new Promise((resolve) => setTimeout(resolve, this.pauseDuration));
|
|
128
|
-
}
|
|
129
|
-
yield { kind: 1 /* TRACE_EVENT */, data: this.traceEvents[i] };
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
//# sourceMappingURL=TraceProcessor.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../front_end/models/trace/TraceProcessor.ts"],
|
|
4
|
-
"sourcesContent": ["// Copyright 2022 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.\n\nimport type * as Handlers from './handlers/handlers.js';\nimport type * as Types from './types/types.js';\n\nimport {type TraceParseEventProgressData, TraceParseEvent} from './ModelImpl.js';\nconst enum Status {\n IDLE = 0,\n PARSING = 1,\n FINISHED_PARSING = 2,\n ERRORED_WHILE_PARSING = 3,\n}\n\nexport class TraceProcessor<ModelHandlers extends {[key: string]: Handlers.Types.TraceEventHandler}> extends\n EventTarget {\n readonly #traceHandlers: {[key: string]: Handlers.Types.TraceEventHandler};\n #pauseDuration: number;\n #pauseFrequencyMs: number;\n #status = Status.IDLE;\n\n constructor(traceHandlers: ModelHandlers, {pauseDuration = 20, pauseFrequencyMs = 100} = {}) {\n super();\n\n this.#traceHandlers = traceHandlers;\n this.#pauseDuration = pauseDuration;\n this.#pauseFrequencyMs = pauseFrequencyMs;\n }\n\n reset(): void {\n if (this.#status === Status.PARSING) {\n throw new Error('Trace processor can\\'t reset while parsing.');\n }\n\n const handlers = Object.values(this.#traceHandlers);\n for (const handler of handlers) {\n handler.reset();\n }\n\n this.#status = Status.IDLE;\n }\n\n async parse(traceEvents: readonly Types.TraceEvents.TraceEventData[], freshRecording = false): Promise<void> {\n if (this.#status !== Status.IDLE) {\n throw new Error('Trace processor can\\'t start parsing when not idle.');\n }\n try {\n this.#status = Status.PARSING;\n await this.#parse(traceEvents, freshRecording);\n this.#status = Status.FINISHED_PARSING;\n } catch (e) {\n this.#status = Status.ERRORED_WHILE_PARSING;\n throw e;\n }\n }\n\n async #parse(traceEvents: readonly Types.TraceEvents.TraceEventData[], freshRecording: boolean): Promise<void> {\n // This iterator steps through all events, periodically yielding back to the\n // main thread to avoid blocking execution. It uses `dispatchEvent` to\n // provide status update events, and other various bits of config like the\n // pause duration and frequency.\n const traceEventIterator = new TraceEventIterator(traceEvents, this.#pauseDuration, this.#pauseFrequencyMs);\n\n // Convert to array so that we are able to iterate all handlers multiple times.\n const sortedHandlers = [...sortHandlers(this.#traceHandlers).values()];\n // Reset.\n for (const handler of sortedHandlers) {\n handler.reset();\n }\n\n // Initialize.\n for (const handler of sortedHandlers) {\n handler.initialize?.(freshRecording);\n }\n\n // Handle each event.\n for await (const item of traceEventIterator) {\n if (item.kind === IteratorItemType.STATUS_UPDATE) {\n this.dispatchEvent(new TraceParseEvent(item.data));\n continue;\n }\n for (const handler of sortedHandlers) {\n handler.handleEvent(item.data);\n }\n }\n\n // Finalize.\n for (const handler of sortedHandlers) {\n await handler.finalize?.();\n }\n }\n\n get data(): Handlers.Types.HandlerData<ModelHandlers>|null {\n if (this.#status !== Status.FINISHED_PARSING) {\n return null;\n }\n\n const data = {};\n for (const [name, handler] of Object.entries(this.#traceHandlers)) {\n Object.assign(data, {[name]: handler.data()});\n }\n\n return data as Handlers.Types.HandlerData<ModelHandlers>;\n }\n}\n\n/**\n * Some Handlers need data provided by others. Dependencies of a handler handler are\n * declared in the `deps` field.\n * @returns A map from trace event handler name to trace event hander whose entries\n * iterate in such a way that each handler is visited after its dependencies.\n */\nexport function sortHandlers(\n traceHandlers: Partial<{[key in Handlers.Types.TraceEventHandlerName]: Handlers.Types.TraceEventHandler}>):\n Map<Handlers.Types.TraceEventHandlerName, Handlers.Types.TraceEventHandler> {\n const sortedMap = new Map<Handlers.Types.TraceEventHandlerName, Handlers.Types.TraceEventHandler>();\n const visited = new Set<Handlers.Types.TraceEventHandlerName>();\n const visitHandler = (handlerName: Handlers.Types.TraceEventHandlerName): void => {\n if (sortedMap.has(handlerName)) {\n return;\n }\n if (visited.has(handlerName)) {\n let stackPath = '';\n for (const handler of visited) {\n if (stackPath || handler === handlerName) {\n stackPath += `${handler}->`;\n }\n }\n stackPath += handlerName;\n throw new Error(`Found dependency cycle in trace event handlers: ${stackPath}`);\n }\n visited.add(handlerName);\n const handler = traceHandlers[handlerName];\n if (!handler) {\n return;\n }\n const deps = handler.deps?.();\n if (deps) {\n deps.forEach(visitHandler);\n }\n sortedMap.set(handlerName, handler);\n };\n\n for (const handlerName of Object.keys(traceHandlers)) {\n visitHandler(handlerName as Handlers.Types.TraceEventHandlerName);\n }\n return sortedMap;\n}\n\nconst enum IteratorItemType {\n TRACE_EVENT = 1,\n STATUS_UPDATE = 2,\n}\n\ntype IteratorItem = IteratorTraceEventItem|IteratorStatusUpdateItem;\n\ntype IteratorTraceEventItem = {\n kind: IteratorItemType.TRACE_EVENT,\n data: Types.TraceEvents.TraceEventData,\n};\n\ntype IteratorStatusUpdateItem = {\n kind: IteratorItemType.STATUS_UPDATE,\n data: TraceParseEventProgressData,\n};\n\nclass TraceEventIterator {\n #time: number;\n\n constructor(\n private traceEvents: readonly Types.TraceEvents.TraceEventData[], private pauseDuration: number,\n private pauseFrequencyMs: number) {\n this.#time = performance.now();\n }\n\n async * [Symbol.asyncIterator](): AsyncGenerator<IteratorItem, void, void> {\n for (let i = 0, length = this.traceEvents.length; i < length; i++) {\n // Every so often we take a break just to render.\n if (performance.now() - this.#time > this.pauseFrequencyMs) {\n this.#time = performance.now();\n // Take the opportunity to provide status update events.\n yield {kind: IteratorItemType.STATUS_UPDATE, data: {index: i, total: length}};\n // Wait for rendering before resuming.\n await new Promise(resolve => setTimeout(resolve, this.pauseDuration));\n }\n\n yield {kind: IteratorItemType.TRACE_EVENT, data: this.traceEvents[i]};\n }\n }\n}\n"],
|
|
5
|
-
"mappings": "AAOA;AACA,IAAW,SAAX,kBAAW,YAAX;AACE,4BAAO,KAAP;AACA,+BAAU,KAAV;AACA,wCAAmB,KAAnB;AACA,6CAAwB,KAAxB;AAJS;AAAA;AAOJ,oCACH,YAAY;AAAA;AAAA;AAAA;AAAA,YAIJ;AAAA,EAEV,YAAY,eAA8B,EAAC,gBAAgB,IAAI,mBAAmB,QAAO,IAAI;AAC3F;AAEA,0BAAsB;AACtB,0BAAsB;AACtB,6BAAyB;AAAA;AAAA,EAG3B,QAAc;AACZ,QAAI,iBAAiB,iBAAgB;AACnC,YAAM,IAAI,MAAM;AAAA;AAGlB,UAAM,WAAW,OAAO,OAAO;AAC/B,eAAW,WAAW,UAAU;AAC9B,cAAQ;AAAA;AAGV,mBAAe;AAAA;AAAA,QAGX,MAAM,aAA0D,iBAAiB,OAAsB;AAC3G,QAAI,iBAAiB,cAAa;AAChC,YAAM,IAAI,MAAM;AAAA;AAElB,QAAI;AACF,qBAAe;AACf,YAAM,YAAY,aAAa;AAC/B,qBAAe;AAAA,aACR,GAAP;AACA,qBAAe;AACf,YAAM;AAAA;AAAA;AAAA,eAIG,aAA0D,gBAAwC;AAK7G,UAAM,qBAAqB,IAAI,mBAAmB,aAAa,qBAAqB;AAGpF,UAAM,iBAAiB,CAAC,GAAG,aAAa,qBAAqB;AAE7D,eAAW,WAAW,gBAAgB;AACpC,cAAQ;AAAA;AAIV,eAAW,WAAW,gBAAgB;AACpC,cAAQ,aAAa;AAAA;AAIvB,qBAAiB,QAAQ,oBAAoB;AAC3C,UAAI,KAAK,SAAS,iBAAiB,eAAe;AAChD,aAAK,cAAc,IAAI,gBAAgB,KAAK;AAC5C;AAAA;AAEF,iBAAW,WAAW,gBAAgB;AACpC,gBAAQ,YAAY,KAAK;AAAA;AAAA;AAK7B,eAAW,WAAW,gBAAgB;AACpC,YAAM,QAAQ;AAAA;AAAA;AAAA,MAId,OAAuD;AACzD,QAAI,iBAAiB,0BAAyB;AAC5C,aAAO;AAAA;AAGT,UAAM,OAAO;AACb,eAAW,CAAC,MAAM,YAAY,OAAO,QAAQ,sBAAsB;AACjE,aAAO,OAAO,MAAM,GAAE,OAAO,QAAQ;AAAA;AAGvC,WAAO;AAAA;AAAA;AAUJ,6BACH,eAC4E;AAC9E,QAAM,YAAY,oBAAI;AACtB,QAAM,UAAU,oBAAI;AACpB,QAAM,eAAe,CAAC,gBAA4D;AAChF,QAAI,UAAU,IAAI,cAAc;AAC9B;AAAA;AAEF,QAAI,QAAQ,IAAI,cAAc;AAC5B,UAAI,YAAY;AAChB,iBAAW,YAAW,SAAS;AAC7B,YAAI,aAAa,aAAY,aAAa;AACxC,uBAAa,GAAG;AAAA;AAAA;AAGpB,mBAAa;AACb,YAAM,IAAI,MAAM,mDAAmD;AAAA;AAErE,YAAQ,IAAI;AACZ,UAAM,UAAU,cAAc;AAC9B,QAAI,CAAC,SAAS;AACZ;AAAA;AAEF,UAAM,OAAO,QAAQ;AACrB,QAAI,MAAM;AACR,WAAK,QAAQ;AAAA;AAEf,cAAU,IAAI,aAAa;AAAA;AAG7B,aAAW,eAAe,OAAO,KAAK,gBAAgB;AACpD,iBAAa;AAAA;AAEf,SAAO;AAAA;AAGT,IAAW,mBAAX,kBAAW,sBAAX;AACE,uDAAc,KAAd;AACA,yDAAgB,KAAhB;AAFS;AAAA;AAiBX,yBAAyB;AAAA,EAGvB,YACY,aAAkE,eAClE,kBAA0B;AAD1B;AAAkE;AAClE;AACV,iBAAa,YAAY;AAAA;AAAA;AAAA,UAGlB,OAAO,iBAA2D;AACzE,aAAS,IAAI,GAAG,SAAS,KAAK,YAAY,QAAQ,IAAI,QAAQ,KAAK;AAEjE,UAAI,YAAY,QAAQ,aAAa,KAAK,kBAAkB;AAC1D,qBAAa,YAAY;AAEzB,cAAM,EAAC,MAAM,uBAAgC,MAAM,EAAC,OAAO,GAAG,OAAO;AAErE,cAAM,IAAI,QAAQ,aAAW,WAAW,SAAS,KAAK;AAAA;AAGxD,YAAM,EAAC,MAAM,qBAA8B,MAAM,KAAK,YAAY;AAAA;AAAA;AAAA;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import * as Platform from "../../core/platform/platform.js";
|
|
2
|
-
export var TreeAction = /* @__PURE__ */ ((TreeAction2) => {
|
|
3
|
-
TreeAction2["MERGE_FUNCTION"] = "MERGE_FUNCTION";
|
|
4
|
-
TreeAction2["COLLAPSE_FUNCTION"] = "COLLAPSE_FUNCTION";
|
|
5
|
-
return TreeAction2;
|
|
6
|
-
})(TreeAction || {});
|
|
7
|
-
export class TreeManipulator {
|
|
8
|
-
#entryToNode;
|
|
9
|
-
#lastInvisibleEntries = null;
|
|
10
|
-
#activeActions = [];
|
|
11
|
-
constructor(entryToNode) {
|
|
12
|
-
this.#entryToNode = entryToNode;
|
|
13
|
-
}
|
|
14
|
-
applyAction(action) {
|
|
15
|
-
if (this.#actionIsActive(action)) {
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
this.#activeActions.push(action);
|
|
19
|
-
this.#lastInvisibleEntries = null;
|
|
20
|
-
}
|
|
21
|
-
removeActiveAction(action) {
|
|
22
|
-
let removedAction = false;
|
|
23
|
-
this.#activeActions = this.#activeActions.filter((activeAction) => {
|
|
24
|
-
if (activeAction.type === action.type && activeAction.entry === action.entry) {
|
|
25
|
-
removedAction = true;
|
|
26
|
-
return false;
|
|
27
|
-
}
|
|
28
|
-
return true;
|
|
29
|
-
});
|
|
30
|
-
if (removedAction) {
|
|
31
|
-
this.#lastInvisibleEntries = null;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
#actionIsActive(action) {
|
|
35
|
-
return this.#activeActions.some((activeAction) => {
|
|
36
|
-
return action.entry === activeAction.entry && action.type === activeAction.type;
|
|
37
|
-
});
|
|
38
|
-
}
|
|
39
|
-
invisibleEntries() {
|
|
40
|
-
if (this.#activeActions.length === 0) {
|
|
41
|
-
return [];
|
|
42
|
-
}
|
|
43
|
-
return this.#calculateInvisibleEntries();
|
|
44
|
-
}
|
|
45
|
-
#calculateInvisibleEntries() {
|
|
46
|
-
if (this.#lastInvisibleEntries) {
|
|
47
|
-
return this.#lastInvisibleEntries;
|
|
48
|
-
}
|
|
49
|
-
const entriesToHide = /* @__PURE__ */ new Set();
|
|
50
|
-
for (const action of this.#activeActions) {
|
|
51
|
-
switch (action.type) {
|
|
52
|
-
case "MERGE_FUNCTION" /* MERGE_FUNCTION */: {
|
|
53
|
-
entriesToHide.add(action.entry);
|
|
54
|
-
break;
|
|
55
|
-
}
|
|
56
|
-
case "COLLAPSE_FUNCTION" /* COLLAPSE_FUNCTION */: {
|
|
57
|
-
const entryNode = this.#entryToNode.get(action.entry);
|
|
58
|
-
if (!entryNode) {
|
|
59
|
-
continue;
|
|
60
|
-
}
|
|
61
|
-
const allAncestors = this.#findAllAncestorsOfNode(entryNode);
|
|
62
|
-
allAncestors.forEach((ancestor) => entriesToHide.add(ancestor));
|
|
63
|
-
break;
|
|
64
|
-
}
|
|
65
|
-
default:
|
|
66
|
-
Platform.assertNever(action.type, `Unknown TreeManipulator action: ${action.type}`);
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
this.#lastInvisibleEntries = [...entriesToHide];
|
|
70
|
-
return this.#lastInvisibleEntries;
|
|
71
|
-
}
|
|
72
|
-
#findAllAncestorsOfNode(root) {
|
|
73
|
-
const ancestors = [];
|
|
74
|
-
const children = [...root.children];
|
|
75
|
-
while (children.length > 0) {
|
|
76
|
-
const childNode = children.shift();
|
|
77
|
-
if (childNode) {
|
|
78
|
-
ancestors.push(childNode.entry);
|
|
79
|
-
children.push(...childNode.children);
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
return ancestors;
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
//# sourceMappingURL=TreeManipulator.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../front_end/models/trace/TreeManipulator.ts"],
|
|
4
|
-
"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';\n\nimport type * as Helpers from './helpers/helpers.js';\nimport type * as Types from './types/types.js';\n\ntype EntryToNodeMap = Map<Types.TraceEvents.TraceEntry, Helpers.TreeHelpers.TraceEntryNode>;\n\nexport const enum TreeAction {\n MERGE_FUNCTION = 'MERGE_FUNCTION',\n COLLAPSE_FUNCTION = 'COLLAPSE_FUNCTION',\n}\n\nexport interface UserTreeAction {\n type: TreeAction;\n entry: Types.TraceEvents.TraceEntry;\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 TreeManipulator {\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 last calculated set of invisible entries. This means we can avoid\n // re-generating this if the set of actions that have been applied has not\n // changed.\n #lastInvisibleEntries: Types.TraceEvents.TraceEntry[]|null = null;\n #activeActions: UserTreeAction[] = [];\n\n constructor(entryToNode: EntryToNodeMap) {\n this.#entryToNode = entryToNode;\n }\n\n /**\n * Applies an action to the visible tree. This will also clear the cache of\n * invisible entries, ensuring that it will be recalculated with the latest set\n * of actions.\n **/\n applyAction(action: UserTreeAction): void {\n if (this.#actionIsActive(action)) {\n // If the action is already active there is no reason to apply it again.\n return;\n }\n\n this.#activeActions.push(action);\n // Clear the last list of invisible entries - this invalidates the cache and\n // ensures that the invisible list will be recalculated, which we have to do\n // now we have changed the list of actions.\n this.#lastInvisibleEntries = null;\n }\n\n /**\n * Removes a matching action, if one is found, from the active actions set.\n * Note that we do not match on action equality and instead search through\n * the set of active actions for one that is of the same type, and has the\n * same entry associated with it.\n *\n * This is a no-op if the action is not active.\n **/\n removeActiveAction(action: UserTreeAction): void {\n let removedAction = false;\n this.#activeActions = this.#activeActions.filter(activeAction => {\n if (activeAction.type === action.type && activeAction.entry === action.entry) {\n removedAction = true;\n return false;\n }\n return true;\n });\n\n if (removedAction) {\n // If we found and removed an action, we need to clear the cache to force\n // the set of invisible entries to be recalculcated.\n this.#lastInvisibleEntries = null;\n }\n }\n\n #actionIsActive(action: UserTreeAction): boolean {\n return this.#activeActions.some(activeAction => {\n return action.entry === activeAction.entry && action.type === activeAction.type;\n });\n }\n\n /**\n * The set of entries that are invisible given the set of applied actions. If\n * no actions are applied, this will return an empty list of entries.\n *\n * This method is cached, so it is safe to call multiple times.\n **/\n invisibleEntries(): Types.TraceEvents.TraceEventData[] {\n if (this.#activeActions.length === 0) {\n return [];\n }\n return this.#calculateInvisibleEntries();\n }\n\n #calculateInvisibleEntries(): Types.TraceEvents.TraceEventData[] {\n // When an action is added, we clear this cache. So if this cache is\n // present it means that the set of active actions has not changed, and so\n // we do not need to recalculate anything.\n if (this.#lastInvisibleEntries) {\n return this.#lastInvisibleEntries;\n }\n\n // We apply each user action in turn to the set of all entries, and mark\n // any that should be hidden by adding them to this set. We do this to\n // ensure we minimise the amount of passes through the list of all entries.\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.TraceEntry>();\n\n for (const action of this.#activeActions) {\n switch (action.type) {\n case TreeAction.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 break;\n }\n\n case TreeAction.COLLAPSE_FUNCTION: {\n // The entry itself remains visible, but all of its ancestors are hidden.\n const entryNode = this.#entryToNode.get(action.entry);\n if (!entryNode) {\n // Invalid node was given, just ignore and move on.\n continue;\n }\n const allAncestors = this.#findAllAncestorsOfNode(entryNode);\n allAncestors.forEach(ancestor => entriesToHide.add(ancestor));\n break;\n }\n default:\n Platform.assertNever(action.type, `Unknown TreeManipulator action: ${action.type}`);\n }\n }\n\n // Now we have applied all actions, return the invisible entries.\n // We cache this under lastInvisibleEntries - if this function is called\n // again and the user actions have not changed, we can avoid recalculating\n // this and just return the last one. This cache is automatically cleared\n // when the user actions are changed.\n\n this.#lastInvisibleEntries = [...entriesToHide];\n\n return this.#lastInvisibleEntries;\n }\n\n #findAllAncestorsOfNode(root: Helpers.TreeHelpers.TraceEntryNode): Types.TraceEvents.TraceEntry[] {\n const ancestors: Types.TraceEvents.TraceEntry[] = [];\n\n // Walk through all the ancestors, 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 ancestors.push(childNode.entry);\n children.push(...childNode.children);\n }\n }\n\n return ancestors;\n }\n}\n"],
|
|
5
|
-
"mappings": "AAGA;AAOO,WAAW,aAAX,kBAAW,gBAAX;AACL,kCAAiB;AACjB,qCAAoB;AAFJ;AAAA;AAoBX,6BAAsB;AAAA;AAAA,0BASkC;AAAA,mBAC1B;AAAA,EAEnC,YAAY,aAA6B;AACvC,wBAAoB;AAAA;AAAA,EAQtB,YAAY,QAA8B;AACxC,QAAI,qBAAqB,SAAS;AAEhC;AAAA;AAGF,wBAAoB,KAAK;AAIzB,iCAA6B;AAAA;AAAA,EAW/B,mBAAmB,QAA8B;AAC/C,QAAI,gBAAgB;AACpB,0BAAsB,oBAAoB,OAAO,kBAAgB;AAC/D,UAAI,aAAa,SAAS,OAAO,QAAQ,aAAa,UAAU,OAAO,OAAO;AAC5E,wBAAgB;AAChB,eAAO;AAAA;AAET,aAAO;AAAA;AAGT,QAAI,eAAe;AAGjB,mCAA6B;AAAA;AAAA;AAAA,kBAIjB,QAAiC;AAC/C,WAAO,oBAAoB,KAAK,kBAAgB;AAC9C,aAAO,OAAO,UAAU,aAAa,SAAS,OAAO,SAAS,aAAa;AAAA;AAAA;AAAA,EAU/E,mBAAuD;AACrD,QAAI,oBAAoB,WAAW,GAAG;AACpC,aAAO;AAAA;AAET,WAAO;AAAA;AAAA,+BAGwD;AAI/D,QAAI,4BAA4B;AAC9B,aAAO;AAAA;AAST,UAAM,gBAAgB,oBAAI;AAE1B,eAAW,UAAU,qBAAqB;AACxC,cAAQ,OAAO;AAAA,aACR,uCAA2B;AAI9B,wBAAc,IAAI,OAAO;AACzB;AAAA;AAAA,aAGG,6CAA8B;AAEjC,gBAAM,YAAY,kBAAkB,IAAI,OAAO;AAC/C,cAAI,CAAC,WAAW;AAEd;AAAA;AAEF,gBAAM,eAAe,6BAA6B;AAClD,uBAAa,QAAQ,cAAY,cAAc,IAAI;AACnD;AAAA;AAAA;AAGA,mBAAS,YAAY,OAAO,MAAM,mCAAmC,OAAO;AAAA;AAAA;AAUlF,iCAA6B,CAAC,GAAG;AAEjC,WAAO;AAAA;AAAA,0BAGe,MAA0E;AAChG,UAAM,YAA4C;AAGlD,UAAM,WAAiD,CAAC,GAAG,KAAK;AAChE,WAAO,SAAS,SAAS,GAAG;AAC1B,YAAM,YAAY,SAAS;AAC3B,UAAI,WAAW;AACb,kBAAU,KAAK,UAAU;AACzB,iBAAS,KAAK,GAAG,UAAU;AAAA;AAAA;AAI/B,WAAO;AAAA;AAAA;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"allowJs": true,
|
|
4
|
-
"checkJs": true,
|
|
5
|
-
"composite": true,
|
|
6
|
-
"declaration": true,
|
|
7
|
-
"experimentalDecorators": true,
|
|
8
|
-
"forceConsistentCasingInFileNames": true,
|
|
9
|
-
"inlineSources": true,
|
|
10
|
-
"lib": [
|
|
11
|
-
"esnext",
|
|
12
|
-
"dom",
|
|
13
|
-
"dom.iterable"
|
|
14
|
-
],
|
|
15
|
-
"module": "esnext",
|
|
16
|
-
"noEmitOnError": true,
|
|
17
|
-
"noFallthroughCasesInSwitch": true,
|
|
18
|
-
"noImplicitOverride": true,
|
|
19
|
-
"noImplicitReturns": true,
|
|
20
|
-
"noUnusedLocals": false,
|
|
21
|
-
"outDir": ".",
|
|
22
|
-
"rootDir": "../../../../../../front_end/models/trace",
|
|
23
|
-
"skipLibCheck": true,
|
|
24
|
-
"sourceMap": true,
|
|
25
|
-
"strict": true,
|
|
26
|
-
"target": "esnext",
|
|
27
|
-
"tsBuildInfoFile": "devtools_entrypoint-legacy-typescript-tsconfig.json.tsbuildinfo",
|
|
28
|
-
"typeRoots": [],
|
|
29
|
-
"useUnknownInCatchVariables": false
|
|
30
|
-
},
|
|
31
|
-
"files": [
|
|
32
|
-
"../../../../../../front_end/models/trace/trace-legacy.ts",
|
|
33
|
-
"../../../../../../front_end/legacy/legacy-defs.d.ts",
|
|
34
|
-
"../../../../../../front_end/global_typings/global_defs.d.ts",
|
|
35
|
-
"../../../../../../front_end/global_typings/request_idle_callback.d.ts",
|
|
36
|
-
"../../../../../../node_modules/@types/filesystem/index.d.ts"
|
|
37
|
-
],
|
|
38
|
-
"references": [
|
|
39
|
-
{
|
|
40
|
-
"path": "./bundle-tsconfig.json"
|
|
41
|
-
}
|
|
42
|
-
]
|
|
43
|
-
}
|