CKeditor配置标准word文档编辑

一、下载官方给的代码https://download.cksource.com/CKEditor/CKEditor5/17.0.0/ckeditor5-build-decoupled-document-17.0.0.zip

ckeditor4-docs-samples-master\editors\document-editor\index.html 查看效果

二、更简单的是 直接修改 完整的 编辑器源码,找到 contents.css 文件20——30行以内的这个class(.cke_editable)(直接追加到最后也可以)

/*设置标准文档*/
.cke_editable
{
   width: 17cm;
   min-height: 21cm;
   padding: 1cm 2cm 2cm;
   margin: 0.5cm auto;
   border: 1px #D3D3D3 solid;
   background: white;
   box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
   font-size: 13px;
   line-height: 1.6;
   /* Fix for missing scrollbars with RTL texts. (#10488) */
   word-wrap: break-word;
}

附 :工具栏的配置:https://ckeditor.com/latest/samples/toolbarconfigurator/index.html

在这里配置想要的 工具,在代码中使用查看效果,

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值