blob: 57d5742bf2e0d7ef9288be18d62b124ff1437df8 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
/**
* @file
* Attaches comment behaviors to the entity form.
*/
(function ($, Drupal) {
/**
*
* @type {Drupal~behavior}
*/
Drupal.behaviors.commentFieldsetSummaries = {
attach(context) {
const $context = $(context);
$context
.find('fieldset.comment-entity-settings-form')
.drupalSetSummary((context) =>
Drupal.checkPlain(
$(context)
.find('.js-form-item-comment input:checked')
.next('label')
.text(),
),
);
},
};
})(jQuery, Drupal);
|