Sometimes you might not like where the menu appears. We give you the ability to give an offset to adjust the menu popup location.
Note that we try our best to place the menu directly below or above your share button. If the menu does not appear in the correct place, you may have HTML errors on your site. Most commonly, the problem lies with missing tags.
Please note that we do not support custom menu width and height using the API. If the menu is placed within a frame that is smaller than its minimum width or height, it will be partially obscured and appear to be "cut off". To resolve this issue, either increase the size of the frame or select a different location on the page for AddThis to appear. The compact menu is 234 pixels wide; a minimum of 240 available pixel width is recommended.
Optional Arguments
-
ui_offset_topOptional - Vertical offset for the drop-down window (in pixels)
-
ui_offset_leftOptional - Horizontal offset for the drop-down window (in pixels)
HTML Code
var addthis_config = {
ui_offset_top: 40,
ui_offset_left: 60
}
Example
Hover Delay
If you would like to delay the appearance of the compact menu when hovering over the button, you may.
-
ui_delayOptional - Delay in milliseconds (minimum 50, maximum 500)
var addthis_config = {
ui_delay: 200
}
Disable Hover
You can turn off the hovering behavior of the compact menu. However, be forewarned! Much sharing is impulse driven; sites that use the menu hover behavior tend to see 4x share increases.
-
ui_clickOptional -
If
true, the compact menu only appears on click.
var addthis_config = {
ui_click: true
}
API Reference
Check out the full AddThis Client API specification to learn more.