feat(ui): friends list as lobby-style rows with kebab + confirm modals #123
@@ -80,6 +80,19 @@
|
||||
if (target) void remove(target.accountId);
|
||||
}
|
||||
|
||||
// While a friend row is slid open, a tap anywhere outside its action buttons
|
||||
// closes it again. Taps on a kebab are skipped so its own toggle stays in charge.
|
||||
$effect(() => {
|
||||
if (revealedId === null) return;
|
||||
function onDown(e: PointerEvent) {
|
||||
const el = e.target as Element | null;
|
||||
if (el?.closest('.acts') || el?.closest('.kebab')) return;
|
||||
revealedId = null;
|
||||
}
|
||||
window.addEventListener('pointerdown', onDown, true);
|
||||
return () => window.removeEventListener('pointerdown', onDown, true);
|
||||
});
|
||||
|
||||
async function getCode() {
|
||||
try {
|
||||
code = await gateway.friendCodeIssue();
|
||||
|
||||
Reference in New Issue
Block a user