@apps-in-toss/native-modules 1.9.3 → 1.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as _apps_in_toss_types from '@apps-in-toss/types';
2
- import { Location, StartUpdateLocationEventParams, Accuracy, CompatiblePlaceholderArgument, SetClipboardTextOptions, FetchContactsOptions, ContactResult, FetchAlbumPhotosOptions, ImageResponse, GetCurrentLocationOptions, OpenCameraOptions, PermissionName, PermissionAccess, PermissionStatus, FetchAlbumPhotos, FetchContacts, GetClipboardText, GetCurrentLocation, SetClipboardText, OpenCamera } from '@apps-in-toss/types';
3
- export { StartUpdateLocationPermissionError } from '@apps-in-toss/types';
2
+ import { Location, StartUpdateLocationEventParams, Accuracy, LoadAdMobParams, ShowAdMobParams, IsAdMobLoadedOptions, CompatiblePlaceholderArgument, SetClipboardTextOptions, FetchContactsOptions, ContactResult, FetchAlbumPhotosOptions, ImageResponse, GetCurrentLocationOptions, OpenCameraOptions, PermissionName, PermissionAccess, PermissionStatus, FetchAlbumPhotos, FetchContacts, GetClipboardText, GetCurrentLocation, SetClipboardText, OpenCamera } from '@apps-in-toss/types';
3
+ export { IsAdMobLoadedOptions, LoadAdMobEvent, LoadAdMobOptions, LoadAdMobParams, ShowAdMobEvent, ShowAdMobOptions, ShowAdMobParams, StartUpdateLocationPermissionError } from '@apps-in-toss/types';
4
4
  import { GraniteEventDefinition, GraniteEvent } from '@granite-js/react-native';
5
5
  import { EmitterSubscription, TurboModule } from 'react-native';
6
6
 
@@ -308,137 +308,6 @@ declare const INTERNAL__appBridgeHandler: {
308
308
  getCallbackIds: typeof getCallbackIds;
309
309
  };
310
310
 
311
- /**
312
- * @public
313
- * @category 광고
314
- * @name AdMobFullScreenEvent
315
- * @description 앱 화면을 덮는 광고(예: 전면 광고, 보상형 광고)를 사용하는 경우에 발생하는 이벤트 타입이에요.
316
- * @example
317
- * ### 광고 이벤트 처리하기
318
- * ```ts
319
- * function handleEvent(event: AdMobFullScreenEvent) {
320
- * switch (event.type) {
321
- * case 'clicked':
322
- * console.log('광고가 클릭됐어요.');
323
- * break;
324
- *
325
- * case 'dismissed':
326
- * console.log('광고가 닫혔어요.');
327
- * break;
328
- *
329
- * case 'failedToShow':
330
- * console.log('광고가 보여지지 않았어요.');
331
- * break;
332
- *
333
- * case 'impression':
334
- * console.log('광고가 노출됐어요.');
335
- * break;
336
- *
337
- * case 'show':
338
- * console.log('광고가 보여졌어요.');
339
- * break;
340
- * }
341
- * }
342
- * ```
343
- */
344
- type AdMobFullScreenEvent = AdClicked | AdDismissed | AdFailedToShow | AdImpression | AdShow;
345
- type AdClicked = {
346
- type: 'clicked';
347
- };
348
- type AdDismissed = {
349
- type: 'dismissed';
350
- };
351
- type AdFailedToShow = {
352
- type: 'failedToShow';
353
- };
354
- type AdImpression = {
355
- type: 'impression';
356
- };
357
- type AdShow = {
358
- type: 'show';
359
- };
360
- type AdUserEarnedReward = {
361
- type: 'userEarnedReward';
362
- data: {
363
- unitType: string;
364
- unitAmount: number;
365
- };
366
- };
367
- interface AdMobHandlerParams<Options = void, Event = AdMobFullScreenEvent> {
368
- options: Options;
369
- onEvent: (event: Event) => void;
370
- onError: (error: unknown) => void;
371
- }
372
- /**
373
- * @public
374
- * @category 광고
375
- * @name ResponseInfo
376
- * @description 광고 로드 응답 정보를 담고 있는 객체예요.
377
- * @property {Array<AdNetworkResponseInfo>} adNetworkInfoArray 광고 네트워크 응답 정보 배열예요.
378
- * @property {AdNetworkResponseInfo | null} loadedAdNetworkInfo 로드된 광고 네트워크 응답 정보예요.
379
- * @property {string | null} responseId 광고 응답 ID예요.
380
- */
381
- interface ResponseInfo {
382
- adNetworkInfoArray: Array<AdNetworkResponseInfo>;
383
- loadedAdNetworkInfo: AdNetworkResponseInfo | null;
384
- responseId: string | null;
385
- }
386
- /**
387
- * @public
388
- * @category 광고
389
- * @name AdNetworkResponseInfo
390
- * @description 광고 네트워크 응답 정보를 담고 있는 객체예요.
391
- * @property {string} adSourceId 광고 소스 ID예요.
392
- * @property {string} adSourceName 광고 소스 이름이예요.
393
- * @property {string} adSourceInstanceId 광고 소스 인스턴스 ID예요.
394
- * @property {string} adSourceInstanceName 광고 소스 인스턴스 이름이예요.
395
- * @property {string | null} adNetworkClassName 광고 네트워크 클래스 이름이예요.
396
- */
397
- interface AdNetworkResponseInfo {
398
- adSourceId: string;
399
- adSourceName: string;
400
- adSourceInstanceId: string;
401
- adSourceInstanceName: string;
402
- adNetworkClassName: string | null;
403
- }
404
- /**
405
- * @public
406
- * @category 광고
407
- * @name AdMobLoadResult
408
- * @description 광고의 ID와 응답 정보를 담고 있는 객체예요. 광고를 로드한 뒤, 관련 정보를 확인할 때 유용해요.
409
- * @property {string} adGroupId 광고 그룹 ID예요.
410
- * @property {string} adUnitId 광고 ID예요.
411
- * @property {ResponseInfo} responseInfo 광고 로드 응답 정보예요. 자세한 내용은 [ResponseInfo](/react-native/reference/native-modules/광고/ResponseInfo.html)를 참고하세요.
412
- */
413
- interface AdMobLoadResult {
414
- adGroupId: string;
415
- adUnitId: string;
416
- responseInfo: ResponseInfo;
417
- }
418
-
419
- interface LoadAdMobOptions {
420
- /**
421
- * 광고 그룹 단위 ID
422
- */
423
- adGroupId: string;
424
- }
425
- /**
426
- * @public
427
- * @category 광고
428
- * @name LoadAdMobEvent
429
- * @description 광고를 불러오는 함수에서 발생하는 이벤트 타입이에요. `loaded` 이벤트가 발생하면 광고를 성공적으로 불러온 거예요. 이때 [AdMobLoadResult](/react-native/reference/native-modules/광고/AdMobLoadResult.html) 객체가 함께 반환돼요.
430
- */
431
- type LoadAdMobEvent = {
432
- type: 'loaded';
433
- data: AdMobLoadResult;
434
- };
435
- /**
436
- * @public
437
- * @category 광고
438
- * @name LoadAdMobParams
439
- * @description 광고를 불러오는 함수에 필요한 옵션 객체예요.
440
- */
441
- type LoadAdMobParams = AdMobHandlerParams<LoadAdMobOptions, LoadAdMobEvent>;
442
311
  /**
443
312
  * @public
444
313
  * @category 광고
@@ -559,28 +428,7 @@ declare function loadAppsInTossAdMob(params: LoadAdMobParams): () => void;
559
428
  declare namespace loadAppsInTossAdMob {
560
429
  var isSupported: () => boolean;
561
430
  }
562
- interface ShowAdMobOptions {
563
- /**
564
- * 광고 그룹 단위 ID
565
- */
566
- adGroupId: string;
567
- }
568
- /**
569
- * @public
570
- * @category 광고
571
- * @name ShowAdMobEvent
572
- * @description 광고를 보여주는 함수에서 발생하는 이벤트 타입이에요. `requested` 이벤트가 발생하면 광고 노출 요청이 Google AdMob에 성공적으로 전달된 거예요.
573
- */
574
- type ShowAdMobEvent = AdMobFullScreenEvent | AdUserEarnedReward | {
575
- type: 'requested';
576
- };
577
- /**
578
- * @public
579
- * @category 광고
580
- * @name ShowAdMobParams
581
- * @description 불러온 광고를 보여주는 함수에 필요한 옵션 객체예요.
582
- */
583
- type ShowAdMobParams = AdMobHandlerParams<ShowAdMobOptions, ShowAdMobEvent>;
431
+
584
432
  /**
585
433
  * @public
586
434
  * @category 광고
@@ -701,12 +549,7 @@ declare function showAppsInTossAdMob(params: ShowAdMobParams): () => void;
701
549
  declare namespace showAppsInTossAdMob {
702
550
  var isSupported: () => boolean;
703
551
  }
704
- interface IsAdMobLoadedOptions {
705
- /**
706
- * 광고 그룹 단위 ID
707
- */
708
- adGroupId: string;
709
- }
552
+
710
553
  /**
711
554
  * @public
712
555
  * @category 광고
@@ -3161,4 +3004,4 @@ declare const INTERNAL__module: {
3161
3004
  tossCoreEventLog: typeof tossCoreEventLog;
3162
3005
  };
3163
3006
 
3164
- export { AppsInTossModule, type AppsInTossSignTossCertParams, BedrockCoreModule, BedrockModule, type CheckoutPaymentOptions, type CheckoutPaymentResult, type CompletedOrRefundedOrdersResult, type ContactsViralParams, type EventLogParams, type GameCenterGameProfileResponse, type GetUserKeyForGameErrorResponse, type GetUserKeyForGameResponse, type GetUserKeyForGameSuccessResponse, GoogleAdMob, type GrantPromotionRewardForGameErrorResponse, type GrantPromotionRewardForGameErrorResult, type GrantPromotionRewardForGameResponse, type GrantPromotionRewardForGameSuccessResponse, type HapticFeedbackType, IAP, AppsInTossModuleInstance as INTERNAL__AppsInTossModule, INTERNAL__appBridgeHandler, INTERNAL__module, type IapCreateOneTimePurchaseOrderOptions, type IapCreateOneTimePurchaseOrderResult, type IapProductListItem, type IsAdMobLoadedOptions, type LoadAdMobEvent, type LoadAdMobOptions, type LoadAdMobParams, type NetworkStatus, type Primitive, type SaveBase64DataParams, type ShowAdMobEvent, type ShowAdMobOptions, type ShowAdMobParams, Storage, type SubmitGameCenterLeaderBoardScoreResponse, TossPay, type UpdateLocationEventEmitter, appLogin, appsInTossEvent, appsInTossSignTossCert, closeView, contactsViral, eventLog, fetchAlbumPhotos, fetchContacts, generateHapticFeedback, getClipboardText, getCurrentLocation, getDeviceId, getGameCenterGameProfile, getIsTossLoginIntegratedService, getLocale, getNetworkStatus, getOperationalEnvironment, getPlatformOS, getSchemeUri, getServerTime, getTossAppVersion, getTossShareLink, getUserKeyForGame, grantPromotionRewardForGame, iapCreateOneTimePurchaseOrder, isMinVersionSupported, onVisibilityChangedByTransparentServiceWeb, openCamera, openGameCenterLeaderboard, openURL, processProductGrant, requestOneTimePurchase, saveBase64Data, setClipboardText, setDeviceOrientation, setIosSwipeGestureEnabled, setScreenAwakeMode, setSecureScreen, share, startUpdateLocation, submitGameCenterLeaderBoardScore };
3007
+ export { AppsInTossModule, type AppsInTossSignTossCertParams, BedrockCoreModule, BedrockModule, type CheckoutPaymentOptions, type CheckoutPaymentResult, type CompletedOrRefundedOrdersResult, type ContactsViralParams, type EventLogParams, type GameCenterGameProfileResponse, type GetUserKeyForGameErrorResponse, type GetUserKeyForGameResponse, type GetUserKeyForGameSuccessResponse, GoogleAdMob, type GrantPromotionRewardForGameErrorResponse, type GrantPromotionRewardForGameErrorResult, type GrantPromotionRewardForGameResponse, type GrantPromotionRewardForGameSuccessResponse, type HapticFeedbackType, IAP, AppsInTossModuleInstance as INTERNAL__AppsInTossModule, INTERNAL__appBridgeHandler, INTERNAL__module, type IapCreateOneTimePurchaseOrderOptions, type IapCreateOneTimePurchaseOrderResult, type IapProductListItem, type NetworkStatus, type Primitive, type SaveBase64DataParams, Storage, type SubmitGameCenterLeaderBoardScoreResponse, TossPay, type UpdateLocationEventEmitter, appLogin, appsInTossEvent, appsInTossSignTossCert, closeView, contactsViral, eventLog, fetchAlbumPhotos, fetchContacts, generateHapticFeedback, getClipboardText, getCurrentLocation, getDeviceId, getGameCenterGameProfile, getIsTossLoginIntegratedService, getLocale, getNetworkStatus, getOperationalEnvironment, getPlatformOS, getSchemeUri, getServerTime, getTossAppVersion, getTossShareLink, getUserKeyForGame, grantPromotionRewardForGame, iapCreateOneTimePurchaseOrder, isMinVersionSupported, onVisibilityChangedByTransparentServiceWeb, openCamera, openGameCenterLeaderboard, openURL, processProductGrant, requestOneTimePurchase, saveBase64Data, setClipboardText, setDeviceOrientation, setIosSwipeGestureEnabled, setScreenAwakeMode, setSecureScreen, share, startUpdateLocation, submitGameCenterLeaderBoardScore };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as _apps_in_toss_types from '@apps-in-toss/types';
2
- import { Location, StartUpdateLocationEventParams, Accuracy, CompatiblePlaceholderArgument, SetClipboardTextOptions, FetchContactsOptions, ContactResult, FetchAlbumPhotosOptions, ImageResponse, GetCurrentLocationOptions, OpenCameraOptions, PermissionName, PermissionAccess, PermissionStatus, FetchAlbumPhotos, FetchContacts, GetClipboardText, GetCurrentLocation, SetClipboardText, OpenCamera } from '@apps-in-toss/types';
3
- export { StartUpdateLocationPermissionError } from '@apps-in-toss/types';
2
+ import { Location, StartUpdateLocationEventParams, Accuracy, LoadAdMobParams, ShowAdMobParams, IsAdMobLoadedOptions, CompatiblePlaceholderArgument, SetClipboardTextOptions, FetchContactsOptions, ContactResult, FetchAlbumPhotosOptions, ImageResponse, GetCurrentLocationOptions, OpenCameraOptions, PermissionName, PermissionAccess, PermissionStatus, FetchAlbumPhotos, FetchContacts, GetClipboardText, GetCurrentLocation, SetClipboardText, OpenCamera } from '@apps-in-toss/types';
3
+ export { IsAdMobLoadedOptions, LoadAdMobEvent, LoadAdMobOptions, LoadAdMobParams, ShowAdMobEvent, ShowAdMobOptions, ShowAdMobParams, StartUpdateLocationPermissionError } from '@apps-in-toss/types';
4
4
  import { GraniteEventDefinition, GraniteEvent } from '@granite-js/react-native';
5
5
  import { EmitterSubscription, TurboModule } from 'react-native';
6
6
 
@@ -308,137 +308,6 @@ declare const INTERNAL__appBridgeHandler: {
308
308
  getCallbackIds: typeof getCallbackIds;
309
309
  };
310
310
 
311
- /**
312
- * @public
313
- * @category 광고
314
- * @name AdMobFullScreenEvent
315
- * @description 앱 화면을 덮는 광고(예: 전면 광고, 보상형 광고)를 사용하는 경우에 발생하는 이벤트 타입이에요.
316
- * @example
317
- * ### 광고 이벤트 처리하기
318
- * ```ts
319
- * function handleEvent(event: AdMobFullScreenEvent) {
320
- * switch (event.type) {
321
- * case 'clicked':
322
- * console.log('광고가 클릭됐어요.');
323
- * break;
324
- *
325
- * case 'dismissed':
326
- * console.log('광고가 닫혔어요.');
327
- * break;
328
- *
329
- * case 'failedToShow':
330
- * console.log('광고가 보여지지 않았어요.');
331
- * break;
332
- *
333
- * case 'impression':
334
- * console.log('광고가 노출됐어요.');
335
- * break;
336
- *
337
- * case 'show':
338
- * console.log('광고가 보여졌어요.');
339
- * break;
340
- * }
341
- * }
342
- * ```
343
- */
344
- type AdMobFullScreenEvent = AdClicked | AdDismissed | AdFailedToShow | AdImpression | AdShow;
345
- type AdClicked = {
346
- type: 'clicked';
347
- };
348
- type AdDismissed = {
349
- type: 'dismissed';
350
- };
351
- type AdFailedToShow = {
352
- type: 'failedToShow';
353
- };
354
- type AdImpression = {
355
- type: 'impression';
356
- };
357
- type AdShow = {
358
- type: 'show';
359
- };
360
- type AdUserEarnedReward = {
361
- type: 'userEarnedReward';
362
- data: {
363
- unitType: string;
364
- unitAmount: number;
365
- };
366
- };
367
- interface AdMobHandlerParams<Options = void, Event = AdMobFullScreenEvent> {
368
- options: Options;
369
- onEvent: (event: Event) => void;
370
- onError: (error: unknown) => void;
371
- }
372
- /**
373
- * @public
374
- * @category 광고
375
- * @name ResponseInfo
376
- * @description 광고 로드 응답 정보를 담고 있는 객체예요.
377
- * @property {Array<AdNetworkResponseInfo>} adNetworkInfoArray 광고 네트워크 응답 정보 배열예요.
378
- * @property {AdNetworkResponseInfo | null} loadedAdNetworkInfo 로드된 광고 네트워크 응답 정보예요.
379
- * @property {string | null} responseId 광고 응답 ID예요.
380
- */
381
- interface ResponseInfo {
382
- adNetworkInfoArray: Array<AdNetworkResponseInfo>;
383
- loadedAdNetworkInfo: AdNetworkResponseInfo | null;
384
- responseId: string | null;
385
- }
386
- /**
387
- * @public
388
- * @category 광고
389
- * @name AdNetworkResponseInfo
390
- * @description 광고 네트워크 응답 정보를 담고 있는 객체예요.
391
- * @property {string} adSourceId 광고 소스 ID예요.
392
- * @property {string} adSourceName 광고 소스 이름이예요.
393
- * @property {string} adSourceInstanceId 광고 소스 인스턴스 ID예요.
394
- * @property {string} adSourceInstanceName 광고 소스 인스턴스 이름이예요.
395
- * @property {string | null} adNetworkClassName 광고 네트워크 클래스 이름이예요.
396
- */
397
- interface AdNetworkResponseInfo {
398
- adSourceId: string;
399
- adSourceName: string;
400
- adSourceInstanceId: string;
401
- adSourceInstanceName: string;
402
- adNetworkClassName: string | null;
403
- }
404
- /**
405
- * @public
406
- * @category 광고
407
- * @name AdMobLoadResult
408
- * @description 광고의 ID와 응답 정보를 담고 있는 객체예요. 광고를 로드한 뒤, 관련 정보를 확인할 때 유용해요.
409
- * @property {string} adGroupId 광고 그룹 ID예요.
410
- * @property {string} adUnitId 광고 ID예요.
411
- * @property {ResponseInfo} responseInfo 광고 로드 응답 정보예요. 자세한 내용은 [ResponseInfo](/react-native/reference/native-modules/광고/ResponseInfo.html)를 참고하세요.
412
- */
413
- interface AdMobLoadResult {
414
- adGroupId: string;
415
- adUnitId: string;
416
- responseInfo: ResponseInfo;
417
- }
418
-
419
- interface LoadAdMobOptions {
420
- /**
421
- * 광고 그룹 단위 ID
422
- */
423
- adGroupId: string;
424
- }
425
- /**
426
- * @public
427
- * @category 광고
428
- * @name LoadAdMobEvent
429
- * @description 광고를 불러오는 함수에서 발생하는 이벤트 타입이에요. `loaded` 이벤트가 발생하면 광고를 성공적으로 불러온 거예요. 이때 [AdMobLoadResult](/react-native/reference/native-modules/광고/AdMobLoadResult.html) 객체가 함께 반환돼요.
430
- */
431
- type LoadAdMobEvent = {
432
- type: 'loaded';
433
- data: AdMobLoadResult;
434
- };
435
- /**
436
- * @public
437
- * @category 광고
438
- * @name LoadAdMobParams
439
- * @description 광고를 불러오는 함수에 필요한 옵션 객체예요.
440
- */
441
- type LoadAdMobParams = AdMobHandlerParams<LoadAdMobOptions, LoadAdMobEvent>;
442
311
  /**
443
312
  * @public
444
313
  * @category 광고
@@ -559,28 +428,7 @@ declare function loadAppsInTossAdMob(params: LoadAdMobParams): () => void;
559
428
  declare namespace loadAppsInTossAdMob {
560
429
  var isSupported: () => boolean;
561
430
  }
562
- interface ShowAdMobOptions {
563
- /**
564
- * 광고 그룹 단위 ID
565
- */
566
- adGroupId: string;
567
- }
568
- /**
569
- * @public
570
- * @category 광고
571
- * @name ShowAdMobEvent
572
- * @description 광고를 보여주는 함수에서 발생하는 이벤트 타입이에요. `requested` 이벤트가 발생하면 광고 노출 요청이 Google AdMob에 성공적으로 전달된 거예요.
573
- */
574
- type ShowAdMobEvent = AdMobFullScreenEvent | AdUserEarnedReward | {
575
- type: 'requested';
576
- };
577
- /**
578
- * @public
579
- * @category 광고
580
- * @name ShowAdMobParams
581
- * @description 불러온 광고를 보여주는 함수에 필요한 옵션 객체예요.
582
- */
583
- type ShowAdMobParams = AdMobHandlerParams<ShowAdMobOptions, ShowAdMobEvent>;
431
+
584
432
  /**
585
433
  * @public
586
434
  * @category 광고
@@ -701,12 +549,7 @@ declare function showAppsInTossAdMob(params: ShowAdMobParams): () => void;
701
549
  declare namespace showAppsInTossAdMob {
702
550
  var isSupported: () => boolean;
703
551
  }
704
- interface IsAdMobLoadedOptions {
705
- /**
706
- * 광고 그룹 단위 ID
707
- */
708
- adGroupId: string;
709
- }
552
+
710
553
  /**
711
554
  * @public
712
555
  * @category 광고
@@ -3161,4 +3004,4 @@ declare const INTERNAL__module: {
3161
3004
  tossCoreEventLog: typeof tossCoreEventLog;
3162
3005
  };
3163
3006
 
3164
- export { AppsInTossModule, type AppsInTossSignTossCertParams, BedrockCoreModule, BedrockModule, type CheckoutPaymentOptions, type CheckoutPaymentResult, type CompletedOrRefundedOrdersResult, type ContactsViralParams, type EventLogParams, type GameCenterGameProfileResponse, type GetUserKeyForGameErrorResponse, type GetUserKeyForGameResponse, type GetUserKeyForGameSuccessResponse, GoogleAdMob, type GrantPromotionRewardForGameErrorResponse, type GrantPromotionRewardForGameErrorResult, type GrantPromotionRewardForGameResponse, type GrantPromotionRewardForGameSuccessResponse, type HapticFeedbackType, IAP, AppsInTossModuleInstance as INTERNAL__AppsInTossModule, INTERNAL__appBridgeHandler, INTERNAL__module, type IapCreateOneTimePurchaseOrderOptions, type IapCreateOneTimePurchaseOrderResult, type IapProductListItem, type IsAdMobLoadedOptions, type LoadAdMobEvent, type LoadAdMobOptions, type LoadAdMobParams, type NetworkStatus, type Primitive, type SaveBase64DataParams, type ShowAdMobEvent, type ShowAdMobOptions, type ShowAdMobParams, Storage, type SubmitGameCenterLeaderBoardScoreResponse, TossPay, type UpdateLocationEventEmitter, appLogin, appsInTossEvent, appsInTossSignTossCert, closeView, contactsViral, eventLog, fetchAlbumPhotos, fetchContacts, generateHapticFeedback, getClipboardText, getCurrentLocation, getDeviceId, getGameCenterGameProfile, getIsTossLoginIntegratedService, getLocale, getNetworkStatus, getOperationalEnvironment, getPlatformOS, getSchemeUri, getServerTime, getTossAppVersion, getTossShareLink, getUserKeyForGame, grantPromotionRewardForGame, iapCreateOneTimePurchaseOrder, isMinVersionSupported, onVisibilityChangedByTransparentServiceWeb, openCamera, openGameCenterLeaderboard, openURL, processProductGrant, requestOneTimePurchase, saveBase64Data, setClipboardText, setDeviceOrientation, setIosSwipeGestureEnabled, setScreenAwakeMode, setSecureScreen, share, startUpdateLocation, submitGameCenterLeaderBoardScore };
3007
+ export { AppsInTossModule, type AppsInTossSignTossCertParams, BedrockCoreModule, BedrockModule, type CheckoutPaymentOptions, type CheckoutPaymentResult, type CompletedOrRefundedOrdersResult, type ContactsViralParams, type EventLogParams, type GameCenterGameProfileResponse, type GetUserKeyForGameErrorResponse, type GetUserKeyForGameResponse, type GetUserKeyForGameSuccessResponse, GoogleAdMob, type GrantPromotionRewardForGameErrorResponse, type GrantPromotionRewardForGameErrorResult, type GrantPromotionRewardForGameResponse, type GrantPromotionRewardForGameSuccessResponse, type HapticFeedbackType, IAP, AppsInTossModuleInstance as INTERNAL__AppsInTossModule, INTERNAL__appBridgeHandler, INTERNAL__module, type IapCreateOneTimePurchaseOrderOptions, type IapCreateOneTimePurchaseOrderResult, type IapProductListItem, type NetworkStatus, type Primitive, type SaveBase64DataParams, Storage, type SubmitGameCenterLeaderBoardScoreResponse, TossPay, type UpdateLocationEventEmitter, appLogin, appsInTossEvent, appsInTossSignTossCert, closeView, contactsViral, eventLog, fetchAlbumPhotos, fetchContacts, generateHapticFeedback, getClipboardText, getCurrentLocation, getDeviceId, getGameCenterGameProfile, getIsTossLoginIntegratedService, getLocale, getNetworkStatus, getOperationalEnvironment, getPlatformOS, getSchemeUri, getServerTime, getTossAppVersion, getTossShareLink, getUserKeyForGame, grantPromotionRewardForGame, iapCreateOneTimePurchaseOrder, isMinVersionSupported, onVisibilityChangedByTransparentServiceWeb, openCamera, openGameCenterLeaderboard, openURL, processProductGrant, requestOneTimePurchase, saveBase64Data, setClipboardText, setDeviceOrientation, setIosSwipeGestureEnabled, setScreenAwakeMode, setSecureScreen, share, startUpdateLocation, submitGameCenterLeaderBoardScore };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@apps-in-toss/native-modules",
3
3
  "type": "module",
4
- "version": "1.9.3",
4
+ "version": "1.10.0",
5
5
  "description": "Native Modules for Apps In Toss",
6
6
  "scripts": {
7
7
  "typecheck": "tsc --noEmit",
@@ -42,7 +42,7 @@
42
42
  "vitest": "^3.2.4"
43
43
  },
44
44
  "dependencies": {
45
- "@apps-in-toss/types": "^1.9.3",
45
+ "@apps-in-toss/types": "^1.10.0",
46
46
  "es-toolkit": "^1.39.3"
47
47
  },
48
48
  "peerDependencies": {
@@ -1,5 +1,13 @@
1
+ import type {
2
+ LoadAdMobOptions,
3
+ LoadAdMobEvent,
4
+ LoadAdMobParams,
5
+ ShowAdMobOptions,
6
+ ShowAdMobEvent,
7
+ ShowAdMobParams,
8
+ IsAdMobLoadedOptions,
9
+ } from '@apps-in-toss/types';
1
10
  import { noop } from 'es-toolkit';
2
- import type { AdMobFullScreenEvent, AdMobHandlerParams, AdMobLoadResult, AdUserEarnedReward } from './types';
3
11
  import { getReferrer } from '../../../utils/getReferrer';
4
12
  import { INTERNAL__appBridgeHandler } from '../../native-event-emitter/internal/appBridge';
5
13
  import { getOperationalEnvironment } from '../getOperationalEnvironment';
@@ -7,31 +15,7 @@ import { isMinVersionSupported } from '../isMinVersionSupported';
7
15
 
8
16
  // MARK: AdMob Load
9
17
 
10
- export interface LoadAdMobOptions {
11
- /**
12
- * 광고 그룹 단위 ID
13
- */
14
- adGroupId: string;
15
- }
16
-
17
- /**
18
- * @public
19
- * @category 광고
20
- * @name LoadAdMobEvent
21
- * @description 광고를 불러오는 함수에서 발생하는 이벤트 타입이에요. `loaded` 이벤트가 발생하면 광고를 성공적으로 불러온 거예요. 이때 [AdMobLoadResult](/react-native/reference/native-modules/광고/AdMobLoadResult.html) 객체가 함께 반환돼요.
22
- */
23
- export type LoadAdMobEvent = {
24
- type: 'loaded';
25
- data: AdMobLoadResult;
26
- };
27
-
28
- /**
29
- * @public
30
- * @category 광고
31
- * @name LoadAdMobParams
32
- * @description 광고를 불러오는 함수에 필요한 옵션 객체예요.
33
- */
34
- export type LoadAdMobParams = AdMobHandlerParams<LoadAdMobOptions, LoadAdMobEvent>;
18
+ export type { LoadAdMobOptions, LoadAdMobEvent, LoadAdMobParams };
35
19
 
36
20
  /**
37
21
  * @public
@@ -172,28 +156,7 @@ export function loadAppsInTossAdMob(params: LoadAdMobParams) {
172
156
 
173
157
  // MARK: AdMob Show
174
158
 
175
- export interface ShowAdMobOptions {
176
- /**
177
- * 광고 그룹 단위 ID
178
- */
179
- adGroupId: string;
180
- }
181
-
182
- /**
183
- * @public
184
- * @category 광고
185
- * @name ShowAdMobEvent
186
- * @description 광고를 보여주는 함수에서 발생하는 이벤트 타입이에요. `requested` 이벤트가 발생하면 광고 노출 요청이 Google AdMob에 성공적으로 전달된 거예요.
187
- */
188
- export type ShowAdMobEvent = AdMobFullScreenEvent | AdUserEarnedReward | { type: 'requested' };
189
-
190
- /**
191
- * @public
192
- * @category 광고
193
- * @name ShowAdMobParams
194
- * @description 불러온 광고를 보여주는 함수에 필요한 옵션 객체예요.
195
- */
196
- export type ShowAdMobParams = AdMobHandlerParams<ShowAdMobOptions, ShowAdMobEvent>;
159
+ export type { ShowAdMobOptions, ShowAdMobEvent, ShowAdMobParams };
197
160
 
198
161
  /**
199
162
  * @public
@@ -375,12 +338,7 @@ showAppsInTossAdMob.isSupported = createIsSupported();
375
338
 
376
339
  // MARK: - isAppsInTossAdMobLoaded
377
340
 
378
- export interface IsAdMobLoadedOptions {
379
- /**
380
- * 광고 그룹 단위 ID
381
- */
382
- adGroupId: string;
383
- }
341
+ export type { IsAdMobLoadedOptions };
384
342
 
385
343
  /**
386
344
  * @public
@@ -1,97 +0,0 @@
1
- /**
2
- * @public
3
- * @category 광고
4
- * @name AdMobFullScreenEvent
5
- * @description 앱 화면을 덮는 광고(예: 전면 광고, 보상형 광고)를 사용하는 경우에 발생하는 이벤트 타입이에요.
6
- * @example
7
- * ### 광고 이벤트 처리하기
8
- * ```ts
9
- * function handleEvent(event: AdMobFullScreenEvent) {
10
- * switch (event.type) {
11
- * case 'clicked':
12
- * console.log('광고가 클릭됐어요.');
13
- * break;
14
- *
15
- * case 'dismissed':
16
- * console.log('광고가 닫혔어요.');
17
- * break;
18
- *
19
- * case 'failedToShow':
20
- * console.log('광고가 보여지지 않았어요.');
21
- * break;
22
- *
23
- * case 'impression':
24
- * console.log('광고가 노출됐어요.');
25
- * break;
26
- *
27
- * case 'show':
28
- * console.log('광고가 보여졌어요.');
29
- * break;
30
- * }
31
- * }
32
- * ```
33
- */
34
- export type AdMobFullScreenEvent = AdClicked | AdDismissed | AdFailedToShow | AdImpression | AdShow;
35
-
36
- type AdClicked = { type: 'clicked' };
37
- type AdDismissed = { type: 'dismissed' };
38
- type AdFailedToShow = { type: 'failedToShow' };
39
- type AdImpression = { type: 'impression' };
40
- type AdShow = { type: 'show' };
41
-
42
- export type AdUserEarnedReward = { type: 'userEarnedReward'; data: { unitType: string; unitAmount: number } };
43
-
44
- export interface AdMobHandlerParams<Options = void, Event = AdMobFullScreenEvent> {
45
- options: Options;
46
- onEvent: (event: Event) => void;
47
- onError: (error: unknown) => void;
48
- }
49
-
50
- /**
51
- * @public
52
- * @category 광고
53
- * @name ResponseInfo
54
- * @description 광고 로드 응답 정보를 담고 있는 객체예요.
55
- * @property {Array<AdNetworkResponseInfo>} adNetworkInfoArray 광고 네트워크 응답 정보 배열예요.
56
- * @property {AdNetworkResponseInfo | null} loadedAdNetworkInfo 로드된 광고 네트워크 응답 정보예요.
57
- * @property {string | null} responseId 광고 응답 ID예요.
58
- */
59
- export interface ResponseInfo {
60
- adNetworkInfoArray: Array<AdNetworkResponseInfo>;
61
- loadedAdNetworkInfo: AdNetworkResponseInfo | null;
62
- responseId: string | null;
63
- }
64
-
65
- /**
66
- * @public
67
- * @category 광고
68
- * @name AdNetworkResponseInfo
69
- * @description 광고 네트워크 응답 정보를 담고 있는 객체예요.
70
- * @property {string} adSourceId 광고 소스 ID예요.
71
- * @property {string} adSourceName 광고 소스 이름이예요.
72
- * @property {string} adSourceInstanceId 광고 소스 인스턴스 ID예요.
73
- * @property {string} adSourceInstanceName 광고 소스 인스턴스 이름이예요.
74
- * @property {string | null} adNetworkClassName 광고 네트워크 클래스 이름이예요.
75
- */
76
- export interface AdNetworkResponseInfo {
77
- adSourceId: string;
78
- adSourceName: string;
79
- adSourceInstanceId: string;
80
- adSourceInstanceName: string;
81
- adNetworkClassName: string | null;
82
- }
83
-
84
- /**
85
- * @public
86
- * @category 광고
87
- * @name AdMobLoadResult
88
- * @description 광고의 ID와 응답 정보를 담고 있는 객체예요. 광고를 로드한 뒤, 관련 정보를 확인할 때 유용해요.
89
- * @property {string} adGroupId 광고 그룹 ID예요.
90
- * @property {string} adUnitId 광고 ID예요.
91
- * @property {ResponseInfo} responseInfo 광고 로드 응답 정보예요. 자세한 내용은 [ResponseInfo](/react-native/reference/native-modules/광고/ResponseInfo.html)를 참고하세요.
92
- */
93
- export interface AdMobLoadResult {
94
- adGroupId: string;
95
- adUnitId: string;
96
- responseInfo: ResponseInfo;
97
- }