Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface AutoCompleteListboxPositionOptions

Hierarchy

Index

Properties

anchor?: PositionAnchor

The configuration to anchor the fixed element to the container element.

defaultvalue

BELOW_CENTER_ANCHOR

closeOnResize?: boolean

Boolean if the select's listbox should not hide if the user resizes the browser while it is visible.

closeOnScroll?: boolean

Boolean if the select's listbox should not hide if the user scrolls the page while it is visible.

disableSwapping?: boolean

Boolean if the auto-swapping behavior should be disabled. It's normally recommended to not disable this since it'll allow elements to appear off screen.

defaultvalue

false

remarks

@since 5.0.0 This will always be true if the FixedPositionOptions.container is null. @remarks @since 5.1.6 Allow this to be false while the container is null. I can't figure out why I prevented that.

disableVHBounds?: boolean

Boolean if the fixed positioning should no longer prevent the fixed element to be positioned within the viewport. This is nice if you want to allow for full page scrolling instead and manually set a max-height on your element.

defaultvalue

false

initialX?: number

The initial x value to use when calculating the position instead of finding the container element to determine the the correct position. All the other positioning logic will still be in effect to ensure the element will be visible within the viewport.

initialY?: number

The initial y value to use when calculating the position instead of finding the container element to determine the the correct position. All the other positioning logic will still be in effect to ensure the element will be visible within the viewport.

listboxStyle?: CSSProperties

An optional style to also apply to the listbox element showing all the matches.

listboxWidth?: PositionWidth

The sizing behavior for the listbox. It will default to have the same width as the select button, but it is also possible to either have the min-width be the width of the select button or just automatically determine the width.

The sizing behavior will always ensure that the left and right bounds of the listbox appear within the viewport.

preventOverlap?: boolean

Boolean if the fixed element should no longer be able to overlap the container element. This is useful for autocomplete menus or other components that retain focus on the container element while the fixed element becomes visible.

defaultvalue

false

transformOrigin?: boolean

Boolean if the style object should include the transformOrigin value based on the x and y positions.

defaultvalue

false

vhMargin?: number

The viewwidth margin to apply so that the element doesn't need to be directly on the screen edge.

defaultvalue

16

vwMargin?: number

The viewwidth margin to apply so that the element doesn't need to be directly on the screen edge.

defaultvalue

16

xMargin?: number

The container width margin to apply so that the element doesn't need to be directly on the container's edge.

defaultvalue

0

yMargin?: number

The container height margin to apply so that the element doesn't need to be directly on the container's edge

defaultvalue

0

Generated using TypeDoc