Nothing
# Generated by tools/generate_components.R. Do not edit by hand.
# nolint start: object_usage_linter.
#' Create a `wa-tag` component
#'
#' Generated wrapper for the Web Awesome `wa-tag` component.
#' Generated from Web Awesome metadata.
#'
#' @param ... Child content for the component's default slot.
#' @param id Optional DOM id attribute for HTML, CSS, and JS targeting.
#' @param class Optional CSS class string.
#' @param style Optional inline CSS style string.
#' @param appearance Enumerated string. Allowed values: `accent`,
#' `filled`, `filled-outlined`, `outlined`. Default: `filled-outlined`.
#' The tag's visual appearance.
#' @param dir String. Optional Web Awesome attribute.
#' @param lang String. Optional Web Awesome attribute.
#' @param pill Boolean. Default: `FALSE`. Draws a pill-style tag with
#' rounded edges.
#' @param size Enumerated string. Allowed values: `large`, `medium`,
#' `small`. Default: `medium`. The tag's size.
#' @param variant Enumerated string. Allowed values: `brand`, `danger`,
#' `neutral`, `success`, `warning`. Default: `neutral`. The tag's theme
#' variant. Defaults to `neutral` if not within another element with a
#' variant.
#' @param with_remove Boolean. Default: `FALSE`. Makes the tag removable
#' and shows a remove button.
#'
#' @section Shiny Bindings:
#' None.
#'
#' @return An HTML tag for the component.
#'
#' @export
wa_tag <- function(
...,
id = NULL,
class = NULL,
style = NULL,
appearance = NULL,
dir = NULL,
lang = NULL,
pill = NULL,
size = NULL,
variant = NULL,
with_remove = NULL
) {
children <- list(...)
if (!is.null(appearance)) {
appearance <- .wa_match_arg(
appearance,
"appearance",
c(
"accent",
"filled",
"filled-outlined",
"outlined"
)
)
}
if (!is.null(size)) {
size <- .wa_match_arg(
size,
"size",
c(
"large",
"medium",
"small"
)
)
}
if (!is.null(variant)) {
variant <- .wa_match_arg(
variant,
"variant",
c(
"brand",
"danger",
"neutral",
"success",
"warning"
)
)
}
attrs <- .wa_normalize_attrs(
list(
"id" = id,
"class" = class,
"style" = style,
"appearance" = appearance,
"dir" = dir,
"lang" = lang,
"pill" = pill,
"size" = size,
"variant" = variant,
"with-remove" = with_remove
),
boolean_names = c("pill", "with-remove"),
boolean_arg_names = c(
"pill" = "pill",
"with-remove" = "with_remove"
)
)
do.call(
.wa_component,
c(
list("wa-tag", .attrs = attrs),
children
)
)
}
# nolint end
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.