mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-29 18:22:41 +01:00
Remove product literal strings in "pht()", part 12
Summary: Ref T13658. Test Plan: This is non-exhuastive. - Poked around "Auth": edited a provider, toggled a provider. Maniphest Tasks: T13658 Differential Revision: https://secure.phabricator.com/D21778
This commit is contained in:
parent
039cbec155
commit
4d70e9d400
10 changed files with 52 additions and 49 deletions
|
@ -80,9 +80,9 @@ final class PhabricatorAuthLoginController
|
||||||
} else {
|
} else {
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'The external account ("%s") you just authenticated with is '.
|
'The external service ("%s") you just authenticated with is '.
|
||||||
'not configured to allow logins on this Phabricator install. '.
|
'not configured to allow logins on this server. An '.
|
||||||
'An administrator may have recently disabled it.',
|
'administrator may have recently disabled it.',
|
||||||
$provider->getProviderName()));
|
$provider->getProviderName()));
|
||||||
}
|
}
|
||||||
} else if ($viewer->getPHID() == $account->getUserPHID()) {
|
} else if ($viewer->getPHID() == $account->getUserPHID()) {
|
||||||
|
@ -94,11 +94,14 @@ final class PhabricatorAuthLoginController
|
||||||
} else {
|
} else {
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'The external account ("%s") you just used to log in is already '.
|
'The external service ("%s") you just used to log in is already '.
|
||||||
'associated with another Phabricator user account. Log in to the '.
|
'associated with another %s user account. Log in to the '.
|
||||||
'other Phabricator account and unlink the external account before '.
|
'other %s account and unlink the external account before '.
|
||||||
'linking it to a new Phabricator account.',
|
'linking it to a new %s account.',
|
||||||
$provider->getProviderName()));
|
$provider->getProviderName(),
|
||||||
|
PlatformSymbols::getPlatformServerName(),
|
||||||
|
PlatformSymbols::getPlatformServerName(),
|
||||||
|
PlatformSymbols::getPlatformServerName()));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// The account is not yet attached to a Phabricator user, so this is
|
// The account is not yet attached to a Phabricator user, so this is
|
||||||
|
@ -109,9 +112,9 @@ final class PhabricatorAuthLoginController
|
||||||
} else {
|
} else {
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'The external account ("%s") you just authenticated with is '.
|
'The external service ("%s") you just authenticated with is '.
|
||||||
'not configured to allow registration on this Phabricator '.
|
'not configured to allow registration on this server. An '.
|
||||||
'install. An administrator may have recently disabled it.',
|
'administrator may have recently disabled it.',
|
||||||
$provider->getProviderName()));
|
$provider->getProviderName()));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -135,11 +138,12 @@ final class PhabricatorAuthLoginController
|
||||||
if ($existing_accounts) {
|
if ($existing_accounts) {
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'Your Phabricator account is already connected to an external '.
|
'Your %s account is already connected to an external '.
|
||||||
'account on this provider ("%s"), but you are currently logged '.
|
'account on this service ("%s"), but you are currently logged '.
|
||||||
'in to the provider with a different account. Log out of the '.
|
'in to the service with a different account. Log out of the '.
|
||||||
'external service, then log back in with the correct account '.
|
'external service, then log back in with the correct account '.
|
||||||
'before refreshing the account link.',
|
'before refreshing the account link.',
|
||||||
|
PlatformSymbols::getPlatformServerName(),
|
||||||
$provider->getProviderName()));
|
$provider->getProviderName()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -148,9 +152,9 @@ final class PhabricatorAuthLoginController
|
||||||
} else {
|
} else {
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'The external account ("%s") you just authenticated with is '.
|
'The external service ("%s") you just authenticated with is '.
|
||||||
'not configured to allow account linking on this Phabricator '.
|
'not configured to allow account linking on this server. An '.
|
||||||
'install. An administrator may have recently disabled it.',
|
'administrator may have recently disabled it.',
|
||||||
$provider->getProviderName()));
|
$provider->getProviderName()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -169,7 +173,8 @@ final class PhabricatorAuthLoginController
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'The external account you just logged in with is not associated '.
|
'The external account you just logged in with is not associated '.
|
||||||
'with a valid Phabricator user.'));
|
'with a valid %s user account.',
|
||||||
|
PlatformSymbols::getPlatformServerName()));
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->loginUser($user);
|
return $this->loginUser($user);
|
||||||
|
|
|
@ -202,7 +202,7 @@ final class PhabricatorAuthNeedsMultiFactorController
|
||||||
$messages = array();
|
$messages = array();
|
||||||
|
|
||||||
$messages[] = pht(
|
$messages[] = pht(
|
||||||
'Before you can use Phabricator, you need to add multi-factor '.
|
'Before you can use this software, you need to add multi-factor '.
|
||||||
'authentication to your account. Multi-factor authentication helps '.
|
'authentication to your account. Multi-factor authentication helps '.
|
||||||
'secure your account by making it more difficult for attackers to '.
|
'secure your account by making it more difficult for attackers to '.
|
||||||
'gain access or take sensitive actions.');
|
'gain access or take sensitive actions.');
|
||||||
|
|
|
@ -42,10 +42,11 @@ final class PhabricatorAuthSetExternalController
|
||||||
PhabricatorAuthLinkMessageType::MESSAGEKEY);
|
PhabricatorAuthLinkMessageType::MESSAGEKEY);
|
||||||
if (!strlen($text)) {
|
if (!strlen($text)) {
|
||||||
$text = pht(
|
$text = pht(
|
||||||
'You can link your Phabricator account to an external account to '.
|
'You can link your %s account to an external account to '.
|
||||||
'allow you to log in more easily in the future. To continue, choose '.
|
'allow you to log in more easily in the future. To continue, choose '.
|
||||||
'an account to link below. If you prefer not to link your account, '.
|
'an account to link below. If you prefer not to link your account, '.
|
||||||
'you can skip this step.');
|
'you can skip this step.',
|
||||||
|
PlatformSymbols::getPlatformServerName());
|
||||||
}
|
}
|
||||||
|
|
||||||
$remarkup_view = new PHUIRemarkupView($viewer, $text);
|
$remarkup_view = new PHUIRemarkupView($viewer, $text);
|
||||||
|
|
|
@ -90,11 +90,11 @@ final class PhabricatorAuthStartController
|
||||||
|
|
||||||
return $this->renderError(
|
return $this->renderError(
|
||||||
pht(
|
pht(
|
||||||
'This Phabricator install is not configured with any enabled '.
|
'This server is not configured with any enabled authentication '.
|
||||||
'authentication providers which can be used to log in. If you '.
|
'providers which can be used to log in. If you have accidentally '.
|
||||||
'have accidentally locked yourself out by disabling all providers, '.
|
'locked yourself out by disabling all providers, you can use `%s` '.
|
||||||
'you can use `%s` to recover access to an account.',
|
'to recover access to an account.',
|
||||||
'phabricator/bin/auth recover <username>'));
|
'./bin/auth recover <username>'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$next_uri = $request->getStr('next');
|
$next_uri = $request->getStr('next');
|
||||||
|
|
|
@ -86,7 +86,7 @@ final class PhabricatorAuthUnlinkController
|
||||||
->appendChild(
|
->appendChild(
|
||||||
pht(
|
pht(
|
||||||
'You can not unlink this account because the administrator has '.
|
'You can not unlink this account because the administrator has '.
|
||||||
'configured Phabricator to make links to "%s" accounts permanent.',
|
'configured this server to make links to "%s" accounts permanent.',
|
||||||
$provider->getProviderName()))
|
$provider->getProviderName()))
|
||||||
->addCancelButton($done_uri);
|
->addCancelButton($done_uri);
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,7 @@ final class PhabricatorAuthUnlinkController
|
||||||
$title = pht('Unlink "%s" Account?', $provider->getProviderName());
|
$title = pht('Unlink "%s" Account?', $provider->getProviderName());
|
||||||
$body = pht(
|
$body = pht(
|
||||||
'You will no longer be able to use your %s account to '.
|
'You will no longer be able to use your %s account to '.
|
||||||
'log in to Phabricator.',
|
'log in.',
|
||||||
$provider->getProviderName());
|
$provider->getProviderName());
|
||||||
|
|
||||||
return $this->newDialog()
|
return $this->newDialog()
|
||||||
|
|
|
@ -34,8 +34,7 @@ final class PhabricatorMustVerifyEmailController
|
||||||
|
|
||||||
$must_verify = pht(
|
$must_verify = pht(
|
||||||
'You must verify your email address to log in. You should have a '.
|
'You must verify your email address to log in. You should have a '.
|
||||||
'new email message from Phabricator with verification instructions '.
|
'new email message with verification instructions in your inbox (%s).',
|
||||||
'in your inbox (%s).',
|
|
||||||
phutil_tag('strong', array(), $email_address));
|
phutil_tag('strong', array(), $email_address));
|
||||||
|
|
||||||
$send_again = pht(
|
$send_again = pht(
|
||||||
|
|
|
@ -49,12 +49,12 @@ final class PhabricatorAuthDisableController
|
||||||
if ($config->getShouldAllowRegistration()) {
|
if ($config->getShouldAllowRegistration()) {
|
||||||
$body = pht(
|
$body = pht(
|
||||||
'Do you want to enable this provider? Users will be able to use '.
|
'Do you want to enable this provider? Users will be able to use '.
|
||||||
'their existing external accounts to register new Phabricator '.
|
'their existing external accounts to register new accounts and '.
|
||||||
'accounts and log in using linked accounts.');
|
'log in using linked accounts.');
|
||||||
} else {
|
} else {
|
||||||
$body = pht(
|
$body = pht(
|
||||||
'Do you want to enable this provider? Users will be able to log '.
|
'Do you want to enable this provider? Users will be able to log '.
|
||||||
'in to Phabricator using linked accounts.');
|
'in using linked accounts.');
|
||||||
}
|
}
|
||||||
$button = pht('Enable Provider');
|
$button = pht('Enable Provider');
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -220,7 +220,7 @@ final class PhabricatorAuthEditController
|
||||||
} else {
|
} else {
|
||||||
$registration_warning = pht(
|
$registration_warning = pht(
|
||||||
"NOTE: Any user who can browse to this install's login page will be ".
|
"NOTE: Any user who can browse to this install's login page will be ".
|
||||||
"able to register a Phabricator account. To restrict who can register ".
|
"able to register an account. To restrict who can register ".
|
||||||
"an account, configure [[ %s | %s ]].",
|
"an account, configure [[ %s | %s ]].",
|
||||||
$config_href,
|
$config_href,
|
||||||
$config_name);
|
$config_name);
|
||||||
|
@ -238,10 +238,9 @@ final class PhabricatorAuthEditController
|
||||||
phutil_tag('strong', array(), pht('Allow Registration:')),
|
phutil_tag('strong', array(), pht('Allow Registration:')),
|
||||||
' ',
|
' ',
|
||||||
pht(
|
pht(
|
||||||
'Allow users to register new Phabricator accounts using this '.
|
'Allow users to register new accounts using this provider. If you '.
|
||||||
'provider. If you disable registration, users can still use this '.
|
'disable registration, users can still use this provider to log in '.
|
||||||
'provider to log in to existing accounts, but will not be able to '.
|
'to existing accounts, but will not be able to create new accounts.'),
|
||||||
'create new accounts.'),
|
|
||||||
);
|
);
|
||||||
|
|
||||||
$str_link = hsprintf(
|
$str_link = hsprintf(
|
||||||
|
@ -249,29 +248,29 @@ final class PhabricatorAuthEditController
|
||||||
pht('Allow Linking Accounts'),
|
pht('Allow Linking Accounts'),
|
||||||
pht(
|
pht(
|
||||||
'Allow users to link account credentials for this provider to '.
|
'Allow users to link account credentials for this provider to '.
|
||||||
'existing Phabricator accounts. There is normally no reason to '.
|
'existing accounts. There is normally no reason to disable this '.
|
||||||
'disable this unless you are trying to move away from a provider '.
|
'unless you are trying to move away from a provider and want to '.
|
||||||
'and want to stop users from creating new account links.'));
|
'stop users from creating new account links.'));
|
||||||
|
|
||||||
$str_unlink = hsprintf(
|
$str_unlink = hsprintf(
|
||||||
'<strong>%s:</strong> %s',
|
'<strong>%s:</strong> %s',
|
||||||
pht('Allow Unlinking Accounts'),
|
pht('Allow Unlinking Accounts'),
|
||||||
pht(
|
pht(
|
||||||
'Allow users to unlink account credentials for this provider from '.
|
'Allow users to unlink account credentials for this provider from '.
|
||||||
'existing Phabricator accounts. If you disable this, Phabricator '.
|
'existing accounts. If you disable this, accounts will be '.
|
||||||
'accounts will be permanently bound to provider accounts.'));
|
'permanently bound to provider accounts.'));
|
||||||
|
|
||||||
$str_trusted_email = hsprintf(
|
$str_trusted_email = hsprintf(
|
||||||
'<strong>%s:</strong> %s',
|
'<strong>%s:</strong> %s',
|
||||||
pht('Trust Email Addresses'),
|
pht('Trust Email Addresses'),
|
||||||
pht(
|
pht(
|
||||||
'Phabricator will skip email verification for accounts registered '.
|
'Skip email verification for accounts registered '.
|
||||||
'through this provider.'));
|
'through this provider.'));
|
||||||
$str_auto_login = hsprintf(
|
$str_auto_login = hsprintf(
|
||||||
'<strong>%s:</strong> %s',
|
'<strong>%s:</strong> %s',
|
||||||
pht('Allow Auto Login'),
|
pht('Allow Auto Login'),
|
||||||
pht(
|
pht(
|
||||||
'Phabricator will automatically login with this provider if it is '.
|
'Automatically log in with this provider if it is '.
|
||||||
'the only available provider.'));
|
'the only available provider.'));
|
||||||
|
|
||||||
$form = id(new AphrontFormView())
|
$form = id(new AphrontFormView())
|
||||||
|
|
|
@ -53,8 +53,7 @@ final class PhabricatorAuthListController
|
||||||
$list->setNoDataString(
|
$list->setNoDataString(
|
||||||
pht(
|
pht(
|
||||||
'%s You have not added authentication providers yet. Use "%s" to add '.
|
'%s You have not added authentication providers yet. Use "%s" to add '.
|
||||||
'a provider, which will let users register new Phabricator accounts '.
|
'a provider, which will let users register new accounts and log in.',
|
||||||
'and log in.',
|
|
||||||
phutil_tag(
|
phutil_tag(
|
||||||
'strong',
|
'strong',
|
||||||
array(),
|
array(),
|
||||||
|
|
|
@ -42,7 +42,7 @@ final class PhabricatorAuthProvidersGuidanceEngineExtension
|
||||||
|
|
||||||
if ($domains_value) {
|
if ($domains_value) {
|
||||||
$message = pht(
|
$message = pht(
|
||||||
'Phabricator is configured with an email domain whitelist (in %s), so '.
|
'This server is configured with an email domain whitelist (in %s), so '.
|
||||||
'only users with a verified email address at one of these %s '.
|
'only users with a verified email address at one of these %s '.
|
||||||
'allowed domain(s) will be able to register an account: %s',
|
'allowed domain(s) will be able to register an account: %s',
|
||||||
$domains_link,
|
$domains_link,
|
||||||
|
@ -53,7 +53,7 @@ final class PhabricatorAuthProvidersGuidanceEngineExtension
|
||||||
->setMessage($message);
|
->setMessage($message);
|
||||||
} else {
|
} else {
|
||||||
$message = pht(
|
$message = pht(
|
||||||
'Anyone who can browse to this Phabricator install will be able to '.
|
'Anyone who can browse to this this server will be able to '.
|
||||||
'register an account. To add email domain restrictions, configure '.
|
'register an account. To add email domain restrictions, configure '.
|
||||||
'%s.',
|
'%s.',
|
||||||
$domains_link);
|
$domains_link);
|
||||||
|
|
Loading…
Reference in a new issue