We need to meet a specific requirement that involves displaying a prefix inside a textbox that cannot be edited. Check out the HTML/CSS code on JSFiddle. The issue arises when we resize the window.
HTML:
<div class="customNameContainer" dir="ltr">
<div title="Publisher prefix" class="publisherPrefix">new_</div>
<input name="customname" class="customName" type="text" maxlength="36">
</div>
CSS
.customNameContainer{
font-family: 'Segoe UI', Tahoma, sans-serif;
font-size: 14px;
color: #333333;
display: -ms-flexbox;
display: flex;
-ms-flex-direction: row;
flex-direction: row;
border: 1px solid #999999;
background-color: #ffffff;
width:50%;
}
.publisherPrefix{
display: -ms-flexbox;
display: flex;
-ms-flex-direction: row;
flex-direction: row;
-ms-flex-align: center;
align-items: center;
color: #888888;
}
.customName{
font-family: 'Segoe UI', Tahoma, sans-serif;
font-size: 14px;
color: #333333;
width: 100%;
border: 0;
}
Note: This code works in all browsers except Edge.
Issue: