diff --git a/src/addon/mod/forum/components/index/addon-mod-forum-index.html b/src/addon/mod/forum/components/index/addon-mod-forum-index.html index eda6f5033..cfb16864f 100644 --- a/src/addon/mod/forum/components/index/addon-mod-forum-index.html +++ b/src/addon/mod/forum/components/index/addon-mod-forum-index.html @@ -70,9 +70,9 @@
- +
-

{{discussion.userfullname}}

+

{{discussion.userfullname}}

{{ discussion.groupname }}

{{discussion.created * 1000 | coreFormatDate: "strftimerecentfull"}}

diff --git a/src/addon/mod/forum/components/post/addon-mod-forum-post.html b/src/addon/mod/forum/components/post/addon-mod-forum-post.html index 600f96f30..87f191833 100644 --- a/src/addon/mod/forum/components/post/addon-mod-forum-post.html +++ b/src/addon/mod/forum/components/post/addon-mod-forum-post.html @@ -1,24 +1,24 @@
-
+

- - -
diff --git a/src/addon/mod/forum/components/post/post.scss b/src/addon/mod/forum/components/post/post.scss index 487ec8477..995dc2f13 100644 --- a/src/addon/mod/forum/components/post/post.scss +++ b/src/addon/mod/forum/components/post/post.scss @@ -42,6 +42,15 @@ ion-app.app-root addon-mod-forum-post .addon-mod_forum-post { display: flex; align-items: center; } + + .addon-mod-forum-post-info { + margin-top: 8px; + } + + .addon-mod-forum-post-title + .addon-mod-forum-post-info { + margin-top: 0px; + } + .addon-mod-forum-post-title h2, .addon-mod-forum-post-info .addon-mod-forum-post-author { flex-grow: 1; diff --git a/src/addon/mod/forum/components/post/post.ts b/src/addon/mod/forum/components/post/post.ts index 36a91e531..74801550b 100644 --- a/src/addon/mod/forum/components/post/post.ts +++ b/src/addon/mod/forum/components/post/post.ts @@ -54,6 +54,7 @@ export class AddonModForumPostComponent implements OnInit, OnDestroy { uniqueId: string; advanced = false; // Display all form fields. tagsEnabled: boolean; + displaySubject = true; protected syncId: string; @@ -78,6 +79,11 @@ export class AddonModForumPostComponent implements OnInit, OnDestroy { */ ngOnInit(): void { this.uniqueId = this.post.id ? 'reply' + this.post.id : 'edit' + this.post.parent; + + const reTranslated = this.translate.instant('addon.mod_forum.re'); + this.displaySubject = this.post.parent == 0 || + (this.post.subject != this.defaultSubject && this.post.subject != 'Re: ' + this.defaultSubject && + this.post.subject != reTranslated + this.defaultSubject); } /** diff --git a/src/components/files/files.ts b/src/components/files/files.ts index 9cc9fea6c..551c81137 100644 --- a/src/components/files/files.ts +++ b/src/components/files/files.ts @@ -61,7 +61,7 @@ export class CoreFilesComponent implements OnInit, DoCheck { */ ngDoCheck(): void { if (this.utils.isTrueOrOne(this.showInline)) { - // Check if there's any change in the extraData object. + // Check if there's any change in the files array. const changes = this.differ.diff(this.files); if (changes) { this.renderInlineFiles(); @@ -69,6 +69,9 @@ export class CoreFilesComponent implements OnInit, DoCheck { } } + /** + * Calculate contentText based on fils that can be rendered inline. + */ protected renderInlineFiles(): void { this.contentText = this.files.reduce((previous, file) => { const text = this.mimetypeUtils.getEmbeddedHtml(file);