Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
<?php
2
// This file is part of Moodle - http://moodle.org/
3
//
4
// Moodle is free software: you can redistribute it and/or modify
5
// it under the terms of the GNU General Public License as published by
6
// the Free Software Foundation, either version 3 of the License, or
7
// (at your option) any later version.
8
//
9
// Moodle is distributed in the hope that it will be useful,
10
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
// GNU General Public License for more details.
13
//
14
// You should have received a copy of the GNU General Public License
15
// along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
16
 
17
/**
18
 * Boost config.
19
 *
20
 * @package   theme_boost
21
 * @copyright 2016 Frédéric Massart
22
 * @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
23
 */
24
 
25
defined('MOODLE_INTERNAL') || die();
26
 
27
require_once(__DIR__ . '/lib.php');
28
 
29
$THEME->name = 'boost';
30
$THEME->sheets = [];
31
$THEME->editor_sheets = [];
32
$THEME->editor_scss = ['editor'];
33
$THEME->usefallback = true;
34
$THEME->scss = function($theme) {
35
    return theme_boost_get_main_scss_content($theme);
36
};
37
 
38
$THEME->layouts = [
39
    // Most backwards compatible layout without the blocks.
40
    'base' => array(
41
        'file' => 'drawers.php',
42
        'regions' => array(),
43
    ),
44
    // Standard layout with blocks.
45
    'standard' => array(
46
        'file' => 'drawers.php',
47
        'regions' => array('side-pre'),
48
        'defaultregion' => 'side-pre',
49
    ),
50
    // Main course page.
51
    'course' => array(
52
        'file' => 'drawers.php',
53
        'regions' => array('side-pre'),
54
        'defaultregion' => 'side-pre',
55
        'options' => array('langmenu' => true),
56
    ),
57
    'coursecategory' => array(
58
        'file' => 'drawers.php',
59
        'regions' => array('side-pre'),
60
        'defaultregion' => 'side-pre',
61
    ),
62
    // Part of course, typical for modules - default page layout if $cm specified in require_login().
63
    'incourse' => array(
64
        'file' => 'drawers.php',
65
        'regions' => array('side-pre'),
66
        'defaultregion' => 'side-pre',
67
    ),
68
    // The site home page.
69
    'frontpage' => array(
70
        'file' => 'drawers.php',
71
        'regions' => array('side-pre'),
72
        'defaultregion' => 'side-pre',
73
        'options' => array('nonavbar' => true),
74
    ),
75
    // Server administration scripts.
76
    'admin' => array(
77
        'file' => 'drawers.php',
78
        'regions' => array('side-pre'),
79
        'defaultregion' => 'side-pre',
80
    ),
81
    // My courses page.
82
    'mycourses' => array(
83
        'file' => 'drawers.php',
84
        'regions' => ['side-pre'],
85
        'defaultregion' => 'side-pre',
86
        'options' => array('nonavbar' => true),
87
    ),
88
    // My dashboard page.
89
    'mydashboard' => array(
90
        'file' => 'drawers.php',
91
        'regions' => array('side-pre'),
92
        'defaultregion' => 'side-pre',
93
        'options' => array('nonavbar' => true, 'langmenu' => true),
94
    ),
95
    // My public page.
96
    'mypublic' => array(
97
        'file' => 'drawers.php',
98
        'regions' => array('side-pre'),
99
        'defaultregion' => 'side-pre',
100
    ),
101
    'login' => array(
102
        'file' => 'login.php',
103
        'regions' => array(),
104
        'options' => array('langmenu' => true),
105
    ),
106
 
107
    // Pages that appear in pop-up windows - no navigation, no blocks, no header and bare activity header.
108
    'popup' => array(
109
        'file' => 'columns1.php',
110
        'regions' => array(),
111
        'options' => array(
112
            'nofooter' => true,
113
            'nonavbar' => true,
114
            'activityheader' => [
115
                'notitle' => true,
116
                'nocompletion' => true,
117
                'nodescription' => true
118
            ]
119
        )
120
    ),
121
    // No blocks and minimal footer - used for legacy frame layouts only!
122
    'frametop' => array(
123
        'file' => 'columns1.php',
124
        'regions' => array(),
125
        'options' => array(
126
            'nofooter' => true,
127
            'nocoursefooter' => true,
128
            'activityheader' => [
129
                'nocompletion' => true
130
            ]
131
        ),
132
    ),
133
    // Embeded pages, like iframe/object embeded in moodleform - it needs as much space as possible.
134
    'embedded' => array(
135
        'file' => 'embedded.php',
136
        'regions' => array('side-pre'),
137
        'defaultregion' => 'side-pre',
138
    ),
139
    // Used during upgrade and install, and for the 'This site is undergoing maintenance' message.
140
    // This must not have any blocks, links, or API calls that would lead to database or cache interaction.
141
    // Please be extremely careful if you are modifying this layout.
142
    'maintenance' => array(
143
        'file' => 'maintenance.php',
144
        'regions' => array(),
145
    ),
146
    // Should display the content and basic headers only.
147
    'print' => array(
148
        'file' => 'columns1.php',
149
        'regions' => array(),
150
        'options' => array('nofooter' => true, 'nonavbar' => false, 'noactivityheader' => true),
151
    ),
152
    // The pagelayout used when a redirection is occuring.
153
    'redirect' => array(
154
        'file' => 'embedded.php',
155
        'regions' => array(),
156
    ),
157
    // The pagelayout used for reports.
158
    'report' => array(
159
        'file' => 'drawers.php',
160
        'regions' => array('side-pre'),
161
        'defaultregion' => 'side-pre',
162
    ),
163
    // The pagelayout used for safebrowser and securewindow.
164
    'secure' => array(
165
        'file' => 'secure.php',
166
        'regions' => array('side-pre'),
167
        'defaultregion' => 'side-pre'
168
    )
169
];
170
 
171
$THEME->parents = [];
172
$THEME->enable_dock = false;
173
$THEME->extrascsscallback = 'theme_boost_get_extra_scss';
174
$THEME->prescsscallback = 'theme_boost_get_pre_scss';
175
$THEME->precompiledcsscallback = 'theme_boost_get_precompiled_css';
176
$THEME->yuicssmodules = array();
177
$THEME->rendererfactory = 'theme_overridden_renderer_factory';
178
$THEME->requiredblocks = '';
179
$THEME->addblockposition = BLOCK_ADDBLOCK_POSITION_FLATNAV;
180
$THEME->iconsystem = \core\output\icon_system::FONTAWESOME;
181
$THEME->haseditswitch = true;
182
$THEME->usescourseindex = true;
183
// By default, all boost theme do not need their titles displayed.
184
$THEME->activityheaderconfig = [
185
    'notitle' => true
186
];