From 9da8780c0e76c11df9a94a23a3086a96682e24d4 Mon Sep 17 00:00:00 2001 From: Alexandre Capt Date: Mon, 8 Jun 2020 10:39:26 +0200 Subject: [PATCH 1/2] fix(import): spans lose spaces --- package-lock.json | 56 +++++++++++------------------------------------ package.json | 2 +- 2 files changed, 14 insertions(+), 44 deletions(-) diff --git a/package-lock.json b/package-lock.json index 6dd9d01..20fff84 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,13 +30,13 @@ "@adobe/helix-fetch": "1.6.1", "@adobe/helix-qr-code": "1.1.0", "image-size": "0.8.3", - "mime": "2.4.5" + "mime": "2.4.6" }, "dependencies": { "mime": { - "version": "2.4.5", - "resolved": "https://registry.npmjs.org/mime/-/mime-2.4.5.tgz", - "integrity": "sha512-3hQhEUF027BuxZjQA3s7rIv/7VCQPa27hN9u9g87sEkWaKwQPuXOkVKtOeiyUrnWqTDiOs8Ed2rwg733mB0R5w==" + "version": "2.4.6", + "resolved": "https://registry.npmjs.org/mime/-/mime-2.4.6.tgz", + "integrity": "sha512-RZKhC3EmpBchfTGBVb8fb+RL2cWyw/32lshnsETttkBAyAUXSGHxbEJWWRXc751DrIxG1q04b8QwMbAwkRPpUA==" } } }, @@ -2519,11 +2519,6 @@ "is-string": "^1.0.5" } }, - "array-iterate": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/array-iterate/-/array-iterate-1.1.4.tgz", - "integrity": "sha512-sNRaPGh9nnmdC8Zf+pT3UqP8rnWj5Hf9wiFGsX3wUQ2yVSIhO2ShFwCoceIPpB41QF6i2OEmrHmCo36xronCVA==" - }, "array-union": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", @@ -6990,15 +6985,6 @@ "resolved": "https://registry.npmjs.org/hast-util-has-property/-/hast-util-has-property-1.0.4.tgz", "integrity": "sha512-ghHup2voGfgFoHMGnaLHOjbYFACKrRh9KFttdCzMCbFoBMJXiNi2+XTrPP8+q6cDJM/RSqlCfVWrjp1H201rZg==" }, - "hast-util-is-body-ok-link": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/hast-util-is-body-ok-link/-/hast-util-is-body-ok-link-1.0.3.tgz", - "integrity": "sha512-NB8jW4iqT+iVld2oCjSk0T2S2FyR86rDZ7nKHx3WNf/WX16fjjdfoog6T+YeJFsPzszVKsNlVJL+k5c4asAHog==", - "requires": { - "hast-util-has-property": "^1.0.0", - "hast-util-is-element": "^1.0.0" - } - }, "hast-util-is-element": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/hast-util-is-element/-/hast-util-is-element-1.0.4.tgz", @@ -7041,9 +7027,9 @@ } }, "hast-util-to-mdast": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/hast-util-to-mdast/-/hast-util-to-mdast-7.1.0.tgz", - "integrity": "sha512-uyHJOq8sXbMQh2hBW8u6IEyrthq53SGiEz8Qcdskpz6osY4VU0QJ9s4l7xCCZaqeUbmcy8wutYPGUMCdWPDASA==", + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/hast-util-to-mdast/-/hast-util-to-mdast-7.1.1.tgz", + "integrity": "sha512-MXD6n7sxvmg1ntpugcGAE0AD+SrZWUqlJgLjYZr93697s3TWgsrs/PGXcgk/E7mvcj4q85tZy5grsMDKzmqBxA==", "requires": { "extend": "^3.0.0", "hast-util-has-property": "^1.0.0", @@ -7051,7 +7037,7 @@ "hast-util-to-text": "^2.0.0", "mdast-util-phrasing": "^2.0.0", "mdast-util-to-string": "^1.0.0", - "rehype-minify-whitespace": "^3.0.0", + "rehype-minify-whitespace": "^4.0.3", "repeat-string": "^1.6.1", "trim-trailing-lines": "^1.1.0", "unist-util-visit": "^2.0.0", @@ -7133,11 +7119,6 @@ "resolved": "https://registry.npmjs.org/html-void-elements/-/html-void-elements-1.0.5.tgz", "integrity": "sha512-uE/TxKuyNIcx44cIWnjr/rfIATDH7ZaOMmstu0CwhFG1Dunhlp4OC6/NMbhiwoq5BpW0ubi303qnEk/PZj614w==" }, - "html-whitespace-sensitive-tag-names": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/html-whitespace-sensitive-tag-names/-/html-whitespace-sensitive-tag-names-1.0.2.tgz", - "integrity": "sha512-9jCcAq9ZsjUkZjNFDvxalDPhktOijpfzLyzBcqMLOFSbtcDNrPlKDvZeH7KdEbP7C6OjPpIdDMMPm0oq2Dpk0A==" - }, "htmlparser2": { "version": "3.10.1", "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", @@ -15594,18 +15575,15 @@ } }, "rehype-minify-whitespace": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/rehype-minify-whitespace/-/rehype-minify-whitespace-3.0.0.tgz", - "integrity": "sha512-Z5NIG9FxTeK2Ta+eTWCnTVPXu1qC58eCXZA3m/Z7PPinKw82KSR+12c2l1sLLSg27QZOmZrrd9piS8dsAVfliQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/rehype-minify-whitespace/-/rehype-minify-whitespace-4.0.3.tgz", + "integrity": "sha512-Iih7mVAJpSv3nNbpxgIKpxkJMfBljZDNW16zlMcADTyQR/WBnpvOGKSWFfw3DIxtYaYNStVNICfoH0Pba5hM1g==", "requires": { "collapse-white-space": "^1.0.0", "hast-util-embedded": "^1.0.0", - "hast-util-has-property": "^1.0.0", - "hast-util-is-body-ok-link": "^1.0.0", "hast-util-is-element": "^1.0.0", - "html-whitespace-sensitive-tag-names": "^1.0.0", - "unist-util-is": "^4.0.0", - "unist-util-modify-children": "^1.0.0" + "hast-util-whitespace": "^1.0.4", + "unist-util-is": "^4.0.0" } }, "rehype-parse": { @@ -17551,14 +17529,6 @@ "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.0.2.tgz", "integrity": "sha512-Ofx8uf6haexJwI1gxWMGg6I/dLnF2yE+KibhD3/diOqY2TinLcqHXCV6OI5gFVn3xQqDH+u0M625pfKwIwgBKQ==" }, - "unist-util-modify-children": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/unist-util-modify-children/-/unist-util-modify-children-1.1.6.tgz", - "integrity": "sha512-TOA6W9QLil+BrHqIZNR4o6IA5QwGOveMbnQxnWYq+7EFORx9vz/CHrtzF36zWrW61E2UKw7sM1KPtIgeceVwXw==", - "requires": { - "array-iterate": "^1.0.0" - } - }, "unist-util-stringify-position": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-2.0.3.tgz", diff --git a/package.json b/package.json index f572651..482dae1 100644 --- a/package.json +++ b/package.json @@ -51,7 +51,7 @@ "fast-csv": "^4.1.3", "fs-extra": "^9.0.0", "hast-util-to-html": "^7.1.1", - "hast-util-to-mdast": "^7.1.0", + "hast-util-to-mdast": "7.1.1", "moment": "^2.24.0", "path": "^0.12.7", "rehype-parse": "6.0.2", From ad82759a7ba8953ae0c3bbecd4de1fa5bf030f14 Mon Sep 17 00:00:00 2001 From: Alexandre Capt Date: Mon, 8 Jun 2020 10:53:40 +0200 Subject: [PATCH 2/2] fix(import): linting... --- src/index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/index.js b/src/index.js index 5d037d2..9c3ff1b 100644 --- a/src/index.js +++ b/src/index.js @@ -355,6 +355,7 @@ async function doImport(importer, url, checkIfRelatedExists, doCreateAssets = fa }); const topics = await handleTopics(importer, $, checkIfRelatedExists, logger); + // eslint-disable-next-line max-len const products = await handleProducts(importer, $, checkIfRelatedExists, doCreateAssets, logger); const $topicsWrap = $('

');