#microformats 2024-09-03

2024-09-03 UTC
fluffy, [snarfed], [snarfed]1, [sebbu] and barnaby joined the channel
#
[jacky]
When does one add the `lang` attribute to items? When it's detected in the parent document (and if so, does it cascade to every element until it specifies otherwise)? Looking at https://microformats.org/wiki/microformats2-parsing and I don't see a mention
#
Loqi
[preview] Tantek Γ‡elik
#
[tantek]
jacky, only explicitly on the element
#
[jacky]
then https://pin13.net/mf2/?url=https%3A%2F%2Fslatecave.net%2Fblog%2Ffixing-pwm-flicker%2F is wrong because it's not defined on the element, it's defined at `<html>`
#
[jacky]
<butterfly-meme-did-I-find-a-bug-in-pin13?.AVIF>
#
Loqi
[preview] [Slatian] Fixing PWM flicker on the Arduino UNO R3
#
[tantek]
jacky, ah, "lang" has not yet been adopted as an mf2 parsing feature, it's still undergoing experimentation
#
[jacky]
ah drat
#
[jacky]
I wanted a πŸ†
#
[jacky]
okay I can do that πŸ€”
#
[jacky]
that aside, this _kinda_ makes me want to expose what extensions are "enabled" in the output, similar to the `debug` block used by pin13
#
[tantek]
ooh that's a good idea
barnaby joined the channel
#
[jacky]
> or from the HTTP `Content-Language` header
#
[jacky]
Interesting add for the parser
#
[tantek]
another good reason why "directly on the element of the property" is probably what we're only going to add, because it's more predictable/simpler for authors and parser writers to work with dependably
#
[jacky]
I _do_ have a means of pulling from a network request in this library if needed but that'd require a little changing to support something like the header
#
[jacky]
that said, this should fix up that person's issue nicely
#
[jacky]
yeah this was a _great_ revisit; fixed up some more bugs with this
#
[jacky]
now I gotta update `http://rust.microformats.io` too πŸ¦”
#
[jacky]
tbh I'd move it to GitHub but the person who made the original crate isn't responsive (but I have push permissions to other ones)
to2ds joined the channel
#
[jacky]
regarding jf2, is there a place for tests that isn't https://github.com/dissolve/jf2_validator/tree/master/samples/jf2 but simiilar to https://github.com/microformats/tests (wanting to do tests against more HTML to confirm alignment)
SyniToxi and [schmarty] joined the channel
#
[tantek]
jacky, I'd start up level from the jf2 spec and see if you get different results
to2ds joined the channel
#
[tantek]
if not, then there may be an uplevel need to point the spec to a test suite repo that can be collectively maintained
#
[jacky]
like testing the examples in there? sure; I did convert some of those cases but couldn't hurt to do them all
#
[tantek]
no I mean what does the jf2 spec itself link to
[Bruno_Pulis] joined the channel
#
[jacky]
well the example files point to that repo by dissolve
#
[jacky]
https://jf2.rocks/ is the validator/implementation reports page
#
[jacky]
tangentially, if this was a thing https://github.com/indieweb/jf2/issues/50, this would make this implementation a lot easier because I could just convert it on the fly from mf2 to jf2
#
Loqi
[preview] [snarfed] #50 Mf2 conversion algorithm
#
[tantek]
well, getting back to community maintenance, jf2.rocks links to this repo for fixes: https://github.com/dissolve/jf2.rocks β€” so perhaps the next steps is to contact dissolve (maybe file an issue on the repo?) and ask if they'd consider migrating it to the microformats org
#
[tantek]
and then assuming that goes well, do the same with the test suite etc.
#
Loqi
[preview] [dissolve] jf2.rocks: code for jf2.rocks template
#
[jacky]
I do not see that links from jf2.rocks! I even looked at the source lol
#
[jacky]
but agreed!
#
[tantek]
it's at the bottom
#
[tantek]
" This site is open source and available on GitHub " where "GitHub" is a hyperlink to that repo
#
[jacky]
_oh_ I was looking at the spec page πŸ™ƒ
#
[jacky]
alright cool ty
gRegor, SyniToxi and barnaby joined the channel
#
gRegor
Re: lang, the inheritance was part of the brainstorming and (I think) implemented by the other parsers that tried out experimental language parsing: https://microformats.org/wiki/microformats2-parsing-brainstorming#Language_inheritance
#
gRegor
Additional details probably in github issues: https://github.com/microformats/php-mf2/issues/96
#
Loqi
[preview] [voxpelli] #96 Experimental language parsing
#
[tantek]
yeah lang "inheritance" is very hard to get right, and predict as an author. it's one of the "not great" mechanisms in HTML πŸ˜•
#
voxpelli
Hey Loqi :)
#
[tantek]
much simpler if we encourage authors to use the lang attribute explicitly on elements where they want it to explicitly show up in the parsed mf2 output
#
gRegor
Not great, but generally working on php-mf2 afaik :)
#
gRegor
I think it's been years since we've really discussed or iterated on that, so fresh eyes is good.
#
gRegor
It's still an experimental flag in php-mf2, we just enabled that flag at some point on the test parser sites
SyniToxi and to2ds joined the channel