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

frc-ui

Package Overview
Dependencies
Maintainers
1
Versions
76
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

frc-ui - npm Package Compare versions

Comparing version 0.0.0-beta.9 to 0.0.0-beta.10

15

es/tree/Tree.js

@@ -81,3 +81,3 @@ var __rest = (this && this.__rest) || function (s, e) {

return (type, flag) => {
const { rowHeight } = this.props;
const { rowHeight, onChange, onExpand } = this.props;
const { height } = this.state;

@@ -106,3 +106,7 @@ const { value } = option;

this.showColorKeys = this.getSelectedPath(keys);
this.setState({ selectedKeys: keys });
this.setState({ selectedKeys: keys }, () => {
if (typeof onChange === 'function') {
onChange(this.state.selectedKeys || []);
}
});
}

@@ -115,3 +119,8 @@ else if (type === 'expand') {

options = this.getOptions(keys);
this.setState({ expandedKeys: keys, tops: [], bottoms: [], options }, this.handleResize);
this.setState({ expandedKeys: keys, tops: [], bottoms: [], options }, () => {
this.handleResize();
if (typeof onExpand === 'function') {
onExpand(this.state.expandedKeys || []);
}
});
}

@@ -118,0 +127,0 @@ }

2

es/tree/types.d.ts

@@ -21,2 +21,4 @@ export interface OptionProps {

rowHeight: number;
onChange?: (selectedKeys: Array<string | number>) => void;
onExpand?: (expandedKeys: Array<string | number>) => void;
fixedTopBottom: boolean;

@@ -23,0 +25,0 @@ }

@@ -165,3 +165,6 @@ "use strict";

return function (type, flag) {
var rowHeight = _this.props.rowHeight;
var _this$props2 = _this.props,
rowHeight = _this$props2.rowHeight,
onChange = _this$props2.onChange,
onExpand = _this$props2.onExpand;
var height = _this.state.height;

@@ -199,2 +202,6 @@ var value = option.value;

selectedKeys: keys
}, function () {
if (typeof onChange === 'function') {
onChange(_this.state.selectedKeys || []);
}
});

@@ -215,3 +222,9 @@ } else if (type === 'expand') {

options: options
}, _this.handleResize);
}, function () {
_this.handleResize();
if (typeof onExpand === 'function') {
onExpand(_this.state.expandedKeys || []);
}
});
}

@@ -292,5 +305,5 @@ }

_this.renderItem = function (type) {
var _this$props2 = _this.props,
prefix = _this$props2.prefix,
rowHeight = _this$props2.rowHeight;
var _this$props3 = _this.props,
prefix = _this$props3.prefix,
rowHeight = _this$props3.rowHeight;

@@ -376,5 +389,5 @@ var options = _this.state[type.toString()];

value: function render() {
var _this$props3 = this.props,
className = _this$props3.className,
prefix = _this$props3.prefix;
var _this$props4 = this.props,
className = _this$props4.className,
prefix = _this$props4.prefix;
var cls = (0, _classnames["default"])("".concat(prefix), className);

@@ -381,0 +394,0 @@ var fixedTop = "".concat(prefix, "-fixed-top");

{
"name": "frc-ui",
"version": "0.0.0-beta.9",
"version": "0.0.0-beta.10",
"description": "React Web UI",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

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