Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(css): update animation tips page #34827

Merged
merged 9 commits into from
Aug 8, 2024
Merged

Conversation

OnkarRuikar
Copy link
Contributor

There is no need to use tricks to achieve the discussed tips on the page. As we have to resort to JS then the Web animation API is the best way to achieve this. The new API also makes the examples simple.

The PR uses element.animate() and element.getAnimations() method in the examples.

@OnkarRuikar OnkarRuikar requested a review from a team as a code owner July 13, 2024 09:09
@OnkarRuikar OnkarRuikar requested review from dipikabh and removed request for a team July 13, 2024 09:09
@github-actions github-actions bot added Content:CSS Cascading Style Sheets docs size/m [PR only] 51-500 LoC changed labels Jul 13, 2024
Copy link
Contributor

github-actions bot commented Jul 13, 2024

Copy link
Member

@estelle estelle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the edits convert this CSS animation tips page to a web animations API guide. As this is a CSS tips and tricks page, not a web animations API page, I think we should keep keyframe animations in the page rather than create animations with JS. Alternatively, we can remove much of the content here and move it to the API section.

files/en-us/web/css/css_animations/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/css/css_animations/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/css/css_animations/tips/index.md Outdated Show resolved Hide resolved
@OnkarRuikar OnkarRuikar requested review from a team as code owners July 16, 2024 07:50
@OnkarRuikar OnkarRuikar requested review from sideshowbarker and removed request for a team July 16, 2024 07:50
@github-actions github-actions bot added the Content:WebAPI Web API docs label Jul 16, 2024
@OnkarRuikar
Copy link
Contributor Author

We don't have to resort to/suggest tricks if better ways are available. Unfortunately, the Web Animation API went completely separate ways and it doesn't gel with CSS animations. Web Animation API uses finish event rather than animationend :(

I've filed an issue to make the legacy CSS stylesheet-defined animations work with Web Animation API.

Alternatively, we can remove much of the content here and move it to the API section.

Moved the page to the Web Animation API content area.

@sideshowbarker sideshowbarker removed their request for review July 16, 2024 13:32
@bsmth bsmth removed the request for review from a team July 17, 2024 07:23
@github-actions github-actions bot added the merge conflicts 🚧 [PR only] label Aug 3, 2024
Copy link
Contributor

github-actions bot commented Aug 3, 2024

This pull request has merge conflicts that must be resolved before it can be merged.

Copy link
Member

@estelle estelle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies. I had reviewed this prior to going on vacation, but I forgot to submit the review.

files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/web_animations_api/tips/index.md Outdated Show resolved Hide resolved
files/en-us/web/css/css_animations/index.md Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Copy link
Member

@estelle estelle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! 🎉

@estelle estelle merged commit b9d7f68 into mdn:main Aug 8, 2024
9 checks passed
@@ -61,8 +61,8 @@ All animations, even those with 0 seconds duration, throw animation events.

- [Using CSS animations](/en-US/docs/Web/CSS/CSS_animations/Using_CSS_animations)
- : Step-by-step tutorial on how to create animations using CSS. This article describes the animation-related CSS properties and at-rule and how they interact with each other.
- [CSS animation tips and tricks](/en-US/docs/Web/CSS/CSS_animations/Tips)
- : Tips and tricks to help you get the most out of CSS animations.
- - [Using the Web Animations API](/en-US/docs/Web/API/Web_Animations_API/Using_the_Web_Animations_API)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo here; can either of you send a follow up?

@OnkarRuikar OnkarRuikar deleted the css_animation_tips branch August 9, 2024 00:22
@OnkarRuikar OnkarRuikar mentioned this pull request Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content:CSS Cascading Style Sheets docs Content:WebAPI Web API docs size/m [PR only] 51-500 LoC changed
Projects
None yet
3 participants