* fixed some bugs with the input event handler on the embeds example, got rid of the non functional 'is selected and is focused' conditions for showing the input.
* fix linting error
Co-authored-by: DamareYoh <34608378+DamareYoh@users.noreply.github.com>
* handle plaintext-only pastes using onPaste handler, regardless of browser
* remove extra console.log; merge code paths in onPaste - they contain the same code
* Allow zero as offset on <anchor> and <focus> inside <selection>
When creating a selection using the <selection> hyperscript tag, you couldn't
set zero as offset on <anchor> and <focus>, because of a faulty falsiness
check. This is fixed by checking if the offset is falsy and explicitly not zero.
* Make sure offset can't be null or undefined on <anchor> and <focus>
Throw exception when offset is strictly null or undefined, on <anchor> and
<focus> when creating a <selection>.
* fix: code blocks's info string
this info string. should be `jsx`
* fix: editor's exec invoke
now, editor.exec() is not available in Slate v0.57.1
so, use editor.insertText() to instead it
* refactor: delete a nerver used value
* update add new chinese translate
update chinese translate to `v0.57.1`
Co-authored-by: Ian Storm Taylor <ian@ianstormtaylor.com>
* fix: Slate editor props
TS2322: Type 'Editor' is not assignable to type 'ReactEditor'.
* revert
* generic type
* generic type
* generic type
* extends Editor
* extends Editor
* infer
* infer
* build: relax transpilation for es modules
ES module output currently includes regenerator runtime functions which
can block strict content security policies. For an ES module output this
isn't required because any runtime supporting ES modules will also
support async/await natively. It is also highly likely that users of the
ES module would also be performing their own transipliation of
async/await and we should not make assumptions on their behalf (some may
prefer promises to regenerator, for example).
This commit splits the babel config into two; an unchanged one for the
UMD output, and another for module output.
* build: override babel settings from plugin