Last modified: 2013-11-04 11:08:52 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T42885, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 40885 - Moving generating of HTML from EntityView into more modular formatters for Snaks/Claims
Moving generating of HTML from EntityView into more modular formatters for Sn...
Status: RESOLVED INVALID
Product: MediaWiki extensions
Classification: Unclassified
WikidataRepo (Other open bugs)
unspecified
All All
: High normal (vote)
: ---
Assigned To: Wikidata bugs
storypoints: 21
:
Depends on: 50578
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-09 10:51 UTC by Daniel A. R. Werner
Modified: 2013-11-04 11:08 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Daniel A. R. Werner 2012-10-09 10:51:45 UTC
Right now all HTML is generated in the EntityView classes. When we start handing around DataValue objects, we might want to create more flexible views, allowing us to render single DataValue objects instead.

This would also allow for more flexible variations of views, e.g. a statement holding a MultiLingualText would use a basic view for that data type, the label and description claims should simply be able to use a variation of that view.
Comment 1 Daniel A. R. Werner 2012-10-09 11:01:34 UTC
It could make sense to do this after Bug 40885 so these DataValue related views could just hold a definition for which template to use and feed the templates with the right data.
Comment 2 denny vrandecic 2012-10-11 10:19:58 UTC
Maybe use EntityHandler for providing the respective renderers. Change from inheritance to composition.
Comment 3 Daniel A. R. Werner 2012-12-21 11:53:52 UTC
The respective renderers are required on Snak/DataValue level, not on Entity level. To make this a little clearer, this is about the PHP EntityView, mainly generating the HTML for the non-JavaScript version.
There could be a SnakView, using a strategy pattern to display different Snak types. In case of a prperty-value Snaks, there would be renderers per DataType/DataValue. Kind of similar to what we have in JavaScript.
Comment 4 Lydia Pintscher 2013-10-19 17:33:23 UTC
What's the status here?
Comment 5 Daniel A. R. Werner 2013-10-28 13:28:24 UTC
@Lydia: This bug is a very early but still pressing description of what we are going to do in the EntityView refactoring I guess. So it is still required but could probably be merged with any other bug describing the EntityView refactoring.
Comment 6 Lydia Pintscher 2013-11-04 11:08:52 UTC
Ok thanks. Closing this one as EntityView is on the radar anyway.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links