ant-design/components/float-button/index.en-US.md
afc163 e027cbec1c
docs: format all markdown (#38629)
* chore: add prettier-ignore in markdown demo

* docs: format markdown api table

* docs: format markdown api table
2022-11-17 17:31:26 +08:00

2.4 KiB
Raw Blame History

category group title cover demo
Components Other FloatButton https://gw.alipayobjects.com/zos/bmw-prod/9b1b62fe-e677-4afc-b9fe-1b2993662611.svg
cols
2

FloatButton. Available since 5.0.0.

When To Use

  • For global functionality on the site.
  • Buttons that can be seen wherever you browse.

Examples

Basic Type Shape Description FloatButton with tooltip FloatButton Group Menu mode BackTop _InternalPanelDoNotUseOrYouWillBeFired

API

common API

Property Description Type Default Version
icon Set the icon component of button ReactNode -
description Text and other ReactNode -
tooltip The text shown in the tooltip ReactNode | () => ReactNode
type Setting button type default | primary default
shape Setting button shape circle | square circle
onClick Set the handler to handle click event (event) => void -
href The target of hyperlink string -
target Specifies where to display the linked URL string -

FloatButton.Group

Property Description Type Default Version
shape Setting button shape of children circle | square circle
trigger Which action can trigger menu open/close click | hover -
open Whether the menu is visible or not boolean -
onOpenChange Callback executed when active menu is changed (open: boolean) => void -

FloatButton.BackTop

Property Description Type Default Version
duration Time to return to topms number 450
target Specifies the scrollable area dom node () => HTMLElement () => window
visibilityHeight The BackTop button will not show until the scroll height reaches this value number 400
onClick A callback function, which can be executed when you click the button () => void -