Skip to content

Commit 2104d0e

Browse files
committed
CSS added for better printing
1 parent 9e8b03a commit 2104d0e

27 files changed

+422
-98
lines changed

inst/tutorials/A00La_discovery/A00La_discovery.Rmd

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,3 +232,15 @@ Si vous voulez, vous pouvez encore tester d'autres commandes R ci-dessous :
232232
```{r code_noscore-check}
233233
234234
```
235+
236+
```{css, echo=FALSE}
237+
@media print {
238+
.topics {
239+
width: 100% !important;
240+
padding: 0 0.5em 0 !important;
241+
}
242+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
243+
display: none !important;
244+
}
245+
}
246+
```

inst/tutorials/A01La_base/A01La_base.Rmd

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -530,3 +530,15 @@ question_text(
530530
allow_retry = TRUE
531531
)
532532
```
533+
534+
```{css, echo=FALSE}
535+
@media print {
536+
.topics {
537+
width: 100% !important;
538+
padding: 0 0.5em 0 !important;
539+
}
540+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
541+
display: none !important;
542+
}
543+
}
544+
```

inst/tutorials/A01La_tools/A01La_tools.Rmd.notusedanymore

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: "**SDD I Module 1** Familiarisation avec les logiciels du cours."
55
tutorial:
66
id: "A01La_tools"
77
version: 2.2.1/4
8-
output:
8+
output:
99
learnr::tutorial:
1010
progressive: true
1111
allow_skip: true
@@ -99,3 +99,15 @@ question_text(
9999
allow_retry = TRUE
100100
)
101101
```
102+
103+
```{css, echo=FALSE}
104+
@media print {
105+
.topics {
106+
width: 100% !important;
107+
padding: 0 0.5em 0 !important;
108+
}
109+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
110+
display: none !important;
111+
}
112+
}
113+
```

inst/tutorials/A01Lb_scatterplot/A01Lb_scatterplot.Rmd

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,3 +365,15 @@ question_text(
365365
allow_retry = TRUE
366366
)
367367
```
368+
369+
```{css, echo=FALSE}
370+
@media print {
371+
.topics {
372+
width: 100% !important;
373+
padding: 0 0.5em 0 !important;
374+
}
375+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
376+
display: none !important;
377+
}
378+
}
379+
```

inst/tutorials/A02La_progression/A02La_progression.Rmd.inactivated

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ Le calcul un à un de l'IMC de chaque individu deviendra très rapidement fastid
264264
weight_w <- c(69, 49, 75, 66, 54)
265265
# Assignation des valeurs de tailles dans un vecteur nommé `height_w`
266266
height_w <- c(174, 155, 169, 179, 168)
267-
# Transformation du vecteur `height_w` de centimètre en mètre
267+
# Transformation du vecteur `height_w` de centimètre en mètre
268268
height_w <- height_w / 100
269269
# Calcul de l'IMC/BMI
270270
weight_w / height_w^2
@@ -299,7 +299,7 @@ Réalisez les mêmes opérations sur les individus 8 à 12 qui sont des hommes.
299299
weight_m <- c(___)
300300
# Assignation des valeurs de tailles dans un vecteur nommé `height_m`
301301
height_m <- ___
302-
# Transformation du vecteur `height_m` de centimètre en mètre
302+
# Transformation du vecteur `height_m` de centimètre en mètre
303303
height_m <- height_m / 100
304304
# Calcul de IMC
305305
___
@@ -310,7 +310,7 @@ ___
310310
weight_m <- c(82, 73, 105, 61, 95)
311311
# Assignation des valeurs de tailles dans un vecteur nommé `height_m`
312312
height_m <- ___
313-
# Transformation du vecteur `height_m` de centimètre en mètre
313+
# Transformation du vecteur `height_m` de centimètre en mètre
314314
height_m <- ___
315315
# Calcul de IMC
316316
weight_m / height_m^2
@@ -324,7 +324,7 @@ weight_m / height_m^2
324324
weight_m <- c(82, 73, 105, 61, 95)
325325
# Assignation des valeurs de tailles dans un vecteur nommé `height_m`
326326
height_m <- c(174, 186, 203, 172, 190)
327-
# Transformation du vecteur `height_m` de centimètre en mètre
327+
# Transformation du vecteur `height_m` de centimètre en mètre
328328
height_m <- height_m / 100
329329
# Calcul de IMC
330330
weight_m / height_m^2
@@ -470,7 +470,7 @@ Pour calculer l'IMC sur le jeu de données `bio_100`, nous employons à nouveau
470470

471471
```{r, echo=TRUE}
472472
bio_100 <- smutate(bio_100, bmi = weight / (height / 100)^2)
473-
# Afficher les premières lignes du tableau de données
473+
# Afficher les premières lignes du tableau de données
474474
head(bio_100, n = 5)
475475
```
476476

@@ -571,7 +571,7 @@ biometry <- smutate(biometry, bmi_cat = case_when(
571571
bmi>= 25 & bmi < 30 ~"overweight",
572572
bmi >= 30 ~ "obese"
573573
))
574-
# Afficher les 5 premières lignes du tableau
574+
# Afficher les 5 premières lignes du tableau
575575
head(biometry)
576576
```
577577

@@ -758,3 +758,15 @@ question_text(
758758
allow_retry = TRUE
759759
)
760760
```
761+
762+
```{css, echo=FALSE}
763+
@media print {
764+
.topics {
765+
width: 100% !important;
766+
padding: 0 0.5em 0 !important;
767+
}
768+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
769+
display: none !important;
770+
}
771+
}
772+
```

inst/tutorials/A02Lb_univariate/A02Lb_univariate.Rmd.inactivated

Lines changed: 25 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ runtime: shiny_prerendered
1717
BioDataScience1::learnr_setup()
1818
SciViews::R()
1919
# Dataset
20-
urchin <- read("urchin_bio", package = "data.io", lang = "fr")
20+
urchin <- read("urchin_bio", package = "data.io", lang = "fr")
2121
zooplankton <- read("zooplankton", package = "data.io", lang = "fr")
2222
copepoda <- fsubset(zooplankton, class %in%
2323
c("Calanoid", "Cyclopoid", "Harpacticoid", "Poecilostomatoid"))
@@ -61,17 +61,17 @@ chart(biometry, ~ age | gender) +
6161
```
6262

6363
```{r histo_h3, exercise=TRUE}
64-
chart(___, ~ ___ ___ ___) +
64+
chart(___, ~ ___ ___ ___) +
6565
___(___)
6666
```
6767

6868
```{r histo_h3-hint-1}
69-
chart(DF, ~ ___ | ___) +
69+
chart(DF, ~ ___ | ___) +
7070
geom_histogram(___)
7171
```
7272

7373
```{r histo_h3-hint-2}
74-
chart(biometry, ~ NUM | FACTOR) +
74+
chart(biometry, ~ NUM | FACTOR) +
7575
geom_histogram(bins = ___)
7676

7777
#### Attention : solution dans le 'hint' suivant! ####
@@ -218,30 +218,30 @@ Reproduisez le graphique suivant qui représente la répartition de taille (`siz
218218

219219
```{r ggridges_intro}
220220
chart(copepoda, class ~ size %fill=% class) +
221-
ggridges::geom_density_ridges(show.legend = FALSE)
221+
ggridges::geom_density_ridges(show.legend = FALSE)
222222
```
223223

224224
```{r ggridges_h3, exercise=TRUE}
225225
chart(___, ___ ~ ___ ___ ___) +
226-
___(___)
226+
___(___)
227227
```
228228

229229
```{r ggridges_h3-hint-1}
230230
chart(DF, ___ ~ ___ %fill=% ___) +
231-
ggridges::geom_density_ridges(___)
231+
ggridges::geom_density_ridges(___)
232232
```
233233

234234
```{r ggridges_h3-hint-2}
235235
chart(copepoda, FACTOR ~ NUM %fill=% FACTOR) +
236-
ggridges::geom_density_ridges(show.legend = ___)
236+
ggridges::geom_density_ridges(show.legend = ___)
237237

238238
#### Attention : solution dans le 'hint' suivant! ####
239239
```
240240

241241
```{r ggridges_h3-solution}
242242
## Solution ##
243243
chart(copepoda, class ~ size %fill=% class) +
244-
ggridges::geom_density_ridges(show.legend = FALSE)
244+
ggridges::geom_density_ridges(show.legend = FALSE)
245245
```
246246

247247
```{r ggridges_h3-check}
@@ -254,25 +254,25 @@ Reproduisez le graphique suivant qui représente la répartition de taille (`siz
254254

255255
```{r ggridges2_intro}
256256
chart(zooplankton, class ~ size) +
257-
ggridges::geom_density_ridges()
257+
ggridges::geom_density_ridges()
258258
```
259259

260260
```{r ggridges2_h2, exercise=TRUE}
261261
chart(___, ___ ~ ___) +
262-
___()
262+
___()
263263
```
264264

265265
```{r ggridges2_h2-hint}
266266
chart(DF, FACTOR ~ NUM) +
267-
ggridges::geom_density_ridges()
267+
ggridges::geom_density_ridges()
268268

269269
#### Attention : solution dans le 'hint' suivant! ####
270270
```
271271

272272
```{r ggridges2_h2-solution}
273273
## Solution ##
274274
chart(zooplankton, class ~ size) +
275-
ggridges::geom_density_ridges()
275+
ggridges::geom_density_ridges()
276276
```
277277

278278
```{r ggridges2_h2-check}
@@ -386,3 +386,15 @@ question_text(
386386
allow_retry = TRUE
387387
)
388388
```
389+
390+
```{css, echo=FALSE}
391+
@media print {
392+
.topics {
393+
width: 100% !important;
394+
padding: 0 0.5em 0 !important;
395+
}
396+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
397+
display: none !important;
398+
}
399+
}
400+
```

inst/tutorials/A02Lc_git/A02Lc_git.Rmd.inactivated

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: "**SDD I Module 2** Vocabulaire lié à la gestion de versions avec
55
tutorial:
66
id: "A02Lc_git"
77
version: 2.0.1/6
8-
output:
8+
output:
99
learnr::tutorial:
1010
progressive: true
1111
allow_skip: true
@@ -160,3 +160,15 @@ question_text(
160160
allow_retry = TRUE
161161
)
162162
```
163+
164+
```{css, echo=FALSE}
165+
@media print {
166+
.topics {
167+
width: 100% !important;
168+
padding: 0 0.5em 0 !important;
169+
}
170+
.topicsContainer, .topicsContainer *, .learnrBanner, .learnrBanner *, .topicActions, .topicActions * {
171+
display: none !important;
172+
}
173+
}
174+
```

0 commit comments

Comments
 (0)