diff --git a/R/comparison_editor.R b/R/comparison_editor.R index cc7800d..a7c76ef 100644 --- a/R/comparison_editor.R +++ b/R/comparison_editor.R @@ -4,7 +4,7 @@ #' @noRd comparison_editor_ui <- function(id, options) { verticalLayout( - h3("Comparison"), + h5("Comparison"), selectInput( NS(id, "comparison_genes"), "Comparison genes", diff --git a/R/details.R b/R/details.R index 6fc2185..ddd0d87 100644 --- a/R/details.R +++ b/R/details.R @@ -8,11 +8,15 @@ details_ui <- function(id) { splitLayout( cellWidths = "auto", uiOutput(NS(id, "copy")), - downloadButton(NS(id, "download"), "Download CSV") + downloadButton( + NS(id, "download"), + "Download CSV", + class = "btn-outline-primary" + ) ) ), div( - style = "margin-top: 16px", + style = "margin-top: 16px; margin-bottom: 8px;", DT::DTOutput(NS(id, "genes")) ) ) @@ -43,13 +47,15 @@ details_server <- function(id, options, results) { "copy_ids_button", "Copy gene IDs", genes_text, - icon = icon("clipboard") + icon = icon("clipboard"), + class = "btn-outline-primary" ), rclipboard::rclipButton( "copy_names_button", "Copy gene names", names_text, - icon = icon("clipboard") + icon = icon("clipboard"), + class = "btn-outline-primary" ) ) }) diff --git a/R/filters.R b/R/filters.R index 382a08f..d3bf86c 100644 --- a/R/filters.R +++ b/R/filters.R @@ -2,18 +2,22 @@ filters_ui <- function(id) { div( class = "well", - style = "margin-top: 24px; margin-bottom: 16px; padding-top: 24px;", + style = "margin-top: 24px; margin-bottom: 16px;", verticalLayout( - radioButtons( - NS(id, "method"), - label = NULL, - choices = list( - "Filter percentiles" = "percentile", - "Filter scores" = "score", - "Filter ranks" = "rank", - "No filtering" = "none" - ), - inline = TRUE + h5("Filter criteria"), + div( + style = "margin-top: 8px;", + radioButtons( + NS(id, "method"), + label = NULL, + choices = list( + "Filter percentiles" = "percentile", + "Filter scores" = "score", + "Filter ranks" = "rank", + "No filtering" = "none" + ), + inline = TRUE + ) ), tabsetPanel( id = NS(id, "sliders"), diff --git a/R/methods.R b/R/methods.R index e56d8cd..96d719d 100644 --- a/R/methods.R +++ b/R/methods.R @@ -1,7 +1,7 @@ # Construct UI for the methods editor. methods_ui <- function(id, options) { verticalLayout( - h3("Methods"), + h5("Methods"), selectInput( NS(id, "optimization_genes"), "Genes to optimize for", diff --git a/R/preset_editor.R b/R/preset_editor.R index 466cf38..08438ef 100644 --- a/R/preset_editor.R +++ b/R/preset_editor.R @@ -16,7 +16,7 @@ preset_editor_ui <- function(id, options) { } verticalLayout( - h3("Inputs"), + h5("Inputs"), selectInput( NS(id, "species"), "Species to include", diff --git a/R/results.R b/R/results.R index 7a4a96b..e70c4ad 100644 --- a/R/results.R +++ b/R/results.R @@ -37,7 +37,22 @@ results_ui <- function(id, options) { ) ), tabPanel( - title = "Method comparison", + title = "Gene sets", + div( + style = "margin-top: 16px", + htmlOutput(NS(id, "comparison_text")), + div( + style = "margin-top: 16px;", + plotly::plotlyOutput( + NS(id, "boxplot"), + width = "100%", + height = "600px" + ) + ) + ) + ), + tabPanel( + title = "Methods", div( style = "margin-top: 16px", plotly::plotlyOutput( @@ -100,29 +115,6 @@ results_ui <- function(id, options) { height = "600px" ) ), - tabPanel( - title = "Comparison", - div( - style = "margin-top: 16px", - htmlOutput(NS(id, "comparison_text")), - plotly::plotlyOutput( - NS(id, "boxplot"), - width = "100%", - height = "600px" - ) - ) - ), - tabPanel( - title = "Ortholog locations", - div( - style = "margin-top: 16px", - plotly::plotlyOutput( - NS(id, "gene_locations_plot"), - width = "100%", - height = "1200px" - ) - ) - ), tabPanel( title = "Scores by position", div( @@ -143,6 +135,17 @@ results_ui <- function(id, options) { ) ) ), + tabPanel( + title = "Ortholog locations", + div( + style = "margin-top: 16px", + plotly::plotlyOutput( + NS(id, "gene_locations_plot"), + width = "100%", + height = "1200px" + ) + ) + ), tabPanel( title = "Detailed results", details_ui(NS(id, "results")) @@ -330,7 +333,10 @@ results_server <- function(id, options, analysis) { if (!is.null(comparison)) { div( reference_div, - div(HTML(comparison_text("comparison genes", comparison))) + div( + style = "margin-top: 16px;", + HTML(comparison_text("comparison genes", comparison)) + ) ) } else { reference_div diff --git a/R/style.R b/R/style.R index a277fb2..1235984 100644 --- a/R/style.R +++ b/R/style.R @@ -9,7 +9,9 @@ custom_css <- function() { "vertical-align: top;", "margin-right: 12px;", "}", - ".shiny-input-container { width: auto !important; min-width: 200px; }" + ".shiny-input-container { width: auto !important; min-width: 200px; }", + "h5 { margin-top: 0.5rem; margin-bottom: 1rem; font-weight: bold; }", + ".navbar-brand { font-weight: bold; }" )) ) }