|
|
@@ -123,78 +123,8 @@ div#history(ng-show="ui.view == 'history'")
|
|
|
i.fa.fa-spin.fa-refresh
|
|
|
| #{translate("loading")}...
|
|
|
|
|
|
- .diff-panel.full-size(ng-controller="HistoryDiffController")
|
|
|
- .diff(
|
|
|
- ng-if="!!history.diff && !history.diff.loading && !history.diff.deleted && !history.diff.error && !history.diff.binary"
|
|
|
- )
|
|
|
- .toolbar.toolbar-alt
|
|
|
- span.name
|
|
|
- | <strong>{{history.diff.highlights.length}} </strong>
|
|
|
- ng-pluralize(
|
|
|
- count="history.diff.highlights.length",
|
|
|
- when="{\
|
|
|
- 'one': 'change',\
|
|
|
- 'other': 'changes'\
|
|
|
- }"
|
|
|
- )
|
|
|
- | in <strong>{{history.diff.pathname}}</strong>
|
|
|
- .toolbar-right(ng-if="!history.isV2")
|
|
|
- a.btn.btn-danger.btn-sm(
|
|
|
- href,
|
|
|
- ng-click="openRestoreDiffModal()"
|
|
|
- ) #{translate("restore_to_before_these_changes")}
|
|
|
- .toolbar-right(ng-if="history.isV2")
|
|
|
- button.btn.btn-danger.btn-sm(
|
|
|
- href,
|
|
|
- ng-if="history.selection.docs[history.selection.pathname].deleted"
|
|
|
- ng-click=""
|
|
|
- )
|
|
|
- i.fa.fa-fw.fa-step-backward
|
|
|
- | Restore this deleted file
|
|
|
- .diff-editor.hide-ace-cursor(
|
|
|
- ace-editor="history",
|
|
|
- theme="settings.theme",
|
|
|
- font-size="settings.fontSize",
|
|
|
- text="history.diff.text",
|
|
|
- highlights="history.diff.highlights",
|
|
|
- read-only="true",
|
|
|
- resize-on="layout:main:resize",
|
|
|
- navigate-highlights="true"
|
|
|
- )
|
|
|
-
|
|
|
- .diff.diff-binary(ng-show="history.diff.binary")
|
|
|
- .toolbar.toolbar-alt
|
|
|
- span.name
|
|
|
- strong {{history.diff.pathname}}
|
|
|
- .alert.alert-info We're still working on showing image and binary changes, sorry. Stay tuned!
|
|
|
-
|
|
|
- .diff-deleted.text-centered(
|
|
|
- ng-show="history.diff.deleted && !history.diff.restoreDeletedSuccess"
|
|
|
- )
|
|
|
- p.text-serif #{translate("file_has_been_deleted", {filename:"{{ history.diff.doc.name }} "})}
|
|
|
- p
|
|
|
- a.btn.btn-primary.btn-lg(
|
|
|
- href,
|
|
|
- ng-click="restoreDeletedDoc()",
|
|
|
- ng-disabled="history.diff.restoreInProgress"
|
|
|
- ) #{translate("restore")}
|
|
|
-
|
|
|
- .diff-deleted.text-centered(
|
|
|
- ng-show="history.diff.deleted && history.diff.restoreDeletedSuccess"
|
|
|
- )
|
|
|
- p.text-serif #{translate("file_restored", {filename:"{{ history.diff.doc.name }} "})}
|
|
|
- p.text-serif #{translate("file_restored_back_to_editor")}
|
|
|
- p
|
|
|
- a.btn.btn-default(
|
|
|
- href,
|
|
|
- ng-click="backToEditorAfterRestore()",
|
|
|
- ) #{translate("file_restored_back_to_editor_btn")}
|
|
|
-
|
|
|
- .loading-panel(ng-show="history.diff.loading")
|
|
|
- i.fa.fa-spin.fa-refresh
|
|
|
- | #{translate("loading")}...
|
|
|
- .error-panel(ng-show="history.diff.error")
|
|
|
- .alert.alert-danger #{translate("generic_something_went_wrong")}
|
|
|
+ include ./history/diffPanelV1
|
|
|
+ include ./history/diffPanelV2
|
|
|
|
|
|
script(type="text/ng-template", id="historyRestoreDiffModalTemplate")
|
|
|
.modal-header
|