BPKText
public struct BPKText : View
A view that displays one or more lines of text
By default the color of BPKText is set to BPKColor.textPrimary with a lineLimit of 1
Use foregroundColor(_ color: BPKColor) to change the color of the text
Use limeLimit(_ number: Int?) to set the number of lines can be displayed. Pass in nil for unlimited lines
-
Declaration
Swift
public init(_ text: String, style: BPKFontStyle = .bodyDefault) -
Declaration
Swift
public var body: some View { get } -
Sets the maximum number of lines that text can occupy in the BPKText.
Declaration
Swift
public func lineLimit(_ number: Int?) -> BPKTextParameters
numberThe line limit. If
nil, no line limit applies.Return Value
A BPKText that limits the number of lines that this
BPKTextinstance displays. -
Sets the strikethrough of the text.
Declaration
Swift
public func strikethrough(_ active: Bool) -> BPKTextParameters
activeWhen true a line will be added in the middle of the text.
Return Value
A BPKText that has a line through the text if active is true.
-
Declaration
Swift
init(_ text: Text, style: BPKFontStyle = .bodyDefault)