move accessiblity region inside main editor block

This commit is contained in:
MathuraMG 2016-08-11 21:26:49 -04:00
parent c8dbb8bef7
commit cd1a803123
2 changed files with 9 additions and 4 deletions

View file

@ -1,4 +1,5 @@
import React, { PropTypes } from 'react'; import React, { PropTypes } from 'react';
import EditorAccessibility from '../components/EditorAccessibility';
import CodeMirror from 'codemirror'; import CodeMirror from 'codemirror';
import 'codemirror/mode/javascript/javascript'; import 'codemirror/mode/javascript/javascript';
import 'codemirror/mode/css/css'; import 'codemirror/mode/css/css';
@ -98,14 +99,21 @@ class Editor extends React.Component {
render() { render() {
return ( return (
<div>
<div ref="container" className="editor-holder" tabIndex="0" title="code editor" role="main"> <div ref="container" className="editor-holder" tabIndex="0" title="code editor" role="main">
</div> </div>
<EditorAccessibility
lintMessages={this.props.lintMessages}
lineNo={this.props.lineNo}
/>
</div>
); );
} }
} }
Editor.propTypes = { Editor.propTypes = {
lintWarning: PropTypes.bool.isRequired, lintWarning: PropTypes.bool.isRequired,
lineNo: PropTypes.string.isRequired,
lintMessages: PropTypes.array.isRequired, lintMessages: PropTypes.array.isRequired,
updateLintMessage: PropTypes.func.isRequired, updateLintMessage: PropTypes.func.isRequired,
clearLintMessage: PropTypes.func.isRequired, clearLintMessage: PropTypes.func.isRequired,

View file

@ -1,6 +1,5 @@
import React, { PropTypes } from 'react'; import React, { PropTypes } from 'react';
import Editor from '../components/Editor'; import Editor from '../components/Editor';
import EditorAccessibility from '../components/EditorAccessibility';
import Sidebar from '../components/Sidebar'; import Sidebar from '../components/Sidebar';
import PreviewFrame from '../components/PreviewFrame'; import PreviewFrame from '../components/PreviewFrame';
import Toolbar from '../components/Toolbar'; import Toolbar from '../components/Toolbar';
@ -174,8 +173,6 @@ class IDEView extends React.Component {
fontSize={this.props.preferences.fontSize} fontSize={this.props.preferences.fontSize}
indentationAmount={this.props.preferences.indentationAmount} indentationAmount={this.props.preferences.indentationAmount}
isTabIndent={this.props.preferences.isTabIndent} isTabIndent={this.props.preferences.isTabIndent}
/>
<EditorAccessibility
lintMessages={this.props.editorAccessibility.lintMessages} lintMessages={this.props.editorAccessibility.lintMessages}
lineNo={this.props.editorAccessibility.lineNo} lineNo={this.props.editorAccessibility.lineNo}
/> />