From 4c7ed7102aa5fdf3245ce1113614fee2d15fbd07 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Fri, 24 Jul 2020 19:56:27 +0200 Subject: checklist dropdown --- .../views/viewer/checklist/checklist.content.js | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 animism-align/frontend/app/views/viewer/checklist/checklist.content.js (limited to 'animism-align/frontend/app/views/viewer/checklist/checklist.content.js') diff --git a/animism-align/frontend/app/views/viewer/checklist/checklist.content.js b/animism-align/frontend/app/views/viewer/checklist/checklist.content.js new file mode 100644 index 0000000..ae72adf --- /dev/null +++ b/animism-align/frontend/app/views/viewer/checklist/checklist.content.js @@ -0,0 +1,30 @@ +import React, { Component } from 'react' +import { connect } from 'react-redux' + +import actions from 'app/actions' + +class ChecklistContent extends Component { + render() { + const { sections, currentSection } = this.props + return ( +
+
+
+ {sections.map(section => { + if (currentSection !== "all" || section.index !== currentSection) return + return ( +
+ ) + })} +
+
+
+ ) + } +} + +const mapStateToProps = state => ({ + sections: state.viewer.sections, +}) + +export default connect(mapStateToProps)(ChecklistContent) -- cgit v1.2.3-70-g09d2