Styler

The Styler allows you to design an unlimited number of styles that can be applied to any WordPress form built with WS Form with ease. Whether you want to maintain consistent branding across your WordPress site or tailor the appearance of individual forms for specific purposes, the Styler offers the flexibility to create, design, and manage styles effortlessly.

For developers, the Styler provides access to over 400 customizable settings, all easily managed using CSS variables for maximum flexibility and control. For beginners, creating styles is a breeze with intuitive options for adjusting colors, sizes, and other design elements, no coding required.

What is a Style?

A style in WS Form is a structured hierarchy of CSS variables, beginning with high-level settings like the color palette and typography. These foundational elements cascade down to progressively more specific settings, including sections, fields, and even individual field types, ensuring a consistent and customizable design throughout your forms.

How to Edit a Style

There are two ways to open the Styler to edit a style.

  1. To edit a style, click Edit on the Styles admin page. This opens the Styler, displaying a sample form with fields that allow you to preview most Styler settings in real time.
WS Form - Styler - Admin Table - Edit Link
  1. Click the Style  icon at the top of the form layout editor. This opens your form alongside the Styler, allowing you to customize its appearance seamlessly.
WS Form - Styler - Layout Editor - Style Button

Quick Start: The Form Category

The Form category in the Styler can be used to change the majority of the styling in a form and provides a quick way of getting the bulk of your form styled. For example, changing the Base color will change other elements on the form such as label colors, help text and input colors automatically.

WS Form - Styler - Form Category

The Form category includes the following style settings:

Sub CategorySettingTypeDefaultDescription
BorderColorColortransparentThe border color. Learn more.
RadiusSize0pxThe border radius. Learn more.
WidthSize0pxThe border width. Learn more.
StyleTextsolidThe border style. Learn more.
Color PaletteBackgroundColortransparentThe form background color.
BaseColor#000000Main color used for labels, inputs and help text.
Base – ContrastColor#ffffffContrast color used for checkmarks, button text, etc.
AccentColor#205493Used for checked and styled checkboxes and radio fields, range slider thumb, etc.
NeutralColor#767676Used for neutral tones on the form such as the file upload button.
PrimaryColor#205493Used for the form submit button and any elements configured to use the Primary color.
SecondaryColor#5b616bDefault color used for other buttons.
SuccessColor#2e8540Used for success messages.
InformationColor#02bfe7Used for information messages.
WarningColor#fdb81eUsed for warning messages.
DangerColor#bb0000Used for error messages and invalid feedback.
SpacingGrid GapSize20pxThe spacing between fields.
Padding – HorizontalSize0pxHorizontal form padding.
Padding – VerticalSize0pxVertical form padding.
TransitionSpeedText200msThe time for transitions it takes for general transitions to run on the form.
Timing FunctionTextease-in-outThe CSS timing function used for transitions. Learn more
TypographyFont FamilyTextinheritThe base font family used throughout the form.
Font SizeSize16pxThe base font size used throughout the form.
Font Size – SmallSize14pxThis is primarily used on field help text.
Font Size – LargeSize18pxThis is primarily used on legends.
Font StyleTextinheritDefines italic or normal text style. Learn more.
Font WeightTextinheritControls text boldness or lightness. Learn more.
Letter SpacingTextinheritAdjusts space between text characters. Learn more.
Line HeightSixe1.4Sets spacing between text lines. Learn more.
Text DecorationTextinheritAdds lines, styles, or colors. Learn more.
Text TransformTextinheritChanges text casing styles. Learn more.

These settings may vary slightly for conversation styles where font sizes and spacing are increased for legibility.

How to Save a Style

Once you have finished making changes to a style, click the Save  icon. This will immediately publish the style ready for use on the website.

The Styler Sidebar

The Styler will open on the left and side of your form by default.

WS Form - Styler - Diagram

Style Name

The Style Name is shown at the top of the Styler. To edit the style name click the Settings icon at the top, change the name, then click the Save icon.

You can search for settings in a variety of ways:

  • Variables (e.g. --wsft-form-color-background)
  • Variable names (e.g. button primary)
  • Category names (e.g. typography)

Simply enter keywords into the search (minimum 2 characters) and the setting hierarchy will be filtered.

Style Categories

The top level style categories are:

  • Form
  • Tab
  • Section
  • Field
  • Field Type
  • Conversational (Only for conversation forms)

To open a category and view the sub-categories click the category name.

Use the Form category to change the main colors, sizes and typography settings for your form.

For more granular control, browse the other top level categories or use the Setting Search to find a particular setting.

Style Setting

There are various types of Style Setting.

Color

Color settings allow you to pick any color for a form element.

WS Form - Styler - Setting - Color

To use the color picker to choose a color, simply click the Swatch.

The following values can be entered into the color Setting Value.

Color ModelExampleDescription
Hex#ff0000Hexadecimal as #rrggbb.
Hex 8#ff000088Hexadecimal with alpha as #rrggbbaa.
RGBrgb(255, 0, 0)Red, green, blue as rgb(r, g, b).
RGBArgba(255, 0, 0, 0)Red, green, blue, alpha as rgba(r, g, b, a).
HSLhsl(0, 100%, 50%)Hue, saturation and lightness as hsl(h, s, l).
HSLAhsla(0, 100%, 50%, 0.533)Hue, saturation and lightness as hsla(h, s, l, a).
var()var(--accent-color)CSS variable.

Size

Size settings allow you to set the size of a form element.

WS Form - Styler - Setting - Size The following values can be entered into the color Setting Value.

Unit of MeasurementExampleTypeDescription
px16pxAbsolutePixels: A fixed unit, most commonly used.
em1.5emRelativeRelative to the font size of the element.
rem1.5remRelativeRoot em: Relative to the font size of the root element.
%90%RelativePercentage: Relative to the parent element’s size.
var()var(--font-size-base)CSS variable.

We recommend a base pixels size of at least 16 pixels to help with the accessibility of your form.

Other Settings

Other settings include:

  • Font family
  • Font style
  • Font weight
  • Text decoration
  • Text transform

These values have text inputs that support a CSS value or variable.

Style Undo

Any changes made during a given editing session can be undone by clicking the Style Undo  icon. This will reset all of the settings in the style those the values that were present when the Styler was opened.

If you want to fully reset a style to the system defaults, you can do that from the Styles admin page by clicking the Reset link.

Settings

The settings panel allows you change the style name and also enable the alternative colors scheme. To access the settings panel click the Settings  icon.

Save

The Save  icon is used to publish the changes you have made to the style so that they are committed to the live version of any form using that style.

If you are making significant changes to a style, consider cloning it or exporting a backup prior to doing so.

Repositioning the Styler

You can temporarily move the Styler by clicking and dragging the WS Form logo. If the Styler is position at the left or right of the screen, WS Form will attempt to lock it in position and introduce left or right margin to the body element to provide you with a better view of your form.