Skip to content

Commit 12d1476

Browse files
committed
HTML term index table now creates one id= per cell rather than per term, fixing an HTML tidy warning.
1 parent 5d5db81 commit 12d1476

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

DESCRIPTION

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: ergm
2-
Version: 4.3-7009
3-
Date: 2022-09-10
2+
Version: 4.3-7049
3+
Date: 2022-09-30
44
Title: Fit, Simulate and Diagnose Exponential-Family Models for Networks
55
Authors@R: c(
66
person("Mark S.", "Handcock", role=c("aut"), email="[email protected]"),

R/ergm-terms-index.R

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,10 @@ PROPOSAL_NOT_IN_TABLE <- "This proposal is not referenced in the lookup table."
518518
# \link[=absdiff-ergmTerm]{test} and check that it works with \out{<a href="../help/absdiff-ergmTerm">test</a>}.
519519
# This address may change from an upstream R-studio change
520520

521-
df$Term <- sprintf(gsub('`([^`(]*)([^`]*)`', '<span class="code"><a href="../help/%1$s" id="%1$s">\\1\\2</a></span>', .fsub(df$Term, '\n', '<br />\n')), df$Link)
521+
df$Term %<>% .fsub('\n', '<br />\n') %>%
522+
gsub('`([^`(]*)([^`]*)`', '<span class="code"><a href="../help/%1$s">\\1\\2</a></span>', .) %>%
523+
sprintf(df$Link) %>%
524+
sprintf('<div id="%s">%s</div>', df$Link, .)
522525
df$Link <- NULL
523526

524527
css <- '<style>.striped th,.striped td {padding:3px 10px} .striped tbody tr:nth-child(odd) {background: #eee} .striped .code {font-family: monospace} .matrix td {align: center} .matrix th,.matrix td {padding-right:5px; width: 75px}</style>'

0 commit comments

Comments
 (0)