@kukejs/kkeditor-image

0.0.22 • Public • Published

@kukejs/kkeditor-image

基于 ckeditor5 的图片拓展插件

此插件主要是对 image 新增和重写一部分功能

  • 新增 因为 wps 拷贝公式无法获取到有效信息 只能把 rtf 格式中的对应二进制解析成图片显示,但存在的问题是在行内模式下图片是垂直居上的,文字与图片无法对齐
  • 新增 图片信息统计的弹框 可以统一修改图片信息

本地调试

// 执行一个脚本
lerna exec --scope @kukejs/kkeditor-image -- yarn run start
或
// 执行 npm 命令
lerna run --scope @kukejs/kkeditor-image start

使用方式

// 引入数学公式解析
import { VerticalAlign, ImageDetails } from ‘@kukejs/kkeditor-image

// 创建编辑器在 plugins 中引入插件
ClassicEditor
    .create( document.querySelector( '#editor' ), {
        plugins: [ VerticalAlign, ImageDetails, ... ],
        toolbar: [ ... ],
        image: {
        toolbar: [
          'imageStyle:inline',
          'imageStyle:block',
          'imageStyle:side',
          '|',
          'verticalAlign'
        ]
      },

Readme

Keywords

Package Sidebar

Install

npm i @kukejs/kkeditor-image

Weekly Downloads

1

Version

0.0.22

License

ISC

Unpacked Size

33.5 kB

Total Files

24

Last publish

Collaborators

  • xiaohengwang
  • zhaoleyuan
  • kukefe