{# These are the dropdown options for the top of the dashboard. #}
<div class="btn-group">
    <a href=".edit-mode-component" class="btn btn-sm btn-default" data-toggle="collapse"><span class="fa fa-cog"></span> Edit</a>
    <a href="#chart-options" id="add-module" class="btn btn-sm btn-default" data-toggle="modal">
        <span class="fa fa-plus"></span> Add widget
    </a>
    <a href="#" class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
        Options <span class="caret"></span>
    </a>
    <ul class="dropdown-menu">
        <li>
            <a href="#save-json-form" data-toggle="collapse">Edit raw JSON</a>
        </li>
        <li>
            <a href="#download-json" target="_blank">Download raw JSON</a>
        </li>
        <li>
            <a href="?jsondash_demo_mode=1">Enable demo mode</a>
        </li>
        <li class="divider"></li>
        <li class="clearfix">
            <form class="pull-left" action="{{ url_for('jsondash.clone', c_id=view.id) }}" method="POST">
                &nbsp;
                <button class="btn btn-default btn-sm">
                    <span class="fa fa-clone text-success"></span> Clone
                </button>
            </form>

            <form class="delete-dashboard pull-right" action="{{ url_for('jsondash.delete', c_id=view.id) }}" method="POST">
                <button class="btn btn-default btn-sm">
                    <span class="fa fa-times-circle text-danger"></span> Delete
                </button>
                &nbsp;
            </form>
        </li>
    </ul>
</div>
