Icon An icon is a glyph used to represent something else UI Components ["web-component"] Spec
Categories

Icon

An icon is a glyph used to represent something else

element Icon <ui-icon> {
// An icon is a glyph used to represent something else
// export Icon
content { // 1 { … }
icon : "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" | "" // specify what icon should appear
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
}
states { // 2 { … }
disabled : "disabled" | "clickable" [compound] // have interactions disabled
"disabled" — disable interactions
"clickable" — allow interactions but appear disabled
loading : boolean // indicate it is loading content
}
variations { // 6 { … }
: boolean // be formatted as a link
: boolean // be fitted without any space to the left or right of it.
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
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
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
spin : boolean // be formatted to spin like a loader
}
settings { // 3 { … }
set : string // The icon set to use
href : string // Link to a page
target : string // The target for a link
}
plural <ui-icons> { { … }
}
}
import {
ICON_NAMES,
SIZE_VARIATION,
COLORED_VARIATION,
COLOR_OPTIONS,
modifyVariation,
withUsageLevel,
getStates,
} from '@semantic-ui/specs';
export default {
uiType: 'element',
name: 'Icon',
description: 'An icon is a glyph used to represent something else',
tagName: 'ui-icon',
exportName: 'Icon',
content: [
{
name: 'Icon',
attribute: 'icon',
description: 'specify what icon should appear',
usageLevel: 1,
options: ICON_NAMES,
},
],
states: getStates(['disabled', 'loading']).map(state => withUsageLevel(state, 1)),
variations: [
{
name: 'Link',
description: 'be formatted as a link',
usageLevel: 1,
},
{
name: 'Fitted',
description: 'be fitted without any space to the left or right of it.',
usageLevel: 1,
},
COLORED_VARIATION,
SIZE_VARIATION,
modifyVariation(SIZE_VARIATION, {
includeAttributeClass: true
}),
{
name: 'Spin',
description: 'be formatted to spin like a loader',
usageLevel: 3,
attribute: 'spin',
},
],
settings: [
{
name: 'set',
type: 'string',
attribute: 'set',
description: 'The icon set to use',
},
{
name: 'href',
type: 'string',
attribute: 'href',
description: 'Link to a page',
},
{
name: 'target',
type: 'string',
attribute: 'target',
description: 'The target for a link',
},
],
supportsPlural: true,
pluralName: 'Icons',
pluralTagName: 'ui-icons',
pluralDescription: 'Icons exist together as a group',
pluralVariations: [
'colored',
'size',
],
examples: {
defaultAttributes: {
icon: 'check',
},
},
};
{ "uiType": "element", "name": "Icon", "description": "An icon is a glyph used to represent something else", "tagName": "ui-icon", "exportName": "Icon", "content": [ { "name": "Icon", "attribute": "icon", "description": "specify what icon should appear", "usageLevel": 1, "options": [ "arrow-down", "arrow-left", "arrow-left-right", "arrow-right", "arrow-up", "arrow-up-down", "chevron-down", "chevron-first", "chevron-last", "chevron-left", "chevron-right", "chevron-up", "chevrons-down-up", "chevrons-left-right", "chevrons-up-down", "compass", "corner-down-left", "corner-down-right", "crosshair", "external-link", "home", "layout-panel-left", "layout-panel-top", "menu", "mouse-pointer", "archive", "archive-restore", "archive-x", "arrow-down-a-z", "arrow-up-a-z", "bookmark", "bookmark-check", "bookmark-plus", "circle-ellipsis", "circle-minus", "circle-plus", "circle-x", "clipboard", "clipboard-paste", "cloud-download", "cloud-upload", "copy", "copy-check", "backspace", "download", "ellipsis", "ellipsis-vertical", "expand", "eye", "eye-off", "grip-horizontal", "grip-vertical", "hand", "heart", "heart-off", "link", "list-checks", "maximize", "merge", "minimize", "minus", "mouse-pointer-click", "move", "paperclip", "pencil", "pin", "pin-off", "plus", "redo", "refresh", "replace", "rocket", "rotate-ccw", "rotate-cw", "save", "scan", "scissors", "search", "share", "split", "thumbs-down", "thumbs-up", "trash", "undo", "unlink", "upload", "vote", "x", "zoom-in", "zoom-out", "badge-alert", "badge-check", "badge-info", "ban", "check", "check-check", "error", "circle-check", "circle-dashed", "help", "construction", "flag", "flame", "frown", "info", "life-buoy", "loader", "loader-circle", "meh", "server-crash", "warning", "bolt", "avatar", "contact", "id-card", "user", "user-check", "user-cog", "user-minus", "user-plus", "user-search", "user-x", "users", "circle-dot", "password", "square-check", "text-cursor-input", "toggle-left", "toggle-right", "activity", "chart-area", "chart-bar", "chart-bar-stacked", "chart-candlestick", "chart-gantt", "chart-line", "chart-network", "chart-pie", "chart-scatter", "clipboard-list", "funnel", "gauge", "grid-2x2", "grid-3x3", "layout-dashboard", "layout-grid", "layout-list", "list-filter", "list-tree", "qr-code", "radar", "sigma", "table", "table-cells-merge", "table-cells-split", "trending-down", "trending-up", "file", "file-archive", "file-check", "file-code", "file-image", "file-lock", "file-plus", "file-search", "file-spreadsheet", "file-text", "file-x", "files", "folder", "folder-open", "folder-plus", "folder-tree", "newspaper", "notebook", "presentation", "scroll-text", "sticky-note", "audio-lines", "camera", "camera-off", "captions", "film", "gallery-horizontal", "image", "image-off", "image-plus", "images", "mic", "mic-off", "music", "podcast", "video", "video-off", "circle-pause", "circle-play", "circle-stop", "fast-forward", "pause", "picture-in-picture", "play", "repeat", "rewind", "shuffle", "skip-back", "skip-forward", "volume-high", "volume-low", "volume-x", "a-arrow-down", "a-arrow-up", "a-large-small", "asterisk", "bold", "hash", "heading", "heading-1", "heading-2", "heading-3", "italic", "list", "list-indent-decrease", "list-indent-increase", "list-ordered", "quote", "remove-formatting", "spell-check", "strikethrough", "subscript", "superscript", "table-of-contents", "text-align-center", "text-align-end", "text-align-justify", "text-align-start", "text-quote", "text-select", "type", "underline", "align-center-horizontal", "align-center-vertical", "align-end-horizontal", "align-end-vertical", "align-start-horizontal", "align-start-vertical", "bring-to-front", "columns-2", "columns-3", "crop", "droplet", "eraser", "flip-horizontal", "flip-vertical", "highlighter", "layers", "paint-bucket", "brush", "palette", "eyedropper", "ruler", "send-to-back", "shapes", "signature", "at-sign", "bell", "bell-dot", "bell-off", "bell-ring", "forward", "inbox", "mail", "mail-open", "mail-plus", "megaphone", "chat", "chat-more", "chat-plus", "message-square", "message-square-dot", "message-square-reply", "messages-square", "phone", "phone-call", "phone-missed", "phone-off", "reply", "reply-all", "screen-share", "screen-share-off", "send", "smile", "voicemail", "barcode", "box", "credit-card", "gift", "package", "package-open", "receipt", "shopping-bag", "shopping-cart", "store", "tag", "tags", "ticket", "truck", "alarm-clock", "calendar", "calendar-check", "calendar-clock", "calendar-days", "calendar-plus", "calendar-range", "calendar-x", "clock", "history", "hourglass", "timer", "cookie", "fingerprint", "globe-lock", "key", "lock", "lock-open", "log-in", "log-out", "scan-face", "shield", "shield-alert", "shield-check", "shield-off", "shield-x", "vault", "incognito", "languages", "moon", "settings", "sliders", "sun-moon", "wrench", "building", "kanban", "milestone", "briefcase", "banknote", "circle-dollar-sign", "coins", "dollar-sign", "euro", "landmark", "percent", "scale", "wallet", "car", "hospital", "locate", "locate-fixed", "map", "map-pin", "map-pin-off", "map-pin-plus", "plane", "route", "waypoints", "app-window", "command", "panel-bottom", "panel-bottom-close", "panel-bottom-open", "sidebar", "panel-left-close", "panel-left-open", "panel-right", "panel-right-close", "panel-right-open", "power", "separator-horizontal", "battery", "battery-charging", "battery-full", "battery-low", "battery-medium", "battery-warning", "computer", "cpu", "hard-drive", "headphones", "keyboard", "laptop", "monitor", "monitor-smartphone", "mouse", "printer", "server", "smartphone", "tablet", "tv", "usb", "watch", "webcam", "bluetooth", "bluetooth-off", "cast", "cloud-off", "cloud-sync", "globe", "network", "plug", "radio-tower", "router", "rss", "signal", "unplug", "wifi", "wifi-high", "wifi-low", "wifi-off", "wifi-zero", "braces", "bug", "code", "component", "container", "database", "database-backup", "diff", "git-branch", "git-commit", "git-compare", "git-fork", "git-graph", "git-merge", "git-pull-request", "git-pull-request-closed", "git-pull-request-draft", "logs", "puzzle", "regex", "search-code", "terminal", "variable", "webhook", "workflow", "github", "award", "crown", "dice", "party-popper", "star", "star-half", "trophy", "bot", "brain", "sparkles", "magic-wand", "book", "book-open", "flask", "graduation-cap", "library", "cloud", "cloud-lightning", "cloud-rain", "snowflake", "sun", "thermometer", "wind", "accessibility", "calculator", "circle", "coffee", "copyright", "cross", "hexagon", "infinity", "leaf", "lightbulb", "recycle", "square", "target", "triangle" ] } ], "states": [ { "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" } ], "usageLevel": 1 }, { "name": "Loading", "attribute": "loading", "description": "indicate it is loading content", "usageLevel": 1 } ], "variations": [ { "name": "Link", "description": "be formatted as a link", "usageLevel": 1 }, { "name": "Fitted", "description": "be fitted without any space to the left or right of it.", "usageLevel": 1 }, { "name": "Colored", "attribute": "color", "includeAttributeClass": true, "usageLevel": 3, "description": "be colored", "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": "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": "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" } ], "includeAttributeClass": true }, { "name": "Spin", "description": "be formatted to spin like a loader", "usageLevel": 3, "attribute": "spin" } ], "settings": [ { "name": "set", "type": "string", "attribute": "set", "description": "The icon set to use" }, { "name": "href", "type": "string", "attribute": "href", "description": "Link to a page" }, { "name": "target", "type": "string", "attribute": "target", "description": "The target for a link" } ], "supportsPlural": true, "pluralName": "Icons", "pluralTagName": "ui-icons", "pluralDescription": "Icons exist together as a group", "pluralVariations": [ "colored", "size" ], "examples": { "defaultAttributes": { "icon": "check" } } }