0.1.1 • Published 5 years ago

bubble-bg v0.1.1

Weekly downloads
3
License
GPL-3.0
Repository
github
Last release
5 years ago

Bubble BG

NPM version NPM downloads

About

Bubble BG is a web component based on bubbly-bg library. It allows add background with animated bubbles to your site.

How to Install

First, install the library in your project by npm:

$ npm install bubble-bg

Or Yarn:

$ yarn add bubble-bg

Getting Started

Connect libary with project using script tag in HTML:

<script type="module" src="/path/to/bubble-bg.js"></script>

ES6 import:

import 'bubble-bg';

Props

NameTypeDefaultDescriptionAvailable options
animateBubblesbooleantrueEnable or disable bubbles animationtrue - enable, false - disable
shadowBlurnumber4Canvas shadowBlur valuee.g: 1
bubblesCountnumber20Number of bubblese.g: 63
colorsstring[]["#2ae", "#17b"]Background gradient stops colorse.g: ["#4287f5", "#4248f5" ,"#f542a7"]
composestringlighterCanvas compose valuelighter or
shadowColorstring#fffe.g: rgb(), #f0f0f0
gradientAnglenumber45Background gradient angle directionvalues between 0 and 360

Example

With default props:

<body>
  <bubble-bg></bubble-bg>
</body>

With custom props:

<body>
  <bubble-bg
    shadowColor="#fefefe"
    bubblesCount="34"
  ></bubble-bg>
</body>

License

This project is licensed under the GPL 3.0 License © 2019-present Jakub Biesiada

0.1.1

5 years ago

0.1.0

5 years ago