@parca/profile 0.16.434 → 0.16.435
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/GraphTooltipArrow/useGraphTooltipMetaInfo/index.d.ts.map +1 -1
- package/dist/GraphTooltipArrow/useGraphTooltipMetaInfo/index.js +3 -3
- package/dist/MatchersInput/index.d.ts +1 -1
- package/dist/MatchersInput/index.d.ts.map +1 -1
- package/dist/MatchersInput/index.js +3 -3
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/index.d.ts.map +1 -1
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/index.js +1 -5
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/utils.d.ts.map +1 -1
- package/dist/ProfileIcicleGraph/IcicleGraphArrow/utils.js +7 -7
- package/dist/ProfileView/index.d.ts +1 -0
- package/dist/ProfileView/index.d.ts.map +1 -1
- package/dist/ProfileView/index.js +1 -1
- package/dist/ProfileViewWithData.d.ts.map +1 -1
- package/dist/ProfileViewWithData.js +5 -0
- package/dist/components/ActionButtons/GroupByDropdown.d.ts +7 -3
- package/dist/components/ActionButtons/GroupByDropdown.d.ts.map +1 -1
- package/dist/components/ActionButtons/GroupByDropdown.js +82 -10
- package/dist/components/VisualisationToolbar/index.d.ts +2 -1
- package/dist/components/VisualisationToolbar/index.d.ts.map +1 -1
- package/dist/components/VisualisationToolbar/index.js +6 -3
- package/dist/styles.css +1 -1
- package/package.json +2 -2
- package/src/GraphTooltipArrow/useGraphTooltipMetaInfo/index.ts +3 -5
- package/src/MatchersInput/index.tsx +4 -3
- package/src/ProfileIcicleGraph/IcicleGraphArrow/index.tsx +1 -5
- package/src/ProfileIcicleGraph/IcicleGraphArrow/utils.ts +11 -10
- package/src/ProfileView/index.tsx +2 -0
- package/src/ProfileViewWithData.tsx +16 -1
- package/src/components/ActionButtons/GroupByDropdown.tsx +227 -19
- package/src/components/VisualisationToolbar/index.tsx +16 -2
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.16.435 (2024-10-14)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @parca/profile
|
|
9
|
+
|
|
6
10
|
## 0.16.434 (2024-10-02)
|
|
7
11
|
|
|
8
12
|
**Note:** Version bump only for package @parca/profile
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/GraphTooltipArrow/useGraphTooltipMetaInfo/index.ts"],"names":[],"mappings":"AAaA,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAoBnC,UAAU,KAAK;IACb,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,UAAU,wBAAwB;IAChC,UAAU,EAAE,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACpC,gBAAgB,EAAE,MAAM,CAAC;IACzB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;CACzB;AAED,eAAO,MAAM,uBAAuB,mBAAkB,KAAK,KAAG,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/GraphTooltipArrow/useGraphTooltipMetaInfo/index.ts"],"names":[],"mappings":"AAaA,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAoBnC,UAAU,KAAK;IACb,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,UAAU,wBAAwB;IAChC,UAAU,EAAE,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACpC,gBAAgB,EAAE,MAAM,CAAC;IACzB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;CACzB;AAED,eAAO,MAAM,uBAAuB,mBAAkB,KAAK,KAAG,wBA4F7D,CAAC"}
|
|
@@ -26,8 +26,8 @@ export const useGraphTooltipMetaInfo = ({ table, row }) => {
|
|
|
26
26
|
const functionSystemName = arrowToString(table.getChild(FIELD_FUNCTION_SYSTEM_NAME)?.get(row)) ?? '';
|
|
27
27
|
const functionStartLine = table.getChild(FIELD_FUNCTION_START_LINE)?.get(row) ?? 0n;
|
|
28
28
|
const lineNumber = locationLine !== 0n ? locationLine : functionStartLine !== 0n ? functionStartLine : undefined;
|
|
29
|
-
const
|
|
30
|
-
const labelColumnNames = table.schema.fields.filter(field => field.name.startsWith(
|
|
29
|
+
const labelPrefix = 'labels.';
|
|
30
|
+
const labelColumnNames = table.schema.fields.filter(field => field.name.startsWith(labelPrefix));
|
|
31
31
|
const { queryServiceClient, enableSourcesView } = useParcaContext();
|
|
32
32
|
const { profileSource } = useProfileViewContext();
|
|
33
33
|
const { isLoading: sourceLoading, response: sourceResponse } = useQuery(queryServiceClient, profileSource, QueryRequest_ReportType.SOURCE, {
|
|
@@ -50,7 +50,7 @@ export const useGraphTooltipMetaInfo = ({ table, row }) => {
|
|
|
50
50
|
const file = getTextForFile();
|
|
51
51
|
const labelPairs = labelColumnNames
|
|
52
52
|
.map((field, i) => [
|
|
53
|
-
labelColumnNames[i].name.slice(
|
|
53
|
+
labelColumnNames[i].name.slice(labelPrefix.length),
|
|
54
54
|
arrowToString(table.getChild(field.name)?.get(row)) ?? '',
|
|
55
55
|
])
|
|
56
56
|
.filter(value => value[1] !== '');
|
|
@@ -15,7 +15,7 @@ interface UseLabelNames {
|
|
|
15
15
|
result: ILabelNamesResult;
|
|
16
16
|
loading: boolean;
|
|
17
17
|
}
|
|
18
|
-
export declare const useLabelNames: (client: QueryServiceClient, profileType: string, start?: number, end?: number) => UseLabelNames;
|
|
18
|
+
export declare const useLabelNames: (client: QueryServiceClient, profileType: string, start?: number, end?: number, match?: string[]) => UseLabelNames;
|
|
19
19
|
declare const MatchersInput: ({ queryClient, setMatchersString, runQuery, currentQuery, profileType, }: MatchersInputProps) => JSX.Element;
|
|
20
20
|
export default MatchersInput;
|
|
21
21
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/MatchersInput/index.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAAgB,cAAc,EAAE,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAEhF,OAAO,EAAC,KAAK,EAAC,MAAM,eAAe,CAAC;AAMpC,UAAU,kBAAkB;IAC1B,WAAW,EAAE,kBAAkB,CAAC;IAChC,iBAAiB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,YAAY,EAAE,KAAK,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED,UAAU,aAAa;IACrB,MAAM,EAAE,iBAAiB,CAAC;IAC1B,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,aAAa,WAChB,kBAAkB,eACb,MAAM,UACX,MAAM,QACR,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/MatchersInput/index.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAAgB,cAAc,EAAE,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAEhF,OAAO,EAAC,KAAK,EAAC,MAAM,eAAe,CAAC;AAMpC,UAAU,kBAAkB;IAC1B,WAAW,EAAE,kBAAkB,CAAC;IAChC,iBAAiB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,YAAY,EAAE,KAAK,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED,UAAU,aAAa;IACrB,MAAM,EAAE,iBAAiB,CAAC;IAC1B,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,aAAa,WAChB,kBAAkB,eACb,MAAM,UACX,MAAM,QACR,MAAM,UACJ,MAAM,EAAE,KACf,aAyBF,CAAC;AAEF,QAAA,MAAM,aAAa,6EAMhB,kBAAkB,KAAG,GAAG,CAAC,OAoL3B,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -19,12 +19,12 @@ import { Query } from '@parca/parser';
|
|
|
19
19
|
import { millisToProtoTimestamp, sanitizeLabelValue } from '@parca/utilities';
|
|
20
20
|
import useGrpcQuery from '../useGrpcQuery';
|
|
21
21
|
import SuggestionsList, { Suggestion, Suggestions } from './SuggestionsList';
|
|
22
|
-
export const useLabelNames = (client, profileType, start, end) => {
|
|
22
|
+
export const useLabelNames = (client, profileType, start, end, match) => {
|
|
23
23
|
const metadata = useGrpcMetadata();
|
|
24
24
|
const { data, isLoading, error } = useGrpcQuery({
|
|
25
|
-
key: ['labelNames', profileType],
|
|
25
|
+
key: ['labelNames', profileType, match?.join(',')],
|
|
26
26
|
queryFn: async () => {
|
|
27
|
-
const request = { match: [] };
|
|
27
|
+
const request = { match: match !== undefined ? match : [] };
|
|
28
28
|
if (start !== undefined && end !== undefined) {
|
|
29
29
|
request.start = millisToProtoTimestamp(start);
|
|
30
30
|
request.end = millisToProtoTimestamp(end);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/index.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAgE,MAAM,OAAO,CAAC;AAKrF,OAAO,EAAC,eAAe,EAAC,MAAM,eAAe,CAAC;AAG9C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAQ1C,OAAO,EAA2B,KAAK,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAO5E,OAAO,EAAwB,aAAa,EAAC,MAAM,oBAAoB,CAAC;AAGxE,eAAO,MAAM,iBAAiB,gBAAgB,CAAC;AAC/C,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AACjD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,mBAAmB,kBAAkB,CAAC;AACnD,eAAO,MAAM,aAAa,YAAY,CAAC;AACvC,eAAO,MAAM,mBAAmB,kBAAkB,CAAC;AACnD,eAAO,MAAM,0BAA0B,yBAAyB,CAAC;AACjE,eAAO,MAAM,wBAAwB,uBAAuB,CAAC;AAC7D,eAAO,MAAM,yBAAyB,uBAAuB,CAAC;AAC9D,eAAO,MAAM,cAAc,aAAa,CAAC;AACzC,eAAO,MAAM,YAAY,WAAW,CAAC;AACrC,eAAO,MAAM,gBAAgB,eAAe,CAAC;AAC7C,eAAO,MAAM,UAAU,SAAS,CAAC;AACjC,eAAO,MAAM,UAAU,SAAS,CAAC;AAEjC,UAAU,qBAAqB;IAC7B,KAAK,EAAE,eAAe,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;IACrC,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,OAAO,CAAC;IAC3B,YAAY,EAAE,OAAO,CAAC;IACtB,wBAAwB,EAAE,MAAM,EAAE,CAAC;IACnC,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED,eAAO,MAAM,gBAAgB,iBACb,MAAM,EAAE,cACV,OAAO,uBACE,WAAW,KAC/B,aAQF,CAAC;AAIF,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/index.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAgE,MAAM,OAAO,CAAC;AAKrF,OAAO,EAAC,eAAe,EAAC,MAAM,eAAe,CAAC;AAG9C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAQ1C,OAAO,EAA2B,KAAK,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAO5E,OAAO,EAAwB,aAAa,EAAC,MAAM,oBAAoB,CAAC;AAGxE,eAAO,MAAM,iBAAiB,gBAAgB,CAAC;AAC/C,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AACjD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,mBAAmB,kBAAkB,CAAC;AACnD,eAAO,MAAM,aAAa,YAAY,CAAC;AACvC,eAAO,MAAM,mBAAmB,kBAAkB,CAAC;AACnD,eAAO,MAAM,0BAA0B,yBAAyB,CAAC;AACjE,eAAO,MAAM,wBAAwB,uBAAuB,CAAC;AAC7D,eAAO,MAAM,yBAAyB,uBAAuB,CAAC;AAC9D,eAAO,MAAM,cAAc,aAAa,CAAC;AACzC,eAAO,MAAM,YAAY,WAAW,CAAC;AACrC,eAAO,MAAM,gBAAgB,eAAe,CAAC;AAC7C,eAAO,MAAM,UAAU,SAAS,CAAC;AACjC,eAAO,MAAM,UAAU,SAAS,CAAC;AAEjC,UAAU,qBAAqB;IAC7B,KAAK,EAAE,eAAe,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;IACrC,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,OAAO,CAAC;IAC3B,YAAY,EAAE,OAAO,CAAC;IACtB,wBAAwB,EAAE,MAAM,EAAE,CAAC;IACnC,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED,eAAO,MAAM,gBAAgB,iBACb,MAAM,EAAE,cACV,OAAO,uBACE,WAAW,KAC/B,aAQF,CAAC;AAIF,eAAO,MAAM,gBAAgB,mDA4P3B,CAAC;AAEH,eAAe,gBAAgB,CAAC"}
|
|
@@ -140,16 +140,13 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({ arrow, total, f
|
|
|
140
140
|
const highlightSimilarStacksSetName = useMemo(() => {
|
|
141
141
|
return highlightSimilarStacksPreference ? setHoveringName : noop;
|
|
142
142
|
}, [highlightSimilarStacksPreference]);
|
|
143
|
-
const highlightSimilarStacksSetLevel = useMemo(() => {
|
|
144
|
-
return highlightSimilarStacksPreference ? setHoveringLevel : noop;
|
|
145
|
-
}, [highlightSimilarStacksPreference]);
|
|
146
143
|
const highlightSimilarStacksRow = highlightSimilarStacksPreference ? hoveringRow : null;
|
|
147
144
|
const path = useMemo(() => {
|
|
148
145
|
return [];
|
|
149
146
|
}, []);
|
|
150
147
|
// useMemo for the root graph as it otherwise renders the whole graph if the hoveringRow changes.
|
|
151
148
|
const root = useMemo(() => {
|
|
152
|
-
return (_jsx("svg", { className: "font-robotoMono", width: width, height: height, preserveAspectRatio: "xMinYMid", ref: svg, onContextMenu: displayMenu, children: _jsx("g", { ref: ref, children: _jsx("g", { transform: 'translate(0, 0)', children: _jsx(IcicleNode, { table: table, row: 0, mappingColors: mappingColors, x: 0, y: 0, totalWidth: width ?? 1, height: RowHeight, setCurPath: setCurPath, curPath: curPath, total: total, xScale: xScale, path: path, level: 0, isRoot: true, searchString: currentSearchString ?? '', setHoveringRow: setHoveringRow, setHoveringLevel:
|
|
149
|
+
return (_jsx("svg", { className: "font-robotoMono", width: width, height: height, preserveAspectRatio: "xMinYMid", ref: svg, onContextMenu: displayMenu, children: _jsx("g", { ref: ref, children: _jsx("g", { transform: 'translate(0, 0)', children: _jsx(IcicleNode, { table: table, row: 0, mappingColors: mappingColors, x: 0, y: 0, totalWidth: width ?? 1, height: RowHeight, setCurPath: setCurPath, curPath: curPath, total: total, xScale: xScale, path: path, level: 0, isRoot: true, searchString: currentSearchString ?? '', setHoveringRow: setHoveringRow, setHoveringLevel: setHoveringLevel, sortBy: sortBy, darkMode: isDarkMode, compareMode: compareMode, profileType: profileType, isContextMenuOpen: isContextMenuOpen, hoveringName: highlightSimilarStacksName, setHoveringName: highlightSimilarStacksSetName, hoveringRow: highlightSimilarStacksRow, colorForSimilarNodes: colorForSimilarNodes, highlightSimilarStacksPreference: highlightSimilarStacksPreference }) }) }) }));
|
|
153
150
|
}, [
|
|
154
151
|
width,
|
|
155
152
|
height,
|
|
@@ -171,7 +168,6 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({ arrow, total, f
|
|
|
171
168
|
colorForSimilarNodes,
|
|
172
169
|
highlightSimilarStacksPreference,
|
|
173
170
|
path,
|
|
174
|
-
highlightSimilarStacksSetLevel,
|
|
175
171
|
highlightSimilarStacksSetName,
|
|
176
172
|
]);
|
|
177
173
|
return (_jsx(_Fragment, { children: _jsxs("div", { onMouseLeave: () => dispatch(setHoveringNode(undefined)), children: [_jsx(ContextMenu, { menuId: MENU_ID, table: table, row: hoveringRow ?? 0, level: hoveringLevel ?? 0, total: total, totalUnfiltered: total + filtered, profileType: profileType, compareAbsolute: compareAbsolute, trackVisibility: trackVisibility, curPath: curPath, setCurPath: setCurPath, hideMenu: hideAll, hideBinary: hideBinary, unit: arrow.unit }), dockedMetainfo ? (_jsx(DockedGraphTooltip, { table: table, row: hoveringRow, level: hoveringLevel ?? 0, total: total, totalUnfiltered: total + filtered, profileType: profileType, unit: arrow.unit, compareAbsolute: compareAbsolute })) : (!isContextMenuOpen && (_jsx(GraphTooltipArrow, { contextElement: svg.current, isContextMenuOpen: isContextMenuOpen, children: _jsx(GraphTooltipArrowContent, { table: table, row: hoveringRow, level: hoveringLevel ?? 0, isFixed: false, total: total, totalUnfiltered: total + filtered, profileType: profileType, unit: arrow.unit, compareAbsolute: compareAbsolute }) }))), root] }) }));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/utils.ts"],"names":[],"mappings":"AAaA,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAEnC,OAAO,EAAiC,KAAK,OAAO,EAAC,MAAM,cAAc,CAAC;AAW1E,wBAAgB,SAAS,CACvB,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,EACjB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,MAAM,EACb,cAAc,EAAE,OAAO,GACtB,MAAM,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/ProfileIcicleGraph/IcicleGraphArrow/utils.ts"],"names":[],"mappings":"AAaA,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAEnC,OAAO,EAAiC,KAAK,OAAO,EAAC,MAAM,cAAc,CAAC;AAW1E,wBAAgB,SAAS,CACvB,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,EACjB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,MAAM,EACb,cAAc,EAAE,OAAO,GACtB,MAAM,CAkCR;AAED,eAAO,MAAM,cAAc,YAAa,MAAM,KAAG,OAMhD,CAAC;AAEF,eAAO,MAAM,oBAAoB,2BACP,MAAM,mBACb,MAAM,SAChB,MAAM,QACP,MAAM,KACX,MAOF,CAAC;AAEF,eAAO,MAAM,6BAA6B,2BAChB,MAAM,QACxB,MAAM,KACX,MAMF,CAAC;AAEF,eAAO,MAAM,aAAa,WAAY,GAAG,KAAG,MAAM,GAAG,IAQpD,CAAC"}
|
|
@@ -15,23 +15,23 @@ import { divide, getLastItem, valueFormatter } from '@parca/utilities';
|
|
|
15
15
|
import { hexifyAddress } from '../../utils';
|
|
16
16
|
import { FIELD_FUNCTION_NAME, FIELD_LABELS_ONLY, FIELD_LOCATION_ADDRESS, FIELD_MAPPING_FILE, } from './index';
|
|
17
17
|
export function nodeLabel(table, row, level, showBinaryName) {
|
|
18
|
-
const functionName = arrowToString(table.getChild(FIELD_FUNCTION_NAME)?.get(row));
|
|
19
18
|
const labelsOnly = table.getChild(FIELD_LABELS_ONLY)?.get(row);
|
|
20
|
-
const pprofLabelPrefix = 'pprof_labels.';
|
|
21
|
-
const labelColumnNames = table.schema.fields.filter(field => field.name.startsWith(pprofLabelPrefix));
|
|
22
|
-
if (functionName !== null && functionName !== '') {
|
|
23
|
-
return functionName;
|
|
24
|
-
}
|
|
25
19
|
if (level === 1 && labelsOnly !== null && labelsOnly) {
|
|
20
|
+
const labelPrefix = 'labels.';
|
|
21
|
+
const labelColumnNames = table.schema.fields.filter(field => field.name.startsWith(labelPrefix));
|
|
26
22
|
return labelColumnNames
|
|
27
23
|
.map((field, i) => [
|
|
28
|
-
labelColumnNames[i].name.slice(
|
|
24
|
+
labelColumnNames[i].name.slice(labelPrefix.length),
|
|
29
25
|
arrowToString(table.getChild(field.name)?.get(row)) ?? '',
|
|
30
26
|
])
|
|
31
27
|
.filter(value => value[1] !== '')
|
|
32
28
|
.map(([k, v]) => `${k}="${v}"`)
|
|
33
29
|
.join(', ');
|
|
34
30
|
}
|
|
31
|
+
const functionName = arrowToString(table.getChild(FIELD_FUNCTION_NAME)?.get(row));
|
|
32
|
+
if (functionName !== null && functionName !== '') {
|
|
33
|
+
return functionName;
|
|
34
|
+
}
|
|
35
35
|
let mappingString = '';
|
|
36
36
|
if (showBinaryName) {
|
|
37
37
|
const mappingFile = table.getChild(FIELD_MAPPING_FILE)?.get(row) ?? '';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ProfileView/index.tsx"],"names":[],"mappings":"AA0BA,OAAO,EACL,SAAS,IAAI,aAAa,EAC1B,UAAU,EACV,eAAe,EACf,kBAAkB,EAClB,MAAM,EACN,UAAU,EACV,GAAG,EACJ,MAAM,eAAe,CAAC;AAUvB,OAAO,EAAC,aAAa,EAAC,MAAM,kBAAkB,CAAC;AAO/C,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,KAAK,CAAC,EAAE,eAAe,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,eAAe,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ProfileView/index.tsx"],"names":[],"mappings":"AA0BA,OAAO,EACL,SAAS,IAAI,aAAa,EAC1B,UAAU,EACV,eAAe,EACf,kBAAkB,EAClB,MAAM,EACN,UAAU,EACV,GAAG,EACJ,MAAM,eAAe,CAAC;AAUvB,OAAO,EAAC,aAAa,EAAC,MAAM,kBAAkB,CAAC;AAO/C,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,KAAK,CAAC,EAAE,eAAe,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,eAAe,EAAE,OAAO,CAAC;IACzB,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB;AAED,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,UAAU,aAAa;IACrB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,aAAa,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,GAAG,CAAC;CACb;AAED,UAAU,UAAU;IAClB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,GAAG,CAAC;CACb;AAED,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,cAAc,CAAC;IAC/B,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,WAAW,CAAC,EAAE,kBAAkB,CAAC;IACjC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAWD,eAAO,MAAM,WAAW,0JAYrB,gBAAgB,KAAG,GAAG,CAAC,OA6UzB,CAAC"}
|
|
@@ -162,7 +162,7 @@ export const ProfileView = ({ total, filtered, flamegraphData, topTableData, cal
|
|
|
162
162
|
'items-center mb-2': hasProfileSource,
|
|
163
163
|
}), children: _jsxs("div", { children: [hasProfileSource && (_jsxs("div", { className: "flex items-center gap-1", children: [_jsx("div", { className: "text-xs font-medium", children: headerParts.length > 0 ? headerParts[0].replace(/"/g, '') : '' }), _jsx("div", { className: "text-xs font-medium", children: headerParts.length > 1
|
|
164
164
|
? headerParts[headerParts.length - 1].replace(/"/g, '')
|
|
165
|
-
: '' })] })), profileViewExternalMainActions != null ? profileViewExternalMainActions : null] }) }), _jsx(VisualisationToolbar, { groupBy: groupBy, toggleGroupBy: toggleGroupBy, hasProfileSource: hasProfileSource, pprofdownloading: pprofDownloading, profileSource: profileSource, queryClient: queryClient, onDownloadPProf: onDownloadPProf, isMultiPanelView: isMultiPanelView, dashboardItems: dashboardItems, curPath: curPath, setNewCurPath: setNewCurPath, profileType: profileSource?.ProfileType(), total: total, filtered: filtered, currentSearchString: currentSearchString, setSearchString: setSearchString }), _jsx("div", { className: "w-full", ref: ref, children: _jsx(DragDropContext, { onDragEnd: onDragEnd, children: _jsx(Droppable, { droppableId: "droppable", direction: "horizontal", children: provided => (_jsx("div", { ref: provided.innerRef, className: cx('grid w-full gap-2', isMultiPanelView ? 'grid-cols-2' : 'grid-cols-1'), ...provided.droppableProps, children: dashboardItems.map((dashboardItem, index) => {
|
|
165
|
+
: '' })] })), profileViewExternalMainActions != null ? profileViewExternalMainActions : null] }) }), _jsx(VisualisationToolbar, { groupBy: groupBy, toggleGroupBy: toggleGroupBy, hasProfileSource: hasProfileSource, pprofdownloading: pprofDownloading, profileSource: profileSource, queryClient: queryClient, onDownloadPProf: onDownloadPProf, isMultiPanelView: isMultiPanelView, dashboardItems: dashboardItems, curPath: curPath, setNewCurPath: setNewCurPath, profileType: profileSource?.ProfileType(), total: total, filtered: filtered, currentSearchString: currentSearchString, setSearchString: setSearchString, groupByLabels: flamegraphData.groupByLabels ?? [] }), _jsx("div", { className: "w-full", ref: ref, children: _jsx(DragDropContext, { onDragEnd: onDragEnd, children: _jsx(Droppable, { droppableId: "droppable", direction: "horizontal", children: provided => (_jsx("div", { ref: provided.innerRef, className: cx('grid w-full gap-2', isMultiPanelView ? 'grid-cols-2' : 'grid-cols-1'), ...provided.droppableProps, children: dashboardItems.map((dashboardItem, index) => {
|
|
166
166
|
return (_jsx(Draggable, { draggableId: dashboardItem, index: index, isDragDisabled: !isMultiPanelView, children: (provided, snapshot) => (_createElement("div", { ref: provided.innerRef, ...provided.draggableProps, key: dashboardItem, className: cx('w-full min-h-96', snapshot.isDragging
|
|
167
167
|
? 'bg-gray-200 dark:bg-gray-500'
|
|
168
168
|
: 'bg-white dark:bg-gray-900') },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProfileViewWithData.d.ts","sourceRoot":"","sources":["../src/ProfileViewWithData.tsx"],"names":[],"mappings":"AAeA,OAAO,EAA0B,kBAAkB,EAAC,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"ProfileViewWithData.d.ts","sourceRoot":"","sources":["../src/ProfileViewWithData.tsx"],"names":[],"mappings":"AAeA,OAAO,EAA0B,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAM1E,OAAO,EAAsB,aAAa,EAAC,MAAM,iBAAiB,CAAC;AAKnE,UAAU,wBAAwB;IAChC,WAAW,EAAE,kBAAkB,CAAC;IAChC,aAAa,EAAE,aAAa,CAAC;IAC7B,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,eAAO,MAAM,mBAAmB,oCAG7B,wBAAwB,KAAG,GAAG,CAAC,OA6NjC,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
|
@@ -15,6 +15,7 @@ import { useEffect, useMemo, useState } from 'react';
|
|
|
15
15
|
import { QueryRequest_ReportType } from '@parca/client';
|
|
16
16
|
import { useGrpcMetadata, useParcaContext, useURLState } from '@parca/components';
|
|
17
17
|
import { saveAsBlob } from '@parca/utilities';
|
|
18
|
+
import { useLabelNames } from './MatchersInput';
|
|
18
19
|
import { FIELD_FUNCTION_NAME } from './ProfileIcicleGraph/IcicleGraphArrow';
|
|
19
20
|
import { ProfileView } from './ProfileView';
|
|
20
21
|
import { useQuery } from './useQuery';
|
|
@@ -52,6 +53,9 @@ export const ProfileViewWithData = ({ queryClient, profileSource, }) => {
|
|
|
52
53
|
invertCallStack,
|
|
53
54
|
binaryFrameFilter,
|
|
54
55
|
});
|
|
56
|
+
const mergedProfileSource = profileSource;
|
|
57
|
+
const matchers = mergedProfileSource.query.matchers.map(m => `${m.key}${m.matcherType}"${m.value}"`);
|
|
58
|
+
const { result: profileLabelsResponse } = useLabelNames(queryClient, profileSource.ProfileType().toString(), undefined, undefined, matchers);
|
|
55
59
|
const { isLoading: profilemetadataLoading, response: profilemetadataResponse } = useQuery(queryClient, profileSource, QueryRequest_ReportType.PROFILE_METADATA, {
|
|
56
60
|
skip: !dashboardItems.includes('icicle'),
|
|
57
61
|
nodeTrimThreshold,
|
|
@@ -146,6 +150,7 @@ export const ProfileViewWithData = ({ queryClient, profileSource, }) => {
|
|
|
146
150
|
? profilemetadataResponse?.report?.profileMetadata?.mappingFiles
|
|
147
151
|
: undefined,
|
|
148
152
|
mappingsLoading: profilemetadataLoading,
|
|
153
|
+
groupByLabels: profileLabelsResponse.response?.labelNames ?? [],
|
|
149
154
|
}, topTableData: {
|
|
150
155
|
loading: tableLoading,
|
|
151
156
|
arrow: tableResponse?.report.oneofKind === 'tableArrow'
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface GroupByControlsProps {
|
|
2
3
|
groupBy: string[];
|
|
4
|
+
labels: string[];
|
|
3
5
|
toggleGroupBy: (key: string) => void;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
+
setGroupByLabels: (labels: string[]) => void;
|
|
7
|
+
}
|
|
8
|
+
declare const GroupByControls: React.FC<GroupByControlsProps>;
|
|
9
|
+
export default GroupByControls;
|
|
6
10
|
//# sourceMappingURL=GroupByDropdown.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GroupByDropdown.d.ts","sourceRoot":"","sources":["../../../src/components/ActionButtons/GroupByDropdown.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"GroupByDropdown.d.ts","sourceRoot":"","sources":["../../../src/components/ActionButtons/GroupByDropdown.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAoQzD,UAAU,oBAAoB;IAC5B,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,aAAa,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,gBAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;CAC9C;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAoDnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -11,8 +11,11 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
11
11
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
12
|
// See the License for the specific language governing permissions and
|
|
13
13
|
// limitations under the License.
|
|
14
|
-
import {
|
|
14
|
+
import { useEffect, useRef, useState } from 'react';
|
|
15
|
+
import { Transition } from '@headlessui/react';
|
|
15
16
|
import { Icon } from '@iconify/react';
|
|
17
|
+
import Select from 'react-select';
|
|
18
|
+
import { Button } from '@parca/components';
|
|
16
19
|
import { FIELD_FUNCTION_FILE_NAME, FIELD_FUNCTION_NAME, FIELD_LABELS, FIELD_LOCATION_ADDRESS, FIELD_MAPPING_FILE, } from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
17
20
|
const groupByOptions = [
|
|
18
21
|
{
|
|
@@ -21,12 +24,6 @@ const groupByOptions = [
|
|
|
21
24
|
description: 'Stacktraces are grouped by function names.',
|
|
22
25
|
disabled: true,
|
|
23
26
|
},
|
|
24
|
-
{
|
|
25
|
-
value: FIELD_LABELS,
|
|
26
|
-
label: 'Labels',
|
|
27
|
-
description: 'Stacktraces are grouped by pprof labels.',
|
|
28
|
-
disabled: false,
|
|
29
|
-
},
|
|
30
27
|
{
|
|
31
28
|
value: FIELD_FUNCTION_FILE_NAME,
|
|
32
29
|
label: 'Filename',
|
|
@@ -46,12 +43,87 @@ const groupByOptions = [
|
|
|
46
43
|
disabled: false,
|
|
47
44
|
},
|
|
48
45
|
];
|
|
49
|
-
const
|
|
46
|
+
const LabelSelector = ({ labels, groupBy, setGroupByLabels, isOpen, labelsButtonRef, setIsLabelSelectorOpen, }) => {
|
|
47
|
+
const [position, setPosition] = useState({ top: 0, left: 0 });
|
|
48
|
+
useEffect(() => {
|
|
49
|
+
if (isOpen && labelsButtonRef.current !== null) {
|
|
50
|
+
const rect = labelsButtonRef.current.getBoundingClientRect();
|
|
51
|
+
const parentRect = labelsButtonRef.current.offsetParent?.getBoundingClientRect() ?? {
|
|
52
|
+
top: 0,
|
|
53
|
+
left: 0,
|
|
54
|
+
};
|
|
55
|
+
setPosition({
|
|
56
|
+
top: rect.bottom - parentRect.top,
|
|
57
|
+
left: rect.right - parentRect.left + 4,
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
}, [isOpen, labelsButtonRef]);
|
|
61
|
+
if (!isOpen)
|
|
62
|
+
return null;
|
|
63
|
+
return (_jsx("div", { className: "absolute w-64 ml-4 z-20", style: {
|
|
64
|
+
top: `${position.top}px`,
|
|
65
|
+
left: `${position.left}px`,
|
|
66
|
+
}, children: _jsx(Select, { isMulti: true, name: "labels", options: labels.map(label => ({ label, value: `${FIELD_LABELS}.${label}` })), className: "parca-select-container text-sm w-full border-gray-300 border rounded-md", classNamePrefix: "parca-select parca-groupby-label", value: groupBy
|
|
67
|
+
.filter(l => l.startsWith(FIELD_LABELS))
|
|
68
|
+
.map(l => ({ value: l, label: l.slice(FIELD_LABELS.length + 1) })), onChange: newValue => {
|
|
69
|
+
setGroupByLabels(newValue.map(option => option.value));
|
|
70
|
+
setIsLabelSelectorOpen(false);
|
|
71
|
+
}, placeholder: "Select labels...", styles: {
|
|
72
|
+
menu: provided => ({
|
|
73
|
+
...provided,
|
|
74
|
+
position: 'relative',
|
|
75
|
+
marginBottom: 0,
|
|
76
|
+
boxShadow: 'none',
|
|
77
|
+
marginTop: 0,
|
|
78
|
+
}),
|
|
79
|
+
control: provided => ({
|
|
80
|
+
...provided,
|
|
81
|
+
boxShadow: 'none',
|
|
82
|
+
borderBottom: '1px solid #e2e8f0',
|
|
83
|
+
borderRight: 0,
|
|
84
|
+
borderLeft: 0,
|
|
85
|
+
borderTop: 0,
|
|
86
|
+
borderBottomLeftRadius: 0,
|
|
87
|
+
borderBottomRightRadius: 0,
|
|
88
|
+
':hover': {
|
|
89
|
+
borderColor: '#e2e8f0',
|
|
90
|
+
borderBottomLeftRadius: 0,
|
|
91
|
+
borderBottomRightRadius: 0,
|
|
92
|
+
},
|
|
93
|
+
}),
|
|
94
|
+
}, menuIsOpen: true }) }));
|
|
95
|
+
};
|
|
96
|
+
const GroupByDropdown = ({ groupBy, toggleGroupBy, onLabelClick, labelsButtonRef, }) => {
|
|
97
|
+
const [isDropdownOpen, setIsDropdownOpen] = useState(false);
|
|
50
98
|
const label = groupBy.length === 0
|
|
51
99
|
? 'Nothing'
|
|
52
100
|
: groupBy.length === 1
|
|
53
101
|
? groupByOptions.find(option => option.value === groupBy[0])?.label
|
|
54
102
|
: 'Multiple';
|
|
55
|
-
|
|
103
|
+
const selectedLabels = groupBy
|
|
104
|
+
.filter(l => l.startsWith(FIELD_LABELS))
|
|
105
|
+
.map(l => l.slice(FIELD_LABELS.length + 1));
|
|
106
|
+
return (_jsxs("div", { className: "relative", children: [_jsx("label", { className: "text-sm", children: "Group" }), _jsxs("div", { className: "relative text-left", id: "h-group-by-filter", children: [_jsxs(Button, { variant: "neutral", onClick: () => setIsDropdownOpen(!isDropdownOpen), className: "relative w-max cursor-default rounded-md border bg-white py-2 pl-3 pr-[1.7rem] text-left text-sm shadow-sm dark:border-gray-600 dark:bg-gray-900 sm:text-sm", children: [_jsx("span", { className: "block overflow-x-hidden text-ellipsis", children: label }), _jsx("span", { className: "pointer-events-none absolute inset-y-0 right-0 flex items-center pr-2 text-gray-400", children: _jsx(Icon, { icon: "heroicons:chevron-down-20-solid", "aria-hidden": "true" }) })] }), _jsx(Transition, { as: "div", leave: "transition ease-in duration-100", leaveFrom: "opacity-100", leaveTo: "opacity-0", show: isDropdownOpen, children: _jsx("div", { className: "absolute left-0 z-10 mt-1 min-w-[400px] overflow-auto rounded-md bg-gray-50 py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none dark:border-gray-600 dark:bg-gray-900 dark:ring-white dark:ring-opacity-20 sm:text-sm", children: _jsx("div", { className: "p-4", children: _jsx("fieldset", { children: _jsxs("div", { className: "space-y-5", children: [groupByOptions.map(({ value, label, description, disabled }) => (_jsxs("div", { className: "relative flex items-start", children: [_jsx("div", { className: "flex h-6 items-center", children: _jsx("input", { id: value, name: value, type: "checkbox", disabled: disabled, className: "h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-600", checked: groupBy.includes(value), onChange: () => toggleGroupBy(value) }) }), _jsxs("div", { className: "ml-3 text-sm leading-6", children: [_jsx("label", { htmlFor: value, className: "font-medium text-gray-900 dark:text-gray-200", children: label }), _jsx("p", { className: "text-gray-500 dark:text-gray-400", children: description })] })] }, value))), _jsxs("div", { className: "ml-7 flex flex-col items-start text-sm leading-6 cursor-pointer", onClick: onLabelClick, ref: labelsButtonRef, children: [_jsxs("div", { className: "flex justify-between w-full items-center", children: [_jsxs("div", { children: [_jsx("span", { className: "font-medium text-gray-900 dark:text-gray-200", children: "Labels" }), _jsx("p", { className: "text-gray-500 dark:text-gray-400", children: "Stacktraces are grouped by labels." })] }), _jsx(Icon, { icon: "flowbite:caret-right-solid", className: "h-[14px] w-[14px]" })] }), selectedLabels.length > 0 && (_jsxs("div", { className: "flex gap-2 flex-wrap", children: [_jsx("span", { className: "text-gray-500 dark:text-gray-200", children: "Selected labels:" }), _jsx("div", { className: "flex", children: selectedLabels.map(label => (_jsx("span", { className: "mr-2 px-3 py-1 text-xs text-gray-700 dark:text-gray-200 bg-gray-200 rounded-md dark:bg-gray-900", children: label }, label))) })] }))] })] }) }) }) }) })] })] }));
|
|
107
|
+
};
|
|
108
|
+
const GroupByControls = ({ groupBy, labels, toggleGroupBy, setGroupByLabels, }) => {
|
|
109
|
+
const [isLabelSelectorOpen, setIsLabelSelectorOpen] = useState(false);
|
|
110
|
+
const labelsButton = useRef(null);
|
|
111
|
+
const labelSelectorRef = useRef(null);
|
|
112
|
+
useEffect(() => {
|
|
113
|
+
const handleClickOutside = (event) => {
|
|
114
|
+
if (isLabelSelectorOpen &&
|
|
115
|
+
labelSelectorRef.current !== null &&
|
|
116
|
+
!labelSelectorRef.current.contains(event.target) &&
|
|
117
|
+
labelsButton.current !== null &&
|
|
118
|
+
!labelsButton.current.contains(event.target)) {
|
|
119
|
+
setIsLabelSelectorOpen(false);
|
|
120
|
+
}
|
|
121
|
+
};
|
|
122
|
+
document.addEventListener('mousedown', handleClickOutside);
|
|
123
|
+
return () => {
|
|
124
|
+
document.removeEventListener('mousedown', handleClickOutside);
|
|
125
|
+
};
|
|
126
|
+
}, [isLabelSelectorOpen]);
|
|
127
|
+
return (_jsx("div", { className: "inline-flex items-start", children: _jsxs("div", { className: "relative flex items-start", children: [_jsx(GroupByDropdown, { groupBy: groupBy, toggleGroupBy: toggleGroupBy, onLabelClick: () => setIsLabelSelectorOpen(!isLabelSelectorOpen), labelsButtonRef: labelsButton }), _jsx("div", { ref: labelSelectorRef, children: _jsx(LabelSelector, { labels: labels, groupBy: groupBy, setGroupByLabels: setGroupByLabels, isOpen: isLabelSelectorOpen, labelsButtonRef: labelsButton, setIsLabelSelectorOpen: setIsLabelSelectorOpen }) })] }) }));
|
|
56
128
|
};
|
|
57
|
-
export default
|
|
129
|
+
export default GroupByControls;
|
|
@@ -19,7 +19,8 @@ interface Props {
|
|
|
19
19
|
filtered: bigint;
|
|
20
20
|
setSearchString?: (searchString: string) => void;
|
|
21
21
|
currentSearchString?: string;
|
|
22
|
+
groupByLabels: string[];
|
|
22
23
|
}
|
|
23
|
-
declare const VisualisationToolbar: ({ hasProfileSource, profileSource, queryClient, onDownloadPProf, pprofdownloading, curPath, setNewCurPath, profileType, total, filtered, setSearchString, currentSearchString, }: Props) => JSX.Element;
|
|
24
|
+
declare const VisualisationToolbar: ({ hasProfileSource, profileSource, queryClient, onDownloadPProf, pprofdownloading, curPath, setNewCurPath, profileType, total, filtered, setSearchString, currentSearchString, groupByLabels, }: Props) => JSX.Element;
|
|
24
25
|
export default VisualisationToolbar;
|
|
25
26
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/VisualisationToolbar/index.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAAC,YAAY,EAAE,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAE/D,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAG1C,OAAO,EAAC,aAAa,EAAC,MAAM,qBAAqB,CAAC;AAQlD,UAAU,KAAK;IACb,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3B,aAAa,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,gBAAgB,EAAE,OAAO,CAAC;IAC1B,gBAAgB,EAAE,OAAO,CAAC;IAC1B,cAAc,EAAE,GAAG,CAAC;IACpB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,WAAW,CAAC,EAAE,kBAAkB,CAAC;IACjC,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,gBAAgB,EAAE,OAAO,GAAG,SAAS,CAAC;IACtC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,aAAa,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;IACxC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,mBAAmB,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/VisualisationToolbar/index.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAAC,YAAY,EAAE,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAE/D,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAG1C,OAAO,EAAC,aAAa,EAAC,MAAM,qBAAqB,CAAC;AAQlD,UAAU,KAAK;IACb,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3B,aAAa,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,gBAAgB,EAAE,OAAO,CAAC;IAC1B,gBAAgB,EAAE,OAAO,CAAC;IAC1B,cAAc,EAAE,GAAG,CAAC;IACpB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,WAAW,CAAC,EAAE,kBAAkB,CAAC;IACjC,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,gBAAgB,EAAE,OAAO,GAAG,SAAS,CAAC;IACtC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,aAAa,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;IACxC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB;AAED,QAAA,MAAM,oBAAoB,oMAcvB,KAAK,KAAG,GAAG,CAAC,OAkHd,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|
|
@@ -15,14 +15,14 @@ import { useCallback } from 'react';
|
|
|
15
15
|
import { Icon } from '@iconify/react';
|
|
16
16
|
import cx from 'classnames';
|
|
17
17
|
import { Button, UserPreferencesModal, useParcaContext, useURLState } from '@parca/components';
|
|
18
|
-
import { FIELD_FUNCTION_NAME } from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
18
|
+
import { FIELD_FUNCTION_NAME, FIELD_LABELS } from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
19
19
|
import GroupByDropdown from '../ActionButtons/GroupByDropdown';
|
|
20
20
|
import FilterByFunctionButton from '../FilterByFunctionButton';
|
|
21
21
|
import ShareButton from '../ShareButton';
|
|
22
22
|
import ViewSelector from '../ViewSelector';
|
|
23
23
|
import MultiLevelDropdown from './MultiLevelDropdown';
|
|
24
24
|
import TableColumnsDropdown from './TableColumnsDropdown';
|
|
25
|
-
const VisualisationToolbar = ({ hasProfileSource, profileSource, queryClient, onDownloadPProf, pprofdownloading, curPath, setNewCurPath, profileType, total, filtered, setSearchString, currentSearchString, }) => {
|
|
25
|
+
const VisualisationToolbar = ({ hasProfileSource, profileSource, queryClient, onDownloadPProf, pprofdownloading, curPath, setNewCurPath, profileType, total, filtered, setSearchString, currentSearchString, groupByLabels, }) => {
|
|
26
26
|
const [dashboardItems] = useURLState('dashboard_items', {
|
|
27
27
|
alwaysReturnArray: true,
|
|
28
28
|
});
|
|
@@ -39,6 +39,9 @@ const VisualisationToolbar = ({ hasProfileSource, profileSource, queryClient, on
|
|
|
39
39
|
? setGroupBy(groupBy.filter(v => v !== key)) // remove
|
|
40
40
|
: setGroupBy([...groupBy, key]); // add
|
|
41
41
|
}, [groupBy, setGroupBy]);
|
|
42
|
+
const setGroupByLabels = useCallback((labels) => {
|
|
43
|
+
setGroupBy(groupBy.filter(l => !l.startsWith(`${FIELD_LABELS}.`)).concat(labels));
|
|
44
|
+
}, [groupBy, setGroupBy]);
|
|
42
45
|
const clearSelection = useCallback(() => {
|
|
43
46
|
setSearchString?.('');
|
|
44
47
|
}, [setSearchString]);
|
|
@@ -49,6 +52,6 @@ const VisualisationToolbar = ({ hasProfileSource, profileSource, queryClient, on
|
|
|
49
52
|
: 'justify-end', {
|
|
50
53
|
'items-end': !hasProfileSource && profileViewExternalMainActions != null,
|
|
51
54
|
'items-center': hasProfileSource,
|
|
52
|
-
}), children: _jsxs("div", { className: "flex w-full justify-between items-end", children: [_jsxs("div", { className: "flex gap-3 items-end", children: [isGraphViz && (_jsxs(_Fragment, { children: [_jsx(GroupByDropdown, { groupBy: groupBy, toggleGroupBy: toggleGroupBy }), _jsx(MultiLevelDropdown, { profileType: profileType, onSelect: () => { } }), _jsxs(Button, { variant: "neutral", className: "gap-2 w-max", onClick: () => setNewCurPath([]), disabled: curPath.length === 0, children: ["Reset graph", _jsx(Icon, { icon: "system-uicons:reset", width: 20 })] })] })), isTableViz && (_jsxs(_Fragment, { children: [_jsx(TableColumnsDropdown, { profileType: profileType, total: total, filtered: filtered }), dashboardItems.length > 1 && (_jsx(Button, { color: "neutral", onClick: clearSelection, className: "w-auto", variant: "neutral", disabled: currentSearchString === undefined || currentSearchString.length === 0, children: "Clear selection" }))] })), _jsx(FilterByFunctionButton, {}), profileViewExternalSubActions != null ? profileViewExternalSubActions : null] }), _jsxs("div", { className: "flex gap-3", children: [preferencesModal === true ? _jsx(UserPreferencesModal, {}) : null, _jsx(ShareButton, { profileSource: profileSource, queryClient: queryClient, queryRequest: profileSource?.QueryRequest() ?? undefined, onDownloadPProf: onDownloadPProf, pprofdownloading: pprofdownloading ?? false, profileViewExternalSubActions: profileViewExternalSubActions }), _jsx(ViewSelector, {})] })] }) }));
|
|
55
|
+
}), children: _jsxs("div", { className: "flex w-full justify-between items-end", children: [_jsxs("div", { className: "flex gap-3 items-end", children: [isGraphViz && (_jsxs(_Fragment, { children: [_jsx(GroupByDropdown, { groupBy: groupBy, toggleGroupBy: toggleGroupBy, labels: groupByLabels, setGroupByLabels: setGroupByLabels }), _jsx(MultiLevelDropdown, { profileType: profileType, onSelect: () => { } }), _jsxs(Button, { variant: "neutral", className: "gap-2 w-max", onClick: () => setNewCurPath([]), disabled: curPath.length === 0, children: ["Reset graph", _jsx(Icon, { icon: "system-uicons:reset", width: 20 })] })] })), isTableViz && (_jsxs(_Fragment, { children: [_jsx(TableColumnsDropdown, { profileType: profileType, total: total, filtered: filtered }), dashboardItems.length > 1 && (_jsx(Button, { color: "neutral", onClick: clearSelection, className: "w-auto", variant: "neutral", disabled: currentSearchString === undefined || currentSearchString.length === 0, children: "Clear selection" }))] })), _jsx(FilterByFunctionButton, {}), profileViewExternalSubActions != null ? profileViewExternalSubActions : null] }), _jsxs("div", { className: "flex gap-3", children: [preferencesModal === true ? _jsx(UserPreferencesModal, {}) : null, _jsx(ShareButton, { profileSource: profileSource, queryClient: queryClient, queryRequest: profileSource?.QueryRequest() ?? undefined, onDownloadPProf: onDownloadPProf, pprofdownloading: pprofdownloading ?? false, profileViewExternalSubActions: profileViewExternalSubActions }), _jsx(ViewSelector, {})] })] }) }));
|
|
53
56
|
};
|
|
54
57
|
export default VisualisationToolbar;
|
package/dist/styles.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! tailwindcss v3.2.4 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.-inset-2{bottom:-.5rem;left:-.5rem;right:-.5rem;top:-.5rem}.inset-y-0{bottom:0;top:0}.left-\[25px\]{left:25px}.left-0{left:0}.top-\[-46px\]{top:-46px}.right-0{right:0}.top-0{top:0}.bottom-3{bottom:.75rem}.top-\[-5px\]{top:-5px}.top-\[7px\]{top:7px}.right-\[6px\]{right:6px}.top-\[-1px\]{top:-1px}.left-\[18px\]{left:18px}.bottom-0{bottom:0}.left-full{left:100%}.z-50{z-index:50}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.m-auto{margin:auto}.m-2{margin:.5rem}.mx-auto{margin-left:auto;margin-right:auto}.mx-2{margin-left:.5rem;margin-right:.5rem}.my-2{margin-bottom:.5rem;margin-top:.5rem}.my-20{margin-bottom:5rem;margin-top:5rem}.my-6{margin-bottom:1.5rem;margin-top:1.5rem}.my-4{margin-bottom:1rem;margin-top:1rem}.mr-3{margin-right:.75rem}.mt-1{margin-top:.25rem}.mb-2{margin-bottom:.5rem}.mb-0\.5{margin-bottom:.125rem}.mt-1\.5{margin-top:.375rem}.mb-0{margin-bottom:0}.ml-auto{margin-left:auto}.mb-4{margin-bottom:1rem}.mr-2{margin-right:.5rem}.ml-3{margin-left:.75rem}.ml-2{margin-left:.5rem}.mr-6{margin-right:1.5rem}.mr-1{margin-right:.25rem}.mb-1{margin-bottom:.25rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-8{margin-top:2rem}.mt-0{margin-top:0}.ml-1{margin-left:.25rem}.mt-2{margin-top:.5rem}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.\!flex{display:flex!important}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.hidden{display:none}.h-fit{height:-moz-fit-content;height:fit-content}.h-10{height:2.5rem}.h-\[38px\]{height:38px}.h-auto{height:auto}.h-full{height:100%}.h-1{height:.25rem}.h-\[20px\]{height:20px}.h-\[16px\]{height:16px}.h-\[1px\]{height:1px}.h-\[45px\]{height:45px}.h-\[30px\]{height:30px}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-4{height:1rem}.h-\[700px\]{height:700px}.h-\[80vh\]{height:80vh}.h-\[14px\]{height:14px}.max-h-\[400px\]{max-height:400px}.max-h-\[50vh\]{max-height:50vh}.max-h-\[300px\]{max-height:300px}.min-h-52{min-height:13rem}.min-h-48{min-height:12rem}.min-h-96{min-height:24rem}.min-h-\[700px\]{min-height:700px}.w-full{width:100%}.w-auto{width:auto}.w-1\/4{width:25%}.w-3\/4{width:75%}.w-\[500px\]{width:500px}.w-40{width:10rem}.w-\[44px\]{width:44px}.w-\[16px\]{width:16px}.w-max{width:-moz-max-content;width:max-content}.w-\[270px\]{width:270px}.w-5{width:1.25rem}.w-3{width:.75rem}.w-7{width:1.75rem}.w-9{width:2.25rem}.w-11{width:2.75rem}.w-\[52px\]{width:52px}.w-\[68px\]{width:68px}.w-\[76px\]{width:76px}.w-\[84px\]{width:84px}.w-\[92px\]{width:92px}.w-\[100px\]{width:100px}.w-\[108px\]{width:108px}.w-\[116px\]{width:116px}.w-4{width:1rem}.w-\[18px\]{width:18px}.w-8{width:2rem}.w-44{width:11rem}.w-\[460px\]{width:460px}.w-\[19\.25\%\]{width:19.25%}.w-11\/12{width:91.666667%}.w-1\/12{width:8.333333%}.w-16{width:4rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-\[420px\]{width:420px}.w-48{width:12rem}.w-\[246px\]{width:246px}.w-\[14px\]{width:14px}.w-56{width:14rem}.min-w-\[300px\]{min-width:300px}.min-w-\[400px\]{min-width:400px}.max-w-\[500px\]{max-width:500px}.max-w-80{max-width:20rem}.max-w-48{max-width:12rem}.max-w-\[300px\]{max-width:300px}.max-w-\[400px\]{max-width:400px}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.shrink{flex-shrink:1}.flex-grow-0{flex-grow:0}.flex-grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.origin-top-left{transform-origin:top left}.origin-bottom-left{transform-origin:bottom left}.origin-top-right{transform-origin:top right}.translate-x-6{--tw-translate-x:1.5rem}.translate-x-0,.translate-x-6{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-0{--tw-translate-x:0px}.translate-y-1{--tw-translate-y:0.25rem}.translate-y-0,.translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-0{--tw-translate-y:0px}.-rotate-90{--tw-rotate:-90deg}.-rotate-90,.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-auto{cursor:auto}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-4{gap:1rem}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-x-2{-moz-column-gap:.5rem;column-gap:.5rem}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.25rem*var(--tw-space-y-reverse));margin-top:calc(1.25rem*(1 - var(--tw-space-y-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-clip{overflow:clip}.overflow-scroll{overflow:scroll}.overflow-x-hidden{overflow-x:hidden}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-full{border-radius:9999px}.rounded-none{border-radius:0}.rounded-l-md{border-bottom-left-radius:.375rem;border-top-left-radius:.375rem}.rounded-l-none{border-bottom-left-radius:0;border-top-left-radius:0}.rounded-r-none{border-bottom-right-radius:0;border-top-right-radius:0}.rounded-r-md{border-bottom-right-radius:.375rem;border-top-right-radius:.375rem}.rounded-t-lg{border-top-left-radius:.5rem;border-top-right-radius:.5rem}.rounded-l{border-bottom-left-radius:.25rem;border-top-left-radius:.25rem}.rounded-r{border-bottom-right-radius:.25rem;border-top-right-radius:.25rem}.rounded-tr-none{border-top-right-radius:0}.rounded-br-none{border-bottom-right-radius:0}.rounded-tl-none{border-top-left-radius:0}.rounded-bl-none{border-bottom-left-radius:0}.border{border-width:1px}.border-2{border-width:2px}.border-x{border-left-width:1px;border-right-width:1px}.border-y{border-bottom-width:1px;border-top-width:1px}.border-t{border-top-width:1px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-l{border-left-width:1px}.border-l-0{border-left-width:0}.border-r-0{border-right-width:0}.border-none{border-style:none}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.border-transparent{border-color:transparent}.border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-indigo-500{--tw-border-opacity:1;border-color:rgb(99 102 241/var(--tw-border-opacity))}.border-gray-400{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity))}.border-r-gray-200{--tw-border-opacity:1;border-right-color:rgb(229 231 235/var(--tw-border-opacity))}.border-l-amber-900{--tw-border-opacity:1;border-left-color:rgb(120 53 15/var(--tw-border-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-indigo-600{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}.bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity))}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-indigo-100{--tw-bg-opacity:1;background-color:rgb(224 231 255/var(--tw-bg-opacity))}.bg-yellow-200{--tw-bg-opacity:1;background-color:rgb(254 240 138/var(--tw-bg-opacity))}.bg-yellow-700{--tw-bg-opacity:1;background-color:rgb(161 98 7/var(--tw-bg-opacity))}.bg-gray-600{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity))}.bg-indigo-50{--tw-bg-opacity:1;background-color:rgb(238 242 255/var(--tw-bg-opacity))}.bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.bg-indigo-500{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-inherit{background-color:inherit}.bg-indigo-400{--tw-bg-opacity:1;background-color:rgb(129 140 248/var(--tw-bg-opacity))}.bg-opacity-90{--tw-bg-opacity:0.9}.fill-transparent{fill:transparent}.fill-current{fill:currentColor}.stroke-gray-300{stroke:#d1d5db}.stroke-white{stroke:#fff}.stroke-\[3\]{stroke-width:3}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-10{padding:2.5rem}.p-4{padding:1rem}.p-1\.5{padding:.375rem}.p-1{padding:.25rem}.p-\[6px\]{padding:6px}.px-2{padding-left:.5rem;padding-right:.5rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.px-4{padding-left:1rem;padding-right:1rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.px-3{padding-left:.75rem;padding-right:.75rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-0{padding-bottom:0;padding-top:0}.px-1{padding-left:.25rem;padding-right:.25rem}.px-8{padding-left:2rem;padding-right:2rem}.pr-0{padding-right:0}.pt-2{padding-top:.5rem}.pl-3{padding-left:.75rem}.pr-9{padding-right:2.25rem}.pb-4{padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pb-\[10px\]{padding-bottom:10px}.pt-0{padding-top:0}.pr-4{padding-right:1rem}.pl-1{padding-left:.25rem}.pr-10{padding-right:2.5rem}.pr-2{padding-right:.5rem}.pl-5{padding-left:1.25rem}.pr-\[1\.7rem\]{padding-right:1.7rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.align-top{vertical-align:top}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.text-base{font-size:1rem;line-height:1.5rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-\[10px\]{font-size:10px}.text-lg{font-size:1.125rem;line-height:1.75rem}.font-semibold{font-weight:600}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.uppercase{text-transform:uppercase}.capitalize{text-transform:capitalize}.leading-6{line-height:1.5rem}.leading-5{line-height:1.25rem}.text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-gray-100{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-indigo-600{--tw-text-opacity:1;color:rgb(79 70 229/var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity))}.\!text-indigo-600{--tw-text-opacity:1!important;color:rgb(79 70 229/var(--tw-text-opacity))!important}.text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.opacity-100{opacity:1}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-90{opacity:.9}.shadow-\[0_0_10px_2px_rgba\(0\2c 0\2c 0\2c 0\.3\)\]{--tw-shadow:0 0 10px 2px rgba(0,0,0,.3);--tw-shadow-colored:0 0 10px 2px var(--tw-shadow-color)}.shadow-\[0_0_10px_2px_rgba\(0\2c 0\2c 0\2c 0\.3\)\],.shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.shadow-md,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.ring-0,.ring-1{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-0{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)}.ring-black{--tw-ring-opacity:1;--tw-ring-color:rgb(0 0 0/var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity:0.05}.blur{--tw-blur:blur(8px)}.blur,.invert{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.invert{--tw-invert:invert(100%)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-100{transition-duration:.1s}.duration-200{transition-duration:.2s}.duration-150{transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.\[stroke-dasharray\:6\2c 4\]{stroke-dasharray:6,4}.\[stroke-linecap\:round\]{stroke-linecap:round}.\[stroke-linejoin\:round\]{stroke-linejoin:round}.hover\:whitespace-normal:hover{white-space:normal}.hover\:bg-gray-200:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.hover\:bg-indigo-600:hover{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.hover\:bg-\[\#62626212\]:hover{background-color:#62626212}.hover\:bg-indigo-200:hover{--tw-bg-opacity:1;background-color:rgb(199 210 254/var(--tw-bg-opacity))}.hover\:text-white:hover{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.focus\:border-indigo-500:focus{--tw-border-opacity:1;border-color:rgb(99 102 241/var(--tw-border-opacity))}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-1:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.focus\:ring-1:focus,.focus\:ring-2:focus{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\:ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.focus\:ring-0:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\:ring-indigo-500:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(99 102 241/var(--tw-ring-opacity))}.focus\:ring-indigo-600:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(79 70 229/var(--tw-ring-opacity))}.focus\:ring-offset-2:focus{--tw-ring-offset-width:2px}.focus-visible\:ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\:ring-white\/75:focus-visible{--tw-ring-color:hsla(0,0%,100%,.75)}.focus-visible\:ring-white:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity))}.focus-visible\:ring-opacity-75:focus-visible{--tw-ring-opacity:0.75}.group:hover .group-hover\:flex{display:flex}[class~=theme-dark] .dark\:border-gray-500{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-gray-600{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-gray-700{--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-r-gray-700{--tw-border-opacity:1;border-right-color:rgb(55 65 81/var(--tw-border-opacity))}[class~=theme-dark] .dark\:bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-indigo-700{--tw-bg-opacity:1;background-color:rgb(67 56 202/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-yellow-700{--tw-bg-opacity:1;background-color:rgb(161 98 7/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-600{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-indigo-500{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-opacity-80{--tw-bg-opacity:0.8}[class~=theme-dark] .dark\:stroke-gray-500{stroke:#6b7280}[class~=theme-dark] .dark\:stroke-gray-700{stroke:#374151}[class~=theme-dark] .dark\:text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-200{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-50{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-indigo-500{--tw-text-opacity:1;color:rgb(99 102 241/var(--tw-text-opacity))}[class~=theme-dark] .dark\:\!text-indigo-400{--tw-text-opacity:1!important;color:rgb(129 140 248/var(--tw-text-opacity))!important}[class~=theme-dark] .dark\:ring-white{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity))}[class~=theme-dark] .dark\:ring-opacity-20{--tw-ring-opacity:0.2}[class~=theme-dark] .dark\:hover\:bg-\[\#ffffff12\]:hover{background-color:#ffffff12}[class~=theme-dark] .dark\:hover\:bg-indigo-500:hover{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}[class~=theme-dark] .hover\:dark\:text-gray-100:hover{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity))}@media (min-width:640px){.sm\:inline{display:inline}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}@media (min-width:768px){.md\:block{display:block}.md\:flex-row{flex-direction:row}}
|
|
1
|
+
/*! tailwindcss v3.2.4 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.-inset-2{bottom:-.5rem;left:-.5rem;right:-.5rem;top:-.5rem}.inset-y-0{bottom:0;top:0}.left-\[25px\]{left:25px}.left-0{left:0}.top-\[-46px\]{top:-46px}.right-0{right:0}.top-0{top:0}.bottom-3{bottom:.75rem}.top-\[-5px\]{top:-5px}.top-\[7px\]{top:7px}.right-\[6px\]{right:6px}.top-\[-1px\]{top:-1px}.left-\[18px\]{left:18px}.bottom-0{bottom:0}.left-full{left:100%}.z-50{z-index:50}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.m-auto{margin:auto}.m-2{margin:.5rem}.mx-auto{margin-left:auto;margin-right:auto}.mx-2{margin-left:.5rem;margin-right:.5rem}.my-2{margin-bottom:.5rem;margin-top:.5rem}.my-20{margin-bottom:5rem;margin-top:5rem}.my-6{margin-bottom:1.5rem;margin-top:1.5rem}.my-4{margin-bottom:1rem;margin-top:1rem}.mr-3{margin-right:.75rem}.mt-1{margin-top:.25rem}.mb-2{margin-bottom:.5rem}.mb-0\.5{margin-bottom:.125rem}.mt-1\.5{margin-top:.375rem}.mb-0{margin-bottom:0}.ml-auto{margin-left:auto}.mb-4{margin-bottom:1rem}.mr-2{margin-right:.5rem}.ml-3{margin-left:.75rem}.ml-2{margin-left:.5rem}.mr-6{margin-right:1.5rem}.mr-1{margin-right:.25rem}.mb-1{margin-bottom:.25rem}.ml-4{margin-left:1rem}.ml-7{margin-left:1.75rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-8{margin-top:2rem}.mt-0{margin-top:0}.ml-1{margin-left:.25rem}.mt-2{margin-top:.5rem}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.\!flex{display:flex!important}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.hidden{display:none}.h-fit{height:-moz-fit-content;height:fit-content}.h-10{height:2.5rem}.h-\[38px\]{height:38px}.h-auto{height:auto}.h-full{height:100%}.h-1{height:.25rem}.h-\[20px\]{height:20px}.h-\[16px\]{height:16px}.h-\[1px\]{height:1px}.h-\[45px\]{height:45px}.h-\[30px\]{height:30px}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-4{height:1rem}.h-\[700px\]{height:700px}.h-\[80vh\]{height:80vh}.h-\[14px\]{height:14px}.max-h-\[400px\]{max-height:400px}.max-h-\[50vh\]{max-height:50vh}.max-h-\[300px\]{max-height:300px}.min-h-52{min-height:13rem}.min-h-48{min-height:12rem}.min-h-96{min-height:24rem}.min-h-\[700px\]{min-height:700px}.w-full{width:100%}.w-auto{width:auto}.w-1\/4{width:25%}.w-3\/4{width:75%}.w-\[500px\]{width:500px}.w-40{width:10rem}.w-\[44px\]{width:44px}.w-\[16px\]{width:16px}.w-max{width:-moz-max-content;width:max-content}.w-\[270px\]{width:270px}.w-5{width:1.25rem}.w-3{width:.75rem}.w-7{width:1.75rem}.w-9{width:2.25rem}.w-11{width:2.75rem}.w-\[52px\]{width:52px}.w-\[68px\]{width:68px}.w-\[76px\]{width:76px}.w-\[84px\]{width:84px}.w-\[92px\]{width:92px}.w-\[100px\]{width:100px}.w-\[108px\]{width:108px}.w-\[116px\]{width:116px}.w-4{width:1rem}.w-\[18px\]{width:18px}.w-8{width:2rem}.w-44{width:11rem}.w-\[460px\]{width:460px}.w-\[19\.25\%\]{width:19.25%}.w-11\/12{width:91.666667%}.w-1\/12{width:8.333333%}.w-64{width:16rem}.w-\[14px\]{width:14px}.w-16{width:4rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-\[420px\]{width:420px}.w-48{width:12rem}.w-\[246px\]{width:246px}.w-56{width:14rem}.min-w-\[300px\]{min-width:300px}.min-w-\[400px\]{min-width:400px}.max-w-\[500px\]{max-width:500px}.max-w-80{max-width:20rem}.max-w-48{max-width:12rem}.max-w-\[300px\]{max-width:300px}.max-w-\[400px\]{max-width:400px}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.shrink{flex-shrink:1}.flex-grow-0{flex-grow:0}.flex-grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.origin-top-left{transform-origin:top left}.origin-bottom-left{transform-origin:bottom left}.origin-top-right{transform-origin:top right}.translate-x-6{--tw-translate-x:1.5rem}.translate-x-0,.translate-x-6{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-0{--tw-translate-x:0px}.translate-y-1{--tw-translate-y:0.25rem}.translate-y-0,.translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-0{--tw-translate-y:0px}.-rotate-90{--tw-rotate:-90deg}.-rotate-90,.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-auto{cursor:auto}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-4{gap:1rem}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-x-2{-moz-column-gap:.5rem;column-gap:.5rem}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.25rem*var(--tw-space-y-reverse));margin-top:calc(1.25rem*(1 - var(--tw-space-y-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-clip{overflow:clip}.overflow-scroll{overflow:scroll}.overflow-x-hidden{overflow-x:hidden}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-full{border-radius:9999px}.rounded-none{border-radius:0}.rounded-l-md{border-bottom-left-radius:.375rem;border-top-left-radius:.375rem}.rounded-l-none{border-bottom-left-radius:0;border-top-left-radius:0}.rounded-r-none{border-bottom-right-radius:0;border-top-right-radius:0}.rounded-r-md{border-bottom-right-radius:.375rem;border-top-right-radius:.375rem}.rounded-t-lg{border-top-left-radius:.5rem;border-top-right-radius:.5rem}.rounded-l{border-bottom-left-radius:.25rem;border-top-left-radius:.25rem}.rounded-r{border-bottom-right-radius:.25rem;border-top-right-radius:.25rem}.rounded-tr-none{border-top-right-radius:0}.rounded-br-none{border-bottom-right-radius:0}.rounded-tl-none{border-top-left-radius:0}.rounded-bl-none{border-bottom-left-radius:0}.border{border-width:1px}.border-2{border-width:2px}.border-x{border-left-width:1px;border-right-width:1px}.border-y{border-bottom-width:1px;border-top-width:1px}.border-t{border-top-width:1px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-l{border-left-width:1px}.border-l-0{border-left-width:0}.border-r-0{border-right-width:0}.border-none{border-style:none}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.border-transparent{border-color:transparent}.border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-indigo-500{--tw-border-opacity:1;border-color:rgb(99 102 241/var(--tw-border-opacity))}.border-gray-400{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity))}.border-r-gray-200{--tw-border-opacity:1;border-right-color:rgb(229 231 235/var(--tw-border-opacity))}.border-l-amber-900{--tw-border-opacity:1;border-left-color:rgb(120 53 15/var(--tw-border-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-indigo-600{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}.bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity))}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-indigo-100{--tw-bg-opacity:1;background-color:rgb(224 231 255/var(--tw-bg-opacity))}.bg-yellow-200{--tw-bg-opacity:1;background-color:rgb(254 240 138/var(--tw-bg-opacity))}.bg-yellow-700{--tw-bg-opacity:1;background-color:rgb(161 98 7/var(--tw-bg-opacity))}.bg-gray-600{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity))}.bg-indigo-50{--tw-bg-opacity:1;background-color:rgb(238 242 255/var(--tw-bg-opacity))}.bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.bg-indigo-500{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-inherit{background-color:inherit}.bg-indigo-400{--tw-bg-opacity:1;background-color:rgb(129 140 248/var(--tw-bg-opacity))}.bg-opacity-90{--tw-bg-opacity:0.9}.fill-transparent{fill:transparent}.fill-current{fill:currentColor}.stroke-gray-300{stroke:#d1d5db}.stroke-white{stroke:#fff}.stroke-\[3\]{stroke-width:3}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-10{padding:2.5rem}.p-4{padding:1rem}.p-1\.5{padding:.375rem}.p-1{padding:.25rem}.p-\[6px\]{padding:6px}.px-2{padding-left:.5rem;padding-right:.5rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.px-4{padding-left:1rem;padding-right:1rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.px-3{padding-left:.75rem;padding-right:.75rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-0{padding-bottom:0;padding-top:0}.px-1{padding-left:.25rem;padding-right:.25rem}.px-8{padding-left:2rem;padding-right:2rem}.pr-0{padding-right:0}.pt-2{padding-top:.5rem}.pl-3{padding-left:.75rem}.pr-9{padding-right:2.25rem}.pb-4{padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pb-\[10px\]{padding-bottom:10px}.pt-0{padding-top:0}.pr-4{padding-right:1rem}.pl-1{padding-left:.25rem}.pr-10{padding-right:2.5rem}.pr-2{padding-right:.5rem}.pl-5{padding-left:1.25rem}.pr-\[1\.7rem\]{padding-right:1.7rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.align-top{vertical-align:top}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.text-base{font-size:1rem;line-height:1.5rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-\[10px\]{font-size:10px}.text-lg{font-size:1.125rem;line-height:1.75rem}.font-semibold{font-weight:600}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.uppercase{text-transform:uppercase}.capitalize{text-transform:capitalize}.leading-6{line-height:1.5rem}.leading-5{line-height:1.25rem}.text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-gray-100{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-indigo-600{--tw-text-opacity:1;color:rgb(79 70 229/var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity))}.\!text-indigo-600{--tw-text-opacity:1!important;color:rgb(79 70 229/var(--tw-text-opacity))!important}.text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.opacity-100{opacity:1}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-90{opacity:.9}.shadow-\[0_0_10px_2px_rgba\(0\2c 0\2c 0\2c 0\.3\)\]{--tw-shadow:0 0 10px 2px rgba(0,0,0,.3);--tw-shadow-colored:0 0 10px 2px var(--tw-shadow-color)}.shadow-\[0_0_10px_2px_rgba\(0\2c 0\2c 0\2c 0\.3\)\],.shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.shadow-md,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.ring-0,.ring-1{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-0{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)}.ring-black{--tw-ring-opacity:1;--tw-ring-color:rgb(0 0 0/var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity:0.05}.blur{--tw-blur:blur(8px)}.blur,.invert{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.invert{--tw-invert:invert(100%)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-100{transition-duration:.1s}.duration-200{transition-duration:.2s}.duration-150{transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.\[stroke-dasharray\:6\2c 4\]{stroke-dasharray:6,4}.\[stroke-linecap\:round\]{stroke-linecap:round}.\[stroke-linejoin\:round\]{stroke-linejoin:round}.hover\:whitespace-normal:hover{white-space:normal}.hover\:bg-gray-200:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.hover\:bg-indigo-600:hover{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.hover\:bg-\[\#62626212\]:hover{background-color:#62626212}.hover\:bg-indigo-200:hover{--tw-bg-opacity:1;background-color:rgb(199 210 254/var(--tw-bg-opacity))}.hover\:text-white:hover{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.focus\:border-indigo-500:focus{--tw-border-opacity:1;border-color:rgb(99 102 241/var(--tw-border-opacity))}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-1:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.focus\:ring-1:focus,.focus\:ring-2:focus{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\:ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.focus\:ring-0:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\:ring-indigo-500:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(99 102 241/var(--tw-ring-opacity))}.focus\:ring-indigo-600:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(79 70 229/var(--tw-ring-opacity))}.focus\:ring-offset-2:focus{--tw-ring-offset-width:2px}.focus-visible\:ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\:ring-white\/75:focus-visible{--tw-ring-color:hsla(0,0%,100%,.75)}.focus-visible\:ring-white:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity))}.focus-visible\:ring-opacity-75:focus-visible{--tw-ring-opacity:0.75}.group:hover .group-hover\:flex{display:flex}[class~=theme-dark] .dark\:border-gray-500{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-gray-600{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-gray-700{--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity))}[class~=theme-dark] .dark\:border-r-gray-700{--tw-border-opacity:1;border-right-color:rgb(55 65 81/var(--tw-border-opacity))}[class~=theme-dark] .dark\:bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-indigo-700{--tw-bg-opacity:1;background-color:rgb(67 56 202/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-yellow-700{--tw-bg-opacity:1;background-color:rgb(161 98 7/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-600{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-indigo-500{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-opacity-80{--tw-bg-opacity:0.8}[class~=theme-dark] .dark\:stroke-gray-500{stroke:#6b7280}[class~=theme-dark] .dark\:stroke-gray-700{stroke:#374151}[class~=theme-dark] .dark\:text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-200{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-50{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-indigo-500{--tw-text-opacity:1;color:rgb(99 102 241/var(--tw-text-opacity))}[class~=theme-dark] .dark\:\!text-indigo-400{--tw-text-opacity:1!important;color:rgb(129 140 248/var(--tw-text-opacity))!important}[class~=theme-dark] .dark\:ring-white{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity))}[class~=theme-dark] .dark\:ring-opacity-20{--tw-ring-opacity:0.2}[class~=theme-dark] .dark\:hover\:bg-\[\#ffffff12\]:hover{background-color:#ffffff12}[class~=theme-dark] .dark\:hover\:bg-indigo-500:hover{--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity))}[class~=theme-dark] .hover\:dark\:text-gray-100:hover{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity))}@media (min-width:640px){.sm\:inline{display:inline}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}@media (min-width:768px){.md\:block{display:block}.md\:flex-row{flex-direction:row}}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parca/profile",
|
|
3
|
-
"version": "0.16.
|
|
3
|
+
"version": "0.16.435",
|
|
4
4
|
"description": "Profile viewing libraries",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@headlessui/react": "^1.7.19",
|
|
@@ -73,5 +73,5 @@
|
|
|
73
73
|
"access": "public",
|
|
74
74
|
"registry": "https://registry.npmjs.org/"
|
|
75
75
|
},
|
|
76
|
-
"gitHead": "
|
|
76
|
+
"gitHead": "f97dc5a4d3b5abbf82c1647279b1186c6a43b69f"
|
|
77
77
|
}
|
|
@@ -64,10 +64,8 @@ export const useGraphTooltipMetaInfo = ({table, row}: Props): GraphTooltipMetaIn
|
|
|
64
64
|
const functionStartLine: bigint = table.getChild(FIELD_FUNCTION_START_LINE)?.get(row) ?? 0n;
|
|
65
65
|
const lineNumber =
|
|
66
66
|
locationLine !== 0n ? locationLine : functionStartLine !== 0n ? functionStartLine : undefined;
|
|
67
|
-
const
|
|
68
|
-
const labelColumnNames = table.schema.fields.filter(field =>
|
|
69
|
-
field.name.startsWith(pprofLabelPrefix)
|
|
70
|
-
);
|
|
67
|
+
const labelPrefix = 'labels.';
|
|
68
|
+
const labelColumnNames = table.schema.fields.filter(field => field.name.startsWith(labelPrefix));
|
|
71
69
|
|
|
72
70
|
const {queryServiceClient, enableSourcesView} = useParcaContext();
|
|
73
71
|
const {profileSource} = useProfileViewContext();
|
|
@@ -101,7 +99,7 @@ export const useGraphTooltipMetaInfo = ({table, row}: Props): GraphTooltipMetaIn
|
|
|
101
99
|
|
|
102
100
|
const labelPairs: Array<[string, string]> = labelColumnNames
|
|
103
101
|
.map((field, i) => [
|
|
104
|
-
labelColumnNames[i].name.slice(
|
|
102
|
+
labelColumnNames[i].name.slice(labelPrefix.length),
|
|
105
103
|
arrowToString(table.getChild(field.name)?.get(row)) ?? '',
|
|
106
104
|
])
|
|
107
105
|
.filter(value => value[1] !== '') as Array<[string, string]>;
|
|
@@ -46,14 +46,15 @@ export const useLabelNames = (
|
|
|
46
46
|
client: QueryServiceClient,
|
|
47
47
|
profileType: string,
|
|
48
48
|
start?: number,
|
|
49
|
-
end?: number
|
|
49
|
+
end?: number,
|
|
50
|
+
match?: string[]
|
|
50
51
|
): UseLabelNames => {
|
|
51
52
|
const metadata = useGrpcMetadata();
|
|
52
53
|
|
|
53
54
|
const {data, isLoading, error} = useGrpcQuery<LabelsResponse>({
|
|
54
|
-
key: ['labelNames', profileType],
|
|
55
|
+
key: ['labelNames', profileType, match?.join(',')],
|
|
55
56
|
queryFn: async () => {
|
|
56
|
-
const request: LabelsRequest = {match: []};
|
|
57
|
+
const request: LabelsRequest = {match: match !== undefined ? match : []};
|
|
57
58
|
if (start !== undefined && end !== undefined) {
|
|
58
59
|
request.start = millisToProtoTimestamp(start);
|
|
59
60
|
request.end = millisToProtoTimestamp(end);
|
|
@@ -210,9 +210,6 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({
|
|
|
210
210
|
const highlightSimilarStacksSetName = useMemo(() => {
|
|
211
211
|
return highlightSimilarStacksPreference ? setHoveringName : noop;
|
|
212
212
|
}, [highlightSimilarStacksPreference]);
|
|
213
|
-
const highlightSimilarStacksSetLevel = useMemo(() => {
|
|
214
|
-
return highlightSimilarStacksPreference ? setHoveringLevel : noop;
|
|
215
|
-
}, [highlightSimilarStacksPreference]);
|
|
216
213
|
const highlightSimilarStacksRow = highlightSimilarStacksPreference ? hoveringRow : null;
|
|
217
214
|
const path = useMemo(() => {
|
|
218
215
|
return [];
|
|
@@ -248,7 +245,7 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({
|
|
|
248
245
|
isRoot={true}
|
|
249
246
|
searchString={(currentSearchString as string) ?? ''}
|
|
250
247
|
setHoveringRow={setHoveringRow}
|
|
251
|
-
setHoveringLevel={
|
|
248
|
+
setHoveringLevel={setHoveringLevel}
|
|
252
249
|
sortBy={sortBy}
|
|
253
250
|
darkMode={isDarkMode}
|
|
254
251
|
compareMode={compareMode}
|
|
@@ -285,7 +282,6 @@ export const IcicleGraphArrow = memo(function IcicleGraphArrow({
|
|
|
285
282
|
colorForSimilarNodes,
|
|
286
283
|
highlightSimilarStacksPreference,
|
|
287
284
|
path,
|
|
288
|
-
highlightSimilarStacksSetLevel,
|
|
289
285
|
highlightSimilarStacksSetName,
|
|
290
286
|
]);
|
|
291
287
|
|
|
@@ -30,20 +30,16 @@ export function nodeLabel(
|
|
|
30
30
|
level: number,
|
|
31
31
|
showBinaryName: boolean
|
|
32
32
|
): string {
|
|
33
|
-
const functionName: string | null = arrowToString(table.getChild(FIELD_FUNCTION_NAME)?.get(row));
|
|
34
33
|
const labelsOnly: boolean | null = table.getChild(FIELD_LABELS_ONLY)?.get(row);
|
|
35
|
-
const pprofLabelPrefix = 'pprof_labels.';
|
|
36
|
-
const labelColumnNames = table.schema.fields.filter(field =>
|
|
37
|
-
field.name.startsWith(pprofLabelPrefix)
|
|
38
|
-
);
|
|
39
|
-
if (functionName !== null && functionName !== '') {
|
|
40
|
-
return functionName;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
34
|
if (level === 1 && labelsOnly !== null && labelsOnly) {
|
|
35
|
+
const labelPrefix = 'labels.';
|
|
36
|
+
const labelColumnNames = table.schema.fields.filter(field =>
|
|
37
|
+
field.name.startsWith(labelPrefix)
|
|
38
|
+
);
|
|
39
|
+
|
|
44
40
|
return labelColumnNames
|
|
45
41
|
.map((field, i) => [
|
|
46
|
-
labelColumnNames[i].name.slice(
|
|
42
|
+
labelColumnNames[i].name.slice(labelPrefix.length),
|
|
47
43
|
arrowToString(table.getChild(field.name)?.get(row)) ?? '',
|
|
48
44
|
])
|
|
49
45
|
.filter(value => value[1] !== '')
|
|
@@ -51,6 +47,11 @@ export function nodeLabel(
|
|
|
51
47
|
.join(', ');
|
|
52
48
|
}
|
|
53
49
|
|
|
50
|
+
const functionName: string | null = arrowToString(table.getChild(FIELD_FUNCTION_NAME)?.get(row));
|
|
51
|
+
if (functionName !== null && functionName !== '') {
|
|
52
|
+
return functionName;
|
|
53
|
+
}
|
|
54
|
+
|
|
54
55
|
let mappingString = '';
|
|
55
56
|
if (showBinaryName) {
|
|
56
57
|
const mappingFile: string | null = table.getChild(FIELD_MAPPING_FILE)?.get(row) ?? '';
|
|
@@ -58,6 +58,7 @@ export interface FlamegraphData {
|
|
|
58
58
|
error?: any;
|
|
59
59
|
mappings?: string[];
|
|
60
60
|
mappingsLoading: boolean;
|
|
61
|
+
groupByLabels: string[];
|
|
61
62
|
}
|
|
62
63
|
|
|
63
64
|
export interface TopTableData {
|
|
@@ -396,6 +397,7 @@ export const ProfileView = ({
|
|
|
396
397
|
filtered={filtered}
|
|
397
398
|
currentSearchString={currentSearchString}
|
|
398
399
|
setSearchString={setSearchString}
|
|
400
|
+
groupByLabels={flamegraphData.groupByLabels ?? []}
|
|
399
401
|
/>
|
|
400
402
|
|
|
401
403
|
<div className="w-full" ref={ref}>
|
|
@@ -17,8 +17,9 @@ import {QueryRequest_ReportType, QueryServiceClient} from '@parca/client';
|
|
|
17
17
|
import {useGrpcMetadata, useParcaContext, useURLState} from '@parca/components';
|
|
18
18
|
import {saveAsBlob} from '@parca/utilities';
|
|
19
19
|
|
|
20
|
+
import {useLabelNames} from './MatchersInput';
|
|
20
21
|
import {FIELD_FUNCTION_NAME} from './ProfileIcicleGraph/IcicleGraphArrow';
|
|
21
|
-
import {ProfileSource} from './ProfileSource';
|
|
22
|
+
import {MergedProfileSource, ProfileSource} from './ProfileSource';
|
|
22
23
|
import {ProfileView} from './ProfileView';
|
|
23
24
|
import {useQuery} from './useQuery';
|
|
24
25
|
import {downloadPprof} from './utils';
|
|
@@ -76,6 +77,19 @@ export const ProfileViewWithData = ({
|
|
|
76
77
|
binaryFrameFilter,
|
|
77
78
|
});
|
|
78
79
|
|
|
80
|
+
const mergedProfileSource = profileSource as MergedProfileSource;
|
|
81
|
+
const matchers = mergedProfileSource.query.matchers.map(
|
|
82
|
+
m => `${m.key}${m.matcherType}"${m.value}"`
|
|
83
|
+
);
|
|
84
|
+
|
|
85
|
+
const {result: profileLabelsResponse} = useLabelNames(
|
|
86
|
+
queryClient,
|
|
87
|
+
profileSource.ProfileType().toString(),
|
|
88
|
+
undefined,
|
|
89
|
+
undefined,
|
|
90
|
+
matchers
|
|
91
|
+
);
|
|
92
|
+
|
|
79
93
|
const {isLoading: profilemetadataLoading, response: profilemetadataResponse} = useQuery(
|
|
80
94
|
queryClient,
|
|
81
95
|
profileSource,
|
|
@@ -204,6 +218,7 @@ export const ProfileViewWithData = ({
|
|
|
204
218
|
? profilemetadataResponse?.report?.profileMetadata?.mappingFiles
|
|
205
219
|
: undefined,
|
|
206
220
|
mappingsLoading: profilemetadataLoading,
|
|
221
|
+
groupByLabels: profileLabelsResponse.response?.labelNames ?? [],
|
|
207
222
|
}}
|
|
208
223
|
topTableData={{
|
|
209
224
|
loading: tableLoading,
|
|
@@ -11,8 +11,13 @@
|
|
|
11
11
|
// See the License for the specific language governing permissions and
|
|
12
12
|
// limitations under the License.
|
|
13
13
|
|
|
14
|
-
import {
|
|
14
|
+
import React, {useEffect, useRef, useState} from 'react';
|
|
15
|
+
|
|
16
|
+
import {Transition} from '@headlessui/react';
|
|
15
17
|
import {Icon} from '@iconify/react';
|
|
18
|
+
import Select from 'react-select';
|
|
19
|
+
|
|
20
|
+
import {Button} from '@parca/components';
|
|
16
21
|
|
|
17
22
|
import {
|
|
18
23
|
FIELD_FUNCTION_FILE_NAME,
|
|
@@ -22,6 +27,33 @@ import {
|
|
|
22
27
|
FIELD_MAPPING_FILE,
|
|
23
28
|
} from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
24
29
|
|
|
30
|
+
interface LabelSelectorProps {
|
|
31
|
+
labels: string[];
|
|
32
|
+
groupBy: string[];
|
|
33
|
+
setGroupByLabels: (labels: string[]) => void;
|
|
34
|
+
isOpen: boolean;
|
|
35
|
+
labelsButtonRef: React.RefObject<HTMLDivElement>;
|
|
36
|
+
setIsLabelSelectorOpen: (isOpen: boolean) => void;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
interface LabelSelectorProps {
|
|
40
|
+
labels: string[];
|
|
41
|
+
groupBy: string[];
|
|
42
|
+
setGroupByLabels: (labels: string[]) => void;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
interface LabelOption {
|
|
46
|
+
label: string;
|
|
47
|
+
value: string;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
interface GroupByDropdownProps {
|
|
51
|
+
groupBy: string[];
|
|
52
|
+
toggleGroupBy: (key: string) => void;
|
|
53
|
+
onLabelClick: () => void;
|
|
54
|
+
labelsButtonRef: React.RefObject<HTMLDivElement>;
|
|
55
|
+
}
|
|
56
|
+
|
|
25
57
|
const groupByOptions = [
|
|
26
58
|
{
|
|
27
59
|
value: FIELD_FUNCTION_NAME,
|
|
@@ -29,12 +61,6 @@ const groupByOptions = [
|
|
|
29
61
|
description: 'Stacktraces are grouped by function names.',
|
|
30
62
|
disabled: true,
|
|
31
63
|
},
|
|
32
|
-
{
|
|
33
|
-
value: FIELD_LABELS,
|
|
34
|
-
label: 'Labels',
|
|
35
|
-
description: 'Stacktraces are grouped by pprof labels.',
|
|
36
|
-
disabled: false,
|
|
37
|
-
},
|
|
38
64
|
{
|
|
39
65
|
value: FIELD_FUNCTION_FILE_NAME,
|
|
40
66
|
label: 'Filename',
|
|
@@ -55,13 +81,92 @@ const groupByOptions = [
|
|
|
55
81
|
},
|
|
56
82
|
];
|
|
57
83
|
|
|
58
|
-
const
|
|
84
|
+
const LabelSelector: React.FC<LabelSelectorProps> = ({
|
|
85
|
+
labels,
|
|
86
|
+
groupBy,
|
|
87
|
+
setGroupByLabels,
|
|
88
|
+
isOpen,
|
|
89
|
+
labelsButtonRef,
|
|
90
|
+
setIsLabelSelectorOpen,
|
|
91
|
+
}) => {
|
|
92
|
+
const [position, setPosition] = useState({top: 0, left: 0});
|
|
93
|
+
|
|
94
|
+
useEffect(() => {
|
|
95
|
+
if (isOpen && labelsButtonRef.current !== null) {
|
|
96
|
+
const rect = labelsButtonRef.current.getBoundingClientRect();
|
|
97
|
+
const parentRect = labelsButtonRef.current.offsetParent?.getBoundingClientRect() ?? {
|
|
98
|
+
top: 0,
|
|
99
|
+
left: 0,
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
setPosition({
|
|
103
|
+
top: rect.bottom - parentRect.top,
|
|
104
|
+
left: rect.right - parentRect.left + 4,
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
}, [isOpen, labelsButtonRef]);
|
|
108
|
+
|
|
109
|
+
if (!isOpen) return null;
|
|
110
|
+
|
|
111
|
+
return (
|
|
112
|
+
<div
|
|
113
|
+
className="absolute w-64 ml-4 z-20"
|
|
114
|
+
style={{
|
|
115
|
+
top: `${position.top}px`,
|
|
116
|
+
left: `${position.left}px`,
|
|
117
|
+
}}
|
|
118
|
+
>
|
|
119
|
+
<Select<LabelOption, true>
|
|
120
|
+
isMulti
|
|
121
|
+
name="labels"
|
|
122
|
+
options={labels.map(label => ({label, value: `${FIELD_LABELS}.${label}`}))}
|
|
123
|
+
className="parca-select-container text-sm w-full border-gray-300 border rounded-md"
|
|
124
|
+
classNamePrefix="parca-select parca-groupby-label"
|
|
125
|
+
value={groupBy
|
|
126
|
+
.filter(l => l.startsWith(FIELD_LABELS))
|
|
127
|
+
.map(l => ({value: l, label: l.slice(FIELD_LABELS.length + 1)}))}
|
|
128
|
+
onChange={newValue => {
|
|
129
|
+
setGroupByLabels(newValue.map(option => option.value));
|
|
130
|
+
setIsLabelSelectorOpen(false);
|
|
131
|
+
}}
|
|
132
|
+
placeholder="Select labels..."
|
|
133
|
+
styles={{
|
|
134
|
+
menu: provided => ({
|
|
135
|
+
...provided,
|
|
136
|
+
position: 'relative',
|
|
137
|
+
marginBottom: 0,
|
|
138
|
+
boxShadow: 'none',
|
|
139
|
+
marginTop: 0,
|
|
140
|
+
}),
|
|
141
|
+
control: provided => ({
|
|
142
|
+
...provided,
|
|
143
|
+
boxShadow: 'none',
|
|
144
|
+
borderBottom: '1px solid #e2e8f0',
|
|
145
|
+
borderRight: 0,
|
|
146
|
+
borderLeft: 0,
|
|
147
|
+
borderTop: 0,
|
|
148
|
+
borderBottomLeftRadius: 0,
|
|
149
|
+
borderBottomRightRadius: 0,
|
|
150
|
+
':hover': {
|
|
151
|
+
borderColor: '#e2e8f0',
|
|
152
|
+
borderBottomLeftRadius: 0,
|
|
153
|
+
borderBottomRightRadius: 0,
|
|
154
|
+
},
|
|
155
|
+
}),
|
|
156
|
+
}}
|
|
157
|
+
menuIsOpen={true}
|
|
158
|
+
/>
|
|
159
|
+
</div>
|
|
160
|
+
);
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
const GroupByDropdown: React.FC<GroupByDropdownProps> = ({
|
|
59
164
|
groupBy,
|
|
60
165
|
toggleGroupBy,
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
166
|
+
onLabelClick,
|
|
167
|
+
labelsButtonRef,
|
|
168
|
+
}) => {
|
|
169
|
+
const [isDropdownOpen, setIsDropdownOpen] = useState(false);
|
|
65
170
|
const label =
|
|
66
171
|
groupBy.length === 0
|
|
67
172
|
? 'Nothing'
|
|
@@ -69,24 +174,33 @@ const GroupByDropdown = ({
|
|
|
69
174
|
? groupByOptions.find(option => option.value === groupBy[0])?.label
|
|
70
175
|
: 'Multiple';
|
|
71
176
|
|
|
177
|
+
const selectedLabels = groupBy
|
|
178
|
+
.filter(l => l.startsWith(FIELD_LABELS))
|
|
179
|
+
.map(l => l.slice(FIELD_LABELS.length + 1));
|
|
180
|
+
|
|
72
181
|
return (
|
|
73
182
|
<div className="relative">
|
|
74
183
|
<label className="text-sm">Group</label>
|
|
75
|
-
<
|
|
76
|
-
<
|
|
184
|
+
<div className="relative text-left" id="h-group-by-filter">
|
|
185
|
+
<Button
|
|
186
|
+
variant="neutral"
|
|
187
|
+
onClick={() => setIsDropdownOpen(!isDropdownOpen)}
|
|
188
|
+
className="relative w-max cursor-default rounded-md border bg-white py-2 pl-3 pr-[1.7rem] text-left text-sm shadow-sm dark:border-gray-600 dark:bg-gray-900 sm:text-sm"
|
|
189
|
+
>
|
|
77
190
|
<span className="block overflow-x-hidden text-ellipsis">{label}</span>
|
|
78
191
|
<span className="pointer-events-none absolute inset-y-0 right-0 flex items-center pr-2 text-gray-400">
|
|
79
192
|
<Icon icon="heroicons:chevron-down-20-solid" aria-hidden="true" />
|
|
80
193
|
</span>
|
|
81
|
-
</
|
|
194
|
+
</Button>
|
|
82
195
|
|
|
83
196
|
<Transition
|
|
84
197
|
as="div"
|
|
85
198
|
leave="transition ease-in duration-100"
|
|
86
199
|
leaveFrom="opacity-100"
|
|
87
200
|
leaveTo="opacity-0"
|
|
201
|
+
show={isDropdownOpen}
|
|
88
202
|
>
|
|
89
|
-
<
|
|
203
|
+
<div className="absolute left-0 z-10 mt-1 min-w-[400px] overflow-auto rounded-md bg-gray-50 py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none dark:border-gray-600 dark:bg-gray-900 dark:ring-white dark:ring-opacity-20 sm:text-sm">
|
|
90
204
|
<div className="p-4">
|
|
91
205
|
<fieldset>
|
|
92
206
|
<div className="space-y-5">
|
|
@@ -114,14 +228,108 @@ const GroupByDropdown = ({
|
|
|
114
228
|
</div>
|
|
115
229
|
</div>
|
|
116
230
|
))}
|
|
231
|
+
<div
|
|
232
|
+
className="ml-7 flex flex-col items-start text-sm leading-6 cursor-pointer"
|
|
233
|
+
onClick={onLabelClick}
|
|
234
|
+
ref={labelsButtonRef}
|
|
235
|
+
>
|
|
236
|
+
<div className="flex justify-between w-full items-center">
|
|
237
|
+
<div>
|
|
238
|
+
<span className="font-medium text-gray-900 dark:text-gray-200">Labels</span>
|
|
239
|
+
<p className="text-gray-500 dark:text-gray-400">
|
|
240
|
+
Stacktraces are grouped by labels.
|
|
241
|
+
</p>
|
|
242
|
+
</div>
|
|
243
|
+
|
|
244
|
+
<Icon icon="flowbite:caret-right-solid" className="h-[14px] w-[14px]" />
|
|
245
|
+
</div>
|
|
246
|
+
|
|
247
|
+
{selectedLabels.length > 0 && (
|
|
248
|
+
<div className="flex gap-2 flex-wrap">
|
|
249
|
+
<span className="text-gray-500 dark:text-gray-200">Selected labels:</span>
|
|
250
|
+
|
|
251
|
+
<div className="flex">
|
|
252
|
+
{selectedLabels.map(label => (
|
|
253
|
+
<span
|
|
254
|
+
key={label}
|
|
255
|
+
className="mr-2 px-3 py-1 text-xs text-gray-700 dark:text-gray-200 bg-gray-200 rounded-md dark:bg-gray-900"
|
|
256
|
+
>
|
|
257
|
+
{label}
|
|
258
|
+
</span>
|
|
259
|
+
))}
|
|
260
|
+
</div>
|
|
261
|
+
</div>
|
|
262
|
+
)}
|
|
263
|
+
</div>
|
|
117
264
|
</div>
|
|
118
265
|
</fieldset>
|
|
119
266
|
</div>
|
|
120
|
-
</
|
|
267
|
+
</div>
|
|
121
268
|
</Transition>
|
|
122
|
-
</
|
|
269
|
+
</div>
|
|
270
|
+
</div>
|
|
271
|
+
);
|
|
272
|
+
};
|
|
273
|
+
|
|
274
|
+
interface GroupByControlsProps {
|
|
275
|
+
groupBy: string[];
|
|
276
|
+
labels: string[];
|
|
277
|
+
toggleGroupBy: (key: string) => void;
|
|
278
|
+
setGroupByLabels: (labels: string[]) => void;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
const GroupByControls: React.FC<GroupByControlsProps> = ({
|
|
282
|
+
groupBy,
|
|
283
|
+
labels,
|
|
284
|
+
toggleGroupBy,
|
|
285
|
+
setGroupByLabels,
|
|
286
|
+
}) => {
|
|
287
|
+
const [isLabelSelectorOpen, setIsLabelSelectorOpen] = useState(false);
|
|
288
|
+
|
|
289
|
+
const labelsButton = useRef<HTMLDivElement>(null);
|
|
290
|
+
const labelSelectorRef = useRef<HTMLDivElement>(null);
|
|
291
|
+
|
|
292
|
+
useEffect(() => {
|
|
293
|
+
const handleClickOutside = (event: MouseEvent): void => {
|
|
294
|
+
if (
|
|
295
|
+
isLabelSelectorOpen &&
|
|
296
|
+
labelSelectorRef.current !== null &&
|
|
297
|
+
!labelSelectorRef.current.contains(event.target as Node) &&
|
|
298
|
+
labelsButton.current !== null &&
|
|
299
|
+
!labelsButton.current.contains(event.target as Node)
|
|
300
|
+
) {
|
|
301
|
+
setIsLabelSelectorOpen(false);
|
|
302
|
+
}
|
|
303
|
+
};
|
|
304
|
+
|
|
305
|
+
document.addEventListener('mousedown', handleClickOutside);
|
|
306
|
+
return () => {
|
|
307
|
+
document.removeEventListener('mousedown', handleClickOutside);
|
|
308
|
+
};
|
|
309
|
+
}, [isLabelSelectorOpen]);
|
|
310
|
+
|
|
311
|
+
return (
|
|
312
|
+
<div className="inline-flex items-start">
|
|
313
|
+
<div className="relative flex items-start">
|
|
314
|
+
<GroupByDropdown
|
|
315
|
+
groupBy={groupBy}
|
|
316
|
+
toggleGroupBy={toggleGroupBy}
|
|
317
|
+
onLabelClick={() => setIsLabelSelectorOpen(!isLabelSelectorOpen)}
|
|
318
|
+
labelsButtonRef={labelsButton}
|
|
319
|
+
/>
|
|
320
|
+
<div ref={labelSelectorRef}>
|
|
321
|
+
<LabelSelector
|
|
322
|
+
labels={labels}
|
|
323
|
+
groupBy={groupBy}
|
|
324
|
+
setGroupByLabels={setGroupByLabels}
|
|
325
|
+
isOpen={isLabelSelectorOpen}
|
|
326
|
+
labelsButtonRef={labelsButton}
|
|
327
|
+
setIsLabelSelectorOpen={setIsLabelSelectorOpen}
|
|
328
|
+
/>
|
|
329
|
+
</div>
|
|
330
|
+
</div>
|
|
123
331
|
</div>
|
|
124
332
|
);
|
|
125
333
|
};
|
|
126
334
|
|
|
127
|
-
export default
|
|
335
|
+
export default GroupByControls;
|
|
@@ -20,7 +20,7 @@ import {QueryRequest, QueryServiceClient} from '@parca/client';
|
|
|
20
20
|
import {Button, UserPreferencesModal, useParcaContext, useURLState} from '@parca/components';
|
|
21
21
|
import {ProfileType} from '@parca/parser';
|
|
22
22
|
|
|
23
|
-
import {FIELD_FUNCTION_NAME} from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
23
|
+
import {FIELD_FUNCTION_NAME, FIELD_LABELS} from '../../ProfileIcicleGraph/IcicleGraphArrow';
|
|
24
24
|
import {ProfileSource} from '../../ProfileSource';
|
|
25
25
|
import GroupByDropdown from '../ActionButtons/GroupByDropdown';
|
|
26
26
|
import FilterByFunctionButton from '../FilterByFunctionButton';
|
|
@@ -47,6 +47,7 @@ interface Props {
|
|
|
47
47
|
filtered: bigint;
|
|
48
48
|
setSearchString?: (searchString: string) => void;
|
|
49
49
|
currentSearchString?: string;
|
|
50
|
+
groupByLabels: string[];
|
|
50
51
|
}
|
|
51
52
|
|
|
52
53
|
const VisualisationToolbar = ({
|
|
@@ -62,6 +63,7 @@ const VisualisationToolbar = ({
|
|
|
62
63
|
filtered,
|
|
63
64
|
setSearchString,
|
|
64
65
|
currentSearchString,
|
|
66
|
+
groupByLabels,
|
|
65
67
|
}: Props): JSX.Element => {
|
|
66
68
|
const [dashboardItems] = useURLState<string[]>('dashboard_items', {
|
|
67
69
|
alwaysReturnArray: true,
|
|
@@ -90,6 +92,13 @@ const VisualisationToolbar = ({
|
|
|
90
92
|
[groupBy, setGroupBy]
|
|
91
93
|
);
|
|
92
94
|
|
|
95
|
+
const setGroupByLabels = useCallback(
|
|
96
|
+
(labels: string[]): void => {
|
|
97
|
+
setGroupBy(groupBy.filter(l => !l.startsWith(`${FIELD_LABELS}.`)).concat(labels));
|
|
98
|
+
},
|
|
99
|
+
[groupBy, setGroupBy]
|
|
100
|
+
);
|
|
101
|
+
|
|
93
102
|
const clearSelection = useCallback((): void => {
|
|
94
103
|
setSearchString?.('');
|
|
95
104
|
}, [setSearchString]);
|
|
@@ -114,7 +123,12 @@ const VisualisationToolbar = ({
|
|
|
114
123
|
<div className="flex gap-3 items-end">
|
|
115
124
|
{isGraphViz && (
|
|
116
125
|
<>
|
|
117
|
-
<GroupByDropdown
|
|
126
|
+
<GroupByDropdown
|
|
127
|
+
groupBy={groupBy}
|
|
128
|
+
toggleGroupBy={toggleGroupBy}
|
|
129
|
+
labels={groupByLabels}
|
|
130
|
+
setGroupByLabels={setGroupByLabels}
|
|
131
|
+
/>
|
|
118
132
|
<MultiLevelDropdown profileType={profileType} onSelect={() => {}} />
|
|
119
133
|
<Button
|
|
120
134
|
variant="neutral"
|