Skip to content

Commit

Permalink
used tachyons to style landing page
Browse files Browse the repository at this point in the history
relates to issue #3
  • Loading branch information
Armand-Lluka committed Oct 12, 2018
1 parent a14450f commit ce20aaf
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 36 deletions.
39 changes: 21 additions & 18 deletions public/index.html
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="theme-color" content="#000000">
<!--

<head>
<meta charset="utf-8">
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="theme-color" content="#000000">
<!--
manifest.json provides metadata used when your web app is added to the
homescreen on Android. See https://developers.google.com/web/fundamentals/engage-and-retain/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json">
<!--
<link rel="manifest" href="%PUBLIC_URL%/manifest.json">
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Expand All @@ -19,14 +20,15 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title>
</head>
<body>
<noscript>
You need to enable JavaScript to run this app.
</noscript>
<div id="root"></div>
<!--
<title>React App</title>
</head>

<body>
<noscript>
You need to enable JavaScript to run this app.
</noscript>
<div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
Expand All @@ -36,5 +38,6 @@
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</html>
</body>

</html>
20 changes: 11 additions & 9 deletions src/components/App.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import React, { Component } from 'react';
import styled from 'styled-components';
import Header from './Header';
import React, { Component } from "react";
import styled from "styled-components";
import Header from "./Header";

import logo from './assets/logo.png';
import logo from "./assets/logo.png";

const LargeCenteredImage = styled.img.attrs({
className: 'w70 centered',
className: "h-75 "
})``;

class App extends Component {
state = {
response: '',
response: ""
};

componentDidMount() {
Expand All @@ -29,7 +29,7 @@ class App extends Component {
}

callApi = async () => {
const response = await fetch('/api/get_locations');
const response = await fetch("/api/get_locations");
const body = await response.json();
if (response.status !== 200) throw Error(body.message);
console.log(body);
Expand All @@ -38,9 +38,11 @@ class App extends Component {

render() {
return (
<div className="App">
<div className="App vh-100 vw-100">
<Header />
<LargeCenteredImage src={logo} alt="East End Trades Guild" />
<div className=" debug flex justify-center items-center h-75 w-100 ">
<LargeCenteredImage src={logo} alt="East End Trades Guild" />
</div>
</div>
);
}
Expand Down
18 changes: 9 additions & 9 deletions src/components/Header.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
import React from 'react';
import styled from 'styled-components';
import logo from './assets/logo.png';
import burger from './assets/burger.png';
import appTitle from './assets/app_title.png';
import React from "react";
import styled from "styled-components";
import logo from "./assets/logo.png";
import burger from "./assets/burger.png";
import appTitle from "./assets/app_title.png";

const MyHeader = styled.header.attrs({
className: 'w100 pa1 bg-dark-pink flex justify-between items-center',
className: "w100 pa1 flex justify-between items-center"
})``;

const HeaderLogo = styled.img.attrs({
className: 'h3 w3 pa1',
className: "h3 w3 pa1"
})``;

const HeaderTitle = styled.img.attrs({
className: 'w-40',
className: "w-50 mw5"
})``;

const NavBurger = styled.img.attrs({
className: 'pr2',
className: "pr2"
})``;

export default () => (
Expand Down
Binary file modified src/components/assets/app_title.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/components/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit ce20aaf

Please sign in to comment.