add bookdown import and tidy up rmd
diff --git a/DESCRIPTION b/DESCRIPTION
index 5bf0181..d391b08 100644
--- a/DESCRIPTION
+++ b/DESCRIPTION
@@ -17,6 +17,6 @@
LazyData: true
URL: https://github.com/brentthorne/posterdown
BugReports: https://github.com/brentthorne/posterdown/issues
-Imports: rmarkdown, knitr, yaml, tinytex, ggplot2, rticles, kableExtra, Cairo
+Imports: rmarkdown, bookdown, knitr, yaml, tinytex, ggplot2, rticles, kableExtra, Cairo
SystemRequirements: GNU make
RoxygenNote: 6.1.1
diff --git a/NAMESPACE b/NAMESPACE
index aa88438..de5bf6c 100644
--- a/NAMESPACE
+++ b/NAMESPACE
@@ -1,6 +1,7 @@
# Generated by roxygen2: do not edit by hand
export(posterdown_pdf)
+import(bookdown)
import(ggplot2)
import(knitr)
import(rmarkdown)
diff --git a/R/posterdown.R b/R/posterdown.R
index fd1e995..ea111c6 100644
--- a/R/posterdown.R
+++ b/R/posterdown.R
@@ -9,6 +9,7 @@
#' @docType package
#' @name posterdown
#' @import rmarkdown
+#' @import bookdown
#' @import ggplot2
#' @import knitr
NULL
diff --git a/R/posterdown_pdf.R b/R/posterdown_pdf.R
index 06f5bd7..7890f49 100644
--- a/R/posterdown_pdf.R
+++ b/R/posterdown_pdf.R
@@ -1,4 +1,4 @@
-#' Posterdown PDF format (using 'memoir' document class)
+#' Posterdown PDF format (using Memoir LaTeX document class)
#'
#' @inheritParams rmarkdown::pdf_document
#' @param ... Additional arguments to \code{rmarkdown::pdf_document}
@@ -10,9 +10,9 @@
#'
#' \dontrun{
#' library(rmarkdown)
-#' draft("MyArticle.Rmd", template = "posterdown_generic", package = "posterdown")
+#' draft("MyArticle.Rmd", template = "posterdown_pdf", package = "posterdown")
#' }
-#'
+#' @return
#' @export
posterdown_pdf <- function(..., keep_tex = TRUE) {
inherit_pdf_document(...,
diff --git a/R/utils.R b/R/utils.R
index 2aa1fa3..fdf4d97 100644
--- a/R/utils.R
+++ b/R/utils.R
@@ -76,7 +76,3 @@
# return format
fmt
}
-
-
-
-
diff --git a/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure1_map.pdf b/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure1_map.pdf
deleted file mode 100644
index f282986..0000000
--- a/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure1_map.pdf
+++ /dev/null
Binary files differ
diff --git a/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure2.pdf b/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure2.pdf
deleted file mode 100644
index b58a47e..0000000
--- a/inst/rmarkdown/templates/posterdown_pdf/skeleton/Figures/figure2.pdf
+++ /dev/null
Binary files differ
diff --git a/inst/rmarkdown/templates/posterdown_pdf/skeleton/skeleton.Rmd b/inst/rmarkdown/templates/posterdown_pdf/skeleton/skeleton.Rmd
index 19a7269..6e6dc6a 100644
--- a/inst/rmarkdown/templates/posterdown_pdf/skeleton/skeleton.Rmd
+++ b/inst/rmarkdown/templates/posterdown_pdf/skeleton/skeleton.Rmd
@@ -1,5 +1,4 @@
---
-#
# PLEASE SEE THE README for in depth description github.com/brentthorne/posterdown
#
#---POSTER SIZE & DEFAULT FONT---#
@@ -83,6 +82,7 @@
```{r, out.width="80%", fig.cap='This is a map of Canada, the ggspatial package is great for GIS folks in R! \\label{mymapfig}', cache=TRUE}
library(ggplot2)
library(ggspatial)
+library(tidyverse)
library(ggthemes)
library(sf)
diff --git a/man/posterdown_pdf.Rd b/man/posterdown_pdf.Rd
index add1004..a0e5906 100644
--- a/man/posterdown_pdf.Rd
+++ b/man/posterdown_pdf.Rd
@@ -2,7 +2,7 @@
% Please edit documentation in R/posterdown_pdf.R
\name{posterdown_pdf}
\alias{posterdown_pdf}
-\title{Posterdown PDF format (using 'memoir' document class)}
+\title{Posterdown PDF format (using Memoir LaTeX document class)}
\usage{
posterdown_pdf(..., keep_tex = TRUE)
}
@@ -16,13 +16,12 @@
\code{\link[rmarkdown:render]{render}}
}
\description{
-Posterdown PDF format (using 'memoir' document class)
+Posterdown PDF format (using Memoir LaTeX document class)
}
\examples{
\dontrun{
library(rmarkdown)
-draft("MyArticle.Rmd", template = "posterdown_generic", package = "posterdown")
+draft("MyArticle.Rmd", template = "posterdown_pdf", package = "posterdown")
}
-
}