Skip to content

Commit

Permalink
Change title for reference page (#2475)
Browse files Browse the repository at this point in the history
To something that isn't so function specific. Fixes #2181.
  • Loading branch information
hadley authored May 3, 2024
1 parent a8e849c commit c35fa8c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# pkgdown (development version)

* The title for the "Reference" page is now "Package index" since this page might contain more than just function details (#2181).
* `build_redirects()` now automatically adds redirects for topic
aliases. This matches the behaviour of `?` and will help keep links stable in the long term (#1876).
* `build_redirects()` now reports which redirects it is generating.
Expand Down
2 changes: 1 addition & 1 deletion R/build-reference-index.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ data_reference_index <- function(pkg = ".", error_call = caller_env()) {
rows <- Filter(function(x) !x$is_internal, rows)

print_yaml(list(
pagetitle = tr_("Function reference"),
pagetitle = tr_("Package index"),
rows = rows,
has_icons = has_icons
))
Expand Down
2 changes: 1 addition & 1 deletion po/R-pkgdown.pot
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ msgid "CRAN release: %s"
msgstr ""

#: build-reference-index.R:22
msgid "Function reference"
msgid "Package index"
msgstr ""

#: build-reference-index.R:132
Expand Down
6 changes: 3 additions & 3 deletions tests/testthat/_snaps/build-reference-index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Code
data_reference_index(pkg)
Output
pagetitle: Function reference
pagetitle: Package index
rows:
- title: A
slug: a
Expand Down Expand Up @@ -100,7 +100,7 @@
Code
data_reference_index(pkg)
Output
pagetitle: Function reference
pagetitle: Package index
rows:
- title: bla
slug: bla
Expand Down Expand Up @@ -160,7 +160,7 @@
Code
data_reference_index(pkg)
Output
pagetitle: Function reference
pagetitle: Package index
rows:
- title: bla
slug: bla
Expand Down

0 comments on commit c35fa8c

Please sign in to comment.