this.primereact=this.primereact||{},this.primereact.inputtext=function(t,e,r,n,o){"use strict";function i(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var p=i(e);function l(){return l=Object.assign||function(t){for(var e=1;e0||null!=this.props.defaultValue&&this.props.defaultValue.toString().length>0||this.elementRef&&this.elementRef.current&&null!=this.elementRef.current.value&&this.elementRef.current.value.toString().length>0}},{key:"onKeyPress",value:function(t){this.props.onKeyPress&&this.props.onKeyPress(t),this.props.keyfilter&&n.KeyFilter.onKeyPress(t,this.props.keyfilter,this.props.validateOnly)}},{key:"onInput",value:function(t){var e=!0;this.props.keyfilter&&this.props.validateOnly&&(e=n.KeyFilter.validate(t,this.props.keyfilter)),this.props.onInput&&this.props.onInput(t,e),this.props.onChange||(t.target.value.length>0?r.DomHandler.addClass(t.target,"p-filled"):r.DomHandler.removeClass(t.target,"p-filled"))}},{key:"updateForwardRef",value:function(){var t=this.props.forwardRef;t&&("function"==typeof t?t(this.elementRef.current):t.current=this.elementRef.current)}},{key:"componentDidMount",value:function(){this.updateForwardRef(),this.props.tooltip&&this.renderTooltip()}},{key:"componentDidUpdate",value:function(t){t.tooltip===this.props.tooltip&&t.tooltipOptions===this.props.tooltipOptions||(this.tooltip?this.tooltip.update(v({content:this.props.tooltip},this.props.tooltipOptions||{})):this.renderTooltip())}},{key:"componentWillUnmount",value:function(){this.tooltip&&(this.tooltip.destroy(),this.tooltip=null)}},{key:"renderTooltip",value:function(){this.tooltip=o.tip({target:this.elementRef.current,content:this.props.tooltip,options:this.props.tooltipOptions})}},{key:"render",value:function(){var t=r.classNames("p-inputtext p-component",{"p-disabled":this.props.disabled,"p-filled":this.isFilled()},this.props.className),e=r.ObjectUtils.findDiffKeys(this.props,g.defaultProps);return p.default.createElement("input",l({ref:this.elementRef},e,{className:t,onInput:this.onInput,onKeyPress:this.onKeyPress}))}}])&&u(y.prototype,b),m&&u(y,m),Object.defineProperty(y,"prototype",{writable:!1}),g}(e.Component);return b(P,"defaultProps",{keyfilter:null,validateOnly:!1,tooltip:null,tooltipOptions:null,onInput:null,onKeyPress:null,forwardRef:null}),t.InputText=p.default.forwardRef((function(t,e){return p.default.createElement(P,l({forwardRef:e},t))})),Object.defineProperty(t,"__esModule",{value:!0}),t}({},React,primereact.utils,primereact.keyfilter,primereact.tooltip);