mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-12-29 00:21:41 +03:00
Merged with master
This commit is contained in:
commit
37575489d2
@ -137,11 +137,11 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compile project(':react-native-fast-image')
|
||||
compile project(':realm')
|
||||
compile project(':react-native-vector-icons')
|
||||
compile project(':react-native-restart')
|
||||
compile project(':react-native-linear-gradient')
|
||||
compile project(':react-native-fast-image')
|
||||
implementation fileTree(dir: "libs", include: ["*.jar"])
|
||||
implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}"
|
||||
implementation "com.facebook.react:react-native:+" // From node_modules
|
||||
|
@ -14,7 +14,7 @@
|
||||
android:name=".MainActivity"
|
||||
android:label="@string/app_name"
|
||||
android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
android:windowSoftInputMode="adjustPan">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
|
@ -3,11 +3,11 @@ package com.esteem;
|
||||
import android.app.Application;
|
||||
|
||||
import com.facebook.react.ReactApplication;
|
||||
import com.dylanvann.fastimage.FastImageViewPackage;
|
||||
import io.realm.react.RealmReactPackage;
|
||||
import com.oblador.vectoricons.VectorIconsPackage;
|
||||
import com.avishayil.rnrestart.ReactNativeRestartPackage;
|
||||
import com.BV.LinearGradient.LinearGradientPackage;
|
||||
import com.dylanvann.fastimage.FastImageViewPackage;
|
||||
import com.facebook.react.ReactNativeHost;
|
||||
import com.facebook.react.ReactPackage;
|
||||
import com.facebook.react.shell.MainReactPackage;
|
||||
@ -28,11 +28,11 @@ public class MainApplication extends Application implements ReactApplication {
|
||||
protected List<ReactPackage> getPackages() {
|
||||
return Arrays.<ReactPackage>asList(
|
||||
new MainReactPackage(),
|
||||
new FastImageViewPackage(),
|
||||
new RealmReactPackage(),
|
||||
new VectorIconsPackage(),
|
||||
new ReactNativeRestartPackage(),
|
||||
new LinearGradientPackage(),
|
||||
new FastImageViewPackage()
|
||||
new LinearGradientPackage()
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,6 @@
|
||||
rootProject.name = 'esteem'
|
||||
include ':react-native-fast-image'
|
||||
project(':react-native-fast-image').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-fast-image/android')
|
||||
include ':realm'
|
||||
project(':realm').projectDir = new File(rootProject.projectDir, '../node_modules/realm/android')
|
||||
include ':react-native-vector-icons'
|
||||
@ -7,7 +9,5 @@ include ':react-native-restart'
|
||||
project(':react-native-restart').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-restart/android')
|
||||
include ':react-native-linear-gradient'
|
||||
project(':react-native-linear-gradient').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-linear-gradient/android')
|
||||
include ':react-native-fast-image'
|
||||
project(':react-native-fast-image').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-fast-image/android')
|
||||
|
||||
include ':app'
|
||||
|
@ -47,7 +47,6 @@
|
||||
64D2BA75D6054D5B89967502 /* Roboto.ttf in Resources */ = {isa = PBXBuildFile; fileRef = C308EE3EEC7A48BD919DDFF2 /* Roboto.ttf */; };
|
||||
75A37827C6324BFEA60CC6DA /* EvilIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = F084E460D2B1450B9827AB33 /* EvilIcons.ttf */; };
|
||||
832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
|
||||
85DF300A6EDC4AE98CD8B5AB /* libFastImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A668FDF5F71F4AC7B4EC6B1D /* libFastImage.a */; };
|
||||
912899FDD21841C7A2444920 /* Feather.ttf in Resources */ = {isa = PBXBuildFile; fileRef = D81FE31209CF4D24AA4DAE1B /* Feather.ttf */; };
|
||||
ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */; };
|
||||
CBE87E3CB30C4B90B585E2FD /* Foundation.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 6CC9B75BE0E640CBB2DE5316 /* Foundation.ttf */; };
|
||||
@ -58,6 +57,7 @@
|
||||
F9220AB054914BE1BF04A4B2 /* libRNVectorIcons.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 8616E7F6C6264500B0F3C0AB /* libRNVectorIcons.a */; };
|
||||
FB28DFAA729D4DC3B1668FBC /* Entypo.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 0754D5AAEA2D4DCA9DA7283D /* Entypo.ttf */; };
|
||||
FE22D3734B2C48CB890715FF /* libRealmReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 6D0A4B6BC3004763A0094EF3 /* libRealmReact.a */; };
|
||||
BA0C1519F2E34F3090353B33 /* libFastImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A0E809C308B04FFF8DEB1C3E /* libFastImage.a */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
/* Begin PBXContainerItemProxy section */
|
||||
@ -117,13 +117,6 @@
|
||||
remoteGlobalIDString = 64AA15081EF7F30100718508;
|
||||
remoteInfo = "BVLinearGradient-tvOS";
|
||||
};
|
||||
0C518B79217202700049DBA5 /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 5B1A171CF0E94B1CB0D66C57 /* FastImage.xcodeproj */;
|
||||
proxyType = 2;
|
||||
remoteGlobalIDString = A287971D1DE0C0A60081BDFA;
|
||||
remoteInfo = FastImage;
|
||||
};
|
||||
0C518B7C217202700049DBA5 /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 2DBBBAA0633D41CBB01D6FEB /* RCTRestart.xcodeproj */;
|
||||
@ -409,7 +402,6 @@
|
||||
2F7FE3F27575464186B3A5EC /* Zocial.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Zocial.ttf; path = "../node_modules/native-base/Fonts/Zocial.ttf"; sourceTree = "<group>"; };
|
||||
44CA43D49E374185BA6F37AF /* BVLinearGradient.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = BVLinearGradient.xcodeproj; path = "../node_modules/react-native-linear-gradient/BVLinearGradient.xcodeproj"; sourceTree = "<group>"; };
|
||||
56E30585028B4757AFB2F260 /* Octicons.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Octicons.ttf; path = "../node_modules/native-base/Fonts/Octicons.ttf"; sourceTree = "<group>"; };
|
||||
5B1A171CF0E94B1CB0D66C57 /* FastImage.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = FastImage.xcodeproj; path = "../node_modules/react-native-fast-image/ios/FastImage.xcodeproj"; sourceTree = "<group>"; };
|
||||
5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTAnimation.xcodeproj; path = "../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj"; sourceTree = "<group>"; };
|
||||
6CC9B75BE0E640CBB2DE5316 /* Foundation.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Foundation.ttf; path = "../node_modules/native-base/Fonts/Foundation.ttf"; sourceTree = "<group>"; };
|
||||
6D0A4B6BC3004763A0094EF3 /* libRealmReact.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libRealmReact.a; sourceTree = "<group>"; };
|
||||
@ -419,7 +411,6 @@
|
||||
88197F38DF02441F9B738AFF /* rubicon-icon-font.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "rubicon-icon-font.ttf"; path = "../node_modules/native-base/Fonts/rubicon-icon-font.ttf"; sourceTree = "<group>"; };
|
||||
8C8AE61985C54992AC765420 /* FontAwesome.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = FontAwesome.ttf; path = "../node_modules/native-base/Fonts/FontAwesome.ttf"; sourceTree = "<group>"; };
|
||||
9F13A372FBF946B5BDBE78FA /* Ionicons.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Ionicons.ttf; path = "../node_modules/native-base/Fonts/Ionicons.ttf"; sourceTree = "<group>"; };
|
||||
A668FDF5F71F4AC7B4EC6B1D /* libFastImage.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libFastImage.a; sourceTree = "<group>"; };
|
||||
ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTBlob.xcodeproj; path = "../node_modules/react-native/Libraries/Blob/RCTBlob.xcodeproj"; sourceTree = "<group>"; };
|
||||
B2C904BFD14B44C68128BB7F /* libRCTRestart.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libRCTRestart.a; sourceTree = "<group>"; };
|
||||
B3E4DB34CA2240EDA2D0E831 /* SimpleLineIcons.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = SimpleLineIcons.ttf; path = "../node_modules/native-base/Fonts/SimpleLineIcons.ttf"; sourceTree = "<group>"; };
|
||||
@ -431,6 +422,8 @@
|
||||
E75C11A31EE54C5899D50416 /* Roboto_medium.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Roboto_medium.ttf; path = "../node_modules/native-base/Fonts/Roboto_medium.ttf"; sourceTree = "<group>"; };
|
||||
F084E460D2B1450B9827AB33 /* EvilIcons.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = EvilIcons.ttf; path = "../node_modules/native-base/Fonts/EvilIcons.ttf"; sourceTree = "<group>"; };
|
||||
FBBEEEBB9C8048F78189B2C0 /* libc++.tbd */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; };
|
||||
C840826DE45F44E5A4972D7F /* FastImage.xcodeproj */ = {isa = PBXFileReference; name = "FastImage.xcodeproj"; path = "../node_modules/react-native-fast-image/ios/FastImage.xcodeproj"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = wrapper.pb-project; explicitFileType = undefined; includeInIndex = 0; };
|
||||
A0E809C308B04FFF8DEB1C3E /* libFastImage.a */ = {isa = PBXFileReference; name = "libFastImage.a"; path = "libFastImage.a"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = archive.ar; explicitFileType = undefined; includeInIndex = 0; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXFrameworksBuildPhase section */
|
||||
@ -458,13 +451,13 @@
|
||||
832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */,
|
||||
00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */,
|
||||
139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */,
|
||||
85DF300A6EDC4AE98CD8B5AB /* libFastImage.a in Frameworks */,
|
||||
3AB14466CEC544049AD08811 /* libBVLinearGradient.a in Frameworks */,
|
||||
D91033650FE94398A5424B19 /* libRCTRestart.a in Frameworks */,
|
||||
F9220AB054914BE1BF04A4B2 /* libRNVectorIcons.a in Frameworks */,
|
||||
FE22D3734B2C48CB890715FF /* libRealmReact.a in Frameworks */,
|
||||
5E482AACE164450FAD00E13F /* libc++.tbd in Frameworks */,
|
||||
4EB85A02CD474B848E110697 /* libz.tbd in Frameworks */,
|
||||
BA0C1519F2E34F3090353B33 /* libFastImage.a in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@ -590,14 +583,6 @@
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
0C518B6E2172026F0049DBA5 /* Products */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
0C518B7A217202700049DBA5 /* libFastImage.a */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
0C518B702172026F0049DBA5 /* Products */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
@ -727,11 +712,11 @@
|
||||
832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */,
|
||||
00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */,
|
||||
139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */,
|
||||
5B1A171CF0E94B1CB0D66C57 /* FastImage.xcodeproj */,
|
||||
44CA43D49E374185BA6F37AF /* BVLinearGradient.xcodeproj */,
|
||||
2DBBBAA0633D41CBB01D6FEB /* RCTRestart.xcodeproj */,
|
||||
CFB5920886014F419FC6D19A /* RNVectorIcons.xcodeproj */,
|
||||
0019E13B96A747699592B643 /* RealmReact.xcodeproj */,
|
||||
C840826DE45F44E5A4972D7F /* FastImage.xcodeproj */,
|
||||
);
|
||||
name = Libraries;
|
||||
sourceTree = "<group>";
|
||||
@ -896,10 +881,6 @@
|
||||
ProductGroup = 0C518B682172026F0049DBA5 /* Products */;
|
||||
ProjectRef = 44CA43D49E374185BA6F37AF /* BVLinearGradient.xcodeproj */;
|
||||
},
|
||||
{
|
||||
ProductGroup = 0C518B6E2172026F0049DBA5 /* Products */;
|
||||
ProjectRef = 5B1A171CF0E94B1CB0D66C57 /* FastImage.xcodeproj */;
|
||||
},
|
||||
{
|
||||
ProductGroup = 00C302A81ABCB8CE00DB3ED1 /* Products */;
|
||||
ProjectRef = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */;
|
||||
@ -1021,13 +1002,6 @@
|
||||
remoteRef = 0C518B76217202700049DBA5 /* PBXContainerItemProxy */;
|
||||
sourceTree = BUILT_PRODUCTS_DIR;
|
||||
};
|
||||
0C518B7A217202700049DBA5 /* libFastImage.a */ = {
|
||||
isa = PBXReferenceProxy;
|
||||
fileType = archive.ar;
|
||||
path = libFastImage.a;
|
||||
remoteRef = 0C518B79217202700049DBA5 /* PBXContainerItemProxy */;
|
||||
sourceTree = BUILT_PRODUCTS_DIR;
|
||||
};
|
||||
0C518B7D217202700049DBA5 /* libRCTRestart.a */ = {
|
||||
isa = PBXReferenceProxy;
|
||||
fileType = archive.ar;
|
||||
@ -1434,17 +1408,18 @@
|
||||
);
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = esteemTests/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
@ -1463,17 +1438,18 @@
|
||||
COPY_PHASE_STRIP = NO;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = esteemTests/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
@ -1493,11 +1469,11 @@
|
||||
DEAD_CODE_STRIPPING = NO;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = esteem/Info.plist;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
@ -1519,11 +1495,11 @@
|
||||
CURRENT_PROJECT_VERSION = 1;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = esteem/Info.plist;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
@ -1552,16 +1528,17 @@
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = "esteem-tvOS/Info.plist";
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
@ -1589,16 +1566,17 @@
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = "esteem-tvOS/Info.plist";
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
@ -1625,16 +1603,17 @@
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = "esteem-tvOSTests/Info.plist";
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
@ -1661,16 +1640,17 @@
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-linear-gradient/BVLinearGradient",
|
||||
"$(SRCROOT)/../node_modules/react-native-restart/ios/RCTRestart/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
|
||||
"$(SRCROOT)/../node_modules/realm/src/**",
|
||||
"$(SRCROOT)/../node_modules/react-native-fast-image/ios/FastImage/**",
|
||||
);
|
||||
INFOPLIST_FILE = "esteem-tvOSTests/Info.plist";
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"\"$(SRCROOT)/$(TARGET_NAME)\"",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-ObjC",
|
||||
|
@ -38,7 +38,7 @@
|
||||
</dict>
|
||||
</dict>
|
||||
<key>NSLocationWhenInUseUsageDescription</key>
|
||||
<string></string>
|
||||
<string/>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
@ -70,19 +70,5 @@
|
||||
<string>SimpleLineIcons.ttf</string>
|
||||
<string>Zocial.ttf</string>
|
||||
</array>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>armv7</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<false/>
|
||||
</dict>
|
||||
</plist>
|
||||
|
287
package-lock.json
generated
287
package-lock.json
generated
@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "esteem",
|
||||
"name": "eSteem",
|
||||
"version": "0.0.1",
|
||||
"lockfileVersion": 1,
|
||||
"requires": true,
|
||||
@ -302,11 +302,6 @@
|
||||
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.1.2.tgz",
|
||||
"integrity": "sha512-x5HFsW+E/nQalGMw7hu+fvPqnBeBaIr0lWJ2SG0PPL2j+Pm9lYvCrsZJGIgauPIENx0v10INIyFjmSNUD/gSqQ=="
|
||||
},
|
||||
"@babel/plugin-check-constants": {
|
||||
"version": "7.0.0-beta.38",
|
||||
"resolved": "https://registry.npmjs.org/@babel/plugin-check-constants/-/plugin-check-constants-7.0.0-beta.38.tgz",
|
||||
"integrity": "sha512-MjdGn/2sMLu0fnNFbkILut0OsegzRTeCOJ/uGHH88TwTXPzxONx2cTVJ36i3cTQXHMiIOUT3hX6HqzWM99Q6vA=="
|
||||
},
|
||||
"@babel/plugin-external-helpers": {
|
||||
"version": "7.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@babel/plugin-external-helpers/-/plugin-external-helpers-7.0.0.tgz",
|
||||
@ -1512,7 +1507,7 @@
|
||||
"dependencies": {
|
||||
"chalk": {
|
||||
"version": "1.1.3",
|
||||
"resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
|
||||
"requires": {
|
||||
"ansi-styles": "^2.2.1",
|
||||
@ -1705,7 +1700,7 @@
|
||||
},
|
||||
"babel-plugin-istanbul": {
|
||||
"version": "4.1.6",
|
||||
"resolved": "http://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz",
|
||||
"resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz",
|
||||
"integrity": "sha512-PWP9FQ1AhZhS01T/4qLSKoHGY/xvkZdVBGlKM/HuxxS3+sC66HhTNR7+MpbO/so/cz/wY94MeSWJuP1hXIPfwQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -1738,7 +1733,7 @@
|
||||
},
|
||||
"babel-plugin-syntax-object-rest-spread": {
|
||||
"version": "6.13.0",
|
||||
"resolved": "http://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz",
|
||||
"integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U="
|
||||
},
|
||||
"babel-plugin-syntax-trailing-function-commas": {
|
||||
@ -2291,7 +2286,7 @@
|
||||
},
|
||||
"browserify-aes": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "http://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz",
|
||||
"integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==",
|
||||
"requires": {
|
||||
"buffer-xor": "^1.0.3",
|
||||
@ -2600,7 +2595,7 @@
|
||||
},
|
||||
"color": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "http://registry.npmjs.org/color/-/color-1.0.3.tgz",
|
||||
"resolved": "https://registry.npmjs.org/color/-/color-1.0.3.tgz",
|
||||
"integrity": "sha1-5I6DLYXxTvaU+0aIEcLVz+cptV0=",
|
||||
"requires": {
|
||||
"color-convert": "^1.8.2",
|
||||
@ -2779,7 +2774,7 @@
|
||||
},
|
||||
"create-hash": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "http://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz",
|
||||
"integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==",
|
||||
"requires": {
|
||||
"cipher-base": "^1.0.1",
|
||||
@ -2791,7 +2786,7 @@
|
||||
},
|
||||
"create-hmac": {
|
||||
"version": "1.1.7",
|
||||
"resolved": "http://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz",
|
||||
"resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz",
|
||||
"integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==",
|
||||
"requires": {
|
||||
"cipher-base": "^1.0.3",
|
||||
@ -3856,7 +3851,7 @@
|
||||
},
|
||||
"events": {
|
||||
"version": "1.1.1",
|
||||
"resolved": "http://registry.npmjs.org/events/-/events-1.1.1.tgz",
|
||||
"resolved": "https://registry.npmjs.org/events/-/events-1.1.1.tgz",
|
||||
"integrity": "sha1-nr23Y1rQmccNzEwqH1AEKI6L2SQ="
|
||||
},
|
||||
"evp_bytestokey": {
|
||||
@ -3958,7 +3953,7 @@
|
||||
},
|
||||
"external-editor": {
|
||||
"version": "2.2.0",
|
||||
"resolved": "http://registry.npmjs.org/external-editor/-/external-editor-2.2.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/external-editor/-/external-editor-2.2.0.tgz",
|
||||
"integrity": "sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A==",
|
||||
"requires": {
|
||||
"chardet": "^0.4.0",
|
||||
@ -4834,7 +4829,7 @@
|
||||
},
|
||||
"get-stream": {
|
||||
"version": "3.0.0",
|
||||
"resolved": "http://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz",
|
||||
"integrity": "sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ="
|
||||
},
|
||||
"get-value": {
|
||||
@ -5350,7 +5345,7 @@
|
||||
},
|
||||
"is-builtin-module": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "http://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz",
|
||||
"integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=",
|
||||
"requires": {
|
||||
"builtin-modules": "^1.0.0"
|
||||
@ -5495,7 +5490,7 @@
|
||||
},
|
||||
"is-obj": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "http://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz",
|
||||
"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz",
|
||||
"integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8=",
|
||||
"dev": true
|
||||
},
|
||||
@ -6983,12 +6978,12 @@
|
||||
},
|
||||
"json5": {
|
||||
"version": "0.5.1",
|
||||
"resolved": "http://registry.npmjs.org/json5/-/json5-0.5.1.tgz",
|
||||
"resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz",
|
||||
"integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE="
|
||||
},
|
||||
"jsonfile": {
|
||||
"version": "2.4.0",
|
||||
"resolved": "http://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
|
||||
"integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=",
|
||||
"requires": {
|
||||
"graceful-fs": "^4.1.6"
|
||||
@ -7538,7 +7533,7 @@
|
||||
"dependencies": {
|
||||
"chalk": {
|
||||
"version": "1.1.3",
|
||||
"resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -7584,7 +7579,7 @@
|
||||
"dependencies": {
|
||||
"chalk": {
|
||||
"version": "1.1.3",
|
||||
"resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||
"integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -7634,7 +7629,7 @@
|
||||
},
|
||||
"load-json-file": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
|
||||
"integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=",
|
||||
"requires": {
|
||||
"graceful-fs": "^4.1.2",
|
||||
@ -7914,9 +7909,9 @@
|
||||
}
|
||||
},
|
||||
"metro": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro/-/metro-0.47.1.tgz",
|
||||
"integrity": "sha512-39o0ZLHNWOi8+Pc2zB/gG0bito7BEmjUF4AKZLkOSGMuQw4JF/WcgN20v3XRR4hCL8SEQr6YSFw2Vpzw8OSYyA==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro/-/metro-0.48.1.tgz",
|
||||
"integrity": "sha512-7V+YOqfmgGhomdWAoD58zRQvPxUgBIo6b1YgcZULvh7yPPMo3tTkTvrzS2Qd2N3LFTysRQWzOlkb7O7jAV5FDw==",
|
||||
"requires": {
|
||||
"@babel/core": "^7.0.0",
|
||||
"@babel/generator": "^7.0.0",
|
||||
@ -7944,13 +7939,13 @@
|
||||
"json-stable-stringify": "^1.0.1",
|
||||
"lodash.throttle": "^4.1.1",
|
||||
"merge-stream": "^1.0.1",
|
||||
"metro-cache": "0.47.1",
|
||||
"metro-config": "0.47.1",
|
||||
"metro-core": "0.47.1",
|
||||
"metro-minify-uglify": "0.47.1",
|
||||
"metro-react-native-babel-preset": "0.47.1",
|
||||
"metro-resolver": "0.47.1",
|
||||
"metro-source-map": "0.47.1",
|
||||
"metro-cache": "0.48.1",
|
||||
"metro-config": "0.48.1",
|
||||
"metro-core": "0.48.1",
|
||||
"metro-minify-uglify": "0.48.1",
|
||||
"metro-react-native-babel-preset": "0.48.1",
|
||||
"metro-resolver": "0.48.1",
|
||||
"metro-source-map": "0.48.1",
|
||||
"mime-types": "2.1.11",
|
||||
"mkdirp": "^0.5.1",
|
||||
"node-fetch": "^2.2.0",
|
||||
@ -7975,11 +7970,10 @@
|
||||
"integrity": "sha512-Xj9XuRuz3nTSbaTXWv3itLOcxyF4oPD8douBBmj7U9BBC6nEBYfyOJYQMf/8PJAFotC62UY5dFfIGEPr7WswzQ=="
|
||||
},
|
||||
"babel-preset-fbjs": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/babel-preset-fbjs/-/babel-preset-fbjs-3.0.1.tgz",
|
||||
"integrity": "sha512-Fc0t7v8T1tBwv5AVyDDZEnS3T7OQ97qV0XawVZg1ouarlM9xCHL994C5tU8TBIKPk3yZXG+SaEM1YQcx/yLlcg==",
|
||||
"version": "3.1.0",
|
||||
"resolved": "https://registry.npmjs.org/babel-preset-fbjs/-/babel-preset-fbjs-3.1.0.tgz",
|
||||
"integrity": "sha512-j+B9xZsnqWFxHaqt3B8aFYftSgrcgbO5NF3mTtHYd6R442NJW2aBk3k+XvxXwIia98UuZxCg8psZY79bXbhwew==",
|
||||
"requires": {
|
||||
"@babel/plugin-check-constants": "^7.0.0-beta.38",
|
||||
"@babel/plugin-proposal-class-properties": "^7.0.0",
|
||||
"@babel/plugin-proposal-object-rest-spread": "^7.0.0",
|
||||
"@babel/plugin-syntax-class-properties": "^7.0.0",
|
||||
@ -8040,9 +8034,9 @@
|
||||
}
|
||||
},
|
||||
"metro-react-native-babel-preset": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-react-native-babel-preset/-/metro-react-native-babel-preset-0.47.1.tgz",
|
||||
"integrity": "sha512-p5qrbcECeZ/PYQm3Sv7cxMtVdUz4TZrhjjGFkAdmSWlhveztALYzk0lNn6fL3DCRcFRiO0NvS90JO5XXOJFk3w==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-react-native-babel-preset/-/metro-react-native-babel-preset-0.48.1.tgz",
|
||||
"integrity": "sha512-euJ0MOyBYTa76kQNbly6An9FNpu9BqxfkXhKtD8hWZxo5dxIAk25AmoWfXU2OHj7PogG/u0Ndo3tmhZZ2NWYvA==",
|
||||
"requires": {
|
||||
"@babel/plugin-proposal-class-properties": "^7.0.0",
|
||||
"@babel/plugin-proposal-export-default-from": "^7.0.0",
|
||||
@ -8077,18 +8071,18 @@
|
||||
"@babel/plugin-transform-typescript": "^7.0.0",
|
||||
"@babel/plugin-transform-unicode-regex": "^7.0.0",
|
||||
"@babel/template": "^7.0.0",
|
||||
"metro-babel7-plugin-react-transform": "0.47.1",
|
||||
"metro-babel7-plugin-react-transform": "0.48.1",
|
||||
"react-transform-hmr": "^1.0.4"
|
||||
}
|
||||
},
|
||||
"mime-db": {
|
||||
"version": "1.23.0",
|
||||
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.23.0.tgz",
|
||||
"resolved": "http://registry.npmjs.org/mime-db/-/mime-db-1.23.0.tgz",
|
||||
"integrity": "sha1-oxtAcK2uon1zLqMzdApk0OyaZlk="
|
||||
},
|
||||
"mime-types": {
|
||||
"version": "2.1.11",
|
||||
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.11.tgz",
|
||||
"resolved": "http://registry.npmjs.org/mime-types/-/mime-types-2.1.11.tgz",
|
||||
"integrity": "sha1-wlnEcb2oCKhdbNGTtDCl+uRHOzw=",
|
||||
"requires": {
|
||||
"mime-db": "~1.23.0"
|
||||
@ -8122,9 +8116,9 @@
|
||||
}
|
||||
},
|
||||
"metro-babel-register": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-babel-register/-/metro-babel-register-0.47.1.tgz",
|
||||
"integrity": "sha512-yp7Z55VrpO3ZJLgFTcBNlhYmPCfstvBDRbj0S/d6IAk9YQeI10XSFOsVJcRgbrEfihrU/un7VXc3QC8PIkjxlQ==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-babel-register/-/metro-babel-register-0.48.1.tgz",
|
||||
"integrity": "sha512-bSjMAD16vpyHRWeMJ6CXvhWbFbiW58YXhA9zgRbFBdxOcJPbkhj6HEX+FlxTlr2O0MNY27/4U96MFXTcRWcZhQ==",
|
||||
"requires": {
|
||||
"@babel/core": "^7.0.0",
|
||||
"@babel/plugin-proposal-class-properties": "^7.0.0",
|
||||
@ -8148,33 +8142,33 @@
|
||||
}
|
||||
},
|
||||
"metro-babel7-plugin-react-transform": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-babel7-plugin-react-transform/-/metro-babel7-plugin-react-transform-0.47.1.tgz",
|
||||
"integrity": "sha512-b7drnNbVww/AastsGlVBy3o5HJUGgjEMB1UrXHYh8Me5dVqirH5uEdy0d3cQAnMaq4lv5PBmcaoX/FP0bdLI5A==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-babel7-plugin-react-transform/-/metro-babel7-plugin-react-transform-0.48.1.tgz",
|
||||
"integrity": "sha512-b39Sowwzp0bqitbS3NkF5fzcuoT6vpLqj6Su7xgfCyW5EmYpvxunK7HwMSoZagAIpbD0H6r+iw+L2Ib1EEWfWw==",
|
||||
"requires": {
|
||||
"@babel/helper-module-imports": "^7.0.0"
|
||||
}
|
||||
},
|
||||
"metro-cache": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-cache/-/metro-cache-0.47.1.tgz",
|
||||
"integrity": "sha512-pMW9soKT2adcTLLPX52aJADPVl1u0NYKNBXG+B3J2vB4OZmtAQq66PlG+sl0sjqGoq4PoUW+Oq+L3J5RcAMTmQ==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-cache/-/metro-cache-0.48.1.tgz",
|
||||
"integrity": "sha512-Nq1RQ7SkhVKKO/uWKzc6JtvDm0JJD/kDsoIQNR2Db37fNlyGxij0FoYRNOX3BOnyhz0NG8kU1pz0qH43bPQ5rg==",
|
||||
"requires": {
|
||||
"jest-serializer": "23.0.1",
|
||||
"metro-core": "0.47.1",
|
||||
"metro-core": "0.48.1",
|
||||
"mkdirp": "^0.5.1",
|
||||
"rimraf": "^2.5.4"
|
||||
}
|
||||
},
|
||||
"metro-config": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-config/-/metro-config-0.47.1.tgz",
|
||||
"integrity": "sha512-TqVGWCfD8OHqdSmQn7hEmEYxGlATim6rnhOEp5hJvqPPdVnN8iU/5qRdTl8FR7sH7Axx5TeV1pi8G86M8m0djg==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-config/-/metro-config-0.48.1.tgz",
|
||||
"integrity": "sha512-pqdbDHUtoQPfWiL8h3x/cN5Q8w/sPt5/UaXk4oIzalU+ooEh0Hi9w10wJHKVRtWzD27o828O04En51C9eEDY5g==",
|
||||
"requires": {
|
||||
"cosmiconfig": "^5.0.5",
|
||||
"metro": "0.47.1",
|
||||
"metro-cache": "0.47.1",
|
||||
"metro-core": "0.47.1",
|
||||
"metro": "0.48.1",
|
||||
"metro-cache": "0.48.1",
|
||||
"metro-core": "0.48.1",
|
||||
"pretty-format": "^23.4.1"
|
||||
},
|
||||
"dependencies": {
|
||||
@ -8203,25 +8197,25 @@
|
||||
}
|
||||
},
|
||||
"metro-core": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-core/-/metro-core-0.47.1.tgz",
|
||||
"integrity": "sha512-xO/vP3jNd8GD2nZw7rJq+dQ/UEJ4pniHmP3rV0a8jIMRMIsknHaf8EX/C66H8bcYV0eTkRoY1MZH2AV1cCGTAw==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-core/-/metro-core-0.48.1.tgz",
|
||||
"integrity": "sha512-uctosjP4imHThHlD5hAt0Yg7tiRLmY3GlU4VaIs0YH2i82yI56b93RtTCI1ACWhL7LUuttSVpPXCBN3ERTe+KA==",
|
||||
"requires": {
|
||||
"jest-haste-map": "23.5.0",
|
||||
"lodash.throttle": "^4.1.1",
|
||||
"metro-resolver": "0.47.1",
|
||||
"metro-resolver": "0.48.1",
|
||||
"wordwrap": "^1.0.0"
|
||||
}
|
||||
},
|
||||
"metro-memory-fs": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-memory-fs/-/metro-memory-fs-0.47.1.tgz",
|
||||
"integrity": "sha512-C+QSofDZvPlWvFKMn0aYFYWpOT8t28i6TfdIhWY5AkXECUr0W8a7POgSIx022G4fWyF/SxSqccXpp7zSjn6EZA=="
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-memory-fs/-/metro-memory-fs-0.48.1.tgz",
|
||||
"integrity": "sha512-ASbRBpmfRraFilm5o5gdY9X0DQAmkvCgAHDunCo0J2vlQ730VbuhhR67pVRmRr5oXXmDdEIYUkJSIqzP0Q+UKQ=="
|
||||
},
|
||||
"metro-minify-uglify": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-minify-uglify/-/metro-minify-uglify-0.47.1.tgz",
|
||||
"integrity": "sha512-7AKb8wZJr4TiJMV5xyeV67ZGhhvh0s9tV56zCM1DIMuJVuFbqcKHJUPghiiA+zL6m1MgRMTxaIzjeNh3eM+xoA==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-minify-uglify/-/metro-minify-uglify-0.48.1.tgz",
|
||||
"integrity": "sha512-8htDNs3dil5CopLnMrE6SGjMGg44KB+omE3ZyTNSWXbmZl8aG3spl+xpSJyvkIQrSFNSCzMVZ8V+lDJDwKJ/zg==",
|
||||
"requires": {
|
||||
"uglify-es": "^3.1.9"
|
||||
},
|
||||
@ -8302,17 +8296,17 @@
|
||||
}
|
||||
},
|
||||
"metro-resolver": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-resolver/-/metro-resolver-0.47.1.tgz",
|
||||
"integrity": "sha512-eb6i2tnVi+wASPxWk71P4lsJ7ndbRsv8qEijgTDaOBXYZliDEJW5uHC41JJK0IeRLYu+N3eGc/EdhOjTUGJj1A==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-resolver/-/metro-resolver-0.48.1.tgz",
|
||||
"integrity": "sha512-d28ki5RTRUPFNQVJEgiMx3Zr81NlxOm1mKgaBx93Alyy2ZZ1Gvs25olZHwHgKPsRTgCqg5kgImkIHtjP2j8BdQ==",
|
||||
"requires": {
|
||||
"absolute-path": "^0.0.0"
|
||||
}
|
||||
},
|
||||
"metro-source-map": {
|
||||
"version": "0.47.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-source-map/-/metro-source-map-0.47.1.tgz",
|
||||
"integrity": "sha512-E3mM+CVC4m9QMCQWgHOf2iapjZbt7KeKu1AorRt5pDbWk6bPxbmdO7y+mvaZWktqveB5qTi7CCoBhvS7E7Qonw==",
|
||||
"version": "0.48.1",
|
||||
"resolved": "https://registry.npmjs.org/metro-source-map/-/metro-source-map-0.48.1.tgz",
|
||||
"integrity": "sha512-6+YSKB3zRLGA39I0G/wfPizf1HPlrnmeX70E1vvH0G1HVD/ko5dqjJgH4vlr71Za9xYZLSuaXoQmmgkcf6at4w==",
|
||||
"requires": {
|
||||
"source-map": "^0.5.6"
|
||||
}
|
||||
@ -8406,13 +8400,13 @@
|
||||
},
|
||||
"minimist": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
|
||||
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ="
|
||||
},
|
||||
"minipass": {
|
||||
"version": "2.3.4",
|
||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.4.tgz",
|
||||
"integrity": "sha512-mlouk1OHlaUE8Odt1drMtG1bAJA4ZA6B/ehysgV0LUIrDHdKgo1KorZq3pK0b/7Z7LJIQ12MNM6aC+Tn6lUZ5w==",
|
||||
"version": "2.3.5",
|
||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.5.tgz",
|
||||
"integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==",
|
||||
"requires": {
|
||||
"safe-buffer": "^5.1.2",
|
||||
"yallist": "^3.0.0"
|
||||
@ -8426,9 +8420,9 @@
|
||||
}
|
||||
},
|
||||
"minizlib": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.1.0.tgz",
|
||||
"integrity": "sha512-4T6Ur/GctZ27nHfpt9THOdRZNgyJ9FZchYO1ceg5S8Q3DNLCKYy44nCZzgCJgcvx2UM8czmqak5BCxJMrq37lA==",
|
||||
"version": "1.1.1",
|
||||
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.1.1.tgz",
|
||||
"integrity": "sha512-TrfjCjk4jLhcJyGMYymBH6oTXcWjYbUAXTHDbtnWHjZC25h0cdajHuPE1zxb4DVmu8crfh+HwH/WMuyLG0nHBg==",
|
||||
"requires": {
|
||||
"minipass": "^2.2.1"
|
||||
}
|
||||
@ -8454,7 +8448,7 @@
|
||||
},
|
||||
"mkdirp": {
|
||||
"version": "0.5.1",
|
||||
"resolved": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
|
||||
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
|
||||
"integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
|
||||
"requires": {
|
||||
"minimist": "0.0.8"
|
||||
@ -8462,7 +8456,7 @@
|
||||
"dependencies": {
|
||||
"minimist": {
|
||||
"version": "0.0.8",
|
||||
"resolved": "http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
|
||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
|
||||
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0="
|
||||
}
|
||||
}
|
||||
@ -8580,7 +8574,7 @@
|
||||
},
|
||||
"react-native-keyboard-aware-scroll-view": {
|
||||
"version": "0.5.0",
|
||||
"resolved": "http://registry.npmjs.org/react-native-keyboard-aware-scroll-view/-/react-native-keyboard-aware-scroll-view-0.5.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/react-native-keyboard-aware-scroll-view/-/react-native-keyboard-aware-scroll-view-0.5.0.tgz",
|
||||
"integrity": "sha512-nGXsACZBCiWuwRrZy+UjiSJqb4tZ/6ePHUSY8M+09g4VfNm/ogvvWpwBa6B999NZ6DwhZTKBjVWeZxX9XG8bbQ==",
|
||||
"requires": {
|
||||
"prop-types": "^15.6.0",
|
||||
@ -8752,9 +8746,9 @@
|
||||
"integrity": "sha512-m/e6jgWu8/v5niCUKQi9qQl8QdeEduFA96xHDDzFGqly0OOjI7c+60KM/2sppfnUU9JJagf+zs+yGhqSOFj71g=="
|
||||
},
|
||||
"npm-packlist": {
|
||||
"version": "1.1.11",
|
||||
"resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.1.11.tgz",
|
||||
"integrity": "sha512-CxKlZ24urLkJk+9kCm48RTQ7L4hsmgSVzEk0TLGPzzyuFxD7VNgy5Sl24tOLMzQv773a/NeJ1ce1DKeacqffEA==",
|
||||
"version": "1.1.12",
|
||||
"resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.1.12.tgz",
|
||||
"integrity": "sha512-WJKFOVMeAlsU/pjXuqVdzU0WfgtIBCupkEVwn+1Y0ERAbUfWw8R4GjgVbaKnUjRoD2FoQbHOCbOyT5Mbs9Lw4g==",
|
||||
"requires": {
|
||||
"ignore-walk": "^3.0.1",
|
||||
"npm-bundled": "^1.0.1"
|
||||
@ -8790,7 +8784,7 @@
|
||||
},
|
||||
"npmlog": {
|
||||
"version": "2.0.4",
|
||||
"resolved": "https://registry.npmjs.org/npmlog/-/npmlog-2.0.4.tgz",
|
||||
"resolved": "http://registry.npmjs.org/npmlog/-/npmlog-2.0.4.tgz",
|
||||
"integrity": "sha1-mLUlMPJRTKkNCexbIsiEZyI3VpI=",
|
||||
"requires": {
|
||||
"ansi": "~0.3.1",
|
||||
@ -8984,7 +8978,7 @@
|
||||
"dependencies": {
|
||||
"minimist": {
|
||||
"version": "0.0.10",
|
||||
"resolved": "http://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz",
|
||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz",
|
||||
"integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8="
|
||||
},
|
||||
"wordwrap": {
|
||||
@ -9437,7 +9431,7 @@
|
||||
},
|
||||
"regexpp": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "http://registry.npmjs.org/regexpp/-/regexpp-1.1.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/regexpp/-/regexpp-1.1.0.tgz",
|
||||
"integrity": "sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw==",
|
||||
"dev": true
|
||||
},
|
||||
@ -9565,9 +9559,9 @@
|
||||
}
|
||||
},
|
||||
"querystringify": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.0.0.tgz",
|
||||
"integrity": "sha512-eTPo5t/4bgaMNZxyjWx6N2a6AuE0mq51KWvpc7nU/MAqixcI6v6KrGUKES0HaomdnolQBBXU/++X6/QQ9KL4tw=="
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.1.0.tgz",
|
||||
"integrity": "sha512-sluvZZ1YiTLD5jsqZcDmFyV2EwToyXZBfpoVOmktMmW+VEnhgakFHnasVph65fOjGPTWN0Nw3+XQaSeMayr0kg=="
|
||||
},
|
||||
"raf": {
|
||||
"version": "3.4.0",
|
||||
@ -9616,14 +9610,14 @@
|
||||
}
|
||||
},
|
||||
"react": {
|
||||
"version": "16.5.0",
|
||||
"resolved": "https://registry.npmjs.org/react/-/react-16.5.0.tgz",
|
||||
"integrity": "sha512-nw/yB/L51kA9PsAy17T1JrzzGRk+BlFCJwFF7p+pwVxgqwPjYNeZEkkH7LXn9dmflolrYMXLWMTkQ77suKPTNQ==",
|
||||
"version": "16.6.0",
|
||||
"resolved": "https://registry.npmjs.org/react/-/react-16.6.0.tgz",
|
||||
"integrity": "sha512-zJPnx/jKtuOEXCbQ9BKaxDMxR0001/hzxXwYxG8septeyYGfsgAei6NgfbVgOhbY1WOP2o3VPs/E9HaN+9hV3Q==",
|
||||
"requires": {
|
||||
"loose-envify": "^1.1.0",
|
||||
"object-assign": "^4.1.1",
|
||||
"prop-types": "^15.6.2",
|
||||
"schedule": "^0.3.0"
|
||||
"scheduler": "^0.10.0"
|
||||
}
|
||||
},
|
||||
"react-clone-referenced-element": {
|
||||
@ -9637,9 +9631,9 @@
|
||||
"integrity": "sha512-WUSQJ4P/wWcusaH+zZmbECOk7H5N2pOIl0vzheeornkIMhu+qrNdGFm0bDZLCb0hSF0jf/kH1SgkNGfBdTc4wA=="
|
||||
},
|
||||
"react-devtools-core": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/react-devtools-core/-/react-devtools-core-3.4.0.tgz",
|
||||
"integrity": "sha512-yV3LLhoRwbfcQyVPNwb1EZ9W7CGu+kX2EqyZ3Cl5C+cbXcb6FJ3YSeeBt9BQB+hjyjRMBjQSKqnpPS6OMSEUow==",
|
||||
"version": "3.4.2",
|
||||
"resolved": "https://registry.npmjs.org/react-devtools-core/-/react-devtools-core-3.4.2.tgz",
|
||||
"integrity": "sha512-1pqbxenMeOiVPLf5Fm69woc+Q/pb/lLfWCizJuVJQDm9v7x0fcr76VMcq6Q30Onv3ikkfrlAQgOcOdCk/0t5tA==",
|
||||
"requires": {
|
||||
"shell-quote": "^1.6.1",
|
||||
"ws": "^3.3.1"
|
||||
@ -9663,9 +9657,9 @@
|
||||
}
|
||||
},
|
||||
"react-is": {
|
||||
"version": "16.5.2",
|
||||
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.5.2.tgz",
|
||||
"integrity": "sha512-hSl7E6l25GTjNEZATqZIuWOgSnpXb3kD0DVCujmg46K5zLxsbiKaaT6VO9slkSBDPZfYs30lwfJwbOFOnoEnKQ==",
|
||||
"version": "16.6.0",
|
||||
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.6.0.tgz",
|
||||
"integrity": "sha512-q8U7k0Fi7oxF1HvQgyBjPwDXeMplEsArnKt2iYhuIF86+GBbgLHdAmokL3XUFjTd7Q363OSNG55FOGUdONVn1g==",
|
||||
"dev": true
|
||||
},
|
||||
"react-lifecycles-compat": {
|
||||
@ -9674,9 +9668,9 @@
|
||||
"integrity": "sha512-fBASbA6LnOU9dOU2eW7aQ8xmYBSXUIWr+UmF9b1efZBazGNO+rcXT/icdKnYm2pTwcRylVUYwW7H1PHfLekVzA=="
|
||||
},
|
||||
"react-native": {
|
||||
"version": "0.57.2",
|
||||
"resolved": "https://registry.npmjs.org/react-native/-/react-native-0.57.2.tgz",
|
||||
"integrity": "sha512-UbFbyt0rfrNLOtBXn3EmtHJ3EqL0/PhGCfGGZIg7vHn/U4K+2wZNvrLwzhqiZYSjvtmJluA1vMiQTvWBupCx8w==",
|
||||
"version": "0.57.3",
|
||||
"resolved": "https://registry.npmjs.org/react-native/-/react-native-0.57.3.tgz",
|
||||
"integrity": "sha512-FmJQdGjo0rEfEYbw+dhMPn2P/vDpvPebAwL3YDaQ/iYSi+IGPNHdepEaDpU1vfFOAnxrh3BlfACC+RsoeQ3SWw==",
|
||||
"requires": {
|
||||
"@babel/runtime": "^7.0.0",
|
||||
"absolute-path": "^0.0.0",
|
||||
@ -9693,17 +9687,17 @@
|
||||
"errorhandler": "^1.5.0",
|
||||
"escape-string-regexp": "^1.0.5",
|
||||
"event-target-shim": "^1.0.5",
|
||||
"fbjs": "0.8.17",
|
||||
"fbjs": "^1.0.0",
|
||||
"fbjs-scripts": "^0.8.1",
|
||||
"fs-extra": "^1.0.0",
|
||||
"glob": "^7.1.1",
|
||||
"graceful-fs": "^4.1.3",
|
||||
"inquirer": "^3.0.6",
|
||||
"lodash": "^4.17.5",
|
||||
"metro": "^0.47.1",
|
||||
"metro-babel-register": "^0.47.1",
|
||||
"metro-core": "^0.47.1",
|
||||
"metro-memory-fs": "^0.47.1",
|
||||
"metro": "^0.48.1",
|
||||
"metro-babel-register": "^0.48.1",
|
||||
"metro-core": "^0.48.1",
|
||||
"metro-memory-fs": "^0.48.1",
|
||||
"mime": "^1.3.4",
|
||||
"minimist": "^1.2.0",
|
||||
"mkdirp": "^0.5.1",
|
||||
@ -9732,6 +9726,26 @@
|
||||
"yargs": "^9.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"core-js": {
|
||||
"version": "2.5.7",
|
||||
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.7.tgz",
|
||||
"integrity": "sha512-RszJCAxg/PP6uzXVXL6BsxSXx/B05oJAQ2vkJRjyjrEcNVycaqOmNb5OTxZPE3xa5gwZduqza6L9JOCenh/Ecw=="
|
||||
},
|
||||
"fbjs": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/fbjs/-/fbjs-1.0.0.tgz",
|
||||
"integrity": "sha512-MUgcMEJaFhCaF1QtWGnmq9ZDRAzECTCRAF7O6UZIlAlkTs1SasiX9aP0Iw7wfD2mJ7wDTNfg2w7u5fSCwJk1OA==",
|
||||
"requires": {
|
||||
"core-js": "^2.4.1",
|
||||
"fbjs-css-vars": "^1.0.0",
|
||||
"isomorphic-fetch": "^2.1.1",
|
||||
"loose-envify": "^1.0.0",
|
||||
"object-assign": "^4.1.0",
|
||||
"promise": "^7.1.1",
|
||||
"setimmediate": "^1.0.5",
|
||||
"ua-parser-js": "^0.7.18"
|
||||
}
|
||||
},
|
||||
"fs-extra": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-1.0.0.tgz",
|
||||
@ -9964,7 +9978,7 @@
|
||||
},
|
||||
"react-native-vector-icons": {
|
||||
"version": "4.6.0",
|
||||
"resolved": "http://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-4.6.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-4.6.0.tgz",
|
||||
"integrity": "sha512-rpfhfPiXCK2PX1nrNhdxSMrEGB/Gw/SvKoPM0G2wAkSoqynnes19K0VYI+Up7DqR1rFIpE4hP2erpT1tNx2tfg==",
|
||||
"requires": {
|
||||
"lodash": "^4.0.0",
|
||||
@ -10064,7 +10078,7 @@
|
||||
},
|
||||
"react-redux": {
|
||||
"version": "5.0.7",
|
||||
"resolved": "http://registry.npmjs.org/react-redux/-/react-redux-5.0.7.tgz",
|
||||
"resolved": "https://registry.npmjs.org/react-redux/-/react-redux-5.0.7.tgz",
|
||||
"integrity": "sha512-5VI8EV5hdgNgyjfmWzBbdrqUkrVRKlyTKk1sGH3jzM2M2Mhj/seQgPXaz6gVAj2lz/nz688AdTqMO18Lr24Zhg==",
|
||||
"requires": {
|
||||
"hoist-non-react-statics": "^2.5.0",
|
||||
@ -10083,15 +10097,15 @@
|
||||
}
|
||||
},
|
||||
"react-test-renderer": {
|
||||
"version": "16.5.0",
|
||||
"resolved": "https://registry.npmjs.org/react-test-renderer/-/react-test-renderer-16.5.0.tgz",
|
||||
"integrity": "sha512-cuN9BoZ1p6T3oxrjxN7pQDSmgWzAxWBi8gtCHcViMYcw/1xqOIyatt2YFhiCWg7115TPQqkTKEu+F44YjFE4ig==",
|
||||
"version": "16.6.0-alpha.8af6728",
|
||||
"resolved": "https://registry.npmjs.org/react-test-renderer/-/react-test-renderer-16.6.0-alpha.8af6728.tgz",
|
||||
"integrity": "sha512-42RB1hvEjVuJGrGddGqVj1obs9NhWiuijkz+qsuY0qRzF0ygD5xg4eRdm0H4YNtkp+332g6OWO9O2ussu67cFQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"object-assign": "^4.1.1",
|
||||
"prop-types": "^15.6.2",
|
||||
"react-is": "^16.5.0",
|
||||
"schedule": "^0.3.0"
|
||||
"react-is": "^16.6.0-alpha.8af6728",
|
||||
"scheduler": "^0.10.0-alpha.8af6728"
|
||||
}
|
||||
},
|
||||
"react-timer-mixin": {
|
||||
@ -10138,7 +10152,7 @@
|
||||
},
|
||||
"readable-stream": {
|
||||
"version": "2.3.6",
|
||||
"resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
|
||||
"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
|
||||
"integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
|
||||
"requires": {
|
||||
"core-util-is": "~1.0.0",
|
||||
@ -10151,9 +10165,9 @@
|
||||
}
|
||||
},
|
||||
"realm": {
|
||||
"version": "2.18.0",
|
||||
"resolved": "https://registry.npmjs.org/realm/-/realm-2.18.0.tgz",
|
||||
"integrity": "sha512-+FzQ0S3WjcnklhCZx/SPFh/rU311w+gfPOrtlG2wZPB6qq4ZJ6sarIIrHAyB0y7eHiWxDpwIYTW0oMQgwpNh3g==",
|
||||
"version": "2.16.0",
|
||||
"resolved": "https://registry.npmjs.org/realm/-/realm-2.16.0.tgz",
|
||||
"integrity": "sha512-u2n8+/0XzUVcsCB2VJ0E1KU2BHG08to7td6gm/bAhHgY9a8z4+ye1Gxod7i7cXepG9zljlU9k7fJck7/EbHnMA==",
|
||||
"requires": {
|
||||
"command-line-args": "^4.0.6",
|
||||
"decompress": "^4.2.0",
|
||||
@ -10890,11 +10904,12 @@
|
||||
"resolved": "http://registry.npmjs.org/sax/-/sax-1.1.6.tgz",
|
||||
"integrity": "sha1-XWFr6KXmB9VOEUr65Vt+ry/MMkA="
|
||||
},
|
||||
"schedule": {
|
||||
"version": "0.3.0",
|
||||
"resolved": "https://registry.npmjs.org/schedule/-/schedule-0.3.0.tgz",
|
||||
"integrity": "sha512-20+1KVo517sR7Nt+bYBN8a+bEJDKLPEx7Ohtts1kX05E4/HY53YUNuhfkVNItmWAnBYHcpG9vsd2/CJxG+aPCQ==",
|
||||
"scheduler": {
|
||||
"version": "0.10.0",
|
||||
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.10.0.tgz",
|
||||
"integrity": "sha512-+TSTVTCBAA3h8Anei3haDc1IRwMeDmtI/y/o3iBe3Mjl2vwYF9DtPDt929HyRmV/e7au7CLu8sc4C4W0VOs29w==",
|
||||
"requires": {
|
||||
"loose-envify": "^1.1.0",
|
||||
"object-assign": "^4.1.1"
|
||||
}
|
||||
},
|
||||
@ -11028,7 +11043,7 @@
|
||||
},
|
||||
"sha.js": {
|
||||
"version": "2.4.11",
|
||||
"resolved": "http://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz",
|
||||
"resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz",
|
||||
"integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==",
|
||||
"requires": {
|
||||
"inherits": "^2.0.1",
|
||||
@ -11543,7 +11558,7 @@
|
||||
},
|
||||
"strip-ansi": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
|
||||
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
|
||||
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
|
||||
"requires": {
|
||||
"ansi-regex": "^2.0.0"
|
||||
@ -11743,7 +11758,7 @@
|
||||
},
|
||||
"load-json-file": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
|
||||
"integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -11858,7 +11873,7 @@
|
||||
},
|
||||
"through": {
|
||||
"version": "2.3.8",
|
||||
"resolved": "http://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
||||
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
||||
"integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU="
|
||||
},
|
||||
"through2": {
|
||||
@ -12110,9 +12125,9 @@
|
||||
"integrity": "sha1-rOEWq1V80Zc4ak6I9GhTeMiy5Po="
|
||||
},
|
||||
"unbzip2-stream": {
|
||||
"version": "1.3.0",
|
||||
"resolved": "https://registry.npmjs.org/unbzip2-stream/-/unbzip2-stream-1.3.0.tgz",
|
||||
"integrity": "sha512-kE2WkurNnPUMcryNioS68DDbhoPB8Qxsd8btHSj+sd5Pjh2GsjmeHLzMSqV9HHziAo8FzVxVCJl9ZYhk7yY1pA==",
|
||||
"version": "1.3.1",
|
||||
"resolved": "https://registry.npmjs.org/unbzip2-stream/-/unbzip2-stream-1.3.1.tgz",
|
||||
"integrity": "sha512-fIZnvdjblYs7Cru/xC6tCPVhz7JkYcVQQkePwMLyQELzYTds2Xn8QefPVnvdVhhZqubxNA1cASXEH5wcK0Bucw==",
|
||||
"requires": {
|
||||
"buffer": "^3.0.1",
|
||||
"through": "^2.3.6"
|
||||
@ -12142,7 +12157,7 @@
|
||||
},
|
||||
"underscore.string": {
|
||||
"version": "2.4.0",
|
||||
"resolved": "http://registry.npmjs.org/underscore.string/-/underscore.string-2.4.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/underscore.string/-/underscore.string-2.4.0.tgz",
|
||||
"integrity": "sha1-jN2PusTi0uoefi6Al8QvRCKA+Fs="
|
||||
},
|
||||
"unicode-canonical-property-names-ecmascript": {
|
||||
@ -12491,7 +12506,7 @@
|
||||
},
|
||||
"wrap-ansi": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "http://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
|
||||
"resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
|
||||
"integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=",
|
||||
"requires": {
|
||||
"string-width": "^1.0.1",
|
||||
|
@ -6,6 +6,7 @@ import PostPlaceHolder from './view/postPlaceHolderView';
|
||||
import TextWithIcon from './view/textWithIconView';
|
||||
import WalletLineItem from './view/walletLineItemView';
|
||||
import Chip from './view/chipView';
|
||||
import ProfileSummaryPlaceHolder from './view/profileSummaryPlaceHolder';
|
||||
|
||||
export {
|
||||
Card,
|
||||
@ -16,4 +17,5 @@ export {
|
||||
PostPlaceHolder,
|
||||
TextWithIcon,
|
||||
WalletLineItem,
|
||||
ProfileSummaryPlaceHolder,
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
import React from 'react';
|
||||
import { View, Fragment } from 'react-native';
|
||||
import { View } from 'react-native';
|
||||
import Placeholder from 'rn-placeholder';
|
||||
|
||||
import styles from './postPlaceHolderStyles';
|
||||
|
@ -0,0 +1,27 @@
|
||||
import React from 'react';
|
||||
import { View } from 'react-native';
|
||||
import Placeholder from 'rn-placeholder';
|
||||
|
||||
import styles from './profileSummaryPlaceHolderStyles';
|
||||
|
||||
const ProfileSummaryPlaceHolder = () => (
|
||||
<View style={styles.container}>
|
||||
<View style={styles.textWrapper}>
|
||||
<Placeholder.Paragraph lineNumber={1} />
|
||||
</View>
|
||||
<Placeholder.Box animate="fade" height={75} width="100%" radius={5} />
|
||||
<View style={styles.paragraphWrapper}>
|
||||
<Placeholder.Paragraph
|
||||
lineNumber={3}
|
||||
textSize={16}
|
||||
lineSpacing={5}
|
||||
width="100%"
|
||||
lastLineWidth="70%"
|
||||
firstLineWidth="50%"
|
||||
animate="fade"
|
||||
/>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
|
||||
export default ProfileSummaryPlaceHolder;
|
@ -0,0 +1,22 @@
|
||||
import EStyleSheet from 'react-native-extended-stylesheet';
|
||||
|
||||
export default EStyleSheet.create({
|
||||
container: {
|
||||
backgroundColor: '$white',
|
||||
padding: 20,
|
||||
borderStyle: 'solid',
|
||||
borderWidth: 1,
|
||||
borderTopWidth: 1,
|
||||
borderColor: '#e2e5e8',
|
||||
borderRadius: 5,
|
||||
marginRight: 0,
|
||||
marginLeft: 0,
|
||||
marginTop: 10,
|
||||
},
|
||||
textWrapper: {
|
||||
marginBottom: 10,
|
||||
},
|
||||
paragraphWrapper: {
|
||||
marginTop: 10,
|
||||
},
|
||||
});
|
@ -1,21 +1,21 @@
|
||||
import EStyleSheet from "react-native-extended-stylesheet";
|
||||
import EStyleSheet from 'react-native-extended-stylesheet';
|
||||
|
||||
export default EStyleSheet.create({
|
||||
container: {
|
||||
justifyContent: "center",
|
||||
justifyContent: 'center',
|
||||
margin: 5,
|
||||
},
|
||||
wrapper: {
|
||||
flexDirection: "row",
|
||||
alignSelf: "flex-start",
|
||||
flexDirection: 'row',
|
||||
alignSelf: 'flex-start',
|
||||
},
|
||||
icon: {
|
||||
color: "#c1c5c7",
|
||||
color: '#c1c5c7',
|
||||
fontSize: 12,
|
||||
marginRight: 3,
|
||||
},
|
||||
text: {
|
||||
color: "#788187",
|
||||
color: '#788187',
|
||||
fontSize: 11,
|
||||
},
|
||||
});
|
||||
|
@ -1,15 +1,14 @@
|
||||
import React from "react";
|
||||
import { View, TouchableHighlight, Text } from "react-native";
|
||||
import Ionicons from "react-native-vector-icons/Ionicons";
|
||||
import styles from "./textWithIconStyles";
|
||||
import React from 'react';
|
||||
import { View, TouchableHighlight, Text } from 'react-native';
|
||||
import Ionicons from 'react-native-vector-icons/Ionicons';
|
||||
import styles from './textWithIconStyles';
|
||||
|
||||
const TextWithIcon = ({ iconName, text, isClickable, onPress }) => (
|
||||
const TextWithIcon = ({
|
||||
iconName, text, isClickable, onPress,
|
||||
}) => (
|
||||
<View style={styles.container}>
|
||||
{isClickable || onPress ? (
|
||||
<TouchableHighlight
|
||||
underlayColor="transparent"
|
||||
onPress={() => onPress && onPress()}
|
||||
>
|
||||
<TouchableHighlight underlayColor="transparent" onPress={() => onPress && onPress()}>
|
||||
<View style={styles.wrapper}>
|
||||
{text && <Ionicons style={styles.icon} name={iconName} />}
|
||||
<Text style={styles.text}>{text}</Text>
|
||||
|
@ -33,8 +33,6 @@ class CollapsibleCardView extends Component {
|
||||
};
|
||||
}
|
||||
|
||||
// Component Life Cycles
|
||||
|
||||
// Component Functions
|
||||
_initContentHeight = (event) => {
|
||||
if (this.anime.contentHeight > 0) return;
|
||||
@ -70,6 +68,7 @@ class CollapsibleCardView extends Component {
|
||||
titleComponent,
|
||||
noBorder,
|
||||
fitContent,
|
||||
isTitleCenter,
|
||||
} = this.props;
|
||||
const { expanded } = this.state;
|
||||
|
||||
@ -81,6 +80,7 @@ class CollapsibleCardView extends Component {
|
||||
>
|
||||
{titleComponent || (
|
||||
<ContainerHeader
|
||||
isCenter={isTitleCenter}
|
||||
color={titleColor || '#788187'}
|
||||
fontSize={fontSize || 12}
|
||||
title={title}
|
||||
|
@ -19,10 +19,14 @@ export default EStyleSheet.create({
|
||||
fontSize: 14,
|
||||
fontWeight: '600',
|
||||
marginLeft: 32,
|
||||
width: '$deviceWidth - 64',
|
||||
},
|
||||
centerTitle: {
|
||||
textAlign: 'center',
|
||||
},
|
||||
icon: {
|
||||
alignSelf: 'center',
|
||||
color:"$iconColor",
|
||||
color: '$iconColor',
|
||||
fontSize: 18,
|
||||
marginRight: 32,
|
||||
},
|
||||
|
@ -33,13 +33,17 @@ class ContainerHeaderView extends Component {
|
||||
iconName,
|
||||
isBoldTitle,
|
||||
title,
|
||||
isCenter,
|
||||
} = this.props;
|
||||
|
||||
return (
|
||||
<View style={[styles.wrapper, hasSeperator && styles.hasTopBorder]}>
|
||||
<Text
|
||||
numberOfLines={2}
|
||||
ellipsizeMode="tail"
|
||||
style={[
|
||||
styles.title,
|
||||
isCenter && styles.centerTitle,
|
||||
isBoldTitle && { fontWeight: 'bold' },
|
||||
color && { color },
|
||||
fontSize && { fontSize },
|
||||
|
@ -34,8 +34,20 @@ class HeaderContainer extends Component {
|
||||
navigation.openDrawer();
|
||||
};
|
||||
|
||||
_handleOnPressBackButton = () => {
|
||||
const { navigation } = this.props;
|
||||
|
||||
navigation.navigate('HomeScreen');
|
||||
};
|
||||
|
||||
render() {
|
||||
return <HeaderView handleOpenDrawer={this._handleOpenDrawer} {...this.props} />;
|
||||
return (
|
||||
<HeaderView
|
||||
handleOnPressBackButton={this._handleOnPressBackButton}
|
||||
handleOpenDrawer={this._handleOpenDrawer}
|
||||
{...this.props}
|
||||
/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -9,19 +9,29 @@ export default EStyleSheet.create({
|
||||
maxHeight: 74,
|
||||
backgroundColor: '$white',
|
||||
},
|
||||
|
||||
containerReverse: {
|
||||
justifyContent: 'space-between',
|
||||
flexDirection: 'row-reverse',
|
||||
},
|
||||
avatarWrapperReverse: {
|
||||
borderTopLeftRadius: 68 / 2,
|
||||
borderBottomLeftRadius: 68 / 2,
|
||||
},
|
||||
avatarWrapper: {
|
||||
backgroundColor: '#357ce6',
|
||||
height: 50,
|
||||
width: 68,
|
||||
justifyContent: 'center',
|
||||
},
|
||||
avatarDefault: {
|
||||
borderTopRightRadius: 68 / 2,
|
||||
borderBottomRightRadius: 68 / 2,
|
||||
justifyContent: 'center',
|
||||
},
|
||||
titleWrapper: {
|
||||
flexDirection: 'column',
|
||||
justifyContent: 'center',
|
||||
marginLeft: 8,
|
||||
marginRight: 8,
|
||||
},
|
||||
title: {
|
||||
fontSize: 14,
|
||||
@ -39,4 +49,17 @@ export default EStyleSheet.create({
|
||||
alignSelf: 'flex-end',
|
||||
marginRight: 12,
|
||||
},
|
||||
backIcon: {
|
||||
fontSize: 24,
|
||||
color: '$iconColor',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
backButton: {
|
||||
marginLeft: 24,
|
||||
},
|
||||
backButtonWrapper: {
|
||||
flexGrow: 1,
|
||||
flexDirection: 'column',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
});
|
||||
|
@ -5,7 +5,12 @@ import {
|
||||
import FastImage from 'react-native-fast-image';
|
||||
// Constants
|
||||
|
||||
// Utils
|
||||
|
||||
import { getReputation } from '../../../utils/user';
|
||||
|
||||
// Components
|
||||
import { IconButton } from '../../iconButton';
|
||||
|
||||
// Styles
|
||||
import styles from './headerStyles';
|
||||
@ -29,20 +34,55 @@ class HeaderView extends Component {
|
||||
// Component Functions
|
||||
|
||||
render() {
|
||||
const { avatar, handleOpenDrawer, hideStatusBar } = this.props;
|
||||
const {
|
||||
avatar,
|
||||
handleOpenDrawer,
|
||||
handleOnPressBackButton,
|
||||
hideStatusBar,
|
||||
userName,
|
||||
isReverse,
|
||||
name,
|
||||
reputation,
|
||||
} = this.props;
|
||||
|
||||
return (
|
||||
<SafeAreaView style={styles.container}>
|
||||
<SafeAreaView style={[styles.container, isReverse && styles.containerReverse]}>
|
||||
<StatusBar hidden={hideStatusBar} translucent />
|
||||
<TouchableOpacity onPress={() => handleOpenDrawer()}>
|
||||
<View style={styles.avatarWrapper}>
|
||||
<FastImage style={styles.avatar} source={avatar} defaultSource={DEFAULT_IMAGE} />
|
||||
<TouchableOpacity onPress={() => !isReverse && handleOpenDrawer()}>
|
||||
<View
|
||||
style={[
|
||||
styles.avatarWrapper,
|
||||
isReverse ? styles.avatarWrapperReverse : styles.avatarDefault,
|
||||
]}
|
||||
>
|
||||
<FastImage
|
||||
style={styles.avatar}
|
||||
source={{ uri: avatar }}
|
||||
defaultSource={DEFAULT_IMAGE}
|
||||
/>
|
||||
</View>
|
||||
</TouchableOpacity>
|
||||
<View style={styles.titleWrapper}>
|
||||
<Text style={styles.title}> eSteem Project </Text>
|
||||
<Text style={styles.subTitle}> @u-e (63)</Text>
|
||||
{name && <Text style={styles.title}>{name}</Text>}
|
||||
{userName
|
||||
&& reputation && (
|
||||
<Text style={styles.subTitle}>
|
||||
@
|
||||
{userName}
|
||||
{`(${getReputation(reputation)})`}
|
||||
</Text>
|
||||
)}
|
||||
</View>
|
||||
{isReverse && (
|
||||
<View style={styles.backButtonWrapper}>
|
||||
<IconButton
|
||||
style={styles.backButton}
|
||||
iconStyle={styles.backIcon}
|
||||
name="md-arrow-back"
|
||||
onPress={() => handleOnPressBackButton()}
|
||||
/>
|
||||
</View>
|
||||
)}
|
||||
</SafeAreaView>
|
||||
);
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ const IconButton = ({
|
||||
}) => (
|
||||
<Fragment>
|
||||
<TouchableHighlight
|
||||
style={[!style && styles.iconButton, style && style]}
|
||||
style={[styles.iconButton, style && style]}
|
||||
onPress={() => onPress && onPress()}
|
||||
underlayColor={backgroundColor || 'white'}
|
||||
>
|
||||
|
@ -1,14 +1,5 @@
|
||||
import React, { Component } from 'react';
|
||||
|
||||
// Services and Actions
|
||||
|
||||
// Middleware
|
||||
|
||||
// Constants
|
||||
|
||||
// Utilities
|
||||
|
||||
// Component
|
||||
import { PostCardView } from '..';
|
||||
|
||||
/*
|
||||
@ -23,10 +14,6 @@ class PostCardContainer extends Component {
|
||||
this.state = {};
|
||||
}
|
||||
|
||||
// Component Life Cycle Functions
|
||||
|
||||
// Component Functions
|
||||
|
||||
render() {
|
||||
return <PostCardView {...this.props} />;
|
||||
}
|
||||
|
@ -117,8 +117,18 @@ class PostCard extends Component {
|
||||
});
|
||||
};
|
||||
|
||||
_handleOnUserPress = () => {
|
||||
const { handleOnUserPress, content, user } = this.props;
|
||||
|
||||
if (handleOnUserPress && content && content.author !== user.name) {
|
||||
handleOnUserPress(content.author);
|
||||
}
|
||||
};
|
||||
|
||||
render() {
|
||||
const { content, isLoggedIn, user } = this.props;
|
||||
const {
|
||||
content, isLoggedIn, user, handleOnUserPress,
|
||||
} = this.props;
|
||||
const {
|
||||
isVoted, isVoting, isModalVisible, value,
|
||||
} = this.state;
|
||||
@ -128,7 +138,9 @@ class PostCard extends Component {
|
||||
<Card style={styles.post}>
|
||||
<CardItem style={styles.header}>
|
||||
<Left>
|
||||
<TouchableOpacity>
|
||||
<TouchableOpacity
|
||||
onPress={() => this._handleOnUserPress()}
|
||||
>
|
||||
<Thumbnail style={styles.avatar} source={{ uri: content && content.avatar }} />
|
||||
</TouchableOpacity>
|
||||
<Body style={styles.body}>
|
||||
|
@ -1,10 +1,12 @@
|
||||
import React, { Component } from 'react';
|
||||
import { withNavigation } from 'react-navigation';
|
||||
|
||||
// Services and Actions
|
||||
|
||||
// Middleware
|
||||
|
||||
// Constants
|
||||
import { default as ROUTES } from '../../../constants/routeNames';
|
||||
|
||||
// Utilities
|
||||
|
||||
@ -27,9 +29,21 @@ class PostsContainer extends Component {
|
||||
|
||||
// Component Functions
|
||||
|
||||
_handleOnUserPress = (username) => {
|
||||
const { navigation } = this.props;
|
||||
|
||||
navigation.navigate({
|
||||
routeName: ROUTES.SCREENS.PROFILE,
|
||||
params: {
|
||||
username,
|
||||
},
|
||||
key: username + Math.random() * 100,
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
return <PostsView {...this.props} />;
|
||||
return <PostsView handleOnUserPress={this._handleOnUserPress} {...this.props} />;
|
||||
}
|
||||
}
|
||||
|
||||
export default PostsContainer;
|
||||
export default withNavigation(PostsContainer);
|
||||
|
@ -12,14 +12,17 @@ import { getPosts } from '../../../providers/steem/dsteem';
|
||||
import { PostCard } from '../../postCard';
|
||||
import { FilterBar } from '../../filterBar';
|
||||
import { PostPlaceHolder } from '../../basicUIElements';
|
||||
import { NoPost } from '../../basicUIElements';
|
||||
|
||||
// Styles
|
||||
import styles from './postsStyles';
|
||||
|
||||
class FeedView extends Component {
|
||||
class PostsView extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
isReady: false,
|
||||
user: props.user || null,
|
||||
posts: [],
|
||||
startAuthor: '',
|
||||
startPermlink: '',
|
||||
@ -30,10 +33,20 @@ class FeedView extends Component {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this._loadPosts();
|
||||
this._loadPosts(this.state.user);
|
||||
AppState.addEventListener('change', this._handleAppStateChange);
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps) {
|
||||
const { user } = this.props;
|
||||
|
||||
if (user !== nextProps.user) {
|
||||
this.setState({ user: nextProps.user });
|
||||
|
||||
this._loadPosts(nextProps.user, nextProps.tag);
|
||||
}
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
AppState.removeEventListener('change', this._handleAppStateChange);
|
||||
}
|
||||
@ -45,29 +58,34 @@ class FeedView extends Component {
|
||||
this.setState({ appState: nextAppState });
|
||||
};
|
||||
|
||||
_loadPosts = () => {
|
||||
const { user, getFor, tag } = this.props;
|
||||
_loadPosts = (user, _tag = null) => {
|
||||
const { getFor, tag } = this.props;
|
||||
const options = { tag: _tag || tag, limit: 10 };
|
||||
|
||||
getPosts(getFor, { tag, limit: 10 }, user.name)
|
||||
.then((result) => {
|
||||
if (result) {
|
||||
this.setState({
|
||||
isReady: true,
|
||||
posts: result,
|
||||
startAuthor: result[result.length - 1].author,
|
||||
startPermlink: result[result.length - 1].permlink,
|
||||
refreshing: false,
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
alert(err);
|
||||
});
|
||||
if (user) {
|
||||
getPosts(getFor, options, user)
|
||||
.then((result) => {
|
||||
if (result) {
|
||||
this.setState({
|
||||
isReady: true,
|
||||
posts: result,
|
||||
startAuthor: result[result.length - 1].author,
|
||||
startPermlink: result[result.length - 1].permlink,
|
||||
refreshing: false,
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
alert(err);
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
_loadMore = () => {
|
||||
const { posts, startAuthor, startPermlink } = this.state;
|
||||
const { user, getFor, tag } = this.props;
|
||||
const {
|
||||
posts, startAuthor, startPermlink, user,
|
||||
} = this.state;
|
||||
const { getFor, tag } = this.props;
|
||||
|
||||
this.setState({ isLoading: true });
|
||||
|
||||
@ -85,24 +103,26 @@ class FeedView extends Component {
|
||||
_posts.shift();
|
||||
this.setState({
|
||||
posts: [...posts, ..._posts],
|
||||
startAuthor: result[result.length - 1].author,
|
||||
startPermlink: result[result.length - 1].permlink,
|
||||
startAuthor: result && result[result.length - 1] && result[result.length - 1].author,
|
||||
startPermlink: result && result[result.length - 1] && result[result.length - 1].permlink,
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
_handleOnRefreshPosts = () => {
|
||||
const { user } = this.state;
|
||||
|
||||
this.setState(
|
||||
{
|
||||
refreshing: true,
|
||||
},
|
||||
() => {
|
||||
this._loadPosts();
|
||||
this._loadPosts(user);
|
||||
},
|
||||
);
|
||||
};
|
||||
|
||||
renderFooter = () => {
|
||||
_renderFooter = () => {
|
||||
const { isLoading } = this.state;
|
||||
|
||||
if (isLoading) {
|
||||
@ -116,29 +136,33 @@ class FeedView extends Component {
|
||||
};
|
||||
|
||||
_getRenderItem = () => {
|
||||
const { isReady, refreshing, posts } = this.state;
|
||||
const { componentId, user } = this.props;
|
||||
const {
|
||||
isReady, refreshing, posts, user,
|
||||
} = this.state;
|
||||
const { componentId, handleOnUserPress, filterOptions } = this.props;
|
||||
|
||||
if (isReady) {
|
||||
if (user && posts && posts.length > 0) {
|
||||
return (
|
||||
<Fragment>
|
||||
<FilterBar
|
||||
dropdownIconName="md-arrow-dropdown"
|
||||
options={[
|
||||
'ALL NOTIFICATION',
|
||||
'LATEST NOTF',
|
||||
'ESTEEMAPP',
|
||||
'UGUR ERDAL',
|
||||
'ONLY YESTERDAY',
|
||||
]}
|
||||
defaultText="NEW POST"
|
||||
rightIconName="md-apps"
|
||||
/>
|
||||
{filterOptions && (
|
||||
<FilterBar
|
||||
dropdownIconName="md-arrow-dropdown"
|
||||
options={filterOptions}
|
||||
defaultText="NEW POST"
|
||||
rightIconName="md-apps"
|
||||
/>
|
||||
)}
|
||||
<FlatList
|
||||
data={posts}
|
||||
showsVerticalScrollIndicator={false}
|
||||
renderItem={({ item }) => (
|
||||
<PostCard componentId={componentId} content={item} user={user} isLoggedIn />
|
||||
<PostCard
|
||||
componentId={componentId}
|
||||
content={item}
|
||||
user={user}
|
||||
isLoggedIn
|
||||
handleOnUserPress={handleOnUserPress}
|
||||
/>
|
||||
)}
|
||||
keyExtractor={(post, index) => index.toString()}
|
||||
onEndReached={this._loadMore}
|
||||
@ -147,7 +171,19 @@ class FeedView extends Component {
|
||||
onRefresh={() => this._handleOnRefreshPosts()}
|
||||
onEndThreshold={0}
|
||||
initialNumToRender={10}
|
||||
ListFooterComponent={this.renderFooter}
|
||||
ListFooterComponent={this._renderFooter}
|
||||
/>
|
||||
</Fragment>
|
||||
);
|
||||
}
|
||||
|
||||
if (isReady && !posts && posts.length < 1) {
|
||||
return (
|
||||
<Fragment>
|
||||
<NoPost
|
||||
name={user.name}
|
||||
text={"haven't posted anything yet"}
|
||||
defaultText="Login to see!"
|
||||
/>
|
||||
</Fragment>
|
||||
);
|
||||
@ -166,4 +202,4 @@ class FeedView extends Component {
|
||||
}
|
||||
}
|
||||
|
||||
export default FeedView;
|
||||
export default PostsView;
|
||||
|
@ -1,6 +1,6 @@
|
||||
import React, { Component, Fragment } from 'react';
|
||||
import {
|
||||
View, Image, Text, TouchableOpacity,
|
||||
View, Image, Text, TouchableOpacity, Dimensions,
|
||||
} from 'react-native';
|
||||
import { DropdownButton } from '../../dropdownButton';
|
||||
|
||||
@ -15,6 +15,8 @@ import { IconButton } from '../../iconButton';
|
||||
// eslint-disable-next-line
|
||||
import styles from './profileSummaryStyles';
|
||||
|
||||
const DEVICE_WIDTH = Dimensions.get('window').width;
|
||||
|
||||
class ProfileSummaryView extends Component {
|
||||
/* Props
|
||||
* ------------------------------------------------
|
||||
@ -49,9 +51,20 @@ class ProfileSummaryView extends Component {
|
||||
const votingPowerText = `Voting power: ${percentVP}% • Full in ${hoursVP} hours`;
|
||||
const rcsPowerText = `RCs: ${percentRC}% • Full in ${hoursRC} hours`;
|
||||
|
||||
/* eslint-disable */
|
||||
const rowLength = location
|
||||
? location.length
|
||||
: null + link
|
||||
? link.length
|
||||
: null + date
|
||||
? date.length
|
||||
: null;
|
||||
|
||||
const isColumn = rowLength && DEVICE_WIDTH / rowLength <= 15;
|
||||
|
||||
return (
|
||||
<Fragment>
|
||||
<View style={styles.textWithIconWrapper}>
|
||||
<View style={[isColumn ? styles.textWithIconWrapperColumn : styles.textWithIconWrapper]}>
|
||||
<TextWithIcon text={location} iconName="md-navigate" />
|
||||
<TextWithIcon isClickable text={link} iconName="md-globe" />
|
||||
<TextWithIcon text={date} iconName="md-calendar" />
|
||||
|
@ -7,7 +7,7 @@ import { SideMenuView } from '..';
|
||||
|
||||
/*
|
||||
* Props Name Description
|
||||
*@props --> props name here description here
|
||||
*@props --> props name navigation coming from react-navigation
|
||||
*
|
||||
*/
|
||||
|
||||
|
@ -59,10 +59,10 @@ export default EStyleSheet.create({
|
||||
},
|
||||
buttonText: {
|
||||
fontSize: 18,
|
||||
fontFamily: 'Gill Sans',
|
||||
fontFamily: '$primaryFontFamily',
|
||||
textAlign: 'center',
|
||||
margin: 10,
|
||||
color: '#ffffff',
|
||||
color: '$white',
|
||||
backgroundColor: 'transparent',
|
||||
},
|
||||
});
|
||||
|
@ -28,7 +28,7 @@ class SideMenuView extends Component {
|
||||
|
||||
render() {
|
||||
const { isLoggedIn, userAvatar, navigateToRoute } = this.props;
|
||||
|
||||
// TODO: Change dummy data
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<View style={styles.headerView}>
|
||||
|
@ -4,7 +4,7 @@ import { default as ROUTES } from '../constants/routeNames';
|
||||
|
||||
// Screens
|
||||
import {
|
||||
Editor, Login, PinCode, Splash,
|
||||
Splash, Login, PinCode, SteemConnect, Editor, Profile,
|
||||
} from '../screens';
|
||||
|
||||
// Components
|
||||
@ -29,5 +29,8 @@ export default SwitchNavigator({
|
||||
[ROUTES.DRAWER.MAIN]: mainNavigation,
|
||||
[ROUTES.SCREENS.EDITOR]: { screen: Editor },
|
||||
[ROUTES.SCREENS.LOGIN]: { screen: Login },
|
||||
[ROUTES.SCREENS.PINCODE]: { screen: PinCode },
|
||||
[ROUTES.SCREENS.PROFILE]: { screen: Profile },
|
||||
[ROUTES.SCREENS.SPLASH]: { screen: Splash },
|
||||
[ROUTES.SCREENS.STEEM_CONNECT]: { screen: SteemConnect },
|
||||
});
|
||||
|
@ -7,7 +7,9 @@ export default {
|
||||
HOME: `Home${SCREEN_SUFFIX}`,
|
||||
LOGIN: `Login${SCREEN_SUFFIX}`,
|
||||
PINCODE: `PinCode${SCREEN_SUFFIX}`,
|
||||
PROFILE: `Profile${SCREEN_SUFFIX}`,
|
||||
SPLASH: `Splash${SCREEN_SUFFIX}`,
|
||||
STEEM_CONNECT: `SteemConnect${SCREEN_SUFFIX}`,
|
||||
},
|
||||
DRAWER: {
|
||||
MAIN: `Main${DRAWER_SUFFIX}`,
|
||||
|
@ -36,6 +36,11 @@ const authMenuItems = [
|
||||
route: 'Settings',
|
||||
icon: 'gear',
|
||||
},
|
||||
{
|
||||
name: 'LoginTest',
|
||||
route: ROUTES.SCREENS.LOGIN,
|
||||
icon: 'user-o',
|
||||
},
|
||||
];
|
||||
|
||||
const noAuthMenuItems = [
|
||||
|
@ -5,6 +5,8 @@ import {
|
||||
setAuthStatus,
|
||||
getUserDataWithUsername,
|
||||
updateUserData,
|
||||
setPinCode,
|
||||
getPinCode,
|
||||
} from '../../realm/realm';
|
||||
import { encryptKey, decryptKey } from '../../utils/crypto';
|
||||
import steemConnect from './steemConnectAPI';
|
||||
@ -13,7 +15,10 @@ export const Login = (username, password) => {
|
||||
let publicKeys;
|
||||
let privateKeys;
|
||||
const resultKeys = {
|
||||
active: null, memo: null, owner: null, posting: null,
|
||||
active: null,
|
||||
memo: null,
|
||||
owner: null,
|
||||
posting: null,
|
||||
};
|
||||
let loginFlag = false;
|
||||
|
||||
@ -21,7 +26,9 @@ export const Login = (username, password) => {
|
||||
// Get user account data from STEEM Blockchain
|
||||
getAccount(username)
|
||||
.then((result) => {
|
||||
if (result.length < 1) {
|
||||
if (isLoggedInUser(username)) {
|
||||
reject(new Error('You are already logged in, please try to add another account'));
|
||||
} else if (result.length < 1) {
|
||||
reject(new Error('Invalid credentails, please check and try again'));
|
||||
}
|
||||
|
||||
@ -75,20 +82,73 @@ export const Login = (username, password) => {
|
||||
});
|
||||
};
|
||||
|
||||
export const loginWithSC2 = async (accessToken) => {
|
||||
await steemConnect.setAccessToken(accessToken);
|
||||
const account = await steemConnect.me();
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
const userData = {
|
||||
username: account.account.name,
|
||||
authType: 'steemConnect',
|
||||
masterKey: '',
|
||||
postingKey: '',
|
||||
activeKey: '',
|
||||
memoKey: '',
|
||||
accessToken: '',
|
||||
};
|
||||
|
||||
const authData = {
|
||||
isLoggedIn: true,
|
||||
};
|
||||
|
||||
if (isLoggedInUser(account.account.name)) {
|
||||
reject(new Error('You are already logged in, please try to add another account'));
|
||||
}
|
||||
|
||||
setAuthStatus(authData)
|
||||
.then(() => {
|
||||
setUserData(userData)
|
||||
.then(() => {
|
||||
resolve({ ...account.account, accessToken });
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
});
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
export const setUserDataWithPinCode = data => new Promise((resolve, reject) => {
|
||||
let updatedUserData;
|
||||
const result = getUserDataWithUsername(data.username);
|
||||
const userData = result[0];
|
||||
|
||||
const privateKeys = getPrivateKeys(userData.username, data.password);
|
||||
|
||||
const updatedUserData = {
|
||||
username: userData.username,
|
||||
authType: 'masterKey',
|
||||
masterKey: encryptKey(data.password, data.pinCode),
|
||||
postingKey: encryptKey(privateKeys.posting.toString(), data.pinCode),
|
||||
activeKey: encryptKey(privateKeys.active.toString(), data.pinCode),
|
||||
memoKey: encryptKey(privateKeys.memo.toString(), data.pinCode),
|
||||
};
|
||||
if (userData.authType === 'masterKey') {
|
||||
updatedUserData = {
|
||||
username: userData.username,
|
||||
authType: 'masterKey',
|
||||
masterKey: encryptKey(data.password, data.pinCode),
|
||||
postingKey: encryptKey(privateKeys.posting.toString(), data.pinCode),
|
||||
activeKey: encryptKey(privateKeys.active.toString(), data.pinCode),
|
||||
memoKey: encryptKey(privateKeys.memo.toString(), data.pinCode),
|
||||
};
|
||||
} else if (userData.authType === 'steemConnect') {
|
||||
updatedUserData = {
|
||||
username: userData.name,
|
||||
authType: 'steemConnect',
|
||||
accessToken: encryptKey(data.accessToken, data.pinCode),
|
||||
postingKey: '',
|
||||
masterKey: '',
|
||||
activeKey: '',
|
||||
memoKey: '',
|
||||
};
|
||||
}
|
||||
|
||||
updateUserData(updatedUserData)
|
||||
.then(() => {
|
||||
@ -98,7 +158,14 @@ export const setUserDataWithPinCode = data => new Promise((resolve, reject) => {
|
||||
|
||||
setAuthStatus(authData)
|
||||
.then(() => {
|
||||
resolve();
|
||||
const encriptedPinCode = encryptKey(data.pinCode, 'pin-code');
|
||||
setPinCode(encriptedPinCode)
|
||||
.then(() => {
|
||||
resolve();
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
});
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
@ -110,27 +177,41 @@ export const setUserDataWithPinCode = data => new Promise((resolve, reject) => {
|
||||
resolve();
|
||||
});
|
||||
|
||||
export const verifyPinCode = data => new Promise((resolve, reject) => {
|
||||
export const verifyPinCode = async (data) => {
|
||||
const result = getUserDataWithUsername(data.username);
|
||||
const userData = result[0];
|
||||
const masterKey = decryptKey(userData.masterKey, data.pinCode);
|
||||
if (masterKey === data.password) {
|
||||
const authData = {
|
||||
isLoggedIn: true,
|
||||
};
|
||||
|
||||
setAuthStatus(authData)
|
||||
.then(() => {
|
||||
resolve();
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(new Error('Invalid pin code, please check and try again'));
|
||||
});
|
||||
} else {
|
||||
reject(new Error('Invalid pin code, please check and try again'));
|
||||
reject();
|
||||
let loginFlag = false;
|
||||
if (userData.masterKey || userData.accessToken) {
|
||||
const masterKey = decryptKey(userData.masterKey, data.pinCode);
|
||||
const accessToken = decryptKey(userData.accessToken, data.pinCode);
|
||||
if (masterKey === data.password || (data.accessToken && accessToken === data.accessToken)) {
|
||||
loginFlag = true;
|
||||
}
|
||||
} else if (data.accessToken) {
|
||||
const encriptedPinCode = await getPinCode();
|
||||
const pinCode = decryptKey(encriptedPinCode, 'pin-code');
|
||||
if (pinCode == data.pinCode) {
|
||||
loginFlag = true;
|
||||
}
|
||||
}
|
||||
});
|
||||
return new Promise((resolve, reject) => {
|
||||
if (loginFlag) {
|
||||
const authData = {
|
||||
isLoggedIn: true,
|
||||
};
|
||||
setAuthStatus(authData)
|
||||
.then(() => {
|
||||
resolve();
|
||||
})
|
||||
.catch((error) => {
|
||||
// TODO: create function for throw error
|
||||
reject(new Error('Unknown error, please contact to eSteem.'));
|
||||
});
|
||||
} else {
|
||||
reject(new Error('Invalid pin code, please check and try again'));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
const getPrivateKeys = (username, password) => ({
|
||||
active: dsteem.PrivateKey.fromLogin(username, password, 'active'),
|
||||
@ -138,39 +219,11 @@ const getPrivateKeys = (username, password) => ({
|
||||
owner: dsteem.PrivateKey.fromLogin(username, password, 'owner'),
|
||||
posting: dsteem.PrivateKey.fromLogin(username, password, 'posting'),
|
||||
});
|
||||
export const loginWithSC2 = async (access_token, pinCode) => {
|
||||
let account;
|
||||
|
||||
await steemConnect.setAccessToken(access_token);
|
||||
account = await steemConnect.me();
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
const userData = {
|
||||
username: account.name,
|
||||
authType: 'steemConnect',
|
||||
accessToken: encryptKey(access_token, pinCode),
|
||||
postingKey: '',
|
||||
masterKey: '',
|
||||
activeKey: '',
|
||||
memoKey: '',
|
||||
};
|
||||
|
||||
const authData = {
|
||||
isLoggedIn: true,
|
||||
};
|
||||
|
||||
setAuthStatus(authData)
|
||||
.then(() => {
|
||||
setUserData(userData)
|
||||
.then(() => {
|
||||
resolve(true);
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
});
|
||||
})
|
||||
.catch((error) => {
|
||||
reject(error);
|
||||
});
|
||||
});
|
||||
const isLoggedInUser = (username) => {
|
||||
const result = getUserDataWithUsername(username);
|
||||
if (result.length > 0) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
};
|
||||
|
@ -21,10 +21,11 @@ const authSchema = {
|
||||
name: AUTH_SCHEMA,
|
||||
properties: {
|
||||
isLoggedIn: { type: 'bool', default: false },
|
||||
pinCode: { type: 'string' },
|
||||
},
|
||||
};
|
||||
|
||||
const realm = new Realm({ schema: [userSchema, authSchema] });
|
||||
const realm = new Realm({ path: 'esteem.realm', schema: [userSchema, authSchema] });
|
||||
|
||||
// TODO: This is getting ALL user data, we should change this method with getUserDataWithUsername
|
||||
export const getUserData = () => new Promise((resolve, reject) => {
|
||||
@ -38,9 +39,7 @@ export const getUserData = () => new Promise((resolve, reject) => {
|
||||
|
||||
export const getUserDataWithUsername = (username) => {
|
||||
try {
|
||||
const user = Array.from(
|
||||
realm.objects(USER_SCHEMA).filtered('username = $0', username),
|
||||
);
|
||||
const user = Array.from(realm.objects(USER_SCHEMA).filtered('username = $0', username));
|
||||
return user;
|
||||
} catch (error) {
|
||||
return error;
|
||||
@ -66,9 +65,7 @@ export const setUserData = userData => new Promise((resolve, reject) => {
|
||||
|
||||
export const updateUserData = userData => new Promise((resolve, reject) => {
|
||||
try {
|
||||
const account = realm
|
||||
.objects(USER_SCHEMA)
|
||||
.filtered('username = $0', userData.username);
|
||||
const account = realm.objects(USER_SCHEMA).filtered('username = $0', userData.username);
|
||||
|
||||
if (Array.from(account).length > 0) {
|
||||
realm.write(() => {
|
||||
@ -118,12 +115,42 @@ export const getAuthStatus = () => new Promise((resolve, reject) => {
|
||||
export const setAuthStatus = authStatus => new Promise((resolve, reject) => {
|
||||
try {
|
||||
const auth = realm.objects(AUTH_SCHEMA);
|
||||
const test = Array.from(auth);
|
||||
const test1 = Array.from(auth).length;
|
||||
realm.write(() => {
|
||||
realm.delete(auth);
|
||||
realm.create(AUTH_SCHEMA, authStatus);
|
||||
resolve(authStatus);
|
||||
if (Array.from(auth).length > 0) {
|
||||
auth[0].isLoggedIn = authStatus.isLoggedIn;
|
||||
resolve(auth[0]);
|
||||
} else {
|
||||
realm.create(AUTH_SCHEMA, { ...authStatus, pinCode: '' });
|
||||
resolve(authStatus);
|
||||
}
|
||||
});
|
||||
} catch (error) {
|
||||
reject(error);
|
||||
}
|
||||
});
|
||||
|
||||
export const setPinCode = pinCode => new Promise((resolve, reject) => {
|
||||
try {
|
||||
const auth = realm.objects(AUTH_SCHEMA);
|
||||
|
||||
realm.write(() => {
|
||||
auth[0].pinCode = pinCode;
|
||||
resolve(auth[0]);
|
||||
});
|
||||
} catch (error) {
|
||||
reject(error);
|
||||
}
|
||||
});
|
||||
|
||||
export const getPinCode = () => new Promise((resolve, reject) => {
|
||||
try {
|
||||
const auth = realm.objects(AUTH_SCHEMA);
|
||||
if (auth[0]) {
|
||||
resolve(auth[0].pinCode);
|
||||
}
|
||||
} catch (error) {
|
||||
reject(error);
|
||||
}
|
||||
});
|
||||
|
@ -18,6 +18,11 @@ export const fetchAccountFromSteem = (username, password) => (dispatch) => {
|
||||
.catch(err => dispatch({ type: FETCH_ACCOUNT_FAIL, payload: err }));
|
||||
};
|
||||
|
||||
export const addPassiveAccount = data => ({
|
||||
type: ADD_NEW_ACCOUNT,
|
||||
payload: { isActive: false, ...data },
|
||||
});
|
||||
|
||||
export const addNewAccount = data => ({
|
||||
type: ADD_NEW_ACCOUNT,
|
||||
payload: data,
|
||||
@ -32,3 +37,8 @@ export const removeAccountData = data => ({
|
||||
type: REMOVE_ACCOUNT_DATA,
|
||||
payload: data,
|
||||
});
|
||||
|
||||
export const failedAccount = data => ({
|
||||
type: FETCH_ACCOUNT_FAIL,
|
||||
payload: data,
|
||||
});
|
||||
|
9
src/redux/actions/applicationActions.js
Normal file
9
src/redux/actions/applicationActions.js
Normal file
@ -0,0 +1,9 @@
|
||||
import { LOGIN, LOGOUT } from '../constants/constants';
|
||||
|
||||
export const login = () => ({
|
||||
type: LOGIN,
|
||||
});
|
||||
|
||||
export const logout = () => ({
|
||||
type: LOGOUT,
|
||||
});
|
@ -3,6 +3,7 @@ export const FETCH_USER_SUCCESS = 'FETCH_USER_SUCCESS';
|
||||
export const FETCH_USER_FAIL = 'FETCH_USER_FAIL';
|
||||
export const SET_USER_DATA = 'SET_USER_DATA';
|
||||
|
||||
export const LOGIN = 'LOGIN';
|
||||
export const LOGOUT = 'LOGOUT';
|
||||
export const LOGOUT_SUCCESS = 'LOGOUT_SUCCESS';
|
||||
export const LOGOUT_FAIL = 'LOGOUT_FAIL';
|
||||
|
@ -30,7 +30,7 @@ export default function (state = initialState, action) {
|
||||
...state,
|
||||
isFetching: false,
|
||||
hasError: true,
|
||||
errorMessage: action.err,
|
||||
errorMessage: action.payload,
|
||||
};
|
||||
case ADD_NEW_ACCOUNT:
|
||||
return {
|
||||
|
24
src/redux/reducers/applicationReducer.js
Normal file
24
src/redux/reducers/applicationReducer.js
Normal file
@ -0,0 +1,24 @@
|
||||
import { LOGIN, LOGOUT } from '../constants/constants';
|
||||
|
||||
const initialState = {
|
||||
isLoggedIn: false, // Has any logged in user.
|
||||
loading: false, // It is lock to all screen and shows loading animation.
|
||||
};
|
||||
|
||||
export default function (state = initialState, action) {
|
||||
switch (action.type) {
|
||||
case LOGIN:
|
||||
return {
|
||||
...state,
|
||||
isLoggedIn: true,
|
||||
};
|
||||
case LOGOUT:
|
||||
return {
|
||||
...state,
|
||||
isLoggedIn: false,
|
||||
};
|
||||
|
||||
default:
|
||||
return state;
|
||||
}
|
||||
}
|
@ -1,8 +1,10 @@
|
||||
import { combineReducers } from 'redux';
|
||||
import accountReducer from './accountReducer';
|
||||
import applicationReducer from './applicationReducer';
|
||||
import nav from './nav';
|
||||
|
||||
export default combineReducers({
|
||||
account: accountReducer,
|
||||
application: applicationReducer,
|
||||
nav,
|
||||
});
|
||||
|
@ -78,7 +78,7 @@ export default class HomeScreen extends PureComponent {
|
||||
const { componentId } = this.props;
|
||||
return (
|
||||
<Fragment>
|
||||
<Header />
|
||||
<Header userName={user.name} reputation={user && user.reputation} />
|
||||
<View style={styles.root} key="overlay">
|
||||
<ScrollableTabView
|
||||
style={styles.tabView}
|
||||
@ -96,6 +96,14 @@ export default class HomeScreen extends PureComponent {
|
||||
<View tabLabel="Feed" style={styles.tabbarItem}>
|
||||
{isLoggedIn ? (
|
||||
<Posts
|
||||
filterOptions={[
|
||||
'NEW POSTS',
|
||||
'VOTES',
|
||||
'REPLIES',
|
||||
'MENTIONS',
|
||||
'FOLLOWS',
|
||||
'REBLOGS',
|
||||
]}
|
||||
isLoginMust
|
||||
getFor="feed"
|
||||
tag={user.name}
|
||||
@ -108,10 +116,17 @@ export default class HomeScreen extends PureComponent {
|
||||
)}
|
||||
</View>
|
||||
<View tabLabel="Hot" style={styles.tabbarItem}>
|
||||
<Posts getFor="hot" user={user} isLoggedIn={isLoggedIn} componentId={componentId} />
|
||||
<Posts
|
||||
filterOptions={['NEW POSTS', 'VOTES', 'REPLIES', 'MENTIONS', 'FOLLOWS', 'REBLOGS']}
|
||||
getFor="hot"
|
||||
user={user}
|
||||
isLoggedIn={isLoggedIn}
|
||||
componentId={componentId}
|
||||
/>
|
||||
</View>
|
||||
<View tabLabel="Popular" style={styles.tabbarItem}>
|
||||
<Posts
|
||||
filterOptions={['NEW POSTS', 'VOTES', 'REPLIES', 'MENTIONS', 'FOLLOWS', 'REBLOGS']}
|
||||
getFor="trending"
|
||||
user={user}
|
||||
isLoggedIn={isLoggedIn}
|
||||
|
@ -4,6 +4,7 @@ import { Editor } from './editor';
|
||||
import { Home } from './home';
|
||||
import { Login } from './login';
|
||||
import { Notification } from './notification';
|
||||
import SteemConnect from './steem-connect/steemConnect';
|
||||
import { Profile } from './profile';
|
||||
|
||||
// import Author from './authorProfile';
|
||||
@ -25,6 +26,7 @@ export {
|
||||
Notification,
|
||||
PinCode,
|
||||
Profile,
|
||||
SteemConnect,
|
||||
Splash,
|
||||
// Author,
|
||||
// SideMenu,
|
||||
|
@ -1,11 +1,15 @@
|
||||
import React, { Component } from 'react';
|
||||
import { View, Linking, StatusBar } from 'react-native';
|
||||
import {
|
||||
View, Linking, StatusBar, Platform, Alert,
|
||||
} from 'react-native';
|
||||
import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view';
|
||||
import ScrollableTabView from '@esteemapp/react-native-scrollable-tab-view';
|
||||
|
||||
// Actions
|
||||
import { addNewAccount } from '../../../redux/actions/accountAction';
|
||||
import { isLoggedIn } from '../../../redux/actions/userActions';
|
||||
import { addPassiveAccount, failedAccount } from '../../../redux/actions/accountAction';
|
||||
import {
|
||||
login as loginAction,
|
||||
} from '../../../redux/actions/applicationActions';
|
||||
|
||||
// Internal Components
|
||||
import { FormInput } from '../../../components/formInput';
|
||||
@ -46,13 +50,15 @@ class LoginScreen extends Component {
|
||||
Login(username, password)
|
||||
.then((result) => {
|
||||
if (result) {
|
||||
dispatch(addNewAccount(result));
|
||||
dispatch(isLoggedIn(true));
|
||||
dispatch(addPassiveAccount(result));
|
||||
dispatch(loginAction());
|
||||
navigation.navigate(ROUTES.SCREENS.PINCODE);
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
dispatch(isLoggedIn(false));
|
||||
.catch((err) => {
|
||||
// TODO: Change with global error handling
|
||||
Alert.alert('Error', err.message);
|
||||
dispatch(failedAccount(err.message));
|
||||
this.setState({ isLoading: false });
|
||||
});
|
||||
};
|
||||
@ -74,19 +80,8 @@ class LoginScreen extends Component {
|
||||
};
|
||||
|
||||
_loginwithSc2 = () => {
|
||||
// Navigation.push(this.props.componentId, {
|
||||
// component: {
|
||||
// name: 'navigation.eSteem.SteemConnect',
|
||||
// passProps: {},
|
||||
// options: {
|
||||
// topBar: {
|
||||
// title: {
|
||||
// text: 'Login via SC2',
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// });
|
||||
const { navigation } = this.props;
|
||||
navigation.navigate(ROUTES.SCREENS.STEEM_CONNECT);
|
||||
};
|
||||
|
||||
render() {
|
||||
@ -104,24 +99,26 @@ class LoginScreen extends Component {
|
||||
description="To get all the benefits using eSteem"
|
||||
onPress={() => this._handleSignUp()}
|
||||
/>
|
||||
<KeyboardAwareScrollView
|
||||
onKeyboardWillShow={() => this.setState({ keyboardIsOpen: true })}
|
||||
onKeyboardWillHide={() => this.setState({ keyboardIsOpen: false })}
|
||||
<ScrollableTabView
|
||||
locked={isLoading}
|
||||
style={styles.tabView}
|
||||
renderTabBar={() => (
|
||||
<TabBar
|
||||
style={styles.tabbar}
|
||||
tabUnderlineDefaultWidth={100} // default containerWidth / (numberOfTabs * 4)
|
||||
tabUnderlineScaleX={2} // default 3
|
||||
activeColor="#357ce6"
|
||||
inactiveColor="#222"
|
||||
/>
|
||||
)}
|
||||
>
|
||||
<ScrollableTabView
|
||||
locked={isLoading}
|
||||
style={styles.tabView}
|
||||
renderTabBar={() => (
|
||||
<TabBar
|
||||
style={styles.tabbar}
|
||||
tabUnderlineDefaultWidth={100} // default containerWidth / (numberOfTabs * 4)
|
||||
tabUnderlineScaleX={2} // default 3
|
||||
activeColor="#357ce6"
|
||||
inactiveColor="#222"
|
||||
/>
|
||||
)}
|
||||
>
|
||||
<View tabLabel="Sign in" style={styles.tabbarItem}>
|
||||
<View tabLabel="Sign in" style={styles.tabbarItem}>
|
||||
<KeyboardAwareScrollView
|
||||
onKeyboardWillShow={() => this.setState({ keyboardIsOpen: true })}
|
||||
onKeyboardWillHide={() => this.setState({ keyboardIsOpen: false })}
|
||||
enableAutoAutomaticScroll={Platform.OS === 'ios'}
|
||||
contentContainerStyle={{ flexGrow: 1 }}
|
||||
>
|
||||
<FormInput
|
||||
rightIconName="md-at"
|
||||
leftIconName="md-close-circle"
|
||||
@ -148,35 +145,36 @@ class LoginScreen extends Component {
|
||||
removed upon logout!"
|
||||
iconName="ios-information-circle-outline"
|
||||
/>
|
||||
<View style={styles.footerButtons}>
|
||||
<TextButton onPress={() => navigation.navigate(ROUTES.DRAWER.MAIN)} text="cancel" />
|
||||
</View>
|
||||
<MainButton
|
||||
wrapperStyle={styles.mainButtonWrapper}
|
||||
onPress={this._handleOnPressLogin}
|
||||
iconName="md-person"
|
||||
iconColor="white"
|
||||
text="LOGIN"
|
||||
isDisable={!isUsernameValid || password.length < 2 || username.length < 2}
|
||||
isLoading={isLoading}
|
||||
/>
|
||||
</KeyboardAwareScrollView>
|
||||
|
||||
<View style={styles.footerButtons}>
|
||||
<TextButton onPress={() => navigation.navigate(ROUTES.DRAWER.MAIN)} text="cancel" />
|
||||
</View>
|
||||
<View tabLabel="SteemConnect" style={styles.steemConnectTab}>
|
||||
<InformationArea
|
||||
description="If you don't want to keep your password encrypted and saved on your device, you can use Steemconnect."
|
||||
iconName="ios-information-circle-outline"
|
||||
/>
|
||||
<MainButton
|
||||
wrapperStyle={styles.mainButtonWrapper}
|
||||
onPress={() => this._loginwithSc2()}
|
||||
iconName="md-person"
|
||||
source={STEEM_CONNECT_LOGO}
|
||||
text="steem"
|
||||
secondText="connect"
|
||||
/>
|
||||
</View>
|
||||
</ScrollableTabView>
|
||||
</KeyboardAwareScrollView>
|
||||
<MainButton
|
||||
wrapperStyle={styles.mainButtonWrapper}
|
||||
onPress={this._handleOnPressLogin}
|
||||
iconName="md-person"
|
||||
iconColor="white"
|
||||
text="LOGIN"
|
||||
isDisable={!isUsernameValid || password.length < 2 || username.length < 2}
|
||||
isLoading={isLoading}
|
||||
/>
|
||||
</View>
|
||||
<View tabLabel="SteemConnect" style={styles.steemConnectTab}>
|
||||
<InformationArea
|
||||
description="If you don't want to keep your password encrypted and saved on your device, you can use Steemconnect."
|
||||
iconName="ios-information-circle-outline"
|
||||
/>
|
||||
<MainButton
|
||||
wrapperStyle={styles.mainButtonWrapper}
|
||||
onPress={() => this._loginwithSc2()}
|
||||
iconName="md-person"
|
||||
source={STEEM_CONNECT_LOGO}
|
||||
text="steem"
|
||||
secondText="connect"
|
||||
/>
|
||||
</View>
|
||||
</ScrollableTabView>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
@ -59,11 +59,12 @@ class PinCodeContainer extends Component {
|
||||
pinCode: pin,
|
||||
password,
|
||||
username: name,
|
||||
accessToken: navigation.getParam('accessToken', ''),
|
||||
};
|
||||
verifyPinCode(pinData)
|
||||
.then(() => {
|
||||
// TODO: make global route
|
||||
navigation.navigate(ROUTES.DRAWER.MAIN);
|
||||
resolve();
|
||||
})
|
||||
.catch((err) => {
|
||||
alert(err);
|
||||
|
@ -1,7 +1,5 @@
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Text, TouchableOpacity, Animated, View,
|
||||
} from 'react-native';
|
||||
import { Text, TouchableOpacity, View } from 'react-native';
|
||||
import { Container } from 'native-base';
|
||||
|
||||
import { Logo, NumericKeyboard, PinAnimatedInput } from '../../../components';
|
||||
@ -12,7 +10,6 @@ class PinCodeScreen extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
showPassword: false,
|
||||
pin: '',
|
||||
};
|
||||
}
|
||||
@ -37,6 +34,7 @@ class PinCodeScreen extends Component {
|
||||
this.setState({ pin: newPin });
|
||||
setPinCode(`${pin}${value}`)
|
||||
.then(() => {
|
||||
// TODO: fix unmounted component error
|
||||
this.setState({ pin: '' });
|
||||
})
|
||||
.catch(() => {
|
||||
|
@ -1,47 +1,47 @@
|
||||
import EStyleSheet from "react-native-extended-stylesheet";
|
||||
import EStyleSheet from 'react-native-extended-stylesheet';
|
||||
|
||||
export default EStyleSheet.create({
|
||||
container: {
|
||||
flex: 1,
|
||||
paddingTop: "$deviceHeight / 15",
|
||||
paddingTop: '$deviceHeight / 15',
|
||||
},
|
||||
logoView: {
|
||||
flex: 2,
|
||||
},
|
||||
titleView: {
|
||||
flex: 1,
|
||||
justifyContent: "center",
|
||||
alignItems: "center",
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
},
|
||||
title: {
|
||||
color: "#357ce6",
|
||||
color: '#357ce6',
|
||||
fontSize: 20,
|
||||
fontWeight: "bold",
|
||||
fontWeight: 'bold',
|
||||
},
|
||||
informationView: {
|
||||
flex: 1,
|
||||
alignItems: "center",
|
||||
alignItems: 'center',
|
||||
},
|
||||
animatedView: {
|
||||
flex: 1,
|
||||
alignItems: "center",
|
||||
alignItems: 'center',
|
||||
},
|
||||
numericKeyboardView: {
|
||||
flex: 6,
|
||||
justifyContent: "center",
|
||||
alignItems: "center",
|
||||
alignSelf: "center",
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
alignSelf: 'center',
|
||||
},
|
||||
forgotButtonView: {
|
||||
flex: 2,
|
||||
justifyContent: "center",
|
||||
alignItems: "center",
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
},
|
||||
forgotButtonText: {
|
||||
color: "#788187",
|
||||
color: '#788187',
|
||||
fontSize: 14,
|
||||
marginTop: 25,
|
||||
alignSelf: "center",
|
||||
alignSelf: 'center',
|
||||
marginBottom: 25,
|
||||
},
|
||||
});
|
||||
|
@ -1,16 +1,142 @@
|
||||
import React, { Component } from 'react';
|
||||
import React, { Component, Fragment } from 'react';
|
||||
|
||||
// Components
|
||||
import { ProfileScreen } from '..';
|
||||
|
||||
// Utilitites
|
||||
import {
|
||||
getFollows, getPosts, getUser, getUserComments,
|
||||
} from '../../../providers/steem/dsteem';
|
||||
import { getUserData, getAuthStatus } from '../../../realm/realm';
|
||||
|
||||
class ProfileContainer extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {};
|
||||
this.state = {
|
||||
user: null,
|
||||
posts: [],
|
||||
commments: [],
|
||||
replies: [],
|
||||
about: {},
|
||||
follows: {},
|
||||
isLoggedIn: false,
|
||||
isLoading: false,
|
||||
isReverseHeader: false,
|
||||
isReady: false,
|
||||
};
|
||||
}
|
||||
|
||||
async componentDidMount() {
|
||||
const { navigation } = this.props;
|
||||
const selectedUser = navigation.state && navigation.state.params;
|
||||
|
||||
this._loadProfile(selectedUser);
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps) {
|
||||
const { navigation } = this.props;
|
||||
const isParamsChange = nextProps.navigation.state
|
||||
&& navigation.state
|
||||
&& nextProps.navigation.state.params.username !== navigation.state.params.username;
|
||||
|
||||
if (isParamsChange) {
|
||||
const selectedUser = nextProps.navigation.state && nextProps.navigation.state.params;
|
||||
|
||||
this._loadProfile(selectedUser);
|
||||
}
|
||||
}
|
||||
|
||||
_getComments = async (user) => {
|
||||
await getUserComments({ start_author: user, limit: 10 })
|
||||
.then((result) => {
|
||||
this.setState({
|
||||
isReady: true,
|
||||
commments: result,
|
||||
refreshing: false,
|
||||
isLoading: false,
|
||||
});
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
};
|
||||
|
||||
async _loadProfile(selectedUser = null) {
|
||||
// TODO: use from redux store.
|
||||
let isLoggedIn;
|
||||
let userData;
|
||||
let username;
|
||||
|
||||
await getAuthStatus().then((res) => {
|
||||
isLoggedIn = res;
|
||||
});
|
||||
|
||||
if (selectedUser) {
|
||||
username = selectedUser.username;
|
||||
this.setState({ isReverseHeader: true });
|
||||
} else if (isLoggedIn) {
|
||||
await getUserData().then((res) => {
|
||||
userData = Array.from(res)[0];
|
||||
});
|
||||
|
||||
username = userData.username;
|
||||
}
|
||||
|
||||
let user;
|
||||
let follows;
|
||||
let about;
|
||||
|
||||
await getFollows(username).then((res) => {
|
||||
follows = res;
|
||||
});
|
||||
|
||||
user = await getUser(username);
|
||||
|
||||
about = user.json_metadata && JSON.parse(user.json_metadata);
|
||||
|
||||
this.setState(
|
||||
{
|
||||
user,
|
||||
isLoggedIn,
|
||||
follows,
|
||||
username,
|
||||
about: about && about.profile,
|
||||
},
|
||||
() => {
|
||||
this._getComments(username);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
render() {
|
||||
return <ProfileScreen {...this.props} />;
|
||||
const {
|
||||
about,
|
||||
commments,
|
||||
follows,
|
||||
isReverseHeader,
|
||||
isLoading,
|
||||
isLoggedIn,
|
||||
user,
|
||||
isReady,
|
||||
username,
|
||||
} = this.state;
|
||||
|
||||
return (
|
||||
<Fragment>
|
||||
<ProfileScreen
|
||||
isReady={isReady}
|
||||
about={about}
|
||||
isReverseHeader={isReverseHeader}
|
||||
commments={commments}
|
||||
follows={follows}
|
||||
isLoading={isLoading}
|
||||
isLoggedIn={isLoggedIn}
|
||||
username={username}
|
||||
user={user}
|
||||
{...this.props}
|
||||
/>
|
||||
</Fragment>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2,24 +2,18 @@
|
||||
import React, { Component, Fragment } from 'react';
|
||||
import { FlatList, ActivityIndicator, View } from 'react-native';
|
||||
|
||||
import FastImage from 'react-native-fast-image';
|
||||
// Components
|
||||
import ScrollableTabView from '@esteemapp/react-native-scrollable-tab-view';
|
||||
import Comment from '../../../components/comment/comment';
|
||||
import { CollapsibleCard } from '../../../components/collapsibleCard';
|
||||
import { FilterBar } from '../../../components/filterBar';
|
||||
import { NoPost } from '../../../components/basicUIElements';
|
||||
import { PostCard } from '../../../components/postCard';
|
||||
import { Header } from '../../../components/header';
|
||||
import { NoPost, ProfileSummaryPlaceHolder } from '../../../components/basicUIElements';
|
||||
import { Posts } from '../../../components/posts';
|
||||
import { ProfileSummary } from '../../../components/profileSummary';
|
||||
import { TabBar } from '../../../components/tabBar';
|
||||
import { Wallet } from '../../../components/wallet';
|
||||
import { Header } from '../../../components/header';
|
||||
|
||||
// Utilitites
|
||||
import {
|
||||
getUser, getFollows, getPosts, getUserComments,
|
||||
} from '../../../providers/steem/dsteem';
|
||||
import { getUserData, getAuthStatus } from '../../../realm/realm';
|
||||
import { getFormatedCreatedDate } from '../../../utils/time';
|
||||
|
||||
// Styles
|
||||
@ -28,131 +22,25 @@ import styles from './profileStyles';
|
||||
class ProfileScreen extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
user: [],
|
||||
posts: [],
|
||||
commments: [],
|
||||
replies: [],
|
||||
about: {},
|
||||
follows: {},
|
||||
isLoggedIn: false,
|
||||
isLoading: true,
|
||||
};
|
||||
this.state = {};
|
||||
}
|
||||
|
||||
async componentDidMount() {
|
||||
let isLoggedIn;
|
||||
await getAuthStatus().then((res) => {
|
||||
isLoggedIn = res;
|
||||
});
|
||||
|
||||
if (isLoggedIn) {
|
||||
let user;
|
||||
let userData;
|
||||
let follows;
|
||||
let about;
|
||||
|
||||
await getUserData().then((res) => {
|
||||
userData = Array.from(res);
|
||||
});
|
||||
|
||||
await getFollows(userData[0].username).then((res) => {
|
||||
follows = res;
|
||||
});
|
||||
|
||||
user = await getUser(userData[0].username);
|
||||
// json_metadata: "{}" can be ceme as emty object if the account new!
|
||||
about = user.json_metadata && JSON.parse(user.json_metadata);
|
||||
this.setState(
|
||||
{
|
||||
user,
|
||||
isLoggedIn,
|
||||
follows,
|
||||
about: about && about.profile,
|
||||
},
|
||||
() => {
|
||||
this._getBlog(userData[0].username);
|
||||
this._getComments(userData[0].username);
|
||||
},
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
_renderFooter = () => {
|
||||
if (this.state.isLoading) return null;
|
||||
|
||||
return (
|
||||
<View style={{ marginVertical: 20 }}>
|
||||
<ActivityIndicator animating size="large" />
|
||||
</View>
|
||||
);
|
||||
};
|
||||
|
||||
_getBlog = (user) => {
|
||||
this.setState({ isLoading: true });
|
||||
getPosts('blog', { tag: user, limit: 10 }, user)
|
||||
.then((result) => {
|
||||
this.setState({
|
||||
isReady: true,
|
||||
posts: result,
|
||||
start_author: result[result.length - 1].author,
|
||||
start_permlink: result[result.length - 1].permlink,
|
||||
refreshing: false,
|
||||
isLoading: false,
|
||||
});
|
||||
})
|
||||
.catch((err) => {
|
||||
alert(err);
|
||||
});
|
||||
};
|
||||
|
||||
_getMore = async () => {
|
||||
console.log('get more');
|
||||
await getPosts(
|
||||
'blog',
|
||||
{
|
||||
tag: this.state.user.name,
|
||||
limit: 10,
|
||||
start_author: this.state.start_author,
|
||||
start_permlink: this.state.start_permlink,
|
||||
},
|
||||
this.state.user.name,
|
||||
).then((result) => {
|
||||
console.log(result);
|
||||
const posts = result;
|
||||
posts.shift();
|
||||
this.setState({
|
||||
posts: [...this.state.posts, ...posts],
|
||||
start_author: result[result.length - 1] && result[result.length - 1].author,
|
||||
start_permlink: result[result.length - 1] && result[result.length - 1].permlink,
|
||||
isLoading: false,
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
_getComments = async (user) => {
|
||||
await getUserComments({ start_author: user, limit: 10 })
|
||||
.then((result) => {
|
||||
this.setState({
|
||||
isReady: true,
|
||||
commments: result,
|
||||
refreshing: false,
|
||||
isLoading: false,
|
||||
});
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
};
|
||||
|
||||
_getPostRenderItem = () => {};
|
||||
|
||||
render() {
|
||||
const {
|
||||
user, follows, posts, commments, isLoggedIn, isLoading, about,
|
||||
} = this.state;
|
||||
about,
|
||||
commments,
|
||||
follows,
|
||||
isLoading,
|
||||
isLoggedIn,
|
||||
isReverseHeader,
|
||||
user,
|
||||
isReady,
|
||||
username,
|
||||
} = this.props;
|
||||
let _about;
|
||||
let avatar;
|
||||
let coverImage;
|
||||
let name;
|
||||
let location;
|
||||
let website;
|
||||
let votingPower;
|
||||
@ -166,36 +54,50 @@ class ProfileScreen extends Component {
|
||||
fullInHourVP = Math.ceil((100 - votingPower) * 0.833333);
|
||||
fullInHourRC = Math.ceil((100 - resourceCredits) * 0.833333);
|
||||
}
|
||||
console.log(user);
|
||||
|
||||
if (about) {
|
||||
_about = about.about;
|
||||
coverImage = about.cover_image;
|
||||
avatar = about.profile_image;
|
||||
location = about.location;
|
||||
website = about.website;
|
||||
name = about.name;
|
||||
}
|
||||
return (
|
||||
<Fragment>
|
||||
<Header />
|
||||
<Header
|
||||
name={name}
|
||||
avatar={avatar}
|
||||
isReverse={isReverseHeader}
|
||||
userName={user && user.name}
|
||||
reputation={user && user.reputation}
|
||||
/>
|
||||
<View style={styles.container}>
|
||||
<CollapsibleCard
|
||||
title={_about}
|
||||
defaultTitle="Profile details"
|
||||
expanded={!isLoggedIn}
|
||||
locked={!isLoggedIn}
|
||||
>
|
||||
<ProfileSummary
|
||||
percentVP={votingPower}
|
||||
percentRC={resourceCredits}
|
||||
hoursVP={fullInHourVP}
|
||||
hoursRC={fullInHourRC}
|
||||
location={location}
|
||||
link={website}
|
||||
date={getFormatedCreatedDate(user && user.created)}
|
||||
followerCount={follows.follower_count}
|
||||
followingCount={follows.following_count}
|
||||
coverImage={coverImage}
|
||||
/>
|
||||
</CollapsibleCard>
|
||||
{!isReady ? (
|
||||
<ProfileSummaryPlaceHolder />
|
||||
) : (
|
||||
<CollapsibleCard
|
||||
title={_about}
|
||||
isTitleCenter
|
||||
defaultTitle="Profile details"
|
||||
expanded={isLoggedIn}
|
||||
locked={!isLoggedIn}
|
||||
>
|
||||
<ProfileSummary
|
||||
percentVP={votingPower}
|
||||
percentRC={resourceCredits}
|
||||
hoursVP={fullInHourVP}
|
||||
hoursRC={fullInHourRC}
|
||||
location={location}
|
||||
link={website}
|
||||
date={getFormatedCreatedDate(user && user.created)}
|
||||
followerCount={follows.follower_count}
|
||||
followingCount={follows.following_count}
|
||||
coverImage={coverImage}
|
||||
/>
|
||||
</CollapsibleCard>
|
||||
)}
|
||||
|
||||
<ScrollableTabView
|
||||
style={styles.tabView}
|
||||
@ -210,40 +112,21 @@ class ProfileScreen extends Component {
|
||||
)}
|
||||
>
|
||||
<View tabLabel="Post" style={styles.postTabBar}>
|
||||
<FilterBar
|
||||
isHide={!isLoggedIn}
|
||||
dropdownIconName="md-arrow-dropdown"
|
||||
options={['NEW POSTS', 'VOTES', 'REPLIES', 'MENTIONS', 'FOLLOWS', 'REBLOGS']}
|
||||
defaultText="ALL NOTIFICATION"
|
||||
onDropdownSelect={this._handleOnDropdownSelect}
|
||||
rightIconName="md-apps"
|
||||
/>
|
||||
{posts && posts.length > 0 ? (
|
||||
<FlatList
|
||||
data={posts}
|
||||
showsVerticalScrollIndicator={false}
|
||||
renderItem={({ item }) => (
|
||||
<PostCard
|
||||
style={{
|
||||
shadowColor: '#f6f6f6',
|
||||
}}
|
||||
content={item}
|
||||
user={user}
|
||||
isLoggedIn
|
||||
/>
|
||||
)}
|
||||
keyExtractor={(post, index) => index.toString()}
|
||||
onEndReached={(info) => {
|
||||
!isLoading && this._getMore();
|
||||
}}
|
||||
onEndThreshold={0}
|
||||
bounces={false}
|
||||
/>
|
||||
) : (
|
||||
<NoPost
|
||||
name={user.name}
|
||||
text={"haven't posted anything yet"}
|
||||
defaultText="Login to see!"
|
||||
{user && (
|
||||
<Posts
|
||||
filterOptions={[
|
||||
'NEW POSTS',
|
||||
'VOTES',
|
||||
'REPLIES',
|
||||
'MENTIONS',
|
||||
'FOLLOWS',
|
||||
'REBLOGS',
|
||||
]}
|
||||
isLoginMust
|
||||
getFor="blog"
|
||||
tag={username}
|
||||
user={user && user}
|
||||
isLoggedIn={isLoggedIn}
|
||||
/>
|
||||
)}
|
||||
</View>
|
||||
@ -259,13 +142,13 @@ class ProfileScreen extends Component {
|
||||
/>
|
||||
) : (
|
||||
<NoPost
|
||||
name={user.name}
|
||||
name={username}
|
||||
text="haven't commented anything yet"
|
||||
defaultText="Login to see!"
|
||||
/>
|
||||
)}
|
||||
</View>
|
||||
<View tabLabel={user.balance ? `$${user.balance}` : 'Wallet'}>
|
||||
<View tabLabel={user && user.balance ? `$${user && user.balance}` : 'Wallet'}>
|
||||
<Wallet user={user} />
|
||||
</View>
|
||||
</ScrollableTabView>
|
||||
|
@ -14,7 +14,7 @@ class SplashContainer extends Component {
|
||||
|
||||
_getUserData = () => {
|
||||
const { navigation } = this.props;
|
||||
|
||||
|
||||
getAuthStatus().then((res) => {
|
||||
getUserData().then((response) => {
|
||||
if (response) {
|
||||
|
@ -1,40 +1,53 @@
|
||||
import React, { Component } from 'react';
|
||||
import { View, WebView } from 'react-native';
|
||||
import RNRestart from 'react-native-restart';
|
||||
import { Navigation } from 'react-native-navigation';
|
||||
import { connect } from 'react-redux';
|
||||
|
||||
import { loginWithSC2 } from '../../providers/steem/auth';
|
||||
import { steemConnectOptions } from './config';
|
||||
import { goToAuthScreens } from '../../navigation';
|
||||
|
||||
export default class SteemConnect extends Component {
|
||||
// Actions
|
||||
import { addPassiveAccount } from '../../redux/actions/accountAction';
|
||||
import { login as loginAction } from '../../redux/actions/applicationActions';
|
||||
|
||||
// Constants
|
||||
import { default as ROUTES } from '../../constants/routeNames';
|
||||
|
||||
class SteemConnect extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {};
|
||||
this.state = {
|
||||
isLoading: false,
|
||||
};
|
||||
}
|
||||
|
||||
onNavigationStateChange(event) {
|
||||
let access_token;
|
||||
let accessToken;
|
||||
const { navigation, dispatch } = this.props;
|
||||
const { isLoading } = this.state;
|
||||
|
||||
if (event.url.indexOf('?access_token=') > -1) {
|
||||
this.webview.stopLoading();
|
||||
try {
|
||||
access_token = event.url.match(/\?(?:access_token)\=([\S\s]*?)\&/)[1];
|
||||
accessToken = event.url.match(/\?(?:access_token)\=([\S\s]*?)\&/)[1];
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
// TODO: return
|
||||
}
|
||||
if (!isLoading) {
|
||||
this.setState({ isLoading: true });
|
||||
loginWithSC2(accessToken, 'pinCode')
|
||||
.then((result) => {
|
||||
if (result) {
|
||||
dispatch(addPassiveAccount(result));
|
||||
dispatch(loginAction());
|
||||
navigation.navigate(ROUTES.SCREENS.PINCODE, { accessToken });
|
||||
} else {
|
||||
// TODO: Error alert (Toast Message)
|
||||
}
|
||||
})
|
||||
.catch((error) => {
|
||||
// TODO: return
|
||||
});
|
||||
}
|
||||
|
||||
loginWithSC2(access_token, 'pinCode')
|
||||
.then((result) => {
|
||||
if (result) {
|
||||
// TODO: Handle pinCode and navigate to home page
|
||||
goToAuthScreens();
|
||||
} else {
|
||||
// TODO: Error alert (Toast Message)
|
||||
console.log('loginWithSC2 error');
|
||||
}
|
||||
})
|
||||
.catch((error) => {
|
||||
console.log(error);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@ -58,3 +71,5 @@ export default class SteemConnect extends Component {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default connect()(SteemConnect);
|
||||
|
@ -1,5 +1,5 @@
|
||||
import CryptoJS from 'crypto-js';
|
||||
|
||||
export const encryptKey = (key, pinCode) => CryptoJS.AES.encrypt(key, pinCode).toString();
|
||||
export const encryptKey = (key, data) => CryptoJS.AES.encrypt(key, data).toString();
|
||||
|
||||
export const decryptKey = (key, pinCode) => CryptoJS.AES.decrypt(key, pinCode).toString(CryptoJS.enc.Utf8);
|
||||
export const decryptKey = (key, data) => CryptoJS.AES.decrypt(key, data).toString(CryptoJS.enc.Utf8);
|
||||
|
24
src/utils/user.js
Normal file
24
src/utils/user.js
Normal file
@ -0,0 +1,24 @@
|
||||
export const getReputation = (input) => {
|
||||
if (input === 0) {
|
||||
return 25;
|
||||
}
|
||||
|
||||
if (!input) {
|
||||
return input;
|
||||
}
|
||||
|
||||
let neg = false;
|
||||
|
||||
if (input < 0) neg = true;
|
||||
|
||||
let reputationLevel = Math.log10(Math.abs(input));
|
||||
reputationLevel = Math.max(reputationLevel - 9, 0);
|
||||
|
||||
if (reputationLevel < 0) reputationLevel = 0;
|
||||
|
||||
if (neg) reputationLevel *= -1;
|
||||
|
||||
reputationLevel = reputationLevel * 9 + 25;
|
||||
|
||||
return Math.floor(reputationLevel);
|
||||
};
|
Loading…
Reference in New Issue
Block a user