├── native-src ├── ios │ ├── .gitignore │ ├── .gitattributes │ ├── PushPlugin │ │ ├── PushManager.h │ │ ├── PushPlugin.h │ │ ├── Info.plist │ │ ├── Push.h │ │ ├── PushManager.m │ │ └── Push.m │ ├── PushPlugin.xcodeproj │ │ ├── xcuserdata │ │ │ └── backendservtestuser.xcuserdatad │ │ │ │ ├── xcdebugger │ │ │ │ └── Breakpoints_v2.xcbkptlist │ │ │ │ └── xcschemes │ │ │ │ ├── xcschememanagement.plist │ │ │ │ ├── PushPluginLibrary.xcscheme │ │ │ │ └── PushPlugin.xcscheme │ │ └── project.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ ├── xcuserdata │ │ │ └── backendservtestuser.xcuserdatad │ │ │ │ └── UserInterfaceState.xcuserstate │ │ │ └── xcshareddata │ │ │ └── PushPlugin.xccheckout │ ├── PushPluginTests │ │ ├── Info.plist │ │ └── PushPluginTests.m │ └── README.md └── android │ ├── .gitattributes │ ├── app │ ├── .gitignore │ ├── src │ │ └── main │ │ │ ├── res │ │ │ └── values │ │ │ │ └── strings.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── telerik │ │ │ │ └── pushplugin │ │ │ │ ├── InstanceIdListenerService.java │ │ │ │ ├── PushPluginListener.java │ │ │ │ ├── UnregisterTokenThread.java │ │ │ │ ├── ObtainTokenThread.java │ │ │ │ ├── PushLifecycleCallbacks.java │ │ │ │ ├── JsonObjectExtended.java │ │ │ │ └── PushPlugin.java │ │ │ └── AndroidManifest.xml │ ├── proguard-rules.pro │ ├── build.gradle │ └── app.iml │ ├── settings.gradle │ ├── .gitignore │ ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties │ ├── build.gradle │ ├── gradle.properties │ ├── android.iml │ ├── pushplugin.iml │ ├── README.md │ ├── gradlew.bat │ └── gradlew ├── src ├── platforms │ ├── android │ │ ├── pushplugin.aar │ │ └── include.gradle │ └── ios │ │ ├── PushPlugin.framework │ │ ├── Info.plist │ │ ├── PushPlugin │ │ ├── Headers │ │ │ ├── PushManager.h │ │ │ ├── PushPlugin.h │ │ │ └── Push.h │ │ ├── Modules │ │ │ └── module.modulemap │ │ └── _CodeSignature │ │ │ └── CodeResources │ │ ├── app.entitlements │ │ └── Info.plist ├── .npmignore ├── scripts │ ├── preuninstall.js │ └── postinstall.js ├── hooks │ ├── before-prepare.js │ └── utils.js ├── tsconfig.json ├── package.json ├── index.d.ts ├── push-plugin.android.ts └── push-plugin.ios.ts ├── demo ├── app │ ├── App_Resources │ │ ├── iOS │ │ │ ├── Assets.xcassets │ │ │ │ ├── Contents.json │ │ │ │ ├── AppIcon.appiconset │ │ │ │ │ ├── icon-29.png │ │ │ │ │ ├── icon-40.png │ │ │ │ │ ├── icon-76.png │ │ │ │ │ ├── icon-1024.png │ │ │ │ │ ├── icon-29@2x.png │ │ │ │ │ ├── icon-29@3x.png │ │ │ │ │ ├── icon-40@2x.png │ │ │ │ │ ├── icon-40@3x.png │ │ │ │ │ ├── icon-60@2x.png │ │ │ │ │ ├── icon-60@3x.png │ │ │ │ │ ├── icon-76@2x.png │ │ │ │ │ ├── icon-83.5@2x.png │ │ │ │ │ └── Contents.json │ │ │ │ ├── LaunchImage.launchimage │ │ │ │ │ ├── Default.png │ │ │ │ │ ├── Default@2x.png │ │ │ │ │ ├── Default-568h@2x.png │ │ │ │ │ ├── Default-667h@2x.png │ │ │ │ │ ├── Default-736h@3x.png │ │ │ │ │ ├── Default-Landscape.png │ │ │ │ │ ├── Default-Portrait.png │ │ │ │ │ ├── Default-Landscape@2x.png │ │ │ │ │ ├── Default-Landscape@3x.png │ │ │ │ │ ├── Default-Portrait@2x.png │ │ │ │ │ └── Contents.json │ │ │ │ ├── LaunchScreen.Center.imageset │ │ │ │ │ ├── LaunchScreen-Center.png │ │ │ │ │ ├── LaunchScreen-Center@2x.png │ │ │ │ │ └── Contents.json │ │ │ │ └── LaunchScreen.AspectFill.imageset │ │ │ │ │ ├── LaunchScreen-AspectFill.png │ │ │ │ │ ├── LaunchScreen-AspectFill@2x.png │ │ │ │ │ └── Contents.json │ │ │ ├── build.xcconfig │ │ │ ├── Info.plist │ │ │ └── LaunchScreen.storyboard │ │ └── Android │ │ │ ├── drawable-hdpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── drawable-ldpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── drawable-mdpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── drawable-xhdpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── values-v21 │ │ │ ├── colors.xml │ │ │ └── styles.xml │ │ │ ├── drawable-xxhdpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── drawable-xxxhdpi │ │ │ ├── icon.png │ │ │ ├── logo.png │ │ │ └── background.png │ │ │ ├── values │ │ │ ├── colors.xml │ │ │ └── styles.xml │ │ │ ├── drawable-nodpi │ │ │ └── splash_screen.xml │ │ │ ├── app.gradle │ │ │ └── AndroidManifest.xml │ ├── package.json │ ├── app.css │ ├── README.md │ ├── main-page.ts │ ├── app.ts │ ├── main-page.xml │ └── main-view-model.ts ├── README.md ├── tsconfig.json └── package.json ├── publish ├── publish.sh ├── package.json ├── build-android.sh ├── pack.sh └── build-ios.sh ├── .gitignore ├── .github ├── pull_request_template.md └── issue_template.md ├── tslint.json ├── .travis.yml ├── CONTRIBUTING.md ├── DevelopmentWorkflow.md ├── MIGRATE-TO-FIREBASE.md └── LICENSE /native-src/ios/.gitignore: -------------------------------------------------------------------------------- 1 | build/ -------------------------------------------------------------------------------- /native-src/ios/.gitattributes: -------------------------------------------------------------------------------- 1 | * -crlf -------------------------------------------------------------------------------- /native-src/android/.gitattributes: -------------------------------------------------------------------------------- 1 | * -crlf -------------------------------------------------------------------------------- /native-src/android/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /native-src/android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /native-src/android/.gitignore: -------------------------------------------------------------------------------- 1 | out/ 2 | .idea/ 3 | .gradle/ 4 | local.properties 5 | build/ -------------------------------------------------------------------------------- /src/platforms/android/pushplugin.aar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/src/platforms/android/pushplugin.aar -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /native-src/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | pushplugin 3 | 4 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin/PushManager.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "Push.h" 3 | 4 | @interface PushManager : NSObject 5 | @end 6 | -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/Info.plist: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/src/platforms/ios/PushPlugin.framework/Info.plist -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/PushPlugin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/src/platforms/ios/PushPlugin.framework/PushPlugin -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-hdpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-hdpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-hdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-hdpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-ldpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-ldpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-ldpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-ldpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-mdpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-mdpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-mdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-mdpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xhdpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xhdpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xhdpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/values-v21/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3d5afe 4 | -------------------------------------------------------------------------------- /native-src/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/native-src/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxhdpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxhdpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxhdpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxxhdpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxxhdpi/icon.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxxhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxxhdpi/logo.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-hdpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-hdpi/background.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-ldpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-ldpi/background.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-mdpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-mdpi/background.png -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/Headers/PushManager.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "Push.h" 3 | 4 | @interface PushManager : NSObject 5 | @end 6 | -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xhdpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xhdpi/background.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxhdpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxhdpi/background.png -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-xxxhdpi/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/Android/drawable-xxxhdpi/background.png -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/Modules/module.modulemap: -------------------------------------------------------------------------------- 1 | framework module PushPlugin { 2 | umbrella header "PushPlugin.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-76.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-1024.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-29@3x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-40@3x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-60@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-60@3x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-76@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/AppIcon.appiconset/icon-83.5@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default.png -------------------------------------------------------------------------------- /src/.npmignore: -------------------------------------------------------------------------------- 1 | # Exclude the native source code. The native libraries are included in the push-plugin as compiled resources (i.e. jar & framework) 2 | native-src/ 3 | *.map 4 | *.ts 5 | !*.d.ts 6 | tsconfig.json -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-568h@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-667h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-667h@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-736h@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-736h@3x.png -------------------------------------------------------------------------------- /native-src/ios/PushPlugin.xcodeproj/xcuserdata/backendservtestuser.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Portrait.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Portrait.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Landscape@3x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Portrait@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchImage.launchimage/Default-Portrait@2x.png -------------------------------------------------------------------------------- /demo/app/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "android": { 3 | "v8Flags": "--expose_gc", 4 | "requireModules": ["nativescript-push-notifications"] 5 | }, 6 | "main": "app.js", 7 | "name": "tns-template-hello-world-ts", 8 | "version": "3.3.0" 9 | } -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.Center.imageset/LaunchScreen-Center.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.Center.imageset/LaunchScreen-Center.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.Center.imageset/LaunchScreen-Center@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.Center.imageset/LaunchScreen-Center@2x.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.AspectFill.imageset/LaunchScreen-AspectFill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.AspectFill.imageset/LaunchScreen-AspectFill.png -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.AspectFill.imageset/LaunchScreen-AspectFill@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.AspectFill.imageset/LaunchScreen-AspectFill@2x.png -------------------------------------------------------------------------------- /native-src/ios/PushPlugin.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /publish/publish.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PACK_DIR="$CURRENT_DIR/package" 5 | 6 | publish() { 7 | cd $PACK_DIR 8 | echo 'Publishing to npm...' 9 | npm publish *.tgz 10 | } 11 | 12 | ./pack.sh && publish -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #F5F5F5 4 | #757575 5 | #33B5E5 6 | #272734 7 | -------------------------------------------------------------------------------- /src/platforms/ios/app.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | aps-environment 6 | development 7 | 8 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin.xcodeproj/project.xcworkspace/xcuserdata/backendservtestuser.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NativeScript/push-plugin/HEAD/native-src/ios/PushPlugin.xcodeproj/project.xcworkspace/xcuserdata/backendservtestuser.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /native-src/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Dec 08 09:38:51 EET 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip 7 | -------------------------------------------------------------------------------- /src/platforms/ios/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | UIBackgroundModes 6 | 7 | remote-notification 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/scripts/preuninstall.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | var utils = require('../hooks/utils'); 3 | var hook = require('nativescript-hook')(path.resolve(__dirname, '../')); 4 | var projDir = hook.findProjectDir(); 5 | 6 | hook.preuninstall(); 7 | 8 | if (projDir) { 9 | utils.removeIfPresent(path.join(projDir, 'platforms')); 10 | } -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/drawable-nodpi/splash_screen.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /publish/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "nativescript-publish", 3 | "version": "1.0.0", 4 | "description": "Publish helper", 5 | "repository": { 6 | "type": "git", 7 | "url": "https://github.com/NativeScript/nativescript-plugin-seed.git" 8 | }, 9 | "license": "Apache-2.0", 10 | "devDependencies": { 11 | "ncp": "^2.0.0", 12 | "rimraf": "^2.5.0" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/app.gradle: -------------------------------------------------------------------------------- 1 | // Add your native dependencies here: 2 | 3 | // Uncomment to add recyclerview-v7 dependency 4 | //dependencies { 5 | // compile 'com.android.support:recyclerview-v7:+' 6 | //} 7 | 8 | android { 9 | defaultConfig { 10 | generatedDensities = [] 11 | applicationId = "org.nativescript.ppTest" 12 | } 13 | aaptOptions { 14 | additionalParameters "--no-version-vectors" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /native-src/android/app/src/main/java/com/telerik/pushplugin/InstanceIdListenerService.java: -------------------------------------------------------------------------------- 1 | package com.telerik.pushplugin; 2 | 3 | import com.google.firebase.iid.FirebaseInstanceIdService; 4 | 5 | /** 6 | * Listens for refresh of the Token made by GCM. 7 | */ 8 | public class InstanceIdListenerService extends FirebaseInstanceIdService { 9 | 10 | @Override 11 | public void onTokenRefresh() { 12 | PushPlugin.executeOnTokenRefreshCallback(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin/PushPlugin.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | //! Project version number for PushPlugin. 4 | FOUNDATION_EXPORT double PushPluginVersionNumber; 5 | 6 | //! Project version string for PushPlugin. 7 | FOUNDATION_EXPORT const unsigned char PushPluginVersionString[]; 8 | 9 | // In this header, you should import all the public headers of your framework using statements like #import 10 | 11 | #import 12 | #import -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/Headers/PushPlugin.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | //! Project version number for PushPlugin. 4 | FOUNDATION_EXPORT double PushPluginVersionNumber; 5 | 6 | //! Project version string for PushPlugin. 7 | FOUNDATION_EXPORT const unsigned char PushPluginVersionString[]; 8 | 9 | // In this header, you should import all the public headers of your framework using statements like #import 10 | 11 | #import 12 | #import -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.Center.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchScreen-Center.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchScreen-Center@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Assets.xcassets/LaunchScreen.AspectFill.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchScreen-AspectFill.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchScreen-AspectFill@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/build.xcconfig: -------------------------------------------------------------------------------- 1 | // You can add custom settings here 2 | // for example you can uncomment the following line to force distribution code signing 3 | // CODE_SIGN_IDENTITY = iPhone Distribution 4 | // To build for device with XCode 8 you need to specify your development team. More info: https://developer.apple.com/library/prerelease/content/releasenotes/DeveloperTools/RN-Xcode/Introduction.html 5 | // DEVELOPMENT_TEAM = YOUR_TEAM_ID; 6 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 7 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 8 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /.project 2 | .vscode 3 | .idea 4 | .DS_Store 5 | *.js 6 | *.js.map 7 | *.log 8 | *.esm.json 9 | !src/scripts/*.js 10 | !src/hooks/*.js 11 | !seed-tests/*.js 12 | seed-tests/seed-copy/**/*.* 13 | seed-tests/seed-copy-new-git-repo/**/*.* 14 | demo/**/*.js 15 | !demo/karma.conf.js 16 | !demo/app/tests/*.js 17 | demo/*.d.ts 18 | !demo/references.d.ts 19 | demo/lib 20 | demo/platforms 21 | demo/node_modules 22 | node_modules 23 | publish/src 24 | publish/package 25 | demo/report/report.html 26 | demo/report/stats.json 27 | src/platforms/android/sync 28 | -------------------------------------------------------------------------------- /demo/README.md: -------------------------------------------------------------------------------- 1 | This NativeScript project demonstrates how the plugin works. 2 | If you want to test it out on an emulator or a device you can follow the instructions below: 3 | 4 | * `git clone https://github.com/NativeScript/NativeScript/push-plugin.git` 5 | * `cd push-plugin/demo` or `cd push-plugin/demo-angular` 6 | * if you are building for android, copy the `google-services.json` downloaded from the general settings page for your project in the Firebase console and add the Sender ID from the Cloud Messaging settings page to the `app/main-view-model.ts` file. 7 | * `npm run build.plugin && npm install` 8 | * `tns run android` or `tns run ios` depending on the platform you want to test 9 | 10 | -------------------------------------------------------------------------------- /src/hooks/before-prepare.js: -------------------------------------------------------------------------------- 1 | var utils = require('./utils'); 2 | 3 | module.exports = function ($logger, $projectData) { 4 | 5 | // No need to check if file exists cause it's a before-prepare hook 6 | // and if project targets Android, platforms dir is already created. 7 | // If Android is not set up correctly, platform is not added and we log an error 8 | 9 | utils.setLogger(_log); 10 | 11 | if (utils.targetsAndroid($projectData.projectDir)) { 12 | utils.addIfNecessary($projectData.platformsDir, $projectData.appResourcesDirectoryPath); 13 | } 14 | 15 | function _log (str) { 16 | $logger.info('nativescript-push-notifications -- ' + str); 17 | } 18 | }; 19 | -------------------------------------------------------------------------------- /native-src/android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | google() 6 | jcenter() 7 | google() 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:3.0.1' 11 | 12 | // NOTE: Do not place your application dependencies here; they belong 13 | // in the individual module build.gradle files 14 | } 15 | } 16 | 17 | allprojects { 18 | repositories { 19 | google() 20 | jcenter() 21 | maven { url "https://maven.google.com" } 22 | } 23 | } 24 | 25 | task clean(type: Delete) { 26 | delete rootProject.buildDir 27 | } 28 | -------------------------------------------------------------------------------- /native-src/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 7 | 8 | 9 | 10 | 11 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /native-src/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in C:\Users\gprodano\AppData\Local\Android\android-sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | -------------------------------------------------------------------------------- /demo/app/app.css: -------------------------------------------------------------------------------- 1 | /* 2 | In NativeScript, the app.css file is where you place CSS rules that 3 | you would like to apply to your entire application. Check out 4 | http://docs.nativescript.org/ui/styling for a full list of the CSS 5 | selectors and properties you can use to style UI components. 6 | 7 | /* 8 | In many cases you may want to use the NativeScript core theme instead 9 | of writing your own CSS rules. For a full list of class names in the theme 10 | refer to http://docs.nativescript.org/ui/theme. 11 | The imported CSS rules must precede all other types of rules. 12 | */ 13 | @import '~nativescript-theme-core/css/core.light.css'; 14 | 15 | /* 16 | The following CSS rule changes the font size of all UI 17 | components that have the btn class name. 18 | */ 19 | .btn { 20 | font-size: 18; 21 | } 22 | -------------------------------------------------------------------------------- /src/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es5", 4 | "module": "commonjs", 5 | "declaration": true, 6 | "removeComments": true, 7 | "noLib": false, 8 | "emitDecoratorMetadata": true, 9 | "experimentalDecorators": true, 10 | "lib": ["es6", "dom"], 11 | "sourceMap": true, 12 | "pretty": true, 13 | "allowUnreachableCode": false, 14 | "allowUnusedLabels": false, 15 | "noEmitHelpers": true, 16 | "noEmitOnError": false, 17 | "noImplicitAny": false, 18 | "noImplicitReturns": true, 19 | "noImplicitUseStrict": false, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "exclude": [ 23 | "node_modules" 24 | ], 25 | "compileOnSave": false 26 | } -------------------------------------------------------------------------------- /native-src/ios/PushPluginTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | com.ddimitrov.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /demo/app/README.md: -------------------------------------------------------------------------------- 1 | # NativeScript TypeScript Template 2 | 3 | This template creates a NativeScript app with the NativeScript hello world example, 4 | however, in this template the example is built with TypeScript. 5 | 6 | You can create a new app that uses this template with either the `--template` option. 7 | 8 | ``` 9 | tns create my-app-name --template tns-template-hello-world-ts 10 | ``` 11 | 12 | Or the `--tsc` shorthand. 13 | 14 | ``` 15 | tns create my-app-name --tsc 16 | ``` 17 | 18 | > Note: Both commands will create a new NativeScript app that uses the latest version of this template published to [npm] (https://www.npmjs.com/package/tns-template-hello-world-ts). 19 | 20 | If you want to create a new app that uses the source of the template from the `master` branch, you can execute the following: 21 | 22 | ``` 23 | tns create my-app-name --template https://github.com/NativeScript/template-hello-world-ts.git#master 24 | ``` 25 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | com.telerik.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(CURRENT_PROJECT_VERSION) 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /native-src/android/app/src/main/java/com/telerik/pushplugin/PushPluginListener.java: -------------------------------------------------------------------------------- 1 | package com.telerik.pushplugin; 2 | 3 | import com.google.firebase.messaging.RemoteMessage; 4 | 5 | /** 6 | * Defines methods for Success and Error callbacks 7 | */ 8 | public interface PushPluginListener { 9 | /** 10 | * Defines a success callback method, which is used to pass success function reference 11 | * from the nativescript to the Java plugin 12 | * 13 | * @param message 14 | * @param data 15 | */ 16 | void success(Object data, RemoteMessage.Notification notificationObj); 17 | void success(Object data); // method overload to mimic optional argument 18 | 19 | 20 | /** 21 | * Defines a error callback method, which is used to pass success function reference 22 | * from the nativescript to the Java plugin 23 | * 24 | * @param data 25 | */ 26 | void error(Object data); 27 | } 28 | -------------------------------------------------------------------------------- /native-src/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true -------------------------------------------------------------------------------- /native-src/android/android.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/scripts/postinstall.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | var utils = require('../hooks/utils'); 3 | var hook = require('nativescript-hook')(path.resolve(__dirname, '../')); 4 | var projDir = hook.findProjectDir(); 5 | 6 | hook.postinstall(); 7 | 8 | if (projDir) { 9 | var resourcesDir; 10 | 11 | try { 12 | var globalPath = require('child_process').execSync('npm root -g').toString().trim(); 13 | var tns = require(path.join(globalPath, 'nativescript')); 14 | var project = tns.projectDataService.getProjectData(projDir); 15 | resourcesDir = project.appResourcesDirectoryPath; 16 | } catch (exc) { 17 | console.log('Push plugin cannot find project root. Project will be initialized during build.'); 18 | } 19 | if (resourcesDir) { 20 | utils.checkForGoogleServicesJson(projDir, resourcesDir); 21 | utils.addOnPluginInstall(path.join(projDir, 'platforms'), resourcesDir); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /publish/build-android.sh: -------------------------------------------------------------------------------- 1 | set -e 2 | set -o pipefail 3 | 4 | CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 5 | 6 | SOURCE_NAME="app" 7 | ANDROID_SOURCE_DIR="$CURRENT_DIR/../native-src/android" 8 | 9 | PROJECT_NAME="$SOURCE_NAME" 10 | 11 | BUILD_OUTPUT_DIR="$ANDROID_SOURCE_DIR/$PROJECT_NAME/build/outputs/aar/" 12 | 13 | PLUGIN_TARGET_DIR="$CURRENT_DIR/../src/platforms" 14 | PLUGIN_TARGET_SUBDIR="$PLUGIN_TARGET_DIR/android" 15 | 16 | cd $ANDROID_SOURCE_DIR 17 | 18 | ./gradlew clean assembleRelease 19 | 20 | echo "$PROJECT_NAME-release.aar was built in $BUILD_OUTPUT_DIR" 21 | 22 | if [ ! -d $PLUGIN_TARGET_DIR ]; then 23 | mkdir $PLUGIN_TARGET_DIR 24 | fi 25 | 26 | if [ ! -d $PLUGIN_TARGET_SUBDIR ]; then 27 | mkdir $PLUGIN_TARGET_SUBDIR 28 | fi 29 | 30 | cp -R "$BUILD_OUTPUT_DIR/$PROJECT_NAME-release.aar" $PLUGIN_TARGET_SUBDIR/pushplugin.aar 31 | 32 | echo "force livesync" > "$PLUGIN_TARGET_SUBDIR/sync" 33 | 34 | echo "Android library was copied to $PLUGIN_TARGET_SUBDIR" 35 | 36 | cd $CURRENT_DIR 37 | -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/values-v21/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 9 | 10 | 11 | 14 | 15 | 16 | 19 | 20 | 23 | -------------------------------------------------------------------------------- /native-src/android/pushplugin.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin.xcodeproj/xcuserdata/backendservtestuser.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | PushPlugin.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | PushPluginLibrary.xcscheme 13 | 14 | orderHint 15 | 1 16 | 17 | 18 | SuppressBuildableAutocreation 19 | 20 | 2B6E19161B454838006A7B46 21 | 22 | primary 23 | 24 | 25 | 2B6E19211B454838006A7B46 26 | 27 | primary 28 | 29 | 30 | 2B6E19381B454A67006A7B46 31 | 32 | primary 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /native-src/ios/PushPluginTests/PushPluginTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // PushPluginTests.m 3 | // PushPluginTests 4 | // 5 | // Created by BackendServTestUser on 7/2/15. 6 | // Copyright (c) 2015 BackendServTestUser. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface PushPluginTests : XCTestCase 13 | 14 | @end 15 | 16 | @implementation PushPluginTests 17 | 18 | - (void)setUp { 19 | [super setUp]; 20 | // Put setup code here. This method is called before the invocation of each test method in the class. 21 | } 22 | 23 | - (void)tearDown { 24 | // Put teardown code here. This method is called after the invocation of each test method in the class. 25 | [super tearDown]; 26 | } 27 | 28 | - (void)testExample { 29 | // This is an example of a functional test case. 30 | XCTAssert(YES, @"Pass"); 31 | } 32 | 33 | - (void)testPerformanceExample { 34 | // This is an example of a performance test case. 35 | [self measureBlock:^{ 36 | // Put the code you want to measure the time of here. 37 | }]; 38 | } 39 | 40 | @end 41 | -------------------------------------------------------------------------------- /src/platforms/android/include.gradle: -------------------------------------------------------------------------------- 1 | android { 2 | defaultConfig { 3 | multiDexEnabled true 4 | } 5 | 6 | productFlavors { 7 | "nativescript-push-notifications" { 8 | dimension "nativescript-push-notifications" 9 | } 10 | } 11 | } 12 | 13 | dependencies { 14 | def firebaseMessagingVersion = project.hasProperty('firebaseMessagingVersion') ? project.firebaseMessagingVersion : '12.0.1' 15 | def supportVer = project.hasProperty("supportVersion") ? supportVersion : "25.1.0"; 16 | 17 | compile "com.android.support:appcompat-v7:$supportVer" 18 | compile "com.google.firebase:firebase-messaging:$firebaseMessagingVersion" 19 | compile "com.android.support:multidex:1.0.1" 20 | } 21 | 22 | task copyGoogleServicesJson { 23 | description "Copies the mandatory google-services.json from App_Resources/Android folder." 24 | 25 | def path = "$projectDir/../../app/App_Resources/Android/google-services.json" 26 | def servicesFile = file(path) 27 | if(servicesFile.exists()) { 28 | copy { 29 | from path 30 | into "$projectDir" 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin/Push.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface Push : NSObject 5 | { 6 | NSDictionary *notificationMessage; 7 | BOOL isInline; 8 | } 9 | 10 | @property (nonatomic, strong) NSDictionary *notificationMessage; 11 | @property BOOL isInline; 12 | @property (nonatomic, retain) NSDictionary *launchNotification; 13 | 14 | + (instancetype)sharedInstance; 15 | 16 | -(void)register:(NSMutableDictionary *)options; 17 | -(void)unregister; 18 | -(void)areNotificationsEnabled; 19 | -(void)registerUserNotificationSettings:(NSDictionary*)options; 20 | -(void)setApplicationIconBadgeNumber:(NSMutableDictionary *)options; 21 | -(void)didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken; 22 | -(void)didFailToRegisterForRemoteNotificationsWithError:(NSError *)error; 23 | -(void)notificationReceived; 24 | -(void)success:(NSString *)eventName WithMessage:(NSString *)message; 25 | -(void)success:(NSString *)eventName WithDictionary:(NSMutableDictionary *)userInfo; 26 | -(void)fail:(NSString *)eventName WithMessage:(NSString *)message withError:(NSError *)error; 27 | @end 28 | -------------------------------------------------------------------------------- /src/platforms/ios/PushPlugin.framework/Headers/Push.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface Push : NSObject 5 | { 6 | NSDictionary *notificationMessage; 7 | BOOL isInline; 8 | } 9 | 10 | @property (nonatomic, strong) NSDictionary *notificationMessage; 11 | @property BOOL isInline; 12 | @property (nonatomic, retain) NSDictionary *launchNotification; 13 | 14 | + (instancetype)sharedInstance; 15 | 16 | -(void)register:(NSMutableDictionary *)options; 17 | -(void)unregister; 18 | -(void)areNotificationsEnabled; 19 | -(void)registerUserNotificationSettings:(NSDictionary*)options; 20 | -(void)setApplicationIconBadgeNumber:(NSMutableDictionary *)options; 21 | -(void)didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken; 22 | -(void)didFailToRegisterForRemoteNotificationsWithError:(NSError *)error; 23 | -(void)notificationReceived; 24 | -(void)success:(NSString *)eventName WithMessage:(NSString *)message; 25 | -(void)success:(NSString *)eventName WithDictionary:(NSMutableDictionary *)userInfo; 26 | -(void)fail:(NSString *)eventName WithMessage:(NSString *)message withError:(NSError *)error; 27 | @end 28 | -------------------------------------------------------------------------------- /demo/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es5", 4 | "module": "commonjs", 5 | "declaration": false, 6 | "removeComments": true, 7 | "noLib": false, 8 | "emitDecoratorMetadata": true, 9 | "experimentalDecorators": true, 10 | "lib": [ 11 | "es6", 12 | "dom" 13 | ], 14 | "pretty": true, 15 | "allowUnreachableCode": false, 16 | "allowUnusedLabels": false, 17 | "noEmitHelpers": true, 18 | "noEmitOnError": false, 19 | "noImplicitAny": false, 20 | "noImplicitReturns": true, 21 | "noImplicitUseStrict": false, 22 | "noFallthroughCasesInSwitch": true, 23 | "baseUrl": ".", 24 | "paths": { 25 | "*": [ 26 | "./node_modules/tns-core-modules/*", 27 | "./node_modules/*" 28 | ], 29 | "~/*": [ 30 | "app/*" 31 | ] 32 | } 33 | }, 34 | "include": [ 35 | "../src", 36 | "**/*" 37 | ], 38 | "exclude": [ 39 | "../src/node_modules", 40 | "node_modules", 41 | "platforms" 42 | ], 43 | "compileOnSave": false 44 | } -------------------------------------------------------------------------------- /native-src/android/README.md: -------------------------------------------------------------------------------- 1 | # Push Plugin for Android 2 | 3 | This is the native java code for push notifications for the Android platform, which is designed to be easily used in NativeScript. 4 | 5 | # Build 6 | 7 | The project contains an intellij project file. It must be configured to use the Android SDK by specifying the local location of the SDK. 8 | 9 | The build's output is in the /out folder, containing the .aar file ready to be used in an Android Application. 10 | 11 | # API 12 | 13 | - Register - use to subscribe the device for Push Notifications 14 | 15 | > public static void register(Context appContext, String projectId, PushPluginListener callbacks) 16 | 17 | 18 | - Unregister - use to unsubscribe from Push Notifications 19 | 20 | > public static void unregister (Context appContext, String projectId, PushPluginListener callbacks) 21 | 22 | - OnMessageReceived - subscribe to be called via a listener 23 | 24 | > public static void setOnMessageReceivedCallback(PushPluginListener callbacks) 25 | 26 | - OnTokenRefresh - subscribe for the token refresh event 27 | 28 | > public static void executeOnTokenRefreshCallback() 29 | 30 | - Are notifications enabled - currently this cannot be checked in meaningful way and will always return true 31 | 32 | > public static Boolean areNotificationsEnabled () -------------------------------------------------------------------------------- /native-src/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.library' 2 | 3 | android { 4 | compileSdkVersion 26 5 | buildToolsVersion "26.0.2" 6 | 7 | defaultConfig { 8 | minSdkVersion 19 9 | targetSdkVersion 26 10 | versionCode 2 11 | versionName "1.1" 12 | } 13 | buildTypes { 14 | release { 15 | minifyEnabled false 16 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 17 | } 18 | } 19 | } 20 | 21 | dependencies { 22 | compile fileTree(dir: 'libs', include: ['*.jar']) 23 | // compile 'com.android.support:appcompat-v7:25.1.0' 24 | compile 'com.google.firebase:firebase-messaging:12.0.1' 25 | } 26 | 27 | gradle.buildFinished { 28 | description "Copies the .aar file to the plugin folder after build." 29 | 30 | def path = "$projectDir/build/outputs/aar/app-debug.aar" // might break if you build it for other than debug 31 | def servicesFile = file(path) 32 | if(servicesFile.exists()) { 33 | copy { 34 | from path 35 | into "$projectDir/../../../src/platforms/android" 36 | rename "app-debug.aar", "pushplugin.aar" 37 | } 38 | 39 | println "\nPlugin copied to src/platforms/android folder." 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /.github/pull_request_template.md: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | ## PR Checklist 11 | 12 | - [ ] The PR title follows our guidelines: https://github.com/NativeScript/NativeScript/blob/master/CONTRIBUTING.md#commit-messages. 13 | - [ ] There is an issue for the bug/feature this PR is for. To avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it. 14 | - [ ] All existing tests are passing 15 | - [ ] Tests for the changes are included 16 | 17 | ## What is the current behavior? 18 | 19 | 20 | ## What is the new behavior? 21 | 22 | 23 | Fixes/Implements/Closes #[Issue Number]. 24 | 25 | 26 | 27 | 36 | 37 | -------------------------------------------------------------------------------- /.github/issue_template.md: -------------------------------------------------------------------------------- 1 | ### Make sure to check the demo app(s) for sample usage 2 | 3 | ### Make sure to check the existing issues in this repository 4 | 5 | ### If the demo apps cannot help and there is no issue for your problem, tell us about it 6 | Please, ensure your title is less than 63 characters long and starts with a capital 7 | letter. 8 | 9 | ### Which platform(s) does your issue occur on? 10 | - iOS/Android/Both 11 | - iOS/Android versions 12 | - emulator or device. What type of device? 13 | 14 | ### Please, provide the following version numbers that your issue occurs with: 15 | 16 | - CLI: (run `tns --version` to fetch it) 17 | - Cross-platform modules: (check the 'version' attribute in the 18 | `node_modules/tns-core-modules/package.json` file in your project) 19 | - Runtime(s): (look for the `"tns-android"` and `"tns-ios"` properties in the `package.json` file of your project) 20 | - Plugin(s): (look for the version numbers in the `package.json` file of your 21 | project and paste your dependencies and devDependencies here) 22 | 23 | ### Please, tell us how to recreate the issue in as much detail as possible. 24 | Describe the steps to reproduce it. 25 | 26 | ### Is there any code involved? 27 | - provide a code example to recreate the problem 28 | - (EVEN BETTER) provide a .zip with application or refer to a repository with application where the problem is reproducible. 29 | -------------------------------------------------------------------------------- /demo/app/main-page.ts: -------------------------------------------------------------------------------- 1 | /* 2 | In NativeScript, a file with the same name as an XML file is known as 3 | a code-behind file. The code-behind is a great place to place your view 4 | logic, and to set up your page’s data binding. 5 | */ 6 | 7 | import { EventData } from 'tns-core-modules/data/observable'; 8 | import { Page } from 'tns-core-modules/ui/page'; 9 | import { PushTestModel } from './main-view-model'; 10 | 11 | // Event handler for Page "navigatingTo" event attached in main-page.xml 12 | export function navigatingTo(args: EventData) { 13 | /* 14 | This gets a reference this page’s UI component. You can 15 | view the API reference of the Page to see what’s available at 16 | https://docs.nativescript.org/api-reference/classes/_ui_page_.page.html 17 | */ 18 | let page = args.object; 19 | 20 | /* 21 | A page’s bindingContext is an object that should be used to perform 22 | data binding between XML markup and TypeScript code. Properties 23 | on the bindingContext can be accessed using the {{ }} syntax in XML. 24 | In this example, the {{ message }} and {{ onTap }} bindings are resolved 25 | against the object returned by createViewModel(). 26 | 27 | You can learn more about data binding in NativeScript at 28 | https://docs.nativescript.org/core-concepts/data-binding. 29 | */ 30 | page.bindingContext = new PushTestModel(); 31 | } -------------------------------------------------------------------------------- /demo/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "demo", 3 | "version": "1.1.0", 4 | "nativescript": { 5 | "id": "org.nativescript.ppTest", 6 | "tns-ios": { 7 | "version": "4.2.0" 8 | }, 9 | "tns-android": { 10 | "version": "4.2.0" 11 | } 12 | }, 13 | "repository": { 14 | "type": "git", 15 | "url": "https://github.com/NativeScript/push-plugin.git" 16 | }, 17 | "license": "Apache-2.0", 18 | "dependencies": { 19 | "nativescript-push-notifications": "../src", 20 | "nativescript-theme-core": "^1.0.4", 21 | "tns-core-modules": "~4.2.0" 22 | }, 23 | "devDependencies": { 24 | "babel-traverse": "6.26.0", 25 | "babel-types": "6.26.0", 26 | "babylon": "6.18.0", 27 | "lazy": "1.0.11", 28 | "nativescript-css-loader": "~0.26.0", 29 | "nativescript-dev-typescript": "~0.7.0", 30 | "nativescript-dev-webpack": "~0.15.0", 31 | "tslint": "^5.8.0", 32 | "typescript": "~2.8.1" 33 | }, 34 | "scripts": { 35 | "build.plugin": "cd ../src && npm run build", 36 | "ci.tslint": "npm run build.plugin && npm i && tslint --config ../tslint.json 'app/**/*.ts' --exclude '**/node_modules/**'", 37 | "ci.android.build": "npm run build.plugin && tns build android", 38 | "ci.ios.build": "npm run build.plugin && tns build ios", 39 | "generate-android-snapshot": "generate-android-snapshot --targetArchs arm,arm64,ia32 --install" 40 | } 41 | } -------------------------------------------------------------------------------- /tslint.json: -------------------------------------------------------------------------------- 1 | { 2 | "rules": { 3 | "class-name": true, 4 | "comment-format": [ 5 | true, 6 | "check-space" 7 | ], 8 | "indent": [ 9 | true, 10 | "spaces" 11 | ], 12 | "no-duplicate-variable": true, 13 | "no-eval": true, 14 | "no-internal-module": true, 15 | "no-trailing-whitespace": true, 16 | "no-var-keyword": true, 17 | "one-line": [ 18 | true, 19 | "check-open-brace", 20 | "check-whitespace" 21 | ], 22 | "quotemark": [ 23 | false, 24 | "double" 25 | ], 26 | "semicolon": [ 27 | true, 28 | "always" 29 | ], 30 | "triple-equals": [ 31 | true, 32 | "allow-null-check" 33 | ], 34 | "typedef-whitespace": [ 35 | true, 36 | { 37 | "call-signature": "nospace", 38 | "index-signature": "nospace", 39 | "parameter": "nospace", 40 | "property-declaration": "nospace", 41 | "variable-declaration": "nospace" 42 | } 43 | ], 44 | "variable-name": [ 45 | true, 46 | "ban-keywords" 47 | ], 48 | "whitespace": [ 49 | true, 50 | "check-branch", 51 | "check-decl", 52 | "check-operator", 53 | "check-separator", 54 | "check-type" 55 | ] 56 | } 57 | } -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 12 | 13 | 16 | 17 | 18 | 19 | 20 | 21 | 27 | 28 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /demo/app/app.ts: -------------------------------------------------------------------------------- 1 | /* 2 | In NativeScript, the app.ts file is the entry point to your application. 3 | You can use this file to perform app-level initialization, but the primary 4 | purpose of the file is to pass control to the app’s first module. 5 | */ 6 | 7 | import * as app from 'tns-core-modules/application'; 8 | 9 | // ANDROID ONLY! 10 | // this event is used to handle notifications that have been received while the app is not in the foreground 11 | // in iOS the system invokes the notificationCallbackIOS method automatically when a notification is tapped 12 | app.on(app.resumeEvent, function(args) { 13 | if (args.android) { 14 | const act = args.android; 15 | const intent = act.getIntent(); 16 | const extras = intent.getExtras(); 17 | console.log("Resuming activity"); 18 | if (extras) { 19 | console.log("If your notification has data (key: value) pairs, they will be listed here:"); 20 | const keys = extras.keySet(); 21 | const iterator = keys.iterator(); 22 | while (iterator.hasNext()) { 23 | const key = iterator.next(); 24 | console.log(key + ": " + extras.get(key).toString()); 25 | // clear the used keys in order to avoid getting them back 26 | // when manually switching the application between background and foreground 27 | intent.removeExtra(key); 28 | } 29 | } 30 | } 31 | }); 32 | 33 | app.start({ moduleName: 'main-page' }); 34 | /* 35 | Do not place any code after the application has been started as it will not 36 | be executed on iOS. 37 | */ 38 | -------------------------------------------------------------------------------- /src/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "nativescript-push-notifications", 3 | "version": "1.1.6", 4 | "description": "Receive push notifications in your NativeScript app on Android and iOS.", 5 | "main": "push-plugin", 6 | "typings": "index.d.ts", 7 | "author": "NativeScript Team", 8 | "bugs": { 9 | "url": "https://github.com/NativeScript/push-plugin/issues" 10 | }, 11 | "repository": { 12 | "type": "git", 13 | "url": "https://github.com/NativeScript/push-plugin.git" 14 | }, 15 | "license": "Apache-2.0", 16 | "homepage": "https://github.com/NativeScript/push-plugin", 17 | "readmeFilename": "README.md", 18 | "nativescript": { 19 | "platforms": { 20 | "ios": "3.0.0", 21 | "android": "3.0.0" 22 | }, 23 | "hooks": [ 24 | { 25 | "type": "before-prepare", 26 | "script": "hooks/before-prepare.js", 27 | "inject": true 28 | } 29 | ] 30 | }, 31 | "scripts": { 32 | "build": "npm i && tsc", 33 | "tslint": "cd .. && tslint \"**/*.ts\" --config tslint.json --exclude \"**/node_modules/**\"", 34 | "clean": "cd ../demo && rimraf hooks node_modules platforms && cd ../src && rimraf node_modules", 35 | "ci.tslint": "npm i && tslint '**/*.ts' --config ../tslint.json --exclude '**/node_modules/**'", 36 | "postinstall": "node scripts/postinstall.js", 37 | "preuninstall": "node scripts/preuninstall.js" 38 | }, 39 | "dependencies": { 40 | "nativescript-hook": "~0.2.4" 41 | }, 42 | "devDependencies": { 43 | "rimraf": "^2.6.2", 44 | "tns-core-modules": "^3.3.0", 45 | "tns-platform-declarations": "^3.3.0", 46 | "tslint": "^5.8.0", 47 | "typescript": "^2.7.2" 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /demo/app/App_Resources/iOS/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIRequiresFullScreen 28 | 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | UIInterfaceOrientationLandscapeRight 38 | 39 | UISupportedInterfaceOrientations~ipad 40 | 41 | UIInterfaceOrientationPortrait 42 | UIInterfaceOrientationPortraitUpsideDown 43 | UIInterfaceOrientationLandscapeLeft 44 | UIInterfaceOrientationLandscapeRight 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /native-src/android/app/src/main/java/com/telerik/pushplugin/UnregisterTokenThread.java: -------------------------------------------------------------------------------- 1 | package com.telerik.pushplugin; 2 | 3 | import android.util.Log; 4 | import com.google.firebase.iid.FirebaseInstanceId; 5 | 6 | import java.io.IOException; 7 | 8 | /** 9 | * Responsible for unregister device from GCM service functionality. 10 | * By design, this must happen in async way in a Thread. 11 | */ 12 | public class UnregisterTokenThread extends Thread { 13 | private static final String TAG = "UnregisterTokenThread"; 14 | 15 | private final String projectId; 16 | private final PushPluginListener callbacks; 17 | 18 | public UnregisterTokenThread(String projectId, PushPluginListener callbacks) { 19 | this.projectId = projectId; 20 | this.callbacks = callbacks; 21 | } 22 | 23 | @Override 24 | public void run() { 25 | try { 26 | deleteTokenFromGCM(); 27 | } catch (IOException e) { 28 | e.printStackTrace(); 29 | } 30 | } 31 | 32 | private void deleteTokenFromGCM() throws IOException { 33 | try { 34 | FirebaseInstanceId.getInstance().deleteToken(this.projectId, "FCM"); 35 | } catch (IOException e) { 36 | if (callbacks != null) { 37 | callbacks.error("Invalid project ID."); 38 | } 39 | return; 40 | } 41 | 42 | Log.d(TAG, "Token deleted!"); 43 | 44 | if(callbacks != null) { 45 | callbacks.success("Device unregistered!"); 46 | } 47 | 48 | // TODO: Wrap the whole callback. 49 | PushPlugin.isActive = false; 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /native-src/android/app/src/main/java/com/telerik/pushplugin/ObtainTokenThread.java: -------------------------------------------------------------------------------- 1 | package com.telerik.pushplugin; 2 | 3 | import android.util.Log; 4 | import com.google.firebase.iid.FirebaseInstanceId; 5 | 6 | import java.io.IOException; 7 | 8 | /** 9 | * Responsible for obtaining a Token from the GCM service. 10 | * By design, this must happen in async way in a Thread. 11 | */ 12 | public class ObtainTokenThread extends Thread { 13 | private static final String TAG = "ObtainTokenThread"; 14 | private final PushPluginListener callbacks; 15 | 16 | private String token; 17 | private final String projectId; 18 | 19 | public ObtainTokenThread(String projectId, PushPluginListener callbacks) { 20 | this.projectId = projectId; 21 | this.callbacks = callbacks; 22 | } 23 | 24 | @Override 25 | public void run() { 26 | try { 27 | this.token = getTokenFromGCM(); 28 | } catch (IOException e) { 29 | this.callbacks.error("Error while retrieving a token: " + e.getMessage()); 30 | e.printStackTrace(); 31 | } 32 | } 33 | 34 | private String getTokenFromGCM() throws IOException { 35 | this.token = FirebaseInstanceId.getInstance().getToken(this.projectId, "FCM"); 36 | 37 | if(this.callbacks != null) { 38 | Log.d(TAG, "Calling listener callback with token: " + this.token); 39 | this.callbacks.success(this.token); 40 | } else { 41 | Log.d(TAG, "Token call returned, but no callback provided."); 42 | } 43 | 44 | // TODO: Wrap the whole callback. 45 | PushPlugin.isActive = true; 46 | return this.token; 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /native-src/ios/PushPlugin.xcodeproj/project.xcworkspace/xcshareddata/PushPlugin.xccheckout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDESourceControlProjectFavoriteDictionaryKey 6 | 7 | IDESourceControlProjectIdentifier 8 | BC8B754B-9C8D-47D0-ABA9-1598CAAC06C3 9 | IDESourceControlProjectName 10 | PushPlugin 11 | IDESourceControlProjectOriginsDictionary 12 | 13 | E8C553F8FBDE6C62B10352AA36517C14BC12A66F 14 | https://github.com/telerik/push-plugin-ios.git 15 | 16 | IDESourceControlProjectPath 17 | PushPlugin.xcodeproj 18 | IDESourceControlProjectRelativeInstallPathDictionary 19 | 20 | E8C553F8FBDE6C62B10352AA36517C14BC12A66F 21 | ../.. 22 | 23 | IDESourceControlProjectURL 24 | https://github.com/telerik/push-plugin-ios.git 25 | IDESourceControlProjectVersion 26 | 111 27 | IDESourceControlProjectWCCIdentifier 28 | E8C553F8FBDE6C62B10352AA36517C14BC12A66F 29 | IDESourceControlProjectWCConfigurations 30 | 31 | 32 | IDESourceControlRepositoryExtensionIdentifierKey 33 | public.vcs.git 34 | IDESourceControlWCCIdentifierKey 35 | E8C553F8FBDE6C62B10352AA36517C14BC12A66F 36 | IDESourceControlWCCName 37 | push-plugin-ios 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /demo/app/App_Resources/Android/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 18 | 19 | 21 | 22 | 23 | 31 | 32 | 34 | 35 | 36 | 42 | 43 | 45 | 46 | -------------------------------------------------------------------------------- /demo/app/main-page.xml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 12 | 13 | 14 | 15 | 16 | 27 | 28 |