Skip to content
Draft
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
1 change: 0 additions & 1 deletion src/components/Appbar/AppbarContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ const AppbarContent = ({
numberOfLines={1}
accessible
role={onPress ? 'none' : 'heading'}
testID={`${testID}-title-text`}
maxFontSizeMultiplier={titleMaxFontSizeMultiplier}
>
{title}
Expand Down
1 change: 0 additions & 1 deletion src/components/Appbar/AppbarHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,6 @@ const AppbarHeader = ({

return (
<View
testID={`${testID}-root-layer`}
style={[
{
backgroundColor,
Expand Down
1 change: 0 additions & 1 deletion src/components/BottomNavigation/BottomNavigation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,6 @@ const BottomNavigation = <Route extends BaseRoute>({
safeAreaInsets={safeAreaInsets}
labelMaxFontSizeMultiplier={labelMaxFontSizeMultiplier}
compact={compact}
testID={`${testID}-bar`}
theme={theme}
/>
</View>
Expand Down
6 changes: 1 addition & 5 deletions src/components/BottomNavigation/BottomNavigationBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -494,10 +494,7 @@ const BottomNavigationBar = <Route extends BaseRoute>({
onLayout={onLayout}
container
>
<Animated.View
style={[styles.barContent, { backgroundColor }]}
testID={`${testID}-content`}
>
<Animated.View style={[styles.barContent, { backgroundColor }]}>
<View
style={[
styles.items,
Expand All @@ -510,7 +507,6 @@ const BottomNavigationBar = <Route extends BaseRoute>({
},
]}
role={'tablist'}
testID={`${testID}-content-wrapper`}
>
{routes.map((route, index) => {
const focused = navigationState.index === index;
Expand Down
4 changes: 1 addition & 3 deletions src/components/Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,6 @@ const Button = ({
<Surface
{...rest}
ref={ref}
testID={`${testID}-container`}
style={
[
styles.button,
Expand Down Expand Up @@ -366,7 +365,7 @@ const Button = ({
>
<View style={[styles.content, { opacity: textOpacity }, contentStyle]}>
{icon && loading !== true ? (
<View style={iconStyle} testID={`${testID}-icon-container`}>
<View style={iconStyle}>
<Icon
source={icon}
size={customLabelSize ?? iconSize}
Expand All @@ -393,7 +392,6 @@ const Button = ({
variant="labelLarge"
selectable={false}
numberOfLines={1}
testID={`${testID}-text`}
style={[
styles.label,
isMode('text')
Expand Down
2 changes: 0 additions & 2 deletions src/components/Card/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -236,14 +236,12 @@ const Card = ({
]}
theme={theme}
elevation={isMode('elevated') ? elevation : 0}
testID={`${testID}-container`}
container
{...rest}
>
{isMode('outlined') && (
<View
pointerEvents="none"
testID={`${testID}-outline`}
style={[
{
borderColor,
Expand Down
1 change: 0 additions & 1 deletion src/components/Checkbox/CheckboxItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,6 @@ const CheckboxItem = ({
{isLeading && checkbox}
<Text
variant={labelVariant}
testID={`${testID}-text`}
maxFontSizeMultiplier={labelMaxFontSizeMultiplier}
style={[styles.label, computedStyle, labelStyle]}
>
Expand Down
1 change: 0 additions & 1 deletion src/components/Chip/Chip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,6 @@ const Chip = ({
]}
elevation={elevationStyle}
{...rest}
testID={`${testID}-container`}
theme={theme}
container
>
Expand Down
3 changes: 1 addition & 2 deletions src/components/CrossFadeIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ const CrossFadeIcon = ({

return (
<View
testID={testID}
style={[
styles.content,
{
Expand All @@ -104,7 +105,6 @@ const CrossFadeIcon = ({
transform: [{ rotate: rotatePrev }],
},
]}
testID={`${testID}-previous`}
>
<Icon source={previousIcon} size={size} color={color} theme={theme} />
</Animated.View>
Expand All @@ -117,7 +117,6 @@ const CrossFadeIcon = ({
transform: [{ rotate: rotateNext }],
},
]}
testID={`${testID}-current`}
>
<Icon source={currentIcon} size={size} color={color} theme={theme} />
</Animated.View>
Expand Down
8 changes: 1 addition & 7 deletions src/components/DataTable/DataTableCell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ const DataTableCell = ({
>
<CellContent
textStyle={textStyle}
testID={testID}
maxFontSizeMultiplier={maxFontSizeMultiplier}
>
{children}
Expand All @@ -94,11 +93,7 @@ const CellContent = ({
children,
textStyle,
maxFontSizeMultiplier,
testID,
}: Pick<
Props,
'children' | 'textStyle' | 'testID' | 'maxFontSizeMultiplier'
>) => {
}: Pick<Props, 'children' | 'textStyle' | 'maxFontSizeMultiplier'>) => {
if (React.isValidElement(children)) {
return children;
}
Expand All @@ -108,7 +103,6 @@ const CellContent = ({
style={textStyle}
numberOfLines={1}
maxFontSizeMultiplier={maxFontSizeMultiplier}
testID={`${testID}-text-container`}
>
{children}
</Text>
Expand Down
6 changes: 1 addition & 5 deletions src/components/Drawer/DrawerCollapsedItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -189,13 +189,9 @@ const DrawerCollapsedItem = ({
},
style,
]}
testID={`${testID}-outline`}
/>

<View
style={[styles.icon, { top: iconPadding }]}
testID={`${testID}-container`}
>
<View style={[styles.icon, { top: iconPadding }]}>
{badge !== false && (
<View style={styles.badgeContainer}>
{typeof badge === 'boolean' ? (
Expand Down
3 changes: 0 additions & 3 deletions src/components/FAB/Content.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ export type ContentProps = {
labelAnimatedStyle?: StyleProp<AnimatedStyle<ViewStyle>>;
labelNumberOfLines?: number;
labelEllipsisMode?: 'clip' | 'tail' | 'head' | 'middle';
testID?: string;
};

/**
Expand All @@ -50,7 +49,6 @@ const Content = ({
labelAnimatedStyle,
labelNumberOfLines,
labelEllipsisMode,
testID,
}: ContentProps) => {
const hasLabel = label !== undefined && label !== '';
const colorStyle = { color: contentColor };
Expand Down Expand Up @@ -86,7 +84,6 @@ const Content = ({
ellipsizeMode={labelEllipsisMode}
maxFontSizeMultiplier={labelMaxFontSizeMultiplier}
style={colorStyle}
testID={testID ? `${testID}-text` : undefined}
>
{label}
</AnimatedText>
Expand Down
1 change: 0 additions & 1 deletion src/components/FAB/Menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,6 @@ const MenuItem = ({
leading={leading}
trailing={trailing}
iconLabelGap={iconLabelGap}
testID={testID}
/>
</TouchableRipple>
</View>
Expand Down
2 changes: 0 additions & 2 deletions src/components/FAB/Shell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,6 @@ const Shell = ({
shadowStyle,
visible ? styles.pointerEventsAuto : styles.pointerEventsNone,
]}
testID={`${testID}-container`}
>
<Reanimated.View style={[styles.clip, clipStyle]}>
{overlay}
Expand Down Expand Up @@ -332,7 +331,6 @@ const Shell = ({
labelAnimatedStyle={labelAnimatedStyle}
labelNumberOfLines={labelAnimatedStyle ? 1 : undefined}
labelEllipsisMode={labelAnimatedStyle ? 'clip' : undefined}
testID={testID}
/>
)}
</TouchableRipple>
Expand Down
1 change: 0 additions & 1 deletion src/components/IconButton/IconButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ const IconButton = ({
return (
<Surface
ref={ref}
testID={`${testID}-container`}
style={[
{
backgroundColor: backgroundOpacity < 1 ? undefined : backgroundColor,
Expand Down
5 changes: 1 addition & 4 deletions src/components/List/ListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -240,10 +240,7 @@ const ListItem = ({
style: getLeftStyles(alignToTop, description),
})
: null}
<View
style={[styles.item, styles.content, contentStyle]}
testID={`${testID}-content`}
>
<View style={[styles.item, styles.content, contentStyle]}>
{renderTitle()}

{description
Expand Down
3 changes: 1 addition & 2 deletions src/components/Menu/Menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,6 @@ const Menu = ({
style={[styles.wrapper, positionStyle, style]}
pointerEvents={pointerEvents}
onAccessibilityEscape={onDismiss}
testID={`${testID}-view`}
>
<Animated.View
pointerEvents={pointerEvents}
Expand All @@ -675,7 +674,7 @@ const Menu = ({
contentStyle,
]}
elevation={elevation}
testID={`${testID}-surface`}
testID={testID}
theme={theme}
container
>
Expand Down
1 change: 0 additions & 1 deletion src/components/Menu/MenuItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,6 @@ const MenuItem = ({
variant="bodyLarge"
selectable={false}
numberOfLines={1}
testID={`${testID}-title`}
style={[titleTextStyle, titleStyle]}
maxFontSizeMultiplier={titleMaxFontSizeMultiplier}
>
Expand Down
3 changes: 0 additions & 3 deletions src/components/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,6 @@ function Modal({
}),
},
]}
testID={`${testID}-backdrop`}
/>
<View
style={[
Expand All @@ -213,10 +212,8 @@ function Modal({
style,
]}
pointerEvents="box-none"
testID={`${testID}-wrapper`}
>
<Surface
testID={`${testID}-surface`}
theme={theme}
style={[{ opacity }, styles.content, contentContainerStyle]}
container
Expand Down
1 change: 0 additions & 1 deletion src/components/ProgressBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ const ProgressBar = ({
>
{width ? (
<Animated.View
testID={`${testID}-fill`}
style={[
styles.progressBar,
{
Expand Down
6 changes: 0 additions & 6 deletions src/components/Searchbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,6 @@ const Searchbar = ({
styles.container,
style,
]}
testID={`${testID}-container`}
elevation={elevation}
container
theme={theme}
Expand All @@ -262,7 +261,6 @@ const Searchbar = ({
}
theme={theme}
aria-label={searchAccessibilityLabel}
testID={`${testID}-icon`}
/>
<TextInput
style={[
Expand Down Expand Up @@ -300,7 +298,6 @@ const Searchbar = ({
// when clearing the value.
<View
pointerEvents={value ? 'auto' : 'none'}
testID={`${testID}-icon-wrapper`}
style={[
!value && styles.v3ClearIcon,
right !== undefined && styles.v3ClearIconHidden,
Expand All @@ -322,7 +319,6 @@ const Searchbar = ({
/>
))
}
testID={`${testID}-clear-icon`}
role="button"
theme={theme}
/>
Expand All @@ -336,7 +332,6 @@ const Searchbar = ({
iconColor={traileringIconColor || colors.onSurfaceVariant}
icon={traileringIcon}
aria-label={traileringIconAccessibilityLabel}
testID={`${testID}-trailering-icon`}
/>
) : null}
{isBarMode &&
Expand All @@ -350,7 +345,6 @@ const Searchbar = ({
backgroundColor: colors.outline,
},
]}
testID={`${testID}-divider`}
/>
)}
</Surface>
Expand Down
4 changes: 1 addition & 3 deletions src/components/SegmentedButtons/SegmentedButtonItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -211,14 +211,13 @@ const SegmentedButtonItem = ({
>
{showCheckedIcon ? (
<Animated.View
testID={`${testID}-check-icon`}
style={[iconStyle, { transform: [{ scale: checkScale }] }]}
>
<Icon source={'check'} size={iconSize} color={textColor} />
</Animated.View>
) : null}
{showIcon ? (
<Animated.View testID={`${testID}-icon`} style={iconStyle}>
<Animated.View style={iconStyle}>
<Icon source={icon} size={iconSize} color={textColor} />
</Animated.View>
) : null}
Expand All @@ -228,7 +227,6 @@ const SegmentedButtonItem = ({
selectable={false}
numberOfLines={1}
maxFontSizeMultiplier={labelMaxFontSizeMultiplier}
testID={`${testID}-label`}
>
{label}
</Text>
Expand Down
1 change: 0 additions & 1 deletion src/components/Snackbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,6 @@ const Snackbar = ({
}
aria-label={iconAccessibilityLabel}
style={styles.icon}
testID={`${testID}-icon`}
/>
) : null}
</View>
Expand Down
6 changes: 1 addition & 5 deletions src/components/Surface.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,7 @@ const SurfaceIOS = ({
}, [style, elevation, backgroundColor, shadowColor, mode, container]);

return (
<Animated.View
ref={ref}
style={outerLayerViewStyles}
testID={`${testID}-outer-layer`}
>
<Animated.View ref={ref} style={outerLayerViewStyles}>
<Animated.View {...props} style={innerLayerViewStyles} testID={testID}>
{children}
</Animated.View>
Expand Down
Loading