use pikaday element instead of child element when comparing against trigger element

This is to fix a bug that occurs when a child element inside the trigger element is clicked. When the child element is clicked, the date picker should still open.