Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

chore: add loading shimmer, give nodata container a min height

TzeYiingd70245ca90b7
diff --git a/studio/components/ui/Charts/NoDataPlaceholder.tsx b/studio/components/ui/Charts/NoDataPlaceholder.tsx
index ecec43e8236..6a7a7e29c72 100644
--- a/studio/components/ui/Charts/NoDataPlaceholder.tsx
+++ b/studio/components/ui/Charts/NoDataPlaceholder.tsx
@@ -12,9 +12,10 @@ const NoDataPlaceholder: React.FC<Props> = ({
}) => (
<div
className={
- 'border-scale-600 flex h-full w-full flex-col items-center justify-center space-y-2 border border-dashed text-center ' +
+ 'border-scale-600 flex w-full flex-col items-center justify-center space-y-2 border border-dashed text-center ' +
className
}
+ style={{minHeight: "100px"}}
>
<IconBarChart2 className="text-scale-800" />
<div>
diff --git a/studio/pages/project/[ref]/reports/api-overview.tsx b/studio/pages/project/[ref]/reports/api-overview.tsx
index d5c86f0b25a..1062a48bbe6 100644
--- a/studio/pages/project/[ref]/reports/api-overview.tsx
+++ b/studio/pages/project/[ref]/reports/api-overview.tsx
@@ -38,24 +38,26 @@ export const ApiReport: NextPageWithLayout = () => {
}
return (
- <div className="flex flex-col gap-4 px-5 py-6 mx-auto 1xl:px-28 lg:px-16 xl:px-24 2xl:px-32">
+ <div className="flex flex-col gap-4 px-5 py-6 h-full mx-auto 1xl:px-28 lg:px-16 xl:px-24 2xl:px-32">
<ReportHeader title="API" isLoading={report.isLoading} onRefresh={report.refresh} />
-
- <ReportFilterBar
- onRemoveFilters={report.removeFilters}
- onDatepickerChange={handleDatepickerChange}
- datepickerFrom={report.params.totalRequests.iso_timestamp_start}
- datepickerTo={report.params.totalRequests.iso_timestamp_end}
- onAddFilter={report.addFilter}
- filters={report.filters}
- datepickerHelpers={REPORTS_DATEPICKER_HELPERS.map((helper, index) => ({
- ...helper,
- disabled: (index > 0 && tier?.key === 'FREE') || (index > 1 && tier?.key !== 'PRO'),
- }))}
- />
- <div className="h-2 w-full">
- <ShimmerLine active={report.isLoading} />
+ <div className="w-full flex flex-col gap-1">
+ <ReportFilterBar
+ onRemoveFilters={report.removeFilters}
+ onDatepickerChange={handleDatepickerChange}
+ datepickerFrom={report.params.totalRequests.iso_timestamp_start}
+ datepickerTo={report.params.totalRequests.iso_timestamp_end}
+ onAddFilter={report.addFilter}
+ filters={report.filters}
+ datepickerHelpers={REPORTS_DATEPICKER_HELPERS.map((helper, index) => ({
+ ...helper,
+ disabled: (index > 0 && tier?.key === 'FREE') || (index > 1 && tier?.key !== 'PRO'),
+ }))}
+ />
+ <div className="h-2 w-full">
+ <ShimmerLine active={report.isLoading} />
+ </div>
</div>
+
<ReportWidget
isLoading={report.isLoading}
params={report.params.totalRequests}