From b27c0bc0633b60b63b308d4d56c3010ba5045346 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Thu, 14 Jan 2016 08:52:46 +0000 Subject: [PATCH] Remove need to specify class on project images --- static/src/js/components/index/project-image.js | 3 ++- static/src/js/components/index/project-images-main.js | 8 +------- static/src/js/components/index/project-images-types.js | 3 --- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/static/src/js/components/index/project-image.js b/static/src/js/components/index/project-image.js index f7bc92e..76bdee5 100644 --- a/static/src/js/components/index/project-image.js +++ b/static/src/js/components/index/project-image.js @@ -5,9 +5,10 @@ var Col = ReactBootstrap.Col; export default class ProjectImage extends React.Component { render() { var animationClass = this.props.isHovered ? 'zoomIn' : 'zoomOut'; + var classes = this.props.data.title.toLowerCase().replace(' ', '-'); return ( -
+
diff --git a/static/src/js/components/index/project-images-main.js b/static/src/js/components/index/project-images-main.js index 52ee695..ba77459 100644 --- a/static/src/js/components/index/project-images-main.js +++ b/static/src/js/components/index/project-images-main.js @@ -5,37 +5,31 @@ var Row = ReactBootstrap.Row; const DATA = [ { - className: 'college', - title: 'College', + title: 'Custom PC', text: 'My time at college was where I learnt most about programming, and discovered my skill and passion for it.', link: '', }, { - className: 'personal', title: 'Personal', text: 'I write code just to write code, but sometimes it serves a purpose.', link: '', }, { - className: 'work', title: 'Work', text: 'I\'m an apprentice software developer at Dabapps, and this is what I\'ve done.', link: '', }, { - className: 'college', title: 'College', text: 'My time at college was where I learnt most about programming, and discovered my skill and passion for it.', link: '', }, { - className: 'personal', title: 'Personal', text: 'I write code just to write code, but sometimes it serves a purpose.', link: '', }, { - className: 'work', title: 'Work', text: 'I\'m an apprentice software developer at Dabapps, and this is what I\'ve done.', link: '', diff --git a/static/src/js/components/index/project-images-types.js b/static/src/js/components/index/project-images-types.js index 0861d05..d5f993a 100644 --- a/static/src/js/components/index/project-images-types.js +++ b/static/src/js/components/index/project-images-types.js @@ -5,19 +5,16 @@ var Row = ReactBootstrap.Row; const DATA = [ { - className: 'college', title: 'College', text: 'My time at college was where I learnt most about programming, and discovered my skill and passion for it.', link: '', }, { - className: 'personal', title: 'Personal', text: 'I write code just to write code, but sometimes it serves a purpose.', link: '#project-images-main', }, { - className: 'work', title: 'Work', text: 'I\'m an apprentice software developer at Dabapps, and this is what I\'ve done.', link: '',