Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 0 additions & 79 deletions apple/TablePro/Core/Menu/AboutPanelCredits.swift

This file was deleted.

32 changes: 32 additions & 0 deletions apple/TablePro/Core/Menu/AppDelegate+MainMenuActions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -156,3 +156,35 @@ enum MainMenuLink {
static let repository = "https://github.com/TableProApp/TablePro"
static let issues = "https://github.com/TableProApp/TablePro/issues"
}

/// The About panel's credits line, kept out of the delegate so the menu action stays
/// a single call.
enum AboutPanelCredits {
static func attributedString() -> NSAttributedString {
let style: [NSAttributedString.Key: Any] = [
.font: NSFont.systemFont(ofSize: 11),
.foregroundColor: NSColor.secondaryLabelColor
]
let credits = NSMutableAttributedString()
let links: [(String, String)] = [
("Website", MainMenuLink.website),
("GitHub", MainMenuLink.repository),
(String(localized: "Documentation"), MainMenuLink.documentation),
(String(localized: "Sponsor"), SupportLinks.sponsors(.aboutPanel).absoluteString)
]
for (index, link) in links.enumerated() {
if index > 0 {
credits.append(NSAttributedString(string: " | ", attributes: style))
}
let attributed = NSMutableAttributedString(string: link.0, attributes: style)
if let url = URL(string: link.1) {
attributed.addAttribute(.link, value: url, range: NSRange(location: 0, length: attributed.length))
}
credits.append(attributed)
}
let centered = NSMutableParagraphStyle()
centered.alignment = .center
credits.addAttribute(.paragraphStyle, value: centered, range: NSRange(location: 0, length: credits.length))
return credits
}
}
40 changes: 0 additions & 40 deletions apple/TablePro/Resources/Localizable.xcstrings
Original file line number Diff line number Diff line change
Expand Up @@ -182092,46 +182092,6 @@
}
}
},
"Thanks to these license holders" : {
"localizations" : {
"fr" : {
"stringUnit" : {
"state" : "translated",
"value" : "Merci à ces détenteurs de licence"
}
},
"ko" : {
"stringUnit" : {
"state" : "translated",
"value" : "라이선스를 구매해 주신 분들께 감사드립니다"
}
},
"tr" : {
"stringUnit" : {
"state" : "translated",
"value" : "Bu lisans sahiplerine teşekkürler"
}
},
"vi" : {
"stringUnit" : {
"state" : "translated",
"value" : "Cảm ơn những người đã mua giấy phép"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "感谢这些许可证持有者"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "感謝這些授權持有者"
}
}
}
},
"Thanks. Your license is what pays for the next release." : {
"localizations" : {
"fr" : {
Expand Down
3 changes: 0 additions & 3 deletions apple/TablePro/Resources/Supporters.json

This file was deleted.

44 changes: 0 additions & 44 deletions apple/TableProTests/Core/Menu/AboutPanelCreditsTests.swift

This file was deleted.

1 change: 0 additions & 1 deletion apple/changelog.d/3923.added.md

This file was deleted.

Loading