#microformats 2018-01-14

2018-01-14 UTC
[miklb], tantek, [kevinmarks], [joe]1, [chrisaldrich], [eddie], nitot, barpthewire, [colinwalker], ivc, randomstranger, gayboi, chrisaldrich, nitot_, [jeremycherfas], aaronpk_, aaronpk and chimo joined the channel
#
aaronpk
is the new implied name parsing rule going to fix this situation? https://david.shanske.com/2018/01/14/1774/
#
Loqi
[David Shanske] Skip to content David Shanske The Definitive Location Menu ...
#
Loqi
[David Shanske] Skip to content David Shanske The Definitive Location Menu ...
#
Zegnat
It should, in that the h-entry should not get a name at all
#
KartikPrabhu
eh! if h-entry gets no name at all then what does "implied name" even mean?
#
Zegnat
There is an h-entry with e-content, the fact e-content is explicit will be taken as a sign that the fact name is missing is also explicit.
#
Zegnat
So the parser should not add a name.
#
KartikPrabhu
so this will break consumers who use a comparison between name and content-value to figure out if it is a note?
#
Zegnat
Oh, hmm, wait, I read the issue wrong.
#
Zegnat
e-content will not make it skip name implication, but p-author should. Only other p- properties would suppress it, according to the issue.
#
Loqi
[David Shanske] Skip to content David Shanske The Definitive Location Menu ...
#
Loqi
[tantek] #6 reduce instances when p-name is implied
[kevinmarks] joined the channel
#
KartikPrabhu
so other p-* properties are skipped in name implication or is name implication itself skipped if there are other p-*
#
KartikPrabhu
that seems to have been undecided
#
KartikPrabhu
the latter will break note post-type discovery
#
sknebel
only if your notes rely on implied names
#
Zegnat
name implication is skipped when other explicit p- properties are defined (i.e. it is assumed p-name is explicitly left out thus should not be auto-filled)
#
Zegnat
at least that is how I understood the issue
#
KartikPrabhu
sknebel: that is what post-type-discovery says afaik
#
sknebel
if you know a site where that's the case, that'd be good to know
#
Zegnat
Also, “no "name" property” is a check in Post Type Discovery (https://www.w3.org/TR/post-type-discovery/) so consumers should correctly identify it as a note without needing to compare any name to content
#
Loqi
[Tantek Çelik] Post Type Discovery
#
aaronpk
The only reason we need that heuristic in the first place is because name appears in notes due to implied name
#
aaronpk
it would be so much better if it just didn't appear in the first place
#
KartikPrabhu
Zegnat: aah nice catch. I had missed that caveat
#
aaronpk
Actually the only reason we started doing class="e-content p-name" is because leaving off the name class results in an ugly implied name
#
KartikPrabhu
aaronpk: yes fair enough
#
Zegnat
I wonder if https://github.com/microformats/microformats2-parsing/issues/6 should extend to “any explicit properties” rather than “any explicit p-* properties”.
#
Loqi
[tantek] #6 reduce instances when p-name is implied
#
[kevinmarks]
also because other note systems did that too (eg twitter feeds when they had them)
#
aaronpk
That was only because Atom requires the name due to its blogging roots
#
Zegnat
E.g. I can totally have a post with e-content, dt-published, and u-author. But then it would still go and imply a name because I have no explicit p- property.
#
Zegnat
adds that to the issue
#
KartikPrabhu
Zegnat: so you are proposing that if there is no property found then imply the name?
#
KartikPrabhu
is there a use-case where such an implied name is useful?
#
Zegnat
<a href="example.com" class="h-card">name</a>
#
aaronpk
Implied name (and photo and url) are useful for the minimal h-cards and things
#
KartikPrabhu
hmmm yeah
#
Zegnat
Cool, I was able to just use the HTML from my blog. The only p- property in my HTML is the p-name. https://github.com/microformats/microformats2-parsing/issues/6#issuecomment-357550670
#
Loqi
[Zegnat] Just a thought I just had in chat when I realised `e-content` wasn’t going to stop a `name` property to be implied per @tantek’s proposed new limitation: > "p-name MUST NOT be implied if there are any explicit p-* properties or any nested micr...
#
Zegnat
wouldn’t mind severely cutting down on all implied properties
#
gRegorLove
Definitely in favor of blocking implied p-name if other p-* exist; it's on my mental roadmap for the near future in php-mf2.
#
aaronpk
Good cause I don't even know where to start with that change :-p
[miklb] joined the channel
#
KartikPrabhu
Zegnat's new rule is easier to implement
#
aaronpk
I know surprisingly little about how the parser actually works
#
Zegnat
I realised the same limitation aaronpk. I actually sat down and started writing down the algo for VCP because I couldn’t keep it straight any more: https://wiki.zegnat.net/media/mf2dom.html
#
gRegorLove
php-mf2 keeps objects of properties it's parsed by prefix, so checking if other p- have been parsed is easy.
#
Zegnat
gRegorLove do you see any reason why we should limit it to p-?
#
gRegorLove
Longer-term, I don't know. Short-term, it seems like a smaller change that is less likely to cause unexpected results.
#
gRegorLove
I won't be implementing it too soon, so if the discussion goes that way (broadening it) I'm fine with that.
#
gRegorLove
I haven't looked over the earlier conversation on the mf wiki either
#
Zegnat
Note that tantek’s proposed limitation also adds nested h- as a thing that should stop implying a name. So not just p-
#
Zegnat
If the idea is to put a stop to parser output like that of GWG’s post, seeing any property is probably a sign of markup being nested within the h- and thus a valid reason to not imply name.
#
Zegnat
But I am off to bed. Will think about it some more. Have a good one all!
#
[kevinmarks]
hm. There was some value in assuming that a name would always be available, but implying unhelpful ones is less good (like the "a jpg" alt text)
#
[kevinmarks]
implied names having load of newlines in has always been annoying
#
gRegorLove
Definitely add examples to https://github.com/microformats/microformats2-parsing/issues/6 where stopping based on *any* other property would be helpful for implied name.
#
Loqi
[tantek] #6 reduce instances when p-name is implied
#
Zegnat
Just added Tantek’s home page HTML as another h-entry example that has no explicit p- properties (except for the currently necessary p-name)