Parent Issue: Create Field Widget Actions plugins for Automators.

Created on 7 July 2025, 8 days ago

Problem/Motivation

NOTE - IMPORTANT: This is a parent issue, if you want to start working on a specific widget and automator combination, please create a child issue using the template below.

The Field Widget Action module is merged into 1.2.x, together with currently three widgets in the AI Automators:

In this process also the following have been made to make development/testing faster going forward:

  • A base class for all Automators Field Widget Plugins.
  • Any specific UI rules for a button, moves to a trait, see the trait for Image Alt Text where we have to make sure its just used when an image exists. These traits can be used by any consumer of the Field Widget Actions, and should be places in that module, rather than the Automators.
  • Functional Javascript tests, with a whole setup of a widget and a browser actually clicking the widget action. Make sure to use the AI base class and the takeScreenshot, and you can get screenshots of the process while doing it in a test.

Proposed resolution

Now we need the communities help to start pushing out a lot of Field Widget Actions for all the different field form displays that the field types that the Automators supports.

This means a combination of one or many Automator Types, that can be found under src/Plugin/AiAutomatorType and one or many form display types that will work the same.

So for instance you can decide to do the "llm_link" automator type, that maps to "link" field and the "link_default" form display type, but not the "linkit".

To be able to start on such an issue, you should:

  1. First check the issue queue so it has not already be created.
  2. Then create an issue using the Feature Issue Template below.
  3. Attach that issue as a child to the issue you are looking at here.
  4. This means that this issue your are looking at here, should not be worked on and should only be deemed finished when all the base Automators are covered.
  5. All issues gets 1 credit, even if a integer field is 100 times simpler then the Custom Field type.
  6. If anything is missing in the base class, please add it there in your MR.
  7. If a trait is missing for an UI, please add it to the Field Widget Action module in your MR.

Feature Issue Template

<h3 id="summary-problem-motivation">Problem/Motivation</h3>
The Field Widget Action module is merged into 1.2.x, however we need to start adding Automators plugins to it. The parent issue [#] is a parent issue for all the implementations of the Automators plugins. Read more in the parent issue.

This is the implementation of the Field Widget Action(s) [field_widget_actions] for the AI Automator Type(s) [ai_automator_types].

<h3 id="summary-proposed-resolution">Proposed resolution</h3>

<ul>
  <li>In the AI Automators module, create a new Field Widget Action plugin under src/Plugin/FieldWidgetAction.</li>
  <li>Call it [fieldWidgetActionsAiAutomatorType].php</li>
  <li>Use the FieldWidgetAction attribute and connect it to the correct widget_types and field_types</li>
  <li>At minimum, set up the first part of the aiAutomatorsAjax, where it picks the correct components, and if it should clearEntity and the formElementProperty. clearEntity, means that it removes the enities, to recreate them for the Automators, this should not be set if its a subfield.</li>
  <li>Manually test that its working and record a video of it working and upload to the feature (could be done by a reviewer).</li>
  <li>(optional, can be removed) Write at least a kernel test of the ajax function</li>
  <li>(optional, can be removed) Even better Function Javascript tests, but that is optional.</li>
</ul>

Feature request
Status

Active

Version

1.2

Component

AI Automators

Created by

🇩🇪Germany marcus_johansson

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024