Problem/Motivation

Currently it is not possible to configure where the collapsible dnd functionality is allowed.
Some routes I was able to identity where the collapsible dnd was present but could be enabled/disabled are:
* 'entity.entity_form_display.*'
* 'entity.entity_view_display.*'
* 'entity.menu.edit_form'
* 'entity.webform.edit_form'

Proposed resolution

I made a fork with a proposed solution of a config form where you can configure which of the above paths are allowed to have the collapsible dnd library included.
It works with wildcards so all entities are covered (nodes, paragraphs, media, ...).

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

wannesdr created an issue. See original summary.

wannesdr’s picture

Title: Add possibility to configure areas the collapsible functionality should get applied to » Add feature to configure the areas the collapsible functionality should apply to

reszli’s picture

This is really handy. (I wanted to disable it on webforms only)
One option missing is the taxonomy vocabulary forms.

adding the following to CollapsibleDndRoutes::$collapsibleDndRoutes solved it for me

    'entity.taxonomy_vocabulary.overview_form' => [
      'config_key' => 'taxonomy_vocabulary_form',
      'label' => 'taxonomy edit form',
    ],

I would also propose to enable options by default - disable on demand.
BTW, simple textarea where one can add any route would be more flexible then the hard-coded checkboxes.

nagy.balint’s picture

Version: 8.x-2.x-dev » 3.x-dev

  • nagy.balint committed 3da7c1db on 3.x
    feat: #3381906 Add feature to configure the areas the collapsible...
nagy.balint’s picture

Status: Active » Fixed

I implemented it slightly differently with a textarea as suggested in #4.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.