@@ -79,15 +79,18 @@ const MyComponent = () => {
79
79
80
80
## Props
81
81
82
- | Property | Type | Description | Default |
83
- | ------------------- | -------------------------------------- | ------------------------------------------------------------------ | ------- |
84
- | ` colorScheme ` | ` 'cyan' \| 'green' \| 'gold' \| 'red' ` | The colour scheme of the alert. Mapped to an icon. | 'info' |
85
- | ` title ` | ` string ` | The title of the alert. | |
86
- | ` text ` | ` string ` | The text of the alert. | |
87
- | ` link ` | ` string ` | The text of the link. | |
88
- | ` onPressLink ` | ` () => void ` | A callback function to be called when the link is clicked. | |
89
- | ` onPressIconButton ` | ` () => void ` | A callback function to be called when the icon button is clicked. | |
90
- | ` onClose ` | ` () => void ` | A callback function to be called when the close button is clicked. | |
82
+ | Property | Type | Description | Default |
83
+ | ------------------- | -------------------------------------- | ----------------------------------------------------------------- | ------- |
84
+ | ` colorScheme ` | ` 'cyan' \| 'green' \| 'gold' \| 'red' ` | The colour scheme of the alert. Mapped to an icon. | 'info' |
85
+ | ` title ` | ` string ` | The title of the alert. | |
86
+ | ` text ` | ` string ` | The text of the alert. | |
87
+ | ` link ` | ` string ` | The text of the link. | |
88
+ | ` linkTestID ` | ` string ` | The testID of the link. | |
89
+ | ` iconButtonTestID ` | ` string ` | The testID of the icon button. | |
90
+ | ` onPress ` | ` () => void ` | A callback function to be called when the alert is tapped. | |
91
+ | ` onPressLink ` | ` () => void ` | A callback function to be called when the link is tapped. | |
92
+ | ` onPressIconButton ` | ` () => void ` | A callback function to be called when the icon button is tapped. | |
93
+ | ` onClose ` | ` () => void ` | A callback function to be called when the close button is tapped. | |
91
94
92
95
## Variants
93
96
@@ -106,15 +109,15 @@ If you need to use the Alert component in a more advanced way, you can use the p
106
109
<VStack space = " lg" style = { {flex: 1 }} >
107
110
<AlertTitle >Information</AlertTitle >
108
111
<AlertText >Unlock the power of knowledge with the following information.</AlertText >
109
- <AlertLink onPress = { () => console .log (' Link clicked ' )} >
112
+ <AlertLink onPress = { () => console .log (' Link tapped ' )} >
110
113
<AlertLinkText >Learn more</AlertLinkText >
111
114
<AlertLinkChevron />
112
115
</AlertLink >
113
116
</VStack >
114
- <AlertIconButton onPress = { () => console .log (' Icon button clicked ' )} >
117
+ <AlertIconButton onPress = { () => console .log (' Icon button tapped ' )} >
115
118
<AlertIconButtonChevron />
116
119
</AlertIconButton >
117
- <AlertCloseButton onClose = { () => console .log (' Close button clicked ' )} >
120
+ <AlertCloseButton onClose = { () => console .log (' Close button tapped ' )} >
118
121
<AlertCloseButtonIcon />
119
122
</AlertCloseButton >
120
123
</Alert >
@@ -146,17 +149,17 @@ const MyComponent = () => {
146
149
<AlertTitle >Information</AlertTitle >
147
150
<AlertText >Unlock the power of knowledge with the following information.</AlertText >
148
151
149
- <AlertLink onPress = { () => console .log (' Link clicked ' )} >
152
+ <AlertLink onPress = { () => console .log (' Link tapped ' )} >
150
153
<AlertLinkText >Learn more</AlertLinkText >
151
154
<AlertLinkChevron />
152
155
</AlertLink >
153
156
</VStack >
154
157
{ /* Note: AlertIconButton should not be used with the AlertLink component */ }
155
- <AlertIconButton onPress = { () => console .log (' Icon button clicked ' )} >
158
+ <AlertIconButton onPress = { () => console .log (' Icon button tapped ' )} >
156
159
<AlertIconButtonChevron />
157
160
</AlertIconButton >
158
161
159
- <AlertCloseButton onClose = { () => console .log (' Close button clicked ' )} >
162
+ <AlertCloseButton onClose = { () => console .log (' Close button tapped ' )} >
160
163
<AlertCloseButtonIcon />
161
164
</AlertCloseButton >
162
165
</Alert >
0 commit comments