lukehaas / css-loaders

A collection of loading spinners animated with CSS
MIT License
7.05k stars 1.04k forks source link

Transparent Background #19

Open benjaminprojas opened 9 years ago

benjaminprojas commented 9 years ago

When trying to use transparently, most of these loaders do not work well. Any chance they could be tweaked to work in a transparent environment?

lukehaas commented 9 years ago

Only two of the loaders require a solid background colour, loaders 2 and 3. There is really no way of avoiding this at the moment. Ideally loader 3 could be achieved using border gradients but unfortunately border gradients can't be combined with border-radius. Another alternative that would be nice to have is to use CSS masking to create an exclusion but that currently only works with images.

chrisnicola commented 8 years ago

You could try not setting the color in the box shadow property. It will default to the color of the element instead making it more flexible.