1
0
mirror of https://github.com/psychopy/psychojs.git synced 2025-05-12 08:38:10 +00:00

Merge pull request #378 from thewhodidthis/bf#318--textbox

visual/TextInput: use nullish coalescing operator for stroke styling fallbacks
This commit is contained in:
Alain Pitiot 2021-06-09 14:00:07 +02:00 committed by GitHub
commit bad98abde7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -831,9 +831,9 @@ function DefaultBoxGenerator(styles)
if (style.stroke)
{
box.lineStyle(
style.stroke.width || 1,
style.stroke.color || 0,
style.stroke.alpha || 1
style.stroke.width ?? 1,
style.stroke.color ?? 0,
style.stroke.alpha ?? 1
);
}