Skip to content
This repository was archived by the owner on Feb 23, 2026. It is now read-only.
/ harmonie Public archive

Commit ab40564

Browse files
authored
Merge pull request #206 from makinosp/develop
Develop
2 parents 180620b + a162696 commit ab40564

File tree

5 files changed

+79
-33
lines changed

5 files changed

+79
-33
lines changed

PrivacyPolicy.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Privacy Policy
2+
3+
## About the App
4+
5+
This application is a tool that uses the VRChat Web API to display and manage information related to VRChat accounts. The app respects user privacy and operates in accordance with the policies outlined below.
6+
7+
## Collection of Personal Information
8+
9+
This application does not collect, store, or share any personal information from users. All data is obtained through the VRChat Web API and used only within the app.
10+
11+
## Handling of Authentication Information
12+
13+
The app uses VRChat authentication tokens to access the API. These tokens are securely stored on the device and are not shared with any third parties.
14+
15+
## VRChat Privacy Policy
16+
17+
When using the VRChat API, users must comply with VRChat’s Privacy Policy. Please refer to the following link for details:
18+
[VRChat Privacy Policy](https://hello.vrchat.com/privacy)
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
//
2+
// GeometricScreen.swift
3+
// Harmonie
4+
//
5+
// Created by makinosp on 2024/11/15.
6+
//
7+
8+
import SwiftUICore
9+
10+
struct GeometricScreen<Content>: View where Content: View {
11+
private let content: () -> Content
12+
private let action: (_ geometry: GeometryProxy) -> Void
13+
14+
init(
15+
@ViewBuilder content: @escaping () -> Content,
16+
action: @escaping (_ geometry: GeometryProxy) -> Void
17+
) {
18+
self.content = content
19+
self.action = action
20+
}
21+
22+
var body: some View {
23+
GeometryReader { geometry in
24+
content()
25+
.onChange(of: geometry) {
26+
action(geometry)
27+
}
28+
.onAppear {
29+
action(geometry)
30+
}
31+
}
32+
}
33+
}

harmonie/Views/ContentView.swift

Lines changed: 16 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,23 @@ struct ContentView: View {
1414
@Environment(FavoriteViewModel.self) var favoriteVM: FavoriteViewModel
1515

1616
var body: some View {
17-
GeometryReader { geometry in
18-
Group {
19-
switch appVM.step {
20-
case .initializing:
21-
ProgressScreen()
22-
.task {
23-
appVM.step = await appVM.setup(service: appVM.services.authenticationService)
24-
}
25-
.errorAlert()
26-
case .loggingIn:
27-
LoginView()
28-
.errorAlert()
29-
case .done:
30-
MainTabView()
31-
.errorAlert()
32-
}
33-
}
34-
.onChange(of: geometry) {
35-
setScreenSize(geometry)
36-
}
37-
.onAppear {
38-
setScreenSize(geometry)
17+
GeometricScreen {
18+
switch appVM.step {
19+
case .initializing:
20+
ProgressScreen()
21+
.task {
22+
appVM.step = await appVM.setup(service: appVM.services.authenticationService)
23+
}
24+
.errorAlert()
25+
case .loggingIn:
26+
LoginView()
27+
.errorAlert()
28+
case .done:
29+
MainTabView()
30+
.errorAlert()
3931
}
32+
} action: { geometry in
33+
setScreenSize(geometry)
4034
}
4135
}
4236

harmonie/Views/Location/LocationsView.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ struct LocationsView: View {
8686
}
8787
}
8888
}
89+
.safeAreaPadding(.top, 20)
8990
.background(Color(.systemGroupedBackground))
9091
.setColumn(appVM.screenSize)
9192
}

harmonie/Views/MainTabView.swift

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import VRCKit
1010

1111
struct MainTabView: View {
1212
@Environment(\.scenePhase) var scenePhase
13+
@Environment(\.horizontalSizeClass) var defaultHorizontalSizeClass
1314
@Environment(AppViewModel.self) var appVM: AppViewModel
1415
@Environment(FriendViewModel.self) var friendVM: FriendViewModel
1516
@Environment(FavoriteViewModel.self) var favoriteVM: FavoriteViewModel
@@ -48,15 +49,6 @@ extension MainTabViewSegment {
4849
case .settings: SettingsView()
4950
}
5051
}
51-
52-
var label: Label<Text, Image> {
53-
Label(description, systemImage: icon.systemName)
54-
}
55-
56-
@available(iOS 18, *)
57-
var tab: some TabContent {
58-
Tab(description, systemImage: icon.systemName, value: self) { content }
59-
}
6052
}
6153

6254
@MainActor
@@ -85,17 +77,25 @@ extension MainTabView {
8577
tabSegment.content
8678
.tag(tabSegment)
8779
.tabItem {
88-
tabSegment.label
80+
Label(
81+
tabSegment.description,
82+
systemImage: tabSegment.icon.systemName
83+
)
8984
}
9085
}
9186
}
9287
}
9388

9489
@available(iOS 18, *) private var tabView: some View {
9590
TabView(selection: $selection) {
96-
return ForEach(MainTabViewSegment.allCases) { $0.tab }
91+
ForEach(MainTabViewSegment.allCases) { segment in
92+
Tab(segment.description, systemImage: segment.icon.systemName, value: segment) {
93+
segment.content.environment(\.horizontalSizeClass, defaultHorizontalSizeClass)
94+
}
95+
}
9796
}
9897
.tabViewStyle(.sidebarAdaptable)
98+
.environment(\.horizontalSizeClass, .compact)
9999
}
100100

101101
private func fetchFriendsTask() async {

0 commit comments

Comments
 (0)