@microsoft/fast-foundation > Button

Button class

A Button Custom HTML Element. Based largely on the <button> element.

start - Content which can be provided before the button content

end - Content which can be provided after the button content

  • The default slot for button content

control - The button element

content - The element wrapping button content

Signature:

export declare class Button extends FormAssociatedButton 

Properties

Property Modifiers Type Description
autofocus boolean Determines if the element should receive document focus on page load.
control HTMLButtonElement
defaultSlottedContent HTMLElement[] Default slotted content
formaction string See <button> element for more details.
formenctype string See <button> element for more details.
formId string The id of a form to associate the element to.
formmethod string See <button> element for more details.
formnovalidate boolean See <button> element for more details.
formtarget "_self" | "_blank" | "_parent" | "_top" See <button> element for more details.
type "submit" | "reset" | "button" The button type.