CSS Tip! 🤙
You can use mask-composite and some JavaScript to create this pointer proximity following glow border ✨
.glow {
mask-composite: intersect;
mask-clip: padding-box, border-box;
mask:
linear-gradient(#0000, #0000),
conic-gradient(#0000 0deg, #fff, #0000
Hey, do you like fancy glowing cards?
Let's get this tweet to 250 likes, and I'll create a tutorial for it.
This is 100% @figma. Xitter is really butchering the quality, check how smooth it is live: figma.com/proto/Aw5VqbnF…
Bringing the bear back to form controls with CSS :has() and CSS anchoring 👀
ʕ´•ᴥ•`ʔ
:root:has([type=password]:focus) .paw {
top: anchor(--password, top);
}
Only JavaScript is to toggle the password reveal whose button is anchored to the input 😉
@CodePen link below! 👇
JavaScript && CSS Tip! ✨
Use IntersectionObserver(IO) with a low threshold and custom properties to power list animations 🔥
el.style.setProperty('--shown', entry.isIntersecting ? 1 : 0)
li { scale: calc(0.25 + (var(--shown, 1) * 0.75));}
Demo link below! 👇
#Flutter animation tip🪄
Bring any boring scroll view in your UI to life (ListView, GridView, ..etc) by wrapping its children with an animated widget and let the itemBuilder do its magic 🪄🧪 (it will run your animation when each item scrolls into view 🤫)
Code 👇🏼
the little details™
Use trigonometric functions in CSS to create a smooth staggered transition delay 🎬
.character {
transition-delay:
calc(sin((var(--index) / 12) * 45deg) * 0.475s);
}
This? Completed it ✨
HTML, CSS, and JavaScript can take you to fun places 🚀
You might spot some added extras in this version!
┬┴┬┴┤•ᴥ•ʔ├┬┴┬┴
@CodePen link below 👇
CSS Tip! 🤙
Use custom properties to work out the nested radius of elements for you 😎
.parent {
--nested-radius: calc(var(--radius) - var(--padding));
}
.nested {
border-radius: var(--nested-radius);
}
Couldn't resist making an interactive visual!
@CodePen link below 👇