theme object passed to
VirtualTryOn.init(). No CSS files, no overrides, no build step.
Every part of the widget’s UI renders inside a Shadow DOM. That means theming
is fully isolated: your site’s CSS never leaks into the widget, and the widget
never breaks your styles. You change the look exclusively through the
theme
object.How theming works
Pass atheme object to VirtualTryOn.init(). All fields are optional — omit
theme entirely and you get the default sage-green dark theme.
Theme modes
Themode field switches the entire color palette. The default is 'dark'.
In light mode, surfaces become white and neutral, and the accent shifts to a
darker sage green (
#4d7c4b) for stronger contrast against light backgrounds.
Shadows are also softened for a lighter feel.Custom brand colors & fonts
Override individual properties to match your brand. Here is a fulltheme object
using every available option:
Theme options
All parameters are optional. Omittheme entirely to use the default dark
appearance.
Examples
Mix and match the options below to match your store. Each tab is a drop-intheme
object.
- Light mode
- Custom accent
- Custom fonts
- Corners
- Fully customized
Advanced: CSS variables
This section is optional. The
theme object covers everything most merchants
need — reach for these variables only when inspecting or fine-tuning in dev tools.theme parameters to CSS custom properties defined
on the Shadow DOM :host — for example --vto-accent, --vto-bg-primary,
--vto-radius-md, and --vto-font-sans. You can inspect all of them in your
browser’s dev tools by selecting the widget’s shadow root.
Surfaces
Surfaces
Text
Text
Accent
Accent
Radii
Radii
Typography
Typography
Next steps
Widget Overview
See everything the widget does and how it fits together.
Quickstart
Get the widget running and run your first try-on.