0 Tk

Field

Field

A field, prop or parameter to display in your content.

Usage

Use the name, type, required and default props to display a field component in your content.

Example:

name: required
type: string

The `description` can be set as prop or in the default slot with full **markdown** support.
::field{name="name" type="string" required}
The `description` can be set as prop or in the default slot with full **markdown** support.
::

Props

  • name (required) - string
  • default - string
    • Default: undefined
  • type - string
    • Default: undefined
  • ui - Partial<{ wrapper: string; container: string; name: string; required: string; type: string; label: string; description: string; }>
    • Default: {}
  • description - string
    • Default: undefined
  • required - boolean
    • Default: false

Config

{
  wrapper: 'mt-5',
  container: 'flex items-start gap-x-2.5 font-mono text-sm',
  name: 'rounded-md font-semibold text-primary',
  required: 'text-gray-500 dark:text-gray-400',
  type: 'text-right',
  label: 'flex flex-1 gap-x-2.5',
  description: 'mt-3 mb-0 text-gray-600 dark:text-gray-300 text-sm space-y-3'
}