use dom traversal for element selection