1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-02-13 11:44:55 +01:00

1935 Commits

Author SHA1 Message Date
Ian Storm Taylor
adb2678732
Rename "state" to "value" everywhere (#1313)
* rename state to value in slate core, as deprecation

* rename all references to state to value in slate core

* migrate slate-base64-serializer

* migrate slate-html-serializer

* migrate slate-hyperscript

* migrate slate-plain-serializer

* migrate slate-prop-types

* migrate slate-simulator

* fix change.setState compat

* deprecate references to state in slate-react

* remove all references to state in slate-react

* remove `value` and `schema` from props to all components

* fix default renderPlaceholder

* fix tests

* update examples

* update walkthroughs

* update guides

* update reference
2017-10-27 13:39:06 -07:00
Ian Storm Taylor
44addc8140 update plugins guide 2017-10-27 13:12:26 -07:00
Ian Storm Taylor
759979f995 add extra code sample to plugins guide 2017-10-27 13:11:30 -07:00
Ian Storm Taylor
8f307b8260
fix to always normalize ancestors of a node (#1310)
* fix to always normalize ancestors of a node

* fix plugins example

* update changelog
2017-10-27 09:36:06 -07:00
Ian Storm Taylor
d4eec124d8 fix duplicate declaration 2017-10-27 09:03:03 -07:00
Tobias Andersen
44b3c8c30c fix broken onSelect event (#1309)
* fix broken onSelect event

* Update after.js
2017-10-27 08:52:52 -07:00
Ian Storm Taylor
ac14038607 update readme and docs 2017-10-26 16:29:04 -07:00
Ian Storm Taylor
a5c4148651 Publish
- slate-base64-serializer@0.1.22
 - slate-dev-logger@0.1.23
 - slate-html-serializer@0.2.8
 - slate-hyperscript@0.2.8
 - slate-plain-serializer@0.2.8
 - slate-prop-types@0.2.8
 - slate-react@0.8.2
 - slate-simulator@0.2.2
 - slate@0.28.2
slate@0.28.2 slate-simulator@0.2.2 slate-react@0.8.2 slate-prop-types@0.2.8 slate-plain-serializer@0.2.8 slate-hyperscript@0.2.8 slate-html-serializer@0.2.8 slate-dev-logger@0.1.23 slate-base64-serializer@0.1.22
2017-10-26 16:26:47 -07:00
Ian Storm Taylor
3ce94b3db7 fix linter 2017-10-26 16:26:16 -07:00
Ian Storm Taylor
5ba34c1152 fix rendering tests 2017-10-26 16:25:32 -07:00
Ian Storm Taylor
6268bac4f4 update readme 2017-10-26 16:23:38 -07:00
Ian Storm Taylor
34c528b156 add benchmarks, update benchmark reporting 2017-10-26 14:46:34 -07:00
Ian Storm Taylor
e0978a31e9 change offset key serialization to allow dashes in keys, fixes #474 2017-10-26 14:06:22 -07:00
Ian Storm Taylor
db6e29fbe3 remove hairspace compat for chrome/safari 2017-10-26 14:04:08 -07:00
Ian Storm Taylor
753b88747e Publish
- slate-base64-serializer@0.1.21
 - slate-dev-logger@0.1.22
 - slate-html-serializer@0.2.7
 - slate-hyperscript@0.2.7
 - slate-plain-serializer@0.2.7
 - slate-prop-types@0.2.7
 - slate-react@0.8.1
 - slate-simulator@0.2.1
 - slate@0.28.1
slate@0.28.1 slate-simulator@0.2.1 slate-react@0.8.1 slate-prop-types@0.2.7 slate-plain-serializer@0.2.7 slate-hyperscript@0.2.7 slate-html-serializer@0.2.7 slate-dev-logger@0.1.22 slate-base64-serializer@0.1.21
2017-10-26 10:38:34 -07:00
Ian Storm Taylor
31b4f67573 fix to reresolve the editor plugin less, add warning (#1300)
* fix to reresolve the editor plugin less, add warning

* update comments
2017-10-26 10:31:09 -07:00
Yifeng Wang
2e1f9c8f63 fix table handler args (#1292) 2017-10-26 09:31:53 -07:00
Ivan Starkov
39338d5c58 Fix wrap-unwrap Block-Inline docs (#1296) 2017-10-26 09:31:00 -07:00
Ian Storm Taylor
1235a0a8c5 fix findRange for text nodes next to inlines (#1298) 2017-10-26 09:26:58 -07:00
Ian Storm Taylor
c170e7940e Merge branch 'master' of github.com:ianstormtaylor/slate 2017-10-26 09:22:44 -07:00
Ian Storm Taylor
2ab806189a update docs 2017-10-26 09:22:06 -07:00
Brandon Johnson
e7b4020ed2 Include Array.prototype.includes polyfill (#1297)
* Include Array.prototype.includes polyfill

In https://github.com/ianstormtaylor/slate/commit/070a700
the `default` feature set was added
and the `Array.prototype.includes` feature removed
from the polyfill.io request.
I think it's great to include the `default` feature set,
but, `Array.prototype.includes` is not included in the `default` set,
so we have to explicitly request it.
IE 11 needs an `Array.prototype.includes` polyfill
in order for the examples to work.

* Update dev.html

* Update index.html
2017-10-26 09:18:02 -07:00
Ian Storm Taylor
b215e5b7ac update docs 2017-10-25 20:23:22 -07:00
Ian Storm Taylor
c22839c6eb add data model guide, update docs 2017-10-25 20:13:52 -07:00
Ian Storm Taylor
5b2e53039a update changelogs 2017-10-25 18:32:58 -07:00
Ian Storm Taylor
3e860a1cbe Publish
- slate-base64-serializer@0.1.20
 - slate-dev-logger@0.1.21
 - slate-html-serializer@0.2.6
 - slate-hyperscript@0.2.6
 - slate-plain-serializer@0.2.6
 - slate-prop-types@0.2.6
 - slate-react@0.8.0
 - slate-simulator@0.2.0
 - slate@0.28.0
slate@0.28.0 slate-simulator@0.2.0 slate-react@0.8.0 slate-prop-types@0.2.6 slate-plain-serializer@0.2.6 slate-hyperscript@0.2.6 slate-html-serializer@0.2.6 slate-dev-logger@0.1.21 slate-base64-serializer@0.1.20
2017-10-25 18:20:37 -07:00
Ian Storm Taylor
f6b92ba710 update simulator 2017-10-25 18:17:36 -07:00
Ian Storm Taylor
fe863c7d47 fix linter 2017-10-25 18:12:39 -07:00
Ian Storm Taylor
e14d8b18d0 optimize toJSON options including, fixes #1281 (#1290) 2017-10-25 18:10:34 -07:00
Ivan Starkov
cd0e577023 Fix IE11 error (#1264)
* Fix IE11 error

* Update find-dom-point.js
2017-10-25 18:09:02 -07:00
Ian Storm Taylor
ed593c732b remove some polyfills (#1288)
* remove some polyfills

* use for-of for iteration when possible
2017-10-25 17:55:18 -07:00
Ian Storm Taylor
509d3d50fc remove rendering from schema & make it expressive (#1262)
* split rendering out of schema

* remove default components

* first stab at new schema

* make default normalizations smarter

* revert to forcing defaults to be verbose?

* refactor reason constants

* split nodes into blocks/inlines

* get tests passing

* restructure schema tests

* add parent test

* cleanup

* remove defaults from schema

* refactor schema rule.nodes validation, update example

* embed schema in state objects

* fixes

* update examples, and fixes

* update walkthroughs

* update docs

* remove old schemas doc page

* add more tests

* update benchmarks
2017-10-25 17:32:29 -07:00
Justin Weiss
6298d5442d Revert "Keep marks after splitting a block (#1273)" (#1289)
This reverts commit 6f676d67712b15216cf611e01dead990ee0dd8c1.

This behavior should be in userland, because there isn't agreement
among text editors on how it should behave.

Resolves #1269.
2017-10-25 17:31:19 -07:00
Ian Storm Taylor
1777fc3959 fix benchmarks
f
2017-10-25 17:17:14 -07:00
Ian Storm Taylor
8b72534f63 Publish
- slate-react@0.7.4
slate-react@0.7.4
2017-10-25 15:38:07 -07:00
Ian Storm Taylor
443be389c3 fix tests 2017-10-25 15:35:32 -07:00
Ian Storm Taylor
d620141efe cleanup void, fix void selections in safari 2017-10-25 15:33:34 -07:00
AlbertHilb
fe0d7fd1ce Reshape Void component. (#1265)
* Reshape `Void` component.
Add some cases where editor blur should be prevented.

* Update tests.
2017-10-25 15:32:10 -07:00
Ian Storm Taylor
3b41f11370 fix 2017-10-25 15:01:34 -07:00
Ian Storm Taylor
070a700130 update examples polyfill to use default and es6 2017-10-25 15:01:27 -07:00
Brandon Johnson
092b8a0e5d Request Array.prototype.includes polyfill (#1287)
Slate uses `Array.prototype.includes`
in at least one place:
https://github.com/ianstormtaylor/slate/blob/b558872/packages/slate/src/schemas/core.js#L62

So, request an `Array.prototype.includes` polyfill
from polyfill.io
if the user's browser needs it,
which is the case with IE 11.

Also requests minified JavaScript,
since this code is used
for the slatejs.org website,
and there's no need to serve
non-minified code there.
2017-10-25 14:59:39 -07:00
Kelly Joseph Price
b558872b56 Fix Edge pasting exception (#1286) 2017-10-25 14:30:33 -07:00
Ian Storm Taylor
3f25e6a902 update plugins guide 2017-10-25 11:18:48 -07:00
Ian Storm Taylor
0694daf26a add plugins guide 2017-10-25 11:04:37 -07:00
Ian Storm Taylor
68680f6754 Publish
- slate-base64-serializer@0.1.19
 - slate-dev-logger@0.1.20
 - slate-html-serializer@0.2.5
 - slate-hyperscript@0.2.5
 - slate-plain-serializer@0.2.5
 - slate-prop-types@0.2.5
 - slate-react@0.7.3
 - slate-simulator@0.1.19
 - slate@0.27.5
slate@0.27.5 slate-simulator@0.1.19 slate-react@0.7.3 slate-prop-types@0.2.5 slate-plain-serializer@0.2.5 slate-hyperscript@0.2.5 slate-html-serializer@0.2.5 slate-dev-logger@0.1.20 slate-base64-serializer@0.1.19
2017-10-24 22:40:47 -07:00
Ian Storm Taylor
8b56027e6d update lockfile 2017-10-24 22:40:14 -07:00
Ryan Yurkanin
fe157efdf2 Making the default for Text.create to have leaves (#1268) 2017-10-24 22:38:38 -07:00
Justin Weiss
6f676d6771 Keep marks after splitting a block (#1273)
If you have, for example, a bold mark, and you hit "Enter", the new
block won't carry over the formatting. Instead, it should (at least if
you start typing right away).

Fixes #1269.
2017-10-24 22:36:49 -07:00
Irwan Fario Subastian
33bfeb8cda Slate base64 serializer and SSR (#1208)
* provide polyfill for btoa and atob

* add fallback for Buffer.from

* fix listing issues

* remove window usage for URIComponent

* remove monkeyPatching and add window check

* fix linter warnings

* update to use isomorphic-base64
2017-10-24 22:33:49 -07:00
Ashutosh Rishi Ranjan
a0a03ba276 Removed data argument from simulator event handlers (#1274)
In `slate-react@0.6.0`: The data argument to event handlers has been removed...

The event handlers generated in the slate-simulator `Simalator` object was
still passing a data argument.
2017-10-24 22:32:48 -07:00