JSFiddle - React, Tailwind, and code Playground

by cheack

HTML

<div class="field-wrap required">
          <label class="field-float">Order Number:</label>
          <input placeholder="Order Number" class="form-control input-float" required="" name="orderNumber" type="text">        </div>

CSS

body{
  background: red;
}
.field-wrap:after {
  content: "Required";
  position: absolute;
    top: 0;
    right: 15px;
    bottom: auto;
    left: auto;
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    display: block;
    text-align: right;
    font-size: 11px;
    color: #878787;
    pointer-events: none;
}