Skip to content

Commit f54b35e

Browse files
committed
CU-868ffcgaz PR#169 fixes
1 parent 1e102e0 commit f54b35e

File tree

4 files changed

+4
-28
lines changed

4 files changed

+4
-28
lines changed

src/components/roles/roles-modal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export const RolesModal: React.FC<RolesModalProps> = ({ isOpen, onClose }) => {
7575
}, [activeUnit, pendingAssignments, onClose]);
7676

7777
return (
78-
<Modal isOpen={isOpen} onClose={onClose} size="full" {...({} as any)}>
78+
<Modal isOpen={isOpen} onClose={onClose} size="full">
7979
<ModalBackdrop />
8080
<ModalContent className="m-4 w-full max-w-3xl rounded-2xl">
8181
<ModalHeader>

src/components/status/__tests__/status-bottom-sheet.test.tsx

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ jest.mock('react-i18next', () => ({
44
}));
55

66
// Mock all UI components based on actual imports
7-
jest.mock('../../ui/actionsheet', () => {
7+
jest.mock('@/components/ui/actionsheet', () => {
88
const mockReact = require('react');
99
const { View } = require('react-native');
1010

@@ -231,30 +231,6 @@ import { StatusBottomSheet } from '../status-bottom-sheet';
231231

232232
const mockSetActiveCall = jest.fn();
233233

234-
// Mock the Actionsheet components
235-
jest.mock('@/components/ui/actionsheet', () => ({
236-
Actionsheet: ({ children, isOpen }: { children: React.ReactNode; isOpen: boolean }) => {
237-
const { View } = require('react-native');
238-
return isOpen ? <View testID="actionsheet">{children}</View> : null;
239-
},
240-
ActionsheetBackdrop: ({ children }: { children: React.ReactNode }) => {
241-
const { View } = require('react-native');
242-
return <View testID="actionsheet-backdrop">{children}</View>;
243-
},
244-
ActionsheetContent: ({ children }: { children: React.ReactNode }) => {
245-
const { View } = require('react-native');
246-
return <View testID="actionsheet-content">{children}</View>;
247-
},
248-
ActionsheetDragIndicator: () => {
249-
const { View } = require('react-native');
250-
return <View testID="actionsheet-drag-indicator" />;
251-
},
252-
ActionsheetDragIndicatorWrapper: ({ children }: { children: React.ReactNode }) => {
253-
const { View } = require('react-native');
254-
return <View testID="actionsheet-drag-indicator-wrapper">{children}</View>;
255-
},
256-
}));
257-
258234
const mockTranslation = {
259235
t: (key: string, options?: any) => {
260236
const translations: Record<string, string> = {

src/components/ui/bottomsheet/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ const BottomSheetContext = createContext<{
4141
handleOpen: () => void;
4242
}>({
4343
visible: false,
44-
bottomSheetRef: { current: null as any },
44+
bottomSheetRef: { current: null },
4545
handleClose: () => { },
4646
handleOpen: () => { },
4747
});

src/components/ui/skeleton/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ type ISkeletonTextProps = React.ComponentProps<typeof View> &
1717
startColor?: string;
1818
};
1919

20-
const Skeleton = forwardRef<any, ISkeletonProps>(({ className, variant, children, startColor = 'bg-background-200', isLoaded = false, speed = 2, ...props }, ref) => {
20+
const Skeleton = forwardRef<React.ElementRef<typeof View>, ISkeletonProps>(({ className, variant, children, startColor = 'bg-background-200', isLoaded = false, speed = 2, ...props }, ref) => {
2121
const pulseAnim = new Animated.Value(1);
2222
const customTimingFunction = Easing.bezier(0.4, 0, 0.6, 1);
2323
const fadeDuration = 0.6;

0 commit comments

Comments
 (0)