💄 Inline the gutter component

This commit is contained in:
Ben Ogle
2014-06-24 11:17:09 -07:00
parent ae96d9aeaa
commit 866bc02d68

View File

@@ -81,16 +81,13 @@ EditorComponent = React.createClass
className += ' is-focused' if focused
className += ' has-selection' if hasSelection
gutter = null
if showLineNumbers
gutter = GutterComponent {
ref: 'gutter', onMouseDown: @onGutterMouseDown, onWidthChanged: @onGutterWidthChanged,
lineDecorations, defaultCharWidth, editor, renderedRowRange, maxLineNumberDigits, scrollViewHeight,
scrollTop, scrollHeight, lineHeightInPixels, @pendingChanges, mouseWheelScreenRow
}
div className: className, style: {fontSize, lineHeight, fontFamily}, tabIndex: -1,
gutter
if showLineNumbers
GutterComponent {
ref: 'gutter', onMouseDown: @onGutterMouseDown, onWidthChanged: @onGutterWidthChanged,
lineDecorations, defaultCharWidth, editor, renderedRowRange, maxLineNumberDigits, scrollViewHeight,
scrollTop, scrollHeight, lineHeightInPixels, @pendingChanges, mouseWheelScreenRow
}
div ref: 'scrollView', className: 'scroll-view', onMouseDown: @onMouseDown,
InputComponent