Multiple fields widget should fully work in the contexual form

Created on 13 March 2025, about 1 month ago

Overview

Not categorizing as *bug* because this, like many other things XB, is functionality that hasn't been built yet. Nothing has been broken, etc.

All the issues were found in the page data form. I assume this would hold true with the props for, but there aren't currently prop types that support offering a multi value widget.

Among other things, I could only add 2 items despite it being an unlimited item field, and clicking remove on an item resulted in the whole widget disappearing.

Proposed resolution

Obviously, get it working. Perhaps get it radix'd in the process.

User interface changes

📌 Task
Status

Active

Version

0.0

Component

Semi-Coupled theme engine

Created by

🇺🇸United States bnjmnm Ann Arbor, MI

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

Merge Requests

Comments & Activities

  • Issue created by @bnjmnm
  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    I ran into this months ago in #3467870 — see #3467870-16: Support `{type: array, …}` prop shapes , which included this screenshot:

    (back in September!)

  • 🇺🇸United States bnjmnm Ann Arbor, MI

    Re #2. So 📌 [later phase] Support matching `{type: array, …}` prop shapes Postponed should definitely be blocked on this. We'll scope this at the widget JS functionality (controls show up, it is sortable, 'add' and 'remove' add and remove the correct things, etc), which should free up #3467870 to focus on what is attempting to be built there.

  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    🙏 Music to my ears! 😄

  • Merge request !801#3512860 multi value widget support → (Merged) created by bnjmnm
  • Pipeline finished with Failed
    about 1 month ago
    Total: 682s
    #452473
  • Pipeline finished with Failed
    about 1 month ago
    Total: 1544s
    #452486
  • Pipeline finished with Failed
    about 1 month ago
    Total: 1396s
    #453258
  • Pipeline finished with Failed
    about 1 month ago
    Total: 1552s
    #453396
  • Pipeline finished with Failed
    30 days ago
    Total: 1104s
    #459114
  • Pipeline finished with Failed
    30 days ago
    Total: 2116s
    #459138
  • Pipeline finished with Failed
    30 days ago
    Total: 1477s
    #459173
  • Pipeline finished with Failed
    30 days ago
    #459182
  • Pipeline finished with Failed
    30 days ago
    Total: 1402s
    #459206
  • Pipeline finished with Failed
    30 days ago
    Total: 2301s
    #459243
  • Pipeline finished with Canceled
    30 days ago
    Total: 207s
    #459267
  • Pipeline finished with Failed
    30 days ago
    Total: 2108s
    #459269
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    Feedback addressed

    • The media library e2e fail is unrelated and is addressed in this MR
    • The phpstan fail is unrelated and addressed in this MR
  • Pipeline finished with Failed
    29 days ago
    Total: 1449s
    #459860
  • Pipeline finished with Failed
    29 days ago
    Total: 1799s
    #459875
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    Review findings have been addressed. The CI reds are the same unrelated ones I called out in #6

    • The media library e2e fail is unrelated and is addressed in this MR
    • The phpstan fail is unrelated and addressed in this MR
  • 🇦🇺Australia larowlan 🇦🇺🏝.au GMT+10

    Adding parent Meta

  • Pipeline finished with Failed
    26 days ago
    Total: 1359s
    #461822
  • Pipeline finished with Failed
    26 days ago
    Total: 2820s
    #461831
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    Knew the tabledrag targeting in ajax.hyperscriptify.js wasn't great - adding a few attributes per @larowlan suggestion does a much better job of it.

  • Pipeline finished with Failed
    24 days ago
    #463341
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    The currently skipped-on-ci e2e tests are also passing

  • Pipeline finished with Canceled
    24 days ago
    #463471
  • Pipeline finished with Running
    24 days ago
    #463472
  • Pipeline finished with Failed
    24 days ago
    #463566
  • Pipeline finished with Failed
    24 days ago
    #463570
  • Pipeline finished with Failed
    24 days ago
    #463538
  • Pipeline finished with Failed
    24 days ago
    #463592
  • Pipeline finished with Canceled
    24 days ago
    #463612
  • Pipeline finished with Failed
    24 days ago
    #463614
  • Pipeline finished with Failed
    24 days ago
    Total: 1484s
    #463650
  • Pipeline finished with Skipped
    24 days ago
    #463687
    • bnjmnm committed 2e53da3a on 0.x
      Issue #3512860: Multi-valued fields' widget should fully work in the...
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    Given the required approvals are made, this passes tests, and there's several other issues that will benefit from the hyperscriptify and test improvements, I'm going to merge this in.

  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    Great to see this starting to work, this unblocks initial tyoe: array support as indicated in #2! 🥳

  • 🇺🇸United States bnjmnm Ann Arbor, MI

    This scope couldn't include component instance forms as there aren't props that support them yet.

  • 🇦🇺Australia larowlan 🇦🇺🏝.au GMT+10

    Adding related 📌 Add e2e tests for multi-value textfield widget in page data form Active

    FWIW this is not working as expected when there is another button on the form above the multi-value widget.

    I've traced it down to issues in the client data converter w.r.t cached form state where the form state is not set to programmed - which causes Drupal to find a triggering element.

    Will continue with unpicking it over there.

Production build 0.71.5 2024