#dev 2025-09-01

2025-09-01 UTC
barnaby, barnabywalters, grufwub, lain`, failxontour, gRegorLove_, bterry1, gotra and rjomara5853 joined the channel
[snarfed], Loqi_, thegreekgeek_, [social] and [Murray] joined the channel
#
[Murray]
@failxontour: without knowing specifically what you're wanting to do, it's hard to say. There was a pattern for a while of rendering an `<a>` element, and then using JS (if it's available) to swap that out for a `<button>`. It's not something I've seen needed in a few years, though Popover is certainly something that might bring it back
#
[Murray]
That said, it really depends what you're trying to do if that makes sense. Can you achieve what you're after without using Popover? The `<dialog>` element has decent browser support these days, and can do a lot; there's also the `<details>` element for disclosure patterns (though how far you can push that is tenuous)
#
[Murray]
I definitely wouldn't suggest using Popover just yet, if broad support is required; its a few years away from even being "baseline" for public code imo
#
[Murray]
There are probably polyfills out there too, but without knowing what specific functionality you're using Popover to create, it's hard to recommend which one 😅
ttybitnik, [artlung], barnaby, ggarcia248, roxwize_, zoglesby_, chimo, bitauger_, angelo, cow_2001, chee, onla, barnabywalters, CrimeWave, vimlena and failxontour joined the channel
#
failxontour
@Murray sorry I missed your posts on halloy and had to check online. I could probably code an example that can use the dialog option I wanted a simple popver event without a closing dialog present so it nessecarily interupts the user session to take a minute to look at where their being taken I've seen similar security methods for 3rd party link handling used on steam and other services
#
failxontour
@Murray as for me I ususally check down below on the left while hoverwing within the browser where the link takes me but this is not nessecarily a thing for mobile users they would have to press and hold a link to know where it takes you. I find this bad counter-intuitive UX design as it stops the user from actually checking links to where they take them
#
failxontour
@Murray as I had problematic links that do not offer a ssl certificate I wanted to warn users about the implications of potential viewing an unsafe website
#
failxontour
maybe a bit of an XY problem
#
failxontour
then I stumbled over popover commandfor="" and wanted to play arround with a new implementation especially as it utilizies the semantic <button> element
#
failxontour
I was actually just looking to implement popper.js to the site when I noticed this
#
failxontour
my personal site is a link aggrergator and I found a couple of articles related to <button> element and honestly the whole point we still using <a> today is kinda ridicioulus because it always had been this way. Well why did we ditch <strong> for <b> formatting then and later switch over to CSS for styling. Rambling a bit but all this useless duplicate annotation for something that should be as easy as a ready to be place
#
failxontour
Seems a bit like obfuscation with the <a> element today. It's not something uncommon but all this effort to style something to act and look like an element that is already there for year seems like nonsense to me. An article I read on css-tricks sorta aggrevated me to try out buttons intead of the usual a element
#
[morganm]
Is it possible to extract files from the browser cache? Like to extract all the cached images on a certain site potentially within params?
#
[morganm]
I shared this article I made recently to a few people and got some interesting questions. https://www.morganwebdev.org/posts/har-bulk-image-export-with-dev-tools/
#
[morganm]
this method in the post relies on making a network tab recording and exporting a HAR file. but it doesnt seem to include cached files, a new refresh of the page is needed
#
failxontour
but with buttons I also did miss a bit of the previewing link option present which pointed me again into the direction of popovers.
barnaby joined the channel
#
[Murray]
@failxontour: not gonna lie, you've lost me a bit here 😄 I think you're wanting to warn people about potentially unsafe, offsite links? So when they press a link to an HTTP (or otherwise deemed "unsafe" site) they get a modal window pop up and say "Hey, here be dragons, continue at your own peril"?
#
[Murray]
If that is the case, then I'd probably suggest _not_ using a pop up/modal at all. There are a bunch of accessibility and UX concerns around having something styled like a link, that doesn't behave like a link; and I'd say that is doubly so if there are _other links_ on the site that behave "normally", making for an inconsistent experience
#
[Murray]
Instead, I'd say put a visible warning in front of any link deemed hazardous. A simple text warning, maybe with a little ⚠️ (warning) icon or emoji, some bold styles or colours, would be sufficient. If you want to provide further context, use a tooltip, i.e. a button placed alongside the link that opens up a `<dialog>` element with additional context, or expands some extra text
#
[Murray]
Something basic like "(Warning: Potentially Unsafe Link) `<a href="http://unsafe-link">`Fancy Website `</a>`" feels like it would get the point across as well as a sudden context switch and unexpected pop up
#
[Murray]
However, if you're set on the modal route, then I'd say a `<dialog>` is ideal. It has all of the benefits of Popover, but far fewer browser compat issues. Hit a button, get a modal window, select a "continue onwards" link, or close out. They're keyboard navigable, work on mobile, and well understood by most browsers and assistive tech
#
[Murray]
Oh, and if you activate a `<dialog>` as a modal window (via JS) it will even handle the focus trapping for you, which is otherwise a complete pain 😄
#
[Murray]
Still, I feel like a visible warning would be a better UX, clearer intent, and would help handle edge cases (thinking about people like me, who middle-click links typically to open them in new tabs in the background, which here likely wouldn't do anything and I wouldn't even notice)
#
[Murray]
(And as for places like Steam and Discord throwing up "warning" messages, whilst I understand that the language used is all about security, I have never seen any objective reasoning behind them outside of "if people leave the platform, how will we capture their money?", so call me skeptical on that pattern's _utility_ 😄)
barnaby joined the channel
#
[morganm]
https://groups.google.com/a/mozilla.org/g/dev-platform/c/JuDlPRWOFWY/m/5OjxV2Y-DgAJ?pli=1 < - View transitions are apparently being turned on in Firefox. I liked this posts succintness and a window into the process of shipping a feature like this
#
[Murray]
Yeah, pumped about that 😄
[social]1, [Murray]1, [artlung]1, thegreekgeek__, rosipov and barnabywalters joined the channel
#
[snarfed]
viewtransitions++ are awesome!
#
Loqi
viewtransitions has 1 karma over the last year