Menu is not getting opened in latest version of editor core

Nothing is happened while clicking on + icon in latest version(137.0.0).

In old version if i am clicking on that icon then it displays menu like below.

@umang.savaliya @karanpalan

Because there’s nothing there. In the new version, there’s no Date or Divider in the “Basic” example anymore. It will work if you try another example like “Full page” :slightly_smiling_face:

And, yes it’s a bug. It shouldn’t show the + if there’s nothing to show.

Thanks @rifat for the update :grinning:

@rifat editor core latest version 137.0.0 is not compatible with react 17.0.1(latest) version . If we are using editor-core with react 17.0.1 then it is not displaying any menu like if we click on Normal Text then nothing is happened.

1 Like

Hi @rifat, we have the same error with the editor core with the last version of react. It doesn’t display any menu (except the menu of colors and alignment). Do you have planned to release a fix soon? Please keep in mind, that if you need more information you can contact us for it.

1 Like
const webpackAliases = {
  '../../../../ui/ToolbarButton': path.resolve(
    __dirname,
    'src/overrides/atlaskit/editor/toolbar-button.js'
  )
};
import AKToolbarButton from '@atlaskit/editor-core/dist/esm/ui/ToolbarButton';

export default function ToolbarButton(props) {
  const handleOnClick = e => {
    e.persist();
    setTimeout(() => {
      if (props.onClick) {
        props.onClick(e);
      }
    }, 0);
  };

  return <AKToolbarButton {...props} onClick={handleOnClick} />;
}

This is what I’ve done to solve this issue. I’m not 100% sure why the onClick event ends up triggering with-outer-listeners so quickly, but the solution is to delay the onClick event slightly.

Hello @jlaramie may I know how you made this code snippet to work? I can’t seem to make your code work. I am using Editor for comments functionality. Menu dropdown (heading) and link button and also the More formatting button all seem to not work. Im using editor-core version 147.0.1 and react version 17.0.1.

Appreciate your help guys! Thanks

Hello @david.gonzalez have they released a fix for this? we also have the same problem using latest version of editor-core and latest-version of react. Thank you

Hi, we currently are using the snippet code that @jlaramie said two comments before. And it is working for us perfectly but we don’t know any fix for this problem.

1 Like

Hello @david.gonzalez I finally got it to work. Thank you!

1 Like