Skip to content

Commit

Permalink
Update devdependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
hoon610 committed Oct 6, 2023
1 parent 83d84e3 commit 9242d21
Show file tree
Hide file tree
Showing 9 changed files with 192 additions and 136 deletions.
19 changes: 10 additions & 9 deletions .firebase/hosting.YnVpbGQ.cache
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@ logo192.png,1696095925005,3ee59515172ee198f3be375979df15ac5345183e656720a381b887
logo512.png,1696095925032,ee7e2f3fdb8209c4b6fd7bef6ba50d1b9dba30a25bb5c3126df057e1cb6f5331
manifest.json,1696095924880,aff3449bdc238776f5d6d967f19ec491b36aed5fb7f23ccff6500736fd58494a
robots.txt,1696095925088,bfe106a3fb878dc83461c86818bf74fc1bdc7f28538ba613cd3e775516ce8b49
asset-manifest.json,1696199733846,08e47d03ebb4774602f8901ea785ecb4b932f98e13a2f4ab24f4bec1770a9362
index.html,1696199733846,467e4605f5f554c132ab03031a4416a00d2233d7f44a36d4ad4c598bc3d7bd92
static/css/main.d3e7513f.css,1696199733861,58eb18c5ec604c3d163ed0f3ae80d2f186521e0a7e85e920045add352716e14c
static/js/787.c9af9561.chunk.js,1696199733861,b7e8270026b67559fd3ab1d52eec9189b683a40e2c95a24bd6adfbcb2e017da9
static/css/main.d3e7513f.css.map,1696199733861,d9e981f1eeed0b0e070449b09d90a0ec34d0e229cbcc030246baeeb324f92220
static/js/main.aaaec4ca.js.LICENSE.txt,1696199733861,62ab455d56d208fdf0a3c6e2f9fc69be5b54333ce8313b5e485f22d75dabbba5
static/js/787.c9af9561.chunk.js.map,1696199733861,8b1b58fa9842356515295aa4116fecc978469857dca9c450dedc1b753a62e3b0
static/js/main.aaaec4ca.js,1696199733861,0ea555bce02e6ce92ecac5fcc325c7161ecc77fa2ab1d6355b4096742ad765d6
static/js/main.aaaec4ca.js.map,1696199733862,ef0793737a5cf4b5f98385dd37b070e524aca3f0c7e2a834ea960d7cc52a8a5e
asset-manifest.json,1696561518562,6529f9f47bcd3d97c96d6bc78b3e9b060641ae01fa9165df65b6892066ede3fb
index.html,1696561518562,e80f394a46c852e2e22dfbadc7cc24d56799c269a4f6b47921aa109878af5544
static/css/main.e81cd919.css,1696561518572,a62de4de3d16d2cf9343fb970321db4548839e94e94c934869fe19b6310d6f98
static/js/787.c9af9561.chunk.js,1696561518574,b7e8270026b67559fd3ab1d52eec9189b683a40e2c95a24bd6adfbcb2e017da9
static/css/main.e81cd919.css.map,1696561518572,2ece3480dd63ff5ae994b80910d64e0cc754f940786158a54e135ac65c5933ba
static/js/main.303cc6a5.js.LICENSE.txt,1696561518572,62ab455d56d208fdf0a3c6e2f9fc69be5b54333ce8313b5e485f22d75dabbba5
static/js/787.c9af9561.chunk.js.map,1696561518574,8b1b58fa9842356515295aa4116fecc978469857dca9c450dedc1b753a62e3b0
static/media/logo1.5f8343f11bc51187de6b.png,1696561518572,b81eb8b09e10ac213b31121ec98921ba9fca4a52bdfbceac63be619775be2a3d
static/js/main.303cc6a5.js,1696561518574,dae0d61dd3a57b9a7c4fd4cc666267272ae931f44a30ed51dbb79604ce80e0b0
static/js/main.303cc6a5.js.map,1696561518575,d5ccd1b80890a4d1a91119fab198d390fdfecde7e225417c5b2b947ca162b3af
28 changes: 25 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,8 @@
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@babel/plugin-proposal-private-property-in-object": "^7.21.11"
}
}
77 changes: 39 additions & 38 deletions src/Header.js
Original file line number Diff line number Diff line change
@@ -1,71 +1,72 @@
import React from 'react'
import "./Header.css"
import SearchIcon from '@mui/icons-material/Search';
import HomeIcon from '@mui/icons-material/Home';
import FlagIcon from '@mui/icons-material/Flag';
import SubscriptionsOutlinedIcon from '@mui/icons-material/SubscriptionsOutlined';
import StorefrontOutlinedIcon from '@mui/icons-material/StorefrontOutlined';
import SupervisedUserCircleIcon from '@mui/icons-material/SupervisedUserCircle';
import { Avatar } from '@mui/material';
import { IconButton } from '@mui/material';
import AddIcon from '@mui/icons-material/Add';
import ForumIcon from '@mui/icons-material/Forum';
import NotificationsActiveIcon from '@mui/icons-material/NotificationsActive';
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
import { useStateValue } from './StateProvider';

import React from "react";
import "./Header.css";
import SearchIcon from "@mui/icons-material/Search";
import HomeIcon from "@mui/icons-material/Home";
import FlagIcon from "@mui/icons-material/Flag";
import SubscriptionsOutlinedIcon from "@mui/icons-material/SubscriptionsOutlined";
import StorefrontOutlinedIcon from "@mui/icons-material/StorefrontOutlined";
import SupervisedUserCircleIcon from "@mui/icons-material/SupervisedUserCircle";
import { Avatar } from "@mui/material";
import { IconButton } from "@mui/material";
import AddIcon from "@mui/icons-material/Add";
import ForumIcon from "@mui/icons-material/Forum";
import NotificationsActiveIcon from "@mui/icons-material/NotificationsActive";
import ExpandMoreIcon from "@mui/icons-material/ExpandMore";
import { useStateValue } from "./StateProvider";
import logo1 from "./assets/logo1.png";
function Header() {
const [{user}, dispatch] = useStateValue();
const [{ user }, dispatch] = useStateValue();
return (
<div className='header'>
<div className="header">
<div className="header__left">
<img src="https://upload.wikimedia.org/wikipedia/commons/thumb/b/b8/2021_Facebook_icon.svg/1024px-2021_Facebook_icon.svg.png" alt="facebook logo" />
<img src={logo1} alt="facebook logo" />
<div className="header__input">
<SearchIcon />
<input placeholder="Search Facebook" type="text" />
<SearchIcon />
<input placeholder="Search Facebook" type="text" />
</div>
</div>


<div className="header__center">
<div className="header__option
header__option--active">
<HomeIcon fontSize='large' />
<div
className="header__option
header__option--active"
>
<HomeIcon fontSize="large" />
</div>
<div className="header__option">
<FlagIcon fontSize='large' />
<FlagIcon fontSize="large" />
</div>
<div className="header__option">
<SubscriptionsOutlinedIcon fontSize='large' />
<SubscriptionsOutlinedIcon fontSize="large" />
</div>
<div className="header__option">
<StorefrontOutlinedIcon fontSize='large' />
<StorefrontOutlinedIcon fontSize="large" />
</div>
<div className="header__option">
<SupervisedUserCircleIcon fontSize='large' />
<SupervisedUserCircleIcon fontSize="large" />
</div>
</div>
</div>

<div className="header__right">
<div className="header__info">
<Avatar src={user.photoURL}/>
<h4>{user.displayName}</h4>
<Avatar src={user.photoURL} />
<h4>{user.displayName}</h4>
</div>
<IconButton>
<AddIcon />
<AddIcon />
</IconButton>
<IconButton>
<ForumIcon />
<ForumIcon />
</IconButton>
<IconButton>
<NotificationsActiveIcon />
<NotificationsActiveIcon />
</IconButton>
<IconButton>
<ExpandMoreIcon />
<ExpandMoreIcon />
</IconButton>
</div>
</div>
)
);
}

export default Header
export default Header;
7 changes: 7 additions & 0 deletions src/Login.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
.login > div > img {
object-fit: contain;
height: 150px;
max-width: 200px;
}
.login > div > button {
width: 300px;
Expand All @@ -26,4 +27,10 @@
}
.login{
text-align: center;
}
.login__logo{
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
89 changes: 50 additions & 39 deletions src/Login.js
Original file line number Diff line number Diff line change
@@ -1,52 +1,63 @@
import React from 'react'
import "./Login.css"
import { Button } from '@mui/material'
import { auth, provider } from './firebase'
import { useStateValue } from './StateProvider'
import { actionTypes } from './reducer'
import React from "react";
import "./Login.css";
import { Button } from "@mui/material";
import { auth, provider } from "./firebase";
import { useStateValue } from "./StateProvider";
import { actionTypes } from "./reducer";
import logo from "./assets/logo.png";
import logo1 from "./assets/logo1.png";

function Login() {
const [state, dispatch] = useStateValue();
const [state, dispatch] = useStateValue();

const signIn = () => {
auth.signInWithPopup(provider)
.then(result => {
dispatch({
type: actionTypes.SET_USER,
user: result.user
})
console.log(result)
}).catch(error=> alert(error.message))
}
const signInGuest = () => {
const signIn = () => {
auth
.signInWithPopup(provider)
.then((result) => {
dispatch({
type: actionTypes.SET_USER,
user: {
displayName: "Guest"
},
})
}
type: actionTypes.SET_USER,
user: result.user,
});
console.log(result);
})
.catch((error) => alert(error.message));
};
const signInGuest = () => {
dispatch({
type: actionTypes.SET_USER,
user: {
displayName: "Guest",
},
});
};

return (
<div className='login'>
<div className="login__logo">
<img src="https://upload.wikimedia.org/wikipedia/en/thumb/0/04/Facebook_f_logo_%282021%29.svg/512px-Facebook_f_logo_%282021%29.svg.png?20210818083032" alt="logo" className="src" />
<img src="https://www.logo.wine/a/logo/Facebook/Facebook-Logo.wine.svg" alt="" className="src" />
<h1>Clone!</h1>
<h2>by Hoon Kang <a href='https://github.com/hoon610' target='_blank' rel='noopener noreferrer'>
GitHub
</a></h2>
</div>
<div className="buttons">
<div className="login">
<div className="login__logo">
<img src={logo1} alt="logo" className="logo" />
<img src={logo} alt="" className="logotext" />

<h2>
by Hoon Kang{" "}
<a
href="https://github.com/hoon610"
target="_blank"
rel="noopener noreferrer"
>
GitHub
</a>
</h2>
</div>
<div className="buttons">
<Button type="submit" onClick={signIn}>
Sign in
Sign in
</Button>
<Button type="submit" onClick={signInGuest}>
Sign in as guest
Sign in as guest
</Button>
</div>
</div>
</div>
)
);
}

export default Login
export default Login;
Loading

0 comments on commit 9242d21

Please sign in to comment.