that doesn't seem too hard,
@psychobunny can we add a filter.hook to augment the
if not, it's doable by injecting a script tag, in the footer for example, via a plugin, but that will happen after-the-fact, make the ajax for each user and inject the button after the ajax.success happens
.. that would also need to listen to for the infinite posts-load, which may also require a plugin.hook or, see if there any events that triggers on.post.load, along with adding it for NEW posts, I am sure there is a socket event that happens, just not sure which one yet.
The last and the most ugly thing I can think of, and don't try this at home, is to disable sanitizeHTML, and augment each post with a script tag, LOL -- , have it fetch the data, and maybe use localStorage is the user is the same, no seriously, dont do that.
I think I could help, how urgent is this?
I guess bottom line you have these options, I think:
- Editing the template: hacky, will break with a NodeBB upgrade
- inject a script in the footer, less hacky, probably your best option, it would still require some DOM selectors to be in there, but I think it's fair to assume so.