Back to directory
canonical avatar

vanilla-framework

From community websites to web applications, this CSS framework will help you achieve a consistent look and feel.. Read more below about its uses, features, and usage.

Clone repository

git clone https://github.com/canonical/vanilla-framework.git

980

Stars

207

Forks

31

Watchers

LGPL-3.0

License

vanilla Vanilla Framework

npm version Downloads Chat in #vanilla:ubuntu.com on Matrix This project is using Percy.io for visual regression testing.

Vanilla Framework is an extensible CSS framework, built using Sass and is designed to be used either directly or by using themes to extend or supplement its patterns.

Documentation |

Table of contents

Using Vanilla

Hotlinking

You can link to the latest build to add directly into your markup like so, by replacing the x values with the version number you wish to link.

<link rel="stylesheet" href="https://assets.ubuntu.com/v1/vanilla_framework_version_x_x_x_min.css" />

Including Vanilla in your project via NPM or yarn

To get set up with Sass, add the sass and vanilla-framework packages to your project dependencies:

yarn add sass vanilla-framework

In the script that builds the CSS in your package.json, you should include the path to node_modules when looking for @imports. In this example, we have called the build script "build-css":

"build-css": "sass -w --load-path=node_modules src:dist --style=compressed"

Make a folder src/, create a file inside called style.scss and import Vanilla:

// Import the theme
@import 'vanilla-framework';
@include vanilla;

// Optionally override some settings
$color-brand: #ffffff;

// Add theme if applicable

If you don't want the whole framework, you can just @include specific parts - e.g. @include vf-b-forms.

Now run yarn build-css, which will convert any Sass files in the src/ folder to CSS in the dist/ folder.

To watch for changes in your Sass files, add the following script to your package.json

"watch-css":  "yarn build-css && sass --load-path=node_modules -w src:dist --style=compressed"

Developing Vanilla

If you're looking to contribute to the Vanilla project itself, start here.

Community

Keep up to date with all new developments and upcoming changes with Vanilla.

Code licensed LGPLv3 by Canonical Ltd

With ♥ from Canonical

Releases

What's Changed

Card pattern title height by @petesfrench in #5832

Full Changelog: v4.57.0...v4.58.0

What's Changed

feat(WD-37057): add media (image, video) support to Tiered list pattern by @muhammad-ali-pk in #5817

Full Changelog: v4.56.0...v4.57.0

Getting Vanilla Framework Install with NPM: https://www.npmjs.com/package/vanilla-framework Visit the documentation at https://vanillaframework.io/docs New in Vanilla v4.56.0 🚀 Features

Add Ubuntu P...

Jun 26, 2026

v4.55.1

Download .zip

What's Changed

fix(CheckboxInput & RadioInput): handle wrapper by @kimanhou in #5818 fix(CheckboxInput & RadioInput): update releases.yml by @kimanhou in #5820

Full Changelog: v4.55.0...v.4.55.1

What's Changed

chore: skip Percy on Blocked PRs even with the Percy label by @Onibenjo in #5812 feat: Update position of CTA block in Tiered list and Equal heights patterns by @muhammad-ali-pk in #58...