           <div className='row-wrap'>
             {problemsWorked}
             {practiceButton}
-            {if @state.showAll then chapterButton}
+            {chapterToggleButton}
           </div>
           {helpText}
         </div>

        <div className='practice-button-wrap'>
          <PracticeButton showAll={@state.showAll} courseId={@props.courseId} pageIds={unit.page_ids}/>
        </div>
      chapterButton =
        <div className='chapter-button-wrap'>
          <BS.Button className="chapter-button" bsStyle='primary' onClick={@displayChapter}>
            View This Chapter
          </BS.Button>
        </div>
      helpText =

  displayUnit: (unit, chapter) ->
    @setState({unit, chapter: chapter})

  toggleChapter: ->
    @setState({showAll: not @state.showAll}, -> @loadChart())

  displayTopic: ->
    {courseId} = @props
