Filter hinzugefügt

This commit is contained in:
2026-03-19 17:06:40 +01:00
parent daba64c83a
commit 70a2fe2526
7 changed files with 140 additions and 19 deletions
+12 -2
View File
@@ -1,4 +1,5 @@
f_reactable <- function(daten, coldefs = NULL, selection = "single", defaultSelected = NULL, hoehe = NULL) {
f_reactable <- function(daten, coldefs = NULL, selection = "single",
defaultSelected = NULL, hoehe = NULL, highlight_valuta = NULL) {
reactable(
daten,
selection = selection,
@@ -18,7 +19,16 @@ f_reactable <- function(daten, coldefs = NULL, selection = "single", defaultSele
# borderColor = "#dfe2e5",
rowSelectedStyle = list(backgroundColor = "#98F5FF")#
),
rowStyle = list(cursor = "pointer"),
rowStyle = function(index) {
style <- list(cursor = "pointer") # immer aktiv
if (!is.null(highlight_valuta) &&
daten$valuta[index] == highlight_valuta) {
style$background <- "#fff3cd"
}
style
},
onClick = "select",
columns = coldefs
)