mirror of
https://github.com/nimiq/qr-scanner.git
synced 2026-07-28 04:06:51 +00:00
Disable native BarcodeDetector on M1/M2 Macs with Ventura
On Macs with an M1/M2 processor and macOS Ventura (macOS version 13), the BarcodeDetector is broken in Chromium based browsers, regardless of the version. For that constellation, the BarcodeDetector does not error but does not detect QR codes. Macs without an M1/M2 or before Ventura are fine. See https://bugs.chromium.org/p/chromium/issues/detail?id=1382442. Fixes #209
This commit is contained in:
Vendored
+15
@@ -122,4 +122,19 @@ declare class BarcodeDetector {
|
||||
cornerPoints: QrScanner.Point[];
|
||||
}>>;
|
||||
}
|
||||
declare global {
|
||||
interface Navigator {
|
||||
readonly userAgentData?: {
|
||||
readonly platform: string;
|
||||
readonly brands: Array<{
|
||||
readonly brand: string;
|
||||
readonly version: string;
|
||||
}>;
|
||||
getHighEntropyValues(hints: string[]): Promise<{
|
||||
readonly architecture?: string;
|
||||
readonly platformVersion?: string;
|
||||
}>;
|
||||
};
|
||||
}
|
||||
}
|
||||
export default QrScanner;
|
||||
|
||||
Reference in New Issue
Block a user