Skip to content

Commit

Permalink
Merge branch 'main' into chore/bun-mono-repo
Browse files Browse the repository at this point in the history
  • Loading branch information
hannojg authored Oct 30, 2024
2 parents 3d355e1 + db99c08 commit ef58c61
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ contact_links:
url: https://react-native-vision-camera.com/docs/guides/troubleshooting
about: Please read the Troubleshooting Guide before opening an issue.
- name: Margelo Community Discord
url: https://discord.gg/6CSHz2qAvA
url: https://margelo.com/discord
about: Discuss and chat about react-native-vision-camera or other Margelo libraries with our team or other community members. Remember to read the rules!
- name: CameraX Issue Tracker
url: https://issuetracker.google.com/issues?q=componentid:618491%20status:open#
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
bun bootstrap
```

Read the READMEs in [`android/`](android/README.md) and [`ios/`](ios/README.md) for a quick overview of the native development workflow.
Read the READMEs in [`android/`](package/android/README.md) and [`ios/`](package/ios/README.md) for a quick overview of the native development workflow.

> You can also open VisionCamera in [a quick online editor (github1s)](https://github1s.com/mrousavy/react-native-vision-camera)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,6 @@ If you're integrating VisionCamera in a production app, consider [funding this p

* 🐦 [**Follow me on Twitter**](https://twitter.com/mrousavy) for updates
* 📝 [**Check out my blog**](https://mrousavy.com/blog) for examples and experiments
* 💬 [**Join the Margelo Community Discord**](https://discord.gg/6CSHz2qAvA) for chatting about VisionCamera
* 💬 [**Join the Margelo Community Discord**](https://margelo.com/discord) for chatting about VisionCamera
* 💖 [**Sponsor me on GitHub**](https://github.com/sponsors/mrousavy) to support my work
* 🍪 [**Buy me a Ko-Fi**](https://ko-fi.com/mrousavy) to support my work
8 changes: 7 additions & 1 deletion docs/docs/guides/CODE_SCANNING.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ A Code Scanner is a separate Camera output (just like photo or video) that can d
- **Data Matrix**: Square Data Matrix codes
- **Barcode (EAN)**: EAN-13 or EAN-8 Barcodes
- **Barcode (Code)**: Code-128, Code-39 or Code-93 Barcodes
- **Barcode (other)**: Codabar, ITF-14, UPC-E or PDF-417 Barcodes
- **Barcode (other)**: Codabar, Interleaved2of5 (ITF), ITF-14, UPC-E or PDF-417 Barcodes

## Setup

Expand Down Expand Up @@ -142,4 +142,10 @@ const codeScanner = useCodeScanner({

You will need to keep this in mind and do the conversion from EAN-13 to UPC-A yourself. This can be done by removing the front `0` digit from the code to get a UPC-A code.

## Interleaved2of5 (ITF) and ITF-14

Interleaved2of5 (ITF) barcodes are supported by both, Android and iOS, where Android's SDK supports barcodes in ITF format with a minimum length of 6 characters.

ITF-14 is a sub type of interleaved2of5 which always encodes 14 characters. The ITF-14 type is only supported by iOS. If you want to have the restriction to 14 characters in Android as well, you have to handle this in your own code.

#### 🚀 Next section: [Frame Processors](frame-processors)
2 changes: 1 addition & 1 deletion docs/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ module.exports = {
items: [
{
label: 'Community Discord',
href: 'https://discord.com/invite/6CSHz2qAvA',
href: 'https://margelo.com/discord',
},
{
label: 'GitHub discussions',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ extension AVMetadataObject.ObjectType {
self = .ean8
return
case "itf":
self = .interleaved2of5
return
case "itf-14":
self = .itf14
return
case "upc-e":
Expand Down Expand Up @@ -78,8 +81,10 @@ extension AVMetadataObject.ObjectType {
return "ean-13"
case .ean8:
return "ean-8"
case .itf14:
case .interleaved2of5:
return "itf"
case .itf14:
return "itf-14"
case .upce:
return "upce"
case .qr:
Expand Down
1 change: 1 addition & 0 deletions package/src/types/CodeScanner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ export type CodeType =
| 'ean-13'
| 'ean-8'
| 'itf'
| 'itf-14'
| 'upc-e'
| 'upc-a'
| 'qr'
Expand Down

0 comments on commit ef58c61

Please sign in to comment.