/
toolbar.js
57 lines (55 loc) · 1.87 KB
/
toolbar.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import * as React from 'react'
import PropTypes from 'prop-types'
// based on the example: http://quilljs.com/standalone/full/
export const QuillToolbar = function({ id }) {
return (
<div className="ql-toolbar" id={`toolbar-${id}`} >
<span className="ql-formats">
<select className="ql-font" />
<select className="ql-size" />
</span>
<span className="ql-formats">
<button className="ql-bold" />
<button className="ql-italic" />
<button className="ql-underline" />
<button className="ql-strike" />
</span>
<span className="ql-formats">
<select className="ql-color" />
<select className="ql-background" />
</span>
<span className="ql-formats">
<button className="ql-script" value="sub" />
<button className="ql-script" value="super" />
</span>
<span className="ql-formats">
<button className="ql-header" value="1" />
<button className="ql-header" value="2" />
<button className="ql-blockquote" />
<button className="ql-code-block" />
</span>
<span className="ql-formats">
<button className="ql-list" value="ordered" />
<button className="ql-list" value="bullet" />
<button className="ql-indent" value="-1" />
<button className="ql-indent" value="+1" />
</span>
<span className="ql-formats">
<button className="ql-direction" value="rtl" />
<select className="ql-align" />
</span>
<span className="ql-formats">
<button className="ql-link" />
<button className="ql-image" />
<button className="ql-video" />
<button className="ql-formula" />
</span>
<span className="ql-formats">
<button className="ql-clean" />
</span>
</div>
)
}
QuillToolbar.propTypes = {
id: PropTypes.number.isRequired,
}