The plugins site is currently in development.
We've been looking to provide a higher-quality, spam-free experience at the plugins site for some time, and a major error on our part forced us to shut down the current site before we could put the new one in place. We are developing a new site, and you can follow along with its development on GitHub. For more information about this transition, including steps you can take as a plugin author to prepare, please read our post about what's going on.
Fix for dimensions.js incompatibility
| Project: | BeautyTips |
| Version: | 0.9.1 |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Originally posted at http://www.lullabot.com/articles/announcing-beautytips-jquery-tooltip-pl...
I'm moving it over here for easier issue management:
---------------------------
Hi guys!
I have fixed the compatibility issue with the jquery.dimensions.js plug-in (the ONE edge of the tooltip always gets cutoff).
If you have this problem, you can apply the following to fix it:
1) Add the "btOuterWidth" function to the jquery.bt.js:
/**
* jQuery's dimensions.js overrides the $().btOuterWidth() function
* this is a copy of original jQuery's outerWidth() function to allow the plugin to work when dimensions.js is present
*/
jQuery.fn.btOuterWidth = function(margin) {
function num(elem, prop) {
return elem[0] && parseInt(jQuery.curCSS(elem[0], prop, true), 10) || 0;
};
return this["innerWidth"]()
+ num(this, "borderLeftWidth")
+ num(this, "borderRightWidth")
+ (margin ? num(this, "marginLeft")
+ num(this, "marginRight") : 0);
}; // </ jQuery.fn.btOuterWidth() >
2) In the jquery.bt.js, replace all calls of the "outerWidth" function to the "btOuterWidth" function
- Login to post comments
