Selector API
Rules must target at least one .sp-* class from the tables below. Every .sp-* class in a selector must be from this list. Unknown classes are rejected at validation time.
Non-.sp- tokens are allowed as part of a selector, provided a valid .sp-* class is also present:
/* Allowed: sp- root class present, element and class descendants are fine */
.sp-topbar a { color: white; }
.sp-markdown-content h1, .sp-markdown-content h2 { color: #004831; }
.sp-sidenav-item-bg div { color: #2d406c; }
/* Rejected: no sp- class at all */
h1 { color: red; }
/* Rejected: sp-unknown not in the allowed list */
.sp-unknown { color: red; }Generic components
Selector | Component | Notes |
|---|---|---|
| Consumer app root | Set |
| Page background behind the whole consumer app | Overrides the default light and dark page background. |
| Any dropdown wrapper | Shared Select component. All product selectors. |
| Any dropdown trigger button | |
| Any dropdown options panel | Option items are div elements. Target with |
| Any radio button row | Routing modal, mobile mode picker. |
| Any counter badge | Search result tab counts. |
Top bar
Selector | Component | Notes |
|---|---|---|
| Top navigation bar | Also applied to the profile icon button. |
| Portal name and logo link | |
| Product dropdown wrapper | |
| Product dropdown trigger button | |
| Product dropdown panel | |
| Profile icon button | Use to override sp-topbar styles on the button specifically. Border rules are ignored to prevent layout overflow. |
| Sidebar-open icon button (tablet and mobile only) | Sits inside |
| Right-side icon group (profile, search) on mobile | Wrapper around the icons shown at tablet and mobile breakpoints. |
| Colored stripe below the top bar | Override via |
Landing page
Selector | Component | Notes |
|---|---|---|
| Landing page outer wrapper | |
| Inner section behind the product grid | Separate from |
| Hero section wrapper | |
| Hero text and description area | Contains a prose container. |
| Product tile grid container | |
| Individual product card | |
| Colored accent bar on tile | Override via |
| Product name | |
| Product description text |
Profile menu
Selector | Component |
|---|---|
| Profile dropdown panel |
| User email text in desktop profile dropdown |
| Provider (single sign-on) login button |
| Light, dark, and system mode flyout panel |
| Mode option button (Light, Dark, System) |
| Mode toggle button in the top bar (logged-out only) |
| Dropdown panel of the logged-out Mode toggle |
| Mode option button in logged-out dropdown |
| Log in button in the top bar (logged-out only) |
| Mobile profile slide-out panel |
| Panel heading text ("Profile") |
| Header row (title and close button). |
| Close button |
| User email and manage account section. |
| User email text |
| "Manage my account" link |
| Dark, light, and system mode picker section. |
| Mode section label ("Mode" and icon) |
| Each Light, Dark, or System radio row |
| Mode option preview image (light, dark, system) |
| Radio input circle border color (all states) |
| Radio filled dot (shown when selected) |
| Logout (or login) row |
Search
Selector | Component | Notes |
|---|---|---|
| Search trigger button in top bar | |
| Keyboard shortcut hint containers | |
| Search text input | |
| Search dialog container | |
| Exit and close area at top of search modal (desktop) | |
| Close button on mobile search modal | |
| Product filter dropdown panel | |
| All, Products, APIs tab row | |
| Result count badge on each tab | |
| Left and right scroll arrows on the tab list when it overflows | |
| Product filter dropdown trigger button (mobile search view) | |
| Product filter dropdown options panel (mobile search view) | |
| Individual result row | |
| Highlighted matching text within a result | |
| Empty state shown before any search is performed | |
| State shown when a search returns no results | |
| Loading indicator while results are fetching | |
| HTTP or AsyncAPI method label (GET, POST, PUB), shown in search results and the side navigation | Override |
Side navigation
Selector | Component | Notes |
|---|---|---|
| Side navigation panel | |
| Inner scrollable area | Has its own background. Must be targeted separately from |
| Nav item row (outer wrapper) | Does not directly render background or text color. |
| Nav item inner background div | Target this for background and hover colors. |
| Active nav item | |
| API endpoint group item | |
| Expanded operations panel | |
| Tag and group header row | |
| Hover highlight overlay | |
| Individual operation row | Set text color on the side nav. |
| Active and selected operation | |
| Responsive side-nav drawer panel (mobile and tablet) | |
| Header strip at the top of the responsive side-nav | |
| Product switcher wrapper inside the responsive side-nav header | |
| Trigger button of the product switcher in the responsive side-nav | |
| Dropdown options list of the product switcher in the responsive side-nav |
Main content
Selector | Component | Notes |
|---|---|---|
| Main content wrapper | |
| Breadcrumb bar | |
| Markdown and HTML document content | |
| Table of contents sidebar | |
| Nav inside the sidebar | Set |
| Table of contents link | |
| Currently visible section link | |
| Anchor copy-link button beside h2 and h3 headings | SVG icon. Use |
| Last modified date string | |
| Horizontal rule below document title | Use |
| Doc page outer flex container | |
| Doc page inner content column |
API viewer
Selector | Component | Notes |
|---|---|---|
| API spec renderer wrapper | |
| Toolbar above the spec | |
| Scrollable spec content area | Use |
| Download API dropdown trigger | |
| Download format options panel | |
| Elements and Swagger UI toggle wrapper | |
| Toggle track button | |
| Try-it-out routing button | |
| Explore in SwaggerHub link | |
| Generate Code button wrapper | |
| Open in Swagger Studio button | |
| Edit and manage content button | |
| Last modified date above spec |
Routing modal
Selector | Component | Notes |
|---|---|---|
| Try-it-out routing settings dialog | |
| Cancel button | |
| Confirm and save button | |
| Credentials toggle switch | |
| Radio button container | Use |
Other
Selector | Component |
|---|---|
| Tooltip panel |
| 404 page wrapper |
| 404 content card |
| 404 heading |
| 404 body text |
Footer
Selector | Component |
|---|---|
| Footer outer wrapper |
| Inner content wrapper. Controls the top border between footer and page content. |
| Footer description text |
| Footer links row |
| Individual footer link anchors (descendant of |
| Divider icons between links (descendant of |
| Footer logo image (descendant of |
| SmartBear attribution bar |