Proyectos de Subversion Moodle

Rev

Rev 1 | | Comparar con el anterior | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
{{!
2
    This file is part of Moodle - http://moodle.org/
3
 
4
    Moodle is free software: you can redistribute it and/or modify
5
    it under the terms of the GNU General Public License as published by
6
    the Free Software Foundation, either version 3 of the License, or
7
    (at your option) any later version.
8
 
9
    Moodle is distributed in the hope that it will be useful,
10
    but WITHOUT ANY WARRANTY; without even the implied warranty of
11
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
    GNU General Public License for more details.
13
 
14
    You should have received a copy of the GNU General Public License
15
    along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
16
}}
17
{{!
18
    @template core_message/message_drawer_view_overview_section
19
 
20
    This template is a base template to render a collapsible "section" on the
21
    overview page of the message drawer, for example the messages section.
22
 
23
    Classes required for JS:
24
    * none
25
 
26
    Data attributes required for JS:
27
    * All data attributes are required
28
 
29
    Context variables required for this template:
30
    * userid The logged in user id
31
    * urls The URLs for the popover
32
 
33
    Example context (json):
34
    {}
35
 
36
}}
37
 
38
<div
39
    class="section border-0 card rounded-0"
40
    data-region="{{$region}}{{/region}}"
41
>
42
    <div id="{{$region}}{{/region}}-toggle" class="card-header rounded-0" data-region="toggle">
43
        <button
1441 ariadna 44
            class="btn btn-link w-100 text-start p-1 p-sm-2 d-flex rounded-0 align-items-center overview-section-toggle {{^expanded}}collapsed{{/expanded}}"
45
            data-bs-toggle="collapse"
46
            data-bs-target="#{{$region}}{{/region}}-target-{{uniqid}}"
1 efrain 47
            aria-expanded="{{#expanded}}true{{/expanded}}{{^expanded}}false{{/expanded}}"
48
            aria-controls="{{$region}}{{/region}}-target-{{uniqid}}"
49
        >
50
            <span class="collapsed-icon-container">
1441 ariadna 51
                <span class="dir-rtl-hide">{{#pix}} t/collapsed, core {{/pix}}</span>
52
                <span class="dir-ltr-hide">{{#pix}} t/collapsed_rtl, core {{/pix}}</span>
1 efrain 53
            </span>
54
            <span class="expanded-icon-container">
55
                {{#pix}} t/expanded, core {{/pix}}
56
            </span>
1441 ariadna 57
            <span class="fw-bold ms-1">{{$title}}{{/title}}</span>
1 efrain 58
            <small
1441 ariadna 59
                class="hidden ms-1"
1 efrain 60
                data-region="section-total-count-container" aria-labelledby="{{$region}}{{/region}}-total-count-label"
61
            >
62
                (<span aria-hidden="true" data-region="section-total-count">{{count.total}}</span>)
1441 ariadna 63
                <span class="visually-hidden" id="{{$region}}{{/region}}-total-count-label">
1 efrain 64
                    {{#str}} totalconversations, core_message, {{count.total}} {{/str}}
65
                </span>
66
            </small>
1441 ariadna 67
            <span class="hidden ms-2" data-region="loading-icon-container">
1 efrain 68
                {{> core/loading }}
69
            </span>
70
            <span
1441 ariadna 71
                class="{{^count.unread}}hidden{{/count.unread}} badge rounded-pill bg-primary text-white ms-auto"
1 efrain 72
                data-region="section-unread-count-container" aria-labelledby="{{$region}}{{/region}}-unread-count-label"
73
            >
74
                <span aria-hidden="true" data-region="section-unread-count">{{count.unread}}</span>
1441 ariadna 75
                <span class="visually-hidden" id="{{$region}}{{/region}}-unread-count-label">
1 efrain 76
                    {{#str}} unreadconversations, core_message, {{count.unread}} {{/str}}
77
                </span>
78
            </span>
79
        </button>
80
    </div>
81
    {{< core_message/message_drawer_lazy_load_list }}
82
        {{$rootclasses}}collapse border-bottom {{#expanded}}show{{/expanded}}{{/rootclasses}}
83
        {{$rootattributes}}
84
            id="{{$region}}{{/region}}-target-{{uniqid}}"
85
            aria-labelledby="{{$region}}{{/region}}-toggle"
1441 ariadna 86
            data-bs-parent="#message-drawer-view-overview-container-{{uniqid}}"
1 efrain 87
        {{/rootattributes}}
88
    {{/ core_message/message_drawer_lazy_load_list }}
89
</div>