From dfcac84a69d764a5c224a58b6497f1036e222e45 Mon Sep 17 00:00:00 2001 From: epriestley Date: Tue, 24 Sep 2013 10:49:54 -0700 Subject: [PATCH] Improve some new string translations Summary: Ref T2217. Cleans up some of the "attached %d file(s)" stuff. Test Plan: Generated some of these transactions and verified they render more naturally. Reviewers: btrahan, chad Reviewed By: chad CC: aran Maniphest Tasks: T2217 Differential Revision: https://secure.phabricator.com/D7096 --- .../storage/ManiphestTransaction.php | 4 +- .../PhabricatorBaseEnglishTranslation.php | 63 +++++++++++++++++++ 2 files changed, 65 insertions(+), 2 deletions(-) diff --git a/src/applications/maniphest/storage/ManiphestTransaction.php b/src/applications/maniphest/storage/ManiphestTransaction.php index 9067c56b78..e7777333fc 100644 --- a/src/applications/maniphest/storage/ManiphestTransaction.php +++ b/src/applications/maniphest/storage/ManiphestTransaction.php @@ -308,7 +308,7 @@ final class ManiphestTransaction $this->renderHandleList($removed)); } else if ($removed && $added) { return pht( - '%s changed projects, added %d: %s; removed %d: %s', + '%s changed project(s), added %d: %s; removed %d: %s', $this->renderHandleLink($author_phid), count($added), $this->renderHandleList($added), @@ -380,7 +380,7 @@ final class ManiphestTransaction $this->renderHandleList($removed)); } else { return pht( - '%s changed projects, attached %d: %s; detached %d: %s', + '%s changed file(s), attached %d: %s; detached %d: %s', $this->renderHandleLink($author_phid), count($added), $this->renderHandleList($added), diff --git a/src/infrastructure/internationalization/PhabricatorBaseEnglishTranslation.php b/src/infrastructure/internationalization/PhabricatorBaseEnglishTranslation.php index 95bac8ab0e..509fe3c959 100644 --- a/src/infrastructure/internationalization/PhabricatorBaseEnglishTranslation.php +++ b/src/infrastructure/internationalization/PhabricatorBaseEnglishTranslation.php @@ -682,6 +682,69 @@ abstract class PhabricatorBaseEnglishTranslation '%s Commits', ), + '%s added %d project(s): %s' => array( + array( + '%s added a project: %2$s', + '%s added projects: %2$s', + ), + ), + + '%s removed %d project(s): %s' => array( + array( + '%s removed a project: %2$s', + '%s removed projects: %2$s', + ), + ), + + '%s changed project(s), added %d: %s; removed %d: %s' => + '%s changed projects, added: %3$s; removed: %5$s', + + '%s attached %d file(s): %s' => array( + array( + '%s attached a file: %3$s', + '%s attached files: %3$s', + ), + ), + + '%s detached %d file(s): %s' => array( + array( + '%s detached a file: %3$s', + '%s detached files: %3$s', + ), + ), + + '%s changed file(s), attached %d: %s; detached %d: %s' => + '%s changed files, attached: %3$s; detached: %5$s', + + + '%s added %d dependencie(s): %s.' => array( + array( + '%s added a dependency: %3$s', + '%s added a dependencies: %3$s', + ), + ), + + '%s added %d dependent task(s): %s.' => array( + array( + '%s added a dependent task: %3$s', + '%s added dependent tasks: %3$s', + ), + ), + + '%s removed %d dependencie(s): %s.' => array( + array( + '%s removed a dependency: %3$s.', + '%s removed dependencies: %3$s.', + ), + ), + + '%s removed %d dependent task(s): %s.' => array( + array( + '%s removed a dependent task: %3$s.', + '%s removed dependent tasks: %3$s.', + ), + ), + ); }