From c267df521224cce1d060dda5bcd8e58116169ca9 Mon Sep 17 00:00:00 2001 From: Aki Hamano <54422211+t-hamano@users.noreply.github.com> Date: Wed, 3 Apr 2024 11:25:38 +0900 Subject: [PATCH] Search Block: Apply font-related style inheritance to input field (#60321) * Search Block: Apply font-related style inheritance to input field * Add missin styles Co-authored-by: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> --------- Co-authored-by: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> Co-authored-by: t-hamano Co-authored-by: ramonjd Co-authored-by: aaronrobertshaw Co-authored-by: gigitux --- packages/block-library/src/search/style.scss | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/packages/block-library/src/search/style.scss b/packages/block-library/src/search/style.scss index 1434f29de76810..eb8e3051bada85 100644 --- a/packages/block-library/src/search/style.scss +++ b/packages/block-library/src/search/style.scss @@ -97,6 +97,17 @@ $button-spacing-y: math.div($grid-unit-15, 2); // 6px } } +// We are lowering the specificity so that the input element can override the rule for the input element inside the search block. +:where(.wp-block-search__input) { + font-family: inherit; + font-weight: inherit; + font-size: inherit; + line-height: inherit; + letter-spacing: inherit; + text-transform: inherit; + font-style: inherit; +} + // We are lowering the specificity so that the button element can override the rule for the button inside the search block. :where(.wp-block-search__button-inside .wp-block-search__inside-wrapper) { padding: $grid-unit-05;