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

feat: update title of question page #3443

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

ADTmux
Copy link

@ADTmux ADTmux commented Apr 13, 2024

PR Checklist

PR Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Developer experience (improves developer workflows for contributing to the project)

Description

Clicking a question's title changes the name of the tab to reflect that question.

Git Issues

Closes #3409


@ADTmux ADTmux requested a review from a team as a code owner April 13, 2024 10:38
@ADTmux
Copy link
Author

ADTmux commented Apr 13, 2024

Please let me know if a different workaround was required, or a different approach was expected! I'd be happy to work on that as well!

Copy link
Member

@benfurber benfurber left a comment

Choose a reason for hiding this comment

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

Thanks for this @ADTmux. I think it's better to set it on QuestionPage though and I'd love to see it tested in the cypress test for questions/read.

@benfurber benfurber self-assigned this Apr 13, 2024
@benfurber benfurber added the 🤝 Awaiting author Waiting on action from the author label Apr 13, 2024
@ADTmux ADTmux changed the title Questions: Title of the tab changes on clicking question title Questions: title of the tab changes on clicking question title Apr 15, 2024
@ADTmux
Copy link
Author

ADTmux commented Apr 15, 2024

hey @benfurber , tested on Cypress and did the requested change. Please let me know what next is required! :)

@benfurber
Copy link
Member

@ADTmux Sorry to request another change on a tiny commit(!) but I think it should be set during the useeffect rather than the render. Let's go with just after setQuestion(foundQuestion)

The branch is also failing the linting right now. That's easiest to fix by running yarn format.

@ADTmux
Copy link
Author

ADTmux commented Apr 30, 2024

Hi @benfurber could you test it now?

@benfurber
Copy link
Member

Awesome. Thanks @ADTmux.

So I think that updating the commit messages to our style will fix the linter plus a rebase with master and we're good to go.

@benfurber benfurber changed the title Questions: title of the tab changes on clicking question title feat: update title of question page Apr 30, 2024
@ADTmux ADTmux force-pushed the issue#3409 branch 7 times, most recently from dfd337a to 67dc9a9 Compare May 2, 2024 01:36
@ADTmux
Copy link
Author

ADTmux commented May 2, 2024

@benfurber Done!

@benfurber
Copy link
Member

Hey @ADTmux. Thanks for making that change. Looks like you've pulled in some unrelated (and wrong) changes too? The stuff incrementViewCount on src/pages/Question/QuestionPage.tsx shouldn't be included. I think then the failing unit test will pass.

@benfurber
Copy link
Member

Just checking in @ADTmux. Have you seen my last comment? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤝 Awaiting author Waiting on action from the author
Projects
Status: No status
Status: 💬 Changes Requested
Development

Successfully merging this pull request may close these issues.

Questions: Page title should update with question title
2 participants