@(url: String, submitText: String, readonly: Boolean, noteForm: Form[String])(implicit messages: Messages)

<form action="@url" method="POST" class="pure-form pure-form-stacked">
  @defining(noteForm("contents")) { f =>
    <textarea class="pure-input-1 upload-text" name="@f.name" id=@f.id" autocomplete="off" autofocus="on" required @if(readonly){ readonly }>@f.value</textarea>
    <div class="pure-input-1 upload-error">
      @if(f.hasErrors) {
        @f.error.map(_.message)
      }
    </div>
  }
  <button type="submit" class="pure-button pure-button-primary pure-input-1 upload-btn">@submitText</button>
</form>

@(url: String, submitText: String, readonly: Boolean, noteForm: Form[String])(implicit messages: Messages)

<form action="@url" method="POST" class="pure-form pure-form-stacked">
  @defining(noteForm("contents")) { f =>
    <textarea class="pure-input-1 upload-text" name="@f.name" id="@f.id" autocomplete="off" autofocus="on" required @if(readonly){ readonly }>@f.value</textarea>
    <div class="pure-input-1 upload-error">
      @if(f.hasErrors) {
        @f.error.map(_.message)
      }
    </div>
  }
  <button type="submit" class="pure-button pure-button-primary pure-input-1 upload-btn">@submitText</button>
</form>

Fix the id of the upload textarea
Fix the id of the upload textarea
