public void ShouldReturnNameWhenConvertedToString() { NamedColor color = new NamedColor("name", Colors.AliceBlue); Assert.AreEqual <string>("name", color.ToString()); }
/// <summary> /// Sets the background color of the element to the given colour. /// </summary> public IComponentFeatures Background(NamedColor color) { this.AddPendingClass($"bg-{color.ToString().Hyphenate().ToLower()}"); return(this); }
/// <summary> /// Sets the text colour to the given colour. /// </summary> public IComponentFeatures Text(NamedColor color) { this.AddPendingClass($"text-{color.ToString().Hyphenate().ToLower()}"); return(this); }
public Color(NamedColor color) : this(color.ToString(format : "G")) { }