Your IP : 216.73.216.26


Current Path : /home2/wtmwscom/public_html/post/Track and Trace_files/
Upload File :
Current File : /home2/wtmwscom/public_html/post/Track and Trace_files/OutSystemsReactWidgets.js

define("OutSystems/ReactWidgets/AdvancedHtml",["require","exports","tslib","react","OutSystems/ReactView/Widget"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t=r.createFactory(this.props.tag);if(t){var e={"data-advancedhtml":""};return this.fillWithBuiltinProperties(e),t(e,this.props.children)}return null},e=i.__decorate([n.WidgetSpec],e)}(n.Widget);e.AdvancedHtml=o}),define("OutSystems/ReactWidgets/Button",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.handleClick=function(t){var e=this;if(t.preventDefault(),t.stopPropagation(),this.props.confirmationMessage&&this.props.confirmationMessage.length){var i=navigator.notification;i?i.confirm(this.props.confirmationMessage,function(t){1===t&&e.executeWithActiveClassOn(function(){return e.props.onClick()})},""):window.confirm(this.props.confirmationMessage)&&this.executeWithActiveClassOn(function(){return e.props.onClick()})}else this.executeWithActiveClassOn(function(){return e.props.onClick()})},e.prototype.render=function(){var t=this,e={"data-button":"",className:this.props.style,type:this.props.isDefault?"submit":"button",disabled:!this.props.enabled,onClick:function(e){return t.handleClick(e)}};return this.fillWithBuiltinProperties(e),n.DOM.button(e,this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Button=o}),define("OutSystems/ReactWidgets/ButtonGroup",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ClientRuntime/DataTypes","react"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.selectedValue=null,e}return i.__extends(e,t),e.prototype.syncSelectedValueWithProps=function(){var t=this;this.selectedValue=null;var e=!1;o.Children.forEach(this.props.children,function(i){e=e||i&&i.props&&n.equals(t.props.variable.value,i.props.value)}),this.selectedValue=e?this.props.variable.value:null},e.prototype.componentDidUpdate=function(){this.syncSelectedValueWithProps()},e.prototype.componentDidMount=function(){this.syncSelectedValueWithProps()},e.prototype.updateValue=function(t){var e=this;n.equals(this.props.variable.value,t)||(this.selectedValue=t,this.props.variable.value=t,this.props.onChange&&this.executeAfterPaint(function(){e.props.onChange()}))},Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.getHTMLNode()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.selectedValue},enumerable:!0,configurable:!0}),e.prototype.render=function(){var t=this,e=0,i=o.Children.map(this.props.children,function(i){return i&&i.props&&(i=o.cloneElement(i,{isSelected:n.equals(t.props.variable.value,i.props.value),enabled:i.props.enabled&&t.props.enabled,updateValueInParent:function(e){t.updateValue(e)},key:e})),e++,i}),r={"data-button-group":"",className:this.props.style};return this.fillWithBuiltinProperties(r),o.DOM.div(r,o.DOM.div(null,i),this.createValidationElement())},e=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.ButtonGroup=s}),define("OutSystems/ReactWidgets/ButtonGroupItem",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.handleClick=function(t){var e=this;this.executeWithActiveClassOn(function(){return e.props.updateValueInParent(e.props.value)})},e.prototype.render=function(){var t=this,e={"data-button-group-item":"",className:this.props.style+(this.props.isSelected?" button-group-selected-item":""),disabled:!this.props.enabled,onClick:function(e){return t.handleClick(e)}};return this.fillWithBuiltinProperties(e),n.DOM.button(e,this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.ButtonGroupItem=o}),define("OutSystems/ReactWidgets/Checkbox",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={value:e.variable.value},r}return i.__extends(e,t),e.prototype.onChange=function(t){var e=this,i=t.target;this.props.variable.value=i.checked,this.setState({value:i.checked},function(){e.props.onChange&&e.executeAfterPaint(function(){e.executeWithActiveClassOn(function(){return e.props.onChange()})})})},Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.getHTMLNode()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.htmlElement.checked},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){return this.htmlElement.validity},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),e.prototype.updateValue=function(t){this.setState({value:t})},e.prototype.componentWillReceiveProps=function(t){this.props.variable.value!==t.variable.value&&this.updateValue(t.variable.value)},e.prototype.render=function(){var t=this,e={"data-checkbox":"",className:this.props.style,disabled:!this.props.enabled,type:"checkbox",onChange:function(e){return t.onChange(e)},onClick:function(t){return t.stopPropagation()},checked:this.state.value};return this.fillWithBuiltinProperties(e),n.DOM.span(null,n.DOM.input(e),this.createValidationElement())},e=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.Checkbox=o}),define("OutSystems/ReactWidgets/RadioButton",["require","exports","tslib","OutSystems/ClientRuntime/DataConversion","OutSystems/ClientRuntime/DataTypes","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(e,i){return t.call(this,e,i)||this}return i.__extends(e,t),e.prototype.onChange=function(t){var e=this,i=t.target;i.checked&&(this.props.variable.value=this.props.value,this.props.onChange&&this.executeAfterPaint(function(){e.executeWithActiveClassOn(function(){return e.props.onChange()})}))},e.prototype.render=function(){var t=this,e=this.props,o=e.variable,a=e.value,l={"data-radio":"",name:this.idServiceProperties.service.getId(this.props.groupName),value:r.JSConversions.convertTo(this.props.value,n.DataTypes.Text),className:this.props.style,disabled:!this.props.enabled,type:"radio",onChange:function(e){return t.onChange(e)},onClick:function(t){return t.stopPropagation()},checked:n.equals(o.value,a)};return this.fillWithBuiltinProperties(l),s.createElement("input",i.__assign({},l))},e=i.__decorate([o.WidgetSpec],e)}(o.Widget);e.RadioButton=a}),define("OutSystems/ReactWidgets/Container",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ReactView/AnimatedGroup","OutSystems/ReactView/ScrollExtensions","react"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}i.__extends(e,t),a=e,e.toHtmlAlign=function(t){switch(t){case 2:return"center";case 1:return"left";case 3:return"right";case 0:return;default:return}},e.prototype.serializeCustomStateProperties=function(){return o.serializeScrollProperties(this.getHTMLNode())},e.prototype.loadCustomStateProperties=function(t){o.loadScrollProperties(this.getHTMLNode(),t)},Object.defineProperty(e.prototype,"skipRenderWhenHidden",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.render=function(){var t=null;if(this.props.visible){var e={textAlign:a.toHtmlAlign(this.props.align),cursor:this.props.extendedEvents&&this.props.extendedEvents.onClick?"pointer":void 0},i={"data-container":"",className:this.props.style,style:e};this.fillWithBuiltinProperties(i),t=s.DOM.div(i,this.props.children)}return this.props.animate?s.createElement(n.AnimatedGroup,{},t):t};var a;return e=a=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Container=a}),define("OutSystems/ReactWidgets/DropdownNative",["require","exports","tslib","OutSystems/ReactView/Widget","react","OutSystems/ClientRuntime/DataTypes","OutSystems/ClientRuntime/DataConversion"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.selectedValue=null,r}i.__extends(e,t),a=e,Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.selectedValue},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){var t=this.selectedValue?!0:!1,e={valid:t,badInput:!1};return e},enumerable:!0,configurable:!0}),e.prototype.componentDidMount=function(){this.setVariable()},e.prototype.componentDidUpdate=function(){this.setVariable()},e.prototype.isVariableDefined=function(){return!s.JSConversions.isDefault(this.props.variable.value)},e.prototype.setVariable=function(){if(this.props.list&&this.props.list.length>0){var t=!1;if(this.isVariableDefined())for(var e=0;e<this.props.list.length;e++){var i=this.props.values(this.props.list.getItem(e));if(o.equals(i,this.props.variable.value)){t=!0;break}}if(t||this.isEmptyValueDefined())!t&&this.isVariableDefined()&&(this.props.variable.value=null);else{var r=this.props.values(this.props.list.getItem(0));o.equals(r,this.props.variable.value)||(this.props.variable.value=r,this.props.onChange&&this.props.onChange())}}},e.prototype.isEmptyValueDefined=function(){return this.props.emptyValue&&this.props.emptyValue.length>0},e.prototype.getSelectedValueAndOptions=function(){var t=0,e=[];if(this.isEmptyValueDefined()&&(t=-1,e.push(n.createElement("option",{key:-1,value:-1},this.props.emptyValue))),this.props.list&&this.props.list.length>0)for(var i=0;i<this.props.list.length;i++){var r=this.props.list.getItem(i);o.equals(this.variable.value,this.props.values(r))&&(t=i,this.selectedValue=this.variable.value);var a=s.JSConversions.convertTo(this.props.labels(r),o.DataTypes.Text);e.push(n.createElement("option",{key:i,value:i},a))}return{selectedValue:t,options:e}},e.prototype.handleChange=function(t){var e=parseInt(t.target.value,10),i=null;e>=0&&(i=this.props.values(this.props.list.getItem(e))),this.variable.value=i,this.selectedValue=i,this.props.onChange&&this.props.onChange()},e.prototype.render=function(){var t={className:a.DropdownContainer,"data-dropdown":""},e={className:a.DropdownDisplay+" "+this.props.style+(this.props.enabled?"":" "+a.DropdownDisabled),onChange:this.handleChange.bind(this),required:this.props.mandatory};this.fillWithBuiltinProperties(t);var r=this.getSelectedValueAndOptions(),o=r.selectedValue,s=r.options;return n.createElement("div",i.__assign({},t),n.createElement("select",i.__assign({},e,{value:o}),s),this.createValidationElement())};var a;return e.DropdownContainer="dropdown-container",e.DropdownDisplay="dropdown-display",e.DropdownDisabled="dropdown-disabled",e=a=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.DropdownNative=a}),define("OutSystems/ReactWidgets/DropdownCustom",["require","exports","tslib","OutSystems/ReactView/Widget","react","OutSystems/ClientRuntime/DataTypes","OutSystems/ClientRuntime/DataConversion"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.selectedValue=null,r.state={listVisible:!1,position:{left:"0px",top:"0px",width:"0px",height:"0px"}},r}i.__extends(e,t),a=e,e.prototype.select=function(t){this.variable.value===t?this.hide():(this.variable.value=t,this.selectedValue=t,this.setState({listVisible:!1}),this.props.onChange&&this.props.onChange())},Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.element},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.selectedValue},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){var t=this.selectedValue?!0:!1,e={valid:t,badInput:!1};return e},enumerable:!0,configurable:!0}),e.prototype.componentDidMount=function(){this.setVariable(),this.element=this.getHTMLNode(),this.updateState()},e.prototype.componentDidUpdate=function(){this.setVariable(),this.updateState()},e.prototype.setVariable=function(){if(this.props.list&&this.props.list.length>0){var t=!1;if(this.isVariableDefined())for(var e=0;e<this.props.list.length;e++){var i=this.props.values(this.props.list.getItem(e));if(o.equals(i,this.props.variable.value)){t=!0;break}}if(t||this.isEmptyValueDefined())!t&&this.isVariableDefined()&&(this.props.variable.value=null);else{var r=this.props.values(this.props.list.getItem(0));o.equals(r,this.props.variable.value)||(this.props.variable.value=r,this.props.onChange&&this.props.onChange())}}},e.prototype.show=function(){this.offsetLeft=this.htmlElement.getBoundingClientRect().left,this.setState({listVisible:!0})},e.prototype.hide=function(t){void 0===t&&(t=null),t&&t.stopPropagation(),this.setState({listVisible:!1})},e.prototype.updateState=function(){var t=this.getHTMLNode(),e=t.childNodes[0],i=e.childNodes[0],r=t.childNodes[1];if(r||(t.classList.remove(a.DropdownExpandedDown),t.classList.remove(a.DropdownExpandedUp),t.classList.remove(a.DropdownExpanded)),t&&e&&r&&i){var n={left:"",top:"",width:"",height:""},o=i.getBoundingClientRect(),s=e.getBoundingClientRect(),l=window.pageYOffset,p=window.pageXOffset,u=Math.round(o.left+p),c=Math.round(o.right+p),h=Math.round(s.top+l),d=Math.round(s.bottom+l),f=r.getBoundingClientRect(),g=Math.round(f.height),m=Math.round(f.width),y=l+window.innerHeight,v=(u+c)/2,b=void 0,w=void 0;window.innerWidth<=a.SmartphonePortraitWidth?(b=window.innerWidth-2*a.PopupBoxMargin,n.width=Math.round(b)+"px",w=p+a.PopupBoxMargin):(b=m,w=this.state.listVisible?this.offsetLeft:Math.max(p,v-b/2));var S,C=void 0,P=document.querySelector("[data-popup]"),R=P?P.getBoundingClientRect():null,x=R?R.top:l;h-x>y-d?(t.classList.add(a.DropdownExpanded,a.DropdownExpandedUp),t.classList.remove(a.DropdownExpandedDown),S=h-g,S<x-a.PopupBoxMargin&&(S=x+a.PopupBoxMargin,C=h-x-a.PopupBoxMargin,n.height=Math.round(C)+"px")):(t.classList.add(a.DropdownExpanded,a.DropdownExpandedDown),t.classList.remove(a.DropdownExpandedUp),S=d,S+g>y-a.PopupBoxMargin&&(C=y-d-a.PopupBoxMargin,n.height=Math.round(C)+"px")),n.left=Math.round(w)+"px",n.top=Math.round(S)+"px",(this.state.position.left!==n.left||this.state.position.top!==n.top||this.state.position.width!==n.width||this.state.position.height!==n.height&&""!==n.height)&&this.setState({position:n})}},e.prototype.isEmptyValueDefined=function(){return this.props.emptyValue&&this.props.emptyValue.length>0},e.prototype.isVariableDefined=function(){return!s.JSConversions.isDefault(this.props.variable.value)},e.prototype.prepareDropdownContainerAttributes=function(){var t={"data-dropdown":"",className:a.DropdownContainer+" "+this.props.style};return this.fillWithBuiltinProperties(t),t},e.prototype.prepareDropdownDisplayAttributes=function(){var t=this,e={className:a.DropdownDisplay+(this.props.enabled?"":" "+a.DropdownDisabled),onClick:function(e){e.stopPropagation(),t.props.enabled&&t.show()}};return e},e.prototype.renderEmptyValue=function(){var t=this,e=null,i=null;if(this.isEmptyValueDefined()){var r=n.DOM.span(null,this.props.emptyValue),o={className:a.DropdownPopUpRow+" "+a.DropdownEmptyValueRow+(this.isVariableDefined()?"":" "+a.DropdownPopUpRowSelected),onClick:function(e){t.props.variable.value=null,t.selectedValue=null,t.props.onChange&&t.props.onChange(),t.setState({listVisible:!1})}};i=n.DOM.div(o,r),this.isVariableDefined()||(e=r)}return{selectedElement:e,emptyValueItem:i}},e.prototype.renderDropdownList=function(t){var e=this,i=null,r=null,s={className:a.DropdownList,style:this.state.position};return i=n.DOM.div(s,n.DOM.div({className:a.ScrollableList+" "+a.ScrollableListWithScroll},t,this.props.placeholders.content.render(this,this.props.list,function(t,i){var s=null;s=e.props.values(e.props.list.getItem(i));var l={onClick:function(t){return e.select(s)},className:a.DropdownPopUpRow};return e.props.variable.value&&o.equals(s,e.props.variable.value)&&(r=t,e.selectedValue=e.props.variable.value,l.className=l.className+" "+a.DropdownPopUpRowSelected),n.DOM.div(l,t)}))),{list:i,selectedElement:r}},e.prototype.renderDropdownBackground=function(){var t=this;if(this.state.listVisible){var e={width:"100%",height:"100%",position:"fixed",top:"0px",left:"0px"},i=n.DOM.div({className:a.DropdownBackgroundWindow,style:e,onClick:function(e){return t.hide(e)}});return i}return null},e.prototype.render=function(){var t=this.renderEmptyValue(),e=this.renderDropdownList(t?t.emptyValueItem:null),i=this.prepareDropdownDisplayAttributes(),r=n.DOM.div(i,n.DOM.div({className:a.DropdownDisplayContent},e.selectedElement?e.selectedElement:t?t.selectedElement:null));return n.DOM.div(this.prepareDropdownContainerAttributes(),r,this.state.listVisible?e.list:null,this.renderDropdownBackground(),this.createValidationElement())};var a;return e.SmartphonePortraitWidth=420,e.PopupBoxMargin=10,e.DropdownList="dropdown-list",e.DropdownContainer="dropdown-container",e.DropdownDisplay="dropdown-display",e.DropdownDisplayContent="dropdown-display-content",e.DropdownDisabled="dropdown-disabled",e.DropdownPopUpRow="dropdown-popup-row",e.DropdownPopUpRowSelected="dropdown-popup-row-selected",e.DropdownEmptyValueRow="drowpdown-empty-value-row",e.DropdownBackgroundWindow="dropdown-background-window",e.ScrollableList="scrollable-list",e.ScrollableListWithScroll="scrollable-list-with-scroll",e.DropdownExpanded="dropdown-expanded",e.DropdownExpandedUp="dropdown-expanded-up",e.DropdownExpandedDown="dropdown-expanded-down",e=a=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.DropdownCustom=a}),define("OutSystems/ReactWidgets/Dropdown",["require","exports","tslib","OutSystems/ReactView/Widget","react","./DropdownNative","./DropdownCustom"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){return 1===this.props.dropdownMode?n.createElement(s.DropdownCustom,i.__assign({},this.props)):n.createElement(o.DropdownNative,i.__assign({},this.props))},e=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.Dropdown=a}),define("OutSystems/ReactWidgets/Expression",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t={"data-expression":"",className:this.props.style};return this.fillWithBuiltinProperties(t),n.DOM.span(t,this.props.value)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Expression=o}),define("OutSystems/ReactWidgets/List",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ReactView/AnimatedGroup","react-virtualized-list/virtualized-scroll-viewer","OutSystems/ReactView/ScrollExtensions","OutSystems/ClientRuntime/ObjectExtensions","react","OutSystems/ClientRuntime/Flow"],function(t,e,i,r,n,o,s,a,l,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var u="scroll",c="resize",h="orientationchange",d=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.previousListLength=0,r.shouldLoadState=!1,r.isScrollEndingEventHandlerRunning=!1,r.isVirtualizationEnabled=d.shouldVirtualizeList(e),r.shouldLoadState=t.prototype.getScreenStateCache.call(r).shouldLoad,r}i.__extends(e,t),d=e,e.prototype.serializeCustomStateProperties=function(){var t=this.getScrollHostInfo(),e=s.getScrollInfo(t.scrollHost);return{top:e.scroll.y,left:e.scroll.x}},e.prototype.loadCustomStateProperties=function(t){var e=t,i=this.getScrollViewer();if(i)i.scrollToOffset(e.left,e.top);else{var r=this.getScrollHostInfo().scrollHost;s.setScrollOffset(r,e.left,e.top)}},e.prototype.getInfiniteScrollThreshold=function(){if(void 0===this.infiniteScrollThreshold&&(this.infiniteScrollThreshold=2e3,this.props.extendedProperties)){var t=this.props.extendedProperties[d.InfiniteScrollThresholdName];void 0!==t&&(this.infiniteScrollThreshold=parseInt(t,10))}return this.infiniteScrollThreshold},e.prototype.getScreenStateCache=function(){var e=t.prototype.getScreenStateCache.call(this);return{navigationKey:e.navigationKey,shouldSave:e.shouldSave,shouldLoad:this.isVirtualizationEnabled?this.shouldLoadState:e.shouldLoad,state:e.state}},e.prototype.getChildContext=function(){var t=this;return{ancestorGenerationNode:this._generationNode,getScreenStateCache:function(){return t.getScreenStateCache()}}},e.prototype.getScrollHostInfo=function(){return this.scrollHostInfo||(this.scrollHostInfo=s.getScrollHostInfo(this.getHTMLNode())),this.scrollHostInfo},e.shouldVirtualizeList=function(t){return!t.extendedProperties||"true"!==(t.extendedProperties["disable-virtualization"]+"").toLowerCase()},e.prototype.componentDidMount=function(){var t=this;this.props.onScrollEnding&&this.executeAfterPaint(function(){if(!t.isDisposed){t.scrollHandler=function(){return t.tryFireScrollEndingEvent()},t.deferredScrollHandler=function(){return t.tryFireScrollEndingEvent(!0)};var e=t.getScrollHostInfo().scrollHost;e.addEventListener(u,t.scrollHandler),e.addEventListener(c,t.scrollHandler),window.addEventListener(h,t.deferredScrollHandler)}}),this.storeListLength()},e.prototype.componentDidUpdate=function(){this.props.onScrollEnding&&this.previousListLength!==this.props.source.length&&this.tryFireScrollEndingEvent(),this.storeListLength()},e.prototype.componentWillUpdate=function(t,e){this.isVirtualizationEnabled=d.shouldVirtualizeList(t)},e.prototype.storeListLength=function(){0!==this.props.source_dataFetchStatus&&this.props.source.length>0&&(this.previousListLength=this.props.source.length)},e.prototype.componentWillUnmount=function(){if(this.scrollHandler){var t=this.getScrollHostInfo().scrollHost;t.removeEventListener(u,this.scrollHandler),t.removeEventListener(c,this.scrollHandler)}this.deferredScrollHandler&&window.removeEventListener(h,this.deferredScrollHandler),this.scrollHostInfo=null},e.prototype.tryFireScrollEndingEvent=function(t){if(void 0===t&&(t=!1),!this.isScrollEndingEventHandlerRunning){var e=this.getInfiniteScrollThreshold(),i=this.getScrollHostInfo(),r=s.getScrollInfo(i.scrollHost);r.scroll.y>0&&r.scroll.y>this.lastScrollTop||t?r.scroll.height<=r.scroll.y+r.viewport.height+e&&this.executeScrollEndingEventHandler():(r.scroll.x>0&&r.scroll.x>this.lastScrollLeft||t)&&r.scroll.width<=r.scroll.x+r.viewport.width+e&&this.executeScrollEndingEventHandler(),this.lastScrollTop=r.scroll.y,this.lastScrollLeft=r.scroll.x}},e.prototype.executeScrollEndingEventHandler=function(){var t=this;this.isScrollEndingEventHandlerRunning=!0,p.tryFinally(this.props.onScrollEnding,function(){t.isScrollEndingEventHandlerRunning=!1})},e.prototype.renderListItems=function(t,e){return this.props.source.length>0?this.props.placeholders.content.render(this,this.props.source,null,t,e):null},e.prototype.getScrollViewer=function(){return this.refs[d.ScrollViewerComponentRef]},e.prototype.shouldSuspendAnimations=function(){if(1!==Math.abs(this.previousListLength-this.props.source.length))return!0;if(this.isVirtualizationEnabled){var t=this.getScrollViewer();return!t||!t.isInitialized||t.isScrolling}return!1},e.prototype.renderListWrapper=function(t,e){var i=this;if(this.props.animateItems){var r={component:this.props.tag,shouldSuspendAnimations:function(){return i.shouldSuspendAnimations()}};return l.createElement(n.AnimatedGroup,a.assign({},t,r),e)}var o=l.createFactory(this.props.tag);return o(t,e)},e.prototype.render=function(){var t=this,e="";switch(this.props.source_dataFetchStatus){case 0:e=" list-loading";break;case 2:e=" list-error"}var i={"data-list":"","data-virtualization-disabled":this.isVirtualizationEnabled?null:"","data-animation-disabled":this.props.animateItems?null:"",className:this.props.style+e};if(this.fillWithBuiltinProperties(i),this.isVirtualizationEnabled){var r=void 0,n=void 0;this.props.extendedProperties&&(r=parseInt(this.props.extendedProperties[d.ViewportSafetyMarginBefore],10),n=parseInt(this.props.extendedProperties[d.ViewportSafetyMarginAfter],10));var s={renderWrapper:function(e){return t.renderListWrapper(i,e)},renderItems:function(e,i){return t.renderListItems(e,i)},length:this.props.source.length,ref:d.ScrollViewerComponentRef,viewportSafetyMarginBefore:r?r:null,viewportSafetyMarginAfter:n?n:null,initializationCompleted:function(){t.shouldLoadState=!1}};return l.createElement(o.VirtualizedScrollViewer,a.assign({},i,s))}return this.renderListWrapper(i,this.renderListItems())};var d;return e.ScrollViewerComponentRef="scrollViewer",e.InfiniteScrollThresholdName="infinite-scroll-threshold",e.ViewportSafetyMarginBefore="virtualization-threshold-before",e.ViewportSafetyMarginAfter="virtualization-threshold-after",e.childContextTypes=a.assign({getScreenStateCache:l.PropTypes.func},r.Widget.childContextTypes),e=d=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.List=d}),define("OutSystems/ReactWidgets/Swipeable",["require","exports","tslib","react","OutSystems/ClientRuntime/ObjectExtensions"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){var e=t.call(this)||this;return e.defaultState={x:null,y:null,swiping:!1,start:0},e.calculatePos=function(t){var i=t.changedTouches[0].clientX,r=t.changedTouches[0].clientY,n=e.state.x-i,o=e.state.y-r,s=Math.abs(n),a=Math.abs(o);return{deltaX:n,deltaY:o,absX:s,absY:a}},e.touchStart=function(t){t.touches.length>1||e.setState({start:Date.now(),x:t.touches[0].clientX,y:t.touches[0].clientY,swiping:!1})},e.touchMove=function(t){if(e.state.x&&e.state.y&&!(t.touches.length>1)){var i=!1,r=e.calculatePos(t);Math.abs(r.deltaX)>Math.abs(r.deltaY)&&t.preventDefault(),r.absX<e.props.delta&&r.absY<e.props.delta||(e.props.onSwiping&&e.props.onSwiping(t,r.deltaX,r.deltaY,r.absX,r.absY),r.absX>r.absY?r.deltaX>0?e.props.onSwipingLeft&&(e.props.onSwipingLeft(t,r.absX,e.state.x),i=!0):e.props.onSwipingRight&&(e.props.onSwipingRight(t,r.absX,e.state.x),i=!0):r.deltaY>0?e.props.onSwipingUp&&(e.props.onSwipingUp(t,r.absY),i=!0):e.props.onSwipingDown&&(e.props.onSwipingDown(t,r.absY),i=!0),e.setState({swiping:!0}),i&&t.preventDefault())}},e.touchEnd=function(t){if(e.state.swiping){var i=e.calculatePos(t),r=Date.now()-e.state.start,n=Math.sqrt(i.absX*i.absX+i.absY*i.absY)/r,o=n>e.props.flickThreshold;e.props.onSwiped&&e.props.onSwiped(t,i.deltaX,i.deltaY,o),i.absX>i.absY?i.deltaX>0?e.props.onSwipedLeft&&e.props.onSwipedLeft(t,i.deltaX,o):e.props.onSwipedRight&&e.props.onSwipedRight(t,i.deltaX,o):i.deltaY>0?e.props.onSwipedUp&&e.props.onSwipedUp(t,i.deltaY,o):e.props.onSwipedDown&&e.props.onSwipedDown(t,i.deltaY,o)}e.setState(e.defaultState)},e.state=e.defaultState,e}return i.__extends(e,t),e.prototype.render=function(){return r.DOM.div(n.assign({},this.props,{onTouchStart:this.touchStart,onTouchMove:this.touchMove,onTouchEnd:this.touchEnd}),this.props.children)},e.propTypes={onSwiped:r.PropTypes.func,onSwiping:r.PropTypes.func,onSwipingUp:r.PropTypes.func,onSwipingRight:r.PropTypes.func,onSwipingDown:r.PropTypes.func,onSwipingLeft:r.PropTypes.func,onSwipedUp:r.PropTypes.func,onSwipedRight:r.PropTypes.func,onSwipedDown:r.PropTypes.func,onSwipedLeft:r.PropTypes.func,flickThreshold:r.PropTypes.number,delta:r.PropTypes.number},e.defaultProps={flickThreshold:.6,delta:10},e}(r.Component);e.Swipeable=o}),define("OutSystems/ReactWidgets/ListItem",["require","exports","tslib","react","react-dom","OutSystems/ReactView/Widget","./Swipeable"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a;!function(t){var e;!function(t){t[t.RightVisible=0]="RightVisible",t[t.RightAction=1]="RightAction",t[t.LeftVisible=2]="LeftVisible",t[t.LeftAction=3]="LeftAction"}(e=t.Actions||(t.Actions={}));var i;!function(t){t[t.Left=0]="Left",t[t.Right=1]="Right"}(i=t.Directions||(t.Directions={}))}(a=e.SwipeActions||(e.SwipeActions={}));var l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t={"data-list-item":"","data-not-scrollable":"",onClick:this.props.containerClick,className:this.props.classProperty};return this.props.fillWithParentProperties(t),r.DOM.div(t,this.props.placeholderContent.render())},e}(r.Component);e.ListItemBasic=l;var p=function(t){function e(i,r){var o=t.call(this,i,r)||this;return o.touchWindowEventListener=function(t){o.unregisterTouchWindowEventListener(),o.animate()},o.handleTouch=function(t){o.propagateTouch||t.stopPropagation()},o.registerTouchWindowEventListener=function(){o.propagateTouch=!1,window.addEventListener(e.TouchStartEvent,o.touchWindowEventListener)},o.unregisterTouchWindowEventListener=function(){o.propagateTouch=!0,window.removeEventListener(e.TouchStartEvent,o.touchWindowEventListener)},o.onSwipingLeft=function(t,e,i){o.handleSwiping(!1,t,e,i)},o.onSwipingRight=function(t,e,i){o.handleSwiping(!0,t,e,i)},o.onSwiped=function(){var t=!1,i=!1;switch(o.setState({showRightButtons:!1,showLeftButtons:!1}),o.state.action){case a.Actions.RightVisible:o.registerTouchWindowEventListener(),t=!0;break;case a.Actions.LeftVisible:o.registerTouchWindowEventListener(),i=!0;break;case a.Actions.LeftAction:var r=o.refs[e.LeftReferenceName],s=n.findDOMNode(r).children[0];s&&(o.timeoutClickHandle=setTimeout(function(){return s.click()},o.props.animationTimeout));break;case a.Actions.RightAction:var l=o.refs[e.RightReferenceName],p=n.findDOMNode(l).children;if(p.length>0){var u=p[p.length-1];u&&(o.timeoutClickHandle=setTimeout(function(){return u.click()},o.props.animationTimeout))}}o.setState({deltaPixels:0,action:null,showRightButtons:t,showLeftButtons:i,swipingLeft:!1,swipingRight:!1,animating:!0,animatingFullSwipeRight:o.state.action===a.Actions.LeftAction,animatingFullSwipeLeft:o.state.action===a.Actions.RightAction}),o.startAnimationTimeout()},o.handleActionContainerClick=function(t){o.animate(),t.stopPropagation()},o.handleContentClick=function(t){o.state.showRightButtons||o.state.showLeftButtons||o.state.animating||o.props.containerClick(t)},o.state={deltaPixels:0,showRightButtons:!1,showLeftButtons:!1,swipingLeft:!1,swipingRight:!1,animating:!1,action:null,callActionWhenSwipingFarRight:!1,callActionWhenSwipingFarLeft:!1,lastContainerClass:"",shouldRenderActions:!1,animatingFullSwipeRight:!1,animatingFullSwipeLeft:!1},o.propagateTouch=!0,o.actionsMaxWidth=0,o.leftPlaceholderCache=null,o.rightPlaceholderCache=null,o.contentPlaceholderCache=null,o}
return i.__extends(e,t),e.prototype.startAnimationTimeout=function(){var t=this;this.clearAnimationTimeout(),this.animationTimeoutHandle=setTimeout(function(){t.setState({animating:!1,action:null,animatingFullSwipeRight:!1,animatingFullSwipeLeft:!1,shouldRenderActions:t.state.showLeftButtons||t.state.showRightButtons})},this.props.animationTimeout)},e.prototype.clearAnimationTimeout=function(){this.animationTimeoutHandle&&clearTimeout(this.animationTimeoutHandle)},e.prototype.clearClickTimeout=function(){this.timeoutClickHandle&&clearTimeout(this.timeoutClickHandle)},e.prototype.componentWillReceiveProps=function(t){this.leftPlaceholderCache=null,this.rightPlaceholderCache=null,this.contentPlaceholderCache=null},e.prototype.componentDidMount=function(){if(this.props.extendedProperties){var t=this.props.extendedProperties[e.SwipeLeftEdgeThresholdExtended],i=this.props.extendedProperties[e.SwipeRightEdgeThresholdExtended];t&&(this.swipeLeftEdgeThreshold=parseInt(t,10)),i&&(this.swipeRightEdgeThreshold=parseInt(i,10))}},e.prototype.componentDidUpdate=function(){this.state.lastContainerClass!==this.lastContainerClass&&this.setState({lastContainerClass:this.lastContainerClass})},e.prototype.componentWillUnmount=function(){this.clearAnimationTimeout(),this.clearClickTimeout(),this.unregisterTouchWindowEventListener()},e.prototype.updateElementCachedInfo=function(){var t=n.findDOMNode(this.refs[e.SwipeReferenceName]);if(!this.actionsMaxWidth){var i=t.querySelector("[data-list-item-action]");i&&(this.actionsMaxWidth=parseInt(window.getComputedStyle(i,null).getPropertyValue("max-width"),10))}this.leftActionsCount=t.getElementsByClassName(e.LeftActions)[0].getElementsByTagName(e.Button).length,this.rightActionsCount=t.getElementsByClassName(e.RightActions)[0].getElementsByTagName(e.Button).length,this.contentWidth=t.querySelector("[data-list-item-content]").clientWidth,e.deviceWidth=window.innerWidth||document.documentElement.clientWidth},e.prototype.showFullSwipe=function(){return this.state.action===a.Actions.LeftAction||this.state.action===a.Actions.RightAction||this.state.animatingFullSwipeLeft||this.state.animatingFullSwipeRight},e.prototype.getSwipeLeftEdgeThreshold=function(){return this.swipeLeftEdgeThreshold?this.swipeLeftEdgeThreshold:e.SwipeLeftEdgeDefaultThreshold},e.prototype.getSwipeRightEdgeThreshold=function(){return this.swipeRightEdgeThreshold?this.swipeRightEdgeThreshold:e.SwipeRightEdgeDefaultThreshold},e.prototype.getSwipeThresholdToTriggerAction=function(t){return this.state.showLeftButtons||this.state.showRightButtons?.75*this.actionsMaxWidth:t===a.Directions.Right?this.actionsMaxWidth*(Math.min(2,this.leftActionsCount)+.75):this.actionsMaxWidth*(Math.min(2,this.rightActionsCount)+.75)},e.prototype.handleSwiping=function(t,i,r,n){this.updateElementCachedInfo(),this.setState({shouldRenderActions:!0});var o=t?a.Directions.Right:a.Directions.Left;if(!this.swipingHandleStylesAndDelta(r,o,n)){var s=null;r>this.props.visibilityThreshold&&(s=t?a.Actions.LeftVisible:a.Actions.RightVisible);var l=t?this.props.callActionWhenSwipingFarRight:this.props.callActionWhenSwipingFarLeft;l&&r>this.getSwipeThresholdToTriggerAction(o)&&(s=t?a.Actions.LeftAction:a.Actions.RightAction);var p=r-e.SwipeStartThreshold;this.setState({deltaPixels:t?p:-p,action:s,swipingLeft:!t,swipingRight:t})}},e.prototype.getActionsPlaceholderStyle=function(t){var e=!t,i=e?this.leftActionsCount:this.rightActionsCount,r=e&&this.state.swipingRight||t&&this.state.swipingLeft,n=e&&this.state.showLeftButtons||t&&this.state.showRightButtons,o=e&&this.state.animatingFullSwipeRight||t&&this.state.animatingFullSwipeLeft;if(r){var s=0;return n&&!this.state.animating&&(s=i*this.actionsMaxWidth),{width:Math.abs(this.state.deltaPixels)+s+"px"}}return n?{width:i*this.actionsMaxWidth+"px"}:o?{width:this.contentWidth+"px"}:null},e.prototype.swipingHandleStylesAndDelta=function(t,e,i){return this.shouldAbort(e,i)?!0:(this.tryAnimate(e),!1)},e.prototype.shouldAbort=function(t,i){if(t===a.Directions.Right){if(i<this.getSwipeRightEdgeThreshold())return!0}else if(i>e.deviceWidth-this.getSwipeLeftEdgeThreshold())return!0;return this.state.animating?!0:t===a.Directions.Right?!this.leftActionsCount&&!this.state.showRightButtons||this.state.showLeftButtons&&!this.props.callActionWhenSwipingFarRight:!this.rightActionsCount&&!this.state.showLeftButtons||this.state.showRightButtons&&!this.props.callActionWhenSwipingFarLeft},e.prototype.tryAnimate=function(t){(t===a.Directions.Right&&this.state.showRightButtons||t===a.Directions.Left&&this.state.showLeftButtons)&&this.animate()},e.prototype.animate=function(){this.setState({showLeftButtons:!1,showRightButtons:!1,animating:!0}),this.startAnimationTimeout()},e.prototype.getContainerClass=function(){if(this.state.animating)return this.state.lastContainerClass;var t=null;return t=this.state.showRightButtons?e.FloatRight:this.state.showLeftButtons?e.FloatLeft:this.state.deltaPixels<0?e.FloatRight:e.FloatLeft},e.prototype.getRenderedLeftPlaceholder=function(){return this.state.shouldRenderActions?(null===this.leftPlaceholderCache&&(this.leftPlaceholderCache=this.props.placeholderLeftActions.render()),this.leftPlaceholderCache):null},e.prototype.getRenderedRightPlaceholder=function(){return this.state.shouldRenderActions?(null===this.rightPlaceholderCache&&(this.rightPlaceholderCache=this.props.placeholderRightActions.render()),this.rightPlaceholderCache):null},e.prototype.getRenderedContentPlaceholder=function(){return null===this.contentPlaceholderCache&&(this.contentPlaceholderCache=this.props.placeholderContent.render()),this.contentPlaceholderCache},e.prototype.render=function(){this.lastContainerClass=this.getContainerClass();var t=e.Container+(this.showFullSwipe()?" "+e.FullSwipe:"");this.state.animating&&(t+=" "+e.Animating),this.state.showRightButtons&&(t+=" "+e.ShowRightButtons),this.state.showLeftButtons&&(t+=" "+e.ShowLeftButtons);var i={"data-list-item-content":"","data-not-scrollable":"",className:this.props.classProperty,onSwipingLeft:this.onSwipingLeft,onClick:this.handleContentClick,onSwipingRight:this.onSwipingRight,delta:e.SwipeStartThreshold,onSwiped:this.onSwiped};return this.props.fillWithParentProperties(i),r.DOM.div({"data-list-item":"","data-not-scrollable":""},r.DOM.div({className:t+" "+this.lastContainerClass,ref:e.SwipeReferenceName,onTouchStart:this.handleTouch},r.DOM.div({className:e.LeftActions,style:this.getActionsPlaceholderStyle(!1),onClick:this.handleActionContainerClick,ref:e.LeftReferenceName},this.getRenderedLeftPlaceholder()),r.createElement(s.Swipeable,i,this.getRenderedContentPlaceholder()),r.DOM.div({className:e.RightActions,style:this.getActionsPlaceholderStyle(!0),onClick:this.handleActionContainerClick,ref:e.RightReferenceName},this.getRenderedRightPlaceholder())))},e.LeftReferenceName="left-swipe-reference",e.RightReferenceName="right-swipe-reference",e.SwipeReferenceName="swipe-reference",e.TouchStartEvent="touchstart",e.Button="button",e.Container="list-item-container",e.LeftActions="list-item-left-actions",e.RightActions="list-item-right-actions",e.FloatRight="list-item-float-right",e.FloatLeft="list-item-float-left",e.FullSwipe="list-item-full-swipe",e.Animating="list-item-animating",e.ShowRightButtons="list-item-show-right-buttons",e.ShowLeftButtons="list-item-show-left-buttons",e.SwipeStartThreshold=15,e.SwipeLeftEdgeThresholdExtended="list-item-swipe-left-edge-threshold",e.SwipeRightEdgeThresholdExtended="list-item-swipe-right-edge-threshold",e.SwipeLeftEdgeDefaultThreshold=15,e.SwipeRightEdgeDefaultThreshold=15,e}(r.Component);e.ListItemSwipeable=p;var u=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.handleClick=function(t){e.props.onClick&&(t.stopPropagation(),e.executeWithActiveClassOn(function(){return e.props.onClick()}))},e}return i.__extends(e,t),e.prototype.render=function(){var t=this,e=this.props.placeholders.leftActions===o.PlaceholderContent.Empty,i=this.props.placeholders.rightActions===o.PlaceholderContent.Empty;return e&&i?r.createElement(l,{containerClick:this.handleClick,placeholderContent:this.props.placeholders.content,fillWithParentProperties:function(e){return t.fillWithBuiltinProperties(e)},classProperty:this.props.style},null):r.createElement(p,{extendedProperties:this.props.extendedProperties,visibilityThreshold:35,animationTimeout:400,placeholderContent:this.props.placeholders.content,placeholderLeftActions:this.props.placeholders.leftActions,placeholderRightActions:this.props.placeholders.rightActions,callActionWhenSwipingFarRight:this.props.triggerActionOnFullSwipeRight,callActionWhenSwipingFarLeft:this.props.triggerActionOnFullSwipeLeft,containerClick:this.handleClick,fillWithParentProperties:function(e){return t.fillWithBuiltinProperties(e)},classProperty:this.props.style},null)},e=i.__decorate([o.WidgetSpec],e)}(o.Widget);e.ListItem=u}),define("OutSystems/ReactWidgets/ListItemAction",["require","exports","tslib","react","OutSystems/ReactView/Widget"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.disableSpamProtect=r.disableSpamProtection(e),r}return i.__extends(e,t),e.prototype.handleClick=function(t){var e=this;(!this.alreadyTriggered||this.disableSpamProtect)&&(this.executeWithActiveClassOn(function(){return e.props.onClick()}),this.alreadyTriggered=!0)},e.prototype.render=function(){var t=this,e={"data-list-item-action":"",className:this.props.style,onClick:function(e){return t.handleClick(e)}};return this.fillWithBuiltinProperties(e),r.DOM.button(e,this.props.children)},e.prototype.disableSpamProtection=function(t){return!!t.extendedProperties&&"true"!==(t.extendedProperties["disable-spam-protection"]+"").toLowerCase()},e=i.__decorate([n.WidgetSpec],e)}(n.Widget);e.ListItemAction=o}),define("OutSystems/ReactWidgets/TableRecords",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ClientRuntime/ObjectExtensions","react"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.state={sortAttribute:""},e}return i.__extends(e,t),e.prototype.setDataHeaderInRowCells=function(){for(var t=this.body?this.body.getElementsByTagName("tr"):[],e=this.header?this.header.getElementsByTagName("th"):[],i=0;i<e.length;i++)for(var r=e[i].innerText,n=0;n<t.length;n++)t[n].getElementsByTagName("td")[i].setAttribute("data-header",r)},e.prototype.componentDidMount=function(){this.setDataHeaderInRowCells()},e.prototype.componentDidUpdate=function(){this.setDataHeaderInRowCells()},e.prototype.renderHeader=function(){var t=this,e={className:this.props.styleHeader};return this.props.showHeader?o.createElement("thead",{ref:function(e){return t.header=e}},o.createElement("tr",i.__assign({},e),this.props.placeholders.headerRow.render())):null},e.prototype.renderRows=function(){var t=this,e={className:this.props.styleRow};return this.props.source.length>0?o.createElement("tbody",{ref:function(e){return t.body=e}},this.props.placeholders.row.render(this,this.props.source,function(t,r){return o.createElement("tr",i.__assign({},e),t)})):null},e.prototype.onSort=function(t){this.setState({sortAttribute:t}),this.props.onSort(t)},e.prototype.getChildContext=function(){var e=this,i=t.prototype.getChildContext.call(this);return this.props.onSort&&(i.onTableRecordsSort=function(t){return e.onSort(t)},i.tableRecordsCurrentSortAttribute=this.state.sortAttribute),i},e.prototype.render=function(){var t={className:this.props.style};return this.fillWithBuiltinProperties(t),o.createElement("table",i.__assign({},t),this.renderHeader(),this.renderRows())},e.childContextTypes=n.assign({onTableRecordsSort:o.PropTypes.func,tableRecordsCurrentSortAttribute:o.PropTypes.string},r.Widget.childContextTypes),e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.TableRecords=s}),define("OutSystems/ReactWidgets/HeaderCell",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ClientRuntime/ObjectExtensions","react"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.handleClick=function(t){t.preventDefault(),t.stopPropagation(),e.executeWithActiveClassOn(function(){return e.onSort(e.props.sortAttribute)})},e}return i.__extends(e,t),Object.defineProperty(e.prototype,"onSort",{get:function(){return this.context.onTableRecordsSort},enumerable:!0,configurable:!0}),e.prototype.shouldComponentUpdate=function(e,i,r){return this.context.tableRecordsCurrentSortAttribute!==r.tableRecordsCurrentSortAttribute||t.prototype.shouldComponentUpdate.call(this,e,i,r)},e.prototype.render=function(){var t,e=this.props.style||"",r={className:"sortable-icon"};"sortable"!==this.props.style&&this.props.sortAttribute&&(e+=" sortable",t=o.createElement("div",i.__assign({},r)));var n=this.context;"sorted"!==this.props.style&&n&&this.props.sortAttribute&&this.props.sortAttribute===n.tableRecordsCurrentSortAttribute&&(e+=" sorted"),e=e.trim();var s={className:e};return this.onSort&&this.props.sortAttribute&&(s.onClick=this.handleClick),this.fillWithBuiltinProperties(s),o.createElement("th",i.__assign({},s),this.props.children,t)},e.contextTypes=n.assign({onTableRecordsSort:o.PropTypes.func,tableRecordsCurrentSortAttribute:o.PropTypes.string},r.Widget.contextTypes),e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.HeaderCell=s}),define("OutSystems/ReactWidgets/RowCell",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t={className:this.props.style};return this.fillWithBuiltinProperties(t),n.createElement("td",i.__assign({},t),this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.RowCell=o}),define("OutSystems/ReactWidgets/Form",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),Object.defineProperty(e.prototype,"isValidationAggregator",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.render=function(){var t={"data-form":"",noValidate:!0,className:this.props.style,onSubmit:function(t){return t.preventDefault()}};return this.fillWithBuiltinProperties(t),n.DOM.form(t,this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.ValidationWidget);e.Form=o}),define("OutSystems/ReactWidgets/Icon",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t="";switch(this.props.iconSize){case 0:t="1x";break;case 1:t="2x";break;case 2:t="3x";break;case 3:t="4x";break;default:t="1x"}var e={"data-icon":"",className:(this.props.style?this.props.style:"")+" fa fa-"+this.props.icon+" fa-"+t};return this.fillWithBuiltinProperties(e),n.DOM.i(e)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Icon=o}),define("OutSystems/ReactWidgets/Image",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o;!function(t){function e(){var e=Date.now(),i=t.GC_HIGH_PRESSURE<n;t.map.forEach(function(t,r,o){t.referenceCount<=0&&(i||t.expireDate<e)&&(URL.revokeObjectURL(t.cachedObjectURL),o["delete"](r),n-=t.size)})}function i(i){var r=i.content,o=t.map.get(r);void 0!==o&&(o.referenceCount--,o.expireDate=Date.now()+t.TTL,t.map.set(r,o),t.GC_HIGH_PRESSURE<n&&e())}function r(e){var i=e.content,r=t.map.get(i);if(!i)return null;if(void 0===r){var o=e.toBlob();if(!o)return null;r={expireDate:0,referenceCount:0,cachedObjectURL:URL.createObjectURL(o),size:o.size},n+=r.size}return r.referenceCount++,t.map.set(i,r),r.cachedObjectURL}t.TTL=12e4,t.GC_INTERVAL=1e4,t.GC_HIGH_PRESSURE=52428800,t.map=new Map,t.interval=setInterval(t.gc,t.GC_INTERVAL);var n=0;t.gc=e,t.releaseURL=i,t.requestURL=r}(o||(o={}));var s=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={objectURL:null,hasError:!1},r}i.__extends(e,t),s=e,e.prototype.loadBinary=function(t){var e=this,i=this.props.imageContent.content;t.loadContent().then(function(r){var n=r.content;if(!e.state.objectURL||n!==i){var s=o.requestURL(t);e.setState({objectURL:s,hasError:!1})}})},e.prototype.componentWillMount=function(){s.isBinary(this.props)&&this.loadBinary(this.props.imageContent)},e.prototype.componentWillReceiveProps=function(t){s.isBinary(t)?t.imageContent.content!==this.props.imageContent.content&&(o.releaseURL(this.props.imageContent),this.loadBinary(t.imageContent)):this.setState({objectURL:this.state.objectURL,hasError:!1})},e.isBinary=function(t){return 2===t.type&&t.imageContent&&!t.imageContent.url},e.prototype.componentWillUnmount=function(){s.isBinary(this.props)&&o.releaseURL(this.props.imageContent)},e.prototype.prepareImageAttributes=function(){var t=this,e={"data-image":"",className:this.props.style,src:""};if(this.state.hasError)e.src=this.props.defaultImage;else{switch(this.props.type){case 1:e.src=this.props.url;break;case 2:this.props.imageContent&&this.props.imageContent.hasContent()?e.src=this.state.objectURL||this.props.imageContent.url:e.src=this.state.objectURL||this.props.defaultImage;break;default:e.src=this.props.image}e.onError=function(){t.props.defaultImage&&t.setState({objectURL:t.state.objectURL,hasError:!0})}}return this.fillWithBuiltinProperties(e),e},e.prototype.render=function(){return n.DOM.img(this.prepareImageAttributes())};var s;return e=s=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Image=s}),define("OutSystems/ReactWidgets/Throttling",["require","exports"],function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(){this.last=0}return t.prototype.dispose=function(){clearTimeout(this.deferTimerHandle),this.timeoutFunction&&this.timeoutFunction()},t.prototype.throttle=function(e,i){var r=this;void 0===i&&(i=t.DefaultThrottlingInterval);var n=(new Date).valueOf();this.last&&n<this.last+i?(clearTimeout(this.deferTimerHandle),this.timeoutFunction=function(){r.last=n,r.timeoutFunction=null,e()},this.deferTimerHandle=setTimeout(this.timeoutFunction,i)):(this.last=n,e())},t.DefaultThrottlingInterval=200,t.CustomThrottlingRuntimeAttribute="data-onchange-throttle-milliseconds",t.CustomThrottlingProperty="onchange-throttle-milliseconds",t}();e.Throttling=i}),define("OutSystems/ReactWidgets/Input",["require","exports","tslib","OutSystems/ReactView/Widget","./Throttling","OutSystems/ClientRuntime/DataTypes","OutSystems/ClientRuntime/DataConversion","react"],function(t,e,i,r,n,o,s,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var l=function(t){function e(e,i){var r=t.call(this,e,i)||this;if(r.props.extendedProperties){var o=r.props.extendedProperties[n.Throttling.CustomThrottlingProperty];"undefined"!=typeof o&&(r.throttleValue=parseInt(o,10));var s=r.props.extendedProperties[l.ShowDefaultValueProperty];"undefined"!=typeof s&&(r.ShowDefaultValue="true"===s.toLowerCase())}return r.state={value:r.convertFromModel(e.variable.value)},r.throttling=new n.Throttling,r}i.__extends(e,t),l=e,e.prototype.getCorrectDatePartForType=function(t,e){switch(this.props.inputType){case 5:return t.toString("yyyy-MM-ddTHH:mm");case 4:return t.toString("yyyy-MM-dd");case 3:return t.toString("HH:mm")}throw new Error("A correct datetime type is required")},e.prototype.convertFromModel=function(t){switch(this.props.inputType){case 4:case 5:case 3:return l.isNullDate(t)&&!this.ShowDefaultValue?"":this.getCorrectDatePartForType(t,this.props.inputType);case 2:return 0!==parseFloat(t)||this.ShowDefaultValue?t:"";default:return t}},e.isNullDate=function(t){return t.equals(o.DateTime.defaultValue)},Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.getHTMLNode()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.htmlElement.value},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){return this.htmlElement.validity},enumerable:!0,configurable:!0}),e.prototype.onChange=function(t){var e=this,i=t.target;this.variable.value=i.value,this.setState({value:i.value}),this.props.onChange&&this.throttling.throttle(function(){return e.props.onChange()},this.throttleValue)},e.prototype.preparePromptForBrowsersThatDontSupportHTML5=function(t){var e=this.htmlElement;switch(t){case 4:e.placeholder=o.Constants.FORMAT.defaultDateTimeFormat.dateFormat;break;case 3:e.placeholder=o.Constants.FORMAT.defaultDateTimeFormat.timeFormat;break;case 5:e.placeholder=o.Constants.FORMAT.defaultDateTimeFormat.dateTimeFormat}},e.prototype.componentDidMount=function(){var t=this.props.inputType;if(void 0===l.supportsHTML5Inputs){var e=this.htmlElement;e.type!==l.toInputHtmlType(t)?l.supportsHTML5Inputs=!1:l.supportsHTML5Inputs=!0}void 0!==this.props.prompt||4!==t&&5!==t&&3!==t||l.supportsHTML5Inputs||this.preparePromptForBrowsersThatDontSupportHTML5(t)},e.prototype.componentWillReceiveProps=function(t){var e=this.getHTMLNode(),i=t.variable.value.valueOf().toString(),r=s.JSConversions.convertTo(e.value,this.variable.type).valueOf().toString(),n=r===i;this.shouldUpdateValue(t.variable)&&!n&&this.updateValue(t.variable.value)},e.prototype.componentWillUnmount=function(){this.throttling.dispose()},e.prototype.updateValue=function(t){this.setState({value:this.convertFromModel(t)})},e.toInputHtmlType=function(t){switch(t){case 0:return"text";case 1:return"password";case 2:return"number";case 3:return"time";case 4:return"date";case 5:return"datetime-local";case 6:return"tel";case 7:return"email";case 8:return"search";default:return""}},e.prototype.shouldUseDefaultProperty=function(t){return!this.props.extendedProperties||!this.props.extendedProperties.hasOwnProperty(t)},e.prototype.render=function(){var t=this,e={"data-input":"",className:this.props.style,disabled:!this.props.enabled,required:this.props.mandatory,type:l.toInputHtmlType(this.props.inputType),placeholder:this.props.prompt,onChange:function(e){return t.onChange(e)},value:this.state.value.toString()};switch(this.throttleValue!==n.Throttling.DefaultThrottlingInterval&&(e[n.Throttling.CustomThrottlingRuntimeAttribute]=this.throttleValue),this.ShowDefaultValue!==l.ShowDefaultValueDefault&&(e[l.ShowDefaultValueRuntimeAttribute]=this.ShowDefaultValue),this.props.inputType){case 2:var i=this.props.variable.type;switch(i){case o.DataTypes.Integer:this.shouldUseDefaultProperty("pattern")&&(e.pattern="[0-9]*"),e.max=o.Constants.MAX_INTEGER_VALUE;break;case o.DataTypes.LongInteger:this.shouldUseDefaultProperty("pattern")&&(e.pattern="[0-9]*"),e.max=o.Constants.MAX_LONGINTEGER_VALUE.toString();break;case o.DataTypes.Currency:case o.DataTypes.Decimal:this.shouldUseDefaultProperty("pattern")&&(e.pattern="[0-9]+.[0-9]*"),this.shouldUseDefaultProperty("step")&&(e.step="any")}break;case 3:case 5:case 4:break;default:this.props.maxLength>0&&(e.maxLength=this.props.maxLength)}this.fillWithBuiltinProperties(e);var r={className:"input-"+e.type};return a.DOM.span(r,a.DOM.input(e),this.createValidationElement())};var l;return e.ShowDefaultValueDefault=!1,e.ShowDefaultValueRuntimeAttribute="data-show-default-value",e.ShowDefaultValueProperty="show-default-value",e.supportsHTML5Inputs=void 0,e=l=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.Input=l}),define("OutSystems/ReactWidgets/Label",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t={"data-label":"",className:this.props.style,htmlFor:this.getSiblingWidgetId(this.props.targetWidget)};return this.props.mandatory&&(t.className=(void 0===t.className?"":t.className+" ")+"mandatory"),this.props.gridProperties&&this.props.gridProperties.width&&(t.className=(void 0===t.className?"":t.className+" ")+"OSInline"),this.fillWithBuiltinProperties(t),n.DOM.label(t,this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Label=o}),define("OutSystems/ReactWidgets/Link",["require","exports","tslib","OutSystems/ReactView/Widget","react","react-router","OutSystems/ClientRuntime/Navigation"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.handleClick=function(t){var e=this;t.preventDefault(),t.stopPropagation();var i=function(){return e.executeWithActiveClassOn(function(){return e.props.onClick()})};if(this.props.confirmationMessage&&this.props.confirmationMessage.length){var r=navigator.notification;r?r.confirm(this.props.confirmationMessage,function(t){1===t&&i()},""):window.confirm(this.props.confirmationMessage)&&i()}else i()},e.prototype.render=function(){var t,e=this,i={"data-link":"",className:this.props.style,disabled:!this.props.enabled,activeClassName:"active"};if(this.props.enabled&&(t=this.props.url||"javascript:void(0);",this.props.url?i.onClick=function(t){return t.stopPropagation()}:i.onClick=function(t){return e.handleClick(t)},this.props.url)){var r=s.getUrlInfo(this.props.url);if(r.isInternal)return i.to={pathname:r.path,query:r.queryParams,state:{transition:this.props.transition}},this.fillWithBuiltinProperties(i),n.createElement(o.Link,i,this.props.children)}return i.href=t,this.fillWithBuiltinProperties(i),n.DOM.a(i,this.props.children)},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Link=a}),define("OutSystems/ReactWidgets/Popup",["require","exports","tslib","OutSystems/ReactView/Widget","react","OutSystems/ReactView/Portal","OutSystems/ReactView/AnimatedGroup"],function(t,e,i,r,n,o,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}i.__extends(e,t),a=e,e.prototype.componentDidMount=function(){this.focusFirstFocusableElement()},e.prototype.componentWillUnmount=function(){this.disableScroll(!1)},e.prototype.componentWillMount=function(){this.disableScroll(this.props.showPopup)},e.prototype.componentWillUpdate=function(t){this.disableScroll(t.showPopup)},e.prototype.disableScroll=function(t){t?document.body.classList.add(a.DisableScrollClass):document.body.classList.remove(a.DisableScrollClass)},e.prototype.focusFirstFocusableElement=function(){if(this.props.showPopup){var t=this.getHTMLNode().querySelector("input, button, textarea, select, a");t&&t.focus()}},e.prototype.render=function(){if(this.props.showPopup){var t={"data-popup-backdrop":"",className:"popup-backdrop",onTouchMove:function(t){return t.stopPropagation()},transitionName:"popup-animation",component:"div",onClick:function(t){return t.stopPropagation()}},e={className:"popup-content",ref:a.ReferenceName},i={"data-popup":"",className:"popup-dialog "+this.props.style};this.fillWithBuiltinProperties(i);var r=n.DOM.div(i,n.DOM.div(e,this.props.children));return n.createElement(o.Portal,null,n.createElement(s.AnimatedGroup,t,r))}return null};var a;return e.DisableScrollClass="popup-disable-scroll",e=a=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Popup=a}),define("OutSystems/ReactWidgets/Placeholder",["require","exports","tslib","OutSystems/ReactView/ScrollExtensions","react","OutSystems/ReactView/Widget"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}i.__extends(e,t),s=e,e.toHtmlAlign=function(t){switch(t){case 2:return"center";case 1:return"left";case 3:return"right";default:return}},e.prototype.hasOrWillHaveChildren=function(t){return!0},e.prototype.serializeCustomStateProperties=function(){return r.serializeScrollProperties(this.getHTMLNode())},e.prototype.loadCustomStateProperties=function(t){r.loadScrollProperties(this.getHTMLNode(),t)},e.prototype.render=function(){var t={textAlign:s.toHtmlAlign(this.props.align),minHeight:this.props.height,cursor:this.props.extendedEvents&&this.props.extendedEvents.onClick?"pointer":void 0},e={className:this.props.style,style:t};return this.fillWithBuiltinProperties(e),n.DOM.div(e,this.props.content.render())};var s;return e=s=i.__decorate([o.WidgetSpec],e)}(o.Widget);e.Placeholder=s}),define("OutSystems/ReactWidgets/Popover",["require","exports","tslib","OutSystems/ReactView/Widget","react","react-dom"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={expanded:!1},r}i.__extends(e,t),s=e,e.prototype.show=function(t){t.stopPropagation(),this.setState({expanded:!0})},e.prototype.hide=function(t){t.stopPropagation(),this.setState({expanded:!1})},e.prototype.adjustPositionBasedOnViewport=function(){if(this.state.expanded){var t=o.findDOMNode(this.refs[s.bottomPlaceholderReference]),e="",i=t.getBoundingClientRect();i.left<0?(e="translateX(0)",t.style.left="0px",t.style.marginLeft="0px"):i.right>window.innerWidth?(e="translateX(0)",t.style.left="",t.style.right="0px"):e="translateX(-50%)",i.bottom>window.innerHeight&&(e+=" translateY(-100%)",t.style.marginTop="20px"),t.style.transform=e,t.style.webkitTransform=e}},e.prototype.componentDidUpdate=function(){this.adjustPositionBasedOnViewport()},e.prototype.componentDidMount=function(){this.adjustPositionBasedOnViewport()},e.prototype.preparePopoverAttributes=function(){var t={"data-popover":"",className:this.props.style};return this.fillWithBuiltinProperties(t),this.state.expanded&&(t.className+=" popover-expanded"),t},e.prototype.preparePopoverTopPlaceholderAttributes=function(){var t=this,e={className:"popover-top",onClick:function(e){return t.show(e)}};return e},e.prototype.preparePopoverBottomPlaceholderAttributes=function(){var t=this,e={width:this.props.popoverWidth?this.props.popoverWidth+"px":""},i={className:"popover-bottom ",onClick:function(e){return t.hide(e)},style:e,ref:s.bottomPlaceholderReference};return i},e.prototype.prepareBackgroundWindowAttributes=function(){var t=this,e={width:"100%",height:"100%",position:"fixed",top:"0px",left:"0px"},i={className:"popover-background-window",style:e,onClick:function(e){return t.hide(e)}};return i},e.prototype.render=function(){var t=n.DOM.div(this.preparePopoverTopPlaceholderAttributes(),this.props.placeholders.topContent.render()),e=null,i=null;return this.state.expanded&&(e=n.DOM.div(this.preparePopoverBottomPlaceholderAttributes(),this.props.placeholders.bottomContent.render()),i=n.DOM.div(this.prepareBackgroundWindowAttributes())),n.DOM.div(this.preparePopoverAttributes(),t,e,i)};var s;return e.bottomPlaceholderReference="bottom-placeholder-ref",e=s=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Popover=s}),define("OutSystems/ReactWidgets/Switch",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={value:e.variable.value},r}i.__extends(e,t),o=e,e.prototype.onChange=function(t){var e=this,i=t.target;this.props.variable.value=i.checked,
this.setState({value:i.checked},function(){e.props.onChange&&e.executeAfterPaint(function(){e.executeWithActiveClassOn(function(){return e.props.onChange()})})})},Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.getHTMLNode()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.htmlElement.checked},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){return this.htmlElement.validity},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),e.prototype.updateValue=function(t){this.setState({value:t})},e.prototype.componentWillReceiveProps=function(t){this.props.variable.value!==t.variable.value&&this.updateValue(t.variable.value)},e.prototype.render=function(){var t=this,e={"data-switch":"",className:this.props.style,disabled:!this.props.enabled,type:"checkbox",onChange:function(e){return t.onChange(e)},checked:this.state.value,ref:o.ReferenceName};return this.fillWithBuiltinProperties(e),n.DOM.span(null,n.DOM.input(e),this.createValidationElement())};var o;return e=o=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.Switch=o}),define("OutSystems/ReactWidgets/Text",["require","exports","tslib","OutSystems/ReactView/Widget","react"],function(t,e,i,r,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.render=function(){var t,e={className:this.props.style};return this.fillWithBuiltinProperties(e),(t=n.DOM).span.apply(t,[e].concat(this.props.text))},e=i.__decorate([r.WidgetSpec],e)}(r.Widget);e.Text=o}),define("OutSystems/ReactWidgets/TextArea",["require","exports","tslib","OutSystems/ReactView/Widget","./Throttling","react"],function(t,e,i,r,n,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={value:""},r.throttling=new n.Throttling,r}return i.__extends(e,t),e.prototype.onChange=function(t){var e=this,i=t.target;this.variable.value=i.value,this.setState({value:i.value}),this.props.onChange&&this.throttling.throttle(function(){return e.props.onChange()},this.throttleValue)},Object.defineProperty(e.prototype,"htmlElement",{get:function(){return this.getHTMLNode()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.htmlElement.value},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){return this.htmlElement.validity},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.variable},enumerable:!0,configurable:!0}),e.prototype.componentDidMount=function(){if(this.updateValue(this.props.variable.value),this.props.extendedProperties){var t=this.props.extendedProperties[n.Throttling.CustomThrottlingProperty];"undefined"!=typeof t&&(this.throttleValue=parseInt(t,10))}},e.prototype.updateValue=function(t){this.setState({value:t})},e.prototype.componentWillReceiveProps=function(t){this.props.variable.value!==t.variable.value&&this.updateValue(t.variable.value)},e.prototype.componentWillUnmount=function(){this.throttling.dispose()},e.prototype.render=function(){var t=this,e={"data-textarea":"",className:this.props.style,disabled:!this.props.enabled,required:this.props.mandatory,rows:this.props.textLines,placeholder:this.props.prompt,onChange:function(e){return t.onChange(e)},value:this.state.value.toString()};return this.props.maxLength>0&&(e.maxLength=this.props.maxLength),this.fillWithBuiltinProperties(e),o.DOM.span(null,o.DOM.textarea(e),this.createValidationElement())},e=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.TextArea=s}),define("OutSystems/ReactWidgets/Upload",["require","exports","tslib","OutSystems/ReactView/Widget","OutSystems/ClientRuntime/DataTypes","OutSystems/ClientRuntime/NativeHelper","react","react-dom"],function(t,e,i,r,n,o,s,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var l=function(t){function e(e,i){var r=t.call(this,e,i)||this;return r.state={value:null},r}i.__extends(e,t),l=e,Object.defineProperty(e.prototype,"isMandatory",{get:function(){return this.props.mandatory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"variable",{get:function(){return this.props.fileContent},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hiddenInput",{get:function(){return a.findDOMNode(this.refs[l.HiddenInput])},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValue",{get:function(){return this.variable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputedValueValidity",{get:function(){return this.hiddenInput.validity},enumerable:!0,configurable:!0}),e.prototype.getAcceptProperty=function(){var t;switch(this.props.accept){case 0:t="image/*";break;case 1:t="video/*";break;default:t=""}return t},e.prototype.success=function(t,e){var i=new n.BinaryData(t);this.props.fileName&&(this.props.fileName.value=e),this.variable.value=i,this.setState({value:i}),this.props.onChange&&this.props.onChange()},e.prototype.handleFileSelect=function(t){var e=this,i=t.target.files[0];if(i){var r=new FileReader,o=i.name;r.onload=function(t){var i=t.target.result,r=i.indexOf(";base64,"),s=i.substr(r+8),a=new n.BinaryData(s);e.props.fileName&&(e.props.fileName.value=o),e.variable.value=a,e.setState({value:a}),e.props.onChange&&e.props.onChange()},r.readAsDataURL(i)}},e.prototype.handleNativeFileSelect=function(){var t=this,e=window;if(!e.device)throw Error("Cordova should have loaded by now.");if(!e.filechooser)throw Error("Filechooser plugin should have loaded by now.");var i=!1;this.props.extendedProperties&&this.props.extendedProperties[l.Capture]&&(i=!0);var r={accept:this.getAcceptProperty(),capture:i};e.filechooser.select(r,function(e){return t.success(e.FileContent,e.FileName)},function(t){throw Error(t)})},e.prototype.isNativeAndSpecialVersion=function(){var t=window;return t.device&&o.isRunningOnNative()&&"android"===t.device.platform.toLowerCase()&&0===t.device.version.indexOf("4.4.2")?!0:!1},e.prototype.fileSelectHandlerOnClick=function(t){var e=this;o.ensureNativeReady().then(function(){e.isNativeAndSpecialVersion()&&e.handleNativeFileSelect()})},e.prototype.componentWillReceiveProps=function(t){this.shouldUpdateValue(t.fileContent)&&this.updateValue(t.fileContent.value)},e.prototype.updateValue=function(t){this.setState({value:t})},e.prototype.render=function(){var t=this,e=this.getAcceptProperty(),i={display:"none"},r={type:"file",accept:e,style:i,onChange:function(e){return t.handleFileSelect(e)},onClick:function(e){return t.fileSelectHandlerOnClick(e)},ref:l.HiddenInput,required:this.props.mandatory},n=this.props.extendedProperties;if(n)for(var o in n)"style"!==o&&(r[o]=n[o]);var a={"data-upload":"",className:this.props.style};this.variable.value.hasContent()&&(a.className+=" uploaded"),this.fillWithBuiltinProperties(a);var p={className:"upload-"+r.type},u=s.DOM.label(a,s.DOM.input(r),this.props.children);return s.DOM.span(p,u,this.createValidationElement())};var l;return e.HiddenInput="hiddenInput",e.Capture="capture",e=l=i.__decorate([r.WidgetSpec],e)}(r.InputWithVariableWidget);e.Upload=l}),define("OutSystems/ReactWidgets/Main",["require","exports","./AdvancedHtml","./Button","./ButtonGroup","./ButtonGroupItem","./Checkbox","./RadioButton","./Container","./Dropdown","./Expression","./List","./ListItem","./ListItemAction","./TableRecords","./HeaderCell","./RowCell","./Form","./Icon","./Image","./Input","./Label","./Link","./Popup","./Placeholder","./Popover","./Switch","./Text","./TextArea","./Upload"],function(t,e,i,r,n,o,s,a,l,p,u,c,h,d,f,g,m,y,v,b,w,S,C,P,R,x,O,W,D,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AdvancedHtml=i.AdvancedHtml,e.Button=r.Button,e.ButtonGroup=n.ButtonGroup,e.ButtonGroupItem=o.ButtonGroupItem,e.Checkbox=s.Checkbox,e.RadioButton=a.RadioButton,e.Container=l.Container,e.Dropdown=p.Dropdown,e.Expression=u.Expression,e.List=c.List,e.ListItem=h.ListItem,e.ListItemAction=d.ListItemAction,e.TableRecords=f.TableRecords,e.HeaderCell=g.HeaderCell,e.RowCell=m.RowCell,e.Form=y.Form,e.Icon=v.Icon,e.Image=b.Image,e.Input=w.Input,e.Label=S.Label,e.Link=C.Link,e.Popup=P.Popup,e.Placeholder=R.Placeholder,e.Popover=x.Popover,e.Switch=O.Switch,e.Text=W.Text,e.TextArea=D.TextArea,e.Upload=L.Upload,e.Version="1.0.0"});
// All licensing information regarding this source code can be found in the LICENSES.txt file.
//# sourceMappingURL=OutSystemsReactWidgets.js.map?ts=1575554076108