Skip to content

Commit e9650e8

Browse files
Fix hydration errors across a variety of pages (#1556)
Small PR to resolve all the hydration errors on a few pages
1 parent 8213d69 commit e9650e8

File tree

5 files changed

+14
-9
lines changed

5 files changed

+14
-9
lines changed

.changeset/blue-drinks-dress.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@hyperdx/app": patch
3+
---
4+
5+
Fix hydration errors across a variety of pages

packages/app/src/HDXMultiSeriesTableChart.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,8 +293,8 @@ export const Table = ({
293293
</tr>
294294
)}
295295
</tbody>
296-
{tableBottom && tableBottom}
297296
</table>
297+
{tableBottom}
298298
</div>
299299
);
300300
};

packages/app/src/SessionsPage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ function SessionCardList({
220220
const defaultTimeRange = parseTimeQuery('Past 1h', false) as [Date, Date];
221221
const appliedConfigMap = {
222222
sessionSource: parseAsString,
223-
where: parseAsString,
223+
where: parseAsString.withDefault(''),
224224
whereLanguage: parseAsStringEnum<'sql' | 'lucene'>(['sql', 'lucene']),
225225
};
226226
export default function SessionsPage() {

packages/app/src/TeamPage.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { useCallback, useState } from 'react';
1+
import { Fragment, useCallback, useState } from 'react';
22
import Head from 'next/head';
33
import { CopyToClipboard } from 'react-copy-to-clipboard';
44
import { SubmitHandler, useForm, useWatch } from 'react-hook-form';
@@ -162,11 +162,11 @@ function SourcesSection() {
162162
<Card variant="muted">
163163
<Stack>
164164
{sources?.map(s => (
165-
<>
166-
<Flex key={s.id} justify="space-between" align="center">
165+
<Fragment key={s.id}>
166+
<Flex justify="space-between" align="center">
167167
<div>
168168
<Text>{s.name}</Text>
169-
<Text size="xxs" c="dimmed" mt="xs">
169+
<Text size="xxs" c="dimmed" mt="xs" component="div">
170170
<Group gap="xs">
171171
{capitalizeFirstLetter(s.kind)}
172172
<Group gap={2}>
@@ -216,7 +216,7 @@ function SourcesSection() {
216216
/>
217217
)}
218218
<Divider />
219-
</>
219+
</Fragment>
220220
))}
221221
{!IS_LOCAL_MODE && isCreatingSource && (
222222
<TableSourceForm

packages/app/src/components/DBSearchPageFilters.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1229,7 +1229,7 @@ const DBSearchPageFiltersComponent = ({
12291229
withArrow
12301230
label="Denoise results will visually remove events matching common event patterns from the results table."
12311231
>
1232-
<Text size="xs" mt="-2px">
1232+
<Text size="xs" mt="-2px" component="div">
12331233
<Group gap={2}>
12341234
<IconShadow
12351235
size={14}
@@ -1258,7 +1258,7 @@ const DBSearchPageFiltersComponent = ({
12581258
withArrow
12591259
label="Only show root spans (spans with no parent span)."
12601260
>
1261-
<Text size="xs" mt="-2px">
1261+
<Text size="xs" mt="-2px" component="div">
12621262
<Group gap={2}>
12631263
<IconSitemap
12641264
size={14}

0 commit comments

Comments
 (0)