Problem/Motivation

The module does not support custom widgets for paragraphs bundles selection from a field and displays all target bundles instead.

Steps to reproduce

- Install Paragraphs Browser
- Install Paragraphs Selection module
- Create new 3 paragraph types
- Create a node bundle with a paragraph field which references 2 paragraph types out of 3 available using Paragraphs Selection module
- Configure Paragraphs Browser as usual
- Go to create a new node - the paragraph browser will display all 3 paragraph types instead of 2 types which were configured on the 4th step

Proposed resolution

Use ParagraphSelection::getSortedAllowedTypes() method of paragraph selection handler instead of checking only for standard $handler_settings['target_bundles'] values.

Comments

Spleshka created an issue. See original summary.

spleshka’s picture

Attaching a patch with proposed solution.

beloglazov91’s picture

The patch does the same but compatible with 8.x-1.1 version.

elaman’s picture

Status: Needs review » Reviewed & tested by the community

#3 is working.