{{!
    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 mod_h5pactivity/reviewattempts

    This template will render the H5P activity inside a recent activity report.

    Variables requirer for this template:
    * userpicture - User fullname and picture
    * grade - User grade
    * userdate - Submission date

    Example context (json):
    {
        "userpicture": "<a href=\"#\"> </a>",
        "grade": "30.77 / 100.00",
        "userdate": "Wednesday, 27 January 2021, 9:54 AM",
        "userurl": "http://localhost/m/stable_master/user/view.php?id=3&course=6",
        "fullname": "Lukáš Svoboda"
    }

}}
<table class="h5pactivity-recent">
    <tbody>
    <tr>
        <td class="userpicture">{{{userpicture}}}</td>
        <td>
            <div class="title">
                {{#modinfo}}
                    {{modicon}}<a href="{{modurl}}">{{modname}}</a>
                {{/modinfo}}
            </div>
            {{#grade}}
                <div class="grade">
                    {{grade}}
                </div>
            {{/grade}}
            <div class="user">
                <a href="{{userurl}}">{{fullname}}</a> - {{#userdate}} {{submissiontimestamp}}, {{#str}} strftimedatetime {{/str}} {{/userdate}}
            </div>
        </td>
    </tr>
    </tbody>
</table>
