From ecd7f64a68c5748791a79ee32c79c0031c07c77e Mon Sep 17 00:00:00 2001 From: chrisgarrity Date: Wed, 17 Aug 2016 09:28:25 -0400 Subject: [PATCH] [WIP] Added react-router to About page, others are currently broken --- src/components/carousel/carousel.jsx | 14 +- src/components/navbar/navbar.jsx | 12 +- src/components/sectionitem/sectionitem.jsx | 33 ++++ src/components/sectionitem/sectionitem.scss | 42 +++++ .../tab-sections/about-sections/videos.jsx | 68 ------- src/components/tabnav/tabnav.jsx | 68 +++---- src/routes.json | 4 +- src/template.html | 41 ++-- src/views/about/about.jsx | 95 ++++++---- src/views/about/about.scss | 51 +---- .../about-sections => views/about}/faq.jsx | 13 +- .../about-sections => views/about}/info.jsx | 11 +- .../about-sections => views/about}/press.jsx | 11 +- src/views/about/videos.jsx | 32 ++++ src/views/index/index.jsx | 176 +++++++++++------- src/views/index/index.scss | 133 +++++++++++++ static/js/lib/content-nav.js | 55 ------ static/js/lib/responsiveslides.min.js | 8 - static/js/lib/simple-expand.min.js | 4 - static/style/content.css | 6 +- static/style/site.css | 7 +- static/style/style.css | 160 ---------------- 22 files changed, 480 insertions(+), 564 deletions(-) create mode 100644 src/components/sectionitem/sectionitem.jsx create mode 100644 src/components/sectionitem/sectionitem.scss delete mode 100644 src/components/tab-sections/about-sections/videos.jsx rename src/{components/tab-sections/about-sections => views/about}/faq.jsx (83%) rename src/{components/tab-sections/about-sections => views/about}/info.jsx (98%) rename src/{components/tab-sections/about-sections => views/about}/press.jsx (90%) create mode 100644 src/views/about/videos.jsx create mode 100644 src/views/index/index.scss delete mode 100755 static/js/lib/content-nav.js delete mode 100755 static/js/lib/responsiveslides.min.js delete mode 100755 static/js/lib/simple-expand.min.js diff --git a/src/components/carousel/carousel.jsx b/src/components/carousel/carousel.jsx index e69539f..a3eab72 100644 --- a/src/components/carousel/carousel.jsx +++ b/src/components/carousel/carousel.jsx @@ -10,7 +10,11 @@ require('./carousel.scss'); */ var Carousel = React.createClass({ type: 'Carousel', + propTypes: { + items: React.PropTypes.array + }, render: function () { + /* TODO: allow override of default settings */ var settings = { dots: true, arrows: false, @@ -21,16 +25,10 @@ var Carousel = React.createClass({ speed: 500, cssEase: 'linear' }; - var images= [ - {id:'s1', url:'images/slide1.png'}, - {id:'s2', url:'images/slide2.png'}, - {id:'s3', url:'images/slide3.png'}, - {id:'s4', url:'images/slide4.png'}, - {id:'s5', url:'images/slide5.png'}, - ]; + return ( - {images.map((item, i) => { return (
) })} + {this.props.items.map((item) => { return (
) })}
); } diff --git a/src/components/navbar/navbar.jsx b/src/components/navbar/navbar.jsx index a35bf0c..a8f2b69 100755 --- a/src/components/navbar/navbar.jsx +++ b/src/components/navbar/navbar.jsx @@ -14,33 +14,33 @@ var NavBar = React.createClass({