-
-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
1 parent
41fa5f9
commit c28edfd
Showing
6 changed files
with
120 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
library(shinythemes) | ||
## basic ui.R | ||
theme <- "{{ theme }}" | ||
if(!nzchar(theme)) theme <- "cerulean" | ||
|
||
the_theme <- shinytheme(theme) | ||
|
||
# a list of the model objects | ||
models <- {{ model_list }} | ||
|
||
# uses models (a list of models) to create the model UI | ||
shinytheme_tabPanel <- function(models){ | ||
model_n <- paste0("model", seq_along(models)) | ||
tabPanels <- mapply(function(x,y) tabPanel(y$model$description, y$ui(x)), | ||
x=model_n, y=models, | ||
SIMPLIFY = FALSE) | ||
do.call(tabsetPanel, args = unname(tabPanels)) | ||
} | ||
|
||
navbarPage( | ||
title = "{{ shiny_title }}", | ||
theme = the_theme, | ||
tabPanel("Models", | ||
{{ auth_ui }}, | ||
sidebarPanel( | ||
{{{ date_range }}} | ||
), | ||
mainPanel( | ||
shinytheme_tabPanel(models) | ||
) | ||
) | ||
) | ||
|
||
|
||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.