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

fix: make launchpad link open default browser #20399

Merged
merged 6 commits into from
Mar 1, 2022

Conversation

elevatebart
Copy link
Contributor

@elevatebart elevatebart commented Feb 28, 2022

User facing changelog

Instead of the link below (Learn more.) opening in a new electron window, it now opens in the default browser.

Screen Shot 2022-02-28 at 10 43 19 AM

  • Have tests been added/updated?

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Feb 28, 2022

Thanks for taking the time to open a PR!

@elevatebart elevatebart marked this pull request as ready for review February 28, 2022 17:00
@cypress
Copy link

cypress bot commented Feb 28, 2022



Test summary

17787 0 217 0Flakiness 4


Run details

Project cypress
Status Passed
Commit 15206c9
Started Mar 1, 2022 3:00 AM
Ended Mar 1, 2022 3:13 AM
Duration 12:38 💡
OS Linux Debian - 10.10
Browser Multiple

View run in Cypress Dashboard ➡️


Flakiness

commands/net_stubbing.cy.ts Flakiness
1 network stubbing > intercepting response > can throttle a proxy response using res.setThrottle
2 network stubbing > waiting and aliasing > can timeout incrementally waiting on requests
cypress/proxy-logging.cy.ts Flakiness
1 Proxy Logging > request logging > xhr log has response body/status code
2 Proxy Logging > request logging > xhr log has response body/status code

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@@ -97,7 +98,7 @@ const props = defineProps<{
description?: string
}>()

const openDocs = () => window.open('https://on.cypress.io/guides/configuration')
Copy link
Contributor

@tbiethman tbiethman Feb 28, 2022

Choose a reason for hiding this comment

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

I think we could just set the href prop on the Button and not have to worry about using the right mutation here:

href?: string // will cause the button to render as link element with button styles

Buttons with an href prop will use the external link mutation by default.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It will not be cool with router links...

Copy link
Contributor

Choose a reason for hiding this comment

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

That's what the internalLink/to props are for 😛 lots of props on Button apparently

Copy link
Contributor Author

Choose a reason for hiding this comment

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

... awwwww no! that's horrible.

I can do that... even if I am dying inside.

Copy link
Contributor

Choose a reason for hiding this comment

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

I hate that <Button> takes a href but this seems like the way to go. We could fix this eventually all in one shot. Do you plan to do this @elevatebart ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just did ;)

Copy link
Contributor

@lmiller1990 lmiller1990 left a comment

Choose a reason for hiding this comment

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

Same comment as Tyler! What do you think about that @elevatebart?

cy.findByRole('button', { name: 'Continue' }).click()
cy.intercept('POST', 'mutation-ExternalLink_OpenExternal').as('OpenExternal')
cy.findByText('Learn more.').click()
cy.wait('@OpenExternal')
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we assert the correct arg was included in the request?

Copy link
Contributor

Choose a reason for hiding this comment

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

Edit: probably irrelevant if you make the change mentioned by @tbiethman.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added in commit 15206c9

@@ -97,7 +98,7 @@ const props = defineProps<{
description?: string
}>()

const openDocs = () => window.open('https://on.cypress.io/guides/configuration')
Copy link
Contributor

Choose a reason for hiding this comment

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

I hate that <Button> takes a href but this seems like the way to go. We could fix this eventually all in one shot. Do you plan to do this @elevatebart ?

@elevatebart
Copy link
Contributor Author

@tbiethman @lmiller1990 Updated in the use of href in cad49a1

Copy link
Contributor Author

@elevatebart elevatebart left a comment

Choose a reason for hiding this comment

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

responded

@lmiller1990
Copy link
Contributor

Gonna merge since the request of Tyler is already done ✔️

@lmiller1990 lmiller1990 merged commit d1a082b into 10.0-release Mar 1, 2022
@lmiller1990 lmiller1990 deleted the elevatebart/fix/launchpad-links branch March 1, 2022 07:50
tgriesser added a commit that referenced this pull request Mar 2, 2022
* 10.0-release:
  fix: comment link to accurate docs (#20437)
  fix: scaffold commands file (#20398)
  fix(launchpad): support default export (#20383)
  feat(launchpad): support for Vue CLI 5 (#20413)
  fix: UNIFY-676 browsers should be configurable in setupNodeEvents (#20367)
  fix: make launchpad link open default browser (#20399)
  fix(icons): publish the files in the package
  fix: build icons in build-prod (#20411)
  test: migrate module-api to 10.0
  chore: build this branch
  test: migrate module_api to system tests (#20265)
  chore: remove pkg/driver //@ts-nocheck final (#20169)
  chore: fix "cannot find module" in clone-repo-and-checkout-release-branch (#20293)
  chore: Update Chrome (beta) to 99.0.4844.45 (#20234)
  chore: fix CI cache state for darwin (#20339)
  Add TODO comments
  feedback
  chore: move tests to its own file.
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.

3 participants