New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-polymorph

Package Overview
Dependencies
Maintainers
1
Versions
143
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-polymorph - npm Package Compare versions

Comparing version 0.2.5 to 0.2.6

7

CHANGELOG.md
Changelog
=========
## 0.2.6
### Fixes
- Fixed a bug in `NumericInput` when illegal chars have been entered but the
old valid value was still `null`.
## 0.2.5

@@ -5,0 +12,0 @@

9

lib/components/NumericInput.js

@@ -123,2 +123,3 @@ 'use strict';

var handledValue = void 0;
var lastValidValue = this.state.oldValue;
if (!isValueRegular && value !== '') {

@@ -128,3 +129,3 @@ // input contains invalid value

// - reject it and show last valid value
handledValue = this.state.oldValue;
handledValue = lastValidValue ? lastValidValue : '0.000000';
position = position - 1;

@@ -138,3 +139,3 @@ } else if (!this._isNumeric(value)) {

// input value contains more than one dot
var splitedOldValue = this.state.oldValue.split('.');
var splitedOldValue = lastValidValue.split('.');
if (splitedOldValue[0].length <= splitedValue[0].length) {

@@ -148,3 +149,3 @@ // dot is in decimal part

if (beforeDot.length > this.props.maxBeforeDot) {
handledValue = this.state.oldValue;
handledValue = lastValidValue;
}

@@ -162,3 +163,3 @@ } else {

// - reject it and show last valid value
handledValue = this.state.oldValue;
handledValue = lastValidValue;
}

@@ -165,0 +166,0 @@ }

{
"name": "react-polymorph",
"description": "React components with highly customizable logic, markup and styles.",
"version": "0.2.5",
"version": "0.2.6",
"author": {

@@ -6,0 +6,0 @@ "name": "Dominik Guzei",

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