Skip to content

Commit

Permalink
fix: fix link style issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Kashish Grover committed Jun 28, 2020
1 parent bf3dae3 commit 13bca29
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-native-see-more-inline",
"version": "1.2.0",
"version": "1.2.1",
"description": "Show a \"read more\", \"see more\", \"read less\", \"see less\" inline with your text in React Native",
"main": "index.js",
"repository": "git@github.com:kashishgrover/react-native-see-more-inline.git",
Expand Down
3 changes: 2 additions & 1 deletion src/SeeMore/SeeMore.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ class SeeMore extends React.Component {
linkPressedColor,
seeMoreText,
seeLessText,
style,
} = this.props;
const isTruncable = truncationIndex < text.length;

Expand All @@ -121,7 +122,7 @@ class SeeMore extends React.Component {
<Text
{...this.props}
{...this.panResponder.panHandlers}
style={{ color: isLinkPressed ? linkPressedColor : linkColor }}
style={[style, { color: isLinkPressed ? linkPressedColor : linkColor }]}
>
{isShowingMore ? null : <Text {...this.props}>...</Text>}
{isShowingMore ? ` ${seeLessText}` : ` ${seeMoreText}`}
Expand Down

0 comments on commit 13bca29

Please sign in to comment.