MTColorValue

public struct MTColorValue : Codable, Sendable

Encodes a color to a hex string when converted to JSON. Accepts either a hex color string (e.g. “#RRGGBB”) or a UIColor.

  • raw

    Undocumented

    Declaration

    Swift

    public let raw: String
  • Undocumented

    Declaration

    Swift

    public init(_ hexColor: String)
  • Undocumented

    Declaration

    Swift

    public init(_ color: UIColor)
  • Declaration

    Swift

    public init(from decoder: any Decoder) throws
  • Declaration

    Swift

    public func encode(to encoder: any Encoder) throws