Skip to content

Commit 22b447a

Browse files
committed
Merge remote-tracking branch 'origin/sum-by-optimization' into sum-by-optimization
2 parents 3d86f99 + ee34187 commit 22b447a

File tree

2 files changed

+7
-15
lines changed

2 files changed

+7
-15
lines changed

ui/packages/shared/profile/src/ProfileSelector/MetricsGraphSection.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ export function MetricsGraphSection({
170170
to={querySelection.to}
171171
profile={profileSelection}
172172
comparing={comparing}
173-
sumBy={sumBy ?? []}
173+
sumBy={sumBy ?? []}
174174
sumByLoading={defaultSumByLoading}
175175
setTimeRange={handleTimeRangeChange}
176176
addLabelMatcher={addLabelMatcher}

ui/packages/shared/profile/src/useSumBy.ts

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,21 +11,13 @@
1111
// See the License for the specific language governing permissions and
1212
// limitations under the License.
1313

14-
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
15-
16-
17-
18-
import { QueryServiceClient } from '@parca/client';
19-
import { DateTimeRange } from '@parca/components';
20-
import { ProfileType } from '@parca/parser';
21-
22-
23-
24-
import { useLabelNames } from './hooks/useLabels';
25-
26-
14+
import {useCallback, useEffect, useMemo, useRef, useState} from 'react';
2715

16+
import {QueryServiceClient} from '@parca/client';
17+
import {DateTimeRange} from '@parca/components';
18+
import {ProfileType} from '@parca/parser';
2819

20+
import {useLabelNames} from './hooks/useLabels';
2921

3022
export const DEFAULT_EMPTY_SUM_BY: string[] = [];
3123

@@ -71,7 +63,7 @@ export const useSumBySelection = (
7163
(labels: string[]) => void,
7264
{
7365
isLoading: boolean;
74-
},
66+
}
7567
] => {
7668
const [userSelectedSumBy, setUserSelectedSumBy] = useState<Record<string, string[] | undefined>>(
7769
profileType != null ? {[profileType.toString()]: defaultValue} : {}

0 commit comments

Comments
 (0)