#dev 2026-01-29
2026-01-29 UTC
troojg, barnaby, grufwub, Saige_Leah, [Al_Abut], GWG, DanQ, blacklight, [Trevor_Morris], ax562, [jeremycherfas], oodani, sebbu, jonnybarnes, aks and [lazcorp] joined the channel
#
[lazcorp] I recently replaced the JavaScript enabled "Cite this post" button on my blog posts by using the "popover" global attribute and a bit of css styling & transformation. That let me delete around 30 lines of JS from my site (as well as the fallback HTML for people who didn't have JS enabled) and leave it all to native browser implementation.
#
[lazcorp] Browser support for the popover global attribute is pretty good: https://caniuse.com/?search=popover
thegreekgeek, barnaby, rMdes, gRegor and [Murray] joined the channel
ax562 joined the channel
#
[tantek]1 lazcorp, curious if you considered using textarea elements with minimal onclick handlers to select all the contents to make it easier to one-click then copy the text for a citation
#
[tantek]1 also the textarea gives a semantic of hey there's this is the text here you want to click and select
#
[tantek]1 am guessing there may be accessibility benefits too
#
[tantek]1 there may be experimental CSS UI properties to also select the entire contents of an input/textarea by default, I know I proposed some ages ago but I feel they might be implemented by now
#
[tantek]1 yes! "user-select: all" now works at least in Firefox!
#
[tantek]1 woohoo, I can rip out some JS!
#
[tantek]1 yep, fairly good cross-browser support: https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties/user-select#browser_compatibility
#
[tantek]1 I got the automatic "select all" inside the input working, mostly (and may have uncovered a browser bug, will find out later today). Either way, I just replaced 20 lines of JS with one CSS rule
barnaby joined the channel
#
[morgan] I was kind of interested in that mdn doc you just shared, it just seemed a little odd that is says "(its https://developer.mozilla.org/en-US/docs/Glossary/Chrome)" as a sort of explanatory note. I didnt quite get what it meant at first/not sure exactly what about chrome explains the former content, when its below the baseline multi browser logo for that feature. Im kinda curious enough to take a quick pass look and see if I can suggest a
#
[morgan] rewording
#
[morgan] cool css feature, not sure what I would use it for immediately, but its got some power to it.
#
[tantek]1 yeah the use-case is citation UI
CrimeWave, ax562, rMdes and DanQ joined the channel
