1
0
Fork 0
mirror of https://github.com/overleaf/overleaf.git synced 2025-04-11 07:15:13 +00:00

Adapt styles to avoid layout breaking/showing options that do not make sense when no history entries are loaded.

This commit is contained in:
Paulo Reis 2018-08-17 15:31:59 +01:00
parent 27823d3e06
commit fc424aee9e
2 changed files with 5 additions and 4 deletions
services/web
app/views/project/editor/history
public/stylesheets/app/editor

View file

@ -6,7 +6,7 @@
i.fa.fa-spin.fa-refresh
|    #{translate("loading")}...
span.history-toolbar-selected-version(
ng-show="!history.loadingFileTree && !history.showOnlyLabels && !history.error"
ng-show="!history.loadingFileTree && !history.showOnlyLabels && history.selection.updates.length && !history.error"
) #{translate("browsing_project_as_of")} 
time.history-toolbar-time {{ history.selection.updates[0].meta.end_ts | formatDate:'Do MMM YYYY, h:mm a' }}
span.history-toolbar-selected-version(
@ -19,13 +19,13 @@
button.history-toolbar-btn(
ng-click="showAddLabelDialog();"
ng-if="!history.showOnlyLabels"
ng-disabled="history.loadingFileTree"
ng-disabled="history.loadingFileTree || history.selection.updates.length == 0"
)
i.fa.fa-tag
|  #{translate("history_label_this_version")}
button.history-toolbar-btn(
ng-click="toggleHistoryViewMode();"
ng-disabled="history.loadingFileTree"
ng-disabled="history.loadingFileTree || history.selection.updates.length == 0"
)
i.fa.fa-exchange
|  #{translate("compare_to_another_version")}

View file

@ -19,6 +19,7 @@
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
margin-right: (@line-height-computed / 2);
}
.history-toolbar-time,
.history-toolbar-selected-label {
@ -33,7 +34,7 @@
.btn-xs;
padding-left: @padding-small-horizontal;
padding-right: @padding-small-horizontal;
margin-left: (@line-height-computed / 2);
margin-right: (@line-height-computed / 2);
}
.history-toolbar-entries-list {
flex: 0 0 @changesListWidth;