{{!
    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.

    Edwiser RemUI
    @package   theme_remui
    @copyright (c) 2022 WisdmLabs (https://wisdmlabs.com/)
    @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

}}
{{#old_card}}
<div class=" col-lg-12  animation-{{animation}}" data-plugin="appear" data-animate="{{animation}}" data-course-id="{{id}}">
    <div class="row no-space my-2 bg-white mx-0">
        <div class="col-lg-3 col-md-4 p-0">
            <a href="{{ courseurl }}" aria-label="Course - {{{ coursename }}}">
            <div class="rounded-top" style="background-image: url('{{ courseimage }}');background-size: cover;background-position: center; position: relative;height:200px;"></div>
            {{^visible}}<i class="hidden-icon fa fa-eye-slash text-white" aria-hidden="true" title="{{#str}} hiddencourse, theme_remui {{/str}}"></i>{{/visible}}
            </a>

            {{# instructors }}
            <a href="{{ url }}" class="d-flex justify-content-end instructor-img {{ imgStyle }}" data-toggle="tooltip" title="{{{name}}}" aria-label="Instructor for {{coursename}} is - {{name}}">
                <img src="{{ picture }}" style="border: 2px solid white; cursor: pointer;" class="rounded-circle" alt="{{ name }}" />
            </a>
            {{/ instructors }}
        </div>
        <div class="col-lg-9 col-md-8 p-0">
            <div class="card-body h-full p-3"  title="{{{ coursename }}}">
                <h4 class="card-title mt-1 ellipsis ellipsis-2"><a href="{{ courseurl }}" class="font-weight-400 text-dark font-size-18" tabindex="-1">{{{ coursename }}}</a></h4>
                <p class="card-text"><span class="text-muted">{{{ categoryname }}}</span></p>
                <p class="card-text">{{{ coursesummary }}}</p>

                {{# mycourses}}
                    <div class="w-200 pull-right">
                        {{# coursecompleted }}
                            <div class="card-footer bg-transparent border-0 p-0 activity-btn {{listbuttons}}">
                                <a href="{{ courseurl }}" class="btn btn-success btn-block p-10 bg-green-500 border-0 rounded-0 text-white font-weight-800" href="" aria-label="Course Completed 100%" >
                                <i class="fa fa-check" aria-hidden="true"></i>
                                {{coursecompleted}}</a>
                            </div>
                        {{/ coursecompleted }}

                        {{# courseinprogress }}
                            <div class="progress progress-xs m-0 bg-purple-200 w-p100 {{listprogress}}">
                                <div class="progress-bar bg-purple-400" style="width: {{percentage}}%;" role="progressbar">
                                </div>
                            </div>
                            <div class="card-footer bg-transparent border-0 p-0 activity-btn {{listbuttons}}">
                                <a href="{{# lastaccessactivity}} {{lastaccessactivity}} {{/ lastaccessactivity}}{{^ lastaccessactivity}} {{ courseurl }} {{/ lastaccessactivity}}" class="btn btn-default btn-block p-10 bg-purple-500 border-0 rounded-0 text-white font-weight-800" href="" aria-label="Course Completed {{percentage}}%, Resume the course" role="button"><i class="fa fa-refresh" aria-hidden="true"></i>
                                {{courseinprogress}}</a>
                            </div>
                        {{/ courseinprogress }}

                        {{# coursetostart }}
                            <div class="card-footer bg-transparent border-0 p-0 activity-btn {{listbuttons}}">
                                <a href="{{ courseurl }}" class="btn btn-info btn-block p-10 border-0 rounded-0 text-white font-weight-800" href=""  aria-label="Start the course - {{coursename}}" role="button"><i class="fa fa-play-circle" aria-hidden="true"></i>
                                {{coursetostart}}</a>
                            </div>
                        {{/ coursetostart }}
                    </div>
                {{/ mycourses}}

                {{^ mycourses}}
                    {{# usercanmanage }}
                        <div class="card-footer bg-transparent border-0 text-muted activity-btn {{listbuttons}}">
                            <div class="enrolmenticons d-inline-block">
                                {{{ enrollmenticons }}}
                            </div>

                            <button type="button"
                                class="btn btn-icon {{^icondesign}}btn-outline-primary{{/icondesign}} btn-sm btn-round float-right showoptions "
                                data-plugin="toolbar"
                                data-toolbar="#course-{{ id }}-options">
                                <i class="icon fa fa-cog" aria-hidden="true"></i>
                            </button>
                        </div>
                        <div class="toolbar-icons tool-items toolbar-primary" id="course-{{ id }}-options" hidden="">
                            <a href="{{ enrollusers }}" class="tool-item" title="{{# str }} enroluser, theme_remui {{/ str }}"><i class="icon fa fa-users" aria-hidden="true"></i></a>
                            <a href="{{ grader }}" class="tool-item" title="{{# str }} graderreport, theme_remui {{/ str }}"><i class="icon fa fa-star" aria-hidden="true"></i></a>
                            <a href="{{ activity }}" class="tool-item" title="{{# str }} activityeport, theme_remui {{/ str }}"><i class="icon fa fa-pie-chart" aria-hidden="true"></i></a>
                            <a href="{{ editcourse }}" class="tool-item" title="{{# str }} editcourse, theme_remui {{/ str }}"><i class="icon fa fa-edit" aria-hidden="true"></i></a>
                        </div>
                    {{/ usercanmanage }}

                    {{^ usercanmanage }}
                        <div class="card-footer bg-transparent text-muted">
                            <div class="enrolmenticons">
                                {{{ enrollmenticons }}}
                            </div>
                        </div>
                    {{/ usercanmanage }}
                {{/ mycourses}}
            </div>
        </div>
    </div>
</div>
{{/old_card}}
