slate-react-placeholder
Advanced tools
Comparing version 0.1.11 to 0.1.12
@@ -101,3 +101,3 @@ (function (global, factory) { | ||
return React.createElement( | ||
React.Fragment, | ||
'span', | ||
null, | ||
@@ -104,0 +104,0 @@ React.createElement( |
@@ -1,1 +0,1 @@ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react")):"function"==typeof define&&define.amd?define(["exports","react"],t):t(e.SlateReactPlaceholder={},e.React)}(this,function(e,t){"use strict";t=t&&t.hasOwnProperty("default")?t.default:t;var r=function(e,t){if(!e)throw new Error("Invariant failed")},n=function(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}return Array.from(e)};e.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=e.placeholder,o=e.when;return r(a,"You must pass `SlateReactPlaceholder` an `options.placeholder` string."),r(o,"You must pass `SlateReactPlaceholder` an `options.when` query."),{decorateNode:function(e,t,r){if(!t.query(o,e))return r();var a=r(),l=e.getFirstText(),i=e.getLastText(),c={anchor:{key:l.key,offset:0},focus:{key:i.key,offset:i.text.length},mark:{type:"placeholder"}};return[].concat(n(a),[c])},renderMark:function(e,r,n){var o=e.children;return"placeholder"===e.mark.type?t.createElement(t.Fragment,null,t.createElement("span",{contentEditable:!1,style:{pointerEvents:"none",display:"inline-block",width:"0",maxWidth:"100%",whiteSpace:"nowrap",opacity:"0.333"}},a),o):n()}}},Object.defineProperty(e,"__esModule",{value:!0})}); | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react")):"function"==typeof define&&define.amd?define(["exports","react"],t):t(e.SlateReactPlaceholder={},e.React)}(this,function(e,t){"use strict";t=t&&t.hasOwnProperty("default")?t.default:t;var r=function(e,t){if(!e)throw new Error("Invariant failed")},n=function(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}return Array.from(e)};e.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=e.placeholder,o=e.when;return r(a,"You must pass `SlateReactPlaceholder` an `options.placeholder` string."),r(o,"You must pass `SlateReactPlaceholder` an `options.when` query."),{decorateNode:function(e,t,r){if(!t.query(o,e))return r();var a=r(),l=e.getFirstText(),i=e.getLastText(),c={anchor:{key:l.key,offset:0},focus:{key:i.key,offset:i.text.length},mark:{type:"placeholder"}};return[].concat(n(a),[c])},renderMark:function(e,r,n){var o=e.children;return"placeholder"===e.mark.type?t.createElement("span",null,t.createElement("span",{contentEditable:!1,style:{pointerEvents:"none",display:"inline-block",width:"0",maxWidth:"100%",whiteSpace:"nowrap",opacity:"0.333"}},a),o):n()}}},Object.defineProperty(e,"__esModule",{value:!0})}); |
@@ -95,3 +95,3 @@ import React from 'react'; | ||
return React.createElement( | ||
React.Fragment, | ||
'span', | ||
null, | ||
@@ -98,0 +98,0 @@ React.createElement( |
@@ -101,3 +101,3 @@ 'use strict'; | ||
return React.createElement( | ||
React.Fragment, | ||
'span', | ||
null, | ||
@@ -104,0 +104,0 @@ React.createElement( |
{ | ||
"name": "slate-react-placeholder", | ||
"description": "A Slate plugin to render a placeholder with React.", | ||
"version": "0.1.11", | ||
"version": "0.1.12", | ||
"license": "MIT", | ||
@@ -21,3 +21,3 @@ "repository": "git://github.com/ianstormtaylor/slate.git", | ||
"mocha": "^2.5.3", | ||
"slate": "^0.44.8", | ||
"slate": "^0.44.9", | ||
"tiny-invariant": "^1.0.1" | ||
@@ -24,0 +24,0 @@ }, |
Sorry, the diff of this file is not supported yet
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
39994