Skip to content

Commit

Permalink
MDL-56938 messages: Images and videos display badly in messaging
Browse files Browse the repository at this point in the history
Make sure they get minimum and maximum width so they don't overflow and
don't appear tiny.
  • Loading branch information
Damyon Wiese committed Nov 21, 2016
1 parent cd4a6b8 commit fce0f1c
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 0 deletions.
4 changes: 4 additions & 0 deletions filter/mediaplugin/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
margin-top: 5px;
margin-bottom: 5px;
text-align: center;

/* Make videos as wide as possible without being wider than their containers */
width: 100vw;
max-width: 100%;
}

.mediaplugin > div {
Expand Down
4 changes: 4 additions & 0 deletions theme/boost/scss/moodle/message.scss
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@
border: 1px solid #e3e3e3;
clear: both;

img {
max-width: 100%;
}

.contacts-area {
border-right: 1px solid #e3e3e3;
height: 600px;
Expand Down
4 changes: 4 additions & 0 deletions theme/bootstrapbase/less/moodle/message.less
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@
clear: both;
border-radius: 4px;

img {
max-width: 100%;
}

.contacts-area {
border-right: 1px solid #e3e3e3;
height: 600px;
Expand Down
3 changes: 3 additions & 0 deletions theme/bootstrapbase/style/moodle.css
Original file line number Diff line number Diff line change
Expand Up @@ -5838,6 +5838,9 @@ a.ygtvspacer:hover {
clear: both;
border-radius: 4px;
}
.messaging-area-container .messaging-area img {
max-width: 100%;
}
.messaging-area-container .messaging-area .contacts-area {
border-right: 1px solid #e3e3e3;
height: 600px;
Expand Down

0 comments on commit fce0f1c

Please sign in to comment.