MDL-64230 files: Display long file/folder names with ellipsis

* Instead of clipping long file/folder names by default, truncate them
with ellipsis to indicate to the user that the file/folder has a long
name.
This commit is contained in:
Jun Pataleta
2019-03-08 14:48:49 +08:00
parent a713ed3ba6
commit ed90e4d378
5 changed files with 23 additions and 2 deletions
+2 -2
View File
@@ -168,7 +168,7 @@ class core_files_renderer extends plugin_renderer_base {
<div class="fp-reficons2"></div>
</div>
<div class="fp-filename-field">
<div class="fp-filename"></div>
<div class="fp-filename text-truncate"></div>
</div>
</a>
<a class="fp-contextmenu" href="#">'.$this->pix_icon('i/menu', '▶').'</a>
@@ -335,7 +335,7 @@ class core_files_renderer extends plugin_renderer_base {
<div class="fp-reficons2"></div>
</div>
<div class="fp-filename-field">
<p class="fp-filename"></p>
<p class="fp-filename text-truncate"></p>
</div>
</a>';
return $rv;
+6
View File
@@ -196,6 +196,12 @@
padding-top: 5px;
padding-bottom: 12px;
min-width: 112px;
// Undo truncating of text on hover.
&:hover {
overflow: inherit;
white-space: normal;
text-overflow: inherit;
}
}
// Table view (File Picker only)
.file-picker .yui3-datatable table {
+4
View File
@@ -12745,6 +12745,10 @@ body.drawer-ease {
padding-top: 5px;
padding-bottom: 12px;
min-width: 112px; }
.fp-iconview .fp-filename-field .fp-filename:hover {
overflow: inherit;
white-space: normal;
text-overflow: inherit; }
.file-picker .yui3-datatable table {
border: 0 solid #bbb;
@@ -299,6 +299,12 @@
padding-top: 5px;
padding-bottom: 12px;
min-width: 112px;
// Undo truncating of text on hover.
&:hover {
overflow: inherit;
white-space: normal;
text-overflow: unset;
}
}
// Table view (File Picker only)
+5
View File
@@ -7381,6 +7381,11 @@ span.editinstructions {
padding-bottom: 12px;
min-width: 112px;
}
.fp-iconview .fp-filename-field .fp-filename:hover {
overflow: inherit;
white-space: normal;
text-overflow: unset;
}
.file-picker .yui3-datatable table {
border: 0 solid #bbb;
width: 100%;