diff --git a/freeze.rds b/freeze.rds index 89e1ef0..ce76c85 100644 Binary files a/freeze.rds and b/freeze.rds differ diff --git a/index.html b/index.html index f5d4a3d..80eff27 100644 --- a/index.html +++ b/index.html @@ -321,7 +321,7 @@

Date Formatter

format_date( start = "date_start", end = "date_end", - format = "%Y", + date_format = "%Y", sep = "->", sort_by = "start" ) |> diff --git a/man/format_date.html b/man/format_date.html index cbbff79..7ca51fc 100644 --- a/man/format_date.html +++ b/man/format_date.html @@ -250,9 +250,9 @@

Usage

format_date(
   data,
   start = "start",
-  end = "end",
-  sep = "-",
-  format = "%M %Y",
+  end = NULL,
+  sep = " - ",
+  date_format = "%M %Y",
   colname_date = "date",
   replace_na = "Present",
   sort_by = "none",
@@ -265,7 +265,7 @@ 

Arguments

-data +data Data frame for resume entry @@ -273,7 +273,7 @@

Arguments

-start +start Start date column name. Default is "start" @@ -281,23 +281,23 @@

Arguments

-end +end -End date column name. Default is "end" +Optional. End date column name.
-sep +sep -Separator between start and end date. Default is "-" +Separator between start and end date. Default is " - "
-format +date_format Date format. Default is "%M %Y" @@ -305,7 +305,7 @@

Arguments

-colname_date +colname_date Name for the generated date column. Default is "date" @@ -313,7 +313,7 @@

Arguments

-replace_na +replace_na Value to replace NA values. Default is "Present" @@ -321,7 +321,7 @@

Arguments

-sort_by +sort_by Sort by "none", "start" or "end". Default is "none" @@ -329,7 +329,7 @@

Arguments

-decreasing +decreasing Sort in decreasing order. Default is TRUE @@ -347,13 +347,13 @@

Examples

library(typstcv)
 
 work |>
-  format_date(format = "%Y", sort_by = "start") |>
+  format_date(end = "end", date_format = "%Y", sort_by = "start") |>
   resume_entry()
```{=typst}
-#resume-entry(title: "Associate Professor",location: "Zürich, Switzerland",date: "1909-1911",description: "University of Zürich",)
-#resume-entry(title: "Junior Professor",location: "Bern, Switzerland",date: "1908-1909",description: "University of Bern",)
-#resume-entry(title: "Technical Assistant",location: "Bern, Switzerland",date: "1902-1908",description: "Federal Patent Office",)
+#resume-entry(title: "Associate Professor",location: "Zürich, Switzerland",date: "1909 - 1911",description: "University of Zürich",)
+#resume-entry(title: "Junior Professor",location: "Bern, Switzerland",date: "1908 - 1909",description: "University of Bern",)
+#resume-entry(title: "Technical Assistant",location: "Bern, Switzerland",date: "1902 - 1908",description: "Federal Patent Office",)
 ```
diff --git a/man/resume_entry.html b/man/resume_entry.html index ce18c8f..b33eb62 100644 --- a/man/resume_entry.html +++ b/man/resume_entry.html @@ -261,7 +261,7 @@

Arguments

-data +data A data frame with columns for title, location, date, and description @@ -269,7 +269,7 @@

Arguments

-title +title The column name for the title. Default is "title" @@ -277,7 +277,7 @@

Arguments

-location +location The column name for the location. Default is "location" @@ -285,7 +285,7 @@

Arguments

-date +date The column name for the date. Default is "date" @@ -293,7 +293,7 @@

Arguments

-description +description The column name for the description. Default is "description" diff --git a/search.json b/search.json index 128c79f..71cd369 100644 --- a/search.json +++ b/search.json @@ -36,7 +36,7 @@ "href": "man/format_date.html", "title": "typstcv", "section": "", - "text": "Data Column Formatter\n\n\n\nformat_date(\n data,\n start = \"start\",\n end = \"end\",\n sep = \"-\",\n format = \"%M %Y\",\n colname_date = \"date\",\n replace_na = \"Present\",\n sort_by = \"none\",\n decreasing = TRUE\n)\n\n\n\n\n\n\n\ndata\n\n\nData frame for resume entry\n\n\n\n\nstart\n\n\nStart date column name. Default is \"start\"\n\n\n\n\nend\n\n\nEnd date column name. Default is \"end\"\n\n\n\n\nsep\n\n\nSeparator between start and end date. Default is \"-\"\n\n\n\n\nformat\n\n\nDate format. Default is \"%M %Y\"\n\n\n\n\ncolname_date\n\n\nName for the generated date column. Default is \"date\"\n\n\n\n\nreplace_na\n\n\nValue to replace NA values. Default is \"Present\"\n\n\n\n\nsort_by\n\n\nSort by \"none\", \"start\" or \"end\". Default is \"none\"\n\n\n\n\ndecreasing\n\n\nSort in decreasing order. Default is TRUE\n\n\n\n\n\n\nData frame with formatted date column\n\n\n\n\nlibrary(typstcv)\n\nwork |>\n format_date(format = \"%Y\", sort_by = \"start\") |>\n resume_entry()\n\n```{=typst}\n#resume-entry(title: \"Associate Professor\",location: \"Zürich, Switzerland\",date: \"1909-1911\",description: \"University of Zürich\",)\n#resume-entry(title: \"Junior Professor\",location: \"Bern, Switzerland\",date: \"1908-1909\",description: \"University of Bern\",)\n#resume-entry(title: \"Technical Assistant\",location: \"Bern, Switzerland\",date: \"1902-1908\",description: \"Federal Patent Office\",)\n```", + "text": "Data Column Formatter\n\n\n\nformat_date(\n data,\n start = \"start\",\n end = NULL,\n sep = \" - \",\n date_format = \"%M %Y\",\n colname_date = \"date\",\n replace_na = \"Present\",\n sort_by = \"none\",\n decreasing = TRUE\n)\n\n\n\n\n\n\n\ndata\n\n\nData frame for resume entry\n\n\n\n\nstart\n\n\nStart date column name. Default is \"start\"\n\n\n\n\nend\n\n\nOptional. End date column name.\n\n\n\n\nsep\n\n\nSeparator between start and end date. Default is \" - \"\n\n\n\n\ndate_format\n\n\nDate format. Default is \"%M %Y\"\n\n\n\n\ncolname_date\n\n\nName for the generated date column. Default is \"date\"\n\n\n\n\nreplace_na\n\n\nValue to replace NA values. Default is \"Present\"\n\n\n\n\nsort_by\n\n\nSort by \"none\", \"start\" or \"end\". Default is \"none\"\n\n\n\n\ndecreasing\n\n\nSort in decreasing order. Default is TRUE\n\n\n\n\n\n\nData frame with formatted date column\n\n\n\n\nlibrary(typstcv)\n\nwork |>\n format_date(end = \"end\", date_format = \"%Y\", sort_by = \"start\") |>\n resume_entry()\n\n```{=typst}\n#resume-entry(title: \"Associate Professor\",location: \"Zürich, Switzerland\",date: \"1909 - 1911\",description: \"University of Zürich\",)\n#resume-entry(title: \"Junior Professor\",location: \"Bern, Switzerland\",date: \"1908 - 1909\",description: \"University of Bern\",)\n#resume-entry(title: \"Technical Assistant\",location: \"Bern, Switzerland\",date: \"1902 - 1908\",description: \"Federal Patent Office\",)\n```", "crumbs": [ "Reference", "format_date" @@ -47,7 +47,7 @@ "href": "man/format_date.html#data-column-formatter", "title": "typstcv", "section": "", - "text": "Data Column Formatter\n\n\n\nformat_date(\n data,\n start = \"start\",\n end = \"end\",\n sep = \"-\",\n format = \"%M %Y\",\n colname_date = \"date\",\n replace_na = \"Present\",\n sort_by = \"none\",\n decreasing = TRUE\n)\n\n\n\n\n\n\n\ndata\n\n\nData frame for resume entry\n\n\n\n\nstart\n\n\nStart date column name. Default is \"start\"\n\n\n\n\nend\n\n\nEnd date column name. Default is \"end\"\n\n\n\n\nsep\n\n\nSeparator between start and end date. Default is \"-\"\n\n\n\n\nformat\n\n\nDate format. Default is \"%M %Y\"\n\n\n\n\ncolname_date\n\n\nName for the generated date column. Default is \"date\"\n\n\n\n\nreplace_na\n\n\nValue to replace NA values. Default is \"Present\"\n\n\n\n\nsort_by\n\n\nSort by \"none\", \"start\" or \"end\". Default is \"none\"\n\n\n\n\ndecreasing\n\n\nSort in decreasing order. Default is TRUE\n\n\n\n\n\n\nData frame with formatted date column\n\n\n\n\nlibrary(typstcv)\n\nwork |>\n format_date(format = \"%Y\", sort_by = \"start\") |>\n resume_entry()\n\n```{=typst}\n#resume-entry(title: \"Associate Professor\",location: \"Zürich, Switzerland\",date: \"1909-1911\",description: \"University of Zürich\",)\n#resume-entry(title: \"Junior Professor\",location: \"Bern, Switzerland\",date: \"1908-1909\",description: \"University of Bern\",)\n#resume-entry(title: \"Technical Assistant\",location: \"Bern, Switzerland\",date: \"1902-1908\",description: \"Federal Patent Office\",)\n```", + "text": "Data Column Formatter\n\n\n\nformat_date(\n data,\n start = \"start\",\n end = NULL,\n sep = \" - \",\n date_format = \"%M %Y\",\n colname_date = \"date\",\n replace_na = \"Present\",\n sort_by = \"none\",\n decreasing = TRUE\n)\n\n\n\n\n\n\n\ndata\n\n\nData frame for resume entry\n\n\n\n\nstart\n\n\nStart date column name. Default is \"start\"\n\n\n\n\nend\n\n\nOptional. End date column name.\n\n\n\n\nsep\n\n\nSeparator between start and end date. Default is \" - \"\n\n\n\n\ndate_format\n\n\nDate format. Default is \"%M %Y\"\n\n\n\n\ncolname_date\n\n\nName for the generated date column. Default is \"date\"\n\n\n\n\nreplace_na\n\n\nValue to replace NA values. Default is \"Present\"\n\n\n\n\nsort_by\n\n\nSort by \"none\", \"start\" or \"end\". Default is \"none\"\n\n\n\n\ndecreasing\n\n\nSort in decreasing order. Default is TRUE\n\n\n\n\n\n\nData frame with formatted date column\n\n\n\n\nlibrary(typstcv)\n\nwork |>\n format_date(end = \"end\", date_format = \"%Y\", sort_by = \"start\") |>\n resume_entry()\n\n```{=typst}\n#resume-entry(title: \"Associate Professor\",location: \"Zürich, Switzerland\",date: \"1909 - 1911\",description: \"University of Zürich\",)\n#resume-entry(title: \"Junior Professor\",location: \"Bern, Switzerland\",date: \"1908 - 1909\",description: \"University of Bern\",)\n#resume-entry(title: \"Technical Assistant\",location: \"Bern, Switzerland\",date: \"1902 - 1908\",description: \"Federal Patent Office\",)\n```", "crumbs": [ "Reference", "format_date" @@ -102,7 +102,7 @@ "href": "index.html", "title": "typstcv", "section": "", - "text": "This package provides helper functinons for kazuyanagimoto/quarto-awesomecv-typst. This work are inspired by these three works:\n\nByungjin Park’s Awesome-CV\n\nA beautiful LaTeX template of CV\n\nPaul Tsouchlos’s modern-cv\n\nA Typst implementation of Awesome-CV\n\nMitchell O’Hara-Wild and Rob Hyndman’s vitae\n\nR package for modern CV, including Awesome-CV\n\n\n\n\nYou can install the development version of typstcv from R-universe with:\ninstall.packages(\"typstcv\", repos = \"https://kazuyanagimoto.r-universe.dev\")\n\n\n\nYou can find a simple example and qmd code.\n\n\nYou can use the template with quarto command.\nquarto use template kazuyanagimoto/quarto-awesomecv-typst\n\n\n\nSet author information in YAML.\nauthor:\n firstname: Albert\n lastname: Einstein\n address: \"Rämistrasse 101, CH-8092 Zürich, Switzerland, Zürich\"\n position: \"Research Physicist・Professor\"\n contacts:\n - icon: fa envelope\n text: ae@example.com\n url: \"mailto:ae@example.com\"\n - icon: PATH_TO_ICON/icon.svg\n text: example.com\n url: https://example.com\n\nfontawesome icons are supported via duskmoon314/typst-fontawesome with fa prefix.\nSVG icons can be used by specifying the path to the icon file\n\n\n\n\nYou can set fonts and the accent color in YAML.\nstyle:\n color-accent: \"516db0\"\n font-header: \"Roboto\"\n font-text: \"Source Sans Pro\"\nformat:\n awesomecv-typst:\n font-paths: [\"PATH_TO_FONT\"]\n\n\n\nresume_entry() is a helper function to create resume entryies from a data frame.\neduc |>\n resume_entry(\n title = \"title\",\n location = \"location\",\n date = \"year\",\n description = \"detail\"\n)\n\n\n\ndate_formatter() is a helper function to format dates in the resume.\nwork |>\n format_date(\n start = \"date_start\",\n end = \"date_end\",\n format = \"%Y\",\n sep = \"->\",\n sort_by = \"start\"\n ) |>\n resume_entry()", + "text": "This package provides helper functinons for kazuyanagimoto/quarto-awesomecv-typst. This work are inspired by these three works:\n\nByungjin Park’s Awesome-CV\n\nA beautiful LaTeX template of CV\n\nPaul Tsouchlos’s modern-cv\n\nA Typst implementation of Awesome-CV\n\nMitchell O’Hara-Wild and Rob Hyndman’s vitae\n\nR package for modern CV, including Awesome-CV\n\n\n\n\nYou can install the development version of typstcv from R-universe with:\ninstall.packages(\"typstcv\", repos = \"https://kazuyanagimoto.r-universe.dev\")\n\n\n\nYou can find a simple example and qmd code.\n\n\nYou can use the template with quarto command.\nquarto use template kazuyanagimoto/quarto-awesomecv-typst\n\n\n\nSet author information in YAML.\nauthor:\n firstname: Albert\n lastname: Einstein\n address: \"Rämistrasse 101, CH-8092 Zürich, Switzerland, Zürich\"\n position: \"Research Physicist・Professor\"\n contacts:\n - icon: fa envelope\n text: ae@example.com\n url: \"mailto:ae@example.com\"\n - icon: PATH_TO_ICON/icon.svg\n text: example.com\n url: https://example.com\n\nfontawesome icons are supported via duskmoon314/typst-fontawesome with fa prefix.\nSVG icons can be used by specifying the path to the icon file\n\n\n\n\nYou can set fonts and the accent color in YAML.\nstyle:\n color-accent: \"516db0\"\n font-header: \"Roboto\"\n font-text: \"Source Sans Pro\"\nformat:\n awesomecv-typst:\n font-paths: [\"PATH_TO_FONT\"]\n\n\n\nresume_entry() is a helper function to create resume entryies from a data frame.\neduc |>\n resume_entry(\n title = \"title\",\n location = \"location\",\n date = \"year\",\n description = \"detail\"\n)\n\n\n\ndate_formatter() is a helper function to format dates in the resume.\nwork |>\n format_date(\n start = \"date_start\",\n end = \"date_end\",\n date_format = \"%Y\",\n sep = \"->\",\n sort_by = \"start\"\n ) |>\n resume_entry()", "crumbs": [ "Home" ] @@ -122,7 +122,7 @@ "href": "index.html#usage", "title": "typstcv", "section": "", - "text": "You can find a simple example and qmd code.\n\n\nYou can use the template with quarto command.\nquarto use template kazuyanagimoto/quarto-awesomecv-typst\n\n\n\nSet author information in YAML.\nauthor:\n firstname: Albert\n lastname: Einstein\n address: \"Rämistrasse 101, CH-8092 Zürich, Switzerland, Zürich\"\n position: \"Research Physicist・Professor\"\n contacts:\n - icon: fa envelope\n text: ae@example.com\n url: \"mailto:ae@example.com\"\n - icon: PATH_TO_ICON/icon.svg\n text: example.com\n url: https://example.com\n\nfontawesome icons are supported via duskmoon314/typst-fontawesome with fa prefix.\nSVG icons can be used by specifying the path to the icon file\n\n\n\n\nYou can set fonts and the accent color in YAML.\nstyle:\n color-accent: \"516db0\"\n font-header: \"Roboto\"\n font-text: \"Source Sans Pro\"\nformat:\n awesomecv-typst:\n font-paths: [\"PATH_TO_FONT\"]\n\n\n\nresume_entry() is a helper function to create resume entryies from a data frame.\neduc |>\n resume_entry(\n title = \"title\",\n location = \"location\",\n date = \"year\",\n description = \"detail\"\n)\n\n\n\ndate_formatter() is a helper function to format dates in the resume.\nwork |>\n format_date(\n start = \"date_start\",\n end = \"date_end\",\n format = \"%Y\",\n sep = \"->\",\n sort_by = \"start\"\n ) |>\n resume_entry()", + "text": "You can find a simple example and qmd code.\n\n\nYou can use the template with quarto command.\nquarto use template kazuyanagimoto/quarto-awesomecv-typst\n\n\n\nSet author information in YAML.\nauthor:\n firstname: Albert\n lastname: Einstein\n address: \"Rämistrasse 101, CH-8092 Zürich, Switzerland, Zürich\"\n position: \"Research Physicist・Professor\"\n contacts:\n - icon: fa envelope\n text: ae@example.com\n url: \"mailto:ae@example.com\"\n - icon: PATH_TO_ICON/icon.svg\n text: example.com\n url: https://example.com\n\nfontawesome icons are supported via duskmoon314/typst-fontawesome with fa prefix.\nSVG icons can be used by specifying the path to the icon file\n\n\n\n\nYou can set fonts and the accent color in YAML.\nstyle:\n color-accent: \"516db0\"\n font-header: \"Roboto\"\n font-text: \"Source Sans Pro\"\nformat:\n awesomecv-typst:\n font-paths: [\"PATH_TO_FONT\"]\n\n\n\nresume_entry() is a helper function to create resume entryies from a data frame.\neduc |>\n resume_entry(\n title = \"title\",\n location = \"location\",\n date = \"year\",\n description = \"detail\"\n)\n\n\n\ndate_formatter() is a helper function to format dates in the resume.\nwork |>\n format_date(\n start = \"date_start\",\n end = \"date_end\",\n date_format = \"%Y\",\n sep = \"->\",\n sort_by = \"start\"\n ) |>\n resume_entry()", "crumbs": [ "Home" ] diff --git a/vignettes/awesomecv/awesomecv.pdf b/vignettes/awesomecv/awesomecv.pdf index 013df8a..d70eac5 100644 Binary files a/vignettes/awesomecv/awesomecv.pdf and b/vignettes/awesomecv/awesomecv.pdf differ diff --git a/vignettes/gallery.html b/vignettes/gallery.html index adbac46..a81a53c 100644 --- a/vignettes/gallery.html +++ b/vignettes/gallery.html @@ -291,7 +291,7 @@

Gallery

-
+