Skip to content

Breaking change on height(Upgrading from 3.5.1 to 3.6/3.7) #5270

Description

Image for: Description

Using .height() is rounding the value

  • What do you expect to happen?
    get the real height
  • What actually happens?
    the browser shows the real height but jquery get it rounded
  • Which browsers are affected? tested on
    chrome 114.0.5735.110
    opera 99.0.4788.65
    chromium:113.0.5672.127
    edge 114.0.1823.43
    firefox 103.0.2

Description

having rounded height produces misaligned objects

V3.5:

V3.6/V3.7:

Link to test case

Same code, just different versions of jquery
V3.7.0: https://jsfiddle.net/6jqh4pmb/1/ (fails)
V3.6.4: https://jsfiddle.net/6jqh4pmb/2/ (fails)
V3.5.1: https://jsfiddle.net/6jqh4pmb/3/ (This is working fine)

Metadata

Image for: Metadata

Metadata

Image for: Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

Image for: Issue actions