{{!
    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_courseformat/local/overview/overviewdialog

    Shows an overview dialog.

    Example context (json):
    {
        "buttoncontent" : "Trigger button",
        "title": "Total Attempts",
        "description": "This shows the total attempts made by the user in the course.",
        "hasitems": true,
        "items": [
            {
                "label": "Allowed Attempts",
                "value": 3
            },
            {
                "label": "Average Attempts",
                "value": "Max reached"
            }
        ]
    }
}}
{{< core/local/dropdown/dialog }}
    {{$ dialogcontent }}
        <div class="px-3">
            {{#title}}
            <span class="fw-bold">{{title}}</span>
            {{/title}}
            {{#description}}
            <div class="mt-2 mb-3">{{{description}}}</div>
            {{/description}}
            {{#hasitems}}
            <ul class="my-2">
                {{#items}}
                    <li>
                        {{#str}}
                        labelvalue, core, {
                            "label": {{#quote}}{{label}}{{/quote}},
                            "value": {{#quote}}<span class="fw-bold">{{value}}</span>{{/quote}}
                        }
                        {{/str}}
                    </li>
                {{/items}}
            </ul>
            {{/hasitems}}
        </div>
    {{/ dialogcontent }}
{{/ core/local/dropdown/dialog }}
