Skip to content

fix[dark-mode-toggle]: fix dark/light mode toggle on mobile#1332

Merged
benjagm merged 2 commits intojson-schema-org:mainfrom
Karan-Palan:fix/dark-mode-toggle-mobile
Mar 4, 2025
Merged

fix[dark-mode-toggle]: fix dark/light mode toggle on mobile#1332
benjagm merged 2 commits intojson-schema-org:mainfrom
Karan-Palan:fix/dark-mode-toggle-mobile

Conversation

@Karan-Palan
Copy link
Copy Markdown
Contributor

What kind of change does this PR introduce?

Bugfix: Ensures the dark/light mode toggle closes automatically when the user clicks outside the toggle or interacts with other elements on the mobile view.

Issue Number:

Screenshots/videos:

Screencast.from.2025-01-19.19-10-35.webm

If relevant, did you update the documentation?

No

Summary

#1281 - This PR resolves the issue where the dark/light mode toggle on the JSON Schema website did not close automatically when the user clicked outside it or interacted with other page elements in the mobile view.

Does this PR introduce a breaking change?

@Karan-Palan Karan-Palan requested a review from a team as a code owner January 19, 2025 13:42
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jan 19, 2025

built with Refined Cloudflare Pages Action

⚡ Cloudflare Pages Deployment

Name Status Preview Last Commit
website ✅ Ready (View Log) Visit Preview 661e73d

@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 19, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (69c8c3c) to head (661e73d).
Report is 30 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1332   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           10        10           
  Lines          373       382    +9     
  Branches        94        97    +3     
=========================================
+ Hits           373       382    +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

DhairyaMajmudar

This comment was marked as outdated.

@DhairyaMajmudar DhairyaMajmudar self-requested a review January 22, 2025 13:50
Copy link
Copy Markdown
Member

@DhairyaMajmudar DhairyaMajmudar left a comment

Choose a reason for hiding this comment

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

LGTM 👍🏻

@benjagm
Copy link
Copy Markdown
Collaborator

benjagm commented Feb 1, 2025

I am not able to reproduce the issue in production. Can you please check again if the issue is still relevant?

@Karan-Palan
Copy link
Copy Markdown
Contributor Author

Karan-Palan commented Feb 1, 2025

I am not able to reproduce the issue in production. Can you please check again if the issue is still relevant?

I checked it on my phone, still facing this issue

screen-20250201-212620.mp4

And this is after the change (tested on this PRs deployment)

screen-20250201-212952.mp4

Copy link
Copy Markdown
Collaborator

@benjagm benjagm left a comment

Choose a reason for hiding this comment

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

LGTM

@benjagm benjagm merged commit 24b8e46 into json-schema-org:main Mar 4, 2025
Sign up for free to 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.

🐛 Bug: Dark/Light Mode Toggle Doesn't Close Automatically on Mobile

3 participants