Henning Snater has uploaded a new change for review.
https://gerrit.wikimedia.org/r/190782
Change subject: Updated entityview - itemview/propertyview relationship
......................................................................
Updated entityview - itemview/propertyview relationship
Change-Id: I592bab460c2f0474caee43a0d8bb933d9ad65bfc
---
M lib/resources/jquery.wikibase/jquery.wikibase.entityview.js
M lib/resources/jquery.wikibase/jquery.wikibase.itemview.js
M lib/resources/jquery.wikibase/jquery.wikibase.propertyview.js
3 files changed, 49 insertions(+), 23 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase
refs/changes/82/190782/1
diff --git a/lib/resources/jquery.wikibase/jquery.wikibase.entityview.js
b/lib/resources/jquery.wikibase/jquery.wikibase.entityview.js
index 33ff2e7..ee9d2c1 100644
--- a/lib/resources/jquery.wikibase/jquery.wikibase.entityview.js
+++ b/lib/resources/jquery.wikibase/jquery.wikibase.entityview.js
@@ -4,7 +4,7 @@
var PARENT = $.ui.TemplatedWidget;
/**
- * Abstract base view for displaying Wikibase `Entity`s.
+ * Abstract base view for displaying a Wikibase `Entity`.
* @class jQuery.wikibase.entityview
* @extends jQuery.ui.TemplatedWidget
* @abstract
@@ -22,17 +22,6 @@
* single language code.
* @param {wikibase.entityChangers.EntityChangersFactory}
options.entityChangersFactory
* Required to be able to store changes applied to the entity.
- * @param {wikibase.store.EntityStore} options.entityStore
- * Required by sub-components of the `entityview` to enable those to
dynamically query for
- * `Entity` objects.
- * @param {wikibase.ValueViewBuilder} options.valueViewBuilder
- * Required by the `snakview` interfacing a `snakview` "value"
`Variation` to
- * `jQuery.valueview`.
- * @param {dataTypes.DataTypeStore} options.dataTypeStore
- * Required by the `snakview` for retrieving and evaluating a proper
`dataTypes.DataType`
- * object when interacting on a "value" `Variation`.
- *
- * @throws {Error} when called.
*/
/**
* @event afterstartediting
@@ -49,7 +38,6 @@
$.widget( 'wikibase.entityview', PARENT, {
/**
* @inheritdoc
- * @property {Object}
* @protected
*/
options: {
@@ -68,32 +56,30 @@
},
value: null,
languages: null,
- entityStore: null,
- valueViewBuilder: null,
- dataTypeStore: null
+ entityChangersFactory: null
},
/**
* @property {jQuery}
- * @protected
+ * @readonly
*/
$label: null,
/**
* @property {jQuery}
- * @protected
+ * @readonly
*/
$description: null,
/**
* @property {jQuery}
- * @protected
+ * @readonly
*/
$aliases: null,
/**
* @property {jQuery|null}
- * @protected
+ * @readonly
*/
$entityTerms: null,
diff --git a/lib/resources/jquery.wikibase/jquery.wikibase.itemview.js
b/lib/resources/jquery.wikibase/jquery.wikibase.itemview.js
index 23a27b5..b398e48 100644
--- a/lib/resources/jquery.wikibase/jquery.wikibase.itemview.js
+++ b/lib/resources/jquery.wikibase/jquery.wikibase.itemview.js
@@ -17,12 +17,32 @@
* @author H. Snater < [email protected] >
*
* @constructor
+ *
+ * @param {wikibase.store.EntityStore} options.entityStore
+ * Required by sub-components of the `entityview` to enable those to
dynamically query for
+ * `Entity` objects.
+ * @param {wikibase.ValueViewBuilder} options.valueViewBuilder
+ * Required by the `snakview` interfacing a `snakview` "value"
`Variation` to
+ * `jQuery.valueview`.
+ * @param {dataTypes.DataTypeStore} options.dataTypeStore
+ * Required by the `snakview` for retrieving and evaluating a proper
`dataTypes.DataType`
+ * object when interacting on a "value" `Variation`.
*/
$.widget( 'wikibase.itemview', PARENT, {
/**
- * @property {jQuery}
+ * @inheritdoc
* @protected
*/
+ options: {
+ entityStore: null,
+ valueViewBuilder: null,
+ dataTypeStore: null
+ },
+
+ /**
+ * @property {jQuery}
+ * @readonly
+ */
$statements: null,
/**
diff --git a/lib/resources/jquery.wikibase/jquery.wikibase.propertyview.js
b/lib/resources/jquery.wikibase/jquery.wikibase.propertyview.js
index 95f0595..2df4fdf 100644
--- a/lib/resources/jquery.wikibase/jquery.wikibase.propertyview.js
+++ b/lib/resources/jquery.wikibase/jquery.wikibase.propertyview.js
@@ -16,17 +16,37 @@
* @author H. Snater < [email protected] >
*
* @constructor
+ *
+ * @param {wikibase.store.EntityStore} options.entityStore
+ * Required by sub-components of the `entityview` to enable those to
dynamically query for
+ * `Entity` objects.
+ * @param {wikibase.ValueViewBuilder} options.valueViewBuilder
+ * Required by the `snakview` interfacing a `snakview` "value"
`Variation` to
+ * `jQuery.valueview`.
+ * @param {dataTypes.DataTypeStore} options.dataTypeStore
+ * Required by the `snakview` for retrieving and evaluating a proper
`dataTypes.DataType`
+ * object when interacting on a "value" `Variation`.
*/
$.widget( 'wikibase.propertyview', PARENT, {
/**
- * @property {jQuery}
+ * @inheritdoc
* @protected
+ */
+ options: {
+ entityStore: null,
+ valueViewBuilder: null,
+ dataTypeStore: null
+ },
+
+ /**
+ * @property {jQuery}
+ * @readonly
*/
$dataType: null,
/**
* @property {jQuery}
- * @protected
+ * @readonly
*/
$statements: null,
--
To view, visit https://gerrit.wikimedia.org/r/190782
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I592bab460c2f0474caee43a0d8bb933d9ad65bfc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Henning Snater <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits