Socket
Socket
Sign inDemoInstall

inputmask

Package Overview
Dependencies
0
Maintainers
1
Versions
180
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 5.0.9-beta.54 to 5.0.9-beta.56

0

bundle.js

@@ -0,0 +0,0 @@ import "./lib/polyfills/Object.getPrototypeOf";

1

Changelog.md

@@ -17,2 +17,3 @@ # Change Log

### Fixed
- Inputmask datetime alias mm/yy min value bug #2744
- ALT codes #2779

@@ -19,0 +20,0 @@ - Pressing the Win button #2780

@@ -0,0 +0,0 @@ import "./inputmask.js";

@@ -0,0 +0,0 @@ import {keys} from "./keycode.js";

@@ -0,0 +0,0 @@ export default {

@@ -0,0 +0,0 @@ export default function (owner, key, value) {

@@ -0,0 +0,0 @@ import extend from "./extend";

@@ -0,0 +0,0 @@ export default function extend() {

@@ -0,0 +0,0 @@ import window from "./global/window";

@@ -0,0 +0,0 @@ const escapeRegexRegex = new RegExp("(\\" + ["/", ".", "*", "+", "?", "|", "(", ")", "[", "]", "{", "}", "\\", "$", "^"].join("|\\") + ")", "gim");

@@ -0,0 +0,0 @@ import {

@@ -0,0 +0,0 @@ import Inputmask from "./inputmask";

@@ -0,0 +0,0 @@ /*

21

lib/extensions/inputmask.date.extensions.js

@@ -102,3 +102,3 @@ /*

useDateObject = true;
if (datavalue.length < 4) datavalue = pad(datavalue, 4, true);
if (datavalue.length < formatCode[fcode][4]) datavalue = pad(datavalue, formatCode[fcode][4], true);
}

@@ -155,8 +155,11 @@ if ((datavalue !== "" && !isNaN(datavalue)) || targetProp === "ampm") dateOperation.call(dateObj._date, datavalue);

}], //Month as its full name.
yy: ["[0-9]{2}", Date.prototype.setFullYear, "year", function () {
yy: ["[0-9]{2}", function (val) {
const centuryPart = new Date().getFullYear().toString().slice(0, 2);
Date.prototype.setFullYear.call(this, `${centuryPart}${val}`);
}, "year", function () {
return pad(Date.prototype.getFullYear.call(this), 2);
}], //Year as last two digits; leading zero for years less than 10.
}, 2], //Year as last two digits; leading zero for years less than 10.
yyyy: ["[0-9]{4}", Date.prototype.setFullYear, "year", function () {
return pad(Date.prototype.getFullYear.call(this), 4);
}], h: ["[1-9]|1[0-2]", Date.prototype.setHours, "hours", Date.prototype.getHours], //Hours; no leading zero for single-digit hours (12-hour clock).
}, 4], h: ["[1-9]|1[0-2]", Date.prototype.setHours, "hours", Date.prototype.getHours], //Hours; no leading zero for single-digit hours (12-hour clock).
hh: ["0[1-9]|1[0-2]", Date.prototype.setHours, "hours", function () {

@@ -329,3 +332,3 @@ return pad(Date.prototype.getHours.call(this), 2);

var current = dateParts[fcode[2]], minVal = opts.min[fcode[2]],
maxVal = opts.max ? opts.max[fcode[2]] : minVal, curVal = [];
maxVal = opts.max ? opts.max[fcode[2]] : minVal + 1, curVal = [];

@@ -408,3 +411,3 @@ let forceCurrentValue = false;

}
if (dateObjValue === undefined && opts.placeholder === "") {
if (dateObjValue === undefined && (opts.placeholder === "" || opts.inputFormat.indexOf("mmmm") !== -1)) {
opts.placeholder = placeHolder;

@@ -446,3 +449,3 @@ }

if (dynMatches) {
matchLength = parseInt(dynMatches[0]);
matchLength = parseInt(dynMatches[0]);
} else {

@@ -455,3 +458,3 @@ let targetSymbol = match[0][0],

matchLength = ndx - calcPos;
if(matchLength === 0) matchLength = match[0].length;
if (matchLength === 0) matchLength = match[0].length;
}

@@ -526,3 +529,3 @@

} else {
tokenMatch = getTokenMatch.call(inputmask,pos + 2, opts, maskset);
tokenMatch = getTokenMatch.call(inputmask, pos + 2, opts, maskset);
if (tokenMatch.targetMatch && tokenMatch.targetMatchIndex === pos + 1 && tokenMatch.targetMatch[0].length > 1 && formatCode[tokenMatch.targetMatch[0]] !== undefined) {

@@ -529,0 +532,0 @@ validator = formatcode(tokenMatch.targetMatch)[0];

@@ -0,0 +0,0 @@ const canUseDOM = !!(

@@ -0,0 +0,0 @@ import {keys} from "./keycode.js";

@@ -0,0 +0,0 @@ /*

@@ -0,0 +0,0 @@ import window from "./global/window";

@@ -0,0 +0,0 @@ /*

@@ -0,0 +0,0 @@ export {keyCode, toKey, toKeyCode, keys};

@@ -0,0 +0,0 @@ import $ from "./dependencyLibs/inputmask.dependencyLib";

@@ -0,0 +0,0 @@ import {keys} from "./keycode.js";

@@ -0,0 +0,0 @@ export default function (isGroup, isOptional, isQuantifier, isAlternator) {

@@ -0,0 +0,0 @@ // https://tc39.github.io/ecma262/#sec-array.prototype.includes

@@ -0,0 +0,0 @@ const reduce = Function.bind.call(Function.call, Array.prototype.reduce);

@@ -0,0 +0,0 @@ if (typeof Object.getPrototypeOf !== "function") {

@@ -0,0 +0,0 @@ if (!String.prototype.includes) {

@@ -0,0 +0,0 @@ import window from "./global/window";

@@ -0,0 +0,0 @@ import {getLastValidPosition, seekNext} from "./positioning";

@@ -0,0 +0,0 @@ import {

@@ -0,0 +0,0 @@ Copyright (c) 2010 - 2018 Robin Herbots

@@ -0,0 +0,0 @@ (() => {

{
"name": "inputmask",
"version": "5.0.9-beta.54",
"version": "5.0.9-beta.56",
"description": "Inputmask is a javascript library which creates an input mask. Inputmask can run against vanilla javascript, jQuery and jqlite.",

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

@@ -0,0 +0,0 @@ # Inputmask

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