Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/react-select/src/Select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,8 @@ export interface Props<
components: SelectComponentsConfig<Option, IsMulti, Group>;
/** Whether the value of the select, e.g. SingleValue, should be displayed in the control. */
controlShouldRenderValue: boolean;
/** Testing id applied to the outer Select container */
'data-testid'?: string;
/** Delimiter used to join multiple values into a single HTML Input value */
delimiter?: string;
/** Clear all values when the user presses escape AND the menu is closed */
Expand Down
3 changes: 2 additions & 1 deletion packages/react-select/src/components/containers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,15 @@ export const SelectContainer = <
>(
props: ContainerProps<Option, IsMulti, Group>
) => {
const { children, innerProps, isDisabled, isRtl } = props;
const { children, innerProps, isDisabled, isRtl, selectProps } = props;
return (
<div
{...getStyleProps(props, 'container', {
'--is-disabled': isDisabled,
'--is-rtl': isRtl,
})}
{...innerProps}
data-testid={selectProps['data-testid']}
>
{children}
</div>
Expand Down