Skip to content

Commit

Permalink
(Jyutping App) Improve AboutView and MacAboutView
Browse files Browse the repository at this point in the history
  • Loading branch information
bingzheung committed Oct 24, 2023
1 parent a061df2 commit 7fcb1b8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
13 changes: 6 additions & 7 deletions Jyutping/Jyutping/AppMaster.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,16 @@ struct AppMaster {
return marketingVersion + " (" + currentProjectVersion + ")"
}()

/// `https://jyutping.app`
static let websiteAddress: String = "https://jyutping.app"

/// `https://jyutping.app`
static let websiteURL: URL = URL(string: websiteAddress)!

/// `https://apps.apple.com/hk/app/id1509367629`
static let appStoreAddress: String = "https://apps.apple.com/hk/app/id1509367629"
static let jyutping4MacAddress: String = "https://jyutping.app/mac"
static let privacyPolicyAddress: String = "https://jyutping.app/privacy"
static let faqAddress: String = "https://jyutping.app/faq"

/// Email Feedback
static let emailAddress: String = "[email protected]"
static let sourceCodeAddress: String = "https://github.com/yuetyam/jyutping"
static let appStoreAddress: String = "https://apps.apple.com/hk/app/id1509367629"
static let emailAddress: String = "[email protected]"
}

extension AppMaster {
Expand Down
8 changes: 4 additions & 4 deletions Jyutping/Jyutping/iOS/AboutView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,16 @@ struct AboutView: View {
SafariLink(AppMaster.websiteAddress) {
EnhancedLabel("Website", icon: "globe.asia.australia", symbol: .safari)
}
SafariLink("https://jyutping.app/mac") {
SafariLink(AppMaster.jyutping4MacAddress) {
EnhancedLabel("Jyutping for macOS", icon: "command.square", symbol: .safari)
}
SafariLink("https://github.com/yuetyam/jyutping") {
SafariLink(AppMaster.sourceCodeAddress) {
EnhancedLabel("Source Code", icon: "chevron.left.forwardslash.chevron.right", symbol: .safari)
}
SafariLink("https://jyutping.app/privacy") {
SafariLink(AppMaster.privacyPolicyAddress) {
EnhancedLabel("Privacy Policy", icon: "lock.circle", symbol: .safari)
}
SafariLink("https://jyutping.app/faq") {
SafariLink(AppMaster.faqAddress) {
EnhancedLabel("FAQ", icon: "questionmark.circle", symbol: .safari)
}
}
Expand Down
7 changes: 4 additions & 3 deletions Jyutping/Jyutping/macOS/MacAboutView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ struct MacAboutView: View {
}
.block()
VStack {
LinkLabel(icon: "globe.asia.australia", title: "Website", link: "https://jyutping.app")
LinkLabel(icon: "chevron.left.forwardslash.chevron.right", title: "Source Code", link: "https://github.com/yuetyam/jyutping")
LinkLabel(icon: "lock.circle", title: "Privacy Policy", link: "https://jyutping.app/privacy")
LinkLabel(icon: "globe.asia.australia", title: "Website", link: AppMaster.websiteAddress)
LinkLabel(icon: "chevron.left.forwardslash.chevron.right", title: "Source Code", link: AppMaster.sourceCodeAddress)
LinkLabel(icon: "lock.circle", title: "Privacy Policy", link: AppMaster.privacyPolicyAddress)
LinkLabel(icon: "questionmark.circle", title: "FAQ", link: AppMaster.faqAddress)
}
.block()
VStack {
Expand Down

0 comments on commit 7fcb1b8

Please sign in to comment.