reactjs - 如何提交报告表单以便发送到 React Native 中的特定电子邮件
问题描述
我正在尝试使用 React Native 为社交媒体应用程序设置报告发布屏幕,用户可以在其中报告不适当或垃圾邮件的帖子。我只想让用户选择一个原因,然后直接发送到特定的电子邮件。到目前为止,这是我在前端所拥有的:
import React from 'react';
import { Text, View, StyleSheet, TouchableOpacity } from 'react-native';
export default function ReportScreen({ navigation }) {
return (
<View style={styles.container}>
<Text style={{ fontSize: 30 }}>Why are you reporting this?</Text>
<TouchableOpacity
style={styles.panelButton}
onPress={() => {
this.handleSubmit();
}}
>
<Text style={styles.panelButtonTitle}>It's abusive or harmful</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.panelButton}
onPress={() => {
this.handleSubmit();
}}
>
<Text style={styles.panelButtonTitle}>
It's inappropriate or offensive
</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.panelButton}
onPress={() => {
this.handleSubmit();
}}
>
<Text style={styles.panelButtonTitle}>Cancel</Text>
</TouchableOpacity>
<Button onPress={() => navigation.goBack()} title="Go Back" />
</View>
);
}
解决方案
推荐阅读
- .net-core - 将挑战设置为 openidconnect .net core 5.0 时是否可以设置 clientID/tenantId?
- c++ - extern int main(int argc, char* argv[]) 使用?
- visual-studio-code - 当智能感知出现在 vs 代码中时如何导航光标?
- amazon-web-services - 点击链接确认授权放大
- python - 如何在 .kv 中引用应用程序?任何引用都以 AttributeError 结尾
- python - 与您实际录制的内容相比,屏幕录制输出 (mp4) 更短、更快速
- centos8 - snap.microk8s.daemon-kubelet 由于 centos 8 上的容器而无法工作
- c++ - 如何在 C++ 中将名称文件设置为变量?
- ios - Swift:使编程宽度约束适应纵向和横向
- java - 一旦捕获到异常,代码就会终止 java