Key Rotation
CSSA key icon rotates ninety degrees to fit a keyhole, expanding into a circular transition wipe.
- Tier
- CSS
- Dependencies
- None
- Duration
- 4 s, loops
- Categories
- Transitions and reveals
- Use cases
- Security and trust, Transitions and reveals
- Industries
- Construction and built environment, Cross-industry
- Style
- Duotone · light stroke
- Set
- handover
- Tags
- rotateringwipeloop
Companion assets
The same artwork, not animated. Derived from the entry’s own resting state, so it matches exactly.
Code
animation.svg
<svg xmlns="http://www.w3.org/2000/svg" fill="none" aria-hidden="true" class="pulsar pulsar-handover-key" data-pulsar="handover-key" viewBox="0 0 160 96"><circle cx="80" cy="48" r="32" stroke="currentColor" stroke-dasharray="3 3" stroke-width="1.5" class="keyhole-backdrop" opacity=".3"></circle><circle cx="80" cy="48" r="12" stroke="var(--pulsar-accent, currentColor)" stroke-width="2" class="ripple"></circle><g class="key-rotator"><circle cx="62" cy="48" r="9" fill="currentColor" fill-opacity=".1" stroke="currentColor" stroke-width="2" class="key-bow"></circle><circle cx="62" cy="48" r="3" fill="currentColor" class="key-hole"></circle><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M71 48h25m-6 0v6m5-6v5" class="key-blade"></path><circle cx="96" cy="48" r="2" fill="var(--pulsar-accent, currentColor)" class="key-tip"></circle></g></svg>
animation.css
.pulsar-handover-key {
display: block;
width: 100%;
height: 100%;
}
.pulsar-handover-key .key-rotator {
transform-origin: 80px 48px;
animation: handover-key-turn 4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}
.pulsar-handover-key .ripple {
transform-origin: 80px 48px;
animation: handover-key-pulse 4s ease-out infinite;
}
@keyframes handover-key-turn {
0%,
15% {
transform: rotate(0deg);
}
45%,
75% {
transform: rotate(90deg);
}
100% {
transform: rotate(0deg);
}
}
@keyframes handover-key-pulse {
0%,
35% {
r: 12px;
opacity: 0;
}
50% {
opacity: 0.8;
}
75%,
100% {
r: 36px;
opacity: 0;
}
}
@media (prefers-reduced-motion: reduce) {
.pulsar-handover-key .key-rotator,
.pulsar-handover-key .ripple {
animation: none;
transform: none;
opacity: 0.5;
}
}