diff --git a/package-lock.json b/package-lock.json index 790b0551..4fc45fad 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,7 +16,7 @@ "node-fetch": "^2.6.9", "opencollective-postinstall": "^2.0.3", "regenerator-runtime": "^0.13.3", - "tesseract.js-core": "^6.0.0-3", + "tesseract.js-core": "^6.0.0-4", "wasm-feature-detect": "^1.2.11", "zlibjs": "^0.3.1" }, @@ -8752,9 +8752,9 @@ } }, "node_modules/tesseract.js-core": { - "version": "6.0.0-3", - "resolved": "https://registry.npmjs.org/tesseract.js-core/-/tesseract.js-core-6.0.0-3.tgz", - "integrity": "sha512-sHmDE1XnAI8sWpiKisodss5KKN57+9/ABZdp1eEsSBNMmHPGI2HahiY3EZx6LETxahAr3WF3erVF0WPebkk17g==", + "version": "6.0.0-4", + "resolved": "https://registry.npmjs.org/tesseract.js-core/-/tesseract.js-core-6.0.0-4.tgz", + "integrity": "sha512-ev3wSmKggyVEnDt3M/SPhu0ljH67+LWApIuVsgPU6sKHz1eISKiEBiXXn01yLKlLOt3vLFeMufHGnCcV3xLE3w==", "license": "Apache-2.0" }, "node_modules/test-exclude": { @@ -16185,9 +16185,9 @@ } }, "tesseract.js-core": { - "version": "6.0.0-3", - "resolved": "https://registry.npmjs.org/tesseract.js-core/-/tesseract.js-core-6.0.0-3.tgz", - "integrity": "sha512-sHmDE1XnAI8sWpiKisodss5KKN57+9/ABZdp1eEsSBNMmHPGI2HahiY3EZx6LETxahAr3WF3erVF0WPebkk17g==" + "version": "6.0.0-4", + "resolved": "https://registry.npmjs.org/tesseract.js-core/-/tesseract.js-core-6.0.0-4.tgz", + "integrity": "sha512-ev3wSmKggyVEnDt3M/SPhu0ljH67+LWApIuVsgPU6sKHz1eISKiEBiXXn01yLKlLOt3vLFeMufHGnCcV3xLE3w==" }, "test-exclude": { "version": "6.0.0", diff --git a/package.json b/package.json index 5f694c54..05097df5 100644 --- a/package.json +++ b/package.json @@ -68,7 +68,7 @@ "node-fetch": "^2.6.9", "opencollective-postinstall": "^2.0.3", "regenerator-runtime": "^0.13.3", - "tesseract.js-core": "^6.0.0-3", + "tesseract.js-core": "^6.0.0-4", "wasm-feature-detect": "^1.2.11", "zlibjs": "^0.3.1" }, diff --git a/tests/recognize.test.js b/tests/recognize.test.js index 44a66adc..a9c5833a 100644 --- a/tests/recognize.test.js +++ b/tests/recognize.test.js @@ -317,10 +317,10 @@ describe('recognize()', () => { it('recongize large image', async () => { await worker.reinitialize('eng'); const { data: { layoutBlocks } } = await worker.recognize(`${IMAGE_PATH}/testocr.png`, {}, { text: false, layoutBlocks: true }); - expect(layoutBlocks[0].bbox[0]).to.be(36); - expect(layoutBlocks[0].bbox[1]).to.be(92); - expect(layoutBlocks[0].bbox[2]).to.be(618); - expect(layoutBlocks[0].bbox[3]).to.be(361); + expect(layoutBlocks[0].bbox.x0).to.be(36); + expect(layoutBlocks[0].bbox.y0).to.be(92); + expect(layoutBlocks[0].bbox.x1).to.be(618); + expect(layoutBlocks[0].bbox.y1).to.be(361); }).timeout(TIMEOUT); }); });