Backtop

A button to back to top.

Basic Usage

Scroll down to see the bottom-right button.

Customizations

Display area is 40px * 40px.

Backtop API

Backtop Attributes

NameDescriptionTypeDefault
targetthe target to trigger scroll.string
visibility-heightthe button will not show until the scroll height reaches this value.number200
rightright distance.number40
bottombottom distance.number40

Backtop Events

NameDescriptionParameters
clicktriggers when click.(evt: MouseEvent) => void

Backtop Slots

NameDescription
defaultcustomize default content.

Source

ComponentDocs

Contributors