 ExerciseGroup = require './group'
 ExerciseBadges = require '../exercise-badges'
 ExerciseIdentifierLink = require '../exercise-identifier-link'
+ScrollTo = require '../scroll-to-mixin'
 
 ExerciseMixin =
   getLastPartId: ->


ExerciseWithScroll = React.createClass
  displayName: 'ExerciseWithScroll'
  mixins: [ExerciseMixin]

  render: ->
    {parts, footer, pinned} = @props

    if @isSinglePart()
      return @renderSinglePart()

    exerciseParts = @renderMultiParts()

    exerciseGroup = @renderGroup()
    footer ?= @renderFooter() if pinned

    <CardBody footer={footer} pinned={pinned} className='openstax-multipart-exercise-card'>
      <ExerciseBadges isMultipart={true}/>
      {exerciseGroup}
      {exerciseParts}
      {@renderIdLink(false)}
    </CardBody>


Exercise = React.createClass

        onContinue: _.partial onNextStep, currentStep: step.stepIndex

    footerProps = _.omit(@props, 'onContinue')
    <ExFooter {...canContinueControlProps} {...footerProps} panel='review'/>

  renderIdLink: (related = true) ->
