UNPKG

jqwidgets-scripts-custom

Version:

jQWidgets is an advanced jQuery, Angular 7, Vue, React, ASP .NET MVC, Custom Elements and HTML5 UI framework.

7 lines (6 loc) 8.66 kB
require('../../jqwidgets/jqxcore'); require('../../jqwidgets/jqxdata'); require('../../jqwidgets/jqxbuttons'); require('../../jqwidgets/jqxscrollbar'); require('../../jqwidgets/jqxtextarea'); !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core"),require("@angular/forms")):"function"==typeof define&&define.amd?define("jqwidgets-ng/jqxtextarea",["exports","@angular/core","@angular/forms"],e):e((t["jqwidgets-ng"]=t["jqwidgets-ng"]||{},t["jqwidgets-ng"].jqxtextarea={}),t.ng.core,t.ng.forms)}(this,function(t,e,r){"use strict";function i(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,i=r.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(h){o={error:h}}finally{try{n&&!n.done&&(r=i["return"])&&r.call(i)}finally{if(o)throw o.error}}return s}var n=function(){},o={provide:r.NG_VALUE_ACCESSOR,useExisting:e.forwardRef(function(){return s}),multi:!0},s=function(){function t(t){this.autoCreate=!0,this.properties=["disabled","displayMember","dropDownWidth","height","items","maxLength","minLength","opened","placeHolder","popupZIndex","query","renderer","roundedCorners","rtl","scrollBarSize","searchMode","source","theme","valueMember","width"],this.onTouchedCallback=n,this.onChangeCallback=n,this.onChange=new e.EventEmitter,this.onClose=new e.EventEmitter,this.onOpen=new e.EventEmitter,this.onSelect=new e.EventEmitter,this.elementRef=t}return t.prototype.ngOnInit=function(){this.autoCreate&&this.createComponent()},t.prototype.ngOnChanges=function(t){if(this.host)for(var e=0;e<this.properties.length;e++){var r="attr"+this.properties[e].substring(0,1).toUpperCase()+this.properties[e].substring(1),n=!1;if(this[r]!==undefined){if("object"==typeof this[r]){if(this[r]instanceof Array&&(n=this.arraysEqual(this[r],this.host.jqxTextArea(this.properties[e]))),n)return!1;this.host.jqxTextArea(this.properties[e],this[r]);continue}this[r]!==this.host.jqxTextArea(this.properties[e])&&this.host.jqxTextArea(this.properties[e],this[r])}}},t.prototype.arraysEqual=function(t,e){if(t&&!e||!t&&e)return!1;if(t.length!=e.length)return!1;for(var r=0;r<t.length;r++)if(t[r]!==e[r])return!1;return!0},t.prototype.manageAttributes=function(){for(var t={},e=0;e<this.properties.length;e++){var r="attr"+this.properties[e].substring(0,1).toUpperCase()+this.properties[e].substring(1);this[r]!==undefined&&(t[this.properties[e]]=this[r])}return t},t.prototype.moveClasses=function(t,e){var r,n=t.classList;0<n.length&&(r=e.classList).add.apply(r,function o(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(i(arguments[e]));return t}(n)),t.className=""},t.prototype.moveStyles=function(t,e){var r=t.style.cssText;e.style.cssText=r,t.style.cssText=""},t.prototype.createComponent=function(t){this.host||(t?JQXLite.extend(t,this.manageAttributes()):t=this.manageAttributes(),this.host=JQXLite(this.elementRef.nativeElement.firstChild),this.moveClasses(this.elementRef.nativeElement,this.host[0]),this.moveStyles(this.elementRef.nativeElement,this.host[0]),this.__wireEvents__(),this.widgetObject=jqwidgets.createInstance(this.host,"jqxTextArea",t))},t.prototype.createWidget=function(t){this.createComponent(t)},t.prototype.__updateRect__=function(){this.host&&this.host.css({width:this.attrWidth,height:this.attrHeight})},t.prototype.writeValue=function(t){this.widgetObject&&null!==t&&t!==undefined&&this.host.jqxTextArea("val",t)},t.prototype.registerOnChange=function(t){this.onChangeCallback=t},t.prototype.registerOnTouched=function(t){this.onTouchedCallback=t},t.prototype.setOptions=function(t){this.host.jqxTextArea("setOptions",t)},t.prototype.disabled=function(t){if(t===undefined)return this.host.jqxTextArea("disabled");this.host.jqxTextArea("disabled",t)},t.prototype.displayMember=function(t){if(t===undefined)return this.host.jqxTextArea("displayMember");this.host.jqxTextArea("displayMember",t)},t.prototype.dropDownWidth=function(t){if(t===undefined)return this.host.jqxTextArea("dropDownWidth");this.host.jqxTextArea("dropDownWidth",t)},t.prototype.height=function(t){if(t===undefined)return this.host.jqxTextArea("height");this.host.jqxTextArea("height",t)},t.prototype.items=function(t){if(t===undefined)return this.host.jqxTextArea("items");this.host.jqxTextArea("items",t)},t.prototype.maxLength=function(t){if(t===undefined)return this.host.jqxTextArea("maxLength");this.host.jqxTextArea("maxLength",t)},t.prototype.minLength=function(t){if(t===undefined)return this.host.jqxTextArea("minLength");this.host.jqxTextArea("minLength",t)},t.prototype.opened=function(t){if(t===undefined)return this.host.jqxTextArea("opened");this.host.jqxTextArea("opened",t)},t.prototype.placeHolder=function(t){if(t===undefined)return this.host.jqxTextArea("placeHolder");this.host.jqxTextArea("placeHolder",t)},t.prototype.popupZIndex=function(t){if(t===undefined)return this.host.jqxTextArea("popupZIndex");this.host.jqxTextArea("popupZIndex",t)},t.prototype.query=function(t){if(t===undefined)return this.host.jqxTextArea("query");this.host.jqxTextArea("query",t)},t.prototype.renderer=function(t){if(t===undefined)return this.host.jqxTextArea("renderer");this.host.jqxTextArea("renderer",t)},t.prototype.roundedCorners=function(t){if(t===undefined)return this.host.jqxTextArea("roundedCorners");this.host.jqxTextArea("roundedCorners",t)},t.prototype.rtl=function(t){if(t===undefined)return this.host.jqxTextArea("rtl");this.host.jqxTextArea("rtl",t)},t.prototype.scrollBarSize=function(t){if(t===undefined)return this.host.jqxTextArea("scrollBarSize");this.host.jqxTextArea("scrollBarSize",t)},t.prototype.searchMode=function(t){if(t===undefined)return this.host.jqxTextArea("searchMode");this.host.jqxTextArea("searchMode",t)},t.prototype.source=function(t){if(t===undefined)return this.host.jqxTextArea("source");this.host.jqxTextArea("source",t)},t.prototype.theme=function(t){if(t===undefined)return this.host.jqxTextArea("theme");this.host.jqxTextArea("theme",t)},t.prototype.valueMember=function(t){if(t===undefined)return this.host.jqxTextArea("valueMember");this.host.jqxTextArea("valueMember",t)},t.prototype.width=function(t){if(t===undefined)return this.host.jqxTextArea("width");this.host.jqxTextArea("width",t)},t.prototype.destroy=function(){this.host.jqxTextArea("destroy")},t.prototype.focus=function(){this.host.jqxTextArea("focus")},t.prototype.refresh=function(){this.host.jqxTextArea("refresh")},t.prototype.render=function(){this.host.jqxTextArea("render")},t.prototype.selectAll=function(){this.host.jqxTextArea("selectAll")},t.prototype.val=function(t){return t!==undefined?this.host.jqxTextArea("val",t):this.host.jqxTextArea("val")},t.prototype.__wireEvents__=function(){var e=this;this.host.on("change",function(t){e.onChange.emit(t),e.onChangeCallback(e.host.val())}),this.host.on("close",function(t){e.onClose.emit(t)}),this.host.on("open",function(t){e.onOpen.emit(t)}),this.host.on("select",function(t){e.onSelect.emit(t)}),this.host.on("keyup",function(){e.onChangeCallback(e.host.val())})},t.decorators=[{type:e.Component,args:[{selector:"jqxTextArea",template:"<div><ng-content></ng-content></div>",providers:[o],changeDetection:e.ChangeDetectionStrategy.OnPush}]}],t.ctorParameters=function(){return[{type:e.ElementRef}]},t.propDecorators={attrDisabled:[{type:e.Input,args:["disabled"]}],attrDisplayMember:[{type:e.Input,args:["displayMember"]}],attrDropDownWidth:[{type:e.Input,args:["dropDownWidth"]}],attrItems:[{type:e.Input,args:["items"]}],attrMaxLength:[{type:e.Input,args:["maxLength"]}],attrMinLength:[{type:e.Input,args:["minLength"]}],attrOpened:[{type:e.Input,args:["opened"]}],attrPlaceHolder:[{type:e.Input,args:["placeHolder"]}],attrPopupZIndex:[{type:e.Input,args:["popupZIndex"]}],attrQuery:[{type:e.Input,args:["query"]}],attrRenderer:[{type:e.Input,args:["renderer"]}],attrRoundedCorners:[{type:e.Input,args:["roundedCorners"]}],attrRtl:[{type:e.Input,args:["rtl"]}],attrScrollBarSize:[{type:e.Input,args:["scrollBarSize"]}],attrSearchMode:[{type:e.Input,args:["searchMode"]}],attrSource:[{type:e.Input,args:["source"]}],attrTheme:[{type:e.Input,args:["theme"]}],attrValueMember:[{type:e.Input,args:["valueMember"]}],attrWidth:[{type:e.Input,args:["width"]}],attrHeight:[{type:e.Input,args:["height"]}],autoCreate:[{type:e.Input,args:["auto-create"]}],onChange:[{type:e.Output}],onClose:[{type:e.Output}],onOpen:[{type:e.Output}],onSelect:[{type:e.Output}]},t}(),h=function(){function t(){}return t.decorators=[{type:e.NgModule,args:[{imports:[r.FormsModule],declarations:[s],exports:[s]}]}],t}();t.jqxTextAreaComponent=s,t.jqxTextAreaModule=h,Object.defineProperty(t,"__esModule",{value:!0})});