# Responsive ToolBar

The ToolBar enables you to hide the tools that do not fit its width and allows you to programmatically determine their rendering.

By default, the ToolBar allows you to choose from three different overflow modes for smaller screen sizes:

<Row>
  <Column count={[24,24,8]} style={{marginBottom: "1rem"}}>
    <Component className="tile" href="#scroll-mode">
      <ComponentTitle>Scroll Mode</ComponentTitle>
      <ComponentDescription style={{padding: "0 10px 10px 10px"}}>Display all tools with scrollable navigation and customizable scroll buttons.</ComponentDescription>
    </Component>
  </Column>
  <Column count={[24,24,8]} style={{marginBottom: "1rem"}}>
    <Component className="tile" href="#section-mode">
      <ComponentTitle>Section Mode</ComponentTitle>
      <ComponentDescription style={{padding: "0 10px 10px 10px"}}>Show overflowing tools in a popup while maintaining their initial layout.</ComponentDescription>
    </Component>
  </Column>
  <Column count={[24,24,8]} style={{marginBottom: "1rem"}}>
    <Component className="tile" href="#menu-mode">
      <ComponentTitle>Menu Mode</ComponentTitle>
      <ComponentDescription style={{padding: "0 10px 10px 10px"}}>Display tools that don't fit in a popup menu with customizable rendering.</ComponentDescription>
    </Component>
  </Column>
</Row>

## Scroll Mode

Setting the [`overflow`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#overflow) property of the ToolBar to `scroll` allows you to display all tools regardless of the component's width. In this mode, the ToolBar tools become scrollable and the component displays two scroll buttons for easier navigation.

The following example demonstrates how to make the ToolBar tools scrollable.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/scroll-mode/source.txt)

### Controlling Scroll Buttons Visibility

When the ToolBar is in scroll mode, you can control the visibility of the scroll buttons. To determine whether the buttons should always be visible, automatically displayed, or hidden based on your requirements, use the built-in [`scrollButtons`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#scrollbuttons) property which accepts the following values:

* `auto` (default)—The scroll buttons will be rendered only when the tools list overflows its container.
* `visible`—The scroll buttons will be always visible.
* `hidden`—No scroll buttons will be rendered.

The following example demonstrates how to dynamically update the value of the `scrollButtons` property.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/scroll-mode/visibility/source.txt)

### Adjusting Scroll Buttons Position

The scroll mode allows you to adjust the position of the scroll buttons in the ToolBar component. To render the buttons either at the beginning of the component, the end of the component, or at each side of the tools list, use the [`scrollButtonsPosition`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#scrollbuttonsposition) property and set its value to either of the following possible options:

* `split` (default)—The scroll buttons will be rendered at each side of the tools list.
* `start`—The scroll buttons will be rendered at the start before all tools.
* `end`—The scroll buttons will be rendered at the end after all tools.

The following example demonstrates how to use the `scrollButtonsPosition` property to adjust the scroll buttons' position.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/scroll-mode/position/source.txt)

### Customizing Scroll Buttons Icons

You can modify the icons used for the scroll buttons in the ToolBar. To replace the default icons with the ones that better fit your application's requirement, utilize the [`prevSVGButtonIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#prevsvgbuttonicon) and [`nextSVGButtonIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#nextsvgbuttonicon) properties.

> In case you have configured the application to [use font icons](https://www.telerik.com/kendo-angular-ui/components/icons/icon-settings#using-font-icons), use the [`prevButtonIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#prevbuttonicon) and [`nextButtonIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbaroverflowsettings#nextbuttonicon) properties.

The following example demonstrates how to change the default scroll buttons icons.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/scroll-mode/icons/source.txt)

## Section Mode

The section mode allows you to display overflowing ToolBar tools in a popup element while also maintaining the components used for their rendering and their initial layout. To enable this behavior, set the value of the [`overflow`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#overflow) property to `section`.

The following example demonstrates how to render overflowing ToolBar tools in a popup using their initial components and layout.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/section-mode/source.txt)

## Menu Mode

The menu mode of the ToolBar displays tools that don't fit within the component's width in a popup, which opens when a designated button is clicked. To enable this behavior, set the value of the [`overflow`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#overflow) property to `menu` or `true`.

The following example demonstrates how to display overflowing ToolBar tools in a menu popup element.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/basic-setup/source.txt)

### Customizing Tools Rendering

You can set the ToolBar tools to display their text or icon either in the ToolBar or in its overflow popup by using the [`showText`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarbuttoncomponent#showtext) or [`showIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarbuttoncomponent#showicon) properties of the corresponding tool.

To specify the text and icons visibility for all tools in the ToolBar at once, you also have the ability to define the [`showText`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#showtext) and [`showIcon`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#showicon) properties on the Toolbar component itself.

> The values of the `showText` and `showIcon` properties, declared on an individual tool, take priority over the values set on the ToolBar component itself.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/customize-overflow/source.txt)

### Customizing the Popup

You can customize the overflow button popup by setting the [`popupSettings`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#popupsettings) property of the Toolbar.

The [`popupSettings`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/toolbarcomponent#popupsettings) input allows you to configure the following options:

* [`animate`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/popupsettings#animate)—Controls the popup animation. By default, the open and close animations are enabled.
* [`popupClass`](https://www.telerik.com/kendo-angular-ui/components/toolbar/api/popupsettings#popupclass)—Specifies a list of CSS classes that are used to style the popup.

The following example demonstrates how to turn off the default open and close animations and assign a CSS class to the popup to customize its height.

[Demo Source](https://demos.telerik.com/kendo-angular-ui/demos/toolbar/responsive/popup-customization/source.txt)

## Suggested Links

* [API Reference of the ToolBar](https://www.telerik.com/kendo-angular-ui/components/toolbar/api)
* [ToolBar Appearance](https://www.telerik.com/kendo-angular-ui/components/toolbar/toolbar/appearance)
