@@ -21,21 +21,26 @@ You can find Quill at https://quilljs.com/
2121Run console command
2222
2323```
24- composer require bizley/quill:^3.0
24+ composer require bizley/quill:^3.1
2525```
2626
2727Or add the package to your ` composer.json ` :
2828
2929``` json
3030{
3131 "require" : {
32- "bizley/quill" : " ^3.0 "
32+ "bizley/quill" : " ^3.1 "
3333 }
3434}
3535```
3636
3737and run ` composer update ` .
3838
39+ ### NPM Assets
40+
41+ This package might depend on some NPM packages. Make sure you can fetch them by configuring your
42+ ` composer.json ` properly (i.e. by using https://asset-packagist.org/ - see instructions there).
43+
3944### Usage
4045
4146Use it as an active field extension
@@ -104,7 +109,7 @@ lines are added.
104109
105110### Quill source
106111
107- By default Quill is provided through the CDN (https://cdn.quilljs.com ). You can change the Quill's version set with the
112+ By default, Quill is provided through the CDN (https://cdn.quilljs.com ). You can change the Quill's version set with the
108113current yii2-quill's release by changing ` 'quillVersion' ` parameter but some options may not work correctly in this case.
109114Starting from version 3.0.0 you can use local assets for Quill provided through NPM packet manager - to do
110115so run
@@ -159,7 +164,7 @@ To add this option configure widget with [Formula module](https://quilljs.com/do
159164]
160165```
161166
162- By default KaTeX is provided through the CDN (https://cdn.jsdelivr.net ). You can change the version of KaTeX by setting
167+ By default, KaTeX is provided through the CDN (https://cdn.jsdelivr.net ). You can change the version of KaTeX by setting
163168the ` 'katexVersion' ` parameter. Starting from version 3.0.0 you can use local assets for KaTeX provided through NPM
164169packet manager - to do so run
165170
@@ -193,7 +198,7 @@ To add this option configure widget with [Syntax Highlighter module](https://qui
193198]
194199```
195200
196- By default highlight.js is provided through the CDN (https://cdn.jsdelivr.net ). You can change the version of
201+ By default, highlight.js is provided through the CDN (https://cdn.jsdelivr.net ). You can change the version of
197202highlight.js by setting the ` 'highlightVersion' ` parameter. Starting from version 3.0.0 you can use local assets for
198203highlight.js provided through NPM packet manager - to do so run
199204
@@ -215,3 +220,36 @@ You also need to set `['localAssets' => true]` in Quill's configuration.
215220
216221You can change the default highlight.js stylesheet (for both CDN and local version) by setting the ` 'highlightStyle' `
217222parameter. See [ the list of possible styles] ( https://github.com/isagalaev/highlight.js/tree/master/src/styles ) .
223+
224+ ### Smart Break module
225+
226+ You can add Smart Break (support for shift + enter) by using the
227+ [ quill-smart-break] ( https://github.com/simialbi/quill-smart-break/ ) plugin:
228+
229+ ``` php
230+ [
231+ 'modules' => [
232+ 'smart-breaker' => true,
233+ ],
234+ ]
235+ ```
236+
237+ Starting from version 3.1.0 quill-smart-break is provided through NPM packet manager by local asset. For
238+ previous versions you would have to add it through custom JS (see ` js ` property).
239+ Run
240+
241+ ```
242+ composer require npm-asset/quill-smart-break:^0.1
243+ ```
244+
245+ Or add the package to your ` composer.json ` :
246+
247+ ``` json
248+ {
249+ "require" : {
250+ "npm-asset/quill-smart-break" : " >=0.1.1 <1.0.0"
251+ }
252+ }
253+ ```
254+
255+ You also need to set ` ['localAssets' => true] ` in Quill's configuration.
0 commit comments