OS_Wrapper System: - Simplify API: Remove PageWrapper, merge keyboard props into OS_Wrapper - Add auto-scroll when keyboard appears (Android only) - Add tap-to-dismiss keyboard for both Static and List modes - Fix contentPaddingBottom default to 250px (prevent keyboard overlap) - Change default contentPadding to 0 (per-screen control) - Remove Platform.OS checks from IOSWrapper and AndroidWrapper Constants: - Add PADDING_INLINE constant (16px) for consistent inline padding - Add OS_PADDING_TOP constants for tab layouts Job Screens Migration (9 files): - Apply PADDING_INLINE to all Job screens: - ScreenBeranda, ScreenBeranda2 - ScreenArchive, ScreenArchive2 - MainViewStatus, MainViewStatus2 - ScreenJobCreate, ScreenJobEdit - Job detail screen Keyboard Handling: - Simplified useKeyboardForm hook - Auto-scroll by keyboard height when keyboard appears - Track scroll position for accurate scroll targets - TouchableWithoutFeedback wraps all content for tap-to-dismiss Documentation: - Update TASK-005 with Phase 1 completion status - Update Quick Reference with unified API examples Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
67 lines
1.5 KiB
TypeScript
67 lines
1.5 KiB
TypeScript
import { Platform } from "react-native";
|
|
|
|
export {
|
|
OS_ANDROID_HEIGHT,
|
|
OS_IOS_HEIGHT,
|
|
OS_HEIGHT,
|
|
OS_ANDROID_PADDING_TOP,
|
|
OS_IOS_PADDING_TOP,
|
|
OS_PADDING_TOP,
|
|
PADDING_INLINE,
|
|
TEXT_SIZE_SMALL,
|
|
TEXT_SIZE_MEDIUM,
|
|
TEXT_SIZE_LARGE,
|
|
TEXT_SIZE_XLARGE,
|
|
ICON_SIZE_XLARGE as ICON_SIZE_XLARGE,
|
|
ICON_SIZE_LARGE as ICON_SIZE_MEDIUM,
|
|
ICON_SIZE_MEDIUM as ICON_SIZE_SMALL,
|
|
ICON_SIZE_XSMALL as ICON_SIZE_XSMALL,
|
|
ICON_SIZE_SMALLL as ICON_SIZE_BUTTON,
|
|
DRAWER_HEIGHT,
|
|
RADIUS_BUTTON,
|
|
PADDING_EXTRA_SMALL,
|
|
PADDING_SMALL,
|
|
PADDING_MEDIUM,
|
|
PADDING_LARGE,
|
|
PAGINATION_DEFAULT_TAKE
|
|
};
|
|
|
|
// OS Height
|
|
const OS_ANDROID_HEIGHT = 60
|
|
const OS_IOS_HEIGHT = 80
|
|
const OS_HEIGHT = Platform.OS === "ios" ? OS_IOS_HEIGHT : OS_ANDROID_HEIGHT
|
|
|
|
// OS Padding Top
|
|
const OS_ANDROID_PADDING_TOP = 12
|
|
const OS_IOS_PADDING_TOP = 12
|
|
const OS_PADDING_TOP = Platform.OS === "ios" ? OS_IOS_PADDING_TOP : OS_ANDROID_PADDING_TOP
|
|
|
|
// Text Size
|
|
const TEXT_SIZE_SMALL = 12;
|
|
const TEXT_SIZE_MEDIUM = 14;
|
|
const TEXT_SIZE_LARGE = 16;
|
|
const TEXT_SIZE_XLARGE = 18;
|
|
|
|
// Icon Size
|
|
const ICON_SIZE_XSMALL = 10
|
|
const ICON_SIZE_SMALLL = 14
|
|
const ICON_SIZE_MEDIUM = 18;
|
|
const ICON_SIZE_LARGE = 22;
|
|
const ICON_SIZE_XLARGE = 26;
|
|
|
|
// Drawer Height
|
|
const DRAWER_HEIGHT = 500; // tinggi drawer5
|
|
|
|
// Radius Button
|
|
const RADIUS_BUTTON = 50
|
|
|
|
// Padding
|
|
const PADDING_INLINE = 16
|
|
const PADDING_EXTRA_SMALL = 10
|
|
const PADDING_SMALL = 12
|
|
const PADDING_MEDIUM = 16
|
|
const PADDING_LARGE = 20
|
|
|
|
// Pagination
|
|
const PAGINATION_DEFAULT_TAKE = 10;
|