post-0.9.0 fixes
This commit is contained in:
parent
ca8670e23c
commit
88e450eb08
8 changed files with 44 additions and 15 deletions
4
package-lock.json
generated
4
package-lock.json
generated
|
@ -5649,8 +5649,8 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"lbryinc": {
|
"lbryinc": {
|
||||||
"version": "github:lbryio/lbryinc#d250096a6fc5df16be4f82812ecce28d6e558b6e",
|
"version": "github:lbryio/lbryinc#67bb3e215be3f13605c5e3f9f2b0e2fb880724cf",
|
||||||
"from": "github:lbryio/lbryinc#d250096a6fc5df16be4f82812ecce28d6e558b6e",
|
"from": "github:lbryio/lbryinc#67bb3e215be3f13605c5e3f9f2b0e2fb880724cf",
|
||||||
"requires": {
|
"requires": {
|
||||||
"reselect": "^3.0.0"
|
"reselect": "^3.0.0"
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
"@expo/vector-icons": "^8.1.0",
|
"@expo/vector-icons": "^8.1.0",
|
||||||
"gfycat-style-urls": "^1.0.3",
|
"gfycat-style-urls": "^1.0.3",
|
||||||
"lbry-redux": "lbryio/lbry-redux#d44cd9ca56dee784dba42c0cc13061ae75cbd46c",
|
"lbry-redux": "lbryio/lbry-redux#d44cd9ca56dee784dba42c0cc13061ae75cbd46c",
|
||||||
"lbryinc": "lbryio/lbryinc#d250096a6fc5df16be4f82812ecce28d6e558b6e",
|
"lbryinc": "lbryio/lbryinc#67bb3e215be3f13605c5e3f9f2b0e2fb880724cf",
|
||||||
"lodash": ">=4.17.11",
|
"lodash": ">=4.17.11",
|
||||||
"merge": ">=1.2.1",
|
"merge": ">=1.2.1",
|
||||||
"moment": "^2.22.1",
|
"moment": "^2.22.1",
|
||||||
|
|
4
src/component/channelRewardsDriver/index.js
Normal file
4
src/component/channelRewardsDriver/index.js
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
import { connect } from 'react-redux';
|
||||||
|
import ChannelRewardsDriver from './view';
|
||||||
|
|
||||||
|
export default connect()(ChannelRewardsDriver);
|
20
src/component/channelRewardsDriver/view.js
Normal file
20
src/component/channelRewardsDriver/view.js
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
import React from 'react';
|
||||||
|
import { Text, TouchableOpacity } from 'react-native';
|
||||||
|
import Colors from 'styles/colors';
|
||||||
|
import Icon from 'react-native-vector-icons/FontAwesome5';
|
||||||
|
import publishStyle from 'styles/publish';
|
||||||
|
|
||||||
|
class ChannelRewardsDriver extends React.PureComponent<Props> {
|
||||||
|
render() {
|
||||||
|
const { navigation } = this.props;
|
||||||
|
|
||||||
|
return (
|
||||||
|
<TouchableOpacity style={publishStyle.rewardDriverCard} onPress={() => navigation.navigate('Rewards')}>
|
||||||
|
<Icon name="award" size={16} style={publishStyle.rewardIcon} />
|
||||||
|
<Text style={publishStyle.rewardDriverText}>Earn some credits to be able to create your channel.</Text>
|
||||||
|
</TouchableOpacity>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ChannelRewardsDriver;
|
|
@ -167,12 +167,14 @@ export default class ChannelSelector extends React.PureComponent {
|
||||||
|
|
||||||
channelExists = name => {
|
channelExists = name => {
|
||||||
const { channels = [] } = this.props;
|
const { channels = [] } = this.props;
|
||||||
for (let channel of channels) {
|
if (channels) {
|
||||||
if (
|
for (let channel of channels) {
|
||||||
name.toLowerCase() === channel.name.toLowerCase() ||
|
if (
|
||||||
`@${name}`.toLowerCase() === channel.name.toLowerCase()
|
name.toLowerCase() === channel.name.toLowerCase() ||
|
||||||
) {
|
`@${name}`.toLowerCase() === channel.name.toLowerCase()
|
||||||
return true;
|
) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import Colors from 'styles/colors';
|
||||||
import Icon from 'react-native-vector-icons/FontAwesome5';
|
import Icon from 'react-native-vector-icons/FontAwesome5';
|
||||||
import publishStyle from 'styles/publish';
|
import publishStyle from 'styles/publish';
|
||||||
|
|
||||||
class PublishRewadsDriver extends React.PureComponent<Props> {
|
class PublishRewardsDriver extends React.PureComponent<Props> {
|
||||||
render() {
|
render() {
|
||||||
const { navigation } = this.props;
|
const { navigation } = this.props;
|
||||||
|
|
||||||
|
@ -17,4 +17,4 @@ class PublishRewadsDriver extends React.PureComponent<Props> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default PublishRewadsDriver;
|
export default PublishRewardsDriver;
|
||||||
|
|
|
@ -17,6 +17,7 @@ import {
|
||||||
import { navigateToUri, uploadImageAsset } from 'utils/helper';
|
import { navigateToUri, uploadImageAsset } from 'utils/helper';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
import ChannelIconItem from 'component/channelIconItem';
|
import ChannelIconItem from 'component/channelIconItem';
|
||||||
|
import ChannelRewardsDriver from 'component/channelRewardsDriver';
|
||||||
import Colors from 'styles/colors';
|
import Colors from 'styles/colors';
|
||||||
import Constants from 'constants'; // eslint-disable-line node/no-deprecated-api
|
import Constants from 'constants'; // eslint-disable-line node/no-deprecated-api
|
||||||
import EmptyStateView from 'component/emptyStateView';
|
import EmptyStateView from 'component/emptyStateView';
|
||||||
|
@ -455,8 +456,8 @@ export default class ChannelCreator extends React.PureComponent {
|
||||||
return { name: tag };
|
return { name: tag };
|
||||||
}),
|
}),
|
||||||
website,
|
website,
|
||||||
cover: coverImageUrl,
|
coverUrl: coverImageUrl,
|
||||||
thumbnail: thumbnailUrl,
|
thumbnailUrl: thumbnailUrl,
|
||||||
};
|
};
|
||||||
|
|
||||||
if (this.state.editMode) {
|
if (this.state.editMode) {
|
||||||
|
@ -728,7 +729,7 @@ export default class ChannelCreator extends React.PureComponent {
|
||||||
};
|
};
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { abandoningClaimIds, fetchingChannels, updatingChannel, channels = [], navigation } = this.props;
|
const { abandoningClaimIds, balance, fetchingChannels, updatingChannel, channels = [], navigation } = this.props;
|
||||||
const {
|
const {
|
||||||
autoStyle,
|
autoStyle,
|
||||||
autoStyles,
|
autoStyles,
|
||||||
|
@ -884,6 +885,7 @@ export default class ChannelCreator extends React.PureComponent {
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
</View>
|
</View>
|
||||||
</View>
|
</View>
|
||||||
|
{balance < 0.1 && <ChannelRewardsDriver navigation={navigation} />}
|
||||||
|
|
||||||
<View style={channelCreatorStyle.card}>
|
<View style={channelCreatorStyle.card}>
|
||||||
<View style={channelCreatorStyle.textInputLayout}>
|
<View style={channelCreatorStyle.textInputLayout}>
|
||||||
|
|
|
@ -104,11 +104,12 @@ const channelCreatorStyle = StyleSheet.create({
|
||||||
avatarImageContainer: {
|
avatarImageContainer: {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
left: screenWidth / 2 - 80 / 2,
|
left: screenWidth / 2 - 80 / 2,
|
||||||
bottom: -16,
|
bottom: -8,
|
||||||
width: 80,
|
width: 80,
|
||||||
height: 80,
|
height: 80,
|
||||||
borderRadius: 160,
|
borderRadius: 160,
|
||||||
overflow: 'hidden',
|
overflow: 'hidden',
|
||||||
|
zIndex: 50,
|
||||||
},
|
},
|
||||||
avatarTouchArea: {
|
avatarTouchArea: {
|
||||||
width: 80,
|
width: 80,
|
||||||
|
|
Loading…
Reference in a new issue