Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Quote extends Element

인용기호를 편집하는데 사용되는 API 모델입니다The API model used to edit quotation marks.

Methods

Table of Contents
maxLevel3
minLevel3

append(html)

  • html <String> 추가할 HTML <String> HTML String to append.

인자로 넘겨받은 HTML String으로 Element의 뒤쪽에 자식으로 추가합니다The HTML String passed as an argument is added as a child at the back of the Element.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.append('<span>TEXT</span>');

prepend(html)

  • html <String> 추가할 HTML <String> HTML String to append.

인자로 넘겨받은 HTML String으로 Element의 앞쪽에 자식으로 추가합니다The HTML String passed as an argument is added as a child to the front of the Element.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.prepend('<span>TEXT</span>');

remove()

Removes the Element 자신을 제거합니다itself.

Status
subtletrue
colourRed
title모든 Element를 제거할 경우 이후의 작업에서 오류가 발생할 수 있습니다If all elements are removed, errors may occur in subsequent operations.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.remove();

replace(html)

  • html <String> 교체할 <String> The HTML String to replace.

Element 자신을 인자로 넘겨받은 HTML String으로 교체합니다Replaces the element itself with the HTML String passed as an argument.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.replace('<p><span>Quote replaced</span></p>');

setHTML(html)

  • html <String> 인용기호 내부에 설정할 HTML 문자열<String> HTML string to set inside quotes

인자로 넘겨받은 HTML 문자열값을 인용기호의 내부 HTML로 설정합니다.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.setHTML('<p><span>HTML를<p><span>Add 추가합니다HTML. 기존에 입력된 내용은 모두 지워집니다All previously entered information will be erased.</span></p>');

setText(text)

  • text <String> 인용기호 내부에 설정할 Text 문자열

...

  • <String> Text string to set inside quotation marks

Set the text string value passed as an argument to the internal text of quotation marks.

Code Block
languagejs
themeEmacs
var quote = editor.getAPIModelById('id');
quote.setText('텍스트입니다Sample text.');