{{!
    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 theme_foundation/partials/carousel

    Carousel.

    Context variables required for this template:
    * carouselid - Carousel any.

    Example context (json):
    {
        "carouselid": false
    }
}}
{{#carouselid}}
<div id="{{carouselid}}" class="carousel slide" data-bs-ride="carousel">
    <div class="carousel-indicators">
        {{#carouselindicators}}
        <button type="button" data-bs-target="#{{carouselid}}" data-bs-slide-to="{{indicatornumber}}"{{#indicatoractive}} class="active" aria-current="true"{{/indicatoractive}} aria-label="{{slidetitle}}"></button>
        {{/carouselindicators}}
    </div>
    <div class="carousel-inner container-fluid">
        {{#carouselslides}}
        <div class="carousel-item{{#slideactive}} active{{/slideactive}}">
            <div class="row the-slide">
                <div class="col-xs-5 the-slide-caption">
                    <h5>{{slidetitle}}</h5>
                    <div>{{{slidecaption}}}</div>
                </div>
                <div class="col-xs-7 the-slide-image-container">
                    <img src="{{slideimage}}" class="the-slide-image" alt="{{slideimagetext}}">
                </div>
            </div>
        </div>
        {{/carouselslides}}
    </div>
    <a class="carousel-control carousel-control-prev" href="#{{carouselid}}" role="button" data-bs-slide="prev">
        <span class="fa fa-chevron-circle-left" aria-hidden="true"></span>
        <span class="visually-hidden">{{#str}}previous{{/str}}</span>
    </a>
    <a class="carousel-control carousel-control-next" href="#{{carouselid}}" role="button" data-bs-slide="next">
        <span class="fa fa-chevron-circle-right" aria-hidden="true"></span>
        <span class="visually-hidden">{{#str}}next{{/str}}</span>
    </a>
</div>
{{/carouselid}}
