payload icon indicating copy to clipboard operation
payload copied to clipboard

Link Editor In Richtext Fields Is Always Displayed Regardless Of Whether Custom Fields are Defined

Open zjohnson-messagedigital opened this issue 1 year ago • 3 comments

Describe the Bug

Image Issue looks to be caused by: https://github.com/payloadcms/payload/blob/9c6ab39bf489876e21e7c7d5dc714858d91ac335/packages/richtext-lexical/src/field/features/Link/plugins/floatingLinkEditor/utilities.ts#L50 This should be checking extraFields.length not fields.length

Link to the code that reproduces this issue

https://github.com/zjohnson-messagedigital/payload/tree/repro-fields-group-in-lexical-richtext

Reproduction Steps

  1. Configure payload to use default slateEditor in payload config
  2. Add rich text field to collection
  3. Create item in collection
  4. Add a link to the field Expected: Only default link fields should be visible Actual: Default fields plus empty group field named "Fields" is visible

Which area(s) are affected? (Select all that apply)

plugin: richtext-lexical

Environment Info

Using payload version v2.32.2

zjohnson-messagedigital avatar Mar 17 '25 16:03 zjohnson-messagedigital

Hi, this has been fixed as of Payload 3.28.1.

Payload v2 will only receive critical and security fixes

AlessioGr avatar Mar 17 '25 17:03 AlessioGr

Ugh, too bad my multi-tenant and sso customizations are preventing me from migrating ☹

zjohnson-messagedigital avatar Mar 17 '25 17:03 zjohnson-messagedigital

This issue has been automatically locked. Please open a new issue if this issue persists with any additional detail.

github-actions[bot] avatar Mar 25 '25 05:03 github-actions[bot]