Bugfix for EOF

This commit is contained in:
Diego Najar 2021-06-08 23:34:49 +02:00
parent 1edd3eec53
commit a98e5e4582
5 changed files with 154 additions and 152 deletions

2
.gitignore vendored
View file

@ -29,3 +29,5 @@ bl-themes/tagg
bl-themes/small bl-themes/small
bl-themes/future-imperfect bl-themes/future-imperfect
bl-themes/social-network bl-themes/social-network
Dockerfile
conf/*

View file

@ -68,8 +68,8 @@ class pluginEasyMDE extends Plugin {
$toolbar = Sanitize::htmlDecode($this->getValue('toolbar')); $toolbar = Sanitize::htmlDecode($this->getValue('toolbar'));
$pageBreak = PAGE_BREAK; $pageBreak = PAGE_BREAK;
return <<<EOF return <<<EOF
<script> <script>
// Function required for Bludit // Function required for Bludit
// Returns the content of the editor // Returns the content of the editor
function editorGetContent() { function editorGetContent() {
@ -114,7 +114,7 @@ class pluginEasyMDE extends Plugin {
}] }]
}); });
</script> </script>
EOF; EOF;
} }
} }

View file

@ -90,8 +90,8 @@ class pluginTinymce extends Plugin {
$skin = 'oxide-dark'; $skin = 'oxide-dark';
} }
return <<<EOF return <<<EOF
<script> <script>
// Function required for Bludit // Function required for Bludit
// Returns the content of the editor // Returns the content of the editor
@ -142,8 +142,8 @@ class pluginTinymce extends Plugin {
} }
}); });
</script> </script>
EOF; EOF;
} }
} }

View file

@ -50,15 +50,15 @@ class pluginVisitsStats extends Plugin {
$labelVisits = $L->g('Visits'); $labelVisits = $L->g('Visits');
$labelUnique = $L->g('Unique'); $labelUnique = $L->g('Unique');
return <<<EOF return <<<EOF
<div class="pluginVisitsStats mb-4 pt-4 border-top"> <div class="pluginVisitsStats mb-4 pt-4 border-top">
<h3 class="m-0 p-0"><i class="bi bi-bar-chart"></i>$label</h3> <h3 class="m-0 p-0"><i class="bi bi-bar-chart"></i>$label</h3>
<canvas id="visits-stats"></canvas> <canvas id="visits-stats"></canvas>
</div> </div>
<script> <script>
var ctx = document.getElementById('visits-stats'); var ctx = document.getElementById('visits-stats');
new Chart(ctx, { new Chart(ctx, {
type: 'bar', type: 'bar',
data: { data: {
labels: [$labels], labels: [$labels],
@ -85,9 +85,9 @@ class pluginVisitsStats extends Plugin {
}] }]
} }
} }
}); });
</script> </script>
EOF; EOF;
} }
// Plugin form for settings // Plugin form for settings

View file

@ -25,13 +25,13 @@ class pluginWelcome extends Plugin {
$labelGoodEvening = $L->g('good-evening'); $labelGoodEvening = $L->g('good-evening');
$labelGoodNight = $L->g('good-night'); $labelGoodNight = $L->g('good-night');
return <<<EOF return <<<EOF
<div class="pluginWelcome mb-4"> <div class="pluginWelcome mb-4">
<h2 id="hello-message" class="m-0 p-0"><i class="bi bi-emoji-laughing"></i>Welcome</h2> <h2 id="hello-message" class="m-0 p-0"><i class="bi bi-emoji-laughing"></i>Welcome</h2>
</div> </div>
<script> <script>
$(document).ready(function() { $(document).ready(function() {
$("#hello-message").fadeOut(1000, function() { $("#hello-message").fadeOut(1000, function() {
var date = new Date() var date = new Date()
var hours = date.getHours() var hours = date.getHours()
@ -45,9 +45,9 @@ class pluginWelcome extends Plugin {
$(this).html('<i class="bi bi-moon-stars"></i>$labelGoodNight, $name'); $(this).html('<i class="bi bi-moon-stars"></i>$labelGoodNight, $name');
} }
}).fadeIn(1000); }).fadeIn(1000);
}); });
</script> </script>
EOF; EOF;
} }
} }