scandit-react-native-datacapture-core 8.7.0-beta.1 → 8.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -0
- package/android/build.gradle +1 -1
- package/dist/core.js +235 -340
- package/dist/core.js.flow +50 -143
- package/dist/core.js.map +1 -1
- package/dist/dts/core.d.ts +55 -152
- package/dist/dts/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.flow +0 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/scandit-react-native-datacapture-core.podspec +1 -1
package/dist/dts/core.d.ts
CHANGED
|
@@ -2513,8 +2513,6 @@ declare class CoreProxyAdapter {
|
|
|
2513
2513
|
/**
|
|
2514
2514
|
* Severity threshold for {@link ScanditLogger}. A record is emitted when its own level is less than or equal to the configured level, and the configured level is not {@link LogLevel.Off}.
|
|
2515
2515
|
*
|
|
2516
|
-
* The level is only one of the two gates a record has to pass. The other is its {@link LogCategory}, which is checked independently — raising the level does not reveal records whose category is masked out. See {@link LogCategory}.
|
|
2517
|
-
*
|
|
2518
2516
|
* @since 8.7.0
|
|
2519
2517
|
*/
|
|
2520
2518
|
declare enum LogLevel {
|
|
@@ -2549,7 +2547,7 @@ declare enum LogLevel {
|
|
|
2549
2547
|
*/
|
|
2550
2548
|
Debug = 4,
|
|
2551
2549
|
/**
|
|
2552
|
-
* The most verbose level
|
|
2550
|
+
* The most verbose level. It adds the per-frame event callbacks, which a running scanner produces continuously.
|
|
2553
2551
|
*
|
|
2554
2552
|
* @since 8.7.0
|
|
2555
2553
|
*/
|
|
@@ -2557,18 +2555,9 @@ declare enum LogLevel {
|
|
|
2557
2555
|
}
|
|
2558
2556
|
|
|
2559
2557
|
/**
|
|
2560
|
-
* The kind of activity a record describes.
|
|
2561
|
-
*
|
|
2562
|
-
* Category and {@link LogLevel} are checked independently. A record is emitted only when its level passes the configured level **and** its category is present in the configured mask, so raising the level alone never reveals a record whose category is masked out.
|
|
2563
|
-
*
|
|
2564
|
-
* The default mask is `Bridge | Lifecycle | Listener`. {@link LogCategory.Events} is excluded from it, and must be opted into explicitly:
|
|
2565
|
-
*
|
|
2566
|
-
* ```javascript
|
|
2567
|
-
* import { ScanditLogger, LogLevel, LogCategory, DEFAULT_CATEGORIES } from 'scandit-react-native-datacapture-core';
|
|
2558
|
+
* The kind of activity a record describes.
|
|
2568
2559
|
*
|
|
2569
|
-
*
|
|
2570
|
-
* ScanditLogger.setCategories(DEFAULT_CATEGORIES | LogCategory.Events);
|
|
2571
|
-
* ```
|
|
2560
|
+
* The category is a label. It never decides whether a record is kept: {@link LogLevel} alone does. Per-frame callbacks carry {@link LogCategory.Events} and are logged at {@link LogLevel.Trace}.
|
|
2572
2561
|
*
|
|
2573
2562
|
* @since 8.7.0
|
|
2574
2563
|
*/
|
|
@@ -2592,13 +2581,12 @@ declare enum LogCategory {
|
|
|
2592
2581
|
*/
|
|
2593
2582
|
Listener = 4,
|
|
2594
2583
|
/**
|
|
2595
|
-
* Per-frame event dispatch, such as session updates and the acknowledgement each one sends back to native. These records are
|
|
2584
|
+
* Per-frame event dispatch, such as session updates and the acknowledgement each one sends back to native. These records are logged at {@link LogLevel.Trace}, because a running scanner produces them continuously.
|
|
2596
2585
|
*
|
|
2597
2586
|
* @since 8.7.0
|
|
2598
2587
|
*/
|
|
2599
2588
|
Events = 8
|
|
2600
2589
|
}
|
|
2601
|
-
declare const DEFAULT_CATEGORIES: number;
|
|
2602
2590
|
|
|
2603
2591
|
/**
|
|
2604
2592
|
* One entry in the {@link ScanditLogger} buffer. Records are produced by the SDK; you receive them from {@link ScanditLogger.getRecentLogs} and {@link ScanditLogger.subscribe}.
|
|
@@ -2637,7 +2625,7 @@ interface LogRecord {
|
|
|
2637
2625
|
*/
|
|
2638
2626
|
message: string;
|
|
2639
2627
|
/**
|
|
2640
|
-
* Additional key/value context, such as the identifiers of the mode or view involved, and the arguments of the call
|
|
2628
|
+
* Additional key/value context, such as the identifiers of the mode or view involved, and the arguments of the call. Arguments are redacted against a fixed floor.
|
|
2641
2629
|
*
|
|
2642
2630
|
* @since 8.7.0
|
|
2643
2631
|
*/
|
|
@@ -2674,7 +2662,7 @@ interface LogRecordError {
|
|
|
2674
2662
|
*/
|
|
2675
2663
|
message: string;
|
|
2676
2664
|
/**
|
|
2677
|
-
* Stack trace.
|
|
2665
|
+
* Stack trace. Never set on a record the SDK stores, because it can contain file paths from your own application binary.
|
|
2678
2666
|
*
|
|
2679
2667
|
* @since 8.7.0
|
|
2680
2668
|
*/
|
|
@@ -2684,22 +2672,25 @@ interface LogRecordError {
|
|
|
2684
2672
|
type Subscriber = (record: LogRecord) => void;
|
|
2685
2673
|
interface LogConfig {
|
|
2686
2674
|
level: LogLevel;
|
|
2687
|
-
categories: number;
|
|
2688
|
-
bufferSize: number;
|
|
2689
2675
|
}
|
|
2690
2676
|
type ConfigListener = (config: LogConfig) => void;
|
|
2677
|
+
/** Receives records queued for native storage; `installNativeLogReceiver` registers it. */
|
|
2678
|
+
interface NativeSink {
|
|
2679
|
+
onQueued(): void;
|
|
2680
|
+
flush(): Promise<void>;
|
|
2681
|
+
}
|
|
2691
2682
|
/**
|
|
2692
2683
|
* Per-method override metadata consumed by the centralized bridge
|
|
2693
2684
|
* interceptor (`instrumentBridgeCall`). Populated by code generation — each
|
|
2694
2685
|
* platform package's `generated/<Interface>LogMetadata.ts` auto-registers
|
|
2695
2686
|
* its map at module load via `ScanditLogger.registerMethodMetadata`.
|
|
2696
2687
|
*
|
|
2697
|
-
* `
|
|
2698
|
-
*
|
|
2699
|
-
*
|
|
2700
|
-
* since `Events` is excluded from the default category mask.
|
|
2688
|
+
* `level` is the level the method's success record is logged at (generated
|
|
2689
|
+
* metadata marks per-frame callbacks `Trace`); `category` labels the record.
|
|
2690
|
+
* Errors ignore both.
|
|
2701
2691
|
*/
|
|
2702
2692
|
interface MethodLogMetadata {
|
|
2693
|
+
level?: LogLevel;
|
|
2703
2694
|
category?: LogCategory;
|
|
2704
2695
|
}
|
|
2705
2696
|
declare const REDACTED_ARG_KEYS: readonly string[];
|
|
@@ -2709,25 +2700,22 @@ declare const REDACTED_ARG_METHODS: readonly string[];
|
|
|
2709
2700
|
*
|
|
2710
2701
|
* Logging is off until you raise the level. Records are written to the platform console and kept in an in-memory ring buffer you can read with {@link ScanditLogger.getRecentLogs} or observe with {@link ScanditLogger.subscribe}.
|
|
2711
2702
|
*
|
|
2712
|
-
* **Privacy.** The buffer never leaves your application process. The SDK does not transmit or upload any of it, and nothing reaches Scandit unless you send it yourself.
|
|
2703
|
+
* **Privacy.** The buffer never leaves your application process. The SDK does not transmit or upload any of it, and nothing reaches Scandit unless you send it yourself. While the level is above `Off` the SDK also stores the records in your application’s private storage, from where {@link ScanditLogger.writeLogs} exports them to a file that stays until you delete it.
|
|
2713
2704
|
*
|
|
2714
|
-
* Call arguments are recorded, but a fixed redaction floor is applied first: imagery, license keys, device identifiers and captured-document fields are replaced with `[redacted]`, and parser payloads are redacted wholesale.
|
|
2705
|
+
* Call arguments are recorded, but a fixed redaction floor is applied first: imagery, license keys, device identifiers and captured-document fields are replaced with `[redacted]`, and parser payloads are redacted wholesale. The floor cannot be changed, and error stack traces are never recorded.
|
|
2715
2706
|
*
|
|
2716
2707
|
* @since 8.7.0
|
|
2717
2708
|
*/
|
|
2718
2709
|
declare class ScanditLogger {
|
|
2719
2710
|
private static _level;
|
|
2720
|
-
private static _categories;
|
|
2721
|
-
private static _bufferSize;
|
|
2722
2711
|
private static _buffer;
|
|
2723
2712
|
private static _writeIdx;
|
|
2724
2713
|
private static _count;
|
|
2725
2714
|
private static _subscribers;
|
|
2726
2715
|
private static _configListeners;
|
|
2727
|
-
private static
|
|
2728
|
-
private static
|
|
2729
|
-
private static
|
|
2730
|
-
private static _effectiveRedactedArgKeys;
|
|
2716
|
+
private static _pendingForNative;
|
|
2717
|
+
private static _nativeSink;
|
|
2718
|
+
private static readonly _redactedArgKeys;
|
|
2731
2719
|
private static readonly _CORRELATION_WINDOW_MS;
|
|
2732
2720
|
private static _methodMetadata;
|
|
2733
2721
|
/**
|
|
@@ -2738,56 +2726,13 @@ declare class ScanditLogger {
|
|
|
2738
2726
|
static registerMethodMetadata(metadata: Record<string, MethodLogMetadata>): void;
|
|
2739
2727
|
/** Lookup the metadata for a given native method name, if any. */
|
|
2740
2728
|
static getMethodMetadata(methodName: string): MethodLogMetadata | undefined;
|
|
2741
|
-
/**
|
|
2742
|
-
* Controls whether the arguments of each call are recorded. The default is `true`, with the redaction floor applied. Pass `false` to drop arguments entirely, keeping only the method name and the identifiers of the mode or view involved.
|
|
2743
|
-
*
|
|
2744
|
-
* @since 8.7.0
|
|
2745
|
-
*/
|
|
2746
|
-
static setLogBridgeArgs(enabled: boolean): void;
|
|
2747
|
-
/**
|
|
2748
|
-
* Returns whether call arguments are being recorded.
|
|
2749
|
-
*
|
|
2750
|
-
* @since 8.7.0
|
|
2751
|
-
*/
|
|
2752
|
-
static getLogBridgeArgs(): boolean;
|
|
2753
|
-
/**
|
|
2754
|
-
* Controls whether a {@link LogRecordError.stack} is kept on records that carry an error. The default is `false`, because a stack trace can contain file paths from your own application binary.
|
|
2755
|
-
*
|
|
2756
|
-
* @since 8.7.0
|
|
2757
|
-
*/
|
|
2758
|
-
static setLogErrorStacks(enabled: boolean): void;
|
|
2759
|
-
/**
|
|
2760
|
-
* Returns whether error stack traces are being kept.
|
|
2761
|
-
*
|
|
2762
|
-
* @since 8.7.0
|
|
2763
|
-
*/
|
|
2764
|
-
static getLogErrorStacks(): boolean;
|
|
2765
|
-
/**
|
|
2766
|
-
* Adds argument keys to the redaction floor, replacing any previously added with this method. The floor itself cannot be removed from, so an empty list restores it rather than disabling redaction. Matching is recursive and also descends into JSON strings, so a key nested inside a serialized payload is caught.
|
|
2767
|
-
*
|
|
2768
|
-
* @since 8.7.0
|
|
2769
|
-
*/
|
|
2770
|
-
static setAdditionalRedactedArgKeys(keys: Iterable<string>): void;
|
|
2771
|
-
/**
|
|
2772
|
-
* Adds one key to the redaction floor, keeping the keys already added.
|
|
2773
|
-
*
|
|
2774
|
-
* @since 8.7.0
|
|
2775
|
-
*/
|
|
2776
|
-
static addRedactedArgKey(key: string): void;
|
|
2777
|
-
/**
|
|
2778
|
-
* Returns a copy of the keys currently redacted — the built-in floor plus anything added.
|
|
2779
|
-
*
|
|
2780
|
-
* @since 8.7.0
|
|
2781
|
-
*/
|
|
2782
|
-
static getRedactedArgKeys(): Set<string>;
|
|
2783
|
-
private static _recomputeRedactedArgKeys;
|
|
2784
2729
|
private static _redactValue;
|
|
2785
2730
|
private static _applyArgPolicy;
|
|
2786
2731
|
private static _isRedactedArgMethod;
|
|
2787
2732
|
private static _redactEveryValue;
|
|
2788
2733
|
private static _applyErrorPolicy;
|
|
2789
2734
|
/**
|
|
2790
|
-
* Sets the severity threshold. The default is {@link LogLevel.Off}, which disables logging entirely.
|
|
2735
|
+
* Sets the severity threshold. The default is {@link LogLevel.Off}, which disables logging entirely.
|
|
2791
2736
|
*
|
|
2792
2737
|
* @since 8.7.0
|
|
2793
2738
|
*/
|
|
@@ -2799,26 +2744,7 @@ declare class ScanditLogger {
|
|
|
2799
2744
|
*/
|
|
2800
2745
|
static getLevel(): LogLevel;
|
|
2801
2746
|
/**
|
|
2802
|
-
*
|
|
2803
|
-
*
|
|
2804
|
-
* @since 8.7.0
|
|
2805
|
-
*/
|
|
2806
|
-
static setCategories(mask: number): void;
|
|
2807
|
-
/**
|
|
2808
|
-
* Returns the current category mask.
|
|
2809
|
-
*
|
|
2810
|
-
* @since 8.7.0
|
|
2811
|
-
*/
|
|
2812
|
-
static getCategories(): number;
|
|
2813
|
-
/**
|
|
2814
|
-
* Sets how many records the ring buffer holds, at least 1. The default is 1000. Resizing discards the records currently buffered.
|
|
2815
|
-
*
|
|
2816
|
-
* @since 8.7.0
|
|
2817
|
-
*/
|
|
2818
|
-
static setBufferSize(size: number): void;
|
|
2819
|
-
/**
|
|
2820
|
-
* Subscribe to configuration changes (`setLevel` / `setCategories` /
|
|
2821
|
-
* `setBufferSize`). The callback fires immediately with the current
|
|
2747
|
+
* Subscribe to configuration changes (`setLevel`). The callback fires immediately with the current
|
|
2822
2748
|
* configuration when attached, then again on every subsequent change.
|
|
2823
2749
|
* Returns an unsubscribe function.
|
|
2824
2750
|
*
|
|
@@ -2827,12 +2753,6 @@ declare class ScanditLogger {
|
|
|
2827
2753
|
*/
|
|
2828
2754
|
static onConfigChange(cb: ConfigListener): () => void;
|
|
2829
2755
|
private static _emitConfig;
|
|
2830
|
-
/**
|
|
2831
|
-
* Returns the current buffer capacity.
|
|
2832
|
-
*
|
|
2833
|
-
* @since 8.7.0
|
|
2834
|
-
*/
|
|
2835
|
-
static getBufferSize(): number;
|
|
2836
2756
|
/**
|
|
2837
2757
|
* Returns the buffered records, oldest first. This is the call to use when attaching logs to a support ticket.
|
|
2838
2758
|
*
|
|
@@ -2861,49 +2781,56 @@ declare class ScanditLogger {
|
|
|
2861
2781
|
/**
|
|
2862
2782
|
* Discards all buffered records.
|
|
2863
2783
|
*
|
|
2784
|
+
* Also deletes the log files the SDK stored on the device while the level was above `Off`. The returned promise resolves once they are gone.
|
|
2785
|
+
*
|
|
2864
2786
|
* @since 8.7.0
|
|
2865
2787
|
*/
|
|
2866
|
-
static clear(): void
|
|
2788
|
+
static clear(): Promise<void>;
|
|
2789
|
+
/** TS-emitted records not yet handed to native storage. Internal: used by `installNativeLogReceiver`. */
|
|
2790
|
+
static pendingNativeRecordCount(): number;
|
|
2791
|
+
/** Removes and returns every record waiting for native storage. Internal. */
|
|
2792
|
+
static takePendingNativeRecords(): LogRecord[];
|
|
2793
|
+
/** Registers (or, with `undefined`, removes) the sink that moves queued records to native storage. Internal. */
|
|
2794
|
+
static setNativeSink(sink: NativeSink | undefined): void;
|
|
2795
|
+
private static _enqueueForNative;
|
|
2867
2796
|
/**
|
|
2868
|
-
* Writes the
|
|
2869
|
-
* absolute path written.
|
|
2797
|
+
* Writes the records the SDK stored on the device, oldest first, as a redacted JSON-lines file
|
|
2798
|
+
* and resolves with the absolute path written. Without `path` the file is
|
|
2799
|
+
* `scandit-debug-log.jsonl` in the application's cache directory, replaced on every call.
|
|
2870
2800
|
*
|
|
2871
2801
|
* An app can only write inside its own storage: pass a path under the app container on iOS
|
|
2872
2802
|
* (Documents, Library or the temporary directory) or under `Context.getFilesDir()` /
|
|
2873
2803
|
* `Context.getExternalFilesDir()` on Android. A relative `path` is resolved against the app's
|
|
2874
2804
|
* documents/files directory, which is the portable way to ask for a destination.
|
|
2875
2805
|
*
|
|
2876
|
-
* Rejects when
|
|
2877
|
-
*
|
|
2806
|
+
* Rejects when no record is stored (call `setLevel` first), the SDK is not initialized yet,
|
|
2807
|
+
* or the destination cannot be written.
|
|
2878
2808
|
*
|
|
2879
|
-
*
|
|
2809
|
+
* Writes the records the SDK stored on the device, oldest first, as a redacted, human-readable JSON-lines file with a one-line header in front, and returns the absolute path written. Records from the native side and from the JavaScript side are both included.
|
|
2810
|
+
*
|
|
2811
|
+
* Without `path` the file is `scandit-debug-log.jsonl` in the application’s cache directory, replaced on every call. With a `path`, missing parent directories are created and a file already there is replaced; nothing else in the destination directory is removed.
|
|
2880
2812
|
*
|
|
2881
2813
|
* An app can only write inside its own storage. Pass a path under the app container on iOS (Documents, Library or the temporary directory), or under `Context.getFilesDir()` or `Context.getExternalFilesDir()` on Android — anywhere else needs the Storage Access Framework or MediaStore on Android 10 and later. A relative `path` is resolved against the app’s documents/files directory, which is the portable way to name a destination.
|
|
2882
2814
|
*
|
|
2883
|
-
* Rejects if
|
|
2815
|
+
* Rejects if no record is stored (call {@link ScanditLogger.setLevel} first), the SDK is not initialized yet, or the destination cannot be written; the rejection carries a message saying which, except on Cordova iOS, where only the error code reaches the caller.
|
|
2884
2816
|
*
|
|
2885
2817
|
* Nothing is uploaded — the file is yours to keep, attach to a support mail to `support@scandit.com`, or hand to your own upload flow.
|
|
2886
2818
|
*
|
|
2887
2819
|
* @since 8.7.0
|
|
2888
2820
|
*/
|
|
2889
|
-
static writeLogs(path
|
|
2821
|
+
static writeLogs(path?: string): Promise<string>;
|
|
2822
|
+
/** Whether a record at `level` would be kept under the current level. */
|
|
2823
|
+
static isEnabled(level: LogLevel): boolean;
|
|
2890
2824
|
static emit(level: LogLevel, category: LogCategory, source: string, message: string, fields?: Record<string, unknown>, durationMs?: number, error?: LogRecordError): void;
|
|
2891
2825
|
/**
|
|
2892
2826
|
* Insert a `LogRecord` produced by the native side into the local buffer.
|
|
2893
2827
|
*
|
|
2894
|
-
* Applies TS-side level
|
|
2895
|
-
* `setCategories` is the single source of truth for what lands in the
|
|
2896
|
-
* unified buffer, regardless of how the native side categorized the
|
|
2897
|
-
* record. This matters because the native sides (Android/iOS) don't yet
|
|
2898
|
-
* consume the generated `logCategory` metadata — they emit per-frame
|
|
2899
|
-
* `finish*` records at `Bridge`, but the customer expects them under
|
|
2900
|
-
* `Events` (default-masked-off). The override + gate here closes that
|
|
2901
|
-
* gap until a native LogMetadata file exists.
|
|
2828
|
+
* Applies the TS-side level gate; native already applied its per-method override.
|
|
2902
2829
|
*
|
|
2903
2830
|
* Skips the platform-native console sink (the native side already wrote
|
|
2904
2831
|
* to `android.util.Log` / `os_log` / etc.).
|
|
2905
2832
|
*
|
|
2906
|
-
* Best-effort correlation: when the
|
|
2833
|
+
* Best-effort correlation: when the incoming
|
|
2907
2834
|
* record has a `durationMs`, look back for the most recent unmatched
|
|
2908
2835
|
* `ts.bridge` record with the same method name (last segment after the
|
|
2909
2836
|
* dot) within a 10-second window and attach a derived
|
|
@@ -2961,29 +2888,6 @@ declare function createNativeProxy<PROXY>(nativeCaller: NativeCaller): PROXY;
|
|
|
2961
2888
|
/** Instruments a proxy's bridge calls for logging; `NativeProxy` already does this at construction. Idempotent. */
|
|
2962
2889
|
declare function wrapNativeProxy(target: NativeProxy): void;
|
|
2963
2890
|
|
|
2964
|
-
/**
|
|
2965
|
-
* Method decorator that emits a `LogRecord` for each invocation of the
|
|
2966
|
-
* annotated method, capturing its arguments under `fields.args`.
|
|
2967
|
-
*
|
|
2968
|
-
* `ScanditLogger.emit` redacts by argument **key name** and by method name. A
|
|
2969
|
-
* positional scalar argument has neither, so it is logged as-is: a method whose
|
|
2970
|
-
* sensitive data arrives as a bare string or number needs an entry in
|
|
2971
|
-
* `REDACTED_ARG_METHODS`, or no annotation.
|
|
2972
|
-
*
|
|
2973
|
-
* `source` and `category` are **required**: they are taxonomy labels, and a
|
|
2974
|
-
* default would silently mislabel every record from a module that forgot to
|
|
2975
|
-
* pass one — e.g. a barcode class inheriting `'ts.core'` and being filed under
|
|
2976
|
-
* the wrong subsystem, which is worse than a compile error. `level` does have a
|
|
2977
|
-
* default (`LogLevel.Debug`) because it is a severity, not a label: an
|
|
2978
|
-
* unintended `Debug` is visible and harmless. Failures always emit at
|
|
2979
|
-
* `LogLevel.Error` with the error attached, regardless of `level`.
|
|
2980
|
-
*/
|
|
2981
|
-
declare function LogValues(options: {
|
|
2982
|
-
source: string;
|
|
2983
|
-
category: LogCategory;
|
|
2984
|
-
level?: LogLevel;
|
|
2985
|
-
}): MethodDecorator;
|
|
2986
|
-
|
|
2987
2891
|
|
|
2988
2892
|
|
|
2989
2893
|
/**
|
|
@@ -3002,8 +2906,8 @@ declare function LogValues(options: {
|
|
|
3002
2906
|
* Call this once per framework, immediately after the NativeProxy is bound
|
|
3003
2907
|
* (typically in `init*Proxy.ts`).
|
|
3004
2908
|
*
|
|
3005
|
-
* Returns a teardown that detaches
|
|
3006
|
-
* listener, so the receiver can be turned off again. Calling this function more
|
|
2909
|
+
* Returns a teardown that detaches the BATCH_EVENT handler, the config
|
|
2910
|
+
* listener and the `appendLogs` sink, so the receiver can be turned off again. Calling this function more
|
|
3007
2911
|
* than once on the same proxy is safe: the previous registration is disposed
|
|
3008
2912
|
* first. It is NOT safe to rely on the EventEmitter to de-duplicate — it does
|
|
3009
2913
|
* not (see `previousTeardowns`).
|
|
@@ -3052,13 +2956,10 @@ declare function armNativeLogReceiver(proxy: BaseProxy, onInstalled?: () => void
|
|
|
3052
2956
|
declare function subscribeNativeLogChannel(proxy: BaseProxy): Promise<void>;
|
|
3053
2957
|
|
|
3054
2958
|
/**
|
|
3055
|
-
* Per-method `LogRecord` category overrides for the CoreProxy
|
|
3056
|
-
* bridge surface. Consumed by the centralized `ScanditLogger` interceptor
|
|
3057
|
-
*
|
|
3058
|
-
*
|
|
3059
|
-
* default category mask. Level and category gate independently: those
|
|
3060
|
-
* records are emitted at `Debug` and stay hidden until the category is
|
|
3061
|
-
* opted into, so raising the level does not reveal them.
|
|
2959
|
+
* Per-method `LogRecord` level and category overrides for the CoreProxy
|
|
2960
|
+
* bridge surface. Consumed by the centralized `ScanditLogger` interceptor:
|
|
2961
|
+
* per-frame / per-scan callbacks log at `Trace` under their category label, so
|
|
2962
|
+
* they only show once the level is raised to `Trace`.
|
|
3062
2963
|
*
|
|
3063
2964
|
* Auto-registered as a side effect of importing this module via the
|
|
3064
2965
|
* generated `index.ts` barrel — no customer wiring required.
|
|
@@ -6245,6 +6146,8 @@ declare abstract class ModeBase<C extends BaseController<unknown>, L extends Bas
|
|
|
6245
6146
|
protected withController<T>(action: (controller: C) => Promise<T>, fallback: T): Promise<T>;
|
|
6246
6147
|
protected withListenerController(action: (controller: L) => Promise<void>): Promise<void>;
|
|
6247
6148
|
protected withListenerController<T>(action: (controller: L) => Promise<T>, fallback: T): Promise<T>;
|
|
6149
|
+
private logHeld;
|
|
6150
|
+
private logModeError;
|
|
6248
6151
|
get context(): DataCaptureContext | null;
|
|
6249
6152
|
constructor();
|
|
6250
6153
|
protected abstract createController(): C;
|
|
@@ -8398,6 +8301,6 @@ declare enum ClusteringMode {
|
|
|
8398
8301
|
AutoWithManualCorrection = "autoWithManualCorrection"
|
|
8399
8302
|
}
|
|
8400
8303
|
|
|
8401
|
-
export { AimerViewfinder, BaseController, CORE_PROXY_LOG_METADATA, CORE_PROXY_TYPE_NAMES, CameraController, CameraOwnershipHelper, CameraOwnershipManager, CameraSettings, CameraSwitchControl, CameraSwitchControlController, ClusteringMode, ColorFillOverlay, ControlImage, CoreProxyAdapter,
|
|
8304
|
+
export { AimerViewfinder, BaseController, CORE_PROXY_LOG_METADATA, CORE_PROXY_TYPE_NAMES, CameraController, CameraOwnershipHelper, CameraOwnershipManager, CameraSettings, CameraSwitchControl, CameraSwitchControlController, ClusteringMode, ColorFillOverlay, ControlImage, CoreProxyAdapter, DataCaptureContextEvents, DataCaptureContextSettings, DataCaptureViewEvents, DefaultSerializeable, Direction, EventDataParser, Expiration, FactoryMaker, Feedback, FocusGestureListenerEvents, FontFamily, FrameDataController, FrameDataSettings, FrameDataSettingsBuilder, FrameSourceListenerEvents, HTMLElementState, HtmlElementPosition, HtmlElementSize, ImageBuffer, ImageFrameSource, LaserlineViewfinder, LicenseInfo, ListenerRegistry, LogCategory, LogLevel, MacroModeListenerEvents, MeasureUnit, ModeBase, NoViewfinder, NoneLocationSelection, Observable, PinchToZoom, PrivateFocusGestureDeserializer, PrivateFrameData, PrivateZoomGestureDeserializer, REDACTED_ARG_KEYS, REDACTED_ARG_METHODS, RadiusLocationSelection, RectWithUnit, RectangularLocationSelection, RectangularViewfinder, SKIP, ScanIntention$1 as ScanIntention, ScanditIcon, ScanditIconBuilder, ScanditIconShape, ScanditIconType, ScanditLogger, SelectionMode$1 as SelectionMode, SequenceFrameSource, SizeWithAspect, SizeWithUnit, SizingMode, Sound, SwipeToZoom, TapToFocus, TextAlignment, TorchListenerEvents, TorchState, TorchSwitchControl, VIEW_CREATION_PRE_BEGIN_TIMEOUT_MS, VIEW_CREATION_TIMEOUT_MS, Vibration, VibrationType, ViewCreationGate, WaveFormVibration, ZoomGestureListenerEvents, ZoomListenerEvents, ZoomSwitchControl, armNativeLogReceiver, buildStaticCoreDefaultsJson, createNativeProxy, ensureCoreDefaults, generateIdentifier, getCoreDefaults, ignoreFromSerialization, ignoreFromSerializationIfNull, installNativeLogReceiver, loadCoreDefaults, markSingleInstancePerView, nameForSerialization, registerCoreProxies, registerProxies, resetCameraControllerPayloadParserWarnings, resetDataCaptureViewPayloadParserWarnings, serializationDefault, setCoreDefaultsLoader, singleInstanceOverlayName, subscribeNativeLogChannel, wrapNativeProxy };
|
|
8402
8305
|
export type { BaseProxy, BrushJSON, CameraControllerListener, CameraOwner, CameraSettingsJSON, ColorJSON, Control$1 as Control, CoreDefaults, CoreNativeCallerProvider, CoreProxy, CoreProxyType, DataCaptureComponent, DataCaptureContextCreationOptions, DataCaptureContextListener, DataCaptureContextProxy, DataCaptureMode, DataCaptureOverlay, DataCaptureView$1 as DataCaptureView, DataCaptureViewControllerListener, DataCaptureViewListener, DataCaptureViewProxy, DidChangeSizeEventPayload, DidChangeStateEventPayload, DidChangeStatusEventPayload, EventPayload, FeedbackJSON, FocusGesture$1 as FocusGesture, FocusGestureJSON, FocusGestureListener, FrameData, FrameDataJSON, FrameSource$1 as FrameSource, FrameSourceDidChangeStateEventPayload, FrameSourceListener, ImageBufferJSON, LocationSelection, LogRecord, LogRecordError, MacroModeListener, MarginsWithUnitJSON, MethodLogMetadata, NativeCallResult, NativeCaller, NativeCallerProvider, NativeCameraActivatedHandler, NumberWithUnitJSON, PointJSON, PointWithUnitJSON, PrivateBrush, PrivateCamera, PrivateCameraSettings, PrivateColor, PrivateContextStatus, PrivateControl, PrivateDataCaptureComponent, PrivateDataCaptureContext, PrivateDataCaptureMode, PrivateDataCaptureOverlay, PrivateFeedback, PrivateImageBuffer, PrivateMarginsWithUnit, PrivateNumberWithUnit, PrivatePinchToZoom, PrivatePoint, PrivatePointWithUnit, PrivateQuadrilateral, PrivateRadiusLocationSelection, PrivateRectangularLocationSelection, PrivateRectangularViewfinderAnimation, PrivateScanditIcon, PrivateSize, PrivateSizeWithUnitAndAspect, PrivateSound, PrivateSwipeToZoom, PrivateTapToFocus, PrivateVibration, PropertyChangeListener, ProxyEvent, QuadrilateralJSON, RadiusLocationSelectionJSON, RectangularLocationSelectionJSON, RectangularViewfinderAnimationJSON, ScanditIconJSON, Serializeable, SizeJSON, SizeWithUnitAndAspectJSON, SoundJSON, StringSerializeable, TorchListener, VibrationJSON, ViewCreationAttempt, Viewfinder, WithControllerDispatch, ZoomGesture$1 as ZoomGesture, ZoomGestureJSON, ZoomGestureListener, ZoomListener };
|
|
8403
8306
|
export { Anchor$1 as Anchor, BaseDataCaptureView, Brush$1 as Brush, Camera, CameraPosition, Color$1 as Color, ContextStatus, DataCaptureContext, DataCaptureViewController, FocusGestureStrategy, FocusRange, FrameSourceState, LogoStyle$1 as LogoStyle, MacroMode, MarginsWithUnit$1 as MarginsWithUnit, NativeProxy, NumberWithUnit, OpenSourceSoftwareLicenseInfo, Orientation, Point, PointWithUnit, Quadrilateral$1 as Quadrilateral, Rect$1 as Rect, RectangularViewfinderAnimation$1 as RectangularViewfinderAnimation, RectangularViewfinderLineStyle, RectangularViewfinderStyle, Size, SizeWithUnitAndAspect, VideoResolution, ZoomSwitchOrientation };
|
package/dist/dts/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Size, Orientation, BaseDataCaptureView, MarginsWithUnit, PointWithUnit, LogoStyle, Anchor, FocusGesture, ZoomGesture, Point, Quadrilateral, Control, Serializeable, DataCaptureContext, DataCaptureContextSettings, DataCaptureContextCreationOptions, FrameSourceState, TorchState, CameraPosition, CameraSettings, DataCaptureOverlay as DataCaptureOverlay$1, NativeCaller } from './core';
|
|
2
|
-
export { AimerViewfinder, Anchor, Brush, Camera, CameraPosition, CameraSettings, CameraSwitchControl, ClusteringMode, Color, ColorFillOverlay, ContextStatus, Control,
|
|
2
|
+
export { AimerViewfinder, Anchor, Brush, Camera, CameraPosition, CameraSettings, CameraSwitchControl, ClusteringMode, Color, ColorFillOverlay, ContextStatus, Control, DataCaptureComponent, DataCaptureContext, DataCaptureContextCreationOptions, DataCaptureContextListener, DataCaptureContextSettings, DataCaptureMode, DataCaptureOverlay, Direction, Expiration, Feedback, FocusGesture, FocusGestureListener, FocusGestureStrategy, FocusRange, FontFamily, FrameData, FrameDataSettings, FrameDataSettingsBuilder, FrameSource, FrameSourceListener, FrameSourceState, ImageBuffer, ImageFrameSource, LaserlineViewfinder, LicenseInfo, LocationSelection, LogCategory, LogLevel, LogRecord, LogRecordError, LogoStyle, MacroMode, MacroModeListener, MarginsWithUnit, MeasureUnit, NoViewfinder, NoneLocationSelection, NumberWithUnit, OpenSourceSoftwareLicenseInfo, Orientation, PinchToZoom, Point, PointWithUnit, Quadrilateral, RadiusLocationSelection, Rect, RectWithUnit, RectangularLocationSelection, RectangularViewfinder, RectangularViewfinderAnimation, RectangularViewfinderLineStyle, RectangularViewfinderStyle, ScanIntention, ScanditIcon, ScanditIconBuilder, ScanditIconShape, ScanditIconType, ScanditLogger, SelectionMode, SequenceFrameSource, Size, SizeWithAspect, SizeWithUnit, SizeWithUnitAndAspect, SizingMode, Sound, SwipeToZoom, TapToFocus, TextAlignment, TorchListener, TorchState, TorchSwitchControl, Vibration, VibrationType, VideoResolution, Viewfinder, WaveFormVibration, ZoomGesture, ZoomGestureListener, ZoomListener, ZoomSwitchControl, ZoomSwitchOrientation } from './core';
|
|
3
3
|
import React$1, { DependencyList, MutableRefObject } from 'react';
|
|
4
4
|
import { StyleProp, ViewStyle, LayoutChangeEvent, NativeModule } from 'react-native';
|
|
5
5
|
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CORE_PROXY_TYPE_NAMES, registerCoreProxies, FactoryMaker, loadCoreDefaults, setCoreDefaultsLoader, buildStaticCoreDefaultsJson, getCoreDefaults, BaseDataCaptureView, DataCaptureContext, TorchState, CameraPosition, Camera, FrameSourceState } from './core.js';
|
|
2
|
-
export { AimerViewfinder, Anchor, Brush, CameraSettings, CameraSwitchControl, ClusteringMode, Color, ColorFillOverlay, ContextStatus,
|
|
2
|
+
export { AimerViewfinder, Anchor, Brush, CameraSettings, CameraSwitchControl, ClusteringMode, Color, ColorFillOverlay, ContextStatus, DataCaptureContextSettings, Direction, Expiration, Feedback, FocusGestureStrategy, FocusRange, FontFamily, FrameDataSettings, FrameDataSettingsBuilder, ImageBuffer, ImageFrameSource, LaserlineViewfinder, LicenseInfo, LogCategory, LogLevel, LogoStyle, MacroMode, MarginsWithUnit, MeasureUnit, NoViewfinder, NoneLocationSelection, NumberWithUnit, OpenSourceSoftwareLicenseInfo, Orientation, PinchToZoom, Point, PointWithUnit, Quadrilateral, RadiusLocationSelection, Rect, RectWithUnit, RectangularLocationSelection, RectangularViewfinder, RectangularViewfinderAnimation, RectangularViewfinderLineStyle, RectangularViewfinderStyle, ScanIntention, ScanditIcon, ScanditIconBuilder, ScanditIconShape, ScanditIconType, ScanditLogger, SelectionMode, SequenceFrameSource, Size, SizeWithAspect, SizeWithUnit, SizeWithUnitAndAspect, SizingMode, Sound, SwipeToZoom, TapToFocus, TextAlignment, TorchSwitchControl, Vibration, VibrationType, VideoResolution, WaveFormVibration, ZoomSwitchControl, ZoomSwitchOrientation } from './core.js';
|
|
3
3
|
import { NativeEventEmitter, Platform, NativeModules, TurboModuleRegistry, findNodeHandle, requireNativeComponent, AppState, PermissionsAndroid } from 'react-native';
|
|
4
4
|
import React, { useState, useEffect, useCallback, useMemo, useRef, createContext, useContext, useLayoutEffect } from 'react';
|
|
5
5
|
|
|
@@ -182,7 +182,7 @@ setCoreDefaultsLoader(initCoreDefaults);
|
|
|
182
182
|
|
|
183
183
|
class DataCaptureVersion {
|
|
184
184
|
static get pluginVersion() {
|
|
185
|
-
return '8.7.0
|
|
185
|
+
return '8.7.0';
|
|
186
186
|
}
|
|
187
187
|
/**
|
|
188
188
|
* Version of the native SDK the plugin is running against.
|