mirror of
https://github.com/Universal-Omega/PortableInfobox.git
synced 2024-11-15 03:35:53 +00:00
Fix #35 and panel rendering
This commit is contained in:
parent
05e55672a6
commit
8d2d9d6594
|
@ -27,6 +27,7 @@ class PortableInfoboxParsingHelper {
|
|||
|
||||
if ( $templateText ) {
|
||||
$parser = new \Parser();
|
||||
$parser->setTitle( $title );
|
||||
$parserOptions = new \ParserOptions();
|
||||
$frame = $parser->getPreprocessor()->newFrame();
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ class PortableInfoboxTemplateEngine {
|
|||
public function __construct() {
|
||||
if ( !isset( self::$lightncandy ) ) {
|
||||
self::$lightncandy = class_exists( '\LightnCandy\LightnCandy' ) ? \LightnCandy\LightnCandy::class : \LightnCandy::class;
|
||||
self::$compileFlags = self::$lightncandy::FLAG_BESTPERFORMANCE | self::$lightncandy::FLAG_PARENT;
|
||||
self::$compileFlags = self::$lightncandy::FLAG_BESTPERFORMANCE | self::$lightncandy::FLAG_PARENT | self::$lightncandy::FLAG_HANDLEBARS;
|
||||
}
|
||||
|
||||
if ( !isset( self::$memcache ) ) {
|
||||
|
|
|
@ -215,7 +215,7 @@ class PortableInfoboxRenderService {
|
|||
break;
|
||||
}
|
||||
}
|
||||
if ( $collapse !== null && count( $tabContents ) > 0 && !empty( $header ) ) {
|
||||
if ( $collapse !== null && count( $sections ) > 0 && !empty( $header ) ) {
|
||||
$cssClasses[] = 'pi-collapse';
|
||||
$cssClasses[] = 'pi-collapse-' . $collapse;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue