From 28017495733c8df05c44c17eecb5c5f2a6f98b27 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 15 Dec 2023 19:19:24 +0600 Subject: [PATCH 01/97] Bump github/codeql-action from 2 to 3 (#849) Bumps [github/codeql-action](https://github.com/github/codeql-action) from 2 to 3. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/github/codeql-action/compare/v2...v3) --- updated-dependencies: - dependency-name: github/codeql-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/codeql-analysis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 4f10a83..db11c10 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -43,7 +43,7 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v3 with: languages: ${{ matrix.language }} # If you wish to specify custom queries, you can do so here or in a config file. @@ -54,7 +54,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # If this step fails, then you should remove it and run the build manually (see below) - name: Autobuild - uses: github/codeql-action/autobuild@v2 + uses: github/codeql-action/autobuild@v3 # ℹ️ Command-line programs to run using the OS shell. # 📚 https://git.io/JvXDl @@ -68,4 +68,4 @@ jobs: # make release - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v3 From 48a7b473192fa222f8666191b50da2048d2824a6 Mon Sep 17 00:00:00 2001 From: Alexandre Neto Date: Sun, 24 Dec 2023 06:32:38 +0000 Subject: [PATCH 02/97] Specify European Portuguese (#854) --- README.md | 2 +- i18n/pt-br.toml | 4 ++++ i18n/{pt.toml => pt-pt.toml} | 4 ++++ 3 files changed, 9 insertions(+), 1 deletion(-) rename i18n/{pt.toml => pt-pt.toml} (97%) diff --git a/README.md b/README.md index cfc391a..ca33208 100644 --- a/README.md +++ b/README.md @@ -61,7 +61,7 @@ For more details about the features please visit [here](https://toha-guides.netl - Tiếng Việt - Turkish - Arabic (العربية) -- Português +- Português Europeu - Català - Português Brasileiro diff --git a/i18n/pt-br.toml b/i18n/pt-br.toml index 7642dc8..01671a4 100644 --- a/i18n/pt-br.toml +++ b/i18n/pt-br.toml @@ -124,3 +124,7 @@ other = "Nota legal" [search] other = "Pesquisar" + +[minute] +one = "minuto" +other = "minutos" \ No newline at end of file diff --git a/i18n/pt.toml b/i18n/pt-pt.toml similarity index 97% rename from i18n/pt.toml rename to i18n/pt-pt.toml index 65f7703..eddbbca 100644 --- a/i18n/pt.toml +++ b/i18n/pt-pt.toml @@ -124,3 +124,7 @@ other = "Nota legal" [search] other = "Pesquisar" + +[minute] +one = "minuto" +other = "minutos" From d3968ca711efbaa1e699e231ee72759db86c5c53 Mon Sep 17 00:00:00 2001 From: Augusto Pace Date: Fri, 29 Dec 2023 18:04:27 +0100 Subject: [PATCH 03/97] Fixed and improved circular progess animation on about section (#850) Co-authored-by: Emruz Hossain --- assets/styles/sections/about.scss | 15 +++++++++------ layouts/partials/misc/badge.html | 10 ++++++++-- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/assets/styles/sections/about.scss b/assets/styles/sections/about.scss index f3ba974..5f58333 100644 --- a/assets/styles/sections/about.scss +++ b/assets/styles/sections/about.scss @@ -20,20 +20,25 @@ $progress-bar-colors: ( } @mixin circular-progress-animation-breakpoints() { - $progress: 50; + $progress: 0; $duration: 0; + $delay: 1.8; - @for $i from 1 through 10 { + @for $i from 0 through 20 { .circular-progress-percentage-#{$progress} { animation: circular-loading-#{$progress} #{$duration}s linear forwards 1.8s; } + .circular-progress-percentage-#{$progress}-delay { + animation-delay: #{$delay}s; + } $progress: $progress + 5; $duration: $duration + 0.18; + $delay: $duration + 1.8; } } @mixin circular-progress-animation-keyframes($progress, $degree, $keyframes) { - @for $i from 1 through $keyframes { + @for $i from 0 through $keyframes { @keyframes circular-loading-#{$progress} { 0% { transform: rotate(0); @@ -122,7 +127,6 @@ $progress-bar-colors: ( border-bottom-left-radius: 80px; border-right: 0; transform-origin: center right; - animation: circular-loading-1 1.8s linear forwards; } } .circular-progress-value { @@ -144,8 +148,7 @@ $progress-bar-colors: ( } @include circular-progress-bar-color(); @include circular-progress-animation-breakpoints(); - @include circular-progress-animation-keyframes($progress: 50, $degree: 0, $keyframes: 10); - @include circular-progress-animation-keyframes($progress: 1, $degree: 180, $keyframes: 5); + @include circular-progress-animation-keyframes($progress: 0, $degree: 0, $keyframes: 20); } @include media('<=large') { diff --git a/layouts/partials/misc/badge.html b/layouts/partials/misc/badge.html index cfd8eeb..a55eab4 100644 --- a/layouts/partials/misc/badge.html +++ b/layouts/partials/misc/badge.html @@ -12,10 +12,16 @@ {{ if hasPrefix .color "#"}} {{ $predefinedColor = false }} {{ end }} + {{ $leftProgress := 0 }} + {{ $rightProgress := .percentage }} + {{ if ge .percentage 50 }} + {{ $rightProgress = 50 }} + {{ $leftProgress = sub .percentage 50 }} + {{ end }}
Date: Mon, 1 Jan 2024 14:58:11 +0600 Subject: [PATCH 04/97] Refactor alert shortcode (#858) Signed-off-by: hossainemruz --- assets/styles/components/misc.scss | 31 ++++++++++++++++++++++++++++++ assets/styles/mixins.scss | 20 +++++++++++++++++++ assets/styles/variables.scss | 27 ++++++++++++++++++++++++++ layouts/shortcodes/alert.html | 17 ++++++++++++++-- 4 files changed, 93 insertions(+), 2 deletions(-) diff --git a/assets/styles/components/misc.scss b/assets/styles/components/misc.scss index 55803c7..4276c78 100644 --- a/assets/styles/components/misc.scss +++ b/assets/styles/components/misc.scss @@ -31,6 +31,24 @@ pre { } } } + $alert-types: ('success', 'info', 'warning', 'danger'); + +.alert { + @each $type in $alert-types { + &.#{$type} { + background: get-alert-bg-color($type, 'light'); + svg { + width: 1.25rem; + height: 1.25rem; + color: get-alert-text-color($type, 'light') !important; + } + strong { + padding-left: 0.5rem; + color: get-alert-text-color($type, 'light') !important; + } + } + } +} html[data-theme='dark'] { .paginator { @@ -45,4 +63,17 @@ html[data-theme='dark'] { } } } + .alert { + @each $type in $alert-types { + &.#{$type} { + background: get-alert-bg-color($type, 'dark'); + svg { + color: get-alert-text-color($type, 'dark') !important; + } + strong { + color: get-alert-text-color($type, 'dark') !important; + } + } + } + } } diff --git a/assets/styles/mixins.scss b/assets/styles/mixins.scss index e9731a6..28139f3 100644 --- a/assets/styles/mixins.scss +++ b/assets/styles/mixins.scss @@ -50,3 +50,23 @@ color: get-dark-color('text-over-accent-color'); } } + +@function get-alert-bg-color($type, $mode) { + $colors: map-get($alerts, $type); + @if $mode == 'light' { + @return map-get($colors, 'bg-color'); + } @else { + @return map-get($colors, 'text-color'); + } + @return red; +} + +@function get-alert-text-color($type, $mode) { + $colors: map-get($alerts, $type); + @if $mode == 'light' { + @return map-get($colors, 'text-color'); + } @else { + @return map-get($colors, 'bg-color'); + } + @return red; +} diff --git a/assets/styles/variables.scss b/assets/styles/variables.scss index 1fd02af..e49d1b7 100644 --- a/assets/styles/variables.scss +++ b/assets/styles/variables.scss @@ -93,3 +93,30 @@ $brand-colors: ( 'diaspora': #1e1e1e, 'whatsapp': #25d366, ); + +$alerts: ( + 'success': ( + // green 100 + 'bg-color': #dcfce7, + // green 800 + 'text-color': #166534, + ), + 'info': ( + // sky 100 + 'bg-color': #e0f2fe, + // sky 800 + 'text-color': #075985, + ), + 'warning': ( + // yellow 100 + 'bg-color': #fef9c3, + // yellow 800 + 'text-color': #854d0e, + ), + 'danger': ( + // red 100 + 'bg-color': #fee2e2, + // red 800 + 'text-color': #991b1b, + ), +); diff --git a/layouts/shortcodes/alert.html b/layouts/shortcodes/alert.html index ee1eb02..16074b5 100644 --- a/layouts/shortcodes/alert.html +++ b/layouts/shortcodes/alert.html @@ -1,3 +1,16 @@ -
- {{.Inner | markdownify }} +{{ $type := .Get "type"}} +{{ $icon := "alert-circle"}} +{{ if eq $type "success" }} + {{ $icon = "check-circle"}} +{{ else if eq $type "warning" }} + {{ $icon = "alert-triangle"}} +{{ else if eq $type "danger" }} + {{ $icon = "alert-octagon"}} +{{ else if eq $type "info" }} + {{ $icon = "info"}} +{{ end }} + +
+ + {{.Inner | markdownify }}
From 0c0072eac1e1b5c4e8e231b1af50094d74bad990 Mon Sep 17 00:00:00 2001 From: Emruz Hossain Date: Sun, 7 Jan 2024 02:08:05 +0600 Subject: [PATCH 05/97] Add hugoVersion info in config.yaml (#861) Signed-off-by: hossainemruz --- config.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/config.yaml b/config.yaml index 1386de9..d85daaa 100644 --- a/config.yaml +++ b/config.yaml @@ -1,4 +1,7 @@ module: + hugoVersion: + min: "0.118.0" + extended: true mounts: - source: content target: content @@ -19,4 +22,4 @@ module: - source: ../../node_modules/@fontsource/mulish/files target: static/files - source: ../../node_modules/katex/dist/fonts - target: static/fonts \ No newline at end of file + target: static/fonts From b9713b5461827898aa2c9b495c1970d9ed36e034 Mon Sep 17 00:00:00 2001 From: hossainemruz Date: Sat, 13 Jan 2024 19:09:23 +0600 Subject: [PATCH 06/97] Add link to migration guide Signed-off-by: hossainemruz --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index ca33208..7e078dd 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +**If you are migrating from v3 (git submodule based) theme to v4 (hugo modules based) theme, please read this [migration guide](https://toha-guides.netlify.app/posts/update-v3-to-v4/).** + # Toha [![Netlify Status](https://api.netlify.com/api/v1/badges/b1b93b02-f278-440b-ae1b-304e9f4c4ab5/deploy-status)](https://app.netlify.com/sites/toha/deploys) From 2c5cbeee9445b74ad5a10e81471efd73c4952067 Mon Sep 17 00:00:00 2001 From: Emruz Hossain Date: Sun, 14 Jan 2024 13:43:18 +0600 Subject: [PATCH 07/97] Update README.md (#863) --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7e078dd..6e90e14 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ -**If you are migrating from v3 (git submodule based) theme to v4 (hugo modules based) theme, please read this [migration guide](https://toha-guides.netlify.app/posts/update-v3-to-v4/).** +> [!IMPORTANT] +> If you are migrating from v3 (`git submodule` based) theme to v4 (`hugo modules` based) theme, please read this [migration guide](https://toha-guides.netlify.app/posts/update-v3-to-v4/). # Toha From 1aa27921d01867590d60f2af6e64722d801b771d Mon Sep 17 00:00:00 2001 From: Dieter Vansteenwegen <46349482+dietervansteenwegen@users.noreply.github.com> Date: Wed, 17 Jan 2024 13:56:07 +0100 Subject: [PATCH 08/97] Add Researchgate as contact option (#864) --- layouts/partials/footer.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index e98273a..048074f 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -115,6 +115,10 @@
  • {{ $value }}
  • + {{ else if (eq $key "researchgate") }} +
  • + {{ $author.name }} +
  • {{ else if reflect.IsMap $value }}
  • {{ if (and (isset $value "url") (isset $value "icon"))}} From def5ce662e416eb097e86397a0a501a2d1a48c85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Fri, 19 Jan 2024 20:00:11 +0100 Subject: [PATCH 09/97] Add select maximum number of posts per page (#866) * Add select maximum number of posts per page * Rename ans simplify posts to show * Fix --- layouts/_default/list.html | 3 ++- layouts/categories/list.html | 3 ++- layouts/tags/list.html | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 6bc2de4..9485de3 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -32,7 +32,8 @@
    {{ $posts := where .RegularPagesRecursive "Layout" "!=" "search" }} - {{ $paginator := .Paginate $posts 12 }} + {{ $numShow := site.Params.features.pagination.maxPostsPerPage | default 12}} + {{ $paginator := .Paginate $posts $numShow }} {{ range $paginator.Pages }} {{ if .Layout }} {{/* ignore the search.md file*/}} diff --git a/layouts/categories/list.html b/layouts/categories/list.html index 48a48a4..5a79b8f 100644 --- a/layouts/categories/list.html +++ b/layouts/categories/list.html @@ -33,7 +33,8 @@
    {{ $posts := where .RegularPagesRecursive "Layout" "!=" "search" }} - {{ $paginator := .Paginate $posts 12 }} + {{ $numShow := site.Params.features.pagination.maxPostsPerPage | default 12}} + {{ $paginator := .Paginate $posts $numShow }} {{ range $paginator.Pages }} {{ if .Layout }} {{/* ignore the search.md file*/}} diff --git a/layouts/tags/list.html b/layouts/tags/list.html index 4ff7fd7..514a141 100644 --- a/layouts/tags/list.html +++ b/layouts/tags/list.html @@ -33,7 +33,8 @@
    {{ $posts := where .RegularPagesRecursive "Layout" "!=" "search" }} - {{ $paginator := .Paginate $posts 12 }} + {{ $numShow := site.Params.features.pagination.maxPostsPerPage | default 12}} + {{ $paginator := .Paginate $posts $numShow }} {{ range $paginator.Pages }} {{ if .Layout }} {{/* ignore the search.md file*/}} From c74672c1c1efba09b4a6180f665f0713af37cf95 Mon Sep 17 00:00:00 2001 From: Emruz Hossain Date: Wed, 24 Jan 2024 10:06:35 +0600 Subject: [PATCH 10/97] Update local development guide (#869) Signed-off-by: hossainemruz --- README.md | 86 +++++++++++++++++++++++++++++++++------------- exampleSite/go.sum | 2 -- 2 files changed, 62 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index 6e90e14..10e8f5d 100644 --- a/README.md +++ b/README.md @@ -188,34 +188,72 @@ For local development, you can make changes in the theme submodule and test the At first, fork [this repo](https://github.com/hugo-toha/toha). Then, follow the following steps to use the forked theme for local developments, -**Using the forked theme in your own site:** - -If you want to run your local development against your own site, follow the following steps: - -```bash -# add the original theme as a submodule of your site if you haven't done already -$ git submodule add https://github.com/hugo-toha/toha.git themes/toha -# navigate into the toha theme folder -$ cd themes/toha -# add your own fork as a remote -$ git remote add my-fork https://github.com//toha -# create a new branch for your changes -$ git checkout -b my-feature-branch -``` - -**Using the forked theme in the example site:** +#### Running the forked theme against the example site If your want to run your local development against this [example site](https://github.com/hugo-toha/hugo-toha.github.io), follow the following steps: ```bash -# clone the example site along with the submodules -$ git clone git@github.com:hugo-toha/hugo-toha.github.io.git --recursive -# navigate into the toha theme folder -$ cd themes/toha -# add your own fork as a remote -$ git remote add my-fork https://github.com//toha -# create a new branch for your changes -$ git checkout -b my-feature-branch +# go to exampleSite directory +$ cd exampleSite +# install hugo modules +$ hugo mod tidy +# install dependencies +$ hugo mod npm pack +$ npm install +# run the example site locally +$ hugo server -w +``` + +Now, you can make change in the theme and they will be reflected immediately on the running site. If you need to change any configuration, you can do that in the `config.yaml` file inside `exampleSite` folder. If you need to add any content or data, you can create the respective folder inside `exampleSite` directory and add your desired content or data there. + +#### Running the forked theme against your own site + +If you want to run your local development against your own site, follow the following steps: + +**Replace the theme module:** + +Open your site's `go.mod` file and replace the `github.com/hugo-toha/toha/v4` with your forked repo's path. For example, if your forked repo is `github.com//toha`, then replace the `github.com/hugo-toha/toha/v4` with `github.com//toha/v4`. + +```go +module github.com/hugo-toha/hugo-toha.github.io + +go 1.19 + +require github.com/hugo-toha/toha/v4 v4.0.1-0.20231229170427-d3968ca711ef // indirect + +replace( + github.com/hugo-toha/toha/v4 => github.com//toha +) +``` + +For interactive development, you can replace the theme with your locally cloned fork. For example, if you have cloned your fork in `/home/my-projects/toha`, then replace the `github.com/hugo-toha/toha/v4` with `/home/my-projects/toha`. + +```go +module github.com/hugo-toha/hugo-toha.github.io + +go 1.19 + +require github.com/hugo-toha/toha/v4 v4.0.1-0.20231229170427-d3968ca711ef // indirect + +replace( + github.com/hugo-toha/toha/v4 => /home/my-projects/toha +) +``` + +**Update dependencies:** + +```bash +# update hugo modules +$ hugo mod tidy +# install dependencies +$ hugo mod npm pack +$ npm install +``` + +**Run your site locally:** + +```bash +$ hugo server -w ``` From there you can make changes to the source code of the theme while testing with your running Hugo site or the example site. diff --git a/exampleSite/go.sum b/exampleSite/go.sum index 845d5ce..9101a35 100644 --- a/exampleSite/go.sum +++ b/exampleSite/go.sum @@ -1,4 +1,2 @@ -github.com/hugo-toha/hugo-toha.github.io v0.0.0-20221228191121-007f31838bd6 h1:TPFhOZAnuH4wjLIdzimswCRa2qCcc1teKVTatADJU2g= -github.com/hugo-toha/hugo-toha.github.io v0.0.0-20221228191121-007f31838bd6/go.mod h1:OMMaP9Hh9NsKd41lVIazBQRPa0s6Z57AfJoY3DcCNNY= github.com/hugo-toha/hugo-toha.github.io v0.0.0-20231031082630-2c32a26d2207 h1:T71lEaGpHYpdy8yKM5vaVwm+CJGt8wjHvPgVM+GjCJM= github.com/hugo-toha/hugo-toha.github.io v0.0.0-20231031082630-2c32a26d2207/go.mod h1:aTn1lQX1rbcbfbwNuWHG/L5DPtD+bEzQro49QyFlbEg= From b3aae4de33b618845594b940727dd151112e18f0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 2 Feb 2024 11:45:20 +0000 Subject: [PATCH 11/97] Bump release-drafter/release-drafter from 5.25.0 to 6.0.0 (#879) Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.25.0 to 6.0.0. - [Release notes](https://github.com/release-drafter/release-drafter/releases) - [Commits](https://github.com/release-drafter/release-drafter/compare/v5.25.0...v6.0.0) --- updated-dependencies: - dependency-name: release-drafter/release-drafter dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/merge-to-main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/merge-to-main.yml b/.github/workflows/merge-to-main.yml index fdd8b73..691bf0c 100644 --- a/.github/workflows/merge-to-main.yml +++ b/.github/workflows/merge-to-main.yml @@ -10,6 +10,6 @@ jobs: runs-on: ubuntu-latest steps: # Create/Update release draft - - uses: release-drafter/release-drafter@v5.25.0 + - uses: release-drafter/release-drafter@v6.0.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 5159cdf6bb7a4d5bbf811098135d7c4c8e91149b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 2 Feb 2024 11:46:19 +0000 Subject: [PATCH 12/97] Bump peter-evans/create-pull-request from 5 to 6 (#877) Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 5 to 6. - [Release notes](https://github.com/peter-evans/create-pull-request/releases) - [Commits](https://github.com/peter-evans/create-pull-request/compare/v5...v6) --- updated-dependencies: - dependency-name: peter-evans/create-pull-request dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- .github/workflows/autoprefixer.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/autoprefixer.yml b/.github/workflows/autoprefixer.yml index f4abab1..9d3880b 100644 --- a/.github/workflows/autoprefixer.yml +++ b/.github/workflows/autoprefixer.yml @@ -21,7 +21,7 @@ jobs: npm run autoprefixer - name: Create Pull Request - uses: peter-evans/create-pull-request@v5 + uses: peter-evans/create-pull-request@v6 with: branch: autoprefixer branch-suffix: timestamp From 3d1b8f830f8d565e7daaf93ee5da3a2bbe9d9079 Mon Sep 17 00:00:00 2001 From: Nico <92774152+niltied@users.noreply.github.com> Date: Fri, 2 Feb 2024 17:18:06 +0100 Subject: [PATCH 13/97] Changing the translation of 'Notes' (#875) Changed the translation for the word "Notes" from "Remarques" to "Notes" (as in English). Co-authored-by: Emruz Hossain --- i18n/fr.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/i18n/fr.toml b/i18n/fr.toml index ade4ecf..c42d30b 100644 --- a/i18n/fr.toml +++ b/i18n/fr.toml @@ -117,7 +117,7 @@ other = "Suite" other = "Afficher le certificat" [notes] -other = "Remarques" +other = "Notes" [disclaimer_text] other = "Avis de responsabilité" @@ -127,4 +127,4 @@ other = "Chercher" [minute] one = "minute" -other = "minutes" \ No newline at end of file +other = "minutes" From 3283a3b844c433a398f79f9e7caf40192ea388fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Fri, 2 Feb 2024 17:57:18 +0100 Subject: [PATCH 14/97] Add param profile to hide author in post (#870) * Add param profile * Fix date duplicated when profile not set * Change param localization --------- Co-authored-by: Emruz Hossain --- layouts/_default/single.html | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/layouts/_default/single.html b/layouts/_default/single.html index e999f71..5070b3f 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -36,15 +36,26 @@
    + {{ if site.Params.features.blog.showAuthor | default true }}
    Author Image
    {{ partial "helpers/get-author-name.html" . }}

    {{ .Page.Date | time.Format ":date_full" }}{{ if site.Params.features.readingTime }} | {{ .ReadingTime }} {{i18n "minute" .ReadingTime }}{{ end }}

    - + {{ else }} +
    + {{ end }} +

    {{ .Page.Title }}

    + + {{ if not (site.Params.features.blog.showAuthor | default true) }} +
    +

    {{ .Page.Date | time.Format ":date_full" }}{{ if site.Params.features.readingTime }} | {{ .ReadingTime }} {{i18n "minute" .ReadingTime }}{{ end }}

    +
    + {{ end }} + {{ if site.Params.features.tags.enable }} {{partial "misc/tags.html" .Params.tags }} {{ end }} From de1cee3951f73c746b549d2e4007106b1108208d Mon Sep 17 00:00:00 2001 From: Emruz Hossain Date: Fri, 2 Feb 2024 23:02:12 +0600 Subject: [PATCH 15/97] Fix replace directive in local development guide (#880) --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 10e8f5d..be320d6 100644 --- a/README.md +++ b/README.md @@ -222,7 +222,7 @@ go 1.19 require github.com/hugo-toha/toha/v4 v4.0.1-0.20231229170427-d3968ca711ef // indirect replace( - github.com/hugo-toha/toha/v4 => github.com//toha + github.com/hugo-toha/toha/v4 => github.com//toha/v4 ) ``` From e8b0cfb32ef053eb4394fd41865e78a737918a81 Mon Sep 17 00:00:00 2001 From: Emruz Hossain Date: Sat, 3 Feb 2024 00:31:03 +0600 Subject: [PATCH 16/97] Fix active menu on sidebar not getting highlighted in dark mode (#881) Signed-off-by: Emruz Hossain --- assets/styles/components/links.scss | 16 ++++++++++++++-- exampleSite/config.yaml | 1 + 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/assets/styles/components/links.scss b/assets/styles/components/links.scss index 1dd63f8..3b162e2 100644 --- a/assets/styles/components/links.scss +++ b/assets/styles/components/links.scss @@ -14,6 +14,7 @@ a { text-decoration: none !important; color: get-light-color('text-color'); @include transition(); + &.active { display: inline; color: get-light-color('accent-color'); @@ -29,6 +30,7 @@ a { a.header-anchor { text-decoration: none; color: get-light-color('heading-color'); + i, svg { font-size: 10pt; @@ -36,12 +38,15 @@ a.header-anchor { display: none; margin-left: 0.5rem; } + &:hover { + i, svg { display: inline-block; } } + code { color: get-light-color('inline-code-color'); } @@ -54,26 +59,33 @@ a.header-anchor { html[data-theme='dark'] { a { color: get-dark-color('accent-color'); + &:hover, &:focus { text-decoration: get-dark-color('hover-over-accent-color') underline; color: get-dark-color('hover-over-accent-color'); } } + .list-link { color: get-dark-color('text-color'); - &:hover { + + &:hover, + &.active { color: get-dark-color('accent-color'); } } + a.header-anchor { color: get-dark-color('heading-color'); + i, svg { color: get-dark-color('text-color'); } + code { color: get-dark-color('inline-code-color'); } } -} +} \ No newline at end of file diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 74db6cc..1db84ff 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -98,6 +98,7 @@ params: # Enable and configure blog posts blog: enable: true + showAuthor: true # Share post on different social media shareButtons: facebook: true From 11bddc36a221034df656cf2b0f4b45f314a0551c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 08:26:12 +0100 Subject: [PATCH 17/97] Add company and school logos (#882) * Add education logo * Fix width * Update css * Add logos to company * Add multiple positions * Update Styling * Strenghten poistion title * Improve timeline * Fix missing curly braces * Fix curly braces * Add space * Add space between position and date * Make single and multiple experiences more consistent * Remove single-position layout * Remove duplicated comment --- assets/styles/components/images.scss | 10 ++++ assets/styles/sections/experiences.scss | 10 ++++ layouts/partials/sections/education-alt.html | 12 +++++ layouts/partials/sections/education.html | 13 ++++++ layouts/partials/sections/experiences.html | 4 +- .../sections/experiences/experience-info.html | 5 -- .../experiences/multiple-positions.html | 29 ------------ .../sections/experiences/positions.html | 46 +++++++++++++++++++ .../sections/experiences/single-position.html | 23 ---------- 9 files changed, 93 insertions(+), 59 deletions(-) delete mode 100644 layouts/partials/sections/experiences/experience-info.html delete mode 100644 layouts/partials/sections/experiences/multiple-positions.html create mode 100644 layouts/partials/sections/experiences/positions.html delete mode 100644 layouts/partials/sections/experiences/single-position.html diff --git a/assets/styles/components/images.scss b/assets/styles/components/images.scss index d546d7b..146ea8b 100644 --- a/assets/styles/components/images.scss +++ b/assets/styles/components/images.scss @@ -46,3 +46,13 @@ html[data-theme='dark'] { .svg-inverted { filter: invert(1); } + +.logo-holder { + height: 64px; + margin-bottom: 1em; +} + +.company-logo { + max-height: 100%; + width: auto; +} \ No newline at end of file diff --git a/assets/styles/sections/experiences.scss b/assets/styles/sections/experiences.scss index d6f6085..aae541b 100644 --- a/assets/styles/sections/experiences.scss +++ b/assets/styles/sections/experiences.scss @@ -92,6 +92,16 @@ } } + .company-heading { + h5 { + display: inline; + margin-right: 0.25em; + } + p { + display: inline; + } + } + @include media('<=medium') { .container { max-width: 100%; diff --git a/layouts/partials/sections/education-alt.html b/layouts/partials/sections/education-alt.html index b6996df..827194b 100644 --- a/layouts/partials/sections/education-alt.html +++ b/layouts/partials/sections/education-alt.html @@ -31,6 +31,18 @@
    + + {{ $logoImage:= resources.Get .institution.logo}} + {{ if $logoImage }} + {{/* svg don't support "Fit" operation */}} + {{ if ne $logoImage.MediaType.SubType "svg" }} + {{ $logoImage = $logoImage.Fit "300x300" }} + {{ end }} +
    + +
    + {{ end }} +
    {{ if .institution.url }} diff --git a/layouts/partials/sections/education.html b/layouts/partials/sections/education.html index 6a7fb74..39ef52a 100644 --- a/layouts/partials/sections/education.html +++ b/layouts/partials/sections/education.html @@ -31,6 +31,19 @@
    + + {{ $logoImage:= resources.Get .institution.logo}} + {{ if $logoImage }} + {{/* svg don't support "Fit" operation */}} + {{ if ne $logoImage.MediaType.SubType "svg" }} + {{ $logoImage = $logoImage.Fit "300x300" }} + {{ end }} + +
    + +
    + {{ end }} +
    {{ if .institution.url }} diff --git a/layouts/partials/sections/experiences.html b/layouts/partials/sections/experiences.html index eafe926..b1cd34f 100644 --- a/layouts/partials/sections/experiences.html +++ b/layouts/partials/sections/experiences.html @@ -18,11 +18,11 @@ {{ if eq (mod $index 2) 0 }}
    {{ partial "sections/experiences/vertical-line.html" $index }} - {{ partial "sections/experiences/experience-info.html" $experience }} + {{ partial "sections/experiences/positions.html" $experience }}
    {{else}}
    - {{ partial "sections/experiences/experience-info.html" $experience }} + {{ partial "sections/experiences/positions.html" $experience }} {{ partial "sections/experiences/vertical-line.html" $index }}
    {{ end }} diff --git a/layouts/partials/sections/experiences/experience-info.html b/layouts/partials/sections/experiences/experience-info.html deleted file mode 100644 index 1d068a9..0000000 --- a/layouts/partials/sections/experiences/experience-info.html +++ /dev/null @@ -1,5 +0,0 @@ -{{ if gt (len .positions) 1 }} - {{ partial "sections/experiences/multiple-positions.html" . }} -{{ else }} - {{ partial "sections/experiences/single-position.html" . }} -{{ end }} diff --git a/layouts/partials/sections/experiences/multiple-positions.html b/layouts/partials/sections/experiences/multiple-positions.html deleted file mode 100644 index 1c77f53..0000000 --- a/layouts/partials/sections/experiences/multiple-positions.html +++ /dev/null @@ -1,29 +0,0 @@ -
    -
    - -
    {{ if .company.url }}{{ .company.name }}{{ else }}{{ .company.name }}{{ end }}
    - - - {{ $oldestPosition := index (last 1 .positions) 0}} - {{ $mostRecentPosition := index (first 1 .positions) 0}} -

    - {{ $oldestPosition.start }} - {{ if $mostRecentPosition.end }}{{ $mostRecentPosition.end }}{{ else }}{{ i18n "present" }}{{ end }}, - {{ .company.location }} -

    - -

    {{ .company.overview | markdownify }}

    -
    - -
    - {{ range $index,$position:= .positions }} -
    {{ $position.designation }}
    -

    {{ $position.start }} - {{if $position.end }} {{ $position.end }} {{else}} {{ i18n "present" }} {{end}}

    - -
      - {{ range $position.responsibilities }} -
    • {{ . | markdownify }}
    • - {{ end }} -
    - {{ end }} -
    -
    diff --git a/layouts/partials/sections/experiences/positions.html b/layouts/partials/sections/experiences/positions.html new file mode 100644 index 0000000..514d449 --- /dev/null +++ b/layouts/partials/sections/experiences/positions.html @@ -0,0 +1,46 @@ +
    +
    + {{ $logoImage:= resources.Get .company.logo}} + {{ if $logoImage }} + {{/* svg don't support "Fit" operation */}} + {{ if ne $logoImage.MediaType.SubType "svg" }} + {{ $logoImage = $logoImage.Fit "300x300" }} + {{ end }} +
    + +
    + {{ end }} + + {{ $oldestPosition := index (last 1 .positions) 0}} + {{ $mostRecentPosition := index (first 1 .positions) 0}} +
    +
    {{ if .company.url }}{{ .company.name }}{{ else }}{{ .company.name }}{{ end }}
    +

    + {{ $oldestPosition.start }} - {{ if $mostRecentPosition.end }}{{ $mostRecentPosition.end }}{{ else }}{{ i18n "present" }}{{ end }} +

    +
    +

    + {{ .company.location }} +

    + +

    {{ .company.overview | markdownify }}

    +
    + +
    + {{ range $index,$position:= .positions }} +
    +
    {{ $position.designation }}
    +

    {{ $position.start }} - {{if $position.end }} {{ $position.end }} {{else}} {{ i18n "present" }} {{end}}

    +
    + + {{ if $position.responsibilities }} +
    {{ i18n "responsibilities" }}
    +
      + {{ range $position.responsibilities }} +
    • {{ . | markdownify }}
    • + {{ end }} +
    + {{ end }} + {{ end }} +
    +
    diff --git a/layouts/partials/sections/experiences/single-position.html b/layouts/partials/sections/experiences/single-position.html deleted file mode 100644 index 4b0e500..0000000 --- a/layouts/partials/sections/experiences/single-position.html +++ /dev/null @@ -1,23 +0,0 @@ -
    -
    - {{ $position:= index .positions 0 }} - -
    {{ $position.designation }}
    -
    {{ if .company.url }}{{ .company.name }}{{ else }}{{ .company.name }}{{ end }}
    - -

    {{ $position.start }} - {{ if $position.end }}{{ $position.end }}{{ else }}{{ i18n "present" }}{{ end }}, - {{ .company.location }} -

    -
    - -

    {{ .company.overview | markdownify }}

    - - {{ if $position.responsibilities }} -
    {{ i18n "responsibilities" }}
    -
      - {{ range $position.responsibilities }} -
    • {{ . | markdownify }}
    • - {{ end }} -
    - {{ end }} -
    From 96768ade2dd8852c2102997d857a7a4c5ece6132 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 08:27:15 +0100 Subject: [PATCH 18/97] Add dutch in Readme (#883) Co-authored-by: Emruz Hossain --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index be320d6..3468061 100644 --- a/README.md +++ b/README.md @@ -67,6 +67,7 @@ For more details about the features please visit [here](https://toha-guides.netl - Português Europeu - Català - Português Brasileiro +- Nederlands To know more about how to translate your site, please visit [here](https://toha-guides.netlify.app/posts/translation/). Follow, the data and post format from this [example site](https://hugo-toha.github.io). From df78c743c8073e662b7d6f945180b98181ec7d9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 08:29:12 +0100 Subject: [PATCH 19/97] Fix Tags sidebar font color (#890) Co-authored-by: Emruz Hossain --- assets/styles/components/links.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/styles/components/links.scss b/assets/styles/components/links.scss index 3b162e2..61369a2 100644 --- a/assets/styles/components/links.scss +++ b/assets/styles/components/links.scss @@ -10,7 +10,7 @@ a { } } -.list-link { +.list-link, .taxonomy-term { text-decoration: none !important; color: get-light-color('text-color'); @include transition(); @@ -67,7 +67,7 @@ html[data-theme='dark'] { } } - .list-link { + .list-link, .taxonomy-term { color: get-dark-color('text-color'); &:hover, From 970656789ce6d3977a93c94221a8c056cb242cc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 08:31:09 +0100 Subject: [PATCH 20/97] Fix anchors in post cards (#891) Co-authored-by: Emruz Hossain --- layouts/partials/cards/post.html | 38 +++++++++++++++++--------------- 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/layouts/partials/cards/post.html b/layouts/partials/cards/post.html index 0653031..99178bc 100644 --- a/layouts/partials/cards/post.html +++ b/layouts/partials/cards/post.html @@ -1,24 +1,26 @@
    - -
    -
    + - + +
    From cbdb07dbf1146875de72555dbe2006b3c4497f01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 18:24:21 +0100 Subject: [PATCH 21/97] Add custom subsections in education (#888) * Add custom subsections in education * Apply requested changes --- assets/styles/sections/education.scss | 6 ++++++ layouts/partials/sections/education-alt.html | 8 ++++++++ layouts/partials/sections/education.html | 8 ++++++++ 3 files changed, 22 insertions(+) diff --git a/assets/styles/sections/education.scss b/assets/styles/sections/education.scss index 75e39af..8188844 100644 --- a/assets/styles/sections/education.scss +++ b/assets/styles/sections/education.scss @@ -129,6 +129,12 @@ margin-bottom: 0; } } + + .custom-section { + .custom-content { + padding-bottom: 0.5em; + } + } } } } diff --git a/layouts/partials/sections/education-alt.html b/layouts/partials/sections/education-alt.html index 827194b..3c6273b 100644 --- a/layouts/partials/sections/education-alt.html +++ b/layouts/partials/sections/education-alt.html @@ -118,6 +118,14 @@
    {{ end }} + {{ if .custonSections }} +
    + {{ range .custonSections }} +
    {{ .name }}:
    +
    {{ .content | markdownify }}
    + {{ end }} +
    + {{ end }}
    diff --git a/layouts/partials/sections/education.html b/layouts/partials/sections/education.html index 39ef52a..afd586d 100644 --- a/layouts/partials/sections/education.html +++ b/layouts/partials/sections/education.html @@ -119,6 +119,14 @@
    {{ end }} + {{ if .custonSections }} +
    + {{ range .custonSections }} +
    {{ .name }}:
    +
    {{ .content | markdownify }}
    + {{ end }} +
    + {{ end }}
    From 35bca7198749eb412eadbebc2a30493f2c0227f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 12 Feb 2024 20:35:55 +0100 Subject: [PATCH 22/97] Add spacing between project tags (#892) * Add spacing between project tags * Fix --- assets/styles/sections/projects.scss | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/assets/styles/sections/projects.scss b/assets/styles/sections/projects.scss index 582d348..47c1242 100644 --- a/assets/styles/sections/projects.scss +++ b/assets/styles/sections/projects.scss @@ -35,6 +35,10 @@ .project-card-footer { display: flex; + .badge { + margin-left: 0.1em; + margin-right: 0.1em; + } } .project-tags-holder { From b8bee52c7ca5800b453c2f4ff59f048f95d96542 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Tue, 13 Feb 2024 21:01:20 +0100 Subject: [PATCH 23/97] Fix hovering tags in posts (#894) --- assets/styles/components/buttons.scss | 13 ------------- layouts/partials/misc/tags.html | 12 ++++++------ 2 files changed, 6 insertions(+), 19 deletions(-) diff --git a/assets/styles/components/buttons.scss b/assets/styles/components/buttons.scss index 6e595b5..0d7283e 100644 --- a/assets/styles/components/buttons.scss +++ b/assets/styles/components/buttons.scss @@ -56,14 +56,12 @@ font-size: 0.5em; list-style-type: none; display: inline-block; - background: get-light-color('accent-color'); margin-left: 0.2em; margin-right: 0.2em; margin-top: 0.6em; margin-bottom: 0.6em; } a { - color: get-light-color('text-over-accent-color'); text-decoration: none !important; } } @@ -143,17 +141,6 @@ html[data-theme='dark'] { color: get-dark-color('muted-text-color'); } - .tags { - li { - background: get-dark-color('accent-color'); - a { - background-color: get-dark-color('bg-card'); - border: 1px solid get-dark-color('muted-text-color'); - color: get-dark-color('text-over-accent-color'); - } - } - } - .icon-button { background-color: get-dark-color('muted-text-color'); color: get-dark-color('text-over-accent-color') !important; diff --git a/layouts/partials/misc/tags.html b/layouts/partials/misc/tags.html index 166fde5..f333300 100644 --- a/layouts/partials/misc/tags.html +++ b/layouts/partials/misc/tags.html @@ -1,8 +1,8 @@
    -
      - {{ range . }} - {{ $url:= printf "tags/%s/" . }} -
    • {{ . }}
    • - {{ end }} -
    +
      + {{ range . }} + {{ $url:= printf "tags/%s/" . }} +
    • {{ . }}
    • + {{ end }} +
    From 32e95a572f000055192a15d27208f7897bed21a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Fri, 16 Feb 2024 15:34:13 +0100 Subject: [PATCH 24/97] Update theme.toml for hugoThemesSiteBuilder (#896) * Update theme.toml * Add min hugo version --- theme.toml | 47 +++++++++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 20 deletions(-) diff --git a/theme.toml b/theme.toml index 3ab6525..0032852 100644 --- a/theme.toml +++ b/theme.toml @@ -1,24 +1,14 @@ -# theme.toml template for a Hugo theme -# See https://github.com/gohugoio/hugoThemes#themetoml for an example -description = "A simple hugo theme for personal portfolio" -homepage = "https://hugo-toha.github.io/" +name = "Toha" license = "MIT" licenselink = "https://github.com/hugo-toha/toha/blob/master/LICENSE" -min_version = "0.118.0" -name = "Toha" +description = "A simple hugo theme for personal portfolio" + +# The home page of the theme, where the source can be found. +homepage = "https://github.com/hugo-toha/toha" + +# If you have a running demo of the theme. +demosite = "https://hugo-toha.github.io/" -features = [ - "Minimalist Design", - "Fully Responsive", - "Multiple Language Support", - "Carefully Designed Cards", - "Experience Timeline", - "Achievement Gallery", - "Sidebar to Categorize the Posts", - "Short Codes", - "Google Analytics Support", - "Disqus Comment Support", -] tags = [ "Portfolio", "Blog", @@ -34,7 +24,24 @@ tags = [ "Bootstrap", "Syntax highlighting", ] +features = [ + "Minimalist Design", + "Fully Responsive", + "Multiple Language Support", + "Carefully Designed Cards", + "Experience Timeline", + "Achievement Gallery", + "Sidebar to Categorize the Posts", + "Short Codes", + "Google Analytics Support", + "Disqus Comment Support", +] [author] -homepage = "https://hossainemruz.github.io" -name = "Emruz Hossain" + homepage = "https://hossainemruz.github.io" + name = "Emruz Hossain" + +[module] + [module.hugoVersion] + extended = true + min = "0.118.0" \ No newline at end of file From 9f5a44e24ea5397fcfc3bcd5ffa1b4c70572069e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Mon, 19 Feb 2024 10:11:18 +0100 Subject: [PATCH 25/97] Fix logos (#898) --- layouts/partials/sections/education-alt.html | 4 ---- layouts/partials/sections/education.html | 5 ----- layouts/partials/sections/experiences/positions.html | 4 ---- 3 files changed, 13 deletions(-) diff --git a/layouts/partials/sections/education-alt.html b/layouts/partials/sections/education-alt.html index 3c6273b..cbb6120 100644 --- a/layouts/partials/sections/education-alt.html +++ b/layouts/partials/sections/education-alt.html @@ -34,10 +34,6 @@ {{ $logoImage:= resources.Get .institution.logo}} {{ if $logoImage }} - {{/* svg don't support "Fit" operation */}} - {{ if ne $logoImage.MediaType.SubType "svg" }} - {{ $logoImage = $logoImage.Fit "300x300" }} - {{ end }}
    diff --git a/layouts/partials/sections/education.html b/layouts/partials/sections/education.html index afd586d..fcfb8e5 100644 --- a/layouts/partials/sections/education.html +++ b/layouts/partials/sections/education.html @@ -34,11 +34,6 @@ {{ $logoImage:= resources.Get .institution.logo}} {{ if $logoImage }} - {{/* svg don't support "Fit" operation */}} - {{ if ne $logoImage.MediaType.SubType "svg" }} - {{ $logoImage = $logoImage.Fit "300x300" }} - {{ end }} -
    diff --git a/layouts/partials/sections/experiences/positions.html b/layouts/partials/sections/experiences/positions.html index 514d449..367801b 100644 --- a/layouts/partials/sections/experiences/positions.html +++ b/layouts/partials/sections/experiences/positions.html @@ -2,10 +2,6 @@
    {{ $logoImage:= resources.Get .company.logo}} {{ if $logoImage }} - {{/* svg don't support "Fit" operation */}} - {{ if ne $logoImage.MediaType.SubType "svg" }} - {{ $logoImage = $logoImage.Fit "300x300" }} - {{ end }}
    From 1ec4cd2688547cd26b556a0b568fe38459458d64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Fri, 23 Feb 2024 18:37:35 +0100 Subject: [PATCH 26/97] Add tags in post cards from search results (#895) * Add tags in post cards from search results * Use on_card parameter to decide to show the cards or not * Fix search cards height * Minor fix * Fix null tags * Fix CSS not applied properly in search page Signed-off-by: hossainemruz --------- Signed-off-by: hossainemruz Co-authored-by: Emruz Hossain --- assets/scripts/pages/search.js | 9 ++++++++- layouts/_default/search.html | 24 ++++++++++++++++++------ 2 files changed, 26 insertions(+), 7 deletions(-) diff --git a/assets/scripts/pages/search.js b/assets/scripts/pages/search.js index cd5eb08..87cd0c5 100644 --- a/assets/scripts/pages/search.js +++ b/assets/scripts/pages/search.js @@ -79,6 +79,13 @@ window.addEventListener('DOMContentLoaded', () => { // pull template from hugo template definition const templateDefinition = document.getElementById('search-result-template').innerHTML // replace values + function adaptTags() { + const tags = value.item.tags; + let string = ''; + if (tags) tags.forEach((t) => {string += '
  • ' + t + "
  • "}); + return string; + } + const output = render(templateDefinition, { key, title: value.item.title, @@ -86,7 +93,7 @@ window.addEventListener('DOMContentLoaded', () => { date: value.item.date, summary: value.item.summary, link: value.item.permalink, - tags: value.item.tags, + tags: adaptTags(), categories: value.item.categories, snippet }) diff --git a/layouts/_default/search.html b/layouts/_default/search.html index 75aad98..5877e7d 100644 --- a/layouts/_default/search.html +++ b/layouts/_default/search.html @@ -28,28 +28,40 @@ {{ end }} {{ define "content" }} +
    -
    +
    From 803821d7e8d92b236e8d55fbfa095beee63b389b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernat=20Borr=C3=A0s=20Civil?= <70479573+BernatBC@users.noreply.github.com> Date: Sun, 25 Feb 2024 10:20:00 +0100 Subject: [PATCH 27/97] Fixes posts in search results (#900) --- layouts/_default/search.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/_default/search.html b/layouts/_default/search.html index 5877e7d..9475868 100644 --- a/layouts/_default/search.html +++ b/layouts/_default/search.html @@ -34,7 +34,7 @@
    -
    +
    - +
    {{ block "navbar" . }} {{ end }} diff --git a/layouts/_default/search.html b/layouts/_default/search.html index 9475868..371c808 100644 --- a/layouts/_default/search.html +++ b/layouts/_default/search.html @@ -58,8 +58,8 @@ {{ end }}
    diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 8981d32..9d59e76 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -37,7 +37,7 @@
    {{ if site.Params.features.blog.showAuthor | default true }} -
    +
    Author Image
    {{ partial "helpers/get-author-name.html" . }}

    {{ .Page.Date | time.Format ":date_full" }}{{ if site.Params.features.readingTime }} | {{ .ReadingTime }} {{i18n "minute" .ReadingTime }}{{ end }}

    @@ -51,7 +51,7 @@
    {{ if not (site.Params.features.blog.showAuthor | default true) }} -
    +

    {{ .Page.Date | time.Format ":date_full" }}{{ if site.Params.features.readingTime }} | {{ .ReadingTime }} {{i18n "minute" .ReadingTime }}{{ end }}

    {{ end }} @@ -64,7 +64,7 @@
    -
    +
    - +
    @@ -175,7 +175,7 @@
    {{ if and site.Params.features.toc.enable ( .Params.enableTOC | default true ) }}
    -
    {{ i18n "toc_heading" }}
    +
    {{ i18n "toc_heading" }}

    {{ .TableOfContents }} diff --git a/layouts/index.html b/layouts/index.html index 81296de..5a1faf2 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -29,7 +29,7 @@ document.documentElement.setAttribute('data-theme', theme); - + {{- partial "navigators/navbar.html" . -}} diff --git a/layouts/partials/cards/accomplishments.html b/layouts/partials/cards/accomplishments.html index a62fa22..27015b1 100644 --- a/layouts/partials/cards/accomplishments.html +++ b/layouts/partials/cards/accomplishments.html @@ -4,7 +4,7 @@
    {{ .name }}
    {{ .organization.name }} - {{ .timeline }} + {{ .timeline }}
    @@ -12,7 +12,7 @@
    diff --git a/layouts/partials/cards/post.html b/layouts/partials/cards/post.html index 99178bc..4426b7c 100644 --- a/layouts/partials/cards/post.html +++ b/layouts/partials/cards/post.html @@ -15,12 +15,12 @@ {{ end }}
    diff --git a/layouts/partials/cards/publication.html b/layouts/partials/cards/publication.html index bdc7b21..2c238e1 100644 --- a/layouts/partials/cards/publication.html +++ b/layouts/partials/cards/publication.html @@ -12,11 +12,11 @@
    {{ .title }}
    {{ .publishedIn.name }} - {{ .publishedIn.date }} + {{ .publishedIn.date }}
    {{ range $index,$author:= .authors }} - {{ .name }} + {{ .name }} {{ end }}
    @@ -26,13 +26,13 @@
    diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 048074f..c04bd7a 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -66,7 +66,7 @@