Using percentages for playlist font-sizing was ambitious, but fell prey to `editor-style.css` in the admin. We have switched to using pixels. The editor styles were also forcing MediaElement players to inherit `font-family`, which was undesirable. And while we're at it, remove the top and bottom border from the playlist's list of tracks, which adds a dash of lovely to the playlist's default styles.

Props nacin for the addition of `—` in the playlist track list.
Fixes #27600.


Built from https://develop.svn.wordpress.org/trunk@27865


git-svn-id: http://core.svn.wordpress.org/trunk@27696 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Scott Taylor 2014-03-30 22:12:16 +00:00
parent c95f232727
commit b6ac65f07f
2 changed files with 33 additions and 23 deletions

View File

@ -1,3 +1,7 @@
.mejs-container * {
font-family: Helvetica, Arial;
}
.mejs-container, .mejs-embed, .mejs-embed body { .mejs-container, .mejs-embed, .mejs-embed body {
background: #000; background: #000;
} }
@ -59,8 +63,8 @@
border: 1px solid #ccc; border: 1px solid #ccc;
padding: 10px; padding: 10px;
margin: 12px 0 18px; margin: 12px 0 18px;
font-size: 85%; font-size: 14px;
line-height: 160%; line-height: 1.5;
} }
.wp-playlist video { .wp-playlist video {
@ -92,46 +96,47 @@
} }
.wp-playlist-caption { .wp-playlist-caption {
max-width: 85%; max-width: 90%;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
font-size: 14px;
line-height: 1.5;
} }
.wp-caption-meta { .wp-playlist-item-meta {
display: block; display: block;
font-size: 14px;
line-height: 1.5;
} }
.wp-caption-title { .wp-playlist-item-title {
font-size: 100%; font-size: 14px;
line-height: 1.5;
} }
.wp-caption-album { .wp-playlist-item-album {
font-style: italic; font-style: italic;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
.wp-caption-artist { .wp-playlist-item-artist {
font-size: 85%; font-size: 12px;
text-transform: uppercase; text-transform: uppercase;
} }
.wp-caption-by {
font-size: 65%;
font-weight: bold;
}
.wp-playlist-item-length { .wp-playlist-item-length {
position: absolute; position: absolute;
right: 3px; right: 3px;
top: 0; top: 0;
font-size: 14px;
line-height: 1.5;
} }
.wp-playlist-tracks { .wp-playlist-tracks {
margin-top: 10px; margin-top: 10px;
border-top: 1px solid #ccc;
} }
.wp-playlist-item { .wp-playlist-item {
@ -141,6 +146,10 @@
border-bottom: 1px solid #ccc; border-bottom: 1px solid #ccc;
} }
.wp-playlist-item:last-child {
border-bottom: 0;
}
.wp-playlist-light .wp-playlist-item { .wp-playlist-light .wp-playlist-item {
color: #333; color: #333;
} }
@ -175,10 +184,12 @@
max-width: 60px; max-width: 60px;
height: auto; height: auto;
margin-right: 10px; margin-right: 10px;
padding: 0;
border: 0;
} }
.wp-playlist-current-item .wp-caption-title, .wp-playlist-current-item .wp-playlist-item-title,
.wp-playlist-current-item .wp-caption-artist { .wp-playlist-current-item .wp-playlist-item-artist {
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;

View File

@ -1019,9 +1019,9 @@ function wp_underscore_playlist_templates() {
<img src="{{ data.thumb.src }}"/> <img src="{{ data.thumb.src }}"/>
<# } #> <# } #>
<div class="wp-playlist-caption"> <div class="wp-playlist-caption">
<span class="wp-caption-meta wp-caption-title">&#8220;{{{ data.title }}}&#8221;</span> <span class="wp-playlist-item-meta wp-playlist-item-title">&#8220;{{{ data.title }}}&#8221;</span>
<# if ( data.meta.album ) { #><span class="wp-caption-meta wp-caption-album">{{ data.meta.album }}</span><# } #> <# if ( data.meta.album ) { #><span class="wp-playlist-item-meta wp-playlist-item-album">{{ data.meta.album }}</span><# } #>
<# if ( data.meta.artist ) { #><span class="wp-caption-meta wp-caption-artist">{{ data.meta.artist }}</span><# } #> <# if ( data.meta.artist ) { #><span class="wp-playlist-item-meta wp-playlist-item-artist">{{ data.meta.artist }}</span><# } #>
</div> </div>
</script> </script>
<script type="text/html" id="tmpl-wp-playlist-item"> <script type="text/html" id="tmpl-wp-playlist-item">
@ -1031,10 +1031,9 @@ function wp_underscore_playlist_templates() {
<# if ( data.caption ) { #> <# if ( data.caption ) { #>
{{{ data.caption }}} {{{ data.caption }}}
<# } else { #> <# } else { #>
<span class="wp-caption-title">&#8220;{{{ data.title }}}&#8221;</span> <span class="wp-playlist-item-title">&#8220;{{{ data.title }}}&#8221;</span>
<# if ( data.artists && data.meta.artist ) { #> <# if ( data.artists && data.meta.artist ) { #>
<span class="wp-caption-by"><?php _e( 'by' ) ?></span> <span class="wp-playlist-item-artist"> &mdash; {{ data.meta.artist }}</span>
<span class="wp-caption-artist">{{ data.meta.artist }}</span>
<# } #> <# } #>
<# } #> <# } #>
</div> </div>