site-kit-wp: Search URL hover background color Inconsistent to other Menu Dropdowns

Bug Description

Minor UI issue. When entering a term into the search URL field, the results appear.

When you hover over the results, the background colour is darker than the other menu options.

See screencast below.

search

Steps to reproduce

  1. Go to ‘Site Kit dashboard’
  2. Click on ‘Search URL’ icon in the header
  3. Type in a search term
  4. Results appear see issue when you hover over items.

Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • The hover background color for tertiary buttons, dropdown items and any other selectable/interactive elements on white background that has grey background on hover, should be consistently using interactive/tertiary-hover color token
  • The background color on hover, should be updated for following elements:
    • The dropdown items in: the search results menu items, date range dropdown, help dropdown and Google Account menu item dropdown
    • Multi-select chips, the roles in Dashboard Sharing dialog Image
    • Sub-header navigation chip items Image
    • Table rows in Top search queries for your site and Top content over the last 28 days widgets Image
    • Dropdown select in module settings Image

Implementation Brief

Note: at the time of writing, we are covering tertiary buttons hover with correct color token, we just need to ensure all items listed listed in the AC are aligned, and we have needed toke in the variable already: $c-interactive-tertiary-hover

  • Apply the $c-interactive-tertiary-hover color for on hover, on following elements:
    • assets/sass/components/global/_googlesitekit-entity-search.scss for .mdc-button under hover state
    • assets/sass/components/global/_googlesitekit-autocomplete.scss for .autocomplete__option:hover
    • assets/sass/components/global/_googlesitekit-sharing-settings.scss for .googlesitekit-sharing-settings__button on it’s hover state
    • assets/sass/vendor/_mdc-button.scss for .mdc-button--dropdown on hover state
    • assets/sass/components/global/_googlesitekit-dropdown-menu.scss add style for .mdc-list-item, on hover state, pseudo before should use the referenced background color and reset/unset default opacity, as $c-interactive-tertiary-hover is having rgba value with transparency already included. This should cover all dropdown items - in particular the ones in user menu and help menu
    • assets/sass/components/global/_googlesitekit-sharing-settings.scss for .googlesitekit-user-role-select, add hover state style for before pseudo element , also unset default opacity
    • assets/sass/components/global/_googlesitekit-dashboard-navigation.scss for .mdc-chip add for hover state target before pseudo element, and also unset the opacity
    • assets/sass/components/global/_googlesitekit-table.scss for .googlesitekit-table__body-row update the existing hover background
    • assets/sass/components/global/_googlesitekit-entity-header.scss for .mdc-button under .googlesitekit-entity-header__back, add background on hover for before pseudo element, and also unset the opacity

Test Coverage

  • No new tests are needed, update any failing VRT

QA Brief

Changelog entry

About this issue

Most upvoted comments

@wpdarren @aaemnnosttv Hover state token should be N-50. I just reviewed the whole UI and the only place where is different is in the search component. Let me know if you find another issue and i’ll take a look.

@wpdarren @aaemnnosttv The hover state that is being used on the date picker is the right one.