struct Match: Equatable {
let left: Title
let right: Title
}
func swipe(_ title: Title, vote: Vote) {
session.send(vote)
if partner.agreed(on: title) {
queue.append(Match(left: title, right: title))
}
}
final class CoupleWatch {
var titles: [Title] = []
func load() async throws {
titles = try await api.feed(region: .device)
}
}
NavigationStack {
SwipeView()
.toolbar { InviteCode() }
}
let packing = PackingList.template(.city)
trip.pins.append(PlacePin(coord))
map.markVisited(country)
@main
struct WaywovenApp: App {
var body: some Scene {
WindowGroup { HomeView() }
}
}
struct Match: Equatable {
let left: Title
let right: Title
}
func swipe(_ title: Title, vote: Vote) {
session.send(vote)
if partner.agreed(on: title) {
queue.append(Match(left: title, right: title))
}
}
class DuetlyApp extends StatelessWidget {
Widget build(BuildContext context) {
return MaterialApp(home: SwipeDeck());
}
}
Future<void> joinPair(String code) async {
await supabase.from('pairs').upsert({
'code': code,
'user_b': session.user.id,
});
}
onPanEnd: (details) {
if (details.velocity.dx > 400) like();
if (details.velocity.dx < -400) skip();
}
StreamBuilder(
stream: likes.snapshots(),
builder: (_, snap) => MatchList(snap.data),
)
Trip(
name: "Lisbon",
pins: const [],
packing: PackingList.beach(),
)
void markCountry(String iso) {
visited.add(iso);
sync.upload(visited);
}
class DuetlyApp extends StatelessWidget {
Widget build(BuildContext context) {
return MaterialApp(home: SwipeDeck());
}
}