Skip to content

Commit

Permalink
Merge pull request #144 from hmrc/PLATUI-1154_add_isNaN_polyfill_for_IE
Browse files Browse the repository at this point in the history
PLATUI-1154: Add polyfill for Number.isNaN to fix timeout dialog issu…
  • Loading branch information
matthewmascord authored May 5, 2021
2 parents 382d0b6 + 94e26e5 commit 7b7eef7
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/).

## [Unreleased]

## [1.33.0] - 2021-05-04

## Fixed

- Fix timeout dialog on IE by adding polyfill for Number.isNaN

## [1.32.0] - 2021-04-29

## Fixed
Expand Down
2 changes: 1 addition & 1 deletion check-compatibility.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (!knownPrototypeKitNames.includes(consumerPackageJson.name)) {
}

const compatibility = {
1.30: {
1.33: {
'prototype-kit': ['9.12', '9.11', '9.10', '9.9', '9.8', '9.7', '9.6', '9.5', '9.4', '9.3', '9.2', '9.1', '9.0', '9.9', '9.10', '9.11'],
},
0.6: {
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hmrc-frontend",
"version": "1.32.0",
"version": "1.33.0",
"description": "Design patterns for HMRC frontends",
"scripts": {
"start": "gulp dev",
Expand Down
2 changes: 2 additions & 0 deletions src/components/timeout-dialog/validate-input.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import '../../vendor/polyfills/Number/prototype/isNaN';

function ValidateInput() {
}

Expand Down
4 changes: 4 additions & 0 deletions src/vendor/polyfills/Number/prototype/isNaN.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
// Polyfill from https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isNaN
Number.isNaN = Number.isNaN || function isNaN(input) {
return typeof input === 'number' && input !== input;
}

0 comments on commit 7b7eef7

Please sign in to comment.