Socket
Socket
Sign inDemoInstall

@talend/json-schema-form-core

Package Overview
Dependencies
2
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.1 to 1.2.2

6

CHANGELOG.md
# @talend/json-schema-form-core
## 1.2.2
### Patch Changes
- 5d631f2: TMC-27327 - Fix input number validation to display correct error message
## 1.2.1

@@ -4,0 +10,0 @@

2

package.json
{
"name": "@talend/json-schema-form-core",
"version": "1.2.1",
"version": "1.2.2",
"description": "JSON-Schema and JSON-UI-Schema utilities for form generation.",

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

@@ -8,3 +8,3 @@ /* Common code for validating a value against its form and schema definition */

// If the user types a non-integer value, the value is emptied by browser but still displayed in UI
if (event.target?.validity && !event.target.validity.valid) {
if (event.target?.validity && event.target.validity.badInput) {
return { valid: false, message: 'CUSTOM_ERROR_INVALID_INPUT' };

@@ -11,0 +11,0 @@ }

@@ -27,3 +27,3 @@ import { validate } from './validate';

const testForm = { type: 'number', key: ['hero'], schema: { type: 'number' } };
const event = { target: { validity: { valid: false } } };
const event = { target: { validity: { badInput: true } } };
let result = validate(testForm, value, event);

@@ -30,0 +30,0 @@ expect(result.error.message).toBe('CUSTOM_ERROR_INVALID_INPUT');

Sorry, the diff of this file is too big to display

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc