I am trying to append a button to a text input.
It works when I am in desktop mode, but when you change the size to a mobile-viewing size the button separates from the input.
Here is my fiddle.
I am using purecss:
input {
font-size: 16px;
padding-right: 50px;
border-radius: 0px;
height: 30px;
}
.pure-button {
margin-left: -45px;
height: 30px;
width: 40px;
padding: 1px;
}
span {
cursor: pointer;
display: inline-block;
height: 11px;
width: 8px;
text-align: center;
white-space: nowrap;
align-self: flex-start;
background: red;
background-position: 0 0;
margin: 1px;
}
<link href="https://cdnjs.cloudflare.com/ajax/libs/pure/0.6.0/pure-min.css" rel="stylesheet"/>
<div class="pure-g">
<div class="pure-u-1">
<form class="pure-form">
<fieldset>
<input type="text" class="pure-input-1-2" />
<button type="submit" class="pure-button pure-button-primary">
<span></span>
</button>
</fieldset>
</form>
</div>
</div>