Customizing a new Ribbon toolbar tab
If you want to create a Ribbon toolbar tab that behaves differently from a normal Ribbon toolbar tab (which has Groups containing buttons), use the <ext:pagetype> element in a Ribbon toolbar tab extension configuration to specify your own custom client-side implementation of the tab.
Procedure
- First, ensure that you have configured a Ribbon toolbar tab in your custom Editor's configuration file.
- Create a JavaScript class that inherits from Tridion.Controls.RibbonPage and defines your custom implementation of the Ribbon tab. At the end of the file, call
Tridion.Controls.Deck.registerPageTypeto register this new type of Ribbon tab under a specific name. - Save this file as a .js file and add it to your Visual Studio solution.
- Create a new
cfg:groupelement for this JavaScript file in your custom Editor's configuration file, and give it a dependency on the Ribbon Toolbar group in Content Manager Explorer. - Add a
ControlResourcesattribute to the server-side class for ASCX control, and set it to the name of this new resource group. - In the
ext:extensionelement that defines the Ribbon toolbar tab you want to customize, setext:pagetypeto the name under which you registered your new type of Ribbon tab.