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

@xcoobee/payment-sdk

Package Overview
Dependencies
Maintainers
3
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@xcoobee/payment-sdk - npm Package Compare versions

Comparing version 0.8.4 to 0.9.0

dist/browser/base64/browserBase64.d.ts

14

dist/browser/browser.js

@@ -17,11 +17,2 @@ var __extends = (this && this.__extends) || (function () {

/**
* Implements web version of Base64Interface to manipulate base64 strings
*
* @implements Base64Interface
*/
export var base64 = {
atob: function (str) { return atob(str); },
btoa: function (str) { return btoa(str); },
};
/**
* Implements web version of QrGeneratorInterface to generate QRs

@@ -31,3 +22,3 @@ *

*/
export var qrGenerator = {
var qrGenerator = {
generate: function (url, size) {

@@ -77,3 +68,3 @@ return new Promise(function (resolve) {

function BrowserXcooBeePaymentSDK(config) {
return _super.call(this, config, base64, qrGenerator) || this;
return _super.call(this, config, qrGenerator) || this;
}

@@ -83,1 +74,2 @@ return BrowserXcooBeePaymentSDK;

export { BrowserXcooBeePaymentSDK };
//# sourceMappingURL=browser.js.map

@@ -11,2 +11,3 @@ var __spreadArrays = (this && this.__spreadArrays) || function () {

/**
* @internal
* @class Builder

@@ -117,3 +118,3 @@ */

Builder.prototype.getKey = function () {
return "" + this.reference + this.amount + this.tax;
return this.reference + "_" + this.amount + "_" + this.tax;
};

@@ -158,2 +159,3 @@ /**

this.reference = config["0-6"];
this.logic = [];
if (config.l) {

@@ -248,3 +250,3 @@ (Array.isArray(config.l) ? config.l : [config.l]).forEach(function (item) {

* Makes current item a tip item
* This will render separte item in basket with tip inputs
* This will render separate item in basket with tip inputs
*

@@ -402,1 +404,2 @@ * @returns {Builder}

export { Builder };
//# sourceMappingURL=Builder.js.map

@@ -5,2 +5,5 @@ /**

import { FlexPaymentActions } from "./types";
/**
* @internal
*/
export var conflictingActions = [

@@ -21,3 +24,10 @@ FlexPaymentActions.externalPricing,

export var defaultQrSize = 450;
/**
* @internal
*/
export var appUrl = "https://app.xcoobee.com";
/**
* @internal
*/
export var logoSrc = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB2ZXJzaW9uPSIxLjIiIHdpZHRoPSI5NC4yM21tIiBoZWlnaHQ9IjkzLjk4bW0iIHZpZXdCb3g9IjAgMCA5NDIzIDkzOTgiIHByZXNlcnZlQXNwZWN0UmF0aW89InhNaWRZTWlkIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiIHN0cm9rZS13aWR0aD0iMjguMjIyIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOm9vbz0iaHR0cDovL3htbC5vcGVub2ZmaWNlLm9yZy9zdmcvZXhwb3J0IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeG1sbnM6cHJlc2VudGF0aW9uPSJodHRwOi8vc3VuLmNvbS94bWxucy9zdGFyb2ZmaWNlL3ByZXNlbnRhdGlvbiIgeG1sbnM6c21pbD0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9TTUlMMjAvIiB4bWxuczphbmltPSJ1cm46b2FzaXM6bmFtZXM6dGM6b3BlbmRvY3VtZW50OnhtbG5zOmFuaW1hdGlvbjoxLjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPgogPGRlZnMgY2xhc3M9IkNsaXBQYXRoR3JvdXAiPgogIDxjbGlwUGF0aCBpZD0icHJlc2VudGF0aW9uX2NsaXBfcGF0aCIgY2xpcFBhdGhVbml0cz0idXNlclNwYWNlT25Vc2UiPgogICA8cmVjdC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AgICAgPHBhdGggZmlsbD0icmdiKDI1NSwyNTUsMjU1KSIgc3Ryb2tlPSJub25lIiBkPSJNIDkwMyw3MjkxIEMgMTgxOCw4MjA0IDI1NTEsNjkyNSAyNTUxLDY5MjUgTCAyNTUxLDQzMzQgQyAyNTUxLDQzMzQgLTQxNyw1OTc4IDkwMyw3MjkxIFoiLz4KICAgICAgIDwvZz4KICAgICAgPC9nPgogICAgICA8ZyBjbGFzcz0iY29tLnN1bi5zdGFyLmRyYXdpbmcuQ2xvc2VkQmV6aWVyU2hhcGUiPgogICAgICAgPGcgaWQ9ImlkMTMiPgogICAgICAgIDxyZWN0IGNsYXNzPSJCb3VuZGluZ0JveCIgc3Ryb2tlPSJub25lIiBmaWxsPSJub25lIiB4PSI2ODcyIiB5PSI0MzMzIiB3aWR0aD0iMTk4OSIgaGVpZ2h0PSIzMjg4Ii8+CiAgICAgICAgPHBhdGggZmlsbD0icmdiKDI1NSwyNTUsMjU1KSIgc3Ryb2tlPSJub25lIiBkPSJNIDY4NzIsNDMzNCBMIDY4NzIsNjkyNSBDIDY4NzIsNjkyNSA3NjA1LDgyMDQgODUyMSw3MjkxIDg3NTQsNzA1OSA4ODUzLDY4MTggODg1OSw2NTc2IEwgODg1OSw2NTczIEMgODg4MSw1NDQ3IDY4NzIsNDMzNCA2ODcyLDQzMzQgWiIvPgogICAgICAgPC9nPgogICAgICA8L2c+CiAgICAgPC9nPgogICAgPC9nPgogICA8L2c+CiAgPC9nPgogPC9nPgo8L3N2Zz4=";
//# sourceMappingURL=config.js.map

@@ -14,1 +14,2 @@ export var FlexPaymentActions;

})(FlexPaymentActions || (FlexPaymentActions = {}));
//# sourceMappingURL=types.js.map

@@ -0,4 +1,5 @@

import { base64 } from "./base64/browserBase64";
import { appUrl, defaultQrSize, maxDataPackageSize, maxDeviceIdLength, maxSourceLength, urlMaxLength, } from "./config";
import { Builder } from "./Builder";
import { Combinator } from "./Combinator";
import { combineToJSON } from "./utils";
/**

@@ -8,3 +9,3 @@ * class XcooBeePaymentSDK

var XcooBeePaymentSDK = /** @class */ (function () {
function XcooBeePaymentSDK(config, base64, qrGenerator) {
function XcooBeePaymentSDK(config, qrGenerator) {
if (!config) {

@@ -16,5 +17,2 @@ throw new Error("config is required");

}
if (!base64) {
throw new Error("base64 is required");
}
if (config.xcoobeeDeviceId && config.xcoobeeDeviceId.length > maxDeviceIdLength) {

@@ -38,3 +36,2 @@ throw new Error("Max xcoobeeDeviceId length is " + maxDeviceIdLength);

this.source = config.source;
this.base64 = base64;
this.qrGenerator = qrGenerator;

@@ -62,7 +59,5 @@ }

if (flexItems === void 0) { flexItems = []; }
var dataPackage = flexItems.length
? this.base64.btoa(Combinator.combineToJSON(flexItems))
: "";
var dataPackage = flexItems.length ? base64.btoa(combineToJSON(flexItems)) : "";
if (dataPackage.length > maxDataPackageSize) {
throw new Error("Data package is too large");
throw new Error("Data package is too large, max size: " + maxDataPackageSize + ", received: " + dataPackage.length);
}

@@ -309,1 +304,2 @@ var params = {

export { XcooBeePaymentSDK };
//# sourceMappingURL=XcooBeePaymentSDK.js.map

@@ -7,2 +7,3 @@ "use strict";

/**
* @internal
* @class Builder

@@ -108,3 +109,3 @@ */

getKey() {
return `${this.reference}${this.amount}${this.tax}`;
return `${this.reference}_${this.amount}_${this.tax}`;
}

@@ -148,2 +149,3 @@ /**

this.reference = config["0-6"];
this.logic = [];
if (config.l) {

@@ -237,3 +239,3 @@ (Array.isArray(config.l) ? config.l : [config.l]).forEach((item) => this.addLogic(item));

* Makes current item a tip item
* This will render separte item in basket with tip inputs
* This will render separate item in basket with tip inputs
*

@@ -390,2 +392,1 @@ * @returns {Builder}

exports.Builder = Builder;
//# sourceMappingURL=Builder.js.map

@@ -8,2 +8,5 @@ "use strict";

const types_1 = require("./types");
/**
* @internal
*/
exports.conflictingActions = [

@@ -24,4 +27,9 @@ types_1.FlexPaymentActions.externalPricing,

exports.defaultQrSize = 450;
/**
* @internal
*/
exports.appUrl = "https://app.xcoobee.com";
/**
* @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b2tlPSJub25lIiBkPSJNIDkwMyw3MjkxIEMgMTgxOCw4MjA0IDI1NTEsNjkyNSAyNTUxLDY5MjUgTCAyNTUxLDQzMzQgQyAyNTUxLDQzMzQgLTQxNyw1OTc4IDkwMyw3MjkxIFoiLz4KICAgICAgIDwvZz4KICAgICAgPC9nPgogICAgICA8ZyBjbGFzcz0iY29tLnN1bi5zdGFyLmRyYXdpbmcuQ2xvc2VkQmV6aWVyU2hhcGUiPgogICAgICAgPGcgaWQ9ImlkMTMiPgogICAgICAgIDxyZWN0IGNsYXNzPSJCb3VuZGluZ0JveCIgc3Ryb2tlPSJub25lIiBmaWxsPSJub25lIiB4PSI2ODcyIiB5PSI0MzMzIiB3aWR0aD0iMTk4OSIgaGVpZ2h0PSIzMjg4Ii8+CiAgICAgICAgPHBhdGggZmlsbD0icmdiKDI1NSwyNTUsMjU1KSIgc3Ryb2tlPSJub25lIiBkPSJNIDY4NzIsNDMzNCBMIDY4NzIsNjkyNSBDIDY4NzIsNjkyNSA3NjA1LDgyMDQgODUyMSw3MjkxIDg3NTQsNzA1OSA4ODUzLDY4MTggODg1OSw2NTc2IEwgODg1OSw2NTczIEMgODg4MSw1NDQ3IDY4NzIsNDMzNCA2ODcyLDQzMzQgWiIvPgogICAgICAgPC9nPgogICAgICA8L2c+CiAgICAgPC9nPgogICAgPC9nPgogICA8L2c+CiAgPC9nPgogPC9nPgo8L3N2Zz4=";
//# sourceMappingURL=config.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.NodeXcooBeePaymentSDK = exports.qrGenerator = exports.base64 = void 0;
exports.NodeXcooBeePaymentSDK = void 0;
const XcooBeePaymentSDK_1 = require("./XcooBeePaymentSDK");
const config_1 = require("./config");
/**
* Implements node version of Base64Interface to manipulate base64 strings
*
* @implements Base64Interface
*/
exports.base64 = {
atob: (str) => Buffer.from(str, "base64").toString(),
btoa: (str) => Buffer.from(str).toString("base64"),
};
/**
* Implements node version of QrGeneratorInterface to generate QRs

@@ -20,3 +11,3 @@ *

*/
exports.qrGenerator = {
const qrGenerator = {
generate: (url, size) => {

@@ -54,6 +45,5 @@ let QrCode;

constructor(config) {
super(config, exports.base64, exports.qrGenerator);
super(config, qrGenerator);
}
}
exports.NodeXcooBeePaymentSDK = NodeXcooBeePaymentSDK;
//# sourceMappingURL=node.js.map

@@ -17,2 +17,1 @@ "use strict";

})(FlexPaymentActions = exports.FlexPaymentActions || (exports.FlexPaymentActions = {}));
//# sourceMappingURL=types.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.XcooBeePaymentSDK = void 0;
const base64_1 = require("./base64/nodeBase64");
const config_1 = require("./config");
const Builder_1 = require("./Builder");
const Combinator_1 = require("./Combinator");
const utils_1 = require("./utils");
/**

@@ -11,3 +12,3 @@ * class XcooBeePaymentSDK

class XcooBeePaymentSDK {
constructor(config, base64, qrGenerator) {
constructor(config, qrGenerator) {
if (!config) {

@@ -19,5 +20,2 @@ throw new Error("config is required");

}
if (!base64) {
throw new Error("base64 is required");
}
if (config.xcoobeeDeviceId && config.xcoobeeDeviceId.length > config_1.maxDeviceIdLength) {

@@ -41,3 +39,2 @@ throw new Error(`Max xcoobeeDeviceId length is ${config_1.maxDeviceIdLength}`);

this.source = config.source;
this.base64 = base64;
this.qrGenerator = qrGenerator;

@@ -64,7 +61,5 @@ }

getUrl(flexItems = []) {
const dataPackage = flexItems.length
? this.base64.btoa(Combinator_1.Combinator.combineToJSON(flexItems))
: "";
const dataPackage = flexItems.length ? base64_1.base64.btoa(utils_1.combineToJSON(flexItems)) : "";
if (dataPackage.length > config_1.maxDataPackageSize) {
throw new Error("Data package is too large");
throw new Error(`Data package is too large, max size: ${config_1.maxDataPackageSize}, received: ${dataPackage.length}`);
}

@@ -302,2 +297,1 @@ const params = {

exports.XcooBeePaymentSDK = XcooBeePaymentSDK;
//# sourceMappingURL=XcooBeePaymentSDK.js.map

@@ -12,3 +12,3 @@ {

"license": "Apache-2.0",
"version": "0.8.4",
"version": "0.9.0",
"description": "",

@@ -30,6 +30,9 @@ "homepage": "https://github.com/XcooBee/payment-sdk-js#readme",

"scripts": {
"test": "mocha -r ts-node/register tests/**/*.test.ts",
"coverage": "nyc -r lcov -e .ts -x \"*.test.ts\" npm run test",
"docs": "typedoc",
"build": "tsc && tsc -p tsconfig.browser.json"
"test": "ts-mocha -p tsconfig.json --paths tests/**/*.test.ts",
"coverage": "nyc --check-coverage -r lcov -e .ts -x \"*.test.ts\" npm run test",
"docs-node": "typedoc --mode file --excludeNotExported --excludePrivate --stripInternal --out docs/node --readme none",
"docs-web": "typedoc --tsconfig tsconfig.browser.json --mode file --excludeNotExported --excludePrivate --stripInternal --out docs/browser --readme none",
"docs": "rm -rf ./docs && npm run docs-node && npm run docs-web",
"build": "ttsc && ttsc -p tsconfig.browser.json",
"build-web-example": "webpack examples/web/web.js -o examples/web/web.bundle.js"
},

@@ -41,2 +44,13 @@ "prettier": {

},
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.ts": [
"prettier --write",
"tslint"
]
},
"devDependencies": {

@@ -46,3 +60,6 @@ "@types/chai": "^4.2.11",

"@types/node": "^14.0.13",
"@zerollup/ts-transform-paths": "^1.7.18",
"chai": "^4.2.0",
"husky": "^4.2.5",
"lint-staged": "^10.2.11",
"mocha": "^8.0.1",

@@ -53,4 +70,6 @@ "mocha-sinon": "^2.1.2",

"sinon": "^9.0.2",
"ts-node": "^8.10.2",
"ts-mocha": "^7.0.0",
"tsconfig-paths": "^3.9.0",
"tslint": "^6.1.2",
"ttypescript": "^1.5.10",
"typedoc": "^0.17.7",

@@ -57,0 +76,0 @@ "typedoc-plugin-markdown": "^2.3.1",

@@ -33,3 +33,3 @@ # XcooBee Contactless Payment SDK for JavaScript

See the [complete documentation here](docs/globals.md).
See the complete documentation for [node](docs/node/README.md) and [browser](docs/browser/README.md).

@@ -36,0 +36,0 @@ ## Deployment

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