Heim > Fragen und Antworten > Hauptteil
P粉1139388802023-08-18 00:42:54
如果您只想让图标始终位于单词“North”旁边,只需将其放在标签内:
.flex { display:flex; align-items:center; resize: both; overflow:auto; background: #99AAAA; max-width: fit-content; max-height: fit-content; }
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.2/css/all.min.css" rel="stylesheet"/> <h3>拖动角落进行调整大小</h3> <div class="flex"> <span>THE KING OF THE NORTH <i class="fa-solid fa-image"></i></span> </div>