Socket
Book a DemoInstallSign in
Socket

quarz

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

quarz

a simple javascript notification library

2.2.6
unpublished
latest
Source
npmnpm
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

quarz.js

Preview

This should give you an idea of how the package can be used.

import "quarz/lib/quarz.css";
import quarz from "quarz";

quarz.setup();

quarz.success("created user profile");

Medium Article

Article

Installation

npm install quarz

NPM Package

Demo

Web Demo

Importing

import "quarz/lib/quarz.css";
import quarz from "quarz";

Usage 🚀

Setup

You can either just call the method or pass some configuration adjustments to fit your needs.

quarz.setup();

quarz.setup({
  gravity: "bottom", // top or bottom
  position: 'left', // left or right
  x: 25, y: 25, // space from the side
  duration: 2000,
  delay: 100,
  mobile: {
    x: 20, y: 20,
    gravity: "top",
    position: "left"
  }
});
Notifications
quarz.success("created user profile");

quarz.error({
  title: "something went wrong",
  duration: 4000,
  delay: 200
});

quarz.warning({
  title: "your email had been changed",
  duration: 2000,
  delay: 50
});

quarz.info({
  title: "today is your cake day!",
  color: "#FFC6A5",
  duration: 5000,
  delay: 2000
});
Loading Indicators
// show a loading indicator
quarz.loading();
quarz.loading("#FFDEA5");
quarz.loading({ color: "#FFDEA5" });

// stop the loading indicator
quarz.stop();

Properties

Setup
PropertyDescriptionPossible or Example Values
gravitythe vertical position of the loading notifications/indicators"top", "bottom"
positionthe horizontal position of the loading notifications/indicators"left", "right"
xthe space between the left/right of the screen and the notifications/indicators25
ythe space between the top/bottom of the screen and the notifications/indicators25
Notifications
PropertyDescriptionPossible or Example Values
titlethe message displayed on the notification"string"
durationhow long the notification is supposed to be visible in milliseconds3000
delayhow long the script should wait before showing the notification in milliseconds200
colorthe color you want to override the original color (which is defined by the type) with"#FF99E3"
Loading Indicators
PropertyDescriptionPossible or Example Values
colorthe color you want to override the original color (which is defined by the type) with"#FF99E3"

License

MIT

Keywords

quarz

FAQs

Package last updated on 29 May 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.