antiscroll icon indicating copy to clipboard operation
antiscroll copied to clipboard

Add a Minimum scroller height/width

Open Radagaisus opened this issue 12 years ago • 3 comments

See this screenshot. That tiny little black thing at the right side is antiscroll.

A simple fix is to add a minimal height, and adjust the top position based on it:

//  Scrollbar.Vertical.prototype.update

height = trackHeight * paneHeight / innerEl.scrollHeight
top = trackHeight * innerEl.scrollTop / innerEl.scrollHeight

if height < 30
  top = top - (30 - height)
  height = 30

this.el
      .css('height', height)
      .css('top', top)

Minimum height should probably be an option, as well.

Radagaisus avatar Oct 16 '12 23:10 Radagaisus

Please, do the fix on a branch of yours and do a pull request or post a diff.

arlm avatar Oct 29 '12 12:10 arlm

@arlm it's on my task list :)

Radagaisus avatar Oct 29 '12 12:10 Radagaisus

I have merged a lot of code into my antiscroll fork and it contemplates a portion of code to set the minimum size to 20. Take a look on it and when my pull request is accepted/merged we can close this issue, IMHO.

arlm avatar Oct 29 '12 15:10 arlm