- add Preview class
plug preview code