react-pdf icon indicating copy to clipboard operation
react-pdf copied to clipboard

Docs: lineHeight can't accept length or percentage

Open crowbait opened this issue 1 year ago • 0 comments

In this issue it has been noted that lineHeight is limited to the unitless number value type (thus lineHeight = x * fontSize).

While this is not wrong behaviour, the usual CSS line height property also allows for other value types, eg. length.

This key difference should be noted in the docs.

Also, it may be prudent to change the type of lineHeight to number, as strings (commonly used in JSX styling for CSS values containing units) could lead to false confidence in the acceptable values of lineHeight.

crowbait avatar Aug 25 '24 21:08 crowbait