diff --git a/.eslintrc.json b/.eslintrc.json index 22a61fa6f..6b7b524e9 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -33,6 +33,7 @@ "react/prop-types": 0, "import/no-named-default": "off", "no-param-reassign": "off", - "no-case-declarations": "off" + "no-case-declarations": "off", + "no-cycle": "off" } } diff --git a/src/components/avatarHeader/avatarHeaderStyles.js b/src/components/avatarHeader/avatarHeaderStyles.js new file mode 100644 index 000000000..1840141d8 --- /dev/null +++ b/src/components/avatarHeader/avatarHeaderStyles.js @@ -0,0 +1,46 @@ +import EStyleSheet from 'react-native-extended-stylesheet'; + +export default EStyleSheet.create({ + headerContainer: { + height: 100, + flexDirection: 'row', + padding: 21, + }, + backIcon: { + color: '$white', + }, + wrapper: { + marginLeft: 16, + flexDirection: 'row', + justifyContent: 'center', + alignItems: 'center', + }, + textWrapper: { + marginLeft: 16, + }, + name: { + color: '$white', + fontSize: 14, + fontWeight: 'bold', + }, + username: { + color: '$white', + fontSize: 12, + marginTop: 4, + }, + addIcon: { + color: '$white', + textAlign: 'center', + }, + addButton: { + backgroundColor: '$iconColor', + width: 20, + height: 20, + borderRadius: 20 / 2, + borderColor: '$white', + borderWidth: 1, + position: 'absolute', + bottom: 0, + left: 45, + }, +}); diff --git a/src/components/avatarHeader/avatarHeaderView.js b/src/components/avatarHeader/avatarHeaderView.js new file mode 100644 index 000000000..7e4f9683c --- /dev/null +++ b/src/components/avatarHeader/avatarHeaderView.js @@ -0,0 +1,61 @@ +import React from 'react'; +import { withNavigation } from 'react-navigation'; +import { View, Text, SafeAreaView } from 'react-native'; +import LinearGradient from 'react-native-linear-gradient'; + +import { UserAvatar } from '../userAvatar'; +import { IconButton } from '../iconButton'; + +// Styles +import styles from './avatarHeaderStyles'; + +const AvatarHeader = ({ + username, + name, + reputation, + navigation, + avatarUrl, + showImageUploadActions, +}) => ( + + + + + + + + + {!!name && {name}} + {`@${username} (${reputation})`} + + + + + +); + +export default withNavigation(AvatarHeader); diff --git a/src/components/avatarHeader/index.js b/src/components/avatarHeader/index.js new file mode 100644 index 000000000..6ea71cf70 --- /dev/null +++ b/src/components/avatarHeader/index.js @@ -0,0 +1,3 @@ +import AvatarHeader from './avatarHeaderView'; + +export { AvatarHeader }; diff --git a/src/components/basicHeader/view/basicHeaderStyles.js b/src/components/basicHeader/view/basicHeaderStyles.js index 374afb299..5d7ab8139 100644 --- a/src/components/basicHeader/view/basicHeaderStyles.js +++ b/src/components/basicHeader/view/basicHeaderStyles.js @@ -19,7 +19,7 @@ export default EStyleSheet.create({ saveIcon: { fontSize: 20, color: '$iconColor', - marginLeft: 15, + width: 50, }, savedIcon: { color: '#a1c982', @@ -36,7 +36,6 @@ export default EStyleSheet.create({ quickTitle: { fontSize: 10, color: '$iconColor', - marginLeft: 24, alignSelf: 'center', }, rightIcon: { diff --git a/src/components/basicHeader/view/basicHeaderView.js b/src/components/basicHeader/view/basicHeaderView.js index 1e310b9c9..0c19f39a7 100644 --- a/src/components/basicHeader/view/basicHeaderView.js +++ b/src/components/basicHeader/view/basicHeaderView.js @@ -100,24 +100,16 @@ class BasicHeaderView extends Component { (isModalHeader ? handleOnPressClose() : handleOnPressBackButton())} disabled={disabled} /> {isHasIcons && !isReply && ( - - {!isDraftSaving ? ( - handleOnSaveButtonPress && handleOnSaveButtonPress()} - /> - ) : ( - - )} - + )} {!isInputVisible && ( @@ -184,11 +176,19 @@ class BasicHeaderView extends Component { {isHasIcons && ( {!isReply && ( - + + {!isDraftSaving ? ( + handleOnSaveButtonPress && handleOnSaveButtonPress()} + /> + ) : ( + + )} + )} { - this.setState({ formInputWidth: '100%' }); - }, 100); - } - componentWillReceiveProps(nextProps) { const { isValid } = this.props; @@ -54,18 +46,15 @@ class FormInputView extends Component { const { onChange } = this.props; this.setState({ value }); - onChange && onChange(value); + if (onChange) onChange(value); }; _handleOnFocus = () => { - const { inputBorderColor } = this.state; - if (inputBorderColor !== '#357ce6') { - this.setState({ inputBorderColor: '#357ce6' }); - } + this.setState({ inputBorderColor: '#357ce6' }); }; render() { - const { inputBorderColor, isValid, value, formInputWidth } = this.state; + const { inputBorderColor, isValid, value } = this.state; const { placeholder, type, @@ -75,6 +64,9 @@ class FormInputView extends Component { rightIconName, secureTextEntry, iconType, + wrapperStyle, + height, + inputStyle, } = this.props; return ( {isFirstImage && value && value.length > 2 ? ( @@ -90,26 +83,30 @@ class FormInputView extends Component { ) : ( - + rightIconName && ( + + ) )} this._handleOnFocus()} + style={inputStyle} + onFocus={() => this.setState({ inputBorderColor: '#357ce6' })} + onBlur={() => this.setState({ inputBorderColor: '#e7e7e7' })} autoCapitalize="none" secureTextEntry={secureTextEntry} + height={height} placeholder={placeholder} editable={isEditable || true} textContentType={type} - onChangeText={val => this._handleOnChange(val)} + onChangeText={this._handleOnChange} value={value} - style={{ width: formInputWidth }} /> diff --git a/src/components/header/container/headerContainer.js b/src/components/header/container/headerContainer.js index f15bf207a..6a8871cac 100644 --- a/src/components/header/container/headerContainer.js +++ b/src/components/header/container/headerContainer.js @@ -1,12 +1,7 @@ import React, { PureComponent } from 'react'; import { withNavigation } from 'react-navigation'; import { connect } from 'react-redux'; - -// Services and Actions - -// Middleware - -// Constants +import { get, has } from 'lodash'; // Component import HeaderView from '../view/headerView'; @@ -30,7 +25,7 @@ class HeaderContainer extends PureComponent { _handleOpenDrawer = () => { const { navigation } = this.props; - if (navigation && navigation.openDrawer && typeof navigation.openDrawer === 'function') { + if (has(navigation, 'openDrawer') && typeof get(navigation, 'openDrawer') === 'function') { navigation.openDrawer(); } }; @@ -52,19 +47,11 @@ class HeaderContainer extends PureComponent { isLoginDone, isDarkTheme, } = this.props; - let displayName; - let username; - let reputation; + const _user = isReverse && selectedUser ? selectedUser : currentAccount; - if (isReverse && selectedUser) { - displayName = selectedUser.display_name; - username = selectedUser.name; - reputation = selectedUser.reputation; - } else if (!isReverse) { - displayName = currentAccount.display_name; - username = currentAccount.name; - reputation = currentAccount.reputation; - } + const displayName = get(_user, 'display_name'); + const username = get(_user, 'name'); + const reputation = get(_user, 'reputation'); return ( ( onPress && onPress()} + onPress={() => !isLoading && onPress && onPress()} underlayColor={backgroundColor || 'white'} disabled={disabled} > - + {!isLoading ? ( + + ) : ( + + )} ); diff --git a/src/components/index.js b/src/components/index.js index f993e074c..a0c250c22 100644 --- a/src/components/index.js +++ b/src/components/index.js @@ -1,33 +1,182 @@ -import { CircularButton, TextButton, IconButton } from './buttons'; +import { AvatarHeader } from './avatarHeader'; +import { BasicHeader } from './basicHeader'; +import { BottomTabBar } from './bottomTabBar'; +import { CheckBox } from './checkbox'; +import { CircularButton, TextButton, SquareButton } from './buttons'; +import { CollapsibleCard } from './collapsibleCard'; +import { ContainerHeader } from './containerHeader'; +import { DateTimePicker } from './dateTimePicker'; +import { DropdownButton } from './dropdownButton'; +import { FilterBar } from './filterBar'; +import { FormatedCurrency } from './formatedElements'; import { FormInput } from './formInput'; +import { Header } from './header'; +import { Icon } from './icon'; +import { IconButton } from './iconButton'; +import { InformationArea } from './informationArea'; +import { InformationBox } from './informationBox'; +import { LoginHeader } from './loginHeader'; +import { MainButton } from './mainButton'; +import { MarkdownEditor } from './markdownEditor'; +import { Modal } from './modal'; +import { NotificationLine } from './notificationLine'; import { NumericKeyboard } from './numericKeyboard'; +import { ParentPost } from './parentPost'; +import { PercentBar } from './percentBar'; import { PinAnimatedInput } from './pinAnimatedInput'; +import { PostCard } from './postCard'; +import { PostDisplay } from './postView'; +import { PostDropdown } from './postDropdown'; +import { PostForm } from './postForm'; +import { PostHeaderDescription, PostBody, Tags } from './postElements'; +import { PostListItem } from './postListItem'; +import { ProfileSummary } from './profileSummary'; +import { PulseAnimation } from './animations'; +import { SearchInput } from './searchInput'; +import { SearchModal } from './searchModal'; +import { SettingsItem } from './settingsItem'; import { SideMenu } from './sideMenu'; -import Icon from './icon'; -import Logo from './logo/logo'; -import Modal from './modal'; +import { SummaryArea, TagArea, TextArea, TitleArea } from './editorElements'; +import { TabBar } from './tabBar'; import { TextInput } from './textInput'; -import ScaleSlider from './scaleSlider/scaleSliderView'; -import UserListItem from './basicUIElements/view/userListItem/userListItem'; +import { ToastNotification } from './toastNotification'; +import { ToggleSwitch } from './toggleSwitch'; +import { TransferFormItem } from './transferFormItem'; +import { Upvote } from './upvote'; +import { UserAvatar } from './userAvatar'; +import Logo from './logo/logo'; import PostButton from './postButton/postButtonView'; -import Promote from './promote/promoteView'; +import ProfileEditForm from './profileEditForm/profileEditFormView'; +import ScaleSlider from './scaleSlider/scaleSliderView'; + +// View +import { Comment } from './comment'; +import { Comments } from './comments'; +import { CommentsDisplay } from './commentsDisplay'; +import { LeaderBoard } from './leaderboard'; +import { Notification } from './notification'; +import { Points } from './points'; +import { Posts } from './posts'; +import { Transaction } from './transaction'; +import { VotersDisplay } from './votersDisplay'; +import { Wallet } from './wallet'; +import { WalletDetails } from './walletDetails'; import PostBoost from './postBoost/postBoostView'; +import Profile from './profile/profileView'; +import Promote from './promote/promoteView'; + +// Basic UI Elements +import { + BoostPlaceHolder, + Card, + Chip, + GrayWrapper, + LineBreak, + ListItemPlaceHolder, + ListPlaceHolder, + NoInternetConnection, + NoPost, + PostCardPlaceHolder, + PostPlaceHolder, + ProfileSummaryPlaceHolder, + StickyBar, + Tag, + TextWithIcon, + UserListItem, + WalletDetailsPlaceHolder, + WalletLineItem, + WalletUnclaimedPlaceHolder, +} from './basicUIElements'; export { + Card, + Chip, + GrayWrapper, + LineBreak, + ListItemPlaceHolder, + ListPlaceHolder, + BoostPlaceHolder, + NoInternetConnection, + NoPost, + PostCardPlaceHolder, + PostPlaceHolder, + ProfileSummaryPlaceHolder, + StickyBar, + Tag, + TextWithIcon, + UserListItem, + WalletDetailsPlaceHolder, + WalletLineItem, + WalletUnclaimedPlaceHolder, + AvatarHeader, + BasicHeader, + InformationBox, + BottomTabBar, + CheckBox, CircularButton, + CollapsibleCard, + Comment, + Comments, + CommentsDisplay, + ContainerHeader, + DateTimePicker, + DropdownButton, + FilterBar, + FormatedCurrency, FormInput, + Header, Icon, IconButton, + InformationArea, + LeaderBoard, + LoginHeader, Logo, + MainButton, + MarkdownEditor, Modal, + Notification, + NotificationLine, NumericKeyboard, + ParentPost, + PercentBar, PinAnimatedInput, + Points, + PostBody, + PostBoost, + PostButton, + PostCard, + PostDisplay, + PostDropdown, + PostForm, + PostHeaderDescription, + PostListItem, + Posts, + Profile, + ProfileEditForm, + ProfileSummary, + Promote, + PulseAnimation, ScaleSlider, + SearchInput, + SearchModal, + SettingsItem, SideMenu, + SquareButton, + SummaryArea, + TabBar, + TagArea, + Tags, + TextArea, TextButton, TextInput, - UserListItem, - PostButton, - Promote, - PostBoost, + TitleArea, + ToastNotification, + ToggleSwitch, + Transaction, + TransferFormItem, + Upvote, + UserAvatar, + VotersDisplay, + Wallet, + WalletDetails, }; diff --git a/src/components/informationBox/index.js b/src/components/informationBox/index.js index 10361ddd1..5cecb5272 100644 --- a/src/components/informationBox/index.js +++ b/src/components/informationBox/index.js @@ -1 +1,3 @@ -export { default } from './view/informationBox'; +import InformationBox from './view/informationBoxView'; + +export { InformationBox }; diff --git a/src/components/informationBox/view/informationBox.js b/src/components/informationBox/view/informationBoxView.js similarity index 100% rename from src/components/informationBox/view/informationBox.js rename to src/components/informationBox/view/informationBoxView.js diff --git a/src/components/notification/view/notificationView.js b/src/components/notification/view/notificationView.js index 0cb82410b..c663c211f 100644 --- a/src/components/notification/view/notificationView.js +++ b/src/components/notification/view/notificationView.js @@ -8,7 +8,7 @@ import { injectIntl } from 'react-intl'; // Components import { ContainerHeader } from '../../containerHeader'; import { FilterBar } from '../../filterBar'; -import NotificationLine from '../../notificationLine'; +import { NotificationLine } from '../..'; import { ListPlaceHolder } from '../../basicUIElements'; // Utils diff --git a/src/components/notificationLine/index.js b/src/components/notificationLine/index.js index 1852da893..a7eb88538 100644 --- a/src/components/notificationLine/index.js +++ b/src/components/notificationLine/index.js @@ -1,3 +1,3 @@ -import NotificationLineView from './view/notificationLineView'; +import NotificationLine from './view/notificationLineView'; -export default NotificationLineView; +export { NotificationLine }; diff --git a/src/components/numericKeyboard/views/numericKeyboardView.js b/src/components/numericKeyboard/views/numericKeyboardView.js index 9bc3d39fe..ca2c1c7f9 100644 --- a/src/components/numericKeyboard/views/numericKeyboardView.js +++ b/src/components/numericKeyboard/views/numericKeyboardView.js @@ -1,7 +1,8 @@ import React from 'react'; import { View } from 'react-native'; import times from 'lodash/times'; -import { CircularButton, IconButton } from '../../buttons'; +import { CircularButton } from '../../buttons'; +import { IconButton } from '../../iconButton'; import styles from './numericKeyboardStyles'; @@ -26,11 +27,11 @@ const NumericKeyboard = ({ onPress }) => ( onPress={value => onPress && onPress(value)} /> onPress && onPress('clear')} + onPress={() => onPress && onPress('clear')} isCircle buttonStyle={styles.buttonWithoutBorder} style={styles.iconButton} - name="backspace" + name="ios-backspace" /> diff --git a/src/screens/profile/screen/profileStyles.js b/src/components/profile/profileStyles.js similarity index 100% rename from src/screens/profile/screen/profileStyles.js rename to src/components/profile/profileStyles.js diff --git a/src/components/profile/profileView.js b/src/components/profile/profileView.js new file mode 100644 index 000000000..a1c961d27 --- /dev/null +++ b/src/components/profile/profileView.js @@ -0,0 +1,238 @@ +import React, { PureComponent, Fragment } from 'react'; +import { View, ScrollView } from 'react-native'; +import { injectIntl } from 'react-intl'; +import get from 'lodash/get'; +import ScrollableTabView from 'react-native-scrollable-tab-view'; + +// Components +import { CollapsibleCard } from '../collapsibleCard'; +import { Comments } from '../comments'; +import { Header } from '../header'; +import { NoPost, ProfileSummaryPlaceHolder, WalletDetailsPlaceHolder } from '../basicUIElements'; +import { Posts } from '../posts'; +import { ProfileSummary } from '../profileSummary'; +import { TabBar } from '../tabBar'; +import { Wallet } from '../wallet'; + +// Constants +import { PROFILE_FILTERS } from '../../constants/options/filters'; + +// Utils +import { getFormatedCreatedDate } from '../../utils/time'; + +// Styles +import styles from './profileStyles'; +import globalStyles from '../../globalStyles'; + +class ProfileView extends PureComponent { + constructor(props) { + super(props); + this.state = { + isSummaryOpen: true, + collapsibleMoreHeight: 0, + estimatedWalletValue: 0, + oldEstimatedWalletValue: 0, + }; + } + + _handleOnScroll = () => { + const { isSummaryOpen } = this.state; + + if (isSummaryOpen) this.setState({ isSummaryOpen: false }); + }; + + _handleOnSummaryExpanded = () => { + const { isSummaryOpen } = this.state; + + if (!isSummaryOpen) this.setState({ isSummaryOpen: true }); + }; + + _handleUIChange = height => { + this.setState({ collapsibleMoreHeight: height }); + }; + + render() { + const { + about, + activePage, + changeForceLoadPostState, + comments, + currencyRate, + currencySymbol, + follows, + forceLoadPost, + getReplies, + handleFollowUnfollowUser, + handleMuteUnmuteUser, + handleOnBackPress, + handleOnFavoritePress, + handleOnFollowsPress, + handleOnPressProfileEdit, + intl, + isDarkTheme, + isFavorite, + isFollowing, + isLoggedIn, + isMuted, + isOwnProfile, + isProfileLoading, + isReady, + quickProfile, + resourceCredits, + selectedUser, + username, + votingPower, + } = this.props; + + const { + isSummaryOpen, + collapsibleMoreHeight, + estimatedWalletValue, + oldEstimatedWalletValue, + } = this.state; + + return ( + +
+ + {!isReady ? ( + + ) : ( + + + + )} + + ( + + )} + onChangeTab={({ i }) => { + if (i !== 2) { + this.setState({ + estimatedWalletValue: 0, + oldEstimatedWalletValue: estimatedWalletValue, + }); + } else this.setState({ estimatedWalletValue: oldEstimatedWalletValue }); + }} + > + + + + + {comments && comments.length > 0 ? ( + + + + ) : ( + + )} + + + {selectedUser ? ( + this.setState({ estimatedWalletValue: value })} + selectedUser={selectedUser} + handleOnScroll={isSummaryOpen ? this._handleOnScroll : null} + /> + ) : ( + + )} + + + + + ); + } +} + +export default injectIntl(ProfileView); diff --git a/src/components/profileEditForm/profileEditFormStyles.js b/src/components/profileEditForm/profileEditFormStyles.js new file mode 100644 index 000000000..53a092327 --- /dev/null +++ b/src/components/profileEditForm/profileEditFormStyles.js @@ -0,0 +1,71 @@ +import EStyleSheet from 'react-native-extended-stylesheet'; + +export default EStyleSheet.create({ + container: { + paddingHorizontal: 32, + paddingVertical: 16, + backgroundColor: '$primaryBackgroundColor', + flex: 1, + }, + formStyle: { + backgroundColor: '$white', + height: 30, + marginTop: 8, + }, + label: { + fontSize: 14, + color: '$primaryDarkText', + fontWeight: '500', + }, + formItem: { + marginBottom: 24, + }, + coverImg: { + borderRadius: 5, + height: 60, + marginBottom: 12, + alignSelf: 'stretch', + backgroundColor: '#296CC0', + }, + coverImageWrapper: {}, + addIcon: { + color: '$white', + textAlign: 'center', + }, + addButton: { + backgroundColor: '$iconColor', + width: 20, + height: 20, + borderRadius: 20 / 2, + borderColor: '$white', + borderWidth: 1, + position: 'absolute', + bottom: 0, + right: 10, + }, + + saveButton: { + backgroundColor: '$primaryBlue', + width: 55, + height: 55, + borderRadius: 55 / 2, + position: 'absolute', + top: -25, + right: 10, + zIndex: 999, + borderWidth: 2, + borderColor: '$white', + }, + saveIcon: { + color: '$white', + textAlign: 'center', + }, + + input: { + fontSize: 14, + color: '$primaryDarkText', + alignSelf: 'flex-start', + width: '100%', + height: 30, + }, +}); diff --git a/src/components/profileEditForm/profileEditFormView.js b/src/components/profileEditForm/profileEditFormView.js new file mode 100644 index 000000000..6a713dfc9 --- /dev/null +++ b/src/components/profileEditForm/profileEditFormView.js @@ -0,0 +1,88 @@ +import React from 'react'; +import { withNavigation } from 'react-navigation'; +import { View, TouchableOpacity, Image, Text, Platform } from 'react-native'; +import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view'; +import { injectIntl } from 'react-intl'; + +// Images +import LIGHT_COVER_IMAGE from '../../assets/default_cover_image.png'; +import DARK_COVER_IMAGE from '../../assets/dark_cover_image.png'; + +// Components +import { FormInput } from '../formInput'; +import { IconButton } from '../iconButton'; + +// Utils +import { getResizedImage } from '../../utils/image'; + +// Styles +import styles from './profileEditFormStyles'; + +const ProfileEditFormView = ({ + avatarUrl, + coverUrl, + formData, + handleOnItemChange, + handleOnSubmit, + intl, + isDarkTheme, + isLoading, + showImageUploadActions, + ...props +}) => ( + + + + + + + + + + {formData.map(item => ( + + + {intl.formatMessage({ + id: `profile.edit.${item.label}`, + })} + + handleOnItemChange(value, item.valueKey)} + placeholder={item.placeholder} + isEditable + type="none" + value={props[item.valueKey]} + inputStyle={styles.input} + /> + + ))} + + +); + +export default injectIntl(withNavigation(ProfileEditFormView)); diff --git a/src/components/profileSummary/view/profileSummaryView.js b/src/components/profileSummary/view/profileSummaryView.js index 6c74fb091..eee2092d6 100644 --- a/src/components/profileSummary/view/profileSummaryView.js +++ b/src/components/profileSummary/view/profileSummaryView.js @@ -8,6 +8,7 @@ import { ActivityIndicator, Linking, } from 'react-native'; +import get from 'lodash/get'; // Constants import LIGHT_COVER_IMAGE from '../../../assets/default_cover_image.png'; @@ -21,6 +22,7 @@ import { DropdownButton } from '../../dropdownButton'; // Utils import { makeCountFriendly } from '../../../utils/formatter'; +import { getResizedImage } from '../../../utils/image'; // Styles import styles from './profileSummaryStyles'; @@ -44,7 +46,7 @@ class ProfileSummaryView extends PureComponent { // Component Functions _handleOnPressLink = url => { - Linking.openURL(url); + if (url) Linking.openURL(url); }; _handleOnDropdownSelect = index => { @@ -60,13 +62,14 @@ class ProfileSummaryView extends PureComponent { render() { const { isShowPercentText } = this.state; const { - coverImage, date, + about, followerCount, followingCount, handleFollowUnfollowUser, handleOnFavoritePress, handleOnFollowsPress, + handleOnPressProfileEdit, handleUIChange, hoursRC, hoursVP, @@ -78,59 +81,60 @@ class ProfileSummaryView extends PureComponent { isMuted, isOwnProfile, isProfileLoading, - link, - location, percentRC, percentVP, } = this.props; - const dropdownOpions = []; + const dropdownOptions = []; const votingPowerHoursText = hoursVP && `• Full in ${hoursVP} hours`; const votingPowerText = `Voting power: ${percentVP}% ${votingPowerHoursText || ''}`; const rcPowerHoursText = hoursRC && `• Full in ${hoursRC} hours`; const rcPowerText = `RCs: ${percentRC}% ${rcPowerHoursText || ''}`; + const link = get(about, 'website', ''); + const location = get(about, 'location', ''); + + const ABOUT_DATA = [ + { id: 1, text: date, icon: 'calendar' }, + { id: 2, text: link, icon: 'earth', onPress: () => this._handleOnPressLink(link) }, + { id: 3, text: location, icon: 'near-me' }, + ]; const rowLength = (location ? location.length : 0) + (link ? link.length : 0) + (date ? date.length : 0); const isColumn = rowLength && DEVICE_WIDTH / rowLength <= 7.3; const followButtonIcon = !isFollowing ? 'account-plus' : 'account-minus'; - const coverImageUrl = `https://steemitimages.com/400x0/${coverImage}`; + let coverImageUrl = getResizedImage(get(about, 'cover_image'), 400); - dropdownOpions.push(!isMuted ? 'MUTE' : 'UNMUTE'); + if (!coverImageUrl) { + coverImageUrl = isDarkTheme + ? require('../../../assets/dark_cover_image.png') + : require('../../../assets/default_cover_image.png'); + } else { + coverImageUrl = { uri: coverImageUrl }; + } + + dropdownOptions.push(!isMuted ? 'MUTE' : 'UNMUTE'); return ( - {!!location && ( - - )} - {!!link && ( - this._handleOnPressLink(link)} - text={link} - iconSize={14} - iconName="earth" - iconType="MaterialCommunityIcons" - /> - )} - {!!date && ( - + {ABOUT_DATA.map(item => + get(item, 'text', null) ? ( + + ) : null, )} - {isLoggedIn && !isOwnProfile && ( + {isLoggedIn && !isOwnProfile ? ( )} + ) : ( + isOwnProfile && ( + + + + ) )} diff --git a/src/components/searchInput/index.js b/src/components/searchInput/index.js index d54bb6ba0..84ceedaa4 100644 --- a/src/components/searchInput/index.js +++ b/src/components/searchInput/index.js @@ -1,3 +1,3 @@ import SearchInput from './view/searchInputView'; -export default SearchInput; +export { SearchInput }; diff --git a/src/components/searchModal/container/searchModalContainer.js b/src/components/searchModal/container/searchModalContainer.js index 3d5afb267..46a79c619 100644 --- a/src/components/searchModal/container/searchModalContainer.js +++ b/src/components/searchModal/container/searchModalContainer.js @@ -1,17 +1,17 @@ import React, { PureComponent } from 'react'; import { withNavigation } from 'react-navigation'; import { connect } from 'react-redux'; +import get from 'lodash/get'; // Services and Actions import { search } from '../../../providers/esteem/esteem'; import { lookupAccounts, getTrendingTags } from '../../../providers/steem/dsteem'; -// Middleware - // Constants import { default as ROUTES } from '../../../constants/routeNames'; // Utilities +import { getResizedAvatar } from '../../../utils/image'; // Component import SearchModalView from '../view/searchModalView'; @@ -41,41 +41,45 @@ class SearchModalContainer extends PureComponent { _handleOnChangeSearchInput = text => { const { isConnected } = this.props; - + if (text && text.length < 2) return; + if (this.timer) { + clearTimeout(this.timer); + } if (!isConnected) return; - - if (text && text !== '@' && text !== '#') { - if (text[0] === '@') { - lookupAccounts(text.substr(1)).then(res => { - const users = res.map(item => ({ - image: `https://steemitimages.com/u/${item}/avatar/small`, - text: item, - ...item, - })); - this.setState({ searchResults: { type: 'user', data: users } }); - }); - } else if (text[0] === '#') { - getTrendingTags(text.substr(1)).then(res => { - const tags = res.map(item => ({ - text: `#${item.name}`, - ...item, - })); - - this.setState({ searchResults: { type: 'tag', data: tags } }); - }); - } else { - search({ q: text }).then(res => { - res.results = res.results - .filter(item => item.title !== '') - .map(item => ({ - image: item.img_url || `https://steemitimages.com/u/${item.author}/avatar/small`, - text: item.title, + this.timer = setTimeout(() => { + if (text && text !== '@' && text !== '#') { + if (text[0] === '@') { + lookupAccounts(text.substr(1)).then(res => { + const users = res.map(item => ({ + image: getResizedAvatar(item), + text: item, ...item, })); - this.setState({ searchResults: { type: 'content', data: res.results } }); - }); + this.setState({ searchResults: { type: 'user', data: users } }); + }); + } else if (text[0] === '#') { + getTrendingTags(text.substr(1)).then(res => { + const tags = res.map(item => ({ + text: `#${get(item, 'name', '')}`, + ...item, + })); + + this.setState({ searchResults: { type: 'tag', data: tags } }); + }); + } else { + search({ q: text }).then(res => { + res.results = res.results + .filter(item => item.title !== '') + .map(item => ({ + image: item.img_url || getResizedAvatar(get(item, 'author')), + text: item.title, + ...item, + })); + this.setState({ searchResults: { type: 'content', data: get(res, 'results', []) } }); + }); + } } - } + }, 500); }; _handleOnPressListItem = (type, item) => { @@ -89,24 +93,24 @@ class SearchModalContainer extends PureComponent { switch (type) { case 'user': - routeName = item.text === username ? ROUTES.TABBAR.PROFILE : ROUTES.SCREENS.PROFILE; + routeName = get(item, 'text') === username ? ROUTES.TABBAR.PROFILE : ROUTES.SCREENS.PROFILE; params = { - username: item.text, + username: get(item, 'text'), }; key = item.text; break; case 'content': routeName = ROUTES.SCREENS.POST; params = { - author: item.author, - permlink: item.permlink, + author: get(item, 'author'), + permlink: get(item, 'permlink'), }; - key = item.permlink; + key = get(item, 'permlink'); break; case 'tag': routeName = ROUTES.SCREENS.SEARCH_RESULT; params = { - tag: item.text.substr(1), + tag: get(item, 'text', '').substr(1), }; break; @@ -129,13 +133,13 @@ class SearchModalContainer extends PureComponent { return ( ); } diff --git a/src/components/searchModal/view/searchModalStyles.js b/src/components/searchModal/view/searchModalStyles.js index 7bf7601f7..1cd55d186 100644 --- a/src/components/searchModal/view/searchModalStyles.js +++ b/src/components/searchModal/view/searchModalStyles.js @@ -47,7 +47,7 @@ export default EStyleSheet.create({ marginRight: 24, flex: 1, }, - searhItems: { + searchItems: { marginHorizontal: 30, marginVertical: 10, flexDirection: 'row', diff --git a/src/components/searchModal/view/searchModalView.js b/src/components/searchModal/view/searchModalView.js index e92bf112b..52ddbdad6 100644 --- a/src/components/searchModal/view/searchModalView.js +++ b/src/components/searchModal/view/searchModalView.js @@ -1,13 +1,10 @@ import React, { PureComponent } from 'react'; import { View, Text, FlatList, TouchableOpacity, SafeAreaView } from 'react-native'; - import FastImage from 'react-native-fast-image'; - -// Constants +import { get, has } from 'lodash'; // Components -import { Modal } from '../..'; -import SearchInput from '../../searchInput'; +import { Modal, SearchInput } from '../..'; // Styles import styles from './searchModalStyles'; @@ -40,7 +37,7 @@ class SearchModalView extends PureComponent { return ( handleOnClose()} + handleOnModalClose={handleOnClose} isFullScreen swipeToClose isTransparent @@ -53,12 +50,14 @@ class SearchModalView extends PureComponent { /> ( // TODO: Make it quick ui component - handleOnPressListItem(searchResults.type, item)}> - + handleOnPressListItem(get(searchResults, 'type'), item)} + > + {item.image && ( - {item.text && {item.text}} + {has(item, 'text') && {item.text}} )} - keyExtractor={(post, index) => index.toString()} + keyExtractor={(item, index) => get(item, 'id', index).toString()} removeClippedSubviews onEndThreshold={0} initialNumToRender={20} diff --git a/src/components/sideMenu/view/sideMenuView.js b/src/components/sideMenu/view/sideMenuView.js index 4f4525fd3..0cdb5b578 100644 --- a/src/components/sideMenu/view/sideMenuView.js +++ b/src/components/sideMenu/view/sideMenuView.js @@ -6,7 +6,7 @@ import ActionSheet from 'react-native-actionsheet'; import VersionNumber from 'react-native-version-number'; // Components -import { IconButton } from '../../buttons'; +import { IconButton } from '../../iconButton'; import { Icon } from '../../icon'; import { UserAvatar } from '../../userAvatar'; @@ -121,13 +121,13 @@ class SideMenuView extends Component { this._handleOnPressAddAccountIcon()} + onPress={this._handleOnPressAddAccountIcon} style={styles.addAccountIcon} /> diff --git a/src/components/textInput/view/textInputView.js b/src/components/textInput/view/textInputView.js index 97c571e19..09f19b977 100644 --- a/src/components/textInput/view/textInputView.js +++ b/src/components/textInput/view/textInputView.js @@ -5,9 +5,9 @@ import { connect } from 'react-redux'; // Styles import styles from './textInputStyles'; -const TextInputView = ({ isDarkTheme, innerRef, ...props }) => ( +const TextInputView = ({ isDarkTheme, innerRef, height, ...props }) => ( { - const { dispatch, currentUsername } = this.props; + const { + dispatch, + currentUsername: { name }, + } = this.props; - const routeName = currentUsername === username ? ROUTES.TABBAR.PROFILE : ROUTES.SCREENS.PROFILE; + const routeName = name === username ? ROUTES.TABBAR.PROFILE : ROUTES.SCREENS.PROFILE; const navigateAction = NavigationActions.navigate({ routeName, @@ -42,11 +48,21 @@ class UserAvatarView extends Component { }; render() { - const { username, size, style, disableSize, noAction } = this.props; + const { + username, + size, + style, + disableSize, + noAction, + avatarUrl, + currentUsername: { name, avatar }, + } = this.props; const imageSize = size === 'xl' ? 'large' : 'small'; let _size; const _avatar = username - ? { uri: `https://steemitimages.com/u/${username}/avatar/${imageSize}` } + ? { + uri: avatarUrl || (name === username ? avatar : getResizedAvatar(username, imageSize)), + } : DEFAULT_IMAGE; if (!disableSize) { @@ -73,7 +89,7 @@ class UserAvatarView extends Component { } const mapStateToProps = state => ({ - currentUsername: state.account.currentAccount.name, + currentUsername: state.account.currentAccount, }); export default connect(mapStateToProps)(UserAvatarView); diff --git a/src/config/locales/ac-ace.json b/src/config/locales/ac-ace.json index 9c9e5d5df..4c838e2f3 100644 --- a/src/config/locales/ac-ace.json +++ b/src/config/locales/ac-ace.json @@ -97,7 +97,13 @@ "days": "uroë-uroë", "day": "uroë", "steem_dollars": "Steem Dollars", - "savings": "Keunëubah" + "savings": "Keunëubah", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Peungaturan", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ar-SA.json b/src/config/locales/ar-SA.json index 91aacc7e0..25623804d 100644 --- a/src/config/locales/ar-SA.json +++ b/src/config/locales/ar-SA.json @@ -97,7 +97,13 @@ "days": "أيام", "day": "يوم", "steem_dollars": "ستيم دولار", - "savings": "مدخرات" + "savings": "مدخرات", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "إعدادات", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/as-IN.json b/src/config/locales/as-IN.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/as-IN.json +++ b/src/config/locales/as-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/az-AZ.json b/src/config/locales/az-AZ.json index cca21b584..86369f27f 100644 --- a/src/config/locales/az-AZ.json +++ b/src/config/locales/az-AZ.json @@ -97,7 +97,13 @@ "days": "gün", "day": "gün", "steem_dollars": "Steem Dollar", - "savings": "Yığımlar" + "savings": "Yığımlar", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Tənzimləmələr", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/bg-BG.json b/src/config/locales/bg-BG.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/bg-BG.json +++ b/src/config/locales/bg-BG.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/bn-BD.json b/src/config/locales/bn-BD.json index 7a899d526..c217d5118 100644 --- a/src/config/locales/bn-BD.json +++ b/src/config/locales/bn-BD.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/bo-BT.json b/src/config/locales/bo-BT.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/bo-BT.json +++ b/src/config/locales/bo-BT.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/bs-BA.json b/src/config/locales/bs-BA.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/bs-BA.json +++ b/src/config/locales/bs-BA.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ca-ES.json b/src/config/locales/ca-ES.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ca-ES.json +++ b/src/config/locales/ca-ES.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ceb-PH.json b/src/config/locales/ceb-PH.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ceb-PH.json +++ b/src/config/locales/ceb-PH.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/cs-CZ.json b/src/config/locales/cs-CZ.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/cs-CZ.json +++ b/src/config/locales/cs-CZ.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/da-DK.json b/src/config/locales/da-DK.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/da-DK.json +++ b/src/config/locales/da-DK.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/de-DE.json b/src/config/locales/de-DE.json index 832deb00d..4dbe3947d 100644 --- a/src/config/locales/de-DE.json +++ b/src/config/locales/de-DE.json @@ -97,7 +97,13 @@ "days": "Tagen", "day": "Tag", "steem_dollars": "Steem-Dollar", - "savings": "Gesichert" + "savings": "Gesichert", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Einstellungen", @@ -222,7 +228,8 @@ "fetch_error": "Das Abrufen der Daten vom Server ist fehlgeschlagen. Bitte versuche es nochmal oder informiere uns unter info@esteem.app", "connection_fail": "Verbindung fehlgeschlagen!", "connection_success": "Erfolgreich verbunden!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Möchtest du diesen Beitrag wirklich teilen?", diff --git a/src/config/locales/el-GR.json b/src/config/locales/el-GR.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/el-GR.json +++ b/src/config/locales/el-GR.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/en-US.json b/src/config/locales/en-US.json index a759aec14..8b27b9950 100644 --- a/src/config/locales/en-US.json +++ b/src/config/locales/en-US.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", diff --git a/src/config/locales/eo-UY.json b/src/config/locales/eo-UY.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/eo-UY.json +++ b/src/config/locales/eo-UY.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/es-ES.json b/src/config/locales/es-ES.json index 88a77d235..62b55f21b 100644 --- a/src/config/locales/es-ES.json +++ b/src/config/locales/es-ES.json @@ -97,7 +97,13 @@ "days": "días", "day": "día", "steem_dollars": "Steem Dólares", - "savings": "Ahorros" + "savings": "Ahorros", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Ajustes", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/et-EE.json b/src/config/locales/et-EE.json index 0822c3d59..34cd42fb8 100644 --- a/src/config/locales/et-EE.json +++ b/src/config/locales/et-EE.json @@ -97,7 +97,13 @@ "days": "päeva", "day": "päev", "steem_dollars": "Steem Dollar", - "savings": "Säästud" + "savings": "Säästud", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Seaded", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/fa-IR.json b/src/config/locales/fa-IR.json index 0317302c0..612d9391d 100644 --- a/src/config/locales/fa-IR.json +++ b/src/config/locales/fa-IR.json @@ -97,7 +97,13 @@ "days": "روزها", "day": "روز", "steem_dollars": "دلار استیم", - "savings": "پس انداز" + "savings": "پس انداز", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "تنظیمات", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/fi-FI.json b/src/config/locales/fi-FI.json index 793d10642..80d4aa708 100644 --- a/src/config/locales/fi-FI.json +++ b/src/config/locales/fi-FI.json @@ -97,7 +97,13 @@ "days": "päivää", "day": "päivä", "steem_dollars": "Steem dollarit", - "savings": "Säästöt" + "savings": "Säästöt", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Asetukset", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/fil-PH.json b/src/config/locales/fil-PH.json index 9f2c3b135..2ba21cb5e 100644 --- a/src/config/locales/fil-PH.json +++ b/src/config/locales/fil-PH.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/fr-FR.json b/src/config/locales/fr-FR.json index b67944da3..2eba1b6e8 100644 --- a/src/config/locales/fr-FR.json +++ b/src/config/locales/fr-FR.json @@ -97,7 +97,13 @@ "days": "jours", "day": "jour", "steem_dollars": "Steem Dollars", - "savings": "Économies" + "savings": "Économies", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Réglages", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ga-IE.json b/src/config/locales/ga-IE.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ga-IE.json +++ b/src/config/locales/ga-IE.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/gl-ES.json b/src/config/locales/gl-ES.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/gl-ES.json +++ b/src/config/locales/gl-ES.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/got-DE.json b/src/config/locales/got-DE.json index 511bfceb9..7214a4952 100644 --- a/src/config/locales/got-DE.json +++ b/src/config/locales/got-DE.json @@ -97,7 +97,13 @@ "days": "dagos", "day": "dags", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Lageinos", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/he-IL.json b/src/config/locales/he-IL.json index f1070d485..44eee328e 100644 --- a/src/config/locales/he-IL.json +++ b/src/config/locales/he-IL.json @@ -97,7 +97,13 @@ "days": "ימים", "day": "יום", "steem_dollars": "דולר Steem", - "savings": "חסכונות" + "savings": "חסכונות", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "הגדרות", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/hi-IN.json b/src/config/locales/hi-IN.json index d4868fdd4..0dc4866c2 100644 --- a/src/config/locales/hi-IN.json +++ b/src/config/locales/hi-IN.json @@ -97,7 +97,13 @@ "days": "दिनों", "day": "दिन", "steem_dollars": "स्टीम डॉलर्स", - "savings": "बचत" + "savings": "बचत", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "समायोजन", @@ -222,7 +228,8 @@ "fetch_error": "डेटा प्राप्त करना विफल रहा, कृपया पुनः प्रयास करें या हमें info@esteem.app पर सूचित करें", "connection_fail": "कनेक्ट करना विफल रहा", "connection_success": "सफलतापूर्वक जुड़ा हुआ है!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "क्या आप निश्चित हैं, आप इसे हटाना चाहते हैं?", diff --git a/src/config/locales/hr-HR.json b/src/config/locales/hr-HR.json index 31bb06420..63d709e17 100644 --- a/src/config/locales/hr-HR.json +++ b/src/config/locales/hr-HR.json @@ -97,7 +97,13 @@ "days": "dani", "day": "dan", "steem_dollars": "Steem Dolari", - "savings": "Štednja" + "savings": "Štednja", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Postavke", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/hu-HU.json b/src/config/locales/hu-HU.json index f8798524c..7d9ff336b 100644 --- a/src/config/locales/hu-HU.json +++ b/src/config/locales/hu-HU.json @@ -55,7 +55,7 @@ "vote_title": "Szavazási pontok", "reblog_title": "Megosztási pontok", "login_title": "Bejelentkezés pontok", - "checkin_title": "Points for heartbeat", + "checkin_title": "Életjel pontok", "checkin_extra_title": "Használati bónusz", "no_activity": "Itt nincs tevékenység!", "outgoing_transfer_description": "", @@ -68,8 +68,8 @@ "login_desc": "Minden eSteem bejelentkezés alkalmával automatikusan 100 pontra vagy jogosult.", "checkin_extra_desc": "Az alkalmazás következetes használata extra esélyt kínál arra, hogy több 10 pontot nyerj, légy aktívabb és nyerj többet.", "dropdown_transfer": "Ajándék", - "dropdown_promote": "Promoválás", - "dropdown_boost": "Kiemelés", + "dropdown_promote": "Hirdetés", + "dropdown_boost": "Felpörgetés", "from": "Tőle", "to": "Címzett" }, @@ -97,7 +97,13 @@ "days": "napok", "day": "nap", "steem_dollars": "Steem Dollár", - "savings": "Megtakarítások" + "savings": "Megtakarítások", + "edit": { + "display_name": "Megjelenítendő név", + "about": "Rólunk", + "location": "Tartózkodási hely", + "website": "Weboldal" + } }, "settings": { "settings": "Beállítások", @@ -222,14 +228,15 @@ "fetch_error": "Sikertelen adatbetöltés, kérjük próbáld meg újra vagy írj nekünk ide info@esteem.app", "connection_fail": "Sikertelen kapcsolat!", "connection_success": "A kapcsolat sikerült!", - "checking": "Ellenőrzés..." + "checking": "Ellenőrzés folyamatban...", + "not_existing_post": "A bejegyzés nem létezik! Kérjük ellenőrizd a linket és a szerzőt." }, "post": { "reblog_alert": "Biztos, hogy megosztod?", "removed_hint": "A bejegyzést eltávolította", "copy_link": "Link másolása", "reblogged": "megosztva általa", - "sponsored": "KIEMELT", + "sponsored": "TÁMOGATOTT", "open_thread": "Bejegyzés megnyitása" }, "drafts": { @@ -269,7 +276,7 @@ }, "payout": { "potential_payout": "Lehetséges Kifizetés", - "promoted": "Promovált", + "promoted": "Hirdetett", "author_payout": "Szerzői Kifizetés", "curation_payout": "Kurátori Kifizetés", "payout_date": "Kifizetés" @@ -280,8 +287,8 @@ "reply": "válasz", "share": "megosztás", "bookmarks": "hozzáadás a könyvjelzőkhöz", - "promote": "promoválás", - "boost": "kiemelés" + "promote": "hirdetés", + "boost": "felpörgetés" }, "deep_link": { "no_existing_user": "Nem létező felhasználó", @@ -326,15 +333,15 @@ "next": "KÖVETKEZŐ" }, "promote": { - "title": "Promoválás", + "title": "Hirdetés", "days": "nap", "user": "Felhasználó", "permlink": "Bejegyzés", "permlinkPlaceholder": "szerző/permlink", - "information": "Bistos promoválod?" + "information": "Bistos hirdeted?" }, "boostPost": { - "title": "Kiemelés" + "title": "Felpörgetés" }, "voters_dropdown": { "rewards": "JUTALMAK", diff --git a/src/config/locales/hy-AM.json b/src/config/locales/hy-AM.json index 73923eafa..3c206ee4e 100644 --- a/src/config/locales/hy-AM.json +++ b/src/config/locales/hy-AM.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/id-ID.json b/src/config/locales/id-ID.json index fb0030fcf..324606717 100644 --- a/src/config/locales/id-ID.json +++ b/src/config/locales/id-ID.json @@ -19,7 +19,7 @@ "unfollow": "berhenti mengikuti anda", "ignore": "mengabaikan anda", "reblog": "menampilkan kembali post anda", - "transfer": "steem ditransfer", + "transfer": "transfer steem", "comingsoon": "Fitur akan segera hadir!", "notification": "Pemberitahuan", "leaderboard": "Papan Peringkat", @@ -70,8 +70,8 @@ "dropdown_transfer": "Hadiah", "dropdown_promote": "Promosikan", "dropdown_boost": "Meningkatkan", - "from": "From", - "to": "To" + "from": "Dari", + "to": "Kepada" }, "messages": { "comingsoon": "Fungsi pesan akan segera hadir!" @@ -97,7 +97,13 @@ "days": "hari", "day": "hari", "steem_dollars": "Steem Dollars", - "savings": "Tabungan" + "savings": "Tabungan", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Pengaturan", @@ -222,15 +228,16 @@ "fetch_error": "Gagal mengambil data, silakan coba lagi atau beri tahu kami di info@esteem.app", "connection_fail": "Koneksi gagal!", "connection_success": "Berhasil terhubung!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Anda yakin, anda ingin me-reblog?", "removed_hint": "Pos dihapus oleh", "copy_link": "Copy Link", "reblogged": "direblog Oleh", - "sponsored": "SPONSORED", - "open_thread": "Open Thread" + "sponsored": "DISPONSORI", + "open_thread": "Buka Thread" }, "drafts": { "title": "Konsep", @@ -300,7 +307,7 @@ "transfer": { "from": "Dari", "to": "Kepada", - "amount_information": "Drag the slider to adjust the amount", + "amount_information": "Seret penggeser untuk menyesuaikan jumlahnya", "amount": "Jumlah", "memo": "Memo", "information": "Anda yakin mentransfer dana?", diff --git a/src/config/locales/is-IS.json b/src/config/locales/is-IS.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/is-IS.json +++ b/src/config/locales/is-IS.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/it-IT.json b/src/config/locales/it-IT.json index 32438f417..8898c6406 100644 --- a/src/config/locales/it-IT.json +++ b/src/config/locales/it-IT.json @@ -97,7 +97,13 @@ "days": "giorni", "day": "giorno", "steem_dollars": "Steem Dollars", - "savings": "Risparmi" + "savings": "Risparmi", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Impostazioni", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ja-JP.json b/src/config/locales/ja-JP.json index 8de527bba..4bfab9599 100644 --- a/src/config/locales/ja-JP.json +++ b/src/config/locales/ja-JP.json @@ -1,347 +1,354 @@ { "wallet": { - "curation_reward": "Curation Reward", - "author_reward": "Author Reward", - "comment_benefactor_reward": "Comment Benefactor Reward", - "claim_reward_balance": "Claim Reward Balance", - "transfer": "Transfer", - "transfer_to_vesting": "Transfer To Vesting", - "transfer_from_savings": "Transfer From Savings", - "withdraw_vesting": "Power Down", - "fill_order": "Fill Order" + "curation_reward": "キュレーション報酬", + "author_reward": "投稿者報酬", + "comment_benefactor_reward": "コメント寄与者報酬", + "claim_reward_balance": "報酬残高の請求", + "transfer": "送金", + "transfer_to_vesting": "パワーアップ", + "transfer_from_savings": "貯蓄口座から振替", + "withdraw_vesting": "パワーダウン", + "fill_order": "注文の入力" }, "notification": { - "vote": "likes your post", - "unvote": "unvoted your post", - "reply": "replied to your post", - "mention": "mentioned you", - "follow": "followed you", - "unfollow": "unfollowed you", - "ignore": "ignored you", - "reblog": "reblogged your post", - "transfer": "transfered steem", - "comingsoon": "Feature is coming soon!", - "notification": "Notifications", - "leaderboard": "Leaderboard", - "epoint": "Points", - "leaderboard_title": "Top Users", - "recent": "Recent", - "yesterday": "Yesterday", - "this_week": "This Week", - "this_month": "This Month", - "older_then": "Older Than A Month" + "vote": "あなたの投稿をいいねしました", + "unvote": "あなたの投稿をダウンヴォートしました", + "reply": "あなたの投稿に返信しました", + "mention": "あなたを話題にしました", + "follow": "あなたをフォローしました", + "unfollow": "あなたをフォロー解除しました", + "ignore": "あなたをミュートしました", + "reblog": "あなたの投稿をリブログしました", + "transfer": "steem を送金しました", + "comingsoon": "近日公開!", + "notification": "通知", + "leaderboard": "ランキング", + "epoint": "ポイント", + "leaderboard_title": "トップユーザー", + "recent": "最新", + "yesterday": "昨日", + "this_week": "今週", + "this_month": "今月", + "older_then": "1ヶ月以上前" }, "leaderboard": { - "daily": "Daily", - "weekly": "Weekly", - "monthly": "Monthly" + "daily": "日間", + "weekly": "週間", + "monthly": "月間" }, "points": { - "post": "Post", - "esteemPoints": "eSteem Points", - "comment": "Comment", - "checkin": "Check-in", - "vote": "Vote", - "reblog": "Reblog", - "login": "Login", - "incoming_transfer_title": "Incoming transfer", - "outgoing_transfer_title": "Outgoing transfer", - "checkin_extra": "Bonus", - "delegation": "Delegation", - "delegation_title": "Delegation reward", - "delegation_desc": "You can earn 1 point per day for each 100sp delegation", - "post_title": "Points for post", - "comment_title": "Points for comment", - "vote_title": "Points for vote", - "reblog_title": "Points for reblog", - "login_title": "Points for login", - "checkin_title": "Points for heartbeat", - "checkin_extra_title": "Usage bonus", - "no_activity": "No activity here!", + "post": "投稿", + "esteemPoints": "eSteem ポイント", + "comment": "コメント", + "checkin": "チェックイン", + "vote": "ヴォート", + "reblog": "リブログ", + "login": "ログイン", + "incoming_transfer_title": "受贈", + "outgoing_transfer_title": "贈与", + "checkin_extra": "ボーナス", + "delegation": "デリゲーション", + "delegation_title": "デリゲーション報酬", + "delegation_desc": "100 STEEM POWER を委託するごとに毎日1ポイントが獲得できます", + "post_title": "投稿によるポイント", + "comment_title": "コメントによるポイント", + "vote_title": "ヴォートによるポイント", + "reblog_title": "リブログによるポイント", + "login_title": "ログインによるポイント", + "checkin_title": "ハートビートによるポイント", + "checkin_extra_title": "使用ボーナス", + "no_activity": "アクティビティがありません!", "outgoing_transfer_description": "", "incoming_transfer_description": "", - "post_desc": "You can earn point by posting regularly. Posting gives you 15 points.", - "comment_desc": "Each comment you make helps you to grow your audience and make friendship but also earns you 5 points.", - "checkin_desc": "Checking in on eSteem app gives you 0.25 points and helps you stay connected with your friends.", - "vote_desc": "By voting you give reward to other creators and show your appreciation but also earn 0.01 x vote weight points.", - "reblog_desc": " Share what post you like with your friends and earn 1 points.", - "login_desc": "When you login into eSteem app you are entitled to earn 100 points automatically.", - "checkin_extra_desc": "Consistent use of app gives you extra chances to earn more 10 points, be more active and earn more.", - "dropdown_transfer": "Gift", - "dropdown_promote": "Promote", - "dropdown_boost": "Boost", - "from": "From", - "to": "To" + "post_desc": "定期的に投稿することでポイントを獲得できます。投稿すると15ポイントもらえます。", + "comment_desc": "コメントすると交友関係を広げられるだけでなく、5ポイント獲得できます。", + "checkin_desc": "eSteem アプリにチェックインすると0.25ポイントがもらえ、友人とのつながりにも役立ちます。", + "vote_desc": "ヴォートすることで他者に報酬を与えて評価できるだけでなく、ヴォート比重の0.01倍のポイントを獲得できます。", + "reblog_desc": "あなたの好きな投稿を周囲に共有することで、1ポイント獲得できます。", + "login_desc": "eSteem アプリにログインすると、自動的に100ポイント獲得できるようになります。", + "checkin_extra_desc": "アプリを一貫して使用しつづけると、さらに10ポイント獲得できます。積極的に使用してポイントを手に入れよう。", + "dropdown_transfer": "贈る", + "dropdown_promote": "プロモート", + "dropdown_boost": "ブースト", + "from": "差出人", + "to": "受取人" }, "messages": { - "comingsoon": "Messages feature is coming soon!" + "comingsoon": "メッセージ機能は近日公開予定です!" }, "profile": { - "following": "Following", - "follower": "Follower", - "post": "Post", - "details": "Profile Details", - "comments": "Comments", - "replies": "Replies", - "wallet": "Wallet", - "wallet_details": "Wallet Details", - "unclaimed_rewards": "Unclaimed Rewards", - "full_in": "Full in", - "hours": "hours", - "voting_power": "Voting power", - "login_to_see": "Login to see", - "havent_commented": "haven't commented anything yet", - "havent_posted": "haven't posted anything yet", + "following": "フォロー", + "follower": "フォロワー", + "post": "投稿", + "details": "プロフィールの詳細", + "comments": "コメント", + "replies": "返信", + "wallet": "ウォレット", + "wallet_details": "ウォレットの詳細", + "unclaimed_rewards": "未請求の報酬", + "full_in": "最大まで", + "hours": "時間", + "voting_power": "ヴォート能力", + "login_to_see": "ログイン", + "havent_commented": "まだ何もコメントしていません", + "havent_posted": "まだ何も投稿していません", "steem_power": "Steem Power", - "next_power_text": "Next power down is in", - "days": "days", - "day": "day", + "next_power_text": "次のパワーダウンまで", + "days": "日", + "day": "日", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "貯蓄口座", + "edit": { + "display_name": "表示名", + "about": "このアプリについて", + "location": "場所", + "website": "ウェブサイト" + } }, "settings": { - "settings": "Settings", - "general": "General", - "currency": "Currency", - "language": "Language", - "server": "Server", - "dark_theme": "Dark Theme", - "push_notification": "Push Notification", + "settings": "設定", + "general": "一般", + "currency": "通貨", + "language": "言語", + "server": "サーバー", + "dark_theme": "ダークテーマ", + "push_notification": "プッシュ通知", "notification": { - "follow": "Follow", - "vote": "Vote", - "comment": "Comment", - "mention": "Mention", - "reblog": "Reblog", - "transfers": "Transfers" + "follow": "フォロー", + "vote": "ヴォート", + "comment": "コメント", + "mention": "メンション", + "reblog": "リブログ", + "transfers": "送金" }, - "pincode": "Pincode", - "reset_pin": "Reset Pin Code", - "reset": "Reset", - "nsfw_content": "NSFW Content", - "send_feedback": "Send Feedback", - "send": "Send", - "default_footer": "Default Footer", + "pincode": "PINコード", + "reset_pin": "PINコードをリセット", + "reset": "リセット", + "nsfw_content": "不適切な内容", + "send_feedback": "フィードバックを送信する", + "send": "送信", + "default_footer": "デフォルトフッター", "nsfw": { - "always_show": "Always show", - "always_hide": "Always hide", - "always_warn": "Always warn" + "always_show": "常に表示する", + "always_hide": "常に表示しない", + "always_warn": "常に警告する" }, - "feedback_success": "Email successfully open", - "feedback_fail": "Email client could not open", - "server_fail": "Server not available" + "feedback_success": "メールを開くことができました", + "feedback_fail": "メールを開くことができませんでした", + "server_fail": "サーバーは利用できません" }, "voters": { - "voters_info": "Voters Info", - "no_user": "User is not found." + "voters_info": "ヴォート情報", + "no_user": "ユーザーが見つかりません。" }, "login": { - "signin": "Sign in", - "signup": "Sign up", - "signin_title": "To get all the benefits of using eSteem", - "username": "Username", - "password": "Password or WIF", - "description": "User credentials are kept locally on the device. Credentials are removed upon logout!", - "cancel": "cancel", - "login": "LOGIN", - "steemconnect_description": "If you don't want to keep your password encrypted and saved on your device, you can use Steemconnect.", - "steemconnect_fee_description": "Steemconnect may charge some fees from your reward transactions" + "signin": "ログイン", + "signup": "新規登録", + "signin_title": "eSteem の素晴らしさを満喫しよう", + "username": "ユーザー名", + "password": "パスワードまたは WIF", + "description": "ユーザーのログイン情報は端末に保存され、ログアウトすると削除されます。", + "cancel": "キャンセル", + "login": "ログイン", + "steemconnect_description": "端末に暗号化したパスワードを保存したくない場合、Steemconnect を利用できます。", + "steemconnect_fee_description": "Steemconnect はあなたの報酬から一定の手数料を徴収するかもしれません" }, "home": { - "feed": "Feed", - "popular": "Popular" + "feed": "フィード", + "popular": "人気" }, "side_menu": { - "profile": "Profile", - "bookmarks": "Bookmarks", - "favorites": "Favorites", - "drafts": "Drafts", - "schedules": "Schedules", - "gallery": "Gallery", - "settings": "Settings", - "add_account": "Add Account", - "logout": "Logout", - "cancel": "Cancel", - "logout_text": "Are you sure you want to logout?" + "profile": "プロフィール", + "bookmarks": "ブックマーク", + "favorites": "お気に入り", + "drafts": "下書き", + "schedules": "スケジュール", + "gallery": "ギャラリー", + "settings": "設定", + "add_account": "アカウントを追加", + "logout": "ログアウト", + "cancel": "キャンセル", + "logout_text": "本当にログアウトしますか?" }, "header": { - "title": "Login to customize your feed", - "search": "Search..." + "title": "ログインして自分好みのフィードをつくろう", + "search": "検索..." }, "basic_header": { - "publish": "Publish", - "search": "Search", - "update": "Update", - "reply": "Reply" + "publish": "公開", + "search": "検索", + "update": "更新", + "reply": "返信" }, "editor": { - "title": "Title", - "tags": "tags", - "default_placeholder": "What would you like to write about today?", - "reply_placeholder": "What would you like to write about above post?", - "publish": "Publish", - "reply": "Reply", - "open_gallery": "Open Gallery", - "capture_photo": "Capture a photo" + "title": "タイトル", + "tags": "タグ", + "default_placeholder": "今日のことについて何か投稿してみませんか?", + "reply_placeholder": "投稿について何かコメントしてみませんか?", + "publish": "公開", + "reply": "返信", + "open_gallery": "ギャラリーを開く", + "capture_photo": "写真を撮る" }, "pincode": { - "enter_text": "Enter pin to unlock", - "set_new": "Set new pin", - "write_again": "Write again", - "forgot_text": "Oh, I forgot it..." + "enter_text": "PIN を入力してロックを解除", + "set_new": "新しい PIN を設定", + "write_again": "もう一度入力", + "forgot_text": "忘れてしまった場合" }, "alert": { - "success": "Success!", - "successful": "Successful", - "allRead": "Marked all notifications as read", - "claim_reward_balance_ok": "Reward balance claimed", - "fail": "Fail!", - "move": "Move", - "move_question": "Are you sure to move to drafts?", - "success_shared": "Your post successfully shared", - "success_moved": "Moved to draft", - "permission_denied": "Permission denied", - "permission_text": "Please, go to phone Settings and change eSteem app permissions.", - "success_rebloged": "Rebloged!", - "already_rebloged": "You have already reblogged!", - "warning": "Warning", - "invalid_pincode": "Invalid pin code, please check and try again.", - "remove_alert": "Are you sure want to remove?", - "clear_alert": "Are you sure you want to clear?", - "clear_user_alert": "Are you sure you want to clear all user data?", - "clear": "Clear", - "cancel": "Cancel", - "delete": "Delete", - "copied": "Copied!", - "no_internet": "No connection!", - "confirm": "Confirm", - "removed": "Removed", - "same_user": "This user already added to list", - "unknow_error": "An error occurred", - "error": "Error", - "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", - "connection_fail": "Connection Failed!", - "connection_success": "Successfully connected!", - "checking": "Cheking..." + "success": "成功しました!", + "successful": "成功しました", + "allRead": "すべての通知を既読にする", + "claim_reward_balance_ok": "報酬残高を請求しました", + "fail": "失敗!", + "move": "移動", + "move_question": "本当に下書きへ移動しますか?", + "success_shared": "投稿の共有に成功しました", + "success_moved": "下書きへ移動", + "permission_denied": "アクセスが拒否されました", + "permission_text": "本体の設定から eSteem アプリの権限を変更してください。", + "success_rebloged": "リブログしました!", + "already_rebloged": "既にリブログしています!", + "warning": "警告", + "invalid_pincode": "PINコードが間違っています。もう一度確認してやり直してください。", + "remove_alert": "本当に削除しますか?", + "clear_alert": "本当に消去しますか?", + "clear_user_alert": "本当に全てのユーザーデータを消去しますか?", + "clear": "消去", + "cancel": "キャンセル", + "delete": "削除", + "copied": "コピーしました!", + "no_internet": "ネットワークに接続されていません!", + "confirm": "確認", + "removed": "削除しました", + "same_user": "このユーザーは既にリストに追加されています", + "unknow_error": "エラーが発生しました", + "error": "エラー", + "fetch_error": "データを取得できませんでした。もう一度やり直すか info@esteem.app に連絡してください", + "connection_fail": "接続に失敗しました!", + "connection_success": "接続に成功しました!", + "checking": "確認中...", + "not_existing_post": "投稿は存在しません!パーマリンクと投稿者を確認してください。" }, "post": { - "reblog_alert": "Are you sure, you want to reblog?", - "removed_hint": "The post was removed by", - "copy_link": "Copy Link", - "reblogged": "reblogged by", - "sponsored": "SPONSORED", - "open_thread": "Open Thread" + "reblog_alert": "本当にリブログしますか?", + "removed_hint": "投稿は削除されました", + "copy_link": "リンクをコピー", + "reblogged": "リブログしています", + "sponsored": "PR", + "open_thread": "スレッドを開く" }, "drafts": { - "title": "Drafts", - "load_error": "Could not load drafts", - "empty_list": "Nothing here", - "deleted": "Draft deleted" + "title": "下書き", + "load_error": "下書きを読み込めませんでした", + "empty_list": "まだ何もありません", + "deleted": "下書きを削除しました" }, "schedules": { - "title": "Schedules", - "empty_list": "Nothing here", - "deleted": "Scheduled post deleted", - "move": "Move to drafts", - "moved": "Moved to drafts" + "title": "スケジュール", + "empty_list": "まだ何もありません", + "deleted": "予約投稿を削除しました", + "move": "下書きへ移動", + "moved": "下書きへ移動しました" }, "bookmarks": { - "title": "Bookmarks", - "load_error": "Could not load bookmarks", - "empty_list": "Nothing here", - "deleted": "Bookmark removed", - "search": "Search in bookmarks", - "added": "Added to bookmarks", - "add": "Add to bookmarks" + "title": "ブックマーク", + "load_error": "ブックマークを読み込めませんでした", + "empty_list": "まだ何もありません", + "deleted": "ブックマークを削除しました", + "search": "ブックマークを検索", + "added": "ブックマークに追加しました", + "add": "ブックマークに追加" }, "favorites": { - "title": "Favorites", - "load_error": "Could not load favorites", - "empty_list": "Nothing here", - "search": "Search in favorites" + "title": "お気に入り", + "load_error": "お気に入りを読み込めませんでした", + "empty_list": "まだ何もありません", + "search": "お気に入りの検索" }, "auth": { - "invalid_pin": "Invalid pin code, please check and try again", - "invalid_username": "Invalid username, please check and try again", - "already_logged": "You are already logged in, please try to add another account", - "invalid_credentials": "Invalid credentials, please check and try again", - "unknow_error": "Unknown error, please contact us at support@esteem.app" + "invalid_pin": "PINコードが間違っています。もう一度確認してやり直してください。", + "invalid_username": "ユーザー名が間違っています。もう一度確認してやり直してください", + "already_logged": "既にログインしています。他のアカウントを追加してください", + "invalid_credentials": "ログイン情報が間違っています。もう一度確認してやり直してください", + "unknow_error": "不明なエラー。support@esteem.app に連絡してください" }, "payout": { - "potential_payout": "Potential Payout", - "promoted": "Promoted", - "author_payout": "Author Payout", - "curation_payout": "Curation Payout", - "payout_date": "Payout" + "potential_payout": "見込み支払額", + "promoted": "プロモート", + "author_payout": "投稿者支払額", + "curation_payout": "キュレーション支払額", + "payout_date": "支払額" }, "post_dropdown": { - "copy": "copy link", - "reblog": "reblog", - "reply": "reply", - "share": "share", - "bookmarks": "add to bookmarks", - "promote": "promote", - "boost": "boost" + "copy": "リンクをコピー", + "reblog": "リブログ", + "reply": "返信", + "share": "共有", + "bookmarks": "ブックマークに追加", + "promote": "プロモート", + "boost": "ブースト" }, "deep_link": { - "no_existing_user": "No existing user", - "no_existing_post": "No existing post" + "no_existing_user": "ユーザーは存在しません", + "no_existing_post": "投稿は存在しません" }, "search": { - "posts": "Posts", - "comments": "Comments" + "posts": "投稿", + "comments": "コメント" }, "comment_filter": { - "trending": "trending", - "reputation": "reputation", - "votes": "votes", - "age": "age" + "trending": "トレンド", + "reputation": "評判", + "votes": "ヴォート", + "age": "新着順" }, "transfer": { - "from": "From", - "to": "To", - "amount_information": "Drag the slider to adjust the amount", - "amount": "Amount", - "memo": "Memo", - "information": "Are you sure to transfer funds?", - "amount_desc": "Balance", - "memo_desc": "This memo is public", - "to_placeholder": "Username", - "memo_placeholder": "Enter your notes here", - "transfer_token": "Transfer", - "points": "Gift ESTM to someone", - "transfer_to_saving": "Transfer To Saving", - "powerUp": "Power Up", - "withdraw_to_saving": "Withdraw To Saving", - "steemconnect_title": "Steemconnect Transfer", - "next": "NEXT", - "delegate": "Delegate", - "power_down": "Power Down", - "withdraw_steem": "Withdraw Steem", - "withdraw_sbd": "Withdraw Steem Dollar" + "from": "差出人", + "to": "受取人", + "amount_information": "スライドして金額を設定", + "amount": "金額", + "memo": "メモ", + "information": "本当に送金しますか?", + "amount_desc": "残高", + "memo_desc": "このメモは公開されます", + "to_placeholder": "ユーザー名", + "memo_placeholder": "ここに内容を入力してください", + "transfer_token": "送金", + "points": "ESTMを贈る", + "transfer_to_saving": "貯蓄口座に送金", + "powerUp": "パワーアップ", + "withdraw_to_saving": "貯蓄口座に引き出す", + "steemconnect_title": "Steemconnect 送金", + "next": "次へ", + "delegate": "デリゲーション", + "power_down": "パワーダウン", + "withdraw_steem": "Steem を引き出す", + "withdraw_sbd": "Steem Dollar を引き出す" }, "boost": { - "title": "Get eSteem Points", - "buy": "GET ESTM", - "next": "NEXT" + "title": "eSteem ポイントを手に入れる", + "buy": "ESTM を手に入れる", + "next": "次へ" }, "promote": { - "title": "Promote", - "days": "days", - "user": "User", - "permlink": "Post", - "permlinkPlaceholder": "author/permlink", - "information": "Are you sure to promote?" + "title": "プロモート", + "days": "日間", + "user": "ユーザー", + "permlink": "投稿", + "permlinkPlaceholder": "投稿者/パーマリンク", + "information": "本当にプロモートしますか?" }, "boostPost": { - "title": "Boost" + "title": "ブースト" }, "voters_dropdown": { - "rewards": "REWARDS", - "percent": "PERCENT", - "time": "TIME" + "rewards": "報酬", + "percent": "パーセント", + "time": "時間" }, "reblog": { - "title": "Reblog Info" + "title": "リブログ情報" } } diff --git a/src/config/locales/ka-GE.json b/src/config/locales/ka-GE.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ka-GE.json +++ b/src/config/locales/ka-GE.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/kk-KZ.json b/src/config/locales/kk-KZ.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/kk-KZ.json +++ b/src/config/locales/kk-KZ.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ko-KR.json b/src/config/locales/ko-KR.json index a6dd2a431..3a8cddd44 100644 --- a/src/config/locales/ko-KR.json +++ b/src/config/locales/ko-KR.json @@ -55,7 +55,7 @@ "vote_title": "투표 포인트", "reblog_title": "리블로그 포인트", "login_title": "로그인 포인트", - "checkin_title": "Points for heartbeat", + "checkin_title": "체크인 포인트", "checkin_extra_title": "체크인 보너스", "no_activity": "아직 포인트 관련 활동이 없습니다", "outgoing_transfer_description": "", @@ -97,7 +97,13 @@ "days": "일", "day": "일", "steem_dollars": "스팀 달러", - "savings": "안전 금고" + "savings": "안전 금고", + "edit": { + "display_name": "이름", + "about": "소개", + "location": "위치", + "website": "웹사이트" + } }, "settings": { "settings": "설정", @@ -222,7 +228,8 @@ "fetch_error": "서버에서 데이터를 가져오는데 실패했습니다. 다시 시도해보시거나 info@esteem.app로 문의해주세요.", "connection_fail": "연결 실패!", "connection_success": "성공적으로 연결되었습니다", - "checking": "Cheking..." + "checking": "확인 중...", + "not_existing_post": "글이 존재하지 않습니다! permlink와 저자를 확인해주세요." }, "post": { "reblog_alert": "리블로그 하시겠습니까?", @@ -230,7 +237,7 @@ "copy_link": "링크 복사", "reblogged": "리블로그됨", "sponsored": "투표 후원받음", - "open_thread": "Open Thread" + "open_thread": "스레드 열기" }, "drafts": { "title": "임시 보관함", @@ -298,8 +305,9 @@ "age": "작성일" }, "transfer": { + "from": "보낸 사람", "to": "받는 사람", - "amount_information": "Drag the slider to adjust the amount", + "amount_information": "슬라이드를 드래그해서 수량을 설정할 수 있습니다", "amount": "수량", "memo": "메모", "information": "자금을 전송하시겠습니까?", diff --git a/src/config/locales/ks-IN.json b/src/config/locales/ks-IN.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ks-IN.json +++ b/src/config/locales/ks-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ku-TR.json b/src/config/locales/ku-TR.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ku-TR.json +++ b/src/config/locales/ku-TR.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ky-KG.json b/src/config/locales/ky-KG.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ky-KG.json +++ b/src/config/locales/ky-KG.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/lt-LT.json b/src/config/locales/lt-LT.json index 652a10e69..02674a136 100644 --- a/src/config/locales/lt-LT.json +++ b/src/config/locales/lt-LT.json @@ -97,7 +97,13 @@ "days": "d.", "day": "d.", "steem_dollars": "Steem Dollars", - "savings": "Santaupos" + "savings": "Santaupos", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Nustatymai", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/lv-LV.json b/src/config/locales/lv-LV.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/lv-LV.json +++ b/src/config/locales/lv-LV.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/mk-MK.json b/src/config/locales/mk-MK.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/mk-MK.json +++ b/src/config/locales/mk-MK.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/mn-MN.json b/src/config/locales/mn-MN.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/mn-MN.json +++ b/src/config/locales/mn-MN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ms-MY.json b/src/config/locales/ms-MY.json index f3895f6e7..c6d4f69aa 100644 --- a/src/config/locales/ms-MY.json +++ b/src/config/locales/ms-MY.json @@ -97,7 +97,13 @@ "days": "hari", "day": "hari", "steem_dollars": "Steem Dollars", - "savings": "Simpanan" + "savings": "Simpanan", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Tetapan", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ne-NP.json b/src/config/locales/ne-NP.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/ne-NP.json +++ b/src/config/locales/ne-NP.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/nl-NL.json b/src/config/locales/nl-NL.json index c12fc6efa..ea9979437 100644 --- a/src/config/locales/nl-NL.json +++ b/src/config/locales/nl-NL.json @@ -97,7 +97,13 @@ "days": "dagen", "day": "dag", "steem_dollars": "Steem Dollars", - "savings": "Spaarrekening" + "savings": "Spaarrekening", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Instellingen", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/no-NO.json b/src/config/locales/no-NO.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/no-NO.json +++ b/src/config/locales/no-NO.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/pa-IN.json b/src/config/locales/pa-IN.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/pa-IN.json +++ b/src/config/locales/pa-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/pcm-NG.json b/src/config/locales/pcm-NG.json index f78f418b5..696ee0db6 100644 --- a/src/config/locales/pcm-NG.json +++ b/src/config/locales/pcm-NG.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/pl-PL.json b/src/config/locales/pl-PL.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/pl-PL.json +++ b/src/config/locales/pl-PL.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/pt-PT.json b/src/config/locales/pt-PT.json index 152f5a5b8..e027804dd 100644 --- a/src/config/locales/pt-PT.json +++ b/src/config/locales/pt-PT.json @@ -97,7 +97,13 @@ "days": "dias", "day": "dia", "steem_dollars": "Steem Dólares", - "savings": "Poupanças" + "savings": "Poupanças", + "edit": { + "display_name": "Nome a Exibir", + "about": "Sobre", + "location": "Localização", + "website": "Website" + } }, "settings": { "settings": "Configurações", @@ -222,7 +228,8 @@ "fetch_error": "Falha ao buscar dados, por favor tente novamente ou nos informe no info@esteem.app", "connection_fail": "Falha na conexão!", "connection_success": "Conectado com sucesso!", - "checking": "Checando..." + "checking": "A verificar...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Tem certeza de que deseja reblogar?", diff --git a/src/config/locales/ro-RO.json b/src/config/locales/ro-RO.json index 354781269..f8c91fb93 100644 --- a/src/config/locales/ro-RO.json +++ b/src/config/locales/ro-RO.json @@ -97,7 +97,13 @@ "days": "zile", "day": "zi", "steem_dollars": "Steem Dolari", - "savings": "Economii" + "savings": "Economii", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Setări", @@ -222,14 +228,15 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connectare Eșuată!", "connection_success": "Conectat cu succes!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", "removed_hint": "Postarea a fost eliminată de către", "copy_link": "Copiere link", "reblogged": "redistribuit de", - "sponsored": "SPONSORED", + "sponsored": "SPONSORIZAT", "open_thread": "Open Thread" }, "drafts": { @@ -300,10 +307,10 @@ "transfer": { "from": "De la", "to": "Către", - "amount_information": "Drag the slider to adjust the amount", + "amount_information": "Trage glisorul pentru a ajusta cantitatea", "amount": "Sumă", "memo": "Notă", - "information": "Are you sure to transfer funds?", + "information": "Ești sigur că vrei să transferi fonduri?", "amount_desc": "Sold", "memo_desc": "Această notă este publică", "to_placeholder": "Nume de utilizator", @@ -321,7 +328,7 @@ "withdraw_sbd": "Retrage Steem Dolar" }, "boost": { - "title": "Get eSteem Points", + "title": "Câștigă puncte eSteem", "buy": "GET ESTM", "next": "URMĂTORUL" }, diff --git a/src/config/locales/ru-RU.json b/src/config/locales/ru-RU.json index 68eae408f..5ca887b45 100644 --- a/src/config/locales/ru-RU.json +++ b/src/config/locales/ru-RU.json @@ -97,7 +97,13 @@ "days": "д", "day": "д", "steem_dollars": "Доллары Steem", - "savings": "Сейф" + "savings": "Сейф", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Настройки", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sa-IN.json b/src/config/locales/sa-IN.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/sa-IN.json +++ b/src/config/locales/sa-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sk-SK.json b/src/config/locales/sk-SK.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/sk-SK.json +++ b/src/config/locales/sk-SK.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sl-SI.json b/src/config/locales/sl-SI.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/sl-SI.json +++ b/src/config/locales/sl-SI.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sq-AL.json b/src/config/locales/sq-AL.json index 73923eafa..3c206ee4e 100644 --- a/src/config/locales/sq-AL.json +++ b/src/config/locales/sq-AL.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sr-CS.json b/src/config/locales/sr-CS.json index b7e2ab2bb..003b1d626 100644 --- a/src/config/locales/sr-CS.json +++ b/src/config/locales/sr-CS.json @@ -97,7 +97,13 @@ "days": "dana", "day": "dan", "steem_dollars": "Steem dolari", - "savings": "Ušteđevina" + "savings": "Ušteđevina", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Podešavanja", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sv-SE.json b/src/config/locales/sv-SE.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/sv-SE.json +++ b/src/config/locales/sv-SE.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/sw-KE.json b/src/config/locales/sw-KE.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/sw-KE.json +++ b/src/config/locales/sw-KE.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ta-IN.json b/src/config/locales/ta-IN.json index a922688e8..09467c7cc 100644 --- a/src/config/locales/ta-IN.json +++ b/src/config/locales/ta-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/tg-TJ.json b/src/config/locales/tg-TJ.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/tg-TJ.json +++ b/src/config/locales/tg-TJ.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/th-TH.json b/src/config/locales/th-TH.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/th-TH.json +++ b/src/config/locales/th-TH.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/tk-TM.json b/src/config/locales/tk-TM.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/tk-TM.json +++ b/src/config/locales/tk-TM.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/tr-TR.json b/src/config/locales/tr-TR.json index 327995d8f..601a8b9cb 100644 --- a/src/config/locales/tr-TR.json +++ b/src/config/locales/tr-TR.json @@ -97,7 +97,13 @@ "days": "gün içinde düşecek", "day": "gün içinde düşecek", "steem_dollars": "Steem Dolar", - "savings": "Biriktir" + "savings": "Biriktir", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Ayarlar", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/uk-UA.json b/src/config/locales/uk-UA.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/uk-UA.json +++ b/src/config/locales/uk-UA.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ur-IN.json b/src/config/locales/ur-IN.json index f2edaf463..da158d7a8 100644 --- a/src/config/locales/ur-IN.json +++ b/src/config/locales/ur-IN.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/ur-PK.json b/src/config/locales/ur-PK.json index f2edaf463..da158d7a8 100644 --- a/src/config/locales/ur-PK.json +++ b/src/config/locales/ur-PK.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/uz-UZ.json b/src/config/locales/uz-UZ.json index 8de527bba..db117d1ca 100644 --- a/src/config/locales/uz-UZ.json +++ b/src/config/locales/uz-UZ.json @@ -97,7 +97,13 @@ "days": "days", "day": "day", "steem_dollars": "Steem Dollars", - "savings": "Savings" + "savings": "Savings", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Settings", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/vi-VN.json b/src/config/locales/vi-VN.json index 44f8c40f4..a79283642 100644 --- a/src/config/locales/vi-VN.json +++ b/src/config/locales/vi-VN.json @@ -97,7 +97,13 @@ "days": "ngày", "day": "ngày", "steem_dollars": "Steem Dollars", - "savings": "Tiết kiệm" + "savings": "Tiết kiệm", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Cài đặt", @@ -118,7 +124,7 @@ "pincode": "Mã PIN", "reset_pin": "Đặt Lại Mã Pin", "reset": "Thiết lập lại", - "nsfw_content": "Nội dung NSFW", + "nsfw_content": "Nội dung NSFW (nội dung không phù hợp để xem trong môi trường làm việc hoặc gần trẻ em)", "send_feedback": "Gửi phản hồi", "send": "Gửi", "default_footer": "Phần mặc định ở cuối trang", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", @@ -298,6 +305,7 @@ "age": "tuổi" }, "transfer": { + "from": "Từ", "to": "Đến", "amount_information": "Drag the slider to adjust the amount", "amount": "Số lượng", diff --git a/src/config/locales/yo-NG.json b/src/config/locales/yo-NG.json index 51517470a..fba7cb8a5 100644 --- a/src/config/locales/yo-NG.json +++ b/src/config/locales/yo-NG.json @@ -97,7 +97,13 @@ "days": "awon ojo", "day": "ojo", "steem_dollars": "Dollar ti steem", - "savings": "Ipamo" + "savings": "Ipamo", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "Eto", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/zh-CN.json b/src/config/locales/zh-CN.json index 5bcc36352..ca94e1753 100644 --- a/src/config/locales/zh-CN.json +++ b/src/config/locales/zh-CN.json @@ -97,7 +97,13 @@ "days": "天", "day": "天", "steem_dollars": "Steem Dollars", - "savings": "储蓄" + "savings": "储蓄", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "设置", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/config/locales/zh-TW.json b/src/config/locales/zh-TW.json index 285737114..a7beb56c4 100644 --- a/src/config/locales/zh-TW.json +++ b/src/config/locales/zh-TW.json @@ -97,7 +97,13 @@ "days": "天", "day": "天", "steem_dollars": "Steem Dollars", - "savings": "儲蓄" + "savings": "儲蓄", + "edit": { + "display_name": "Display Name", + "about": "About", + "location": "Location", + "website": "Website" + } }, "settings": { "settings": "設定", @@ -222,7 +228,8 @@ "fetch_error": "Fetching data failed, please try again or notify us at info@esteem.app", "connection_fail": "Connection Failed!", "connection_success": "Successfully connected!", - "checking": "Cheking..." + "checking": "Checking...", + "not_existing_post": "The post does not exist! Please check permlink and author." }, "post": { "reblog_alert": "Are you sure, you want to reblog?", diff --git a/src/constants/routeNames.js b/src/constants/routeNames.js index 99c8ee6fe..bbab45cf9 100644 --- a/src/constants/routeNames.js +++ b/src/constants/routeNames.js @@ -15,15 +15,15 @@ export default { LOGIN: `Login${SCREEN_SUFFIX}`, PINCODE: `PinCode${SCREEN_SUFFIX}`, POST: `Post${SCREEN_SUFFIX}`, + PROFILE_EDIT: `ProfileEdit${SCREEN_SUFFIX}`, PROFILE: `Profile${SCREEN_SUFFIX}`, - PROMOTE: `Promote${SCREEN_SUFFIX}`, REBLOGS: `Reblogs${SCREEN_SUFFIX}`, + REDEEM: `Redeem${SCREEN_SUFFIX}`, SEARCH_RESULT: `SearchResult${SCREEN_SUFFIX}`, SETTINGS: `Settings${SCREEN_SUFFIX}`, STEEM_CONNECT: `SteemConnect${SCREEN_SUFFIX}`, TRANSFER: `Transfer${SCREEN_SUFFIX}`, VOTERS: `Voters${SCREEN_SUFFIX}`, - REDEEM: `Redeem${SCREEN_SUFFIX}`, }, DRAWER: { MAIN: `Main${DRAWER_SUFFIX}`, diff --git a/src/constants/steemConnectOptions.js b/src/constants/steemConnectOptions.js index c0a1b731d..4a06ae128 100644 --- a/src/constants/steemConnectOptions.js +++ b/src/constants/steemConnectOptions.js @@ -1,6 +1,7 @@ export const steemConnectOptions = { base_url: 'https://app.steemconnect.com/', client_id: 'esteemapp', - redirect_uri: 'http://127.0.0.1:3415/', // http://127.0.0.1:3415 - scope: 'vote,comment,delete_comment,comment_options,custom_json,claim_reward_balance,offline', + redirect_uri: 'http://127.0.0.1:3415/', + scope: + 'vote,comment,delete_comment,comment_options,custom_json,claim_reward_balance,account_update,offline', }; diff --git a/src/screens/boost/container/boostContainer.js b/src/containers/inAppPurchaseContainer.js similarity index 85% rename from src/screens/boost/container/boostContainer.js rename to src/containers/inAppPurchaseContainer.js index 82d7dbc24..417f2b7e3 100644 --- a/src/screens/boost/container/boostContainer.js +++ b/src/containers/inAppPurchaseContainer.js @@ -1,3 +1,4 @@ +/* eslint-disable no-unused-vars */ import React, { Component } from 'react'; import { connect } from 'react-redux'; import { Platform, Alert } from 'react-native'; @@ -5,15 +6,13 @@ import { withNavigation } from 'react-navigation'; import RNIap, { purchaseErrorListener, purchaseUpdatedListener } from 'react-native-iap'; import { injectIntl } from 'react-intl'; import get from 'lodash/get'; + // Services -import { purchaseOrder } from '../../../providers/esteem/esteem'; -import bugsnag from '../../../config/bugsnag'; +import bugsnag from '../config/bugsnag'; +import { purchaseOrder } from '../providers/esteem/esteem'; // Utilities -import { default as ROUTES } from '../../../constants/routeNames'; - -// Component -import BoostScreen from '../screen/boostScreen'; +import { default as ROUTES } from '../constants/routeNames'; const ITEM_SKUS = Platform.select({ ios: ['099points', '199points', '499points', '999points', '4999points', '9999points'], @@ -26,7 +25,7 @@ class BoostContainer extends Component { this.state = { productList: [], isLoading: true, - isProccesing: false, + isProcessing: false, }; } @@ -41,6 +40,7 @@ class BoostContainer extends Component { this.purchaseUpdateSubscription.remove(); this.purchaseUpdateSubscription = null; } + if (this.purchaseErrorSubscription) { this.purchaseErrorSubscription.remove(); this.purchaseErrorSubscription = null; @@ -74,7 +74,7 @@ class BoostContainer extends Component { } else if (Platform.OS === 'android') { RNIap.consumePurchaseAndroid(token); } - this.setState({ isProccesing: false }); + this.setState({ isProcessing: false }); }) .catch(err => bugsnag.notify(err, report => { @@ -104,7 +104,7 @@ class BoostContainer extends Component { error.debugMessage, ); } - this.setState({ isProccesing: false }); + this.setState({ isProcessing: false }); }); }; @@ -128,7 +128,7 @@ class BoostContainer extends Component { _buyItem = async sku => { const { navigation } = this.props; - await this.setState({ isProccesing: true }); + await this.setState({ isProcessing: true }); if (sku !== 'freePoints') { try { @@ -148,17 +148,19 @@ class BoostContainer extends Component { }; render() { - const { productList, isLoading, isProccesing } = this.state; + const { children } = this.props; + const { productList, isLoading, isProcessing } = this.state; // const FREE_ESTM = { productId: 'freePoints', title: 'free estm' }; return ( - + children && + children({ + // productList: [...productList, FREE_ESTM], + productList, + buyItem: this._buyItem, + isLoading, + isProcessing, + }) ); } } diff --git a/src/containers/index.js b/src/containers/index.js index 70b22e689..5ca7e667e 100644 --- a/src/containers/index.js +++ b/src/containers/index.js @@ -1,5 +1,15 @@ +import InAppPurchaseContainer from './inAppPurchaseContainer'; import PointsContainer from './pointsContainer'; -import TransferContainer from './transferContainer'; +import ProfileContainer from './profileContainer'; +import ProfileEditContainer from './profileEditContainer'; import RedeemContainer from './redeemContainer'; +import TransferContainer from './transferContainer'; -export { PointsContainer, TransferContainer, RedeemContainer }; +export { + InAppPurchaseContainer, + PointsContainer, + ProfileContainer, + ProfileEditContainer, + RedeemContainer, + TransferContainer, +}; diff --git a/src/containers/profileContainer.js b/src/containers/profileContainer.js new file mode 100644 index 000000000..8b979abec --- /dev/null +++ b/src/containers/profileContainer.js @@ -0,0 +1,395 @@ +/* eslint-disable no-unused-vars */ +import React, { Component } from 'react'; +import { connect } from 'react-redux'; +import { withNavigation } from 'react-navigation'; +import { get, has } from 'lodash'; +import { Alert } from 'react-native'; + +// Providers +import { + followUser, + unfollowUser, + ignoreUser, + getFollows, + getRepliesByLastUpdate, + getUserComments, + getUser, + getIsFollowing, + getIsMuted, +} from '../providers/steem/dsteem'; + +// Esteem providers +import { getIsFavorite, addFavorite, removeFavorite } from '../providers/esteem/esteem'; + +// Utilitites +import { getRcPower, getVotingPower } from '../utils/manaBar'; + +// Constants +import { default as ROUTES } from '../constants/routeNames'; + +class ProfileContainer extends Component { + constructor(props) { + super(props); + + this.state = { + comments: [], + follows: {}, + forceLoadPost: false, + isFavorite: false, + isFollowing: false, + isMuted: false, + isProfileLoading: false, + isReady: false, + isOwnProfile: !has(props, 'navigation.state.params.username'), + user: null, + quickProfile: { + reputation: get(props, 'navigation.state.params.reputation', ''), + name: get(props, 'navigation.state.params.username', ''), + }, + }; + } + + componentDidMount() { + const { + navigation, + isConnected, + isLoggedIn, + currentAccount: { name: currentAccountUsername }, + } = this.props; + const username = get(navigation, 'state.params.username'); + const { isOwnProfile } = this.state; + let targetUsername = currentAccountUsername; + + if (!isConnected) return; + + if (!isLoggedIn && !username) { + navigation.navigate(ROUTES.SCREENS.LOGIN); + return; + } + + if (!isOwnProfile) { + targetUsername = username; + } + + this._loadProfile(targetUsername); + } + + componentWillReceiveProps(nextProps) { + if (!nextProps.isConnected) return; + + const { isLoggedIn, navigation } = this.props; + const { isOwnProfile } = this.state; + + if (isLoggedIn && !nextProps.isLoggedIn) { + navigation.navigate(ROUTES.SCREENS.LOGIN); + return; + } + + if (isOwnProfile) { + const { user } = this.state; + const { activeBottomTab, currentAccount } = this.props; + + const currentUsername = + get(currentAccount, 'name') !== get(nextProps, 'currentAccount.name') && + get(nextProps, 'currentAccount.name'); + const isActiveTabChanged = + activeBottomTab !== get(nextProps, 'activeBottomTab') && + get(nextProps, 'activeBottomTab') === ROUTES.TABBAR.PROFILE; + + if ((isActiveTabChanged && user) || currentUsername) { + this._loadProfile(get(nextProps, 'currentAccount.name')); + } + } + } + + _getReplies = async user => { + const { isOwnProfile } = this.state; + let repliesAction; + + if (!isOwnProfile) { + repliesAction = getUserComments; + } else { + repliesAction = getRepliesByLastUpdate; + } + + await repliesAction({ start_author: user, limit: 10 }).then(result => { + this.setState({ + comments: result, + }); + }); + }; + + _handleFollowUnfollowUser = async isFollowAction => { + const { isFollowing, username } = this.state; + const { currentAccount, pinCode } = this.props; + const follower = get(currentAccount, 'name', ''); + const following = username; + + let followAction; + + this.setState({ + isProfileLoading: true, + }); + + if (isFollowAction && !isFollowing) { + followAction = followUser; + } else { + followAction = unfollowUser; + } + + followAction(currentAccount, pinCode, { + follower, + following, + }) + .then(() => { + this._profileActionDone(); + }) + .catch(err => { + this._profileActionDone(err); + }); + }; + + _handleMuteUnmuteUser = isMuteAction => { + this.setState({ + isProfileLoading: true, + }); + + if (isMuteAction) { + this._muteUser(); + } else { + this._handleFollowUnfollowUser(); + } + }; + + _muteUser = () => { + const { username } = this.state; + const { currentAccount, pinCode } = this.props; + const follower = currentAccount.name; + const following = username; + + ignoreUser(currentAccount, pinCode, { + follower, + following, + }) + .then(() => { + this._profileActionDone(); + }) + .catch(err => { + this._profileActionDone(err); + }); + }; + + _profileActionDone = (error = null) => { + const { username } = this.state; + + if (error) { + this.setState( + { + error, + }, + () => Alert.alert(get(error, 'message') || error.toString()), + ); + } else { + this._fetchProfile(username, true); + } + }; + + _fetchProfile = async (username = null, isProfileAction = false) => { + const { username: _username, isFollowing, isMuted, isOwnProfile } = this.state; + + if (username) { + const { currentAccount } = this.props; + let _isFollowing; + let _isMuted; + let isFavorite; + let follows; + + if (!isOwnProfile) { + _isFollowing = await getIsFollowing(username, currentAccount.name); + + _isMuted = _isFollowing ? false : await getIsMuted(username, currentAccount.name); + + getIsFavorite(username, currentAccount.name).then(isFav => { + isFavorite = isFav; + }); + } + + try { + follows = await getFollows(username); + } catch (err) { + follows = null; + } + + if (isProfileAction && (isFollowing === _isFollowing && isMuted === _isMuted)) { + this._fetchProfile(_username, true); + } else { + this.setState({ + follows, + isFollowing: _isFollowing, + isMuted: _isMuted, + isFavorite, + isReady: true, + isProfileLoading: false, + }); + } + } + }; + + _loadProfile = async (username = null) => { + let user; + + try { + user = await getUser(username); + this._fetchProfile(username); + } catch (error) { + this._profileActionDone(error); + } + + this.setState(prevState => ({ + quickProfile: { + ...prevState.quickProfile, + display_name: get(user, 'display_name'), + reputation: get(user, 'reputation'), + }, + user, + username, + })); + + this._getReplies(username); + }; + + _handleFollowsPress = async isFollowingPress => { + const { navigation } = this.props; + const { username, follows } = this.state; + const count = get(follows, !isFollowingPress ? 'follower_count' : 'following_count'); + + navigation.navigate({ + routeName: ROUTES.SCREENS.FOLLOWS, + params: { + isFollowingPress, + count, + username, + }, + key: `${username}${count}`, + }); + }; + + _handleOnFavoritePress = (isFavorite = false) => { + const { currentAccount } = this.props; + const { username } = this.state; + let favoriteAction; + + if (isFavorite) { + favoriteAction = removeFavorite; + } else { + favoriteAction = addFavorite; + } + + favoriteAction(currentAccount.name, username).then(() => { + this.setState({ isFavorite: !isFavorite }); + }); + }; + + _handleOnBackPress = () => { + const { navigation } = this.props; + const navigationParams = get(navigation.state, 'params'); + + if (get(navigationParams, 'fetchData')) { + navigationParams.fetchData(); + } + }; + + _changeForceLoadPostState = value => { + this.setState({ forceLoadPost: value }); + }; + + _handleOnPressProfileEdit = () => { + const { navigation, currentAccount } = this.props; + + navigation.navigate({ + routeName: ROUTES.SCREENS.PROFILE_EDIT, + params: { + fetchUser: () => this.setState({ user: currentAccount }), + }, + }); + }; + + render() { + const { + avatar, + comments, + error, + follows, + forceLoadPost, + isFavorite, + isFollowing, + isMuted, + isOwnProfile, + isProfileLoading, + isReady, + quickProfile, + user, + username, + } = this.state; + const { currency, isDarkTheme, isLoggedIn, navigation, children } = this.props; + const activePage = get(navigation.state.params, 'state', 0); + const { currencyRate, currencySymbol } = currency; + + let votingPower; + let resourceCredits; + + if (user) { + votingPower = getVotingPower(user).toFixed(1); + resourceCredits = getRcPower(user).toFixed(1); + } + + return ( + children && + children({ + about: get(user, 'about.profile'), + activePage, + avatar, + setEstimatedWalletValue: this._setEstimatedWalletValue, + changeForceLoadPostState: this._changeForceLoadPostState, + comments, + currency, + currencyRate, + currencySymbol, + votingPower, + resourceCredits, + error, + follows, + forceLoadPost, + getReplies: () => this._getReplies(username), + handleFollowUnfollowUser: this._handleFollowUnfollowUser, + handleMuteUnmuteUser: this._handleMuteUnmuteUser, + handleOnBackPress: this._handleOnBackPress, + handleOnFavoritePress: this._handleOnFavoritePress, + handleOnFollowsPress: this._handleFollowsPress, + handleOnPressProfileEdit: this._handleOnPressProfileEdit, + isDarkTheme, + isFavorite, + isFollowing, + isLoggedIn, + isMuted, + isOwnProfile, + isProfileLoading, + isReady, + quickProfile, + selectedUser: user, + username, + }) + ); + } +} +const mapStateToProps = state => ({ + currency: state.application.currency, + isConnected: state.application.isConnected, + isDarkTheme: state.application.isDarkTheme, + isLoggedIn: state.application.isLoggedIn, + pinCode: state.application.pin, + activeBottomTab: state.ui.activeBottomTab, + currentAccount: state.account.currentAccount, +}); + +export default connect(mapStateToProps)(withNavigation(ProfileContainer)); diff --git a/src/containers/profileEditContainer.js b/src/containers/profileEditContainer.js new file mode 100644 index 000000000..e8be93e0a --- /dev/null +++ b/src/containers/profileEditContainer.js @@ -0,0 +1,214 @@ +import { Component } from 'react'; +import { Alert } from 'react-native'; +import { connect } from 'react-redux'; +import { injectIntl } from 'react-intl'; +import ImagePicker from 'react-native-image-crop-picker'; +import get from 'lodash/get'; +import { withNavigation } from 'react-navigation'; + +import { uploadImage } from '../providers/esteem/esteem'; + +import { profileUpdate } from '../providers/steem/dsteem'; +import { updateCurrentAccount } from '../redux/actions/accountAction'; + +// import ROUTES from '../constants/routeNames'; + +const FORM_DATA = [ + { + valueKey: 'name', + type: 'text', + label: 'display_name', + placeholder: '', + }, + { + valueKey: 'about', + type: 'text', + label: 'about', + placeholder: '', + }, + { + valueKey: 'location', + type: 'text', + label: 'location', + placeholder: '', + }, + { + valueKey: 'website', + type: 'text', + label: 'website', + placeholder: '', + }, +]; + +class ProfileEditContainer extends Component { + /* Props + * ------------------------------------------------ + * @prop { type } name - Description.... + */ + + constructor(props) { + super(props); + this.state = { + isLoading: false, + about: get(props.currentAccount, 'about.profile.about'), + name: get(props.currentAccount, 'about.profile.name'), + location: get(props.currentAccount, 'about.profile.location'), + website: get(props.currentAccount, 'about.profile.website'), + coverUrl: get(props.currentAccount, 'about.profile.cover_image'), + avatarUrl: get(props.currentAccount, 'avatar'), + }; + } + + // Component Life Cycles + + // Component Functions + + _handleOnItemChange = (val, item) => { + this.setState({ [item]: val }); + }; + + _uploadImage = (media, action) => { + const { intl } = this.props; + + this.setState({ isLoading: true }); + uploadImage(media) + .then(res => { + if (res.data && res.data.url) { + this.setState({ [action]: res.data.url, isLoading: false }); + } + }) + .catch(error => { + if (error) { + Alert.alert( + intl.formatMessage({ + id: 'alert.fail', + }), + error.message || error.toString(), + ); + } + this.setState({ isLoading: false }); + }); + }; + + _handleMediaAction = (type, uploadAction) => { + if (type === 'camera') { + this._handleOpenCamera(uploadAction); + } else if (type === 'image') { + this._handleOpenImagePicker(uploadAction); + } + }; + + _handleOpenImagePicker = action => { + ImagePicker.openPicker({ + includeBase64: true, + }) + .then(image => { + this._handleMediaOnSelected(image, action); + }) + .catch(e => { + this._handleMediaOnSelectFailure(e); + }); + }; + + _handleOpenCamera = action => { + ImagePicker.openCamera({ + includeBase64: true, + }) + .then(image => { + this._handleMediaOnSelected(image, action); + }) + .catch(e => { + this._handleMediaOnSelectFailure(e); + }); + }; + + _handleMediaOnSelected = (media, action) => { + this.setState({ isLoading: true }, () => { + this._uploadImage(media, action); + }); + }; + + _handleMediaOnSelectFailure = error => { + const { intl } = this.props; + + if (get(error, 'code') === 'E_PERMISSION_MISSING') { + Alert.alert( + intl.formatMessage({ + id: 'alert.permission_denied', + }), + intl.formatMessage({ + id: 'alert.permission_text', + }), + ); + } + }; + + _handleOnSubmit = async () => { + const { currentAccount, pinCode, dispatch, navigation, intl } = this.props; + const { name, location, website, about, coverUrl, avatarUrl } = this.state; + + await this.setState({ isLoading: true }); + + const params = { + profile_image: avatarUrl, + cover_image: coverUrl, + name, + website, + about, + location, + }; + + await profileUpdate(params, pinCode, currentAccount) + .then(async () => { + const _currentAccount = { ...currentAccount, display_name: name, avatar: avatarUrl }; + _currentAccount.about.profile = { ...params }; + + dispatch(updateCurrentAccount(_currentAccount)); + + navigation.state.params.fetchUser(); + navigation.goBack(); + }) + .catch(error => { + Alert.alert( + intl.formatMessage({ + id: 'alert.fail', + }), + get(error, 'message', error.toString()), + ); + }); + + this.setState({ isLoading: false }); + }; + + render() { + const { children, currentAccount, isDarkTheme } = this.props; + const { isLoading, name, location, website, about, coverUrl, avatarUrl } = this.state; + + return ( + children && + children({ + about, + avatarUrl, + coverUrl, + currentAccount, + formData: FORM_DATA, + handleMediaAction: this._handleMediaAction, + handleOnItemChange: this._handleOnItemChange, + handleOnSubmit: this._handleOnSubmit, + isDarkTheme, + isLoading, + location, + name, + website, + }) + ); + } +} + +const mapStateToProps = state => ({ + currentAccount: state.account.currentAccount, + isDarkTheme: state.application.isDarkTheme, + pinCode: state.application.pin, +}); + +export default connect(mapStateToProps)(injectIntl(withNavigation(ProfileEditContainer))); diff --git a/src/navigation/baseNavigator.js b/src/navigation/baseNavigator.js index 92e457f81..9b1dbc91c 100644 --- a/src/navigation/baseNavigator.js +++ b/src/navigation/baseNavigator.js @@ -7,8 +7,7 @@ import ROUTES from '../constants/routeNames'; // Components import { Icon, IconContainer } from '../components/icon'; import { Home, Notification, Profile, Points } from '../screens'; -import { PostButton } from '../components'; -import { BottomTabBar } from '../components/bottomTabBar'; +import { PostButton, BottomTabBar } from '../components'; const BaseNavigator = createBottomTabNavigator( { diff --git a/src/navigation/routes.js b/src/navigation/routes.js index 94323118a..d5ffb02d7 100644 --- a/src/navigation/routes.js +++ b/src/navigation/routes.js @@ -18,6 +18,7 @@ import { PinCode, Post, Profile, + ProfileEdit, Reblogs, Redeem, SearchResult, @@ -55,6 +56,12 @@ const stackNavigatior = createStackNavigator( header: () => null, }, }, + [ROUTES.SCREENS.PROFILE_EDIT]: { + screen: ProfileEdit, + navigationOptions: { + header: () => null, + }, + }, [ROUTES.SCREENS.POST]: { screen: Post, navigationOptions: { diff --git a/src/providers/esteem/esteem.js b/src/providers/esteem/esteem.js index e8e049903..5ff899b34 100644 --- a/src/providers/esteem/esteem.js +++ b/src/providers/esteem/esteem.js @@ -300,7 +300,14 @@ export const getImages = username => api.get(`api/images/${username}`).then(resp export const addMyImage = (user, url) => api.post('/image', { username: user, image_url: url }); -export const uploadImage = file => { +export const uploadImage = media => { + const file = { + uri: media.path, + type: media.mime, + name: media.filename || `IMG_${Math.random()}.JPG`, + size: media.size, + }; + const fData = new FormData(); fData.append('postimage', file); diff --git a/src/providers/steem/dsteem.js b/src/providers/steem/dsteem.js index aa72ac0c0..de99ee966 100644 --- a/src/providers/steem/dsteem.js +++ b/src/providers/steem/dsteem.js @@ -1,7 +1,8 @@ +/* eslint-disable camelcase */ import { Client, PrivateKey } from 'dsteem'; import steemconnect from 'steemconnect'; import Config from 'react-native-config'; -import get from 'lodash/get'; +import { get, has } from 'lodash'; import { getServer } from '../../realm/realm'; import { getUnreadActivityCount } from '../esteem/esteem'; @@ -117,45 +118,44 @@ export const getState = async path => { export const getUser = async user => { try { const account = await client.database.getAccounts([user]); + const _account = { ...account[0] }; + let unreadActivityCount; if (account && account.length < 1) return null; - // get global properties to calculate Steem Power const globalProperties = await client.database.getDynamicGlobalProperties(); const rcPower = await client.call('rc_api', 'find_rc_accounts', { accounts: [user] }); - let unreadActivityCount; try { unreadActivityCount = await getUnreadActivityCount({ user }); } catch (error) { unreadActivityCount = 0; } - account[0].reputation = getReputation(account[0].reputation); - account[0].username = account[0].name; - account[0].unread_activity_count = unreadActivityCount; - account[0].rc_manabar = rcPower.rc_accounts[0].rc_manabar; - account[0].steem_power = await vestToSteem( - account[0].vesting_shares, + _account.reputation = getReputation(_account.reputation); + _account.username = _account.name; + _account.unread_activity_count = unreadActivityCount; + _account.rc_manabar = rcPower.rc_accounts[0].rc_manabar; + _account.steem_power = await vestToSteem( + _account.vesting_shares, globalProperties.total_vesting_shares, globalProperties.total_vesting_fund_steem, ); - account[0].received_steem_power = await vestToSteem( - get(account[0], 'received_vesting_shares'), + _account.received_steem_power = await vestToSteem( + get(_account, 'received_vesting_shares'), get(globalProperties, 'total_vesting_shares'), get(globalProperties, 'total_vesting_fund_steem'), ); - account[0].delegated_steem_power = await vestToSteem( - get(account[0], 'delegated_vesting_shares'), + _account.delegated_steem_power = await vestToSteem( + get(_account, 'delegated_vesting_shares'), get(globalProperties, 'total_vesting_shares'), get(globalProperties, 'total_vesting_fund_steem'), ); - account[0].about = - get(account[0], 'json_metadata') && JSON.parse(get(account[0], 'json_metadata')); - account[0].avatar = getAvatar(get(account[0], 'about')); - account[0].display_name = getName(get(account[0], 'about')); + _account.about = has(_account, 'json_metadata') && JSON.parse(get(_account, 'json_metadata')); + _account.avatar = getAvatar(get(_account, 'about')); + _account.display_name = getName(get(_account, 'about')); - return account[0]; + return _account; } catch (error) { return Promise.reject(error); } @@ -1167,6 +1167,63 @@ export const boost = (currentAccount, pinCode, point, permlink, author) => { return Promise.reject(new Error('Something went wrong!')); }; +export const profileUpdate = async (params, pin, currentAccount) => { + const digitPinCode = getDigitPinCode(pin); + const key = getActiveKey(get(currentAccount, 'local'), digitPinCode); + + if (get(currentAccount, 'local.authType') === AUTH_TYPE.STEEM_CONNECT) { + const token = decryptKey(get(currentAccount, 'local.accessToken'), digitPinCode); + const api = new steemconnect.Client({ + accessToken: token, + }); + + const _params = { + account: get(currentAccount, 'name'), + memo_key: get(currentAccount, 'memo_key'), + json_metadata: jsonStringify(params), + }; + + const opArray = [['account_update', _params]]; + + return api + .broadcast(opArray) + .then(resp => resp.result) + .catch(error => console.log(error)); + } + + if (key) { + const opArray = [ + [ + 'account_update', + { + account: get(currentAccount, 'name'), + memo_key: get(currentAccount, 'memo_key'), + json_metadata: jsonStringify({ profile: params }), + }, + ], + ]; + + const privateKey = PrivateKey.fromString(key); + + return new Promise((resolve, reject) => { + client.broadcast + .sendOperations(opArray, privateKey) + .then(result => { + resolve(result); + }) + .catch(error => { + if (get(error, 'jse_info.code') === 4030100) { + error.message = + 'We noticed that your device has incorrect date or time. Please fix Date & Time or Set Automatically and try again.'; + } + reject(error); + }); + }); + } + + return Promise.reject(new Error('You dont have permission!')); +}; + // HELPERS const getAnyPrivateKey = (local, pin) => { diff --git a/src/screens/application/container/applicationContainer.js b/src/screens/application/container/applicationContainer.js index 4d329d1b7..5235efd87 100644 --- a/src/screens/application/container/applicationContainer.js +++ b/src/screens/application/container/applicationContainer.js @@ -487,13 +487,6 @@ class ApplicationContainer extends Component { const isExistUser = await getExistUser(); realmObject[0].name = currentUsername; - dispatch( - updateCurrentAccount({ - name: realmObject[0].username, - avatar: realmObject[0].avatar, - authType: realmObject[0].authType, - }), - ); // If in dev mode pin code does not show if ((!isExistUser || !pinCode) && _isPinCodeOpen) { dispatch(openPinCodeModal()); diff --git a/src/screens/application/screen/applicationScreen.js b/src/screens/application/screen/applicationScreen.js index 8d51742a5..7ffe46cd3 100644 --- a/src/screens/application/screen/applicationScreen.js +++ b/src/screens/application/screen/applicationScreen.js @@ -9,8 +9,7 @@ import { ReduxNavigation } from '../../../navigation/reduxNavigation'; import { toastNotification as toastNotificationAction } from '../../../redux/actions/uiAction'; // Components -import { NoInternetConnection } from '../../../components/basicUIElements'; -import { ToastNotification } from '../../../components/toastNotification'; +import { ToastNotification, NoInternetConnection } from '../../../components'; // Themes (Styles) import darkTheme from '../../../themes/darkTheme'; diff --git a/src/screens/bookmarks/screen/bookmarksScreen.js b/src/screens/bookmarks/screen/bookmarksScreen.js index 7044e806a..130ac1609 100644 --- a/src/screens/bookmarks/screen/bookmarksScreen.js +++ b/src/screens/bookmarks/screen/bookmarksScreen.js @@ -5,13 +5,7 @@ import ScrollableTabView from 'react-native-scrollable-tab-view'; import ActionSheet from 'react-native-actionsheet'; // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { - PostCardPlaceHolder, - UserListItem, - WalletDetailsPlaceHolder, -} from '../../../components/basicUIElements'; -import { TabBar } from '../../../components/tabBar'; +import { UserListItem, WalletDetailsPlaceHolder, BasicHeader, TabBar } from '../../../components'; // Styles import globalStyles from '../../../globalStyles'; diff --git a/src/screens/boost/index.js b/src/screens/boost/index.js deleted file mode 100644 index d24bdad11..000000000 --- a/src/screens/boost/index.js +++ /dev/null @@ -1,4 +0,0 @@ -import Boost from './container/boostContainer'; - -export { Boost }; -export default Boost; diff --git a/src/screens/boost/screen/boostScreen.js b/src/screens/boost/screen/boostScreen.js index eb973c5da..31d21dfe6 100644 --- a/src/screens/boost/screen/boostScreen.js +++ b/src/screens/boost/screen/boostScreen.js @@ -1,13 +1,13 @@ -import React, { PureComponent, Fragment } from 'react'; -import { injectIntl } from 'react-intl'; +import React, { Fragment } from 'react'; import { View, Text } from 'react-native'; import get from 'lodash/get'; +import { useIntl } from 'react-intl'; // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { MainButton } from '../../../components/mainButton'; -import { Icon } from '../../../components/icon'; -import { BoostPlaceHolder } from '../../../components/basicUIElements'; +import { BasicHeader, Icon, MainButton, BoostPlaceHolder } from '../../../components'; + +// Container +import { InAppPurchaseContainer } from '../../../containers'; // Styles import globalStyles from '../../../globalStyles'; @@ -15,95 +15,83 @@ import styles from './boostScreenStyles'; const DEALS = { '9999points': 'BEST DEAL!', '4999points': 'POPULAR!' }; -class BoostScreen extends PureComponent { - /* Props - * ------------------------------------------------ - * @prop { type } name - Description.... - */ - - constructor(props) { - super(props); - this.state = { - selectedBoost: 0, - }; - } - - // Component Life Cycles - - // Component Functions - _renderDeal = item => { - if (DEALS[item.productId]) { - return ( - - - {DEALS[item.productId]} - - - - ); - } - }; - - _getTitle = title => { - let _title = title.toUpperCase(); - - if (_title.includes('(ESTEEM)')) { - _title = _title.replace('(ESTEEM)', ''); - } - - return _title; - }; - - render() { - const { intl, buyItem, productList, isLoading, isProccesing } = this.props; - const { selectedBoost } = this.state; - +const _renderDeal = item => { + if (DEALS[item.productId]) { return ( - - - - {isLoading ? ( - - ) : ( - productList.map(item => ( - - {this._renderDeal(item)} - - buyItem(item.productId)} - height={50} - text={intl.formatMessage({ - id: 'boost.buy', - })} - isDisable={isProccesing} - isLoading={false} - > - - {this._getTitle(get(item, 'title'))} - - - - - - - - - {get(item, 'localizedPrice', null) && ( - {get(item, 'localizedPrice', 0)} - )} - - - )) - )} + + + {DEALS[item.productId]} + + ); } -} -export default injectIntl(BoostScreen); + return null; +}; + +const _getTitle = title => { + let _title = title.toUpperCase(); + + if (_title.includes('(ESTEEM)')) { + _title = _title.replace('(ESTEEM)', ''); + } + + return _title; +}; + +const BoostScreen = () => { + const intl = useIntl(); + + return ( + + {({ buyItem, productList, isLoading, isProcessing }) => ( + + + + {isLoading ? ( + + ) : ( + productList.map(item => ( + + {_renderDeal(item)} + + buyItem(item.productId)} + height={50} + text={intl.formatMessage({ + id: 'boost.buy', + })} + isDisable={isProcessing} + isLoading={false} + > + + {_getTitle(get(item, 'title'))} + + + + + + + + + {get(item, 'localizedPrice', null) && ( + {get(item, 'localizedPrice', 0)} + )} + + + )) + )} + + )} + + ); +}; + +export default BoostScreen; diff --git a/src/screens/drafts/screen/draftsScreen.js b/src/screens/drafts/screen/draftsScreen.js index da783cbc2..4f2d18817 100644 --- a/src/screens/drafts/screen/draftsScreen.js +++ b/src/screens/drafts/screen/draftsScreen.js @@ -11,10 +11,7 @@ import { catchDraftImage } from '../../../utils/image'; import { getFormatedCreatedDate } from '../../../utils/time'; // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { PostListItem } from '../../../components/postListItem'; -import { PostCardPlaceHolder } from '../../../components/basicUIElements'; -import { TabBar } from '../../../components/tabBar'; +import { BasicHeader, TabBar, PostListItem, PostCardPlaceHolder } from '../../../components'; // Styles import globalStyles from '../../../globalStyles'; diff --git a/src/screens/editor/container/editorContainer.js b/src/screens/editor/container/editorContainer.js index 4a61e5a1c..3db98c28b 100644 --- a/src/screens/editor/container/editorContainer.js +++ b/src/screens/editor/container/editorContainer.js @@ -42,7 +42,6 @@ class EditorContainer extends Component { autoFocusText: false, draftId: null, draftPost: null, - isCameraOrPickerOpen: false, isDraftSaved: false, isDraftSaving: false, isEdit: false, @@ -141,8 +140,6 @@ class EditorContainer extends Component { }; _handleRoutingAction = routingAction => { - this.setState({ isCameraOrPickerOpen: true }); - if (routingAction === 'camera') { this._handleOpenCamera(); } else if (routingAction === 'image') { @@ -175,7 +172,7 @@ class EditorContainer extends Component { }; _handleMediaOnSelected = media => { - this.setState({ isCameraOrPickerOpen: false, isUploading: true }, () => { + this.setState({ isUploading: true }, () => { this._uploadImage(media); }); // For new image api @@ -189,33 +186,27 @@ class EditorContainer extends Component { _uploadImage = media => { const { intl } = this.props; - const file = { - uri: media.path, - type: media.mime, - name: media.filename || `IMG_${Math.random()}.JPG`, - size: media.size, - }; - - uploadImage(file) + uploadImage(media) .then(res => { if (res.data && res.data.url) { this.setState({ uploadedImage: res.data, isUploading: false }); } }) .catch(error => { - Alert.alert( - intl.formatMessage({ - id: 'alert.fail', - }), - error.message || error.toString(), - ); + if (error) { + Alert.alert( + intl.formatMessage({ + id: 'alert.fail', + }), + error.message || error.toString(), + ); + } this.setState({ isUploading: false }); }); }; _handleMediaOnSelectFailure = error => { const { intl } = this.props; - this.setState({ isCameraOrPickerOpen: false }); if (get(error, 'code') === 'E_PERMISSION_MISSING') { Alert.alert( @@ -567,7 +558,6 @@ class EditorContainer extends Component { const { autoFocusText, draftPost, - isCameraOrPickerOpen, isDraftSaved, isDraftSaving, isEdit, @@ -589,7 +579,6 @@ class EditorContainer extends Component { handleOnImagePicker={this._handleRoutingAction} handleOnSubmit={this._handleSubmit} initialEditor={this._initialEditor} - isCameraOrPickerOpen={isCameraOrPickerOpen} isDarkTheme={isDarkTheme} isDraftSaved={isDraftSaved} isDraftSaving={isDraftSaving} diff --git a/src/screens/editor/screen/editorScreen.js b/src/screens/editor/screen/editorScreen.js index a25341111..439209953 100644 --- a/src/screens/editor/screen/editorScreen.js +++ b/src/screens/editor/screen/editorScreen.js @@ -7,9 +7,14 @@ import get from 'lodash/get'; import { getWordsCount } from '../../../utils/editor'; // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { TitleArea, TagArea, TextArea, SummaryArea } from '../../../components/editorElements'; -import { PostForm } from '../../../components/postForm'; +import { + BasicHeader, + TitleArea, + TagArea, + TextArea, + SummaryArea, + PostForm, +} from '../../../components'; // Styles import globalStyles from '../../../globalStyles'; diff --git a/src/screens/follows/screen/followsScreen.js b/src/screens/follows/screen/followsScreen.js index 3995d6311..4f8a7981b 100644 --- a/src/screens/follows/screen/followsScreen.js +++ b/src/screens/follows/screen/followsScreen.js @@ -6,8 +6,7 @@ import { injectIntl } from 'react-intl'; // Constants // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { UserListItem } from '../../../components/basicUIElements'; +import { BasicHeader, UserListItem } from '../../../components'; // Utils import styles from './followScreenStyles'; diff --git a/src/screens/home/screen/homeScreen.js b/src/screens/home/screen/homeScreen.js index ebc439670..5be76eaa9 100644 --- a/src/screens/home/screen/homeScreen.js +++ b/src/screens/home/screen/homeScreen.js @@ -4,9 +4,7 @@ import ScrollableTabView from 'react-native-scrollable-tab-view'; import { injectIntl } from 'react-intl'; // Components -import { TabBar } from '../../../components/tabBar'; -import { Posts } from '../../../components/posts'; -import { Header } from '../../../components/header'; +import { TabBar, Posts, Header } from '../../../components'; // Styles import styles from './homeStyles'; @@ -23,8 +21,6 @@ class HomeScreen extends PureComponent { render() { const { currentAccount, intl, isLoggedIn } = this.props; - let tag; - return (
@@ -50,7 +46,7 @@ class HomeScreen extends PureComponent { diff --git a/src/screens/index.js b/src/screens/index.js index 68cdd34f2..3a1ad20db 100755 --- a/src/screens/index.js +++ b/src/screens/index.js @@ -1,5 +1,4 @@ import { Bookmarks } from './bookmarks'; -import { Boost } from './boost'; import { Drafts } from './drafts'; import { Editor } from './editor'; import { Follows } from './follows'; @@ -10,14 +9,16 @@ import { Notification } from './notification'; import { PinCode } from './pinCode'; import { Points } from './points'; import { Post } from './post'; -import { Profile } from './profile'; import { SearchResult } from './searchResult'; import { Settings } from './settings'; -import Voters from './voters'; -import SteemConnect from './steem-connect/steemConnect'; -import Transfer from './transfer'; +import Boost from './boost/screen/boostScreen'; +import Profile from './profile/screen/profileScreen'; +import ProfileEdit from './profileEdit/screen/profileEditScreen'; import Reblogs from './reblogs'; import Redeem from './redeem/screen/redeemScreen'; +import SteemConnect from './steem-connect/steemConnect'; +import Transfer from './transfer'; +import Voters from './voters'; export { Bookmarks, @@ -33,11 +34,12 @@ export { Points, Post, Profile, + ProfileEdit, + Reblogs, + Redeem, SearchResult, Settings, SteemConnect, Transfer, Voters, - Reblogs, - Redeem, }; diff --git a/src/screens/login/screen/loginScreen.js b/src/screens/login/screen/loginScreen.js index 9282075b3..f466ad59f 100644 --- a/src/screens/login/screen/loginScreen.js +++ b/src/screens/login/screen/loginScreen.js @@ -8,13 +8,15 @@ import { injectIntl } from 'react-intl'; import SteemConnect from '../../steem-connect/steemConnect'; // Internal Components -import { FormInput } from '../../../components/formInput'; -import { InformationArea } from '../../../components/informationArea'; -import { LoginHeader } from '../../../components/loginHeader'; -import { MainButton } from '../../../components/mainButton'; -import { Modal } from '../../../components'; -import { TabBar } from '../../../components/tabBar'; -import { TextButton } from '../../../components/buttons'; +import { + FormInput, + InformationArea, + LoginHeader, + MainButton, + Modal, + TabBar, + TextButton, +} from '../../../components'; // Constants import { default as ROUTES } from '../../../constants/routeNames'; @@ -102,7 +104,7 @@ class LoginScreen extends PureComponent { onKeyboardWillShow={() => this.setState({ keyboardIsOpen: true })} onKeyboardWillHide={() => this.setState({ keyboardIsOpen: false })} enableAutoAutomaticScroll={Platform.OS === 'ios'} - contentContainerStyle={{ flexGrow: 1 }} + contentContainerStyle={styles.formWrapper} > { - const { navigation, isLoggedIn, currentAccount } = this.props; - const selectedUser = get(navigation.state, 'params'); - - if (!isLoggedIn && !selectedUser) { - navigation.navigate(ROUTES.SCREENS.LOGIN); - return; - } - - if (get(selectedUser, 'username', false) && selectedUser.username !== currentAccount.name) { - this._loadProfile(selectedUser.username); - - if (selectedUser.username) { - const selectedQuickProfile = { - reputation: selectedUser.reputation, - name: selectedUser.username, - }; - - this.setState({ selectedQuickProfile }); - } - - this.setState({ isReverseHeader: true }); - } else { - this._loadProfile(currentAccount.name); - } - }; - - componentWillReceiveProps(nextProps) { - const { activeBottomTab, currentAccount, isLoggedIn, navigation } = this.props; - const currentUsername = - get(currentAccount, 'name') !== nextProps.currentAccount.name && - nextProps.currentAccount.name; - - if (isLoggedIn && !nextProps.isLoggedIn) { - navigation.navigate(ROUTES.SCREENS.LOGIN); - return; - } - - if ( - (activeBottomTab !== get(nextProps, 'activeBottomTab') && - get(nextProps, 'activeBottomTab') === ROUTES.TABBAR.PROFILE) || - currentUsername - ) { - this._loadProfile(currentAccount.name); - this.setState({ forceLoadPost: true }); - } - } - - _getReplies = async user => { - const { isReverseHeader } = this.state; - if (isReverseHeader) { - await getUserComments({ start_author: user, limit: 10 }).then(result => { - this.setState({ - comments: result, - }); - }); - } else { - await getRepliesByLastUpdate({ start_author: user, limit: 10 }).then(result => { - this.setState({ - comments: result, - }); - }); - } - }; - - _handleFollowUnfollowUser = async isFollowAction => { - const { isFollowing } = this.state; - - this.setState({ - isProfileLoading: true, - }); - - if (isFollowAction && !isFollowing) { - this._followUser(); - } else { - this._unfollowUser(); - } - }; - - _handleMuteUnmuteUser = isMuteAction => { - this.setState({ - isProfileLoading: true, - }); - - if (isMuteAction) { - this._muteUser(); - } else { - this._unfollowUser(); - } - }; - - _unfollowUser = () => { - const { username } = this.state; - const { currentAccount, pinCode } = this.props; - const follower = currentAccount.name; - const following = username; - - unfollowUser(currentAccount, pinCode, { - follower, - following, - }) - .then(() => { - this._profileActionDone(); - }) - .catch(err => { - this._profileActionDone(err); - }); - }; - - _followUser = () => { - const { username } = this.state; - const { currentAccount, pinCode } = this.props; - const follower = currentAccount.name; - const following = username; - - followUser(currentAccount, pinCode, { - follower, - following, - }) - .then(() => { - this._profileActionDone(); - }) - .catch(err => { - this._profileActionDone(err); - }); - }; - - _muteUser = () => { - const { username } = this.state; - const { currentAccount, pinCode } = this.props; - const follower = currentAccount.name; - const following = username; - - ignoreUser(currentAccount, pinCode, { - follower, - following, - }) - .then(() => { - this._profileActionDone(); - }) - .catch(err => { - this._profileActionDone(err); - }); - }; - - _profileActionDone = (error = null) => { - const { username } = this.state; - - if (error) { - this.setState( - { - error, - }, - () => alert(error.message || error.toString()), - ); - } else { - this._fetchProfile(username, true); - } - }; - - _fetchProfile = async (username = null, isProfileAction = false) => { - const { username: _username, isFollowing, isMuted } = this.state; - - if (username) { - const { isLoggedIn, currentAccount } = this.props; - let _isFollowing; - let _isMuted; - let isFavorite; - let follows; - - if (isLoggedIn && currentAccount.name !== username) { - _isFollowing = await getIsFollowing(username, currentAccount.name); - - _isMuted = _isFollowing ? false : await getIsMuted(username, currentAccount.name); - - getIsFavorite(username, currentAccount.name).then(isFav => { - isFavorite = isFav; - }); - } - - try { - follows = await getFollows(username); - } catch (err) { - follows = null; - } - - /** - * This follow code totally a work arround - * Ceated for server response delay. - */ - if (isProfileAction && (isFollowing === _isFollowing && isMuted === _isMuted)) { - this._fetchProfile(_username, true); - } else { - this.setState({ - follows, - isFollowing: _isFollowing, - isMuted: _isMuted, - isFavorite, - isReady: true, - isProfileLoading: false, - }); - } - } - }; - - _loadProfile = async (selectedUser = null) => { - const { isConnected } = this.props; - - if (!isConnected) return; - - const user = await getUser(selectedUser); - - this._fetchProfile(selectedUser); - - this.setState(prevState => ({ - selectedQuickProfile: { - ...prevState.selectedQuickProfile, - display_name: user.display_name, - reputation: user.reputation, - }, - })); - - this.setState( - { - user, - username: selectedUser, - }, - () => { - this._getReplies(selectedUser); - }, - ); - }; - - _handleFollowsPress = async isFollowingPress => { - const { navigation } = this.props; - const { username, follows } = this.state; - let count; - - if (!isFollowingPress) { - count = follows.follower_count; - } else { - count = follows.following_count; - } - - navigation.navigate({ - routeName: ROUTES.SCREENS.FOLLOWS, - params: { - isFollowingPress, - count, - username, - }, - key: `${username}${count}`, - }); - }; - - _addFavorite = () => { - const { currentAccount } = this.props; - const { username } = this.state; - - addFavorite(currentAccount.name, username).then(() => { - this.setState({ isFavorite: true }); - }); - }; - - _removeFavorite = () => { - const { currentAccount } = this.props; - const { username } = this.state; - - removeFavorite(currentAccount.name, username).then(() => { - this.setState({ isFavorite: false }); - }); - }; - - _handleOnFavoritePress = isFavorite => { - if (isFavorite) { - this._removeFavorite(); - } else { - this._addFavorite(); - } - }; - - _handleOnBackPress = () => { - const { navigation } = this.props; - const navigationParams = get(navigation.state, 'params'); - - if (get(navigationParams, 'fetchData')) { - navigationParams.fetchData(); - } - }; - - _changeForceLoadPostState = value => { - this.setState({ forceLoadPost: value }); - }; - - render() { - const { - avatar, - comments, - error, - follows, - isFavorite, - isFollowing, - isMuted, - isProfileLoading, - isReady, - isReverseHeader, - selectedQuickProfile, - user, - username, - forceLoadPost, - } = this.state; - const { isDarkTheme, isLoggedIn, currency, navigation } = this.props; - const activePage = get(navigation.state.params, 'state', 0); - - return ( - this._getReplies(username)} - handleFollowUnfollowUser={this._handleFollowUnfollowUser} - handleMuteUnmuteUser={this._handleMuteUnmuteUser} - handleOnBackPress={this._handleOnBackPress} - handleOnFavoritePress={this._handleOnFavoritePress} - handleOnFollowsPress={this._handleFollowsPress} - isDarkTheme={isDarkTheme} - isFavorite={isFavorite} - isFollowing={isFollowing} - isLoggedIn={isLoggedIn} - isMuted={isMuted} - isProfileLoading={isProfileLoading} - isReady={isReady} - isReverseHeader={isReverseHeader} - selectedQuickProfile={selectedQuickProfile} - selectedUser={user} - username={username} - forceLoadPost={forceLoadPost} - changeForceLoadPostState={this._changeForceLoadPostState} - /> - ); - } -} - -const mapStateToProps = state => ({ - // Applicaiton - isLoggedIn: state.application.isLoggedIn, - isDarkTheme: state.application.isDarkTheme, - currency: state.application.currency, - isConnected: state.application.isConnected, - - // Ui - activeBottomTab: state.ui.activeBottomTab, - - // Account - currentAccount: state.account.currentAccount, - pinCode: state.application.pin, -}); - -export default connect(mapStateToProps)(withNavigation(ProfileContainer)); diff --git a/src/screens/profile/index.js b/src/screens/profile/index.js deleted file mode 100644 index 578dab22f..000000000 --- a/src/screens/profile/index.js +++ /dev/null @@ -1,5 +0,0 @@ -import ProfileScreen from './screen/profileScreen'; -import Profile from './container/profileContainer'; - -export { ProfileScreen, Profile }; -export default Profile; diff --git a/src/screens/profile/screen/profileScreen.js b/src/screens/profile/screen/profileScreen.js index edc7740d4..aeddf8a86 100644 --- a/src/screens/profile/screen/profileScreen.js +++ b/src/screens/profile/screen/profileScreen.js @@ -1,274 +1,80 @@ -import React, { PureComponent, Fragment } from 'react'; -import { View, ScrollView } from 'react-native'; -import { injectIntl } from 'react-intl'; +import React from 'react'; -// Components -import ScrollableTabView from 'react-native-scrollable-tab-view'; -import { Comments } from '../../../components/comments'; -import { CollapsibleCard } from '../../../components/collapsibleCard'; -import { Header } from '../../../components/header'; -import { - NoPost, - ProfileSummaryPlaceHolder, - WalletDetailsPlaceHolder, -} from '../../../components/basicUIElements'; -import { Posts } from '../../../components/posts'; -import { ProfileSummary } from '../../../components/profileSummary'; -import { TabBar } from '../../../components/tabBar'; -import { Wallet } from '../../../components/wallet'; +import { Profile } from '../../../components'; +import { ProfileContainer } from '../../../containers'; -// Constants -import { PROFILE_FILTERS } from '../../../constants/options/filters'; - -// Utilitites -import { getFormatedCreatedDate } from '../../../utils/time'; -import { getRcPower, getVotingPower } from '../../../utils/manaBar'; - -// Styles -import styles from './profileStyles'; -import globalStyles from '../../../globalStyles'; - -class ProfileScreen extends PureComponent { - constructor(props) { - super(props); - this.state = { - isSummaryOpen: true, - collapsibleMoreHeight: 0, - estimatedWalletValue: 0, - oldEstimatedWalletValue: 0, - }; - } - - _handleOnScroll = () => { - const { isSummaryOpen } = this.state; - - if (isSummaryOpen) this.setState({ isSummaryOpen: false }); - }; - - _handleOnSummaryExpanded = () => { - const { isSummaryOpen } = this.state; - - if (!isSummaryOpen) this.setState({ isSummaryOpen: true }); - }; - - _handleUIChange = height => { - this.setState({ collapsibleMoreHeight: height }); - }; - - _setEstimatedWalletValue = value => { - if (value) this.setState({ estimatedWalletValue: value }); - }; - - render() { - const { +const ProfileScreen = () => ( + + {({ about, + activePage, + avatar, + changeForceLoadPostState, comments, currency, + currencyRate, + currencySymbol, + error, follows, + forceLoadPost, getReplies, handleFollowUnfollowUser, handleMuteUnmuteUser, handleOnBackPress, handleOnFavoritePress, handleOnFollowsPress, - intl, + handleOnPressProfileEdit, isDarkTheme, isFavorite, isFollowing, isLoggedIn, isMuted, + isOwnProfile, isProfileLoading, isReady, - isReverseHeader, - selectedQuickProfile, + quickProfile, + resourceCredits, selectedUser, + setEstimatedWalletValue, username, - activePage, - forceLoadPost, - changeForceLoadPostState, - } = this.props; + votingPower, + }) => ( + + )} + +); - const { - isSummaryOpen, - collapsibleMoreHeight, - estimatedWalletValue, - oldEstimatedWalletValue, - } = this.state; - - let _about; - let coverImage; - let location; - let website; - let votingPower; - let resourceCredits; - let fullInHourVP; - let fullInHourRC; - let _estimatedWalletValue; - - if (selectedUser) { - votingPower = getVotingPower(selectedUser).toFixed(1); - resourceCredits = getRcPower(selectedUser).toFixed(1); - fullInHourVP = Math.ceil((100 - votingPower) * 0.833333); - fullInHourRC = Math.ceil((100 - resourceCredits) * 0.833333); - } - - if (about) { - _about = about.about; - coverImage = about.cover_image; - ({ location } = about); - ({ website } = about); - } - - if (estimatedWalletValue) { - const { currencyRate, currencySymbol } = currency; - _estimatedWalletValue = `${currencySymbol} ${( - estimatedWalletValue * currencyRate - ).toFixed()}`; - } - - return ( - -
- - {!isReady ? ( - - ) : ( - - - - )} - - ( - - )} - onChangeTab={({ i }) => { - if (i !== 2) { - this.setState({ - estimatedWalletValue: 0, - oldEstimatedWalletValue: estimatedWalletValue, - }); - } else this.setState({ estimatedWalletValue: oldEstimatedWalletValue }); - }} - > - - - - - {comments && comments.length > 0 ? ( - - - - ) : ( - - )} - - - {selectedUser ? ( - - ) : ( - - )} - - - - - ); - } -} - -export default injectIntl(ProfileScreen); +export default ProfileScreen; diff --git a/src/screens/profileEdit/screen/profileEditScreen.js b/src/screens/profileEdit/screen/profileEditScreen.js new file mode 100644 index 000000000..127fef11c --- /dev/null +++ b/src/screens/profileEdit/screen/profileEditScreen.js @@ -0,0 +1,103 @@ +import React, { PureComponent, Fragment } from 'react'; +import { injectIntl } from 'react-intl'; +import get from 'lodash/get'; +import ActionSheet from 'react-native-actionsheet'; + +import { ProfileEditContainer } from '../../../containers'; + +import { AvatarHeader, ProfileEditForm } from '../../../components'; + +class ProfileEditScreen extends PureComponent { + /* Props + * ------------------------------------------------ + * @prop { type } name - Description.... + */ + + constructor(props) { + super(props); + this.state = { + selectedUploadAction: '', + }; + + this.galleryRef = React.createRef(); + } + + // Component Life Cycles + + // Component Functions + _showImageUploadActions = async action => { + await this.setState({ selectedUploadAction: action }); + this.galleryRef.current.show(); + }; + + render() { + const { intl } = this.props; + const { selectedUploadAction } = this.state; + + return ( + + {({ + currentAccount, + isDarkTheme, + formData, + handleOnItemChange, + handleMediaAction, + name, + location, + website, + about, + avatarUrl, + coverUrl, + isLoading, + handleOnSubmit, + }) => ( + + this._showImageUploadActions('avatarUrl')} + /> + this._showImageUploadActions('coverUrl')} + handleOnItemChange={handleOnItemChange} + isLoading={isLoading} + handleOnSubmit={handleOnSubmit} + /> + { + handleMediaAction( + index === 0 ? 'image' : index === 1 && 'camera', + selectedUploadAction, + ); + }} + /> + + )} + + ); + } +} + +export default injectIntl(ProfileEditScreen); diff --git a/src/screens/reblogs/screen/reblogScreen.js b/src/screens/reblogs/screen/reblogScreen.js index b3b0b3f53..1710a2f07 100644 --- a/src/screens/reblogs/screen/reblogScreen.js +++ b/src/screens/reblogs/screen/reblogScreen.js @@ -5,8 +5,7 @@ import { useIntl } from 'react-intl'; // Constants // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { UserListItem } from '../../../components/basicUIElements'; +import { BasicHeader, UserListItem } from '../../../components'; import AccountListContainer from '../../../containers/accountListContainer'; diff --git a/src/screens/searchResult/screen/searchResultScreen.js b/src/screens/searchResult/screen/searchResultScreen.js index 91d70d7dc..c7dee45b2 100644 --- a/src/screens/searchResult/screen/searchResultScreen.js +++ b/src/screens/searchResult/screen/searchResultScreen.js @@ -4,9 +4,7 @@ import ScrollableTabView from 'react-native-scrollable-tab-view'; import { injectIntl } from 'react-intl'; // Components -import { TabBar } from '../../../components/tabBar'; -import { Posts } from '../../../components/posts'; -import SearchInput from '../../../components/searchInput'; +import { SearchInput, Posts, TabBar } from '../../../components'; // Styles import styles from './searchResultStyles'; diff --git a/src/screens/settings/screen/settingsScreen.js b/src/screens/settings/screen/settingsScreen.js index 58a801611..dade3e7b0 100644 --- a/src/screens/settings/screen/settingsScreen.js +++ b/src/screens/settings/screen/settingsScreen.js @@ -12,9 +12,7 @@ import CURRENCY, { VALUE as CURRENCY_VALUE } from '../../../constants/options/cu import NSFW from '../../../constants/options/nsfw'; // Components -import { BasicHeader } from '../../../components/basicHeader'; -import { SettingsItem } from '../../../components/settingsItem'; -import { CollapsibleCard } from '../../../components/collapsibleCard'; +import { BasicHeader, SettingsItem, CollapsibleCard } from '../../../components'; // Styles import styles from './settingsStyles'; @@ -84,15 +82,6 @@ class SettingsScreen extends PureComponent { })} titleStyle={styles.cardTitle} /> - + {!!isLoggedIn && ( { } return null; }; + +export const getResizedImage = (url, size = 400) => { + if (!url) return ''; + + if (url.includes('img.esteem')) return `https://img.esteem.ws/${size}x0/${url}`; + + return `https://steemitimages.com/${size}x0/${url}`; +}; + +export const getResizedAvatar = (author, sizeString = 'small') => { + if (!author) return ''; + + return `https://steemitimages.com/u/${author}/avatar/${sizeString}`; +}; diff --git a/src/utils/postParser.js b/src/utils/postParser.js index bca6cf36a..0a5939ed1 100644 --- a/src/utils/postParser.js +++ b/src/utils/postParser.js @@ -10,6 +10,7 @@ import { getPostReblogs } from '../providers/esteem/esteem'; // Utils import { getReputation } from './reputation'; +import { getResizedImage, getResizedAvatar } from './image'; export const parsePosts = async (posts, currentUserName) => { if (posts) { @@ -33,7 +34,7 @@ export const parsePost = async (post, currentUserName, isPromoted) => { post.image = postImage(post.json_metadata, post.body); post.vote_count = post.active_votes.length; post.author_reputation = getReputation(post.author_reputation); - post.avatar = `https://steemitimages.com/u/${post.author}/avatar/small`; + post.avatar = getResizedAvatar(get(post, 'author')); post.active_votes.sort((a, b) => b.rshares - a.rshares); post.body = renderPostBody(post); @@ -89,7 +90,7 @@ const postImage = (metaData, body) => { } if (imageLink) { - return `https://steemitimages.com/600x0/${imageLink}`; + return getResizedImage(imageLink, 600); } return ''; }; @@ -108,7 +109,7 @@ export const parseComments = async (comments, currentUserName) => { get(comment, 'pending_payout_value') ? get(comment, 'pending_payout_value') : 0, ).toFixed(3); comment.author_reputation = getReputation(get(comment, 'author_reputation')); - comment.avatar = `https://steemitimages.com/u/${get(comment, 'author')}/avatar/small`; + comment.avatar = getResizedAvatar(get(comment, 'author')); comment.markdownBody = get(comment, 'body'); comment.body = renderPostBody(comment); comment.active_votes = activeVotes; @@ -170,7 +171,7 @@ const parseActiveVotes = (post, currentUserName) => { value.reputation = getReputation(get(value, 'reputation')); value.percent /= 100; value.is_down_vote = Math.sign(value.percent) < 0; - value.avatar = `https://steemitimages.com/u/${value.voter}/avatar/small`; + value.avatar = getResizedAvatar(get(value, 'voter')); }); }