jcubic / jcubic/jquery.splitter
jQuery .height() and .width() don't include padding and border
- Dominant language
- JavaScript
- Stars
- 243
- Forks
- 96
- PR merge metrics
- No merged PRs in 30d
Description
jQuery `.height()` and `.width()` are not equivalent to `offsetHeight` and `offsetWidth` since they don't include padding and border.
If we want to override the default splitter style with padding and border, the calculated height and width will be incorrect.
You can replace `splitter.width()` and `splitter.height()` with `splitter.get(0).offsetWidth` and `splitter.get(0).offsetHeight`, respectively, to overcome this issue.
Contributor guide
No contributing guide indexed for this repository
Research direction
Search the plugin source for the splitter.width() and splitter.height() calls and inspect how those dimensions are used when padding or borders are present. Replace the measurements with the corresponding offset dimensions, then verify that splitter sizing remains correct with padded and bordered styles.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, jquery
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 50/100