     @constructor
   ###
   constructor: (routes) ->
-    {div,form,input,textarea,button,a} = React.DOM
 
     @create = React.createClass
 
       render: ->
+        {div,form,input,textarea,button,a} = React.DOM
+
         div className: 'new-song',
-          form onSubmit: @onFormSubmit,
+          form onSubmit: @onFormSubmit, ref: 'form',
             input
               autoFocus: true
               name: 'name'


      onFormSubmit: (e) ->
        e.preventDefault()
        @refs['name'].getDOMNode().focus()

  @MSG_SONG_NAME: goog.getMsg 'Song name'
  @MSG_WRITE_LYRICS_HERE: goog.getMsg 'Write lyrics here'

goog.provide 'app.songs.edit.react.Page'

goog.require 'app.songs.Song'
goog.require 'este.dom'
goog.require 'goog.ui.Textarea'

class app.songs.edit.react.Page
