mirror of
https://github.com/Universal-Omega/PortableInfobox.git
synced 2024-11-15 11:59:56 +00:00
VE-1960: Template for mobile image collections
This commit is contained in:
parent
c9da5425a7
commit
d097426242
|
@ -84,7 +84,6 @@ class NodeImage extends Node {
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getTabberItems( $value ) {
|
private function getTabberItems( $value ) {
|
||||||
global $wgArticleAsJson;
|
|
||||||
$tabberItems = array();
|
$tabberItems = array();
|
||||||
$tabberMarkers = $this->getMarkers( $value, 'TABBER' );
|
$tabberMarkers = $this->getMarkers( $value, 'TABBER' );
|
||||||
for ( $i = 0; $i < count ( $tabberMarkers ); $i++ ) {
|
for ( $i = 0; $i < count ( $tabberMarkers ); $i++ ) {
|
||||||
|
@ -103,6 +102,7 @@ class NodeImage extends Node {
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getTabberData( $html ) {
|
private function getTabberData( $html ) {
|
||||||
|
global $wgArticleAsJson;
|
||||||
$data = array();
|
$data = array();
|
||||||
$doc = new \DOMDocument();
|
$doc = new \DOMDocument();
|
||||||
$doc->loadHTML( $html );
|
$doc->loadHTML( $html );
|
||||||
|
|
|
@ -19,7 +19,7 @@ class PortableInfoboxRenderService extends WikiaService {
|
||||||
'navigation' => 'PortableInfoboxItemNavigation.mustache',
|
'navigation' => 'PortableInfoboxItemNavigation.mustache',
|
||||||
'hero-mobile' => 'PortableInfoboxItemHeroMobile.mustache',
|
'hero-mobile' => 'PortableInfoboxItemHeroMobile.mustache',
|
||||||
'image-collection' => 'PortableInfoboxItemImageCollection.mustache',
|
'image-collection' => 'PortableInfoboxItemImageCollection.mustache',
|
||||||
'image-collection-mobile' => 'PortableInfoboxItemImageCollection.mustache' // TODO: Create separated template for mobile
|
'image-collection-mobile' => 'PortableInfoboxItemImageCollectionMobile.mustache'
|
||||||
];
|
];
|
||||||
private $templateEngine;
|
private $templateEngine;
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
<div class="pi-image-collection" data-refs="{{#images}}{{ref}},{{/images}}"></div>
|
Loading…
Reference in a new issue