From 884d70a94d87dd60c5f7a68a58a56a0b439e4a55 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:22:55 +0000
Subject: [PATCH 01/19] Get comment form heading.

---
 core/modules/comment/comment.module | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module
index 0928695ed156..3628bb9c50c7 100644
--- a/core/modules/comment/comment.module
+++ b/core/modules/comment/comment.module
@@ -722,6 +722,9 @@ function comment_preprocess_field(&$variables) {
 
     // Append additional attributes from the first field item.
     $variables['attributes'] += $variables['items'][0]['attributes']->storage();
+    
+    // Get comment form heading.
+    $variables['form_heading'] = $element[0]['#comment_form_heading'];
 
     // Create separate variables for the comments and comment form.
     $variables['comments'] = $element[0]['comments'];
-- 
GitLab


From 1d87968ffdd47db95561995616c7669e435fadc9 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:24:28 +0000
Subject: [PATCH 02/19] Update the form heading for all comment types.

---
 core/modules/comment/comment.post_update.php | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/core/modules/comment/comment.post_update.php b/core/modules/comment/comment.post_update.php
index 2c07518c49c3..3c78e472277e 100644
--- a/core/modules/comment/comment.post_update.php
+++ b/core/modules/comment/comment.post_update.php
@@ -14,3 +14,14 @@ function comment_removed_post_updates() {
     'comment_post_update_add_ip_address_setting' => '9.0.0',
   ];
 }
+
+/**
+ * Update the form heading for all comment types.
+ */
+function comment_post_update_form_heading_for_comment_types() {
+  $config_factory = \Drupal::configFactory();
+  foreach ($config_factory->listAll('comment.type.') as $type_name) {
+    $type = $config_factory->getEditable($type_name);
+    $type->set('form_heading', 'Add new comment')->save(TRUE);
+  }
+}
-- 
GitLab


From 254937dc43cd1853b5cdaa72f31d826ab18aa5c2 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:27:26 +0000
Subject: [PATCH 03/19] Add form_heading to comment.type.* in
 comment.schema.yml

---
 core/modules/comment/config/schema/comment.schema.yml | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/core/modules/comment/config/schema/comment.schema.yml b/core/modules/comment/config/schema/comment.schema.yml
index 33b3e55ac3ab..6ec4db9b859d 100644
--- a/core/modules/comment/config/schema/comment.schema.yml
+++ b/core/modules/comment/config/schema/comment.schema.yml
@@ -40,6 +40,9 @@ comment.type.*:
     description:
       type: text
       label: 'Description'
+    form_heading:
+      type: label
+      label: 'Form heading'
 
 field.storage_settings.comment:
   type: mapping
-- 
GitLab


From b61acc85359c709f3e9107b69e6fd94dc82c9a99 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:32:42 +0000
Subject: [PATCH 04/19] Add form_heading to form in CommentTypeForm.php

---
 core/modules/comment/src/CommentTypeForm.php | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/core/modules/comment/src/CommentTypeForm.php b/core/modules/comment/src/CommentTypeForm.php
index 78f11c665f90..ba0193d5ccff 100644
--- a/core/modules/comment/src/CommentTypeForm.php
+++ b/core/modules/comment/src/CommentTypeForm.php
@@ -103,6 +103,13 @@ public function form(array $form, FormStateInterface $form_state) {
       '#description' => $this->t('Displays on the <em>Comment types</em> page.'),
       '#title' => $this->t('Description'),
     ];
+    
+    $form['form_heading'] = [
+      '#type' => 'textfield',
+      '#title' => $this->t('Form heading'),
+      '#maxlength' => 255,
+      '#default_value' => $comment_type->getFormHeading(),
+    ];
 
     if ($comment_type->isNew()) {
       $options = [];
-- 
GitLab


From bde2339e6f31135042ead58a04b73ec4714bb957 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:35:22 +0000
Subject: [PATCH 05/19] Add public functions getFormHeading() and
 setFormHeading to Update CommentTypeInterface.php

---
 .../comment/src/CommentTypeInterface.php      | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/core/modules/comment/src/CommentTypeInterface.php b/core/modules/comment/src/CommentTypeInterface.php
index acde96c694f0..a601fd2dd477 100644
--- a/core/modules/comment/src/CommentTypeInterface.php
+++ b/core/modules/comment/src/CommentTypeInterface.php
@@ -27,6 +27,25 @@ public function getDescription();
    */
   public function setDescription($description);
 
+  /**
+   * Returns the comment type form heading.
+   *
+   * @return string
+   *   The comment-type form heading.
+   */
+  public function getFormHeading();
+
+  /**
+   * Sets the form heading of the comment type.
+   *
+   * @param string $form_heading
+   *   The new form heading.
+   *
+   * @return $this
+   */
+  public function setFormHeading($form_heading);
+
+
   /**
    * Gets the target entity type id for this comment type.
    *
-- 
GitLab


From 11c91eb52c0a60d9defc4d3759141a30d21aa187 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:38:59 +0000
Subject: [PATCH 06/19] Add form_heading to CommentType.php

---
 .../comment/src/Entity/CommentType.php        | 25 +++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/core/modules/comment/src/Entity/CommentType.php b/core/modules/comment/src/Entity/CommentType.php
index 77aa049538b6..5944d521266e 100644
--- a/core/modules/comment/src/Entity/CommentType.php
+++ b/core/modules/comment/src/Entity/CommentType.php
@@ -48,6 +48,7 @@
  *     "label",
  *     "target_entity_type_id",
  *     "description",
+ *     "form_heading",
  *   }
  * )
  */
@@ -74,6 +75,14 @@ class CommentType extends ConfigEntityBundleBase implements CommentTypeInterface
    */
   protected $description;
 
+  /**
+   * The form heading of the comment type.
+   *
+   * @var string
+   */
+  protected $form_heading = 'Add new comment';
+
+
   /**
    * The target entity type.
    *
@@ -96,6 +105,22 @@ public function setDescription($description) {
     return $this;
   }
 
+  /**
+   * {@inheritdoc}
+   */
+  public function getFormHeading() {
+    return $this->form_heading;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function setFormHeading($form_heading) {
+    $this->form_heading = $form_heading;
+    return $this;
+  }
+
+
   /**
    * {@inheritdoc}
    */
-- 
GitLab


From 4f122acd3215fefc22220ad9b016ad5598c6d79d Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:43:16 +0000
Subject: [PATCH 07/19] Add #comment_form_heading to
 CommentDefaultFormatter.php

---
 .../Plugin/Field/FieldFormatter/CommentDefaultFormatter.php    | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php b/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php
index fbc51eac5051..c0d21e0d651d 100644
--- a/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php
+++ b/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php
@@ -2,6 +2,7 @@
 
 namespace Drupal\comment\Plugin\Field\FieldFormatter;
 
+use Drupal\comment\Entity\CommentType;
 use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface;
 use Drupal\Core\Entity\Entity\EntityViewDisplay;
 use Drupal\Core\Entity\EntityDisplayRepositoryInterface;
@@ -206,9 +207,11 @@ public function viewElements(FieldItemListInterface $items, $langcode) {
         }
       }
 
+      $comment_type = CommentType::load($this->getFieldSetting('comment_type'));
       $elements[] = $output + [
         '#comment_type' => $this->getFieldSetting('comment_type'),
         '#comment_display_mode' => $this->getFieldSetting('default_mode'),
+        '#comment_form_heading' => $comment_type->getFormHeading(),
         'comments' => [],
         'comment_form' => [],
       ];
-- 
GitLab


From de4c98e807cb3312786af4a812a94d9d26764c2a Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:45:14 +0000
Subject: [PATCH 08/19] Add form_heading to CommentTestTrait.php

---
 core/modules/comment/src/Tests/CommentTestTrait.php | 1 +
 1 file changed, 1 insertion(+)

diff --git a/core/modules/comment/src/Tests/CommentTestTrait.php b/core/modules/comment/src/Tests/CommentTestTrait.php
index e26a2f02fbd9..6ef08d811014 100644
--- a/core/modules/comment/src/Tests/CommentTestTrait.php
+++ b/core/modules/comment/src/Tests/CommentTestTrait.php
@@ -49,6 +49,7 @@ public function addDefaultCommentField($entity_type, $bundle, $field_name = 'com
       $comment_type_storage->create([
         'id' => $comment_type_id,
         'label' => Unicode::ucfirst($comment_type_id),
+        'form_heading' => 'Add new comment',
         'target_entity_type_id' => $entity_type,
         'description' => 'Default comment field',
       ])->save();
-- 
GitLab


From 3d334778673abe374f84f0766e3f4567929cb10d Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:47:16 +0000
Subject: [PATCH 09/19] Add form_heading to field--comment.html.twig

---
 core/modules/comment/templates/field--comment.html.twig | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/core/modules/comment/templates/field--comment.html.twig b/core/modules/comment/templates/field--comment.html.twig
index 879f4d57ae4f..a3b168e7f4f3 100644
--- a/core/modules/comment/templates/field--comment.html.twig
+++ b/core/modules/comment/templates/field--comment.html.twig
@@ -14,7 +14,8 @@
  *   be displayed after the main title tag that appears in the template.
  * - comments: List of comments rendered through comment.html.twig.
  * - content_attributes: HTML attributes for the form title.
- * - comment_form: The 'Add new comment' form.
+ * - comment_form: The form to add new comment.
+ * - form_heading: The heading for comment form.
  * - comment_display_mode: Is the comments are threaded.
  * - comment_type: The comment type bundle ID for the comment field.
  * - entity_type: The entity type to which the field belongs.
@@ -36,7 +37,7 @@
   {{ comments }}
 
   {% if comment_form %}
-    <h2{{ content_attributes }}>{{ 'Add new comment'|t }}</h2>
+    <h2{{ content_attributes }}>{{ form_heading }}</h2>
     {{ comment_form }}
   {% endif %}
 
-- 
GitLab


From 223f1b16676f3bea8188e44e993a36a8a2dcf59c Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:49:55 +0000
Subject: [PATCH 10/19] Add Tests for Comment heading section to
 CommentTypeTest.php

---
 .../tests/src/Functional/CommentTypeTest.php  | 55 +++++++++++++++++++
 1 file changed, 55 insertions(+)

diff --git a/core/modules/comment/tests/src/Functional/CommentTypeTest.php b/core/modules/comment/tests/src/Functional/CommentTypeTest.php
index 097560027541..0e7fe1a948b4 100644
--- a/core/modules/comment/tests/src/Functional/CommentTypeTest.php
+++ b/core/modules/comment/tests/src/Functional/CommentTypeTest.php
@@ -211,4 +211,59 @@ public function testCommentTypeDeletion(): void {
     $this->assertSession()->pageTextContains('The comment type ' . $type->label() . ' has been deleted.');
   }
 
+  /**
+   * Tests for Comment heading section.
+   */
+  public function testCommentHeading() {
+    $user = $this->drupalCreateUser([], 'comments', TRUE);
+    // Log in a test user.
+    $this->drupalLogin($user);
+    // Ensure that the new comment type admin page can be accessed.
+    $this->drupalGet('admin/structure/comment/types/add');
+    $this->assertSession()->statusCodeEquals(200);
+    // Create a comment type via the user interface and assert the form heading is saved.
+    $edit = [
+      'id' => 'header',
+      'label' => 'title for header',
+      'description' => '',
+      'target_entity_type_id' => 'node',
+      'form_heading' => 'heading for new comment',
+    ];
+    $this->submitForm($edit, 'Save');
+    $comment_type = CommentType::load('header');
+    $this->assertInstanceOf(CommentType::class, $comment_type);
+    $this->assertSame('heading for new comment', $comment_type->get('form_heading'));
+
+    // Create a Content type and a node and attach comment to it.
+    $this->drupalCreateContentType(['type' => 'page']);
+    $this->addDefaultCommentField('node', 'page', 'header', CommentItemInterface::OPEN, 'header');
+    $field_storage = FieldStorageConfig::loadByName('node', 'header');
+
+    $node = Node::create([
+      'type' => 'page',
+      'title' => 'Node with Comment',
+    ]);
+    $node->save();
+
+    // Add a new comment of this type.
+    $comment = Comment::create([
+      'comment_type' => 'header',
+      'entity_type' => 'node',
+      'field_name' => 'header',
+      'entity_id' => $node->id(),
+    ]);
+    $comment->save();
+
+    $this->drupalGet('comment/' . $comment->id());
+    $this->assertSession()->statusCodeEquals(200);
+    $edit = [
+      'subject[0][value]' => 'New comment',
+      'comment_body[0][value]' => 'Body Content',
+    ];
+    $this->submitForm($edit, 'Save');
+    $this->drupalGet('comment/' . $comment->id());
+    $this->assertSession()->pageTextContains('Node with Comment');
+    $this->assertSession()->pageTextContains('heading for new comment');
+  }
+
 }
-- 
GitLab


From 2809c42abaa38c1c8c66a53b2ed8d8828c5ebf3c Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:52:40 +0000
Subject: [PATCH 11/19] Add form_heading to CommentTypeResourceTestBase.php

---
 .../tests/src/Functional/Rest/CommentTypeResourceTestBase.php    | 1 +
 1 file changed, 1 insertion(+)

diff --git a/core/modules/comment/tests/src/Functional/Rest/CommentTypeResourceTestBase.php b/core/modules/comment/tests/src/Functional/Rest/CommentTypeResourceTestBase.php
index c1769a928c9c..e08fde1ca4a5 100644
--- a/core/modules/comment/tests/src/Functional/Rest/CommentTypeResourceTestBase.php
+++ b/core/modules/comment/tests/src/Functional/Rest/CommentTypeResourceTestBase.php
@@ -60,6 +60,7 @@ protected function getExpectedNormalizedEntity() {
     return [
       'dependencies' => [],
       'description' => 'Camelids are large, strictly herbivorous animals with slender necks and long legs.',
+      'form_heading' => 'Add new comment',
       'id' => 'camelids',
       'label' => 'Camelids',
       'langcode' => 'en',
-- 
GitLab


From fd0a77a529ec06194ea118afb53fdd77bf4c4615 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:56:01 +0000
Subject: [PATCH 12/19] Add form_heading to jsonapi CommentTypeTest.php

---
 core/modules/jsonapi/tests/src/Functional/CommentTypeTest.php | 1 +
 1 file changed, 1 insertion(+)

diff --git a/core/modules/jsonapi/tests/src/Functional/CommentTypeTest.php b/core/modules/jsonapi/tests/src/Functional/CommentTypeTest.php
index 24e42d3e666b..0ef3db9f61e0 100644
--- a/core/modules/jsonapi/tests/src/Functional/CommentTypeTest.php
+++ b/core/modules/jsonapi/tests/src/Functional/CommentTypeTest.php
@@ -97,6 +97,7 @@ protected function getExpectedDocument(): array {
           'status' => TRUE,
           'target_entity_type_id' => 'node',
           'drupal_internal__id' => 'camelids',
+          'form_heading' => 'Add new comment',
         ],
       ],
     ];
-- 
GitLab


From 74ce9daa643ffa66ee0d5b338c80ee2eeb8dac4f Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 00:57:44 +0000
Subject: [PATCH 13/19] Add form_heading to standard profile
 comment.type.comment.yml

---
 core/profiles/standard/config/install/comment.type.comment.yml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/core/profiles/standard/config/install/comment.type.comment.yml b/core/profiles/standard/config/install/comment.type.comment.yml
index ddcbbc986095..18b732579745 100644
--- a/core/profiles/standard/config/install/comment.type.comment.yml
+++ b/core/profiles/standard/config/install/comment.type.comment.yml
@@ -5,3 +5,4 @@ id: comment
 label: 'Default comments'
 target_entity_type_id: node
 description: 'Allows commenting on content'
+form_heading: 'Add new comment'
-- 
GitLab


From a54d37b60c9df214c4e239cb758a8b26515c10c6 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:06:56 +0000
Subject: [PATCH 14/19] Add form_heading to stable9's field--comment.html.twig

---
 core/themes/stable9/templates/field/field--comment.html.twig | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/core/themes/stable9/templates/field/field--comment.html.twig b/core/themes/stable9/templates/field/field--comment.html.twig
index 33a60ae0bdcb..b349366560e6 100644
--- a/core/themes/stable9/templates/field/field--comment.html.twig
+++ b/core/themes/stable9/templates/field/field--comment.html.twig
@@ -14,7 +14,8 @@
  *   be displayed after the main title tag that appears in the template.
  * - comments: List of comments rendered through comment.html.twig.
  * - content_attributes: HTML attributes for the form title.
- * - comment_form: The 'Add new comment' form.
+ * - comment_form: The form to add new comment.
+ * - form_heading: The heading for comment form.
  * - comment_display_mode: Is the comments are threaded.
  * - comment_type: The comment type bundle ID for the comment field.
  * - entity_type: The entity type to which the field belongs.
@@ -36,7 +37,7 @@
   {{ comments }}
 
   {% if comment_form %}
-    <h2{{ content_attributes }}>{{ 'Add new comment'|t }}</h2>
+    <h2{{ content_attributes }}>{{ form_heading }}</h2>
     {{ comment_form }}
   {% endif %}
 
-- 
GitLab


From 2141fbd778151a06074496f93c515118bcbfb401 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:08:14 +0000
Subject: [PATCH 15/19] Add form_heading to starterkit's
 field--comment.html.twig

---
 .../templates/field/field--comment.html.twig                 | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/core/themes/starterkit_theme/templates/field/field--comment.html.twig b/core/themes/starterkit_theme/templates/field/field--comment.html.twig
index 1ec3ee64b104..565c448c7b05 100644
--- a/core/themes/starterkit_theme/templates/field/field--comment.html.twig
+++ b/core/themes/starterkit_theme/templates/field/field--comment.html.twig
@@ -13,7 +13,8 @@
  * - title_suffix: Additional title output populated by modules, intended to
  *   be displayed after the main title tag that appears in the template.
  * - comments: List of comments rendered through comment.html.twig.
- * - comment_form: The 'Add new comment' form.
+ * - comment_form: The form to add new comment.
+ * - form_heading: The heading for comment form.
  * - comment_display_mode: Is the comments are threaded.
  * - comment_type: The comment type bundle ID for the comment field.
  * - entity_type: The entity type to which the field belongs.
@@ -50,7 +51,7 @@
   {{ comments }}
 
   {% if comment_form %}
-    <h2 class="title comment-form__title">{{ 'Add new comment'|t }}</h2>
+    <h2 class="title comment-form__title">{{ form_heading }}</h2>
     {{ comment_form }}
   {% endif %}
 
-- 
GitLab


From bf88117d61c66b8f956bf28e0c1c711aea1498ac Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:27:43 +0000
Subject: [PATCH 16/19] Fixed double-blank-line after function in
 CommentType.php

---
 core/modules/comment/src/Entity/CommentType.php | 1 -
 1 file changed, 1 deletion(-)

diff --git a/core/modules/comment/src/Entity/CommentType.php b/core/modules/comment/src/Entity/CommentType.php
index 5944d521266e..6809c5d72eff 100644
--- a/core/modules/comment/src/Entity/CommentType.php
+++ b/core/modules/comment/src/Entity/CommentType.php
@@ -120,7 +120,6 @@ public function setFormHeading($form_heading) {
     return $this;
   }
 
-
   /**
    * {@inheritdoc}
    */
-- 
GitLab


From c0969419e2f9da144567ccbe6d79ec7a852e3b83 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:29:55 +0000
Subject: [PATCH 17/19] Fixed double-blank-line after function in
 CommentTypeInterface.php

---
 core/modules/comment/src/CommentTypeInterface.php | 1 -
 1 file changed, 1 deletion(-)

diff --git a/core/modules/comment/src/CommentTypeInterface.php b/core/modules/comment/src/CommentTypeInterface.php
index a601fd2dd477..591ce51c1cf1 100644
--- a/core/modules/comment/src/CommentTypeInterface.php
+++ b/core/modules/comment/src/CommentTypeInterface.php
@@ -45,7 +45,6 @@ public function getFormHeading();
    */
   public function setFormHeading($form_heading);
 
-
   /**
    * Gets the target entity type id for this comment type.
    *
-- 
GitLab


From 2fb6c9103d9e6567c2bc8ebdf09a47e035df2c74 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:31:06 +0000
Subject: [PATCH 18/19] Fixed whitespace found at end of line in
 CommentTypeForm.php

---
 core/modules/comment/src/CommentTypeForm.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/core/modules/comment/src/CommentTypeForm.php b/core/modules/comment/src/CommentTypeForm.php
index ba0193d5ccff..6738503faf36 100644
--- a/core/modules/comment/src/CommentTypeForm.php
+++ b/core/modules/comment/src/CommentTypeForm.php
@@ -103,7 +103,7 @@ public function form(array $form, FormStateInterface $form_state) {
       '#description' => $this->t('Displays on the <em>Comment types</em> page.'),
       '#title' => $this->t('Description'),
     ];
-    
+
     $form['form_heading'] = [
       '#type' => 'textfield',
       '#title' => $this->t('Form heading'),
-- 
GitLab


From b4d47ab96ab9f97244f89f17bc46ffc7c94642b9 Mon Sep 17 00:00:00 2001
From: Jacob Mirzaian <62478-jacobupal@users.noreply.drupalcode.org>
Date: Fri, 16 Aug 2024 01:32:16 +0000
Subject: [PATCH 19/19] Fixed whitespace found at end of line in comment.module

---
 core/modules/comment/comment.module | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module
index 3628bb9c50c7..0a3fd65952d4 100644
--- a/core/modules/comment/comment.module
+++ b/core/modules/comment/comment.module
@@ -722,7 +722,7 @@ function comment_preprocess_field(&$variables) {
 
     // Append additional attributes from the first field item.
     $variables['attributes'] += $variables['items'][0]['attributes']->storage();
-    
+
     // Get comment form heading.
     $variables['form_heading'] = $element[0]['#comment_form_heading'];
 
-- 
GitLab

