diff --git a/src/commons/helpers.jsx b/src/commons/helpers.jsx
new file mode 100644
index 0000000..fe03ce6
--- /dev/null
+++ b/src/commons/helpers.jsx
@@ -0,0 +1,12 @@
+
+export function replacePlaceHolders(text, placeholdersMap) {
+ for (let [key, value] of placeholdersMap) {
+ console.log(key, value, text)
+ text = text.replace(key, value)
+ }
+ return text
+}
+
+export function capitalizeFirstLetter(str) {
+ return str[0].toUpperCase() + str.slice(1);
+}
\ No newline at end of file
diff --git a/src/components/FooterSticky.jsx b/src/components/FooterSticky.jsx
index 17750bd..d36768e 100644
--- a/src/components/FooterSticky.jsx
+++ b/src/components/FooterSticky.jsx
@@ -5,19 +5,15 @@ import FooterIcons from './FooterIcons';
function Copyright() {
return (
- <>
-
- {'Copyright © '}
- {/*
- */}
-
- Pardhu Madipalli
- {' '}
- {/*
- */}
- {new Date().getFullYear()}
-
- >
+
+ {'Copyright © '}
+
+
+ Pardhu Madipalli
+ {' '}
+
+ {new Date().getFullYear()}
+
);
}
diff --git a/src/content/homepage.yml b/src/content/homepage.yml
index 76f3d3f..621640a 100644
--- a/src/content/homepage.yml
+++ b/src/content/homepage.yml
@@ -2,9 +2,9 @@ data:
mainItems:
- key: software
title: Software Engineering
- subtitle: Five years experience
+ subtitle: Number_of_years years experience
text:
- - Working as a cloud full stack developer for more than 4 years. Over this time, I have worked on very diverse areas including web server technologies, cloud infrastructure and applications, and, UI.
+ - Working as a cloud full stack developer for more than Number_of_years years. Over this time, I have worked on very diverse areas including web server technologies, cloud infrastructure and applications, and, UI.
- I've made contributions to several projects using technologies such as NodeJS, docker, and maven in my free time. I also have a very fair understanding of data science by working on multiple college projects.
link: "/work"
linkTitle: Work Profile
diff --git a/src/content/volunteering.yml b/src/content/volunteering.yml
index dbe1087..a10d9f6 100644
--- a/src/content/volunteering.yml
+++ b/src/content/volunteering.yml
@@ -11,6 +11,7 @@ data:
- |
Anybody can enter a url into our site and verify if it is blocked by any ISP in India.
imageUrl: /vol/software-developer.png
+# imageUrl: /vol/software.png
- position: Teacher, Volunteer recruiter
org:
name: eVidyaloka
diff --git a/src/pages/homePage.jsx b/src/pages/homePage.jsx
index c69d912..85c4d3a 100644
--- a/src/pages/homePage.jsx
+++ b/src/pages/homePage.jsx
@@ -16,6 +16,7 @@ import {
} from "@mui/material/styles";
import {WorkOutline as WorkIcon, VolunteerActivismOutlined as VolunteerIcon} from "@mui/icons-material";
import {fetchDataAndUpdateItems} from "../commons/commons";
+import {capitalizeFirstLetter, replacePlaceHolders} from "../commons/helpers";
// import { green, purple, grey } from '@mui/material/colors';
const StyledBox = styled(Grid)(({ theme }) => ({
@@ -97,6 +98,9 @@ const itemIconMap = {
}
const HomePage = () => {
+ const placeHoldersMap = new Map()
+ placeHoldersMap.set('Number_of_years',
+ numberInWords[new Date().getFullYear() - new Date(2018, 6, 25).getFullYear()])
const [data, setData] = React.useState()
React.useEffect(fetchDataAndUpdateItems(homePageFile, setData), [])
return (
@@ -107,10 +111,11 @@ const HomePage = () => {
data.mainItems.map((item, i) =>
replacePlaceHolders(line, placeHoldersMap))}
+ // text={item.text}
icon={itemIconMap[item.key]} />
)
}
@@ -143,4 +148,5 @@ const HomePage = () => {
)
}
+const numberInWords = ['', 'one', 'Two', 'Three', 'Four', 'Five', 'six', 'seven', 'eight', 'nine']
export default HomePage
\ No newline at end of file