Barcode Generator
Please note that this content is under development and is not ready for implementation. This status message will be updated as content development progresses.
Description
The BarcodeGenerator component generates and displays barcodes based on the provided data. It can handle both single and multiple barcode generation, making it versatile for various use cases within the Mock App system.
The component uses its data
and dataPath
props to extract the necessary information for barcode generation. The resulting barcodes are displayed on the screen once generated.
The BarcodeGenerator is typically used as follows:
-
Passing the credential object:
- The
data
prop receives the entire credential object generated by the previous step in the process. - This prop is usually not specified directly in the component configuration, as it's automatically populated with the credential generate in the previous step.
- The
-
Specifying the data path:
- Use the
dataPath
prop to specify a JSON pointer path to extract barcode data from the credential object.
- Use the
Example
{
"name": "BarcodeGenerator",
"type": "Result",
"props": {
"dataPath": "/credentialSubject/outputEPCList/index/name"
}
}
This example specifies that for each item in the outputEPCList
, the name
field should be used to generate a barcode. The actual credential object is not shown here, as it's automatically provided to the component by the previous step.
Definitions
Property | Required | Description | Type |
---|---|---|---|
name | Yes | The name of the component (should be "BarcodeGenerator") | String |
type | Yes | The type of the component (should be "Result") | ComponentType |
props | Yes | The properties for the BarcodeGenerator | Props |
Props
Property | Required | Description | Type |
---|---|---|---|
data | No | The credential object containing the data for barcode generation (usually automatically provided) | Object |
dataPath | Yes | A JSON pointer path to extract barcode data from the credential object | String |