native-fn 1.0.33 → 1.0.35
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.ts +13 -5
- package/dist/native.cjs +89 -3
- package/dist/native.min.cjs +1 -1
- package/dist/native.min.mjs +1 -1
- package/dist/native.mjs +89 -3
- package/dist/native.umd.js +89 -3
- package/dist/native.umd.min.js +1 -1
- package/dist/plugin/app/index.d.ts +14 -5
- package/dist/plugin/app/src/errors/url-open-error.d.ts +2 -0
- package/dist/plugin/app/src/plugin/app/types/app.d.ts +2 -2
- package/dist/plugin/app/src/plugin/app/types/index.d.ts +10 -1
- package/dist/plugin/app/src/plugin/platform/types/index.d.ts +1 -1
- package/dist/plugin/app/src/plugin/theme/types/index.d.ts +15 -1
- package/dist/plugin/app/src/types/native.d.ts +12 -4
- package/dist/plugin/platform/index.d.ts +3 -3
- package/dist/plugin/platform/src/errors/url-open-error.d.ts +2 -0
- package/dist/plugin/platform/src/plugin/app/types/app.d.ts +2 -2
- package/dist/plugin/platform/src/plugin/app/types/index.d.ts +10 -1
- package/dist/plugin/platform/src/plugin/platform/types/index.d.ts +1 -1
- package/dist/plugin/platform/src/plugin/theme/types/index.d.ts +15 -1
- package/dist/plugin/platform/src/types/native.d.ts +12 -4
- package/dist/plugin/theme/index.d.ts +22 -3
- package/dist/plugin/theme/src/errors/url-open-error.d.ts +2 -0
- package/dist/plugin/theme/src/plugin/app/types/app.d.ts +2 -2
- package/dist/plugin/theme/src/plugin/app/types/index.d.ts +10 -1
- package/dist/plugin/theme/src/plugin/platform/types/index.d.ts +1 -1
- package/dist/plugin/theme/src/plugin/theme/types/index.d.ts +15 -1
- package/dist/plugin/theme/src/types/native.d.ts +12 -4
- package/dist/src/errors/url-open-error.d.ts +2 -0
- package/dist/src/plugin/app/types/app.d.ts +2 -2
- package/dist/src/plugin/app/types/index.d.ts +10 -1
- package/dist/src/plugin/platform/types/index.d.ts +1 -1
- package/dist/src/plugin/theme/types/index.d.ts +15 -1
- package/dist/src/types/native.d.ts +12 -4
- package/package.json +1 -1
- package/dist/plugin/app/src/plugin/app/types/appModule.d.ts +0 -54
- package/dist/plugin/app/src/plugin/platform/types/platformModule.d.ts +0 -13
- package/dist/plugin/app/src/plugin/theme/types/themeModule.d.ts +0 -24
- package/dist/plugin/platform/src/plugin/app/types/appModule.d.ts +0 -54
- package/dist/plugin/platform/src/plugin/platform/types/platformModule.d.ts +0 -13
- package/dist/plugin/platform/src/plugin/theme/types/themeModule.d.ts +0 -24
- package/dist/plugin/theme/src/plugin/app/types/appModule.d.ts +0 -54
- package/dist/plugin/theme/src/plugin/platform/types/platformModule.d.ts +0 -13
- package/dist/plugin/theme/src/plugin/theme/types/themeModule.d.ts +0 -24
- package/dist/src/plugin/app/types/appModule.d.ts +0 -54
- package/dist/src/plugin/platform/types/platformModule.d.ts +0 -13
- package/dist/src/plugin/theme/types/themeModule.d.ts +0 -24
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
declare interface ModuleBase {
|
|
2
|
-
Constants: Record<string, any>;
|
|
3
|
-
Errors: Record<string, ErrorConstructor>;
|
|
4
2
|
}
|
|
5
3
|
declare interface NativePlugin<T> extends ModuleBase {
|
|
6
4
|
installed: boolean;
|
|
7
5
|
name: string;
|
|
8
6
|
module: T;
|
|
7
|
+
Constants: Record<string, any>;
|
|
8
|
+
Errors: Record<string, ErrorConstructor>;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
type SystemColor = 'ActiveBorder' | 'ActiveCaption' | 'AppWorkspace' | 'Background' | 'ButtonHighlight' | 'ButtonShadow' | 'CaptionText' | 'InactiveBorder' | 'InactiveCaption' | 'InactiveCaptionText' | 'InfoBackground' | 'InfoText' | 'Menu' | 'MenuText' | 'Scrollbar' | 'ThreeDDarkShadow' | 'ThreeDFace' | 'ThreeDHighlight' | 'ThreeDLightShadow' | 'ThreeDShadow' | 'Window' | 'WindowFrame' | 'WindowText';
|
|
@@ -71,10 +71,29 @@ declare interface ThemeInstance {
|
|
|
71
71
|
onAppearanceChange: (listener: (appearance?: Appearances) => any, options?: boolean | AddEventListenerOptions) => () => void;
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
-
declare
|
|
74
|
+
declare const UnsupportedColorError: ErrorConstructor;
|
|
75
|
+
|
|
76
|
+
declare const EasingError: ErrorConstructor;
|
|
77
|
+
declare const CubicBezierSyntaxError: ErrorConstructor;
|
|
78
|
+
declare const LinearSyntaxError: ErrorConstructor;
|
|
79
|
+
declare const StepSyntaxError: ErrorConstructor;
|
|
80
|
+
declare const UnsupportedEasingFunctionError: ErrorConstructor;
|
|
81
|
+
|
|
82
|
+
declare module 'native-fn' {
|
|
75
83
|
interface NativePlugins {
|
|
76
84
|
Theme: ThemeInstance;
|
|
77
85
|
}
|
|
86
|
+
interface NativeConstants {
|
|
87
|
+
Appearances: Appearances;
|
|
88
|
+
}
|
|
89
|
+
interface NativeErrors {
|
|
90
|
+
EasingError: typeof EasingError;
|
|
91
|
+
UnsupportedEasingFunctionError: typeof UnsupportedEasingFunctionError;
|
|
92
|
+
StepSyntaxError: typeof StepSyntaxError;
|
|
93
|
+
LinearSyntaxError: typeof LinearSyntaxError;
|
|
94
|
+
CubicBezierSyntaxError: typeof CubicBezierSyntaxError;
|
|
95
|
+
UnsupportedColorError: typeof UnsupportedColorError;
|
|
96
|
+
}
|
|
78
97
|
}
|
|
79
98
|
|
|
80
99
|
declare const NativeThemePlugin: NativePlugin<ThemeInstance>;
|
|
@@ -47,8 +47,8 @@ export declare type MessengerOpenOptions = {
|
|
|
47
47
|
subject?: Stringifiable;
|
|
48
48
|
body?: Stringifiable;
|
|
49
49
|
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions
|
|
50
|
+
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions) => Promise<void>>;
|
|
51
51
|
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions
|
|
52
|
+
open: (options: AppOpenOptions) => Promise<AppOpenState>;
|
|
53
53
|
messenger: Messenger;
|
|
54
54
|
}
|
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
export * from './app';
|
|
2
2
|
import type { AppInstance } from './app';
|
|
3
|
-
|
|
3
|
+
import { AppOpenState, Messengers } from "../constants/app";
|
|
4
|
+
import { URLOpenError } from "../errors/url-open-error";
|
|
5
|
+
declare module 'native-fn' {
|
|
4
6
|
interface NativePlugins {
|
|
5
7
|
App: AppInstance;
|
|
6
8
|
}
|
|
9
|
+
interface NativeConstants {
|
|
10
|
+
AppOpenState: AppOpenState;
|
|
11
|
+
Messengers: Messengers;
|
|
12
|
+
}
|
|
13
|
+
interface NativeErrors {
|
|
14
|
+
URLOpenError: typeof URLOpenError;
|
|
15
|
+
}
|
|
7
16
|
}
|
|
@@ -2,8 +2,22 @@ export * from './color';
|
|
|
2
2
|
export * from './easing-syntax';
|
|
3
3
|
export * from './theme';
|
|
4
4
|
import type { ThemeInstance } from './theme';
|
|
5
|
-
|
|
5
|
+
import { Appearances } from "../constants/theme";
|
|
6
|
+
import { UnsupportedColorError } from "../errors/unsupported-color-error";
|
|
7
|
+
import { CubicBezierSyntaxError, EasingError, LinearSyntaxError, StepSyntaxError, UnsupportedEasingFunctionError } from "../errors/easing-error";
|
|
8
|
+
declare module 'native-fn' {
|
|
6
9
|
interface NativePlugins {
|
|
7
10
|
Theme: ThemeInstance;
|
|
8
11
|
}
|
|
12
|
+
interface NativeConstants {
|
|
13
|
+
Appearances: Appearances;
|
|
14
|
+
}
|
|
15
|
+
interface NativeErrors {
|
|
16
|
+
EasingError: typeof EasingError;
|
|
17
|
+
UnsupportedEasingFunctionError: typeof UnsupportedEasingFunctionError;
|
|
18
|
+
StepSyntaxError: typeof StepSyntaxError;
|
|
19
|
+
LinearSyntaxError: typeof LinearSyntaxError;
|
|
20
|
+
CubicBezierSyntaxError: typeof CubicBezierSyntaxError;
|
|
21
|
+
UnsupportedColorError: typeof UnsupportedColorError;
|
|
22
|
+
}
|
|
9
23
|
}
|
|
@@ -1,16 +1,24 @@
|
|
|
1
|
+
export interface NativePlugins {
|
|
2
|
+
}
|
|
3
|
+
export interface NativeConstants {
|
|
4
|
+
[key: string]: any;
|
|
5
|
+
}
|
|
6
|
+
export interface NativeErrors {
|
|
7
|
+
[key: string]: ErrorConstructor;
|
|
8
|
+
}
|
|
1
9
|
export declare interface ModuleBase {
|
|
2
|
-
Constants: Record<string, any>;
|
|
3
|
-
Errors: Record<string, ErrorConstructor>;
|
|
4
10
|
}
|
|
5
11
|
export declare interface NativePlugin<T> extends ModuleBase {
|
|
6
12
|
installed: boolean;
|
|
7
13
|
name: string;
|
|
8
14
|
module: T;
|
|
15
|
+
Constants: Record<string, any>;
|
|
16
|
+
Errors: Record<string, ErrorConstructor>;
|
|
9
17
|
}
|
|
10
18
|
export declare interface NativeBase extends ModuleBase {
|
|
11
19
|
Version: string;
|
|
20
|
+
Constants: NativeConstants;
|
|
21
|
+
Errors: NativeErrors;
|
|
12
22
|
extends: <T>(plugin: NativePlugin<T>) => NativeInstance;
|
|
13
23
|
}
|
|
14
|
-
export interface NativePlugins {
|
|
15
|
-
}
|
|
16
24
|
export type NativeInstance = NativeBase & NativePlugins;
|
|
@@ -47,8 +47,8 @@ export declare type MessengerOpenOptions = {
|
|
|
47
47
|
subject?: Stringifiable;
|
|
48
48
|
body?: Stringifiable;
|
|
49
49
|
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions
|
|
50
|
+
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions) => Promise<void>>;
|
|
51
51
|
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions
|
|
52
|
+
open: (options: AppOpenOptions) => Promise<AppOpenState>;
|
|
53
53
|
messenger: Messenger;
|
|
54
54
|
}
|
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
export * from './app';
|
|
2
2
|
import type { AppInstance } from './app';
|
|
3
|
-
|
|
3
|
+
import { AppOpenState, Messengers } from "../constants/app";
|
|
4
|
+
import { URLOpenError } from "../errors/url-open-error";
|
|
5
|
+
declare module 'native-fn' {
|
|
4
6
|
interface NativePlugins {
|
|
5
7
|
App: AppInstance;
|
|
6
8
|
}
|
|
9
|
+
interface NativeConstants {
|
|
10
|
+
AppOpenState: AppOpenState;
|
|
11
|
+
Messengers: Messengers;
|
|
12
|
+
}
|
|
13
|
+
interface NativeErrors {
|
|
14
|
+
URLOpenError: typeof URLOpenError;
|
|
15
|
+
}
|
|
7
16
|
}
|
|
@@ -2,8 +2,22 @@ export * from './color';
|
|
|
2
2
|
export * from './easing-syntax';
|
|
3
3
|
export * from './theme';
|
|
4
4
|
import type { ThemeInstance } from './theme';
|
|
5
|
-
|
|
5
|
+
import { Appearances } from "../constants/theme";
|
|
6
|
+
import { UnsupportedColorError } from "../errors/unsupported-color-error";
|
|
7
|
+
import { CubicBezierSyntaxError, EasingError, LinearSyntaxError, StepSyntaxError, UnsupportedEasingFunctionError } from "../errors/easing-error";
|
|
8
|
+
declare module 'native-fn' {
|
|
6
9
|
interface NativePlugins {
|
|
7
10
|
Theme: ThemeInstance;
|
|
8
11
|
}
|
|
12
|
+
interface NativeConstants {
|
|
13
|
+
Appearances: Appearances;
|
|
14
|
+
}
|
|
15
|
+
interface NativeErrors {
|
|
16
|
+
EasingError: typeof EasingError;
|
|
17
|
+
UnsupportedEasingFunctionError: typeof UnsupportedEasingFunctionError;
|
|
18
|
+
StepSyntaxError: typeof StepSyntaxError;
|
|
19
|
+
LinearSyntaxError: typeof LinearSyntaxError;
|
|
20
|
+
CubicBezierSyntaxError: typeof CubicBezierSyntaxError;
|
|
21
|
+
UnsupportedColorError: typeof UnsupportedColorError;
|
|
22
|
+
}
|
|
9
23
|
}
|
|
@@ -1,16 +1,24 @@
|
|
|
1
|
+
export interface NativePlugins {
|
|
2
|
+
}
|
|
3
|
+
export interface NativeConstants {
|
|
4
|
+
[key: string]: any;
|
|
5
|
+
}
|
|
6
|
+
export interface NativeErrors {
|
|
7
|
+
[key: string]: ErrorConstructor;
|
|
8
|
+
}
|
|
1
9
|
export declare interface ModuleBase {
|
|
2
|
-
Constants: Record<string, any>;
|
|
3
|
-
Errors: Record<string, ErrorConstructor>;
|
|
4
10
|
}
|
|
5
11
|
export declare interface NativePlugin<T> extends ModuleBase {
|
|
6
12
|
installed: boolean;
|
|
7
13
|
name: string;
|
|
8
14
|
module: T;
|
|
15
|
+
Constants: Record<string, any>;
|
|
16
|
+
Errors: Record<string, ErrorConstructor>;
|
|
9
17
|
}
|
|
10
18
|
export declare interface NativeBase extends ModuleBase {
|
|
11
19
|
Version: string;
|
|
20
|
+
Constants: NativeConstants;
|
|
21
|
+
Errors: NativeErrors;
|
|
12
22
|
extends: <T>(plugin: NativePlugin<T>) => NativeInstance;
|
|
13
23
|
}
|
|
14
|
-
export interface NativePlugins {
|
|
15
|
-
}
|
|
16
24
|
export type NativeInstance = NativeBase & NativePlugins;
|
package/package.json
CHANGED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { OS } from '../../../constants/platform';
|
|
2
|
-
import { AppOpenState, Messengers } from '../constants/app';
|
|
3
|
-
export declare interface EventListenerUtil {
|
|
4
|
-
useStd: boolean;
|
|
5
|
-
add: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
6
|
-
remove: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
7
|
-
withVender: (target: any, type?: string) => string;
|
|
8
|
-
}
|
|
9
|
-
export declare interface EventListenerOptions {
|
|
10
|
-
type?: string;
|
|
11
|
-
callback: EventListenerOrEventListenerObject | null;
|
|
12
|
-
options?: AddEventListenerOptions | boolean;
|
|
13
|
-
}
|
|
14
|
-
export declare interface AppInfo {
|
|
15
|
-
scheme?: URLCandidate;
|
|
16
|
-
fallback?: URLCandidate | (() => any);
|
|
17
|
-
timeout?: number;
|
|
18
|
-
allowWebStore?: boolean;
|
|
19
|
-
}
|
|
20
|
-
export declare interface AndroidAppInfo extends AppInfo {
|
|
21
|
-
packageName?: string;
|
|
22
|
-
intent?: URLCandidate;
|
|
23
|
-
}
|
|
24
|
-
export declare interface IOSAppInfo extends MacOSAppInfo {
|
|
25
|
-
universal?: URLCandidate;
|
|
26
|
-
}
|
|
27
|
-
export declare interface WindowsAppInfo extends AppInfo {
|
|
28
|
-
productId?: string;
|
|
29
|
-
}
|
|
30
|
-
export declare interface MacOSAppInfo extends AppInfo {
|
|
31
|
-
bundleId?: string;
|
|
32
|
-
trackId?: string;
|
|
33
|
-
}
|
|
34
|
-
export declare interface AppOpenOptions {
|
|
35
|
-
[OS.Android]?: AndroidAppInfo;
|
|
36
|
-
[OS.iOS]?: IOSAppInfo;
|
|
37
|
-
[OS.Windows]?: WindowsAppInfo;
|
|
38
|
-
[OS.MacOS]?: MacOSAppInfo;
|
|
39
|
-
}
|
|
40
|
-
export declare type URLCandidate = URL | string;
|
|
41
|
-
export declare type Stringifiable = string | number | boolean | HTMLElement | null | undefined;
|
|
42
|
-
export declare type StringifiableSequence = Stringifiable[] | NodeList | NodeListOf<Node> | HTMLCollectionBase;
|
|
43
|
-
export declare type MessengerOpenOptions = {
|
|
44
|
-
to?: Stringifiable | StringifiableSequence;
|
|
45
|
-
cc?: Stringifiable | StringifiableSequence;
|
|
46
|
-
bcc?: Stringifiable | StringifiableSequence;
|
|
47
|
-
subject?: Stringifiable;
|
|
48
|
-
body?: Stringifiable;
|
|
49
|
-
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions, self?: WindowProxy) => Promise<void>>;
|
|
51
|
-
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions, target?: WindowProxy) => Promise<AppOpenState>;
|
|
53
|
-
messenger: Messenger;
|
|
54
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Devices, Engines, OS } from '../../../constants/platform';
|
|
2
|
-
export declare interface PlatformInstance {
|
|
3
|
-
os: OS;
|
|
4
|
-
device: Devices;
|
|
5
|
-
engine: Engines;
|
|
6
|
-
osVersion: string;
|
|
7
|
-
engineVersion: string;
|
|
8
|
-
renderer: string;
|
|
9
|
-
isWebview: boolean;
|
|
10
|
-
isStandalone: boolean;
|
|
11
|
-
isMobile: boolean;
|
|
12
|
-
isDesktop: boolean;
|
|
13
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Appearances } from '../constants/theme';
|
|
2
|
-
import type { EasingKeyword, EasingSyntax } from '../types/easing-syntax';
|
|
3
|
-
import type { Color } from '../types/color';
|
|
4
|
-
export declare interface ListenerEntry {
|
|
5
|
-
fn: (appearance: Appearances) => any;
|
|
6
|
-
capture: boolean;
|
|
7
|
-
once: boolean;
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
}
|
|
10
|
-
export declare type ThemeColorMetaAppearanceKeys = 'default' | 'dark' | 'light';
|
|
11
|
-
export declare type ThemeColorMetaGroup = Partial<Record<ThemeColorMetaAppearanceKeys, HTMLMetaElement>>;
|
|
12
|
-
export declare interface SetThemeColorOptions {
|
|
13
|
-
appearance?: ThemeColorMetaAppearanceKeys;
|
|
14
|
-
duration?: number;
|
|
15
|
-
easingFunction?: EasingSyntax | EasingKeyword;
|
|
16
|
-
defaultColor?: string;
|
|
17
|
-
}
|
|
18
|
-
export declare interface ThemeInstance {
|
|
19
|
-
setThemeColor: (color: Color, options?: SetThemeColorOptions) => Promise<string | undefined>;
|
|
20
|
-
getThemeColor: () => Color | undefined;
|
|
21
|
-
removeThemeColor: (appearance?: ThemeColorMetaAppearanceKeys) => void;
|
|
22
|
-
detectAppearance: () => Promise<Appearances>;
|
|
23
|
-
onAppearanceChange: (listener: (appearance?: Appearances) => any, options?: boolean | AddEventListenerOptions) => () => void;
|
|
24
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { OS } from '../../../constants/platform';
|
|
2
|
-
import { AppOpenState, Messengers } from '../constants/app';
|
|
3
|
-
export declare interface EventListenerUtil {
|
|
4
|
-
useStd: boolean;
|
|
5
|
-
add: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
6
|
-
remove: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
7
|
-
withVender: (target: any, type?: string) => string;
|
|
8
|
-
}
|
|
9
|
-
export declare interface EventListenerOptions {
|
|
10
|
-
type?: string;
|
|
11
|
-
callback: EventListenerOrEventListenerObject | null;
|
|
12
|
-
options?: AddEventListenerOptions | boolean;
|
|
13
|
-
}
|
|
14
|
-
export declare interface AppInfo {
|
|
15
|
-
scheme?: URLCandidate;
|
|
16
|
-
fallback?: URLCandidate | (() => any);
|
|
17
|
-
timeout?: number;
|
|
18
|
-
allowWebStore?: boolean;
|
|
19
|
-
}
|
|
20
|
-
export declare interface AndroidAppInfo extends AppInfo {
|
|
21
|
-
packageName?: string;
|
|
22
|
-
intent?: URLCandidate;
|
|
23
|
-
}
|
|
24
|
-
export declare interface IOSAppInfo extends MacOSAppInfo {
|
|
25
|
-
universal?: URLCandidate;
|
|
26
|
-
}
|
|
27
|
-
export declare interface WindowsAppInfo extends AppInfo {
|
|
28
|
-
productId?: string;
|
|
29
|
-
}
|
|
30
|
-
export declare interface MacOSAppInfo extends AppInfo {
|
|
31
|
-
bundleId?: string;
|
|
32
|
-
trackId?: string;
|
|
33
|
-
}
|
|
34
|
-
export declare interface AppOpenOptions {
|
|
35
|
-
[OS.Android]?: AndroidAppInfo;
|
|
36
|
-
[OS.iOS]?: IOSAppInfo;
|
|
37
|
-
[OS.Windows]?: WindowsAppInfo;
|
|
38
|
-
[OS.MacOS]?: MacOSAppInfo;
|
|
39
|
-
}
|
|
40
|
-
export declare type URLCandidate = URL | string;
|
|
41
|
-
export declare type Stringifiable = string | number | boolean | HTMLElement | null | undefined;
|
|
42
|
-
export declare type StringifiableSequence = Stringifiable[] | NodeList | NodeListOf<Node> | HTMLCollectionBase;
|
|
43
|
-
export declare type MessengerOpenOptions = {
|
|
44
|
-
to?: Stringifiable | StringifiableSequence;
|
|
45
|
-
cc?: Stringifiable | StringifiableSequence;
|
|
46
|
-
bcc?: Stringifiable | StringifiableSequence;
|
|
47
|
-
subject?: Stringifiable;
|
|
48
|
-
body?: Stringifiable;
|
|
49
|
-
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions, self?: WindowProxy) => Promise<void>>;
|
|
51
|
-
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions, target?: WindowProxy) => Promise<AppOpenState>;
|
|
53
|
-
messenger: Messenger;
|
|
54
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Devices, Engines, OS } from '../../../constants/platform';
|
|
2
|
-
export declare interface PlatformInstance {
|
|
3
|
-
os: OS;
|
|
4
|
-
device: Devices;
|
|
5
|
-
engine: Engines;
|
|
6
|
-
osVersion: string;
|
|
7
|
-
engineVersion: string;
|
|
8
|
-
renderer: string;
|
|
9
|
-
isWebview: boolean;
|
|
10
|
-
isStandalone: boolean;
|
|
11
|
-
isMobile: boolean;
|
|
12
|
-
isDesktop: boolean;
|
|
13
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Appearances } from '../constants/theme';
|
|
2
|
-
import type { EasingKeyword, EasingSyntax } from '../types/easing-syntax';
|
|
3
|
-
import type { Color } from '../types/color';
|
|
4
|
-
export declare interface ListenerEntry {
|
|
5
|
-
fn: (appearance: Appearances) => any;
|
|
6
|
-
capture: boolean;
|
|
7
|
-
once: boolean;
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
}
|
|
10
|
-
export declare type ThemeColorMetaAppearanceKeys = 'default' | 'dark' | 'light';
|
|
11
|
-
export declare type ThemeColorMetaGroup = Partial<Record<ThemeColorMetaAppearanceKeys, HTMLMetaElement>>;
|
|
12
|
-
export declare interface SetThemeColorOptions {
|
|
13
|
-
appearance?: ThemeColorMetaAppearanceKeys;
|
|
14
|
-
duration?: number;
|
|
15
|
-
easingFunction?: EasingSyntax | EasingKeyword;
|
|
16
|
-
defaultColor?: string;
|
|
17
|
-
}
|
|
18
|
-
export declare interface ThemeInstance {
|
|
19
|
-
setThemeColor: (color: Color, options?: SetThemeColorOptions) => Promise<string | undefined>;
|
|
20
|
-
getThemeColor: () => Color | undefined;
|
|
21
|
-
removeThemeColor: (appearance?: ThemeColorMetaAppearanceKeys) => void;
|
|
22
|
-
detectAppearance: () => Promise<Appearances>;
|
|
23
|
-
onAppearanceChange: (listener: (appearance?: Appearances) => any, options?: boolean | AddEventListenerOptions) => () => void;
|
|
24
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { OS } from '../../../constants/platform';
|
|
2
|
-
import { AppOpenState, Messengers } from '../constants/app';
|
|
3
|
-
export declare interface EventListenerUtil {
|
|
4
|
-
useStd: boolean;
|
|
5
|
-
add: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
6
|
-
remove: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
7
|
-
withVender: (target: any, type?: string) => string;
|
|
8
|
-
}
|
|
9
|
-
export declare interface EventListenerOptions {
|
|
10
|
-
type?: string;
|
|
11
|
-
callback: EventListenerOrEventListenerObject | null;
|
|
12
|
-
options?: AddEventListenerOptions | boolean;
|
|
13
|
-
}
|
|
14
|
-
export declare interface AppInfo {
|
|
15
|
-
scheme?: URLCandidate;
|
|
16
|
-
fallback?: URLCandidate | (() => any);
|
|
17
|
-
timeout?: number;
|
|
18
|
-
allowWebStore?: boolean;
|
|
19
|
-
}
|
|
20
|
-
export declare interface AndroidAppInfo extends AppInfo {
|
|
21
|
-
packageName?: string;
|
|
22
|
-
intent?: URLCandidate;
|
|
23
|
-
}
|
|
24
|
-
export declare interface IOSAppInfo extends MacOSAppInfo {
|
|
25
|
-
universal?: URLCandidate;
|
|
26
|
-
}
|
|
27
|
-
export declare interface WindowsAppInfo extends AppInfo {
|
|
28
|
-
productId?: string;
|
|
29
|
-
}
|
|
30
|
-
export declare interface MacOSAppInfo extends AppInfo {
|
|
31
|
-
bundleId?: string;
|
|
32
|
-
trackId?: string;
|
|
33
|
-
}
|
|
34
|
-
export declare interface AppOpenOptions {
|
|
35
|
-
[OS.Android]?: AndroidAppInfo;
|
|
36
|
-
[OS.iOS]?: IOSAppInfo;
|
|
37
|
-
[OS.Windows]?: WindowsAppInfo;
|
|
38
|
-
[OS.MacOS]?: MacOSAppInfo;
|
|
39
|
-
}
|
|
40
|
-
export declare type URLCandidate = URL | string;
|
|
41
|
-
export declare type Stringifiable = string | number | boolean | HTMLElement | null | undefined;
|
|
42
|
-
export declare type StringifiableSequence = Stringifiable[] | NodeList | NodeListOf<Node> | HTMLCollectionBase;
|
|
43
|
-
export declare type MessengerOpenOptions = {
|
|
44
|
-
to?: Stringifiable | StringifiableSequence;
|
|
45
|
-
cc?: Stringifiable | StringifiableSequence;
|
|
46
|
-
bcc?: Stringifiable | StringifiableSequence;
|
|
47
|
-
subject?: Stringifiable;
|
|
48
|
-
body?: Stringifiable;
|
|
49
|
-
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions, self?: WindowProxy) => Promise<void>>;
|
|
51
|
-
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions, target?: WindowProxy) => Promise<AppOpenState>;
|
|
53
|
-
messenger: Messenger;
|
|
54
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Devices, Engines, OS } from '../../../constants/platform';
|
|
2
|
-
export declare interface PlatformInstance {
|
|
3
|
-
os: OS;
|
|
4
|
-
device: Devices;
|
|
5
|
-
engine: Engines;
|
|
6
|
-
osVersion: string;
|
|
7
|
-
engineVersion: string;
|
|
8
|
-
renderer: string;
|
|
9
|
-
isWebview: boolean;
|
|
10
|
-
isStandalone: boolean;
|
|
11
|
-
isMobile: boolean;
|
|
12
|
-
isDesktop: boolean;
|
|
13
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Appearances } from '../constants/theme';
|
|
2
|
-
import type { EasingKeyword, EasingSyntax } from '../types/easing-syntax';
|
|
3
|
-
import type { Color } from '../types/color';
|
|
4
|
-
export declare interface ListenerEntry {
|
|
5
|
-
fn: (appearance: Appearances) => any;
|
|
6
|
-
capture: boolean;
|
|
7
|
-
once: boolean;
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
}
|
|
10
|
-
export declare type ThemeColorMetaAppearanceKeys = 'default' | 'dark' | 'light';
|
|
11
|
-
export declare type ThemeColorMetaGroup = Partial<Record<ThemeColorMetaAppearanceKeys, HTMLMetaElement>>;
|
|
12
|
-
export declare interface SetThemeColorOptions {
|
|
13
|
-
appearance?: ThemeColorMetaAppearanceKeys;
|
|
14
|
-
duration?: number;
|
|
15
|
-
easingFunction?: EasingSyntax | EasingKeyword;
|
|
16
|
-
defaultColor?: string;
|
|
17
|
-
}
|
|
18
|
-
export declare interface ThemeInstance {
|
|
19
|
-
setThemeColor: (color: Color, options?: SetThemeColorOptions) => Promise<string | undefined>;
|
|
20
|
-
getThemeColor: () => Color | undefined;
|
|
21
|
-
removeThemeColor: (appearance?: ThemeColorMetaAppearanceKeys) => void;
|
|
22
|
-
detectAppearance: () => Promise<Appearances>;
|
|
23
|
-
onAppearanceChange: (listener: (appearance?: Appearances) => any, options?: boolean | AddEventListenerOptions) => () => void;
|
|
24
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { OS } from '../../../constants/platform';
|
|
2
|
-
import { AppOpenState, Messengers } from '../constants/app';
|
|
3
|
-
export declare interface EventListenerUtil {
|
|
4
|
-
useStd: boolean;
|
|
5
|
-
add: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
6
|
-
remove: (target: any, eventListenerOptions: EventListenerOptions) => void;
|
|
7
|
-
withVender: (target: any, type?: string) => string;
|
|
8
|
-
}
|
|
9
|
-
export declare interface EventListenerOptions {
|
|
10
|
-
type?: string;
|
|
11
|
-
callback: EventListenerOrEventListenerObject | null;
|
|
12
|
-
options?: AddEventListenerOptions | boolean;
|
|
13
|
-
}
|
|
14
|
-
export declare interface AppInfo {
|
|
15
|
-
scheme?: URLCandidate;
|
|
16
|
-
fallback?: URLCandidate | (() => any);
|
|
17
|
-
timeout?: number;
|
|
18
|
-
allowWebStore?: boolean;
|
|
19
|
-
}
|
|
20
|
-
export declare interface AndroidAppInfo extends AppInfo {
|
|
21
|
-
packageName?: string;
|
|
22
|
-
intent?: URLCandidate;
|
|
23
|
-
}
|
|
24
|
-
export declare interface IOSAppInfo extends MacOSAppInfo {
|
|
25
|
-
universal?: URLCandidate;
|
|
26
|
-
}
|
|
27
|
-
export declare interface WindowsAppInfo extends AppInfo {
|
|
28
|
-
productId?: string;
|
|
29
|
-
}
|
|
30
|
-
export declare interface MacOSAppInfo extends AppInfo {
|
|
31
|
-
bundleId?: string;
|
|
32
|
-
trackId?: string;
|
|
33
|
-
}
|
|
34
|
-
export declare interface AppOpenOptions {
|
|
35
|
-
[OS.Android]?: AndroidAppInfo;
|
|
36
|
-
[OS.iOS]?: IOSAppInfo;
|
|
37
|
-
[OS.Windows]?: WindowsAppInfo;
|
|
38
|
-
[OS.MacOS]?: MacOSAppInfo;
|
|
39
|
-
}
|
|
40
|
-
export declare type URLCandidate = URL | string;
|
|
41
|
-
export declare type Stringifiable = string | number | boolean | HTMLElement | null | undefined;
|
|
42
|
-
export declare type StringifiableSequence = Stringifiable[] | NodeList | NodeListOf<Node> | HTMLCollectionBase;
|
|
43
|
-
export declare type MessengerOpenOptions = {
|
|
44
|
-
to?: Stringifiable | StringifiableSequence;
|
|
45
|
-
cc?: Stringifiable | StringifiableSequence;
|
|
46
|
-
bcc?: Stringifiable | StringifiableSequence;
|
|
47
|
-
subject?: Stringifiable;
|
|
48
|
-
body?: Stringifiable;
|
|
49
|
-
} | HTMLFormElement | FormData;
|
|
50
|
-
export declare type Messenger = Record<Messengers, (options: MessengerOpenOptions, self?: WindowProxy) => Promise<void>>;
|
|
51
|
-
export declare interface AppInstance {
|
|
52
|
-
open: (options: AppOpenOptions, target?: WindowProxy) => Promise<AppOpenState>;
|
|
53
|
-
messenger: Messenger;
|
|
54
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Devices, Engines, OS } from '../../../constants/platform';
|
|
2
|
-
export declare interface PlatformInstance {
|
|
3
|
-
os: OS;
|
|
4
|
-
device: Devices;
|
|
5
|
-
engine: Engines;
|
|
6
|
-
osVersion: string;
|
|
7
|
-
engineVersion: string;
|
|
8
|
-
renderer: string;
|
|
9
|
-
isWebview: boolean;
|
|
10
|
-
isStandalone: boolean;
|
|
11
|
-
isMobile: boolean;
|
|
12
|
-
isDesktop: boolean;
|
|
13
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Appearances } from '../constants/theme';
|
|
2
|
-
import type { EasingKeyword, EasingSyntax } from '../types/easing-syntax';
|
|
3
|
-
import type { Color } from '../types/color';
|
|
4
|
-
export declare interface ListenerEntry {
|
|
5
|
-
fn: (appearance: Appearances) => any;
|
|
6
|
-
capture: boolean;
|
|
7
|
-
once: boolean;
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
}
|
|
10
|
-
export declare type ThemeColorMetaAppearanceKeys = 'default' | 'dark' | 'light';
|
|
11
|
-
export declare type ThemeColorMetaGroup = Partial<Record<ThemeColorMetaAppearanceKeys, HTMLMetaElement>>;
|
|
12
|
-
export declare interface SetThemeColorOptions {
|
|
13
|
-
appearance?: ThemeColorMetaAppearanceKeys;
|
|
14
|
-
duration?: number;
|
|
15
|
-
easingFunction?: EasingSyntax | EasingKeyword;
|
|
16
|
-
defaultColor?: string;
|
|
17
|
-
}
|
|
18
|
-
export declare interface ThemeInstance {
|
|
19
|
-
setThemeColor: (color: Color, options?: SetThemeColorOptions) => Promise<string | undefined>;
|
|
20
|
-
getThemeColor: () => Color | undefined;
|
|
21
|
-
removeThemeColor: (appearance?: ThemeColorMetaAppearanceKeys) => void;
|
|
22
|
-
detectAppearance: () => Promise<Appearances>;
|
|
23
|
-
onAppearanceChange: (listener: (appearance?: Appearances) => any, options?: boolean | AddEventListenerOptions) => () => void;
|
|
24
|
-
}
|