WMDE-leszek has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/385432 )

Change subject: Do not use messages from View-specific dependency in 
HtmlTimeFormatter
......................................................................

Do not use messages from View-specific dependency in HtmlTimeFormatter

valueview-expert-timevalue-calendar-gregorian/julian messages
are defined in data value view values JS library, which is
a dependency of the View component.
In principle, these are not known to the Lib component, as
it is meant to be independent from View component.
Classes in the Lib component should hence only use messages
which are known inside of this component.

Change-Id: I4c893a1ee8f7c9bbe2c962636a16f865757f05f9
---
M lib/i18n/en.json
M lib/i18n/qqq.json
M lib/includes/Formatters/HtmlTimeFormatter.php
3 files changed, 6 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/32/385432/1

diff --git a/lib/i18n/en.json b/lib/i18n/en.json
index f284db5..1e10275 100644
--- a/lib/i18n/en.json
+++ b/lib/i18n/en.json
@@ -77,6 +77,8 @@
        "datatypes-type-tabular-data": "Tabular data",
        "datatypes-type-external-id": "External identifier",
        "version-wikibase": "Wikibase",
+       "wikibase-time-calendar-gregorian": "Gregorian",
+       "wikibase-time-calendar-julian": "Julian",
        "wikibase-time-precision-Gannum": "$1 billion years CE",
        "wikibase-time-precision-Mannum": "$1 million years CE",
        "wikibase-time-precision-annum": "{{PLURAL:$1|$1 year|$1 years}} CE",
diff --git a/lib/i18n/qqq.json b/lib/i18n/qqq.json
index b16efe5..9797653 100644
--- a/lib/i18n/qqq.json
+++ b/lib/i18n/qqq.json
@@ -88,6 +88,8 @@
        "datatypes-type-tabular-data": "The name of a data type for 
tabular-data\n{{Identical|Tabular data}}",
        "datatypes-type-external-id": "The name of a data type for external 
identifiers in Wikibase.",
        "version-wikibase": "Name of the Wikibase extension collection, used on 
[[Special:Version]]",
+       "wikibase-time-calendar-gregorian": "Label displayed with the formatted 
dates referring to the Gregorian calendar model.\n{{Identical|Gregorian}}",
+       "wikibase-time-calendar-julian": "Label displayed with the formatted 
dates referring to the Julian calendar model.\n{{Identical|Julian}}",
        "wikibase-time-precision-Gannum": "Used to present a point in time with 
the precession of 1 billion of years. $1 is the point in time in billion years, 
rounded to billion years.\n{{Related|Wikibase-time-precision}}",
        "wikibase-time-precision-Mannum": "Used to present a point in time with 
the precession of 1 million of years. $1 is the point in time in million years, 
rounded to million years.\n{{Related|Wikibase-time-precision}}",
        "wikibase-time-precision-annum": "Used to present a point in time with 
the precession of 10000 years to 100000 years. $1 is the point in time in 
years, rounded to 10000 or 100000 years.\n{{Related|Wikibase-time-precision}}",
diff --git a/lib/includes/Formatters/HtmlTimeFormatter.php 
b/lib/includes/Formatters/HtmlTimeFormatter.php
index c5129fc..5d2b891 100644
--- a/lib/includes/Formatters/HtmlTimeFormatter.php
+++ b/lib/includes/Formatters/HtmlTimeFormatter.php
@@ -25,8 +25,8 @@
 class HtmlTimeFormatter extends ValueFormatterBase {
 
        private static $calendarKeys = [
-               TimeValue::CALENDAR_GREGORIAN => 
'valueview-expert-timevalue-calendar-gregorian',
-               TimeValue::CALENDAR_JULIAN => 
'valueview-expert-timevalue-calendar-julian',
+               TimeValue::CALENDAR_GREGORIAN => 
'wikibase-time-calendar-gregorian',
+               TimeValue::CALENDAR_JULIAN => 'wikibase-time-calendar-julian',
        ];
 
        /**

-- 
To view, visit https://gerrit.wikimedia.org/r/385432
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4c893a1ee8f7c9bbe2c962636a16f865757f05f9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: WMDE-leszek <leszek.mani...@wikimedia.de>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to