|
@@ -2,7 +2,9 @@
|
|
|
|
|
|
jQuery( document ).ready(function( $ ) {
|
|
jQuery( document ).ready(function( $ ) {
|
|
|
|
|
|
|
|
+ // ====================================
|
|
// Scroll
|
|
// Scroll
|
|
|
|
+ // ====================================
|
|
|
|
|
|
$('a').smoothScroll({
|
|
$('a').smoothScroll({
|
|
speed: 400,
|
|
speed: 400,
|
|
@@ -11,7 +13,18 @@ jQuery( document ).ready(function( $ ) {
|
|
|
|
|
|
var sticky = new Sticky('.stickyscroll');
|
|
var sticky = new Sticky('.stickyscroll');
|
|
|
|
|
|
- // Alerts
|
|
|
|
|
|
+ // ====================================
|
|
|
|
+ // Notifications
|
|
|
|
+ // ====================================
|
|
|
|
+
|
|
|
|
+ $(window).bind('beforeunload', () => {
|
|
|
|
+ $('#notifload').addClass('active');
|
|
|
|
+ });
|
|
|
|
+ $(document).ajaxSend(() => {
|
|
|
|
+ $('#notifload').addClass('active');
|
|
|
|
+ }).ajaxComplete(() => {
|
|
|
|
+ $('#notifload').removeClass('active');
|
|
|
|
+ });
|
|
|
|
|
|
var alerts = new Alerts();
|
|
var alerts = new Alerts();
|
|
if(alertsData) {
|
|
if(alertsData) {
|
|
@@ -20,20 +33,29 @@ jQuery( document ).ready(function( $ ) {
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
- // Editor
|
|
|
|
|
|
+ // ====================================
|
|
|
|
+ // Markdown Editor
|
|
|
|
+ // ====================================
|
|
|
|
|
|
if($('#mk-editor').length === 1) {
|
|
if($('#mk-editor').length === 1) {
|
|
|
|
|
|
let mde = new SimpleMDE({
|
|
let mde = new SimpleMDE({
|
|
autofocus: true,
|
|
autofocus: true,
|
|
- element: $("#mk-editor").get(0),
|
|
|
|
autoDownloadFontAwesome: false,
|
|
autoDownloadFontAwesome: false,
|
|
- placeholder: 'Enter Markdown formatted content here...',
|
|
|
|
|
|
+ element: $("#mk-editor").get(0),
|
|
hideIcons: ['heading', 'quote'],
|
|
hideIcons: ['heading', 'quote'],
|
|
|
|
+ placeholder: 'Enter Markdown formatted content here...',
|
|
showIcons: ['strikethrough', 'heading-1', 'heading-2', 'heading-3', 'code', 'table', 'horizontal-rule'],
|
|
showIcons: ['strikethrough', 'heading-1', 'heading-2', 'heading-3', 'code', 'table', 'horizontal-rule'],
|
|
- spellChecker: false
|
|
|
|
|
|
+ spellChecker: false,
|
|
|
|
+ status: false
|
|
});
|
|
});
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // ====================================
|
|
|
|
+ // Pages logic
|
|
|
|
+ // ====================================
|
|
|
|
+
|
|
|
|
+ //=include pages/edit.js
|
|
|
|
+
|
|
});
|
|
});
|