Skip to main content

css

Adds an extra CSS class to the component root, used to scope style overrides to a single editor or form instance.

Usage

css?: string;

Default: "".

On Editor, the class is appended to the root alongside the built-in classes (wx-editor wx-inline-form for inline and fullscreen, wx-editor wx-panel for modal and sidebar). On Form, it is appended to the .wx-sections body.

Example

<script setup>
import { Editor } from "@svar-ui/vue-editor";

const items = [{ comp: "text", key: "name", label: "Name" }];
const values = { name: "John Doe" };
</script>

<template>
<Editor css="task-editor" :items="items" :values="values" />
</template>

<style scoped>
.task-editor .wx-message {
font-weight: 600;
}
</style>