GithubHelp home page GithubHelp logo

doc22940 / css-spinner Goto Github PK

View Code? Open in Web Editor NEW

This project forked from loadingio/css-spinner

1.0 0.0 0.0 1.01 MB

small, elegant pure css spinner for ajax or loading animation

Home Page: https://loading.io/css/

HTML 19.02% CSS 38.05% JavaScript 42.93%

css-spinner's Introduction

CSS-Spinner

Live Demo

collection of 12 small, elegant pure css spinners for your website loading animation.

css spinner

Features

  • vanilla - no external dependency and no additional library required.
  • standalone - use any of them separately.
  • customizable - use Stylus variables to quickly customize them to fit your need.
  • easy to use - simple as copy and paste while also simple to use with pug mixins.
  • small - average size 1K per spinner unminimized, unzipped

Usage

loading.io provides a web interface to quickly choose and copy your desired spinners, yet you can still find the source code in this repository. The simplest usage is as:

  1. Find and download the html file of desired loader under build/ folder.
  2. Copy its content to the place you want to use this loader.
  3. Done.

Separated CSS and HTML files are also available under build folder so that you can reuse the css to reduce payload size.

We also provide stylus and pug source files for better integrating these spinners into your project. Find corresponding stylus and pug files for your desired spinners under src/ folders.

Additionally, you will need vars.styl and basic.styl if you are going to build by yourself. See following section for more detail.

Customization

To customize speed and color of a loader, first ensure you have stylus install locally ( you will need npm too ):

npm install -g stylus

then, edit vars.styl with your desired configuration. for now you can edit the following style of a spinner:

  • size
  • color
  • speed

once you've done with the editing, run stylus to build yourself a css file:

stylus -o . --import vars.styl --import basic.styl src/<desired-loader>/main.styl

use the generated main.css together with build//main.html to add this loader in your project.

Browser Compatibility

These spinners use CSS Animation and Transformation which is widely supported by major modern browsers except IE<=9. To support older browsers like IE9, please use loading.io to generate alternative GIF Loaders instead.

License

All loader files here are released under CC0 License. However, you could attribute to this link: loading.io css spinner ( https://loading.io/css/ ) to give loading.io a thumbs-up.

Other Resources

If you want to make custom css loading animation, loading.io also provides loading.css - A pure CSS loading animation library, and a helper GIF builder. Don't forget to check it out and share your customized loader with us!

css-spinner's People

Contributors

stephencweiss avatar zbryikt 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.