Merge pull request #2476 from dpalou/MOBILE-3492

MOBILE-3492 core: Don't collapse some texts in big screens
main
Juan Leyva 2020-08-25 11:47:17 +02:00 committed by GitHub
commit 16d032033d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -354,7 +354,8 @@ export class CoreFormatTextDirective implements OnChanges {
this.element.classList.add('core-disable-media-adapt'); this.element.classList.add('core-disable-media-adapt');
this.element.innerHTML = ''; // Remove current contents. this.element.innerHTML = ''; // Remove current contents.
if (this.maxHeight && result.div.innerHTML != '') { if (this.maxHeight && result.div.innerHTML != '' &&
(this.fullOnClick || (window.innerWidth < 576 || window.innerHeight < 576))) { // Don't collapse in big screens.
// Move the children to the current element to be able to calculate the height. // Move the children to the current element to be able to calculate the height.
this.domUtils.moveChildren(result.div, this.element); this.domUtils.moveChildren(result.div, this.element);