/**
 * Kendo UI v2023.3.1114 (http://www.telerik.com/kendo-ui)
 * Copyright 2023 Progress Software Corporation and/or one of its subsidiaries or affiliates. All rights reserved.
 *
 * Kendo UI commercial licenses may be obtained at
 * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete
 * If you do not own a commercial license, this file shall be governed by the trial license terms.
 */
import"./kendo.core.js";var __meta__={id:"floatinglabel",name:"FloatingLabel",category:"framework",depends:["core"],hidden:!0};!function(e,t){var n=window.kendo,o=n.ui.Widget,i=n.ui,l=".kendoFloatingLabel",a="k-empty",s="k-focus",d="k-disabled",r="k-no-click",p="k-readonly",g=o.extend({init:function(i,l){var a=this;o.fn.init.call(a,i,l),l=e.extend(!0,{},l),a.widget=a.options.widget,a.widgetWrapper=a.widget.wrapper[0],a.refresh(),a._editable({readonly:a.options.widget.options.readonly!==t&&a.options.widget.options.readonly,disable:a.options.widget.options.enable!==t&&!a.options.widget.options.enable}),a.widgetWrapper.style.width&&(a.element.css("width",a.widgetWrapper.style.width),a.widgetWrapper.style.width="100%"),a.element.addClass("k-floating-label-container"),n.notify(a)},options:{name:"FloatingLabel",widget:null,useReadOnlyClass:!1,floatCheck:({element:e})=>!e.val()},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},refresh:function(){var e=this,t=e.element;t.removeClass(a).removeClass(s),e.options.floatCheck({element:e.options.widget.element,floating:e.element})&&t.addClass(a),(document.activeElement===e.options.widget.element[0]||e.options.widget.input&&document.activeElement===e.options.widget.input[0])&&t.addClass(s)},destroy:function(){this.element.off(l),o.fn.destroy.call(this)},_editable:function(e){var t=this,n=t.element,o=e.disable,i=e.readonly;n.off(l),i||o?n.toggleClass(d,o).toggleClass(t.options.useReadOnlyClass?p:r,i):(n.removeClass(d).removeClass(t.options.useReadOnlyClass?p:r),n.on("focusin"+l,t.refresh.bind(t)),n.on("focusout"+l,t.refresh.bind(t)))}});i.plugin(g)}(window.kendo.jQuery);var kendo$1=kendo;export{kendo$1 as default};
//# sourceMappingURL=kendo.floatinglabel.js.map
