-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
164 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,19 @@ | ||
import Foundation | ||
|
||
enum LyricsError: Error { | ||
enum LyricsError: Error, CustomStringConvertible { | ||
case NoCurrentTrack | ||
case MusixmatchRestricted | ||
case InvalidMusixmatchToken | ||
case DecodingError | ||
case NoSuchSong | ||
|
||
var description: String { | ||
switch self { | ||
case .NoSuchSong: "No Song Found" | ||
case .MusixmatchRestricted: "Restricted" | ||
case .InvalidMusixmatchToken: "Unauthorized" | ||
case .DecodingError: "Decoding Error" | ||
case .NoCurrentTrack: "No Track Instance" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
Sources/EeveeSpotify/Models/Headers/SPTEncoreAttributedString.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import Foundation | ||
|
||
@objc protocol SPTEncoreAttributedString { | ||
func initWithString(_ string: String, typeStyle: Any, attributes: Any) -> SPTEncoreAttributedString | ||
func text() -> String | ||
func typeStyle() -> Any | ||
func attributes() -> SPTEncoreAttributes | ||
} |
7 changes: 7 additions & 0 deletions
7
Sources/EeveeSpotify/Models/Headers/SPTEncoreAttributes.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import UIKit | ||
|
||
@objc protocol SPTEncoreAttributes { | ||
func `init`(_: (SPTEncoreAttributes) -> Void) -> SPTEncoreAttributes | ||
func foregroundColor() -> UIColor | ||
func setForegroundColor(_ color: UIColor) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import Foundation | ||
|
||
@objc protocol SPTEncoreLabel { | ||
func text() -> NSArray | ||
func setText(_ text: NSArray) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,4 +9,4 @@ import Foundation | |
@objc enum ClickState: Int { | ||
case primary | ||
case secondary | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters