Closed eleventhaus closed 5 years ago
Hello there @eleventhaus,
Thank you for your interest in working with our products. If you do not want to have animation on NavPills, go inside and change (lines 84-98):
<div className={classes.contentWrapper}>
<SwipeableViews
axis={direction === "rtl" ? "x-reverse" : "x"}
index={this.state.active}
onChangeIndex={this.handleChangeIndex}
>
{tabs.map((prop, key) => {
return (
<div className={classes.tabContent} key={key}>
{prop.tabContent}
</div>
);
})}
</SwipeableViews>
</div>
with
<div className={classes.contentWrapper}>
{tabs.map((prop, key) => {
if (key === this.state.active) {
return (
<div className={classes.tabContent} key={key}>
{prop.tabContent}
</div>
);
}
return null;
})}
</div>
I'll speak with the board if this is something we should add on our product as well, for our next updates.
Best, Manu
TY
Also, to note, when using NavPills (without implementing the fix above to remove animation) the shadow on the card elements is cut off by the gridcontainer. Something to consider with regards to styling.
Default NavPills
NavPills without animation
Hello again, @eleventhaus
Thank you for sharing this with us. We'll see what we can do, in our next updates.
Best, Manu
!!! IF YOU DO NOT USE THIS ISSUES TEAMPLATE, YOUR ISSUE IS LIABLE TO BEING IGNORED BY US
Prerequisites
Please answer the following questions for yourself before submitting an issue.
Expected Behavior
When using navpills, there should be an option to re-render content without showing an animation on selecting tabs - like the angular version of Material Kit Pro
Current Behavior
Animation occurs
Failure Information (for bugs)
none
Steps to Reproduce
use navpills and navigate between tabs
Context
Please provide any relevant information about your setup. This is important in case the issue is not reproducible except for under certain conditions.
Failure Logs
Please include any relevant log snippets or files here.