Theming
Customize your forms to perfectly match your brand.
Set up custom themes
import { Composer, Formsmd } from "formsmd";
const composer = new Composer({
id: "my-form"
});
composer.opinionScale("nps", {
question: "How likely are you to recommend our product to a friend or colleague?",
required: true
});
// Set the themes during instantiation
const formsmd = new Formsmd(
composer.template,
document.getElementById("my-form-container"),
{
themeLight: {
accent: "#353148",
accentForeground: "#e2d2b6",
backgroundColor: "#e2d2b6",
color: "#353148"
},
themeDark: {
accent: "#e2d2b6",
accentForeground: "#353148",
backgroundColor: "#353148",
color: "#e2d2b6"
}
}
);
formsmd.init();

The themeLight and themeDark options
themeLight and themeDark optionsName
Type
Description
Light and dark modes
Toggle
Last updated