The <zg-selector-mask> tag is a web component that is used to wrap the cells during user selection for styling purposes. The element should not be manually inserted by the user. The selector mask is styleable via CSS variables or the zg-selector-mask CSS selector.

Image of the DOM relationship for the zg-selector-mask web component tag

Related Web Components


A <zg-selector-mask> tag can be triggered by adding the selector attribute on the <zing-grid> tag, like so:

<zing-grid selector


There are no attributes available for the <zg-selector-mask> web component.

CSS Variables

<zg-selector-mask> can be styled with CSS variables, like so:

:root {
  --zg-selector-mask-background: red;

Below is a list of all the associated --zg-selector-mask CSS variables. Check out the full list of CSS variables or our Styling Basics guide to learn more about styling the grid.

ZGSelectorMask CSS Variables and Default Values
NameDefaultDescriptionDemoCSS Ref
--zg-selector-mask-backgroundvar(--theme-color-secondary)Styles the background of selector mask
--zg-selector-mask-opacity.1Sets the opacity of selector mask

CSS Selector

<zg-selector-mask> can be styled by common CSS selectors, like so:

zg-selector-mask {
  background: red;


There are no slots available for the <zg-selector-mask> web component.

[api: <zg-selector-mask>]