(BUG) Auto Show Formatting Options when commenting does not worked
Hi
I tried the new new Reddit UI and toggle the Auto Show Formatting Options when commenting. But, the thing is it does not automatically load unless I toggle it manually. What do you think?
I'm not sure, it's still working for me. When you click "Reply" on a comment, does it not enable the formatting options for that either?
it is quite erratic. sometimes it does not appear and I have to click the T button or the comment button again to make it appear
@joelacus after extension update to version 1.12 it looks like I need to refresh the webpage again to make sure the toolbar appear again. What do you think? 2024-10-21 09-24-21.flv.zip
I think I kinda figured out what the problem was:
- ASFOWC only executes when
comment-body-headeris attached to the page; this element only shows up on full post pagesroutename='post_page'and not on comment thread pagesroutename='comment_page'; -
waitForAddedNodeonly runs once and does not execute again, which means hidden comments (x more replies) and new batch of comments (as user scrolls down to the end of the current batch) won't have the listener attached; - the listener can be attached multiple times, which repeatedly opens and closes the formatting toolbar.
I've rewritten this feature and placed an MutationObserver that would look for new comments and attach the listener instead. So far things are looking more promising, but I won't bet on it working perfectly all the time.