Proyectos de Subversion Moodle

Rev

| 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 mod_forum/inpage_reply_v2
19
 
20
    In page reply HTML for the nested v2 discussion display mode.
21
 
22
    Classes required for JS:
23
    * none
24
 
25
    Data attributes required for JS:
26
    * none
27
 
28
    Example context (json):
29
    {
30
        "postid": 0,
31
        "reply_url": "",
32
        "sesskey": "",
33
        "parentsubject": ""
34
    }
35
}}
36
<div
37
    class="mt-4 mb-4"
38
    data-content="inpage-reply-content"
39
    style="display: none;"
40
>
41
    <div class="d-flex">
42
        <div class="author-image-container">
43
            {{#loggedinuser}}
44
                <img
45
                    class="rounded-circle w-100"
46
                    src="{{{profileimageurl}}}"
47
                    alt="{{#str}} pictureof, core, {{fullname}} {{/str}}"
48
                    aria-hidden="true"
49
                >
50
            {{/loggedinuser}}
51
        </div>
52
        <div class="w-100">
53
            {{#loggedinuser}}
54
                <h4 class="h5 font-weight-bold reply-author">{{#str}} replyauthorself, mod_forum, {{firstname}}{{/str}}</h4>
55
            {{/loggedinuser}}
56
            {{#throttlingwarningmsg}}
57
                <div class="alert alert-danger alert-block fade in " role="alert">
58
                    {{throttlingwarningmsg}}
59
                </div>
60
            {{/throttlingwarningmsg}}
61
            <form data-post-id="{{postid}}" data-content="inpage-reply-form" action="{{{reply_url}}}">
62
                <textarea
63
                    name="post"
64
                    rows="3"
65
                    class="w-100"
66
                    {{#parentauthorname}}
67
                    placeholder="{{#str}} replyingtoauthor, forum, {{.}} {{/str}}"
68
                    {{/parentauthorname}}
69
                    {{^parentauthorname}}
70
                    placeholder="{{#str}} replyplaceholder, forum {{/str}}"
71
                    {{/parentauthorname}}
72
                    data-auto-rows
73
                    data-min-rows="3"
74
                    data-max-rows="10"
75
                ></textarea>
76
                <input type="hidden" name="postformat" value="{{postformat}}"/>
77
                <input type="hidden" name="subject" value="{{parentsubject}}"/>
78
                <input type="hidden" name="reply" value="{{postid}}"/>
79
                <input type="hidden" name="sesskey" value="{{sesskey}}"/>
80
                <div class="d-flex mt-3 align-items-center flex-wrap">
81
                    <button class="btn btn-primary font-weight-bold px-3" data-action="forum-inpage-submit">
82
                        <span data-region="submit-text">{{#str}} posttoforum, mod_forum {{/str}}</span>
83
                        <span data-region="loading-icon-container" class="hidden">{{> core/loading }}</span>
84
                    </button>
85
                    <button data-action="forum-advanced-reply" class="btn btn-link mr-auto" type="submit">
86
                        {{#str}} advanced, core {{/str}}
87
                    </button>
88
                    {{#canreplyprivately}}
89
                    <div class="form-check form-check-inline">
90
                        <div class="custom-control custom-switch">
91
                            <input name="privatereply" type="checkbox" class="custom-control-input" id="private-reply-checkbox-{{uniqid}}">
92
                            <label class="custom-control-label" for="private-reply-checkbox-{{uniqid}}">
93
                                {{#str}} privatereply, forum {{/str}}
94
                            </label>
95
                        </div>
96
                    </div>
97
                    {{/canreplyprivately}}
98
                    <button
99
                        class="btn btn-icon icon-no-margin icon-size-4 text-muted"
100
                        title="{{#str}} cancelreply, mod_forum {{/str}}"
101
                        data-action="cancel-inpage-reply"
102
                    >
103
                        {{#pix}} i/delete, core {{/pix}}
104
                    </button>
105
                </div>
106
            </form>
107
        </div>
108
    </div>
109
</div>