Mandatory Asterisk is not rendered for the Nested field groups

Created on 28 May 2024, about 1 month ago
Updated 24 June 2024, 4 days ago

Problem/Motivation

Mandatory Asterisk is not rendered for the Nested field groups

Steps to reproduce

1. Edit Article content type
2. Navigate to manage form display
3. Add nested field groups, move one mandatory field within the nested group
4. Add/Edit the article content
5. Mandatory Asterisk will be missing for Nested field groups (attached the screenshot)

Proposed resolution

.form-required class need to be added for the respective nested field group

🐛 Bug report
Status

RTBC

Version

3.0

Component

Code

Created by

🇮🇳India heykarthikwithu Bengaluru 🌍

Live updates comments and jobs are added and updated live.
  • Novice

    It would make a good project for someone who is new to the Drupal contribution process. It's preferred over Newbie.

Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @heykarthikwithu
  • 🇮🇳India heykarthikwithu Bengaluru 🌍

    I see we would need to add something like this within - formatters/fieldset/fieldset.js

    $('.fieldset__label').first().addClass('form-required');

  • First commit to issue fork.
  • Status changed to Needs review 28 days ago
  • 🇬🇧United Kingdom NexusNovaz

    I've added the line you mentioned above to the file. Tested on a vanilla drupal 10 instance and the first fieldset is marked as required. Though, i suspect another change may be needed to require the second fieldset.

  • Pipeline finished with Failed
    28 days ago
    Total: 243s
    #187679
  • 🇬🇧United Kingdom NexusNovaz

    Apologies!

    Updated the location and the line of code. I believe it now works as expected. Please could !55 this be reviewed

  • Pipeline finished with Failed
    28 days ago
    #187688
  • Status changed to RTBC 19 days ago
  • 🇦🇺Australia jannakha Brisbane!

    this issue affects some themes, eg Claro or Olivero

    MR!55 fixes the issue - tested on D 10.2.7 on Claro and Olivero.

    before

    after

    Why do tests fail?

  • 🇦🇺Australia jannakha Brisbane!

    @Edde20

    what's in the #8 patch?
    does the issue require re-testing?
    please set status of the issue to "needs review" and add some description to what's in the patch.

Production build 0.69.0 2024