Skip to content

Commit

Permalink
Fix #37: Removed Enable Trema Course Style for Topics setting.
Browse files Browse the repository at this point in the history
When disabled, this was also causing padding issues with other course format layout.
  • Loading branch information
michael-milette committed May 16, 2024
1 parent 7e247e1 commit 5d57a70
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 63 deletions.
2 changes: 0 additions & 2 deletions lang/en/theme_trema.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,6 @@
$string['enableadmindashboard'] = 'Admin Dashboard';
$string['enabletremalines_desc'] = 'Enable Trema Lines: <br> <img class="img-responsive" src="{$a}">';
$string['enabletremalines'] = 'Enable Trema Lines';
$string['enabletrematopics_desc'] = 'Enable Trema Course Style for Course format Topics: <br> <img class="img-responsive" src="{$a}">';
$string['enabletrematopics'] = 'Enable Trema Course Style for Topics';
$string['favicon_desc'] = 'Upload your own favicon. It should be an .ico file.';
$string['favicon'] = 'Custom favicon';
$string['hideprimarynavigationitems_desc'] = 'Choose which of the built-in primary (custom) menu items that you would like to remove.';
Expand Down
4 changes: 0 additions & 4 deletions lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -259,10 +259,6 @@ function theme_trema_get_main_scss_content($theme) {
$filename = !empty($theme->settings->preset) ? $theme->settings->preset : 'default.scss';
$scss .= file_get_contents("$CFG->dirroot/theme/trema/scss/preset/{$filename}");

if (!empty($theme->settings->enabletrematopics)) {
$scss .= file_get_contents("$CFG->dirroot/theme/trema/scss/trema/topics.scss");
}

if (empty($theme->settings->enabletremalines)) {
$scss .= "%border-frequency { &:before, &:after { content: none !important;}}";
}
Expand Down
Binary file removed pix/examples/trematopics.png
Binary file not shown.
4 changes: 4 additions & 0 deletions scss/trema/incourse.scss
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@
#completionprogressid .btn {
height: auto;
}

#region-main {
padding: 0.5rem;
}
}

body#page-my-index.page-mycourses {
Expand Down
48 changes: 0 additions & 48 deletions scss/trema/topics.scss

This file was deleted.

9 changes: 0 additions & 9 deletions settings/general_settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,15 +112,6 @@
$setting->set_updatedcallback('theme_reset_all_caches');
$page->add($setting);

// Enable Trema Course Style for Topics.
$name = 'theme_trema/enabletrematopics';
$title = get_string('enabletrematopics', 'theme_trema');
$description = get_string('enabletrematopics_desc', 'theme_trema', "$CFG->wwwroot/theme/trema/pix/examples/trematopics.png");
$default = '1';
$setting = new admin_setting_configcheckbox($name, $title, $description, $default);
$setting->set_updatedcallback('theme_reset_all_caches');
$page->add($setting);

// Enable Trema Lines.
$name = 'theme_trema/enabletremalines';
$title = get_string('enabletremalines', 'theme_trema');
Expand Down

0 comments on commit 5d57a70

Please sign in to comment.