You've already forked jsonresume
Add stackoverflowfr theme
This commit is contained in:
@@ -26,12 +26,9 @@
|
||||
package kendallfr
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"jsonresume/model"
|
||||
"jsonresume/themes"
|
||||
"path"
|
||||
"strings"
|
||||
"text/template"
|
||||
)
|
||||
|
||||
@@ -46,10 +43,10 @@ var Theme = themes.Theme{
|
||||
Name: "kendallfr",
|
||||
Directory: packageDirectory,
|
||||
Functions: template.FuncMap{
|
||||
"iconClass": iconClass,
|
||||
"formatDateWork": formatDateWork,
|
||||
"formatDateEdu": formatDateEdu,
|
||||
"formatDatePub": formatDatePub,
|
||||
"iconClass": themes.IconClass,
|
||||
"formatDateWork": themes.FormatDateWorkFR,
|
||||
"formatDateEdu": themes.FormatDateEduFR,
|
||||
"formatDatePub": themes.FormatDatePubFR,
|
||||
"css": getCSS,
|
||||
"printcss": getPrintCSS,
|
||||
},
|
||||
@@ -69,91 +66,3 @@ func getPrintCSS() string {
|
||||
func init() {
|
||||
(&Theme).Register()
|
||||
}
|
||||
func iconClass(network string) string {
|
||||
network = strings.ToLower(network)
|
||||
switch network {
|
||||
// special cases
|
||||
case "google-plus":
|
||||
case "googleplus":
|
||||
return "fa fa-google-plus"
|
||||
case "flickr":
|
||||
case "flicker":
|
||||
return "fa fa-flickr"
|
||||
case "dribbble":
|
||||
case "dribble":
|
||||
return "fa fa-dribbble"
|
||||
case "codepen":
|
||||
return "fa fa-codepen"
|
||||
case "soundcloud":
|
||||
return "fa fa-soundcloud"
|
||||
case "reddit":
|
||||
return "fa fa-reddit"
|
||||
case "tumblr":
|
||||
case "tumbler":
|
||||
return "fa fa-tumblr"
|
||||
case "stack-overflow":
|
||||
case "stackoverflow":
|
||||
return "fa fa-stack-overflow"
|
||||
case "blog":
|
||||
case "rss":
|
||||
return "fa fa-rss"
|
||||
case "gitlab":
|
||||
return "fa fa-gitlab"
|
||||
case "keybase":
|
||||
return "fa fa-key"
|
||||
default:
|
||||
return "fa fa-" + network
|
||||
}
|
||||
|
||||
return "fa fa-" + network
|
||||
}
|
||||
|
||||
func getMonth(date model.ResumeDate) string {
|
||||
switch date.Month() {
|
||||
case 1:
|
||||
return "Janvier"
|
||||
case 2:
|
||||
return "Février"
|
||||
case 3:
|
||||
return "Mars"
|
||||
case 4:
|
||||
return "Avril"
|
||||
case 5:
|
||||
return "Mai"
|
||||
case 6:
|
||||
return "Juin"
|
||||
case 7:
|
||||
return "Juillet"
|
||||
case 8:
|
||||
return "Août"
|
||||
case 9:
|
||||
return "Septembre"
|
||||
case 10:
|
||||
return "Octobre"
|
||||
case 11:
|
||||
return "Novembre"
|
||||
case 12:
|
||||
return "Décembre"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
func formatDateWork(date model.ResumeDate) string {
|
||||
if date.IsZero() {
|
||||
return "Présent"
|
||||
}
|
||||
return fmt.Sprintf("%s %d", getMonth(date), date.Year())
|
||||
}
|
||||
|
||||
func formatDateEdu(date model.ResumeDate) string {
|
||||
if date.IsZero() {
|
||||
return "Présent"
|
||||
}
|
||||
return fmt.Sprintf("%d", date.Year())
|
||||
}
|
||||
|
||||
func formatDatePub(date model.ResumeDate) string {
|
||||
if date.IsZero() {
|
||||
return "Présent"
|
||||
}
|
||||
return fmt.Sprintf("%d %s %d", date.Day(), getMonth(date), date.Year())
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
{{if .Awards -}}
|
||||
<!-- AWARDS -->
|
||||
<div class="box">
|
||||
<h2><i class="fa fa-certificate ico"></i> Awards</h2>
|
||||
<h2><i class="fa fa-certificate ico"></i> Récompenses</h2>
|
||||
<ul id="awards" class="clearfix">
|
||||
{{range .Awards -}}
|
||||
<li>
|
||||
|
||||
Reference in New Issue
Block a user