diff --git a/.appveyor.yml b/.appveyor.yml
deleted file mode 100644
index a7b2426e0..000000000
--- a/.appveyor.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-# appveyor file
-# http://www.appveyor.com/docs/appveyor-yml
-
-max_jobs: 1
-
-shallow_clone: true
-
-init:
- - git config --global core.autocrlf true
-
-image:
- - Visual Studio 2017
-
-environment:
- nodejs_version: "4"
- matrix:
- - PLATFORM: windows-10-store
- JUST_BUILD: --justBuild
-install:
- - npm cache clean -f
- - node --version
- - npm install -g cordova-paramedic@https://github.com/apache/cordova-paramedic.git
- - npm install -g cordova
-
-build: off
-
-test_script:
- - cordova-paramedic --config pr\%PLATFORM% --plugin . %JUST_BUILD%
diff --git a/.asf.yaml b/.asf.yaml
new file mode 100644
index 000000000..541b4eec8
--- /dev/null
+++ b/.asf.yaml
@@ -0,0 +1,46 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+github:
+ description: Apache Cordova Plugin camera
+ homepage: https://cordova.apache.org/
+
+ labels:
+ - cordova
+ - mobile
+ - javascript
+ - nodejs
+ - hacktoberfest
+ - java
+ - objective-c
+ - cordova-plugin
+
+ features:
+ wiki: false
+ issues: true
+ projects: true
+
+ enabled_merge_buttons:
+ squash: true
+ merge: false
+ rebase: false
+
+notifications:
+ commits: commits@cordova.apache.org
+ issues: issues@cordova.apache.org
+ pullrequests_status: issues@cordova.apache.org
+ pullrequests_comment: issues@cordova.apache.org
diff --git a/.eslintrc.yml b/.eslintrc.yml
index 0cccb8c7a..421bf5335 100644
--- a/.eslintrc.yml
+++ b/.eslintrc.yml
@@ -1,10 +1,23 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
root: true
-extends: semistandard
-rules:
- indent:
- - error
- - 4
- camelcase: off
- padded-blocks: off
- operator-linebreak: off
- no-throw-literal: off
\ No newline at end of file
+extends: '@cordova/eslint-config/browser'
+
+overrides:
+ - files: [tests/**/*.js]
+ extends: '@cordova/eslint-config/node-tests'
diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md
new file mode 100644
index 000000000..3220c258b
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE.md
@@ -0,0 +1,42 @@
+
+
+### Issue Type
+
+
+- [ ] Bug Report
+- [ ] Feature Request
+- [ ] Support Question
+
+## Description
+
+## Information
+
+
+### Command or Code
+
+
+### Environment, Platform, Device
+
+
+
+
+### Version information
+
+
+
+
+## Checklist
+
+
+- [ ] I searched for already existing GitHub issues about this
+- [ ] I updated all Cordova tooling to their most recent version
+- [ ] I included all the necessary information above
diff --git a/.github/ISSUE_TEMPLATE/BUG_REPORT.md b/.github/ISSUE_TEMPLATE/BUG_REPORT.md
new file mode 100644
index 000000000..bd8a3acb3
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/BUG_REPORT.md
@@ -0,0 +1,50 @@
+---
+name: 🐛 Bug Report
+about: If something isn't working as expected.
+
+---
+
+# Bug Report
+
+## Problem
+
+### What is expected to happen?
+
+
+
+### What does actually happen?
+
+
+
+## Information
+
+
+
+
+### Command or Code
+
+
+
+
+### Environment, Platform, Device
+
+
+
+
+### Version information
+
+
+
+
+## Checklist
+
+
+- [ ] I searched for existing GitHub issues
+- [ ] I updated all Cordova tooling to most recent version
+- [ ] I included all the necessary information above
diff --git a/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md b/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md
new file mode 100644
index 000000000..381fc8a3b
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md
@@ -0,0 +1,29 @@
+---
+name: 🚀 Feature Request
+about: A suggestion for a new functionality
+
+---
+
+# Feature Request
+
+## Motivation Behind Feature
+
+
+
+
+## Feature Description
+
+
+
+
+## Alternatives or Workarounds
+
+
+
diff --git a/.github/ISSUE_TEMPLATE/SUPPORT_QUESTION.md b/.github/ISSUE_TEMPLATE/SUPPORT_QUESTION.md
new file mode 100644
index 000000000..f3b397c61
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/SUPPORT_QUESTION.md
@@ -0,0 +1,26 @@
+---
+name: 💬 Support Question
+about: If you have a question, please check out our Slack or StackOverflow!
+
+---
+
+
+
+Apache Cordova uses GitHub Issues as a feature request and bug tracker _only_.
+For usage and support questions, please check out the resources below. Thanks!
+
+---
+
+You can get answers to your usage and support questions about **Apache Cordova** on:
+
+* GitHub Discussions: https://github.com/apache/cordova/discussions
+* Slack Community Chat: https://cordova.slack.com (you can sign-up at https://s.apache.org/cordova-slack)
+* StackOverflow: https://stackoverflow.com/questions/tagged/cordova using the tag `cordova`
+
+---
+
+If you are using a tool that uses Cordova internally, like e.g. Ionic, check their support channels:
+
+* **Ionic Framework**
+ * [Ionic Community Forum](https://forum.ionicframework.com/)
+ * [Ionic Discord](https://ionic.link/discord)
\ No newline at end of file
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index 91582f4ef..712b2ff04 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -1,6 +1,5 @@
+
+
+
+
+### Description
+
+
+
+
+### Testing
+
-### What testing has been done on this change?
### Checklist
-- [ ] [Reported an issue](http://cordova.apache.org/contribute/issues.html) in the JIRA database
-- [ ] Commit message follows the format: "CB-3232: (android) Fix bug with resolving file paths", where CB-xxxx is the JIRA ID & "android" is the platform affected.
-- [ ] Added automated test coverage as appropriate for this change.
+
+- [ ] I've run the tests to see all new and existing tests pass
+- [ ] I added automated test coverage as appropriate for this change
+- [ ] Commit is prefixed with `(platform)` if this change only applies to one platform (e.g. `(android)`)
+- [ ] If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct [keyword to close issues using keywords](https://help.github.com/articles/closing-issues-using-keywords/))
+- [ ] I've updated the documentation if necessary
diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml
new file mode 100644
index 000000000..3159b6b49
--- /dev/null
+++ b/.github/workflows/android.yml
@@ -0,0 +1,137 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Android Testsuite
+
+on:
+ push:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+ pull_request:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+
+jobs:
+ test:
+ name: Android ${{ matrix.versions.android }} Test
+ runs-on: macos-latest
+ continue-on-error: true
+
+ # hoist configurations to top that are expected to be updated
+ env:
+ # Storing a copy of the repo
+ repo: ${{ github.event.pull_request.head.repo.full_name || github.repository }}
+
+ node-version: 16
+
+ # These are the default Java configurations used by most tests.
+ # To customize these options, add "java-distro" or "java-version" to the strategy matrix with its overriding value.
+ default_java-distro: temurin
+ default_java-version: 11
+
+ # These are the default Android System Image configurations used by most tests.
+ # To customize these options, add "system-image-arch" or "system-image-target" to the strategy matrix with its overriding value.
+ default_system-image-arch: x86_64
+ default_system-image-target: google_apis # Most system images have a google_api option. Set this as default.
+
+ # configurations for each testing strategy (test matrix)
+ strategy:
+ matrix:
+ versions:
+ # Test the lowest minimum supported APIs
+ - android: 7
+ android-api: 24
+
+ # Test the last 3-4 supported APIs
+ - android: 10
+ android-api: 29
+
+ - android: 11
+ android-api: 30
+
+ - android: 12L
+ android-api: 32
+
+ - android: 13
+ android-api: 33
+
+ timeout-minutes: 60
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-node@v3
+ with:
+ node-version: ${{ env.node-version }}
+ - uses: actions/setup-java@v3
+ env:
+ java-version: ${{ matrix.versions.java-version == '' && env.default_java-version || matrix.versions.java-version }}
+ java-distro: ${{ matrix.versions.java-distro == '' && env.default_java-distro || matrix.versions.java-distro }}
+ with:
+ distribution: ${{ env.java-distro }}
+ java-version: ${{ env.java-version }}
+
+ - name: Run Environment Information
+ run: |
+ node --version
+ npm --version
+ java -version
+
+ - name: Run npm install
+ run: |
+ export PATH="/usr/local/lib/android/sdk/platform-tools":$PATH
+ export JAVA_HOME=$JAVA_HOME_11_X64
+ npm i -g cordova@latest
+ npm ci
+
+ - name: Run paramedic install
+ if: ${{ endswith(env.repo, '/cordova-paramedic') != true }}
+ run: npm i -g github:apache/cordova-paramedic
+
+ - uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b
+ env:
+ system-image-arch: ${{ matrix.versions.system-image-arch == '' && env.default_system-image-arch || matrix.versions.system-image-arch }}
+ system-image-target: ${{ matrix.versions.system-image-target == '' && env.default_system-image-target || matrix.versions.system-image-target }}
+ with:
+ api-level: ${{ matrix.versions.android-api }}
+ target: ${{ env.system-image-target }}
+ arch: ${{ env.system-image-arch }}
+ force-avd-creation: false
+ disable-animations: false
+ emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim
+ script: echo "Pregenerate the AVD before running Paramedic"
+
+ - name: Run paramedic tests
+ uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b
+ env:
+ system-image-arch: ${{ matrix.versions.system-image-arch == '' && env.default_system-image-arch || matrix.versions.system-image-arch }}
+ system-image-target: ${{ matrix.versions.system-image-target == '' && env.default_system-image-target || matrix.versions.system-image-target }}
+ test_config: 'android-${{ matrix.versions.android }}.config.json'
+ # Generally, this should automatically work for cordova-paramedic & plugins. If the path is unique, this can be manually changed.
+ test_plugin_path: ${{ endswith(env.repo, '/cordova-paramedic') && './spec/testable-plugin/' || './' }}
+ paramedic: ${{ endswith(env.repo, '/cordova-paramedic') && 'node main.js' || 'cordova-paramedic' }}
+ with:
+ api-level: ${{ matrix.versions.android-api }}
+ target: ${{ env.system-image-target }}
+ arch: ${{ env.system-image-arch }}
+ force-avd-creation: false
+ disable-animations: false
+ emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim
+ script: ${{ env.paramedic }} --config ./pr/local/${{ env.test_config }} --plugin ${{ env.test_plugin_path }}
diff --git a/.github/workflows/chrome.yml b/.github/workflows/chrome.yml
new file mode 100644
index 000000000..72c92ff9b
--- /dev/null
+++ b/.github/workflows/chrome.yml
@@ -0,0 +1,73 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Chrome Testsuite
+
+on:
+ push:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+ pull_request:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+
+jobs:
+ test:
+ name: Chrome Latest Test
+ runs-on: ubuntu-latest
+
+ # hoist configurations to top that are expected to be updated
+ env:
+ # Storing a copy of the repo
+ repo: ${{ github.event.pull_request.head.repo.full_name || github.repository }}
+
+ node-version: 16
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-node@v3
+ with:
+ node-version: ${{ env.node-version }}
+
+ - name: Run install xvfb
+ run: sudo apt-get install xvfb
+
+ - name: Run Environment Information
+ run: |
+ node --version
+ npm --version
+
+ - name: Run npm install
+ run: |
+ npm i -g cordova@latest
+ npm ci
+
+ - name: Run paramedic install
+ if: ${{ endswith(env.repo, '/cordova-paramedic') != true }}
+ run: npm i -g github:apache/cordova-paramedic
+
+ - name: Run paramedic tests
+ env:
+ test_config: 'browser.config.json'
+ # Generally, this should automatically work for cordova-paramedic & plugins. If the path is unique, this can be manually changed.
+ test_plugin_path: ${{ endswith(env.repo, '/cordova-paramedic') && './spec/testable-plugin/' || './' }}
+ paramedic: ${{ endswith(env.repo, '/cordova-paramedic') && 'node main.js' || 'cordova-paramedic' }}
+ run: xvfb-run --auto-servernum ${{ env.paramedic }} --config ./pr/local/${{ env.test_config }} --plugin ${{ env.test_plugin_path }}
diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml
new file mode 100644
index 000000000..fc293b7fb
--- /dev/null
+++ b/.github/workflows/ios.yml
@@ -0,0 +1,101 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: iOS Testsuite
+
+on:
+ push:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+ pull_request:
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
+ - '.eslint*'
+
+jobs:
+ test:
+ name: iOS ${{ matrix.versions.ios-version }} Test
+ runs-on: ${{ matrix.versions.os-version }}
+ continue-on-error: true
+
+ # hoist configurations to top that are expected to be updated
+ env:
+ # Storing a copy of the repo
+ repo: ${{ github.event.pull_request.head.repo.full_name || github.repository }}
+
+ node-version: 16
+
+ # > Starting April 26, 2021, all iOS and iPadOS apps submitted to the App Store must be built with Xcode 12 and the iOS 14 SDK.
+ # Because of Apple's requirement, listed above, We will only be using the latest Xcode release for testing.
+ # To customize these options, add "xcode-version" to the strategy matrix with its overriding value.
+ default_xcode-version: latest-stable
+
+ strategy:
+ matrix:
+ versions:
+ - os-version: macos-11
+ ios-version: 13.x
+ xcode-version: 11.x
+
+ - os-version: macos-11
+ ios-version: 14.x
+ xcode-version: 12.x
+
+ - os-version: macos-11
+ ios-version: 15.x
+ xcode-version: 13.x
+
+ - os-version: macos-12
+ ios-version: 16.x
+ xcode-version: 14.x
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-node@v3
+ with:
+ node-version: ${{ env.node-version }}
+ - uses: maxim-lobanov/setup-xcode@9a697e2b393340c3cacd97468baa318e4c883d98
+ env:
+ xcode-version: ${{ matrix.versions.xcode-version == '' && env.default_xcode-version || matrix.versions.xcode-version }}
+ with:
+ xcode-version: ${{ env.xcode-version }}
+
+ - name: Run Environment Information
+ run: |
+ node --version
+ npm --version
+ xcodebuild -version
+
+ - name: Run npm install
+ run: |
+ npm i -g cordova@latest ios-deploy@latest
+ npm ci
+
+ - name: Run paramedic install
+ if: ${{ endswith(env.repo, '/cordova-paramedic') != true }}
+ run: npm i -g github:apache/cordova-paramedic
+
+ - name: Run paramedic tests
+ env:
+ test_config: 'ios-${{ matrix.versions.ios-version }}.config.json'
+ # Generally, this should automatically work for cordova-paramedic & plugins. If the path is unique, this can be manually changed.
+ test_plugin_path: ${{ endswith(env.repo, '/cordova-paramedic') && './spec/testable-plugin/' || './' }}
+ paramedic: ${{ endswith(env.repo, '/cordova-paramedic') && 'node main.js' || 'cordova-paramedic' }}
+ run: ${{ env.paramedic }} --config ./pr/local/${{ env.test_config }} --plugin ${{ env.test_plugin_path }}
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
new file mode 100644
index 000000000..0f82eb4c6
--- /dev/null
+++ b/.github/workflows/lint.yml
@@ -0,0 +1,56 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Lint Test
+
+on:
+ push:
+ paths:
+ - '**.js'
+ - '.eslint*'
+ - '.github/workflow/lint.yml'
+ pull_request:
+ paths:
+ - '**.js'
+ - '.eslint*'
+ - '.github/workflow/lint.yml'
+
+jobs:
+ test:
+ name: Lint Test
+ runs-on: ubuntu-latest
+ env:
+ node-version: 16
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-node@v3
+ with:
+ node-version: ${{ env.node-version }}
+
+ - name: Run Environment Information
+ run: |
+ node --version
+ npm --version
+
+ - name: Run npm install
+ run: |
+ npm ci
+
+ - name: Run lint test
+ run: |
+ npm run lint
diff --git a/.github/workflows/release-notify.yml b/.github/workflows/release-notify.yml
new file mode 100644
index 000000000..d9a76f15b
--- /dev/null
+++ b/.github/workflows/release-notify.yml
@@ -0,0 +1,13 @@
+name: Close issue asking for release
+
+on:
+ issues:
+ types: [opened]
+
+jobs:
+ action-test:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: niklasmerz/release-notify@master
+ with:
+ repo-token: ${{ secrets.GITHUB_TOKEN }}
diff --git a/.npmignore b/.npmignore
new file mode 100644
index 000000000..2657abf2a
--- /dev/null
+++ b/.npmignore
@@ -0,0 +1,2 @@
+.*
+tests
diff --git a/.ratignore b/.ratignore
deleted file mode 100644
index 7fd6d830c..000000000
--- a/.ratignore
+++ /dev/null
@@ -1 +0,0 @@
-TEMPLATE.md
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 52f71713e..000000000
--- a/.travis.yml
+++ /dev/null
@@ -1,96 +0,0 @@
-sudo: false
-addons:
- jwt:
- secure: QivPLlqTVvOo3TJeHxuBOfxU6lho1I0IxQ3b68yntkEQQJko6kzleXHfgjf0a8aw8m38E3+fxaBWF1bGyucGwOLDWY8Ddt2P2xg44zdXH5EXHd9oIqAgngIdzLvUtH3Db2TbQEtIGOkrnNR2STovjqB7vHGLASQrgs4oL7r32/s=
-env:
- global:
- - SAUCE_USERNAME=snay
- - TRAVIS_NODE_VERSION="4.2"
-matrix:
- include:
- - env: TEST_DIR=.
- language: objective-c
- - env: TEST_DIR=./tests/ios
- language: objective-c
- - env: PLATFORM=browser-chrome
- os: linux
- language: node_js
- node_js: '4.2'
- - env: PLATFORM=browser-firefox
- os: linux
- language: node_js
- node_js: '4.2'
- - env: PLATFORM=browser-safari
- os: linux
- language: node_js
- node_js: '4.2'
- - env: PLATFORM=browser-edge
- os: linux
- language: node_js
- node_js: '4.2'
- - env: PLATFORM=ios-9.3
- os: osx
- osx_image: xcode7.3
- language: node_js
- node_js: "4.2"
- - env: PLATFORM=ios-10.0
- os: osx
- osx_image: xcode7.3
- language: node_js
- node_js: "4.2"
- - env: PLATFORM=android-4.4
- os: linux
- language: android
- jdk: oraclejdk8
- android:
- components:
- - tools
- - extra-android-m2repository
- - build-tools-26.0.2
- - env: PLATFORM=android-5.1
- os: linux
- language: android
- jdk: oraclejdk8
- android:
- components:
- - tools
- - extra-android-m2repository
- - build-tools-26.0.2
- - env: PLATFORM=android-6.0
- os: linux
- language: android
- jdk: oraclejdk8
- android:
- components:
- - tools
- - extra-android-m2repository
- - build-tools-26.0.2
- - env: PLATFORM=android-7.0
- os: linux
- language: android
- jdk: oraclejdk8
- android:
- components:
- - tools
- - extra-android-m2repository
- - build-tools-26.0.2
-before_install:
-- rm -rf ~/.nvm && git clone https://github.com/creationix/nvm.git ~/.nvm && (cd ~/.nvm && git checkout `git describe --abbrev=0 --tags`) && source ~/.nvm/nvm.sh && nvm install $TRAVIS_NODE_VERSION
-- node --version
-- if [[ "$PLATFORM" =~ android ]]; then gradle --version; fi
-- if [[ "$PLATFORM" =~ ios ]]; then npm install -g ios-deploy; fi
-- if [[ "$PLATFORM" =~ android ]]; then echo y | android update sdk -u --filter android-22,android-23,android-24,android-25,android-26;
- fi
-- git clone https://github.com/apache/cordova-paramedic /tmp/paramedic && pushd /tmp/paramedic
- && npm install && popd
-- npm install -g cordova
-install:
-- npm install
-script:
-- if [[ "$TEST_DIR" != "" ]];
- then cd $TEST_DIR && npm install && npm test;
- else
- node /tmp/paramedic/main.js --config pr/$PLATFORM --plugin $(pwd) --shouldUseSauce
- --buildName travis-plugin-camera-$TRAVIS_JOB_NUMBER;
- fi
-
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 4c8e6a5ea..21a93d72a 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -25,13 +25,13 @@ Anyone can contribute to Cordova. And we need your contributions.
There are multiple ways to contribute: report bugs, improve the docs, and
contribute code.
-
-For instructions on this, start with the
+
+For instructions on this, start with the
[contribution overview](http://cordova.apache.org/contribute/).
The details are explained there, but the important items are:
- - Sign and submit an Apache ICLA (Contributor License Agreement).
- - Have a Jira issue open that corresponds to your contribution.
+ - Check for Github issues that corresponds to your contribution and link or create them if necessary.
- Run the tests so your patch doesn't break existing functionality.
We look forward to your contributions!
+
diff --git a/README.md b/README.md
index 446511744..4c92e77a7 100644
--- a/README.md
+++ b/README.md
@@ -21,12 +21,10 @@ description: Take pictures with the device camera.
# under the License.
-->
-|AppVeyor|Travis CI|
-|:-:|:-:|
-|[![Build status](https://ci.appveyor.com/api/projects/status/github/apache/cordova-plugin-camera?branch=master)](https://ci.appveyor.com/project/ApacheSoftwareFoundation/cordova-plugin-camera)|[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg?branch=master)](https://travis-ci.org/apache/cordova-plugin-camera)|
-
# cordova-plugin-camera
+[![Android Testsuite](https://github.com/apache/cordova-plugin-camera/actions/workflows/android.yml/badge.svg)](https://github.com/apache/cordova-plugin-camera/actions/workflows/android.yml) [![Chrome Testsuite](https://github.com/apache/cordova-plugin-camera/actions/workflows/chrome.yml/badge.svg)](https://github.com/apache/cordova-plugin-camera/actions/workflows/chrome.yml) [![iOS Testsuite](https://github.com/apache/cordova-plugin-camera/actions/workflows/ios.yml/badge.svg)](https://github.com/apache/cordova-plugin-camera/actions/workflows/ios.yml) [![Lint Test](https://github.com/apache/cordova-plugin-camera/actions/workflows/lint.yml/badge.svg)](https://github.com/apache/cordova-plugin-camera/actions/workflows/lint.yml)
+
This plugin defines a global `navigator.camera` object, which provides an API for taking pictures and for choosing images from
the system's image library.
@@ -40,40 +38,33 @@ Although the object is attached to the global scoped `navigator`, it is not avai
## Installation
-This requires cordova 5.0+
-
cordova plugin add cordova-plugin-camera
-Older versions of cordova can still install via the __deprecated__ id
- cordova plugin add org.apache.cordova.camera
It is also possible to install via repo url directly ( unstable )
cordova plugin add https://github.com/apache/cordova-plugin-camera.git
+## Plugin variables
+
+The plugin uses the `ANDROIDX_CORE_VERSION` variable to configure `androidx.core:core` dependency. This allows to avoid conflicts with other plugins that have the dependency hardcoded.
+If no value is passed, it will use `1.6.+` as the default value.
+
+The variable is configured on install time
+
+ cordova plugin add cordova-plugin-camera --variable ANDROIDX_CORE_VERSION=1.8.0
## How to Contribute
-Contributors are welcome! And we need your contributions to keep the project moving forward. You can [report bugs](https://issues.apache.org/jira/issues/?jql=project%20%3D%20CB%20AND%20status%20in%20(Open%2C%20%22In%20Progress%22%2C%20Reopened)%20AND%20resolution%20%3D%20Unresolved%20AND%20component%20%3D%20%22cordova-plugin-camera%22%20ORDER%20BY%20priority%20DESC%2C%20summary%20ASC%2C%20updatedDate%20DESC), improve the documentation, or [contribute code](https://github.com/apache/cordova-plugin-camera/pulls).
+Contributors are welcome! And we need your contributions to keep the project moving forward. You can[report bugs, improve the documentation, or [contribute code](https://github.com/apache/cordova-plugin-camera/pulls).
There is a specific [contributor workflow](http://wiki.apache.org/cordova/ContributorWorkflow) we recommend. Start reading there. More information is available on [our wiki](http://wiki.apache.org/cordova).
-:warning: **Found an issue?** File it on [JIRA issue tracker](https://issues.apache.org/jira/issues/?jql=project%20%3D%20CB%20AND%20status%20in%20(Open%2C%20%22In%20Progress%22%2C%20Reopened)%20AND%20resolution%20%3D%20Unresolved%20AND%20component%20%3D%20%22cordova-plugin-camera%22%20ORDER%20BY%20priority%20DESC%2C%20summary%20ASC%2C%20updatedDate%20DESC).
-
**Have a solution?** Send a [Pull Request](https://github.com/apache/cordova-plugin-camera/pulls).
In order for your changes to be accepted, you need to sign and submit an Apache [ICLA](http://www.apache.org/licenses/#clas) (Individual Contributor License Agreement). Then your name will appear on the list of CLAs signed by [non-committers](https://people.apache.org/committer-index.html#unlistedclas) or [Cordova committers](http://people.apache.org/committers-by-project.html#cordova).
**And don't forget to test and document your code.**
-
-## This documentation is generated by a tool
-
-:warning: Run `npm install` in the plugin repo to enable automatic docs generation if you plan to send a PR.
-[jsdoc-to-markdown](https://www.npmjs.com/package/jsdoc-to-markdown) is used to generate the docs.
-Documentation consists of template and API docs produced from the plugin JS code and should be regenerated before each commit (done automatically via [husky](https://github.com/typicode/husky), running `npm run gen-docs` script as a `precommit` hook - see `package.json` for details).
-
-
-
### iOS Quirks
Since iOS 10 it's mandatory to provide an usage description in the `info.plist` if trying to access privacy-sensitive data. When the system prompts the user to allow access, this usage description string will displayed as part of the permission dialog box, but if you didn't provide the usage description, the app will crash before showing the dialog. Also, Apple will reject apps that access private data but don't provide an usage description.
@@ -179,14 +170,8 @@ than `DATA_URL`.
__Supported Platforms__
- Android
-- BlackBerry
- Browser
-- Firefox
-- FireOS
- iOS
-- Windows
-- WP8
-- Ubuntu
More examples [here](#camera-getPicture-examples). Quirks [here](#camera-getPicture-quirks).
@@ -291,19 +276,14 @@ Optional parameters to customize the camera settings.
### Camera.DestinationType : enum
Defines the output format of `Camera.getPicture` call.
-_Note:_ On iOS passing `DestinationType.NATIVE_URI` along with
-`PictureSourceType.PHOTOLIBRARY` or `PictureSourceType.SAVEDPHOTOALBUM` will
-disable any image modifications (resize, quality change, cropping, etc.) due
-to implementation specific.
**Kind**: static enum property of [Camera](#module_Camera)
**Properties**
| Name | Type | Default | Description |
| --- | --- | --- | --- |
-| DATA_URL | number
| 0
| Return base64 encoded string. DATA_URL can be very memory intensive and cause app crashes or out of memory errors. Use FILE_URI or NATIVE_URI if possible |
+| DATA_URL | number
| 0
| Return base64 encoded string. DATA_URL can be very memory intensive and cause app crashes or out of memory errors. Use FILE_URI if possible |
| FILE_URI | number
| 1
| Return file uri (content://media/external/images/media/2 for Android) |
-| NATIVE_URI | number
| 2
| Return native uri (eg. asset-library://... for iOS) |
@@ -332,9 +312,6 @@ to implementation specific.
### Camera.PictureSourceType : enum
Defines the output format of `Camera.getPicture` call.
-_Note:_ On iOS passing `PictureSourceType.PHOTOLIBRARY` or `PictureSourceType.SAVEDPHOTOALBUM`
-along with `DestinationType.NATIVE_URI` will disable any image modifications (resize, quality
-change, cropping, etc.) due to implementation specific.
**Kind**: static enum property of [Camera](#module_Camera)
**Properties**
@@ -393,6 +370,8 @@ location.
| [width] | Number
| 320
| width, in pixels, of the screen element onto which to anchor the popover. |
| [height] | Number
| 480
| height, in pixels, of the screen element onto which to anchor the popover. |
| [arrowDir] | [PopoverArrowDirection](#module_Camera.PopoverArrowDirection)
| ARROW_ANY
| Direction the arrow on the popover should point. |
+| [popoverWidth] | Number
| 0
| width of the popover (0 or not specified will use apple's default width). |
+| [popoverHeight] | Number
| 0
| height of the popover (0 or not specified will use apple's default height). |
---
@@ -411,13 +390,13 @@ navigator.camera.getPicture(onSuccess, onFail,
{
destinationType: Camera.DestinationType.FILE_URI,
sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
+ popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY, 300, 600)
});
// Reposition the popover if the orientation changes.
window.onorientationchange = function() {
var cameraPopoverHandle = new CameraPopoverHandle();
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
+ var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY, 400, 500);
cameraPopoverHandle.setPosition(cameraPopoverOptions);
}
```
@@ -448,7 +427,7 @@ Take a photo and retrieve it as a Base64-encoded image:
* Warning: Using DATA_URL is not recommended! The DATA_URL destination
* type is very memory intensive, even with a low quality setting. Using it
* can result in out of memory errors and application crashes. Use FILE_URI
- * or NATIVE_URI instead.
+ * instead.
*/
navigator.camera.getPicture(onSuccess, onFail, { quality: 25,
destinationType: Camera.DestinationType.DATA_URL
@@ -469,12 +448,6 @@ Take a photo and retrieve it as a Base64-encoded image:
-#### Amazon Fire OS Quirks
-
-Amazon Fire OS uses intents to launch the camera activity on the device to capture
-images, and on phones with low memory, the Cordova activity may be killed. In this
-scenario, the image may not appear when the Cordova activity is restored.
-
#### Android Quirks
Android uses intents to launch the camera activity on the device to capture
@@ -490,10 +463,6 @@ successful.
Can only return photos as Base64-encoded image.
-#### Firefox OS Quirks
-
-Camera plugin is currently implemented using [Web Activities][web_activities].
-
#### iOS Quirks
Including a JavaScript `alert()` in either of the callback functions
@@ -505,110 +474,24 @@ displays:
// do your thing here!
}, 0);
-#### Windows Phone 7 Quirks
-
-Invoking the native camera application while the device is connected
-via Zune does not work, and triggers an error callback.
-
-#### Windows quirks
-
-On Windows Phone 8.1 using `SAVEDPHOTOALBUM` or `PHOTOLIBRARY` as a source type causes application to suspend until file picker returns the selected image and
-then restore with start page as defined in app's `config.xml`. In case when `camera.getPicture` was called from different page, this will lead to reloading
-start page from scratch and success and error callbacks will never be called.
-
-To avoid this we suggest using SPA pattern or call `camera.getPicture` only from your app's start page.
-
-More information about Windows Phone 8.1 picker APIs is here: [How to continue your Windows Phone app after calling a file picker](https://msdn.microsoft.com/en-us/library/windows/apps/dn720490.aspx)
-
-#### Tizen Quirks
-
-Tizen only supports a `destinationType` of
-`Camera.DestinationType.FILE_URI` and a `sourceType` of
-`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-
## `CameraOptions` Errata
-#### Amazon Fire OS Quirks
-
-- Any `cameraDirection` value results in a back-facing photo.
-
-- Ignores the `allowEdit` parameter.
-
-- `Camera.PictureSourceType.PHOTOLIBRARY` and `Camera.PictureSourceType.SAVEDPHOTOALBUM` both display the same photo album.
-
#### Android Quirks
-- Any `cameraDirection` value results in a back-facing photo.
+- Any `cameraDirection` value results in a back-facing photo. (= You can only use the back camera)
-- **`allowEdit` is unpredictable on Android and it should not be used!** The Android implementation of this plugin tries to find and use an application on the user's device to do image cropping. The plugin has no control over what application the user selects to perform the image cropping and it is very possible that the user could choose an incompatible option and cause the plugin to fail. This sometimes works because most devices come with an application that handles cropping in a way that is compatible with this plugin (Google Plus Photos), but it is unwise to rely on that being the case. If image editing is essential to your application, consider seeking a third party library or plugin that provides its own image editing utility for a more robust solution.
+- **`allowEdit` is unpredictable on Android and it should not be used!** The Android implementation of this plugin tries to find and use an application on the user's device to do image cropping. The plugin has no control over what application the user selects to perform the image cropping and it is very possible that the user could choose an incompatible option and cause the plugin to fail. This sometimes works because most devices come with an application that handles cropping in a way that is compatible with this plugin (Google Photos), but it is unwise to rely on that being the case. If image editing is essential to your application, consider seeking a third party library or plugin that provides its own image editing utility for a more robust solution.
- `Camera.PictureSourceType.PHOTOLIBRARY` and `Camera.PictureSourceType.SAVEDPHOTOALBUM` both display the same photo album.
- Ignores the `encodingType` parameter if the image is unedited (i.e. `quality` is 100, `correctOrientation` is false, and no `targetHeight` or `targetWidth` are specified). The `CAMERA` source will always return the JPEG file given by the native camera and the `PHOTOLIBRARY` and `SAVEDPHOTOALBUM` sources will return the selected file in its existing encoding.
-#### BlackBerry 10 Quirks
-
-- Ignores the `quality` parameter.
-
-- Ignores the `allowEdit` parameter.
-
-- `Camera.MediaType` is not supported.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
-#### Firefox OS Quirks
-
-- Ignores the `quality` parameter.
-
-- `Camera.DestinationType` is ignored and equals `1` (image file URI)
-
-- Ignores the `allowEdit` parameter.
-
-- Ignores the `PictureSourceType` parameter (user chooses it in a dialog window)
-
-- Ignores the `encodingType`
-
-- Ignores the `targetWidth` and `targetHeight`
-
-- `Camera.MediaType` is not supported.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
#### iOS Quirks
- When using `destinationType.FILE_URI`, photos are saved in the application's temporary directory. The contents of the application's temporary directory is deleted when the application ends.
-- When using `destinationType.NATIVE_URI` and `sourceType.CAMERA`, photos are saved in the saved photo album regardless on the value of `saveToPhotoAlbum` parameter.
-
-- When using `destinationType.NATIVE_URI` and `sourceType.PHOTOLIBRARY` or `sourceType.SAVEDPHOTOALBUM`, all editing options are ignored and link is returned to original picture.
-
-#### Tizen Quirks
-
-- options not supported
-
-- always returns a FILE URI
-
-#### Windows Phone 7 and 8 Quirks
-
-- Ignores the `allowEdit` parameter.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
-- Ignores the `saveToPhotoAlbum` parameter. IMPORTANT: All images taken with the WP8/8 Cordova camera API are always copied to the phone's camera roll. Depending on the user's settings, this could also mean the image is auto-uploaded to their OneDrive. This could potentially mean the image is available to a wider audience than your app intended. If this is a blocker for your application, you will need to implement the CameraCaptureTask as [documented on MSDN][msdn_wp8_docs]. You may also comment or up-vote the related issue in the [issue tracker][wp8_bug].
-
-- Ignores the `mediaType` property of `cameraOptions` as the Windows Phone SDK does not provide a way to choose videos from PHOTOLIBRARY.
[android_lifecycle]: http://cordova.apache.org/docs/en/dev/guide/platforms/android/lifecycle.html
-[web_activities]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-[wp8_bug]: https://issues.apache.org/jira/browse/CB-2083
-[msdn_wp8_docs]: http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx
## Sample: Take Pictures, Select Pictures from the Picture Library, and Get Thumbnails
@@ -636,7 +519,7 @@ function setOptions(srcType) {
encodingType: Camera.EncodingType.JPEG,
mediaType: Camera.MediaType.PICTURE,
allowEdit: true,
- correctOrientation: true //Corrects Android orientation quirks
+ correctOrientation: true
}
return options;
}
@@ -676,12 +559,6 @@ function displayImage(imgUri) {
}
```
-To display the image on some platforms, you might need to include the main part of the URI in the Content-Security-Policy ` ` element in index.html. For example, on Windows 10, you can include `ms-appdata:` in your ` ` element. Here is an example.
-
-```html
-
-```
-
## Take a Picture and Return Thumbnails (Resize the Picture)
To get smaller images, you can return a resized image by passing both `targetHeight` and `targetWidth` values with your CameraOptions object. In this example, you resize the returned image to fit in a 100px by 100px box (the aspect ratio is maintained, so 100px is either the height or width, whichever is greater in the source).
diff --git a/RELEASENOTES.md b/RELEASENOTES.md
index 9849f4138..8d35c2ceb 100644
--- a/RELEASENOTES.md
+++ b/RELEASENOTES.md
@@ -20,6 +20,142 @@
-->
# Release Notes
+### 7.0.0 (Sep 06, 2023)
+
+**Breaking Changes:**
+
+* [GH-848](https://github.com/apache/cordova-plugin-camera/pull/848) fix!: remove deprecated platforms
+* [GH-844](https://github.com/apache/cordova-plugin-camera/pull/844) feat(android)!: Android 13 support
+
+**Fixes:**
+
+* [GH-827](https://github.com/apache/cordova-plugin-camera/pull/827) fix(android): set `applicationId`
+* [GH-810](https://github.com/apache/cordova-plugin-camera/pull/810) fix(browser): use `navigator.mediaDevices.getUserMedia`
+* [GH-712](https://github.com/apache/cordova-plugin-camera/pull/712) fix(ios): preserving `EXIF` data
+* [GH-780](https://github.com/apache/cordova-plugin-camera/pull/780) fix(android): update queries in `plugin.xml`
+
+**Chores, Dependencies, Docs:**
+
+* [GH-850](https://github.com/apache/cordova-plugin-camera/pull/850) chore: remove windows/osx from `plugin.xml`
+* [GH-849](https://github.com/apache/cordova-plugin-camera/pull/849) chore: Update `SUPPORT_QUESTION.md` template
+* [GH-831](https://github.com/apache/cordova-plugin-camera/pull/831) chore(android): Cleanup obsolete `BuildConfig` comments
+* [GH-846](https://github.com/apache/cordova-plugin-camera/pull/846) dep(dev)!: bump `@cordova/eslint-config@5.0`
+* [GH-800](https://github.com/apache/cordova-plugin-camera/pull/800) dep(npm): bump package-lock v2 w/ rebuild
+* [GH-808](https://github.com/apache/cordova-plugin-camera/pull/808) docs(README): Document `ANDROIDX_CORE_VERSION` variable
+
+**CI:**
+
+* [GH-851](https://github.com/apache/cordova-plugin-camera/pull/851) ci(gh-action): sync with `paramedic` configs
+* [GH-835](https://github.com/apache/cordova-plugin-camera/pull/835) ci(android): Drop API 22 & 31. Added API 24 & 33
+* [GH-804](https://github.com/apache/cordova-plugin-camera/pull/804) ci: sync workflow with `paramedic`
+* [GH-798](https://github.com/apache/cordova-plugin-camera/pull/798) ci(android): update java requirement for `cordova-android@11`
+* [GH-770](https://github.com/apache/cordova-plugin-camera/pull/770) ci(ios): update workflow w/ iOS 15
+* [GH-766](https://github.com/apache/cordova-plugin-camera/pull/766) ci: remove old ci workflow
+* [GH-765](https://github.com/apache/cordova-plugin-camera/pull/765) ci: add action-badge
+* [GH-764](https://github.com/apache/cordova-plugin-camera/pull/764) ci: remove `travis` & `appveyor`
+* [GH-762](https://github.com/apache/cordova-plugin-camera/pull/762) ci: add `gh-actions` workflows
+
+### 6.0.0 (Aug 19, 2021)
+
+**Feature:**
+
+* [GH-751](https://github.com/apache/cordova-plugin-camera/pull/751) feat(android)!: support **AndroidX**
+* [GH-750](https://github.com/apache/cordova-plugin-camera/pull/750) feat(android): bump `cordova-android` requirements for `10.x`
+* [GH-731](https://github.com/apache/cordova-plugin-camera/pull/731) feat(android): encode `heic` format to `EncodingType` for webview display [#711](https://github.com/apache/cordova-plugin-camera/issues/711)
+* [GH-684](https://github.com/apache/cordova-plugin-camera/pull/684) feat(android): `sdk-30` package visibility support
+
+**Fix:**
+
+* [GH-687](https://github.com/apache/cordova-plugin-camera/pull/687) fix(android): return exception message (where it exists)
+* [GH-585](https://github.com/apache/cordova-plugin-camera/pull/585) fix(android): file path correction if `Uri` authority is `FileProvider`
+
+**Chore & CI:**
+
+* [GH-749](https://github.com/apache/cordova-plugin-camera/pull/749) chore: bump plugin version for next major
+* [GH-654](https://github.com/apache/cordova-plugin-camera/pull/654) chore: add release notify action
+* [GH-745](https://github.com/apache/cordova-plugin-camera/pull/745) ci(gh-action): added workflow to run tests
+
+### 5.0.3 (Aug 04, 2021)
+
+* [GH-754](https://github.com/apache/cordova-plugin-camera/pull/754) chore: rebuilt `package-lock.json`
+* [GH-748](https://github.com/apache/cordova-plugin-camera/pull/748) fix: incorrect version in `package-lock`
+* [GH-747](https://github.com/apache/cordova-plugin-camera/pull/747) chore: set the 5.x versions locked to `cordova-android` `<10.0.0`
+* [GH-729](https://github.com/apache/cordova-plugin-camera/pull/729) chore(asf): Update GitHub repo metadata
+
+### 5.0.2 (May 11, 2021)
+* [GH-728](https://github.com/apache/cordova-plugin-camera/pull/728) plugin release preparation - audit fix
+* [GH-700](https://github.com/apache/cordova-plugin-camera/pull/700) Bugfix [issue 665](https://github.com/apache/cordova-plugin-camera/issues/665) - app crashes after taking a picture due to a bug in the camera plugin when app is resumed
+* [GH-691](https://github.com/apache/cordova-plugin-camera/pull/691) ci: add node-14.x to workflow (#691)
+
+### 5.0.1 (Nov 04, 2020)
+
+* [GH-686](https://github.com/apache/cordova-plugin-camera/pull/686) chore(android): add missing apache license header
+* [GH-685](https://github.com/apache/cordova-plugin-camera/pull/685) fix(ios): correctly append exif on **iOS** 14
+* [GH-669](https://github.com/apache/cordova-plugin-camera/pull/669) fix(android): save to photo gallery - fixes issues [#341](https://github.com/apache/cordova-plugin-camera/pull/341) & [#577](https://github.com/apache/cordova-plugin-camera/pull/577)
+* [GH-672](https://github.com/apache/cordova-plugin-camera/pull/672) chore: Fix JIRA links in RELEASENOTES.md
+* [GH-664](https://github.com/apache/cordova-plugin-camera/pull/664) chore: Update RELEASENOTES
+
+### 5.0.0 (Sep 14, 2020)
+
+* [GH-648](https://github.com/apache/cordova-plugin-camera/pull/648) ci(travis): update osx xcode image
+* [GH-637](https://github.com/apache/cordova-plugin-camera/pull/637) breaking: remove `NATIVE_URI` DestinationType
+* [GH-628](https://github.com/apache/cordova-plugin-camera/pull/628) breaking: bump project requirements
+* [GH-634](https://github.com/apache/cordova-plugin-camera/pull/634) chore: remove deprecated `file-transfer` plugin
+* [GH-632](https://github.com/apache/cordova-plugin-camera/pull/632) fix(android): return error if file url is null
+* [GH-510](https://github.com/apache/cordova-plugin-camera/pull/510) fix(android): use provider prefix to avoid conflicts other plugin providers
+* [GH-617](https://github.com/apache/cordova-plugin-camera/pull/617) breaking(android): stop using `CordovaUri` helper class
+* [GH-630](https://github.com/apache/cordova-plugin-camera/pull/630) chore: add `package-lock.json`
+* [GH-631](https://github.com/apache/cordova-plugin-camera/pull/631) chore(package): use short notation
+* [GH-629](https://github.com/apache/cordova-plugin-camera/pull/629) feat: migrate to `@cordova/eslint-config@3.x`
+* [GH-626](https://github.com/apache/cordova-plugin-camera/pull/626) ci: fix additional tests
+* [GH-627](https://github.com/apache/cordova-plugin-camera/pull/627) breaking: bump version 5.0.0-dev
+* [GH-612](https://github.com/apache/cordova-plugin-camera/pull/612) fix(ios): `tempFilePath` called twice if using `CameraUsesGeolocation`
+* [GH-588](https://github.com/apache/cordova-plugin-camera/pull/588) Cache images in device storage, devices have enough space now.
+* [GH-508](https://github.com/apache/cordova-plugin-camera/pull/508) docs(readme): app renamed to Google Photos
+* chore(asf): update git notification settings
+* [GH-580](https://github.com/apache/cordova-plugin-camera/pull/580) fix(ios): return copy of video when picking from gallery on **iOS** 13
+* Update CONTRIBUTING.md
+* [GH-551](https://github.com/apache/cordova-plugin-camera/pull/551) Fix UI API called on a background thread
+* [GH-576](https://github.com/apache/cordova-plugin-camera/pull/576) ci: updates Node.js versions
+* [GH-575](https://github.com/apache/cordova-plugin-camera/pull/575) chore(npm): adds ignore list
+* [GH-513](https://github.com/apache/cordova-plugin-camera/pull/513) docs(README): remove confusing comment
+* [GH-512](https://github.com/apache/cordova-plugin-camera/pull/512) docs(README): remove orphan **Windows** phone 7 note
+* [GH-306](https://github.com/apache/cordova-plugin-camera/pull/306) ImagePicker returning same image
+
+### 4.1.0 (Jun 27, 2019)
+
+- docs: remove outdated test docs translations ([`06dc38f`](https://github.com/apache/cordova-plugin-camera/commit/06dc38f))
+- build: remove `.ratignore` file that is not needed any more ([`5dc9527`](https://github.com/apache/cordova-plugin-camera/commit/5dc9527))
+- chore: fix repo and issue urls and license in package.json and plugin.xml ([`cad8bd1`](https://github.com/apache/cordova-plugin-camera/commit/cad8bd1))
+- fix: temporarily remove Appium tests to unbreak CI ([#468](https://github.com/apache/cordova-plugin-camera/issues/468)) ([`19d8e2f`](https://github.com/apache/cordova-plugin-camera/commit/19d8e2f))
+- ci(travis): Update Travis CI configuration for new paramedic ([#455](https://github.com/apache/cordova-plugin-camera/issues/455)) ([`cffd0ac`](https://github.com/apache/cordova-plugin-camera/commit/cffd0ac))
+- fix(android): Fix NullPointerException error on some Android phones ([#429](https://github.com/apache/cordova-plugin-camera/issues/429)) ([`295e928`](https://github.com/apache/cordova-plugin-camera/commit/295e928))
+- ci: Update CI Environment Setup for Node.js 6 ([#438](https://github.com/apache/cordova-plugin-camera/issues/438)) ([`fae190e`](https://github.com/apache/cordova-plugin-camera/commit/fae190e))
+- refactor(android): Enhancement: Camera plugin code cleanup ([#425](https://github.com/apache/cordova-plugin-camera/issues/425)) ([`a13665d`](https://github.com/apache/cordova-plugin-camera/commit/a13665d))
+- fix(android): Exif data lost on many cases ([#331](https://github.com/apache/cordova-plugin-camera/issues/331)) ([`81b878d`](https://github.com/apache/cordova-plugin-camera/commit/81b878d))
+- chore(github): Add or update GitHub pull request and issue template ([`b261d31`](https://github.com/apache/cordova-plugin-camera/commit/b261d31))
+- fix(ios): fixes UIImagePickerController cancel handling for iOS11+ ([#377](https://github.com/apache/cordova-plugin-camera/issues/377)) ([`24c8b6c`](https://github.com/apache/cordova-plugin-camera/commit/24c8b6c))
+- docs: Remove deprecated platforms from docs ([#394](https://github.com/apache/cordova-plugin-camera/issues/394)) ([`7ddb3df`](https://github.com/apache/cordova-plugin-camera/commit/7ddb3df))
+- fix(android): return DATA_URL for ALLMEDIA if it's an image ([#382](https://github.com/apache/cordova-plugin-camera/issues/382)) ([`60e7795`](https://github.com/apache/cordova-plugin-camera/commit/60e7795))
+- refactor(ios): [CB-13813](https://issues.apache.org/jira/browse/CB-13813): Remove old iOS code ([#381](https://github.com/apache/cordova-plugin-camera/issues/381)) ([`ce77aab`](https://github.com/apache/cordova-plugin-camera/commit/ce77aab))
+- feat(ios): [CB-13865](https://issues.apache.org/jira/browse/CB-13865): (Ipad) Making popover Window Size configurable using popoverOptions - imagePicker ([#314](https://github.com/apache/cordova-plugin-camera/issues/314)) ([`cd72047`](https://github.com/apache/cordova-plugin-camera/commit/cd72047))
+- chore(types): [CB-13837](https://issues.apache.org/jira/browse/CB-13837): fix TypeScript Definition for CameraPopoverOptions ([#379](https://github.com/apache/cordova-plugin-camera/issues/379)) ([`86b0bf2`](https://github.com/apache/cordova-plugin-camera/commit/86b0bf2))
+- docs(android): clarify android quirk of cameraDirection ([`a5a3d88`](https://github.com/apache/cordova-plugin-camera/commit/a5a3d88), [`bfbe4a1`](https://github.com/apache/cordova-plugin-camera/commit/bfbe4a1))
+- chore(release): Bump minor version ([#370](https://github.com/apache/cordova-plugin-camera/issues/370)) ([`eed4433`](https://github.com/apache/cordova-plugin-camera/commit/eed4433))
+- build: Remove automatic README generation ([#365](https://github.com/apache/cordova-plugin-camera/issues/365)) ([`07e8574`](https://github.com/apache/cordova-plugin-camera/commit/07e8574))
+- docs: remove JIRA link ([`bcb26fb`](https://github.com/apache/cordova-plugin-camera/commit/bcb26fb))
+- ci(travis): also accept terms for android sdk `android-27` ([`a346212`](https://github.com/apache/cordova-plugin-camera/commit/a346212))
+- docs: remove outdated docs translations that haven't been touched for 3 years ([`403682b`](https://github.com/apache/cordova-plugin-camera/commit/403682b))
+- fix(android): [CB-14097](https://issues.apache.org/jira/browse/CB-14097): Fix crash when selecting some files with getPicture ([#322](https://github.com/apache/cordova-plugin-camera/issues/322)) ([`5c23b65`](https://github.com/apache/cordova-plugin-camera/commit/5c23b65))
+- fix(browser): [CB-13384](https://issues.apache.org/jira/browse/CB-13384): Added deprecation of video.src compatibility ([#288](https://github.com/apache/cordova-plugin-camera/issues/288)) ([`5163d38`](https://github.com/apache/cordova-plugin-camera/commit/5163d38))
+- fix(browser): Remove audio flag from getUserMedia ([#284](https://github.com/apache/cordova-plugin-camera/issues/284)) ([`36343a8`](https://github.com/apache/cordova-plugin-camera/commit/36343a8))
+- docs: replace warning emoji with warning unicode ([#317](https://github.com/apache/cordova-plugin-camera/issues/317)) ([`ead7d5e`](https://github.com/apache/cordova-plugin-camera/commit/ead7d5e))
+- feat(android): Update engines to use variables ([#323](https://github.com/apache/cordova-plugin-camera/issues/323)) ([`6899c5e`](https://github.com/apache/cordova-plugin-camera/commit/6899c5e))
+- feat(android): [CB-14017](https://issues.apache.org/jira/browse/CB-14017): Make com.android.support:support-v4 version configurable ([#318](https://github.com/apache/cordova-plugin-camera/issues/318)) ([`e334656`](https://github.com/apache/cordova-plugin-camera/commit/e334656))
+- refactor(android): [CB-14047](https://issues.apache.org/jira/browse/CB-14047): CameraLauncher: Replacing Repeated String literals with final variables ([#319](https://github.com/apache/cordova-plugin-camera/issues/319)) ([`5ec121b`](https://github.com/apache/cordova-plugin-camera/commit/5ec121b))
+- fix(windows): [CB-11714](https://issues.apache.org/jira/browse/CB-11714): added extra check for content-type in savePhoto() without options.targetWidth/Height ([#242](https://github.com/apache/cordova-plugin-camera/issues/242)) ([`a201722`](https://github.com/apache/cordova-plugin-camera/commit/a201722), [`dc73954`](https://github.com/apache/cordova-plugin-camera/commit/dc73954), [`dca4b9c`](https://github.com/apache/cordova-plugin-camera/commit/dca4b9c), [`c1b9772`](https://github.com/apache/cordova-plugin-camera/commit/c1b9772), [`eb57b02`](https://github.com/apache/cordova-plugin-camera/commit/eb57b02))
+
+
### 4.0.3 (Apr 12, 2018)
* [CB-12593](https://issues.apache.org/jira/browse/CB-12593) **Android** Fix potential `FileProvider` conflicts
* Fix a mistake in the examples of usage descriptions (#313)
diff --git a/appium-tests/android/android.spec.js b/appium-tests/android/android.spec.js
deleted file mode 100644
index b75698708..000000000
--- a/appium-tests/android/android.spec.js
+++ /dev/null
@@ -1,751 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-// these tests are meant to be executed by Cordova ParaMedic Appium runner
-// you can find it here: https://github.com/apache/cordova-paramedic/
-// it is not necessary to do a full CI setup to run these tests
-// Run:
-// node cordova-paramedic/main.js --platform android --plugin cordova-plugin-camera --skipMainTests --target
-// Please note only Android 5.1 and 4.4 are supported at this point.
-
-'use strict';
-
-var wdHelper = global.WD_HELPER;
-var screenshotHelper = global.SCREENSHOT_HELPER;
-var wd = wdHelper.getWD();
-var cameraConstants = require('../../www/CameraConstants');
-var cameraHelper = require('../helpers/cameraHelper');
-
-var MINUTE = 60 * 1000;
-var BACK_BUTTON = 4;
-var DEFAULT_SCREEN_WIDTH = 360;
-var DEFAULT_SCREEN_HEIGHT = 567;
-var DEFAULT_WEBVIEW_CONTEXT = 'WEBVIEW';
-var PROMISE_PREFIX = 'appium_camera_promise_';
-var CONTEXT_NATIVE_APP = 'NATIVE_APP';
-
-describe('Camera tests Android.', function () {
- var driver;
- // the name of webview context, it will be changed to match needed context if there are named ones:
- var webviewContext = DEFAULT_WEBVIEW_CONTEXT;
- // this indicates that the device library has the test picture:
- var isTestPictureSaved = false;
- // we need to know the screen width and height to properly click on an image in the gallery:
- var screenWidth = DEFAULT_SCREEN_WIDTH;
- var screenHeight = DEFAULT_SCREEN_HEIGHT;
- // promise count to use in promise ID
- var promiseCount = 0;
- // determine if Appium session is created successfully
- var appiumSessionStarted = false;
- // determine if camera is present on the device/emulator
- var cameraAvailable = false;
- // determine if emulator is within a range of acceptable resolutions able to run these tests
- var isResolutionBad = true;
- // a path to the image we add to the gallery before test run
- var fillerImagePath;
- var isAndroid7 = getIsAndroid7();
-
- function getIsAndroid7() {
- if (global.USE_SAUCE) {
- return global.SAUCE_CAPS && (parseFloat(global.SAUCE_CAPS.platformVersion) >= 7);
- } else {
- // this is most likely null, meaning we cannot determine if it is Android 7 or not
- // paramedic needs to be modified to receive and pass the platform version when testing locally
- return global.PLATFORM_VERSION && (parseFloat(global.PLATFORM_VERSION) >= 7);
- }
- }
-
- function getNextPromiseId() {
- promiseCount += 1;
- return getCurrentPromiseId();
- }
-
- function getCurrentPromiseId() {
- return PROMISE_PREFIX + promiseCount;
- }
-
- function gracefullyFail(error) {
- fail(error);
- return driver
- .quit()
- .then(function () {
- return getDriver();
- });
- }
-
- // combinines specified options in all possible variations
- // you can add more options to test more scenarios
- function generateOptions() {
- var sourceTypes = [
- cameraConstants.PictureSourceType.CAMERA,
- cameraConstants.PictureSourceType.PHOTOLIBRARY
- ];
- var destinationTypes = cameraConstants.DestinationType;
- var encodingTypes = cameraConstants.EncodingType;
- var allowEditOptions = [ true, false ];
- var correctOrientationOptions = [ true, false ];
-
- return cameraHelper.generateSpecs(sourceTypes, destinationTypes, encodingTypes, allowEditOptions, correctOrientationOptions);
- }
-
- // invokes Camera.getPicture() with the specified options
- // and goes through all UI interactions unless 'skipUiInteractions' is true
- function getPicture(options, skipUiInteractions) {
- var promiseId = getNextPromiseId();
- if (!options) {
- options = {};
- }
- // assign default values
- if (!options.hasOwnProperty('allowEdit')) {
- options.allowEdit = true;
- }
- if (!options.hasOwnProperty('destinationType')) {
- options.destinationType = cameraConstants.DestinationType.FILE_URI;
- }
- if (!options.hasOwnProperty('sourceType')) {
- options.destinationType = cameraConstants.PictureSourceType.CAMERA;
- }
-
- return driver
- .context(webviewContext)
- .execute(cameraHelper.getPicture, [options, promiseId])
- .context(CONTEXT_NATIVE_APP)
- .then(function () {
- if (skipUiInteractions) {
- return;
- }
- // selecting a picture from gallery
- if (options.hasOwnProperty('sourceType') &&
- (options.sourceType === cameraConstants.PictureSourceType.PHOTOLIBRARY ||
- options.sourceType === cameraConstants.PictureSourceType.SAVEDPHOTOALBUM)) {
- var tapTile = new wd.TouchAction();
- var swipeRight = new wd.TouchAction();
- tapTile
- .tap({
- x: Math.round(screenWidth / 4),
- y: Math.round(screenHeight / 4)
- });
- swipeRight
- .press({x: 10, y: Math.round(screenHeight / 4)})
- .wait(300)
- .moveTo({x: Math.round(screenWidth - (screenWidth / 8)), y: 0})
- .wait(1500)
- .release()
- .wait(1000);
- if (options.allowEdit) {
- return driver
- // always wait before performing touchAction
- .sleep(7000)
- .performTouchAction(tapTile);
- }
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().text("Gallery");', 20000)
- .fail(function () {
- // If the Gallery button is not present, swipe right to reveal the Gallery button!
- return driver
- .performTouchAction(swipeRight)
- .waitForElementByAndroidUIAutomator('new UiSelector().text("Gallery");', 20000)
- })
- .click()
- // always wait before performing touchAction
- .sleep(7000)
- .performTouchAction(tapTile);
- }
- // taking a picture from camera
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*shutter.*")', MINUTE / 2)
- .click()
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*done.*")', MINUTE / 2)
- .click()
- .then(function () {
- if (isAndroid7 && options.allowEdit) {
- return driver
- .elementByAndroidUIAutomator('new UiSelector().text("Crop picture");', 20000)
- .click()
- .fail(function () {
- // don't freak out just yet...
- return driver;
- })
- .elementByAndroidUIAutomator('new UiSelector().text("JUST ONCE");', 20000)
- .click()
- .fail(function () {
- // maybe someone's hit that "ALWAYS" button?
- return driver;
- });
- }
- return driver;
- });
- })
- .then(function () {
- if (skipUiInteractions) {
- return;
- }
- if (options.allowEdit) {
- var saveText = isAndroid7 ? 'SAVE' : 'Save';
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().text("' + saveText + '")', MINUTE)
- .click();
- }
- })
- .fail(function (failure) {
- throw failure;
- });
- }
-
- // checks if the picture was successfully taken
- // if shouldLoad is falsy, ensures that the error callback was called
- function checkPicture(shouldLoad, options) {
- if (!options) {
- options = {};
- }
- return driver
- .context(webviewContext)
- .setAsyncScriptTimeout(MINUTE / 2)
- .executeAsync(cameraHelper.checkPicture, [getCurrentPromiseId(), options, isAndroid7])
- .then(function (result) {
- if (shouldLoad) {
- if (result !== 'OK') {
- fail(result);
- }
- } else if (result.indexOf('ERROR') === -1) {
- throw 'Unexpected success callback with result: ' + result;
- }
- });
- }
-
- // deletes the latest image from the gallery
- function deleteImage() {
- var holdTile = new wd.TouchAction();
- holdTile
- .press({x: Math.round(screenWidth / 4), y: Math.round(screenHeight / 5)})
- .wait(1000)
- .release();
- return driver
- // always wait before performing touchAction
- .sleep(7000)
- .performTouchAction(holdTile)
- .elementByAndroidUIAutomator('new UiSelector().text("Delete")')
- .then(function (element) {
- return element
- .click()
- .elementByAndroidUIAutomator('new UiSelector().text("OK")')
- .click();
- }, function () {
- // couldn't find Delete menu item. Possibly there is no image.
- return driver;
- });
- }
-
- function getDriver() {
- driver = wdHelper.getDriver('Android');
- return driver.getWebviewContext()
- .then(function(context) {
- webviewContext = context;
- return driver.context(webviewContext);
- })
- .waitForDeviceReady()
- .injectLibraries()
- .then(function () {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- return driver
- .then(function () { return getPicture(options, true); })
- .context(CONTEXT_NATIVE_APP)
- // case insensitive select, will be handy with Android 7 support
- .elementByXPath('//android.widget.Button[translate(@text, "alow", "ALOW")="ALLOW"]')
- .click()
- .fail(function noAlert() { })
- .deviceKeyEvent(BACK_BUTTON)
- .sleep(2000)
- .elementById('action_bar_title')
- .then(function () {
- // success means we're still in native app
- return driver
- .deviceKeyEvent(BACK_BUTTON);
- }, function () {
- // error means we're already in webview
- return driver;
- });
- })
- .then(function () {
- // doing it inside a function because otherwise
- // it would not hook up to the webviewContext var change
- // in the first methods of this chain
- return driver.context(webviewContext);
- })
- .deleteFillerImage(fillerImagePath)
- .then(function () {
- fillerImagePath = null;
- })
- .addFillerImage()
- .then(function (result) {
- if (result && result.indexOf('ERROR:') === 0) {
- throw new Error(result);
- } else {
- fillerImagePath = result;
- }
- });
- }
-
- function recreateSession() {
- return driver
- .quit()
- .finally(function () {
- return getDriver();
- });
- }
-
- function tryRunSpec(spec) {
- return driver
- .then(spec)
- .fail(function () {
- return recreateSession()
- .then(spec)
- .fail(function() {
- return recreateSession()
- .then(spec);
- });
- })
- .fail(gracefullyFail);
- }
-
- // produces a generic spec function which
- // takes a picture with specified options
- // and then verifies it
- function generateSpec(options) {
- return function () {
- return driver
- .then(function () {
- return getPicture(options);
- })
- .then(function () {
- return checkPicture(true, options);
- });
- };
- }
-
- function checkSession(done, skipResolutionCheck) {
- if (!appiumSessionStarted) {
- fail('Failed to start a session ' + (lastFailureReason ? lastFailureReason : ''));
- done();
- }
- if (!skipResolutionCheck && isResolutionBad) {
- fail('The resolution of this target device is not within the appropriate range of width: blah-blah and height: bleh-bleh. The target\'s current resolution is: ' + isResolutionBad);
- }
- }
-
- function checkCamera(options, pending) {
- if (!cameraAvailable) {
- pending('Skipping because this test requires a functioning camera on the Android device/emulator, and this test suite\'s functional camera test failed on your target environment.');
- } else if (isAndroid7 && options.allowEdit) {
- // TODO: Check if it is fixed some day
- pending('Skipping because can\'t test with allowEdit=true on Android 7: getting unexpected "Camera cancelled" message.');
- } else if (isAndroid7 && (options.sourceType !== cameraConstants.PictureSourceType.CAMERA)) {
- pending('Skipping because can\'t click on the gallery tile on Android 7.');
- }
- }
-
- afterAll(function (done) {
- checkSession(done);
- driver
- .quit()
- .done(done);
- }, MINUTE);
-
- it('camera.ui.util configuring driver and starting a session', function (done) {
- // retry up to 3 times
- getDriver()
- .fail(function () {
- return getDriver()
- .fail(function () {
- return getDriver()
- .fail(fail);
- });
- })
- .then(function () {
- appiumSessionStarted = true;
- })
- .done(done);
- }, 30 * MINUTE);
-
- it('camera.ui.util determine screen dimensions', function (done) {
- checkSession(done, /*skipResolutionCheck?*/ true); // skip the resolution check here since we are about to find out in this spec!
- driver
- .context(CONTEXT_NATIVE_APP)
- .getWindowSize()
- .then(function (size) {
- screenWidth = Number(size.width);
- screenHeight = Number(size.height);
- isResolutionBad = false;
- /*
- TODO: what are acceptable resolution values?
- need to check what the emulators used in CI return.
- and also what local device definitions work and dont
- */
- })
- .done(done);
- }, MINUTE);
-
- it('camera.ui.util determine camera availability', function (done) {
- checkSession(done);
- var opts = {
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- saveToPhotoAlbum: false
- };
-
- return driver
- .then(function () {
- return getPicture(opts);
- })
- .then(function () {
- cameraAvailable = true;
- }, function () {
- return recreateSession();
- })
- .done(done);
- }, 5 * MINUTE);
-
- describe('Specs.', function () {
- // getPicture() with saveToPhotoLibrary = true
- it('camera.ui.spec.1 Saving a picture to the photo library', function (done) {
- var opts = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- saveToPhotoAlbum: true
- };
- checkSession(done);
- checkCamera(opts, pending);
-
- var spec = generateSpec(opts);
- tryRunSpec(spec)
- .then(function () {
- isTestPictureSaved = true;
- })
- .done(done);
- }, 10 * MINUTE);
-
- // getPicture() with mediaType: VIDEO, sourceType: PHOTOLIBRARY
- it('camera.ui.spec.2 Selecting only videos', function (done) {
- checkSession(done);
- var spec = function () {
- var options = { sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- mediaType: cameraConstants.MediaType.VIDEO };
- return driver
- .then(function () {
- return getPicture(options, true);
- })
- .context(CONTEXT_NATIVE_APP)
- .then(function () {
- // try to find "Gallery" menu item
- // if there's none, the gallery should be already opened
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().text("Gallery")', 20000)
- .then(function (element) {
- return element.click();
- }, function () {
- return driver;
- });
- })
- .then(function () {
- // if the gallery is opened on the videos page,
- // there should be a "Choose video" or "Select video" caption
- var videoSelector = isAndroid7 ? 'new UiSelector().text("Select video")' : 'new UiSelector().text("Choose video")';
- return driver
- .elementByAndroidUIAutomator(videoSelector)
- .fail(function () {
- throw 'Couldn\'t find a "Choose/select video" element.';
- });
- })
- .deviceKeyEvent(BACK_BUTTON)
- .elementByAndroidUIAutomator('new UiSelector().text("Gallery")')
- .deviceKeyEvent(BACK_BUTTON)
- .finally(function () {
- return driver
- .elementById('action_bar_title')
- .then(function () {
- // success means we're still in native app
- return driver
- .deviceKeyEvent(BACK_BUTTON)
- // give native app some time to close
- .sleep(2000)
- // try again! because every ~30th build
- // on Sauce Labs this backbutton doesn't work
- .elementById('action_bar_title')
- .then(function () {
- // success means we're still in native app
- return driver
- .deviceKeyEvent(BACK_BUTTON);
- }, function () {
- // error means we're already in webview
- return driver;
- });
- }, function () {
- // error means we're already in webview
- return driver;
- });
- });
- };
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- // getPicture(), then dismiss
- // wait for the error callback to be called
- it('camera.ui.spec.3 Dismissing the camera', function (done) {
- var options = {
- quality: 50,
- allowEdit: true,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.FILE_URI
- };
- checkSession(done);
- checkCamera(options, pending);
- var spec = function () {
- return driver
- .then(function () {
- return getPicture(options, true);
- })
- .context(CONTEXT_NATIVE_APP)
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*cancel.*")', MINUTE / 2)
- .click()
- .then(function () {
- return checkPicture(false);
- });
- };
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- // getPicture(), then take picture but dismiss the edit
- // wait for the error callback to be called
- it('camera.ui.spec.4 Dismissing the edit', function (done) {
- var options = {
- quality: 50,
- allowEdit: true,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.FILE_URI
- };
- checkSession(done);
- checkCamera(options, pending);
- var spec = function () {
- return driver
- .then(function () {
- return getPicture(options, true);
- })
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*shutter.*")', MINUTE / 2)
- .click()
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*done.*")', MINUTE / 2)
- .click()
- .then(function () {
- if (isAndroid7 && options.allowEdit) {
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().text("Crop picture");', 20000)
- .click()
- .waitForElementByAndroidUIAutomator('new UiSelector().text("JUST ONCE");', 20000)
- .click()
- .deviceKeyEvent(BACK_BUTTON);
- }
- return driver
- .waitForElementByAndroidUIAutomator('new UiSelector().resourceIdMatches(".*discard.*")', MINUTE / 2)
- .click();
- })
- .then(function () {
- return checkPicture(false);
- });
- };
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.5 Verifying target image size, sourceType=CAMERA', function (done) {
- var opts = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- checkSession(done);
- checkCamera(opts, pending);
- var spec = generateSpec(opts);
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.6 Verifying target image size, sourceType=PHOTOLIBRARY', function (done) {
- var opts = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- checkSession(done);
- checkCamera(opts, pending);
- var spec = generateSpec(opts);
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.7 Verifying target image size, sourceType=CAMERA, DestinationType=NATIVE_URI', function (done) {
- var opts = {
- quality: 50,
- allowEdit: true,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.NATIVE_URI,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- checkSession(done);
- checkCamera(opts, pending);
- var spec = generateSpec(opts);
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.8 Verifying target image size, sourceType=PHOTOLIBRARY, DestinationType=NATIVE_URI', function (done) {
- var opts = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- destinationType: cameraConstants.DestinationType.NATIVE_URI,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- checkSession(done);
- checkCamera(opts, pending);
-
- var spec = generateSpec(opts);
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.9 Verifying target image size, sourceType=CAMERA, DestinationType=NATIVE_URI, quality=100', function (done) {
- var opts = {
- quality: 50,
- allowEdit: true,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.NATIVE_URI,
- saveToPhotoAlbum: false,
- targetWidth: 305,
- targetHeight: 305
- };
- checkSession(done);
- checkCamera(opts, pending);
- var spec = generateSpec(opts);
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- it('camera.ui.spec.10 Verifying target image size, sourceType=PHOTOLIBRARY, DestinationType=NATIVE_URI, quality=100', function (done) {
- var opts = {
- quality: 100,
- allowEdit: true,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- destinationType: cameraConstants.DestinationType.NATIVE_URI,
- saveToPhotoAlbum: false,
- targetWidth: 305,
- targetHeight: 305
- };
- checkSession(done);
- checkCamera(opts, pending);
- var spec = generateSpec(opts);
-
- tryRunSpec(spec).done(done);
- }, 10 * MINUTE);
-
- // combine various options for getPicture()
- generateOptions().forEach(function (spec) {
- it('camera.ui.spec.11.' + spec.id + ' Combining options. ' + spec.description, function (done) {
- checkSession(done);
- checkCamera(spec.options, pending);
-
- var s = generateSpec(spec.options);
- tryRunSpec(s).done(done);
- }, 10 * MINUTE);
- });
-
- it('camera.ui.util Delete filler picture from device library', function (done) {
- if (isAndroid7 || global.USE_SAUCE) {
- pending();
- }
- driver
- .context(webviewContext)
- .deleteFillerImage(fillerImagePath)
- .done(done);
- }, MINUTE);
-
- it('camera.ui.util Delete taken picture from device library', function (done) {
- if (isAndroid7 || global.USE_SAUCE) {
- pending();
- }
- checkSession(done);
- if (!isTestPictureSaved) {
- // couldn't save test picture earlier, so nothing to delete here
- done();
- return;
- }
- // delete exactly one latest picture
- // this should be the picture we've taken in the first spec
- driver
- .context(CONTEXT_NATIVE_APP)
- .deviceKeyEvent(BACK_BUTTON)
- .sleep(1000)
- .deviceKeyEvent(BACK_BUTTON)
- .sleep(1000)
- .deviceKeyEvent(BACK_BUTTON)
- .elementById('Apps')
- .click()
- .then(function () {
- return driver
- .elementByXPath('//android.widget.Button[@text="OK"]')
- .click()
- .fail(function () {
- // no cling is all right
- // it is not a brand new emulator, then
- });
- })
- .elementByAndroidUIAutomator('new UiSelector().text("Gallery")')
- .click()
- .elementByAndroidUIAutomator('new UiSelector().textContains("Pictures")')
- .click()
- .then(deleteImage)
- .deviceKeyEvent(BACK_BUTTON)
- .sleep(1000)
- .deviceKeyEvent(BACK_BUTTON)
- .sleep(1000)
- .deviceKeyEvent(BACK_BUTTON)
- .fail(fail)
- .finally(done);
- }, 3 * MINUTE);
- });
-
-});
-
diff --git a/appium-tests/helpers/cameraHelper.js b/appium-tests/helpers/cameraHelper.js
deleted file mode 100644
index 72f7a2700..000000000
--- a/appium-tests/helpers/cameraHelper.js
+++ /dev/null
@@ -1,311 +0,0 @@
-/* global Q, resolveLocalFileSystemURL, Camera, cordova */
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-'use strict';
-
-var cameraConstants = require('../../www/CameraConstants');
-
-function findKeyByValue(set, value) {
- for (var k in set) {
- if (set.hasOwnProperty(k)) {
- if (set[k] == value) {
- return k;
- }
- }
- }
- return undefined;
-}
-
-function getDescription(spec) {
- var desc = '';
-
- desc += 'sourceType: ' + findKeyByValue(cameraConstants.PictureSourceType, spec.options.sourceType);
- desc += ', destinationType: ' + findKeyByValue(cameraConstants.DestinationType, spec.options.destinationType);
- desc += ', encodingType: ' + findKeyByValue(cameraConstants.EncodingType, spec.options.encodingType);
- desc += ', allowEdit: ' + spec.options.allowEdit.toString();
- desc += ', correctOrientation: ' + spec.options.correctOrientation.toString();
-
- return desc;
-}
-
-module.exports.generateSpecs = function (sourceTypes, destinationTypes, encodingTypes, allowEditOptions, correctOrientationOptions) {
- var destinationType,
- sourceType,
- encodingType,
- allowEdit,
- correctOrientation,
- specs = [],
- id = 1;
- for (destinationType in destinationTypes) {
- if (destinationTypes.hasOwnProperty(destinationType)) {
- for (sourceType in sourceTypes) {
- if (sourceTypes.hasOwnProperty(sourceType)) {
- for (encodingType in encodingTypes) {
- if (encodingTypes.hasOwnProperty(encodingType)) {
- for (allowEdit in allowEditOptions) {
- if (allowEditOptions.hasOwnProperty(allowEdit)) {
- for (correctOrientation in correctOrientationOptions) {
- // if taking picture from photolibrary, don't vary 'correctOrientation' option
- if ((sourceTypes[sourceType] === cameraConstants.PictureSourceType.PHOTOLIBRARY ||
- sourceTypes[sourceType] === cameraConstants.PictureSourceType.SAVEDPHOTOALBUM) &&
- correctOrientation === true) { continue; }
- var spec = {
- 'id': id++,
- 'options': {
- 'destinationType': destinationTypes[destinationType],
- 'sourceType': sourceTypes[sourceType],
- 'encodingType': encodingTypes[encodingType],
- 'allowEdit': allowEditOptions[allowEdit],
- 'saveToPhotoAlbum': false,
- 'correctOrientation': correctOrientationOptions[correctOrientation]
- }
- };
- spec.description = getDescription(spec);
- specs.push(spec);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- return specs;
-};
-
-// calls getPicture() and saves the result in promise
-// note that this function is executed in the context of tested app
-// and not in the context of tests
-module.exports.getPicture = function (opts, pid) {
- if (navigator._appiumPromises[pid - 1]) {
- navigator._appiumPromises[pid - 1] = null;
- }
- navigator._appiumPromises[pid] = Q.defer();
- navigator.camera.getPicture(function (result) {
- navigator._appiumPromises[pid].resolve(result);
- }, function (err) {
- navigator._appiumPromises[pid].reject(err);
- }, opts);
-};
-
-// verifies taken picture when the promise is resolved,
-// calls a callback with 'OK' if everything is good,
-// calls a callback with 'ERROR: ' if something is wrong
-// note that this function is executed in the context of tested app
-// and not in the context of tests
-module.exports.checkPicture = function (pid, options, skipContentCheck, cb) {
- var isIos = cordova.platformId === "ios";
- var isAndroid = cordova.platformId === "android";
- // skip image type check if it's unmodified on Android:
- // https://github.com/apache/cordova-plugin-camera/#android-quirks-1
- var skipFileTypeCheckAndroid = isAndroid && options.quality === 100 &&
- !options.targetWidth && !options.targetHeight &&
- !options.correctOrientation;
-
- // Skip image type check if destination is NATIVE_URI and source - device's photoalbum
- // https://github.com/apache/cordova-plugin-camera/#ios-quirks-1
- var skipFileTypeCheckiOS = isIos && options.destinationType === Camera.DestinationType.NATIVE_URI &&
- (options.sourceType === Camera.PictureSourceType.PHOTOLIBRARY ||
- options.sourceType === Camera.PictureSourceType.SAVEDPHOTOALBUM);
-
- var skipFileTypeCheck = skipFileTypeCheckAndroid || skipFileTypeCheckiOS;
-
- var desiredType = 'JPEG';
- var mimeType = 'image/jpeg';
- if (options.encodingType === Camera.EncodingType.PNG) {
- desiredType = 'PNG';
- mimeType = 'image/png';
- }
-
- function errorCallback(msg) {
- if (msg.hasOwnProperty('message')) {
- msg = msg.message;
- }
- cb('ERROR: ' + msg);
- }
-
- // verifies the image we get from plugin
- function verifyResult(result) {
- if (result.length === 0) {
- errorCallback('The result is empty.');
- return;
- } else if (isIos && options.destinationType === Camera.DestinationType.NATIVE_URI && result.indexOf('assets-library:') !== 0) {
- errorCallback('Expected "' + result.substring(0, 150) + '"to start with "assets-library:"');
- return;
- } else if (isIos && options.destinationType === Camera.DestinationType.FILE_URI && result.indexOf('file:') !== 0) {
- errorCallback('Expected "' + result.substring(0, 150) + '"to start with "file:"');
- return;
- }
-
- try {
- window.atob(result);
- // if we got here it is a base64 string (DATA_URL)
- result = "data:" + mimeType + ";base64," + result;
- } catch (e) {
- // not DATA_URL
- if (options.destinationType === Camera.DestinationType.DATA_URL) {
- errorCallback('Expected ' + result.substring(0, 150) + 'not to be DATA_URL');
- return;
- }
- }
-
- try {
- if (result.indexOf('file:') === 0 ||
- result.indexOf('content:') === 0 ||
- result.indexOf('assets-library:') === 0) {
-
- if (!window.resolveLocalFileSystemURL) {
- errorCallback('Cannot read file. Please install cordova-plugin-file to fix this.');
- return;
- }
- if (skipContentCheck) {
- cb('OK');
- return;
- }
- resolveLocalFileSystemURL(result, function (entry) {
- if (skipFileTypeCheck) {
- displayFile(entry);
- } else {
- verifyFile(entry);
- }
- }, function (err) {
- errorCallback(err);
- });
- } else {
- displayImage(result);
- }
- } catch (e) {
- errorCallback(e);
- }
- }
-
- // verifies that the file type matches the requested type
- function verifyFile(entry) {
- try {
- var reader = new FileReader();
- reader.onloadend = function(e) {
- var arr = (new Uint8Array(e.target.result)).subarray(0, 4);
- var header = '';
- for(var i = 0; i < arr.length; i++) {
- header += arr[i].toString(16);
- }
- var actualType = 'unknown';
-
- switch (header) {
- case "89504e47":
- actualType = 'PNG';
- break;
- case 'ffd8ffe0':
- case 'ffd8ffe1':
- case 'ffd8ffe2':
- actualType = 'JPEG';
- break;
- }
-
- if (actualType === desiredType) {
- displayFile(entry);
- } else {
- errorCallback('File type mismatch. Expected ' + desiredType + ', got ' + actualType);
- }
- };
- reader.onerror = function (e) {
- errorCallback(e);
- };
- entry.file(function (file) {
- reader.readAsArrayBuffer(file);
- }, function (e) {
- errorCallback(e);
- });
- } catch (e) {
- errorCallback(e);
- }
- }
-
- // reads the file, then displays the image
- function displayFile(entry) {
- function onFileReceived(file) {
- var reader = new FileReader();
- reader.onerror = function (e) {
- errorCallback(e);
- };
- reader.onloadend = function (evt) {
- displayImage(evt.target.result);
- };
- reader.readAsDataURL(file);
- }
-
- entry.file(onFileReceived, function (e) {
- errorCallback(e);
- });
- }
-
- function displayImage(image) {
- try {
- var imgEl = document.getElementById('camera_test_image');
- if (!imgEl) {
- imgEl = document.createElement('img');
- imgEl.id = 'camera_test_image';
- document.body.appendChild(imgEl);
- }
- var timedOut = false;
- var loadTimeout = setTimeout(function () {
- timedOut = true;
- imgEl.src = '';
- errorCallback('The image did not load: ' + image.substring(0, 150));
- }, 10000);
- var done = function (status) {
- if (!timedOut) {
- clearTimeout(loadTimeout);
- imgEl.src = '';
- cb(status);
- }
- };
- imgEl.onload = function () {
- try {
- // aspect ratio is preserved so only one dimension should match
- if ((typeof options.targetWidth === 'number' && imgEl.naturalWidth !== options.targetWidth) &&
- (typeof options.targetHeight === 'number' && imgEl.naturalHeight !== options.targetHeight))
- {
- done('ERROR: Wrong image size: ' + imgEl.naturalWidth + 'x' + imgEl.naturalHeight +
- '. Requested size: ' + options.targetWidth + 'x' + options.targetHeight);
- } else {
- done('OK');
- }
- } catch (e) {
- errorCallback(e);
- }
- };
- imgEl.src = image;
- } catch (e) {
- errorCallback(e);
- }
- }
-
- navigator._appiumPromises[pid].promise
- .then(function (result) {
- verifyResult(result);
- })
- .fail(function (e) {
- errorCallback(e);
- });
-};
diff --git a/appium-tests/ios/ios.spec.js b/appium-tests/ios/ios.spec.js
deleted file mode 100644
index d4eebdec7..000000000
--- a/appium-tests/ios/ios.spec.js
+++ /dev/null
@@ -1,512 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-// these tests are meant to be executed by Cordova Paramedic test runner
-// you can find it here: https://github.com/apache/cordova-paramedic/
-// it is not necessary to do a full CI setup to run these tests
-// just run "node cordova-paramedic/main.js --platform ios --plugin cordova-plugin-camera"
-
-'use strict';
-
-var wdHelper = global.WD_HELPER;
-var screenshotHelper = global.SCREENSHOT_HELPER;
-var isDevice = global.DEVICE;
-var cameraConstants = require('../../www/CameraConstants');
-var cameraHelper = require('../helpers/cameraHelper');
-
-var MINUTE = 60 * 1000;
-var DEFAULT_WEBVIEW_CONTEXT = 'WEBVIEW_1';
-var PROMISE_PREFIX = 'appium_camera_promise_';
-var CONTEXT_NATIVE_APP = 'NATIVE_APP';
-
-describe('Camera tests iOS.', function () {
- var driver;
- var webviewContext = DEFAULT_WEBVIEW_CONTEXT;
- // promise count to use in promise ID
- var promiseCount = 0;
- // going to set this to false if session is created successfully
- var failedToStart = true;
- // points out which UI automation to use
- var isXCUI = false;
- // spec counter to restart the session
- var specsRun = 0;
-
- function getNextPromiseId() {
- promiseCount += 1;
- return getCurrentPromiseId();
- }
-
- function getCurrentPromiseId() {
- return PROMISE_PREFIX + promiseCount;
- }
-
- function gracefullyFail(error) {
- fail(error);
- return driver
- .quit()
- .then(function () {
- return getDriver();
- });
- }
-
- // generates test specs by combining all the specified options
- // you can add more options to test more scenarios
- function generateOptions() {
- var sourceTypes = cameraConstants.PictureSourceType;
- var destinationTypes = cameraConstants.DestinationType;
- var encodingTypes = cameraConstants.EncodingType;
- var allowEditOptions = [ true, false ];
- var correctOrientationOptions = [ true, false ];
-
- return cameraHelper.generateSpecs(sourceTypes, destinationTypes, encodingTypes, allowEditOptions, correctOrientationOptions);
- }
-
- function usePicture(allowEdit) {
- return driver
- .sleep(10)
- .then(function () {
- if (isXCUI) {
- return driver.waitForElementByAccessibilityId('Choose', MINUTE / 3).click();
- } else {
- if (allowEdit) {
- return wdHelper.tapElementByXPath('//UIAButton[@label="Choose"]', driver);
- }
- return driver.elementByXPath('//*[@label="Use"]').click();
- }
- });
- }
-
- function clickPhoto() {
- if (isXCUI) {
- // iOS >=10
- return driver
- .context(CONTEXT_NATIVE_APP)
- .elementsByXPath('//XCUIElementTypeCell')
- .then(function(photos) {
- if (photos.length == 0) {
- return driver
- .sleep(0) // driver.source is not a function o.O
- .source()
- .then(function (src) {
- console.log(src);
- gracefullyFail('Couldn\'t find an image to click');
- });
- }
- // intentionally clicking the second photo here
- // the first one is not clickable for some reason
- return photos[1].click();
- });
- }
- // iOS <10
- return driver
- .elementByXPath('//UIACollectionCell')
- .click();
- }
-
- function getPicture(options, cancelCamera, skipUiInteractions) {
- var promiseId = getNextPromiseId();
- if (!options) {
- options = {};
- }
- // assign defaults
- if (!options.hasOwnProperty('allowEdit')) {
- options.allowEdit = true;
- }
- if (!options.hasOwnProperty('destinationType')) {
- options.destinationType = cameraConstants.DestinationType.FILE_URI;
- }
- if (!options.hasOwnProperty('sourceType')) {
- options.destinationType = cameraConstants.PictureSourceType.CAMERA;
- }
-
- return driver
- .context(webviewContext)
- .execute(cameraHelper.getPicture, [options, promiseId])
- .context(CONTEXT_NATIVE_APP)
- .then(function () {
- if (skipUiInteractions) {
- return;
- }
- if (options.hasOwnProperty('sourceType') && options.sourceType === cameraConstants.PictureSourceType.PHOTOLIBRARY) {
- return driver
- .waitForElementByAccessibilityId('Camera Roll', MINUTE / 2)
- .click()
- .then(function () {
- return clickPhoto();
- })
- .then(function () {
- if (!options.allowEdit) {
- return driver;
- }
- return usePicture(options.allowEdit);
- });
- }
- if (options.hasOwnProperty('sourceType') && options.sourceType === cameraConstants.PictureSourceType.SAVEDPHOTOALBUM) {
- return clickPhoto()
- .then(function () {
- if (!options.allowEdit) {
- return driver;
- }
- return usePicture(options.allowEdit);
- });
- }
- if (cancelCamera) {
- return driver
- .waitForElementByAccessibilityId('Cancel', MINUTE / 2)
- .click();
- }
- return driver
- .waitForElementByAccessibilityId('Take Picture', MINUTE / 2)
- .click()
- .waitForElementByAccessibilityId('Use Photo', MINUTE / 2)
- .click();
- })
- .fail(fail);
- }
-
- // checks if the picture was successfully taken
- // if shouldLoad is falsy, ensures that the error callback was called
- function checkPicture(shouldLoad, options) {
- if (!options) {
- options = {};
- }
- return driver
- .context(webviewContext)
- .setAsyncScriptTimeout(MINUTE / 2)
- .executeAsync(cameraHelper.checkPicture, [getCurrentPromiseId(), options, false])
- .then(function (result) {
- if (shouldLoad) {
- if (result !== 'OK') {
- fail(result);
- }
- } else if (result.indexOf('ERROR') === -1) {
- throw 'Unexpected success callback with result: ' + result;
- }
- });
- }
-
- // takes a picture with the specified options
- // and then verifies it
- function runSpec(options, done, pending) {
- if (options.sourceType === cameraConstants.PictureSourceType.CAMERA && !isDevice) {
- pending('Camera is not available on iOS simulator');
- }
- checkSession(done);
- specsRun += 1;
- return driver
- .then(function () {
- return getPicture(options);
- })
- .then(function () {
- return checkPicture(true, options);
- })
- .fail(gracefullyFail);
- }
-
- function getDriver() {
- failedToStart = true;
- driver = wdHelper.getDriver('iOS');
- return wdHelper.getWebviewContext(driver)
- .then(function(context) {
- webviewContext = context;
- return driver.context(webviewContext);
- })
- .then(function () {
- return wdHelper.waitForDeviceReady(driver);
- })
- .then(function () {
- return wdHelper.injectLibraries(driver);
- })
- .sessionCapabilities()
- .then(function (caps) {
- var platformVersion = parseFloat(caps.platformVersion);
- isXCUI = platformVersion >= 10.0;
- })
- .then(function () {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
- return driver
- .then(function () { return getPicture(options, false, true); })
- .context(CONTEXT_NATIVE_APP)
- .acceptAlert()
- .then(function alertDismissed() {
- // TODO: once we move to only XCUITest-based (which is force on you in either iOS 10+ or Xcode 8+)
- // UI tests, we will have to:
- // a) remove use of autoAcceptAlerts appium capability since it no longer functions in XCUITest
- // b) can remove this entire then() clause, as we do not need to explicitly handle the acceptAlert
- // failure callback, since we will be guaranteed to hit the permission dialog on startup.
- }, function noAlert() {
- // in case the contacts permission alert never showed up: no problem, don't freak out.
- // This can happen if:
- // a) The application-under-test already had photos permissions granted to it
- // b) Appium's autoAcceptAlerts capability is provided (and functioning)
- })
- .elementByAccessibilityId('Cancel', 10000)
- .click();
- })
- .then(function () {
- failedToStart = false;
- });
- }
-
- function checkSession(done) {
- if (failedToStart) {
- fail('Failed to start a session');
- done();
- }
- }
-
- it('camera.ui.util configure driver and start a session', function (done) {
- // retry up to 3 times
- getDriver()
- .fail(function () {
- return getDriver()
- .fail(function () {
- return getDriver()
- .fail(fail);
- });
- })
- .fail(fail)
- .done(done);
- }, 30 * MINUTE);
-
- describe('Specs.', function () {
- afterEach(function (done) {
- if (specsRun >= 19) {
- specsRun = 0;
- // we need to restart the session regularly because for some reason
- // when running against iOS 10 simulator on SauceLabs,
- // Appium cannot handle more than ~20 specs at one session
- // the error would be as follows:
- // "Could not proxy command to remote server. Original error: Error: connect ECONNREFUSED 127.0.0.1:8100"
- checkSession(done);
- return driver
- .quit()
- .then(function () {
- return getDriver()
- .fail(function () {
- return getDriver()
- .fail(function () {
- return getDriver()
- .fail(fail);
- });
- });
- })
- .done(done);
- } else {
- done();
- }
- }, 30 * MINUTE);
-
- // getPicture() with mediaType: VIDEO, sourceType: PHOTOLIBRARY
- it('camera.ui.spec.1 Selecting only videos', function (done) {
- checkSession(done);
- specsRun += 1;
- var options = { sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- mediaType: cameraConstants.MediaType.VIDEO };
- driver
- // skip ui unteractions
- .then(function () { return getPicture(options, false, true); })
- .waitForElementByXPath('//*[contains(@label,"Videos")]', MINUTE / 2)
- .elementByAccessibilityId('Cancel')
- .click()
- .fail(gracefullyFail)
- .done(done);
- }, 7 * MINUTE);
-
- // getPicture(), then dismiss
- // wait for the error callback to be called
- it('camera.ui.spec.2 Dismissing the camera', function (done) {
- checkSession(done);
- if (!isDevice) {
- pending('Camera is not available on iOS simulator');
- }
- specsRun += 1;
- var options = { sourceType: cameraConstants.PictureSourceType.CAMERA,
- saveToPhotoAlbum: false };
- driver
- .then(function () {
- return getPicture(options, true);
- })
- .then(function () {
- return checkPicture(false);
- })
- .fail(gracefullyFail)
- .done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.3 Verifying target image size, sourceType=CAMERA', function (done) {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.4 Verifying target image size, sourceType=SAVEDPHOTOALBUM', function (done) {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.5 Verifying target image size, sourceType=PHOTOLIBRARY', function (done) {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.6 Verifying target image size, sourceType=CAMERA, destinationType=FILE_URL', function (done) {
- // remove this line if you don't mind the tests leaving a photo saved on device
- pending('Cannot prevent iOS from saving the picture to photo library');
-
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.7 Verifying target image size, sourceType=SAVEDPHOTOALBUM, destinationType=FILE_URL', function (done) {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.8 Verifying target image size, sourceType=PHOTOLIBRARY, destinationType=FILE_URL', function (done) {
- var options = {
- quality: 50,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 210,
- targetHeight: 210
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.9 Verifying target image size, sourceType=CAMERA, destinationType=FILE_URL, quality=100', function (done) {
- // remove this line if you don't mind the tests leaving a photo saved on device
- pending('Cannot prevent iOS from saving the picture to photo library');
-
- var options = {
- quality: 100,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.CAMERA,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 305,
- targetHeight: 305
- };
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.10 Verifying target image size, sourceType=SAVEDPHOTOALBUM, destinationType=FILE_URL, quality=100', function (done) {
- var options = {
- quality: 100,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 305,
- targetHeight: 305
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- it('camera.ui.spec.11 Verifying target image size, sourceType=PHOTOLIBRARY, destinationType=FILE_URL, quality=100', function (done) {
- var options = {
- quality: 100,
- allowEdit: false,
- sourceType: cameraConstants.PictureSourceType.PHOTOLIBRARY,
- destinationType: cameraConstants.DestinationType.FILE_URL,
- saveToPhotoAlbum: false,
- targetWidth: 305,
- targetHeight: 305
- };
-
- runSpec(options, done, pending).done(done);
- }, 7 * MINUTE);
-
- // combine various options for getPicture()
- generateOptions().forEach(function (spec) {
- it('camera.ui.spec.12.' + spec.id + ' Combining options. ' + spec.description, function (done) {
- // remove this check if you don't mind the tests leaving a photo saved on device
- if (spec.options.sourceType === cameraConstants.PictureSourceType.CAMERA &&
- spec.options.destinationType === cameraConstants.DestinationType.NATIVE_URI) {
- pending('Skipping: cannot prevent iOS from saving the picture to photo library and cannot delete it. ' +
- 'For more info, see iOS quirks here: https://github.com/apache/cordova-plugin-camera#ios-quirks-1');
- }
-
- runSpec(spec.options, done, pending).done(done);
- }, 7 * MINUTE);
- });
-
- });
-
- it('camera.ui.util Destroy the session', function (done) {
- checkSession(done);
- driver
- .quit()
- .done(done);
- }, 5 * MINUTE);
-});
diff --git a/doc/de/README.md b/doc/de/README.md
deleted file mode 100644
index 97e6526a8..000000000
--- a/doc/de/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-Dieses Plugin definiert eine globale `navigator.camera`-Objekt, das eine API für Aufnahmen und für die Auswahl der Bilder aus dem System-Image-Library bietet.
-
-Obwohl das Objekt mit der globalen Gültigkeitsbereich `navigator` verbunden ist, steht es nicht bis nach dem `Deviceready`-Ereignis.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Installation
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * Kamera
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-Nimmt ein Foto mit der Kamera, oder ein Foto aus dem Gerät Bildergalerie abgerufen. Das Bild wird an den Erfolg-Rückruf als base64-codierte `String` oder als URI für die Image-Datei übergeben. Die Methode selbst gibt ein `CameraPopoverHandle`-Objekt, das verwendet werden kann, um die Datei-Auswahl-Popover neu zu positionieren.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### Beschreibung
-
-Die `camera.getPicture`-Funktion öffnet das Gerät Standard-Kamera-Anwendung, die Benutzern ermöglicht, Bilder ausrichten. Dieses Verhalten tritt in der Standardeinstellung, wenn `Camera.sourceType` `Camera.PictureSourceType.CAMERA` entspricht. Sobald der Benutzer die Fotoschnäpper, die Kameraanwendung geschlossen wird und die Anwendung wird wiederhergestellt.
-
-Wenn `Camera.sourceType` `Camera.PictureSourceType.PHOTOLIBRARY` oder `Camera.PictureSourceType.SAVEDPHOTOALBUM` ist, dann wird ein Dialogfeld angezeigt, das Benutzern ermöglicht, ein vorhandenes Bild auszuwählen. Die `camera.getPicture`-Funktion gibt ein `CameraPopoverHandle`-Objekt, das verwendet werden kann, um die Bild-Auswahl-Dialog, z. B. beim ändert sich der Orientierung des Geräts neu positionieren.
-
-Der Rückgabewert wird an die `cameraSuccess`-Callback-Funktion in einem der folgenden Formate, je nach dem angegebenen `cameraOptions` gesendet:
-
- * A `String` mit dem base64-codierte Foto-Bild.
-
- * A `String` , die die Bild-Datei-Stelle auf lokalem Speicher (Standard).
-
-Sie können tun, was Sie wollen, mit dem codierten Bildes oder URI, zum Beispiel:
-
- * Rendern Sie das Bild in ein ` ` Tag, wie im folgenden Beispiel
-
- * Die Daten lokal zu speichern ( `LocalStorage` , [Lawnchair](http://brianleroux.github.com/lawnchair/), etc..)
-
- * Post die Daten an einen entfernten server
-
-**Hinweis**: Fotoauflösung auf neueren Geräten ist ganz gut. Fotos aus dem Gerät Galerie ausgewählt sind nicht zu einer niedrigeren Qualität herunterskaliert, selbst wenn ein `Qualität`-Parameter angegeben wird. Um Speicherprobleme zu vermeiden, legen Sie `Camera.destinationType` auf `FILE_URI` statt `DATA_URL`.
-
-#### Unterstützte Plattformen
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### Beispiel
-
-Nehmen Sie ein Foto und rufen Sie sie als base64-codierte Bild:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Nehmen Sie ein Foto und rufen Sie das Bild-Datei-Speicherort:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### "Einstellungen" (iOS)
-
- * **CameraUsesGeolocation** (Boolean, Standardwert ist False). Zur Erfassung von JPEGs, auf true festgelegt, um Geolocation-Daten im EXIF-Header zu erhalten. Dies löst einen Antrag auf Geolocation-Berechtigungen, wenn auf True festgelegt.
-
-
-
-
-#### Amazon Fire OS Macken
-
-Amazon Fire OS verwendet Absichten zum Starten von der Kamera-Aktivität auf dem Gerät, um Bilder zu erfassen und auf Handys mit wenig Speicher, Cordova Tätigkeit getötet werden kann. In diesem Szenario kann das Bild nicht angezeigt, wenn die Aktivität von Cordova wiederhergestellt wird.
-
-#### Android Eigenarten
-
-Android verwendet Absichten zum Starten von der Kamera-Aktivität auf dem Gerät, um Bilder zu erfassen und auf Handys mit wenig Speicher, Cordova Tätigkeit getötet werden kann. In diesem Szenario kann das Bild nicht angezeigt, wenn die Aktivität von Cordova wiederhergestellt wird.
-
-#### Browser-Eigenheiten
-
-Fotos können nur als base64-codierte Bild zurückgeben werden.
-
-#### Firefox OS Macken
-
-Kamera-Plugin ist derzeit implementiert mithilfe von [Web-Aktivitäten](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### iOS Macken
-
-Einschließlich einer JavaScript-`alert()` entweder Rückruffunktionen kann Probleme verursachen. Wickeln Sie die Warnung innerhalb eine `setTimeout()` erlauben die iOS-Bild-Picker oder Popover vollständig zu schließen, bevor die Warnung angezeigt:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 Macken
-
-Die native Kameraanwendung aufrufen, während das Gerät via Zune angeschlossen ist funktioniert nicht und löst eine Fehler-Callback.
-
-#### Tizen Macken
-
-Tizen unterstützt nur ein `DestinationType` von `Camera.DestinationType.FILE_URI` und ein `SourceType` von `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-## CameraOptions
-
-Optionale Parameter die Kameraeinstellungen anpassen.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **Qualität**: Qualität des gespeicherten Bildes, ausgedrückt als ein Bereich von 0-100, wo 100 in der Regel voller Auflösung ohne Verlust aus der Dateikomprimierung ist. Der Standardwert ist 50. *(Anzahl)* (Beachten Sie, dass Informationen über die Kamera Auflösung nicht verfügbar ist.)
-
- * **DestinationType**: Wählen Sie das Format des Rückgabewerts. Der Standardwert ist FILE_URI. Im Sinne `navigator.camera.DestinationType` *(Anzahl)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **SourceType**: Legen Sie die Quelle des Bildes. Der Standardwert ist die Kamera. Im Sinne `navigator.camera.PictureSourceType` *(Anzahl)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **AllowEdit**: einfache Bearbeitung des Bildes vor Auswahl zu ermöglichen. *(Boolesch)*
-
- * **EncodingType**: die zurückgegebene Image-Datei ist Codierung auswählen. Standardwert ist JPEG. Im Sinne `navigator.camera.EncodingType` *(Anzahl)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **TargetWidth**: Breite in Pixel zum Bild skalieren. Muss mit **TargetHeight**verwendet werden. Seitenverhältnis bleibt konstant. *(Anzahl)*
-
- * **TargetHeight**: Höhe in Pixel zum Bild skalieren. Muss mit **TargetWidth**verwendet werden. Seitenverhältnis bleibt konstant. *(Anzahl)*
-
- * **MediaType**: Legen Sie den Typ der Medien zur Auswahl. Funktioniert nur, wenn `PictureSourceType` ist `PHOTOLIBRARY` oder `SAVEDPHOTOALBUM` . Im Sinne `nagivator.camera.MediaType` *(Anzahl)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. STANDARD. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **CorrectOrientation**: Drehen Sie das Bild um die Ausrichtung des Geräts während der Aufnahme zu korrigieren. *(Boolesch)*
-
- * **SaveToPhotoAlbum**: das Bild auf das Fotoalbum auf dem Gerät zu speichern, nach Einnahme. *(Boolesch)*
-
- * **PopoverOptions**: iOS-nur Optionen, die Popover Lage in iPad angeben. In definierten`CameraPopoverOptions`.
-
- * **CameraDirection**: Wählen Sie die Kamera (vorn oder hinten-gerichtete) verwenden. Der Standardwert ist zurück. Im Sinne `navigator.camera.Direction` *(Anzahl)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### Amazon Fire OS Macken
-
- * `cameraDirection`Ergebnisse in einem hinten gerichteter Foto Wert.
-
- * Ignoriert die `allowEdit` Parameter.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`und `Camera.PictureSourceType.SAVEDPHOTOALBUM` beide das gleiche Fotoalbum anzuzeigen.
-
-#### Android Eigenarten
-
- * `cameraDirection`Ergebnisse in einem hinten gerichteter Foto Wert.
-
- * Android verwendet auch die Ernte-Aktivität für AllowEdit, obwohl Ernte sollte arbeiten und das zugeschnittene Bild zurück zu Cordova, das einzige, dass Werke konsequent die gebündelt mit der Google-Plus-Fotos-Anwendung ist tatsächlich zu übergeben. Andere Kulturen funktioniert möglicherweise nicht.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`und `Camera.PictureSourceType.SAVEDPHOTOALBUM` beide das gleiche Fotoalbum anzuzeigen.
-
-#### BlackBerry 10 Macken
-
- * Ignoriert die `quality` Parameter.
-
- * Ignoriert die `allowEdit` Parameter.
-
- * `Camera.MediaType`wird nicht unterstützt.
-
- * Ignoriert die `correctOrientation` Parameter.
-
- * Ignoriert die `cameraDirection` Parameter.
-
-#### Firefox OS Macken
-
- * Ignoriert die `quality` Parameter.
-
- * `Camera.DestinationType`wird ignoriert, und gleich `1` (Bilddatei-URI)
-
- * Ignoriert die `allowEdit` Parameter.
-
- * Ignoriert die `PictureSourceType` Parameter (Benutzer wählt es in einem Dialogfenster)
-
- * Ignoriert die`encodingType`
-
- * Ignoriert die `targetWidth` und`targetHeight`
-
- * `Camera.MediaType`wird nicht unterstützt.
-
- * Ignoriert die `correctOrientation` Parameter.
-
- * Ignoriert die `cameraDirection` Parameter.
-
-#### iOS Macken
-
- * Legen Sie `quality` unter 50 Speicherfehler auf einigen Geräten zu vermeiden.
-
- * Bei der Verwendung `destinationType.FILE_URI` , Fotos werden im temporären Verzeichnis der Anwendung gespeichert. Den Inhalt des temporären Verzeichnis der Anwendung wird gelöscht, wenn die Anwendung beendet.
-
-#### Tizen Macken
-
- * nicht unterstützte Optionen
-
- * gibt immer einen Datei-URI
-
-#### Windows Phone 7 und 8 Eigenarten
-
- * Ignoriert die `allowEdit` Parameter.
-
- * Ignoriert die `correctOrientation` Parameter.
-
- * Ignoriert die `cameraDirection` Parameter.
-
- * Ignoriert die `saveToPhotoAlbum` Parameter. WICHTIG: Alle Aufnahmen die wp7/8 Cordova-Kamera-API werden immer in Kamerarolle des Telefons kopiert. Abhängig von den Einstellungen des Benutzers könnte dies auch bedeuten, dass das Bild in ihre OneDrive automatisch hochgeladen ist. Dies könnte möglicherweise bedeuten, dass das Bild für ein breiteres Publikum als Ihre Anwendung vorgesehen ist. Wenn diese einen Blocker für Ihre Anwendung, Sie müssen die CameraCaptureTask zu implementieren, wie im Msdn dokumentiert: Sie können kommentieren oder Up-Abstimmung das Beiträge zu diesem Thema im [Bugtracker](https://issues.apache.org/jira/browse/CB-2083)
-
- * Ignoriert die `mediaType` -Eigenschaft des `cameraOptions` wie das Windows Phone SDK keine Möglichkeit, Fotothek Videos wählen.
-
-## CameraError
-
-onError-Callback-Funktion, die eine Fehlermeldung bereitstellt.
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### Beschreibung
-
- * **Meldung**: die Nachricht wird durch das Gerät systemeigenen Code bereitgestellt. *(String)*
-
-## cameraSuccess
-
-onSuccess Callback-Funktion, die die Bilddaten bereitstellt.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### Beschreibung
-
- * **CMYK**: Base64-Codierung der Bilddaten, *oder* die Image-Datei-URI, je nach `cameraOptions` in Kraft. *(String)*
-
-#### Beispiel
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Ein Handle für das Dialogfeld "Popover" erstellt von `navigator.camera.getPicture`.
-
-#### Beschreibung
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### Unterstützte Plattformen
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Beispiel
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-nur iOS-Parametern, die Anker-Element Lage und Pfeil Richtung der Popover angeben, bei der Auswahl von Bildern aus einem iPad Bibliothek oder Album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### Beschreibung
-
- * **X**: x Pixelkoordinate des Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
- * **y**: y Pixelkoordinate des Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
- * **width**: Breite in Pixeln, das Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
- * **height**: Höhe in Pixeln, das Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
- * **arrowDir**: Richtung der Pfeil auf der Popover zeigen sollte. Im Sinne `Camera.PopoverArrowDirection` *(Anzahl)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Beachten Sie, dass die Größe der Popover ändern kann, um die Richtung des Pfeils und Ausrichtung des Bildschirms anzupassen. Achten Sie darauf, um Orientierung zu berücksichtigen, wenn Sie den Anker-Element-Speicherort angeben.
-
-## navigator.camera.cleanup
-
-Entfernt Mittelstufe Fotos von der Kamera aus der vorübergehenden Verwahrung genommen.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### Beschreibung
-
-Fortgeschrittene Image-Dateien, die in vorübergehender Verwahrung gehalten werden, nach dem Aufruf von `camera.getPicture` entfernt. Gilt nur wenn der Wert von `Camera.sourceType` gleich `Camera.PictureSourceType.CAMERA` und `Camera.destinationType` gleich `Camera.DestinationType.FILE_URI`.
-
-#### Unterstützte Plattformen
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Beispiel
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/de/index.md b/doc/de/index.md
deleted file mode 100644
index 1c7486cec..000000000
--- a/doc/de/index.md
+++ /dev/null
@@ -1,434 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Dieses Plugin definiert eine globale `navigator.camera`-Objekt, das eine API für Aufnahmen und für die Auswahl der Bilder aus dem System-Image-Library bietet.
-
-Obwohl das Objekt mit der globalen Gültigkeitsbereich `navigator` verbunden ist, steht es nicht bis nach dem `Deviceready`-Ereignis.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Installation
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Nimmt ein Foto mit der Kamera, oder ein Foto aus dem Gerät Bildergalerie abgerufen. Das Bild wird an den Erfolg-Rückruf als base64-codierte `String` oder als URI für die Image-Datei übergeben. Die Methode selbst gibt ein `CameraPopoverHandle`-Objekt, das verwendet werden kann, um die Datei-Auswahl-Popover neu zu positionieren.
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### Beschreibung
-
-Die `camera.getPicture`-Funktion öffnet das Gerät Standard-Kamera-Anwendung, die Benutzern ermöglicht, Bilder ausrichten. Dieses Verhalten tritt in der Standardeinstellung, wenn `Camera.sourceType` `Camera.PictureSourceType.CAMERA` entspricht. Sobald der Benutzer die Fotoschnäpper, die Kameraanwendung geschlossen wird und die Anwendung wird wiederhergestellt.
-
-Wenn `Camera.sourceType` `Camera.PictureSourceType.PHOTOLIBRARY` oder `Camera.PictureSourceType.SAVEDPHOTOALBUM` ist, dann wird ein Dialogfeld angezeigt, das Benutzern ermöglicht, ein vorhandenes Bild auszuwählen. Die `camera.getPicture`-Funktion gibt ein `CameraPopoverHandle`-Objekt, das verwendet werden kann, um die Bild-Auswahl-Dialog, z. B. beim ändert sich der Orientierung des Geräts neu positionieren.
-
-Der Rückgabewert wird an die `cameraSuccess`-Callback-Funktion in einem der folgenden Formate, je nach dem angegebenen `cameraOptions` gesendet:
-
-* A `String` mit dem base64-codierte Foto-Bild.
-
-* A `String` , die die Bild-Datei-Stelle auf lokalem Speicher (Standard).
-
-Sie können tun, was Sie wollen, mit dem codierten Bildes oder URI, zum Beispiel:
-
-* Rendern Sie das Bild in ein ` ` Tag, wie im folgenden Beispiel
-
-* Die Daten lokal zu speichern ( `LocalStorage` , [Lawnchair][1], etc..)
-
-* Post die Daten an einen entfernten server
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**Hinweis**: Fotoauflösung auf neueren Geräten ist ganz gut. Fotos aus dem Gerät Galerie ausgewählt sind nicht zu einer niedrigeren Qualität herunterskaliert, selbst wenn ein `Qualität`-Parameter angegeben wird. Um Speicherprobleme zu vermeiden, legen Sie `Camera.destinationType` auf `FILE_URI` statt `DATA_URL`.
-
-### Unterstützte Plattformen
-
-* Amazon Fire OS
-* Android
-* BlackBerry 10
-* Browser
-* Firefox OS
-* iOS
-* Tizen
-* Windows Phone 7 und 8
-* Windows 8
-
-### "Einstellungen" (iOS)
-
-* **CameraUsesGeolocation** (Boolean, Standardwert ist False). Zur Erfassung von JPEGs, auf true festgelegt, um Geolocation-Daten im EXIF-Header zu erhalten. Dies löst einen Antrag auf Geolocation-Berechtigungen, wenn auf True festgelegt.
-
-
-
-
-### Amazon Fire OS Macken
-
-Amazon Fire OS verwendet Absichten zum Starten von der Kamera-Aktivität auf dem Gerät, um Bilder zu erfassen und auf Handys mit wenig Speicher, Cordova Tätigkeit getötet werden kann. In diesem Szenario kann das Bild nicht angezeigt, wenn die Aktivität von Cordova wiederhergestellt wird.
-
-### Android Eigenarten
-
-Android verwendet Absichten zum Starten von der Kamera-Aktivität auf dem Gerät, um Bilder zu erfassen und auf Handys mit wenig Speicher, Cordova Tätigkeit getötet werden kann. In diesem Szenario kann das Bild nicht angezeigt, wenn die Aktivität von Cordova wiederhergestellt wird.
-
-### Browser-Eigenheiten
-
-Fotos können nur als base64-codierte Bild zurückgeben werden.
-
-### Firefox OS Macken
-
-Kamera-Plugin ist derzeit implementiert mithilfe von [Web-Aktivitäten][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS Macken
-
-Einschließlich einer JavaScript-`alert()` entweder Rückruffunktionen kann Probleme verursachen. Wickeln Sie die Warnung innerhalb eine `setTimeout()` erlauben die iOS-Bild-Picker oder Popover vollständig zu schließen, bevor die Warnung angezeigt:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Windows Phone 7 Macken
-
-Die native Kameraanwendung aufrufen, während das Gerät via Zune angeschlossen ist funktioniert nicht und löst eine Fehler-Callback.
-
-### Tizen Macken
-
-Tizen unterstützt nur ein `DestinationType` von `Camera.DestinationType.FILE_URI` und ein `SourceType` von `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Beispiel
-
-Nehmen Sie ein Foto und rufen Sie sie als base64-codierte Bild:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Nehmen Sie ein Foto und rufen Sie das Bild-Datei-Speicherort:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-Optionale Parameter die Kameraeinstellungen anpassen.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### Optionen
-
-* **Qualität**: Qualität des gespeicherten Bildes, ausgedrückt als ein Bereich von 0-100, wo 100 in der Regel voller Auflösung ohne Verlust aus der Dateikomprimierung ist. Der Standardwert ist 50. *(Anzahl)* (Beachten Sie, dass Informationen über die Kamera Auflösung nicht verfügbar ist.)
-
-* **DestinationType**: Wählen Sie das Format des Rückgabewerts. Der Standardwert ist FILE_URI. Im Sinne `navigator.camera.DestinationType` *(Anzahl)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **SourceType**: Legen Sie die Quelle des Bildes. Der Standardwert ist die Kamera. Im Sinne `navigator.camera.PictureSourceType` *(Anzahl)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **AllowEdit**: einfache Bearbeitung des Bildes vor Auswahl zu ermöglichen. *(Boolesch)*
-
-* **EncodingType**: die zurückgegebene Image-Datei ist Codierung auswählen. Standardwert ist JPEG. Im Sinne `navigator.camera.EncodingType` *(Anzahl)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **TargetWidth**: Breite in Pixel zum Bild skalieren. Muss mit **TargetHeight**verwendet werden. Seitenverhältnis bleibt konstant. *(Anzahl)*
-
-* **TargetHeight**: Höhe in Pixel zum Bild skalieren. Muss mit **TargetWidth**verwendet werden. Seitenverhältnis bleibt konstant. *(Anzahl)*
-
-* **MediaType**: Legen Sie den Typ der Medien zur Auswahl. Funktioniert nur, wenn `PictureSourceType` ist `PHOTOLIBRARY` oder `SAVEDPHOTOALBUM` . Im Sinne `nagivator.camera.MediaType` *(Anzahl)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. STANDARD. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **CorrectOrientation**: Drehen Sie das Bild um die Ausrichtung des Geräts während der Aufnahme zu korrigieren. *(Boolesch)*
-
-* **SaveToPhotoAlbum**: das Bild auf das Fotoalbum auf dem Gerät zu speichern, nach Einnahme. *(Boolesch)*
-
-* **PopoverOptions**: iOS-nur Optionen, die Popover Lage in iPad angeben. In definierten`CameraPopoverOptions`.
-
-* **CameraDirection**: Wählen Sie die Kamera (vorn oder hinten-gerichtete) verwenden. Der Standardwert ist zurück. Im Sinne `navigator.camera.Direction` *(Anzahl)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Amazon Fire OS Macken
-
-* `cameraDirection`Ergebnisse in einem hinten gerichteter Foto Wert.
-
-* Ignoriert die `allowEdit` Parameter.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`und `Camera.PictureSourceType.SAVEDPHOTOALBUM` beide das gleiche Fotoalbum anzuzeigen.
-
-### Android Eigenarten
-
-* `cameraDirection`Ergebnisse in einem hinten gerichteter Foto Wert.
-
-* Ignoriert die `allowEdit` Parameter.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`und `Camera.PictureSourceType.SAVEDPHOTOALBUM` beide das gleiche Fotoalbum anzuzeigen.
-
-### BlackBerry 10 Macken
-
-* Ignoriert die `quality` Parameter.
-
-* Ignoriert die `allowEdit` Parameter.
-
-* `Camera.MediaType`wird nicht unterstützt.
-
-* Ignoriert die `correctOrientation` Parameter.
-
-* Ignoriert die `cameraDirection` Parameter.
-
-### Firefox OS Macken
-
-* Ignoriert die `quality` Parameter.
-
-* `Camera.DestinationType`wird ignoriert, und gleich `1` (Bilddatei-URI)
-
-* Ignoriert die `allowEdit` Parameter.
-
-* Ignoriert die `PictureSourceType` Parameter (Benutzer wählt es in einem Dialogfenster)
-
-* Ignoriert die`encodingType`
-
-* Ignoriert die `targetWidth` und`targetHeight`
-
-* `Camera.MediaType`wird nicht unterstützt.
-
-* Ignoriert die `correctOrientation` Parameter.
-
-* Ignoriert die `cameraDirection` Parameter.
-
-### iOS Macken
-
-* Legen Sie `quality` unter 50 Speicherfehler auf einigen Geräten zu vermeiden.
-
-* Bei der Verwendung `destinationType.FILE_URI` , Fotos werden im temporären Verzeichnis der Anwendung gespeichert. Den Inhalt des temporären Verzeichnis der Anwendung wird gelöscht, wenn die Anwendung beendet.
-
-### Tizen Macken
-
-* nicht unterstützte Optionen
-
-* gibt immer einen Datei-URI
-
-### Windows Phone 7 und 8 Eigenarten
-
-* Ignoriert die `allowEdit` Parameter.
-
-* Ignoriert die `correctOrientation` Parameter.
-
-* Ignoriert die `cameraDirection` Parameter.
-
-* Ignoriert die `saveToPhotoAlbum` Parameter. WICHTIG: Alle Aufnahmen die wp7/8 Cordova-Kamera-API werden immer in Kamerarolle des Telefons kopiert. Abhängig von den Einstellungen des Benutzers könnte dies auch bedeuten, dass das Bild in ihre OneDrive automatisch hochgeladen ist. Dies könnte möglicherweise bedeuten, dass das Bild für ein breiteres Publikum als Ihre Anwendung vorgesehen ist. Wenn diese einen Blocker für Ihre Anwendung, Sie müssen die CameraCaptureTask zu implementieren, wie im Msdn dokumentiert: Sie können kommentieren oder Up-Abstimmung das Beiträge zu diesem Thema im [Bugtracker][3]
-
-* Ignoriert die `mediaType` -Eigenschaft des `cameraOptions` wie das Windows Phone SDK keine Möglichkeit, Fotothek Videos wählen.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-onError-Callback-Funktion, die eine Fehlermeldung bereitstellt.
-
- function(message) {
- // Show a helpful message
- }
-
-
-### Parameter
-
-* **Meldung**: die Nachricht wird durch das Gerät systemeigenen Code bereitgestellt. *(String)*
-
-## cameraSuccess
-
-onSuccess Callback-Funktion, die die Bilddaten bereitstellt.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### Parameter
-
-* **CMYK**: Base64-Codierung der Bilddaten, *oder* die Image-Datei-URI, je nach `cameraOptions` in Kraft. *(String)*
-
-### Beispiel
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Ein Handle für das Dialogfeld "Popover" erstellt von `navigator.camera.getPicture`.
-
-### Methoden
-
-* **SetPosition**: Legen Sie die Position der Popover.
-
-### Unterstützte Plattformen
-
-* iOS
-
-### setPosition
-
-Legen Sie die Position von der Popover.
-
-**Parameter**:
-
-* `cameraPopoverOptions`: die `CameraPopoverOptions` angeben, dass die neue Position
-
-### Beispiel
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-nur iOS-Parametern, die Anker-Element Lage und Pfeil Richtung der Popover angeben, bei der Auswahl von Bildern aus einem iPad Bibliothek oder Album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **X**: x Pixelkoordinate des Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
-* **y**: y Pixelkoordinate des Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
-* **width**: Breite in Pixeln, das Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
-* **height**: Höhe in Pixeln, das Bildschirmelement auf dem der Popover zu verankern. *(Anzahl)*
-
-* **arrowDir**: Richtung der Pfeil auf der Popover zeigen sollte. Im Sinne `Camera.PopoverArrowDirection` *(Anzahl)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Beachten Sie, dass die Größe der Popover ändern kann, um die Richtung des Pfeils und Ausrichtung des Bildschirms anzupassen. Achten Sie darauf, um Orientierung zu berücksichtigen, wenn Sie den Anker-Element-Speicherort angeben.
-
-## navigator.camera.cleanup
-
-Entfernt Mittelstufe Fotos von der Kamera aus der vorübergehenden Verwahrung genommen.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### Beschreibung
-
-Fortgeschrittene Image-Dateien, die in vorübergehender Verwahrung gehalten werden, nach dem Aufruf von `camera.getPicture` entfernt. Gilt nur wenn der Wert von `Camera.sourceType` gleich `Camera.PictureSourceType.CAMERA` und `Camera.destinationType` gleich `Camera.DestinationType.FILE_URI`.
-
-### Unterstützte Plattformen
-
-* iOS
-
-### Beispiel
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/es/README.md b/doc/es/README.md
deleted file mode 100644
index 76af1649f..000000000
--- a/doc/es/README.md
+++ /dev/null
@@ -1,411 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-Este plugin define un global `navigator.camera` objeto que proporciona una API para tomar fotografías y por elegir imágenes de biblioteca de imágenes del sistema.
-
-Aunque el objeto está unido al ámbito global `navigator` , no estará disponible hasta después de la `deviceready` evento.
-
- document.addEventListener ("deviceready", onDeviceReady, false);
- function onDeviceReady() {console.log(navigator.camera)};
-
-
-## Instalación
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * Cámara
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * Navigator.Camera.Cleanup
-
-## navigator.camera.getPicture
-
-Toma una foto con la cámara, o recupera una foto de Galería de imágenes del dispositivo. La imagen se pasa a la devolución de llamada de éxito como un codificado en base64 `String` , o como el URI para el archivo de imagen. El método se devuelve un `CameraPopoverHandle` objeto que puede utilizarse para volver a colocar el popover de selección de archivo.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### Descripción
-
-El `camera.getPicture` función abre la aplicación de cámara predeterminada del dispositivo que permite a los usuarios ajustar imágenes. Este comportamiento se produce de forma predeterminada, cuando `Camera.sourceType` es igual a `Camera.PictureSourceType.CAMERA` . Una vez que el usuario ajusta la foto, una aplicación de cámara se cierra y se restablecerá la aplicación.
-
-Si `Camera.sourceType` es `Camera.PictureSourceType.PHOTOLIBRARY` o `Camera.PictureSourceType.SAVEDPHOTOALBUM` , entonces una muestra de diálogo que permite a los usuarios seleccionar una imagen existente. El `camera.getPicture` función devuelve un `CameraPopoverHandle` objeto, que puede utilizarse para volver a colocar el diálogo de selección de imagen, por ejemplo, cuando cambia la orientación del dispositivo.
-
-El valor devuelto es enviado a la `cameraSuccess` función de callback, en uno de los formatos siguientes, dependiendo del objeto `cameraOptions` :
-
- * Una `String` que contiene la imagen codificada en base64.
-
- * Una `String` que representa la ubicación del archivo de imagen en almacenamiento local (por defecto).
-
-Puedes hacer lo que quieras con la imagen codificada o URI, por ejemplo:
-
- * Representar la imagen en una etiqueta de ` `, como en el ejemplo siguiente
-
- * Guardar los datos localmente (`LocalStorage`, [Lawnchair](http://brianleroux.github.com/lawnchair/), etc.)
-
- * Enviar los datos a un servidor remoto
-
-**Nota**: resolución de la foto en los nuevos dispositivos es bastante bueno. Fotos seleccionadas de la Galería del dispositivo no son degradadas a una calidad más baja, incluso si un `quality` se especifica el parámetro. Para evitar problemas con la memoria común, establezca `Camera.destinationType` a `FILE_URI` en lugar de`DATA_URL`.
-
-#### Plataformas soportadas
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### Ejemplo
-
-Tomar una foto y recuperarlo como una imagen codificada en base64:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Tomar una foto y recuperar la ubicación del archivo de la imagen:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### Preferencias (iOS)
-
- * **CameraUsesGeolocation** (booleano, el valor predeterminado de false). Para la captura de imágenes JPEG, establecido en true para obtener datos de geolocalización en la cabecera EXIF. Esto activará la solicitud de permisos de geolocalización si establecido en true.
-
-
-
-
-#### Amazon fuego OS rarezas
-
-Amazon fuego OS utiliza los intentos para poner en marcha la actividad de la cámara del dispositivo para capturar imágenes y en teléfonos con poca memoria, puede matar la actividad Cordova. En este escenario, la imagen no aparezca cuando se restaura la actividad cordova.
-
-#### Rarezas Android
-
-Android utiliza los intentos para iniciar la actividad de la cámara del dispositivo para capturar imágenes, y en los teléfonos con poca memoria, puede matar la actividad Cordova. En este escenario, la imagen no aparezca cuando se restaura la actividad Cordova.
-
-#### Navegador rarezas
-
-Sólo puede devolver fotos como imagen codificada en base64.
-
-#### Firefox OS rarezas
-
-Cámara plugin actualmente se implementa mediante [Actividades Web](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### iOS rarezas
-
-Incluyendo un JavaScript `alert()` en cualquiera de la devolución de llamada funciones pueden causar problemas. Envuelva la alerta dentro de un `setTimeout()` para permitir que el selector de imagen iOS o popover cerrar completamente antes de la alerta se muestra:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 rarezas
-
-Invocando la aplicación de cámara nativa mientras el dispositivo está conectado vía Zune no funciona y desencadena un callback de error.
-
-#### Rarezas Tizen
-
-Tizen sólo es compatible con un `destinationType` de `Camera.DestinationType.FILE_URI` y un `sourceType` de`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-## CameraOptions
-
-Parámetros opcionales para personalizar la configuración de la cámara.
-
- {calidad: destinationType 75,: Camera.DestinationType.DATA_URL, sourceType: Camera.PictureSourceType.CAMERA, allowEdit: true, encodingType: Camera.EncodingType.JPEG, targetWidth: 100, targetHeight: 100, popoverOptions: CameraPopoverOptions, saveToPhotoAlbum: falsa};
-
-
- * **calidad**: calidad de la imagen guardada, expresada en un rango de 0-100, donde 100 es típicamente resolución sin pérdida de compresión del archivo. El valor predeterminado es 50. *(Número)* (Tenga en cuenta que no está disponible información sobre resolución de la cámara).
-
- * **destinationType**: elegir el formato del valor devuelto. El valor predeterminado es FILE_URI. Definido en `navigator.camera.DestinationType` *(número)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: establecer el origen de la imagen. El valor predeterminado es cámara. Definido en `navigator.camera.PictureSourceType` *(número)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: permite edición sencilla de imagen antes de la selección. *(Booleano)*
-
- * **encodingType**: elegir la codificación del archivo de imagen devuelta. Por defecto es JPEG. Definido en `navigator.camera.EncodingType` *(número)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: ancho en píxeles a escala de la imagen. Debe usarse con **targetHeight**. Proporción se mantiene constante. *(Número)*
-
- * **targetHeight**: altura en píxeles a escala de la imagen. Debe usarse con **targetWidth**. Proporción se mantiene constante. *(Número)*
-
- * **mediaType**: definir el tipo de medios para seleccionar. Sólo funciona cuando `PictureSourceType` es `PHOTOLIBRARY` o `SAVEDPHOTOALBUM` . Definido en `nagivator.camera.MediaType` *(número)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DE FORMA PREDETERMINADA. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: rotar la imagen para corregir la orientación del dispositivo durante la captura. *(Booleano)*
-
- * **saveToPhotoAlbum**: guardar la imagen en el álbum de fotos en el dispositivo después de su captura. *(Booleano)*
-
- * **popoverOptions**: opciones sólo iOS que especifican popover ubicación en iPad. Definido en`CameraPopoverOptions`.
-
- * **cameraDirection**: elegir la cámara para usar (o parte posterior-frontal). El valor predeterminado es atrás. Definido en `navigator.camera.Direction` *(número)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### Amazon fuego OS rarezas
-
- * Cualquier valor de `cameraDirection` da como resultado una foto orientada hacia atrás.
-
- * Ignora el `allowEdit` parámetro.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY` y `Camera.PictureSourceType.SAVEDPHOTOALBUM` Mostrar el mismo álbum de fotos.
-
-#### Rarezas Android
-
- * Cualquier valor de `cameraDirection` da como resultado una foto orientada hacia atrás.
-
- * Android también utiliza la actividad de cultivo de allowEdit, aunque cultivo debe trabajar y realmente pasar la imagen recortada a Córdoba, el único que funciona constantemente es el integrado con la aplicación de Google Plus fotos. Otros cultivos pueden no funcionar.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY` y `Camera.PictureSourceType.SAVEDPHOTOALBUM` Mostrar el mismo álbum de fotos.
-
-#### BlackBerry 10 rarezas
-
- * Ignora el `quality` parámetro.
-
- * Ignora el `allowEdit` parámetro.
-
- * `Camera.MediaType`No se admite.
-
- * Ignora el `correctOrientation` parámetro.
-
- * Ignora el `cameraDirection` parámetro.
-
-#### Firefox OS rarezas
-
- * Ignora el `quality` parámetro.
-
- * `Camera.DestinationType`se ignora y es igual a `1` (URI del archivo de imagen)
-
- * Ignora el `allowEdit` parámetro.
-
- * Ignora el `PictureSourceType` parámetro (el usuario lo elige en una ventana de diálogo)
-
- * Ignora el`encodingType`
-
- * Ignora el `targetWidth` y`targetHeight`
-
- * `Camera.MediaType`No se admite.
-
- * Ignora el `correctOrientation` parámetro.
-
- * Ignora el `cameraDirection` parámetro.
-
-#### iOS rarezas
-
- * Establecer `quality` por debajo de 50 para evitar errores de memoria en algunos dispositivos.
-
- * Cuando se utiliza `destinationType.FILE_URI` , fotos se guardan en el directorio temporal de la aplicación. El contenido del directorio temporal de la aplicación se eliminará cuando finalice la aplicación.
-
-#### Rarezas Tizen
-
- * opciones no compatibles
-
- * siempre devuelve un identificador URI de archivo
-
-#### Windows Phone 7 y 8 rarezas
-
- * Ignora el `allowEdit` parámetro.
-
- * Ignora el `correctOrientation` parámetro.
-
- * Ignora el `cameraDirection` parámetro.
-
- * Ignora el `saveToPhotoAlbum` parámetro. IMPORTANTE: Todas las imágenes tomadas con la cámara wp7/8 cordova API siempre se copian en rollo de cámara del teléfono. Dependiendo de la configuración del usuario, esto podría significar también que la imagen es auto-subido a su OneDrive. Esto potencialmente podría significar que la imagen está disponible a una audiencia más amplia que su aplicación previsto. Si un bloqueador para su aplicación, usted necesitará aplicar el CameraCaptureTask como se documenta en msdn: también puede comentar o votar hasta el tema relacionado en el [issue tracker de](https://issues.apache.org/jira/browse/CB-2083)
-
- * Ignora el `mediaType` propiedad de `cameraOptions` como el SDK de Windows Phone no proporciona una manera para elegir vídeos fototeca.
-
-## CameraError
-
-onError función callback que proporciona un mensaje de error.
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### Descripción
-
- * **mensaje**: el mensaje es proporcionado por código nativo del dispositivo. *(String)*
-
-## cameraSuccess
-
-onSuccess función callback que proporciona los datos de imagen.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### Descripción
-
- * **imageData**: codificación en Base64 de los datos de imagen, *o* el archivo de imagen URI, dependiendo de `cameraOptions` en vigor. *(String)*
-
-#### Ejemplo
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Un identificador para el cuadro de diálogo popover creado por`navigator.camera.getPicture`.
-
-#### Descripción
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### Plataformas soportadas
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Ejemplo
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-Sólo iOS parámetros que especifican la dirección ancla elemento ubicación y la flecha de la popover al seleccionar imágenes de biblioteca o álbum de un iPad.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### Descripción
-
- * **x**: coordenadas de píxeles del elemento de la pantalla en la que anclar el popover x. *(Número)*
-
- * **y**: coordenada píxeles del elemento de la pantalla en la que anclar el popover. *(Número)*
-
- * **anchura**: anchura, en píxeles, del elemento sobre el que anclar el popover pantalla. *(Número)*
-
- * **altura**: alto, en píxeles, del elemento sobre el que anclar el popover pantalla. *(Número)*
-
- * **arrowDir**: dirección de la flecha en el popover debe apuntar. Definido en `Camera.PopoverArrowDirection` *(número)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Tenga en cuenta que puede cambiar el tamaño de la popover para ajustar la dirección de la flecha y orientación de la pantalla. Asegúrese de que para tener en cuenta los cambios de orientación cuando se especifica la ubicación del elemento de anclaje.
-
-## Navigator.Camera.Cleanup
-
-Elimina intermedio fotos tomadas por la cámara de almacenamiento temporal.
-
- Navigator.Camera.cleanup (cameraSuccess, cameraError);
-
-
-#### Descripción
-
-Elimina intermedio archivos de imagen que se mantienen en depósito temporal después de llamar `camera.getPicture` . Se aplica sólo cuando el valor de `Camera.sourceType` es igual a `Camera.PictureSourceType.CAMERA` y el `Camera.destinationType` es igual a`Camera.DestinationType.FILE_URI`.
-
-#### Plataformas soportadas
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Ejemplo
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/es/index.md b/doc/es/index.md
deleted file mode 100644
index dfd0970b9..000000000
--- a/doc/es/index.md
+++ /dev/null
@@ -1,391 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Este plugin define un global `navigator.camera` objeto que proporciona una API para tomar fotografías y por elegir imágenes de biblioteca de imágenes del sistema.
-
-Aunque el objeto está unido al ámbito global `navigator` , no estará disponible hasta después de la `deviceready` evento.
-
- document.addEventListener ("deviceready", onDeviceReady, false);
- function onDeviceReady() {console.log(navigator.camera)};
-
-
-## Instalación
-
- Cordova plugin agregar cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Toma una foto con la cámara, o recupera una foto de Galería de imágenes del dispositivo. La imagen se pasa a la devolución de llamada de éxito como un codificado en base64 `String` , o como el URI para el archivo de imagen. El método se devuelve un `CameraPopoverHandle` objeto que puede utilizarse para volver a colocar el popover de selección de archivo.
-
- navigator.camera.getPicture (cameraSuccess, cameraError, cameraOptions);
-
-
-### Descripción
-
-El `camera.getPicture` función abre la aplicación de cámara predeterminada del dispositivo que permite a los usuarios ajustar imágenes. Este comportamiento se produce de forma predeterminada, cuando `Camera.sourceType` es igual a `Camera.PictureSourceType.CAMERA` . Una vez que el usuario ajusta la foto, una aplicación de cámara se cierra y se restablecerá la aplicación.
-
-Si `Camera.sourceType` es `Camera.PictureSourceType.PHOTOLIBRARY` o `Camera.PictureSourceType.SAVEDPHOTOALBUM` , entonces una muestra de diálogo que permite a los usuarios seleccionar una imagen existente. El `camera.getPicture` función devuelve un `CameraPopoverHandle` objeto, que puede utilizarse para volver a colocar el diálogo de selección de imagen, por ejemplo, cuando cambia la orientación del dispositivo.
-
-El valor devuelto es enviado a la `cameraSuccess` función de callback, en uno de los formatos siguientes, dependiendo del objeto `cameraOptions` :
-
-* Una `String` que contiene la imagen codificada en base64.
-
-* Una `String` que representa la ubicación del archivo de imagen en almacenamiento local (por defecto).
-
-Puedes hacer lo que quieras con la imagen codificada o URI, por ejemplo:
-
-* Representar la imagen en una etiqueta de ` `, como en el ejemplo siguiente
-
-* Guardar los datos localmente (`LocalStorage`, [Lawnchair][1], etc.)
-
-* Enviar los datos a un servidor remoto
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**Nota**: resolución de la foto en los nuevos dispositivos es bastante bueno. Fotos seleccionadas de la Galería del dispositivo no son degradadas a una calidad más baja, incluso si un `quality` se especifica el parámetro. Para evitar problemas con la memoria común, establezca `Camera.destinationType` a `FILE_URI` en lugar de`DATA_URL`.
-
-### Plataformas soportadas
-
-* Amazon fire OS
-* Android
-* BlackBerry 10
-* Explorador
-* Firefox OS
-* iOS
-* Tizen
-* Windows Phone 7 y 8
-* Windows 8
-
-### Preferencias (iOS)
-
-* **CameraUsesGeolocation** (booleano, el valor predeterminado de false). Para la captura de imágenes JPEG, establecido en true para obtener datos de geolocalización en la cabecera EXIF. Esto activará la solicitud de permisos de geolocalización si establecido en true.
-
-
-
-
-### Amazon fuego OS rarezas
-
-Amazon fuego OS utiliza los intentos para poner en marcha la actividad de la cámara del dispositivo para capturar imágenes y en teléfonos con poca memoria, puede matar la actividad Cordova. En este escenario, la imagen no aparezca cuando se restaura la actividad cordova.
-
-### Rarezas Android
-
-Android utiliza los intentos para iniciar la actividad de la cámara del dispositivo para capturar imágenes, y en los teléfonos con poca memoria, puede matar la actividad Cordova. En este escenario, la imagen no aparezca cuando se restaura la actividad Cordova.
-
-### Navegador rarezas
-
-Sólo puede devolver fotos como imagen codificada en base64.
-
-### Firefox OS rarezas
-
-Cámara plugin actualmente se implementa mediante [Actividades Web][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS rarezas
-
-Incluyendo un JavaScript `alert()` en cualquiera de la devolución de llamada funciones pueden causar problemas. Envuelva la alerta dentro de un `setTimeout()` para permitir que el selector de imagen iOS o popover cerrar completamente antes de la alerta se muestra:
-
- setTimeout(function() {/ / Haz lo tuyo aquí!}, 0);
-
-
-### Windows Phone 7 rarezas
-
-Invocando la aplicación de cámara nativa mientras el dispositivo está conectado vía Zune no funciona y desencadena un callback de error.
-
-### Rarezas Tizen
-
-Tizen sólo es compatible con un `destinationType` de `Camera.DestinationType.FILE_URI` y un `sourceType` de`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Ejemplo
-
-Tomar una foto y recuperarlo como una imagen codificada en base64:
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {var imagen = document.getElementById('myImage');
- Image.src = "datos: image / jpeg; base64," + imageData;}
-
- function onFail(message) {alert (' falló porque: ' + mensaje);}
-
-
-Tomar una foto y recuperar la ubicación del archivo de la imagen:
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {var imagen = document.getElementById('myImage');
- Image.src = imageURI;
- } function onFail(message) {alert (' falló porque: ' + mensaje);}
-
-
-## CameraOptions
-
-Parámetros opcionales para personalizar la configuración de la cámara.
-
- {calidad: destinationType 75,: Camera.DestinationType.DATA_URL, sourceType: Camera.PictureSourceType.CAMERA, allowEdit: true, encodingType: Camera.EncodingType.JPEG, targetWidth: 100, targetHeight: 100, popoverOptions: CameraPopoverOptions, saveToPhotoAlbum: falsa};
-
-
-### Opciones
-
-* **calidad**: calidad de la imagen guardada, expresada en un rango de 0-100, donde 100 es típicamente resolución sin pérdida de compresión del archivo. El valor predeterminado es 50. *(Número)* (Tenga en cuenta que no está disponible información sobre resolución de la cámara).
-
-* **destinationType**: elegir el formato del valor devuelto. El valor predeterminado es FILE_URI. Definido en `navigator.camera.DestinationType` *(número)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: establecer el origen de la imagen. El valor predeterminado es cámara. Definido en `navigator.camera.PictureSourceType` *(número)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: permite edición sencilla de imagen antes de la selección. *(Booleano)*
-
-* **encodingType**: elegir la codificación del archivo de imagen devuelta. Por defecto es JPEG. Definido en `navigator.camera.EncodingType` *(número)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: ancho en píxeles a escala de la imagen. Debe usarse con **targetHeight**. Proporción se mantiene constante. *(Número)*
-
-* **targetHeight**: altura en píxeles a escala de la imagen. Debe usarse con **targetWidth**. Proporción se mantiene constante. *(Número)*
-
-* **mediaType**: definir el tipo de medios para seleccionar. Sólo funciona cuando `PictureSourceType` es `PHOTOLIBRARY` o `SAVEDPHOTOALBUM` . Definido en `nagivator.camera.MediaType` *(número)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DE FORMA PREDETERMINADA. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: rotar la imagen para corregir la orientación del dispositivo durante la captura. *(Booleano)*
-
-* **saveToPhotoAlbum**: guardar la imagen en el álbum de fotos en el dispositivo después de su captura. *(Booleano)*
-
-* **popoverOptions**: opciones sólo iOS que especifican popover ubicación en iPad. Definido en`CameraPopoverOptions`.
-
-* **cameraDirection**: elegir la cámara para usar (o parte posterior-frontal). El valor predeterminado es atrás. Definido en `navigator.camera.Direction` *(número)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Amazon fuego OS rarezas
-
-* Cualquier valor de `cameraDirection` da como resultado una foto orientada hacia atrás.
-
-* Ignora el `allowEdit` parámetro.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY` y `Camera.PictureSourceType.SAVEDPHOTOALBUM` Mostrar el mismo álbum de fotos.
-
-### Rarezas Android
-
-* Cualquier valor de `cameraDirection` da como resultado una foto orientada hacia atrás.
-
-* Ignora el `allowEdit` parámetro.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY` y `Camera.PictureSourceType.SAVEDPHOTOALBUM` Mostrar el mismo álbum de fotos.
-
-### BlackBerry 10 rarezas
-
-* Ignora el `quality` parámetro.
-
-* Ignora el `allowEdit` parámetro.
-
-* `Camera.MediaType`No se admite.
-
-* Ignora el `correctOrientation` parámetro.
-
-* Ignora el `cameraDirection` parámetro.
-
-### Firefox OS rarezas
-
-* Ignora el `quality` parámetro.
-
-* `Camera.DestinationType`se ignora y es igual a `1` (URI del archivo de imagen)
-
-* Ignora el `allowEdit` parámetro.
-
-* Ignora el `PictureSourceType` parámetro (el usuario lo elige en una ventana de diálogo)
-
-* Ignora el`encodingType`
-
-* Ignora el `targetWidth` y`targetHeight`
-
-* `Camera.MediaType`No se admite.
-
-* Ignora el `correctOrientation` parámetro.
-
-* Ignora el `cameraDirection` parámetro.
-
-### iOS rarezas
-
-* Establecer `quality` por debajo de 50 para evitar errores de memoria en algunos dispositivos.
-
-* Cuando se utiliza `destinationType.FILE_URI` , fotos se guardan en el directorio temporal de la aplicación. El contenido del directorio temporal de la aplicación se eliminará cuando finalice la aplicación.
-
-### Rarezas Tizen
-
-* opciones no compatibles
-
-* siempre devuelve un identificador URI de archivo
-
-### Windows Phone 7 y 8 rarezas
-
-* Ignora el `allowEdit` parámetro.
-
-* Ignora el `correctOrientation` parámetro.
-
-* Ignora el `cameraDirection` parámetro.
-
-* Ignora el `saveToPhotoAlbum` parámetro. IMPORTANTE: Todas las imágenes tomadas con la cámara wp7/8 cordova API siempre se copian en rollo de cámara del teléfono. Dependiendo de la configuración del usuario, esto podría significar también que la imagen es auto-subido a su OneDrive. Esto potencialmente podría significar que la imagen está disponible a una audiencia más amplia que su aplicación previsto. Si un bloqueador para su aplicación, usted necesitará aplicar el CameraCaptureTask como se documenta en msdn: también puede comentar o votar hasta el tema relacionado en el [issue tracker de][3]
-
-* Ignora el `mediaType` propiedad de `cameraOptions` como el SDK de Windows Phone no proporciona una manera para elegir vídeos fototeca.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-onError función callback que proporciona un mensaje de error.
-
- function(Message) {/ / Mostrar un mensaje útil}
-
-
-### Parámetros
-
-* **mensaje**: el mensaje es proporcionado por código nativo del dispositivo. *(String)*
-
-## cameraSuccess
-
-onSuccess función callback que proporciona los datos de imagen.
-
- function(ImageData) {/ / hacer algo con la imagen}
-
-
-### Parámetros
-
-* **imageData**: codificación en Base64 de los datos de imagen, *o* el archivo de imagen URI, dependiendo de `cameraOptions` en vigor. *(String)*
-
-### Ejemplo
-
- Mostrar imagen / / function cameraCallback(imageData) {var imagen = document.getElementById('myImage');
- Image.src = "datos: image / jpeg; base64," + imageData;}
-
-
-## CameraPopoverHandle
-
-Un identificador para el cuadro de diálogo popover creado por`navigator.camera.getPicture`.
-
-### Métodos
-
-* **setPosition**: establecer la posición de la popover.
-
-### Plataformas soportadas
-
-* iOS
-
-### setPosition
-
-Establecer la posición de la popover.
-
-**Parámetros**:
-
-* `cameraPopoverOptions`: el `CameraPopoverOptions` que especifican la nueva posición
-
-### Ejemplo
-
- var cameraPopoverHandle = navigator.camera.getPicture (onSuccess, onFail, {destinationType: Camera.DestinationType.FILE_URI, sourceType: Camera.PictureSourceType.PHOTOLIBRARY, popoverOptions: CameraPopoverOptions nuevo (300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)});
-
- Vuelva a colocar el popover si cambia la orientación.
- Window.onorientationchange = function() {var cameraPopoverOptions = new CameraPopoverOptions (0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-Sólo iOS parámetros que especifican la dirección ancla elemento ubicación y la flecha de la popover al seleccionar imágenes de biblioteca o álbum de un iPad.
-
- {x: 0, y: 32, ancho: 320, altura: 480, arrowDir: Camera.PopoverArrowDirection.ARROW_ANY};
-
-
-### CameraPopoverOptions
-
-* **x**: coordenadas de píxeles del elemento de la pantalla en la que anclar el popover x. *(Número)*
-
-* **y**: coordenada píxeles del elemento de la pantalla en la que anclar el popover. *(Número)*
-
-* **anchura**: anchura, en píxeles, del elemento sobre el que anclar el popover pantalla. *(Número)*
-
-* **altura**: alto, en píxeles, del elemento sobre el que anclar el popover pantalla. *(Número)*
-
-* **arrowDir**: dirección de la flecha en el popover debe apuntar. Definido en `Camera.PopoverArrowDirection` *(número)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Tenga en cuenta que puede cambiar el tamaño de la popover para ajustar la dirección de la flecha y orientación de la pantalla. Asegúrese de que para tener en cuenta los cambios de orientación cuando se especifica la ubicación del elemento de anclaje.
-
-## Navigator.Camera.Cleanup
-
-Elimina intermedio fotos tomadas por la cámara de almacenamiento temporal.
-
- Navigator.Camera.cleanup (cameraSuccess, cameraError);
-
-
-### Descripción
-
-Elimina intermedio archivos de imagen que se mantienen en depósito temporal después de llamar `camera.getPicture` . Se aplica sólo cuando el valor de `Camera.sourceType` es igual a `Camera.PictureSourceType.CAMERA` y el `Camera.destinationType` es igual a`Camera.DestinationType.FILE_URI`.
-
-### Plataformas soportadas
-
-* iOS
-
-### Ejemplo
-
- Navigator.Camera.cleanup (onSuccess, onFail);
-
- function onSuccess() {console.log ("cámara limpieza éxito.")}
-
- function onFail(message) {alert (' falló porque: ' + mensaje);}
diff --git a/doc/fr/README.md b/doc/fr/README.md
deleted file mode 100644
index 091dd2372..000000000
--- a/doc/fr/README.md
+++ /dev/null
@@ -1,378 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-Ce plugin définit un global `navigator.camera` objet qui fournit une API pour la prise de photos et de choisir des images de la bibliothèque d'images du système.
-
-Bien que l'objet est attaché à la portée globale `navigator` , il n'est pas disponible jusqu'après la `deviceready` événement.
-
- document.addEventListener (« deviceready », onDeviceReady, false) ;
- function onDeviceReady() {console.log(navigator.camera);}
-
-
-## Installation
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * Appareil photo
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * Navigator.Camera.Cleanup
-
-## navigator.camera.getPicture
-
-Prend une photo à l'aide de la caméra, ou récupère une photo de la Galerie d'images de l'appareil. L'image est passé au rappel succès comme un codage base64 `String` , ou comme l'URI du fichier de l'image. La méthode elle-même retourne un `CameraPopoverHandle` objet qui permet de repositionner le kangourou de sélection de fichier.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### Description
-
-Le `camera.getPicture` fonction ouvre l'application de caméra par défaut de l'appareil qui permet aux utilisateurs de prendre des photos. Ce comportement se produit par défaut, lorsque `Camera.sourceType` est égal à `Camera.PictureSourceType.CAMERA` . Une fois que l'utilisateur s'enclenche la photo, l'application appareil photo se ferme et l'application est restaurée.
-
-Si `Camera.sourceType` est `Camera.PictureSourceType.PHOTOLIBRARY` ou `Camera.PictureSourceType.SAVEDPHOTOALBUM` , puis un dialogue affiche qui permet aux utilisateurs de sélectionner une image existante. Le `camera.getPicture` retourne un `CameraPopoverHandle` objet, ce qui permet de repositionner le dialogue de sélection d'image, par exemple, lorsque l'orientation de l'appareil change.
-
-La valeur de retour est envoyée à la `cameraSuccess` la fonction de rappel, dans l'un des formats suivants, selon les `cameraOptions` :
-
- * A `String` contenant l'image photo codée en base64.
-
- * A `String` qui représente l'emplacement du fichier image sur le stockage local (par défaut).
-
-Vous pouvez faire ce que vous voulez avec l'image codée ou URI, par exemple :
-
- * Afficher l'image dans un ` ` tag, comme dans l'exemple ci-dessous
-
- * Enregistrer les données localement ( `LocalStorage` , [poids](http://brianleroux.github.com/lawnchair/), etc..)
-
- * Publier les données sur un serveur distant
-
-**NOTE**: la résolution de Photo sur les nouveaux appareils est assez bonne. Photos sélectionnées de la Galerie de l'appareil ne sont pas réduites à une baisse de la qualité, même si un `quality` paramètre est spécifié. Pour éviter les problèmes de mémoire commun, définissez `Camera.destinationType` à `FILE_URI` au lieu de`DATA_URL`.
-
-#### Plates-formes supportées
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### Exemple
-
-Prendre une photo, puis extrayez-la comme une image codée en base64 :
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- }) ;
-
- function onSuccess(imageData) {var image = document.getElementById('myImage') ;
- image.src = "données : image / jpeg ; base64," + imageData;}
-
- function onFail(message) {alert (' a échoué car: "+ message);}
-
-
-Prendre une photo et récupérer l'emplacement du fichier de l'image :
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI }) ;
-
- function onSuccess(imageURI) {var image = document.getElementById('myImage') ;
- image.SRC = imageURI ;
- } function onFail(message) {alert (' a échoué car: "+ message);}
-
-
-#### Préférences (iOS)
-
- * **CameraUsesGeolocation** (boolean, par défaut, false). Pour capturer des images JPEG, true pour obtenir des données de géolocalisation dans l'en-tête EXIF. Cela va déclencher une demande d'autorisations de géolocalisation si défini à true.
-
-
-
-
-#### Amazon Fire OS Quirks
-
-Amazon Fire OS utilise des intentions pour lancer l'activité de l'appareil photo sur l'appareil pour capturer des images et sur les téléphones avec peu de mémoire, l'activité de Cordova peut être tuée. Dans ce scénario, l'image peut ne pas apparaître lorsque l'activité de cordova est restaurée.
-
-#### Quirks Android
-
-Android utilise des intentions pour lancer l'activité de l'appareil photo sur l'appareil pour capturer des images et sur les téléphones avec peu de mémoire, l'activité de Cordova peut être tuée. Dans ce scénario, l'image peut ne pas apparaître lorsque l'activité de Cordova est restaurée.
-
-#### Bizarreries navigateur
-
-Peut retourner uniquement les photos comme image codée en base64.
-
-#### Firefox OS Quirks
-
-Appareil photo plugin est actuellement mis en œuvre à l'aide [d'Activités sur le Web](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### Notes au sujet d'iOS
-
-Y compris un JavaScript `alert()` dans les deux le rappel fonctions peuvent causer des problèmes. Envelopper l'alerte dans un `setTimeout()` pour permettre le sélecteur d'image iOS ou kangourou pour fermer entièrement avant que l'alerte s'affiche :
-
- setTimeout(function() {/ / faire votre truc ici!}, 0) ;
-
-
-#### Windows Phone 7 Quirks
-
-Invoquant l'application native caméra alors que l'appareil est connecté via Zune ne fonctionne pas et déclenche un rappel de l'erreur.
-
-#### Bizarreries de paciarelli
-
-Paciarelli prend uniquement en charge un `destinationType` de `Camera.DestinationType.FILE_URI` et un `sourceType` de`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-## CameraOptions
-
-Paramètres optionnels pour personnaliser les réglages de l'appareil.
-
- {qualité : destinationType 75,: Camera.DestinationType.DATA_URL, TypeSource : Camera.PictureSourceType.CAMERA, allowEdit : encodingType vrai,: Camera.EncodingType.JPEG, targetWidth : 100, targetHeight : 100, popoverOptions : CameraPopoverOptions, saveToPhotoAlbum : false} ;
-
-
- * **qualité**: qualité de l'image enregistrée, exprimée en une gamme de 0 à 100, 100 étant généralement pleine résolution sans perte de compression de fichiers. La valeur par défaut est 50. *(Nombre)* (Notez que les informations sur la résolution de la caméra sont indisponibles).
-
- * **destinationType**: choisissez le format de la valeur de retour. La valeur par défaut est FILE_URI. Définies dans `navigator.camera.DestinationType` *(nombre)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: définissez la source de l'image. La valeur par défaut est la caméra. Définies dans `navigator.camera.PictureSourceType` *(nombre)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: permettre un montage simple d'image avant la sélection. *(Booléen)*
-
- * **encodingType**: choisir le fichier image retournée de codage. Valeur par défaut est JPEG. Définies dans `navigator.camera.EncodingType` *(nombre)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: largeur en pixels de l'image de l'échelle. Doit être utilisé avec **targetHeight**. Aspect ratio reste constant. *(Nombre)*
-
- * **targetHeight**: hauteur en pixels de l'image de l'échelle. Doit être utilisé avec **targetWidth**. Aspect ratio reste constant. *(Nombre)*
-
- * **mediaType**: définir le type de média pour choisir de. Ne fonctionne que quand `PictureSourceType` est `PHOTOLIBRARY` ou `SAVEDPHOTOALBUM` . Définies dans `nagivator.camera.MediaType` *(nombre)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. PAR DÉFAUT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: faire pivoter l'image afin de corriger l'orientation de l'appareil lors de la capture. *(Booléen)*
-
- * **saveToPhotoAlbum**: enregistrer l'image sur l'album photo sur l'appareil après la capture. *(Booléen)*
-
- * **popoverOptions**: iOS uniquement des options qui spécifient l'emplacement de kangourou dans iPad. Défini dans`CameraPopoverOptions`.
-
- * **cameraDirection**: choisissez la caméra à utiliser (ou dos-face). La valeur par défaut est de retour. Définies dans `navigator.camera.Direction` *(nombre)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### Amazon Fire OS Quirks
-
- * Tout `cameraDirection` résultats dans le back-face photo de valeur.
-
- * Ignore la `allowEdit` paramètre.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`et `Camera.PictureSourceType.SAVEDPHOTOALBUM` les deux affichent le même album photo.
-
-#### Quirks Android
-
- * Tout `cameraDirection` résultats dans le back-face photo de valeur.
-
- * Android utilise également l'activité de récolte pour allowEdit, même si la récolte doit travailler et transmet en réalité l'image recadrée à Cordoue, le seul que les œuvres sont toujours celui livré avec l'application Google Plus Photos. Autres cultures peuvent ne pas fonctionner.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`et `Camera.PictureSourceType.SAVEDPHOTOALBUM` les deux affichent le même album photo.
-
-#### BlackBerry 10 Quirks
-
- * Ignore la `quality` paramètre.
-
- * Ignore la `allowEdit` paramètre.
-
- * `Camera.MediaType`n'est pas pris en charge.
-
- * Ignore la `correctOrientation` paramètre.
-
- * Ignore la `cameraDirection` paramètre.
-
-#### Firefox OS Quirks
-
- * Ignore la `quality` paramètre.
-
- * `Camera.DestinationType`est ignorée et est égal à `1` (URI du fichier image)
-
- * Ignore la `allowEdit` paramètre.
-
- * Ignore la `PictureSourceType` paramètre (utilisateur il choisit dans une fenêtre de dialogue)
-
- * Ignore le`encodingType`
-
- * Ignore la `targetWidth` et`targetHeight`
-
- * `Camera.MediaType`n'est pas pris en charge.
-
- * Ignore la `correctOrientation` paramètre.
-
- * Ignore la `cameraDirection` paramètre.
-
-#### Notes au sujet d'iOS
-
- * La valeur `quality` inférieur à 50 pour éviter les erreurs de mémoire sur certains appareils.
-
- * Lorsque vous utilisez `destinationType.FILE_URI` , les photos sont sauvegardées dans le répertoire temporaire de l'application. Le contenu du répertoire temporaire de l'application est supprimé lorsque l'application se termine.
-
-#### Bizarreries de paciarelli
-
- * options non prises en charge
-
- * retourne toujours un URI de fichier
-
-#### Notes au sujet de Windows Phone 7 et 8
-
- * Ignore la `allowEdit` paramètre.
-
- * Ignore la `correctOrientation` paramètre.
-
- * Ignore la `cameraDirection` paramètre.
-
- * Ignore la `saveToPhotoAlbum` paramètre. IMPORTANT : Toutes les images prises avec la caméra de cordova wp7/8 API sont toujours copiés au rôle d'appareil photo du téléphone. Selon les paramètres de l'utilisateur, cela pourrait également signifier que l'image est auto-téléchargées à leur OneDrive. Potentiellement, cela pourrait signifier que l'image est disponible à un public plus large que votre application destinée. Si ce un bloqueur pour votre application, vous devrez implémenter le CameraCaptureTask tel que documenté sur msdn : vous pouvez aussi commenter ou haut-vote la question connexe dans le [gestionnaire d'incidents](https://issues.apache.org/jira/browse/CB-2083)
-
- * Ignore la `mediaType` propriété de `cameraOptions` comme le kit de développement Windows Phone ne fournit pas un moyen de choisir les vidéos de PHOTOLIBRARY.
-
-## CameraError
-
-fonction de rappel onError qui fournit un message d'erreur.
-
- function(message) {/ / afficher un message utile}
-
-
-#### Description
-
- * **message**: le message est fourni par du code natif de l'appareil. *(String)*
-
-## cameraSuccess
-
-fonction de rappel onSuccess qui fournit les données d'image.
-
- function(ImageData) {/ / faire quelque chose avec l'image}
-
-
-#### Description
-
- * **imageData**: codage Base64 de l'image, *ou* le fichier image URI, selon `cameraOptions` en vigueur. *(String)*
-
-#### Exemple
-
- Afficher image / / function cameraCallback(imageData) {var image = document.getElementById('myImage') ;
- image.src = "données : image / jpeg ; base64," + imageData;}
-
-
-## CameraPopoverHandle
-
-Un handle vers la boîte de dialogue de kangourou créé par`navigator.camera.getPicture`.
-
-#### Description
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### Plates-formes supportées
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Exemple
-
- var cameraPopoverHandle = navigator.camera.getPicture (onSuccess, onFail, {destinationType : Camera.DestinationType.FILE_URI, TypeSource : Camera.PictureSourceType.PHOTOLIBRARY, popoverOptions : nouvelle CameraPopoverOptions (300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)}) ;
-
- Repositionner le kangourou si l'orientation change.
- Window.onorientationchange = function() {var cameraPopoverOptions = new CameraPopoverOptions (0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY) ;
- cameraPopoverHandle.setPosition(cameraPopoverOptions) ;
- }
-
-
-## CameraPopoverOptions
-
-iOS uniquement les paramètres qui spécifient la direction ancre élément emplacement et de la flèche de la kangourou lors de la sélection des images de la bibliothèque de l'iPad ou l'album.
-
- {x: 0, y: 32, largeur : 320, hauteur : 480, arrowDir : Camera.PopoverArrowDirection.ARROW_ANY} ;
-
-
-#### Description
-
- * **x**: coordonnée de pixel de l'élément de l'écran sur lequel ancrer le kangourou x. *(Nombre)*
-
- * **y**: coordonnée de y pixels de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
- * **largeur**: largeur, en pixels, de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
- * **hauteur**: hauteur, en pixels, de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
- * **arrowDir**: Direction de la flèche sur le kangourou doit pointer. Définies dans `Camera.PopoverArrowDirection` *(nombre)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Notez que la taille de la kangourou peut changer pour s'adapter à la direction de la flèche et l'orientation de l'écran. Assurez-vous que tenir compte des changements d'orientation lors de la spécification de l'emplacement d'élément d'ancrage.
-
-## Navigator.Camera.Cleanup
-
-Supprime les intermédiaires photos prises par la caméra de stockage temporaire.
-
- Navigator.Camera.Cleanup (cameraSuccess, cameraError) ;
-
-
-#### Description
-
-Supprime les intermédiaires les fichiers image qui sont gardées en dépôt temporaire après avoir appelé `camera.getPicture` . S'applique uniquement lorsque la valeur de `Camera.sourceType` est égale à `Camera.PictureSourceType.CAMERA` et le `Camera.destinationType` est égal à`Camera.DestinationType.FILE_URI`.
-
-#### Plates-formes supportées
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Exemple
-
- Navigator.Camera.Cleanup (onSuccess, onFail) ;
-
- fonction onSuccess() {console.log ("succès de caméra nettoyage.")}
-
- function onFail(message) {alert (' a échoué car: "+ message);}
\ No newline at end of file
diff --git a/doc/fr/index.md b/doc/fr/index.md
deleted file mode 100644
index ec005f0ac..000000000
--- a/doc/fr/index.md
+++ /dev/null
@@ -1,391 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Ce plugin définit un global `navigator.camera` objet qui fournit une API pour la prise de photos et de choisir des images de la bibliothèque d'images du système.
-
-Bien que l'objet est attaché à la portée globale `navigator` , il n'est pas disponible jusqu'après la `deviceready` événement.
-
- document.addEventListener (« deviceready », onDeviceReady, false) ;
- function onDeviceReady() {console.log(navigator.camera);}
-
-
-## Installation
-
- Cordova plugin ajouter cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Prend une photo à l'aide de la caméra, ou récupère une photo de la Galerie d'images de l'appareil. L'image est passé au rappel succès comme un codage base64 `String` , ou comme l'URI du fichier de l'image. La méthode elle-même retourne un `CameraPopoverHandle` objet qui permet de repositionner le kangourou de sélection de fichier.
-
- navigator.camera.getPicture (cameraSuccess, cameraError, cameraOptions) ;
-
-
-### Description
-
-Le `camera.getPicture` fonction ouvre l'application de caméra par défaut de l'appareil qui permet aux utilisateurs de prendre des photos. Ce comportement se produit par défaut, lorsque `Camera.sourceType` est égal à `Camera.PictureSourceType.CAMERA` . Une fois que l'utilisateur s'enclenche la photo, l'application appareil photo se ferme et l'application est restaurée.
-
-Si `Camera.sourceType` est `Camera.PictureSourceType.PHOTOLIBRARY` ou `Camera.PictureSourceType.SAVEDPHOTOALBUM` , puis un dialogue affiche qui permet aux utilisateurs de sélectionner une image existante. Le `camera.getPicture` retourne un `CameraPopoverHandle` objet, ce qui permet de repositionner le dialogue de sélection d'image, par exemple, lorsque l'orientation de l'appareil change.
-
-La valeur de retour est envoyée à la `cameraSuccess` la fonction de rappel, dans l'un des formats suivants, selon les `cameraOptions` :
-
-* A `String` contenant l'image photo codée en base64.
-
-* A `String` qui représente l'emplacement du fichier image sur le stockage local (par défaut).
-
-Vous pouvez faire ce que vous voulez avec l'image codée ou URI, par exemple :
-
-* Afficher l'image dans un ` ` tag, comme dans l'exemple ci-dessous
-
-* Enregistrer les données localement ( `LocalStorage` , [poids][1], etc..)
-
-* Publier les données sur un serveur distant
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**NOTE**: la résolution de Photo sur les nouveaux appareils est assez bonne. Photos sélectionnées de la Galerie de l'appareil ne sont pas réduites à une baisse de la qualité, même si un `quality` paramètre est spécifié. Pour éviter les problèmes de mémoire commun, définissez `Camera.destinationType` à `FILE_URI` au lieu de`DATA_URL`.
-
-### Plates-formes prises en charge
-
-* Amazon Fire OS
-* Android
-* BlackBerry 10
-* Navigateur
-* Firefox OS
-* iOS
-* Paciarelli
-* Windows Phone 7 et 8
-* Windows 8
-
-### Préférences (iOS)
-
-* **CameraUsesGeolocation** (boolean, par défaut, false). Pour capturer des images JPEG, true pour obtenir des données de géolocalisation dans l'en-tête EXIF. Cela va déclencher une demande d'autorisations de géolocalisation si défini à true.
-
-
-
-
-### Amazon Fire OS Quirks
-
-Amazon Fire OS utilise des intentions pour lancer l'activité de l'appareil photo sur l'appareil pour capturer des images et sur les téléphones avec peu de mémoire, l'activité de Cordova peut être tuée. Dans ce scénario, l'image peut ne pas apparaître lorsque l'activité de cordova est restaurée.
-
-### Quirks Android
-
-Android utilise des intentions pour lancer l'activité de l'appareil photo sur l'appareil pour capturer des images et sur les téléphones avec peu de mémoire, l'activité de Cordova peut être tuée. Dans ce scénario, l'image peut ne pas apparaître lorsque l'activité de Cordova est restaurée.
-
-### Bizarreries navigateur
-
-Peut retourner uniquement les photos comme image codée en base64.
-
-### Firefox OS Quirks
-
-Appareil photo plugin est actuellement mis en œuvre à l'aide [d'Activités sur le Web][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS Quirks
-
-Y compris un JavaScript `alert()` dans les deux le rappel fonctions peuvent causer des problèmes. Envelopper l'alerte dans un `setTimeout()` pour permettre le sélecteur d'image iOS ou kangourou pour fermer entièrement avant que l'alerte s'affiche :
-
- setTimeout(function() {/ / faire votre truc ici!}, 0) ;
-
-
-### Windows Phone 7 Quirks
-
-Invoquant l'application native caméra alors que l'appareil est connecté via Zune ne fonctionne pas et déclenche un rappel de l'erreur.
-
-### Bizarreries de paciarelli
-
-Paciarelli prend uniquement en charge un `destinationType` de `Camera.DestinationType.FILE_URI` et un `sourceType` de`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Exemple
-
-Prendre une photo, puis extrayez-la comme une image codée en base64 :
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- }) ;
-
- function onSuccess(imageData) {var image = document.getElementById('myImage') ;
- image.src = "données : image / jpeg ; base64," + imageData;}
-
- function onFail(message) {alert (' a échoué car: "+ message);}
-
-
-Prendre une photo et récupérer l'emplacement du fichier de l'image :
-
- navigator.camera.getPicture (onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI }) ;
-
- function onSuccess(imageURI) {var image = document.getElementById('myImage') ;
- image.SRC = imageURI ;
- } function onFail(message) {alert (' a échoué car: "+ message);}
-
-
-## CameraOptions
-
-Paramètres optionnels pour personnaliser les réglages de l'appareil.
-
- {qualité : destinationType 75,: Camera.DestinationType.DATA_URL, TypeSource : Camera.PictureSourceType.CAMERA, allowEdit : encodingType vrai,: Camera.EncodingType.JPEG, targetWidth : 100, targetHeight : 100, popoverOptions : CameraPopoverOptions, saveToPhotoAlbum : false} ;
-
-
-### Options
-
-* **qualité**: qualité de l'image enregistrée, exprimée en une gamme de 0 à 100, 100 étant généralement pleine résolution sans perte de compression de fichiers. La valeur par défaut est 50. *(Nombre)* (Notez que les informations sur la résolution de la caméra sont indisponibles).
-
-* **destinationType**: choisissez le format de la valeur de retour. La valeur par défaut est FILE_URI. Définies dans `navigator.camera.DestinationType` *(nombre)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: définissez la source de l'image. La valeur par défaut est la caméra. Définies dans `navigator.camera.PictureSourceType` *(nombre)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: permettre un montage simple d'image avant la sélection. *(Booléen)*
-
-* **encodingType**: choisir le fichier image retournée de codage. Valeur par défaut est JPEG. Définies dans `navigator.camera.EncodingType` *(nombre)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: largeur en pixels de l'image de l'échelle. Doit être utilisé avec **targetHeight**. Aspect ratio reste constant. *(Nombre)*
-
-* **targetHeight**: hauteur en pixels de l'image de l'échelle. Doit être utilisé avec **targetWidth**. Aspect ratio reste constant. *(Nombre)*
-
-* **mediaType**: définir le type de média pour choisir de. Ne fonctionne que quand `PictureSourceType` est `PHOTOLIBRARY` ou `SAVEDPHOTOALBUM` . Définies dans `nagivator.camera.MediaType` *(nombre)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. PAR DÉFAUT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: faire pivoter l'image afin de corriger l'orientation de l'appareil lors de la capture. *(Booléen)*
-
-* **saveToPhotoAlbum**: enregistrer l'image sur l'album photo sur l'appareil après la capture. *(Booléen)*
-
-* **popoverOptions**: iOS uniquement des options qui spécifient l'emplacement de kangourou dans iPad. Défini dans`CameraPopoverOptions`.
-
-* **cameraDirection**: choisissez la caméra à utiliser (ou dos-face). La valeur par défaut est de retour. Définies dans `navigator.camera.Direction` *(nombre)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Amazon Fire OS Quirks
-
-* Tout `cameraDirection` résultats dans le back-face photo de valeur.
-
-* Ignore la `allowEdit` paramètre.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`et `Camera.PictureSourceType.SAVEDPHOTOALBUM` les deux affichent le même album photo.
-
-### Quirks Android
-
-* Tout `cameraDirection` résultats dans le back-face photo de valeur.
-
-* Ignore la `allowEdit` paramètre.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`et `Camera.PictureSourceType.SAVEDPHOTOALBUM` les deux affichent le même album photo.
-
-### BlackBerry 10 Quirks
-
-* Ignore la `quality` paramètre.
-
-* Ignore la `allowEdit` paramètre.
-
-* `Camera.MediaType`n'est pas pris en charge.
-
-* Ignore la `correctOrientation` paramètre.
-
-* Ignore la `cameraDirection` paramètre.
-
-### Firefox OS Quirks
-
-* Ignore la `quality` paramètre.
-
-* `Camera.DestinationType`est ignorée et est égal à `1` (URI du fichier image)
-
-* Ignore la `allowEdit` paramètre.
-
-* Ignore la `PictureSourceType` paramètre (utilisateur il choisit dans une fenêtre de dialogue)
-
-* Ignore le`encodingType`
-
-* Ignore la `targetWidth` et`targetHeight`
-
-* `Camera.MediaType`n'est pas pris en charge.
-
-* Ignore la `correctOrientation` paramètre.
-
-* Ignore la `cameraDirection` paramètre.
-
-### iOS Quirks
-
-* La valeur `quality` inférieur à 50 pour éviter les erreurs de mémoire sur certains appareils.
-
-* Lorsque vous utilisez `destinationType.FILE_URI` , les photos sont sauvegardées dans le répertoire temporaire de l'application. Le contenu du répertoire temporaire de l'application est supprimé lorsque l'application se termine.
-
-### Bizarreries de paciarelli
-
-* options non prises en charge
-
-* retourne toujours un URI de fichier
-
-### Windows Phone 7 et 8 Quirks
-
-* Ignore la `allowEdit` paramètre.
-
-* Ignore la `correctOrientation` paramètre.
-
-* Ignore la `cameraDirection` paramètre.
-
-* Ignore la `saveToPhotoAlbum` paramètre. IMPORTANT : Toutes les images prises avec la caméra de cordova wp7/8 API sont toujours copiés au rôle d'appareil photo du téléphone. Selon les paramètres de l'utilisateur, cela pourrait également signifier que l'image est auto-téléchargées à leur OneDrive. Potentiellement, cela pourrait signifier que l'image est disponible à un public plus large que votre application destinée. Si ce un bloqueur pour votre application, vous devrez implémenter le CameraCaptureTask tel que documenté sur msdn : vous pouvez aussi commenter ou haut-vote la question connexe dans le [gestionnaire d'incidents][3]
-
-* Ignore la `mediaType` propriété de `cameraOptions` comme le kit de développement Windows Phone ne fournit pas un moyen de choisir les vidéos de PHOTOLIBRARY.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-fonction de rappel onError qui fournit un message d'erreur.
-
- function(message) {/ / afficher un message utile}
-
-
-### Paramètres
-
-* **message**: le message est fourni par du code natif de l'appareil. *(String)*
-
-## cameraSuccess
-
-fonction de rappel onSuccess qui fournit les données d'image.
-
- function(ImageData) {/ / faire quelque chose avec l'image}
-
-
-### Paramètres
-
-* **imageData**: codage Base64 de l'image, *ou* le fichier image URI, selon `cameraOptions` en vigueur. *(String)*
-
-### Exemple
-
- Afficher image / / function cameraCallback(imageData) {var image = document.getElementById('myImage') ;
- image.src = "données : image / jpeg ; base64," + imageData;}
-
-
-## CameraPopoverHandle
-
-Un handle vers la boîte de dialogue de kangourou créé par`navigator.camera.getPicture`.
-
-### Méthodes
-
-* **setPosition**: définir la position de la kangourou.
-
-### Plates-formes prises en charge
-
-* iOS
-
-### setPosition
-
-Définir la position de la kangourou.
-
-**Paramètres**:
-
-* `cameraPopoverOptions`: la `CameraPopoverOptions` qui spécifie la nouvelle position
-
-### Exemple
-
- var cameraPopoverHandle = navigator.camera.getPicture (onSuccess, onFail, {destinationType : Camera.DestinationType.FILE_URI, TypeSource : Camera.PictureSourceType.PHOTOLIBRARY, popoverOptions : nouvelle CameraPopoverOptions (300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)}) ;
-
- Repositionner le kangourou si l'orientation change.
- Window.onorientationchange = function() {var cameraPopoverOptions = new CameraPopoverOptions (0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY) ;
- cameraPopoverHandle.setPosition(cameraPopoverOptions) ;
- }
-
-
-## CameraPopoverOptions
-
-iOS uniquement les paramètres qui spécifient la direction ancre élément emplacement et de la flèche de la kangourou lors de la sélection des images de la bibliothèque de l'iPad ou l'album.
-
- {x: 0, y: 32, largeur : 320, hauteur : 480, arrowDir : Camera.PopoverArrowDirection.ARROW_ANY} ;
-
-
-### CameraPopoverOptions
-
-* **x**: coordonnée de pixel de l'élément de l'écran sur lequel ancrer le kangourou x. *(Nombre)*
-
-* **y**: coordonnée de y pixels de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
-* **largeur**: largeur, en pixels, de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
-* **hauteur**: hauteur, en pixels, de l'élément de l'écran sur lequel ancrer le kangourou. *(Nombre)*
-
-* **arrowDir**: Direction de la flèche sur le kangourou doit pointer. Définies dans `Camera.PopoverArrowDirection` *(nombre)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Notez que la taille de la kangourou peut changer pour s'adapter à la direction de la flèche et l'orientation de l'écran. Assurez-vous que tenir compte des changements d'orientation lors de la spécification de l'emplacement d'élément d'ancrage.
-
-## Navigator.Camera.Cleanup
-
-Supprime les intermédiaires photos prises par la caméra de stockage temporaire.
-
- Navigator.Camera.Cleanup (cameraSuccess, cameraError) ;
-
-
-### Description
-
-Supprime les intermédiaires les fichiers image qui sont gardées en dépôt temporaire après avoir appelé `camera.getPicture` . S'applique uniquement lorsque la valeur de `Camera.sourceType` est égale à `Camera.PictureSourceType.CAMERA` et le `Camera.destinationType` est égal à`Camera.DestinationType.FILE_URI`.
-
-### Plates-formes prises en charge
-
-* iOS
-
-### Exemple
-
- Navigator.Camera.Cleanup (onSuccess, onFail) ;
-
- fonction onSuccess() {console.log ("succès de caméra nettoyage.")}
-
- function onFail(message) {alert (' a échoué car: "+ message);}
diff --git a/doc/img/android-fail.png b/doc/img/android-fail.png
deleted file mode 100644
index f9e4e8628..000000000
Binary files a/doc/img/android-fail.png and /dev/null differ
diff --git a/doc/img/android-success.png b/doc/img/android-success.png
deleted file mode 100644
index 0bb9abd4a..000000000
Binary files a/doc/img/android-success.png and /dev/null differ
diff --git a/doc/img/blackberry-fail.png b/doc/img/blackberry-fail.png
deleted file mode 100644
index b89efaf13..000000000
Binary files a/doc/img/blackberry-fail.png and /dev/null differ
diff --git a/doc/img/blackberry-success.png b/doc/img/blackberry-success.png
deleted file mode 100644
index 286d0b9b8..000000000
Binary files a/doc/img/blackberry-success.png and /dev/null differ
diff --git a/doc/img/browser-fail.png b/doc/img/browser-fail.png
deleted file mode 100644
index 3894be67d..000000000
Binary files a/doc/img/browser-fail.png and /dev/null differ
diff --git a/doc/img/browser-success.png b/doc/img/browser-success.png
deleted file mode 100644
index 6c2c000e3..000000000
Binary files a/doc/img/browser-success.png and /dev/null differ
diff --git a/doc/img/firefox-fail.png b/doc/img/firefox-fail.png
deleted file mode 100644
index 2c6cbd190..000000000
Binary files a/doc/img/firefox-fail.png and /dev/null differ
diff --git a/doc/img/firefox-success.png b/doc/img/firefox-success.png
deleted file mode 100644
index deb9d24ab..000000000
Binary files a/doc/img/firefox-success.png and /dev/null differ
diff --git a/doc/img/fireos-fail.png b/doc/img/fireos-fail.png
deleted file mode 100644
index b1e7b9b9e..000000000
Binary files a/doc/img/fireos-fail.png and /dev/null differ
diff --git a/doc/img/fireos-success.png b/doc/img/fireos-success.png
deleted file mode 100644
index 7b6289e06..000000000
Binary files a/doc/img/fireos-success.png and /dev/null differ
diff --git a/doc/img/ios-fail.png b/doc/img/ios-fail.png
deleted file mode 100644
index 2d8caf807..000000000
Binary files a/doc/img/ios-fail.png and /dev/null differ
diff --git a/doc/img/ios-success.png b/doc/img/ios-success.png
deleted file mode 100644
index 3bf3b5ac7..000000000
Binary files a/doc/img/ios-success.png and /dev/null differ
diff --git a/doc/img/ubuntu-fail.png b/doc/img/ubuntu-fail.png
deleted file mode 100644
index ca82c79fa..000000000
Binary files a/doc/img/ubuntu-fail.png and /dev/null differ
diff --git a/doc/img/ubuntu-success.png b/doc/img/ubuntu-success.png
deleted file mode 100644
index b15227db7..000000000
Binary files a/doc/img/ubuntu-success.png and /dev/null differ
diff --git a/doc/img/windows-fail.png b/doc/img/windows-fail.png
deleted file mode 100644
index 982a8cf2b..000000000
Binary files a/doc/img/windows-fail.png and /dev/null differ
diff --git a/doc/img/windows-success.png b/doc/img/windows-success.png
deleted file mode 100644
index b8ae79bb7..000000000
Binary files a/doc/img/windows-success.png and /dev/null differ
diff --git a/doc/img/wp8-fail.png b/doc/img/wp8-fail.png
deleted file mode 100644
index 28c458823..000000000
Binary files a/doc/img/wp8-fail.png and /dev/null differ
diff --git a/doc/img/wp8-success.png b/doc/img/wp8-success.png
deleted file mode 100644
index a37cad697..000000000
Binary files a/doc/img/wp8-success.png and /dev/null differ
diff --git a/doc/it/README.md b/doc/it/README.md
deleted file mode 100644
index 601f6f175..000000000
--- a/doc/it/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-Questo plugin definisce un oggetto globale `navigator.camera`, che fornisce un'API per scattare foto e per aver scelto immagini dalla libreria di immagini del sistema.
-
-Anche se l'oggetto è associato con ambito globale del `navigator`, non è disponibile fino a dopo l'evento `deviceready`.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Installazione
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * Fotocamera
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-Prende una foto utilizzando la fotocamera, o recupera una foto dalla galleria di immagini del dispositivo. L'immagine è passata al callback di successo come `String` con codifica base64, o come l'URI per il file di immagine. Lo stesso metodo restituisce un oggetto `CameraPopoverHandle` che può essere utilizzato per riposizionare il Muffin di selezione file.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### Descrizione
-
-La funzione `camera.getPicture` apre predefinito fotocamera applicazione il dispositivo che consente agli utenti di scattare foto. Questo comportamento si verifica per impostazione predefinita, quando `Camera.sourceType` è uguale a `Camera.PictureSourceType.CAMERA`. Una volta che l'utente scatta la foto, si chiude l'applicazione fotocamera e l'applicazione viene ripristinato.
-
-Se `Camera.sourceType` è `Camera.PictureSourceType.PHOTOLIBRARY` o `Camera.PictureSourceType.SAVEDPHOTOALBUM`, una finestra di dialogo Visualizza che permette agli utenti di selezionare un'immagine esistente. La funzione `camera.getPicture` restituisce un oggetto `CameraPopoverHandle` che può essere utilizzato per riposizionare la finestra di selezione immagine, ad esempio, quando l'orientamento del dispositivo.
-
-Il valore restituito viene inviato alla funzione di callback `cameraSuccess`, in uno dei seguenti formati, a seconda il `cameraOptions` specificato:
-
- * A `String` contenente l'immagine della foto con codifica base64.
-
- * A `String` che rappresenta il percorso del file di immagine su archiviazione locale (predefinito).
-
-Si può fare quello che vuoi con l'immagine codificata o URI, ad esempio:
-
- * Il rendering dell'immagine in un ` ` tag, come nell'esempio qui sotto
-
- * Salvare i dati localmente ( `LocalStorage` , [Lawnchair](http://brianleroux.github.com/lawnchair/), ecc.)
-
- * Inviare i dati a un server remoto
-
-**Nota**: risoluzione foto sui più recenti dispositivi è abbastanza buona. Foto selezionate dalla galleria del dispositivo non è percepiranno di qualità inferiore, anche se viene specificato un parametro di `quality`. Per evitare problemi di memoria comune, impostare `Camera.destinationType` `FILE_URI` piuttosto che `DATA_URL`.
-
-#### Piattaforme supportate
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### Esempio
-
-Scattare una foto e recuperarla come un'immagine con codifica base64:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Scattare una foto e recuperare il percorso del file dell'immagine:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### Preferenze (iOS)
-
- * **CameraUsesGeolocation** (boolean, default è false). Per l'acquisizione di immagini JPEG, impostato su true per ottenere dati di geolocalizzazione nell'intestazione EXIF. Questo innescherà una richiesta per le autorizzazioni di geolocalizzazione, se impostato su true.
-
-
-
-
-#### Amazon fuoco OS stranezze
-
-Amazon fuoco OS utilizza intenti a lanciare l'attività della fotocamera sul dispositivo per catturare immagini e sui telefoni con poca memoria, l'attività di Cordova può essere ucciso. In questo scenario, l'immagine potrebbe non apparire quando viene ripristinata l'attività di cordova.
-
-#### Stranezze Android
-
-Android utilizza intenti a lanciare l'attività della fotocamera sul dispositivo per catturare immagini e sui telefoni con poca memoria, l'attività di Cordova può essere ucciso. In questo scenario, l'immagine potrebbe non apparire quando viene ripristinata l'attività di Cordova.
-
-#### Stranezze browser
-
-Può restituire solo la foto come immagine con codifica base64.
-
-#### Firefox OS stranezze
-
-Fotocamera plugin è attualmente implementato mediante [Web Activities](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### iOS stranezze
-
-Compreso un JavaScript `alert()` in una delle funzioni di callback può causare problemi. Avvolgere l'avviso all'interno di un `setTimeout()` per consentire la selezione immagine iOS o muffin per chiudere completamente la prima che viene visualizzato l'avviso:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 capricci
-
-Richiamando l'applicazione nativa fotocamera mentre il dispositivo è collegato tramite Zune non funziona e innesca un callback di errore.
-
-#### Tizen stranezze
-
-Tizen supporta solo a `destinationType` di `Camera.DestinationType.FILE_URI` e un `sourceType` di `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-## CameraOptions
-
-Parametri opzionali per personalizzare le impostazioni della fotocamera.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **quality**: qualità dell'immagine salvata, espressa come un intervallo di 0-100, dove 100 è tipicamente piena risoluzione senza perdita di compressione file. Il valore predefinito è 50. *(Numero)* (Si noti che informazioni sulla risoluzione della fotocamera non sono disponibile).
-
- * **destinationType**: Scegli il formato del valore restituito. Il valore predefinito è FILE_URI. Definito in `navigator.camera.DestinationType` *(numero)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: impostare l'origine dell'immagine. Il valore predefinito è la fotocamera. Definito in `navigator.camera.PictureSourceType` *(numero)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **Proprietà allowEdit**: consentire la semplice modifica dell'immagine prima di selezione. *(Booleano)*
-
- * **encodingType**: scegliere il file immagine restituita di codifica. Predefinito è JPEG. Definito in `navigator.camera.EncodingType` *(numero)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: larghezza in pixel all'immagine della scala. Deve essere usato con **targetHeight**. Proporzioni rimane costante. *(Numero)*
-
- * **targetHeight**: altezza in pixel all'immagine della scala. Deve essere usato con **targetWidth**. Proporzioni rimane costante. *(Numero)*
-
- * **mediaType**: impostare il tipo di supporto per scegliere da. Funziona solo quando `PictureSourceType` è `PHOTOLIBRARY` o `SAVEDPHOTOALBUM` . Definito in `nagivator.camera.MediaType` *(numero)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. PER IMPOSTAZIONE PREDEFINITA. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: ruotare l'immagine per correggere l'orientamento del dispositivo durante l'acquisizione. *(Booleano)*
-
- * **saveToPhotoAlbum**: salvare l'immagine nell'album di foto sul dispositivo dopo la cattura. *(Booleano)*
-
- * **popoverOptions**: solo iOS opzioni che specificano la posizione di muffin in iPad. Definito in`CameraPopoverOptions`.
-
- * **cameraDirection**: scegliere la telecamera da utilizzare (o retro-frontale). Il valore predefinito è tornato. Definito in `navigator.camera.Direction` *(numero)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### Amazon fuoco OS stranezze
-
- * Qualsiasi `cameraDirection` valore i risultati in una foto di lamatura.
-
- * Ignora il `allowEdit` parametro.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`e `Camera.PictureSourceType.SAVEDPHOTOALBUM` entrambi visualizzare l'album fotografico stesso.
-
-#### Stranezze Android
-
- * Qualsiasi `cameraDirection` valore i risultati in una foto di lamatura.
-
- * Android utilizza anche l'attività di ritaglio per allowEdit, anche se raccolto dovrebbe funzionare ed effettivamente passare l'immagine ritagliata a Cordova, l'unico che funziona è sempre quello in bundle con l'applicazione di Google Plus foto. Altre colture potrebbero non funzionare.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`e `Camera.PictureSourceType.SAVEDPHOTOALBUM` entrambi visualizzare l'album fotografico stesso.
-
-#### BlackBerry 10 capricci
-
- * Ignora il `quality` parametro.
-
- * Ignora il `allowEdit` parametro.
-
- * `Camera.MediaType`non è supportato.
-
- * Ignora il `correctOrientation` parametro.
-
- * Ignora il `cameraDirection` parametro.
-
-#### Firefox OS stranezze
-
- * Ignora il `quality` parametro.
-
- * `Camera.DestinationType`viene ignorato e corrisponde a `1` (URI del file di immagine)
-
- * Ignora il `allowEdit` parametro.
-
- * Ignora il `PictureSourceType` parametro (utente ne sceglie in una finestra di dialogo)
-
- * Ignora il`encodingType`
-
- * Ignora le `targetWidth` e`targetHeight`
-
- * `Camera.MediaType`non è supportato.
-
- * Ignora il `correctOrientation` parametro.
-
- * Ignora il `cameraDirection` parametro.
-
-#### iOS stranezze
-
- * Impostare `quality` inferiore al 50 per evitare errori di memoria su alcuni dispositivi.
-
- * Quando si utilizza `destinationType.FILE_URI` , foto vengono salvati nella directory temporanea dell'applicazione. Il contenuto della directory temporanea dell'applicazione viene eliminato quando l'applicazione termina.
-
-#### Tizen stranezze
-
- * opzioni non supportate
-
- * restituisce sempre un URI del FILE
-
-#### Windows Phone 7 e 8 stranezze
-
- * Ignora il `allowEdit` parametro.
-
- * Ignora il `correctOrientation` parametro.
-
- * Ignora il `cameraDirection` parametro.
-
- * Ignora il `saveToPhotoAlbum` parametro. IMPORTANTE: Tutte le immagini scattate con la fotocamera di cordova wp7/8 API vengono sempre copiate rotolo fotocamera del telefono cellulare. A seconda delle impostazioni dell'utente, questo potrebbe anche significare che l'immagine viene caricato in automatico a loro OneDrive. Questo potenzialmente potrebbe significare che l'immagine è disponibile a un pubblico più ampio di app destinate. Se questo un blocco dell'applicazione, sarà necessario implementare il CameraCaptureTask come documentato su msdn: si può anche commentare o up-voto la questione correlata nel [tracciatore di problemi](https://issues.apache.org/jira/browse/CB-2083)
-
- * Ignora la `mediaType` proprietà di `cameraOptions` come il SDK di Windows Phone non fornisce un modo per scegliere il video da PHOTOLIBRARY.
-
-## CameraError
-
-funzione di callback onError che fornisce un messaggio di errore.
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### Descrizione
-
- * **message**: il messaggio è fornito dal codice nativo del dispositivo. *(String)*
-
-## cameraSuccess
-
-funzione di callback onSuccess che fornisce i dati di immagine.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### Descrizione
-
- * **imageData**: Base64 codifica dei dati immagine, *o* il file di immagine URI, a seconda `cameraOptions` in vigore. *(String)*
-
-#### Esempio
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Un handle per la finestra di dialogo di muffin creato da `navigator.camera.getPicture`.
-
-#### Descrizione
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### Piattaforme supportate
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Esempio
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS solo parametri che specificano l'ancoraggio elemento posizione e freccia direzione il Muffin quando si selezionano le immagini dalla libreria un iPad o un album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### Descrizione
-
- * **x**: pixel coordinata x dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
- * **y**: coordinata y di pixel dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
- * **width**: larghezza, in pixel, dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
- * **height**: altezza, in pixel, dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
- * **arrowDir**: direzione dovrebbe puntare la freccia il muffin. Definito in `Camera.PopoverArrowDirection` *(numero)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Si noti che la dimensione del muffin possa cambiare per regolare la direzione della freccia e l'orientamento dello schermo. Assicurarsi che tenere conto di modifiche di orientamento quando si specifica la posizione di elemento di ancoraggio.
-
-## navigator.camera.cleanup
-
-Rimuove intermedio foto scattate con la fotocamera da deposito temporaneo.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### Descrizione
-
-Rimuove i file di immagine intermedia che vengono tenuti in custodia temporanea dopo la chiamata a `camera.getPicture`. Si applica solo quando il valore di `Camera.sourceType` è uguale a `Camera.PictureSourceType.CAMERA` e il `Camera.destinationType` è uguale a `Camera.DestinationType.FILE_URI`.
-
-#### Piattaforme supportate
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Esempio
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/it/index.md b/doc/it/index.md
deleted file mode 100644
index da0b919f0..000000000
--- a/doc/it/index.md
+++ /dev/null
@@ -1,434 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Questo plugin definisce un oggetto globale `navigator.camera`, che fornisce un'API per scattare foto e per aver scelto immagini dalla libreria di immagini del sistema.
-
-Anche se l'oggetto è associato con ambito globale del `navigator`, non è disponibile fino a dopo l'evento `deviceready`.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Installazione
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Prende una foto utilizzando la fotocamera, o recupera una foto dalla galleria di immagini del dispositivo. L'immagine è passata al callback di successo come `String` con codifica base64, o come l'URI per il file di immagine. Lo stesso metodo restituisce un oggetto `CameraPopoverHandle` che può essere utilizzato per riposizionare il Muffin di selezione file.
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### Descrizione
-
-La funzione `camera.getPicture` apre predefinito fotocamera applicazione il dispositivo che consente agli utenti di scattare foto. Questo comportamento si verifica per impostazione predefinita, quando `Camera.sourceType` è uguale a `Camera.PictureSourceType.CAMERA`. Una volta che l'utente scatta la foto, si chiude l'applicazione fotocamera e l'applicazione viene ripristinato.
-
-Se `Camera.sourceType` è `Camera.PictureSourceType.PHOTOLIBRARY` o `Camera.PictureSourceType.SAVEDPHOTOALBUM`, una finestra di dialogo Visualizza che permette agli utenti di selezionare un'immagine esistente. La funzione `camera.getPicture` restituisce un oggetto `CameraPopoverHandle` che può essere utilizzato per riposizionare la finestra di selezione immagine, ad esempio, quando l'orientamento del dispositivo.
-
-Il valore restituito viene inviato alla funzione di callback `cameraSuccess`, in uno dei seguenti formati, a seconda il `cameraOptions` specificato:
-
-* A `String` contenente l'immagine della foto con codifica base64.
-
-* A `String` che rappresenta il percorso del file di immagine su archiviazione locale (predefinito).
-
-Si può fare quello che vuoi con l'immagine codificata o URI, ad esempio:
-
-* Il rendering dell'immagine in un ` ` tag, come nell'esempio qui sotto
-
-* Salvare i dati localmente ( `LocalStorage` , [Lawnchair][1], ecc.)
-
-* Inviare i dati a un server remoto
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**Nota**: risoluzione foto sui più recenti dispositivi è abbastanza buona. Foto selezionate dalla galleria del dispositivo non è percepiranno di qualità inferiore, anche se viene specificato un parametro di `quality`. Per evitare problemi di memoria comune, impostare `Camera.destinationType` `FILE_URI` piuttosto che `DATA_URL`.
-
-### Piattaforme supportate
-
-* Amazon fuoco OS
-* Android
-* BlackBerry 10
-* Browser
-* Firefox OS
-* iOS
-* Tizen
-* Windows Phone 7 e 8
-* Windows 8
-
-### Preferenze (iOS)
-
-* **CameraUsesGeolocation** (boolean, default è false). Per l'acquisizione di immagini JPEG, impostato su true per ottenere dati di geolocalizzazione nell'intestazione EXIF. Questo innescherà una richiesta per le autorizzazioni di geolocalizzazione, se impostato su true.
-
-
-
-
-### Amazon fuoco OS stranezze
-
-Amazon fuoco OS utilizza intenti a lanciare l'attività della fotocamera sul dispositivo per catturare immagini e sui telefoni con poca memoria, l'attività di Cordova può essere ucciso. In questo scenario, l'immagine potrebbe non apparire quando viene ripristinata l'attività di cordova.
-
-### Stranezze Android
-
-Android utilizza intenti a lanciare l'attività della fotocamera sul dispositivo per catturare immagini e sui telefoni con poca memoria, l'attività di Cordova può essere ucciso. In questo scenario, l'immagine potrebbe non apparire quando viene ripristinata l'attività di Cordova.
-
-### Stranezze browser
-
-Può restituire solo la foto come immagine con codifica base64.
-
-### Firefox OS stranezze
-
-Fotocamera plugin è attualmente implementato mediante [Web Activities][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS stranezze
-
-Compreso un JavaScript `alert()` in una delle funzioni di callback può causare problemi. Avvolgere l'avviso all'interno di un `setTimeout()` per consentire la selezione immagine iOS o muffin per chiudere completamente la prima che viene visualizzato l'avviso:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Windows Phone 7 stranezze
-
-Richiamando l'applicazione nativa fotocamera mentre il dispositivo è collegato tramite Zune non funziona e innesca un callback di errore.
-
-### Tizen stranezze
-
-Tizen supporta solo a `destinationType` di `Camera.DestinationType.FILE_URI` e un `sourceType` di `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Esempio
-
-Scattare una foto e recuperarla come un'immagine con codifica base64:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Scattare una foto e recuperare il percorso del file dell'immagine:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-Parametri opzionali per personalizzare le impostazioni della fotocamera.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### Opzioni
-
-* **quality**: qualità dell'immagine salvata, espressa come un intervallo di 0-100, dove 100 è tipicamente piena risoluzione senza perdita di compressione file. Il valore predefinito è 50. *(Numero)* (Si noti che informazioni sulla risoluzione della fotocamera non sono disponibile).
-
-* **destinationType**: Scegli il formato del valore restituito. Il valore predefinito è FILE_URI. Definito in `navigator.camera.DestinationType` *(numero)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: impostare l'origine dell'immagine. Il valore predefinito è la fotocamera. Definito in `navigator.camera.PictureSourceType` *(numero)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **Proprietà allowEdit**: consentire la semplice modifica dell'immagine prima di selezione. *(Booleano)*
-
-* **encodingType**: scegliere il file immagine restituita di codifica. Predefinito è JPEG. Definito in `navigator.camera.EncodingType` *(numero)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: larghezza in pixel all'immagine della scala. Deve essere usato con **targetHeight**. Proporzioni rimane costante. *(Numero)*
-
-* **targetHeight**: altezza in pixel all'immagine della scala. Deve essere usato con **targetWidth**. Proporzioni rimane costante. *(Numero)*
-
-* **mediaType**: impostare il tipo di supporto per scegliere da. Funziona solo quando `PictureSourceType` è `PHOTOLIBRARY` o `SAVEDPHOTOALBUM` . Definito in `nagivator.camera.MediaType` *(numero)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. PER IMPOSTAZIONE PREDEFINITA. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: ruotare l'immagine per correggere l'orientamento del dispositivo durante l'acquisizione. *(Booleano)*
-
-* **saveToPhotoAlbum**: salvare l'immagine nell'album di foto sul dispositivo dopo la cattura. *(Booleano)*
-
-* **popoverOptions**: solo iOS opzioni che specificano la posizione di muffin in iPad. Definito in`CameraPopoverOptions`.
-
-* **cameraDirection**: scegliere la telecamera da utilizzare (o retro-frontale). Il valore predefinito è tornato. Definito in `navigator.camera.Direction` *(numero)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Amazon fuoco OS stranezze
-
-* Qualsiasi `cameraDirection` valore i risultati in una foto di lamatura.
-
-* Ignora il `allowEdit` parametro.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`e `Camera.PictureSourceType.SAVEDPHOTOALBUM` entrambi visualizzare l'album fotografico stesso.
-
-### Stranezze Android
-
-* Qualsiasi `cameraDirection` valore i risultati in una foto di lamatura.
-
-* Ignora il `allowEdit` parametro.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`e `Camera.PictureSourceType.SAVEDPHOTOALBUM` entrambi visualizzare l'album fotografico stesso.
-
-### BlackBerry 10 capricci
-
-* Ignora il `quality` parametro.
-
-* Ignora il `allowEdit` parametro.
-
-* `Camera.MediaType`non è supportato.
-
-* Ignora il `correctOrientation` parametro.
-
-* Ignora il `cameraDirection` parametro.
-
-### Firefox OS stranezze
-
-* Ignora il `quality` parametro.
-
-* `Camera.DestinationType`viene ignorato e corrisponde a `1` (URI del file di immagine)
-
-* Ignora il `allowEdit` parametro.
-
-* Ignora il `PictureSourceType` parametro (utente ne sceglie in una finestra di dialogo)
-
-* Ignora il`encodingType`
-
-* Ignora le `targetWidth` e`targetHeight`
-
-* `Camera.MediaType`non è supportato.
-
-* Ignora il `correctOrientation` parametro.
-
-* Ignora il `cameraDirection` parametro.
-
-### iOS stranezze
-
-* Impostare `quality` inferiore al 50 per evitare errori di memoria su alcuni dispositivi.
-
-* Quando si utilizza `destinationType.FILE_URI` , foto vengono salvati nella directory temporanea dell'applicazione. Il contenuto della directory temporanea dell'applicazione viene eliminato quando l'applicazione termina.
-
-### Tizen stranezze
-
-* opzioni non supportate
-
-* restituisce sempre un URI del FILE
-
-### Windows Phone 7 e 8 stranezze
-
-* Ignora il `allowEdit` parametro.
-
-* Ignora il `correctOrientation` parametro.
-
-* Ignora il `cameraDirection` parametro.
-
-* Ignora il `saveToPhotoAlbum` parametro. IMPORTANTE: Tutte le immagini scattate con la fotocamera di cordova wp7/8 API vengono sempre copiate rotolo fotocamera del telefono cellulare. A seconda delle impostazioni dell'utente, questo potrebbe anche significare che l'immagine viene caricato in automatico a loro OneDrive. Questo potenzialmente potrebbe significare che l'immagine è disponibile a un pubblico più ampio di app destinate. Se questo un blocco dell'applicazione, sarà necessario implementare il CameraCaptureTask come documentato su msdn: si può anche commentare o up-voto la questione correlata nel [tracciatore di problemi][3]
-
-* Ignora la `mediaType` proprietà di `cameraOptions` come il SDK di Windows Phone non fornisce un modo per scegliere il video da PHOTOLIBRARY.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-funzione di callback onError che fornisce un messaggio di errore.
-
- function(message) {
- // Show a helpful message
- }
-
-
-### Parametri
-
-* **message**: il messaggio è fornito dal codice nativo del dispositivo. *(String)*
-
-## cameraSuccess
-
-funzione di callback onSuccess che fornisce i dati di immagine.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### Parametri
-
-* **imageData**: Base64 codifica dei dati immagine, *o* il file di immagine URI, a seconda `cameraOptions` in vigore. *(String)*
-
-### Esempio
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Un handle per la finestra di dialogo di muffin creato da `navigator.camera.getPicture`.
-
-### Metodi
-
-* **setPosition**: impostare la posizione dei muffin.
-
-### Piattaforme supportate
-
-* iOS
-
-### setPosition
-
-Impostare la posizione dei muffin.
-
-**Parametri**:
-
-* `cameraPopoverOptions`: il `CameraPopoverOptions` che specificare la nuova posizione
-
-### Esempio
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS solo parametri che specificano l'ancoraggio elemento posizione e freccia direzione il Muffin quando si selezionano le immagini dalla libreria un iPad o un album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **x**: pixel coordinata x dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
-* **y**: coordinata y di pixel dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
-* **width**: larghezza, in pixel, dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
-* **height**: altezza, in pixel, dell'elemento dello schermo su cui ancorare il muffin. *(Numero)*
-
-* **arrowDir**: direzione dovrebbe puntare la freccia il muffin. Definito in `Camera.PopoverArrowDirection` *(numero)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Si noti che la dimensione del muffin possa cambiare per regolare la direzione della freccia e l'orientamento dello schermo. Assicurarsi che tenere conto di modifiche di orientamento quando si specifica la posizione di elemento di ancoraggio.
-
-## navigator.camera.cleanup
-
-Rimuove intermedio foto scattate con la fotocamera da deposito temporaneo.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### Descrizione
-
-Rimuove i file di immagine intermedia che vengono tenuti in custodia temporanea dopo la chiamata a `camera.getPicture`. Si applica solo quando il valore di `Camera.sourceType` è uguale a `Camera.PictureSourceType.CAMERA` e il `Camera.destinationType` è uguale a `Camera.DestinationType.FILE_URI`.
-
-### Piattaforme supportate
-
-* iOS
-
-### Esempio
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/ja/README.md b/doc/ja/README.md
deleted file mode 100644
index a50c18518..000000000
--- a/doc/ja/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-このプラグインは、写真を撮るため、システムのイメージ ライブラリからイメージを選択するために API を提供します、グローバル `navigator.camera` オブジェクトを定義します。
-
-オブジェクトは、グローバル スコープの `ナビゲーター` に添付、それがないまで `deviceready` イベントの後。
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## インストール
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * カメラ
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-カメラを使用して写真を取るか、デバイスの画像ギャラリーから写真を取得します。 イメージが渡されます成功時のコールバックを base64 エンコードされた `文字列`、または、URI としてイメージ ファイル。 メソッド自体はファイル選択ポップ オーバーの位置を変更するために使用できる `CameraPopoverHandle` オブジェクトを返します。
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### 解説
-
-`camera.getPicture` 関数は、ユーザーの写真をスナップすることができますデバイスのデフォルト カメラ アプリケーションを開きます。 `Camera.sourceType` が `Camera.PictureSourceType.CAMERA` と等しい場合既定では、この現象が発生します。 ユーザーは写真をスナップ、カメラ アプリケーションを閉じるし、アプリケーションが復元されます。
-
-`Camera.sourceType` `Camera.PictureSourceType.PHOTOLIBRARY` または `Camera.PictureSourceType.SAVEDPHOTOALBUM` の場合、ダイアログ ボックスはユーザーを既存のイメージを選択することができますが表示されます。 `camera.getPicture` 関数は、デバイスの向きが変更されたとき、たとえば、イメージの選択ダイアログには、位置を変更するために使用することができます、`CameraPopoverHandle` オブジェクトを返します。
-
-戻り値が `cameraSuccess` コールバック関数の指定 `cameraOptions` に応じて、次の形式のいずれかに送信されます。
-
- * A `String` 写真の base64 でエンコードされたイメージを含んでいます。
-
- * A `String` (既定値) のローカル記憶域上のイメージ ファイルの場所を表します。
-
-自由に変更、エンコードされたイメージ、または URI などを行うことができます。
-
- * イメージをレンダリングする ` ` 以下の例のように、タグ
-
- * ローカル データの保存 ( `LocalStorage` 、 [Lawnchair](http://brianleroux.github.com/lawnchair/)など)。
-
- * リモート サーバーにデータを投稿します。
-
-**注**: 新しいデバイス上の写真の解像度はかなり良いです。 デバイスのギャラリーから選択した写真は `quality` パラメーターが指定されて場合でも下方の品質に縮小されません。 一般的なメモリの問題を避けるために `DATA_URL` ではなく `FILE_URI` に `Camera.destinationType` を設定します。.
-
-#### サポートされているプラットフォーム
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### 例
-
-写真を撮るし、base64 エンコード イメージとして取得します。
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-写真を撮るし、イメージのファイルの場所を取得します。
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### 環境設定 (iOS)
-
- * **CameraUsesGeolocation**(ブール値、デフォルトは false)。 Jpeg 画像をキャプチャするため EXIF ヘッダーで地理位置情報データを取得する場合は true に設定します。 これは、場合地理位置情報のアクセス許可に対する要求をトリガーする true に設定します。
-
-
-
-
-#### アマゾン火 OS 癖
-
-アマゾン火 OS イメージをキャプチャするデバイス上のカメラの活動を開始する意図を使用して、メモリの少ない携帯電話、コルドバ活動が殺されるかもしれない。 このシナリオではコルドバ活動が復元されると、イメージが表示されません。
-
-#### Android の癖
-
-アンドロイド、イメージをキャプチャするデバイス上でカメラのアクティビティを開始する意図を使用し、メモリの少ない携帯電話、コルドバ活動が殺されるかもしれない。 このシナリオではコルドバ活動が復元されると、イメージが表示されません。
-
-#### ブラウザーの癖
-
-Base64 エンコード イメージとして写真を返すのみことができます。
-
-#### Firefox OS 癖
-
-カメラのプラグインは現在、[Web アクティビティ](https://hacks.mozilla.org/2013/01/introducing-web-activities/) を使用して実装されていた.
-
-#### iOS の癖
-
-コールバック関数のいずれかの JavaScript `alert()` を含む問題が発生することができます。 IOS イメージ ピッカーまたは完全が終了するまで、警告が表示されますポップ オーバーを許可する `setTimeout()` 内でアラートをラップします。
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 の癖
-
-ネイティブ カメラ アプリケーションを呼び出すと、デバイスが Zune を介して接続されている動作しませんし、エラー コールバックをトリガーします。
-
-#### Tizen の癖
-
-Tizen のみ `Camera.DestinationType.FILE_URI` の `destinationType` と `Camera.PictureSourceType.PHOTOLIBRARY` の `sourceType` をサポートしています.
-
-## CameraOptions
-
-カメラの設定をカスタマイズするオプションのパラメーター。
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **quality**: 0-100、100 がファイルの圧縮から損失なしで通常のフル解像度の範囲で表される、保存されたイメージの品質。 既定値は 50 です。 *(数)*(カメラの解像度についての情報が利用できないことに注意してください)。
-
- * **destinationType**: 戻り値の形式を選択します。既定値は FILE_URI です。定義されている `navigator.camera.DestinationType` *(番号)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: 画像のソースを設定します。既定値は、カメラです。定義されている `navigator.camera.PictureSourceType` *(番号)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: 単純な選択の前に画像の編集を許可します。*(ブール値)*
-
- * **encodingType**: 返されるイメージ ファイルのエンコーディングを選択します。デフォルトは JPEG です。定義されている `navigator.camera.EncodingType` *(番号)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: スケール イメージにピクセル単位の幅。**TargetHeight**を使用する必要があります。縦横比は変わりません。*(数)*
-
- * **targetHeight**: スケール イメージにピクセル単位の高さ。**TargetWidth**を使用する必要があります。縦横比は変わりません。*(数)*
-
- * **mediaType**: から選択するメディアの種類を設定します。 場合にのみ働きます `PictureSourceType` は `PHOTOLIBRARY` または `SAVEDPHOTOALBUM` 。 定義されている `nagivator.camera.MediaType` *(番号)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DEFAULT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: キャプチャ中に、デバイスの向きを修正する画像を回転させます。*(ブール値)*
-
- * **saveToPhotoAlbum**: キャプチャ後、デバイス上のフォト アルバムに画像を保存します。*(ブール値)*
-
- * **popoverOptions**: iPad のポップ オーバーの場所を指定する iOS のみのオプションです。定義されています。`CameraPopoverOptions`.
-
- * **cameraDirection**: (前面または背面側) を使用するカメラを選択します。既定値は戻るです。定義されている `navigator.camera.Direction` *(番号)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### アマゾン火 OS 癖
-
- * 任意 `cameraDirection` 背面写真で結果の値します。
-
- * 無視、 `allowEdit` パラメーター。
-
- * `Camera.PictureSourceType.PHOTOLIBRARY``Camera.PictureSourceType.SAVEDPHOTOALBUM`両方のアルバムが表示されます同じ写真。
-
-#### Android の癖
-
- * 任意 `cameraDirection` 背面写真で結果の値します。
-
- * アンドロイドも使用しています作物活性、allowEdit もトリミングする必要があります動作し、実際にトリミングされた画像をコルドバで 1 つだけの作品一貫して Google プラス写真アプリケーションにバンドルされているものであることに渡します。 他の作物が機能しません。
-
- * `Camera.PictureSourceType.PHOTOLIBRARY``Camera.PictureSourceType.SAVEDPHOTOALBUM`両方のアルバムが表示されます同じ写真。
-
-#### ブラックベリー 10 癖
-
- * 無視、 `quality` パラメーター。
-
- * 無視、 `allowEdit` パラメーター。
-
- * `Camera.MediaType`サポートされていません。
-
- * 無視、 `correctOrientation` パラメーター。
-
- * 無視、 `cameraDirection` パラメーター。
-
-#### Firefox OS 癖
-
- * 無視、 `quality` パラメーター。
-
- * `Camera.DestinationType`無視され、等しい `1` (イメージ ファイル URI)
-
- * 無視、 `allowEdit` パラメーター。
-
- * 無視、 `PictureSourceType` パラメーター (ユーザーが選択ダイアログ ウィンドウに)
-
- * 無視します、`encodingType`
-
- * 無視、 `targetWidth` と`targetHeight`
-
- * `Camera.MediaType`サポートされていません。
-
- * 無視、 `correctOrientation` パラメーター。
-
- * 無視、 `cameraDirection` パラメーター。
-
-#### iOS の癖
-
- * 設定 `quality` 一部のデバイスでメモリ不足エラーを避けるために 50 の下。
-
- * 使用する場合 `destinationType.FILE_URI` 、写真、アプリケーションの一時ディレクトリに保存されます。アプリケーションの一時ディレクトリの内容は、アプリケーションの終了時に削除されます。
-
-#### Tizen の癖
-
- * サポートされていないオプション
-
- * 常にファイルの URI を返す
-
-#### Windows Phone 7 と 8 癖
-
- * 無視、 `allowEdit` パラメーター。
-
- * 無視、 `correctOrientation` パラメーター。
-
- * 無視、 `cameraDirection` パラメーター。
-
- * 無視、 `saveToPhotoAlbum` パラメーター。 重要: wp7/8 コルドバ カメラ API で撮影したすべての画像は携帯電話のカメラ巻き物に常にコピーします。 ユーザーの設定に応じて、これも、画像はその OneDrive に自動アップロードを意味できます。 イメージは意図したアプリより広い聴衆に利用できる可能性があります可能性があります。 場合は、このアプリケーションのブロッカー、msdn で説明されているように、CameraCaptureTask を実装する必要があります: コメントにすることがありますもかアップ投票関連の問題を[課題追跡システム](https://issues.apache.org/jira/browse/CB-2083)で
-
- * 無視、 `mediaType` のプロパティ `cameraOptions` として Windows Phone SDK には、フォト ライブラリからビデオを選択する方法は行いません。
-
-## CameraError
-
-エラー メッセージを提供する onError コールバック関数。
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### 解説
-
- * **message**: メッセージは、デバイスのネイティブ コードによって提供されます。*(文字列)*
-
-## cameraSuccess
-
-画像データを提供する onSuccess コールバック関数。
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### 解説
-
- * **imagedata を扱う**: Base64 エンコード イメージのデータ、*または*画像ファイルによって URI の `cameraOptions` 効果。*(文字列)*
-
-#### 例
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-`Navigator.camera.getPicture` によって作成されたポップオーバーパン ダイアログ ボックスへのハンドル.
-
-#### 解説
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### サポートされているプラットフォーム
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 例
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS だけ指定パラメーターをポップ オーバーのアンカー要素の場所および矢印方向計算されたライブラリまたはアルバムから画像を選択するとき。
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### 解説
-
- * **x**: ピクセルの x 座標画面要素にポップ オーバーのアンカーになります。*(数)*
-
- * **y**: y ピクセル座標の画面要素にポップ オーバーのアンカーになります。*(数)*
-
- * **width**: ポップ オーバーのアンカーになる上の画面要素のピクセル単位の幅。*(数)*
-
- * **height**: ポップ オーバーのアンカーになる上の画面要素のピクセル単位の高さ。*(数)*
-
- * **arrowDir**: 方向のポップ オーバーで矢印をポイントする必要があります。定義されている `Camera.PopoverArrowDirection` *(番号)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-矢印の方向と、画面の向きを調整するポップ オーバーのサイズを変更可能性がありますに注意してください。 アンカー要素の位置を指定するときの方向の変化を考慮することを確認します。
-
-## navigator.camera.cleanup
-
-削除中間一時ストレージからカメラで撮影した写真。
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### 解説
-
-`camera.getPicture` を呼び出した後一時記憶域に保存されている中間画像ファイルを削除します。 `Camera.sourceType` の値が `Camera.PictureSourceType.CAMERA` に等しい、`Camera.destinationType` が `Camera.DestinationType.FILE_URI` と等しいの場合にのみ適用されます。.
-
-#### サポートされているプラットフォーム
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 例
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/ja/index.md b/doc/ja/index.md
deleted file mode 100644
index 5bdb3e1b9..000000000
--- a/doc/ja/index.md
+++ /dev/null
@@ -1,434 +0,0 @@
-
-
-# cordova-plugin-camera
-
-このプラグインは、写真を撮るため、システムのイメージ ライブラリからイメージを選択するために API を提供します、グローバル `navigator.camera` オブジェクトを定義します。
-
-オブジェクトは、グローバル スコープの `ナビゲーター` に添付、それがないまで `deviceready` イベントの後。
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## インストール
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-カメラを使用して写真を取るか、デバイスの画像ギャラリーから写真を取得します。 イメージが渡されます成功時のコールバックを base64 エンコードされた `文字列`、または、URI としてイメージ ファイル。 メソッド自体はファイル選択ポップ オーバーの位置を変更するために使用できる `CameraPopoverHandle` オブジェクトを返します。
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### 解説
-
-`camera.getPicture` 関数は、ユーザーの写真をスナップすることができますデバイスのデフォルト カメラ アプリケーションを開きます。 `Camera.sourceType` が `Camera.PictureSourceType.CAMERA` と等しい場合既定では、この現象が発生します。 ユーザーは写真をスナップ、カメラ アプリケーションを閉じるし、アプリケーションが復元されます。
-
-`Camera.sourceType` `Camera.PictureSourceType.PHOTOLIBRARY` または `Camera.PictureSourceType.SAVEDPHOTOALBUM` の場合、ダイアログ ボックスはユーザーを既存のイメージを選択することができますが表示されます。 `camera.getPicture` 関数は、デバイスの向きが変更されたとき、たとえば、イメージの選択ダイアログには、位置を変更するために使用することができます、`CameraPopoverHandle` オブジェクトを返します。
-
-戻り値が `cameraSuccess` コールバック関数の指定 `cameraOptions` に応じて、次の形式のいずれかに送信されます。
-
-* A `String` 写真の base64 でエンコードされたイメージを含んでいます。
-
-* A `String` (既定値) のローカル記憶域上のイメージ ファイルの場所を表します。
-
-自由に変更、エンコードされたイメージ、または URI などを行うことができます。
-
-* イメージをレンダリングする ` ` 以下の例のように、タグ
-
-* ローカル データの保存 ( `LocalStorage` 、 [Lawnchair][1]など)。
-
-* リモート サーバーにデータを投稿します。
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**注**: 新しいデバイス上の写真の解像度はかなり良いです。 デバイスのギャラリーから選択した写真は `quality` パラメーターが指定されて場合でも下方の品質に縮小されません。 一般的なメモリの問題を避けるために `DATA_URL` ではなく `FILE_URI` に `Camera.destinationType` を設定します。.
-
-### サポートされているプラットフォーム
-
-* アマゾン火 OS
-* アンドロイド
-* ブラックベリー 10
-* ブラウザー
-* Firefox の OS
-* iOS
-* Tizen
-* Windows Phone 7 と 8
-* Windows 8
-
-### 環境設定 (iOS)
-
-* **CameraUsesGeolocation**(ブール値、デフォルトは false)。 Jpeg 画像をキャプチャするため EXIF ヘッダーで地理位置情報データを取得する場合は true に設定します。 これは、場合地理位置情報のアクセス許可に対する要求をトリガーする true に設定します。
-
-
-
-
-### アマゾン火 OS 癖
-
-アマゾン火 OS イメージをキャプチャするデバイス上のカメラの活動を開始する意図を使用して、メモリの少ない携帯電話、コルドバ活動が殺されるかもしれない。 このシナリオではコルドバ活動が復元されると、イメージが表示されません。
-
-### Android の癖
-
-アンドロイド、イメージをキャプチャするデバイス上でカメラのアクティビティを開始する意図を使用し、メモリの少ない携帯電話、コルドバ活動が殺されるかもしれない。 このシナリオではコルドバ活動が復元されると、イメージが表示されません。
-
-### ブラウザーの癖
-
-Base64 エンコード イメージとして写真を返すのみことができます。
-
-### Firefox OS 癖
-
-カメラのプラグインは現在、[Web アクティビティ][2] を使用して実装されていた.
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS の癖
-
-コールバック関数のいずれかの JavaScript `alert()` を含む問題が発生することができます。 IOS イメージ ピッカーまたは完全が終了するまで、警告が表示されますポップ オーバーを許可する `setTimeout()` 内でアラートをラップします。
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Windows Phone 7 の癖
-
-ネイティブ カメラ アプリケーションを呼び出すと、デバイスが Zune を介して接続されている動作しませんし、エラー コールバックをトリガーします。
-
-### Tizen の癖
-
-Tizen のみ `Camera.DestinationType.FILE_URI` の `destinationType` と `Camera.PictureSourceType.PHOTOLIBRARY` の `sourceType` をサポートしています.
-
-### 例
-
-写真を撮るし、base64 エンコード イメージとして取得します。
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-写真を撮るし、イメージのファイルの場所を取得します。
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-カメラの設定をカスタマイズするオプションのパラメーター。
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### オプション
-
-* **quality**: 0-100、100 がファイルの圧縮から損失なしで通常のフル解像度の範囲で表される、保存されたイメージの品質。 既定値は 50 です。 *(数)*(カメラの解像度についての情報が利用できないことに注意してください)。
-
-* **destinationType**: 戻り値の形式を選択します。既定値は FILE_URI です。定義されている `navigator.camera.DestinationType` *(番号)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: 画像のソースを設定します。既定値は、カメラです。定義されている `navigator.camera.PictureSourceType` *(番号)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: 単純な選択の前に画像の編集を許可します。*(ブール値)*
-
-* **encodingType**: 返されるイメージ ファイルのエンコーディングを選択します。デフォルトは JPEG です。定義されている `navigator.camera.EncodingType` *(番号)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: スケール イメージにピクセル単位の幅。**TargetHeight**を使用する必要があります。縦横比は変わりません。*(数)*
-
-* **targetHeight**: スケール イメージにピクセル単位の高さ。**TargetWidth**を使用する必要があります。縦横比は変わりません。*(数)*
-
-* **mediaType**: から選択するメディアの種類を設定します。 場合にのみ働きます `PictureSourceType` は `PHOTOLIBRARY` または `SAVEDPHOTOALBUM` 。 定義されている `nagivator.camera.MediaType` *(番号)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DEFAULT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: キャプチャ中に、デバイスの向きを修正する画像を回転させます。*(ブール値)*
-
-* **saveToPhotoAlbum**: キャプチャ後、デバイス上のフォト アルバムに画像を保存します。*(ブール値)*
-
-* **popoverOptions**: iPad のポップ オーバーの場所を指定する iOS のみのオプションです。定義されています。`CameraPopoverOptions`.
-
-* **cameraDirection**: (前面または背面側) を使用するカメラを選択します。既定値は戻るです。定義されている `navigator.camera.Direction` *(番号)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### アマゾン火 OS 癖
-
-* 任意 `cameraDirection` 背面写真で結果の値します。
-
-* 無視、 `allowEdit` パラメーター。
-
-* `Camera.PictureSourceType.PHOTOLIBRARY``Camera.PictureSourceType.SAVEDPHOTOALBUM`両方のアルバムが表示されます同じ写真。
-
-### Android の癖
-
-* 任意 `cameraDirection` 背面写真で結果の値します。
-
-* 無視、 `allowEdit` パラメーター。
-
-* `Camera.PictureSourceType.PHOTOLIBRARY``Camera.PictureSourceType.SAVEDPHOTOALBUM`両方のアルバムが表示されます同じ写真。
-
-### ブラックベリー 10 癖
-
-* 無視、 `quality` パラメーター。
-
-* 無視、 `allowEdit` パラメーター。
-
-* `Camera.MediaType`サポートされていません。
-
-* 無視、 `correctOrientation` パラメーター。
-
-* 無視、 `cameraDirection` パラメーター。
-
-### Firefox OS 癖
-
-* 無視、 `quality` パラメーター。
-
-* `Camera.DestinationType`無視され、等しい `1` (イメージ ファイル URI)
-
-* 無視、 `allowEdit` パラメーター。
-
-* 無視、 `PictureSourceType` パラメーター (ユーザーが選択ダイアログ ウィンドウに)
-
-* 無視します、`encodingType`
-
-* 無視、 `targetWidth` と`targetHeight`
-
-* `Camera.MediaType`サポートされていません。
-
-* 無視、 `correctOrientation` パラメーター。
-
-* 無視、 `cameraDirection` パラメーター。
-
-### iOS の癖
-
-* 設定 `quality` 一部のデバイスでメモリ不足エラーを避けるために 50 の下。
-
-* 使用する場合 `destinationType.FILE_URI` 、写真、アプリケーションの一時ディレクトリに保存されます。アプリケーションの一時ディレクトリの内容は、アプリケーションの終了時に削除されます。
-
-### Tizen の癖
-
-* サポートされていないオプション
-
-* 常にファイルの URI を返す
-
-### Windows Phone 7 と 8 癖
-
-* 無視、 `allowEdit` パラメーター。
-
-* 無視、 `correctOrientation` パラメーター。
-
-* 無視、 `cameraDirection` パラメーター。
-
-* 無視、 `saveToPhotoAlbum` パラメーター。 重要: wp7/8 コルドバ カメラ API で撮影したすべての画像は携帯電話のカメラ巻き物に常にコピーします。 ユーザーの設定に応じて、これも、画像はその OneDrive に自動アップロードを意味できます。 イメージは意図したアプリより広い聴衆に利用できる可能性があります可能性があります。 場合は、このアプリケーションのブロッカー、msdn で説明されているように、CameraCaptureTask を実装する必要があります: コメントにすることがありますもかアップ投票関連の問題を[課題追跡システム][3]で
-
-* 無視、 `mediaType` のプロパティ `cameraOptions` として Windows Phone SDK には、フォト ライブラリからビデオを選択する方法は行いません。
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-エラー メッセージを提供する onError コールバック関数。
-
- function(message) {
- // Show a helpful message
- }
-
-
-### パラメーター
-
-* **message**: メッセージは、デバイスのネイティブ コードによって提供されます。*(文字列)*
-
-## cameraSuccess
-
-画像データを提供する onSuccess コールバック関数。
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### パラメーター
-
-* **imagedata を扱う**: Base64 エンコード イメージのデータ、*または*画像ファイルによって URI の `cameraOptions` 効果。*(文字列)*
-
-### 例
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-`Navigator.camera.getPicture` によって作成されたポップオーバーパン ダイアログ ボックスへのハンドル.
-
-### メソッド
-
-* **setPosition**: ポップ オーバーの位置を設定します。
-
-### サポートされているプラットフォーム
-
-* iOS
-
-### setPosition
-
-ポップ オーバーの位置を設定します。
-
-**パラメーター**:
-
-* `cameraPopoverOptions`:、 `CameraPopoverOptions` の新しい位置を指定します。
-
-### 例
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS だけ指定パラメーターをポップ オーバーのアンカー要素の場所および矢印方向計算されたライブラリまたはアルバムから画像を選択するとき。
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **x**: ピクセルの x 座標画面要素にポップ オーバーのアンカーになります。*(数)*
-
-* **y**: y ピクセル座標の画面要素にポップ オーバーのアンカーになります。*(数)*
-
-* **width**: ポップ オーバーのアンカーになる上の画面要素のピクセル単位の幅。*(数)*
-
-* **height**: ポップ オーバーのアンカーになる上の画面要素のピクセル単位の高さ。*(数)*
-
-* **arrowDir**: 方向のポップ オーバーで矢印をポイントする必要があります。定義されている `Camera.PopoverArrowDirection` *(番号)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-矢印の方向と、画面の向きを調整するポップ オーバーのサイズを変更可能性がありますに注意してください。 アンカー要素の位置を指定するときの方向の変化を考慮することを確認します。
-
-## navigator.camera.cleanup
-
-削除中間一時ストレージからカメラで撮影した写真。
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### 説明
-
-`camera.getPicture` を呼び出した後一時記憶域に保存されている中間画像ファイルを削除します。 `Camera.sourceType` の値が `Camera.PictureSourceType.CAMERA` に等しい、`Camera.destinationType` が `Camera.DestinationType.FILE_URI` と等しいの場合にのみ適用されます。.
-
-### サポートされているプラットフォーム
-
-* iOS
-
-### 例
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/ko/README.md b/doc/ko/README.md
deleted file mode 100644
index 7b7c2153f..000000000
--- a/doc/ko/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-이 플러그인 시스템의 이미지 라이브러리에서 이미지를 선택 및 사진 촬영을 위한 API를 제공 하는 글로벌 `navigator.camera` 개체를 정의 합니다.
-
-개체 `navigator` 글로벌 범위 첨부 아니에요 때까지 사용할 수 있는 `deviceready` 이벤트 후.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## 설치
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * 카메라
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-카메라를 사용 하 여 사진을 걸립니다 또는 소자의 이미지 갤러리에서 사진을 검색 합니다. 이미지는 성공 콜백에 전달 base64 인코딩된 `문자열` 또는 URI로 이미지 파일에 대 한. 방법 자체는 파일 선택 popover 위치를 사용할 수 있는 `CameraPopoverHandle` 개체를 반환 합니다.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### 설명
-
-`Camera.getPicture` 함수 스냅 사진을 사용자가 소자의 기본 카메라 응용 프로그램을 엽니다. 이 문제는 `Camera.sourceType` `Camera.PictureSourceType.CAMERA` 경우 기본적으로 발생 합니다. 일단 사용자 스냅 사진, 카메라 응용 프로그램 종료 하 고 응용 프로그램 복원 됩니다.
-
-`Camera.sourceType`은 `Camera.PictureSourceType.PHOTOLIBRARY` 또는 `Camera.PictureSourceType.SAVEDPHOTOALBUM`, 대화 상자가 사용자가 기존 이미지를 선택할 수 있도록 표시 됩니다. `camera.getPicture` 함수는 장치 방향 변경 될 때 이미지 선택 대화 상자, 예를 들어, 위치를 변경 하려면 사용할 수 있는 `CameraPopoverHandle` 개체를 반환 합니다.
-
-반환 값은 `cameraSuccess` 콜백 함수 지정된 `cameraOptions`에 따라 다음 형식 중 하나에 전송 됩니다.
-
- * A `String` base64 인코딩된 사진 이미지를 포함 합니다.
-
- * A `String` 로컬 저장소 (기본값)의 이미지 파일 위치를 나타내는.
-
-할 수 있는 당신이 원하는대로 인코딩된 이미지 또는 URI, 예를 들면:
-
- * 렌더링 이미지는 ` ` 아래 예제와 같이 태그
-
- * 로컬로 데이터를 저장 ( `LocalStorage` , [Lawnchair](http://brianleroux.github.com/lawnchair/), 등.)
-
- * 원격 서버에 데이터 게시
-
-**참고**: 더 새로운 장치에 사진 해상도 아주 좋은. 소자의 갤러리에서 선택 된 사진 `품질` 매개 변수를 지정 하는 경우에 낮은 품질에 관하여 하지는. 일반적인 메모리 문제를 피하기 위해 `DATA_URL` 보다 `FILE_URI` `Camera.destinationType` 설정.
-
-#### 지원 되는 플랫폼
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### 예를 들어
-
-촬영 및 base64 인코딩 이미지로 검색:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-촬영 하 고 이미지의 파일 위치를 검색:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### 환경 설정 (iOS)
-
- * **CameraUsesGeolocation** (boolean, 기본값: false)입니다. 캡처 Jpeg, EXIF 헤더에 지리적 데이터를 true로 설정 합니다. 이 경우 위치 정보 사용 권한에 대 한 요청을 일으킬 것 이다 true로 설정 합니다.
-
-
-
-
-#### 아마존 화재 OS 단점
-
-아마존 화재 OS 의도 사용 하 여 이미지 캡처 장치에서 카메라 활동을 시작 하 고 낮은 메모리와 휴대 전화에 코르 도우 바 활동 살해 수 있습니다. 코르도바 활동 복원 되 면이 시나리오에서는 이미지가 나타나지 않을 수 있습니다.
-
-#### 안 드 로이드 단점
-
-안 드 로이드 의도 사용 하 여 이미지 캡처 장치에서 카메라 활동을 시작 하 고 낮은 메모리와 휴대 전화에 코르 도우 바 활동 살해 수 있습니다. 코르도바 활동 복원 되 면이 시나리오에서는 이미지가 나타나지 않을 수 있습니다.
-
-#### 브라우저 만지면
-
-수 base64 인코딩 이미지로 사진을 반환 합니다.
-
-#### 파이어 폭스 OS 단점
-
-카메라 플러그인은 현재 [웹 활동](https://hacks.mozilla.org/2013/01/introducing-web-activities/)를 사용 하 여 구현.
-
-#### iOS 단점
-
-자바 `alert()`를 포함 하 여 콜백 함수 중 하나에 문제가 발생할 수 있습니다. 포장 허용 iOS 이미지 피커 또는 popover를 완벽 하 게 경고를 표시 하기 전에 닫습니다 `setTimeout()` 내에서 경고:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 단점
-
-장치 Zune 통해 연결 된 동안 네이티브 카메라 응용 프로그램을 호출 하면 작동 하지 않습니다 하 고 오류 콜백 트리거합니다.
-
-#### Tizen 특수
-
-`Camera.DestinationType.FILE_URI`의 `destinationType`와 `Camera.PictureSourceType.PHOTOLIBRARY`의 `sourceType` Tizen 지원.
-
-## CameraOptions
-
-카메라 설정을 사용자 지정 하는 선택적 매개 변수.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **품질**: 범위 0-100, 100은 파일 압축에서 손실 없이 일반적으로 전체 해상도 저장된 된 이미지의 품질. 기본값은 50입니다. *(수)* (Note 카메라의 해상도 대 한 정보는 사용할 수 없습니다.)
-
- * **destinationType**: 반환 값의 형식을 선택 합니다. 기본값은 FILE_URI입니다. 에 정의 된 `navigator.camera.DestinationType` *(수)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: 그림의 소스를 설정 합니다. 기본값은 카메라입니다. 에 정의 된 `navigator.camera.PictureSourceType` *(수)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: 선택 하기 전에 이미지의 간단한 편집을 허용 합니다. *(부울)*
-
- * **encodingType**: 반환 된 이미지 파일의 인코딩을 선택 합니다. 기본값은 JPEG입니다. 에 정의 된 `navigator.camera.EncodingType` *(수)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: 스케일 이미지를 픽셀 너비. **TargetHeight**와 함께 사용 해야 합니다. 가로 세로 비율이 일정 하 게 유지 합니다. *(수)*
-
- * **targetHeight**: 스케일 이미지를 픽셀 단위로 높이. **TargetWidth**와 함께 사용 해야 합니다. 가로 세로 비율이 일정 하 게 유지 합니다. *(수)*
-
- * **mediaType**:에서 선택 미디어 유형을 설정 합니다. 때에 작동 `PictureSourceType` 는 `PHOTOLIBRARY` 또는 `SAVEDPHOTOALBUM` . 에 정의 된 `nagivator.camera.MediaType` *(수)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. 기본입니다. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: 캡처 도중 장치의 방향에 대 한 해결 하기 위해 이미지를 회전 합니다. *(부울)*
-
- * **saveToPhotoAlbum**: 캡처 후 장치에서 사진 앨범에 이미지를 저장 합니다. *(부울)*
-
- * **popoverOptions**: iPad에 popover 위치를 지정 하는 iOS 전용 옵션. 에 정의 된`CameraPopoverOptions`.
-
- * **cameraDirection**: (앞 이나 뒤로-연결)를 사용 하 여 카메라를 선택 하십시오. 기본값은 다시. 에 정의 된 `navigator.camera.Direction` *(수)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### 아마존 화재 OS 단점
-
- * 어떤 `cameraDirection` 다시 연결 사진에 결과 값.
-
- * 무시는 `allowEdit` 매개 변수.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`그리고 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 둘 다 동일한 사진 앨범을 표시 합니다.
-
-#### 안 드 로이드 단점
-
- * 어떤 `cameraDirection` 다시 연결 사진에 결과 값.
-
- * 안 드 로이드도 사용 자르기 활동 allowEdit, 비록 작물 작업과 실제로 코르도바, 유일 하 게 작품 지속적으로 구글 플러스 사진 응용 프로그램과 함께 번들로 제공 하는 것은 등을 맞댄 자른된 이미지를 전달 해야 합니다. 다른 작물은 작동 하지 않을 수 있습니다.
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`그리고 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 둘 다 동일한 사진 앨범을 표시 합니다.
-
-#### 블랙베리 10 단점
-
- * 무시는 `quality` 매개 변수.
-
- * 무시는 `allowEdit` 매개 변수.
-
- * `Camera.MediaType`지원 되지 않습니다.
-
- * 무시는 `correctOrientation` 매개 변수.
-
- * 무시는 `cameraDirection` 매개 변수.
-
-#### 파이어 폭스 OS 단점
-
- * 무시는 `quality` 매개 변수.
-
- * `Camera.DestinationType`무시 되 고 `1` (이미지 파일 URI)
-
- * 무시는 `allowEdit` 매개 변수.
-
- * 무시는 `PictureSourceType` 매개 변수 (사용자가 선택 그것 대화 창에서)
-
- * 무시 하는`encodingType`
-
- * 무시는 `targetWidth` 와`targetHeight`
-
- * `Camera.MediaType`지원 되지 않습니다.
-
- * 무시는 `correctOrientation` 매개 변수.
-
- * 무시는 `cameraDirection` 매개 변수.
-
-#### iOS 단점
-
- * 설정 `quality` 일부 장치 메모리 오류를 피하기 위해 50 아래.
-
- * 사용 하는 경우 `destinationType.FILE_URI` , 사진 응용 프로그램의 임시 디렉터리에 저장 됩니다. 응용 프로그램이 종료 될 때 응용 프로그램의 임시 디렉터리의 내용은 삭제 됩니다.
-
-#### Tizen 특수
-
- * 지원 되지 않는 옵션
-
- * 항상 파일 URI를 반환 합니다.
-
-#### Windows Phone 7, 8 특수
-
- * 무시는 `allowEdit` 매개 변수.
-
- * 무시는 `correctOrientation` 매개 변수.
-
- * 무시는 `cameraDirection` 매개 변수.
-
- * 무시는 `saveToPhotoAlbum` 매개 변수. 중요: 모든 이미지 API wp7/8 코르도바 카메라로 촬영 항상 복사 됩니다 휴대 전화의 카메라 롤에. 사용자의 설정에 따라이 또한 그들의 OneDrive에 자동 업로드 이미지는 의미. 이 잠재적으로 이미지는 당신의 애플 리 케이 션을 위한 보다 넓은 청중에 게 사용할 수 있는 의미. 이 경우 응용 프로그램에 대 한 차단, 당신은 msdn에 설명 대로 단말기를 구현 해야 합니다: 수 있습니다 또한 의견 또는 [이슈 트래커](https://issues.apache.org/jira/browse/CB-2083) 에서 업-투표 관련된 문제
-
- * 무시는 `mediaType` 속성을 `cameraOptions` 으로 Windows Phone SDK PHOTOLIBRARY에서 비디오를 선택 하는 방법을 제공 하지 않습니다.
-
-## CameraError
-
-오류 메시지를 제공 하는 onError 콜백 함수.
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### 설명
-
- * **메시지**: 메시지는 장치의 네이티브 코드에 의해 제공 됩니다. *(문자열)*
-
-## cameraSuccess
-
-이미지 데이터를 제공 하는 onSuccess 콜백 함수.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### 설명
-
- * **imageData**: Base64 인코딩은 이미지 데이터, *또는* 이미지 파일에 따라 URI의 `cameraOptions` 적용. *(문자열)*
-
-#### 예를 들어
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-`navigator.camera.getPicture`에 의해 만들어진 popover 대화에 대 한 핸들.
-
-#### 설명
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### 지원 되는 플랫폼
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 예를 들어
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS 전용 매개 변수 iPad의 보관 함 또는 앨범에서 이미지를 선택 하면 앵커 요소 위치와 화살표의 방향으로 popover 지정 하는.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### 설명
-
- * **x**: x는 popover 앵커는 화면 요소의 픽셀 좌표. *(수)*
-
- * **y**: y 픽셀 좌표는 popover 앵커는 화면 요소입니다. *(수)*
-
- * **폭**: 폭 (픽셀)는 popover 앵커는 화면 요소. *(수)*
-
- * **높이**: 높이 (픽셀)는 popover 앵커는 화면 요소. *(수)*
-
- * **arrowDir**: 방향 화살표는 popover 가리켜야 합니다. 에 정의 된 `Camera.PopoverArrowDirection` *(수)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-참고는 popover의 크기 조정 화살표 방향 및 화면 방향 변경 될 수 있습니다. 앵커 요소 위치를 지정 하는 경우 방향 변경에 대 한 계정에 있는지 확인 합니다.
-
-## navigator.camera.cleanup
-
-제거 임시 저장소에서 카메라로 찍은 사진을 중간.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### 설명
-
-`camera.getPicture`를 호출한 후 임시 저장소에 보관 됩니다 중간 이미지 파일을 제거 합니다. `Camera.sourceType` 값은 `Camera.PictureSourceType.CAMERA` 및 `Camera.destinationType`와 `Camera.DestinationType.FILE_URI` 때만 적용 됩니다..
-
-#### 지원 되는 플랫폼
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 예를 들어
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/ko/index.md b/doc/ko/index.md
deleted file mode 100644
index 794aa9741..000000000
--- a/doc/ko/index.md
+++ /dev/null
@@ -1,434 +0,0 @@
-
-
-# cordova-plugin-camera
-
-이 플러그인 시스템의 이미지 라이브러리에서 이미지를 선택 및 사진 촬영을 위한 API를 제공 하는 글로벌 `navigator.camera` 개체를 정의 합니다.
-
-개체 `navigator` 글로벌 범위 첨부 아니에요 때까지 사용할 수 있는 `deviceready` 이벤트 후.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## 설치
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-카메라를 사용 하 여 사진을 걸립니다 또는 소자의 이미지 갤러리에서 사진을 검색 합니다. 이미지는 성공 콜백에 전달 base64 인코딩된 `문자열` 또는 URI로 이미지 파일에 대 한. 방법 자체는 파일 선택 popover 위치를 사용할 수 있는 `CameraPopoverHandle` 개체를 반환 합니다.
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### 설명
-
-`Camera.getPicture` 함수 스냅 사진을 사용자가 소자의 기본 카메라 응용 프로그램을 엽니다. 이 문제는 `Camera.sourceType` `Camera.PictureSourceType.CAMERA` 경우 기본적으로 발생 합니다. 일단 사용자 스냅 사진, 카메라 응용 프로그램 종료 하 고 응용 프로그램 복원 됩니다.
-
-`Camera.sourceType`은 `Camera.PictureSourceType.PHOTOLIBRARY` 또는 `Camera.PictureSourceType.SAVEDPHOTOALBUM`, 대화 상자가 사용자가 기존 이미지를 선택할 수 있도록 표시 됩니다. `camera.getPicture` 함수는 장치 방향 변경 될 때 이미지 선택 대화 상자, 예를 들어, 위치를 변경 하려면 사용할 수 있는 `CameraPopoverHandle` 개체를 반환 합니다.
-
-반환 값은 `cameraSuccess` 콜백 함수 지정된 `cameraOptions`에 따라 다음 형식 중 하나에 전송 됩니다.
-
-* A `String` base64 인코딩된 사진 이미지를 포함 합니다.
-
-* A `String` 로컬 저장소 (기본값)의 이미지 파일 위치를 나타내는.
-
-할 수 있는 당신이 원하는대로 인코딩된 이미지 또는 URI, 예를 들면:
-
-* 렌더링 이미지는 ` ` 아래 예제와 같이 태그
-
-* 로컬로 데이터를 저장 ( `LocalStorage` , [Lawnchair][1], 등.)
-
-* 원격 서버에 데이터 게시
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**참고**: 더 새로운 장치에 사진 해상도 아주 좋은. 소자의 갤러리에서 선택 된 사진 `품질` 매개 변수를 지정 하는 경우에 낮은 품질에 관하여 하지는. 일반적인 메모리 문제를 피하기 위해 `DATA_URL` 보다 `FILE_URI` `Camera.destinationType` 설정.
-
-### 지원 되는 플랫폼
-
-* 아마존 화재 운영 체제
-* 안 드 로이드
-* 블랙베리 10
-* 브라우저
-* Firefox 운영 체제
-* iOS
-* Tizen
-* Windows Phone 7과 8
-* 윈도우 8
-
-### 환경 설정 (iOS)
-
-* **CameraUsesGeolocation** (boolean, 기본값: false)입니다. 캡처 Jpeg, EXIF 헤더에 지리적 데이터를 true로 설정 합니다. 이 경우 위치 정보 사용 권한에 대 한 요청을 일으킬 것 이다 true로 설정 합니다.
-
-
-
-
-### 아마존 화재 OS 단점
-
-아마존 화재 OS 의도 사용 하 여 이미지 캡처 장치에서 카메라 활동을 시작 하 고 낮은 메모리와 휴대 전화에 코르 도우 바 활동 살해 수 있습니다. 코르도바 활동 복원 되 면이 시나리오에서는 이미지가 나타나지 않을 수 있습니다.
-
-### 안 드 로이드 단점
-
-안 드 로이드 의도 사용 하 여 이미지 캡처 장치에서 카메라 활동을 시작 하 고 낮은 메모리와 휴대 전화에 코르 도우 바 활동 살해 수 있습니다. 코르도바 활동 복원 되 면이 시나리오에서는 이미지가 나타나지 않을 수 있습니다.
-
-### 브라우저 만지면
-
-수 base64 인코딩 이미지로 사진을 반환 합니다.
-
-### 파이어 폭스 OS 단점
-
-카메라 플러그인은 현재 [웹 활동][2]를 사용 하 여 구현.
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS 단점
-
-자바 `alert()`를 포함 하 여 콜백 함수 중 하나에 문제가 발생할 수 있습니다. 포장 허용 iOS 이미지 피커 또는 popover를 완벽 하 게 경고를 표시 하기 전에 닫습니다 `setTimeout()` 내에서 경고:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Windows Phone 7 단점
-
-장치 Zune 통해 연결 된 동안 네이티브 카메라 응용 프로그램을 호출 하면 작동 하지 않습니다 하 고 오류 콜백 트리거합니다.
-
-### Tizen 특수
-
-`Camera.DestinationType.FILE_URI`의 `destinationType`와 `Camera.PictureSourceType.PHOTOLIBRARY`의 `sourceType` Tizen 지원.
-
-### 예를 들어
-
-촬영 및 base64 인코딩 이미지로 검색:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-촬영 하 고 이미지의 파일 위치를 검색:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-카메라 설정을 사용자 지정 하는 선택적 매개 변수.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### 옵션
-
-* **품질**: 범위 0-100, 100은 파일 압축에서 손실 없이 일반적으로 전체 해상도 저장된 된 이미지의 품질. 기본값은 50입니다. *(수)* (Note 카메라의 해상도 대 한 정보는 사용할 수 없습니다.)
-
-* **destinationType**: 반환 값의 형식을 선택 합니다. 기본값은 FILE_URI입니다. 에 정의 된 `navigator.camera.DestinationType` *(수)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: 그림의 소스를 설정 합니다. 기본값은 카메라입니다. 에 정의 된 `navigator.camera.PictureSourceType` *(수)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: 선택 하기 전에 이미지의 간단한 편집을 허용 합니다. *(부울)*
-
-* **encodingType**: 반환 된 이미지 파일의 인코딩을 선택 합니다. 기본값은 JPEG입니다. 에 정의 된 `navigator.camera.EncodingType` *(수)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: 스케일 이미지를 픽셀 너비. **TargetHeight**와 함께 사용 해야 합니다. 가로 세로 비율이 일정 하 게 유지 합니다. *(수)*
-
-* **targetHeight**: 스케일 이미지를 픽셀 단위로 높이. **TargetWidth**와 함께 사용 해야 합니다. 가로 세로 비율이 일정 하 게 유지 합니다. *(수)*
-
-* **mediaType**:에서 선택 미디어 유형을 설정 합니다. 때에 작동 `PictureSourceType` 는 `PHOTOLIBRARY` 또는 `SAVEDPHOTOALBUM` . 에 정의 된 `nagivator.camera.MediaType` *(수)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. 기본입니다. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: 캡처 도중 장치의 방향에 대 한 해결 하기 위해 이미지를 회전 합니다. *(부울)*
-
-* **saveToPhotoAlbum**: 캡처 후 장치에서 사진 앨범에 이미지를 저장 합니다. *(부울)*
-
-* **popoverOptions**: iPad에 popover 위치를 지정 하는 iOS 전용 옵션. 에 정의 된`CameraPopoverOptions`.
-
-* **cameraDirection**: (앞 이나 뒤로-연결)를 사용 하 여 카메라를 선택 하십시오. 기본값은 다시. 에 정의 된 `navigator.camera.Direction` *(수)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### 아마존 화재 OS 단점
-
-* 어떤 `cameraDirection` 다시 연결 사진에 결과 값.
-
-* 무시는 `allowEdit` 매개 변수.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`그리고 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 둘 다 동일한 사진 앨범을 표시 합니다.
-
-### 안 드 로이드 단점
-
-* 어떤 `cameraDirection` 다시 연결 사진에 결과 값.
-
-* 무시는 `allowEdit` 매개 변수.
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`그리고 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 둘 다 동일한 사진 앨범을 표시 합니다.
-
-### 블랙베리 10 단점
-
-* 무시는 `quality` 매개 변수.
-
-* 무시는 `allowEdit` 매개 변수.
-
-* `Camera.MediaType`지원 되지 않습니다.
-
-* 무시는 `correctOrientation` 매개 변수.
-
-* 무시는 `cameraDirection` 매개 변수.
-
-### 파이어 폭스 OS 단점
-
-* 무시는 `quality` 매개 변수.
-
-* `Camera.DestinationType`무시 되 고 `1` (이미지 파일 URI)
-
-* 무시는 `allowEdit` 매개 변수.
-
-* 무시는 `PictureSourceType` 매개 변수 (사용자가 선택 그것 대화 창에서)
-
-* 무시 하는`encodingType`
-
-* 무시는 `targetWidth` 와`targetHeight`
-
-* `Camera.MediaType`지원 되지 않습니다.
-
-* 무시는 `correctOrientation` 매개 변수.
-
-* 무시는 `cameraDirection` 매개 변수.
-
-### iOS 단점
-
-* 설정 `quality` 일부 장치 메모리 오류를 피하기 위해 50 아래.
-
-* 사용 하는 경우 `destinationType.FILE_URI` , 사진 응용 프로그램의 임시 디렉터리에 저장 됩니다. 응용 프로그램이 종료 될 때 응용 프로그램의 임시 디렉터리의 내용은 삭제 됩니다.
-
-### Tizen 특수
-
-* 지원 되지 않는 옵션
-
-* 항상 파일 URI를 반환 합니다.
-
-### Windows Phone 7, 8 특수
-
-* 무시는 `allowEdit` 매개 변수.
-
-* 무시는 `correctOrientation` 매개 변수.
-
-* 무시는 `cameraDirection` 매개 변수.
-
-* 무시는 `saveToPhotoAlbum` 매개 변수. 중요: 모든 이미지 API wp7/8 코르도바 카메라로 촬영 항상 복사 됩니다 휴대 전화의 카메라 롤에. 사용자의 설정에 따라이 또한 그들의 OneDrive에 자동 업로드 이미지는 의미. 이 잠재적으로 이미지는 당신의 애플 리 케이 션을 위한 보다 넓은 청중에 게 사용할 수 있는 의미. 이 경우 응용 프로그램에 대 한 차단, 당신은 msdn에 설명 대로 단말기를 구현 해야 합니다: 수 있습니다 또한 의견 또는 [이슈 트래커][3] 에서 업-투표 관련된 문제
-
-* 무시는 `mediaType` 속성을 `cameraOptions` 으로 Windows Phone SDK PHOTOLIBRARY에서 비디오를 선택 하는 방법을 제공 하지 않습니다.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-오류 메시지를 제공 하는 onError 콜백 함수.
-
- function(message) {
- // Show a helpful message
- }
-
-
-### 매개 변수
-
-* **메시지**: 메시지는 장치의 네이티브 코드에 의해 제공 됩니다. *(문자열)*
-
-## cameraSuccess
-
-이미지 데이터를 제공 하는 onSuccess 콜백 함수.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### 매개 변수
-
-* **imageData**: Base64 인코딩은 이미지 데이터, *또는* 이미지 파일에 따라 URI의 `cameraOptions` 적용. *(문자열)*
-
-### 예를 들어
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-`navigator.camera.getPicture`에 의해 만들어진 popover 대화에 대 한 핸들.
-
-### 메서드
-
-* **setPosition**:는 popover의 위치를 설정 합니다.
-
-### 지원 되는 플랫폼
-
-* iOS
-
-### setPosition
-
-popover의 위치를 설정 합니다.
-
-**매개 변수**:
-
-* `cameraPopoverOptions`:는 `CameraPopoverOptions` 새 위치를 지정 하는
-
-### 예를 들어
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS 전용 매개 변수 iPad의 보관 함 또는 앨범에서 이미지를 선택 하면 앵커 요소 위치와 화살표의 방향으로 popover 지정 하는.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **x**: x는 popover 앵커는 화면 요소의 픽셀 좌표. *(수)*
-
-* **y**: y 픽셀 좌표는 popover 앵커는 화면 요소입니다. *(수)*
-
-* **폭**: 폭 (픽셀)는 popover 앵커는 화면 요소. *(수)*
-
-* **높이**: 높이 (픽셀)는 popover 앵커는 화면 요소. *(수)*
-
-* **arrowDir**: 방향 화살표는 popover 가리켜야 합니다. 에 정의 된 `Camera.PopoverArrowDirection` *(수)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-참고는 popover의 크기 조정 화살표 방향 및 화면 방향 변경 될 수 있습니다. 앵커 요소 위치를 지정 하는 경우 방향 변경에 대 한 계정에 있는지 확인 합니다.
-
-## navigator.camera.cleanup
-
-제거 임시 저장소에서 카메라로 찍은 사진을 중간.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### 설명
-
-`camera.getPicture`를 호출한 후 임시 저장소에 보관 됩니다 중간 이미지 파일을 제거 합니다. `Camera.sourceType` 값은 `Camera.PictureSourceType.CAMERA` 및 `Camera.destinationType`와 `Camera.DestinationType.FILE_URI` 때만 적용 됩니다..
-
-### 지원 되는 플랫폼
-
-* iOS
-
-### 예를 들어
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/pl/README.md b/doc/pl/README.md
deleted file mode 100644
index e7b9d4481..000000000
--- a/doc/pl/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-Ten plugin definiuje obiekt globalny `navigator.camera`, który dostarcza API do robienia zdjęć i wybór zdjęć z biblioteki obrazów systemu.
-
-Mimo, że obiekt jest dołączony do globalnego zakresu `navigator`, to nie dostępne dopiero po zdarzeniu `deviceready`.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Instalacja
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * Aparat
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-Ma zdjęcia za pomocą aparatu, lub pobiera zdjęcia z urządzenia Galeria zdjęć. Obraz jest przekazywany do wywołania zwrotnego sukces jako kodowane algorytmem base64 `ciąg`, lub identyfikator URI dla pliku obrazu. Sama metoda zwraca obiekt `CameraPopoverHandle`, który może służyć do zmiany położenia pliku wyboru popover.
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### Opis
-
-Funkcja `camera.getPicture` otwiera urządzenia domyślnej aplikacji aparat fotograficzny ów pozwala użytkownik wobec chwycić zębami kino. To zachowanie występuje domyślnie, gdy `Camera.sourceType` jest równa `Camera.PictureSourceType.CAMERA`. Gdy użytkownik zaskoczy zdjęcie, ten aparat fotograficzny applicationâ zamyka i aplikacji jest przywracany.
-
-Jeśli `Camera.sourceType` jest równe `Camera.PictureSourceType.PHOTOLIBRARY` lub `Camera.PictureSourceType.SAVEDPHOTOALBUM`, wtedy zostanie wyświetlone okno dialogowe pozwalające użytkownikowi na wybór istniejącego obrazu. Funkcja `camera.getPicture` zwraca obiekt `CameraPopoverHandle`, który obsługuje zmianę położenia okna wyboru obrazu, np. po zmianie orientacji urządzenia.
-
-Zwracana wartość jest wysyłany do funkcji wywołania zwrotnego `cameraSuccess`, w jednym z następujących formatów, w zależności od określonego `cameraOptions`:
-
- * `String` zawierający obraz zakodowany przy pomocy base64.
-
- * `String` reprezentujący lokalizację pliku obrazu w lokalnym magazynie (domyślnie).
-
-Może rób, co chcesz z zakodowany obraz lub identyfikatora URI, na przykład:
-
- * Przedstawić obraz w tagu ` `, jak w przykładzie poniżej
-
- * Zapisać lokalnie dane (`LocalStorage`, [Lawnchair](http://brianleroux.github.com/lawnchair/), etc.)
-
- * Wysłać dane na zdalny serwer
-
-**Uwaga**: zdjęcie rozdzielczości na nowsze urządzenia jest bardzo dobry. Zdjęcia wybrane z galerii urządzenia są nie przeskalowanych w dół do niższej jakości, nawet jeśli określono parametr `quality`. Aby uniknąć typowych problemów z pamięci, zestaw `Camera.destinationType` `FILE_URI` zamiast `DATA_URL`.
-
-#### Obsługiwane platformy
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### Przykład
-
-Zrób zdjęcie i pobrać go jako kodowane algorytmem base64 obrazu:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Zrób zdjęcie i pobrać lokalizacji pliku obrazu:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### Preferencje (iOS)
-
- * **CameraUsesGeolocation** (boolean, wartość domyślna to false). Do przechwytywania JPEG, zestaw do true, aby uzyskać danych geolokalizacyjnych w nagłówku EXIF. To spowoduje wniosek o geolokalizacji uprawnienia, jeśli zestaw na wartość true.
-
-
-
-
-#### Amazon ogień OS dziwactwa
-
-Amazon ogień OS używa intencje do rozpoczęcia działalności aparatu na urządzenie do przechwytywania obrazów, i na telefony z pamięci, Cordova aktywność może zostać zabity. W tym scenariuszu obraz mogą nie być wyświetlane po przywróceniu aktywności cordova.
-
-#### Dziwactwa Androida
-
-Android używa intencje do rozpoczęcia działalności aparatu na urządzenie do przechwytywania obrazów, i na telefony z pamięci, Cordova aktywność może zostać zabity. W tym scenariuszu obraz mogą nie być wyświetlane po przywróceniu aktywności Cordova.
-
-#### Quirks przeglądarki
-
-Może zwracać tylko zdjęcia jako obraz w formacie algorytmem base64.
-
-#### Firefox OS dziwactwa
-
-Aparat plugin jest obecnie implementowane za pomocą [Działania sieci Web](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### Dziwactwa iOS
-
-W jednej z funkcji wywołania zwrotnego w tym JavaScript `alert()` może powodować problemy. Owinąć w `setTimeout()` umożliwia wybór obrazu iOS lub popover całkowicie zamknąć zanim wyświetli alert alert:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Dziwactwa Windows Phone 7
-
-Wywoływanie aparat native aplikacji, podczas gdy urządzenie jest podłączone przez Zune nie działa i powoduje błąd wywołania zwrotnego.
-
-#### Dziwactwa Tizen
-
-Tizen obsługuje tylko `destinationType` z `Camera.DestinationType.FILE_URI` i `sourceType` z `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-## CameraOptions
-
-Opcjonalne parametry, aby dostosować ustawienia aparatu.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **quality**: Jakość zapisywanego obrazu, wyrażona w przedziale 0-100, gdzie 100 zazwyczaj jest maksymalną rozdzielczością bez strat w czasie kompresji pliku. Wartością domyślną jest 50. *(Liczba)* (Pamiętaj, że informacja o rozdzielczości aparatu jest niedostępna.)
-
- * **destinationType**: Wybierz format zwracanej wartości. Wartością domyślną jest FILE_URI. Zdefiniowane w `navigator.camera.DestinationType` *(numer)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **sourceType**: Ustaw źródło obrazu. Wartością domyślną jest aparat fotograficzny. Zdefiniowane w `navigator.camera.PictureSourceType` *(numer)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: Pozwala na prostą edycję obrazu przed zaznaczeniem. *(Boolean)*
-
- * **encodingType**: Wybierz plik obrazu zwracany jest kodowanie. Domyślnie jest JPEG. Zdefiniowane w `navigator.camera.EncodingType` *(numer)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: Szerokość w pikselach skalowanego obrazu. Musi być użyte z **targetHeight**. Współczynnik proporcji pozostaje stały. *(Liczba)*
-
- * **targetHeight**: Wysokość w pikselach skalowanego obrazu. Musi być użyte z **targetWidth**. Współczynnik proporcji pozostaje stały. *(Liczba)*
-
- * **mediaType**: Ustawia typ nośnika, z którego będzie wybrany. Działa tylko wtedy, gdy `PictureSourceType` jest `PHOTOLIBRARY` lub `SAVEDPHOTOALBUM`. Zdefiniowane w `nagivator.camera.MediaType` *(Liczba)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DEFAULT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: Obraca obraz aby skorygować orientację urządzenia podczas przechwytywania. *(Boolean)*
-
- * **saveToPhotoAlbum**: Po przechwyceniu zapisuje na urządzeniu obraz w albumie na zdjęcia. *(Boolean)*
-
- * **popoverOptions**: Opcja tylko dla platformy iOS, która określa położenie wyskakującego okna na iPadzie. Zdefiniowane w `CameraPopoverOptions`.
-
- * **cameraDirection**: Wybierz aparat do korzystania (lub z powrotem przodem). Wartością domyślną jest z powrotem. Zdefiniowane w `navigator.camera.Direction` *(numer)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### Amazon ogień OS dziwactwa
-
- * Jakakolwiek wartość w `cameraDirection` skutkuje użyciem tylnej kamery.
-
- * Parametr `allowEdit` jest ignorowany.
-
- * Oba parametry `Camera.PictureSourceType.PHOTOLIBRARY` oraz `Camera.PictureSourceType.SAVEDPHOTOALBUM` wyświetlają ten sam album ze zdjęciami.
-
-#### Dziwactwa Androida
-
- * Jakakolwiek wartość w `cameraDirection` skutkuje użyciem tylnej kamery.
-
- * Android również używa aktywność upraw dla allowEdit, choć upraw powinien pracować i faktycznie przejść przycięte zdjęcie Wróć do Cordova, ten tylko jeden który działa konsekwentnie jest ten, wiązany z aplikacji Google Plus zdjęcia. Inne rośliny mogą nie działać.
-
- * Oba parametry `Camera.PictureSourceType.PHOTOLIBRARY` oraz `Camera.PictureSourceType.SAVEDPHOTOALBUM` wyświetlają ten sam album ze zdjęciami.
-
-#### Jeżyna 10 dziwactwa
-
- * Parametr `quality` jest ignorowany.
-
- * Parametr `allowEdit` jest ignorowany.
-
- * Nie jest wspierane `Camera.MediaType`.
-
- * Parametr `correctOrientation` jest ignorowany.
-
- * Parametr `cameraDirection` jest ignorowany.
-
-#### Firefox OS dziwactwa
-
- * Parametr `quality` jest ignorowany.
-
- * `Camera.DestinationType`jest ignorowane i jest równa `1` (plik obrazu URI)
-
- * Parametr `allowEdit` jest ignorowany.
-
- * Ignoruje `PictureSourceType` parametr (użytkownik wybiera go w oknie dialogowym)
-
- * Ignoruje`encodingType`
-
- * Ignoruje `targetWidth` i`targetHeight`
-
- * Nie jest wspierane `Camera.MediaType`.
-
- * Parametr `correctOrientation` jest ignorowany.
-
- * Parametr `cameraDirection` jest ignorowany.
-
-#### Dziwactwa iOS
-
- * Ustaw `quality` poniżej 50 aby uniknąć błędów pamięci na niektórych urządzeniach.
-
- * Podczas korzystania z `destinationType.FILE_URI` , zdjęcia są zapisywane w katalogu tymczasowego stosowania. Zawartość katalogu tymczasowego stosowania jest usuwany po zakończeniu aplikacji.
-
-#### Dziwactwa Tizen
-
- * opcje nie są obsługiwane
-
- * zawsze zwraca FILE URI
-
-#### Windows Phone 7 i 8 dziwactwa
-
- * Parametr `allowEdit` jest ignorowany.
-
- * Parametr `correctOrientation` jest ignorowany.
-
- * Parametr `cameraDirection` jest ignorowany.
-
- * Ignoruje `saveToPhotoAlbum` parametr. Ważne: Wszystkie zdjęcia zrobione aparatem wp7/8 cordova API są zawsze kopiowane do telefonu w kamerze. W zależności od ustawień użytkownika może to też oznaczać że obraz jest automatycznie przesłane do ich OneDrive. Potencjalnie może to oznaczać, że obraz jest dostępne dla szerszego grona odbiorców niż Twoja aplikacja przeznaczona. Jeśli ten bloker aplikacji, trzeba będzie wdrożenie CameraCaptureTask, opisane na msdn: można także komentarz lub górę głosowanie powiązanych kwestii w [śledzenia błędów](https://issues.apache.org/jira/browse/CB-2083)
-
- * Ignoruje `mediaType` Właściwość `cameraOptions` jako SDK Windows Phone nie umożliwiają wybór filmów z PHOTOLIBRARY.
-
-## CameraError
-
-funkcja wywołania zwrotnego PrzyBłędzie, która zawiera komunikat o błędzie.
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### Opis
-
- * **message**: Natywny kod komunikatu zapewniany przez urządzenie. *(Ciąg znaków)*
-
-## cameraSuccess
-
-onSuccess funkcji wywołania zwrotnego, który dostarcza dane obrazu.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### Opis
-
- * **imageData**: Dane obrazu kodowane przy pomocy Base64 *lub* URI pliku obrazu, w zależności od użycia `cameraOptions`. *(Ciąg znaków)*
-
-#### Przykład
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Uchwyt do okna dialogowego popover, stworzony przez `navigator.camera.getPicture`.
-
-#### Opis
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### Obsługiwane platformy
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Przykład
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-tylko do iOS parametrami, które określić kotwicy element lokalizacji i strzałka kierunku popover, przy wyborze zdjęć z iPad biblioteki lub album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### Opis
-
- * **x**: współrzędna piksela x elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
- * **y**: współrzędna piksela y elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
- * **width**: szerokość w pikselach elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
- * **height**: wysokość w pikselach elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
- * **arrowDir**: Kierunek, który powinna wskazywać strzałka na wyskakującym oknie. Zdefiniowane w `Camera.PopoverArrowDirection` *(Liczba)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Należy pamiętać, że rozmiar popover może zmienić aby zmienić kierunek strzałki i orientacji ekranu. Upewnij się uwzględnić zmiany orientacji podczas określania położenia elementu kotwicy.
-
-## navigator.camera.cleanup
-
-Usuwa pośrednie zdjęcia zrobione przez aparat z czasowego składowania.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### Opis
-
-Usuwa pliki obrazów pośrednich, które są przechowywane w pamięci tymczasowej po wywołaniu `camera.getPicture`. Ma zastosowanie tylko, gdy wartość `Camera.sourceType` jest równa `Camera.PictureSourceType.CAMERA` i `Camera.destinationType` jest równa `Camera.DestinationType.FILE_URI`.
-
-#### Obsługiwane platformy
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### Przykład
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/pl/index.md b/doc/pl/index.md
deleted file mode 100644
index f22669876..000000000
--- a/doc/pl/index.md
+++ /dev/null
@@ -1,434 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Ten plugin definiuje obiekt globalny `navigator.camera`, który dostarcza API do robienia zdjęć i wybór zdjęć z biblioteki obrazów systemu.
-
-Mimo, że obiekt jest dołączony do globalnego zakresu `navigator`, to nie dostępne dopiero po zdarzeniu `deviceready`.
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## Instalacja
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Ma zdjęcia za pomocą aparatu, lub pobiera zdjęcia z urządzenia Galeria zdjęć. Obraz jest przekazywany do wywołania zwrotnego sukces jako kodowane algorytmem base64 `ciąg`, lub identyfikator URI dla pliku obrazu. Sama metoda zwraca obiekt `CameraPopoverHandle`, który może służyć do zmiany położenia pliku wyboru popover.
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### Opis
-
-Funkcja `camera.getPicture` otwiera urządzenia domyślnej aplikacji aparat fotograficzny ów pozwala użytkownik wobec chwycić zębami kino. To zachowanie występuje domyślnie, gdy `Camera.sourceType` jest równa `Camera.PictureSourceType.CAMERA`. Gdy użytkownik zaskoczy zdjęcie, ten aparat fotograficzny applicationâ zamyka i aplikacji jest przywracany.
-
-Jeśli `Camera.sourceType` jest równe `Camera.PictureSourceType.PHOTOLIBRARY` lub `Camera.PictureSourceType.SAVEDPHOTOALBUM`, wtedy zostanie wyświetlone okno dialogowe pozwalające użytkownikowi na wybór istniejącego obrazu. Funkcja `camera.getPicture` zwraca obiekt `CameraPopoverHandle`, który obsługuje zmianę położenia okna wyboru obrazu, np. po zmianie orientacji urządzenia.
-
-Zwracana wartość jest wysyłany do funkcji wywołania zwrotnego `cameraSuccess`, w jednym z następujących formatów, w zależności od określonego `cameraOptions`:
-
-* `String` zawierający obraz zakodowany przy pomocy base64.
-
-* `String` reprezentujący lokalizację pliku obrazu w lokalnym magazynie (domyślnie).
-
-Może rób, co chcesz z zakodowany obraz lub identyfikatora URI, na przykład:
-
-* Przedstawić obraz w tagu ` `, jak w przykładzie poniżej
-
-* Zapisać lokalnie dane (`LocalStorage`, [Lawnchair][1], etc.)
-
-* Wysłać dane na zdalny serwer
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**Uwaga**: zdjęcie rozdzielczości na nowsze urządzenia jest bardzo dobry. Zdjęcia wybrane z galerii urządzenia są nie przeskalowanych w dół do niższej jakości, nawet jeśli określono parametr `quality`. Aby uniknąć typowych problemów z pamięci, zestaw `Camera.destinationType` `FILE_URI` zamiast `DATA_URL`.
-
-### Obsługiwane platformy
-
-* Amazon Fire OS
-* Android
-* BlackBerry 10
-* Przeglądarka
-* Firefox OS
-* iOS
-* Tizen
-* Windows Phone 7 i 8
-* Windows 8
-
-### Preferencje (iOS)
-
-* **CameraUsesGeolocation** (boolean, wartość domyślna to false). Do przechwytywania JPEG, zestaw do true, aby uzyskać danych geolokalizacyjnych w nagłówku EXIF. To spowoduje wniosek o geolokalizacji uprawnienia, jeśli zestaw na wartość true.
-
-
-
-
-### Amazon ogień OS dziwactwa
-
-Amazon ogień OS używa intencje do rozpoczęcia działalności aparatu na urządzenie do przechwytywania obrazów, i na telefony z pamięci, Cordova aktywność może zostać zabity. W tym scenariuszu obraz mogą nie być wyświetlane po przywróceniu aktywności cordova.
-
-### Dziwactwa Androida
-
-Android używa intencje do rozpoczęcia działalności aparatu na urządzenie do przechwytywania obrazów, i na telefony z pamięci, Cordova aktywność może zostać zabity. W tym scenariuszu obraz mogą nie być wyświetlane po przywróceniu aktywności Cordova.
-
-### Quirks przeglądarki
-
-Może zwracać tylko zdjęcia jako obraz w formacie algorytmem base64.
-
-### Firefox OS dziwactwa
-
-Aparat plugin jest obecnie implementowane za pomocą [Działania sieci Web][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### Dziwactwa iOS
-
-W jednej z funkcji wywołania zwrotnego w tym JavaScript `alert()` może powodować problemy. Owinąć w `setTimeout()` umożliwia wybór obrazu iOS lub popover całkowicie zamknąć zanim wyświetli alert alert:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Dziwactwa Windows Phone 7
-
-Wywoływanie aparat native aplikacji, podczas gdy urządzenie jest podłączone przez Zune nie działa i powoduje błąd wywołania zwrotnego.
-
-### Dziwactwa Tizen
-
-Tizen obsługuje tylko `destinationType` z `Camera.DestinationType.FILE_URI` i `sourceType` z `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Przykład
-
-Zrób zdjęcie i pobrać go jako kodowane algorytmem base64 obrazu:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Zrób zdjęcie i pobrać lokalizacji pliku obrazu:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-Opcjonalne parametry, aby dostosować ustawienia aparatu.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### Opcje
-
-* **quality**: Jakość zapisywanego obrazu, wyrażona w przedziale 0-100, gdzie 100 zazwyczaj jest maksymalną rozdzielczością bez strat w czasie kompresji pliku. Wartością domyślną jest 50. *(Liczba)* (Pamiętaj, że informacja o rozdzielczości aparatu jest niedostępna.)
-
-* **destinationType**: Wybierz format zwracanej wartości. Wartością domyślną jest FILE_URI. Zdefiniowane w `navigator.camera.DestinationType` *(numer)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **sourceType**: Ustaw źródło obrazu. Wartością domyślną jest aparat fotograficzny. Zdefiniowane w `navigator.camera.PictureSourceType` *(numer)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: Pozwala na prostą edycję obrazu przed zaznaczeniem. *(Boolean)*
-
-* **encodingType**: Wybierz plik obrazu zwracany jest kodowanie. Domyślnie jest JPEG. Zdefiniowane w `navigator.camera.EncodingType` *(numer)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: Szerokość w pikselach skalowanego obrazu. Musi być użyte z **targetHeight**. Współczynnik proporcji pozostaje stały. *(Liczba)*
-
-* **targetHeight**: Wysokość w pikselach skalowanego obrazu. Musi być użyte z **targetWidth**. Współczynnik proporcji pozostaje stały. *(Liczba)*
-
-* **mediaType**: Ustawia typ nośnika, z którego będzie wybrany. Działa tylko wtedy, gdy `PictureSourceType` jest `PHOTOLIBRARY` lub `SAVEDPHOTOALBUM`. Zdefiniowane w `nagivator.camera.MediaType` *(Liczba)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. DEFAULT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: Obraca obraz aby skorygować orientację urządzenia podczas przechwytywania. *(Boolean)*
-
-* **saveToPhotoAlbum**: Po przechwyceniu zapisuje na urządzeniu obraz w albumie na zdjęcia. *(Boolean)*
-
-* **popoverOptions**: Opcja tylko dla platformy iOS, która określa położenie wyskakującego okna na iPadzie. Zdefiniowane w `CameraPopoverOptions`.
-
-* **cameraDirection**: Wybierz aparat do korzystania (lub z powrotem przodem). Wartością domyślną jest z powrotem. Zdefiniowane w `navigator.camera.Direction` *(numer)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Amazon ogień OS dziwactwa
-
-* Jakakolwiek wartość w `cameraDirection` skutkuje użyciem tylnej kamery.
-
-* Parametr `allowEdit` jest ignorowany.
-
-* Oba parametry `Camera.PictureSourceType.PHOTOLIBRARY` oraz `Camera.PictureSourceType.SAVEDPHOTOALBUM` wyświetlają ten sam album ze zdjęciami.
-
-### Dziwactwa Androida
-
-* Jakakolwiek wartość w `cameraDirection` skutkuje użyciem tylnej kamery.
-
-* Parametr `allowEdit` jest ignorowany.
-
-* Oba parametry `Camera.PictureSourceType.PHOTOLIBRARY` oraz `Camera.PictureSourceType.SAVEDPHOTOALBUM` wyświetlają ten sam album ze zdjęciami.
-
-### Jeżyna 10 dziwactwa
-
-* Parametr `quality` jest ignorowany.
-
-* Parametr `allowEdit` jest ignorowany.
-
-* Nie jest wspierane `Camera.MediaType`.
-
-* Parametr `correctOrientation` jest ignorowany.
-
-* Parametr `cameraDirection` jest ignorowany.
-
-### Firefox OS dziwactwa
-
-* Parametr `quality` jest ignorowany.
-
-* `Camera.DestinationType`jest ignorowane i jest równa `1` (plik obrazu URI)
-
-* Parametr `allowEdit` jest ignorowany.
-
-* Ignoruje `PictureSourceType` parametr (użytkownik wybiera go w oknie dialogowym)
-
-* Ignoruje`encodingType`
-
-* Ignoruje `targetWidth` i`targetHeight`
-
-* Nie jest wspierane `Camera.MediaType`.
-
-* Parametr `correctOrientation` jest ignorowany.
-
-* Parametr `cameraDirection` jest ignorowany.
-
-### Dziwactwa iOS
-
-* Ustaw `quality` poniżej 50 aby uniknąć błędów pamięci na niektórych urządzeniach.
-
-* Podczas korzystania z `destinationType.FILE_URI` , zdjęcia są zapisywane w katalogu tymczasowego stosowania. Zawartość katalogu tymczasowego stosowania jest usuwany po zakończeniu aplikacji.
-
-### Dziwactwa Tizen
-
-* opcje nie są obsługiwane
-
-* zawsze zwraca FILE URI
-
-### Windows Phone 7 i 8 dziwactwa
-
-* Parametr `allowEdit` jest ignorowany.
-
-* Parametr `correctOrientation` jest ignorowany.
-
-* Parametr `cameraDirection` jest ignorowany.
-
-* Ignoruje `saveToPhotoAlbum` parametr. Ważne: Wszystkie zdjęcia zrobione aparatem wp7/8 cordova API są zawsze kopiowane do telefonu w kamerze. W zależności od ustawień użytkownika może to też oznaczać że obraz jest automatycznie przesłane do ich OneDrive. Potencjalnie może to oznaczać, że obraz jest dostępne dla szerszego grona odbiorców niż Twoja aplikacja przeznaczona. Jeśli ten bloker aplikacji, trzeba będzie wdrożenie CameraCaptureTask, opisane na msdn: można także komentarz lub górę głosowanie powiązanych kwestii w [śledzenia błędów][3]
-
-* Ignoruje `mediaType` Właściwość `cameraOptions` jako SDK Windows Phone nie umożliwiają wybór filmów z PHOTOLIBRARY.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-funkcja wywołania zwrotnego PrzyBłędzie, która zawiera komunikat o błędzie.
-
- function(message) {
- // Show a helpful message
- }
-
-
-### Parametry
-
-* **message**: Natywny kod komunikatu zapewniany przez urządzenie. *(Ciąg znaków)*
-
-## cameraSuccess
-
-onSuccess funkcji wywołania zwrotnego, który dostarcza dane obrazu.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### Parametry
-
-* **imageData**: Dane obrazu kodowane przy pomocy Base64 *lub* URI pliku obrazu, w zależności od użycia `cameraOptions`. *(Ciąg znaków)*
-
-### Przykład
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Uchwyt do okna dialogowego popover, stworzony przez `navigator.camera.getPicture`.
-
-### Metody
-
-* **setPosition**: Ustawia pozycję wyskakującego okna.
-
-### Obsługiwane platformy
-
-* iOS
-
-### setPosition
-
-Ustaw pozycję popover.
-
-**Parametry**:
-
-* `cameraPopoverOptions`: `CameraPopoverOptions`, która określa nową pozycję
-
-### Przykład
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-tylko do iOS parametrami, które określić kotwicy element lokalizacji i strzałka kierunku popover, przy wyborze zdjęć z iPad biblioteki lub album.
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **x**: współrzędna piksela x elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
-* **y**: współrzędna piksela y elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
-* **width**: szerokość w pikselach elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
-* **height**: wysokość w pikselach elementu ekranu, na którym zakotwiczone jest wyskakujące okno. *(Liczba)*
-
-* **arrowDir**: Kierunek, który powinna wskazywać strzałka na wyskakującym oknie. Zdefiniowane w `Camera.PopoverArrowDirection` *(Liczba)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Należy pamiętać, że rozmiar popover może zmienić aby zmienić kierunek strzałki i orientacji ekranu. Upewnij się uwzględnić zmiany orientacji podczas określania położenia elementu kotwicy.
-
-## navigator.camera.cleanup
-
-Usuwa pośrednie zdjęcia zrobione przez aparat z czasowego składowania.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### Opis
-
-Usuwa pliki obrazów pośrednich, które są przechowywane w pamięci tymczasowej po wywołaniu `camera.getPicture`. Ma zastosowanie tylko, gdy wartość `Camera.sourceType` jest równa `Camera.PictureSourceType.CAMERA` i `Camera.destinationType` jest równa `Camera.DestinationType.FILE_URI`.
-
-### Obsługiwane platformy
-
-* iOS
-
-### Przykład
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/ru/index.md b/doc/ru/index.md
deleted file mode 100644
index f93609ca0..000000000
--- a/doc/ru/index.md
+++ /dev/null
@@ -1,417 +0,0 @@
-
-
-# cordova-plugin-camera
-
-Этот плагин предоставляет API для съемки и для выбора изображения из библиотеки изображений системы.
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-Снимает фотографию с помощью камеры, или получает фотографию из галереи изображений устройства. Изображение передается на функцию обратного вызова успешного завершения как `String` в base64-кодировке, или как URI указывающего на файл изображения. Метод возвращает объект `CameraPopoverHandle`, который может использоваться для перемещения инструмента выбора файла.
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### Описание
-
-Функция `camera.getPicture` открывает приложение камеры устройства, которое позволяет снимать фотографии. Это происходит по умолчанию, когда `Camera.sourceType` равно `Camera.PictureSourceType.CAMERA` . Как только пользователь делает снимок,приложение камеры закрывается и приложение восстанавливается.
-
-Если `Camera.sourceType` является `Camera.PictureSourceType.PHOTOLIBRARY` или `Camera.PictureSourceType.SAVEDPHOTOALBUM` , то показывается диалоговое окно, которое позволяет пользователям выбрать существующее изображение. Функция `camera.getPicture` возвращает объект `CameraPopoverHandle` объект, который может использоваться для перемещения диалога выбора изображения, например, при изменении ориентации устройства.
-
-Возвращаемое значение отправляется в функцию обратного вызова `cameraSuccess` в одном из следующих форматов, в зависимости от параметра `cameraOptions` :
-
-* A объект `String` содержащий фото изображение в base64-кодировке.
-
-* Объект `String` представляющий расположение файла изображения на локальном хранилище (по умолчанию).
-
-Вы можете сделать все, что угодно вы хотите с закодированным изображением или URI, например:
-
-* Отобразить изображение с помощью тега ` `, как показано в примере ниже
-
-* Сохранять данные локально (`LocalStorage`, [Lawnchair][1], и т.д.)
-
-* Отправлять данные на удаленный сервер
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**Примечание**: разрешение фото на более новых устройствах является достаточно хорошим. Фотографии из галереи устройства не масштабируются к более низкому качеству, даже если указан параметр `quality`. Чтобы избежать общих проблем с памятью, установите `Camera.destinationType` в `FILE_URI` вместо `DATA_URL`.
-
-### Поддерживаемые платформы
-
-* Amazon Fire OS
-* Android
-* BlackBerry 10
-* Обозреватель
-* Firefox OS
-* iOS
-* Tizen
-* Windows Phone 7 и 8
-* Windows 8
-
-### Предпочтения (iOS)
-
-* **CameraUsesGeolocation** (логическое значение, по умолчанию false). Для захвата изображения JPEG, значение true, чтобы получить данные геопозиционирования в заголовке EXIF. Это вызовет запрос на разрешения геолокации, если задано значение true.
-
-
-
-
-### Особенности Amazon Fire OS
-
-Amazon Fire OS используют намерения для запуска активности камеры на устройстве для съемки фотографий, и на устройствах с низким объемам памяти, активность Cordova может быть завершена. В этом случае изображение может не появиться при восстановлении активности Cordova.
-
-### Особенности Android
-
-Android используют намерения для запуска активности камеры на устройстве для съемки фотографий, и на устройствах с низким объемам памяти, активность Cordova может быть завершена. В этом случае изображение может не появиться при восстановлении активности Cordova.
-
-### Браузер причуды
-
-Может возвращать только фотографии как изображения в кодировке base64.
-
-### Особенности Firefox OS
-
-Плагин Camera на данный момент реализован с использованием [Web Activities][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### Особенности iOS
-
-Включение функции JavaScript `alert()` в любой из функций обратного вызова функции может вызвать проблемы. Оберните вызов alert в `setTimeout()` для позволения окну выбора изображений iOS полностью закрыться перед отображение оповещения:
-
- setTimeout(function() {/ / ваши вещи!}, 0);
-
-
-### Особенности Windows Phone 7
-
-Вызов встроенного приложения камеры, в то время как устройство подключено к Zune не работает, и инициирует обратный вызов для ошибки.
-
-### Особенности Tizen
-
-Tizen поддерживает только значение `destinationType` равное `Camera.DestinationType.FILE_URI` и значение `sourceType` равное `Camera.PictureSourceType.PHOTOLIBRARY`.
-
-### Пример
-
-Сделайте фотографию и получите его как изображение в base64-кодировке:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-Сделайте фотографию и получить расположение файла с изображением:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-Необязательные параметры для настройки параметров камеры.
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### Параметры
-
-* **quality**: качество сохраняемого изображения, выражается в виде числа в диапазоне от 0 до 100, где 100 является обычно полным изображением без потери качества при сжатии. Значение по умолчанию — 50. *(Число)* (Обратите внимание, что информация о разрешении камеры недоступна.)
-
-* **параметр destinationType**: выберите формат возвращаемого значения. Значение по умолчанию — FILE_URI. Определяется в `navigator.camera.DestinationType` *(число)*
-
- Camera.DestinationType = {
- DATA_URL: 0, / / возвращение изображения в base64-кодировке строки
- FILE_URI: 1, / / возврат файла изображения URI
- NATIVE_URI: 2 / / возвращение образа собственного URI (например, Библиотека активов: / / на iOS или содержание: / / на андроиде)
- };
-
-
-* **тип источника**: установить источник рисунка. По умолчанию используется камера. Определяется в `navigator.camera.PictureSourceType` *(число)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY: 0,
- CAMERA: 1,
- SAVEDPHOTOALBUM: 2
- };
-
-
-* **allowEdit**: позволит редактирование изображения средствами телефона перед окончательным выбором изображения. *(Логический)*
-
-* **Тип_шифрования**: выберите возвращенный файл в кодировку. Значение по умолчанию — JPEG. Определяется в `navigator.camera.EncodingType` *(число)*
-
- Camera.EncodingType = {
- JPEG: 0, // возвращает изображение в формате JPEG
- PNG: 1 // возвращает рисунок в формате PNG
- };
-
-
-* **targetWidth**: ширина изображения в пикселах к которой необходимо осуществить масштабирование. Это значение должно использоваться совместно с **targetHeight**. Пропорции изображения останутся неизменными. *(Число)*
-
-* **targetHeight**: высота изображения в пикселах к которой необходимо осуществить масштабирование. Это значение должно использоваться совместно с **targetWidth**. Пропорции изображения останутся неизменными. *(Число)*
-
-* **тип носителя**: Установите источник получения изображения, из которого надо выбрать изображение. Работает только если `PictureSourceType` равно `PHOTOLIBRARY` или `SAVEDPHOTOALBUM` . Определяется в `nagivator.camera.MediaType` *(число)*
-
- Camera.MediaType = {
- PICTURE: 0, / / разрешить выбор только сохраненных изображений. DEFAULT. Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: вращает изображение, чтобы внести исправления к ориентации устройства во время захвата. *(Логический)*
-
-* **saveToPhotoAlbum**: сохранить изображение в фотоальбом на устройстве после захвата. *(Логическое)*
-
-* **popoverOptions**: только для iOS параметры, которые определяют местоположение инструмента в iPad. Определены в`CameraPopoverOptions`.
-
-* **cameraDirection**: выбрать камеру для использования (передней или задней стороне). Значение по умолчанию — обратно. Определяется в `navigator.camera.Direction` *(число)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### Особенности Amazon Fire OS
-
-* Любое значение `cameraDirection` возвращает фотографию сделанную задней камерой.
-
-* Игнорирует параметр `allowEdit`.
-
-* Оба параметра `Camera.PictureSourceType.PHOTOLIBRARY` и `Camera.PictureSourceType.SAVEDPHOTOALBUM` отображают один и тот же фотоальбом.
-
-### Особенности Android
-
-* Любое значение `cameraDirection` возвращает фотографию сделанную задней камерой.
-
-* Игнорирует параметр `allowEdit`.
-
-* Оба параметра `Camera.PictureSourceType.PHOTOLIBRARY` и `Camera.PictureSourceType.SAVEDPHOTOALBUM` отображают один и тот же фотоальбом.
-
-### Особенности BlackBerry 10
-
-* Игнорирует `quality` параметр.
-
-* Игнорирует параметр `allowEdit`.
-
-* `Camera.MediaType` не поддерживается.
-
-* Игнорирует параметр `correctOrientation`.
-
-* Игнорирует параметр `cameraDirection`.
-
-### Особенности Firefox OS
-
-* Игнорирует `quality` параметр.
-
-* Значение `Camera.DestinationType` игнорируется и равно `1` (URI для файла изображения)
-
-* Игнорирует параметр `allowEdit`.
-
-* Игнорирует параметр `PictureSourceType` (пользователь выбирает его в диалоговом окне)
-
-* Игнорирует параметр `encodingType`
-
-* Игнорирует `targetWidth` и `targetHeight`
-
-* `Camera.MediaType` не поддерживается.
-
-* Игнорирует параметр `correctOrientation`.
-
-* Игнорирует параметр `cameraDirection`.
-
-### Особенности iOS
-
-* Установите `quality` ниже 50, для того чтобы избежать ошибок памяти на некоторых устройствах.
-
-* При использовании `destinationType.FILE_URI` , фотографии сохраняются во временном каталоге приложения. Содержимое приложения временного каталога удаляется при завершении приложения.
-
-### Особенности Tizen
-
-* options, не поддерживается
-
-* всегда возвращает URI файла
-
-### Особенности Windows Phone 7 и 8
-
-* Игнорирует параметр `allowEdit`.
-
-* Игнорирует параметр `correctOrientation`.
-
-* Игнорирует параметр `cameraDirection`.
-
-* Игнорирует `saveToPhotoAlbum` параметр. Важно: Все изображения, снятые камерой wp7/8 cordova API всегда копируются в рулон камеры телефона. В зависимости от параметров пользователя это также может означать, что изображение автоматически загружены на их OneDrive. Потенциально это может означать, что этот образ доступен для более широкой аудитории, чем ваше приложение предназначено. Если этот блокатор для вашего приложения, вам нужно будет осуществить CameraCaptureTask, как описано на сайте msdn: вы можете также комментарий или вверх голосование связанный с этим вопрос [отслеживания][3]
-
-* Игнорирует свойство `mediaType` объекта `cameraOptions` так как Windows Phone SDK не предоставляет способ выбрать видео из PHOTOLIBRARY.
-
- [3]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-Функция обратного вызова вызываемая в случае возникновения ошибки.
-
- function(message) {
- // Show a helpful message
- }
-
-
-### Параметры
-
-* **сообщение**: сообщение об ошибке предоставляемое платформой устройства. *(Строка)*
-
-## cameraSuccess
-
-Функция обратного вызова onSuccess, получающая данные изображения.
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### Параметры
-
-* **imageData**: Данные изображения в Base64 кодировке, *или* URI, в зависимости от применяемых параметров `cameraOptions`. *(Строка)*
-
-### Пример
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-Дескриптор диалогового окна инструмента, созданный `navigator.camera.getPicture`.
-
-### Методы
-
-* **setPosition**: Задайте положение инструмента выбора изображения.
-
-### Поддерживаемые платформы
-
-* iOS
-
-### setPosition
-
-Устанавливает положение инструмента выбора изображения.
-
-**Параметры**:
-
-* `cameraPopoverOptions`: Объект `CameraPopoverOptions`, определяющий новое положение
-
-### Пример
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-Параметры только для iOS, которые определяют расположение элемента привязки и направление стрелки инструмента при выборе изображений из библиотеки изображений iPad или альбома.
-
- {x: 0, y: 32, ширина: 320, высота: 480, arrowDir: Camera.PopoverArrowDirection.ARROW_ANY};
-
-
-### CameraPopoverOptions
-
-* **x**: x координата в пикселях элемента экрана, на котором закрепить инструмента. *(Число)*
-
-* **x**: y координата в пикселях элемента экрана, на котором закрепить инструмента. *(Число)*
-
-* **width**: ширина в пикселях элемента экрана, на котором закрепить инструмент выбора изображения. *(Число)*
-
-* **height**: высота в пикселях элемента экрана, на котором закрепить инструмент выбора изображения. *(Число)*
-
-* **arrowDir**: Направление, куда должна указывать стрелка на инструменте. Определено в `Camera.PopoverArrowDirection` *(число)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-Обратите внимание, что размер инструмента может изменяться для корректировки в зависимости направлении стрелки и ориентации экрана. Убедитесь, что учитываете возможные изменения ориентации при указании расположения элемента привязки.
-
-## navigator.camera.cleanup
-
-Удаляет промежуточные фотографии, сделанные камерой из временного хранилища.
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### Описание
-
-Удаляет промежуточные файлы изображений, которые хранятся во временном хранилище после вызова метода `camera.getPicture` . Применяется только тогда, когда значение `Camera.sourceType` равно `Camera.PictureSourceType.CAMERA` и `Camera.destinationType` равняется `Camera.DestinationType.FILE_URI`.
-
-### Поддерживаемые платформы
-
-* iOS
-
-### Пример
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/doc/zh/README.md b/doc/zh/README.md
deleted file mode 100644
index 2f7c9e658..000000000
--- a/doc/zh/README.md
+++ /dev/null
@@ -1,421 +0,0 @@
-
-
-# cordova-plugin-camera
-
-[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg)](https://travis-ci.org/apache/cordova-plugin-camera)
-
-這個外掛程式定義了一個全球 `navigator.camera` 物件,它提供了 API,拍照,從系統的圖像庫中選擇圖像。
-
-雖然該物件附加到全球範圍內 `導航器`,它不可用直到 `deviceready` 事件之後。
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## 安裝
-
- cordova plugin add cordova-plugin-camera
-
-
-## API
-
- * 相機
- * navigator.camera.getPicture(success, fail, options)
- * CameraOptions
- * CameraPopoverHandle
- * CameraPopoverOptions
- * navigator.camera.cleanup
-
-## navigator.camera.getPicture
-
-需要一張照片,使用相機,或從設備的圖像庫檢索一張照片。 圖像被傳遞給成功回檔的 base64 編碼 `String`,或作為 URI 為影像檔。 該方法本身返回一個 `CameraPopoverHandle` 物件,它可以用來重新置放檔選擇氣泡框。
-
- navigator.camera.getPicture(cameraSuccess, cameraError, cameraOptions);
-
-
-#### 說明
-
-`camera.getPicture` 函數打開該設備的預設攝像頭應用程式,允許使用者拍照。 `Camera.sourceType` 等於 `Camera.PictureSourceType.CAMERA` 時,預設情況下,發生此行為。 一旦使用者打斷了他的照片,相機應用程式關閉,且應用程式還原。
-
-如果 `Camera.sourceType` 是 `Camera.PictureSourceType.PHOTOLIBRARY` 或 `Camera.PictureSourceType.SAVEDPHOTOALBUM`,然後顯示一個對話方塊,允許使用者選擇一個現有的圖像。 `camera.getPicture` 函數返回一個 `CameraPopoverHandle` 物件,它可以用於重新置放圖像選擇的對話方塊,例如,當設備的方向變化。
-
-傳回值是發送到 `cameraSuccess` 回呼函數中,在以下的格式,具體取決於指定的 `cameraOptions` 之一:
-
- * A `String` 包含的 base64 編碼的照片圖像。
-
- * A `String` 表示在本機存放區 (預設值) 上的影像檔位置。
-
-你可以做任何你想要的編碼的圖像或 URI,例如:
-
- * 呈現在圖像 ` ` 標記,如下面的示例所示
-
- * 保存本地的資料 ( `LocalStorage` , [Lawnchair](http://brianleroux.github.com/lawnchair/),等等.)
-
- * 將資料發佈到遠端伺服器
-
-**注**: 在更新設備上的照片解析度是很好。 選擇從設備的庫的照片是不壓縮螢幕使其以較低的品質,即使指定了一個 `quality` 參數。 要避免常見的記憶體問題,請將 `Camera.destinationType` 設置為 `FILE_URI`,而不是 `DATA_URL`.
-
-#### 支援的平臺
-
-![](doc/img/android-success.png) ![](doc/img/blackberry-success.png) ![](doc/img/browser-success.png) ![](doc/img/firefox-success.png) ![](doc/img/fireos-success.png) ![](doc/img/ios-success.png) ![](doc/img/windows-success.png) ![](doc/img/wp8-success.png) ![](doc/img/ubuntu-success.png)
-
-#### 示例
-
-拍一張照片,並檢索它作為一個 base64 編碼的圖像:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-拍一張照片和檢索圖像的檔位置:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-#### 首選項 (iOS)
-
- * **CameraUsesGeolocation**(布林值,預設值為 false)。 用於捕獲 jpeg 檔,設置為 true,以在 EXIF 頭資訊中獲取地理定位資料。 這將觸發請求的地理位置的許可權,如果設置為 true。
-
-
-
-
-#### 亞馬遜火 OS 怪癖
-
-亞馬遜火 OS 使用意圖啟動相機活動設備來捕捉圖像上, 和手機上記憶體不足,科爾多瓦活動可能被殺害。 在這種情況下,可能不會顯示圖像時恢復了科爾多瓦活動。
-
-#### Android 的怪癖
-
-Android 使用意圖以啟動相機活動設備來捕捉圖像上, 和手機上記憶體不足,科爾多瓦活動可能被殺害。 在這種情況下,可能不會顯示圖像時恢復了科爾多瓦活動。
-
-#### 瀏覽器的怪癖
-
-可以只返回照片作為 base64 編碼的圖像。
-
-#### 火狐瀏覽器作業系統的怪癖
-
-觀景窗外掛程式目前實施使用 [Web 活動](https://hacks.mozilla.org/2013/01/introducing-web-activities/).
-
-#### iOS 的怪癖
-
-包括 JavaScript `alert ()` 中的回呼函數會導致問題。 包裝內 `setTimeout()` 允許 iOS 圖像選取器或氣泡框以完全關閉之前,警報將顯示警報:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-#### Windows Phone 7 的怪癖
-
-調用本機攝像頭應用程式,而通過 Zune 所連接的設備不能工作,並且觸發錯誤回檔。
-
-#### Tizen 怪癖
-
-泰只支援 `destinationType` 的 `Camera.DestinationType.FILE_URI` 和 `Camera.PictureSourceType.PHOTOLIBRARY` 的 `sourceType`.
-
-## CameraOptions
-
-要自訂相機設置的可選參數。
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
- * **品質**: 保存的圖像,表示為範圍 0-100,100,是通常全解析度,無損失從檔案壓縮的品質。 預設值為 50。 *(人數)*(請注意相機的解析度有關的資訊是不可用)。
-
- * **可**: 選擇傳回值的格式。預設值是 FILE_URI。定義在 `navigator.camera.DestinationType` *(人數)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
- * **時**: 設置圖片的來源。預設值是觀景窗。定義在 `navigator.camera.PictureSourceType` *(人數)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
- * **allowEdit**: 允許簡單編輯前選擇圖像。*(布林)*
-
- * **encodingType**: 選擇返回的影像檔的編碼。預設值為 JPEG。定義在 `navigator.camera.EncodingType` *(人數)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
- * **targetWidth**: 向尺度圖像的圖元寬度。必須用**targetHeight**。縱橫比保持不變。*(人數)*
-
- * **targetHeight**: 以圖元為單位向尺度圖像的高度。必須用**targetWidth**。縱橫比保持不變。*(人數)*
-
- * **媒體類型**: 設置的媒體,從選擇類型。 時才起作用 `PictureSourceType` 是 `PHOTOLIBRARY` 或 `SAVEDPHOTOALBUM` 。 定義在 `nagivator.camera.MediaType` *(人數)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. 預設情況。 Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
- * **correctOrientation**: 旋轉圖像,該設備時捕獲的定向的正確。*(布林)*
-
- * **saveToPhotoAlbum**: 將圖像保存到相冊在設備上捕獲後。*(布林)*
-
- * **popoverOptions**: 只有 iOS 在 iPad 中指定氣泡框位置的選項。在中定義`CameraPopoverOptions`.
-
- * **cameraDirection**: 選擇相機以使用 (前面或後面-面向)。預設值是背。定義在 `navigator.camera.Direction` *(人數)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-#### 亞馬遜火 OS 怪癖
-
- * 任何 `cameraDirection` 值回朝的照片中的結果。
-
- * 忽略 `allowEdit` 參數。
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`和 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 都顯示相同的相冊。
-
-#### Android 的怪癖
-
- * 任何 `cameraDirection` 值回朝的照片中的結果。
-
- * 安卓也用於作物活動 allowEdit,即使作物應工作,實際上將裁剪的圖像傳回給科爾多瓦,那個唯一的作品一直是一個與谷歌加上照片應用程式捆綁在一起。 其他作物可能無法工作。
-
- * `Camera.PictureSourceType.PHOTOLIBRARY`和 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 都顯示相同的相冊。
-
-#### 黑莓 10 怪癖
-
- * 忽略 `quality` 參數。
-
- * 忽略 `allowEdit` 參數。
-
- * `Camera.MediaType`不受支援。
-
- * 忽略 `correctOrientation` 參數。
-
- * 忽略 `cameraDirection` 參數。
-
-#### 火狐瀏覽器作業系統的怪癖
-
- * 忽略 `quality` 參數。
-
- * `Camera.DestinationType`將被忽略並且等於 `1` (影像檔的 URI)
-
- * 忽略 `allowEdit` 參數。
-
- * 忽略 `PictureSourceType` 參數 (使用者選擇它在對話方塊視窗中)
-
- * 忽略`encodingType`
-
- * 忽略了 `targetWidth` 和`targetHeight`
-
- * `Camera.MediaType`不受支援。
-
- * 忽略 `correctOrientation` 參數。
-
- * 忽略 `cameraDirection` 參數。
-
-#### iOS 的怪癖
-
- * 設置 `quality` 低於 50,避免在某些設備上的記憶體不足錯誤。
-
- * 當使用 `destinationType.FILE_URI` ,照片都保存在應用程式的臨時目錄。應用程式結束時,將刪除該應用程式的臨時目錄中的內容。
-
-#### Tizen 怪癖
-
- * 不支援的選項
-
- * 總是返回一個檔的 URI
-
-#### Windows Phone 7 和 8 怪癖
-
- * 忽略 `allowEdit` 參數。
-
- * 忽略 `correctOrientation` 參數。
-
- * 忽略 `cameraDirection` 參數。
-
- * 忽略 `saveToPhotoAlbum` 參數。 重要: 使用 wp7/8 科爾多瓦攝像頭 API 拍攝的所有圖像總是都複製到手機的相機膠捲。 根據使用者的設置,這可能也意味著圖像是自動上傳到他們另。 這有可能意味著的圖像,可以比你的應用程式的目的更多的觀眾。 如果此阻滯劑您的應用程式,您將需要實現 CameraCaptureTask 在 msdn 上記載: [HTTP://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx](http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx)你可能還評論或在[問題追蹤器](https://issues.apache.org/jira/browse/CB-2083)的向上投票的相關的問題
-
- * 忽略了 `mediaType` 屬性的 `cameraOptions` 作為 Windows Phone SDK 並不提供從 PHOTOLIBRARY 中選擇視頻的方法。
-
-## CameraError
-
-onError 的回呼函數提供了一條錯誤訊息。
-
- function(message) {
- // Show a helpful message
- }
-
-
-#### 說明
-
- * **message**: 消息提供的設備的本機代碼。*(String)*
-
-## cameraSuccess
-
-提供的圖像資料的 onSuccess 回呼函數。
-
- function(imageData) {
- // Do something with the image
- }
-
-
-#### 說明
-
- * **imageData**: Base64 編碼進行編碼的圖像資料,*或*影像檔的 URI,取決於 `cameraOptions` 效果。*(String)*
-
-#### 示例
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-由 `navigator.camera.getPicture` 創建的氣泡框對話方塊的控制碼.
-
-#### 說明
-
- * **setPosition**: Set the position of the popover. Takes the `CameraPopoverOptions` that specify the new position.
-
-#### 支援的平臺
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 示例
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS 僅指定氣泡框的錨元素的位置和箭頭方向,從 iPad 庫或專輯選擇圖像時的參數。
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-#### 說明
-
- * **x**: x 螢幕元素到其錨定氣泡框上的圖元座標。*(人數)*
-
- * **y**: 螢幕元素到其錨定氣泡框上的 y 圖元座標。*(人數)*
-
- * **width**: 寬度以圖元為單位),到其錨定氣泡框上的螢幕元素。*(人數)*
-
- * **height**: 高度以圖元為單位),到其錨定氣泡框上的螢幕元素。*(人數)*
-
- * **arrowDir**: 氣泡框上的箭頭應指向的方向。定義在 `Camera.PopoverArrowDirection` *(人數)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-請注意氣泡框的大小可能會更改箭頭的方向和螢幕的方向進行調整。 請確保帳戶方向更改時指定錨元素位置。
-
-## navigator.camera.cleanup
-
-刪除中間從臨時存儲攝像機所拍攝的照片。
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-#### 說明
-
-刪除保留在臨時存儲在調用 `camera.getPicture` 後的中間的影像檔。 適用只有當 `Camera.sourceType` 的值等於 `Camera.PictureSourceType.CAMERA` 和 `Camera.destinationType` 等於 `Camera.DestinationType.FILE_URI`.
-
-#### 支援的平臺
-
-![](doc/img/android-fail.png) ![](doc/img/blackberry-fail.png) ![](doc/img/browser-fail.png) ![](doc/img/firefox-fail.png) ![](doc/img/fireos-fail.png) ![](doc/img/ios-success.png) ![](doc/img/windows-fail.png) ![](doc/img/wp8-fail.png) ![](doc/img/ubuntu-fail.png)
-
-#### 示例
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
\ No newline at end of file
diff --git a/doc/zh/index.md b/doc/zh/index.md
deleted file mode 100644
index ab719ab51..000000000
--- a/doc/zh/index.md
+++ /dev/null
@@ -1,435 +0,0 @@
-
-
-# cordova-plugin-camera
-
-這個外掛程式定義了一個全球 `navigator.camera` 物件,它提供了 API,拍照,從系統的圖像庫中選擇圖像。
-
-雖然該物件附加到全球範圍內 `導航器`,它不可用直到 `deviceready` 事件之後。
-
- document.addEventListener("deviceready", onDeviceReady, false);
- function onDeviceReady() {
- console.log(navigator.camera);
- }
-
-
-## 安裝
-
- cordova plugin add cordova-plugin-camera
-
-
-## navigator.camera.getPicture
-
-需要一張照片,使用相機,或從設備的圖像庫檢索一張照片。 圖像被傳遞給成功回檔的 base64 編碼 `String`,或作為 URI 為影像檔。 該方法本身返回一個 `CameraPopoverHandle` 物件,它可以用來重新置放檔選擇氣泡框。
-
- navigator.camera.getPicture( cameraSuccess, cameraError, cameraOptions );
-
-
-### 說明
-
-`camera.getPicture` 函數打開該設備的預設攝像頭應用程式,允許使用者拍照。 `Camera.sourceType` 等於 `Camera.PictureSourceType.CAMERA` 時,預設情況下,發生此行為。 一旦使用者打斷了他的照片,相機應用程式關閉,且應用程式還原。
-
-如果 `Camera.sourceType` 是 `Camera.PictureSourceType.PHOTOLIBRARY` 或 `Camera.PictureSourceType.SAVEDPHOTOALBUM`,然後顯示一個對話方塊,允許使用者選擇一個現有的圖像。 `camera.getPicture` 函數返回一個 `CameraPopoverHandle` 物件,它可以用於重新置放圖像選擇的對話方塊,例如,當設備的方向變化。
-
-傳回值是發送到 `cameraSuccess` 回呼函數中,在以下的格式,具體取決於指定的 `cameraOptions` 之一:
-
-* A `String` 包含的 base64 編碼的照片圖像。
-
-* A `String` 表示在本機存放區 (預設值) 上的影像檔位置。
-
-你可以做任何你想要的編碼的圖像或 URI,例如:
-
-* 呈現在圖像 ` ` 標記,如下面的示例所示
-
-* 保存本地的資料 ( `LocalStorage` , [Lawnchair][1],等等.)
-
-* 將資料發佈到遠端伺服器
-
- [1]: http://brianleroux.github.com/lawnchair/
-
-**注**: 在更新設備上的照片解析度是很好。 選擇從設備的庫的照片是不壓縮螢幕使其以較低的品質,即使指定了一個 `quality` 參數。 要避免常見的記憶體問題,請將 `Camera.destinationType` 設置為 `FILE_URI`,而不是 `DATA_URL`.
-
-### 支援的平臺
-
-* 亞馬遜火 OS
-* Android 系統
-* 黑莓 10
-* 瀏覽器
-* 火狐瀏覽器的作業系統
-* iOS
-* 泰
-* Windows Phone 7 和 8
-* Windows 8
-
-### 首選項 (iOS)
-
-* **CameraUsesGeolocation**(布林值,預設值為 false)。 用於捕獲 jpeg 檔,設置為 true,以在 EXIF 頭資訊中獲取地理定位資料。 這將觸發請求的地理位置的許可權,如果設置為 true。
-
-
-
-
-### 亞馬遜火 OS 怪癖
-
-亞馬遜火 OS 使用意圖啟動相機活動設備來捕捉圖像上, 和手機上記憶體不足,科爾多瓦活動可能被殺害。 在這種情況下,可能不會顯示圖像時恢復了科爾多瓦活動。
-
-### Android 的怪癖
-
-Android 使用意圖以啟動相機活動設備來捕捉圖像上, 和手機上記憶體不足,科爾多瓦活動可能被殺害。 在這種情況下,可能不會顯示圖像時恢復了科爾多瓦活動。
-
-### 瀏覽器的怪癖
-
-可以只返回照片作為 base64 編碼的圖像。
-
-### 火狐瀏覽器作業系統的怪癖
-
-觀景窗外掛程式目前實施使用 [Web 活動][2].
-
- [2]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-
-### iOS 的怪癖
-
-包括 JavaScript `alert ()` 中的回呼函數會導致問題。 包裝內 `setTimeout()` 允許 iOS 圖像選取器或氣泡框以完全關閉之前,警報將顯示警報:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-
-### Windows Phone 7 的怪癖
-
-調用本機攝像頭應用程式,而通過 Zune 所連接的設備不能工作,並且觸發錯誤回檔。
-
-### 泰怪癖
-
-泰只支援 `destinationType` 的 `Camera.DestinationType.FILE_URI` 和 `Camera.PictureSourceType.PHOTOLIBRARY` 的 `sourceType`.
-
-### 示例
-
-拍一張照片,並檢索它作為一個 base64 編碼的圖像:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-拍一張照片和檢索圖像的檔位置:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-
-## CameraOptions
-
-要自訂相機設置的可選參數。
-
- { quality : 75,
- destinationType : Camera.DestinationType.DATA_URL,
- sourceType : Camera.PictureSourceType.CAMERA,
- allowEdit : true,
- encodingType: Camera.EncodingType.JPEG,
- targetWidth: 100,
- targetHeight: 100,
- popoverOptions: CameraPopoverOptions,
- saveToPhotoAlbum: false };
-
-
-### 選項
-
-* **品質**: 保存的圖像,表示為範圍 0-100,100,是通常全解析度,無損失從檔案壓縮的品質。 預設值為 50。 *(人數)*(請注意相機的解析度有關的資訊是不可用)。
-
-* **可**: 選擇傳回值的格式。預設值是 FILE_URI。定義在 `navigator.camera.DestinationType` *(人數)*
-
- Camera.DestinationType = {
- DATA_URL : 0, // Return image as base64-encoded string
- FILE_URI : 1, // Return image file URI
- NATIVE_URI : 2 // Return image native URI (e.g., assets-library:// on iOS or content:// on Android)
- };
-
-
-* **時**: 設置圖片的來源。預設值是觀景窗。定義在 `navigator.camera.PictureSourceType` *(人數)*
-
- Camera.PictureSourceType = {
- PHOTOLIBRARY : 0,
- CAMERA : 1,
- SAVEDPHOTOALBUM : 2
- };
-
-
-* **allowEdit**: 允許簡單編輯前選擇圖像。*(布林)*
-
-* **encodingType**: 選擇返回的影像檔的編碼。預設值為 JPEG。定義在 `navigator.camera.EncodingType` *(人數)*
-
- Camera.EncodingType = {
- JPEG : 0, // Return JPEG encoded image
- PNG : 1 // Return PNG encoded image
- };
-
-
-* **targetWidth**: 向尺度圖像的圖元寬度。必須用**targetHeight**。縱橫比保持不變。*(人數)*
-
-* **targetHeight**: 以圖元為單位向尺度圖像的高度。必須用**targetWidth**。縱橫比保持不變。*(人數)*
-
-* **媒體類型**: 設置的媒體,從選擇類型。 時才起作用 `PictureSourceType` 是 `PHOTOLIBRARY` 或 `SAVEDPHOTOALBUM` 。 定義在 `nagivator.camera.MediaType` *(人數)*
-
- Camera.MediaType = {
- PICTURE: 0, // allow selection of still pictures only. 預設情況。 Will return format specified via DestinationType
- VIDEO: 1, // allow selection of video only, WILL ALWAYS RETURN FILE_URI
- ALLMEDIA : 2 // allow selection from all media types
- };
-
-
-* **correctOrientation**: 旋轉圖像,該設備時捕獲的定向的正確。*(布林)*
-
-* **saveToPhotoAlbum**: 將圖像保存到相冊在設備上捕獲後。*(布林)*
-
-* **popoverOptions**: 只有 iOS 在 iPad 中指定氣泡框位置的選項。在中定義`CameraPopoverOptions`.
-
-* **cameraDirection**: 選擇相機以使用 (前面或後面-面向)。預設值是背。定義在 `navigator.camera.Direction` *(人數)*
-
- Camera.Direction = {
- BACK : 0, // Use the back-facing camera
- FRONT : 1 // Use the front-facing camera
- };
-
-
-### 亞馬遜火 OS 怪癖
-
-* 任何 `cameraDirection` 值回朝的照片中的結果。
-
-* 忽略 `allowEdit` 參數。
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`和 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 都顯示相同的相冊。
-
-### Android 的怪癖
-
-* 任何 `cameraDirection` 值結果在背面的照片。
-
-* 忽略 `allowEdit` 參數。
-
-* `Camera.PictureSourceType.PHOTOLIBRARY`和 `Camera.PictureSourceType.SAVEDPHOTOALBUM` 都顯示相同的寫真集。
-
-### 黑莓 10 的怪癖
-
-* 忽略 `quality` 參數。
-
-* 忽略 `allowEdit` 參數。
-
-* `Camera.MediaType`不受支援。
-
-* 忽略 `correctOrientation` 參數。
-
-* 忽略 `cameraDirection` 參數。
-
-### 火狐瀏覽器作業系統的怪癖
-
-* 忽略 `quality` 參數。
-
-* `Camera.DestinationType`將被忽略並且等於 `1` (影像檔的 URI)
-
-* 忽略 `allowEdit` 參數。
-
-* 忽略 `PictureSourceType` 參數 (使用者選擇它在對話方塊視窗中)
-
-* 忽略`encodingType`
-
-* 忽略了 `targetWidth` 和`targetHeight`
-
-* `Camera.MediaType`不受支援。
-
-* 忽略 `correctOrientation` 參數。
-
-* 忽略 `cameraDirection` 參數。
-
-### iOS 的怪癖
-
-* 設置 `quality` 低於 50,避免在某些設備上的記憶體不足錯誤。
-
-* 當使用 `destinationType.FILE_URI` ,照片都保存在應用程式的臨時目錄。應用程式結束時,將刪除該應用程式的臨時目錄中的內容。
-
-### 泰怪癖
-
-* 不支援的選項
-
-* 總是返回一個檔的 URI
-
-### Windows Phone 7 和 8 的怪癖
-
-* 忽略 `allowEdit` 參數。
-
-* 忽略 `correctOrientation` 參數。
-
-* 忽略 `cameraDirection` 參數。
-
-* 忽略 `saveToPhotoAlbum` 參數。 重要: 使用 wp7/8 科爾多瓦攝像頭 API 拍攝的所有圖像總是都複製到手機的相機膠捲。 根據使用者的設置,這可能也意味著圖像是自動上傳到他們另。 這有可能意味著的圖像,可以比你的應用程式的目的更多的觀眾。 如果此阻滯劑您的應用程式,您將需要實現 CameraCaptureTask 在 msdn 上記載: [HTTP://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx][3]你可能還評論或在[問題追蹤器][4]的向上投票的相關的問題
-
-* 忽略了 `mediaType` 屬性的 `cameraOptions` 作為 Windows Phone SDK 並不提供從 PHOTOLIBRARY 中選擇視頻的方法。
-
- [3]: http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx
- [4]: https://issues.apache.org/jira/browse/CB-2083
-
-## CameraError
-
-onError 的回呼函數提供了一條錯誤訊息。
-
- function(message) {
- // Show a helpful message
- }
-
-
-### 參數
-
-* **message**: 消息提供的設備的本機代碼。*(String)*
-
-## cameraSuccess
-
-提供的圖像資料的 onSuccess 回呼函數。
-
- function(imageData) {
- // Do something with the image
- }
-
-
-### 參數
-
-* **imageData**: Base64 編碼進行編碼的圖像資料,*或*影像檔的 URI,取決於 `cameraOptions` 效果。*(String)*
-
-### 示例
-
- // Show image
- //
- function cameraCallback(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
-
-## CameraPopoverHandle
-
-由 `navigator.camera.getPicture` 創建的氣泡框對話方塊的控制碼.
-
-### 方法
-
-* **setPosition**: 設置氣泡框的位置。
-
-### 支援的平臺
-
-* iOS
-
-### setPosition
-
-設置氣泡框的位置。
-
-**參數**:
-
-* `cameraPopoverOptions`: `CameraPopoverOptions` ,指定新的位置
-
-### 示例
-
- var cameraPopoverHandle = navigator.camera.getPicture(onSuccess, onFail,
- { destinationType: Camera.DestinationType.FILE_URI,
- sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
- });
-
- // Reposition the popover if the orientation changes.
- window.onorientationchange = function() {
- var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
- cameraPopoverHandle.setPosition(cameraPopoverOptions);
- }
-
-
-## CameraPopoverOptions
-
-iOS 僅指定氣泡框的錨元素的位置和箭頭方向,從 iPad 庫或專輯選擇圖像時的參數。
-
- { x : 0,
- y : 32,
- width : 320,
- height : 480,
- arrowDir : Camera.PopoverArrowDirection.ARROW_ANY
- };
-
-
-### CameraPopoverOptions
-
-* **x**: x 螢幕元素到其錨定氣泡框上的圖元座標。*(人數)*
-
-* **y**: 螢幕元素到其錨定氣泡框上的 y 圖元座標。*(人數)*
-
-* **width**: 寬度以圖元為單位),到其錨定氣泡框上的螢幕元素。*(人數)*
-
-* **height**: 高度以圖元為單位),到其錨定氣泡框上的螢幕元素。*(人數)*
-
-* **arrowDir**: 氣泡框上的箭頭應指向的方向。定義在 `Camera.PopoverArrowDirection` *(人數)*
-
- Camera.PopoverArrowDirection = {
- ARROW_UP : 1, // matches iOS UIPopoverArrowDirection constants
- ARROW_DOWN : 2,
- ARROW_LEFT : 4,
- ARROW_RIGHT : 8,
- ARROW_ANY : 15
- };
-
-
-請注意氣泡框的大小可能會更改箭頭的方向和螢幕的方向進行調整。 請確保帳戶方向更改時指定錨元素位置。
-
-## navigator.camera.cleanup
-
-刪除中間從臨時存儲攝像機所拍攝的照片。
-
- navigator.camera.cleanup( cameraSuccess, cameraError );
-
-
-### 描述
-
-刪除保留在臨時存儲在調用 `camera.getPicture` 後的中間的影像檔。 適用只有當 `Camera.sourceType` 的值等於 `Camera.PictureSourceType.CAMERA` 和 `Camera.destinationType` 等於 `Camera.DestinationType.FILE_URI`.
-
-### 支援的平臺
-
-* iOS
-
-### 示例
-
- navigator.camera.cleanup(onSuccess, onFail);
-
- function onSuccess() {
- console.log("Camera cleanup success.")
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
diff --git a/jsdoc2md/TEMPLATE.md b/jsdoc2md/TEMPLATE.md
deleted file mode 100644
index 194719388..000000000
--- a/jsdoc2md/TEMPLATE.md
+++ /dev/null
@@ -1,460 +0,0 @@
----
-title: Camera
-description: Take pictures with the device camera.
----
-{{>cdv-license~}}
-
-|AppVeyor|Travis CI|
-|:-:|:-:|
-|[![Build status](https://ci.appveyor.com/api/projects/status/github/apache/cordova-plugin-camera?branch=master)](https://ci.appveyor.com/project/ApacheSoftwareFoundation/cordova-plugin-camera)|[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg?branch=master)](https://travis-ci.org/apache/cordova-plugin-camera)|
-
-# cordova-plugin-camera
-
-This plugin defines a global `navigator.camera` object, which provides an API for taking pictures and for choosing images from
-the system's image library.
-
-{{>cdv-header device-ready-warning-obj='navigator.camera' npmName='cordova-plugin-camera' cprName='org.apache.cordova.camera' pluginName='cordova-plugin-camera' repoUrl='https://github.com/apache/cordova-plugin-camera' }}
-
-
-### iOS Quirks
-
-Since iOS 10 it's mandatory to provide an usage description in the `info.plist` if trying to access privacy-sensitive data. When the system prompts the user to allow access, this usage description string will displayed as part of the permission dialog box, but if you didn't provide the usage description, the app will crash before showing the dialog. Also, Apple will reject apps that access private data but don't provide an usage description.
-
-This plugins requires the following usage descriptions:
-
-- `NSCameraUsageDescription` specifies the reason for your app to access the device's camera.
-- `NSPhotoLibraryUsageDescription` specifies the reason for your app to access the user's photo library.
-- `NSLocationWhenInUseUsageDescription` specifies the reason for your app to access the user's location information while your app is in use. (Set it if you have `CameraUsesGeolocation` preference set to `true`)
-- `NSPhotoLibraryAddUsageDescription` specifies the reason for your app to get write-only access to the user's photo library
-
-To add these entries into the `info.plist`, you can use the `edit-config` tag in the `config.xml` like this:
-
-```
-
- need camera access to take pictures
-
-```
-
-```
-
- need photo library access to get pictures from there
-
-```
-
-```
-
- need location access to find things nearby
-
-```
-
-```
-
- need photo library access to save pictures there
-
-```
-
----
-
-# API Reference
-
-{{#orphans~}}
-{{>member-index}}
-{{/orphans}}
-* [CameraPopoverHandle](#module_CameraPopoverHandle)
-* [CameraPopoverOptions](#module_CameraPopoverOptions)
-
----
-
-{{#modules~}}
-{{>header~}}
-{{>body~}}
-{{>members~}}
-
----
-
-{{/modules}}
-
-## `camera.getPicture` Errata
-
-#### Example
-
-Take a photo and retrieve the image's file location:
-
- navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
- destinationType: Camera.DestinationType.FILE_URI });
-
- function onSuccess(imageURI) {
- var image = document.getElementById('myImage');
- image.src = imageURI;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-Take a photo and retrieve it as a Base64-encoded image:
-
- /**
- * Warning: Using DATA_URL is not recommended! The DATA_URL destination
- * type is very memory intensive, even with a low quality setting. Using it
- * can result in out of memory errors and application crashes. Use FILE_URI
- * or NATIVE_URI instead.
- */
- navigator.camera.getPicture(onSuccess, onFail, { quality: 25,
- destinationType: Camera.DestinationType.DATA_URL
- });
-
- function onSuccess(imageData) {
- var image = document.getElementById('myImage');
- image.src = "data:image/jpeg;base64," + imageData;
- }
-
- function onFail(message) {
- alert('Failed because: ' + message);
- }
-
-#### Preferences (iOS)
-
-- __CameraUsesGeolocation__ (boolean, defaults to false). For capturing JPEGs, set to true to get geolocation data in the EXIF header. This will trigger a request for geolocation permissions if set to true.
-
-
-
-#### Amazon Fire OS Quirks
-
-Amazon Fire OS uses intents to launch the camera activity on the device to capture
-images, and on phones with low memory, the Cordova activity may be killed. In this
-scenario, the image may not appear when the Cordova activity is restored.
-
-#### Android Quirks
-
-Android uses intents to launch the camera activity on the device to capture
-images, and on phones with low memory, the Cordova activity may be killed. In this
-scenario, the result from the plugin call will be delivered via the resume event.
-See [the Android Lifecycle guide][android_lifecycle]
-for more information. The `pendingResult.result` value will contain the value that
-would be passed to the callbacks (either the URI/URL or an error message). Check
-the `pendingResult.pluginStatus` to determine whether or not the call was
-successful.
-
-#### Browser Quirks
-
-Can only return photos as Base64-encoded image.
-
-#### Firefox OS Quirks
-
-Camera plugin is currently implemented using [Web Activities][web_activities].
-
-#### iOS Quirks
-
-Including a JavaScript `alert()` in either of the callback functions
-can cause problems. Wrap the alert within a `setTimeout()` to allow
-the iOS image picker or popover to fully close before the alert
-displays:
-
- setTimeout(function() {
- // do your thing here!
- }, 0);
-
-#### Windows Phone 7 Quirks
-
-Invoking the native camera application while the device is connected
-via Zune does not work, and triggers an error callback.
-
-#### Windows quirks
-
-On Windows Phone 8.1 using `SAVEDPHOTOALBUM` or `PHOTOLIBRARY` as a source type causes application to suspend until file picker returns the selected image and
-then restore with start page as defined in app's `config.xml`. In case when `camera.getPicture` was called from different page, this will lead to reloading
-start page from scratch and success and error callbacks will never be called.
-
-To avoid this we suggest using SPA pattern or call `camera.getPicture` only from your app's start page.
-
-More information about Windows Phone 8.1 picker APIs is here: [How to continue your Windows Phone app after calling a file picker](https://msdn.microsoft.com/en-us/library/windows/apps/dn720490.aspx)
-
-#### Tizen Quirks
-
-Tizen only supports a `destinationType` of
-`Camera.DestinationType.FILE_URI` and a `sourceType` of
-`Camera.PictureSourceType.PHOTOLIBRARY`.
-
-
-## `CameraOptions` Errata
-
-#### Amazon Fire OS Quirks
-
-- Any `cameraDirection` value results in a back-facing photo.
-
-- Ignores the `allowEdit` parameter.
-
-- `Camera.PictureSourceType.PHOTOLIBRARY` and `Camera.PictureSourceType.SAVEDPHOTOALBUM` both display the same photo album.
-
-#### Android Quirks
-
-- Any `cameraDirection` value results in a back-facing photo.
-
-- **`allowEdit` is unpredictable on Android and it should not be used!** The Android implementation of this plugin tries to find and use an application on the user's device to do image cropping. The plugin has no control over what application the user selects to perform the image cropping and it is very possible that the user could choose an incompatible option and cause the plugin to fail. This sometimes works because most devices come with an application that handles cropping in a way that is compatible with this plugin (Google Plus Photos), but it is unwise to rely on that being the case. If image editing is essential to your application, consider seeking a third party library or plugin that provides its own image editing utility for a more robust solution.
-
-- `Camera.PictureSourceType.PHOTOLIBRARY` and `Camera.PictureSourceType.SAVEDPHOTOALBUM` both display the same photo album.
-
-- Ignores the `encodingType` parameter if the image is unedited (i.e. `quality` is 100, `correctOrientation` is false, and no `targetHeight` or `targetWidth` are specified). The `CAMERA` source will always return the JPEG file given by the native camera and the `PHOTOLIBRARY` and `SAVEDPHOTOALBUM` sources will return the selected file in its existing encoding.
-
-#### BlackBerry 10 Quirks
-
-- Ignores the `quality` parameter.
-
-- Ignores the `allowEdit` parameter.
-
-- `Camera.MediaType` is not supported.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
-#### Firefox OS Quirks
-
-- Ignores the `quality` parameter.
-
-- `Camera.DestinationType` is ignored and equals `1` (image file URI)
-
-- Ignores the `allowEdit` parameter.
-
-- Ignores the `PictureSourceType` parameter (user chooses it in a dialog window)
-
-- Ignores the `encodingType`
-
-- Ignores the `targetWidth` and `targetHeight`
-
-- `Camera.MediaType` is not supported.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
-#### iOS Quirks
-
-- When using `destinationType.FILE_URI`, photos are saved in the application's temporary directory. The contents of the application's temporary directory is deleted when the application ends.
-
-- When using `destinationType.NATIVE_URI` and `sourceType.CAMERA`, photos are saved in the saved photo album regardless on the value of `saveToPhotoAlbum` parameter.
-
-- When using `destinationType.NATIVE_URI` and `sourceType.PHOTOLIBRARY` or `sourceType.SAVEDPHOTOALBUM`, all editing options are ignored and link is returned to original picture.
-
-#### Tizen Quirks
-
-- options not supported
-
-- always returns a FILE URI
-
-#### Windows Phone 7 and 8 Quirks
-
-- Ignores the `allowEdit` parameter.
-
-- Ignores the `correctOrientation` parameter.
-
-- Ignores the `cameraDirection` parameter.
-
-- Ignores the `saveToPhotoAlbum` parameter. IMPORTANT: All images taken with the WP8/8 Cordova camera API are always copied to the phone's camera roll. Depending on the user's settings, this could also mean the image is auto-uploaded to their OneDrive. This could potentially mean the image is available to a wider audience than your app intended. If this is a blocker for your application, you will need to implement the CameraCaptureTask as [documented on MSDN][msdn_wp8_docs]. You may also comment or up-vote the related issue in the [issue tracker][wp8_bug].
-
-- Ignores the `mediaType` property of `cameraOptions` as the Windows Phone SDK does not provide a way to choose videos from PHOTOLIBRARY.
-
-[android_lifecycle]: http://cordova.apache.org/docs/en/dev/guide/platforms/android/lifecycle.html
-[web_activities]: https://hacks.mozilla.org/2013/01/introducing-web-activities/
-[wp8_bug]: https://issues.apache.org/jira/browse/CB-2083
-[msdn_wp8_docs]: http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394006.aspx
-
-## Sample: Take Pictures, Select Pictures from the Picture Library, and Get Thumbnails
-
-The Camera plugin allows you to do things like open the device's Camera app and take a picture, or open the file picker and select one. The code snippets in this section demonstrate different tasks including:
-
-* Open the Camera app and [take a Picture](#takePicture)
-* Take a picture and [return thumbnails](#getThumbnails) (resized picture)
-* Take a picture and [generate a FileEntry object](#convert)
-* [Select a file](#selectFile) from the picture library
-* Select a JPEG image and [return thumbnails](#getFileThumbnails) (resized image)
-* Select an image and [generate a FileEntry object](#convert)
-
-## Take a Picture
-
-Before you can take a picture, you need to set some Camera plugin options to pass into the Camera plugin's `getPicture` function. Here is a common set of recommendations. In this example, you create the object that you will use for the Camera options, and set the `sourceType` dynamically to support both the Camera app and the file picker.
-
-```js
-function setOptions(srcType) {
- var options = {
- // Some common settings are 20, 50, and 100
- quality: 50,
- destinationType: Camera.DestinationType.FILE_URI,
- // In this app, dynamically set the picture source, Camera or photo gallery
- sourceType: srcType,
- encodingType: Camera.EncodingType.JPEG,
- mediaType: Camera.MediaType.PICTURE,
- allowEdit: true,
- correctOrientation: true //Corrects Android orientation quirks
- }
- return options;
-}
-```
-
-Typically, you want to use a FILE_URI instead of a DATA_URL to avoid most memory issues. JPEG is the recommended encoding type for Android.
-
-You take a picture by passing in the options object to `getPicture`, which takes a CameraOptions object as the third argument. When you call `setOptions`, pass `Camera.PictureSourceType.CAMERA` as the picture source.
-
-```js
-function openCamera(selection) {
-
- var srcType = Camera.PictureSourceType.CAMERA;
- var options = setOptions(srcType);
- var func = createNewFileEntry;
-
- navigator.camera.getPicture(function cameraSuccess(imageUri) {
-
- displayImage(imageUri);
- // You may choose to copy the picture, save it somewhere, or upload.
- func(imageUri);
-
- }, function cameraError(error) {
- console.debug("Unable to obtain picture: " + error, "app");
-
- }, options);
-}
-```
-
-Once you take the picture, you can display it or do something else. In this example, call the app's `displayImage` function from the preceding code.
-
-```js
-function displayImage(imgUri) {
-
- var elem = document.getElementById('imageFile');
- elem.src = imgUri;
-}
-```
-
-To display the image on some platforms, you might need to include the main part of the URI in the Content-Security-Policy ` ` element in index.html. For example, on Windows 10, you can include `ms-appdata:` in your ` ` element. Here is an example.
-
-```html
-
-```
-
-## Take a Picture and Return Thumbnails (Resize the Picture)
-
-To get smaller images, you can return a resized image by passing both `targetHeight` and `targetWidth` values with your CameraOptions object. In this example, you resize the returned image to fit in a 100px by 100px box (the aspect ratio is maintained, so 100px is either the height or width, whichever is greater in the source).
-
-```js
-function openCamera(selection) {
-
- var srcType = Camera.PictureSourceType.CAMERA;
- var options = setOptions(srcType);
- var func = createNewFileEntry;
-
- if (selection == "camera-thmb") {
- options.targetHeight = 100;
- options.targetWidth = 100;
- }
-
- navigator.camera.getPicture(function cameraSuccess(imageUri) {
-
- // Do something
-
- }, function cameraError(error) {
- console.debug("Unable to obtain picture: " + error, "app");
-
- }, options);
-}
-```
-
-## Select a File from the Picture Library
-
-When selecting a file using the file picker, you also need to set the CameraOptions object. In this example, set the `sourceType` to `Camera.PictureSourceType.SAVEDPHOTOALBUM`. To open the file picker, call `getPicture` just as you did in the previous example, passing in the success and error callbacks along with CameraOptions object.
-
-```js
-function openFilePicker(selection) {
-
- var srcType = Camera.PictureSourceType.SAVEDPHOTOALBUM;
- var options = setOptions(srcType);
- var func = createNewFileEntry;
-
- navigator.camera.getPicture(function cameraSuccess(imageUri) {
-
- // Do something
-
- }, function cameraError(error) {
- console.debug("Unable to obtain picture: " + error, "app");
-
- }, options);
-}
-```
-
-## Select an Image and Return Thumbnails (resized images)
-
-Resizing a file selected with the file picker works just like resizing using the Camera app; set the `targetHeight` and `targetWidth` options.
-
-```js
-function openFilePicker(selection) {
-
- var srcType = Camera.PictureSourceType.SAVEDPHOTOALBUM;
- var options = setOptions(srcType);
- var func = createNewFileEntry;
-
- if (selection == "picker-thmb") {
- // To downscale a selected image,
- // Camera.EncodingType (e.g., JPEG) must match the selected image type.
- options.targetHeight = 100;
- options.targetWidth = 100;
- }
-
- navigator.camera.getPicture(function cameraSuccess(imageUri) {
-
- // Do something with image
-
- }, function cameraError(error) {
- console.debug("Unable to obtain picture: " + error, "app");
-
- }, options);
-}
-```
-
-## Take a picture and get a FileEntry Object
-
-If you want to do something like copy the image to another location, or upload it somewhere using the FileTransfer plugin, you need to get a FileEntry object for the returned picture. To do that, call `window.resolveLocalFileSystemURL` on the file URI returned by the Camera app. If you need to use a FileEntry object, set the `destinationType` to `Camera.DestinationType.FILE_URI` in your CameraOptions object (this is also the default value).
-
->*Note* You need the [File plugin](https://www.npmjs.com/package/cordova-plugin-file) to call `window.resolveLocalFileSystemURL`.
-
-Here is the call to `window.resolveLocalFileSystemURL`. The image URI is passed to this function from the success callback of `getPicture`. The success handler of `resolveLocalFileSystemURL` receives the FileEntry object.
-
-```js
-function getFileEntry(imgUri) {
- window.resolveLocalFileSystemURL(imgUri, function success(fileEntry) {
-
- // Do something with the FileEntry object, like write to it, upload it, etc.
- // writeFile(fileEntry, imgUri);
- console.log("got file: " + fileEntry.fullPath);
- // displayFileData(fileEntry.nativeURL, "Native URL");
-
- }, function () {
- // If don't get the FileEntry (which may happen when testing
- // on some emulators), copy to a new FileEntry.
- createNewFileEntry(imgUri);
- });
-}
-```
-
-In the example shown in the preceding code, you call the app's `createNewFileEntry` function if you don't get a valid FileEntry object. The image URI returned from the Camera app should result in a valid FileEntry, but platform behavior on some emulators may be different for files returned from the file picker.
-
->*Note* To see an example of writing to a FileEntry, see the [File plugin README](https://www.npmjs.com/package/cordova-plugin-file).
-
-The code shown here creates a file in your app's cache (in sandboxed storage) named `tempFile.jpeg`. With the new FileEntry object, you can copy the image to the file or do something else like upload it.
-
-```js
-function createNewFileEntry(imgUri) {
- window.resolveLocalFileSystemURL(cordova.file.cacheDirectory, function success(dirEntry) {
-
- // JPEG file
- dirEntry.getFile("tempFile.jpeg", { create: true, exclusive: false }, function (fileEntry) {
-
- // Do something with it, like write to it, upload it, etc.
- // writeFile(fileEntry, imgUri);
- console.log("got file: " + fileEntry.fullPath);
- // displayFileData(fileEntry.fullPath, "File copied to");
-
- }, onErrorCreateFile);
-
- }, onErrorResolveUrl);
-}
-```
diff --git a/package-lock.json b/package-lock.json
new file mode 100644
index 000000000..aaa1f6c79
--- /dev/null
+++ b/package-lock.json
@@ -0,0 +1,4229 @@
+{
+ "name": "cordova-plugin-camera",
+ "version": "7.0.0",
+ "lockfileVersion": 2,
+ "requires": true,
+ "packages": {
+ "": {
+ "name": "cordova-plugin-camera",
+ "version": "7.0.0",
+ "license": "Apache-2.0",
+ "devDependencies": {
+ "@cordova/eslint-config": "^5.0.0"
+ },
+ "engines": {
+ "cordovaDependencies": {
+ "3.0.0": {
+ "cordova-android": ">=6.3.0"
+ },
+ "4.1.0": {
+ "cordova": ">=7.1.0",
+ "cordova-android": ">=6.3.0"
+ },
+ "5.0.0": {
+ "cordova": ">=9.0.0",
+ "cordova-android": ">=9.0.0",
+ "cordova-ios": ">=5.1.0"
+ },
+ "5.0.4-dev": {
+ "cordova": ">=9.0.0",
+ "cordova-android": "<10.0.0",
+ "cordova-ios": ">=5.1.0"
+ },
+ "6.0.0": {
+ "cordova": ">=9.0.0",
+ "cordova-android": ">=10.0.0",
+ "cordova-ios": ">=5.1.0"
+ },
+ "7.0.0": {
+ "cordova": ">=9.0.0",
+ "cordova-android": ">=12.0.0",
+ "cordova-ios": ">=5.1.0"
+ },
+ "8.0.0": {
+ "cordova": ">100"
+ }
+ }
+ }
+ },
+ "node_modules/@aashutoshrathi/word-wrap": {
+ "version": "1.2.6",
+ "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz",
+ "integrity": "sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==",
+ "dev": true,
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/@cordova/eslint-config": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/@cordova/eslint-config/-/eslint-config-5.0.0.tgz",
+ "integrity": "sha512-tBSV8LbT6RjWsO2lSp45Y+zU7hfXhGMGhfYTZjDrjzli87WOgE6IAS37k6F45JNoGq1XlCJEVkCWwz4KCF8Scw==",
+ "dev": true,
+ "dependencies": {
+ "eslint": "^8.31.0",
+ "eslint-config-standard": "^17.0.0",
+ "eslint-plugin-import": "^2.27.2",
+ "eslint-plugin-n": "^15.6.1",
+ "eslint-plugin-promise": "^6.1.1"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ }
+ },
+ "node_modules/@eslint-community/eslint-utils": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz",
+ "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==",
+ "dev": true,
+ "dependencies": {
+ "eslint-visitor-keys": "^3.3.0"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "peerDependencies": {
+ "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0"
+ }
+ },
+ "node_modules/@eslint-community/regexpp": {
+ "version": "4.6.2",
+ "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.6.2.tgz",
+ "integrity": "sha512-pPTNuaAG3QMH+buKyBIGJs3g/S5y0caxw0ygM3YyE6yJFySwiGGSzA+mM3KJ8QQvzeLh3blwgSonkFjgQdxzMw==",
+ "dev": true,
+ "engines": {
+ "node": "^12.0.0 || ^14.0.0 || >=16.0.0"
+ }
+ },
+ "node_modules/@eslint/eslintrc": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.2.tgz",
+ "integrity": "sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g==",
+ "dev": true,
+ "dependencies": {
+ "ajv": "^6.12.4",
+ "debug": "^4.3.2",
+ "espree": "^9.6.0",
+ "globals": "^13.19.0",
+ "ignore": "^5.2.0",
+ "import-fresh": "^3.2.1",
+ "js-yaml": "^4.1.0",
+ "minimatch": "^3.1.2",
+ "strip-json-comments": "^3.1.1"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://opencollective.com/eslint"
+ }
+ },
+ "node_modules/@eslint/js": {
+ "version": "8.47.0",
+ "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.47.0.tgz",
+ "integrity": "sha512-P6omY1zv5MItm93kLM8s2vr1HICJH8v0dvddDhysbIuZ+vcjOHg5Zbkf1mTkcmi2JA9oBG2anOkRnW8WJTS8Og==",
+ "dev": true,
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ }
+ },
+ "node_modules/@humanwhocodes/config-array": {
+ "version": "0.11.10",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.10.tgz",
+ "integrity": "sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==",
+ "dev": true,
+ "dependencies": {
+ "@humanwhocodes/object-schema": "^1.2.1",
+ "debug": "^4.1.1",
+ "minimatch": "^3.0.5"
+ },
+ "engines": {
+ "node": ">=10.10.0"
+ }
+ },
+ "node_modules/@humanwhocodes/module-importer": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz",
+ "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==",
+ "dev": true,
+ "engines": {
+ "node": ">=12.22"
+ },
+ "funding": {
+ "type": "github",
+ "url": "https://github.com/sponsors/nzakas"
+ }
+ },
+ "node_modules/@humanwhocodes/object-schema": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz",
+ "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==",
+ "dev": true
+ },
+ "node_modules/@nodelib/fs.scandir": {
+ "version": "2.1.5",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
+ "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
+ "dev": true,
+ "dependencies": {
+ "@nodelib/fs.stat": "2.0.5",
+ "run-parallel": "^1.1.9"
+ },
+ "engines": {
+ "node": ">= 8"
+ }
+ },
+ "node_modules/@nodelib/fs.stat": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
+ "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
+ "dev": true,
+ "engines": {
+ "node": ">= 8"
+ }
+ },
+ "node_modules/@nodelib/fs.walk": {
+ "version": "1.2.8",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
+ "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
+ "dev": true,
+ "dependencies": {
+ "@nodelib/fs.scandir": "2.1.5",
+ "fastq": "^1.6.0"
+ },
+ "engines": {
+ "node": ">= 8"
+ }
+ },
+ "node_modules/@types/json5": {
+ "version": "0.0.29",
+ "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz",
+ "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==",
+ "dev": true
+ },
+ "node_modules/acorn": {
+ "version": "8.10.0",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
+ "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "dev": true,
+ "bin": {
+ "acorn": "bin/acorn"
+ },
+ "engines": {
+ "node": ">=0.4.0"
+ }
+ },
+ "node_modules/acorn-jsx": {
+ "version": "5.3.2",
+ "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz",
+ "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==",
+ "dev": true,
+ "peerDependencies": {
+ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0"
+ }
+ },
+ "node_modules/ajv": {
+ "version": "6.12.6",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz",
+ "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.1",
+ "fast-json-stable-stringify": "^2.0.0",
+ "json-schema-traverse": "^0.4.1",
+ "uri-js": "^4.2.2"
+ },
+ "funding": {
+ "type": "github",
+ "url": "https://github.com/sponsors/epoberezkin"
+ }
+ },
+ "node_modules/ansi-regex": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
+ "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "dev": true,
+ "dependencies": {
+ "color-convert": "^2.0.1"
+ },
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/chalk/ansi-styles?sponsor=1"
+ }
+ },
+ "node_modules/argparse": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
+ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "dev": true
+ },
+ "node_modules/array-buffer-byte-length": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz",
+ "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "is-array-buffer": "^3.0.1"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/array-includes": {
+ "version": "3.1.6",
+ "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.6.tgz",
+ "integrity": "sha512-sgTbLvL6cNnw24FnbaDyjmvddQ2ML8arZsgaJhoABMoplz/4QRhtrYS+alr1BUM1Bwp6dhx8vVCBSLG+StwOFw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "get-intrinsic": "^1.1.3",
+ "is-string": "^1.0.7"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/array.prototype.findlastindex": {
+ "version": "1.2.2",
+ "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.2.tgz",
+ "integrity": "sha512-tb5thFFlUcp7NdNF6/MpDk/1r/4awWG1FIz3YqDf+/zJSTezBb+/5WViH41obXULHVpDzoiCLpJ/ZO9YbJMsdw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0",
+ "get-intrinsic": "^1.1.3"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/array.prototype.flat": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.1.tgz",
+ "integrity": "sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/array.prototype.flatmap": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.1.tgz",
+ "integrity": "sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/arraybuffer.prototype.slice": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.1.tgz",
+ "integrity": "sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw==",
+ "dev": true,
+ "dependencies": {
+ "array-buffer-byte-length": "^1.0.0",
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "get-intrinsic": "^1.2.1",
+ "is-array-buffer": "^3.0.2",
+ "is-shared-array-buffer": "^1.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/available-typed-arrays": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz",
+ "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/balanced-match": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
+ "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==",
+ "dev": true
+ },
+ "node_modules/brace-expansion": {
+ "version": "1.1.11",
+ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
+ "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
+ "dev": true,
+ "dependencies": {
+ "balanced-match": "^1.0.0",
+ "concat-map": "0.0.1"
+ }
+ },
+ "node_modules/builtins": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/builtins/-/builtins-5.0.1.tgz",
+ "integrity": "sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==",
+ "dev": true,
+ "dependencies": {
+ "semver": "^7.0.0"
+ }
+ },
+ "node_modules/builtins/node_modules/semver": {
+ "version": "7.5.4",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz",
+ "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==",
+ "dev": true,
+ "dependencies": {
+ "lru-cache": "^6.0.0"
+ },
+ "bin": {
+ "semver": "bin/semver.js"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/call-bind": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz",
+ "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==",
+ "dev": true,
+ "dependencies": {
+ "function-bind": "^1.1.1",
+ "get-intrinsic": "^1.0.2"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/callsites": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
+ "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/chalk": {
+ "version": "4.1.2",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
+ "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
+ "dev": true,
+ "dependencies": {
+ "ansi-styles": "^4.1.0",
+ "supports-color": "^7.1.0"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/chalk/chalk?sponsor=1"
+ }
+ },
+ "node_modules/color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "dev": true,
+ "dependencies": {
+ "color-name": "~1.1.4"
+ },
+ "engines": {
+ "node": ">=7.0.0"
+ }
+ },
+ "node_modules/color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
+ "dev": true
+ },
+ "node_modules/concat-map": {
+ "version": "0.0.1",
+ "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
+ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==",
+ "dev": true
+ },
+ "node_modules/cross-spawn": {
+ "version": "7.0.3",
+ "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
+ "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==",
+ "dev": true,
+ "dependencies": {
+ "path-key": "^3.1.0",
+ "shebang-command": "^2.0.0",
+ "which": "^2.0.1"
+ },
+ "engines": {
+ "node": ">= 8"
+ }
+ },
+ "node_modules/debug": {
+ "version": "4.3.4",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz",
+ "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
+ "dev": true,
+ "dependencies": {
+ "ms": "2.1.2"
+ },
+ "engines": {
+ "node": ">=6.0"
+ },
+ "peerDependenciesMeta": {
+ "supports-color": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/deep-is": {
+ "version": "0.1.4",
+ "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz",
+ "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==",
+ "dev": true
+ },
+ "node_modules/define-properties": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz",
+ "integrity": "sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA==",
+ "dev": true,
+ "dependencies": {
+ "has-property-descriptors": "^1.0.0",
+ "object-keys": "^1.1.1"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/doctrine": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz",
+ "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==",
+ "dev": true,
+ "dependencies": {
+ "esutils": "^2.0.2"
+ },
+ "engines": {
+ "node": ">=6.0.0"
+ }
+ },
+ "node_modules/es-abstract": {
+ "version": "1.22.1",
+ "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.1.tgz",
+ "integrity": "sha512-ioRRcXMO6OFyRpyzV3kE1IIBd4WG5/kltnzdxSCqoP8CMGs/Li+M1uF5o7lOkZVFjDs+NLesthnF66Pg/0q0Lw==",
+ "dev": true,
+ "dependencies": {
+ "array-buffer-byte-length": "^1.0.0",
+ "arraybuffer.prototype.slice": "^1.0.1",
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "es-set-tostringtag": "^2.0.1",
+ "es-to-primitive": "^1.2.1",
+ "function.prototype.name": "^1.1.5",
+ "get-intrinsic": "^1.2.1",
+ "get-symbol-description": "^1.0.0",
+ "globalthis": "^1.0.3",
+ "gopd": "^1.0.1",
+ "has": "^1.0.3",
+ "has-property-descriptors": "^1.0.0",
+ "has-proto": "^1.0.1",
+ "has-symbols": "^1.0.3",
+ "internal-slot": "^1.0.5",
+ "is-array-buffer": "^3.0.2",
+ "is-callable": "^1.2.7",
+ "is-negative-zero": "^2.0.2",
+ "is-regex": "^1.1.4",
+ "is-shared-array-buffer": "^1.0.2",
+ "is-string": "^1.0.7",
+ "is-typed-array": "^1.1.10",
+ "is-weakref": "^1.0.2",
+ "object-inspect": "^1.12.3",
+ "object-keys": "^1.1.1",
+ "object.assign": "^4.1.4",
+ "regexp.prototype.flags": "^1.5.0",
+ "safe-array-concat": "^1.0.0",
+ "safe-regex-test": "^1.0.0",
+ "string.prototype.trim": "^1.2.7",
+ "string.prototype.trimend": "^1.0.6",
+ "string.prototype.trimstart": "^1.0.6",
+ "typed-array-buffer": "^1.0.0",
+ "typed-array-byte-length": "^1.0.0",
+ "typed-array-byte-offset": "^1.0.0",
+ "typed-array-length": "^1.0.4",
+ "unbox-primitive": "^1.0.2",
+ "which-typed-array": "^1.1.10"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/es-set-tostringtag": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz",
+ "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==",
+ "dev": true,
+ "dependencies": {
+ "get-intrinsic": "^1.1.3",
+ "has": "^1.0.3",
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/es-shim-unscopables": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.0.tgz",
+ "integrity": "sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==",
+ "dev": true,
+ "dependencies": {
+ "has": "^1.0.3"
+ }
+ },
+ "node_modules/es-to-primitive": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz",
+ "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==",
+ "dev": true,
+ "dependencies": {
+ "is-callable": "^1.1.4",
+ "is-date-object": "^1.0.1",
+ "is-symbol": "^1.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/escape-string-regexp": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz",
+ "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",
+ "dev": true,
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/eslint": {
+ "version": "8.47.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.47.0.tgz",
+ "integrity": "sha512-spUQWrdPt+pRVP1TTJLmfRNJJHHZryFmptzcafwSvHsceV81djHOdnEeDmkdotZyLNjDhrOasNK8nikkoG1O8Q==",
+ "dev": true,
+ "dependencies": {
+ "@eslint-community/eslint-utils": "^4.2.0",
+ "@eslint-community/regexpp": "^4.6.1",
+ "@eslint/eslintrc": "^2.1.2",
+ "@eslint/js": "^8.47.0",
+ "@humanwhocodes/config-array": "^0.11.10",
+ "@humanwhocodes/module-importer": "^1.0.1",
+ "@nodelib/fs.walk": "^1.2.8",
+ "ajv": "^6.12.4",
+ "chalk": "^4.0.0",
+ "cross-spawn": "^7.0.2",
+ "debug": "^4.3.2",
+ "doctrine": "^3.0.0",
+ "escape-string-regexp": "^4.0.0",
+ "eslint-scope": "^7.2.2",
+ "eslint-visitor-keys": "^3.4.3",
+ "espree": "^9.6.1",
+ "esquery": "^1.4.2",
+ "esutils": "^2.0.2",
+ "fast-deep-equal": "^3.1.3",
+ "file-entry-cache": "^6.0.1",
+ "find-up": "^5.0.0",
+ "glob-parent": "^6.0.2",
+ "globals": "^13.19.0",
+ "graphemer": "^1.4.0",
+ "ignore": "^5.2.0",
+ "imurmurhash": "^0.1.4",
+ "is-glob": "^4.0.0",
+ "is-path-inside": "^3.0.3",
+ "js-yaml": "^4.1.0",
+ "json-stable-stringify-without-jsonify": "^1.0.1",
+ "levn": "^0.4.1",
+ "lodash.merge": "^4.6.2",
+ "minimatch": "^3.1.2",
+ "natural-compare": "^1.4.0",
+ "optionator": "^0.9.3",
+ "strip-ansi": "^6.0.1",
+ "text-table": "^0.2.0"
+ },
+ "bin": {
+ "eslint": "bin/eslint.js"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://opencollective.com/eslint"
+ }
+ },
+ "node_modules/eslint-config-standard": {
+ "version": "17.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-standard/-/eslint-config-standard-17.1.0.tgz",
+ "integrity": "sha512-IwHwmaBNtDK4zDHQukFDW5u/aTb8+meQWZvNFWkiGmbWjD6bqyuSSBxxXKkCftCUzc1zwCH2m/baCNDLGmuO5Q==",
+ "dev": true,
+ "funding": [
+ {
+ "type": "github",
+ "url": "https://github.com/sponsors/feross"
+ },
+ {
+ "type": "patreon",
+ "url": "https://www.patreon.com/feross"
+ },
+ {
+ "type": "consulting",
+ "url": "https://feross.org/support"
+ }
+ ],
+ "engines": {
+ "node": ">=12.0.0"
+ },
+ "peerDependencies": {
+ "eslint": "^8.0.1",
+ "eslint-plugin-import": "^2.25.2",
+ "eslint-plugin-n": "^15.0.0 || ^16.0.0 ",
+ "eslint-plugin-promise": "^6.0.0"
+ }
+ },
+ "node_modules/eslint-import-resolver-node": {
+ "version": "0.3.9",
+ "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz",
+ "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==",
+ "dev": true,
+ "dependencies": {
+ "debug": "^3.2.7",
+ "is-core-module": "^2.13.0",
+ "resolve": "^1.22.4"
+ }
+ },
+ "node_modules/eslint-import-resolver-node/node_modules/debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "dependencies": {
+ "ms": "^2.1.1"
+ }
+ },
+ "node_modules/eslint-module-utils": {
+ "version": "2.8.0",
+ "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.0.tgz",
+ "integrity": "sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==",
+ "dev": true,
+ "dependencies": {
+ "debug": "^3.2.7"
+ },
+ "engines": {
+ "node": ">=4"
+ },
+ "peerDependenciesMeta": {
+ "eslint": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/eslint-module-utils/node_modules/debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "dependencies": {
+ "ms": "^2.1.1"
+ }
+ },
+ "node_modules/eslint-plugin-es": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-4.1.0.tgz",
+ "integrity": "sha512-GILhQTnjYE2WorX5Jyi5i4dz5ALWxBIdQECVQavL6s7cI76IZTDWleTHkxz/QT3kvcs2QlGHvKLYsSlPOlPXnQ==",
+ "dev": true,
+ "dependencies": {
+ "eslint-utils": "^2.0.0",
+ "regexpp": "^3.0.0"
+ },
+ "engines": {
+ "node": ">=8.10.0"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/mysticatea"
+ },
+ "peerDependencies": {
+ "eslint": ">=4.19.1"
+ }
+ },
+ "node_modules/eslint-plugin-es/node_modules/eslint-utils": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz",
+ "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==",
+ "dev": true,
+ "dependencies": {
+ "eslint-visitor-keys": "^1.1.0"
+ },
+ "engines": {
+ "node": ">=6"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/mysticatea"
+ }
+ },
+ "node_modules/eslint-plugin-es/node_modules/eslint-visitor-keys": {
+ "version": "1.3.0",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz",
+ "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/eslint-plugin-import": {
+ "version": "2.28.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.28.0.tgz",
+ "integrity": "sha512-B8s/n+ZluN7sxj9eUf7/pRFERX0r5bnFA2dCaLHy2ZeaQEAz0k+ZZkFWRFHJAqxfxQDx6KLv9LeIki7cFdwW+Q==",
+ "dev": true,
+ "dependencies": {
+ "array-includes": "^3.1.6",
+ "array.prototype.findlastindex": "^1.2.2",
+ "array.prototype.flat": "^1.3.1",
+ "array.prototype.flatmap": "^1.3.1",
+ "debug": "^3.2.7",
+ "doctrine": "^2.1.0",
+ "eslint-import-resolver-node": "^0.3.7",
+ "eslint-module-utils": "^2.8.0",
+ "has": "^1.0.3",
+ "is-core-module": "^2.12.1",
+ "is-glob": "^4.0.3",
+ "minimatch": "^3.1.2",
+ "object.fromentries": "^2.0.6",
+ "object.groupby": "^1.0.0",
+ "object.values": "^1.1.6",
+ "resolve": "^1.22.3",
+ "semver": "^6.3.1",
+ "tsconfig-paths": "^3.14.2"
+ },
+ "engines": {
+ "node": ">=4"
+ },
+ "peerDependencies": {
+ "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8"
+ }
+ },
+ "node_modules/eslint-plugin-import/node_modules/debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "dependencies": {
+ "ms": "^2.1.1"
+ }
+ },
+ "node_modules/eslint-plugin-import/node_modules/doctrine": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz",
+ "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==",
+ "dev": true,
+ "dependencies": {
+ "esutils": "^2.0.2"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/eslint-plugin-n": {
+ "version": "15.7.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-n/-/eslint-plugin-n-15.7.0.tgz",
+ "integrity": "sha512-jDex9s7D/Qial8AGVIHq4W7NswpUD5DPDL2RH8Lzd9EloWUuvUkHfv4FRLMipH5q2UtyurorBkPeNi1wVWNh3Q==",
+ "dev": true,
+ "dependencies": {
+ "builtins": "^5.0.1",
+ "eslint-plugin-es": "^4.1.0",
+ "eslint-utils": "^3.0.0",
+ "ignore": "^5.1.1",
+ "is-core-module": "^2.11.0",
+ "minimatch": "^3.1.2",
+ "resolve": "^1.22.1",
+ "semver": "^7.3.8"
+ },
+ "engines": {
+ "node": ">=12.22.0"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/mysticatea"
+ },
+ "peerDependencies": {
+ "eslint": ">=7.0.0"
+ }
+ },
+ "node_modules/eslint-plugin-n/node_modules/semver": {
+ "version": "7.5.4",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz",
+ "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==",
+ "dev": true,
+ "dependencies": {
+ "lru-cache": "^6.0.0"
+ },
+ "bin": {
+ "semver": "bin/semver.js"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/eslint-plugin-promise": {
+ "version": "6.1.1",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-6.1.1.tgz",
+ "integrity": "sha512-tjqWDwVZQo7UIPMeDReOpUgHCmCiH+ePnVT+5zVapL0uuHnegBUs2smM13CzOs2Xb5+MHMRFTs9v24yjba4Oig==",
+ "dev": true,
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "peerDependencies": {
+ "eslint": "^7.0.0 || ^8.0.0"
+ }
+ },
+ "node_modules/eslint-scope": {
+ "version": "7.2.2",
+ "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz",
+ "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==",
+ "dev": true,
+ "dependencies": {
+ "esrecurse": "^4.3.0",
+ "estraverse": "^5.2.0"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://opencollective.com/eslint"
+ }
+ },
+ "node_modules/eslint-utils": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz",
+ "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==",
+ "dev": true,
+ "dependencies": {
+ "eslint-visitor-keys": "^2.0.0"
+ },
+ "engines": {
+ "node": "^10.0.0 || ^12.0.0 || >= 14.0.0"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/mysticatea"
+ },
+ "peerDependencies": {
+ "eslint": ">=5"
+ }
+ },
+ "node_modules/eslint-utils/node_modules/eslint-visitor-keys": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz",
+ "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==",
+ "dev": true,
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/eslint-visitor-keys": {
+ "version": "3.4.3",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz",
+ "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==",
+ "dev": true,
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://opencollective.com/eslint"
+ }
+ },
+ "node_modules/espree": {
+ "version": "9.6.1",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz",
+ "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==",
+ "dev": true,
+ "dependencies": {
+ "acorn": "^8.9.0",
+ "acorn-jsx": "^5.3.2",
+ "eslint-visitor-keys": "^3.4.1"
+ },
+ "engines": {
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://opencollective.com/eslint"
+ }
+ },
+ "node_modules/esquery": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz",
+ "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==",
+ "dev": true,
+ "dependencies": {
+ "estraverse": "^5.1.0"
+ },
+ "engines": {
+ "node": ">=0.10"
+ }
+ },
+ "node_modules/esrecurse": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz",
+ "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==",
+ "dev": true,
+ "dependencies": {
+ "estraverse": "^5.2.0"
+ },
+ "engines": {
+ "node": ">=4.0"
+ }
+ },
+ "node_modules/estraverse": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
+ "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "dev": true,
+ "engines": {
+ "node": ">=4.0"
+ }
+ },
+ "node_modules/esutils": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
+ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true,
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/fast-deep-equal": {
+ "version": "3.1.3",
+ "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
+ "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
+ "dev": true
+ },
+ "node_modules/fast-json-stable-stringify": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz",
+ "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==",
+ "dev": true
+ },
+ "node_modules/fast-levenshtein": {
+ "version": "2.0.6",
+ "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
+ "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==",
+ "dev": true
+ },
+ "node_modules/fastq": {
+ "version": "1.15.0",
+ "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz",
+ "integrity": "sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==",
+ "dev": true,
+ "dependencies": {
+ "reusify": "^1.0.4"
+ }
+ },
+ "node_modules/file-entry-cache": {
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz",
+ "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==",
+ "dev": true,
+ "dependencies": {
+ "flat-cache": "^3.0.4"
+ },
+ "engines": {
+ "node": "^10.12.0 || >=12.0.0"
+ }
+ },
+ "node_modules/find-up": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz",
+ "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==",
+ "dev": true,
+ "dependencies": {
+ "locate-path": "^6.0.0",
+ "path-exists": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/flat-cache": {
+ "version": "3.0.4",
+ "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz",
+ "integrity": "sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==",
+ "dev": true,
+ "dependencies": {
+ "flatted": "^3.1.0",
+ "rimraf": "^3.0.2"
+ },
+ "engines": {
+ "node": "^10.12.0 || >=12.0.0"
+ }
+ },
+ "node_modules/flatted": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz",
+ "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==",
+ "dev": true
+ },
+ "node_modules/for-each": {
+ "version": "0.3.3",
+ "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz",
+ "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==",
+ "dev": true,
+ "dependencies": {
+ "is-callable": "^1.1.3"
+ }
+ },
+ "node_modules/fs.realpath": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
+ "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==",
+ "dev": true
+ },
+ "node_modules/function-bind": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
+ "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
+ "dev": true
+ },
+ "node_modules/function.prototype.name": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz",
+ "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.19.0",
+ "functions-have-names": "^1.2.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/functions-have-names": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz",
+ "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==",
+ "dev": true,
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/get-intrinsic": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz",
+ "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==",
+ "dev": true,
+ "dependencies": {
+ "function-bind": "^1.1.1",
+ "has": "^1.0.3",
+ "has-proto": "^1.0.1",
+ "has-symbols": "^1.0.3"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/get-symbol-description": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz",
+ "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.1.1"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/glob": {
+ "version": "7.2.3",
+ "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz",
+ "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==",
+ "dev": true,
+ "dependencies": {
+ "fs.realpath": "^1.0.0",
+ "inflight": "^1.0.4",
+ "inherits": "2",
+ "minimatch": "^3.1.1",
+ "once": "^1.3.0",
+ "path-is-absolute": "^1.0.0"
+ },
+ "engines": {
+ "node": "*"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/isaacs"
+ }
+ },
+ "node_modules/glob-parent": {
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
+ "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
+ "dev": true,
+ "dependencies": {
+ "is-glob": "^4.0.3"
+ },
+ "engines": {
+ "node": ">=10.13.0"
+ }
+ },
+ "node_modules/globals": {
+ "version": "13.21.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.21.0.tgz",
+ "integrity": "sha512-ybyme3s4yy/t/3s35bewwXKOf7cvzfreG2lH0lZl0JB7I4GxRP2ghxOK/Nb9EkRXdbBXZLfq/p/0W2JUONB/Gg==",
+ "dev": true,
+ "dependencies": {
+ "type-fest": "^0.20.2"
+ },
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/globalthis": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz",
+ "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==",
+ "dev": true,
+ "dependencies": {
+ "define-properties": "^1.1.3"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/gopd": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz",
+ "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==",
+ "dev": true,
+ "dependencies": {
+ "get-intrinsic": "^1.1.3"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/graphemer": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz",
+ "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==",
+ "dev": true
+ },
+ "node_modules/has": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
+ "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
+ "dev": true,
+ "dependencies": {
+ "function-bind": "^1.1.1"
+ },
+ "engines": {
+ "node": ">= 0.4.0"
+ }
+ },
+ "node_modules/has-bigints": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz",
+ "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==",
+ "dev": true,
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/has-flag": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
+ "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/has-property-descriptors": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz",
+ "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==",
+ "dev": true,
+ "dependencies": {
+ "get-intrinsic": "^1.1.1"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/has-proto": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz",
+ "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/has-symbols": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz",
+ "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/has-tostringtag": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz",
+ "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==",
+ "dev": true,
+ "dependencies": {
+ "has-symbols": "^1.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/ignore": {
+ "version": "5.2.4",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz",
+ "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==",
+ "dev": true,
+ "engines": {
+ "node": ">= 4"
+ }
+ },
+ "node_modules/import-fresh": {
+ "version": "3.3.0",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz",
+ "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==",
+ "dev": true,
+ "dependencies": {
+ "parent-module": "^1.0.0",
+ "resolve-from": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=6"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/imurmurhash": {
+ "version": "0.1.4",
+ "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz",
+ "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==",
+ "dev": true,
+ "engines": {
+ "node": ">=0.8.19"
+ }
+ },
+ "node_modules/inflight": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
+ "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==",
+ "dev": true,
+ "dependencies": {
+ "once": "^1.3.0",
+ "wrappy": "1"
+ }
+ },
+ "node_modules/inherits": {
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",
+ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==",
+ "dev": true
+ },
+ "node_modules/internal-slot": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz",
+ "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==",
+ "dev": true,
+ "dependencies": {
+ "get-intrinsic": "^1.2.0",
+ "has": "^1.0.3",
+ "side-channel": "^1.0.4"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/is-array-buffer": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz",
+ "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.0",
+ "is-typed-array": "^1.1.10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-bigint": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz",
+ "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==",
+ "dev": true,
+ "dependencies": {
+ "has-bigints": "^1.0.1"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-boolean-object": {
+ "version": "1.1.2",
+ "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz",
+ "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-callable": {
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz",
+ "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-core-module": {
+ "version": "2.13.0",
+ "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz",
+ "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==",
+ "dev": true,
+ "dependencies": {
+ "has": "^1.0.3"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-date-object": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz",
+ "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==",
+ "dev": true,
+ "dependencies": {
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-extglob": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
+ "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/is-glob": {
+ "version": "4.0.3",
+ "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
+ "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
+ "dev": true,
+ "dependencies": {
+ "is-extglob": "^2.1.1"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/is-negative-zero": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz",
+ "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-number-object": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz",
+ "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==",
+ "dev": true,
+ "dependencies": {
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-path-inside": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz",
+ "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/is-regex": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz",
+ "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-shared-array-buffer": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz",
+ "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-string": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz",
+ "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==",
+ "dev": true,
+ "dependencies": {
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-symbol": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz",
+ "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==",
+ "dev": true,
+ "dependencies": {
+ "has-symbols": "^1.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-typed-array": {
+ "version": "1.1.12",
+ "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz",
+ "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==",
+ "dev": true,
+ "dependencies": {
+ "which-typed-array": "^1.1.11"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/is-weakref": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz",
+ "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/isarray": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz",
+ "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==",
+ "dev": true
+ },
+ "node_modules/isexe": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
+ "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
+ "dev": true
+ },
+ "node_modules/js-yaml": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
+ "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
+ "dev": true,
+ "dependencies": {
+ "argparse": "^2.0.1"
+ },
+ "bin": {
+ "js-yaml": "bin/js-yaml.js"
+ }
+ },
+ "node_modules/json-schema-traverse": {
+ "version": "0.4.1",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
+ "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==",
+ "dev": true
+ },
+ "node_modules/json-stable-stringify-without-jsonify": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz",
+ "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==",
+ "dev": true
+ },
+ "node_modules/json5": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz",
+ "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==",
+ "dev": true,
+ "dependencies": {
+ "minimist": "^1.2.0"
+ },
+ "bin": {
+ "json5": "lib/cli.js"
+ }
+ },
+ "node_modules/levn": {
+ "version": "0.4.1",
+ "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz",
+ "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==",
+ "dev": true,
+ "dependencies": {
+ "prelude-ls": "^1.2.1",
+ "type-check": "~0.4.0"
+ },
+ "engines": {
+ "node": ">= 0.8.0"
+ }
+ },
+ "node_modules/locate-path": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz",
+ "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==",
+ "dev": true,
+ "dependencies": {
+ "p-locate": "^5.0.0"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/lodash.merge": {
+ "version": "4.6.2",
+ "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz",
+ "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==",
+ "dev": true
+ },
+ "node_modules/lru-cache": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz",
+ "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==",
+ "dev": true,
+ "dependencies": {
+ "yallist": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/minimatch": {
+ "version": "3.1.2",
+ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",
+ "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==",
+ "dev": true,
+ "dependencies": {
+ "brace-expansion": "^1.1.7"
+ },
+ "engines": {
+ "node": "*"
+ }
+ },
+ "node_modules/minimist": {
+ "version": "1.2.8",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz",
+ "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==",
+ "dev": true,
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/ms": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
+ "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
+ "dev": true
+ },
+ "node_modules/natural-compare": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz",
+ "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==",
+ "dev": true
+ },
+ "node_modules/object-inspect": {
+ "version": "1.12.3",
+ "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz",
+ "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==",
+ "dev": true,
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/object-keys": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
+ "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/object.assign": {
+ "version": "4.1.4",
+ "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz",
+ "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "has-symbols": "^1.0.3",
+ "object-keys": "^1.1.1"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/object.fromentries": {
+ "version": "2.0.6",
+ "resolved": "https://registry.npmjs.org/object.fromentries/-/object.fromentries-2.0.6.tgz",
+ "integrity": "sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/object.groupby": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/object.groupby/-/object.groupby-1.0.0.tgz",
+ "integrity": "sha512-70MWG6NfRH9GnbZOikuhPPYzpUpof9iW2J9E4dW7FXTqPNb6rllE6u39SKwwiNh8lCwX3DDb5OgcKGiEBrTTyw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "es-abstract": "^1.21.2",
+ "get-intrinsic": "^1.2.1"
+ }
+ },
+ "node_modules/object.values": {
+ "version": "1.1.6",
+ "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.6.tgz",
+ "integrity": "sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/once": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
+ "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",
+ "dev": true,
+ "dependencies": {
+ "wrappy": "1"
+ }
+ },
+ "node_modules/optionator": {
+ "version": "0.9.3",
+ "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz",
+ "integrity": "sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==",
+ "dev": true,
+ "dependencies": {
+ "@aashutoshrathi/word-wrap": "^1.2.3",
+ "deep-is": "^0.1.3",
+ "fast-levenshtein": "^2.0.6",
+ "levn": "^0.4.1",
+ "prelude-ls": "^1.2.1",
+ "type-check": "^0.4.0"
+ },
+ "engines": {
+ "node": ">= 0.8.0"
+ }
+ },
+ "node_modules/p-limit": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz",
+ "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==",
+ "dev": true,
+ "dependencies": {
+ "yocto-queue": "^0.1.0"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/p-locate": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz",
+ "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==",
+ "dev": true,
+ "dependencies": {
+ "p-limit": "^3.0.2"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/parent-module": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
+ "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==",
+ "dev": true,
+ "dependencies": {
+ "callsites": "^3.0.0"
+ },
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/path-exists": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
+ "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/path-is-absolute": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
+ "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==",
+ "dev": true,
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/path-key": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
+ "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/path-parse": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
+ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
+ "dev": true
+ },
+ "node_modules/prelude-ls": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
+ "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.8.0"
+ }
+ },
+ "node_modules/punycode": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.0.tgz",
+ "integrity": "sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==",
+ "dev": true,
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/queue-microtask": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
+ "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
+ "dev": true,
+ "funding": [
+ {
+ "type": "github",
+ "url": "https://github.com/sponsors/feross"
+ },
+ {
+ "type": "patreon",
+ "url": "https://www.patreon.com/feross"
+ },
+ {
+ "type": "consulting",
+ "url": "https://feross.org/support"
+ }
+ ]
+ },
+ "node_modules/regexp.prototype.flags": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz",
+ "integrity": "sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "functions-have-names": "^1.2.3"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/regexpp": {
+ "version": "3.2.0",
+ "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz",
+ "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/mysticatea"
+ }
+ },
+ "node_modules/resolve": {
+ "version": "1.22.4",
+ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.4.tgz",
+ "integrity": "sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==",
+ "dev": true,
+ "dependencies": {
+ "is-core-module": "^2.13.0",
+ "path-parse": "^1.0.7",
+ "supports-preserve-symlinks-flag": "^1.0.0"
+ },
+ "bin": {
+ "resolve": "bin/resolve"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/resolve-from": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
+ "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==",
+ "dev": true,
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/reusify": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
+ "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==",
+ "dev": true,
+ "engines": {
+ "iojs": ">=1.0.0",
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/rimraf": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
+ "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==",
+ "dev": true,
+ "dependencies": {
+ "glob": "^7.1.3"
+ },
+ "bin": {
+ "rimraf": "bin.js"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/isaacs"
+ }
+ },
+ "node_modules/run-parallel": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
+ "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
+ "dev": true,
+ "funding": [
+ {
+ "type": "github",
+ "url": "https://github.com/sponsors/feross"
+ },
+ {
+ "type": "patreon",
+ "url": "https://www.patreon.com/feross"
+ },
+ {
+ "type": "consulting",
+ "url": "https://feross.org/support"
+ }
+ ],
+ "dependencies": {
+ "queue-microtask": "^1.2.2"
+ }
+ },
+ "node_modules/safe-array-concat": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz",
+ "integrity": "sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.0",
+ "has-symbols": "^1.0.3",
+ "isarray": "^2.0.5"
+ },
+ "engines": {
+ "node": ">=0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/safe-regex-test": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz",
+ "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.1.3",
+ "is-regex": "^1.1.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/semver": {
+ "version": "6.3.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz",
+ "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==",
+ "dev": true,
+ "bin": {
+ "semver": "bin/semver.js"
+ }
+ },
+ "node_modules/shebang-command": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
+ "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
+ "dev": true,
+ "dependencies": {
+ "shebang-regex": "^3.0.0"
+ },
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/shebang-regex": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
+ "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/side-channel": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz",
+ "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.0",
+ "get-intrinsic": "^1.0.2",
+ "object-inspect": "^1.9.0"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/string.prototype.trim": {
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz",
+ "integrity": "sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/string.prototype.trimend": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz",
+ "integrity": "sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/string.prototype.trimstart": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz",
+ "integrity": "sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/strip-ansi": {
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
+ "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
+ "dev": true,
+ "dependencies": {
+ "ansi-regex": "^5.0.1"
+ },
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/strip-bom": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
+ "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==",
+ "dev": true,
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/strip-json-comments": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz",
+ "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==",
+ "dev": true,
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/supports-color": {
+ "version": "7.2.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
+ "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
+ "dev": true,
+ "dependencies": {
+ "has-flag": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/supports-preserve-symlinks-flag": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
+ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
+ "dev": true,
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/text-table": {
+ "version": "0.2.0",
+ "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz",
+ "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==",
+ "dev": true
+ },
+ "node_modules/tsconfig-paths": {
+ "version": "3.14.2",
+ "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.2.tgz",
+ "integrity": "sha512-o/9iXgCYc5L/JxCHPe3Hvh8Q/2xm5Z+p18PESBU6Ff33695QnCHBEjcytY2q19ua7Mbl/DavtBOLq+oG0RCL+g==",
+ "dev": true,
+ "dependencies": {
+ "@types/json5": "^0.0.29",
+ "json5": "^1.0.2",
+ "minimist": "^1.2.6",
+ "strip-bom": "^3.0.0"
+ }
+ },
+ "node_modules/type-check": {
+ "version": "0.4.0",
+ "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz",
+ "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==",
+ "dev": true,
+ "dependencies": {
+ "prelude-ls": "^1.2.1"
+ },
+ "engines": {
+ "node": ">= 0.8.0"
+ }
+ },
+ "node_modules/type-fest": {
+ "version": "0.20.2",
+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz",
+ "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==",
+ "dev": true,
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/typed-array-buffer": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz",
+ "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.1",
+ "is-typed-array": "^1.1.10"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/typed-array-byte-length": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz",
+ "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "has-proto": "^1.0.1",
+ "is-typed-array": "^1.1.10"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/typed-array-byte-offset": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz",
+ "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==",
+ "dev": true,
+ "dependencies": {
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "has-proto": "^1.0.1",
+ "is-typed-array": "^1.1.10"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/typed-array-length": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz",
+ "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "is-typed-array": "^1.1.9"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/unbox-primitive": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz",
+ "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "has-bigints": "^1.0.2",
+ "has-symbols": "^1.0.3",
+ "which-boxed-primitive": "^1.0.2"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/uri-js": {
+ "version": "4.4.1",
+ "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
+ "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
+ "dev": true,
+ "dependencies": {
+ "punycode": "^2.1.0"
+ }
+ },
+ "node_modules/which": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
+ "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
+ "dev": true,
+ "dependencies": {
+ "isexe": "^2.0.0"
+ },
+ "bin": {
+ "node-which": "bin/node-which"
+ },
+ "engines": {
+ "node": ">= 8"
+ }
+ },
+ "node_modules/which-boxed-primitive": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz",
+ "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==",
+ "dev": true,
+ "dependencies": {
+ "is-bigint": "^1.0.1",
+ "is-boolean-object": "^1.1.0",
+ "is-number-object": "^1.0.4",
+ "is-string": "^1.0.5",
+ "is-symbol": "^1.0.3"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/which-typed-array": {
+ "version": "1.1.11",
+ "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz",
+ "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==",
+ "dev": true,
+ "dependencies": {
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "gopd": "^1.0.1",
+ "has-tostringtag": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/wrappy": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
+ "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==",
+ "dev": true
+ },
+ "node_modules/yallist": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
+ "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
+ "dev": true
+ },
+ "node_modules/yocto-queue": {
+ "version": "0.1.0",
+ "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz",
+ "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==",
+ "dev": true,
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ }
+ },
+ "dependencies": {
+ "@aashutoshrathi/word-wrap": {
+ "version": "1.2.6",
+ "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz",
+ "integrity": "sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==",
+ "dev": true
+ },
+ "@cordova/eslint-config": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/@cordova/eslint-config/-/eslint-config-5.0.0.tgz",
+ "integrity": "sha512-tBSV8LbT6RjWsO2lSp45Y+zU7hfXhGMGhfYTZjDrjzli87WOgE6IAS37k6F45JNoGq1XlCJEVkCWwz4KCF8Scw==",
+ "dev": true,
+ "requires": {
+ "eslint": "^8.31.0",
+ "eslint-config-standard": "^17.0.0",
+ "eslint-plugin-import": "^2.27.2",
+ "eslint-plugin-n": "^15.6.1",
+ "eslint-plugin-promise": "^6.1.1"
+ }
+ },
+ "@eslint-community/eslint-utils": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz",
+ "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^3.3.0"
+ }
+ },
+ "@eslint-community/regexpp": {
+ "version": "4.6.2",
+ "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.6.2.tgz",
+ "integrity": "sha512-pPTNuaAG3QMH+buKyBIGJs3g/S5y0caxw0ygM3YyE6yJFySwiGGSzA+mM3KJ8QQvzeLh3blwgSonkFjgQdxzMw==",
+ "dev": true
+ },
+ "@eslint/eslintrc": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.2.tgz",
+ "integrity": "sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g==",
+ "dev": true,
+ "requires": {
+ "ajv": "^6.12.4",
+ "debug": "^4.3.2",
+ "espree": "^9.6.0",
+ "globals": "^13.19.0",
+ "ignore": "^5.2.0",
+ "import-fresh": "^3.2.1",
+ "js-yaml": "^4.1.0",
+ "minimatch": "^3.1.2",
+ "strip-json-comments": "^3.1.1"
+ }
+ },
+ "@eslint/js": {
+ "version": "8.47.0",
+ "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.47.0.tgz",
+ "integrity": "sha512-P6omY1zv5MItm93kLM8s2vr1HICJH8v0dvddDhysbIuZ+vcjOHg5Zbkf1mTkcmi2JA9oBG2anOkRnW8WJTS8Og==",
+ "dev": true
+ },
+ "@humanwhocodes/config-array": {
+ "version": "0.11.10",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.10.tgz",
+ "integrity": "sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==",
+ "dev": true,
+ "requires": {
+ "@humanwhocodes/object-schema": "^1.2.1",
+ "debug": "^4.1.1",
+ "minimatch": "^3.0.5"
+ }
+ },
+ "@humanwhocodes/module-importer": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz",
+ "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==",
+ "dev": true
+ },
+ "@humanwhocodes/object-schema": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz",
+ "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==",
+ "dev": true
+ },
+ "@nodelib/fs.scandir": {
+ "version": "2.1.5",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
+ "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
+ "dev": true,
+ "requires": {
+ "@nodelib/fs.stat": "2.0.5",
+ "run-parallel": "^1.1.9"
+ }
+ },
+ "@nodelib/fs.stat": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
+ "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
+ "dev": true
+ },
+ "@nodelib/fs.walk": {
+ "version": "1.2.8",
+ "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
+ "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
+ "dev": true,
+ "requires": {
+ "@nodelib/fs.scandir": "2.1.5",
+ "fastq": "^1.6.0"
+ }
+ },
+ "@types/json5": {
+ "version": "0.0.29",
+ "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz",
+ "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==",
+ "dev": true
+ },
+ "acorn": {
+ "version": "8.10.0",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
+ "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "dev": true
+ },
+ "acorn-jsx": {
+ "version": "5.3.2",
+ "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz",
+ "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==",
+ "dev": true,
+ "requires": {}
+ },
+ "ajv": {
+ "version": "6.12.6",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz",
+ "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "fast-json-stable-stringify": "^2.0.0",
+ "json-schema-traverse": "^0.4.1",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "ansi-regex": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
+ "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
+ "dev": true
+ },
+ "ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "dev": true,
+ "requires": {
+ "color-convert": "^2.0.1"
+ }
+ },
+ "argparse": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
+ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "dev": true
+ },
+ "array-buffer-byte-length": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz",
+ "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "is-array-buffer": "^3.0.1"
+ }
+ },
+ "array-includes": {
+ "version": "3.1.6",
+ "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.6.tgz",
+ "integrity": "sha512-sgTbLvL6cNnw24FnbaDyjmvddQ2ML8arZsgaJhoABMoplz/4QRhtrYS+alr1BUM1Bwp6dhx8vVCBSLG+StwOFw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "get-intrinsic": "^1.1.3",
+ "is-string": "^1.0.7"
+ }
+ },
+ "array.prototype.findlastindex": {
+ "version": "1.2.2",
+ "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.2.tgz",
+ "integrity": "sha512-tb5thFFlUcp7NdNF6/MpDk/1r/4awWG1FIz3YqDf+/zJSTezBb+/5WViH41obXULHVpDzoiCLpJ/ZO9YbJMsdw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0",
+ "get-intrinsic": "^1.1.3"
+ }
+ },
+ "array.prototype.flat": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.1.tgz",
+ "integrity": "sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0"
+ }
+ },
+ "array.prototype.flatmap": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.1.tgz",
+ "integrity": "sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4",
+ "es-shim-unscopables": "^1.0.0"
+ }
+ },
+ "arraybuffer.prototype.slice": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.1.tgz",
+ "integrity": "sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw==",
+ "dev": true,
+ "requires": {
+ "array-buffer-byte-length": "^1.0.0",
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "get-intrinsic": "^1.2.1",
+ "is-array-buffer": "^3.0.2",
+ "is-shared-array-buffer": "^1.0.2"
+ }
+ },
+ "available-typed-arrays": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz",
+ "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==",
+ "dev": true
+ },
+ "balanced-match": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
+ "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==",
+ "dev": true
+ },
+ "brace-expansion": {
+ "version": "1.1.11",
+ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
+ "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
+ "dev": true,
+ "requires": {
+ "balanced-match": "^1.0.0",
+ "concat-map": "0.0.1"
+ }
+ },
+ "builtins": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/builtins/-/builtins-5.0.1.tgz",
+ "integrity": "sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==",
+ "dev": true,
+ "requires": {
+ "semver": "^7.0.0"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "7.5.4",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz",
+ "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==",
+ "dev": true,
+ "requires": {
+ "lru-cache": "^6.0.0"
+ }
+ }
+ }
+ },
+ "call-bind": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz",
+ "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==",
+ "dev": true,
+ "requires": {
+ "function-bind": "^1.1.1",
+ "get-intrinsic": "^1.0.2"
+ }
+ },
+ "callsites": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
+ "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
+ "dev": true
+ },
+ "chalk": {
+ "version": "4.1.2",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
+ "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
+ "dev": true,
+ "requires": {
+ "ansi-styles": "^4.1.0",
+ "supports-color": "^7.1.0"
+ }
+ },
+ "color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "dev": true,
+ "requires": {
+ "color-name": "~1.1.4"
+ }
+ },
+ "color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
+ "dev": true
+ },
+ "concat-map": {
+ "version": "0.0.1",
+ "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
+ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==",
+ "dev": true
+ },
+ "cross-spawn": {
+ "version": "7.0.3",
+ "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
+ "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==",
+ "dev": true,
+ "requires": {
+ "path-key": "^3.1.0",
+ "shebang-command": "^2.0.0",
+ "which": "^2.0.1"
+ }
+ },
+ "debug": {
+ "version": "4.3.4",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz",
+ "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
+ "dev": true,
+ "requires": {
+ "ms": "2.1.2"
+ }
+ },
+ "deep-is": {
+ "version": "0.1.4",
+ "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz",
+ "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==",
+ "dev": true
+ },
+ "define-properties": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz",
+ "integrity": "sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA==",
+ "dev": true,
+ "requires": {
+ "has-property-descriptors": "^1.0.0",
+ "object-keys": "^1.1.1"
+ }
+ },
+ "doctrine": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz",
+ "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==",
+ "dev": true,
+ "requires": {
+ "esutils": "^2.0.2"
+ }
+ },
+ "es-abstract": {
+ "version": "1.22.1",
+ "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.1.tgz",
+ "integrity": "sha512-ioRRcXMO6OFyRpyzV3kE1IIBd4WG5/kltnzdxSCqoP8CMGs/Li+M1uF5o7lOkZVFjDs+NLesthnF66Pg/0q0Lw==",
+ "dev": true,
+ "requires": {
+ "array-buffer-byte-length": "^1.0.0",
+ "arraybuffer.prototype.slice": "^1.0.1",
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "es-set-tostringtag": "^2.0.1",
+ "es-to-primitive": "^1.2.1",
+ "function.prototype.name": "^1.1.5",
+ "get-intrinsic": "^1.2.1",
+ "get-symbol-description": "^1.0.0",
+ "globalthis": "^1.0.3",
+ "gopd": "^1.0.1",
+ "has": "^1.0.3",
+ "has-property-descriptors": "^1.0.0",
+ "has-proto": "^1.0.1",
+ "has-symbols": "^1.0.3",
+ "internal-slot": "^1.0.5",
+ "is-array-buffer": "^3.0.2",
+ "is-callable": "^1.2.7",
+ "is-negative-zero": "^2.0.2",
+ "is-regex": "^1.1.4",
+ "is-shared-array-buffer": "^1.0.2",
+ "is-string": "^1.0.7",
+ "is-typed-array": "^1.1.10",
+ "is-weakref": "^1.0.2",
+ "object-inspect": "^1.12.3",
+ "object-keys": "^1.1.1",
+ "object.assign": "^4.1.4",
+ "regexp.prototype.flags": "^1.5.0",
+ "safe-array-concat": "^1.0.0",
+ "safe-regex-test": "^1.0.0",
+ "string.prototype.trim": "^1.2.7",
+ "string.prototype.trimend": "^1.0.6",
+ "string.prototype.trimstart": "^1.0.6",
+ "typed-array-buffer": "^1.0.0",
+ "typed-array-byte-length": "^1.0.0",
+ "typed-array-byte-offset": "^1.0.0",
+ "typed-array-length": "^1.0.4",
+ "unbox-primitive": "^1.0.2",
+ "which-typed-array": "^1.1.10"
+ }
+ },
+ "es-set-tostringtag": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz",
+ "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==",
+ "dev": true,
+ "requires": {
+ "get-intrinsic": "^1.1.3",
+ "has": "^1.0.3",
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "es-shim-unscopables": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.0.tgz",
+ "integrity": "sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==",
+ "dev": true,
+ "requires": {
+ "has": "^1.0.3"
+ }
+ },
+ "es-to-primitive": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz",
+ "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==",
+ "dev": true,
+ "requires": {
+ "is-callable": "^1.1.4",
+ "is-date-object": "^1.0.1",
+ "is-symbol": "^1.0.2"
+ }
+ },
+ "escape-string-regexp": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz",
+ "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",
+ "dev": true
+ },
+ "eslint": {
+ "version": "8.47.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.47.0.tgz",
+ "integrity": "sha512-spUQWrdPt+pRVP1TTJLmfRNJJHHZryFmptzcafwSvHsceV81djHOdnEeDmkdotZyLNjDhrOasNK8nikkoG1O8Q==",
+ "dev": true,
+ "requires": {
+ "@eslint-community/eslint-utils": "^4.2.0",
+ "@eslint-community/regexpp": "^4.6.1",
+ "@eslint/eslintrc": "^2.1.2",
+ "@eslint/js": "^8.47.0",
+ "@humanwhocodes/config-array": "^0.11.10",
+ "@humanwhocodes/module-importer": "^1.0.1",
+ "@nodelib/fs.walk": "^1.2.8",
+ "ajv": "^6.12.4",
+ "chalk": "^4.0.0",
+ "cross-spawn": "^7.0.2",
+ "debug": "^4.3.2",
+ "doctrine": "^3.0.0",
+ "escape-string-regexp": "^4.0.0",
+ "eslint-scope": "^7.2.2",
+ "eslint-visitor-keys": "^3.4.3",
+ "espree": "^9.6.1",
+ "esquery": "^1.4.2",
+ "esutils": "^2.0.2",
+ "fast-deep-equal": "^3.1.3",
+ "file-entry-cache": "^6.0.1",
+ "find-up": "^5.0.0",
+ "glob-parent": "^6.0.2",
+ "globals": "^13.19.0",
+ "graphemer": "^1.4.0",
+ "ignore": "^5.2.0",
+ "imurmurhash": "^0.1.4",
+ "is-glob": "^4.0.0",
+ "is-path-inside": "^3.0.3",
+ "js-yaml": "^4.1.0",
+ "json-stable-stringify-without-jsonify": "^1.0.1",
+ "levn": "^0.4.1",
+ "lodash.merge": "^4.6.2",
+ "minimatch": "^3.1.2",
+ "natural-compare": "^1.4.0",
+ "optionator": "^0.9.3",
+ "strip-ansi": "^6.0.1",
+ "text-table": "^0.2.0"
+ }
+ },
+ "eslint-config-standard": {
+ "version": "17.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-standard/-/eslint-config-standard-17.1.0.tgz",
+ "integrity": "sha512-IwHwmaBNtDK4zDHQukFDW5u/aTb8+meQWZvNFWkiGmbWjD6bqyuSSBxxXKkCftCUzc1zwCH2m/baCNDLGmuO5Q==",
+ "dev": true,
+ "requires": {}
+ },
+ "eslint-import-resolver-node": {
+ "version": "0.3.9",
+ "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz",
+ "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==",
+ "dev": true,
+ "requires": {
+ "debug": "^3.2.7",
+ "is-core-module": "^2.13.0",
+ "resolve": "^1.22.4"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "requires": {
+ "ms": "^2.1.1"
+ }
+ }
+ }
+ },
+ "eslint-module-utils": {
+ "version": "2.8.0",
+ "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.0.tgz",
+ "integrity": "sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==",
+ "dev": true,
+ "requires": {
+ "debug": "^3.2.7"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "requires": {
+ "ms": "^2.1.1"
+ }
+ }
+ }
+ },
+ "eslint-plugin-es": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-4.1.0.tgz",
+ "integrity": "sha512-GILhQTnjYE2WorX5Jyi5i4dz5ALWxBIdQECVQavL6s7cI76IZTDWleTHkxz/QT3kvcs2QlGHvKLYsSlPOlPXnQ==",
+ "dev": true,
+ "requires": {
+ "eslint-utils": "^2.0.0",
+ "regexpp": "^3.0.0"
+ },
+ "dependencies": {
+ "eslint-utils": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz",
+ "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^1.1.0"
+ }
+ },
+ "eslint-visitor-keys": {
+ "version": "1.3.0",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz",
+ "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==",
+ "dev": true
+ }
+ }
+ },
+ "eslint-plugin-import": {
+ "version": "2.28.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.28.0.tgz",
+ "integrity": "sha512-B8s/n+ZluN7sxj9eUf7/pRFERX0r5bnFA2dCaLHy2ZeaQEAz0k+ZZkFWRFHJAqxfxQDx6KLv9LeIki7cFdwW+Q==",
+ "dev": true,
+ "requires": {
+ "array-includes": "^3.1.6",
+ "array.prototype.findlastindex": "^1.2.2",
+ "array.prototype.flat": "^1.3.1",
+ "array.prototype.flatmap": "^1.3.1",
+ "debug": "^3.2.7",
+ "doctrine": "^2.1.0",
+ "eslint-import-resolver-node": "^0.3.7",
+ "eslint-module-utils": "^2.8.0",
+ "has": "^1.0.3",
+ "is-core-module": "^2.12.1",
+ "is-glob": "^4.0.3",
+ "minimatch": "^3.1.2",
+ "object.fromentries": "^2.0.6",
+ "object.groupby": "^1.0.0",
+ "object.values": "^1.1.6",
+ "resolve": "^1.22.3",
+ "semver": "^6.3.1",
+ "tsconfig-paths": "^3.14.2"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
+ "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
+ "dev": true,
+ "requires": {
+ "ms": "^2.1.1"
+ }
+ },
+ "doctrine": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz",
+ "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==",
+ "dev": true,
+ "requires": {
+ "esutils": "^2.0.2"
+ }
+ }
+ }
+ },
+ "eslint-plugin-n": {
+ "version": "15.7.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-n/-/eslint-plugin-n-15.7.0.tgz",
+ "integrity": "sha512-jDex9s7D/Qial8AGVIHq4W7NswpUD5DPDL2RH8Lzd9EloWUuvUkHfv4FRLMipH5q2UtyurorBkPeNi1wVWNh3Q==",
+ "dev": true,
+ "requires": {
+ "builtins": "^5.0.1",
+ "eslint-plugin-es": "^4.1.0",
+ "eslint-utils": "^3.0.0",
+ "ignore": "^5.1.1",
+ "is-core-module": "^2.11.0",
+ "minimatch": "^3.1.2",
+ "resolve": "^1.22.1",
+ "semver": "^7.3.8"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "7.5.4",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz",
+ "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==",
+ "dev": true,
+ "requires": {
+ "lru-cache": "^6.0.0"
+ }
+ }
+ }
+ },
+ "eslint-plugin-promise": {
+ "version": "6.1.1",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-6.1.1.tgz",
+ "integrity": "sha512-tjqWDwVZQo7UIPMeDReOpUgHCmCiH+ePnVT+5zVapL0uuHnegBUs2smM13CzOs2Xb5+MHMRFTs9v24yjba4Oig==",
+ "dev": true,
+ "requires": {}
+ },
+ "eslint-scope": {
+ "version": "7.2.2",
+ "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz",
+ "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==",
+ "dev": true,
+ "requires": {
+ "esrecurse": "^4.3.0",
+ "estraverse": "^5.2.0"
+ }
+ },
+ "eslint-utils": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz",
+ "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^2.0.0"
+ },
+ "dependencies": {
+ "eslint-visitor-keys": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz",
+ "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==",
+ "dev": true
+ }
+ }
+ },
+ "eslint-visitor-keys": {
+ "version": "3.4.3",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz",
+ "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==",
+ "dev": true
+ },
+ "espree": {
+ "version": "9.6.1",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz",
+ "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==",
+ "dev": true,
+ "requires": {
+ "acorn": "^8.9.0",
+ "acorn-jsx": "^5.3.2",
+ "eslint-visitor-keys": "^3.4.1"
+ }
+ },
+ "esquery": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz",
+ "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==",
+ "dev": true,
+ "requires": {
+ "estraverse": "^5.1.0"
+ }
+ },
+ "esrecurse": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz",
+ "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==",
+ "dev": true,
+ "requires": {
+ "estraverse": "^5.2.0"
+ }
+ },
+ "estraverse": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
+ "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "dev": true
+ },
+ "esutils": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
+ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true
+ },
+ "fast-deep-equal": {
+ "version": "3.1.3",
+ "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
+ "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
+ "dev": true
+ },
+ "fast-json-stable-stringify": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz",
+ "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==",
+ "dev": true
+ },
+ "fast-levenshtein": {
+ "version": "2.0.6",
+ "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
+ "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==",
+ "dev": true
+ },
+ "fastq": {
+ "version": "1.15.0",
+ "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz",
+ "integrity": "sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==",
+ "dev": true,
+ "requires": {
+ "reusify": "^1.0.4"
+ }
+ },
+ "file-entry-cache": {
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz",
+ "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==",
+ "dev": true,
+ "requires": {
+ "flat-cache": "^3.0.4"
+ }
+ },
+ "find-up": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz",
+ "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==",
+ "dev": true,
+ "requires": {
+ "locate-path": "^6.0.0",
+ "path-exists": "^4.0.0"
+ }
+ },
+ "flat-cache": {
+ "version": "3.0.4",
+ "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz",
+ "integrity": "sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==",
+ "dev": true,
+ "requires": {
+ "flatted": "^3.1.0",
+ "rimraf": "^3.0.2"
+ }
+ },
+ "flatted": {
+ "version": "3.2.7",
+ "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz",
+ "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==",
+ "dev": true
+ },
+ "for-each": {
+ "version": "0.3.3",
+ "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz",
+ "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==",
+ "dev": true,
+ "requires": {
+ "is-callable": "^1.1.3"
+ }
+ },
+ "fs.realpath": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
+ "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==",
+ "dev": true
+ },
+ "function-bind": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
+ "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
+ "dev": true
+ },
+ "function.prototype.name": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz",
+ "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.19.0",
+ "functions-have-names": "^1.2.2"
+ }
+ },
+ "functions-have-names": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz",
+ "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==",
+ "dev": true
+ },
+ "get-intrinsic": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz",
+ "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==",
+ "dev": true,
+ "requires": {
+ "function-bind": "^1.1.1",
+ "has": "^1.0.3",
+ "has-proto": "^1.0.1",
+ "has-symbols": "^1.0.3"
+ }
+ },
+ "get-symbol-description": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz",
+ "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.1.1"
+ }
+ },
+ "glob": {
+ "version": "7.2.3",
+ "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz",
+ "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==",
+ "dev": true,
+ "requires": {
+ "fs.realpath": "^1.0.0",
+ "inflight": "^1.0.4",
+ "inherits": "2",
+ "minimatch": "^3.1.1",
+ "once": "^1.3.0",
+ "path-is-absolute": "^1.0.0"
+ }
+ },
+ "glob-parent": {
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
+ "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
+ "dev": true,
+ "requires": {
+ "is-glob": "^4.0.3"
+ }
+ },
+ "globals": {
+ "version": "13.21.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.21.0.tgz",
+ "integrity": "sha512-ybyme3s4yy/t/3s35bewwXKOf7cvzfreG2lH0lZl0JB7I4GxRP2ghxOK/Nb9EkRXdbBXZLfq/p/0W2JUONB/Gg==",
+ "dev": true,
+ "requires": {
+ "type-fest": "^0.20.2"
+ }
+ },
+ "globalthis": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz",
+ "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3"
+ }
+ },
+ "gopd": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz",
+ "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==",
+ "dev": true,
+ "requires": {
+ "get-intrinsic": "^1.1.3"
+ }
+ },
+ "graphemer": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz",
+ "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==",
+ "dev": true
+ },
+ "has": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
+ "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
+ "dev": true,
+ "requires": {
+ "function-bind": "^1.1.1"
+ }
+ },
+ "has-bigints": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz",
+ "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==",
+ "dev": true
+ },
+ "has-flag": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
+ "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
+ "dev": true
+ },
+ "has-property-descriptors": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz",
+ "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==",
+ "dev": true,
+ "requires": {
+ "get-intrinsic": "^1.1.1"
+ }
+ },
+ "has-proto": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz",
+ "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==",
+ "dev": true
+ },
+ "has-symbols": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz",
+ "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==",
+ "dev": true
+ },
+ "has-tostringtag": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz",
+ "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==",
+ "dev": true,
+ "requires": {
+ "has-symbols": "^1.0.2"
+ }
+ },
+ "ignore": {
+ "version": "5.2.4",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz",
+ "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==",
+ "dev": true
+ },
+ "import-fresh": {
+ "version": "3.3.0",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz",
+ "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==",
+ "dev": true,
+ "requires": {
+ "parent-module": "^1.0.0",
+ "resolve-from": "^4.0.0"
+ }
+ },
+ "imurmurhash": {
+ "version": "0.1.4",
+ "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz",
+ "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==",
+ "dev": true
+ },
+ "inflight": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
+ "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==",
+ "dev": true,
+ "requires": {
+ "once": "^1.3.0",
+ "wrappy": "1"
+ }
+ },
+ "inherits": {
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",
+ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==",
+ "dev": true
+ },
+ "internal-slot": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz",
+ "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==",
+ "dev": true,
+ "requires": {
+ "get-intrinsic": "^1.2.0",
+ "has": "^1.0.3",
+ "side-channel": "^1.0.4"
+ }
+ },
+ "is-array-buffer": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz",
+ "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.0",
+ "is-typed-array": "^1.1.10"
+ }
+ },
+ "is-bigint": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz",
+ "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==",
+ "dev": true,
+ "requires": {
+ "has-bigints": "^1.0.1"
+ }
+ },
+ "is-boolean-object": {
+ "version": "1.1.2",
+ "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz",
+ "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "is-callable": {
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz",
+ "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==",
+ "dev": true
+ },
+ "is-core-module": {
+ "version": "2.13.0",
+ "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz",
+ "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==",
+ "dev": true,
+ "requires": {
+ "has": "^1.0.3"
+ }
+ },
+ "is-date-object": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz",
+ "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==",
+ "dev": true,
+ "requires": {
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "is-extglob": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
+ "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
+ "dev": true
+ },
+ "is-glob": {
+ "version": "4.0.3",
+ "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
+ "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
+ "dev": true,
+ "requires": {
+ "is-extglob": "^2.1.1"
+ }
+ },
+ "is-negative-zero": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz",
+ "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==",
+ "dev": true
+ },
+ "is-number-object": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz",
+ "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==",
+ "dev": true,
+ "requires": {
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "is-path-inside": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz",
+ "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==",
+ "dev": true
+ },
+ "is-regex": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz",
+ "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "is-shared-array-buffer": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz",
+ "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2"
+ }
+ },
+ "is-string": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz",
+ "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==",
+ "dev": true,
+ "requires": {
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "is-symbol": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz",
+ "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==",
+ "dev": true,
+ "requires": {
+ "has-symbols": "^1.0.2"
+ }
+ },
+ "is-typed-array": {
+ "version": "1.1.12",
+ "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz",
+ "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==",
+ "dev": true,
+ "requires": {
+ "which-typed-array": "^1.1.11"
+ }
+ },
+ "is-weakref": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz",
+ "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2"
+ }
+ },
+ "isarray": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz",
+ "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==",
+ "dev": true
+ },
+ "isexe": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
+ "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
+ "dev": true
+ },
+ "js-yaml": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
+ "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
+ "dev": true,
+ "requires": {
+ "argparse": "^2.0.1"
+ }
+ },
+ "json-schema-traverse": {
+ "version": "0.4.1",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
+ "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==",
+ "dev": true
+ },
+ "json-stable-stringify-without-jsonify": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz",
+ "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==",
+ "dev": true
+ },
+ "json5": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz",
+ "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==",
+ "dev": true,
+ "requires": {
+ "minimist": "^1.2.0"
+ }
+ },
+ "levn": {
+ "version": "0.4.1",
+ "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz",
+ "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==",
+ "dev": true,
+ "requires": {
+ "prelude-ls": "^1.2.1",
+ "type-check": "~0.4.0"
+ }
+ },
+ "locate-path": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz",
+ "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==",
+ "dev": true,
+ "requires": {
+ "p-locate": "^5.0.0"
+ }
+ },
+ "lodash.merge": {
+ "version": "4.6.2",
+ "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz",
+ "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==",
+ "dev": true
+ },
+ "lru-cache": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz",
+ "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==",
+ "dev": true,
+ "requires": {
+ "yallist": "^4.0.0"
+ }
+ },
+ "minimatch": {
+ "version": "3.1.2",
+ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",
+ "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==",
+ "dev": true,
+ "requires": {
+ "brace-expansion": "^1.1.7"
+ }
+ },
+ "minimist": {
+ "version": "1.2.8",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz",
+ "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==",
+ "dev": true
+ },
+ "ms": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
+ "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
+ "dev": true
+ },
+ "natural-compare": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz",
+ "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==",
+ "dev": true
+ },
+ "object-inspect": {
+ "version": "1.12.3",
+ "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz",
+ "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==",
+ "dev": true
+ },
+ "object-keys": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
+ "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",
+ "dev": true
+ },
+ "object.assign": {
+ "version": "4.1.4",
+ "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz",
+ "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "has-symbols": "^1.0.3",
+ "object-keys": "^1.1.1"
+ }
+ },
+ "object.fromentries": {
+ "version": "2.0.6",
+ "resolved": "https://registry.npmjs.org/object.fromentries/-/object.fromentries-2.0.6.tgz",
+ "integrity": "sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ }
+ },
+ "object.groupby": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/object.groupby/-/object.groupby-1.0.0.tgz",
+ "integrity": "sha512-70MWG6NfRH9GnbZOikuhPPYzpUpof9iW2J9E4dW7FXTqPNb6rllE6u39SKwwiNh8lCwX3DDb5OgcKGiEBrTTyw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "es-abstract": "^1.21.2",
+ "get-intrinsic": "^1.2.1"
+ }
+ },
+ "object.values": {
+ "version": "1.1.6",
+ "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.6.tgz",
+ "integrity": "sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ }
+ },
+ "once": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
+ "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",
+ "dev": true,
+ "requires": {
+ "wrappy": "1"
+ }
+ },
+ "optionator": {
+ "version": "0.9.3",
+ "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz",
+ "integrity": "sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==",
+ "dev": true,
+ "requires": {
+ "@aashutoshrathi/word-wrap": "^1.2.3",
+ "deep-is": "^0.1.3",
+ "fast-levenshtein": "^2.0.6",
+ "levn": "^0.4.1",
+ "prelude-ls": "^1.2.1",
+ "type-check": "^0.4.0"
+ }
+ },
+ "p-limit": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz",
+ "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==",
+ "dev": true,
+ "requires": {
+ "yocto-queue": "^0.1.0"
+ }
+ },
+ "p-locate": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz",
+ "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==",
+ "dev": true,
+ "requires": {
+ "p-limit": "^3.0.2"
+ }
+ },
+ "parent-module": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
+ "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==",
+ "dev": true,
+ "requires": {
+ "callsites": "^3.0.0"
+ }
+ },
+ "path-exists": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
+ "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==",
+ "dev": true
+ },
+ "path-is-absolute": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
+ "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==",
+ "dev": true
+ },
+ "path-key": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
+ "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
+ "dev": true
+ },
+ "path-parse": {
+ "version": "1.0.7",
+ "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
+ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
+ "dev": true
+ },
+ "prelude-ls": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
+ "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==",
+ "dev": true
+ },
+ "punycode": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.0.tgz",
+ "integrity": "sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==",
+ "dev": true
+ },
+ "queue-microtask": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
+ "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
+ "dev": true
+ },
+ "regexp.prototype.flags": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz",
+ "integrity": "sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.2.0",
+ "functions-have-names": "^1.2.3"
+ }
+ },
+ "regexpp": {
+ "version": "3.2.0",
+ "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz",
+ "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==",
+ "dev": true
+ },
+ "resolve": {
+ "version": "1.22.4",
+ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.4.tgz",
+ "integrity": "sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==",
+ "dev": true,
+ "requires": {
+ "is-core-module": "^2.13.0",
+ "path-parse": "^1.0.7",
+ "supports-preserve-symlinks-flag": "^1.0.0"
+ }
+ },
+ "resolve-from": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
+ "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==",
+ "dev": true
+ },
+ "reusify": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
+ "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==",
+ "dev": true
+ },
+ "rimraf": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
+ "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==",
+ "dev": true,
+ "requires": {
+ "glob": "^7.1.3"
+ }
+ },
+ "run-parallel": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
+ "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
+ "dev": true,
+ "requires": {
+ "queue-microtask": "^1.2.2"
+ }
+ },
+ "safe-array-concat": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz",
+ "integrity": "sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.0",
+ "has-symbols": "^1.0.3",
+ "isarray": "^2.0.5"
+ }
+ },
+ "safe-regex-test": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz",
+ "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.1.3",
+ "is-regex": "^1.1.4"
+ }
+ },
+ "semver": {
+ "version": "6.3.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz",
+ "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==",
+ "dev": true
+ },
+ "shebang-command": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
+ "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
+ "dev": true,
+ "requires": {
+ "shebang-regex": "^3.0.0"
+ }
+ },
+ "shebang-regex": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
+ "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
+ "dev": true
+ },
+ "side-channel": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz",
+ "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.0",
+ "get-intrinsic": "^1.0.2",
+ "object-inspect": "^1.9.0"
+ }
+ },
+ "string.prototype.trim": {
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz",
+ "integrity": "sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ }
+ },
+ "string.prototype.trimend": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz",
+ "integrity": "sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ }
+ },
+ "string.prototype.trimstart": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz",
+ "integrity": "sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.20.4"
+ }
+ },
+ "strip-ansi": {
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
+ "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
+ "dev": true,
+ "requires": {
+ "ansi-regex": "^5.0.1"
+ }
+ },
+ "strip-bom": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
+ "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==",
+ "dev": true
+ },
+ "strip-json-comments": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz",
+ "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==",
+ "dev": true
+ },
+ "supports-color": {
+ "version": "7.2.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
+ "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
+ "dev": true,
+ "requires": {
+ "has-flag": "^4.0.0"
+ }
+ },
+ "supports-preserve-symlinks-flag": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
+ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
+ "dev": true
+ },
+ "text-table": {
+ "version": "0.2.0",
+ "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz",
+ "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==",
+ "dev": true
+ },
+ "tsconfig-paths": {
+ "version": "3.14.2",
+ "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.2.tgz",
+ "integrity": "sha512-o/9iXgCYc5L/JxCHPe3Hvh8Q/2xm5Z+p18PESBU6Ff33695QnCHBEjcytY2q19ua7Mbl/DavtBOLq+oG0RCL+g==",
+ "dev": true,
+ "requires": {
+ "@types/json5": "^0.0.29",
+ "json5": "^1.0.2",
+ "minimist": "^1.2.6",
+ "strip-bom": "^3.0.0"
+ }
+ },
+ "type-check": {
+ "version": "0.4.0",
+ "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz",
+ "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==",
+ "dev": true,
+ "requires": {
+ "prelude-ls": "^1.2.1"
+ }
+ },
+ "type-fest": {
+ "version": "0.20.2",
+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz",
+ "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==",
+ "dev": true
+ },
+ "typed-array-buffer": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz",
+ "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "get-intrinsic": "^1.2.1",
+ "is-typed-array": "^1.1.10"
+ }
+ },
+ "typed-array-byte-length": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz",
+ "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "has-proto": "^1.0.1",
+ "is-typed-array": "^1.1.10"
+ }
+ },
+ "typed-array-byte-offset": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz",
+ "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==",
+ "dev": true,
+ "requires": {
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "has-proto": "^1.0.1",
+ "is-typed-array": "^1.1.10"
+ }
+ },
+ "typed-array-length": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz",
+ "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "is-typed-array": "^1.1.9"
+ }
+ },
+ "unbox-primitive": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz",
+ "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "has-bigints": "^1.0.2",
+ "has-symbols": "^1.0.3",
+ "which-boxed-primitive": "^1.0.2"
+ }
+ },
+ "uri-js": {
+ "version": "4.4.1",
+ "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
+ "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
+ "dev": true,
+ "requires": {
+ "punycode": "^2.1.0"
+ }
+ },
+ "which": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
+ "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
+ "dev": true,
+ "requires": {
+ "isexe": "^2.0.0"
+ }
+ },
+ "which-boxed-primitive": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz",
+ "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==",
+ "dev": true,
+ "requires": {
+ "is-bigint": "^1.0.1",
+ "is-boolean-object": "^1.1.0",
+ "is-number-object": "^1.0.4",
+ "is-string": "^1.0.5",
+ "is-symbol": "^1.0.3"
+ }
+ },
+ "which-typed-array": {
+ "version": "1.1.11",
+ "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz",
+ "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==",
+ "dev": true,
+ "requires": {
+ "available-typed-arrays": "^1.0.5",
+ "call-bind": "^1.0.2",
+ "for-each": "^0.3.3",
+ "gopd": "^1.0.1",
+ "has-tostringtag": "^1.0.0"
+ }
+ },
+ "wrappy": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
+ "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==",
+ "dev": true
+ },
+ "yallist": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
+ "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
+ "dev": true
+ },
+ "yocto-queue": {
+ "version": "0.1.0",
+ "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz",
+ "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==",
+ "dev": true
+ }
+ }
+}
diff --git a/package.json b/package.json
index 57747b1f8..624d571ff 100644
--- a/package.json
+++ b/package.json
@@ -1,40 +1,29 @@
{
"name": "Camera",
- "version": "4.0.3",
- "description": "Cordova Camera",
+ "version": "7.0.0",
+ "description": "Cordova Camera Plugin",
"types": "./types/index.d.ts",
"cordova": {
"id": "Camera",
"platforms": [
"android",
"ios",
- "browser",
- "windows",
- "osx"
+ "browser"
]
},
- "repository": {
- "type": "git",
- "url": "https://github.com/apache/cordova-plugin-camera"
- },
- "bugs": {
- "url": "https://issues.apache.org/jira/browse/CB"
- },
+ "repository": "github:apache/cordova-plugin-camera",
+ "bugs": "https://github.com/apache/cordova-plugin-camera/issues",
"keywords": [
"cordova",
"camera",
"ecosystem:cordova",
"cordova-android",
"cordova-ios",
- "cordova-browser",
- "cordova-windows",
- "cordova-osx"
+ "cordova-browser"
],
"scripts": {
- "precommit": "npm run gen-docs && git add README.md",
- "gen-docs": "jsdoc2md --template \"jsdoc2md/TEMPLATE.md\" \"www/**/*.js\" --plugin \"dmd-plugin-cordova-plugin\" > README.md",
- "test": "npm run eslint",
- "eslint": "node node_modules/eslint/bin/eslint www && node node_modules/eslint/bin/eslint src && node node_modules/eslint/bin/eslint tests"
+ "test": "npm run lint",
+ "lint": "eslint ."
},
"author": "Apache Software Foundation",
"license": "Apache-2.0",
@@ -43,21 +32,36 @@
"3.0.0": {
"cordova-android": ">=6.3.0"
},
+ "4.1.0": {
+ "cordova-android": ">=6.3.0",
+ "cordova": ">=7.1.0"
+ },
"5.0.0": {
+ "cordova-android": ">=9.0.0",
+ "cordova-ios": ">=5.1.0",
+ "cordova": ">=9.0.0"
+ },
+ "5.0.4-dev": {
+ "cordova-android": "<10.0.0",
+ "cordova-ios": ">=5.1.0",
+ "cordova": ">=9.0.0"
+ },
+ "6.0.0": {
+ "cordova-android": ">=10.0.0",
+ "cordova-ios": ">=5.1.0",
+ "cordova": ">=9.0.0"
+ },
+ "7.0.0": {
+ "cordova-android": ">=12.0.0",
+ "cordova-ios": ">=5.1.0",
+ "cordova": ">=9.0.0"
+ },
+ "8.0.0": {
"cordova": ">100"
}
}
},
"devDependencies": {
- "dmd-plugin-cordova-plugin": "^0.1.0",
- "eslint": "^4.3.0",
- "eslint-config-semistandard": "^11.0.0",
- "eslint-config-standard": "^10.2.1",
- "eslint-plugin-import": "^2.3.0",
- "eslint-plugin-node": "^5.0.0",
- "eslint-plugin-promise": "^3.5.0",
- "eslint-plugin-standard": "^3.0.1",
- "husky": "^0.10.1",
- "jsdoc-to-markdown": "^1.2.0"
+ "@cordova/eslint-config": "^5.0.0"
}
}
diff --git a/plugin.xml b/plugin.xml
index cb3465bd1..c5a84bb29 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -22,16 +22,18 @@
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:rim="http://www.blackberry.com/ns/widgets"
id="Camera"
- version="4.0.3">
+ version="7.0.0">
Camera
Cordova Camera Plugin
Apache 2.0
cordova,camera
- https://git-wip-us.apache.org/repos/asf/cordova-plugin-camera.git
- https://issues.apache.org/jira/browse/CB/component/12320645
+ https://github.com/apache/cordova-plugin-camera
+ https://github.com/apache/cordova-plugin-camera/issues
-
+
+
+
@@ -42,8 +44,6 @@
-
-
@@ -56,12 +56,14 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
@@ -128,36 +149,4 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/android/CameraLauncher.java b/src/android/CameraLauncher.java
index 39e0308f9..ef730d643 100644
--- a/src/android/CameraLauncher.java
+++ b/src/android/CameraLauncher.java
@@ -18,34 +18,15 @@ Licensed to the Apache Software Foundation (ASF) under one
*/
package org.apache.cordova.camera;
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.text.SimpleDateFormat;
-import java.util.Date;
-
-import org.apache.cordova.BuildHelper;
-import org.apache.cordova.CallbackContext;
-import org.apache.cordova.CordovaPlugin;
-import org.apache.cordova.CordovaResourceApi;
-import org.apache.cordova.LOG;
-import org.apache.cordova.PermissionHelper;
-import org.apache.cordova.PluginResult;
-import org.json.JSONArray;
-import org.json.JSONException;
-
import android.Manifest;
-import android.annotation.TargetApi;
+import android.annotation.SuppressLint;
import android.app.Activity;
import android.content.ActivityNotFoundException;
+import android.content.ContentResolver;
import android.content.ContentValues;
-import android.content.Context;
import android.content.Intent;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
import android.database.Cursor;
import android.graphics.Bitmap;
import android.graphics.Bitmap.CompressFormat;
@@ -58,13 +39,29 @@ Licensed to the Apache Software Foundation (ASF) under one
import android.os.Build;
import android.os.Bundle;
import android.os.Environment;
-import android.provider.DocumentsContract;
import android.provider.MediaStore;
-import android.provider.OpenableColumns;
import androidx.core.content.FileProvider;
import android.util.Base64;
-import android.content.pm.PackageManager;
-import android.content.pm.PackageManager.NameNotFoundException;
+
+import org.apache.cordova.BuildHelper;
+import org.apache.cordova.CallbackContext;
+import org.apache.cordova.CordovaPlugin;
+import org.apache.cordova.LOG;
+import org.apache.cordova.PermissionHelper;
+import org.apache.cordova.PluginResult;
+import org.json.JSONArray;
+import org.json.JSONException;
+
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Date;
/**
* This class launches the camera view, allows the user to take a picture, closes the camera view,
@@ -75,7 +72,6 @@ public class CameraLauncher extends CordovaPlugin implements MediaScannerConnect
private static final int DATA_URL = 0; // Return base64 encoded string
private static final int FILE_URI = 1; // Return file uri (content://media/external/images/media/2 for Android)
- private static final int NATIVE_URI = 2; // On Android, this is the same as FILE_URI
private static final int PHOTOLIBRARY = 0; // Choose image from picture library (same as SAVEDPHOTOALBUM for Android)
private static final int CAMERA = 1; // Take picture from camera
@@ -87,9 +83,21 @@ public class CameraLauncher extends CordovaPlugin implements MediaScannerConnect
private static final int JPEG = 0; // Take a picture of type JPEG
private static final int PNG = 1; // Take a picture of type PNG
+ private static final String JPEG_TYPE = "jpg";
+ private static final String PNG_TYPE = "png";
+ private static final String JPEG_EXTENSION = "." + JPEG_TYPE;
+ private static final String PNG_EXTENSION = "." + PNG_TYPE;
+ private static final String PNG_MIME_TYPE = "image/png";
+ private static final String JPEG_MIME_TYPE = "image/jpeg";
+ private static final String HEIC_MIME_TYPE = "image/heic";
private static final String GET_PICTURE = "Get Picture";
private static final String GET_VIDEO = "Get Video";
private static final String GET_All = "Get All";
+ private static final String CROPPED_URI_KEY = "croppedUri";
+ private static final String IMAGE_URI_KEY = "imageUri";
+ private static final String IMAGE_FILE_PATH_KEY = "imageFilePath";
+
+ private static final String TAKE_PICTURE_ACTION = "takePicture";
public static final int PERMISSION_DENIED_ERROR = 20;
public static final int TAKE_PIC_SEC = 0;
@@ -100,10 +108,13 @@ public class CameraLauncher extends CordovaPlugin implements MediaScannerConnect
//Where did this come from?
private static final int CROP_CAMERA = 100;
+ private static final String TIME_FORMAT = "yyyyMMdd_HHmmss";
+
private int mQuality; // Compression quality hint (0-100: 0=low quality & high compression, 100=compress of max quality)
private int targetWidth; // desired width of the image
private int targetHeight; // desired height of the image
- private CordovaUri imageUri; // Uri of captured image
+ private Uri imageUri; // Uri of captured image
+ private String imageFilePath; // File where the image is stored
private int encodingType; // Type of encoding to use
private int mediaType; // What type of media to retrieve
private int destType; // Source type (needs to be saved for the permission handling)
@@ -113,14 +124,13 @@ public class CameraLauncher extends CordovaPlugin implements MediaScannerConnect
private boolean orientationCorrected; // Has the picture's orientation been corrected
private boolean allowEdit; // Should we allow the user to crop the image.
- protected final static String[] permissions = { Manifest.permission.CAMERA, Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE };
-
public CallbackContext callbackContext;
private int numPics;
private MediaScannerConnection conn; // Used to update gallery app with newly-written files
private Uri scanMe; // Uri of image to be added to content store
private Uri croppedUri;
+ private String croppedFilePath;
private ExifHelper exifData; // Exif data from source
private String applicationId;
@@ -135,13 +145,11 @@ public class CameraLauncher extends CordovaPlugin implements MediaScannerConnect
*/
public boolean execute(String action, JSONArray args, CallbackContext callbackContext) throws JSONException {
this.callbackContext = callbackContext;
- //Adding an API to CoreAndroid to get the BuildConfigValue
- //This allows us to not make this a breaking change to embedding
- this.applicationId = (String) BuildHelper.getBuildConfigValue(cordova.getActivity(), "APPLICATION_ID");
- this.applicationId = preferences.getString("applicationId", this.applicationId);
+ this.applicationId = cordova.getContext().getPackageName();
+ this.applicationId = preferences.getString("applicationId", this.applicationId);
- if (action.equals("takePicture")) {
+ if (action.equals(TAKE_PICTURE_ACTION)) {
this.srcType = CAMERA;
this.destType = FILE_URI;
this.saveToPhotoAlbum = false;
@@ -185,10 +193,11 @@ public boolean execute(String action, JSONArray args, CallbackContext callbackCo
}
else if ((this.srcType == PHOTOLIBRARY) || (this.srcType == SAVEDPHOTOALBUM)) {
// FIXME: Stop always requesting the permission
- if(!PermissionHelper.hasPermission(this, Manifest.permission.READ_EXTERNAL_STORAGE)) {
- PermissionHelper.requestPermission(this, SAVE_TO_ALBUM_SEC, Manifest.permission.READ_EXTERNAL_STORAGE);
+ String[] permissions = getPermissions(true, mediaType);
+ if(!hasPermissions(permissions)) {
+ PermissionHelper.requestPermissions(this, SAVE_TO_ALBUM_SEC, permissions);
} else {
- this.getImage(this.srcType, destType, encodingType);
+ this.getImage(this.srcType, destType);
}
}
}
@@ -213,18 +222,39 @@ else if ((this.srcType == PHOTOLIBRARY) || (this.srcType == SAVEDPHOTOALBUM)) {
// LOCAL METHODS
//--------------------------------------------------------------------------
- private String getTempDirectoryPath() {
- File cache = null;
-
- // SD Card Mounted
- if (Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED)) {
- cache = cordova.getActivity().getExternalCacheDir();
+ private String[] getPermissions(boolean storageOnly, int mediaType) {
+ ArrayList permissions = new ArrayList<>();
+
+ if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
+ // Android API 33 and higher
+ switch (mediaType) {
+ case PICTURE:
+ permissions.add(Manifest.permission.READ_MEDIA_IMAGES);
+ break;
+ case VIDEO:
+ permissions.add(Manifest.permission.READ_MEDIA_VIDEO);
+ break;
+ default:
+ permissions.add(Manifest.permission.READ_MEDIA_IMAGES);
+ permissions.add(Manifest.permission.READ_MEDIA_VIDEO);
+ break;
+ }
+ } else {
+ // Android API 32 or lower
+ permissions.add(Manifest.permission.READ_EXTERNAL_STORAGE);
+ permissions.add(Manifest.permission.WRITE_EXTERNAL_STORAGE);
}
- // Use internal storage
- else {
- cache = cordova.getActivity().getCacheDir();
+
+ if (!storageOnly) {
+ // Add camera permission when not storage.
+ permissions.add(Manifest.permission.CAMERA);
}
+ return permissions.toArray(new String[0]);
+ }
+
+ private String getTempDirectoryPath() {
+ File cache = cordova.getActivity().getCacheDir();
// Create the cache directory if it doesn't exist
cache.mkdirs();
return cache.getAbsolutePath();
@@ -245,8 +275,13 @@ private String getTempDirectoryPath() {
* @param encodingType Compression quality hint (0-100: 0=low quality & high compression, 100=compress of max quality)
*/
public void callTakePicture(int returnType, int encodingType) {
- boolean saveAlbumPermission = PermissionHelper.hasPermission(this, Manifest.permission.READ_EXTERNAL_STORAGE)
- && PermissionHelper.hasPermission(this, Manifest.permission.WRITE_EXTERNAL_STORAGE);
+ String[] storagePermissions = getPermissions(true, mediaType);
+ boolean saveAlbumPermission;
+ if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
+ saveAlbumPermission = this.saveToPhotoAlbum ? hasPermissions(storagePermissions) : true;
+ } else {
+ saveAlbumPermission = hasPermissions(storagePermissions);
+ }
boolean takePicturePermission = PermissionHelper.hasPermission(this, Manifest.permission.CAMERA);
// CB-10120: The CAMERA permission does not need to be requested unless it is declared
@@ -274,13 +309,12 @@ public void callTakePicture(int returnType, int encodingType) {
if (takePicturePermission && saveAlbumPermission) {
takePicture(returnType, encodingType);
- } else if (saveAlbumPermission && !takePicturePermission) {
+ } else if (saveAlbumPermission) {
PermissionHelper.requestPermission(this, TAKE_PIC_SEC, Manifest.permission.CAMERA);
- } else if (!saveAlbumPermission && takePicturePermission) {
- PermissionHelper.requestPermissions(this, TAKE_PIC_SEC,
- new String[]{Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE});
+ } else if (takePicturePermission) {
+ PermissionHelper.requestPermissions(this, TAKE_PIC_SEC, storagePermissions);
} else {
- PermissionHelper.requestPermissions(this, TAKE_PIC_SEC, permissions);
+ PermissionHelper.requestPermissions(this, TAKE_PIC_SEC, getPermissions(false, mediaType));
}
}
@@ -294,10 +328,11 @@ public void takePicture(int returnType, int encodingType)
// Specify file so that large image is captured and returned
File photo = createCaptureFile(encodingType);
- this.imageUri = new CordovaUri(FileProvider.getUriForFile(cordova.getActivity(),
- applicationId + ".provider",
- photo));
- intent.putExtra(android.provider.MediaStore.EXTRA_OUTPUT, imageUri.getCorrectUri());
+ this.imageFilePath = photo.getAbsolutePath();
+ this.imageUri = FileProvider.getUriForFile(cordova.getActivity(),
+ applicationId + ".cordova.plugin.camera.provider",
+ photo);
+ intent.putExtra(MediaStore.EXTRA_OUTPUT, imageUri);
//We can write to this URI, this will hopefully allow us to write files to get to the next step
intent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
@@ -306,7 +341,6 @@ public void takePicture(int returnType, int encodingType)
PackageManager mPm = this.cordova.getActivity().getPackageManager();
if(intent.resolveActivity(mPm) != null)
{
-
this.cordova.startActivityForResult((CordovaPlugin) this, intent, (CAMERA + 1) * 16 + returnType + 1);
}
else
@@ -341,9 +375,9 @@ private File createCaptureFile(int encodingType, String fileName) {
}
if (encodingType == JPEG) {
- fileName = fileName + ".jpg";
+ fileName = fileName + JPEG_EXTENSION;
} else if (encodingType == PNG) {
- fileName = fileName + ".png";
+ fileName = fileName + PNG_EXTENSION;
} else {
throw new IllegalArgumentException("Invalid Encoding Type: " + encodingType);
}
@@ -352,20 +386,19 @@ private File createCaptureFile(int encodingType, String fileName) {
}
-
/**
* Get image from photo library.
*
* @param srcType The album to get image from.
* @param returnType Set the type of image to return.
- * @param encodingType
*/
// TODO: Images selected from SDCARD don't display correctly, but from CAMERA ALBUM do!
// TODO: Images from kitkat filechooser not going into crop function
- public void getImage(int srcType, int returnType, int encodingType) {
+ public void getImage(int srcType, int returnType) {
Intent intent = new Intent();
String title = GET_PICTURE;
croppedUri = null;
+ croppedFilePath = null;
if (this.mediaType == PICTURE) {
intent.setType("image/*");
if (this.allowEdit) {
@@ -381,9 +414,10 @@ public void getImage(int srcType, int returnType, int encodingType) {
intent.putExtra("aspectX", 1);
intent.putExtra("aspectY", 1);
}
- File photo = createCaptureFile(JPEG);
- croppedUri = Uri.fromFile(photo);
- intent.putExtra(android.provider.MediaStore.EXTRA_OUTPUT, croppedUri);
+ File croppedFile = createCaptureFile(JPEG);
+ croppedFilePath = croppedFile.getAbsolutePath();
+ croppedUri = Uri.fromFile(croppedFile);
+ intent.putExtra(MediaStore.EXTRA_OUTPUT, croppedUri);
} else {
intent.setAction(Intent.ACTION_GET_CONTENT);
intent.addCategory(Intent.CATEGORY_OPENABLE);
@@ -407,57 +441,53 @@ public void getImage(int srcType, int returnType, int encodingType) {
}
}
-
- /**
- * Brings up the UI to perform crop on passed image URI
- *
- * @param picUri
- */
- private void performCrop(Uri picUri, int destType, Intent cameraIntent) {
- try {
- Intent cropIntent = new Intent("com.android.camera.action.CROP");
- // indicate image type and Uri
- cropIntent.setDataAndType(picUri, "image/*");
- // set crop properties
- cropIntent.putExtra("crop", "true");
-
-
- // indicate output X and Y
- if (targetWidth > 0) {
- cropIntent.putExtra("outputX", targetWidth);
- }
- if (targetHeight > 0) {
- cropIntent.putExtra("outputY", targetHeight);
- }
- if (targetHeight > 0 && targetWidth > 0 && targetWidth == targetHeight) {
- cropIntent.putExtra("aspectX", 1);
- cropIntent.putExtra("aspectY", 1);
- }
- // create new file handle to get full resolution crop
- croppedUri = Uri.fromFile(createCaptureFile(this.encodingType, System.currentTimeMillis() + ""));
- cropIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
- cropIntent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
- cropIntent.putExtra("output", croppedUri);
-
-
- // start the activity - we handle returning in onActivityResult
-
- if (this.cordova != null) {
- this.cordova.startActivityForResult((CordovaPlugin) this,
- cropIntent, CROP_CAMERA + destType);
+ /**
+ * Brings up the UI to perform crop on passed image URI
+ *
+ * @param picUri
+ */
+ private void performCrop(Uri picUri, int destType, Intent cameraIntent) {
+ try {
+ Intent cropIntent = new Intent("com.android.camera.action.CROP");
+ // indicate image type and Uri
+ cropIntent.setDataAndType(picUri, "image/*");
+ // set crop properties
+ cropIntent.putExtra("crop", "true");
+
+ // indicate output X and Y
+ if (targetWidth > 0) {
+ cropIntent.putExtra("outputX", targetWidth);
+ }
+ if (targetHeight > 0) {
+ cropIntent.putExtra("outputY", targetHeight);
+ }
+ if (targetHeight > 0 && targetWidth > 0 && targetWidth == targetHeight) {
+ cropIntent.putExtra("aspectX", 1);
+ cropIntent.putExtra("aspectY", 1);
+ }
+ // create new file handle to get full resolution crop
+ croppedFilePath = createCaptureFile(this.encodingType, System.currentTimeMillis() + "").getAbsolutePath();
+ croppedUri = Uri.parse(croppedFilePath);
+ cropIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
+ cropIntent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
+ cropIntent.putExtra("output", croppedUri);
+
+ // start the activity - we handle returning in onActivityResult
+
+ if (this.cordova != null) {
+ this.cordova.startActivityForResult((CordovaPlugin) this,
+ cropIntent, CROP_CAMERA + destType);
+ }
+ } catch (ActivityNotFoundException anfe) {
+ LOG.e(LOG_TAG, "Crop operation not supported on this device");
+ try {
+ processResultFromCamera(destType, cameraIntent);
+ } catch (IOException e) {
+ e.printStackTrace();
+ LOG.e(LOG_TAG, "Unable to write to file");
+ }
}
- } catch (ActivityNotFoundException anfe) {
- LOG.e(LOG_TAG, "Crop operation not supported on this device");
- try {
- processResultFromCamera(destType, cameraIntent);
- }
- catch (IOException e)
- {
- e.printStackTrace();
- LOG.e(LOG_TAG, "Unable to write to file");
- }
}
- }
/**
* Applies all needed transformation to the image received from the camera.
@@ -472,9 +502,8 @@ private void processResultFromCamera(int destType, Intent intent) throws IOExcep
ExifHelper exif = new ExifHelper();
String sourcePath = (this.allowEdit && this.croppedUri != null) ?
- FileHelper.stripFileProtocol(this.croppedUri.toString()) :
- this.imageUri.getFilePath();
-
+ this.croppedFilePath :
+ this.imageFilePath;
if (this.encodingType == JPEG) {
try {
@@ -495,16 +524,18 @@ private void processResultFromCamera(int destType, Intent intent) throws IOExcep
// in the gallery and the modified image is saved in the temporary
// directory
if (this.saveToPhotoAlbum) {
- galleryUri = Uri.fromFile(new File(getPicturesPath()));
+ GalleryPathVO galleryPathVO = getPicturesPath();
+ galleryUri = Uri.fromFile(new File(galleryPathVO.getGalleryPath()));
if (this.allowEdit && this.croppedUri != null) {
writeUncompressedImage(croppedUri, galleryUri);
} else {
- Uri imageUri = this.imageUri.getFileUri();
- writeUncompressedImage(imageUri, galleryUri);
+ if (Build.VERSION.SDK_INT <= 28) { // Between LOLLIPOP_MR1 and P, can be changed later to the constant Build.VERSION_CODES.P
+ writeTakenPictureToGalleryLowerThanAndroidQ(galleryUri);
+ } else { // Android Q or higher
+ writeTakenPictureToGalleryStartingFromAndroidQ(galleryPathVO);
+ }
}
-
- refreshGallery(galleryUri);
}
// If sending base64 image back
@@ -532,7 +563,7 @@ private void processResultFromCamera(int destType, Intent intent) throws IOExcep
}
// If sending filename back
- else if (destType == FILE_URI || destType == NATIVE_URI) {
+ else if (destType == FILE_URI) {
// If all this is true we shouldn't compress the image.
if (this.targetHeight == -1 && this.targetWidth == -1 && this.mQuality == 100 &&
!this.correctOrientation) {
@@ -545,10 +576,10 @@ else if (destType == FILE_URI || destType == NATIVE_URI) {
Uri uri = Uri.fromFile(createCaptureFile(this.encodingType, System.currentTimeMillis() + ""));
if (this.allowEdit && this.croppedUri != null) {
- Uri croppedUri = Uri.fromFile(new File(getFileNameFromUri(this.croppedUri)));
+ Uri croppedUri = Uri.parse(croppedFilePath);
writeUncompressedImage(croppedUri, uri);
} else {
- Uri imageUri = this.imageUri.getFileUri();
+ Uri imageUri = this.imageUri;
writeUncompressedImage(imageUri, uri);
}
@@ -568,9 +599,7 @@ else if (destType == FILE_URI || destType == NATIVE_URI) {
// Add compressed version of captured image to returned media store Uri
OutputStream os = this.cordova.getActivity().getContentResolver().openOutputStream(uri);
- CompressFormat compressFormat = encodingType == JPEG ?
- CompressFormat.JPEG :
- CompressFormat.PNG;
+ CompressFormat compressFormat = getCompressFormatForEncodingType(encodingType);
bitmap.compress(compressFormat, this.mQuality, os);
os.close();
@@ -594,56 +623,69 @@ else if (destType == FILE_URI || destType == NATIVE_URI) {
throw new IllegalStateException();
}
- this.cleanup(FILE_URI, this.imageUri.getFileUri(), galleryUri, bitmap);
+ this.cleanup(FILE_URI, this.imageUri, galleryUri, bitmap);
bitmap = null;
}
- private String getPicturesPath() {
- String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
- String imageFileName = "IMG_" + timeStamp + (this.encodingType == JPEG ? ".jpg" : ".png");
+ private void writeTakenPictureToGalleryLowerThanAndroidQ(Uri galleryUri) throws IOException {
+ writeUncompressedImage(imageUri, galleryUri);
+ refreshGallery(galleryUri);
+ }
+
+ private void writeTakenPictureToGalleryStartingFromAndroidQ(GalleryPathVO galleryPathVO) throws IOException {
+ // Starting from Android Q, working with the ACTION_MEDIA_SCANNER_SCAN_FILE intent is deprecated
+ // https://developer.android.com/reference/android/content/Intent#ACTION_MEDIA_SCANNER_SCAN_FILE
+ // we must start working with the MediaStore from Android Q on.
+ ContentResolver resolver = this.cordova.getActivity().getContentResolver();
+ ContentValues contentValues = new ContentValues();
+ contentValues.put(MediaStore.MediaColumns.DISPLAY_NAME, galleryPathVO.getGalleryFileName());
+ contentValues.put(MediaStore.MediaColumns.MIME_TYPE, getMimetypeForEncodingType());
+ Uri galleryOutputUri = resolver.insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, contentValues);
+
+ InputStream fileStream = org.apache.cordova.camera.FileHelper.getInputStreamFromUriString(imageUri.toString(), cordova);
+ writeUncompressedImage(fileStream, galleryOutputUri);
+ }
+
+ private CompressFormat getCompressFormatForEncodingType(int encodingType) {
+ return encodingType == JPEG ? CompressFormat.JPEG : CompressFormat.PNG;
+ }
+
+ private GalleryPathVO getPicturesPath() {
+ String timeStamp = new SimpleDateFormat(TIME_FORMAT).format(new Date());
+ String imageFileName = "IMG_" + timeStamp + getExtensionForEncodingType();
File storageDir = Environment.getExternalStoragePublicDirectory(
Environment.DIRECTORY_PICTURES);
storageDir.mkdirs();
- String galleryPath = storageDir.getAbsolutePath() + "/" + imageFileName;
- return galleryPath;
+ return new GalleryPathVO(storageDir.getAbsolutePath(), imageFileName);
}
private void refreshGallery(Uri contentUri) {
Intent mediaScanIntent = new Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE);
+ // Starting from Android Q, working with the ACTION_MEDIA_SCANNER_SCAN_FILE intent is deprecated
mediaScanIntent.setData(contentUri);
this.cordova.getActivity().sendBroadcast(mediaScanIntent);
}
/**
* Converts output image format int value to string value of mime type.
- * @param outputFormat int Output format of camera API.
- * Must be value of either JPEG or PNG constant
* @return String String value of mime type or empty string if mime type is not supported
*/
- private String getMimetypeForFormat(int outputFormat) {
- if (outputFormat == PNG) return "image/png";
- if (outputFormat == JPEG) return "image/jpeg";
+ private String getMimetypeForEncodingType() {
+ if (encodingType == PNG) return PNG_MIME_TYPE;
+ if (encodingType == JPEG) return JPEG_MIME_TYPE;
return "";
}
- private String outputModifiedBitmap(Bitmap bitmap, Uri uri) throws IOException {
+ private String outputModifiedBitmap(Bitmap bitmap, Uri uri, String mimeTypeOfOriginalFile) throws IOException {
// Some content: URIs do not map to file paths (e.g. picasa).
String realPath = FileHelper.getRealPath(uri, this.cordova);
+ String fileName = calculateModifiedBitmapOutputFileName(mimeTypeOfOriginalFile, realPath);
- // Get filename from uri
- String fileName = realPath != null ?
- realPath.substring(realPath.lastIndexOf('/') + 1) :
- "modified." + (this.encodingType == JPEG ? "jpg" : "png");
-
- String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
- //String fileName = "IMG_" + timeStamp + (this.encodingType == JPEG ? ".jpg" : ".png");
String modifiedPath = getTempDirectoryPath() + "/" + fileName;
OutputStream os = new FileOutputStream(modifiedPath);
- CompressFormat compressFormat = this.encodingType == JPEG ?
- CompressFormat.JPEG :
- CompressFormat.PNG;
+ CompressFormat compressFormat = getCompressFormatForEncodingType(this.encodingType);
bitmap.compress(compressFormat, this.mQuality, os);
os.close();
@@ -663,6 +705,23 @@ private String outputModifiedBitmap(Bitmap bitmap, Uri uri) throws IOException {
return modifiedPath;
}
+ private String calculateModifiedBitmapOutputFileName(String mimeTypeOfOriginalFile, String realPath) {
+ if (realPath == null) {
+ return "modified" + getExtensionForEncodingType();
+ }
+ String fileName = realPath.substring(realPath.lastIndexOf('/') + 1);
+ if (getMimetypeForEncodingType().equals(mimeTypeOfOriginalFile)) {
+ return fileName;
+ }
+ // if the picture is not a jpeg or png, (a .heic for example) when processed to a bitmap
+ // the file extension is changed to the output format, f.e. an input file my_photo.heic could become my_photo.jpg
+ return fileName.substring(fileName.lastIndexOf(".") + 1) + getExtensionForEncodingType();
+ }
+
+ private String getExtensionForEncodingType() {
+ return this.encodingType == JPEG ? JPEG_EXTENSION : PNG_EXTENSION;
+ }
+
/**
* Applies all needed transformation to the image received from the gallery.
@@ -680,80 +739,90 @@ private void processResultFromGallery(int destType, Intent intent) {
return;
}
}
- int rotate = 0;
String fileLocation = FileHelper.getRealPath(uri, this.cordova);
- LOG.d(LOG_TAG, "File locaton is: " + fileLocation);
+ LOG.d(LOG_TAG, "File location is: " + fileLocation);
- // If you ask for video or all media type you will automatically get back a file URI
- // and there will be no attempt to resize any returned data
- if (this.mediaType != PICTURE) {
- this.callbackContext.success(fileLocation);
- }
- else {
- String uriString = uri.toString();
- // Get the path to the image. Makes loading so much easier.
- String mimeType = FileHelper.getMimeType(uriString, this.cordova);
-
- // This is a special case to just return the path as no scaling,
- // rotating, nor compressing needs to be done
- if (this.targetHeight == -1 && this.targetWidth == -1 &&
- (destType == FILE_URI || destType == NATIVE_URI) && !this.correctOrientation &&
- mimeType.equalsIgnoreCase(getMimetypeForFormat(encodingType)))
- {
- this.callbackContext.success(uriString);
+ String uriString = uri.toString();
+ String finalLocation = fileLocation != null ? fileLocation : uriString;
+ String mimeTypeOfGalleryFile = FileHelper.getMimeType(uriString, this.cordova);
+
+ if (finalLocation == null) {
+ this.failPicture("Error retrieving result.");
+ } else {
+ // If you ask for video or the selected file cannot be processed
+ // there will be no attempt to resize any returned data.
+ if (this.mediaType == VIDEO || !isImageMimeTypeProcessable(mimeTypeOfGalleryFile)) {
+ this.callbackContext.success(finalLocation);
} else {
- // If we don't have a valid image so quit.
- if (!("image/jpeg".equalsIgnoreCase(mimeType) || "image/png".equalsIgnoreCase(mimeType))) {
- LOG.d(LOG_TAG, "I either have a null image path or bitmap");
- this.failPicture("Unable to retrieve path to picture!");
- return;
- }
- Bitmap bitmap = null;
- try {
- bitmap = getScaledAndRotatedBitmap(uriString);
- } catch (IOException e) {
- e.printStackTrace();
- }
- if (bitmap == null) {
- LOG.d(LOG_TAG, "I either have a null image path or bitmap");
- this.failPicture("Unable to create bitmap!");
- return;
- }
- // If sending base64 image back
- if (destType == DATA_URL) {
- this.processPicture(bitmap, this.encodingType);
- }
+ // This is a special case to just return the path as no scaling,
+ // rotating, nor compressing needs to be done
+ if (this.targetHeight == -1 && this.targetWidth == -1 &&
+ destType == FILE_URI && !this.correctOrientation &&
+ getMimetypeForEncodingType().equalsIgnoreCase(mimeTypeOfGalleryFile))
+ {
+ this.callbackContext.success(finalLocation);
+ } else {
+ Bitmap bitmap = null;
+ try {
+ bitmap = getScaledAndRotatedBitmap(uriString);
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ if (bitmap == null) {
+ LOG.d(LOG_TAG, "I either have a null image path or bitmap");
+ this.failPicture("Unable to create bitmap!");
+ return;
+ }
- // If sending filename back
- else if (destType == FILE_URI || destType == NATIVE_URI) {
- // Did we modify the image?
- if ( (this.targetHeight > 0 && this.targetWidth > 0) ||
- (this.correctOrientation && this.orientationCorrected) ||
- !mimeType.equalsIgnoreCase(getMimetypeForFormat(encodingType)))
- {
- try {
- String modifiedPath = this.outputModifiedBitmap(bitmap, uri);
- // The modified image is cached by the app in order to get around this and not have to delete you
- // application cache I'm adding the current system time to the end of the file url.
- this.callbackContext.success("file://" + modifiedPath + "?" + System.currentTimeMillis());
-
- } catch (Exception e) {
- e.printStackTrace();
- this.failPicture("Error retrieving image.");
+ // If sending base64 image back
+ if (destType == DATA_URL) {
+ this.processPicture(bitmap, this.encodingType);
+ }
+
+ // If sending filename back
+ else if (destType == FILE_URI) {
+ // Did we modify the image?
+ if ( (this.targetHeight > 0 && this.targetWidth > 0) ||
+ (this.correctOrientation && this.orientationCorrected) ||
+ !mimeTypeOfGalleryFile.equalsIgnoreCase(getMimetypeForEncodingType()))
+ {
+ try {
+ String modifiedPath = this.outputModifiedBitmap(bitmap, uri, mimeTypeOfGalleryFile);
+ // The modified image is cached by the app in order to get around this and not have to delete you
+ // application cache I'm adding the current system time to the end of the file url.
+ this.callbackContext.success("file://" + modifiedPath + "?" + System.currentTimeMillis());
+
+ } catch (Exception e) {
+ e.printStackTrace();
+ this.failPicture("Error retrieving image: "+e.getLocalizedMessage());
+ }
+ } else {
+ this.callbackContext.success(finalLocation);
}
- } else {
- this.callbackContext.success(fileLocation);
}
+ if (bitmap != null) {
+ bitmap.recycle();
+ bitmap = null;
+ }
+ System.gc();
}
- if (bitmap != null) {
- bitmap.recycle();
- bitmap = null;
- }
- System.gc();
}
}
+
+ }
+
+ /**
+ * JPEG, PNG and HEIC mime types (images) can be scaled, decreased in quantity, corrected by orientation.
+ * But f.e. an image/gif cannot be scaled, but is can be selected through the PHOTOLIBRARY.
+ *
+ * @param mimeType The mimeType to check
+ * @return if the mimeType is a processable image mime type
+ */
+ private boolean isImageMimeTypeProcessable(String mimeType) {
+ return JPEG_MIME_TYPE.equalsIgnoreCase(mimeType) || PNG_MIME_TYPE.equalsIgnoreCase(mimeType)
+ || HEIC_MIME_TYPE.equalsIgnoreCase(mimeType);
}
/**
@@ -801,7 +870,7 @@ else if (srcType == CAMERA) {
try {
if (this.allowEdit) {
Uri tmpFile = FileProvider.getUriForFile(cordova.getActivity(),
- applicationId + ".provider",
+ applicationId + ".cordova.plugin.camera.provider",
createCaptureFile(this.encodingType));
performCrop(tmpFile, destType, intent);
} else {
@@ -809,7 +878,7 @@ else if (srcType == CAMERA) {
}
} catch (IOException e) {
e.printStackTrace();
- this.failPicture("Error capturing image.");
+ this.failPicture("Error capturing image: "+e.getLocalizedMessage());
}
}
@@ -900,34 +969,11 @@ private void writeUncompressedImage(InputStream fis, Uri dest) throws FileNotFou
private void writeUncompressedImage(Uri src, Uri dest) throws FileNotFoundException,
IOException {
- FileInputStream fis = new FileInputStream(FileHelper.stripFileProtocol(src.toString()));
+ InputStream fis = FileHelper.getInputStreamFromUriString(src.toString(), cordova);
writeUncompressedImage(fis, dest);
}
- /**
- * Create entry in media store for image
- *
- * @return uri
- */
- private Uri getUriFromMediaStore() {
- ContentValues values = new ContentValues();
- values.put(android.provider.MediaStore.Images.Media.MIME_TYPE, "image/jpeg");
- Uri uri;
- try {
- uri = this.cordova.getActivity().getContentResolver().insert(android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values);
- } catch (RuntimeException e) {
- LOG.d(LOG_TAG, "Can't write to external media storage.");
- try {
- uri = this.cordova.getActivity().getContentResolver().insert(android.provider.MediaStore.Images.Media.INTERNAL_CONTENT_URI, values);
- } catch (RuntimeException ex) {
- LOG.d(LOG_TAG, "Can't write to internal media storage.");
- return null;
- }
- }
- return uri;
- }
-
/**
* Return a scaled and rotated bitmap based on the target width and height
*
@@ -975,19 +1021,20 @@ private Bitmap getScaledAndRotatedBitmap(String imageUrl) throws IOException {
InputStream fileStream = FileHelper.getInputStreamFromUriString(imageUrl, cordova);
if (fileStream != null) {
// Generate a temporary file
- String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
- String fileName = "IMG_" + timeStamp + (this.encodingType == JPEG ? ".jpg" : ".png");
+ String timeStamp = new SimpleDateFormat(TIME_FORMAT).format(new Date());
+ String fileName = "IMG_" + timeStamp + (getExtensionForEncodingType());
localFile = new File(getTempDirectoryPath() + fileName);
galleryUri = Uri.fromFile(localFile);
writeUncompressedImage(fileStream, galleryUri);
try {
String mimeType = FileHelper.getMimeType(imageUrl.toString(), cordova);
- if ("image/jpeg".equalsIgnoreCase(mimeType)) {
+ if (JPEG_MIME_TYPE.equalsIgnoreCase(mimeType)) {
// ExifInterface doesn't like the file:// prefix
String filePath = galleryUri.toString().replace("file://", "");
// read exifData of source
exifData = new ExifHelper();
exifData.createInFile(filePath);
+ exifData.readExifData();
// Use ExifInterface to pull rotation information
if (this.correctOrientation) {
ExifInterface exif = new ExifInterface(filePath);
@@ -999,15 +1046,11 @@ private Bitmap getScaledAndRotatedBitmap(String imageUrl) throws IOException {
rotate = 0;
}
}
- }
- catch (Exception e)
- {
+ } catch (Exception e) {
LOG.e(LOG_TAG,"Exception while getting input stream: "+ e.toString());
return null;
}
-
-
try {
// figure out the original width and height of the image
BitmapFactory.Options options = new BitmapFactory.Options();
@@ -1053,7 +1096,6 @@ private Bitmap getScaledAndRotatedBitmap(String imageUrl) throws IOException {
// determine the correct aspect ratio
int[] widthHeight = calculateAspectRatio(rotatedWidth, rotatedHeight);
-
// Load in the smallest bitmap possible that is closest to the size we want
options.inJustDecodeBounds = false;
options.inSampleSize = calculateSampleSize(rotatedWidth, rotatedHeight, widthHeight[0], widthHeight[1]);
@@ -1093,8 +1135,7 @@ private Bitmap getScaledAndRotatedBitmap(String imageUrl) throws IOException {
}
}
return scaledBitmap;
- }
- finally {
+ } finally {
// delete the temporary copy
if (localFile != null) {
localFile.delete();
@@ -1227,6 +1268,7 @@ private void checkForDuplicateImage(int type) {
// delete the duplicate file if the difference is 2 for file URI or 1 for Data URL
if ((currentNumOfImages - numPics) == diff) {
cursor.moveToLast();
+ @SuppressLint("Range")
int id = Integer.valueOf(cursor.getString(cursor.getColumnIndex(MediaStore.Images.Media._ID)));
if (diff == 2) {
id--;
@@ -1244,9 +1286,9 @@ private void checkForDuplicateImage(int type) {
*/
private Uri whichContentStore() {
if (Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED)) {
- return android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI;
+ return MediaStore.Images.Media.EXTERNAL_CONTENT_URI;
} else {
- return android.provider.MediaStore.Images.Media.INTERNAL_CONTENT_URI;
+ return MediaStore.Images.Media.INTERNAL_CONTENT_URI;
}
}
@@ -1257,9 +1299,7 @@ private Uri whichContentStore() {
*/
public void processPicture(Bitmap bitmap, int encodingType) {
ByteArrayOutputStream jpeg_data = new ByteArrayOutputStream();
- CompressFormat compressFormat = encodingType == JPEG ?
- CompressFormat.JPEG :
- CompressFormat.PNG;
+ CompressFormat compressFormat = getCompressFormatForEncodingType(encodingType);
try {
if (bitmap.compress(compressFormat, mQuality, jpeg_data)) {
@@ -1272,7 +1312,7 @@ public void processPicture(Bitmap bitmap, int encodingType) {
code = null;
}
} catch (Exception e) {
- this.failPicture("Error compressing image.");
+ this.failPicture("Error compressing image: "+e.getLocalizedMessage());
}
jpeg_data = null;
}
@@ -1298,7 +1338,7 @@ private void scanForGallery(Uri newImage) {
public void onMediaScannerConnected() {
try {
this.conn.scanFile(this.scanMe.toString(), "image/*");
- } catch (java.lang.IllegalStateException e) {
+ } catch (IllegalStateException e) {
LOG.e(LOG_TAG, "Can't scan file in MediaScanner after taking picture");
}
@@ -1308,9 +1348,8 @@ public void onScanCompleted(String path, Uri uri) {
this.conn.disconnect();
}
-
public void onRequestPermissionResult(int requestCode, String[] permissions,
- int[] grantResults) throws JSONException {
+ int[] grantResults) {
for (int r : grantResults) {
if (r == PackageManager.PERMISSION_DENIED) {
this.callbackContext.sendPluginResult(new PluginResult(PluginResult.Status.ERROR, PERMISSION_DENIED_ERROR));
@@ -1322,7 +1361,7 @@ public void onRequestPermissionResult(int requestCode, String[] permissions,
takePicture(this.destType, this.encodingType);
break;
case SAVE_TO_ALBUM_SEC:
- this.getImage(this.srcType, this.destType, this.encodingType);
+ this.getImage(this.srcType, this.destType);
break;
}
}
@@ -1347,11 +1386,15 @@ public Bundle onSaveInstanceState() {
state.putBoolean("saveToPhotoAlbum", this.saveToPhotoAlbum);
if (this.croppedUri != null) {
- state.putString("croppedUri", this.croppedUri.toString());
+ state.putString(CROPPED_URI_KEY, this.croppedFilePath);
}
if (this.imageUri != null) {
- state.putString("imageUri", this.imageUri.getFileUri().toString());
+ state.putString(IMAGE_URI_KEY, this.imageFilePath);
+ }
+
+ if (this.imageFilePath != null) {
+ state.putString(IMAGE_FILE_PATH_KEY, this.imageFilePath);
}
return state;
@@ -1370,38 +1413,28 @@ public void onRestoreStateForActivityResult(Bundle state, CallbackContext callba
this.correctOrientation = state.getBoolean("correctOrientation");
this.saveToPhotoAlbum = state.getBoolean("saveToPhotoAlbum");
- if (state.containsKey("croppedUri")) {
- this.croppedUri = Uri.parse(state.getString("croppedUri"));
+ if (state.containsKey(CROPPED_URI_KEY)) {
+ this.croppedUri = Uri.parse(state.getString(CROPPED_URI_KEY));
}
- if (state.containsKey("imageUri")) {
+ if (state.containsKey(IMAGE_URI_KEY)) {
//I have no idea what type of URI is being passed in
- this.imageUri = new CordovaUri(Uri.parse(state.getString("imageUri")));
+ this.imageUri = Uri.parse(state.getString(IMAGE_URI_KEY));
+ }
+
+ if (state.containsKey(IMAGE_FILE_PATH_KEY)) {
+ this.imageFilePath = state.getString(IMAGE_FILE_PATH_KEY);
}
this.callbackContext = callbackContext;
}
- /*
- * This is dirty, but it does the job.
- *
- * Since the FilesProvider doesn't really provide you a way of getting a URL from the file,
- * and since we actually need the Camera to create the file for us most of the time, we don't
- * actually write the file, just generate the location based on a timestamp, we need to get it
- * back from the Intent.
- *
- * However, the FilesProvider preserves the path, so we can at least write to it from here, since
- * we own the context in this case.
- */
-
- private String getFileNameFromUri(Uri uri) {
- String fullUri = uri.toString();
- String partial_path = fullUri.split("external_files")[1];
- File external_storage = Environment.getExternalStorageDirectory();
- String path = external_storage.getAbsolutePath() + partial_path;
- return path;
-
+ private boolean hasPermissions(String[] permissions) {
+ for (String permission: permissions) {
+ if (!PermissionHelper.hasPermission(this, permission)) {
+ return false;
+ }
+ }
+ return true;
}
-
-
}
diff --git a/src/android/CordovaUri.java b/src/android/CordovaUri.java
deleted file mode 100644
index 56e388667..000000000
--- a/src/android/CordovaUri.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
-*/
-
-package org.apache.cordova.camera;
-
-import android.net.Uri;
-import android.os.Build;
-import android.os.Environment;
-import androidx.core.content.FileProvider;
-
-import java.io.File;
-
-/*
- * This class exists because Andorid FilesProvider doesn't work on Android 4.4.4 and below and throws
- * weird errors. I'm not sure why writing to shared cache directories is somehow verboten, but it is
- * and this error is irritating for a Compatibility library to have.
- *
- */
-
-public class CordovaUri {
-
- private Uri androidUri;
- private String fileName;
- private Uri fileUri;
-
- /*
- * We always expect a FileProvider string to be passed in for the file that we create
- *
- */
- CordovaUri (Uri inputUri)
- {
- //Determine whether the file is a content or file URI
- if(inputUri.getScheme().equals("content"))
- {
- androidUri = inputUri;
- fileName = getFileNameFromUri(androidUri);
- fileUri = Uri.parse("file://" + fileName);
- }
- else
- {
- fileUri = inputUri;
- fileName = FileHelper.stripFileProtocol(inputUri.toString());
- }
- }
-
- public Uri getFileUri()
- {
- return fileUri;
- }
-
- public String getFilePath()
- {
- return fileName;
- }
-
- /*
- * This only gets called by takePicture
- */
-
- public Uri getCorrectUri()
- {
- if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.M)
- return androidUri;
- else
- return fileUri;
- }
-
- /*
- * This is dirty, but it does the job.
- *
- * Since the FilesProvider doesn't really provide you a way of getting a URL from the file,
- * and since we actually need the Camera to create the file for us most of the time, we don't
- * actually write the file, just generate the location based on a timestamp, we need to get it
- * back from the Intent.
- *
- * However, the FilesProvider preserves the path, so we can at least write to it from here, since
- * we own the context in this case.
- */
-
- private String getFileNameFromUri(Uri uri) {
- String fullUri = uri.toString();
- String partial_path = fullUri.split("external_files")[1];
- File external_storage = Environment.getExternalStorageDirectory();
- String path = external_storage.getAbsolutePath() + partial_path;
- return path;
-
- }
-}
diff --git a/src/android/FileHelper.java b/src/android/FileHelper.java
index ccc5e3e75..b9abf8765 100644
--- a/src/android/FileHelper.java
+++ b/src/android/FileHelper.java
@@ -19,7 +19,6 @@ Licensed to the Apache Software Foundation (ASF) under one
import android.annotation.SuppressLint;
import android.content.ContentUris;
import android.content.Context;
-import android.content.CursorLoader;
import android.database.Cursor;
import android.net.Uri;
import android.os.Build;
@@ -29,8 +28,8 @@ Licensed to the Apache Software Foundation (ASF) under one
import android.webkit.MimeTypeMap;
import org.apache.cordova.CordovaInterface;
-import org.apache.cordova.LOG;
+import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
@@ -44,29 +43,20 @@ public class FileHelper {
* Returns the real path of the given URI string.
* If the given URI string represents a content:// URI, the real path is retrieved from the media store.
*
- * @param uriString the URI string of the audio/image/video
+ * @param uri the URI of the audio/image/video
* @param cordova the current application context
* @return the full path to the file
*/
@SuppressWarnings("deprecation")
public static String getRealPath(Uri uri, CordovaInterface cordova) {
- String realPath = null;
-
- if (Build.VERSION.SDK_INT < 11)
- realPath = FileHelper.getRealPathFromURI_BelowAPI11(cordova.getActivity(), uri);
-
- // SDK >= 11
- else
- realPath = FileHelper.getRealPathFromURI_API11_And_Above(cordova.getActivity(), uri);
-
- return realPath;
+ return FileHelper.getRealPathFromURI(cordova.getActivity(), uri);
}
/**
* Returns the real path of the given URI.
* If the given URI is a content:// URI, the real path is retrieved from the media store.
*
- * @param uri the URI of the audio/image/video
+ * @param uriString the URI string from which to obtain the input stream
* @param cordova the current application context
* @return the full path to the file
*/
@@ -75,11 +65,9 @@ public static String getRealPath(String uriString, CordovaInterface cordova) {
}
@SuppressLint("NewApi")
- public static String getRealPathFromURI_API11_And_Above(final Context context, final Uri uri) {
-
- final boolean isKitKat = Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT;
+ public static String getRealPathFromURI(final Context context, final Uri uri) {
// DocumentProvider
- if (isKitKat && DocumentsContract.isDocumentUri(context, uri)) {
+ if (DocumentsContract.isDocumentUri(context, uri)) {
// ExternalStorageProvider
if (isExternalStorageDocument(uri)) {
@@ -97,10 +85,21 @@ public static String getRealPathFromURI_API11_And_Above(final Context context, f
else if (isDownloadsDocument(uri)) {
final String id = DocumentsContract.getDocumentId(uri);
- final Uri contentUri = ContentUris.withAppendedId(
- Uri.parse("content://downloads/public_downloads"), Long.valueOf(id));
-
- return getDataColumn(context, contentUri, null, null);
+ if (id != null && id.length() > 0) {
+ if (id.startsWith("raw:")) {
+ return id.replaceFirst("raw:", "");
+ }
+ try {
+ final Uri contentUri = ContentUris.withAppendedId(
+ Uri.parse("content://downloads/public_downloads"), Long.valueOf(id));
+
+ return getDataColumn(context, contentUri, null, null);
+ } catch (NumberFormatException e) {
+ return null;
+ }
+ } else {
+ return null;
+ }
}
// MediaProvider
else if (isMediaDocument(uri)) {
@@ -132,6 +131,9 @@ else if ("content".equalsIgnoreCase(uri.getScheme())) {
if (isGooglePhotosUri(uri))
return uri.getLastPathSegment();
+ if (isFileProviderUri(context, uri))
+ return getFileProviderPath(context, uri);
+
return getDataColumn(context, uri, null, null);
}
// File
@@ -142,22 +144,6 @@ else if ("file".equalsIgnoreCase(uri.getScheme())) {
return null;
}
- public static String getRealPathFromURI_BelowAPI11(Context context, Uri contentUri) {
- String[] proj = { MediaStore.Images.Media.DATA };
- String result = null;
-
- try {
- Cursor cursor = context.getContentResolver().query(contentUri, proj, null, null, null);
- int column_index = cursor.getColumnIndexOrThrow(MediaStore.Images.Media.DATA);
- cursor.moveToFirst();
- result = cursor.getString(column_index);
-
- } catch (Exception e) {
- result = null;
- }
- return result;
- }
-
/**
* Returns an input stream based on given URI string.
*
@@ -177,6 +163,7 @@ public static InputStream getInputStreamFromUriString(String uriString, CordovaI
if (question > -1) {
uriString = uriString.substring(0, question);
}
+
if (uriString.startsWith("file:///android_asset/")) {
Uri uri = Uri.parse(uriString);
String relativePath = uri.getPath().substring(15);
@@ -206,6 +193,7 @@ public static InputStream getInputStreamFromUriString(String uriString, CordovaI
* @return a path without the "file://" prefix
*/
public static String stripFileProtocol(String uriString) {
+
if (uriString.startsWith("file://")) {
uriString = uriString.substring(7);
}
@@ -225,7 +213,7 @@ public static String getMimeTypeForExtension(String path) {
}
return MimeTypeMap.getSingleton().getMimeTypeFromExtension(extension);
}
-
+
/**
* Returns the mime type of the data specified by the given URI string.
*
@@ -233,7 +221,7 @@ public static String getMimeTypeForExtension(String path) {
* @return the mime type of the specified data
*/
public static String getMimeType(String uriString, CordovaInterface cordova) {
- String mimeType = null;
+ String mimeType;
Uri uri = Uri.parse(uriString);
if (uriString.startsWith("content://")) {
@@ -316,4 +304,28 @@ public static boolean isMediaDocument(Uri uri) {
public static boolean isGooglePhotosUri(Uri uri) {
return "com.google.android.apps.photos.content".equals(uri.getAuthority());
}
+
+ /**
+ * @param context The Application context
+ * @param uri The Uri is checked by functions
+ * @return Whether the Uri authority is FileProvider
+ */
+ public static boolean isFileProviderUri(final Context context, final Uri uri) {
+ final String packageName = context.getPackageName();
+ final String authority = new StringBuilder(packageName).append(".provider").toString();
+ return authority.equals(uri.getAuthority());
+ }
+
+ /**
+ * @param context The Application context
+ * @param uri The Uri is checked by functions
+ * @return File path or null if file is missing
+ */
+ public static String getFileProviderPath(final Context context, final Uri uri)
+ {
+ final File appDir = context.getExternalFilesDir(Environment.DIRECTORY_PICTURES);
+ final File file = new File(appDir, uri.getLastPathSegment());
+ return file.exists() ? file.toString(): null;
+ }
+
}
diff --git a/src/android/GalleryPathVO.java b/src/android/GalleryPathVO.java
new file mode 100644
index 000000000..579044327
--- /dev/null
+++ b/src/android/GalleryPathVO.java
@@ -0,0 +1,43 @@
+/*
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+*/
+package org.apache.cordova.camera;
+
+public class GalleryPathVO {
+ private final String galleryPath;
+ private String picturesDirectory;
+ private String galleryFileName;
+
+ public GalleryPathVO(String picturesDirectory, String galleryFileName) {
+ this.picturesDirectory = picturesDirectory;
+ this.galleryFileName = galleryFileName;
+ this.galleryPath = this.picturesDirectory + "/" + this.galleryFileName;
+ }
+
+ public String getGalleryPath() {
+ return galleryPath;
+ }
+
+ public String getPicturesDirectory() {
+ return picturesDirectory;
+ }
+
+ public String getGalleryFileName() {
+ return galleryFileName;
+ }
+}
diff --git a/src/android/xml/camera_provider_paths.xml b/src/android/xml/camera_provider_paths.xml
index 2db87bdbd..326674847 100644
--- a/src/android/xml/camera_provider_paths.xml
+++ b/src/android/xml/camera_provider_paths.xml
@@ -17,5 +17,5 @@
-->
-
+
\ No newline at end of file
diff --git a/src/browser/CameraProxy.js b/src/browser/CameraProxy.js
index 38f241f9f..104c64f8f 100644
--- a/src/browser/CameraProxy.js
+++ b/src/browser/CameraProxy.js
@@ -19,13 +19,13 @@
*
*/
-var HIGHEST_POSSIBLE_Z_INDEX = 2147483647;
+const HIGHEST_POSSIBLE_Z_INDEX = 2147483647;
function takePicture (success, error, opts) {
if (opts && opts[2] === 1) {
capture(success, error, opts);
} else {
- var input = document.createElement('input');
+ const input = document.createElement('input');
input.style.position = 'relative';
input.style.zIndex = HIGHEST_POSSIBLE_Z_INDEX;
input.className = 'cordova-camera-select';
@@ -33,11 +33,11 @@ function takePicture (success, error, opts) {
input.name = 'files[]';
input.onchange = function (inputEvent) {
- var reader = new FileReader(); /* eslint no-undef : 0 */
+ const reader = new FileReader(); /* eslint no-undef : 0 */
reader.onload = function (readerEvent) {
input.parentNode.removeChild(input);
- var imageData = readerEvent.target.result;
+ const imageData = readerEvent.target.result;
return success(imageData.substr(imageData.indexOf(',') + 1));
};
@@ -50,16 +50,16 @@ function takePicture (success, error, opts) {
}
function capture (success, errorCallback, opts) {
- var localMediaStream;
- var targetWidth = opts[3];
- var targetHeight = opts[4];
+ let localMediaStream;
+ let targetWidth = opts[3];
+ let targetHeight = opts[4];
targetWidth = targetWidth === -1 ? 320 : targetWidth;
targetHeight = targetHeight === -1 ? 240 : targetHeight;
- var video = document.createElement('video');
- var button = document.createElement('button');
- var parent = document.createElement('div');
+ const video = document.createElement('video');
+ const button = document.createElement('button');
+ const parent = document.createElement('div');
parent.style.position = 'relative';
parent.style.zIndex = HIGHEST_POSSIBLE_Z_INDEX;
parent.className = 'cordova-camera-capture';
@@ -72,13 +72,13 @@ function capture (success, errorCallback, opts) {
button.onclick = function () {
// create a canvas and capture a frame from video stream
- var canvas = document.createElement('canvas');
+ const canvas = document.createElement('canvas');
canvas.width = targetWidth;
canvas.height = targetHeight;
canvas.getContext('2d').drawImage(video, 0, 0, targetWidth, targetHeight);
// convert image stored in canvas to base64 encoded image
- var imageData = canvas.toDataURL('image/png');
+ let imageData = canvas.toDataURL('image/png');
imageData = imageData.replace('data:image/png;base64,', '');
// stop video stream, remove video and button.
@@ -100,23 +100,30 @@ function capture (success, errorCallback, opts) {
navigator.mozGetUserMedia ||
navigator.msGetUserMedia;
- var successCallback = function (stream) {
+ const successCallback = function (stream) {
localMediaStream = stream;
- video.src = window.URL.createObjectURL(localMediaStream);
+ if ('srcObject' in video) {
+ video.srcObject = localMediaStream;
+ } else {
+ video.src = window.URL.createObjectURL(localMediaStream);
+ }
video.play();
-
document.body.appendChild(parent);
};
- if (navigator.getUserMedia) {
- navigator.getUserMedia({video: true, audio: true}, successCallback, errorCallback);
+ if (navigator.mediaDevices.getUserMedia) {
+ navigator.mediaDevices.getUserMedia({ video: true, audio: false })
+ .then(successCallback)
+ .catch(errorCallback);
+ } else if (navigator.getUserMedia) {
+ navigator.getUserMedia({ video: true, audio: false }, successCallback, errorCallback);
} else {
alert('Browser does not support camera :(');
}
}
module.exports = {
- takePicture: takePicture,
+ takePicture,
cleanup: function () {}
};
diff --git a/src/ios/CDVCamera.h b/src/ios/CDVCamera.h
index f64f66c27..647ffab19 100644
--- a/src/ios/CDVCamera.h
+++ b/src/ios/CDVCamera.h
@@ -24,8 +24,7 @@
enum CDVDestinationType {
DestinationTypeDataUrl = 0,
- DestinationTypeFileUri,
- DestinationTypeNativeUri
+ DestinationTypeFileUri
};
typedef NSUInteger CDVDestinationType;
diff --git a/src/ios/CDVCamera.m b/src/ios/CDVCamera.m
index aef76f956..6793da45b 100644
--- a/src/ios/CDVCamera.m
+++ b/src/ios/CDVCamera.m
@@ -29,6 +29,7 @@ Licensed to the Apache Software Foundation (ASF) under one
#import
#import
#import
+#import
#ifndef __CORDOVA_4_0_0
#import
@@ -139,11 +140,9 @@ - (BOOL)popoverSupported
- (void)takePicture:(CDVInvokedUrlCommand*)command
{
self.hasPendingOperation = YES;
-
__weak CDVCamera* weakSelf = self;
[self.commandDelegate runInBackground:^{
-
CDVPictureOptions* pictureOptions = [CDVPictureOptions createFromTakePictureArguments:command];
pictureOptions.popoverSupported = [weakSelf popoverSupported];
pictureOptions.usesGeolocation = [weakSelf usesGeolocation];
@@ -158,82 +157,93 @@ - (void)takePicture:(CDVInvokedUrlCommand*)command
}
// Validate the app has permission to access the camera
- if (pictureOptions.sourceType == UIImagePickerControllerSourceTypeCamera && [AVCaptureDevice respondsToSelector:@selector(authorizationStatusForMediaType:)]) {
- AVAuthorizationStatus authStatus = [AVCaptureDevice authorizationStatusForMediaType:AVMediaTypeVideo];
- if (authStatus == AVAuthorizationStatusDenied ||
- authStatus == AVAuthorizationStatusRestricted) {
- // If iOS 8+, offer a link to the Settings app
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wtautological-pointer-compare"
- NSString* settingsButton = (&UIApplicationOpenSettingsURLString != NULL)
- ? NSLocalizedString(@"Settings", nil)
- : nil;
-#pragma clang diagnostic pop
-
- // Denied; show an alert
- dispatch_async(dispatch_get_main_queue(), ^{
- [[[UIAlertView alloc] initWithTitle:[[NSBundle mainBundle]
- objectForInfoDictionaryKey:@"CFBundleDisplayName"]
- message:NSLocalizedString(@"Access to the camera has been prohibited; please enable it in the Settings app to continue.", nil)
- delegate:weakSelf
- cancelButtonTitle:NSLocalizedString(@"OK", nil)
- otherButtonTitles:settingsButton, nil] show];
- });
- }
+ if (pictureOptions.sourceType == UIImagePickerControllerSourceTypeCamera) {
+ [AVCaptureDevice requestAccessForMediaType:AVMediaTypeVideo completionHandler:^(BOOL granted)
+ {
+ if (!granted)
+ {
+ // Denied; show an alert
+ dispatch_async(dispatch_get_main_queue(), ^{
+ UIAlertController *alertController = [UIAlertController alertControllerWithTitle:[[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleDisplayName"] message:NSLocalizedString(@"Access to the camera has been prohibited; please enable it in the Settings app to continue.", nil) preferredStyle:UIAlertControllerStyleAlert];
+ [alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil) style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
+ [weakSelf sendNoPermissionResult:command.callbackId];
+ }]];
+ [alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Settings", nil) style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
+ [[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString] options:@{} completionHandler:nil];
+ [weakSelf sendNoPermissionResult:command.callbackId];
+ }]];
+ [weakSelf.viewController presentViewController:alertController animated:YES completion:nil];
+ });
+ } else {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [weakSelf showCameraPicker:command.callbackId withOptions:pictureOptions];
+ });
+ }
+ }];
+ } else {
+ [weakSelf options:pictureOptions requestPhotoPermissions:^(BOOL granted) {
+ if (!granted) {
+ // Denied; show an alert
+ dispatch_async(dispatch_get_main_queue(), ^{
+ UIAlertController *alertController = [UIAlertController alertControllerWithTitle:[[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleDisplayName"] message:NSLocalizedString(@"Access to the camera roll has been prohibited; please enable it in the Settings to continue.", nil) preferredStyle:UIAlertControllerStyleAlert];
+ [alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil) style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
+ [weakSelf sendNoPermissionResult:command.callbackId];
+ }]];
+ [alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Settings", nil) style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
+ [[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
+ [weakSelf sendNoPermissionResult:command.callbackId];
+ }]];
+ [weakSelf.viewController presentViewController:alertController animated:YES completion:nil];
+ });
+ } else {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [weakSelf showCameraPicker:command.callbackId withOptions:pictureOptions];
+ });
+ }
+ }];
}
+ }];
+}
+- (void)showCameraPicker:(NSString*)callbackId withOptions:(CDVPictureOptions *) pictureOptions
+{
+ // Perform UI operations on the main thread
+ dispatch_async(dispatch_get_main_queue(), ^{
CDVCameraPicker* cameraPicker = [CDVCameraPicker createFromPictureOptions:pictureOptions];
- weakSelf.pickerController = cameraPicker;
+ self.pickerController = cameraPicker;
- cameraPicker.delegate = weakSelf;
- cameraPicker.callbackId = command.callbackId;
+ cameraPicker.delegate = self;
+ cameraPicker.callbackId = callbackId;
// we need to capture this state for memory warnings that dealloc this object
- cameraPicker.webView = weakSelf.webView;
-
- // Perform UI operations on the main thread
- dispatch_async(dispatch_get_main_queue(), ^{
- // If a popover is already open, close it; we only want one at a time.
- if (([[weakSelf pickerController] pickerPopoverController] != nil) && [[[weakSelf pickerController] pickerPopoverController] isPopoverVisible]) {
- [[[weakSelf pickerController] pickerPopoverController] dismissPopoverAnimated:YES];
- [[[weakSelf pickerController] pickerPopoverController] setDelegate:nil];
- [[weakSelf pickerController] setPickerPopoverController:nil];
- }
+ cameraPicker.webView = self.webView;
- if ([weakSelf popoverSupported] && (pictureOptions.sourceType != UIImagePickerControllerSourceTypeCamera)) {
- if (cameraPicker.pickerPopoverController == nil) {
- cameraPicker.pickerPopoverController = [[NSClassFromString(@"UIPopoverController") alloc] initWithContentViewController:cameraPicker];
- }
- [weakSelf displayPopover:pictureOptions.popoverOptions];
- weakSelf.hasPendingOperation = NO;
- } else {
- cameraPicker.modalPresentationStyle = UIModalPresentationCurrentContext;
- [weakSelf.viewController presentViewController:cameraPicker animated:YES completion:^{
- weakSelf.hasPendingOperation = NO;
- }];
+ // If a popover is already open, close it; we only want one at a time.
+ if (([[self pickerController] pickerPopoverController] != nil) && [[[self pickerController] pickerPopoverController] isPopoverVisible]) {
+ [[[self pickerController] pickerPopoverController] dismissPopoverAnimated:YES];
+ [[[self pickerController] pickerPopoverController] setDelegate:nil];
+ [[self pickerController] setPickerPopoverController:nil];
+ }
+
+ if ([self popoverSupported] && (pictureOptions.sourceType != UIImagePickerControllerSourceTypeCamera)) {
+ if (cameraPicker.pickerPopoverController == nil) {
+ cameraPicker.pickerPopoverController = [[NSClassFromString(@"UIPopoverController") alloc] initWithContentViewController:cameraPicker];
}
- });
- }];
+ [self displayPopover:pictureOptions.popoverOptions];
+ self.hasPendingOperation = NO;
+ } else {
+ cameraPicker.modalPresentationStyle = UIModalPresentationCurrentContext;
+ [self.viewController presentViewController:cameraPicker animated:YES completion:^{
+ self.hasPendingOperation = NO;
+ }];
+ }
+ });
}
-// Delegate for camera permission UIAlertView
-- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex
+- (void)sendNoPermissionResult:(NSString*)callbackId
{
- // If Settings button (on iOS 8), open the settings app
- if (buttonIndex == 1) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wtautological-pointer-compare"
- if (&UIApplicationOpenSettingsURLString != NULL) {
- [[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
- }
-#pragma clang diagnostic pop
- }
-
- // Dismiss the view
- [[self.pickerController presentingViewController] dismissViewControllerAnimated:YES completion:nil];
-
CDVPluginResult* result = [CDVPluginResult resultWithStatus:CDVCommandStatus_ERROR messageAsString:@"has no access to camera"]; // error callback expects string ATM
- [self.commandDelegate sendPluginResult:result callbackId:self.pickerController.callbackId];
+ [self.commandDelegate sendPluginResult:result callbackId:callbackId];
self.hasPendingOperation = NO;
self.pickerController = nil;
@@ -291,8 +301,21 @@ - (void)displayPopover:(NSDictionary*)options
- (void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated
{
if([navigationController isKindOfClass:[UIImagePickerController class]]){
- UIImagePickerController* cameraPicker = (UIImagePickerController*)navigationController;
+ // If popoverWidth and popoverHeight are specified and are greater than 0, then set popover size, else use apple's default popoverSize
+ NSDictionary* options = self.pickerController.pictureOptions.popoverOptions;
+ if(options) {
+ NSInteger popoverWidth = [self integerValueForKey:options key:@"popoverWidth" defaultValue:0];
+ NSInteger popoverHeight = [self integerValueForKey:options key:@"popoverHeight" defaultValue:0];
+ if(popoverWidth > 0 && popoverHeight > 0)
+ {
+ [viewController setPreferredContentSize:CGSizeMake(popoverWidth,popoverHeight)];
+ }
+ }
+
+
+ UIImagePickerController* cameraPicker = (UIImagePickerController*)navigationController;
+
if(![cameraPicker.mediaTypes containsObject:(NSString*)kUTTypeImage]){
[viewController.navigationItem setTitle:NSLocalizedString(@"Videos", nil)];
}
@@ -352,7 +375,7 @@ - (void)popoverControllerDidDismissPopover:(id)popoverController
- (NSData*)processImage:(UIImage*)image info:(NSDictionary*)info options:(CDVPictureOptions*)options
{
NSData* data = nil;
-
+
switch (options.encodingType) {
case EncodingTypePNG:
data = UIImagePNGRepresentation(image);
@@ -365,45 +388,141 @@ - (NSData*)processImage:(UIImage*)image info:(NSDictionary*)info options:(CDVPic
} else {
data = UIImageJPEGRepresentation(image, [options.quality floatValue] / 100.0f);
}
-
- if (options.usesGeolocation) {
- NSDictionary* controllerMetadata = [info objectForKey:@"UIImagePickerControllerMediaMetadata"];
+
+ if (pickerController.sourceType == UIImagePickerControllerSourceTypeCamera) {
+ if (options.usesGeolocation) {
+ NSDictionary* controllerMetadata = [info objectForKey:@"UIImagePickerControllerMediaMetadata"];
+ if (controllerMetadata) {
+ self.data = data;
+ self.metadata = [[NSMutableDictionary alloc] init];
+
+ NSMutableDictionary* EXIFDictionary = [[controllerMetadata objectForKey:(NSString*)kCGImagePropertyExifDictionary]mutableCopy];
+ if (EXIFDictionary) {
+ [self.metadata setObject:EXIFDictionary forKey:(NSString*)kCGImagePropertyExifDictionary];
+ }
+
+ if (IsAtLeastiOSVersion(@"8.0")) {
+ [[self locationManager] performSelector:NSSelectorFromString(@"requestWhenInUseAuthorization") withObject:nil afterDelay:0];
+ }
+ [[self locationManager] startUpdatingLocation];
+ }
+ data = nil;
+ }
+ } else if (pickerController.sourceType == UIImagePickerControllerSourceTypePhotoLibrary) {
+ PHAsset* asset = [info objectForKey:@"UIImagePickerControllerPHAsset"];
+ NSDictionary* controllerMetadata = [self getImageMetadataFromAsset:asset];
+
+ self.data = data;
if (controllerMetadata) {
- self.data = data;
self.metadata = [[NSMutableDictionary alloc] init];
-
+
NSMutableDictionary* EXIFDictionary = [[controllerMetadata objectForKey:(NSString*)kCGImagePropertyExifDictionary]mutableCopy];
- if (EXIFDictionary) {
+ if (EXIFDictionary) {
[self.metadata setObject:EXIFDictionary forKey:(NSString*)kCGImagePropertyExifDictionary];
}
-
- if (IsAtLeastiOSVersion(@"8.0")) {
- [[self locationManager] performSelector:NSSelectorFromString(@"requestWhenInUseAuthorization") withObject:nil afterDelay:0];
+ NSMutableDictionary* TIFFDictionary = [[controllerMetadata objectForKey:(NSString*)kCGImagePropertyTIFFDictionary
+ ]mutableCopy];
+ if (TIFFDictionary) {
+ [self.metadata setObject:TIFFDictionary forKey:(NSString*)kCGImagePropertyTIFFDictionary];
+ }
+ NSMutableDictionary* GPSDictionary = [[controllerMetadata objectForKey:(NSString*)kCGImagePropertyGPSDictionary
+]mutableCopy];
+ if (GPSDictionary) {
+ [self.metadata setObject:GPSDictionary forKey:(NSString*)kCGImagePropertyGPSDictionary
+];
}
- [[self locationManager] startUpdatingLocation];
}
}
+
}
break;
default:
break;
};
-
+
return data;
}
+/* --------------------------------------------------------------
+-- get the metadata of the image from a PHAsset
+-------------------------------------------------------------- */
+- (NSDictionary*)getImageMetadataFromAsset:(PHAsset*)asset {
+
+ if(asset == nil) {
+ return nil;
+ }
+
+ // get photo info from this asset
+ __block NSDictionary *dict = nil;
+ PHImageRequestOptions *imageRequestOptions = [[PHImageRequestOptions alloc] init];
+ imageRequestOptions.synchronous = YES;
+ [[PHImageManager defaultManager]
+ requestImageDataForAsset:asset
+ options:imageRequestOptions
+ resultHandler: ^(NSData *imageData, NSString *dataUTI, UIImageOrientation orientation, NSDictionary *info) {
+ dict = [self convertImageMetadata:imageData]; // as this imageData is in NSData format so we need a method to convert this NSData into NSDictionary
+ }];
+ return dict;
+}
+
+-(NSDictionary*)convertImageMetadata:(NSData*)imageData {
+ CGImageSourceRef imageSource = CGImageSourceCreateWithData((__bridge CFDataRef)(imageData), NULL);
+ if (imageSource) {
+ NSDictionary *options = @{(NSString *)kCGImageSourceShouldCache : [NSNumber numberWithBool:NO]};
+ CFDictionaryRef imageProperties = CGImageSourceCopyPropertiesAtIndex(imageSource, 0, (__bridge CFDictionaryRef)options);
+ if (imageProperties) {
+ NSDictionary *metadata = (__bridge NSDictionary *)imageProperties;
+ CFRelease(imageProperties);
+ CFRelease(imageSource);
+ NSLog(@"Metadata of selected image%@", metadata);// image metadata after converting NSData into NSDictionary
+ return metadata;
+ }
+ CFRelease(imageSource);
+ }
+
+ NSLog(@"Can't read image metadata");
+ return nil;
+}
+
+- (void)options:(CDVPictureOptions*)options requestPhotoPermissions:(void (^)(BOOL auth))completion
+{
+ if((unsigned long)options.sourceType == 1){
+ completion(YES);
+ }
+ else{
+ PHAuthorizationStatus status = [PHPhotoLibrary authorizationStatus];
+
+ switch (status) {
+ case PHAuthorizationStatusAuthorized:
+ completion(YES);
+ break;
+ case PHAuthorizationStatusNotDetermined: {
+ [PHPhotoLibrary requestAuthorization:^(PHAuthorizationStatus authorizationStatus) {
+ if (authorizationStatus == PHAuthorizationStatusAuthorized) {
+ completion(YES);
+ } else {
+ completion(NO);
+ }
+ }];
+ break;
+ }
+ default:
+ completion(NO);
+ break;
+ }
+
+ }
+
+}
+
- (NSString*)tempFilePath:(NSString*)extension
{
NSString* docsPath = [NSTemporaryDirectory()stringByStandardizingPath];
- NSFileManager* fileMgr = [[NSFileManager alloc] init]; // recommended by Apple (vs [NSFileManager defaultManager]) to be threadsafe
- NSString* filePath;
-
- // generate unique file name
- int i = 1;
- do {
- filePath = [NSString stringWithFormat:@"%@/%@%03d.%@", docsPath, CDV_PHOTO_PREFIX, i++, extension];
- } while ([fileMgr fileExistsAtPath:filePath]);
-
+ // unique file name
+ NSTimeInterval timeStamp = [[NSDate date] timeIntervalSince1970];
+ NSNumber *timeStampObj = [NSNumber numberWithDouble: timeStamp];
+ NSString* filePath = [NSString stringWithFormat:@"%@/%@%ld.%@", docsPath, CDV_PHOTO_PREFIX, [timeStampObj longValue], extension];
+
return filePath;
}
@@ -416,13 +535,13 @@ - (UIImage*)retrieveImage:(NSDictionary*)info options:(CDVPictureOptions*)option
} else {
image = [info objectForKey:UIImagePickerControllerOriginalImage];
}
-
+
if (options.correctOrientation) {
image = [image imageCorrectedForCaptureOrientation];
}
-
+
UIImage* scaledImage = nil;
-
+
if ((options.targetSize.width > 0) && (options.targetSize.height > 0)) {
// if cropToSize, resize image and crop to target size, otherwise resize to fit target without cropping
if (options.cropToSize) {
@@ -431,7 +550,7 @@ - (UIImage*)retrieveImage:(NSDictionary*)info options:(CDVPictureOptions*)option
scaledImage = [image imageByScalingNotCroppingForSize:options.targetSize];
}
}
-
+
return (scaledImage == nil ? image : scaledImage);
}
@@ -442,67 +561,69 @@ - (void)resultForImage:(CDVPictureOptions*)options info:(NSDictionary*)info comp
UIImage* image = nil;
switch (options.destinationType) {
- case DestinationTypeNativeUri:
- {
- NSURL* url = [info objectForKey:UIImagePickerControllerReferenceURL];
- saveToPhotoAlbum = NO;
- // If, for example, we use sourceType = Camera, URL might be nil because image is stored in memory.
- // In this case we must save image to device before obtaining an URI.
- if (url == nil) {
- image = [self retrieveImage:info options:options];
- ALAssetsLibrary* library = [ALAssetsLibrary new];
- [library writeImageToSavedPhotosAlbum:image.CGImage orientation:(ALAssetOrientation)(image.imageOrientation) completionBlock:^(NSURL *assetURL, NSError *error) {
- CDVPluginResult* resultToReturn = nil;
- if (error) {
- resultToReturn = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[error localizedDescription]];
- } else {
- NSString* nativeUri = [[self urlTransformer:assetURL] absoluteString];
- resultToReturn = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:nativeUri];
- }
- completion(resultToReturn);
- }];
- return;
- } else {
- NSString* nativeUri = [[self urlTransformer:url] absoluteString];
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:nativeUri];
- }
- }
- break;
- case DestinationTypeFileUri:
+ case DestinationTypeDataUrl:
{
image = [self retrieveImage:info options:options];
NSData* data = [self processImage:image info:info options:options];
- if (data) {
-
- NSString* extension = options.encodingType == EncodingTypePNG? @"png" : @"jpg";
- NSString* filePath = [self tempFilePath:extension];
- NSError* err = nil;
-
- // save file
- if (![data writeToFile:filePath options:NSAtomicWrite error:&err]) {
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[err localizedDescription]];
- } else {
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:[[self urlTransformer:[NSURL fileURLWithPath:filePath]] absoluteString]];
- }
+ if (data) {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:toBase64(data)];
}
}
break;
- case DestinationTypeDataUrl:
+ default: // DestinationTypeFileUri
{
image = [self retrieveImage:info options:options];
NSData* data = [self processImage:image info:info options:options];
- if (data) {
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:toBase64(data)];
+ if (data) {
+ if (pickerController.sourceType == UIImagePickerControllerSourceTypePhotoLibrary) {
+ NSMutableData *imageDataWithExif = [NSMutableData data];
+ if (self.metadata) {
+ CGImageSourceRef sourceImage = CGImageSourceCreateWithData((__bridge CFDataRef)self.data, NULL);
+ CFStringRef sourceType = CGImageSourceGetType(sourceImage);
+
+ CGImageDestinationRef destinationImage = CGImageDestinationCreateWithData((__bridge CFMutableDataRef)imageDataWithExif, sourceType, 1, NULL);
+ CGImageDestinationAddImageFromSource(destinationImage, sourceImage, 0, (__bridge CFDictionaryRef)self.metadata);
+ CGImageDestinationFinalize(destinationImage);
+
+ CFRelease(sourceImage);
+ CFRelease(destinationImage);
+ } else {
+ imageDataWithExif = [self.data mutableCopy];
+ }
+
+ NSError* err = nil;
+ NSString* extension = self.pickerController.pictureOptions.encodingType == EncodingTypePNG ? @"png":@"jpg";
+ NSString* filePath = [self tempFilePath:extension];
+
+ // save file
+ if (![imageDataWithExif writeToFile:filePath options:NSAtomicWrite error:&err]) {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[err localizedDescription]];
+ }
+ else {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:[[self urlTransformer:[NSURL fileURLWithPath:filePath]] absoluteString]];
+ }
+
+ } else if (pickerController.sourceType != UIImagePickerControllerSourceTypeCamera || !options.usesGeolocation) {
+ // No need to save file if usesGeolocation is true since it will be saved after the location is tracked
+ NSString* extension = options.encodingType == EncodingTypePNG? @"png" : @"jpg";
+ NSString* filePath = [self tempFilePath:extension];
+ NSError* err = nil;
+
+ // save file
+ if (![data writeToFile:filePath options:NSAtomicWrite error:&err]) {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[err localizedDescription]];
+ } else {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:[[self urlTransformer:[NSURL fileURLWithPath:filePath]] absoluteString]];
+ }
+ }
+
}
}
break;
- default:
- break;
};
-
+
if (saveToPhotoAlbum && image) {
- ALAssetsLibrary* library = [ALAssetsLibrary new];
- [library writeImageToSavedPhotosAlbum:image.CGImage orientation:(ALAssetOrientation)(image.imageOrientation) completionBlock:nil];
+ UIImageWriteToSavedPhotosAlbum(image, nil, nil, nil);
}
completion(result);
@@ -511,17 +632,30 @@ - (void)resultForImage:(CDVPictureOptions*)options info:(NSDictionary*)info comp
- (CDVPluginResult*)resultForVideo:(NSDictionary*)info
{
NSString* moviePath = [[info objectForKey:UIImagePickerControllerMediaURL] absoluteString];
+ // On iOS 13 the movie path becomes inaccessible, create and return a copy
+ if (IsAtLeastiOSVersion(@"13.0")) {
+ moviePath = [self createTmpVideo:[[info objectForKey:UIImagePickerControllerMediaURL] path]];
+ }
return [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:moviePath];
}
+- (NSString *) createTmpVideo:(NSString *) moviePath {
+ NSString* moviePathExtension = [moviePath pathExtension];
+ NSString* copyMoviePath = [self tempFilePath:moviePathExtension];
+ NSFileManager* fileMgr = [[NSFileManager alloc] init];
+ NSError *error;
+ [fileMgr copyItemAtPath:moviePath toPath:copyMoviePath error:&error];
+ return [[NSURL fileURLWithPath:copyMoviePath] absoluteString];
+}
+
- (void)imagePickerController:(UIImagePickerController*)picker didFinishPickingMediaWithInfo:(NSDictionary*)info
{
__weak CDVCameraPicker* cameraPicker = (CDVCameraPicker*)picker;
__weak CDVCamera* weakSelf = self;
-
+
dispatch_block_t invoke = ^(void) {
__block CDVPluginResult* result = nil;
-
+
NSString* mediaType = [info objectForKey:UIImagePickerControllerMediaType];
if ([mediaType isEqualToString:(NSString*)kUTTypeImage]) {
[weakSelf resultForImage:cameraPicker.pictureOptions info:info completion:^(CDVPluginResult* res) {
@@ -539,7 +673,7 @@ - (void)imagePickerController:(UIImagePickerController*)picker didFinishPickingM
weakSelf.pickerController = nil;
}
};
-
+
if (cameraPicker.pictureOptions.popoverSupported && (cameraPicker.pickerPopoverController != nil)) {
[cameraPicker.pickerPopoverController dismissPopoverAnimated:YES];
cameraPicker.pickerPopoverController.delegate = nil;
@@ -562,20 +696,18 @@ - (void)imagePickerControllerDidCancel:(UIImagePickerController*)picker
{
__weak CDVCameraPicker* cameraPicker = (CDVCameraPicker*)picker;
__weak CDVCamera* weakSelf = self;
-
+
dispatch_block_t invoke = ^ (void) {
CDVPluginResult* result;
- if (picker.sourceType == UIImagePickerControllerSourceTypeCamera && [AVCaptureDevice authorizationStatusForMediaType:AVMediaTypeVideo] != ALAuthorizationStatusAuthorized) {
+ if (picker.sourceType == UIImagePickerControllerSourceTypeCamera && [AVCaptureDevice authorizationStatusForMediaType:AVMediaTypeVideo] != AVAuthorizationStatusAuthorized) {
result = [CDVPluginResult resultWithStatus:CDVCommandStatus_ERROR messageAsString:@"has no access to camera"];
- } else if (picker.sourceType != UIImagePickerControllerSourceTypeCamera && [ALAssetsLibrary authorizationStatus] != ALAuthorizationStatusAuthorized) {
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_ERROR messageAsString:@"has no access to assets"];
} else {
result = [CDVPluginResult resultWithStatus:CDVCommandStatus_ERROR messageAsString:@"No Image Selected"];
}
-
+
[weakSelf.commandDelegate sendPluginResult:result callbackId:cameraPicker.callbackId];
-
+
weakSelf.hasPendingOperation = NO;
weakSelf.pickerController = nil;
};
@@ -585,15 +717,15 @@ - (void)imagePickerControllerDidCancel:(UIImagePickerController*)picker
- (CLLocationManager*)locationManager
{
- if (locationManager != nil) {
- return locationManager;
- }
-
- locationManager = [[CLLocationManager alloc] init];
- [locationManager setDesiredAccuracy:kCLLocationAccuracyNearestTenMeters];
- [locationManager setDelegate:self];
-
- return locationManager;
+ if (locationManager != nil) {
+ return locationManager;
+ }
+
+ locationManager = [[CLLocationManager alloc] init];
+ [locationManager setDesiredAccuracy:kCLLocationAccuracyNearestTenMeters];
+ [locationManager setDelegate:self];
+
+ return locationManager;
}
- (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocation*)newLocation fromLocation:(CLLocation*)oldLocation
@@ -601,15 +733,15 @@ - (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocat
if (locationManager == nil) {
return;
}
-
+
[self.locationManager stopUpdatingLocation];
self.locationManager = nil;
-
+
NSMutableDictionary *GPSDictionary = [[NSMutableDictionary dictionary] init];
-
+
CLLocationDegrees latitude = newLocation.coordinate.latitude;
CLLocationDegrees longitude = newLocation.coordinate.longitude;
-
+
// latitude
if (latitude < 0.0) {
latitude = latitude * -1.0f;
@@ -618,7 +750,7 @@ - (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocat
[GPSDictionary setObject:@"N" forKey:(NSString*)kCGImagePropertyGPSLatitudeRef];
}
[GPSDictionary setObject:[NSNumber numberWithFloat:latitude] forKey:(NSString*)kCGImagePropertyGPSLatitude];
-
+
// longitude
if (longitude < 0.0) {
longitude = longitude * -1.0f;
@@ -628,7 +760,7 @@ - (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocat
[GPSDictionary setObject:@"E" forKey:(NSString*)kCGImagePropertyGPSLongitudeRef];
}
[GPSDictionary setObject:[NSNumber numberWithFloat:longitude] forKey:(NSString*)kCGImagePropertyGPSLongitude];
-
+
// altitude
CGFloat altitude = newLocation.altitude;
if (!isnan(altitude)){
@@ -640,7 +772,7 @@ - (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocat
}
[GPSDictionary setObject:[NSNumber numberWithFloat:altitude] forKey:(NSString *)kCGImagePropertyGPSAltitude];
}
-
+
// Time and date
NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
[formatter setDateFormat:@"HH:mm:ss.SSSSSS"];
@@ -648,7 +780,7 @@ - (void)locationManager:(CLLocationManager*)manager didUpdateToLocation:(CLLocat
[GPSDictionary setObject:[formatter stringFromDate:newLocation.timestamp] forKey:(NSString *)kCGImagePropertyGPSTimeStamp];
[formatter setDateFormat:@"yyyy:MM:dd"];
[GPSDictionary setObject:[formatter stringFromDate:newLocation.timestamp] forKey:(NSString *)kCGImagePropertyGPSDateStamp];
-
+
[self.metadata setObject:GPSDictionary forKey:(NSString *)kCGImagePropertyGPSDictionary];
[self imagePickerControllerReturnImageResult];
}
@@ -661,7 +793,7 @@ - (void)locationManager:(CLLocationManager*)manager didFailWithError:(NSError*)e
[self.locationManager stopUpdatingLocation];
self.locationManager = nil;
-
+
[self imagePickerControllerReturnImageResult];
}
@@ -669,26 +801,37 @@ - (void)imagePickerControllerReturnImageResult
{
CDVPictureOptions* options = self.pickerController.pictureOptions;
CDVPluginResult* result = nil;
-
+
+ NSMutableData *imageDataWithExif = [NSMutableData data];
+
if (self.metadata) {
- CGImageSourceRef sourceImage = CGImageSourceCreateWithData((__bridge CFDataRef)self.data, NULL);
+ NSData* dataCopy = [self.data mutableCopy];
+ CGImageSourceRef sourceImage = CGImageSourceCreateWithData((__bridge CFDataRef)dataCopy, NULL);
CFStringRef sourceType = CGImageSourceGetType(sourceImage);
-
- CGImageDestinationRef destinationImage = CGImageDestinationCreateWithData((__bridge CFMutableDataRef)self.data, sourceType, 1, NULL);
+
+ CGImageDestinationRef destinationImage = CGImageDestinationCreateWithData((__bridge CFMutableDataRef)imageDataWithExif, sourceType, 1, NULL);
CGImageDestinationAddImageFromSource(destinationImage, sourceImage, 0, (__bridge CFDictionaryRef)self.metadata);
CGImageDestinationFinalize(destinationImage);
-
+
+ dataCopy = nil;
CFRelease(sourceImage);
CFRelease(destinationImage);
+ } else {
+ imageDataWithExif = [self.data mutableCopy];
}
-
+
switch (options.destinationType) {
- case DestinationTypeFileUri:
+ case DestinationTypeDataUrl:
+ {
+ result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:toBase64(self.data)];
+ }
+ break;
+ default: // DestinationTypeFileUri
{
NSError* err = nil;
NSString* extension = self.pickerController.pictureOptions.encodingType == EncodingTypePNG ? @"png":@"jpg";
NSString* filePath = [self tempFilePath:extension];
-
+
// save file
if (![self.data writeToFile:filePath options:NSAtomicWrite error:&err]) {
result = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[err localizedDescription]];
@@ -698,28 +841,19 @@ - (void)imagePickerControllerReturnImageResult
}
}
break;
- case DestinationTypeDataUrl:
- {
- result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsString:toBase64(self.data)];
- }
- break;
- case DestinationTypeNativeUri:
- default:
- break;
};
-
+
if (result) {
[self.commandDelegate sendPluginResult:result callbackId:self.pickerController.callbackId];
}
-
+
self.hasPendingOperation = NO;
self.pickerController = nil;
self.data = nil;
self.metadata = nil;
-
+ imageDataWithExif = nil;
if (options.saveToPhotoAlbum) {
- ALAssetsLibrary *library = [ALAssetsLibrary new];
- [library writeImageDataToSavedPhotosAlbum:self.data metadata:self.metadata completionBlock:nil];
+ UIImageWriteToSavedPhotosAlbum([[UIImage alloc] initWithData:self.data], nil, nil, nil);
}
}
@@ -736,14 +870,14 @@ - (UIViewController*)childViewControllerForStatusBarHidden
{
return nil;
}
-
+
- (void)viewWillAppear:(BOOL)animated
{
SEL sel = NSSelectorFromString(@"setNeedsStatusBarAppearanceUpdate");
if ([self respondsToSelector:sel]) {
[self performSelector:sel withObject:nil afterDelay:0];
}
-
+
[super viewWillAppear:animated];
}
@@ -753,7 +887,7 @@ + (instancetype) createFromPictureOptions:(CDVPictureOptions*)pictureOptions;
cameraPicker.pictureOptions = pictureOptions;
cameraPicker.sourceType = pictureOptions.sourceType;
cameraPicker.allowsEditing = pictureOptions.allowsEditing;
-
+
if (cameraPicker.sourceType == UIImagePickerControllerSourceTypeCamera) {
// We only allow taking pictures (no video) in this API.
cameraPicker.mediaTypes = @[(NSString*)kUTTypeImage];
@@ -765,7 +899,7 @@ + (instancetype) createFromPictureOptions:(CDVPictureOptions*)pictureOptions;
NSArray* mediaArray = @[(NSString*)(pictureOptions.mediaType == MediaTypeVideo ? kUTTypeMovie : kUTTypeImage)];
cameraPicker.mediaTypes = mediaArray;
}
-
+
return cameraPicker;
}
diff --git a/src/osx/CDVCamera.h b/src/osx/CDVCamera.h
deleted file mode 100644
index 310d1923f..000000000
--- a/src/osx/CDVCamera.h
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
- */
-#import
-#import
-#import
-
-
-
-enum CDVDestinationType {
- DestinationTypeDataUrl = 0,
- DestinationTypeFileUri,
- DestinationTypeNativeUri
-};
-typedef NSUInteger CDVDestinationType;
-
-enum CDVSourceType {
- SourceTypePhotoLibrary = 0,
- SourceTypeCamera,
- SourceTypePhotoAlbum
-};
-typedef NSUInteger CDVSourceType;
-
-enum CDVEncodingType {
- EncodingTypeJPEG = 0,
- EncodingTypePNG
-};
-typedef NSUInteger CDVEncodingType;
-
-enum CDVMediaType {
- MediaTypePicture = 0,
- MediaTypeVideo,
- MediaTypeAll
-};
-typedef NSUInteger CDVMediaType;
-
-
-// ======================================================================= //
-
-
-@interface CDVPictureOptions : NSObject
-
-@property (strong) NSNumber *quality;
-@property (assign) CDVDestinationType destinationType;
-@property (assign) CDVSourceType sourceType;
-@property (assign) CGSize targetSize;
-@property (assign) CDVEncodingType encodingType;
-@property (assign) CDVMediaType mediaType;
-@property (assign) BOOL allowsEditing;
-@property (assign) BOOL correctOrientation;
-@property (assign) BOOL saveToPhotoAlbum;
-
-+ (instancetype) createFromTakePictureArguments:(CDVInvokedUrlCommand *)command;
-
-@end
-
-
-// ======================================================================= //
-
-
-@interface CDVCamera : CDVPlugin
-
-- (void)takePicture:(CDVInvokedUrlCommand *)command;
-- (void)cleanup:(CDVInvokedUrlCommand *)command;
-
-@end
diff --git a/src/osx/CDVCamera.m b/src/osx/CDVCamera.m
deleted file mode 100644
index 9693eefb8..000000000
--- a/src/osx/CDVCamera.m
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
- */
-#import "CDVCamera.h"
-
-
-@implementation CDVPictureOptions
-
-+ (instancetype) createFromTakePictureArguments:(CDVInvokedUrlCommand*)command {
- CDVPictureOptions *pictureOptions = [[CDVPictureOptions alloc] init];
-
- pictureOptions.quality = [command argumentAtIndex:0 withDefault:@(50)];
- pictureOptions.destinationType = [[command argumentAtIndex:1 withDefault:@(DestinationTypeFileUri)] unsignedIntegerValue];
- pictureOptions.sourceType = [[command argumentAtIndex:2 withDefault:@(SourceTypeCamera)] unsignedIntegerValue];
-
- NSNumber *targetWidth = [command argumentAtIndex:3 withDefault:nil];
- NSNumber *targetHeight = [command argumentAtIndex:4 withDefault:nil];
- pictureOptions.targetSize = CGSizeMake(0, 0);
- if ((targetWidth != nil) && (targetHeight != nil)) {
- pictureOptions.targetSize = CGSizeMake([targetWidth floatValue], [targetHeight floatValue]);
- }
-
- pictureOptions.encodingType = [[command argumentAtIndex:5 withDefault:@(EncodingTypeJPEG)] unsignedIntegerValue];
- pictureOptions.mediaType = [[command argumentAtIndex:6 withDefault:@(MediaTypePicture)] unsignedIntegerValue];
- pictureOptions.allowsEditing = [[command argumentAtIndex:7 withDefault:@(NO)] boolValue];
- pictureOptions.correctOrientation = [[command argumentAtIndex:8 withDefault:@(NO)] boolValue];
- pictureOptions.saveToPhotoAlbum = [[command argumentAtIndex:9 withDefault:@(NO)] boolValue];
-
- return pictureOptions;
-}
-
-@end
-
-
-// ======================================================================= //
-
-
-@implementation CDVCamera
-
-/*!
- Static array that stores the temporary created files allowing to delete them when calling navigator.camera.cleanup(...)
- */
-static NSMutableArray *cleanUpFiles;
-
-+ (void)initialize {
- cleanUpFiles = [NSMutableArray array];
-}
-
-- (void)takePicture:(CDVInvokedUrlCommand *)command {
- CDVPictureOptions *pictureOptions = [CDVPictureOptions createFromTakePictureArguments:command];
- if (pictureOptions.sourceType == SourceTypeCamera) {
- [self takePictureFromCamera:command withOptions:pictureOptions];
- } else {
- [self takePictureFromFile:command withOptions:pictureOptions];
- }
-}
-
-- (void)cleanup:(CDVInvokedUrlCommand*)command {
- [self.commandDelegate runInBackground:^{
- if (cleanUpFiles.count > 0) {
- for (int i=0; i 0 && pictureOptions.targetSize.height > 0) {
- sourceImage = [self resizeImage:sourceImage toSize:pictureOptions.targetSize];
- }
-
- CGImageRef cgRef = [sourceImage CGImageForProposedRect:NULL context:nil hints:nil];
- NSBitmapImageRep *imageRepresentation = [[NSBitmapImageRep alloc] initWithCGImage:cgRef];
-
- NSData *data = (pictureOptions.encodingType == EncodingTypeJPEG)
- ? [imageRepresentation representationUsingType:NSJPEGFileType properties:@{NSImageCompressionFactor: [NSNumber numberWithFloat:pictureOptions.quality.floatValue/100.f]}]
- : [imageRepresentation representationUsingType:NSPNGFileType properties:@{NSImageCompressionFactor: @1.0}];
-
- return data;
-}
-
-/*!
- Auxiliar method to resize an image.
- */
-- (NSImage *)resizeImage:(NSImage *)image toSize:(CGSize)newSize {
- CGFloat aspectWidth = newSize.width / image.size.width;
- CGFloat aspectHeight = newSize.height / image.size.height;
- CGFloat aspectRatio = MIN(aspectWidth, aspectHeight);
-
- CGSize scaledSize = NSMakeSize(image.size.width*aspectRatio, image.size.height*aspectRatio);
-
- NSImage *smallImage = [[NSImage alloc] initWithSize: scaledSize];
- [smallImage lockFocus];
- [image setSize: scaledSize];
- [[NSGraphicsContext currentContext] setImageInterpolation:NSImageInterpolationHigh];
- [image drawAtPoint:NSZeroPoint fromRect:CGRectMake(0, 0, scaledSize.width, scaledSize.height) operation:NSCompositeCopy fraction:1.0];
- [smallImage unlockFocus];
- return smallImage;
-}
-
-/*!
- Auxiliar method to know if a given file is an image or not.
- */
-- (BOOL)fileIsImage:(NSURL *)fileURL {
- NSString *type;
- BOOL isImage = NO;
-
- if ([fileURL getResourceValue:&type forKey:NSURLTypeIdentifierKey error:nil]) {
- isImage = [[NSImage imageTypes] containsObject:type];
- }
-
- return isImage;
-}
-
-/*!
- Auxiliar method that generates an unique filename for an image in the temporary directory.
- */
-- (NSString *)uniqueImageName:(CDVPictureOptions *)pictureOptions {
- NSString *tempDir = NSTemporaryDirectory();
- NSString *guid = [[NSProcessInfo processInfo] globallyUniqueString] ;
- NSString *extension = (pictureOptions.encodingType == EncodingTypeJPEG) ? @"jpeg" : @"png";
- NSString *uniqueFileName = [NSString stringWithFormat:@"%@%@.%@", tempDir, guid, extension];
- return uniqueFileName;
-}
-
-@end
\ No newline at end of file
diff --git a/src/windows/CameraProxy.js b/src/windows/CameraProxy.js
deleted file mode 100644
index e20d28d61..000000000
--- a/src/windows/CameraProxy.js
+++ /dev/null
@@ -1,867 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-/* global Windows:true, URL:true, module:true, require:true, WinJS:true */
-
-var Camera = require('./Camera');
-
-var getAppData = function () {
- return Windows.Storage.ApplicationData.current;
-};
-var encodeToBase64String = function (buffer) {
- return Windows.Security.Cryptography.CryptographicBuffer.encodeToBase64String(buffer);
-};
-var OptUnique = Windows.Storage.CreationCollisionOption.generateUniqueName;
-var CapMSType = Windows.Media.Capture.MediaStreamType;
-var webUIApp = Windows.UI.WebUI.WebUIApplication;
-var fileIO = Windows.Storage.FileIO;
-var pickerLocId = Windows.Storage.Pickers.PickerLocationId;
-
-module.exports = {
-
- // args will contain :
- // ... it is an array, so be careful
- // 0 quality:50,
- // 1 destinationType:Camera.DestinationType.FILE_URI,
- // 2 sourceType:Camera.PictureSourceType.CAMERA,
- // 3 targetWidth:-1,
- // 4 targetHeight:-1,
- // 5 encodingType:Camera.EncodingType.JPEG,
- // 6 mediaType:Camera.MediaType.PICTURE,
- // 7 allowEdit:false,
- // 8 correctOrientation:false,
- // 9 saveToPhotoAlbum:false,
- // 10 popoverOptions:null
- // 11 cameraDirection:0
-
- takePicture: function (successCallback, errorCallback, args) {
- var sourceType = args[2];
-
- if (sourceType !== Camera.PictureSourceType.CAMERA) {
- takePictureFromFile(successCallback, errorCallback, args);
- } else {
- takePictureFromCamera(successCallback, errorCallback, args);
- }
- }
-};
-
-// https://msdn.microsoft.com/en-us/library/windows/apps/ff462087(v=vs.105).aspx
-var windowsVideoContainers = ['.avi', '.flv', '.asx', '.asf', '.mov', '.mp4', '.mpg', '.rm', '.srt', '.swf', '.wmv', '.vob'];
-var windowsPhoneVideoContainers = ['.avi', '.3gp', '.3g2', '.wmv', '.3gp', '.3g2', '.mp4', '.m4v'];
-
-// Default aspect ratio 1.78 (16:9 hd video standard)
-var DEFAULT_ASPECT_RATIO = '1.8';
-
-// Highest possible z-index supported across browsers. Anything used above is converted to this value.
-var HIGHEST_POSSIBLE_Z_INDEX = 2147483647;
-
-// Resize method
-function resizeImage (successCallback, errorCallback, file, targetWidth, targetHeight, encodingType) {
- var tempPhotoFileName = '';
- var targetContentType = '';
-
- if (encodingType === Camera.EncodingType.PNG) {
- tempPhotoFileName = 'camera_cordova_temp_return.png';
- targetContentType = 'image/png';
- } else {
- tempPhotoFileName = 'camera_cordova_temp_return.jpg';
- targetContentType = 'image/jpeg';
- }
-
- var storageFolder = getAppData().localFolder;
- file.copyAsync(storageFolder, file.name, Windows.Storage.NameCollisionOption.replaceExisting)
- .then(function (storageFile) {
- return fileIO.readBufferAsync(storageFile);
- })
- .then(function (buffer) {
- var strBase64 = encodeToBase64String(buffer);
- var imageData = 'data:' + file.contentType + ';base64,' + strBase64;
- var image = new Image(); /* eslint no-undef : 0 */
- image.src = imageData;
- image.onload = function () {
- var ratio = Math.min(targetWidth / this.width, targetHeight / this.height);
- var imageWidth = ratio * this.width;
- var imageHeight = ratio * this.height;
-
- var canvas = document.createElement('canvas');
- var storageFileName;
-
- canvas.width = imageWidth;
- canvas.height = imageHeight;
-
- canvas.getContext('2d').drawImage(this, 0, 0, imageWidth, imageHeight);
-
- var fileContent = canvas.toDataURL(targetContentType).split(',')[1];
-
- var storageFolder = getAppData().localFolder;
-
- storageFolder.createFileAsync(tempPhotoFileName, OptUnique)
- .then(function (storagefile) {
- var content = Windows.Security.Cryptography.CryptographicBuffer.decodeFromBase64String(fileContent);
- storageFileName = storagefile.name;
- return fileIO.writeBufferAsync(storagefile, content);
- })
- .done(function () {
- successCallback('ms-appdata:///local/' + storageFileName);
- }, errorCallback);
- };
- })
- .done(null, function (err) {
- errorCallback(err);
- });
-}
-
-// Because of asynchronous method, so let the successCallback be called in it.
-function resizeImageBase64 (successCallback, errorCallback, file, targetWidth, targetHeight) {
- fileIO.readBufferAsync(file).done(function (buffer) {
- var strBase64 = encodeToBase64String(buffer);
- var imageData = 'data:' + file.contentType + ';base64,' + strBase64;
-
- var image = new Image(); /* eslint no-undef : 0 */
- image.src = imageData;
-
- image.onload = function () {
- var ratio = Math.min(targetWidth / this.width, targetHeight / this.height);
- var imageWidth = ratio * this.width;
- var imageHeight = ratio * this.height;
- var canvas = document.createElement('canvas');
-
- canvas.width = imageWidth;
- canvas.height = imageHeight;
-
- var ctx = canvas.getContext('2d');
- ctx.drawImage(this, 0, 0, imageWidth, imageHeight);
-
- // The resized file ready for upload
- var finalFile = canvas.toDataURL(file.contentType);
-
- // Remove the prefix such as "data:" + contentType + ";base64," , in order to meet the Cordova API.
- var arr = finalFile.split(',');
- var newStr = finalFile.substr(arr[0].length + 1);
- successCallback(newStr);
- };
- }, function (err) { errorCallback(err); });
-}
-
-function takePictureFromFile (successCallback, errorCallback, args) {
- // Detect Windows Phone
- if (navigator.appVersion.indexOf('Windows Phone 8.1') >= 0) {
- takePictureFromFileWP(successCallback, errorCallback, args);
- } else {
- takePictureFromFileWindows(successCallback, errorCallback, args);
- }
-}
-
-function takePictureFromFileWP (successCallback, errorCallback, args) {
- var mediaType = args[6];
- var destinationType = args[1];
- var targetWidth = args[3];
- var targetHeight = args[4];
- var encodingType = args[5];
-
- /*
- Need to add and remove an event listener to catch activation state
- Using FileOpenPicker will suspend the app and it's required to catch the PickSingleFileAndContinue
- https://msdn.microsoft.com/en-us/library/windows/apps/xaml/dn631755.aspx
- */
- var filePickerActivationHandler = function (eventArgs) {
- if (eventArgs.kind === Windows.ApplicationModel.Activation.ActivationKind.pickFileContinuation) {
- var file = eventArgs.files[0];
- if (!file) {
- errorCallback("User didn't choose a file.");
- webUIApp.removeEventListener('activated', filePickerActivationHandler);
- return;
- }
- if (destinationType === Camera.DestinationType.FILE_URI || destinationType === Camera.DestinationType.NATIVE_URI) {
- if (targetHeight > 0 && targetWidth > 0) {
- resizeImage(successCallback, errorCallback, file, targetWidth, targetHeight, encodingType);
- } else {
- var storageFolder = getAppData().localFolder;
- file.copyAsync(storageFolder, file.name, Windows.Storage.NameCollisionOption.replaceExisting).done(function (storageFile) {
- if (destinationType === Camera.DestinationType.NATIVE_URI) {
- successCallback('ms-appdata:///local/' + storageFile.name);
- } else {
- successCallback(URL.createObjectURL(storageFile));
- }
- }, function () {
- errorCallback("Can't access localStorage folder.");
- });
- }
- } else {
- if (targetHeight > 0 && targetWidth > 0) {
- resizeImageBase64(successCallback, errorCallback, file, targetWidth, targetHeight);
- } else {
- fileIO.readBufferAsync(file).done(function (buffer) {
- var strBase64 = encodeToBase64String(buffer);
- successCallback(strBase64);
- }, errorCallback);
- }
- }
- webUIApp.removeEventListener('activated', filePickerActivationHandler);
- }
- };
-
- var fileOpenPicker = new Windows.Storage.Pickers.FileOpenPicker();
- if (mediaType === Camera.MediaType.PICTURE) {
- fileOpenPicker.fileTypeFilter.replaceAll(['.png', '.jpg', '.jpeg']);
- fileOpenPicker.suggestedStartLocation = pickerLocId.picturesLibrary;
- } else if (mediaType === Camera.MediaType.VIDEO) {
- fileOpenPicker.fileTypeFilter.replaceAll(windowsPhoneVideoContainers);
- fileOpenPicker.suggestedStartLocation = pickerLocId.videosLibrary;
- } else {
- fileOpenPicker.fileTypeFilter.replaceAll(['*']);
- fileOpenPicker.suggestedStartLocation = pickerLocId.documentsLibrary;
- }
-
- webUIApp.addEventListener('activated', filePickerActivationHandler);
- fileOpenPicker.pickSingleFileAndContinue();
-}
-
-function takePictureFromFileWindows (successCallback, errorCallback, args) {
- var mediaType = args[6];
- var destinationType = args[1];
- var targetWidth = args[3];
- var targetHeight = args[4];
- var encodingType = args[5];
-
- var fileOpenPicker = new Windows.Storage.Pickers.FileOpenPicker();
- if (mediaType === Camera.MediaType.PICTURE) {
- fileOpenPicker.fileTypeFilter.replaceAll(['.png', '.jpg', '.jpeg']);
- fileOpenPicker.suggestedStartLocation = pickerLocId.picturesLibrary;
- } else if (mediaType === Camera.MediaType.VIDEO) {
- fileOpenPicker.fileTypeFilter.replaceAll(windowsVideoContainers);
- fileOpenPicker.suggestedStartLocation = pickerLocId.videosLibrary;
- } else {
- fileOpenPicker.fileTypeFilter.replaceAll(['*']);
- fileOpenPicker.suggestedStartLocation = pickerLocId.documentsLibrary;
- }
-
- fileOpenPicker.pickSingleFileAsync().done(function (file) {
- if (!file) {
- errorCallback("User didn't choose a file.");
- return;
- }
- if (destinationType === Camera.DestinationType.FILE_URI || destinationType === Camera.DestinationType.NATIVE_URI) {
- if (targetHeight > 0 && targetWidth > 0) {
- resizeImage(successCallback, errorCallback, file, targetWidth, targetHeight, encodingType);
- } else {
- var storageFolder = getAppData().localFolder;
- file.copyAsync(storageFolder, file.name, Windows.Storage.NameCollisionOption.replaceExisting).done(function (storageFile) {
- if (destinationType === Camera.DestinationType.NATIVE_URI) {
- successCallback('ms-appdata:///local/' + storageFile.name);
- } else {
- successCallback(URL.createObjectURL(storageFile));
- }
- }, function () {
- errorCallback("Can't access localStorage folder.");
- });
- }
- } else {
- if (targetHeight > 0 && targetWidth > 0) {
- resizeImageBase64(successCallback, errorCallback, file, targetWidth, targetHeight);
- } else {
- fileIO.readBufferAsync(file).done(function (buffer) {
- var strBase64 = encodeToBase64String(buffer);
- successCallback(strBase64);
- }, errorCallback);
- }
- }
- }, function () {
- errorCallback("User didn't choose a file.");
- });
-}
-
-function takePictureFromCamera (successCallback, errorCallback, args) {
- // Check if necessary API available
- if (!Windows.Media.Capture.CameraCaptureUI) {
- takePictureFromCameraWP(successCallback, errorCallback, args);
- } else {
- takePictureFromCameraWindows(successCallback, errorCallback, args);
- }
-}
-
-function takePictureFromCameraWP (successCallback, errorCallback, args) {
- // We are running on WP8.1 which lacks CameraCaptureUI class
- // so we need to use MediaCapture class instead and implement custom UI for camera
- var destinationType = args[1];
- var targetWidth = args[3];
- var targetHeight = args[4];
- var encodingType = args[5];
- var saveToPhotoAlbum = args[9];
- var cameraDirection = args[11];
- var capturePreview = null;
- var cameraCaptureButton = null;
- var cameraCancelButton = null;
- var capture = null;
- var captureSettings = null;
- var CaptureNS = Windows.Media.Capture;
- var sensor = null;
-
- function createCameraUI () {
- // create style for take and cancel buttons
- var buttonStyle = 'width:45%;padding: 10px 16px;font-size: 18px;line-height: 1.3333333;color: #333;background-color: #fff;border-color: #ccc; border: 1px solid transparent;border-radius: 6px; display: block; margin: 20px; z-index: 1000;border-color: #adadad;';
-
- // Create fullscreen preview
- // z-order style element for capturePreview and cameraCancelButton elts
- // is necessary to avoid overriding by another page elements, -1 sometimes is not enough
- capturePreview = document.createElement('video');
- capturePreview.style.cssText = 'position: fixed; left: 0; top: 0; width: 100%; height: 100%; z-index: ' + (HIGHEST_POSSIBLE_Z_INDEX - 1) + ';';
-
- // Create capture button
- cameraCaptureButton = document.createElement('button');
- cameraCaptureButton.innerText = 'Take';
- cameraCaptureButton.style.cssText = buttonStyle + 'position: fixed; left: 0; bottom: 0; margin: 20px; z-index: ' + HIGHEST_POSSIBLE_Z_INDEX + ';';
-
- // Create cancel button
- cameraCancelButton = document.createElement('button');
- cameraCancelButton.innerText = 'Cancel';
- cameraCancelButton.style.cssText = buttonStyle + 'position: fixed; right: 0; bottom: 0; margin: 20px; z-index: ' + HIGHEST_POSSIBLE_Z_INDEX + ';';
-
- capture = new CaptureNS.MediaCapture();
-
- captureSettings = new CaptureNS.MediaCaptureInitializationSettings();
- captureSettings.streamingCaptureMode = CaptureNS.StreamingCaptureMode.video;
- }
-
- function continueVideoOnFocus () {
- // if preview is defined it would be stuck, play it
- if (capturePreview) {
- capturePreview.play();
- }
- }
-
- function startCameraPreview () {
- // Search for available camera devices
- // This is necessary to detect which camera (front or back) we should use
- var DeviceEnum = Windows.Devices.Enumeration;
- var expectedPanel = cameraDirection === 1 ? DeviceEnum.Panel.front : DeviceEnum.Panel.back;
-
- // Add focus event handler to capture the event when user suspends the app and comes back while the preview is on
- window.addEventListener('focus', continueVideoOnFocus);
-
- DeviceEnum.DeviceInformation.findAllAsync(DeviceEnum.DeviceClass.videoCapture).then(function (devices) {
- if (devices.length <= 0) {
- destroyCameraPreview();
- errorCallback('Camera not found');
- return;
- }
-
- devices.forEach(function (currDev) {
- if (currDev.enclosureLocation.panel && currDev.enclosureLocation.panel === expectedPanel) {
- captureSettings.videoDeviceId = currDev.id;
- }
- });
-
- captureSettings.photoCaptureSource = Windows.Media.Capture.PhotoCaptureSource.photo;
-
- return capture.initializeAsync(captureSettings);
- }).then(function () {
-
- // create focus control if available
- var VideoDeviceController = capture.videoDeviceController;
- var FocusControl = VideoDeviceController.focusControl;
-
- if (FocusControl.supported === true) {
- capturePreview.addEventListener('click', function () {
- // Make sure function isn't called again before previous focus is completed
- if (this.getAttribute('clicked') === '1') {
- return false;
- } else {
- this.setAttribute('clicked', '1');
- }
- var preset = Windows.Media.Devices.FocusPreset.autoNormal;
- var parent = this;
- FocusControl.setPresetAsync(preset).done(function () {
- // set the clicked attribute back to '0' to allow focus again
- parent.setAttribute('clicked', '0');
- });
- });
- }
-
- // msdn.microsoft.com/en-us/library/windows/apps/hh452807.aspx
- capturePreview.msZoom = true;
- capturePreview.src = URL.createObjectURL(capture);
- capturePreview.play();
-
- // Bind events to controls
- sensor = Windows.Devices.Sensors.SimpleOrientationSensor.getDefault();
- if (sensor !== null) {
- sensor.addEventListener('orientationchanged', onOrientationChange);
- }
-
- // add click events to capture and cancel buttons
- cameraCaptureButton.addEventListener('click', onCameraCaptureButtonClick);
- cameraCancelButton.addEventListener('click', onCameraCancelButtonClick);
-
- // Change default orientation
- if (sensor) {
- setPreviewRotation(sensor.getCurrentOrientation());
- } else {
- setPreviewRotation(Windows.Graphics.Display.DisplayInformation.getForCurrentView().currentOrientation);
- }
-
- // Get available aspect ratios
- var aspectRatios = getAspectRatios(capture);
-
- // Couldn't find a good ratio
- if (aspectRatios.length === 0) {
- destroyCameraPreview();
- errorCallback('There\'s not a good aspect ratio available');
- return;
- }
-
- // add elements to body
- document.body.appendChild(capturePreview);
- document.body.appendChild(cameraCaptureButton);
- document.body.appendChild(cameraCancelButton);
-
- if (aspectRatios.indexOf(DEFAULT_ASPECT_RATIO) > -1) {
- return setAspectRatio(capture, DEFAULT_ASPECT_RATIO);
- } else {
- // Doesn't support 16:9 - pick next best
- return setAspectRatio(capture, aspectRatios[0]);
- }
- }).done(null, function (err) {
- destroyCameraPreview();
- errorCallback('Camera intitialization error ' + err);
- });
- }
-
- function destroyCameraPreview () {
- // If sensor is available, remove event listener
- if (sensor !== null) {
- sensor.removeEventListener('orientationchanged', onOrientationChange);
- }
-
- // Pause and dispose preview element
- capturePreview.pause();
- capturePreview.src = null;
-
- // Remove event listeners from buttons
- cameraCaptureButton.removeEventListener('click', onCameraCaptureButtonClick);
- cameraCancelButton.removeEventListener('click', onCameraCancelButtonClick);
-
- // Remove the focus event handler
- window.removeEventListener('focus', continueVideoOnFocus);
-
- // Remove elements
- [capturePreview, cameraCaptureButton, cameraCancelButton].forEach(function (elem) {
- if (elem /* && elem in document.body.childNodes */) {
- document.body.removeChild(elem);
- }
- });
-
- // Stop and dispose media capture manager
- if (capture) {
- capture.stopRecordAsync();
- capture = null;
- }
- }
-
- function captureAction () {
-
- var encodingProperties;
- var fileName;
- var tempFolder = getAppData().temporaryFolder;
-
- if (encodingType === Camera.EncodingType.PNG) {
- fileName = 'photo.png';
- encodingProperties = Windows.Media.MediaProperties.ImageEncodingProperties.createPng();
- } else {
- fileName = 'photo.jpg';
- encodingProperties = Windows.Media.MediaProperties.ImageEncodingProperties.createJpeg();
- }
-
- tempFolder.createFileAsync(fileName, OptUnique)
- .then(function (tempCapturedFile) {
- return new WinJS.Promise(function (complete) {
- var photoStream = new Windows.Storage.Streams.InMemoryRandomAccessStream();
- var finalStream = new Windows.Storage.Streams.InMemoryRandomAccessStream();
- capture.capturePhotoToStreamAsync(encodingProperties, photoStream)
- .then(function () {
- return Windows.Graphics.Imaging.BitmapDecoder.createAsync(photoStream);
- })
- .then(function (dec) {
- finalStream.size = 0; // BitmapEncoder requires the output stream to be empty
- return Windows.Graphics.Imaging.BitmapEncoder.createForTranscodingAsync(finalStream, dec);
- })
- .then(function (enc) {
- // We need to rotate the photo wrt sensor orientation
- enc.bitmapTransform.rotation = orientationToRotation(sensor.getCurrentOrientation());
- return enc.flushAsync();
- })
- .then(function () {
- return tempCapturedFile.openAsync(Windows.Storage.FileAccessMode.readWrite);
- })
- .then(function (fileStream) {
- return Windows.Storage.Streams.RandomAccessStream.copyAndCloseAsync(finalStream, fileStream);
- })
- .done(function () {
- photoStream.close();
- finalStream.close();
- complete(tempCapturedFile);
- }, function () {
- photoStream.close();
- finalStream.close();
- throw new Error('An error has occured while capturing the photo.');
- });
- });
- })
- .done(function (capturedFile) {
- destroyCameraPreview();
- savePhoto(capturedFile, {
- destinationType: destinationType,
- targetHeight: targetHeight,
- targetWidth: targetWidth,
- encodingType: encodingType,
- saveToPhotoAlbum: saveToPhotoAlbum
- }, successCallback, errorCallback);
- }, function (err) {
- destroyCameraPreview();
- errorCallback(err);
- });
- }
-
- function getAspectRatios (capture) {
- var videoDeviceController = capture.videoDeviceController;
- var photoAspectRatios = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.photo).map(function (element) {
- return (element.width / element.height).toFixed(1);
- }).filter(function (element, index, array) { return (index === array.indexOf(element)); });
-
- var videoAspectRatios = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.videoRecord).map(function (element) {
- return (element.width / element.height).toFixed(1);
- }).filter(function (element, index, array) { return (index === array.indexOf(element)); });
-
- var videoPreviewAspectRatios = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.videoPreview).map(function (element) {
- return (element.width / element.height).toFixed(1);
- }).filter(function (element, index, array) { return (index === array.indexOf(element)); });
-
- var allAspectRatios = [].concat(photoAspectRatios, videoAspectRatios, videoPreviewAspectRatios);
-
- var aspectObj = allAspectRatios.reduce(function (map, item) {
- if (!map[item]) {
- map[item] = 0;
- }
- map[item]++;
- return map;
- }, {});
-
- return Object.keys(aspectObj).filter(function (k) {
- return aspectObj[k] === 3;
- });
- }
-
- function setAspectRatio (capture, aspect) {
- // Max photo resolution with desired aspect ratio
- var videoDeviceController = capture.videoDeviceController;
- var photoResolution = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.photo)
- .filter(function (elem) {
- return ((elem.width / elem.height).toFixed(1) === aspect);
- })
- .reduce(function (prop1, prop2) {
- return (prop1.width * prop1.height) > (prop2.width * prop2.height) ? prop1 : prop2;
- });
-
- // Max video resolution with desired aspect ratio
- var videoRecordResolution = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.videoRecord)
- .filter(function (elem) {
- return ((elem.width / elem.height).toFixed(1) === aspect);
- })
- .reduce(function (prop1, prop2) {
- return (prop1.width * prop1.height) > (prop2.width * prop2.height) ? prop1 : prop2;
- });
-
- // Max video preview resolution with desired aspect ratio
- var videoPreviewResolution = videoDeviceController.getAvailableMediaStreamProperties(CapMSType.videoPreview)
- .filter(function (elem) {
- return ((elem.width / elem.height).toFixed(1) === aspect);
- })
- .reduce(function (prop1, prop2) {
- return (prop1.width * prop1.height) > (prop2.width * prop2.height) ? prop1 : prop2;
- });
-
- return videoDeviceController.setMediaStreamPropertiesAsync(CapMSType.photo, photoResolution)
- .then(function () {
- return videoDeviceController.setMediaStreamPropertiesAsync(CapMSType.videoPreview, videoPreviewResolution);
- })
- .then(function () {
- return videoDeviceController.setMediaStreamPropertiesAsync(CapMSType.videoRecord, videoRecordResolution);
- });
- }
-
- /**
- * When Capture button is clicked, try to capture a picture and return
- */
- function onCameraCaptureButtonClick () {
- // Make sure user can't click more than once
- if (this.getAttribute('clicked') === '1') {
- return false;
- } else {
- this.setAttribute('clicked', '1');
- }
- captureAction();
- }
-
- /**
- * When Cancel button is clicked, destroy camera preview and return with error callback
- */
- function onCameraCancelButtonClick () {
- // Make sure user can't click more than once
- if (this.getAttribute('clicked') === '1') {
- return false;
- } else {
- this.setAttribute('clicked', '1');
- }
- destroyCameraPreview();
- errorCallback('no image selected');
- }
-
- /**
- * When the phone orientation change, get the event and change camera preview rotation
- * @param {Object} e - SimpleOrientationSensorOrientationChangedEventArgs
- */
- function onOrientationChange (e) {
- setPreviewRotation(e.orientation);
- }
-
- /**
- * Converts SimpleOrientation to a VideoRotation to remove difference between camera sensor orientation
- * and video orientation
- * @param {number} orientation - Windows.Devices.Sensors.SimpleOrientation
- * @return {number} - Windows.Media.Capture.VideoRotation
- */
- function orientationToRotation (orientation) {
- // VideoRotation enumerable and BitmapRotation enumerable have the same values
- // https://msdn.microsoft.com/en-us/library/windows/apps/windows.media.capture.videorotation.aspx
- // https://msdn.microsoft.com/en-us/library/windows/apps/windows.graphics.imaging.bitmaprotation.aspx
-
- switch (orientation) {
- // portrait
- case Windows.Devices.Sensors.SimpleOrientation.notRotated:
- return Windows.Media.Capture.VideoRotation.clockwise90Degrees;
- // landscape
- case Windows.Devices.Sensors.SimpleOrientation.rotated90DegreesCounterclockwise:
- return Windows.Media.Capture.VideoRotation.none;
- // portrait-flipped (not supported by WinPhone Apps)
- case Windows.Devices.Sensors.SimpleOrientation.rotated180DegreesCounterclockwise:
- // Falling back to portrait default
- return Windows.Media.Capture.VideoRotation.clockwise90Degrees;
- // landscape-flipped
- case Windows.Devices.Sensors.SimpleOrientation.rotated270DegreesCounterclockwise:
- return Windows.Media.Capture.VideoRotation.clockwise180Degrees;
- // faceup & facedown
- default:
- // Falling back to portrait default
- return Windows.Media.Capture.VideoRotation.clockwise90Degrees;
- }
- }
-
- /**
- * Rotates the current MediaCapture's video
- * @param {number} orientation - Windows.Devices.Sensors.SimpleOrientation
- */
- function setPreviewRotation (orientation) {
- capture.setPreviewRotation(orientationToRotation(orientation));
- }
-
- try {
- createCameraUI();
- startCameraPreview();
- } catch (ex) {
- errorCallback(ex);
- }
-}
-
-function takePictureFromCameraWindows (successCallback, errorCallback, args) {
- var destinationType = args[1];
- var targetWidth = args[3];
- var targetHeight = args[4];
- var encodingType = args[5];
- var allowCrop = !!args[7];
- var saveToPhotoAlbum = args[9];
- var WMCapture = Windows.Media.Capture;
- var cameraCaptureUI = new WMCapture.CameraCaptureUI();
-
- cameraCaptureUI.photoSettings.allowCropping = allowCrop;
-
- if (encodingType === Camera.EncodingType.PNG) {
- cameraCaptureUI.photoSettings.format = WMCapture.CameraCaptureUIPhotoFormat.png;
- } else {
- cameraCaptureUI.photoSettings.format = WMCapture.CameraCaptureUIPhotoFormat.jpeg;
- }
-
- // decide which max pixels should be supported by targetWidth or targetHeight.
- var maxRes = null;
- var UIMaxRes = WMCapture.CameraCaptureUIMaxPhotoResolution;
- var totalPixels = targetWidth * targetHeight;
-
- if (targetWidth === -1 && targetHeight === -1) {
- maxRes = UIMaxRes.highestAvailable;
- // Temp fix for CB-10539
- /* else if (totalPixels <= 320 * 240) {
- maxRes = UIMaxRes.verySmallQvga;
- } */
- } else if (totalPixels <= 640 * 480) {
- maxRes = UIMaxRes.smallVga;
- } else if (totalPixels <= 1024 * 768) {
- maxRes = UIMaxRes.mediumXga;
- } else if (totalPixels <= 3 * 1000 * 1000) {
- maxRes = UIMaxRes.large3M;
- } else if (totalPixels <= 5 * 1000 * 1000) {
- maxRes = UIMaxRes.veryLarge5M;
- } else {
- maxRes = UIMaxRes.highestAvailable;
- }
-
- cameraCaptureUI.photoSettings.maxResolution = maxRes;
-
- var cameraPicture;
-
- // define focus handler for windows phone 10.0
- var savePhotoOnFocus = function () {
- window.removeEventListener('focus', savePhotoOnFocus);
- // call only when the app is in focus again
- savePhoto(cameraPicture, {
- destinationType: destinationType,
- targetHeight: targetHeight,
- targetWidth: targetWidth,
- encodingType: encodingType,
- saveToPhotoAlbum: saveToPhotoAlbum
- }, successCallback, errorCallback);
- };
-
- // if windows phone 10, add and delete focus eventHandler to capture the focus back from cameraUI to app
- if (navigator.appVersion.indexOf('Windows Phone 10.0') >= 0) {
- window.addEventListener('focus', savePhotoOnFocus);
- }
-
- cameraCaptureUI.captureFileAsync(WMCapture.CameraCaptureUIMode.photo).done(function (picture) {
- if (!picture) {
- errorCallback("User didn't capture a photo.");
- // Remove the focus handler if present
- window.removeEventListener('focus', savePhotoOnFocus);
- return;
- }
- cameraPicture = picture;
-
- // If not windows 10, call savePhoto() now. If windows 10, wait for the app to be in focus again
- if (navigator.appVersion.indexOf('Windows Phone 10.0') < 0) {
- savePhoto(cameraPicture, {
- destinationType: destinationType,
- targetHeight: targetHeight,
- targetWidth: targetWidth,
- encodingType: encodingType,
- saveToPhotoAlbum: saveToPhotoAlbum
- }, successCallback, errorCallback);
- }
- }, function () {
- errorCallback('Fail to capture a photo.');
- window.removeEventListener('focus', savePhotoOnFocus);
- });
-}
-
-function savePhoto (picture, options, successCallback, errorCallback) {
- // success callback for capture operation
- var success = function (picture) {
- if (options.destinationType === Camera.DestinationType.FILE_URI || options.destinationType === Camera.DestinationType.NATIVE_URI) {
- if (options.targetHeight > 0 && options.targetWidth > 0) {
- resizeImage(successCallback, errorCallback, picture, options.targetWidth, options.targetHeight, options.encodingType);
- } else {
- picture.copyAsync(getAppData().localFolder, picture.name, OptUnique).done(function (copiedFile) {
- successCallback('ms-appdata:///local/' + copiedFile.name);
- }, errorCallback);
- }
- } else {
- if (options.targetHeight > 0 && options.targetWidth > 0) {
- resizeImageBase64(successCallback, errorCallback, picture, options.targetWidth, options.targetHeight);
- } else {
- fileIO.readBufferAsync(picture).done(function (buffer) {
- var strBase64 = encodeToBase64String(buffer);
- picture.deleteAsync().done(function () {
- successCallback(strBase64);
- }, function (err) {
- errorCallback(err);
- });
- }, errorCallback);
- }
- }
- };
-
- if (!options.saveToPhotoAlbum) {
- success(picture);
-
- } else {
- var savePicker = new Windows.Storage.Pickers.FileSavePicker();
- var saveFile = function (file) {
- if (file) {
- // Prevent updates to the remote version of the file until we're done
- Windows.Storage.CachedFileManager.deferUpdates(file);
- picture.moveAndReplaceAsync(file)
- .then(function () {
- // Let Windows know that we're finished changing the file so
- // the other app can update the remote version of the file.
- return Windows.Storage.CachedFileManager.completeUpdatesAsync(file);
- })
- .done(function (updateStatus) {
- if (updateStatus === Windows.Storage.Provider.FileUpdateStatus.complete) {
- success(picture);
- } else {
- errorCallback('File update status is not complete.');
- }
- }, errorCallback);
- } else {
- errorCallback('Failed to select a file.');
- }
- };
- savePicker.suggestedStartLocation = pickerLocId.picturesLibrary;
-
- if (options.encodingType === Camera.EncodingType.PNG) {
- savePicker.fileTypeChoices.insert('PNG', ['.png']);
- savePicker.suggestedFileName = 'photo.png';
- } else {
- savePicker.fileTypeChoices.insert('JPEG', ['.jpg']);
- savePicker.suggestedFileName = 'photo.jpg';
- }
-
- // If Windows Phone 8.1 use pickSaveFileAndContinue()
- if (navigator.appVersion.indexOf('Windows Phone 8.1') >= 0) {
- /*
- Need to add and remove an event listener to catch activation state
- Using FileSavePicker will suspend the app and it's required to catch the pickSaveFileContinuation
- https://msdn.microsoft.com/en-us/library/windows/apps/xaml/dn631755.aspx
- */
- var fileSaveHandler = function (eventArgs) {
- if (eventArgs.kind === Windows.ApplicationModel.Activation.ActivationKind.pickSaveFileContinuation) {
- var file = eventArgs.file;
- saveFile(file);
- webUIApp.removeEventListener('activated', fileSaveHandler);
- }
- };
- webUIApp.addEventListener('activated', fileSaveHandler);
- savePicker.pickSaveFileAndContinue();
- } else {
- savePicker.pickSaveFileAsync()
- .done(saveFile, errorCallback);
- }
- }
-}
-
-require('cordova/exec/proxy').add('Camera', module.exports);
diff --git a/tests/ios/CDVCameraTest/CDVCameraLibTests/CameraTest.m b/tests/ios/CDVCameraTest/CDVCameraLibTests/CameraTest.m
index b9439d108..d74cdbaac 100644
--- a/tests/ios/CDVCameraTest/CDVCameraLibTests/CameraTest.m
+++ b/tests/ios/CDVCameraTest/CDVCameraLibTests/CameraTest.m
@@ -82,7 +82,7 @@ - (void) testPictureOptionsCreate
XCTAssertEqual(options.usesGeolocation, NO);
// Set each argument, check whether they are set. different from defaults
- popoverOptions = @{ @"x" : @1, @"y" : @2, @"width" : @3, @"height" : @4 };
+ popoverOptions = @{ @"x" : @1, @"y" : @2, @"width" : @3, @"height" : @4, @"popoverWidth": @200, @"popoverHeight": @300 };
args = @[
@(49),
@@ -127,7 +127,7 @@ - (void) testCameraPickerCreate
// Souce is Camera, and image type
- popoverOptions = @{ @"x" : @1, @"y" : @2, @"width" : @3, @"height" : @4 };
+ popoverOptions = @{ @"x" : @1, @"y" : @2, @"width" : @3, @"height" : @4, @"popoverWidth": @200, @"popoverHeight": @300 };
args = @[
@(49),
@(DestinationTypeDataUrl),
diff --git a/tests/ios/doc/de/README.md b/tests/ios/doc/de/README.md
deleted file mode 100644
index 0b3ae9693..000000000
--- a/tests/ios/doc/de/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# iOS-Tests für CDVCamera
-
-Sie müssen installieren `node.js` in `Cordova-Ios` zu ziehen.
-
-Installieren Sie Cordova-Ios zum ersten Mal:
-
- npm install
-
-
-... im aktuellen Ordner.
-
-# Testen von Xcode
-
- 1. Starten Sie die Datei `CDVCameraTest.xcworkspace` .
- 2. Wählen Sie im Dropdown-Schema "CDVCameraLibTests"
- 3. Klicken Sie und halten Sie auf den `Play` -Button und wählen Sie das `Schraubenschlüssel` -Symbol zum Ausführen der tests
-
-# Tests von der Befehlszeile aus
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/es/README.md b/tests/ios/doc/es/README.md
deleted file mode 100644
index 7240746c2..000000000
--- a/tests/ios/doc/es/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# Pruebas de iOS para CDVCamera
-
-Necesita instalar `node.js` en `Córdoba-ios`.
-
-Primero instalar cordova-ios:
-
- npm install
-
-
-... en la carpeta actual.
-
-# Prueba de Xcode
-
- 1. Iniciar el archivo `CDVCameraTest.xcworkspace` .
- 2. Elija "CDVCameraLibTests" en el menú de lista desplegable esquema
- 3. Haga clic y mantenga el botón de `Play` y elegir el icono de `llave inglesa` para ejecutar las pruebas
-
-# Pruebas desde la línea de comandos
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/fr/README.md b/tests/ios/doc/fr/README.md
deleted file mode 100644
index 4c656a36f..000000000
--- a/tests/ios/doc/fr/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# Tests d'iOS pour CDVCamera
-
-Vous devez installer `node.js` à `cordova-ios`.
-
-Commencez par installer cordova-ios :
-
- npm install
-
-
-... dans le dossier actuel.
-
-# Tests de Xcode
-
- 1. Lancez le fichier `CDVCameraTest.xcworkspace` .
- 2. Choisissez « CDVCameraLibTests » dans le menu déroulant de régime
- 3. Cliquez et maintenez sur la touche `Play` et cliquez sur l'icône de `clé` pour exécuter les tests
-
-# Test de la ligne de commande
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/it/README.md b/tests/ios/doc/it/README.md
deleted file mode 100644
index af02253a3..000000000
--- a/tests/ios/doc/it/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# Test di iOS per CDVCamera
-
-È necessario installare `node. js` per tirare in `cordova-ios`.
-
-In primo luogo installare cordova-ios:
-
- npm install
-
-
-... nella cartella corrente.
-
-# Test da Xcode
-
- 1. Lanciare il file `CDVCameraTest.xcworkspace` .
- 2. Scegli "CDVCameraLibTests" dal menu a discesa Schema
- 3. Fare clic e tenere premuto il pulsante `Play` e scegliere l'icona della `chiave inglese` per eseguire i test
-
-# Test dalla riga di comando
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/ja/README.md b/tests/ios/doc/ja/README.md
deleted file mode 100644
index ca0fe844f..000000000
--- a/tests/ios/doc/ja/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# CDVCamera の iOS のテスト
-
-`Node.js` `コルドバ`ios をプルするをインストールする必要があります。.
-
-コルドバ ios をインストールします。
-
- npm install
-
-
-現在のフォルダーに.
-
-# Xcode からテスト
-
- 1. `CDVCameraTest.xcworkspace`ファイルを起動します。
- 2. スキーム] ドロップダウン メニューから"CDVCameraLibTests"を選択します。
- 3. クリックし、`再生`ボタンを押し、テストを実行する`レンチ`のアイコンを選択
-
-# コマンドラインからテスト
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/ko/README.md b/tests/ios/doc/ko/README.md
deleted file mode 100644
index 3ad9cfcec..000000000
--- a/tests/ios/doc/ko/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# CDVCamera에 대 한 iOS 테스트
-
-`Node.js` `코르도바` ios에서를 설치 해야.
-
-코르도바-ios를 설치 하는 첫번째는:
-
- npm install
-
-
-현재 폴더에....
-
-# Xcode에서 테스트
-
- 1. `CDVCameraTest.xcworkspace` 파일을 시작 합니다.
- 2. 구성표 드롭 다운 메뉴에서 "CDVCameraLibTests"를 선택
- 3. 클릭 하 고 `재생` 버튼에는 테스트를 실행 하려면 `공구 모양` 아이콘을 선택
-
-# 명령줄에서 테스트
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/pl/README.md b/tests/ios/doc/pl/README.md
deleted file mode 100644
index 82caa41a0..000000000
--- a/tests/ios/doc/pl/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# iOS testy dla CDVCamera
-
-Musisz zainstalować `node.js` ciągnąć w `cordova-ios`.
-
-Najpierw zainstalować cordova-ios:
-
- npm install
-
-
-... w folderze bieżącym.
-
-# Badania z Xcode
-
- 1. Uruchom plik `CDVCameraTest.xcworkspace` .
- 2. Wybierz z menu rozwijanego systemu "CDVCameraLibTests"
- 3. Kliknij i przytrzymaj przycisk `Play` i wybrać ikonę `klucz` do testów
-
-# Badania z wiersza polecenia
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/doc/zh/README.md b/tests/ios/doc/zh/README.md
deleted file mode 100644
index 5312987a0..000000000
--- a/tests/ios/doc/zh/README.md
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-# CDVCamera 的 iOS 測試
-
-您需要安裝`node.js`拉`科爾多瓦 ios`中.
-
-第一次安裝科爾多瓦 ios:
-
- npm install
-
-
-在當前資料夾中。
-
-# 從 Xcode 測試
-
- 1. 啟動`CDVCameraTest.xcworkspace`檔。
- 2. 從方案下拉式功能表中選擇"CDVCameraLibTests"
- 3. 按一下並堅持`播放`按鈕,然後選擇要運行的測試的`扳手`圖示
-
-# 從命令列測試
-
- npm test
\ No newline at end of file
diff --git a/tests/ios/package.json b/tests/ios/package.json
index 4b9486f4a..39053030c 100644
--- a/tests/ios/package.json
+++ b/tests/ios/package.json
@@ -8,6 +8,6 @@
"cordova-ios": "*"
},
"scripts": {
- "test": "xcodebuild -scheme CordovaLib && xcodebuild test -scheme CDVCameraLibTests -destination 'platform=iOS Simulator,name=iPhone 5'"
+ "test": "xcodebuild -scheme CordovaLib && xcodebuild test -scheme CDVCameraLibTests -destination 'platform=iOS Simulator,name=iPhone 5s'"
}
}
diff --git a/tests/package.json b/tests/package.json
index 646e22cdb..b1b15be1c 100644
--- a/tests/package.json
+++ b/tests/package.json
@@ -1,6 +1,6 @@
{
"name": "cordova-plugin-camera-tests",
- "version": "2.4.1-dev",
+ "version": "7.0.0",
"description": "",
"cordova": {
"id": "cordova-plugin-camera-tests",
@@ -10,5 +10,5 @@
"ecosystem:cordova"
],
"author": "",
- "license": "Apache 2.0"
+ "license": "Apache-2.0"
}
diff --git a/tests/plugin.xml b/tests/plugin.xml
index 622e21f76..ae6003c29 100644
--- a/tests/plugin.xml
+++ b/tests/plugin.xml
@@ -22,12 +22,10 @@
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:rim="http://www.blackberry.com/ns/widgets"
id="cordova-plugin-camera-tests"
- version="4.0.3">
+ version="7.0.0">
Cordova Camera Plugin Tests
Apache 2.0
-
-
diff --git a/tests/tests.js b/tests/tests.js
index f45b8b66c..721d41232 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -19,7 +19,7 @@
*
*/
-/* globals Camera, resolveLocalFileSystemURL, FileEntry, CameraPopoverOptions, FileTransfer, FileUploadOptions, LocalFileSystem, MSApp */
+/* globals Camera, resolveLocalFileSystemURL, FileEntry, CameraPopoverOptions, LocalFileSystem */
/* eslint-env jasmine */
exports.defineAutoTests = function () {
@@ -42,10 +42,8 @@ exports.defineAutoTests = function () {
it('camera.spec.2 should contain three DestinationType constants', function () {
expect(Camera.DestinationType.DATA_URL).toBe(0);
expect(Camera.DestinationType.FILE_URI).toBe(1);
- expect(Camera.DestinationType.NATIVE_URI).toBe(2);
expect(navigator.camera.DestinationType.DATA_URL).toBe(0);
expect(navigator.camera.DestinationType.FILE_URI).toBe(1);
- expect(navigator.camera.DestinationType.NATIVE_URI).toBe(2);
});
it('camera.spec.3 should contain two EncodingType constants', function () {
@@ -80,20 +78,20 @@ exports.defineAutoTests = function () {
/******************************************************************************/
exports.defineManualTests = function (contentEl, createActionButton) {
- var pictureUrl = null;
- var fileObj = null;
- var fileEntry = null;
- var pageStartTime = +new Date();
+ let pictureUrl = null;
+ let fileObj = null;
+ let fileEntry = null;
+ const pageStartTime = +new Date();
// default camera options
- var camQualityDefault = ['50', 50];
- var camDestinationTypeDefault = ['FILE_URI', 1];
- var camPictureSourceTypeDefault = ['CAMERA', 1];
- var camAllowEditDefault = ['allowEdit', false];
- var camEncodingTypeDefault = ['JPEG', 0];
- var camMediaTypeDefault = ['mediaType', 0];
- var camCorrectOrientationDefault = ['correctOrientation', false];
- var camSaveToPhotoAlbumDefault = ['saveToPhotoAlbum', true];
+ const camQualityDefault = ['50', 50];
+ const camDestinationTypeDefault = ['FILE_URI', 1];
+ const camPictureSourceTypeDefault = ['CAMERA', 1];
+ const camAllowEditDefault = ['allowEdit', false];
+ const camEncodingTypeDefault = ['JPEG', 0];
+ const camMediaTypeDefault = ['mediaType', 0];
+ const camCorrectOrientationDefault = ['correctOrientation', false];
+ const camSaveToPhotoAlbumDefault = ['saveToPhotoAlbum', true];
function log (value) {
console.log(value);
@@ -103,7 +101,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
function clearStatus () {
document.getElementById('camera_status').innerHTML = '';
document.getElementById('camera_image').src = 'about:blank';
- var canvas = document.getElementById('canvas');
+ const canvas = document.getElementById('canvas');
canvas.width = canvas.height = 1;
pictureUrl = null;
fileObj = null;
@@ -121,8 +119,8 @@ exports.defineManualTests = function (contentEl, createActionButton) {
log('URL: "' + url.slice(0, 90) + '"');
pictureUrl = url;
- var img = document.getElementById('camera_image');
- var startTime = new Date();
+ const img = document.getElementById('camera_image');
+ const startTime = new Date();
img.src = url;
img.onload = function () {
log('Img size: ' + img.naturalWidth + 'x' + img.naturalHeight);
@@ -140,7 +138,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
function getPictureWin (data) {
setPicture(data);
// TODO: Fix resolveLocalFileSystemURI to work with native-uri.
- if (pictureUrl.indexOf('file:') === 0 || pictureUrl.indexOf('content:') === 0 || pictureUrl.indexOf('ms-appdata:') === 0 || pictureUrl.indexOf('assets-library:') === 0) {
+ if (pictureUrl.indexOf('file:') === 0 || pictureUrl.indexOf('content:') === 0) {
resolveLocalFileSystemURL(data, function (e) {
fileEntry = e;
logCallback('resolveLocalFileSystemURL()', true)(e.toURL());
@@ -149,44 +147,24 @@ exports.defineManualTests = function (contentEl, createActionButton) {
} else if (pictureUrl.indexOf('data:image/jpeg;base64') === 0) {
// do nothing
} else {
- var path = pictureUrl.replace(/^file:\/\/(localhost)?/, '').replace(/%20/g, ' ');
+ const path = pictureUrl.replace(/^file:\/\/(localhost)?/, '').replace(/%20/g, ' ');
fileEntry = new FileEntry('image_name.png', path);
}
}
function getPicture () {
clearStatus();
- var options = extractOptions();
+ const options = extractOptions();
log('Getting picture with options: ' + JSON.stringify(options));
- var popoverHandle = navigator.camera.getPicture(getPictureWin, onGetPictureError, options);
+ const popoverHandle = navigator.camera.getPicture(getPictureWin, onGetPictureError, options);
// Reposition the popover if the orientation changes.
window.onorientationchange = function () {
- var newPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, 0);
+ const newPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, 0, 300, 400);
popoverHandle.setPosition(newPopoverOptions);
};
}
- function uploadImage () {
- var ft = new FileTransfer();
- var options = new FileUploadOptions();
- options.fileKey = 'photo';
- options.fileName = 'test.jpg';
- options.mimeType = 'image/jpeg';
- ft.onprogress = function (progressEvent) {
- console.log('progress: ' + progressEvent.loaded + ' of ' + progressEvent.total);
- };
- var server = 'http://sheltered-retreat-43956.herokuapp.com';
-
- ft.upload(pictureUrl, server + '/upload', win, fail, options);
- function win (information_back) {
- log('upload complete');
- }
- function fail (message) {
- log('upload failed: ' + JSON.stringify(message));
- }
- }
-
function logCallback (apiName, success) {
return function () {
log('Call to ' + apiName + (success ? ' success: ' : ' failed: ') + JSON.stringify([].slice.call(arguments)));
@@ -194,12 +172,12 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
/**
- * Select image from library using a NATIVE_URI destination type
+ * Select image from library
* This calls FileEntry.getMetadata, FileEntry.setMetadata, FileEntry.getParent, FileEntry.file, and FileReader.readAsDataURL.
*/
function readFile () {
function onFileReadAsDataURL (evt) {
- var img = document.getElementById('camera_image');
+ const img = document.getElementById('camera_image');
img.style.visibility = 'visible';
img.style.display = 'block';
img.src = evt.target.result;
@@ -210,7 +188,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
log('Got file: ' + JSON.stringify(file));
fileObj = file;
/* eslint-disable no-undef */
- var reader = new FileReader();
+ const reader = new FileReader();
/* eslint-enable no-undef */
reader.onload = function () {
log('FileReader.readAsDataURL() - length = ' + reader.result.length);
@@ -237,13 +215,13 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
/**
- * Copy image from library using a NATIVE_URI destination type
+ * Copy image from library
* This calls FileEntry.copyTo and FileEntry.moveTo.
*/
function copyImage () {
- var onFileSystemReceived = function (fileSystem) {
- var destDirEntry = fileSystem.root;
- var origName = fileEntry.name;
+ const onFileSystemReceived = function (fileSystem) {
+ const destDirEntry = fileSystem.root;
+ const origName = fileEntry.name;
// Test FileEntry API here.
fileEntry.copyTo(destDirEntry, 'copied_file.png', logCallback('FileEntry.copyTo', true), logCallback('FileEntry.copyTo', false));
@@ -271,17 +249,17 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
/**
- * Write image to library using a NATIVE_URI destination type
+ * Write image to library
* This calls FileEntry.createWriter, FileWriter.write, and FileWriter.truncate.
*/
function writeImage () {
- var onFileWriterReceived = function (fileWriter) {
+ const onFileWriterReceived = function (fileWriter) {
fileWriter.onwrite = logCallback('FileWriter.write', true);
fileWriter.onerror = logCallback('FileWriter.write', false);
fileWriter.write('some text!');
};
- var onFileTruncateWriterReceived = function (fileWriter) {
+ const onFileTruncateWriterReceived = function (fileWriter) {
fileWriter.onwrite = logCallback('FileWriter.truncate', true);
fileWriter.onerror = logCallback('FileWriter.truncate', false);
fileWriter.truncate(10);
@@ -292,20 +270,20 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
function displayImageUsingCanvas () {
- var canvas = document.getElementById('canvas');
- var img = document.getElementById('camera_image');
- var w = img.width;
- var h = img.height;
+ const canvas = document.getElementById('canvas');
+ const img = document.getElementById('camera_image');
+ let w = img.width;
+ let h = img.height;
h = 100 / w * h;
w = 100;
canvas.width = w;
canvas.height = h;
- var context = canvas.getContext('2d');
+ const context = canvas.getContext('2d');
context.drawImage(img, 0, 0, w, h);
}
/**
- * Remove image from library using a NATIVE_URI destination type
+ * Remove image from library
* This calls FileEntry.remove.
*/
function removeImage () {
@@ -333,9 +311,9 @@ exports.defineManualTests = function (contentEl, createActionButton) {
return;
}
/* eslint-enable no-undef */
- var URLApi = window.URL || window.webkitURL;
+ const URLApi = window.URL || window.webkitURL;
if (URLApi) {
- var blobURL = URLApi.createObjectURL(fileObj);
+ const blobURL = URLApi.createObjectURL(fileObj);
if (blobURL) {
setPicture(blobURL, function () {
URLApi.revokeObjectURL(blobURL);
@@ -349,11 +327,11 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
function extractOptions () {
- var els = document.querySelectorAll('#image-options select');
- var ret = {};
+ const els = document.querySelectorAll('#image-options select');
+ const ret = {};
/* eslint-disable no-cond-assign */
- for (var i = 0, el; el = els[i]; ++i) {
- var value = el.value;
+ for (let i = 0, el; el = els[i]; ++i) {
+ let value = el.value;
if (value === '') continue;
value = +value;
@@ -368,20 +346,20 @@ exports.defineManualTests = function (contentEl, createActionButton) {
}
function createOptionsEl (name, values, selectionDefault) {
- var openDiv = '' + name + ': ';
- var select = '
';
+ const openDiv = '' + name + ': ';
+ const select = '';
- var defaultOption = '';
+ let defaultOption = '';
if (selectionDefault === undefined) {
defaultOption = 'default ';
}
- var options = '';
+ let options = '';
if (typeof values === 'boolean') {
- values = { 'true': 1, 'false': 0 };
+ values = { true: 1, false: 0 };
}
- for (var k in values) {
- var isSelected = '';
+ for (const k in values) {
+ let isSelected = '';
if (selectionDefault) {
if (selectionDefault[0] === k) {
isSelected = 'selected';
@@ -390,35 +368,35 @@ exports.defineManualTests = function (contentEl, createActionButton) {
options += '' + k + ' ';
}
- var closeDiv = '
';
+ const closeDiv = ' ';
return openDiv + select + defaultOption + options + closeDiv;
}
/******************************************************************************/
- var info_div = 'Camera ' +
+ const info_div = 'Camera ' +
'' +
'
Status:
' +
'img:
' +
'canvas:
' +
'
';
- var options_div = 'Cordova Camera API Options ' +
+ const options_div = 'Cordova Camera API Options ' +
'' +
createOptionsEl('sourceType', Camera.PictureSourceType, camPictureSourceTypeDefault) +
createOptionsEl('destinationType', Camera.DestinationType, camDestinationTypeDefault) +
createOptionsEl('encodingType', Camera.EncodingType, camEncodingTypeDefault) +
createOptionsEl('mediaType', Camera.MediaType, camMediaTypeDefault) +
- createOptionsEl('quality', { '0': 0, '50': 50, '80': 80, '100': 100 }, camQualityDefault) +
- createOptionsEl('targetWidth', { '50': 50, '200': 200, '800': 800, '2048': 2048 }) +
- createOptionsEl('targetHeight', { '50': 50, '200': 200, '800': 800, '2048': 2048 }) +
+ createOptionsEl('quality', { 0: 0, 50: 50, 80: 80, 100: 100 }, camQualityDefault) +
+ createOptionsEl('targetWidth', { 50: 50, 200: 200, 800: 800, 2048: 2048 }) +
+ createOptionsEl('targetHeight', { 50: 50, 200: 200, 800: 800, 2048: 2048 }) +
createOptionsEl('allowEdit', true, camAllowEditDefault) +
createOptionsEl('correctOrientation', true, camCorrectOrientationDefault) +
createOptionsEl('saveToPhotoAlbum', true, camSaveToPhotoAlbumDefault) +
createOptionsEl('cameraDirection', Camera.Direction) +
'
';
- var getpicture_div = '
';
- var test_procedure = 'Recommended Test Procedure ' +
+ const getpicture_div = '
';
+ const test_procedure = 'Recommended Test Procedure ' +
'Options not specified should be the default value' +
' Status box should update with image and info whenever an image is taken or selected from library' +
'
' +
@@ -432,13 +410,13 @@ exports.defineManualTests = function (contentEl, createActionButton) {
'
sourceType=CAMERA targetWidth & targetHeight=50 allowEdit=false Do Get File Metadata test below and take note of size Repeat test but with width and height=800. Size should be significantly larger. ' +
'quality=0 targetWidth & targetHeight=default allowEdit=false Do Get File Metadata test below and take note of size Repeat test but with quality=80. Size should be significantly larger. ' +
'';
- var inputs_div = 'Native File Inputs ' +
+ const inputs_div = 'Native File Inputs ' +
'For the following tests, status box should update with file selected' +
'input type=file
' +
'capture=camera
' +
'capture=camcorder
' +
'capture=microphone
';
- var actions_div = 'Actions ' +
+ const actions_div = 'Actions ' +
'For the following tests, ensure that an image is set in status box' +
'
' +
'Expected result: Get metadata about file selected. Status box will show, along with the metadata, "Call to FileEntry.getMetadata success, Call to FileEntry.setMetadata success, Call to FileEntry.getParent success"' +
@@ -455,22 +433,14 @@ exports.defineManualTests = function (contentEl, createActionButton) {
'
' +
'Expected result: Remove image from library. Status box will show "FileEntry.remove success:["OK"]';
- // We need to wrap this code due to Windows security restrictions
- // see http://msdn.microsoft.com/en-us/library/windows/apps/hh465380.aspx#differences for details
- if (window.MSApp && window.MSApp.execUnsafeLocalFunction) {
- MSApp.execUnsafeLocalFunction(function () {
- contentEl.innerHTML = info_div + options_div + getpicture_div + test_procedure + inputs_div + actions_div;
- });
- } else {
- contentEl.innerHTML = info_div + options_div + getpicture_div + test_procedure + inputs_div + actions_div;
- }
+ contentEl.innerHTML = info_div + options_div + getpicture_div + test_procedure + inputs_div + actions_div;
- var elements = document.getElementsByClassName('testInputTag');
- var listener = function (e) {
+ const elements = document.getElementsByClassName('testInputTag');
+ const listener = function (e) {
testInputTag(e.target);
};
- for (var i = 0; i < elements.length; ++i) {
- var item = elements[i];
+ for (let i = 0; i < elements.length; ++i) {
+ const item = elements[i];
item.addEventListener('change', listener, false);
}
@@ -498,10 +468,6 @@ exports.defineManualTests = function (contentEl, createActionButton) {
writeImage();
}, 'write');
- createActionButton('Upload Image', function () {
- uploadImage();
- }, 'upload');
-
createActionButton('Draw Using Canvas', function () {
displayImageUsingCanvas();
}, 'draw_canvas');
diff --git a/types/index.d.ts b/types/index.d.ts
index fa50e9ce2..1d32f40d3 100644
--- a/types/index.d.ts
+++ b/types/index.d.ts
@@ -51,8 +51,6 @@ interface CameraOptions {
* Defined in navigator.camera.DestinationType. Default is FILE_URI.
* DATA_URL : 0, Return image as base64-encoded string
* FILE_URI : 1, Return image file URI
- * NATIVE_URI : 2 Return image native URI
- * (e.g., assets-library:// on iOS or content:// on Android)
*/
destinationType?: number;
/**
@@ -136,6 +134,12 @@ interface CameraPopoverOptions {
* ARROW_ANY : 15
*/
arrowDir : number;
+ popoverWidth: number;
+ popoverHeight: number;
+}
+
+declare class CameraPopoverOptions implements CameraPopoverOptions {
+ constructor(x?: number, y?: number, width?: number, height?: number, arrowDir?: number);
}
declare var Camera: {
@@ -143,7 +147,6 @@ declare var Camera: {
DestinationType: {
DATA_URL: number;
FILE_URI: number;
- NATIVE_URI: number
}
Direction: {
BACK: number;
diff --git a/www/Camera.js b/www/Camera.js
index 0eade0fe3..5c0627a33 100644
--- a/www/Camera.js
+++ b/www/Camera.js
@@ -19,9 +19,9 @@
*
*/
-var argscheck = require('cordova/argscheck');
-var exec = require('cordova/exec');
-var Camera = require('./Camera');
+const argscheck = require('cordova/argscheck');
+const exec = require('cordova/exec');
+const Camera = require('./Camera');
// XXX: commented out
// CameraPopoverHandle = require('./CameraPopoverHandle');
@@ -32,10 +32,10 @@ var Camera = require('./Camera');
/**
* @exports camera
*/
-var cameraExport = {};
+const cameraExport = {};
// Tack on the Camera Constants to the base camera plugin.
-for (var key in Camera) {
+for (const key in Camera) {
cameraExport[key] = Camera[key];
}
@@ -114,14 +114,8 @@ for (var key in Camera) {
* __Supported Platforms__
*
* - Android
- * - BlackBerry
* - Browser
- * - Firefox
- * - FireOS
* - iOS
- * - Windows
- * - WP8
- * - Ubuntu
*
* More examples [here](#camera-getPicture-examples). Quirks [here](#camera-getPicture-quirks).
*
@@ -134,22 +128,22 @@ for (var key in Camera) {
cameraExport.getPicture = function (successCallback, errorCallback, options) {
argscheck.checkArgs('fFO', 'Camera.getPicture', arguments);
options = options || {};
- var getValue = argscheck.getValue;
+ const getValue = argscheck.getValue;
- var quality = getValue(options.quality, 50);
- var destinationType = getValue(options.destinationType, Camera.DestinationType.FILE_URI);
- var sourceType = getValue(options.sourceType, Camera.PictureSourceType.CAMERA);
- var targetWidth = getValue(options.targetWidth, -1);
- var targetHeight = getValue(options.targetHeight, -1);
- var encodingType = getValue(options.encodingType, Camera.EncodingType.JPEG);
- var mediaType = getValue(options.mediaType, Camera.MediaType.PICTURE);
- var allowEdit = !!options.allowEdit;
- var correctOrientation = !!options.correctOrientation;
- var saveToPhotoAlbum = !!options.saveToPhotoAlbum;
- var popoverOptions = getValue(options.popoverOptions, null);
- var cameraDirection = getValue(options.cameraDirection, Camera.Direction.BACK);
+ const quality = getValue(options.quality, 50);
+ const destinationType = getValue(options.destinationType, Camera.DestinationType.FILE_URI);
+ const sourceType = getValue(options.sourceType, Camera.PictureSourceType.CAMERA);
+ const targetWidth = getValue(options.targetWidth, -1);
+ const targetHeight = getValue(options.targetHeight, -1);
+ const encodingType = getValue(options.encodingType, Camera.EncodingType.JPEG);
+ const mediaType = getValue(options.mediaType, Camera.MediaType.PICTURE);
+ const allowEdit = !!options.allowEdit;
+ const correctOrientation = !!options.correctOrientation;
+ const saveToPhotoAlbum = !!options.saveToPhotoAlbum;
+ const popoverOptions = getValue(options.popoverOptions, null);
+ const cameraDirection = getValue(options.cameraDirection, Camera.Direction.BACK);
- var args = [quality, destinationType, sourceType, targetWidth, targetHeight, encodingType,
+ const args = [quality, destinationType, sourceType, targetWidth, targetHeight, encodingType,
mediaType, allowEdit, correctOrientation, saveToPhotoAlbum, popoverOptions, cameraDirection];
exec(successCallback, errorCallback, 'Camera', 'takePicture', args);
diff --git a/www/CameraConstants.js b/www/CameraConstants.js
index d92d38157..32fe6a360 100644
--- a/www/CameraConstants.js
+++ b/www/CameraConstants.js
@@ -26,20 +26,14 @@ module.exports = {
/**
* @description
* Defines the output format of `Camera.getPicture` call.
- * _Note:_ On iOS passing `DestinationType.NATIVE_URI` along with
- * `PictureSourceType.PHOTOLIBRARY` or `PictureSourceType.SAVEDPHOTOALBUM` will
- * disable any image modifications (resize, quality change, cropping, etc.) due
- * to implementation specific.
*
* @enum {number}
*/
DestinationType: {
- /** Return base64 encoded string. DATA_URL can be very memory intensive and cause app crashes or out of memory errors. Use FILE_URI or NATIVE_URI if possible */
+ /** Return base64 encoded string. DATA_URL can be very memory intensive and cause app crashes or out of memory errors. Use FILE_URI if possible */
DATA_URL: 0,
/** Return file uri (content://media/external/images/media/2 for Android) */
- FILE_URI: 1,
- /** Return native uri (eg. asset-library://... for iOS) */
- NATIVE_URI: 2
+ FILE_URI: 1
},
/**
* @enum {number}
@@ -64,9 +58,6 @@ module.exports = {
/**
* @description
* Defines the output format of `Camera.getPicture` call.
- * _Note:_ On iOS passing `PictureSourceType.PHOTOLIBRARY` or `PictureSourceType.SAVEDPHOTOALBUM`
- * along with `DestinationType.NATIVE_URI` will disable any image modifications (resize, quality
- * change, cropping, etc.) due to implementation specific.
*
* @enum {number}
*/
diff --git a/www/CameraPopoverHandle.js b/www/CameraPopoverHandle.js
index 211ae74b1..f7252d40c 100644
--- a/www/CameraPopoverHandle.js
+++ b/www/CameraPopoverHandle.js
@@ -23,7 +23,7 @@
* @ignore in favour of iOS' one
* A handle to an image picker popover.
*/
-var CameraPopoverHandle = function () {
+const CameraPopoverHandle = function () {
this.setPosition = function (popoverOptions) {
console.log('CameraPopoverHandle.setPosition is only supported on iOS.');
};
diff --git a/www/CameraPopoverOptions.js b/www/CameraPopoverOptions.js
index 14829fd56..68e8ae199 100644
--- a/www/CameraPopoverOptions.js
+++ b/www/CameraPopoverOptions.js
@@ -19,7 +19,7 @@
*
*/
-var Camera = require('./Camera');
+const Camera = require('./Camera');
/**
* @namespace navigator
@@ -39,14 +39,18 @@ var Camera = require('./Camera');
* @param {Number} [width=320] - width, in pixels, of the screen element onto which to anchor the popover.
* @param {Number} [height=480] - height, in pixels, of the screen element onto which to anchor the popover.
* @param {module:Camera.PopoverArrowDirection} [arrowDir=ARROW_ANY] - Direction the arrow on the popover should point.
+ * @param {Number} [popoverWidth=0] - width of the popover (0 or not specified will use apple's default width).
+ * @param {Number} [popoverHeight=0] - height of the popover (0 or not specified will use apple's default height).
*/
-var CameraPopoverOptions = function (x, y, width, height, arrowDir) {
+const CameraPopoverOptions = function (x, y, width, height, arrowDir, popoverWidth, popoverHeight) {
// information of rectangle that popover should be anchored to
this.x = x || 0;
this.y = y || 32;
this.width = width || 320;
this.height = height || 480;
this.arrowDir = arrowDir || Camera.PopoverArrowDirection.ARROW_ANY;
+ this.popoverWidth = popoverWidth || 0;
+ this.popoverHeight = popoverHeight || 0;
};
module.exports = CameraPopoverOptions;
diff --git a/www/ios/CameraPopoverHandle.js b/www/ios/CameraPopoverHandle.js
index 6912a4e44..b3ac04f54 100644
--- a/www/ios/CameraPopoverHandle.js
+++ b/www/ios/CameraPopoverHandle.js
@@ -19,7 +19,7 @@
*
*/
-var exec = require('cordova/exec');
+const exec = require('cordova/exec');
/**
* @namespace navigator
@@ -37,18 +37,18 @@ var exec = require('cordova/exec');
* {
* destinationType: Camera.DestinationType.FILE_URI,
* sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
- * popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY)
+ * popoverOptions: new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY, 300, 600)
* });
*
* // Reposition the popover if the orientation changes.
* window.onorientationchange = function() {
* var cameraPopoverHandle = new CameraPopoverHandle();
- * var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
+ * var cameraPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY, 400, 500);
* cameraPopoverHandle.setPosition(cameraPopoverOptions);
* }
* @module CameraPopoverHandle
*/
-var CameraPopoverHandle = function () {
+const CameraPopoverHandle = function () {
/**
* Can be used to reposition the image selection dialog,
* for example, when the device orientation changes.
@@ -58,7 +58,7 @@ var CameraPopoverHandle = function () {
* @param {module:CameraPopoverOptions} popoverOptions
*/
this.setPosition = function (popoverOptions) {
- var args = [ popoverOptions ];
+ const args = [popoverOptions];
exec(null, null, 'Camera', 'repositionPopover', args);
};
};