Skip to content

simplified animation - #33

Merged
skywalkerSam merged 4 commits into
mainfrom
about
Jul 20, 2025
Merged

simplified animation#33
skywalkerSam merged 4 commits into
mainfrom
about

Conversation

@skywalkerSam

@skywalkerSamskywalkerSam commented Jul 20, 2025

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • Style

    • Reduced the animation duration for the word slider effect on the About page for a snappier experience.
    • Added support to pause animations for users who prefer reduced motion.
  • Refactor

    • Disabled advanced GSAP-based text animations and removed an extra line break for a cleaner layout.
  • Content Update

    • Updated the cover image and source link for a post with a new NASA image.
    • Standardized closing phrases across multiple posts with consistent capitalization and spacing before emojis.

@vercel

vercelBot commented Jul 20, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

NameStatusPreviewCommentsUpdated (UTC)
skywalkersam-dev✅ Ready (Inspect)Visit Preview💬 Add feedbackJul 20, 2025 10:17am

@coderabbitai

coderabbitaiBot commented Jul 20, 2025

Copy link
Copy Markdown

Walkthrough

The animation duration for the .wrapper element in the CSS was shortened from 21 to 12 seconds. In the TypeScript component, all GSAP-related animation code was commented out, effectively disabling GSAP-driven animations. Additionally, a redundant line break in the JSX was removed. A new CSS media query was added to pause the .wrapper animation for users who prefer reduced motion. The cover image URL and its source link in a post metadata file were updated to a different NASA image.

Changes

File(s)Change Summary
src/app/about/_components/animated-intro.cssReduced .wrapper's wordSlider animation duration from 21s to 12s.
src/app/about/_components/animated-intro.tsxCommented out all GSAP imports and animation logic; removed a <br /> between <h1> tags.
src/styles/globals.cssAdded media query to pause .wrapper animation for users with reduced motion preference.
_data/posts/a-starboy.mdUpdated cover image URL, Open Graph image URL, and source link to a new NASA image resource.
_data/posts/a-night-to-remember.mdRemoved trailing whitespace and extra non-breaking space lines at file end.
_data/posts/february-the-9th.mdAdded closing line "Until Next Time... ✌️" at the end of the post.
_data/posts/strangers-passing-by.mdReformatted closing phrase capitalization and spacing before emoji; removed trailing blank lines.
_data/posts/the-journey.mdReformatted closing phrase capitalization and spacing before emoji.
_data/posts/the-very-essence-of-being-alive.mdChanged ellipsis to three periods and added space before emoji in closing line.
_data/posts/the-vibe.mdReformatted closing phrase capitalization and spacing before emoji.

Possibly related PRs

  • About #32: Introduced the initial AnimatedIntro component and related constants, which are directly modified in this PR.

Poem

A hop and a skip, the seconds now fly,
Twelve beats for the slider, as time passes by.
GSAP takes a nap, its magic on hold,
The intro stands simple, yet still bright and bold.
🐇✨


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4b1426b and 9f112c6.

📒 Files selected for processing (7)
  • _data/posts/a-night-to-remember.md (0 hunks)
  • _data/posts/a-starboy.md (2 hunks)
  • _data/posts/february-the-9th.md (1 hunks)
  • _data/posts/strangers-passing-by.md (1 hunks)
  • _data/posts/the-journey.md (1 hunks)
  • _data/posts/the-very-essence-of-being-alive.md (1 hunks)
  • _data/posts/the-vibe.md (1 hunks)
💤 Files with no reviewable changes (1)
  • _data/posts/a-night-to-remember.md
✅ Files skipped from review due to trivial changes (6)
  • _data/posts/the-journey.md
  • _data/posts/the-very-essence-of-being-alive.md
  • _data/posts/the-vibe.md
  • _data/posts/strangers-passing-by.md
  • _data/posts/february-the-9th.md
  • _data/posts/a-starboy.md

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@coderabbitaicoderabbitaiBot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
src/app/about/_components/animated-intro.tsx (1)

4-5: Consider removing commented imports entirely.

Since GSAP functionality has been disabled, consider removing these commented import statements completely to reduce code clutter, unless this change is intended to be temporary.

-// import { useGSAP } from "@gsap/react";-// import gsap from "gsap";
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9bc11e5 and d94c4fc.

📒 Files selected for processing (2)
  • src/app/about/_components/animated-intro.css (1 hunks)
  • src/app/about/_components/animated-intro.tsx (1 hunks)
🔇 Additional comments (1)
src/app/about/_components/animated-intro.css (1)

20-20: LGTM! Animation duration reduction improves user experience.

Reducing the animation duration from 21s to 12s makes the word slider animation more responsive while maintaining the same smooth transitions. This aligns well with the PR objective of simplifying the animation.

Comment on lines +8 to +23
// useGSAP(() => {
// // Respect user's motion preferences
// const prefersReducedMotion = window.matchMedia(
// "(prefers-reduced-motion: reduce)",
// ).matches;

if (prefersReducedMotion) {
gsap.set(".hero-text h1", { y: 0, opacity: 1 });
return;
}
gsap.fromTo(
".hero-text h1",
{ y: 30, opacity: 0 },
{ y: 0, opacity: 1, stagger: 0.2, duration: 1, ease: "power2.inOut" },
);
}, []);
// if (prefersReducedMotion) {
// gsap.set(".hero-text h1", { y: 0, opacity: 1 });
// return;
// }
// gsap.fromTo(
// ".hero-text h1",
// { y: 30, opacity: 0 },
// { y: 0, opacity: 1, stagger: 0.2, duration: 1, ease: "power2.inOut" },
// );
// }, []);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue

Important: Accessibility consideration lost with GSAP removal.

The commented GSAP code included important accessibility features that respected the user's prefers-reduced-motion setting. With GSAP disabled, this accessibility consideration is now lost, and the CSS animations will run regardless of user preferences.

Consider implementing a CSS-based solution to respect reduced motion preferences:

+ useEffect(() => {+ const prefersReducedMotion = window.matchMedia(+ "(prefers-reduced-motion: reduce)",+ ).matches;++ if (prefersReducedMotion) {+ const wrappers = document.querySelectorAll('.wrapper');+ wrappers.forEach(wrapper => {+ (wrapper as HTMLElement).style.animationPlayState = 'paused';+ });+ }+ }, []);

Alternatively, add CSS media query support in your CSS file:

@media (prefers-reduced-motion: reduce) {
.wrapper {
animation-play-state: paused;
}
}
🤖 Prompt for AI Agents
In src/app/about/_components/animated-intro.tsx around lines 8 to 23, the
previously used GSAP animation code that respected the user's
prefers-reduced-motion setting is commented out, causing loss of accessibility
support. To fix this, implement a CSS-based solution that respects reduced
motion preferences by adding a media query for prefers-reduced-motion in the
component's CSS file, which pauses or disables animations for users who prefer
reduced motion. This ensures animations do not run against user settings while
maintaining accessibility.

@skywalkerSam
skywalkerSam merged commit 28aea03 into mainJul 20, 2025
4 checks passed
@coderabbitaicoderabbitaiBot mentioned this pull request Jul 24, 2025
@coderabbitaicoderabbitaiBot mentioned this pull request Oct 17, 2025
@coderabbitaicoderabbitaiBot mentioned this pull request Aug 10, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@skywalkerSam