Skip to content

Commit

Permalink
Added taptic plugin. #571
Browse files Browse the repository at this point in the history
  • Loading branch information
mlynch committed Sep 25, 2016
1 parent 3266d21 commit d1c18b0
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ import { Splashscreen } from './plugins/splashscreen';
import { SQLite } from './plugins/sqlite';
import { StatusBar } from './plugins/statusbar';
import { StreamingMedia } from './plugins/streaming-media';
import { Taptic } from './plugins/taptic';
import { ThreeDeeTouch } from './plugins/3dtouch';
import { Toast } from './plugins/toast';
import { TouchID } from './plugins/touchid';
Expand Down Expand Up @@ -142,6 +143,7 @@ export * from './plugins/safari-view-controller';
export * from './plugins/sms';
export * from './plugins/spinnerdialog';
export * from './plugins/streaming-media';
export * from './plugins/taptic';
export * from './plugins/toast';
export * from './plugins/twitter-connect';
export * from './plugins/video-editor';
Expand Down Expand Up @@ -203,6 +205,7 @@ Sim,
Splashscreen,
SQLite,
StatusBar,
Taptic,
TouchID,
Transfer,
TextToSpeech,
Expand Down Expand Up @@ -305,6 +308,7 @@ window['IonicNative'] = {
SQLite,
StatusBar,
StreamingMedia,
Taptic,
ThreeDeeTouch,
Toast,
TouchID,
Expand Down
29 changes: 29 additions & 0 deletions src/plugins/taptic.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import { Cordova, Plugin } from './plugin';

@Plugin({
plugin: 'cordova-plugin-taptic-engine',
pluginRef: 'TapticEngine',
repo: 'https://github.com/EddyVerbruggen/cordova-plugin-taptic-engine',
platforms: ['iOS']
})
export class Taptic {
/**
*
*/
@Cordova()
static selection(): void { return; }

/**
* Use this to indicate success/failure/warning to the user.
* options should be of the type { type: 'success' } (or 'warning'/'error')
*/
@Cordova()
static notification(options: { type: string }): void { return; }

/**
* Use this to indicate success/failure/warning to the user.
* options should be of the type { style: 'light' } (or 'medium'/'heavy')
*/
@Cordova()
static impact(options: { style: string }): void { return; }
}

0 comments on commit d1c18b0

Please sign in to comment.