{{!
    This file is part of Moodle - http://moodle.org/

    Moodle is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Moodle is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
}}
{{!
    @template core/full_header

    This template renders the header.

    Example context (json):
    {
        "contextheader": "context_header_html",
        "settingsmenu": "settings_html",
        "hasnavbar": false,
        "navbar": "navbar_if_available",
        "courseheader": "course_header_html",
        "welcomemessage": "welcomemessage"
    }
}}
<header id="page-header" class="header-maxwidth d-print-none">
<div class="headerbuttons">
        {{#hasmycourses}}
            <a href="#" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" data-tooltip="tooltip" data-placement= "right" title="{{{mycourses}}}" class="btn btn-secondary headerbutton mycourses" style="float:right;"><i class="fa-2x fa fa-history mycourses"></i></a>
        <div class="dropdown-menu dropdown-menu-right iconsidebar">
            <h5>{{{mycourses}}}</h5>
            {{{mycoursesmenu}}}
        </div>
        {{/hasmycourses}}

        {{#hasheaderblocks}}
        <div class="blockpanelbtn">
            <button id="blocksliderbutton" class="btn btn-secondary headerbutton" style="float:right;" type="button" data-toggle="collapse" data-target="#blockslider" aria-expanded="false" aria-controls="blockslider" title="{{# str }} coursedashbutton, theme_learnr {{/ str }}">
                <i class="fa-2x fa fa-arrows-v" aria-hidden="true"> </i>
            </button>
        </div>
        {{/hasheaderblocks}}

        {{#showenrollinktoteacher}}
        <div class="enrollbtn"> 
            <a href="{{{easycodelink}}}" title="{{{easyenrolbtntext}}}" class="btn btn-secondary headerbutton easyenrolbtn" style="float:right;"><i class="fa fa-2x fa-key" aria-hidden="true"></i><span class="sr-only">{{{easyenrolbtntext}}}</span></a>
        </div>
        {{/showenrollinktoteacher}}
        </div>
    <div class="w-100">

        

        {{#displayheaderblocks}}
            {{#hasheaderblocks}}
            <div class="fp-blocks collapse slidingblockpanel" id="blockslider">
                <div class="container-fluid">
                    <div class="row">
                        <div class="col-md-4">
                                <section data-region="blocks-columna" class="hidden-print">
                                    {{{ columnabtn }}}
                                    {{{ columnaregion }}}
                                </section>
                        </div>
                        <div class="col-md-4">
                                <section data-region="blocks-columnb" class="hidden-print">
                                    {{{ columnbbtn }}}
                                    {{{ columnbregion }}}
                                </section>
                        </div>
                        <div class="col-md-4">
                                <section data-region="blocks-columnc" class="hidden-print">
                                    {{{ columncbtn }}}
                                    {{{ columncregion }}}
                                </section>
                        </div>
                    </div>
                </div>
                 <div class="text-center blockpanelbtn">
                <button id="blocksliderbutton" class="btn btn-secondary blockpanelbutton" type="button" data-toggle="collapse" data-target="#blockslider" aria-expanded="false" aria-controls="blockslider" title="{{# str }} closecoursedashboard, theme_learnr {{/ str }}">
                    <i class="fa-2x fa fa-arrows-v" aria-hidden="true">{{# str }} closecoursedashboard, theme_learnr {{/ str }} </i>
                </button>
            </div>
            </div>
            {{/hasheaderblocks}}
        {{/displayheaderblocks}}

        <div class="d-flex flex-wrap">
            {{#hasnavbar}}
            <div id="page-navbar">
                {{{navbar}}}
            </div>
            {{/hasnavbar}}

            <div class="ml-auto d-flex">
                {{{pageheadingbutton}}}
            </div>
            <div id="course-header">
                {{{courseheader}}}
            </div>
        </div>
        <div class="d-flex align-items-center">
            {{^welcomemessage}}
                {{#contextheader}}
                    <div class="mr-auto">
                        {{{contextheader}}}
                    </div>
                {{/contextheader}}
            {{/welcomemessage}}
            {{> core/welcome }}
            <div class="header-actions-container ml-auto" data-region="header-actions-container">
                {{#headeractions}}
                    <div class="header-action ml-2">{{{.}}}</div>
                {{/headeractions}}
            </div>
        </div>
    </div>
</header>
