https://github.com/smallruraldog/wangeditor
laravel vue admin wangeditor扩展
https://github.com/smallruraldog/wangeditor
laravel laravel-vue-admin
Last synced: about 2 months ago
JSON representation
laravel vue admin wangeditor扩展
- Host: GitHub
- URL: https://github.com/smallruraldog/wangeditor
- Owner: SmallRuralDog
- Created: 2020-01-20T16:01:15.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-20T16:11:32.000Z (over 6 years ago)
- Last Synced: 2025-07-23T05:43:16.659Z (11 months ago)
- Topics: laravel, laravel-vue-admin
- Language: PHP
- Size: 25.4 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
laravel vue admin wangeditor扩展
## 安装
```shell script
composer require laravel-vue-admin-component/wangeditor
```
## 使用
```php
$form->item('content','文章内容')->displayComponent(Wangeditor::make());
```
## 属性
编辑器相关属性设置
### 自定义菜单
```php
Wangeditor::make()->menus([
'head', // 标题
'bold', // 粗体
'fontSize', // 字号
'fontName', // 字体
'italic', // 斜体
'underline', // 下划线
'strikeThrough', // 删除线
'foreColor', // 文字颜色
'backColor', // 背景颜色
'link', // 插入链接
'list', // 列表
'justify', // 对齐方式
'quote', // 引用
'emoticon', // 表情
'image', // 插入图片
'table', // 表格
'video', // 插入视频
'code', // 插入代码
'undo', // 撤销
'redo' // 重复
]);
```
### 编辑区域的 z-index
```php
Wangeditor::make()->zIndex(10);
```
### 使用 base64 保存图片
```php
Wangeditor::make()->uploadImgShowBase64();
```
### 配置服务器端地址
```php
Wangeditor::make()->uploadImgServer(route('upload'));
```