#dev 2024-03-24
2024-03-24 UTC
BinarySavior, to2ds and [tantek] joined the channel
to2ds joined the channel
claudinec_away, mahboubine, to2ds, bterry, [aciccarello], wagle and [qubyte] joined the channel
# [qubyte] Today I decided to finally convert my internal representation of notes/likes/links/replies from a broken (because of my broken understanding at the time) mf2 implementation to a normalized jf2. It’s actually not been that hard. Only a few edge cases. I have a parsing layer which was responsible for turning mf2 JSON into JS objects, and it turns out that the JS objects are pretty much just jf2 anyway.
# mahboubine [qubyte]: what's jf2?
# Loqi jf2 is a W3C Note and a JSON Post Serialization Format of microformats2 for that is optimized for h-entry consuming code, as compared to the standard microformats JSON representation https://indieweb.org/JF2
# mahboubine capjamesg: cool, why would I use this instead of microformats?
box464 joined the channel
# mahboubine I guess the wiki already answers that
box464 joined the channel
# [KevinMarks] It is less flexible, but easier to read as JSON.
box464 and [Paul_Robert_Ll] joined the channel
# [Paul_Robert_Ll] [qubyte] Don’t know if you looked at https://github.com/getindiekit/mf2tojf2; hopefully covers a few more edge cases, and also provides a mechanism for referencing.
ttybitnik and mahboubine joined the channel
# [Paul_Robert_Ll] The mf2 → JF2 ← mf2 conversion is the bane of my ~life~ time developing Indiekit. And having to work with both means I’m often confused by the slight differences in the 2 specs.
macram_, geoffo, nertzy and [snarfed] joined the channel; macram_ left the channel
geoffo and [Joao_Paulo_Pes] joined the channel
# [tantek] [snarfed] a "formal/standard mf2 => jf2 conversion algorithm" would depend on an updated jf2 to reflect modern jf2-consuming implementations and process other issues as well: https://github.com/indieweb/jf2/issues
# [tantek] [snarfed] I suggest you file an issue requesting that the spec https://jf2.spec.indieweb.org/ document an explicit / precise "mf2 => jf2 conversion algorithm"
# [tantek] aaronpk, this use-case (primary object for a page) is a strong enough use-case that it really should be part of a more formally specified algorithm. can you file Feature Request issue on mf2 parsing spec to document an algorithm to determine the primary object (if there are more than one) of a page, either for mf2 parsers or consumers of mf2json?
# [tantek] and definitely cite your prior work https://github.com/aaronpk/XRay/blob/main/lib/XRay/Formats/Mf2.php#L36 and the test cases it's been built from
# [tantek] user docs don't say anything about import/export or APIs/protocols: https://support.apple.com/guide/iphone/get-started-with-journal-iph0e5ca7dd3/ios
AramZS joined the channel
# [tantek] hmm it looks like the only way to get things "out" is into iCloud: https://support.apple.com/guide/iphone/change-journal-settings-iphf965002cf/17.0/ios/17.0
nertzy and mahboubine joined the channel
# capjamesg Reference dictionary for autocomplete: https://gist.github.com/rxaviers/7360908
# capjamesg It turns out I wrote a blog post on it: https://jamesg.blog/2021/10/25/reacjis/
# [aciccarello] I wish the Mac emoji picker was easier to use. It never works how/when I expect it to.
# [aciccarello] I'd rather use the Unicode symbol than the microsyntax. But having suggestions when typing : is nice.
# [aciccarello] Slack and markdown are the two contexts I've seen it used.
# Loqi ok, I added "[[emoji]] text syntax of ":" (emoji-name) ":" like <code> `😄` </code> for 😄 and other standard Unicode emoji, as well as other custom names for custom emoji in software like [[Mastodon]], and services like [[Discord]] and [[Slack]]. Related: [[auto-emoji]]" to the "See Also" section of /microsyntax https://indieweb.org/wiki/index.php?diff=94349&oldid=86814
# [tantek] auto-emoji << IndieWeb Example:
{{capjamesg}}
has supported auto-emoji via emoji shortcodes [https://jamesg.blog/2021/10/25/reacjis/ since at least 2021-10-25], using his code https://github.com/capjamesg/cinnamon/blob/main/static/js/editor.js#L319 and reference shortcode dictionary https://gist.github.com/rxaviers/7360908# Loqi ok, I added "IndieWeb Example:
{{capjamesg}}
has supported auto-emoji via emoji shortcodes [https://jamesg.blog/2021/10/25/reacjis/ since at least 2021-10-25], using his code https://github.com/capjamesg/cinnamon/blob/main/static/js/editor.js#L319 and reference shortcode dictionary https://gist.github.com/rxaviers/7360908" to a brand new "See Also" section of /auto-emoji https://indieweb.org/wiki/index.php?diff=94350&oldid=94348 # [tantek] aciccarello, as in, some context support both Markdown and emoji shortcodes, e.g. GitHub and GitLab, however, seeing feature requests like this makes me think emoji shortcodes are not actually part of Markdown: https://github.com/executablebooks/MyST-Parser/issues/565
# [tantek] e.g. "emoji" is not mentioned in the latest CommonMark spec either: https://spec.commonmark.org/0.31.2/
# Loqi ok, I added "Services support: [[GitHub]], [[GitLab]]" to the "See Also" section of /auto-emoji https://indieweb.org/wiki/index.php?diff=94351&oldid=94350
# Loqi ok, I added "Hypothesis: the colon delimiting syntax came from auto-converting emoticons which often start with a ':' (like : ) or : D or : P ) into emoji." to the "See Also" section of /auto-emoji https://indieweb.org/wiki/index.php?diff=94352&oldid=94351
# [tantek] auto-emoji << emoji shortcodes are their own [[microsyntax]] (see https://emojipedia.org/shortcodes) and are not actually part of [[Markdown]] (no mention of emoji in https://spec.commonmark.org/). They happen to be supported in many text-entry boxes, some of which also support Markdown (e.g. [[GitHub]]), and thus are mistakenly thought of as part of Markdown, or even part of GitHub Flavored Markdown, despite that spec also having no mention
# [tantek] of emoji (https://github.github.com/gfm/)
# Loqi ok, I added "emoji shortcodes are their own [[microsyntax]] (see https://emojipedia.org/shortcodes) and are not actually part of [[Markdown]] (no mention of emoji in https://spec.commonmark.org/). They happen to be supported in many text-entry boxes, some of which also support Markdown (e.g. [[GitHub]]), and thus are mistakenly thought of as part of Markdown, or even part of GitHub Flavored Markdown, despite that spec also having no mention" to the "See Also" section of /auto-emoji https://indieweb.org/wiki/index.php?diff=94353&oldid=94352
# [tantek] Thanks capjamesg, as I have not used some of those services, please feel free to add the ones you have experience with (or can quickly test) to /auto-emoji