#' Posterdown IDS-CD based on HTML format (using pagedown::poster_relaxed)
#'
#' @inheritParams pagedown::poster_relaxed
#' @param ... Additional arguments to `rmarkdown::html_document`
#'
#' @return R Markdown output format to pass to
#'   [rmarkdown::render()]
#'
#'@examples
#'\donttest{
#'file <- file.path(tempdir(),"foo.rmd")
#'rmarkdown::draft(file, template="posterdown_ids", package="posterdown.ids")
#'}
#'
#' @description The output format `posterdown_ids()` mimics the IDS Mannheim
#' corporate design posters.
#' @rdname posterdown_ids
#' @export
posterdown_ids <- function(...,
                            template = find_resource("posterdown_ids", "template.html"),
                            css = NULL) {
  pagedown::poster_relaxed(..., css = css, template = template)
}


#' @description Print html code for a linked qr code to the given url
#' @importFrom qrcode add_logo qr_code generate_svg
#' @export
qrlink <- function(url, logo = NULL) {
  tmp <- tempfile(fileext = ".svg")
  qrcode <- qrcode::qr_code(url, ecl =  if(is.null(logo)) "L" else "H")
  if(!is.null(logo)) {
    qrcode <- qrcode::add_logo(qrcode, logo, ecl = "L")
  }
  qrcode::generate_svg(qrcode, tmp,  show = FALSE)
  return(paste0( sprintf('<a class="qrcode" href="%s"><img class="qrcode">', url),
                 gsub("\r?\n|\r", "", readChar(tmp, 1e7)),
                 '</img></a>'
         ))
}

