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

Tutorial button not properly navigating #328

Closed
sophieeng opened this issue Jul 16, 2022 · 2 comments
Closed

Tutorial button not properly navigating #328

sophieeng opened this issue Jul 16, 2022 · 2 comments
Assignees
Labels
bug Something isn't working mv3 An issue related to moving from Chrome manifest v2 to v3

Comments

@sophieeng
Copy link
Collaborator

sophieeng commented Jul 16, 2022

If you click the tutorial button in the popup, it should navigate you to the main settings page and then do the tutorial-modal. Currently, if you already have the settings page domainlist tab open for Chrome then it will not switch to the main settings page and show the modal.

This was found in going through the checklist in #289 for Chrome.

@sophieeng sophieeng self-assigned this Jul 16, 2022
@sophieeng sophieeng added bug Something isn't working mv3 An issue related to moving from Chrome manifest v2 to v3 labels Jul 16, 2022
@OliverWang13
Copy link
Collaborator

This is a tricky issue. It works a lot better when navigating from another site. In that case, it works by switching the setting TUTORIAL_SHOWN to false, and then running chrome.runtime.openOptionsPage(). When our options page opens, it defaults to settings_view.js, which then checks the TUTORIAL_SHOWN value and shows the tutorial if it is false.

Currently, when on the options page, it sends a message to settings-view.js called SHOW_TUTORIAL. I think that this perhaps interacts strangely with the chrome.runtime.openOptionsPage() or storage.set(stores.settings, false, "TUTORIAL_SHOWN" lines. Our darkmode toggle works nearly identically because it uses the same message passing system, but it does not share any of the same issues.

Maybe we would have more success sending a message to protection.js and having that communicate with settings-view.js. Maybe there is a way to force a reload of the page, making it more similar to when our options page isn't open. Maybe there is a way to create an on change listener that looks for when TUTORIAL_SHOWN is changed. Other ideas are also welcome.

@OliverWang13
Copy link
Collaborator

This is resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mv3 An issue related to moving from Chrome manifest v2 to v3
Projects
None yet
Development

No branches or pull requests

2 participants