server state and stdio streaming

This commit is contained in:
2023-10-03 02:57:35 -06:00
parent dc4c8efeb2
commit 4a4563ba85
25 changed files with 502 additions and 80 deletions

View File

@@ -42,7 +42,7 @@ export function Button(
return (
<button
{...props}
disabled={(!IS_BROWSER && !props.href) || props.disabled}
disabled={(!IS_BROWSER && !props.href && props.type !== 'submit') || props.disabled}
class={classes}
/>
);

10
components/Loader.tsx Normal file
View File

@@ -0,0 +1,10 @@
export function Loader() {
return (
<div class="grid grid-cols-2 grid-rows-2 w-20 h-20 loader m-auto">
<div class="loader-ball w-5 h-5 rounded-full"></div>
<div class="loader-ball w-5 h-5 rounded-full" style={{'--loader-delay': '-1s'}}></div>
<div class="loader-ball w-5 h-5 rounded-full" style={{'--loader-delay': '-1.7s'}}></div>
<div class="loader-ball w-5 h-5 rounded-full" style={{'--loader-delay': '-2.6s'}}></div>
</div>
)
}