The buttons to select or deselect the checklist may lie outside of the .pat-checklist element. However, to avoid mismatches, the selectors then need to be disambiguated by starting with an object id. In other words, the selector needs to start with #elementId.
Clicking the toggle checkbox to change the states.
Clicking select all / deselect all only affects parent of buttons and its children.