Skip to content

Type Alias: REnumFieldProps

ts
type REnumFieldProps = ExtractPublicPropTypes<
  ReturnType<typeof makeREnumFieldProps>
>;

Public props interface for the REnumField component. Includes all VInput props plus enum field-specific options for dynamic choice loading, rendering variants, icon customization, and unified field architecture features.

Example

typescript
// Component props typing
interface MyComponentProps {
  enumFieldProps: REnumFieldProps;
}

// Programmatic prop construction
const fieldProps: REnumFieldProps = {
  renderAs: "select",
  choices: [
    { value: "draft", label: "Draft" },
    { value: "published", label: "Published" },
  ],
  doRefreshChoices: async () => {
    // Load choices from API
  },
  multiple: false,
  label: "Status",
  // ... other VInput props
};