Skip to content

Commit

Permalink
fix: Add truthy check in case user sets a null value for a reason
Browse files Browse the repository at this point in the history
  • Loading branch information
CatchABus committed Dec 10, 2024
1 parent 90f7fb1 commit 73330e7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ export class Input extends Container
this.options.TextClass = options.TextClass ?? Text;

const textStyle = { ...defaultTextStyle, ...options.textStyle };
const colorSource = Color.isColorLike(textStyle.fill)
const colorSource = textStyle.fill && Color.isColorLike(textStyle.fill)
? textStyle.fill
: 0x000000;

Expand Down

0 comments on commit 73330e7

Please sign in to comment.