Skip to content

Richtext ​

Feature-rich WYSWYG text editor

Usage ​

Simple Usage ​

preview
vue
<template>
  <p-richtext />
</template>

Control Variants ​

Richtext has 2 control variants, simple and advanced. Default is simple

preview
vue
<template>
  <p-richtext variant="simple" />
  <p-richtext variant="advanced" />
</template>

Placeholder ​

preview
vue
<template>
  <p-richtext placeholder="Write something" />
</template>

Disabled State ​

preview
vue
<template>
  <p-richtext disabled />
</template>

Readonly State ​

preview
vue
<template>
  <p-richtext readonly />
</template>

Error State ​

preview
vue
<template>
  <p-richtext error />
</template>

Binding v-model ​

Textarea value can be binding with v-model.

preview

result:

-
vue
<template>
  <p-richtext v-model="result" />
</template>

API ​

Props ​

PropsTypeDefaultDescription
placeholderString-Input's placeholder
disabledBooleanfalseDisable state
readonlyBooleanfalseReadonly state
errorBooleanfalseError state
acceptString-Whitelist character can be inputted
modelValueString-v-model value

Slots ​

NameDescription
There no slots here

Events ​

NameArgumentsDescription
inputNative Input ObjectEvent when value inputted

See Also ​

Released under the MIT License.