Skip to content

Releases: mebjas/html5-qrcode

V2.0.4

28 May 09:08
4bf6b0d
Compare
Choose a tag to compare

Version 2.0.4

  • Source code migrated from javascript to typescript.
  • Issue#198 fixed - Fixing autoplay in Cordova Android apps

Version 2.0.3

03 May 06:09
b7f8c91
Compare
Choose a tag to compare

Version 2.0.3

  • Show specific error message if web-cam access fails due to insecure context like web page being neither https or localhost.

Version 2.0.2

26 Apr 09:38
70802a5
Compare
Choose a tag to compare

Version 2.0.1

15 Apr 14:15
2c9c5ef
Compare
Choose a tag to compare

Bug fix release

  • Bug fix: Zxing-js library was logging to console even if verbose is false - #175

Version 2.0.0

13 Apr 11:24
1177ca4
Compare
Choose a tag to compare

Version 2.0.0

  • Major Change Migrated from Lazarsoft QR Code scanning to ZXing-js.
    • More robust support for QR Code scanning
    • Support for barcode scanning in following formats
       ZXing.BarcodeFormat.QR_CODE,
       ZXing.BarcodeFormat.AZTEC,
       ZXing.BarcodeFormat.CODABAR,
       ZXing.BarcodeFormat.CODE_39,
       ZXing.BarcodeFormat.CODE_93,
       ZXing.BarcodeFormat.CODE_128,
       ZXing.BarcodeFormat.DATA_MATRIX,
       ZXing.BarcodeFormat.MAXICODE,
       ZXing.BarcodeFormat.ITF,
       ZXing.BarcodeFormat.EAN_13,
       ZXing.BarcodeFormat.EAN_8,
       ZXing.BarcodeFormat.PDF_417,
       ZXing.BarcodeFormat.RSS_14,
       ZXing.BarcodeFormat.RSS_EXPANDED,
       ZXing.BarcodeFormat.UPC_A,
       ZXing.BarcodeFormat.UPC_E,
       ZXing.BarcodeFormat.UPC_EAN_EXTENSION
      
    • Library size increased to 319Kb.

V1.2.3

11 Oct 11:37
b396404
Compare
Choose a tag to compare

Version 1.2.3

  • Added support for videoConstraints in config as an experimental config.

        /* videoConstraints: {MediaTrackConstraints}, Optional
         *  @beta(this config is not well supported yet).
         *
         *  Important: When passed this will override other configurations
         *  like 'cameraIdOrConfig' or configurations like 'aspectRatio'.
         *
         *  videoConstraints should be of type {@code MediaTrackConstraints}
         *  as defined in
         *  https://developer.mozilla.org/en-US/docs/Web/API/MediaTrackConstraints
         *  and is used to specify a variety of video or camera controls
         *  like: aspect ratio, facing mode, video frame rate.
         */

    If passed this will override cameraIdOrConfig and aspectRatio.

  • Added two new experimental APIs in Html5Qrcode class

    • getRunningTrackCapabilities() - New
      /**
       * Returns the capabilities of the running video track.
       * 
       * @beta This is an experimental API
       * @returns the capabilities of a running video track.
       * @throws error if the scanning is not in running state.
       */
      getRunningTrackCapabilities()
    • applyVideoConstraints(videoConstaints) - New
      /**
       * Apply a video constraints on running video track.
       * 
       * Important:
       *  1. Must be called only if the camera based scanning is in progress.
       *  2. Changing aspectRatio while scanner is running is not yet supported.
       * 
       * @beta This is an experimental API
       * @param {MediaTrackConstraints} specifies a variety of video or camera
       *  controls as defined in 
       *  https://developer.mozilla.org/en-US/docs/Web/API/MediaTrackConstraints
       * @returns a Promise which succeeds if the passed constraints are applied,
       *  fails otherwise.
       * @throws error if the scanning is not in running state.
       */
      applyVideoConstraints(videoConstaints) {}

V1.2.2

20 Sep 05:52
a69f707
Compare
Choose a tag to compare

Version 1.2.2

  • Bug fix in Html5QrcodeScanner - file scanning.

V1.2.1

30 Aug 10:08
e01c690
Compare
Choose a tag to compare

Added support for facingMode constraing in Html5Qrcode#start

Update:
In mobile devices you may want users to directly scan the QR code using the back camera or the front camera for some use cases. For such cases you can avoid using the exact camera device id that you get from Html5Qrcode.getCameras(). The start() method allows passing constraints in place of camera device id similar to html5 web API syntax. You can start scanning like mentioned in these examples:

const html5QrCode = new Html5Qrcode("#reader");
const qrCodeSuccessCallback = message => { /* handle success */ }
const config = { fps: 10, qrbox: 250 };

// If you want to prefer front camera
html5QrCode.start({ facingMode: "user" }, config, qrCodeSuccessCallback);

// If you want to prefer back camera
html5QrCode.start({ facingMode: "environment" }, config, qrCodeSuccessCallback);

// Select front camera or fail with `OverconstrainedError`.
html5QrCode.start({ facingMode: { exact: "user"} }, config, qrCodeSuccessCallback);

// Select back camera or fail with `OverconstrainedError`.
html5QrCode.start({ facingMode: { exact: "environment"} }, config, qrCodeSuccessCallback);

V1.2.0

09 Aug 07:35
0c59227
Compare
Choose a tag to compare

Version 1.2.0

  • Added support for scanning mirrored QR code, or scanning in case camera feed is mirrored (horizontally flipped).

V1.1.9

02 Aug 10:52
fe424f3
Compare
Choose a tag to compare

Version 1.1.9

  • Added support for config.aspectRatio in both Html5Qrcode and Html5QrcodeScanner

    Use this property to render the video feed in a certain aspect ratio. Passing a nonstandard aspect ratio like 100000:1 could lead to the video feed not even showing up. Ideal values can be:

    Value Aspect Ratio Use Case
    1.333334 4:3 Standard camera aspect ratio
    1.777778 16:9 Fullscreen, cinematic
    1.0 1:1 Square view