我需要将一个元素定位在table-cell的顶部角落,并使文本堆叠在底部。我使用了vertical-align: bottom将所有文本向下移动,但现在我有一个问题,因为table-cell不支持相对定位...有什么想法可以解决这个问题吗?
<div style = "display: table-cell; vertical-align: bottom">
<div class = "top"> Top corner</div>
<h2> some text in the bottom </h2>
<h3> some more text in the bottom </h3>
</div>
编辑:它应该看起来像这样
+-----------+ +-----------+ +------------+
|top text | |top text | |top text |
| | | | | |
|some long | | | | |
|text | | | | |
|more long | | | | |
|text | | | | |
|end of | | | |some text |
|text | |text | |text |
|<button> | |<button> | |<button> |
+-----------+ +-----------+ +------------+
这些内容都包裹在一个display:table的div中。我想要使用display:table-cell是为了让这些列等高并且能够灵活地适应不同长度的文本。