Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions packages/app/src/SessionSubpanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,12 @@ export default function SessionSubpanel({
const [rowId, setRowId] = useState<string | undefined>(undefined);
const [aliasWith, setAliasWith] = useState<WithClause[]>([]);

useEffect(() => {
return () => {
setDrawerOpen(false);
};
}, [setDrawerOpen]);

const [tsQuery, setTsQuery] = useQueryState(
'ts',
parseAsInteger.withOptions({ history: 'replace' }),
Expand Down Expand Up @@ -467,6 +473,8 @@ export default function SessionSubpanel({
source={traceSource}
rowId={rowId}
aliasWith={aliasWith}
isNestedPanel={true}
withOverlay={true}
onClose={() => {
setDrawerOpen(false);
setRowId(undefined);
Expand Down
4 changes: 3 additions & 1 deletion packages/app/src/components/DBRowSidePanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ type DBRowSidePanelProps = {
aliasWith?: WithClause[];
onClose: () => void;
isNestedPanel?: boolean;
withOverlay?: boolean;
breadcrumbPath?: BreadcrumbPath;
onBreadcrumbClick?: BreadcrumbNavigationCallback;
};
Expand Down Expand Up @@ -527,6 +528,7 @@ export default function DBRowSidePanelErrorBoundary({
aliasWith,
source,
isNestedPanel,
withOverlay,
breadcrumbPath = [],
onBreadcrumbClick,
}: DBRowSidePanelProps) {
Expand Down Expand Up @@ -566,7 +568,7 @@ export default function DBRowSidePanelErrorBoundary({
<Drawer
opened={rowId != null}
withCloseButton={false}
withOverlay={!isNestedPanel}
withOverlay={withOverlay ?? !isNestedPanel}
onClose={() => {
if (!subDrawerOpen) {
_onClose();
Expand Down
Loading