diff --git a/src/components/Loading.js b/src/components/Loading.js new file mode 100644 index 0000000..902c631 --- /dev/null +++ b/src/components/Loading.js @@ -0,0 +1,13 @@ +import { $html, $if } from "sigpro"; + +/** LOADING (Overlay Component) */ +export const Loading = (props) => { + // Se espera un signal props.$show para controlar la visibilidad + return $if(props.$show, () => + $html("div", { + class: "fixed inset-0 z-[100] flex items-center justify-center backdrop-blur-sm bg-base-100/30" + }, [ + $html("span", { class: "loading loading-spinner loading-lg text-primary" }), + ]), + ); +};