iOS 웹뷰 이미지 저장 기능 추가 (네이티브 브릿지)
- iOS 환경에서 이미지 다운로드가 안 되는 문제 해결 - 네이티브 앱 브릿지를 통한 이미지 저장 기능 구현 - iOS만 네이티브 브릿지 사용, Android/웹은 기존 방식 유지 변경사항: - BridgeMessageType에 SAVE_IMAGE 타입 추가 - SaveImageRequest, SaveImageResponse 인터페이스 정의 - appBridge.saveImage() 메서드 구현 - cash-receipt-sample.tsx에서 iOS 환경 감지 및 네이티브 저장 처리 - 네이티브 앱 개발자를 위한 구현 가이드 문서 추가 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -82,7 +82,10 @@ export enum BridgeMessageType {
|
||||
SET_NOTIFICATION_SETTING = 'setNotificationSetting',
|
||||
|
||||
// 알림 링크 확인
|
||||
CHECK_ALARM_LINK = 'checkAlarmLink'
|
||||
CHECK_ALARM_LINK = 'checkAlarmLink',
|
||||
|
||||
// 이미지 저장
|
||||
SAVE_IMAGE = 'saveImage'
|
||||
}
|
||||
|
||||
export interface DeviceInfo {
|
||||
@@ -118,4 +121,16 @@ export interface NotificationSettingResponse {
|
||||
enabled: boolean;
|
||||
needsPermission?: boolean;
|
||||
message?: string;
|
||||
}
|
||||
|
||||
export interface SaveImageRequest {
|
||||
imageData: string; // base64 encoded image data
|
||||
fileName?: string; // 파일명 (optional, default: timestamp)
|
||||
mimeType?: string; // MIME 타입 (optional, default: 'image/png')
|
||||
}
|
||||
|
||||
export interface SaveImageResponse {
|
||||
success: boolean;
|
||||
filePath?: string; // 저장된 파일 경로
|
||||
error?: string;
|
||||
}
|
||||
Reference in New Issue
Block a user