How can I add an element to my list with clicking on "Add button" without losing style of my "li" in a new element. When I'm trying to add with append() it loses my styling. I know why it loses but I have no idea how to fix it.
<div class="wrapper">
    <input type="text" class="text_field" placeholder="Write a new task here..." onfocus="this.placeholder = ''" onblur="this.placeholder = 'Write a new task here...'" />
    <input type="submit" class="add_btn" value="Add" />
    <div class="items">
        <ul class="sortable">
            <li>
                <input class='tasks' type='checkbox' />
                <p>Meet Larry at 6pm</p>
            </li>
        </ul>
    </div>
</div>
CSS:
.tasks {
    position: absolute;
    margin: 20px 20px;
    width: 19px;
    height: 19px;
    display: block;
}
.tasks:before {
    content:"";width: 19px;height: 19px;border: 1px solid #43d6b0;
}
 
     
    