New layout for choose media config item.

This commit is contained in:
Matthias Mees 2013-06-18 12:01:11 +02:00
parent a57a39082b
commit c8ccc5c9bd
2 changed files with 25 additions and 9 deletions

View File

@ -57,17 +57,16 @@
<input name="serendipity[{$postKey}][{$config_item}]" type="hidden" value="{$cbag_value}">
</div>
{elseif $ctype == 'media'}
<div class="clearfix">
<div class="form_field media_choose">
<label for="serendipity[{$postKey}][{$config_item}]">{$cname}
{if $cdesc != ''}<span>{$cdesc}</span>{/if}
</label>
{* This should be solved using JS. *}
<div id="{$config_item}_preview" style="background-image: url({$value}); width: {$preview_width}; height: {$preview_height}; background-repeat: no-repeat;">&nbsp;</div>
{* This should be input[type=file] … *}
<input id="serendipity[{$postKey}][{$config_item}]" name="serendipity[{$postKey}][{$config_item}]" type="text" value="{$value}" onchange="change_preview('{$config_item}')">
<input id="serendipity[{$postKey}][{$config_item}]" name="serendipity[{$postKey}][{$config_item}]" type="text" value="{$value}" onchange="change_preview('{$config_item}')">{* This should be input[type=file] … *}
<a href="#" onclick="choose_media('serendipity[{$postKey}][{$config_item}]')">{$CONST.MEDIA_LIBRARY}</a>
{* … not touching it in order to not break it for now. *}
<a class="button_link" href="#" title="{$CONST.MEDIA_LIBRARY}" onclick="choose_media('serendipity[{$postKey}][{$config_item}]')"><span class="icon-picture"></span><span class="visuallyhidden"> {$CONST.MEDIA_LIBRARY}</span></a>
<div id="{$config_item}_preview" style="background-image: url({$value}); width: {$preview_width}; height: {$preview_height}; background-repeat: no-repeat;"></div>
</div>
{elseif $ctype == 'sequence'}
{if !$sequencejs_output}

View File

@ -901,7 +901,8 @@ input[type=checkbox] {
.comment_full,
.serendipity_commentDirection,
.entry_info,
.pagination {
.pagination,
.media_choose > div {
clear: both;
}
@ -1154,6 +1155,10 @@ main {
width: 100%;
}
.configuration_group .media_choose input {
width: 90%;
}
#serendipity_category .form_multiselect label {
width: auto;
}
@ -1807,6 +1812,16 @@ input[name="serendipity[filter][fileCategory]"] {
max-width: 48%;
}
.configuration_group .media_choose input {
margin-right: 1%;
max-width: 41.5%;
}
.media_choose .button_link {
position: relative;
top: 2px;
}
.configuration_group .form_select,
.configuration_group .form_multiselect,
.configuration_group .form_field,
@ -1981,7 +1996,9 @@ input[name="serendipity[filter][fileCategory]"] {
/* LARGER SCREEN (e.g. laptops)
----------------------------------------------------------------- */
@media only screen and (min-width: 1280px) {
.configuration_group .media_choose input {
max-width: 42.5%;
}
}