amir2mi / flatifycss
Modern flat design framework for the web, inspired by Duolingo design system.
Requires
None
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
- dev-master
- v2.0.1
- v2.0.0
- v1.5.3
- v1.5.2
- v1.5.1
- v1.5.0
- v1.4.1
- v1.4.0
- v1.3.4
- v1.3.3
- v1.3.2
- v1.3.1
- v1.3.0
- v1.2.14
- v1.2.13
- v1.2.12
- v1.2.11
- v1.2.10
- v1.2.9
- v1.2.8
- v1.2.7
- v1.2.6
- v1.2.5
- v1.2.4
- v1.2.3
- v1.2.2
- v1.2.1
- v1.2.0
- v1.1.9
- v1.1.8
- v1.1.7
- v1.1.6
- v1.1.5
- v1.1.4
- v1.1.3
- v1.1.2
- v1.1.1
- v1.1.0
- v1.0.2
- v1.0.1
- dev-ami-momo-patch-1
- dev-revive-docs
- dev-amir2mi-patch-1
- dev-feature/dynamic-rtl
- dev-add-toast
This package is auto-updated.
Last update: 2026-11-27 18:36:54 UTC
README
FlatifyCSS
Modern flat design framework for the web, inspired by Duolingo design system.
Documentation • News • Issues • React components
Getting started
You can use FlatifyCSS in several ways:
- Install it using package managers
- Load it directly from a CDN
- Download the latest project files
CDN
You can add FlatifyCSS using jsDelivr with these lines of code, @2 keeps you on the latest 2.x release:
<!-- CSS --> <link href="https://cdn.jsdelivr.net/npm/flatifycss@2/dist/css/flatify-min.css" rel="stylesheet" crossorigin="anonymous" /> <!-- JavaScript : Popperjs + FlatifyCSS --> <script src="https://unpkg.com/@popperjs/core@2" crossorigin="anonymous"></script> <script src="https://cdn.jsdelivr.net/npm/flatifycss@2/dist/js/flatify-min.js" crossorigin="anonymous"></script>
Here is a whole page to start from:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <link href="https://fonts.googleapis.com/css2?family=Fira+Code&family=Nunito:wght@400;600;700&display=swap" rel="stylesheet" /> <link href="https://cdn.jsdelivr.net/npm/flatifycss@2/dist/css/flatify-min.css" rel="stylesheet" /> <title>Hello FlatifyCSS</title> </head> <body class="container-md"> <h1>Hello!</h1> <button class="button style-accent">It works</button> </body> </html>
Package managers
You can include FlatifyCSS in your project using npm, Yarn, Bun or Composer:
npm install flatifycss yarn add flatifycss bun add flatifycss composer require amir2mi/flatifycss
Then import the files you need, for example in a bundler:
import "flatifycss/dist/css/flatify-min.css"; import "flatifycss/dist/js/flatify-min.js";
Sass
The Sass source is in the /scss folder. Every variable uses !default, so you can change colors, fonts and sizes without touching the package files:
@use "flatifycss/scss/flatify" with ( $ACCENT_COLOR: #8e44ad, $BORDER_RADIUS: 0.5em );
All variables are listed on the customization page.
Contents
After installing FlatifyCSS or downloading the archive file, you'll find a /dist folder with compiled CSS, JS, and their map files:
CSS
- Files with
-noprefixdon't use PostCSS Autoprefixer - Files with
-minare minified
Available CSS files:
flatify.cssflatify-min.cssflatify-noprefix.cssflatify-noprefix-min.css
The same files work for left to right and right to left pages, set dir="rtl" on <html>. The old flatify-rtl*.css files from version 1 are still there as copies, they will be removed in version 3.
JS
Note: FlatifyCSS needs Popperjs for dropdowns and popovers. This library isn't included in FlatifyCSS's JavaScript file, so you need to add it to your webpage separately. The JavaScript is only needed for interactive components, see the JavaScript page.
flatify.jsflatify-min.js
Dark mode
There is a %dark-mode Sass placeholder, and the compiled CSS can do it with a few CSS variables. Both ways are on the dark mode page.
React
Using React? React FlatifyCSS has the components ready, with TypeScript types.
Development
I use Bun for everything here.
- Run
bun installin the root directory - Run
bun run buildto compile the stylesheet and JavaScript file into/dist - Run
bun run watchwhile you work
After building, open examples/playground.html in your browser to try the components with the local CSS and JavaScript.
The documentation website is in /website, run bun install and bun start there. For more information about FlatifyCSS's Gulp tasks, read here.
Contributing
Found a bug or have an idea? Open an issue first, then pull requests are welcome. Please keep changes small and follow the code standards.