diff --git a/R/tt_bootstrap.R b/R/tt_bootstrap.R index e7927831..b9fac76e 100644 --- a/R/tt_bootstrap.R +++ b/R/tt_bootstrap.R @@ -114,8 +114,9 @@ bootstrap_setting <- function(x, new, component = "row") { idx <- grep("tinytable columns before this", out) } else if (component == "cell") { idx <- grep("tinytable cells before this", out) + # idx <- 8 # hard-coded location (dangerous?) } else if (component == "css") { - idx <- grep("", out, fixed = TRUE) + idx <- grep("", out, fixed = TRUE)[1] } else if (component == "newrows") { idx <- grep("tinytable new rows before this", out) } diff --git a/inst/templates/bootstrap.html b/inst/templates/bootstrap.html index 6d98a1c5..51aafa5a 100644 --- a/inst/templates/bootstrap.html +++ b/inst/templates/bootstrap.html @@ -1,44 +1,17 @@ - $tinytable_TABLE_ID - - - - +
- +
$tinytable_BOOTSTRAP_CAPTION $tinytable_BOOTSTRAP_HEADER @@ -50,6 +23,28 @@
+ + + + + diff --git a/vignettes/tutorial.qmd b/vignettes/tutorial.qmd index 5a147ca7..12101ba8 100644 --- a/vignettes/tutorial.qmd +++ b/vignettes/tutorial.qmd @@ -83,7 +83,7 @@ tt(x, align = "ccrrl") The `width` arguments accepts a number between 0 and 1, indicating what proportion of the linewidth the table should cover: ```{r} -tt(x, width = 0.3) +tt(x, width = 0.5) ``` ```{r}