Skip to content

Commit 34374a3

Browse files
committed
Update sign_msg message & make compose_delivery_receipt checked by default
1 parent cff3381 commit 34374a3

File tree

5 files changed

+9
-10
lines changed

5 files changed

+9
-10
lines changed

language/az.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@
411411
'Added SMTP server!' => 'SMTP server əlavə edilmişdir!',
412412
'Added repository' => 'Anbar əlavə edilmişdir',
413413
'Added server!' => 'Server əlavə edilmişdir',
414-
'Are you sure you wanto to delete this server? ' => 'Siz əminsiniz?',
414+
'Are you sure you want to delete this server?' => 'Siz əminsiniz?',
415415
'Could not find that repository/owner combination at github.com' => 'Github.com-da kombinasiya anbar/sahib tapılmamışdır',
416416
'Disable prompts when deleting' => 'Silinmə vaxtı sorğunu kəsmək',
417417
'Enable keyboard shortcuts' => 'Qaynar klavişləri qoşmaq',

modules/core/message_list_functions.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,14 +120,13 @@ function message_list_meta($input, $output_mod) {
120120
$since = DEFAULT_SINCE;
121121
}
122122
$date = sprintf('%s', mb_strtolower($output_mod->trans($times[$since])));
123-
$max = sprintf($output_mod->trans('sources@%d each'), $limit);
123+
$max = sprintf($output_mod->trans('%d items per source'), $limit);
124124

125125
return '<div class="list_meta d-flex align-items-center fs-6">'.
126126
$date.
127-
'<b>-</b>'.
127+
'<b> :</b>'.
128128
'<span class="src_count"></span> '.$max.
129-
'<b>-</b>'.
130-
'<span class="total"></span> '.$output_mod->trans('total').'</div>';
129+
'</div>';
131130
}}
132131

133132
/**

modules/profiles/modules.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ protected function output() {
213213
*/
214214
class Hm_Output_compose_signature_button extends Hm_Output_Module {
215215
protected function output() {
216-
return '<input type="hidden" value="'.$this->trans('You need at least one configured profile to sign messages').'" id="sign_msg" />'.
216+
return '<input type="hidden" value="'.$this->trans('You need at least one profile with a signature to sign messages. Please configure a signature in your profile settings.').'" id="sign_msg" />'.
217217
'<input class="compose_sign btn btn-light float-end mt-3 me-2 border" type="button" value="'.$this->trans('Sign').'" />';
218218
}
219219
}

modules/smtp/modules.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1193,7 +1193,7 @@ protected function output() {
11931193
(!$html ? '<label for="compose_body">'.$this->trans('Message').'</label>': '').
11941194
'</div>';
11951195
if($this->get('enable_compose_delivery_receipt_setting')) {
1196-
$res .= '<div class="form-check mb-3"><input value="0" name="compose_delivery_receipt" id="compose_delivery_receipt" type="checkbox" class="form-check-input" /><label for="compose_delivery_receipt" class="form-check-label">'.$this->trans('Request a delivery receipt').'</label></div>';
1196+
$res .= '<div class="form-check mb-3"><input value="1" name="compose_delivery_receipt" id="compose_delivery_receipt" type="checkbox" class="form-check-input" checked/><label for="compose_delivery_receipt" class="form-check-label">'.$this->trans('Request a delivery receipt').'</label></div>';
11971197
}
11981198
if ($html == 2) {
11991199
$res .= '<link href="'.WEB_ROOT.'modules/smtp/assets/markdown/editor.css" rel="stylesheet" />'.

tests/phpunit/modules/core/message_list_functions.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ public function test_get_message_list_settings() {
2929
public function test_get_message_list_meta() {
3030
$mod = new Hm_Output_Test(array('foo' => 'bar', 'bar' => 'foo'), array('bar'));
3131
$this->assertEquals('', message_list_meta(array(), $mod));
32-
$this->assertEquals('<div class="list_meta d-flex align-items-center fs-6">last 7 days<b>-</b><span class="src_count"></span> sources@20 each<b>-</b><span class="total"></span> total</div>', message_list_meta(array('list_meta' => 'foo', 'message_list_since' => '-1 week'), $mod));
33-
$this->assertEquals('<div class="list_meta d-flex align-items-center fs-6">last 7 days<b>-</b><span class="src_count"></span> sources@5 each<b>-</b><span class="total"></span> total</div>', message_list_meta(array('list_meta' => 'foo', 'per_source_limit' => 5), $mod));
34-
$this->assertEquals('<div class="list_meta d-flex align-items-center fs-6">last 7 days<b>-</b><span class="src_count"></span> sources@5 each<b>-</b><span class="total"></span> total</div>', message_list_meta(array('list_meta' => 'foo', 'per_source_limit' => 5, 'message_list_since' => '-1 week'), $mod));
32+
$this->assertEquals('<div class="list_meta fs-6">last 7 days<b> :</b><span class="src_count"></span> 20 items per source</div>', message_list_meta(array('list_meta' => 'foo', 'message_list_since' => '-1 week'), $mod));
33+
$this->assertEquals('<div class="list_meta fs-6">last 7 days<b> :</b><span class="src_count"></span> 5 items per source</div>', message_list_meta(array('list_meta' => 'foo', 'per_source_limit' => 5), $mod));
34+
$this->assertEquals('<div class="list_meta fs-6">last 7 days<b> :</b><span class="src_count"></span> 5 items per source</div>', message_list_meta(array('list_meta' => 'foo', 'per_source_limit' => 5, 'message_list_since' => '-1 week'), $mod));
3535
}
3636
/**
3737
* @preserveGlobalState disabled

0 commit comments

Comments
 (0)