contenteditable与user-modify

元素可编辑

1
-webkit-user-modify: read-only | read-write | read-write-plaintext-only
1
2
3
4
5
6
contenteditable=""
contenteditable="events"
contenteditable="caret"
contenteditable="plaintext-only"
contenteditable="true"
contenteditable="false"
  • read-only:只读
  • read-write :读写,可以输入富文本
  • read-write-plaintext-only:读写,只能输入纯文本

注:contenteditable中默认可以输入(粘贴)富文本