1/** 2 * @file 3 * Provides the processing logic for fieldsets. 4 */ 5 6(($) => { 7 Drupal.FieldGroup = Drupal.FieldGroup || {}; 8 Drupal.FieldGroup.Effects = Drupal.FieldGroup.Effects || {}; 9 10 /** 11 * This script adds the required and error classes to the fieldset wrapper. 12 */ 13 Drupal.behaviors.fieldGroupFieldset = { 14 attach(context) { 15 $(once('field-group-fieldset', '.field-group-fieldset', context)).each( 16 (index, element) => { 17 const $this = $(element); 18 19 if ( 20 element.matches('.required-fields') && 21 ($this.find('[required]').length > 0 || 22 $this.find('.form-required').length > 0) 23 ) { 24 $('legend', $this).first().addClass('form-required'); 25 } 26 }, 27 ); 28 }, 29 }; 30})(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.