Skip to content
Open
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
5 changes: 5 additions & 0 deletions .changeset/better-mice-dress.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@genseki/react': patch
---

Fix pinning column size
2 changes: 1 addition & 1 deletion legacies/react/src/react/components/primitives/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export * from '../../../../v2/components/primitives/input-group'
export * from '../../../../v2/components/primitives/tanstack-table'
export * from './annotation'
export * from './avatar'
export * from './badge'
Expand Down Expand Up @@ -47,7 +48,6 @@ export * from './switch'
export * from './tab'
export * from './table'
export * from './tag-group'
export * from './tanstack-table'
export * from './text-area'
export * from './text-field'
export * from './time-field'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
import {
TanstackTable,
type TanstackTableProps,
} from '../../../../components/primitives/tanstack-table'
} from '../../../../../../v2/components/primitives/tanstack-table'
import { useTableStatesContext } from '../../../../providers/table'
import type { BaseData } from '../../types'
import { useCollectionList } from '../context'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,16 @@ import {
type Table as TanstackTableCore,
} from '@tanstack/react-table'

import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from './table'

import { Typography } from '../../../../v2'
import { cn } from '../../utils/cn'
import {
Table,
TableBody,
TableCell,
TableHead,
TableHeader,
TableRow,
} from '../../../src/react/components/primitives/table'
import { cn } from '../../../src/react/utils/cn'
import { Typography } from '../..'

type RowClickHandler<T> = (row: Row<T>, e: React.MouseEvent<HTMLTableCellElement>) => void

Expand Down Expand Up @@ -58,6 +64,7 @@ const getCommonPinningClassesAndStyle = (column: Column<any>) => {
const style: CSSProperties = {
left: isPinned === 'left' ? `${column.getStart('left')}px` : undefined,
right: isPinned === 'right' ? `${column.getAfter('right')}px` : undefined,
width: column.getSize(),
}

return { className, style }
Expand Down
Loading