add a directive for checkboxes