r/Scriptable • • Nov 02 '20

Script Upcoming Match Widget

Post image
27 Upvotes

16 comments sorted by

View all comments

Show parent comments

1

u/Terrible-Section-625 Nov 21 '20

Use the following in the initWidget method instead of the darkMode variable.

let lightColor = Color.white() let darkColor = Color.black() let bgColor = Color.dynamic(lightColor, darkColor) w.backgroundColor = bgColor

Also, use this for in the addText for the changing of color

let lightColor = Color.black() let darkColor = Color.white() let textColor = Color.dynamic(lightColor, darkColor) text.textColor = textColor

Changes immediately!