@parca/profile 0.17.4 → 0.17.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/IcicleGraphNodes.d.ts.map +1 -1
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/IcicleGraphNodes.js +7 -2
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/index.d.ts.map +1 -1
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/index.js +12 -1
- package/package.json +2 -2
- package/src/ProfileIcicleGraph/IcicleGraphArrow/IcicleGraphNodes.tsx +7 -2
- package/src/ProfileIcicleGraph/IcicleGraphArrow/index.tsx +12 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.17.5](https://github.com/parca-dev/parca/compare/@parca/profile@0.17.4...@parca/profile@0.17.5) (2025-06-03)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @parca/profile
|
|
9
|
+
|
|
6
10
|
## [0.17.4](https://github.com/parca-dev/parca/compare/@parca/profile@0.17.3...@parca/profile@0.17.4) (2025-06-02)
|
|
7
11
|
|
|
8
12
|
**Note:** Version bump only for package @parca/profile
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IcicleGraphNodes.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/IcicleGraphNodes.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAgB,MAAM,OAAO,CAAC;AAErC,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAMnC,OAAO,yCAAyC,CAAC;AAIjD,OAAO,EAAC,aAAa,EAAC,MAAM,qBAAqB,CAAC;AAgBlD,eAAO,MAAM,SAAS,KAAK,CAAC;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a;IAC5B,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,aAAa,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,OAAO,CAAC;IACrB,aAAa,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,EAAE,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1D,oBAAoB,EAAE,MAAM,CAAC;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,EAAE,OAAO,CAAC;IACvB,aAAa,EAAE,aAAa,CAAC;IAG7B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,KAAK,IAAI,CAAC;CACnD;AAED,eAAO,MAAM,gBAAgB;;;CAG5B,CAAC;AACF,eAAO,MAAM,qBAAqB;;;;CAIjC,CAAC;AAEF,eAAO,MAAM,UAAU,6CAiLrB,CAAC"}
|
|
@@ -47,7 +47,9 @@ export const IcicleNode = React.memo(function IcicleNodeNoMemo({ table, row, col
|
|
|
47
47
|
const diff = diffColumn?.get(row) !== null ? BigInt(diffColumn?.get(row)) : null;
|
|
48
48
|
const filename = arrowToString(filenameColumn?.get(row));
|
|
49
49
|
const depth = depthColumn?.get(row) ?? 0;
|
|
50
|
-
const valueOffset = valueOffsetColumn?.get(row) !== null
|
|
50
|
+
const valueOffset = valueOffsetColumn?.get(row) !== null && valueOffsetColumn?.get(row) !== undefined
|
|
51
|
+
? BigInt(valueOffsetColumn?.get(row))
|
|
52
|
+
: 0n;
|
|
51
53
|
const colorAttribute = colorBy === 'filename' ? filename : colorBy === 'binary' ? mappingFile : null;
|
|
52
54
|
const colorsMap = colors;
|
|
53
55
|
const hoveringName = hoveringRow !== undefined ? arrowToString(functionNameColumn?.get(hoveringRow)) : '';
|
|
@@ -70,7 +72,10 @@ export const IcicleNode = React.memo(function IcicleNodeNoMemo({ table, row, col
|
|
|
70
72
|
}
|
|
71
73
|
return { isHighlightEnabled: true, isHighlighted: isSearchMatch(searchString, name) };
|
|
72
74
|
}, [searchString, name]);
|
|
73
|
-
const selectionOffset = valueOffsetColumn?.get(selectedRow) !== null
|
|
75
|
+
const selectionOffset = valueOffsetColumn?.get(selectedRow) !== null &&
|
|
76
|
+
valueOffsetColumn?.get(selectedRow) !== undefined
|
|
77
|
+
? BigInt(valueOffsetColumn?.get(selectedRow))
|
|
78
|
+
: 0n;
|
|
74
79
|
const selectionCumulative = cumulativeColumn?.get(selectedRow) !== null ? BigInt(cumulativeColumn?.get(selectedRow)) : 0n;
|
|
75
80
|
if (valueOffset + cumulative <= selectionOffset ||
|
|
76
81
|
valueOffset >= selectionOffset + selectionCumulative) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/index.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAqD,MAAM,OAAO,CAAC;AAK1E,OAAO,EAAC,eAAe,EAAC,MAAM,eAAe,CAAC;AAG9C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAE1C,OAAO,EAAc,KAAK,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE/D,OAAO,EAAC,aAAa,EAAC,MAAM,qBAAqB,CAAC;AAGlD,OAAO,EAAwB,aAAa,EAAC,MAAM,oBAAoB,CAAC;AAIxE,OAAO,EACL,gBAAgB,EAMjB,MAAM,SAAS,CAAC;AAEjB,eAAO,MAAM,iBAAiB,gBAAgB,C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W,CAAC;AACrC,eAAO,MAAM,gBAAgB,eAAe,CAAC;AAC7C,eAAO,MAAM,UAAU,SAAS,CAAC;AACjC,eAAO,MAAM,UAAU,SAAS,CAAC;AACjC,eAAO,MAAM,YAAY,WAAW,CAAC;AACrC,eAAO,MAAM,WAAW,UAAU,CAAC;AACnC,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AAEjD,UAAU,qBAAqB;IAC7B,KAAK,EAAE,eAAe,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,aAAa,EAAE,aAAa,CAAC;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,gBAAgB,EAAE,CAAC;IAC5B,UAAU,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,IAAI,CAAC;IAC/C,YAAY,EAAE,OAAO,CAAC;IACtB,wBAAwB,EAAE,MAAM,EAAE,CAAC;IACnC,eAAe,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,eAAO,MAAM,gBAAgB,iBACb,MAAM,EAAE,cACV,OAAO,uBACE,WAAW,KAC/B,aAQF,CAAC;AAEF,eAAO,MAAM,iBAAiB,kBACb,MAAM,EAAE,cACX,OAAO,uBACE,WAAW,KAC/B,aAQF,CAAC;AAeF,eAAO,MAAM,gBAAgB,mDA8N3B,CAAC;AAEH,eAAe,gBAAgB,CAAC"}
|
|
@@ -63,6 +63,17 @@ export const getFilenameColors = (filenamesList, isDarkMode, currentColorProfile
|
|
|
63
63
|
return colors;
|
|
64
64
|
};
|
|
65
65
|
const noop = () => { };
|
|
66
|
+
function getMaxDepth(depthColumn) {
|
|
67
|
+
if (depthColumn === null)
|
|
68
|
+
return 0;
|
|
69
|
+
let max = 0;
|
|
70
|
+
for (const val of depthColumn) {
|
|
71
|
+
const numVal = Number(val);
|
|
72
|
+
if (numVal > max)
|
|
73
|
+
max = numVal;
|
|
74
|
+
}
|
|
75
|
+
return max;
|
|
76
|
+
}
|
|
66
77
|
export const IcicleGraphArrow = memo(function IcicleGraphArrow({ arrow, total, filtered, width, setCurPath, curPath, profileType, profileSource, mappingsListFromMetadata, compareAbsolute, isIcicleChart = false, }) {
|
|
67
78
|
const [highlightSimilarStacksPreference] = useUserPreference(USER_PREFERENCES.HIGHLIGHT_SIMILAR_STACKS.key);
|
|
68
79
|
const [hoveringRow, setHoveringRow] = useState(undefined);
|
|
@@ -155,7 +166,7 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({ arrow, total, f
|
|
|
155
166
|
setCurPath(path);
|
|
156
167
|
};
|
|
157
168
|
const depthColumn = table.getChild(FIELD_DEPTH);
|
|
158
|
-
const maxDepth =
|
|
169
|
+
const maxDepth = getMaxDepth(depthColumn);
|
|
159
170
|
const height = maxDepth * RowHeight;
|
|
160
171
|
// To find the selected row, we must walk the current path and look at which
|
|
161
172
|
// children of the current frame matches the path element exactly. Until the
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parca/profile",
|
|
3
|
-
"version": "0.17.
|
|
3
|
+
"version": "0.17.5",
|
|
4
4
|
"description": "Profile viewing libraries",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@headlessui/react": "^1.7.19",
|
|
@@ -77,5 +77,5 @@
|
|
|
77
77
|
"access": "public",
|
|
78
78
|
"registry": "https://registry.npmjs.org/"
|
|
79
79
|
},
|
|
80
|
-
"gitHead": "
|
|
80
|
+
"gitHead": "859a26525b61192beea3ed997057e6df3d98ea8d"
|
|
81
81
|
}
|
|
@@ -114,7 +114,9 @@ export const IcicleNode = React.memo(function IcicleNodeNoMemo({
|
|
|
114
114
|
const filename: string | null = arrowToString(filenameColumn?.get(row));
|
|
115
115
|
const depth: number = depthColumn?.get(row) ?? 0;
|
|
116
116
|
const valueOffset: bigint =
|
|
117
|
-
valueOffsetColumn?.get(row) !== null
|
|
117
|
+
valueOffsetColumn?.get(row) !== null && valueOffsetColumn?.get(row) !== undefined
|
|
118
|
+
? BigInt(valueOffsetColumn?.get(row))
|
|
119
|
+
: 0n;
|
|
118
120
|
|
|
119
121
|
const colorAttribute =
|
|
120
122
|
colorBy === 'filename' ? filename : colorBy === 'binary' ? mappingFile : null;
|
|
@@ -147,7 +149,10 @@ export const IcicleNode = React.memo(function IcicleNodeNoMemo({
|
|
|
147
149
|
}, [searchString, name]);
|
|
148
150
|
|
|
149
151
|
const selectionOffset =
|
|
150
|
-
valueOffsetColumn?.get(selectedRow) !== null
|
|
152
|
+
valueOffsetColumn?.get(selectedRow) !== null &&
|
|
153
|
+
valueOffsetColumn?.get(selectedRow) !== undefined
|
|
154
|
+
? BigInt(valueOffsetColumn?.get(selectedRow))
|
|
155
|
+
: 0n;
|
|
151
156
|
const selectionCumulative =
|
|
152
157
|
cumulativeColumn?.get(selectedRow) !== null ? BigInt(cumulativeColumn?.get(selectedRow)) : 0n;
|
|
153
158
|
if (
|
|
@@ -106,6 +106,17 @@ export const getFilenameColors = (
|
|
|
106
106
|
|
|
107
107
|
const noop = (): void => {};
|
|
108
108
|
|
|
109
|
+
function getMaxDepth(depthColumn: Vector<any> | null): number {
|
|
110
|
+
if (depthColumn === null) return 0;
|
|
111
|
+
|
|
112
|
+
let max = 0;
|
|
113
|
+
for (const val of depthColumn) {
|
|
114
|
+
const numVal = Number(val);
|
|
115
|
+
if (numVal > max) max = numVal;
|
|
116
|
+
}
|
|
117
|
+
return max;
|
|
118
|
+
}
|
|
119
|
+
|
|
109
120
|
export const IcicleGraphArrow = memo(function IcicleGraphArrow({
|
|
110
121
|
arrow,
|
|
111
122
|
total,
|
|
@@ -237,7 +248,7 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({
|
|
|
237
248
|
};
|
|
238
249
|
|
|
239
250
|
const depthColumn = table.getChild(FIELD_DEPTH);
|
|
240
|
-
const maxDepth =
|
|
251
|
+
const maxDepth = getMaxDepth(depthColumn);
|
|
241
252
|
const height = maxDepth * RowHeight;
|
|
242
253
|
|
|
243
254
|
// To find the selected row, we must walk the current path and look at which
|