From 65213b1ffab431d613cd4573f7fe2b70b03c3d84 Mon Sep 17 00:00:00 2001 From: Daniel B Date: Wed, 14 Jul 2021 15:35:05 -0500 Subject: [PATCH] 2021.07.14.01 --- WME-URComments-Enhanced.js | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/WME-URComments-Enhanced.js b/WME-URComments-Enhanced.js index 0cdcc27..e5eabbc 100644 --- a/WME-URComments-Enhanced.js +++ b/WME-URComments-Enhanced.js @@ -1,7 +1,7 @@ // ==UserScript== // @name WME URComments-Enhanced (beta) // @namespace https://greasyfork.org/users/166843 -// @version 2020.09.09.01 +// @version 2021.07.14.01 // eslint-disable-next-line max-len // @description URComments-Enhanced (URC-E) allows Waze editors to handle WME update requests more quickly and efficiently. Also adds many UR filtering options, ability to change the markers, plus much, much, more! // @grant none @@ -38,19 +38,7 @@ const SCRIPT_NAME = `URC-E${((GM_info.script.name.search(/beta/) > -1) ? ' β' : SETTINGS_STORE_NAME = 'WME_URC-E', ALERT_UPDATE = true, SCRIPT_VERSION = GM_info.script.version, - SCRIPT_VERSION_CHANGES = ['NEW: Setting to auto zoom out after closing UR panel.', - 'NEW: Shortcut to insert permalink to UR.', - 'NEW: Spreadsheet shortcut of "$PERMALINK$" to insert permalink to UR.', - 'CHANGE: Faster load time.', - 'CHANGE: Far less script execution awaits, letting script run more synchronously.', - 'CHANGE: Style compatibility with WME v2.62-35-g266443036.', - 'BUGFIX: Permalink shortcut icon not working correctly. (2020.09.09.01)', - 'BUGFIX: Side panel alignments in certain situations. (2020.09.09.01)', - 'BUGFIX: Script style setting not correctly showing in settings.', - 'BUGFIX: Better error handling.', - 'BUGFIX: WazeWrap stored settings not applied in some cases.', - 'BUGFIX: Multiple event listeners in certain situations.', - 'BUGFIX: Width of UR panel not wide enough for text (native WME issue).'], + SCRIPT_VERSION_CHANGES = ['BUGFIX: Fix for WME changes - missing day names.'], DOUBLE_CLICK_ICON = 'data:image/png;base64,iVBORw0KGgoAAAANSUhE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XIXjGKLA52vYpSB7ZIHaAJbHDRN28HTaZGiMvha5B55NDs7S7EEcNmcwygHKESEfyeBOOXSMDg46OKVc5uiciAVxaxxUx6gvDFAhJOn0wiBv1FVDirJxn3Ns3s35Y0Hz+wWZmOUozXHe0D8xfrJgEvwPdf23WAwmO7p6fEazW3C4fgNPVAixOZacokAAAAASUVORK5CYII=', DEBUG = true, LOAD_BEGIN_TIME = performance.now(), @@ -4785,6 +4773,15 @@ function loadTranslations() { return new Promise((resolve, reject) => { logDebug('Loading translations.'); let errorText; + /* FIX FOR WME MISSING DAY NAMES 2021.07.13 - snhroc */ + if (!I18n.translations[I18n.locale].date.day_names) { + I18n.translations[I18n.locale].date.day_names = []; + Object.entries(I18n.translations[I18n.locale].date).forEach(([k, v]) => { + if (k.indexOf('day_names_') === 0) + I18n.translations[I18n.locale].date.day_names.push(v); + }); + } + /* END FIX */ $.getJSON(`https://sheets.googleapis.com/v4/spreadsheets/${URCE_SPREADSHEET_ID}/values/Script_Translations!A3:AA?key=${URCE_API_KEY}`, data => { const translationLocales = []; let translations = {};