Skip to content
This repository has been archived by the owner on Nov 26, 2020. It is now read-only.

Commit

Permalink
Removing extra spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
hebertialmeida committed Feb 21, 2019
1 parent b718f4f commit 499e3e0
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 22 deletions.
14 changes: 7 additions & 7 deletions Source/FolioReaderConfig.swift
Original file line number Diff line number Diff line change
Expand Up @@ -153,29 +153,29 @@ open class FolioReaderConfig: NSObject {
// MARK: Quote image share

/// Custom Quote logo
open var quoteCustomLogoImage = UIImage(readerImageNamed: "icon-logo")
open var quoteCustomLogoImage = UIImage(readerImageNamed: "icon-logo")

/// Add custom backgrounds and font colors to Quote Images
open var quoteCustomBackgrounds = [QuoteImage]()
open var quoteCustomBackgrounds = [QuoteImage]()

/// Enable or disable default Quote Image backgrounds
open var quotePreserveDefaultBackgrounds = true
open var quotePreserveDefaultBackgrounds = true

// MARK: Realm

/// Realm configuration for storing highlights
open var realmConfiguration = Realm.Configuration(schemaVersion: 2)
open var realmConfiguration = Realm.Configuration(schemaVersion: 2)

// MARK: Localized strings

/// Localizes Highlight title
open var localizedHighlightsTitle = NSLocalizedString("Highlights", comment: "")
open var localizedHighlightsTitle = NSLocalizedString("Highlights", comment: "")

/// Localizes Content title
open var localizedContentsTitle = NSLocalizedString("Contents", comment: "")
open var localizedContentsTitle = NSLocalizedString("Contents", comment: "")

/// Use the readers `UIMenuController` which enables the highlighting etc. The default is `true`. If set to false it's possible to modify the shared `UIMenuController` for yourself. Note: This doesn't disable the text selection in the web view.
open var useReaderMenuController = true
open var useReaderMenuController = true

/// Used to distinguish between multiple or different reader instances. The content of the user defaults (font settings etc.) depends on this identifier. The default is `nil`.
open var identifier: String?
Expand Down
30 changes: 15 additions & 15 deletions Source/Models/Highlight+Helper.swift
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ public enum HighlightStyle: Int {
*/
public static func styleForClass(_ className: String) -> HighlightStyle {
switch className {
case "highlight-yellow": return .yellow
case "highlight-green": return .green
case "highlight-blue": return .blue
case "highlight-pink": return .pink
case "highlight-yellow": return .yellow
case "highlight-green": return .green
case "highlight-blue": return .blue
case "highlight-pink": return .pink
case "highlight-underline": return .underline
default: return .yellow
default: return .yellow
}
}

Expand All @@ -45,11 +45,11 @@ public enum HighlightStyle: Int {

let enumStyle = (HighlightStyle(rawValue: style) ?? HighlightStyle())
switch enumStyle {
case .yellow: return "highlight-yellow"
case .green: return "highlight-green"
case .blue: return "highlight-blue"
case .pink: return "highlight-pink"
case .underline: return "highlight-underline"
case .yellow: return "highlight-yellow"
case .green: return "highlight-green"
case .blue: return "highlight-blue"
case .pink: return "highlight-pink"
case .underline: return "highlight-underline"
}
}

Expand All @@ -58,11 +58,11 @@ public enum HighlightStyle: Int {
/// - Returns: Tuple of all color compnonents.
private func colorComponents() -> (red: CGFloat, green: CGFloat, blue: CGFloat, alpha: CGFloat) {
switch self {
case .yellow: return (red: 255, green: 235, blue: 107, alpha: 0.9)
case .green: return (red: 192, green: 237, blue: 114, alpha: 0.9)
case .blue: return (red: 173, green: 216, blue: 255, alpha: 0.9)
case .pink: return (red: 255, green: 176, blue: 202, alpha: 0.9)
case .underline: return (red: 240, green: 40, blue: 20, alpha: 0.6)
case .yellow: return (red: 255, green: 235, blue: 107, alpha: 0.9)
case .green: return (red: 192, green: 237, blue: 114, alpha: 0.9)
case .blue: return (red: 173, green: 216, blue: 255, alpha: 0.9)
case .pink: return (red: 255, green: 176, blue: 202, alpha: 0.9)
case .underline: return (red: 240, green: 40, blue: 20, alpha: 0.6)
}
}

Expand Down
Binary file added docs/docsets/FolioReaderKit.tgz
Binary file not shown.
1 change: 1 addition & 0 deletions docs/docsets/FolioReaderKit.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<entry><version>1.4.0</version><url>https://folioReader.github.io/FolioReaderKit/docsets/FolioReaderKit.tgz</url></entry>

0 comments on commit 499e3e0

Please sign in to comment.