Make topbar doc code consistent with example
Merge pull request #3985 from izhan/patch-1

Make topbar doc code consistent with example