1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-01 08:21:15 +03:00

Fix Button 'Create' - to be marked for translation

Fix Button 'Create' - to be marked for translation

closes: https://github.com/ansible/awx/issues/6887
This commit is contained in:
nixocio 2020-05-04 16:29:15 -04:00
parent 63fec77f82
commit 44311c163c
3 changed files with 4 additions and 1 deletions

View File

@ -336,6 +336,7 @@ function JobTemplateForm({
value={labelsField.value} value={labelsField.value}
onChange={labels => labelsHelpers.setValue(labels)} onChange={labels => labelsHelpers.setValue(labels)}
onError={setContentError} onError={setContentError}
createText={i18n._(t`Create`)}
/> />
</FormGroup> </FormGroup>
<VariablesField <VariablesField

View File

@ -29,7 +29,7 @@ async function loadLabelOptions(setLabels, onError) {
} }
} }
function LabelSelect({ value, placeholder, onChange, onError }) { function LabelSelect({ value, placeholder, onChange, onError, createText }) {
const { selections, onSelect, options, setOptions } = useSyncedSelectValue( const { selections, onSelect, options, setOptions } = useSyncedSelectValue(
value, value,
onChange onChange
@ -81,6 +81,7 @@ function LabelSelect({ value, placeholder, onChange, onError }) {
isExpanded={isExpanded} isExpanded={isExpanded}
ariaLabelledBy="label-select" ariaLabelledBy="label-select"
placeholderText={placeholder} placeholderText={placeholder}
createText={createText}
> >
{renderOptions(options)} {renderOptions(options)}
</Select> </Select>

View File

@ -251,6 +251,7 @@ function WorkflowJobTemplateForm({
value={labelsField.value} value={labelsField.value}
onChange={labels => labelsHelpers.setValue(labels)} onChange={labels => labelsHelpers.setValue(labels)}
onError={setContentError} onError={setContentError}
createText={i18n._(t`Create`)}
/> />
</FormGroup> </FormGroup>
</FormFullWidthLayout> </FormFullWidthLayout>