Generated wrapper for the Web Awesome wa-popup component.
Generated from Web Awesome metadata.
Usage
wa_popup(
...,
id = NULL,
class = NULL,
style = NULL,
active = NULL,
anchor = NULL,
arrow = NULL,
arrow_padding = NULL,
arrow_placement = NULL,
auto_size = NULL,
auto_size_padding = NULL,
auto_size_boundary = NULL,
boundary = NULL,
dir = NULL,
distance = NULL,
flip = NULL,
flip_fallback_placements = NULL,
flip_fallback_strategy = NULL,
flip_padding = NULL,
flip_boundary = NULL,
hover_bridge = NULL,
lang = NULL,
placement = NULL,
shift = NULL,
shift_padding = NULL,
shift_boundary = NULL,
skidding = NULL,
sync = NULL,
anchor_slot = NULL
)Arguments
- ...
Child content for the component's default slot.
- id
Optional DOM id attribute for HTML, CSS, and JS targeting.
- class
Optional CSS class string.
- style
Optional inline CSS style string.
- active
Boolean. Default:
FALSE. Activates the positioning logic and shows the popup. When this attribute is removed, the positioning logic is torn down and the popup will be hidden.- anchor
The element the popup will be anchored to. If the anchor lives outside of the popup, you can provide the anchor element
id, a DOM element reference, or aVirtualElement. If the anchor lives inside the popup, use theanchorslot instead.- arrow
Boolean. Default:
FALSE. Attaches an arrow to the popup. The arrow's size and color can be customized using the--arrow-sizeand--arrow-colorcustom properties. For additional customizations, you can also target the arrow using::part(arrow)in your stylesheet.- arrow_padding
Number. Default:
10. The amount of padding between the arrow and the edges of the popup. If the popup has a border-radius, for example, this will prevent it from overflowing the corners.- arrow_placement
Enumerated string. Allowed values:
anchor,center,end,start. Default:anchor. The placement of the arrow. The default isanchor, which will align the arrow as close to the center of the anchor as possible, considering available space andarrow-padding. A value ofstart,end, orcenterwill align the arrow to the start, end, or center of the popover instead.- auto_size
Enumerated string. Allowed values:
both,horizontal,vertical. When set, this will cause the popup to automatically resize itself to prevent it from overflowing.- auto_size_padding
Number. Default:
0. The amount of padding, in pixels, to exceed before the auto-size behavior will occur.- auto_size_boundary
The auto-size boundary describes clipping element(s) that overflow will be checked relative to when resizing. By default, the boundary includes overflow ancestors that will cause the element to be clipped. If needed, you can change the boundary by passing a reference to one or more elements to this property.
- boundary
Enumerated string. Allowed values:
scroll,viewport. Default:viewport. The bounding box to use for flipping, shifting, and auto-sizing.- dir
String. Optional Web Awesome attribute.
- distance
Number. Default:
0. The distance in pixels from which to offset the panel away from its anchor.- flip
Boolean. Default:
FALSE. When set, placement of the popup will flip to the opposite site to keep it in view. You can useflipFallbackPlacementsto further configure how the fallback placement is determined.- flip_fallback_placements
String. Default:
"". If the preferred placement doesn't fit, popup will be tested in these fallback placements until one fits. Must be a string of any number of placements separated by a space, e.g. "top bottom left". If no placement fits, the flip fallback strategy will be used instead.- flip_fallback_strategy
Enumerated string. Allowed values:
best-fit,initial. Default:best-fit. When neither the preferred placement nor the fallback placements fit, this value will be used to determine whether the popup should be positioned using the best available fit based on available space or as it was initially preferred.- flip_padding
Number. Default:
0. The amount of padding, in pixels, to exceed before the flip behavior will occur.- flip_boundary
The flip boundary describes clipping element(s) that overflow will be checked relative to when flipping. By default, the boundary includes overflow ancestors that will cause the element to be clipped. If needed, you can change the boundary by passing a reference to one or more elements to this property.
- hover_bridge
Boolean. Default:
FALSE. When a gap exists between the anchor and the popup element, this option will add a "hover bridge" that fills the gap using an invisible element. This makes listening for events such asmouseenterandmouseleavemore sane because the pointer never technically leaves the element. The hover bridge will only be drawn when the popover is active.- lang
String. Optional Web Awesome attribute.
- placement
Enumerated string. Allowed values:
bottom,bottom-end,bottom-start,left,left-end,left-start,right,right-end,right-start,top,top-end,top-start. Default:top. The preferred placement of the popup. Note that the actual placement will vary as configured to keep the panel inside of the viewport.- shift
Boolean. Default:
FALSE. Moves the popup along the axis to keep it in view when clipped.- shift_padding
Number. Default:
0. The amount of padding, in pixels, to exceed before the shift behavior will occur.- shift_boundary
The shift boundary describes clipping element(s) that overflow will be checked relative to when shifting. By default, the boundary includes overflow ancestors that will cause the element to be clipped. If needed, you can change the boundary by passing a reference to one or more elements to this property.
- skidding
Number. Default:
0. The distance in pixels from which to offset the panel along its anchor.- sync
Enumerated string. Allowed values:
both,height,width. Syncs the popup's width or height to that of the anchor element.- anchor_slot
The element the popup will be anchored to. If the anchor lives outside of the popup, you can use the
anchorattribute or property instead.