ready for docker update

This commit is contained in:
Andreas Gammelgaard Damsbo 2025-08-27 12:45:02 +02:00
parent fb8ed79ac9
commit 42cc9e7660
No known key found for this signature in database
4 changed files with 146 additions and 60 deletions

View file

@ -3,7 +3,7 @@ RUN apt-get update -y && apt-get install -y cmake make libcurl4-openssl-dev lib
RUN mkdir -p /usr/local/lib/R/etc/ /usr/lib/R/etc/
RUN echo "options(renv.config.pak.enabled = FALSE, repos = c(CRAN = 'https://cran.rstudio.com/'), download.file.method = 'libcurl', Ncpus = 4)" | tee /usr/local/lib/R/etc/Rprofile.site | tee /usr/lib/R/etc/Rprofile.site
RUN R -e 'install.packages("remotes")'
RUN R -e 'remotes::install_version("renv", version = "1.1.4")'
RUN R -e 'remotes::install_version("renv", version = "1.1.5")'
COPY renv.lock renv.lock
RUN --mount=type=cache,id=renv-cache,target=/root/.cache/R/renv R -e 'renv::restore()'
WORKDIR /srv/shiny-server/

View file

@ -3527,7 +3527,8 @@ dummy_Imports <- function() {
cardx::all_of(),
parameters::ci(),
DT::addRow(),
bslib::accordion()
bslib::accordion(),
NHANES::NHANES()
)
# https://github.com/hadley/r-pkgs/issues/828
}
@ -4046,7 +4047,7 @@ simple_snake <- function(data){
#### Current file: /Users/au301842/FreesearchR/R//hosted_version.R
########
hosted_version <- function()'v25.8.1-250808'
hosted_version <- function()'v25.8.1-250827'
########
@ -8486,10 +8487,11 @@ ui_elements <- function(selection) {
icon = shiny::icon("pen-to-square"),
value = "nav_prepare",
bslib::nav_panel(
title = "Overview",
title = "Overview and filter",
icon = shiny::icon("eye"),
value = "nav_prepare_overview",
tags$h3("Overview and filtering"),
# validation_ui("validation_col"),
fluidRow(
shiny::column(
width = 9,
@ -10964,6 +10966,18 @@ server <- function(input, output, session) {
})
# validation_server(id = "validation_col",
# data = purrr::map2(
# .x = validation_lib()[1],
# .y = list(
# list(
# x =
# reactive(rv$data),
# y =
# reactive(rv$data_variables)
# )),
# make_validation))
######### Data filter
# IDEAFilter has the least cluttered UI, but might have a License issue
# Consider using shinyDataFilter, though not on CRAN

File diff suppressed because one or more lines are too long

View file

@ -6,9 +6,10 @@ $(document).on('shown.bs.tab', '#main_panel', function(e) {
$('#main_panel .dropdown-toggle').removeClass('show').attr('aria-expanded', 'false');
});
$(document).on('shiny:sessioninitialized', function() {
// Function to collapse navbar on mobile
function collapseNavbar() {
// Function to collapse navbar on mobile
function collapseNavbar() {
var navbar = $('.navbar-collapse');
if (navbar.hasClass('show')) {
navbar.removeClass('show');
@ -17,13 +18,40 @@ function collapseNavbar() {
}
}
// Add click event to navigation tabs
$(document).on('click', '.nav-link[data-bs-toggle=\"tab\"]', function() {
// Main approach: Handle clicks on nav elements
$(document).on('click', '.navbar-nav .nav-link, .dropdown-item', function(event) {
var $target = $(event.currentTarget);
// Don't collapse if this is a dropdown toggle
if ($target.hasClass('dropdown-toggle')) {
return;
}
// Don't collapse if this is inside a dropdown and the dropdown should stay open
if ($target.hasClass('nav-link') && $target.closest('.dropdown').length &&
!$target.attr('data-bs-toggle')) {
return;
}
// Collapse the navbar after a short delay
setTimeout(collapseNavbar, 10);
});
// Also handle direct clicks on nav items
$(document).on('click', '.navbar-nav .nav-link', function() {
// Handle tab toggles specifically
$(document).on('click', '.nav-link[data-bs-toggle="tab"]', function() {
if (!$(this).hasClass('dropdown-toggle')) {
setTimeout(collapseNavbar, 10);
}
});
// Optional: Handle clicks outside the navbar to close it
$(document).on('click', function(event) {
var navbar = $('.navbar-collapse');
// Check if click is outside navbar and navbar is open
if (navbar.hasClass('show') &&
!$(event.target).closest('.navbar').length) {
collapseNavbar();
}
});
});