refactor(selector regexp): update the selector regexp

The new regexp is easier to understand and marginally faster (~5%)