Adds implementation of toggle around pattern