Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

qreator

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

qreator - npm Package Compare versions

Comparing version 9.2.0 to 9.2.1

5

lib/browser/png.d.ts

@@ -1,6 +0,5 @@

/// <reference types="node" />
import { ImageOptions, Matrix } from "./typing/types";
export declare function getPNG(text: string, inOptions?: ImageOptions): Promise<Buffer>;
export declare function getPNG(text: string, inOptions?: ImageOptions): Promise<Uint8ClampedArray>;
export declare function generateImage({ matrix, size, margin, logo, logoWidth, logoHeight, color, bgColor, borderRadius, }: ImageOptions & {
matrix: Matrix;
}): Promise<Buffer>;
}): Promise<Uint8ClampedArray>;

@@ -1,6 +0,5 @@

/// <reference types="node" />
import { ImageOptions, Matrix } from "./typing/types";
export declare function getPNG(text: string, inOptions?: ImageOptions): Promise<Buffer>;
export declare function getPNG(text: string, inOptions?: ImageOptions): Promise<Uint8ClampedArray>;
export declare function generateImage({ matrix, size, margin, logo, logoWidth, logoHeight, color, bgColor, borderRadius, }: ImageOptions & {
matrix: Matrix;
}): Promise<Buffer>;
}): Promise<Uint8ClampedArray>;

3

lib/png.js

@@ -28,4 +28,5 @@ import { QR } from "./qr-base.js";

}
return await qrImage.png().toBuffer();
const { data } = await qrImage.png().toBuffer({ resolveWithObject: true });
return new Uint8ClampedArray(data.buffer);
}
//# sourceMappingURL=png.js.map

@@ -228,2 +228,8 @@ import test from "ava";

},
{
name: "PNG memory usage",
fn: getPNG,
filename: "qr_large.png",
params: { size: 300, margin: 10 },
}
].forEach((testData) => {

@@ -230,0 +236,0 @@ test.serial(testData.name, async (t) => {

{
"name": "qreator",
"version": "9.2.0",
"version": "9.2.1",
"description": "QR Code generator for browser and node.js with tree shaking and logo support",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/Short-io/qreator",

@@ -41,3 +41,4 @@ import { ImageOptions, Matrix } from "./typing/types";

}
return await qrImage.png().toBuffer();
const { data } = await qrImage.png().toBuffer({ resolveWithObject: true});
return new Uint8ClampedArray(data.buffer);
}

@@ -241,2 +241,8 @@ import test from "ava";

},
{
name: "PNG memory usage",
fn: getPNG,
filename: "qr_large.png",
params: { size: 300, margin: 10 },
}
] as TestParams[]).forEach((testData) => {

@@ -243,0 +249,0 @@ test.serial(testData.name, async (t) => {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc