🐛(button): 修复 disabled 属性只标注属性不生效的问题

This commit is contained in:
就眠儀式 2022-11-02 11:53:43 +08:00
parent cf254de182
commit 21d8d05032
2 changed files with 5 additions and 6 deletions

View File

@ -24,10 +24,10 @@ export interface ButtonProps {
loadingIcon?: string;
borderStyle?: string;
border?: ButtonBorder;
fluid?: string | boolean;
radius?: string | boolean;
loading?: string | boolean;
disabled?: string | boolean;
fluid?: boolean;
radius?: boolean;
loading?: boolean;
disabled?: boolean;
nativeType?: ButtonNativeType;
}
@ -35,7 +35,6 @@ const props = withDefaults(defineProps<ButtonProps>(), {
loadingIcon: "layui-icon-loading-one",
borderStyle: "soild",
nativeType: "button",
disabled: false,
loading: false,
radius: false,
fluid: false,

View File

@ -99,7 +99,7 @@ export default {
<lay-button type="normal" size="lg">百搭按钮</lay-button>
<lay-button type="warm" size="lg">暖色按钮</lay-button>
<lay-button type="danger" size="lg">警告按钮</lay-button>
<lay-button type="disabled" size="lg">禁用按钮</lay-button>
<lay-button disabled size="lg">禁用按钮</lay-button>
</template>
<script>