CSS Element "passing" over each other in a li

Asked

Viewed 183 times

1

I have a custom select (Dropbox), in which there is a search field in the list, this select with jquery was downloaded (I didn’t do it), well, I had to position one over the other for my purpose, the problem is that one select overrides the other when active, as if it were transparent, I already changed in css the property position, z-index, background color and nothing, I’ll leave a print of the problem, anyone suggest something? I don’t have much intimacy with frontend (css)

first image with the first select selected (without any underneath) second image with a select on top of others, look at the list of options

inserir a descrição da imagem aqui, inserir a descrição da imagem aqui

below the css snippet:

/* @group Results */
.chosen-container .chosen-results {
  color: #444; 
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 240px;
  -webkit-overflow-scrolling: touch;
}
.chosen-container .chosen-results li {
  display:none;
  margin: 0;
  padding: 1px 1px;
  list-style: none;
  text-align:left;
  z-index: 999999 !important
}
.chosen-container .chosen-results li.active-result {
  display: list-item;
  cursor: pointer;
}
.chosen-container .chosen-results li.disabled-result {
  display: list-item;
  color: #ccc;
  cursor: default;
}
.chosen-container .chosen-results li.highlighted {
  background-color: #3875d7;
  color: #fff;
}
.chosen-container .chosen-results li.no-results {
  color: #777;
  display: list-item;
  background: #f4f4f4;
}
.chosen-container .chosen-results li.group-result {
  display: list-item;
  font-weight: bold;
  cursor: default;
}
.chosen-container .chosen-results li.group-option {
  padding-left: 15px;
}
.chosen-container .chosen-results li em {
  font-style: normal;
  text-decoration: underline;
}

/* @end */
  • 1

    Put a z-index: 999999 !important in the css of select and forehead.

  • Thanks to all who answered, select is not the problem, but the list with the options, this jquery generates a css read with the results, and this list does not overwrite the select that is below, as in the photos.

  • What is the plugin you are using to do this?

  • @Douglasfernandes, I use the Chosen https://plugins.jquery.com/chosen/ https:/davidwalsh.name/demo/jquery-chosen.phpplugin

  • 1

    Guys with me downloading again the css of the plugin, but so far do not know what was the problem. thanks to all

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.