mirror of
https://github.com/yattee/yattee.git
synced 2025-08-09 20:24:06 +00:00
Add chat links in settings
This commit is contained in:
@@ -3,7 +3,8 @@ import SwiftUI
|
||||
|
||||
struct Help: View {
|
||||
static let wikiURL = URL(string: "https://github.com/yattee/yattee/wiki")!
|
||||
static let matrixURL = URL(string: "https://tinyurl.com/yattee-matrix")!
|
||||
static let matrixURL = URL(string: "https://tinyurl.com/matrix-yattee")!
|
||||
static let discordURL = URL(string: "https://yattee.stream/discord")!
|
||||
static let issuesURL = URL(string: "https://github.com/yattee/yattee/issues")!
|
||||
static let milestonesURL = URL(string: "https://github.com/yattee/yattee/milestones")!
|
||||
static let donationsURL = URL(string: "https://github.com/yattee/yattee/wiki/Donations")!
|
||||
@@ -30,9 +31,11 @@ struct Help: View {
|
||||
Section {
|
||||
header("I want to ask a question")
|
||||
|
||||
Text("Discussions take place in Matrix chat channel. It's a good spot for general questions.")
|
||||
Text("Discussions take place in Discord and Matrix. It's a good spot for general questions.")
|
||||
.padding(.bottom, 8)
|
||||
|
||||
helpItemLink("Discord Server", url: Self.discordURL, systemImage: "message")
|
||||
.padding(.bottom, 8)
|
||||
helpItemLink("Matrix Channel", url: Self.matrixURL, systemImage: "message")
|
||||
.padding(.bottom, 8)
|
||||
}
|
||||
|
@@ -3,6 +3,9 @@ import Foundation
|
||||
import SwiftUI
|
||||
|
||||
struct SettingsView: View {
|
||||
static let matrixURL = URL(string: "https://tinyurl.com/matrix-yattee")!
|
||||
static let discordURL = URL(string: "https://yattee.stream/discord")!
|
||||
|
||||
#if os(macOS)
|
||||
private enum Tabs: Hashable {
|
||||
case locations, browsing, player, history, sponsorBlock, advanced, help
|
||||
@@ -158,13 +161,38 @@ struct SettingsView: View {
|
||||
}
|
||||
}
|
||||
|
||||
Section(footer: versionString) {
|
||||
Section {
|
||||
NavigationLink {
|
||||
Help()
|
||||
} label: {
|
||||
Label("Help", systemImage: "questionmark.circle")
|
||||
}
|
||||
}
|
||||
|
||||
#if !os(tvOS)
|
||||
Section(header: Text("Contact"), footer: versionString) {
|
||||
Link(destination: Self.discordURL) {
|
||||
HStack {
|
||||
Image("Discord")
|
||||
.resizable()
|
||||
.renderingMode(.template)
|
||||
.frame(maxWidth: 30, maxHeight: 30)
|
||||
|
||||
Text("Discord Server")
|
||||
}
|
||||
}
|
||||
|
||||
Link(destination: Self.matrixURL) {
|
||||
HStack {
|
||||
Image("Matrix")
|
||||
.resizable()
|
||||
.renderingMode(.template)
|
||||
.frame(maxWidth: 30, maxHeight: 30)
|
||||
Text("Matrix Chat")
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
.navigationTitle("Settings")
|
||||
.toolbar {
|
||||
@@ -200,7 +228,7 @@ struct SettingsView: View {
|
||||
case .advanced:
|
||||
return 300
|
||||
case .help:
|
||||
return 570
|
||||
return 600
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user