File tree Expand file tree Collapse file tree 2 files changed +37
-1
lines changed
Expand file tree Collapse file tree 2 files changed +37
-1
lines changed Original file line number Diff line number Diff line change 99 StyleSheet ,
1010 Text ,
1111 TextInput ,
12+ TouchableOpacity ,
1213 TouchableWithoutFeedback ,
1314 View ,
1415} from 'react-native' ;
@@ -176,6 +177,22 @@ function App() {
176177 < Text style = { styles . welcomeSubtitle } >
177178 What can I help you with?
178179 </ Text >
180+ < View style = { styles . suggestionsContainer } >
181+ { [
182+ 'Explain quantum computing in simple terms' ,
183+ 'Write a short poem about coding' ,
184+ 'What are the benefits of on-device AI?' ,
185+ 'Give me 3 fun facts about space' ,
186+ ] . map ( ( prompt , i ) => (
187+ < TouchableOpacity
188+ key = { i }
189+ style = { styles . suggestionChip }
190+ onPress = { ( ) => setUserInput ( prompt ) }
191+ >
192+ < Text style = { styles . suggestionChipText } > { prompt } </ Text >
193+ </ TouchableOpacity >
194+ ) ) }
195+ </ View >
179196 </ View >
180197 </ TouchableWithoutFeedback >
181198 ) }
@@ -253,6 +270,25 @@ const styles = StyleSheet.create({
253270 color : ColorPalette . blueDark ,
254271 textAlign : 'center' ,
255272 } ,
273+ suggestionsContainer : {
274+ flexDirection : 'row' ,
275+ flexWrap : 'wrap' ,
276+ justifyContent : 'center' ,
277+ gap : 8 ,
278+ paddingTop : 16 ,
279+ } ,
280+ suggestionChip : {
281+ borderWidth : 1 ,
282+ borderColor : ColorPalette . blueLight ,
283+ borderRadius : 20 ,
284+ paddingHorizontal : 14 ,
285+ paddingVertical : 8 ,
286+ backgroundColor : '#fafbff' ,
287+ } ,
288+ suggestionChipText : {
289+ fontSize : 13 ,
290+ color : ColorPalette . primary ,
291+ } ,
256292 messageBubble : {
257293 maxWidth : '80%' ,
258294 padding : 12 ,
Original file line number Diff line number Diff line change @@ -2717,7 +2717,7 @@ SPEC CHECKSUMS:
27172717 React-Mapbuffer: 94f4264de2cb156960cd82b338a403f4653f2fd9
27182718 React-microtasksnativemodule: 6c4ee39a36958c39c97b074d28f360246a335e84
27192719 react-native-background-downloader: 114f96122822fa97b06ea0f2250b8e8270696995
2720- react-native-executorch: 86764f0bd936e8ff18fdb30c36343bb01aab54da
2720+ react-native-executorch: 517da022131a15a98ea5337f02a88e7807a1ec3d
27212721 react-native-safe-area-context: befb5404eb8a16fdc07fa2bebab3568ecabcbb8a
27222722 React-NativeModulesApple: ebf2ce72b35870036900d6498b33724386540a71
27232723 React-oscompat: eb0626e8ba1a2c61673c991bf9dc21834898475d
You can’t perform that action at this time.
0 commit comments