creativetimofficial / material-kit-react

Material Kit React free and open source by Creative Tim
https://www.creative-tim.com/product/material-kit-react?ref=mkr-readme
1.19k stars 2.13k forks source link

The "filter" css class, when applied to the Parallax component, is disabling all the buttons and links #11

Closed hustlelikeaboss closed 5 years ago

hustlelikeaboss commented 6 years ago

The "filter" css class, when applied to the Parallax component, is disabling all the buttons and links inside the component.

<Parallax filter image={require("assets/img/landing-bg.jpg")}>

Example: https://creativetimofficial.github.io/material-kit-react/#/landing-page

Not sure what exactly content: "''" is supposed to do, but removing it has fixed the issue for me:

filter: { "&:before": { background: "rgba(0, 0, 0, 0.05)" }, "&:after,&:before": { position: "absolute", zIndex: "1", width: "100%", height: "100%", display: "block", left: "0", top: "0", // content: "''" } },

einazare commented 6 years ago

Hello @hustlelikeaboss ,

And thank you for your interest in using our product. It actually does not. If you can see, there is a zIndex property there, which will make the filter to be on top on each child. If you want your children of the Parallax to appear above, than you'll need to add a zIndex property for your children as well, preferably set to 2 or higher to make them on top of the Parallax filter.

Does this makes sense?

Best, Manu

hustlelikeaboss commented 6 years ago

Try clicking the button in the paralax on this page: https://creativetimofficial.github.io/material-kit-react/#/landing-page.

I set it to 10 and no difference.

einazare commented 6 years ago

Hello again @hustlelikeaboss ,

I see that it works just fine on the live preview. Here are two images with and without zIndex on children:

screen shot 2018-05-24 at 11 14 58 am screen shot 2018-05-24 at 11 15 04 am

As you can see, without z-index on children, they appear to be behind the parallax, but with z-index, they are above.

Is this helpful?

Best, Manu

hustlelikeaboss commented 6 years ago

I feel like we're talking past each other, but thanks for taking the time to respond.

mustafa-kahraman commented 6 years ago

any solution?