@syncfusion/ej2-inputs
Advanced tools
Comparing version 26.1.39 to 26.1.40
/*! | ||
* filename: index.d.ts | ||
* version : 26.1.39 | ||
* version : 26.1.40 | ||
* Copyright Syncfusion Inc. 2001 - 2023. All rights reserved. | ||
@@ -5,0 +5,0 @@ * Use of this code is subject to the terms of our license. |
{ | ||
"_from": "@syncfusion/ej2-inputs@*", | ||
"_id": "@syncfusion/ej2-inputs@26.1.38", | ||
"_id": "@syncfusion/ej2-inputs@26.1.39", | ||
"_inBundle": false, | ||
"_integrity": "sha512-CzxeAQnytAW+YbMVo82W8Ew9Z2f7Cx7k5p4DSvdUUnX42ELTiDHJAgmWBvbiKd/N8TLZjIyARWVlkuAKDPb6Iw==", | ||
"_integrity": "sha512-HEuIj2L6ytaYR8EhUN5aKQXqJeW46JTD7rsWO/uYXVrhcR6gg9soswQCPPyGOO8i+lkU+21h/hktIeWPGdNOyg==", | ||
"_location": "/@syncfusion/ej2-inputs", | ||
@@ -42,4 +42,4 @@ "_phantomChildren": {}, | ||
], | ||
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-inputs/-/ej2-inputs-26.1.38.tgz", | ||
"_shasum": "09672591ff610b232b0ea3140db081747ff8ccf2", | ||
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-inputs/-/ej2-inputs-26.1.39.tgz", | ||
"_shasum": "851565d18a1056a01a9c761f8bbfb4ff9fb7e13f", | ||
"_spec": "@syncfusion/ej2-inputs@*", | ||
@@ -53,3 +53,3 @@ "_where": "/jenkins/workspace/elease-automation_release_26.1.1/packages/included", | ||
"@syncfusion/ej2-base": "~26.1.37", | ||
"@syncfusion/ej2-buttons": "~26.1.35", | ||
"@syncfusion/ej2-buttons": "~26.1.40", | ||
"@syncfusion/ej2-popups": "~26.1.38", | ||
@@ -124,5 +124,5 @@ "@syncfusion/ej2-splitbuttons": "~26.1.35" | ||
"typings": "index.d.ts", | ||
"version": "26.1.39", | ||
"version": "26.1.40", | ||
"sideEffects": false, | ||
"homepage": "https://www.syncfusion.com/javascript-ui-controls" | ||
} |
@@ -282,2 +282,6 @@ import { Base, EmitType } from '@syncfusion/ej2-base'; | ||
formElement?: HTMLFormElement; | ||
/** | ||
* Returns the date format mapped for the input. | ||
*/ | ||
format?: string; | ||
} | ||
@@ -284,0 +288,0 @@ export interface FormEventArgs { |
@@ -652,3 +652,4 @@ var __extends = (this && this.__extends) || (function () { | ||
var currentRule = this.rules["" + name]["" + rule]; | ||
var args = { value: this.inputElement.value, param: param, element: this.inputElement, formElement: this.element }; | ||
var dateFormat = ((rule === 'min' || rule === 'max') && this.rules["" + name].date && typeof (this.rules["" + name].date) === 'string') ? this.rules["" + name].date : null; | ||
var args = { value: this.inputElement.value, param: param, element: this.inputElement, formElement: this.element, format: dateFormat }; | ||
this.trigger('validationBegin', args); | ||
@@ -850,3 +851,12 @@ if (!args.param && rule === 'required') { | ||
// Maximum rule validation for date | ||
return new Date(option.value).getTime() <= new Date(JSON.parse(JSON.stringify(option.param))).getTime(); | ||
if (option.format && option.format !== '') { | ||
var globalize = new Internationalization; | ||
var dateOptions = { format: option.format.toString(), type: 'dateTime', skeleton: 'yMd' }; | ||
var dateValue = globalize.parseDate(option.value, dateOptions); | ||
var maxValue = globalize.parseDate(JSON.parse(JSON.stringify(option.param)), dateOptions); | ||
return new Date(dateValue).getTime() <= new Date(maxValue).getTime(); | ||
} | ||
else { | ||
return new Date(option.value).getTime() <= new Date(JSON.parse(JSON.stringify(option.param))).getTime(); | ||
} | ||
}, | ||
@@ -864,3 +874,12 @@ min: function (option) { | ||
// Minimum rule validation for date | ||
return new Date(option.value).getTime() >= new Date(JSON.parse(JSON.stringify(option.param))).getTime(); | ||
if (option.format && option.format !== '') { | ||
var globalize = new Internationalization; | ||
var dateOptions = { format: option.format.toString(), type: 'dateTime', skeleton: 'yMd' }; | ||
var dateValue = globalize.parseDate(option.value, dateOptions); | ||
var minValue = globalize.parseDate(JSON.parse(JSON.stringify(option.param)), dateOptions); | ||
return new Date(dateValue).getTime() >= new Date(minValue).getTime(); | ||
} | ||
else { | ||
return new Date(option.value).getTime() >= new Date(JSON.parse(JSON.stringify(option.param))).getTime(); | ||
} | ||
} | ||
@@ -867,0 +886,0 @@ }, |
@@ -619,3 +619,3 @@ /* eslint-disable valid-jsdoc, jsdoc/require-jsdoc, jsdoc/require-returns, jsdoc/require-param */ | ||
var floatTextContent = parentElement.getElementsByClassName('e-float-text-content')[0]; | ||
if (floatTextContent) { | ||
if (floatTextContent && floatTextContent.children[0]) { | ||
floatTextContent.children[0].textContent = placeholder; | ||
@@ -622,0 +622,0 @@ } |
Sorry, the diff of this file is too big to display
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 too big to display
Sorry, the diff of this file is not supported yet
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 too big to display
Sorry, the diff of this file is not supported yet
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
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
30328596
407386