feat: allow search .bsky.social account #notesearch

This commit is contained in:
Lhc_fl 2024-10-18 08:45:45 +08:00 committed by laoXong
parent 9bd46e6351
commit 03ed6aaa90

View File

@ -175,7 +175,12 @@ async function search() {
text: i18n.ts.lookupConfirm,
});
if (!confirm.canceled) {
router.push(`/${query}`);
if (query.endsWith('.bsky.social')) {
// convert to bsky bridge
router.push(`/${query}@bsky.brid.gy`);
} else {
router.push(`/${query}`);
}
return;
}
}