let user be able to choose matching group in custom regex