From c8675ecd845bf4a5321e92219d24f3701d50489d Mon Sep 17 00:00:00 2001 From: artisin Date: Thu, 15 Jun 2017 13:58:04 -0500 Subject: [PATCH] =?UTF-8?q?init(all):=20init=20commit=20=E2=86=92=20?= =?UTF-8?q?=E2=98=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .babelrc | 16 + .cz-config.js | 38 + .eslintrc.js | 206 ++ .gitattributes | 13 + .github/ISSUE_TEMPLATE.md | 13 + .github/PULL_REQUEST_TEMPLATE.md | 12 + .gitignore | 52 + .npmignore | 52 + .zappr.yml | 34 + CHANGELOG.md | 0 CONTRIBUTING.md | 102 + LICENSE.txt | 22 + README.md | 146 + __tests__/index.js | 56 + dist/firemap.js | 4300 ++++++++++++++++++++++++++++++ dist/firemap.js.map | 1 + dist/firemap.min.js | 26 + lib/draw-click-map.js | 65 + lib/draw-heat-map.js | 145 + lib/get-color.js | 49 + lib/get-convex-hull-polygon.js | 39 + lib/get-point-value.js | 66 + lib/index.js | 434 +++ package.json | 60 + webpack.config.js | 81 + yarn.lock | 4241 +++++++++++++++++++++++++++++ 26 files changed, 10269 insertions(+) create mode 100644 .babelrc create mode 100644 .cz-config.js create mode 100644 .eslintrc.js create mode 100644 .gitattributes create mode 100644 .github/ISSUE_TEMPLATE.md create mode 100644 .github/PULL_REQUEST_TEMPLATE.md create mode 100644 .gitignore create mode 100644 .npmignore create mode 100644 .zappr.yml create mode 100644 CHANGELOG.md create mode 100644 CONTRIBUTING.md create mode 100644 LICENSE.txt create mode 100644 README.md create mode 100644 __tests__/index.js create mode 100644 dist/firemap.js create mode 100644 dist/firemap.js.map create mode 100644 dist/firemap.min.js create mode 100644 lib/draw-click-map.js create mode 100644 lib/draw-heat-map.js create mode 100644 lib/get-color.js create mode 100644 lib/get-convex-hull-polygon.js create mode 100644 lib/get-point-value.js create mode 100644 lib/index.js create mode 100644 package.json create mode 100644 webpack.config.js create mode 100644 yarn.lock diff --git a/.babelrc b/.babelrc new file mode 100644 index 0000000..eaa74b5 --- /dev/null +++ b/.babelrc @@ -0,0 +1,16 @@ +{ + "presets": [ + ["env", { + "targets": { + "browsers": ["last 4 versions"] + }, + "include": ["transform-regenerator"] + }] + ], + "plugins": [ + ["transform-runtime", { + "polyfill": false, + "regenerator": true + }] + ] +} diff --git a/.cz-config.js b/.cz-config.js new file mode 100644 index 0000000..df7de03 --- /dev/null +++ b/.cz-config.js @@ -0,0 +1,38 @@ + +module.exports = { + types: [ + {value: 'chore', name: 'chore: Changes to the build process or auxiliary tools\n and libraries such as documentation generation'}, + {value: 'docs', name: 'docs: Documentation only changes'}, + {value: 'feat', name: 'feat: A new feature'}, + {value: 'fix', name: 'fix: A bug fix'}, + {value: 'init', name: 'init: Initial commit'}, + {value: 'perf', name: 'perf: A code change that improves performance'}, + {value: 'refactor', name: 'refactor: A code change that neither fixes a bug nor adds a feature'}, + {value: 'release', name: 'release: A code release and tag'}, + {value: 'revert', name: 'revert: Revert to a commit'}, + {value: 'style', name: 'style: Changes that do not affect the meaning of the code\n (white-space, formatting, missing semi-colons, etc)'}, + {value: 'syntax', name: 'syntax: Spelling, grammar, punctuation, or mechanics'}, + {value: 'update', name: 'update: Updates feature'}, + {value: 'test', name: 'test: Adding missing tests'}, + {value: 'WIP', name: 'WIP: Work in progress'} + ], + // scopes: {Array of Strings}: Specify the scopes for your particular project. + // Eg.: for some banking system: ["acccounts", "payments"]. + // For another travelling application: ["bookings", "search", "profile"] + scopes: [ + {name: 'lib'}, + {name: '__scripts__'}, + {name: '__tests__'}, + {name: 'root'} + ], + // scopeOverrides: {Object where key contains a Array of String}: + // Use this when you want to override scopes for a specific commit type. + // Example bellow specify scopes when type is fix: + scopeOverrides: {}, + // allowCustomScopes: {boolean, default false}: adds the option custom to + // scope selection so you can still typea scope if you need. + allowCustomScopes: true, + // allowBreakingChanges: {Array of Strings: default none}. List of commit + // types you would like to the question breaking change prompted. Eg.: ['feat', 'fix'] + allowBreakingChanges: ['feat', 'fix'] +}; diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 0000000..4bc671c --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,206 @@ +module.exports = { + "env": { + "browser": true, + "commonjs": true, + "es6": true, + "node": true + }, + "extends": "eslint:recommended", + "parserOptions": { + "ecmaVersion": 2017, + "sourceType": "module", + "ecmaFeatures": { + "jsx": true + } + }, + "globals": { + "$": true, + "_": true, + "Immutable": true + }, + + "plugins": [ + // e.g. "react" (must run `npm install eslint-plugin-react` first) + "react" + ], + "rules": { + ////////// Possible Errors ////////// + + "comma-dangle": 2, // disallow trailing commas in object literals + "no-cond-assign": 2, // disallow assignment in conditional expressions + "no-console": 2, // disallow use of console (off by default in the node environment) + "no-constant-condition": 2, // disallow use of constant expressions in conditions + "no-control-regex": 2, // disallow control characters in regular expressions + "no-debugger": 2, // disallow use of debugger + "no-dupe-args": 2, // disallow duplicate arguments in functions + "no-dupe-keys": 2, // disallow duplicate keys when creating object literals + "no-duplicate-case": 2, // disallow a duplicate case label + "no-empty-character-class": 2, // disallow the use of empty character classes in regular expressions + "no-empty": 2, // disallow empty statements + "no-ex-assign": 2, // disallow assigning to the exception in a catch block + "no-extra-boolean-cast": 2, // disallow double-negation boolean casts in a boolean context + "no-extra-parens": 0, // disallow unnecessary parentheses (off by default) + "no-extra-semi": 2, // disallow unnecessary semicolons + "no-func-assign": 2, // disallow overwriting functions written as function declarations + "no-inner-declarations": 2, // disallow function or variable declarations in nested blocks + "no-invalid-regexp": 2, // disallow invalid regular expression strings in the RegExp constructor + "no-irregular-whitespace": 2, // disallow irregular whitespace outside of strings and comments + "no-negated-in-lhs": 2, // disallow negation of the left operand of an in expression + "no-obj-calls": 2, // disallow the use of object properties of the global object (Math and JSON) as functions + "no-regex-spaces": 2, // disallow multiple spaces in a regular expression literal + "no-reserved-keys": 0, // disallow reserved words being used as object literal keys (off by default) + "no-sparse-arrays": 2, // disallow sparse arrays + "no-unreachable": 2, // disallow unreachable statements after a return, throw, continue, or break statement + "use-isnan": 2, // disallow comparisons with the value NaN + "valid-jsdoc": 0, // Ensure JSDoc comments are valid (off by default) + "valid-typeof": 0, // Ensure that the results of typeof are compared against a valid string + "no-unexpected-multiline": 2, // Avoid code that looks like two expressions but is actually one (off by default) + ////////// Best Practices ////////// + + "accessor-pairs": 2, // enforces getter/setter pairs in objects (off by default) + "block-scoped-var": 2, // treat var statements as if they were block scoped (off by default) + "complexity": 2, // specify the maximum cyclomatic complexity allowed in a program (off by default) + "consistent-return": 0, // require return statements to either always or never specify values + "curly": 2, // specify curly brace conventions for all control statements + "default-case": 2, // require default case in switch statements (off by default) + "dot-notation": 2, // encourages use of dot notation whenever possible + "dot-location": 0, // enforces consistent newlines before or after dots (off by default) + "eqeqeq": 2, // require the use of === and !== + "guard-for-in": 2, // make sure for-in loops have an if statement (off by default) + "no-alert": 2, // disallow the use of alert, confirm, and prompt + "no-caller": 2, // disallow use of arguments.caller or arguments.callee + "no-div-regex": 2, // disallow division operators explicitly at beginning of regular expression (off by default) + "no-else-return": 2, // disallow else after a return in an if (off by default) + "no-eq-null": 2, // disallow comparisons to null without a type-checking operator (off by default) + "no-eval": 2, // disallow use of eval() + "no-extend-native": 2, // disallow adding to native types + "no-extra-bind": 2, // disallow unnecessary function binding + "no-fallthrough": 2, // disallow fallthrough of case statements + "no-floating-decimal": 2, // disallow the use of leading or trailing decimal points in numeric literals (off by default) + "no-implied-eval": 2, // disallow use of eval()-like methods + "no-iterator": 2, // disallow usage of __iterator__ property + "no-labels": 2, // disallow use of labeled statements + "no-lone-blocks": 2, // disallow unnecessary nested blocks + "no-loop-func": 2, // disallow creation of functions within loops + "no-multi-spaces": 0, // disallow use of multiple spaces + "no-multi-str": 2, // disallow use of multiline strings + "no-native-reassign": 2, // disallow reassignments of native objects + "no-new-func": 2, // disallow use of new operator for Function object + "no-new-wrappers": 2, // disallows creating new instances of String, Number, and Boolean + "no-new": 2, // disallow use of new operator when not part of the assignment or comparison + "no-octal-escape": 2, // disallow use of octal escape sequences in string literals, such as var foo = "Copyright \251"; + "no-octal": 2, // disallow use of octal literals + "no-param-reassign": 0, // disallow reassignment of function parameters (off by default) + "no-process-env": 2, // disallow use of process.env (off by default) + "no-proto": 2, // disallow usage of __proto__ property + "no-redeclare": 2, // disallow declaring the same variable more then once + "no-return-assign": 2, // disallow use of assignment in return statement + "no-script-url": 2, // disallow use of javascript: urls + "no-self-compare": 2, // disallow comparisons where both sides are exactly the same (off by default) + "no-sequences": 2, // disallow use of comma operator + "no-throw-literal": 2, // restrict what can be thrown as an exception (off by default) + "no-unused-expressions": 2, // disallow usage of expressions in statement position + "no-void": 2, // disallow use of void operator (off by default) + "no-warning-comments": 2, // disallow usage of configurable warning terms in comments, e.g. TODO or FIXME (off by default) + "no-with": 2, // disallow use of the with statement + "radix": 2, // require use of the second argument for parseInt() (off by default) + "vars-on-top": 2, // requires to declare all vars on top of their containing scope (off by default) + "wrap-iife": 2, // require immediate function invocation to be wrapped in parentheses (off by default) + "yoda": 2, // require or disallow Yoda conditions + + ////////// Variables ////////// + + "no-catch-shadow": 2, // disallow the catch clause parameter name being the same as a variable in the outer scope (off by default in the node environment) + "no-delete-var": 2, // disallow deletion of variables + "no-label-var": 2, // disallow labels that share a name with a variable + "no-shadow": 2, // disallow declaration of variables already declared in the outer scope + "no-shadow-restricted-names": 2, // disallow shadowing of names such as arguments + "no-undef": 2, // disallow use of undeclared variables unless mentioned in a /*global */ block + "no-undef-init": 2, // disallow use of undefined when initializing variables + "no-undefined": 2, // disallow use of undefined variable (off by default) + "no-unused-vars": 2, // disallow declaration of variables that are not used in the code + "no-use-before-define": 2, // disallow use of variables before they are defined + + + ////////// Node.js ////////// + + "handle-callback-err": 2, // enforces error handling in callbacks (off by default) (on by default in the node environment) + "no-mixed-requires": 2, // disallow mixing regular variable and require declarations (off by default) (on by default in the node environment) + "no-new-require": 2, // disallow use of new operator with the require function (off by default) (on by default in the node environment) + "no-path-concat": 2, // disallow string concatenation with __dirname and __filename (off by default) (on by default in the node environment) + "no-process-exit": 2, // disallow process.exit() (on by default in the node environment) + "no-restricted-modules": 2, // restrict usage of specified node modules (off by default) + "no-sync": 2, // disallow use of synchronous methods (off by default) + + + ////////// Stylistic Issues ////////// + + "array-bracket-spacing": 2, // enforce spacing inside array brackets (off by default) + "brace-style": [2, "1tbs", { // enforce one true brace style (off by default) + "allowSingleLine": true + }], + "camelcase": 2, // require camel case names + "comma-spacing": 2, // enforce spacing before and after comma + "comma-style": 2, // enforce one true comma style (off by default) + "computed-property-spacing": 2, // require or disallow padding inside computed properties (off by default) + "consistent-this": 0, // enforces consistent naming when capturing the current execution context (off by default) + "eol-last": 2, // enforce newline at the end of file, with no multiple empty lines + "func-names": 0, // require function expressions to have a name (off by default) + "func-style": 2, // enforces use of function declarations or expressions (off by default) + "indent": [1, 2, { // this option sets a specific tab width for your code (off by default) + "SwitchCase": 2, + "VariableDeclarator": { "var": 2, "let": 2, "const": 3} + }], + "key-spacing": 2, // enforces spacing between keys and values in object literal properties + "lines-around-comment": 0, // enforces empty lines around comments (off by default) + "linebreak-style": 2, // disallow mixed 'LF' and 'CRLF' as linebreaks (off by default) + "max-nested-callbacks": 2, // specify the maximum depth callbacks can be nested (off by default) + "new-cap": 1, // require a capital letter for constructors + "new-parens": 2, // disallow the omission of parentheses when invoking a constructor with no arguments + "new-parens": 2, // disallow the omission of parentheses when invoking a constructor with no arguments + "newline-after-var": 0, // allow/disallow an empty newline after var statement (off by default) + "no-array-constructor": 2, // disallow use of the Array constructor + "no-continue": 1, // disallow use of the continue statement (off by default) + "no-inline-comments": 2, // disallow comments inline after code (off by default) + "no-lonely-if": 2, // disallow if as the only statement in an else block (off by default) + "no-mixed-spaces-and-tabs": 2, // disallow mixed spaces and tabs for indentation + "no-multiple-empty-lines": 0, // disallow multiple empty lines (off by default) + "no-nested-ternary": 2, // disallow nested ternary expressions (off by default) + "no-new-object": 2, // disallow use of the Object constructor + "no-spaced-func": 2, // disallow space between function identifier and application + "no-ternary": 0, // disallow the use of ternary operators (off by default) + "no-trailing-spaces": 2, // disallow trailing whitespace at the end of lines + "no-underscore-dangle": 0, // disallow dangling underscores in identifiers + "one-var": 0, // allow just one var statement per function (off by default) + "operator-assignment": 2, // require assignment operator shorthand where possible or prohibit it entirely (off by default) + "operator-linebreak": 0, // enforce operators to be placed before or after line breaks (off by default) + "padded-blocks": 0, // enforce padding within blocks (off by default) + "quotes": [2, "single"], // require quotes around object literal property names (off by default) + "quote-props": [2, "as-needed"], // specify whether double or single quotes should be used + "semi-spacing": [2, { // enforce spacing before and after semicolons + "before": false, + "after": true + }], + "semi": [2, "always"], // require or disallow use of semicolons instead of ASI + "sort-vars": 0, // sort variables within the same declaration block (off by default) + "space-after-keywords": 0, // require a space after certain keywords (off by default) + "space-before-blocks": 2, // require or disallow space before blocks (off by default) + "space-before-function-paren": 0, // require or disallow space before function opening parenthesis (off by default) + "space-in-parens": 2, // require or disallow spaces inside parentheses (off by default) + "space-infix-ops": 2, // require spaces around operators + "space-unary-ops": 2, // require or disallow spaces before/after unary operators (words on by default, nonwords off by default) + "spaced-comment": 0, // require or disallow a space immediately following the // or /* in a comment (off by default) + "wrap-regex": 2, // require regex literals to be wrapped in parentheses (off by default) + + + ////////// ECMAScript 6 ////////// + "require-await": 0, // Disallow async functions which have no await expression + "constructor-super": 2, // verify super() callings in constructors (off by default) + "generator-star-spacing": 2, // enforce the spacing around the * in generator functions (off by default) + "no-this-before-super": 2, // disallow to use this/super before super() calling in constructors (off by default) + "no-var": 2, // require let or const instead of var (off by default) + "object-shorthand": 0, // require method and property shorthand syntax for object literals (off by default) + "prefer-const": 1, // suggest using of const declaration for variables that are never modified after declared (off by default) + + } +}; diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..a4f3a46 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,13 @@ +# See https://help.github.com/articles/dealing-with-line-endings + +# These files are text and should be normalized (Convert crlf => lf) +*.md text +*.txt text +*.html text +*.css text +*.js text + +# Denote all files that are truly binary and should not be modified. +*.png binary +*.jpg binary +*.pdf binary diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..6de9dc4 --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,13 @@ + diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..4c50990 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,12 @@ +#### Description: + + + + + +#### Checklist: + +- [ ] Update/change/fix has/passes test(s) +- [ ] Follows the existing code style +- [ ] Has decent commit message +- [ ] Commit and code comes with a smile diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..753bc5c --- /dev/null +++ b/.gitignore @@ -0,0 +1,52 @@ +# Custom/library specific + + +# Global +*~ +# KDE directory preferences +.directory +# Linux trash folder which might appear on any partition or disk +.Trash-* +# cache files for sublime text +*.tmlanguage.cache +*.tmPreferences.cache +*.stTheme.cache +# workspace files are user-specific +*.sublime-workspace +# project files should be checked into the repository, unless a significant +# proportion of contributors will probably not be using SublimeText +# *.sublime-project +# sftp configuration file +sftp-config.json +# Logs +logs +*.log +npm-debug.log* +# Packages +node_modules/ +bower_components/ +# Misc +.DS_Store +.public +.publish +.directory +.temp +public +private +_private +.private +.iron-node.js +Desktop.ini +app/assets/stylesheets/generated +lib-cov +*.seed +*.log +*.csv +*.dat +*.out +*.pid +*.gz +pids +logs +results +tmp diff --git a/.npmignore b/.npmignore new file mode 100644 index 0000000..753bc5c --- /dev/null +++ b/.npmignore @@ -0,0 +1,52 @@ +# Custom/library specific + + +# Global +*~ +# KDE directory preferences +.directory +# Linux trash folder which might appear on any partition or disk +.Trash-* +# cache files for sublime text +*.tmlanguage.cache +*.tmPreferences.cache +*.stTheme.cache +# workspace files are user-specific +*.sublime-workspace +# project files should be checked into the repository, unless a significant +# proportion of contributors will probably not be using SublimeText +# *.sublime-project +# sftp configuration file +sftp-config.json +# Logs +logs +*.log +npm-debug.log* +# Packages +node_modules/ +bower_components/ +# Misc +.DS_Store +.public +.publish +.directory +.temp +public +private +_private +.private +.iron-node.js +Desktop.ini +app/assets/stylesheets/generated +lib-cov +*.seed +*.log +*.csv +*.dat +*.out +*.pid +*.gz +pids +logs +results +tmp diff --git a/.zappr.yml b/.zappr.yml new file mode 100644 index 0000000..2fa2998 --- /dev/null +++ b/.zappr.yml @@ -0,0 +1,34 @@ +# docs: https://zappr.readthedocs.io/en/latest/setup/ +approvals: + # PR needs at least 1 approvals + minimum: 1 + # approval = comment that matches this regex + pattern: "^(:\\+1:|πŸ‘|\\+1|LGTM)$" + veto: + # veto/blocking a PR = comment that matches this regex + pattern: "^(:\\-1:|πŸ‘Ž|\\-1|LBTM)$" + # note that `from` is by default empty, + # accepting any matching comment as approval + from: + # commenter must be either one of: + orgs: + # a public zalando org member + # (any org in here counts) + # - your-organization + # OR a collaborator of the repo + collaborators: true + # OR one of these guys + users: + - artisin +specification: + # title requirements + title: + # PR title is at least this many characters long + minimum-length: + enabled: true + length: 8 +commit: + message: + # commit message has to match any one of + patterns: + - "\\(.*?\\):" diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..e69de29 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..294a68b --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,102 @@ +# Contributing + +A healthy community is a contributing community, and contributions are welcomed and appreciated with open hearts and open fingers. First things first, make sure you [search the issue tracker](https://github.com/artisin/firemap/issues) to ensure your issue/fix/update has not previously been discussed and/or fixed in the `master`. Additionally, if you're planning to implement a new feature, change the API, or any change that will take over a handful of minutes, please create an issue first and wait for a response from one of the maintainers. Otherwise, there are no guarantees your hard work will be merged, and then we will feel shitty that you feel shitty since all your efforts will have been for naught. + + +## Issue Tracker + +The [issue tracker](https://github.com/artisin/firemap/issues) is the preferred channel for [bug reports](#bug-reports), [features requests](#feature-requests), and [submitting pull requests](#pull-requests). Please respect the following guidelines: + ++ Please **do not** use the issue tracker for personal support requests (use [Stack Overflow](https://stackoverflow.com/questions/tagged/firemap)). ++ Please **do not** post comments consisting solely of "+1" or ":+1:". ++ Keep the discussion on topic, respect the opinions of others, and most importantly don't be a prick; or in other words, don't be a fucking asshole. + + +## Bug Reports + +A "bug" is defined as a demonstrable problem that is caused by the code in the repository. If you find a bug, please report it so we can fix it. Remember, you're the first defense against the war on bugs. + +__Guidelines for bug reports__: + +1. Use the GitHub [issue](https://github.com/artisin/firemap/issues) search, and check if the issue has already been reported. +2. Try to reproduce the bug using the latest `master` (or `development` if present) branch in the repository. +3. Isolate the problem, and ideally, create a test case and/or upload the code to a repository or post the code inline if the size is reasonable. + +A good bug report shouldn't leave others needing to chase you down for more information. Please try to be as detailed as possible in your report. It's important you include the following: + ++ What's your environment? ++ Expected behavior ++ Actual behavior ++ What steps and/or code will reproduce the bug? ++ Have you identified what's causing the bug, and potential solutions or opinions? ++ Any other useful details that will help fix the potential bugs. + + +## Feature Requests + +Feature requests are welcomed. But take a moment to find out whether your idea fits with the scope and aims of the project. It's up to you to make a strong case and demonstrate the merits of this feature. Furthermore, provide as much detail and context as possible. + + +## Pull Requests + +1. [Fork](https://help.github.com/fork-a-repo/) the repository. + + ```bash + git clone https://github.com//firemap.git + cd firemap + git remote add upstream https://github.com/artisin/firemap.git + ``` + +2. Link `firemap`, to symlink the package folder during development. + + ```bash + yarn run link + ``` + +3. Install the dependencies. Make sure you have [yarn](https://yarnpkg.com) [installed](https://yarnpkg.com/en/docs/install). + + ```bash + yarn install + ``` + +4. Create a new branch to contain your feature, change, or fix. + + ```bash + git checkout -b + ``` + +5. Commit your changes in logical chunks. + + To keep commits uniform, this project uses [commitizen](http://commitizen.github.io/cz-cli/), but don't worry if you've never heard about commitizen or don't know how to use it. Everything is pre-configured and ready for you to rock 'n' roll out of the box. Just follow these simple steps: + 1. Make your update/change/fix + 2. Add your changes `git add .` + 3. Run: `npm run commit` - An interactive command prompt will appear and lead you step-by-step through the whole process. It's easy peasy lemon squeezy so don't worry about a thing. + + If commitizen does not work or for some extraneous reason you wish not to use it your commit must follow the [angular commit](https://github.com/angular/angular.js/blob/master/CONTRIBUTING.md#-git-commit-guidelines) format: `(): `. Otherwise, your pull request will fail during approval, but it’s highly encouraged you use `npm run commit` to make everyone's life just a bit easier. + +6. Test changes and/or write test(s) to validate feature, change, or fix. + + ```bash + yarn run test + ``` + +7. Locally merge (or rebase) the upstream development branch into your topic branch. + + ```bash + git pull [--rebase] upstream master + ``` + +8. Push your topic branch up to your fork. + + ```bash + git push origin + ``` + +9. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/) with a clear title and description against the `master` branch. Suggestions, changes, or improvements may be required for your changes to be merged, but small pull requests should be accepted quickly. Ideally, your pull request meets the four pillars of quality: + 1. Update/change/fix has test(s) + 2. Follows the existing code style + 3. Has decent commit message(s) + 4. Commit, and code comes with a smile + + +# License + +**IMPORTANT:** By contributing your code, you agree to license your contribution under the [MIT](https://github.com/artisin/firemap/blob/master/LICENSE.txt) License. diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 0000000..0d270b7 --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,22 @@ +The MIT License + +Copyright (c) 2017 te schultz +https://github.com/artisin/firemap + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..530357a --- /dev/null +++ b/README.md @@ -0,0 +1,146 @@ +# FireMap + +FireMap is a refinement on the typical "heatmap" to help better visualize mouse position data through Inverse Distance Weighting. I created a companion website to display various FireMap example outputs along with some additional detail you can check out here: [https://firemap.netlify.com/](https://firemap.netlify.com/) + +Compared to [heatmap.js](https://www.patrick-wied.at/static/heatmapjs/?utm_source=gh) and other heatmap libraries there are two major differences. FireMap uses a standardized GIS algorithm compared to heatmap.js and others that use a density equation of some sort? This was the primary reason for creating FireMap since I thought it would be advantageous to employ a deterministic algorithm. Secondly, due to the calculation intensive nature of FireMap it's not intended to be used in real-time, although, it does have said capability. + +# Install + +You can install FireMap either through npm: + +```bash + npm install --save-dev firemap +``` + +Alternatively, you can manually download FireMap through the Github repository here: [github.com/artisin/firemap/dist/](https://github.com/artisin/firemap/dist) + + +# Initialize + +The FireMap class instance is exported through: `export default`; + +__ECMAScript 6 Module Syntax__ +```js +import FireMap from 'firemap'; +``` + +__CommonJS Syntax__ +```js +const FireMap = require('firemap').default; +``` + +__Create a New Instance__ + +FireMap is a Class, and as such, you must initialize it. The FireMap `constructor` accepts an option object argument to set the initial/default options. + +```js +// option-less +const firemap = new FireMap(); + +// options +const firemap = new FireMap({ + // if no canvas element is passed it defauls to the + // first getElementsByTagName('canvas') + canvas: document.getElementById('my-canvas-element'), + // changes sampling DOM area + area: 10 +}); +``` + +## Data Structure + +Typically you'll use FireMap in a post-event fashion using tracking data you've collected. However, you can draw a semi-real-time heatmap using the `realTime` method. There are two data types, `dataPoints` (mousemove) and `clickPoints` (pointerdown) that are either passed to the initial Class `constructor` or the `draw` method. + +__`dataPoints` β†’ Mouse Position Data__ + +```js +firemap.draw({ + dataPoints: [{ x: 10, y: 15, value: 5}, ...] +}) +``` + +__`clickPoints` β†’ Mouse Click Data__ + +```js +firemap.draw({ + clickPoints: [{ x: 20, y: 150}, ...] +}) +``` + +__Both__ + +```js +firemap.draw({ + dataPoints: [{ x: 10, y: 15, value: 5}, ...], + clickPoints: [{ x: 20, y: 150}, ...] +}) +``` + + +## Class Methods + +### Class Instance β†’ `constructor(options = {})` + +Creates a `FireMap` instance β€” many of these options can also be passed to the `draw` method. + ++ `options.dataPoints` = {arr} β†’ user data points for mouse (mousemove) ++ `options.clickPoints` = {arr} β†’ user data points for clicks (pointerdown) ++ `options.area` = {num} β†’ sampling area that clusters all points within its area into a single cluster default is 10 so 10px by 10px sample area ++ `options.canvas` = {dom} β†’ canvas dom element to draw map on ++ `options.cleanEdges` = {bln} β†’ cleans edges of polygon to remove rough edges to make it look pretty, only used if corners is false ++ `options.clickColor` = {str} β†’ color of the click point data stars ++ `options.clickSize` = {num} β†’ size of the click point data stars ++ `options.corners` = {num} β†’ creates pseudo data points for corner of the window so heatmap spans the entire screen ++ `options.height` = {num} β†’ height of canvas || screen height ++ `options.hue` = {num} β†’ color hue for map default is 0.5 green, 0.8 violet, 3.5 rgbiv and no non-point color ++ `options.interval` = {num} β†’ interpolation interval of unknown points, the lower the number the more points calculated - computation time increase by O(n2) where n is the number of data points ++ `options.limit` = {num} β†’ search neighborhood limit, higher number the smoother blend of map colors - has a minor increase in computation time ++ `options.maxValue` = {num} β†’ used for color, and the default is 100, so any value above 100 is going to be the same color ++ `options.mesh` = {bln} β†’ to create a mesh-like map rather then a solid map ++ `options.opacity` = {num} β†’ opacity of canvus fill ++ `options.points` = {bln} β†’ to draw data marker point coordinates ++ `options.pointSize` = {num} β†’ font-size of points in px ++ `options.styles` = {obj} β†’ custom CSS canvas styles ++ `options.subscribe` = {fnc} β†’ a subscribe function that is invoked on the mouse tracking & click event, passes the event and binded to this ++ `options.threshold` = {num} β†’ point label value threshold, if a values does not meet threshold no point label will be generated ++ `options.throttle` = {num} β†’ mouse tracker throttle ++ `options.width` = {num} β†’ width of canvas, defaults to current screen width + +### Draws/create Map β†’ `draw(options = {})` + +Draws/creates a heatmap for the canvas element using either passed in `dataPoints` or real-time data points through the invocation of the `draw` method or automatically through the `realTime` method. + +__IMPORTANT__: In all likelihood you don’t want data sets of over 1000+ data points because the computation time is O(n2) where n is the number of data points. With 1000-1500 points with an `interval` of `8` it takes 20-40 seconds to compute 1000-1500 data points and if you want a high quality render with an `interval` of `4` there will be two times as many calculations. If you are using FireMap to gather data points you can reduce data points by increasing the `area` (recommended) or increasing the `throttle`. + +__Options__ +These options can also be passed into the initial `constructor`. + ++ `options.dataPoints` = {arr} β†’ user data points for mouse (mousemove) ++ `options.clickPoints`= {arr} β†’ user data points for clicks (pointerdown) ++ `options.clickSize` = {num} β†’ size of the click point data stars ++ `options.clickColor` = {str} β†’ color of the click point data stars ++ `options.cb` = {fnc} β†’ Callback function invoked upon completion and binded to instance with the first arg being the canvas context (ctx) ++ `options.hue` = {num} β†’ color hue for map default is 0.5 green, 0.8 violet, 3.5 rgbiv and no non-point color ++ `options.interval` = {num} β†’ interpolation interval of unknown points, the lower the number the more points calculated - computation time increase by O(n2) where n is the number of data poi ++ `options.limit` = {num} β†’ search neighborhood limit, higher num smoother blend of map colors ++ `options.mesh` = {bln} β†’ to create a mesh-like map rather then a solid map ++ `options.opacity` = {num} β†’ opacity of canvus fill ++ `options.points` = {bln} β†’ to draw data marker point coordinates ++ `options.pointSize` = {num} β†’ font-size of points ++ `options.threshold` = {num} β†’ point values has to be higher than threshold + + +### Get/Format Data β†’ `getData()` + +The `getData` method converts the raw tracking data matrix into valid/formatted tracking data to be used by the `draw` method. However, you'll first need to initialize the tracking feature through the `init` method in order to generate said data to be formatted. The data is returned in an array that consists of objects `{x: , y: , value: }`. + + +### Initialize Mouse & Click Tracking β†’ `init(subscribe = fnc)` + +To use FireMaps built-in mouse position and click logging feature you need to invoke the `init` method. There're two primary ways to "log" this data to send to your server. You can dump the data via the `getData` method either on a leave event or poll event. Or you can subscribe to the raw event data through the `subscribe` function. If you choose the latter, you can pass a `subscribe` function to the `init` method or declare it via the `option` object in the class constructor. The `subscribe` function is binded to the instance so that you can access the internals through `this`. Additionally, the `subscribe` function is passed two arguments, the first is the raw event and the second is the type of event which will be a string of `'mousemove'` or `'pointerdown'`. + + +### Real Time Drawing β†’ `realTime(drawInterval = 10)` + +FireMap can also draw in real-time, but unlike [heatmap.js](https://www.patrick-wied.at/static/heatmapjs/?utm_source=gh), FireMap is not intended to draw in real time. The `drawInterval` determines how often the map should re-draw and the default is set at `10`, so that it re-draws every `10` new data points. + diff --git a/__tests__/index.js b/__tests__/index.js new file mode 100644 index 0000000..7f8c693 --- /dev/null +++ b/__tests__/index.js @@ -0,0 +1,56 @@ +require("regenerator-runtime/runtime"); +const JSDOM = require('jsdom'); +// const cunt = require('canvas-prebuilt') +// const cheerio = require('cheerio') +// const $ = cheerio.load('') + +const dom = new JSDOM.JSDOM(` + + + +`); +window = dom.window; +document = window.document; + +const fucker = dom.window.document.getElementById('test'); +// console.log(fucker.toDataURL()) + +const FireMap = require('firemap').default; +// import {FireMap} from 'firemap' +// import test from 'firemap'; + +console.log(FireMap) + +// // console.log(fucker.toDataURL()) +// const testData = { +// dataPoints: [{"x":1920,"y":995,"value":11.1},{"x":1920,"y":0,"value":11.1},{"x":1445,"y":180,"value":42.3},{"x":1440,"y":180,"value":10},{"x":1440,"y":175,"value":239},{"x":1375,"y":195,"value":10},{"x":1320,"y":210,"value":10.4},{"x":1300,"y":165,"value":10.1},{"x":1125,"y":360,"value":10.2},{"x":900,"y":135,"value":10.2},{"x":855,"y":125,"value":10},{"x":805,"y":105,"value":10},{"x":785,"y":655,"value":10.1},{"x":670,"y":90,"value":11.7},{"x":660,"y":80,"value":10.2},{"x":655,"y":80,"value":11.7},{"x":650,"y":80,"value":39.1},{"x":645,"y":75,"value":10},{"x":610,"y":380,"value":240.7},{"x":605,"y":545,"value":10.1},{"x":595,"y":765,"value":10},{"x":595,"y":755,"value":10},{"x":595,"y":725,"value":10.2},{"x":590,"y":795,"value":320.8},{"x":590,"y":785,"value":10.7},{"x":590,"y":780,"value":10},{"x":590,"y":775,"value":31.5},{"x":590,"y":770,"value":10.6},{"x":570,"y":385,"value":10.2},{"x":440,"y":410,"value":10},{"x":40,"y":525,"value":10},{"x":0,"y":995,"value":11.1},{"x":0,"y":0,"value":11.1}], +// clickPoints: [{"x":650,"y":80,"value":1},{"x":590,"y":795,"value":1}] +// }; + +// // const cunt = FireMap(Object.assign(testData)) + +// // console.log(fucker.toDataURL()) + + +// // console.log(fucker.toDataURL()) +// const cunt = new FireMap(Object.assign({canvas: dom.window.document.getElementById('cunt')}, testData)) +// // console.log(fucker.toDataURL()) + + +// cunt.draw({ +// cb: function (ctx) { +// console.log(dom.window.document.getElementById('cunt').toDataURL()) +// // console.log(ctx.get) +// // console.log('cunt') +// // const shit = dom.window.document.getElementById('cunt '); +// // // console.log(fucker.toDataURL()) +// // console.log(shit.toDataURL()) +// // console.log('dsdsdsdsd') +// // console.log(this.canvas.toDataURL()) +// } +// }); + + +// // $.html() + +// debugger \ No newline at end of file diff --git a/dist/firemap.js b/dist/firemap.js new file mode 100644 index 0000000..be3fe07 --- /dev/null +++ b/dist/firemap.js @@ -0,0 +1,4300 @@ +/*! + * The MIT License + * + * Copyright (c) 2017 te schultz + * https://github.com/artisin/firemap + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + * + */ + + +/* eslint-disable */ + +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(); + else if(typeof define === 'function' && define.amd) + define([], factory); + else if(typeof exports === 'object') + exports["firemap"] = factory(); + else + root["firemap"] = factory(); +})(this, function() { +return /******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // identity function for calling harmony imports with the correct context +/******/ __webpack_require__.i = function(value) { return value; }; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { +/******/ configurable: false, +/******/ enumerable: true, +/******/ get: getter +/******/ }); +/******/ } +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = 44); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports, __webpack_require__) { + +var store = __webpack_require__(28)('wks') + , uid = __webpack_require__(31) + , Symbol = __webpack_require__(1).Symbol + , USE_SYMBOL = typeof Symbol == 'function'; + +var $exports = module.exports = function(name){ + return store[name] || (store[name] = + USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name)); +}; + +$exports.store = store; + +/***/ }), +/* 1 */ +/***/ (function(module, exports) { + +// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028 +var global = module.exports = typeof window != 'undefined' && window.Math == Math + ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')(); +if(typeof __g == 'number')__g = global; // eslint-disable-line no-undef + +/***/ }), +/* 2 */ +/***/ (function(module, exports, __webpack_require__) { + +var isObject = __webpack_require__(11); +module.exports = function(it){ + if(!isObject(it))throw TypeError(it + ' is not an object!'); + return it; +}; + +/***/ }), +/* 3 */ +/***/ (function(module, exports) { + +var core = module.exports = {version: '2.4.0'}; +if(typeof __e == 'number')__e = core; // eslint-disable-line no-undef + +/***/ }), +/* 4 */ +/***/ (function(module, exports, __webpack_require__) { + +// Thank's IE8 for his funny defineProperty +module.exports = !__webpack_require__(23)(function(){ + return Object.defineProperty({}, 'a', {get: function(){ return 7; }}).a != 7; +}); + +/***/ }), +/* 5 */ +/***/ (function(module, exports, __webpack_require__) { + +var dP = __webpack_require__(7) + , createDesc = __webpack_require__(27); +module.exports = __webpack_require__(4) ? function(object, key, value){ + return dP.f(object, key, createDesc(1, value)); +} : function(object, key, value){ + object[key] = value; + return object; +}; + +/***/ }), +/* 6 */ +/***/ (function(module, exports) { + +module.exports = {}; + +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { + +var anObject = __webpack_require__(2) + , IE8_DOM_DEFINE = __webpack_require__(53) + , toPrimitive = __webpack_require__(74) + , dP = Object.defineProperty; + +exports.f = __webpack_require__(4) ? Object.defineProperty : function defineProperty(O, P, Attributes){ + anObject(O); + P = toPrimitive(P, true); + anObject(Attributes); + if(IE8_DOM_DEFINE)try { + return dP(O, P, Attributes); + } catch(e){ /* empty */ } + if('get' in Attributes || 'set' in Attributes)throw TypeError('Accessors not supported!'); + if('value' in Attributes)O[P] = Attributes.value; + return O; +}; + +/***/ }), +/* 8 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = function(it){ + return toString.call(it).slice(8, -1); +}; + +/***/ }), +/* 9 */ +/***/ (function(module, exports, __webpack_require__) { + +// optional / simple context binding +var aFunction = __webpack_require__(12); +module.exports = function(fn, that, length){ + aFunction(fn); + if(that === undefined)return fn; + switch(length){ + case 1: return function(a){ + return fn.call(that, a); + }; + case 2: return function(a, b){ + return fn.call(that, a, b); + }; + case 3: return function(a, b, c){ + return fn.call(that, a, b, c); + }; + } + return function(/* ...args */){ + return fn.apply(that, arguments); + }; +}; + +/***/ }), +/* 10 */ +/***/ (function(module, exports) { + +var hasOwnProperty = {}.hasOwnProperty; +module.exports = function(it, key){ + return hasOwnProperty.call(it, key); +}; + +/***/ }), +/* 11 */ +/***/ (function(module, exports) { + +module.exports = function(it){ + return typeof it === 'object' ? it !== null : typeof it === 'function'; +}; + +/***/ }), +/* 12 */ +/***/ (function(module, exports) { + +module.exports = function(it){ + if(typeof it != 'function')throw TypeError(it + ' is not a function!'); + return it; +}; + +/***/ }), +/* 13 */ +/***/ (function(module, exports) { + +// 7.2.1 RequireObjectCoercible(argument) +module.exports = function(it){ + if(it == undefined)throw TypeError("Can't call method on " + it); + return it; +}; + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + +var isObject = __webpack_require__(11) + , document = __webpack_require__(1).document + // in old IE typeof document.createElement is 'object' + , is = isObject(document) && isObject(document.createElement); +module.exports = function(it){ + return is ? document.createElement(it) : {}; +}; + +/***/ }), +/* 15 */ +/***/ (function(module, exports, __webpack_require__) { + +var global = __webpack_require__(1) + , core = __webpack_require__(3) + , ctx = __webpack_require__(9) + , hide = __webpack_require__(5) + , PROTOTYPE = 'prototype'; + +var $export = function(type, name, source){ + var IS_FORCED = type & $export.F + , IS_GLOBAL = type & $export.G + , IS_STATIC = type & $export.S + , IS_PROTO = type & $export.P + , IS_BIND = type & $export.B + , IS_WRAP = type & $export.W + , exports = IS_GLOBAL ? core : core[name] || (core[name] = {}) + , expProto = exports[PROTOTYPE] + , target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE] + , key, own, out; + if(IS_GLOBAL)source = name; + for(key in source){ + // contains in native + own = !IS_FORCED && target && target[key] !== undefined; + if(own && key in exports)continue; + // export native or passed + out = own ? target[key] : source[key]; + // prevent global pollution for namespaces + exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key] + // bind timers to global for call from export context + : IS_BIND && own ? ctx(out, global) + // wrap global constructors for prevent change them in library + : IS_WRAP && target[key] == out ? (function(C){ + var F = function(a, b, c){ + if(this instanceof C){ + switch(arguments.length){ + case 0: return new C; + case 1: return new C(a); + case 2: return new C(a, b); + } return new C(a, b, c); + } return C.apply(this, arguments); + }; + F[PROTOTYPE] = C[PROTOTYPE]; + return F; + // make static versions for prototype methods + })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out; + // export proto methods to core.%CONSTRUCTOR%.methods.%NAME% + if(IS_PROTO){ + (exports.virtual || (exports.virtual = {}))[key] = out; + // export proto methods to core.%CONSTRUCTOR%.prototype.%NAME% + if(type & $export.R && expProto && !expProto[key])hide(expProto, key, out); + } + } +}; +// type bitmap +$export.F = 1; // forced +$export.G = 2; // global +$export.S = 4; // static +$export.P = 8; // proto +$export.B = 16; // bind +$export.W = 32; // wrap +$export.U = 64; // safe +$export.R = 128; // real proto method for `library` +module.exports = $export; + +/***/ }), +/* 16 */ +/***/ (function(module, exports, __webpack_require__) { + +var def = __webpack_require__(7).f + , has = __webpack_require__(10) + , TAG = __webpack_require__(0)('toStringTag'); + +module.exports = function(it, tag, stat){ + if(it && !has(it = stat ? it : it.prototype, TAG))def(it, TAG, {configurable: true, value: tag}); +}; + +/***/ }), +/* 17 */ +/***/ (function(module, exports, __webpack_require__) { + +var shared = __webpack_require__(28)('keys') + , uid = __webpack_require__(31); +module.exports = function(key){ + return shared[key] || (shared[key] = uid(key)); +}; + +/***/ }), +/* 18 */ +/***/ (function(module, exports) { + +// 7.1.4 ToInteger +var ceil = Math.ceil + , floor = Math.floor; +module.exports = function(it){ + return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it); +}; + +/***/ }), +/* 19 */ +/***/ (function(module, exports, __webpack_require__) { + +// to indexed object, toObject with fallback for non-array-like ES3 strings +var IObject = __webpack_require__(55) + , defined = __webpack_require__(13); +module.exports = function(it){ + return IObject(defined(it)); +}; + +/***/ }), +/* 20 */ +/***/ (function(module, exports) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || Function("return this")() || (1,eval)("this"); +} catch(e) { + // This works if the window reference is available + if(typeof window === "object") + g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), +/* 21 */ +/***/ (function(module, exports, __webpack_require__) { + +// getting tag from 19.1.3.6 Object.prototype.toString() +var cof = __webpack_require__(8) + , TAG = __webpack_require__(0)('toStringTag') + // ES3 wrong here + , ARG = cof(function(){ return arguments; }()) == 'Arguments'; + +// fallback for IE11 Script Access Denied error +var tryGet = function(it, key){ + try { + return it[key]; + } catch(e){ /* empty */ } +}; + +module.exports = function(it){ + var O, T, B; + return it === undefined ? 'Undefined' : it === null ? 'Null' + // @@toStringTag case + : typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T + // builtinTag case + : ARG ? cof(O) + // ES3 arguments fallback + : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B; +}; + +/***/ }), +/* 22 */ +/***/ (function(module, exports) { + +// IE 8- don't enum bug keys +module.exports = ( + 'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf' +).split(','); + +/***/ }), +/* 23 */ +/***/ (function(module, exports) { + +module.exports = function(exec){ + try { + return !!exec(); + } catch(e){ + return true; + } +}; + +/***/ }), +/* 24 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(1).document && document.documentElement; + +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var LIBRARY = __webpack_require__(26) + , $export = __webpack_require__(15) + , redefine = __webpack_require__(68) + , hide = __webpack_require__(5) + , has = __webpack_require__(10) + , Iterators = __webpack_require__(6) + , $iterCreate = __webpack_require__(58) + , setToStringTag = __webpack_require__(16) + , getPrototypeOf = __webpack_require__(64) + , ITERATOR = __webpack_require__(0)('iterator') + , BUGGY = !([].keys && 'next' in [].keys()) // Safari has buggy iterators w/o `next` + , FF_ITERATOR = '@@iterator' + , KEYS = 'keys' + , VALUES = 'values'; + +var returnThis = function(){ return this; }; + +module.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED){ + $iterCreate(Constructor, NAME, next); + var getMethod = function(kind){ + if(!BUGGY && kind in proto)return proto[kind]; + switch(kind){ + case KEYS: return function keys(){ return new Constructor(this, kind); }; + case VALUES: return function values(){ return new Constructor(this, kind); }; + } return function entries(){ return new Constructor(this, kind); }; + }; + var TAG = NAME + ' Iterator' + , DEF_VALUES = DEFAULT == VALUES + , VALUES_BUG = false + , proto = Base.prototype + , $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT] + , $default = $native || getMethod(DEFAULT) + , $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined + , $anyNative = NAME == 'Array' ? proto.entries || $native : $native + , methods, key, IteratorPrototype; + // Fix native + if($anyNative){ + IteratorPrototype = getPrototypeOf($anyNative.call(new Base)); + if(IteratorPrototype !== Object.prototype){ + // Set @@toStringTag to native iterators + setToStringTag(IteratorPrototype, TAG, true); + // fix for some old engines + if(!LIBRARY && !has(IteratorPrototype, ITERATOR))hide(IteratorPrototype, ITERATOR, returnThis); + } + } + // fix Array#{values, @@iterator}.name in V8 / FF + if(DEF_VALUES && $native && $native.name !== VALUES){ + VALUES_BUG = true; + $default = function values(){ return $native.call(this); }; + } + // Define iterator + if((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])){ + hide(proto, ITERATOR, $default); + } + // Plug for library + Iterators[NAME] = $default; + Iterators[TAG] = returnThis; + if(DEFAULT){ + methods = { + values: DEF_VALUES ? $default : getMethod(VALUES), + keys: IS_SET ? $default : getMethod(KEYS), + entries: $entries + }; + if(FORCED)for(key in methods){ + if(!(key in proto))redefine(proto, key, methods[key]); + } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods); + } + return methods; +}; + +/***/ }), +/* 26 */ +/***/ (function(module, exports) { + +module.exports = true; + +/***/ }), +/* 27 */ +/***/ (function(module, exports) { + +module.exports = function(bitmap, value){ + return { + enumerable : !(bitmap & 1), + configurable: !(bitmap & 2), + writable : !(bitmap & 4), + value : value + }; +}; + +/***/ }), +/* 28 */ +/***/ (function(module, exports, __webpack_require__) { + +var global = __webpack_require__(1) + , SHARED = '__core-js_shared__' + , store = global[SHARED] || (global[SHARED] = {}); +module.exports = function(key){ + return store[key] || (store[key] = {}); +}; + +/***/ }), +/* 29 */ +/***/ (function(module, exports, __webpack_require__) { + +var ctx = __webpack_require__(9) + , invoke = __webpack_require__(54) + , html = __webpack_require__(24) + , cel = __webpack_require__(14) + , global = __webpack_require__(1) + , process = global.process + , setTask = global.setImmediate + , clearTask = global.clearImmediate + , MessageChannel = global.MessageChannel + , counter = 0 + , queue = {} + , ONREADYSTATECHANGE = 'onreadystatechange' + , defer, channel, port; +var run = function(){ + var id = +this; + if(queue.hasOwnProperty(id)){ + var fn = queue[id]; + delete queue[id]; + fn(); + } +}; +var listener = function(event){ + run.call(event.data); +}; +// Node.js 0.9+ & IE10+ has setImmediate, otherwise: +if(!setTask || !clearTask){ + setTask = function setImmediate(fn){ + var args = [], i = 1; + while(arguments.length > i)args.push(arguments[i++]); + queue[++counter] = function(){ + invoke(typeof fn == 'function' ? fn : Function(fn), args); + }; + defer(counter); + return counter; + }; + clearTask = function clearImmediate(id){ + delete queue[id]; + }; + // Node.js 0.8- + if(__webpack_require__(8)(process) == 'process'){ + defer = function(id){ + process.nextTick(ctx(run, id, 1)); + }; + // Browsers with MessageChannel, includes WebWorkers + } else if(MessageChannel){ + channel = new MessageChannel; + port = channel.port2; + channel.port1.onmessage = listener; + defer = ctx(port.postMessage, port, 1); + // Browsers with postMessage, skip WebWorkers + // IE8 has postMessage, but it's sync & typeof its postMessage is 'object' + } else if(global.addEventListener && typeof postMessage == 'function' && !global.importScripts){ + defer = function(id){ + global.postMessage(id + '', '*'); + }; + global.addEventListener('message', listener, false); + // IE8- + } else if(ONREADYSTATECHANGE in cel('script')){ + defer = function(id){ + html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function(){ + html.removeChild(this); + run.call(id); + }; + }; + // Rest old browsers + } else { + defer = function(id){ + setTimeout(ctx(run, id, 1), 0); + }; + } +} +module.exports = { + set: setTask, + clear: clearTask +}; + +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { + +// 7.1.15 ToLength +var toInteger = __webpack_require__(18) + , min = Math.min; +module.exports = function(it){ + return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991 +}; + +/***/ }), +/* 31 */ +/***/ (function(module, exports) { + +var id = 0 + , px = Math.random(); +module.exports = function(key){ + return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36)); +}; + +/***/ }), +/* 32 */ +/***/ (function(module, exports) { + +/** + * Created by Denis Radin aka PixelsCommander + * http://pixelscommander.com + * + * Polyfill is build around the principe that janks are most harmful to UX when user is continously interacting with app. + * So we are basically preventing operation from being executed while user interacts with interface. + * Currently this implies scrolls, taps, clicks, mouse and touch movements. + * The condition is pretty simple - if there were no interactions for 300 msec there is a huge chance that we are in idle. + */ + +var applyPolyfill = function () { + //By default we may assume that user stopped interaction if we are idle for 300 miliseconds + var IDLE_ENOUGH_DELAY = 300; + var timeoutId = null; + var callbacks = []; + var lastInteractionTime = Date.now(); + var deadline = { + timeRemaining: IDLE_ENOUGH_DELAY + }; + + var isFree = function () { + return timeoutId === null; + } + + var onContinousInteractionStarts = function (interactionName) { + deadline.timeRemaining = 0; + lastInteractionTime = Date.now(); + + if (!timeoutId) { + timeoutId = setTimeout(timeoutCompleted, IDLE_ENOUGH_DELAY); + } + } + + var onContinousInteractionEnds = function (interactionName) { + clearTimeout(timeoutId); + timeoutId = null; + + for (var i = 0; i < callbacks.length; i++) { + executeCallback(callbacks[i]) + } + } + + //Consider categorizing last interaction timestamp in order to add cancelling events like touchend, touchleave, touchcancel, mouseup, mouseout, mouseleave + document.addEventListener('keydown', onContinousInteractionStarts.bind(this, 'keydown')); + document.addEventListener('mousedown', onContinousInteractionStarts.bind(this, 'mousedown')); + document.addEventListener('touchstart', onContinousInteractionStarts.bind(this, 'touchstart')); + document.addEventListener('touchmove', onContinousInteractionStarts.bind(this, 'touchmove')); + document.addEventListener('mousemove', onContinousInteractionStarts.bind(this, 'mousemove')); + document.addEventListener('scroll', onContinousInteractionStarts.bind(this, 'scroll'), true); + + + var timeoutCompleted = function () { + var expectedEndTime = lastInteractionTime + IDLE_ENOUGH_DELAY; + var delta = expectedEndTime - Date.now(); + + if (delta > 0) { + timeoutId = setTimeout(timeoutCompleted, delta); + } else { + onContinousInteractionEnds(); + } + } + + var createCallbackObject = function (callback, timeout) { + var callbackObject = { + callback: callback, + timeoutId: null + }; + + callbackObject.timeoutId = timeout !== null ? setTimeout(executeCallback.bind(this, callbackObject), timeout) : null; + + return callbackObject; + } + + var addCallback = function (callbackObject, timeout) { + callbacks.push(callbackObject); + } + + var executeCallback = function (callbackObject) { + var callbackIndex = callbacks.indexOf(callbackObject); + + if (callbackIndex !== -1) { + callbacks.splice(callbacks.indexOf(callbackObject), 1); + } + + callbackObject.callback(deadline); + + if (callbackObject.timeoutId) { + clearTimeout(callbackObject.timeoutId); + callbackObject.timeoutId = null; + } + } + + return function (callback, options) { + var timeout = (options && options.timeout) || null; + var callbackObject = createCallbackObject(callback, timeout); + + if (isFree()) { + executeCallback(callbackObject); + } else { + addCallback(callbackObject); + } + }; +}; + +if (!window.requestIdleCallback) { + window.ricActivated = true; + window.requestIdleCallback = applyPolyfill(); +} + +window.requestUserIdle = window.ricActivated && window.requestIdleCallback || applyPolyfill(); + +/***/ }), +/* 33 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +//requestIdleCallback Polyfill +__webpack_require__(32); + +/** + * Generates canvus starts + * @param {num} arms -> number of arms on star + * @param {num} x -> position x + * @param {num} y -> position y + * @param {num} outerRadius -> outter radius + * @param {num} innerRadius -> innter radius + * @param {dom} context -> canvus element + * @param {str} colour -> color fill + */ +var drawStar = function drawStar(arms, x, y, outerRadius, innerRadius, context, colour) { + var angle = Math.PI / arms; + context.fillStyle = colour; + context.beginPath(); + for (var i = 0; i < 2 * arms; i++) { + var r = i & 1 ? innerRadius : outerRadius; + var pointX = x + Math.cos(i * angle) * r; + var pointY = y + Math.sin(i * angle) * r; + + if (!i) { + context.moveTo(pointX, pointY); + } else { + context.lineTo(pointX, pointY); + } + } + context.closePath(); + context.fill(); +}; + +/** + * Creates and draws the heat map + * @param {ojb} options.ctx -> canvuas context + * @param {arr} options.clickPoints -> data points to create clicks from [{}...] + */ +var drawClicks = function drawClicks(_ref) { + var ctx = _ref.ctx, + clickPoints = _ref.clickPoints; + + var self = this; + var clickColor = self.clickColor || 'rgba(231, 76, 60, 0.75)'; + var clickSize = self.clickSize || 20; + + return new Promise(function (done) { + window.requestUserIdle(function () { + /** + * Draw coordinate points + */ + var point = null; + for (var i = 0; i < clickPoints.length; i += 1) { + point = clickPoints[i]; + //draw start + drawStar(8, point.x, point.y, clickSize, clickSize / 2, ctx, clickColor); + } + + //-> + done(true); + }, { timeout: 2000 }); + }); +}; + +module.exports = drawClicks; + +/***/ }), +/* 34 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var getPointValue = __webpack_require__(43); +var getColor = __webpack_require__(42); +//requestIdleCallback Polyfill +__webpack_require__(32); + +/** + * sorts based on i axis + * @param {arr} dataPoints -> dataPoints to min/max + * @param {str} i -> x | y + * @return {obj} -> min/max + */ +var getMinMax = function getMinMax(dataPoints) { + var i = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'x'; + + dataPoints.sort(function (a, b) { + return a[i] === b[i] ? a.x - b.x : a[i] - b[i]; + }); + return { + min: dataPoints[0][i], + max: dataPoints[dataPoints.length - 1][i] + }; +}; + +/** + * Creates and draws the heat map + * @param {ojb} options.ctx -> canvuas context + * @param {num} options.limit -> neighborhood limit + * @param {num} options.interval -> interpolation interval + * @param {arr} options.dataPoints -> data points to create map from [{}...] + * @param {arr} options.polygon -> the surounding convex polygon around dataPoints + * @param {bln} options.cleanEdges -> to remove rough edges + * @param {bln} options.mesh -> to create mesh-like map + * @param {bln} options.points -> to draw coordinates for dataPoints + * @param {num} options.pointSize -> size of coordinates points + */ +var drawHeatMap = function drawHeatMap(_ref) { + var ctx = _ref.ctx, + limit = _ref.limit, + interval = _ref.interval, + dataPoints = _ref.dataPoints, + polygon = _ref.polygon, + cleanEdges = _ref.cleanEdges, + mesh = _ref.mesh, + points = _ref.points, + pointSize = _ref.pointSize; + + var self = this; + var size = self.size; + var hue = self.hue; + var max = self.maxValue; + var opacity = self.opacity; + var thresh = self.threshold; + var corners = self.corners; + var radius = mesh ? interval * 1.5 : 1; + return new Promise(function (done) { + window.requestUserIdle(function () { + //set up + limit = limit > dataPoints.length ? dataPoints.length : limit + 1; + var xMinMax = getMinMax(dataPoints, 'x'); + var yMinMax = getMinMax(dataPoints, 'y'); + var xMin = xMinMax.min; + var yMin = yMinMax.min; + var xMax = xMinMax.max; + var yMax = yMinMax.max; + var dbl = 2 * interval; + var col = []; + var val = 0.0; + var x = 0; + var y = 0; + var color = ''; + var gradient = null; + //clear pervious canvus before redraw + ctx.clearRect(0, 0, size.width, size.height); + + //draw heatmap + for (x = xMin; x < xMax; x += interval) { + for (y = yMin; y < yMax; y += interval) { + //get indv points value + val = getPointValue(limit, polygon, dataPoints, { x: x, y: y }); + if (val !== -255) { + ctx.beginPath(); + //get corresponding color to val + col = getColor({ val: val, hue: hue, max: max }); + color = 'rgba(' + col[0] + ', ' + col[1] + ', ' + col[2] + ','; + gradient = ctx.createRadialGradient(x, y, radius, x, y, interval); + gradient.addColorStop(0, color + opacity + ')'); + gradient.addColorStop(1, color + ' 0)'); + ctx.fillStyle = '#ffffff'; + ctx.lineJoin = 'round'; + ctx.fillStyle = gradient; + ctx.fillRect(x - interval, y - interval, dbl, dbl); + ctx.fill(); + ctx.closePath(); + } + } + } + + /** + * Clean hard edges + */ + if (!corners && cleanEdges && polygon.length > 1) { + ctx.globalCompositeOperation = 'destination-in'; + ctx.fillStyle = '#ffffff'; + ctx.lineJoin = 'round'; + ctx.beginPath(); + ctx.moveTo(polygon[0].x, polygon[0].y); + for (var i = 1; i < polygon.length; i++) { + ctx.lineTo(polygon[i].x, polygon[i].y); + } + ctx.lineTo(polygon[0].x, polygon[0].y); + ctx.closePath(); + ctx.fill(); + } + + /** + * Draw coordinate points + */ + if (points) { + var PI2 = 2 * Math.PI; + var point = null; + for (var _i = 0; _i < dataPoints.length; _i += 1) { + point = dataPoints[_i]; + if (point.value > thresh) { + //get corresponding color to val + color = getColor({ val: point.value, hue: hue, max: max }); + ctx.globalCompositeOperation = 'source-over'; + ctx.fillStyle = 'rgba(255, 255, 255, 0.95)'; + ctx.beginPath(); + ctx.arc(point.x, point.y, pointSize, 0, PI2, false); + ctx.fill(); + ctx.lineWidth = pointSize / 4; + ctx.strokeStyle = 'rgba(' + color[0] + ', ' + color[1] + ', ' + color[2] + ', 0.8)'; + ctx.beginPath(); + ctx.arc(point.x, point.y, pointSize, 0, PI2, false); + ctx.stroke(); + ctx.textAlign = 'center'; + ctx.font = pointSize - 2 + 'px monospace'; + ctx.textBaseline = 'middle'; + ctx.fillStyle = '#474f50'; + ctx.fillText(Math.round(point.value), point.x, point.y); + } + } + } + + //-> + done(true); + }, { timeout: 2000 }); + }); +}; + +module.exports = drawHeatMap; + +/***/ }), +/* 35 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Gets perpendicular vector + */ +var vectorProduct = function vectorProduct(a, b, c) { + return (b.x - a.x) * (c.y - a.y) - (b.y - a.y) * (c.x - a.x); +}; + +/** + * Creates an convex hull polygon - ie, the outter bounds around the points + * @param {arr} points -> points to form polygon around + * @return {arr} -> the polygon points + */ +var getConvexHullPolygon = function getConvexHullPolygon(points) { + return new Promise(function (done) { + var lower = []; + var upper = []; + + for (var i = 0; i < points.length; i += 1) { + while (lower.length >= 2 && vectorProduct(lower[lower.length - 2], lower[lower.length - 1], points[i]) <= 0) { + lower.pop(); + } + lower.push(points[i]); + } + for (var _i = points.length - 1; _i >= 0; _i -= 1) { + while (upper.length >= 2 && vectorProduct(upper[upper.length - 2], upper[upper.length - 1], points[_i]) <= 0) { + upper.pop(); + } + upper.push(points[_i]); + } + + upper.pop(); + lower.pop(); + var polygon = lower.concat(upper); + done(polygon); + }); +}; + +module.exports = getConvexHullPolygon; + +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; + +var _promise = __webpack_require__(46); + +var _promise2 = _interopRequireDefault(_promise); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +exports.default = function (fn) { + return function () { + var gen = fn.apply(this, arguments); + return new _promise2.default(function (resolve, reject) { + function step(key, arg) { + try { + var info = gen[key](arg); + var value = info.value; + } catch (error) { + reject(error); + return; + } + + if (info.done) { + resolve(value); + } else { + return _promise2.default.resolve(value).then(function (value) { + step("next", value); + }, function (err) { + step("throw", err); + }); + } + } + + return step("next"); + }); + }; +}; + +/***/ }), +/* 37 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; + +exports.default = function (instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } +}; + +/***/ }), +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; + +var _defineProperty = __webpack_require__(45); + +var _defineProperty2 = _interopRequireDefault(_defineProperty); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +exports.default = function () { + function defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + (0, _defineProperty2.default)(target, descriptor.key, descriptor); + } + } + + return function (Constructor, protoProps, staticProps) { + if (protoProps) defineProperties(Constructor.prototype, protoProps); + if (staticProps) defineProperties(Constructor, staticProps); + return Constructor; + }; +}(); + +/***/ }), +/* 39 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(86); + + +/***/ }), +/* 40 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _detectHover = __webpack_require__(82); + +var _detectHover2 = _interopRequireDefault(_detectHover); + +var _detectPointer = __webpack_require__(84); + +var _detectPointer2 = _interopRequireDefault(_detectPointer); + +var _detectTouchEvents = __webpack_require__(85); + +var _detectTouchEvents2 = _interopRequireDefault(_detectTouchEvents); + +var _detectPassiveEvents = __webpack_require__(83); + +var _detectPassiveEvents2 = _interopRequireDefault(_detectPassiveEvents); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +/* + * detectIt object structure + * const detectIt = { + * deviceType: 'mouseOnly' / 'touchOnly' / 'hybrid', + * passiveEvents: boolean, + * hasTouch: boolean, + * hasMouse: boolean, + * maxTouchPoints: number, + * primaryHover: 'hover' / 'none', + * primaryPointer: 'fine' / 'coarse' / 'none', + * state: { + * detectHover, + * detectPointer, + * detectTouchEvents, + * detectPassiveEvents, + * }, + * update() {...}, + * } + */ + +function determineDeviceType(hasTouch, anyHover, anyFine, state) { + // A hybrid device is one that both hasTouch and any input device can hover + // or has a fine pointer. + if (hasTouch && (anyHover || anyFine)) return 'hybrid'; + + // workaround for browsers that have the touch events api, + // and have implemented Level 4 media queries but not the + // hover and pointer media queries, so the tests are all false (notable Firefox) + // if it hasTouch, no pointer and hover support, and on an android assume it's touchOnly + // if it hasTouch, no pointer and hover support, and not on an android assume it's a hybrid + if (hasTouch && Object.keys(state.detectHover).filter(function (key) { + return key !== 'update'; + }).every(function (key) { + return state.detectHover[key] === false; + }) && Object.keys(state.detectPointer).filter(function (key) { + return key !== 'update'; + }).every(function (key) { + return state.detectPointer[key] === false; + })) { + if (window.navigator && /android/.test(window.navigator.userAgent.toLowerCase())) { + return 'touchOnly'; + } + return 'hybrid'; + } + + // In almost all cases a device that doesn’t support touch will have a mouse, + // but there may be rare exceptions. Note that it doesn’t work to do additional tests + // based on hover and pointer media queries as older browsers don’t support these. + // Essentially, 'mouseOnly' is the default. + return hasTouch ? 'touchOnly' : 'mouseOnly'; +} + +var detectIt = { + state: { + detectHover: _detectHover2.default, + detectPointer: _detectPointer2.default, + detectTouchEvents: _detectTouchEvents2.default, + detectPassiveEvents: _detectPassiveEvents2.default + }, + update: function update() { + detectIt.state.detectHover.update(); + detectIt.state.detectPointer.update(); + detectIt.state.detectTouchEvents.update(); + detectIt.state.detectPassiveEvents.update(); + detectIt.updateOnlyOwnProperties(); + }, + updateOnlyOwnProperties: function updateOnlyOwnProperties() { + if (typeof window !== 'undefined') { + detectIt.passiveEvents = detectIt.state.detectPassiveEvents.hasSupport || false; + + detectIt.hasTouch = detectIt.state.detectTouchEvents.hasSupport || false; + + detectIt.deviceType = determineDeviceType(detectIt.hasTouch, detectIt.state.detectHover.anyHover, detectIt.state.detectPointer.anyFine, detectIt.state); + + detectIt.hasMouse = detectIt.deviceType !== 'touchOnly'; + + detectIt.primaryInput = detectIt.deviceType === 'mouseOnly' && 'mouse' || detectIt.deviceType === 'touchOnly' && 'touch' || + // deviceType is hybrid: + detectIt.state.detectHover.hover && 'mouse' || detectIt.state.detectHover.none && 'touch' || + // if there's no support for hover media queries but detectIt determined it's + // a hybrid device, then assume it's a mouse first device + 'mouse'; + } + } +}; + +detectIt.updateOnlyOwnProperties(); +exports.default = detectIt; + +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as the `TypeError` message for "Functions" methods. */ +var FUNC_ERROR_TEXT = 'Expected a function'; + +/** Used as references for various `Number` constants. */ +var NAN = 0 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; + +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; + +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeMax = Math.max, + nativeMin = Math.min; + +/** + * Gets the timestamp of the number of milliseconds that have elapsed since + * the Unix epoch (1 January 1970 00:00:00 UTC). + * + * @static + * @memberOf _ + * @since 2.4.0 + * @category Date + * @returns {number} Returns the timestamp. + * @example + * + * _.defer(function(stamp) { + * console.log(_.now() - stamp); + * }, _.now()); + * // => Logs the number of milliseconds it took for the deferred invocation. + */ +var now = function() { + return root.Date.now(); +}; + +/** + * Creates a debounced function that delays invoking `func` until after `wait` + * milliseconds have elapsed since the last time the debounced function was + * invoked. The debounced function comes with a `cancel` method to cancel + * delayed `func` invocations and a `flush` method to immediately invoke them. + * Provide `options` to indicate whether `func` should be invoked on the + * leading and/or trailing edge of the `wait` timeout. The `func` is invoked + * with the last arguments provided to the debounced function. Subsequent + * calls to the debounced function return the result of the last `func` + * invocation. + * + * **Note:** If `leading` and `trailing` options are `true`, `func` is + * invoked on the trailing edge of the timeout only if the debounced function + * is invoked more than once during the `wait` timeout. + * + * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred + * until to the next tick, similar to `setTimeout` with a timeout of `0`. + * + * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) + * for details over the differences between `_.debounce` and `_.throttle`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to debounce. + * @param {number} [wait=0] The number of milliseconds to delay. + * @param {Object} [options={}] The options object. + * @param {boolean} [options.leading=false] + * Specify invoking on the leading edge of the timeout. + * @param {number} [options.maxWait] + * The maximum time `func` is allowed to be delayed before it's invoked. + * @param {boolean} [options.trailing=true] + * Specify invoking on the trailing edge of the timeout. + * @returns {Function} Returns the new debounced function. + * @example + * + * // Avoid costly calculations while the window size is in flux. + * jQuery(window).on('resize', _.debounce(calculateLayout, 150)); + * + * // Invoke `sendMail` when clicked, debouncing subsequent calls. + * jQuery(element).on('click', _.debounce(sendMail, 300, { + * 'leading': true, + * 'trailing': false + * })); + * + * // Ensure `batchLog` is invoked once after 1 second of debounced calls. + * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 }); + * var source = new EventSource('/stream'); + * jQuery(source).on('message', debounced); + * + * // Cancel the trailing debounced invocation. + * jQuery(window).on('popstate', debounced.cancel); + */ +function debounce(func, wait, options) { + var lastArgs, + lastThis, + maxWait, + result, + timerId, + lastCallTime, + lastInvokeTime = 0, + leading = false, + maxing = false, + trailing = true; + + if (typeof func != 'function') { + throw new TypeError(FUNC_ERROR_TEXT); + } + wait = toNumber(wait) || 0; + if (isObject(options)) { + leading = !!options.leading; + maxing = 'maxWait' in options; + maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait; + trailing = 'trailing' in options ? !!options.trailing : trailing; + } + + function invokeFunc(time) { + var args = lastArgs, + thisArg = lastThis; + + lastArgs = lastThis = undefined; + lastInvokeTime = time; + result = func.apply(thisArg, args); + return result; + } + + function leadingEdge(time) { + // Reset any `maxWait` timer. + lastInvokeTime = time; + // Start the timer for the trailing edge. + timerId = setTimeout(timerExpired, wait); + // Invoke the leading edge. + return leading ? invokeFunc(time) : result; + } + + function remainingWait(time) { + var timeSinceLastCall = time - lastCallTime, + timeSinceLastInvoke = time - lastInvokeTime, + result = wait - timeSinceLastCall; + + return maxing ? nativeMin(result, maxWait - timeSinceLastInvoke) : result; + } + + function shouldInvoke(time) { + var timeSinceLastCall = time - lastCallTime, + timeSinceLastInvoke = time - lastInvokeTime; + + // Either this is the first call, activity has stopped and we're at the + // trailing edge, the system time has gone backwards and we're treating + // it as the trailing edge, or we've hit the `maxWait` limit. + return (lastCallTime === undefined || (timeSinceLastCall >= wait) || + (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait)); + } + + function timerExpired() { + var time = now(); + if (shouldInvoke(time)) { + return trailingEdge(time); + } + // Restart the timer. + timerId = setTimeout(timerExpired, remainingWait(time)); + } + + function trailingEdge(time) { + timerId = undefined; + + // Only invoke if we have `lastArgs` which means `func` has been + // debounced at least once. + if (trailing && lastArgs) { + return invokeFunc(time); + } + lastArgs = lastThis = undefined; + return result; + } + + function cancel() { + if (timerId !== undefined) { + clearTimeout(timerId); + } + lastInvokeTime = 0; + lastArgs = lastCallTime = lastThis = timerId = undefined; + } + + function flush() { + return timerId === undefined ? result : trailingEdge(now()); + } + + function debounced() { + var time = now(), + isInvoking = shouldInvoke(time); + + lastArgs = arguments; + lastThis = this; + lastCallTime = time; + + if (isInvoking) { + if (timerId === undefined) { + return leadingEdge(lastCallTime); + } + if (maxing) { + // Handle invocations in a tight loop. + timerId = setTimeout(timerExpired, wait); + return invokeFunc(lastCallTime); + } + } + if (timerId === undefined) { + timerId = setTimeout(timerExpired, wait); + } + return result; + } + debounced.cancel = cancel; + debounced.flush = flush; + return debounced; +} + +/** + * Creates a throttled function that only invokes `func` at most once per + * every `wait` milliseconds. The throttled function comes with a `cancel` + * method to cancel delayed `func` invocations and a `flush` method to + * immediately invoke them. Provide `options` to indicate whether `func` + * should be invoked on the leading and/or trailing edge of the `wait` + * timeout. The `func` is invoked with the last arguments provided to the + * throttled function. Subsequent calls to the throttled function return the + * result of the last `func` invocation. + * + * **Note:** If `leading` and `trailing` options are `true`, `func` is + * invoked on the trailing edge of the timeout only if the throttled function + * is invoked more than once during the `wait` timeout. + * + * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred + * until to the next tick, similar to `setTimeout` with a timeout of `0`. + * + * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) + * for details over the differences between `_.throttle` and `_.debounce`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to throttle. + * @param {number} [wait=0] The number of milliseconds to throttle invocations to. + * @param {Object} [options={}] The options object. + * @param {boolean} [options.leading=true] + * Specify invoking on the leading edge of the timeout. + * @param {boolean} [options.trailing=true] + * Specify invoking on the trailing edge of the timeout. + * @returns {Function} Returns the new throttled function. + * @example + * + * // Avoid excessively updating the position while scrolling. + * jQuery(window).on('scroll', _.throttle(updatePosition, 100)); + * + * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes. + * var throttled = _.throttle(renewToken, 300000, { 'trailing': false }); + * jQuery(element).on('click', throttled); + * + * // Cancel the trailing throttled invocation. + * jQuery(window).on('popstate', throttled.cancel); + */ +function throttle(func, wait, options) { + var leading = true, + trailing = true; + + if (typeof func != 'function') { + throw new TypeError(FUNC_ERROR_TEXT); + } + if (isObject(options)) { + leading = 'leading' in options ? !!options.leading : leading; + trailing = 'trailing' in options ? !!options.trailing : trailing; + } + return debounce(func, wait, { + 'leading': leading, + 'maxWait': wait, + 'trailing': trailing + }); +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} + +module.exports = throttle; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(20))) + +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Converts an HSL color value to RGB. Conversion formula + * adapted from http://en.wikipedia.org/wiki/HSL_color_space. + * Assumes h, s, and l are contained in the set [0, 1] and + * returns r, g, and b in the set [0, 255]. + */ +var hslToRgb = function hslToRgb(h, s, l) { + var r = void 0, + g = void 0, + b = void 0; + + if (s === 0) { + // achromatic + r = g = b = l; + } else { + var hue2rgb = function hue2rgb(p, q, t) { + if (t < 0) { + t += 1; + } + if (t > 1) { + t -= 1; + } + if (t < 1 / 6) { + return p + (q - p) * 6 * t; + } + if (t < 1 / 2) { + return q; + } + if (t < 2 / 3) { + return p + (q - p) * (2 / 3 - t) * 6; + } + return p; + }; + + var q = l < 0.5 ? l * (1 + s) : l + s - l * s; + var p = 2 * l - q; + r = hue2rgb(p, q, h + 1 / 3); + g = hue2rgb(p, q, h); + b = hue2rgb(p, q, h - 1 / 3); + } + + return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)]; +}; + +/** + * Gets color based on constrants + */ +var getColor = function getColor(_ref) { + var hue = _ref.hue, + max = _ref.max, + val = _ref.val; + + // 0 -> orange + // 0.5 -> green + // 1 -> violet + var min = 0; + var dif = max - min; + val = val > max ? max : val < min ? min : val; + return hslToRgb(1 - (1 - hue) - (val - min) * hue / dif, 1, 0.5); +}; + +module.exports = getColor; + +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Gets the inverse distance weight of the point + * @param {num} limit -> limit points + * @param {arr} polygon -> the convex hull polygon + * @param {arr} points -> all points + * @param {num} options.x -> point in quesion + * @param {num} options.y -> point in question + * @return {num} -> value + */ +var getPointValue = function getPointValue(limit, polygon, points, _ref) { + var x = _ref.x, + y = _ref.y; + + var insidePolygon = false; + var xa = 0; + var xb = 0; + var ya = 0; + var yb = 0; + var intersect = false; + var p = polygon.length - 1; + //find out if point inside the polygon + for (var i = 0; i < polygon.length; i++) { + xa = polygon[i].x; + ya = polygon[i].y; + xb = polygon[p].x; + yb = polygon[p].y; + intersect = ya > y !== yb > y && x < (xb - xa) * (y - ya) / (yb - ya) + xa; + insidePolygon = !intersect ? insidePolygon : !insidePolygon; + p = i; + } + + if (insidePolygon) { + var arr = []; + var pwr = 2; + var dist = 0.0; + var inv = 0.0; + + //square distances + for (var _i = 0; _i < points.length; _i++) { + var distX = x - points[_i].x; + var distY = y - points[_i].y; + dist = distX * distX + distY * distY; + if (dist === 0) { + return points[_i].value; + } + arr[_i] = [dist, _i]; + } + + arr.sort(function (a, b) { + return a[0] - b[0]; + }); + + //calc + var b = 0.0; + var ptr = 0; + var t = 0.0; + for (var _i2 = 0; _i2 < limit; _i2++) { + ptr = arr[_i2]; + inv = 1 / Math.pow(ptr[0], pwr); + t += inv * points[ptr[1]].value; + b += inv; + } + return t / b; + } + + return -255; +}; + +module.exports = getPointValue; + +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _regenerator = __webpack_require__(39); + +var _regenerator2 = _interopRequireDefault(_regenerator); + +var _asyncToGenerator2 = __webpack_require__(36); + +var _asyncToGenerator3 = _interopRequireDefault(_asyncToGenerator2); + +var _classCallCheck2 = __webpack_require__(37); + +var _classCallCheck3 = _interopRequireDefault(_classCallCheck2); + +var _createClass2 = __webpack_require__(38); + +var _createClass3 = _interopRequireDefault(_createClass2); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var lodashThrottle = __webpack_require__(41); +var detectIt = __webpack_require__(40); +var getConvexHullPolygon = __webpack_require__(35); +var drawHeatMap = __webpack_require__(34); +var drawClickMap = __webpack_require__(33); + +var FireMap = function () { + /** + * @param {arr} dataPoints -> user data points for mouse + * @param {arr} clickPoints -> user data points for clicks + * @param {num} area -> sampling area which clusters all points + * within its area into a single cluster + * default is 5 so 5px by 5px sample area + * @param {dom} canvas -> canvas dom element to draw map on + * @param {bln} cleanEdges -> cleans edges of polygon to remove rough + * edges to make it look pretty, only used + * if corners is false + * @param {str} clickColor -> color of the click point data stars + * @param {num} clickSize -> size of the click point data stars + * @param {num} corners -> creats pseudo data points for cornor of the + * window so heatmap spans the entire screen + * @param {num} height -> height of canvas || screen height + * @param {num} hue -> color hue for map default is 0.5 green, + * 0.8 violet, 3.5 rgbiv and no non-point color + * @param {num} interval -> interpolation interval of unknown points, + * the lower the number the more points + * calculates which producesed a better map + * @param {num} limit -> search neighborhood limit, higher num + * smoother blend of map colors + * but it also increase computation time + * @param {num} maxValue -> max value for color default is 100 + * so any value above 100 is going to be the + * same color + * @param {bln} mesh -> to create a mesh-like map rather then + * a solid map + * @param {num} opacity -> opacity of canvus fill + * @param {bln} points -> to draw data marker point coordinates + * @param {num} pointSize -> font-size of points + * @param {obj} styles -> custom CSS canvas styles + * @param {fnk} subscribe -> a subscribe function that is invoked on + * the mouse tracking & click event, + * passes the event and binded to this + * @param {num} threshold -> point values has to be higher than threshold + * @param {num} throttle -> mouse tracker throttle + * @param {num} width -> width of canvas || screen width + */ + function FireMap() { + var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + _ref$dataPoints = _ref.dataPoints, + dataPoints = _ref$dataPoints === undefined ? [] : _ref$dataPoints, + _ref$clickPoints = _ref.clickPoints, + clickPoints = _ref$clickPoints === undefined ? [] : _ref$clickPoints, + subscribe = _ref.subscribe, + canvas = _ref.canvas, + width = _ref.width, + height = _ref.height, + _ref$area = _ref.area, + area = _ref$area === undefined ? 10 : _ref$area, + _ref$maxValue = _ref.maxValue, + maxValue = _ref$maxValue === undefined ? 100 : _ref$maxValue, + _ref$styles = _ref.styles, + styles = _ref$styles === undefined ? {} : _ref$styles, + _ref$hue = _ref.hue, + hue = _ref$hue === undefined ? 0.5 : _ref$hue, + _ref$opacity = _ref.opacity, + opacity = _ref$opacity === undefined ? 0.8 : _ref$opacity, + _ref$cleanEdges = _ref.cleanEdges, + cleanEdges = _ref$cleanEdges === undefined ? true : _ref$cleanEdges, + _ref$throttle = _ref.throttle, + throttle = _ref$throttle === undefined ? 100 : _ref$throttle, + _ref$threshold = _ref.threshold, + threshold = _ref$threshold === undefined ? 110 : _ref$threshold, + _ref$corners = _ref.corners, + corners = _ref$corners === undefined ? true : _ref$corners, + _ref$limit = _ref.limit, + limit = _ref$limit === undefined ? 100 : _ref$limit, + _ref$interval = _ref.interval, + interval = _ref$interval === undefined ? 8 : _ref$interval, + _ref$mesh = _ref.mesh, + mesh = _ref$mesh === undefined ? false : _ref$mesh, + _ref$points = _ref.points, + points = _ref$points === undefined ? false : _ref$points, + _ref$pointSize = _ref.pointSize, + pointSize = _ref$pointSize === undefined ? 13 : _ref$pointSize, + _ref$clickTrack = _ref.clickTrack, + clickTrack = _ref$clickTrack === undefined ? false : _ref$clickTrack, + clickSize = _ref.clickSize, + clickColor = _ref.clickColor; + + (0, _classCallCheck3.default)(this, FireMap); + + var self = this; + self.error = false; + + /** + * Error gate + */ + canvas = canvas || document.getElementsByTagName('canvas') && document.getElementsByTagName('canvas')[0]; + if (!canvas) { + self.error = true; + console.error('Fatal Fire Map Error: Canvas element not found, cannot proceed.'); + return false; + } + /** + * User data + */ + self.dataPoints = dataPoints; + self.clickPoints = clickPoints; + + /** + * Tracking Vars/setup + */ + self.area = area; + self.throttle = throttle; + self.threshold = threshold; + var getDocSize = function getDocSize() { + var axis = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'Width'; + + var D = document; + return Math.max(D.body['scroll' + axis], D.documentElement['scroll' + axis], D.body['offset' + axis], D.documentElement['offset' + axis], D.body['client' + axis], D.documentElement['client' + axis]); + }; + self.width = width ? width : getDocSize('Width'); + self.height = height ? height : getDocSize('Height'); + //used in mouse track + self._time = false; + self._temp = []; + //create location matrix, add one for safty + self.data = []; + self.data.length = Math.round((self.width + self.area) / self.area) + 1; + var ySize = Math.round((self.height + self.area) / self.area) + 1; + for (var i = self.data.length - 1; i >= 0; i--) { + self.data[i] = []; + self.data[i].length = ySize; + } + //checks for clickTracking and creates need be + self.clickTrack = clickTrack; + if (self.clickTrack) { + self.clickData = []; + self.clickData.length = Math.round((self.width + self.area) / self.area) + 1; + for (var _i = self.clickData.length - 1; _i >= 0; _i--) { + self.clickData[_i] = []; + self.clickData[_i].length = ySize; + } + } + + /** + * HeatMap + */ + self.drawHeatMap = drawHeatMap.bind(self); + self.drawClickMap = drawClickMap.bind(self); + self.maxValue = maxValue; + self.hue = hue; + self.cleanEdges = cleanEdges; + self.opacity = opacity; + self.ctx = null; + //set canvus to take up entire screen + canvas.width = self.width; + canvas.height = self.height; + self.canvas = canvas; + self.points = []; + self.polygon = []; + self.limits = { + xMin: 0, + xMax: 0, + yMin: 0, + yMax: 0 + }; + self.size = { + height: canvas.height, + width: canvas.width + }; + //set canvus style props + styles = Object.assign({ + position: 'absolute', + top: '0', + left: '0', + opacity: opacity + }, styles); + Object.keys(styles).forEach(function (key) { + canvas.style[key] = styles[key]; + }); + + /** + * Draw + */ + self.corners = corners; + self.limit = limit; + self.interval = interval; + self.mesh = mesh; + self.points = points; + self.pointSize = pointSize; + //clicks + self.clickSize = clickSize; + self.clickColor = clickColor; + + //used for realtime tracking + if (typeof subscribe === 'function') { + self.subscribe = subscribe.bind(self); + } + self.dataPointCount = false; + } + + /** + * Draws the heatzmap based on data points + * @param {arr} options.dataPoints -> user data points for mouse + * @param {arr} options.clickPoint -> user data points for clicks + * @param {num} options.clickSize -> size of the click point data stars + * @param {str} options.clickColor -> color of the click point data stars + * @param {fnk} options.cb -> Callback function invoked upon completion + * and binded to instance with the first arg + * being the canvas context (ctx) + * @param {num} options.hue -> color hue for map default is 0.5 green, + * 0.8 violet, 3.5 rgbiv and no non-point color + * @param {num} options. interval -> interpolation interval of unknown points, + * the lower the number the more points + * calculates which producesed a better + * @param {num} options.limit -> search neighborhood limit, higher num + * smoother blend of map colors + * @param {bln} options.mesh -> to create a mesh-like map rather then + * a solid map + * @param {num} options.opacity -> opacity of canvus fill + * @param {bln} options.points -> to draw data marker point coordinates + * @param {num} options.pointSize -> font-size of points + * @param {num} options.threshold -> point values has to be higher than threshold + */ + + + (0, _createClass3.default)(FireMap, [{ + key: 'draw', + value: function draw() { + var _ref2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + dataPoints = _ref2.dataPoints, + clickPoints = _ref2.clickPoints, + limit = _ref2.limit, + interval = _ref2.interval, + mesh = _ref2.mesh, + points = _ref2.points, + pointSize = _ref2.pointSize, + threshold = _ref2.threshold, + hue = _ref2.hue, + opacity = _ref2.opacity, + clickSize = _ref2.clickSize, + clickColor = _ref2.clickColor, + _ref2$cb = _ref2.cb, + cb = _ref2$cb === undefined ? false : _ref2$cb; + + var self = this; + dataPoints = dataPoints !== undefined ? dataPoints : self.dataPoints; + clickPoints = clickPoints !== undefined ? clickPoints : self.clickPoints; + limit = limit !== undefined ? limit : self.limit; + interval = interval !== undefined ? interval : self.interval; + mesh = mesh !== undefined ? mesh : self.mesh; + points = points !== undefined ? points : self.points; + pointSize = pointSize !== undefined ? pointSize : self.pointSize; + //self vars + self.threshold = threshold !== undefined ? threshold : self.threshold; + self.hue = hue !== undefined ? hue : self.hue; + self.opacity = opacity !== undefined ? opacity : self.opacity; + self.clickSize = clickSize !== undefined ? clickSize : self.clickSize; + self.clickColor = clickColor !== undefined ? clickColor : self.clickColor; + var ctx = void 0; + /** + * Wrapper so that we don't trip up the main thread. draw-heat-map also + * is wrapped via requestUserIdle to only execue on idle + */ + var run = function () { + var _ref3 = (0, _asyncToGenerator3.default)(_regenerator2.default.mark(function _callee() { + var cleanEdges, polygon; + return _regenerator2.default.wrap(function _callee$(_context) { + while (1) { + switch (_context.prev = _context.next) { + case 0: + //cannot't clean with real time + cleanEdges = dataPoints ? self.cleanEdges : false; + + ctx = self.canvas.getContext('2d'); + + if (!dataPoints.length) { + _context.next = 6; + break; + } + + _context.t0 = dataPoints; + _context.next = 9; + break; + + case 6: + _context.next = 8; + return self.getData(); + + case 8: + _context.t0 = _context.sent; + + case 9: + dataPoints = _context.t0; + + if (!dataPoints.length) { + _context.next = 16; + break; + } + + _context.next = 13; + return getConvexHullPolygon(dataPoints); + + case 13: + polygon = _context.sent; + _context.next = 16; + return self.drawHeatMap({ + ctx: ctx, limit: limit, interval: interval, dataPoints: dataPoints, polygon: polygon, cleanEdges: cleanEdges, mesh: mesh, points: points, pointSize: pointSize + }); + + case 16: + if (!(clickPoints === true)) { + _context.next = 22; + break; + } + + _context.next = 19; + return self.getData(self.clickData || [], true); + + case 19: + _context.t1 = _context.sent; + _context.next = 23; + break; + + case 22: + _context.t1 = clickPoints; + + case 23: + clickPoints = _context.t1; + + if (!clickPoints.length) { + _context.next = 27; + break; + } + + _context.next = 27; + return self.drawClickMap({ ctx: ctx, clickPoints: clickPoints }); + + case 27: + return _context.abrupt('return', true); + + case 28: + case 'end': + return _context.stop(); + } + } + }, _callee, this); + })); + + function run() { + return _ref3.apply(this, arguments); + } + + return run; + }(); + run().then(function () { + console.log('Draw Complete'); + if (cb) { + cb.apply(self, [ctx]); + } + }); + } + + /** + * Formats the data matricks are removes undefined data + * @param {arr} source -> Source data + * @return {prm} -> promise([{x, y, value} ...]) + */ + + }, { + key: 'getData', + value: function getData() { + var source = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; + var click = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; + + var self = this; + return new Promise(function (done) { + source = source || self.data; + var data = []; + var value = null; + for (var x = source.length - 1; x >= 0; x--) { + for (var y = source[x].length - 1; y >= 0; y--) { + value = source[x][y]; + if (value) { + data.push({ + x: x * self.area, + y: y * self.area, + value: !click ? value / 10 : value + }); + } + } + } + done(data); + }); + } + + /** + * Client init to start tracking mouse movements + */ + + }, { + key: 'init', + value: function init() { + var subscribe = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; + + var self = this; + if (!self.error) { + //subscribe set up + self.subscribe = subscribe && typeof subscribe === 'function' ? subscribe.bind(self) : self.subscribe; + var sub = function sub(event, type) { + return self.subscribe && self.subscribe(event, type); + }; + //mouse movement + self._trackAndLogMouse = self._trackAndLogMouse.bind(self); + document.addEventListener('mousemove', lodashThrottle(function (event) { + self._trackAndLogMouse(event); + sub(event, 'mousemove'); + }, self.throttle), detectIt.passiveEvents ? { passive: true } : false); + + //click + if (self.clickTrack) { + self._logClicks = self._logClicks.bind(self); + document.addEventListener('pointerdown', lodashThrottle(function (event) { + self._logClicks(event); + sub(event, 'pointerdown'); + }, 75), detectIt.passiveEvents ? { passive: true } : false); + } + + //used so that tracker resets otherwise you get edge outliers + document.addEventListener('pointerdown', function () { + self._time = new Date(); + }, detectIt.passiveEvents ? { passive: true } : false); + } + //places data points at corners of canvus + if (self.corners) { + var val = 1; + var x = self.data.length - 1; + var y = self.data[0].length - 1; + self.data[0][0] = val; + self.data[0][y] = val; + self.data[x][0] = val; + self.data[x][y] = val; + } + } + }, { + key: '_setCoordinates', + value: function _setCoordinates(x, y) { + var mouse = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true; + + var self = this; + var posX = Math.round(x / self.area); + var posY = Math.round(y / self.area); + //mouse loging + if (mouse) { + if (!self._time || !self._temp.length) { + self._time = new Date(); + self._temp = [posX, posY]; + } else { + var newTime = new Date(); + var time = newTime - self._time; + //set current data + var temp = self._temp; + //set data, and error check + if (self.data[temp[0]]) { + var data = self.data[temp[0]][temp[1]]; + self.data[temp[0]][temp[1]] = !data ? time : data + time; + } + //store new time + temp + self._time = newTime; + self._temp = [posX, posY]; + } + //for real time update + if (self.dataPointCount) { + self.dataPointCount.count += 1; + } + } else { + //click track + var _data = self.clickData[posX][posY]; + self.clickData[posX][posY] = !_data ? 1 : _data + 1; + } + } + + /** + * Tracks mouse events set movements to _setCoordinates + */ + + }, { + key: '_trackAndLogMouse', + value: function _trackAndLogMouse(event) { + var self = this; + event = event || window.event; + if (event.pageX === null && event.clientX !== null) { + var eventDoc = event.target && event.target.ownerDocument || document; + var doc = eventDoc.documentElement; + var body = eventDoc.body; + + event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0); + event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0); + } + self._setCoordinates(event.pageX, event.pageY); + } + + /** + * Tracks clicks + */ + + }, { + key: '_logClicks', + value: function _logClicks(event) { + var self = this; + event = event || window.event; + if (event.pageX === null && event.clientX !== null) { + var eventDoc = event.target && event.target.ownerDocument || document; + var doc = eventDoc.documentElement; + var body = eventDoc.body; + + event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0); + event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0); + } + self._setCoordinates(event.pageX, event.pageY, false); + } + + /** + * Updates heatmap in real time + * @param {num} interval -> update heatmap every x data points + */ + + }, { + key: 'realTime', + value: function realTime() { + var drawInterval = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 10; + + var self = this; + var dataPointCount = { count: 0 }; + var proxy = new Proxy(dataPointCount, { + set: function set(target, property, value) { + target[property] = value; + if (value % drawInterval === 0) { + self.draw(); + } + return true; + } + }); + self.dataPointCount = proxy; + } + }]); + return FireMap; +}(); + +exports.default = FireMap; + +/***/ }), +/* 45 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { "default": __webpack_require__(47), __esModule: true }; + +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { "default": __webpack_require__(48), __esModule: true }; + +/***/ }), +/* 47 */ +/***/ (function(module, exports, __webpack_require__) { + +__webpack_require__(77); +var $Object = __webpack_require__(3).Object; +module.exports = function defineProperty(it, key, desc){ + return $Object.defineProperty(it, key, desc); +}; + +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { + +__webpack_require__(78); +__webpack_require__(80); +__webpack_require__(81); +__webpack_require__(79); +module.exports = __webpack_require__(3).Promise; + +/***/ }), +/* 49 */ +/***/ (function(module, exports) { + +module.exports = function(){ /* empty */ }; + +/***/ }), +/* 50 */ +/***/ (function(module, exports) { + +module.exports = function(it, Constructor, name, forbiddenField){ + if(!(it instanceof Constructor) || (forbiddenField !== undefined && forbiddenField in it)){ + throw TypeError(name + ': incorrect invocation!'); + } return it; +}; + +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { + +// false -> Array#indexOf +// true -> Array#includes +var toIObject = __webpack_require__(19) + , toLength = __webpack_require__(30) + , toIndex = __webpack_require__(72); +module.exports = function(IS_INCLUDES){ + return function($this, el, fromIndex){ + var O = toIObject($this) + , length = toLength(O.length) + , index = toIndex(fromIndex, length) + , value; + // Array#includes uses SameValueZero equality algorithm + if(IS_INCLUDES && el != el)while(length > index){ + value = O[index++]; + if(value != value)return true; + // Array#toIndex ignores holes, Array#includes - not + } else for(;length > index; index++)if(IS_INCLUDES || index in O){ + if(O[index] === el)return IS_INCLUDES || index || 0; + } return !IS_INCLUDES && -1; + }; +}; + +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { + +var ctx = __webpack_require__(9) + , call = __webpack_require__(57) + , isArrayIter = __webpack_require__(56) + , anObject = __webpack_require__(2) + , toLength = __webpack_require__(30) + , getIterFn = __webpack_require__(75) + , BREAK = {} + , RETURN = {}; +var exports = module.exports = function(iterable, entries, fn, that, ITERATOR){ + var iterFn = ITERATOR ? function(){ return iterable; } : getIterFn(iterable) + , f = ctx(fn, that, entries ? 2 : 1) + , index = 0 + , length, step, iterator, result; + if(typeof iterFn != 'function')throw TypeError(iterable + ' is not iterable!'); + // fast case for arrays with default iterator + if(isArrayIter(iterFn))for(length = toLength(iterable.length); length > index; index++){ + result = entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]); + if(result === BREAK || result === RETURN)return result; + } else for(iterator = iterFn.call(iterable); !(step = iterator.next()).done; ){ + result = call(iterator, f, step.value, entries); + if(result === BREAK || result === RETURN)return result; + } +}; +exports.BREAK = BREAK; +exports.RETURN = RETURN; + +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = !__webpack_require__(4) && !__webpack_require__(23)(function(){ + return Object.defineProperty(__webpack_require__(14)('div'), 'a', {get: function(){ return 7; }}).a != 7; +}); + +/***/ }), +/* 54 */ +/***/ (function(module, exports) { + +// fast apply, http://jsperf.lnkit.com/fast-apply/5 +module.exports = function(fn, args, that){ + var un = that === undefined; + switch(args.length){ + case 0: return un ? fn() + : fn.call(that); + case 1: return un ? fn(args[0]) + : fn.call(that, args[0]); + case 2: return un ? fn(args[0], args[1]) + : fn.call(that, args[0], args[1]); + case 3: return un ? fn(args[0], args[1], args[2]) + : fn.call(that, args[0], args[1], args[2]); + case 4: return un ? fn(args[0], args[1], args[2], args[3]) + : fn.call(that, args[0], args[1], args[2], args[3]); + } return fn.apply(that, args); +}; + +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { + +// fallback for non-array-like ES3 and non-enumerable old V8 strings +var cof = __webpack_require__(8); +module.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it){ + return cof(it) == 'String' ? it.split('') : Object(it); +}; + +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { + +// check on default Array iterator +var Iterators = __webpack_require__(6) + , ITERATOR = __webpack_require__(0)('iterator') + , ArrayProto = Array.prototype; + +module.exports = function(it){ + return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it); +}; + +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { + +// call something on iterator step with safe closing on error +var anObject = __webpack_require__(2); +module.exports = function(iterator, fn, value, entries){ + try { + return entries ? fn(anObject(value)[0], value[1]) : fn(value); + // 7.4.6 IteratorClose(iterator, completion) + } catch(e){ + var ret = iterator['return']; + if(ret !== undefined)anObject(ret.call(iterator)); + throw e; + } +}; + +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var create = __webpack_require__(62) + , descriptor = __webpack_require__(27) + , setToStringTag = __webpack_require__(16) + , IteratorPrototype = {}; + +// 25.1.2.1.1 %IteratorPrototype%[@@iterator]() +__webpack_require__(5)(IteratorPrototype, __webpack_require__(0)('iterator'), function(){ return this; }); + +module.exports = function(Constructor, NAME, next){ + Constructor.prototype = create(IteratorPrototype, {next: descriptor(1, next)}); + setToStringTag(Constructor, NAME + ' Iterator'); +}; + +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { + +var ITERATOR = __webpack_require__(0)('iterator') + , SAFE_CLOSING = false; + +try { + var riter = [7][ITERATOR](); + riter['return'] = function(){ SAFE_CLOSING = true; }; + Array.from(riter, function(){ throw 2; }); +} catch(e){ /* empty */ } + +module.exports = function(exec, skipClosing){ + if(!skipClosing && !SAFE_CLOSING)return false; + var safe = false; + try { + var arr = [7] + , iter = arr[ITERATOR](); + iter.next = function(){ return {done: safe = true}; }; + arr[ITERATOR] = function(){ return iter; }; + exec(arr); + } catch(e){ /* empty */ } + return safe; +}; + +/***/ }), +/* 60 */ +/***/ (function(module, exports) { + +module.exports = function(done, value){ + return {value: value, done: !!done}; +}; + +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { + +var global = __webpack_require__(1) + , macrotask = __webpack_require__(29).set + , Observer = global.MutationObserver || global.WebKitMutationObserver + , process = global.process + , Promise = global.Promise + , isNode = __webpack_require__(8)(process) == 'process'; + +module.exports = function(){ + var head, last, notify; + + var flush = function(){ + var parent, fn; + if(isNode && (parent = process.domain))parent.exit(); + while(head){ + fn = head.fn; + head = head.next; + try { + fn(); + } catch(e){ + if(head)notify(); + else last = undefined; + throw e; + } + } last = undefined; + if(parent)parent.enter(); + }; + + // Node.js + if(isNode){ + notify = function(){ + process.nextTick(flush); + }; + // browsers with MutationObserver + } else if(Observer){ + var toggle = true + , node = document.createTextNode(''); + new Observer(flush).observe(node, {characterData: true}); // eslint-disable-line no-new + notify = function(){ + node.data = toggle = !toggle; + }; + // environments with maybe non-completely correct, but existent Promise + } else if(Promise && Promise.resolve){ + var promise = Promise.resolve(); + notify = function(){ + promise.then(flush); + }; + // for other environments - macrotask based on: + // - setImmediate + // - MessageChannel + // - window.postMessag + // - onreadystatechange + // - setTimeout + } else { + notify = function(){ + // strange IE + webpack dev server bug - use .call(global) + macrotask.call(global, flush); + }; + } + + return function(fn){ + var task = {fn: fn, next: undefined}; + if(last)last.next = task; + if(!head){ + head = task; + notify(); + } last = task; + }; +}; + +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { + +// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties]) +var anObject = __webpack_require__(2) + , dPs = __webpack_require__(63) + , enumBugKeys = __webpack_require__(22) + , IE_PROTO = __webpack_require__(17)('IE_PROTO') + , Empty = function(){ /* empty */ } + , PROTOTYPE = 'prototype'; + +// Create object with fake `null` prototype: use iframe Object with cleared prototype +var createDict = function(){ + // Thrash, waste and sodomy: IE GC bug + var iframe = __webpack_require__(14)('iframe') + , i = enumBugKeys.length + , lt = '<' + , gt = '>' + , iframeDocument; + iframe.style.display = 'none'; + __webpack_require__(24).appendChild(iframe); + iframe.src = 'javascript:'; // eslint-disable-line no-script-url + // createDict = iframe.contentWindow.Object; + // html.removeChild(iframe); + iframeDocument = iframe.contentWindow.document; + iframeDocument.open(); + iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt); + iframeDocument.close(); + createDict = iframeDocument.F; + while(i--)delete createDict[PROTOTYPE][enumBugKeys[i]]; + return createDict(); +}; + +module.exports = Object.create || function create(O, Properties){ + var result; + if(O !== null){ + Empty[PROTOTYPE] = anObject(O); + result = new Empty; + Empty[PROTOTYPE] = null; + // add "__proto__" for Object.getPrototypeOf polyfill + result[IE_PROTO] = O; + } else result = createDict(); + return Properties === undefined ? result : dPs(result, Properties); +}; + + +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { + +var dP = __webpack_require__(7) + , anObject = __webpack_require__(2) + , getKeys = __webpack_require__(66); + +module.exports = __webpack_require__(4) ? Object.defineProperties : function defineProperties(O, Properties){ + anObject(O); + var keys = getKeys(Properties) + , length = keys.length + , i = 0 + , P; + while(length > i)dP.f(O, P = keys[i++], Properties[P]); + return O; +}; + +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { + +// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O) +var has = __webpack_require__(10) + , toObject = __webpack_require__(73) + , IE_PROTO = __webpack_require__(17)('IE_PROTO') + , ObjectProto = Object.prototype; + +module.exports = Object.getPrototypeOf || function(O){ + O = toObject(O); + if(has(O, IE_PROTO))return O[IE_PROTO]; + if(typeof O.constructor == 'function' && O instanceof O.constructor){ + return O.constructor.prototype; + } return O instanceof Object ? ObjectProto : null; +}; + +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { + +var has = __webpack_require__(10) + , toIObject = __webpack_require__(19) + , arrayIndexOf = __webpack_require__(51)(false) + , IE_PROTO = __webpack_require__(17)('IE_PROTO'); + +module.exports = function(object, names){ + var O = toIObject(object) + , i = 0 + , result = [] + , key; + for(key in O)if(key != IE_PROTO)has(O, key) && result.push(key); + // Don't enum bug & hidden keys + while(names.length > i)if(has(O, key = names[i++])){ + ~arrayIndexOf(result, key) || result.push(key); + } + return result; +}; + +/***/ }), +/* 66 */ +/***/ (function(module, exports, __webpack_require__) { + +// 19.1.2.14 / 15.2.3.14 Object.keys(O) +var $keys = __webpack_require__(65) + , enumBugKeys = __webpack_require__(22); + +module.exports = Object.keys || function keys(O){ + return $keys(O, enumBugKeys); +}; + +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { + +var hide = __webpack_require__(5); +module.exports = function(target, src, safe){ + for(var key in src){ + if(safe && target[key])target[key] = src[key]; + else hide(target, key, src[key]); + } return target; +}; + +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(5); + +/***/ }), +/* 69 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var global = __webpack_require__(1) + , core = __webpack_require__(3) + , dP = __webpack_require__(7) + , DESCRIPTORS = __webpack_require__(4) + , SPECIES = __webpack_require__(0)('species'); + +module.exports = function(KEY){ + var C = typeof core[KEY] == 'function' ? core[KEY] : global[KEY]; + if(DESCRIPTORS && C && !C[SPECIES])dP.f(C, SPECIES, { + configurable: true, + get: function(){ return this; } + }); +}; + +/***/ }), +/* 70 */ +/***/ (function(module, exports, __webpack_require__) { + +// 7.3.20 SpeciesConstructor(O, defaultConstructor) +var anObject = __webpack_require__(2) + , aFunction = __webpack_require__(12) + , SPECIES = __webpack_require__(0)('species'); +module.exports = function(O, D){ + var C = anObject(O).constructor, S; + return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S); +}; + +/***/ }), +/* 71 */ +/***/ (function(module, exports, __webpack_require__) { + +var toInteger = __webpack_require__(18) + , defined = __webpack_require__(13); +// true -> String#at +// false -> String#codePointAt +module.exports = function(TO_STRING){ + return function(that, pos){ + var s = String(defined(that)) + , i = toInteger(pos) + , l = s.length + , a, b; + if(i < 0 || i >= l)return TO_STRING ? '' : undefined; + a = s.charCodeAt(i); + return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff + ? TO_STRING ? s.charAt(i) : a + : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000; + }; +}; + +/***/ }), +/* 72 */ +/***/ (function(module, exports, __webpack_require__) { + +var toInteger = __webpack_require__(18) + , max = Math.max + , min = Math.min; +module.exports = function(index, length){ + index = toInteger(index); + return index < 0 ? max(index + length, 0) : min(index, length); +}; + +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { + +// 7.1.13 ToObject(argument) +var defined = __webpack_require__(13); +module.exports = function(it){ + return Object(defined(it)); +}; + +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { + +// 7.1.1 ToPrimitive(input [, PreferredType]) +var isObject = __webpack_require__(11); +// instead of the ES6 spec version, we didn't implement @@toPrimitive case +// and the second argument - flag - preferred type is a string +module.exports = function(it, S){ + if(!isObject(it))return it; + var fn, val; + if(S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val; + if(typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it)))return val; + if(!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val; + throw TypeError("Can't convert object to primitive value"); +}; + +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { + +var classof = __webpack_require__(21) + , ITERATOR = __webpack_require__(0)('iterator') + , Iterators = __webpack_require__(6); +module.exports = __webpack_require__(3).getIteratorMethod = function(it){ + if(it != undefined)return it[ITERATOR] + || it['@@iterator'] + || Iterators[classof(it)]; +}; + +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var addToUnscopables = __webpack_require__(49) + , step = __webpack_require__(60) + , Iterators = __webpack_require__(6) + , toIObject = __webpack_require__(19); + +// 22.1.3.4 Array.prototype.entries() +// 22.1.3.13 Array.prototype.keys() +// 22.1.3.29 Array.prototype.values() +// 22.1.3.30 Array.prototype[@@iterator]() +module.exports = __webpack_require__(25)(Array, 'Array', function(iterated, kind){ + this._t = toIObject(iterated); // target + this._i = 0; // next index + this._k = kind; // kind +// 22.1.5.2.1 %ArrayIteratorPrototype%.next() +}, function(){ + var O = this._t + , kind = this._k + , index = this._i++; + if(!O || index >= O.length){ + this._t = undefined; + return step(1); + } + if(kind == 'keys' )return step(0, index); + if(kind == 'values')return step(0, O[index]); + return step(0, [index, O[index]]); +}, 'values'); + +// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7) +Iterators.Arguments = Iterators.Array; + +addToUnscopables('keys'); +addToUnscopables('values'); +addToUnscopables('entries'); + +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { + +var $export = __webpack_require__(15); +// 19.1.2.4 / 15.2.3.6 Object.defineProperty(O, P, Attributes) +$export($export.S + $export.F * !__webpack_require__(4), 'Object', {defineProperty: __webpack_require__(7).f}); + +/***/ }), +/* 78 */ +/***/ (function(module, exports) { + + + +/***/ }), +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var LIBRARY = __webpack_require__(26) + , global = __webpack_require__(1) + , ctx = __webpack_require__(9) + , classof = __webpack_require__(21) + , $export = __webpack_require__(15) + , isObject = __webpack_require__(11) + , aFunction = __webpack_require__(12) + , anInstance = __webpack_require__(50) + , forOf = __webpack_require__(52) + , speciesConstructor = __webpack_require__(70) + , task = __webpack_require__(29).set + , microtask = __webpack_require__(61)() + , PROMISE = 'Promise' + , TypeError = global.TypeError + , process = global.process + , $Promise = global[PROMISE] + , process = global.process + , isNode = classof(process) == 'process' + , empty = function(){ /* empty */ } + , Internal, GenericPromiseCapability, Wrapper; + +var USE_NATIVE = !!function(){ + try { + // correct subclassing with @@species support + var promise = $Promise.resolve(1) + , FakePromise = (promise.constructor = {})[__webpack_require__(0)('species')] = function(exec){ exec(empty, empty); }; + // unhandled rejections tracking support, NodeJS Promise without it fails @@species test + return (isNode || typeof PromiseRejectionEvent == 'function') && promise.then(empty) instanceof FakePromise; + } catch(e){ /* empty */ } +}(); + +// helpers +var sameConstructor = function(a, b){ + // with library wrapper special case + return a === b || a === $Promise && b === Wrapper; +}; +var isThenable = function(it){ + var then; + return isObject(it) && typeof (then = it.then) == 'function' ? then : false; +}; +var newPromiseCapability = function(C){ + return sameConstructor($Promise, C) + ? new PromiseCapability(C) + : new GenericPromiseCapability(C); +}; +var PromiseCapability = GenericPromiseCapability = function(C){ + var resolve, reject; + this.promise = new C(function($$resolve, $$reject){ + if(resolve !== undefined || reject !== undefined)throw TypeError('Bad Promise constructor'); + resolve = $$resolve; + reject = $$reject; + }); + this.resolve = aFunction(resolve); + this.reject = aFunction(reject); +}; +var perform = function(exec){ + try { + exec(); + } catch(e){ + return {error: e}; + } +}; +var notify = function(promise, isReject){ + if(promise._n)return; + promise._n = true; + var chain = promise._c; + microtask(function(){ + var value = promise._v + , ok = promise._s == 1 + , i = 0; + var run = function(reaction){ + var handler = ok ? reaction.ok : reaction.fail + , resolve = reaction.resolve + , reject = reaction.reject + , domain = reaction.domain + , result, then; + try { + if(handler){ + if(!ok){ + if(promise._h == 2)onHandleUnhandled(promise); + promise._h = 1; + } + if(handler === true)result = value; + else { + if(domain)domain.enter(); + result = handler(value); + if(domain)domain.exit(); + } + if(result === reaction.promise){ + reject(TypeError('Promise-chain cycle')); + } else if(then = isThenable(result)){ + then.call(result, resolve, reject); + } else resolve(result); + } else reject(value); + } catch(e){ + reject(e); + } + }; + while(chain.length > i)run(chain[i++]); // variable length - can't use forEach + promise._c = []; + promise._n = false; + if(isReject && !promise._h)onUnhandled(promise); + }); +}; +var onUnhandled = function(promise){ + task.call(global, function(){ + var value = promise._v + , abrupt, handler, console; + if(isUnhandled(promise)){ + abrupt = perform(function(){ + if(isNode){ + process.emit('unhandledRejection', value, promise); + } else if(handler = global.onunhandledrejection){ + handler({promise: promise, reason: value}); + } else if((console = global.console) && console.error){ + console.error('Unhandled promise rejection', value); + } + }); + // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should + promise._h = isNode || isUnhandled(promise) ? 2 : 1; + } promise._a = undefined; + if(abrupt)throw abrupt.error; + }); +}; +var isUnhandled = function(promise){ + if(promise._h == 1)return false; + var chain = promise._a || promise._c + , i = 0 + , reaction; + while(chain.length > i){ + reaction = chain[i++]; + if(reaction.fail || !isUnhandled(reaction.promise))return false; + } return true; +}; +var onHandleUnhandled = function(promise){ + task.call(global, function(){ + var handler; + if(isNode){ + process.emit('rejectionHandled', promise); + } else if(handler = global.onrejectionhandled){ + handler({promise: promise, reason: promise._v}); + } + }); +}; +var $reject = function(value){ + var promise = this; + if(promise._d)return; + promise._d = true; + promise = promise._w || promise; // unwrap + promise._v = value; + promise._s = 2; + if(!promise._a)promise._a = promise._c.slice(); + notify(promise, true); +}; +var $resolve = function(value){ + var promise = this + , then; + if(promise._d)return; + promise._d = true; + promise = promise._w || promise; // unwrap + try { + if(promise === value)throw TypeError("Promise can't be resolved itself"); + if(then = isThenable(value)){ + microtask(function(){ + var wrapper = {_w: promise, _d: false}; // wrap + try { + then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1)); + } catch(e){ + $reject.call(wrapper, e); + } + }); + } else { + promise._v = value; + promise._s = 1; + notify(promise, false); + } + } catch(e){ + $reject.call({_w: promise, _d: false}, e); // wrap + } +}; + +// constructor polyfill +if(!USE_NATIVE){ + // 25.4.3.1 Promise(executor) + $Promise = function Promise(executor){ + anInstance(this, $Promise, PROMISE, '_h'); + aFunction(executor); + Internal.call(this); + try { + executor(ctx($resolve, this, 1), ctx($reject, this, 1)); + } catch(err){ + $reject.call(this, err); + } + }; + Internal = function Promise(executor){ + this._c = []; // <- awaiting reactions + this._a = undefined; // <- checked in isUnhandled reactions + this._s = 0; // <- state + this._d = false; // <- done + this._v = undefined; // <- value + this._h = 0; // <- rejection state, 0 - default, 1 - handled, 2 - unhandled + this._n = false; // <- notify + }; + Internal.prototype = __webpack_require__(67)($Promise.prototype, { + // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected) + then: function then(onFulfilled, onRejected){ + var reaction = newPromiseCapability(speciesConstructor(this, $Promise)); + reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true; + reaction.fail = typeof onRejected == 'function' && onRejected; + reaction.domain = isNode ? process.domain : undefined; + this._c.push(reaction); + if(this._a)this._a.push(reaction); + if(this._s)notify(this, false); + return reaction.promise; + }, + // 25.4.5.1 Promise.prototype.catch(onRejected) + 'catch': function(onRejected){ + return this.then(undefined, onRejected); + } + }); + PromiseCapability = function(){ + var promise = new Internal; + this.promise = promise; + this.resolve = ctx($resolve, promise, 1); + this.reject = ctx($reject, promise, 1); + }; +} + +$export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: $Promise}); +__webpack_require__(16)($Promise, PROMISE); +__webpack_require__(69)(PROMISE); +Wrapper = __webpack_require__(3)[PROMISE]; + +// statics +$export($export.S + $export.F * !USE_NATIVE, PROMISE, { + // 25.4.4.5 Promise.reject(r) + reject: function reject(r){ + var capability = newPromiseCapability(this) + , $$reject = capability.reject; + $$reject(r); + return capability.promise; + } +}); +$export($export.S + $export.F * (LIBRARY || !USE_NATIVE), PROMISE, { + // 25.4.4.6 Promise.resolve(x) + resolve: function resolve(x){ + // instanceof instead of internal slot check because we should fix it without replacement native Promise core + if(x instanceof $Promise && sameConstructor(x.constructor, this))return x; + var capability = newPromiseCapability(this) + , $$resolve = capability.resolve; + $$resolve(x); + return capability.promise; + } +}); +$export($export.S + $export.F * !(USE_NATIVE && __webpack_require__(59)(function(iter){ + $Promise.all(iter)['catch'](empty); +})), PROMISE, { + // 25.4.4.1 Promise.all(iterable) + all: function all(iterable){ + var C = this + , capability = newPromiseCapability(C) + , resolve = capability.resolve + , reject = capability.reject; + var abrupt = perform(function(){ + var values = [] + , index = 0 + , remaining = 1; + forOf(iterable, false, function(promise){ + var $index = index++ + , alreadyCalled = false; + values.push(undefined); + remaining++; + C.resolve(promise).then(function(value){ + if(alreadyCalled)return; + alreadyCalled = true; + values[$index] = value; + --remaining || resolve(values); + }, reject); + }); + --remaining || resolve(values); + }); + if(abrupt)reject(abrupt.error); + return capability.promise; + }, + // 25.4.4.4 Promise.race(iterable) + race: function race(iterable){ + var C = this + , capability = newPromiseCapability(C) + , reject = capability.reject; + var abrupt = perform(function(){ + forOf(iterable, false, function(promise){ + C.resolve(promise).then(capability.resolve, reject); + }); + }); + if(abrupt)reject(abrupt.error); + return capability.promise; + } +}); + +/***/ }), +/* 80 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var $at = __webpack_require__(71)(true); + +// 21.1.3.27 String.prototype[@@iterator]() +__webpack_require__(25)(String, 'String', function(iterated){ + this._t = String(iterated); // target + this._i = 0; // next index +// 21.1.5.2.1 %StringIteratorPrototype%.next() +}, function(){ + var O = this._t + , index = this._i + , point; + if(index >= O.length)return {value: undefined, done: true}; + point = $at(O, index); + this._i += point.length; + return {value: point, done: false}; +}); + +/***/ }), +/* 81 */ +/***/ (function(module, exports, __webpack_require__) { + +__webpack_require__(76); +var global = __webpack_require__(1) + , hide = __webpack_require__(5) + , Iterators = __webpack_require__(6) + , TO_STRING_TAG = __webpack_require__(0)('toStringTag'); + +for(var collections = ['NodeList', 'DOMTokenList', 'MediaList', 'StyleSheetList', 'CSSRuleList'], i = 0; i < 5; i++){ + var NAME = collections[i] + , Collection = global[NAME] + , proto = Collection && Collection.prototype; + if(proto && !proto[TO_STRING_TAG])hide(proto, TO_STRING_TAG, NAME); + Iterators[NAME] = Iterators.Array; +} + +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; + +var detectHover = { + update: function update() { + if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.matchMedia === 'function') { + detectHover.hover = window.matchMedia('(hover: hover)').matches; + detectHover.none = window.matchMedia('(hover: none)').matches || window.matchMedia('(hover: on-demand)').matches; + detectHover.anyHover = window.matchMedia('(any-hover: hover)').matches; + detectHover.anyNone = window.matchMedia('(any-hover: none)').matches || window.matchMedia('(any-hover: on-demand)').matches; + } + } +}; + +detectHover.update(); +exports.default = detectHover; + +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; + +// adapted from https://github.com/WICG/EventListenerOptions/blob/gh-pages/explainer.md +var detectPassiveEvents = { + update: function update() { + if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.addEventListener === 'function' && typeof Object.defineProperty === 'function') { + var passive = false; + var options = Object.defineProperty({}, 'passive', { + get: function get() { + passive = true; + } + }); + window.addEventListener('test', null, options); + + detectPassiveEvents.hasSupport = passive; + } + } +}; + +detectPassiveEvents.update(); +exports.default = detectPassiveEvents; + +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; + +var detectPointer = { + update: function update() { + if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.matchMedia === 'function') { + detectPointer.fine = window.matchMedia('(pointer: fine)').matches; + detectPointer.coarse = window.matchMedia('(pointer: coarse)').matches; + detectPointer.none = window.matchMedia('(pointer: none)').matches; + detectPointer.anyFine = window.matchMedia('(any-pointer: fine)').matches; + detectPointer.anyCoarse = window.matchMedia('(any-pointer: coarse)').matches; + detectPointer.anyNone = window.matchMedia('(any-pointer: none)').matches; + } + } +}; + +detectPointer.update(); +exports.default = detectPointer; + +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +var detectTouchEvents = { + update: function update() { + if (window !== undefined) { + detectTouchEvents.hasSupport = 'ontouchstart' in window; + detectTouchEvents.browserSupportsApi = Boolean(window.TouchEvent); + } + } +}; + +detectTouchEvents.update(); +exports.default = detectTouchEvents; + +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {// This method of obtaining a reference to the global object needs to be +// kept identical to the way it is obtained in runtime.js +var g = + typeof global === "object" ? global : + typeof window === "object" ? window : + typeof self === "object" ? self : this; + +// Use `getOwnPropertyNames` because not all browsers support calling +// `hasOwnProperty` on the global `self` object in a worker. See #183. +var hadRuntime = g.regeneratorRuntime && + Object.getOwnPropertyNames(g).indexOf("regeneratorRuntime") >= 0; + +// Save the old regeneratorRuntime in case it needs to be restored later. +var oldRuntime = hadRuntime && g.regeneratorRuntime; + +// Force reevalutation of runtime.js. +g.regeneratorRuntime = undefined; + +module.exports = __webpack_require__(87); + +if (hadRuntime) { + // Restore the original runtime. + g.regeneratorRuntime = oldRuntime; +} else { + // Remove the global property added by runtime.js. + try { + delete g.regeneratorRuntime; + } catch(e) { + g.regeneratorRuntime = undefined; + } +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(20))) + +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {/** + * Copyright (c) 2014, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * https://raw.github.com/facebook/regenerator/master/LICENSE file. An + * additional grant of patent rights can be found in the PATENTS file in + * the same directory. + */ + +!(function(global) { + "use strict"; + + var Op = Object.prototype; + var hasOwn = Op.hasOwnProperty; + var undefined; // More compressible than void 0. + var $Symbol = typeof Symbol === "function" ? Symbol : {}; + var iteratorSymbol = $Symbol.iterator || "@@iterator"; + var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator"; + var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; + + var inModule = typeof module === "object"; + var runtime = global.regeneratorRuntime; + if (runtime) { + if (inModule) { + // If regeneratorRuntime is defined globally and we're in a module, + // make the exports object identical to regeneratorRuntime. + module.exports = runtime; + } + // Don't bother evaluating the rest of this file if the runtime was + // already defined globally. + return; + } + + // Define the runtime globally (as expected by generated code) as either + // module.exports (if we're in a module) or a new, empty object. + runtime = global.regeneratorRuntime = inModule ? module.exports : {}; + + function wrap(innerFn, outerFn, self, tryLocsList) { + // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator. + var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator; + var generator = Object.create(protoGenerator.prototype); + var context = new Context(tryLocsList || []); + + // The ._invoke method unifies the implementations of the .next, + // .throw, and .return methods. + generator._invoke = makeInvokeMethod(innerFn, self, context); + + return generator; + } + runtime.wrap = wrap; + + // Try/catch helper to minimize deoptimizations. Returns a completion + // record like context.tryEntries[i].completion. This interface could + // have been (and was previously) designed to take a closure to be + // invoked without arguments, but in all the cases we care about we + // already have an existing method we want to call, so there's no need + // to create a new function object. We can even get away with assuming + // the method takes exactly one argument, since that happens to be true + // in every case, so we don't have to touch the arguments object. The + // only additional allocation required is the completion record, which + // has a stable shape and so hopefully should be cheap to allocate. + function tryCatch(fn, obj, arg) { + try { + return { type: "normal", arg: fn.call(obj, arg) }; + } catch (err) { + return { type: "throw", arg: err }; + } + } + + var GenStateSuspendedStart = "suspendedStart"; + var GenStateSuspendedYield = "suspendedYield"; + var GenStateExecuting = "executing"; + var GenStateCompleted = "completed"; + + // Returning this object from the innerFn has the same effect as + // breaking out of the dispatch switch statement. + var ContinueSentinel = {}; + + // Dummy constructor functions that we use as the .constructor and + // .constructor.prototype properties for functions that return Generator + // objects. For full spec compliance, you may wish to configure your + // minifier not to mangle the names of these two functions. + function Generator() {} + function GeneratorFunction() {} + function GeneratorFunctionPrototype() {} + + // This is a polyfill for %IteratorPrototype% for environments that + // don't natively support it. + var IteratorPrototype = {}; + IteratorPrototype[iteratorSymbol] = function () { + return this; + }; + + var getProto = Object.getPrototypeOf; + var NativeIteratorPrototype = getProto && getProto(getProto(values([]))); + if (NativeIteratorPrototype && + NativeIteratorPrototype !== Op && + hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) { + // This environment has a native %IteratorPrototype%; use it instead + // of the polyfill. + IteratorPrototype = NativeIteratorPrototype; + } + + var Gp = GeneratorFunctionPrototype.prototype = + Generator.prototype = Object.create(IteratorPrototype); + GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype; + GeneratorFunctionPrototype.constructor = GeneratorFunction; + GeneratorFunctionPrototype[toStringTagSymbol] = + GeneratorFunction.displayName = "GeneratorFunction"; + + // Helper for defining the .next, .throw, and .return methods of the + // Iterator interface in terms of a single ._invoke method. + function defineIteratorMethods(prototype) { + ["next", "throw", "return"].forEach(function(method) { + prototype[method] = function(arg) { + return this._invoke(method, arg); + }; + }); + } + + runtime.isGeneratorFunction = function(genFun) { + var ctor = typeof genFun === "function" && genFun.constructor; + return ctor + ? ctor === GeneratorFunction || + // For the native GeneratorFunction constructor, the best we can + // do is to check its .name property. + (ctor.displayName || ctor.name) === "GeneratorFunction" + : false; + }; + + runtime.mark = function(genFun) { + if (Object.setPrototypeOf) { + Object.setPrototypeOf(genFun, GeneratorFunctionPrototype); + } else { + genFun.__proto__ = GeneratorFunctionPrototype; + if (!(toStringTagSymbol in genFun)) { + genFun[toStringTagSymbol] = "GeneratorFunction"; + } + } + genFun.prototype = Object.create(Gp); + return genFun; + }; + + // Within the body of any async function, `await x` is transformed to + // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test + // `hasOwn.call(value, "__await")` to determine if the yielded value is + // meant to be awaited. + runtime.awrap = function(arg) { + return { __await: arg }; + }; + + function AsyncIterator(generator) { + function invoke(method, arg, resolve, reject) { + var record = tryCatch(generator[method], generator, arg); + if (record.type === "throw") { + reject(record.arg); + } else { + var result = record.arg; + var value = result.value; + if (value && + typeof value === "object" && + hasOwn.call(value, "__await")) { + return Promise.resolve(value.__await).then(function(value) { + invoke("next", value, resolve, reject); + }, function(err) { + invoke("throw", err, resolve, reject); + }); + } + + return Promise.resolve(value).then(function(unwrapped) { + // When a yielded Promise is resolved, its final value becomes + // the .value of the Promise<{value,done}> result for the + // current iteration. If the Promise is rejected, however, the + // result for this iteration will be rejected with the same + // reason. Note that rejections of yielded Promises are not + // thrown back into the generator function, as is the case + // when an awaited Promise is rejected. This difference in + // behavior between yield and await is important, because it + // allows the consumer to decide what to do with the yielded + // rejection (swallow it and continue, manually .throw it back + // into the generator, abandon iteration, whatever). With + // await, by contrast, there is no opportunity to examine the + // rejection reason outside the generator function, so the + // only option is to throw it from the await expression, and + // let the generator function handle the exception. + result.value = unwrapped; + resolve(result); + }, reject); + } + } + + if (typeof global.process === "object" && global.process.domain) { + invoke = global.process.domain.bind(invoke); + } + + var previousPromise; + + function enqueue(method, arg) { + function callInvokeWithMethodAndArg() { + return new Promise(function(resolve, reject) { + invoke(method, arg, resolve, reject); + }); + } + + return previousPromise = + // If enqueue has been called before, then we want to wait until + // all previous Promises have been resolved before calling invoke, + // so that results are always delivered in the correct order. If + // enqueue has not been called before, then it is important to + // call invoke immediately, without waiting on a callback to fire, + // so that the async generator function has the opportunity to do + // any necessary setup in a predictable way. This predictability + // is why the Promise constructor synchronously invokes its + // executor callback, and why async functions synchronously + // execute code before the first await. Since we implement simple + // async functions in terms of async generators, it is especially + // important to get this right, even though it requires care. + previousPromise ? previousPromise.then( + callInvokeWithMethodAndArg, + // Avoid propagating failures to Promises returned by later + // invocations of the iterator. + callInvokeWithMethodAndArg + ) : callInvokeWithMethodAndArg(); + } + + // Define the unified helper method that is used to implement .next, + // .throw, and .return (see defineIteratorMethods). + this._invoke = enqueue; + } + + defineIteratorMethods(AsyncIterator.prototype); + AsyncIterator.prototype[asyncIteratorSymbol] = function () { + return this; + }; + runtime.AsyncIterator = AsyncIterator; + + // Note that simple async functions are implemented on top of + // AsyncIterator objects; they just return a Promise for the value of + // the final result produced by the iterator. + runtime.async = function(innerFn, outerFn, self, tryLocsList) { + var iter = new AsyncIterator( + wrap(innerFn, outerFn, self, tryLocsList) + ); + + return runtime.isGeneratorFunction(outerFn) + ? iter // If outerFn is a generator, return the full iterator. + : iter.next().then(function(result) { + return result.done ? result.value : iter.next(); + }); + }; + + function makeInvokeMethod(innerFn, self, context) { + var state = GenStateSuspendedStart; + + return function invoke(method, arg) { + if (state === GenStateExecuting) { + throw new Error("Generator is already running"); + } + + if (state === GenStateCompleted) { + if (method === "throw") { + throw arg; + } + + // Be forgiving, per 25.3.3.3.3 of the spec: + // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume + return doneResult(); + } + + context.method = method; + context.arg = arg; + + while (true) { + var delegate = context.delegate; + if (delegate) { + var delegateResult = maybeInvokeDelegate(delegate, context); + if (delegateResult) { + if (delegateResult === ContinueSentinel) continue; + return delegateResult; + } + } + + if (context.method === "next") { + // Setting context._sent for legacy support of Babel's + // function.sent implementation. + context.sent = context._sent = context.arg; + + } else if (context.method === "throw") { + if (state === GenStateSuspendedStart) { + state = GenStateCompleted; + throw context.arg; + } + + context.dispatchException(context.arg); + + } else if (context.method === "return") { + context.abrupt("return", context.arg); + } + + state = GenStateExecuting; + + var record = tryCatch(innerFn, self, context); + if (record.type === "normal") { + // If an exception is thrown from innerFn, we leave state === + // GenStateExecuting and loop back for another invocation. + state = context.done + ? GenStateCompleted + : GenStateSuspendedYield; + + if (record.arg === ContinueSentinel) { + continue; + } + + return { + value: record.arg, + done: context.done + }; + + } else if (record.type === "throw") { + state = GenStateCompleted; + // Dispatch the exception by looping back around to the + // context.dispatchException(context.arg) call above. + context.method = "throw"; + context.arg = record.arg; + } + } + }; + } + + // Call delegate.iterator[context.method](context.arg) and handle the + // result, either by returning a { value, done } result from the + // delegate iterator, or by modifying context.method and context.arg, + // setting context.delegate to null, and returning the ContinueSentinel. + function maybeInvokeDelegate(delegate, context) { + var method = delegate.iterator[context.method]; + if (method === undefined) { + // A .throw or .return when the delegate iterator has no .throw + // method always terminates the yield* loop. + context.delegate = null; + + if (context.method === "throw") { + if (delegate.iterator.return) { + // If the delegate iterator has a return method, give it a + // chance to clean up. + context.method = "return"; + context.arg = undefined; + maybeInvokeDelegate(delegate, context); + + if (context.method === "throw") { + // If maybeInvokeDelegate(context) changed context.method from + // "return" to "throw", let that override the TypeError below. + return ContinueSentinel; + } + } + + context.method = "throw"; + context.arg = new TypeError( + "The iterator does not provide a 'throw' method"); + } + + return ContinueSentinel; + } + + var record = tryCatch(method, delegate.iterator, context.arg); + + if (record.type === "throw") { + context.method = "throw"; + context.arg = record.arg; + context.delegate = null; + return ContinueSentinel; + } + + var info = record.arg; + + if (! info) { + context.method = "throw"; + context.arg = new TypeError("iterator result is not an object"); + context.delegate = null; + return ContinueSentinel; + } + + if (info.done) { + // Assign the result of the finished delegate to the temporary + // variable specified by delegate.resultName (see delegateYield). + context[delegate.resultName] = info.value; + + // Resume execution at the desired location (see delegateYield). + context.next = delegate.nextLoc; + + // If context.method was "throw" but the delegate handled the + // exception, let the outer generator proceed normally. If + // context.method was "next", forget context.arg since it has been + // "consumed" by the delegate iterator. If context.method was + // "return", allow the original .return call to continue in the + // outer generator. + if (context.method !== "return") { + context.method = "next"; + context.arg = undefined; + } + + } else { + // Re-yield the result returned by the delegate method. + return info; + } + + // The delegate iterator is finished, so forget it and continue with + // the outer generator. + context.delegate = null; + return ContinueSentinel; + } + + // Define Generator.prototype.{next,throw,return} in terms of the + // unified ._invoke helper method. + defineIteratorMethods(Gp); + + Gp[toStringTagSymbol] = "Generator"; + + // A Generator should always return itself as the iterator object when the + // @@iterator function is called on it. Some browsers' implementations of the + // iterator prototype chain incorrectly implement this, causing the Generator + // object to not be returned from this call. This ensures that doesn't happen. + // See https://github.com/facebook/regenerator/issues/274 for more details. + Gp[iteratorSymbol] = function() { + return this; + }; + + Gp.toString = function() { + return "[object Generator]"; + }; + + function pushTryEntry(locs) { + var entry = { tryLoc: locs[0] }; + + if (1 in locs) { + entry.catchLoc = locs[1]; + } + + if (2 in locs) { + entry.finallyLoc = locs[2]; + entry.afterLoc = locs[3]; + } + + this.tryEntries.push(entry); + } + + function resetTryEntry(entry) { + var record = entry.completion || {}; + record.type = "normal"; + delete record.arg; + entry.completion = record; + } + + function Context(tryLocsList) { + // The root entry object (effectively a try statement without a catch + // or a finally block) gives us a place to store values thrown from + // locations where there is no enclosing try statement. + this.tryEntries = [{ tryLoc: "root" }]; + tryLocsList.forEach(pushTryEntry, this); + this.reset(true); + } + + runtime.keys = function(object) { + var keys = []; + for (var key in object) { + keys.push(key); + } + keys.reverse(); + + // Rather than returning an object with a next method, we keep + // things simple and return the next function itself. + return function next() { + while (keys.length) { + var key = keys.pop(); + if (key in object) { + next.value = key; + next.done = false; + return next; + } + } + + // To avoid creating an additional object, we just hang the .value + // and .done properties off the next function object itself. This + // also ensures that the minifier will not anonymize the function. + next.done = true; + return next; + }; + }; + + function values(iterable) { + if (iterable) { + var iteratorMethod = iterable[iteratorSymbol]; + if (iteratorMethod) { + return iteratorMethod.call(iterable); + } + + if (typeof iterable.next === "function") { + return iterable; + } + + if (!isNaN(iterable.length)) { + var i = -1, next = function next() { + while (++i < iterable.length) { + if (hasOwn.call(iterable, i)) { + next.value = iterable[i]; + next.done = false; + return next; + } + } + + next.value = undefined; + next.done = true; + + return next; + }; + + return next.next = next; + } + } + + // Return an iterator with no values. + return { next: doneResult }; + } + runtime.values = values; + + function doneResult() { + return { value: undefined, done: true }; + } + + Context.prototype = { + constructor: Context, + + reset: function(skipTempReset) { + this.prev = 0; + this.next = 0; + // Resetting context._sent for legacy support of Babel's + // function.sent implementation. + this.sent = this._sent = undefined; + this.done = false; + this.delegate = null; + + this.method = "next"; + this.arg = undefined; + + this.tryEntries.forEach(resetTryEntry); + + if (!skipTempReset) { + for (var name in this) { + // Not sure about the optimal order of these conditions: + if (name.charAt(0) === "t" && + hasOwn.call(this, name) && + !isNaN(+name.slice(1))) { + this[name] = undefined; + } + } + } + }, + + stop: function() { + this.done = true; + + var rootEntry = this.tryEntries[0]; + var rootRecord = rootEntry.completion; + if (rootRecord.type === "throw") { + throw rootRecord.arg; + } + + return this.rval; + }, + + dispatchException: function(exception) { + if (this.done) { + throw exception; + } + + var context = this; + function handle(loc, caught) { + record.type = "throw"; + record.arg = exception; + context.next = loc; + + if (caught) { + // If the dispatched exception was caught by a catch block, + // then let that catch block handle the exception normally. + context.method = "next"; + context.arg = undefined; + } + + return !! caught; + } + + for (var i = this.tryEntries.length - 1; i >= 0; --i) { + var entry = this.tryEntries[i]; + var record = entry.completion; + + if (entry.tryLoc === "root") { + // Exception thrown outside of any try block that could handle + // it, so set the completion value of the entire function to + // throw the exception. + return handle("end"); + } + + if (entry.tryLoc <= this.prev) { + var hasCatch = hasOwn.call(entry, "catchLoc"); + var hasFinally = hasOwn.call(entry, "finallyLoc"); + + if (hasCatch && hasFinally) { + if (this.prev < entry.catchLoc) { + return handle(entry.catchLoc, true); + } else if (this.prev < entry.finallyLoc) { + return handle(entry.finallyLoc); + } + + } else if (hasCatch) { + if (this.prev < entry.catchLoc) { + return handle(entry.catchLoc, true); + } + + } else if (hasFinally) { + if (this.prev < entry.finallyLoc) { + return handle(entry.finallyLoc); + } + + } else { + throw new Error("try statement without catch or finally"); + } + } + } + }, + + abrupt: function(type, arg) { + for (var i = this.tryEntries.length - 1; i >= 0; --i) { + var entry = this.tryEntries[i]; + if (entry.tryLoc <= this.prev && + hasOwn.call(entry, "finallyLoc") && + this.prev < entry.finallyLoc) { + var finallyEntry = entry; + break; + } + } + + if (finallyEntry && + (type === "break" || + type === "continue") && + finallyEntry.tryLoc <= arg && + arg <= finallyEntry.finallyLoc) { + // Ignore the finally entry if control is not jumping to a + // location outside the try/catch block. + finallyEntry = null; + } + + var record = finallyEntry ? finallyEntry.completion : {}; + record.type = type; + record.arg = arg; + + if (finallyEntry) { + this.method = "next"; + this.next = finallyEntry.finallyLoc; + return ContinueSentinel; + } + + return this.complete(record); + }, + + complete: function(record, afterLoc) { + if (record.type === "throw") { + throw record.arg; + } + + if (record.type === "break" || + record.type === "continue") { + this.next = record.arg; + } else if (record.type === "return") { + this.rval = this.arg = record.arg; + this.method = "return"; + this.next = "end"; + } else if (record.type === "normal" && afterLoc) { + this.next = afterLoc; + } + + return ContinueSentinel; + }, + + finish: function(finallyLoc) { + for (var i = this.tryEntries.length - 1; i >= 0; --i) { + var entry = this.tryEntries[i]; + if (entry.finallyLoc === finallyLoc) { + this.complete(entry.completion, entry.afterLoc); + resetTryEntry(entry); + return ContinueSentinel; + } + } + }, + + "catch": function(tryLoc) { + for (var i = this.tryEntries.length - 1; i >= 0; --i) { + var entry = this.tryEntries[i]; + if (entry.tryLoc === tryLoc) { + var record = entry.completion; + if (record.type === "throw") { + var thrown = record.arg; + resetTryEntry(entry); + } + return thrown; + } + } + + // The context.catch method must only be called with a location + // argument that corresponds to a known catch block. + throw new Error("illegal catch attempt"); + }, + + delegateYield: function(iterable, resultName, nextLoc) { + this.delegate = { + iterator: values(iterable), + resultName: resultName, + nextLoc: nextLoc + }; + + if (this.method === "next") { + // Deliberately forget the last sent value so that we don't + // accidentally pass it on to the delegate. + this.arg = undefined; + } + + return ContinueSentinel; + } + }; +})( + // Among the various tricks for obtaining a reference to the global + // object, this seems to be the most reliable technique that does not + // use indirect eval (which violates Content Security Policy). + typeof global === "object" ? global : + typeof window === "object" ? window : + typeof self === "object" ? self : this +); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(20))) + +/***/ }) +/******/ ]); +}); +//# sourceMappingURL=firemap.js.map \ No newline at end of file diff --git a/dist/firemap.js.map b/dist/firemap.js.map new file mode 100644 index 0000000..31a469e --- /dev/null +++ b/dist/firemap.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["webpack:///webpack/universalModuleDefinition","webpack:///webpack/bootstrap fc86a3e6eca71cf03084","webpack:///./~/core-js/library/modules/_wks.js","webpack:///./~/core-js/library/modules/_global.js","webpack:///./~/core-js/library/modules/_an-object.js","webpack:///./~/core-js/library/modules/_core.js","webpack:///./~/core-js/library/modules/_descriptors.js","webpack:///./~/core-js/library/modules/_hide.js","webpack:///./~/core-js/library/modules/_iterators.js","webpack:///./~/core-js/library/modules/_object-dp.js","webpack:///./~/core-js/library/modules/_cof.js","webpack:///./~/core-js/library/modules/_ctx.js","webpack:///./~/core-js/library/modules/_has.js","webpack:///./~/core-js/library/modules/_is-object.js","webpack:///./~/core-js/library/modules/_a-function.js","webpack:///./~/core-js/library/modules/_defined.js","webpack:///./~/core-js/library/modules/_dom-create.js","webpack:///./~/core-js/library/modules/_export.js","webpack:///./~/core-js/library/modules/_set-to-string-tag.js","webpack:///./~/core-js/library/modules/_shared-key.js","webpack:///./~/core-js/library/modules/_to-integer.js","webpack:///./~/core-js/library/modules/_to-iobject.js","webpack:///(webpack)/buildin/global.js","webpack:///./~/core-js/library/modules/_classof.js","webpack:///./~/core-js/library/modules/_enum-bug-keys.js","webpack:///./~/core-js/library/modules/_fails.js","webpack:///./~/core-js/library/modules/_html.js","webpack:///./~/core-js/library/modules/_iter-define.js","webpack:///./~/core-js/library/modules/_library.js","webpack:///./~/core-js/library/modules/_property-desc.js","webpack:///./~/core-js/library/modules/_shared.js","webpack:///./~/core-js/library/modules/_task.js","webpack:///./~/core-js/library/modules/_to-length.js","webpack:///./~/core-js/library/modules/_uid.js","webpack:///./~/ric/src/ric-polyfill.js","webpack:///./lib/draw-click-map.js","webpack:///./lib/draw-heat-map.js","webpack:///./lib/get-convex-hull-polygon.js","webpack:///./~/babel-runtime/helpers/asyncToGenerator.js","webpack:///./~/babel-runtime/helpers/classCallCheck.js","webpack:///./~/babel-runtime/helpers/createClass.js","webpack:///./~/babel-runtime/regenerator/index.js","webpack:///./~/detect-it/lib/index.js","webpack:///./~/lodash.throttle/index.js","webpack:///./lib/get-color.js","webpack:///./lib/get-point-value.js","webpack:///./lib/index.js","webpack:///./~/babel-runtime/core-js/object/define-property.js","webpack:///./~/babel-runtime/core-js/promise.js","webpack:///./~/core-js/library/fn/object/define-property.js","webpack:///./~/core-js/library/fn/promise.js","webpack:///./~/core-js/library/modules/_add-to-unscopables.js","webpack:///./~/core-js/library/modules/_an-instance.js","webpack:///./~/core-js/library/modules/_array-includes.js","webpack:///./~/core-js/library/modules/_for-of.js","webpack:///./~/core-js/library/modules/_ie8-dom-define.js","webpack:///./~/core-js/library/modules/_invoke.js","webpack:///./~/core-js/library/modules/_iobject.js","webpack:///./~/core-js/library/modules/_is-array-iter.js","webpack:///./~/core-js/library/modules/_iter-call.js","webpack:///./~/core-js/library/modules/_iter-create.js","webpack:///./~/core-js/library/modules/_iter-detect.js","webpack:///./~/core-js/library/modules/_iter-step.js","webpack:///./~/core-js/library/modules/_microtask.js","webpack:///./~/core-js/library/modules/_object-create.js","webpack:///./~/core-js/library/modules/_object-dps.js","webpack:///./~/core-js/library/modules/_object-gpo.js","webpack:///./~/core-js/library/modules/_object-keys-internal.js","webpack:///./~/core-js/library/modules/_object-keys.js","webpack:///./~/core-js/library/modules/_redefine-all.js","webpack:///./~/core-js/library/modules/_redefine.js","webpack:///./~/core-js/library/modules/_set-species.js","webpack:///./~/core-js/library/modules/_species-constructor.js","webpack:///./~/core-js/library/modules/_string-at.js","webpack:///./~/core-js/library/modules/_to-index.js","webpack:///./~/core-js/library/modules/_to-object.js","webpack:///./~/core-js/library/modules/_to-primitive.js","webpack:///./~/core-js/library/modules/core.get-iterator-method.js","webpack:///./~/core-js/library/modules/es6.array.iterator.js","webpack:///./~/core-js/library/modules/es6.object.define-property.js","webpack:///./~/core-js/library/modules/es6.promise.js","webpack:///./~/core-js/library/modules/es6.string.iterator.js","webpack:///./~/core-js/library/modules/web.dom.iterable.js","webpack:///./~/detect-hover/lib/index.js","webpack:///./~/detect-passive-events/lib/index.js","webpack:///./~/detect-pointer/lib/index.js","webpack:///./~/detect-touch-events/lib/index.js","webpack:///./~/regenerator-runtime/runtime-module.js","webpack:///./~/regenerator-runtime/runtime.js"],"names":["require","drawStar","arms","x","y","outerRadius","innerRadius","context","colour","angle","Math","PI","fillStyle","beginPath","i","r","pointX","cos","pointY","sin","moveTo","lineTo","closePath","fill","drawClicks","ctx","clickPoints","self","clickColor","clickSize","Promise","done","window","requestUserIdle","point","length","timeout","module","exports","getPointValue","getColor","getMinMax","dataPoints","sort","a","b","min","max","drawHeatMap","limit","interval","polygon","cleanEdges","mesh","points","pointSize","size","hue","maxValue","opacity","thresh","threshold","corners","radius","xMinMax","yMinMax","xMin","yMin","xMax","yMax","dbl","col","val","color","gradient","clearRect","width","height","createRadialGradient","addColorStop","lineJoin","fillRect","globalCompositeOperation","PI2","value","arc","lineWidth","strokeStyle","stroke","textAlign","font","textBaseline","fillText","round","vectorProduct","c","getConvexHullPolygon","lower","upper","pop","push","concat","hslToRgb","h","s","l","g","hue2rgb","p","q","t","dif","insidePolygon","xa","xb","ya","yb","intersect","arr","pwr","dist","inv","distX","distY","ptr","pow","lodashThrottle","detectIt","drawClickMap","FireMap","subscribe","canvas","area","styles","throttle","clickTrack","error","document","getElementsByTagName","console","getDocSize","axis","D","body","documentElement","_time","_temp","data","ySize","clickData","bind","limits","Object","assign","position","top","left","keys","forEach","key","style","dataPointCount","cb","undefined","run","getContext","getData","then","log","apply","source","click","sub","event","type","_trackAndLogMouse","addEventListener","passiveEvents","passive","_logClicks","Date","mouse","posX","posY","newTime","time","temp","count","pageX","clientX","eventDoc","target","ownerDocument","doc","scrollLeft","clientLeft","pageY","clientY","scrollTop","clientTop","_setCoordinates","drawInterval","proxy","Proxy","set","property","draw"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;ACVA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA,mDAA2C,cAAc;;AAEzD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,mCAA2B,0BAA0B,EAAE;AACvD,yCAAiC,eAAe;AAChD;AACA;AACA;;AAEA;AACA,8DAAsD,+DAA+D;;AAErH;AACA;;AAEA;AACA;;;;;;;AChEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,uB;;;;;;ACVA;AACA;AACA;AACA,uCAAuC,gC;;;;;;ACHvC;AACA;AACA;AACA;AACA,E;;;;;;ACJA,6BAA6B;AAC7B,qCAAqC,gC;;;;;;ACDrC;AACA;AACA,iCAAiC,QAAQ,gBAAgB,UAAU,GAAG;AACtE,CAAC,E;;;;;;ACHD;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA,E;;;;;;ACPA,oB;;;;;;ACAA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG,UAAU;AACb;AACA;AACA;AACA,E;;;;;;ACfA,iBAAiB;;AAEjB;AACA;AACA,E;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACnBA,uBAAuB;AACvB;AACA;AACA,E;;;;;;ACHA;AACA;AACA,E;;;;;;ACFA;AACA;AACA;AACA,E;;;;;;ACHA;AACA;AACA;AACA;AACA,E;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACNA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mEAAmE;AACnE;AACA,qFAAqF;AACrF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX,SAAS;AACT;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,+CAA+C;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,eAAe;AACf,eAAe;AACf,eAAe;AACf,gBAAgB;AAChB,yB;;;;;;AC5DA;AACA;AACA;;AAEA;AACA,kEAAkE,+BAA+B;AACjG,E;;;;;;ACNA;AACA;AACA;AACA;AACA,E;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACLA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACLA;;AAEA;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;;AAEA;AACA;AACA,4CAA4C;;AAE5C;;;;;;;ACpBA;AACA;AACA;AACA;AACA,yBAAyB,kBAAkB,EAAE;;AAE7C;AACA;AACA;AACA;AACA,GAAG,UAAU;AACb;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACtBA;AACA;AACA;AACA,a;;;;;;ACHA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA,E;;;;;;ACNA,6E;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,4BAA4B,aAAa;;AAEzC;AACA;AACA;AACA;AACA;AACA,wCAAwC,oCAAoC;AAC5E,4CAA4C,oCAAoC;AAChF,KAAK,2BAA2B,oCAAoC;AACpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB,mBAAmB;AACnC;AACA;AACA,iCAAiC,2BAA2B;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,E;;;;;;ACrEA,sB;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACPA;AACA;AACA,mDAAmD;AACnD;AACA,uCAAuC;AACvC,E;;;;;;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;AC1EA;AACA;AACA;AACA;AACA,2DAA2D;AAC3D,E;;;;;;ACLA;AACA;AACA;AACA;AACA,E;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA,uBAAuB,sBAAsB;AAC7C;AACA;AACA;;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;AAEA;AACA;AACA,SAAS;AACT;AACA;AACA,WAAW;AACX;AACA,WAAW;AACX;AACA;;AAEA;AACA,KAAK;AACL;AACA,E;;;;;;;ACrCA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,E;;;;;;;ACRA;;AAEA;;AAEA;;AAEA;;AAEA,sCAAsC,uCAAuC,gBAAgB;;AAE7F;AACA;AACA,mBAAmB,kBAAkB;AACrC;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,CAAC,G;;;;;;AC1BD;;;;;;;;ACAA;;AAEA;AACA;AACA,CAAC;;AAED;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA,sCAAsC,uCAAuC,gBAAgB;;AAE7F;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN,eAAe,IAAI;AACnB;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;AACA,GAAG;AACH;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,2B;;;;;;AC/GA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa,OAAO;AACpB;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,SAAS;AACpB,WAAW,OAAO;AAClB,WAAW,OAAO,YAAY;AAC9B,WAAW,QAAQ;AACnB;AACA,WAAW,OAAO;AAClB;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,8CAA8C,kBAAkB;AAChE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,SAAS;AACpB,WAAW,OAAO;AAClB,WAAW,OAAO,YAAY;AAC9B,WAAW,QAAQ;AACnB;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;AACA;AACA,mDAAmD,oBAAoB;AACvE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,EAAE;AACb,aAAa,QAAQ;AACrB;AACA;AACA,gBAAgB;AAChB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,EAAE;AACb,aAAa,QAAQ;AACrB;AACA;AACA,oBAAoB;AACpB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,EAAE;AACb,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,EAAE;AACb,aAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;;;;;;;;;;ACtbA;;;;;;AAMA,IAAMM,WAAY,SAAZA,QAAY,CAAUC,CAAV,EAAaC,CAAb,EAAgBC,CAAhB,EAAmB;AACnC,MAAI1F,UAAJ;AAAA,MAAO2F,UAAP;AAAA,MAAU7D,UAAV;;AAEA,MAAG2D,MAAM,CAAT,EAAY;AACV;AACAzF,QAAI2F,IAAI7D,IAAI4D,CAAZ;AACD,GAHD,MAGK;AACH,QAAME,UAAU,SAAVA,OAAU,CAAUC,CAAV,EAAaC,CAAb,EAAgBC,CAAhB,EAAmB;AACjC,UAA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;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA,E;;;;;;;ACXA;AACA;AACA;AACA;AACA;;AAEA;AACA,yFAAgF,aAAa,EAAE;;AAE/F;AACA,qDAAqD,0BAA0B;AAC/E;AACA,E;;;;;;ACZA;AACA;;AAEA;AACA;AACA,+BAA+B,qBAAqB;AACpD,+BAA+B,SAAS,EAAE;AAC1C,CAAC,UAAU;;AAEX;AACA;AACA;AACA;AACA;AACA;AACA,2BAA2B,SAAS,mBAAmB;AACvD,+BAA+B,aAAa;AAC5C;AACA,GAAG,UAAU;AACb;AACA,E;;;;;;ACpBA;AACA,UAAU;AACV,E;;;;;;ACFA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA,uCAAuC,oBAAoB,EAAE;AAC7D;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;;AAEA;AACA,gBAAgB;AAChB;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,E;;;;;;ACnEA;AACA;AACA;AACA;AACA;AACA,6BAA6B;AAC7B;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;;;;;;;ACxCA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACZA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH,E;;;;;;ACZA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;AChBA;AACA;AACA;;AAEA;AACA;AACA,E;;;;;;ACNA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH,E;;;;;;ACNA,wC;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,oBAAoB,aAAa;AACjC,GAAG;AACH,E;;;;;;ACbA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACPA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;AChBA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACNA;AACA;AACA;AACA;AACA,E;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;ACXA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,E;;;;;;;ACPA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,gCAAgC;AAChC,cAAc;AACd,iBAAiB;AACjB;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;;AAED;AACA;;AAEA;AACA;AACA,4B;;;;;;ACjCA;AACA;AACA,oEAAuE,yCAA0C,E;;;;;;;;;;;;;ACFjH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oCAAoC;AACpC;;AAEA;AACA;AACA;AACA;AACA,+CAA+C,sDAAiD,oBAAoB;AACpH;AACA;AACA,GAAG,UAAU;AACb,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH,YAAY;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA,WAAW;AACX,SAAS;AACT,OAAO;AACP;AACA;AACA;AACA,2CAA2C;AAC3C;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,mBAAmB,gCAAgC;AACnD,SAAS;AACT;AACA;AACA,OAAO;AACP;AACA;AACA,KAAK;AACL;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,eAAe,qCAAqC;AACpD;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,kCAAkC;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kCAAkC;AAClC;AACA;AACA;AACA;AACA,uBAAuB,wBAAwB;AAC/C;AACA;AACA,SAAS;AACT;AACA;AACA,OAAO;AACP,KAAK;AACL;AACA;AACA;AACA;AACA,GAAG;AACH,kBAAkB,uBAAuB,KAAK;AAC9C;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA,iBAAiB;AACjB,wBAAwB;AACxB,gBAAgB;AAChB,oBAAoB;AACpB,wBAAwB;AACxB,gBAAgB;AAChB,oBAAoB;AACpB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,0DAA0D,kBAAkB;AAC5E;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,OAAO;AACP;AACA,KAAK;AACL;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK;AACL;AACA;AACA;AACA,CAAC,E;;;;;;;AC1SD;AACA;;AAEA;AACA;AACA,6BAA6B;AAC7B,cAAc;AACd;AACA,CAAC;AACD;AACA;AACA;AACA,+BAA+B;AAC/B;AACA;AACA,UAAU;AACV,CAAC,E;;;;;;AChBD;AACA;AACA;AACA;AACA;;AAEA,wGAAwG,OAAO;AAC/G;AACA;AACA;AACA;AACA;AACA,C;;;;;;;ACZA;;AAEA;AACA;AACA,CAAC;;AAED,oGAAoG,mBAAmB,EAAE,mBAAmB,kGAAkG;;AAE9O;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,8B;;;;;;;ACpBA;;AAEA;AACA;AACA,CAAC;;AAED,oGAAoG,mBAAmB,EAAE,mBAAmB,8HAA8H;;AAE1Q;AACA;AACA;AACA;AACA;AACA,4CAA4C;AAC5C;AACA;AACA;AACA,OAAO;AACP;;AAEA;AACA;AACA;AACA;;AAEA;AACA,sC;;;;;;;AC1BA;;AAEA;AACA;AACA,CAAC;;AAED,oGAAoG,mBAAmB,EAAE,mBAAmB,kGAAkG;;AAE9O;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,gC;;;;;;;ACtBA;;AAEA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,oC;;;;;;ACfA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;;;;;;;AC9BA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,gBAAgB;AAChB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc;AACd,KAAK;AACL,cAAc;AACd;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,yDAAyD;AACzD;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,YAAY;AACZ;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA,WAAW;AACX;;AAEA;AACA;AACA,wCAAwC,WAAW;AACnD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,SAAS;AACT;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,2BAA2B;AAC3B;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,SAAS;AACT;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,SAAS;AACT;AACA;AACA;AACA;;AAEA;;AAEA,SAAS;AACT;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,oCAAoC,cAAc;AAClD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,KAAK;AACL;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,iCAAiC,kBAAkB;AACnD;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,iBAAiB;;AAEjB;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,wBAAwB,iBAAiB;AACzC;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,YAAY;AACZ;AACA;;AAEA;AACA,YAAY;AACZ;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,KAAK;;AAEL;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA,8CAA8C,QAAQ;AACtD;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,aAAa;AACb;AACA;;AAEA,WAAW;AACX;AACA;AACA;;AAEA,WAAW;AACX;AACA;AACA;;AAEA,WAAW;AACX;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA,8CAA8C,QAAQ;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,KAAK;;AAEL;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,OAAO;AACP;AACA;;AAEA;AACA,KAAK;;AAEL;AACA,8CAA8C,QAAQ;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA,8CAA8C,QAAQ;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA","file":"firemap.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"firemap\"] = factory();\n\telse\n\t\troot[\"firemap\"] = factory();\n})(this, function() {\nreturn \n\n\n// WEBPACK FOOTER //\n// webpack/universalModuleDefinition"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// identity function for calling harmony imports with the correct context\n \t__webpack_require__.i = function(value) { return value; };\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 44);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap fc86a3e6eca71cf03084","var store = require('./_shared')('wks')\n , uid = require('./_uid')\n , Symbol = require('./_global').Symbol\n , USE_SYMBOL = typeof Symbol == 'function';\n\nvar $exports = module.exports = function(name){\n return store[name] || (store[name] =\n USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));\n};\n\n$exports.store = store;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_wks.js\n// module id = 0\n// module chunks = 0","// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nvar global = module.exports = typeof window != 'undefined' && window.Math == Math\n ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')();\nif(typeof __g == 'number')__g = global; // eslint-disable-line no-undef\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_global.js\n// module id = 1\n// module chunks = 0","var isObject = require('./_is-object');\nmodule.exports = function(it){\n if(!isObject(it))throw TypeError(it + ' is not an object!');\n return it;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_an-object.js\n// module id = 2\n// module chunks = 0","var core = module.exports = {version: '2.4.0'};\nif(typeof __e == 'number')__e = core; // eslint-disable-line no-undef\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_core.js\n// module id = 3\n// module chunks = 0","// Thank's IE8 for his funny defineProperty\nmodule.exports = !require('./_fails')(function(){\n return Object.defineProperty({}, 'a', {get: function(){ return 7; }}).a != 7;\n});\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_descriptors.js\n// module id = 4\n// module chunks = 0","var dP = require('./_object-dp')\n , createDesc = require('./_property-desc');\nmodule.exports = require('./_descriptors') ? function(object, key, value){\n return dP.f(object, key, createDesc(1, value));\n} : function(object, key, value){\n object[key] = value;\n return object;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_hide.js\n// module id = 5\n// module chunks = 0","module.exports = {};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iterators.js\n// module id = 6\n// module chunks = 0","var anObject = require('./_an-object')\n , IE8_DOM_DEFINE = require('./_ie8-dom-define')\n , toPrimitive = require('./_to-primitive')\n , dP = Object.defineProperty;\n\nexports.f = require('./_descriptors') ? Object.defineProperty : function defineProperty(O, P, Attributes){\n anObject(O);\n P = toPrimitive(P, true);\n anObject(Attributes);\n if(IE8_DOM_DEFINE)try {\n return dP(O, P, Attributes);\n } catch(e){ /* empty */ }\n if('get' in Attributes || 'set' in Attributes)throw TypeError('Accessors not supported!');\n if('value' in Attributes)O[P] = Attributes.value;\n return O;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-dp.js\n// module id = 7\n// module chunks = 0","var toString = {}.toString;\n\nmodule.exports = function(it){\n return toString.call(it).slice(8, -1);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_cof.js\n// module id = 8\n// module chunks = 0","// optional / simple context binding\nvar aFunction = require('./_a-function');\nmodule.exports = function(fn, that, length){\n aFunction(fn);\n if(that === undefined)return fn;\n switch(length){\n case 1: return function(a){\n return fn.call(that, a);\n };\n case 2: return function(a, b){\n return fn.call(that, a, b);\n };\n case 3: return function(a, b, c){\n return fn.call(that, a, b, c);\n };\n }\n return function(/* ...args */){\n return fn.apply(that, arguments);\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_ctx.js\n// module id = 9\n// module chunks = 0","var hasOwnProperty = {}.hasOwnProperty;\nmodule.exports = function(it, key){\n return hasOwnProperty.call(it, key);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_has.js\n// module id = 10\n// module chunks = 0","module.exports = function(it){\n return typeof it === 'object' ? it !== null : typeof it === 'function';\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_is-object.js\n// module id = 11\n// module chunks = 0","module.exports = function(it){\n if(typeof it != 'function')throw TypeError(it + ' is not a function!');\n return it;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_a-function.js\n// module id = 12\n// module chunks = 0","// 7.2.1 RequireObjectCoercible(argument)\nmodule.exports = function(it){\n if(it == undefined)throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_defined.js\n// module id = 13\n// module chunks = 0","var isObject = require('./_is-object')\n , document = require('./_global').document\n // in old IE typeof document.createElement is 'object'\n , is = isObject(document) && isObject(document.createElement);\nmodule.exports = function(it){\n return is ? document.createElement(it) : {};\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_dom-create.js\n// module id = 14\n// module chunks = 0","var global = require('./_global')\n , core = require('./_core')\n , ctx = require('./_ctx')\n , hide = require('./_hide')\n , PROTOTYPE = 'prototype';\n\nvar $export = function(type, name, source){\n var IS_FORCED = type & $export.F\n , IS_GLOBAL = type & $export.G\n , IS_STATIC = type & $export.S\n , IS_PROTO = type & $export.P\n , IS_BIND = type & $export.B\n , IS_WRAP = type & $export.W\n , exports = IS_GLOBAL ? core : core[name] || (core[name] = {})\n , expProto = exports[PROTOTYPE]\n , target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE]\n , key, own, out;\n if(IS_GLOBAL)source = name;\n for(key in source){\n // contains in native\n own = !IS_FORCED && target && target[key] !== undefined;\n if(own && key in exports)continue;\n // export native or passed\n out = own ? target[key] : source[key];\n // prevent global pollution for namespaces\n exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]\n // bind timers to global for call from export context\n : IS_BIND && own ? ctx(out, global)\n // wrap global constructors for prevent change them in library\n : IS_WRAP && target[key] == out ? (function(C){\n var F = function(a, b, c){\n if(this instanceof C){\n switch(arguments.length){\n case 0: return new C;\n case 1: return new C(a);\n case 2: return new C(a, b);\n } return new C(a, b, c);\n } return C.apply(this, arguments);\n };\n F[PROTOTYPE] = C[PROTOTYPE];\n return F;\n // make static versions for prototype methods\n })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;\n // export proto methods to core.%CONSTRUCTOR%.methods.%NAME%\n if(IS_PROTO){\n (exports.virtual || (exports.virtual = {}))[key] = out;\n // export proto methods to core.%CONSTRUCTOR%.prototype.%NAME%\n if(type & $export.R && expProto && !expProto[key])hide(expProto, key, out);\n }\n }\n};\n// type bitmap\n$export.F = 1; // forced\n$export.G = 2; // global\n$export.S = 4; // static\n$export.P = 8; // proto\n$export.B = 16; // bind\n$export.W = 32; // wrap\n$export.U = 64; // safe\n$export.R = 128; // real proto method for `library` \nmodule.exports = $export;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_export.js\n// module id = 15\n// module chunks = 0","var def = require('./_object-dp').f\n , has = require('./_has')\n , TAG = require('./_wks')('toStringTag');\n\nmodule.exports = function(it, tag, stat){\n if(it && !has(it = stat ? it : it.prototype, TAG))def(it, TAG, {configurable: true, value: tag});\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_set-to-string-tag.js\n// module id = 16\n// module chunks = 0","var shared = require('./_shared')('keys')\n , uid = require('./_uid');\nmodule.exports = function(key){\n return shared[key] || (shared[key] = uid(key));\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_shared-key.js\n// module id = 17\n// module chunks = 0","// 7.1.4 ToInteger\nvar ceil = Math.ceil\n , floor = Math.floor;\nmodule.exports = function(it){\n return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-integer.js\n// module id = 18\n// module chunks = 0","// to indexed object, toObject with fallback for non-array-like ES3 strings\nvar IObject = require('./_iobject')\n , defined = require('./_defined');\nmodule.exports = function(it){\n return IObject(defined(it));\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-iobject.js\n// module id = 19\n// module chunks = 0","var g;\r\n\r\n// This works in non-strict mode\r\ng = (function() {\r\n\treturn this;\r\n})();\r\n\r\ntry {\r\n\t// This works if eval is allowed (see CSP)\r\n\tg = g || Function(\"return this\")() || (1,eval)(\"this\");\r\n} catch(e) {\r\n\t// This works if the window reference is available\r\n\tif(typeof window === \"object\")\r\n\t\tg = window;\r\n}\r\n\r\n// g can still be undefined, but nothing to do about it...\r\n// We return undefined, instead of nothing here, so it's\r\n// easier to handle this case. if(!global) { ...}\r\n\r\nmodule.exports = g;\r\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// (webpack)/buildin/global.js\n// module id = 20\n// module chunks = 0","// getting tag from 19.1.3.6 Object.prototype.toString()\nvar cof = require('./_cof')\n , TAG = require('./_wks')('toStringTag')\n // ES3 wrong here\n , ARG = cof(function(){ return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function(it, key){\n try {\n return it[key];\n } catch(e){ /* empty */ }\n};\n\nmodule.exports = function(it){\n var O, T, B;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T\n // builtinTag case\n : ARG ? cof(O)\n // ES3 arguments fallback\n : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_classof.js\n// module id = 21\n// module chunks = 0","// IE 8- don't enum bug keys\nmodule.exports = (\n 'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'\n).split(',');\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_enum-bug-keys.js\n// module id = 22\n// module chunks = 0","module.exports = function(exec){\n try {\n return !!exec();\n } catch(e){\n return true;\n }\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_fails.js\n// module id = 23\n// module chunks = 0","module.exports = require('./_global').document && document.documentElement;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_html.js\n// module id = 24\n// module chunks = 0","'use strict';\nvar LIBRARY = require('./_library')\n , $export = require('./_export')\n , redefine = require('./_redefine')\n , hide = require('./_hide')\n , has = require('./_has')\n , Iterators = require('./_iterators')\n , $iterCreate = require('./_iter-create')\n , setToStringTag = require('./_set-to-string-tag')\n , getPrototypeOf = require('./_object-gpo')\n , ITERATOR = require('./_wks')('iterator')\n , BUGGY = !([].keys && 'next' in [].keys()) // Safari has buggy iterators w/o `next`\n , FF_ITERATOR = '@@iterator'\n , KEYS = 'keys'\n , VALUES = 'values';\n\nvar returnThis = function(){ return this; };\n\nmodule.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED){\n $iterCreate(Constructor, NAME, next);\n var getMethod = function(kind){\n if(!BUGGY && kind in proto)return proto[kind];\n switch(kind){\n case KEYS: return function keys(){ return new Constructor(this, kind); };\n case VALUES: return function values(){ return new Constructor(this, kind); };\n } return function entries(){ return new Constructor(this, kind); };\n };\n var TAG = NAME + ' Iterator'\n , DEF_VALUES = DEFAULT == VALUES\n , VALUES_BUG = false\n , proto = Base.prototype\n , $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT]\n , $default = $native || getMethod(DEFAULT)\n , $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined\n , $anyNative = NAME == 'Array' ? proto.entries || $native : $native\n , methods, key, IteratorPrototype;\n // Fix native\n if($anyNative){\n IteratorPrototype = getPrototypeOf($anyNative.call(new Base));\n if(IteratorPrototype !== Object.prototype){\n // Set @@toStringTag to native iterators\n setToStringTag(IteratorPrototype, TAG, true);\n // fix for some old engines\n if(!LIBRARY && !has(IteratorPrototype, ITERATOR))hide(IteratorPrototype, ITERATOR, returnThis);\n }\n }\n // fix Array#{values, @@iterator}.name in V8 / FF\n if(DEF_VALUES && $native && $native.name !== VALUES){\n VALUES_BUG = true;\n $default = function values(){ return $native.call(this); };\n }\n // Define iterator\n if((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])){\n hide(proto, ITERATOR, $default);\n }\n // Plug for library\n Iterators[NAME] = $default;\n Iterators[TAG] = returnThis;\n if(DEFAULT){\n methods = {\n values: DEF_VALUES ? $default : getMethod(VALUES),\n keys: IS_SET ? $default : getMethod(KEYS),\n entries: $entries\n };\n if(FORCED)for(key in methods){\n if(!(key in proto))redefine(proto, key, methods[key]);\n } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);\n }\n return methods;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iter-define.js\n// module id = 25\n// module chunks = 0","module.exports = true;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_library.js\n// module id = 26\n// module chunks = 0","module.exports = function(bitmap, value){\n return {\n enumerable : !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable : !(bitmap & 4),\n value : value\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_property-desc.js\n// module id = 27\n// module chunks = 0","var global = require('./_global')\n , SHARED = '__core-js_shared__'\n , store = global[SHARED] || (global[SHARED] = {});\nmodule.exports = function(key){\n return store[key] || (store[key] = {});\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_shared.js\n// module id = 28\n// module chunks = 0","var ctx = require('./_ctx')\n , invoke = require('./_invoke')\n , html = require('./_html')\n , cel = require('./_dom-create')\n , global = require('./_global')\n , process = global.process\n , setTask = global.setImmediate\n , clearTask = global.clearImmediate\n , MessageChannel = global.MessageChannel\n , counter = 0\n , queue = {}\n , ONREADYSTATECHANGE = 'onreadystatechange'\n , defer, channel, port;\nvar run = function(){\n var id = +this;\n if(queue.hasOwnProperty(id)){\n var fn = queue[id];\n delete queue[id];\n fn();\n }\n};\nvar listener = function(event){\n run.call(event.data);\n};\n// Node.js 0.9+ & IE10+ has setImmediate, otherwise:\nif(!setTask || !clearTask){\n setTask = function setImmediate(fn){\n var args = [], i = 1;\n while(arguments.length > i)args.push(arguments[i++]);\n queue[++counter] = function(){\n invoke(typeof fn == 'function' ? fn : Function(fn), args);\n };\n defer(counter);\n return counter;\n };\n clearTask = function clearImmediate(id){\n delete queue[id];\n };\n // Node.js 0.8-\n if(require('./_cof')(process) == 'process'){\n defer = function(id){\n process.nextTick(ctx(run, id, 1));\n };\n // Browsers with MessageChannel, includes WebWorkers\n } else if(MessageChannel){\n channel = new MessageChannel;\n port = channel.port2;\n channel.port1.onmessage = listener;\n defer = ctx(port.postMessage, port, 1);\n // Browsers with postMessage, skip WebWorkers\n // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'\n } else if(global.addEventListener && typeof postMessage == 'function' && !global.importScripts){\n defer = function(id){\n global.postMessage(id + '', '*');\n };\n global.addEventListener('message', listener, false);\n // IE8-\n } else if(ONREADYSTATECHANGE in cel('script')){\n defer = function(id){\n html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function(){\n html.removeChild(this);\n run.call(id);\n };\n };\n // Rest old browsers\n } else {\n defer = function(id){\n setTimeout(ctx(run, id, 1), 0);\n };\n }\n}\nmodule.exports = {\n set: setTask,\n clear: clearTask\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_task.js\n// module id = 29\n// module chunks = 0","// 7.1.15 ToLength\nvar toInteger = require('./_to-integer')\n , min = Math.min;\nmodule.exports = function(it){\n return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-length.js\n// module id = 30\n// module chunks = 0","var id = 0\n , px = Math.random();\nmodule.exports = function(key){\n return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_uid.js\n// module id = 31\n// module chunks = 0","/**\n * Created by Denis Radin aka PixelsCommander\n * http://pixelscommander.com\n *\n * Polyfill is build around the principe that janks are most harmful to UX when user is continously interacting with app.\n * So we are basically preventing operation from being executed while user interacts with interface.\n * Currently this implies scrolls, taps, clicks, mouse and touch movements.\n * The condition is pretty simple - if there were no interactions for 300 msec there is a huge chance that we are in idle.\n */\n\nvar applyPolyfill = function () {\n //By default we may assume that user stopped interaction if we are idle for 300 miliseconds\n var IDLE_ENOUGH_DELAY = 300;\n var timeoutId = null;\n var callbacks = [];\n var lastInteractionTime = Date.now();\n var deadline = {\n timeRemaining: IDLE_ENOUGH_DELAY\n };\n\n var isFree = function () {\n return timeoutId === null;\n }\n\n var onContinousInteractionStarts = function (interactionName) {\n deadline.timeRemaining = 0;\n lastInteractionTime = Date.now();\n\n if (!timeoutId) {\n timeoutId = setTimeout(timeoutCompleted, IDLE_ENOUGH_DELAY);\n }\n }\n\n var onContinousInteractionEnds = function (interactionName) {\n clearTimeout(timeoutId);\n timeoutId = null;\n\n for (var i = 0; i < callbacks.length; i++) {\n executeCallback(callbacks[i])\n }\n }\n\n //Consider categorizing last interaction timestamp in order to add cancelling events like touchend, touchleave, touchcancel, mouseup, mouseout, mouseleave\n document.addEventListener('keydown', onContinousInteractionStarts.bind(this, 'keydown'));\n document.addEventListener('mousedown', onContinousInteractionStarts.bind(this, 'mousedown'));\n document.addEventListener('touchstart', onContinousInteractionStarts.bind(this, 'touchstart'));\n document.addEventListener('touchmove', onContinousInteractionStarts.bind(this, 'touchmove'));\n document.addEventListener('mousemove', onContinousInteractionStarts.bind(this, 'mousemove'));\n document.addEventListener('scroll', onContinousInteractionStarts.bind(this, 'scroll'), true);\n\n\n var timeoutCompleted = function () {\n var expectedEndTime = lastInteractionTime + IDLE_ENOUGH_DELAY;\n var delta = expectedEndTime - Date.now();\n\n if (delta > 0) {\n timeoutId = setTimeout(timeoutCompleted, delta);\n } else {\n onContinousInteractionEnds();\n }\n }\n\n var createCallbackObject = function (callback, timeout) {\n var callbackObject = {\n callback: callback,\n timeoutId: null\n };\n\n callbackObject.timeoutId = timeout !== null ? setTimeout(executeCallback.bind(this, callbackObject), timeout) : null;\n\n return callbackObject;\n }\n\n var addCallback = function (callbackObject, timeout) {\n callbacks.push(callbackObject);\n }\n\n var executeCallback = function (callbackObject) {\n var callbackIndex = callbacks.indexOf(callbackObject);\n\n if (callbackIndex !== -1) {\n callbacks.splice(callbacks.indexOf(callbackObject), 1);\n }\n\n callbackObject.callback(deadline);\n\n if (callbackObject.timeoutId) {\n clearTimeout(callbackObject.timeoutId);\n callbackObject.timeoutId = null;\n }\n }\n\n return function (callback, options) {\n var timeout = (options && options.timeout) || null;\n var callbackObject = createCallbackObject(callback, timeout);\n\n if (isFree()) {\n executeCallback(callbackObject);\n } else {\n addCallback(callbackObject);\n }\n };\n};\n\nif (!window.requestIdleCallback) {\n window.ricActivated = true;\n window.requestIdleCallback = applyPolyfill();\n}\n\nwindow.requestUserIdle = window.ricActivated && window.requestIdleCallback || applyPolyfill();\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/ric/src/ric-polyfill.js\n// module id = 32\n// module chunks = 0","//requestIdleCallback Polyfill\nrequire('ric');\n\n/**\n * Generates canvus starts\n * @param {num} arms -> number of arms on star\n * @param {num} x -> position x\n * @param {num} y -> position y\n * @param {num} outerRadius -> outter radius\n * @param {num} innerRadius -> innter radius\n * @param {dom} context -> canvus element\n * @param {str} colour -> color fill\n */\nconst drawStar = function (arms, x, y, outerRadius, innerRadius, context, colour) {\n const angle = (Math.PI / arms);\n context.fillStyle = colour;\n context.beginPath();\n for (let i = 0; i < 2 * arms; i++) {\n const r = (i & 1) ? innerRadius : outerRadius;\n const pointX = x + Math.cos(i * angle) * r;\n const pointY = y + Math.sin(i * angle) * r;\n\n if (!i) {\n context.moveTo(pointX, pointY);\n } else {\n context.lineTo(pointX, pointY);\n }\n }\n context.closePath();\n context.fill();\n};\n\n\n/**\n * Creates and draws the heat map\n * @param {ojb} options.ctx -> canvuas context\n * @param {arr} options.clickPoints -> data points to create clicks from [{}...]\n */\nconst drawClicks = function ({\n ctx, clickPoints\n}) {\n const self = this;\n const clickColor = self.clickColor || 'rgba(231, 76, 60, 0.75)';\n const clickSize = self.clickSize || 20;\n\n return new Promise(function (done) {\n window.requestUserIdle(function () {\n /**\n * Draw coordinate points\n */\n let point = null;\n for (let i = 0; i < clickPoints.length; i += 1) {\n point = clickPoints[i];\n //draw start\n drawStar(8, point.x, point.y, clickSize, clickSize / 2, ctx, clickColor);\n }\n\n //->\n done(true);\n }, {timeout: 2000});\n });\n\n};\n\nmodule.exports = drawClicks;\n\n\n\n// WEBPACK FOOTER //\n// ./lib/draw-click-map.js","const getPointValue = require('./get-point-value');\nconst getColor = require('./get-color.js');\n//requestIdleCallback Polyfill\nrequire('ric');\n\n/**\n * sorts based on i axis\n * @param {arr} dataPoints -> dataPoints to min/max\n * @param {str} i -> x | y\n * @return {obj} -> min/max\n */\nconst getMinMax = function (dataPoints, i = 'x') {\n dataPoints.sort(function (a, b) {\n return a[i] === b[i] ? a.x - b.x : a[i] - b[i];\n });\n return {\n min: dataPoints[0][i],\n max: dataPoints[dataPoints.length - 1][i]\n };\n};\n\n\n/**\n * Creates and draws the heat map\n * @param {ojb} options.ctx -> canvuas context\n * @param {num} options.limit -> neighborhood limit\n * @param {num} options.interval -> interpolation interval\n * @param {arr} options.dataPoints -> data points to create map from [{}...]\n * @param {arr} options.polygon -> the surounding convex polygon around dataPoints\n * @param {bln} options.cleanEdges -> to remove rough edges\n * @param {bln} options.mesh -> to create mesh-like map\n * @param {bln} options.points -> to draw coordinates for dataPoints\n * @param {num} options.pointSize -> size of coordinates points\n */\nconst drawHeatMap = function ({\n ctx, limit, interval, dataPoints, polygon, cleanEdges, mesh, points, pointSize\n}) {\n const self = this;\n const size = self.size;\n const hue = self.hue;\n const max = self.maxValue;\n const opacity = self.opacity;\n const thresh = self.threshold;\n const corners = self.corners;\n const radius = mesh ? interval * 1.5 : 1;\n return new Promise(function (done) {\n window.requestUserIdle(function () {\n //set up\n limit = limit > dataPoints.length ? dataPoints.length : limit + 1;\n const xMinMax = getMinMax(dataPoints, 'x');\n const yMinMax = getMinMax(dataPoints, 'y');\n const xMin = xMinMax.min;\n const yMin = yMinMax.min;\n const xMax = xMinMax.max;\n const yMax = yMinMax.max;\n const dbl = 2 * interval;\n let col = [];\n let val = 0.0;\n let x = 0;\n let y = 0;\n let color = '';\n let gradient = null;\n //clear pervious canvus before redraw\n ctx.clearRect(0, 0, size.width, size.height);\n\n //draw heatmap\n for (x = xMin; x < xMax; x += interval) {\n for (y = yMin; y < yMax; y += interval) {\n //get indv points value\n val = getPointValue(limit, polygon, dataPoints, {x, y});\n if (val !== -255) {\n ctx.beginPath();\n //get corresponding color to val\n col = getColor({val, hue, max});\n color = `rgba(${col[0]}, ${col[1]}, ${col[2]},`;\n gradient = ctx.createRadialGradient(x, y, radius, x, y, interval);\n gradient.addColorStop(0, color + opacity + ')');\n gradient.addColorStop(1, color + ' 0)');\n ctx.fillStyle = '#ffffff';\n ctx.lineJoin = 'round';\n ctx.fillStyle = gradient;\n ctx.fillRect(x - interval, y - interval, dbl, dbl);\n ctx.fill();\n ctx.closePath();\n }\n }\n }\n\n\n /**\n * Clean hard edges\n */\n if (!corners && (cleanEdges && polygon.length > 1)) {\n ctx.globalCompositeOperation = 'destination-in';\n ctx.fillStyle = '#ffffff';\n ctx.lineJoin = 'round';\n ctx.beginPath();\n ctx.moveTo(polygon[0].x, polygon[0].y);\n for (let i = 1; i < polygon.length; i++) {\n ctx.lineTo(polygon[i].x, polygon[i].y);\n }\n ctx.lineTo(polygon[0].x, polygon[0].y);\n ctx.closePath();\n ctx.fill();\n }\n\n\n /**\n * Draw coordinate points\n */\n if (points) {\n const PI2 = 2 * Math.PI;\n let point = null;\n for (let i = 0; i < dataPoints.length; i += 1) {\n point = dataPoints[i];\n if (point.value > thresh) {\n //get corresponding color to val\n color = getColor({val: point.value, hue, max});\n ctx.globalCompositeOperation = 'source-over';\n ctx.fillStyle = 'rgba(255, 255, 255, 0.95)';\n ctx.beginPath();\n ctx.arc(point.x, point.y, pointSize, 0, PI2, false);\n ctx.fill();\n ctx.lineWidth = pointSize / 4;\n ctx.strokeStyle = `rgba(${color[0]}, ${color[1]}, ${color[2]}, 0.8)`;\n ctx.beginPath();\n ctx.arc(point.x, point.y, pointSize, 0, PI2, false);\n ctx.stroke();\n ctx.textAlign = 'center';\n ctx.font = `${pointSize - 2}px monospace`;\n ctx.textBaseline = 'middle';\n ctx.fillStyle = '#474f50';\n ctx.fillText(Math.round(point.value), point.x, point.y);\n }\n }\n }\n\n //->\n done(true);\n }, {timeout: 2000});\n });\n\n};\n\nmodule.exports = drawHeatMap;\n\n\n\n// WEBPACK FOOTER //\n// ./lib/draw-heat-map.js","\n/**\n * Gets perpendicular vector\n */\nconst vectorProduct = function (a, b, c) {\n return (b.x - a.x) * (c.y - a.y) - (b.y - a.y) * (c.x - a.x);\n};\n\n/**\n * Creates an convex hull polygon - ie, the outter bounds around the points\n * @param {arr} points -> points to form polygon around\n * @return {arr} -> the polygon points\n */\nconst getConvexHullPolygon = function (points) {\n return new Promise(function (done) {\n const lower = [];\n const upper = [];\n\n for (let i = 0; i < points.length; i += 1) {\n while (lower.length >= 2 && vectorProduct(lower[lower.length - 2], lower[lower.length - 1], points[i]) <= 0) {\n lower.pop();\n }\n lower.push(points[i]);\n }\n for (let i = points.length - 1; i >= 0; i -= 1) {\n while (upper.length >= 2 && vectorProduct(upper[upper.length - 2], upper[upper.length - 1], points[i]) <= 0) {\n upper.pop();\n }\n upper.push(points[i]);\n }\n\n upper.pop();\n lower.pop();\n const polygon = lower.concat(upper);\n done(polygon);\n });\n};\n\nmodule.exports = getConvexHullPolygon;\n\n\n\n// WEBPACK FOOTER //\n// ./lib/get-convex-hull-polygon.js","\"use strict\";\n\nexports.__esModule = true;\n\nvar _promise = require(\"../core-js/promise\");\n\nvar _promise2 = _interopRequireDefault(_promise);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nexports.default = function (fn) {\n return function () {\n var gen = fn.apply(this, arguments);\n return new _promise2.default(function (resolve, reject) {\n function step(key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n return _promise2.default.resolve(value).then(function (value) {\n step(\"next\", value);\n }, function (err) {\n step(\"throw\", err);\n });\n }\n }\n\n return step(\"next\");\n });\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/helpers/asyncToGenerator.js\n// module id = 36\n// module chunks = 0","\"use strict\";\n\nexports.__esModule = true;\n\nexports.default = function (instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/helpers/classCallCheck.js\n// module id = 37\n// module chunks = 0","\"use strict\";\n\nexports.__esModule = true;\n\nvar _defineProperty = require(\"../core-js/object/define-property\");\n\nvar _defineProperty2 = _interopRequireDefault(_defineProperty);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nexports.default = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n (0, _defineProperty2.default)(target, descriptor.key, descriptor);\n }\n }\n\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n}();\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/helpers/createClass.js\n// module id = 38\n// module chunks = 0","module.exports = require(\"regenerator-runtime\");\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/regenerator/index.js\n// module id = 39\n// module chunks = 0","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _detectHover = require('detect-hover');\n\nvar _detectHover2 = _interopRequireDefault(_detectHover);\n\nvar _detectPointer = require('detect-pointer');\n\nvar _detectPointer2 = _interopRequireDefault(_detectPointer);\n\nvar _detectTouchEvents = require('detect-touch-events');\n\nvar _detectTouchEvents2 = _interopRequireDefault(_detectTouchEvents);\n\nvar _detectPassiveEvents = require('detect-passive-events');\n\nvar _detectPassiveEvents2 = _interopRequireDefault(_detectPassiveEvents);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n/*\n * detectIt object structure\n * const detectIt = {\n * deviceType: 'mouseOnly' / 'touchOnly' / 'hybrid',\n * passiveEvents: boolean,\n * hasTouch: boolean,\n * hasMouse: boolean,\n * maxTouchPoints: number,\n * primaryHover: 'hover' / 'none',\n * primaryPointer: 'fine' / 'coarse' / 'none',\n * state: {\n * detectHover,\n * detectPointer,\n * detectTouchEvents,\n * detectPassiveEvents,\n * },\n * update() {...},\n * }\n */\n\nfunction determineDeviceType(hasTouch, anyHover, anyFine, state) {\n // A hybrid device is one that both hasTouch and any input device can hover\n // or has a fine pointer.\n if (hasTouch && (anyHover || anyFine)) return 'hybrid';\n\n // workaround for browsers that have the touch events api,\n // and have implemented Level 4 media queries but not the\n // hover and pointer media queries, so the tests are all false (notable Firefox)\n // if it hasTouch, no pointer and hover support, and on an android assume it's touchOnly\n // if it hasTouch, no pointer and hover support, and not on an android assume it's a hybrid\n if (hasTouch && Object.keys(state.detectHover).filter(function (key) {\n return key !== 'update';\n }).every(function (key) {\n return state.detectHover[key] === false;\n }) && Object.keys(state.detectPointer).filter(function (key) {\n return key !== 'update';\n }).every(function (key) {\n return state.detectPointer[key] === false;\n })) {\n if (window.navigator && /android/.test(window.navigator.userAgent.toLowerCase())) {\n return 'touchOnly';\n }\n return 'hybrid';\n }\n\n // In almost all cases a device that doesn’t support touch will have a mouse,\n // but there may be rare exceptions. Note that it doesn’t work to do additional tests\n // based on hover and pointer media queries as older browsers don’t support these.\n // Essentially, 'mouseOnly' is the default.\n return hasTouch ? 'touchOnly' : 'mouseOnly';\n}\n\nvar detectIt = {\n state: {\n detectHover: _detectHover2.default,\n detectPointer: _detectPointer2.default,\n detectTouchEvents: _detectTouchEvents2.default,\n detectPassiveEvents: _detectPassiveEvents2.default\n },\n update: function update() {\n detectIt.state.detectHover.update();\n detectIt.state.detectPointer.update();\n detectIt.state.detectTouchEvents.update();\n detectIt.state.detectPassiveEvents.update();\n detectIt.updateOnlyOwnProperties();\n },\n updateOnlyOwnProperties: function updateOnlyOwnProperties() {\n if (typeof window !== 'undefined') {\n detectIt.passiveEvents = detectIt.state.detectPassiveEvents.hasSupport || false;\n\n detectIt.hasTouch = detectIt.state.detectTouchEvents.hasSupport || false;\n\n detectIt.deviceType = determineDeviceType(detectIt.hasTouch, detectIt.state.detectHover.anyHover, detectIt.state.detectPointer.anyFine, detectIt.state);\n\n detectIt.hasMouse = detectIt.deviceType !== 'touchOnly';\n\n detectIt.primaryInput = detectIt.deviceType === 'mouseOnly' && 'mouse' || detectIt.deviceType === 'touchOnly' && 'touch' ||\n // deviceType is hybrid:\n detectIt.state.detectHover.hover && 'mouse' || detectIt.state.detectHover.none && 'touch' ||\n // if there's no support for hover media queries but detectIt determined it's\n // a hybrid device, then assume it's a mouse first device\n 'mouse';\n }\n }\n};\n\ndetectIt.updateOnlyOwnProperties();\nexports.default = detectIt;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/detect-it/lib/index.js\n// module id = 40\n// module chunks = 0","/**\n * lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as the `TypeError` message for \"Functions\" methods. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max,\n nativeMin = Math.min;\n\n/**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\nvar now = function() {\n return root.Date.now();\n};\n\n/**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\nfunction debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n result = wait - timeSinceLastCall;\n\n return maxing ? nativeMin(result, maxWait - timeSinceLastInvoke) : result;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n}\n\n/**\n * Creates a throttled function that only invokes `func` at most once per\n * every `wait` milliseconds. The throttled function comes with a `cancel`\n * method to cancel delayed `func` invocations and a `flush` method to\n * immediately invoke them. Provide `options` to indicate whether `func`\n * should be invoked on the leading and/or trailing edge of the `wait`\n * timeout. The `func` is invoked with the last arguments provided to the\n * throttled function. Subsequent calls to the throttled function return the\n * result of the last `func` invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the throttled function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.throttle` and `_.debounce`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to throttle.\n * @param {number} [wait=0] The number of milliseconds to throttle invocations to.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=true]\n * Specify invoking on the leading edge of the timeout.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new throttled function.\n * @example\n *\n * // Avoid excessively updating the position while scrolling.\n * jQuery(window).on('scroll', _.throttle(updatePosition, 100));\n *\n * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.\n * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });\n * jQuery(element).on('click', throttled);\n *\n * // Cancel the trailing throttled invocation.\n * jQuery(window).on('popstate', throttled.cancel);\n */\nfunction throttle(func, wait, options) {\n var leading = true,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n if (isObject(options)) {\n leading = 'leading' in options ? !!options.leading : leading;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n return debounce(func, wait, {\n 'leading': leading,\n 'maxWait': wait,\n 'trailing': trailing\n });\n}\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = value.replace(reTrim, '');\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nmodule.exports = throttle;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/lodash.throttle/index.js\n// module id = 41\n// module chunks = 0","/**\n * Converts an HSL color value to RGB. Conversion formula\n * adapted from http://en.wikipedia.org/wiki/HSL_color_space.\n * Assumes h, s, and l are contained in the set [0, 1] and\n * returns r, g, and b in the set [0, 255].\n */\nconst hslToRgb = function (h, s, l) {\n let r, g, b;\n\n if(s === 0) {\n // achromatic\n r = g = b = l;\n }else{\n const hue2rgb = function (p, q, t) {\n if(t < 0) { t += 1; }\n if(t > 1) { t -= 1; }\n if(t < 1 / 6) { return p + (q - p) * 6 * t; }\n if(t < 1 / 2) { return q; }\n if(t < 2 / 3) { return p + (q - p) * (2 / 3 - t) * 6; }\n return p;\n };\n\n const q = l < 0.5 ? l * (1 + s) : l + s - l * s;\n const p = 2 * l - q;\n r = hue2rgb(p, q, h + 1 / 3);\n g = hue2rgb(p, q, h);\n b = hue2rgb(p, q, h - 1 / 3);\n }\n\n return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)];\n};\n\n/**\n * Gets color based on constrants\n */\nconst getColor = function ({hue, max, val}) {\n // 0 -> orange\n // 0.5 -> green\n // 1 -> violet\n const min = 0;\n const dif = max - min;\n val = val > max ? max : val < min ? min : val;\n return hslToRgb(1 - (1 - hue) - (((val - min) * hue) / dif), 1, 0.5);\n};\n\nmodule.exports = getColor;\n\n\n\n\n\n\n// WEBPACK FOOTER //\n// ./lib/get-color.js","/**\n * Gets the inverse distance weight of the point\n * @param {num} limit -> limit points\n * @param {arr} polygon -> the convex hull polygon\n * @param {arr} points -> all points\n * @param {num} options.x -> point in quesion\n * @param {num} options.y -> point in question\n * @return {num} -> value\n */\nconst getPointValue = function (limit, polygon, points, {x, y}) {\n let insidePolygon = false;\n let xa = 0;\n let xb = 0;\n let ya = 0;\n let yb = 0;\n let intersect = false;\n let p = polygon.length - 1;\n //find out if point inside the polygon\n for (let i = 0; i < polygon.length; i++) {\n xa = polygon[i].x;\n ya = polygon[i].y;\n xb = polygon[p].x;\n yb = polygon[p].y;\n intersect = ((ya > y) !== (yb > y)) && (x < (xb - xa) * (y - ya) / (yb - ya) + xa);\n insidePolygon = !intersect ? insidePolygon : !insidePolygon;\n p = i;\n }\n\n if (insidePolygon) {\n const arr = [];\n const pwr = 2;\n let dist = 0.0;\n let inv = 0.0;\n\n //square distances\n for (let i = 0; i < points.length; i++) {\n const distX = x - points[i].x;\n const distY = y - points[i].y;\n dist = distX * distX + distY * distY;\n if (dist === 0) {\n return points[i].value;\n }\n arr[i] = [dist, i];\n }\n\n arr.sort(function (a, b) {\n return a[0] - b[0];\n });\n\n //calc\n let b = 0.0;\n let ptr = 0;\n let t = 0.0;\n for (let i = 0; i < limit; i++) {\n ptr = arr[i];\n inv = 1 / Math.pow(ptr[0], pwr);\n t += inv * points[ptr[1]].value;\n b += inv;\n }\n return t / b;\n }\n\n return -255;\n};\n\nmodule.exports = getPointValue;\n\n\n\n// WEBPACK FOOTER //\n// ./lib/get-point-value.js","const lodashThrottle = require('lodash.throttle');\nconst detectIt = require('detect-it');\nconst getConvexHullPolygon = require('./get-convex-hull-polygon.js');\nconst drawHeatMap = require('./draw-heat-map.js');\nconst drawClickMap = require('./draw-click-map.js');\n\n\nclass FireMap {\n /**\n * @param {arr} dataPoints -> user data points for mouse\n * @param {arr} clickPoints -> user data points for clicks\n * @param {num} area -> sampling area which clusters all points\n * within its area into a single cluster\n * default is 5 so 5px by 5px sample area\n * @param {dom} canvas -> canvas dom element to draw map on\n * @param {bln} cleanEdges -> cleans edges of polygon to remove rough\n * edges to make it look pretty, only used\n * if corners is false\n * @param {str} clickColor -> color of the click point data stars\n * @param {num} clickSize -> size of the click point data stars\n * @param {num} corners -> creats pseudo data points for cornor of the\n * window so heatmap spans the entire screen\n * @param {num} height -> height of canvas || screen height\n * @param {num} hue -> color hue for map default is 0.5 green,\n * 0.8 violet, 3.5 rgbiv and no non-point color\n * @param {num} interval -> interpolation interval of unknown points,\n * the lower the number the more points\n * calculates which producesed a better map\n * @param {num} limit -> search neighborhood limit, higher num\n * smoother blend of map colors\n * but it also increase computation time\n * @param {num} maxValue -> max value for color default is 100\n * so any value above 100 is going to be the\n * same color\n * @param {bln} mesh -> to create a mesh-like map rather then\n * a solid map\n * @param {num} opacity -> opacity of canvus fill\n * @param {bln} points -> to draw data marker point coordinates\n * @param {num} pointSize -> font-size of points\n * @param {obj} styles -> custom CSS canvas styles\n * @param {fnk} subscribe -> a subscribe function that is invoked on\n * the mouse tracking & click event,\n * passes the event and binded to this\n * @param {num} threshold -> point values has to be higher than threshold\n * @param {num} throttle -> mouse tracker throttle\n * @param {num} width -> width of canvas || screen width\n */\n constructor({\n //user data points\n dataPoints = [], clickPoints = [], subscribe,\n //cavus setting\n canvas, width, height, area = 10, maxValue = 100, styles = {},\n //map appearance settings\n hue = 0.5, opacity = 0.8, cleanEdges = true,\n //mouse event setting\n throttle = 100, threshold = 110,\n //draw setting\n corners = true, limit = 100, interval = 8, mesh = false, points = false, pointSize = 13,\n //click setting\n clickTrack = false, clickSize, clickColor\n } = {}) {\n const self = this;\n self.error = false;\n\n /**\n * Error gate\n */\n canvas = canvas\n || document.getElementsByTagName('canvas')\n && document.getElementsByTagName('canvas')[0];\n if (!canvas) {\n self.error = true;\n console.error('Fatal Fire Map Error: Canvas element not found, cannot proceed.');\n return false;\n }\n /**\n * User data\n */\n self.dataPoints = dataPoints;\n self.clickPoints = clickPoints;\n\n /**\n * Tracking Vars/setup\n */\n self.area = area;\n self.throttle = throttle;\n self.threshold = threshold;\n const getDocSize = function(axis = 'Width') {\n const D = document;\n return Math.max(\n D.body[`scroll${axis}`], D.documentElement[`scroll${axis}`],\n D.body[`offset${axis}`], D.documentElement[`offset${axis}`],\n D.body[`client${axis}`], D.documentElement[`client${axis}`]\n );\n };\n self.width = width ? width : getDocSize('Width');\n self.height = height ? height : getDocSize('Height');\n //used in mouse track\n self._time = false;\n self._temp = [];\n //create location matrix, add one for safty\n self.data = [];\n self.data.length = Math.round((self.width + self.area) / self.area) + 1;\n const ySize = Math.round((self.height + self.area) / self.area) + 1;\n for (let i = self.data.length - 1; i >= 0; i--) {\n self.data[i] = [];\n self.data[i].length = ySize;\n }\n //checks for clickTracking and creates need be\n self.clickTrack = clickTrack;\n if (self.clickTrack) {\n self.clickData = [];\n self.clickData.length = Math.round((self.width + self.area) / self.area) + 1;\n for (let i = self.clickData.length - 1; i >= 0; i--) {\n self.clickData[i] = [];\n self.clickData[i].length = ySize;\n }\n }\n\n /**\n * HeatMap\n */\n self.drawHeatMap = drawHeatMap.bind(self);\n self.drawClickMap = drawClickMap.bind(self);\n self.maxValue = maxValue;\n self.hue = hue;\n self.cleanEdges = cleanEdges;\n self.opacity = opacity;\n self.ctx = null;\n //set canvus to take up entire screen\n canvas.width = self.width;\n canvas.height = self.height;\n self.canvas = canvas;\n self.points = [];\n self.polygon = [];\n self.limits = {\n xMin: 0,\n xMax: 0,\n yMin: 0,\n yMax: 0\n };\n self.size = {\n height: canvas.height,\n width: canvas.width\n };\n //set canvus style props\n styles = Object.assign({\n position: 'absolute',\n top: '0',\n left: '0',\n opacity: opacity\n }, styles);\n Object.keys(styles).forEach(function (key) {\n canvas.style[key] = styles[key];\n });\n\n /**\n * Draw\n */\n self.corners = corners;\n self.limit = limit;\n self.interval = interval;\n self.mesh = mesh;\n self.points = points;\n self.pointSize = pointSize;\n //clicks\n self.clickSize = clickSize;\n self.clickColor = clickColor;\n\n //used for realtime tracking\n if (typeof subscribe === 'function') {\n self.subscribe = subscribe.bind(self);\n }\n self.dataPointCount = false;\n }\n\n\n\n /**\n * Draws the heatzmap based on data points\n * @param {arr} options.dataPoints -> user data points for mouse\n * @param {arr} options.clickPoint -> user data points for clicks\n * @param {num} options.clickSize -> size of the click point data stars\n * @param {str} options.clickColor -> color of the click point data stars\n * @param {fnk} options.cb -> Callback function invoked upon completion\n * and binded to instance with the first arg\n * being the canvas context (ctx)\n * @param {num} options.hue -> color hue for map default is 0.5 green,\n * 0.8 violet, 3.5 rgbiv and no non-point color\n * @param {num} options. interval -> interpolation interval of unknown points,\n * the lower the number the more points\n * calculates which producesed a better\n * @param {num} options.limit -> search neighborhood limit, higher num\n * smoother blend of map colors\n * @param {bln} options.mesh -> to create a mesh-like map rather then\n * a solid map\n * @param {num} options.opacity -> opacity of canvus fill\n * @param {bln} options.points -> to draw data marker point coordinates\n * @param {num} options.pointSize -> font-size of points\n * @param {num} options.threshold -> point values has to be higher than threshold\n */\n draw ({\n dataPoints, clickPoints, limit, interval,\n mesh, points, pointSize, threshold, hue, opacity, clickSize, clickColor,\n cb = false\n } = {}) {\n const self = this;\n dataPoints = dataPoints !== undefined ? dataPoints : self.dataPoints;\n clickPoints = clickPoints !== undefined ? clickPoints : self.clickPoints;\n limit = limit !== undefined ? limit : self.limit;\n interval = interval !== undefined ? interval : self.interval;\n mesh = mesh !== undefined ? mesh : self.mesh;\n points = points !== undefined ? points : self.points;\n pointSize = pointSize !== undefined ? pointSize : self.pointSize;\n //self vars\n self.threshold = threshold !== undefined ? threshold : self.threshold;\n self.hue = hue !== undefined ? hue : self.hue;\n self.opacity = opacity !== undefined ? opacity : self.opacity;\n self.clickSize = clickSize !== undefined ? clickSize : self.clickSize;\n self.clickColor = clickColor !== undefined ? clickColor : self.clickColor;\n let ctx;\n /**\n * Wrapper so that we don't trip up the main thread. draw-heat-map also\n * is wrapped via requestUserIdle to only execue on idle\n */\n const run = async function run () {\n //cannot't clean with real time\n const cleanEdges = dataPoints ? self.cleanEdges : false;\n ctx = self.canvas.getContext('2d');\n dataPoints = dataPoints.length ? dataPoints : await self.getData();\n if (dataPoints.length) {\n const polygon = await getConvexHullPolygon(dataPoints);\n await self.drawHeatMap({\n ctx, limit, interval, dataPoints, polygon, cleanEdges, mesh, points, pointSize\n });\n }\n //clickpoints\n clickPoints = clickPoints === true\n ? await self.getData(self.clickData || [], true)\n : clickPoints;\n if (clickPoints.length) {\n await self.drawClickMap({ctx, clickPoints});\n }\n return true;\n };\n run().then(function () {\n console.log('Draw Complete');\n if (cb) {\n cb.apply(self, [ctx]);\n }\n });\n }\n\n\n /**\n * Formats the data matricks are removes undefined data\n * @param {arr} source -> Source data\n * @return {prm} -> promise([{x, y, value} ...])\n */\n getData (source = null, click = false) {\n const self = this;\n return new Promise(function (done) {\n source = source || self.data;\n const data = [];\n let value = null;\n for (let x = source.length - 1; x >= 0; x--) {\n for (let y = source[x].length - 1; y >= 0; y--) {\n value = source[x][y];\n if (value) {\n data.push({\n x: x * self.area,\n y: y * self.area,\n value: !click ? value / 10 : value\n });\n }\n }\n }\n done(data);\n });\n }\n\n\n /**\n * Client init to start tracking mouse movements\n */\n init(subscribe = null) {\n const self = this;\n if (!self.error) {\n //subscribe set up\n self.subscribe = subscribe && typeof subscribe === 'function'\n ? subscribe.bind(self)\n : self.subscribe;\n const sub = (event, type) => self.subscribe && self.subscribe(event, type);\n //mouse movement\n self._trackAndLogMouse = self._trackAndLogMouse.bind(self);\n document.addEventListener('mousemove',\n lodashThrottle(function (event) {\n self._trackAndLogMouse(event);\n sub(event, 'mousemove');\n }, self.throttle),\n detectIt.passiveEvents ? {passive: true} : false\n );\n\n //click\n if (self.clickTrack) {\n self._logClicks = self._logClicks.bind(self);\n document.addEventListener('pointerdown',\n lodashThrottle(function (event) {\n self._logClicks(event);\n sub(event, 'pointerdown');\n }, 75),\n detectIt.passiveEvents ? {passive: true} : false\n );\n }\n\n //used so that tracker resets otherwise you get edge outliers\n document.addEventListener('pointerdown', function () {\n self._time = new Date();\n }, detectIt.passiveEvents ? {passive: true} : false);\n }\n //places data points at corners of canvus\n if (self.corners) {\n const val = 1;\n const x = self.data.length - 1;\n const y = self.data[0].length - 1;\n self.data[0][0] = val;\n self.data[0][y] = val;\n self.data[x][0] = val;\n self.data[x][y] = val;\n }\n }\n\n\n _setCoordinates(x, y, mouse = true) {\n const self = this;\n const posX = Math.round(x / self.area);\n const posY = Math.round(y / self.area);\n //mouse loging\n if (mouse) {\n if (!self._time || !self._temp.length) {\n self._time = new Date();\n self._temp = [posX, posY];\n }else {\n const newTime = new Date();\n const time = newTime - self._time;\n //set current data\n const temp = self._temp;\n //set data, and error check\n if (self.data[temp[0]]) {\n const data = self.data[temp[0]][temp[1]];\n self.data[temp[0]][temp[1]] = !data ? time : (data + time);\n }\n //store new time + temp\n self._time = newTime;\n self._temp = [posX, posY];\n }\n //for real time update\n if (self.dataPointCount) {\n self.dataPointCount.count += 1;\n }\n }else {\n //click track\n const data = self.clickData[posX][posY];\n self.clickData[posX][posY] = !data ? 1 : (data + 1);\n }\n }\n\n\n /**\n * Tracks mouse events set movements to _setCoordinates\n */\n _trackAndLogMouse(event) {\n const self = this;\n event = event || window.event;\n if (event.pageX === null && event.clientX !== null) {\n const eventDoc = (event.target && event.target.ownerDocument) || document;\n const doc = eventDoc.documentElement;\n const body = eventDoc.body;\n\n event.pageX = event.clientX +\n (doc && doc.scrollLeft || body && body.scrollLeft || 0) -\n (doc && doc.clientLeft || body && body.clientLeft || 0);\n event.pageY = event.clientY +\n (doc && doc.scrollTop || body && body.scrollTop || 0) -\n (doc && doc.clientTop || body && body.clientTop || 0);\n }\n self._setCoordinates(event.pageX, event.pageY);\n }\n\n\n /**\n * Tracks clicks\n */\n _logClicks(event) {\n const self = this;\n event = event || window.event;\n if (event.pageX === null && event.clientX !== null) {\n const eventDoc = (event.target && event.target.ownerDocument) || document;\n const doc = eventDoc.documentElement;\n const body = eventDoc.body;\n\n event.pageX = event.clientX +\n (doc && doc.scrollLeft || body && body.scrollLeft || 0) -\n (doc && doc.clientLeft || body && body.clientLeft || 0);\n event.pageY = event.clientY +\n (doc && doc.scrollTop || body && body.scrollTop || 0) -\n (doc && doc.clientTop || body && body.clientTop || 0);\n }\n self._setCoordinates(event.pageX, event.pageY, false);\n }\n\n\n /**\n * Updates heatmap in real time\n * @param {num} interval -> update heatmap every x data points\n */\n realTime (drawInterval = 10) {\n const self = this;\n const dataPointCount = {count: 0};\n const proxy = new Proxy(dataPointCount, {\n set: function (target, property, value) {\n target[property] = value;\n if (value % drawInterval === 0) {\n self.draw();\n }\n return true;\n }\n });\n self.dataPointCount = proxy;\n }\n}\n\n\nexport default FireMap;\n\n\n\n// WEBPACK FOOTER //\n// ./lib/index.js","module.exports = { \"default\": require(\"core-js/library/fn/object/define-property\"), __esModule: true };\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/core-js/object/define-property.js\n// module id = 45\n// module chunks = 0","module.exports = { \"default\": require(\"core-js/library/fn/promise\"), __esModule: true };\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/babel-runtime/core-js/promise.js\n// module id = 46\n// module chunks = 0","require('../../modules/es6.object.define-property');\nvar $Object = require('../../modules/_core').Object;\nmodule.exports = function defineProperty(it, key, desc){\n return $Object.defineProperty(it, key, desc);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/fn/object/define-property.js\n// module id = 47\n// module chunks = 0","require('../modules/es6.object.to-string');\nrequire('../modules/es6.string.iterator');\nrequire('../modules/web.dom.iterable');\nrequire('../modules/es6.promise');\nmodule.exports = require('../modules/_core').Promise;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/fn/promise.js\n// module id = 48\n// module chunks = 0","module.exports = function(){ /* empty */ };\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_add-to-unscopables.js\n// module id = 49\n// module chunks = 0","module.exports = function(it, Constructor, name, forbiddenField){\n if(!(it instanceof Constructor) || (forbiddenField !== undefined && forbiddenField in it)){\n throw TypeError(name + ': incorrect invocation!');\n } return it;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_an-instance.js\n// module id = 50\n// module chunks = 0","// false -> Array#indexOf\n// true -> Array#includes\nvar toIObject = require('./_to-iobject')\n , toLength = require('./_to-length')\n , toIndex = require('./_to-index');\nmodule.exports = function(IS_INCLUDES){\n return function($this, el, fromIndex){\n var O = toIObject($this)\n , length = toLength(O.length)\n , index = toIndex(fromIndex, length)\n , value;\n // Array#includes uses SameValueZero equality algorithm\n if(IS_INCLUDES && el != el)while(length > index){\n value = O[index++];\n if(value != value)return true;\n // Array#toIndex ignores holes, Array#includes - not\n } else for(;length > index; index++)if(IS_INCLUDES || index in O){\n if(O[index] === el)return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_array-includes.js\n// module id = 51\n// module chunks = 0","var ctx = require('./_ctx')\n , call = require('./_iter-call')\n , isArrayIter = require('./_is-array-iter')\n , anObject = require('./_an-object')\n , toLength = require('./_to-length')\n , getIterFn = require('./core.get-iterator-method')\n , BREAK = {}\n , RETURN = {};\nvar exports = module.exports = function(iterable, entries, fn, that, ITERATOR){\n var iterFn = ITERATOR ? function(){ return iterable; } : getIterFn(iterable)\n , f = ctx(fn, that, entries ? 2 : 1)\n , index = 0\n , length, step, iterator, result;\n if(typeof iterFn != 'function')throw TypeError(iterable + ' is not iterable!');\n // fast case for arrays with default iterator\n if(isArrayIter(iterFn))for(length = toLength(iterable.length); length > index; index++){\n result = entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);\n if(result === BREAK || result === RETURN)return result;\n } else for(iterator = iterFn.call(iterable); !(step = iterator.next()).done; ){\n result = call(iterator, f, step.value, entries);\n if(result === BREAK || result === RETURN)return result;\n }\n};\nexports.BREAK = BREAK;\nexports.RETURN = RETURN;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_for-of.js\n// module id = 52\n// module chunks = 0","module.exports = !require('./_descriptors') && !require('./_fails')(function(){\n return Object.defineProperty(require('./_dom-create')('div'), 'a', {get: function(){ return 7; }}).a != 7;\n});\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_ie8-dom-define.js\n// module id = 53\n// module chunks = 0","// fast apply, http://jsperf.lnkit.com/fast-apply/5\nmodule.exports = function(fn, args, that){\n var un = that === undefined;\n switch(args.length){\n case 0: return un ? fn()\n : fn.call(that);\n case 1: return un ? fn(args[0])\n : fn.call(that, args[0]);\n case 2: return un ? fn(args[0], args[1])\n : fn.call(that, args[0], args[1]);\n case 3: return un ? fn(args[0], args[1], args[2])\n : fn.call(that, args[0], args[1], args[2]);\n case 4: return un ? fn(args[0], args[1], args[2], args[3])\n : fn.call(that, args[0], args[1], args[2], args[3]);\n } return fn.apply(that, args);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_invoke.js\n// module id = 54\n// module chunks = 0","// fallback for non-array-like ES3 and non-enumerable old V8 strings\nvar cof = require('./_cof');\nmodule.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it){\n return cof(it) == 'String' ? it.split('') : Object(it);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iobject.js\n// module id = 55\n// module chunks = 0","// check on default Array iterator\nvar Iterators = require('./_iterators')\n , ITERATOR = require('./_wks')('iterator')\n , ArrayProto = Array.prototype;\n\nmodule.exports = function(it){\n return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_is-array-iter.js\n// module id = 56\n// module chunks = 0","// call something on iterator step with safe closing on error\nvar anObject = require('./_an-object');\nmodule.exports = function(iterator, fn, value, entries){\n try {\n return entries ? fn(anObject(value)[0], value[1]) : fn(value);\n // 7.4.6 IteratorClose(iterator, completion)\n } catch(e){\n var ret = iterator['return'];\n if(ret !== undefined)anObject(ret.call(iterator));\n throw e;\n }\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iter-call.js\n// module id = 57\n// module chunks = 0","'use strict';\nvar create = require('./_object-create')\n , descriptor = require('./_property-desc')\n , setToStringTag = require('./_set-to-string-tag')\n , IteratorPrototype = {};\n\n// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()\nrequire('./_hide')(IteratorPrototype, require('./_wks')('iterator'), function(){ return this; });\n\nmodule.exports = function(Constructor, NAME, next){\n Constructor.prototype = create(IteratorPrototype, {next: descriptor(1, next)});\n setToStringTag(Constructor, NAME + ' Iterator');\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iter-create.js\n// module id = 58\n// module chunks = 0","var ITERATOR = require('./_wks')('iterator')\n , SAFE_CLOSING = false;\n\ntry {\n var riter = [7][ITERATOR]();\n riter['return'] = function(){ SAFE_CLOSING = true; };\n Array.from(riter, function(){ throw 2; });\n} catch(e){ /* empty */ }\n\nmodule.exports = function(exec, skipClosing){\n if(!skipClosing && !SAFE_CLOSING)return false;\n var safe = false;\n try {\n var arr = [7]\n , iter = arr[ITERATOR]();\n iter.next = function(){ return {done: safe = true}; };\n arr[ITERATOR] = function(){ return iter; };\n exec(arr);\n } catch(e){ /* empty */ }\n return safe;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iter-detect.js\n// module id = 59\n// module chunks = 0","module.exports = function(done, value){\n return {value: value, done: !!done};\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_iter-step.js\n// module id = 60\n// module chunks = 0","var global = require('./_global')\n , macrotask = require('./_task').set\n , Observer = global.MutationObserver || global.WebKitMutationObserver\n , process = global.process\n , Promise = global.Promise\n , isNode = require('./_cof')(process) == 'process';\n\nmodule.exports = function(){\n var head, last, notify;\n\n var flush = function(){\n var parent, fn;\n if(isNode && (parent = process.domain))parent.exit();\n while(head){\n fn = head.fn;\n head = head.next;\n try {\n fn();\n } catch(e){\n if(head)notify();\n else last = undefined;\n throw e;\n }\n } last = undefined;\n if(parent)parent.enter();\n };\n\n // Node.js\n if(isNode){\n notify = function(){\n process.nextTick(flush);\n };\n // browsers with MutationObserver\n } else if(Observer){\n var toggle = true\n , node = document.createTextNode('');\n new Observer(flush).observe(node, {characterData: true}); // eslint-disable-line no-new\n notify = function(){\n node.data = toggle = !toggle;\n };\n // environments with maybe non-completely correct, but existent Promise\n } else if(Promise && Promise.resolve){\n var promise = Promise.resolve();\n notify = function(){\n promise.then(flush);\n };\n // for other environments - macrotask based on:\n // - setImmediate\n // - MessageChannel\n // - window.postMessag\n // - onreadystatechange\n // - setTimeout\n } else {\n notify = function(){\n // strange IE + webpack dev server bug - use .call(global)\n macrotask.call(global, flush);\n };\n }\n\n return function(fn){\n var task = {fn: fn, next: undefined};\n if(last)last.next = task;\n if(!head){\n head = task;\n notify();\n } last = task;\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_microtask.js\n// module id = 61\n// module chunks = 0","// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])\nvar anObject = require('./_an-object')\n , dPs = require('./_object-dps')\n , enumBugKeys = require('./_enum-bug-keys')\n , IE_PROTO = require('./_shared-key')('IE_PROTO')\n , Empty = function(){ /* empty */ }\n , PROTOTYPE = 'prototype';\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar createDict = function(){\n // Thrash, waste and sodomy: IE GC bug\n var iframe = require('./_dom-create')('iframe')\n , i = enumBugKeys.length\n , lt = '<'\n , gt = '>'\n , iframeDocument;\n iframe.style.display = 'none';\n require('./_html').appendChild(iframe);\n iframe.src = 'javascript:'; // eslint-disable-line no-script-url\n // createDict = iframe.contentWindow.Object;\n // html.removeChild(iframe);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt);\n iframeDocument.close();\n createDict = iframeDocument.F;\n while(i--)delete createDict[PROTOTYPE][enumBugKeys[i]];\n return createDict();\n};\n\nmodule.exports = Object.create || function create(O, Properties){\n var result;\n if(O !== null){\n Empty[PROTOTYPE] = anObject(O);\n result = new Empty;\n Empty[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = createDict();\n return Properties === undefined ? result : dPs(result, Properties);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-create.js\n// module id = 62\n// module chunks = 0","var dP = require('./_object-dp')\n , anObject = require('./_an-object')\n , getKeys = require('./_object-keys');\n\nmodule.exports = require('./_descriptors') ? Object.defineProperties : function defineProperties(O, Properties){\n anObject(O);\n var keys = getKeys(Properties)\n , length = keys.length\n , i = 0\n , P;\n while(length > i)dP.f(O, P = keys[i++], Properties[P]);\n return O;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-dps.js\n// module id = 63\n// module chunks = 0","// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)\nvar has = require('./_has')\n , toObject = require('./_to-object')\n , IE_PROTO = require('./_shared-key')('IE_PROTO')\n , ObjectProto = Object.prototype;\n\nmodule.exports = Object.getPrototypeOf || function(O){\n O = toObject(O);\n if(has(O, IE_PROTO))return O[IE_PROTO];\n if(typeof O.constructor == 'function' && O instanceof O.constructor){\n return O.constructor.prototype;\n } return O instanceof Object ? ObjectProto : null;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-gpo.js\n// module id = 64\n// module chunks = 0","var has = require('./_has')\n , toIObject = require('./_to-iobject')\n , arrayIndexOf = require('./_array-includes')(false)\n , IE_PROTO = require('./_shared-key')('IE_PROTO');\n\nmodule.exports = function(object, names){\n var O = toIObject(object)\n , i = 0\n , result = []\n , key;\n for(key in O)if(key != IE_PROTO)has(O, key) && result.push(key);\n // Don't enum bug & hidden keys\n while(names.length > i)if(has(O, key = names[i++])){\n ~arrayIndexOf(result, key) || result.push(key);\n }\n return result;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-keys-internal.js\n// module id = 65\n// module chunks = 0","// 19.1.2.14 / 15.2.3.14 Object.keys(O)\nvar $keys = require('./_object-keys-internal')\n , enumBugKeys = require('./_enum-bug-keys');\n\nmodule.exports = Object.keys || function keys(O){\n return $keys(O, enumBugKeys);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_object-keys.js\n// module id = 66\n// module chunks = 0","var hide = require('./_hide');\nmodule.exports = function(target, src, safe){\n for(var key in src){\n if(safe && target[key])target[key] = src[key];\n else hide(target, key, src[key]);\n } return target;\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_redefine-all.js\n// module id = 67\n// module chunks = 0","module.exports = require('./_hide');\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_redefine.js\n// module id = 68\n// module chunks = 0","'use strict';\nvar global = require('./_global')\n , core = require('./_core')\n , dP = require('./_object-dp')\n , DESCRIPTORS = require('./_descriptors')\n , SPECIES = require('./_wks')('species');\n\nmodule.exports = function(KEY){\n var C = typeof core[KEY] == 'function' ? core[KEY] : global[KEY];\n if(DESCRIPTORS && C && !C[SPECIES])dP.f(C, SPECIES, {\n configurable: true,\n get: function(){ return this; }\n });\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_set-species.js\n// module id = 69\n// module chunks = 0","// 7.3.20 SpeciesConstructor(O, defaultConstructor)\nvar anObject = require('./_an-object')\n , aFunction = require('./_a-function')\n , SPECIES = require('./_wks')('species');\nmodule.exports = function(O, D){\n var C = anObject(O).constructor, S;\n return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_species-constructor.js\n// module id = 70\n// module chunks = 0","var toInteger = require('./_to-integer')\n , defined = require('./_defined');\n// true -> String#at\n// false -> String#codePointAt\nmodule.exports = function(TO_STRING){\n return function(that, pos){\n var s = String(defined(that))\n , i = toInteger(pos)\n , l = s.length\n , a, b;\n if(i < 0 || i >= l)return TO_STRING ? '' : undefined;\n a = s.charCodeAt(i);\n return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff\n ? TO_STRING ? s.charAt(i) : a\n : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;\n };\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_string-at.js\n// module id = 71\n// module chunks = 0","var toInteger = require('./_to-integer')\n , max = Math.max\n , min = Math.min;\nmodule.exports = function(index, length){\n index = toInteger(index);\n return index < 0 ? max(index + length, 0) : min(index, length);\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-index.js\n// module id = 72\n// module chunks = 0","// 7.1.13 ToObject(argument)\nvar defined = require('./_defined');\nmodule.exports = function(it){\n return Object(defined(it));\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-object.js\n// module id = 73\n// module chunks = 0","// 7.1.1 ToPrimitive(input [, PreferredType])\nvar isObject = require('./_is-object');\n// instead of the ES6 spec version, we didn't implement @@toPrimitive case\n// and the second argument - flag - preferred type is a string\nmodule.exports = function(it, S){\n if(!isObject(it))return it;\n var fn, val;\n if(S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val;\n if(typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it)))return val;\n if(!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/_to-primitive.js\n// module id = 74\n// module chunks = 0","var classof = require('./_classof')\n , ITERATOR = require('./_wks')('iterator')\n , Iterators = require('./_iterators');\nmodule.exports = require('./_core').getIteratorMethod = function(it){\n if(it != undefined)return it[ITERATOR]\n || it['@@iterator']\n || Iterators[classof(it)];\n};\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/core.get-iterator-method.js\n// module id = 75\n// module chunks = 0","'use strict';\nvar addToUnscopables = require('./_add-to-unscopables')\n , step = require('./_iter-step')\n , Iterators = require('./_iterators')\n , toIObject = require('./_to-iobject');\n\n// 22.1.3.4 Array.prototype.entries()\n// 22.1.3.13 Array.prototype.keys()\n// 22.1.3.29 Array.prototype.values()\n// 22.1.3.30 Array.prototype[@@iterator]()\nmodule.exports = require('./_iter-define')(Array, 'Array', function(iterated, kind){\n this._t = toIObject(iterated); // target\n this._i = 0; // next index\n this._k = kind; // kind\n// 22.1.5.2.1 %ArrayIteratorPrototype%.next()\n}, function(){\n var O = this._t\n , kind = this._k\n , index = this._i++;\n if(!O || index >= O.length){\n this._t = undefined;\n return step(1);\n }\n if(kind == 'keys' )return step(0, index);\n if(kind == 'values')return step(0, O[index]);\n return step(0, [index, O[index]]);\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)\nIterators.Arguments = Iterators.Array;\n\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/es6.array.iterator.js\n// module id = 76\n// module chunks = 0","var $export = require('./_export');\n// 19.1.2.4 / 15.2.3.6 Object.defineProperty(O, P, Attributes)\n$export($export.S + $export.F * !require('./_descriptors'), 'Object', {defineProperty: require('./_object-dp').f});\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/es6.object.define-property.js\n// module id = 77\n// module chunks = 0","'use strict';\nvar LIBRARY = require('./_library')\n , global = require('./_global')\n , ctx = require('./_ctx')\n , classof = require('./_classof')\n , $export = require('./_export')\n , isObject = require('./_is-object')\n , aFunction = require('./_a-function')\n , anInstance = require('./_an-instance')\n , forOf = require('./_for-of')\n , speciesConstructor = require('./_species-constructor')\n , task = require('./_task').set\n , microtask = require('./_microtask')()\n , PROMISE = 'Promise'\n , TypeError = global.TypeError\n , process = global.process\n , $Promise = global[PROMISE]\n , process = global.process\n , isNode = classof(process) == 'process'\n , empty = function(){ /* empty */ }\n , Internal, GenericPromiseCapability, Wrapper;\n\nvar USE_NATIVE = !!function(){\n try {\n // correct subclassing with @@species support\n var promise = $Promise.resolve(1)\n , FakePromise = (promise.constructor = {})[require('./_wks')('species')] = function(exec){ exec(empty, empty); };\n // unhandled rejections tracking support, NodeJS Promise without it fails @@species test\n return (isNode || typeof PromiseRejectionEvent == 'function') && promise.then(empty) instanceof FakePromise;\n } catch(e){ /* empty */ }\n}();\n\n// helpers\nvar sameConstructor = function(a, b){\n // with library wrapper special case\n return a === b || a === $Promise && b === Wrapper;\n};\nvar isThenable = function(it){\n var then;\n return isObject(it) && typeof (then = it.then) == 'function' ? then : false;\n};\nvar newPromiseCapability = function(C){\n return sameConstructor($Promise, C)\n ? new PromiseCapability(C)\n : new GenericPromiseCapability(C);\n};\nvar PromiseCapability = GenericPromiseCapability = function(C){\n var resolve, reject;\n this.promise = new C(function($$resolve, $$reject){\n if(resolve !== undefined || reject !== undefined)throw TypeError('Bad Promise constructor');\n resolve = $$resolve;\n reject = $$reject;\n });\n this.resolve = aFunction(resolve);\n this.reject = aFunction(reject);\n};\nvar perform = function(exec){\n try {\n exec();\n } catch(e){\n return {error: e};\n }\n};\nvar notify = function(promise, isReject){\n if(promise._n)return;\n promise._n = true;\n var chain = promise._c;\n microtask(function(){\n var value = promise._v\n , ok = promise._s == 1\n , i = 0;\n var run = function(reaction){\n var handler = ok ? reaction.ok : reaction.fail\n , resolve = reaction.resolve\n , reject = reaction.reject\n , domain = reaction.domain\n , result, then;\n try {\n if(handler){\n if(!ok){\n if(promise._h == 2)onHandleUnhandled(promise);\n promise._h = 1;\n }\n if(handler === true)result = value;\n else {\n if(domain)domain.enter();\n result = handler(value);\n if(domain)domain.exit();\n }\n if(result === reaction.promise){\n reject(TypeError('Promise-chain cycle'));\n } else if(then = isThenable(result)){\n then.call(result, resolve, reject);\n } else resolve(result);\n } else reject(value);\n } catch(e){\n reject(e);\n }\n };\n while(chain.length > i)run(chain[i++]); // variable length - can't use forEach\n promise._c = [];\n promise._n = false;\n if(isReject && !promise._h)onUnhandled(promise);\n });\n};\nvar onUnhandled = function(promise){\n task.call(global, function(){\n var value = promise._v\n , abrupt, handler, console;\n if(isUnhandled(promise)){\n abrupt = perform(function(){\n if(isNode){\n process.emit('unhandledRejection', value, promise);\n } else if(handler = global.onunhandledrejection){\n handler({promise: promise, reason: value});\n } else if((console = global.console) && console.error){\n console.error('Unhandled promise rejection', value);\n }\n });\n // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should\n promise._h = isNode || isUnhandled(promise) ? 2 : 1;\n } promise._a = undefined;\n if(abrupt)throw abrupt.error;\n });\n};\nvar isUnhandled = function(promise){\n if(promise._h == 1)return false;\n var chain = promise._a || promise._c\n , i = 0\n , reaction;\n while(chain.length > i){\n reaction = chain[i++];\n if(reaction.fail || !isUnhandled(reaction.promise))return false;\n } return true;\n};\nvar onHandleUnhandled = function(promise){\n task.call(global, function(){\n var handler;\n if(isNode){\n process.emit('rejectionHandled', promise);\n } else if(handler = global.onrejectionhandled){\n handler({promise: promise, reason: promise._v});\n }\n });\n};\nvar $reject = function(value){\n var promise = this;\n if(promise._d)return;\n promise._d = true;\n promise = promise._w || promise; // unwrap\n promise._v = value;\n promise._s = 2;\n if(!promise._a)promise._a = promise._c.slice();\n notify(promise, true);\n};\nvar $resolve = function(value){\n var promise = this\n , then;\n if(promise._d)return;\n promise._d = true;\n promise = promise._w || promise; // unwrap\n try {\n if(promise === value)throw TypeError(\"Promise can't be resolved itself\");\n if(then = isThenable(value)){\n microtask(function(){\n var wrapper = {_w: promise, _d: false}; // wrap\n try {\n then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));\n } catch(e){\n $reject.call(wrapper, e);\n }\n });\n } else {\n promise._v = value;\n promise._s = 1;\n notify(promise, false);\n }\n } catch(e){\n $reject.call({_w: promise, _d: false}, e); // wrap\n }\n};\n\n// constructor polyfill\nif(!USE_NATIVE){\n // 25.4.3.1 Promise(executor)\n $Promise = function Promise(executor){\n anInstance(this, $Promise, PROMISE, '_h');\n aFunction(executor);\n Internal.call(this);\n try {\n executor(ctx($resolve, this, 1), ctx($reject, this, 1));\n } catch(err){\n $reject.call(this, err);\n }\n };\n Internal = function Promise(executor){\n this._c = []; // <- awaiting reactions\n this._a = undefined; // <- checked in isUnhandled reactions\n this._s = 0; // <- state\n this._d = false; // <- done\n this._v = undefined; // <- value\n this._h = 0; // <- rejection state, 0 - default, 1 - handled, 2 - unhandled\n this._n = false; // <- notify\n };\n Internal.prototype = require('./_redefine-all')($Promise.prototype, {\n // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected)\n then: function then(onFulfilled, onRejected){\n var reaction = newPromiseCapability(speciesConstructor(this, $Promise));\n reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;\n reaction.fail = typeof onRejected == 'function' && onRejected;\n reaction.domain = isNode ? process.domain : undefined;\n this._c.push(reaction);\n if(this._a)this._a.push(reaction);\n if(this._s)notify(this, false);\n return reaction.promise;\n },\n // 25.4.5.1 Promise.prototype.catch(onRejected)\n 'catch': function(onRejected){\n return this.then(undefined, onRejected);\n }\n });\n PromiseCapability = function(){\n var promise = new Internal;\n this.promise = promise;\n this.resolve = ctx($resolve, promise, 1);\n this.reject = ctx($reject, promise, 1);\n };\n}\n\n$export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: $Promise});\nrequire('./_set-to-string-tag')($Promise, PROMISE);\nrequire('./_set-species')(PROMISE);\nWrapper = require('./_core')[PROMISE];\n\n// statics\n$export($export.S + $export.F * !USE_NATIVE, PROMISE, {\n // 25.4.4.5 Promise.reject(r)\n reject: function reject(r){\n var capability = newPromiseCapability(this)\n , $$reject = capability.reject;\n $$reject(r);\n return capability.promise;\n }\n});\n$export($export.S + $export.F * (LIBRARY || !USE_NATIVE), PROMISE, {\n // 25.4.4.6 Promise.resolve(x)\n resolve: function resolve(x){\n // instanceof instead of internal slot check because we should fix it without replacement native Promise core\n if(x instanceof $Promise && sameConstructor(x.constructor, this))return x;\n var capability = newPromiseCapability(this)\n , $$resolve = capability.resolve;\n $$resolve(x);\n return capability.promise;\n }\n});\n$export($export.S + $export.F * !(USE_NATIVE && require('./_iter-detect')(function(iter){\n $Promise.all(iter)['catch'](empty);\n})), PROMISE, {\n // 25.4.4.1 Promise.all(iterable)\n all: function all(iterable){\n var C = this\n , capability = newPromiseCapability(C)\n , resolve = capability.resolve\n , reject = capability.reject;\n var abrupt = perform(function(){\n var values = []\n , index = 0\n , remaining = 1;\n forOf(iterable, false, function(promise){\n var $index = index++\n , alreadyCalled = false;\n values.push(undefined);\n remaining++;\n C.resolve(promise).then(function(value){\n if(alreadyCalled)return;\n alreadyCalled = true;\n values[$index] = value;\n --remaining || resolve(values);\n }, reject);\n });\n --remaining || resolve(values);\n });\n if(abrupt)reject(abrupt.error);\n return capability.promise;\n },\n // 25.4.4.4 Promise.race(iterable)\n race: function race(iterable){\n var C = this\n , capability = newPromiseCapability(C)\n , reject = capability.reject;\n var abrupt = perform(function(){\n forOf(iterable, false, function(promise){\n C.resolve(promise).then(capability.resolve, reject);\n });\n });\n if(abrupt)reject(abrupt.error);\n return capability.promise;\n }\n});\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/es6.promise.js\n// module id = 79\n// module chunks = 0","'use strict';\nvar $at = require('./_string-at')(true);\n\n// 21.1.3.27 String.prototype[@@iterator]()\nrequire('./_iter-define')(String, 'String', function(iterated){\n this._t = String(iterated); // target\n this._i = 0; // next index\n// 21.1.5.2.1 %StringIteratorPrototype%.next()\n}, function(){\n var O = this._t\n , index = this._i\n , point;\n if(index >= O.length)return {value: undefined, done: true};\n point = $at(O, index);\n this._i += point.length;\n return {value: point, done: false};\n});\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/es6.string.iterator.js\n// module id = 80\n// module chunks = 0","require('./es6.array.iterator');\nvar global = require('./_global')\n , hide = require('./_hide')\n , Iterators = require('./_iterators')\n , TO_STRING_TAG = require('./_wks')('toStringTag');\n\nfor(var collections = ['NodeList', 'DOMTokenList', 'MediaList', 'StyleSheetList', 'CSSRuleList'], i = 0; i < 5; i++){\n var NAME = collections[i]\n , Collection = global[NAME]\n , proto = Collection && Collection.prototype;\n if(proto && !proto[TO_STRING_TAG])hide(proto, TO_STRING_TAG, NAME);\n Iterators[NAME] = Iterators.Array;\n}\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/core-js/library/modules/web.dom.iterable.js\n// module id = 81\n// module chunks = 0","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol ? \"symbol\" : typeof obj; };\n\nvar detectHover = {\n update: function update() {\n if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.matchMedia === 'function') {\n detectHover.hover = window.matchMedia('(hover: hover)').matches;\n detectHover.none = window.matchMedia('(hover: none)').matches || window.matchMedia('(hover: on-demand)').matches;\n detectHover.anyHover = window.matchMedia('(any-hover: hover)').matches;\n detectHover.anyNone = window.matchMedia('(any-hover: none)').matches || window.matchMedia('(any-hover: on-demand)').matches;\n }\n }\n};\n\ndetectHover.update();\nexports.default = detectHover;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/detect-hover/lib/index.js\n// module id = 82\n// module chunks = 0","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; };\n\n// adapted from https://github.com/WICG/EventListenerOptions/blob/gh-pages/explainer.md\nvar detectPassiveEvents = {\n update: function update() {\n if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.addEventListener === 'function' && typeof Object.defineProperty === 'function') {\n var passive = false;\n var options = Object.defineProperty({}, 'passive', {\n get: function get() {\n passive = true;\n }\n });\n window.addEventListener('test', null, options);\n\n detectPassiveEvents.hasSupport = passive;\n }\n }\n};\n\ndetectPassiveEvents.update();\nexports.default = detectPassiveEvents;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/detect-passive-events/lib/index.js\n// module id = 83\n// module chunks = 0","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol ? \"symbol\" : typeof obj; };\n\nvar detectPointer = {\n update: function update() {\n if ((typeof window === 'undefined' ? 'undefined' : _typeof(window)) === 'object' && typeof window.matchMedia === 'function') {\n detectPointer.fine = window.matchMedia('(pointer: fine)').matches;\n detectPointer.coarse = window.matchMedia('(pointer: coarse)').matches;\n detectPointer.none = window.matchMedia('(pointer: none)').matches;\n detectPointer.anyFine = window.matchMedia('(any-pointer: fine)').matches;\n detectPointer.anyCoarse = window.matchMedia('(any-pointer: coarse)').matches;\n detectPointer.anyNone = window.matchMedia('(any-pointer: none)').matches;\n }\n }\n};\n\ndetectPointer.update();\nexports.default = detectPointer;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/detect-pointer/lib/index.js\n// module id = 84\n// module chunks = 0","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nvar detectTouchEvents = {\n update: function update() {\n if (window !== undefined) {\n detectTouchEvents.hasSupport = 'ontouchstart' in window;\n detectTouchEvents.browserSupportsApi = Boolean(window.TouchEvent);\n }\n }\n};\n\ndetectTouchEvents.update();\nexports.default = detectTouchEvents;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/detect-touch-events/lib/index.js\n// module id = 85\n// module chunks = 0","// This method of obtaining a reference to the global object needs to be\n// kept identical to the way it is obtained in runtime.js\nvar g =\n typeof global === \"object\" ? global :\n typeof window === \"object\" ? window :\n typeof self === \"object\" ? self : this;\n\n// Use `getOwnPropertyNames` because not all browsers support calling\n// `hasOwnProperty` on the global `self` object in a worker. See #183.\nvar hadRuntime = g.regeneratorRuntime &&\n Object.getOwnPropertyNames(g).indexOf(\"regeneratorRuntime\") >= 0;\n\n// Save the old regeneratorRuntime in case it needs to be restored later.\nvar oldRuntime = hadRuntime && g.regeneratorRuntime;\n\n// Force reevalutation of runtime.js.\ng.regeneratorRuntime = undefined;\n\nmodule.exports = require(\"./runtime\");\n\nif (hadRuntime) {\n // Restore the original runtime.\n g.regeneratorRuntime = oldRuntime;\n} else {\n // Remove the global property added by runtime.js.\n try {\n delete g.regeneratorRuntime;\n } catch(e) {\n g.regeneratorRuntime = undefined;\n }\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/regenerator-runtime/runtime-module.js\n// module id = 86\n// module chunks = 0","/**\n * Copyright (c) 2014, Facebook, Inc.\n * All rights reserved.\n *\n * This source code is licensed under the BSD-style license found in the\n * https://raw.github.com/facebook/regenerator/master/LICENSE file. An\n * additional grant of patent rights can be found in the PATENTS file in\n * the same directory.\n */\n\n!(function(global) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n var inModule = typeof module === \"object\";\n var runtime = global.regeneratorRuntime;\n if (runtime) {\n if (inModule) {\n // If regeneratorRuntime is defined globally and we're in a module,\n // make the exports object identical to regeneratorRuntime.\n module.exports = runtime;\n }\n // Don't bother evaluating the rest of this file if the runtime was\n // already defined globally.\n return;\n }\n\n // Define the runtime globally (as expected by generated code) as either\n // module.exports (if we're in a module) or a new, empty object.\n runtime = global.regeneratorRuntime = inModule ? module.exports : {};\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n runtime.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunctionPrototype[toStringTagSymbol] =\n GeneratorFunction.displayName = \"GeneratorFunction\";\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n prototype[method] = function(arg) {\n return this._invoke(method, arg);\n };\n });\n }\n\n runtime.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n runtime.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n if (!(toStringTagSymbol in genFun)) {\n genFun[toStringTagSymbol] = \"GeneratorFunction\";\n }\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n runtime.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return Promise.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return Promise.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration. If the Promise is rejected, however, the\n // result for this iteration will be rejected with the same\n // reason. Note that rejections of yielded Promises are not\n // thrown back into the generator function, as is the case\n // when an awaited Promise is rejected. This difference in\n // behavior between yield and await is important, because it\n // allows the consumer to decide what to do with the yielded\n // rejection (swallow it and continue, manually .throw it back\n // into the generator, abandon iteration, whatever). With\n // await, by contrast, there is no opportunity to examine the\n // rejection reason outside the generator function, so the\n // only option is to throw it from the await expression, and\n // let the generator function handle the exception.\n result.value = unwrapped;\n resolve(result);\n }, reject);\n }\n }\n\n if (typeof global.process === \"object\" && global.process.domain) {\n invoke = global.process.domain.bind(invoke);\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new Promise(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n runtime.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n runtime.async = function(innerFn, outerFn, self, tryLocsList) {\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList)\n );\n\n return runtime.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n if (delegate.iterator.return) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n Gp[toStringTagSymbol] = \"Generator\";\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n runtime.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n runtime.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n})(\n // Among the various tricks for obtaining a reference to the global\n // object, this seems to be the most reliable technique that does not\n // use indirect eval (which violates Content Security Policy).\n typeof global === \"object\" ? global :\n typeof window === \"object\" ? window :\n typeof self === \"object\" ? self : this\n);\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/regenerator-runtime/runtime.js\n// module id = 87\n// module chunks = 0"],"sourceRoot":""} \ No newline at end of file diff --git a/dist/firemap.min.js b/dist/firemap.min.js new file mode 100644 index 0000000..e6b350e --- /dev/null +++ b/dist/firemap.min.js @@ -0,0 +1,26 @@ +/*! + * The MIT License + * + * Copyright (c) 2017 te schultz + * https://github.com/artisin/firemap + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + * + */ +!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.firemap=e():t.firemap=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.i=function(t){return t},e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=44)}([function(t,e,n){var r=n(28)("wks"),o=n(31),i=n(1).Symbol,a="function"==typeof i;(t.exports=function(t){return r[t]||(r[t]=a&&i[t]||(a?i:o)("Symbol."+t))}).store=r},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e,n){var r=n(11);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){t.exports=!n(23)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e,n){var r=n(7),o=n(27);t.exports=n(4)?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e){t.exports={}},function(t,e,n){var r=n(2),o=n(53),i=n(74),a=Object.defineProperty;e.f=n(4)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){var r=n(12);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(11),o=n(1).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,e,n){var r=n(1),o=n(3),i=n(9),a=n(5),c=function(t,e,n){var u,s,f,l=t&c.F,d=t&c.G,p=t&c.S,h=t&c.P,v=t&c.B,y=t&c.W,m=d?o:o[e]||(o[e]={}),g=m.prototype,w=d?r:p?r[e]:(r[e]||{}).prototype;d&&(n=e);for(u in n)(s=!l&&w&&void 0!==w[u])&&u in m||(f=s?w[u]:n[u],m[u]=d&&"function"!=typeof w[u]?n[u]:v&&s?i(f,r):y&&w[u]==f?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(f):h&&"function"==typeof f?i(Function.call,f):f,h&&((m.virtual||(m.virtual={}))[u]=f,t&c.R&&g&&!g[u]&&a(g,u,f)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,t.exports=c},function(t,e,n){var r=n(7).f,o=n(10),i=n(0)("toStringTag");t.exports=function(t,e,n){t&&!o(t=n?t:t.prototype,i)&&r(t,i,{configurable:!0,value:e})}},function(t,e,n){var r=n(28)("keys"),o=n(31);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(55),o=n(13);t.exports=function(t){return r(o(t))}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){var r=n(8),o=n(0)("toStringTag"),i="Arguments"==r(function(){return arguments}()),a=function(t,e){try{return t[e]}catch(t){}};t.exports=function(t){var e,n,c;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=a(e=Object(t),o))?n:i?r(e):"Object"==(c=r(e))&&"function"==typeof e.callee?"Arguments":c}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){t.exports=n(1).document&&document.documentElement},function(t,e,n){"use strict";var r=n(26),o=n(15),i=n(68),a=n(5),c=n(10),u=n(6),s=n(58),f=n(16),l=n(64),d=n(0)("iterator"),p=!([].keys&&"next"in[].keys()),h=function(){return this};t.exports=function(t,e,n,v,y,m,g){s(n,e,v);var w,x,b,_=function(t){if(!p&&t in O)return O[t];switch(t){case"keys":case"values":return function(){return new n(this,t)}}return function(){return new n(this,t)}},k=e+" Iterator",P="values"==y,j=!1,O=t.prototype,E=O[d]||O["@@iterator"]||y&&O[y],M=E||_(y),S=y?P?_("entries"):M:void 0,T="Array"==e?O.entries||E:E;if(T&&(b=l(T.call(new t)))!==Object.prototype&&(f(b,k,!0),r||c(b,d)||a(b,d,h)),P&&E&&"values"!==E.name&&(j=!0,M=function(){return E.call(this)}),r&&!g||!p&&!j&&O[d]||a(O,d,M),u[e]=M,u[k]=h,y)if(w={values:P?M:_("values"),keys:m?M:_("keys"),entries:S},g)for(x in w)x in O||i(O,x,w[x]);else o(o.P+o.F*(p||j),e,w);return w}},function(t,e){t.exports=!0},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){var r=n(1),o=r["__core-js_shared__"]||(r["__core-js_shared__"]={});t.exports=function(t){return o[t]||(o[t]={})}},function(t,e,n){var r,o,i,a=n(9),c=n(54),u=n(24),s=n(14),f=n(1),l=f.process,d=f.setImmediate,p=f.clearImmediate,h=f.MessageChannel,v=0,y={},m=function(){var t=+this;if(y.hasOwnProperty(t)){var e=y[t];delete y[t],e()}},g=function(t){m.call(t.data)};d&&p||(d=function(t){for(var e=[],n=1;arguments.length>n;)e.push(arguments[n++]);return y[++v]=function(){c("function"==typeof t?t:Function(t),e)},r(v),v},p=function(t){delete y[t]},"process"==n(8)(l)?r=function(t){l.nextTick(a(m,t,1))}:h?(o=new h,i=o.port2,o.port1.onmessage=g,r=a(i.postMessage,i,1)):f.addEventListener&&"function"==typeof postMessage&&!f.importScripts?(r=function(t){f.postMessage(t+"","*")},f.addEventListener("message",g,!1)):r="onreadystatechange"in s("script")?function(t){u.appendChild(s("script")).onreadystatechange=function(){u.removeChild(this),m.call(t)}}:function(t){setTimeout(a(m,t,1),0)}),t.exports={set:d,clear:p}},function(t,e,n){var r=n(18),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e){var n=function(){var t=null,e=[],n=Date.now(),r={timeRemaining:300},o=function(){return null===t},i=function(e){r.timeRemaining=0,n=Date.now(),t||(t=setTimeout(c,300))},a=function(n){clearTimeout(t),t=null;for(var r=0;r0?t=setTimeout(c,r):a()},u=function(t,e){var n={callback:t,timeoutId:null};return n.timeoutId=null!==e?setTimeout(f.bind(this,n),e):null,n},s=function(t,n){e.push(t)},f=function(t){-1!==e.indexOf(t)&&e.splice(e.indexOf(t),1),t.callback(r),t.timeoutId&&(clearTimeout(t.timeoutId),t.timeoutId=null)};return function(t,e){var n=e&&e.timeout||null,r=u(t,n);o()?f(r):s(r)}};window.requestIdleCallback||(window.ricActivated=!0,window.requestIdleCallback=n()),window.requestUserIdle=window.ricActivated&&window.requestIdleCallback||n()},function(t,e,n){"use strict";n(32);var r=function(t,e,n,r,o,i,a){var c=Math.PI/t;i.fillStyle=a,i.beginPath();for(var u=0;u<2*t;u++){var s=1&u?o:r,f=e+Math.cos(u*c)*s,l=n+Math.sin(u*c)*s;u?i.lineTo(f,l):i.moveTo(f,l)}i.closePath(),i.fill()},o=function(t){var e=t.ctx,n=t.clickPoints,o=this,i=o.clickColor||"rgba(231, 76, 60, 0.75)",a=o.clickSize||20;return new Promise(function(t){window.requestUserIdle(function(){for(var o=null,c=0;c1&&void 0!==arguments[1]?arguments[1]:"x";return t.sort(function(t,n){return t[e]===n[e]?t.x-n.x:t[e]-n[e]}),{min:t[0][e],max:t[t.length-1][e]}},a=function(t){var e=t.ctx,n=t.limit,a=t.interval,c=t.dataPoints,u=t.polygon,s=t.cleanEdges,f=t.mesh,l=t.points,d=t.pointSize,p=this,h=p.size,v=p.hue,y=p.maxValue,m=p.opacity,g=p.threshold,w=p.corners,x=f?1.5*a:1;return new Promise(function(t){window.requestUserIdle(function(){n=n>c.length?c.length:n+1;var f=i(c,"x"),p=i(c,"y"),b=f.min,_=p.min,k=f.max,P=p.max,j=2*a,O=[],E=0,M=0,S=0,T="",L=null;for(e.clearRect(0,0,h.width,h.height),M=b;M1){e.globalCompositeOperation="destination-in",e.fillStyle="#ffffff",e.lineJoin="round",e.beginPath(),e.moveTo(u[0].x,u[0].y);for(var C=1;Cg&&(T=o({val:A.value,hue:v,max:y}),e.globalCompositeOperation="source-over",e.fillStyle="rgba(255, 255, 255, 0.95)",e.beginPath(),e.arc(A.x,A.y,d,0,I,!1),e.fill(),e.lineWidth=d/4,e.strokeStyle="rgba("+T[0]+", "+T[1]+", "+T[2]+", 0.8)",e.beginPath(),e.arc(A.x,A.y,d,0,I,!1),e.stroke(),e.textAlign="center",e.font=d-2+"px monospace",e.textBaseline="middle",e.fillStyle="#474f50",e.fillText(Math.round(A.value),A.x,A.y));t(!0)},{timeout:2e3})})};t.exports=a},function(t,e,n){"use strict";var r=function(t,e,n){return(e.x-t.x)*(n.y-t.y)-(e.y-t.y)*(n.x-t.x)},o=function(t){return new Promise(function(e){for(var n=[],o=[],i=0;i=2&&r(n[n.length-2],n[n.length-1],t[i])<=0;)n.pop();n.push(t[i])}for(var a=t.length-1;a>=0;a-=1){for(;o.length>=2&&r(o[o.length-2],o[o.length-1],t[a])<=0;)o.pop();o.push(t[a])}o.pop(),n.pop(),e(n.concat(o))})};t.exports=o},function(t,e,n){"use strict";e.__esModule=!0;var r=n(46),o=function(t){return t&&t.__esModule?t:{default:t}}(r);e.default=function(t){return function(){var e=t.apply(this,arguments);return new o.default(function(t,n){function r(i,a){try{var c=e[i](a),u=c.value}catch(t){return void n(t)}if(!c.done)return o.default.resolve(u).then(function(t){r("next",t)},function(t){r("throw",t)});t(u)}return r("next")})}}},function(t,e,n){"use strict";e.__esModule=!0,e.default=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){"use strict";e.__esModule=!0;var r=n(45),o=function(t){return t&&t.__esModule?t:{default:t}}(r);e.default=function(){function t(t,e){for(var n=0;n=e||n<0||O&&r>=m}function f(){var t=k();if(s(t))return l(t);w=setTimeout(f,a(t))}function l(t){return w=void 0,E&&v?r(t):(v=y=void 0,g)}function d(){void 0!==w&&clearTimeout(w),P=0,v=x=y=w=void 0}function p(){return void 0===w?g:l(k())}function h(){var t=k(),n=s(t);if(v=arguments,y=this,x=t,n){if(void 0===w)return i(x);if(O)return w=setTimeout(f,e),r(x)}return void 0===w&&(w=setTimeout(f,e)),g}var v,y,m,g,w,x,P=0,j=!1,O=!1,E=!0;if("function"!=typeof t)throw new TypeError(u);return e=c(e)||0,o(n)&&(j=!!n.leading,O="maxWait"in n,m=O?b(c(n.maxWait)||0,e):m,E="trailing"in n?!!n.trailing:E),h.cancel=d,h.flush=p,h}function r(t,e,r){var i=!0,a=!0;if("function"!=typeof t)throw new TypeError(u);return o(r)&&(i="leading"in r?!!r.leading:i,a="trailing"in r?!!r.trailing:a),n(t,e,{leading:i,maxWait:e,trailing:a})}function o(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function i(t){return!!t&&"object"==typeof t}function a(t){return"symbol"==typeof t||i(t)&&x.call(t)==f}function c(t){if("number"==typeof t)return t;if(a(t))return s;if(o(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=o(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(l,"");var n=p.test(t);return n||h.test(t)?v(t.slice(2),n?2:8):d.test(t)?s:+t}var u="Expected a function",s=NaN,f="[object Symbol]",l=/^\s+|\s+$/g,d=/^[-+]0x[0-9a-f]+$/i,p=/^0b[01]+$/i,h=/^0o[0-7]+$/i,v=parseInt,y="object"==typeof e&&e&&e.Object===Object&&e,m="object"==typeof self&&self&&self.Object===Object&&self,g=y||m||Function("return this")(),w=Object.prototype,x=w.toString,b=Math.max,_=Math.min,k=function(){return g.Date.now()};t.exports=r}).call(e,n(20))},function(t,e,n){"use strict";var r=function(t,e,n){var r=void 0,o=void 0,i=void 0;if(0===e)r=o=i=n;else{var a=function(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t},c=n<.5?n*(1+e):n+e-n*e,u=2*n-c;r=a(u,c,t+1/3),o=a(u,c,t),i=a(u,c,t-1/3)}return[Math.round(255*r),Math.round(255*o),Math.round(255*i)]},o=function(t){var e=t.hue,n=t.max,o=t.val,i=n-0;return o=o>n?n:o<0?0:o,r(1-(1-e)-(o-0)*e/i,1,.5)};t.exports=o},function(t,e,n){"use strict";var r=function(t,e,n,r){for(var o=r.x,i=r.y,a=!1,c=0,u=0,s=0,f=0,l=!1,d=e.length-1,p=0;pi!=f>i&&o<(u-c)*(i-s)/(f-s)+c,a=l?!a:a,d=p;if(a){for(var h=[],v=0,y=0,m=0;m0&&void 0!==arguments[0]?arguments[0]:{},n=e.dataPoints,r=void 0===n?[]:n,o=e.clickPoints,i=void 0===o?[]:o,a=e.subscribe,c=e.canvas,u=e.width,f=e.height,l=e.area,d=void 0===l?10:l,p=e.maxValue,h=void 0===p?100:p,m=e.styles,g=void 0===m?{}:m,w=e.hue,x=void 0===w?.5:w,b=e.opacity,_=void 0===b?.8:b,k=e.cleanEdges,P=void 0===k||k,j=e.throttle,O=void 0===j?100:j,E=e.threshold,M=void 0===E?110:E,S=e.corners,T=void 0===S||S,L=e.limit,C=void 0===L?100:L,I=e.interval,A=void 0===I?8:I,R=e.mesh,F=void 0!==R&&R,D=e.points,N=void 0!==D&&D,z=e.pointSize,H=void 0===z?13:z,G=e.clickTrack,W=void 0!==G&&G,X=e.clickSize,B=e.clickColor;(0,s.default)(this,t);var Y=this;if(Y.error=!1,!(c=c||document.getElementsByTagName("canvas")&&document.getElementsByTagName("canvas")[0]))return Y.error=!0,console.error("Fatal Fire Map Error: Canvas element not found, cannot proceed."),!1;Y.dataPoints=r,Y.clickPoints=i,Y.area=d,Y.throttle=O,Y.threshold=M;var U=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Width",e=document;return Math.max(e.body["scroll"+t],e.documentElement["scroll"+t],e.body["offset"+t],e.documentElement["offset"+t],e.body["client"+t],e.documentElement["client"+t])};Y.width=u||U("Width"),Y.height=f||U("Height"),Y._time=!1,Y._temp=[],Y.data=[],Y.data.length=Math.round((Y.width+Y.area)/Y.area)+1;for(var q=Math.round((Y.height+Y.area)/Y.area)+1,$=Y.data.length-1;$>=0;$--)Y.data[$]=[],Y.data[$].length=q;if(Y.clickTrack=W,Y.clickTrack){Y.clickData=[],Y.clickData.length=Math.round((Y.width+Y.area)/Y.area)+1;for(var V=Y.clickData.length-1;V>=0;V--)Y.clickData[V]=[],Y.clickData[V].length=q}Y.drawHeatMap=v.bind(Y),Y.drawClickMap=y.bind(Y),Y.maxValue=h,Y.hue=x,Y.cleanEdges=P,Y.opacity=_,Y.ctx=null,c.width=Y.width,c.height=Y.height,Y.canvas=c,Y.points=[],Y.polygon=[],Y.limits={xMin:0,xMax:0,yMin:0,yMax:0},Y.size={height:c.height,width:c.width},g=Object.assign({position:"absolute",top:"0",left:"0",opacity:_},g),Object.keys(g).forEach(function(t){c.style[t]=g[t]}),Y.corners=T,Y.limit=C,Y.interval=A,Y.mesh=F,Y.points=N,Y.pointSize=H,Y.clickSize=X,Y.clickColor=B,"function"==typeof a&&(Y.subscribe=a.bind(Y)),Y.dataPointCount=!1}return(0,l.default)(t,[{key:"draw",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.dataPoints,n=t.clickPoints,r=t.limit,o=t.interval,a=t.mesh,u=t.points,s=t.pointSize,f=t.threshold,l=t.hue,d=t.opacity,p=t.clickSize,v=t.clickColor,y=t.cb,m=void 0!==y&&y,g=this;e=void 0!==e?e:g.dataPoints,n=void 0!==n?n:g.clickPoints,r=void 0!==r?r:g.limit,o=void 0!==o?o:g.interval,a=void 0!==a?a:g.mesh,u=void 0!==u?u:g.points,s=void 0!==s?s:g.pointSize,g.threshold=void 0!==f?f:g.threshold,g.hue=void 0!==l?l:g.hue,g.opacity=void 0!==d?d:g.opacity,g.clickSize=void 0!==p?p:g.clickSize,g.clickColor=void 0!==v?v:g.clickColor;var w=void 0;(function(){function t(){return f.apply(this,arguments)}var f=(0,c.default)(i.default.mark(function t(){var c,f;return i.default.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(c=!!e&&g.cleanEdges,w=g.canvas.getContext("2d"),!e.length){t.next=6;break}t.t0=e,t.next=9;break;case 6:return t.next=8,g.getData();case 8:t.t0=t.sent;case 9:if(e=t.t0,!e.length){t.next=16;break}return t.next=13,h(e);case 13:return f=t.sent,t.next=16,g.drawHeatMap({ctx:w,limit:r,interval:o,dataPoints:e,polygon:f,cleanEdges:c,mesh:a,points:u,pointSize:s});case 16:if(!0!==n){t.next=22;break}return t.next=19,g.getData(g.clickData||[],!0);case 19:t.t1=t.sent,t.next=23;break;case 22:t.t1=n;case 23:if(n=t.t1,!n.length){t.next=27;break}return t.next=27,g.drawClickMap({ctx:w,clickPoints:n});case 27:return t.abrupt("return",!0);case 28:case"end":return t.stop()}},t,this)}));return t})()().then(function(){console.log("Draw Complete"),m&&m.apply(g,[w])})}},{key:"getData",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=this;return new Promise(function(r){t=t||n.data;for(var o=[],i=null,a=t.length-1;a>=0;a--)for(var c=t[a].length-1;c>=0;c--)(i=t[a][c])&&o.push({x:a*n.area,y:c*n.area,value:e?i:i/10});r(o)})}},{key:"init",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=this;if(!e.error){e.subscribe=t&&"function"==typeof t?t.bind(e):e.subscribe;var n=function(t,n){return e.subscribe&&e.subscribe(t,n)};e._trackAndLogMouse=e._trackAndLogMouse.bind(e),document.addEventListener("mousemove",d(function(t){e._trackAndLogMouse(t),n(t,"mousemove")},e.throttle),!!p.passiveEvents&&{passive:!0}),e.clickTrack&&(e._logClicks=e._logClicks.bind(e),document.addEventListener("pointerdown",d(function(t){e._logClicks(t),n(t,"pointerdown")},75),!!p.passiveEvents&&{passive:!0})),document.addEventListener("pointerdown",function(){e._time=new Date},!!p.passiveEvents&&{passive:!0})}if(e.corners){var r=e.data.length-1,o=e.data[0].length-1;e.data[0][0]=1,e.data[0][o]=1,e.data[r][0]=1,e.data[r][o]=1}}},{key:"_setCoordinates",value:function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=this,o=Math.round(t/r.area),i=Math.round(e/r.area);if(n){if(r._time&&r._temp.length){var a=new Date,c=a-r._time,u=r._temp;if(r.data[u[0]]){var s=r.data[u[0]][u[1]];r.data[u[0]][u[1]]=s?s+c:c}r._time=a,r._temp=[o,i]}else r._time=new Date,r._temp=[o,i];r.dataPointCount&&(r.dataPointCount.count+=1)}else{var f=r.clickData[o][i];r.clickData[o][i]=f?f+1:1}}},{key:"_trackAndLogMouse",value:function(t){var e=this;if(t=t||window.event,null===t.pageX&&null!==t.clientX){var n=t.target&&t.target.ownerDocument||document,r=n.documentElement,o=n.body;t.pageX=t.clientX+(r&&r.scrollLeft||o&&o.scrollLeft||0)-(r&&r.clientLeft||o&&o.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||o&&o.scrollTop||0)-(r&&r.clientTop||o&&o.clientTop||0)}e._setCoordinates(t.pageX,t.pageY)}},{key:"_logClicks",value:function(t){var e=this;if(t=t||window.event,null===t.pageX&&null!==t.clientX){var n=t.target&&t.target.ownerDocument||document,r=n.documentElement,o=n.body;t.pageX=t.clientX+(r&&r.scrollLeft||o&&o.scrollLeft||0)-(r&&r.clientLeft||o&&o.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||o&&o.scrollTop||0)-(r&&r.clientTop||o&&o.clientTop||0)}e._setCoordinates(t.pageX,t.pageY,!1)}},{key:"realTime",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10,e=this,n={count:0},r=new Proxy(n,{set:function(n,r,o){return n[r]=o,o%t==0&&e.draw(),!0}});e.dataPointCount=r}}]),t}();e.default=m},function(t,e,n){t.exports={default:n(47),__esModule:!0}},function(t,e,n){t.exports={default:n(48),__esModule:!0}},function(t,e,n){n(77);var r=n(3).Object;t.exports=function(t,e,n){return r.defineProperty(t,e,n)}},function(t,e,n){n(78),n(80),n(81),n(79),t.exports=n(3).Promise},function(t,e){t.exports=function(){}},function(t,e){t.exports=function(t,e,n,r){if(!(t instanceof e)||void 0!==r&&r in t)throw TypeError(n+": incorrect invocation!");return t}},function(t,e,n){var r=n(19),o=n(30),i=n(72);t.exports=function(t){return function(e,n,a){var c,u=r(e),s=o(u.length),f=i(a,s);if(t&&n!=n){for(;s>f;)if((c=u[f++])!=c)return!0}else for(;s>f;f++)if((t||f in u)&&u[f]===n)return t||f||0;return!t&&-1}}},function(t,e,n){var r=n(9),o=n(57),i=n(56),a=n(2),c=n(30),u=n(75),s={},f={},e=t.exports=function(t,e,n,l,d){var p,h,v,y,m=d?function(){return t}:u(t),g=r(n,l,e?2:1),w=0;if("function"!=typeof m)throw TypeError(t+" is not iterable!");if(i(m)){for(p=c(t.length);p>w;w++)if((y=e?g(a(h=t[w])[0],h[1]):g(t[w]))===s||y===f)return y}else for(v=m.call(t);!(h=v.next()).done;)if((y=o(v,g,h.value,e))===s||y===f)return y};e.BREAK=s,e.RETURN=f},function(t,e,n){t.exports=!n(4)&&!n(23)(function(){return 7!=Object.defineProperty(n(14)("div"),"a",{get:function(){return 7}}).a})},function(t,e){t.exports=function(t,e,n){var r=void 0===n;switch(e.length){case 0:return r?t():t.call(n);case 1:return r?t(e[0]):t.call(n,e[0]);case 2:return r?t(e[0],e[1]):t.call(n,e[0],e[1]);case 3:return r?t(e[0],e[1],e[2]):t.call(n,e[0],e[1],e[2]);case 4:return r?t(e[0],e[1],e[2],e[3]):t.call(n,e[0],e[1],e[2],e[3])}return t.apply(n,e)}},function(t,e,n){var r=n(8);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(6),o=n(0)("iterator"),i=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||i[o]===t)}},function(t,e,n){var r=n(2);t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(e){var i=t.return;throw void 0!==i&&r(i.call(t)),e}}},function(t,e,n){"use strict";var r=n(62),o=n(27),i=n(16),a={};n(5)(a,n(0)("iterator"),function(){return this}),t.exports=function(t,e,n){t.prototype=r(a,{next:o(1,n)}),i(t,e+" Iterator")}},function(t,e,n){var r=n(0)("iterator"),o=!1;try{var i=[7][r]();i.return=function(){o=!0},Array.from(i,function(){throw 2})}catch(t){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var i=[7],a=i[r]();a.next=function(){return{done:n=!0}},i[r]=function(){return a},t(i)}catch(t){}return n}},function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}},function(t,e,n){var r=n(1),o=n(29).set,i=r.MutationObserver||r.WebKitMutationObserver,a=r.process,c=r.Promise,u="process"==n(8)(a);t.exports=function(){var t,e,n,s=function(){var r,o;for(u&&(r=a.domain)&&r.exit();t;){o=t.fn,t=t.next;try{o()}catch(r){throw t?n():e=void 0,r}}e=void 0,r&&r.enter()};if(u)n=function(){a.nextTick(s)};else if(i){var f=!0,l=document.createTextNode("");new i(s).observe(l,{characterData:!0}),n=function(){l.data=f=!f}}else if(c&&c.resolve){var d=c.resolve();n=function(){d.then(s)}}else n=function(){o.call(r,s)};return function(r){var o={fn:r,next:void 0};e&&(e.next=o),t||(t=o,n()),e=o}}},function(t,e,n){var r=n(2),o=n(63),i=n(22),a=n(17)("IE_PROTO"),c=function(){},u=function(){var t,e=n(14)("iframe"),r=i.length;for(e.style.display="none",n(24).appendChild(e),e.src="javascript:",t=e.contentWindow.document,t.open(),t.write("