From 34c067c3be9fcabe0e9ecd57d36159bcdfd15ab3 Mon Sep 17 00:00:00 2001 From: tophf Date: Thu, 28 Jan 2021 15:41:53 +0300 Subject: [PATCH] hide USO-archive version in manager * it's a hard-to-read blob of digits: 2021110.8.46 * it's somewhat redundant as we have the 'update age' column --- manage/manage.css | 1 + manage/render.js | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/manage/manage.css b/manage/manage.css index b7d6674a..6a4afa3c 100644 --- a/manage/manage.css +++ b/manage/manage.css @@ -361,6 +361,7 @@ a:hover { padding-left: .5em; font-weight: normal; } +.newUI .style-info[data-type=version][data-is-date], .newUI .style-info[data-type=version][data-value=""], .newUI .style-info[data-type=version][data-value="1.0.0"] { display: none; diff --git a/manage/render.js b/manage/render.js index e2da59bd..cc0afb6d 100644 --- a/manage/render.js +++ b/manage/render.js @@ -1,6 +1,6 @@ /* global $ $$ animateElement scrollElementIntoView */// dom.js /* global API */// msg.js -/* global debounce isEmptyObj sessionStore */// toolbox.js +/* global URLS debounce isEmptyObj sessionStore */// toolbox.js /* global filterAndAppend */// filters.js /* global installed newUI */// manage.js /* global prefs */ @@ -83,6 +83,11 @@ function createStyleElement({style, name: nameLC}) { parts.homepage.href = parts.homepage.title = style.url || ''; parts.infoVer.textContent = ud ? ud.version : ''; parts.infoVer.dataset.value = ud ? ud.version : ''; + if (`${style.updateUrl}`.startsWith(URLS.usoArchiveRaw)) { + parts.infoVer.dataset.isDate = ''; + } else { + delete parts.infoVer.dataset.isDate; + } if (newUI.enabled) { createAgeText(parts.infoAge, style); } else {