Newer Version Available

This content describes an older version of this product. View Latest

setPanelWidth() for Lightning Experience

Sets a utility panel’s width.

Arguments

Name Type Description
utilityId string The ID of the utility of which to set the width. Optional when called within a utility.
widthPX integer The width of the utility panel in pixels.

Sample Code

This component, when added to a single-column Lightning page used in a utility bar, sets the width of the utility panel to 800 pixels when the button is pressed.

Component code:

Controller code:

Response

This method returns a promise that, upon success, resolves to true.