Skip to content
This repository has been archived by the owner on Dec 2, 2022. It is now read-only.

Commit

Permalink
2.7.4
Browse files Browse the repository at this point in the history
  • Loading branch information
gjb2048 committed Jul 31, 2014
2 parents 9b500db + d19f037 commit 7411714
Show file tree
Hide file tree
Showing 10 changed files with 212 additions and 211 deletions.
59 changes: 58 additions & 1 deletion README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,57 @@ Cool things to know about the theme.
- The entire colour scheme can be modified with theme settings
- The homepage main area is just a label. The theme will ship with custom classes that you can set for tables and links to modify their formatting. No knowledge of code is needed as you can use the text editor to do this. Documentation will be provided outlining what the additional classes are.

Required version of Moodle
==========================
This version works with Moodle version 2013111800 release 2.6 (Build: 20131118) and above within the 2.6 branch until the
next release.

Please ensure that your hardware and software complies with 'Requirements' in 'Installing Moodle' on
'docs.moodle.org/26/en/Installing_Moodle'.

Installation
============
1. Ensure you have the version of Moodle as stated above in 'Required version of Moodle'. This is essential as the
theme relies on underlying core code that is out of our control.
2. Login as an administrator and put Moodle in 'Maintenance Mode' so that there are no users using it bar you as the administrator.
3. Copy the extracted 'essential' folder to the '/theme/' folder.
4. Go to 'Site administration' -> 'Notifications' and follow standard the 'plugin' update notification.
5. Select as the theme for the site.
6. Put Moodle out of Maintenance Mode.

Upgrading
=========
1. Ensure you have the version of Moodle as stated above in 'Required version of Moodle'. This is essential as the
theme relies on underlying core code that is out of our control.
2. Login as an administrator and put Moodle in 'Maintenance Mode' so that there are no users using it bar you as the administrator.
3. Make a backup of your old 'essential' folder in '/theme/' and then delete the folder.
4. Copy the replacement extracted 'essential' folder to the '/theme/' folder.
5. Go to 'Site administration' -> 'Notifications' and follow standard the 'plugin' update notification.
6. If automatic 'Purge all caches' appears not to work by lack of display etc. then perform a manual 'Purge all caches'
under 'Home -> Site administration -> Development -> Purge all caches'.
7. Put Moodle out of Maintenance Mode.

Uninstallation
==============
1. Put Moodle in 'Maintenance Mode' so that there are no users using it bar you as the administrator.
2. Change the theme to another theme of your choice.
3. In '/theme/' remove the folder 'essential'.
4. Put Moodle out of Maintenance Mode.

Reporting issues
================
Before reporting an issue, please ensure that you are running the latest version for your release of Moodle. It is essential
that you are operating the required version of Moodle as stated at the top - this is because the theme relies on core
functionality that is out of its control.

When reporting an issue you can post in the theme's forum on Moodle.org (currently 'moodle.org/mod/forum/view.php?id=46')
or check the issue list https://github.com/DBezemer/moodle-theme_essential/issues and if the problem does not exist, create an
issue.

It is essential that you provide as much information as possible, the critical information being the contents of the theme's
'version.php' file. Other version information such as specific Moodle version, theme name and version also helps. A screen shot
can be really useful in visualising the issue along with any files you consider to be relevant.

New in 2.7.4
========================
- FIX: Issue #68. Expand all not showing on Edit course settings.
Expand All @@ -24,17 +75,23 @@ New in 2.7.4
- FIX: Issue #85. Header logo location in RTL.
- FIX: Reverted icons back to #999.
- FIX: Alternative colour sets all now have the same CSS, docking fixed and consistent with settings.
- FIX: Moved all RTL to separate sheet from main CSS. Sheet 'essential-rtl' uses 'flipped' technology whilst 'rtl' sheet has manual styles.
- FIX: Moved all RTL to separate sheet from main CSS. Sheet 'essential-rtl' uses 'flipped' technology ('grunt-css-flip') whilst 'rtl' sheet has manual styles.
- FIX: Issue #78. Category icon issue in RTL.
- FIX: Issue #90. XML Editor last used.
- FIX: Issue #88. XML editor contrast issues.
- FIX: Issue #89. Dock causes horizontal scroll bar.
- FIX: Issue #93. Navbar / breadcrumb colour setting needed for contrast issues.
- FIX: Issue #94. Docking centred text.
- FIX: Issue #95. Navbar colour to far.
- FIX: Height of page header constrained when screen width < 767px and row-fluid spans go 100%.
- NEW: Alternative colour sets have text and link colour settings.
- NEW: Optimised svg's to be smaller.
- NEW: Warning about IE8 as M2.6 does not support it - http://docs.moodle.org/dev/Moodle_2.6_release_notes#Requirements.
- NEW: If the page width setting is narrow and there are custom menu items the navigation bar and page adjusts to cope.
- NEW: Optimised colour setting code in lib.php.
- NOTE: If you are using an RTL language then please read the instructions in the config.php file to swap to the RTL styles manually. As
a code solution to swapping files does not work at the moment and combining all possible CSS into one file leads to a big file with
lots of redundant CSS. This presents problems when it comes to portable devices and bandwidth.

New in 2.7.3
========================
Expand Down
10 changes: 8 additions & 2 deletions config.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,18 @@
$THEME->yuicssmodules = array();
$THEME->parents = array('bootstrapbase');
$THEME->sheets = array('fontawesome');
if ('ltr' === get_string('thisdirection', 'langconfig')) {
/*
global $PAGE;
if (strpos($PAGE->bodyclasses, 'dir-rtl') === false) { // TODO - only works with TDM off.
$THEME->sheets[] = 'essential';
} else {
$THEME->sheets[] = 'essential-rtl';
$THEME->sheets[] = 'rtl';
}
} */
$THEME->sheets[] = 'essential'; // LTR.
//$THEME->sheets[] = 'essential-rtl'; // RTL.
//$THEME->sheets[] = 'rtl'; // RTL.
// Note: Swap above and do a purge all caches if using an RTL language.
$THEME->sheets[] = 'custom';
$THEME->supportscssoptimisation = false;

Expand Down
11 changes: 8 additions & 3 deletions lang/en/theme_essential.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@
$string['displayafterlogin'] = 'Show after login only';
$string['dontdisplay'] = 'Never show';

// Readme.
$string['readme_title'] = 'Essential read-me';
$string['readme_desc'] = 'Please click on \'{$a->url}\' for lots more information about Essential.';


/* CustomMenu */
$string['custommenuheading'] = 'Custom menu';
$string['custommenuheadingsub'] = 'Add additional functionality to your custommenu.';
Expand Down Expand Up @@ -210,7 +215,7 @@
$string['defaultcolors'] = 'Default colours';
$string['alternativecolors'] = 'Alternative colours {$a}';
$string['alternativethemecolor'] = 'Alternative theme colour {$a}';
$string['alternativethemecolordesc'] = 'What colour should your theme be for the alternative theme colours {$a}. If enabled and the user choose it, this will replace the default theme colour.';
$string['alternativethemecolordesc'] = 'What colour should your theme be for the alternative theme colours {$a}.';
$string['alternativethemename'] = 'Colour scheme name';
$string['alternativethemenamedesc'] = 'Provide a name for your alternative theme colours';
$string['alternativethemecolors'] = 'Alternative theme colours';
Expand All @@ -222,7 +227,7 @@
$string['alternativethemeurlcolor'] = 'Alternative link colour {$a}';
$string['alternativethemeurlcolordesc'] = 'Set the colour for your alternative linked text {$a}.';
$string['alternativethemehovercolor'] = 'Alternative theme hover colour {$a}';
$string['alternativethemehovercolordesc'] = 'What colour should your theme hovers be for the alternative theme colours {$a}. If enabled and the user choose it, this will replace the default theme hover colour.';
$string['alternativethemehovercolordesc'] = 'What colour should your theme hovers be for the alternative theme colours {$a}.';
$string['enablealternativethemecolors'] = 'Enable alternative theme colours {$a}';
$string['enablealternativethemecolorsdesc'] = 'If enabled, the user will be able to choose the alternative theme colours {$a}.';

Expand All @@ -243,7 +248,7 @@
/* Slideshow */
$string['slideshowheading'] = 'Front page slide show';
$string['slideshowheadingsub'] = 'Dynamic slide show for the front page';
$string['slideshowdesc'] = 'This creates a dynamic slide show of up to sixteen slides for you to promote important elements of your site.';
$string['slideshowdesc'] = 'This creates a dynamic slide show of up to sixteen slides for you to promote important elements of your site. The show is responsive where image height is set according to screen size. The recommended height is 300px. The width is set at 100% and therefore the actual height will be smaller if the width is greater than the screen size. At smaller screen sizes the height is reduced dynamically without the need to provide separate images. For reference screen width < 767px = height 165px, width between 768px and 979px = height 225px and width > 980px = height 300px. If no image is selected for a slide, then the default_slide image in the pix folder is used.';

$string['toggleslideshow'] = 'Toggle slide show display';
$string['toggleslideshowdesc'] = 'Choose if you wish to hide or show the slide show.';
Expand Down
6 changes: 3 additions & 3 deletions lang/en_us/theme_essential.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/

/* General */
$string['editiconsdesc'] = 'This utilises the Font Awesome to display colored and neater formatted edit icons in course pages and blocks. Please note that currsently this is NOT compatible with Autohide.';
$string['editiconsdesc'] = 'This utilises the Font Awesome to display colored and neater formatted edit icons in course pages and blocks. Please note that currently this is NOT compatible with Autohide.';
$string['customcssdesc'] = 'Whatever CSS rules you add to this textarea will be reflected in every page, making for easier customization of this theme.';
$string['copyrightdesc'] = 'The name of your organization.';

Expand Down Expand Up @@ -53,11 +53,11 @@

$string['alternativecolors'] = 'Alternative colors {$a}';
$string['alternativethemecolor'] = 'Alternative theme color {$a}';
$string['alternativethemecolordesc'] = 'What color should your theme be for the alternative theme colors {$a}. If enabled and the user choose it, this will replace the default theme color.';
$string['alternativethemecolordesc'] = 'What color should your theme be for the alternative theme colors {$a}.';
$string['alternativethemecolors'] = 'Alternative theme colors';
$string['alternativethemecolorsdesc'] = 'Defines theme colors alternative that the user may select.';
$string['alternativethemehovercolor'] = 'Alternative theme hover color {$a}';
$string['alternativethemehovercolordesc'] = 'What color should your theme hovers be for the alternative theme colors {$a}. If enabled and the user choose it, this will replace the default theme hover color.';
$string['alternativethemehovercolordesc'] = 'What color should your theme hovers be for the alternative theme colors {$a}.';
$string['defaultcolors'] = 'Default colors';
$string['enablealternativethemecolors'] = 'Enable alternative theme colors {$a}';
$string['enablealternativethemecolorsdesc'] = 'If enabled, the user will be able to choose the alternative theme colors {$a}.';
Expand Down
122 changes: 59 additions & 63 deletions layout/includes/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,71 +51,67 @@
</nav>

<div id="page-header" class="clearfix<?php echo ($oldnavbar)? ' oldnavbar': '';?>">
<div class="container-fluid">
<div class="row-fluid">
<!-- HEADER: LOGO AREA -->
<div class="<?php echo $logoclass; echo (!$left) ? ' pull-right': '';?>">
<?php if (!$haslogo) { ?>
<i id="headerlogo" class="fa fa-<?php echo $PAGE->theme->settings->siteicon ?>"></i>
<h1 id="title"><?php echo $SITE->shortname; ?></h1>
<?php } else { ?>
<a class="logo" href="<?php echo $CFG->wwwroot; ?>" title="<?php print_string('home'); ?>"></a>
<?php } ?>
</div>
<?php if (isloggedin() && $hasprofilepic) { ?>
<div class="span1<?php echo ($left) ? ' pull-right': '';?>" id="profilepic">
<p id="socialheading"><?php echo $USER->firstname; ?></p>
<ul class="socials unstyled">
<li>
<?php echo $OUTPUT->user_picture($USER); ?>
</li>
</ul>
</div>
<?php
}
// If true, displays the heading and available social links; displays nothing if false.
if ($hassocialnetworks) {
?>
<div class="span3<?php echo ($left) ? ' pull-right': '';?>">
<p id="socialheading"><?php echo get_string('socialnetworks','theme_essential')?></p>
<ul class="socials unstyled">
<?php
echo $OUTPUT->render_social_network('googleplus');
echo $OUTPUT->render_social_network('twitter');
echo $OUTPUT->render_social_network('facebook');
echo $OUTPUT->render_social_network('linkedin');
echo $OUTPUT->render_social_network('youtube');
echo $OUTPUT->render_social_network('flickr');
echo $OUTPUT->render_social_network('pinterest');
echo $OUTPUT->render_social_network('instagram');
echo $OUTPUT->render_social_network('vk');
echo $OUTPUT->render_social_network('skype');
echo $OUTPUT->render_social_network('website');
?>
</ul>
</div>
<?php
}

// If true, displays the heading and available social links; displays nothing if false.
if ($hasmobileapps) {
?>
<div class="span2 pull-right">
<p id="socialheading"><?php echo get_string('mobileappsheading','theme_essential')?></p>
<ul class="socials unstyled">
<?php
echo $OUTPUT->render_social_network('ios');
echo $OUTPUT->render_social_network('android');
?>
</ul>
</div>
<?php
}

if (!empty($courseheader)) { ?>
<div id="course-header"><?php echo $courseheader; ?></div>
<div class="row-fluid">
<!-- HEADER: LOGO AREA -->
<div class="<?php echo $logoclass; echo (!$left) ? ' pull-right': '';?>">
<?php if (!$haslogo) { ?>
<i id="headerlogo" class="fa fa-<?php echo $PAGE->theme->settings->siteicon ?>"></i>
<h1 id="title"><?php echo $SITE->shortname; ?></h1>
<?php } else { ?>
<a class="logo" href="<?php echo $CFG->wwwroot; ?>" title="<?php print_string('home'); ?>"></a>
<?php } ?>
</div>
<?php if (isloggedin() && $hasprofilepic) { ?>
<div class="span1<?php echo ($left) ? ' pull-right': '';?>" id="profilepic">
<p id="profileheading"><?php echo $USER->firstname; ?></p>
<ul class="socials unstyled">
<li>
<?php echo $OUTPUT->user_picture($USER); ?>
</li>
</ul>
</div>
<?php
}
// If true, displays the heading and available social links; displays nothing if false.
if ($hassocialnetworks) {
?>
<div class="span4<?php echo ($left) ? ' pull-right': '';?>" id="socialnetworks">
<p id="socialheading"><?php echo get_string('socialnetworks','theme_essential')?></p>
<ul class="socials unstyled">
<?php
echo $OUTPUT->render_social_network('googleplus');
echo $OUTPUT->render_social_network('twitter');
echo $OUTPUT->render_social_network('facebook');
echo $OUTPUT->render_social_network('linkedin');
echo $OUTPUT->render_social_network('youtube');
echo $OUTPUT->render_social_network('flickr');
echo $OUTPUT->render_social_network('pinterest');
echo $OUTPUT->render_social_network('instagram');
echo $OUTPUT->render_social_network('vk');
echo $OUTPUT->render_social_network('skype');
echo $OUTPUT->render_social_network('website');
?>
</ul>
</div>
<?php
}
// If true, displays the heading and available social links; displays nothing if false.
if ($hasmobileapps) {
?>
<div class="span2<?php echo ($left) ? ' pull-right': '';?>">
<p id="socialheading"><?php echo get_string('mobileappsheading','theme_essential')?></p>
<ul class="socials unstyled">
<?php
echo $OUTPUT->render_social_network('ios');
echo $OUTPUT->render_social_network('android');
?>
</ul>
</div>
<?php
}
if (!empty($courseheader)) { ?>
<div id="course-header"><?php echo $courseheader; ?></div>
<?php } ?>
</div>
</div>
</header>
4 changes: 2 additions & 2 deletions layout/includes/pagesettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,11 @@

$logoclass = 'span12';
if (($hassocialnetworks || $hasmobileapps) && $hasprofilepic) {
$logoclass = 'span6';
$logoclass = 'span5';
} else if (!($hassocialnetworks || $hasmobileapps) && $hasprofilepic) {
$logoclass = 'span11';
} else if (($hassocialnetworks || $hasmobileapps) && !$hasprofilepic) {
$logoclass = 'span7';
$logoclass = 'span6';
}

$oldnavbar = $PAGE->theme->settings->oldnavbar;
Expand Down
8 changes: 7 additions & 1 deletion settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,13 @@
$setting = new admin_setting_configtextarea($name, $title, $description, $default);
$setting->set_updatedcallback('theme_reset_all_caches');
$temp->add($setting);


$readme = new moodle_url('/theme/essential/Readme.txt');
$readme = html_writer::link($readme, 'Readme.txt', array('target' => '_blank'));

$temp->add(new admin_setting_heading('theme_essential_generalreadme', get_string('readme_title', 'theme_essential'),
get_string('readme_desc', 'theme_essential', array('url' => $readme))));

$ADMIN->add('theme_essential', $temp);

/* Custom Menu Settings */
Expand Down
Loading

0 comments on commit 7411714

Please sign in to comment.