Skip to content

Commit

Permalink
Tabs scrollbar (#258)
Browse files Browse the repository at this point in the history
  • Loading branch information
joncombe authored Dec 16, 2024
1 parent 680fa3a commit a5a54fb
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

- Improve spacing on schema tree buttons.
- Fix case-sensitive error where schema refresh doesn't always occur.
- Add scrollbar to SQL results tab bar when many resultsets are returned.

## 2024-12-06 - 0.19.4

Expand Down
20 changes: 11 additions & 9 deletions src/components/CrateTabsShad/CrateTabsShad.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,15 +48,17 @@ function CrateTabsShad({
value={activeTab}
onValueChange={onTabChange}
>
<TabsList
className={`min-h-10 ${hideWhenSingleTab && items.length === 1 ? 'hidden' : 'border-b'}`}
>
{items.map(item => (
<TabsTrigger key={item.key} value={item.key}>
{item.label}
</TabsTrigger>
))}
</TabsList>
<div className="overflow-x-auto">
<TabsList
className={`min-h-10 ${hideWhenSingleTab && items.length === 1 ? 'hidden' : 'border-b'}`}
>
{items.map(item => (
<TabsTrigger key={item.key} value={item.key}>
{item.label}
</TabsTrigger>
))}
</TabsList>
</div>
{items.map(item => (
<TabsContent
key={item.key}
Expand Down
2 changes: 1 addition & 1 deletion src/components/SQLResults/SQLResults.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function SQLResults({ results, format }: Params) {
})}
>
<div className="flex items-center justify-between gap-1.5 text-sm">
<span>Result {i}</span>
<span className="whitespace-nowrap">Result {i}</span>
{queryResult.status === 'EXECUTING' ? (
<Loader size={Loader.sizes.SMALL} />
) : queryResult.status === 'ERROR' ? (
Expand Down

0 comments on commit a5a54fb

Please sign in to comment.