Skip to content

Commit 9b4e918

Browse files
committed
1.7.2
1 parent ef57c3f commit 9b4e918

File tree

3 files changed

+15
-13
lines changed

3 files changed

+15
-13
lines changed

dist/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ var Navigator = function (_React$Component) {
389389

390390
return _react2.default.createElement("div", null);
391391
} else {
392-
return nowPage === child.key || fthis.state.historyPages.includes(child.key) || child.props.alwaysLive ? _react2.default.createElement(
392+
return _react2.default.createElement(
393393
"div",
394394
{
395395
// onTouchStart={(e) => {
@@ -454,8 +454,8 @@ var Navigator = function (_React$Component) {
454454
key: child.key,
455455
className: fthis.state.startPage === child.key ? "showPage scrollPage" : "hiddenPage"
456456
},
457-
_react2.default.cloneElement(child, fthis.state.props[child.key], child.props.children)
458-
) : null;
457+
nowPage === child.key || fthis.state.historyPages.includes(child.key) || child.props.alwaysLive ? _react2.default.cloneElement(child, fthis.state.props[child.key], child.props.children) : null
458+
);
459459
}
460460
}) : _react2.default.createElement(
461461
"div",

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react.cordova-navigation_controller",
3-
"version": "1.7.1",
3+
"version": "1.7.2",
44
"description": "Navigator for Cordova with React.js(react.cordova), This will help you to manage your pages history in the app and change pages with animation.",
55
"main": "dist/index.js",
66
"scripts": {

src/index.js

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -459,9 +459,7 @@ export default class Navigator extends React.Component {
459459

460460
return <div></div>;
461461
} else {
462-
return nowPage === child.key ||
463-
fthis.state.historyPages.includes(child.key) ||
464-
child.props.alwaysLive ? (
462+
return (
465463
<div
466464
// onTouchStart={(e) => {
467465

@@ -549,13 +547,17 @@ export default class Navigator extends React.Component {
549547
: "hiddenPage"
550548
}
551549
>
552-
{React.cloneElement(
553-
child,
554-
fthis.state.props[child.key],
555-
child.props.children
556-
)}
550+
{nowPage === child.key ||
551+
fthis.state.historyPages.includes(child.key) ||
552+
child.props.alwaysLive
553+
? React.cloneElement(
554+
child,
555+
fthis.state.props[child.key],
556+
child.props.children
557+
)
558+
: null}
557559
</div>
558-
) : null;
560+
);
559561
}
560562
})
561563
) : (

0 commit comments

Comments
 (0)