just a bit of additional theming

This commit is contained in:
Andreas Gammelgaard Damsbo 2024-12-18 10:37:37 +01:00
commit 7877d95176
No known key found for this signature in database
9 changed files with 2795 additions and 27 deletions

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1 @@
shinyApp(ui, server)

View file

@ -4,7 +4,7 @@ username: agdamsbo
account: agdamsbo
server: shinyapps.io
hostUrl: https://api.shinyapps.io/v1
appId: 13611073
bundleId: 9533439
appId: 13611288
bundleId: 9533633
url: https://agdamsbo.shinyapps.io/freesearcheR/
version: 1

View file

@ -33,19 +33,32 @@ library(DT)
# }
# library(webResearch)
source(here::here("functions.R"))
# source("functions.R")
# light <- custom_theme()
#
# dark <- custom_theme(bg = "#000",
# fg="#fff")
server <- function(input, output, session) {
## Listing files in www in session start to keep when ending and removing
## everything else.
files.to.keep <- list.files("www/")
# observeEvent(input$dark_mode,{
# session$setCurrentTheme(
# if (isTRUE(input$dark_mode)) dark else light
# )})
output$docs_file <- renderUI({
# shiny::includeHTML("www/docs.html")
HTML(readLines("www/docs.html"))
})
rv <- shiny::reactiveValues(
list = NULL,
ds = NULL,
@ -491,3 +504,5 @@ server <- function(input, output, session) {
})
})
}

View file

@ -258,15 +258,18 @@ ui_elements <- list(
)
)
# Initial attempt at creating light and dark versions
light <- custom_theme()
dark <- custom_theme(bg = "#000",
fg="#fff")
# Fonts to consider:
# https://webdesignerdepot.com/17-open-source-fonts-youll-actually-love/
ui <- bslib::page(
title = "freesearcheR",
theme = bslib::bs_theme(
primary = "#1E4A8F",
secondary = "#FF6F61",
bootswatch = "minty",
base_font = bslib::font_google("Montserrat"),
code_font = bslib::font_google("Open Sans")
),
theme = light,
shiny::useBusyIndicators(),
bslib::page_navbar(
id = "main_panel",
ui_elements$import,