fix(uni-app): 🐛 安装类型依赖
This commit is contained in:
parent
80debf6d6b
commit
18a037e9b7
|
|
@ -83,6 +83,7 @@
|
|||
"test": "vitest run"
|
||||
},
|
||||
"dependencies": {
|
||||
"@jonny1994/qqmap-wx-jssdk": "^1.4.0",
|
||||
"@r-utils/common": "workspace:^",
|
||||
"chroma-js": "catalog:",
|
||||
"lodash-es": "catalog:",
|
||||
|
|
|
|||
|
|
@ -1,3 +1,45 @@
|
|||
declare namespace WechatMiniprogram {
|
||||
/** 微信小程序 NFC 适配器 */
|
||||
interface NFCAdapter {
|
||||
/** 开始监听 NFC 标签发现事件 */
|
||||
startDiscovery(options?: {
|
||||
/** 启动成功回调 */
|
||||
success?: (res: NFCError) => void;
|
||||
/** 启动失败回调 */
|
||||
fail?: (res: NFCError) => void;
|
||||
}): void;
|
||||
/** 停止监听 NFC 标签发现事件 */
|
||||
stopDiscovery(options?: {
|
||||
/** 停止成功回调 */
|
||||
success?: (res: NFCError) => void;
|
||||
/** 停止失败回调 */
|
||||
fail?: (res: NFCError) => void;
|
||||
}): void;
|
||||
/** 注册 NFC 标签发现回调 */
|
||||
onDiscovered(callback: (res: OnDiscoveredCallbackResult) => void): void;
|
||||
/** 取消注册 NFC 标签发现回调 */
|
||||
offDiscovered(callback?: (res: OnDiscoveredCallbackResult) => void): void;
|
||||
}
|
||||
|
||||
/** 微信小程序 NFC 操作结果 */
|
||||
interface NFCError {
|
||||
/** 错误码 */
|
||||
errCode?: number;
|
||||
/** 错误信息 */
|
||||
errMsg?: string;
|
||||
}
|
||||
|
||||
/** 微信小程序 NFC 标签发现结果 */
|
||||
interface OnDiscoveredCallbackResult {
|
||||
/** NFC 标签 ID */
|
||||
id: ArrayBuffer;
|
||||
/** NFC 标签消息列表 */
|
||||
messages?: unknown[];
|
||||
/** NFC 支持的技术列表 */
|
||||
techs?: string[];
|
||||
}
|
||||
}
|
||||
|
||||
export function startNfcScan(): Promise<number[]>;
|
||||
|
||||
export class WeixinNfcUtil {
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ declare module "vue/types/options" {
|
|||
export declare function install(Vue: VueConstructor): void;
|
||||
|
||||
/** 页面可见性生命周期插件 */
|
||||
declare const VisibilityPlugin: PluginObject<never> & {
|
||||
declare const VisibilityPlugin: PluginObject<unknown> & {
|
||||
/** 安装页面可见性生命周期插件 */
|
||||
install: typeof install;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import { ComponentPublicInstance } from "vue";
|
|||
type CustomClassObj = Record<string, boolean>;
|
||||
type CustomClass = string | Array<string> | CustomClassObj;
|
||||
type DistCustomClass = Record<string, true>;
|
||||
|
||||
export function createCustomClassObj(customClass: string): DistCustomClass;
|
||||
export function createCustomClassObj(
|
||||
customClass: Array<string>,
|
||||
|
|
|
|||
|
|
@ -153,6 +153,9 @@ importers:
|
|||
|
||||
packages/uni-app:
|
||||
dependencies:
|
||||
'@jonny1994/qqmap-wx-jssdk':
|
||||
specifier: ^1.4.0
|
||||
version: 1.4.0
|
||||
'@r-utils/common':
|
||||
specifier: workspace:^
|
||||
version: link:../common
|
||||
|
|
|
|||
Loading…
Reference in New Issue