mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/MultimediaViewer
synced 2024-09-29 13:17:35 +00:00
248875e703
In order to communicate that there is more content below. This is related to acceptance criteria #8 of story #830. For more details check: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/830 Some further improvement to consider: - We'll need to adjust the "more details" button margin to make it fit better in the current above the fold area (0.55 em instead of the current 0.7em). - If the panel is open, and the user clicks outside of it (e.g., over the image), the panel should close. - We may want to eliminate the pointing-down chevron if we don't want it to conflict with the big "more details" button. Change-Id: If14886647aa0660a524a720e8d223eca655d5f3f
106 lines
2 KiB
Plaintext
106 lines
2 KiB
Plaintext
@import "mmv.globals";
|
|
@import "mmv.mixins";
|
|
|
|
@metadata-background: rgb(248, 248, 248);
|
|
@metadata-above-fold-reveal-height: 12;
|
|
|
|
.mw-mmv-wrapper {
|
|
top: 0px;
|
|
left: 0px;
|
|
right: 0px;
|
|
z-index: 1001;
|
|
position: absolute;
|
|
bottom: auto;
|
|
}
|
|
|
|
.mw-mmv-main {
|
|
width: 100%;
|
|
height: auto;
|
|
position: relative;
|
|
|
|
.jq-fullscreened {
|
|
background-color: black;
|
|
}
|
|
}
|
|
|
|
.mw-mmv-image-wrapper {
|
|
position: fixed;
|
|
top: 0px;
|
|
bottom: @metadatabar-above-fold-height;
|
|
left: 0px;
|
|
right: 0px;
|
|
}
|
|
|
|
.mw-mmv-image-inner-wrapper {
|
|
display: table;
|
|
width: 100%;
|
|
height: 100%;
|
|
}
|
|
|
|
.mw-mmv-pre-image {
|
|
position: absolute;
|
|
top: 0px;
|
|
height: 32px;
|
|
width: 100%;
|
|
z-index: 1;
|
|
}
|
|
|
|
.mw-mmv-post-image {
|
|
position: absolute;
|
|
width: 100%;
|
|
bottom: auto;
|
|
height: auto;
|
|
color: #333333;
|
|
background-color: #ffffff;
|
|
min-height: (@metadatabar-above-fold-height + 1);
|
|
z-index: 2;
|
|
}
|
|
|
|
// above-the-fold part of the metadata panel
|
|
.mw-mmv-above-fold {
|
|
width: 100%;
|
|
height: @metadatabar-above-fold-height - @metadata-above-fold-reveal-height;
|
|
// min-height is used when the height is changed to auto to display long texts, to make sure the layout
|
|
// is not messed up wheen the text is short and does not fill the available place. It is also used by
|
|
// Javascript to get the "default" height.
|
|
min-height: @metadatabar-above-fold-height - @metadata-above-fold-reveal-height;
|
|
position: relative;
|
|
border-bottom: 1px solid #dddddd;
|
|
|
|
.jq-fullscreened & {
|
|
height: @metadatabar-above-fold-fullscreen-height;
|
|
min-height: @metadatabar-above-fold-fullscreen-height;
|
|
}
|
|
|
|
.mw-mmv-untruncated & {
|
|
height: auto;
|
|
}
|
|
}
|
|
|
|
// Fullscreen styles
|
|
|
|
.cursor-hidden {
|
|
cursor: none;
|
|
}
|
|
|
|
.mw-mmv-main.jq-fullscreened {
|
|
background-color: black;
|
|
}
|
|
|
|
.jq-fullscreened {
|
|
.mw-mmv-image-wrapper, // make the image occupy the whole screen
|
|
.mw-mmv-post-image { // make sure the panel fits in the screen and does not cause scrollbars to appear
|
|
bottom: 0px;
|
|
}
|
|
|
|
.mw-mmv-post-image {
|
|
position: fixed;
|
|
min-height: 0;
|
|
.opacity(0);
|
|
transition: opacity 0.25s;
|
|
|
|
&:hover {
|
|
.opacity(1);
|
|
}
|
|
}
|
|
} |