Make WordPress Core

Opened 8 months ago

Closed 8 months ago

#61372 closed defect (bug) (wontfix)

Twenty Seventeen: Search Block Clear text button not showing on frontend

Reported by: pranitdugad's profile pranitdugad Owned by:
Milestone: Priority: normal
Severity: trivial Version:
Component: Bundled Theme Keywords: close 2nd-opinion
Focuses: Cc:

Description

In Twenty Seventeen, the Search Block has a Clear Entered text Button (X) appearing once the user adds text to search input on the editor side but the same button does not appear on the frontend side.

While on other themes it seems to be working fine(as shown in video).

Video: https://jmp.sh/Hl64U3rn

Change History (4)

#1 @nkpathan
8 months ago

  • Resolution set to invalid
  • Status changed from new to closed
Please find below given css visible Search Block Clear text button in site's Front End:


input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: none;
    height: 16px;
    width: 16px;
    margin-left: .4em;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23777'><path d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/></svg>");
    cursor: pointer;
}

Thanks

#2 @nkpathan
8 months ago

  • Resolution invalid deleted
  • Status changed from closed to reopened

#3 @sabernhardt
8 months ago

  • Keywords close 2nd-opinion added
  • Severity changed from minor to trivial

Twenty Seventeen removes the browser's search cancel button from the front end as part of the normalize style set. PR 92 updated those styles, so I would say that the theme should continue to remove the button from the front end.

The editor styles theoretically could be updated with the same ruleset, but

  1. I think the cancel button can be useful when starting to write a placeholder attribute and then deciding to remove it,
  2. the button only appears in the editor when someone types in an optional placeholder (and on hover/focus after it has a placeholder), and
  3. the theme does not set its more noticeable styles related to forms within the editor (#45293).

#4 @karmatosed
8 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from reopened to closed

As recommended I am going to close this for now. I agree with @sabernhardt's comments. Thank you everyone for collaboration on this for now.

Note: See TracTickets for help on using tickets.