Chuyển tới nội dung chính

Button

Properties​

Button​

NameTypeDefaultDescription
variantButtonVariantsprimaryĐộ đậm của background color
loadingbooleanHiển thị icon loading
disabledbooleanTrạng thái disable
typeButtonTypehighlightLoại button
htmlTypeButtonHTMLTypebuttonHTML button type
sizeButtonSizeKích thước button
fullWidthbooleanĐặt kích thước button full parent width
prefixIconReact.ReactNodeThêm prefix icon
suffixIconReact.ReactNodeThêm suffix icon
iconReact.ReactNodeThêm icon cho button

Type​

ButtonType​

NameDescription
"highlight"highlight
"danger"danger
"neutral"neutral

ButtonHTMLType​

NameDescription
"submit"submit
"button"button
"reset"reset

ButtonSize​

NameDescription
"large"large
"medium"medium
"small"small

ButtonVariants​

NameDescription
"primary"primary button
"secondary"secondary button
"tertiary"tertiary button

Example​

import React from "react";
import { Page, Button } from "zmp-ui";

function HomePage(props) {
return (

<Button size="large">Button</Button>

);
}