styling of the multiselect broken in gin darkmode

Created on 9 January 2025, 3 months ago

Problem/Motivation

The styling of the multiselect is broken in the gin dark

seems like the background of the multiselect is still using the coloring of the light mode.

Steps to reproduce

Proposed resolution

๐Ÿ› Bug report
Status

Active

Version

2.0

Component

User experience

Created by

๐Ÿ‡ฉ๐Ÿ‡ชGermany rkoller Nรผrnberg, Germany

Live updates comments and jobs are added and updated live.
  • Accessibility

    It affects the ability of people with disabilities or special needs (such as blindness or color-blindness) to use Drupal.

  • Usability

    Makes Drupal easier to use. Preferred over UX, D7UX, etc.

Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @rkoller
  • ๐Ÿ‡ฒ๐Ÿ‡ฆMorocco simobm

    I just can't figure out how to apply the changes from my fork, but anyways, applying these changes to pb.css should do it:

    @media (prefers-color-scheme: dark) {
      .pb-filter__multi-dropdown__items div{
        background-color: #2a2a2d;
        border-bottom: 1px solid rgba(212, 212, 218, 0.34);
      }
    
      .pb-filter__multi-dropdown__items div:hover,
      .pb-filter__multi-dropdown__items div:focus {
        background-color: #2a2a2de8;
      }
    }
    
  • Pipeline finished with Failed
    2 months ago
    Total: 480s
    #405839
  • Pipeline finished with Success
    2 months ago
    Total: 465s
    #409520
  • Hi @rkoller and @simobm,

    I was reviewing this issue, and I believe it would be more appropriate to address it within the Gin Admin theme rather than making changes here. Could you please confirm if this approach makes sense, or if I might be overlooking something?

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia utkarsh_33

    Move the Project browser specific styling from gin theme to project browser's scope. ๐Ÿ“Œ Move the Project browser specific styling from gin theme to project browser's scope. Active this issue moves the styling from gin to the Project browser's scope.I think once this is in then fixing all the css related issue specific to gin would be easier.
    Attaching the issue for reference.

  • Pipeline finished with Skipped
    about 1 month ago
    #429948
  • Pipeline finished with Canceled
    about 1 month ago
    Total: 122s
    #438385
  • Pipeline finished with Canceled
    about 1 month ago
    Total: 124s
    #438386
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia utkarsh_33

    This is how the dropdown looks:-

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia utkarsh_33

    Marking NR.

  • Pipeline finished with Failed
    about 1 month ago
    Total: 496s
    #438387
  • Pipeline finished with Success
    about 1 month ago
    Total: 468s
    #438393
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia narendraR Jaipur, India

    The background and text color of Filter by category items is different from other filters eg Security advisory coverage.
    Also suggested some css change.

  • Pipeline finished with Running
    about 1 month ago
    #438457
  • Pipeline finished with Canceled
    about 1 month ago
    Total: 150s
    #438456
  • Pipeline finished with Failed
    about 1 month ago
    Total: 475s
    #438481
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia utkarsh_33

    It needs a round of manual testing and also i'm not sure about the css rule for hovering over the div.Already added the questions for the same.

  • Pipeline finished with Success
    about 1 month ago
    Total: 363s
    #438689
  • Hi @utkarsh_33, While reviewing this issue, I had a few observations.

    1. It seems that dark mode-related changes would be more appropriately placed in the gin.css file rather than pb.css, as all other Gin-
    specific styling is handled there. Would you agree with this approach?

    2. If we want it to look similar with the other select dropdowns we need to change the colour of text to black like other select dropdowns
    when it gets focus or hover.

    3. But i noticed in light mode this dropdown is not similar with other select dropdowns so we may consider it and can obtain the background color for before and after hover like this also.

    I used this code for the changes

    .gin--dark-mode .pb-filter__multi-dropdown__items--visible {
      background-color: var(--gin-bg-layer);
    }
    .gin--dark-mode .pb-filter__multi-dropdown__items--visible div:hover,
    .gin--dark-mode .pb-filter__multi-dropdown__items--visible div:focus {
      background-color: var(--gin-bg-layer2);
    }
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia utkarsh_33

    I think it makes sense to move the css rules to gin.css.I think i didnโ€™t completely get how points 2 and 3 makes it similar to other dropdown.If you think it makes sense then you can push the changes accordingly.

  • Pipeline finished with Success
    29 days ago
    Total: 492s
    #440401
  • My 2nd point was that in your previous commit bd6e4af7 after hovering over the div it is getting blue color as i thought you were trying to make the hover same as the other dropdowns like e.g. Security Advisory Coverage, Maintenance Status etc. I was saying if we follow this we need to change the color of the text from white to black when it get blue bg color while hovering.

    Alternatively we may pick the design as i mentioned in my 3rd point it may look good as in light mode also Filter by category is not identical with other select dropdowns.

    As you make the changes in the MR now. I think it is looking good. Let's wait for feedback from others.

  • Pipeline finished with Success
    26 days ago
    Total: 1143s
    #443181
  • Pipeline finished with Success
    23 days ago
    Total: 871s
    #445320
  • Pipeline finished with Skipped
    22 days ago
    #445844
  • Status changed to RTBC 21 days ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States phenaproxima Massachusetts

    Gave this a quick manual test and confirmed that the selector looks awful in 2.0.x with Gin's dark mode enabled, and much nicer with this MR applied!

    The CSS doesn't look problematic to me either. As far as I can tell, we're good to go here.

  • First commit to issue fork.
  • Pipeline finished with Skipped
    21 days ago
    #446667
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States chrisfromredfin Portland, Maine

    confirmed fixed with manual testing.

  • Pipeline finished with Failed
    21 days ago
    Total: 384s
    #446661
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024