Skip to main content

Theming API

Use the below variables to customize and theme the booking engine for your website.

Each of these variables has a defined default value which you can override by explicitly setting a variable in the style object. This object will be set as the value to the style parameter in the configuration object in the initSkipper function call.

type Style = {
// FONT CONFIGURATIONS
primaryFont?: StyleFont | string;
primaryFontBaseSize?: string;
primaryFontColor?: string;
secondaryFont?: StyleFont | string;
baseFontSize?: string;
secondaryFontColor?: string;

// MAIN COLOR CONFIGURATIONS
primaryColor?: string;
accentColor?: string;
accentFontColor?: string;
accentBackgroundColor?: string;
primaryBorderColor?: string;
primaryBackgroundColor?: string;
secondaryBorderColor?: string;
secondaryBackgroundColor?: string;
overlay?: Overlay | string;

// HELPER TEXT COLOR CONFIGURATIONS
placeholderFontColor?: string;
helperFontColor?: string;

// ADDITIONAL COLOR CONFIGURATIONS
alertColor?: string;
alertFontColor?: string;
alertBackgroundColor?: string;
successColor?: string;
successFontColor?: string;
successBackgroundColor?: string;
errorColor?: string;
errorFontColor?: string;
errorBackgroundColor?: string;
warningColor?: string;
warningFontColor?: string;
warningBackgroundColor?: string;
highlightColor?: string;
highlightFontColor?: string;
highlightBackgroundColor?: string;

// OPACITY
inactiveOpacity?: number;
disabledOpacity?: number;
highlightOpacity?: number;
stateOpacity?: number;
};

type StyleFont = {
family: string;
transform?: "uppercase" | "capitalize" | "lowercase" | "none";
letterSpacing?: string; // accepts any valid CSS value for the letter-spacing property
};

type Overlay = {
backgroundColor?: string;
opacity?: number;
};
FieldDescriptionFormatDefault Value
primaryFontThis is your brand's main header font type and will be applied broadly to header, and CTA text elements. You can either specify a font family as a string, or specify a StyleFont object if, in addition to the font family, you want transform the text in one of the specified ways. We expect this font family value to be already available in the environment of the website.OTF, TTF or StyleFont objectserif
primaryFontBaseSizeThe base font size for your header text. Increase this if your primaryFont is small.absolute size in pixels16px
primaryFontColorThe color of your primaryFont text used for headers.HEX value#000000
secondaryFontThis is your brand's main body font type and will be applied broadly to body, link, subheading, and description text elements. You can either specify a font family as a string, or specify a StyleFont object if, in addition to the font family, you want transform the text in one of the specified ways. We expect this font family value to be already available in the environment of the website.OTF, TTF or a StyleFont objectHelvetica
baseFontSizeThe base font size for your main body text. Increase this if your secondaryFont is small.absolute size in pixels16px
secondaryFontColorThe color of your secondaryFont text used for the main body text.HEX value#767676
primaryColorThis is your brand's main color and will be used across all CTA types. Additionally, opacity variations of this color will be applied in limited use as visual highlights or to designate inactive elements.HEX value#000000
accentColorThis is your brand's secondary color and will be used in limited use for banner & message elements.HEX value#3E8791
accentFontColorThe color of additional text that will be displayed with the accentBackgroundColor as the background.HEX value#FFFFFF
accentBackgroundColorThe background color of additional text that will be displayed with the accentFontColor as the text color.HEX value#3E8791
primaryBorderColorThe color for the calendar outline, form field border and loading placeholder animationHEX value#D9D9D9
primaryBackgroundColorThe main background color of the booking engineHEX value#FFFFFF
secondaryBorderColorThe color for the outline of areas where additional information is displayedHEX value#D9D9D9
secondaryBackgroundColorThe background color for areas where there is secondary informationHEX value#F1F2F4
overlayThis allows you to configure the widget's overlay background color and opacity.HEX value or Overlay object
placeholderFontColorThe color for placeholder text in form fieldsHEX value#A9A9A9
helperFontColorThe color for accessory textHEX value#767676
alertColorThe main color for alert and supplemental messaging and iconsHEX value#7E7E7E
alertFontColorThe text color that will be displayed with the alertBackgroundColor as the backgroundHEX value#7E7E7E
alertBackgroundColorThe background color for areas that will display an alertHEX value#7E7E7E
successColorThe main color for success messaging and iconsHEX value#22C55E
successFontColorThe text color that will be displayed with the successBackgroundColor as the backgroundHEX value#FFFFFF
successBackgroundColorThe background color for areas that will display a success messageHEX value#22C55E
errorColorThe main color for error messaging and iconsHEX value#B91C1C
errorFontColorThe text color that will be displayed with the errorBackgroundColorHEX value#000000
errorBackgroundColorThe background color for error messagingHEX value#EF5151
warningColorThe main color for warning messaging and iconsHEX value#FACC14
warningFontColorThe text color that will be displayed with the warningBackgroundColorHEX value#000000
warningBackgroundColorThe background color for warning messagingHEX value#FACC14
highlightColorThe main color for informative messaging and iconsHEX value#FFAD75
highlightFontColorThe text color that will be displayed with the highlightBackgroundColorHEX value#000000
highlightBackgroundColorThe background color for informative messagingHEX value#FFAD75
inactiveOpacityThe opacity for inactive statesHEX value0.5
disabledOpacityThe opacity for disabled statesHEX value0.3
stateOpacityThe opacity for focused, highlighted statesHEX value0.4

Examples

With StyleFont

window.initSkipper({
target: "skipper-target",
targetIds: ["main-reserve-button"],
targetClasses: ["other-reserve-buttons"],
hotelId: "HOTELID",
style: {
primaryColor: "#1B3A5C",
accentColor: "#7F9580",
primaryFont: {
family: "Comic Sans MS",
transform: "capitalize",
letterSpacing: "0.5px",
},
},
fallbackUrl: "https://<enter-fallback-CRS-or-PMS-site-here>",
});

Without StyleFont

window.initSkipper({
target: "skipper-target",
targetIds: ["main-reserve-button"],
targetClasses: ["other-reserve-buttons"],
hotelId: "HOTELID",
style: {
primaryColor: "#1B3A5C",
accentColor: "#7F9580",
primaryFont: "Comic Sans MS",
},
fallbackUrl: "https://<enter-fallback-CRS-or-PMS-site-here>",
});