-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathui.R
134 lines (133 loc) · 5.06 KB
/
ui.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
## --------------------------------------------------------------------------
## ui.R --
## --------------------------------------------------------------------------
shiny::tagList(
# Adds the NEB logo to the navbar
tags$head(tags$script(type = "text/javascript", src = "code.js")),
tags$style(type = "text/css", "body {padding-top: 60px;}"),
##-------------------------------------------------------
## NAVBAR PAGE --
##-------------------------------------------------------
bslib::page_navbar(
title = "Uncle Dashboard",
id = "dashboard_navbar",
selected = "tab_database",
position = "fixed-top",
##----------------------------------------
## Dark mode controls --
##----------------------------------------
# Theme default on app load
theme = theme_light,
bg = "#073642",
header = shiny::tagList(
# shiny::div(style = "display: inline-block", shiny::icon("adjust")),
# shiny::div(style = "display: inline-block", " "),
shiny::div(
style = "display: inline-block",
shinyWidgets::prettySwitch(
inputId = "dark_mode",
label = "Dark mode.",
value = FALSE # set to match the default theme on app load
)
)
),
##--------------------------------------------------------
## NAVBAR TAB: DATABASE --
##--------------------------------------------------------
shiny::tabPanel(
"Database Connection",
icon = shiny::icon("database"),
value = "tab_database",
shiny::sidebarLayout(
##----------------------------------------
## Side panel --
##----------------------------------------
shiny::sidebarPanel(
width = 2,
dbQueryUI("db_query")
),
##----------------------------------------
## Main panel --
##----------------------------------------
shiny::mainPanel(
width = 10,
dbViewUI("db_view")
)
)
),
##-------------------------------------------------------
## NAVBAR TAB: SUMMARY SCATTER PLOTS --
##-------------------------------------------------------
shiny::tabPanel(
"Summary Data Visualization",
icon = shiny::icon("braille"),
value = "tab_scatter",
shiny::sidebarLayout(
##----------------------------------------
## Side panel --
##----------------------------------------
shiny::sidebarPanel(
width = 2,
shiny::tabsetPanel(
# id = "sidebarPanel_scatter",
type = "tabs",
selected = "tab_opts_scatter",
shiny::tabPanel(
title = "Filters",
icon = shiny::icon("filter"),
value = "tab_data_filters",
dataFiltersUI("filters")
),
shiny::tabPanel(
title = "Options",
icon = shiny::icon("palette"),
value = "tab_opts_scatter",
plotOptsUI("opts_scatter")
)
)
),
##----------------------------------------
## Main panel --
##----------------------------------------
shiny::mainPanel(
width = 10,
scatterPlotsUI("scatter")
)
)
),
##-------------------------------------------------------
## NAVBAR TAB: PLATE LAYOUT SAMPLE INSPECTOR --
##-------------------------------------------------------
shiny::tabPanel(
"Plate Inspector",
icon = shiny::icon("search"),
value = "tab_inspector",
plateInspectorUI("inspector")
),
##--------------------------------------------------------
## NAVBAR DROPDOWN: TOOLS --
##--------------------------------------------------------
shiny::navbarMenu(
"Tools",
icon = shiny::icon("tools"),
shiny::tabPanel(
"Database Troubleshooting",
icon = shiny::icon("database"),
value = "tab_diag",
dbDiagUI("db_diag")
)
),
##-------------------------------------------------------
## NAVBAR TAB: ABOUT THE APP --
##-------------------------------------------------------
shiny::tabPanel(
"About this App",
icon = shiny::icon("info-circle"),
value = "tab_about",
aboutUI("about")
)
)
)
##--------------------------------------------------------------------------
## end ui.R --
##--------------------------------------------------------------------------