Problem/Motivation
Should be done after #3529103: Remove Island's specific Form classes
The islands are not configurable in /admin/structure/display-builder/{id}
Proposed resolution
Do we need to implement Drupal\Core\Plugin\PluginFormInterface on islands plugins?
Let's start using this interface by adding those configs:
- components providers in component library (by default, disable
display_builder). Today, it is hardcoded in::getDefinitionsForProvider() - block providers in block library (by default,disable
ui_patterns_layouts) - display "Clear" button in history buttons (must be hidden by default)
- buttons with labels, icons, or both.
Issue fork display_builder-3529067
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
Comment #2
pdureau commentedComment #3
pdureau commentedComment #4
pdureau commentedComment #5
mogtofu33 commentedComment #6
pdureau commentedComment #7
mogtofu33 commentedComment #8
pdureau commentedIt would be better to start working on this after #3529103: Remove Island's specific Form classes is merged
Comment #10
christian.wiedemann commentedComment #12
christian.wiedemann commentedHi all, I set this to review. It is not done but a short review would help me to know if I am on the right path. We can discuss that on wendsday
I did:
* Add PluginFormInterface, ConfigurableInterface to IslandInterface
* Implement a sample base form with a dummy label.
* Add forms.
* Pass configuration to island.
Questions:
* Should we make PluginFormInterface optional and add a basic implementation as a trait?
* Are there some basic configurations for every island.
Comment #13
christian.wiedemann commentedComment #14
pdureau commentedit is debatable, but i don't see any configuration shared by all islands. I can picture islands with no configuration.
By the way, you didn't add those first configs:
Do we focus this issue to the mechanism, and move the addition of the first configs to island plugins in a follow-up issue?
Comment #15
pdureau commentedTODO in the scope of this issue:
Pierre will move this to another issue:
Comment #16
christian.wiedemann commentedI finalized the island configuration part. Happy about review.
Comment #17
pdureau commentedThe expected config was not to display all the buttons or not, but only the "Clear" button:
Comment #18
pdureau commentedComment #19
mogtofu33 commentedFor the the configuration form of History island raise an ajax error without message.
Comment #20
mogtofu33 commentedI struggled on the rebase so canceled it, would be probable easier to squash the current mr to one commit.
Comment #23
mogtofu33 commentedI created a rebased version, bug is still there, and cannot add a new DB config as well.
Comment #24
mogtofu33 commentedFixed the configure click problem, the route
{display_builder}/{instance_id}was conflicting with{display_builder}/deleteStill have a problem when creating a new config of DB islands, the route require an id which is not ready yet and will raise an error.
Comment #25
mogtofu33 commentedFixed the new case, some style review and should be ok.
Comment #27
mogtofu33 commented