64 lines
1.8 KiB
Swift
64 lines
1.8 KiB
Swift
|
|
enum PageIcon: String, CaseIterable {
|
|
|
|
// MARK: Statistics
|
|
|
|
case statisticsTime = "time"
|
|
|
|
case statisticsElevationUp = "elevation-up"
|
|
|
|
case statisticsElevationDown = "elevation-down"
|
|
|
|
case statisticsDistance = "distance"
|
|
|
|
case statisticsEnergy = "energy"
|
|
|
|
// MARK: Buttons
|
|
|
|
case buttonDownload = "download"
|
|
|
|
case buttonExternalLink = "external"
|
|
|
|
case buttonGitLink = "git"
|
|
|
|
case buttonPlay = "play-circle"
|
|
|
|
// MARK: Audio player
|
|
|
|
case audioPlayerPlaylist = "playlist"
|
|
|
|
case audioPlayerClose = "close"
|
|
|
|
case audioPlayerPlay = "play"
|
|
|
|
case audioPlayerPause = "pause"
|
|
|
|
case audioPlayerPrevious = "previous"
|
|
|
|
case audioPlayerNext = "next"
|
|
|
|
var icon: ContentIcon.Type {
|
|
switch self {
|
|
case .statisticsTime: return StatisticsTimeIcon.self
|
|
case .statisticsElevationUp: return StatisticsElevationUpIcon.self
|
|
case .statisticsElevationDown: return StatisticsElevationDownIcon.self
|
|
case .statisticsDistance: return StatisticsDistanceIcon.self
|
|
case .statisticsEnergy: return StatisticsEnergyIcon.self
|
|
case .buttonDownload: return ButtonDownloadIcon.self
|
|
case .buttonExternalLink: return ButtonExternalIcon.self
|
|
case .buttonGitLink: return ButtonGitIcon.self
|
|
case .buttonPlay: return ButtonPlayIcon.self
|
|
case .audioPlayerPlaylist: return AudioPlayerPlaylistIcon.self
|
|
case .audioPlayerClose: return AudioPlayerCloseIcon.self
|
|
case .audioPlayerPlay: return AudioPlayerPlayIcon.self
|
|
case .audioPlayerPause: return AudioPlayerPauseIcon.self
|
|
case .audioPlayerPrevious: return AudioPlayerPreviousIcon.self
|
|
case .audioPlayerNext: return AudioPlayerNextIcon.self
|
|
}
|
|
}
|
|
}
|
|
|
|
extension PageIcon: Hashable {
|
|
|
|
}
|