Skip to content

Commit

Permalink
fix(ui): Freightline items overflow with 2+ items (akuity#1348)
Browse files Browse the repository at this point in the history
Signed-off-by: Remington Breeze <remington@breeze.software>
  • Loading branch information
rbreeze authored Jan 2, 2024
1 parent 3509a29 commit c343c41
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions ui/src/features/freightline/freight-contents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const FreightContents = (props: {
} & React.PropsWithChildren
) => (
<Tooltip
className={`flex items-center my-1 flex-col bg-neutral-800 rounded p-1 ${
className={`flex items-center my-1 flex-col bg-neutral-800 rounded p-1 w-full ${
promoting && highlighted ? 'bg-transparent' : ''
}`}
overlay={props.overlay}
Expand All @@ -33,7 +33,7 @@ export const FreightContents = (props: {

return (
<div
className={`hover:text-white flex flex-col justify-center items-center font-mono text-xs flex-shrink min-w-min w-full ${
className={`hover:text-white flex flex-col justify-start items-center font-mono text-xs flex-shrink min-w-min w-full overflow-y-auto max-h-full ${
highlighted ? 'text-white' : 'text-gray-500'
}`}
>
Expand Down
4 changes: 3 additions & 1 deletion ui/src/features/freightline/freight-item.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ export const FreightItem = ({
onMouseEnter={() => onHover(true)}
onMouseLeave={() => onHover(false)}
>
<div className='flex w-full h-full mb-1 items-center justify-center'>{children}</div>
<div className='flex w-full h-full mb-1 items-center justify-center overflow-hidden'>
{children}
</div>
<div className='mt-auto w-full'>
<div
className={`w-full text-center font-mono text-xs truncate ${
Expand Down

0 comments on commit c343c41

Please sign in to comment.