VitNode
Forms

Text Language Input

Text Language Input is a component that allows users to input text in different languages.

Usage

import { z } from 'zod';
import { zodLanguageInput } from 'vitnode-frontend/helpers/zod';
import { AutoForm } from 'vitnode-frontend/form/auto-form';
import { AutoFormStringLanguageInput } from 'vitnode-frontend/form/fields/text-language-input';
const formSchema = z.object({
  description: zodLanguageInput,
});
<AutoForm
  formSchema={formSchema}
  fields={[
    {
      id: 'description',
      component: AutoFormStringLanguageInput,
    },
  ]}
/>

API Reference

PropTypeDefault
onChange
(value: value: StringLanguage[]]) => void
-
value
StringLanguage[]
-

On this page