Socket
Socket
Sign inDemoInstall

pnotify

Package Overview
Dependencies
19
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 5.0.0-alpha.5 to 5.0.0-alpha.6

CHANGELOG.md

65

package.json
{
"name": "pnotify",
"version": "5.0.0-alpha.5",
"version": "5.0.0-alpha.6",
"description": "Beautiful notifications and prompts.",

@@ -25,9 +25,10 @@ "keywords": [

"author": "Hunter Perrin",
"files": [
"dist",
"src"
],
"directories": {
"lib": "dist"
"scripts": {
"build-dev": "./package-sh.sh npm run build-dev",
"build": "./package-sh.sh npm run build",
"watch": "./package-sh.sh npm run watch",
"deploy": "git checkout gh-pages && git merge develop && rm -rf ./dist/ && npm run build && npm run build-dev && git add . && git commit -m 'Update built files.' && git push && git checkout develop",
"lint": "eslint index.html make.js src/*.html src/*.js demo/*"
},
"files": [],
"repository": {

@@ -37,21 +38,16 @@ "type": "git",

},
"scripts": {
"build-dev": "ENV=development npm run build-umd && npm run build-cleanup",
"build": "npm run build-umd && npm run build-es && npm run build-cleanup",
"build-umd": "webpack",
"build-es": "node make.js",
"build-cleanup": "node cleanup.js",
"watch": "ENV=development webpack --watch",
"deploy": "git checkout gh-pages && git merge develop && rm -rf ./dist/ && npm run build && npm run build-dev && git add . && git commit -m 'Update built files.' && git push && git checkout develop",
"prepublish": "rm -rf ./dist/ && npm run build",
"lint": "eslint index.html make.js src/*.html src/*.js demo/*"
"commitlint": {
"extends": [
"@commitlint/config-conventional"
]
},
"husky": {
"hooks": {
"commit-msg": "commitlint -e $HUSKY_GIT_PARAMS"
}
},
"devDependencies": {
"@babel/core": "^7.8.4",
"@babel/plugin-transform-classes": "^7.8.3",
"@babel/preset-env": "^7.8.4",
"@smui/common": "^1.0.0-beta.20",
"@commitlint/cli": "^8.3.5",
"@commitlint/config-conventional": "^8.3.4",
"babel-eslint": "^10.0.3",
"babel-loader": "^8.0.6",
"css-loader": "^3.4.2",
"eslint": "^6.8.0",

@@ -66,10 +62,19 @@ "eslint-config-semistandard": "^15.0.0",

"eslint-plugin-standard": "^4.0.1",
"mini-css-extract-plugin": "^0.9.0",
"style-loader": "^1.1.3",
"svelte": "^3.18.2",
"svelte-loader": "^2.13.6",
"webpack": "^4.41.6",
"webpack-cli": "^3.3.11"
"husky": "^4.2.3",
"lerna": "^3.18.3"
},
"dependencies": {}
"dependencies": {
"@pnotify/animate": "5.0.0-alpha.6",
"@pnotify/bootstrap3": "5.0.0-alpha.6",
"@pnotify/bootstrap4": "5.0.0-alpha.6",
"@pnotify/confirm": "5.0.0-alpha.6",
"@pnotify/core": "5.0.0-alpha.6",
"@pnotify/desktop": "5.0.0-alpha.6",
"@pnotify/font-awesome4": "5.0.0-alpha.6",
"@pnotify/font-awesome5": "5.0.0-alpha.6",
"@pnotify/font-awesome5-fix": "5.0.0-alpha.6",
"@pnotify/glyphicon": "5.0.0-alpha.6",
"@pnotify/mobile": "5.0.0-alpha.6",
"@pnotify/reference": "5.0.0-alpha.6"
}
}

@@ -52,23 +52,29 @@ [![npm version](https://badge.fury.io/js/pnotify.svg)](https://www.npmjs.com/package/pnotify) [![jsDelivr Hits](https://data.jsdelivr.com/v1/package/npm/pnotify/badge?style=rounded)](https://www.jsdelivr.com/package/npm/pnotify)

You can get PNotify using NPM. (You can also use [jsDelivr](https://www.jsdelivr.com/package/npm/pnotify) or [UNPKG](https://unpkg.com/pnotify/).)
You can get PNotify using NPM. (You can also use [jsDelivr](https://www.jsdelivr.com/package/npm/pnotify).)
You *should* install the packages you need individually. Alternatively, you can install all of them at once with the `pnotify` package.
```sh
npm install --save pnotify
# Install the packages you need individually.
# If you plan to use Material style:
npm install --save material-design-icons
# You definitely need this one.
npm install --save-dev @pnotify/core
# These are the optional ones.
npm install --save-dev @pnotify/animate
npm install --save-dev @pnotify/bootstrap3
npm install --save-dev @pnotify/bootstrap4
npm install --save-dev @pnotify/confirm
npm install --save-dev @pnotify/desktop
npm install --save-dev @pnotify/font-awesome4
npm install --save-dev @pnotify/font-awesome5
npm install --save-dev @pnotify/font-awesome5-fix
npm install --save-dev @pnotify/glyphicon
npm install --save-dev @pnotify/mobile
# If you plan to use the Animate module:
npm install --save animate.css
# ...
# If you plan to use NonBlock.js for non-blocking notices:
npm install --save nonblockjs
# Or, you can install this to get them all (if you're lazy).
npm install --save pnotify
```
Inside the pnotify package:
* `src` Svelte components and uncompressed CSS.
* `dist` compressed CSS and UMD modules.
* `dist/es` compressed ECMAScript modules.
## [Migrating from PNotify 4](MIGRATING.md)

@@ -82,7 +88,7 @@

[PNotify in Svelte](https://codesandbox.io/s/nwoxqkvw6m). (Use the source files.)
[PNotify in Svelte](https://codesandbox.io/s/nwoxqkvw6m).
```js
import { alert, defaultModules } from 'pnotify/src/PNotify.svelte';
import * as PNotifyMobile from 'pnotify/src/PNotifyMobile.svelte';
import { alert, defaultModules } from '@pnotify/core';
import * as PNotifyMobile from '@pnotify/mobile';

@@ -99,6 +105,6 @@ defaultModules.set(PNotifyMobile, {});

```js
import { alert, defaultModules } from 'pnotify/dist/PNotify.js';
import 'pnotify/dist/PNotify.css';
import * as PNotifyMobile from 'pnotify/dist/PNotifyMobile.js';
import 'pnotify/dist/PNotifyMobile.css';
import { alert, defaultModules } from '@pnotify/core';
import '@pnotify/core/dist/PNotify.css';
import * as PNotifyMobile from '@pnotify/mobile';
import '@pnotify/mobile/dist/PNotifyMobile.css';

@@ -115,6 +121,6 @@ defaultModules.set(PNotifyMobile, {});

```ts
import { alert, defaultModules } from 'pnotify/dist/PNotify.js';
import 'pnotify/dist/PNotify.css';
import * as PNotifyMobile from 'pnotify/dist/PNotifyMobile.js';
import 'pnotify/dist/PNotifyMobile.css';
import { alert, defaultModules } from '@pnotify/core';
import '@pnotify/core/dist/PNotify.css';
import * as PNotifyMobile from '@pnotify/mobile';
import '@pnotify/mobile/dist/PNotifyMobile.css';

@@ -140,6 +146,6 @@ defaultModules.set(PNotifyMobile, {});

import { Injectable } from '@angular/core';
import { alert, defaultModules } from 'pnotify/dist/PNotify.js';
import 'pnotify/dist/PNotify.css';
import * as PNotifyMobile from 'pnotify/dist/PNotifyMobile.js';
import 'pnotify/dist/PNotifyMobile.css';
import { alert, defaultModules } from '@pnotify/core';
import '@pnotify/core/dist/PNotify.css';
import * as PNotifyMobile from '@pnotify/mobile';
import '@pnotify/mobile/dist/PNotifyMobile.css';

@@ -183,9 +189,9 @@ defaultModules.set(PNotifyMobile, {});

```html
<link href="node_modules/pnotify/dist/PNotify.js" rel="stylesheet" type="text/css" />
<link href="node_modules/pnotify/dist/PNotifyMobile.js" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/core/dist/PNotify.css" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/mobile/dist/PNotifyMobile.css" rel="stylesheet" type="text/css" />
```
```js
var angular = require('angular');
var PNotify = require('pnotify/dist/PNotify.js');
var PNotifyMobile = require('pnotify/dist/PNotifyMobile.js');
var PNotify = require('@pnotify/core');
var PNotifyMobile = require('@pnotify/mobile');

@@ -206,6 +212,6 @@ PNotify.defaultModules.set(PNotifyMobile, {});

```html
<script type="text/javascript" src="node_modules/pnotify/dist/PNotify.js"></script>
<link href="node_modules/pnotify/dist/PNotify.js" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="node_modules/pnotify/dist/PNotifyMobile.js"></script>
<link href="node_modules/pnotify/dist/PNotifyMobile.js" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="node_modules/@pnotify/core/dist/PNotify.js"></script>
<link href="node_modules/@pnotify/core/dist/PNotify.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="node_modules/@pnotify/mobile/dist/PNotifyMobile.js"></script>
<link href="node_modules/@pnotify/mobile/dist/PNotifyMobile.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">

@@ -220,10 +226,10 @@ PNotify.defaultModules.set(PNotifyMobile, {});

PNotify in vanilla ECMAScript 6+. (Use the ES modules from `dist/es`.)
PNotify in vanilla ECMAScript 6+.
```html
<link href="node_modules/pnotify/dist/PNotify.js" rel="stylesheet" type="text/css" />
<link href="node_modules/pnotify/dist/PNotifyMobile.js" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/core/dist/PNotify.css" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/mobile/dist/PNotifyMobile.css" rel="stylesheet" type="text/css" />
<script type="module">
import { alert, defaultModules } from 'node_modules/pnotify/dist/es/PNotify.js';
import * as PNotifyMobile from 'node_modules/pnotify/dist/es/PNotifyMobile.js';
import { alert, defaultModules } from 'node_modules/@pnotify/core/dist/PNotify.js';
import * as PNotifyMobile from 'node_modules/@pnotify/mobile/dist/PNotifyMobile.js';

@@ -243,3 +249,3 @@ defaultModules.set(PNotifyMobile, {});

```html
<link href="node_modules/pnotify/dist/PNotifyBrightTheme.css" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/core/dist/BrightTheme.css" rel="stylesheet" type="text/css" />
```

@@ -250,3 +256,3 @@

```js
import 'pnotify/dist/PNotifyBrightTheme.css';
import '@pnotify/core/dist/BrightTheme.css';
```

@@ -259,3 +265,3 @@

```html
<link href="node_modules/pnotify/dist/PNotifyMaterial.css" rel="stylesheet" type="text/css" />
<link href="node_modules/@pnotify/core/dist/Material.css" rel="stylesheet" type="text/css" />
```

@@ -266,3 +272,3 @@

```js
import 'pnotify/dist/PNotifyMaterial.css';
import '@pnotify/core/dist/Material.css';
```

@@ -273,5 +279,5 @@

```js
import { defaults } from 'pnotify/dist/PNotify.js';
import { defaults } from '@pnotify/core';
// or
const { defaults } = require('pnotify/dist/PNotify.js');
const { defaults } = require('@pnotify/core');

@@ -326,3 +332,3 @@ // Set default styling.

```html
<link rel="stylesheet" href="node_modules/pnotify/dist/PNotifyBootstrap4.css" />
<link rel="stylesheet" href="node_modules/@pnotify/bootstrap4/dist/PNotifyBootstrap4.css" />
```

@@ -333,3 +339,3 @@

```js
import 'pnotify/dist/PNotifyBootstrap4.css';
import '@pnotify/bootstrap4/dist/PNotifyBootstrap4.css';
```

@@ -340,7 +346,7 @@

```js
import { defaultModules } from 'pnotify/dist/PNotify.js';
import * as PNotifyBootstrap4 from 'pnotify/dist/PNotifyBootstrap4.js';
import { defaultModules } from '@pnotify/core';
import * as PNotifyBootstrap4 from '@pnotify/bootstrap4';
// or
const { defaultModules } = require('pnotify/dist/PNotify.js');
const PNotifyBootstrap4 = require('pnotify/dist/PNotifyBootstrap4.js');
const { defaultModules } = require('@pnotify/core');
const PNotifyBootstrap4 = require('@pnotify/bootstrap4');
```

@@ -361,7 +367,7 @@

```js
import { defaultModules } from 'pnotify/dist/PNotify.js';
import * as PNotifyFontAwesome4 from 'pnotify/dist/PNotifyFontAwesome4.js';
import { defaultModules } from '@pnotify/core';
import * as PNotifyFontAwesome4 from '@pnotify/font-awesome4';
// or
const { defaultModules } = require('pnotify/dist/PNotify.js');
const PNotifyFontAwesome4 = require('pnotify/dist/PNotifyFontAwesome4.js');
const { defaultModules } = require('@pnotify/core');
const PNotifyFontAwesome4 = require('@pnotify/font-awesome4');
```

@@ -380,9 +386,9 @@

```js
import { defaultModules } from 'pnotify/dist/PNotify.js';
import * as PNotifyFontAwesome from 'pnotify/dist/PNotifyFontAwesome.js';
import * as PNotifyFontAwesome5 from 'pnotify/dist/PNotifyFontAwesome5.js';
import { defaultModules } from '@pnotify/core';
import * as PNotifyFontAwesome5Fix from '@pnotify/font-awesome5-fix';
import * as PNotifyFontAwesome5 from '@pnotify/font-awesome5';
// or
const { defaultModules } = require('pnotify/dist/PNotify.js');
const PNotifyFontAwesome = require('pnotify/dist/PNotifyFontAwesome.js');
const PNotifyFontAwesome5 = require('pnotify/dist/PNotifyFontAwesome5.js');
const { defaultModules } = require('@pnotify/core');
const PNotifyFontAwesome5Fix = require('@pnotify/font-awesome5-fix');
const PNotifyFontAwesome5 = require('@pnotify/font-awesome5');
```

@@ -393,7 +399,7 @@

```js
defaultModules.set(PNotifyFontAwesome, {});
defaultModules.set(PNotifyFontAwesome5Fix, {});
defaultModules.set(PNotifyFontAwesome5, {});
```
If you don't want to use Font Awesome 5 as your default icons, but you still want support for them in your notices, you should include only the `PNotifyFontAwesome` module. They do some mysterious magic in their code that breaks PNotify. This module has a workaround for it.
If you don't want to use Font Awesome 5 as your default icons, but you still want support for them in your notices, you should include only the `@pnotify/font-awesome5-fix` package. Font Awesome 5 does some mysterious magic in its code that breaks PNotify. This module has a workaround for it.

@@ -405,5 +411,5 @@ # Creating Notices

```js
import { alert, notice, info, success, error } from 'PNotify/dist/PNotify.js';
import { alert, notice, info, success, error } from '@pnotify/core';
// or
const { alert, notice, info, success, error } = require('pnotify/dist/PNotify.js');
const { alert, notice, info, success, error } = require('@pnotify/core');

@@ -526,5 +532,5 @@ // Manually set the type.

```js
import { defaults } from 'PNotify/dist/PNotify.js';
import { defaults } from '@pnotify/core';
// or
const { defaults } = require('pnotify/dist/PNotify.js');
const { defaults } = require('@pnotify/core');

@@ -537,7 +543,7 @@ defaults.width = '400px';

```js
import { defaultModules } from 'PNotify/dist/PNotify.js';
import * as PNotifyMobile from 'PNotify/dist/PNotifyMobile.js';
import { defaultModules } from '@pnotify/core';
import * as PNotifyMobile from '@pnotify/mobile';
// or
const { defaultModules } = require('pnotify/dist/PNotify.js');
const PNotifyMobile = require('pnotify/dist/PNotifyMobile.js');
const { defaultModules } = require('@pnotify/core');
const PNotifyMobile = require('@pnotify/mobile');

@@ -555,5 +561,5 @@ // Add a module to the defaults. Note that the second argument should

```js
import { defaults } from 'PNotify/dist/PNotifyAnimate.js';
import { defaults } from '@pnotify/animate';
// or
const { defaults } = require('pnotify/dist/PNotifyAnimate.js');
const { defaults } = require('@pnotify/animate');

@@ -572,7 +578,7 @@ // then

```js
import { notice, defaultModules } from 'PNotify/dist/PNotify.js';
import * as PNotifyBootstrap4 from 'PNotify/dist/PNotifyBootstrap4.js';
import * as PNotifyFontAwesome4 from 'PNotify/dist/PNotifyFontAwesome4.js';
import * as PNotifyMobile from 'PNotify/dist/PNotifyMobile.js';
import * as PNotifyAnimate from 'PNotify/dist/PNotifyAnimate.js';
import { notice, defaultModules } from '@pnotify/core';
import * as PNotifyBootstrap4 from '@pnotify/bootstrap4';
import * as PNotifyFontAwesome4 from '@pnotify/font-awesome4';
import * as PNotifyMobile from '@pnotify/mobile';
import * as PNotifyAnimate from '@pnotify/animate';

@@ -715,3 +721,3 @@ defaultModules.set(PNotifyBootstrap4, {});

```js
import { alert } from 'PNotify/dist/es/PNotify.js';
import { alert } from '@pnotify/core';
const notice = alert({

@@ -758,5 +764,5 @@ title: 'Confirmation Needed',

* `notice.open()`<br>
* `notice.open(immediate)`<br>
Open the notice.
* `notice.close()`<br>
* `notice.close(immediate, timerHide, waitAfterward)`<br>
Close the notice.

@@ -822,3 +828,3 @@ * `notice.update(options)`<br>

```js
import {alert, Stack} from 'pnotify/dist/PNotify.js';
import {alert, Stack} from '@pnotify/core';

@@ -888,5 +894,5 @@ const myStack = new Stack({

Queue a position call in that many milliseconds, unless another one is queued beforehand.
* `close()`<br>
* `close(immediate)`<br>
Close all the notices in the stack.
* `open()`<br>
* `open(immediate)`<br>
Open all the notices in the stack.

@@ -893,0 +899,0 @@ * `openLast()`<br>

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc