Problem/Motivation

Even when the translation has been added, the 'Custom Body Class Settings' label in content type edit page does not show the translation for the active site language.

Steps to reproduce

  1. Install and enable module.
  2. Add translation to the 'Custom Body Class Settings' string.
  3. Access content type edit screen (/admin/structure/types/manage/content_type).
  4. The label 'Custom Body Class Settings' does not show the translation.

Proposed resolution

Change line 46 of custom_body_class.module from

#title' => ('Custom Body Class Settings'),

to

#title' => t('Custom Body Class Settings'),

After this change, the label translation in displayed.

CommentFileSizeAuthor
#2 issues-3410777-translation-added.patch644 bytesviren18febs
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

ilfelice created an issue. See original summary.

viren18febs’s picture

Status: Active » Needs review
StatusFileSize
new644 bytes

I have added a patch with the changes.
Thanks

ilfelice’s picture

Hello @viren18febs!

Thank you for the fast response.

I don't have my dev PC at hand, so have not actually tried the patch.

But looking at it, and being as simple as it is, I think it patch is good to go.

Have a happy new year!

AstonVictor made their first commit to this issue’s fork.

astonvictor’s picture

Status: Needs review » Reviewed & tested by the community

It works for me. Added changes as an MR.

astonvictor’s picture

note that the 2.0.0 branch is missing in Gitlab.