@yoopta/blockquote 4.5.2-rc.0 → 4.5.2-rc.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +57 -5
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,11 +1,63 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Blockquote plugin
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Blockquote is plugin for Yoopta-Editor
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
### Installation
|
|
6
6
|
|
|
7
|
+
```bash
|
|
8
|
+
yarn add @yoopta/blockquote
|
|
7
9
|
```
|
|
8
|
-
const blockquote = require('yoopta-blockquote');
|
|
9
10
|
|
|
10
|
-
|
|
11
|
+
### Usage
|
|
12
|
+
|
|
13
|
+
```jsx
|
|
14
|
+
import Blockquote from '@yoopta/blockquote';
|
|
15
|
+
|
|
16
|
+
const plugins = [Blockquote];
|
|
17
|
+
|
|
18
|
+
const Editor = () => {
|
|
19
|
+
return <YooptaEditor plugins={plugins} />;
|
|
20
|
+
};
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### Default classnames
|
|
24
|
+
|
|
25
|
+
- .yoopta-blockquote
|
|
26
|
+
|
|
27
|
+
### Default options
|
|
28
|
+
|
|
29
|
+
```js
|
|
30
|
+
const Blockquote = new YooptaPlugin({
|
|
31
|
+
options: {
|
|
32
|
+
display: {
|
|
33
|
+
title: 'Blockquote',
|
|
34
|
+
description: 'Capture quote',
|
|
35
|
+
},
|
|
36
|
+
shortcuts: ['>'],
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### How to extend
|
|
42
|
+
|
|
43
|
+
```tsx
|
|
44
|
+
const plugins = [
|
|
45
|
+
Blockquote.extend({
|
|
46
|
+
renders: {
|
|
47
|
+
blockquote: (props) => <YourCustomComponent {...props} />
|
|
48
|
+
},
|
|
49
|
+
options: {
|
|
50
|
+
shortcuts: [`<your custom shortcuts>`],
|
|
51
|
+
align: 'left' | 'center' | 'right',
|
|
52
|
+
display: {
|
|
53
|
+
title: `<your custom title>`,
|
|
54
|
+
description: `<your custom description>`,
|
|
55
|
+
},
|
|
56
|
+
HTMLAttributes: {
|
|
57
|
+
className: '<your classname>',
|
|
58
|
+
// ...other HTML attributes
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
});
|
|
62
|
+
];
|
|
11
63
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yoopta/blockquote",
|
|
3
|
-
"version": "4.5.2-rc.
|
|
3
|
+
"version": "4.5.2-rc.2",
|
|
4
4
|
"description": "Blockquote plugin for Yoopta Editor",
|
|
5
5
|
"author": "Darginec05 <devopsbanda@gmail.com>",
|
|
6
6
|
"homepage": "https://github.com/Darginec05/Editor-Yoopta#readme",
|
|
@@ -34,5 +34,5 @@
|
|
|
34
34
|
"bugs": {
|
|
35
35
|
"url": "https://github.com/Darginec05/Editor-Yoopta/issues"
|
|
36
36
|
},
|
|
37
|
-
"gitHead": "
|
|
37
|
+
"gitHead": "156d69963cc79b2e57eb6347d5cd7063bb7e3792"
|
|
38
38
|
}
|