DUPLICATE PAGE
(see footnote)
Of course the 9 possibilities above aren't the only possible CSS spinners. You can find hundreds of other CSS-only spinners, from simple rotating squares to state of the art concentric moving figures with amazing colors. The 9 above are only some variations to show what kind of things is possible with the CSS code of the snake spinner of the previous page.
To make it quick & easy to adapt and combine, I've replaced the used 'color' and 'background-color' by CSS-variables.Also the eye color is put in a CSS-variable.
<div class="imgBox">
<div class="spinner"></div>
<img src="images/..." alt="...">
</div>
<script> /* none */ <script>
.spinner { /* variables */
--spinner-color: green;
--spinner-bg-color: #EFEFEF;
--spinner-eye-color: white;
--spinner-outer-ring:
0 0 0 5px var(--spinner-bg-color);
--spinner-outer-border:
0 0 0 6px var(--spinner-bg-color);
}
.imgBox { /* nothing changed */
}
.spinner { /* variables inserted */
/* styles from before */
background-image:
radial-gradient(circle at 37px 24px,
var(--spinner-eye-color) 1.5px, transparent 1.5px),
radial-gradient(circle at 43px 25px,
var(--spinner-eye-color) 1.5px, transparent 1.5px),
radial-gradient(circle at 25px 100px, transparent 24px,
var(--spinner-color) 25px);
border: solid var(--spinner-bg-color);
box-shadow:
var(--spinner-outer-ring),
var(--spinner-outer-border);
}
.spinner:before {
/* styles from before */
background: var(--spinner-bg-color);
}
.spinner:after {
/* styles from before */
background-image:
radial-gradient(circle at 19px 0,
transparent 6px,
var(--spinner-bg-color) 6px);
}
DUPLICATE PAGE