<titledata-rh="true">Special Components | SketchyBar</title><metadata-rh="true"name="twitter:card"content="summary_large_image"><metadata-rh="true"property="og:url"content="https://felixkratz.github.io//SketchyBar/config/components"><metadata-rh="true"name="docusaurus_locale"content="en"><metadata-rh="true"name="docsearch:language"content="en"><metadata-rh="true"name="docusaurus_version"content="current"><metadata-rh="true"name="docusaurus_tag"content="docs-default-current"><metadata-rh="true"name="docsearch:version"content="current"><metadata-rh="true"name="docsearch:docusaurus_tag"content="docs-default-current"><metadata-rh="true"property="og:title"content="Special Components | SketchyBar"><metadata-rh="true"name="description"content="Components -- Special Items with special properties"><metadata-rh="true"property="og:description"content="Components -- Special Items with special properties"><linkdata-rh="true"rel="icon"href="/SketchyBar/img/favicon.ico"><linkdata-rh="true"rel="canonical"href="https://felixkratz.github.io//SketchyBar/config/components"><linkdata-rh="true"rel="alternate"href="https://felixkratz.github.io//SketchyBar/config/components"hreflang="en"><linkdata-rh="true"rel="alternate"href="https://felixkratz.github.io//SketchyBar/config/components"hreflang="x-default"><linkrel="stylesheet"href="/SketchyBar/assets/css/styles.d31a9c85.css">
<divrole="region"><ahref="#"class="skipToContent_ZgBM">Skip to main content</a></div><navclass="navbar navbar--fixed-top"><divclass="navbar__inner"><divclass="navbar__items"><buttonaria-label="Navigation bar toggle"class="navbar__toggle clean-btn"type="button"tabindex="0"><svgwidth="30"height="30"viewBox="0 0 30 30"aria-hidden="true"><pathstroke="currentColor"stroke-linecap="round"stroke-miterlimit="10"stroke-width="2"d="M4 7h22M4 15h22M4 23h22"></path></svg></button><aclass="navbar__brand"href="/SketchyBar/"><divclass="navbar__logo"><imgsrc="/SketchyBar/img/logo.svg"alt="SketchyBar Logo"class="themedImage_W2Cr themedImage--light_TfLj"><imgsrc="/SketchyBar/img/logo.svg"alt="SketchyBar Logo"class="themedImage_W2Cr themedImage--dark_oUvU"></div><bclass="navbar__title">SketchyBar</b></a></div><divclass="navbar__items navbar__items--right"><aclass="navbar__item navbar__link"href="/SketchyBar/features">Features</a><aclass="navbar__item navbar__link"href="/SketchyBar/setup">Setup & Installation</a><aclass="navbar__item navbar__link"href="/SketchyBar/config/bar">Configuration</a><ahref="https://github.com/FelixKratz/SketchyBar"target="_blank"rel="noopener noreferrer"class="navbar__item navbar__link"></a><divclass="toggle_S7eR colorModeToggle_vKtC"><buttonclass="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x"type="button"disabled=""title="Switch between dark and light mode (currently light mode)"aria-label="Switch between dark and light mode (currently light mode)"><svgviewBox="0 0 24 24"width="24"height="24"class="lightToggleIcon_v35p"><pathfill="currentColor"d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svgviewBox="0 0 24 24"width="24"height="24"class="darkToggleIcon_nQuB"><pathfill="currentColor"d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div></div></div><divrole="presentation"class="navbar-sidebar__backdrop"></div></nav><divclass="main-wrapper"><divclass="docPage_P2Lg"><buttonaria-label="Scroll back to top"class="clean-btn theme-back-to-top-button backToTopButton_RiI4"type="button"></button><asideclass="theme-doc-sidebar-container docSidebarContainer_rKC_"><divclass="sidebar_RiAD"><navclass="menu thin-scrollbar menu_izAj"><ulclass="theme-doc-sidebar-menu menu__list"><liclass="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><aclass="menu__link"href="/SketchyBar/features">Features</a></li><liclass="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><aclass="menu__link"href="/SketchyBar/setup">Setup</a></li><liclass="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item"><divclass="menu__list-item-collapsible"><aclass="menu__linkmenu__link--sublistmenu__link--sublist
Currently there are the components (more details in the corresponding sections below):</p><ul><li><em>graph</em>: showing a graph,</li><li><em>space</em>: representing a mission control space</li><li><em>bracket</em>: brackets together other items</li><li><em>alias</em>: an alias of a menu bar item from the macOS bar</li></ul><h3class="anchor anchorWithStickyNavbar_mojV"id="data-graph----draws-an-arbitrary-graph-into-the-bar">Data Graph -- Draws an arbitrary graph into the bar<aclass="hash-link"href="#data-graph----draws-an-arbitrary-graph-into-the-bar"title="Direct link to heading"></a></h3><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add graph </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">position</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">width </span><spanclass="token keyword"style="font-style:italic">in</span><spanclass="token plain"> points</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>Additional graph properties:</p><table><thead><tr><thalign="center"><property<!---->></th><thalign="center"><value<!---->></th><thalign="center">default</th><th>description</th></tr></thead><tbody><tr><tdalign="center"><code>graph.color</code></td><tdalign="center"><code><argb_hex></code></td><tdalign="center"><code>0xcccccc</code></td><td>Color of the graph line</td></tr><tr><tdalign="center"><code>graph.fill_color</code></td><tdalign="center"><code><argb_hex></code></td><tdalign="center"><code>0xcccccc</code></td><td>Fill color of the graph</td></tr><tr><tdalign="center"><code>graph.line_width</code></td><tdalign="center"><code><float></code></td><tdalign="center"><code>0.5</code></td><td>Width of the line in points</td></tr></tbody></table><p>Push data points into the graph via:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --push </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">data point</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="00242
if you set a background for the graph item and set a height for it, the graph
will draw inside of the background. With a background enabled, the graph can
also be moved via a <code>y_offset</code>, e.g.:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --set </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">graph name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"> background.color</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token plain">0xff00ff00 background.height</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token number"style="color:rgb(247, 140, 108)">20</span><spanclass="token plain"></span><spanclass="token assign-left variable"style="color:rgb(191, 199, 213)">y_offset</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token number"style="color:rgb(247, 140, 108)">2</span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><h3class="anchor anchorWithStickyNavbar_mojV"id="space----associate-mission-control-spaces-with-an-item">Space -- Associate mission control spaces with an item<aclass="hash-link"href="#space----associate-mission-control-spaces-with-an-item"title="Direct link to heading"></a></h3><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add space </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">position</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>The space component overrides the definition of the following properties and they must be set to correctly associate a mission control space with this item:</p><ul><li><em>associated_space</em>: Which space this item represents</li><li><em>associated_display</em>: On which display the <em>associated_space</em> is shown.</li></ul><p>The space component has additional variables available in <em>scripts</em>:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="tokenvariab
<code>false</code> if the associated space is not selected, while
<code>$SID</code> holds the space id and <code>$DID</code> the display id.</p><p>By default the space component invokes the following script:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --set </span><spanclass="token variable"style="color:rgb(191, 199, 213)">$NAME</span><spanclass="token plain"> icon.highlight</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token variable"style="color:rgb(191, 199, 213)">$SELECTED</span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>which you can freely configure to your liking by supplying a different script
to the space component:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --set </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token assign-left variable"style="color:rgb(191, 199, 213)">script</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">script/path</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>For performance reasons the space script is only run on a change in the
<code>$SELECTED</code> variable, i.e. if the associated space has become active
or has resigned being active.</p><h3class="anchor anchorWithStickyNavbar_mojV"id="item-bracket----group-items-in-eg-colored-sections">Item Bracket -- Group Items in e.g. colored sections<aclass="hash-link"href="#item-bracket----group-items-in-eg-colored-sections"title="Direct link to heading"></a></h3><p>It is possible to bracket together items via the command (see <ahref="https://github.com/FelixKratz/SketchyBar/discussions/12#discussioncomment-1455842"target="_blank"rel="noopener noreferrer">this</a> discussion for an example):</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add bracket </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">first item name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">..</span><spanclass="token plain">. </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">n-th item name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>The first item must always be the one listed earliest in the config. It is now possible to
E.g., if I wanted a colored background around <em>all</em> my space components (which are named <em>code</em>, <em>writing</em>, <em>reading</em> and <em>entertainment</em>) I would set it up like this:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add bracket primary_spaces code </span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> writing </span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> reading </span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> entertainment </span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"></span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> --set primary_spaces background.color</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token plain">0xffffffff </span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> background.corner_radius</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token number"style="color:rgb(247, 140, 108)">4</span><spanclass="token plain"></span><spanclass="token punctuation"style="color:rgb(199, 146, 234)">\</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain"> background.height</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token number"style="color:rgb(247, 140, 108)">20</span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>this draws a white background below all my space components.</p><h3class="anchor anchorWithStickyNavbar_mojV"id="item-alias----mirror-items-of-the-original-macos-status-bar-into-sketchybar">Item Alias -- Mirror items of the original macOS status bar into sketchybar<aclass="hash-link"href="#item-alias----mirror-items-of-the-original-macos-status-bar-into-sketchybar"title="Direct link to heading"></a></h3><p>It is possible to create an alias for default menu bar items
(such as MeetingBar, etc.) in sketchybar. The default menu bar can be set to
autohide and this should still work.</p><p>To create an alias of a default menu bar item use the following syntax:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add </span><spanclass="token builtin class-name"style="color:rgb(255, 203, 107)">alias</span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">application_name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">position</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>this operation requires <em>screen capture permissions</em>, which should be granted
in the system preferences.</p><p>This will put the default macOS menu bar item into sketchybar. If an
application has multiple menu bar widgets the command can be overloaded by
providing a <em>window_owner</em> and a <em>window_name</em></p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --add </span><spanclass="token builtin class-name"style="color:rgb(255, 203, 107)">alias</span><spanclass="token plain"></span><spanclass="token string"style="color:rgb(195, 232, 141)">"<window_owner>,<window_name>"</span><spanclass="token plain"></span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">position</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>this way the default system items can also be aliased in sketchybar as well,
e.g.:</p><ul><li>"Control Center,Bluetooth"</li><li>"Control Center,WiFi"</li><li>...</li></ul><p>Or the individual widgets of <ahref="https://github.com/exelban/stats"target="_blank"rel="noopener noreferrer">Stats</a>:</p><ul><li>"Stats,CPU_Mini"</li><li>etc...</li></ul><p>All further macOS menu bar items currently available on your system can be
found via the command</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --query default_menu_items</span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>where all items with their respective owner and name are listed.</p><p>You can override the color of an alias via the property:</p><divclass="codeBlockContainer_I0IT language-bash theme-code-block"><divclass="codeBlockContent_wNvx"style="color:#bfc7d5;background-color:#292d3e"><pretabindex="0"class="prism-code language-bash codeBlock_jd64 thin-scrollbar"><codeclass="codeBlockLines_mRuA"><spanclass="token-line"style="color:#bfc7d5"><spanclass="token plain">sketchybar --set </span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">name</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><spanclass="token plain"> alias.color</span><spanclass="token operator"style="color:rgb(137, 221, 255)">=</span><spanclass="token operator"style="color:rgb(137, 221, 255)"><</span><spanclass="token plain">argb_hex</span><spanclass="token operator"style="color:rgb(137, 221, 255)">></span><br></span></code></pre><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="copyButton_eDfN clean-btn"><spanclass="copyButtonIcons_W9eQ"aria-hidden="true"><svgclass="copyButtonIcon_XEyF"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_i9w9"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div><p>Aliases currently are not clickable but can be modified with all the options
available for simple items.</p></div></article><navclass="pagination-nav docusaurus-mt-lg"aria-label="Docs pages navigation"><divclass="pagination-nav__item"><aclass="pagination-nav__link"href="/SketchyBar/config/items"><divclass="pagination-nav__sublabel">Previous</div><divclass="pagination-nav__label">Item Properties</div></a></div><divclass="pagination-nav__item pagination-nav__item--next"><aclass="pagination-nav__link"href="/SketchyBar/config/popups"><divclass="pagination-nav__sublabel">Next</div><divclass="pagination-nav__label">Popup Menus</div></a></div></nav></div></div><divclass="col col--3"><divclass="tableOfContents_cNA8 thin-scrollbar theme-doc-toc-desktop"><ulclass="table-of-contents table-of-contents__left-border"><li><ahref="#components----special-items-with-special-properties"class="table-of-contents__link toc-highlight">Components -- Special Items with special properties</a><ul><li><ahref="#data-graph----draws-an-arbitrary-graph-into-the-bar"class="table-of-contents__link toc-highlight">Data Graph -- Draws an arbitrary graph into the bar</a></li><li><ahref="#space----associate-mission-control-spaces-with-an-item"class="table-of-contents__link toc-highlight">Space -- Associate mission control spaces with an item</a></li><li><ahref="#item-bracket----group-items-in-eg-colored-sections"class="table-of-contents__link toc-highlight">Item Bracket -- Group Items in e.g. colored sections</a></li><li><ahref="#item-alias----mirror-items-of-the-original-macos-status-bar-into-sketchybar"class="table-of-contents__link toc-highlight">Item Alias -- Mirror items of the original macOS status bar into sketchybar</a></li></ul></li></ul></div></div></div></div></main></div></div></div>