( props: MultiValueProps<Option, IsMulti, Group> )
| 157 | } |
| 158 | |
| 159 | const MultiValue = < |
| 160 | Option, |
| 161 | IsMulti extends boolean, |
| 162 | Group extends GroupBase<Option> |
| 163 | >( |
| 164 | props: MultiValueProps<Option, IsMulti, Group> |
| 165 | ) => { |
| 166 | const { |
| 167 | children, |
| 168 | components, |
| 169 | data, |
| 170 | innerProps, |
| 171 | isDisabled, |
| 172 | removeProps, |
| 173 | selectProps, |
| 174 | } = props; |
| 175 | |
| 176 | const { Container, Label, Remove } = components; |
| 177 | |
| 178 | return ( |
| 179 | <Container |
| 180 | data={data} |
| 181 | innerProps={{ |
| 182 | ...getStyleProps(props, 'multiValue', { |
| 183 | 'multi-value': true, |
| 184 | 'multi-value--is-disabled': isDisabled, |
| 185 | }), |
| 186 | ...innerProps, |
| 187 | }} |
| 188 | selectProps={selectProps} |
| 189 | > |
| 190 | <Label |
| 191 | data={data} |
| 192 | innerProps={{ |
| 193 | ...getStyleProps(props, 'multiValueLabel', { |
| 194 | 'multi-value__label': true, |
| 195 | }), |
| 196 | }} |
| 197 | selectProps={selectProps} |
| 198 | > |
| 199 | {children} |
| 200 | </Label> |
| 201 | <Remove |
| 202 | data={data} |
| 203 | innerProps={{ |
| 204 | ...getStyleProps(props, 'multiValueRemove', { |
| 205 | 'multi-value__remove': true, |
| 206 | }), |
| 207 | 'aria-label': `Remove ${children || 'option'}`, |
| 208 | ...removeProps, |
| 209 | }} |
| 210 | selectProps={selectProps} |
| 211 | /> |
| 212 | </Container> |
| 213 | ); |
| 214 | }; |
| 215 | |
| 216 | export default MultiValue; |
nothing calls this directly
no test coverage detected
searching dependent graphs…