add onCaret class for styling purposes