aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/main.js
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2018-10-13 14:11:08 +0200
committerMario Vavti <mario@mariovavti.com>2018-10-13 14:11:08 +0200
commitf0cdbd0f520d14f3840caf41856f56133e9c3970 (patch)
treeea6bf0ca2a5a878f0156286a928c70c427958e76 /view/js/main.js
parent321b2b9b49e7c4412906e56ffdcc1be4bf8441be (diff)
parent9632cafa95e76a53460e761385a3376f14881eae (diff)
downloadvolse-hubzilla-f0cdbd0f520d14f3840caf41856f56133e9c3970.tar.gz
volse-hubzilla-f0cdbd0f520d14f3840caf41856f56133e9c3970.tar.bz2
volse-hubzilla-f0cdbd0f520d14f3840caf41856f56133e9c3970.zip
Merge branch 'dev' into 3.8RC
Diffstat (limited to 'view/js/main.js')
-rw-r--r--view/js/main.js41
1 files changed, 22 insertions, 19 deletions
diff --git a/view/js/main.js b/view/js/main.js
index 48277f5cc..3e81ba0e4 100644
--- a/view/js/main.js
+++ b/view/js/main.js
@@ -44,25 +44,28 @@ $(document).ready(function() {
$(document).on('click', '.conversation-settings-link', getConversationSettings);
$(document).on('click', '#settings_module_ajax_submit', postConversationSettings);
- jQuery.timeago.settings.strings = {
- prefixAgo : aStr['t01'],
- prefixFromNow : aStr['t02'],
- suffixAgo : aStr['t03'],
- suffixFromNow : aStr['t04'],
- seconds : aStr['t05'],
- minute : aStr['t06'],
- minutes : aStr['t07'],
- hour : aStr['t08'],
- hours : aStr['t09'],
- day : aStr['t10'],
- days : aStr['t11'],
- month : aStr['t12'],
- months : aStr['t13'],
- year : aStr['t14'],
- years : aStr['t15'],
- wordSeparator : aStr['t16'],
- numbers : aStr['t17'],
- };
+ var tf = new Function('n', aStr['plural_func']);
+
+ jQuery.timeago.settings.strings = {
+ prefixAgo : aStr['t01'],
+ prefixFromNow : aStr['t02'],
+ suffixAgo : aStr['t03'],
+ suffixFromNow : aStr['t04'],
+ seconds : aStr['t05'],
+ minute : aStr['t06'],
+ minutes : function(value){return aStr['t07'].split("/")[tf(value)];},
+ hour : aStr['t08'],
+ hours : function(value){return aStr['t09'].split("/")[tf(value)];},
+ day : aStr['t10'],
+ days : function(value){return aStr['t11'].split("/")[tf(value)];},
+ month : aStr['t12'],
+ months : function(value){return aStr['t13'].split("/")[tf(value)];},
+ year : aStr['t14'],
+ years : function(value){return aStr['t15'].split("/")[tf(value)];},
+ wordSeparator : aStr['t16'],
+ numbers : aStr['t17'],
+ };
+
//mod_mail only
$(".mail-conv-detail .autotime").timeago();