context = window
rest = context.JK.Rest()

@ProductJamBlasterPage = React.createClass({

  render: () ->

    `<div className="top-container">
      <div className="full-row name-and-artist">
        <div>
          <h1 className="jam-track-name">JAMBLASTER</h1>
          <h2 className="original-artist">by JamKazam</h2>
          <div className="clearall"/>
        </div>
        <div className="preview-and-action-box">
          <h2>See What You Can Do With The JamBlaster</h2>
          <div className="video-wrapper">
            <div className="video-container">
              <iframe src="//www.youtube.com/embed/iteR0ciRhtw" frameborder="0" allowfullscreen="allowfullscreen" />
            </div>
          </div>
          <img src="/assets/landing/arrow-jamblaster-order.png" className="arrow2" />
          <button data-celery="5675ffb8004f6711002918b6" data-celery-version="v2" className="white-bordered-button">
            Place Order for JamBlaster
          </button>
          <div className="tiny-note">
            Reserve your spot in our next JamBlaster manufacturing run now! <br/> Pre-order now and you won’t be charged until 30 days before we ship.
          </div>
        </div>
      </div>

      <div className="row summary-text">
        <p className="product-description">
          With your smartphone and a JamBlaster, you can:
        </p>

        <ul>
          <li>Play live in sync with other musicians from different locations over the Internet with the lowest possible latency – great for rehearsals without travel or space, co-writing, or joining open jams for fun</li>
          <li>Make pro quality audio (and optionally video) recordings of yourself and others – both master mix and fully isolated stems</li>
          <li>Learn and play along with 4,000+ of your favorite songs – with the ability to solo or mute any part, slow down playback for practice, change pitch/key, and more</li>
          <li>Teach or take online music lessons that really work – unlike Skype and Google Hangouts, which suffer from very high latency and poor audio quality</li>
          <li>Broadcast live video performances with pro quality audio through YouTube to family, friends, and fans – either yourself or your band playing in one location, or your online distributed JamKazam sessions</li>
        </ul>
      </div>
    </div>`


  ctaClick: (e) ->
    e.preventDefault()


  watchLatencyVideo: (e) ->
    e.preventDefault()
    context.JK.popExternalLink($(e.target).attr('href'))

  componentDidMount: () ->
    script = document.createElement("script");

    script.src = "https://www.trycelery.com/js/celery.js";
    script.async = true;

    document.body.appendChild(script);
})