Code Monkey home page Code Monkey logo

furtive's Introduction

Furtive

A forward-thinking, lightweight, CSS microframework. Minimal by design.

2.47kB gzipped.

Furtive is truly mobile-first and nearly all dimensions are done in rem. It also has a small footprint, cutting down on the bandwidth necessary for downloading CSS. Furtive is intended to be just that, furtive. It's the perfect starting point to get your project up and running.

Furtive remains lightweight because it doesn't preoccupy itself with older browsers. As a result, Furtive can use cutting edge tech like flexbox, SVGs, and limited vendor prefixing. It's also available in SCSS, CSS, Stylus, and comes with a gulpfile for customizing the build.

Installation

You can install via bower:

$ bower install --save furtive

Or, you can install via npm:

$ npm install --save furtive

Or, you can clone the source:

$ git clone https://github.com/johnotander/furtive.git

Using the SCSS

In your SCSS file, you can import furtive:

@import "/path/to/furtive/scss/all";

Or, if you like, you can just import a subset of the files, they're located in the scss directory.

Customizing the SCSS

Furtive contains a file scss/_variables.scss, which allows for variable customization:

$font-family: 'Lato', Helvetica, sans-serif;
$dark-gray: #222;
$text-color: $dark-gray;
$body-bg: #fafafa;

@import "/path/to/furtive/scss/all";

Using the CSS

Furtive provides two CSS files: furtive.css, and a minified version furtive.min.css. In order to use one, you can add a <link> in your <head>.

<!DOCTYPE html>
<html>
<head>
  <!-- ... -->
  <link rel="stylesheet" href="/path/to/furtive/css/furtive.min.css">
  <!-- ... -->
</head>
<body>
  <!-- ... -->
</body>
</html>

Using the Stylus

Similarly to the SCSS option, you can import stylus files as well, all stylus files are in the stylus directory.

Usage

Detailed documentation and examples can be found at furtive.co.

Keep Furtive as lightweight as possible

It's recommended to use Furtive with uncss, ensuring that only the CSS that is being used are included. An example of uncss in action with gulp:

gulp.task('uncss', function() {
  return gulp.src('css/furtive.min.css')
    .pipe(size({ gzip: true, showFiles: true }))
    .pipe(uncss({ html: ['index.html'] }))
    .pipe(rename('index.furtive.min.css'))
    .pipe(cssmin())
    .pipe(size({ gzip: true, showFiles: true }))
    .pipe(gulp.dest('./'));
});

The above example task is what's used by furtive.co. It allows that page to save about 30%, shrinking even further from 2.5kB to 1.8kB.

furtive [uncss●●] % gulp uncss
[12:23:43] Using gulpfile ~/code/frnt/furtive/gulpfile.js
[12:23:43] Starting 'uncss'...
[12:23:43] furtive.min.css 2.52 kB (gzipped)
[12:23:44] index.furtive.min.css 1.8 kB (gzipped)
[12:23:44] Finished 'uncss' after 970 ms

License

MIT

Contributing

  1. Fork it
  • Create your feature branch (git checkout -b my-new-feature)
  • Install the dependencies and run gulp (npm i && gulp)
  • Commit your changes (git commit -am 'Add some feature')
  • Push to the branch (git push origin my-new-feature)
  • Create new Pull Request

Thanks to the following:

Crafted with <3 by John Otander (@4lpine).

furtive's People

Contributors

asavartsov avatar capito-tar-gz avatar cybardev avatar johno avatar sindelg avatar tonybolanyo avatar wayann avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

furtive's Issues

Base font size is too small on mobile

Hello,

On mobile the base font size is 12px.
This is kind of small and can be hard to read on some devices. It is generally recommended to avoid having the main text smaller than 16 px.
Would it be possible to use a bigger font?

Use variable for Headline scaling.

The headlines are too big for my taste - but that's my taste only. It would be cool if I could specify the scale just like on http://type-scale.com/ using a variable and SASS would calculate the sizes according to that scale for me.

Would a pull request be welcome for that?

Grid on furtive.co uses -webkit-flex, github src does not. Safari seems to require it still

I don't see any other branches, is there a newer version of the code anywhere?

When you say "preoccupy itself with older browsers", is it possible to point out which browsers we are targeting?

Also the documentation doesn't mention .grd-col-1-6-sm (targeting for -sm, -md, -lg), which is quite handy. Though the source is so small that makes it easier to read through than any other css project I've used :)

Thanks for a great project...

input checkbox "state" unviewable on some devices

When viewing on a Galaxy Tab A/Firefox Browser, checkbox inputs are elongated and the visible "check/x" is never shown...

Screenshot attached from your site.

I traced it down to this code:

input[type="checkbox"]` {
  padding: .5rem;

I 've manually override it with this...

input[type="checkbox"] {
  padding: 0;
  margin: .5rem;
}

screenshot_20171208-132449

Responsive grid

Hey!

I may not understand the "rework-flex-grid" properly.

.gridClass {
  /* ... */
}

.gridClass-rowClass {
  /* ... */
}

.gridClass-rowClass-columnClass {
  /* ... */
}

@media screen and (min-width: 32rem) {
  .gridClass-rowClass-columnClass--sm {
    /* ... */
  }
}

In this example where do the digits indicating the number of columns go?

'bower error Invalid Version 2.2.' on install

Can't seem to get furtive to install furtive via 'bower install --save furtive' due to invalid version error.

bower furtive#*             not-cached git://github.com/johnotander/furtive.git#*
bower furtive#*                resolve git://github.com/johnotander/furtive.git#*
bower furtive#*               download https://github.com/johnotander/furtive/archive/2.2.2.tar.gz
bower furtive#*                extract archive.tar.gz
bower furtive#*                  error Invalid Version: 2.2.

Stack trace:
TypeError: Invalid Version: 2.2.
    at new SemVer (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\semver\semver.js:273:11)
    at compare (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\semver\semver.js:460:10)
    at Object.neq (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\semver\semver.js:504:10)
    at GitHubResolver.GitResolver._savePkgMeta (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\lib\core\resolvers\GitResolver.js:224:56)
    at GitHubResolver._savePkgMeta (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\lib\core\resolvers\GitHubResolver.js:134:53)
    at _fulfilled (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:834:54)
    at self.promiseDispatch.done (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:863:30)
    at Promise.promise.promiseDispatch (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:796:13)
    at C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:604:44
    at runSingle (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:137:13)

Console trace:
Error
    at StandardRenderer.error (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\lib\renderers\StandardRenderer.js:82:37)
    at Logger.<anonymous> (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\bin\bower:110:22)
    at Logger.emit (events.js:107:17)
    at Logger.emit (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\bower-logger\lib\Logger.js:29:39)
    at C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\lib\commands\index.js:45:20
    at _rejected (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:844:24)
    at C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:870:30
    at Promise.when (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:1122:31)
    at Promise.promise.promiseDispatch (C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:788:41)
    at C:\Users\xxx\AppData\Roaming\npm\node_modules\bower\node_modules\q\q.js:604:44
System info:
Bower version: 1.4.1
Node version: 0.12.6
OS: Windows_NT 6.1.7601 x64

Use viewport variables in grid media queries

There are two variables defined in _variables.scss for viewport size:

$viewport-m: 32rem !default;
$viewport-l: 48rem !default;

But values are harcoded on _grid.scss:

...
@media screen and (min-width: 32rem) {
...
@media screen and (min-width: 48rem) {
...
@media screen and (min-width: 64rem) {

Maybe a $viewport-xl variable is needed and it should be use in media queries.

Hint users to use Uncss

I think it would be great if you hint the users to use Uncss to remove anything they don't use in Furtive, to make it even lighter.

What do you think?

Add a red button style

Can we get support for a .btn--red class? I think it would go great with the other buttons available.

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.