Inline is not removing br
Hainesy opened this issue · comments
Describe the bug
The inline property makes no difference as to whether a <br />
tag is being rendered.
To Reproduce
<SkeletonTheme baseColor={color} highlightColor={highlightColor}>
<Skeleton
inline
height={height}
width={width}
style={{ display: 'block', borderRadius, aspectRatio, lineHeight: 1 }}
/>
</SkeletonTheme>
Actual Behavior
A <br />
tag was rendered
Expected Behavior
No <br />
tag should be rendered
Versions
- react-loading-skeleton version: 3.3.1
- Browser version: N/A
Hi @Hainesy, looking at the code, it appears that <br />
is only rendered when inline
is false.
react-loading-skeleton/src/Skeleton.tsx
Lines 134 to 146 in c96a340
Maybe the issue is that you set display: block
in the style
prop.
If you still think there is a bug, please submit a runnable example that shows the problem. Thanks.