@syncfusion/ej2-react-base
Advanced tools
Comparing version 17.1.50 to 17.2.28-beta
@@ -7,22 +7,5 @@ # Changelog | ||
#### Bug Fixes | ||
- Provided option to prevent delay rendering of React components. | ||
## 17.1.49 (2019-05-29) | ||
### Common | ||
#### Bug Fixes | ||
- Resolved template rendering issue in splitter component in react. | ||
## 17.1.38 (2019-03-29) | ||
### Common | ||
#### New Features | ||
- Provided `react-final-form` support for Form components. | ||
- Provided complex template support in base. | ||
@@ -33,14 +16,2 @@ #### Bug Fixes | ||
## 17.1.32-beta (2019-03-13) | ||
### Common | ||
#### New Features | ||
- Provided `react-final-form` support for Form components. | ||
#### Bug Fixes | ||
- Resolved template rendering issue on state changes. | ||
## 16.4.52 (2019-02-05) | ||
@@ -47,0 +18,0 @@ |
/*! | ||
* filename: ej2-react-base.umd.min.js | ||
* version : 17.1.50 | ||
* version : 17.2.28-beta | ||
* Copyright Syncfusion Inc. 2001 - 2019. All rights reserved. | ||
@@ -10,3 +10,3 @@ * Use of this code is subject to the terms of our license. | ||
*/ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("react-dom"),require("@syncfusion/ej2-base")):"function"==typeof define&&define.amd?define(["exports","react","react-dom","@syncfusion/ej2-base"],t):t(e.ej={},e.React,e.ReactDOM,e.ej2Base)}(this,function(e,t,r,n){"use strict";function i(e,t){return"string"==typeof e?d(e,t):function(t){var i=document.createElement("div");document.body.appendChild(i);var o=e,s=t;return"object"==typeof o&&(o=e.template,s=n.extend({},t,e.data||{})),r.render(o(s),i),n.detach(i),i.children}}var o=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),s=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],p=["accordion","tab","splitter"],a=function(e){function i(){var t=null!==e&&e.apply(this,arguments)||this;return t.attrKeys=[],t.cachedTimeOut=0,t.isAppendCalled=!1,t}return o(i,e),i.prototype.componentWillMount=function(){var e=Object.keys(this.props);this.htmlattributes={},this.attrKeys=s.concat(this.controlAttributes||[]);for(var t=0,r=e;t<r.length;t++){var n=r[t];-1===n.indexOf("data-")&&-1===n.indexOf("aria-")&&-1===this.attrKeys.indexOf(n)||(this.htmlattributes[n]=this.props[n])}},i.prototype.componentDidMount=function(){var e=this;this.refreshChild(!0),this.canDelayUpdate=-1!==p.indexOf(this.getModuleName()),this.props.immediateRender?this.renderComponent():this.cachedTimeOut=setTimeout(function(){e.renderComponent()})},i.prototype.renderComponent=function(){var e=r.findDOMNode(this);e&&(this.isAppendCalled=!0,this.appendTo(e))},i.prototype.componentWillReceiveProps=function(e){var t=this;this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(r.findDOMNode(this)));for(var i=n.extend({},e),o=0,s=Object.keys(e);o<s.length;o++){var p=s[o],a="className"===p;a||n.isNullOrUndefined(this.htmlattributes[p])||this.htmlattributes[p]===i[p]||(this.htmlattributes[p]=i[p]),this.props[p]===e[p]?delete i[p]:-1!==this.attrKeys.indexOf(p)&&(a?(this.element.classList.remove(this.props[p]),this.element.classList.add(i[p])):"disabled"!==p&&delete i[p])}i.children&&delete i.children,this.canDelayUpdate||this.props.delayUpdate?setTimeout(function(){t.refreshProperties(i,e)}):this.refreshProperties(i,e)},i.prototype.refreshProperties=function(e,t){Object.keys(e).length&&(this.processComplexTemplate(e,this),this.setProperties(e)),this.refreshChild(!1,t)},i.prototype.processComplexTemplate=function(e,t){var r=t.complexTemplate;if(r)for(var i in r){var o=r[i];e[i]&&n.setValue(o,n.getValue(i,e),e)}},i.prototype.getDefaultAttributes=function(){return this.htmlattributes},i.prototype.trigger=function(e,t){if(!0!==this.isDestroyed){"change"!==e&&"input"!==e||this.props.onChange&&t.event&&this.props.onChange.call(void 0,{syntheticEvent:t.event,nativeEvent:{text:t.value},value:t.value,target:this});var r=this.isProtectedOnChange;this.isProtectedOnChange=!1,this.modelObserver.notify(e,t),this.isProtectedOnChange=r}},i.prototype.compareObjects=function(e,t){return JSON.stringify(e)===JSON.stringify(t)},i.prototype.refreshChild=function(e,t){if(this.checkInjectedModules){for(var r=this.getInjectedModules()||[],i=0,o=this.getInjectedServices()||[];i<o.length;i++){var s=o[i];-1===r.indexOf(s)&&r.push(s)}this.injectedModules=r}if(this.directivekeys){var p=this.validateChildren({},this.directivekeys,t||this.props);if(p){if(!e&&this.skipRefresh)for(var a=0,c=this.skipRefresh;a<c.length;a++){delete p[c[a]]}if(this.prevProperties)for(var h=Object.keys(this.prevProperties),l=0;l<h.length;l++){var u=h[l];this.compareObjects(this.prevProperties[u],p[u])?delete p[u]:this.prevProperties=n.extend(this.prevProperties,p)}else this.prevProperties=n.extend({},p,{},!0);this.setProperties(p,e)}}},i.prototype.componentWillUnmount=function(){this.destroy()},i.prototype.validateChildren=function(e,r,n){for(var i=!1,o=0,s=t.Children.toArray(n.children);o<s.length;o++){var p=s[o],a=this.getChildType(p),c=r[a];if(a&&r){var h=this.getChildProps(t.Children.toArray(p.props.children),c);h.length&&(i=!0,e[p.type.propertyName||a]=h)}}return i?e:null},i.prototype.getChildType=function(e){return e.type&&e.type.isDirective?e.type.moduleName||"":""},i.prototype.getChildProps=function(e,t){for(var r=[],i=0,o=e;i<o.length;i++){var s=o[i],p=!1,a=void 0;"string"==typeof t?(p=!0,a=t):a=Object.keys(t)[0];var c=s.props;if(this.getChildType(s)===a)if(p||!c.children){var h=n.extend({},c,{},!0);this.processComplexTemplate(h,s.type),r.push(h)}else{var l=this.validateChildren(n.extend({},c),t[a],c)||c;l.children&&delete l.children,this.processComplexTemplate(l,s.type),r.push(l)}}return r},i.prototype.getInjectedServices=function(){for(var e=0,r=t.Children.toArray(this.props.children);e<r.length;e++){var n=r[e];if(n.type.isService)return n.props.services}return[]},i}(t.PureComponent),c=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),h=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return c(t,e),t.prototype.render=function(){return null},t.isDirective=!0,t}(t.PureComponent),l=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return l(t,e),t.prototype.render=function(){return null},t.isService=!0,t}(t.PureComponent),d=n.getTemplateEngine();n.setTemplateEngine({compile:i}),e.ComponentBase=a,e.applyMixins=function(e,t){t.forEach(function(t){Object.getOwnPropertyNames(t.prototype).forEach(function(r){e.prototype[r]=t.prototype[r]})})},e.ComplexBase=h,e.Inject=u,e.compile=i,Object.defineProperty(e,"__esModule",{value:!0})}); | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("react-dom"),require("@syncfusion/ej2-base")):"function"==typeof define&&define.amd?define(["exports","react","react-dom","@syncfusion/ej2-base"],t):t(e.ej={},e.React,e.ReactDOM,e.ej2Base)}(this,function(e,t,r,n){"use strict";function i(e,t){return"string"==typeof e?d(e,t):function(t){var i=document.createElement("div");document.body.appendChild(i);var o=e,s=t;return"object"==typeof o&&(o=e.template,s=n.extend({},t,e.data||{})),r.render(o(s),i),n.detach(i),i.children}}var o=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),s=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],p=["accordion","tab","splitter"],a=function(e){function i(){var t=null!==e&&e.apply(this,arguments)||this;return t.attrKeys=[],t.cachedTimeOut=0,t.isAppendCalled=!1,t}return o(i,e),i.prototype.componentWillMount=function(){var e=Object.keys(this.props);this.htmlattributes={},this.attrKeys=s.concat(this.controlAttributes||[]);for(var t=0,r=e;t<r.length;t++){var n=r[t];-1===n.indexOf("data-")&&-1===n.indexOf("aria-")&&-1===this.attrKeys.indexOf(n)||(this.htmlattributes[n]=this.props[n])}},i.prototype.componentDidMount=function(){var e=this;this.refreshChild(!0),this.canDelayUpdate=-1!==p.indexOf(this.getModuleName()),this.props.immediateRender?this.renderReactComponent():this.cachedTimeOut=setTimeout(function(){e.renderReactComponent()})},i.prototype.renderReactComponent=function(){var e=r.findDOMNode(this);e&&(this.isAppendCalled=!0,this.appendTo(e))},i.prototype.componentWillReceiveProps=function(e){var t=this;this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(r.findDOMNode(this)));for(var i=n.extend({},e),o=0,s=Object.keys(e);o<s.length;o++){var p=s[o],a="className"===p;a||n.isNullOrUndefined(this.htmlattributes[p])||this.htmlattributes[p]===i[p]||(this.htmlattributes[p]=i[p]),this.props[p]===e[p]?delete i[p]:-1!==this.attrKeys.indexOf(p)&&(a?(this.element.classList.remove(this.props[p]),this.element.classList.add(i[p])):"disabled"!==p&&delete i[p])}i.children&&delete i.children,this.canDelayUpdate||this.props.delayUpdate?setTimeout(function(){t.refreshProperties(i,e)}):this.refreshProperties(i,e)},i.prototype.refreshProperties=function(e,t){Object.keys(e).length&&(this.processComplexTemplate(e,this),this.setProperties(e)),this.refreshChild(!1,t)},i.prototype.processComplexTemplate=function(e,t){var r=t.complexTemplate;if(r)for(var i in r){var o=r[i];e[i]&&n.setValue(o,n.getValue(i,e),e)}},i.prototype.getDefaultAttributes=function(){return this.htmlattributes},i.prototype.trigger=function(e,t,r){if(!0!==this.isDestroyed){"change"!==e&&"input"!==e||this.props.onChange&&t.event&&this.props.onChange.call(void 0,{syntheticEvent:t.event,nativeEvent:{text:t.value},value:t.value,target:this});var n=this.isProtectedOnChange;this.isProtectedOnChange=!1,this.modelObserver.notify(e,t,r),this.isProtectedOnChange=n}},i.prototype.compareObjects=function(e,t){return JSON.stringify(e)===JSON.stringify(t)},i.prototype.refreshChild=function(e,t){if(this.checkInjectedModules){for(var r=this.getInjectedModules()||[],i=0,o=this.getInjectedServices()||[];i<o.length;i++){var s=o[i];-1===r.indexOf(s)&&r.push(s)}this.injectedModules=r}if(this.directivekeys){var p=this.validateChildren({},this.directivekeys,t||this.props);if(p){if(!e&&this.skipRefresh)for(var a=0,c=this.skipRefresh;a<c.length;a++){delete p[c[a]]}if(this.prevProperties)for(var h=Object.keys(this.prevProperties),l=0;l<h.length;l++){var u=h[l];this.compareObjects(this.prevProperties[u],p[u])?delete p[u]:this.prevProperties=n.extend(this.prevProperties,p)}else this.prevProperties=n.extend({},p,{},!0);this.setProperties(p,e)}}},i.prototype.componentWillUnmount=function(){this.destroy()},i.prototype.validateChildren=function(e,r,n){for(var i=!1,o=0,s=t.Children.toArray(n.children);o<s.length;o++){var p=s[o],a=this.getChildType(p),c=r[a];if(a&&r){var h=this.getChildProps(t.Children.toArray(p.props.children),c);h.length&&(i=!0,e[p.type.propertyName||a]=h)}}return i?e:null},i.prototype.getChildType=function(e){return e.type&&e.type.isDirective?e.type.moduleName||"":""},i.prototype.getChildProps=function(e,t){for(var r=[],i=0,o=e;i<o.length;i++){var s=o[i],p=!1,a=void 0;"string"==typeof t?(p=!0,a=t):a=Object.keys(t)[0];var c=s.props;if(this.getChildType(s)===a)if(p||!c.children){var h=n.extend({},c,{},!0);this.processComplexTemplate(h,s.type),r.push(h)}else{var l=this.validateChildren(n.extend({},c),t[a],c)||c;l.children&&delete l.children,this.processComplexTemplate(l,s.type),r.push(l)}}return r},i.prototype.getInjectedServices=function(){for(var e=0,r=t.Children.toArray(this.props.children);e<r.length;e++){var n=r[e];if(n.type.isService)return n.props.services}return[]},i}(t.PureComponent),c=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),h=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return c(t,e),t.prototype.render=function(){return null},t.isDirective=!0,t}(t.PureComponent),l=function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return l(t,e),t.prototype.render=function(){return null},t.isService=!0,t}(t.PureComponent),d=n.getTemplateEngine();n.setTemplateEngine({compile:i}),e.ComponentBase=a,e.applyMixins=function(e,t){t.forEach(function(t){Object.getOwnPropertyNames(t.prototype).forEach(function(r){e.prototype[r]=t.prototype[r]})})},e.ComplexBase=h,e.Inject=u,e.compile=i,Object.defineProperty(e,"__esModule",{value:!0})}); | ||
//# sourceMappingURL=ej2-react-base.umd.min.js.map |
@@ -36,11 +36,11 @@ import { Children, PureComponent } from 'react'; | ||
if (this.props.immediateRender) { | ||
this.renderComponent(); | ||
this.renderReactComponent(); | ||
} | ||
else { | ||
this.cachedTimeOut = setTimeout(() => { | ||
this.renderComponent(); | ||
this.renderReactComponent(); | ||
}); | ||
} | ||
} | ||
renderComponent() { | ||
renderReactComponent() { | ||
let ele = findDOMNode(this); | ||
@@ -52,2 +52,3 @@ if (ele) { | ||
} | ||
// tslint:disable-next-line:no-any | ||
componentWillReceiveProps(nextProps) { | ||
@@ -83,2 +84,3 @@ if (!this.isAppendCalled) { | ||
} | ||
// tslint:disable-next-line:no-any | ||
if (this.canDelayUpdate || this.props.delayUpdate) { | ||
@@ -95,2 +97,3 @@ setTimeout(() => { | ||
if (Object.keys(dProps).length) { | ||
// tslint:disable-next-line:no-any | ||
this.processComplexTemplate(dProps, this); | ||
@@ -116,3 +119,3 @@ this.setProperties(dProps); | ||
/* tslint:disable:no-any */ | ||
trigger(eventName, eventProp) { | ||
trigger(eventName, eventProp, successHandler) { | ||
if (this.isDestroyed !== true) { | ||
@@ -131,3 +134,3 @@ if ((eventName === 'change' || eventName === 'input')) { | ||
this.isProtectedOnChange = false; | ||
this.modelObserver.notify(eventName, eventProp); | ||
this.modelObserver.notify(eventName, eventProp, successHandler); | ||
this.isProtectedOnChange = prevDetection; | ||
@@ -134,0 +137,0 @@ } |
@@ -53,11 +53,11 @@ import { Children, PureComponent } from 'react'; | ||
if (this.props.immediateRender) { | ||
this.renderComponent(); | ||
this.renderReactComponent(); | ||
} | ||
else { | ||
this.cachedTimeOut = setTimeout(function () { | ||
_this.renderComponent(); | ||
_this.renderReactComponent(); | ||
}); | ||
} | ||
}; | ||
ComponentBase.prototype.renderComponent = function () { | ||
ComponentBase.prototype.renderReactComponent = function () { | ||
var ele = findDOMNode(this); | ||
@@ -69,2 +69,3 @@ if (ele) { | ||
}; | ||
// tslint:disable-next-line:no-any | ||
ComponentBase.prototype.componentWillReceiveProps = function (nextProps) { | ||
@@ -102,2 +103,3 @@ var _this = this; | ||
} | ||
// tslint:disable-next-line:no-any | ||
if (this.canDelayUpdate || this.props.delayUpdate) { | ||
@@ -114,2 +116,3 @@ setTimeout(function () { | ||
if (Object.keys(dProps).length) { | ||
// tslint:disable-next-line:no-any | ||
this.processComplexTemplate(dProps, this); | ||
@@ -135,3 +138,3 @@ this.setProperties(dProps); | ||
/* tslint:disable:no-any */ | ||
ComponentBase.prototype.trigger = function (eventName, eventProp) { | ||
ComponentBase.prototype.trigger = function (eventName, eventProp, successHandler) { | ||
if (this.isDestroyed !== true) { | ||
@@ -150,3 +153,3 @@ if ((eventName === 'change' || eventName === 'input')) { | ||
this.isProtectedOnChange = false; | ||
this.modelObserver.notify(eventName, eventProp); | ||
this.modelObserver.notify(eventName, eventProp, successHandler); | ||
this.isProtectedOnChange = prevDetection; | ||
@@ -153,0 +156,0 @@ } |
/*! | ||
* filename: ej2-react-base.min.js | ||
* version : 17.1.50 | ||
* version : 17.2.28-beta | ||
* Copyright Syncfusion Inc. 2001 - 2019. All rights reserved. | ||
@@ -10,3 +10,3 @@ * Use of this code is subject to the terms of our license. | ||
*/ | ||
this.ej=this.ej||{},this.ej.reactbase=function(t,e,r,n){"use strict";function i(t,e){e.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(r){t.prototype[r]=e.prototype[r]})})}function o(t,e){return"string"==typeof t?f(t,e):function(e){var i=document.createElement("div");document.body.appendChild(i);var o=t,s=e;return"object"==typeof o&&(o=t.template,s=n.extend({},e,t.data||{})),r.render(o(s),i),n.detach(i),i.children}}var s=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),p=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],a=["accordion","tab","splitter"],h=function(t){function i(){var e=null!==t&&t.apply(this,arguments)||this;return e.attrKeys=[],e.cachedTimeOut=0,e.isAppendCalled=!1,e}return s(i,t),i.prototype.componentWillMount=function(){var t=Object.keys(this.props);this.htmlattributes={},this.attrKeys=p.concat(this.controlAttributes||[]);for(var e=0,r=t;e<r.length;e++){var n=r[e];-1===n.indexOf("data-")&&-1===n.indexOf("aria-")&&-1===this.attrKeys.indexOf(n)||(this.htmlattributes[n]=this.props[n])}},i.prototype.componentDidMount=function(){var t=this;this.refreshChild(!0),this.canDelayUpdate=-1!==a.indexOf(this.getModuleName()),this.props.immediateRender?this.renderComponent():this.cachedTimeOut=setTimeout(function(){t.renderComponent()})},i.prototype.renderComponent=function(){var t=r.findDOMNode(this);t&&(this.isAppendCalled=!0,this.appendTo(t))},i.prototype.componentWillReceiveProps=function(t){var e=this;this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(r.findDOMNode(this)));for(var i=n.extend({},t),o=0,s=Object.keys(t);o<s.length;o++){var p=s[o],a="className"===p;a||n.isNullOrUndefined(this.htmlattributes[p])||this.htmlattributes[p]===i[p]||(this.htmlattributes[p]=i[p]),this.props[p]===t[p]?delete i[p]:-1!==this.attrKeys.indexOf(p)&&(a?(this.element.classList.remove(this.props[p]),this.element.classList.add(i[p])):"disabled"!==p&&delete i[p])}i.children&&delete i.children,this.canDelayUpdate||this.props.delayUpdate?setTimeout(function(){e.refreshProperties(i,t)}):this.refreshProperties(i,t)},i.prototype.refreshProperties=function(t,e){Object.keys(t).length&&(this.processComplexTemplate(t,this),this.setProperties(t)),this.refreshChild(!1,e)},i.prototype.processComplexTemplate=function(t,e){var r=e.complexTemplate;if(r)for(var i in r){var o=r[i];t[i]&&n.setValue(o,n.getValue(i,t),t)}},i.prototype.getDefaultAttributes=function(){return this.htmlattributes},i.prototype.trigger=function(t,e){if(!0!==this.isDestroyed){"change"!==t&&"input"!==t||this.props.onChange&&e.event&&this.props.onChange.call(void 0,{syntheticEvent:e.event,nativeEvent:{text:e.value},value:e.value,target:this});var r=this.isProtectedOnChange;this.isProtectedOnChange=!1,this.modelObserver.notify(t,e),this.isProtectedOnChange=r}},i.prototype.compareObjects=function(t,e){return JSON.stringify(t)===JSON.stringify(e)},i.prototype.refreshChild=function(t,e){if(this.checkInjectedModules){for(var r=this.getInjectedModules()||[],i=0,o=this.getInjectedServices()||[];i<o.length;i++){var s=o[i];-1===r.indexOf(s)&&r.push(s)}this.injectedModules=r}if(this.directivekeys){var p=this.validateChildren({},this.directivekeys,e||this.props);if(p){if(!t&&this.skipRefresh)for(var a=0,h=this.skipRefresh;a<h.length;a++)delete p[h[a]];if(this.prevProperties)for(var c=Object.keys(this.prevProperties),l=0;l<c.length;l++){var u=c[l];this.compareObjects(this.prevProperties[u],p[u])?delete p[u]:this.prevProperties=n.extend(this.prevProperties,p)}else this.prevProperties=n.extend({},p,{},!0);this.setProperties(p,t)}}},i.prototype.componentWillUnmount=function(){this.destroy()},i.prototype.validateChildren=function(t,r,n){for(var i=!1,o=0,s=e.Children.toArray(n.children);o<s.length;o++){var p=s[o],a=this.getChildType(p),h=r[a];if(a&&r){var c=this.getChildProps(e.Children.toArray(p.props.children),h);c.length&&(i=!0,t[p.type.propertyName||a]=c)}}return i?t:null},i.prototype.getChildType=function(t){return t.type&&t.type.isDirective?t.type.moduleName||"":""},i.prototype.getChildProps=function(t,e){for(var r=[],i=0,o=t;i<o.length;i++){var s=o[i],p=!1,a=void 0;"string"==typeof e?(p=!0,a=e):a=Object.keys(e)[0];var h=s.props;if(this.getChildType(s)===a)if(p||!h.children){var c=n.extend({},h,{},!0);this.processComplexTemplate(c,s.type),r.push(c)}else{var l=this.validateChildren(n.extend({},h),e[a],h)||h;l.children&&delete l.children,this.processComplexTemplate(l,s.type),r.push(l)}}return r},i.prototype.getInjectedServices=function(){for(var t=0,r=e.Children.toArray(this.props.children);t<r.length;t++){var n=r[t];if(n.type.isService)return n.props.services}return[]},i}(e.PureComponent),c=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return c(e,t),e.prototype.render=function(){return null},e.isDirective=!0,e}(e.PureComponent),u=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return u(e,t),e.prototype.render=function(){return null},e.isService=!0,e}(e.PureComponent),f=n.getTemplateEngine();return n.setTemplateEngine({compile:o}),t.ComponentBase=h,t.applyMixins=i,t.ComplexBase=l,t.Inject=d,t.compile=o,t}({},React,ReactDOM,ej.base),this.ejs=ej; | ||
this.ej=this.ej||{},this.ej.reactbase=function(t,e,r,n){"use strict";function i(t,e){e.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(r){t.prototype[r]=e.prototype[r]})})}function o(t,e){return"string"==typeof t?f(t,e):function(e){var i=document.createElement("div");document.body.appendChild(i);var o=t,s=e;return"object"==typeof o&&(o=t.template,s=n.extend({},e,t.data||{})),r.render(o(s),i),n.detach(i),i.children}}var s=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),p=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],a=["accordion","tab","splitter"],c=function(t){function i(){var e=null!==t&&t.apply(this,arguments)||this;return e.attrKeys=[],e.cachedTimeOut=0,e.isAppendCalled=!1,e}return s(i,t),i.prototype.componentWillMount=function(){var t=Object.keys(this.props);this.htmlattributes={},this.attrKeys=p.concat(this.controlAttributes||[]);for(var e=0,r=t;e<r.length;e++){var n=r[e];-1===n.indexOf("data-")&&-1===n.indexOf("aria-")&&-1===this.attrKeys.indexOf(n)||(this.htmlattributes[n]=this.props[n])}},i.prototype.componentDidMount=function(){var t=this;this.refreshChild(!0),this.canDelayUpdate=-1!==a.indexOf(this.getModuleName()),this.props.immediateRender?this.renderReactComponent():this.cachedTimeOut=setTimeout(function(){t.renderReactComponent()})},i.prototype.renderReactComponent=function(){var t=r.findDOMNode(this);t&&(this.isAppendCalled=!0,this.appendTo(t))},i.prototype.componentWillReceiveProps=function(t){var e=this;this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(r.findDOMNode(this)));for(var i=n.extend({},t),o=0,s=Object.keys(t);o<s.length;o++){var p=s[o],a="className"===p;a||n.isNullOrUndefined(this.htmlattributes[p])||this.htmlattributes[p]===i[p]||(this.htmlattributes[p]=i[p]),this.props[p]===t[p]?delete i[p]:-1!==this.attrKeys.indexOf(p)&&(a?(this.element.classList.remove(this.props[p]),this.element.classList.add(i[p])):"disabled"!==p&&delete i[p])}i.children&&delete i.children,this.canDelayUpdate||this.props.delayUpdate?setTimeout(function(){e.refreshProperties(i,t)}):this.refreshProperties(i,t)},i.prototype.refreshProperties=function(t,e){Object.keys(t).length&&(this.processComplexTemplate(t,this),this.setProperties(t)),this.refreshChild(!1,e)},i.prototype.processComplexTemplate=function(t,e){var r=e.complexTemplate;if(r)for(var i in r){var o=r[i];t[i]&&n.setValue(o,n.getValue(i,t),t)}},i.prototype.getDefaultAttributes=function(){return this.htmlattributes},i.prototype.trigger=function(t,e,r){if(!0!==this.isDestroyed){"change"!==t&&"input"!==t||this.props.onChange&&e.event&&this.props.onChange.call(void 0,{syntheticEvent:e.event,nativeEvent:{text:e.value},value:e.value,target:this});var n=this.isProtectedOnChange;this.isProtectedOnChange=!1,this.modelObserver.notify(t,e,r),this.isProtectedOnChange=n}},i.prototype.compareObjects=function(t,e){return JSON.stringify(t)===JSON.stringify(e)},i.prototype.refreshChild=function(t,e){if(this.checkInjectedModules){for(var r=this.getInjectedModules()||[],i=0,o=this.getInjectedServices()||[];i<o.length;i++){var s=o[i];-1===r.indexOf(s)&&r.push(s)}this.injectedModules=r}if(this.directivekeys){var p=this.validateChildren({},this.directivekeys,e||this.props);if(p){if(!t&&this.skipRefresh)for(var a=0,c=this.skipRefresh;a<c.length;a++)delete p[c[a]];if(this.prevProperties)for(var h=Object.keys(this.prevProperties),l=0;l<h.length;l++){var u=h[l];this.compareObjects(this.prevProperties[u],p[u])?delete p[u]:this.prevProperties=n.extend(this.prevProperties,p)}else this.prevProperties=n.extend({},p,{},!0);this.setProperties(p,t)}}},i.prototype.componentWillUnmount=function(){this.destroy()},i.prototype.validateChildren=function(t,r,n){for(var i=!1,o=0,s=e.Children.toArray(n.children);o<s.length;o++){var p=s[o],a=this.getChildType(p),c=r[a];if(a&&r){var h=this.getChildProps(e.Children.toArray(p.props.children),c);h.length&&(i=!0,t[p.type.propertyName||a]=h)}}return i?t:null},i.prototype.getChildType=function(t){return t.type&&t.type.isDirective?t.type.moduleName||"":""},i.prototype.getChildProps=function(t,e){for(var r=[],i=0,o=t;i<o.length;i++){var s=o[i],p=!1,a=void 0;"string"==typeof e?(p=!0,a=e):a=Object.keys(e)[0];var c=s.props;if(this.getChildType(s)===a)if(p||!c.children){var h=n.extend({},c,{},!0);this.processComplexTemplate(h,s.type),r.push(h)}else{var l=this.validateChildren(n.extend({},c),e[a],c)||c;l.children&&delete l.children,this.processComplexTemplate(l,s.type),r.push(l)}}return r},i.prototype.getInjectedServices=function(){for(var t=0,r=e.Children.toArray(this.props.children);t<r.length;t++){var n=r[t];if(n.type.isService)return n.props.services}return[]},i}(e.PureComponent),h=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return h(e,t),e.prototype.render=function(){return null},e.isDirective=!0,e}(e.PureComponent),u=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return u(e,t),e.prototype.render=function(){return null},e.isService=!0,e}(e.PureComponent),f=n.getTemplateEngine();return n.setTemplateEngine({compile:o}),t.ComponentBase=c,t.applyMixins=i,t.ComplexBase=l,t.Inject=d,t.compile=o,t}({},React,ReactDOM,ej.base),this.ejs=ej; | ||
//# sourceMappingURL=ej2-react-base.min.js.map |
/*! | ||
* filename: index.d.ts | ||
* version : 17.1.50 | ||
* version : 17.2.28-beta | ||
* Copyright Syncfusion Inc. 2001 - 2019. All rights reserved. | ||
@@ -5,0 +5,0 @@ * Use of this code is subject to the terms of our license. |
{ | ||
"_from": "@syncfusion/ej2-react-base@*", | ||
"_id": "@syncfusion/ej2-react-base@17.1.49", | ||
"_id": "@syncfusion/ej2-react-base@17.2.1", | ||
"_inBundle": false, | ||
"_integrity": "sha512-mS3rDy+gxVC4Brj6YqWLvmCGsipEm2g6TkmKLS43zd4obm0egIj7JmOQOrT684XIpaZbB8ScO9fu+Ict/lasPg==", | ||
"_integrity": "sha512-qeXEvwoLsxxGugI4CWhuq+/UgH51UwVIOm87Ns2Ss3ShvO5JXKV+Sei++7zXCy1xFn8mRmTij/xQrSUzWBLvAg==", | ||
"_location": "/@syncfusion/ej2-react-base", | ||
@@ -21,19 +21,36 @@ "_phantomChildren": {}, | ||
"/", | ||
"/@syncfusion/ej2-react-barcode-generator", | ||
"/@syncfusion/ej2-react-buttons", | ||
"/@syncfusion/ej2-react-calendars", | ||
"/@syncfusion/ej2-react-charts", | ||
"/@syncfusion/ej2-react-circulargauge", | ||
"/@syncfusion/ej2-react-diagrams", | ||
"/@syncfusion/ej2-react-documenteditor", | ||
"/@syncfusion/ej2-react-dropdowns", | ||
"/@syncfusion/ej2-react-filemanager", | ||
"/@syncfusion/ej2-react-gantt", | ||
"/@syncfusion/ej2-react-grids", | ||
"/@syncfusion/ej2-react-heatmap", | ||
"/@syncfusion/ej2-react-inplace-editor", | ||
"/@syncfusion/ej2-react-inputs", | ||
"/@syncfusion/ej2-react-layouts", | ||
"/@syncfusion/ej2-react-lineargauge", | ||
"/@syncfusion/ej2-react-lists", | ||
"/@syncfusion/ej2-react-maps", | ||
"/@syncfusion/ej2-react-navigations", | ||
"/@syncfusion/ej2-react-notifications", | ||
"/@syncfusion/ej2-react-pdfviewer", | ||
"/@syncfusion/ej2-react-pivotview", | ||
"/@syncfusion/ej2-react-popups", | ||
"/@syncfusion/ej2-react-querybuilder", | ||
"/@syncfusion/ej2-react-richtexteditor", | ||
"/@syncfusion/ej2-react-schedule", | ||
"/@syncfusion/ej2-react-splitbuttons" | ||
"/@syncfusion/ej2-react-splitbuttons", | ||
"/@syncfusion/ej2-react-treegrid", | ||
"/@syncfusion/ej2-react-treemap" | ||
], | ||
"_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-react-base/-/ej2-react-base-17.1.49.tgz", | ||
"_shasum": "d6293c50d4fb0ac4a776771c20e3bd54c6276d2d", | ||
"_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-react-base/-/ej2-react-base-17.2.1.tgz", | ||
"_shasum": "723d6636397d7411280a0df7124fffc19903eac9", | ||
"_spec": "@syncfusion/ej2-react-base@*", | ||
"_where": "/jenkins/workspace/ation_hotfix_16.4.0.42_Vol4-CJVRBFC7Z7RSISPRJNEMNQSRMCB6XTG67IJD6R2DVNXFIKQEITTQ@2/packages/included", | ||
"_where": "/jenkins/workspace/ation_hotfix_16.4.0.42_Vol4-CJVRBFC7Z7RSISPRJNEMNQSRMCB6XTG67IJD6R2DVNXFIKQEITTQ/packages/included", | ||
"author": { | ||
@@ -47,3 +64,3 @@ "name": "Syncfusion Inc." | ||
"dependencies": { | ||
"@syncfusion/ej2-base": "~17.1.49" | ||
"@syncfusion/ej2-base": "~17.2.28-beta" | ||
}, | ||
@@ -77,4 +94,4 @@ "deprecated": false, | ||
}, | ||
"version": "17.1.50", | ||
"version": "17.2.28-beta", | ||
"sideEffects": true | ||
} |
@@ -33,3 +33,3 @@ /** | ||
componentDidMount(): void; | ||
private renderComponent; | ||
private renderReactComponent; | ||
componentWillReceiveProps(nextProps: any): void; | ||
@@ -39,3 +39,3 @@ refreshProperties(dProps: Object, nextProps: Object): void; | ||
getDefaultAttributes(): Object; | ||
trigger(eventName: string, eventProp?: any): void; | ||
trigger(eventName: string, eventProp?: any, successHandler?: any): void; | ||
compareObjects(oldProps: Object, newProps: Object): boolean; | ||
@@ -42,0 +42,0 @@ private refreshChild; |
@@ -52,11 +52,11 @@ var __extends = (this && this.__extends) || (function () { | ||
if (this.props.immediateRender) { | ||
this.renderComponent(); | ||
this.renderReactComponent(); | ||
} | ||
else { | ||
this.cachedTimeOut = setTimeout(function () { | ||
_this.renderComponent(); | ||
_this.renderReactComponent(); | ||
}); | ||
} | ||
}; | ||
ComponentBase.prototype.renderComponent = function () { | ||
ComponentBase.prototype.renderReactComponent = function () { | ||
var ele = ReactDOM.findDOMNode(this); | ||
@@ -68,2 +68,3 @@ if (ele) { | ||
}; | ||
// tslint:disable-next-line:no-any | ||
ComponentBase.prototype.componentWillReceiveProps = function (nextProps) { | ||
@@ -101,2 +102,3 @@ var _this = this; | ||
} | ||
// tslint:disable-next-line:no-any | ||
if (this.canDelayUpdate || this.props.delayUpdate) { | ||
@@ -113,2 +115,3 @@ setTimeout(function () { | ||
if (Object.keys(dProps).length) { | ||
// tslint:disable-next-line:no-any | ||
this.processComplexTemplate(dProps, this); | ||
@@ -134,3 +137,3 @@ this.setProperties(dProps); | ||
/* tslint:disable:no-any */ | ||
ComponentBase.prototype.trigger = function (eventName, eventProp) { | ||
ComponentBase.prototype.trigger = function (eventName, eventProp, successHandler) { | ||
if (this.isDestroyed !== true) { | ||
@@ -149,3 +152,3 @@ if ((eventName === 'change' || eventName === 'input')) { | ||
this.isProtectedOnChange = false; | ||
this.modelObserver.notify(eventName, eventProp); | ||
this.modelObserver.notify(eventName, eventProp, successHandler); | ||
this.isProtectedOnChange = prevDetection; | ||
@@ -152,0 +155,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
165182
1260
2
+ Added@syncfusion/ej2-base@17.2.49(transitive)
+ Added@syncfusion/ej2-icons@17.2.47(transitive)
- Removed@syncfusion/ej2-base@17.1.49(transitive)
- Removed@syncfusion/ej2-icons@17.1.47(transitive)