!MMqDFaFUehZZVwknKE:matrix.org

Draftail

51 Members
A configurable rich text editor built with Draft.js https://www.draftail.org/21 Servers

Load older messages


SenderMessageTime
9 Sep 2019
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool Thibaud - is this something you recognize? > const initialContent = { entityMap: {}, blocks: [] } > const initialEditorState = createEditorStateFromRaw(initialContent) I get an error on the 2nd line: “TypeError: cannot read property ‘getKey’ of undefined” This is nearly a cut-paste from your docs, so not sure what I’m missing. 16:16:42
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool Looks like you need at least this: >>> { entityMap: {}, blocks: [{text: ‘’, type: ‘unstyled’}]}) } 20:20:34
10 Sep 2019
@_slack_wagtailcms_UJ8V8S3M3:matrix.orgthp44 changed their profile picture.15:31:37
12 Sep 2019
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud sharpertool yep – there is a bug / implementation detail in the Draft.js conversion that means the content needs to at least have one block 13:47:45
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud (edited) ... one block => ... one block in it 13:47:46
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud The editor wouldn’t be usable anyway if it was initialised with "no blocks", but the way this fails is a bit annoying 13:48:21
@_slack_wagtailcms_U0LQA2BFT:matrix.orgmattwestcott changed their profile picture.15:18:06
@_slack_wagtailcms_U6VSCTBH6:matrix.orgscotchester changed their profile picture.15:51:32
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool changed their profile picture.21:44:16
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool
In reply to@_slack_wagtailcms_U0ME9SGR1:matrix.org
The editor wouldn’t be usable anyway if it was initialised with "no blocks", but the way this fails is a bit annoying
Well, maybe the example can be updated to represent the minimal required value
21:44:27
@_slack_wagtailcms_U4N6SF7K5:matrix.orgflipperpa changed their profile picture.23:21:24
13 Sep 2019
@_slack_wagtailcms_U0L1Z4JMC:matrix.orgtom changed their profile picture.05:10:38
@_slack_wagtailcms_U7KV2C319:matrix.orgsonny changed their profile picture.08:27:32
@_slack_wagtailcms_U1HDLHL9M:matrix.orgcoenvanderkamp changed their profile picture.09:44:05
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud changed their profile picture.14:33:15
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud
In reply to@_slack_wagtailcms_U9DQ4PP9R:matrix.org
Well, maybe the example can be updated to represent the minimal required value
can you show me which example this is from?
14:33:17
18 Sep 2019
@_slack_wagtailcms_UJHDYNXJP:matrix.orgEric Sherman changed their profile picture.13:39:20
@_slack_wagtailcms_UJHDYNXJP:matrix.orgEric Sherman changed their profile picture.16:16:12
@_slack_wagtailcms_UJHDYNXJP:matrix.orgEric Sherman can you use the 'placeholder' prop in draftail in wagtail when declaring rich text blocks to set placeholder text for that block? 16:16:12
@_slack_wagtailcms_U0L1Z4JMC:matrix.orgtom changed their profile picture.16:28:48
@_slack_wagtailcms_U0LQA2BFT:matrix.orgmattwestcott changed their profile picture.20:56:45
19 Sep 2019
@_slack_wagtailcms_UJHDYNXJP:matrix.orgEric Sherman changed their profile picture.02:59:23
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool changed their profile picture.06:33:24
@_slack_wagtailcms_U9DQ4PP9R:matrix.orgsharpertool
In reply to@_slack_wagtailcms_U0ME9SGR1:matrix.org
can you show me which example this is from?
Sorry for the late response, but it’s here > https://www.draftail.org/docs/controlled-component#data-conversion-helpers
06:33:25
@_slack_wagtailcms_U0LQA2BFT:matrix.orgmattwestcott changed their profile picture.08:04:49
@_slack_wagtailcms_U0R212R3M:matrix.orgloicteixeira changed their profile picture.08:44:36
@_slack_wagtailcms_U0L1Z4JMC:matrix.orgtom changed their profile picture.09:00:06
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud changed their profile picture.09:30:51
@_slack_wagtailcms_U0ME9SGR1:matrix.orgThibaud
In reply to@_slack_wagtailcms_U9DQ4PP9R:matrix.org
Sorry for the late response, but it’s here > https://www.draftail.org/docs/controlled-component#data-conversion-helpers
thank you, I’ll fix this now
09:30:52
@_slack_wagtailcms_U4N6SF7K5:matrix.orgflipperpa changed their profile picture.21:04:57

Show newer messages


Back to Room ListRoom Version: 1