javascript
you need
if (!document.startViewTransition) switchTheme()
document.startViewTransition(switchTheme);
following is a simple example, that uses a circular mask
lets add a little blur to the svg
let's try to pivot the center of the circle to top left
we've seen all the svg mask animations, but we can use clip-paths too
the issue with using clip path is that you can't do much with it, like adding gradient or blur. so svg should be a good choice for most cases
lets see how can we improve the clip-path animation with a custom svg with linear gradient
we can use local assets too
you can use gifs too
this one's good 😉
here are the two animation timing functions i'm using for the examples
btw we've updated our landing pic.twitter.com/rNNavmEu5Q
— Drizzle ORM (@DrizzleORM) August 5, 2024
Shigure Ui ftw https://t.co/wK9O86PVOy pic.twitter.com/FAVVKQxdmw
— SaltyAom (@saltyAom) June 24, 2024
OK, you can do some fun things quite simply now with View Transitions API.
— Lucie (@li_hbr) June 24, 2024
Thanks for showing me @rds_agi via @saltyAom ❤️ pic.twitter.com/dEBYHsmKra
🔦 flowplane now has a light mode
— shiv (@sxhivs) June 22, 2024
credits to @rds_agi for the css transition.@_nightsweekends @_buildspace pic.twitter.com/lUFgzJrEGD
leapflow now also has a light mode :)
— Suhas Sumukh (@suhasasumukh) June 22, 2024
cc: @rds_agi pic.twitter.com/lwZr5QkcIj
Ultimate Rick Roll with Framer 😏
— Ruddro (@ruddro29) June 27, 2024
page transition effect in .@framer pic.twitter.com/qAglIZ3uMg
给博客加上了主题切换效果, thank you @rds_agi pic.twitter.com/0lYlc0YQZ0
— Godruoyi (@godruoyi) June 25, 2024