Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add barcode raw value #39

Open
3 of 8 tasks
Iuriy-Budnikov opened this issue Oct 3, 2023 · 0 comments
Open
3 of 8 tasks

Add barcode raw value #39

Iuriy-Budnikov opened this issue Oct 3, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@Iuriy-Budnikov
Copy link

What happened?

BarcodeScanning.m

[result addObject:@{
  @"value": barcode.displayValue,
  @"format": format,
  @"rawValue": barcode.rawValue
 }];

BarcodeScanningModule.java

public void onSuccess(List<Barcode> barcodes) {
  WritableArray result = Arguments.createArray();
  for (Barcode barcode : barcodes) {
      WritableMap map = Arguments.createMap();
      map.putString("value", barcode.getDisplayValue());
      map.putDouble("format", barcode.getFormat());
      map.putString("rawValue", barcode.getRawValue());
      result.pushMap(map);
  }
  promise.resolve(result);
}

TS

export interface Barcode {
  format: BarcodeFormat;
  value: string;
  rawValue: string;
}

Could you please add a getRawValue.
Thanks

Version

@react-native-ml-kit/barcode-scanning: version@react-native-ml-kit/face-detection: version@react-native-ml-kit/identify-languages: version@react-native-ml-kit/image-labeling: version@react-native-ml-kit/text-recognition: version@react-native-ml-kit/translate-text: version

Which ML Kit packages do you use?

  • @react-native-ml-kit/barcode-scanning
  • @react-native-ml-kit/face-detection
  • @react-native-ml-kit/identify-languages
  • @react-native-ml-kit/image-labeling
  • @react-native-ml-kit/text-recognition
  • @react-native-ml-kit/translate-text

What platforms are you seeing this issue on?

  • Android
  • iOS

System Information

Check prev message

Steps to Reproduce

Check prev message

@Iuriy-Budnikov Iuriy-Budnikov added the bug Something isn't working label Oct 3, 2023
@a7medev a7medev self-assigned this Oct 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants