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

CODE CHANGE:modified travelsafety.html file #1875

Open
4 tasks done
chandru110 opened this issue Nov 2, 2024 · 5 comments
Open
4 tasks done

CODE CHANGE:modified travelsafety.html file #1875

chandru110 opened this issue Nov 2, 2024 · 5 comments

Comments

@chandru110
Copy link

chandru110 commented Nov 2, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Describe the code change

Optimized Circle Generation with Loops: Instead of manually creating individual circle elements, a for loop was used to generate circles dynamically. This approach keeps the code short and easy to modify if the number of circles changes.

Event Handling Simplification: The mousemove event handler was used efficiently with a centralized coords object, updating circle positions in a single frame rather than recalculating them per circle, improving performance.

Better Color Management: Colors were managed through an array and applied in sequence across the circles, making it easy to modify or add new themes.

Responsive Navbar and Layout: Bootstrap’s responsive grid layout and navigation were improved to ensure the elements adapt smoothly on different screen sizes, making the design more mobile-friendly.

Code Organization for Readability: Code was reorganized to group similar sections together (HTML structure, styles, and scripts), making it easier to navigate and understand.

Accessibility Improvements: Added aria-label attributes for interactive elements to enhance usability for screen readers, creating a more inclusive design.

Commenting and Cleanup: Added comments to key parts of the JavaScript code to improve readability and understanding for future developers.

Proposed solution

Optimized Circle Generation with Loops: Instead of manually creating individual circle elements, a for loop was used to generate circles dynamically. This approach keeps the code short and easy to modify if the number of circles changes.

Event Handling Simplification: The mousemove event handler was used efficiently with a centralized coords object, updating circle positions in a single frame rather than recalculating them per circle, improving performance.

Better Color Management: Colors were managed through an array and applied in sequence across the circles, making it easy to modify or add new themes.

Responsive Navbar and Layout: Bootstrap’s responsive grid layout and navigation were improved to ensure the elements adapt smoothly on different screen sizes, making the design more mobile-friendly.

Code Organization for Readability: Code was reorganized to group similar sections together (HTML structure, styles, and scripts), making it easier to navigate and understand.

Accessibility Improvements: Added aria-label attributes for interactive elements to enhance usability for screen readers, creating a more inclusive design.

Commenting and Cleanup: Added comments to key parts of the JavaScript code to improve readability and understanding for future developers.

Record

  • I agree to follow this project's Code of Conduct
  • I'm a GSSOC'24 contributor
  • I want to work on this issue
Copy link
Contributor

github-actions bot commented Nov 2, 2024

Thank you for creating this issue! 🎉 Your issue will soon be reviewed by either the PA or a mentor. Please note that Level 1 is temporary and can be changed during the review. In the meantime, please make sure to provide all the necessary details and context. If you have any questions or additional information, feel free to add them here. Your contributions are highly appreciated! 😊

You can also check our CONTRIBUTING.md for guidelines on contributing to this project.

Copy link
Contributor

github-actions bot commented Nov 2, 2024

Thanks for creating the issue in BuddyTrail!
Before you start working on your PR, please make sure to:

  • ⭐ Star the repository if you haven't already.
  • Pull the latest changes to avoid any merge conflicts.
  • Attach before & after screenshots in your PR for clarity.
  • Include the issue number in your PR description for better tracking.
    Don't forget to follow @PriyaGhosal – Project Admin – for more updates!

We're excited to see your contribution as part of GSSOC Extended Edition 2024 and Hacktoberfest! 🎉
Happy open-source contributing!

@chandru110
Copy link
Author

chandru110 commented Nov 2, 2024

pull request done and enchanceed the code

Copy link
Contributor

github-actions bot commented Nov 2, 2024

Hello @chandru110! Your issue #1875 has been closed. Thank you for your contribution!

@chandru110 chandru110 reopened this Nov 2, 2024
@chandru110
Copy link
Author

So kindly review the PR and merge it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant