Button 按钮 #
基本使用 #
按钮的 type 分别为 default、tertiary、primary、info、success、warning 和 error。
基本使用
<template>
<div>
<h-button>Default</h-button>
<h-button type="primary">Primary</h-button>
<h-button type="info">Info</h-button>
<h-button type="warning">Warning</h-button>
<h-button type="error">Error</h-button>
<h-button type="error" size="small">Error</h-button>
</div>
</template>
<script lang="ts" setup></script>
<style scoped lang="scss">
* {
margin-left: 10px;
}
</style>
组件 API #
Attributes 属性 #
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
|---|---|---|---|---|
Methods 方法 #
| 方法名 | 说明 | 参数 | 返回值 |
|---|---|---|---|
Events 事件 #
| 事件名 | 说明 | 参数 | 返回值 |
|---|---|---|---|
Slots 插槽 #
| 插槽名 | 说明 | 参数 |
|---|---|---|
hare-ui