design-system icon indicating copy to clipboard operation
design-system copied to clipboard

[bug]: Checkbox missing padding in RTL

Open zaaakher opened this issue 9 months ago • 0 comments

What version of strapi-design-system are you using?

[email protected]

[email protected]

@strapi/[email protected]

What's Wrong?

Upon creating this PR in Strapi admin. I realized the checkbox doesn't have a space between the box and the label when the language is RTL.

When LTR

image

When RTL

image

Upon further investigation it seems to be coming from here

To Reproduce

1- Create a <div>

2- Set the property dir to `RTL

3- Place a <Checkbox/> component inside that RTL div.

4- See the lack of space between the label and the box, switch back and forth between rtl and ltr to see the difference.

Expected Behaviour

It should use paddingStart instead of paddingLeft so that it's consistent regardless of direction. I was gonna make a PR for it but handleResponsiveValues.ts looked too complex for me to get through it in the short time I have. So I kindly leave it to you. I appreciate your efforts :)

zaaakher avatar May 07 '24 14:05 zaaakher