@shindakun I’ve done some CSS and other tweaks and have it looking more to my liking. I'd like to get rid of the Like and Share buttons totally, but when I removed them from the HTML everything broke. 😒 meanwhile I'm hiding the text. I also rearranged a couple of items. So pleasing. Thank you again.
@Miraz Yeah I've been thinking about getting rid of the buttons myself. If you remove the label section near the top of the "render" functions that should allow you to remove the HTML for the buttons. For example:
var label = reposts.length + (reposts.length === 1 ? ' share' : ' shares');
document.getElementById('share-count').innerHTML = label;
@manton Do you know whether or not it's the case that even if one were to keep the native M.b webmention code intact, incoming webmentions will only use that third-party function, and therefore once you turn on displaying native webmentions, all mentions in the meantime won't have gotten picked up by M.b?
@Miraz Ack! Looks like I left out
<ul class="shares" id="shares"></ul> in the HTML on the post. I also noticed I didn't mention that you need to supply an image for shares. The code looks for
/images/anon-avatar.png by default.
@matpacker There is something odd about the post that webmention.io recieved, looking at the JSON returned to the page its coming in as:
"sentence_html": "<a href=\"[www.mathewpacker.com/2019/12/2...](https://www.mathewpacker.com/2019/12/2523/)\">someone</a> posted '' linking to <a href=\"[miraz.me/2019/12/2...](https://miraz.me/2019/12/21/thanks-to-shindakun.html)\">[miraz.me/2019/12/2...](https://miraz.me/2019/12/21/thanks-to-shindakun.html)</a>"
So, it knows you send something just doesn't appear to have written the text.
Thanks for testing that, I had completely forgotten about it.
@matpacker Hmm doesn't look like it's updated in the data sent back to the page (at least not yet). I haven't used that plugin, so I don't know to much about how its sending to webmention.io that mention definietly is much ligher on details then the ones from micro.blog. I wonder if that's why the original implmentation I based my post on only shows a name and profile icon for "shares". Though the other examples of them I found do appear to have comment text. Maybe the issue is specific to the plugin, can't install it on the free wordpress.com account. :(
@Miraz it looks like you should be alright once you add the "shares" <ul> .
It got left out of the HTML in my original post by mistake, it should have included three elements:
<ul class="replies" id="replies"></ul>
<ul class="likes" id="likes"></ul>
<ul class="shares" id="shares"></ul>
I imagine a variant could be written that finds the permalink URL for every post on a page and then goes and asks webmention.io for a count, for each post, and displays that with the post on the homepage, but it’s probably that much more complex….
div placeholder, and then you’d have counts with each post on the homepage. So maybe 80% of the JS is the same?
@matpacker @shindakun I just noticed that Miraz’s post is reporting “4 shares” (and wondered what they were…), which coincidentally corresponds to 4 “speaking head” icons from mathewpacker.com, so webmention.io is seeing them as shares and not replies, I guess…if that helps any in debugging….
We'll create and host a microblog for you.
✔ Use your own domain name
✔ Short or long posts
✔ Photo hosting
✔ Cross-posting to Twitter and more
✔ Custom themes
✔ Publish from the web or native apps
All the features of a hosted microblog, plus...
✔ Podcast hosting
✔ Short videos
✔ Companion iPhone app Wavelength for recording and editing
✔ Podcast feed
Great for businesses or families.
✔ Add people to your blog
✔ Your whole team can write or edit blog posts