From e224a48c95b47cc2bf03ae01ed657425aa8bf218 Mon Sep 17 00:00:00 2001 From: melloware Date: Fri, 15 Mar 2024 07:52:32 -0400 Subject: [PATCH] Fix #6160: InputText className listed twice --- components/lib/hooks/useDisplayOrder.js | 2 +- components/lib/inputtext/InputText.js | 4 ++-- components/lib/inputtext/__snapshots__/InputText.spec.js.snap | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/components/lib/hooks/useDisplayOrder.js b/components/lib/hooks/useDisplayOrder.js index 86914761ab..40efe6b8c4 100644 --- a/components/lib/hooks/useDisplayOrder.js +++ b/components/lib/hooks/useDisplayOrder.js @@ -1,5 +1,5 @@ import * as React from 'react'; -import { UniqueComponentId } from '../utils/Utils'; +import { ObjectUtils, UniqueComponentId } from '../utils/Utils'; const groupToDisplayedElements = {}; diff --git a/components/lib/inputtext/InputText.js b/components/lib/inputtext/InputText.js index 2f0735f438..8066bf1844 100644 --- a/components/lib/inputtext/InputText.js +++ b/components/lib/inputtext/InputText.js @@ -4,7 +4,7 @@ import { useHandleStyle } from '../componentbase/ComponentBase'; import { useMergeProps } from '../hooks/Hooks'; import { KeyFilter } from '../keyfilter/KeyFilter'; import { Tooltip } from '../tooltip/Tooltip'; -import { DomHandler, ObjectUtils, classNames } from '../utils/Utils'; +import { DomHandler, ObjectUtils } from '../utils/Utils'; import { InputTextBase } from './InputTextBase'; export const InputText = React.memo( @@ -71,7 +71,7 @@ export const InputText = React.memo( const rootProps = mergeProps( { - className: classNames(props.className, cx('root', { isFilled })), + className: cx('root', { isFilled }), onBeforeInput: onBeforeInput, onInput: onInput, onKeyDown: onKeyDown, diff --git a/components/lib/inputtext/__snapshots__/InputText.spec.js.snap b/components/lib/inputtext/__snapshots__/InputText.spec.js.snap index ebd3d0795b..dc881df8d3 100644 --- a/components/lib/inputtext/__snapshots__/InputText.spec.js.snap +++ b/components/lib/inputtext/__snapshots__/InputText.spec.js.snap @@ -3,7 +3,7 @@ exports[`InputText when input has className only 1 className is printed 1`] = `