mirror of
https://github.com/hazemKrimi/personal-website.git
synced 2026-05-01 18:00:26 +00:00
Code refactoring
This commit is contained in:
@@ -1,7 +1,3 @@
|
||||
{{ $styles := resources.Get "css/partials/about-card.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
{{ $cv := resources.Get "cv.pdf" }}
|
||||
{{ $faceImage := resources.Get "images/borded-face.png" }}
|
||||
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
{{ $styles := resources.Get "css/partials/breadcrumb.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
<nav aria-label="breadcrumb" class="breadcrumb">
|
||||
<ol>
|
||||
{{ range .Ancestors.Reverse }}
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
{{ $styles := resources.Get "css/partials/card.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
<article class="card">
|
||||
<div>
|
||||
<h3>{{ .Title }}</h3>
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
{{ $styles := resources.Get "css/partials/contact-form.css" | toCSS | minify }}
|
||||
{{ $scripts := resources.Get "js/partials/contact-form.js" | js.Build | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
<script defer src="{{ $scripts.Permalink }}"></script>
|
||||
|
||||
<form
|
||||
action="{{ .Site.Params.formSpreeURL }}"
|
||||
method="POST"
|
||||
|
||||
@@ -1,14 +1,10 @@
|
||||
{{ $styles := resources.Get "css/partials/footer.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
{{ $faceImage := resources.Get "images/small-face.png" }}
|
||||
{{ $cv :=resources.Get "cv.pdf" }}
|
||||
|
||||
<footer>
|
||||
<div id="footer-face">
|
||||
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi" />
|
||||
<h4>Hazem Krimi</h4>
|
||||
<span>Hazem Krimi</span>
|
||||
</div>
|
||||
<div id="links">
|
||||
<a href="https://www.linkedin.com/in/hazemkrimi" target="_blank">
|
||||
|
||||
@@ -1,16 +1,10 @@
|
||||
{{ $styles := resources.Get "css/partials/header.css" | toCSS | minify }}
|
||||
{{ $scripts := resources.Get "js/partials/header.js" | js.Build | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}">
|
||||
<script defer src="{{ $scripts.Permalink }}"></script>
|
||||
|
||||
{{ $faceImage := resources.Get "images/small-face.png" }}
|
||||
{{ $cv := resources.Get "cv.pdf" }}
|
||||
|
||||
<header>
|
||||
<div id="header-face">
|
||||
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face" />
|
||||
<h3>Hazem Krimi</h3>
|
||||
<span>Hazem Krimi</span>
|
||||
</div>
|
||||
<div id="menus">
|
||||
{{ range site.Menus.main.Sort.ByWeight }}
|
||||
@@ -39,26 +33,3 @@
|
||||
{{ readFile "assets/icons/close.svg" | safeHTML }}
|
||||
</span>
|
||||
</header>
|
||||
|
||||
<nav id="mobile-navigation">
|
||||
<div id="menus">
|
||||
{{ range site.Menus.main.Sort.ByWeight }}
|
||||
<a {{ printf "href=%q" .URL | safeHTMLAttr }}>{{ .Name }}</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
<hr>
|
||||
<div id="links">
|
||||
<span
|
||||
class="theme-toggler"
|
||||
>
|
||||
{{ readFile "assets/icons/moon.svg" | safeHTML }}
|
||||
{{ readFile "assets/icons/sun.svg" | safeHTML }}
|
||||
</span>
|
||||
<a href="{{ $cv.Permalink }}" target="_blank"> {{ readFile "assets/icons/cv.svg" | safeHTML }} </a>
|
||||
<a href="mailto:me@hazemkrimi.tech" target="_blank"> {{ readFile "assets/icons/mail.svg" | safeHTML }} </a>
|
||||
<a href="{{ urls.JoinPath .Site.BaseURL "index.xml" }}" target="_blank"> {{ readFile "assets/icons/rss.svg" | safeHTML }} </a>
|
||||
<a href="https://github.com/hazemKrimi" target="_blank"> {{ readFile "assets/icons/github.svg" | safeHTML }} </a>
|
||||
<a href="https://twitter.com/HazemKrimi" target="_blank"> {{ readFile "assets/icons/twitter.svg" | safeHTML }} </a>
|
||||
<a href="https://www.linkedin.com/in/hazemkrimi" target="_blank"> {{ readFile "assets/icons/linkedin.svg" | safeHTML }} </a>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
{{ $cv := resources.Get "cv.pdf" }}
|
||||
|
||||
<nav id="mobile-navigation">
|
||||
<div id="menus">
|
||||
{{ range site.Menus.main.Sort.ByWeight }}
|
||||
<a {{ printf "href=%q" .URL | safeHTMLAttr }}>{{ .Name }}</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
<hr>
|
||||
<div id="links">
|
||||
<span
|
||||
class="theme-toggler"
|
||||
>
|
||||
{{ readFile "assets/icons/moon.svg" | safeHTML }}
|
||||
{{ readFile "assets/icons/sun.svg" | safeHTML }}
|
||||
</span>
|
||||
<a href="{{ $cv.Permalink }}" target="_blank"> {{ readFile "assets/icons/cv.svg" | safeHTML }} </a>
|
||||
<a href="mailto:me@hazemkrimi.tech" target="_blank"> {{ readFile "assets/icons/mail.svg" | safeHTML }} </a>
|
||||
<a href="{{ urls.JoinPath .Site.BaseURL "index.xml" }}" target="_blank"> {{ readFile "assets/icons/rss.svg" | safeHTML }} </a>
|
||||
<a href="https://github.com/hazemKrimi" target="_blank"> {{ readFile "assets/icons/github.svg" | safeHTML }} </a>
|
||||
<a href="https://twitter.com/HazemKrimi" target="_blank"> {{ readFile "assets/icons/twitter.svg" | safeHTML }} </a>
|
||||
<a href="https://www.linkedin.com/in/hazemkrimi" target="_blank"> {{ readFile "assets/icons/linkedin.svg" | safeHTML }} </a>
|
||||
</div>
|
||||
</nav>
|
||||
@@ -1,8 +1,5 @@
|
||||
{{ $styles := resources.Get "css/partials/pagination.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
{{ $paginator := .Paginator }}
|
||||
|
||||
{{ if gt $paginator.TotalPages 1 }}
|
||||
<div class="pagination">
|
||||
<a class="first {{ if eq $paginator.PageNumber $paginator.First.PageNumber }} active {{ end }}" href="{{ $paginator.First.URL }}">
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
{{ $styles := resources.Get "css/partials/table-of-contents.css" | toCSS | minify }}
|
||||
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||
|
||||
{{ with .TableOfContents }}
|
||||
<aside id="table-of-contents">
|
||||
<h3>Table of contents</h3>
|
||||
|
||||
Reference in New Issue
Block a user