Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
lovvtide committed Jul 30, 2023
1 parent 757a483 commit a81c85d
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 13 deletions.
6 changes: 6 additions & 0 deletions src/assets/up_white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 16 additions & 2 deletions src/components/CommunityPage/NavActions.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Link } from 'react-router-dom';

import { COLORS } from '../../constants';
import svglightning from '../../assets/lightning_white.svg';
import svgstar from '../../assets/star_white.svg';
import svgstar from '../../assets/up_white.svg';


class NavActions extends PureComponent {
Expand Down Expand Up @@ -64,12 +64,26 @@ class NavActions extends PureComponent {
height: 24
}}
>
{/* {this.props.rankMode === 'zaps' ? (
<img
src={this.props.rankMode === 'zaps' ? svglightning : svgstar}
style={{
height: 12,
marginRight: 4,
transform: 'translate(0px, 2px)'
}}
/>
) : (
<Icon
name='star outline'
/>
)}*/}
<img
src={this.props.rankMode === 'zaps' ? svglightning : svgstar}
style={{
height: 12,
marginRight: 4,
transform: 'translate(0px, 2px)'
transform: this.props.rankMode === 'zaps' ? 'translate(0px, 2px)' : 'translate(0px, 1px)'
}}
/>
{mobile ? 'TOP' : 'TOP POSTS'}
Expand Down
9 changes: 6 additions & 3 deletions src/components/Nav/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,9 @@ class Nav extends Component {

return (
<div
onMouseOver={() => this.setState({ hover: 'notifications' })}
onMouseOut={() => this.setState({ hover: '' })}
onClick={() => this.props.viewSidePanel('notifications')}
style={{
marginLeft: mobile ? 8 : 10,
marginRight: mobile ? -4 : -10,
Expand All @@ -301,9 +304,9 @@ class Nav extends Component {
>

<Icon
onMouseOver={() => this.setState({ hover: 'notifications' })}
onMouseOut={() => this.setState({ hover: '' })}
onClick={() => this.props.viewSidePanel('notifications')}
// onMouseOver={() => this.setState({ hover: 'notifications' })}
// onMouseOut={() => this.setState({ hover: '' })}
// onClick={() => this.props.viewSidePanel('notifications')}
name='bell'
style={{
opacity: this.state.hover === 'notifications' ? 1 : 0.9,
Expand Down
8 changes: 4 additions & 4 deletions src/components/Nostr/CommunityList.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { nip19 } from 'nostr-tools';

import { COLORS } from '../../constants';
import crownsvg from '../../assets/crown.svg';
import { loadCommunitiesIndex } from '../../actions';
import { loadCommunitiesIndex, navigate } from '../../actions';

import Name from '../CommunityPage/Name';

Expand Down Expand Up @@ -98,15 +98,15 @@ class CommunityList extends PureComponent {
height: 12
}}
/>
<Link to={`/@${foundernpub}`}>
<div onClick={() => this.props.navigate(`/@${foundernpub}`)} /*to={`/@${foundernpub}`}*/>
<Name
npub={foundernpub}
profile={this.props.metadata[item.event.pubkey]}
style={{
color: COLORS.satelliteGold
}}
/>
</Link>
</div>
</div>
</div>
</div>
Expand Down Expand Up @@ -136,4 +136,4 @@ const mapState = ({ nostr, communities }) => {
};
};

export default connect(mapState, { loadCommunitiesIndex })(CommunityList);
export default connect(mapState, { loadCommunitiesIndex, navigate })(CommunityList);
8 changes: 4 additions & 4 deletions src/components/Nostr/Item.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -600,17 +600,17 @@ class Item extends PureComponent {
marginBottom: this.props.replaceTitleMode === 'list' ? 6 : 12
}}>
{title ? (this.props.communityLink ? (
<Link to={this.props.communityLink}>
<div /*to={this.props.communityLink}*/onClick={() => this.props.navigate(this.props.communityLink)}>
{titleElement}
</Link>
</div>
) : titleElement) : null}
<div style={{
//marginTop: 4
}}>
{link && !this.props.previewReplacedLinks ? (this.props.communityLink ? (
<Link to={this.props.communityLink}>
<div /*to={this.props.communityLink}*/onClick={() => this.props.navigate(this.props.communityLink)}>
{this.renderReplacedLinkElement(link)}
</Link>
</div>
) : this.renderReplacedLinkElement(link)) : null}
</div>
</div>
Expand Down

0 comments on commit a81c85d

Please sign in to comment.