본문으로 건너뛰기

clear-text-format

설명

메뉴바/툴바 또는 Event Bus 메서드를 통해 텍스트 서식이 지워질 때 발생합니다

사용법

"clear-text-format": () => boolean | void;
정보

내부 이벤트를 처리하려면 Event Bus 메서드를 사용할 수 있습니다

예제

// RichText 초기화
const editor = new richtext.Richtext("#root", {
// 구성 속성
});
// "clear-text-format" 이벤트 구독
editor.api.on("clear-text-format", () => {
console.log("Text format was cleared");
});
// 텍스트 서식 지우기
editor.api.exec("clear-text-format", {});

변경 로그: 이 이벤트는 v2.0에서 추가되었습니다