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
 *
19
 * @package   theme_monocolor
20
 * @copyright 2023 Marcin Czaja (https://rosea.io)
21
 * @license   Commercial https://themeforest.net/licenses
22
 *
23
 */
24
 
25
 
26
defined('MOODLE_INTERNAL') || die();
27
 
28
$page = new admin_settingpage('theme_monocolor_block13', get_string('settingsblock13', 'theme_monocolor'));
29
 
30
$name = 'theme_monocolor/displayblock13';
31
$title = get_string('turnon', 'theme_monocolor');
32
$description = get_string('displayblock13_desc', 'theme_monocolor');
33
$default = 0;
34
$setting = new admin_setting_configcheckbox($name, $title .
35
'<span class="badge badge-sq badge-dark ml-2">Block #13</span>', $description, $default);
36
$page->add($setting);
37
 
38
$name = 'theme_monocolor/displayhrblock13';
39
$title = get_string('displayblockhr', 'theme_monocolor');
40
$description = get_string('displayblockhr_desc', 'theme_monocolor');
41
$default = 1;
42
$setting = new admin_setting_configcheckbox($name, $title, $description, $default);
43
$page->add($setting);
44
 
45
$name = 'theme_monocolor/block13id';
46
$title = get_string('additionalid', 'theme_monocolor');
47
$description = get_string('additionalid_desc', 'theme_monocolor');
48
$default = '';
49
$setting = new admin_setting_configtext($name, $title, $description, $default);
50
$page->add($setting);
51
 
52
$name = 'theme_monocolor/block13class';
53
$title = get_string('additionalclass', 'theme_monocolor');
54
$description = get_string('additionalclass_desc', 'theme_monocolor');
55
$default = '';
56
$setting = new admin_setting_configtext($name, $title, $description, $default);
57
$page->add($setting);
58
 
59
$name = 'theme_monocolor/block13introsubtitle';
60
$title = get_string('blockintrosubtitle', 'theme_monocolor');
61
$description = get_string('blockintrosubtitle_desc', 'theme_monocolor');
62
$default = '';
63
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
64
$page->add($setting);
65
 
66
$name = 'theme_monocolor/block13introtitle';
67
$title = get_string('blockintrotitle', 'theme_monocolor');
68
$description = get_string('blockintrotitle_desc', 'theme_monocolor');
69
$default = '';
70
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
71
$page->add($setting);
72
 
73
$name = 'theme_monocolor/block13introcontent';
74
$title = get_string('blockintrocontent', 'theme_monocolor');
75
$description = get_string('blockintrocontent_desc', 'theme_monocolor');
76
$default = '';
77
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
78
$page->add($setting);
79
 
80
$name = 'theme_monocolor/block13htmlcontent';
81
$title = get_string('blockhtmlcontent', 'theme_monocolor');
82
$description = get_string('blockhtmlcontent_desc', 'theme_monocolor');
83
$default = '<div class="row align-items-lg-center">
84
<div class="col-12 col-lg">
85
<h2 class="mb-3">The best Moodle experience ever.</h2>
86
<p class="pb-3 mb-3">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse id lectus nec
87
nunc bibendum facilisis pellentesque ut eros. Praesent bibendum sed mi aliquet tempus.</p>
88
<div class="rui-img-mask row justify-content-center align-items-center mb-4">
89
<div class="rui-img-mask--grayscale col-auto col-sm py-3 text-center">
90
<img src="https://assets.rosea.io/monocolor/demo/logo180x90.png" alt="" width="106" height="60" class="img-fluid">
91
</div>
92
<div class="rui-img-mask--grayscale col-auto col-sm py-3 text-center">
93
<img src="https://assets.rosea.io/monocolor/demo/logo180x90.png" alt="" width="206" height="80" class="img-fluid">
94
</div>
95
<div class="rui-img-mask--grayscale col-auto col-sm py-3 text-center">
96
<img src="https://assets.rosea.io/monocolor/demo/logo180x90.png" alt="" width="69" height="80" class="img-fluid">
97
</div>
98
</div>
99
<div class="d-flex flex-wrap">
100
<a class="btn btn-lg btn-primary" href="#">Try a free lesson</a>
101
<a class="btn btn-lg btn-outline-primary ml-md-2" href="#">Documentation</a>
102
</div>
103
</div>
104
 
105
<div class="rui-img-rounded--xl col-12 col-lg-6 mt-3 mt-lg-0 offset-lg-1">
106
<img src="https://assets.rosea.io/monocolor/demo/600x600.jpg" alt="" width="600" height="600" class="img-fluid">
107
</div>
108
 
109
</div>';
110
$setting = new monocolor_setting_confightmleditor($name, $title, $description, $default);
111
$page->add($setting);
112
 
113
$name = 'theme_monocolor/block13footercontent';
114
$title = get_string('blockfootercontent', 'theme_monocolor');
115
$description = get_string('blockfootercontent_desc', 'theme_monocolor');
116
$default = '';
117
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
118
$page->add($setting);
119
 
120
$fileid = 'block13bg';
121
$name = 'theme_monocolor/block13bg';
122
$title = get_string('blockbg', 'theme_monocolor');
123
$description = get_string('blockbg_desc', 'theme_monocolor');
124
$opts = array('accepted_types' => array('.png', '.jpg', '.gif', '.webp', '.tiff', '.svg'), 'maxfiles' => 1);
125
$setting = new admin_setting_configstoredfile($name, $title, $description, $fileid, 0, $opts);
126
$setting->set_updatedcallback('theme_reset_all_caches');
127
$page->add($setting);
128
 
129
$name = 'theme_monocolor/block13customcss';
130
$title = get_string('blockcustomcss', 'theme_monocolor');
131
$description = get_string('blockcustomcss_desc', 'theme_monocolor');
132
$default = 'background: linear-gradient(to top right, #9f9ef6, #feedba); padding: 80px; text-align: center; border-radius: 80px;';
133
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
134
$page->add($setting);
135
 
136
$settings->add($page);