Create Loading.js
This commit is contained in:
13
src/components/Loading.js
Normal file
13
src/components/Loading.js
Normal file
@@ -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" }),
|
||||
]),
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user