From 5f6496b3be9e65825a6596028972a109accade66 Mon Sep 17 00:00:00 2001 From: CarlosSanabriaM Date: Fri, 8 Nov 2024 15:30:31 +0100 Subject: [PATCH] feat: list multiple jobs within a company in same tab --- exampleSite/config.yaml | 113 +++++++++++----------- layouts/partials/sections/experience.html | 91 ++++------------- 2 files changed, 77 insertions(+), 127 deletions(-) diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 547c89426..9d7ddbf64 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -175,66 +175,65 @@ params: experience: enable: true # title: "Custom Name" - items: - - job: "Senior Software Developer" - company: "Facebook" - companyUrl: "https://example.com" - date: "Jan 2022 - present" - featuredLink: - enable: true - name: "View the project" - url: "https://example.com" - content: "I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city." - - - job: "Software Developer" - company: "Amazon" + companies: + - company: "Facebook" companyUrl: "https://example.com" - date: "Sep 2020 - Dec 2021" - featuredLink: - enable: true - url: "https://example.com" - info: - enable: true - content: I worked as a software developer for more than one year in Amazon. - content: | - I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. - - - Lead backend developer for a product. - - Created a frontend design for a product. - - - job: "Junior Software Developer" - company: "Apple" + jobs: + - job: "Senior Software Developer" + date: "Jan 2022 - present" + featuredLink: + enable: true + name: "View the project" + url: "https://example.com" + content: "I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city." + + - job: "Software Developer" + date: "Sep 2020 - Dec 2021" + featuredLink: + enable: true + url: "https://example.com" + info: + enable: true + content: I worked as a software developer for more than one year in Facebook. + content: | + I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. + + - Lead backend developer for a product. + - Created a frontend design for a product. + - company: "Apple" companyUrl: "https://example.com" - date: "Jan 2020 - Aug 2020" - info: - enable: false - featuredLink: - enable: true - url: "https://example.com" - content: | - I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. - - - Lead backend developer for a product. - - Created a frontend design for a product. - - - job: "UI/UX Designer" - company: "Netflix" - companyUrl: "https://example.com" - date: "June 2017 - Nov 2019" - featuredLink: - enable: true - url: "https://example.com" - content: | - I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. - - - Lead backend developer for a product. - - Created a frontend design for a product. - - - job: "Product Designer" - company: "Google" + jobs: + - job: "Junior Software Developer" + company: "Apple" + companyUrl: "https://example.com" + date: "Jan 2020 - Aug 2020" + info: + enable: false + featuredLink: + enable: true + url: "https://example.com" + content: | + I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. + + - Lead backend developer for a product. + - Created a frontend design for a product. + - company: "Netflix" companyUrl: "https://example.com" - date: "Feb 2016 - Mar 2017" - content: "I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city." + jobs: + - job: "UI/UX Designer" + date: "June 2017 - Nov 2019" + featuredLink: + enable: true + url: "https://example.com" + content: | + I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city. + + - Lead backend developer for a product. + - Created a frontend design for a product. + + - job: "Product Designer" + date: "Feb 2016 - Mar 2017" + content: "I am currently working as a software developer at [example org.](https://example.com) in San Francisco, CA. I am currently working on a project that will be used to help people find the best way to get around the city." # Education education: diff --git a/layouts/partials/sections/experience.html b/layouts/partials/sections/experience.html index f9c2d13dd..e11d3ee91 100644 --- a/layouts/partials/sections/experience.html +++ b/layouts/partials/sections/experience.html @@ -6,60 +6,49 @@

{{ .Site.Params.experience.title | default "Experience"
- {{ range $index, $element := .Site.Params.experience.items }} - {{ if (eq $index 0) }} + {{ range $indexCompany, $company := .Site.Params.experience.companies }} + {{ $sanitizedCompany := replace .company " " "-" }}
+ {{ range $indexJob, $job := .jobs }} +
{{ .job }} - - {{ .company }} + {{ $company.company }} +
{{ .date }} {{ if .info.enable | default true }} + {{ $jobStatus := cond (eq $indexJob 0) "Working" "Worked" }} @@ -76,51 +65,13 @@

{{ .Site.Params.experience.title | default "Experience" {{ end }}

- {{ .content | markdownify}} -
- {{ else }} -
-
- {{ .job }} - - - {{ .company }} - -
- {{ .date }} - {{ if .info.enable | default true }} - - - - - - {{ end }} -
- - {{ if .featuredLink.enable | default false }} - - {{ end }} -
-
{{ .content | markdownify}}
+
+ {{ end }}
{{ end }} - {{ end }}