From 46b21e028c0a183ac1a7db40a9cd6479e7eafc22 Mon Sep 17 00:00:00 2001 From: Hugo MARTIN Date: Sat, 3 Oct 2020 05:59:28 +0200 Subject: [PATCH] Translations and i18n (#60) * Managing i18n * Fix absolute path * Config files * Home link manage langage * Fixing footer i18n * Implemented i18n on newsletter * Implemented two languages in example * Removed old section directory * Using yaml in data to organize home summary * Fully working for old versions without i18n * Integrating language menu CSS * Fix language dropdown CSS * Refactor translation codes * Remove duplicate code * Fix URL issues * Move customMenus and other site related config into data section * Fix error during language toggle * Only show the available translation for the posts * Handle navbar brand URL properly * Fix responsiveness Co-authored-by: Hugo MARTIN Co-authored-by: hossainemruz --- exampleSite/config.yaml | 50 +++++------- exampleSite/data/bn/author.yaml | 16 ++++ exampleSite/data/bn/sections/about.yaml | 77 +++++++++++++++++++ .../data/bn/sections/achievements.yaml | 24 ++++++ exampleSite/data/bn/sections/experiences.yaml | 64 +++++++++++++++ exampleSite/data/bn/sections/projects.yaml | 64 +++++++++++++++ .../data/bn/sections/recent-posts.yaml | 11 +++ exampleSite/data/bn/sections/skills.yaml | 49 ++++++++++++ exampleSite/data/bn/site.yaml | 11 +++ exampleSite/data/en/author.yaml | 18 +++++ exampleSite/data/{ => en}/sections/about.yaml | 1 + .../data/{ => en}/sections/achievements.yaml | 0 .../data/{ => en}/sections/experiences.yaml | 0 .../data/{ => en}/sections/projects.yaml | 0 .../data/{ => en}/sections/recent-posts.yaml | 0 .../data/{ => en}/sections/skills.yaml | 0 exampleSite/data/en/site.yaml | 11 +++ exampleSite/data/fr/author.yaml | 19 +++++ exampleSite/data/fr/sections/about.yaml | 77 +++++++++++++++++++ .../data/fr/sections/achievements.yaml | 24 ++++++ exampleSite/data/fr/sections/experiences.yaml | 64 +++++++++++++++ exampleSite/data/fr/sections/projects.yaml | 64 +++++++++++++++ .../data/fr/sections/recent-posts.yaml | 11 +++ exampleSite/data/fr/sections/skills.yaml | 49 ++++++++++++ exampleSite/data/fr/site.yaml | 11 +++ i18n/bn.toml | 30 ++++++++ i18n/en.toml | 30 ++++++++ i18n/fr.toml | 30 ++++++++ layouts/_default/list.html | 7 +- layouts/_default/single.html | 5 +- layouts/index.html | 9 ++- layouts/partials/cards/post.html | 4 +- layouts/partials/cards/project.html | 2 +- layouts/partials/cards/skill.html | 2 +- layouts/partials/footer.html | 42 +++++++--- layouts/partials/header.html | 2 +- layouts/partials/helpers/country-code.html | 13 ++++ .../navigators/floating-lang-selector.html | 19 +++++ .../partials/navigators/lang-selector-2.html | 19 +++++ .../partials/navigators/lang-selector.html | 14 ++++ layouts/partials/navigators/navbar-2.html | 30 ++++---- layouts/partials/navigators/navbar.html | 43 +++++++---- layouts/partials/navigators/sidebar.html | 4 +- layouts/partials/scripts.html | 1 + layouts/partials/sections/about.html | 4 +- .../partials/sections/achievements/entry.html | 2 +- layouts/partials/sections/home.html | 47 +++++++---- package-lock.json | 70 ++++++++--------- package.json | 2 +- static/assets/css/layouts/list.css | 7 ++ static/assets/css/layouts/main.css | 10 ++- static/assets/css/layouts/single.css | 3 + static/assets/css/navigators/navbar.css | 58 ++++++++++---- static/assets/css/sections/home.css | 3 +- static/assets/js/main.js | 74 +++++++++--------- static/assets/js/popper.min.js | 5 ++ 56 files changed, 1116 insertions(+), 190 deletions(-) create mode 100644 exampleSite/data/bn/author.yaml create mode 100644 exampleSite/data/bn/sections/about.yaml create mode 100644 exampleSite/data/bn/sections/achievements.yaml create mode 100644 exampleSite/data/bn/sections/experiences.yaml create mode 100644 exampleSite/data/bn/sections/projects.yaml create mode 100644 exampleSite/data/bn/sections/recent-posts.yaml create mode 100644 exampleSite/data/bn/sections/skills.yaml create mode 100644 exampleSite/data/bn/site.yaml create mode 100644 exampleSite/data/en/author.yaml rename exampleSite/data/{ => en}/sections/about.yaml (98%) rename exampleSite/data/{ => en}/sections/achievements.yaml (100%) rename exampleSite/data/{ => en}/sections/experiences.yaml (100%) rename exampleSite/data/{ => en}/sections/projects.yaml (100%) rename exampleSite/data/{ => en}/sections/recent-posts.yaml (100%) rename exampleSite/data/{ => en}/sections/skills.yaml (100%) create mode 100644 exampleSite/data/en/site.yaml create mode 100644 exampleSite/data/fr/author.yaml create mode 100644 exampleSite/data/fr/sections/about.yaml create mode 100644 exampleSite/data/fr/sections/achievements.yaml create mode 100644 exampleSite/data/fr/sections/experiences.yaml create mode 100644 exampleSite/data/fr/sections/projects.yaml create mode 100644 exampleSite/data/fr/sections/recent-posts.yaml create mode 100644 exampleSite/data/fr/sections/skills.yaml create mode 100644 exampleSite/data/fr/site.yaml create mode 100644 i18n/bn.toml create mode 100644 i18n/en.toml create mode 100644 i18n/fr.toml create mode 100644 layouts/partials/helpers/country-code.html create mode 100644 layouts/partials/navigators/floating-lang-selector.html create mode 100644 layouts/partials/navigators/lang-selector-2.html create mode 100644 layouts/partials/navigators/lang-selector.html create mode 100644 static/assets/js/popper.min.js diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index a268aed2a..784f6b7ef 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -3,6 +3,21 @@ languageCode: en-us title: "Toha" theme: "toha" +# Manage languages +# For any more details, you can check the official documentation: https://gohugo.io/content-management/multilingual/ +languages: + en: + languageName: English + weight: 1 + fr: + languageName: Français + weight: 2 + bn: + languageName: বাংলা + weight: 3 +# Force a locale to be use, really useful to develop the application ! Should be commented in production, the "weight" should rocks. +#DefaultContentLanguage: fr + # Allow raw html in markdown file markup: goldmark: @@ -24,12 +39,6 @@ enableEmoji: true # Custom parameters params: - # Copyright Notice - copyright: © 2020 Copyright. - - # Meta description for your site. This will help the search engines to find your site. - description: Portfolio and personal blog of Jane Doe. - # background image of the landing page background: "images/background.jpg" @@ -37,9 +46,9 @@ params: # transparent navbar and the main logo will be used in the non-transparent navbar. # It will be default to the theme logos if not provided. logo: - main: /assets/images/main-logo.png - inverted: /assets/images/inverted-logo.png - favicon: /assets/images/favicon.png + main: assets/images/main-logo.png + inverted: assets/images/inverted-logo.png + favicon: assets/images/favicon.png # GitHub repo URL of your site gitRepo: https://github.com/hossainemruz/toha-example-site @@ -50,30 +59,7 @@ params: # specify whether you want to show Table of Contents in reading page enableTOC: true - # specify the list of custom menus that you want to show in the top navbar. - # they will be separated by a divider from the main menus. - customMenus: - - name: Notes - url: https://hossainnotes.netlify.app/docs/example/ - # Provide newsletter configuration. This feature hasn't been implemented yet. # Currently, you can just hide it from the footer. newsletter: enable: true - - # some information about you - author: - name: "Jane Doe" - nickname: "Jane" - image: "images/avatar.png" - # greeting message before your name. it will default to "Hi! I am" if not provided - greeting: "Hi, I am" - # give your some contact information. they will be used in the footer - contactInfo: - email: "janedoe@example.com" - phone: "+0123456789" - # a summary of what you do - summary: - - I am a Developer - - I work with Go - - I love to work with some fun projects diff --git a/exampleSite/data/bn/author.yaml b/exampleSite/data/bn/author.yaml new file mode 100644 index 000000000..815fc21e9 --- /dev/null +++ b/exampleSite/data/bn/author.yaml @@ -0,0 +1,16 @@ +# some information about you +name: "জেইন ডো" +nickname: "জেইন" +# greeting message before your name. it will default to "Hi! I am" if not provided +greeting: "হ্যালো, আমি হলাম" +image: "images/avatar.png" +# give your some contact information. they will be used in the footer +contactInfo: + email: "janedoe@example.com" + phone: "+0123456789" + +# some summary about what you do +summary: + - আমি একজন ডেভেলপার + - আমি ওপেন সোর্স প্রোজেক্ট এ কাজ করতে পছন্দ করি + - আমি মজার কিছু প্রোজেক্ট এ কাজ করতে ভালবাসি diff --git a/exampleSite/data/bn/sections/about.yaml b/exampleSite/data/bn/sections/about.yaml new file mode 100644 index 000000000..e6951073a --- /dev/null +++ b/exampleSite/data/bn/sections/about.yaml @@ -0,0 +1,77 @@ +# section information +section: + name: আমার-সম্পর্কে + enable: true + weight: 1 + showOnNavbar: true + template: sections/about.html + +# your designation +designation: Software Engineer +# your company information +company: + name: Example Co. + url: "https://www.example.com" + +# your resume. this file path should be relative to you "static" directory +resume: "files/resume.pdf" + +# a summary about you +summary: 'I am a passionate software engineer with x years of working experience. I built OSS tools for [Kubernetes](https://kubernetes.io/) using GO. My tools help people to deploy their workloads in Kubernetes. Sometimes, I work on some fun projects such as writing a theme, etc.' + +# your social links +# give as many as you want. use font-awesome for the icons. +socialLinks: +- name: Email + icon: "fas fa-envelope" + url: "example@gmail.com" + +- name: Github + icon: "fab fa-github" + url: "https://www.github.com/example" + +- name: Stackoverflow + icon: "fab fa-stack-overflow" + url: "#" + +- name: LinkedIn + icon: "fab fa-linkedin" + url: "#" + +- name: Twitter + icon: "fab fa-twitter" + url: "#" + +- name: Facebook + icon: "fab fa-facebook" + url: "#" + +# your soft skills +# give the percentage between 50 to 100 with 5 intervals. +# currently supported colors: blue, yellow, pink, green, sky, orange +softSkills: +- name: Leadership + percentage: 85 + color: blue +- name: Team Work + percentage: 90 + color: yellow +- name: Communication + percentage: 85 + color: pink +- name: Hard Working + percentage: 85 + color: green +- name: Fast Learner + percentage: 85 + color: sky +- name: Problem Solving + percentage: 85 + color: orange +# you can also provide color code instead of pre-defined color name +# - name: Example 1 +# percentage: 75 +# color: "#00adb5" +# - name: Example 2 +# percentage: 65 +# color: "#8b8383" diff --git a/exampleSite/data/bn/sections/achievements.yaml b/exampleSite/data/bn/sections/achievements.yaml new file mode 100644 index 000000000..0d2055010 --- /dev/null +++ b/exampleSite/data/bn/sections/achievements.yaml @@ -0,0 +1,24 @@ +# section information +section: + name: সাফল্য + enable: true + weight: 6 + showOnNavbar: true + template: sections/achievements.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your achievements achievements +achievements: +- title: Best Presenter + image: images/achievements/presenter.jpg + summary: Best presenter in the 2020 XYZ conference. +- title: Champion + image: images/achievements/sport.jpg + summary: Champion in cycling inter-city cycling championship 2020. +- title: Graduation + image: images/achievements/graduation-cap.jpg + summary: Received Bachelor of Science (B.Sc.) in Computer Science and Engineer from XYZ University. +- title: Award Winner + image: images/achievements/woman-winner.jpg + summary: Lorem ipsum dolor sit amet consectetur adipisicing elit. Possimus architecto minus facere vero? diff --git a/exampleSite/data/bn/sections/experiences.yaml b/exampleSite/data/bn/sections/experiences.yaml new file mode 100644 index 000000000..f4ace2871 --- /dev/null +++ b/exampleSite/data/bn/sections/experiences.yaml @@ -0,0 +1,64 @@ +# section information +section: + name: অভিজ্ঞতা + enable: true + weight: 3 + showOnNavbar: true + template: sections/experiences.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your experiences +experiences: +- company: + name: Example Co. + url: "https://www.example.com" + location: Dhaka Branch + # company overview + overview: Example Co. is a widely recognized company for cloud-native development. It builds tools for Kubernetes. + positions: + - designation: Senior Software Engineer + start: Nov 2019 + # don't provide end date if you are currently working there. It will be replaced by "Present" + # end: Dec 2020 + # give some points about what was your responsibilities at the company. + responsibilities: + - Design and develop XYZ tool for ABC task + - Design, develop and manage disaster recovery tool [Xtool](https://www.example.com) that backup Kubernetes volumes, databases, and cluster's resource definition. + - Lead backend team. + + - designation: Junior Software Engineer + start: Nov 2017 + end: Oct 2019 + responsibilities: + - Implement and test xyz feature for abc tool. + - Support client for abc tool. + - Learn k,d,w technology for xyz. + +- company: + name: PreExample Co. + url: "https://www.preexample.com" + location: Nowhere + overview: PreExample Co. is a gateway company to enter into Example co. So, nothing special here. + positions: + - designation: Software Engineer + start: March 2016 + end: May 2017 + responsibilities: + - Write lots of example codes. + - Read lots of examples. + - See lots of example videos. + +- company: + name: Intern Counting Company (ICC). + url: "https://www.intern.com" + location: Intern Land + overview: Intern counting Company (ICC) is responsible for counting worldwide intern Engineers. + positions: + - designation: Intern + start: Jun 2015 + end: Jan 2016 + responsibilities: + - Count lost of interns. + - Count more interns. + - Count me as an intern. diff --git a/exampleSite/data/bn/sections/projects.yaml b/exampleSite/data/bn/sections/projects.yaml new file mode 100644 index 000000000..6e39f275d --- /dev/null +++ b/exampleSite/data/bn/sections/projects.yaml @@ -0,0 +1,64 @@ +# section information +section: + name: প্রোজেক্ট + enable: true + weight: 4 + showOnNavbar: true + template: sections/projects.html + # Can optionally hide the title in sections + # hideTitle: true + +# filter buttons +buttons: +- name: All + filter: "all" +- name: Professional + filter: "professional" +- name: Academic + filter: "academic" +- name: Hobby + filter: "hobby" + +# your projects +projects: +- name: Kubernetes + logo: images/projects/kubernetes.png + role: Contributor + timeline: "March 2018 - Present" + repo: https://github.com/kubernetes/kubernetes # If your project is a public repo on GitHub, then provide this link. it will show star count. + #url: "" # If your project is not a public repo but it has a website or any external details url then provide it here. don't provide "repo" and "url" simultaneously. + summary: Production-Grade Container Scheduling and Management. + tags: ["professional", "kubernetes", "cloud"] + +- name: Tensorflow + logo: images/projects/tensorflow.png + role: Developer + timeline: "Jun 2018 - Present" + repo: https://github.com/tensorflow/tensorflow + #url: "" + summary: An Open Source Machine Learning Framework for Everyone. + tags: ["professional", "machine-learning","academic"] + +- name: A sample academic paper + role: Team Lead + timeline: "Jan 2017 - Nov 2017" + url: "https://www.example.com" + summary: Lorem ipsum dolor sit amet consectetur adipisicing elit. Sapiente eius reprehenderit animi suscipit autem eligendi esse amet aliquid error eum. Accusantium distinctio soluta aliquid quas placeat modi suscipit eligendi nisi. + tags: ["academic","iot"] + +- name: Nocode + logo: images/projects/no-code.png + role: Nothing + timeline: "Oct 2019 - Dec 2019" + repo: https://github.com/kelseyhightower/nocode + #url: "" + summary: The best way to write secure and reliable applications. Write nothing; deploy nowhere. + tags: ["hobby", "fun"] + +- name: Toha + logo: images/projects/toha.png + role: Owner + timeline: "Jun 2019 - Present" + repo: https://github.com/hossainemruz/toha + summary: A Hugo theme for personal portfolio. + tags: ["hobby","hugo","theme","professional"] diff --git a/exampleSite/data/bn/sections/recent-posts.yaml b/exampleSite/data/bn/sections/recent-posts.yaml new file mode 100644 index 000000000..4fd6f61ac --- /dev/null +++ b/exampleSite/data/bn/sections/recent-posts.yaml @@ -0,0 +1,11 @@ +# section information +section: + name: সাম্প্রতিক-পোস্ট + enable: true + weight: 5 + showOnNavbar: true + template: sections/recent-posts.html + # Can optionally hide the title in sections + # hideTitle: true + +# no additional configuration is required diff --git a/exampleSite/data/bn/sections/skills.yaml b/exampleSite/data/bn/sections/skills.yaml new file mode 100644 index 000000000..8e166bedd --- /dev/null +++ b/exampleSite/data/bn/sections/skills.yaml @@ -0,0 +1,49 @@ +# section information +section: + name: দক্ষতা + enable: true + weight: 2 + showOnNavbar: true + template: sections/skills.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your Skills. +# Give a summary of you each skill in the summary section. +skills: +- name: Kubernetes + icon: "images/skills/kubernetes.png" + summary: "Capable of deploying, managing application on Kubernetes. Experienced in writing Kubernetes controllers for CRDs." + url: "https://kubernetes.io/" + +- name: Go Development + icon: "images/skills/go.png" + summary: "Using as the main language for professional development. Capable of writing scalable, testable, and maintainable program." + url: "https://golang.org/" + +- name: Cloud Computing + icon: "images/skills/cloud.png" + summary: "Worked with most of the major clouds such as GCP, AWS, Azure etc." + +- name: Docker + icon: "images/skills/docker.svg" + summary: "Write most of the programs as dockerized container. Experienced with multi-stage, multi-arch build process." + url: "https://www.docker.com/" + +- name: Prometheus + icon: "images/skills/prometheus.png" + summary: "Capable of setup, configure Prometheus metrics. Experienced with PromQL, AlertManager. Also, experienced with writing metric exporters." + url: "https://prometheus.io/" + +- name: Linux + icon: "images/skills/linux.png" + summary: "Using as the main operating system. Capable of writing bash/shell scripts." + +- name: Git + icon: "images/skills/git.png" + summary: "Experienced with git-based development. Mostly, use Github. Also, have experience in working with GitLab." + url: "https://git-scm.com/" + +- name: C++ + icon: "images/skills/c++.png" + summary: "Know basic C/C++ programming. Used for contest programming and problem solving." diff --git a/exampleSite/data/bn/site.yaml b/exampleSite/data/bn/site.yaml new file mode 100644 index 000000000..486805e0a --- /dev/null +++ b/exampleSite/data/bn/site.yaml @@ -0,0 +1,11 @@ +# Copyright Notice +copyright: © 2020 Copyright. + +# Meta description for your site. This will help the search engines to find your site. +description: Portfolio and personal blog of Jane Doe. + +# specify the list of custom menus that you want to show in the top navbar. +# they will be separated by a divider from the main menus. +customMenus: +- name: নোটসমুহ + url: https://hossainemruz.gitbook.io/ diff --git a/exampleSite/data/en/author.yaml b/exampleSite/data/en/author.yaml new file mode 100644 index 000000000..57a704fd0 --- /dev/null +++ b/exampleSite/data/en/author.yaml @@ -0,0 +1,18 @@ +# some information about you +name: "Jane Doe" +nickname: "Jane" +# greeting message before your name. it will default to "Hi! I am" if not provided +greeting: "Hi, I am" +image: "images/avatar.png" +# give your some contact information. they will be used in the footer +contactInfo: + email: "janedoe@example.com" + phone: "+0123456789" + +# some summary about what you do +summary: + - I am a Developer + - I am a Devops + - I love servers + - I work on open-source projects + - I love to work with some fun projects diff --git a/exampleSite/data/sections/about.yaml b/exampleSite/data/en/sections/about.yaml similarity index 98% rename from exampleSite/data/sections/about.yaml rename to exampleSite/data/en/sections/about.yaml index 048bff187..4ef5ee0bd 100644 --- a/exampleSite/data/sections/about.yaml +++ b/exampleSite/data/en/sections/about.yaml @@ -4,6 +4,7 @@ section: enable: true weight: 1 showOnNavbar: true + template: sections/about.html # your designation designation: Software Engineer diff --git a/exampleSite/data/sections/achievements.yaml b/exampleSite/data/en/sections/achievements.yaml similarity index 100% rename from exampleSite/data/sections/achievements.yaml rename to exampleSite/data/en/sections/achievements.yaml diff --git a/exampleSite/data/sections/experiences.yaml b/exampleSite/data/en/sections/experiences.yaml similarity index 100% rename from exampleSite/data/sections/experiences.yaml rename to exampleSite/data/en/sections/experiences.yaml diff --git a/exampleSite/data/sections/projects.yaml b/exampleSite/data/en/sections/projects.yaml similarity index 100% rename from exampleSite/data/sections/projects.yaml rename to exampleSite/data/en/sections/projects.yaml diff --git a/exampleSite/data/sections/recent-posts.yaml b/exampleSite/data/en/sections/recent-posts.yaml similarity index 100% rename from exampleSite/data/sections/recent-posts.yaml rename to exampleSite/data/en/sections/recent-posts.yaml diff --git a/exampleSite/data/sections/skills.yaml b/exampleSite/data/en/sections/skills.yaml similarity index 100% rename from exampleSite/data/sections/skills.yaml rename to exampleSite/data/en/sections/skills.yaml diff --git a/exampleSite/data/en/site.yaml b/exampleSite/data/en/site.yaml new file mode 100644 index 000000000..651271005 --- /dev/null +++ b/exampleSite/data/en/site.yaml @@ -0,0 +1,11 @@ +# Copyright Notice +copyright: © 2020 Copyright. + +# Meta description for your site. This will help the search engines to find your site. +description: Portfolio and personal blog of Jane Doe. + +# specify the list of custom menus that you want to show in the top navbar. +# they will be separated by a divider from the main menus. +customMenus: +- name: Notes + url: https://hossainemruz.gitbook.io/ diff --git a/exampleSite/data/fr/author.yaml b/exampleSite/data/fr/author.yaml new file mode 100644 index 000000000..d55c4f314 --- /dev/null +++ b/exampleSite/data/fr/author.yaml @@ -0,0 +1,19 @@ +name: "Jane Doe" +nickname: "Jane" +image: "images/avatar.png" + +# greeting message before your name. it will default to "Hi! I am" if not provided +greeting: "Bonjour, je suis" + +# give your some contact information. they will be used in the footer +contactInfo: + email: "janedoe@example.com" + phone: "+0123456789" + +# some summary about what you do +summary: + - Je suis un développeur + - Je suis un Devops + - J'aime les serveurs + - Je travaille sur des projets open-source + - J'aime travailler avec des projets amusants diff --git a/exampleSite/data/fr/sections/about.yaml b/exampleSite/data/fr/sections/about.yaml new file mode 100644 index 000000000..0fc0f7d23 --- /dev/null +++ b/exampleSite/data/fr/sections/about.yaml @@ -0,0 +1,77 @@ +# section information +section: + name: "A propos" + enable: true + weight: 1 + showOnNavbar: true + template: sections/about.html + +# your designation +designation: "Développeur logiciel" +# your company information +company: + name: Example Co. + url: "https://www.example.com" + +# your resume. this file path should be relative to you "static" directory +resume: "files/resume.pdf" + +# a summary about you +summary: "Je suis un ingénieur en logiciel passionné, avec x années d'expérience professionnelle. J'ai construit des outils OSS pour [Kubernetes](https://kubernetes.io/) en utilisant GO. Mes outils aident les gens à déployer leurs charges de travail dans Kubernetes. Parfois, je travaille sur des projets amusants comme l'écriture d'un thème, etc." + +# your social links +# give as many as you want. use font-awesome for the icons. +socialLinks: +- name: Email + icon: "fas fa-envelope" + url: "example@gmail.com" + +- name: Github + icon: "fab fa-github" + url: "https://www.github.com/example" + +- name: Stackoverflow + icon: "fab fa-stack-overflow" + url: "#" + +- name: LinkedIn + icon: "fab fa-linkedin" + url: "#" + +- name: Twitter + icon: "fab fa-twitter" + url: "#" + +- name: Facebook + icon: "fab fa-facebook" + url: "#" + +# your soft skills +# give the percentage between 50 to 100 with 5 intervals. +# currently supported colors: blue, yellow, pink, green, sky, orange +softSkills: +- name: Chef de projet + percentage: 85 + color: blue +- name: Travail d'équipe + percentage: 90 + color: yellow +- name: Communication + percentage: 85 + color: pink +- name: Persévérant + percentage: 85 + color: green +- name: Autonome + percentage: 85 + color: sky +- name: Logique + percentage: 85 + color: orange +# you can also provide color code instead of pre-defined color name +# - name: Example 1 +# percentage: 75 +# color: "#00adb5" +# - name: Example 2 +# percentage: 65 +# color: "#8b8383" diff --git a/exampleSite/data/fr/sections/achievements.yaml b/exampleSite/data/fr/sections/achievements.yaml new file mode 100644 index 000000000..baec23f09 --- /dev/null +++ b/exampleSite/data/fr/sections/achievements.yaml @@ -0,0 +1,24 @@ +# section information +section: + name: Realisations + enable: true + weight: 6 + showOnNavbar: true + template: sections/achievements.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your achievements achievements +achievements: +- title: Meilleur présentateur + image: images/achievements/presenter.jpg + summary: Meilleur présentateur de la conférence XYZ 2020. +- title: Champion + image: images/achievements/sport.jpg + summary: Champion du championnat cycliste interurbain 2020. +- title: Remise des diplômes + image: images/achievements/graduation-cap.jpg + summary: J'ai obtenu une licence en sciences (B.Sc.) en informatique et en ingénierie à l'université XYZ. +- title: Lauréat du prix + image: images/achievements/woman-winner.jpg + summary: Lorem ipsum dolor sit amet consectetur adipisicing elit. Possimus architecto minus facere vero? diff --git a/exampleSite/data/fr/sections/experiences.yaml b/exampleSite/data/fr/sections/experiences.yaml new file mode 100644 index 000000000..f9e82d201 --- /dev/null +++ b/exampleSite/data/fr/sections/experiences.yaml @@ -0,0 +1,64 @@ +# section information +section: + name: Experiences + enable: true + weight: 3 + showOnNavbar: true + template: sections/experiences.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your experiences +experiences: +- company: + name: Example Co. + url: "https://www.example.com" + location: Dhaka Branch + # company overview + overview: Example Co. est une entreprise largement reconnue pour le développement de l'utilisation des nuages. Elle construit des outils pour Kubernetes. + positions: + - designation: Ingénieur logiciel senior + start: Nov 2019 + # don't provide end date if you are currently working there. It will be replaced by "Present" + # end: Dec 2020 + # give some points about what was your responsibilities at the company. + responsibilities: + - Concevoir et développer l'outil XYZ pour la tâche ABC. + - Concevoir, développer et gérer l'outil de reprise après sinistre [Xtool](https://www.example.com) qui sauvegarde les volumes, les bases de données et la définition des ressources du cluster de Kubernetes. + - Diriger l'équipe de soutien. + + - designation: Ingénieur logiciel junior + start: Nov 2017 + end: Oct 2019 + responsibilities: + - Implémenter et tester la fonction xyz pour l'outil abc. + - Support client pour abc tool. + - Apprendre la technologie k,d,w pour xyz. + +- company: + name: PreExample Co. + url: "https://www.preexample.com" + location: Nowhere + overview: PreExample Co. est une société passerelle pour entrer dans Example co. Donc, rien de spécial ici. + positions: + - designation: Ingénieur logiciel + start: Mars 2016 + end: Mai 2017 + responsibilities: + - Rédigez de nombreux exemples de codes. + - Lire de nombreux exemples. + - Voir de nombreux exemples de vidéos. + +- company: + name: Intern Counting Company (ICC). + url: "https://www.intern.com" + location: Intern Land + overview: La Compagnie de comptage des stagiaires (ICC) est responsable du comptage des ingénieurs stagiaires du monde entier. + positions: + - designation: Stagiaire + start: Juin 2015 + end: Jan 2016 + responsibilities: + - Compte perdu des stagiaires. + - Comptez plus de stagiaires. + - Comptez-moi comme un stagiaire. \ No newline at end of file diff --git a/exampleSite/data/fr/sections/projects.yaml b/exampleSite/data/fr/sections/projects.yaml new file mode 100644 index 000000000..664642172 --- /dev/null +++ b/exampleSite/data/fr/sections/projects.yaml @@ -0,0 +1,64 @@ +# section information +section: + name: Projets + enable: true + weight: 4 + showOnNavbar: true + template: sections/projects.html + # Can optionally hide the title in sections + # hideTitle: true + +# filter buttons +buttons: +- name: All + filter: "all" +- name: Professionnel + filter: "professionnel" +- name: Ecole + filter: "ecole" +- name: Hobby + filter: "hobby" + +# your projects +projects: +- name: Kubernetes + logo: images/projects/kubernetes.png + role: Contributeur + timeline: "Mars 2018 - Présent" + repo: https://github.com/kubernetes/kubernetes # If your project is a public repo on GitHub, then provide this link. it will show star count. + #url: "" # If your project is not a public repo but it has a website or any external details url then provide it here. don't provide "repo" and "url" simultaneously. + summary: Planification et gestion des conteneurs de qualité production. + tags: ["professionnel", "kubernetes", "cloud"] + +- name: Tensorflow + logo: images/projects/tensorflow.png + role: Développeur + timeline: "Juin 2018 - Présent" + repo: https://github.com/tensorflow/tensorflow + #url: "" + summary: Un cadre d'apprentissage machine à source ouverte pour tous. + tags: ["professionnel", "machine-learning","ecole"] + +- name: Un exemple d'article académique + role: Chef d'équipe + timeline: "Janvier 2017 - Novembre 2017" + url: "https://www.example.com" + summary: Lorem ipsum dolor sit amet consectetur adipisicing elit. Sapiente eius reprehenderit animi suscipit autem eligendi esse amet aliquid error eum. Accusantium distinctio soluta aliquid quas placeat modi suscipit eligendi nisi. + tags: ["ecole","iot"] + +- name: Nocode + logo: images/projects/no-code.png + role: Rien + timeline: "Oct 2019 - Dec 2019" + repo: https://github.com/kelseyhightower/nocode + #url: "" + summary: La meilleure façon de rédiger des demandes sûres et fiables. N'écrivez rien, ne déployez rien. + tags: ["hobby", "fun"] + +- name: Toha + logo: images/projects/toha.png + role: Owner + timeline: "Juin 2019 - Présent" + repo: https://github.com/hossainemruz/toha + summary: Un thème Hugo pour le portfolio personnel. + tags: ["hobby","hugo","theme","professionnel"] diff --git a/exampleSite/data/fr/sections/recent-posts.yaml b/exampleSite/data/fr/sections/recent-posts.yaml new file mode 100644 index 000000000..0f267164c --- /dev/null +++ b/exampleSite/data/fr/sections/recent-posts.yaml @@ -0,0 +1,11 @@ +# section information +section: + name: Posts recents + enable: true + weight: 5 + showOnNavbar: true + template: sections/recent-posts.html + # Can optionally hide the title in sections + # hideTitle: true + +# no additional configuration is required diff --git a/exampleSite/data/fr/sections/skills.yaml b/exampleSite/data/fr/sections/skills.yaml new file mode 100644 index 000000000..60b6fbec9 --- /dev/null +++ b/exampleSite/data/fr/sections/skills.yaml @@ -0,0 +1,49 @@ +# section information +section: + name: Competences + enable: true + weight: 2 + showOnNavbar: true + template: sections/skills.html + # Can optionally hide the title in sections + # hideTitle: true + +# Your Skills. +# Give a summary of you each skill in the summary section. +skills: +- name: Kubernetes + icon: "images/skills/kubernetes.png" + summary: "Capable de déployer, de gérer l'application sur Kubernetes. Expérimenté dans la rédaction de contrôleurs Kubernetes pour les CRD." + url: "https://kubernetes.io/" + +- name: Go + icon: "images/skills/go.png" + summary: "Utiliser comme langue principale pour le développement professionnel. Capable d'écrire des programmes évolutifs, testables et maintenables." + url: "https://golang.org/" + +- name: Cloud Computing + icon: "images/skills/cloud.png" + summary: "A travaillé avec la plupart des principaux nuages tels que GCP, AWS, Azure, etc." + +- name: Docker + icon: "images/skills/docker.svg" + summary: "Inscrivez la plupart des programmes en tant que conteneur déchargé. Expérimenté dans le processus de construction en plusieurs étapes et en plusieurs arcs." + url: "https://www.docker.com/" + +- name: Prometheus + icon: "images/skills/prometheus.png" + summary: "Capable d'installation, de configurer les métriques de Prometheus. Expérimenté avec PromQL, AlertManager. Expérimenté également dans la rédaction d'exportateurs de métriques." + url: "https://prometheus.io/" + +- name: Linux + icon: "images/skills/linux.png" + summary: "Utilisé comme système d'exploitation principal. Capable d'écrire des scripts bash/shell." + +- name: Git + icon: "images/skills/git.png" + summary: "Expérimenté dans le développement basé sur les GIT. Surtout, utilisez Github. Avoir également une expérience de travail avec GitLab." + url: "https://git-scm.com/" + +- name: C++ + icon: "images/skills/c++.png" + summary: "Connaître les bases de la programmation C/C++. Utilisé pour la programmation de concours et la résolution de problèmes." diff --git a/exampleSite/data/fr/site.yaml b/exampleSite/data/fr/site.yaml new file mode 100644 index 000000000..9101f1eab --- /dev/null +++ b/exampleSite/data/fr/site.yaml @@ -0,0 +1,11 @@ +# Copyright Notice +copyright: © 2020 Droits d'auteur. + +# Meta description for your site. This will help the search engines to find your site. +description: Portfolio et blog personnel de Jane Doe. + +# specify the list of custom menus that you want to show in the top navbar. +# they will be separated by a divider from the main menus. +customMenus: +- name: Remarques + url: https://hossainemruz.gitbook.io/ diff --git a/i18n/bn.toml b/i18n/bn.toml new file mode 100644 index 000000000..958f5642e --- /dev/null +++ b/i18n/bn.toml @@ -0,0 +1,30 @@ +# More documentation here: https://github.com/nicksnyder/go-i18n +[home] +other = "হোম" + +[posts] +other = "পোষ্ট সমূহ" + +[resume] +other = "আমার জীবনবৃত্তান্ত" + +[navigation] +other = "নেভিগেশন" + +[contact_me] +other = "আমার সাথে যোগাযোগ করুনঃ" + +[newsletter_text] +other = "ইমেইল নোটিফিকেশান এর মাধ্যমে সর্বশেষ তথ্য জানুন" + +[newsletter_input_placeholder] +other = "ইমেইল প্রবেশ করান" + +[newsletter_warning] +other = "আমরা আপনার ইমেল অন্য কারও সাথে শেয়ার করব না।" + +[submit] +other = "জমা দিন" + +[hugoAttributionText] +other = "পাওয়ারড বাই" diff --git a/i18n/en.toml b/i18n/en.toml new file mode 100644 index 000000000..6a5be72a2 --- /dev/null +++ b/i18n/en.toml @@ -0,0 +1,30 @@ +# More documentation here: https://github.com/nicksnyder/go-i18n +[home] +other = "Home" + +[posts] +other = "Posts" + +[resume] +other = "My resume" + +[navigation] +other = "Navigation" + +[contact_me] +other = "Contact me:" + +[newsletter_text] +other = "Stay up to date with email notification" + +[newsletter_input_placeholder] +other = "Enter email" + +[newsletter_warning] +other = "We'll never share your email with anyone else." + +[submit] +other = "Submit" + +[hugoAttributionText] +other = "Powered by" diff --git a/i18n/fr.toml b/i18n/fr.toml new file mode 100644 index 000000000..7067bdd6e --- /dev/null +++ b/i18n/fr.toml @@ -0,0 +1,30 @@ +# More documentation here: https://github.com/nicksnyder/go-i18n +[home] +other = "Accueil" + +[posts] +other = "Des postes" + +[resume] +other = "Mon Curriculum vitæ" + +[navigation] +other = "Naviguation" + +[contact_me] +other = "Contactez moi :" + +[newsletter_text] +other = "Restez à jour par e-mail" + +[newsletter_input_placeholder] +other = "Entrez une adresse e-mail" + +[newsletter_warning] +other = "Nous ne partagerons jamais votre courriel avec quelqu'un d'autre." + +[submit] +other = "Envoyer" + +[hugoAttributionText] +other = "Alimenté par" diff --git a/layouts/_default/list.html b/layouts/_default/list.html index d2c0bf856..9c188b4f4 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -8,13 +8,18 @@ {{ end }} {{ define "sidebar" }} + {{ $blogHome:="#" }} + {{ if site.IsMultiLingual }} + {{ $blogHome = (path.Join (cond ( eq .Language.Lang "en") "" .Language.Lang) "post") }} + {{ end }} + {{ end }} diff --git a/layouts/index.html b/layouts/index.html index d2de69473..74dd04ec5 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -29,9 +29,14 @@ {{- partial "sections/home.html" . -}} - {{ if .Site.Data.sections }} + {{ $sections:= .Site.Data.sections }} + {{ if (index .Site.Data .Site.Language.Lang).sections }} + {{ $sections = (index .Site.Data .Site.Language.Lang).sections }} + {{ end }} + + {{ if $sections }} {{ $background:= "bg-white"}} - {{ range sort .Site.Data.sections "section.weight" }} + {{ range sort $sections "section.weight" }} {{ if .section.enable }}
{{ if .section.template }} diff --git a/layouts/partials/cards/post.html b/layouts/partials/cards/post.html index 663510b8e..766f9dc20 100644 --- a/layouts/partials/cards/post.html +++ b/layouts/partials/cards/post.html @@ -1,5 +1,5 @@
- +
@@ -11,7 +11,7 @@
{{ .Title }}