Skip to content

Feature/dynamic word swap toggle#1643

Merged
omroy07 merged 2 commits intoomroy07:mainfrom
Sunidhi037:feature/dynamic-word-swap-toggle
Feb 24, 2026
Merged

Feature/dynamic word swap toggle#1643
omroy07 merged 2 commits intoomroy07:mainfrom
Sunidhi037:feature/dynamic-word-swap-toggle

Conversation

@Sunidhi037
Copy link
Copy Markdown
Contributor

@Sunidhi037 Sunidhi037 commented Feb 24, 2026

Description:
This PR overhauls the fragmented theme toggle buttons across the AgriTech platform, specifically targeting the transition from static square icons to a unified 2026 premium component.

Key Enhancements:

Dynamic Content Logic: Added JavaScript to intelligently swap the button's text between "Light" and "Dark" based on the current active theme, providing clearer navigation cues to the user.

Premium Pill Aesthetic: Replaced the yellow square with a sophisticated pill-shaped container featuring a deep indigo gradient (#1e1b4b to #312e81) and a soft blue glow.

Tactile Interactions: Integrated cubic-bezier(0.175, 0.885, 0.32, 1.275) timing for a high-quality "pop-out" effect on hover.

Protected Scope Execution: Wrapped all logic in an IIFE to prevent the "Cannot redeclare block-scoped variable" errors observed in earlier development cycles.

BEFORE:
image

AFTER:

Screen.Recording.2026-02-24.120151.mp4

closes #1556

@vercel
Copy link
Copy Markdown

vercel bot commented Feb 24, 2026

@Sunidhi037 is attempting to deploy a commit to the Om Roy's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions
Copy link
Copy Markdown

Thanks for creating a PR for your Issue! ☺️

We'll review it as soon as possible.
In the meantime, please double-check the file changes and ensure that all commits are accurate.

If there are any unresolved review comments, feel free to resolve them. 🙌🏼

@Sunidhi037
Copy link
Copy Markdown
Contributor Author

@omroy07 please make sure to put the label of SWoC26 and difficulty label.

@omroy07 omroy07 merged commit e0b5b86 into omroy07:main Feb 24, 2026
2 of 5 checks passed
@github-actions
Copy link
Copy Markdown

🎉 Congrats @Sunidhi037 on getting your PR merged! 🙌
Thanks for the contribution — looking forward to more from you 🚀

SatyamPandey-07 added a commit to SatyamPandey-07/AgriTech that referenced this pull request Feb 25, 2026
SatyamPandey-07 added a commit to SatyamPandey-07/AgriTech that referenced this pull request Feb 25, 2026
omroy07 added a commit that referenced this pull request Feb 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[UI/UX]: Redesign and Unify Theme Toggle with Premium Animations

2 participants