Interface IBarcodeItemData
A structure defining the default parameters of barcodes.
Package: @aurigma/design-atoms-interfaces
Examples
The following example illustrates how you can enable two buttons in the Toolbox: the first one opens the standard **QrCode** dialog box, while the second custom button adds a predefined QR code to the canvas.
{
"widgets": {
"Toolbox": {
"buttons": [
"QrCode",
{
"action": "CustomBarcode",
"iconClass": "cc-icon-qr-code",
"itemConfig": {
"barcodeContent": {
"barcodeFormat": "QrUrl",
"url": "example.com"
},
"name": "Custom barcode",
"color": "rgb(255,0,0)",
"width": "100",
"location": {
"originX": "left",
"originY": "bottom",
"x": "0%",
"y": "100%"
},
"barcodeOptions": {
"margin": 0
},
"manipulationPermissions": {
"allowMoveHorizontal": false,
"allowMoveVertical": false,
"resizeGrips": {
"edge": false,
"corner": []
}
}
}
}
]
}
}
}
Properties
barcodeContent
The content of barcodes.
Declaration
barcodeContent?: BarcodeContentType<TBarcodeFormat, TBarcodeSubType>;
Property Value
Type | Description |
---|---|
BarcodeContentType<TBarcodeFormat, TBarcodeSubType> | The content of barcodes. |
barcodeOptions
Defines encoding options.
Declaration
barcodeOptions?: IBarcodeOptions;
Property Value
Type | Description |
---|---|
IBarcodeOptions | Defines encoding options. |
barcodePermissions
Defines permissions for barcodes.
Declaration
barcodePermissions?: IBarcodePermissionsData;
Property Value
Type | Description |
---|---|
IBarcodePermissionsData | Defines permissions for barcodes. |
color
Defines the barcode color. The default value is "rgb(0, 0, 0)"
.
Declaration
color?: string;
Property Value
Type | Description |
---|---|
string | Defines the barcode color. The default value is |