<div class="modal" tabindex="-1" role="dialog">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header" ng-show="title">
        <button type="button" class="close" ng-click="$hide()">&times;</button>
        <h4 class="modal-title">{{title}}</h4>
      </div>

      <form name="editRoomForm" role="form" ng-submit="editRoom(selections.room); $hide()" novalidate>
        <div class="modal-body">    
          <label for="room-name">Enter a name for the room:</label>
          <input class="form-control" id="room-name" type="text" name="roomName" placeholder="Room name" ng-model="selections.room.name" ng-maxlength="32" required>
          <p class="help-block" ng-show="editRoomForm.roomName.$error.required && editRoomForm.roomName.$dirty">A valid room name is required.</p>
          <p class="help-block" ng-show="editRoomForm.roomName.$error.maxlength && editRoomForm.roomName.$dirty">The room name cannot be longer than 32 characters.</p>       
        </div>
        <div class="modal-footer">
          <button type="submit" class="btn btn-primary" ng-disabled="editRoomForm.$invalid">Save</button>
          <button type="button" class="btn btn-danger" ng-click="cancelEdit(); $hide()">Cancel</button>
        </div>

      </form>
    </div>
  </div>
</div>
