weathericon.Rd
Create a weathericon for use within a page. Icons can appear on their own, inside of a button, or as an icon for a tabPanel() within a navbarPage().
weathericon( name = NULL, wind = TRUE, flip = NULL, rotate = NULL, towards = NULL, from = NULL, className = NULL, ... )
name | Name of the icon |
---|---|
wind | Should the Wind-Stylesheet be included as dependency.
The default is |
flip | Flip the icon. Either |
rotate | Rotate the icon. Valid values are |
towards | The `towards`-direction for wind icons can be specified either by degrees or by an orientation. See the details. |
from | The `from`-direction for wind icons can be specified either by degrees or by an orientation. See the details. |
className | Define an additional classname for the icon tag. |
... | Additional arguments that are passed to the attributes of the i-tag. Style arguments must be passed as a named list. |
A weather-icon element
The arguments towards
and from
can either be an integer value
between 0-360 or a character giving the direction. The possible items are
stored in the dataset quadrants
.
# NOT RUN { ## To see a full List of icons please run this shiny-app shiny::runApp(system.file("examples/app.R", package = "weathericons"), display.mode="showcase") ## To see how to use classes with icons see the following shiny-app shiny::runApp(system.file("examples/app_classes.R", package = "weathericons"), display.mode="showcase") ## To see how to use JS functions and inline styling, please run this shiny-app shiny::runApp(system.file("examples/js_functions.R", package = "weathericons"), display.mode="showcase") ## To see how to use weathericons for leaflet popups and labels, see shiny::runApp(system.file("examples/leaflet_popup.R", package = "weathericons"), display.mode="showcase") weathericon("wi-forecast-io-fog") weathericon("wi-wu-chanceflurries") weathericon("wi-moon-waxing-crescent-3") weathericon("wi-forecast-io-rain") ## Rotating Icons weathericon("wi wi-yahoo-7", rotate = "90") weathericon("wi wi-yahoo-7", rotate = "180") weathericon("wi wi-yahoo-7", rotate = "270") ## Flipping Icons weathericon("wi wi-yahoo-7", flip = "vertical") ## Wind Icons with Directions weathericon("wi wi-wind", towards = "sse") weathericon("wi-wind", from = "sw") weathericon("wi wi-wind", towards = 40) weathericon("wi wi-wind", from = 40) # }