Skip to content

Commit

Permalink
fix(#28): open tab by one click
Browse files Browse the repository at this point in the history
  • Loading branch information
notmedia committed Dec 6, 2022
1 parent 554eca6 commit 7a1a37b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/pages/side-bar/nodes/method.node.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const GrpcMethodNode: React.FC<TreeNodeRendererProps<GrpcMethod>> = ({ da
const { createGrpcTab } = useTabsStore((store) => store);
const collections = useCollectionsStore((store) => store.collections);

const handleDoubleClick = () => {
const handleClick = () => {
const nodeCollection = collections.find((collection) =>
collection.children?.find((service) =>
service.methods?.find((method) => method.id === data.id)
Expand Down Expand Up @@ -54,7 +54,7 @@ export const GrpcMethodNode: React.FC<TreeNodeRendererProps<GrpcMethod>> = ({ da
key={data.id}
content={content}
css={{ paddingLeft: 20 }}
onDoubleClick={handleDoubleClick}
onClick={handleClick}
/>
);
};

0 comments on commit 7a1a37b

Please sign in to comment.