Overview

:thinking: Why `ComponentTreeItem` and not just `ComponentInputs`? This means that _more_ than just the inputs can be modified by a `ComponentSource` plugin, which I think is a huge risk when we make this a public API.

IMHO this should be changed to something like:
```suggestion:-9+0
  public function optimizeExplicitInput(array $inputValues): void;
```

which removes that risk entirely. Note that `::getDefaultExplicitInput()` already returns such an array, and `::validateComponentInput()` already accepts such an array. So it seems more consistent, too.

Won't block this commit on it though, because `ComponentSourceInterface` won't be a public API until 1.0. :thumbsup:

https://git.drupalcode.org/project/experience_builder/-/merge_requests/1...

public function preSaveItem(ComponentTreeItem $item): void;
public function optimizeExplicitInput(array $inputValues): voi

Proposed resolution

User interface changes

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

larowlan created an issue. See original summary.

larowlan’s picture

Status: Active » Needs review

wim leers made their first commit to this issue’s fork.

wim leers’s picture

Status: Needs review » Reviewed & tested by the community
wim leers’s picture

Assigned: Unassigned » larowlan
Status: Reviewed & tested by the community » Needs review
wim leers’s picture

Assigned: larowlan » Unassigned
Issue summary: View changes
Status: Needs review » Reviewed & tested by the community
Parent issue: » #3520484: [META] Production-ready ComponentSource plugins

wim leers’s picture

Status: Reviewed & tested by the community » Fixed

Thanks!

Status: Fixed » Closed (fixed)

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