#dev 2022-02-14

2022-02-14 UTC
antrdnv[d], Seb[d], corenominal[d], P1000[d], hans63us[d], Seirdy and jacky joined the channel
#
jacky
do people translate content on their site?
[tw2113_Slack_] joined the channel
#
[tw2113_Slack_]
on my personal site? no
#
[tw2113_Slack_]
but even then, I *try* to make sure it's internationalization ready
#
jacky
ooh how so?
#
[tw2113_Slack_]
just to keep force of habit for client work
#
jacky
I've been wondering about doing that
#
jacky
that's a good forcing function
#
[tw2113_Slack_]
i work pretty exclusively with WordPress, so all their translation functions with string content
#
jacky
I got links to the template used to render parts of my site in the footer and I wanna see if I can point people to translate units as well
#
jacky
ahhh gotcha gotcha
#
[tw2113_Slack_]
even if just `esc_html_e()`
#
[tw2113_Slack_]
I am also pretty sure I'll be returning to some client work tomorrow around translating a website to multiple languages using WPML
#
jacky
TIL about WPML
#
[tw2113_Slack_]
every now and then I'm like "should I submit language files to WordPress core for 'pirate speak' or 'pig latin'?" but never do
#
jacky
I've been thinking about piping parts of it (my site's interface) into https://libretranslate.com/ to prime it then play with .pot files
#
[tw2113_Slack_]
I'm not multi-lingual outside those two, and even those would probably be translation services heavy
#
jacky
heh that'd be great
#
jacky
looks like https://projectfluent.org/ is a thing I could experiment with
#
jacky
I might try this out for my 100 days of indieweb
#
[tw2113_Slack_]
go for it
#
[tw2113_Slack_]
good/interesting twist on "100 days of code" and whatnot
#
jacky
yeah - I've been trying to compile a list of things I could try to work on - 5 - 10 days at a time (so I can "sprint" it) and then use that to make a blog series on it
#
aaronpk
If I can't write a post in another language myself then I feel there is little value in me using automated tools to translate my posts, since anyone reading my posts can use those same tools if they need to
#
[tw2113_Slack_]
it definitely feels like a case of if you have a a strong reason to present in multiple, then it's worth the effort but if not, then...yeah
#
jacky
true! I was thinking of using that in place of having someone go to google translate for privacy reasoins
#
jacky
*reasons
#
aaronpk
now, making it easy for automated tools to be able to translate my posts sounds great
#
aaronpk
google translate isn't the only game in town
P1000[d], [tw2113_Slack_], hans63us[d], corenominal[d], Seb[d], antrdnv[d], Ruxton, [jgmac1106], GWG, doosboox, sknebel, Zegnat and oodani joined the channel
#
jacky
ah that's true
[tw2113_Slack_] and [jgmac1106] joined the channel
#
jacky
I might see if I can start with translating the "UI" text of my site (that's easier) and then work up to translating posts
#
[tw2113_Slack_]
Trust no translation service that doesn't support JRR Tolkien languages or Game of Thrones languages
#
[tw2113_Slack_]
just saying
#
[tw2113_Slack_]
bonus points for Klingon
cygnoir[d] joined the channel
#
aaronpk
You know what has Klingon... Duolingo
#
jacky
It does! haha
#
GWG
How do you say Indieweb in Klingon?
#
[aciccarello]
I've thought about translating some of my posts about traveling to Spanish language countries as a language exercise.
#
[aciccarello]
Also, translating my homepage might make sense for people I've met who only speak Spanish
#
jacky
yeah I've begun thinking about this because I have family who don't speak English
#
jacky
but I wanna share stuff from my site with them
#
jacky
and I'm like I could just rewrite parts so it works lol
#
jacky
(they know Spanish and French but not English)
#
[aciccarello]
I noticed indiekit started using locallazy for app localization. It's cool because they suggest translations other projects handed used and have some suggested machine translation which really speeds up the process. https://localazy.com/p/indiekit
SERKHAN5 joined the channel; SERKHAN5 left the channel
#
jacky
oh I'll check that out
#
jacky
https://photoswipe.com/ might be interesting for photo galleries
KartikPrabhu1, petermolnar and [grantcodes] joined the channel
#
[grantcodes]
Photoswipe is great. I use it on my site
[James_Van_Dyne] joined the channel
#
[James_Van_Dyne]
capjamesg: Let me know when you make the indieweb-utils release. Gonna use it to fix my indieauth endpoints in Tanzawa.
sayanarijit[d] joined the channel
#
Murray[d]
Some good news for `rel='canonical'` and POSSE (for those that care about Lighthouse scores, at least): https://whitep4nth3r.com/blog/improved-google-lighthouse-seo-score
#
Murray[d]
(or, I guess more for PESOS really)
tetov-irc joined the channel
#
capjamesg[d]
[James_Van_Dyne] I still have to fix the test cases to not rely on network requests. If you could help with that, I'd appreciate it! I have it on my to-do list but haven't gotten around to it 😦
#
[James_Van_Dyne]
Ok. I'll give it a whirl in the morning.
BinarySavior joined the channel
#
@franckpaul
↩️ j'ai compris, http://webmention.io cherche uniquement des infos au format mf2 (microformat2), de type h_card et consort, et y'a pas ça chez moi.
(twitter.com/_/status/1493214366463897604)
#
@franckpaul
↩️ Mais pourquoi alors la norme webmention ne nécessite pas ça ? Il faut donc que le code sache s'en passer ;-)
(twitter.com/_/status/1493215567481905153)
#
@franckpaul
↩️ le seul truc c'est que les h* (mf2) ne sont pas spécialement répandus et en tout cas pas requis pour les webmentions ; c'est un peu du bricolage tout ça. par exemple j'ai pas mal de métadonnées dans le header pour twitter et consort, http://webmention.io pourrait s'en servir
(twitter.com/_/status/1493215104820723717)
#
@nhoizey
↩️ On va dire que c'est une surcouche de Webmention, pour en améliorer le rendu. Webmention s'occupe du dialogue, pas du contenu.
(twitter.com/_/status/1493217435461292032)
[pfefferle], Ramon[d], jacky and aaronpk joined the channel
#
jacky
finally did some 'magic' to have nginx serve my site's assets instead of letting my site's server do it
#
jacky
should add that to my docs
#
jacky
now to add some integrity stuff and I should be cruising
#
capjamesg[d]
What is the best way to make the headings on an article links?
#
Loqi
It looks like we don't have a page for "best way to make the headings on an article links" yet. Would you like to create it? (Or just say "best way to make the headings on an article links is ____", a sentence describing the term)
#
capjamesg[d]
I see some sites have a paperclip emoji that appears when you hover over a heading.
#
jacky
I've been wondering this too
#
jacky
if you don't mind javascript, https://github.com/tscanlin/tocbot is very light
#
jacky
I've been thinking about doing some post-processing on the HTML of my site to inject it but that feels like more work than I'd like
#
jacky
some markdown libraries tend to do this on the fly!
#
Murray[d]
If all you're after is linkable headings with a small icon of some kind to appear on hover then just wrap them in `<a>` tags and use `::after` in CSS to add an emoji or image file 🙂
#
Murray[d]
(after tends to be better than before to stop the heading jumping around, but there are ways of using negative margins on `:hover` too that can offset that)
#
Murray[d]
If you don't need them to link to themselves, just giving an `id` is enough for the `http://url.com#header` to work
#
jacky
that's actually what I do at https://jacky.wtf/work heh
#
jacky
just with a '#'
[tantek] joined the channel
#
lagash
jacky: setting up your own local LibreTranslate instance isn't too hard (unless you're say on FreeBSD)
#
jacky
heh I wanna try using a *BSD system one of these days
#
jacky
I def have the extra hardware
barnaby joined the channel
#
barnaby
I saw there was some new indieauth stuff! glancing over the spec, it looks like it’s mostly discovery stuff which I don’t need to worry about immediately implementing in my taproot/indieauth provider library, right?
#
barnaby
other than mentioning it in the documentation and examples, perhaps. I leave placement of discovery links up to the end user
#
jacky
IIRC not yet - there's still backcompat suggested so you're good
#
aaronpk
i'm working on a blog post to explain it all
#
aaronpk
but ideally your library would be able to create the new discovery document
#
barnaby
my library doesn’t know anything about the specific URLs involved, as it doesn’t do any routing itself and I wanted to minimise configuration
#
barnaby
but looking through the spec, it might make sense for the library to provide a template JSON object, which the consumer can add URLs to and then return
#
barnaby
blog post explanation sounds good!
#
GWG
barnaby: There are a few other minor things.
#
aaronpk
ah is it a library for building an authorization endpoint and token endpoint?
#
aaronpk
(rather than a library that *provides* those endpoints)
#
barnaby
yeah, it just handles the logic and token storage, and you call its methods in endpoints you define in whatever framework you’re using
#
aaronpk
got it, then yeah that makes sense
#
barnaby
people could build plugins for CMSes or frameworks which wrap it up and add routing, etc, but afaik nobody’s done that yet
#
aaronpk
some of the stuff in the metadata document would be stuff that the library is aware of, such as the PKCE challenge method, so it might make sense to do the JSON template thingy
#
barnaby
yep, that’s what I was thinking
#
barnaby
I’ll add a vague issue for the moment, and then I’ll return to it either when you finish the blog post, or when I sit down and read the new draft in detail
#
barnaby
hmm there are bunch of fairly easy to fix issues on taproot/indieauth, maybe I’ll sit down with it sometime soon
#
capjamesg[d]
But... I haven't got the paperclip thing working although I know how. I don't know if I want a paperclip emoji to show or just to make the links clickable like they are above.
#
capjamesg[d]
Also, how can I avoid screen readers from announcing every header as a link?
#
@jimniels
↩️ I really need to get webmentions and all that jazz setup, but even then you don’t get pinged if the other site doesn’t support the protocol. So this is my solution for keeping a pulse on inbound links ATM—however manual.
(twitter.com/_/status/1493298509675651082)
[schmarty] joined the channel
#
Murray[d]
capjamesg[d] you can't, really. You probably could with ARIA, but I wouldn't suggest it. They *are* links and should be announced that way imo
#
capjamesg[d]
I suppose so. Should I just leave the h2 as a link then?
jacky joined the channel
#
capjamesg[d]
Or use the paperclip and have it announce "Link to heading" or something like that?
#
Murray[d]
I'd personally just leave it as a link 🙂 not 100% sure on compatibility, but that pattern is used in a lot of places (like MDN) so it should be pretty universal (🤞)
#
jacky
capjamesg[d]: that might be fixable using aria things (possibly aria-hidden)
#
jacky
this stuff is tricky so if you find a resource that can help (I know Firefox's Inspector Tools has things for this in-built), please share!
#
jacky
makes a note to make sure his site is accessible
marksuth[d] joined the channel
#
capjamesg[d]
The links now work!
#
capjamesg[d]
In both dark mode and light mode.
#
capjamesg[d]
I'm not going to go with the emoji approach. No need to make things more complicated than they are.
#
capjamesg[d]
I'm excited about this!
#
jacky
oh what did you change? o.O
#
capjamesg[d]
I didn't make the ARIA change yet 🙂
#
capjamesg[d]
I will need to read more into that.
#
capjamesg[d]
I'll see what MDN does haha.
#
jacky
ahh okay
#
jacky
heh yeah good call
#
capjamesg[d]
MDN doesn't use any ARIA attribute.
#
jacky
interesting!
#
jacky
> If you can use a native HTML element [HTML51] or attribute with the semantics and behavior you require already built in, instead of re-purposing an element and adding an ARIA role, state or property to make it accessible, then do so.
#
jacky
the HTML probably leverages implicit accessibility features of the browser so you don't have to worry too much :)
#
capjamesg[d]
That's what I was thinking re: not using ARIA.
sp1ff`, KartikPrabhu and KartikPrabhu1 joined the channel
#
capjamesg[d]
How does a server listen on a port?
#
capjamesg[d]
I read this but it didn’t really answer the question: https://paulbutler.org/2022/what-does-it-mean-to-listen-on-a-port/
#
capjamesg[d]
How does a server accept a network request in the first place?
#
capjamesg[d]
How does a server know what to do with my GET /coffee/ or whatever request before it actually gets to my web server for processing?
#
[schmarty]
this sounds exactly like a julia evans topic.
jacky, KartikPrabhu, angelo and barnaby joined the channel
#
barnaby
that zine is such a good introductory resource [schmarty]++
#
Loqi
[schmarty] has 10 karma in this channel over the last year (23 in all channels)
#
barnaby
been meaning to learn more about low-level networking
sp1ff joined the channel
#
Murray[d]
capjamesg[d] @jacky: the golden rule of ARIA is "never use ARIA (unless you absolutely have to)". If you ever find yourself deliberately *breaking* a native HTML element, then that's probably not going to be well supported 😄 ARIA is more there for adding non-native functionality, or turning "simple" elements like `<div>` into something "complex", like a `<button>` (though rule #2 of ARIA may as well be "never turn a `<div>` into a `<butto
#
Murray[d]
capjamesg[d] I took a look at some of the standard places for best practices: a11ymatters, Scott O'Hara, the a11y project, Tink/Léonie Watson, Eric Bailey, Heydon Pickering, Gov.UK, Sara Soueidan, etc. What I'm seeing is that **none** of them have hyperlinked headings on their blog posts or writing. They all have `id` values; some have tables of contents that act as links; but none of them use that same pattern. I'm slightly surprised by t
jacky and tetov-irc joined the channel