2 * Renders class name and icon in page header.
4 Ext.define('Docs.view.cls.Header', {
5 extend: 'Ext.container.Container',
7 // Initially the component will be empty and so the initial height
8 // will not be correct if not set explicitly
10 alias: 'widget.classheader',
12 tpl: Ext.create('Ext.XTemplate',
13 '<h1 class="{[this.getClass(values)]}">',
15 '<span class="private">Private</span>',
17 '<a href="source/{href}" target="_blank">{name}</a>',
18 '<tpl if="xtypes.length > 0">',
19 '<span>xtype: {[values.xtypes.join(", ")]}</span>',
23 getClass: function(cls) {
27 else if (cls.singleton) {
38 * Loads class name and icon to header.
39 * @param {Object} cls class config.
42 this.update(this.tpl.apply(cls));