diff --git a/client/scss/components/markdown-content.scss b/client/scss/components/markdown-content.scss index 1ff74f26..1de8538c 100644 --- a/client/scss/components/markdown-content.scss +++ b/client/scss/components/markdown-content.scss @@ -136,9 +136,9 @@ //align-items: center; &:before { - content: $icon-open; + content: '\ee70'; display: inline-block; - font-family: 'core-icons'; + font-family: 'Nucleo Outline'; font-style: normal; font-weight: normal; text-decoration: none; diff --git a/fuse.js b/fuse.js index d81f6de5..2c2a2a3c 100644 --- a/fuse.js +++ b/fuse.js @@ -114,9 +114,9 @@ globalTasks.then(() => { log: true }) - // const bundleVendor = fuse.bundle('vendor').shim(SHIMS).instructions('~ index.js') // eslint-disable-line no-unused-vars - // const bundleApp = fuse.bundle('app').instructions('!> [index.js]') - const bundleApp = fuse.bundle('app').shim(SHIMS).instructions('> index.js') + const bundleVendor = fuse.bundle('vendor').shim(SHIMS).instructions('~ index.js') // eslint-disable-line no-unused-vars + const bundleApp = fuse.bundle('app').instructions('!> [index.js]') + // const bundleApp = fuse.bundle('app').shim(SHIMS).instructions('> index.js') const bundleSetup = fuse.bundle('configure').instructions('> configure.js') switch (mode) { diff --git a/package.json b/package.json index 619731d9..b74fdc56 100644 --- a/package.json +++ b/package.json @@ -149,14 +149,12 @@ "jquery-sticky": "~1.0.4", "lodash-cli": "~4.17.4", "lodash-es": "~4.17.4", - "mathjax": "~2.7.1", "node-sass": "~4.5.3", "nodemon": "~1.11.0", "pug-lint": "~2.4.0", "twemoji-awesome": "~1.0.6", "typescript": "~2.4.1", "uglify-es": "~3.0.24", - "uglify-js": "~3.0.24", "vee-validate": "~2.0.0-rc.6", "vue": "~2.3.4", "vue-clipboards": "~1.0.2", diff --git a/server/libs/markdown.js b/server/libs/markdown.js index 20a847c1..14b0c887 100644 --- a/server/libs/markdown.js +++ b/server/libs/markdown.js @@ -1,5 +1,7 @@ 'use strict' +/* global winston */ + const Promise = require('bluebird') const md = require('markdown-it') const mdEmoji = require('markdown-it-emoji') @@ -123,7 +125,6 @@ mathjax.config({ } } }) -mathjax.start() /** * Parse markdown content and build TOC tree @@ -331,12 +332,14 @@ const processMathjax = (content) => { format: mode.format, speakText: false, svg: true, - state: mathjaxState + state: mathjaxState, + timeout: 30 * 1000 }, result => { if (!result.errors) { resolve(result.svg) } else { - reject(new Error(result.errors.join(', '))) + resolve(currentMatch[0]) + winston.warn(result.errors.join(', ')) } }) }) diff --git a/server/views/auth/login.pug b/server/views/auth/login.pug index a8d1772f..ad860349 100644 --- a/server/views/auth/login.pug +++ b/server/views/auth/login.pug @@ -18,7 +18,7 @@ html(data-logic='login') link(rel='manifest', href='/manifest.json') // JS / CSS - //- script(type='text/javascript', src=appconfig.host + '/js/vendor.js') + script(type='text/javascript', src=appconfig.host + '/js/vendor.js') script(type='text/javascript', src=appconfig.host + '/js/app.js') body diff --git a/server/views/configure/index.pug b/server/views/configure/index.pug index c9dc4cc5..d6c1f62a 100644 --- a/server/views/configure/index.pug +++ b/server/views/configure/index.pug @@ -13,7 +13,7 @@ html(data-logic='configure') script(type='text/javascript'). var appconfig = !{JSON.stringify(conf)}; var runmode = !{JSON.stringify(runmode)}; - //- script(type='text/javascript', src='/js/vendor.js') + script(type='text/javascript', src='/js/vendor.js') script(type='text/javascript', src='/js/configure.js') body diff --git a/server/views/error-forbidden.pug b/server/views/error-forbidden.pug index 87300e5e..0028cf88 100644 --- a/server/views/error-forbidden.pug +++ b/server/views/error-forbidden.pug @@ -18,7 +18,7 @@ html(data-logic='error') link(rel='manifest', href=appconfig.host + '/manifest.json') // JS / CSS - //- script(type='text/javascript', src=appconfig.host + '/js/vendor.js') + script(type='text/javascript', src=appconfig.host + '/js/vendor.js') script(type='text/javascript', src=appconfig.host + '/js/app.js') body(class='is-forbidden') diff --git a/server/views/error-notexist.pug b/server/views/error-notexist.pug index b1cf0498..afe2bb19 100644 --- a/server/views/error-notexist.pug +++ b/server/views/error-notexist.pug @@ -18,7 +18,7 @@ html(data-logic='error') link(rel='manifest', href=appconfig.host + '/manifest.json') // JS / CSS - //- script(type='text/javascript', src=appconfig.host + '/js/vendor.js') + script(type='text/javascript', src=appconfig.host + '/js/vendor.js') script(type='text/javascript', src=appconfig.host + '/js/app.js') body(class='is-notexist') diff --git a/server/views/error.pug b/server/views/error.pug index 4aac07f7..3ef6c43f 100644 --- a/server/views/error.pug +++ b/server/views/error.pug @@ -18,7 +18,7 @@ html(data-logic='error') link(rel='manifest', href=appconfig.host + '/manifest.json') // JS / CSS - //- script(type='text/javascript', src=appconfig.host + '/js/vendor.js') + script(type='text/javascript', src=appconfig.host + '/js/vendor.js') script(type='text/javascript', src=appconfig.host + '/js/app.js') body(class='is-error') diff --git a/server/views/layout.pug b/server/views/layout.pug index 005cd388..4e0f0a9f 100644 --- a/server/views/layout.pug +++ b/server/views/layout.pug @@ -23,7 +23,7 @@ html var siteRoot = '!{appconfig.host}'; //- JS / CSS - //- script(type='text/javascript', src=appconfig.host + '/js/vendor.js') + script(type='text/javascript', src=appconfig.host + '/js/vendor.js') script(type='text/javascript', src=appconfig.host + '/js/app.js') block head diff --git a/yarn.lock b/yarn.lock index cab63c12..1163b817 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4262,7 +4262,7 @@ mathjax-node@~1.1.0: jsdom "7.0 - 9.8" mathjax "*" -mathjax@*, mathjax@~2.7.1: +mathjax@*: version "2.7.1" resolved "https://registry.yarnpkg.com/mathjax/-/mathjax-2.7.1.tgz#c82d2f853b2f58f738e3355329adf0b2d8f8face" @@ -4443,24 +4443,7 @@ mongodb@2.2.27: mongodb-core "2.1.14" readable-stream "2.2.7" -mongoose@*: - version "4.10.8" - resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-4.10.8.tgz#31f44ed7884756f9fd9b7708ddcb3fcb4250f34e" - dependencies: - async "2.1.4" - bson "~1.0.4" - hooks-fixed "2.0.0" - kareem "1.4.1" - mongodb "2.2.27" - mpath "0.3.0" - mpromise "0.5.5" - mquery "2.3.1" - ms "2.0.0" - muri "1.2.1" - regexp-clone "0.0.1" - sliced "1.0.1" - -mongoose@^4.11.1: +mongoose@*, mongoose@^4.11.1: version "4.11.1" resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-4.11.1.tgz#2560b6d89e744b05857d024cab8b316066716e3e" dependencies: @@ -6681,13 +6664,6 @@ uglify-js@2.7.5, uglify-js@^2.6, uglify-js@^2.6.1: uglify-to-browserify "~1.0.0" yargs "~3.10.0" -uglify-js@~3.0.24: - version "3.0.24" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.0.24.tgz#ee93400ad9857fb7a1671778db83f6a23f033121" - dependencies: - commander "~2.9.0" - source-map "~0.5.1" - uglify-to-browserify@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7"