jqwidgets-scripts-custom
Version:
jQWidgets is an advanced jQuery, Angular 7, Vue, React, ASP .NET MVC, Custom Elements and HTML5 UI framework.
4 lines (3 loc) • 4.12 kB
JavaScript
require('../../jqwidgets/jqxcore');
require('../../jqwidgets/jqxbuttons');
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core")):"function"==typeof define&&define.amd?define("jqwidgets-ng/jqxlinkbutton",["exports","@angular/core"],e):e((t["jqwidgets-ng"]=t["jqwidgets-ng"]||{},t["jqwidgets-ng"].jqxlinkbutton={}),t.ng.core)}(this,function(t,e){"use strict";function s(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var i,o,s=n.call(t),r=[];try{for(;(void 0===e||0<e--)&&!(i=s.next()).done;)r.push(i.value)}catch(h){o={error:h}}finally{try{i&&!i.done&&(n=s["return"])&&n.call(s)}finally{if(o)throw o.error}}return r}var n=function(){function t(t){this.autoCreate=!0,this.properties=["disabled","height","rtl","theme","width"],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 n="attr"+this.properties[e].substring(0,1).toUpperCase()+this.properties[e].substring(1),i=!1;if(this[n]!==undefined){if("object"==typeof this[n]){if(this[n]instanceof Array&&(i=this.arraysEqual(this[n],this.host.jqxLinkButton(this.properties[e]))),i)return!1;this.host.jqxLinkButton(this.properties[e],this[n]);continue}this[n]!==this.host.jqxLinkButton(this.properties[e])&&this.host.jqxLinkButton(this.properties[e],this[n])}}},t.prototype.arraysEqual=function(t,e){if(t&&!e||!t&&e)return!1;if(t.length!=e.length)return!1;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!1;return!0},t.prototype.manageAttributes=function(){for(var t={},e=0;e<this.properties.length;e++){var n="attr"+this.properties[e].substring(0,1).toUpperCase()+this.properties[e].substring(1);this[n]!==undefined&&(t[this.properties[e]]=this[n])}return t},t.prototype.moveClasses=function(t,e){var n,i=t.classList;0<i.length&&(n=e.classList).add.apply(n,function o(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(s(arguments[e]));return t}(i)),t.className=""},t.prototype.moveStyles=function(t,e){var n=t.style.cssText;e.style.cssText=n,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,"jqxLinkButton",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.setOptions=function(t){this.host.jqxLinkButton("setOptions",t)},t.prototype.disabled=function(t){if(t===undefined)return this.host.jqxLinkButton("disabled");this.host.jqxLinkButton("disabled",t)},t.prototype.height=function(t){if(t===undefined)return this.host.jqxLinkButton("height");this.host.jqxLinkButton("height",t)},t.prototype.rtl=function(t){if(t===undefined)return this.host.jqxLinkButton("rtl");this.host.jqxLinkButton("rtl",t)},t.prototype.theme=function(t){if(t===undefined)return this.host.jqxLinkButton("theme");this.host.jqxLinkButton("theme",t)},t.prototype.width=function(t){if(t===undefined)return this.host.jqxLinkButton("width");this.host.jqxLinkButton("width",t)},t.prototype.__wireEvents__=function(){},t.decorators=[{type:e.Component,args:[{selector:"jqxLinkButton",template:"<div><ng-content></ng-content></div>"}]}],t.ctorParameters=function(){return[{type:e.ElementRef}]},t.propDecorators={attrDisabled:[{type:e.Input,args:["disabled"]}],attrRtl:[{type:e.Input,args:["rtl"]}],attrTheme:[{type:e.Input,args:["theme"]}],attrWidth:[{type:e.Input,args:["width"]}],attrHeight:[{type:e.Input,args:["height"]}],autoCreate:[{type:e.Input,args:["auto-create"]}]},t}(),i=function(){function t(){}return t.decorators=[{type:e.NgModule,args:[{imports:[],declarations:[n],exports:[n]}]}],t}();t.jqxLinkButtonComponent=n,t.jqxLinkButtonModule=i,Object.defineProperty(t,"__esModule",{value:!0})});