From 56947722d3142b7b4bb25862130134cb2ddb5cc5 Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Fri, 8 Dec 2017 16:54:49 +0000 Subject: [PATCH] Add a container component (like bootstrap's). Just meant to help with sizing. --- src/Container.css | 21 +++++++++++++++++++++ src/Container.tsx | 7 +++++++ 2 files changed, 28 insertions(+) create mode 100644 src/Container.css create mode 100644 src/Container.tsx diff --git a/src/Container.css b/src/Container.css new file mode 100644 index 0000000..31d9f3d --- /dev/null +++ b/src/Container.css @@ -0,0 +1,21 @@ +.Container { + padding-right: 15px; + padding-left: 15px; + margin-right: auto; + margin-left: auto; +} +@media (min-width: 768px) { + .Container { + width: 750px; + } +} +@media (min-width: 992px) { + .Container { + width: 970px; + } +} +@media (min-width: 1200px) { + .Container { + width: 1170px; + } +} diff --git a/src/Container.tsx b/src/Container.tsx new file mode 100644 index 0000000..dfff09c --- /dev/null +++ b/src/Container.tsx @@ -0,0 +1,7 @@ +import * as React from 'react'; + +import './Container.css'; + +export default ({children}: {children: any}) => ( +
{children}
+);