ToggleButton
Example
Razor
<kendo-togglebutton>
</kendo-togglebutton>
Attributes
| Attribute | Type | Description |
|---|---|---|
| name | String | Sets the name of the component. |
| as-module | Boolean | Specifies whether the initialization script of the component will be rendered as a JavaScript module. |
| is-in-client-template | Boolean | When placing a Tag Helper within a Kendo Template, set the type to text/html and add the is-in-client-template="true" attribute. |
| deferred | Boolean | Suppress initialization script rendering. Note that this options should be used in conjunction with DeferredScripts method. |
| enable | Boolean | Sets whether the component should be enabled or disabled. |
| fill-mode | FillMode | Sets a value controlling how the color is applied. |
| group | String | Specifies a group of ToggleButtons the current instance belongs to. The string will be rendered as a value of the data-group attribute of the widget's element. |
| icon | String | Sets the icon of the component. |
| icon-class | String | Sets the icon class of the component. |
| image-url | String | Sets the image url for the and img element inside the component. |
| on-click | String | The name of the JavaScript function that will handle the click event. Fires when the ToggleButton selected state is clicked. |
| on-toggle | String | The name of the JavaScript function that will handle the toggle event. Fires when the ToggleButton selected state is toggled. |
| rounded | Rounded | Sets a value controlling the border radius. |
| script-attributes | IDictionary<String,Object> | Sets the attributes that will be added to the script tag of the component's initialization script. |
| selected | Boolean | Specifies the selected state of the ToggleButtons. If set to true the widget will be initially selected. |
| size | ComponentSize | Sets the size of the component. |
| sprite-css-class | String | Sets the CSS class, which will be used for applying a background image to a span element inside the component. |
| tag | String | Sets the HTML tag to be rendered by the Button. Renders a button tag by default. |
| theme-color | ThemeColor | Sets the color of the component according to the applied theme. |