グーグルが助けてくれないという問題に遭遇しました。コンテナーに translate3d(0, 0, 0) が適用され、これにより、幅と高さが 100% の内部コンテナーの寸法が破壊されます。これを示すために小さな jsfiddle を作成しました。#page の翻訳を削除すると、寸法は正しいです... http://jsfiddle.net/11vt14nx/1/
HTML部分
<div class="page-wrapper">
<section id="page">
<div class="artworkPage">
<figure class="vertical-middle">
<img src="asda">
</figure>
<div class="data">
<p class="description">asd</p>
<div class="button-group align-center">
<button class="like small" data-object-id="1">
<span class="icon-thumbs-up"></span>
<span class="value">0</span>
</button>
<button class="dislike small secondary" data-object-id="1">
<span class="icon-thumbs-down"></span>
<span class="value">0</span>
</button>
</div>
</div>
</div>
</section>
</div>
CSS
.artworkPage {
figure {
position: absolute;
top: 0;
left: 0;
height: 100%;
width: 100%;
z-index: 1;
img {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
margin: auto;
max-width: 100%;
max-height: 100%;
}
}
.data {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 2;
background: rgba($body-bg, .8);
@include transition(all .2s linear);
&.hidden {
@include opacity(0);
display: block;
}
.description {
font-size: 14px;
padding: 5px 10px;
margin-bottom: 0;
}
}
}
.page-wrapper {
#page {
white-space: nowrap;
@include translate3d(0, 0, 0);
& > div {
float: none;
white-space: normal;
width: 100%;
@include inline-block(top);
}
}
}
誰かがこれを修正する方法を知っていますか?
前もって感謝します
よろしくトーマス:)