ueditor Ueditor富文本

ueditor Ueditor富文本

Ueditor富文本。

注:第三方小部件默认并未注册,细节见定制小部件。

源代码

源代码。

代码演示

基础样例

最简单的用法。

import { Component } from '@angular/core';import { SFSchema } from '@delon/form';import { NzMessageService } from 'ng-zorro-antd/message';@Component({  selector: 'form-ueditor-simple',  template: `<​sf [schema]="schema" (formSubmit)="submit($event)"><​/sf>`})export class FormUeditorSimpleComponent {    schema: SFSchema = {        properties: {            remark: {                type: 'string',                title: '描述',                ui: {                    widget: 'ueditor'                }            }        }    };    constructor(public msg: NzMessageService) { }    submit(value: any) { this.msg.success(JSON.stringify(value)); }}

API

ui 属性

成员 说明 类型 默认值
[config] 前端配置项说明,见官网 object -
[loading] 初始化提示文本 string 加载中…
[delay] 延迟初始化UEditor,单位:毫秒 number 300
[change] 编辑器内容发生改变时会触发该事件 (html: string) => void -