goobs-frontend
Version:
A comprehensive React-based libary for building modern web applications
46 lines • 1.71 kB
TypeScript
import { default as React } from 'react';
import { FieldStyleOverrides } from '../../Shell';
export interface VLANFieldProps {
initialValue?: string;
/**
* Emits the new VLAN ID as a number. Was previously polymorphic
* `(event | number) => void` — collapsed to `(value: number) => void`
* during the FieldShell migration.
*/
onChange?: (value: number) => void;
label?: string;
helperText?: string;
/** Error message rendered below the input; sets aria-invalid. */
error?: string | boolean;
/** Stable test selector — emitted as `data-field` on the wrapper. */
dataField?: string;
/** Stable test selector — emitted as `data-field-name` on the wrapper. */
dataFieldName?: string;
required?: boolean;
disabled?: boolean;
styles?: FieldStyleOverrides;
/** Array of reserved VLAN IDs that can't be used */
reservedVLANs?: number[];
initialDelay?: number;
repeatInterval?: number;
placeholder?: string;
id?: string;
/**
* Form-engine binding key. Forwarded to the native input for submission and,
* inside a `<Form>`, used to write the numeric VLAN ID into the engine on
* change and mark the field touched on blur; the shell auto-derives
* error/required for this name. Outside a form this is inert.
*/
name?: string;
autoComplete?: string;
}
/**
* A specialized field for VLAN ID entry
* - Validates VLAN ID ranges (1-4094)
* - Provides increment/decrement buttons
* - Supports reserved VLAN ID validation
* - Prevents entry of non-numeric characters
*/
declare const VLANField: React.FC<VLANFieldProps>;
export default VLANField;
//# sourceMappingURL=index.d.ts.map