No Code Attached Yet Information Required bug
avatar peter1szalatnay
peter1szalatnay
29 Feb 2024

Steps to reproduce the issue

Notices that when you use titleSelect="COM_X_FIELD_X_LABEL" in a modal select XML it will never get translated as there is no Text::_() on the button in the code below.

'textHeader' => $modalTitles['select'] ?? Text::_('JSELECT'),

One more thing is that if you don't set the titleSelect the title is empty as the sting value will always return true and Text::_('JSELECT') is never selected either.

Expected result

Modal title should be translated.

Actual result

Modal title is not translated.

System information (as much as possible)

phpversion: 8.2.11
server: nginx/1.23.1
version: Joomla! 5.0.3 Stable [ Kuboresha ] 20-February-2024 16:00 GMT

Additional comments

avatar peter1szalatnay peter1szalatnay - open - 29 Feb 2024
avatar joomla-cms-bot joomla-cms-bot - change - 29 Feb 2024
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 29 Feb 2024
avatar Hackwar Hackwar - change - 26 Mar 2024
Labels Added: bug
avatar Hackwar Hackwar - labeled - 26 Mar 2024
avatar brianteeman
brianteeman - comment - 7 May 2024

If you look at all the instances of this code you will see that Text:: is applied when the button is defined eg

$childBar->popupButton('batch', 'JTOOLBAR_BATCH')
->popupType('inline')
->textHeader(Text::_('COM_BANNERS_BATCH_OPTIONS'))
->url('#joomla-dialog-batch')
->modalWidth('800px')
->modalHeight('fit-content')
->listCheck(true);
}

avatar Quy Quy - change - 7 May 2024
Labels Added: Information Required
avatar Quy Quy - labeled - 7 May 2024
avatar Quy Quy - change - 2 Aug 2024
Status New Closed
Closed_Date 0000-00-00 00:00:00 2024-08-02 20:54:42
Closed_By Quy
avatar Quy Quy - close - 2 Aug 2024
avatar Fedik
Fedik - comment - 3 Aug 2024

It is actually valid bug. Please test the fix #43878

Add a Comment

Login with GitHub to post a comment