Skip to content

Commit

Permalink
unocss
Browse files Browse the repository at this point in the history
  • Loading branch information
sudoskys committed May 8, 2024
1 parent a154352 commit 6c2fe45
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions frontend/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@
import {useWebApp} from "vue-tg";
import {BiometricManager} from "vue-tg";
import {useWebAppBiometricManager} from 'vue-tg';
import {useWebAppPopup} from 'vue-tg'
import {ref} from "vue";
// 响应式数据
const token = ref<string | undefined>(undefined)
const popup = useWebAppPopup()
const WebApp = useWebApp();
const WebAppBiometricManager = useWebAppBiometricManager();
WebApp.ready()
Expand All @@ -20,13 +21,13 @@ const authBiometric = () => {
token.value = auth_token
}
if (!WebAppBiometricManager.isBiometricInited) {
console.log('Biometric not inited')
token.value = 'Biometric not initialized'
console.log('Biometric not initialized')
popup.showAlert('Biometric not initialized')
return
}
if (!WebAppBiometricManager.isBiometricAvailable) {
console.log('Biometric not supported')
token.value = 'Biometric not supported'
popup.showAlert('Biometric not supported')
return
}
const result = WebAppBiometricManager.requestBiometricAccess(
Expand Down

0 comments on commit 6c2fe45

Please sign in to comment.