mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-12-28 07:55:08 +03:00
added emty wallet component
This commit is contained in:
parent
fb7a92563d
commit
f50a2e7b46
@ -55,11 +55,8 @@ class ProfileScreen extends React.Component {
|
||||
};
|
||||
}
|
||||
|
||||
constructor() {
|
||||
super();
|
||||
this.getBlog = this.getBlog.bind(this);
|
||||
this.getMore = this.getMore.bind(this);
|
||||
this.getComments = this.getComments.bind(this);
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
user: [],
|
||||
posts: [],
|
||||
@ -102,8 +99,8 @@ class ProfileScreen extends React.Component {
|
||||
about: about && about.profile,
|
||||
},
|
||||
() => {
|
||||
this.getBlog(userData[0].username);
|
||||
this.getComments(userData[0].username);
|
||||
this._getBlog(userData[0].username);
|
||||
this._getComments(userData[0].username);
|
||||
}
|
||||
);
|
||||
}
|
||||
@ -119,7 +116,7 @@ class ProfileScreen extends React.Component {
|
||||
);
|
||||
};
|
||||
|
||||
getBlog = user => {
|
||||
_getBlog = user => {
|
||||
this.setState({ isLoading: true });
|
||||
getPosts("blog", { tag: user, limit: 10 }, user)
|
||||
.then(result => {
|
||||
@ -137,7 +134,7 @@ class ProfileScreen extends React.Component {
|
||||
});
|
||||
};
|
||||
|
||||
getMore = async () => {
|
||||
_getMore = async () => {
|
||||
console.log("get more");
|
||||
await getPosts(
|
||||
"blog",
|
||||
@ -161,7 +158,7 @@ class ProfileScreen extends React.Component {
|
||||
});
|
||||
};
|
||||
|
||||
getComments = async user => {
|
||||
_getComments = async user => {
|
||||
await getUserComments({ start_author: user, limit: 10 })
|
||||
.then(result => {
|
||||
this.setState({
|
||||
@ -252,7 +249,7 @@ class ProfileScreen extends React.Component {
|
||||
keyExtractor={(post, index) => index.toString()}
|
||||
onEndReached={info => {
|
||||
if (!isLoading) {
|
||||
this.getMore();
|
||||
this._getMore();
|
||||
}
|
||||
}}
|
||||
onEndThreshold={0}
|
||||
|
39
src/wallet/container/walletContainer.js
Normal file
39
src/wallet/container/walletContainer.js
Normal file
@ -0,0 +1,39 @@
|
||||
import React, { Component } from "react";
|
||||
//import { connect } from "react-redux";
|
||||
|
||||
// Services and Actions
|
||||
|
||||
// Middleware
|
||||
|
||||
// Constants
|
||||
|
||||
// Utilities
|
||||
|
||||
// Component
|
||||
import { WalletView } from "../";
|
||||
|
||||
/*
|
||||
* Props Name Description Value
|
||||
*@props --> props name here description here Value Type Here
|
||||
*
|
||||
*/
|
||||
|
||||
class WalletContainer extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {};
|
||||
}
|
||||
|
||||
// Component Life Cycle Functions
|
||||
|
||||
// Component Functions
|
||||
|
||||
render() {
|
||||
// eslint-disable-next-line
|
||||
//const {} = this.props;
|
||||
|
||||
return <WalletView {...this.props} />;
|
||||
}
|
||||
}
|
||||
|
||||
export default WalletContainer;
|
5
src/wallet/index.js
Normal file
5
src/wallet/index.js
Normal file
@ -0,0 +1,5 @@
|
||||
import WalletView from "./view/walletView";
|
||||
import Wallet from "./container/walletContainer";
|
||||
|
||||
export { WalletView, Wallet };
|
||||
export default Wallet;
|
0
src/wallet/view/walletStyles.js
Normal file
0
src/wallet/view/walletStyles.js
Normal file
36
src/wallet/view/walletView.js
Normal file
36
src/wallet/view/walletView.js
Normal file
@ -0,0 +1,36 @@
|
||||
import React, { Component } from "react";
|
||||
import {} from "react-native";
|
||||
|
||||
// Constants
|
||||
|
||||
// Components
|
||||
|
||||
// Styles
|
||||
// eslint-disable-next-line
|
||||
import styles from "./_styles";
|
||||
|
||||
class WalletView extends Component {
|
||||
/* Props
|
||||
* ------------------------------------------------
|
||||
* @prop { type } name - Description....
|
||||
*/
|
||||
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {};
|
||||
}
|
||||
|
||||
// Component Life Cycles
|
||||
|
||||
// Component Functions
|
||||
|
||||
render() {
|
||||
// eslint-disable-next-line
|
||||
const {} = this.props;
|
||||
|
||||
// eslint-disable-next-line
|
||||
return <ElementName />;
|
||||
}
|
||||
}
|
||||
|
||||
export default WalletView;
|
Loading…
Reference in New Issue
Block a user