mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-08-04 00:00:08 +08:00
Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b7591f6c72 |
@@ -9,6 +9,10 @@ export interface AnylineConfig {
|
||||
* @name Anyline
|
||||
* @description
|
||||
* Anyline provides an easy-to-use SDK for applications to enable Optical Character Recognition (OCR) on mobile devices.
|
||||
*
|
||||
* @deprecated since v56.0.0. This legacy `AnylineSDK` API remains functional but upstream recommends migrating to the
|
||||
* new `AnylineInfinityPlugin` API (exposed natively as `window.AnylineInfinity`), which is not covered by this wrapper.
|
||||
* See https://documentation.anyline.com/cordova-plugin-component/latest/infinity-plugins/upgrade-guide.html
|
||||
* @usage
|
||||
* ```typescript
|
||||
* import { Anyline } from '@awesome-cordova-plugins/anyline/ngx';
|
||||
@@ -59,4 +63,17 @@ export class Anyline extends AwesomeCordovaNativePlugin {
|
||||
scan(config: AnylineConfig): Promise<any> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets platform-specific scanning options, such as selecting the camera API on Android
|
||||
* (CameraX vs Camera1) or managing camera permission handling. Must be called before `scan`.
|
||||
*
|
||||
* @param scanStartPlatformOptionsString {string} A JSON-stringified object of platform-specific attributes,
|
||||
* e.g. `JSON.stringify({ androidScanViewAttributes: { useCameraX: false } })`
|
||||
* @returns {Promise<any>} Returns a promise that resolves when the options have been set
|
||||
*/
|
||||
@Cordova()
|
||||
setDefaultScanStartPlatformOptions(scanStartPlatformOptionsString: string): Promise<any> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,6 @@ export enum Connection {
|
||||
CELL_2G = '2g',
|
||||
CELL_3G = '3g',
|
||||
CELL_4G = '4g',
|
||||
CELL_5G = '5g',
|
||||
CELL = 'cellular',
|
||||
NONE = 'none',
|
||||
}
|
||||
@@ -63,7 +62,7 @@ export enum Connection {
|
||||
*
|
||||
* ```
|
||||
* @advanced
|
||||
* The `type` property will return one of the following connection types: `unknown`, `ethernet`, `wifi`, `2g`, `3g`, `4g`, `5g`, `cellular`, `none`
|
||||
* The `type` property will return one of the following connection types: `unknown`, `ethernet`, `wifi`, `2g`, `3g`, `4g`, `cellular`, `none`
|
||||
*/
|
||||
@Plugin({
|
||||
pluginName: 'Network',
|
||||
@@ -84,7 +83,6 @@ export class Network extends AwesomeCordovaNativePlugin {
|
||||
CELL_2G: '2g',
|
||||
CELL_3G: '3g',
|
||||
CELL_4G: '4g',
|
||||
CELL_5G: '5g',
|
||||
CELL: 'cellular',
|
||||
NONE: 'none',
|
||||
};
|
||||
@@ -100,7 +98,6 @@ export class Network extends AwesomeCordovaNativePlugin {
|
||||
* Downlink Max Speed
|
||||
*
|
||||
* @returns {string}
|
||||
* @deprecated Not part of the upstream cordova-plugin-network-information API (verified against v3.1.0 types/index.d.ts and README). Retained for backwards compatibility only.
|
||||
*/
|
||||
@CordovaProperty() downlinkMax: string;
|
||||
|
||||
@@ -112,7 +109,7 @@ export class Network extends AwesomeCordovaNativePlugin {
|
||||
@CordovaCheck()
|
||||
onChange(): Observable<'connected' | 'disconnected'> {
|
||||
return merge(
|
||||
this.onConnect().pipe(mapTo('connected')) as Observable<'connected'>,
|
||||
this.onConnect().pipe(mapTo('connected')),
|
||||
this.onDisconnect().pipe(mapTo('disconnected')) as Observable<'disconnected'>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user