Items
configurationA JavaScript array that contains the ToolBar's commands configuration.
For more information regarding supported commands and their configuration properties check the Getting Started topic.
items
Arrayitems.attributes
ObjectSpecifies the HTML attributes of a ToolBar button.
HTML attributes which are JavaScript keywords (e.g. class) must be quoted.
items.buttons
ArraySpecifies the buttons of ButtonGroup.
items.click
FunctionSpecifies the click event handler of the button. Applicable only for commands of type button and splitButton.
items.enable
BooleanSpecifies whether the control is initially enabled or disabled. Default value is "true".
Default: true
items.group
StringAssigns the button to a group. Applicable only for buttons with togglable: true.
items.hidden
BooleanDetermines if a button is visible or hidden. By default buttons are visible.
Default: false
items.icon
StringSets icon for the item. The icon should be one of the existing in the Kendo UI theme sprite.
items.id
StringSpecifies the ID of the button.
By design the widget will render two buttons - the one located in the ToolBar container will receive the specified ID, the one located in the Overflow Popup container will receive the specified ID but with _overflow suffix. If the ID will be used for determining which button is clicked in the
clickortoggleevent handler, the developer should use the ID property of the event data which always contains the specified ID without suffix.
items.imageUrl
StringIf set, the ToolBar will render an image with the specified URL in the button.
items.menuButtons
ArraySpecifies the menu buttons of a SplitButton or a DropDownButton.
items.overflow
StringSpecifies how the button, or the template behaves when the ToolBar is resized. Possible values are: "always", "never" or "auto" (default). If the items contains a template and overflow is set to always, the template will never be rendered. If the item contains an overflowTemplate and the overflow is set to never, the overflowTemplate will never be rendered.
Default: "auto"
items.overflowTemplate
String|FunctionSpecifies what element will be added in the command overflow popup. Applicable only for items that have a template.
items.primary
BooleanSpecifies whether the button is primary. Primary buttons receive different styling.
Default: false
items.selected
BooleanSpecifies if the toggle button is initially selected. Applicable only for buttons with togglable: true.
Default: false
items.showIcon
StringSpecifies where the button icon will be displayed. Possible values are: "toolbar", "overflow" or "both" (default).
Default: "both"
items.showText
StringSpecifies where the text will be displayed. Possible values are: "toolbar", "overflow" or "both" (default).
Default: "both"
items.spriteCssClass
StringDefines a CSS class (or multiple classes separated by spaces) which will be used for button icon.
items.template
String|FunctionSpecifies what element will be added in the ToolBar wrapper. Items with template does not have a type.
If
overflowTemplateis not defined for a template command, than the command will be treated asoverflow: "never".
items.text
StringSets the text of the button.
items.togglable
BooleanSpecifies if the button is togglable, e.g. has a selected and unselected state.
Buttons with
togglable: truewill fire thetoggleevent.clickevent will not be fired.
Default: false
items.toggle
FunctionSpecifies the toggle event handler of the button. Applicable only for commands of type button and togglable: true.
items.type
StringSpecifies the command type. Supported types are "button", "splitButton", "dropDownButton", "buttonGroup", "separator", "spacer".
Specifying the type is mandatory. Only commands that have a
templatedo not need atype.
items.url
StringSpecifies the url to navigate to.