Edited /components/Badge.tsx to be a block element
If the text for tags/cameras on the grid page overflowed to a second line then the background did not grow with the text. Making the element a block and slightly increasing the padding keeps the text/background similar to the original style while also allowing the background to match the text if it is multiple lines.
This commit is contained in:
parent
1b45eb41ae
commit
b704a701c6
@ -28,7 +28,9 @@ export default function Badge({
|
||||
case 'small':
|
||||
return clsx(
|
||||
'h-max-baseline',
|
||||
'px-[5px] py-[2.75px]',
|
||||
// 'px-[5px] py-[2.75px]', //original padding
|
||||
'block', // added to keep gray background around text when overflowed
|
||||
'px-[6px] py-[5px]', // increased padding for block and to stop content shift
|
||||
'text-[0.7rem] font-medium rounded-[0.25rem]',
|
||||
highContrast
|
||||
? 'text-invert bg-invert'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user