Skip to content

Commit

Permalink
fix: macOS build.
Browse files Browse the repository at this point in the history
  • Loading branch information
laosb committed Feb 20, 2024
1 parent 8f234b7 commit a098c5e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/EasyRichText/Models/ERTColor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public extension ERTDefinedColor {
return uiColor.resolvedColor(with: .init()).cgColor
#elseif canImport(AppKit)
let nsColor = NSColor(color)
return nsColor.resolvedColor(with: .init()).cgColor
return nsColor.cgColor
#endif
}

Expand Down
1 change: 1 addition & 0 deletions Sources/EasyRichTextUI/ERTTextEditor_AppKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#if canImport(AppKit)
import SwiftUI
import AppKit
import EasyRichText

struct ERTTextEditor<RichText: ERTRichText>: NSViewRepresentable {
@ObservedObject var editContext: ERTRichTextEditContext<RichText>
Expand Down
1 change: 1 addition & 0 deletions Sources/EasyRichTextUI/ERTTextViewDelegate_AppKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#if canImport(AppKit)

import AppKit
import EasyRichText

public class ERTTextViewDelegate<RichText: ERTRichText>: NSObject, NSTextViewDelegate {
var context: ERTRichTextEditContext<RichText>
Expand Down

0 comments on commit a098c5e

Please sign in to comment.