ant-design-x-vue
Version:
Craft AI-driven interfaces effortlessly
59 lines (58 loc) • 1.44 kB
JavaScript
import { defineComponent as a, mergeDefaults as r, createVNode as l, mergeProps as s } from "vue";
import { a as i, c as u } from "../../attachments/Attachments2.mjs";
import c from "./ActionButton/index.mjs";
import d from "../StopLoading.mjs";
import { useActionButtonContextInject as m } from "./ActionButton/context.mjs";
import { theme as p } from "ant-design-vue";
const x = /* @__PURE__ */ a({
name: "AXSenderLoadingButton",
__name: "LoadingButton",
props: r({
prefixCls: null,
type: null,
htmlType: null,
shape: null,
size: null,
loading: null,
disabled: null,
ghost: null,
block: null,
danger: null,
icon: null,
href: null,
target: null,
title: null,
onClick: null,
onMousedown: null
}, {
type: "primary",
shape: "circle",
icon: void 0,
disabled: void 0
}),
setup(e) {
const o = i(e, ["type", "shape", "icon", "disabled"]), n = m(), {
token: t
} = p.useToken();
return () => l(c, s({
type: e.type,
disabled: e.disabled,
shape: e.shape,
icon: e.icon
}, o, {
style: {
backgroundColor: "transparent",
color: t.value.colorPrimary
},
class: u(`${n.value.prefixCls}-loading-button`),
action: "onCancel"
}), {
default: () => [l(d, {
className: `${n.value.prefixCls}-loading-icon`
}, null)]
});
}
});
export {
x as default
};