forked from NativeScript/firebase
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcommon.ts
104 lines (83 loc) · 2.38 KB
/
common.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
import { CSSType, Property, View } from '@nativescript/core';
import { IRewardedItem, RequestOptions } from '.';
export abstract class BannerAdSizeBase {
static get BANNER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get FULL_BANNER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get LARGE_BANNER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get LEADERBOARD(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get MEDIUM_RECTANGLE(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get SMART_BANNER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get ADAPTIVE_BANNER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get FLUID(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get WIDE_SKYSCRAPER(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get INVALID(): BannerAdSizeBase {
throw new Error('unimplemented');
}
static get SEARCH(): BannerAdSizeBase {
throw new Error('unimplemented');
}
}
export const sizeProperty = new Property<BannerAdBase, BannerAdSizeBase>({
name: 'size',
});
export const unitIdProperty = new Property<BannerAdBase, BannerAdSizeBase>({
name: 'unitId',
});
@CSSType('BannerAd')
export abstract class BannerAdBase extends View {
static onAdClickedEvent = 'adClicked';
static onAdClosedEvent = 'adClosed';
static onAdFailedToLoadEvent = 'adFailedToLoad';
static onAdLoadedEvent = 'adLoaded';
static onAdOpenedEvent = 'adOpened';
static onAdImpression = 'adImpression';
static onAdFailedToShowFullScreenContent = 'adFailedToShowFullScreenContent';
size: BannerAdSizeBase;
unitId: BannerAdSizeBase;
abstract load(options?: RequestOptions);
abstract isLoading(): boolean;
}
sizeProperty.register(BannerAdBase);
unitIdProperty.register(BannerAdBase);
export enum MaxAdContentRating {
G = 'G',
MA = 'MA',
PG = 'PG',
T = 'T',
UNSPECIFIED = 'UNSPECIFIED',
}
export enum AdEventType {
CLICKED = 'adClicked',
CLOSED = 'adClosed',
LOADED = 'adLoaded',
OPENED = 'adOpened',
IMPRESSION = 'adImpression',
FAILED_TO_SHOW_FULL_SCREEN_CONTENT = 'adFailedToShowFullScreenContent',
FAILED_TO_LOAD_EVENT = 'adFailedToLoad',
}
export enum RewardedAdEventType {
EARNED_REWARD = 'rewarded_earned_reward',
LOADED = 'rewarded_loaded',
}
export enum AdapterStatusState {
NOT_READY,
READY,
}