Discourse Retort

I’ve just updated this to account for the es6 changes outlined here:

4 Likes

Is it normal that after activating the retort plugin the retort-emojis are preselected in the posts emoji-popup?

1 Like

Nah, that’s a bug. Feel free to file an issue at http://github.com/gdpelican/retort/issues and I’ll take care of it soon.

4 Likes

three simple things:

  1. the pop up
  2. a user can add as much as emoji as he wants, and it’s not limited to an emoji per user.
  3. I can put emoji even on my own post.

??

This is available by setting ‘retort allow multiple reactions’ to false.

That’s the intended behaviour. Why do you think you shouldn’t be able to?

1 Like

thanks, I missed that setting.

by pop up , i mean when i click on the emoji sets, a pop up raises. does it need to be like this?

about the self-emoji, i just thought emoji can be something like a “like” button, but with more functionality. and since it’s not usual to like your own post, i didn’t expect to be able to put emojis on my own posts.

plus the fact that I can put emojis on my own post using the text editor itself.

Is anyone here on tests passed (v1.7.0.beta3 +56) and is crashing with Retort enabled?

I’m getting Uncaught TypeError: Cannot read property 'exists' of undefined, such that none of the posts in a thread are showing.

The error for this is:

which is located in /emoji/emoji-groups/ of the plugin.

I also receive another error,

So it looks like somehow Discourse.xyz is undefined, and somehow my version of Retort is messing with it.

Anyone have any ideas?

Appears to be related to removing a bunch of Discourse constants for es6 compatibility, referenced here.

Also, neither of those bits of code appear to be in the master branch of the plugin, and retort appears to work fine on the latest Discourse (I just upgraded discourse-babble.com, which is also running retort, to latest), so I’m not sure how to help here.

That first line in particular looks mighty suspicious; Discourse master branch has this:

import { emojiExists } from 'pretty-text/emoji';

// scrub groups
groups.forEach(group => {
  group.icons = group.icons.reject(obj => !emojiExists(obj));
});
2 Likes

Hi @gdpelican.

Thanks for getting back to this so soon.

I should have clarified we forked Retort and have been modifying it. Going to take a look at your revisions (commit: update Discourse for es6 modules) on the master branch and make adjustments accordingly to our version to see if remedies the errors.

1 Like

Also, might be a good idea to see if you need a fork anymore. I think you forked it so you could limit which emojis can be used in retort, that is now built in, but I might be thinking of someone else…

3 Likes

Hi @cpradio.

I’m actually just about to test to what the original Retort looks like on our dev site . You are right though, we forked so we could limit the number of emojis to try and be more Facebook-esque.

3 Likes

Thanks for the heads up about Retort now incorporating the ability to select which emojis to display! It has the added benefit of proper architecture, and none of my spaghetti code.

7 Likes

Can this plugin be configured to only affect a particular category?
Ideally, being able to switch it on/off per each category individually in its settings dialog.

2 Likes

Not currently, but it’s possible to dev this out. I’ve raised an issue on the retort repo to track the request for this functionality.
https://github.com/gdpelican/retort/issues/22

2 Likes

Hello, first of all thank you for this great idea and plugin.

I’m getting this error on my dev instance with versionv1.7.0.beta5 +98.

Uncaught TypeError: Cannot read property 'icons' of undefined

No emojis to choose from are shown - only faded screen and no popup.

My plugin settings:

Looking at the code seems like your plugin added one more emoji group and it was messed somehow that the pointer for groups is now -1…

Wouldn’t it be worth to not allow negative index @zogstrip ? Similar issue was fixed here: Clicking Emoji button results in faded screen and no selector pop-up

1 Like

I think you wanted to mention @gdpelican who is the author of that plugin rather than me :wink:

1 Like

Sorry if you think this is inappropriate. I was referring to you just because there was similar problem in the past and I think that in this case it would be worthwhile to assure and sanity check page value in the core Discourse function (Independently of other plugins that may arrive in future). And you was doing that change previously…

I can’t get this plugin to work, @gdpelican - It installs fine on the latest Discourse, but clicking the smiley just dims the background (scrolling is still possible) and nothing shows up. It also seems to be pulling something from discourse-meta-s3 amazon?! I just checked with Firebug and it looks like it throws an error: TypeError: r.register is undefined

1 Like

There’s been a recent change to the emoji selector, give me a few and I’ll
fix it.

5 Likes

Okay, I fixed the thing in the latest. :sunny:

4 Likes