Let's start with the things to add to the ui.R. Once again, we add a place for the text to live to the graph tab:
tabPanel("Trend", plotOutput("trend"), h3("User selection history"), p(id = "selection", ""))
Then, we add a button to add the text and some controls to the sidebar:
actionButton("buttonClick", "Add inputs"), selectInput("color", "Text colour", c("Red" = "red", "Blue" = "blue", "Black" = "black")), selectInput("size", "Text size", c("Extremely small" = "xx-small", "Very small" = "x-small", "Small" = "small", "Medium" = "medium", "Large" = "large", "Extra large" = "x-large", "Super size" = "xx-large"))
The last addition is a reference to the JavaScript file that will make everything happen. We add this with the ...