Branding

The branding property lets you customise the player's appearance to match your organisation's brand. For most use cases, setting brandColor1 and brandColor1Text is sufficient.

Quick start

lightbox({
  id: 'YOUR_MODULE_ID',
  branding: {
    colors: {
      brandColor1: 'rgb(186 48 0)',
      brandColor1Text: 'rgb(255 255 255)',
    },
    logo: {
      imageUrl: 'https://example.com/logo.png',
      imageWidth: '200px',
    },
  },
})

Colors

All color values should use CSS color syntax (e.g. rgb(186 48 0), #ba3000).

Brand colors

PropertyDescription
brandColor1Primary brand color — buttons, highlights, active elements
brandColor1TextText/icon color on primary brand elements
brandColor2Secondary brand color for secondary themed buttons
brandColor2TextText/icon color on secondary brand elements
brandColor3Tertiary brand color for tertiary themed buttons
brandColor3TextText/icon color on tertiary brand elements

Slide content colors

PropertyDescription
slideBrandColor1Primary color for branded slide elements
slideBrandColor2Secondary color for branded slide elements
slideBrandColor3Tertiary color for branded slide elements

UI element colors

PropertyDescription
appBackgroundApplication background (mobile/tablet)
appContentBackgroundMain content area background
appBoxShadowBox shadow for buttons, content area, and overlay boxes
lightboxBackgroundDesktop lightbox backdrop
loadingBackgroundLoading state background
loadingSpinnerLoading spinner color
bufferingBackgroundBuffering state background
bufferingSpinnerBuffering spinner color
primaryVideoButtonBackgroundPrimary play/pause button background
primaryVideoButtonIconPrimary play/pause button icon
secondaryVideoButtonBackgroundDesktopSecondary button background (desktop)
secondaryVideoButtonBackgroundMobileTabletSecondary button background (mobile/tablet)
secondaryVideoButtonIconSecondary button icon
readModeButtonBackgroundRead mode (accessibility) button background
readModeButtonIconRead mode button icon
exitButtonBackgroundExit button background
exitButtonIconExit button icon
keyboardFocusKeyboard focus outline color
scrollbarTrackScrollbar and desktop chapter navigation menu color
captionsTextColorCaptions text color
confettiConfetti animation color (opaque colors only)
textColorDarkDark text in the UI
textColorLightLight text in the UI
uiColorBlackThe 'black' used in the UI
uiColorWhiteThe 'white' used in the UI
uiColorErrorError state color
videoAvatarBoxShadowVideo avatar box shadow
videoAvatarPlayIconVideo avatar play icon

Logo

Display your organisation's logo in the player:

branding: {
  logo: {
    imageUrl: 'https://example.com/logo.png',
    imageWidth: '200px',           // optional, default "200px"
    backgroundColor: 'rgb(255 255 255)', // optional, adds padding
  },
}

Typography

Override the default font stacks. If you use non-system webfonts, ensure they are available on the page where the player appears.

branding: {
  typography: {
    fontStack1: "'Roboto', sans-serif",
    fontStack2: "'Roboto Slab', serif",
    fontUiApp: "'Roboto', sans-serif",
    fontUiSlide: "'Roboto', sans-serif",
    captionsFontWeight: '400',       // '400' or '700'
    chapterMenuFontWeight: '700',
  },
}

Custom fonts

Load custom fonts by providing URLs to the font files:

branding: {
  fonts: [{
    family: 'vcCustomFont',
    regular: 'https://example.com/fonts/CustomFont-Regular.ttf',
    bold: 'https://example.com/fonts/CustomFont-Bold.ttf',
  }],
}

CSS variable overrides

For advanced customisation beyond the typed properties, you can set CSS variables directly. These take precedence over colors and typography for any overlapping values.

branding: {
  cssVariables: [
    { name: '--app-content-background-color', value: 'rgb(245 245 245)' },
  ],
}

Custom CSS

For cases where CSS variables aren't sufficient, inject custom CSS rules targeting specific device layouts. Each rule will automatically have !important appended to ensure highest specificity. Custom CSS only applies to "watch" mode and has no effect on "read" mode.

branding: {
  customCss: [{
    name: 'all',
    value: '.sx-button--theme-video-primary { background-color: rgb(255 0 0); }',
  }],
}

Available device targets: all, desktop, mobile-portrait, mobile-landscape, tablet-portrait, tablet-landscape, tablet-portrait-desktop, tablet-landscape-desktop, mobile-tablet-portrait, mobile-tablet-landscape.

Note that the value string should not contain line break characters. If targeting multiple classes, concatenate them in a single string.