├── .watchmanconfig ├── .gitattributes ├── .babelrc ├── snap-1.png ├── snap-2.png ├── app.json ├── ios ├── Icomoon.ttf ├── main.jsbundle.meta ├── assets │ ├── font │ │ └── Icomoon.ttf │ └── src │ │ └── images │ │ └── background.jpg ├── Images.xcassets │ ├── Contents.json │ ├── AppIcon.appiconset │ │ ├── icon-29.png │ │ ├── icon-40.png │ │ ├── icon-50.png │ │ ├── icon-57.png │ │ ├── icon-72.png │ │ ├── icon-76.png │ │ ├── icon-1024.png │ │ ├── icon-20-ipad.png │ │ ├── icon-20@2x.png │ │ ├── icon-20@3x.png │ │ ├── icon-29-ipad.png │ │ ├── icon-29@2x.png │ │ ├── icon-29@3x.png │ │ ├── icon-40@2x.png │ │ ├── icon-40@3x.png │ │ ├── icon-50@2x.png │ │ ├── icon-57@2x.png │ │ ├── icon-60@2x.png │ │ ├── icon-60@3x.png │ │ ├── icon-72@2x.png │ │ ├── icon-76@2x.png │ │ ├── icon-83.5@2x.png │ │ ├── icon-20@2x-ipad.png │ │ ├── icon-29@2x-ipad.png │ │ └── Contents.json │ └── logo-blue.imageset │ │ ├── logo-blue.png │ │ └── Contents.json ├── CoinOnline │ ├── AppDelegate.h │ ├── main.m │ ├── AppDelegate.m │ ├── Info.plist │ └── Base.lproj │ │ └── LaunchScreen.xib ├── CoinOnlineTests │ ├── Info.plist │ └── CoinOnlineTests.m ├── CoinOnline-tvOSTests │ └── Info.plist ├── CoinOnline-tvOS │ └── Info.plist └── CoinOnline.xcodeproj │ └── xcshareddata │ └── xcschemes │ ├── CoinOnline.xcscheme │ └── CoinOnline-tvOS.xcscheme ├── Fonts ├── Entypo.ttf ├── Feather.ttf ├── Zocial.ttf ├── EvilIcons.ttf ├── Foundation.ttf ├── Ionicons.ttf ├── Octicons.ttf ├── FontAwesome.ttf ├── MaterialIcons.ttf ├── SimpleLineIcons.ttf └── MaterialCommunityIcons.ttf ├── src ├── images │ ├── logo.png │ ├── more.png │ └── background.jpg ├── icon │ ├── fonts │ │ ├── Icomoon.ttf │ │ ├── icomoon.eot │ │ └── icomoon.woff │ ├── data.js │ ├── Read Me.txt │ ├── demo-files │ │ ├── demo.js │ │ └── demo.css │ ├── style.css │ ├── config.js │ └── demo.html ├── navigation │ ├── MyStackNavigation.js │ └── TabNavigation.js ├── component │ ├── HeaderTitle.js │ ├── CoinIcon.js │ ├── Counter.js │ ├── CoinCard.js │ ├── CoinItem.js │ └── HeaderMain.js ├── actions │ └── actions.js ├── middleware │ └── CustomMiddleware.js ├── reducers │ └── reducers.js └── page │ ├── MainController.js │ ├── SelectCoinController.js │ ├── SettingController.js │ ├── ChangeBase.js │ └── AddCoinController.js ├── bundle ├── main.jsbundle.meta └── assets │ └── src │ └── images │ └── background.jpg ├── android ├── app │ ├── src │ │ └── main │ │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── styles.xml │ │ │ ├── mipmap-hdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-mdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ └── mipmap-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── assets │ │ │ └── fonts │ │ │ │ ├── Entypo.ttf │ │ │ │ ├── Feather.ttf │ │ │ │ ├── Roboto.ttf │ │ │ │ ├── Zocial.ttf │ │ │ │ ├── EvilIcons.ttf │ │ │ │ ├── Ionicons.ttf │ │ │ │ ├── Octicons.ttf │ │ │ │ ├── FontAwesome.ttf │ │ │ │ ├── Foundation.ttf │ │ │ │ ├── MaterialIcons.ttf │ │ │ │ ├── Roboto_medium.ttf │ │ │ │ ├── SimpleLineIcons.ttf │ │ │ │ ├── rubicon-icon-font.ttf │ │ │ │ └── MaterialCommunityIcons.ttf │ │ │ ├── java │ │ │ └── com │ │ │ │ └── coinonline │ │ │ │ ├── MainActivity.java │ │ │ │ └── MainApplication.java │ │ │ └── AndroidManifest.xml │ ├── BUCK │ ├── proguard-rules.pro │ └── build.gradle ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── keystores │ ├── debug.keystore.properties │ └── BUCK ├── settings.gradle ├── build.gradle ├── gradle.properties ├── gradlew.bat └── gradlew ├── .buckconfig ├── __tests__ └── App.js ├── README-CN.md ├── LICENSE ├── README.md ├── .eslintrc ├── .gitignore ├── package.json ├── index.js └── .flowconfig /.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["react-native"] 3 | } 4 | -------------------------------------------------------------------------------- /snap-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/snap-1.png -------------------------------------------------------------------------------- /snap-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/snap-2.png -------------------------------------------------------------------------------- /app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "CoinOnline", 3 | "displayName": "CoinOnline" 4 | } -------------------------------------------------------------------------------- /ios/Icomoon.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Icomoon.ttf -------------------------------------------------------------------------------- /Fonts/Entypo.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Entypo.ttf -------------------------------------------------------------------------------- /Fonts/Feather.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Feather.ttf -------------------------------------------------------------------------------- /Fonts/Zocial.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Zocial.ttf -------------------------------------------------------------------------------- /Fonts/EvilIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/EvilIcons.ttf -------------------------------------------------------------------------------- /Fonts/Foundation.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Foundation.ttf -------------------------------------------------------------------------------- /Fonts/Ionicons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Ionicons.ttf -------------------------------------------------------------------------------- /Fonts/Octicons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/Octicons.ttf -------------------------------------------------------------------------------- /src/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/images/logo.png -------------------------------------------------------------------------------- /src/images/more.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/images/more.png -------------------------------------------------------------------------------- /Fonts/FontAwesome.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/FontAwesome.ttf -------------------------------------------------------------------------------- /ios/main.jsbundle.meta: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/main.jsbundle.meta -------------------------------------------------------------------------------- /Fonts/MaterialIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/MaterialIcons.ttf -------------------------------------------------------------------------------- /Fonts/SimpleLineIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/SimpleLineIcons.ttf -------------------------------------------------------------------------------- /bundle/main.jsbundle.meta: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/bundle/main.jsbundle.meta -------------------------------------------------------------------------------- /src/images/background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/images/background.jpg -------------------------------------------------------------------------------- /ios/assets/font/Icomoon.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/assets/font/Icomoon.ttf -------------------------------------------------------------------------------- /src/icon/fonts/Icomoon.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/icon/fonts/Icomoon.ttf -------------------------------------------------------------------------------- /src/icon/fonts/icomoon.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/icon/fonts/icomoon.eot -------------------------------------------------------------------------------- /src/icon/fonts/icomoon.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/src/icon/fonts/icomoon.woff -------------------------------------------------------------------------------- /Fonts/MaterialCommunityIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/Fonts/MaterialCommunityIcons.ttf -------------------------------------------------------------------------------- /ios/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | CoinOnline 3 | 4 | -------------------------------------------------------------------------------- /ios/assets/src/images/background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/assets/src/images/background.jpg -------------------------------------------------------------------------------- /bundle/assets/src/images/background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/bundle/assets/src/images/background.jpg -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Entypo.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Entypo.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Feather.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Feather.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Roboto.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Roboto.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Zocial.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Zocial.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/EvilIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/EvilIcons.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Ionicons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Ionicons.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Octicons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Octicons.ttf -------------------------------------------------------------------------------- /.buckconfig: -------------------------------------------------------------------------------- 1 | 2 | [android] 3 | target = Google Inc.:Google APIs:23 4 | 5 | [maven_repositories] 6 | central = https://repo1.maven.org/maven2 7 | -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/FontAwesome.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/FontAwesome.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Foundation.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Foundation.ttf -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-29.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-40.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-50.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-57.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-72.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-76.png -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/MaterialIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/MaterialIcons.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/Roboto_medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/Roboto_medium.ttf -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-1024.png -------------------------------------------------------------------------------- /ios/Images.xcassets/logo-blue.imageset/logo-blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/logo-blue.imageset/logo-blue.png -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/SimpleLineIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/SimpleLineIcons.ttf -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/rubicon-icon-font.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/rubicon-icon-font.ttf -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-20-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-20-ipad.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-20@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-20@3x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-29-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-29-ipad.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-29@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-29@3x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-40@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-40@3x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-50@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-50@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-57@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-57@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-60@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-60@3x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-72@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-76@2x.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-83.5@2x.png -------------------------------------------------------------------------------- /android/keystores/debug.keystore.properties: -------------------------------------------------------------------------------- 1 | key.store=debug.keystore 2 | key.alias=androiddebugkey 3 | key.store.password=android 4 | key.alias.password=android 5 | -------------------------------------------------------------------------------- /android/app/src/main/assets/fonts/MaterialCommunityIcons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/android/app/src/main/assets/fonts/MaterialCommunityIcons.ttf -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-20@2x-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-20@2x-ipad.png -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/icon-29@2x-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yfgeek/CoinOnline/HEAD/ios/Images.xcassets/AppIcon.appiconset/icon-29@2x-ipad.png -------------------------------------------------------------------------------- /android/keystores/BUCK: -------------------------------------------------------------------------------- 1 | keystore( 2 | name = "debug", 3 | properties = "debug.keystore.properties", 4 | store = "debug.keystore", 5 | visibility = [ 6 | "PUBLIC", 7 | ], 8 | ) 9 | -------------------------------------------------------------------------------- /src/icon/data.js: -------------------------------------------------------------------------------- 1 | let data = require('./selection.json'); 2 | let arr = []; 3 | data.icons.forEach((item)=>{ 4 | arr.push( 5 | { 6 | 'cuy' : item.icon.tags[0], 7 | 'color' :item.icon.attrs[0].fill, 8 | }) 9 | }); 10 | console.log(arr) 11 | 12 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip 6 | -------------------------------------------------------------------------------- /__tests__/App.js: -------------------------------------------------------------------------------- 1 | import 'react-native'; 2 | import React from 'react'; 3 | import App from '../src/App'; 4 | 5 | // Note: test renderer must be required after react-native. 6 | import renderer from 'react-test-renderer'; 7 | 8 | it('renders correctly', () => { 9 | const tree = renderer.create( 10 | 11 | ); 12 | }); 13 | -------------------------------------------------------------------------------- /README-CN.md: -------------------------------------------------------------------------------- 1 | # 数字货币钱包 2 | 3 | 4 | 5 | 一个数字货币钱包APP,基于React Native + Redux,支持上百种数字货币,用户可以添加货币及金额,APP根据实时汇率计算出用户设置的货币单位的价格,同时支持iOS和Android客户端。 6 | 7 | - [x] 支持添加数百种数字货币 8 | - [ ] 支持更改基准货币 9 | - [x] 实时API数据 10 | - [x] 数据持久化 11 | 12 | 目前还在开发中...兴趣使然,一个练手项目而已。 13 | 14 | # 截图 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /ios/Images.xcassets/logo-blue.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "logo-blue.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /android/app/src/main/java/com/coinonline/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.coinonline; 2 | 3 | import com.facebook.react.ReactActivity; 4 | 5 | public class MainActivity extends ReactActivity { 6 | 7 | /** 8 | * Returns the name of the main component registered from JavaScript. 9 | * This is used to schedule rendering of the component. 10 | */ 11 | @Override 12 | protected String getMainComponentName() { 13 | return "CoinOnline"; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 2 | Version 2, December 2004 3 | 4 | Copyright (C) 2017 Yifan Wu 5 | 6 | Everyone is permitted to copy and distribute verbatim or modified 7 | copies of this license document, and changing it is allowed as long 8 | as the name is changed. 9 | 10 | DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 11 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 12 | 13 | 0. You just DO WHAT THE FUCK YOU WANT TO. 14 | -------------------------------------------------------------------------------- /ios/CoinOnline/AppDelegate.h: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | */ 9 | 10 | #import 11 | 12 | @interface AppDelegate : UIResponder 13 | 14 | @property (nonatomic, strong) UIWindow *window; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'CoinOnline' 2 | include ':react-native-svg' 3 | project(':react-native-svg').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-svg/android') 4 | include ':react-native-spinkit' 5 | project(':react-native-spinkit').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-spinkit/android') 6 | include ':react-native-vector-icons' 7 | project(':react-native-vector-icons').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-vector-icons/android') 8 | 9 | include ':app' 10 | -------------------------------------------------------------------------------- /ios/CoinOnline/main.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | */ 9 | 10 | #import 11 | 12 | #import "AppDelegate.h" 13 | 14 | int main(int argc, char * argv[]) { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/navigation/MyStackNavigation.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { StackNavigator } from 'react-navigation'; 3 | import AddCoinController from "../page/AddCoinController"; 4 | import MainController from "../page/MainController"; 5 | import TabNavigation from "./TabNavigation"; 6 | import SelectCoinController from "../page/SettingController" 7 | 8 | 9 | const MyStackNavigation = StackNavigator({ 10 | Main: {screen: TabNavigation}, 11 | SelectCoinController: { screen: SelectCoinController }, 12 | AddCoinController: { screen: AddCoinController }, 13 | MainController: { screen: MainController }, 14 | }); 15 | 16 | 17 | export default MyStackNavigation; -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Cryptocurrency Wallet 2 | 3 | 4 | 5 | This is a cryptocurrency wallet application for Android and iOS, supporting for hundreds of cryptocurrencies. [中文页面](README-CN.md) 6 | 7 | The wallet is based on React Native and Redux. The supporting features can be listed as below. 8 | 9 | - [x] Adding, editing or deleting hundreds of cryptocurrencies 10 | - [ ] Editing the base currency 11 | - [x] Real-Time cryptocurrency infromation ,fetching from API 12 | - [x] Data persistence 13 | 14 | More features are going to be designed and implemented. 15 | 16 | # Snapshot 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "parser": "babel-eslint", 3 | "extends": "airbnb-base", 4 | "env": { 5 | "jest": true 6 | }, 7 | "plugins": [ 8 | "react", 9 | "react-native" 10 | ], 11 | "parserOptions": { 12 | "ecmaFeatures": { 13 | "jsx": true 14 | } 15 | }, 16 | "rules": { 17 | "react/jsx-uses-vars": 2, 18 | "react/jsx-uses-react": 2, 19 | "comma-dangle": [ 20 | "error", 21 | { 22 | "arrays": "never", 23 | "objects": "never" 24 | } 25 | ], 26 | "no-underscore-dangle": [ 27 | "error", 28 | { 29 | "allowAfterThis": true 30 | } 31 | ] 32 | }, 33 | "globals": { 34 | "fetch": true 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /src/icon/Read Me.txt: -------------------------------------------------------------------------------- 1 | Open *demo.html* to see a list of all the glyphs in your font along with their codes/ligatures. 2 | 3 | To use the generated font in desktop programs, you can install the TTF font. In order to copy the character associated with each icon, refer to the text box at the bottom right corner of each glyph in demo.html. The character inside this text box may be invisible; but it can still be copied. See this guide for more info: https://icomoon.io/#docs/local-fonts 4 | 5 | You won't need any of the files located under the *demo-files* directory when including the generated font in your own projects. 6 | 7 | You can import *selection.json* back to the IcoMoon app using the *Import Icons* button (or via Main Menu → Manage Projects) to retrieve your icon selection. 8 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | jcenter() 6 | } 7 | dependencies { 8 | classpath 'com.android.tools.build:gradle:2.2.3' 9 | 10 | // NOTE: Do not place your application dependencies here; they belong 11 | // in the individual module build.gradle files 12 | } 13 | } 14 | 15 | allprojects { 16 | repositories { 17 | // Add jitpack repository (added by react-native-spinkit) 18 | maven { url "https://jitpack.io" } 19 | mavenLocal() 20 | jcenter() 21 | maven { 22 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm 23 | url "$rootDir/../node_modules/react-native/android" 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ios/CoinOnlineTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /ios/CoinOnline-tvOSTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | android.useDeprecatedNdk=true 21 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # OSX 2 | # 3 | .DS_Store 4 | 5 | # Xcode 6 | # 7 | build/ 8 | *.pbxuser 9 | !default.pbxuser 10 | *.mode1v3 11 | !default.mode1v3 12 | *.mode2v3 13 | !default.mode2v3 14 | *.perspectivev3 15 | !default.perspectivev3 16 | xcuserdata 17 | *.xccheckout 18 | *.moved-aside 19 | DerivedData 20 | *.hmap 21 | *.ipa 22 | *.xcuserstate 23 | project.xcworkspace 24 | 25 | # Android/IntelliJ 26 | # 27 | build/ 28 | .idea 29 | .gradle 30 | local.properties 31 | *.iml 32 | 33 | # node.js 34 | # 35 | node_modules/ 36 | npm-debug.log 37 | yarn-error.log 38 | 39 | # BUCK 40 | buck-out/ 41 | \.buckd/ 42 | *.keystore 43 | 44 | # fastlane 45 | # 46 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 47 | # screenshots whenever they are needed. 48 | # For more information about the recommended setup visit: 49 | # https://docs.fastlane.tools/best-practices/source-control/ 50 | 51 | */fastlane/report.xml 52 | */fastlane/Preview.html 53 | */fastlane/screenshots 54 | -------------------------------------------------------------------------------- /src/component/HeaderTitle.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Text 5 | } from 'react-native'; 6 | 7 | class HeaderTitle extends Component { 8 | constructor(props) { 9 | super(props); 10 | } 11 | 12 | render() { 13 | const title = this.props.title ? this.props.title : '未设置标题'; 14 | const headerColor = this.props.color ? this.props.color : '#364c62'; 15 | const indent = this.props.indent ? this.props.indent : 10; 16 | return ( 17 | 20 | 23 | 24 | 25 | { title } 28 | 29 | 30 | 31 | 32 | ); 33 | } 34 | } 35 | 36 | 37 | export default HeaderTitle; 38 | -------------------------------------------------------------------------------- /src/icon/demo-files/demo.js: -------------------------------------------------------------------------------- 1 | if (!('boxShadow' in document.body.style)) { 2 | document.body.setAttribute('class', 'noBoxShadow'); 3 | } 4 | 5 | document.body.addEventListener("click", function(e) { 6 | var target = e.target; 7 | if (target.tagName === "INPUT" && 8 | target.getAttribute('class').indexOf('liga') === -1) { 9 | target.select(); 10 | } 11 | }); 12 | 13 | (function() { 14 | var fontSize = document.getElementById('fontSize'), 15 | testDrive = document.getElementById('testDrive'), 16 | testText = document.getElementById('testText'); 17 | function updateTest() { 18 | testDrive.innerHTML = testText.value || String.fromCharCode(160); 19 | if (window.icomoonLiga) { 20 | window.icomoonLiga(testDrive); 21 | } 22 | } 23 | function updateSize() { 24 | testDrive.style.fontSize = fontSize.value + 'px'; 25 | } 26 | fontSize.addEventListener('change', updateSize, false); 27 | testText.addEventListener('input', updateTest, false); 28 | testText.addEventListener('change', updateTest, false); 29 | updateSize(); 30 | }()); 31 | -------------------------------------------------------------------------------- /src/actions/actions.js: -------------------------------------------------------------------------------- 1 | /* 2 | * action 类型 3 | */ 4 | 5 | export const ADD_COIN = 'ADD_COIN'; 6 | export const DELETE_COIN = 'DELETE_COIN'; 7 | export const EDIT_COIN = 'EDIT_COIN'; 8 | export const REMOVE_ALL = 'REMOVE_ALL'; 9 | 10 | 11 | export const SHOW_SETTING = 'SHOW_SETTING'; 12 | export const UPDATE_SETTING = 'UPDATE_SETTING'; 13 | export const INITIAL_SETTING = 'INITIAL_SETTING'; 14 | 15 | export const MODE_ADD = 'MODE_ADD'; 16 | export const MODE_EDIT = 'MODE_EDIT'; 17 | 18 | 19 | /* 20 | * 其它的常量 21 | */ 22 | 23 | export const VisibilityFilters = { 24 | SHOW_ALL: 'SHOW_ALL', 25 | SHOW_COMPLETED: 'SHOW_COMPLETED', 26 | SHOW_ACTIVE: 'SHOW_ACTIVE', 27 | }; 28 | 29 | /* 30 | * action 创建函数 31 | */ 32 | 33 | 34 | export function addCoin(text, numbers, balance, description) { 35 | return { 36 | type: ADD_COIN, text, numbers, balance, description, 37 | }; 38 | } 39 | 40 | export function deleteCoin(index) { 41 | return { type: DELETE_COIN, index }; 42 | } 43 | export function editCoin(index, text, numbers, balance, description) { 44 | return { 45 | type: EDIT_COIN, index, text, numbers, balance, description, 46 | }; 47 | } 48 | 49 | export function removeAllCoins() { 50 | return { type: REMOVE_ALL }; 51 | } 52 | -------------------------------------------------------------------------------- /src/navigation/TabNavigation.js: -------------------------------------------------------------------------------- 1 | import { StackNavigator, TabNavigator } from 'react-navigation'; 2 | import MainController from '../page/MainController'; 3 | import SettingController from '../page/SettingController'; 4 | import * as React from 'react'; 5 | import Ionicons from 'react-native-vector-icons/Ionicons'; 6 | 7 | const RouteConfigs = { 8 | MainController: { 9 | screen: MainController, 10 | navigationOptions: { 11 | tabBarLabel: '主页', 12 | tabBarIcon: ({ tintColor, focused }) => ( 13 | 18 | ) 19 | } 20 | }, 21 | SettingController: { 22 | screen: SettingController, 23 | navigationOptions: { 24 | tabBarLabel: '设置', 25 | tabBarIcon: ({ tintColor, focused }) => ( 26 | 31 | ) 32 | } 33 | } 34 | }; 35 | const TabNavigatorConfig = { 36 | swipeEnabled: false 37 | }; 38 | 39 | const RootTabs = TabNavigator(RouteConfigs, TabNavigatorConfig); 40 | 41 | export default RootTabs; 42 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 12 | 13 | 19 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "CoinOnline", 3 | "version": "0.0.1", 4 | "private": true, 5 | "scripts": { 6 | "start": "node node_modules/react-native/local-cli/cli.js start", 7 | "test": "jest" 8 | }, 9 | "dependencies": { 10 | "eslint-plugin-jsx-a11y": "^6.0.2", 11 | "isomorphic-fetch": "latest", 12 | "native-base": "^2.3.3", 13 | "react": "16.0.0-beta.5", 14 | "react-loading": "^1.0.1", 15 | "react-native": "0.49.5", 16 | "react-native-elements": "^0.18.2", 17 | "react-native-keyboard-aware-scroll-view": "latest", 18 | "react-native-modalbox": "^1.4.2", 19 | "react-native-scrollable-tab-view": "^0.8.0", 20 | "react-native-spinkit": "^1.1.1", 21 | "react-native-svg": "^5.4.2", 22 | "react-native-svg-uri": "^1.2.1", 23 | "react-native-swipeout": "^2.3.1", 24 | "react-native-textinput-effects": "^0.4.1", 25 | "react-native-ultimate-listview": "^3.2.4", 26 | "react-native-vector-icons": "^4.4.2", 27 | "react-navigation": "^1.0.0-beta.15", 28 | "react-redux": "^5.0.6", 29 | "redux": "^3.7.2", 30 | "redux-persist": "^5.4.0", 31 | "redux-thunk": "^2.2.0", 32 | "remote-redux-devtools": "^0.5.12" 33 | }, 34 | "devDependencies": { 35 | "babel-jest": "21.2.0", 36 | "babel-preset-react-native": "4.0.0", 37 | "eslint-plugin-react-native": "^3.2.0", 38 | "jest": "21.2.1", 39 | "react-test-renderer": "16.0.0-beta.5" 40 | }, 41 | "jest": { 42 | "preset": "react-native" 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /android/app/src/main/java/com/coinonline/MainApplication.java: -------------------------------------------------------------------------------- 1 | package com.coinonline; 2 | 3 | import android.app.Application; 4 | 5 | import com.facebook.react.ReactApplication; 6 | import com.horcrux.svg.SvgPackage; 7 | import com.react.rnspinkit.RNSpinkitPackage; 8 | import com.oblador.vectoricons.VectorIconsPackage; 9 | import com.facebook.react.ReactNativeHost; 10 | import com.facebook.react.ReactPackage; 11 | import com.facebook.react.shell.MainReactPackage; 12 | import com.facebook.soloader.SoLoader; 13 | 14 | import java.util.Arrays; 15 | import java.util.List; 16 | 17 | public class MainApplication extends Application implements ReactApplication { 18 | 19 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { 20 | @Override 21 | public boolean getUseDeveloperSupport() { 22 | return BuildConfig.DEBUG; 23 | } 24 | 25 | @Override 26 | protected List getPackages() { 27 | return Arrays.asList( 28 | new MainReactPackage(), 29 | new SvgPackage(), 30 | new RNSpinkitPackage(), 31 | new VectorIconsPackage() 32 | ); 33 | } 34 | 35 | @Override 36 | protected String getJSMainModuleName() { 37 | return "index"; 38 | } 39 | }; 40 | 41 | @Override 42 | public ReactNativeHost getReactNativeHost() { 43 | return mReactNativeHost; 44 | } 45 | 46 | @Override 47 | public void onCreate() { 48 | super.onCreate(); 49 | SoLoader.init(this, /* native exopackage */ false); 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | 2 | import React, { Component } from 'react'; 3 | import { 4 | AppRegistry, 5 | } from 'react-native'; 6 | import { createStore ,applyMiddleware, compose } from 'redux' 7 | import { Provider } from 'react-redux' 8 | import MyStackNavigation from "./src/navigation/MyStackNavigation"; 9 | import reducers from './src/reducers/reducers' 10 | import devToolsEnhancer from 'remote-redux-devtools'; 11 | import thunk from 'redux-thunk'; 12 | import {persistStore, persistCombineReducers} from 'redux-persist'; 13 | import { PersistGate } from 'redux-persist/es/integration/react'; 14 | 15 | import storage from 'redux-persist/es/storage' // default: localStorage if web, AsyncStorage if react-native 16 | const config = { 17 | key: 'root', 18 | storage, 19 | }; 20 | 21 | function configureStore(){ 22 | let reducer = persistCombineReducers(config, reducers); 23 | let store = createStore(reducer, compose(applyMiddleware(thunk),devToolsEnhancer({ realtime: true, port: 8000 }))); 24 | let persistor = persistStore(store); 25 | return { persistor, store } 26 | } 27 | export default class CoinOnline extends Component { 28 | render() { 29 | const { persistor, store } = configureStore(); 30 | return ( 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | ); 39 | } 40 | } 41 | AppRegistry.registerComponent('CoinOnline', () => CoinOnline); 42 | -------------------------------------------------------------------------------- /.flowconfig: -------------------------------------------------------------------------------- 1 | [ignore] 2 | ; We fork some components by platform 3 | .*/*[.]android.js 4 | 5 | ; Ignore "BUCK" generated dirs 6 | /\.buckd/ 7 | 8 | ; Ignore unexpected extra "@providesModule" 9 | .*/node_modules/.*/node_modules/fbjs/.* 10 | 11 | ; Ignore duplicate module providers 12 | ; For RN Apps installed via npm, "Libraries" folder is inside 13 | ; "node_modules/react-native" but in the source repo it is in the root 14 | .*/Libraries/react-native/React.js 15 | 16 | ; Ignore polyfills 17 | .*/Libraries/polyfills/.* 18 | 19 | [include] 20 | 21 | [libs] 22 | node_modules/react-native/Libraries/react-native/react-native-interface.js 23 | node_modules/react-native/flow/ 24 | 25 | [options] 26 | emoji=true 27 | 28 | module.system=haste 29 | 30 | munge_underscores=true 31 | 32 | module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub' 33 | 34 | suppress_type=$FlowIssue 35 | suppress_type=$FlowFixMe 36 | suppress_type=$FlowFixMeProps 37 | suppress_type=$FlowFixMeState 38 | suppress_type=$FixMe 39 | 40 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(5[0-3]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) 41 | suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(5[0-3]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ 42 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy 43 | suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError 44 | 45 | unsafe.enable_getters_and_setters=true 46 | 47 | [version] 48 | ^0.53.0 49 | -------------------------------------------------------------------------------- /ios/CoinOnline/AppDelegate.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | */ 9 | 10 | #import "AppDelegate.h" 11 | 12 | #import 13 | #import 14 | 15 | @implementation AppDelegate 16 | 17 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 18 | { 19 | NSURL *jsCodeLocation; 20 | 21 | jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil]; 22 | //jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"]; 23 | 24 | RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation 25 | moduleName:@"CoinOnline" 26 | initialProperties:nil 27 | launchOptions:launchOptions]; 28 | rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1]; 29 | 30 | self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; 31 | UIViewController *rootViewController = [UIViewController new]; 32 | rootViewController.view = rootView; 33 | self.window.rootViewController = rootViewController; 34 | [self.window makeKeyAndVisible]; 35 | return YES; 36 | } 37 | 38 | @end 39 | -------------------------------------------------------------------------------- /src/middleware/CustomMiddleware.js: -------------------------------------------------------------------------------- 1 | import {addCoin, editCoin} from "../actions/actions"; 2 | 3 | export const addCoinMiddleware = (cuy, numbers, description) => (dispatch) => { 4 | return fetch(`https://api.cryptonator.com/api/ticker/${cuy}`,{ 5 | method: 'GET', 6 | headers: new Headers(), 7 | }) 8 | .then(response => { 9 | return response.json(); 10 | }) 11 | .then(json => dispatch(addCoin( cuy, numbers, parseFloat(numbers) * json.ticker.price, description))) 12 | .catch((e)=>{ 13 | console.warn(`网络错误: ${e}`); 14 | }); 15 | }; 16 | 17 | export const editCoinMiddleware = (id, cuy, numbers, description) => (dispatch) => { 18 | return fetch(`https://api.cryptonator.com/api/ticker/${cuy}`,{ 19 | method: 'GET', 20 | headers: new Headers(), 21 | }) 22 | .then(response => response.json()) 23 | .then(json => dispatch(editCoin( id, cuy, numbers, parseFloat(numbers) * json.ticker.price, description))) 24 | .catch((e)=>{ 25 | console.warn('网络错误') 26 | }); 27 | }; 28 | 29 | 30 | // export const updateCoinMiddleware = (allMap,nation) => (dispatch) => { 31 | // let sequence = Promise.resolve(); 32 | // allMap.map((item,index)=>{ 33 | // sequence = sequence.then(function() { 34 | // return fetch(`https://api.cryptonator.com/api/ticker/${item.text}-${nation}`) 35 | // .then(response => response.json()) 36 | // .then(json => dispatch(editCoin( item.index, item.text+'-'+nation, item.numbers, parseFloat(item.numbers) * json.ticker.price, item.description))) 37 | // .catch((e)=>{ 38 | // console.warn('网络错误') 39 | // }); 40 | // }); 41 | // }); 42 | // }; 43 | 44 | -------------------------------------------------------------------------------- /src/component/CoinIcon.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Image 5 | } from 'react-native'; 6 | 7 | import { createIconSetFromIcoMoon } from 'react-native-vector-icons'; 8 | import selectionConfig from '../icon/selection.json'; 9 | import { ColorConfig, list } from '../icon/config'; 10 | 11 | const Icon = createIconSetFromIcoMoon(selectionConfig); 12 | class CoinIcon extends Component { 13 | constructor(props) { 14 | super(props); 15 | } 16 | 17 | getIcon(cuy) { 18 | cuy = cuy.toLowerCase() || 'btc'; 19 | const w = this.props.width || 48; 20 | const h = this.props.height || 48; 21 | 22 | if (cuy === 'more') { return ; } 23 | 24 | if (list.indexOf(cuy) > 0) { 25 | let color = '#f5922f'; 26 | ColorConfig.forEach((item, index) => { if (item.cuy === cuy) color = item.color; }); 27 | return ; 28 | } 29 | return ; 30 | } 31 | 32 | render() { 33 | const icon = this.getIcon(this.props.cuy); 34 | const w = this.props.width || 48; 35 | const m = this.props.marginLeft || 15; 36 | const r = this.props.marginRight || 0; 37 | return ( 38 | 50 | {icon} 51 | 52 | ); 53 | } 54 | } 55 | 56 | 57 | export default CoinIcon; 58 | -------------------------------------------------------------------------------- /ios/CoinOnline-tvOS/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UIViewControllerBasedStatusBarAppearance 38 | 39 | NSLocationWhenInUseUsageDescription 40 | 41 | NSAppTransportSecurity 42 | 43 | 44 | NSExceptionDomains 45 | 46 | localhost 47 | 48 | NSExceptionAllowsInsecureHTTPLoads 49 | 50 | 51 | 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /android/app/BUCK: -------------------------------------------------------------------------------- 1 | # To learn about Buck see [Docs](https://buckbuild.com/). 2 | # To run your application with Buck: 3 | # - install Buck 4 | # - `npm start` - to start the packager 5 | # - `cd android` 6 | # - `keytool -genkey -v -keystore keystores/debug.keystore -storepass android -alias androiddebugkey -keypass android -dname "CN=Android Debug,O=Android,C=US"` 7 | # - `./gradlew :app:copyDownloadableDepsToLibs` - make all Gradle compile dependencies available to Buck 8 | # - `buck install -r android/app` - compile, install and run application 9 | # 10 | 11 | lib_deps = [] 12 | 13 | for jarfile in glob(['libs/*.jar']): 14 | name = 'jars__' + jarfile[jarfile.rindex('/') + 1: jarfile.rindex('.jar')] 15 | lib_deps.append(':' + name) 16 | prebuilt_jar( 17 | name = name, 18 | binary_jar = jarfile, 19 | ) 20 | 21 | for aarfile in glob(['libs/*.aar']): 22 | name = 'aars__' + aarfile[aarfile.rindex('/') + 1: aarfile.rindex('.aar')] 23 | lib_deps.append(':' + name) 24 | android_prebuilt_aar( 25 | name = name, 26 | aar = aarfile, 27 | ) 28 | 29 | android_library( 30 | name = "all-libs", 31 | exported_deps = lib_deps, 32 | ) 33 | 34 | android_library( 35 | name = "app-code", 36 | srcs = glob([ 37 | "src/main/java/**/*.java", 38 | ]), 39 | deps = [ 40 | ":all-libs", 41 | ":build_config", 42 | ":res", 43 | ], 44 | ) 45 | 46 | android_build_config( 47 | name = "build_config", 48 | package = "com.coinonline", 49 | ) 50 | 51 | android_resource( 52 | name = "res", 53 | package = "com.coinonline", 54 | res = "src/main/res", 55 | ) 56 | 57 | android_binary( 58 | name = "app", 59 | keystore = "//android/keystores:debug", 60 | manifest = "src/main/AndroidManifest.xml", 61 | package_type = "debug", 62 | deps = [ 63 | ":app-code", 64 | ], 65 | ) 66 | -------------------------------------------------------------------------------- /src/component/Counter.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | Text 4 | } from 'react-native'; 5 | 6 | class Counter extends Component { 7 | static defaultProps = { 8 | commas: true, 9 | timeout: 500, 10 | steps: 10, 11 | decimal: 2 12 | }; 13 | 14 | constructor(props) { 15 | super(props); 16 | this.state = { 17 | currentStep: 0, 18 | targetValue: props.value, 19 | originalValue: props.value, 20 | currentValue: props.value 21 | }; 22 | } 23 | 24 | componentWillUnmount() { 25 | clearInterval(this._interval); 26 | } 27 | 28 | getValue(percent) { 29 | const diff = this.state.targetValue - this.state.originalValue; 30 | return (diff * percent) + parseFloat(this.state.originalValue); 31 | } 32 | 33 | componentWillReceiveProps(nextProps) { 34 | this.setState({ 35 | currentStep: 0, 36 | originalValue: this.state.currentValue || 0, 37 | targetValue: nextProps.value || 0 38 | }); 39 | clearInterval(this._interval); 40 | this._interval = setInterval(() => { 41 | if (this.state.currentStep >= this.props.steps) { 42 | clearInterval(this._interval); 43 | } 44 | this.setState({ 45 | currentValue: this.getValue(this.state.currentStep / this.props.steps).toFixed(this.props.decimal), 46 | currentStep: this.state.currentStep + 1 47 | }); 48 | }, this.props.timeout / this.props.steps); 49 | } 50 | 51 | static commas(num) { 52 | return (num || 0).toString().replace(/(?=(?!^)(?:\d{3})+(?:\.|$))(\d{3}(\.\d+$)?)/g, ',$1'); 53 | } 54 | 55 | render() { 56 | let value = this.state.currentValue; 57 | if (this.props.commas) { 58 | value = Counter.commas(value); 59 | } 60 | return ( 61 | 62 | {value} 63 | 64 | ); 65 | } 66 | } 67 | export default Counter; 68 | -------------------------------------------------------------------------------- /src/reducers/reducers.js: -------------------------------------------------------------------------------- 1 | import { combineReducers } from 'redux'; 2 | 3 | import { 4 | ADD_COIN, EDIT_COIN, DELETE_COIN, VisibilityFilters, UPDATE_SETTING, SHOW_SETTING, REMOVE_ALL 5 | } from '../actions/actions'; 6 | 7 | const { SHOW_ALL } = VisibilityFilters; 8 | 9 | function visibilityFilter(state = SHOW_ALL, action) { 10 | switch (action.type) { 11 | default: 12 | return state; 13 | } 14 | } 15 | 16 | function settings(state = { 17 | nation: 'usd' 18 | }, action) { 19 | switch (action.type) { 20 | // case INITIAL_SETTING: 21 | // return { 22 | // 'nation' : 'gbp', 23 | // }; 24 | case UPDATE_SETTING: 25 | return { 26 | nation: action.nation, 27 | storage: action.storage 28 | }; 29 | case SHOW_SETTING: 30 | return state; 31 | default: 32 | return state; 33 | } 34 | } 35 | 36 | function coins(state = [], action) { 37 | switch (action.type) { 38 | case ADD_COIN: 39 | return [ 40 | ...state, 41 | { 42 | text: action.text, 43 | numbers: action.numbers, 44 | balance: action.balance, 45 | description: action.description || '', 46 | deleted: false 47 | } 48 | ]; 49 | case EDIT_COIN: 50 | return [ 51 | ...state.slice(0, action.index), 52 | Object.assign({}, state[action.index], { 53 | text: action.text, 54 | numbers: action.numbers, 55 | balance: action.balance, 56 | description: action.description, 57 | deleted: false 58 | }), 59 | ...state.slice(action.index + 1) 60 | ]; 61 | case DELETE_COIN: 62 | return [ 63 | ...state.slice(0, action.index), 64 | Object.assign({}, state[action.index], { 65 | deleted: true 66 | }), 67 | ...state.slice(action.index + 1) 68 | ]; 69 | case REMOVE_ALL: 70 | state = []; 71 | return state; 72 | default: 73 | return state; 74 | } 75 | } 76 | 77 | const reducers = combineReducers({ 78 | coins, 79 | settings 80 | }); 81 | 82 | export default { 83 | reducer: reducers 84 | }; 85 | -------------------------------------------------------------------------------- /ios/CoinOnlineTests/CoinOnlineTests.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | */ 9 | 10 | #import 11 | #import 12 | 13 | #import 14 | #import 15 | 16 | #define TIMEOUT_SECONDS 600 17 | #define TEXT_TO_LOOK_FOR @"Welcome to React Native!" 18 | 19 | @interface CoinOnlineTests : XCTestCase 20 | 21 | @end 22 | 23 | @implementation CoinOnlineTests 24 | 25 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test 26 | { 27 | if (test(view)) { 28 | return YES; 29 | } 30 | for (UIView *subview in [view subviews]) { 31 | if ([self findSubviewInView:subview matching:test]) { 32 | return YES; 33 | } 34 | } 35 | return NO; 36 | } 37 | 38 | - (void)testRendersWelcomeScreen 39 | { 40 | UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController]; 41 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS]; 42 | BOOL foundElement = NO; 43 | 44 | __block NSString *redboxError = nil; 45 | RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) { 46 | if (level >= RCTLogLevelError) { 47 | redboxError = message; 48 | } 49 | }); 50 | 51 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) { 52 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 53 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 54 | 55 | foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) { 56 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) { 57 | return YES; 58 | } 59 | return NO; 60 | }]; 61 | } 62 | 63 | RCTSetLogFunction(RCTDefaultLogFunction); 64 | 65 | XCTAssertNil(redboxError, @"RedBox error: %@", redboxError); 66 | XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS); 67 | } 68 | 69 | 70 | @end 71 | -------------------------------------------------------------------------------- /ios/CoinOnline/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | 数字货币助手 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1 25 | LSRequiresIPhoneOS 26 | 27 | NSAllowsArbitraryLoads 28 | 29 | NSAppTransportSecurity 30 | 31 | NSExceptionDomains 32 | 33 | localhost 34 | 35 | NSExceptionAllowsInsecureHTTPLoads 36 | 37 | 38 | 39 | 40 | NSLocationWhenInUseUsageDescription 41 | 42 | UIAppFonts 43 | 44 | Entypo.ttf 45 | EvilIcons.ttf 46 | Feather.ttf 47 | FontAwesome.ttf 48 | Foundation.ttf 49 | Ionicons.ttf 50 | MaterialCommunityIcons.ttf 51 | MaterialIcons.ttf 52 | Octicons.ttf 53 | SimpleLineIcons.ttf 54 | Zocial.ttf 55 | Icomoon.ttf 56 | Roboto_medium.ttf 57 | Roboto.ttf 58 | rubicon-icon-font.ttf 59 | 60 | UILaunchStoryboardName 61 | LaunchScreen 62 | UIRequiredDeviceCapabilities 63 | 64 | armv7 65 | 66 | UISupportedInterfaceOrientations 67 | 68 | UIInterfaceOrientationPortrait 69 | UIInterfaceOrientationLandscapeLeft 70 | UIInterfaceOrientationLandscapeRight 71 | 72 | UIViewControllerBasedStatusBarAppearance 73 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 12 | set DEFAULT_JVM_OPTS= 13 | 14 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | set CMD_LINE_ARGS=%* 63 | goto execute 64 | 65 | :4NT_args 66 | @rem Get arguments from the 4NT Shell from JP Software 67 | set CMD_LINE_ARGS=%$ 68 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /src/icon/demo-files/demo.css: -------------------------------------------------------------------------------- 1 | body { 2 | padding: 0; 3 | margin: 0; 4 | font-family: sans-serif; 5 | font-size: 1em; 6 | line-height: 1.5; 7 | color: #555; 8 | background: #fff; 9 | } 10 | h1 { 11 | font-size: 1.5em; 12 | font-weight: normal; 13 | } 14 | small { 15 | font-size: .66666667em; 16 | } 17 | a { 18 | color: #e74c3c; 19 | text-decoration: none; 20 | } 21 | a:hover, a:focus { 22 | box-shadow: 0 1px #e74c3c; 23 | } 24 | .bshadow0, input { 25 | box-shadow: inset 0 -2px #e7e7e7; 26 | } 27 | input:hover { 28 | box-shadow: inset 0 -2px #ccc; 29 | } 30 | input, fieldset { 31 | font-family: sans-serif; 32 | font-size: 1em; 33 | margin: 0; 34 | padding: 0; 35 | border: 0; 36 | } 37 | input { 38 | color: inherit; 39 | line-height: 1.5; 40 | height: 1.5em; 41 | padding: .25em 0; 42 | } 43 | input:focus { 44 | outline: none; 45 | box-shadow: inset 0 -2px #449fdb; 46 | } 47 | .glyph { 48 | font-size: 16px; 49 | width: 15em; 50 | padding-bottom: 1em; 51 | margin-right: 4em; 52 | margin-bottom: 1em; 53 | float: left; 54 | overflow: hidden; 55 | } 56 | .liga { 57 | width: 80%; 58 | width: calc(100% - 2.5em); 59 | } 60 | .talign-right { 61 | text-align: right; 62 | } 63 | .talign-center { 64 | text-align: center; 65 | } 66 | .bgc1 { 67 | background: #f1f1f1; 68 | } 69 | .fgc1 { 70 | color: #999; 71 | } 72 | .fgc0 { 73 | color: #000; 74 | } 75 | p { 76 | margin-top: 1em; 77 | margin-bottom: 1em; 78 | } 79 | .mvm { 80 | margin-top: .75em; 81 | margin-bottom: .75em; 82 | } 83 | .mtn { 84 | margin-top: 0; 85 | } 86 | .mtl, .mal { 87 | margin-top: 1.5em; 88 | } 89 | .mbl, .mal { 90 | margin-bottom: 1.5em; 91 | } 92 | .mal, .mhl { 93 | margin-left: 1.5em; 94 | margin-right: 1.5em; 95 | } 96 | .mhmm { 97 | margin-left: 1em; 98 | margin-right: 1em; 99 | } 100 | .mls { 101 | margin-left: .25em; 102 | } 103 | .ptl { 104 | padding-top: 1.5em; 105 | } 106 | .pbs, .pvs { 107 | padding-bottom: .25em; 108 | } 109 | .pvs, .pts { 110 | padding-top: .25em; 111 | } 112 | .unit { 113 | float: left; 114 | } 115 | .unitRight { 116 | float: right; 117 | } 118 | .size1of2 { 119 | width: 50%; 120 | } 121 | .size1of1 { 122 | width: 100%; 123 | } 124 | .clearfix:before, .clearfix:after { 125 | content: " "; 126 | display: table; 127 | } 128 | .clearfix:after { 129 | clear: both; 130 | } 131 | .hidden-true { 132 | display: none; 133 | } 134 | .textbox0 { 135 | width: 3em; 136 | background: #f1f1f1; 137 | padding: .25em .5em; 138 | line-height: 1.5; 139 | height: 1.5em; 140 | } 141 | #testDrive { 142 | display: block; 143 | padding-top: 24px; 144 | line-height: 1.5; 145 | } 146 | .fs0 { 147 | font-size: 16px; 148 | } 149 | .fs1 { 150 | font-size: 32px; 151 | } 152 | 153 | -------------------------------------------------------------------------------- /src/page/MainController.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Dimensions, 5 | StatusBar, 6 | ScrollView 7 | } from 'react-native'; 8 | import { connect } from 'react-redux'; 9 | 10 | import { addCoin, deleteCoin, pushBalance, setVisibilityFilter, showBalance, VisibilityFilters } from '../actions/actions'; 11 | 12 | import CoinItem from '../component/CoinItem'; 13 | import Header from '../component/HeaderMain'; 14 | import { editCoinMiddleware, updateCoinMiddleware } from '../middleware/CustomMiddleware'; 15 | 16 | const contentHeight = Dimensions.get('window').height - 300; 17 | 18 | class MainController extends Component { 19 | static navigationOptions ={ 20 | header: null 21 | }; 22 | constructor(props) { 23 | super(props); 24 | } 25 | 26 | getTotalBalance() { 27 | const arr = [...this.props.visibleCoins]; 28 | if (arr.length === 0) return 0; 29 | const sum = arr.filter(item => !item.deleted).reduce((prev, current) => prev + parseFloat(current.balance), 0); 30 | return sum; 31 | } 32 | 33 | componentDidMount() { 34 | const { dispatch } = this.props; 35 | this.refreshBalance(); 36 | } 37 | 38 | refreshBalance() { 39 | const { dispatch } = this.props; 40 | // Update the balance to the new balance 41 | this.props.visibleCoins.map((item, index) => { 42 | if (!item.deleted) { 43 | dispatch(editCoinMiddleware( 44 | index, 45 | `${item.text.split('-')[0]}-${this.props.visibleSettings.nation}`, 46 | item.numbers, 47 | item.description 48 | )); 49 | } 50 | }); 51 | } 52 | 53 | render() { 54 | const { navigate } = this.props.navigation; 55 | const totalBalance = this.getTotalBalance(); 56 | return ( 57 | 58 | 59 |
63 | 64 | { 65 | this.props.visibleCoins.map((item, index) => { 66 | if (!item.deleted) { 67 | return ; 68 | } 69 | }) 70 | } 71 | 72 | 73 | ); 74 | } 75 | } 76 | 77 | 78 | function select(state) { 79 | return { 80 | visibleCoins: state.reducer.coins, 81 | visibleSettings: state.reducer.settings 82 | }; 83 | } 84 | export default connect(select)(MainController); 85 | -------------------------------------------------------------------------------- /android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | 19 | # Disabling obfuscation is useful if you collect stack traces from production crashes 20 | # (unless you are using a system that supports de-obfuscate the stack traces). 21 | -dontobfuscate 22 | 23 | # React Native 24 | 25 | # Keep our interfaces so they can be used by other ProGuard rules. 26 | # See http://sourceforge.net/p/proguard/bugs/466/ 27 | -keep,allowobfuscation @interface com.facebook.proguard.annotations.DoNotStrip 28 | -keep,allowobfuscation @interface com.facebook.proguard.annotations.KeepGettersAndSetters 29 | -keep,allowobfuscation @interface com.facebook.common.internal.DoNotStrip 30 | 31 | # Do not strip any method/class that is annotated with @DoNotStrip 32 | -keep @com.facebook.proguard.annotations.DoNotStrip class * 33 | -keep @com.facebook.common.internal.DoNotStrip class * 34 | -keepclassmembers class * { 35 | @com.facebook.proguard.annotations.DoNotStrip *; 36 | @com.facebook.common.internal.DoNotStrip *; 37 | } 38 | 39 | -keepclassmembers @com.facebook.proguard.annotations.KeepGettersAndSetters class * { 40 | void set*(***); 41 | *** get*(); 42 | } 43 | 44 | -keep class * extends com.facebook.react.bridge.JavaScriptModule { *; } 45 | -keep class * extends com.facebook.react.bridge.NativeModule { *; } 46 | -keepclassmembers,includedescriptorclasses class * { native ; } 47 | -keepclassmembers class * { @com.facebook.react.uimanager.UIProp ; } 48 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactProp ; } 49 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactPropGroup ; } 50 | 51 | -dontwarn com.facebook.react.** 52 | 53 | # TextLayoutBuilder uses a non-public Android constructor within StaticLayout. 54 | # See libs/proxy/src/main/java/com/facebook/fbui/textlayoutbuilder/proxy for details. 55 | -dontwarn android.text.StaticLayout 56 | 57 | # okhttp 58 | 59 | -keepattributes Signature 60 | -keepattributes *Annotation* 61 | -keep class okhttp3.** { *; } 62 | -keep interface okhttp3.** { *; } 63 | -dontwarn okhttp3.** 64 | 65 | # okio 66 | 67 | -keep class sun.misc.Unsafe { *; } 68 | -dontwarn java.nio.file.* 69 | -dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement 70 | -dontwarn okio.** 71 | -------------------------------------------------------------------------------- /src/component/CoinCard.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Text, 5 | StyleSheet 6 | } from 'react-native'; 7 | import CoinIcon from './CoinIcon'; 8 | 9 | class CoinCard extends Component { 10 | constructor(props) { 11 | super(props); 12 | } 13 | 14 | render() { 15 | const cuy = this.props.cuy || 'btc'; 16 | const description = this.props.description.substr(this.props.description.length - 4) || 'xmjw'; 17 | return ( 18 | 19 | 23 | 24 | 25 | 29 | CARD NUMBER 30 | ···· ···· ···· ···· ···· {description} 31 | 32 | 33 | 34 | 41 | 45 | CARD HOLDER 46 | Your Name 47 | 48 | 52 | EXPIRATION DATE 53 | Never 54 | 55 | 56 | 57 | ); 58 | } 59 | } 60 | 61 | var styles = StyleSheet.create({ 62 | card: { 63 | marginTop: 10, 64 | marginBottom: 10, 65 | paddingTop: 13, 66 | paddingBottom: 13, 67 | paddingLeft: 15, 68 | paddingRight: 15, 69 | backgroundColor: '#f5f5f5', 70 | justifyContent: 'flex-start', 71 | alignItems: 'flex-start', 72 | borderRadius: 7, 73 | shadowColor: '#0d2959', 74 | shadowOffset: { 75 | width: 0, 76 | height: 0 77 | }, 78 | shadowRadius: 2, 79 | shadowOpacity: 0.3 80 | }, 81 | thumb: { 82 | marginRight: 5 83 | }, 84 | cardTitle: { 85 | color: '#8a8a8a', 86 | fontSize: 12, 87 | fontWeight: 'bold', 88 | backgroundColor: 'transparent' 89 | 90 | }, 91 | cardNumber: { 92 | fontSize: 20, 93 | letterSpacing: 1, 94 | fontWeight: '600', 95 | backgroundColor: '#eeeeee', 96 | paddingTop: 8, 97 | paddingBottom: 8, 98 | paddingLeft: 16, 99 | paddingRight: 16 100 | 101 | }, 102 | text: { 103 | backgroundColor: '#eeeeee', 104 | padding: 8 105 | } 106 | 107 | 108 | }); 109 | 110 | export default CoinCard; 111 | -------------------------------------------------------------------------------- /ios/CoinOnline/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /src/page/SelectCoinController.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | StyleSheet, 4 | Dimensions, 5 | Platform, ListView, Text, View, TouchableOpacity 6 | 7 | } from 'react-native'; 8 | 9 | import { ButtonGroup, List, ListItem } from 'react-native-elements'; 10 | import CoinIcon from '../component/CoinIcon'; 11 | import { CoinList } from '../icon/config'; 12 | 13 | let _this = null; 14 | 15 | class SelectCoinController extends Component { 16 | static navigationOptions ={ 17 | header: null 18 | }; 19 | 20 | constructor(props) { 21 | super(props); 22 | this.state = { 23 | dataSource: null, 24 | loaded: false, 25 | layout: 'list', 26 | text: '', 27 | selectedIndex: 0 28 | }; 29 | this.updateIndex = this.updateIndex.bind(this); 30 | } 31 | 32 | updateIndex(selectedIndex) { 33 | this.setState({ selectedIndex }); 34 | } 35 | 36 | componentDidMount() { 37 | _this = this; 38 | this.loadFromConfig(); 39 | } 40 | loadFromAPI() { 41 | fetch('https://www.cryptonator.com/api/currencies') 42 | .then(response => response.json()) 43 | .then((json) => { 44 | this.setState({ 45 | data: new ListView.DataSource({ rowHasChanged: (r1, r2) => r1 !== r2 }).cloneWithRows(json.rows) 46 | }); 47 | }) 48 | .catch((error) => { 49 | console.log(error); 50 | }); 51 | } 52 | 53 | loadFromConfig() { 54 | this.setState({ 55 | data: new ListView.DataSource({ rowHasChanged: (r1, r2) => r1 !== r2 }).cloneWithRows(CoinList) 56 | }); 57 | } 58 | 59 | 60 | renderRow(rowData, index) { 61 | // let e = this.props.event || null; 62 | return ( 63 | { 64 | _this.props.setCode(rowData.code.toLowerCase()); 65 | }}> 66 | } 71 | key={index} 72 | title={rowData.name} 73 | subtitle={rowData.code} 74 | /> 75 | 76 | ); 77 | } 78 | 79 | render() { 80 | const buttons = ['常用', '所有', '搜索']; 81 | const { selectedIndex } = this.state; 82 | 83 | return ( 84 | 85 | 91 | {this.renderList()} 92 | 93 | ); 94 | } 95 | 96 | renderList() { 97 | if (!this.state.data) { 98 | return ( 99 | loading... 100 | ); 101 | } 102 | return ( 103 | 104 | 108 | 109 | ); 110 | } 111 | } 112 | 113 | const styles = StyleSheet.create({ 114 | list: { 115 | position: 'relative', 116 | top: -50 117 | } 118 | 119 | }); 120 | 121 | export default SelectCoinController; 122 | -------------------------------------------------------------------------------- /src/component/CoinItem.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Text, 5 | StyleSheet, 6 | TouchableHighlight 7 | } from 'react-native'; 8 | 9 | import CoinIcon from './CoinIcon'; 10 | import { deleteCoin } from '../actions/actions'; 11 | import { connect } from 'react-redux'; 12 | import Swipeout from 'react-native-swipeout'; 13 | 14 | 15 | class CoinList extends Component { 16 | constructor(props) { 17 | super(props); 18 | this.state = { 19 | spinkitSize: 50, 20 | reversed: false 21 | }; 22 | this.dispatch = this.props.dispatch; 23 | } 24 | 25 | componentDidMount() { 26 | 27 | } 28 | 29 | // reverse(){ 30 | // this.setState({ 31 | // dataSource: { 32 | // base: this.state.dataSource.target, 33 | // target: this.state.dataSource.base, 34 | // price: 1 / this.state.dataSource.price, 35 | // }, 36 | // reversed: true, 37 | // }); 38 | // } 39 | 40 | deleteItem(key) { 41 | this.dispatch(deleteCoin(key)); 42 | } 43 | 44 | editItem(key) { 45 | this.props.nav('AddCoinController', { 46 | id: key, 47 | cuy: this.props.cuy.toLowerCase().split('-')[0], 48 | numbers: this.props.numbers, 49 | description: this.props.description 50 | }); 51 | } 52 | 53 | render() { 54 | const covert = this.props.cuy.toUpperCase().split('-'); 55 | const buttons = [ 56 | { 57 | text: '编辑', 58 | onPress: e => this.editItem(this.props.itemIndex) 59 | }, 60 | { 61 | text: '删除', 62 | backgroundColor: '#fb3c38', 63 | onPress: e => this.deleteItem(this.props.itemIndex) 64 | } 65 | ]; 66 | 67 | return ( 68 | 69 | 70 | this.editItem(this.props.itemIndex) 74 | } > 75 | 76 | 77 | 78 | {this.props.balance.toFixed(4)} 79 | 82 | {covert[1]} 83 | {this.props.numbers} {covert[0]} 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | ); 92 | } 93 | } 94 | 95 | var styles = StyleSheet.create({ 96 | cell: { 97 | flex: 1, 98 | flexDirection: 'row', 99 | justifyContent: 'center', 100 | alignItems: 'center' 101 | }, 102 | rightContainer: { 103 | flex: 1, 104 | marginTop: 8, 105 | marginLeft: 15, 106 | marginRight: 15 107 | }, 108 | thumb: { 109 | width: 48, 110 | height: 48, 111 | marginLeft: 15 112 | }, 113 | label: { 114 | fontSize: 13 115 | } 116 | }); 117 | function select(state) { 118 | return { 119 | visibleBalance: state.allBalance 120 | }; 121 | } 122 | export default connect(select)(CoinList); 123 | -------------------------------------------------------------------------------- /ios/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "icon-20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "icon-20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "icon-29.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "icon-29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "icon-29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "icon-40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "icon-40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "57x57", 47 | "idiom" : "iphone", 48 | "filename" : "icon-57.png", 49 | "scale" : "1x" 50 | }, 51 | { 52 | "size" : "57x57", 53 | "idiom" : "iphone", 54 | "filename" : "icon-57@2x.png", 55 | "scale" : "2x" 56 | }, 57 | { 58 | "size" : "60x60", 59 | "idiom" : "iphone", 60 | "filename" : "icon-60@2x.png", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "size" : "60x60", 65 | "idiom" : "iphone", 66 | "filename" : "icon-60@3x.png", 67 | "scale" : "3x" 68 | }, 69 | { 70 | "size" : "20x20", 71 | "idiom" : "ipad", 72 | "filename" : "icon-20-ipad.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "20x20", 77 | "idiom" : "ipad", 78 | "filename" : "icon-20@2x-ipad.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "29x29", 83 | "idiom" : "ipad", 84 | "filename" : "icon-29-ipad.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "29x29", 89 | "idiom" : "ipad", 90 | "filename" : "icon-29@2x-ipad.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "40x40", 95 | "idiom" : "ipad", 96 | "filename" : "icon-40.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "40x40", 101 | "idiom" : "ipad", 102 | "filename" : "icon-40@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "50x50", 107 | "idiom" : "ipad", 108 | "filename" : "icon-50.png", 109 | "scale" : "1x" 110 | }, 111 | { 112 | "size" : "50x50", 113 | "idiom" : "ipad", 114 | "filename" : "icon-50@2x.png", 115 | "scale" : "2x" 116 | }, 117 | { 118 | "size" : "72x72", 119 | "idiom" : "ipad", 120 | "filename" : "icon-72.png", 121 | "scale" : "1x" 122 | }, 123 | { 124 | "size" : "72x72", 125 | "idiom" : "ipad", 126 | "filename" : "icon-72@2x.png", 127 | "scale" : "2x" 128 | }, 129 | { 130 | "size" : "76x76", 131 | "idiom" : "ipad", 132 | "filename" : "icon-76.png", 133 | "scale" : "1x" 134 | }, 135 | { 136 | "size" : "76x76", 137 | "idiom" : "ipad", 138 | "filename" : "icon-76@2x.png", 139 | "scale" : "2x" 140 | }, 141 | { 142 | "size" : "83.5x83.5", 143 | "idiom" : "ipad", 144 | "filename" : "icon-83.5@2x.png", 145 | "scale" : "2x" 146 | }, 147 | { 148 | "size" : "1024x1024", 149 | "idiom" : "ios-marketing", 150 | "filename" : "icon-1024.png", 151 | "scale" : "1x" 152 | } 153 | ], 154 | "info" : { 155 | "version" : 1, 156 | "author" : "xcode" 157 | } 158 | } -------------------------------------------------------------------------------- /src/page/SettingController.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | StyleSheet, 4 | View, 5 | Text, 6 | StatusBar, 7 | ScrollView, 8 | Dimensions, 9 | Image, 10 | TouchableOpacity, 11 | Platform 12 | } from 'react-native'; 13 | 14 | import { List, ListItem } from 'react-native-elements'; 15 | 16 | import HeaderTitle from '../component/HeaderTitle'; 17 | import { removeAllCoins } from '../actions/actions'; 18 | import { connect } from 'react-redux'; 19 | 20 | const contentHeight = Dimensions.get('window').height; 21 | 22 | 23 | class SettingController extends Component { 24 | static navigationOptions = ({ navigation }) => ({ 25 | header: null 26 | // headerTitle: '设置' , 27 | // headerStyle:{ 28 | // backgroundColor: '#3c82f7', 29 | // }, 30 | // headerTitleStyle: { 31 | // color: '#ffffff', 32 | // }, 33 | // headerBackTitleStyle:{ 34 | // color: '#ffffff', 35 | // } 36 | }); 37 | 38 | __rednerTitle() { 39 | if (Platform.OS === 'ios') { 40 | return ; 41 | } 42 | return ; 43 | } 44 | 45 | render() { 46 | const { dispatch } = this.props; 47 | return ( 48 | 49 | 50 | {this.__rednerTitle()} 51 | 52 | 56 | 61 | CoinOnline 65 | 您的数字货币小助手 68 | 69 | 70 | 71 | navigation('AddCoinController', { 76 | id: -1 77 | }) } 78 | /> 79 | {}} 84 | style ={ styles.list} 85 | title= "持久模式" 86 | leftIcon={{ name: 'sd-card' }} 87 | /> 88 | 89 | { 92 | dispatch(removeAllCoins()); 93 | }} 94 | style ={ styles.list} 95 | title= "初始化数据" 96 | leftIcon={{ name: 'sd-card' }} 97 | /> 98 | 99 | 104 | 105 | 106 | 107 | 108 | 109 | ); 110 | } 111 | } 112 | 113 | const styles = StyleSheet.create({ 114 | list: { 115 | } 116 | 117 | }); 118 | 119 | 120 | function select(state) { 121 | return { 122 | visibleCoins: state.reducer.coins, 123 | visibleSettings: state.reducer.settings 124 | }; 125 | } 126 | 127 | export default connect(select)(SettingController); 128 | -------------------------------------------------------------------------------- /src/component/HeaderMain.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Text, ImageBackground, Dimensions, TouchableOpacity 5 | } from 'react-native'; 6 | import Counter from './Counter'; 7 | 8 | const contentHeight = Dimensions.get('window').height - 40; 9 | 10 | class Header extends Component { 11 | constructor(props) { 12 | super(props); 13 | } 14 | 15 | 16 | __renderEmpty() { 17 | return ( 18 | 19 | 24 | 25 | 28 | 29 | 32 | 0.00 33 | 34 | 37 | 您尚未添加任何数字货币 38 | 39 | 40 | 41 | 44 | this.props.nav('AddCoinController', { 45 | id: -1 46 | }) }> 47 | 51 | 点我添加 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | ); 61 | } 62 | __renderAll() { 63 | return ( 64 | 65 | 71 | 74 | 75 | 76 | 77 | 80 | 83 | £ 84 | 85 | 86 | 89 | 总资产(估计) 90 | 91 | 94 | this.props.nav('AddCoinController', { 95 | id: -1 96 | }) }> 97 | 102 | + 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | ); 114 | } 115 | 116 | render() { 117 | if (this.props.balance <= 0) return this.__renderEmpty(); 118 | return this.__renderAll(); 119 | } 120 | } 121 | 122 | 123 | export default Header; 124 | -------------------------------------------------------------------------------- /ios/CoinOnline.xcodeproj/xcshareddata/xcschemes/CoinOnline.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 43 | 49 | 50 | 51 | 52 | 53 | 58 | 59 | 61 | 67 | 68 | 69 | 70 | 71 | 77 | 78 | 79 | 80 | 81 | 82 | 92 | 94 | 100 | 101 | 102 | 103 | 104 | 105 | 111 | 113 | 119 | 120 | 121 | 122 | 124 | 125 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /ios/CoinOnline.xcodeproj/xcshareddata/xcschemes/CoinOnline-tvOS.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 43 | 49 | 50 | 51 | 52 | 53 | 58 | 59 | 61 | 67 | 68 | 69 | 70 | 71 | 77 | 78 | 79 | 80 | 81 | 82 | 92 | 94 | 100 | 101 | 102 | 103 | 104 | 105 | 111 | 113 | 119 | 120 | 121 | 122 | 124 | 125 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /src/icon/style.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: 'icomoon'; 3 | src: url('fonts/icomoon.eot?c44t86'); 4 | src: url('fonts/icomoon.eot?c44t86#iefix') format('embedded-opentype'), 5 | url('fonts/icomoon.ttf?c44t86') format('truetype'), 6 | url('fonts/icomoon.woff?c44t86') format('woff'), 7 | url('fonts/icomoon.svg?c44t86#icomoon') format('svg'); 8 | font-weight: normal; 9 | font-style: normal; 10 | } 11 | 12 | [class^="icon-"], [class*=" icon-"] { 13 | /* use !important to prevent issues with browser extensions that change fonts */ 14 | font-family: 'icomoon' !important; 15 | speak: none; 16 | font-style: normal; 17 | font-weight: normal; 18 | font-variant: normal; 19 | text-transform: none; 20 | line-height: 1; 21 | 22 | /* Better Font Rendering =========== */ 23 | -webkit-font-smoothing: antialiased; 24 | -moz-osx-font-smoothing: grayscale; 25 | } 26 | 27 | .icon-x:before { 28 | content: "\e900"; 29 | } 30 | .icon-ada:before { 31 | content: "\e902"; 32 | } 33 | .icon-amp:before { 34 | content: "\e904"; 35 | } 36 | .icon-ant:before { 37 | content: "\e906"; 38 | } 39 | .icon-ardr:before { 40 | content: "\e908"; 41 | } 42 | .icon-ark:before { 43 | content: "\e90a"; 44 | } 45 | .icon-bat:before { 46 | content: "\e90c"; 47 | } 48 | .icon-bcc:before { 49 | content: "\e90e"; 50 | } 51 | .icon-bch:before { 52 | content: "\e910"; 53 | } 54 | .icon-bcn:before { 55 | content: "\e912"; 56 | } 57 | .icon-bnb:before { 58 | content: "\e914"; 59 | } 60 | .icon-btc:before { 61 | content: "\e916"; 62 | } 63 | .icon-btcd:before { 64 | content: "\e918"; 65 | } 66 | .icon-bts:before { 67 | content: "\e91a"; 68 | } 69 | .icon-dash:before { 70 | content: "\e91c"; 71 | } 72 | .icon-dcr:before { 73 | content: "\e91e"; 74 | } 75 | .icon-dgb:before { 76 | content: "\e920"; 77 | } 78 | .icon-dgd:before { 79 | content: "\e922"; 80 | } 81 | .icon-doge:before { 82 | content: "\e924"; 83 | } 84 | .icon-emc:before { 85 | content: "\e926"; 86 | } 87 | .icon-eos:before { 88 | content: "\e928"; 89 | } 90 | .icon-etc:before { 91 | content: "\e929"; 92 | } 93 | .icon-eth .path1:before { 94 | content: "\e92b"; 95 | color: rgb(0, 0, 0); 96 | } 97 | .icon-eth .path2:before { 98 | content: "\e92c"; 99 | margin-left: -1em; 100 | color: rgb(0, 0, 0); 101 | opacity: 0.298; 102 | } 103 | .icon-eth .path3:before { 104 | content: "\e92d"; 105 | margin-left: -1em; 106 | color: rgb(0, 0, 0); 107 | opacity: 0.298; 108 | } 109 | .icon-eth .path4:before { 110 | content: "\e92e"; 111 | margin-left: -1em; 112 | color: rgb(0, 0, 0); 113 | opacity: 0.8010; 114 | } 115 | .icon-eth .path5:before { 116 | content: "\e92f"; 117 | margin-left: -1em; 118 | color: rgb(0, 0, 0); 119 | opacity: 0.298; 120 | } 121 | .icon-fct:before { 122 | content: "\e932"; 123 | } 124 | .icon-game:before { 125 | content: "\e934"; 126 | } 127 | .icon-gbyte:before { 128 | content: "\e936"; 129 | } 130 | .icon-gno:before { 131 | content: "\e938"; 132 | } 133 | .icon-gnt:before { 134 | content: "\e93a"; 135 | } 136 | .icon-hsr:before { 137 | content: "\e93c"; 138 | } 139 | .icon-icn:before { 140 | content: "\e93e"; 141 | } 142 | .icon-kmd:before { 143 | content: "\e940"; 144 | } 145 | .icon-knc:before { 146 | content: "\e942"; 147 | } 148 | .icon-lkk:before { 149 | content: "\e944"; 150 | } 151 | .icon-lsk:before { 152 | content: "\e946"; 153 | } 154 | .icon-ltc:before { 155 | content: "\e948"; 156 | } 157 | .icon-maid .path1:before { 158 | content: "\e94a"; 159 | color: rgb(0, 0, 0); 160 | } 161 | .icon-maid .path2:before { 162 | content: "\e94b"; 163 | margin-left: -1em; 164 | color: rgb(0, 0, 0); 165 | opacity: 0.4020; 166 | } 167 | .icon-maid .path3:before { 168 | content: "\e94c"; 169 | margin-left: -1em; 170 | color: rgb(0, 0, 0); 171 | opacity: 0.8020; 172 | } 173 | .icon-miota:before { 174 | content: "\e94e"; 175 | } 176 | .icon-mln:before { 177 | content: "\e950"; 178 | } 179 | .icon-mona:before { 180 | content: "\e952"; 181 | } 182 | .icon-neo:before { 183 | content: "\e954"; 184 | } 185 | .icon-nlg:before { 186 | content: "\e956"; 187 | } 188 | .icon-nmc:before { 189 | content: "\e958"; 190 | } 191 | .icon-nxt:before { 192 | content: "\e95a"; 193 | } 194 | .icon-omg:before { 195 | content: "\e95c"; 196 | } 197 | .icon-pay:before { 198 | content: "\e95e"; 199 | } 200 | .icon-pivx:before { 201 | content: "\e960"; 202 | } 203 | .icon-pot:before { 204 | content: "\e962"; 205 | } 206 | .icon-ppc:before { 207 | content: "\e964"; 208 | } 209 | .icon-ppt:before { 210 | content: "\e966"; 211 | } 212 | .icon-qtum:before { 213 | content: "\e968"; 214 | } 215 | .icon-rep:before { 216 | content: "\e96a"; 217 | } 218 | .icon-salt:before { 219 | content: "\e96c"; 220 | } 221 | .icon-sc:before { 222 | content: "\e96e"; 223 | } 224 | .icon-sngls:before { 225 | content: "\e970"; 226 | } 227 | .icon-steem:before { 228 | content: "\e972"; 229 | } 230 | .icon-strat:before { 231 | content: "\e974"; 232 | } 233 | .icon-trx:before { 234 | content: "\e976"; 235 | } 236 | .icon-usdt:before { 237 | content: "\e978"; 238 | } 239 | .icon-vtc:before { 240 | content: "\e97a"; 241 | } 242 | .icon-waves .path1:before { 243 | content: "\e97c"; 244 | color: rgb(0, 0, 0); 245 | } 246 | .icon-waves .path2:before { 247 | content: "\e97d"; 248 | margin-left: -1em; 249 | color: rgb(0, 0, 0); 250 | opacity: 0.6; 251 | } 252 | .icon-xcp:before { 253 | content: "\e97f"; 254 | } 255 | .icon-xem:before { 256 | content: "\e981"; 257 | } 258 | .icon-xlm:before { 259 | content: "\e983"; 260 | } 261 | .icon-xmr:before { 262 | content: "\e985"; 263 | } 264 | .icon-xrp:before { 265 | content: "\e987"; 266 | } 267 | .icon-xtz:before { 268 | content: "\e989"; 269 | } 270 | .icon-zec:before { 271 | content: "\e98b"; 272 | } 273 | -------------------------------------------------------------------------------- /android/gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | ############################################################################## 4 | ## 5 | ## Gradle start up script for UN*X 6 | ## 7 | ############################################################################## 8 | 9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 10 | DEFAULT_JVM_OPTS="" 11 | 12 | APP_NAME="Gradle" 13 | APP_BASE_NAME=`basename "$0"` 14 | 15 | # Use the maximum available, or set MAX_FD != -1 to use that value. 16 | MAX_FD="maximum" 17 | 18 | warn ( ) { 19 | echo "$*" 20 | } 21 | 22 | die ( ) { 23 | echo 24 | echo "$*" 25 | echo 26 | exit 1 27 | } 28 | 29 | # OS specific support (must be 'true' or 'false'). 30 | cygwin=false 31 | msys=false 32 | darwin=false 33 | case "`uname`" in 34 | CYGWIN* ) 35 | cygwin=true 36 | ;; 37 | Darwin* ) 38 | darwin=true 39 | ;; 40 | MINGW* ) 41 | msys=true 42 | ;; 43 | esac 44 | 45 | # For Cygwin, ensure paths are in UNIX format before anything is touched. 46 | if $cygwin ; then 47 | [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` 48 | fi 49 | 50 | # Attempt to set APP_HOME 51 | # Resolve links: $0 may be a link 52 | PRG="$0" 53 | # Need this for relative symlinks. 54 | while [ -h "$PRG" ] ; do 55 | ls=`ls -ld "$PRG"` 56 | link=`expr "$ls" : '.*-> \(.*\)$'` 57 | if expr "$link" : '/.*' > /dev/null; then 58 | PRG="$link" 59 | else 60 | PRG=`dirname "$PRG"`"/$link" 61 | fi 62 | done 63 | SAVED="`pwd`" 64 | cd "`dirname \"$PRG\"`/" >&- 65 | APP_HOME="`pwd -P`" 66 | cd "$SAVED" >&- 67 | 68 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 69 | 70 | # Determine the Java command to use to start the JVM. 71 | if [ -n "$JAVA_HOME" ] ; then 72 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 73 | # IBM's JDK on AIX uses strange locations for the executables 74 | JAVACMD="$JAVA_HOME/jre/sh/java" 75 | else 76 | JAVACMD="$JAVA_HOME/bin/java" 77 | fi 78 | if [ ! -x "$JAVACMD" ] ; then 79 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 80 | 81 | Please set the JAVA_HOME variable in your environment to match the 82 | location of your Java installation." 83 | fi 84 | else 85 | JAVACMD="java" 86 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 87 | 88 | Please set the JAVA_HOME variable in your environment to match the 89 | location of your Java installation." 90 | fi 91 | 92 | # Increase the maximum file descriptors if we can. 93 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then 94 | MAX_FD_LIMIT=`ulimit -H -n` 95 | if [ $? -eq 0 ] ; then 96 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 97 | MAX_FD="$MAX_FD_LIMIT" 98 | fi 99 | ulimit -n $MAX_FD 100 | if [ $? -ne 0 ] ; then 101 | warn "Could not set maximum file descriptor limit: $MAX_FD" 102 | fi 103 | else 104 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 105 | fi 106 | fi 107 | 108 | # For Darwin, add options to specify how the application appears in the dock 109 | if $darwin; then 110 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 111 | fi 112 | 113 | # For Cygwin, switch paths to Windows format before running java 114 | if $cygwin ; then 115 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 116 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 117 | 118 | # We build the pattern for arguments to be converted via cygpath 119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 120 | SEP="" 121 | for dir in $ROOTDIRSRAW ; do 122 | ROOTDIRS="$ROOTDIRS$SEP$dir" 123 | SEP="|" 124 | done 125 | OURCYGPATTERN="(^($ROOTDIRS))" 126 | # Add a user-defined pattern to the cygpath arguments 127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 129 | fi 130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 131 | i=0 132 | for arg in "$@" ; do 133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 135 | 136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 138 | else 139 | eval `echo args$i`="\"$arg\"" 140 | fi 141 | i=$((i+1)) 142 | done 143 | case $i in 144 | (0) set -- ;; 145 | (1) set -- "$args0" ;; 146 | (2) set -- "$args0" "$args1" ;; 147 | (3) set -- "$args0" "$args1" "$args2" ;; 148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;; 149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 154 | esac 155 | fi 156 | 157 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules 158 | function splitJvmOpts() { 159 | JVM_OPTS=("$@") 160 | } 161 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS 162 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" 163 | 164 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" 165 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | 3 | import com.android.build.OutputFile 4 | 5 | /** 6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets 7 | * and bundleReleaseJsAndAssets). 8 | * These basically call `react-native bundle` with the correct arguments during the Android build 9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the 10 | * bundle directly from the development server. Below you can see all the possible configurations 11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the 12 | * `apply from: "../../node_modules/react-native/react.gradle"` line. 13 | * 14 | * project.ext.react = [ 15 | * // the name of the generated asset file containing your JS bundle 16 | * bundleAssetName: "index.android.bundle", 17 | * 18 | * // the entry file for bundle generation 19 | * entryFile: "index.android.js", 20 | * 21 | * // whether to bundle JS and assets in debug mode 22 | * bundleInDebug: false, 23 | * 24 | * // whether to bundle JS and assets in release mode 25 | * bundleInRelease: true, 26 | * 27 | * // whether to bundle JS and assets in another build variant (if configured). 28 | * // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants 29 | * // The configuration property can be in the following formats 30 | * // 'bundleIn${productFlavor}${buildType}' 31 | * // 'bundleIn${buildType}' 32 | * // bundleInFreeDebug: true, 33 | * // bundleInPaidRelease: true, 34 | * // bundleInBeta: true, 35 | * 36 | * // whether to disable dev mode in custom build variants (by default only disabled in release) 37 | * // for example: to disable dev mode in the staging build type (if configured) 38 | * devDisabledInStaging: true, 39 | * // The configuration property can be in the following formats 40 | * // 'devDisabledIn${productFlavor}${buildType}' 41 | * // 'devDisabledIn${buildType}' 42 | * 43 | * // the root of your project, i.e. where "package.json" lives 44 | * root: "../../", 45 | * 46 | * // where to put the JS bundle asset in debug mode 47 | * jsBundleDirDebug: "$buildDir/intermediates/assets/debug", 48 | * 49 | * // where to put the JS bundle asset in release mode 50 | * jsBundleDirRelease: "$buildDir/intermediates/assets/release", 51 | * 52 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 53 | * // require('./image.png')), in debug mode 54 | * resourcesDirDebug: "$buildDir/intermediates/res/merged/debug", 55 | * 56 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 57 | * // require('./image.png')), in release mode 58 | * resourcesDirRelease: "$buildDir/intermediates/res/merged/release", 59 | * 60 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means 61 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to 62 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle 63 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/ 64 | * // for example, you might want to remove it from here. 65 | * inputExcludes: ["android/**", "ios/**"], 66 | * 67 | * // override which node gets called and with what additional arguments 68 | * nodeExecutableAndArgs: ["node"], 69 | * 70 | * // supply additional arguments to the packager 71 | * extraPackagerArgs: [] 72 | * ] 73 | */ 74 | 75 | project.ext.react = [ 76 | entryFile: "index.js" 77 | ] 78 | 79 | apply from: "../../node_modules/react-native/react.gradle" 80 | 81 | /** 82 | * Set this to true to create two separate APKs instead of one: 83 | * - An APK that only works on ARM devices 84 | * - An APK that only works on x86 devices 85 | * The advantage is the size of the APK is reduced by about 4MB. 86 | * Upload all the APKs to the Play Store and people will download 87 | * the correct one based on the CPU architecture of their device. 88 | */ 89 | def enableSeparateBuildPerCPUArchitecture = false 90 | 91 | /** 92 | * Run Proguard to shrink the Java bytecode in release builds. 93 | */ 94 | def enableProguardInReleaseBuilds = false 95 | 96 | android { 97 | compileSdkVersion 23 98 | buildToolsVersion "23.0.1" 99 | 100 | defaultConfig { 101 | applicationId "com.coinonline" 102 | minSdkVersion 16 103 | targetSdkVersion 22 104 | versionCode 1 105 | versionName "1.0" 106 | ndk { 107 | abiFilters "armeabi-v7a", "x86" 108 | } 109 | } 110 | splits { 111 | abi { 112 | reset() 113 | enable enableSeparateBuildPerCPUArchitecture 114 | universalApk false // If true, also generate a universal APK 115 | include "armeabi-v7a", "x86" 116 | } 117 | } 118 | buildTypes { 119 | release { 120 | minifyEnabled enableProguardInReleaseBuilds 121 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 122 | } 123 | } 124 | // applicationVariants are e.g. debug, release 125 | applicationVariants.all { variant -> 126 | variant.outputs.each { output -> 127 | // For each separate APK per architecture, set a unique version code as described here: 128 | // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits 129 | def versionCodes = ["armeabi-v7a":1, "x86":2] 130 | def abi = output.getFilter(OutputFile.ABI) 131 | if (abi != null) { // null for the universal-debug, universal-release variants 132 | output.versionCodeOverride = 133 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode 134 | } 135 | } 136 | } 137 | } 138 | 139 | dependencies { 140 | compile project(':react-native-svg') 141 | compile project(':react-native-spinkit') 142 | compile project(':react-native-vector-icons') 143 | compile fileTree(dir: "libs", include: ["*.jar"]) 144 | compile "com.android.support:appcompat-v7:23.0.1" 145 | compile "com.facebook.react:react-native:+" // From node_modules 146 | } 147 | 148 | // Run this once to be able to run the application with BUCK 149 | // puts all compile dependencies into folder libs for BUCK to use 150 | task copyDownloadableDepsToLibs(type: Copy) { 151 | from configurations.compile 152 | into 'libs' 153 | } 154 | -------------------------------------------------------------------------------- /src/icon/config.js: -------------------------------------------------------------------------------- 1 | export const ColorConfig = [ 2 | { cuy: 'x', color: 'rgb(48, 44, 44)' }, 3 | { cuy: 'ada', color: 'rgb(60, 200, 200)' }, 4 | { cuy: 'amp', color: 'rgb(45, 174, 228)' }, 5 | { cuy: 'ant', color: 'rgb(44, 211, 225)' }, 6 | { cuy: 'ardr', color: 'rgb(60, 135, 199)' }, 7 | { cuy: 'ark', color: 'rgb(247, 0, 0)' }, 8 | { cuy: 'bat', color: 'rgb(255, 80, 0)' }, 9 | { cuy: 'bcc', color: 'rgb(247, 147, 28)' }, 10 | { cuy: 'bch', color: 'rgb(247, 147, 26)' }, 11 | { cuy: 'bcn', color: 'rgb(240, 64, 134)' }, 12 | { cuy: 'bnb', color: 'rgb(243, 186, 47)' }, 13 | { cuy: 'btc', color: 'rgb(247, 147, 26)' }, 14 | { cuy: 'btcd', color: 'rgb(255, 102, 0)' }, 15 | { cuy: 'bts', color: 'rgb(53, 186, 235)' }, 16 | { cuy: 'dash', color: 'rgb(28, 117, 188)' }, 17 | { cuy: 'dcr', color: 'rgb(46, 214, 161)' }, 18 | { cuy: 'dgb', color: 'rgb(0, 106, 210)' }, 19 | { cuy: 'dgd', color: 'rgb(244, 208, 41)' }, 20 | { cuy: 'doge', color: 'rgb(195, 166, 52)' }, 21 | { cuy: 'emc', color: 'rgb(180, 159, 252)' }, 22 | { cuy: 'eos', color: 'rgb(180, 159, 252)' }, 23 | { cuy: 'etc', color: 'rgb(102, 144, 115)' }, 24 | { cuy: 'eth', color: 'rgb(98, 126, 234)' }, 25 | { cuy: 'fct', color: 'rgb(65, 123, 164)' }, 26 | { cuy: 'game', color: 'rgb(152, 192, 31)' }, 27 | { cuy: 'gbyte', color: 'rgb(48, 44, 44)' }, 28 | { cuy: 'gno', color: 'rgb(0, 166, 196)' }, 29 | { cuy: 'gnt', color: 'rgb(0, 29, 87)' }, 30 | { cuy: 'hsr', color: 'rgb(86, 66, 142)' }, 31 | { cuy: 'icn', color: 'rgb(76, 111, 140)' }, 32 | { cuy: 'kmd', color: 'rgb(50, 100, 100)' }, 33 | { cuy: 'knc', color: 'rgb(24, 140, 146)' }, 34 | { cuy: 'lkk', color: 'rgb(157, 1, 235)' }, 35 | { cuy: 'lsk', color: 'rgb(2, 136, 209)' }, 36 | { cuy: 'ltc', color: 'rgb(203, 198, 198)' }, 37 | { cuy: 'maid', color: 'rgb(85, 146, 215)' }, 38 | { cuy: 'miota', color: 'rgb(36, 36, 36)' }, 39 | { cuy: 'mln', color: 'rgb(11, 21, 41)' }, 40 | { cuy: 'mona', color: 'rgb(240, 219, 176)' }, 41 | { cuy: 'neo', color: 'rgb(0, 0, 0)' }, 42 | { cuy: 'nlg', color: 'rgb(42, 176, 253)' }, 43 | { cuy: 'nmc', color: 'rgb(24, 108, 157)' }, 44 | { cuy: 'nxt', color: 'rgb(0, 143, 187)' }, 45 | { cuy: 'omg', color: 'rgb(26, 83, 240)' }, 46 | { cuy: 'pay', color: 'rgb(48, 44, 44)' }, 47 | { cuy: 'pivx', color: 'rgb(94, 71, 120)' }, 48 | { cuy: 'pot', color: 'rgb(16, 91, 47)' }, 49 | { cuy: 'ppc', color: 'rgb(60, 176, 84)' }, 50 | { cuy: 'ppt', color: 'rgb(21, 39, 67)' }, 51 | { cuy: 'qtum', color: 'rgb(46, 154, 208)' }, 52 | { cuy: 'rep', color: 'rgb(96, 42, 82)' }, 53 | { cuy: 'salt', color: 'rgb(27, 238, 244)' }, 54 | { cuy: 'sc', color: 'rgb(0, 203, 160)' }, 55 | { cuy: 'sngls', color: 'rgb(179, 13, 35)' }, 56 | { cuy: 'steem', color: 'rgb(75, 162, 242)' }, 57 | { cuy: 'strat', color: 'rgb(19, 135, 201)' }, 58 | { cuy: 'trx', color: 'rgb(0, 0, 0)' }, 59 | { cuy: 'usdt', color: 'rgb(38, 161, 123)' }, 60 | { cuy: 'vtc', color: 'rgb(53, 99, 62)' }, 61 | { cuy: 'waves', color: 'rgb(0, 150, 220)' }, 62 | { cuy: 'xcp', color: 'rgb(237, 22, 80)' }, 63 | { cuy: 'xem', color: 'rgb(103, 178, 232)' }, 64 | { cuy: 'xlm', color: 'rgb(20, 182, 231)' }, 65 | { cuy: 'xmr', color: 'rgb(255, 102, 0)' }, 66 | { cuy: 'xrp', color: 'rgb(0, 170, 228)' }, 67 | { cuy: 'xtz', color: 'rgb(166, 224, 0)' }, 68 | { cuy: 'zec', color: 'rgb(236, 178, 68)' } 69 | ]; 70 | 71 | export const CoinList = [ { code: 'ADA', name: 'ADA' }, 72 | { code: 'ANT', name: 'Aragon' }, 73 | { code: 'ARDR', name: 'ARDR' }, 74 | { code: 'ARK', name: 'ARK' }, 75 | { code: 'REP', name: 'Augur' }, 76 | { code: 'BAT', name: 'BAT' }, 77 | { code: 'BTC', name: 'Bitcoin' }, 78 | { code: 'BCH', name: 'Bitcoin Cash' }, 79 | { code: 'BTCD', name: 'BitcoinDark' }, 80 | { code: 'BTS', name: 'BitShares' }, 81 | { code: 'GBYTE', name: 'Byteball' }, 82 | { code: 'BCN', name: 'Bytecoin' }, 83 | { code: 'XCP', name: 'Counterparty' }, 84 | { code: 'DGD', name: 'DarkGoldCoin' }, 85 | { code: 'DASH', name: 'Dash' }, 86 | { code: 'DCR', name: 'Decred' }, 87 | { code: 'DGB', name: 'Digibyte' }, 88 | { code: 'DOGE', name: 'Dogecoin' }, 89 | { code: 'EMC', name: 'Emercoin' }, 90 | { code: 'EOS', name: 'EOS' }, 91 | { code: 'ETH', name: 'Ethereum' }, 92 | { code: 'ETC', name: 'Ethereum Classic' }, 93 | { code: 'FCT', name: 'Factom' }, 94 | { code: 'GAME', name: 'GameCredits' }, 95 | { code: 'GNO', name: 'GNO' }, 96 | { code: 'GNT', name: 'Golem' }, 97 | { code: 'NLG', name: 'Gulden' }, 98 | { code: 'HSR', name: 'HSR' }, 99 | { code: 'ICN', name: 'Iconomi' }, 100 | { code: 'KNC', name: 'KhanCoin' }, 101 | { code: 'KMD', name: 'KMD' }, 102 | { code: 'LSK', name: 'Lisk' }, 103 | { code: 'LTC', name: 'Litecoin' }, 104 | { code: 'MAID', name: 'MaidSafeCoin' }, 105 | { code: 'MLN', name: 'MLN' }, 106 | { code: 'MONA', name: 'MonaCoin' }, 107 | { code: 'XMR', name: 'Monero' }, 108 | { code: 'NMC', name: 'Namecoin' }, 109 | { code: 'XEM', name: 'NEM' }, 110 | { code: 'NEO', name: 'NEO' }, 111 | { code: 'NXT', name: 'NXT' }, 112 | { code: 'OMG', name: 'OMG' }, 113 | { code: 'PAY', name: 'PAY' }, 114 | { code: 'PPC', name: 'Peercoin' }, 115 | { code: 'PIVX', name: 'PIVX' }, 116 | { code: 'POT', name: 'Potcoin' }, 117 | { code: 'PPT', name: 'PPT' }, 118 | { code: 'QTUM', name: 'QTUM' }, 119 | { code: 'XRP', name: 'Ripple' }, 120 | { code: 'SALT', name: 'SALT' }, 121 | { code: 'SC', name: 'Siacoin' }, 122 | { code: 'SNGLS', name: 'SNGLS' }, 123 | { code: 'STEEM', name: 'Steem' }, 124 | { code: 'XLM', name: 'Stellar' }, 125 | { code: 'STRAT', name: 'STRAT' }, 126 | { code: 'AMP', name: 'Synereo' }, 127 | { code: 'TRX', name: 'TRX' }, 128 | { code: 'VTC', name: 'Vertcoin' }, 129 | { code: 'WAVES', name: 'WAVES' }, 130 | { code: 'XTZ', name: 'XTZ' }, 131 | { code: 'ZEC', name: 'Zcash' } ]; 132 | 133 | export const list = ["0x" , "bcn" , "doge" , "gnt" , "miota" , "pivx" , "steem" , "xmr" , "ada" , "bnb" , "emc" , "hsr" , "mln" , "pot" , "strat" , "xrp" , "amp" , "btc" , "eos" , "icn" , "mona" , "ppc" , "trx" , "xtz" , "ant" , "btcd" , "etc" , "kmd" , "neo" , "ppt" , "usdt" , "zec" , "ardr" , "bts" , "eth" , "knc" , "nlg" , "qtum" , "vtc" , "ark" , "dash" , "fct" , "lkk" , "nmc" , "rep" , "waves" , "bat" , "dcr" , "game" , "lsk" , "nxt" , "salt" , "xcp" , "bcc" , "dgb" , "gbyte" , "ltc" , "omg" , "sc" , "xem" , "bch" , "dgd" , "gno" , "maid" , "pay" , "sngls" , "xlm", "more"]; 134 | -------------------------------------------------------------------------------- /src/page/ChangeBase.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import Modal from 'react-native-modalbox'; 3 | import { 4 | View, 5 | Text, 6 | ImageBackground, 7 | TextInput, 8 | StyleSheet, 9 | KeyboardAvoidingView, 10 | Dimensions, TouchableOpacity, ScrollView 11 | } from 'react-native'; 12 | import { connect } from 'react-redux'; 13 | import CoinIcon from '../component/CoinIcon'; 14 | import CoinCard from '../component/CoinCard'; 15 | import { addCoinMiddleware, editCoinMiddleware } from '../middleware/CustomMiddleware'; 16 | import { deleteCoin, MODE_ADD, MODE_EDIT } from '../actions/actions'; 17 | import SelectCoinController from './SelectCoinController'; 18 | 19 | const contentHeight = Dimensions.get('window').height - 50; 20 | const dismissKeyboard = require('dismissKeyboard'); 21 | 22 | let _this = null; 23 | 24 | class ChangeBase extends Component { 25 | static navigationOptions = ({ navigation }) => ({ 26 | 27 | // header : null, 28 | headerTitle: '修改基准货币', 29 | headerBackTitle: '返回', 30 | headerStyle: { 31 | backgroundColor: '#244f85' 32 | }, 33 | headerTitleStyle: { 34 | color: '#ffffff' 35 | }, 36 | headerBackTitleStyle: { 37 | color: '#ffffff' 38 | }, 39 | headerRight: ( 40 | 41 | _this.doAction(_this.state.mode)} 46 | >保存 47 | 48 | ) 49 | }); 50 | 51 | constructor(props) { 52 | super(props); 53 | let { 54 | id, cuy, numbers, description 55 | } = this.props.navigation.state.params; 56 | if (numbers) numbers = numbers.toString(); 57 | const mode = id < 0 ? MODE_ADD : MODE_EDIT; 58 | this.state = { 59 | id, 60 | numbers: numbers || '', 61 | description: description || '', 62 | cuy: cuy || 'btc', 63 | mode, 64 | swipeToClose: true 65 | }; 66 | } 67 | 68 | componentDidMount() { 69 | _this = this; 70 | } 71 | 72 | render() { 73 | return ( 74 | 75 | 76 | dismissKeyboard()}> 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 拥有货币数量 (*) 85 | this.setState({ numbers: text })} 88 | keyboardType ='numeric' 89 | placeholder = '0.1' 90 | defaultValue = {this.state.numbers} 91 | /> 92 | 93 | 94 | 95 | 数字货币类型 (*) 96 | 97 | { 98 | ['btc', 'ltc', 'etc', 'xmr'].map((item, index) => ( 99 | { 100 | this.setState({ 101 | cuy: item 102 | }); 103 | } 104 | } > 105 | 106 | 107 | )) 108 | } 109 | { 110 | dismissKeyboard(); 111 | this.refs.modal1.open(); 112 | } 113 | } > 114 | 115 | 116 | 117 | 118 | 119 | 数字货币账户 120 | this.setState({ description: text })} 122 | style={styles.inputDescription} 123 | defaultValue = {this.state.description} 124 | placeholder = '1geekH9EiFeitKpigP8NKNJ6U...' 125 | /> 126 | 127 | 128 | 129 | 130 | 131 | 132 | (this.setState({ 133 | cuy 134 | }) 135 | )}/> 136 | 137 | 138 | 139 | 140 | 141 | ); 142 | } 143 | 144 | 145 | doAction(e) { 146 | switch (e) { 147 | case MODE_EDIT: 148 | this.editToCoin(); 149 | break; 150 | case MODE_ADD: 151 | this.addToCoin(); 152 | break; 153 | default: 154 | this.addToCoin(); 155 | } 156 | } 157 | 158 | addToCoin() { 159 | const { dispatch } = this.props; 160 | dispatch(addCoinMiddleware( 161 | `${this.state.cuy}-${this.props.visibleSettings.nation}`, 162 | parseFloat(this.state.numbers), 163 | this.state.description 164 | )); 165 | this.props.navigation.goBack(); 166 | } 167 | 168 | editToCoin() { 169 | const { dispatch } = this.props; 170 | dispatch(editCoinMiddleware( 171 | this.state.id, 172 | `${this.state.cuy}-${this.props.visibleSettings.nation}`, 173 | parseFloat(this.state.numbers), 174 | this.state.description 175 | )); 176 | this.props.navigation.goBack(); 177 | } 178 | 179 | deleteCoin(index) { 180 | const { dispatch } = this.props; 181 | dispatch(deleteCoin(index)); 182 | } 183 | } 184 | 185 | function select(state) { 186 | return { 187 | visibleSettings: state.reducer.settings 188 | }; 189 | } 190 | 191 | 192 | const styles = StyleSheet.create({ 193 | box: { 194 | width: '100%', 195 | height: contentHeight * 0.6 196 | }, 197 | card: { 198 | width: '90%', 199 | height: contentHeight * 0.4, 200 | justifyContent: 'center' 201 | }, 202 | main: { 203 | backgroundColor: '#244f85', 204 | width: '100%', 205 | height: '100%', 206 | justifyContent: 'center', 207 | alignItems: 'center' 208 | }, 209 | secondLayer: { 210 | backgroundColor: '#3d6b9c', 211 | flex: 1, 212 | width: '100%', 213 | paddingTop: 25, 214 | paddingLeft: 25, 215 | paddingRight: 25, 216 | paddingBottom: 10 217 | 218 | }, 219 | thirdLayer: { 220 | backgroundColor: '#275288', 221 | flex: 1, 222 | width: '100%', 223 | paddingTop: 25, 224 | paddingLeft: 25, 225 | paddingRight: 25, 226 | paddingBottom: 10 227 | 228 | }, 229 | forthLayer: { 230 | backgroundColor: '#244c7f', 231 | flex: 1, 232 | width: '100%', 233 | paddingTop: 25, 234 | paddingLeft: 25, 235 | paddingRight: 25, 236 | paddingBottom: 10 237 | 238 | }, 239 | label: { 240 | fontSize: 12, 241 | lineHeight: 12, 242 | color: '#bdc0d1', 243 | fontWeight: '100', 244 | paddingBottom: 15 245 | }, 246 | 247 | icons: { 248 | flexDirection: 'row', 249 | marginBottom: 10 250 | }, 251 | title: { 252 | position: 'absolute', 253 | top: 50, 254 | backgroundColor: 'transparent' 255 | 256 | }, 257 | titleText: { 258 | color: '#ffffff', 259 | fontSize: 18, 260 | shadowColor: '#071e48', 261 | shadowOffset: { 262 | width: 0, 263 | height: 0 264 | }, 265 | shadowRadius: 2 266 | }, 267 | inputNumber: { 268 | lineHeight: 40, 269 | color: '#fff', 270 | fontSize: 48, 271 | borderColor: null, 272 | borderWidth: 0 273 | }, 274 | inputDescription: { 275 | lineHeight: 40, 276 | color: '#ffffff', 277 | fontSize: 25, 278 | borderColor: null, 279 | borderWidth: 0 280 | }, 281 | modal: { 282 | justifyContent: 'flex-start', 283 | alignItems: 'flex-start', 284 | height: '90%', 285 | backgroundColor: '#f3f3f3' 286 | } 287 | 288 | }); 289 | 290 | export default connect(select)(ChangeBase); 291 | -------------------------------------------------------------------------------- /src/page/AddCoinController.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import { 3 | View, 4 | Text, 5 | ImageBackground, 6 | TextInput, 7 | StyleSheet, 8 | KeyboardAvoidingView, 9 | Dimensions, TouchableOpacity, ScrollView 10 | } from 'react-native'; 11 | import { connect } from 'react-redux'; 12 | import CoinIcon from '../component/CoinIcon'; 13 | import CoinCard from '../component/CoinCard'; 14 | import { addCoinMiddleware, editCoinMiddleware } from '../middleware/CustomMiddleware'; 15 | import { deleteCoin, MODE_ADD, MODE_EDIT } from '../actions/actions'; 16 | import Modal from 'react-native-modalbox'; 17 | import SelectCoinController from './SelectCoinController'; 18 | 19 | const contentHeight = Dimensions.get('window').height - 50; 20 | const dismissKeyboard = require('dismissKeyboard'); 21 | 22 | let _this = null; 23 | 24 | class AddCoinController extends Component { 25 | static navigationOptions = ({ navigation }) => ({ 26 | 27 | // header : null, 28 | headerTitle: navigation.state.params.id < 0 ? '添加虚拟货币' : '修改虚拟货币', 29 | headerBackTitle: '返回', 30 | headerStyle: { 31 | backgroundColor: '#244f85' 32 | }, 33 | headerTitleStyle: { 34 | color: '#ffffff' 35 | }, 36 | headerBackTitleStyle: { 37 | color: '#ffffff' 38 | }, 39 | headerRight: ( 40 | 41 | _this.doAction(_this.state.mode)} 46 | >保存 47 | 48 | ) 49 | }); 50 | 51 | constructor(props) { 52 | super(props); 53 | let { 54 | id, cuy, numbers, description 55 | } = this.props.navigation.state.params; 56 | if (numbers) numbers = numbers.toString(); 57 | const mode = id < 0 ? MODE_ADD : MODE_EDIT; 58 | this.state = { 59 | id, 60 | numbers: numbers || '', 61 | description: description || '', 62 | cuy: cuy || 'btc', 63 | mode, 64 | swipeToClose: true 65 | }; 66 | } 67 | 68 | componentDidMount() { 69 | _this = this; 70 | } 71 | 72 | render() { 73 | return ( 74 | 75 | 76 | dismissKeyboard()}> 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 拥有货币数量 (*) 85 | this.setState({ numbers: text })} 88 | keyboardType ='numeric' 89 | placeholder = '0.1' 90 | defaultValue = {this.state.numbers} 91 | /> 92 | 93 | 94 | 95 | 数字货币类型 (*) 96 | 97 | { 98 | ['btc', 'ltc', 'etc', 'xmr'].map((item, index) => ( 99 | { 100 | this.setState({ 101 | cuy: item 102 | }); 103 | } 104 | } > 105 | 106 | 107 | )) 108 | } 109 | { 110 | dismissKeyboard(); 111 | this.refs.modal1.open(); 112 | } 113 | } > 114 | 115 | 116 | 117 | 118 | 119 | 数字货币账户 120 | this.setState({ description: text })} 122 | style={styles.inputDescription} 123 | defaultValue = {this.state.description} 124 | placeholder = '1geekH9EiFeitKpigP8NKNJ6U...' 125 | /> 126 | 127 | 128 | 129 | 130 | 131 | 132 | (this.setState({ 133 | cuy 134 | }) 135 | )}/> 136 | 137 | 138 | 139 | 140 | 141 | ); 142 | } 143 | 144 | 145 | doAction(e) { 146 | switch (e) { 147 | case MODE_EDIT: 148 | this.editToCoin(); 149 | break; 150 | case MODE_ADD: 151 | this.addToCoin(); 152 | break; 153 | default: 154 | this.addToCoin(); 155 | } 156 | } 157 | 158 | addToCoin() { 159 | const { dispatch } = this.props; 160 | dispatch(addCoinMiddleware( 161 | `${this.state.cuy}-${this.props.visibleSettings.nation}`, 162 | parseFloat(this.state.numbers), 163 | this.state.description 164 | )); 165 | this.props.navigation.goBack(); 166 | } 167 | 168 | editToCoin() { 169 | const { dispatch } = this.props; 170 | dispatch(editCoinMiddleware( 171 | this.state.id, 172 | `${this.state.cuy}-${this.props.visibleSettings.nation}`, 173 | parseFloat(this.state.numbers), 174 | this.state.description 175 | )); 176 | this.props.navigation.goBack(); 177 | } 178 | 179 | deleteCoin(index) { 180 | const { dispatch } = this.props; 181 | dispatch(deleteCoin(index)); 182 | } 183 | } 184 | 185 | function select(state) { 186 | return { 187 | visibleCoins: state.reducer.coins, 188 | visibleSettings: state.reducer.settings 189 | }; 190 | } 191 | 192 | 193 | const styles = StyleSheet.create({ 194 | box: { 195 | width: '100%', 196 | height: contentHeight * 0.6 197 | }, 198 | card: { 199 | width: '90%', 200 | height: contentHeight * 0.4, 201 | justifyContent: 'center' 202 | }, 203 | main: { 204 | backgroundColor: '#244f85', 205 | width: '100%', 206 | height: '100%', 207 | justifyContent: 'center', 208 | alignItems: 'center' 209 | }, 210 | secondLayer: { 211 | backgroundColor: '#3d6b9c', 212 | flex: 1, 213 | width: '100%', 214 | paddingTop: 25, 215 | paddingLeft: 25, 216 | paddingRight: 25, 217 | paddingBottom: 10 218 | 219 | }, 220 | thirdLayer: { 221 | backgroundColor: '#275288', 222 | flex: 1, 223 | width: '100%', 224 | paddingTop: 25, 225 | paddingLeft: 25, 226 | paddingRight: 25, 227 | paddingBottom: 10 228 | 229 | }, 230 | forthLayer: { 231 | backgroundColor: '#244c7f', 232 | flex: 1, 233 | width: '100%', 234 | paddingTop: 25, 235 | paddingLeft: 25, 236 | paddingRight: 25, 237 | paddingBottom: 10 238 | 239 | }, 240 | label: { 241 | fontSize: 12, 242 | lineHeight: 12, 243 | color: '#bdc0d1', 244 | fontWeight: '100', 245 | paddingBottom: 15 246 | }, 247 | 248 | icons: { 249 | flexDirection: 'row', 250 | marginBottom: 10 251 | }, 252 | title: { 253 | position: 'absolute', 254 | top: 50, 255 | backgroundColor: 'transparent' 256 | 257 | }, 258 | titleText: { 259 | color: '#ffffff', 260 | fontSize: 18, 261 | shadowColor: '#071e48', 262 | shadowOffset: { 263 | width: 0, 264 | height: 0 265 | }, 266 | shadowRadius: 2 267 | }, 268 | inputNumber: { 269 | lineHeight: 40, 270 | color: '#fff', 271 | fontSize: 48, 272 | borderColor: null, 273 | borderWidth: 0 274 | }, 275 | inputDescription: { 276 | lineHeight: 40, 277 | color: '#ffffff', 278 | fontSize: 25, 279 | borderColor: null, 280 | borderWidth: 0 281 | }, 282 | modal: { 283 | justifyContent: 'flex-start', 284 | alignItems: 'flex-start', 285 | height: '90%', 286 | backgroundColor: '#f3f3f3' 287 | } 288 | 289 | }); 290 | 291 | export default connect(select)(AddCoinController); 292 | -------------------------------------------------------------------------------- /src/icon/demo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IcoMoon Demo 6 | 7 | 8 | 9 | 10 | 11 |
12 |

Font Name: icomoon (Glyphs: 67)

13 |
14 |
15 |

Grid Size: Unknown

16 |
17 |
18 | 19 | 20 | 21 | icon-x 22 |
23 |
24 | 25 | 26 |
27 |
28 | liga: 29 | 30 |
31 |
32 |
33 |
34 | 35 | 36 | 37 | icon-ada 38 |
39 |
40 | 41 | 42 |
43 |
44 | liga: 45 | 46 |
47 |
48 |
49 |
50 | 51 | 52 | 53 | icon-amp 54 |
55 |
56 | 57 | 58 |
59 |
60 | liga: 61 | 62 |
63 |
64 |
65 |
66 | 67 | 68 | 69 | icon-ant 70 |
71 |
72 | 73 | 74 |
75 |
76 | liga: 77 | 78 |
79 |
80 |
81 |
82 | 83 | 84 | 85 | icon-ardr 86 |
87 |
88 | 89 | 90 |
91 |
92 | liga: 93 | 94 |
95 |
96 |
97 |
98 | 99 | 100 | 101 | icon-ark 102 |
103 |
104 | 105 | 106 |
107 |
108 | liga: 109 | 110 |
111 |
112 |
113 |
114 | 115 | 116 | 117 | icon-bat 118 |
119 |
120 | 121 | 122 |
123 |
124 | liga: 125 | 126 |
127 |
128 |
129 |
130 | 131 | 132 | 133 | icon-bcc 134 |
135 |
136 | 137 | 138 |
139 |
140 | liga: 141 | 142 |
143 |
144 |
145 |
146 | 147 | 148 | 149 | icon-bch 150 |
151 |
152 | 153 | 154 |
155 |
156 | liga: 157 | 158 |
159 |
160 |
161 |
162 | 163 | 164 | 165 | icon-bcn 166 |
167 |
168 | 169 | 170 |
171 |
172 | liga: 173 | 174 |
175 |
176 |
177 |
178 | 179 | 180 | 181 | icon-bnb 182 |
183 |
184 | 185 | 186 |
187 |
188 | liga: 189 | 190 |
191 |
192 |
193 |
194 | 195 | 196 | 197 | icon-btc 198 |
199 |
200 | 201 | 202 |
203 |
204 | liga: 205 | 206 |
207 |
208 |
209 |
210 | 211 | 212 | 213 | icon-btcd 214 |
215 |
216 | 217 | 218 |
219 |
220 | liga: 221 | 222 |
223 |
224 |
225 |
226 | 227 | 228 | 229 | icon-bts 230 |
231 |
232 | 233 | 234 |
235 |
236 | liga: 237 | 238 |
239 |
240 |
241 |
242 | 243 | 244 | 245 | icon-dash 246 |
247 |
248 | 249 | 250 |
251 |
252 | liga: 253 | 254 |
255 |
256 |
257 |
258 | 259 | 260 | 261 | icon-dcr 262 |
263 |
264 | 265 | 266 |
267 |
268 | liga: 269 | 270 |
271 |
272 |
273 |
274 | 275 | 276 | 277 | icon-dgb 278 |
279 |
280 | 281 | 282 |
283 |
284 | liga: 285 | 286 |
287 |
288 |
289 |
290 | 291 | 292 | 293 | icon-dgd 294 |
295 |
296 | 297 | 298 |
299 |
300 | liga: 301 | 302 |
303 |
304 |
305 |
306 | 307 | 308 | 309 | icon-doge 310 |
311 |
312 | 313 | 314 |
315 |
316 | liga: 317 | 318 |
319 |
320 |
321 |
322 | 323 | 324 | 325 | icon-emc 326 |
327 |
328 | 329 | 330 |
331 |
332 | liga: 333 | 334 |
335 |
336 |
337 |
338 | 339 | 340 | 341 | icon-eos 342 |
343 |
344 | 345 | 346 |
347 |
348 | liga: 349 | 350 |
351 |
352 |
353 |
354 | 355 | 356 | 357 | icon-etc 358 |
359 |
360 | 361 | 362 |
363 |
364 | liga: 365 | 366 |
367 |
368 |
369 |
370 | 371 | 372 | 373 | icon-eth 374 |
375 |
376 | 377 | 378 |
379 |
380 | liga: 381 | 382 |
383 |
384 |
385 |
386 | 387 | 388 | 389 | icon-fct 390 |
391 |
392 | 393 | 394 |
395 |
396 | liga: 397 | 398 |
399 |
400 |
401 |
402 | 403 | 404 | 405 | icon-game 406 |
407 |
408 | 409 | 410 |
411 |
412 | liga: 413 | 414 |
415 |
416 |
417 |
418 | 419 | 420 | 421 | icon-gbyte 422 |
423 |
424 | 425 | 426 |
427 |
428 | liga: 429 | 430 |
431 |
432 |
433 |
434 | 435 | 436 | 437 | icon-gno 438 |
439 |
440 | 441 | 442 |
443 |
444 | liga: 445 | 446 |
447 |
448 |
449 |
450 | 451 | 452 | 453 | icon-gnt 454 |
455 |
456 | 457 | 458 |
459 |
460 | liga: 461 | 462 |
463 |
464 |
465 |
466 | 467 | 468 | 469 | icon-hsr 470 |
471 |
472 | 473 | 474 |
475 |
476 | liga: 477 | 478 |
479 |
480 |
481 |
482 | 483 | 484 | 485 | icon-icn 486 |
487 |
488 | 489 | 490 |
491 |
492 | liga: 493 | 494 |
495 |
496 |
497 |
498 | 499 | 500 | 501 | icon-kmd 502 |
503 |
504 | 505 | 506 |
507 |
508 | liga: 509 | 510 |
511 |
512 |
513 |
514 | 515 | 516 | 517 | icon-knc 518 |
519 |
520 | 521 | 522 |
523 |
524 | liga: 525 | 526 |
527 |
528 |
529 |
530 | 531 | 532 | 533 | icon-lkk 534 |
535 |
536 | 537 | 538 |
539 |
540 | liga: 541 | 542 |
543 |
544 |
545 |
546 | 547 | 548 | 549 | icon-lsk 550 |
551 |
552 | 553 | 554 |
555 |
556 | liga: 557 | 558 |
559 |
560 |
561 |
562 | 563 | 564 | 565 | icon-ltc 566 |
567 |
568 | 569 | 570 |
571 |
572 | liga: 573 | 574 |
575 |
576 |
577 |
578 | 579 | 580 | 581 | icon-maid 582 |
583 |
584 | 585 | 586 |
587 |
588 | liga: 589 | 590 |
591 |
592 |
593 |
594 | 595 | 596 | 597 | icon-miota 598 |
599 |
600 | 601 | 602 |
603 |
604 | liga: 605 | 606 |
607 |
608 |
609 |
610 | 611 | 612 | 613 | icon-mln 614 |
615 |
616 | 617 | 618 |
619 |
620 | liga: 621 | 622 |
623 |
624 |
625 |
626 | 627 | 628 | 629 | icon-mona 630 |
631 |
632 | 633 | 634 |
635 |
636 | liga: 637 | 638 |
639 |
640 |
641 |
642 | 643 | 644 | 645 | icon-neo 646 |
647 |
648 | 649 | 650 |
651 |
652 | liga: 653 | 654 |
655 |
656 |
657 |
658 | 659 | 660 | 661 | icon-nlg 662 |
663 |
664 | 665 | 666 |
667 |
668 | liga: 669 | 670 |
671 |
672 |
673 |
674 | 675 | 676 | 677 | icon-nmc 678 |
679 |
680 | 681 | 682 |
683 |
684 | liga: 685 | 686 |
687 |
688 |
689 |
690 | 691 | 692 | 693 | icon-nxt 694 |
695 |
696 | 697 | 698 |
699 |
700 | liga: 701 | 702 |
703 |
704 |
705 |
706 | 707 | 708 | 709 | icon-omg 710 |
711 |
712 | 713 | 714 |
715 |
716 | liga: 717 | 718 |
719 |
720 |
721 |
722 | 723 | 724 | 725 | icon-pay 726 |
727 |
728 | 729 | 730 |
731 |
732 | liga: 733 | 734 |
735 |
736 |
737 |
738 | 739 | 740 | 741 | icon-pivx 742 |
743 |
744 | 745 | 746 |
747 |
748 | liga: 749 | 750 |
751 |
752 |
753 |
754 | 755 | 756 | 757 | icon-pot 758 |
759 |
760 | 761 | 762 |
763 |
764 | liga: 765 | 766 |
767 |
768 |
769 |
770 | 771 | 772 | 773 | icon-ppc 774 |
775 |
776 | 777 | 778 |
779 |
780 | liga: 781 | 782 |
783 |
784 |
785 |
786 | 787 | 788 | 789 | icon-ppt 790 |
791 |
792 | 793 | 794 |
795 |
796 | liga: 797 | 798 |
799 |
800 |
801 |
802 | 803 | 804 | 805 | icon-qtum 806 |
807 |
808 | 809 | 810 |
811 |
812 | liga: 813 | 814 |
815 |
816 |
817 |
818 | 819 | 820 | 821 | icon-rep 822 |
823 |
824 | 825 | 826 |
827 |
828 | liga: 829 | 830 |
831 |
832 |
833 |
834 | 835 | 836 | 837 | icon-salt 838 |
839 |
840 | 841 | 842 |
843 |
844 | liga: 845 | 846 |
847 |
848 |
849 |
850 | 851 | 852 | 853 | icon-sc 854 |
855 |
856 | 857 | 858 |
859 |
860 | liga: 861 | 862 |
863 |
864 |
865 |
866 | 867 | 868 | 869 | icon-sngls 870 |
871 |
872 | 873 | 874 |
875 |
876 | liga: 877 | 878 |
879 |
880 |
881 |
882 | 883 | 884 | 885 | icon-steem 886 |
887 |
888 | 889 | 890 |
891 |
892 | liga: 893 | 894 |
895 |
896 |
897 |
898 | 899 | 900 | 901 | icon-strat 902 |
903 |
904 | 905 | 906 |
907 |
908 | liga: 909 | 910 |
911 |
912 |
913 |
914 | 915 | 916 | 917 | icon-trx 918 |
919 |
920 | 921 | 922 |
923 |
924 | liga: 925 | 926 |
927 |
928 |
929 |
930 | 931 | 932 | 933 | icon-usdt 934 |
935 |
936 | 937 | 938 |
939 |
940 | liga: 941 | 942 |
943 |
944 |
945 |
946 | 947 | 948 | 949 | icon-vtc 950 |
951 |
952 | 953 | 954 |
955 |
956 | liga: 957 | 958 |
959 |
960 |
961 |
962 | 963 | 964 | 965 | icon-waves 966 |
967 |
968 | 969 | 970 |
971 |
972 | liga: 973 | 974 |
975 |
976 |
977 |
978 | 979 | 980 | 981 | icon-xcp 982 |
983 |
984 | 985 | 986 |
987 |
988 | liga: 989 | 990 |
991 |
992 |
993 |
994 | 995 | 996 | 997 | icon-xem 998 |
999 |
1000 | 1001 | 1002 |
1003 |
1004 | liga: 1005 | 1006 |
1007 |
1008 |
1009 |
1010 | 1011 | 1012 | 1013 | icon-xlm 1014 |
1015 |
1016 | 1017 | 1018 |
1019 |
1020 | liga: 1021 | 1022 |
1023 |
1024 |
1025 |
1026 | 1027 | 1028 | 1029 | icon-xmr 1030 |
1031 |
1032 | 1033 | 1034 |
1035 |
1036 | liga: 1037 | 1038 |
1039 |
1040 |
1041 |
1042 | 1043 | 1044 | 1045 | icon-xrp 1046 |
1047 |
1048 | 1049 | 1050 |
1051 |
1052 | liga: 1053 | 1054 |
1055 |
1056 |
1057 |
1058 | 1059 | 1060 | 1061 | icon-xtz 1062 |
1063 |
1064 | 1065 | 1066 |
1067 |
1068 | liga: 1069 | 1070 |
1071 |
1072 |
1073 |
1074 | 1075 | 1076 | 1077 | icon-zec 1078 |
1079 |
1080 | 1081 | 1082 |
1083 |
1084 | liga: 1085 | 1086 |
1087 |
1088 |
1089 | 1090 | 1091 |
1092 |

Font Test Drive

1093 | 1098 | 1100 |
  1101 |
1102 |
1103 | 1104 |
1105 |

Generated by IcoMoon

1106 |
1107 | 1108 | 1109 | 1110 | 1111 | --------------------------------------------------------------------------------