refactor: Cleanup test files and migrate Job Detail screen
- Delete ScreenJobCreate2.tsx and ScreenJobEdit2.tsx (test files) - Delete TestWrapper.tsx and TestKeyboardInput.tsx (test components) - Delete test pages (test-keyboard.tsx, test-keyboard-bug.tsx) - Update create.tsx to use ScreenJobCreate (not test version) - Update edit.tsx to use ScreenJobEdit (not test version) - Migrate Job Detail screen to NewWrapper_V2 - Remove TestWrapper from exports - Clean up imports Phase 1 cleanup completed! Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
@@ -1,45 +0,0 @@
|
||||
// TestWrapper.tsx - Wrapper sederhana untuk test keyboard handling
|
||||
import { MainColor } from "@/constants/color-palet";
|
||||
import {
|
||||
Keyboard,
|
||||
KeyboardAvoidingView,
|
||||
Platform,
|
||||
ScrollView,
|
||||
View,
|
||||
} from "react-native";
|
||||
import {
|
||||
NativeSafeAreaViewProps,
|
||||
SafeAreaView,
|
||||
} from "react-native-safe-area-context";
|
||||
|
||||
interface TestWrapperProps {
|
||||
children: React.ReactNode;
|
||||
footerComponent?: React.ReactNode;
|
||||
}
|
||||
|
||||
export function TestWrapper({ children, footerComponent }: TestWrapperProps) {
|
||||
return (
|
||||
<KeyboardAvoidingView
|
||||
behavior="padding" // ← FIX: Gunakan padding untuk iOS & Android (NOT "height" untuk Android!)
|
||||
style={{ flex: 1, backgroundColor: MainColor.darkblue }}
|
||||
keyboardVerticalOffset={0}
|
||||
>
|
||||
<ScrollView
|
||||
style={{ flex: 1 }}
|
||||
contentContainerStyle={{ flexGrow: 1 }}
|
||||
keyboardShouldPersistTaps="handled"
|
||||
>
|
||||
<View style={{ flex: 1, padding: 10 }}>{children}</View>
|
||||
</ScrollView>
|
||||
|
||||
{footerComponent && (
|
||||
<SafeAreaView
|
||||
edges={["bottom"]}
|
||||
style={{ flex: 1, backgroundColor: MainColor.red }}
|
||||
>
|
||||
{footerComponent}
|
||||
</SafeAreaView>
|
||||
)}
|
||||
</KeyboardAvoidingView>
|
||||
);
|
||||
}
|
||||
@@ -63,7 +63,6 @@ import DummyLandscapeImage from "./_ShareComponent/DummyLandscapeImage";
|
||||
import GridComponentView from "./_ShareComponent/GridSectionView";
|
||||
import NewWrapper from "./_ShareComponent/NewWrapper";
|
||||
import BasicWrapper from "./_ShareComponent/BasicWrapper";
|
||||
import { TestWrapper } from "./_ShareComponent/TestWrapper";
|
||||
import { FormWrapper } from "./_ShareComponent/FormWrapper";
|
||||
import { NewWrapper_V2 } from "./_ShareComponent/NewWrapper_V2";
|
||||
|
||||
@@ -131,7 +130,6 @@ export {
|
||||
Spacing,
|
||||
NewWrapper,
|
||||
BasicWrapper,
|
||||
TestWrapper,
|
||||
FormWrapper,
|
||||
NewWrapper_V2,
|
||||
// Stack
|
||||
|
||||
Reference in New Issue
Block a user