TextCard
class TextCard : Card
This is a concrete card class that can display a title and body text.
-
The title of the card to be displayed in the card’s view.
Declaration
Swift
var title: String? { get set }
-
The color with which the title will be displayed.
Note
Defaults to [UIColor whiteColor].Declaration
Swift
var titleColor: UIColor? { get set }
-
The font with which the title will be displayed.
Note
Defaults to medium weight system font, 17pt.Declaration
Swift
var titleFont: UIFont? { get set }
-
The body of the card to be displayed in the card’s view.
Declaration
Swift
var body: String? { get set }
-
The color with which the body will be displayed.
Note
Defaults to [UIColor whiteColor].Declaration
Swift
var bodyColor: UIColor? { get set }
-
The font with which the body will be displayed.
Note
Defaults to regular weight system font, 14pt.Declaration
Swift
var bodyFont: UIFont? { get set }
-
The background color of the card view.
Note
Defaults to #0cac56.Declaration
Swift
var backgroundColor: UIColor? { get set }
-
Creates a new text card.
Declaration
Swift
init(callToAction cardCTA: CardCallToAction, title: String?, body: String?)
Parameters
cardCTA
The call to action object to be displayed when the card is “active”.
title
The title of the card.
body
The body text of the card.
Return Value
Returns an instance of a card with the title, bodyText, and cardCTA.