mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-03-26 07:01:14 +08:00
parent
8bd906c1a7
commit
4f85110f75
@ -62,6 +62,7 @@ import {Printer} from './plugins/printer';
|
|||||||
import {Push} from './plugins/push';
|
import {Push} from './plugins/push';
|
||||||
import {SafariViewController} from './plugins/safari-view-controller';
|
import {SafariViewController} from './plugins/safari-view-controller';
|
||||||
import {Screenshot} from './plugins/screenshot';
|
import {Screenshot} from './plugins/screenshot';
|
||||||
|
import {Sim} from './plugins/sim';
|
||||||
import {SMS} from './plugins/sms';
|
import {SMS} from './plugins/sms';
|
||||||
import {SocialSharing} from './plugins/socialsharing';
|
import {SocialSharing} from './plugins/socialsharing';
|
||||||
import {SpinnerDialog} from './plugins/spinnerdialog';
|
import {SpinnerDialog} from './plugins/spinnerdialog';
|
||||||
@ -138,6 +139,7 @@ export {
|
|||||||
PinDialog,
|
PinDialog,
|
||||||
Screenshot,
|
Screenshot,
|
||||||
SocialSharing,
|
SocialSharing,
|
||||||
|
Sim,
|
||||||
Splashscreen,
|
Splashscreen,
|
||||||
SQLite,
|
SQLite,
|
||||||
StatusBar,
|
StatusBar,
|
||||||
@ -207,6 +209,7 @@ window['IonicNative'] = {
|
|||||||
PinDialog: PinDialog,
|
PinDialog: PinDialog,
|
||||||
SafariViewController: SafariViewController,
|
SafariViewController: SafariViewController,
|
||||||
Screenshot: Screenshot,
|
Screenshot: Screenshot,
|
||||||
|
Sim: Sim,
|
||||||
SMS: SMS,
|
SMS: SMS,
|
||||||
SocialSharing: SocialSharing,
|
SocialSharing: SocialSharing,
|
||||||
SpinnerDialog: SpinnerDialog,
|
SpinnerDialog: SpinnerDialog,
|
||||||
|
35
src/plugins/sim.ts
Normal file
35
src/plugins/sim.ts
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
import {Plugin, Cordova} from './plugin';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @name Sim
|
||||||
|
* @description
|
||||||
|
* Gets info from the Sim card like the carrier name, mcc, mnc and country code and other system dependent info.
|
||||||
|
*
|
||||||
|
* Requires Cordova plugin: `cordova-plugin-sim`. For more info, please see the [Cordova Sim docs](https://github.com/pbakondy/cordova-plugin-sim).
|
||||||
|
*
|
||||||
|
* @usage
|
||||||
|
* ```js
|
||||||
|
* import {Sim} from 'ionic-native';
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Sim.getSimInfo().then(
|
||||||
|
* (info) => console.log('Sim info:', info),
|
||||||
|
* (err) => console.log('Unable to get sim info:', err)
|
||||||
|
* );
|
||||||
|
* ```
|
||||||
|
*/
|
||||||
|
@Plugin({
|
||||||
|
plugin: 'cordova-plugin-sim',
|
||||||
|
pluginRef: 'plugins.sim',
|
||||||
|
repo: 'https://github.com/pbakondy/cordova-plugin-sim',
|
||||||
|
platforms: ['Android', 'iOS', 'Windows Phone']
|
||||||
|
})
|
||||||
|
export class Sim {
|
||||||
|
/**
|
||||||
|
* Returns info from the SIM card.
|
||||||
|
* @returns {Promise}
|
||||||
|
*/
|
||||||
|
@Cordova()
|
||||||
|
static getSimInfo(): Promise<any> { return; }
|
||||||
|
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user