Use new view registry API

This fixes some new deprecation warnings. Also gave NotificationElement an `::initialize` method so you can instantiate one with a model in a single line.