This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
const moment = require("moment")
|
||||
|
||||
module.exports = class {
|
||||
onCreate({kind, value, updated}) {
|
||||
onCreate({kind, value, updated, utc}) {
|
||||
this.state = {text: null, color: "color-menu", tooltip: null}
|
||||
|
||||
if (value == null || value == "") {
|
||||
@@ -10,7 +10,7 @@ module.exports = class {
|
||||
|
||||
switch (kind) {
|
||||
case "date": {
|
||||
const m = moment(value)
|
||||
const m = utc ? moment.utc(value) : moment(value)
|
||||
if (m.year() < 2) {
|
||||
break
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
</div>
|
||||
<div class="meta">
|
||||
<item-meta kind="date" value=input.createdDate updated=input.updatedDate />
|
||||
<item-meta kind="date" value=input.fictionalDate />
|
||||
<item-meta kind="date" value=input.fictionalDate utc=true />
|
||||
<item-tag-list tags=input.tags enableAllTags=input.enableAllTags />
|
||||
<item-meta kind="author" value=input.author />
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user