Skip to content

Commit

Permalink
fix: run npm run format
Browse files Browse the repository at this point in the history
  • Loading branch information
1egoman committed Oct 11, 2024
1 parent 7edcdbf commit ff830f1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
10 changes: 5 additions & 5 deletions packages/web/src/components/apps/workspace/preview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ export function Preview(props: PropsType) {
const { url, status } = usePreview();

switch (status) {
case "booting":
case "connecting":
case 'connecting':
case 'booting':
return (
<div className={cn("flex justify-center items-center w-full h-full", props.className)}>
<div className={cn('flex justify-center items-center w-full h-full', props.className)}>
<span className="text-tertiary-foreground">Booting...</span>
</div>
);
case "running":
case 'running':
if (url === null) {
return;
}
Expand All @@ -26,7 +26,7 @@ export function Preview(props: PropsType) {
<iframe className="w-full h-full" src={url} title="App preview" />
</div>
);
case "stopped":
case 'stopped':
return null;
}
}
6 changes: 2 additions & 4 deletions packages/web/src/routes/apps.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function AppsPage() {

function Apps(props: { app: AppType }) {
const { status: previewStatus } = usePreview();
const previewVisible = previewStatus === "booting" || previewStatus === "running";
const previewVisible = previewStatus === 'booting' || previewStatus === 'running';

return (
<div className="h-screen max-h-screen flex">
Expand All @@ -76,9 +76,7 @@ function Apps(props: { app: AppType }) {
)}
>
<Editor app={props.app} />
{previewVisible ? (
<Preview />
) : null}
{previewVisible ? <Preview /> : null}
</div>
</div>
);
Expand Down

0 comments on commit ff830f1

Please sign in to comment.