Closed Nancy-Salpepi closed 1 year ago
I noticed that if I follow the same steps as above, but with the ammeter (view.sensorToolbox.ammeterToolNode.visibleProperty
) and voltmeter (view.sensorToolbox.voltmeterNodeIcon.visibleProperty
) the visibleProperty stays false after launching.
When I return the meters to the panel, they disappear.
I tested all the functionality described above and it now seems to be working properly (transmitted to preview sim correctly). But I observed the following issues:
ammeterToolNode
and voltmeterNodeIcon
have inconsistent names.Those labels cannot be hidden but they can get their strings set to the empty string:
I improved the tandem name for the voltmeter so it is consistent with the rest of the sim.
The labels were supposed to auto-hide when you hide a voltmeter or ammeter tool node, I corrected that in the commit. I also added a TODO since I was surprised to see 2 levels in that hierarchy (last 2 in this list):
Anyways, I don't think I should work on that tree much more until checking in about the design of that part. Do we still need ammeterToolIconWithLabel
? Should seriesAmmeterNodeIcon
be nested under seriesAmmeterToolNode
? Should the labels be top-level in sensorToolbox, and auto-hide?
I'll review this with @matthew-blackman in #917
@matthew-blackman and I verified that the labels in the sensor toolbox disappear when hiding the corresponding ToolNode. The "Ammeters" text will disappear if both seriesAmmeterToolNode
and ammeterToolNode
are hidden. This all looks good.
@samreid There isn't a reason to keep the *IconWithLabel
. Can you remove those?
I removed the iconWithLabel and regenerated APIs. Tested in Studio. Closing.
Test device Dell
Operating System Win10
Browser Chrome
Problem description For https://github.com/phetsims/qa/issues/774:
In Studio, when a circuit element that there is multiple of, such as a battery, is placed in the play area and then its visible property is set to false (view.circuitElementToolbox.circuitElementTools.rightBatteryToolNode.visibleProperty), it's value will be true when the sim is launched. If that item was not in the play area, its value stays false.
This seems like a bug to me, but I first wanted to make sure that this was not by design.
Steps to reproduce
Visuals
https://user-images.githubusercontent.com/87318828/154090172-5b14ec67-e89a-460f-97e2-bf3c295a6edc.mp4