Demo-Page Repository

Home > mui-country-code-selector > createDefaultRenderInput

createDefaultRenderInput() function

This API is provided as an alpha preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Returns a default function for rendering the input component of the CountryCodeSelector's underlying Autocomplete component. See https://mui.com/material-ui/api/autocomplete/#autocomplete-prop-renderInput for more information about the renderInput prop.

Signature:

export declare function createDefaultRenderInput(label: string, elementWidth: number, shrink?: boolean, variant?: TextFieldVariants): (params: AutocompleteRenderInputParams) => import("react/jsx-runtime").JSX.Element;

Parameters

Parameter

Type

Description

label

string

CountryCodeSelector component’s label passed to the input component.

elementWidth

number

The width of the selector element.

shrink

boolean

(Optional) Indicates whether to shrink the label or not.

variant

TextFieldVariants

(Optional) Variant of the TextField component to use.

**Returns:**

(params: AutocompleteRenderInputParams) => import(“react/jsx-runtime”).JSX.Element

A function for rendering the input component of the CountryCodeSelector's Autocomplete component.