Skip to content

Commit

Permalink
ASDASD
Browse files Browse the repository at this point in the history
  • Loading branch information
thomaspwang committed Oct 16, 2022
1 parent de5851c commit c352bd2
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
8 changes: 6 additions & 2 deletions frontend/src/components/CountdownTimer/CountdownTimer.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
import React from 'react';
import React, { useEffect, useState } from "react";
import "./datetime.css";
import DateTimeDisplay from './DateTimeDisplay';
import { useCountdown } from './useCountdown';
import { currUserAtom } from "../../atoms";
import { useAtom } from "jotai";

const ExpiredNotice = () => {

const [user, setUser] = useAtom(currUserAtom);

const notifyTwilio = async () => {
searchUrl = `http://localhost:4000/twlio/activateAlarm`
const searchUrl = `http://localhost:4000/twlio/activateAlarm`
const response = await fetch(searchUrl, {
mode: 'cors',
method: 'POST',
Expand Down
13 changes: 13 additions & 0 deletions frontend/src/components/FriendSearch/FriendSearch.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import ListItem from '@mui/material/ListItem';
import ListItemButton from '@mui/material/ListItemButton';
import ListItemIcon from '@mui/material/ListItemIcon';
import ListItemText from '@mui/material/ListItemText';
import { useNavigate } from "react-router-dom";
import "./FriendSearch.css";

function FriendSearch() {
Expand All @@ -17,6 +18,7 @@ function FriendSearch() {
const [inputText, setInputText] = useState("");
const [response, setResponse] = useState(null);
const [friends, setFriends] = useState([]);
const navigate = useNavigate();
// const [error, setError] = useState(null);

const getFriends = async () => {
Expand Down Expand Up @@ -84,6 +86,10 @@ function FriendSearch() {
console.log(friends)
}, [])

const navigateAlarm = () => {
navigate("/alarm")
}

return (
<div className="outer-box">
<div className="main">
Expand All @@ -107,6 +113,13 @@ function FriendSearch() {
>
add friend
</Button>
<Button
style={{ backgroundColor: "rgba(186,209,250)", fontFamily: "DM SANS", textTransform: "lowercase", color: "black", boxShadow: "none", marginRight: "10px", marginBottom: "5px"}}
onClick={navigateAlarm}
variant="contained"
>
go back
</Button>
</div>
<p class="title"> current friends</p>
<List style={{ textAlignLast: "center" }}>
Expand Down

0 comments on commit c352bd2

Please sign in to comment.