How can I eliminate the sidebar for page 2 onwards in the resume template? (no information after page 1)
Opened this issue ยท 6 comments
Hi, sorry if this is not the place to post this, but I want to remove the sidebar from the resume after the first page (the 2nd and 3rd page have no information on the sidebar). Is this possible?
Hi,
There is a hacky way to eliminate the grey background of the sidebar. You can use this CSS rule:
.pagedjs_page:not(:first-of-type) {
background: white;
}
You can use the CSS chunk engine to insert this rule in your Rmd file:
---
title: "Lijia Yu's resume"
author: Lijia Yu
date: "`r Sys.Date()`"
output:
pagedown::html_resume:
self_contained: false
---
```{css, echo=FALSE}
.pagedjs_page:not(:first-of-type) {
background: white;
}
```
Aside
================================================================================
![Lijia Yu](https://avatars1.githubusercontent.com/u/895125?s=400&v=4){width=80%}
Using @RLesur's approach, I included this on my .css file, and it did the trick.
.pagedjs_page:not(:first-of-type) {
--sidebar-width: 0rem;
--sidebar-background-color: #ffffff;
--main-width: calc(var(--content-width) - var(--sidebar-width));
--decorator-horizontal-margin: 0.2in;
}
Works great, thanks!
For reference, this question on RStudio Community explains that @maibennett's solution was broken by pagedown 0.14 (thanks, @wjakethompson).
This is related to #211.
We can still use @maibennett's solution if we include the CSS rules in a CSS chunk and not in a CSS file (sorry for that).
See my answer on RStudio Community.
.pagedjs_page:
What if I want to resume the sidebar in specific page ?