Skip to content

Commit

Permalink
Change labeling
Browse files Browse the repository at this point in the history
  • Loading branch information
cnasikas committed Jun 25, 2020
1 parent f6c9ca2 commit 7f12821
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ const JiraConnectorForm: React.FC<ConnectorFlyoutFormProps<JiraActionConnector>>
fullWidth
error={errors.email}
isInvalid={isEmailInvalid}
label={i18n.EMAIL_LABEL}
label={i18n.JIRA_EMAIL_LABEL}
>
<EuiFieldText
fullWidth
Expand All @@ -85,7 +85,7 @@ const JiraConnectorForm: React.FC<ConnectorFlyoutFormProps<JiraActionConnector>>
fullWidth
error={errors.apiToken}
isInvalid={isApiTokenInvalid}
label={i18n.API_TOKEN_LABEL}
label={i18n.JIRA_API_TOKEN_LABEL}
>
<EuiFieldPassword
fullWidth
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ const validateConnector = (action: JiraActionConnector): ValidationResult => {
}

if (!action.secrets.email) {
errors.email = [...errors.email, i18n.EMAIL_REQUIRED];
errors.email = [...errors.email, i18n.JIRA_EMAIL_REQUIRED];
}

if (!action.secrets.apiToken) {
errors.apiToken = [...errors.apiToken, i18n.API_TOKEN_REQUIRED];
errors.apiToken = [...errors.apiToken, i18n.JIRA_API_TOKEN_REQUIRED];
}

return { errors };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,34 @@ export const JIRA_PROJECT_KEY_REQUIRED = i18n.translate(
}
);

export const JIRA_EMAIL_LABEL = i18n.translate(
'xpack.securitySolution.case.connectors.jira.emailTextFieldLabel',
{
defaultMessage: 'Email or Username',
}
);

export const JIRA_EMAIL_REQUIRED = i18n.translate(
'xpack.securitySolution.case.connectors.common.requiredEmailTextField',
{
defaultMessage: 'Email or Username is required',
}
);

export const JIRA_API_TOKEN_LABEL = i18n.translate(
'xpack.securitySolution.case.connectors.jira.apiTokenTextFieldLabel',
{
defaultMessage: 'Api token or Password',
}
);

export const JIRA_API_TOKEN_REQUIRED = i18n.translate(
'xpack.securitySolution.case.connectors.jira.requiredApiTokenTextField',
{
defaultMessage: 'Api token or Password is required',
}
);

export const MAPPING_FIELD_SUMMARY = i18n.translate(
'xpack.securitySolution.case.configureCases.mappingFieldSummary',
{
Expand Down

0 comments on commit 7f12821

Please sign in to comment.