feat: 添加二维码扫描页面,优化用户界面和扫描功能

This commit is contained in:
2026-01-12 00:44:42 +07:00
parent 4902a155a1
commit 8a7af3783b
4 changed files with 57 additions and 12 deletions

View File

@@ -12,9 +12,9 @@ import TradeSettings from "./components/trade-settings.vue";
import UserInfo from "./components/user-info.vue";
import WalletCard from "./components/wallet-card.vue";
const router = useRouter();
const { vibrate } = useHaptics();
const walletStore = useWalletStore();
const { open } = useQRScanner();
async function handleRefresh(event: RefresherCustomEvent) {
vibrate();
@@ -27,15 +27,7 @@ async function handleRefresh(event: RefresherCustomEvent) {
// 处理扫描二维码
async function handleScan() {
vibrate();
const result = await open({
title: "扫描二维码",
});
if (result) {
console.log("扫描结果:", result);
// TODO: 根据扫描结果进行相应处理
// 例如:跳转到对应页面、显示信息等
}
router.push("/scan_qr");
}
</script>