phetsims / beers-law-lab

"Beer's Law Lab" is an educational simulation in HTML5, by PhET Interactive Simulations.
http://phet.colorado.edu/en/simulation/beers-law-lab
GNU General Public License v3.0
2 stars 9 forks source link

Size of "Evaporation" much smaller than in published #318

Closed Nancy-Salpepi closed 1 year ago

Nancy-Salpepi commented 1 year ago

Test device MacBook Air (m1 chip)

Operating System 13.1

Browser Safari 16.2

Problem description For https://github.com/phetsims/qa/issues/889, the size of the word "Evaporation" is much smaller in this version than in the Published. In Published, the words "Evaporation" and "Solute" are the same size.

From @arouinfar on Slack:

Looks like an unintended consequence of dynamic layout. My guess is that “Evaporation” doesn’t have an appropriate maxWidth and it is automatically shrinking to fit in the panel. I don’t see why we would intentionally make the text smaller than the published version.

Visuals

Screenshot 2023-01-31 at 4 05 01 PM
Troubleshooting information: !!!!! DO NOT EDIT !!!!! Name: ‪Laboratoire Loi de Beer-Lambert‬ URL: https://phet-dev.colorado.edu/html/beers-law-lab/1.7.0-dev.8/phet/beers-law-lab_all_phet.html Version: 1.7.0-dev.8 2023-01-27 19:51:37 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/109.0.0.0 Safari/537.36 Language: en-US Window: 1536x781 Pixel Ratio: 1.7999999523162842/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: {}
samreid commented 1 year ago

@pixelzoom would you like to investigate this?

pixelzoom commented 1 year ago

Fixed in the above commit. Screenshots below for normal and stringTest=double. @Nancy-Salpepi please review in master, close if OK.

screenshot_2224 screenshot_2225
samreid commented 1 year ago

I noticed there is still a

console.log( `labelText.width=${labelText.width}` );
pixelzoom commented 1 year ago

Thanks. console.log removed.

Nancy-Salpepi commented 1 year ago

Looks good. Thanks! Closing.

pixelzoom commented 1 year ago

Reopening to confirm in https://github.com/phetsims/qa/issues/894. It looks like changes I made during dev testing did not get into the 1.7 release branch.

@samreid @matthew-blackman FYI.

pixelzoom commented 1 year ago

Still fixed in 1.7. Closing.