Changes between Version 1 and Version 2 of Ticket #26609, comment 4
- Timestamp:
- 12/14/2013 07:13:04 AM (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #26609, comment 4
v1 v2 7 7 Many major front-end frameworks and boilerplates use positioning overrides ( e.g. `position:relative` ) on the `html` and/or `body` elements as routine corrective/normalization practice - so when the admin bar changes from `fixed` to `absolute` positioning, it does '''not''' snap to the top of the ''window'' as expected, but to the top of the `body` element, which has been shifted 46px from the top of the window due to the top margin. 8 8 9 Considering how commonplace explicit `body` element positioning is as a routine normalization practice , I would say that this constitutes a serious problem/oversight.9 Considering how commonplace explicit `body` element positioning is as a routine normalization practice (particularly when off-canvas layouts are to be employed), I would say that this constitutes a serious problem/oversight. 10 10 11 To fix this, the top margin for `html` should be set to `0` at `max-width:600px` to ensure there are no conflicts. 11 There are a number of potential fixes, but this should be remedied in core. 12 13 When the screen is `max-width:600px`, the `html` and `body` should be explicitly set to `position: relative` (which is more common than not, anyway). The admin bar should then be positioned `top:-46px` to compensate. Problem solved.