@hylid/types 4.0.0-alpha.4 → 4.0.0-alpha.6
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/lib/mp.d.ts +8 -3
- package/package.json +1 -1
package/lib/mp.d.ts
CHANGED
|
@@ -14,7 +14,6 @@ export interface IRPCArgs {
|
|
|
14
14
|
disableLimitView?: boolean;
|
|
15
15
|
timeout?: number;
|
|
16
16
|
getResponse?: boolean;
|
|
17
|
-
[key: string]: any;
|
|
18
17
|
}
|
|
19
18
|
export interface getCurrentPagesOptions {
|
|
20
19
|
payload?: Record<string, any>;
|
|
@@ -91,7 +90,7 @@ export interface MPApi extends Omit<MiniprogramApi, 'request'> {
|
|
|
91
90
|
defaultGateway: string;
|
|
92
91
|
defaultHeaders?: Record<string, string>;
|
|
93
92
|
request: PickMPAttr<'request'>;
|
|
94
|
-
}) => PickPromiseAttr<PickMPAttr<
|
|
93
|
+
}) => PickPromiseAttr<PickMPAttr<'rpc'>>;
|
|
95
94
|
rpcWithAuth: PickMPAttr<'rpc'>;
|
|
96
95
|
rpcWithAuthAPlus: PickMPAttr<'rpc'>;
|
|
97
96
|
defineRuntimeConfig: (args: Record<string, any>) => Record<string, any>;
|
|
@@ -109,7 +108,7 @@ export interface MPApi extends Omit<MiniprogramApi, 'request'> {
|
|
|
109
108
|
imageUrl?: string;
|
|
110
109
|
image?: string;
|
|
111
110
|
url: string;
|
|
112
|
-
}) => void;
|
|
111
|
+
} & AsyncCallback<void>) => void;
|
|
113
112
|
homeAddAppToMyApps: (args: {
|
|
114
113
|
appId: string;
|
|
115
114
|
}) => void;
|
|
@@ -181,6 +180,12 @@ export interface MPApi extends Omit<MiniprogramApi, 'request'> {
|
|
|
181
180
|
setTransparentTitle: (args: AsyncCallback<{
|
|
182
181
|
transparentTitle: 'none' | 'auto' | 'always' | 'custom';
|
|
183
182
|
}>) => void;
|
|
183
|
+
getLocation: (args: {
|
|
184
|
+
bizType?: string;
|
|
185
|
+
requestType?: number;
|
|
186
|
+
timeout?: number;
|
|
187
|
+
horizontalAccuracy?: number;
|
|
188
|
+
} & GetLocationArgs) => void;
|
|
184
189
|
}
|
|
185
190
|
export declare type HeadModel = {
|
|
186
191
|
/**
|