This repository has been archived by the owner on Mar 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 100
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #468 from ArkEcosystem/refactor/ionic-4
refactor: migrate from Ionic 3 to 4
- Loading branch information
Showing
538 changed files
with
41,717 additions
and
30,394 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
# EditorConfig helps developers define and maintain consistent coding styles between different editors and IDEs | ||
# editorconfig.org | ||
|
||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
# We recommend you to keep these unchanged | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
end_of_line = lf | ||
insert_final_newline = true | ||
indent_style = tab | ||
indent_size = 4 | ||
trim_trailing_whitespace = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
trim_trailing_whitespace = false | ||
|
||
[*.yml] | ||
trim_trailing_whitespace = false | ||
indent_size = 2 | ||
indent_style = space |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,29 @@ | ||
name: Lint | ||
|
||
on: | ||
push: | ||
branches: | ||
- '**' | ||
pull_request: | ||
types: [ready_for_review, synchronize, opened] | ||
push: | ||
branches: | ||
- "**" | ||
pull_request: | ||
types: [ready_for_review, synchronize, opened] | ||
|
||
jobs: | ||
source: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [10.x, 12.x] | ||
node-version: [12.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
node-version: ${{ matrix.node-version }} | ||
- name: Install pre dependencies | ||
run: yarn global add ionic@4.x cordova@8.x | ||
run: npm install -g ionic cordova | ||
- name: Install | ||
run: npm rebuild node-sass && yarn install --frozen-lockfile | ||
run: npm rebuild node-sass && npm install | ||
- name: Lint | ||
run: npm run lint --bailOnLintError true | ||
run: npm run lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"*.ts": ["tslint -c tslint.json --fix", "prettier --write"], | ||
"src/**/*.ts": ["ng-lint-staged lint --fix --"], | ||
"*.{css,pcss,scss,html,json,md,js}": ["prettier --write"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
10 | ||
12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"printWidth": 80, | ||
"singleQuote": false, | ||
"tabWidth": 4, | ||
"trailingComma": "all", | ||
"useTabs": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
* @luciorubeens @alexbarnsley | ||
* @luciorubeens @alexbarnsley |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
MIT License | ||
|
||
Copyright (c) 2017 Ark.io, Lúcio Rubens <[email protected]>, Alex Barnsley <alex@ark.io> | ||
Copyright (c) ARK Ecosystem <info@ark.io> | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
|
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,80 +13,122 @@ | |
|
||
> Lead Maintainer: [Lúcio Rubens](https://github.com/luciorubeens) | ||
ARK’s mobile wallet is a hybrid application (using the same codebase for Android and iOS which helps with coordinated development). Created using Ionic framework and ARK’s [TypeScript API](https://github.com/ArkEcosystem/ark-ts) to interact with the ARK network via your mobile phone, anytime, anywhere (as long as you have an internet connection). | ||
ARK’s mobile wallet is a hybrid application (using the same codebase for Android and iOS which helps with coordinated development). | ||
|
||
## Download | ||
|
||
- [Google Play](https://play.google.com/store/apps/details?id=io.ark.wallet.mobile) | ||
- [App Store](https://itunes.apple.com/us/app/mobile-ark/id1324625967) | ||
|
||
## Features | ||
|
||
- Import your existing passphrase (import by QR Scanner or write/paste your passphrase). | ||
- Generate a new passphrase. | ||
- Encrypt access to your profile with a custom 6 digit PIN (AES256+PBKDF2). | ||
- Most transaction types are available: send, receive, vote, unvote, register a delegate. | ||
- Connects to both mainnet and devnet. | ||
- Option for additional profiles (separate profiles for different ARK addresses or networks). | ||
- Option to add contacts and easily transact with them. | ||
- Total balance of your combined ARK addresses. | ||
- Wallet backup - input your selected PIN to decrypt your wallet and gain view of your private data. | ||
- Change PIN - if you want to change your encryption/decryption PIN you can easily do so. | ||
- Clear Data - you can clear all your data from the phone. | ||
- Overview of network status with an option to change peer. | ||
- Current market value, along with weekly movements. | ||
- Support for showing data in different FIAT currencies. | ||
## Installation | ||
|
||
## Build | ||
### Node Setup | ||
|
||
Download and install [Node.js](https://nodejs.org/). | ||
|
||
First follow the steps below to install the dependencies: | ||
Then follow the steps below: | ||
|
||
```bash | ||
$ npm install -g ionic [email protected] | ||
$ npm install | ||
$ ionic cordova prepare | ||
npm install -g ionic cordova | ||
npm install -g cordova-res native-run | ||
npm install | ||
ionic cordova prepare | ||
``` | ||
|
||
Run on device: | ||
### iOS Setup | ||
|
||
Download and install [Xcode](https://developer.apple.com/xcode/). | ||
|
||
Then make sure the command-line tools are selected for use: | ||
|
||
```bash | ||
$ ionic cordova run ios | ||
$ ionic cordova run android | ||
xcode-select --install | ||
``` | ||
|
||
Debug in browser: | ||
And you need to install some utilities: | ||
|
||
```bash | ||
$ npm run ionic:serve | ||
npm install -g ios-sim | ||
npm install -g ios-deploy | ||
``` | ||
|
||
## Testing | ||
### Android Setup | ||
|
||
Download and install: | ||
|
||
- [JDK8](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) | ||
- [Gradle](https://gradle.org/install/) | ||
- [Android Studio](https://developer.android.com/studio/) | ||
|
||
Then install Android SDK (API 28) on Android Studio and configure the [environment variables](https://developer.android.com/studio/command-line/variables) (`ANDROID_SDK_ROOT`). | ||
|
||
## Usage | ||
|
||
Debug in device: | ||
|
||
```bash | ||
npm run debug:ios | ||
npm run debug:android | ||
``` | ||
|
||
Debug in browser (without Cordova plugins): | ||
|
||
```bash | ||
npm start | ||
``` | ||
|
||
## Build | ||
|
||
Run the command to create a build for the specific platform: | ||
|
||
```bash | ||
npm run build:ios | ||
npm run build:android | ||
``` | ||
|
||
### iOS Deploy | ||
|
||
- Download the `Development` and `Distribution` certificates in [Apple's member center](https://developer.apple.com/membercenter) | ||
- Open Xcode and import the workspace file in `/platforms/ios` | ||
- Check the `Signing and Capabilities` tab to ensure that the `Provisioning Profile` is set correctly | ||
- Go to `Product` > `Archive` in menu. | ||
- Proceed in `Distribute App` wizard. | ||
- `App Store Connect` > `Upload`. Then it will be listed on [iTunes Connect](https://itunesconnect.apple.com/) | ||
- `App Store Connect` > `Export` to create the `.ipa` file | ||
|
||
### Android Deploy | ||
|
||
- Open the output directory `cd platforms/android/build/outputs/apk` | ||
- Generate a private key to sign the APK (skip this if you already have one): | ||
|
||
To run the unit tests: | ||
```bash | ||
$ npm test | ||
keytool -genkey -v -keystore release-key.keystore -alias ark -keyalg RSA -keysize 2048 -validity 10000 | ||
``` | ||
|
||
To run the unit tests and watch them: | ||
- Sign the unsigned APK: | ||
|
||
```bash | ||
$ npm run test:unit | ||
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore ./release-key.keystore app-release-unsigned.apk mobile-app | ||
``` | ||
|
||
To run the unit tests and generate a coverage report: | ||
- Optimize the APK: | ||
|
||
```bash | ||
$ npm run test:coverage | ||
zipalign -v 4 app-release-unsigned.apk AppRelease.apk | ||
``` | ||
|
||
To run the E2E (end to end) tests: | ||
- Open the [Google Play Store Developer Console](https://play.google.com/apps/publish) and upload the `AppRelease.apk` | ||
|
||
## Testing | ||
|
||
```bash | ||
$ npm run test:e2e | ||
npm test | ||
``` | ||
|
||
## Contributing | ||
|
||
- If you find any bugs, submit an [issue](../../issues) or open [pull-request](../../pulls), helping us catch and fix them. | ||
- Engage with other users and developers on [ARK Slack](https://ark.io/slack/). | ||
- Join to our [gitter](https://gitter.im/ark-developers/Lobby). | ||
- [Contribution bounties](https://docs.ark.io/guidebook/contribution-guidelines/contributing.html). | ||
- [Help translate](./TRANSLATING.md). | ||
|
||
|
@@ -100,4 +142,4 @@ This project exists thanks to all the people who [contribute](../../contributors | |
|
||
## License | ||
|
||
[MIT](LICENSE) © [ARK Ecosystem](https://ark.io) | ||
[MIT](LICENSE) © [ARK Ecosystem](https://ark.io) |
Oops, something went wrong.