Skip to content

Commit

Permalink
fix: empty data
Browse files Browse the repository at this point in the history
  • Loading branch information
hamster1963 committed Nov 29, 2024
1 parent 6e67602 commit e0fa019
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/components/NetworkChart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,12 @@ export function NetworkChart({

if (!monitorData) return <NetworkChartLoading />;

if (monitorData?.success && monitorData.data.length === 0) {
if (monitorData?.success && !monitorData.data) {
return (
<>
<div className="flex flex-col items-center justify-center">
<p className="text-sm font-medium opacity-40"></p>
<p className="text-sm font-medium opacity-40">
<p className="text-sm font-medium opacity-40 mb-4">
{t("monitor.noData")}
</p>
</div>
Expand Down
4 changes: 3 additions & 1 deletion src/components/ServiceTracker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ export const ServiceTracker: React.FC = () => {
}

if (!serviceData?.data?.services) {
return <div className="mt-4">No service data available</div>;
return (
<div className="mt-4 font-thin text-sm">No service data available</div>
);
}

return (
Expand Down

0 comments on commit e0fa019

Please sign in to comment.