It's about deleting some HTML tags as required. Thus, you need to define an event and then wire that to find the element that needs to be removed (using JavaScript/jQuery) and then remove it.
Like removing a table row using a delete button:
function productDelete(ctl) {
$(ctl).parents("tr").remove();
}
An example on similar lines here:
Add, Edit and Delete Data in an HTML Table Using JavaScript and jQuery[
^]