diff --git a/public/cache.manifest b/public/cache.manifest index b44a7f5b..7690f770 100644 --- a/public/cache.manifest +++ b/public/cache.manifest @@ -1,5 +1,5 @@ CACHE MANIFEST -#Date Sun Oct 20 2013 00:00:12 +#Date Sun Oct 20 2013 14:51:35 CACHE: res/worker.js diff --git a/public/recovery.html b/public/recovery.html new file mode 100644 index 00000000..654cb3e4 --- /dev/null +++ b/public/recovery.html @@ -0,0 +1,87 @@ + + + + + StackEdit - Recovery + + + + + + + + + + +
+
+ + + +

StackEdit recovery

+

+ The download of your documents and settings will start in 5 seconds... +

+

To import your documents and settings back in StackEdit:

+
+ + Menu + + + Settings + + Utils + + + Import docs & settings +
+

+ + Documents and settings have been downloaded successfully. +

+

+ + Download failed. Please copy/paste the following content in a file: +

+

+ +

+

To clear the local storage + click here.

+

To reopen StackEdit + click here.

+
+ + + diff --git a/public/res-min/main.js b/public/res-min/main.js index 1407cbc4..5aaa4b42 100644 --- a/public/res-min/main.js +++ b/public/res-min/main.js @@ -15506,7 +15506,11 @@ define("config", function() {}), define("storage", [ "underscore", "utils" ], fu void 0 !== n && e(d.querySelector(".file-list." + n.folderIndex.replace(".", ""))).collapse("show"); } }).on("shown.bs.collapse", function(e) { - e.target === d && (t.val(""), s(""), b.scrollTop += h.querySelector(".file.active").getBoundingClientRect().top - 120); + if (e.target === d) { + t.val(""), s(""); + var n = h.querySelector(".file.active"); + n && (b.scrollTop += n.getBoundingClientRect().top - 120); + } }); var t = e(d.querySelector(".search-bar .form-control")); t.bind("propertychange keyup input paste", function() { @@ -21777,7 +21781,7 @@ if (hljs.LANGUAGES.glsl = function(e) { n.addSteps([ { element: ".navbar-inner", title: "Welcome to StackEdit!", - content: [ '', '

You are using the new secured platform. If you want to recover your documents from the old platform, click here.

', "Please click Next to take a quick tour." ].join(""), + content: [ '', '

You are using the new secured platform. If you want to recover your documents from the old platform click here.

', "Please click Next to take a quick tour." ].join(""), placement: "bottom" }, { element: ".navbar .action-create-file", @@ -22370,7 +22374,7 @@ if (hljs.LANGUAGES.glsl = function(e) { }); }, r; }), define("text!html/bodyIndex.html", [], function() { - return '\n
\n
\n
\n
\n\n\n\n\n
\n \n \n
\n
\n
\n
\n
\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
\n
'; + return '\n
\n
\n
\n
\n\n\n\n\n
\n \n \n
\n
\n
\n
\n
\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
\n
'; }), define("text!html/bodyViewer.html", [], function() { return '\n\n
\n
\n
\n\n\n\n
\n \n \n
\n
\n
\n
\n
\n\n\n'; }), define("text!html/settingsTemplateTooltip.html", [], function() { @@ -25901,17 +25905,17 @@ if (hljs.LANGUAGES.glsl = function(e) { this.type = "text", this.lineCommentStart = ">", this.getNextLineIndent = function(e, t) { if (u === !0 && ("listblock" == e || "listblock-start" == e) && /^\s*(?:[-+*]|\d+\.)\s+$/.test(t)) { var n = l.$getSelectedRows(); - if (n.last > 2) { - var i = new a(n.last - 2, l.session.getLine(n.last - 2).length, n.last - 1, l.session.getLine(n.last - 1).length); - l.session.remove(i); + if (n.last > 1) { + var i = new a(n.last - 2, l.session.getLine(n.last - 2).length, n.last - 1, l.session.getLine(n.last - 1).length), o = l.session.getTextRange(i); + /^\s*(?:[-+*]|\d+\.)\s+$/.test(o) && l.session.remove(i); } return u = !1, this.$getIndent(t); } if (u = !1, "listblock" == e) { - var o = /^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(t); - if (!o) return ""; - var r = o[2]; - return r || (r = parseInt(o[3], 10) + 1 + "."), u = !0, o[1] + r + o[4]; + var r = /^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(t); + if (!r) return ""; + var s = r[2]; + return s || (s = parseInt(r[3], 10) + 1 + "."), u = !0, r[1] + s + r[4]; } return this.$getIndent(t); }; @@ -28726,7 +28730,7 @@ var viewerMode = /(^| )viewer($| )/.test(document.body.className), lightMode = v }(navigator.userAgent || navigator.vendor || window.opera), theme = localStorage.theme || "default", themeModule = "less!themes/" + theme; -1 !== baseDir.indexOf("-min") && (themeModule = "css!themes/" + theme), require([ "jquery", "core", "eventMgr", "synchronizer", "publisher", "mediaImporter", "css", themeModule ], function(e, t, n) { - e(function() { + "undefined" != typeof noStart && noStart || e(function() { t.onReady(), window.applicationCache && window.applicationCache.addEventListener("updateready", function() { window.applicationCache.status === window.applicationCache.UPDATEREADY && (window.applicationCache.swapCache(), n.onMessage("New version available!\nJust refresh the page to upgrade.")); diff --git a/public/res-min/require.js b/public/res-min/require.js index 52c2b076..2ce09b5e 100644 --- a/public/res-min/require.js +++ b/public/res-min/require.js @@ -1,5 +1,5 @@ /** vim: et:ts=4:sw=4:sts=4 - * @license RequireJS 2.1.8 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved. + * @license RequireJS 2.1.9 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved. * Available via the MIT or new BSD license. * see: http://github.com/jrburke/requirejs for details */ @@ -12,7 +12,7 @@ var requirejs, require, define; (function (global) { var req, s, head, baseElement, dataMain, src, interactiveScript, currentlyAddingScript, mainScript, subPath, - version = '2.1.8', + version = '2.1.9', commentRegExp = /(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg, cjsRequireRegExp = /[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g, jsSuffixRegExp = /\.js$/, @@ -22,7 +22,7 @@ var requirejs, require, define; hasOwn = op.hasOwnProperty, ap = Array.prototype, apsp = ap.splice, - isBrowser = !!(typeof window !== 'undefined' && navigator && window.document), + isBrowser = !!(typeof window !== 'undefined' && typeof navigator !== 'undefined' && window.document), isWebWorker = !isBrowser && typeof importScripts !== 'undefined', //PS3 indicates loaded and complete, but need to wait for complete //specifically. Sequence is 'loading', 'loaded', execution, @@ -373,7 +373,6 @@ var requirejs, require, define; function hasPathFallback(id) { var pathConfig = getOwn(config.paths, id); if (pathConfig && isArray(pathConfig) && pathConfig.length > 1) { - removeScript(id); //Pop off the first array value, since it failed, and //retry pathConfig.shift(); @@ -1464,6 +1463,8 @@ var requirejs, require, define; var map = makeModuleMap(id, relMap, true), mod = getOwn(registry, id); + removeScript(id); + delete defined[id]; delete urlFetched[map.url]; delete undefEvents[id]; @@ -1609,7 +1610,7 @@ var requirejs, require, define; //Join the path parts together, then figure out if baseUrl is needed. url = syms.join('/'); - url += (ext || (/\?/.test(url) || skipExt ? '' : '.js')); + url += (ext || (/^data\:|\?/.test(url) || skipExt ? '' : '.js')); url = (url.charAt(0) === '/' || url.match(/^[\w\+\.\-]+:/) ? '' : config.baseUrl) + url; } @@ -1918,7 +1919,7 @@ var requirejs, require, define; } //Look for a data-main script attribute, which could also adjust the baseUrl. - if (isBrowser) { + if (isBrowser && !cfg.skipDataMain) { //Figure out baseUrl. Get it from the script tag with require.js in it. eachReverse(scripts(), function (script) { //Set the 'head' where we can append children by diff --git a/public/res/extensions/welcomeTour.js b/public/res/extensions/welcomeTour.js index a221c79b..84782544 100644 --- a/public/res/extensions/welcomeTour.js +++ b/public/res/extensions/welcomeTour.js @@ -39,7 +39,7 @@ define([ title: 'Welcome to StackEdit!', content: [ '', - '

You are using the new secured platform. If you want to recover your documents from the old platform, click here.

', + '

You are using the new secured platform. If you want to recover your documents from the old platform click here.

', 'Please click Next to take a quick tour.' ].join(""), placement: 'bottom', diff --git a/public/res/html/bodyIndex.html b/public/res/html/bodyIndex.html index 31087b85..4da4e1d6 100644 --- a/public/res/html/bodyIndex.html +++ b/public/res/html/bodyIndex.html @@ -1044,7 +1044,8 @@ Load default settings Reset application + class="icon-fire icon-white"> Reset application StackEdit recovery Old platform recovery diff --git a/public/res/libs/ace_mode.js b/public/res/libs/ace_mode.js index dd3c63a6..47bdbdfb 100644 --- a/public/res/libs/ace_mode.js +++ b/public/res/libs/ace_mode.js @@ -63,11 +63,14 @@ var isIndentingList = false; if(isIndentingList === true && (state == "listblock" || state == "listblock-start") && /^\s*(?:[-+*]|\d+\.)\s+$/.test(line)) { // When hitting enter twice in a listblock, remove the previous line var rows = editor.$getSelectedRows(); - if (rows.last > 2) { + if (rows.last > 1) { var range = new Range( rows.last - 2, editor.session.getLine(rows.last - 2).length, rows.last - 1, editor.session.getLine(rows.last - 1).length); - editor.session.remove(range); + var previousLine = editor.session.getTextRange(range); + if(/^\s*(?:[-+*]|\d+\.)\s+$/.test(previousLine)) { + editor.session.remove(range); + } } isIndentingList = false; return this.$getIndent(line); diff --git a/public/res/main.js b/public/res/main.js index b8a2a14c..4600af0d 100644 --- a/public/res/main.js +++ b/public/res/main.js @@ -138,6 +138,10 @@ if (baseDir.indexOf('-min') !== -1) { // media-importer, we are actually loading all the modules require(["jquery", "core", "eventMgr", "synchronizer", "publisher", "mediaImporter", "css", themeModule, ], function($, core, eventMgr) { + + if(typeof(noStart) !== 'undefined' && noStart) { + return; + } $(function() { diff --git a/views/error_404.html b/views/error_404.html index 4e1effb5..87d46b82 100644 --- a/views/error_404.html +++ b/views/error_404.html @@ -2,7 +2,7 @@ - StackEdit - Error 404 + StackEdit - 404