Display large configuration file name with icon and size in a structured layout
by anoopsuda
HTML
<span class="filename">
<div class="file-header">
<span class="file-name">
THE_HULK-Highspeed-Uploadof-Large-Konfiguration_HULK-Highspeed-Uploadof-Large-Konfiguration - Copy.pptx
</span>
<img src="../../../../assets/revamp-images/ico-green-tick-circle.svg" class="file-icon" />
</div>
<span class="file-size">100 mb</span>
</span>
CSS
.filename {
display: inline-block;
font-family: Arial, sans-serif;
color: #000;
max-width: 350px; /* adjust as needed */
word-break: break-word;
}
.file-header {
display: flex;
justify-content: space-between;
align-items: center;
}
.file-name {
font-size: 13px;
font-weight: 500;
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.file-icon {
width: 16px;
height: 16px;
margin-left: 6px;
flex-shrink: 0;
}
.file-size {
display: block;
font-size: 10px;
color: #000;
white-space: nowrap;
margin-top: 2px;
}