diff --git a/dist/iwmlib.pixi.js b/dist/iwmlib.pixi.js index c3997c7..7d9c091 100644 --- a/dist/iwmlib.pixi.js +++ b/dist/iwmlib.pixi.js @@ -3443,8 +3443,8 @@ if (this.__initHeight > this.opts.maxHeight) { // stack! const distanceToTop = this.container.y; - const distanceToBottom = this.opts.maxHeight - this.container.y - this.container.height; - + const distanceToBottom = this.opts.maxHeight - this.container.y - this.__initHeight; + if (distanceToTop > 0) { throwProps.y.end = 0; } else if (distanceToBottom > 0) { diff --git a/lib/pixi/buttongroup.js b/lib/pixi/buttongroup.js index 76ec22d..2eef1a8 100644 --- a/lib/pixi/buttongroup.js +++ b/lib/pixi/buttongroup.js @@ -505,8 +505,8 @@ export default class ButtonGroup extends PIXI.Container { if (this.__initHeight > this.opts.maxHeight) { // stack! const distanceToTop = this.container.y - const distanceToBottom = this.opts.maxHeight - this.container.y - this.container.height - + const distanceToBottom = this.opts.maxHeight - this.container.y - this.__initHeight + if (distanceToTop > 0) { throwProps.y.end = 0 } else if (distanceToBottom > 0) {