@@ -19,7 +19,6 @@ import { __ } from '@wordpress/i18n';
1919 * Internal dependencies
2020 */
2121import { getSupportedGlobalStylesPanels , useSetting , useStyle } from './hooks' ;
22- import { getTypographyFontSizeValue } from './typography-utils' ;
2322
2423export function useHasTypographyPanel ( name ) {
2524 const hasFontFamily = useHasFontFamilyControl ( name ) ;
@@ -173,19 +172,8 @@ export default function TypographyPanel( { name, element, headingLevel } ) {
173172 } else if ( element && element !== 'text' ) {
174173 prefix = `elements.${ element } .` ;
175174 }
176- const [ fluidTypography ] = useSetting ( 'typography.fluid' , name ) ;
177175 const [ fontSizes ] = useSetting ( 'typography.fontSizes' , name ) ;
178176
179- // Convert static font size values to fluid font sizes if fluidTypography is activated.
180- const fontSizesWithFluidValues = fontSizes . map ( ( font ) => {
181- if ( ! ! fluidTypography ) {
182- font . size = getTypographyFontSizeValue ( font , {
183- fluid : fluidTypography ,
184- } ) ;
185- }
186- return font ;
187- } ) ;
188-
189177 const disableCustomFontSizes = ! useSetting (
190178 'typography.customFontSize' ,
191179 name
@@ -274,7 +262,7 @@ export default function TypographyPanel( { name, element, headingLevel } ) {
274262 < FontSizePicker
275263 value = { fontSize }
276264 onChange = { setFontSize }
277- fontSizes = { fontSizesWithFluidValues }
265+ fontSizes = { fontSizes }
278266 disableCustomFontSizes = { disableCustomFontSizes }
279267 withReset = { false }
280268 withSlider
0 commit comments