Commit 6a35cd6c authored by Jérome Perrin's avatar Jérome Perrin

officejs_support_request_ui: update the relative times of posts periodically

otherwise the test stays on "a few seconds ago" and this becomes "wrong
information", unlike an absolute date with stays correct.
parent e74504d0
......@@ -257,6 +257,14 @@
return queue;
});
})
.onLoop(function () {
// update relative time
this.element.querySelectorAll("li>time").forEach(
function (element) {
element.textContent = moment(element.getAttribute('datetime')).fromNow();
}
);
}, 5000)
.onEvent('submit', function () {
this.submitPostComment();
});
......
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1539140577.69</float>
<float>1539939405.65</float>
<string>GMT+9</string>
</tuple>
</state>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment