英文:
How to place two Text with different fontSize in row with bottom places in the same line
问题
我试图设置两种不同的字体大小和对角。由于大小不同,它们在同一行上下出现。我需要将它们的底部对齐在同一行上。
上面的代码显示如下:
我试图使"Customer Called In (Gowri) March 7th 2023 4:45 PM"在同一行上。
英文:
I am trying to set 2 different font-size and Opposite corner. Due to size differs they appear up and down in same row. I need to align their bottom in the same line.
<h4 className="vertical-timeline-element-subtitle">
{event_tag}
<span className="creatorstyle">
{"(" + created_by + ")"}
</span>
<span className='datestyle'>
{format(new Date(created_at), 'LLLL do yyyy h:mm a')}
</span>
</h4>
The above code shows something like this:
I am trying to make "Customer Called In (Gowri) March 7th 2023 4:45 PM" in the same line.
答案1
得分: 2
使用flexbox
:
.vertical-timeline-element-subtitle {
display: flex;
align-items: center;
}
英文:
use flexbox
:
.vertical-timeline-element-subtitle {
display: flex;
align-items: center;
}
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论