gridjs-react
Advanced tools
Comparing version 3.4.0 to 4.0.0
@@ -1,2 +0,3 @@ | ||
import { createElement, createRef, Component } from 'react'; | ||
import * as React from 'react'; | ||
import { createRef, Component } from 'react'; | ||
import { Grid as Grid$1, h, createRef as createRef$1, Component as Component$1 } from 'gridjs'; | ||
@@ -53,6 +54,7 @@ import ReactDOM from 'react-dom'; | ||
Grid.prototype.componentDidUpdate = function () { | ||
console.log('XXXX'); | ||
this.instance.updateConfig(this.props).forceRender(); | ||
}; | ||
Grid.prototype.render = function () { | ||
return createElement("div", { ref: this.wrapper }); | ||
return React.createElement("div", { ref: this.wrapper }); | ||
}; | ||
@@ -59,0 +61,0 @@ return Grid; |
@@ -9,2 +9,23 @@ (function (global, factory) { | ||
function _interopNamespace(e) { | ||
if (e && e.__esModule) return e; | ||
var n = Object.create(null); | ||
if (e) { | ||
Object.keys(e).forEach(function (k) { | ||
if (k !== 'default') { | ||
var d = Object.getOwnPropertyDescriptor(e, k); | ||
Object.defineProperty(n, k, d.get ? d : { | ||
enumerable: true, | ||
get: function () { | ||
return e[k]; | ||
} | ||
}); | ||
} | ||
}); | ||
} | ||
n['default'] = e; | ||
return Object.freeze(n); | ||
} | ||
var React__namespace = /*#__PURE__*/_interopNamespace(React); | ||
var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM); | ||
@@ -60,6 +81,7 @@ | ||
Grid.prototype.componentDidUpdate = function () { | ||
console.log('XXXX'); | ||
this.instance.updateConfig(this.props).forceRender(); | ||
}; | ||
Grid.prototype.render = function () { | ||
return React.createElement("div", { ref: this.wrapper }); | ||
return React__namespace.createElement("div", { ref: this.wrapper }); | ||
}; | ||
@@ -66,0 +88,0 @@ return Grid; |
@@ -1,2 +0,2 @@ | ||
import{createElement as t,createRef as r,Component as n}from"react";import{Grid as e,h as o,createRef as p,Component as i}from"gridjs";import c from"react-dom"; | ||
import*as t from"react";import{createRef as r,Component as n}from"react";import{Grid as e,h as o,createRef as p,Component as i}from"gridjs";import c from"react-dom"; | ||
/*! ***************************************************************************** | ||
@@ -15,3 +15,3 @@ Copyright (c) Microsoft Corporation. | ||
PERFORMANCE OF THIS SOFTWARE. | ||
***************************************************************************** */var u=function(t,r){return(u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])})(t,r)};function s(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}u(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}var a=function(n){function o(t){var o=n.call(this,t)||this;return o.wrapper=r(),o.instance=null,o.instance=new e(t||{}),o}return s(o,n),o.prototype.getInstance=function(){return this.instance},o.prototype.componentDidMount=function(){this.instance.render(this.wrapper.current)},o.prototype.componentDidUpdate=function(){this.instance.updateConfig(this.props).forceRender()},o.prototype.render=function(){return t("div",{ref:this.wrapper})},o}(n),f=function(t){function r(){var r=null!==t&&t.apply(this,arguments)||this;return r.ref=p(),r}return s(r,t),r.prototype.componentDidMount=function(){c.render(this.props.element,this.ref.current)},r.prototype.render=function(){return o(this.props.parent,{ref:this.ref})},r.defaultProps={parent:"div"},r}(i);function l(t,r){return o(f,{element:t,parent:r})}export{a as Grid,f as ReactWrapper,l as _}; | ||
***************************************************************************** */var s=function(t,r){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])})(t,r)};function u(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}s(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}var a=function(n){function o(t){var o=n.call(this,t)||this;return o.wrapper=r(),o.instance=null,o.instance=new e(t||{}),o}return u(o,n),o.prototype.getInstance=function(){return this.instance},o.prototype.componentDidMount=function(){this.instance.render(this.wrapper.current)},o.prototype.componentDidUpdate=function(){console.log("XXXX"),this.instance.updateConfig(this.props).forceRender()},o.prototype.render=function(){return t.createElement("div",{ref:this.wrapper})},o}(n),f=function(t){function r(){var r=null!==t&&t.apply(this,arguments)||this;return r.ref=p(),r}return u(r,t),r.prototype.componentDidMount=function(){c.render(this.props.element,this.ref.current)},r.prototype.render=function(){return o(this.props.parent,{ref:this.ref})},r.defaultProps={parent:"div"},r}(i);function l(t,r){return o(f,{element:t,parent:r})}export{a as Grid,f as ReactWrapper,l as _}; | ||
//# sourceMappingURL=gridjs.production.es.min.js.map |
@@ -1,16 +0,2 @@ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("gridjs"),require("react-dom")):"function"==typeof define&&define.amd?define(["exports","react","gridjs","react-dom"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).gridjs={},e.React,e.gridjs,e.ReactDOM)}(this,(function(e,t,n,r){"use strict";function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var i=o(r),p=function(e,t){return(p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)}; | ||
/*! ***************************************************************************** | ||
Copyright (c) Microsoft Corporation. | ||
Permission to use, copy, modify, and/or distribute this software for any | ||
purpose with or without fee is hereby granted. | ||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH | ||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY | ||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, | ||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM | ||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR | ||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | ||
PERFORMANCE OF THIS SOFTWARE. | ||
***************************************************************************** */function c(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}p(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var u=function(e){function r(r){var o=e.call(this,r)||this;return o.wrapper=t.createRef(),o.instance=null,o.instance=new n.Grid(r||{}),o}return c(r,e),r.prototype.getInstance=function(){return this.instance},r.prototype.componentDidMount=function(){this.instance.render(this.wrapper.current)},r.prototype.componentDidUpdate=function(){this.instance.updateConfig(this.props).forceRender()},r.prototype.render=function(){return t.createElement("div",{ref:this.wrapper})},r}(t.Component),f=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.ref=n.createRef(),t}return c(t,e),t.prototype.componentDidMount=function(){i.default.render(this.props.element,this.ref.current)},t.prototype.render=function(){return n.h(this.props.parent,{ref:this.ref})},t.defaultProps={parent:"div"},t}(n.Component);e.Grid=u,e.ReactWrapper=f,e._=function(e,t){return n.h(f,{element:e,parent:t})},Object.defineProperty(e,"__esModule",{value:!0})})); | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("gridjs"),require("react-dom")):"function"==typeof define&&define.amd?define(["exports","react","gridjs","react-dom"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).gridjs={},e.React,e.gridjs,e.ReactDOM)}(this,(function(e,t,r,n){"use strict";function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function i(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var c=i(t),u=o(n),p=function(e,t){return(p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function f(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}p(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var a=function(e){function n(n){var o=e.call(this,n)||this;return o.wrapper=t.createRef(),o.instance=null,o.instance=new r.Grid(n||{}),o}return f(n,e),n.prototype.getInstance=function(){return this.instance},n.prototype.componentDidMount=function(){this.instance.render(this.wrapper.current)},n.prototype.componentDidUpdate=function(){console.log("XXXX"),this.instance.updateConfig(this.props).forceRender()},n.prototype.render=function(){return c.createElement("div",{ref:this.wrapper})},n}(t.Component),s=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.ref=r.createRef(),t}return f(t,e),t.prototype.componentDidMount=function(){u.default.render(this.props.element,this.ref.current)},t.prototype.render=function(){return r.h(this.props.parent,{ref:this.ref})},t.defaultProps={parent:"div"},t}(r.Component);e.Grid=a,e.ReactWrapper=s,e._=function(e,t){return r.h(s,{element:e,parent:t})},Object.defineProperty(e,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=gridjs.production.min.js.map |
{ | ||
"name": "gridjs-react", | ||
"version": "3.4.0", | ||
"version": "4.0.0", | ||
"description": "React component for Grid.js", | ||
@@ -24,4 +24,4 @@ "main": "dist/gridjs.production.min.js", | ||
"peerDependencies": { | ||
"react": "^16.13.1", | ||
"gridjs": "^3.2.2" | ||
"gridjs": "^4.0.0", | ||
"react": ">=16.13.1 <18.x" | ||
}, | ||
@@ -45,6 +45,6 @@ "scripts": { | ||
"enzyme-adapter-react-16": "^1.15.5", | ||
"eslint": "~7.22.0", | ||
"eslint": "~7.24.0", | ||
"eslint-config-prettier": "^7.1.0", | ||
"eslint-plugin-jest": "^24.1.3", | ||
"gridjs": "^3.2.2", | ||
"gridjs": "^4.0.0", | ||
"jest": "~25.5.4", | ||
@@ -67,4 +67,3 @@ "jsdom": "^16.4.0", | ||
"typescript": "^3.9.7" | ||
}, | ||
"dependencies": {} | ||
} | ||
} |
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
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
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
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
80596
248