Add server URL to settings
This commit is contained in:
parent
1f25fa576d
commit
ca47292e3d
@ -21,7 +21,6 @@ struct JelApp: App {
|
||||
ContentView()
|
||||
.environmentObject(jellyfinClientController)
|
||||
.task {
|
||||
URLCache.shared.diskCapacity = 1_000_000_000 // 1GB cache for images
|
||||
AuthStateController.shared.load()
|
||||
SettingsController.shared.load()
|
||||
jellyfinClientController.setUrl(url: AuthStateController.shared.serverUrl)
|
||||
|
@ -47,6 +47,7 @@ struct ItemMediaView<Content: View>: View {
|
||||
}
|
||||
|
||||
ItemGenresView(item: item)
|
||||
.padding(.vertical)
|
||||
}
|
||||
.if(max(geo.safeAreaInsets.leading, geo.safeAreaInsets.trailing) > 0) {view in
|
||||
view
|
||||
|
@ -28,6 +28,11 @@ struct SettingsView: View {
|
||||
.textSelection(.enabled)
|
||||
}
|
||||
|
||||
LabeledContent("Server URL") {
|
||||
Text("\(authState.serverUrl?.absoluteString ?? "---")")
|
||||
.textSelection(.enabled)
|
||||
}
|
||||
|
||||
Button(role: .destructive) {
|
||||
authState.loggedIn = false
|
||||
authState.save()
|
||||
@ -81,6 +86,6 @@ struct SettingsView: View {
|
||||
}
|
||||
}
|
||||
|
||||
#Preview {
|
||||
SettingsView(showingSettingsView: .constant(true))
|
||||
}
|
||||
//#Preview {
|
||||
// SettingsView(showingSettingsView: .constant(true))
|
||||
//}
|
||||
|
Loading…
Reference in New Issue
Block a user