Browse Source

Disabled text multi-select

tags/2.2.1^2
jeroen.akkerman 10 months ago
parent
commit
18c03985ea
5 changed files with 60 additions and 51 deletions
  1. 1
    0
      .gitignore
  2. 1
    1
      dist/easymde.min.js
  3. 47
    47
      package-lock.json
  4. 3
    3
      package.json
  5. 8
    0
      src/js/easymde.js

+ 1
- 0
.gitignore View File

@@ -7,3 +7,4 @@ node_modules/
7 7
 *.iws
8 8
 .idea/
9 9
 .vscode/
10
+dev_test/

+ 1
- 1
dist/easymde.min.js
File diff suppressed because it is too large
View File


+ 47
- 47
package-lock.json View File

@@ -332,9 +332,9 @@
332 332
             }
333 333
         },
334 334
         "async-done": {
335
-            "version": "1.2.4",
336
-            "resolved": "https://registry.npmjs.org/async-done/-/async-done-1.2.4.tgz",
337
-            "integrity": "sha512-mxc+yISkb0vjsuvG3dJCIZXzRWjKndQ9Zo9zNDJ1K2wh9eP0E0oGmOWm+4cFOvW4dA0tGFImTW5tQJHCtn1kIQ==",
335
+            "version": "1.3.1",
336
+            "resolved": "https://registry.npmjs.org/async-done/-/async-done-1.3.1.tgz",
337
+            "integrity": "sha512-R1BaUeJ4PMoLNJuk+0tLJgjmEqVsdN118+Z8O+alhnQDQgy0kmD5Mqi0DNEmMx2LM0Ed5yekKu+ZXYvIHceicg==",
338 338
             "dev": true,
339 339
             "requires": {
340 340
                 "end-of-stream": "^1.1.0",
@@ -963,9 +963,9 @@
963 963
             "dev": true
964 964
         },
965 965
         "codemirror": {
966
-            "version": "5.37.0",
967
-            "resolved": "https://registry.npmjs.org/codemirror/-/codemirror-5.37.0.tgz",
968
-            "integrity": "sha512-dQaayDJCLU4UJcwg2RM44oFrs0dMNndTp6qxQJF6XI71l1xN3RB4IqiKES0b0rccbARbrD/UBB4t8DNknfaOTw=="
966
+            "version": "5.39.0",
967
+            "resolved": "https://registry.npmjs.org/codemirror/-/codemirror-5.39.0.tgz",
968
+            "integrity": "sha512-vpJRray/0ZCt9FiS7UcVr1JAm6OBdUt6TA/94Q7MScr8TnutVdQWh/WPr0migzaBPQmYvY7I9UZNvbsaLESIuQ=="
969 969
         },
970 970
         "codemirror-spell-checker": {
971 971
             "version": "1.1.2",
@@ -1104,9 +1104,9 @@
1104 1104
             "dev": true
1105 1105
         },
1106 1106
         "copy-props": {
1107
-            "version": "2.0.3",
1108
-            "resolved": "https://registry.npmjs.org/copy-props/-/copy-props-2.0.3.tgz",
1109
-            "integrity": "sha512-Q5jXiqCOvlQc1Nvy2txrVg9ZexZ0UAw9NBQ7/s3cZ7SCAm0WD7NNsLwwcy+xvNwuVBbfkF2+4SBcz1L1AWbtmw==",
1107
+            "version": "2.0.4",
1108
+            "resolved": "https://registry.npmjs.org/copy-props/-/copy-props-2.0.4.tgz",
1109
+            "integrity": "sha512-7cjuUME+p+S3HZlbllgsn2CDwS+5eCCX16qBgNC4jgSTf49qR1VKy/Zhl400m0IQXl/bPGEVqncgUUMjrr4s8A==",
1110 1110
             "dev": true,
1111 1111
             "requires": {
1112 1112
                 "each-props": "^1.3.0",
@@ -1410,9 +1410,9 @@
1410 1410
             }
1411 1411
         },
1412 1412
         "each-props": {
1413
-            "version": "1.3.1",
1414
-            "resolved": "https://registry.npmjs.org/each-props/-/each-props-1.3.1.tgz",
1415
-            "integrity": "sha1-/BOPUeOid0KG1IWOAtbn3kYt4Vg=",
1413
+            "version": "1.3.2",
1414
+            "resolved": "https://registry.npmjs.org/each-props/-/each-props-1.3.2.tgz",
1415
+            "integrity": "sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA==",
1416 1416
             "dev": true,
1417 1417
             "requires": {
1418 1418
                 "is-plain-object": "^2.0.1",
@@ -1999,14 +1999,14 @@
1999 1999
             "dev": true
2000 2000
         },
2001 2001
         "fsevents": {
2002
-            "version": "1.2.3",
2003
-            "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.3.tgz",
2004
-            "integrity": "sha512-X+57O5YkDTiEQGiw8i7wYc2nQgweIekqkepI8Q3y4wVlurgBt2SuwxTeYUYMZIGpLZH3r/TsMjczCMXE5ZOt7Q==",
2002
+            "version": "1.2.4",
2003
+            "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.4.tgz",
2004
+            "integrity": "sha512-z8H8/diyk76B7q5wg+Ud0+CqzcAF3mBBI/bA5ne5zrRUUIvNkJY//D3BqyH571KuAC4Nr7Rw7CjWX4r0y9DvNg==",
2005 2005
             "dev": true,
2006 2006
             "optional": true,
2007 2007
             "requires": {
2008 2008
                 "nan": "^2.9.2",
2009
-                "node-pre-gyp": "^0.9.0"
2009
+                "node-pre-gyp": "^0.10.0"
2010 2010
             },
2011 2011
             "dependencies": {
2012 2012
                 "abbrev": {
@@ -2087,7 +2087,7 @@
2087 2087
                     }
2088 2088
                 },
2089 2089
                 "deep-extend": {
2090
-                    "version": "0.4.2",
2090
+                    "version": "0.5.1",
2091 2091
                     "bundled": true,
2092 2092
                     "dev": true,
2093 2093
                     "optional": true
@@ -2265,7 +2265,7 @@
2265 2265
                     }
2266 2266
                 },
2267 2267
                 "node-pre-gyp": {
2268
-                    "version": "0.9.1",
2268
+                    "version": "0.10.0",
2269 2269
                     "bundled": true,
2270 2270
                     "dev": true,
2271 2271
                     "optional": true,
@@ -2374,12 +2374,12 @@
2374 2374
                     "optional": true
2375 2375
                 },
2376 2376
                 "rc": {
2377
-                    "version": "1.2.6",
2377
+                    "version": "1.2.7",
2378 2378
                     "bundled": true,
2379 2379
                     "dev": true,
2380 2380
                     "optional": true,
2381 2381
                     "requires": {
2382
-                        "deep-extend": "~0.4.0",
2382
+                        "deep-extend": "^0.5.1",
2383 2383
                         "ini": "~1.3.0",
2384 2384
                         "minimist": "^1.2.0",
2385 2385
                         "strip-json-comments": "~2.0.1"
@@ -3033,9 +3033,9 @@
3033 3033
             }
3034 3034
         },
3035 3035
         "insert-module-globals": {
3036
-            "version": "7.0.6",
3037
-            "resolved": "https://registry.npmjs.org/insert-module-globals/-/insert-module-globals-7.0.6.tgz",
3038
-            "integrity": "sha512-R3sidKJr3SsggqQQ5cEwQb3pWG8RNx0UnpyeiOSR6jorRIeAOzH2gkTWnNdMnyRiVbjrG047K7UCtlMkQ1Mo9w==",
3036
+            "version": "7.1.0",
3037
+            "resolved": "https://registry.npmjs.org/insert-module-globals/-/insert-module-globals-7.1.0.tgz",
3038
+            "integrity": "sha512-LbYZdybvKjbbcKLp03lB323Cgc8f0iL0Rjh8U6JZ7K1gZSf7MxQH191iCNUcLX4qIQ6/yWe4Q4ZsQ+opcReNFg==",
3039 3039
             "dev": true,
3040 3040
             "requires": {
3041 3041
                 "JSONStream": "^1.0.3",
@@ -3584,9 +3584,9 @@
3584 3584
             }
3585 3585
         },
3586 3586
         "marked": {
3587
-            "version": "0.3.19",
3588
-            "resolved": "https://registry.npmjs.org/marked/-/marked-0.3.19.tgz",
3589
-            "integrity": "sha512-ea2eGWOqNxPcXv8dyERdSr/6FmzvWwzjMxpfGB/sbMccXoct+xY+YukPD+QTUZwyvK7BZwcr4m21WBOW41pAkg=="
3587
+            "version": "0.4.0",
3588
+            "resolved": "https://registry.npmjs.org/marked/-/marked-0.4.0.tgz",
3589
+            "integrity": "sha512-tMsdNBgOsrUophCAFQl0XPe6Zqk/uy9gnue+jIIKhykO51hxyu6uNx7zBPy0+y/WKYVZZMspV9YeXLNdKk+iYw=="
3590 3590
         },
3591 3591
         "matchdep": {
3592 3592
             "version": "2.0.0",
@@ -3713,9 +3713,9 @@
3713 3713
             }
3714 3714
         },
3715 3715
         "module-deps": {
3716
-            "version": "6.0.2",
3717
-            "resolved": "https://registry.npmjs.org/module-deps/-/module-deps-6.0.2.tgz",
3718
-            "integrity": "sha512-KWBI3009iRnHjRlxRhe8nJ6kdeBTg4sMi5N6AZgg5f1/v5S7EBCRBOY854I4P5Anl4kx6AJH+4bBBC2Gi3nkvg==",
3716
+            "version": "6.1.0",
3717
+            "resolved": "https://registry.npmjs.org/module-deps/-/module-deps-6.1.0.tgz",
3718
+            "integrity": "sha512-NPs5N511VD1rrVJihSso/LiBShRbJALYBKzDW91uZYy7BpjnO4bGnZL3HjZ9yKcFdZUWwaYjDz9zxbuP7vKMuQ==",
3719 3719
             "dev": true,
3720 3720
             "requires": {
3721 3721
                 "JSONStream": "^1.0.3",
@@ -4244,9 +4244,9 @@
4244 4244
             }
4245 4245
         },
4246 4246
         "pumpify": {
4247
-            "version": "1.5.0",
4248
-            "resolved": "https://registry.npmjs.org/pumpify/-/pumpify-1.5.0.tgz",
4249
-            "integrity": "sha512-UWi0klDoq8xtVzlMRgENV9F7iCTZExaJQSQL187UXsxpk9NnrKGqTqqUNYAKGOzucSOxs2+jUnRNI+rLviPhJg==",
4247
+            "version": "1.5.1",
4248
+            "resolved": "https://registry.npmjs.org/pumpify/-/pumpify-1.5.1.tgz",
4249
+            "integrity": "sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ==",
4250 4250
             "dev": true,
4251 4251
             "requires": {
4252 4252
                 "duplexify": "^3.6.0",
@@ -4824,9 +4824,9 @@
4824 4824
             "dev": true
4825 4825
         },
4826 4826
         "sparkles": {
4827
-            "version": "1.0.0",
4828
-            "resolved": "https://registry.npmjs.org/sparkles/-/sparkles-1.0.0.tgz",
4829
-            "integrity": "sha1-Gsu/tZJDbRC76PeFt8xvgoFQEsM=",
4827
+            "version": "1.0.1",
4828
+            "resolved": "https://registry.npmjs.org/sparkles/-/sparkles-1.0.1.tgz",
4829
+            "integrity": "sha512-dSO0DDYUahUt/0/pD/Is3VIm5TGJjludZ0HVymmhYF6eNA53PVLhnUk0znSYbH8IYBuJdCE+1luR22jNLMaQdw==",
4830 4830
             "dev": true
4831 4831
         },
4832 4832
         "spdx-correct": {
@@ -5233,9 +5233,9 @@
5233 5233
             "integrity": "sha1-VNjrx5SfGngQkItgAsaEFSbJnVo="
5234 5234
         },
5235 5235
         "uglify-js": {
5236
-            "version": "3.3.24",
5237
-            "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.3.24.tgz",
5238
-            "integrity": "sha512-hS7+TDiqIqvWScCcKRybCQzmMnEzJ4ryl9ErRmW4GFyG48p0/dKZiy/5mVLbsFzU8CCnCgQdxMiJzZythvLzCg==",
5236
+            "version": "3.3.25",
5237
+            "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.3.25.tgz",
5238
+            "integrity": "sha512-hobogryjDV36VrLK3Y69ou4REyrTApzUblVFmdQOYRe8cYaSmFJXMb4dR9McdvYDSbeNdzUgYr2YVukJaErJcA==",
5239 5239
             "dev": true,
5240 5240
             "requires": {
5241 5241
                 "commander": "~2.15.0",
@@ -5382,9 +5382,9 @@
5382 5382
             }
5383 5383
         },
5384 5384
         "upath": {
5385
-            "version": "1.0.5",
5386
-            "resolved": "https://registry.npmjs.org/upath/-/upath-1.0.5.tgz",
5387
-            "integrity": "sha512-qbKn90aDQ0YEwvXoLqj0oiuUYroLX2lVHZ+b+xwjozFasAOC4GneDq5+OaIG5Zj+jFmbz/uO+f7a9qxjktJQww==",
5385
+            "version": "1.1.0",
5386
+            "resolved": "https://registry.npmjs.org/upath/-/upath-1.1.0.tgz",
5387
+            "integrity": "sha512-bzpH/oBhoS/QI/YtbkqCg6VEiPYjSZtrHQM6/QnJS6OL9pKUFLqb3aFh4Scvwm45+7iAgiMkLhSbaZxUqmrprw==",
5388 5388
             "dev": true
5389 5389
         },
5390 5390
         "urix": {
@@ -5444,9 +5444,9 @@
5444 5444
             "dev": true
5445 5445
         },
5446 5446
         "v8flags": {
5447
-            "version": "3.0.2",
5448
-            "resolved": "https://registry.npmjs.org/v8flags/-/v8flags-3.0.2.tgz",
5449
-            "integrity": "sha512-6sgSKoFw1UpUPd3cFdF7QGnrH6tDeBgW1F3v9gy8gLY0mlbiBXq8soy8aQpY6xeeCjH5K+JvC62Acp7gtl7wWA==",
5447
+            "version": "3.1.0",
5448
+            "resolved": "https://registry.npmjs.org/v8flags/-/v8flags-3.1.0.tgz",
5449
+            "integrity": "sha512-0m69VIK2dudEf2Ub0xwLQhZkDZu85OmiOpTw+UGDt56ibviYICHziM/3aE+oVg7IjGPp0c83w3eSVqa+lYZ9UQ==",
5450 5450
             "dev": true,
5451 5451
             "requires": {
5452 5452
                 "homedir-polyfill": "^1.0.1"
@@ -5493,9 +5493,9 @@
5493 5493
             }
5494 5494
         },
5495 5495
         "vinyl-fs": {
5496
-            "version": "3.0.2",
5497
-            "resolved": "https://registry.npmjs.org/vinyl-fs/-/vinyl-fs-3.0.2.tgz",
5498
-            "integrity": "sha512-AUSFda1OukBwuLPBTbyuO4IRWgfXmqC4UTW0f8xrCa8Hkv9oyIU+NSqBlgfOLZRoUt7cHdo75hKQghCywpIyIw==",
5496
+            "version": "3.0.3",
5497
+            "resolved": "https://registry.npmjs.org/vinyl-fs/-/vinyl-fs-3.0.3.tgz",
5498
+            "integrity": "sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng==",
5499 5499
             "dev": true,
5500 5500
             "requires": {
5501 5501
                 "fs-mkdirp-stream": "^1.0.0",

+ 3
- 3
package.json View File

@@ -1,6 +1,6 @@
1 1
 {
2 2
     "name": "easymde",
3
-    "version": "2.1.0",
3
+    "version": "2.2.0",
4 4
     "description": "A simple, beautiful, and embeddable JavaScript Markdown editor that easy to use. Features include autosaving and spell checking.",
5 5
     "keywords": [
6 6
         "embeddable",
@@ -16,9 +16,9 @@
16 16
         "url": "https://github.com/ionaru/easy-markdown-editor/issues"
17 17
     },
18 18
     "dependencies": {
19
-        "codemirror": "5.37.0",
19
+        "codemirror": "^5.39.0",
20 20
         "codemirror-spell-checker": "1.1.2",
21
-        "marked": "0.3.19"
21
+        "marked": "^0.4.0"
22 22
     },
23 23
     "devDependencies": {
24 24
         "browserify": "^16.2.2",

+ 8
- 0
src/js/easymde.js View File

@@ -1571,6 +1571,13 @@ EasyMDE.prototype.render = function (el) {
1571 1571
         mode.gitHubSpice = false;
1572 1572
     }
1573 1573
 
1574
+    // eslint-disable-next-line no-unused-vars
1575
+    function configureMouse(cm, repeat, event) {
1576
+        return {
1577
+            addNew: false
1578
+        };
1579
+    }
1580
+
1574 1581
     this.codemirror = CodeMirror.fromTextArea(el, {
1575 1582
         mode: mode,
1576 1583
         backdrop: backdrop,
@@ -1585,6 +1592,7 @@ EasyMDE.prototype.render = function (el) {
1585 1592
         allowDropFileTypes: ['text/plain'],
1586 1593
         placeholder: options.placeholder || el.getAttribute('placeholder') || '',
1587 1594
         styleSelectedText: (options.styleSelectedText != undefined) ? options.styleSelectedText : !isMobile(),
1595
+        configureMouse: configureMouse
1588 1596
     });
1589 1597
 
1590 1598
     this.codemirror.getScrollerElement().style.minHeight = options.minHeight;

Loading…
Cancel
Save