Wrapps the content with div and checks when user clicks outside of the dom. This component is used e.g. on UikDropdown. Check the source code for example.

PropertyTypeRequiredDefault ValueDescription
classNameStringfalsenullclassName, e.g. "my-custom-styling"
ComponentReact.ElementTypefalse"div"Renders the component with a given react element. By default, the component renders <div />. This is usefull when you want to use a same style but render a different HTML element or your custom component. Read and see more examples here.
onOutsideClickFunctionfalseCallback function that is triggered when clicked outside the element area
onOutsideScrollBooleanfalsetrueTriggers the onOutsideClick on scroll as well
onWindowResizeBooleanfalsetrueTriggers the onOutsideClick on window resize as well
...restanyfalseOther properties are passed down to the wrapping element