/** 
 * Copyright 2020 Progress Software Corporation and/or one of its subsidiaries or affiliates. All rights reserved.                                                                                      
 *                                                                                                                                                                                                      
 * Licensed under the Apache License, Version 2.0 (the "License");                                                                                                                                      
 * you may not use this file except in compliance with the License.                                                                                                                                     
 * You may obtain a copy of the License at                                                                                                                                                              
 *                                                                                                                                                                                                      
 *     http://www.apache.org/licenses/LICENSE-2.0                                                                                                                                                       
 *                                                                                                                                                                                                      
 * Unless required by applicable law or agreed to in writing, software                                                                                                                                  
 * distributed under the License is distributed on an "AS IS" BASIS,                                                                                                                                    
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.                                                                                                                             
 * See the License for the specific language governing permissions and                                                                                                                                  
 * limitations under the License.                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       

*/
!function(e,define){define("kendo.mobile.buttongroup.min",["kendo.core.min"],e)}(function(){return function(e,n){function t(e){return"k-"+e+" km-"+e}function i(n){return e('<span class="'+t("badge")+'">'+n+"</span>")}var s=window.kendo,a=s.mobile.ui,o=a.Widget,d="state-active",l="state-disabled",r="select",c="li:not(.km-"+d+")",u=o.extend({init:function(e,n){var i=this;o.fn.init.call(i,e,n),i.element.addClass("km-buttongroup k-widget k-button-group").find("li").each(i._button),i.element.on(i.options.selectOn,c,"_select"),i._enable=!0,i.select(i.options.index),i.options.enable||(i._enable=!1,i.wrapper.addClass(t(l)))},events:[r],options:{name:"ButtonGroup",selectOn:"down",index:-1,enable:!0},current:function(){return this.element.find(".km-"+d)},select:function(i){var s=this,a=-1;i!==n&&i!==-1&&s._enable&&!e(i).is(".km-"+l)&&(s.current().removeClass(t(d)),"number"==typeof i?(a=i,i=e(s.element[0].children[i])):i.nodeType&&(i=e(i),a=i.index()),i.addClass(t(d)),s.selectedIndex=a)},badge:function(n,t){var s,a=this.element;return isNaN(n)||(n=a.children().get(n)),n=a.find(n),s=e(n.children(".km-badge")[0]||i(t).appendTo(n)),t||0===t?(s.html(t),this):t===!1?(s.empty().remove(),this):s.html()},enable:function(e){n===e&&(e=!0),this.wrapper.toggleClass(t(l),!e),this._enable=this.options.enable=e},_button:function(){var n=e(this).addClass(t("button")),a=s.attrValue(n,"icon"),o=s.attrValue(n,"badge"),d=n.children("span"),l=n.find("img").addClass(t("image"));d[0]||(d=n.wrapInner("<span/>").children("span")),d.addClass(t("text")),!l[0]&&a&&n.prepend(e('<span class="'+t("icon")+" "+t(a)+'"/>')),(o||0===o)&&i(o).appendTo(n)},_select:function(e){e.which>1||e.isDefaultPrevented()||!this._enable||(this.select(e.currentTarget),this.trigger(r,{index:this.selectedIndex}))}});a.plugin(u)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,n,t){(t||n)()});
//# sourceMappingURL=kendo.mobile.buttongroup.min.js.map
