Skip to content

Commit

Permalink
feat(connections): sticky table thead
Browse files Browse the repository at this point in the history
  • Loading branch information
kunish committed Sep 4, 2023
1 parent 3728cd2 commit 7f8f8a9
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/components/Collapse.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export const Collapse: ParentComponent<Props> = (props) => {
<div
class={twMerge(
getCollapseClassName(),
'collapse-arrow collapse mb-2 select-none overflow-visible border-secondary bg-base-200',
'collapse collapse-arrow mb-2 select-none border-secondary bg-base-200',
)}
>
<div
Expand Down
2 changes: 1 addition & 1 deletion src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export const Header = () => {
}

return (
<ul class="navbar rounded-box sticky inset-x-0 top-2 z-10 mx-2 mt-2 flex w-auto items-center justify-center bg-base-300 px-4">
<ul class="navbar rounded-box sticky inset-x-0 top-2 z-50 mx-2 mt-2 flex w-auto items-center justify-center bg-base-300 px-4">
<div class="navbar-start gap-4">
<div class={twMerge('drawer w-auto lg:hidden', '')}>
<input
Expand Down
10 changes: 5 additions & 5 deletions src/pages/Connections.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ export default () => {
})

return (
<div class="flex flex-col gap-4">
<div class="flex h-full flex-col gap-4 overflow-y-auto">
<div class="flex w-full items-center gap-2">
<input
class="input input-primary flex-1"
Expand Down Expand Up @@ -268,15 +268,15 @@ export default () => {
/>
</div>

<div class="overflow-x-auto whitespace-nowrap rounded-md">
<table class="table table-xs rounded-none bg-base-200">
<thead>
<div class="overflow-x-auto whitespace-nowrap rounded-md bg-base-300">
<table class="table table-xs relative rounded-none">
<thead class="sticky top-0 z-10">
<For each={table.getHeaderGroups()}>
{(headerGroup) => (
<tr>
<For each={headerGroup.headers}>
{(header) => (
<th class="bg-base-300">
<th class="bg-base-200">
<div
class={twMerge(
'flex items-center justify-between gap-2',
Expand Down

0 comments on commit 7f8f8a9

Please sign in to comment.