From c5b6afa37f13e22b213ad3aaabe594315589dfc3 Mon Sep 17 00:00:00 2001 From: virusdefender Date: Thu, 10 Oct 2019 21:50:44 +0800 Subject: [PATCH] support color --- package-lock.json | 56 +++++++++++++++++++++---- package.json | 1 + src/pages/admin/components/Simditor.vue | 3 ++ 3 files changed, 52 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 5f5e5cd..d437235 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10837,15 +10837,41 @@ "dev": true }, "tar-simditor": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/tar-simditor/-/tar-simditor-2.4.3.tgz", - "integrity": "sha512-yHu66vpvY9fw8RDw6a/pAt2XsJRH0tVix8y6sgg7ieiCTA0mnmQUqS4WsiWOhGyFsmPuJq2EnMfvYyG7bHWHcw==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/tar-simditor/-/tar-simditor-3.0.5.tgz", + "integrity": "sha512-fUQhIVVfp2crf2wanLCpDLWp5Mao/i9lTQeS9Mj46/IOF+FuAKKyJ/ULk6+OlH0Ro6VEVGzlr/bQFArJdCfKsQ==", "requires": { - "marked": "^0.3.5", - "simple-hotkeys": "~1.0.3", - "simple-module": "~2.0.6", - "simple-uploader": "~2.0.7", - "to-markdown": "^3.1.0" + "marked": "^0.3.19", + "simple-hotkeys": "github:itargaryen/simple-hotkeys", + "simple-module": "github:itargaryen/simple-module#v2.1.0", + "simple-uploader": "github:itargaryen/simple-uploader#v2.1.0", + "to-markdown": "^3.1.1" + }, + "dependencies": { + "jquery": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.1.1.tgz", + "integrity": "sha1-NHwcIcfgBBFeCk2jLOzgQfrTyKM=" + }, + "simple-hotkeys": { + "version": "github:itargaryen/simple-hotkeys#8a6b2cf19d06100ac86d7ce4d442df08c561b7e9", + "from": "github:itargaryen/simple-hotkeys" + }, + "simple-module": { + "version": "github:itargaryen/simple-module#ea2688c579170eca533cd0bd8ba7f83c8d241a1c", + "from": "github:itargaryen/simple-module#v2.1.0", + "requires": { + "jquery": "=3.1.1" + } + }, + "simple-uploader": { + "version": "github:itargaryen/simple-uploader#79d795ca1ce0b163c0e335fddad5bf9393004780", + "from": "github:itargaryen/simple-uploader#v2.1.0", + "requires": { + "jquery": "=3.1.1", + "simple-module": "github:itargaryen/simple-module#v2.1.0" + } + } } }, "tar-simditor-markdown": { @@ -10860,6 +10886,20 @@ "simple-uploader": "^2.0.7", "tar-simditor": "^2.3.15", "to-markdown": "^3.1.0" + }, + "dependencies": { + "tar-simditor": { + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/tar-simditor/-/tar-simditor-2.4.3.tgz", + "integrity": "sha512-yHu66vpvY9fw8RDw6a/pAt2XsJRH0tVix8y6sgg7ieiCTA0mnmQUqS4WsiWOhGyFsmPuJq2EnMfvYyG7bHWHcw==", + "requires": { + "marked": "^0.3.5", + "simple-hotkeys": "~1.0.3", + "simple-module": "~2.0.6", + "simple-uploader": "~2.0.7", + "to-markdown": "^3.1.0" + } + } } }, "terser": { diff --git a/package.json b/package.json index ce2ca38..3d7c58f 100644 --- a/package.json +++ b/package.json @@ -25,6 +25,7 @@ "papaparse": "^4.4.0", "raven-js": "^3.25.0", "screenfull": "^3.3.2", + "tar-simditor": "^3.0.5", "tar-simditor-markdown": "^1.2.3", "vue": "^2.5.16", "vue-analytics": "^5.10.4", diff --git a/src/pages/admin/components/Simditor.vue b/src/pages/admin/components/Simditor.vue index e612966..93b928c 100644 --- a/src/pages/admin/components/Simditor.vue +++ b/src/pages/admin/components/Simditor.vue @@ -40,6 +40,9 @@ fileKey: 'image', connectionCount: 3, leaveConfirm: 'Uploading is in progress, are you sure to leave this page?' + }, + allowedStyles: { + span: ['color'] } }) this.editor.on('valuechanged', (e, src) => {