@aurigma/design-editor-iframe
Version:
Using this module you can embed Design Editor (a part of Customer's Canvas) to your page through the IFrame API.
127 lines (126 loc) • 3.83 kB
TypeScript
/**
* A structure containing data that can be encoded into barcodes.
* @example
* ``` js
* var configuration = {
* autoLoadUserInfo: true,
* userInfo: {
* "Ean 8": {
* "BarcodeFormat": "EAN_8",
* "BarcodeValue": "1234567"
* },
* "Ean 13": {
* "BarcodeFormat": "EAN_13",
* "BarcodeValue": "123456789012"
* },
* "Qr Code": {
* "BarcodeFormat": "QR_CODE",
* "BarcodeSubType": "Url",
* "Url": "https://example.com"
* }
* }
* };
* ```
* @public
*/
export interface IBarcodeData {
/** The barcode type. */
barcodeFormat: BarcodeFormat;
/** The QR code subtype. */
barcodeSubType?: BarcodeSubType;
/** The first name encoded into this barcode. */
firstName?: string;
/** The last name encoded into this barcode. */
lastName?: string;
/** The organization name encoded into this barcode. */
organization?: string;
/** The job position encoded into this barcode. */
position?: string;
/** The email address encoded into this barcode. */
email?: string;
/** The mobile phone number encoded into this barcode. */
mobilePhone?: string;
/** The URL encoded into this barcode. */
url?: string;
/** The phone number encoded into this barcode. */
phone?: string;
/** Arbitrary data encoded into QR code. */
data?: string;
/** A value encoded into this barcode. */
barcodeValue?: string;
}
/**
* An enumeration of barcode formats.
* @example
* ``` js
* var configuration = {
* autoLoadUserInfo: true,
* userInfo: {
* "Ean 8": {
* "BarcodeFormat": "EAN_8",
* "BarcodeValue": "1234567"
* },
* "Ean 13": {
* "BarcodeFormat": "EAN_13",
* "BarcodeValue": "123456789012"
* },
* "Qr Code": {
* "BarcodeFormat": "QR_CODE",
* "BarcodeSubType": "Url",
* "Url": "https://example.com"
* }
* }
* };
* ```
* @public
*/
export declare enum BarcodeFormat {
/** Design element representing a barcode in the Code 128B format. */
CODE_128 = "CODE_128",
/** Design element representing a linear EAN-8 code. */
EAN_8 = "EAN_8",
/** Design element representing a linear EAN-13 code. */
EAN_13 = "EAN_13",
/** Design element representing a 13-digit UPC-A code. */
UPC_A = "UPC_A",
/** Design element representing an 8-digit UPC-E code. */
UPC_E = "UPC_E",
/** Design element representing a QR code. Together with QR codes, you can specify {@link BarcodeSubType}. */
QR_CODE = "QR_CODE",
/** Design element representing a DataMatrix code. */
DATA_MATRIX = "DATA_MATRIX"
}
/**
* An enumeration of QR code subtypes.
* @example
* ``` js
* var configuration = {
* autoLoadUserInfo: true,
* userInfo: {
* "Phone Number": {
* "BarcodeFormat": "QR_CODE",
* "BarcodeSubType": "Phone",
* "Phone": "5551234567"
* },
* "Url": {
* "BarcodeFormat": "QR_CODE",
* "BarcodeSubType": "Url",
* "Url": "https://example.com"
* }
* }
* };
* ```
* @public
*/
export declare enum BarcodeSubType {
/** QR code that does not require a subtype. */
None = "None",
/** QR code representing VCard. */
VCard = "VCard",
/** QR code representing a phone number. This barcode subtype uses the {@link IBarcodeData.phone} value. */
Phone = "Phone",
/** QR code representing a URL address. This barcode subtype uses the {@link IBarcodeData.url} value. */
Url = "Url",
/** QR code representing arbitrary data. */
Data = "Data"
}