mirror of
https://github.com/nimbold/Firelink.git
synced 2026-08-28 11:37:17 +00:00
feat(ui): add Deno to about credits and engines list
This commit is contained in:
@@ -11,11 +11,13 @@ enum AddonState: Equatable, Sendable {
|
|||||||
enum AddonType: String, CaseIterable, Sendable {
|
enum AddonType: String, CaseIterable, Sendable {
|
||||||
case ytDlp = "yt-dlp"
|
case ytDlp = "yt-dlp"
|
||||||
case ffmpeg
|
case ffmpeg
|
||||||
|
case deno
|
||||||
|
|
||||||
var binaryName: String {
|
var binaryName: String {
|
||||||
switch self {
|
switch self {
|
||||||
case .ytDlp: return "yt-dlp"
|
case .ytDlp: return "yt-dlp"
|
||||||
case .ffmpeg: return "ffmpeg"
|
case .ffmpeg: return "ffmpeg"
|
||||||
|
case .deno: return "deno"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -26,6 +28,7 @@ final class MediaEngineManager: ObservableObject {
|
|||||||
|
|
||||||
@Published var ytDlpState: AddonState = .notInstalled
|
@Published var ytDlpState: AddonState = .notInstalled
|
||||||
@Published var ffmpegState: AddonState = .notInstalled
|
@Published var ffmpegState: AddonState = .notInstalled
|
||||||
|
@Published var denoState: AddonState = .notInstalled
|
||||||
private var ytDlpPreparationTask: Task<URL?, Never>?
|
private var ytDlpPreparationTask: Task<URL?, Never>?
|
||||||
|
|
||||||
private init() {
|
private init() {
|
||||||
@@ -246,6 +249,7 @@ final class MediaEngineManager: ObservableObject {
|
|||||||
switch addon {
|
switch addon {
|
||||||
case .ytDlp: return ytDlpState
|
case .ytDlp: return ytDlpState
|
||||||
case .ffmpeg: return ffmpegState
|
case .ffmpeg: return ffmpegState
|
||||||
|
case .deno: return denoState
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -253,6 +257,7 @@ final class MediaEngineManager: ObservableObject {
|
|||||||
switch addon {
|
switch addon {
|
||||||
case .ytDlp: ytDlpState = state
|
case .ytDlp: ytDlpState = state
|
||||||
case .ffmpeg: ffmpegState = state
|
case .ffmpeg: ffmpegState = state
|
||||||
|
case .deno: denoState = state
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ struct AboutSettingsPane: View {
|
|||||||
private let aria2URL = URL(string: "https://aria2.github.io/")!
|
private let aria2URL = URL(string: "https://aria2.github.io/")!
|
||||||
private let ytDlpURL = URL(string: "https://github.com/yt-dlp/yt-dlp")!
|
private let ytDlpURL = URL(string: "https://github.com/yt-dlp/yt-dlp")!
|
||||||
private let ffmpegURL = URL(string: "https://ffmpeg.org/")!
|
private let ffmpegURL = URL(string: "https://ffmpeg.org/")!
|
||||||
|
private let denoURL = URL(string: "https://deno.com/")!
|
||||||
private let licenseURL = URL(string: "https://github.com/nimbold/Firelink/blob/main/LICENSE")!
|
private let licenseURL = URL(string: "https://github.com/nimbold/Firelink/blob/main/LICENSE")!
|
||||||
|
|
||||||
private var appVersion: String {
|
private var appVersion: String {
|
||||||
@@ -80,6 +81,8 @@ struct AboutSettingsPane: View {
|
|||||||
Link("yt-dlp", destination: ytDlpURL)
|
Link("yt-dlp", destination: ytDlpURL)
|
||||||
Text("•").foregroundStyle(.secondary)
|
Text("•").foregroundStyle(.secondary)
|
||||||
Link("ffmpeg", destination: ffmpegURL)
|
Link("ffmpeg", destination: ffmpegURL)
|
||||||
|
Text("•").foregroundStyle(.secondary)
|
||||||
|
Link("Deno", destination: denoURL)
|
||||||
}
|
}
|
||||||
Spacer()
|
Spacer()
|
||||||
Link("MIT License", destination: licenseURL)
|
Link("MIT License", destination: licenseURL)
|
||||||
|
|||||||
@@ -46,6 +46,8 @@ struct EngineSettingsPane: View {
|
|||||||
|
|
||||||
addonStatusRow(title: "FFmpeg", state: engineManager.ffmpegState, path: engineManager.binaryPath(for: .ffmpeg))
|
addonStatusRow(title: "FFmpeg", state: engineManager.ffmpegState, path: engineManager.binaryPath(for: .ffmpeg))
|
||||||
|
|
||||||
|
addonStatusRow(title: "Deno", state: engineManager.denoState, path: engineManager.binaryPath(for: .deno))
|
||||||
|
|
||||||
LabeledContent("Browser Cookies") {
|
LabeledContent("Browser Cookies") {
|
||||||
HStack {
|
HStack {
|
||||||
Spacer()
|
Spacer()
|
||||||
|
|||||||
Reference in New Issue
Block a user