axross/ui

ActionButton component

Opened this issue · 0 comments

axross commented

Requirements

Props

  • variant?: "solid" | "outline" | "ghost" | "link" = "solid"
  • intent?: "neutral" | "action" | "danger" = "neutral"
  • size?: "md" | "sm" = "md"
  • disabled?: boolean = false
  • action: () => Promise<void>
  • transition?: boolean
  • icon?: string
  • loadingChildren?: import("react").ReactNode
  • finishedDuration?: number = 1500
  • finishedIcon?: string
  • finishedChildren?: import("react").ReactNode
  • style?: import("react").CSSProperties
  • children?: import("react").ReactNode

Rendered Elements

This component should render single <button> element and all the given props should be provided to this element.

Event Handlers

This component should take any event handler.