Skip to content

Commit

Permalink
[TM-1561] fix error width cell table in poligon review
Browse files Browse the repository at this point in the history
  • Loading branch information
dottyy committed Dec 19, 2024
1 parent 29e71a0 commit b3a4700
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions src/components/elements/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -186,17 +186,18 @@ function Table<TData extends RowData>({
}
>
<div
className="inline w-full max-w-full"
style={{
fontSize: "inherit",
fontWeight: "inherit",
color: "currentColor",
fontFamily: "inherit"
}}
>
<span
className="font-inherit relative"
<div
className="font-inherit relative w-full max-w-full"
style={{
marginRight: `${iconRefs.current[header.index]?.getBoundingClientRect().width}px`
paddingRight: `${iconRefs.current[header.index]?.getBoundingClientRect().width}px`
}}
>
<span
Expand Down Expand Up @@ -238,7 +239,7 @@ function Table<TData extends RowData>({
/>
</span>
</When>
</span>
</div>
</div>
</th>
);
Expand Down
4 changes: 2 additions & 2 deletions src/components/elements/Table/TableVariants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,9 @@ export const VARIANT_TABLE_SITE_POLYGON_REVIEW = {
table: "border-collapse",
name: "border-airtable",
tableWrapper: "border border-neutral-200 rounded-lg overflow-hidden",
trHeader: "bg-neutral-150",
trHeader: "bg-neutral-150 sticky top-0 z-auto",
thHeader:
"first:pl-4 first:pr-2 last:pl-2 last:pr-4 border-y border-neutral-200 text-14-semibold whitespace-normal px-2 border-t-0",
"first:pl-4 first:pr-2 last:pl-2 last:pr-4 border-y border-neutral-200 text-14-semibold whitespace-normal px-2 border-t-0 sticky top-0 z-auto",
tBody: "",
trBody: "bg-white border-y border-neutral-200 last:border-b-0",
tdBody: "text-14-light px-2 py-3 first:pl-4 first:pr-2 last:pl-2 last:pr-4 ",
Expand Down

0 comments on commit b3a4700

Please sign in to comment.