mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 13:38:32 +01:00
MDL-35924 filemanager: added label for the input field when creating a new folder
This commit is contained in:
parent
a5ec499521
commit
e06bfd3df3
@ -305,7 +305,10 @@ class core_files_renderer extends plugin_renderer_base {
|
||||
private function fm_js_template_mkdir() {
|
||||
$rv = '
|
||||
<div class="filemanager fp-mkdir-dlg">
|
||||
<div class="fp-mkdir-dlg-text">'.get_string('newfoldername','repository').'<br/><input type="text" /></div>
|
||||
<div class="fp-mkdir-dlg-text">
|
||||
<label>' . get_string('newfoldername', 'repository') . '</label><br/>
|
||||
<input type="text" />
|
||||
</div>
|
||||
<button class="{!}fp-dlg-butcreate">'.get_string('makeafolder').'</button>
|
||||
<button class="{!}fp-dlg-butcancel">'.get_string('cancel').'</button>
|
||||
</div>';
|
||||
|
@ -319,6 +319,7 @@ M.form_filemanager.init = function(Y, options) {
|
||||
on('keydown', function(e){
|
||||
if (e.keyCode == 13) {Y.bind(perform_action, this)(e);}
|
||||
}, this);
|
||||
node.one('label').set('for', 'fm-newname-' + this.client_id);
|
||||
node.all('.fp-dlg-butcancel').on('click', function(e){e.preventDefault();this.mkdir_dialog.hide();}, this);
|
||||
node.all('.fp-dlg-curpath').set('id', 'fm-curpath-'+this.client_id);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user