CopyButton
IzzyBlazor.CopyButton in the IzzyBlazor.Core package, generated from the 0.1.0-alpha.17 assembly
and its doc comments.
Properties (15)
Textstring?The text to copy.
Forstring?The id of the element to copy from, in place of Text: an input's or text area's value, or any other element's text.
Labelstring? = "Copy"The button's name for screen readers and its tooltip. Defaults to "Copy". A button with content is named by its content and uses this only as the tooltip.
CopiedLabelstring? = "Copied"Announced after copying. Defaults to "Copied".
AccentAccent = Accent.NeutralPrimary (the default) for the main action, Neutral for everything else, Danger for destructive actions, or a custom color (Accent.Of("#0d9488"), Accent.Token("brand")); text on a custom color is chosen for contrast. Emphasis comes from Variant.
VariantButtonVariant = ButtonVariant.GhostVisual weight. Defaults to ButtonVariant.Solid.
SizeControlSize = ControlSize.MdHeight. Defaults to ControlSize.Md.
StartIconIconData?An icon before the text.
EndIconIconData?An icon after the text.
FullWidthbool = falseStretches to the full width of its container.
Loadingbool = falseShows a spinner in place of the start icon and blocks further clicks.
LoadingLabelstring? = "Loading"Read to screen readers while Loading. Defaults to "Loading".
Disabledbool = falseDisables the button.
@bind-Pressedbool?Makes it a toggle button, such as Bold in an editor: true shows it pressed, false not, and screen readers hear which (aria-pressed). With @bind-Pressed a click turns it on and off on interactive pages; on static pages the server decides, as with a submit button's Name and Value. Null (the default) is an ordinary button. Not for links.
ChildContentRenderFragment?The label.
Plus 16 item props and 4 common props.
Show them hereEvents (0)
No events.
Types (3)
Accent
classThe color of a control: buttons, badges, tags, banners, progress bars and menu items. Primary, Neutral and Danger are the roles; emphasis comes from the variant (solid, soft, outline, ghost, link), not from more colors. For one control in another color, use Of (any CSS color) or Token (a theme token); text on it is chosen for contrast.
| Member | Description |
|---|---|
Primary | The brand color, for the main action. |
Neutral | A quiet, gray action. |
Danger | A destructive action, such as Delete. |
Of(string css) | Any CSS color, such as |
Token(string name) | A theme token, such as |
From(Color color) | A |
ButtonVariant
enumA button's visual weight, from strongest to quietest.
| Value | Description |
|---|---|
Solid | Filled with the accent color. For the main action. |
Soft | A light tint of the accent color. |
Outline | An accent-colored border on a transparent background. |
Ghost | Transparent until hovered. For toolbars and dense layouts. |
Link | Looks like a link. |
ControlSize
enumThe height of interactive controls. Shared by buttons and form fields, so a button and an input of the same size line up in a row.
| Value | Description |
|---|---|
Sm | 32px tall, small text. |
Md | 36px tall (the default). |
Lg | 44px tall, large text. For touch-first and marketing pages. |