Set of properties for MaskedInput.

Note that it is simply the combination of two interfaces; access them to see the properties.

Hierarchy

Properties

accept?: string

Define os tipos de arquivos que o campo de input do tipo "file" aceitará para upload. Example:

     <Input
type="file"
accept=".jpg,.png"
/>
autoCapitalize?: "off" | "sentences" | "on" | "words" | "characters"

Indica se o input deve forçar a capitalização de alguma maneira, os valores aceitos são: "off", "sentences", "on", "words" ou "characters" Example:

<Input autoCapitalize="on" />
autoFocus?: boolean

Indica se o input deve receber foco automaticamente. Example:

<Input autoFocus={true} />
autocomplete?: string

Controla o preenchimento automático de campos de input com valores previamente inseridos pelo usuário. Example:

     <Input
autocomplete="username"
/>
autofocus?: boolean

Quando definido como true, o campo de input receberá o foco automaticamente quando a página for carregada. Example:

     <Input
autofocus={true}
/>
backgroundColor?: string

Background color of component

Check the token table to know which values to use

Example:

   <backgroundColor="background-color" />
border?: string

borderColor sets the color of borders in the design system, allowing you to control the visual appearance of elements' outlines.

Check the token table to know which values to use

Example:

   <borderColor="neutral-900" />
borderBottomStyle?: "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"

Defines the border style of a component. You need to define borderWidth before use this property.

Example:

   <View borderWidth="hairline" borderStyle="dashed" />
borderBottomWidth?: string

borderBottomWidth focuses on adjusting the thickness of the bottom border in the design system, allowing you to fine-tune the visual appearance of the bottom border for elements.

Check the token table to know which values to use

Example:

   <borderBottomWidth="hairline" />
borderColor?: string

Border Color of component

Check the token table to know which values to use

Example:

   <borderColor="neutral-900" />
borderHidden?: boolean

Removes the borders of the input. Example:

<MaskInput borderHidden={true}/>
borderLeftStyle?: "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"

Defines the border style of a component. You need to define borderWidth before use this property.

Example:

   <View borderWidth="hairline" borderStyle="dashed" />
borderLeftWidth?: string

borderBottomWidth is used to control the thickness of the bottom border in the design system, giving you control over the visual appearance of the bottom edges of elements.

Check the token table to know which values to use

Example:

   <borderBottomWidth="hairline" />
borderRadius?: string

borderRadius defines the roundness or curvature of corners in the design system, allowing you to create different shapes and styles for elements by adjusting this property.

Check the token table to know which values to use

Example:

   <borderRadius="micro" />
borderRadiusLeftBottom?: string

borderRadiusLeftBottom defines the roundness or curvature of corners in the design system, allowing you to create different shapes and styles for elements by adjusting this property.

Check the token table to know which values to use

Example:

   <borderRadiusLeftBottom="micro" />
borderRadiusLeftTop?: string

borderRadiusLeftTop defines the roundness or curvature of corners in the design system, allowing you to create different shapes and styles for elements by adjusting this property.

Check the token table to know which values to use

Example:

   <borderRadiusLeftTop="micro" />
borderRadiusRightBottom?: string

borderRadiusRightBottom defines the roundness or curvature of corners in the design system, allowing you to create different shapes and styles for elements by adjusting this property.

Check the token table to know which values to use

Example:

   <borderRadiusRightBottom="micro" />
borderRadiusRightTop?: string

borderRadiusRightTop defines the roundness or curvature of corners in the design system, allowing you to create different shapes and styles for elements by adjusting this property.

Check the token table to know which values to use

Example:

   <borderRadiusRightTop="micro" />
borderRightStyle?: "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"

Defines the border style of a component. You need to define borderWidth before use this property.

Example:

   <View borderWidth="hairline" borderStyle="dashed" />
borderRightWidth?: string

borderRightWidth is used to control the thickness of the right border in the design system, giving you control over the visual appearance of the right edges of elements.

Check the token table to know which values to use

Example:

   <borderRightWidth="hairline" />
borderStyle?: "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"

Defines the border style of a component. You need to define borderWidth before use this property.

Example:

   <View borderWidth="hairline" borderStyle="dashed" />
borderTopStyle?: "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"

Defines the border style of a component. You need to define borderWidth before use this property.

Example:

   <View borderWidth="hairline" borderStyle="dashed" />
borderTopWidth?: string

borderTopWidth specifically adjusts the thickness of the top border in the design system, giving you precise control over the visual aspect of the top border of elements.

Check the token table to know which values to use

Example:

   <borderTopWidth="hairline" />
borderWidth?: string

The borderWidth determines the thickness of borders in the design system. It's a crucial property for defining the visual weight of elements.

Check the token table to know which values to use

Example:

   <borderWidth="hairline" />
color?: string

Text color of components

Check the token table to know which values to use

Example:

   <color="neutral-900" />
contentColor?: boolean

"Use contrast colors for text and background"

Example:

 <View contentColors backgroundColor="primary-500" />
disabled?: boolean

Indica se o input está desabilitado. Example:

<Input disabled={true} />
disabledBtnSearch?: boolean

Indica se o buttonSearch está desabilitado. Ele estará visível, mas não será possível utilizar. Example:

<Input disabledBtnSearch="text" />
display?: "none" | "block" | "flex" | "inline" | "inline-block" | "inline-flex"

Changes the element exhibition

Example:

<display="flex"/>
height?: string | number

Adjust component height

Example:

   <height={100} />
id?: string

"Fills the ID of the element (not very practical)."

Example:

 <View id="id" />
inputMode?: "none" | "text" | "search" | "email" | "numeric" | "tel" | "url" | "decimal"

O atributo inputMode especifica o tipo de entrada esperada em um campo de texto. Ele pode ser usado para sugerir ao navegador o teclado virtual apropriado para exibição em dispositivos móveis.

Valores aceitos:

  • text: Entrada de texto normal.
  • email: Endereços de e-mail.
  • numeric: Entrada numérica.
  • decimal: Entrada numérica com dízimas.
  • tel: Números de telefone.
  • url: URLs.
  • search: Termos de pesquisa.

Example:

<Input inputMode="text" />
mask: string | string[]

Valores aceitos para máscara de input.

Uma máscara de input é um formato pré-definido que permite controlar e validar a entrada de dados em um campo de input. A máscara define a estrutura esperada para o valor do input, indicando, por exemplo, onde devem ser inseridos dígitos numéricos, caracteres especiais ou espaços.

Para representar dígitos numéricos, utilize o caractere "9" na máscara. Os dígitos serão preenchidos conforme a entrada do usuário.

Exemplos de máscaras comumente utilizadas incluem CPF, CNPJ, telefone, CEP, entre outros.

// Máscara com CPF
<Input mask="999.999.999-99" />
// Máscara com CNPJ
<Input mask="99.999.999/9999-99" />

Você pode utilizar também duas máscaras ao mesmo tempo, sendo que a prioridade é a máscara de menor tamanho, quando o tamanho do texto digitado for maior que a máscara atual e ainda houver outra na lista de tamanho maior, ele selecionará automaticamente.

<Input mask={["999.999.999-99", "99.999.999/9999-99"]} />
max?: number

Define o valor máximo permitido em campos de input do tipo "number". Example:

     <Input
type="number"
max={100}
/>
maxHeight?: string | number

Adjust component maximum height

Example:

   <maxHeight={100} />
maxLength?: number

O limite de caracteres do input Example:

<Input maxLength={10}/>
maxWidth?: string | number

Adjust component maximum width

Example:

   <maxwidth={100} />
min?: number

Define o valor mínimo permitido em campos de input do tipo "number". Example:

     <Input
type="number"
min={0}
/>
minHeight?: string | number

Adjust component minimum height

Example:

   <minHeight={100} />
minLength?: number

Quando definido como true, o checkbox será exibido como marcado por padrão. Example:

     <Input
minLength={6}
/>
minWidth?: string | number

Adjust component minimum width

Example:

   <minWidth={100} />
multiple?: boolean

Quando definido como true em campos de input do tipo "file", permite que os usuários selecionem vários arquivos para upload. Example:

     <Input
multiple={20}
/>
name?: string

Define o atributo name do elemento de input. Esse atributo é frequentemente usado em formulários para identificar os campos quando os dados são enviados. Example:

     <Input
name="username"
/>
nextInputOnSubmit?: string

Use esta propriedade para passar o ID do próximo input para dar focus quando o cliente submeter o input

onBlur?: ((e) => void)

Type declaration

    • (e): void
    • Função chamada quando o input perde o foco. Example:

      <Input onBlur={this.myFuncion}/>
      

      Parameters

      • e: any

        O valor do input.

      Returns void

onChange: ((e) => void)

Type declaration

    • (e): void
    • Função chamada quando o valor do input é alterado. Example:

      <Input onChange={this.myFuncion}/>
      

      Parameters

      • e: any

        O valor do input.

      Returns void

onClear?: (() => void)

Type declaration

    • (): void
    • call a function when clear button is pressed Example:

      <Input onClear={() => {  }}/>
      

      Returns void

onFocus?: ((e) => void)

Type declaration

    • (e): void
    • Função chamada quando o input ganha o foco. Example:

      <Input onFocus={this.myFuncion}/>
      

      Parameters

      • e: any

        O valor do input.

      Returns void

onSearchButtonPress?: (() => void)

Type declaration

    • (): void
    • Função que será executada ao apertar o botão de busca do input Example:

        <Input
      type="search"
      onSearchButtonPress={() => console.log("search")}
      />

      Returns void

onSubmit?: ((e) => void)

Type declaration

    • (e): void
    • Função chamada quando o input ganha é submetido. Example:

      <Input onFocus={this.myFuncion}/>
      

      Parameters

      • e: any

        O valor do input.

      Returns void

opacity?: "none" | "solid" | "light" | "half" | "heavy" | "transparent"

Changes the element opacity

Example:

<opacity="light" />
pattern?: string

Especifica uma expressão regular que o valor do campo de input deve corresponder para ser considerado válido. Example:

     <Input
pattern="[A-Za-z]+"
/>
placeholder?: string

A dica ou instrução breve para o usuário sobre o valor esperado no campo de entrada. Example:

<Input placeholder="text" />
readonly?: boolean

Define se o campo de input é somente leitura. Quando definido como true, os usuários não poderão editar o conteúdo do campo. Example:

     <Input
readonly={true}
/>
required?: boolean

Indica se o campo de input é obrigatório. Se definido como true, um aviso será exibido se o usuário tentar enviar o formulário sem preencher este campo. Example:

     <Input
required={true}
/>
searchButtonVariant?: "solid" | "ghost" | "icon"

Variantes visuais do input Example:

     <Input
type="search"
searchButtonVariant="ghost"
/>
showClearInput?: boolean

Indica se o botão que limpa o input está visível. Example:

  <Input
type="search"
showClearInput={false}
/>
showSearchButton?: boolean

Exibe o botão de busca Você pode utilizar um type="search" e mesmo assim não mostrar o botão de pesquisa utilizando showSearchButton={false} O valor padrão é false, mas quando type=search o valor padrão é true. Example:

     <Input
type="search"
showSearchButton={false}
/>
size?: number

Especifica a largura visual do campo de input, geralmente em caracteres ou pixels, dependendo da implementação. Example:

     <Input
size={20}
/>
spellcheck?: boolean

Determina se o corretor ortográfico do navegador deve verificar o conteúdo do campo de input. Example:

     <Input
spellcheck={true}
/>
step?: number

Especifica a largura visual do campo de input, geralmente em caracteres ou pixels, dependendo da implementação. Example:

       <Input
type="number"
step={0.5}
/>
transform?: string

"Prepare a position transforming of element"

Example:

 <View transform="rotate(45deg)" />
transition?: string

"Prepare a transition of visual state change"

Example:

 <View transition="background-color 0.5s ease-in-out" />
type?: "number" | "text" | "search" | "file" | "password" | "email"

O tipo de input. Valores aceitos: "text", "number", "password", "email", "file", "search" Example:

<Input type="text" />
value?: any

O valor atual do input. Example:

<Input value="text" />
visibility?: "hidden" | "visible" | "collapse"

Changes the element visibility

Example:

<visibility="visible" />
visualState?: "success" | "danger" | "warning"

"Determines the visual state of the component and its children."

Example:

 <View visualState="success" />
width?: string | number

Adjust component width

Example:

   <width={100} />