pseudo-element

::scroll marker group — CSS reference

Styles the generated box that collects scroll markers. The originating element is the scroller, not each item. The group can arrange the indicators with flexbox; it is distinct from the scrolling content.

Formal Syntax & Structure

css syntaxcss
::scroll-marker-group { display: flex; }

Working Example

Example Snippetcss
<!doctype html><html lang="en"><meta charset="utf-8"><title>::scroll-marker-group</title><style>body{margin:8px;font:16px/20px sans-serif;color:black;background:white}#s{width:200px;height:100px;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-marker-group:after}#s>div{flex:0 0 200px;scroll-snap-align:start;background:#e2e8f0}#s::scroll-marker-group{display:flex;gap:10px}#s>div::scroll-marker{content:"●";color:blue}#s>div::scroll-marker:target-current{color:red}#s::scroll-button(inline-end){content:"Next";display:block;width:80px;height:32px}</style><body><div id="s"><div id="a">First</div><div id="b">Second</div><div id="c">Third</div></div></body></html>
CSS Reference