From b2759f3510835e158157f7ce49f66d5d87112f5a Mon Sep 17 00:00:00 2001 From: Kyuho Lee Date: Mon, 15 Jun 2020 18:04:21 +0900 Subject: [PATCH] Add more style in version comparision --- module/scripts/modules2ko.js | 1 + module/templates/modules2ko-config.html | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/module/scripts/modules2ko.js b/module/scripts/modules2ko.js index f5303f2..e2b812d 100644 --- a/module/scripts/modules2ko.js +++ b/module/scripts/modules2ko.js @@ -18,6 +18,7 @@ class Modules2ko { moduleVersion: module.data.version, translationVersion: info.version, isOutdated: isNewerVersion(module.data.version, info.version), + isPredated: isNewerVersion(info.version, module.data.version), active: active }); } diff --git a/module/templates/modules2ko-config.html b/module/templates/modules2ko-config.html index d32710e..1914c21 100644 --- a/module/templates/modules2ko-config.html +++ b/module/templates/modules2ko-config.html @@ -14,9 +14,11 @@

{{this.title}}

{{#if this.isOutdated }} - {{localize "modules2ko.module-version"}} {{ this.moduleVersion }} | {{localize "modules2ko.translated-version"}} {{ this.translationVersion }} + {{localize "modules2ko.module-version"}} {{ this.moduleVersion }} > {{localize "modules2ko.translated-version"}} {{ this.translationVersion }} + {{else if this.isPredated}} + {{localize "modules2ko.module-version"}} {{ this.moduleVersion }} < {{localize "modules2ko.translated-version"}} {{ this.translationVersion }} {{else}} - {{localize "modules2ko.module-version"}} {{ this.moduleVersion }} | {{localize "modules2ko.translated-version"}} {{ this.translationVersion }} + {{localize "modules2ko.module-version"}} {{ this.moduleVersion }} = {{localize "modules2ko.translated-version"}} {{ this.translationVersion }} {{/if}}