Skip to content
Merged
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion __mocks__/expo-video.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ const VideoView = forwardRef((props: VideoViewProps, ref: ForwardedRef<View>) =>
<View
ref={ref}
accessibilityLabel="MockVideoView"
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
/>
));
Expand Down
2 changes: 0 additions & 2 deletions __mocks__/react-native-safe-area-context.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ function withSafeAreaInsets(WrappedComponent: React.ComponentType<WithSafeAreaIn
function WithSafeAreaInsets(props: WithSafeAreaInsetsProps & {ref: React.ForwardedRef<unknown>}) {
return (
<WrappedComponent
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
ref={props.ref}
insets={insets}
Expand All @@ -34,7 +33,6 @@ function withSafeAreaInsets(WrappedComponent: React.ComponentType<WithSafeAreaIn
function WithSafeAreaInsetsWithRef(props: WithSafeAreaInsetsProps & {ref: ForwardedRef<unknown>}) {
return (
<WithSafeAreaInsets
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
ref={props.ref}
/>
Expand Down
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@
"dotenv": "^16.0.3",
"eslint": "^9.36.0",
"eslint-config-airbnb-typescript": "^18.0.0",
"eslint-config-expensify": "3.0.1",
"eslint-config-expensify": "3.0.2",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-file-progress": "3.0.1",
"eslint-plugin-jest": "^29.0.1",
Expand Down
1 change: 0 additions & 1 deletion src/components/AccountSwitcher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,6 @@ function AccountSwitcher({isScreenFocused}: AccountSwitcherProps) {

return (
<>
{/* eslint-disable-next-line react/jsx-props-no-spreading */}
<TooltipToRender {...tooltipProps}>
<PressableWithFeedback
accessible
Expand Down
2 changes: 0 additions & 2 deletions src/components/ActionSheetAwareScrollView/index.android.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ function ActionSheetAwareScrollView({style, children, ref, ...restProps}: Action

return (
<Reanimated.ScrollView
// eslint-disable-next-line react/jsx-props-no-spreading
{...restProps}
ref={onRef}
style={style}
Expand All @@ -28,7 +27,6 @@ function ActionSheetAwareScrollView({style, children, ref, ...restProps}: Action
* @returns - ActionSheetAwareScrollView
*/
const renderScrollComponent: RenderActionSheetAwareScrollViewComponent = (props) => {
// eslint-disable-next-line react/jsx-props-no-spreading
return <ActionSheetAwareScrollView {...props} />;
};

Expand Down
2 changes: 0 additions & 2 deletions src/components/ActionSheetAwareScrollView/index.ios.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ function ActionSheetAwareScrollView({style, children, ref, ...restProps}: Action

return (
<Reanimated.ScrollView
// eslint-disable-next-line react/jsx-props-no-spreading
{...restProps}
ref={onRef}
style={[style, animatedStyle]}
Expand All @@ -34,7 +33,6 @@ function ActionSheetAwareScrollView({style, children, ref, ...restProps}: Action
* @returns - ActionSheetAwareScrollView
*/
const renderScrollComponent: RenderActionSheetAwareScrollViewComponent = (props) => {
// eslint-disable-next-line react/jsx-props-no-spreading
return <ActionSheetAwareScrollView {...props} />;
};

Expand Down
2 changes: 0 additions & 2 deletions src/components/ActionSheetAwareScrollView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ function ActionSheetAwareScrollView({children, ref, ...restProps}: ActionSheetAw

return (
<Reanimated.ScrollView
// eslint-disable-next-line react/jsx-props-no-spreading
{...restProps}
ref={onRef}
>
Expand All @@ -30,7 +29,6 @@ function ActionSheetAwareScrollView({children, ref, ...restProps}: ActionSheetAw
*/

const renderScrollComponent: RenderActionSheetAwareScrollViewComponent = (props) => {
// eslint-disable-next-line react/jsx-props-no-spreading
return <ActionSheetAwareScrollView {...props} />;
};

Expand Down
1 change: 0 additions & 1 deletion src/components/ActivityIndicator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ function ActivityIndicator({timeout = CONST.TIMING.ACTIVITY_INDICATOR_TIMEOUT, e
return (
<RNActivityIndicator
color={theme.spinner}
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/AmountPicker/AmountSelectorModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ function AmountSelectorModal({value, description = '', onValueSelected, isVisibl
>
<View style={styles.flex1}>
<NumberWithSymbolForm
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
value={currentValue}
onInputChange={setValue}
Expand Down
1 change: 0 additions & 1 deletion src/components/AmountPicker/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ function AmountPicker({value, description, title, errorText = '', onInputChange,
errorText={errorText}
/>
<AmountSelectorModal
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
value={value}
isVisible={isPickerVisible}
Expand Down
1 change: 0 additions & 1 deletion src/components/AmountTextInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ function AmountTextInput({
shouldApplyPaddingToContainer={shouldApplyPaddingToContainer}
rightHandSideComponent={rightHandSideComponent}
navigation={navigation}
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/AmountWithoutCurrencyInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ function AmountWithoutCurrencyInput({
// On android autoCapitalize="words" is necessary when keyboardType="decimal-pad" or inputMode="decimal" to prevent input lag.
// See https://github.com/Expensify/App/issues/51868 for more information
autoCapitalize="words"
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/AnchorForAttachmentsOnly/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ function AnchorForAttachmentsOnly(props: AnchorForAttachmentsOnlyProps) {
const styles = useThemeStyles();
return (
<BaseAnchorForAttachmentsOnly
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
style={styles.mw100}
/>
Expand Down
1 change: 0 additions & 1 deletion src/components/AnchorForAttachmentsOnly/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import type AnchorForAttachmentsOnlyProps from './types';
function AnchorForAttachmentsOnly(props: AnchorForAttachmentsOnlyProps) {
return (
<BaseAnchorForAttachmentsOnly
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
onPressIn={() => DeviceCapabilities.canUseTouchScreen() && ControlSelection.block()}
onPressOut={() => ControlSelection.unblock()}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ function BaseAnchorForCommentsOnly({
suppressHighlighting
// Add testID so it gets selected as an anchor tag by SelectionScraper
testID="a"
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
>
{children}
Expand Down
1 change: 0 additions & 1 deletion src/components/AnchorForCommentsOnly/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ function AnchorForCommentsOnly({onPress, href = '', ...props}: AnchorForComments

return (
<BaseAnchorForCommentsOnly
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
href={href}
onPress={onLinkPress}
Expand Down
1 change: 0 additions & 1 deletion src/components/AnchorForCommentsOnly/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import type {AnchorForCommentsOnlyProps} from './types';
function AnchorForCommentsOnly(props: AnchorForCommentsOnlyProps) {
return (
<BaseAnchorForCommentsOnly
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
onPressIn={() => DeviceCapabilities.canUseTouchScreen() && ControlSelection.block()}
onPressOut={() => ControlSelection.unblock()}
Expand Down
2 changes: 0 additions & 2 deletions src/components/AnimatedFlatListWithCellRenderer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ const createCellRendererComponent = <Item,>(CellRendererComponentProp?: CellRend
onLayout={props.onLayout}
style={CellRendererComponentProp ? undefined : props.style}
>
{/* eslint-disable-next-line react/jsx-props-no-spreading */}
{CellRendererComponentProp ? <CellRendererComponentProp {...props}>{props.children}</CellRendererComponentProp> : props.children}
</Animated.View>
);
Expand Down Expand Up @@ -82,7 +81,6 @@ function FlatListRender<Item = any>(props: AnimatedFlatListWithCellRendererProps
// @ts-expect-error In its current type state, createAnimatedComponent cannot create generic components.
<AnimatedFlatList
ref={ref}
// eslint-disable-next-line react/jsx-props-no-spreading
{...restProps}
CellRendererComponent={CellRendererComponent}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ function AttachmentViewPdf(props: AttachmentViewPdfProps) {
const Content = useMemo(
() => (
<BaseAttachmentViewPdf
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
onScaleChanged={(newScale) => {
// The react-native-pdf's onScaleChanged event will sometimes give us scale values of e.g. 0.99... instead of 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,7 @@ import BaseAttachmentViewPdf from './BaseAttachmentViewPdf';
import type AttachmentViewPdfProps from './types';

function AttachmentViewPdf(props: AttachmentViewPdfProps) {
return (
<BaseAttachmentViewPdf
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
/>
);
return <BaseAttachmentViewPdf {...props} />;
}

export default memo(AttachmentViewPdf);
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,8 @@ function AutoCompleteSuggestionsPortal<TSuggestion>({
<Portal hostName="suggestions">
<TransparentOverlay onPress={resetSuggestions} />
<View style={styles}>
{}
<BaseAutoCompleteSuggestions<TSuggestion>
width={width}
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
/>
</View>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ function AutoCompleteSuggestionsPortal<TSuggestion>({
const componentToRender = (
<BaseAutoCompleteSuggestions<TSuggestion>
width={width}
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/AutoCompleteSuggestions/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,6 @@ function AutoCompleteSuggestions<TSuggestion>({measureParentContainerAndReportCu

return (
<AutoCompleteSuggestionsPortal
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
left={containerState.left}
width={containerState.width}
Expand Down
2 changes: 1 addition & 1 deletion src/components/BaseWidgetItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function BaseWidgetItem({icon, iconBackgroundColor, title, subtitle, ctaText, on
small
style={styles.widgetItemButton}
// Prop spreading allows parent components to pass additional button styling props (e.g., danger: true, success: true)
// eslint-disable-next-line react/jsx-props-no-spreading

{...buttonProps}
/>
</View>
Expand Down
1 change: 0 additions & 1 deletion src/components/Button/ButtonDisabledWhenOffline.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ function ButtonDisabledWhenOffline({disabledWhenOffline = true, ...props}: Butto
const {isOffline} = useNetwork();
return (
<Button
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
isDisabled={disabledWhenOffline && isOffline}
/>
Expand Down
4 changes: 0 additions & 4 deletions src/components/CardFeedIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ function CardFeedIcon({iconProps, selectedFeed, isExpensifyCardFeed = false, use
const isPlaidCardFeed = !!getPlaidInstitutionId(selectedFeed);

if (isExpensifyCardFeed) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <ExpensifyCardFeedIcon {...iconProps} />;
}

Expand All @@ -33,7 +32,6 @@ function CardFeedIcon({iconProps, selectedFeed, isExpensifyCardFeed = false, use
<PlaidCardFeedIcon
plaidUrl={getPlaidInstitutionIconUrl(selectedFeed)}
useSkeletonLoader={useSkeletonLoader}
// eslint-disable-next-line react/jsx-props-no-spreading
{...restIconProps}
/>
);
Expand All @@ -46,7 +44,6 @@ function CardFeedIcon({iconProps, selectedFeed, isExpensifyCardFeed = false, use
return (
<Icon
src={src ?? getCardFeedIcon(selectedFeed, illustrations, companyCardFeedIcons)}
// eslint-disable-next-line react/jsx-props-no-spreading
{...restIconProps}
/>
);
Expand All @@ -60,7 +57,6 @@ function ExpensifyCardFeedIcon(iconProps: Partial<IconProps>) {
return (
<Icon
src={memoizedIllustrations.ExpensifyCardImage}
// eslint-disable-next-line react/jsx-props-no-spreading
{...restIconProps}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/Charts/BarChart/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import type {BarChartProps} from './BarChartContent';
import BarChartContent from './BarChartContent';

function BarChart(props: BarChartProps) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <BarChartContent {...props} />;
}

Expand Down
1 change: 0 additions & 1 deletion src/components/Charts/LineChart/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import type {LineChartProps} from './LineChartContent';
import LineChartContent from './LineChartContent';

function LineChart(props: LineChartProps) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <LineChartContent {...props} />;
}

Expand Down
1 change: 0 additions & 1 deletion src/components/Charts/PieChart/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import type {PieChartProps} from './PieChartContent';
import PieChartContent from './PieChartContent';

function PieChart(props: PieChartProps) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <PieChartContent {...props} />;
}

Expand Down
1 change: 0 additions & 1 deletion src/components/Composer/implementation/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ function Composer({
textAlignVertical="center"
style={[composerStyle, maxHeightStyle]}
markdownStyle={markdownStyle}
/* eslint-disable-next-line react/jsx-props-no-spreading */
{...props}
autoFocus={isInLandscapeMode ? false : props.autoFocus}
readOnly={isDisabled}
Expand Down
1 change: 0 additions & 1 deletion src/components/Composer/implementation/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,6 @@ function Composer({
value={value}
defaultValue={defaultValue}
autoFocus={autoFocus}
/* eslint-disable-next-line react/jsx-props-no-spreading */
{...props}
onSelectionChange={addCursorPositionToSelectionChange}
onContentSizeChange={(e) => {
Expand Down
1 change: 0 additions & 1 deletion src/components/CurrencySelectionList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ function CurrencySelectionList({

return (
<SelectionListWithSections
// eslint-disable-next-line react/jsx-props-no-spreading
{...restProps}
sections={sections}
ListItem={SingleSelectListItem}
Expand Down
1 change: 0 additions & 1 deletion src/components/DistanceMapView/index.android.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ function DistanceMapView({overlayStyle, requireRouteToDisplayMap, ...rest}: Dist
return (
<>
<MapView
// eslint-disable-next-line react/jsx-props-no-spreading
{...rest}
onMapReady={() => {
if (isMapReady) {
Expand Down
1 change: 0 additions & 1 deletion src/components/DistanceMapView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import MapView from '@components/MapView';
import type DistanceMapViewProps from './types';

function DistanceMapView({overlayStyle, ...rest}: DistanceMapViewProps) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <MapView {...rest} />;
}

Expand Down
2 changes: 0 additions & 2 deletions src/components/DraggableList/SortableItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,7 @@ function SortableItem({id, children, disabled = false, isFocused = false}: Sorta
// Use capture phase to intercept Enter before inner MenuItem handles it
onKeyDownCapture={handleKeyDown}
onClick={handleClick}
// eslint-disable-next-line react/jsx-props-no-spreading
{...attributes}
// eslint-disable-next-line react/jsx-props-no-spreading
{...(disabled ? {} : listeners)}
role="button"
tabIndex={0}
Expand Down
1 change: 0 additions & 1 deletion src/components/DraggableList/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ function DraggableList<T>({ref, onSelectRow, focusedIndex, isItemDragDisabled, i
containerStyle={styles.flex1}
contentContainerStyle={styles.flexGrow1}
ListFooterComponentStyle={styles.flex1}
// eslint-disable-next-line react/jsx-props-no-spreading
{...viewProps}
/>
);
Expand Down
1 change: 0 additions & 1 deletion src/components/EmbeddedDemo/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ function EmbeddedDemo({url, webViewProps}: EmbeddedDemoProps) {
source={{uri: url}}
originWhitelist={testDrive.EMBEDDED_DEMO_WHITELIST}
style={styles.flex1}
// eslint-disable-next-line react/jsx-props-no-spreading
{...webViewProps}
/>
);
Expand Down
Loading
Loading