Skip to content
Snippets Groups Projects
Commit a120d078 authored by Nia Kathoni's avatar Nia Kathoni Committed by Daniel Cothran
Browse files

Issue #3348131 by nikathone: Make chart data collector table element operation...

Issue #3348131 by nikathone: Make chart data collector table element operation buttons easier to translate
parent 1bc25450
No related branches found
No related tags found
1 merge request!52Issue #3348131: Translate operations buttons
......@@ -503,10 +503,12 @@ class ChartDataCollectorTable extends FormElement {
$submit += [
'#type' => 'submit',
'#name' => $name,
'#value' => t('@op @on', [
'@op' => ucfirst($operation),
'@on' => $on,
]),
'#value' => match(TRUE) {
$operation === 'add' && $on === 'row' => t('Add row'),
$operation === 'add' && $on === 'column' => t('Add column'),
$operation === 'delete' && $on === 'row' => t('Delete row'),
default => t('Delete column'),
},
'#limit_validation_errors' => [],
'#submit' => [[get_called_class(), 'tableOperationSubmit']],
'#operation' => $operation,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment