Skip to content
This repository has been archived by the owner on Aug 30, 2023. It is now read-only.

Commit

Permalink
🔥 - working with one header; some redundency del
Browse files Browse the repository at this point in the history
The state is working nicely with one header. In addition I've started to remove redundent components no longer needed. chingu-voyages#94
  • Loading branch information
paulywill committed Apr 29, 2019
1 parent 033a0bc commit 591d7e8
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 138 deletions.
3 changes: 0 additions & 3 deletions client/src/components/Dashboard.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
import React, { Component } from 'react';
import PropTypes from 'prop-types';
//import Layout from '../containers/Layout';
import SocialProfileList from './SocialProfileList';
//import { auth } from '../firebase';
import axios from 'axios';
import HeaderLoggedIn from '../containers/HeaderLoggedIn';
import NewHabit from './NewHabit';
import CheckIn from './check-in';
import CurrentHabit from './CurrentHabit';
Expand Down
47 changes: 24 additions & 23 deletions client/src/components/header.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,31 @@ import React from 'react';

const Header = (props) => (

<div>
{/* Logged in*/}
{props.providerData &&
<header className="headerLogin">
<button
aria-haspopup="true"
aria-expanded={"false"}
id="hamburger-menu" >
<i className="main-button-icon fa fa-bars fa-3x"></i>
</button>
<h1>Habit Tracker</h1>
<img src={props.providerData[0].photoURL}
alt={props.providerData[0].providerName}
className="container__profile--photo" />

<header className="App-header">

{props.providerData && <button

aria-haspopup="true"
aria-expanded={"false"}
id="hamburger-menu" >
<i className="main-button-icon fa fa-bars fa-3x"></i>
</button>}
</header>
}
{/* Not Logged in*/}
{!props.providerData &&
<header >
<h1>Habit Tracker</h1>
</header>
}

<h1>Habit Tracker</h1>


{props.providerData &&

<img src={props.providerData[0].photoURL}
alt={props.providerData[0].providerName}
className="container__profile--photo" />

}

</header>

);
</div>
);

export default Header;
42 changes: 0 additions & 42 deletions client/src/containers/HeaderLoggedIn.js

This file was deleted.

30 changes: 0 additions & 30 deletions client/src/containers/Layout.js

This file was deleted.

40 changes: 0 additions & 40 deletions client/src/containers/withAuthentication.js

This file was deleted.

0 comments on commit 591d7e8

Please sign in to comment.