mirror of
https://github.com/clawdbot/clawdbot.git
synced 2026-02-01 03:47:45 +01:00
10 lines
316 B
Swift
10 lines
316 B
Swift
import Foundation
|
|
|
|
extension NSAttributedString {
|
|
func strippingForegroundColor() -> NSAttributedString {
|
|
let mutable = NSMutableAttributedString(attributedString: self)
|
|
mutable.removeAttribute(.foregroundColor, range: NSRange(location: 0, length: mutable.length))
|
|
return mutable
|
|
}
|
|
}
|