Closed brettfiedler closed 6 months ago
I am a little confused, I see that neither model and reference components are removed when a model component is deleted. This is taken while trying to save to a view component after I deleted nameResponse
(a reference component) in my test.
I expected nameResponse
to already be removed at this point.
Yes, there is definitely a related bug here. Steps:
1) Create a view component with a dependency on a model component. 2) Delete the model component. 3) Send to playground. 4) Note that the deleted model component will be referred to in the generated code for the view component.
When a dependency is deleted, it should auto-remove itself from components that depend on it.
This has been fixed for the view component, but several other components will have the same problem:
OK, this has been fixed for the various cases where this is possible.
Unit tests have been added to verify for each of the identified components above.
Merged into main. Closing.
https://github.com/phetsims/paper-land/assets/47331395/835cea58-b629-4f3a-8120-da086916bd34
Steps to reproduce:
toggle-button-responses.json