Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-infinity-menu

Package Overview
Dependencies
Maintainers
28
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-infinity-menu - npm Package Compare versions

Comparing version 3.2.0 to 4.0.0

40

dist/infinity-menu.js

@@ -11,2 +11,6 @@ "use strict";

var _propTypes = require("prop-types");
var _propTypes2 = _interopRequireDefault(_propTypes);
var _react = require("react");

@@ -24,5 +28,5 @@

var _get2 = require("lodash/get");
var _lodash = require("lodash.get");
var _get3 = _interopRequireDefault(_get2);
var _lodash2 = _interopRequireDefault(_lodash);

@@ -91,3 +95,3 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var parentPath = Object.assign([], keyPathArray).splice(0, keyPathArray.length - 2);
var parentNode = (0, _get3.default)(this.props.tree, parentPath);
var parentNode = (0, _lodash2.default)(this.props.tree, parentPath);
// set new max leaves - if none exist use component default property

@@ -225,3 +229,3 @@ parentNode.maxLeaves = !parentNode.maxLeaves ? this.props.maxLeaves : parentNode.maxLeaves + this.props.maxLeaves;

var parentPath = Object.assign([], keyPathArray).splice(0, keyPathArray.length - 2);
var parentNode = (0, _get3.default)(this.props.tree, parentPath);
var parentNode = (0, _lodash2.default)(this.props.tree, parentPath);
var filteredChildren = parentNode.children.some(function (child) {

@@ -469,16 +473,16 @@ return child.isSearchDisplay === true;

InfinityMenu.propTypes = {
tree: _react2.default.PropTypes.array,
headerContent: _react2.default.PropTypes.any,
disableDefaultHeaderContent: _react2.default.PropTypes.bool,
headerProps: _react2.default.PropTypes.object,
customComponentMappings: _react2.default.PropTypes.object,
emptyTreeComponent: _react2.default.PropTypes.any,
emptyTreeComponentProps: _react2.default.PropTypes.object,
filter: _react2.default.PropTypes.func,
onNodeMouseClick: _react2.default.PropTypes.func,
onLeafMouseClick: _react2.default.PropTypes.func,
onLeafMouseDown: _react2.default.PropTypes.func,
onLeafMouseUp: _react2.default.PropTypes.func,
shouldComponentUpdate: _react2.default.PropTypes.func,
maxLeaves: _react2.default.PropTypes.number
tree: _propTypes2.default.array,
headerContent: _propTypes2.default.any,
disableDefaultHeaderContent: _propTypes2.default.bool,
headerProps: _propTypes2.default.object,
customComponentMappings: _propTypes2.default.object,
emptyTreeComponent: _propTypes2.default.any,
emptyTreeComponentProps: _propTypes2.default.object,
filter: _propTypes2.default.func,
onNodeMouseClick: _propTypes2.default.func,
onLeafMouseClick: _propTypes2.default.func,
onLeafMouseDown: _propTypes2.default.func,
onLeafMouseUp: _propTypes2.default.func,
shouldComponentUpdate: _propTypes2.default.func,
maxLeaves: _propTypes2.default.number
};

@@ -485,0 +489,0 @@

{
"name": "react-infinity-menu",
"version": "3.2.0",
"version": "4.0.0",
"description": "An unlimited deep side menu",

@@ -23,3 +23,3 @@ "main": "./dist/infinity-menu.js",

"dependencies": {
"lodash": "^4.16.6",
"lodash.get": "^4.4.2",
"nested-objects": "0.0.2"

@@ -41,5 +41,6 @@ },

"mocha": "^2.3.3",
"react": "^0.14.3",
"react-addons-test-utils": "^0.14.3",
"react-dom": "^0.14.3",
"prop-types": "^15.6.0",
"react": "^16.0.0",
"react-dom": "^16.0.0",
"react-test-renderer": "^16.1.1",
"should": "^7.1.0",

@@ -52,3 +53,3 @@ "should-sinon": "0.0.3",

"peerDependencies": {
"react": ">=0.13.2"
"react": ">=0.16.0"
},

@@ -55,0 +56,0 @@ "directories": {

@@ -0,5 +1,6 @@

import PropTypes from "prop-types";
import React from "react";
import SearchInput from "./search-input";
import NestedObjects from "nested-objects";
import _get from "lodash/get";
import _get from "lodash.get";

@@ -380,16 +381,16 @@ /*

InfinityMenu.propTypes = {
tree: React.PropTypes.array,
headerContent: React.PropTypes.any,
disableDefaultHeaderContent: React.PropTypes.bool,
headerProps: React.PropTypes.object,
customComponentMappings: React.PropTypes.object,
emptyTreeComponent: React.PropTypes.any,
emptyTreeComponentProps: React.PropTypes.object,
filter: React.PropTypes.func,
onNodeMouseClick: React.PropTypes.func,
onLeafMouseClick: React.PropTypes.func,
onLeafMouseDown: React.PropTypes.func,
onLeafMouseUp: React.PropTypes.func,
shouldComponentUpdate: React.PropTypes.func,
maxLeaves: React.PropTypes.number
tree: PropTypes.array,
headerContent: PropTypes.any,
disableDefaultHeaderContent: PropTypes.bool,
headerProps: PropTypes.object,
customComponentMappings: PropTypes.object,
emptyTreeComponent: PropTypes.any,
emptyTreeComponentProps: PropTypes.object,
filter: PropTypes.func,
onNodeMouseClick: PropTypes.func,
onLeafMouseClick: PropTypes.func,
onLeafMouseDown: PropTypes.func,
onLeafMouseUp: PropTypes.func,
shouldComponentUpdate: PropTypes.func,
maxLeaves: PropTypes.number
};

@@ -396,0 +397,0 @@

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
let shallowRenderer = TestUtils.createRenderer();
import { createRenderer } from "react-test-renderer/shallow";
let shallowRenderer = createRenderer();
import InfinityMenu from "../src/infinity-menu";

@@ -6,0 +6,0 @@ import sinon from "sinon";

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
let shallowRenderer = TestUtils.createRenderer();
import TestUtils from "react-dom/test-utils";
import { createRenderer } from "react-test-renderer/shallow";
let shallowRenderer = createRenderer();
import InfinityMenu from "../src/infinity-menu";

@@ -6,0 +7,0 @@ import sinon from "sinon";

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
import InfinityMenu from "../src/infinity-menu";

@@ -8,3 +7,5 @@ import sinon from "sinon";

import "should-sinon";
let shallowRenderer = TestUtils.createRenderer();
import { createRenderer } from "react-test-renderer/shallow";
let shallowRenderer = createRenderer();
import TestUtils from "react-dom/test-utils";

@@ -11,0 +12,0 @@ describe("Empty List Component props", function() {

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
let shallowRenderer = TestUtils.createRenderer();
import { createRenderer } from "react-test-renderer/shallow";
let shallowRenderer = createRenderer();
import InfinityMenu from "../src/infinity-menu";
import should from "should";
import "should-sinon";
import TestUtils from "react-dom/test-utils";

@@ -9,0 +10,0 @@ describe("Header props", function() {

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
let shallowRenderer = TestUtils.createRenderer();
import { createRenderer } from "react-test-renderer/shallow";
let shallowRenderer = createRenderer();
import InfinityMenu from "../src/infinity-menu";
import sinon from "sinon";
import "should-sinon";
import TestUtils from "react-dom/test-utils";

@@ -9,0 +10,0 @@ describe("Leaf/Node Mouse Handlers", function() {

import React from "react";
import ReactDOM from "react-dom";
import TestUtils from "react-addons-test-utils";
import InfinityMenu from "../src/infinity-menu";

@@ -8,2 +7,3 @@ import should from "should";

import "should-sinon";
import TestUtils from "react-dom/test-utils";

@@ -10,0 +10,0 @@ describe("shouldComponentUpdate prop", function() {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc