import React, { Component, Fragment } from "react";
import { Switch, Route, BrowserRouter } from "react-router-dom";

import AppHeader from "../components/AppHeader";

import HomePage from "../views/HomePage";
import DataShopPage from "../views/DataShopPage/Home";
import LoginPage from "../views/LoginPage";
import RigisterPage from "../views/RigisterPage";
import RigisterShopPage from "../views/RigisterShopPage";
import ShopPage from "../views/ShopPage";
import BeauticianShopPage from "../views/BeauticianShopPage/Home";

class Router extends Component {
  constructor(props) {
    super(props);
    this.state = {};
  }
  render() {
    return (
      <BrowserRouter>
        <Fragment>
          <AppHeader />
          <Switch>
            <Route exact path="/" component={HomePage} />
            <Route path="/DataShopPage" component={DataShopPage} />
            <Route path="/LoginPage" component={LoginPage} />
            <Route path="/RigisterPage" component={RigisterPage} />
            <Route path="/RigisterShopPage" component={RigisterShopPage} />
            <Route path="/ShopPage" component={ShopPage} />
            <Route path="/BeauticianShopPage" component={BeauticianShopPage} />
          </Switch>
        </Fragment>
      </BrowserRouter>
    );
  }
}

export default Router;
