GithubHelp home page GithubHelp logo

dartsidedev / kolors Goto Github PK

View Code? Open in Web Editor NEW
1.0 0.0 0.0 2.95 MB

The named HTML colors that you can use in your Flutter apps.

Home Page: https://pub.dev/packages/kolors

License: BSD 3-Clause "New" or "Revised" License

Dart 92.65% HTML 7.35%
flutter dart flutter-package html-colors named-colors hex-colors pubdev pub-dev

kolors's Introduction

kolors

The named HTML colors that you can use in your Flutter apps.

HTML and CSS lets you use around 140 names colors. With this simple Flutter package, you can now access these colors also from your Flutter app.

Continuous Integration codecov kolors Published by dartside.dev GitHub Stars Count

Important links

Inspiration

This package is inspired by the material library's Colorsclass. I found that class to be very convenient for prototyping applications: no hex codes, just simple, intuitive named colors.

As a developer with many years of web background, I found that I often wanted to reach for the web (HTML and CSS) colors from my Flutter application.

Now, with this package, it's possible to find the right colors for quick prototyping.

Usage

import 'package:kolors/kolors.dart';

// Just type "Kolors." and pick a color that you like.
const appBarColor = Kolors.tomato;
const borderColor = Kolors.skyBlue;

// You can use the grouped classes if you know which color's shades
// you are interested in.
const appBarColor = KolorReds.lightSalmon;
const iconColor = KolorGreens.limeGreen;
const fabColor = KolorBlues.skyBlue;

// If you want to show the colors with their names to your users,
// use the "asMap" that contains the colors names and the colors.
final kolorsMap = Kolors.asMap();
final kolorEntries = m.kolorsMap.toList();

// Just the colors as List<Color>
const pinks = KolorPinks.values;

You can find the example app on GitHub and on pub.dev.

Flutter package kolors example app in action

Please keep in mind that this package has a dart:ui dependency (and therefore runs only with Flutter).

kolors's People

Contributors

vincevargadev avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.