<div class="navbar navbar-form navbar-full-width navbar-editor">
    <div class="btn-group" data-toggle="buttons" >
      <label class="btn btn-default btn-sm active" onclick="set_code()">
        <input type="radio" name="options" id="option1" ><%= _("Input") %>
      </label>
      <label class="btn btn-default btn-sm" onclick="set_preview()">
        <input type="radio" name="options" id="option2" ><%= _("Diff") %>
      </label>
      <% if show_preview %>
        <label class="btn btn-default btn-sm" onclick="set_render()">
          <input type="radio" name="options" id="option3" ><%= _("Preview") %>
        </label>
      <% end %>
    </div>

    <% if show_preview %>
      <span id="preview_host_selector" style="display:none">
        <%= select_tag :preview_host_id, options_from_collection_for_select(@template.preview_host_collection, :id, :name),
                       :onchange => 'get_rendered_template()' %>
      </span>
    <% end %>

    <a class="btn btn-default btn-sm btn-fullscreen" href="#" onclick="set_fullscreen_editor('.editor-container');">
      <i class="glyphicon glyphicon-resize-full"></i>
    </a>

    <a class="btn btn-default btn-sm btn-exit-fullscreen hidden" href="#" onclick="exit_fullscreen_editor();">
      <i class="glyphicon glyphicon-resize-small"></i>
    </a>

    <ul class="nav navbar-nav navbar-right navbar-editor">
      <li>
        <%= select_tag('mode', content_tag(:optgroup, options_for_select(['text', 'json', 'ruby', 'sh', 'xml', 'yaml']), :label => _('Syntax Highlighting')), :class => 'form-control input-sm without_select2') %>
      </li>

      <li>
        <%= select_tag('keybinding', content_tag(:optgroup, options_for_select([_('Default'), 'Vim', 'Emacs']), :label => _('Key Binding')), :class => 'form-control input-sm without_select2') %>
      </li>
    </ul>
</div>
