synapse-react-client
Version:
[](https://badge.fury.io/js/synapse-react-client) [](https://github.com/prettier/prettie
30 lines (29 loc) • 677 B
JavaScript
import { jsx as c } from "react/jsx-runtime";
import { useState as u } from "react";
import { Button as b } from "@mui/material";
function D(s) {
const { control: i, callbackData: t, disabled: e, ...r } = s, { onClick: a, buttonText: l, buttonID: d } = i, [o, n] = u(!1);
return /* @__PURE__ */ c(
b,
{
...r,
id: d,
variant: "outlined",
disabled: e || o,
loading: o,
onClick: () => {
n(!0), a({
...t,
refresh: () => {
n(!1), t.refresh();
}
});
},
children: l
}
);
}
export {
D as CustomControlButton
};
//# sourceMappingURL=CustomControlButton.js.map