@parca/profile 0.16.234 → 0.16.235

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,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.235](https://github.com/parca-dev/parca/compare/@parca/profile@0.16.234...@parca/profile@0.16.235) (2023-08-28)
7
+
8
+ **Note:** Version bump only for package @parca/profile
9
+
6
10
  ## [0.16.234](https://github.com/parca-dev/parca/compare/@parca/profile@0.16.233...@parca/profile@0.16.234) (2023-08-28)
7
11
 
8
12
  **Note:** Version bump only for package @parca/profile
@@ -119,11 +119,10 @@ const ProfileSelector = ({ queryClient, querySelection, selectProfile, selectQue
119
119
  queryExpressionString === '' ||
120
120
  queryExpressionString === '{}';
121
121
  const compareDisabled = selectedProfileName === '' || querySelection.expression === undefined;
122
- const Header = () => (_jsxs("div", { className: "mb-2 flex", children: [_jsxs("div", { className: "flex w-full flex-wrap content-start items-end justify-between gap-2", children: [_jsxs("div", { children: [_jsx("label", { className: "text-xs", children: "Profile type" }), _jsx(ProfileTypeSelector, { profileTypesData: profileTypesData, loading: profileTypesLoading, selectedKey: selectedProfileName, onSelection: setProfileName, error: error })] }), _jsxs("div", { className: "w-full flex-1", children: [_jsx("label", { className: "text-xs", children: "Query" }), _jsx(MatchersInput, { queryClient: queryClient, setMatchersString: setMatchersString, runQuery: setQueryExpression, currentQuery: query })] }), _jsxs("div", { children: [_jsx("label", { className: "text-xs", children: "Period" }), _jsx(DateTimeRangePicker, { onRangeSelection: setTimeRangeSelection, range: timeRangeSelection })] }), _jsxs(ButtonGroup, { children: [!searchDisabled && (_jsx(_Fragment, { children: !comparing && (_jsx(CompareButton, { disabled: compareDisabled, onClick: handleCompareClick })) })), _jsx(Button, { disabled: searchDisabled, onClick: (e) => {
123
- e.preventDefault();
124
- setQueryExpression();
125
- }, children: "Search" })] })] }), _jsx("div", { children: comparing && _jsx(IconButton, { onClick: () => closeProfile(), icon: _jsx(CloseIcon, {}) }) })] }));
126
- return (_jsxs(_Fragment, { children: [_jsx(Header, {}), _jsx("div", { className: "rounded bg-white shadow dark:border-gray-500 dark:bg-gray-700", children: _jsx("div", { style: { height: heightStyle }, children: querySelection.expression !== undefined &&
122
+ return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "mb-2 flex", children: [_jsxs("div", { className: "flex w-full flex-wrap content-start items-end justify-between gap-2", children: [_jsxs("div", { children: [_jsx("label", { className: "text-xs", children: "Profile type" }), _jsx(ProfileTypeSelector, { profileTypesData: profileTypesData, loading: profileTypesLoading, selectedKey: selectedProfileName, onSelection: setProfileName, error: error })] }), _jsxs("div", { className: "w-full flex-1", children: [_jsx("label", { className: "text-xs", children: "Query" }), _jsx(MatchersInput, { queryClient: queryClient, setMatchersString: setMatchersString, runQuery: setQueryExpression, currentQuery: query })] }), _jsxs("div", { children: [_jsx("label", { className: "text-xs", children: "Period" }), _jsx(DateTimeRangePicker, { onRangeSelection: setTimeRangeSelection, range: timeRangeSelection })] }), _jsxs(ButtonGroup, { children: [!searchDisabled && (_jsx(_Fragment, { children: !comparing && (_jsx(CompareButton, { disabled: compareDisabled, onClick: handleCompareClick })) })), _jsx(Button, { disabled: searchDisabled, onClick: (e) => {
123
+ e.preventDefault();
124
+ setQueryExpression();
125
+ }, children: "Search" })] })] }), _jsx("div", { children: comparing && _jsx(IconButton, { onClick: () => closeProfile(), icon: _jsx(CloseIcon, {}) }) })] }), _jsx("div", { className: "rounded bg-white shadow dark:border-gray-500 dark:bg-gray-700", children: _jsx("div", { style: { height: heightStyle }, children: querySelection.expression !== undefined &&
127
126
  querySelection.expression.length > 0 &&
128
127
  querySelection.from !== undefined &&
129
128
  querySelection.to !== undefined ? (_jsx("div", { className: "p-2", children: _jsx(ProfileMetricsGraph, { queryClient: queryClient, queryExpression: querySelection.expression, from: querySelection.from, to: querySelection.to, profile: profileSelection, comparing: comparing, setTimeRange: (range) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parca/profile",
3
- "version": "0.16.234",
3
+ "version": "0.16.235",
4
4
  "description": "Profile viewing libraries",
5
5
  "dependencies": {
6
6
  "@parca/client": "^0.16.86",
@@ -49,5 +49,5 @@
49
49
  "access": "public",
50
50
  "registry": "https://registry.npmjs.org/"
51
51
  },
52
- "gitHead": "80655241746e7c54d9028ac88ef262143ab0bf32"
52
+ "gitHead": "15a5c3df23475a1f08d93950631be60a72eea487"
53
53
  }
@@ -197,62 +197,58 @@ const ProfileSelector = ({
197
197
 
198
198
  const compareDisabled = selectedProfileName === '' || querySelection.expression === undefined;
199
199
 
200
- const Header = (): JSX.Element => (
201
- <div className="mb-2 flex">
202
- <div className="flex w-full flex-wrap content-start items-end justify-between gap-2">
203
- <div>
204
- <label className="text-xs">Profile type</label>
205
- <ProfileTypeSelector
206
- profileTypesData={profileTypesData}
207
- loading={profileTypesLoading}
208
- selectedKey={selectedProfileName}
209
- onSelection={setProfileName}
210
- error={error}
211
- />
212
- </div>
200
+ return (
201
+ <>
202
+ <div className="mb-2 flex">
203
+ <div className="flex w-full flex-wrap content-start items-end justify-between gap-2">
204
+ <div>
205
+ <label className="text-xs">Profile type</label>
206
+ <ProfileTypeSelector
207
+ profileTypesData={profileTypesData}
208
+ loading={profileTypesLoading}
209
+ selectedKey={selectedProfileName}
210
+ onSelection={setProfileName}
211
+ error={error}
212
+ />
213
+ </div>
213
214
 
214
- <div className="w-full flex-1">
215
- <label className="text-xs">Query</label>
216
- <MatchersInput
217
- queryClient={queryClient}
218
- setMatchersString={setMatchersString}
219
- runQuery={setQueryExpression}
220
- currentQuery={query}
221
- />
215
+ <div className="w-full flex-1">
216
+ <label className="text-xs">Query</label>
217
+ <MatchersInput
218
+ queryClient={queryClient}
219
+ setMatchersString={setMatchersString}
220
+ runQuery={setQueryExpression}
221
+ currentQuery={query}
222
+ />
223
+ </div>
224
+ <div>
225
+ <label className="text-xs">Period</label>
226
+ <DateTimeRangePicker
227
+ onRangeSelection={setTimeRangeSelection}
228
+ range={timeRangeSelection}
229
+ />
230
+ </div>
231
+ <ButtonGroup>
232
+ {!searchDisabled && (
233
+ <>
234
+ {!comparing && (
235
+ <CompareButton disabled={compareDisabled} onClick={handleCompareClick} />
236
+ )}
237
+ </>
238
+ )}
239
+ <Button
240
+ disabled={searchDisabled}
241
+ onClick={(e: React.MouseEvent<HTMLElement>) => {
242
+ e.preventDefault();
243
+ setQueryExpression();
244
+ }}
245
+ >
246
+ Search
247
+ </Button>
248
+ </ButtonGroup>
222
249
  </div>
223
- <div>
224
- <label className="text-xs">Period</label>
225
- <DateTimeRangePicker
226
- onRangeSelection={setTimeRangeSelection}
227
- range={timeRangeSelection}
228
- />
229
- </div>
230
- <ButtonGroup>
231
- {!searchDisabled && (
232
- <>
233
- {!comparing && (
234
- <CompareButton disabled={compareDisabled} onClick={handleCompareClick} />
235
- )}
236
- </>
237
- )}
238
- <Button
239
- disabled={searchDisabled}
240
- onClick={(e: React.MouseEvent<HTMLElement>) => {
241
- e.preventDefault();
242
- setQueryExpression();
243
- }}
244
- >
245
- Search
246
- </Button>
247
- </ButtonGroup>
250
+ <div>{comparing && <IconButton onClick={() => closeProfile()} icon={<CloseIcon />} />}</div>
248
251
  </div>
249
- <div>{comparing && <IconButton onClick={() => closeProfile()} icon={<CloseIcon />} />}</div>
250
- </div>
251
- );
252
-
253
- return (
254
- <>
255
- <Header />
256
252
  <div className="rounded bg-white shadow dark:border-gray-500 dark:bg-gray-700">
257
253
  <div style={{height: heightStyle}}>
258
254
  {querySelection.expression !== undefined &&