From 1e1ae7bf11bd4e36c566d9514308c83409691a10 Mon Sep 17 00:00:00 2001 From: pooya parsa Date: Sat, 8 Jun 2019 13:43:57 +0430 Subject: [PATCH] refactor: refactor to single package --- .circleci/config.yml | 2 +- .eslintignore | 2 +- README.md | 4 +- jest.config.js | 11 + lerna.json | 15 -- packages/icon/index.js => lib/icon/module.js | 15 +- {packages => lib}/icon/plugin.js | 0 {packages => lib}/icon/resize.js | 0 .../index.js => lib/manifest/module.js | 13 +- packages/meta/index.js => lib/meta/module.js | 12 +- lib/module.js | 13 + .../index.js => lib/onesignal/module.js | 14 +- .../templates => lib/onesignal}/plugin.js | 0 {packages/pwa-utils => lib/utils}/index.js | 0 .../workbox/lib => lib/workbox}/defaults.js | 0 .../workbox/lib => lib/workbox}/module.js | 8 +- .../workbox/lib => lib/workbox}/options.js | 9 +- .../workbox/templates/sw.disable.js | 0 {packages => lib}/workbox/templates/sw.js | 0 .../workbox/templates/workbox.js | 0 .../workbox/lib => lib/workbox}/utils.js | 0 package.json | 42 ++-- packages/icon/CHANGELOG.md | 174 ------------- packages/icon/README.md | 1 - packages/icon/package.json | 18 -- packages/manifest/CHANGELOG.md | 159 ------------ packages/manifest/README.md | 1 - packages/manifest/package.json | 14 -- packages/meta/CHANGELOG.md | 155 ------------ packages/meta/README.md | 1 - packages/meta/package.json | 13 - packages/onesignal/CHANGELOG.md | 164 ------------ packages/onesignal/README.md | 1 - packages/onesignal/dist/OneSignalSDK.js | 2 - packages/onesignal/package.json | 13 - packages/pwa-utils/CHANGELOG.md | 129 ---------- packages/pwa-utils/README.md | 1 - packages/pwa-utils/package.json | 10 - packages/pwa/CHANGELOG.md | 137 ---------- packages/pwa/README.md | 1 - packages/pwa/index.js | 14 -- packages/pwa/package.json | 17 -- packages/workbox/CHANGELOG.md | 236 ------------------ packages/workbox/README.md | 1 - packages/workbox/package.json | 14 -- test/__snapshots__/pwa.test.js.snap | 2 +- test/fixture/nuxt.config.js | 3 +- test/pwa.test.js | 26 +- yarn.lock | 193 +++++++------- 49 files changed, 199 insertions(+), 1461 deletions(-) create mode 100644 jest.config.js delete mode 100644 lerna.json rename packages/icon/index.js => lib/icon/module.js (91%) rename {packages => lib}/icon/plugin.js (100%) rename {packages => lib}/icon/resize.js (100%) rename packages/manifest/index.js => lib/manifest/module.js (85%) rename packages/meta/index.js => lib/meta/module.js (96%) create mode 100755 lib/module.js rename packages/onesignal/index.js => lib/onesignal/module.js (88%) rename {packages/onesignal/templates => lib/onesignal}/plugin.js (100%) rename {packages/pwa-utils => lib/utils}/index.js (100%) rename {packages/workbox/lib => lib/workbox}/defaults.js (100%) rename {packages/workbox/lib => lib/workbox}/module.js (81%) rename {packages/workbox/lib => lib/workbox}/options.js (89%) rename {packages => lib}/workbox/templates/sw.disable.js (100%) rename {packages => lib}/workbox/templates/sw.js (100%) rename {packages => lib}/workbox/templates/workbox.js (100%) rename {packages/workbox/lib => lib/workbox}/utils.js (100%) delete mode 100644 packages/icon/CHANGELOG.md delete mode 100644 packages/icon/README.md delete mode 100644 packages/icon/package.json delete mode 100644 packages/manifest/CHANGELOG.md delete mode 100644 packages/manifest/README.md delete mode 100755 packages/manifest/package.json delete mode 100644 packages/meta/CHANGELOG.md delete mode 100644 packages/meta/README.md delete mode 100755 packages/meta/package.json delete mode 100644 packages/onesignal/CHANGELOG.md delete mode 100644 packages/onesignal/README.md delete mode 100644 packages/onesignal/dist/OneSignalSDK.js delete mode 100755 packages/onesignal/package.json delete mode 100644 packages/pwa-utils/CHANGELOG.md delete mode 100644 packages/pwa-utils/README.md delete mode 100755 packages/pwa-utils/package.json delete mode 100644 packages/pwa/CHANGELOG.md delete mode 100644 packages/pwa/README.md delete mode 100755 packages/pwa/index.js delete mode 100755 packages/pwa/package.json delete mode 100644 packages/workbox/CHANGELOG.md delete mode 100644 packages/workbox/README.md delete mode 100644 packages/workbox/package.json diff --git a/.circleci/config.yml b/.circleci/config.yml index 3bb5f85c..08ce8108 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -26,4 +26,4 @@ jobs: # Test - run: name: Tests - command: yarn test && yarn codecov + command: yarn test --coverage && yarn codecov diff --git a/.eslintignore b/.eslintignore index 7684515c..aaf8becc 100644 --- a/.eslintignore +++ b/.eslintignore @@ -3,4 +3,4 @@ **/dist # Contains Lodash templates -packages/icon/plugin.js +**/plugin.js diff --git a/README.md b/README.md index 0bb29318..6a54ffee 100644 --- a/README.md +++ b/README.md @@ -11,10 +11,10 @@ > Progressive Web Apps (PWA) are reliable, fast, and engaging, although there are many things that can take a PWA from a baseline to exemplary experience. ([learn more](https://developers.google.com/web/progressive-web-apps)) -Using Nuxt PWA you can supercharge your current or next Nuxt project with a heavily tested, updated and stable PWA solution and zero-config! +Supercharge Nuxt with a heavily tested, updated, zero-config and stable PWA solution! ๐Ÿ“– [**Read Documentation**](https://pwa.nuxtjs.org) ## License -MIT - Nuxt Community - Pooya Parsa \ No newline at end of file +MIT - Nuxt Community - Pooya Parsa diff --git a/jest.config.js b/jest.config.js new file mode 100644 index 00000000..acd36cc7 --- /dev/null +++ b/jest.config.js @@ -0,0 +1,11 @@ +module.exports = { + testEnvironment: 'node', + collectCoverageFrom: [ + 'lib/**/*.js', + '!lib/**/plugin.js', + '!lib/**/templates/*.js' + ], + transform: { + '^.+\\.js$': 'babel-jest' + } +} diff --git a/lerna.json b/lerna.json deleted file mode 100644 index 464a820f..00000000 --- a/lerna.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "version": "3.0.0-beta.16", - "useWorkspaces": true, - "npmClient": "yarn", - "conventionalCommits": true, - "exact": true, - "packages": [ - "packages/*" - ], - "command": { - "publish": { - "npmClient": "npm" - } - } -} diff --git a/packages/icon/index.js b/lib/icon/module.js similarity index 91% rename from packages/icon/index.js rename to lib/icon/module.js index 7f6972e9..8cf62e41 100755 --- a/packages/icon/index.js +++ b/lib/icon/module.js @@ -2,17 +2,17 @@ const fs = require('fs-extra') const path = require('path') const hasha = require('hasha') const { fork } = require('child_process') -const { joinUrl, getRouteParams } = require('@nuxtjs/pwa-utils') +const { joinUrl, getRouteParams } = require('../utils') -module.exports = function (options) { - this.nuxt.hook('build:before', () => run.call(this, options, true)) +module.exports = function (iconOptions) { + this.nuxt.hook('build:before', () => run.call(this, iconOptions, true)) if (this.options.mode === 'spa' && !this.options.dev) { - return run.call(this, options, false) // Fill meta + return run.call(this, iconOptions, false) // Fill meta } } -async function run (moduleOptions, _emitAssets) { +async function run (iconOptions, _emitAssets) { const { publicPath } = getRouteParams(this.options) // Defaults @@ -34,8 +34,7 @@ async function run (moduleOptions, _emitAssets) { // Merge options const options = { ...defaults, - ...this.options.icon, - ...moduleOptions + ...iconOptions } // Find iconSrc @@ -174,5 +173,3 @@ async function resizeIcons (options) { }) }) } - -module.exports.meta = require('./package.json') diff --git a/packages/icon/plugin.js b/lib/icon/plugin.js similarity index 100% rename from packages/icon/plugin.js rename to lib/icon/plugin.js diff --git a/packages/icon/resize.js b/lib/icon/resize.js similarity index 100% rename from packages/icon/resize.js rename to lib/icon/resize.js diff --git a/packages/manifest/index.js b/lib/manifest/module.js similarity index 85% rename from packages/manifest/index.js rename to lib/manifest/module.js index 1177b63e..d1b56125 100755 --- a/packages/manifest/index.js +++ b/lib/manifest/module.js @@ -1,10 +1,10 @@ const hash = require('hash-sum') -const { joinUrl, getRouteParams, find } = require('@nuxtjs/pwa-utils') +const { joinUrl, getRouteParams, find } = require('../utils') -module.exports = function nuxtManifest (options) { +module.exports = function nuxtManifest (manifestOptions) { const hook = () => { - addManifest.call(this, options) + addManifest.call(this, manifestOptions) } if (this.options.mode === 'spa') { @@ -14,7 +14,7 @@ module.exports = function nuxtManifest (options) { this.nuxt.hook('build:before', hook) } -function addManifest (_options) { +function addManifest (manifestOptions) { const { routerBase, publicPath } = getRouteParams(this.options) // Combine sources @@ -30,7 +30,8 @@ function addManifest (_options) { theme_color: this.options.loading && this.options.loading.color, lang: 'en' } - const options = { ...defaults, ...this.options.manifest, ..._options } + + const options = { ...defaults, ...manifestOptions } // Remve extra fields from manifest const manifest = { ...options } @@ -68,5 +69,3 @@ function addManifest (_options) { console.warn('Manifest meta already provided!') } } - -module.exports.meta = require('./package.json') diff --git a/packages/meta/index.js b/lib/meta/module.js similarity index 96% rename from packages/meta/index.js rename to lib/meta/module.js index b6940d7d..2c6e5bde 100755 --- a/packages/meta/index.js +++ b/lib/meta/module.js @@ -1,8 +1,8 @@ -const { find, isUrl } = require('@nuxtjs/pwa-utils') +const { find, isUrl } = require('../utils') -module.exports = function nuxtMeta (_options) { +module.exports = function nuxtMeta (metaOptions) { const hook = () => { - generateMeta.call(this, _options) + generateMeta.call(this, metaOptions) } if (this.options.mode === 'spa') { @@ -12,7 +12,7 @@ module.exports = function nuxtMeta (_options) { this.nuxt.hook('build:before', hook) } -function generateMeta (_options) { +function generateMeta (metaOptions) { // Defaults const defaults = { name: process.env.npm_package_name, @@ -40,7 +40,7 @@ function generateMeta (_options) { } // Combine sources - const options = Object.assign({}, defaults, this.options.manifest, this.options.meta, _options) + const options = { ...defaults, ...this.options.manifest, ...metaOptions } // Default value for viewport if (options.viewport === undefined) { @@ -226,5 +226,3 @@ function generateMeta (_options) { this.options.head.meta.push({ hid: 'twitter:creator', name: 'twitter:creator', property: 'twitter:creator', content: options.twitterCreator }) } } - -module.exports.meta = require('./package.json') diff --git a/lib/module.js b/lib/module.js new file mode 100755 index 00000000..e11ba240 --- /dev/null +++ b/lib/module.js @@ -0,0 +1,13 @@ +module.exports = async function nuxtPWA (options) { + const modules = ['icon', 'manifest', 'meta', 'workbox'] + for (const name of modules) { + if (options[name] === false || this.options[name] === false) { + continue + } + const moduleFn = require(`./${name}/module.js`) + const moduleOptions = { ...this.options[name], ...options[name] } + await moduleFn.call(this, moduleOptions) + } +} + +module.exports.meta = require('../package.json') diff --git a/packages/onesignal/index.js b/lib/onesignal/module.js similarity index 88% rename from packages/onesignal/index.js rename to lib/onesignal/module.js index 69b39117..b5ae7aa2 100755 --- a/packages/onesignal/index.js +++ b/lib/onesignal/module.js @@ -1,16 +1,16 @@ const path = require('path') const { writeFileSync, readFileSync } = require('fs') const hashSum = require('hash-sum') -const { defaultsDeep } = require('lodash') -const { getRouteParams, joinUrl } = require('@nuxtjs/pwa-utils') +const defu = require('defu') +const { getRouteParams, joinUrl } = require('../utils') // ============================================= // oneSignal Module // ============================================= -module.exports = function nuxtOneSignal (moduleOptions) { +module.exports = function nuxtOneSignal (oneSignalOptions) { const hook = () => { - addOneSignal.call(this, moduleOptions) + addOneSignal.call(this, oneSignalOptions) } if (this.options.mode === 'spa') { @@ -24,7 +24,7 @@ module.exports = function nuxtOneSignal (moduleOptions) { // addOneSignal // ============================================= -function addOneSignal (moduleOptions) { +function addOneSignal (oneSignalOptions) { const { publicPath } = getRouteParams(this.options) // Merge options @@ -43,7 +43,7 @@ function addOneSignal (moduleOptions) { } } - const options = defaultsDeep({}, this.options.oneSignal, moduleOptions, defaults) + const options = defu(oneSignalOptions, defaults) if (options.OneSignalSDK === undefined) { if (options.cdn) { @@ -108,5 +108,3 @@ function addOneSignal (moduleOptions) { options }) } - -module.exports.meta = require('./package.json') diff --git a/packages/onesignal/templates/plugin.js b/lib/onesignal/plugin.js similarity index 100% rename from packages/onesignal/templates/plugin.js rename to lib/onesignal/plugin.js diff --git a/packages/pwa-utils/index.js b/lib/utils/index.js similarity index 100% rename from packages/pwa-utils/index.js rename to lib/utils/index.js diff --git a/packages/workbox/lib/defaults.js b/lib/workbox/defaults.js similarity index 100% rename from packages/workbox/lib/defaults.js rename to lib/workbox/defaults.js diff --git a/packages/workbox/lib/module.js b/lib/workbox/module.js similarity index 81% rename from packages/workbox/lib/module.js rename to lib/workbox/module.js index e108eca3..4d45126e 100755 --- a/packages/workbox/lib/module.js +++ b/lib/workbox/module.js @@ -3,10 +3,10 @@ const path = require('path') const { getOptions } = require('./options') const { readJSFiles } = require('./utils') -module.exports = function nuxtWorkbox (moduleOptions) { +module.exports = function nuxtWorkbox (workboxOptions) { this.nuxt.hook('build:before', () => { // Get options - const options = getOptions.call(this, moduleOptions) + const options = getOptions.call(this, workboxOptions) // Warning for dev option if (options.dev) { @@ -16,7 +16,7 @@ module.exports = function nuxtWorkbox (moduleOptions) { // Register plugin if (options.autoRegister) { this.addPlugin({ - src: path.resolve(__dirname, '../templates/workbox.js'), + src: path.resolve(__dirname, 'templates/workbox.js'), ssr: false, fileName: 'workbox.js', options: { @@ -40,5 +40,3 @@ module.exports = function nuxtWorkbox (moduleOptions) { } }) } - -module.exports.meta = require('../package.json') diff --git a/packages/workbox/lib/options.js b/lib/workbox/options.js similarity index 89% rename from packages/workbox/lib/options.js rename to lib/workbox/options.js index 344323ee..d2918c4c 100644 --- a/packages/workbox/lib/options.js +++ b/lib/workbox/options.js @@ -1,10 +1,9 @@ const path = require('path') - const defaults = require('./defaults') -const { joinUrl, getRouteParams, startCase } = require('@nuxtjs/pwa-utils') +const { joinUrl, getRouteParams, startCase } = require('../utils') -function getOptions (moduleOptions) { - const options = Object.assign({}, defaults, moduleOptions, this.options.workbox) +function getOptions (workboxOptions) { + const options = { ...defaults, ...workboxOptions } // routerBase if (!options.routerBase) { @@ -20,7 +19,7 @@ function getOptions (moduleOptions) { // swTemplate if (!options.swTemplate) { const disabled = this.options.dev && !options.dev - options.swTemplate = path.resolve(__dirname, `../templates/sw${disabled ? '.disable' : ''}.js`) + options.swTemplate = path.resolve(__dirname, `templates/sw${disabled ? '.disable' : ''}.js`) } // swDest diff --git a/packages/workbox/templates/sw.disable.js b/lib/workbox/templates/sw.disable.js similarity index 100% rename from packages/workbox/templates/sw.disable.js rename to lib/workbox/templates/sw.disable.js diff --git a/packages/workbox/templates/sw.js b/lib/workbox/templates/sw.js similarity index 100% rename from packages/workbox/templates/sw.js rename to lib/workbox/templates/sw.js diff --git a/packages/workbox/templates/workbox.js b/lib/workbox/templates/workbox.js similarity index 100% rename from packages/workbox/templates/workbox.js rename to lib/workbox/templates/workbox.js diff --git a/packages/workbox/lib/utils.js b/lib/workbox/utils.js similarity index 100% rename from packages/workbox/lib/utils.js rename to lib/workbox/utils.js diff --git a/package.json b/package.json index f6b8e4fb..86f2c8ea 100644 --- a/package.json +++ b/package.json @@ -1,30 +1,26 @@ { - "version": "0.0.0", - "private": true, - "contributors": [ - "Pooya Parsa ", - "Alexander Lichter ", - "Jonas Galvez " + "name": "@nuxtjs/pwa", + "version": "3.0.0-beta.16", + "description": "Supercharge Nuxt with a heavily tested, updated, zero-config and stable PWA solution!", + "repository": "nuxt-community/pwa-module", + "files": [ + "lib" ], + "main": "lib/module.js", "scripts": { - "test": "yarn lint && jest", - "lint": "eslint --ext .js packages", - "release": "lerna publish --conventional-commits" + "lint": "eslint --ext .js lib", + "release": "yarn test && standard-version && git push --follow-tags && npm publish", + "generate": "yarn nuxt generate test/fixture", + "test": "yarn lint && yarn generate && jest" }, - "repository": { - "type": "git", - "url": "https://github.com/nuxt-community/pwa-module.git" - }, - "workspaces": [ - "packages/*" - ], - "publishConfig": { - "access": "public" - }, - "jest": { - "testEnvironment": "node", - "coverageDirectory": "./coverage/", - "collectCoverage": true + "dependencies": { + "defu": "^0.0.3", + "execa": "^1.0.0", + "fs-extra": "^8.0.1", + "hash-sum": "^1.0.2", + "hasha": "^5.0.0", + "jimp": "^0.6.4", + "workbox-cdn": "^4.3.1" }, "devDependencies": { "axios": "^0.18.0", diff --git a/packages/icon/CHANGELOG.md b/packages/icon/CHANGELOG.md deleted file mode 100644 index d1db42f7..00000000 --- a/packages/icon/CHANGELOG.md +++ /dev/null @@ -1,174 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -# [3.0.0-beta.16](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.15...v3.0.0-beta.16) (2019-05-07) - - -### Bug Fixes - -* **icon:** handle situation where the iconSrc is `null` or `undefined` ([#187](https://github.com/nuxt-community/pwa-module/issues/187)) ([66be874](https://github.com/nuxt-community/pwa-module/commit/66be874)) - - - - - -# [3.0.0-beta.15](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.14...v3.0.0-beta.15) (2019-05-07) - - -### Bug Fixes - -* **icon:** handle jimp.write callback ([bffe6ed](https://github.com/nuxt-community/pwa-module/commit/bffe6ed)) - - -### Features - -* rewrite icon with async image resizer ([#171](https://github.com/nuxt-community/pwa-module/issues/171)) ([a4a457e](https://github.com/nuxt-community/pwa-module/commit/a4a457e)) - - - - - -# [3.0.0-beta.14](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.13...v3.0.0-beta.14) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.13](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.12...v3.0.0-beta.13) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.12](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.11...v3.0.0-beta.12) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.11](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.10...v3.0.0-beta.11) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.10](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.9...v3.0.0-beta.10) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.9](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.8...v3.0.0-beta.9) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.8](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.7...v3.0.0-beta.8) (2019-02-18) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.7](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.6...v3.0.0-beta.7) (2019-02-17) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.6](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.5](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.3...v3.0.0-beta.5) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.3](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.2](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/icon - - - - - -# [3.0.0-beta.1](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.0...v3.0.0-beta.1) (2019-02-07) - - -### Features - -* **icon:** allow reading icon from assetc/icon.png ([#29](https://github.com/nuxt-community/pwa-module/issues/29)) ([9e0fde3](https://github.com/nuxt-community/pwa-module/commit/9e0fde3)) - - - - - -# [3.0.0-beta.0](https://github.com/nuxt-community/pwa-module/compare/v2.6.0...v3.0.0-beta.0) (2019-02-04) - - -### chore - -* only support nuxt.hook ([854d826](https://github.com/nuxt-community/pwa-module/commit/854d826)) - - -### Code Refactoring - -* use tapable hooks ([#103](https://github.com/nuxt-community/pwa-module/issues/103)) ([9f27d5c](https://github.com/nuxt-community/pwa-module/commit/9f27d5c)) - - -### Features - -* remove debug ([92ba73e](https://github.com/nuxt-community/pwa-module/commit/92ba73e)) -* **icon:** new options ([#126](https://github.com/nuxt-community/pwa-module/issues/126)) ([12e6576](https://github.com/nuxt-community/pwa-module/commit/12e6576)) - - -### BREAKING CHANGES - -* needs nuxt 2.x or later -* webpack >= 4 (Nuxt >= 2) is required - - - - - - -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - - -### Features - -* **icon:** update to jimp 0.5.0 ([b071c4b](https://github.com/nuxt-community/pwa-module/commit/b071c4b)) diff --git a/packages/icon/README.md b/packages/icon/README.md deleted file mode 100644 index 98b5ce26..00000000 --- a/packages/icon/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. \ No newline at end of file diff --git a/packages/icon/package.json b/packages/icon/package.json deleted file mode 100644 index eca4550c..00000000 --- a/packages/icon/package.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "name": "@nuxtjs/icon", - "version": "3.0.0-beta.16", - "license": "MIT", - "main": "index.js", - "repository": "https://github.com/nuxt-community/pwa-module", - "publishConfig": { - "access": "public" - }, - "dependencies": { - "@nuxtjs/pwa-utils": "3.0.0-beta.16", - "execa": "^1.0.0", - "fs-extra": "^8.0.1", - "hash-sum": "^1.0.2", - "hasha": "^5.0.0", - "jimp": "^0.6.4" - } -} diff --git a/packages/manifest/CHANGELOG.md b/packages/manifest/CHANGELOG.md deleted file mode 100644 index 4a39823e..00000000 --- a/packages/manifest/CHANGELOG.md +++ /dev/null @@ -1,159 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -# [3.0.0-beta.16](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.15...v3.0.0-beta.16) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.15](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.14...v3.0.0-beta.15) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.14](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.13...v3.0.0-beta.14) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.13](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.12...v3.0.0-beta.13) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.12](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.11...v3.0.0-beta.12) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.11](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.10...v3.0.0-beta.11) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.10](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.9...v3.0.0-beta.10) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.9](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.8...v3.0.0-beta.9) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.8](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.7...v3.0.0-beta.8) (2019-02-18) - - -### Bug Fixes - -* **manifest:** remove publicPath field ([b03dc14](https://github.com/nuxt-community/pwa-module/commit/b03dc14)) - - - - - -# [3.0.0-beta.7](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.6...v3.0.0-beta.7) (2019-02-17) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.6](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.5](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.3...v3.0.0-beta.5) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.3](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.2](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.1](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.0...v3.0.0-beta.1) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/manifest - - - - - -# [3.0.0-beta.0](https://github.com/nuxt-community/pwa-module/compare/v2.6.0...v3.0.0-beta.0) (2019-02-04) - - -### chore - -* only support nuxt.hook ([854d826](https://github.com/nuxt-community/pwa-module/commit/854d826)) - - -### Code Refactoring - -* use tapable hooks ([#103](https://github.com/nuxt-community/pwa-module/issues/103)) ([9f27d5c](https://github.com/nuxt-community/pwa-module/commit/9f27d5c)) - - -### Features - -* remove debug ([92ba73e](https://github.com/nuxt-community/pwa-module/commit/92ba73e)) - - -### BREAKING CHANGES - -* needs nuxt 2.x or later -* webpack >= 4 (Nuxt >= 2) is required - - - - - - -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - -**Note:** Version bump only for package @nuxtjs/manifest diff --git a/packages/manifest/README.md b/packages/manifest/README.md deleted file mode 100644 index 98b5ce26..00000000 --- a/packages/manifest/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. \ No newline at end of file diff --git a/packages/manifest/package.json b/packages/manifest/package.json deleted file mode 100755 index 570014ae..00000000 --- a/packages/manifest/package.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "name": "@nuxtjs/manifest", - "version": "3.0.0-beta.16", - "license": "MIT", - "main": "index.js", - "repository": "https://github.com/nuxt-community/pwa-module", - "publishConfig": { - "access": "public" - }, - "dependencies": { - "@nuxtjs/pwa-utils": "3.0.0-beta.16", - "hash-sum": "^1.0.2" - } -} diff --git a/packages/meta/CHANGELOG.md b/packages/meta/CHANGELOG.md deleted file mode 100644 index f425780b..00000000 --- a/packages/meta/CHANGELOG.md +++ /dev/null @@ -1,155 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -# [3.0.0-beta.16](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.15...v3.0.0-beta.16) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.15](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.14...v3.0.0-beta.15) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.14](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.13...v3.0.0-beta.14) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.13](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.12...v3.0.0-beta.13) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.12](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.11...v3.0.0-beta.12) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.11](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.10...v3.0.0-beta.11) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.10](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.9...v3.0.0-beta.10) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.9](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.8...v3.0.0-beta.9) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.8](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.7...v3.0.0-beta.8) (2019-02-18) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.7](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.6...v3.0.0-beta.7) (2019-02-17) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.6](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.5](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.3...v3.0.0-beta.5) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.3](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.2](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.1](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.0...v3.0.0-beta.1) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/meta - - - - - -# [3.0.0-beta.0](https://github.com/nuxt-community/pwa-module/compare/v2.6.0...v3.0.0-beta.0) (2019-02-04) - - -### Bug Fixes - -* path ogImage if is url ([#121](https://github.com/nuxt-community/pwa-module/issues/121)) ([d6dc82b](https://github.com/nuxt-community/pwa-module/commit/d6dc82b)) - - -### chore - -* only support nuxt.hook ([854d826](https://github.com/nuxt-community/pwa-module/commit/854d826)) - - -### Features - -* remove debug ([92ba73e](https://github.com/nuxt-community/pwa-module/commit/92ba73e)) - - -### BREAKING CHANGES - -* needs nuxt 2.x or later - - - - - - -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - -**Note:** Version bump only for package @nuxtjs/meta diff --git a/packages/meta/README.md b/packages/meta/README.md deleted file mode 100644 index 212ee9b8..00000000 --- a/packages/meta/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. diff --git a/packages/meta/package.json b/packages/meta/package.json deleted file mode 100755 index 9e0781d4..00000000 --- a/packages/meta/package.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "@nuxtjs/meta", - "version": "3.0.0-beta.16", - "license": "MIT", - "main": "index.js", - "repository": "https://github.com/nuxt-community/pwa-module", - "publishConfig": { - "access": "public" - }, - "dependencies": { - "@nuxtjs/pwa-utils": "3.0.0-beta.16" - } -} diff --git a/packages/onesignal/CHANGELOG.md b/packages/onesignal/CHANGELOG.md deleted file mode 100644 index 7c114328..00000000 --- a/packages/onesignal/CHANGELOG.md +++ /dev/null @@ -1,164 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -# [3.0.0-beta.16](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.15...v3.0.0-beta.16) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.15](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.14...v3.0.0-beta.15) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.14](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.13...v3.0.0-beta.14) (2019-03-17) - - -### Bug Fixes - -* **onesignal:** ensure no duplicate script is added ([#161](https://github.com/nuxt-community/pwa-module/issues/161)) ([89c1a1d](https://github.com/nuxt-community/pwa-module/commit/89c1a1d)) - - - - - -# [3.0.0-beta.13](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.12...v3.0.0-beta.13) (2019-03-17) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.12](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.11...v3.0.0-beta.12) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.11](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.10...v3.0.0-beta.11) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.10](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.9...v3.0.0-beta.10) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.9](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.8...v3.0.0-beta.9) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.8](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.7...v3.0.0-beta.8) (2019-02-18) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.7](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.6...v3.0.0-beta.7) (2019-02-17) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.6](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.5](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.3...v3.0.0-beta.5) (2019-02-08) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.3](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2019-02-07) - - -### Bug Fixes - -* **onesignal:** add cache query to sw.js ([33f8f61](https://github.com/nuxt-community/pwa-module/commit/33f8f61)) - - - - - -# [3.0.0-beta.2](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.1](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.0...v3.0.0-beta.1) (2019-02-07) - -**Note:** Version bump only for package @nuxtjs/onesignal - - - - - -# [3.0.0-beta.0](https://github.com/nuxt-community/pwa-module/compare/v2.6.0...v3.0.0-beta.0) (2019-02-04) - - -### chore - -* only support nuxt.hook ([854d826](https://github.com/nuxt-community/pwa-module/commit/854d826)) - - -### Code Refactoring - -* use tapable hooks ([#103](https://github.com/nuxt-community/pwa-module/issues/103)) ([9f27d5c](https://github.com/nuxt-community/pwa-module/commit/9f27d5c)) - - -### Features - -* remove debug ([92ba73e](https://github.com/nuxt-community/pwa-module/commit/92ba73e)) -* **onesignal:** enable CDN by default ([7c78c67](https://github.com/nuxt-community/pwa-module/commit/7c78c67)) -* update onesignal sdk once ([c08e423](https://github.com/nuxt-community/pwa-module/commit/c08e423)) - - -### BREAKING CHANGES - -* needs nuxt 2.x or later -* webpack >= 4 (Nuxt >= 2) is required - - - - - - -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - -**Note:** Version bump only for package @nuxtjs/onesignal diff --git a/packages/onesignal/README.md b/packages/onesignal/README.md deleted file mode 100644 index 212ee9b8..00000000 --- a/packages/onesignal/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. diff --git a/packages/onesignal/dist/OneSignalSDK.js b/packages/onesignal/dist/OneSignalSDK.js deleted file mode 100644 index 5d473d32..00000000 --- a/packages/onesignal/dist/OneSignalSDK.js +++ /dev/null @@ -1,2 +0,0 @@ -!function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},n.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=102)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(){}return e.shouldLog=function(){try{if("undefined"==typeof window||void 0===window.localStorage)return!1;var e=window.localStorage.getItem("loglevel");return!(!e||"trace"!==e.toLowerCase())}catch(e){return!1}},e.setLevel=function(t){if("undefined"!=typeof window&&void 0!==window.localStorage)try{window.localStorage.setItem("loglevel",t),e.proxyMethodsCreated=void 0,e.createProxyMethods()}catch(e){return}},e.createProxyMethods=function(){if(void 0===e.proxyMethodsCreated){e.proxyMethodsCreated=!0;for(var t={log:"debug",trace:"trace",info:"info",warn:"warn",error:"error"},n=0,i=Object.keys(t);n0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=44)return!(["20160725105554","20160905130425","20161031153904","20161129180326","20161209150850","20170118123525","20170227085837","20170227131422","20170301181722","20170303022339","20170316213902","20170323110425","20170410145022","20170411115307","20170412142208","20170417065206","20170504112025","20170517122419","20170607123825","20170627155318","20170801170322","20170802111520","20170917103825","20170921064520","20171005074949","20171106172903","20171107091003","20171128121223","20171206101620","20171226003912","20180116134019","20180118122319","20180307131617","20180313134936","20180315163333","20180322140748","20180426000307","20180427183532","20180427222832","20180430140610","20180503092946","20180503164101","20180516032417","20180605153619","20180605174236","20180605201706","20180619102821","20180619173714","20180621064021","20180621121604","20180830204350","20180903060751","20180920175354","20181001135620","20181017185317"].indexOf(navigator.buildID)>-1);return!(!e.safari&&void 0===navigator.serviceWorker||e.ios||e.ipod||e.iphone||e.ipad||e.msie||!(e.msedge&&Number(e.version)>=17.17063)&&(t.indexOf("FBAN")>-1||t.indexOf("FBAV")>-1||navigator.appVersion.match(/ wv/)||!(e.safari&&Number(e.version)>=7.1)&&!(e.samsungBrowser&&Number(e.version)>=4)&&!((e.chrome||e.chromium)&&Number(e.version)>=42)&&!(e.yandexbrowser&&Number(e.version)>=15.12)&&!(e.opera&&(e.mobile||e.tablet)&&Number(e.version)>=37||e.opera&&Number(e.version)>=42)&&!e.vivaldi))},t.isChromeLikeBrowser=function(){return s.default.chrome||s.default.chromium||s.default.opera||s.default.yandexbrowser},t.removeDomElement=function(e){var t=document.querySelectorAll(e);if(t.length>0)for(var n=0;n0)for(var s=0;s0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]1&&n[1]||""}var i,r,o,s=n(/(ipod|iphone|ipad)/i).toLowerCase(),a=!/like android/i.test(t)&&/android/i.test(t),u=/nexus\s*[0-6]\s*/i.test(t),c=!u&&/nexus\s*[0-9]+/i.test(t),l=/CrOS/.test(t),d=/silk/i.test(t),f=/sailfish/i.test(t),p=/tizen/i.test(t),h=/(web|hpw)os/i.test(t),g=/windows phone/i.test(t),b=(/SamsungBrowser/i.test(t),!g&&/windows/i.test(t)),v=!s&&!d&&/macintosh/i.test(t),m=!a&&!f&&!p&&!h&&/linux/i.test(t),S=n(/edge\/(\d+(\.\d+)?)/i),y=n(/version\/(\d+(\.\d+)?)/i),w=/tablet/i.test(t)&&!/tablet pc/i.test(t),O=!w&&/[^-]mobi/i.test(t),_=/xbox/i.test(t);/opera/i.test(t)?i={name:"Opera",opera:e,version:y||n(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)}:/opr\/|opios/i.test(t)?i={name:"Opera",opera:e,version:n(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||y}:/SamsungBrowser/i.test(t)?i={name:"Samsung Internet for Android",samsungBrowser:e,version:y||n(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)}:/coast/i.test(t)?i={name:"Opera Coast",coast:e,version:y||n(/(?:coast)[\s\/](\d+(\.\d+)?)/i)}:/yabrowser/i.test(t)?i={name:"Yandex Browser",yandexbrowser:e,version:y||n(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)}:/ucbrowser/i.test(t)?i={name:"UC Browser",ucbrowser:e,version:n(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)}:/mxios/i.test(t)?i={name:"Maxthon",maxthon:e,version:n(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)}:/epiphany/i.test(t)?i={name:"Epiphany",epiphany:e,version:n(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)}:/puffin/i.test(t)?i={name:"Puffin",puffin:e,version:n(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)}:/sleipnir/i.test(t)?i={name:"Sleipnir",sleipnir:e,version:n(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)}:/k-meleon/i.test(t)?i={name:"K-Meleon",kMeleon:e,version:n(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)}:g?(i={name:"Windows Phone",windowsphone:e},S?(i.msedge=e,i.version=S):(i.msie=e,i.version=n(/iemobile\/(\d+(\.\d+)?)/i))):/msie|trident/i.test(t)?i={name:"Internet Explorer",msie:e,version:n(/(?:msie |rv:)(\d+(\.\d+)?)/i)}:l?i={name:"Chrome",chromeos:e,chromeBook:e,chrome:e,version:n(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:/chrome.+? edge/i.test(t)?i={name:"Microsoft Edge",msedge:e,version:S}:/vivaldi/i.test(t)?i={name:"Vivaldi",vivaldi:e,version:n(/vivaldi\/(\d+(\.\d+)?)/i)||y}:f?i={name:"Sailfish",sailfish:e,version:n(/sailfish\s?browser\/(\d+(\.\d+)?)/i)}:/seamonkey\//i.test(t)?i={name:"SeaMonkey",seamonkey:e,version:n(/seamonkey\/(\d+(\.\d+)?)/i)}:/firefox|iceweasel|fxios/i.test(t)?(i={name:"Firefox",firefox:e,version:n(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(t)&&(i.firefoxos=e)):d?i={name:"Amazon Silk",silk:e,version:n(/silk\/(\d+(\.\d+)?)/i)}:/phantom/i.test(t)?i={name:"PhantomJS",phantom:e,version:n(/phantomjs\/(\d+(\.\d+)?)/i)}:/slimerjs/i.test(t)?i={name:"SlimerJS",slimer:e,version:n(/slimerjs\/(\d+(\.\d+)?)/i)}:/blackberry|\bbb\d+/i.test(t)||/rim\stablet/i.test(t)?i={name:"BlackBerry",blackberry:e,version:y||n(/blackberry[\d]+\/(\d+(\.\d+)?)/i)}:h?(i={name:"WebOS",webos:e,version:y||n(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(t)&&(i.touchpad=e)):/bada/i.test(t)?i={name:"Bada",bada:e,version:n(/dolfin\/(\d+(\.\d+)?)/i)}:p?i={name:"Tizen",tizen:e,version:n(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||y}:/qupzilla/i.test(t)?i={name:"QupZilla",qupzilla:e,version:n(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||y}:/chromium/i.test(t)?i={name:"Chromium",chromium:e,version:n(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||y}:/chrome|crios|crmo/i.test(t)?i={name:"Chrome",chrome:e,version:n(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:a?i={name:"Android",version:y}:/safari|applewebkit/i.test(t)?(i={name:"Safari",safari:e},y&&(i.version=y)):s?(i={name:"iphone"==s?"iPhone":"ipad"==s?"iPad":"iPod"},y&&(i.version=y)):i=/googlebot/i.test(t)?{name:"Googlebot",googlebot:e,version:n(/googlebot\/(\d+(\.\d+))/i)||y}:{name:n(/^(.*)\/(.*) /),version:(r=/^(.*)\/(.*) /,o=t.match(r),o&&o.length>1&&o[2]||"")},!i.msedge&&/(apple)?webkit/i.test(t)?(/(apple)?webkit\/537\.36/i.test(t)?(i.name=i.name||"Blink",i.blink=e):(i.name=i.name||"Webkit",i.webkit=e),!i.version&&y&&(i.version=y)):!i.opera&&/gecko\//i.test(t)&&(i.name=i.name||"Gecko",i.gecko=e,i.version=i.version||n(/gecko\/(\d+(\.\d+)?)/i)),i.windowsphone||i.msedge||!a&&!i.silk?i.windowsphone||i.msedge||!s?v?i.mac=e:_?i.xbox=e:b?i.windows=e:m&&(i.linux=e):(i[s]=e,i.ios=e):i.android=e;var E="";i.windows?E=function(e){switch(e){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}}(n(/Windows ((NT|XP)( \d\d?.\d)?)/i)):i.windowsphone?E=n(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i):i.mac?E=(E=n(/Mac OS X (\d+([_\.\s]\d+)*)/i)).replace(/[_\s]/g,"."):s?E=(E=n(/os (\d+([_\s]\d+)*) like mac os x/i)).replace(/[_\s]/g,"."):a?E=n(/android[ \/-](\d+(\.\d+)*)/i):i.webos?E=n(/(?:web|hpw)os\/(\d+(\.\d+)*)/i):i.blackberry?E=n(/rim\stablet\sos\s(\d+(\.\d+)*)/i):i.bada?E=n(/bada\/(\d+(\.\d+)*)/i):i.tizen&&(E=n(/tizen[\/\s](\d+(\.\d+)*)/i)),E&&(i.osversion=E);var P=!i.windows&&E.split(".")[0];return w||c||"ipad"==s||a&&(3==P||P>=4&&!O)||i.silk?i.tablet=e:(O||"iphone"==s||"ipod"==s||a||u||i.blackberry||i.webos||i.bada)&&(i.mobile=e),i.msedge||i.msie&&i.version>=10||i.yandexbrowser&&i.version>=15||i.vivaldi&&i.version>=1||i.chrome&&i.version>=20||i.samsungBrowser&&i.version>=4||i.firefox&&i.version>=20||i.safari&&i.version>=6||i.opera&&i.version>=10||i.ios&&i.osversion&&i.osversion.split(".")[0]>=6||i.blackberry&&i.version>=10.1||i.chromium&&i.version>=20?i.a=e:i.msie&&i.version<10||i.chrome&&i.version<20||i.firefox&&i.version<20||i.safari&&i.version<6||i.opera&&i.version<10||i.ios&&i.osversion&&i.osversion.split(".")[0]<6||i.chromium&&i.version<20?i.c=e:i.x=e,i}var n=t("undefined"!=typeof navigator&&navigator.userAgent||"");function i(e){return e.split(".").length}function r(e,t){var n,i=[];if(Array.prototype.map)return Array.prototype.map.call(e,t);for(n=0;n=0;){if(n[0][t]>n[1][t])return 1;if(n[0][t]!==n[1][t])return-1;if(0===t)return 0}}function s(e,i,r){var s=n;"string"==typeof i&&(r=i,i=void 0),void 0===i&&(i=!1),r&&(s=t(r));var a=""+s.version;for(var u in e)if(e.hasOwnProperty(u)&&s[u]){if("string"!=typeof e[u])throw new Error("Browser version in the minVersion map should be a string: "+u+": "+String(e));return o([a,e[u]])<0}return i}return n.test=function(e){for(var t=0;t0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1] to the first element in .")}}},e.getCurrentNotificationType=function(){return i(this,void 0,void 0,function(){var e,t;return r(this,function(n){switch(n.label){case 0:return[4,OneSignal.context.permissionManager.getNotificationPermission(OneSignal.context.appConfig.safariWebId)];case 1:return(e=n.sent())===p.NotificationPermission.Default?[2,f.SubscriptionStateKind.Default]:e===p.NotificationPermission.Denied?[2,h.OneSignalUtils.isUsingSubscriptionWorkaround()?f.SubscriptionStateKind.Default:f.SubscriptionStateKind.NotSubscribed]:[4,OneSignal.context.subscriptionManager.isAlreadyRegisteredWithOneSignal()];case 2:return t=n.sent(),e===p.NotificationPermission.Granted&&t?[4,OneSignal.privateIsPushNotificationsEnabled()]:[3,4];case 3:return[2,n.sent()?f.SubscriptionStateKind.Subscribed:f.SubscriptionStateKind.MutedByApi];case 4:return[2,f.SubscriptionStateKind.Default]}})})},e.getNotificationTypeFromOptIn=function(e){return 1==e||null==e?f.SubscriptionStateKind.Subscribed:f.SubscriptionStateKind.MutedByApi},e.wasHttpsNativePromptDismissed=function(){return"dismissed"===l.default.getItem("onesignal-notification-prompt")},e.markHttpPopoverShown=function(){sessionStorage.setItem("ONESIGNAL_HTTP_PROMPT_SHOWN","true")},e.isHttpPromptAlreadyShown=function(){return"true"==sessionStorage.getItem("ONESIGNAL_HTTP_PROMPT_SHOWN")},e.checkAndTriggerNotificationPermissionChanged=function(){return i(this,void 0,void 0,function(){var e,t;return r(this,function(n){switch(n.label){case 0:return[4,c.default.get("Options","notificationPermission")];case 1:return e=n.sent(),[4,OneSignal.getNotificationPermission()];case 2:return t=n.sent(),e===t?[3,5]:[4,g.PermissionUtils.triggerNotificationPermissionChanged()];case 3:return n.sent(),[4,c.default.put("Options",{key:"notificationPermission",value:t})];case 4:n.sent(),n.label=5;case 5:return[2]}})})},e.getNotificationIcons=function(){return i(this,void 0,void 0,function(){var t,n,i;return r(this,function(r){switch(r.label){case 0:return[4,e.getAppId()];case 1:if(!(t=r.sent()))throw new s.InvalidStateError(s.InvalidStateReason.MissingAppId);return n=u.default.getOneSignalApiUrl().toString()+"/apps/"+t+"/icon",[4,fetch(n)];case 2:return[4,r.sent().json()];case 3:if((i=r.sent()).errors)throw d.default.error("API call %c"+n,b.Utils.getConsoleStyle("code"),"failed with:",i.errors),new Error("Failed to get notification icons.");return[2,i]}})})},e.getSlidedownPermissionMessageOptions=function(){var e="We'd like to show you notifications for the latest news and updates.",t=OneSignal.config.userConfig.promptOptions;return t?t.slidedown?{autoPrompt:t.slidedown.autoPrompt,actionMessage:t.slidedown.actionMessage||e,acceptButtonText:t.slidedown.acceptButtonText||"Allow",cancelButtonText:t.slidedown.cancelButtonText||"No Thanks"}:{autoPrompt:!1,actionMessage:t.actionMessage||e,acceptButtonText:t.acceptButtonText||"Allow",cancelButtonText:t.cancelButtonText||"No Thanks"}:{autoPrompt:!1,actionMessage:e,acceptButtonText:"Allow",cancelButtonText:"No Thanks"}},e.getFullscreenPermissionMessageOptions=function(){var e=OneSignal.config.userConfig.promptOptions;return e?e.fullscreen?{autoAcceptTitle:e.fullscreen.autoAcceptTitle,actionMessage:e.fullscreen.actionMessage,exampleNotificationTitleDesktop:e.fullscreen.title,exampleNotificationTitleMobile:e.fullscreen.title,exampleNotificationMessageDesktop:e.fullscreen.message,exampleNotificationMessageMobile:e.fullscreen.message,exampleNotificationCaption:e.fullscreen.caption,acceptButtonText:e.fullscreen.acceptButton,cancelButtonText:e.fullscreen.cancelButton}:e:null},e.getPromptOptionsQueryString=function(){var t="";if(e.getFullscreenPermissionMessageOptions())for(var n=e.getPromptOptionsPostHash(),i=0,r=Object.keys(n);i0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=12.1?[4,w.default.internalRegisterForPush(!1)]:[3,4];case 3:return n.sent(),[3,6];case 4:return(e=t||{}).__fromRegister=!0,[4,S.default.sessionInit(e)];case 5:n.sent(),n.label=6;case 6:return[2]}})})}return r(this,function(t){switch(t.label){case 0:return e.initialized?[3,2]:[4,new Promise(function(t,s){e.emitter.once(e.EVENTS.SDK_INITIALIZED,function(){return i(n,void 0,void 0,function(){return r(this,function(e){switch(e.label){case 0:return[4,o()];case 1:return e.sent(),[2,t(void 0)]}})})})})];case 1:return t.sent(),[3,4];case 2:return[4,o()];case 3:return[2,t.sent()];case 4:return[2]}})})},e.getNotificationPermission=function(t){return i(this,void 0,void 0,function(){return r(this,function(n){switch(n.label){case 0:return[4,D.awaitOneSignalInitAndSupported()];case 1:return n.sent(),[2,e.privateGetNotificationPermission(t)]}})})},e.privateGetNotificationPermission=function(t){return i(this,void 0,void 0,function(){var n;return r(this,function(i){switch(i.label){case 0:return[4,e.context.permissionManager.getNotificationPermission(e.config.safariWebId)];case 1:return n=i.sent(),t&&t(n),[2,n]}})})},e.getTags=function(e){return i(this,void 0,void 0,function(){var t,n,i;return r(this,function(r){switch(r.label){case 0:return[4,D.awaitOneSignalInitAndSupported()];case 1:return r.sent(),D.logMethodCall("getTags",e),[4,x.default.getAppConfig()];case 2:return t=r.sent().appId,[4,x.default.getSubscription()];case 3:return(n=r.sent().deviceId)?[4,T.default.getPlayer(t,n)]:(F.default.info(new d.NotSubscribedError(d.NotSubscribedReason.NoDeviceId)),[2,null]);case 4:return i=r.sent().tags,D.executeCallback(e,i),[2,i]}})})},e.sendTag=function(t,n,o){return i(this,void 0,void 0,function(){var i;return r(this,function(r){switch(r.label){case 0:return(i={})[t]=n,[4,e.sendTags(i,o)];case 1:return[2,r.sent()]}})})},e.sendTags=function(t,n){return i(this,void 0,void 0,function(){var i,o,s;return r(this,function(r){switch(r.label){case 0:return[4,D.awaitOneSignalInitAndSupported()];case 1:return r.sent(),D.logMethodCall("sendTags",t,n),t&&0!==Object.keys(t).length?(Object.keys(t).forEach(function(e){!1===t[e]&&(t[e]="false")}),[4,x.default.getAppConfig()]):(F.default.info(new c.InvalidArgumentError("tags",c.InvalidArgumentReason.Empty)),[2,null]);case 2:return i=r.sent().appId,[4,x.default.getEmailProfile()];case 3:return(o=r.sent()).emailId?[4,T.default.updatePlayer(i,o.emailId,{tags:t,email_auth_hash:o.emailAuthHash})]:[3,5];case 4:r.sent(),r.label=5;case 5:return[4,x.default.getSubscription()];case 6:return r.sent().deviceId?[3,8]:[4,D.awaitSdkEvent(e.EVENTS.REGISTERED)];case 7:r.sent(),r.label=8;case 8:return[4,x.default.getSubscription()];case 9:return s=r.sent().deviceId,[4,T.default.updatePlayer(i,s,{tags:t})];case 10:return r.sent(),D.executeCallback(n,t),[2,t]}})})},e.deleteTag=function(t){return i(this,void 0,void 0,function(){return r(this,function(n){switch(n.label){case 0:return[4,e.deleteTags([t])];case 1:return[2,n.sent()]}})})},e.deleteTags=function(t,n){return i(this,void 0,void 0,function(){var i,o,s,a,u,l;return r(this,function(r){switch(r.label){case 0:return[4,D.awaitOneSignalInitAndSupported()];case 1:if(r.sent(),D.logMethodCall("deleteTags",t,n),!W.ValidatorUtils.isValidArray(t))throw new c.InvalidArgumentError("tags",c.InvalidArgumentReason.Malformed);for(0===t.length&&F.default.info(new c.InvalidArgumentError("tags",c.InvalidArgumentReason.Empty)),i={},o=0,s=t;o0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=0;i--){n[i]===t&&n.splice(i,1)}},e}();t.WorkerMessengerReplyBuffer=p;var h=function(){function e(e,t){void 0===t&&(t=new p),this.context=e,this.replies=t}return e.prototype.broadcast=function(e,t){return i(this,void 0,void 0,function(){var n,i,o,s;return r(this,function(r){switch(r.label){case 0:return u.default.getWindowEnv()===l.WindowEnvironmentKind.ServiceWorker?[3,1]:[2];case 1:return[4,self.clients.matchAll({type:"window",includeUncontrolled:!0})];case 2:for(n=r.sent(),i=0,o=n;i Page] Broadcasting '"+e.toString()+"' to window client "+s.url+"."),s.postMessage({command:e,payload:t});r.label=3;case 3:return[2]}})})},e.prototype.unicast=function(e,t,n){return i(this,void 0,void 0,function(){return r(this,function(i){switch(i.label){case 0:if(u.default.getWindowEnv()!==l.WindowEnvironmentKind.ServiceWorker)return[3,1];if(!n)throw new a.InvalidArgumentError("windowClient",a.InvalidArgumentReason.Empty);return f.default.debug("[Worker Messenger] [SW -> Page] Unicasting '"+e.toString()+"' to window client "+n.url+"."),n.postMessage({command:e,payload:t}),[3,4];case 1:return[4,this.isWorkerControllingPage()];case 2:return i.sent()||f.default.debug("[Worker Messenger] The page is not controlled by the service worker yet. Waiting...",self.registration),[4,this.waitUntilWorkerControlsPage()];case 3:i.sent(),f.default.debug("[Worker Messenger] [Page -> SW] Unicasting '"+e.toString()+"' to service worker."),navigator.serviceWorker.controller.postMessage({command:e,payload:t}),i.label=4;case 4:return[2]}})})},e.prototype.listen=function(e){return i(this,void 0,void 0,function(){return r(this,function(t){switch(t.label){case 0:return d.default.supportsServiceWorkers()?u.default.getWindowEnv()!==l.WindowEnvironmentKind.ServiceWorker?[3,1]:(self.addEventListener("message",this.onWorkerMessageReceivedFromPage.bind(this)),f.default.debug("[Worker Messenger] Service worker is now listening for messages."),[3,3]):[2];case 1:return[4,this.listenForPage(e)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},e.prototype.listenForPage=function(e){return i(this,void 0,void 0,function(){return r(this,function(t){switch(t.label){case 0:return e?[3,3]:[4,this.isWorkerControllingPage()];case 1:return t.sent()||f.default.debug("("+location.origin+") [Worker Messenger] The page is not controlled by the service worker yet. Waiting...",self.registration),[4,this.waitUntilWorkerControlsPage()];case 2:t.sent(),f.default.debug("("+location.origin+") [Worker Messenger] The page is now controlled by the service worker."),t.label=3;case 3:return navigator.serviceWorker.addEventListener("message",this.onPageMessageReceivedFromServiceWorker.bind(this)),f.default.debug("("+location.origin+") [Worker Messenger] Page is now listening for messages."),[2]}})})},e.prototype.onWorkerMessageReceivedFromPage=function(e){var t=e.data;if(t&&t.command){var n=this.replies.findListenersForMessage(t.command),i=[],r=[];f.default.debug("[Worker Messenger] Service worker received message:",e.data);for(var o=0,s=n;o=0;a--){var u=i[a];this.replies.deleteListenerRecord(t.command,u)}for(var c=0,l=r;c=0;a--){var u=i[a];this.replies.deleteListenerRecord(t.command,u)}for(var c=0,l=r;c0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&l.default.contains(r.errors[0],"app_id not found")?new a.OneSignalApiError(a.OneSignalApiErrorKind.MissingAppId):r;case 3:return[2]}})})},e}();t.default=d},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s,a=o(n(8));(s=t.InvalidArgumentReason||(t.InvalidArgumentReason={}))[s.Empty=0]="Empty",s[s.Malformed=1]="Malformed",s[s.EnumOutOfRange=2]="EnumOutOfRange";var InvalidArgumentError=function(e){function InvalidArgumentError(n,i){var r=this;switch(i){case t.InvalidArgumentReason.Empty:r=e.call(this,"Supply a non-empty value to '"+n+"'.")||this;break;case t.InvalidArgumentReason.Malformed:r=e.call(this,"The value for '"+n+"' was malformed.")||this;break;case t.InvalidArgumentReason.EnumOutOfRange:r=e.call(this,"The value for '"+n+"' was out of range of the expected input enum.")||this}return r.argument=n,r.reason=t.InvalidArgumentReason[i],Object.setPrototypeOf(r,InvalidArgumentError.prototype),r}return r(InvalidArgumentError,e),InvalidArgumentError}(a.default);t.InvalidArgumentError=InvalidArgumentError},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]{{prompt.native.grant}} to receive notifications","message.action.subscribed":"Thanks for subscribing!","message.action.resubscribed":"You're subscribed to notifications","message.action.unsubscribed":"You won't receive notifications again","dialog.main.title":"Manage Site Notifications","dialog.main.button.subscribe":"SUBSCRIBE","dialog.main.button.unsubscribe":"UNSUBSCRIBE","dialog.blocked.title":"Unblock Notifications","dialog.blocked.message":"Follow these instructions to allow notifications:"}:w,_=n.prenotify,E=void 0===_||_,P=n.showCredit,I=void 0===P||P,C=n.colors,k=void 0===C?null:C,M=n.offset,A=void 0===M?null:M,T=n.launcher,N=void 0===T?null:T,x=this;if(this.options={enable:s,size:l,position:f,theme:g,showLauncherAfter:m,showBadgeAfter:y,text:O,prenotify:E,showCredit:I,colors:k,offset:A},this.options.enable){if(!c.contains(["small","medium","large"],this.options.size))throw new Error("Invalid size "+this.options.size+" for notify button. Choose among 'small', 'medium', or 'large'.");if(!c.contains(["bottom-left","bottom-right"],this.options.position))throw new Error("Invalid position "+this.options.position+" for notify button. Choose either 'bottom-left', or 'bottom-right'.");if(!c.contains(["default","inverse"],this.options.theme))throw new Error("Invalid theme "+this.options.theme+" for notify button. Choose either 'default', or 'inverse'.");if(this.options.showLauncherAfter<0)throw new Error("Invalid delay duration of "+this.options.showLauncherAfter+" for showing the notify button. Choose a value above 0.");if(this.options.showBadgeAfter<0)throw new Error("Invalid delay duration of "+this.options.showBadgeAfter+" for showing the notify button's badge. Choose a value above 0.");this.size=this.options.size,this.position=this.options.position,this.text=this.options.text,this.text["tip.state.unsubscribed"]||(this.text["tip.state.unsubscribed"]="Subscribe to notifications"),this.text["tip.state.subscribed"]||(this.text["tip.state.subscribed"]="You're subscribed to notifications"),this.text["tip.state.blocked"]||(this.text["tip.state.blocked"]="You've blocked notifications"),this.text["message.prenotify"]||(this.text["message.prenotify"]="Click to subscribe to notifications"),this.text["message.action.subscribed"]||(this.text["message.action.subscribed"]="Thanks for subscribing!"),this.text["message.action.resubscribed"]||(this.text["message.action.resubscribed"]="You're subscribed to notifications"),this.text["message.action.subscribing"]||(this.text["message.action.subscribing"]="Click {{prompt.native.grant}} to receive notifications"),this.text["message.action.unsubscribed"]||(this.text["message.action.unsubscribed"]="You won't receive notifications again"),this.text["dialog.main.title"]||(this.text["dialog.main.title"]="Manage Site Notifications"),this.text["dialog.main.button.subscribe"]||(this.text["dialog.main.button.subscribe"]="SUBSCRIBE"),this.text["dialog.main.button.unsubscribe"]||(this.text["dialog.main.button.unsubscribe"]="UNSUBSCRIBE"),this.text["dialog.blocked.title"]||(this.text["dialog.blocked.title"]="Unblock Notifications"),this.text["dialog.blocked.message"]||(this.text["dialog.blocked.message"]="Follow these instructions to allow notifications:"),this._launcher=N,this.state=e.STATES.UNINITIALIZED,this._ignoreSubscriptionState=!1,b.default.emitter.on(e.EVENTS.SUBSCRIBE_CLICK,function(){x.dialog.subscribeButton.disabled=!0,x._ignoreSubscriptionState=!0,b.default.setSubscription(!0).then(function(){return x.dialog.subscribeButton.disabled=!1,x.dialog.hide()}).then(function(){return x.message.display(h.default.TYPES.MESSAGE,x.text["message.action.resubscribed"],h.default.TIMEOUT)}).then(function(){return x._ignoreSubscriptionState=!1,x.launcher.clearIfWasInactive(),x.launcher.inactivate()}).then(function(){return x.updateState()})}),b.default.emitter.on(e.EVENTS.UNSUBSCRIBE_CLICK,function(){x.dialog.unsubscribeButton.disabled=!0,b.default.setSubscription(!1).then(function(){return x.dialog.unsubscribeButton.disabled=!1,x.dialog.hide()}).then(function(){return x.launcher.clearIfWasInactive(),x.launcher.activate()}).then(function(){return x.message.display(h.default.TYPES.MESSAGE,x.text["message.action.unsubscribed"],h.default.TIMEOUT)}).then(function(){return x.updateState()})}),b.default.emitter.on(e.EVENTS.HOVERING,function(){x.hovering=!0,x.launcher.activateIfInactive(),x.message.shown||x.dialog.shown?x.hovering=!1:x.message.contentType!==h.default.TYPES.MESSAGE?new Promise(function(e){if(x.message.queued.length>0)return x.message.dequeue().then(function(t){x.message.content=t,x.message.contentType=h.default.TYPES.QUEUED,e()});x.message.content=c.decodeHtmlEntities(x.message.getTipForState()),x.message.contentType=h.default.TYPES.TIP,e()}).then(function(){return x.message.show()}).then(function(){x.hovering=!1}):x.hovering=!1}),b.default.emitter.on(e.EVENTS.HOVERED,function(){x.message.contentType!==h.default.TYPES.MESSAGE&&x.dialog.hidden&&(x.hovering&&(x.hovering=!1,x.message.waitUntilShown().then(function(){return c.delay(h.default.TIMEOUT)}).then(function(){return x.message.hide()}).then(function(){x.launcher.wasInactive&&x.dialog.hidden&&(x.launcher.inactivate(),x.launcher.wasInactive=null)})),x.message.shown&&x.message.hide().then(function(){x.launcher.wasInactive&&x.dialog.hidden&&(x.launcher.inactivate(),x.launcher.wasInactive=null)}))}),b.default.emitter.on(b.default.EVENTS.SUBSCRIPTION_CHANGED,function(t){return i(x,void 0,void 0,function(){var n,i=this;return r(this,function(r){switch(r.label){case 0:return 1!=t?[3,2]:(this.badge.shown&&this.options.prenotify&&this.badge.hide(),null!==this.dialog.notificationIcons?[3,2]:[4,u.default.getNotificationIcons()]);case 1:n=r.sent(),this.dialog.notificationIcons=n,r.label=2;case 2:return b.default.getNotificationPermission(function(n){i.setState(t?e.STATES.SUBSCRIBED:"denied"===n?e.STATES.BLOCKED:e.STATES.UNSUBSCRIBED,i._ignoreSubscriptionState)}),[2]}})})}),b.default.emitter.on(e.EVENTS.STATE_CHANGED,function(t){x.launcher.element&&(t.to===e.STATES.SUBSCRIBED?x.launcher.inactivate():(t.to===e.STATES.UNSUBSCRIBED||e.STATES.BLOCKED)&&x.launcher.activate())}),b.default.emitter.on(b.default.EVENTS.NATIVE_PROMPT_PERMISSIONCHANGED,function(){x.updateState()}),this.updateState()}}return Object.defineProperty(e,"EVENTS",{get:function(){return{STATE_CHANGED:"notifyButtonStateChange",LAUNCHER_CLICK:"notifyButtonLauncherClick",BELL_CLICK:"notifyButtonButtonClick",SUBSCRIBE_CLICK:"notifyButtonSubscribeClick",UNSUBSCRIBE_CLICK:"notifyButtonUnsubscribeClick",HOVERING:"notifyButtonHovering",HOVERED:"notifyButtonHover"}},enumerable:!0,configurable:!0}),Object.defineProperty(e,"STATES",{get:function(){return{UNINITIALIZED:"uninitialized",SUBSCRIBED:"subscribed",UNSUBSCRIBED:"unsubscribed",BLOCKED:"blocked"}},enumerable:!0,configurable:!0}),Object.defineProperty(e,"TEXT_SUBS",{get:function(){return{"prompt.native.grant":{default:"Allow",chrome:"Allow",firefox:"Always Receive Notifications",safari:"Allow"}}},enumerable:!0,configurable:!0}),e.prototype.showDialogProcedure=function(){var e=this;this.dialog.shown||this.dialog.show().then(function(){c.once(document,"click",function(t,n){e.dialog.element.contains(t.target)||(n(),e.dialog.shown&&e.dialog.hide().then(function(){e.launcher.inactivateIfWasInactive()}))},!0)})},e.prototype.create=function(){return i(this,void 0,void 0,function(){var e,t,n,i,o=this;return r(this,function(r){switch(r.label){case 0:return this.options.enable?[4,b.default.context.dynamicResourceLoader.loadSdkStylesheet()]:[2];case 1:return 0!==r.sent()?(g.default.debug("Not showing notify button because styles failed to load."),[2]):(this.container&&c.removeDomElement("#onesignal-bell-container"),c.addDomElement("body","beforeend",'
'),c.addDomElement(this.container,"beforeend",'
'),c.addDomElement(this.launcher.selector,"beforeend",'
'),c.addDomElement(this.launcher.selector,"beforeend",'
'),c.addDomElement(this.launcher.selector,"beforeend",'
'),c.addDomElement(this.message.selector,"beforeend",'
'),c.addDomElement(this.launcher.selector,"beforeend",'
'),c.addDomElement(this.dialog.selector,"beforeend",'
'),c.addDomElement(this.button.selector,"beforeEnd",''),[4,b.default.isPushNotificationsEnabled()]);case 2:return e=r.sent(),[4,b.default.getSubscription()];case 3:return t=r.sent(),[4,u.default.wasHttpsNativePromptDismissed()];case 4:return n=r.sent(),i=e?"small":this.options.size,[4,this.launcher.resize(i)];case 5:if(r.sent(),"bottom-left"===this.options.position)c.addCssClass(this.container,"onesignal-bell-container-bottom-left"),c.addCssClass(this.launcher.selector,"onesignal-bell-launcher-bottom-left");else{if("bottom-right"!==this.options.position)throw new Error("Invalid OneSignal notify button position "+this.options.position);c.addCssClass(this.container,"onesignal-bell-container-bottom-right"),c.addCssClass(this.launcher.selector,"onesignal-bell-launcher-bottom-right")}if("default"===this.options.theme)c.addCssClass(this.launcher.selector,"onesignal-bell-launcher-theme-default");else{if("inverse"!==this.options.theme)throw new Error("Invalid OneSignal notify button theme "+this.options.theme);c.addCssClass(this.launcher.selector,"onesignal-bell-launcher-theme-inverse")}return this.applyOffsetIfSpecified(),this.setCustomColorsIfSpecified(),this.patchSafariSvgFilterBug(),g.default.info("Showing the notify button."),[4,(e?this.launcher.inactivate():c.nothing()).then(function(){return b.default.getSubscription()}).then(function(t){return!e&&t||null!==o.dialog.notificationIcons?c.nothing():u.default.getNotificationIcons().then(function(e){o.dialog.notificationIcons=e})}).then(function(){return c.delay(o.options.showLauncherAfter)}).then(function(){return c.isUsingSubscriptionWorkaround()&&t&&!0!==n&&!e&&!0===b.default.config.userConfig.autoRegister&&!u.default.isHttpPromptAlreadyShown()?(g.default.debug("Not showing notify button because popover will be shown."),c.nothing()):o.launcher.show()}).then(function(){return c.delay(o.options.showBadgeAfter)}).then(function(){return o.options.prenotify&&!e&&b.default._isNewVisitor?o.message.enqueue(o.text["message.prenotify"]).then(function(){return o.badge.show()}):c.nothing()}).then(function(){return o.initialized=!0})];case 6:return r.sent(),[2]}})})},e.prototype.patchSafariSvgFilterBug=function(){if(!(s.default.safari&&Number(s.default.version)>=9.1)){var e="drop-shadow(0 2px 4px rgba(34,36,38,0.35));",t="drop-shadow(0 2px 4px rgba(34,36,38,0));",n="drop-shadow(0px 2px 2px rgba(34,36,38,.15));";this.graphic.setAttribute("style","filter: "+e+"; -webkit-filter: "+e+";"),this.badge.element.setAttribute("style","filter: "+t+"; -webkit-filter: "+t+";"),this.dialog.element.setAttribute("style","filter: "+n+"; -webkit-filter: "+n+";")}s.default.safari&&this.badge.element.setAttribute("style","display: none;")},e.prototype.applyOffsetIfSpecified=function(){var e=this.options.offset;e&&(this.launcher.element.style.cssText="",e.bottom&&(this.launcher.element.style.cssText+="bottom: "+e.bottom+";"),"bottom-right"===this.options.position?e.right&&(this.launcher.element.style.cssText+="right: "+e.right+";"):"bottom-left"===this.options.position&&e.left&&(this.launcher.element.style.cssText+="left: "+e.left+";"))},e.prototype.setCustomColorsIfSpecified=function(){var e=this.dialog.element.querySelector("button.action"),t=this.button.element.querySelector(".pulse-ring");this.graphic.querySelector(".background").style.cssText="";for(var n=this.graphic.querySelectorAll(".foreground"),i=0;i0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]OneSignal: This page cannot be directly opened, and must be opened as a result of a subscription call."),[2,Promise.resolve()]):((e=i({},this.options)).appId=e.appId,e.subdomainName=e.subdomain,e.origin=e.origin,OneSignal.config=e||{},[4,(new c.default).getAppConfig(e)]);case 1:return t=r.sent(),OneSignal.context=new u.default(t),OneSignal.context.workerMessenger.listen(!0),OneSignal.initialized=!0,this.loadPromise={},this.loadPromise.promise=new Promise(function(e,t){n.loadPromise.resolver=e,n.loadPromise.rejector=t}),this.establishCrossOriginMessaging(),[2,this.loadPromise.promise]}})})},e.prototype.establishCrossOriginMessaging=function(){},e.prototype.dispose=function(){this.messenger.destroy()},e.prototype.finishInitialization=function(){this.loadPromise.resolver()},e.prototype.subscribe=function(){return r(this,void 0,void 0,function(){var e,t;return o(this,function(n){switch(n.label){case 0:return[4,OneSignal.isPushNotificationsEnabled()];case 1:return e=n.sent(),t=opener||parent,e?t&&window.close():a.default.registerForPush(),[2]}})})},e}();t.default=l},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=n.timestamp)return localStorage.removeItem(t),null;var r=n.value;try{r=JSON.parse(n.value)}catch(e){return r}return r},e.removeItem=function(t){if(!e.isLocalStorageSupported())return null;localStorage.removeItem(t)},e}();t.default=i},function(e,t,n){"use strict";var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var r=i(n(5)),o=i(n(1)),s=n(6),a=n(63),u=function(){function e(){}return e.get=function(t,n,i){return e.call("GET",t,n,i)},e.post=function(t,n,i){return e.call("POST",t,n,i)},e.put=function(t,n,i){return e.call("PUT",t,n,i)},e.delete=function(t,n,i){return e.call("DELETE",t,n,i)},e.call=function(t,n,i,s){if("GET"===t){if(n.indexOf("players")>-1&&-1===n.indexOf("app_id="))return console.error("Calls to player api are not permitted without app_id"),Promise.reject(new a.OneSignalApiError(a.OneSignalApiErrorKind.MissingAppId))}else if(n.indexOf("players")>-1&&(!i||!i.app_id))return console.error("Calls to player api are not permitted without app_id"),Promise.reject(new a.OneSignalApiError(a.OneSignalApiErrorKind.MissingAppId));var u=new Headers;if(u.append("SDK-Version","onesignal/web/"+r.default.version()),u.append("Content-Type","application/json;charset=UTF-8"),s)for(var c=0,l=Object.keys(s);c=200&&f<300?t:"no-user-id-error"!==e.identifyError(t)?Promise.reject(t):void 0})},e.identifyError=function(e){if(!e||!e.errors)return"no-error";var t=e.errors;return s.Utils.contains(t,"No user with this id found")||s.Utils.contains(t,"Could not find app_id for given player id.")?"no-user-id-error":"unknown-error"},e}();t.OneSignalApiBase=u,t.default=u},function(e,t,n){"use strict";var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var r=i(n(10)),o=i(n(5)),s=i(n(19)),a=n(62),u=n(95),c=n(7),l=function(){function e(){this.language=o.default.getLanguage(),this.timezone=-60*(new Date).getTimezoneOffset(),this.browserName=r.default.name,this.browserVersion=NaN!==parseInt(String(r.default.version))?parseInt(String(r.default.version)):-1,this.operatingSystem=this.getBrowserOperatingSystem(),this.operatingSystemVersion=String(r.default.osversion),this.devicePlatform=this.getDevicePlatform(),this.deviceModel=navigator.platform,this.sdkVersion=o.default.version().toString(),this.deliveryPlatform=this.getDeliveryPlatform()}return e.prototype.getDevicePlatform=function(){var e=r.default.mobile,t=r.default.tablet;return e?u.DevicePlatformKind.Mobile:t?u.DevicePlatformKind.Tablet:u.DevicePlatformKind.Desktop},e.prototype.isSafari=function(){return r.default.safari&&void 0!==window.safari&&void 0!==window.safari.pushNotification},e.prototype.getBrowserOperatingSystem=function(){return r.default.mac?"Mac OS X":r.default.windows?"Microsoft Windows":r.default.windowsphone?"Microsoft Windows Phone":r.default.linux?"Linux":r.default.chromeos?"Google Chrome OS":r.default.android?"Google Android":r.default.ios?"Apple iOS":r.default.blackberry?"Blackberry":r.default.firefoxos?"Mozilla Firefox OS":r.default.webos?"WebOS":r.default.tizen?"Tizen":r.default.sailfish?"Sailfish OS":"Unknown"},e.prototype.getDeliveryPlatform=function(){var e=c.OneSignalUtils.redetectBrowserUserAgent();return this.isSafari()?a.DeliveryPlatformKind.Safari:e.firefox?a.DeliveryPlatformKind.Firefox:e.msedge?a.DeliveryPlatformKind.Edge:a.DeliveryPlatformKind.ChromeLike},e.prototype.serialize=function(){var e={device_type:this.deliveryPlatform,language:this.language,timezone:this.timezone,device_os:this.browserVersion,sdk:this.sdkVersion,notification_types:this.subscriptionState,delivery_platform:this.deliveryPlatform,browser_name:this.browserName,browser_version:this.browserVersion,operating_system:this.operatingSystem,operating_system_version:this.operatingSystemVersion,device_platform:this.devicePlatform,device_model:this.deviceModel};return this.appId&&(e.app_id=this.appId),e},e.prototype.deserialize=function(e){throw new s.default},e}();t.DeviceRecord=l},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=o(n(19)),a=n(62),u=function(e){function t(t,n,i){var r=e.call(this)||this;return r.email=t,r.emailAuthHash=n,r.pushDeviceRecordId=i,r.deliveryPlatform=a.DeliveryPlatformKind.Email,r}return r(t,e),t.prototype.serialize=function(){var t=e.prototype.serialize.call(this);return this.email&&(t.identifier=this.email),this.emailAuthHash&&(t.email_auth_hash=this.emailAuthHash),this.pushDeviceRecordId&&(t.device_player_id=this.pushDeviceRecordId),t},t.prototype.deserialize=function(e){throw new s.default},t}(n(37).DeviceRecord);t.EmailDeviceRecord=u},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0?i.message:"Thanks for subscribing!",f=new URL(location.href).origin+"?_osp=do_not_open",h=i&&i.url&&i.url.length>0?i.url:f,a=p.BrowserUtils.decodeHtmlEntities(a),d=p.BrowserUtils.decodeHtmlEntities(d),o||(l.default.debug("Sending welcome notification."),u.default.sendNotification(n,[t],{en:a},{en:d},h,null,{__isOneSignalWelcomeNotification:!0},void 0),s.default.trigger(OneSignal.EVENTS.WELCOME_NOTIFICATION_SENT,{title:a,message:d,url:h})),r.label=3;case 3:return[2]}})})},e.onSubscriptionChanged_evaluateNotifyButtonDisplayPredicate=function(){return i(this,void 0,void 0,function(){var e;return r(this,function(t){switch(t.label){case 0:return OneSignal.config.userConfig.notifyButton?(e=OneSignal.config.userConfig.notifyButton.displayPredicate)&&"function"==typeof e&&OneSignal.notifyButton?[4,e()]:[3,2]:[2];case 1:!1!==t.sent()?(l.default.debug("Showing notify button because display predicate returned true."),OneSignal.notifyButton.launcher.show()):(l.default.debug("Hiding notify button because display predicate returned false."),OneSignal.notifyButton.launcher.hide()),t.label=2;case 2:return[2]}})})},e.onSubscriptionChanged_updateCustomLink=function(){return i(this,void 0,void 0,function(){return r(this,function(e){switch(e.label){case 0:return OneSignal.config.userConfig.promptOptions?[4,d.CustomLink.initialize(OneSignal.config.userConfig.promptOptions.customlink)]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}})})},e.triggerSubscriptionChanged=function(e){s.default.trigger(OneSignal.EVENTS.SUBSCRIPTION_CHANGED,e)},e.fireStoredNotificationClicks=function(e){return void 0===e&&(e=document.URL),i(this,void 0,void 0,function(){function t(e){return i(this,void 0,void 0,function(){var t,n,i;return r(this,function(r){switch(r.label){case 0:return[4,c.default.getAppState()];case 1:return(t=r.sent()).clickedNotifications[e.url]=null,[4,c.default.setAppState(t)];case 2:return r.sent(),n=e.data,(i=e.timestamp)&&(Date.now()-i)/1e3/60>5?[2]:(s.default.trigger(OneSignal.EVENTS.NOTIFICATION_CLICKED,n),[2])}})})}var n,o,a,u,l,d;return r(this,function(i){switch(i.label){case 0:return[4,c.default.getAppState()];case 1:return n=i.sent(),[4,c.default.get("Options","notificationClickHandlerMatch")];case 2:if("origin"!==i.sent())return[3,7];o=0,a=Object.keys(n.clickedNotifications),i.label=3;case 3:return o0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]1}return e.prototype.getDeviceId=function(){return r(this,void 0,void 0,function(){var e;return o(this,function(t){switch(t.label){case 0:return[4,f.default.getSubscription()];case 1:if(!(e=t.sent().deviceId))throw new l.NotSubscribedError(l.NotSubscribedReason.NoDeviceId);return[2,e]}})})},e.prototype.createDeviceRecord=function(){return r(this,void 0,void 0,function(){var e,t;return o(this,function(n){switch(n.label){case 0:return(e=new c.PushDeviceRecord).appId=this.context.appConfig.appId,t=e,[4,d.default.getCurrentNotificationType()];case 1:return t.subscriptionState=n.sent(),[2,e]}})})},e.prototype.sendPlayerUpdate=function(e){return r(this,void 0,void 0,function(){var t;return o(this,function(n){switch(n.label){case 0:return[4,this.context.subscriptionManager.isAlreadyRegisteredWithOneSignal()];case 1:return n.sent()?[4,this.getDeviceId()]:(p.default.debug("Not sending the update because user is not registered with OneSignal (no device id)"),[2]);case 2:return t=n.sent(),e?[3,4]:[4,this.createDeviceRecord()];case 3:e=n.sent(),n.label=4;case 4:return this.onSessionSent?[4,a.default.updatePlayer(this.context.appConfig.appId,t,i({notification_types:u.SubscriptionStateKind.Subscribed},e.serialize()))]:[3,6];case 5:return n.sent(),[3,8];case 6:return[4,this.sendOnSessionUpdate(e)];case 7:n.sent(),n.label=8;case 8:return[2]}})})},e.prototype.sendOnSessionUpdate=function(e){return r(this,void 0,void 0,function(){var t,n;return o(this,function(i){switch(i.label){case 0:return this.onSessionSent?[2]:this.context.sessionManager.isFirstPageView()?[4,this.context.subscriptionManager.isAlreadyRegisteredWithOneSignal()]:[2];case 1:return i.sent()?[4,this.getDeviceId()]:(p.default.debug("Not sending the on session because user is not registered with OneSignal (no device id)"),[2]);case 2:return t=i.sent(),e?[3,4]:[4,this.createDeviceRecord()];case 3:e=i.sent(),i.label=4;case 4:if(e.subscriptionState!==u.SubscriptionStateKind.Subscribed&&!0!==OneSignal.config.enableOnSession)return[2];i.label=5;case 5:return i.trys.push([5,7,,8]),[4,a.default.updateUserSession(t,e)];case 6:return i.sent(),this.onSessionSent=!0,[3,8];case 7:return n=i.sent(),p.default.error('Failed to update user session. Error "'+n.message+'" '+n.stack),[3,8];case 8:return[2]}})})},e.prototype.sendPlayerCreate=function(e){return r(this,void 0,void 0,function(){var t,n;return o(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,a.default.createUser(e)];case 1:return(t=i.sent())?(p.default.info("Subscribed to web push and registered with OneSignal",e,t),this.onSessionSent=!0,[2,t]):(p.default.error("Failed to create user."),[2,void 0]);case 2:return n=i.sent(),p.default.error('Failed to create user. Error "'+n.message+'" '+n.stack),[2,void 0];case 3:return[2]}})})},e.prototype.onSessionAlreadyCalled=function(){return this.onSessionSent},e.prototype.sendExternalUserIdUpdate=function(e){return r(this,void 0,void 0,function(){var t;return o(this,function(n){switch(n.label){case 0:return[4,this.getDeviceId()];case 1:return t=n.sent(),[4,a.default.updatePlayer(this.context.appConfig.appId,t,{external_user_id:h.default.getValueOrDefault(e,"")})];case 2:return n.sent(),[2]}})})},e}();t.UpdateManager=g},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s,a=o(n(8));(s=t.SubscriptionErrorReason||(t.SubscriptionErrorReason={}))[s.InvalidSafariSetup=0]="InvalidSafariSetup",s[s.Blocked=1]="Blocked",s[s.Dismissed=2]="Dismissed";var u=function(e){function n(i){var r=this;switch(i){case t.SubscriptionErrorReason.InvalidSafariSetup:r=e.call(this,"The Safari site URL, icon size, or push certificate is invalid, or Safari is in a private session.")||this;break;case t.SubscriptionErrorReason.Blocked:r=e.call(this,"Notification permissions are blocked.")||this;break;case t.SubscriptionErrorReason.Dismissed:r=e.call(this,"The notification permission prompt was dismissed.")||this}return Object.setPrototypeOf(r,n.prototype),r}return r(n,e),n}(a.default);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(){}return e.prototype.isNewSubscription=function(){return this.existingW3cPushSubscription?!!this.existingW3cPushSubscription.w3cEndpoint!=!!this.w3cEndpoint||(!(!this.existingW3cPushSubscription.w3cEndpoint||!this.w3cEndpoint||this.existingW3cPushSubscription.w3cEndpoint.toString()===this.w3cEndpoint.toString())||(this.existingW3cPushSubscription.w3cP256dh!==this.w3cP256dh||this.existingW3cPushSubscription.w3cAuth!==this.w3cAuth)):!this.existingSafariDeviceToken||this.existingSafariDeviceToken!==this.safariDeviceToken},e.setFromW3cSubscription=function(t){var n=new e;if(t&&(n.w3cEndpoint=new URL(t.endpoint),t.getKey)){var i=null;try{i=t.getKey("p256dh")}catch(e){}var r=null;try{r=t.getKey("auth")}catch(e){}if(i){var o=btoa(String.fromCharCode.apply(null,new Uint8Array(i)));n.w3cP256dh=o}if(r){var s=btoa(String.fromCharCode.apply(null,new Uint8Array(r)));n.w3cAuth=s}}return n},e.prototype.setFromSafariSubscription=function(e){this.safariDeviceToken=e},e.prototype.serialize=function(){return{w3cEndpoint:this.w3cEndpoint?this.w3cEndpoint.toString():null,w3cP256dh:this.w3cP256dh,w3cAuth:this.w3cAuth,safariDeviceToken:this.safariDeviceToken,existingPushSubscription:this.existingW3cPushSubscription?this.existingW3cPushSubscription.serialize():null,existingSafariDeviceToken:this.existingSafariDeviceToken}},e.deserialize=function(t){var n=new e;if(!t)return n;try{n.w3cEndpoint=new URL(t.w3cEndpoint)}catch(e){}return n.w3cP256dh=t.w3cP256dh,n.w3cAuth=t.w3cAuth,n.existingW3cPushSubscription=void 0,t.existingW3cPushSubscription?n.existingW3cPushSubscription=e.deserialize(t.existingW3cPushSubscription):t.existingPushSubscription&&(n.existingW3cPushSubscription=e.deserialize(t.existingPushSubscription)),n.safariDeviceToken=t.safariDeviceToken,n.existingSafariDeviceToken=t.existingSafariDeviceToken,n},e}();t.RawPushSubscription=i},function(e,t,n){"use strict";var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var r=n(32),o=n(85),s=i(n(56)),a=i(n(1)),u=function(){function e(){}return e.getServiceWorkerManager=function(e){var t=e.appConfig,n=a.default.getBuildEnvPrefix(),i={workerAPath:new s.default("/"+n+"OneSignalSDKWorker.js"),workerBPath:new s.default("/"+n+"OneSignalSDKUpdaterWorker.js"),registrationOptions:{scope:"/"}};return t.userConfig&&(t.userConfig.path&&(i.workerAPath=new s.default(""+t.userConfig.path+n+t.userConfig.serviceWorkerPath),i.workerBPath=new s.default(""+t.userConfig.path+n+t.userConfig.serviceWorkerUpdaterPath)),t.userConfig.serviceWorkerParam&&(i.registrationOptions=t.userConfig.serviceWorkerParam)),new r.ServiceWorkerManager(e,i)},e.getSubscriptionManager=function(e){var t=e.appConfig,n={safariWebId:t.safariWebId,appId:t.appId,vapidPublicKey:t.vapidPublicKey,onesignalVapidPublicKey:t.onesignalVapidPublicKey};return new o.SubscriptionManager(e,n)},e}();t.ContextHelper=u,t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.base64ToUint8Array=function(e){for(var t=(e+"=".repeat((4-e.length%4)%4)).replace(/\-/g,"+").replace(/_/g,"/"),n=atob(t),i=new Uint8Array(n.length),r=0;r>18]+i[(258048&t)>>12]+i[(4032&t)>>6]+i[63&t];return 1==s?n+=i[(252&(t=r[a]))>>2]+i[(3&t)<<4]+"==":2==s&&(n+=i[(64512&(t=r[a]<<8|r[a+1]))>>10]+i[(1008&t)>>4]+i[(15&t)<<2]+"="),n},t.base64Encode=function(e){return btoa(encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,function(e,t){return String.fromCharCode("0x"+t)}))},t.base64Decode=function(e){return decodeURIComponent(atob(e).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]2&&(t=30),c.default.debug("("+s.default.getWindowEnv().toString()+") OneSignal: User dismissed the native notification prompt; reprompt after "+t+" days."),[4,a.default.put("Options",{key:"promptDismissCount",value:e})];case 4:return i.sent(),n=24*t*60,[2,u.default.setItem("onesignal-notification-prompt","dismissed",n)]}})})},e}();t.default=d},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(n,i){var r=e.call(this,"Registration of a Service Worker failed.")||this;return r.status=n,r.statusText=i,Object.setPrototypeOf(r,t.prototype),r}return r(t,e),t}(o(n(8)).default);t.ServiceWorkerRegistrationError=s,t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(21),r=function(){function e(e){if(!e)throw new i.InvalidArgumentError("path",i.InvalidArgumentReason.Empty);this.path=e.trim()}return e.prototype.getQueryString=function(){var e=this.path.indexOf("?");return-1===e?null:this.path.length>e?this.path.substring(e+1):null},e.prototype.getWithoutQueryString=function(){return this.path.split(e.QUERY_STRING)[0]},e.prototype.getFileName=function(){return this.getWithoutQueryString().split("\\").pop().split("/").pop()},e.prototype.getFileNameWithQuery=function(){return this.path.split("\\").pop().split("/").pop()},e.prototype.getFullPath=function(){return this.path},e.prototype.getPathWithoutFileName=function(){var e=this.getWithoutQueryString(),t=e.lastIndexOf(this.getFileName()),n=e.substring(0,t);return n=n.replace(/[\\\/]$/,"")},e}();t.default=r,r.QUERY_STRING="?"},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=n(4),a=o(n(33)),u=o(n(22)),c=o(n(0)),l=function(e){function t(t){var n=e.call(this,".onesignal-bell-launcher-message","onesignal-bell-launcher-message-opened",null,"hidden",["opacity","transform"],".onesignal-bell-launcher-message-body")||this;return n.bell=t,n.contentType="",n.queued=[],n}return r(t,e),Object.defineProperty(t,"TIMEOUT",{get:function(){return 2500},enumerable:!0,configurable:!0}),Object.defineProperty(t,"TYPES",{get:function(){return{TIP:"tip",MESSAGE:"message",QUEUED:"queued"}},enumerable:!0,configurable:!0}),t.prototype.display=function(e,t,n){var i=this;return void 0===n&&(n=0),c.default.debug("Calling %cdisplay("+e+", "+t+", "+n+").",s.getConsoleStyle("code")),(this.shown?this.hide():s.nothing()).then(function(){i.content=s.decodeHtmlEntities(t),i.contentType=e}).then(function(){return i.show()}).then(function(){return s.delay(n)}).then(function(){return i.hide()}).then(function(){i.content=i.getTipForState(),i.contentType="tip"})},t.prototype.getTipForState=function(){return this.bell.state===u.default.STATES.UNSUBSCRIBED?this.bell.text["tip.state.unsubscribed"]:this.bell.state===u.default.STATES.SUBSCRIBED?this.bell.text["tip.state.subscribed"]:this.bell.state===u.default.STATES.BLOCKED?this.bell.text["tip.state.blocked"]:void 0},t.prototype.enqueue=function(e){var t=this;return this.queued.push(s.decodeHtmlEntities(e)),new Promise(function(e){t.bell.badge.shown?t.bell.badge.hide().then(function(){return t.bell.badge.increment()}).then(function(){return t.bell.badge.show()}).then(e):(t.bell.badge.increment(),t.bell.initialized?t.bell.badge.show().then(e):e())})},t.prototype.dequeue=function(e){var t=this,n=this.queued.pop(e);return new Promise(function(e){t.bell.badge.shown?t.bell.badge.hide().then(function(){return t.bell.badge.decrement()}).then(function(e){return e>0?t.bell.badge.show():Promise.resolve(t)}).then(e(n)):(t.bell.badge.decrement(),e(n))})},t}(a.default);t.default=l},function(e,t,n){"use strict";var i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=63&&(a.default.tablet||a.default.mobile)||a.default.safari&&Number(a.default.version)>=12.1)?[4,e.finishSessionInit(t)]:[3,8];case 7:return i.sent(),OneSignal.privateShowHttpPrompt(),[3,11];case 8:return[4,e.finishSessionInit(t)];case 9:return i.sent(),[4,y.default.registerForPush()];case 10:i.sent(),i.label=11;case 11:return[3,16];case 12:return t.__fromRegister?[4,e.finishSessionInit(t)]:[3,14];case 13:return i.sent(),OneSignal.setSubscription(!0),[3,16];case 14:return[4,e.finishSessionInit(t)];case 15:i.sent(),i.label=16;case 16:return d.default.trigger("ON_SESSION"),[2];case 17:return!0!==OneSignal.config.userConfig.autoRegister&&M.default.debug("OneSignal: Not automatically showing popover because autoRegister is not specifically true."),S.default.isHttpPromptAlreadyShown()&&M.default.debug("OneSignal: Not automatically showing popover because it was previously shown in the same session."),!0!==OneSignal.config.userConfig.autoRegister||S.default.isHttpPromptAlreadyShown()?[3,19]:[4,OneSignal.privateShowHttpPrompt().catch(function(e){e instanceof c.InvalidStateError&&e.reason===c.InvalidStateReason[c.InvalidStateReason.RedundantPermissionMessage]||e instanceof l.default||e instanceof u.default||e instanceof P.default?M.default.debug("[Prompt Not Showing]",e):M.default.info(e)})];case 18:i.sent(),i.label=19;case 19:return[4,e.finishSessionInit(t)];case 20:return i.sent(),d.default.trigger("ON_SESSION"),[2]}})})},e.polyfillSafariFetch=function(){return r(this,void 0,void 0,function(){var e;return o(this,function(t){switch(t.label){case 0:if(!a.default.safari||void 0!==window.fetch)return[3,4];M.default.debug("Loading fetch polyfill for Safari.."),t.label=1;case 1:return t.trys.push([1,3,,4]),[4,(new E.DynamicResourceLoader).loadFetchPolyfill()];case 2:return t.sent(),M.default.debug("Done loading fetch polyfill."),[3,4];case 3:return e=t.sent(),M.default.debug("Error loading fetch polyfill:",e),[3,4];case 4:return[2]}})})},e.errorIfInitAlreadyCalled=function(){if(OneSignal._initCalled)throw new w.SdkInitError(w.SdkInitErrorKind.MultipleInitialization);OneSignal._initCalled=!0},e.loadSubscriptionPopup=function(e){return r(this,void 0,void 0,function(){return o(this,function(t){switch(t.label){case 0:return OneSignal.subscriptionPopupHost=new R.default(OneSignal.proxyFrameHost.url,e),[4,OneSignal.subscriptionPopupHost.load()];case 1:return t.sent(),[2]}})})},e}();t.default=W},function(e,t,n){"use strict";var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var r=n(3),o=i(n(1)),s=function(){function e(){}return e.promiseStub=function(){return{then:e.promiseStub,catch:e.promiseStub}},e.ensureBackwardsCompatibility=function(t){e.environmentPolyfill(t),e.postmams(t),t.syncHashedEmail=e.promiseStub},e.environmentPolyfill=function(e){e.environment={},e.environment.getEnv=function(){return""},e.environment.isPopup=function(){return o.default.getWindowEnv()===r.WindowEnvironmentKind.OneSignalSubscriptionPopup},e.environment.isIframe=function(){return o.default.getWindowEnv()===r.WindowEnvironmentKind.OneSignalProxyFrame}},e.postmams=function(e){var t=function(){this.messenger.message.apply(this.messenger,arguments)},n=function(){this.messenger.postMessage.apply(this.messenger,arguments)};function i(e){e.message=t,e.postMessage=n}e.proxyFrame&&(e.iframePostmam=e.proxyFrame,i(e.iframePostmam)),e.subscriptionPopup&&(e.popupPostmam=e.subscriptionPopup,i(e.popupPostmam)),e.subscriptionModal&&(e.modalPostmam=e.subscriptionModal,i(e.modalPostmam))},e}();t.default=s},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]1?[2,e[1]]:[4,h.default.getAppConfig()];case 1:return[2,t.sent().appId]}})})},e.setupMessageListeners=function(){var t=this;e.workerMessenger.on(c.WorkerMessengerCommand.WorkerVersion,function(t){m.default.debug("[Service Worker] Received worker version message."),e.workerMessenger.broadcast(c.WorkerMessengerCommand.WorkerVersion,u.default.version())}),e.workerMessenger.on(c.WorkerMessengerCommand.Subscribe,function(n){return r(t,void 0,void 0,function(){var t,i,r,s;return o(this,function(o){switch(o.label){case 0:return t=n,m.default.debug("[Service Worker] Received subscribe message."),[4,(i=new d.default(t)).subscriptionManager.subscribe(0)];case 1:return r=o.sent(),[4,i.subscriptionManager.registerSubscription(r)];case 2:return s=o.sent(),e.workerMessenger.broadcast(c.WorkerMessengerCommand.Subscribe,s.serialize()),[2]}})})}),e.workerMessenger.on(c.WorkerMessengerCommand.SubscribeNew,function(n){return r(t,void 0,void 0,function(){var t,i,r,s;return o(this,function(o){switch(o.label){case 0:return t=n,m.default.debug("[Service Worker] Received subscribe new message."),[4,(i=new d.default(t)).subscriptionManager.subscribe(1)];case 1:return r=o.sent(),[4,i.subscriptionManager.registerSubscription(r)];case 2:return s=o.sent(),e.workerMessenger.broadcast(c.WorkerMessengerCommand.SubscribeNew,s.serialize()),[2]}})})}),e.workerMessenger.on(c.WorkerMessengerCommand.AmpSubscriptionState,function(n){return r(t,void 0,void 0,function(){var t,n,i,r;return o(this,function(o){switch(o.label){case 0:return m.default.debug("[Service Worker] Received AMP subscription state message."),[4,self.registration.pushManager.getSubscription()];case 1:return(t=o.sent())?[3,2]:(e.workerMessenger.broadcast(c.WorkerMessengerCommand.AmpSubscriptionState,!1),[3,5]);case 2:return[4,self.registration.pushManager.permissionState(t.options)];case 3:return n=o.sent(),[4,h.default.getSubscription()];case 4:i=o.sent().optedOut,r=!!t&&"granted"===n&&!0!==i,e.workerMessenger.broadcast(c.WorkerMessengerCommand.AmpSubscriptionState,r),o.label=5;case 5:return[2]}})})}),e.workerMessenger.on(c.WorkerMessengerCommand.AmpSubscribe,function(){return r(t,void 0,void 0,function(){var t,n,i,r,s;return o(this,function(o){switch(o.label){case 0:return m.default.debug("[Service Worker] Received AMP subscribe message."),[4,e.getAppId()];case 1:return t=o.sent(),[4,S.ConfigHelper.getAppConfig({appId:t},p.default.downloadServerAppConfig)];case 2:return n=o.sent(),[4,(i=new d.default(n)).subscriptionManager.subscribe(0)];case 3:return r=o.sent(),[4,i.subscriptionManager.registerSubscription(r)];case 4:return s=o.sent(),e.workerMessenger.broadcast(c.WorkerMessengerCommand.AmpSubscribe,s.deviceId),[2]}})})}),e.workerMessenger.on(c.WorkerMessengerCommand.AmpUnsubscribe,function(){return r(t,void 0,void 0,function(){var t,n;return o(this,function(i){switch(i.label){case 0:return m.default.debug("[Service Worker] Received AMP unsubscribe message."),[4,e.getAppId()];case 1:return t=i.sent(),[4,S.ConfigHelper.getAppConfig({appId:t},p.default.downloadServerAppConfig)];case 2:return n=i.sent(),[4,new d.default(n).subscriptionManager.unsubscribe(1)];case 3:return i.sent(),e.workerMessenger.broadcast(c.WorkerMessengerCommand.AmpUnsubscribe,null),[2]}})})})},e.onPushReceived=function(t){m.default.debug("Called %conPushReceived("+JSON.stringify(t,null,4)+"):",w.Utils.getConsoleStyle("code"),t),t.waitUntil(e.parseOrFetchNotifications(t).then(function(t){if(!t||0==t.length)return m.default.debug("Because no notifications were retrieved, we'll display the last known notification, so long as it isn't the welcome notification."),e.displayBackupNotification();for(var n=[],i=0,r=t;i0))for(var n=0,i=t.buttons;n0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]
notification icon
'+this.options.actionMessage+'
',c.addDomElement("body","beforeend",'
'),c.addDomElement(this.container,"beforeend",'
'+i+"
"),c.addCssClass(this.container,s.default.mobile?"slide-up":"slide-down"),this.allowButton.addEventListener("click",this.onPopoverAllowed.bind(this)),this.cancelButton.addEventListener("click",this.onPopoverCanceled.bind(this)),a.default.trigger(e.EVENTS.SHOWN),r.label=2;case 2:return[2]}})})},e.prototype.onPopoverAllowed=function(t){return i(this,void 0,void 0,function(){return r(this,function(t){switch(t.label){case 0:return[4,a.default.trigger(e.EVENTS.ALLOW_CLICK)];case 1:return t.sent(),[2]}})})},e.prototype.onPopoverCanceled=function(t){a.default.trigger(e.EVENTS.CANCEL_CLICK),this.close()},e.prototype.close=function(){var t=this;c.addCssClass(this.container,"close-popover"),c.once(this.dialog,"animationend",function(n,i){n.target!==t.dialog||"slideDownExit"!==n.animationName&&"slideUpExit"!==n.animationName||(c.removeDomElement("#onesignal-popover-container"),i(),a.default.trigger(e.EVENTS.CLOSED))},!0)},e.prototype.getPlatformNotificationIcon=function(){return this.notificationIcons?c.isChromeLikeBrowser()||s.default.firefox||s.default.msedge?this.notificationIcons.chrome?this.notificationIcons.chrome:this.notificationIcons.firefox?this.notificationIcons.firefox:"default-icon":s.default.safari?this.notificationIcons.safari?this.notificationIcons.safari:this.notificationIcons.chrome?this.notificationIcons.chrome:"default-icon":void 0:"default-icon"},Object.defineProperty(e.prototype,"container",{get:function(){return document.querySelector("#onesignal-popover-container")},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"dialog",{get:function(){return document.querySelector("#onesignal-popover-dialog")},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"allowButton",{get:function(){return document.querySelector("#onesignal-popover-allow-button")},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"cancelButton",{get:function(){return document.querySelector("#onesignal-popover-cancel-button")},enumerable:!0,configurable:!0}),e}();t.default=l},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1] Host) Getting event listener count for ",t),e.reply(OneSignal.emitter.numberOfListeners(t)),!1},e.prototype.isSubscribed=function(){var e=this;return new Promise(function(t){e.messenger.message(OneSignal.POSTMAM_COMMANDS.IS_SUBSCRIBED,null,function(e){t(e.data)})})},e.prototype.unsubscribeFromPush=function(){var e=this;return new Promise(function(t){e.messenger.message(OneSignal.POSTMAM_COMMANDS.UNSUBSCRIBE_PROXY_FRAME,null,function(e){t()})})},e.prototype.getProxyServiceWorkerActiveState=function(){var e=this;return new Promise(function(t,n){e.message(OneSignal.POSTMAM_COMMANDS.SERVICE_WORKER_STATE,null,function(e){t(e.data)})})},e.prototype.runCommand=function(e){return i(this,void 0,void 0,function(){var t=this;return r(this,function(n){switch(n.label){case 0:return[4,new Promise(function(n,i){t.message(e,null,function(e){n(e.data)})})];case 1:return[2,n.sent()]}})})},e.prototype.message=function(){for(var e=[],t=0;t0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=i]:[2,!1];case 12:return[2]}})})},e.prototype.isSubscriptionExpiringForSecureIntegration=function(){return i(this,void 0,void 0,function(){var e,t,n,i,o,s;return r(this,function(r){switch(r.label){case 0:return[4,this.context.serviceWorkerManager.getActiveState()];case 1:return(e=r.sent())!==p.ServiceWorkerActiveState.WorkerA&&e!==p.ServiceWorkerActiveState.WorkerB?[2,!1]:[4,c.ServiceWorkerManager.getRegistration()];case 2:return(t=r.sent())&&t.pushManager?[4,t.pushManager.getSubscription()]:[2,!1];case 3:return(n=r.sent())&&n.expirationTime?[4,a.default.getSubscription()]:[2,!1];case 4:return(i=r.sent().createdAt)||(o=31536e6,i=(new Date).getTime()+o),s=i+(n.expirationTime-i)/2,[2,!!n.expirationTime&&((new Date).getTime()>=n.expirationTime||(new Date).getTime()>=s)]}})})},e.prototype.getSubscriptionState=function(){return i(this,void 0,void 0,function(){var t,n,i,o;return r(this,function(r){switch(r.label){case 0:if(e.isSafari())return[2,this.getSubscriptionStateForSecure()];switch(t=h.default.getWindowEnv(),t){case m.WindowEnvironmentKind.ServiceWorker:return[3,1]}return[3,4];case 1:return[4,self.registration.pushManager.getSubscription()];case 2:return n=r.sent(),[4,a.default.getSubscription()];case 3:return i=r.sent().optedOut,[2,{subscribed:!!n,optedOut:!!i}];case 4:return[4,h.default.getIntegration()];case 5:switch(o=r.sent(),o){case y.IntegrationKind.Secure:return[3,6];case y.IntegrationKind.SecureProxy:return[3,7];case y.IntegrationKind.InsecureProxy:return[3,11]}return[3,13];case 6:return[2,this.getSubscriptionStateForSecure()];case 7:switch(t){case m.WindowEnvironmentKind.OneSignalProxyFrame:case m.WindowEnvironmentKind.OneSignalSubscriptionPopup:case m.WindowEnvironmentKind.OneSignalSubscriptionModal:return[3,8]}return[3,9];case 8:return[2,this.getSubscriptionStateForSecure()];case 9:return[4,OneSignal.proxyFrameHost.runCommand(OneSignal.POSTMAM_COMMANDS.GET_SUBSCRIPTION_STATE)];case 10:return[2,r.sent()];case 11:return[4,this.getSubscriptionStateForInsecure()];case 12:return[2,r.sent()];case 13:throw new w.InvalidStateError(w.InvalidStateReason.UnsupportedEnvironment)}})})},e.prototype.getSubscriptionStateForSecure=function(){return i(this,void 0,void 0,function(){var t,n,i,o,s,u,l,d;return r(this,function(r){switch(r.label){case 0:return[4,a.default.getSubscription()];case 1:return t=r.sent(),n=t.deviceId,i=t.optedOut,e.isSafari()?(o=window.safari.pushNotification.permission(this.config.safariWebId),[2,{subscribed:!("granted"!==o.permission||!o.deviceToken||!n),optedOut:!!i}]):[4,this.context.serviceWorkerManager.getActiveState()];case 2:return s=r.sent(),[4,c.ServiceWorkerManager.getRegistration()];case 3:return u=r.sent(),[4,this.context.permissionManager.getNotificationPermission(this.context.appConfig.safariWebId)];case 4:return l=r.sent(),d=s===p.ServiceWorkerActiveState.WorkerA||s===p.ServiceWorkerActiveState.WorkerB,u?[2,{subscribed:!(!n||l!==g.NotificationPermission.Granted||!d),optedOut:!!i}]:[2,{subscribed:!1,optedOut:!!i}]}})})},e.prototype.getSubscriptionStateForInsecure=function(){return i(this,void 0,void 0,function(){var e,t,n,i,o;return r(this,function(r){switch(r.label){case 0:return[4,a.default.getSubscription()];case 1:return e=r.sent(),t=e.deviceId,n=e.subscriptionToken,i=e.optedOut,[4,this.context.permissionManager.getNotificationPermission(this.context.appConfig.safariWebId)];case 2:return o=r.sent(),[2,{subscribed:!(!t||!n||o!==g.NotificationPermission.Granted),optedOut:!!i}]}})})},e.prototype.registerFailedSubscription=function(e,t){return i(this,void 0,void 0,function(){return r(this,function(n){return t.sessionManager.isFirstPageView()&&(t.subscriptionManager.registerSubscription(new b.RawPushSubscription,e),t.sessionManager.incrementPageViewCount()),[2]})})},e}();t.SubscriptionManager=T},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0?t.bell.badge.hide().then(function(){return Promise.all([e.prototype.inactivate.call(t),t.resize("small")])}).then(function(){return t.bell.badge.show()}):Promise.all([e.prototype.inactivate.call(t),t.resize("small")])})},t.prototype.activate=function(){var t=this;return this.bell.badge.content.length>0?this.bell.badge.hide().then(function(){return Promise.all([e.prototype.activate.call(t),t.resize(t.bell.options.size)])}):Promise.all([e.prototype.activate.call(this),this.resize(this.bell.options.size)])},t}(l.default);t.default=f},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=o(n(10)),a=o(n(2)),u=o(n(1)),c=n(4),l=o(n(33)),d=o(n(22)),f=function(e){function t(t){var n=e.call(this,".onesignal-bell-launcher-dialog","onesignal-bell-launcher-dialog-opened",null,"hidden",["opacity","transform"],".onesignal-bell-launcher-dialog-body")||this;return n.bell=t,n.subscribeButtonId="#onesignal-bell-container .onesignal-bell-launcher #subscribe-button",n.unsubscribeButtonId="#onesignal-bell-container .onesignal-bell-launcher #unsubscribe-button",n.notificationIcons=null,n}return r(t,e),t.prototype.getPlatformNotificationIcon=function(){return this.notificationIcons?c.isChromeLikeBrowser()||s.default.firefox||s.default.msedge?this.notificationIcons.chrome||this.notificationIcons.safari:s.default.safari?this.notificationIcons.safari||this.notificationIcons.chrome:void 0:null},t.prototype.show=function(){var t=this;return this.updateBellLauncherDialogBody().then(function(){return e.prototype.show.call(t)})},Object.defineProperty(t.prototype,"subscribeButtonSelectorId",{get:function(){return"subscribe-button"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"unsubscribeButtonSelectorId",{get:function(){return"unsubscribe-button"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"subscribeButton",{get:function(){return this.element.querySelector("#"+this.subscribeButtonSelectorId)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"unsubscribeButton",{get:function(){return this.element.querySelector("#"+this.unsubscribeButtonSelectorId)},enumerable:!0,configurable:!0}),t.prototype.updateBellLauncherDialogBody=function(){var e=this;return OneSignal.getSubscription().then(function(t){c.clearDomElementChildren(document.querySelector(e.nestedContentSelector));var n="Nothing to show.",i="";if(e.bell.options.showCredit&&(i='
Powered by OneSignal
'),e.bell.state===d.default.STATES.SUBSCRIBED&&!0===t||e.bell.state===d.default.STATES.UNSUBSCRIBED&&!1===t){var r="";r=(l=e.getPlatformNotificationIcon())?'
':'
';var o="";o=e.bell.state!==d.default.STATES.SUBSCRIBED?'":'",n="

"+e.bell.text["dialog.main.title"]+'

'+r+'
'+o+"
"+i}else if(e.bell.state===d.default.STATES.BLOCKED){var l=null;s.default.chrome?s.default.mobile||s.default.tablet||(l="/bell/chrome-unblock.jpg"):s.default.firefox?l="/bell/firefox-unblock.jpg":s.default.safari?l="/bell/safari-unblock.jpg":s.default.msedge&&(l="/bell/edge-unblock.png");var f="";l&&(f=''),(s.default.mobile||s.default.tablet)&&s.default.chrome&&(f="
  1. Access Settings by tapping the three menu dots โ‹ฎ
  2. Click Site settings under Advanced.
  3. Click Notifications.
  4. Find and click this entry for this website.
  5. Click Notifications and set it to Allow.
"),n="

"+e.bell.text["dialog.blocked.title"]+'

'+e.bell.text["dialog.blocked.message"]+"

"+f+"
"+i}c.addDomElement(document.querySelector(e.nestedContentSelector),"beforeend",n),e.subscribeButton&&e.subscribeButton.addEventListener("click",function(){OneSignal.__doNotShowWelcomeNotification=!1,a.default.trigger(d.default.EVENTS.SUBSCRIBE_CLICK)}),e.unsubscribeButton&&e.unsubscribeButton.addEventListener("click",function(){return a.default.trigger(d.default.EVENTS.UNSUBSCRIBE_CLICK)}),e.bell.setCustomColorsIfSpecified()})},t}(l.default);t.default=f},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=n(4),a=o(n(2)),u=o(n(34)),c=o(n(22)),l=o(n(24)),d=o(n(57)),f=o(n(17)),p=function(e){function t(t){var n=e.call(this,".onesignal-bell-launcher-button",null,null,"onesignal-bell-launcher-button-active",null,"shown","")||this;return n.bell=t,n.events={mouse:"bell.launcher.button.mouse"},n.element.addEventListener("touchstart",function(){n.onHovering(),n.onTap()},{passive:!0}),n.element.addEventListener("mouseenter",function(){n.onHovering()}),n.element.addEventListener("mouseleave",function(){n.onHovered()}),n.element.addEventListener("touchmove",function(){n.onHovered()},{passive:!0}),n.element.addEventListener("mousedown",function(){n.onTap()}),n.element.addEventListener("mouseup",function(){n.onEndTap()}),n.element.addEventListener("click",function(){n.onHovered(),n.onClick()}),n}return r(t,e),t.prototype.onHovering=function(){(l.default.isEmpty(this.events.mouse)||"out"===l.default.getLast(this.events.mouse))&&a.default.trigger(c.default.EVENTS.HOVERING),l.default.put(this.events.mouse,"over")},t.prototype.onHovered=function(){l.default.put(this.events.mouse,"out"),a.default.trigger(c.default.EVENTS.HOVERED)},t.prototype.onTap=function(){this.pulse(),this.activate(),this.bell.badge.activate()},t.prototype.onEndTap=function(){this.inactivate(),this.bell.badge.inactivate()},t.prototype.onClick=function(){var e=this;if(a.default.trigger(c.default.EVENTS.BELL_CLICK),a.default.trigger(c.default.EVENTS.LAUNCHER_CLICK),!this.bell.message.shown||this.bell.message.contentType!=d.default.TYPES.MESSAGE){var t=l.default.getLast("subscription.optedOut");return this.bell.unsubscribed?t?this.bell.launcher.activateIfInactive().then(function(){e.bell.showDialogProcedure()}):(f.default.registerForPushNotifications(),this.bell._ignoreSubscriptionState=!0,f.default.emitter.once(f.default.EVENTS.SUBSCRIPTION_CHANGED,function(){e.bell.message.display(d.default.TYPES.MESSAGE,e.bell.text["message.action.subscribed"],d.default.TIMEOUT).then(function(){e.bell._ignoreSubscriptionState=!1,e.bell.launcher.inactivate()})})):this.bell.subscribed?this.bell.launcher.activateIfInactive().then(function(){e.bell.showDialogProcedure()}):this.bell.blocked&&(s.isUsingSubscriptionWorkaround()?f.default.registerForPushNotifications():this.bell.launcher.activateIfInactive().then(function(){e.bell.showDialogProcedure()})),this.bell.message.hide()}},t.prototype.pulse=function(){s.removeDomElement(".pulse-ring"),s.addDomElement(this.element,"beforeend",'
'),this.bell.setCustomColorsIfSpecified()},t}(u.default);t.default=p},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(){return e.call(this,".onesignal-bell-launcher-badge","onesignal-bell-launcher-badge-opened",null,"onesignal-bell-launcher-badge-active",null,"hidden")||this}return r(t,e),t.prototype.increment=function(){if(!isNaN(this.content)){var e=+this.content;e+=1,this.content=e.toString()}},t.prototype.show=function(){var t=e.prototype.show.call(this);return OneSignal.notifyButton.setCustomColorsIfSpecified(),t},t.prototype.decrement=function(){if(!isNaN(this.content)){var e=+this.content;e-=1,this.content=e>0?e.toString():""}},t}(o(n(34)).default);t.default=s},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1] Host) User unsubscribed but permission granted. Re-prompting the user for push."),n.label=1;case 1:return n.trys.push([1,3,,4]),[4,g.unsubscribeFromPush()];case 2:return n.sent(),e.reply(OneSignal.POSTMAM_COMMANDS.REMOTE_OPERATION_COMPLETE),[3,4];case 3:return t=n.sent(),v.default.debug("Failed to unsubscribe from push remotely:",t),[3,4];case 4:return[2]}})})},t.prototype.onMarkPromptDismissed=function(e){return s(this,void 0,void 0,function(){return a(this,function(t){switch(t.label){case 0:return v.default.debug("(Reposted from iFrame -> Host) Marking prompt as dismissed."),[4,d.default.markHttpsNativePromptDismissed()];case 1:return t.sent(),e.reply(OneSignal.POSTMAM_COMMANDS.REMOTE_OPERATION_COMPLETE),[2,!1]}})})},t.prototype.onIsSubscribed=function(e){return s(this,void 0,void 0,function(){var t;return a(this,function(n){switch(n.label){case 0:return[4,OneSignal.isPushNotificationsEnabled()];case 1:return t=n.sent(),e.reply(t),[2,!1]}})})},t.prototype.onUnsubscribeProxyFrame=function(e){return s(this,void 0,void 0,function(){return a(this,function(t){switch(t.label){case 0:return[4,OneSignal.isPushNotificationsEnabled()];case 1:return t.sent()?[4,OneSignal.setSubscription(!1)]:[3,4];case 2:return t.sent(),[4,OneSignal.database.rebuild()];case 3:t.sent(),t.label=4;case 4:return e.reply(OneSignal.POSTMAM_COMMANDS.REMOTE_OPERATION_COMPLETE),[2,!1]}})})},t.prototype.onServiceWorkerState=function(e){return s(this,void 0,void 0,function(){var t;return a(this,function(n){switch(n.label){case 0:return[4,OneSignal.context.serviceWorkerManager.getActiveState()];case 1:return t=n.sent(),e.reply(t),[2,!1]}})})},t.prototype.onWorkerVersion=function(e){return s(this,void 0,void 0,function(){var t;return a(this,function(n){switch(n.label){case 0:return[4,OneSignal.context.serviceWorkerManager.getWorkerVersion()];case 1:return t=n.sent(),e.reply(t),[2,!1]}})})},t.prototype.onSubscriptionExpirationState=function(e){return s(this,void 0,void 0,function(){var t;return a(this,function(n){switch(n.label){case 0:return[4,OneSignal.context.subscriptionManager.isSubscriptionExpiring()];case 1:return t=n.sent(),e.reply(t),[2,!1]}})})},t.prototype.onProcessExpiringSubscriptions=function(e){return s(this,void 0,void 0,function(){return a(this,function(t){switch(t.label){case 0:return OneSignal.context,[4,l.default.processExpiringSubscriptions()];case 1:return t.sent(),e.reply(OneSignal.POSTMAM_COMMANDS.REMOTE_OPERATION_COMPLETE),[2,!1]}})})},t.prototype.onGetSubscriptionState=function(e){return s(this,void 0,void 0,function(){var t;return a(this,function(n){switch(n.label){case 0:return[4,OneSignal.context.subscriptionManager.getSubscriptionState()];case 1:return t=n.sent(),e.reply(t),[2,!1]}})})},t}(b.default);t.default=m},function(e,t,n){"use strict";var i=this&&this.__awaiter||function(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{u(i.next(e))}catch(e){o(e)}}function a(e){try{u(i.throw(e))}catch(e){o(e)}}function u(e){e.done?r(e.value):new n(function(t){t(e.value)}).then(s,a)}u((i=i.apply(e,t||[])).next())})},r=this&&this.__generator||function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=i[2&o[0]?"return":o[0]?"throw":"next"])&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[0,r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=(r=s.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]1)return o.default.warn("OneSignal: The web push SDK is included more than once. For optimal performance, please include our SDK only once on your page."),void o.default.debug("OneSignal: Exiting from SDK initialization to prevent double-initialization errors. Occurred "+s.getSdkLoadCount()+" times.");var e;if("undefined"!=typeof OneSignal&&(e=OneSignal),s.isPushNotificationsSupported()?window.OneSignal=n(17).default:(o.default.debug("OneSignal: Push notifications are not supported. A stubbed version of the SDK will be initialized."),window.OneSignal=r.default),e){if(!Array.isArray(e))return void o.default.error("'OneSignal' was not defined as an Array. Skipping pushes");for(var t=0,i=e;t -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - -**Note:** Version bump only for package @nuxtjs/pwa diff --git a/packages/pwa/README.md b/packages/pwa/README.md deleted file mode 100644 index 212ee9b8..00000000 --- a/packages/pwa/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. diff --git a/packages/pwa/index.js b/packages/pwa/index.js deleted file mode 100755 index b4feaecc..00000000 --- a/packages/pwa/index.js +++ /dev/null @@ -1,14 +0,0 @@ -const sequence = (tasks, fn) => tasks.reduce((promise, task) => promise.then(() => fn(task)), Promise.resolve()) - -module.exports = function nuxtPWA (options) { - const modules = ['icon', 'manifest', 'meta', 'workbox'].filter(module => options[module] !== false) - - return sequence(modules, module => { - return this.requireModule({ - src: `@nuxtjs/${module}`, - options: options[module] - }) - }) -} - -module.exports.meta = require('./package.json') diff --git a/packages/pwa/package.json b/packages/pwa/package.json deleted file mode 100755 index 97b27d2d..00000000 --- a/packages/pwa/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "@nuxtjs/pwa", - "version": "3.0.0-beta.16", - "license": "MIT", - "main": "index.js", - "repository": "https://github.com/nuxt-community/pwa-module", - "publishConfig": { - "access": "public" - }, - "dependencies": { - "@nuxtjs/icon": "3.0.0-beta.16", - "@nuxtjs/manifest": "3.0.0-beta.16", - "@nuxtjs/meta": "3.0.0-beta.16", - "@nuxtjs/pwa-utils": "3.0.0-beta.16", - "@nuxtjs/workbox": "3.0.0-beta.16" - } -} diff --git a/packages/workbox/CHANGELOG.md b/packages/workbox/CHANGELOG.md deleted file mode 100644 index ded2b1a4..00000000 --- a/packages/workbox/CHANGELOG.md +++ /dev/null @@ -1,236 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -# [3.0.0-beta.16](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.15...v3.0.0-beta.16) (2019-05-07) - -**Note:** Version bump only for package @nuxtjs/workbox - - - - - -# [3.0.0-beta.15](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.14...v3.0.0-beta.15) (2019-05-07) - - -### Bug Fixes - -* **workbox:** disable `cacheAssets` for dev mode ([dbf6d67](https://github.com/nuxt-community/pwa-module/commit/dbf6d67)) -* **workbox:** use NetworkFirst for dev ([9a67580](https://github.com/nuxt-community/pwa-module/commit/9a67580)) - - -### Features - -* **workbox:** offlineStrategy ([e377436](https://github.com/nuxt-community/pwa-module/commit/e377436)) - - -### Reverts - -* remove unnecessary hmr regex ([1ac5f5c](https://github.com/nuxt-community/pwa-module/commit/1ac5f5c)) - - -### BREAKING CHANGES - -* **workbox:** default changed from NetworkOnly to NetworkFirst when offlinePage is enabled - - - - - -# [3.0.0-beta.14](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.13...v3.0.0-beta.14) (2019-03-17) - - -### Features - -* **workbox:** make plugin fully asynchronous ([1eb1190](https://github.com/nuxt-community/pwa-module/commit/1eb1190)) -* improve computed cacheId ([cd6c9cc](https://github.com/nuxt-community/pwa-module/commit/cd6c9cc)) -* improve sw.register error handling ([9aa76f8](https://github.com/nuxt-community/pwa-module/commit/9aa76f8)) - - - - - -# [3.0.0-beta.13](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.12...v3.0.0-beta.13) (2019-03-17) - - -### Features - -* **workbox:** improve sw.register ([c35f610](https://github.com/nuxt-community/pwa-module/commit/c35f610)) -* sync workbox version with workbox-window ([9a3632a](https://github.com/nuxt-community/pwa-module/commit/9a3632a)) - - - - - -# [3.0.0-beta.12](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.11...v3.0.0-beta.12) (2019-03-05) - -**Note:** Version bump only for package @nuxtjs/workbox - - - - - -# [3.0.0-beta.11](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.10...v3.0.0-beta.11) (2019-03-05) - - -### Bug Fixes - -* **workbox:** always prepend routerBase to swURL ([d3a52b6](https://github.com/nuxt-community/pwa-module/commit/d3a52b6)), closes [#157](https://github.com/nuxt-community/pwa-module/issues/157) - - -### Features - -* **workbox:** allow cache names to be configured ([#154](https://github.com/nuxt-community/pwa-module/issues/154)) ([2d7ed53](https://github.com/nuxt-community/pwa-module/commit/2d7ed53)) -* **workbox:** workbox-window support ([2e356d0](https://github.com/nuxt-community/pwa-module/commit/2e356d0)) - - - - - -# [3.0.0-beta.10](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.9...v3.0.0-beta.10) (2019-02-27) - - -### Features - -* **workbox:** use workbox 4.0.0-0 ([70813ef](https://github.com/nuxt-community/pwa-module/commit/70813ef)) - - - - - -# [3.0.0-beta.9](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.8...v3.0.0-beta.9) (2019-02-27) - -**Note:** Version bump only for package @nuxtjs/workbox - - - - - -# [3.0.0-beta.8](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.7...v3.0.0-beta.8) (2019-02-18) - -**Note:** Version bump only for package @nuxtjs/workbox - - - - - -# [3.0.0-beta.7](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.6...v3.0.0-beta.7) (2019-02-17) - - -### Bug Fixes - -* **module:** handle readJSFiles for string param ([#143](https://github.com/nuxt-community/pwa-module/issues/143)) ([4f06479](https://github.com/nuxt-community/pwa-module/commit/4f06479)) - - -### Features - -* **workbox:** bump to 4.0.0-rc.2 ([7e278f0](https://github.com/nuxt-community/pwa-module/commit/7e278f0)) - - - - - -# [3.0.0-beta.6](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2019-02-08) - - -### Bug Fixes - -* relax pages regex for workbox 4 compatiblity ([04e74a7](https://github.com/nuxt-community/pwa-module/commit/04e74a7)) - - -### Features - -* cleanupOutdatedCaches ([9167013](https://github.com/nuxt-community/pwa-module/commit/9167013)) -* **workbox:** assetsURLPattern, pagesURLPattern ([5fc3d66](https://github.com/nuxt-community/pwa-module/commit/5fc3d66)) -* **workbox:** preCaching option ([67f1c3d](https://github.com/nuxt-community/pwa-module/commit/67f1c3d)) -* **workbox:** upgrade workboxVersion to 4.0.0-rc.0 ([b364572](https://github.com/nuxt-community/pwa-module/commit/b364572)) - - - - - -# [3.0.0-beta.5](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.3...v3.0.0-beta.5) (2019-02-08) - - -### Bug Fixes - -* add workboxExtensions to defaults ([#138](https://github.com/nuxt-community/pwa-module/issues/138)) ([ac8ba74](https://github.com/nuxt-community/pwa-module/commit/ac8ba74)) - - - - - -# [3.0.0-beta.3](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2019-02-07) - - -### Features - -* options.dev ([fb0d38c](https://github.com/nuxt-community/pwa-module/commit/fb0d38c)) - - - - - -# [3.0.0-beta.2](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2019-02-07) - - -### Features - -* offlineAnalytics ([#55](https://github.com/nuxt-community/pwa-module/issues/55)) ([4c4d3ff](https://github.com/nuxt-community/pwa-module/commit/4c4d3ff)) -* workboxExtensions and extension reading fixes ([5c56484](https://github.com/nuxt-community/pwa-module/commit/5c56484)) - - - - - -# [3.0.0-beta.1](https://github.com/nuxt-community/pwa-module/compare/v3.0.0-beta.0...v3.0.0-beta.1) (2019-02-07) - - -### Features - -* use better regexes ([318228e](https://github.com/nuxt-community/pwa-module/commit/318228e)) - - - - - -# [3.0.0-beta.0](https://github.com/nuxt-community/pwa-module/compare/v2.6.0...v3.0.0-beta.0) (2019-02-04) - - -### Bug Fixes - -* routing order for default offline route (/.*). it must be last order ([#100](https://github.com/nuxt-community/pwa-module/issues/100)) ([1c829d0](https://github.com/nuxt-community/pwa-module/commit/1c829d0)) - - -### chore - -* only support nuxt.hook ([854d826](https://github.com/nuxt-community/pwa-module/commit/854d826)) - - -### Features - -* rewrite workbox ([#122](https://github.com/nuxt-community/pwa-module/issues/122)) ([9e49896](https://github.com/nuxt-community/pwa-module/commit/9e49896)) -* **workbox:** change the order of default runtimeCache ([#106](https://github.com/nuxt-community/pwa-module/issues/106)) ([033b504](https://github.com/nuxt-community/pwa-module/commit/033b504)) - - -### BREAKING CHANGES - -* needs nuxt 2.x or later - - - - - - -# [2.6.0](https://github.com/nuxt-community/pwa-module/compare/v2.5.0...v2.6.0) (2018-09-21) - - -### Bug Fixes - -* **workbox:** add missing lodash dependency ([#91](https://github.com/nuxt-community/pwa-module/issues/91)) ([da2c36f](https://github.com/nuxt-community/pwa-module/commit/da2c36f)) - - -### Features - -* **workbox:** support pass config object to `workbox.setConfig` ([#95](https://github.com/nuxt-community/pwa-module/issues/95)) ([b5dab8a](https://github.com/nuxt-community/pwa-module/commit/b5dab8a)) diff --git a/packages/workbox/README.md b/packages/workbox/README.md deleted file mode 100644 index 212ee9b8..00000000 --- a/packages/workbox/README.md +++ /dev/null @@ -1 +0,0 @@ -๐Ÿ‘‰ Please refer to [nuxt-community/pwa-module](https://github.com/nuxt-community/pwa-module) for documentation. diff --git a/packages/workbox/package.json b/packages/workbox/package.json deleted file mode 100644 index 35dadffc..00000000 --- a/packages/workbox/package.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "name": "@nuxtjs/workbox", - "version": "3.0.0-beta.16", - "license": "MIT", - "main": "lib/module.js", - "repository": "https://github.com/nuxt-community/pwa-module", - "publishConfig": { - "access": "public" - }, - "dependencies": { - "@nuxtjs/pwa-utils": "3.0.0-beta.16", - "workbox-cdn": "^4.3.1" - } -} diff --git a/test/__snapshots__/pwa.test.js.snap b/test/__snapshots__/pwa.test.js.snap index 52054281..cb4b5c60 100644 --- a/test/__snapshots__/pwa.test.js.snap +++ b/test/__snapshots__/pwa.test.js.snap @@ -92,7 +92,7 @@ workbox.precaching.precacheAndRoute([ \\"/offline.png\\", \\"precache.js\\" ], { - \\"cacheId\\": \\"nuxt-prod\\", + \\"cacheId\\": \\"@nuxtjs/pwa-prod\\", \\"directoryIndex\\": \\"/\\" }) diff --git a/test/fixture/nuxt.config.js b/test/fixture/nuxt.config.js index 0d80cc4b..dbe4f942 100644 --- a/test/fixture/nuxt.config.js +++ b/test/fixture/nuxt.config.js @@ -11,8 +11,7 @@ module.exports = { }, modules: [ - // '@nuxtjs/onesignal', - '@nuxtjs/pwa' + require('../..') ], manifest: { diff --git a/test/pwa.test.js b/test/pwa.test.js index a4124e15..cbe82c06 100644 --- a/test/pwa.test.js +++ b/test/pwa.test.js @@ -1,9 +1,7 @@ const klawSync = require('klaw-sync') const path = require('path') const fs = require('fs-extra') -const { Nuxt, Builder, Generator } = require('nuxt-edge') - -jest.setTimeout(60000) +const { Nuxt, Builder } = require('nuxt-edge') const getRelativePath = fileObj => path.relative(__dirname, fileObj.path) @@ -12,17 +10,17 @@ const noJS = item => !/\.js/.test(item) describe('pwa', () => { let nuxt - test( - 'build and generate', async () => { - nuxt = new Nuxt(require('./fixture/nuxt.config')) - await nuxt.ready() - - const builder = new Builder(nuxt) - await builder.build() - - const generator = new Generator(nuxt) - await generator.generate({ build: false }) - }) + test('build project', async () => { + nuxt = new Nuxt(require('./fixture/nuxt.config')) + await nuxt.ready() + + // Generate before running tests as a known issue + // Build for more coverage + const builder = new Builder(nuxt) + await builder.build() + // const generator = new Generator(nuxt) + // await generator.generate({ build: false }) + }, 60000) test('build files (.nuxt)', async () => { const buildFiles = klawSync(nuxt.options.buildDir).map(getRelativePath) diff --git a/yarn.lock b/yarn.lock index 5b6dcf94..923d177d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2034,9 +2034,9 @@ stack-trace "0.0.10" "@octokit/endpoint@^5.1.0": - version "5.1.3" - resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-5.1.3.tgz#b503e56c74663a601e6e03c8eb6d143f4653d34d" - integrity sha512-ePx9kcUo0agRk0HaXhl+pKMXpBH1O3CAygwWIh7GT5i5kcUr8QowS0GBaZPirr1e0PqaFYr41hQfcUBA1R5AEQ== + version "5.1.5" + resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-5.1.5.tgz#a9505b835fae98dde5f4b63e53b1605b63424d1a" + integrity sha512-Es0Qj6ynp0mznTnayCX8veXev43/fGjwVvctynwgzcnW+KIK6nrHdqQXUnAA1Az0DsRgbGsh9fDHjP/3Ybfyyw== dependencies: deepmerge "3.2.0" is-plain-object "^3.0.0" @@ -2070,9 +2070,9 @@ universal-user-agent "^2.1.0" "@octokit/rest@^16.16.0": - version "16.27.1" - resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-16.27.1.tgz#7bdb988b71bb355ecedd22e9e3d8956eb89a10b9" - integrity sha512-/2XdHf/rjD0qw5mxiMP7ipo3vSx2WS716fOOydAIHFdl18Q06hkpz+5RAmfdrM34aoEd3NUExikAifz3kg9Fzw== + version "16.28.0" + resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-16.28.0.tgz#0bc39402cc8894519d8438101cae1fbe0e542452" + integrity sha512-9S9h/5tiu5vdrhHHyjXZrq826zaQcfci0O21+KRYL82Y6m8T64dZbYUAFiAlDOsQMtlWmgKmoGIJqWLlgySDdQ== dependencies: "@octokit/request" "^4.0.1" "@octokit/request-error" "^1.0.2" @@ -2450,7 +2450,14 @@ acorn@^6.0.1, acorn@^6.0.5, acorn@^6.0.7, acorn@^6.1.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.1.1.tgz#7d25ae05bb8ad1f9b699108e1094ecd7884adc1f" integrity sha512-jPTiwtOxaHNaAPg/dmrJ/beuzLRnXtB0kQPQ8JpotKJgTB6rX6c8mlf315941pyjBSaPg8NHXS9fhP4u17DpGA== -agent-base@4, agent-base@^4.1.0, agent-base@~4.2.1: +agent-base@4, agent-base@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.3.0.tgz#8165f01c436009bccad0b1d122f05ed770efc6ee" + integrity sha512-salcGninV0nPrwpGNn4VTXBb1SOuXQBiqbrNXoeizJsHrsL6ERFM2Ne3JUSBWRE6aeNJI2ROP/WEEIDUiDe3cg== + dependencies: + es6-promisify "^5.0.0" + +agent-base@~4.2.1: version "4.2.1" resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.2.1.tgz#d89e5999f797875674c07d87f260fc41e83e8ca9" integrity sha512-JVwXMr9nHYTUXsBFKUqhJwvlcYU/blreOEUkhNR2eXZIvwd+c+o5V4MgDPKWnMS/56awN3TRzIP+KoPn+roQtg== @@ -2758,15 +2765,16 @@ atob@^2.1.1: integrity sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg== autoprefixer@^9.4.9: - version "9.5.1" - resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.5.1.tgz#243b1267b67e7e947f28919d786b50d3bb0fb357" - integrity sha512-KJSzkStUl3wP0D5sdMlP82Q52JLy5+atf2MHAre48+ckWkXgixmfHyWmA77wFDy6jTHU6mIgXv6hAQ2mf1PjJQ== + version "9.6.0" + resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.6.0.tgz#0111c6bde2ad20c6f17995a33fad7cf6854b4c87" + integrity sha512-kuip9YilBqhirhHEGHaBTZKXL//xxGnzvsD0FtBQa6z+A69qZD6s/BAX9VzDF1i9VKDquTJDQaPLSEhOnL6FvQ== dependencies: - browserslist "^4.5.4" - caniuse-lite "^1.0.30000957" + browserslist "^4.6.1" + caniuse-lite "^1.0.30000971" + chalk "^2.4.2" normalize-range "^0.1.2" num2fraction "^1.2.2" - postcss "^7.0.14" + postcss "^7.0.16" postcss-value-parser "^3.3.1" aws-sign2@~0.7.0: @@ -2780,12 +2788,12 @@ aws4@^1.8.0: integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== axios@^0.18.0: - version "0.18.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.18.0.tgz#32d53e4851efdc0a11993b6cd000789d70c05102" - integrity sha1-MtU+SFHv3AoRmTts0AB4nXDAUQI= + version "0.18.1" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.18.1.tgz#ff3f0de2e7b5d180e757ad98000f1081b87bcea3" + integrity sha512-0BfJq4NSfQXd+SkFdrvFbG7addhYSBA2mQwISr46pD6E5iqkWg02RAs8vyTT/j0RTnoYmeXauBuSv1qKwR179g== dependencies: - follow-redirects "^1.3.0" - is-buffer "^1.1.5" + follow-redirects "1.5.10" + is-buffer "^2.0.2" babel-eslint@^10.0.1: version "10.0.1" @@ -3068,14 +3076,14 @@ browserify-zlib@^0.2.0: dependencies: pako "~1.0.5" -browserslist@^4.0.0, browserslist@^4.4.2, browserslist@^4.5.4, browserslist@^4.6.0: - version "4.6.1" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.1.tgz#ee5059b1aec18cbec9d055d6cb5e24ae50343a9b" - integrity sha512-1MC18ooMPRG2UuVFJTHFIAkk6mpByJfxCrnUyvSlu/hyQSFHMrlhM02SzNuCV+quTP4CKmqtOMAIjrifrpBJXQ== +browserslist@^4.0.0, browserslist@^4.4.2, browserslist@^4.6.0, browserslist@^4.6.1: + version "4.6.2" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.2.tgz#574c665950915c2ac73a4594b8537a9eba26203f" + integrity sha512-2neU/V0giQy9h3XMPwLhEY3+Ao0uHSwHvU8Q1Ea6AgLVL1sXbX3dzPrJ8NWe5Hi4PoTkCYXOtVR9rfRLI0J/8Q== dependencies: - caniuse-lite "^1.0.30000971" - electron-to-chromium "^1.3.137" - node-releases "^1.1.21" + caniuse-lite "^1.0.30000974" + electron-to-chromium "^1.3.150" + node-releases "^1.1.23" bser@^2.0.0: version "2.0.0" @@ -3282,10 +3290,10 @@ caniuse-api@^3.0.0: lodash.memoize "^4.1.2" lodash.uniq "^4.5.0" -caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000939, caniuse-lite@^1.0.30000957, caniuse-lite@^1.0.30000967, caniuse-lite@^1.0.30000971: - version "1.0.30000971" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000971.tgz#d1000e4546486a6977756547352bc96a4cfd2b13" - integrity sha512-TQFYFhRS0O5rdsmSbF1Wn+16latXYsQJat66f7S7lizXW1PVpWJeZw9wqqVLIjuxDRz7s7xRUj13QCfd8hKn6g== +caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000939, caniuse-lite@^1.0.30000967, caniuse-lite@^1.0.30000971, caniuse-lite@^1.0.30000974: + version "1.0.30000974" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000974.tgz#b7afe14ee004e97ce6dc73e3f878290a12928ad8" + integrity sha512-xc3rkNS/Zc3CmpMKuczWEdY2sZgx09BkAxfvkxlAEBTqcMHeL8QnPqhKse+5sRTi3nrw2pJwToD2WvKn1Uhvww== capture-exit@^2.0.0: version "2.0.0" @@ -3349,9 +3357,9 @@ chokidar@^2.0.2: fsevents "^1.2.7" chokidar@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.0.0.tgz#6b538f0fd6d5d31d5dd2b59e05426bec0f49aa40" - integrity sha512-ebzWopcacB2J19Jsb5RPtMrzmjUZ5VAQnsL0Ztrix3lswozHbiDp+1Lg3AWSKHdwsps/W2vtshA/x3I827F78g== + version "3.0.1" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.0.1.tgz#98fe9aa476c55d9aea7841d6325ffdb30e95b40c" + integrity sha512-2ww34sJWehnbpV0Q4k4V5Hh7juo7po6z7LUWkcIQnSGN1lHOL8GGtLtfwabKvLFQw/hbSUQ0u6V7OgGYgBzlkQ== dependencies: anymatch "^3.0.1" async-each "^1.0.3" @@ -3360,7 +3368,7 @@ chokidar@^3.0.0: is-binary-path "^2.1.0" is-glob "^4.0.1" normalize-path "^3.0.0" - readdirp "^3.0.1" + readdirp "^3.0.2" optionalDependencies: fsevents "^2.0.6" @@ -3514,9 +3522,9 @@ color-string@^1.5.2: simple-swizzle "^0.2.2" color@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/color/-/color-3.1.1.tgz#7abf5c0d38e89378284e873c207ae2172dcc8a61" - integrity sha512-PvUltIXRjehRKPSy89VnDWFKY58xyhTLyxIg21vwQBI6qLwZNPmC8k3C1uytIgFKEpOIzN4y32iPm8231zFHIg== + version "3.1.2" + resolved "https://registry.yarnpkg.com/color/-/color-3.1.2.tgz#68148e7f85d41ad7649c5fa8c8106f098d229e10" + integrity sha512-vXTJhHebByxZn3lDvDJYw4lR5+uB3vuoHsuYA5AKuxRVn5wzzIfQKGLBmgdVRHKTJYeK5rvJcHnrd0Li49CFpg== dependencies: color-convert "^1.9.1" color-string "^1.5.2" @@ -4278,7 +4286,7 @@ debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.8, debug@^2.6.9: dependencies: ms "2.0.0" -debug@3.1.0: +debug@3.1.0, debug@=3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" integrity sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g== @@ -4383,6 +4391,11 @@ defu@^0.0.1: resolved "https://registry.yarnpkg.com/defu/-/defu-0.0.1.tgz#74dc4d64e401d7f95c6755fe98bc5cd688833a8f" integrity sha512-Pz9yznbSzVTNA67lcfqVnktROx2BrrBBcmQqGrfe0zdiN5pl5GQogLA4uaP3U1pR1LHIZpEYTAh2sn+v4rH1dA== +defu@^0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/defu/-/defu-0.0.3.tgz#bdc3ea1e1ab2120d4d4a129147f3ba9b7f9fe103" + integrity sha512-u/fe4fBwrD0KACvI0sYWTWFzooqONZq8ywPnK0ZkAgLNwaDTKpSWvMiiU4QmzhrQCXu8Y0+HIWP8amE18lsL4A== + delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -4601,10 +4614,10 @@ ejs@^2.6.1: resolved "https://registry.yarnpkg.com/ejs/-/ejs-2.6.1.tgz#498ec0d495655abc6f23cd61868d926464071aa0" integrity sha512-0xy4A/twfrRCnkhfk8ErDi5DqdAsAqeGxht4xkCUrsvhhbQNs7E+4jV0CN7+NKIY0aHE72+XvqtBIXzD31ZbXQ== -electron-to-chromium@^1.3.137: - version "1.3.139" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.139.tgz#17a149701d934bbb91d2aa4ae09e5270c38dc0ff" - integrity sha512-8cR7h6doIC/XLgPdsTM3BXpfWLzqrHS6jWrvWLsdZWZWFvVQQUJTbU/wUZsjRGK33OY5ZIiS1n6JbqowuWrmYg== +electron-to-chromium@^1.3.150: + version "1.3.152" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.152.tgz#8f1c08e101d58fe2ef72655481bbf8c83f9450fa" + integrity sha512-Ah10cGMWIXYD8aUTH2Y7lGRhaOFQLyWuxvXmCPCZCbUIGJ4swnNmT6P4aA8RTgUmNw9kmcDL6SoU8TZC4YuZGg== elliptic@^6.0.0: version "6.4.1" @@ -4720,9 +4733,9 @@ es-to-primitive@^1.2.0: is-symbol "^1.0.2" es6-promise@^4.0.3: - version "4.2.6" - resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.6.tgz#b685edd8258886365ea62b57d30de28fadcd974f" - integrity sha512-aRVgGdnmW2OiySVPUC9e6m+plolMAJKjZnQlCwNSuK5yQ0JN61DZSO1X1Ufd1foqWRAlig0rhduTCHe7sVtK5Q== + version "4.2.8" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" + integrity sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w== es6-promisify@^5.0.0: version "5.0.0" @@ -5308,12 +5321,12 @@ flush-write-stream@^1.0.0: inherits "^2.0.3" readable-stream "^2.3.6" -follow-redirects@^1.3.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.7.0.tgz#489ebc198dc0e7f64167bd23b03c4c19b5784c76" - integrity sha512-m/pZQy4Gj287eNy94nivy5wchN3Kp+Q5WgUPNy5lJSZ3sgkVKSYV/ZChMAQVIgx1SqfZ2zBZtPA2YlXIWxxJOQ== +follow-redirects@1.5.10: + version "1.5.10" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.5.10.tgz#7b7a9f9aea2fdff36786a94ff643ed07f4ff5e2a" + integrity sha512-0V5l4Cizzvqt5D44aTXbFZz+FtyXV1vrDN6qrelxtfYQKW0KO0W2T/hkE8xvGa/540LkZlkaUjO4ailYTFtHVQ== dependencies: - debug "^3.2.6" + debug "=3.1.0" for-each@^0.3.3: version "0.3.3" @@ -6187,6 +6200,11 @@ is-buffer@^1.1.5: resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== +is-buffer@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.3.tgz#4ecf3fcf749cbd1e472689e109ac66261a25e725" + integrity sha512-U15Q7MXTuZlrbymiz95PJpZxu8IlipAp4dtS3wOdgPXx3mqBnslrWU14kxfHB+Py/+2PVKSr37dMAgM2A4uArw== + is-callable@^1.1.3, is-callable@^1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" @@ -7585,9 +7603,9 @@ mime@1.6.0, mime@^1.3.4: integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== mime@^2.0.3, mime@^2.3.1, mime@^2.4.2: - version "2.4.3" - resolved "https://registry.yarnpkg.com/mime/-/mime-2.4.3.tgz#229687331e86f68924e6cb59e1cdd937f18275fe" - integrity sha512-QgrPRJfE+riq5TPZMcHZOtm8c6K/yYrMbKIoRfapfiGLxS8OTeIfRhUGW5LU7MlRa52KOAGCfUNruqLrIBvWZw== + version "2.4.4" + resolved "https://registry.yarnpkg.com/mime/-/mime-2.4.4.tgz#bd7b91135fc6b01cde3e9bae33d659b63d8857e5" + integrity sha512-LRxmNwziLPT828z+4YkNzloCFC2YM4wrB99k+AV5ZbEyfGNWfG8SO1FUXLmLDBSo89NrJZ4DIWeLjy1CHGhMGA== mimic-fn@^1.0.0: version "1.2.0" @@ -7646,7 +7664,7 @@ minimist@~0.0.1: resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= -minipass@^2.2.1, minipass@^2.3.4, minipass@^2.3.5: +minipass@^2.2.1, minipass@^2.3.5: version "2.3.5" resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.5.tgz#cacebe492022497f656b0f0f51e2682a9ed2d848" integrity sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA== @@ -7654,7 +7672,7 @@ minipass@^2.2.1, minipass@^2.3.4, minipass@^2.3.5: safe-buffer "^5.1.2" yallist "^3.0.0" -minizlib@^1.1.1: +minizlib@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.2.1.tgz#dd27ea6136243c7c880684e8672bb3a45fd9b614" integrity sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA== @@ -7714,11 +7732,16 @@ ms@2.0.0: resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= -ms@2.1.1, ms@^2.0.0, ms@^2.1.1: +ms@2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== +ms@^2.0.0, ms@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + multimatch@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/multimatch/-/multimatch-2.1.0.tgz#9c7906a22fb4c02919e2f5f75161b4cdbd4b2a2b" @@ -7904,10 +7927,10 @@ node-pre-gyp@^0.12.0: semver "^5.3.0" tar "^4" -node-releases@^1.1.21: - version "1.1.22" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.22.tgz#d90cd5adc59ab9b0f377d4f532b09656399c88bf" - integrity sha512-O6XpteBuntW1j86mw6LlovBIwTe+sO2+7vi9avQffNeIW4upgnaCVm6xrBWH+KATz7mNNRNNeEpuWB7dT6Cr3w== +node-releases@^1.1.23: + version "1.1.23" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.23.tgz#de7409f72de044a2fa59c097f436ba89c39997f0" + integrity sha512-uq1iL79YjfYC0WXoHbC/z28q/9pOl8kSHaXdWmAAc8No+bDwqkZbzIJz55g/MUsPgSGm9LZ7QSUbzTcH5tz47w== dependencies: semver "^5.3.0" @@ -9302,9 +9325,9 @@ postcss-values-parser@^2.0.0, postcss-values-parser@^2.0.1: uniq "^1.0.1" postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.16, postcss@^7.0.2, postcss@^7.0.5, postcss@^7.0.6: - version "7.0.16" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.16.tgz#48f64f1b4b558cb8b52c88987724359acb010da2" - integrity sha512-MOo8zNSlIqh22Uaa3drkdIAgUGEL+AD1ESiSdmElLUmE2uVDo1QloiT/IfW9qRw8Gw+Y/w69UVMGwbufMSftxA== + version "7.0.17" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.17.tgz#4da1bdff5322d4a0acaab4d87f3e782436bad31f" + integrity sha512-546ZowA+KZ3OasvQZHsbuEpysvwTZNGJv9EfyCQdsIDltPSWHAeTQ5fQy/Npi2ZDtLI3zs7Ps/p6wThErhm9fQ== dependencies: chalk "^2.4.2" source-map "^0.6.1" @@ -9734,10 +9757,10 @@ readdirp@^2.2.1: micromatch "^3.1.10" readable-stream "^2.0.2" -readdirp@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.0.1.tgz#14a8875883c5575c235579624a1e177cb0b1ec58" - integrity sha512-emMp13NEwWQQX1yeDgrzDNCSY7NHV6k9HTW0OhyQqOAzYacbqQhnmWiCYjxNPcqMTQ9k77oXQJp28jkytm3+jg== +readdirp@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.0.2.tgz#cba63348e9e42fc1bd334b1d2ef895b6a043cbd6" + integrity sha512-LbyJYv48eywrhOlScq16H/VkCiGKGPC2TpOdZCJ7QXnYEjn3NN/Oblh8QEU3vqfSRBB7OGvh5x45NKiVeNujIQ== dependencies: picomatch "^2.0.4" @@ -9958,9 +9981,9 @@ resolve@1.1.7: integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= resolve@^1.1.7, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.11.0, resolve@^1.2.0, resolve@^1.3.2, resolve@^1.5.0, resolve@^1.8.1: - version "1.11.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.0.tgz#4014870ba296176b86343d50b60f3b50609ce232" - integrity sha512-WL2pBDjqT6pGUNSUzMw00o4T7If+z4H2x3Gz893WoUQ5KW8Vr9txp00ykiP16VBaZF5+j/OcXJHZ9+PCvdiDKw== + version "1.11.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" + integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== dependencies: path-parse "^1.0.6" @@ -10013,9 +10036,9 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: inherits "^2.0.1" rsvp@^4.8.4: - version "4.8.4" - resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.8.4.tgz#b50e6b34583f3dd89329a2f23a8a2be072845911" - integrity sha512-6FomvYPfs+Jy9TfXmBpBuMWNH94SgCsZmJKcanySzgNNP6LjWxBvyLTa9KaMfDDM5oxRfrKDB0r/qeRsLwnBfA== + version "4.8.5" + resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.8.5.tgz#c8f155311d167f68f21e168df71ec5b083113734" + integrity sha512-nfMOlASu9OnRJo1mbEk2cz0D56a1MBNrJ7orjRZQG10XDyuvwksKbuXNp6qa+kbn839HwjwhBzhFmdsaEAfauA== run-async@^2.2.0: version "2.3.0" @@ -10769,17 +10792,17 @@ tapable@^1.0.0, tapable@^1.0.0-beta.5, tapable@^1.1.0: integrity sha512-4WK/bYZmj8xLr+HUCODHGF1ZFzsYffasLUgEiMBY4fgtltdO6B4WJtlSbPaDTLpYTcGVwM2qLnFTICEcNxs3kA== tar@^4, tar@^4.4.8: - version "4.4.8" - resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.8.tgz#b19eec3fde2a96e64666df9fdb40c5ca1bc3747d" - integrity sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ== + version "4.4.10" + resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.10.tgz#946b2810b9a5e0b26140cf78bea6b0b0d689eba1" + integrity sha512-g2SVs5QIxvo6OLp0GudTqEf05maawKUxXru104iaayWA09551tFCTI8f1Asb4lPfkBr91k07iL4c11XO3/b0tA== dependencies: chownr "^1.1.1" fs-minipass "^1.2.5" - minipass "^2.3.4" - minizlib "^1.1.1" + minipass "^2.3.5" + minizlib "^1.2.1" mkdirp "^0.5.0" safe-buffer "^5.1.2" - yallist "^3.0.2" + yallist "^3.0.3" teeny-request@^3.11.3: version "3.11.3" @@ -11102,9 +11125,9 @@ uglify-js@3.4.x: source-map "~0.6.1" uglify-js@^3.1.4, uglify-js@^3.5.1: - version "3.5.15" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.5.15.tgz#fe2b5378fd0b09e116864041437bff889105ce24" - integrity sha512-fe7aYFotptIddkwcm6YuA0HmknBZ52ZzOsUxZEdhhkSsz7RfjHDX2QDxwKTiv4JQ5t5NhfmpgAK+J7LiDhKSqg== + version "3.6.0" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5" + integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg== dependencies: commander "~2.20.0" source-map "~0.6.1" @@ -11541,9 +11564,9 @@ webpack-sources@^1.0.1, webpack-sources@^1.1.0, webpack-sources@^1.3.0: source-map "~0.6.1" webpack@^4.31.0: - version "4.32.2" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.32.2.tgz#3639375364a617e84b914ddb2c770aed511e5bc8" - integrity sha512-F+H2Aa1TprTQrpodRAWUMJn7A8MgDx82yQiNvYMaj3d1nv3HetKU0oqEulL9huj8enirKi8KvEXQ3QtuHF89Zg== + version "4.33.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.33.0.tgz#c30fc4307db432e5c5e3333aaa7c16a15a3b277e" + integrity sha512-ggWMb0B2QUuYso6FPZKUohOgfm+Z0sVFs8WwWuSH1IAvkWs428VDNmOlAxvHGTB9Dm/qOB/qtE5cRx5y01clxw== dependencies: "@webassemblyjs/ast" "1.8.5" "@webassemblyjs/helper-module-context" "1.8.5" @@ -11817,7 +11840,7 @@ yallist@^2.1.2: resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -yallist@^3.0.0, yallist@^3.0.2: +yallist@^3.0.0, yallist@^3.0.2, yallist@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.3.tgz#b4b049e314be545e3ce802236d6cd22cd91c3de9" integrity sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==