QRcode incorporating Logo with optional image style

Created on 7 October 2023, about 1 year ago

Problem/Motivation

Designing visually appealing and branded QR codes that match your brand's identity is crucial for making them effective in your marketing campaigns.

Support the ability of the logo for generated QR codes,

Patch for another module available here: ✨ QR Custom Logo with optional image style Needs review

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

✨ Feature request
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States SocialNicheGuru

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @SocialNicheGuru
  • πŸ‡ΊπŸ‡ΈUnited States tr Cascadia

    QR codes are designed with built-in error correction. This allows part of the QR code to be obscured while still allowing the QR to be scanned and read.

    The way logos usually work are they are simply placed on top of the QR code. Yes, this obscures some of the code, but the code and be read if the logo is small enough. QR code error correction levels allow between 7% and 30% of the QR code to be obscured.

    You can currently easily do this in the Barcodes module with theming. The barcode--qrcode.html.twig template controls how QR codes are displayed - all you have to do is add an img tag and some CSS to control the size and positioning of your logo img on top of the QR code.

    I have some code running locally that lets me increase the default error correction level from the UI - this increases the complexity of the QR code and allows more of it to be obscured. I plan to commit that code eventually, but because overlaying the logo is something easily done with theming I don't have any current plans to put that in unless someone wants to help out with a patch. And I would suggest that a more productive and useful strategy would be to ensure that images generated by this module can use Drupal image filters - that allows modules like image_effects to do things like add overlays without needing any additional code in the Barcodes module. This may be possible already, and may just need documentation.

Production build 0.71.5 2024