add: A widget template.
doc: More details about widget api and layout mode.