mBox.Tooltip.js 714 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*
  2. ---
  3. description: The mBox.Tooltip class extends mBox.Core, helping you to attach tooltips to any DOM element.
  4. authors: Stephan Wagner
  5. license: MIT-style
  6. requires:
  7. - mBox
  8. - core/1.4.5: '*'
  9. - more/Element.Measure
  10. provides: [mBox.Tooltip]
  11. documentation: http://htmltweaks.com/mBox/Documentation/Tooltip
  12. ...
  13. */
  14. mBox.Tooltip = new Class({
  15. Extends: mBox,
  16. options: {
  17. target: null,
  18. event: 'mouseenter',
  19. position: {
  20. x: ['center'],
  21. y: ['top', 'outside']
  22. },
  23. pointer: 'center',
  24. fixed: false,
  25. delayOpenOnce: true
  26. },
  27. // initialize parent
  28. initialize: function(options) {
  29. this.defaultInOut = 'outside';
  30. this.defaultTheme = 'Tooltip';
  31. this.parent(options);
  32. }
  33. });