-
Notifications
You must be signed in to change notification settings - Fork 334
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
Change the styling and behavior of hyperlinks #2872
Conversation
@martenbjork Actually, do we want to keep that hyperlink at all? It's redundant with the massive "rerun.io" that's already on the title bar. |
I'd be down to drop it! But the gigantic link present everywhere, even in the desktop app? If so, let's drop it! |
All right good call! And I'll work on improving the design of gigantilink. |
How do you feel about the "Help" behaviour. Currently it always open in new tab, which is inconsistent with the gigantilink, which needs a modifier and/or middle click for that. Because of the popup blocker thing, I'm leaning towards defaulting to same tab as well or "Help". |
We should definitely make them consistent.
I'd lean towards a new tab. Are you concerned about pop-up blockers? AFAIK, |
Yes. Open https://demo.rerun.io, delete a space view (eg), click on the gigantilink, back, space view is there again. (Though maybe not always? Depends on the browser caching implementation?)
I got that on safari! I had to click and allow.
Need to figure out how/if we can do that from rust/wasm. |
The HTML standard says _blank opens a "new window", maybe that's why. Most browsers today interpret this as "new tab", but I think it's up to the browser vendor.
Agreed! 🚀 |
This might explain safari's behaviour: https://stackoverflow.com/a/2587692/229511 Basically Safari isn't aware of user interactions inside the wasm executable. |
Ah, that makes perfect sense! |
Note that the previous behaviour of opening in new tab with modifier/middle-click was also popup-blocked! One more reason to default to new tab. |
Jikes, Safari is really nervous about those WASM links, eh? 😀 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code lgtm. didn't get to see the latest gigalink version on demo.io yet, but what could possibly go wrong
Indeed. Both Firefox and Chrome seem better behaved by default. Leniency or better ability to detect user interaction? Who knows... |
What
This PR changes the styling and behaviour of hyperlinks, of which there are currently
twothree:The link in the "About" panel. For this I just changed the style to use "normal" colour (ie. white), but keep the link behaviour (underline on hover).The link in the about panel is removed entirely as it is redundant with the top-bar gigantilink.Warning
The forced "new tab" triggered the popup blocker on my computer, so that maybe a motivation to stick with opening help in the same tab by default. Opinions?Opening in new tab used to—and will continue to—trigger popup blocker. This is due to the browser not being aware that some user interaction occurred within the wasm executable.Fixes #2733
Before:
After (mouse hovering on link, thus the underline):
Checklist