alphacreatesys / ckeditor4
集成 CKEDITOR 至 laravel-admin
v1.0.0
2023-12-11 06:09 UTC
Requires
- php: >=7.0.0
- encore/laravel-admin: ~1.6
Requires (Dev)
- phpunit/phpunit: ~6.0
This package is auto-updated.
Last update: 2024-09-05 01:23:16 UTC
README
这是一个 laravel-admin
扩展,它将 CKEDITOR
集成到 laravel-admin
表单中。
屏幕截图
安装
composer require laravel-admin-ext/ckeditor
然后
php artisan vendor:publish --tag=laravel-admin-ckeditor
配置
在 config/admin.php
文件的 extensions
部分,添加属于此扩展的一些配置。
'extensions' => [ 'ckeditor' => [ //Set to false if you want to disable this extension 'enable' => true, // Editor configuration 'config' => [ ] ] ]
编辑器的配置可以在CKEditor 文档中找到,例如配置语言和高度。
'config' => [ 'lang' => 'zh-CN', 'height' => 500, ]
使用方法
在表单中使用它
$form->ckeditor('content'); // Set config $form->ckeditor('content')->options(['lang' => 'fr', 'height' => 500]);
捐赠
通过捐赠一小笔钱帮助项目继续开发。提前感谢。
许可证
许可协议为MIT 许可证 (MIT)。