@itshixun/qckeditor-vue3 1.0.12 → 1.0.13

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.
Files changed (2) hide show
  1. package/README.md +9 -7
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -24,12 +24,14 @@ npm install vue@^3.0.0 ckeditor5@>=42.0.0
24
24
 
25
25
  ### 引入样式
26
26
 
27
- 在使用组件前,需要先引入 CKEditor 的样式文件:
27
+ 在使用组件前,需要引入本库的样式文件:
28
28
 
29
29
  ```typescript
30
- import 'ckeditor5/ckeditor5.css';
30
+ import '@itshixun/qckeditor-vue3/dist/index.css';
31
31
  ```
32
32
 
33
+ > 本样式文件已内置 CKEditor 5 官方样式,无需再单独引入 `ckeditor5/ckeditor5.css`。
34
+
33
35
  ### 基础编辑器(CKEditor)
34
36
 
35
37
  底层 CKEditor 封装组件,支持任意 CKEditor 构建:
@@ -43,7 +45,7 @@ import 'ckeditor5/ckeditor5.css';
43
45
  import { ref } from 'vue';
44
46
  import { ClassicEditor } from 'ckeditor5';
45
47
  import { CKEditor } from '@itshixun/qckeditor-vue3';
46
- import 'ckeditor5/ckeditor5.css';
48
+ import '@itshixun/qckeditor-vue3/dist/index.css';
47
49
 
48
50
  const content = ref('');
49
51
  const editorConfig = {
@@ -64,7 +66,7 @@ const editorConfig = {
64
66
  <script setup lang="ts">
65
67
  import { ref } from 'vue';
66
68
  import { QCKClassic } from '@itshixun/qckeditor-vue3';
67
- import 'ckeditor5/ckeditor5.css';
69
+ import '@itshixun/qckeditor-vue3/dist/index.css';
68
70
 
69
71
  const content = ref('');
70
72
  const editorConfig = {
@@ -90,7 +92,7 @@ const editorConfig = {
90
92
  <script setup lang="ts">
91
93
  import { ref } from 'vue';
92
94
  import { QCKEditorPro } from '@itshixun/qckeditor-vue3';
93
- import 'ckeditor5/ckeditor5.css';
95
+ import '@itshixun/qckeditor-vue3/dist/index.css';
94
96
 
95
97
  const content = ref('');
96
98
  const editorConfig = {
@@ -110,7 +112,7 @@ const editorConfig = {
110
112
 
111
113
  <script setup lang="ts">
112
114
  import { QCKContent } from '@itshixun/qckeditor-vue3';
113
- import 'ckeditor5/ckeditor5.css';
115
+ import '@itshixun/qckeditor-vue3/dist/index.css';
114
116
 
115
117
  const htmlContent = '<p>Hello <strong>World</strong></p>';
116
118
  </script>
@@ -295,7 +297,7 @@ import type { Props, ExtractEditorType } from '@itshixun/qckeditor-vue3';
295
297
 
296
298
  1. **CKEditor 授权**: 本库使用 CKEditor 5 的 GPL 授权。如需商业使用,请购买 [CKEditor 商业授权](https://ckeditor.com/pricing/)。
297
299
 
298
- 2. **样式文件**: 必须导入 `ckeditor5/ckeditor5.css` 以确保编辑器样式正确。
300
+ 2. **样式文件**: 导入 `@itshixun/qckeditor-vue3/dist/index.css` 即可,该文件已内置 CKEditor 5 官方样式。
299
301
 
300
302
  3. **HTML 清洗**: `QCKContent` 和 `QCKEditorPro` 默认开启 XSS 防护,会自动过滤危险标签和属性。
301
303
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itshixun/qckeditor-vue3",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "description": "Vue3 components for CKEditor 5",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -51,4 +51,4 @@
51
51
  "type": "git",
52
52
  "url": ""
53
53
  }
54
- }
54
+ }