phetsims / greenhouse-effect

"Greenhouse Effect" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
4 stars 4 forks source link

Interactive highlight for Ice Age button needs to expand dynamically #349

Closed Nancy-Salpepi closed 3 months ago

Nancy-Salpepi commented 10 months ago

Test device MacBook Air M1 chip

Operating System 13.5

Browser Safari 16.6

Problem description For https://github.com/phetsims/qa/issues/970, the interactive highlight for the Ice Age button doesn't expand when I change locale.

Steps to reproduce

  1. Add ?stringTest=dynamic to end of url
  2. Turn on Interactive Highlights in the Preferences Menu
  3. On either the Waves or Photons screen, select the byDateRadioButton
  4. Press the right arrow key to expand the text
  5. Mouse over the iceAgeRadioButton --This is also seen using keyboard nav

Visuals In Greek:

Screenshot 2023-08-15 at 8 12 20 AM
Troubleshooting information: !!!!! DO NOT EDIT !!!!! Name: ‪Greenhouse Effect‬ URL: https://phet-dev.colorado.edu/html/greenhouse-effect/1.2.0-dev.2/phet/greenhouse-effect_all_phet.html Version: 1.2.0-dev.2 2023-08-10 04:15:01 UTC Features missing: applicationcache, applicationcache, touch Flags: pixelRatioScaling User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36 Language: en-US Window: 1407x729 Pixel Ratio: 2/1 WebGL: WebGL 1.0 (OpenGL ES 2.0 Chromium) GLSL: WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium) Vendor: WebKit (WebKit WebGL) Vertex: attribs: 16 varying: 31 uniform: 1024 Texture: size: 16384 imageUnits: 16 (vertex: 16, combined: 32) Max viewport: 16384x16384 OES_texture_float: true Dependencies JSON: {}
jbphet commented 10 months ago

This is bringing two problems with our code to light, both in the common code.

The first is that interactive highlights don't resize with dynamic layout changes. I'm going to assign this to @jessegreenberg and @jonathanolson for their take on this. It may be a known problem or something new, but they can let us know.

The second is that rectangular radio button groups are not getting resized correctly when the size of individual buttons change, which they should. I'll assign this to @marlitas and @jonathanolson to get their input on this portion.

jbphet commented 10 months ago

For the record, here is an example of it happening in a more "real" case, which is when switching from English to Arabic.

image

jbphet commented 10 months ago

@arouinfar - This is a bit of an edge case and will involve changes to common code to fix. I would consider it non-blocking for the release. What's your take?

jessegreenberg commented 10 months ago

I opened the above issue for the highlights and pushed a potential fix which is ready for review.

arouinfar commented 10 months ago

This is a bit of an edge case and will involve changes to common code to fix. I would consider it non-blocking for the release. What's your take?

I wouldn't consider this blocking either, but looks like we won't have to make that call. Thanks @jessegreenberg!

jbphet commented 10 months ago

The fix that @jessegreenberg committed is an improvement, but doesn't quite fully resolve the problem, see https://github.com/phetsims/sun/issues/851#issuecomment-1686858287. I've created another issue for working on the dynamic layout, see https://github.com/phetsims/sun/issues/852.

marlitas commented 10 months ago

I commented in https://github.com/phetsims/sun/issues/852. I will continue to take a look in there. Just want to confirm that this is not blocking greenhouse.

Unassigning.

Nancy-Salpepi commented 5 months ago

Noting that this issue is still present in https://github.com/phetsims/qa/issues/1033

arouinfar commented 5 months ago

Thanks for reporting @Nancy-Salpepi. @jbphet this issue does not block Greenhouse interviews, but it would be nice to address before publishing the next version.

jonathanolson commented 3 months ago

I believe this should be working based on recent commits (including one above), can you verify?

Nancy-Salpepi commented 3 months ago

This is working nicely on main JO!

jonathanolson commented 3 months ago

Thanks, closing!