import React from 'react';
import {MainContext} from '../../context'
import Left from './Left'
import Center from './Center'
import Right from './Right'
import './style.sass';

const Header = (props) => {
    const { pathname } = props
     return (
       <MainContext.Consumer>{data => {

        return(
            <header className={`wizrd-site-header ${ pathname !== '/' ? '' : '' }`} >
              <div className="wizrd-main-header">
                { props.children }
              </div>
            </header>
          )
         }}
       </MainContext.Consumer>

     );
};


Header.Left = Left
Header.Center = Center
Header.Right = Right


export default Header