fix(views): prevent output of empty heading when there is no page title

fixes #7387
Merge pull request #7414 from jdalsem/empty-page-title

fix(views): prevent output of empty heading when there is no page title