From 02723d90d8984a09d1c1d2cdde48cfcdbf8d0a6d Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Mon, 9 Dec 2024 12:58:26 +0100 Subject: [PATCH] Revert change for __next40pxDefaultSize. --- .../src/components/global-styles/filters-panel.js | 6 +----- packages/components/src/item-group/item/hook.ts | 5 ++--- packages/components/src/item-group/styles.ts | 8 +------- packages/components/src/item-group/types.ts | 6 ------ 4 files changed, 4 insertions(+), 21 deletions(-) diff --git a/packages/block-editor/src/components/global-styles/filters-panel.js b/packages/block-editor/src/components/global-styles/filters-panel.js index 46e17dd9d7bb99..c62099596f66c6 100644 --- a/packages/block-editor/src/components/global-styles/filters-panel.js +++ b/packages/block-editor/src/components/global-styles/filters-panel.js @@ -189,11 +189,7 @@ export default function FiltersPanel( { return ( - + ) { onClick, role = 'listitem', size: sizeProp, - __next40pxDefaultSize, ...otherProps } = useContextSystem( props, 'Item' ); @@ -36,13 +35,13 @@ export function useItem( props: WordPressComponentProps< ItemProps, 'div' > ) { () => cx( ( as === 'button' || as === 'a' ) && - styles.unstyledButton( as, __next40pxDefaultSize ), + styles.unstyledButton( as ), styles.itemSizes[ size ] || styles.itemSizes.medium, styles.item, spacedAround && styles.spacedAround, className ), - [ as, className, cx, size, spacedAround, __next40pxDefaultSize ] + [ as, className, cx, size, spacedAround ] ); const wrapperClassName = cx( styles.itemWrapper ); diff --git a/packages/components/src/item-group/styles.ts b/packages/components/src/item-group/styles.ts index 886f293112ce3f..7fe7dd1d00409c 100644 --- a/packages/components/src/item-group/styles.ts +++ b/packages/components/src/item-group/styles.ts @@ -8,10 +8,7 @@ import { css } from '@emotion/react'; */ import { CONFIG, COLORS, font } from '../utils'; -export const unstyledButton = ( - as: 'a' | 'button', - __next40pxDefaultSize: boolean | undefined -) => { +export const unstyledButton = ( as: 'a' | 'button' ) => { return css` font-size: ${ font( 'default.fontSize' ) }; font-family: inherit; @@ -21,9 +18,6 @@ export const unstyledButton = ( background: none; text-align: start; text-decoration: ${ as === 'a' ? 'none' : undefined }; - height: ${ __next40pxDefaultSize && as === 'button' - ? '40px' - : undefined }; svg, path { fill: currentColor; diff --git a/packages/components/src/item-group/types.ts b/packages/components/src/item-group/types.ts index 04e776c0de58a3..39aad8c6902c72 100644 --- a/packages/components/src/item-group/types.ts +++ b/packages/components/src/item-group/types.ts @@ -38,12 +38,6 @@ export interface ItemProps { * @default 'medium' */ size?: ItemSize; - /** - * Start opting into the larger default height that will become the default size in a future version. - * - * @default false - */ - __next40pxDefaultSize?: boolean; /** * The children elements. */