Skip to content
This repository was archived by the owner on May 31, 2021. It is now read-only.

Commit 3329256

Browse files
committed
Simple 'get help' resources
1 parent f229013 commit 3329256

File tree

2 files changed

+79
-1
lines changed

2 files changed

+79
-1
lines changed

src-ui/map-editor/MapEditorPage.js

+18-1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ import EditGenericCommentDialog from './dialogs/edit-comment-dialog';
2121
import CreateNewSubmapDialog from './dialogs/create-new-submap-dialog';
2222
import SubmapReferencesDialog from './dialogs/submap-references-dialog';
2323
import ReferencesDialog from './dialogs/references-dialog';
24+
var GetHelpDialog = require('./dialogs/get-help-dialog');
2425
import {LinkContainer} from 'react-router-bootstrap';
2526
import SingleMapActions from './single-map-actions';
2627
import {calculateMapName} from '../map-list/map-name-calculator';
@@ -45,6 +46,8 @@ export default class MapEditorPage extends React.Component {
4546
this.download = this.download.bind(this);
4647
this.state = this.props.singleMapStore.getMap();
4748
this.canvasStore = new CanvasStore();
49+
this.closeHelpDialog = this.closeHelpDialog.bind(this);
50+
this.openHelpDialog = this.openHelpDialog.bind(this);
4851
}
4952

5053
componentDidMount() {
@@ -113,6 +116,14 @@ export default class MapEditorPage extends React.Component {
113116
];
114117
}
115118

119+
closeHelpDialog() {
120+
this.setState({openHelpDialog: false});
121+
}
122+
123+
openHelpDialog() {
124+
this.setState({openHelpDialog: true});
125+
}
126+
116127
render() {
117128
const auth = this.props.auth;
118129
const history = this.props.history;
@@ -130,6 +141,10 @@ export default class MapEditorPage extends React.Component {
130141
const comments = singleMapStore.getMap().map.comments;
131142

132143
const canvasStore = this.canvasStore;
144+
const helpDialog = <GetHelpDialog open={this.state.openHelpDialog} close={this.closeHelpDialog}/>;
145+
const helpMenu = <NavItem eventKey={7} href="#" onClick={this.openHelpDialog} key="help">
146+
<Glyphicon glyph="education"></Glyphicon>Get help!
147+
</NavItem>;
133148

134149
return (
135150
<DocumentTitle title={mapName}>
@@ -139,7 +154,8 @@ export default class MapEditorPage extends React.Component {
139154
<AtlasNavbarWithLogout
140155
auth={auth}
141156
history={history}
142-
mainMenu={mapMenu}/>
157+
mainMenu={mapMenu}
158+
rightMenu={[helpMenu]}/>
143159
</Col>
144160
</Row>
145161
<Row className="show-grid">
@@ -175,6 +191,7 @@ export default class MapEditorPage extends React.Component {
175191
<EditActionDialog singleMapStore={singleMapStore}/>
176192
<SubmapReferencesDialog singleMapStore={singleMapStore}/>
177193
<ReferencesDialog singleMapStore={singleMapStore}/>
194+
{helpDialog}
178195
</Grid>
179196
</DocumentTitle>
180197
);
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
/*jshint esversion: 6 */
2+
3+
var React = require('react');
4+
import {
5+
Form,
6+
FormGroup,
7+
FormControl,
8+
ControlLabel,
9+
HelpBlock,
10+
Col,
11+
Radio,
12+
Input,
13+
Modal,
14+
Button,
15+
Glyphicon,
16+
ListGroup,
17+
ListGroupItem
18+
} from 'react-bootstrap';
19+
import ReactDOM from 'react-dom';
20+
21+
var GetHelpDialog = React.createClass({
22+
23+
render: function() {
24+
var show = this.props.open;
25+
return (
26+
<div>
27+
<Modal show={show} onHide={this.props.close}>
28+
<Modal.Header closeButton>
29+
<Modal.Title>
30+
Get help on mapping
31+
</Modal.Title>
32+
</Modal.Header>
33+
<Modal.Body>
34+
<ListGroup>
35+
<ListGroupItem href="http://learn.leadingedgeforum.com/p/wardley-mapping/?product_id=277424&coupon_code=CDANLAUNCH">
36+
<h4 class="list-group-item-heading">Enroll in a self-paced, online course</h4>
37+
<p class="list-group-item-text">An excellent starter to give you all the knowledge you need to start mapping. Click here to learn more!</p>
38+
</ListGroupItem>
39+
{/*<ListGroupItem href="http://learn.leadingedgeforum.com/p/wardley-mapping/?product_id=277424&coupon_code=CDANLAUNCH">
40+
<h4 class="list-group-item-heading">Have your map(s) reviewed</h4>
41+
<p class="list-group-item-text">If you want to receive feedback on this map, click here to book a session with Chris,
42+
the creator of this tool.</p>
43+
</ListGroupItem>
44+
<ListGroupItem href="http://learn.leadingedgeforum.com/p/wardley-mapping/?product_id=277424&coupon_code=CDANLAUNCH">
45+
<h4 class="list-group-item-heading">Book a kickstart session</h4>
46+
<p class="list-group-item-text">Get assistance in mapping your company. You will be able to focus on your business problem instead of wondering, whether your maps are correct.
47+
Helpful advice will be also at hand, when you need it! Click to request contact!</p>
48+
</ListGroupItem>*/}
49+
<ListGroupItem href="http://wardleymaps.com/advanced">
50+
<h4 class="list-group-item-heading">Premium, on-site workshop</h4>
51+
<p class="list-group-item-text">A two-day mapping class delivered by mr. Simon Wardley himself, personally, at your premise. Click to learn more!</p>
52+
</ListGroupItem>
53+
</ListGroup>
54+
</Modal.Body>
55+
</Modal>
56+
</div>
57+
);
58+
}
59+
});
60+
61+
module.exports = GetHelpDialog;

0 commit comments

Comments
 (0)