【发布时间】:2022-11-22 21:13:28
【问题描述】:
我正在尝试垂直对齐第三个输入字段的占位符。假设“text-start”和“text-end”类在 tailwind 中与占位符修饰符一起使用时垂直对齐占位符文本。但奇怪的是,在我的例子中,“text-start”和“text-end”分别与“text-left”和“text-right”做同样的事情。
<div class="flex flex-col space-y-8">
<div class="flex flex-col space-y-4 w-[540px]">
<input class="placeholder-Eerie-Black text-[13px] font-normal tracking-[0px] leading-[15px] bg-Amber border-2 border-opacity-50 border-Eerie-Black rounded-lg h-[50px] p-2" placeholder="Name and Surname*">
<input class="placeholder-Eerie-Black text-[13px] font-normal tracking-[0px] leading-[15px] bg-Amber border-2 border-opacity-50 border-Eerie-Black rounded-lg h-[50px] p-2" placeholder="Email*">
<input class="placeholder:text-end placeholder-Eerie-Black text-[13px] font-normal tracking-[0px] leading-[15px] bg-Amber border-2 border-opacity-50 border-Eerie-Black rounded-lg h-[98px] p-2 text-start" placeholder="Please provide as much detailed information as possible. Thank you *">
</div>
<button class="bg-Green w-[210px] h-[50px] rounded-lg">SUBMIT MESSAGE</button>
</div>
【问题讨论】:
标签: css frontend tailwind-css text-alignment text-align