You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ponymail.apache.org by hu...@apache.org on 2021/11/03 19:10:28 UTC
[incubator-ponymail-foal] branch master updated (6941146 -> 67b2bc3)
This is an automated email from the ASF dual-hosted git repository.
humbedooh pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ponymail-foal.git.
from 6941146 check for timeouts, skip WC if it happens, rather than erroring out completely.
new 84ebe38 Add YUTC timestamp option, lint
new 67b2bc3 regen JS
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
webui/js/config.js | 9 +++++----
webui/js/ponymail.js | 22 +++++++++++++++-------
webui/js/source/base-js-extensions.js | 22 +++++++++++++++-------
3 files changed, 35 insertions(+), 18 deletions(-)
[incubator-ponymail-foal] 02/02: regen JS
Posted by hu...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ponymail-foal.git
commit 67b2bc3ab5fcd36d6d1b94b24d8e0f6ef5f8c274
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Wed Nov 3 20:09:40 2021 +0100
regen JS
---
webui/js/ponymail.js | 22 +++++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/webui/js/ponymail.js b/webui/js/ponymail.js
index cd35c6d..3bd0068 100644
--- a/webui/js/ponymail.js
+++ b/webui/js/ponymail.js
@@ -205,13 +205,21 @@ Number.prototype.pad = function(n) {
/* Func for converting a date to YYYY-MM-DD HH:MM */
-Date.prototype.ISOBare = function() {
- var M, d, h, m, y;
- y = this.getFullYear();
- m = (this.getMonth() + 1).pad(2);
- d = this.getDate().pad(2);
- h = this.getHours().pad(2);
- M = this.getMinutes().pad(2);
+Date.prototype.ISOBare = function(utc = false) {
+ let M, d, h, m, y;
+ if (prefs.UTC === true) {
+ y = this.getUTCFullYear();
+ m = (this.getUTCMonth() + 1).pad(2);
+ d = this.getUTCDate().pad(2);
+ h = this.getUTCHours().pad(2);
+ M = this.getUTCMinutes().pad(2);
+ } else {
+ y = this.getFullYear();
+ m = (this.getMonth() + 1).pad(2);
+ d = this.getDate().pad(2);
+ h = this.getHours().pad(2);
+ M = this.getMinutes().pad(2);
+ }
return y + "-" + m + "-" + d + " " + h + ":" + M;
};
[incubator-ponymail-foal] 01/02: Add YUTC timestamp option, lint
Posted by hu...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ponymail-foal.git
commit 84ebe38025ff81d4d10a63d35b843911a22fd3d7
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Wed Nov 3 20:09:32 2021 +0100
Add YUTC timestamp option, lint
---
webui/js/config.js | 9 +++++----
webui/js/source/base-js-extensions.js | 22 +++++++++++++++-------
2 files changed, 20 insertions(+), 11 deletions(-)
diff --git a/webui/js/config.js b/webui/js/config.js
index 79dce88..e0c08e4 100644
--- a/webui/js/config.js
+++ b/webui/js/config.js
@@ -62,15 +62,16 @@ var pm_config = {
// Localized preferences (defaults)
var prefs = {
- subscribeLinks: false, // Add subscribe button in stats pane?
+ subscribeLinks: false, // Add subscribe button in stats pane?
displayMode: 'threaded', // threaded or flat
groupBy: 'thread', // thread or date
sortOrder: 'forward', // forward or reverse sort
- compactQuotes: true, // Show quotes from original email as compacted blocks?
+ compactQuotes: true, // Show quotes from original email as compacted blocks?
notifications: 'direct', // Notify on direct or indirect replies to your posts?
- hideStats: 'yes', // Hide the email statistics window?
+ hideStats: 'yes', // Hide the email statistics window?
theme: 'default', // Set to 'social' to default to the social theme
- loggedIn: false
+ loggedIn: false,
+ UTC: false, // Use UTC for timestamps in UI. If false, use browser local time.
}
// array of prefs we have now. This is needed in case we change/break the existing
diff --git a/webui/js/source/base-js-extensions.js b/webui/js/source/base-js-extensions.js
index ea0fb48..20328d2 100644
--- a/webui/js/source/base-js-extensions.js
+++ b/webui/js/source/base-js-extensions.js
@@ -84,13 +84,21 @@ Number.prototype.pad = function(n) {
/* Func for converting a date to YYYY-MM-DD HH:MM */
-Date.prototype.ISOBare = function() {
- var M, d, h, m, y;
- y = this.getFullYear();
- m = (this.getMonth() + 1).pad(2);
- d = this.getDate().pad(2);
- h = this.getHours().pad(2);
- M = this.getMinutes().pad(2);
+Date.prototype.ISOBare = function(utc = false) {
+ let M, d, h, m, y;
+ if (prefs.UTC === true) {
+ y = this.getUTCFullYear();
+ m = (this.getUTCMonth() + 1).pad(2);
+ d = this.getUTCDate().pad(2);
+ h = this.getUTCHours().pad(2);
+ M = this.getUTCMinutes().pad(2);
+ } else {
+ y = this.getFullYear();
+ m = (this.getMonth() + 1).pad(2);
+ d = this.getDate().pad(2);
+ h = this.getHours().pad(2);
+ M = this.getMinutes().pad(2);
+ }
return y + "-" + m + "-" + d + " " + h + ":" + M;
};