silverstripe / silverstripe-cms

Silverstripe CMS - this is a module for Silverstripe Framework rather than a standalone app. Use https://github.com/silverstripe/silverstripe-installer/ to set this up.
http://silverstripe.org/
BSD 3-Clause "New" or "Revised" License
516 stars 333 forks source link

Editor link modals erroring for internal and anchor link types #2890

Closed dizzystuff closed 1 year ago

dizzystuff commented 1 year ago

After the 5.0.6 release, trying to add an internal or anchor link type is throwing a js error Uncaught TypeError: this.getRequireLinkText is not a function.

The method looks like it was removed in #2884 but references to it remain/were added.

Doesn't seem to matter where the HTMLEditorField is, replicating is adding text, highlighting the text, selecting Page on this site or Anchor on a page from the link dropdown.

GuySartorelli commented 1 year ago

You need to update the silverstripe/admin module in your project as well, as that is where the entwine method is now defined.

dizzystuff commented 1 year ago

@GuySartorelli I'm using the recipe-cms ^5.0.0, rather than including these core packages on a per-package basis. So I would've expected both updates to come through via a composer update. I'll take a look later today at why then I'm not getting the latest silverstripe/admin module, but might be worth checking the recipe then too for some oddity.

GuySartorelli commented 1 year ago

Hmm. Can you please try a composer update -W?