Skip to content

Commit

Permalink
Make the box-sizing explicit on the MoonLoader circle
Browse files Browse the repository at this point in the history
Recent versions of Tailwind CSS force everything to `box-sizing: border-box;`
(see tailwindlabs/tailwindcss#1111 )
Tailwind isn't the only thing out there using that hack, so this is sure to be a wider-ranging problem.
The result of using Tailwind & react-spinners in the same project without this change is that the spinner circle wobbles around.
  • Loading branch information
maco authored Feb 14, 2020
1 parent 0131314 commit 21a4bea
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/MoonLoader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ class Loader extends React.PureComponent<LoaderSizeProps> {
${this.ballStyle(value)};
border: ${this.moonSize()}px solid ${color};
opacity: 0.1;
box-sizing: content-box;
`;
};

Expand Down

0 comments on commit 21a4bea

Please sign in to comment.