diff --git a/manifest.config.ts b/manifest.config.ts index b07a012..275045b 100644 --- a/manifest.config.ts +++ b/manifest.config.ts @@ -39,7 +39,12 @@ export default defineManifestConfig({ '', '', '', - '', + '', + '', + '', + '', + '', + '', '', '', '', @@ -48,7 +53,7 @@ export default defineManifestConfig({ '', '', '', - ], + ] as any, }, /* ios打包配置 */ ios: {}, diff --git a/src/auto-imports.d.ts b/src/auto-imports.d.ts index ebdb95e..808a544 100644 --- a/src/auto-imports.d.ts +++ b/src/auto-imports.d.ts @@ -9,6 +9,7 @@ declare global { const EffectScope: typeof import('vue')['EffectScope'] const asyncComputed: typeof import('@vueuse/core')['asyncComputed'] const autoResetRef: typeof import('@vueuse/core')['autoResetRef'] + const bluetooth: typeof import('./utils/bluetooth')['default'] const closeDatabase: typeof import('./utils/sqlite')['closeDatabase'] const computed: typeof import('vue')['computed'] const computedAsync: typeof import('@vueuse/core')['computedAsync'] @@ -337,6 +338,9 @@ declare global { export type { Component, Slot, Slots, ComponentPublicInstance, ComputedRef, DirectiveBinding, ExtractDefaultPropTypes, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, MaybeRef, MaybeRefOrGetter, VNode, WritableComputedRef } from 'vue' import('vue') // @ts-ignore + export type { BluetoothDevice, ScanOptions, ScanForDeviceOptions, WriteOptions, BluetoothReceiveData, BluetoothConnectionState, DataCallback, ConnectionStateCallback, DeviceFoundCallback } from './utils/bluetooth' + import('./utils/bluetooth') + // @ts-ignore export type { SystemInfo } from './utils/device' import('./utils/device') // @ts-ignore @@ -352,6 +356,7 @@ declare module 'vue' { readonly EffectScope: UnwrapRef readonly asyncComputed: UnwrapRef readonly autoResetRef: UnwrapRef + readonly bluetooth: UnwrapRef readonly closeDatabase: UnwrapRef readonly computed: UnwrapRef readonly computedAsync: UnwrapRef diff --git a/src/components/bluetooth/connect.vue b/src/components/bluetooth/connect.vue index 8aa8a9c..8a24c8e 100644 --- a/src/components/bluetooth/connect.vue +++ b/src/components/bluetooth/connect.vue @@ -1,33 +1,212 @@