Button A button indicates a possible user action UI Components ["web-component"] Spec
Categories

Button

A button indicates a possible user action

element Button <ui-button> {
// A button indicates a possible user action.
// export Button
types { // 5 { … }
emphasis : "primary" | "secondary" // be emphasized in a layout
"primary" — be emphasized as the first action that should be taken
"secondary" — be emphasized as a secondary option
link : boolean // be formatted as a page link
styled : "subtle" | "flat" | "outline" | "ghost" // be styled to fit into a layout
"subtle" — be styled to be de-emphasized
"flat" — be styled to appear flat
"outline" — be styled to appear outlined
"ghost" — only show styling when hovered
toggle : boolean // emphasize its active state
animated : "horizontal" | "vertical" | "fade" [compound] // animate to show hidden content
"horizontal" — animate hidden content horizontally
"vertical" — animate hidden content vertically
"fade" — fade in hidden content
}
content { // 3 { … }
icon : boolean [→ ui-icon] // include an icon
image : boolean // include an image
badge : boolean // display a notification badge
}
states { // 6 { … }
hover : boolean // be hovered
pressed : boolean // be pressed by a pointer
focus : boolean // be focused by the keyboard
active : boolean // be activated
disabled : "disabled" | "clickable" [compound] // have interactions disabled
"disabled" — disable interactions
"clickable" — allow interactions but appear disabled
loading : boolean // indicate it is loading content
}
variations { // 14 { … }
floated : "left" | "right" // align to the left or right of its container
"left" — appear to the left of content
"right" — appear to the right of content
fluid : boolean // take the width of its container
compact : "compact" | "very" [compound] // reduce its padding
"compact" — reduce its padding slightly
"very" — reduce its padding greatly
size : "mini" | "tiny" | "small" | "medium" | "large" | "big" | "huge" | "massive" // vary in size
"mini" — appear extremely small
"tiny" — appear very small
"small" — appear small
"medium" — appear normal sized
"large" — appear larger than normal
"big" — appear much larger than normal
"huge" — appear very much larger than normal
"massive" — appear extremely larger than normal
circular : boolean // be rounded like a circle
attached : "top" | "attached" | "bottom" | "left" | "right" // attach to other content
"top" — appear attached to the top of other content
"attached" — attach to content above and below
"bottom" — attach to the bottom
"left" — attach to the left
"right" — attach to the right
type : "submit" | "reset" // be a standard html button type
"submit" — submit the surrounding form
"reset" — reset the surrounding form
color : "red" | "orange" | "yellow" | "olive" | "green" | "teal" | "blue" | "violet" | "purple" | "pink" | "brown" | "grey" | "slate" // be colored
"red" — be red
"orange" — be orange
"yellow" — be yellow
"olive" — be olive
"green" — be green
"teal" — be teal
"blue" — be blue
"violet" — be violet
"purple" — be purple
"pink" — be pink
"brown" — be brown
"grey" — be grey
"slate" — be slate
social : "instagram" | "facebook" | "twitter" | "linkedin" | "youtube" // appear formatted with the brand colors of a social website
"instagram" — match the brand colors of Instagram
"facebook" — match the brand colors of Facebook
"twitter" — match the brand colors of Twitter
"linkedin" — match the brand colors of LinkedIn
"youtube" — match the brand colors of YouTube
positive : "positive" | "subtle" // indicate a positive action
"positive" — be positive
"subtle" — subtly hint at a positive action
warning : "warning" | "subtle" // indicate a potentially dangerous action
"warning" — be dangerous
"subtle" — subtly hint it may be dangerous
negative : "negative" | "subtle" // indicate a negative action
"negative" — be negative
"subtle" — subtly hint at a negative action
info : "info" | "subtle" // indicate it contains information
"info" — appear dangerous
"subtle" — subtly hint it may be dangerous
transparent : boolean // appear transparent
}
settings { // 3 { … }
icon-only : boolean = false // Enable to remove spacing for text
icon-after : boolean = false // Enable to position the icon after the text
href : string // link to a webpage
}
plural <ui-buttons> { { … }
shares : styled, icon, size, floated, compact, color, styled, attached
vertical : boolean // be arranged vertically
separate : boolean // have separated items
equal-width : "two" | "three" | "four" | "five" | "six" // have the same width for each button
conditional // show a conditional choice
}
}
import {
COLOR_OPTIONS,
ATTACHED_OPTIONS,
ATTACHED_VARIATION,
addOptionExamples,
getStates,
getVariations,
modifyVariation,
} from '@semantic-ui/specs';
export default {
uiType: 'element',
name: 'Button',
description: 'A button indicates a possible user action.',
tagName: 'ui-button',
exportName: 'Button',
examples: {
defaultPluralContent: `
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
<ui-button>Three</ui-button>
`,
},
content: [
{
name: 'Icon',
includeAttributeClass: true,
attribute: 'icon',
couplesWith: ['ui-icon'],
description: 'include an icon',
exampleCode: `<ui-button icon="pause">Pause</ui-button>`,
},
{
name: 'Image',
attribute: 'image',
description: 'include an image',
usageLevel: 2,
separateExamples: false,
exampleCode: [
`<ui-button>
<img src="/images/avatar/small/jenny.jpg" />
Add Jenny
</ui-button>`,
`<ui-button>
<ui-image src="/images/new-avatar/small/dima.jpg"></ui-image>
Add Dima
</ui-button>`,
],
},
{
name: 'Badge',
attribute: 'badge',
description: 'display a notification badge',
usageLevel: 3,
exampleCode: `<ui-button badge="5">Messages</ui-button>`,
},
],
types: [
{
name: 'Emphasis',
attribute: 'emphasis',
description: 'be emphasized in a layout',
usageLevel: 1,
includeAttributeClass: true,
separateExamples: true,
options: [
{
name: 'Primary',
value: 'primary',
description: 'be emphasized as the first action that should be taken',
exampleCode: `
<ui-button primary>Confirm</ui-button>
<ui-button>Cancel</ui-button>
`,
},
{
name: 'Secondary',
value: 'secondary',
description: 'be emphasized as a secondary option',
exampleCode: `
<ui-button secondary>Confirm</ui-button>
<ui-button>Cancel</ui-button>
`,
},
],
},
{
name: 'Link',
attribute: 'link',
description: 'be formatted as a page link',
usageLevel: 1,
},
{
name: 'Styled',
attribute: 'styled',
description: 'be styled to fit into a layout',
usageLevel: 1,
separateExamples: false,
includeAttributeClass: true,
options: [
{
name: 'Subtle',
value: 'subtle',
description: 'be styled to be de-emphasized',
},
{
name: 'Flat',
value: 'flat',
description: 'be styled to appear flat',
},
{
name: 'Outline',
value: 'outline',
description: 'be styled to appear outlined',
},
{
name: 'Ghost',
value: 'ghost',
description: 'only show styling when hovered',
},
],
},
{
name: 'Toggle',
attribute: 'toggle',
description: 'emphasize its active state',
usageLevel: 3,
exampleCode: `
<ui-button toggle>Inactive</ui-button>
<ui-button toggle active>Active</ui-button>
`,
},
{
name: 'Animated',
attribute: 'animated',
description: 'animate to show hidden content',
includeAttributeClass: true,
compoundAliases: true,
usageLevel: 3,
options: [
{
name: 'Horizontal',
value: 'horizontal',
description: 'animate hidden content horizontally',
exampleCode: `
<ui-button animated>
<span slot="visible">Hover Me</span>
<span slot="hidden">Hidden</span>
</ui-button>
`,
},
{
name: 'Vertical',
value: 'vertical',
description: 'animate hidden content vertically',
exampleCode: `
<ui-button vertical-animated>
<span slot="visible">Hover Me</span>
<span slot="hidden">Hidden</span>
</ui-button>
`,
},
{
name: 'Fade',
value: 'fade',
description: 'fade in hidden content',
exampleCode: `
<ui-button fade-animated>
<span slot="visible">Hover Me</span>
<span slot="hidden">Hidden</span>
</ui-button>
`,
},
],
},
],
states: getStates(['hover', 'pressed', 'focus', 'active', 'disabled', 'loading']),
variations: [
...getVariations(['floated', 'fluid', 'compact', 'size', 'circular']),
modifyVariation(ATTACHED_VARIATION, {
options: addOptionExamples(ATTACHED_OPTIONS, {
'top-attached': `
<ui-button top-attached>Top Action</ui-button>
<ui-segment bottom-attached>Attached content below</ui-segment>
`,
'attached': `
<ui-segment top-attached>Content above</ui-segment>
<ui-button attached>Middle Action</ui-button>
<ui-segment bottom-attached>Content below</ui-segment>
`,
'bottom-attached': `
<ui-segment top-attached>Attached content above</ui-segment>
<ui-button bottom-attached>Bottom Action</ui-button>
`,
'left-attached': `
<ui-segments horizontal>
<ui-button left-attached icon="user">View Profile</ui-button>
<ui-segment>Text to the right</ui-segment>
</ui-segments>
`,
'right-attached': `
<ui-segments horizontal>
<ui-segment>Text to the left</ui-segment>
<ui-button right-attached icon="user">View Profile</ui-button>
</ui-segments>
`,
}),
}),
{
name: 'Type',
attribute: 'type',
description: 'be a standard html button type',
usageLevel: 3,
options: [
{
name: 'Submit',
value: 'submit',
description: 'submit the surrounding form',
},
{
name: 'Reset',
value: 'reset',
description: 'reset the surrounding form',
},
],
},
{
name: 'Colored',
attribute: 'color',
includeAttributeClass: true,
description: 'be colored',
usageLevel: 3,
separateExamples: true,
singularExampleCode: [
COLOR_OPTIONS.map(c => `<ui-button ${c.value}>${c.name}</ui-button>`).join('\n'),
COLOR_OPTIONS.map(c => `<ui-button subtle ${c.value}>${c.name}</ui-button>`).join('\n'),
COLOR_OPTIONS.map(c => `<ui-button flat ${c.value}>${c.name}</ui-button>`).join('\n'),
COLOR_OPTIONS.map(c => `<ui-button outline ${c.value}>${c.name}</ui-button>`).join('\n'),
COLOR_OPTIONS.map(c => `<ui-button ghost ${c.value}>${c.name}</ui-button>`).join('\n'),
],
options: COLOR_OPTIONS,
},
{
name: 'Social Site',
attribute: 'social',
value: 'social',
usageLevel: 5,
description: 'appear formatted with the brand colors of a social website',
includeAttributeClass: true,
options: [
{
name: 'Instagram',
value: 'instagram',
description: 'match the brand colors of Instagram',
exampleCode: `<ui-button instagram icon="instagram">Instagram</ui-button>`,
},
{
name: 'Facebook',
value: 'facebook',
description: 'match the brand colors of Facebook',
exampleCode: `<ui-button facebook icon="facebook">Facebook</ui-button>`,
},
{
name: 'Twitter',
value: 'twitter',
description: 'match the brand colors of Twitter',
exampleCode: `<ui-button twitter icon="twitter">Twitter</ui-button>`,
},
{
name: 'Linkedin',
value: 'linkedin',
description: 'match the brand colors of LinkedIn',
exampleCode: `<ui-button linkedin icon="linkedin">LinkedIn</ui-button>`,
},
{
name: 'Youtube',
value: 'youtube',
description: 'match the brand colors of YouTube',
exampleCode: `<ui-button youtube icon="youtube">YouTube</ui-button>`,
},
],
},
{
name: 'Positive',
attribute: 'positive',
usageLevel: 2,
description: 'indicate a positive action',
options: [
{
name: 'Positive',
value: 'positive',
description: 'be positive',
},
{
name: 'Subtle Positive',
value: 'subtle',
description: 'subtly hint at a positive action',
},
],
},
{
name: 'Warning',
attribute: 'warning',
usageLevel: 2,
description: 'indicate a potentially dangerous action',
options: [
{
name: 'Warning',
value: 'warning',
description: 'be dangerous',
},
{
name: 'Subtle Warning',
value: 'subtle',
description: 'subtly hint it may be dangerous',
},
],
},
{
name: 'Negative',
attribute: 'negative',
usageLevel: 2,
description: 'indicate a negative action',
options: [
{
name: 'Negative',
value: 'negative',
description: 'be negative',
},
{
name: 'Subtle Negative',
value: 'subtle',
description: 'subtly hint at a negative action',
},
],
},
{
name: 'Info',
attribute: 'info',
usageLevel: 2,
description: 'indicate it contains information',
options: [
{
name: 'Info',
value: 'info',
description: 'appear dangerous',
},
{
name: 'Subtle Info',
value: 'subtle',
description: 'subtly hint it may be dangerous',
},
],
},
{
name: 'Transparent',
attribute: 'transparent',
usageLevel: 2,
description: 'appear transparent',
exampleCode: `
<div class="transparent segments">
<div class="standard segment">
<ui-button transparent>Transparent</ui-button>
</div>
</div>
`,
},
],
settings: [
{
name: 'Icon Only',
type: 'boolean',
attribute: 'icon-only',
defaultValue: false,
description: 'Enable to remove spacing for text',
exampleCode: `<ui-button icon="pause" icon-only></ui-button>`,
},
{
name: 'Icon After',
type: 'boolean',
attribute: 'icon-after',
defaultValue: false,
description: 'Enable to position the icon after the text',
},
{
name: 'Href',
type: 'string',
attribute: 'href',
description: 'link to a webpage',
},
],
// Plural (group) support
supportsPlural: true,
pluralName: 'Buttons',
pluralTagName: 'ui-buttons',
pluralExportName: 'Buttons',
pluralDescription: 'Buttons can exist together as a group',
pluralContent: [
{
name: 'Conditional',
description: 'show a conditional choice',
exampleCode: `
<ui-buttons>
<ui-button>Cancel</ui-button>
<span class="conditional">or</span>
<ui-button primary>Save</ui-button>
</ui-buttons>
`,
},
],
pluralSharedTypes: ['styled', 'icon'],
pluralOnlyTypes: [
{
name: 'Vertical',
attribute: 'vertical',
description: 'be arranged vertically',
usageLevel: 3,
},
],
pluralOnlyVariations: [
{
name: 'Separate',
attribute: 'separate',
description: 'have separated items',
},
{
name: 'Equal Width',
attribute: 'equal-width',
description: 'have the same width for each button',
includeAttributeClass: true,
usageLevel: 3,
options: [
{
name: 'Two',
value: 'two',
description: 'have two items evenly split',
exampleCode: `
<ui-buttons equal-width="two">
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
</ui-buttons>
`,
},
{
name: 'Three',
value: 'three',
description: 'have three items evenly split',
exampleCode: `
<ui-buttons equal-width="three">
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
<ui-button>Three</ui-button>
</ui-buttons>
`,
},
{
name: 'Four',
value: 'four',
description: 'have four items evenly split',
exampleCode: `
<ui-buttons equal-width="four">
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
<ui-button>Three</ui-button>
<ui-button>Four</ui-button>
</ui-buttons>
`,
},
{
name: 'Five',
value: 'five',
description: 'have five items evenly split',
exampleCode: `
<ui-buttons equal-width="five">
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
<ui-button>Three</ui-button>
<ui-button>Four</ui-button>
<ui-button>Five</ui-button>
</ui-buttons>
`,
},
{
name: 'Six',
value: 'six',
description: 'have six items evenly split',
exampleCode: `
<ui-buttons equal-width="six">
<ui-button>One</ui-button>
<ui-button>Two</ui-button>
<ui-button>Three</ui-button>
<ui-button>Four</ui-button>
<ui-button>Five</ui-button>
<ui-button>Six</ui-button>
</ui-buttons>
`,
},
],
},
],
pluralSharedVariations: [
'size',
'floated',
'compact',
'color',
'styled',
'attached',
],
};
{ "uiType": "element", "name": "Button", "description": "A button indicates a possible user action.", "tagName": "ui-button", "exportName": "Button", "examples": { "defaultPluralContent": "\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n <ui-button>Three</ui-button>\n " }, "content": [ { "name": "Icon", "includeAttributeClass": true, "attribute": "icon", "couplesWith": [ "ui-icon" ], "description": "include an icon", "exampleCode": "<ui-button icon=\"pause\">Pause</ui-button>" }, { "name": "Image", "attribute": "image", "description": "include an image", "usageLevel": 2, "separateExamples": false, "exampleCode": [ "<ui-button>\n <img src=\"/images/avatar/small/jenny.jpg\" />\n Add Jenny\n </ui-button>", "<ui-button>\n <ui-image src=\"/images/new-avatar/small/dima.jpg\"></ui-image>\n Add Dima\n </ui-button>" ] }, { "name": "Badge", "attribute": "badge", "description": "display a notification badge", "usageLevel": 3, "exampleCode": "<ui-button badge=\"5\">Messages</ui-button>" } ], "types": [ { "name": "Emphasis", "attribute": "emphasis", "description": "be emphasized in a layout", "usageLevel": 1, "includeAttributeClass": true, "separateExamples": true, "options": [ { "name": "Primary", "value": "primary", "description": "be emphasized as the first action that should be taken", "exampleCode": "\n <ui-button primary>Confirm</ui-button>\n <ui-button>Cancel</ui-button>\n " }, { "name": "Secondary", "value": "secondary", "description": "be emphasized as a secondary option", "exampleCode": "\n <ui-button secondary>Confirm</ui-button>\n <ui-button>Cancel</ui-button>\n " } ] }, { "name": "Link", "attribute": "link", "description": "be formatted as a page link", "usageLevel": 1 }, { "name": "Styled", "attribute": "styled", "description": "be styled to fit into a layout", "usageLevel": 1, "separateExamples": false, "includeAttributeClass": true, "options": [ { "name": "Subtle", "value": "subtle", "description": "be styled to be de-emphasized" }, { "name": "Flat", "value": "flat", "description": "be styled to appear flat" }, { "name": "Outline", "value": "outline", "description": "be styled to appear outlined" }, { "name": "Ghost", "value": "ghost", "description": "only show styling when hovered" } ] }, { "name": "Toggle", "attribute": "toggle", "description": "emphasize its active state", "usageLevel": 3, "exampleCode": "\n <ui-button toggle>Inactive</ui-button>\n <ui-button toggle active>Active</ui-button>\n " }, { "name": "Animated", "attribute": "animated", "description": "animate to show hidden content", "includeAttributeClass": true, "compoundAliases": true, "usageLevel": 3, "options": [ { "name": "Horizontal", "value": "horizontal", "description": "animate hidden content horizontally", "exampleCode": "\n <ui-button animated>\n <span slot=\"visible\">Hover Me</span>\n <span slot=\"hidden\">Hidden</span>\n </ui-button>\n " }, { "name": "Vertical", "value": "vertical", "description": "animate hidden content vertically", "exampleCode": "\n <ui-button vertical-animated>\n <span slot=\"visible\">Hover Me</span>\n <span slot=\"hidden\">Hidden</span>\n </ui-button>\n " }, { "name": "Fade", "value": "fade", "description": "fade in hidden content", "exampleCode": "\n <ui-button fade-animated>\n <span slot=\"visible\">Hover Me</span>\n <span slot=\"hidden\">Hidden</span>\n </ui-button>\n " } ] } ], "states": [ { "name": "Hover", "attribute": "hover", "description": "be hovered" }, { "name": "Pressed", "attribute": "pressed", "description": "be pressed by a pointer" }, { "name": "Focus", "attribute": "focus", "description": "be focused by the keyboard" }, { "name": "Active", "attribute": "active", "description": "be activated" }, { "name": "Disabled", "attribute": "disabled", "includeAttributeClass": true, "compoundAliases": true, "description": "have interactions disabled", "options": [ { "name": "Disabled", "value": "disabled", "description": "disable interactions" }, { "name": "Clickable Disabled", "value": "clickable", "description": "allow interactions but appear disabled" } ] }, { "name": "Loading", "attribute": "loading", "description": "indicate it is loading content" } ], "variations": [ { "name": "Floated", "attribute": "floated", "usageLevel": 1, "description": "align to the left or right of its container", "options": [ { "name": "Left Floated", "value": "left", "description": "appear to the left of content" }, { "name": "Right Floated", "value": "right", "description": "appear to the right of content" } ] }, { "name": "Fluid", "attribute": "fluid", "usageLevel": 1, "description": "take the width of its container" }, { "name": "Compact", "attribute": "compact", "usageLevel": 3, "description": "reduce its padding", "compoundAliases": true, "options": [ { "name": "Compact", "value": "compact", "description": "reduce its padding slightly" }, { "name": "Very Compact", "value": "very", "description": "reduce its padding greatly" } ] }, { "name": "Size", "attribute": "size", "usageLevel": 1, "description": "vary in size", "options": [ { "name": "Mini", "value": "mini", "description": "appear extremely small" }, { "name": "Tiny", "value": "tiny", "description": "appear very small" }, { "name": "Small", "value": "small", "description": "appear small" }, { "name": "Medium", "value": "medium", "description": "appear normal sized" }, { "name": "Large", "value": "large", "description": "appear larger than normal" }, { "name": "Big", "value": "big", "description": "appear much larger than normal" }, { "name": "Huge", "value": "huge", "description": "appear very much larger than normal" }, { "name": "Massive", "value": "massive", "description": "appear extremely larger than normal" } ] }, { "name": "Circular", "attribute": "circular", "usageLevel": 3, "description": "be rounded like a circle" }, { "name": "Attached", "attribute": "attached", "includeAttributeClass": true, "separateExamples": true, "usageLevel": 2, "description": "attach to other content", "options": [ { "name": "Top Attached", "value": "top", "description": "appear attached to the top of other content" }, { "name": "Attached", "value": "attached", "description": "attach to content above and below", "exampleCode": "\n <ui-segment top-attached>Content above</ui-segment>\n <ui-button attached>Middle Action</ui-button>\n <ui-segment bottom-attached>Content below</ui-segment>\n " }, { "name": "Bottom Attached", "value": "bottom", "description": "attach to the bottom" }, { "name": "Left Attached", "value": "left", "description": "attach to the left" }, { "name": "Right Attached", "value": "right", "description": "attach to the right" } ] }, { "name": "Type", "attribute": "type", "description": "be a standard html button type", "usageLevel": 3, "options": [ { "name": "Submit", "value": "submit", "description": "submit the surrounding form" }, { "name": "Reset", "value": "reset", "description": "reset the surrounding form" } ] }, { "name": "Colored", "attribute": "color", "includeAttributeClass": true, "description": "be colored", "usageLevel": 3, "separateExamples": true, "singularExampleCode": [ "<ui-button red>Red</ui-button>\n<ui-button orange>Orange</ui-button>\n<ui-button yellow>Yellow</ui-button>\n<ui-button olive>Olive</ui-button>\n<ui-button green>Green</ui-button>\n<ui-button teal>Teal</ui-button>\n<ui-button blue>Blue</ui-button>\n<ui-button violet>Violet</ui-button>\n<ui-button purple>Purple</ui-button>\n<ui-button pink>Pink</ui-button>\n<ui-button brown>Brown</ui-button>\n<ui-button grey>Grey</ui-button>\n<ui-button slate>Slate</ui-button>", "<ui-button subtle red>Red</ui-button>\n<ui-button subtle orange>Orange</ui-button>\n<ui-button subtle yellow>Yellow</ui-button>\n<ui-button subtle olive>Olive</ui-button>\n<ui-button subtle green>Green</ui-button>\n<ui-button subtle teal>Teal</ui-button>\n<ui-button subtle blue>Blue</ui-button>\n<ui-button subtle violet>Violet</ui-button>\n<ui-button subtle purple>Purple</ui-button>\n<ui-button subtle pink>Pink</ui-button>\n<ui-button subtle brown>Brown</ui-button>\n<ui-button subtle grey>Grey</ui-button>\n<ui-button subtle slate>Slate</ui-button>", "<ui-button flat red>Red</ui-button>\n<ui-button flat orange>Orange</ui-button>\n<ui-button flat yellow>Yellow</ui-button>\n<ui-button flat olive>Olive</ui-button>\n<ui-button flat green>Green</ui-button>\n<ui-button flat teal>Teal</ui-button>\n<ui-button flat blue>Blue</ui-button>\n<ui-button flat violet>Violet</ui-button>\n<ui-button flat purple>Purple</ui-button>\n<ui-button flat pink>Pink</ui-button>\n<ui-button flat brown>Brown</ui-button>\n<ui-button flat grey>Grey</ui-button>\n<ui-button flat slate>Slate</ui-button>", "<ui-button outline red>Red</ui-button>\n<ui-button outline orange>Orange</ui-button>\n<ui-button outline yellow>Yellow</ui-button>\n<ui-button outline olive>Olive</ui-button>\n<ui-button outline green>Green</ui-button>\n<ui-button outline teal>Teal</ui-button>\n<ui-button outline blue>Blue</ui-button>\n<ui-button outline violet>Violet</ui-button>\n<ui-button outline purple>Purple</ui-button>\n<ui-button outline pink>Pink</ui-button>\n<ui-button outline brown>Brown</ui-button>\n<ui-button outline grey>Grey</ui-button>\n<ui-button outline slate>Slate</ui-button>", "<ui-button ghost red>Red</ui-button>\n<ui-button ghost orange>Orange</ui-button>\n<ui-button ghost yellow>Yellow</ui-button>\n<ui-button ghost olive>Olive</ui-button>\n<ui-button ghost green>Green</ui-button>\n<ui-button ghost teal>Teal</ui-button>\n<ui-button ghost blue>Blue</ui-button>\n<ui-button ghost violet>Violet</ui-button>\n<ui-button ghost purple>Purple</ui-button>\n<ui-button ghost pink>Pink</ui-button>\n<ui-button ghost brown>Brown</ui-button>\n<ui-button ghost grey>Grey</ui-button>\n<ui-button ghost slate>Slate</ui-button>" ], "options": [ { "name": "Red", "value": "red", "description": "be red" }, { "name": "Orange", "value": "orange", "description": "be orange" }, { "name": "Yellow", "value": "yellow", "description": "be yellow" }, { "name": "Olive", "value": "olive", "description": "be olive" }, { "name": "Green", "value": "green", "description": "be green" }, { "name": "Teal", "value": "teal", "description": "be teal" }, { "name": "Blue", "value": "blue", "description": "be blue" }, { "name": "Violet", "value": "violet", "description": "be violet" }, { "name": "Purple", "value": "purple", "description": "be purple" }, { "name": "Pink", "value": "pink", "description": "be pink" }, { "name": "Brown", "value": "brown", "description": "be brown" }, { "name": "Grey", "value": "grey", "description": "be grey" }, { "name": "Slate", "value": "slate", "description": "be slate" } ] }, { "name": "Social Site", "attribute": "social", "value": "social", "usageLevel": 5, "description": "appear formatted with the brand colors of a social website", "includeAttributeClass": true, "options": [ { "name": "Instagram", "value": "instagram", "description": "match the brand colors of Instagram", "exampleCode": "<ui-button instagram icon=\"instagram\">Instagram</ui-button>" }, { "name": "Facebook", "value": "facebook", "description": "match the brand colors of Facebook", "exampleCode": "<ui-button facebook icon=\"facebook\">Facebook</ui-button>" }, { "name": "Twitter", "value": "twitter", "description": "match the brand colors of Twitter", "exampleCode": "<ui-button twitter icon=\"twitter\">Twitter</ui-button>" }, { "name": "Linkedin", "value": "linkedin", "description": "match the brand colors of LinkedIn", "exampleCode": "<ui-button linkedin icon=\"linkedin\">LinkedIn</ui-button>" }, { "name": "Youtube", "value": "youtube", "description": "match the brand colors of YouTube", "exampleCode": "<ui-button youtube icon=\"youtube\">YouTube</ui-button>" } ] }, { "name": "Positive", "attribute": "positive", "usageLevel": 2, "description": "indicate a positive action", "options": [ { "name": "Positive", "value": "positive", "description": "be positive" }, { "name": "Subtle Positive", "value": "subtle", "description": "subtly hint at a positive action" } ] }, { "name": "Warning", "attribute": "warning", "usageLevel": 2, "description": "indicate a potentially dangerous action", "options": [ { "name": "Warning", "value": "warning", "description": "be dangerous" }, { "name": "Subtle Warning", "value": "subtle", "description": "subtly hint it may be dangerous" } ] }, { "name": "Negative", "attribute": "negative", "usageLevel": 2, "description": "indicate a negative action", "options": [ { "name": "Negative", "value": "negative", "description": "be negative" }, { "name": "Subtle Negative", "value": "subtle", "description": "subtly hint at a negative action" } ] }, { "name": "Info", "attribute": "info", "usageLevel": 2, "description": "indicate it contains information", "options": [ { "name": "Info", "value": "info", "description": "appear dangerous" }, { "name": "Subtle Info", "value": "subtle", "description": "subtly hint it may be dangerous" } ] }, { "name": "Transparent", "attribute": "transparent", "usageLevel": 2, "description": "appear transparent", "exampleCode": "\n <div class=\"transparent segments\">\n <div class=\"standard segment\">\n <ui-button transparent>Transparent</ui-button>\n </div>\n </div>\n " } ], "settings": [ { "name": "Icon Only", "type": "boolean", "attribute": "icon-only", "defaultValue": false, "description": "Enable to remove spacing for text", "exampleCode": "<ui-button icon=\"pause\" icon-only></ui-button>" }, { "name": "Icon After", "type": "boolean", "attribute": "icon-after", "defaultValue": false, "description": "Enable to position the icon after the text" }, { "name": "Href", "type": "string", "attribute": "href", "description": "link to a webpage" } ], "supportsPlural": true, "pluralName": "Buttons", "pluralTagName": "ui-buttons", "pluralExportName": "Buttons", "pluralDescription": "Buttons can exist together as a group", "pluralContent": [ { "name": "Conditional", "description": "show a conditional choice", "exampleCode": "\n <ui-buttons>\n <ui-button>Cancel</ui-button>\n <span class=\"conditional\">or</span>\n <ui-button primary>Save</ui-button>\n </ui-buttons>\n " } ], "pluralSharedTypes": [ "styled", "icon" ], "pluralOnlyTypes": [ { "name": "Vertical", "attribute": "vertical", "description": "be arranged vertically", "usageLevel": 3 } ], "pluralOnlyVariations": [ { "name": "Separate", "attribute": "separate", "description": "have separated items" }, { "name": "Equal Width", "attribute": "equal-width", "description": "have the same width for each button", "includeAttributeClass": true, "usageLevel": 3, "options": [ { "name": "Two", "value": "two", "description": "have two items evenly split", "exampleCode": "\n <ui-buttons equal-width=\"two\">\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n </ui-buttons>\n " }, { "name": "Three", "value": "three", "description": "have three items evenly split", "exampleCode": "\n <ui-buttons equal-width=\"three\">\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n <ui-button>Three</ui-button>\n </ui-buttons>\n " }, { "name": "Four", "value": "four", "description": "have four items evenly split", "exampleCode": "\n <ui-buttons equal-width=\"four\">\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n <ui-button>Three</ui-button>\n <ui-button>Four</ui-button>\n </ui-buttons>\n " }, { "name": "Five", "value": "five", "description": "have five items evenly split", "exampleCode": "\n <ui-buttons equal-width=\"five\">\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n <ui-button>Three</ui-button>\n <ui-button>Four</ui-button>\n <ui-button>Five</ui-button>\n </ui-buttons>\n " }, { "name": "Six", "value": "six", "description": "have six items evenly split", "exampleCode": "\n <ui-buttons equal-width=\"six\">\n <ui-button>One</ui-button>\n <ui-button>Two</ui-button>\n <ui-button>Three</ui-button>\n <ui-button>Four</ui-button>\n <ui-button>Five</ui-button>\n <ui-button>Six</ui-button>\n </ui-buttons>\n " } ] } ], "pluralSharedVariations": [ "size", "floated", "compact", "color", "styled", "attached" ] }