Skip to content

Commit

Permalink
fix ble and splashscreen
Browse files Browse the repository at this point in the history
  • Loading branch information
deguchi committed Oct 28, 2019
1 parent 690bef8 commit aa7c9f7
Show file tree
Hide file tree
Showing 17 changed files with 207 additions and 60 deletions.
5 changes: 5 additions & 0 deletions config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@
<edit-config file="*-Info.plist" mode="merge" target="NSLocationWhenInUseUsageDescription">
<string>館内マップの表示に位置情報を使います。位置情報へのアクセスを許可してください。</string>
</edit-config>
<edit-config file="*-Info.plist" mode="merge" target="NSBluetoothAlwaysUsageDescription">
<string>館内マップの表示にBluetoothを使います。Bluetoothへのアクセスを許可してください。</string>
</edit-config>
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
<preference name="FadeSplashScreen" value="true" />
Expand All @@ -57,6 +60,8 @@
<icon height="1024" platform="ios" src="www/res/icons/ios/icon-1024.png" width="1024" />
<splash height="1136" platform="ios" src="www/res/screens/ios/Default-568h@2x~iphone.png" width="640" />
<splash height="1334" platform="ios" src="www/res/screens/ios/Default-667h.png" width="750" />
<splash height="2436" platform="ios" src="www/res/screens/ios/Default-736h.png" width="1125" />
<splash height="1125" platform="ios" src="www/res/screens/ios/Default-736h.png" width="2436"/>
<splash height="2208" platform="ios" src="www/res/screens/ios/Default-736h.png" width="1242" />
<splash height="1242" platform="ios" src="www/res/screens/ios/Default-Landscape-736h.png" width="2208" />
<splash height="1536" platform="ios" src="www/res/screens/ios/Default-Landscape@2x~ipad.png" width="2048" />
Expand Down
5 changes: 2 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"bb": "browserify -g [ babelify --presets [ \"@babel/preset-env\" \"@babel/preset-react\" ] ] -g uglifyify --entry src/app.js > www/js/all.js"
},
"dependencies": {
"com.unarin.cordova.beacon": "^3.8.1",
"com.unarin.cordova.beacon": "git+https://github.com/petermetz/cordova-plugin-ibeacon.git",
"cordova-android": "^8.1.0",
"cordova-browser": "^5.0.4",
"cordova-ios": "^5.0.1",
Expand Down Expand Up @@ -67,8 +67,8 @@
"cordova": {
"platforms": [
"browser",
"ios",
"android"
"android",
"ios"
],
"plugins": {
"cordova-plugin-bluetooth-status": {},
Expand All @@ -77,9 +77,9 @@
"cordova-plugin-device-orientation": {},
"cordova-plugin-inappbrowser": {},
"cordova-plugin-splashscreen": {},
"com.unarin.cordova.beacon": {},
"cordova-plugin-network-information": {},
"cordova-plugin-wkwebview-engine": {}
"cordova-plugin-wkwebview-engine": {},
"com.unarin.cordova.beacon": {}
}
}
}
6 changes: 3 additions & 3 deletions plugins/android.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@
"files": {}
},
"installed_plugins": {
"com.unarin.cordova.beacon": {
"PACKAGE_NAME": "jp.calil.sabatomap"
},
"cordova-plugin-bluetooth-status": {
"PACKAGE_NAME": "jp.calil.sabatomap"
},
Expand All @@ -33,6 +30,9 @@
},
"cordova-plugin-wkwebview-engine": {
"PACKAGE_NAME": "jp.calil.sabatomap"
},
"com.unarin.cordova.beacon": {
"PACKAGE_NAME": "jp.calil.sabatomap"
}
},
"dependent_plugins": {}
Expand Down
6 changes: 3 additions & 3 deletions plugins/browser.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@
"files": {}
},
"installed_plugins": {
"com.unarin.cordova.beacon": {
"PACKAGE_NAME": "io.cordova.hellocordova"
},
"cordova-plugin-bluetooth-status": {
"PACKAGE_NAME": "io.cordova.hellocordova"
},
Expand All @@ -33,6 +30,9 @@
},
"cordova-plugin-wkwebview-engine": {
"PACKAGE_NAME": "io.cordova.hellocordova"
},
"com.unarin.cordova.beacon": {
"PACKAGE_NAME": "io.cordova.hellocordova"
}
},
"dependent_plugins": {}
Expand Down
51 changes: 51 additions & 0 deletions plugins/com.unarin.cordova.beacon/.circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Javascript Node CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-javascript/ for more details
#
version: 2

aliases:
x-ignore-master: &x-ignore-master
filters:
branches:
ignore: master

x-only-master: &x-only-master
filters:
branches:
only: master


jobs:
lint:
docker:
- image: circleci/node:8.9
steps:
- checkout
- restore_cache:
keys:
- npm-{{ checksum "package-lock.json" }}-{{ arch }}
- npm-
- run: npm install
- save_cache:
paths:
- node_modules
key: npm-{{ checksum "package-lock.json" }}-{{ arch }}
- run:
command: |
LAST_TAG=`git describe --tags --abbrev=0`
echo commitlint --from ${LAST_TAG}
npx commitlint --from ${LAST_TAG}
workflows:
version: 2
pullrequest:
jobs:
- lint:
<<: *x-ignore-master

master:
jobs:
- lint:
<<: *x-only-master
8 changes: 8 additions & 0 deletions plugins/com.unarin.cordova.beacon/.github/issue_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Please include the following to help us address your issue.

1. Expected behavior and actual behavior.
2. Steps to reproduce the problem.
3. cordova-android version
4. cordova-ios version
5. cordova-plugin-ibeacon version
6. If running on a device, device model and os version.
13 changes: 7 additions & 6 deletions plugins/com.unarin.cordova.beacon/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# 3.7.0
# 3.8.1
- Fixing botched plugin id in release of v3.8.0.

## Android
* Permission fixes for Android 8.
* Upgrades AltBeacon to 2.14
# 3.8.0

## iOS
- No changes.
- 40abc3b feat: add ARMA filter support for distance calcs
- f2fe545 build(android): updated to latest published altbeacon library
- 0fa7553 fix(build): upgrades commitlint CLI due to vulnerability
- 7a0472a fix(ios): location manager no longer handles other instances messages

# 3.6.1

Expand Down
31 changes: 30 additions & 1 deletion plugins/com.unarin.cordova.beacon/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,16 @@

* Ranging
* Monitoring

#### Features exclusive to iOS

* Region Monitoring (or geo fencing), works in all app states.
* Advertising device as an iBeacon

#### Features exclusive to Android
* ARMA filter for distance calculations
* Disable request for bluetooth permissions

### Installation

```
Expand Down Expand Up @@ -348,12 +352,37 @@ cordova.plugins.locationManager.startMonitoringForRegion(beaconRegion)

```

##### Enable ARMA filter for distance calculations (Android only)

The underlying library uses the moving average to calculate distance by default, but an ARMA filter can be enabled which will weigh more recent measurements higher than older measurements. It can be enabled by adding the following preference to your `config.xml` file:

```<preference name="com.unarin.cordova.beacon.android.altbeacon.EnableArmaFilter" value="true" />```

#### Disable request for bluetooth permission
By default, this library requests the user for bluetooth permissions when the app starts. If you would like to request permission in a different way or at a different time, set the following preference in your `config.xml` file.

```<preference name="com.unarin.cordova.beacon.android.altbeacon.RequestBtPermission" value="false" />```


## Contributions

> Contributions are welcome at all times, please make sure that the tests are running without errors
> before submitting a pull request. The current development branch that you should submit your pull requests against is
> "v3.x" branch.
This project uses [commitlint](https://github.com/conventional-changelog/commitlint#what-is-commitlint), please ensure all commit messages pass commitlint before submitting a pull request.

### Release checklist

* `CHANGELOG.md` list meaningful changes since last release, use the format of `git log --pretty=oneline --abbrev-commit`
* `package.json` bump the version
* `plugin.xml` bump the version
* Publish to both npm packages (due to historical reasons)
* `$ npm publish` (this publishes under `com.unarin.cordova.beacon` in npm)
* Edit `name` property in the `package.json` file from `com.unarin.cordova.beacon` to `cordova-plugin-ibeacon` (do not commit the change)
* `$ npm publish` again to publish under the legacy package name as well
* revert the change you just did in `package.json`

### How to execute the tests - OS X

#### Prerequisites Of The Test Runner
Expand Down
44 changes: 28 additions & 16 deletions plugins/com.unarin.cordova.beacon/package.json
Original file line number Diff line number Diff line change
@@ -1,28 +1,25 @@
{
"_from": "com.unarin.cordova.beacon@3.7.0",
"_id": "com.unarin.cordova.beacon@3.7.0",
"_from": "git+https://github.com/petermetz/cordova-plugin-ibeacon.git",
"_id": "com.unarin.cordova.beacon@3.8.1",
"_inBundle": false,
"_integrity": "sha512-JdQCAkyXIt986beMsLE33ooDmD9JM0Kdz25Ce4OqsiOe35pOW6G+3hR9EkHU4V1QfnOthpn9b3ohGgwuE4Ou1w==",
"_integrity": "",
"_location": "/com.unarin.cordova.beacon",
"_phantomChildren": {},
"_requested": {
"type": "version",
"registry": true,
"raw": "com.unarin.cordova.beacon@3.7.0",
"name": "com.unarin.cordova.beacon",
"escapedName": "com.unarin.cordova.beacon",
"rawSpec": "3.7.0",
"saveSpec": null,
"fetchSpec": "3.7.0"
"type": "git",
"raw": "https://github.com/petermetz/cordova-plugin-ibeacon.git",
"rawSpec": "https://github.com/petermetz/cordova-plugin-ibeacon.git",
"saveSpec": "git+https://github.com/petermetz/cordova-plugin-ibeacon.git",
"fetchSpec": "https://github.com/petermetz/cordova-plugin-ibeacon.git",
"gitCommittish": null
},
"_requiredBy": [
"#USER",
"/"
],
"_resolved": "https://registry.npmjs.org/com.unarin.cordova.beacon/-/com.unarin.cordova.beacon-3.7.0.tgz",
"_shasum": "4eb1466e68a1439e48323af15bb2085265368198",
"_spec": "com.unarin.cordova.beacon@3.7.0",
"_where": "Z:\\sabatomap",
"_resolved": "git+https://github.com/petermetz/cordova-plugin-ibeacon.git#270ffbbc12159861a16e5e81481103c1e09139cb",
"_spec": "https://github.com/petermetz/cordova-plugin-ibeacon.git",
"_where": "/Users/deguchi/apps/sabatomap",
"author": {
"name": "Peter Metz",
"email": "peter.metz@unarin.com",
Expand All @@ -32,6 +29,11 @@
"url": "https://github.com/petermetz/cordova-plugin-ibeacon/issues"
},
"bundleDependencies": false,
"commitlint": {
"extends": [
"@commitlint/config-conventional"
]
},
"cordova": {
"id": "com.unarin.cordova.beacon",
"platforms": [
Expand All @@ -41,7 +43,17 @@
},
"deprecated": false,
"description": "Proximity Beacon Monitoring and Transmission Plugin (supporting iBeacons)",
"devDependencies": {
"@commitlint/cli": "^7.6.1",
"@commitlint/config-conventional": "^7.0.1",
"husky": "^2.2.0"
},
"homepage": "https://github.com/petermetz/cordova-plugin-ibeacon",
"husky": {
"hooks": {
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
}
},
"keywords": [
"cordova",
"ibeacon",
Expand All @@ -58,5 +70,5 @@
"type": "git",
"url": "git+https://github.com/petermetz/cordova-plugin-ibeacon.git"
},
"version": "3.7.0"
"version": "3.8.1"
}
2 changes: 1 addition & 1 deletion plugins/com.unarin.cordova.beacon/plugin.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<plugin id="com.unarin.cordova.beacon" version="3.7.0" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
<plugin id="com.unarin.cordova.beacon" version="3.8.1" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">

<name>Proximity Beacon Plugin</name>
<description>Proximity Beacon Monitoring and Transmission Plugin (supporting iBeacons)</description>
Expand Down
Loading

0 comments on commit aa7c9f7

Please sign in to comment.