Skip to content

Improved navigation, added home button #143

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

Merged
merged 3 commits into from
Jun 21, 2025

Conversation

vedansh-5
Copy link
Contributor

@vedansh-5 vedansh-5 commented Jun 20, 2025

📌 Fixes

Fixes #139


📝 Summary of Changes

Added home button to go back to report section, users can also click the scum helper heading to go back to the reports section.


📸 Screenshots / Demo (if UI-related)

image


✅ Checklist

  • I’ve tested my changes locally
  • I’ve added tests (if applicable)
  • I’ve updated documentation (if applicable)
  • My code follows the project’s code style guidelines

👀 Reviewer Notes

Add any special notes for the reviewer here

Summary by Sourcery

Restore navigation to the report section by adding a Home button and making the Scrum Helper heading clickable.

New Features:

  • Allow navigation back to the report section via a Home button or by clicking the Scrum Helper heading.

Bug Fixes:

Signed-off-by: Vedansh Saini <77830698+vedansh-5@users.noreply.github.com>
Copy link
Contributor

sourcery-ai bot commented Jun 20, 2025

Reviewer's Guide

This PR improves navigation by adding a home button and making the header clickable to return to the report view, refactors event handler setup in popup.js, updates the HTML structure to include the new button and heading ID, and extends CSS with styles for the home button in both light and dark modes.

Class diagram for updated popup UI elements and event handlers

Loading
classDiagram
    class PopupUI {
      +Element homeButton
      +Element scrumHelperHeading
      +showReportView()
    }
    PopupUI : +addEventListener(homeButton, 'click', showReportView)
    PopupUI : +addEventListener(scrumHelperHeading, 'click', showReportView)
    PopupUI : +showReportView()

File-Level Changes

Change Details Files
Enhanced navigation controls in popup.js
  • Declared homeButton and scrumHelperHeading elements alongside existing toggles
  • Removed duplicate settingsToggle/reportSection/settingsSection declarations
  • Added click handlers on homeButton and scrumHelperHeading to invoke showReportView()
src/scripts/popup.js
Updated popup.html to include home button and clickable header
  • Assigned id="scrumHelperHeading" and cursor-pointer class to the main heading
  • Inserted a homeButton before settingsToggle with FontAwesome icon
  • Wrapped buttons in a flex container for layout alignment
src/popup.html
Added CSS rules for homeButton styling
  • Defined base styles (background, border, cursor, flex alignment)
  • Added active state background for light and dark modes
src/index.css

Assessment against linked issues

Issue Objective Addressed Explanation
#139 Provide a way to navigate back to the main screen from the settings screen.
#139 Make the navigation intuitive for users.

Possibly linked issues


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@vedansh-5 vedansh-5 self-assigned this Jun 20, 2025
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request improves navigation by adding a home button and making the "Scrum Helper" heading clickable to return to the reports section.

  • Added new UI elements (home button and clickable heading) to trigger navigation back to the reports view.
  • Removed duplicate variable declarations in popup.js to streamline the code.
  • Updated CSS to include styles for the new home button.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/scripts/popup.js Added event listeners and refactored duplicate declarations for navigation.
src/popup.html Updated markup to include the clickable scrum helper heading and home button.
src/index.css Added styling for the new home button to support UI consistency.

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey @vedansh-5 - I've reviewed your changes - here's some feedback:

  • Consider moving the inline font-size style on the home button into your CSS files to keep styling consistent and maintainable.
  • Add an accessible label or aria-label to the home button icon so screen readers can identify its purpose.
  • You might consolidate the click handlers for homeButton and scrumHelperHeading into a single function or event delegation pattern to reduce duplication.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Consider moving the inline font-size style on the home button into your CSS files to keep styling consistent and maintainable.
- Add an accessible label or aria-label to the home button icon so screen readers can identify its purpose.
- You might consolidate the click handlers for `homeButton` and `scrumHelperHeading` into a single function or event delegation pattern to reduce duplication.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@vedansh-5
Copy link
Contributor Author

@hpdang @mariobehling Please take a look whenever you can, I'm open for any and all suggestions. Thank you.

@hpdang
Copy link
Member

hpdang commented Jun 21, 2025

The implementation works well for me, I really like it. My only comment is that the two icons feel relative big compared to the overall UI.

@vedansh-5
Copy link
Contributor Author

image
I have reduced the icon size.

Signed-off-by: Vedansh Saini <77830698+vedansh-5@users.noreply.github.com>
@vedansh-5
Copy link
Contributor Author

vedansh-5 commented Jun 21, 2025

I have resolved the conflicts, the extension works fine with all the functionalities intact. Thank you!
@hpdang

@hpdang hpdang merged commit 6f7b349 into fossasia:master Jun 21, 2025
@vedansh-5 vedansh-5 deleted the settingEnhanc branch June 23, 2025 11:55
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.

Improve Navigation: Add Option to Return to Main Screen from Settings
3 participants