Skip to content

Commit 9da90a8

Browse files
committed
Update Color.swift
1 parent 7cc3635 commit 9da90a8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Sources/GameMath/Color.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,9 @@ extension Color: _ExpressibleByColorLiteral {
248248
}
249249

250250
public extension Color {
251-
static let clear: Color = #colorLiteral(red: 0.0, green: 0.0, blue: 0.0, alpha: 0.0)
251+
static var clear: Color { .transparentBlack }
252+
static let transparentWhite: Color = Color(1, 1, 1, 0)
253+
static let transparentBlack: Color = Color(0, 0, 0, 0)
252254

253255
static let white: Color = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0)
254256
static let lightGray: Color = #colorLiteral(red: 0.75, green: 0.75, blue: 0.75, alpha: 1)

0 commit comments

Comments
 (0)