Adobe XD is often confused for a website or app authoring app - but it is meant for prototyping only.
Flash is replaced by HTML5 animations, which can be generated with SVG, CSS, Javascript or a combination of two or three.
Adobe rebranded Flash to Animate CC, and implemented a HTML5 animation output option. It is still Flash, though. Web animations are quite simple to do in Animate CC.
For Mac only Tumult Hype is also a good alternative:
https://tumult.com/hype/
Another good options is Saola Animate. Available for both Mac and Windows.
Create engaging HTML5 animations without coding skills
atomisystems.com
All of these sport animation timelines and keying of properties.
Another method is output to HTML5 Canvas. Godot is perhaps more complex (since it is a game authoring tool) but it also features a fully functional animation timeline, and allows for far more complex interactive behaviour - making it possible to create fully interactive 3d environments, if need be. For free (it is open source).
Unity is similar to Godot in that regard, and can also be used for output to HTML5 Canvas.
Godot provides a huge set of common tools, so you can just focus on making your game without reinventing the wheel.
godotengine.org
Create and grow real-time 3D games, apps, and experiences for entertainment, film, automotive, architecture, and more. Get started with Unity today.
unity.com
For 2d visual programming and animations with timelines, another alternative is Construct 3.
Construct 3 is the worlds best game making software. Make your own game in your browser without coding or with Javascript. Building games has never been easier!
www.construct.net
I mention Godot, Unity, and Construct here because Flash was (and still is) often used for online interactive game experiences as well.