- StyledText
- PressableButton
- TouchableOpacityButton
- Link
- checkbox
- input
- Toast
- Ratings
- Pagination
- Dropdown picker
Modal
https://reactnative.dev/docs/modal
StyledText
<StyledText>
Home
</StyledText>
Property | Description |
children | Child elements or content to be rendered. |
style (optional) | Styling information for the component. |
numberOfLines (optional) Number of lines to limit the content (used in text components). |
PressableButton or TouchableOpacityButton
<PressableButton onPress = {()=> { }} text = { 'Home'} />
Property | Description |
text (optional) | The text or label to be displayed on the button. |
onPress (optional) | A function to be executed when the button is pressed. |
disableStyle (optional) | Styling for the button when it's disabled. |
containerStyle (optional) | Additional container style for the button. |
disabled (optional) | If true , the button is in a disabled state. |
image (optional) | An image component or source to be displayed on the button. |
image_url (optional) | URL or source for the image to be displayed on the button. |
imageStyle (optional) | Styling for the image component. |
textStyle (optional) | Styling for the text on the button. |
These descriptions provide a detailed explanation of each property, its data type, and the role it plays in the buttonPropsType
type definition. You can use this table to better understand the purpose of each property and how to use them in your code or documentation.
Link
<Link href = '/path?name=Branch&products=[Journeys,Email,Universal%20Ads]' >
lorem
</Link>
Property | Description |
href | The URL or link destination. |
children | Child elements or content to be displayed as the link text. |
style (optional) | Styling information for the link. |
Checkbox
<Checkbox isChecked = { isChecked } setChecked = { setChecked } />
Property | Description |
isChecked | Indicates whether the checkbox is checked. |
setChecked | A function to update the isChecked state. |
style (optional) | Styling information for the checkbox. |
asset (optional) | Defines assets for the checked and unchecked image. |
Ratings
<Ratings rating = { 10} size = { 10} />
Property | Description |
size (optional) | Specifies the size of the component. |
rating | Represents the rating value. |
asset (optional) | Defines assets for the filled and empty image. |
Toast
Toast({ text: noResultsFoundPlaceholder })
Property | Description |
type (optional) | Specifies the type of the component. |
text | Contains the text content. |
Input
<Input
setValue = { setEmail }
value = { email }
placeholder = { "emailTr"}
toast = { "email_error"}
pattern = {/^[0-9]/}
/>
Property | Description |
autoFocus (optional) | Determines if the input should receive focus automatically. |
containerStyle (optional) | Styling information for the container of the input. |
style (optional) | Styling information for the input component. |
asset (optional) | Specifies an asset associated with the input. |
value | Contains the current value of the input. |
multiline (optional) | Indicates if the input allows multiple lines of text. |
setValue | A function to set or update the input value. |
defaultValue (optional) | Provides a default value for the input. |
placeholder (optional) | Displays a placeholder text in the input field. |
pattern (optional) | Defines a regular expression pattern for input validation. |
toast (optional) | A message or toast to display as feedback for the input. |
type (optional) | password or text |
Pagination
<Pagination
currentPage = { 10}
getLastPage = { 100} pageHandle = {() => { }}
disableButton = {{
bg: 'red',
text: 'white'
}}
button = {{
bg: 'gold',
text: "white",
borderWidth: 1,
borderColor: 'red',
}}
/>
| Property | Description |
| --------------------- --------------------------------------------- |
| disableButton
(optional) | Configurations for a disabled button. |
| button
(optional) | Configurations for an enabled button. |
| pageHandle
| A function or handler for page management. |
| currentPage
| Represents the current page or state. |
| getLastPage
| A function or handler to retrieve the last page. |
Dropdown picker
<View>
<DropDownPicker
multipleConfig={
{
hasMultiple: true,
storeValue: storeValue,
resetTitle: "Reset",
selectedTitle: "Selected",
setStoreValue: setStoreValue
}
}
items = {
[{ label: '4545', value: "FFFFFFsFF" },
{ label: '4545', value: "FFFFFfFFF" },
{ label: '4545', value: "FFFFsfFFFF" },
{ label: '4545', value: "FFFFFFFF" },
{ label: '4545', value: "FFFFfFFFF" },]
}
/>
</View>
type DropDownPickerProps = {
placeholderConfig?: {
noResultsFoundPlaceholder?: string,
searchPlaceholder?: string,
placeholder?: string,
},
multipleConfig?: {
asset?: {
checked?: number,
unchecked?: number
}
hasMultiple: boolean,
setStoreValue: React.Dispatch<any[]>,
storeValue: any[],
selectedTitle: string,
resetTitle: string,
}
singleConfig?: {
value: {
id?: number | string,
label: string;
value: string;
},
defaultValue: {
id?: number | string,
label: string;
value: string;
},
setValue: React.Dispatch<React.SetStateAction<{
id?: number | string,
label: string;
value: string;
}>>
}
hiddenArrow?: boolean,
imageStyle?: ViewStyle | TextStyle | ImageStyle | object,
textStyle?: ViewStyle | TextStyle | ImageStyle | object,
width?: number,
disable?: boolean,
disableStyle?: ViewStyle | TextStyle | ImageStyle | object,
containerStyle?: ViewStyle | TextStyle | ImageStyle | object,
items: {
id?: number | string,
label: string;
value: string;
}[],
animationType?: "slide" | "fade"
asset?: number,
}
Property | Description |
placeholderConfig | Configuration for the placeholder text, including noResultsFoundPlaceholder , searchPlaceholder , and placeholder . |
multipleConfig | Configuration for multiple selections, including asset , hasMultiple , setStoreValue , storeValue , selectedTitle , and resetTitle . |
singleConfig | Configuration for single selection, including value , defaultValue , and setValue . |
hiddenArrow | A boolean indicating whether the arrow icon is hidden. |
imageStyle | Styling for the image within the component. |
textStyle | Styling for the text within the component. |
width | The width of the component. |
disable | A boolean indicating whether the component is disabled. |
disableStyle | Styling for the disabled component. |
containerStyle | Styling for the component container. |
items | An array of objects representing selectable items with properties id , label , and value . |
animationType | The type of animation for the dropdown, either 'slide' or 'fade' . |
asset | An optional asset for customization, including checked and unchecked properties. |