From 8049ef2a55033fa559fd68b41d2f9277d22c24c8 Mon Sep 17 00:00:00 2001 From: mertsincan Date: Mon, 4 Apr 2022 09:56:13 +0100 Subject: [PATCH] Fixed #2717 - Add inputId property to Chips --- components/doc/chips/index.js | 6 ++++++ components/lib/chips/Chips.d.ts | 1 + components/lib/chips/Chips.js | 3 ++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/components/doc/chips/index.js b/components/doc/chips/index.js index 32f5070da0..42b1061438 100644 --- a/components/doc/chips/index.js +++ b/components/doc/chips/index.js @@ -235,6 +235,12 @@ customChip(item) { null Unique identifier of the component. + + inputId + string + null + Identifier of the focus input to match a label defined for the chips. + name string diff --git a/components/lib/chips/Chips.d.ts b/components/lib/chips/Chips.d.ts index 2a625d5f25..ded8453f8f 100755 --- a/components/lib/chips/Chips.d.ts +++ b/components/lib/chips/Chips.d.ts @@ -33,6 +33,7 @@ interface ChipsChangeParams { export interface ChipsProps { id?: string; inputRef?: React.Ref; + inputId?: string; name?: string; placeholder?: string; value?: any[]; diff --git a/components/lib/chips/Chips.js b/components/lib/chips/Chips.js index 7e3a68f4dc..563ddfb55c 100644 --- a/components/lib/chips/Chips.js +++ b/components/lib/chips/Chips.js @@ -179,7 +179,7 @@ export const Chips = React.memo(React.forwardRef((props, ref) => { const createInput = () => { return (
  • -
  • @@ -229,6 +229,7 @@ Chips.defaultProps = { __TYPE: 'Chips', id: null, inputRef: null, + inputId: null, name: null, placeholder: null, value: null,