Skip to content

Commit 68916f4

Browse files
committed
Adjust empty Studio page
1 parent 31066dd commit 68916f4

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

src/components/site-content-tabs.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,21 @@ import { cx } from 'src/lib/cx';
1515
import { ContentTabSync } from 'src/modules/sync';
1616

1717
export function SiteContentTabs() {
18-
const { selectedSite } = useSiteDetails();
18+
const { selectedSite, data: localSites } = useSiteDetails();
1919
const { importState } = useImportExport();
2020
const { tabs, selectedTab, setSelectedTab } = useContentTabs();
2121
const { __ } = useI18n();
2222

23+
if ( ! localSites.length ) {
24+
return (
25+
<div className="w-full h-full flex items-center justify-center app-no-drag-region">
26+
<p className="text-lg text-gray-600">
27+
{ __( 'All sites removed. Add a new one to get started again.' ) }
28+
</p>
29+
</div>
30+
);
31+
}
32+
2333
if ( ! selectedSite ) {
2434
return (
2535
<div className="w-full h-full flex items-center justify-center app-no-drag-region">

0 commit comments

Comments
 (0)