From b9cc5a9026fc15b9ff85a7e479ef7dd5505a6fa5 Mon Sep 17 00:00:00 2001 From: benweet Date: Tue, 21 Jan 2014 23:48:42 +0000 Subject: [PATCH] Simplified settings dialog --- public/index.html | 4 +- public/res/core.js | 5 ++ public/res/eventMgr.js | 28 +++++- public/res/html/bodyIndex.html | 158 +++++++++++++++++++-------------- public/viewer.html | 2 +- 5 files changed, 123 insertions(+), 74 deletions(-) diff --git a/public/index.html b/public/index.html index 187fb35a..c8792942 100644 --- a/public/index.html +++ b/public/index.html @@ -2,11 +2,11 @@ - StackEdit – *smart* markdown editor + StackEdit – markdown editor - + <\/div>\n\n/gm, ''); + html = html.replace(/ .*<\/span> /g, ''); onPreviewFinished(utils.trim(html)); }); }; @@ -242,7 +264,7 @@ define([ var accordionHtml = _.chain(extensionList).sortBy(function(extension) { return extension.extensionName.toLowerCase(); }).reduce(function(html, extension) { - return html + (extension.settingsBlock ? _.template(settingsExtensionsAccordionHTML, { + return html + (extension.settingsBlock && !(window.lightMode === true && extension.disableInLight === true) ? _.template(settingsExtensionsAccordionHTML, { extensionId: extension.extensionId, extensionName: extension.extensionName, isOptional: extension.isOptional, @@ -250,7 +272,7 @@ define([ }) : ""); }, "").value(); document.querySelector('.accordion-extensions').innerHTML = accordionHtml; - + // Create extension buttons logger.log("onCreateButton"); var onCreateButtonListenerList = getExtensionListenerList("onCreateButton"); diff --git a/public/res/html/bodyIndex.html b/public/res/html/bodyIndex.html index 50e04540..f57b4021 100644 --- a/public/res/html/bodyIndex.html +++ b/public/res/html/bodyIndex.html @@ -906,10 +906,10 @@