Closed samreid closed 3 years ago
@samreid Please clarify. Do you have a use case where you want to be able to set stroke: null
? Or is it sufficient to add an assertion that requires stroke
to be non-null?
I don't have a use case that requires a null
-stroked Accordion box. But the options look like so:
// box
stroke: 'black',
and there is no indication that null is disallowed. I don't have a preference about whether we add support for null
or add an assertion that it is non-null.
Fixed in the above commit, AccordionBox now supported stroke: null
.
this.expandedBoxOutline
and this.collapsedBoxOutline
are created conditionally, if options.stroke
is truthy. So in layout
, they should be updated only if they exist.
@samreid please review.
I reviewed the commit and tested with null in build an atom, everything seems nice! Closing.
Discovered during https://github.com/phetsims/sun/issues/676, if you pass
stroke: null
to AccordionBox, you get this error:Assigning to @jbphet and @pixelzoom who are listed as authors in AccordionBox.