MalikDzgn: QR Code
  • Jelajahi

    Copyright © MalikDzgn -

    Quickly update interesting info starting today

    Malikdzgn

    Malikdzgn
    Affichage des articles dont le libellé est QR Code. Afficher tous les articles
    Affichage des articles dont le libellé est QR Code. Afficher tous les articles

    vendredi 12 février 2021

    Creative Art QR Code Generator – ArtQRCode

    Creative Art QR Code Generator – ArtQRCode

     

    Creative Art QR Code Generator – ArtQRCode

    Category: Javascript , Recommended | September 5, 2019
    AUTHOR:252860883
    VIEWS TOTAL:2,480 views
    OFFICIAL PAGE:Go to website
    LAST UPDATE:September 5, 2019
    LICENSE:MIT

    Preview:

    Creative Art QR Code Generator – ArtQRCode

    Description:

    An art QR code generator that enables you to generate creative, gorgeous QR codes using your own materials.

    How to use it:

    Import the main JavaScript artqrcode.js into the document.

    <script src="./artqrcode.js"></script>

    Create a placeholder to place the generated QR code.

    <div id="qrcode"></div>

    Generate a QR code using default materials.

    let qrcode = new QRCode(document.getElementById("qrcode"), {
        text: "https://cssscript.com"
    });

    Set the size & position of the QR code.

    let qrcode = new QRCode(document.getElementById("qrcode"), {
        width: 500,
        height: 500,
        codeWidth: 330,
        codeHeight: 330,
        top: 85,
        left: 85
    });

    Replace the default materials to create your own styles.

    let qrcode = new QRCode(document.getElementById("qrcode"), {
        materials: {
          border: "./materials/border.png",
          eye: "./materials/eye.png",
          row4: "./materials/row4.png",
          col4: "./materials/col3.png",
          row2col3: "./materials/row2col3.png",
          row3col2: "./materials/row3col2.png",
          col3: ["./materials/col3.png", "./materials/col3_2.png"],
          row2col2: "./materials/row2col2.png",
          corner: "./materials/corner.png",
          row2: ["./materials/row2.png", "./materials/row2_2.png"],
          col2: "./materials/col2.png",
          single: ["./materials/single.png", "./materials/single_2.png"],
        }
    });

    All default configs to customize the art QR code.

    let qrcode = new QRCode(document.getElementById("qrcode"), { 
        width: 256,
        height: 256,
        bgWidth: 256,
        bgHeight: 256,
        codeWidth:256,
        codeHeight:256,
        top: 0,
        left: 0,
        typeNumber: 4,
        colorDark: "#000000",
        colorLight: "#ffffff",
        correctLevel: QRErrorCorrectLevel.L,
        materials: {
          eye: "",
          row2col3: "",
          row3col2: "",
          row4: "",
          col4: "",
          row3: "",
          col3: "",
          row2col2: "",
          corner: "",
          col2: "",
          row2: "",
          single: ""
        }
    });

    Clear the QR code.

    qrcode.clear();

    Recreate the QR code.

    qrcode.makeCode("New Content Here");

    Execute a callback function after loaded.

    function myCallBack(status) {
      console.log(status) // [loaded|success]
    }
    
    let qrcode = new QRCode(document.getElementById("qrcode"), {
        // options here
    }, myCallBack);

    Changelog:

    09/05/2019

    • support callback function
    Space-saving QR Code Generator – qrize.js

    Space-saving QR Code Generator – qrize.js

     

    Space-saving QR Code Generator – qrize.js

    Category: Javascript | October 15, 2018
    AUTHOR:qrize
    VIEWS TOTAL:797 views
    OFFICIAL PAGE:Go to website
    LAST UPDATE:October 15, 2018
    LICENSE:MIT

    Preview:

    Space-saving QR Code Generator – qrize.js

    Description:

    qrize.js is a JavaScript library used to generate space-saving, image/SVG/table based QR codes with URL shortener service integration.

    How to use it:

    Install and import the qrize.js package.

    # Yarn
    $ yarn add qrize
    
    # NPM
    $ npm install qrize --save
    import Qrize from "qrize";

    Or include the ‘qrize.umd.js’ directly on the web page.

    <script src="qrize.umd.js"></script>

    Create a container to place the generated QR code.

    <div id="target"></div>

    Initialize the QR code generator.

    var qr = new Qrize({
        element: document.getElementById('target')
    });

    Generate a QR code inside the container.

    qrize.createImg({ 
      url: "https://cssscript.com/" 
    });
    
    // or
    qrize.createSvg({ 
      url: "https://cssscript.com/" 
    });
    
    // or
    qrize.createTable({ 
      url: "https://cssscript.com/" 
    });

    To config the QR generator just by passing the following parameters to the constructor.

    const qrize = new Qrize({
          element: document.getElementById("qr-target"),
          cellSize: 2,
          margin: 0
    });

    Callback functions.

    qrize.createImg({ 
      url: "https://cssscript.com/",
      onSuccess: function onQrizeSuccess() {
        console.log('Success');
      },
      onFailure: function onQrizeFailure(status, text) {
        console.log('Failure: ', status, text);
      }
    });

    API methods.

    Qrize.getHash({
      url: 'https://cssscript.com/',
      onSuccess({ hash }) {
        console.log(hash);
      }
    })
    
    Qrize.getUrl({
      hash: 'xxx',
      onSuccess({ url }) {
        console.log(url);
      }
    })

    Changelog:

    v0.4.0 (10/15/2018)

    • Add flow annotations
    QR Code Generator With Logo And Title Support – EasyQRCodeJS

    QR Code Generator With Logo And Title Support – EasyQRCodeJS

     

    QR Code Generator With Logo And Title Support – EasyQRCodeJS

    Category: Javascript | February 1, 2021
    AUTHOR:ushelp
    VIEWS TOTAL:300 views
    OFFICIAL PAGE:Go to website
    LAST UPDATE:February 1, 2021
    LICENSE:MIT

    Preview:

    QR Code Generator With Logo And Title Support – EasyQRCodeJS

    Description:

    EasyQRCodeJS is a cross-browser, client-side QR code generator that supports custom logo and title.

    Based on JavaScript, HTML5 canvas and HTML table. Heavily based on the qrcodejs library.

    How to use it:

    Install & download.

    # NPM
    $ npm install easyqrcodejs --save

    Import the EasyQRCodeJS into the HTML document.

    <script src="easy.qrcode.js"></script>

    Create a container in which you want to place the QR code.

    <div id="qrcode"></div>

    Generate a basic QR code.

    var qrcode = new QRCode(document.getElementById("qrcode"), {
        text: "https://cssscript.com"
    });

    Add a custom logo to the QR code.

    var qrcode = new QRCode(document.getElementById("qrcode"), {
        text: "https://cssscript.com",
        logo: "logo.png",
        logoWidth: undefined,
        logoHeight: undefined,
        logoBackgroundColor: '#ffffff',
        logoBackgroundTransparent: false
    });

    Add custom title and subtitle to the QR code.

    var qrcode = new QRCode(document.getElementById("qrcode"), {
        title: "",
        titleFont: "bold 16px Arial",
        titleColor: "#000000",
        titleBackgroundColor: "#ffffff",
        titleHeight: 0,
        titleTop: 30, 
    
        subTitle: "",
        subTitleFont: "14px Arial",
        subTitleColor: "#4F4F4F",
        subTitleTop: 0,
    });

    Customize the appearance of the QR code.

    var qrcode = new QRCode(document.getElementById("qrcode"), {
        width: 256,
        height: 256,
        typeNumber: 4,
        colorDark: "#000000",
        colorLight: "#ffffff",
        correctLevel: QRErrorCorrectLevel.H,
        quietZone: 0,
        quietZoneColor: 'transparent',
        // === Posotion Pattern(Eye) Color
        PO: undefined, // Global Posotion Outer color. if not set, the defaut is `colorDark`
        PI: undefined, // Global Posotion Inner color. if not set, the defaut is `colorDark`
        PO_TL: undefined, // Posotion Outer - Top Left 
        PI_TL: undefined, // Posotion Inner - Top Left 
        PO_TR: undefined, // Posotion Outer - Top Right 
        PI_TR: undefined, // Posotion Inner - Top Right 
        PO_BL: undefined, // Posotion Outer - Bottom Left 
        PI_BL: undefined, // Posotion Inner - Bottom Left 
    
        // === Alignment Color
        AO: undefined, // Alignment Outer. if not set, the defaut is `colorDark`
        AI: undefined, // Alignment Inner. if not set, the defaut is `colorDark`
    
        // === Timing Pattern Color
        timing: undefined, // Global Timing color. if not set, the defaut is `colorDark`
        timing_H: undefined, // Horizontal timing color
        timing_V: undefined, // Vertical timing color
    
        // ==== Backgroud Image
        backgroundImage: undefined, // Background Image
        backgroundImageAlpha: 1, // Background image transparency, value between 0 and 1. default is 1. 
        autoColor: false,
        autoColorDark: "rgba(0, 0, 0, .6)", // Automatic color: dark CSS color
        autoColorLight: "rgba(255, 255, 255, .7)", // Automatic color: light CSS color
    
        // IE9+ Only
        dotScale: 1,
    
        // from Version 1 to Version 40. 0 means automatically choose the closest version based on the text length.
        version: 0, 
    
        // Whether set the QRCode Text as the title attribute value of the image
        tooltip: false, 
    
        // binary mode or not
        binary: false, 
    
        // or 'svg'
        drawer: 'canvas',
    
        // specifies the CORS setting to use when retrieving the image
        crossOrigin: null
    
        // ==== Event Handler
        onRenderingStart: undefined,
        onRenderingEnd: undefined,
    });

    Remove the QR code.

    qrcode.clear();

    Re-generate a new QR code.

    qrcode.makeCode("New Content Here");

    Resize the QR code.

     qrcode.resize(460, 460);

    Changelog:

    v4.3.2 (02/01/2021)

    • Remove annoying console log

    v4.3.1 (01/06/2021)

    • Fixed `quietZoneColor` issue

    v4.3.0 (01/03/2021)

    • Add `autoColorDark`, `autoColorLight` options

    v4.2.1 (12/29/2020)

    • Bugfixed

    v4.2.0 (12/29/2020)

    • Add crossOrigin option.

    v4.1.0 (12/17/2020)

    • Add dotSacale for Timing and Alignment

    v4.0.0 (10/13/2020)

    • Add the feature of generating SVG images

    v3.8.2 (09/28/2020)

    • Updated

    v3.8.1 (08/11/2020)

    • Add EasyQRCode-React-Native

    v3.8.0 (08/04/2020)

    • Cross-browser support for QR code generation based on HTML5 Canvas and Table
    • Required Patterns that support dot style
    • Support for Quiet Zone settings
    • Support custom Position Pattern inner fill and outer border color
    • Support custom Alignment Pattern inner fill and outer border color
    • Support custom Timing Patterns vertical, horizontal color
    • Support Logo images (including transparent PNG images)
    • Support Background Image
    • Support for title, subtitle settings
    • Has no dependencies
    • Support AMD, CMD, CommonJS/Node.js JavaScript modules
    • Angular, Vue.js, React, Next.js Support
    • Support binary(hex) data mode

    v3.7.0 (06/05/2020)

    • Preserve logo image proportions support. You can use any proportion of your logo image, it will be displayed centered in proportion within the range of logoWidth and logoHeight.

    v3.6.0 (05/05/2020)

    • Update easy.qrcode.js

    v3.5.4 (04/14/2020)

    • Fix the error of colorLight in PNG format.

    v3.5.2 (03/24/2020)

    • fixed title and subtitle top invalid issue

    v3.5.0 (01/14/2020)

    • You can control the QR Code version(0-40) now, 0 means that automatically choose the closest version based on the text length

    v3.4.0 (01/10/2020)

    • Fixed a bug when quietZone and title were used together
    • Change onRenderingStart() to onRenderingStart(qrCodeOptions)

    v3.3.0 (12/20/2019)

    • A feature-rich cross-browser QRCode generator for pure javascript.

    v3.2.0 (09/06/2019)

    • Add Angular, Vue.js, React support

    v3.2.0 (09/06/2019)

    • Updated

    v3.1.0 (08/12/2019)

    • Support AMD, CMD, CommonJS/Node.js JavaScript modules

    v3.0.0 (08/08/2019)

    • Added more options

    v2.2.0 (07/19/2019)

    • Added more options
    Flexible Client-side QR Code Generator

    Flexible Client-side QR Code Generator

     

    Flexible Client-side QR Code Generator

    Category: Javascript , Recommended | November 5, 2018
    AUTHOR:nayuki
    VIEWS TOTAL:2,189 views
    OFFICIAL PAGE:Go to website
    LAST UPDATE:November 5, 2018
    LICENSE:MIT

    Preview:

    Flexible Client-side QR Code Generator

    Description:

    Just another flexible, customizable, client-side QR code generator built using pure JavaScript. Also supports Java, Python, and C++.

    Main features:

    • Error correction level: Low, Medium, Quartile and High
    • Output format: bitmap or vector
    • Custom scale and border

    How to use it:

    Import the QR Code Generator’s JavaScript file into the html page.

    <script src="qrcodegen.js"></script>

    Basic usages:

    // Name abbreviated for the sake of these examples here
    var QRC = qrcodegen.QrCode;
    
    // Simple operation
    var qr0 = QRC.encodeText("Hello, world!", QRC.Ecc.MEDIUM);
    var svg = qr0.toSvgString(4);
    
    // Manual operation
    var segs = qrcodegen.QrSegment.makeSegments("3141592653589793238462643383");
    var qr1 = QRC.encodeSegments(segs, QRC.Ecc.HIGH, 5, 5, 2, false);

    Changelog:

    11/05/2018

    • Reordered calls to applyMask()/drawFormatBits() for conceptual clarity, without changing output (because masks don’t affect format bits), in all language versions.

    11/02/2018

    • Simplified a bit of code in JavaScript, TypeScript, Python.

    10/29/2018

    • Tweaked JavaScript code to use String.substring() instead of the deprecated non-standard substr().

    10/27/2018

    • Completely rewrote the algorithm for detecting finder-like patterns, making it more accurate and compliant with the QR Code specification, in all languages.

    10/14/2018

    • Tweaked QrCode.drawFormatBits() to use end-exclusive range in second copy for clarity, in most languages.

    10/09/2018

    • Simplified a bit of JavaScript and TypeScript code.

    10/06/2018

    • Renamed QrSegment.getBits() to getData() in {Java, JavaScript, TypeScript, Python} code, to match C++ and Rust.

    10/04/2018

    • Tweaked {JavaScript, TypeScript, HTML} code to encapsulate the application members.

    10/02/2018

    • Tweaked the BitBuffer class top-level comment in all languages except C.
    • Tweaked BitBuffer.appendBits() comment in several language versions.

    09/17/2018

    • Swapped {dy,dx} variables in commutative operations for clarity, in all languages.

    09/01/2018

    • Reformatted some whitespace for alignment in all language versions.

    08/28/2018

    • Added an assertion to QrCode.encodeSegmentsAdvanced() in all language versions.