Skip to content

Commit

Permalink
fix: name conflicts and add node-fetch type
Browse files Browse the repository at this point in the history
  • Loading branch information
martapanc committed Mar 19, 2024
1 parent 78a756a commit 2913388
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 12 deletions.
Binary file modified .yarn/install-state.gz
Binary file not shown.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
"@testing-library/react": "^14.2.1",
"@types/jest": "^29.5.12",
"@types/js-cookie": "^3.0.6",
"@types/node-fetch": "^2.6.11",
"@types/react": "^18.2.67",
"@types/react-headroom": "^3.2.3",
"@types/react-syntax-highlighter": "^15.5.11",
Expand Down
4 changes: 2 additions & 2 deletions src/components/organisms/home/SkillSummary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ const font = Inter({ weight: '400', subsets: ['latin'] });

import clsxm from '@/lib/clsxm';

import { HomePage } from '@/types/Homepage';
import { HomepageContent } from '@/types/HomepageContent';

interface SkillsProps {
homePage: HomePage;
homePage: HomepageContent;
}

const SkillSummary = ({ homePage }: SkillsProps) => {
Expand Down
4 changes: 2 additions & 2 deletions src/components/organisms/home/Summary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import jobs from '@/data/jobs.json';

import Photo from '@/components/organisms/home/Photo';

import { HomePage } from '@/types/Homepage';
import { HomepageContent } from '@/types/HomepageContent';

interface LinkProps {
key: string;
Expand Down Expand Up @@ -89,7 +89,7 @@ function buildEduLogo(logo: EduLogoProps, logoVersion: string) {
}

export interface SummaryProps {
homePage: HomePage;
homePage: HomepageContent;
}

const Summary = ({ homePage }: SummaryProps) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ const font3 = Square_Peg({ weight: '400', subsets: ['latin'] });

import clsxm from '@/lib/clsxm';

import { Updates } from '@/types/Homepage';
import { Updates } from '@/types/HomepageContent';

interface UpdatesProps {
updates: Updates;
}

const Updates = ({ updates }: UpdatesProps) => {
const UpdatesSummary = ({ updates }: UpdatesProps) => {
return (
<div className='flex flex-col w-full'>
<div className='tracking-widest text-sm font-semibold text-slate-500 mb-5 text-end'>
Expand Down Expand Up @@ -92,4 +92,4 @@ const Updates = ({ updates }: UpdatesProps) => {
);
};

export default Updates;
export default UpdatesSummary;
8 changes: 4 additions & 4 deletions src/components/pages/home-page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ import Intro from '@/components/organisms/home/Intro';
import Projects from '@/components/organisms/home/Projects';
import SkillSummary from '@/components/organisms/home/SkillSummary';
import Summary from '@/components/organisms/home/Summary';
import Updates from '@/components/organisms/home/Updates';
import UpdatesSummary from '@/components/organisms/home/UpdatesSummary';

import { CodeSnippet } from '@/types/CodeSnippet';
import { HomePage } from '@/types/Homepage';
import { HomepageContent } from '@/types/HomepageContent';
import { Project } from '@/types/Project';

type HomePageProps = {
homePage: HomePage;
homePage: HomepageContent;
codeSnippets: CodeSnippet[];
projects: Project[];
};
Expand Down Expand Up @@ -57,7 +57,7 @@ export default function HomePage({

<div className='bg-almost-white dark:bg-home-section4-dark'>
<div className='layout relative flex pt-8 pb-24'>
<Updates updates={homePage.updates} />
<UpdatesSummary updates={homePage.updates} />
</div>
</div>
</section>
Expand Down
2 changes: 1 addition & 1 deletion src/types/Homepage.ts → src/types/HomepageContent.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export interface HomePage {
export interface HomepageContent {
greeting: string;
introduction: Introduction;
skills: Skills;
Expand Down
11 changes: 11 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4735,6 +4735,16 @@ __metadata:
languageName: node
linkType: hard

"@types/node-fetch@npm:^2.6.11":
version: 2.6.11
resolution: "@types/node-fetch@npm:2.6.11"
dependencies:
"@types/node": "npm:*"
form-data: "npm:^4.0.0"
checksum: 10c0/5283d4e0bcc37a5b6d8e629aee880a4ffcfb33e089f4b903b2981b19c623972d1e64af7c3f9540ab990f0f5c89b9b5dda19c5bcb37a8e177079e93683bfd2f49
languageName: node
linkType: hard

"@types/node@npm:*":
version: 20.11.19
resolution: "@types/node@npm:20.11.19"
Expand Down Expand Up @@ -13064,6 +13074,7 @@ __metadata:
"@types/cookie": "npm:^0.6.0"
"@types/jest": "npm:^29.5.12"
"@types/js-cookie": "npm:^3.0.6"
"@types/node-fetch": "npm:^2.6.11"
"@types/react": "npm:^18.2.67"
"@types/react-dom": "npm:^18.2.22"
"@types/react-google-recaptcha": "npm:^2.1.9"
Expand Down

0 comments on commit 2913388

Please sign in to comment.