mobiledoc-kit
Advanced tools
Comparing version 0.10.20 to 0.10.21
@@ -86,2 +86,3 @@ 'use strict'; | ||
autofocus: true, | ||
showLinkTooltips: true, | ||
undoDepth: 5, | ||
@@ -162,2 +163,3 @@ undoBlockTimeout: 5000, // ms for an undo event | ||
* @param {Boolean} [options.autofocus=true] Whether to focus the editor when it is first rendered. | ||
* @param {Boolean} [options.showLinkTooltips=true] Whether to show the url tooltip for links | ||
* @param {number} [options.undoDepth=5] How many undo levels will be available. | ||
@@ -314,3 +316,5 @@ * Set to 0 to disable undo/redo functionality. | ||
this._addTooltip(); | ||
if (this.showLinkTooltips) { | ||
this._addTooltip(); | ||
} | ||
@@ -317,0 +321,0 @@ // A call to `run` will trigger the didUpdatePostCallbacks hooks with a |
@@ -31,4 +31,3 @@ 'use strict'; | ||
function sanitize(text) { | ||
text = text.replace(NEWLINES, ''); | ||
return text; | ||
return text.replace(NEWLINES, ' '); | ||
} | ||
@@ -35,0 +34,0 @@ |
@@ -40,2 +40,3 @@ 'use strict'; | ||
*/ | ||
/* eslint-disable complexity */ | ||
function findOffsetInNode(_x, _x2) { | ||
@@ -98,2 +99,3 @@ var _again = true; | ||
} | ||
/* eslint-enable complexity */ | ||
@@ -100,0 +102,0 @@ function constrainNodeTo(node, parentNode, existingOffset) { |
'use strict'; | ||
exports['default'] = '0.10.20'; | ||
exports['default'] = '0.10.21'; |
{ | ||
"name": "mobiledoc-kit", | ||
"version": "0.10.20", | ||
"version": "0.10.21", | ||
"description": "A toolkit for building WYSIWYG editors with Mobiledoc", | ||
@@ -8,4 +8,4 @@ "repository": "https://github.com/bustle/mobiledoc-kit", | ||
"start": "broccoli serve --host 0.0.0.0", | ||
"test:ci": "npm run build:docs && npm run build && testem ci -f testem-ci.json", | ||
"test": "npm run build:docs && npm run build && testem ci -f testem.json", | ||
"test:ci": "npm run build:docs && npm run build && testem ci -f testem-ci.js", | ||
"test": "npm run build:docs && npm run build && testem ci -f testem.js", | ||
"build": "rm -rf dist && broccoli build dist", | ||
@@ -12,0 +12,0 @@ "build:docs": "jsdoc -c ./.jsdoc", |
# Mobiledoc Kit | ||
[![Travis CI Build Status](https://travis-ci.org/bustle/mobiledoc-kit.svg?branch=master)](https://travis-ci.org/bustle/mobiledoc-kit) | ||
[![Sauce Test Status](https://saucelabs.com/browser-matrix/mobiledoc-kit.svg)](https://saucelabs.com/u/mobiledoc-kit) | ||
@@ -4,0 +6,0 @@ |
@@ -46,2 +46,3 @@ import Tooltip from '../views/tooltip'; | ||
autofocus: true, | ||
showLinkTooltips: true, | ||
undoDepth: 5, | ||
@@ -117,2 +118,3 @@ undoBlockTimeout: 5000, // ms for an undo event | ||
* @param {Boolean} [options.autofocus=true] Whether to focus the editor when it is first rendered. | ||
* @param {Boolean} [options.showLinkTooltips=true] Whether to show the url tooltip for links | ||
* @param {number} [options.undoDepth=5] How many undo levels will be available. | ||
@@ -244,3 +246,5 @@ * Set to 0 to disable undo/redo functionality. | ||
this._addTooltip(); | ||
if (this.showLinkTooltips) { | ||
this._addTooltip(); | ||
} | ||
@@ -247,0 +251,0 @@ // A call to `run` will trigger the didUpdatePostCallbacks hooks with a |
@@ -49,4 +49,3 @@ import { | ||
function sanitize(text) { | ||
text = text.replace(NEWLINES, ''); | ||
return text; | ||
return text.replace(NEWLINES, ' '); | ||
} | ||
@@ -53,0 +52,0 @@ |
@@ -38,2 +38,3 @@ import { DIRECTION } from '../utils/key'; | ||
*/ | ||
/* eslint-disable complexity */ | ||
function findOffsetInNode(node, coords) { | ||
@@ -83,2 +84,3 @@ let closest, dyClosest = 1e8, coordsClosest, offset = 0; | ||
} | ||
/* eslint-enable complexity */ | ||
@@ -85,0 +87,0 @@ function constrainNodeTo(node, parentNode, existingOffset) { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3294593
173
47519
449