import React, { useState, useEffect } from "react"; import './App.css'; class Card extends React.Component{ state = { data: {} } constructor(props) { super(props); this.state.data = props; } render() { return (

{this.state.data.Username}

{this.state.data.Closed}

{this.state.data.UserID}

Verification Photo

); } } function CardImg(data) { return (

Pend: {data.Username}

Avatar

{data.UserID}

) } /* function UserDetail(userID, verification) { const [data, setData] = useState([]); useEffect(() => { fetch( `https://thanos.nightmare.haus/api/user?userID=${userID}` ) .then(res => res.json()) .then(response => { setData(response); }) .catch(error => console.log(error)); }); return (

{data.Nick}

Avatar
Avatar

{data.joined_at}

{data.user.id}

) } */ class Pending extends React.Component { state = { pending: [] } componentDidMount() { const apiUrl = 'https://thanos.nightmare.haus/api/pending'; fetch(apiUrl) .then((response) => response.json()) .then((data) => this.setState({pending: Object.values(data)})); } render() { return (


); } } class Verification extends React.Component { state = { verifications: [] } componentDidMount() { const apiUrl = 'https://thanos.nightmare.haus/api/verifications'; fetch(apiUrl) .then((response) => response.json()) .then((data) => this.setState({verifications: data})); } render() { return (
); } } export { Pending, Verification, } export default Verification;