diff --git a/gui/app/components/document/view-attachment.js b/gui/app/components/document/view-attachment.js index 8bcec149..cd76956e 100644 --- a/gui/app/components/document/view-attachment.js +++ b/gui/app/components/document/view-attachment.js @@ -15,6 +15,7 @@ import { inject as service } from '@ember/service'; import Component from '@ember/component'; export default Component.extend({ + classNames: ['row d-print-none'], documentService: service('document'), appMeta: service(), hasAttachments: notEmpty('files'), @@ -82,7 +83,6 @@ export default Component.extend({ getAttachments() { this.get('documentService').getAttachments(this.get('document.id')).then((files) => { this.set('files', files); - this.get('onReady')(files.length); }); }, diff --git a/gui/app/pods/document/index/controller.js b/gui/app/pods/document/index/controller.js index 5d96fe9f..86ef6140 100644 --- a/gui/app/pods/document/index/controller.js +++ b/gui/app/pods/document/index/controller.js @@ -20,9 +20,7 @@ export default Controller.extend(Tooltips, Notifier, { templateService: service('template'), sectionService: service('section'), linkService: service('link'), - // currentPageId: '', tab: 'content', - tabCount: 0, // how many items inside the tab? queryParams: ['currentPageId'], actions: { @@ -246,9 +244,5 @@ export default Controller.extend(Tooltips, Notifier, { }); }); }, - - onReady(count) { - this.set('tabCount', count); - } } }); diff --git a/gui/app/pods/document/index/template.hbs b/gui/app/pods/document/index/template.hbs index 1663bb1a..88a7d18f 100644 --- a/gui/app/pods/document/index/template.hbs +++ b/gui/app/pods/document/index/template.hbs @@ -27,6 +27,15 @@ onSaveDocument=(action 'onSaveDocument') refresh=(action 'refresh')}} +
+ +
+ {{document/document-heading document=document permissions=permissions @@ -42,19 +51,6 @@ versions=versions onSaveDocument=(action 'onSaveDocument')}} -
- -
- {{#if (eq tab 'content')}} {{document/view-content document=document links=links pages=pages blocks=blocks currentPageId=currentPageId @@ -64,9 +60,6 @@ onCopyPage=(action 'onCopyPage') onMovePage=(action 'onMovePage') onDeletePage=(action 'onPageDeleted') refresh=(action 'refresh')}} {{/if}} - {{#if (eq tab 'attachment')}} - {{document/view-attachment document=document permissions=permissions onReady=(action 'onReady')}} - {{/if}} {{#if (eq tab 'revision')}} {{document/view-revision document=document folder=folder pages=pages permissions=permissions onRollback=(action 'onRollback')}} {{/if}} diff --git a/gui/app/styles/layout/layout-master.scss b/gui/app/styles/layout/layout-master.scss index 1fae3c93..e10e734d 100644 --- a/gui/app/styles/layout/layout-master.scss +++ b/gui/app/styles/layout/layout-master.scss @@ -76,7 +76,7 @@ footer { .layout-content { flex: 0 1 1000px; margin: 0; - padding: 0 2rem 0 3rem; + padding: 0 0 0 3rem; } } diff --git a/gui/app/styles/view/document/doc-structure.scss b/gui/app/styles/view/document/doc-structure.scss index 451d2dad..7ee7b8c6 100644 --- a/gui/app/styles/view/document/doc-structure.scss +++ b/gui/app/styles/view/document/doc-structure.scss @@ -1,5 +1,6 @@ .document-tabnav { - margin: 50px 0 100px 0; + margin: 20px 0 0 0; + padding: 0; } .document-structure { diff --git a/gui/app/styles/view/document/view-attachment.scss b/gui/app/styles/view/document/view-attachment.scss index 667be15a..b7c9f6d8 100644 --- a/gui/app/styles/view/document/view-attachment.scss +++ b/gui/app/styles/view/document/view-attachment.scss @@ -1,6 +1,4 @@ .view-attachment { - margin: 0 0 50px 0; - > .upload-document-files { margin: 10px 0 0 0; @include ease-in(); @@ -11,40 +9,32 @@ } > .list { - margin: 20px 0 0 0; - padding: 7px 0; + margin: 0; + padding: 0; > .item { color: $color-off-black; margin: 0; - padding: 10px 0; + padding: 0; font-size: 1rem; list-style-type: none; - > .icon { + > a { + display: inline-block; + font-size: 1rem; + vertical-align: text-top; margin-right: 10px; } - > a { - @extend .text-truncate; - width: 80%; - color: $color-gray; - - &:hover { - color: $color-link; - } - - > .file { - @extend .text-truncate; - display: inline-block; - font-size: 0.9rem; - width: 80%; - vertical-align: text-top; - } + > .delete { + display: inline-block; + visibility: hidden; } - > .delete { - text-align: right; + &:hover { + > .delete { + visibility: visible; + } } } } diff --git a/gui/app/styles/view/document/vote-likes.scss b/gui/app/styles/view/document/vote-likes.scss index 83973db4..07d584b1 100644 --- a/gui/app/styles/view/document/vote-likes.scss +++ b/gui/app/styles/view/document/vote-likes.scss @@ -14,7 +14,7 @@ } > .buttons { - margin: 30px 0 0 0; + margin: 20px 0 0 0; } > .ack { diff --git a/gui/app/templates/components/document/document-meta.hbs b/gui/app/templates/components/document/document-meta.hbs index 828ea9a7..c51a6b71 100644 --- a/gui/app/templates/components/document/document-meta.hbs +++ b/gui/app/templates/components/document/document-meta.hbs @@ -75,6 +75,9 @@ {{/if}} {{/if}} + + {{document/view-attachment document=document permissions=permissions}} + diff --git a/gui/app/templates/components/document/view-attachment.hbs b/gui/app/templates/components/document/view-attachment.hbs index 9dd22b65..42063094 100644 --- a/gui/app/templates/components/document/view-attachment.hbs +++ b/gui/app/templates/components/document/view-attachment.hbs @@ -1,15 +1,15 @@ -
+
Attachments
+
{{#if hasAttachments}}
-{{/if}} {{#if showLikes}} -
-
- {{#unless voteThanks}} -
- {{folder.likes}} +{{/if}} +{{#if showLikes}} +
+
+ {{#unless voteThanks}} +
+ {{folder.likes}} +
+
+    + +
+ {{else}} +
Thanks for the feedback!
+ {{/unless}}
-
-    - -
- {{else}} -
Thanks for the feedback!
- {{/unless}}
-
-{{/if}} {{/if}} {{#unless hasPages}} {{#if canEdit}} + + {{/if}} +{{/if}} + +{{#unless hasPages}} + {{#if canEdit}}
+ SECTION
-{{/if}} {{/unless}} {{#if canEdit}} +{{/if}} {{/unless}} + +{{#if canEdit}}
diff --git a/gui/app/templates/components/layout/bottom-bar.hbs b/gui/app/templates/components/layout/bottom-bar.hbs index c421dcc8..6e61df96 100644 --- a/gui/app/templates/components/layout/bottom-bar.hbs +++ b/gui/app/templates/components/layout/bottom-bar.hbs @@ -2,7 +2,7 @@