Skip to content

Commit 153f503

Browse files
committed
chore: update example
1 parent 42d6937 commit 153f503

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

tests/main.tsx

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,14 @@ function TestApp() {
2323
setValue((prv) => {
2424
prv[0].push({
2525
type: 'tag',
26-
attrs: { label: 'sss', class: '----asd---', ddd: 'dddd', sss: 'tttt' },
26+
attrs: {
27+
label: 'sss',
28+
className: '----asd---',
29+
id: 'sad',
30+
ddd: 'dddd',
31+
sss: 'tttt',
32+
style: { color: 'red' },
33+
},
2734
})
2835
return [...prv]
2936
})
@@ -57,6 +64,12 @@ function TestApp() {
5764
onChange={handleOnChange}
5865
placeholder="Write here..."
5966
spellCheck={false}
67+
tagAttrs={{ className: '' }}
68+
// tagView={() => (
69+
// <span data-id="a222" onMouseEnter={() => console.log(ref.current?.editor?.getJSON())}>
70+
// Tag View
71+
// </span>
72+
// )}
6073
// data-testId="input"
6174
// tagAttrs={{ test-attr: '22', test: undefined }}
6275
/>

0 commit comments

Comments
 (0)