Function percentField

  • Creates a percent input field component with percent icon prefix.

    Parameters

    • props: UiPercentFieldProps

      Configuration object

    Returns Element

    A JSX element representing the percent field component

    Basic usage with required props

    percentField({
    name: 'rate',
    label: 'Interest Rate',
    });

    Usage with default value

    percentField({
    name: 'tax',
    label: 'Tax Rate',
    defaultValue: '15',
    placeholder: 'Enter percent',
    required: true,
    disabled: false
    });