Files
bigcapital/packages/webapp/src/containers/Homepage/Homepage.tsx
2023-02-03 01:02:31 +02:00

37 lines
883 B
TypeScript

// @ts-nocheck
import React, { useEffect } from 'react';
import { DashboardInsider } from '@/components/Dashboard';
import HomepageContent from './HomepageContent';
import withDashboardActions from '@/containers/Dashboard/withDashboardActions';
import withCurrentOrganization from '@/containers/Organization/withCurrentOrganization';
import { compose } from '@/utils';
/**
* Dashboard homepage.
*/
function DashboardHomepage({
// #withDashboardActions
changePageTitle,
// #withCurrentOrganization
organization,
}) {
useEffect(() => {
changePageTitle(organization.name);
}, [organization.name, changePageTitle]);
return (
<DashboardInsider name="homepage">
<HomepageContent />
</DashboardInsider>
);
}
export default compose(
withDashboardActions,
withCurrentOrganization(({ organization }) => ({ organization })),
)(DashboardHomepage);