mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 04:30:15 +01:00
Merge branch 'MDL-40686' of git://github.com/rwijaya/moodle
Conflicts: theme/bootstrapbase/style/moodle.css
This commit is contained in:
commit
e025a2fc43
@ -78,6 +78,7 @@ if ($confirm) { // the operation was confirmed.
|
||||
}
|
||||
|
||||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading($book->name);
|
||||
|
||||
// The operation has not been confirmed yet so ask the user to do so.
|
||||
if ($chapter->subchapter) {
|
||||
|
@ -114,7 +114,7 @@ $PAGE->set_title($book->name);
|
||||
$PAGE->set_heading($course->fullname);
|
||||
|
||||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading(get_string('editingchapter', 'mod_book'));
|
||||
echo $OUTPUT->heading($book->name);
|
||||
|
||||
$mform->display();
|
||||
|
||||
|
@ -42,7 +42,11 @@ class book_chapter_edit_form extends moodleform {
|
||||
|
||||
$mform = $this->_form;
|
||||
|
||||
$mform->addElement('header', 'general', get_string('edit'));
|
||||
if (!empty($chapter->id)) {
|
||||
$mform->addElement('header', 'general', get_string('editingchapter', 'mod_book'));
|
||||
} else {
|
||||
$mform->addElement('header', 'general', get_string('addafter', 'mod_book'));
|
||||
}
|
||||
|
||||
$mform->addElement('text', 'title', get_string('chaptertitle', 'mod_book'), array('size'=>'30'));
|
||||
$mform->setType('title', PARAM_RAW);
|
||||
|
@ -1,19 +1,6 @@
|
||||
|
||||
.path-mod-book .book_chapter_title {
|
||||
font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
|
||||
text-align: left;
|
||||
font-size: large;
|
||||
font-weight: bold;
|
||||
|
||||
margin-left: 0;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.dir-rtl.path-mod-book .book_chapter_title {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.path-mod-book .navtop img.icon,
|
||||
.path-mod-book .navbotton img.icon {
|
||||
.path-mod-book .navbottom img.icon {
|
||||
margin-right: 4px;
|
||||
margin-left: 4px;
|
||||
border: 0;
|
||||
@ -65,11 +52,6 @@
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
/* toc style NUMBERED */
|
||||
.path-mod-book .book_toc_numbered {
|
||||
font-size: 0.8em;
|
||||
}
|
||||
|
||||
/*toc style BULLETS */
|
||||
.path-mod-book .book_toc_bullets {
|
||||
font-size: 0.8em;
|
||||
|
@ -32,7 +32,7 @@ class booktool_importhtml_form extends moodleform {
|
||||
$mform = $this->_form;
|
||||
$data = $this->_customdata;
|
||||
|
||||
$mform->addElement('header', 'general', get_string('import'));
|
||||
$mform->addElement('header', 'general', get_string('import', 'booktool_importhtml'));
|
||||
|
||||
$options = array(
|
||||
// '0'=>get_string('typeonefile', 'booktool_importhtml'),
|
||||
|
@ -67,7 +67,8 @@ if ($mform->is_cancelled()) {
|
||||
|
||||
} else if ($data = $mform->get_data()) {
|
||||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading(get_string('importingchapters', 'booktool_importhtml'));
|
||||
echo $OUTPUT->heading($book->name);
|
||||
echo $OUTPUT->heading(get_string('importingchapters', 'booktool_importhtml'), 3);
|
||||
|
||||
// this is a bloody hack - children do not try this at home!
|
||||
$fs = get_file_storage();
|
||||
@ -84,7 +85,7 @@ if ($mform->is_cancelled()) {
|
||||
}
|
||||
|
||||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading(get_string('import', 'booktool_importhtml'));
|
||||
echo $OUTPUT->heading($book->name);
|
||||
|
||||
$mform->display();
|
||||
|
||||
|
@ -98,7 +98,9 @@ if ($chapter) {
|
||||
echo html_writer::link('#', $printicon.$printtext, $printlinkatt);
|
||||
?>
|
||||
<a name="top"></a>
|
||||
<h1 class="book_title"><?php echo format_string($book->name, true, array('context'=>$context)) ?></h1>
|
||||
<?php
|
||||
echo $OUTPUT->heading(format_string($book->name, true, array('context'=>$context)), 1);
|
||||
?>
|
||||
<div class="chapter">
|
||||
<?php
|
||||
|
||||
@ -106,11 +108,12 @@ if ($chapter) {
|
||||
if (!$book->customtitles) {
|
||||
if (!$chapter->subchapter) {
|
||||
$currtitle = book_get_chapter_title($chapter->id, $chapters, $book, $context);
|
||||
echo '<h2 class="book_chapter_title">'.$currtitle.'</h2>';
|
||||
echo $OUTPUT->heading($currtitle);
|
||||
} else {
|
||||
$currtitle = book_get_chapter_title($chapters[$chapter->id]->parent, $chapters, $book, $context);
|
||||
$currsubtitle = book_get_chapter_title($chapter->id, $chapters, $book, $context);
|
||||
echo '<h2 class="book_chapter_title">'.$currtitle.'</h2><h3 class="book_chapter_title">'.$currsubtitle.'</h3>';
|
||||
echo $OUTPUT->heading($currtitle);
|
||||
echo $OUTPUT->heading($currsubtitle, 3);
|
||||
}
|
||||
}
|
||||
|
||||
@ -143,7 +146,9 @@ if ($chapter) {
|
||||
echo html_writer::link('#', $printicon.$printtext, $printlinkatt);
|
||||
?>
|
||||
<a name="top"></a>
|
||||
<h1 class="book_title"><?php echo format_string($book->name, true, array('context'=>$context)) ?></h1>
|
||||
<?php
|
||||
echo $OUTPUT->heading(format_string($book->name, true, array('context'=>$context)), 1);
|
||||
?>
|
||||
<p class="book_summary"><?php echo format_text($book->intro, $book->introformat, array('noclean'=>true, 'context'=>$context)) ?></p>
|
||||
<div class="book_info"><table>
|
||||
<tr>
|
||||
@ -178,9 +183,9 @@ if ($chapter) {
|
||||
echo '<div class="book_chapter"><a name="ch'.$ch->id.'"></a>';
|
||||
if (!$book->customtitles) {
|
||||
if (!$chapter->subchapter) {
|
||||
echo '<h2 class="book_chapter_title">'.$titles[$ch->id].'</h2>';
|
||||
echo $OUTPUT->heading($titles[$ch->id]);
|
||||
} else {
|
||||
echo '<h3 class="book_chapter_title">'.$titles[$ch->id].'</h3>';
|
||||
echo $OUTPUT->heading($titles[$ch->id], 3);
|
||||
}
|
||||
}
|
||||
$content = str_replace($link1, '#ch', $chapter->content);
|
||||
|
@ -60,7 +60,7 @@ function booktool_print_get_toc($chapters, $book, $cm) {
|
||||
|
||||
$toc .= html_writer::tag('a', '', array('name' => 'toc')); // Representation of toc (HTML).
|
||||
|
||||
$toc .= html_writer::tag('h2', get_string('toc', 'mod_book'), array('class' => 'book_chapter_title'));
|
||||
$toc .= html_writer::tag('h2', get_string('toc', 'mod_book'));
|
||||
$toc .= html_writer::start_tag('ul');
|
||||
foreach ($chapters as $ch) {
|
||||
if (!$ch->hidden) {
|
||||
|
@ -6,38 +6,12 @@ h1, h2, h3, h4, h5, h6 {
|
||||
page-break-inside: avoid;
|
||||
}
|
||||
|
||||
.book_title {
|
||||
margin-left: -40px;
|
||||
font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 3em;
|
||||
font-weight: bold;
|
||||
margin-top: 120px;
|
||||
margin-bottom: 30px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.book_summary {
|
||||
margin-left: -40px;
|
||||
text-align: center;
|
||||
margin-bottom: 120px;
|
||||
}
|
||||
|
||||
.book_chapter_title {
|
||||
font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
|
||||
text-align: left;
|
||||
font-size: 1.7em;
|
||||
font-weight: bold;
|
||||
|
||||
border-style: solid;
|
||||
border-top-width: 0px;
|
||||
border-right-width: 0px;
|
||||
border-bottom-width: 1px;
|
||||
border-left-width: 0px;
|
||||
|
||||
margin-left: 0px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.book_chapter {
|
||||
page-break-before: always;
|
||||
}
|
||||
|
@ -172,22 +172,24 @@ if ($nextid) {
|
||||
// =====================================================
|
||||
|
||||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading($book->name);
|
||||
|
||||
// upper nav
|
||||
echo '<div class="navtop">'.$chnavigation.'</div>';
|
||||
|
||||
// chapter itself
|
||||
echo $OUTPUT->box_start('generalbox book_content');
|
||||
$hidden = $chapter->hidden ? ' dimmed_text' : null;
|
||||
echo $OUTPUT->box_start('generalbox book_content' . $hidden);
|
||||
|
||||
if (!$book->customtitles) {
|
||||
$hidden = $chapter->hidden ? 'dimmed_text' : '';
|
||||
if (!$chapter->subchapter) {
|
||||
$currtitle = book_get_chapter_title($chapter->id, $chapters, $book, $context);
|
||||
echo $OUTPUT->heading($currtitle, 2, array('class' => 'book_chapter_title '.$hidden));
|
||||
echo $OUTPUT->heading($currtitle, 3);
|
||||
} else {
|
||||
$currtitle = book_get_chapter_title($chapters[$chapter->id]->parent, $chapters, $book, $context);
|
||||
$currsubtitle = book_get_chapter_title($chapter->id, $chapters, $book, $context);
|
||||
echo $OUTPUT->heading($currtitle, 2, array('class' => 'book_chapter_title '.$hidden));
|
||||
echo $OUTPUT->heading($currsubtitle, 3, array('class' => 'book_chapter_title '.$hidden));
|
||||
echo $OUTPUT->heading($currtitle, 3);
|
||||
echo $OUTPUT->heading($currsubtitle, 4);
|
||||
}
|
||||
}
|
||||
$chaptertext = file_rewrite_pluginfile_urls($chapter->content, 'pluginfile.php', $context->id, 'mod_book', 'chapter', $chapter->id);
|
||||
|
Loading…
x
Reference in New Issue
Block a user