mirror of
https://github.com/gtbu/Typesetter-5.3-p8.git
synced 2024-11-22 06:09:13 +01:00
36 lines
702 B
PHP
36 lines
702 B
PHP
|
<?php
|
||
|
/**
|
||
|
* Bootstrap 4 - Typesetter CMS theme
|
||
|
* plugin hooks used by the theme
|
||
|
*
|
||
|
*/
|
||
|
|
||
|
defined('is_running') or die('Not an entry point...');
|
||
|
|
||
|
class Theme_Bootstrap4{
|
||
|
|
||
|
static function AvailableClasses($classes){
|
||
|
global $page, $addonFolderName;
|
||
|
|
||
|
$theme_dir = basename(dirname(__FILE__));
|
||
|
if( $theme_dir != $addonFolderName ){
|
||
|
return $classes;
|
||
|
}
|
||
|
|
||
|
$layout_config = \gp\tool\Output::GetLayoutConfig();
|
||
|
if( empty($layout_config['use_avail_classes']['value']) ){
|
||
|
return $classes;
|
||
|
}
|
||
|
|
||
|
$classes_file = $page->theme_dir . '/' . $page->theme_color . '/classes.php';
|
||
|
|
||
|
if( file_exists($classes_file) ){
|
||
|
include $classes_file; // will overwrite $classes
|
||
|
}
|
||
|
|
||
|
return $classes;
|
||
|
}
|
||
|
|
||
|
|
||
|
}
|