From 944d7175ef136d655b6a83b42cc186ae3e200a6d Mon Sep 17 00:00:00 2001 From: mpadge Date: Tue, 19 Mar 2024 16:47:11 +0100 Subject: [PATCH] improve ed-rev table for #7 --- DESCRIPTION | 2 +- codemeta.json | 2 +- quarto/ed-reviews.qmd | 17 ++++++++++++----- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index ac1a1b6..dc118a6 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: dashboard Title: What the Package Does (One Line, Title Case) -Version: 0.0.6.001 +Version: 0.0.6.002 Authors@R: person(given = "First", family = "Last", diff --git a/codemeta.json b/codemeta.json index a584eef..757cff5 100644 --- a/codemeta.json +++ b/codemeta.json @@ -6,7 +6,7 @@ "name": "dashboard: What the Package Does (One Line, Title Case)", "codeRepository": "https://github.com/ropensci-review-tools/dashboard", "license": "https://spdx.org/licenses/MIT", - "version": "0.0.6.001", + "version": "0.0.6.002", "programmingLanguage": { "@type": "ComputerLanguage", "name": "R", diff --git a/quarto/ed-reviews.qmd b/quarto/ed-reviews.qmd index f0c9fa0..d46546a 100644 --- a/quarto/ed-reviews.qmd +++ b/quarto/ed-reviews.qmd @@ -22,12 +22,16 @@ ed_reviews <- ed_dat$reviews ## Editor Reviews This panel provides data on reviews handled by each editor. Data are shown for -current editors only. +current editors only, with reviews listed from most to least recent. ```{r ed-rev, echo = FALSE, message = FALSE, results = 'asis'} u <- "https://github.com/ropensci/software-review/issues/" for (i in seq_along (ed_reviews)) { this_ed <- names (ed_reviews) [i] + this_tab <- ed_reviews [[i]] + this_tab <- this_tab [order (this_tab$number, decreasing = TRUE), ] + num_rev <- nrow (this_tab) + rev_noun <- ifelse (num_rev == 1, "Review", "Reviews") cat (paste0 ( "## [", this_ed, @@ -35,8 +39,6 @@ for (i in seq_along (ed_reviews)) { this_ed, ")\n\n" )) - cat (paste0 ("Total Reviews: ", nrow (ed_reviews [[i]]), "\n\n")) - this_tab <- ed_reviews [[i]] this_tab$number <- paste0 ( " + dashboard:::add_bg_colours () + print (tab) } ```