Skip to content

Commit c713c8e

Browse files
committed
- Default prop seems to be not working through package though it working in local by using direct source code of component.
- Increased version to v1.3.6
1 parent 4555b58 commit c713c8e

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ <h2 style="color:darkgreen;">Screenshots</h2>
4646
<tr>
4747
<td class="img-asset"><img width="200" src="./rn-swipe-button.png" /></td>
4848
<td class="img-asset"><img width="200" src="./rn-swipe-button-ios.png" /></td>
49-
<td class="img-asset"><img width="200" src="./rn-swipe-button.gif" /></td>
49+
<td class="img-asset"><a href="https://github.com/UdaySravanK/RNSwipeButton/blob/master/docs/rn-swipe-button.gif" target="_blank"><img width="200" src="./rn-swipe-button.gif" /></a></td>
5050
<td class="img-asset"><img width="200" src="./rn-swipe-button-rtl.png" /></td>
5151
</tr>
5252
</table>

examples/RNSwipeButtonDemo/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"dependencies": {
1313
"react": "17.0.1",
1414
"react-native": "0.64.2",
15-
"rn-swipe-button": "^1.3.5"
15+
"rn-swipe-button": "1.3.6"
1616
},
1717
"devDependencies": {
1818
"@babel/core": "^7.12.9",

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "rn-swipe-button",
3-
"version": "1.3.5",
3+
"version": "1.3.6",
44
"description": "react native swipe/slide button component",
55
"main": "index.js",
66
"scripts": {

src/components/SwipeThumb/index.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,12 +179,18 @@ const SwipeThumb = props => {
179179
thumbIconHeight,
180180
thumbIconImageSource,
181181
thumbIconStyles,
182-
thumbIconWidth = thumbIconHeight,
182+
thumbIconWidth,
183183
} = props;
184+
var iconWidth = 0
185+
if (thumbIconWidth == undefined) {
186+
iconWidth = thumbIconHeight
187+
} else {
188+
iconWidth = thumbIconWidth
189+
}
184190
const dynamicStyles = {
185191
...thumbIconStyles,
186192
height: thumbIconHeight,
187-
width: thumbIconWidth,
193+
width: iconWidth,
188194
backgroundColor: disabled
189195
? disabledThumbIconBackgroundColor
190196
: thumbIconBackgroundColor,

0 commit comments

Comments
 (0)