@parca/profile 0.16.126 → 0.16.128
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
CHANGED
|
@@ -3,6 +3,16 @@
|
|
|
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.16.128 (2023-03-02)
|
|
7
|
+
|
|
8
|
+
# 0.16.0 (2023-03-01)
|
|
9
|
+
|
|
10
|
+
**Note:** Version bump only for package @parca/profile
|
|
11
|
+
|
|
12
|
+
## [0.16.127](https://github.com/parca-dev/parca/compare/@parca/profile@0.16.126...@parca/profile@0.16.127) (2023-03-01)
|
|
13
|
+
|
|
14
|
+
**Note:** Version bump only for package @parca/profile
|
|
15
|
+
|
|
6
16
|
## [0.16.126](https://github.com/parca-dev/parca/compare/@parca/profile@0.16.125...@parca/profile@0.16.126) (2023-02-27)
|
|
7
17
|
|
|
8
18
|
**Note:** Version bump only for package @parca/profile
|
|
@@ -83,7 +83,7 @@ var ProfileExplorerApp = function (_a) {
|
|
|
83
83
|
var profileA = ProfileSelectionFromParams(expression_a, from_a, to_a, mergeFrom, mergeTo, labels, filter_by_function);
|
|
84
84
|
setProfileA(profileA);
|
|
85
85
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
86
|
-
}, [merge_from_a, merge_to_a]);
|
|
86
|
+
}, [merge_from_a, merge_to_a, filter_by_function]);
|
|
87
87
|
useEffect(function () {
|
|
88
88
|
var _a;
|
|
89
89
|
var mergeFrom = merge_from_b !== null && merge_from_b !== void 0 ? merge_from_b : undefined;
|
|
@@ -92,7 +92,7 @@ var ProfileExplorerApp = function (_a) {
|
|
|
92
92
|
var profileB = ProfileSelectionFromParams(expression_b, from_b, to_b, mergeFrom, mergeTo, labels, filter_by_function);
|
|
93
93
|
setProfileB(profileB);
|
|
94
94
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
95
|
-
}, [merge_from_b, merge_to_b]);
|
|
95
|
+
}, [merge_from_b, merge_to_b, filter_by_function]);
|
|
96
96
|
if (profileTypesLoading) {
|
|
97
97
|
return _jsx(_Fragment, { children: loader });
|
|
98
98
|
}
|
|
@@ -11,20 +11,20 @@
|
|
|
11
11
|
// See the License for the specific language governing permissions and
|
|
12
12
|
// limitations under the License.
|
|
13
13
|
import { useMemo } from 'react';
|
|
14
|
-
import { diffColor } from '@parca/functions';
|
|
14
|
+
import { COLOR_PROFILES, diffColor } from '@parca/functions';
|
|
15
15
|
import { EVERYTHING_ELSE, selectDarkMode, selectStackColors, useAppSelector } from '@parca/store';
|
|
16
16
|
var useNodeColor = function (_a) {
|
|
17
17
|
var data = _a.data, compareMode = _a.compareMode;
|
|
18
18
|
var colors = useAppSelector(selectStackColors);
|
|
19
19
|
var isDarkMode = useAppSelector(selectDarkMode);
|
|
20
20
|
var color = useMemo(function () {
|
|
21
|
-
var _a;
|
|
21
|
+
var _a, _b;
|
|
22
22
|
if (compareMode) {
|
|
23
23
|
var diff = parseFloat(data.diff);
|
|
24
24
|
var cumulative = parseFloat(data.cumulative);
|
|
25
25
|
return diffColor(diff, cumulative, isDarkMode);
|
|
26
26
|
}
|
|
27
|
-
var color = colors[(_a = data.feature) !== null && _a !== void 0 ? _a : EVERYTHING_ELSE];
|
|
27
|
+
var color = (_b = colors[(_a = data.feature) !== null && _a !== void 0 ? _a : EVERYTHING_ELSE]) !== null && _b !== void 0 ? _b : (!isDarkMode ? COLOR_PROFILES.default.colors[0][0] : COLOR_PROFILES.default.colors[0][1]);
|
|
28
28
|
return color;
|
|
29
29
|
}, [data, colors, isDarkMode, compareMode]);
|
|
30
30
|
return color;
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parca/profile",
|
|
3
|
-
"version": "0.16.
|
|
3
|
+
"version": "0.16.128",
|
|
4
4
|
"description": "Profile viewing libraries",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@parca/client": "^0.16.
|
|
7
|
-
"@parca/components": "^0.16.
|
|
8
|
-
"@parca/dynamicsize": "^0.16.
|
|
9
|
-
"@parca/functions": "^0.16.
|
|
10
|
-
"@parca/parser": "^0.16.
|
|
11
|
-
"@parca/store": "^0.16.
|
|
6
|
+
"@parca/client": "^0.16.65",
|
|
7
|
+
"@parca/components": "^0.16.106",
|
|
8
|
+
"@parca/dynamicsize": "^0.16.54",
|
|
9
|
+
"@parca/functions": "^0.16.66",
|
|
10
|
+
"@parca/parser": "^0.16.55",
|
|
11
|
+
"@parca/store": "^0.16.62",
|
|
12
12
|
"@types/react-beautiful-dnd": "^13.1.3",
|
|
13
13
|
"d3": "7.8.2",
|
|
14
14
|
"d3-scale": "^4.0.2",
|
|
@@ -45,5 +45,5 @@
|
|
|
45
45
|
"access": "public",
|
|
46
46
|
"registry": "https://registry.npmjs.org/"
|
|
47
47
|
},
|
|
48
|
-
"gitHead": "
|
|
48
|
+
"gitHead": "dd68f2daa5f9656dd3c76c212960ebebe91ef832"
|
|
49
49
|
}
|
|
@@ -131,7 +131,7 @@ const ProfileExplorerApp = ({
|
|
|
131
131
|
|
|
132
132
|
setProfileA(profileA);
|
|
133
133
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
134
|
-
}, [merge_from_a, merge_to_a]);
|
|
134
|
+
}, [merge_from_a, merge_to_a, filter_by_function]);
|
|
135
135
|
|
|
136
136
|
useEffect(() => {
|
|
137
137
|
const mergeFrom = merge_from_b ?? undefined;
|
|
@@ -149,7 +149,7 @@ const ProfileExplorerApp = ({
|
|
|
149
149
|
|
|
150
150
|
setProfileB(profileB);
|
|
151
151
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
152
|
-
}, [merge_from_b, merge_to_b]);
|
|
152
|
+
}, [merge_from_b, merge_to_b, filter_by_function]);
|
|
153
153
|
|
|
154
154
|
if (profileTypesLoading) {
|
|
155
155
|
return <>{loader}</>;
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
|
|
14
14
|
import {useMemo} from 'react';
|
|
15
15
|
|
|
16
|
-
import {diffColor} from '@parca/functions';
|
|
16
|
+
import {COLOR_PROFILES, diffColor} from '@parca/functions';
|
|
17
17
|
import {EVERYTHING_ELSE, selectDarkMode, selectStackColors, useAppSelector} from '@parca/store';
|
|
18
18
|
|
|
19
19
|
import type {ColoredFlamegraphNode} from './useColoredGraph';
|
|
@@ -34,7 +34,10 @@ const useNodeColor = ({data, compareMode}: Props): string => {
|
|
|
34
34
|
return diffColor(diff, cumulative, isDarkMode);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
const color =
|
|
37
|
+
const color =
|
|
38
|
+
colors[data.feature ?? EVERYTHING_ELSE] ??
|
|
39
|
+
(!isDarkMode ? COLOR_PROFILES.default.colors[0][0] : COLOR_PROFILES.default.colors[0][1]);
|
|
40
|
+
|
|
38
41
|
return color;
|
|
39
42
|
}, [data, colors, isDarkMode, compareMode]);
|
|
40
43
|
|