SimpleTextComponentData

@Serializable
data class SimpleTextComponentData(val text: String) : AbstractContentComponentData

简单文本组件数据 用于在章节内容中嵌入纯文本段落

Since

Api 2

Parameters

text

文本内容, 支持多行(\n分隔)

Constructors

Link copied to clipboard
constructor(text: String)

Types

Link copied to clipboard
object Companion

SimpleTextComponentData工厂方法和常量集合

Properties

Link copied to clipboard
open override val id: String

数据组件的唯一标识字符串

Link copied to clipboard

Functions

Link copied to clipboard
open override fun toHtmlElement(context: Context): Element

将数据转化为HTML元素, 用于EPUB导出

Link copied to clipboard
open override fun toJsonElement(): JsonElement

将数据序列化为JSON元素