Skip to content

@agala-labs/ui

Markdown Editor

Edits and safely previews a focused subset of Markdown.

Examples

Default

Build interfaces with semantic tokens and accessible Vue components.

<AgalaMarkdownEditor v-model="description" preview="split" />

Import

import { AgalaMarkdownEditor, AgalaMarkdownPreview } from '@agala-labs/ui'

API

PropTypeDefaultDescription
modelValuestringMarkdown source.
preview'tab' | 'split' | 'none''tab'Preview presentation.
toolbarbooleantrueShows formatting actions.
rowsnumberEditor height in rows.
maxlength / showCountnumber / booleanLength limit and counter.
disabledbooleanfalseDisables editing.
error / errorMessageboolean / stringValidation state and copy.
sourcestringMarkdownPreview source.

Events

  • update:modelValue(value: string)

Slots

  • No public slots

Accessibility

Toolbar controls have labels; preview exposes a configurable accessible label.

Released under the MIT License.