Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

Add checkbox to hide tour modal until a new story has been added

ZachTRice01aa75c11eea
diff --git a/web/css/tour.css b/web/css/tour.css
index 0f2ff51ce..e905d0d53 100644
--- a/web/css/tour.css
+++ b/web/css/tour.css
@@ -45,7 +45,7 @@
/* .tour-start */
.tour-start .modal {
overflow-y: auto;
- height: 794px;
+ height: 830px;
width: 635px;
margin-left: auto;
margin-right: auto;
@@ -206,6 +206,10 @@
order: 1;
}
+.tour-start .modal-footer {
+ padding: 0 4px 4px;
+}
+
/* .tour-in-progress */
.tour-in-progress .modal {
left: auto;
diff --git a/web/js/components/tour/modal-tour-start.js b/web/js/components/tour/modal-tour-start.js
index 3313526dc..dc9249f22 100644
--- a/web/js/components/tour/modal-tour-start.js
+++ b/web/js/components/tour/modal-tour-start.js
@@ -1,21 +1,27 @@
import React from 'react';
import PropTypes from 'prop-types';
-import { Modal, ModalHeader, ModalBody } from 'reactstrap';
+import { Modal, ModalHeader, ModalBody, ModalFooter, InputGroup, InputGroupAddon, InputGroupText, Input } from 'reactstrap';
import TourIntro from './content-intro';
import TourBoxes from './tour-boxes';
class ModalStart extends React.Component {
render() {
return (
- <div>
- <Modal isOpen={this.props.modalStart} toggle={this.props.toggleModalStart} onClosed={this.props.showTourAlert} wrapClassName='tour tour-start' className={this.props.className} backdrop={true}>
- <ModalHeader toggle={this.props.toggleModalStart} charCode="">Welcome to Worldview!</ModalHeader>
- <ModalBody>
- <TourIntro toggleModalStart={this.props.toggleModalStart}></TourIntro>
- <TourBoxes stories={this.props.stories} storyOrder={this.props.storyOrder} selectTour={this.props.selectTour}></TourBoxes>
- </ModalBody>
- </Modal>
- </div>
+ <Modal isOpen={this.props.modalStart} toggle={this.props.toggleModalStart} onClosed={this.props.showTourAlert} wrapClassName='tour tour-start' className={this.props.className} backdrop={true}>
+ <ModalHeader toggle={this.props.toggleModalStart} charCode="">Welcome to Worldview!</ModalHeader>
+ <ModalBody>
+ <TourIntro toggleModalStart={this.props.toggleModalStart}></TourIntro>
+ <TourBoxes stories={this.props.stories} storyOrder={this.props.storyOrder} selectTour={this.props.selectTour}></TourBoxes>
+ </ModalBody>
+ <ModalFooter>
+ <InputGroup>
+ <InputGroupText className="w-100">
+ <Input addon type="checkbox" className="float-right m-0" aria-label="Hide this box until a new story has been added." />
+ <span className="ml-2">Check the box to hide this modal until a new story has been added.</span>
+ </InputGroupText>
+ </InputGroup>
+ </ModalFooter>
+ </Modal>
);
}
}