diff --git a/CHANGELOG.md b/CHANGELOG.md index b455878b..bac97f47 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Change history for stripes-erm-components +## 9.2.1 2024-11-27 + * ERM-3431 License Export as CSV does not result in file download + ## 9.2.0 2024-10-31 * ERM-3373 Update module license and guidance for stripes-erm-components * ERM-3344 Move GitHub actions to shared workflows diff --git a/lib/utils/downloadBlob.js b/lib/utils/downloadBlob.js index a9e0638b..0c5f9ceb 100644 --- a/lib/utils/downloadBlob.js +++ b/lib/utils/downloadBlob.js @@ -28,13 +28,12 @@ const downloadBlob = ( } return blob => { - const url = window.URL.createObjectURL(blob); + const url = URL.createObjectURL(blob); const a = document.createElement('a'); a.href = url; a.download = downloadName; - document.body.appendChild(a); a.click(); - a.remove(); + URL.revokeObjectURL(url); }; }; diff --git a/package.json b/package.json index 59eeef58..deeafb84 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@folio/stripes-erm-components", - "version": "9.2.0", + "version": "9.2.1", "description": "Component library for Stripes ERM applications", "sideEffects": [ "*.css"