# NOT RUN {
if (interactive()) {
library(shiny)
library(shinyMobile)
shiny::shinyApp(
ui = f7Page(
title = "Tab Layout",
f7TabLayout(
navbar = f7Navbar(title = HTML(paste("Currently selected:", textOutput("selected")))),
f7Tabs(
id = "tabdemo",
swipeable = TRUE,
animated = FALSE,
f7Tab(tabName = "Tab 1", "tab 1 text"),
f7Tab(tabName = "Tab 2", "tab 2 text"),
f7Tab(tabName = "Tab 3", "tab 3 text"),
.items = shiny::tags$a(
class = "tab-link",
href = "#",
f7Icon("bolt_fill"),
shiny::span(class = "tabbar-label", "Optional Item")
)
)
)
),
server = function(input, output) {
output$selected <- renderText(input$tabdemo)
}
)
}
# }
Run the code above in your browser using DataLab