9c48f24a9c62484d805bc6a714872aed7bcfd81f
[moodle.git] / theme / classic / templates / columns.mustache
1 {{!
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 @template theme_classic/columns
19
20 Admin time setting template.
21
22 Classic 1-3 column layout template.
23
24 Context variables required for this template:
25 * sitename - The name of the site
26 * output - The core renderer for the page
27 * bodyattributes - attributes for the body tag as a string of html attributes
28 * sidepreblocks - HTML for the blocks
29 * hasblocks - true if there are blocks on this page
30 * regionmainsettingsmenu - HTML for the region main settings menu
31 * hasregionmainsettingsmenu - There is a region main settings menu on this page.
32
33 Example context (json):
34 {
35 "sitename": "Moodle",
36 "output": {
37 "doctype": "<!DOCTYPE html>",
38 "page_title": "Test page",
39 "favicon": "favicon.ico",
40 "main_content": "<h1>Headings make html validators happier</h1>"
41 },
42 "bodyattributes":"",
43 "sidepreblocks": "<h2>Blocks html goes here</h2>",
44 "sidepostblocks": "<h2>Blocks html goes here</h2>",
45 "haspreblocks":true,
46 "haspostblocks":true
47 }
48 }}
49 {{> theme_boost/head }}
50
51 <body {{{ bodyattributes }}}>
52
53 <div id="page-wrapper">
54
55 {{{ output.standard_top_of_body_html }}}
56
57 {{>theme_classic/navbar}}
58
59 <div id="page" class="container-fluid">
60 {{{ output.full_header }}}
61
62 <div id="page-content" class="row {{#haspreblocks}} blocks-pre {{/haspreblocks}} {{#haspostblocks}} blocks-post {{/haspostblocks}}">
63 <div id="region-main-box" class="region-main">
64 {{#hasregionmainsettingsmenu}}
65 <div id="region-main-settings-menu" class="d-print-none {{#hasblocks}}has-blocks{{/hasblocks}}">
66 <div> {{{ output.region_main_settings_menu }}} </div>
67 </div>
68 {{/hasregionmainsettingsmenu}}
69 <section id="region-main" class="region-main-content" aria-label="{{#str}}content{{/str}}">
70 {{#hasregionmainsettingsmenu}}
71 <div class="region_main_settings_menu_proxy"></div>
72 {{/hasregionmainsettingsmenu}}
73 {{{ output.course_content_header }}}
74 {{{ output.main_content }}}
75 {{{ output.activity_navigation }}}
76 {{{ output.course_content_footer }}}
77 </section>
78 </div>
79 <div class="columnleft blockcolumn {{#haspreblocks}} has-blocks {{/haspreblocks}}">
80 <section data-region="blocks-column" class="hidden-print" aria-label="{{#str}}blocks{{/str}}">
81 {{{ sidepreblocks }}}
82 </section>
83 </div>
84
85 <div class="columnright blockcolumn {{#haspostblocks}} has-blocks {{/haspostblocks}}">
86 <section data-region="blocks-column" class="hidden-print" aria-label="{{#str}}blocks{{/str}}">
87 {{{ sidepostblocks }}}
88 </section>
89 </div>
90 </div>
91 </div>
92 {{{ output.standard_after_main_region_html }}}
93 {{> theme_boost/footer }}
94 </div>
95
96 </body>
97 </html>
98 {{#js}}
99 M.util.js_pending('theme_boost/loader');
100 require(['theme_boost/loader'], function() {
101 M.util.js_complete('theme_boost/loader');
102 });
103 {{/js}}