Skip to content

Commit

Permalink
Add metadata, disallow robots (#738)
Browse files Browse the repository at this point in the history
  • Loading branch information
argaen authored Mar 15, 2024
1 parent cb84d96 commit 698030b
Show file tree
Hide file tree
Showing 17 changed files with 265 additions and 123 deletions.
2 changes: 1 addition & 1 deletion amplify/backend/function/stockerlambda/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"@types/cors": "^2.8.17",
"@types/express": "^4.17.21",
"@types/jest": "^29.5.6",
"@types/node": "^20.11.24",
"@types/node": "^20.11.27",
"eslint": "^8.57.0",
"eslint-config-airbnb-base": "^15.0.0",
"jest": "^27.4.6",
Expand Down
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"@dinero.js/currencies": "^2.0.0-alpha.14",
"@fontsource/inter": "^5.0.17",
"@hookform/resolvers": "^3.3.4",
"@tanstack/react-query": "^5.25.0",
"@tanstack/react-query-devtools": "^5.21.0",
"@tanstack/react-query": "^5.28.0",
"@tanstack/react-query-devtools": "^5.25.0",
"@tanstack/react-table": "^8.13.0",
"@testing-library/jest-dom": "^6.4.2",
"aws-amplify": "^5.3.12",
Expand All @@ -43,7 +43,7 @@
"debounce-promise": "^3.1.2",
"dinero.js": "^2.0.0-alpha.14",
"luxon": "^3.4.4",
"next": "^14.1.2",
"next": "^14.1.3",
"pako": "^2.1.0",
"react": "^18.2.0",
"react-chartjs-2": "^5.2.0",
Expand Down Expand Up @@ -119,10 +119,10 @@
"@types/google.accounts": "^0.0.14",
"@types/jest": "^29.5.5",
"@types/luxon": "^3.4.2",
"@types/node": "^20.11.24",
"@types/node": "^20.11.27",
"@types/pako": "^2.0.3",
"@types/react": "18.2.62",
"@types/react-dom": "^18.2.19",
"@types/react": "18.2.66",
"@types/react-dom": "^18.2.22",
"@types/react-modal": "^3.16.3",
"@types/react-router-dom": "^5.3.3",
"@types/react-table": "^7.7.19",
Expand All @@ -134,18 +134,18 @@
"eslint": "^8.57.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-airbnb-typescript": "^18.0.0",
"eslint-config-next": "^14.1.1",
"eslint-config-next": "^14.1.3",
"eslint-config-prettier": "^9.1.0",
"eslint-config-react-app": "^7.0.1",
"eslint-plugin-prettier": "^5.1.3",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"postcss": "^8.4.35",
"prettier": "^3.2.5",
"prettier-plugin-tailwindcss": "^0.5.11",
"prettier-plugin-tailwindcss": "^0.5.12",
"snapshot-diff": "^0.10.0",
"tailwindcss": "^3.4.1",
"typescript": "^5.3.3",
"typescript": "^5.4.2",
"webpack-filter-warnings-plugin": "^1.2.1"
}
}
2 changes: 2 additions & 0 deletions public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
User-agent: *
Disallow: /
12 changes: 12 additions & 0 deletions src/__tests__/app/dashboard/accounts/[guid]/layout.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import React from 'react';
import { render, screen } from '@testing-library/react';

import AccountLayout from '@/app/dashboard/accounts/[guid]/layout';

describe('AccountLayout', () => {
it('renders as expected', () => {
render(<AccountLayout><span>hello</span></AccountLayout>);

screen.getByText('hello');
});
});
12 changes: 12 additions & 0 deletions src/__tests__/app/dashboard/accounts/layout.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import React from 'react';
import { render, screen } from '@testing-library/react';

import AccountsLayout from '@/app/dashboard/accounts/layout';

describe('AccountsLayout', () => {
it('renders as expected', () => {
render(<AccountsLayout><span>hello</span></AccountsLayout>);

screen.getByText('hello');
});
});
12 changes: 12 additions & 0 deletions src/__tests__/app/dashboard/commodities/[guid]/layout.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import React from 'react';
import { render, screen } from '@testing-library/react';

import CommodityLayout from '@/app/dashboard/commodities/[guid]/layout';

describe('CommodityLayout', () => {
it('renders as expected', () => {
render(<CommodityLayout><span>hello</span></CommodityLayout>);

screen.getByText('hello');
});
});
12 changes: 12 additions & 0 deletions src/__tests__/app/dashboard/commodities/layout.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import React from 'react';
import { render, screen } from '@testing-library/react';

import CommoditiesLayout from '@/app/dashboard/commodities/layout';

describe('CommoditiesLayout', () => {
it('renders as expected', () => {
render(<CommoditiesLayout><span>hello</span></CommoditiesLayout>);

screen.getByText('hello');
});
});
12 changes: 12 additions & 0 deletions src/__tests__/app/dashboard/investments/layout.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import React from 'react';
import { render, screen } from '@testing-library/react';

import InvestmentsLayout from '@/app/dashboard/investments/layout';

describe('InvestmentsLayout', () => {
it('renders as expected', () => {
render(<InvestmentsLayout><span>hello</span></InvestmentsLayout>);

screen.getByText('hello');
});
});
10 changes: 5 additions & 5 deletions src/__tests__/layout/__snapshots__/LeftSideBar.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@ exports[`LeftSidebar renders as expected 1`] = `
href="/"
>
<span
class="flex justify-center items-center ml-6 mr-1 h-20"
class="flex justify-center items-center h-20"
>
<img
alt="logo"
data-nimg="1"
decoding="async"
height="65"
height="40"
loading="lazy"
src="/_next/image?url=%2Fimg.jpg&w=256&q=75"
srcset="/_next/image?url=%2Fimg.jpg&w=96&q=75 1x, /_next/image?url=%2Fimg.jpg&w=256&q=75 2x"
src="/_next/image?url=%2Fimg.jpg&w=96&q=75"
srcset="/_next/image?url=%2Fimg.jpg&w=48&q=75 1x, /_next/image?url=%2Fimg.jpg&w=96&q=75 2x"
style="color: transparent;"
width="65"
width="40"
/>
</span>
</a>
Expand Down
15 changes: 15 additions & 0 deletions src/app/dashboard/accounts/[guid]/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';

export const metadata = {
title: 'Account | Maffin',
};

export default function AccountLayout({
children,
}: React.PropsWithChildren): JSX.Element {
return (
<div>
{children}
</div>
);
}
15 changes: 15 additions & 0 deletions src/app/dashboard/accounts/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';

export const metadata = {
title: 'Home',
};

export default function AccountsLayout({
children,
}: React.PropsWithChildren): JSX.Element {
return (
<div>
{children}
</div>
);
}
15 changes: 15 additions & 0 deletions src/app/dashboard/commodities/[guid]/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';

export const metadata = {
title: 'Commodity | Maffin',
};

export default function CommodityLayout({
children,
}: React.PropsWithChildren): JSX.Element {
return (
<div>
{children}
</div>
);
}
15 changes: 15 additions & 0 deletions src/app/dashboard/commodities/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';

export const metadata = {
title: 'Commodities',
};

export default function CommoditiesLayout({
children,
}: React.PropsWithChildren): JSX.Element {
return (
<div>
{children}
</div>
);
}
15 changes: 15 additions & 0 deletions src/app/dashboard/investments/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';

export const metadata = {
title: 'Investments',
};

export default function InvestmentsLayout({
children,
}: React.PropsWithChildren): JSX.Element {
return (
<div>
{children}
</div>
);
}
Binary file added src/assets/images/logo-image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/layout/LeftSidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ import React from 'react';
import Link from 'next/link';
import Image from 'next/image';

import maffinLogo from '@/assets/images/maffin_logo_sm.png';
import Logo from '@/assets/images/logo-image.png';
import Menu from './Menu';

export default function LeftSideBar(): JSX.Element {
return (
<div className="fixed bg-dark-700 text-center h-screen pt-20 w-20 pb-5 z-10">
<Link href="/" className="fixed block top-0 h-20 w-20 z-2">
<span className="flex justify-center items-center ml-6 mr-1 h-20">
<Image src={maffinLogo} alt="logo" height="65" />
<span className="flex justify-center items-center h-20">
<Image src={Logo} alt="logo" height="40" />
</span>
</Link>

Expand Down
Loading

0 comments on commit 698030b

Please sign in to comment.