Athena

ProviderButton

Renders one social auth provider button with the package styling and provider metadata.

Import

import { ProviderButton } from "@xylex-group/athena-auth-ui"

Details

  • Category: component
  • Primary entrypoint: @xylex-group/athena-auth-ui
  • Public entrypoints: @xylex-group/athena-auth-ui
  • Source: packages/heroui/src/components/auth/provider-button.tsx

Props

PropTypeRequiredNotes
providerstringYes
display"name" | "full" | "icon" | undefinedNo
uiAthenaAuthUiOptions | undefinedNo
variant"secondary" | "tertiary" | "danger" | "danger-soft" | "ghost" | "outline" | "primary" | undefinedNo
classNameClassNameOrFunction<ButtonRenderProps> | undefinedNoThe CSS className for the element. A function may be provided to compute the class based on component state.
idstring | undefinedNoThe element's unique identifier. See MDN.
namestring | undefinedNoSubmitted as a pair with the button's value as part of the form data.
type"reset" | "button" | "submit" | undefinedNoThe behavior of the button when used in an HTML form.
renderDOMRenderFunction<"button", ButtonRenderProps> | undefinedNoOverrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: * You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). * Only a single root DOM element can be rendered (no fragments). * You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
size"lg" | "md" | "sm" | undefinedNo
__button_group_childboolean | undefinedNo
isDisabledboolean | undefinedNoWhether the button is disabled.
onPressStart((e: PressEvent) => void) | undefinedNoHandler that is called when a press interaction starts.
onPressEnd((e: PressEvent) => void) | undefinedNoHandler that is called when a press interaction ends, either over the target or when the pointer leaves the target.
onPressChange((isPressed: boolean) => void) | undefinedNoHandler that is called when the press state changes.
onPressUp((e: PressEvent) => void) | undefinedNoHandler that is called when a press is released over the target, regardless of whether it started on the target or not.
onClick((e: MouseEvent<FocusableElement>) => void) | undefinedNoNot recommended – use onPress instead. onClick is an alias for onPress provided for compatibility with other libraries. onPress provides additional event details for non-mouse interactions.
autoFocusboolean | undefinedNoWhether the element should receive focus on render.
onFocus((e: FocusEvent<Element, Element>) => void) | undefinedNoHandler that is called when the element receives focus.
onBlur((e: FocusEvent<Element, Element>) => void) | undefinedNoHandler that is called when the element loses focus.
onFocusChange((isFocused: boolean) => void) | undefinedNoHandler that is called when the element's focus status changes.
onKeyDown((e: KeyboardEvent) => void) | undefinedNoHandler that is called when a key is pressed.
onKeyUp((e: KeyboardEvent) => void) | undefinedNoHandler that is called when a key is released.
aria-disabledboolean | "true" | "false" | undefinedNoIndicates whether the element is disabled to users of assistive technology.
aria-expandedboolean | "true" | "false" | undefinedNoIndicates whether the element, or another grouping element it controls, is currently expanded or collapsed.
aria-haspopupboolean | "grid" | "true" | "false" | "menu" | "listbox" | "tree" | "dialog" | undefinedNoIndicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.
aria-controlsstring | undefinedNoIdentifies the element (or elements) whose contents or presence are controlled by the current element.
aria-pressedboolean | "true" | "false" | "mixed" | undefinedNoIndicates the current "pressed" state of toggle buttons.
aria-currentboolean | "true" | "false" | "date" | "time" | "page" | "step" | "location" | undefinedNoIndicates whether this element represents the current item within a container or set of related elements.
preventFocusOnPressboolean | undefinedNoWhether to prevent focus from moving to the button when pressing it. Caution, this can make the button inaccessible and should only be used when alternative keyboard interaction is provided, such as ComboBox's MenuTrigger or a NumberField's increment/decrement control.
formstring | undefinedNoThe <form> element to associate the button with. The value of this attribute must be the id of a <form> in the same document. See MDN.
formActionstring | ((formData: FormData) => void | Promise<void>) | undefinedNoThe URL that processes the information submitted by the button. Overrides the action attribute of the button's form owner.
formEncTypestring | undefinedNoIndicates how to encode the form data that is submitted.
formMethodstring | undefinedNoIndicates the HTTP method used to submit the form.
formNoValidateboolean | undefinedNoIndicates that the form is not to be validated when it is submitted.
formTargetstring | undefinedNoOverrides the target attribute of the button's form owner.
valuestring | undefinedNoThe value associated with the button's name when it's submitted with the form data.
excludeFromTabOrderboolean | undefinedNoWhether to exclude the element from the sequential tab order. If true, the element will not be focusable via the keyboard by tabbing. This should be avoided except in rare scenarios where an alternative means of accessing the element or its functionality via the keyboard is available.
aria-labelstring | undefinedNoDefines a string value that labels the current element.
aria-labelledbystring | undefinedNoIdentifies the element (or elements) that labels the current element.
aria-describedbystring | undefinedNoIdentifies the element (or elements) that describes the object.
aria-detailsstring | undefinedNoIdentifies the element (or elements) that provide a detailed, extended description for the object.
dirstring | undefinedNo
langstring | undefinedNo
hiddenboolean | undefinedNo
inertboolean | undefinedNo
translate"yes" | "no" | undefinedNo
onClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onAuxClickMouseEventHandler<HTMLButtonElement> | undefinedNo
onAuxClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onContextMenuMouseEventHandler<HTMLButtonElement> | undefinedNo
onContextMenuCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onDoubleClickMouseEventHandler<HTMLButtonElement> | undefinedNo
onDoubleClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseDownMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseDownCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseEnterMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseLeaveMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseMoveMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseMoveCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseOutMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseOutCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseOverMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseOverCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseUpMouseEventHandler<HTMLButtonElement> | undefinedNo
onMouseUpCaptureMouseEventHandler<HTMLButtonElement> | undefinedNo
onTouchCancelTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchCancelCaptureTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchEndTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchEndCaptureTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchMoveTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchMoveCaptureTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchStartTouchEventHandler<HTMLButtonElement> | undefinedNo
onTouchStartCaptureTouchEventHandler<HTMLButtonElement> | undefinedNo
onPointerDownPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerDownCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerMovePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerMoveCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerUpPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerUpCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerCancelPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerCancelCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerEnterPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerLeavePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerOverPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerOverCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerOutPointerEventHandler<HTMLButtonElement> | undefinedNo
onPointerOutCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onGotPointerCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onGotPointerCaptureCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onLostPointerCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onLostPointerCaptureCapturePointerEventHandler<HTMLButtonElement> | undefinedNo
onScrollUIEventHandler<HTMLButtonElement> | undefinedNo
onScrollCaptureUIEventHandler<HTMLButtonElement> | undefinedNo
onWheelWheelEventHandler<HTMLButtonElement> | undefinedNo
onWheelCaptureWheelEventHandler<HTMLButtonElement> | undefinedNo
onAnimationStartAnimationEventHandler<HTMLButtonElement> | undefinedNo
onAnimationStartCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNo
onAnimationEndAnimationEventHandler<HTMLButtonElement> | undefinedNo
onAnimationEndCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNo
onAnimationIterationAnimationEventHandler<HTMLButtonElement> | undefinedNo
onAnimationIterationCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNo
onTransitionCancelTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionCancelCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionEndTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionEndCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionRunTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionRunCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionStartTransitionEventHandler<HTMLButtonElement> | undefinedNo
onTransitionStartCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNo
fullWidthboolean | undefinedNo
isIconOnlyboolean | undefinedNo
onHoverStart((e: HoverEvent) => void) | undefinedNoHandler that is called when a hover interaction starts.
onHoverEnd((e: HoverEvent) => void) | undefinedNoHandler that is called when a hover interaction ends.
onHoverChange((isHovering: boolean) => void) | undefinedNoHandler that is called when the hover state changes.
slotstring | null | undefinedNoA slot name for the component. Slots allow the component to receive props from a parent component. An explicit null value indicates that the local props completely override all props received from a parent.
styleStyleOrFunction<ButtonRenderProps> | undefinedNoThe inline style for the element. A function may be provided to compute the style based on component state.
refRef<HTMLButtonElement> | undefinedNoAllows getting a ref to the component instance. Once the component unmounts, React will set ref.current to null (or call the ref with null if you passed a callback ref).
keyKey | null | undefinedNo

Notes

  • Most interactive auth components expect to be rendered under AuthProvider so hooks such as useAuth and the configured navigation bridge are available.
  • See Customization Guide for provider-level localization, route overrides, class-name slots, loading overrides, and email template key mapping.