jRumble with Twitter Bootstrap modal #5

Closed
michaeldv opened this Issue Mar 20, 2012 · 1 comment

Projects

None yet

2 participants

@michaeldv

Hi,

I've tried to rumble modal dialog from Twitter Bootstrap and the modal gets moved outside the browser window (all settings are default). The following changes seems to help with FF but not with Safari:

/========================================================/
/* Rumble Element
/========================================================/
var cx = parseInt($this.css('left')) + rx;
var cy = parseInt($this.css('top')) + ry;
$this.css({
'position':'absolute', // 'relative',
'left': cx + 'px', // 'left':rx+'px',
'top': cy + 'px', // 'top':ry+'px',
.
.
.
/========================================================/
/* Rumble CSS Reset
/========================================================/
var reset = {
// 'left':0,
// 'top':0,

Check it out when you have a chance.

Michael

@jackrugile
Owner

Hey, right now the best way to handle rumbling absolute and fixed position elements, which is what I assume the Bootstrap modal is, is to wrap the element you want to rumble. Then, set the positioning (absolute or fixed) on the wrapper, and apply the rumble to the static or relatively positioned inner item. This is something I eventually want to fix, but that is the best way for now. Is Bootstrap very flexible with adding wrappers to other elements, such as modals? I haven't used it much.

@jackrugile jackrugile closed this Jun 8, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment