0.0.8 • Published 4 years ago

@osynlig/os-placeloader v0.0.8

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

Osynlig Placeloader

A small collection of customizable SVG components to create placeholder loading indicators instead of spinner, like cards loading.

Install

npm i @osynlig/os-placeloader --save

How to use

import  {  PlaceloaderModule  }  from  '@osynlig/os-placeloader';

@NgModule({
	imports: [
		PlaceloaderModule
	]
});
  <os-placeloader speed="2200" primaryColor="rgb(220, 221, 222)" height="74" width="399">
    <svg:g code></svg:g>
  </os-placeloader>

  <os-placeloader speed="2200" primaryColor="#dcddde" height="157" width="399">
    <svg:g facebook></svg:g>
  </os-placeloader>

  <os-placeloader speed="2200" primaryColor="#dcddde" height="120" width="399">
    <svg:g content></svg:g>
  </os-placeloader>

  <os-placeloader speed="2200" primaryColor="#dcddde" height="124" width="399">
    <svg:g list></svg:g>
  </os-placeloader>

Presets (at the moment...)

  • content
  • facebook
  • list
  • code

Properties

speednumber1200animation speed
primaryColorstring#dcdddeplaceloader color can be in rgb(), rgba(), hsl(), hsla() or #hex
widthnumber320width of the placeloader
heightnumber100height of the placeloader

Development

Fork the repo then clone it $ git clone git@github.com:osynligab/placeloader.git

cd into the folder

Install the dependencies $ yarn or npm i

Run the demo app $ npm start

TODO

  • Build demo page