Skip to content

Commit f1245f4

Browse files
author
epriestley
committedApr 19, 2014
Remove flavor text for action buttons
Summary: A small but appreciable number of users find flavor on buttons confusing. Remove this flavor. This retains flavor in headers, error messages, etc., which doesn't cause confusion. Test Plan: Looked at a revision, task, paste, macro, etc. Reviewers: chad, btrahan Reviewed By: btrahan Subscribers: epriestley Differential Revision: https://secure.phabricator.com/D8812
1 parent ba95671 commit f1245f4

File tree

15 files changed

+27
-81
lines changed

15 files changed

+27
-81
lines changed
 

‎conf/default.conf.php

-7
Original file line numberDiff line numberDiff line change
@@ -638,13 +638,6 @@
638638
'https' => true,
639639
),
640640

641-
// By default, Phabricator includes some silly nonsense in the UI, such as
642-
// a submit button called "Clowncopterize" in Differential and a call to
643-
// "Leap Into Action". If you'd prefer more traditional UI strings like
644-
// "Submit", you can set this flag to disable most of the jokes and easter
645-
// eggs.
646-
'phabricator.serious-business' => false,
647-
648641
// Should Phabricator show beta applications on the homepage
649642
'phabricator.show-beta-applications' => false,
650643

‎src/aphront/configuration/AphrontDefaultApplicationConfiguration.php

+2-4
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,6 @@ public function handleException(Exception $ex) {
103103
return $response;
104104
}
105105

106-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
107-
108106
$user = $request->getUser();
109107
if (!$user) {
110108
// If we hit an exception very early, we won't have a user.
@@ -175,9 +173,9 @@ public function handleException(Exception $ex) {
175173
->appendChild($content);
176174

177175
if ($this->getRequest()->isAjax()) {
178-
$dialog->addCancelButton('/', 'Close');
176+
$dialog->addCancelButton('/', pht('Close'));
179177
} else {
180-
$dialog->addCancelButton('/', $is_serious ? 'OK' : 'Away With Thee');
178+
$dialog->addCancelButton('/', pht('OK'));
181179
}
182180

183181
$response = new AphrontDialogResponse();

‎src/applications/config/option/PhabricatorCoreConfigOptions.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -112,11 +112,11 @@ public function getOptions() {
112112
pht("Should Phabricator be serious?"))
113113
->setDescription(
114114
pht(
115-
"By default, Phabricator includes some silly nonsense in the UI, ".
116-
"such as a submit button called 'Clowncopterize' in Differential ".
117-
"and a call to 'Leap Into Action'. If you'd prefer more ".
118-
"traditional UI strings like 'Submit', you can set this flag to ".
119-
"disable most of the jokes and easter eggs.")),
115+
'By default, Phabricator includes some flavor text in the UI, '.
116+
'like a prompt to "Weigh In" rather than "Add Comment" in '.
117+
'Maniphest. If you\'d prefer more traditional UI strings like '.
118+
'"Add Comment", you can set this flag to disable most of the '.
119+
'extra flavor.')),
120120
$this->newOption('environment.append-paths', 'list<string>', $paths)
121121
->setSummary(
122122
pht("These paths get appended to your \$PATH envrionment variable."))

‎src/applications/conpherence/controller/ConpherenceViewController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@ private function renderFormContent($latest_transaction_id) {
133133
$update_uri = $this->getApplicationURI('update/'.$conpherence->getID().'/');
134134

135135
$this->initBehavior('conpherence-pontificate');
136-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
137136

138137
$form =
139138
id(new AphrontFormView())
@@ -149,10 +148,7 @@ private function renderFormContent($latest_transaction_id) {
149148
->setValue($draft->getDraft()))
150149
->appendChild(
151150
id(new AphrontFormSubmitControl())
152-
->setValue(
153-
$is_serious
154-
? pht('Send')
155-
: pht('Pontificate')))
151+
->setValue(pht('Send Message')))
156152
->appendChild(
157153
javelin_tag(
158154
'input',

‎src/applications/differential/view/DifferentialAddCommentView.php

+7-5
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,6 @@ public function setCCs(array $names) {
5252
public function render() {
5353

5454
$this->requireResource('differential-revision-add-comment-css');
55-
56-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
57-
5855
$revision = $this->revision;
5956

6057
$action = null;
@@ -109,7 +106,7 @@ public function render() {
109106
->setUser($this->user))
110107
->appendChild(
111108
id(new AphrontFormSubmitControl())
112-
->setValue($is_serious ? pht('Submit') : pht('Clowncopterize')));
109+
->setValue(pht('Submit')));
113110

114111
Javelin::initBehavior(
115112
'differential-add-reviewers-and-ccs',
@@ -157,8 +154,13 @@ public function render() {
157154
'inline' => 'inline-comment-preview',
158155
));
159156

157+
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
158+
$header_text = $is_serious
159+
? pht('Add Comment')
160+
: pht('Leap Into Action');
161+
160162
$header = id(new PHUIHeaderView())
161-
->setHeader($is_serious ? pht('Add Comment') : pht('Leap Into Action'));
163+
->setHeader($header_text);
162164

163165
$anchor = id(new PhabricatorAnchorView())
164166
->setAnchorName('comment')

‎src/applications/diffusion/controller/DiffusionCommitController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -764,7 +764,7 @@ private function renderAddCommentPanel(
764764
->setUser($user))
765765
->appendChild(
766766
id(new AphrontFormSubmitControl())
767-
->setValue($is_serious ? pht('Submit') : pht('Cook the Books')));
767+
->setValue(pht('Submit')));
768768

769769
$header = new PHUIHeaderView();
770770
$header->setHeader(

‎src/applications/files/controller/PhabricatorFileInfoController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,6 @@ private function buildTransactionView(
9999
? pht('Add Comment')
100100
: pht('Question File Integrity');
101101

102-
$submit_button_name = $is_serious
103-
? pht('Add Comment')
104-
: pht('Debate the Bits');
105-
106102
$draft = PhabricatorDraft::newFromUserAndKey($user, $file->getPHID());
107103

108104
$add_comment_form = id(new PhabricatorApplicationTransactionCommentView())
@@ -111,7 +107,7 @@ private function buildTransactionView(
111107
->setDraft($draft)
112108
->setHeaderText($add_comment_header)
113109
->setAction($this->getApplicationURI('/comment/'.$file->getID().'/'))
114-
->setSubmitButtonName($submit_button_name);
110+
->setSubmitButtonName(pht('Add Comment'));
115111

116112
return array(
117113
$timeline,

‎src/applications/legalpad/controller/LegalpadDocumentViewController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -210,17 +210,13 @@ private function buildAddCommentView(
210210
? pht('Add Comment')
211211
: pht('Debate Legislation');
212212

213-
$button_name = $is_serious
214-
? pht('Add Comment')
215-
: pht('Commence Filibuster');
216-
217213
$form = id(new PhabricatorApplicationTransactionCommentView())
218214
->setUser($user)
219215
->setObjectPHID($document->getPHID())
220216
->setFormID($comment_form_id)
221217
->setHeaderText($title)
222218
->setDraft($draft)
223-
->setSubmitButtonName($button_name)
219+
->setSubmitButtonName(pht('Add Comment'))
224220
->setAction($this->getApplicationURI('/comment/'.$document->getID().'/'))
225221
->setRequestURI($this->getRequest()->getRequestURI());
226222

‎src/applications/macro/controller/PhabricatorMacroViewController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,6 @@ public function processRequest() {
8787
? pht('Add Comment')
8888
: pht('Grovel in Awe');
8989

90-
$submit_button_name = $is_serious
91-
? pht('Add Comment')
92-
: pht('Lavish Praise');
93-
9490
$draft = PhabricatorDraft::newFromUserAndKey($user, $macro->getPHID());
9591

9692
$add_comment_form = id(new PhabricatorApplicationTransactionCommentView())
@@ -99,7 +95,7 @@ public function processRequest() {
9995
->setDraft($draft)
10096
->setHeaderText($comment_header)
10197
->setAction($this->getApplicationURI('/comment/'.$macro->getID().'/'))
102-
->setSubmitButtonName($submit_button_name);
98+
->setSubmitButtonName(pht('Add Comment'));
10399

104100
$object_box = id(new PHUIObjectBoxView())
105101
->setHeader($header)

‎src/applications/maniphest/controller/ManiphestTaskDetailController.php

+3-12
Original file line numberDiff line numberDiff line change
@@ -205,16 +205,6 @@ public function processRequest() {
205205
$draft_text = null;
206206
}
207207

208-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
209-
210-
$submit_text = $is_serious
211-
? pht('Submit')
212-
: pht('Avast!');
213-
214-
$close_text = $is_serious
215-
? pht('Close Task')
216-
: pht('Scuttle Task');
217-
218208
$submit_control = id(new PHUIFormMultiSubmitControl());
219209
if (!$task->isClosed()) {
220210
$close_image = id(new PHUIIconView())
@@ -224,11 +214,11 @@ public function processRequest() {
224214
id(new PHUIButtonView())
225215
->setColor(PHUIButtonView::GREY)
226216
->setIcon($close_image)
227-
->setText($close_text)
217+
->setText(pht('Close Task'))
228218
->setName('scuttle')
229219
->addSigil('alternate-submit-button'));
230220
}
231-
$submit_control->addSubmitButton($submit_text);
221+
$submit_control->addSubmitButton(pht('Submit'));
232222

233223
$comment_form = new AphrontFormView();
234224
$comment_form
@@ -343,6 +333,7 @@ public function processRequest() {
343333
));
344334
}
345335

336+
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
346337
$comment_header = $is_serious
347338
? pht('Add Comment')
348339
: pht('Weigh In');

‎src/applications/paste/controller/PhabricatorPasteViewController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -118,10 +118,6 @@ public function processRequest() {
118118
? pht('Add Comment')
119119
: pht('Debate Paste Accuracy');
120120

121-
$submit_button_name = $is_serious
122-
? pht('Add Comment')
123-
: pht('Pity the Fool');
124-
125121
$draft = PhabricatorDraft::newFromUserAndKey($user, $paste->getPHID());
126122

127123
$add_comment_form = id(new PhabricatorApplicationTransactionCommentView())
@@ -130,7 +126,7 @@ public function processRequest() {
130126
->setDraft($draft)
131127
->setHeaderText($add_comment_header)
132128
->setAction($this->getApplicationURI('/comment/'.$paste->getID().'/'))
133-
->setSubmitButtonName($submit_button_name);
129+
->setSubmitButtonName(pht('Add Comment'));
134130

135131
return $this->buildApplicationPage(
136132
array(

‎src/applications/pholio/controller/PholioMockViewController.php

+1-6
Original file line numberDiff line numberDiff line change
@@ -235,22 +235,17 @@ private function buildAddCommentView(PholioMock $mock, $comment_form_id) {
235235
$draft = PhabricatorDraft::newFromUserAndKey($user, $mock->getPHID());
236236

237237
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
238-
239238
$title = $is_serious
240239
? pht('Add Comment')
241240
: pht('History Beckons');
242241

243-
$button_name = $is_serious
244-
? pht('Add Comment')
245-
: pht('Answer The Call');
246-
247242
$form = id(new PhabricatorApplicationTransactionCommentView())
248243
->setUser($user)
249244
->setObjectPHID($mock->getPHID())
250245
->setFormID($comment_form_id)
251246
->setDraft($draft)
252247
->setHeaderText($title)
253-
->setSubmitButtonName($button_name)
248+
->setSubmitButtonName(pht('Add Comment'))
254249
->setAction($this->getApplicationURI('/comment/'.$mock->getID().'/'))
255250
->setRequestURI($this->getRequest()->getRequestURI());
256251

‎src/applications/phriction/controller/PhrictionMoveController.php

+1-6
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ public function willProcessRequest(array $data) {
1515
public function processRequest() {
1616
$request = $this->getRequest();
1717
$user = $request->getUser();
18-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
1918

2019
if ($this->id) {
2120
$document = id(new PhrictionDocument())->load($this->id);
@@ -114,9 +113,6 @@ public function processRequest() {
114113
->setErrors($errors);
115114
}
116115

117-
$descr_caption = $is_serious ? pht('A reason for the move.') :
118-
pht('You better give a good reason for this.');
119-
120116
$form = id(new PHUIFormLayoutView())
121117
->setUser($user)
122118
->appendChild(
@@ -135,8 +131,7 @@ public function processRequest() {
135131
->setLabel(pht('Edit Notes'))
136132
->setValue($content->getDescription())
137133
->setError(null)
138-
->setName('description')
139-
->setCaption($descr_caption));
134+
->setName('description'));
140135

141136
$dialog = id(new AphrontDialogView())
142137
->setUser($user)

‎src/applications/ponder/view/PonderAddAnswerView.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ public function setActionURI($uri) {
1717
}
1818

1919
public function render() {
20-
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
21-
2220
$question = $this->question;
2321

2422
$header = id(new PHUIHeaderView())
@@ -39,9 +37,7 @@ public function render() {
3937
->setUser($this->user))
4038
->appendChild(
4139
id(new AphrontFormSubmitControl())
42-
->setValue($is_serious ?
43-
pht('Add Answer') :
44-
pht('Bequeath Wisdom')));
40+
->setValue(pht('Add Answer')));
4541

4642
return id(new PHUIObjectBoxView())
4743
->setHeader($header)

‎src/applications/slowvote/controller/PhabricatorSlowvotePollController.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -164,10 +164,6 @@ private function buildCommentForm(PhabricatorSlowvotePoll $poll) {
164164
? pht('Add Comment')
165165
: pht('Enter Deliberations');
166166

167-
$submit_button_name = $is_serious
168-
? pht('Add Comment')
169-
: pht('Perhaps');
170-
171167
$draft = PhabricatorDraft::newFromUserAndKey($viewer, $poll->getPHID());
172168

173169
return id(new PhabricatorApplicationTransactionCommentView())
@@ -176,7 +172,7 @@ private function buildCommentForm(PhabricatorSlowvotePoll $poll) {
176172
->setDraft($draft)
177173
->setHeaderText($add_comment_header)
178174
->setAction($this->getApplicationURI('/comment/'.$poll->getID().'/'))
179-
->setSubmitButtonName($submit_button_name);
175+
->setSubmitButtonName(pht('Add Comment'));
180176

181177
}
182178

0 commit comments

Comments
 (0)
Failed to load comments.