diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 00000000..943f5e9f --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,8 @@ +# These are supported funding model platforms + +github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] +patreon: # not working due missing www. +open_collective: hyperHTML +ko_fi: # Replace with a single Ko-fi username +tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel +custom: https://www.patreon.com/webreflection diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 00000000..58f187be --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 00000000..73cf8d65 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions + +name: build + +on: [push, pull_request] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [16] + + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm test + - run: npm run coverage --if-present + - name: Coveralls + uses: coverallsapp/github-action@master + with: + github-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.gitignore b/.gitignore index 58b805fe..3cb01d4d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ .DS_Store -node_modules/ \ No newline at end of file +node_modules/ +coverage/ + diff --git a/.npmignore b/.npmignore index f4794d23..2b02e166 100644 --- a/.npmignore +++ b/.npmignore @@ -1,5 +1,14 @@ +coverage/* +esm/.eslintrc +logo/* node_modules/* test/* +_config.yml .DS_Store .gitignore -.travis.yml \ No newline at end of file +.travis.yml +.github/ISSUE_TEMPLATE.md +babel-plugins.json +CHANGELOG.md +package-lock.json +rollup.config.js diff --git a/.travis.yml b/.travis.yml index 85e9c12e..cc127136 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,11 @@ language: node_js node_js: - - 7 + - stable git: depth: 1 branches: only: - master + - /^greenkeeper/.*$/ +after_success: + - "npm run coveralls" diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..60ac2164 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,147 @@ +# hyper(html) Changelog + +### v.2.23 + * monkey patched rollup generated code to export once the same module shared within sub-modules + +### v2.22 + * using latest domtagger + +### v2.21 + * refactored out all dependencies + +### v2.20 + * re-tested every single supported browser nd fixed few outstanding issues with the 2.19 release + +### v2.19 + * refactored out most of the code + * finally managed to have coveralls show coverage stats + * attributes can have spaces around as per DOM standard - [#244](https://github.com/WebReflection/hyperHTML/issues/224) + * fixed SVG (non-critical) errors when interpolations are used for numerically expected values + * fixed minor issues with Edge attributes + * changed the unique id so if any of your logic was trusting `_hyper: ....;` comments you need to update your logic - [#300](https://github.com/WebReflection/hyperHTML/issues/300) + +### v2.16.8 + * improved MutationObserver and fallback so that double `dis/connected` events won't happen again + * exposed `observe` utility for 3rd parts so that it is possible to observe any node, not only those defined via template literals. Once observed, a node can have `connected` and `disconnected` listeners that will be triggered automatically. + +### v2.16 + * modified `Wire` class to better handle "_same target_" case, making the `haunted.html` demo work same way as if it was bound to the node, through `valueOf()` invoke which would result in just exactly the same node if the wired content produced a node instead of a fragment. While regular users won't be affected, this is an implementation detail that changes a lot for libraries integrating `hyperHTML.wire` in their logic, making wires as fast as `bind` in most component related use cases. + +### v2.15 + * added [invokable slots](https://github.com/WebReflection/hyperHTML/pull/282#issuecomment-433614081) to let developers explore patterns through callbacks that will receive a unique live node for weak references while rendered. + +### v2.14 + * updated [domdiff](https://github.com/WebReflection/domdiff#domdiff) to match [petit-dom](https://github.com/yelouafi/petit-dom) performance + * up to 3X performance on huge lists + * improved reliability over random changes + * unfortunately there's a +0.6K overall size increase due amount of extra logic involved + +### v2.13.2 + * added support for custom CSS properties as object keys. + +### v2.13.1 + * worked around [TypeScript transpilation bug with Template Literals](https://twitter.com/WebReflection/status/1038115439539363840). + +### v2.13 + * added the ability to define custom attributes via `hyperHTML.define("hyper-attribute", callback)`, so that `

` would invoke `callback(target, anyValue)` where `p` would be the target. + +### v2.12 + * added `hyper.Component#dispatch(type, detail)` method to simplify events dispatching between lightweight components, bubbling a cancelable Custom Event with a `.component` property that points at the dispatcher, while the `event.currentTarget` will be the first node found within the component render. + +### v2.11 + * updated [domdiff](https://github.com/WebReflection/domdiff#domdiff) to v1.0 + +### v2.10.12 + * patched missing `.children` in SVG node in IE / Edge https://github.com/WebReflection/hyperHTML/issues/244 + +### v2.10.10 + * updated [domdiff](https://github.com/WebReflection/domdiff#domdiff) to solve issue #243 (breaking with some sorted list) + +### v2.10.5 + * various fixes and changes after [changes applied to ECMAScript 2015](https://github.com/tc39/ecma262/pull/890) + +### v2.8.0 + * updated [domdiff](https://github.com/WebReflection/domdiff#domdiff) engine to boost performance with segments and lists + +### v2.7.2 + * fixed #218 which was a variant of #200 + +### v2.7.0 + * the `Component.for(obj)` is now created first time via `new Component(obj)` - #216 + +### v2.6.0 + * declarative hyper.Component via `Component.for(context, uid?)` - #202 + * hyperHTML TypeScript information - #201 + +### v2.5.12 + * fixed #200: textarea/style with initial undefined value + +### v2.5.11 + * fixed #198: connected/disconnected events for nested components + +### v2.5.10 + * more rigid / explicit RegExp to avoid glitches with self-closing tags + +### v2.5.8 + * improved `VOID_ELEMENTS` regular expression (aligned with the _viperHTML_ one) + +### v2.5.7 + * fixed `no.js` patch when wrong count of args is passed + +### v2.5.6 + * added `no.js` file for environments without the ability to use modern JS or based on other languages such Dart. + +### v2.5.5 + * build runs on macOS too + * added umd.js file + +### v2.5.2 + * fixed weird SVG case (see #172) + +### v2.5.1 + * improved self-closing reliability recycling and sharing attributes RegExp + +### v2.5.0 + * updated `domdiff` library to the latest version + * implemented self-closing tags (and after various tests) + +### v2.4.3 + * ensure attributes values are updated when different from previous one + * avoid the usage of the word `global` in the whole code + +### v2.4.2 + * fix scripts with actual content too. + +### v2.4.1 + * fix a bug with scripts that don't trigger network requests in both Firefox and Safari (see bug #152) + +### v2.4.0 + * created a `Wire` class to handle via `domdiff` multiple wired nodes. + * brought back multi nodes per wire, a feature lost since **v2.0** + * simplified `Component` handling too, making it compatible again with multi wired content. + * fixed some check to make IE9+ tests green again + +### v2.3.0 + * dropped the `engine` already. Too complex, no real benefits, refactored the whole internal logic to use [domdiff](https://github.com/WebReflection/domdiff) instead. Deprecated [hyperhtml-majinbuu](https://github.com/WebReflection/hyperhtml-majinbuu) and solved diffing "_forever_". + +### v2.2.0 + * the whole `hyperHTML.engine` has been refactored to use [dom-splicer](https://github.com/WebReflection/dom-splicer) as an effort to make engine development easier + +### v2.1.3 + * the MutationObserver is installed only once and only if there are components that have _on(dis)?connect_ handlers. + +### v2.1.2 + * using a new folders convention with `esm/index.js` as main module and `cjs/index.js` as transformed artifact. This plays very well with bundlers when you `import {hyper} from 'hyperhtml/esm'` or `const {hyper} = require('hyperhtml/cjs');` + +### v2.1.1 + * fast changes where prepending or appending same lists; now dropping upfront or removing at the end are part of the fast path too. + +### v2.1.0 + + * created a simple default merge engine focused on performance + * remove majinbuu as core dependency, created [hyperhtml-majinbuu](https://github.com/WebReflection/hyperhtml-majinbuu) project to swap it back via `hyperHTML.engine = require('hyperhtml-majinbuu')` or as ESM + * reduced final bundle size down to 4.1K via brotli + +## v2.0.0 + +Refactoring following ticket #140 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..fb3f291f --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,67 @@ +# Contribute + +## Introduction + +First, thank you for considering contributing to hyperhtml! It's people like you that make the open source community such a great community! ๐Ÿ˜Š + +We welcome any type of contribution, not only code. You can help with +- **QA**: file bug reports, the more details you can give the better (e.g. screenshots with the console open) +- **Marketing**: writing blog posts, howto's, printing stickers, ... +- **Community**: presenting the project at meetups, organizing a dedicated meetup for the local community, ... +- **Code**: take a look at the [open issues](issues). Even if you can't write code, commenting on them, showing that you care about a given issue matters. It helps us triage them. +- **Money**: we welcome financial contributions in full transparency on our [open collective](https://opencollective.com/hyperhtml). + +## Your First Contribution + +Working on your first Pull Request? You can learn how from this *free* series, [How to Contribute to an Open Source Project on GitHub](https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github). + +## Submitting code + +Any code change should be submitted as a pull request. The description should explain what the code does and give steps to execute it. The pull request should also contain tests. + +## Code review process + +The bigger the pull request, the longer it will take to review and merge. Try to break down large pull requests in smaller chunks that are easier to review and merge. +It is also always helpful to have some context for your pull request. What was the purpose? Why does it matter to you? + +## Financial contributions + +We also welcome financial contributions in full transparency on our [open collective](https://opencollective.com/hyperhtml). +Anyone can file an expense. If the expense makes sense for the development of the community, it will be "merged" in the ledger of our open collective by the core contributors and the person who filed the expense will be reimbursed. + +## Questions + +If you have any questions, create an [issue](issue) (protip: do a quick search first to see if someone else didn't ask the same question before!). +You can also reach us at hello@hyperhtml.opencollective.com. + +## Credits + +### Contributors + +Thank you to all the people who have already contributed to hyperhtml! + + + +### Backers + +Thank you to all our backers! [[Become a backer](https://opencollective.com/hyperhtml#backer)] + + + + +### Sponsors + +Thank you to all our sponsors! (please ask your company to also support this open source project by [becoming a sponsor](https://opencollective.com/hyperhtml#sponsor)) + + + + + + + + + + + + + \ No newline at end of file diff --git a/DEEPDIVE.md b/DEEPDIVE.md deleted file mode 100644 index 214523e5..00000000 --- a/DEEPDIVE.md +++ /dev/null @@ -1,231 +0,0 @@ -# hyperHTML Developer DeepDive - -Being extremely lightweight and simple, there's not much to learn about `hyperHTML`, but there's surely more to discuss about patterns floating around it. - -This document aim is to provide as many details as possible per each operation that's possible via `hyperHTML`. - - -## How can the template be unique - -One thing I have recently discovered about template literals, and I wish I knew it before, is that these are as static as any other string. - -This means that not only ``(`a` === `a`)`` is true, but also ``((a=>a)`a${1}b` === (a=>a)`a${2}b`)``. - -This is the first bit to understand: each template string is unique and if the target node has been using this template before, it won't actually parse it again at all and it will simply use the rest of the arguments passed along to update nested bits already known. - - -#### How are known nodes discovered - -The very first time a new template is used against a node, its full content is injected into such node using a special `` random comment instead of real values. - -Such comment is used to discover both attributes, text nodes, and whole fragments or HTML content, the very first time only. - -```js -// simulation of initial fake injection -function fakeContent(statics, ...values) { - const content = statics.join(''); - this.innerHTML = content; -} - -const render = fakeContent.bind(document.body); - -// inject fakeContent to the target -render`a ${'b'} c`; - -// check its content -console.log( - document.body.childNodes -); -// [text, comment, text] -``` - -As basic example, it would be now possible to drop that `comment` with a text node that will update its content when `values[0]` is passed on, and once all nodes have been mapped 1:1 to the amount of extra arguments passed along to update each sub-value, real data is used and real data will be used from that very moment on to populate nodes and attributes. - -At this point `hyperHTML` uses an [expando property](https://developer.mozilla.org/en-US/docs/Glossary/Expando), for the sake of wider compatibility and to avoid too much [GC pressure](https://mail.mozilla.org/pipermail/es-discuss/2014-December/040565.html) due a potentially heavily populated WeakMap, to save the list of callbacks used to update only what's needed to be updated, being specific text nodes, attributes, or fragments, and together with the static template reference. - -From now on, every time the same template is used, all `hyperHTML` has to do is the following: - -```js -// used when the template is known -function update(statics, ...values) { - // list of callbacks that target directly the node - const updates = this[EXPANDO].updates; - // per each value passed along - values.forEach((value, i) => - // update the related content - updates[i](value)); - // it's a 1:1 DOM relationships -} -``` - - -## How are attributes updated - -Quite often developers thinks about DOM attributes as something you can get or set via `node.setAttribute(name, value)`. -Well, that's half of the story, 'cause [attributes are just nodes](https://dom.spec.whatwg.org/#interface-attr) like anything else in the DOM. - -This means that a generic attribute can be updated simply setting its `.value` property, like an `input` element would update its view when we set its value. It'd be silly to `input.setAttribute('value', content)` when we can just `input.value = content`, right? - -And that's how attributes are updated here. Trapped in a closure, a new template render will simply target the specific attribute and change its value, with the only exception of those attributes prefixed with `on`. - -These are meant to be event handlers. And since nobody likes to deal with handlers as string content, `hyperHTML` recognizes these attributes and it actually remove them from the node, but it will assign to the attribute owner, the node, the DOM Level 0 event. - -```js -// simulation of the attribute update mechanism -if (attribute.name.indexOf('on') === 0) { - node.removeAttribute(attribute.name); - updateAttributeUsing(callback => { - node[attribute.name] = callback; - }); -} else { - updateAttributeUsing(value => { - attribute.value = value; - }); -} -``` - -#### Attributes, the right way - -I'm pretty sure at some point someone will file a bug about having the following situation not working: -```js -function update(render, state) { - // WRONG WAY TO SET ATTRIBUTES - render` -

- ${state.whatever} -
- `; -} -``` - -The performance oriented simplicity of `hyperHTML` simply looks for mutable attributes, it doesn't bother with partially mutable attributes. You can also agree with me above code is [YAGNI](https://en.wikipedia.org/wiki/You_aren't_gonna_need_it) at its best. - -Following **the correct way** to obtain the exact same result: -```js -function update(render, state) { - render` -
- ${state.whatever} -
- `; -} -``` -That's it, really, you have a `class` attribute that will update when changes happen, end of all troubles ^_^ - - -## How are text nodes updated - -Text nodes have a very simple rule: if they are in the wild, they'll be targeted and created. -```js -function update(render) { - render` -
- ${'text node'} -

${'html' || node || array}

- ${'text node'} - - - ${new Date && 'text node'} -
- `; -} -``` - -**Remember:** raw text nodes updates are the fastest, cheapest thing to do. Since also CSS ignores spaces around text, unless of course the node is a special one, don't put content right next to tags. Put a space and it'll be faster and safer! - -```js -function update(render) { - render` - -

${'this will accept HTML'}

- -

- ${'this will update a raw textNode'} -

- `; -} - -// test it! -update(hyperHTML.bind(document.body)); -``` - - -## How are HTML and Document Fragments managed - -This is "_the hard core_" bit. By this time, you should have understood how to hook yourself into HTML and fragments world. - -Literally check the example right before this chapter to remember that you **must not have spaces** or any other char around your fragment, being a table row, a list, or anything else, literally! - -```js -function update(render) { - render`${ - 'even this is a fragment' - }`; -} - -function update(render) { - render` - - - ${ - 'so is this' - }${ - 'and even this!!!' - } -
- `; -} -``` - -Got it? Put a single space around your `${template entry points}` and goodbye HTML or fragments. - -#### Good! - -Now we can return few different kind of things per each fragment: - - * a generic DOM `node`, probably the most common case, it will just be there where you expect it when you need it! - * a `string`, in such case `innerHTML` will kick in like there's no tomorrow - * a `boolean` or a `number`, that will be injected through the cheap `textContent` instead of `innerHTML` - * a `DocumentFragment` which will be compared through its childNodes, and if already there, nothing will happen 'cause fragments are just an indirection to reach real updates, and these also lose nodes once appended - * an `Array` of _strings_, that will be injected through `innerHTML` and a brutal `.join('')` - * an `Array` of _nodes_, that if not already the same on the DOM, will be replaced all at once through a runtime fragment. - -I think I've managed to not forget any case (please [file a bug](issues/) if I did!), -but the annoying bit is when you use a fragment as a target. - - -### Binding A Document Fragment - -Document fragments lose their content as soon as you `appendChild(them)`. -Unless you really know what you are doing, don't bind fragments directly. - -```js -// IT DOESN'T WORK AS EXPECTED -var render = hyperHTML.bind( - document.createDocumentFragment() -); - -// first time will return the fragment -document.body.appendChild( - render`

Hello and Goodbye

` -); - -// but second time it will be empty -render`

Hello and Goodbye

` // empty -``` - -To simplify the boilerplate needed to make fragments work as expected, `hyperHTML` offers a method called **wire**. - -Instead of returning the fragment directly, a `.wire()` connects directly the rendered node to the template. - -```js -var render = hyperHTML.wire(); -render`

Hello Again!

` === -render`

Hello Again!

`; // true - -render`

Hello Again!

`; -//

Hello Again!

-``` diff --git a/HELPERS.md b/HELPERS.md new file mode 100644 index 00000000..d0f8aefb --- /dev/null +++ b/HELPERS.md @@ -0,0 +1,57 @@ +## [babel-plugin-remove-ungap] + +Remove the [@ungap ponyfill modules] from your bundle. This will decrease the size of +your bundle if you are targeting modern browsers only or if your build already includes +other polyfills. This has been tested with [hyperHTML] and [lighterhtml] bundles. + + +## [babel-plugin-template-html-minifier] + +Run [html-minifier] on hyperHTML templates. + + +## [babel-plugin-bare-import-rewrite] + +This can be used as an alternative to [rollup-plugin-node-resolve], or can be used with certain node.js +web servers to allow browsing live from source. + +Known web server integrations: +* [fastify-babel] plugin for [fastify] enables running any babel plugins, generally expects `payload.filename` as set by [fastify-static] +* [express-transform-bare-module-specifiers] for [express] servers + + +## [vinyl-rollup] + +This module copies the output of rollup builds to a stream of vinyl-fs objects for [gulp]. +In addition it optionally adds files from modules that were bundled into the stream. This +makes it easy to ensure that LICENSE and package.json files associated with bundled modules +are published on the web server without publishing node.js server-side dependencies to the web. +This can also be used to copy complete modules if required for licensing or if bundled code +requires additional assets that are not part of the bundled JS (images for example). + + +## [babel-plugin-bundled-import-meta] + +If `node_modules/some-web-component/index.js` uses `import.meta.url` to calculate the actual +path to `node_modules/some-web-components/image.png`, rollup does not compensate. This babel +plugin rewrites references to `import.meta.url` so it points to the original location where +it is expected that the additional assets (images and such) can be found. This plugin works +well with `vinyl-rollup` with `copyModules: true`. + + +[babel-plugin-remove-ungap]: https://github.com/cfware/babel-plugin-remove-ungap#readme +[@ungap ponyfill modules]: https://github.com/ungap/ungap.github.io#readme +[hyperHTML]: https://github.com/WebReflection/hyperHTML#readme +[lighterhtml]: https://github.com/WebReflection/lighterhtml#readme +[babel-plugin-template-html-minifier]: https://github.com/cfware/babel-plugin-template-html-minifier#readme +[html-minifier]: https://github.com/kangax/html-minifier#readme +[babel-plugin-bare-import-rewrite]: https://github.com/cfware/babel-plugin-bare-import-rewrite#readme +[rollup-plugin-node-resolve]: https://github.com/rollup/rollup-plugin-node-resolve#readme +[fastify]: https://github.com/fastify/fastify#readme +[fastify-babel]: https://github.com/cfware/fastify-babel#readme +[fastify-static]: https://github.com/fastify/fastify-static#readme +[express-transform-bare-module-specifiers]: https://github.com/nodecg/express-transform-bare-module-specifiers#readme +[express]: https://github.com/expressjs/express#readme +[vinyl-rollup]: https://github.com/cfware/vinyl-rollup#readme +[gulp]: https://github.com/gulpjs/gulp#readme +[babel-plugin-bundled-import-meta]: https://github.com/cfware/babel-plugin-bundled-import-meta#readme diff --git a/LICENSE.txt b/LICENSE.txt index deddd54d..9b3119f5 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,19 +1,15 @@ -Copyright (C) 2017 by Andrea Giammarchi - @WebReflection +ISC License -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: +Copyright (c) 2017, Andrea Giammarchi, @WebReflection -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. -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. +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE +OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. diff --git a/README.md b/README.md index bc33aa8f..72f7e51a 100644 --- a/README.md +++ b/README.md @@ -1,182 +1,204 @@ -# hyperHTML [![Build Status](https://travis-ci.org/WebReflection/hyperHTML.svg?branch=master)](https://travis-ci.org/WebReflection/hyperHTML) +# hyper(HTML) + +### Maintainance Only + +This module is great, works great, and served me greatly, but there's a pletora of modern, faster, more capable alternatives me, among many other OSS developers, offer so that if obvious bugs are proven to exist, these will be fixed, but there won't be a major release and I won't remove legacy support for stuff that, as previously mentioned, works just fine and it's battle-tested from IE to the latest Chrome. + +Removing that legacy support brings pretty much nothing in terms of size too: this module is already smaller than 90% of alternatives out there, dropping 0.xK so that there's less code that, behind feature detection, is not even used in modern browsers, won't benefit anyone. + +Thansk for your understanding and for not opening PRs which goal is to drop a check for legacy browsers ... these won't likely be merged ever as that'd be a major release update and I don't think anyone is interested in that. + +### ๐Ÿ“ฃ Community Announcement + +Please ask questions in the [dedicated discussions repository](https://github.com/WebReflection/discussions), to help the community around this project grow โ™ฅ -A Fast & Light Virtual DOM Alternative - [release post](https://medium.com/@WebReflection/hyperhtml-a-virtual-dom-alternative-279db455ee0e#.lc65pz9vd), -now [available for both client and server](https://github.com/WebReflection/viperHTML). - - - -The easiest way to describe `hyperHTML` is through [an example](https://webreflection.github.io/hyperHTML/test/tick.html). -```js -// this is React's first tick example -// https://facebook.github.io/react/docs/state-and-lifecycle.html -function tick() { - const element = ( -
-

Hello, world!

-

It is {new Date().toLocaleTimeString()}.

-
- ); - ReactDOM.render( - element, - document.getElementById('root') - ); -} -setInterval(tick, 1000); +hyperHTML logo -// this is hyperHTML -function tick(render) { - render` -
-

Hello, world!

-

It is ${new Date().toLocaleTimeString()}.

-
- `; -} -setInterval(tick, 1000, - hyperHTML.bind(document.getElementById('root')) -); -``` +A **Fast & Light Virtual DOM Alternative**. -## Features +- - - - * Zero dependencies and it fits in **less than 1.5KB** (minzipped) - * Uses directly native DOM instead of inventing new syntax/APIs, DOM diffing, or virtual DOM - * Designed for [template literals](http://www.ecma-international.org/ecma-262/6.0/#sec-template-literals), a templating feature built in to JS - * Compatible with vanilla DOM elements and vanilla JS data structures `*` - * Also compatible with Babel transpiled output, hence suitable for every browser you can think of +[![donate](https://img.shields.io/badge/$-donate-ff69b4.svg?maxAge=2592000&style=flat)](https://github.com/WebReflection/donate) [![Backers on Open Collective](https://opencollective.com/hyperhtml/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/hyperhtml/sponsors/badge.svg)](#sponsors) ![WebReflection status](https://offline.report/status/webreflection.svg) -`*` actually, this is just a 100% vanilla JS utility, that's why is most likely the fastest and also the smallest. I also feel like I'm writing Assembly these days ... anyway ... +[![Coverage Status](https://coveralls.io/repos/github/WebReflection/hyperHTML/badge.svg?branch=master)](https://coveralls.io/github/WebReflection/hyperHTML?branch=master) +[![Build Status](https://travis-ci.org/WebReflection/hyperHTML.svg?branch=master)](https://travis-ci.org/WebReflection/hyperHTML) +[![License: ISC](https://img.shields.io/badge/License-ISC-yellow.svg)](https://opensource.org/licenses/ISC) +[![Greenkeeper badge](https://badges.greenkeeper.io/WebReflection/hyperHTML.svg)](https://greenkeeper.io/) ![Blazing Fast](https://img.shields.io/badge/speed-blazing%20๐Ÿ”ฅ-brightgreen.svg) +- - - -## Usage -You have a `hyperHTML` function that is suitable for parsing template literals but it needs a DOM node context to operate. +Following an overview of projects related, or inspired by, _hyperHTML_. For a deep comparison of current libraries, feel free to [check this gist out](https://gist.github.com/WebReflection/761052d6dae7c8207d2fcba7cdede295). -If you want to render many times the same template for a specific node, bind it once and boost up performance for free. -No new nodes, or innerHTML, will be ever used in such case: safe listeners, faster DOM. +## ยตhtml -### Wait ... there is a wire โžฐ in the code! -The helper `hyperHTML.wire(obj?)` is the solution to a common use case: -using `hyperHTML` to _define not the content_ of a node, _but the node_ itself, or a list of nodes. +The latest, smallest, iteration of all best concept from this library since 2017, have been packaged in _~2.5K_. If it's extreme minimalism and great _DX_ that you are after, check [uhtml](https://github.com/WebReflection/uhtml#readme) out. -In this case binding a `DocumentFragment` would work but it will also lose its content as soon as it's appended. -Using `hyperHTML.wire()` will grant that render will always work as expected, without ever losing knowledge of its initial content. -It wires render updates to whatever content is holding. +## hypersimple + +If you've just started with template literals based projects and you like components, or you'd like to understand what's _hyperHTML_ capable of, give [hypersimple](https://github.com/WebReflection/hypersimple#readme) a try ๐ŸŽ‰ + + +## lighterhtml ๐Ÿ’ก + +This little brother is "_showing off_" these days, claiming better performance and unprecedented ease of use. + +[GitHub Repository](https://github.com/WebReflection/lighterhtml) + + +## Neverland ๐ŸŒˆ๐Ÿฆ„ + +If you like React hooks concept, don't miss this little wrap that adds 0._something_ overhead to the already lightweight hyperHTML, bringing in very similar concepts. + +[Blog Post](https://medium.com/@WebReflection/neverland-the-hyperhtmls-hook-a0c3e11324bb) + +[GitHub Repository](https://github.com/WebReflection/neverland) + +## Haunted ๐Ÿฆ‡ ๐ŸŽƒ + +If you also like React hooks mechanism and you'd like to combine these via hyperHTML or [HyperHTMLElement](https://github.com/WebReflection/hyperHTML-Element), try [haunted](https://github.com/matthewp/haunted#haunted--) out! -```js -// hyperHTML.wire() returns a new wire -const render = hyperHTML.wire(); -// which can be used multiple times -const update = () => render` -
Hello Wired!
-`; - -update() === update(); // true -update(); //
Hello Wired!
- -// it is possible to reference a wire -const point = {x: 1, y: 2}; -// simply passing a generic object -hyperHTML.wire(point)` - O -`; - -// the used render will be always the same -hyperHTML.wire(point) === hyperHTML.wire(point); -// true -``` -It is also possible to define a generic template, and in such case the update won't be the single node, but an Array of nodes. +## Bundlers +You can require or import _hyperHTML_ with any bundler and in different ways. -### FAQs +If requiring or importing from `"hyperhtml"` doesn't work, try requiring from `"hyperhtml/cjs"` for CommonJS friendly bundlers (WebPack), or `"hyperhtml/esm"` for ESM compatible bundlers (Rollup). - * _will input lose focus?_ Nope, as [you can test](https://webreflection.github.io/hyperHTML/test/form.html), only what needs to be updated will be updated. +See [HELPERS.md](./HELPERS.md) for a list of additional tools which can be helpful for building hyperHTML based web applications. - * _are events stringified?_ Nope, even if visually set as `` events are treated differently form other attributes. That `help.click` will be indeed directly assigned as `a.onclick = help.click` so don't worry ๐Ÿ˜‰ +- - - + +## Sponsors + +Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/hyperhtml#sponsor)] + + + +## Backers + +Thank you to all our backers! ๐Ÿ™ [[Become a backer](https://opencollective.com/hyperhtml#backer)] + + + +## Contributors + +This project exists thanks to all the people who contribute. [[Contribute](CONTRIBUTING.md)]. + + +- - - - * _how can I differentiate between textContent only and HTML or DOM nodes?_ - If there's any space or char around the value, that'd be a textContent. - Otherwise it can be strings, used as html, or DOM nodes. - As summary: ```render`

This is: ${'text'}

`;``` for text, and ```render`

${'html' || node || array}

`;``` for other cases. - An array will result into html, if its content has strings, or a document fragment, if it contains nodes. - I've thought a pinch of extra handy magic would've been nice there ๐Ÿ˜‰. +### 2.34 Highlights - * _can I use different renders for a single node?_ - Sure thing. However, the best performance gain is reached with nodes that always use the same template string. - If you have a very unpredictable conditional template, you might want to create two different nodes and apply `hyperHTML` with the same template for both of them, swapping them when necessary. - In every other case, the new template will create new content and map it once per change. + * the new `?boolean=${value}` syntax from [ยตhtml](https://github.com/WebReflection/uhtml#readme) has landed in *hyperHTML* too. Feel free to [read this long discussion](https://github.com/WebReflection/discussions/discussions/13) to better understand *why* this syntax is necessary. - * _is this project just the same as [yo-yo](https://github.com/maxogden/yo-yo) or [bel](https://github.com/shama/bel) ?_ - First of all, I didn't even know those projects were existing when I've written `hyperHTML`, and while the goal is quite similar, the implementation is very different. - For instance, `hyperHTML` performance seems to be superior than [yo-yo-perf](https://github.com/shama/yo-yo-perf). - You can directly test [hyperHTML DBMonster](https://webreflection.github.io/hyperHTML/test/dbmonster.html) benchmark and see it goes _N_ times faster than `yo-yo` version on both Desktop and Mobile browsers ๐ŸŽ‰. +### V2.5 Highlights + * `` tags for both custom elements and any other as well ๐ŸŽ‰ -For all other deeper dirty details, please check the [DeepDive](https://github.com/WebReflection/hyperHTML/blob/master/DEEPDIVE.md) page. +### V2 Highlights +Following most important changes in version 2: -### ... wait, WAT? -[ES6 Template literals](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Template_literals) come with a special feature that is not commonly used: prefixed transformers. + * fully rewritten, and [consumable](https://unpkg.com/hyperhtml@latest/esm/index.js), as [ES2015 Module](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import) + * [usable via CDN](https://unpkg.com/hyperhtml@latest/min.js) as bundled global `hyperHTML` variable + * restructured in modules, utilities, helpers, and commented all over for simplified contribution + * **removed** `.escape` and `.adopt`, either useless or unstable. `hyperHTML.adopt` will be implemented as module a part + * **added** support for objects as `style` attribute, fully compatible with [Preact](https://github.com/developit/preact) implementation + * **improved** performance in numerous ways + * **custom elements** V0 and V1 are now fully, and properly, supported through `document.importNode` and/or regular `cloneNode` tested against common polyfills + * back to 4.6K thanks to **rollup** and its ability to merge all the things together like it was already in V1 -Using such feature to map a template string to a generic DOM node, makes it possible to automatically target and update only the differences between two template invokes and with **no `innerHTML` involved**. +## Documentation -Following [an example](https://webreflection.github.io/hyperHTML/test/article.html): +A proper documentation full of examples can be found in [viperhtml.js.org](https://viperhtml.js.org/). + + +## Basic Example +The easiest way to describe `hyperHTML` is through [an example](https://webreflection.github.io/hyperHTML/test/tick.html). ```js -function update(render, state) { +// this is hyperHTML +function tick(render) { render` -
-

${state.title}

- List of ${state.paragraphs.length} paragraphs: - -
+
+

Hello, world!

+

It is ${new Date().toLocaleTimeString()}.

+
`; } - -update( - hyperHTML.bind(articleElement), - { - title: 'True story', - magic: true, - paragraphs: [ - {title: 'touching'}, - {title: 'incredible'}, - {title: 'doge'} - ] - } +setInterval(tick, 1000, + hyperHTML(document.getElementById('root')) ); ``` -Since most of the time templates are 70% static text and 30% or less dynamic, `hyperHTML` passes through the resulting string only once, finds all attributes and content that is dynamic, and maps it 1:1 to the node to make updates as cheap as possible for both node attributes and node content. +## Features + * Zero dependencies, no polyfills needed, and it fits in about **4.6KB** (minified + brotli) + * Uses directly native DOM, no virtual DOM involved + * Designed for [template literals](http://www.ecma-international.org/ecma-262/6.0/#sec-template-literals), a templating feature built in to JS + * Compatible with plain DOM elements and plain JS data structures + * Also compatible with Babel transpiled output, hence suitable for every browser you can think of -### Caveats +## Compatibility -Following a list of `hyperHTML` caveats (so far just one). +IE9+ , iOS8+ , Android 4+ and every modern Mobile or Desktop Browser. +You can verify directly through the following links: -#### Quotes are mandatory for dynamic attributes -To achieve best performance at setup time, a special `` is used the first time as template values. + * [100% code coverage](https://webreflection.github.io/hyperHTML/test/) for browsers natively compatible with string literals + * [100% code coverage](https://webreflection.github.io/hyperHTML/test/ie/) for IE9+ and browsers that need transpiled code + +#### Weakmap error on ie < 11 -This makes it possible to quickly walk through the DOM tree and setup behaviors, but it's also the value looked for within attributes. +'@ungap/weakmap': object is not extensible -Unfortunately, if you have html such `
class="any">
` the result is broken, while using single or double quotes will grant a successful operation. This is the biggest, and so far only, real caveat. +Babel freezes the template literals by spec but that causes problems with the weakmap polyfill. To fix this error add the fix explained on [ungap/weakmap](https://github.com/ungap/weakmap#transpiled-code-and-frozen-objects-in-legacy-browsers) -In summary, always write `

` instead of `

`, or the layout will break, even if the attribute is a number or a boolean. +## HTML Syntax Highlight -In this way you'll also ensure whatever value you'll pass later on won't ever break the layout. It's a bit annoying, yet a win. +If you are using Visual Studio Code you can install `literally-html` to highlight all literals handled by `hyperHTML` and others. +![literally-html example](https://viperhtml.js.org/hyperhtml/documentation/img/literally-html.png) -## Compatibility -If your string literals are transpiled, this project should be compatible with every single browser, old or new. +## Prettier Templates -If you don't transpile string literals, check the [test page](https://webreflection.github.io/hyperHTML/test/) and wait 'till it's green. +If you'd like to make your templates prettier than usual, don't miss this plugin: https://github.com/sgtpep/prettier-plugin-html-template-literals -- - - -(C) 2017 Andrea Giammarchi - MIT Style License +## Questions ? + +Please ask anything you'd like to know in [StackOverflow](https://stackoverflow.com) using the tag [`hyperhtml`](https://stackoverflow.com/questions/tagged/hyperhtml) so that others can benefit from answers and examples. + +#### hyper or lit ? + +You can read more on this [hyperHTML vs lit-html](https://medium.com/@WebReflection/lit-html-vs-hyperhtml-vs-lighterhtml-c084abfe1285) comparison. + +#### installation? + +```js +npm install hyperhtml +``` +If your bundler does not work with the following: +```js +// ES6 +import hyperHTML from 'hyperhtml'; + +// CJS +const hyperHTML = require('hyperhtml'); +``` +You can try any of these other options. +```js +import hyperHTML from 'hyperhtml/esm'; +// or +import {hyper, wire, bind, Component} from 'hyperhtml/esm'; +// or +import hyperHTML from 'https://unpkg.com/hyperhtml?module'; + + +const hyperHTML = require('hyperhtml/cjs').default; +// or +const {hyper, wire, bind, Component} = require('hyperhtml/cjs'); +``` + +In alternative, there is a pre-bundled `require("hyperhtml/umd")` or via unpkg as [UMD module](https://unpkg.com/hyperhtml@latest/umd.js). diff --git a/babel-plugins.json b/babel-plugins.json new file mode 100644 index 00000000..d982204a --- /dev/null +++ b/babel-plugins.json @@ -0,0 +1,13 @@ +[ + "check-es2015-constants", + "transform-es2015-arrow-functions", + "transform-es2015-block-scoped-functions", + "transform-es2015-block-scoping", + "transform-es2015-computed-properties", + "transform-es2015-destructuring", + "transform-es2015-duplicate-keys", + "transform-es2015-function-name", + "transform-es2015-literals", + "transform-es2015-shorthand-properties", + "transform-es2015-spread" +] \ No newline at end of file diff --git a/cjs/classes/Component.js b/cjs/classes/Component.js new file mode 100644 index 00000000..632986bf --- /dev/null +++ b/cjs/classes/Component.js @@ -0,0 +1,166 @@ +'use strict'; +const CustomEvent = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/custom-event')); +const Map = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/essential-map')); +const WeakMap = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/weakmap')); + +// hyperHTML.Component is a very basic class +// able to create Custom Elements like components +// including the ability to listen to connect/disconnect +// events via onconnect/ondisconnect attributes +// Components can be created imperatively or declaratively. +// The main difference is that declared components +// will not automatically render on setState(...) +// to simplify state handling on render. +function Component() { + return this; // this is needed in Edge !!! +} +Object.defineProperty(exports, '__esModule', {value: true}).default = Component + +// Component is lazily setup because it needs +// wire mechanism as lazy content +function setup(content) { + // there are various weakly referenced variables in here + // and mostly are to use Component.for(...) static method. + const children = new WeakMap; + const create = Object.create; + const createEntry = (wm, id, component) => { + wm.set(id, component); + return component; + }; + const get = (Class, info, context, id) => { + const relation = info.get(Class) || relate(Class, info); + switch (typeof id) { + case 'object': + case 'function': + const wm = relation.w || (relation.w = new WeakMap); + return wm.get(id) || createEntry(wm, id, new Class(context)); + default: + const sm = relation.p || (relation.p = create(null)); + return sm[id] || (sm[id] = new Class(context)); + } + }; + const relate = (Class, info) => { + const relation = {w: null, p: null}; + info.set(Class, relation); + return relation; + }; + const set = context => { + const info = new Map; + children.set(context, info); + return info; + }; + // The Component Class + Object.defineProperties( + Component, + { + // Component.for(context[, id]) is a convenient way + // to automatically relate data/context to children components + // If not created yet, the new Component(context) is weakly stored + // and after that same instance would always be returned. + for: { + configurable: true, + value(context, id) { + return get( + this, + children.get(context) || set(context), + context, + id == null ? + 'default' : id + ); + } + } + } + ); + Object.defineProperties( + Component.prototype, + { + // all events are handled with the component as context + handleEvent: {value(e) { + const ct = e.currentTarget; + this[ + ('getAttribute' in ct && ct.getAttribute('data-call')) || + ('on' + e.type) + ](e); + }}, + // components will lazily define html or svg properties + // as soon as these are invoked within the .render() method + // Such render() method is not provided by the base class + // but it must be available through the Component extend. + // Declared components could implement a + // render(props) method too and use props as needed. + html: lazyGetter('html', content), + svg: lazyGetter('svg', content), + // the state is a very basic/simple mechanism inspired by Preact + state: lazyGetter('state', function () { return this.defaultState; }), + // it is possible to define a default state that'd be always an object otherwise + defaultState: {get() { return {}; }}, + // dispatch a bubbling, cancelable, custom event + // through the first known/available node + dispatch: {value(type, detail) { + const {_wire$} = this; + if (_wire$) { + const event = new CustomEvent(type, { + bubbles: true, + cancelable: true, + detail + }); + event.component = this; + return (_wire$.dispatchEvent ? + _wire$ : + _wire$.firstChild + ).dispatchEvent(event); + } + return false; + }}, + // setting some property state through a new object + // or a callback, triggers also automatically a render + // unless explicitly specified to not do so (render === false) + setState: {value(state, render) { + const target = this.state; + const source = typeof state === 'function' ? state.call(this, target) : state; + for (const key in source) target[key] = source[key]; + if (render !== false) + this.render(); + return this; + }} + } + ); +} +exports.setup = setup + +// instead of a secret key I could've used a WeakMap +// However, attaching a property directly will result +// into better performance with thousands of components +// hanging around, and less memory pressure caused by the WeakMap +const lazyGetter = (type, fn) => { + const secret = '_' + type + '$'; + return { + get() { + return this[secret] || setValue(this, secret, fn.call(this, type)); + }, + set(value) { + setValue(this, secret, value); + } + }; +}; + +// shortcut to set value on get or set(value) +const setValue = (self, secret, value) => + Object.defineProperty(self, secret, { + configurable: true, + value: typeof value === 'function' ? + function () { + return (self._wire$ = value.apply(this, arguments)); + } : + value + })[secret] +; + +Object.defineProperties( + Component.prototype, + { + // used to distinguish better than instanceof + ELEMENT_NODE: {value: 1}, + nodeType: {value: -1} + } +); diff --git a/cjs/hyper/render.js b/cjs/hyper/render.js new file mode 100644 index 00000000..a401a66b --- /dev/null +++ b/cjs/hyper/render.js @@ -0,0 +1,39 @@ +'use strict'; +const WeakMap = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/weakmap')); +const tta = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/template-tag-arguments')); + +const {OWNER_SVG_ELEMENT} = require('../shared/constants.js'); +const {Tagger} = require('../objects/Updates.js'); + +// a weak collection of contexts that +// are already known to hyperHTML +const bewitched = new WeakMap; + +// better known as hyper.bind(node), the render is +// the main tag function in charge of fully upgrading +// or simply updating, contexts used as hyperHTML targets. +// The `this` context is either a regular DOM node or a fragment. +function render() { + const wicked = bewitched.get(this); + const args = tta.apply(null, arguments); + if (wicked && wicked.template === args[0]) { + wicked.tagger.apply(null, args); + } else { + upgrade.apply(this, args); + } + return this; +} + +// an upgrade is in charge of collecting template info, +// parse it once, if unknown, to map all interpolations +// as single DOM callbacks, relate such template +// to the current context, and render it after cleaning the context up +function upgrade(template) { + const type = OWNER_SVG_ELEMENT in this ? 'svg' : 'html'; + const tagger = new Tagger(type); + bewitched.set(this, {tagger, template: template}); + this.textContent = ''; + this.appendChild(tagger.apply(null, arguments)); +} + +Object.defineProperty(exports, '__esModule', {value: true}).default = render; diff --git a/cjs/hyper/wire.js b/cjs/hyper/wire.js new file mode 100644 index 00000000..139eaaba --- /dev/null +++ b/cjs/hyper/wire.js @@ -0,0 +1,84 @@ +'use strict'; +const WeakMap = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/weakmap')); +const tta = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/template-tag-arguments')); + +const Wire = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('hyperhtml-wire')); + +const {Tagger} = require('../objects/Updates.js'); + +// all wires used per each context +const wires = new WeakMap; + +// A wire is a callback used as tag function +// to lazily relate a generic object to a template literal. +// hyper.wire(user)`
${user.name}
`; => the div#user +// This provides the ability to have a unique DOM structure +// related to a unique JS object through a reusable template literal. +// A wire can specify a type, as svg or html, and also an id +// via html:id or :id convention. Such :id allows same JS objects +// to be associated to different DOM structures accordingly with +// the used template literal without losing previously rendered parts. +const wire = (obj, type) => obj == null ? + content(type || 'html') : + weakly(obj, type || 'html'); + +// A wire content is a virtual reference to one or more nodes. +// It's represented by either a DOM node, or an Array. +// In both cases, the wire content role is to simply update +// all nodes through the list of related callbacks. +// In few words, a wire content is like an invisible parent node +// in charge of updating its content like a bound element would do. +const content = type => { + let wire, tagger, template; + return function () { + const args = tta.apply(null, arguments); + if (template !== args[0]) { + template = args[0]; + tagger = new Tagger(type); + wire = wireContent(tagger.apply(tagger, args)); + } else { + tagger.apply(tagger, args); + } + return wire; + }; +}; + +// wires are weakly created through objects. +// Each object can have multiple wires associated +// and this is thanks to the type + :id feature. +const weakly = (obj, type) => { + const i = type.indexOf(':'); + let wire = wires.get(obj); + let id = type; + if (-1 < i) { + id = type.slice(i + 1); + type = type.slice(0, i) || 'html'; + } + if (!wire) + wires.set(obj, wire = {}); + return wire[id] || (wire[id] = content(type)); +}; + +// A document fragment loses its nodes +// as soon as it is appended into another node. +// This has the undesired effect of losing wired content +// on a second render call, because (by then) the fragment would be empty: +// no longer providing access to those sub-nodes that ultimately need to +// stay associated with the original interpolation. +// To prevent hyperHTML from forgetting about a fragment's sub-nodes, +// fragments are instead returned as an Array of nodes or, if there's only one entry, +// as a single referenced node which, unlike fragments, will indeed persist +// wire content throughout multiple renderings. +// The initial fragment, at this point, would be used as unique reference to this +// array of nodes or to this single referenced node. +const wireContent = node => { + const childNodes = node.childNodes; + const {length} = childNodes; + return length === 1 ? + childNodes[0] : + (length ? new Wire(childNodes) : node); +}; + +exports.content = content; +exports.weakly = weakly; +Object.defineProperty(exports, '__esModule', {value: true}).default = wire; diff --git a/cjs/index.js b/cjs/index.js new file mode 100644 index 00000000..04ed734a --- /dev/null +++ b/cjs/index.js @@ -0,0 +1,77 @@ +'use strict'; +/*! (c) Andrea Giammarchi (ISC) */ +const WeakMap = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/weakmap')); +const WeakSet = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/essential-weakset')); + +const diff = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('domdiff')); +const Component = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('./classes/Component.js')); +const {setup} = require('./classes/Component.js'); +const Intent = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('./objects/Intent.js')); +const {observe, Tagger} = require('./objects/Updates.js'); +const wire = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('./hyper/wire.js')); +const {content, weakly} = require('./hyper/wire.js'); +const render = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('./hyper/render.js')); + +// all functions are self bound to the right context +// you can do the following +// const {bind, wire} = hyperHTML; +// and use them right away: bind(node)`hello!`; +const bind = context => render.bind(context); +const define = Intent.define; +const tagger = Tagger.prototype; + +hyper.Component = Component; +hyper.bind = bind; +hyper.define = define; +hyper.diff = diff; +hyper.hyper = hyper; +hyper.observe = observe; +hyper.tagger = tagger; +hyper.wire = wire; + +// exported as shared utils +// for projects based on hyperHTML +// that don't necessarily need upfront polyfills +// i.e. those still targeting IE +hyper._ = { + WeakMap, + WeakSet +}; + +// the wire content is the lazy defined +// html or svg property of each hyper.Component +setup(content); + +// everything is exported directly or through the +// hyperHTML callback, when used as top level script +exports.Component = Component; +exports.bind = bind; +exports.define = define; +exports.diff = diff; +exports.hyper = hyper; +exports.observe = observe; +exports.tagger = tagger; +exports.wire = wire; + +// by default, hyperHTML is a smart function +// that "magically" understands what's the best +// thing to do with passed arguments +function hyper(HTML) { + return arguments.length < 2 ? + (HTML == null ? + content('html') : + (typeof HTML === 'string' ? + hyper.wire(null, HTML) : + ('raw' in HTML ? + content('html')(HTML) : + ('nodeType' in HTML ? + hyper.bind(HTML) : + weakly(HTML, 'html') + ) + ) + )) : + ('raw' in HTML ? + content('html') : hyper.wire + ).apply(null, arguments); +} +Object.defineProperty(exports, '__esModule', {value: true}).default = hyper diff --git a/cjs/objects/Intent.js b/cjs/objects/Intent.js new file mode 100644 index 00000000..ef791d77 --- /dev/null +++ b/cjs/objects/Intent.js @@ -0,0 +1,40 @@ +'use strict'; +const attributes = {}; +const intents = {}; +const keys = []; +const hasOwnProperty = intents.hasOwnProperty; + +let length = 0; + +Object.defineProperty(exports, '__esModule', {value: true}).default = { + + // used to invoke right away hyper:attributes + attributes, + + // hyperHTML.define('intent', (object, update) => {...}) + // can be used to define a third parts update mechanism + // when every other known mechanism failed. + // hyper.define('user', info => info.name); + // hyper(node)`

${{user}}

`; + define: (intent, callback) => { + if (intent.indexOf('-') < 0) { + if (!(intent in intents)) { + length = keys.push(intent); + } + intents[intent] = callback; + } else { + attributes[intent] = callback; + } + }, + + // this method is used internally as last resort + // to retrieve a value out of an object + invoke: (object, callback) => { + for (let i = 0; i < length; i++) { + let key = keys[i]; + if (hasOwnProperty.call(object, key)) { + return intents[key](object[key], callback); + } + } + } +}; diff --git a/cjs/objects/Updates.js b/cjs/objects/Updates.js new file mode 100644 index 00000000..0df2e324 --- /dev/null +++ b/cjs/objects/Updates.js @@ -0,0 +1,377 @@ +'use strict'; +const CustomEvent = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/custom-event')); +const WeakSet = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/essential-weakset')); +const isArray = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/is-array')); +const createContent = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('@ungap/create-content')); + +const disconnected = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('disconnected')); +const domdiff = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('domdiff')); +const domtagger = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('domtagger')); +const hyperStyle = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('hyperhtml-style')); +const Wire = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('hyperhtml-wire')); + +const { + CONNECTED, DISCONNECTED, DOCUMENT_FRAGMENT_NODE, OWNER_SVG_ELEMENT +} = require('../shared/constants.js'); + +const Component = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('../classes/Component.js')); +const Intent = (m => m.__esModule ? /* istanbul ignore next */ m.default : /* istanbul ignore next */ m)(require('./Intent.js')); + +const componentType = Component.prototype.nodeType; +const wireType = Wire.prototype.nodeType; + +const observe = disconnected({Event: CustomEvent, WeakSet}); + +exports.Tagger = Tagger; +exports.observe = observe; + +// returns an intent to explicitly inject content as html +const asHTML = html => ({html}); + +// returns nodes from wires and components +const asNode = (item, i) => { + switch (item.nodeType) { + case wireType: + // in the Wire case, the content can be + // removed, post-pended, inserted, or pre-pended and + // all these cases are handled by domdiff already + /* istanbul ignore next */ + return (1 / i) < 0 ? + (i ? item.remove(true) : item.lastChild) : + (i ? item.valueOf(true) : item.firstChild); + case componentType: + return asNode(item.render(), i); + default: + return item; + } +} + +// returns true if domdiff can handle the value +const canDiff = value => 'ELEMENT_NODE' in value; + +// borrowed from uhandlers +// https://github.com/WebReflection/uhandlers +const booleanSetter = (node, key, oldValue) => newValue => { + if (oldValue !== !!newValue) { + if ((oldValue = !!newValue)) + node.setAttribute(key, ''); + else + node.removeAttribute(key); + } +}; + +const hyperSetter = (node, name, svg) => svg ? + value => { + try { + node[name] = value; + } + catch (nope) { + node.setAttribute(name, value); + } + } : + value => { + node[name] = value; + }; + +// when a Promise is used as interpolation value +// its result must be parsed once resolved. +// This callback is in charge of understanding what to do +// with a returned value once the promise is resolved. +const invokeAtDistance = (value, callback) => { + callback(value.placeholder); + if ('text' in value) { + Promise.resolve(value.text).then(String).then(callback); + } else if ('any' in value) { + Promise.resolve(value.any).then(callback); + } else if ('html' in value) { + Promise.resolve(value.html).then(asHTML).then(callback); + } else { + Promise.resolve(Intent.invoke(value, callback)).then(callback); + } +}; + +// quick and dirty way to check for Promise/ish values +const isPromise_ish = value => value != null && 'then' in value; + +// list of attributes that should not be directly assigned +const readOnly = /^(?:form|list)$/i; + +// reused every slice time +const slice = [].slice; + +// simplifies text node creation +const text = (node, text) => node.ownerDocument.createTextNode(text); + +function Tagger(type) { + this.type = type; + return domtagger(this); +} + +Tagger.prototype = { + + // there are four kind of attributes, and related behavior: + // * events, with a name starting with `on`, to add/remove event listeners + // * special, with a name present in their inherited prototype, accessed directly + // * regular, accessed through get/setAttribute standard DOM methods + // * style, the only regular attribute that also accepts an object as value + // so that you can style=${{width: 120}}. In this case, the behavior has been + // fully inspired by Preact library and its simplicity. + attribute(node, name, original) { + const isSVG = OWNER_SVG_ELEMENT in node; + let oldValue; + // if the attribute is the style one + // handle it differently from others + if (name === 'style') + return hyperStyle(node, original, isSVG); + // direct accessors for and friends + else if (name.slice(0, 1) === '.') + return hyperSetter(node, name.slice(1), isSVG); + // boolean accessors for and friends + else if (name.slice(0, 1) === '?') + return booleanSetter(node, name.slice(1)); + // the name is an event one, + // add/remove event listeners accordingly + else if (/^on/.test(name)) { + let type = name.slice(2); + if (type === CONNECTED || type === DISCONNECTED) { + observe(node); + } + else if (name.toLowerCase() + in node) { + type = type.toLowerCase(); + } + return newValue => { + if (oldValue !== newValue) { + if (oldValue) + node.removeEventListener(type, oldValue, false); + oldValue = newValue; + if (newValue) + node.addEventListener(type, newValue, false); + } + }; + } + // the attribute is special ('value' in input) + // and it's not SVG *or* the name is exactly data, + // in this case assign the value directly + else if ( + name === 'data' || + (!isSVG && name in node && !readOnly.test(name)) + ) { + return newValue => { + if (oldValue !== newValue) { + oldValue = newValue; + if (node[name] !== newValue && newValue == null) { + // cleanup on null to avoid silly IE/Edge bug + node[name] = ''; + node.removeAttribute(name); + } + else + node[name] = newValue; + } + }; + } + else if (name in Intent.attributes) { + oldValue; + return any => { + const newValue = Intent.attributes[name](node, any); + if (oldValue !== newValue) { + oldValue = newValue; + if (newValue == null) + node.removeAttribute(name); + else + node.setAttribute(name, newValue); + } + }; + } + // in every other case, use the attribute node as it is + // update only the value, set it as node only when/if needed + else { + let owner = false; + const attribute = original.cloneNode(true); + return newValue => { + if (oldValue !== newValue) { + oldValue = newValue; + if (attribute.value !== newValue) { + if (newValue == null) { + if (owner) { + owner = false; + node.removeAttributeNode(attribute); + } + attribute.value = newValue; + } else { + attribute.value = newValue; + if (!owner) { + owner = true; + node.setAttributeNode(attribute); + } + } + } + } + }; + } + }, + + // in a hyper(node)`
${content}
` case + // everything could happen: + // * it's a JS primitive, stored as text + // * it's null or undefined, the node should be cleaned + // * it's a component, update the content by rendering it + // * it's a promise, update the content once resolved + // * it's an explicit intent, perform the desired operation + // * it's an Array, resolve all values if Promises and/or + // update the node with the resulting list of content + any(node, childNodes) { + const diffOptions = {node: asNode, before: node}; + const nodeType = OWNER_SVG_ELEMENT in node ? /* istanbul ignore next */ 'svg' : 'html'; + let fastPath = false; + let oldValue; + const anyContent = value => { + switch (typeof value) { + case 'string': + case 'number': + case 'boolean': + if (fastPath) { + if (oldValue !== value) { + oldValue = value; + childNodes[0].textContent = value; + } + } else { + fastPath = true; + oldValue = value; + childNodes = domdiff( + node.parentNode, + childNodes, + [text(node, value)], + diffOptions + ); + } + break; + case 'function': + anyContent(value(node)); + break; + case 'object': + case 'undefined': + if (value == null) { + fastPath = false; + childNodes = domdiff( + node.parentNode, + childNodes, + [], + diffOptions + ); + break; + } + default: + fastPath = false; + oldValue = value; + if (isArray(value)) { + if (value.length === 0) { + if (childNodes.length) { + childNodes = domdiff( + node.parentNode, + childNodes, + [], + diffOptions + ); + } + } else { + switch (typeof value[0]) { + case 'string': + case 'number': + case 'boolean': + anyContent({html: value}); + break; + case 'object': + if (isArray(value[0])) { + value = value.concat.apply([], value); + } + if (isPromise_ish(value[0])) { + Promise.all(value).then(anyContent); + break; + } + default: + childNodes = domdiff( + node.parentNode, + childNodes, + value, + diffOptions + ); + break; + } + } + } else if (canDiff(value)) { + childNodes = domdiff( + node.parentNode, + childNodes, + value.nodeType === DOCUMENT_FRAGMENT_NODE ? + slice.call(value.childNodes) : + [value], + diffOptions + ); + } else if (isPromise_ish(value)) { + value.then(anyContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, anyContent); + } else if ('text' in value) { + anyContent(String(value.text)); + } else if ('any' in value) { + anyContent(value.any); + } else if ('html' in value) { + childNodes = domdiff( + node.parentNode, + childNodes, + slice.call( + createContent( + [].concat(value.html).join(''), + nodeType + ).childNodes + ), + diffOptions + ); + } else if ('length' in value) { + anyContent(slice.call(value)); + } else { + anyContent(Intent.invoke(value, anyContent)); + } + break; + } + }; + return anyContent; + }, + + // style or textareas don't accept HTML as content + // it's pointless to transform or analyze anything + // different from text there but it's worth checking + // for possible defined intents. + text(node) { + let oldValue; + const textContent = value => { + if (oldValue !== value) { + oldValue = value; + const type = typeof value; + if (type === 'object' && value) { + if (isPromise_ish(value)) { + value.then(textContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, textContent); + } else if ('text' in value) { + textContent(String(value.text)); + } else if ('any' in value) { + textContent(value.any); + } else if ('html' in value) { + textContent([].concat(value.html).join('')); + } else if ('length' in value) { + textContent(slice.call(value).join('')); + } else { + textContent(Intent.invoke(value, textContent)); + } + } else if (type === 'function') { + textContent(value(node)); + } else { + node.textContent = value == null ? '' : value; + } + } + }; + return textContent; + } +}; diff --git a/cjs/package.json b/cjs/package.json new file mode 100644 index 00000000..0292b995 --- /dev/null +++ b/cjs/package.json @@ -0,0 +1 @@ +{"type":"commonjs"} \ No newline at end of file diff --git a/cjs/shared/constants.js b/cjs/shared/constants.js new file mode 100644 index 00000000..ebe14667 --- /dev/null +++ b/cjs/shared/constants.js @@ -0,0 +1,18 @@ +'use strict'; +// Node.CONSTANTS +// 'cause some engine has no global Node defined +// (i.e. Node, NativeScript, basicHTML ... ) +const ELEMENT_NODE = 1; +exports.ELEMENT_NODE = ELEMENT_NODE; +const DOCUMENT_FRAGMENT_NODE = 11; +exports.DOCUMENT_FRAGMENT_NODE = DOCUMENT_FRAGMENT_NODE; + +// SVG related constants +const OWNER_SVG_ELEMENT = 'ownerSVGElement'; +exports.OWNER_SVG_ELEMENT = OWNER_SVG_ELEMENT; + +// Custom Elements / MutationObserver constants +const CONNECTED = 'connected'; +exports.CONNECTED = CONNECTED; +const DISCONNECTED = 'dis' + CONNECTED; +exports.DISCONNECTED = DISCONNECTED; diff --git a/cjs/shared/utils.js b/cjs/shared/utils.js new file mode 100644 index 00000000..ad9a93a7 --- /dev/null +++ b/cjs/shared/utils.js @@ -0,0 +1 @@ +'use strict'; diff --git a/esm.js b/esm.js new file mode 100644 index 00000000..1ded632c --- /dev/null +++ b/esm.js @@ -0,0 +1,3 @@ +/*! (c) Andrea Giammarchi (ISC) */var hyperHTML=function(N){"use strict";var t={};try{t.WeakMap=WeakMap}catch(e){t.WeakMap=function(t,e){var n=e.defineProperty,r=e.hasOwnProperty,i=a.prototype;return i.delete=function(e){return this.has(e)&&delete e[this._]},i.get=function(e){return this.has(e)?e[this._]:void 0},i.has=function(e){return r.call(e,this._)},i.set=function(e,t){return n(e,this._,{configurable:!0,value:t}),this},a;function a(e){n(this,"_",{value:"_@ungap/weakmap"+t++}),e&&e.forEach(o,this)}function o(e){this.set(e[0],e[1])}}(Math.random(),Object)}var s=t.WeakMap,i={};try{i.WeakSet=WeakSet}catch(e){!function(e,t){var n=r.prototype;function r(){t(this,"_",{value:"_@ungap/weakmap"+e++})}n.add=function(e){return this.has(e)||t(e,this._,{value:!0,configurable:!0}),this},n.has=function(e){return this.hasOwnProperty.call(e,this._)},n.delete=function(e){return this.has(e)&&delete e[this._]},i.WeakSet=r}(Math.random(),Object.defineProperty)}function m(e,t,n,r,i,a){for(var o=("selectedIndex"in t),u=o;ro;)--c;l=u+r-c;var m=Array(l),y=s[c];for(--n;y;){for(var b=y.newi,w=y.oldi;b>>0;n"+e+"",r.querySelectorAll(t)):(r.innerHTML=e,r.childNodes)),n},function(e,t){return("svg"===t?function(e){var t=H(O),n=H("div");return n.innerHTML=''+e+"",F(t,n.firstChild.childNodes),t}:M)(e)});function F(e,t){for(var n=t.length;n--;)e.appendChild(t[0])}function H(e){return e===O?S.createDocumentFragment():S.createElementNS("http://www.w3.org/1999/xhtml",e)}var I,z,V,Z,G,q,B,J,K,Q,U=(z="appendChild",V="cloneNode",Z="createTextNode",q=(G="importNode")in(I=N),(B=I.createDocumentFragment())[z](I[Z]("g")),B[z](I[Z]("")),(q?I[G](B,!0):B[V](!0)).childNodes.length<2?function e(t,n){for(var r=t[V](),i=t.childNodes||[],a=i.length,o=0;n&&o

',J[K].childNodes[0].getAttribute(Q)==Y)||(Y="_dt: "+Y.slice(1,-1)+";",ee=!0)}catch(e){}var te="\x3c!--"+Y+"--\x3e",ne=8,re=1,ie=3,ae=/^(?:style|textarea)$/i,oe=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i;var ue=" \\f\\n\\r\\t",ce="[^"+ue+"\\/>\"'=]+",le="["+ue+"]+"+ce,se="<([A-Za-z]+[A-Za-z0-9:._-]*)((?:",fe="(?:\\s*=\\s*(?:'[^']*?'|\"[^\"]*?\"|<[^>]*?>|"+ce.replace("\\/","")+"))?)",he=new RegExp(se+le+fe+"+)(["+ue+"]*/?>)","g"),de=new RegExp(se+le+fe+"*)(["+ue+"]*/>)","g"),ve=new RegExp("("+le+"\\s*=\\s*)(['\"]?)"+te+"\\2","gi");function pe(e,t,n,r){return"<"+t+n.replace(ve,ge)+r}function ge(e,t,n){return t+(n||'"')+Y+(n||'"')}function me(e,t,n){return oe.test(t)?e:"<"+t+n+">"}var ye=ee?function(e,t){var n=t.join(" ");return t.slice.call(e,0).sort(function(e,t){return n.indexOf(e.name)<=n.indexOf(t.name)?-1:1})}:function(e,t){return t.slice.call(e,0)};function be(e,t,n,r){for(var i=e.childNodes,a=i.length,o=0;o { + wm.set(id, component); + return component; + }; + const get = (Class, info, context, id) => { + const relation = info.get(Class) || relate(Class, info); + switch (typeof id) { + case 'object': + case 'function': + const wm = relation.w || (relation.w = new WeakMap); + return wm.get(id) || createEntry(wm, id, new Class(context)); + default: + const sm = relation.p || (relation.p = create(null)); + return sm[id] || (sm[id] = new Class(context)); + } + }; + const relate = (Class, info) => { + const relation = {w: null, p: null}; + info.set(Class, relation); + return relation; + }; + const set = context => { + const info = new Map; + children.set(context, info); + return info; + }; + // The Component Class + Object.defineProperties( + Component, + { + // Component.for(context[, id]) is a convenient way + // to automatically relate data/context to children components + // If not created yet, the new Component(context) is weakly stored + // and after that same instance would always be returned. + for: { + configurable: true, + value(context, id) { + return get( + this, + children.get(context) || set(context), + context, + id == null ? + 'default' : id + ); + } + } + } + ); + Object.defineProperties( + Component.prototype, + { + // all events are handled with the component as context + handleEvent: {value(e) { + const ct = e.currentTarget; + this[ + ('getAttribute' in ct && ct.getAttribute('data-call')) || + ('on' + e.type) + ](e); + }}, + // components will lazily define html or svg properties + // as soon as these are invoked within the .render() method + // Such render() method is not provided by the base class + // but it must be available through the Component extend. + // Declared components could implement a + // render(props) method too and use props as needed. + html: lazyGetter('html', content), + svg: lazyGetter('svg', content), + // the state is a very basic/simple mechanism inspired by Preact + state: lazyGetter('state', function () { return this.defaultState; }), + // it is possible to define a default state that'd be always an object otherwise + defaultState: {get() { return {}; }}, + // dispatch a bubbling, cancelable, custom event + // through the first known/available node + dispatch: {value(type, detail) { + const {_wire$} = this; + if (_wire$) { + const event = new CustomEvent(type, { + bubbles: true, + cancelable: true, + detail + }); + event.component = this; + return (_wire$.dispatchEvent ? + _wire$ : + _wire$.firstChild + ).dispatchEvent(event); + } + return false; + }}, + // setting some property state through a new object + // or a callback, triggers also automatically a render + // unless explicitly specified to not do so (render === false) + setState: {value(state, render) { + const target = this.state; + const source = typeof state === 'function' ? state.call(this, target) : state; + for (const key in source) target[key] = source[key]; + if (render !== false) + this.render(); + return this; + }} + } + ); +} + +// instead of a secret key I could've used a WeakMap +// However, attaching a property directly will result +// into better performance with thousands of components +// hanging around, and less memory pressure caused by the WeakMap +const lazyGetter = (type, fn) => { + const secret = '_' + type + '$'; + return { + get() { + return this[secret] || setValue(this, secret, fn.call(this, type)); + }, + set(value) { + setValue(this, secret, value); + } + }; +}; + +// shortcut to set value on get or set(value) +const setValue = (self, secret, value) => + Object.defineProperty(self, secret, { + configurable: true, + value: typeof value === 'function' ? + function () { + return (self._wire$ = value.apply(this, arguments)); + } : + value + })[secret] +; + +Object.defineProperties( + Component.prototype, + { + // used to distinguish better than instanceof + ELEMENT_NODE: {value: 1}, + nodeType: {value: -1} + } +); diff --git a/esm/hyper/render.js b/esm/hyper/render.js new file mode 100644 index 00000000..b3c4c863 --- /dev/null +++ b/esm/hyper/render.js @@ -0,0 +1,38 @@ +import WeakMap from '@ungap/weakmap'; +import tta from '@ungap/template-tag-arguments'; + +import {OWNER_SVG_ELEMENT} from '../shared/constants.js'; +import {Tagger} from '../objects/Updates.js'; + +// a weak collection of contexts that +// are already known to hyperHTML +const bewitched = new WeakMap; + +// better known as hyper.bind(node), the render is +// the main tag function in charge of fully upgrading +// or simply updating, contexts used as hyperHTML targets. +// The `this` context is either a regular DOM node or a fragment. +function render() { + const wicked = bewitched.get(this); + const args = tta.apply(null, arguments); + if (wicked && wicked.template === args[0]) { + wicked.tagger.apply(null, args); + } else { + upgrade.apply(this, args); + } + return this; +} + +// an upgrade is in charge of collecting template info, +// parse it once, if unknown, to map all interpolations +// as single DOM callbacks, relate such template +// to the current context, and render it after cleaning the context up +function upgrade(template) { + const type = OWNER_SVG_ELEMENT in this ? 'svg' : 'html'; + const tagger = new Tagger(type); + bewitched.set(this, {tagger, template: template}); + this.textContent = ''; + this.appendChild(tagger.apply(null, arguments)); +} + +export default render; diff --git a/esm/hyper/wire.js b/esm/hyper/wire.js new file mode 100644 index 00000000..3911fbc7 --- /dev/null +++ b/esm/hyper/wire.js @@ -0,0 +1,82 @@ +import WeakMap from '@ungap/weakmap'; +import tta from '@ungap/template-tag-arguments'; + +import Wire from 'hyperhtml-wire'; + +import {Tagger} from '../objects/Updates.js'; + +// all wires used per each context +const wires = new WeakMap; + +// A wire is a callback used as tag function +// to lazily relate a generic object to a template literal. +// hyper.wire(user)`
${user.name}
`; => the div#user +// This provides the ability to have a unique DOM structure +// related to a unique JS object through a reusable template literal. +// A wire can specify a type, as svg or html, and also an id +// via html:id or :id convention. Such :id allows same JS objects +// to be associated to different DOM structures accordingly with +// the used template literal without losing previously rendered parts. +const wire = (obj, type) => obj == null ? + content(type || 'html') : + weakly(obj, type || 'html'); + +// A wire content is a virtual reference to one or more nodes. +// It's represented by either a DOM node, or an Array. +// In both cases, the wire content role is to simply update +// all nodes through the list of related callbacks. +// In few words, a wire content is like an invisible parent node +// in charge of updating its content like a bound element would do. +const content = type => { + let wire, tagger, template; + return function () { + const args = tta.apply(null, arguments); + if (template !== args[0]) { + template = args[0]; + tagger = new Tagger(type); + wire = wireContent(tagger.apply(tagger, args)); + } else { + tagger.apply(tagger, args); + } + return wire; + }; +}; + +// wires are weakly created through objects. +// Each object can have multiple wires associated +// and this is thanks to the type + :id feature. +const weakly = (obj, type) => { + const i = type.indexOf(':'); + let wire = wires.get(obj); + let id = type; + if (-1 < i) { + id = type.slice(i + 1); + type = type.slice(0, i) || 'html'; + } + if (!wire) + wires.set(obj, wire = {}); + return wire[id] || (wire[id] = content(type)); +}; + +// A document fragment loses its nodes +// as soon as it is appended into another node. +// This has the undesired effect of losing wired content +// on a second render call, because (by then) the fragment would be empty: +// no longer providing access to those sub-nodes that ultimately need to +// stay associated with the original interpolation. +// To prevent hyperHTML from forgetting about a fragment's sub-nodes, +// fragments are instead returned as an Array of nodes or, if there's only one entry, +// as a single referenced node which, unlike fragments, will indeed persist +// wire content throughout multiple renderings. +// The initial fragment, at this point, would be used as unique reference to this +// array of nodes or to this single referenced node. +const wireContent = node => { + const childNodes = node.childNodes; + const {length} = childNodes; + return length === 1 ? + childNodes[0] : + (length ? new Wire(childNodes) : node); +}; + +export { content, weakly }; +export default wire; diff --git a/esm/index.d.ts b/esm/index.d.ts new file mode 100644 index 00000000..02ce463a --- /dev/null +++ b/esm/index.d.ts @@ -0,0 +1,3 @@ +import hyper from ".."; +export * from '..'; +export default hyper; diff --git a/esm/index.js b/esm/index.js new file mode 100644 index 00000000..254708a6 --- /dev/null +++ b/esm/index.js @@ -0,0 +1,66 @@ +/*! (c) Andrea Giammarchi (ISC) */ +import WeakMap from '@ungap/weakmap'; +import WeakSet from '@ungap/essential-weakset'; + +import diff from 'domdiff'; +import Component, {setup} from './classes/Component.js'; +import Intent from './objects/Intent.js'; +import {observe, Tagger} from './objects/Updates.js'; +import wire, {content, weakly} from './hyper/wire.js'; +import render from './hyper/render.js'; + +// all functions are self bound to the right context +// you can do the following +// const {bind, wire} = hyperHTML; +// and use them right away: bind(node)`hello!`; +const bind = context => render.bind(context); +const define = Intent.define; +const tagger = Tagger.prototype; + +hyper.Component = Component; +hyper.bind = bind; +hyper.define = define; +hyper.diff = diff; +hyper.hyper = hyper; +hyper.observe = observe; +hyper.tagger = tagger; +hyper.wire = wire; + +// exported as shared utils +// for projects based on hyperHTML +// that don't necessarily need upfront polyfills +// i.e. those still targeting IE +hyper._ = { + WeakMap, + WeakSet +}; + +// the wire content is the lazy defined +// html or svg property of each hyper.Component +setup(content); + +// everything is exported directly or through the +// hyperHTML callback, when used as top level script +export {Component, bind, define, diff, hyper, observe, tagger, wire}; + +// by default, hyperHTML is a smart function +// that "magically" understands what's the best +// thing to do with passed arguments +export default function hyper(HTML) { + return arguments.length < 2 ? + (HTML == null ? + content('html') : + (typeof HTML === 'string' ? + hyper.wire(null, HTML) : + ('raw' in HTML ? + content('html')(HTML) : + ('nodeType' in HTML ? + hyper.bind(HTML) : + weakly(HTML, 'html') + ) + ) + )) : + ('raw' in HTML ? + content('html') : hyper.wire + ).apply(null, arguments); +} diff --git a/esm/objects/Intent.js b/esm/objects/Intent.js new file mode 100644 index 00000000..a18dab89 --- /dev/null +++ b/esm/objects/Intent.js @@ -0,0 +1,39 @@ +const attributes = {}; +const intents = {}; +const keys = []; +const hasOwnProperty = intents.hasOwnProperty; + +let length = 0; + +export default { + + // used to invoke right away hyper:attributes + attributes, + + // hyperHTML.define('intent', (object, update) => {...}) + // can be used to define a third parts update mechanism + // when every other known mechanism failed. + // hyper.define('user', info => info.name); + // hyper(node)`

${{user}}

`; + define: (intent, callback) => { + if (intent.indexOf('-') < 0) { + if (!(intent in intents)) { + length = keys.push(intent); + } + intents[intent] = callback; + } else { + attributes[intent] = callback; + } + }, + + // this method is used internally as last resort + // to retrieve a value out of an object + invoke: (object, callback) => { + for (let i = 0; i < length; i++) { + let key = keys[i]; + if (hasOwnProperty.call(object, key)) { + return intents[key](object[key], callback); + } + } + } +}; diff --git a/esm/objects/Updates.js b/esm/objects/Updates.js new file mode 100644 index 00000000..103b45ff --- /dev/null +++ b/esm/objects/Updates.js @@ -0,0 +1,377 @@ +import CustomEvent from '@ungap/custom-event'; +import WeakSet from '@ungap/essential-weakset'; +import isArray from '@ungap/is-array'; +import createContent from '@ungap/create-content'; + +import disconnected from 'disconnected'; +import domdiff from 'domdiff'; +import domtagger from 'domtagger'; +import hyperStyle from 'hyperhtml-style'; +import Wire from 'hyperhtml-wire'; + +import { + CONNECTED, DISCONNECTED, + DOCUMENT_FRAGMENT_NODE, + OWNER_SVG_ELEMENT +} from '../shared/constants.js'; + +import Component from '../classes/Component.js'; +import Intent from './Intent.js'; + +const componentType = Component.prototype.nodeType; +const wireType = Wire.prototype.nodeType; + +const observe = disconnected({Event: CustomEvent, WeakSet}); + +export {Tagger, observe}; + +// returns an intent to explicitly inject content as html +const asHTML = html => ({html}); + +// returns nodes from wires and components +const asNode = (item, i) => { + switch (item.nodeType) { + case wireType: + // in the Wire case, the content can be + // removed, post-pended, inserted, or pre-pended and + // all these cases are handled by domdiff already + /* istanbul ignore next */ + return (1 / i) < 0 ? + (i ? item.remove(true) : item.lastChild) : + (i ? item.valueOf(true) : item.firstChild); + case componentType: + return asNode(item.render(), i); + default: + return item; + } +} + +// returns true if domdiff can handle the value +const canDiff = value => 'ELEMENT_NODE' in value; + +// borrowed from uhandlers +// https://github.com/WebReflection/uhandlers +const booleanSetter = (node, key, oldValue) => newValue => { + if (oldValue !== !!newValue) { + if ((oldValue = !!newValue)) + node.setAttribute(key, ''); + else + node.removeAttribute(key); + } +}; + +const hyperSetter = (node, name, svg) => svg ? + value => { + try { + node[name] = value; + } + catch (nope) { + node.setAttribute(name, value); + } + } : + value => { + node[name] = value; + }; + +// when a Promise is used as interpolation value +// its result must be parsed once resolved. +// This callback is in charge of understanding what to do +// with a returned value once the promise is resolved. +const invokeAtDistance = (value, callback) => { + callback(value.placeholder); + if ('text' in value) { + Promise.resolve(value.text).then(String).then(callback); + } else if ('any' in value) { + Promise.resolve(value.any).then(callback); + } else if ('html' in value) { + Promise.resolve(value.html).then(asHTML).then(callback); + } else { + Promise.resolve(Intent.invoke(value, callback)).then(callback); + } +}; + +// quick and dirty way to check for Promise/ish values +const isPromise_ish = value => value != null && 'then' in value; + +// list of attributes that should not be directly assigned +const readOnly = /^(?:form|list)$/i; + +// reused every slice time +const slice = [].slice; + +// simplifies text node creation +const text = (node, text) => node.ownerDocument.createTextNode(text); + +function Tagger(type) { + this.type = type; + return domtagger(this); +} + +Tagger.prototype = { + + // there are four kind of attributes, and related behavior: + // * events, with a name starting with `on`, to add/remove event listeners + // * special, with a name present in their inherited prototype, accessed directly + // * regular, accessed through get/setAttribute standard DOM methods + // * style, the only regular attribute that also accepts an object as value + // so that you can style=${{width: 120}}. In this case, the behavior has been + // fully inspired by Preact library and its simplicity. + attribute(node, name, original) { + const isSVG = OWNER_SVG_ELEMENT in node; + let oldValue; + // if the attribute is the style one + // handle it differently from others + if (name === 'style') + return hyperStyle(node, original, isSVG); + // direct accessors for and friends + else if (name.slice(0, 1) === '.') + return hyperSetter(node, name.slice(1), isSVG); + // boolean accessors for and friends + else if (name.slice(0, 1) === '?') + return booleanSetter(node, name.slice(1)); + // the name is an event one, + // add/remove event listeners accordingly + else if (/^on/.test(name)) { + let type = name.slice(2); + if (type === CONNECTED || type === DISCONNECTED) { + observe(node); + } + else if (name.toLowerCase() + in node) { + type = type.toLowerCase(); + } + return newValue => { + if (oldValue !== newValue) { + if (oldValue) + node.removeEventListener(type, oldValue, false); + oldValue = newValue; + if (newValue) + node.addEventListener(type, newValue, false); + } + }; + } + // the attribute is special ('value' in input) + // and it's not SVG *or* the name is exactly data, + // in this case assign the value directly + else if ( + name === 'data' || + (!isSVG && name in node && !readOnly.test(name)) + ) { + return newValue => { + if (oldValue !== newValue) { + oldValue = newValue; + if (node[name] !== newValue && newValue == null) { + // cleanup on null to avoid silly IE/Edge bug + node[name] = ''; + node.removeAttribute(name); + } + else + node[name] = newValue; + } + }; + } + else if (name in Intent.attributes) { + oldValue; + return any => { + const newValue = Intent.attributes[name](node, any); + if (oldValue !== newValue) { + oldValue = newValue; + if (newValue == null) + node.removeAttribute(name); + else + node.setAttribute(name, newValue); + } + }; + } + // in every other case, use the attribute node as it is + // update only the value, set it as node only when/if needed + else { + let owner = false; + const attribute = original.cloneNode(true); + return newValue => { + if (oldValue !== newValue) { + oldValue = newValue; + if (attribute.value !== newValue) { + if (newValue == null) { + if (owner) { + owner = false; + node.removeAttributeNode(attribute); + } + attribute.value = newValue; + } else { + attribute.value = newValue; + if (!owner) { + owner = true; + node.setAttributeNode(attribute); + } + } + } + } + }; + } + }, + + // in a hyper(node)`
${content}
` case + // everything could happen: + // * it's a JS primitive, stored as text + // * it's null or undefined, the node should be cleaned + // * it's a component, update the content by rendering it + // * it's a promise, update the content once resolved + // * it's an explicit intent, perform the desired operation + // * it's an Array, resolve all values if Promises and/or + // update the node with the resulting list of content + any(node, childNodes) { + const diffOptions = {node: asNode, before: node}; + const nodeType = OWNER_SVG_ELEMENT in node ? /* istanbul ignore next */ 'svg' : 'html'; + let fastPath = false; + let oldValue; + const anyContent = value => { + switch (typeof value) { + case 'string': + case 'number': + case 'boolean': + if (fastPath) { + if (oldValue !== value) { + oldValue = value; + childNodes[0].textContent = value; + } + } else { + fastPath = true; + oldValue = value; + childNodes = domdiff( + node.parentNode, + childNodes, + [text(node, value)], + diffOptions + ); + } + break; + case 'function': + anyContent(value(node)); + break; + case 'object': + case 'undefined': + if (value == null) { + fastPath = false; + childNodes = domdiff( + node.parentNode, + childNodes, + [], + diffOptions + ); + break; + } + default: + fastPath = false; + oldValue = value; + if (isArray(value)) { + if (value.length === 0) { + if (childNodes.length) { + childNodes = domdiff( + node.parentNode, + childNodes, + [], + diffOptions + ); + } + } else { + switch (typeof value[0]) { + case 'string': + case 'number': + case 'boolean': + anyContent({html: value}); + break; + case 'object': + if (isArray(value[0])) { + value = value.concat.apply([], value); + } + if (isPromise_ish(value[0])) { + Promise.all(value).then(anyContent); + break; + } + default: + childNodes = domdiff( + node.parentNode, + childNodes, + value, + diffOptions + ); + break; + } + } + } else if (canDiff(value)) { + childNodes = domdiff( + node.parentNode, + childNodes, + value.nodeType === DOCUMENT_FRAGMENT_NODE ? + slice.call(value.childNodes) : + [value], + diffOptions + ); + } else if (isPromise_ish(value)) { + value.then(anyContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, anyContent); + } else if ('text' in value) { + anyContent(String(value.text)); + } else if ('any' in value) { + anyContent(value.any); + } else if ('html' in value) { + childNodes = domdiff( + node.parentNode, + childNodes, + slice.call( + createContent( + [].concat(value.html).join(''), + nodeType + ).childNodes + ), + diffOptions + ); + } else if ('length' in value) { + anyContent(slice.call(value)); + } else { + anyContent(Intent.invoke(value, anyContent)); + } + break; + } + }; + return anyContent; + }, + + // style or textareas don't accept HTML as content + // it's pointless to transform or analyze anything + // different from text there but it's worth checking + // for possible defined intents. + text(node) { + let oldValue; + const textContent = value => { + if (oldValue !== value) { + oldValue = value; + const type = typeof value; + if (type === 'object' && value) { + if (isPromise_ish(value)) { + value.then(textContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, textContent); + } else if ('text' in value) { + textContent(String(value.text)); + } else if ('any' in value) { + textContent(value.any); + } else if ('html' in value) { + textContent([].concat(value.html).join('')); + } else if ('length' in value) { + textContent(slice.call(value).join('')); + } else { + textContent(Intent.invoke(value, textContent)); + } + } else if (type === 'function') { + textContent(value(node)); + } else { + node.textContent = value == null ? '' : value; + } + } + }; + return textContent; + } +}; diff --git a/esm/shared/constants.js b/esm/shared/constants.js new file mode 100644 index 00000000..667b8e9d --- /dev/null +++ b/esm/shared/constants.js @@ -0,0 +1,12 @@ +// Node.CONSTANTS +// 'cause some engine has no global Node defined +// (i.e. Node, NativeScript, basicHTML ... ) +export const ELEMENT_NODE = 1; +export const DOCUMENT_FRAGMENT_NODE = 11; + +// SVG related constants +export const OWNER_SVG_ELEMENT = 'ownerSVGElement'; + +// Custom Elements / MutationObserver constants +export const CONNECTED = 'connected'; +export const DISCONNECTED = 'dis' + CONNECTED; diff --git a/hyperhtml.js b/hyperhtml.js deleted file mode 100644 index 49d95fcb..00000000 --- a/hyperhtml.js +++ /dev/null @@ -1,495 +0,0 @@ -var hyperHTML = (function () {'use strict'; - - /*! (C) 2017 Andrea Giammarchi @WebReflection (MIT) */ - - // hyperHTML \o/ - // - // var render = hyperHTML.bind(document.body); - // setInterval(() => render` - //

โšก๏ธ hyperHTML โšก๏ธ

- //

- // ${(new Date).toLocaleString()} - //

- // `, 1000); - function hyperHTML(statics) { - return EXPANDO in this && - this[EXPANDO].s === statics ? - update.apply(this, arguments) : - upgrade.apply(this, arguments); - } - - // A wire โžฐ is a bridge between a document fragment - // and its inevitably lost list of rendered nodes - // - // var render = hyperHTML.wire(); - // render` - //
Hello Wired!
- // `; - // - // Every single invocation will return that div - // or the list of elements it contained as Array. - // This simplifies most task where hyperHTML - // is used to create the node itself, instead of - // populating an already known and bound one. - hyperHTML.wire = function wire(obj) { - return arguments.length < 1 ? - wireContent() : - wireWeakly(obj); - }; - - // - - - - - - - - - - - - - - - - - - - - - - - - - // ------------------------- - // DOM parsing & traversing - // ------------------------- - - // setup attributes for updates - // - //

- // - // Note: always use quotes around attributes, even for events, - // booleans, or numbers, otherwise this function fails. - function attributesSeeker(node, actions) { - for (var - attribute, - attributes = slice.call(node.attributes), - i = 0, - length = attributes.length; - i < length; i++ - ) { - attribute = attributes[i]; - if (attribute.value === uidc) { - actions.push(setAttribute(node, attribute)); - } - } - } - - // traverse the whole node in search of editable content - // decide what each future update should change - // - //
- //

${some.HTML}

- //

- // ${some.text} - //

- //
- function lukeTreeWalker(node, actions) { - for (var - child, text, - childNodes = slice.call(node.childNodes), - length = childNodes.length, - i = 0; i < length; i++ - ) { - child = childNodes[i]; - switch (child.nodeType) { - case 1: - attributesSeeker(child, actions); - lukeTreeWalker(child, actions); - break; - case 8: - if (child.textContent === uid) { - if (length === 1) { - actions.push(setAnyContent(node)); - node.removeChild(child); - } else if ( - (i < 1 || childNodes[i - 1].nodeType === 1) && - (i + 1 === length || childNodes[i + 1].nodeType === 1) - ) { - actions.push(setVirtualContent(child)); - } else { - text = node.ownerDocument.createTextNode(''); - actions.push(setTextContent(text)); - node.replaceChild(text, child); - } - } - break; - } - } - } - - - // ------------------------- - // DOM manipulating - // ------------------------- - - // update regular bound nodes - // - // var render = hyperHTML.bind(node); - // function update() { - // render`template`; - // } - function setAnyContent(node) { - return function any(value) { - switch (typeof value) { - case 'string': - node.innerHTML = value; - break; - case 'number': - case 'boolean': - node.textContent = value; - break; - default: - if (Array.isArray(value)) { - if (value.length === 1) { - any(value[0]); - } else if(typeof value[0] === 'string') { - any(value.join('')); - } else { - var i = indexOfDiffereces(node.childNodes, value); - if (-1 < i) { - updateViaArray(node, value, i); - } - } - } else { - populateNode(node, value); - } - break; - } - }; - } - - // update attributes node - // - // render`${name}`; - // - // Note: attributes with `on` prefix are set directly as callbacks. - // These won't ever be transformed into strings while other - // attributes will be automatically sanitized. - function setAttribute(node, attribute) { - var - name = attribute.name, - isSpecial = SPECIAL_ATTRIBUTE.test(name) - ; - if (isSpecial) node.removeAttribute(name); - return isSpecial ? - function event(value) { - node[name] = value; - } : - function attr(value) { - attribute.value = value; - }; - } - - // update the "emptiness" - // this function is used when template literals - // have sneaky html/fragment capable - // updates in the wild (no spaces around) - // - // render` - //

Content before

${ - // 'any content in between' - // }

Content after

- // `; - // - // Note: this is the most expensive - // update of them all. - function setVirtualContent(node) { - var - fragment = document.createDocumentFragment(), - childNodes = [] - ; - return function any(value) { - var i, parentNode = node.parentNode; - switch (typeof value) { - case 'string': - case 'number': - case 'boolean': - removeNodeList(childNodes, 0); - injectHTML(fragment, value); - childNodes = slice.call(fragment.childNodes); - parentNode.insertBefore(fragment, node); - break; - default: - if (Array.isArray(value)) { - if (value.length === 0) { - any(value[0]); - } else if(typeof value[0] === 'string') { - any(value.join('')); - } else { - i = indexOfDiffereces(childNodes, value); - if (-1 < i) { - removeNodeList(childNodes, i); - value = value.slice(i); - appendNodes(fragment, value); - parentNode.insertBefore(fragment, node); - childNodes.push.apply(childNodes, value); - } - } - } else { - removeNodeList(childNodes, 0); - childNodes = value.nodeType === 11 ? - slice.call(value.childNodes) : - [value]; - parentNode.insertBefore(value, node); - } - break; - } - }; - } - - // basic closure to update nodes textContent - // - // render` - //

- // ${'spaces around means textContent'} - //

`; - function setTextContent(node) { - return function text(value) { - node.textContent = value; - }; - } - - - // ------------------------- - // Helpers - // ------------------------- - - // it does exactly what it says - function appendNodes(node, childNodes) { - for (var - i = 0, - length = childNodes.length; - i < length; i++ - ) { - node.appendChild(childNodes[i]); - } - } - - // given two collections, find - // the first index that has different content. - // If the two lists are the same, return -1 - // to indicate no differences were found. - function indexOfDiffereces(a, b) { - if (a === b) return -1; - var - i = 0, - aLength = a.length, - bLength = b.length - ; - while (i < aLength) { - if (i < bLength && a[i] === b[i]) i++; - else return i; - } - return i === bLength ? -1 : i; - } - - // inject HTML into a template node - // and populate a fragment with resulting nodes - // - // Note: for partial layout such `` or `` - // you need an HTML5 compatible browser - // (or an HTML5 Template specification that works) - function injectHTML(fragment, html) { - var template = fragment.ownerDocument.createElement('template'); - template.innerHTML = html; - appendNodes( - fragment, - slice.call((template.content || template).childNodes) - ); - } - - // accordingly with the kind of child - // it put its content into a parent node - function populateNode(parent, child) { - switch (child.nodeType) { - case 1: - var childNodes = parent.childNodes; - if (childNodes.length !== 1 || childNodes[0] !== child) { - resetAndPopulate(parent, child); - } - break; - case 11: - if (-1 < indexOfDiffereces(parent.childNodes, child.childNodes)) { - resetAndPopulate(parent, child); - } - break; - case 3: - parent.textContent = child.textContent; - break; - } - } - - // it does exactly what it says - function removeNodeList(list, startIndex) { - var length = list.length, child; - while (startIndex < length--) { - child = list[length]; - child.parentNode.removeChild(child); - } - } - - // drop all nodes and append a node - function resetAndPopulate(parent, child) { - parent.textContent = ''; - parent.appendChild(child); - } - - // the first time a hyperHTML.wire() is invoked - // remember the list of nodes that should be updated - // at every consequent render call. - // The resulting function might return the very first node - // or the Array of all nodes that might need updates. - function setupAndGetContent(node) { - for (var - child, - children = [], - childNodes = node.childNodes, - i = 0, - length = childNodes.length; - i < length; i++ - ) { - child = childNodes[i]; - if ( - 1 === child.nodeType || - 0 < trim.call(child.textContent).length - ) { - children.push(child); - } - } - length = children.length; - return length < 2 ? - ((child = length < 1 ? node : children[0]), - function () { return child; }) : - function () { return children; }; - } - - // remove and/or and a list of nodes through an array - function updateViaArray(node, childNodes, i) { - var fragment = node.ownerDocument.createDocumentFragment(); - if (0 < i) { - removeNodeList(node.childNodes, i); - appendNodes(fragment, childNodes.slice(i)); - node.appendChild(fragment); - } else { - appendNodes(fragment, childNodes); - resetAndPopulate(node, fragment); - } - } - - // remove and/or and a list of nodes through a fragment - /* temporarily removed until it's demonstrated it's needed - function updateViaFragment(node, fragment, i) { - if (0 < i) { - removeNodeList(node.childNodes, i); - var slim = fragment.cloneNode(); - appendNodes(slim, slice.call(fragment.childNodes, i)); - node.appendChild(fragment, slim); - } else { - resetAndPopulate(node, fragment); - } - } - //*/ - - // create a new wire for generic DOM content - function wireContent() { - var content, fragment, render, setup, template; - return function update(statics) { - if (template !== statics) { - setup = true; - template = statics; - fragment = document.createDocumentFragment(); - render = hyperHTML.bind(fragment); - } - render.apply(null, arguments); - if (setup) { - setup = false; - content = setupAndGetContent(fragment); - } - return content(); - }; - } - - // get or create a wired weak reference - function wireWeakly(obj) { - return wm.get(obj) || ( - wm.set(obj, wireContent()), - wireWeakly(obj) - ); - } - - // ------------------------- - // Template setup - // ------------------------- - - // each known hyperHTML update is - // kept as simple as possible. - function update(statics) { - for (var - i = 1, - length = arguments.length, - updates = this[EXPANDO].u; - i < length; i++ - ) { - updates[i - 1](arguments[i]); - } - return this; - } - - // but the first time, it needs to be setup. - // From now on, only update(statics) will be called - // unless this node won't be used for other renderings. - function upgrade(statics) { - var - updates = [], - html = statics.join(uidc) - ; - if (this.nodeType === 1) { - this.innerHTML = html; - } else { - injectHTML(this, html); - } - lukeTreeWalker(this, updates); - this[EXPANDO] = {s: statics, u: updates}; - return update.apply(this, arguments); - } - - - // ------------------------- - // local variables - // ------------------------- - - var - // decide special attributes behavior - SPECIAL_ATTRIBUTE = /^(?:on[a-z]+|async|autofocus|autoplay|capture|checked|controls|deferred|disabled|formnovalidate|loop|multiple|muted|required)$/, - // avoids WeakMap to avoid memory pressure - EXPANDO = '_hyperHTML', - // use a pseudo unique id to avoid conflicts - uid = EXPANDO + ((Math.random() * new Date) | 0), - // use comment nodes with pseudo unique content to setup - uidc = '', - // verify empty textContent on .wire() setup - trim = EXPANDO.trim || function () { - return this.replace(/^\s+|\s+$/g, ''); - }, - // convert DOM.childNodes into arrays to avoid - // DOM mutation backfiring on loops - slice = [].slice, - // used for weak references - // if WeakMap is not available - // it uses a configurable, non enumerable, - // quick and dirty expando property. - wm = typeof WeakMap === typeof wm ? - { - get: function (obj) { return obj[EXPANDO]; }, - set: function (obj, value) { - Object.defineProperty(obj, EXPANDO, { - configurable: true, - value: value - }); - } - } : - new WeakMap(); - ; - - // Simply to avoid duplicated RegExp in viperHTML - hyperHTML.SPECIAL_ATTRIBUTE = SPECIAL_ATTRIBUTE; - - // ------------------------- - // โšก๏ธ ๏ธ๏ธThe End โžฐ - // ------------------------- - return hyperHTML; - -}()); - -// umd.KISS -try { module.exports = hyperHTML; } catch(o_O) {} diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 00000000..8fe28e62 --- /dev/null +++ b/index.d.ts @@ -0,0 +1,51 @@ +type TemplateFunction = (template: TemplateStringsArray, ...values: any[]) => T; +export type BoundTemplateFunction = TemplateFunction; +export type WiredTemplateFunction = TemplateFunction; + +export declare class Component { + static for(this: new() => TComponent, context: object, identity?: any): TComponent; + handleEvent(e: Event): void; + html: WiredTemplateFunction; + svg: WiredTemplateFunction; + state: T; + get defaultState(): T; + setState(state: Partial | ((this: this, state: T) => Partial), render?: boolean): this; + dispatch(type: string, detail?: any): boolean; +} + +export declare function bind(element: T): BoundTemplateFunction; + +export declare function define(intent: string, callback: Function): void; + +export declare function wire(identity?: object | null, type?: 'html' | 'svg'): WiredTemplateFunction; +export declare function wire(identity?: object | null, type_id?: string): WiredTemplateFunction; + +export declare const hyper: { + Component: typeof Component; + bind: typeof bind; + define: typeof define; + hyper: typeof hyper; + wire: typeof wire; + + // hyper(null, 'html')`HTML` + (identity: null | undefined, type?: 'html' | 'svg'): WiredTemplateFunction; + + // hyper('html')`HTML` + (type: 'html' | 'svg'): WiredTemplateFunction; + + // hyper(element)`HTML` + (element: T): BoundTemplateFunction; + + // hyper`HTML` + (template: TemplateStringsArray, ...values: any[]): any; + + // hyper(obj, 'html:id')`HTML` + // hyper(obj)`HTML` + (identity: object, type?: 'html' | 'svg'): WiredTemplateFunction; + (identity: object, type_id?: string): WiredTemplateFunction; + + // hyper()`HTML` + (): WiredTemplateFunction; +}; + +export default hyper; diff --git a/index.js b/index.js new file mode 100644 index 00000000..f9649b1c --- /dev/null +++ b/index.js @@ -0,0 +1,2020 @@ +var hyperHTML = (function (document) { + 'use strict'; + + /*! (c) Andrea Giammarchi - ISC */ + var self = {}; + + try { + self.WeakMap = WeakMap; + } catch (WeakMap) { + // this could be better but 90% of the time + // it's everything developers need as fallback + self.WeakMap = function (id, Object) { + + var dP = Object.defineProperty; + var hOP = Object.hasOwnProperty; + var proto = WeakMap.prototype; + + proto["delete"] = function (key) { + return this.has(key) && delete key[this._]; + }; + + proto.get = function (key) { + return this.has(key) ? key[this._] : void 0; + }; + + proto.has = function (key) { + return hOP.call(key, this._); + }; + + proto.set = function (key, value) { + dP(key, this._, { + configurable: true, + value: value + }); + return this; + }; + + return WeakMap; + + function WeakMap(iterable) { + dP(this, '_', { + value: '_@ungap/weakmap' + id++ + }); + if (iterable) iterable.forEach(add, this); + } + + function add(pair) { + this.set(pair[0], pair[1]); + } + }(Math.random(), Object); + } + + var WeakMap$1 = self.WeakMap; + + /*! (c) Andrea Giammarchi - ISC */ + var self$1 = {}; + + try { + self$1.WeakSet = WeakSet; + } catch (WeakSet) { + (function (id, dP) { + var proto = WeakSet.prototype; + + proto.add = function (object) { + if (!this.has(object)) dP(object, this._, { + value: true, + configurable: true + }); + return this; + }; + + proto.has = function (object) { + return this.hasOwnProperty.call(object, this._); + }; + + proto["delete"] = function (object) { + return this.has(object) && delete object[this._]; + }; + + self$1.WeakSet = WeakSet; + + function WeakSet() { + + dP(this, '_', { + value: '_@ungap/weakmap' + id++ + }); + } + })(Math.random(), Object.defineProperty); + } + + var WeakSet$1 = self$1.WeakSet; + + var _ref = [], + indexOf = _ref.indexOf; + + var append = function append(get, parent, children, start, end, before) { + var isSelect = ('selectedIndex' in parent); + var noSelection = isSelect; + + while (start < end) { + var child = get(children[start], 1); + parent.insertBefore(child, before); + + if (isSelect && noSelection && child.selected) { + noSelection = !noSelection; + var selectedIndex = parent.selectedIndex; + parent.selectedIndex = selectedIndex < 0 ? start : indexOf.call(parent.querySelectorAll('option'), child); + } + + start++; + } + }; + var eqeq = function eqeq(a, b) { + return a == b; + }; + var identity = function identity(O) { + return O; + }; + var indexOf$1 = function indexOf(moreNodes, moreStart, moreEnd, lessNodes, lessStart, lessEnd, compare) { + var length = lessEnd - lessStart; + /* istanbul ignore if */ + + if (length < 1) return -1; + + while (moreEnd - moreStart >= length) { + var m = moreStart; + var l = lessStart; + + while (m < moreEnd && l < lessEnd && compare(moreNodes[m], lessNodes[l])) { + m++; + l++; + } + + if (l === lessEnd) return moreStart; + moreStart = m + 1; + } + + return -1; + }; + var isReversed = function isReversed(futureNodes, futureEnd, currentNodes, currentStart, currentEnd, compare) { + while (currentStart < currentEnd && compare(currentNodes[currentStart], futureNodes[futureEnd - 1])) { + currentStart++; + futureEnd--; + } + return futureEnd === 0; + }; + var next = function next(get, list, i, length, before) { + return i < length ? get(list[i], 0) : 0 < i ? get(list[i - 1], -0).nextSibling : before; + }; + var remove = function remove(get, children, start, end) { + while (start < end) { + drop(get(children[start++], -1)); + } + }; // - - - - - - - - - - - - - - - - - - - + // diff related constants and utilities + // - - - - - - - - - - - - - - - - - - - + + var DELETION = -1; + var INSERTION = 1; + var SKIP = 0; + var SKIP_OND = 50; + + var HS = function HS(futureNodes, futureStart, futureEnd, futureChanges, currentNodes, currentStart, currentEnd, currentChanges) { + var k = 0; + /* istanbul ignore next */ + + var minLen = futureChanges < currentChanges ? futureChanges : currentChanges; + var link = Array(minLen++); + var tresh = Array(minLen); + tresh[0] = -1; + + for (var i = 1; i < minLen; i++) { + tresh[i] = currentEnd; + } + + var nodes = currentNodes.slice(currentStart, currentEnd); + + for (var _i = futureStart; _i < futureEnd; _i++) { + var index = nodes.indexOf(futureNodes[_i]); + + if (-1 < index) { + var idxInOld = index + currentStart; + k = findK(tresh, minLen, idxInOld); + /* istanbul ignore else */ + + if (-1 < k) { + tresh[k] = idxInOld; + link[k] = { + newi: _i, + oldi: idxInOld, + prev: link[k - 1] + }; + } + } + } + + k = --minLen; + --currentEnd; + + while (tresh[k] > currentEnd) { + --k; + } + + minLen = currentChanges + futureChanges - k; + var diff = Array(minLen); + var ptr = link[k]; + --futureEnd; + + while (ptr) { + var _ptr = ptr, + newi = _ptr.newi, + oldi = _ptr.oldi; + + while (futureEnd > newi) { + diff[--minLen] = INSERTION; + --futureEnd; + } + + while (currentEnd > oldi) { + diff[--minLen] = DELETION; + --currentEnd; + } + + diff[--minLen] = SKIP; + --futureEnd; + --currentEnd; + ptr = ptr.prev; + } + + while (futureEnd >= futureStart) { + diff[--minLen] = INSERTION; + --futureEnd; + } + + while (currentEnd >= currentStart) { + diff[--minLen] = DELETION; + --currentEnd; + } + + return diff; + }; // this is pretty much the same petit-dom code without the delete map part + // https://github.com/yelouafi/petit-dom/blob/bd6f5c919b5ae5297be01612c524c40be45f14a7/src/vdom.js#L556-L561 + + + var OND = function OND(futureNodes, futureStart, rows, currentNodes, currentStart, cols, compare) { + var length = rows + cols; + var v = []; + var d, k, r, c, pv, cv, pd; + + outer: for (d = 0; d <= length; d++) { + /* istanbul ignore if */ + if (d > SKIP_OND) return null; + pd = d - 1; + /* istanbul ignore next */ + + pv = d ? v[d - 1] : [0, 0]; + cv = v[d] = []; + + for (k = -d; k <= d; k += 2) { + if (k === -d || k !== d && pv[pd + k - 1] < pv[pd + k + 1]) { + c = pv[pd + k + 1]; + } else { + c = pv[pd + k - 1] + 1; + } + + r = c - k; + + while (c < cols && r < rows && compare(currentNodes[currentStart + c], futureNodes[futureStart + r])) { + c++; + r++; + } + + if (c === cols && r === rows) { + break outer; + } + + cv[d + k] = c; + } + } + + var diff = Array(d / 2 + length / 2); + var diffIdx = diff.length - 1; + + for (d = v.length - 1; d >= 0; d--) { + while (c > 0 && r > 0 && compare(currentNodes[currentStart + c - 1], futureNodes[futureStart + r - 1])) { + // diagonal edge = equality + diff[diffIdx--] = SKIP; + c--; + r--; + } + + if (!d) break; + pd = d - 1; + /* istanbul ignore next */ + + pv = d ? v[d - 1] : [0, 0]; + k = c - r; + + if (k === -d || k !== d && pv[pd + k - 1] < pv[pd + k + 1]) { + // vertical edge = insertion + r--; + diff[diffIdx--] = INSERTION; + } else { + // horizontal edge = deletion + c--; + diff[diffIdx--] = DELETION; + } + } + + return diff; + }; + + var applyDiff = function applyDiff(diff, get, parentNode, futureNodes, futureStart, currentNodes, currentStart, currentLength, before) { + var live = []; + var length = diff.length; + var currentIndex = currentStart; + var i = 0; + + while (i < length) { + switch (diff[i++]) { + case SKIP: + futureStart++; + currentIndex++; + break; + + case INSERTION: + // TODO: bulk appends for sequential nodes + live.push(futureNodes[futureStart]); + append(get, parentNode, futureNodes, futureStart++, futureStart, currentIndex < currentLength ? get(currentNodes[currentIndex], 0) : before); + break; + + case DELETION: + currentIndex++; + break; + } + } + + i = 0; + + while (i < length) { + switch (diff[i++]) { + case SKIP: + currentStart++; + break; + + case DELETION: + // TODO: bulk removes for sequential nodes + if (-1 < live.indexOf(currentNodes[currentStart])) currentStart++;else remove(get, currentNodes, currentStart++, currentStart); + break; + } + } + }; + + var findK = function findK(ktr, length, j) { + var lo = 1; + var hi = length; + + while (lo < hi) { + var mid = (lo + hi) / 2 >>> 0; + if (j < ktr[mid]) hi = mid;else lo = mid + 1; + } + + return lo; + }; + + var smartDiff = function smartDiff(get, parentNode, futureNodes, futureStart, futureEnd, futureChanges, currentNodes, currentStart, currentEnd, currentChanges, currentLength, compare, before) { + applyDiff(OND(futureNodes, futureStart, futureChanges, currentNodes, currentStart, currentChanges, compare) || HS(futureNodes, futureStart, futureEnd, futureChanges, currentNodes, currentStart, currentEnd, currentChanges), get, parentNode, futureNodes, futureStart, currentNodes, currentStart, currentLength, before); + }; + + var drop = function drop(node) { + return (node.remove || dropChild).call(node); + }; + + function dropChild() { + var parentNode = this.parentNode; + /* istanbul ignore else */ + + if (parentNode) parentNode.removeChild(this); + } + + /*! (c) 2018 Andrea Giammarchi (ISC) */ + + var domdiff = function domdiff(parentNode, // where changes happen + currentNodes, // Array of current items/nodes + futureNodes, // Array of future items/nodes + options // optional object with one of the following properties + // before: domNode + // compare(generic, generic) => true if same generic + // node(generic) => Node + ) { + if (!options) options = {}; + var compare = options.compare || eqeq; + var get = options.node || identity; + var before = options.before == null ? null : get(options.before, 0); + var currentLength = currentNodes.length; + var currentEnd = currentLength; + var currentStart = 0; + var futureEnd = futureNodes.length; + var futureStart = 0; // common prefix + + while (currentStart < currentEnd && futureStart < futureEnd && compare(currentNodes[currentStart], futureNodes[futureStart])) { + currentStart++; + futureStart++; + } // common suffix + + + while (currentStart < currentEnd && futureStart < futureEnd && compare(currentNodes[currentEnd - 1], futureNodes[futureEnd - 1])) { + currentEnd--; + futureEnd--; + } + + var currentSame = currentStart === currentEnd; + var futureSame = futureStart === futureEnd; // same list + + if (currentSame && futureSame) return futureNodes; // only stuff to add + + if (currentSame && futureStart < futureEnd) { + append(get, parentNode, futureNodes, futureStart, futureEnd, next(get, currentNodes, currentStart, currentLength, before)); + return futureNodes; + } // only stuff to remove + + + if (futureSame && currentStart < currentEnd) { + remove(get, currentNodes, currentStart, currentEnd); + return futureNodes; + } + + var currentChanges = currentEnd - currentStart; + var futureChanges = futureEnd - futureStart; + var i = -1; // 2 simple indels: the shortest sequence is a subsequence of the longest + + if (currentChanges < futureChanges) { + i = indexOf$1(futureNodes, futureStart, futureEnd, currentNodes, currentStart, currentEnd, compare); // inner diff + + if (-1 < i) { + append(get, parentNode, futureNodes, futureStart, i, get(currentNodes[currentStart], 0)); + append(get, parentNode, futureNodes, i + currentChanges, futureEnd, next(get, currentNodes, currentEnd, currentLength, before)); + return futureNodes; + } + } + /* istanbul ignore else */ + else if (futureChanges < currentChanges) { + i = indexOf$1(currentNodes, currentStart, currentEnd, futureNodes, futureStart, futureEnd, compare); // outer diff + + if (-1 < i) { + remove(get, currentNodes, currentStart, i); + remove(get, currentNodes, i + futureChanges, currentEnd); + return futureNodes; + } + } // common case with one replacement for many nodes + // or many nodes replaced for a single one + + /* istanbul ignore else */ + + + if (currentChanges < 2 || futureChanges < 2) { + append(get, parentNode, futureNodes, futureStart, futureEnd, get(currentNodes[currentStart], 0)); + remove(get, currentNodes, currentStart, currentEnd); + return futureNodes; + } // the half match diff part has been skipped in petit-dom + // https://github.com/yelouafi/petit-dom/blob/bd6f5c919b5ae5297be01612c524c40be45f14a7/src/vdom.js#L391-L397 + // accordingly, I think it's safe to skip in here too + // if one day it'll come out like the speediest thing ever to do + // then I might add it in here too + // Extra: before going too fancy, what about reversed lists ? + // This should bail out pretty quickly if that's not the case. + + + if (currentChanges === futureChanges && isReversed(futureNodes, futureEnd, currentNodes, currentStart, currentEnd, compare)) { + append(get, parentNode, futureNodes, futureStart, futureEnd, next(get, currentNodes, currentEnd, currentLength, before)); + return futureNodes; + } // last resort through a smart diff + + + smartDiff(get, parentNode, futureNodes, futureStart, futureEnd, futureChanges, currentNodes, currentStart, currentEnd, currentChanges, currentLength, compare, before); + return futureNodes; + }; + + + + /*! (c) Andrea Giammarchi - ISC */ + var self$2 = {}; + self$2.CustomEvent = typeof CustomEvent === 'function' ? CustomEvent : function (__p__) { + CustomEvent[__p__] = new CustomEvent('').constructor[__p__]; + return CustomEvent; + + function CustomEvent(type, init) { + if (!init) init = {}; + var e = document.createEvent('CustomEvent'); + e.initCustomEvent(type, !!init.bubbles, !!init.cancelable, init.detail); + return e; + } + }('prototype'); + var CustomEvent$1 = self$2.CustomEvent; + + /*! (c) Andrea Giammarchi - ISC */ + var self$3 = {}; + + try { + self$3.Map = Map; + } catch (Map) { + self$3.Map = function Map() { + var i = 0; + var k = []; + var v = []; + return { + "delete": function _delete(key) { + var had = contains(key); + + if (had) { + k.splice(i, 1); + v.splice(i, 1); + } + + return had; + }, + forEach: function forEach(callback, context) { + k.forEach(function (key, i) { + callback.call(context, v[i], key, this); + }, this); + }, + get: function get(key) { + return contains(key) ? v[i] : void 0; + }, + has: function has(key) { + return contains(key); + }, + set: function set(key, value) { + v[contains(key) ? i : k.push(key) - 1] = value; + return this; + } + }; + + function contains(v) { + i = k.indexOf(v); + return -1 < i; + } + }; + } + + var Map$1 = self$3.Map; + + // able to create Custom Elements like components + // including the ability to listen to connect/disconnect + // events via onconnect/ondisconnect attributes + // Components can be created imperatively or declaratively. + // The main difference is that declared components + // will not automatically render on setState(...) + // to simplify state handling on render. + + function Component() { + return this; // this is needed in Edge !!! + } // Component is lazily setup because it needs + // wire mechanism as lazy content + + function setup(content) { + // there are various weakly referenced variables in here + // and mostly are to use Component.for(...) static method. + var children = new WeakMap$1(); + var create = Object.create; + + var createEntry = function createEntry(wm, id, component) { + wm.set(id, component); + return component; + }; + + var get = function get(Class, info, context, id) { + var relation = info.get(Class) || relate(Class, info); + + switch (typeof(id)) { + case 'object': + case 'function': + var wm = relation.w || (relation.w = new WeakMap$1()); + return wm.get(id) || createEntry(wm, id, new Class(context)); + + default: + var sm = relation.p || (relation.p = create(null)); + return sm[id] || (sm[id] = new Class(context)); + } + }; + + var relate = function relate(Class, info) { + var relation = { + w: null, + p: null + }; + info.set(Class, relation); + return relation; + }; + + var set = function set(context) { + var info = new Map$1(); + children.set(context, info); + return info; + }; // The Component Class + + + Object.defineProperties(Component, { + // Component.for(context[, id]) is a convenient way + // to automatically relate data/context to children components + // If not created yet, the new Component(context) is weakly stored + // and after that same instance would always be returned. + "for": { + configurable: true, + value: function value(context, id) { + return get(this, children.get(context) || set(context), context, id == null ? 'default' : id); + } + } + }); + Object.defineProperties(Component.prototype, { + // all events are handled with the component as context + handleEvent: { + value: function value(e) { + var ct = e.currentTarget; + this['getAttribute' in ct && ct.getAttribute('data-call') || 'on' + e.type](e); + } + }, + // components will lazily define html or svg properties + // as soon as these are invoked within the .render() method + // Such render() method is not provided by the base class + // but it must be available through the Component extend. + // Declared components could implement a + // render(props) method too and use props as needed. + html: lazyGetter('html', content), + svg: lazyGetter('svg', content), + // the state is a very basic/simple mechanism inspired by Preact + state: lazyGetter('state', function () { + return this.defaultState; + }), + // it is possible to define a default state that'd be always an object otherwise + defaultState: { + get: function get() { + return {}; + } + }, + // dispatch a bubbling, cancelable, custom event + // through the first known/available node + dispatch: { + value: function value(type, detail) { + var _wire$ = this._wire$; + + if (_wire$) { + var event = new CustomEvent$1(type, { + bubbles: true, + cancelable: true, + detail: detail + }); + event.component = this; + return (_wire$.dispatchEvent ? _wire$ : _wire$.firstChild).dispatchEvent(event); + } + + return false; + } + }, + // setting some property state through a new object + // or a callback, triggers also automatically a render + // unless explicitly specified to not do so (render === false) + setState: { + value: function value(state, render) { + var target = this.state; + var source = typeof state === 'function' ? state.call(this, target) : state; + + for (var key in source) { + target[key] = source[key]; + } + + if (render !== false) this.render(); + return this; + } + } + }); + } // instead of a secret key I could've used a WeakMap + // However, attaching a property directly will result + // into better performance with thousands of components + // hanging around, and less memory pressure caused by the WeakMap + + var lazyGetter = function lazyGetter(type, fn) { + var secret = '_' + type + '$'; + return { + get: function get() { + return this[secret] || setValue(this, secret, fn.call(this, type)); + }, + set: function set(value) { + setValue(this, secret, value); + } + }; + }; // shortcut to set value on get or set(value) + + + var setValue = function setValue(self, secret, value) { + return Object.defineProperty(self, secret, { + configurable: true, + value: typeof value === 'function' ? function () { + return self._wire$ = value.apply(this, arguments); + } : value + })[secret]; + }; + + Object.defineProperties(Component.prototype, { + // used to distinguish better than instanceof + ELEMENT_NODE: { + value: 1 + }, + nodeType: { + value: -1 + } + }); + + var attributes = {}; + var intents = {}; + var keys = []; + var hasOwnProperty = intents.hasOwnProperty; + var length = 0; + var Intent = { + // used to invoke right away hyper:attributes + attributes: attributes, + // hyperHTML.define('intent', (object, update) => {...}) + // can be used to define a third parts update mechanism + // when every other known mechanism failed. + // hyper.define('user', info => info.name); + // hyper(node)`

${{user}}

`; + define: function define(intent, callback) { + if (intent.indexOf('-') < 0) { + if (!(intent in intents)) { + length = keys.push(intent); + } + + intents[intent] = callback; + } else { + attributes[intent] = callback; + } + }, + // this method is used internally as last resort + // to retrieve a value out of an object + invoke: function invoke(object, callback) { + for (var i = 0; i < length; i++) { + var key = keys[i]; + + if (hasOwnProperty.call(object, key)) { + return intents[key](object[key], callback); + } + } + } + }; + + var isArray = Array.isArray || + /* istanbul ignore next */ + function (toString) { + /* istanbul ignore next */ + var $ = toString.call([]); + /* istanbul ignore next */ + + return function isArray(object) { + return toString.call(object) === $; + }; + }({}.toString); + + /*! (c) Andrea Giammarchi - ISC */ + var createContent = function (document) { + + var FRAGMENT = 'fragment'; + var TEMPLATE = 'template'; + var HAS_CONTENT = ('content' in create(TEMPLATE)); + var createHTML = HAS_CONTENT ? function (html) { + var template = create(TEMPLATE); + template.innerHTML = html; + return template.content; + } : function (html) { + var content = create(FRAGMENT); + var template = create(TEMPLATE); + var childNodes = null; + + if (/^[^\S]*?<(col(?:group)?|t(?:head|body|foot|r|d|h))/i.test(html)) { + var selector = RegExp.$1; + template.innerHTML = '' + html + '
'; + childNodes = template.querySelectorAll(selector); + } else { + template.innerHTML = html; + childNodes = template.childNodes; + } + + append(content, childNodes); + return content; + }; + return function createContent(markup, type) { + return (type === 'svg' ? createSVG : createHTML)(markup); + }; + + function append(root, childNodes) { + var length = childNodes.length; + + while (length--) { + root.appendChild(childNodes[0]); + } + } + + function create(element) { + return element === FRAGMENT ? document.createDocumentFragment() : document.createElementNS('http://www.w3.org/1999/xhtml', element); + } // it could use createElementNS when hasNode is there + // but this fallback is equally fast and easier to maintain + // it is also battle tested already in all IE + + + function createSVG(svg) { + var content = create(FRAGMENT); + var template = create('div'); + template.innerHTML = '' + svg + ''; + append(content, template.firstChild.childNodes); + return content; + } + }(document); + + /*! (c) Andrea Giammarchi */ + function disconnected(poly) { + + var Event = poly.Event; + var WeakSet = poly.WeakSet; + var notObserving = true; + var observer = null; + return function observe(node) { + if (notObserving) { + notObserving = !notObserving; + observer = new WeakSet(); + startObserving(node.ownerDocument); + } + + observer.add(node); + return node; + }; + + function startObserving(document) { + var connected = new WeakSet(); + var disconnected = new WeakSet(); + + try { + new MutationObserver(changes).observe(document, { + subtree: true, + childList: true + }); + } catch (o_O) { + var timer = 0; + var records = []; + + var reschedule = function reschedule(record) { + records.push(record); + clearTimeout(timer); + timer = setTimeout(function () { + changes(records.splice(timer = 0, records.length)); + }, 0); + }; + + document.addEventListener('DOMNodeRemoved', function (event) { + reschedule({ + addedNodes: [], + removedNodes: [event.target] + }); + }, true); + document.addEventListener('DOMNodeInserted', function (event) { + reschedule({ + addedNodes: [event.target], + removedNodes: [] + }); + }, true); + } + + function changes(records) { + for (var record, length = records.length, i = 0; i < length; i++) { + record = records[i]; + dispatchAll(record.removedNodes, 'disconnected', disconnected, connected); + dispatchAll(record.addedNodes, 'connected', connected, disconnected); + } + } + + function dispatchAll(nodes, type, wsin, wsout) { + for (var node, event = new Event(type), length = nodes.length, i = 0; i < length; (node = nodes[i++]).nodeType === 1 && dispatchTarget(node, event, type, wsin, wsout)) { + } + } + + function dispatchTarget(node, event, type, wsin, wsout) { + if (observer.has(node) && !wsin.has(node)) { + wsout["delete"](node); + wsin.add(node); + node.dispatchEvent(event); + /* + // The event is not bubbling (perf reason: should it?), + // hence there's no way to know if + // stop/Immediate/Propagation() was called. + // Should DOM Level 0 work at all? + // I say it's a YAGNI case for the time being, + // and easy to implement in user-land. + if (!event.cancelBubble) { + var fn = node['on' + type]; + if (fn) + fn.call(node, event); + } + */ + } + + for (var // apparently is node.children || IE11 ... ^_^;; + // https://github.com/WebReflection/disconnected/issues/1 + children = node.children || [], length = children.length, i = 0; i < length; dispatchTarget(children[i++], event, type, wsin, wsout)) { + } + } + } + } + + /*! (c) Andrea Giammarchi - ISC */ + var importNode = function (document, appendChild, cloneNode, createTextNode, importNode) { + var _native = (importNode in document); // IE 11 has problems with cloning templates: + // it "forgets" empty childNodes. This feature-detects that. + + + var fragment = document.createDocumentFragment(); + fragment[appendChild](document[createTextNode]('g')); + fragment[appendChild](document[createTextNode]('')); + /* istanbul ignore next */ + + var content = _native ? document[importNode](fragment, true) : fragment[cloneNode](true); + return content.childNodes.length < 2 ? function importNode(node, deep) { + var clone = node[cloneNode](); + + for (var + /* istanbul ignore next */ + childNodes = node.childNodes || [], length = childNodes.length, i = 0; deep && i < length; i++) { + clone[appendChild](importNode(childNodes[i], deep)); + } + + return clone; + } : + /* istanbul ignore next */ + _native ? document[importNode] : function (node, deep) { + return node[cloneNode](!!deep); + }; + }(document, 'appendChild', 'cloneNode', 'createTextNode', 'importNode'); + + var trim = ''.trim || + /* istanbul ignore next */ + function () { + return String(this).replace(/^\s+|\s+/g, ''); + }; + + /*! (c) Andrea Giammarchi - ISC */ + // Custom + var UID = '-' + Math.random().toFixed(6) + '%'; // Edge issue! + + var UID_IE = false; + + try { + if (!function (template, content, tabindex) { + return content in template && (template.innerHTML = '

', template[content].childNodes[0].getAttribute(tabindex) == UID); + }(document.createElement('template'), 'content', 'tabindex')) { + UID = '_dt: ' + UID.slice(1, -1) + ';'; + UID_IE = true; + } + } catch (meh) {} + + var UIDC = ''; // DOM + + var COMMENT_NODE = 8; + var ELEMENT_NODE = 1; + var TEXT_NODE = 3; + var SHOULD_USE_TEXT_CONTENT = /^(?:style|textarea)$/i; + var VOID_ELEMENTS = /^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i; + + /*! (c) Andrea Giammarchi - ISC */ + function sanitize (template) { + return template.join(UIDC).replace(selfClosing, fullClosing).replace(attrSeeker, attrReplacer); + } + var spaces = ' \\f\\n\\r\\t'; + var almostEverything = '[^' + spaces + '\\/>"\'=]+'; + var attrName = '[' + spaces + ']+' + almostEverything; + var tagName = '<([A-Za-z]+[A-Za-z0-9:._-]*)((?:'; + var attrPartials = '(?:\\s*=\\s*(?:\'[^\']*?\'|"[^"]*?"|<[^>]*?>|' + almostEverything.replace('\\/', '') + '))?)'; + var attrSeeker = new RegExp(tagName + attrName + attrPartials + '+)([' + spaces + ']*/?>)', 'g'); + var selfClosing = new RegExp(tagName + attrName + attrPartials + '*)([' + spaces + ']*/>)', 'g'); + var findAttributes = new RegExp('(' + attrName + '\\s*=\\s*)([\'"]?)' + UIDC + '\\2', 'gi'); + + function attrReplacer($0, $1, $2, $3) { + return '<' + $1 + $2.replace(findAttributes, replaceAttributes) + $3; + } + + function replaceAttributes($0, $1, $2) { + return $1 + ($2 || '"') + UID + ($2 || '"'); + } + + function fullClosing($0, $1, $2) { + return VOID_ELEMENTS.test($1) ? $0 : '<' + $1 + $2 + '>'; + } + + var umap = (function (_) { + return { + // About: get: _.get.bind(_) + // It looks like WebKit/Safari didn't optimize bind at all, + // so that using bind slows it down by 60%. + // Firefox and Chrome are just fine in both cases, + // so let's use the approach that works fast everywhere ๐Ÿ‘ + get: function get(key) { + return _.get(key); + }, + set: function set(key, value) { + return _.set(key, value), value; + } + }; + }); + + /* istanbul ignore next */ + + var normalizeAttributes = UID_IE ? function (attributes, parts) { + var html = parts.join(' '); + return parts.slice.call(attributes, 0).sort(function (left, right) { + return html.indexOf(left.name) <= html.indexOf(right.name) ? -1 : 1; + }); + } : function (attributes, parts) { + return parts.slice.call(attributes, 0); + }; + + function find(node, path) { + var length = path.length; + var i = 0; + + while (i < length) { + node = node.childNodes[path[i++]]; + } + + return node; + } + + function parse(node, holes, parts, path) { + var childNodes = node.childNodes; + var length = childNodes.length; + var i = 0; + + while (i < length) { + var child = childNodes[i]; + + switch (child.nodeType) { + case ELEMENT_NODE: + var childPath = path.concat(i); + parseAttributes(child, holes, parts, childPath); + parse(child, holes, parts, childPath); + break; + + case COMMENT_NODE: + var textContent = child.textContent; + + if (textContent === UID) { + parts.shift(); + holes.push( // basicHTML or other non standard engines + // might end up having comments in nodes + // where they shouldn't, hence this check. + SHOULD_USE_TEXT_CONTENT.test(node.nodeName) ? Text(node, path) : Any(child, path.concat(i))); + } else { + switch (textContent.slice(0, 2)) { + case '/*': + if (textContent.slice(-2) !== '*/') break; + + case "\uD83D\uDC7B": + // ghost + node.removeChild(child); + i--; + length--; + } + } + + break; + + case TEXT_NODE: + // the following ignore is actually covered by browsers + // only basicHTML ends up on previous COMMENT_NODE case + // instead of TEXT_NODE because it knows nothing about + // special style or textarea behavior + + /* istanbul ignore if */ + if (SHOULD_USE_TEXT_CONTENT.test(node.nodeName) && trim.call(child.textContent) === UIDC) { + parts.shift(); + holes.push(Text(node, path)); + } + + break; + } + + i++; + } + } + + function parseAttributes(node, holes, parts, path) { + var attributes = node.attributes; + var cache = []; + var remove = []; + var array = normalizeAttributes(attributes, parts); + var length = array.length; + var i = 0; + + while (i < length) { + var attribute = array[i++]; + var direct = attribute.value === UID; + var sparse; + + if (direct || 1 < (sparse = attribute.value.split(UIDC)).length) { + var name = attribute.name; // the following ignore is covered by IE + // and the IE9 double viewBox test + + /* istanbul ignore else */ + + if (cache.indexOf(name) < 0) { + cache.push(name); + var realName = parts.shift().replace(direct ? /^(?:|[\S\s]*?\s)(\S+?)\s*=\s*('|")?$/ : new RegExp('^(?:|[\\S\\s]*?\\s)(' + name + ')\\s*=\\s*(\'|")[\\S\\s]*', 'i'), '$1'); + var value = attributes[realName] || // the following ignore is covered by browsers + // while basicHTML is already case-sensitive + + /* istanbul ignore next */ + attributes[realName.toLowerCase()]; + if (direct) holes.push(Attr(value, path, realName, null));else { + var skip = sparse.length - 2; + + while (skip--) { + parts.shift(); + } + + holes.push(Attr(value, path, realName, sparse)); + } + } + + remove.push(attribute); + } + } + + length = remove.length; + i = 0; + /* istanbul ignore next */ + + var cleanValue = 0 < length && UID_IE && !('ownerSVGElement' in node); + + while (i < length) { + // Edge HTML bug #16878726 + var attr = remove[i++]; // IE/Edge bug lighterhtml#63 - clean the value or it'll persist + + /* istanbul ignore next */ + + if (cleanValue) attr.value = ''; // IE/Edge bug lighterhtml#64 - don't use removeAttributeNode + + node.removeAttribute(attr.name); + } // This is a very specific Firefox/Safari issue + // but since it should be a not so common pattern, + // it's probably worth patching regardless. + // Basically, scripts created through strings are death. + // You need to create fresh new scripts instead. + // TODO: is there any other node that needs such nonsense? + + + var nodeName = node.nodeName; + + if (/^script$/i.test(nodeName)) { + // this used to be like that + // var script = createElement(node, nodeName); + // then Edge arrived and decided that scripts created + // through template documents aren't worth executing + // so it became this ... hopefully it won't hurt in the wild + var script = document.createElement(nodeName); + length = attributes.length; + i = 0; + + while (i < length) { + script.setAttributeNode(attributes[i++].cloneNode(true)); + } + + script.textContent = node.textContent; + node.parentNode.replaceChild(script, node); + } + } + + function Any(node, path) { + return { + type: 'any', + node: node, + path: path + }; + } + + function Attr(node, path, name, sparse) { + return { + type: 'attr', + node: node, + path: path, + name: name, + sparse: sparse + }; + } + + function Text(node, path) { + return { + type: 'text', + node: node, + path: path + }; + } + + // globals + var parsed = umap(new WeakMap$1()); + + function createInfo(options, template) { + var markup = (options.convert || sanitize)(template); + var transform = options.transform; + if (transform) markup = transform(markup); + var content = createContent(markup, options.type); + cleanContent(content); + var holes = []; + parse(content, holes, template.slice(0), []); + return { + content: content, + updates: function updates(content) { + var updates = []; + var len = holes.length; + var i = 0; + var off = 0; + + while (i < len) { + var info = holes[i++]; + var node = find(content, info.path); + + switch (info.type) { + case 'any': + updates.push({ + fn: options.any(node, []), + sparse: false + }); + break; + + case 'attr': + var sparse = info.sparse; + var fn = options.attribute(node, info.name, info.node); + if (sparse === null) updates.push({ + fn: fn, + sparse: false + });else { + off += sparse.length - 2; + updates.push({ + fn: fn, + sparse: true, + values: sparse + }); + } + break; + + case 'text': + updates.push({ + fn: options.text(node), + sparse: false + }); + node.textContent = ''; + break; + } + } + + len += off; + return function () { + var length = arguments.length; + + if (len !== length - 1) { + throw new Error(length - 1 + ' values instead of ' + len + '\n' + template.join('${value}')); + } + + var i = 1; + var off = 1; + + while (i < length) { + var update = updates[i - off]; + + if (update.sparse) { + var values = update.values; + var value = values[0]; + var j = 1; + var l = values.length; + off += l - 2; + + while (j < l) { + value += arguments[i++] + values[j++]; + } + + update.fn(value); + } else update.fn(arguments[i++]); + } + + return content; + }; + } + }; + } + + function createDetails(options, template) { + var info = parsed.get(template) || parsed.set(template, createInfo(options, template)); + return info.updates(importNode.call(document, info.content, true)); + } + + var empty = []; + + function domtagger(options) { + var previous = empty; + var updates = cleanContent; + return function (template) { + if (previous !== template) updates = createDetails(options, previous = template); + return updates.apply(null, arguments); + }; + } + + function cleanContent(fragment) { + var childNodes = fragment.childNodes; + var i = childNodes.length; + + while (i--) { + var child = childNodes[i]; + + if (child.nodeType !== 1 && trim.call(child.textContent).length === 0) { + fragment.removeChild(child); + } + } + } + + /*! (c) Andrea Giammarchi - ISC */ + var hyperStyle = function () { + + var IS_NON_DIMENSIONAL = /acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[ch]|zoo|^ord/i; + var hyphen = /([^A-Z])([A-Z]+)/g; + return function hyperStyle(node, original) { + return 'ownerSVGElement' in node ? svg(node, original) : update(node.style, false); + }; + + function ized($0, $1, $2) { + return $1 + '-' + $2.toLowerCase(); + } + + function svg(node, original) { + var style; + if (original) style = original.cloneNode(true);else { + node.setAttribute('style', '--hyper:style;'); + style = node.getAttributeNode('style'); + } + style.value = ''; + node.setAttributeNode(style); + return update(style, true); + } + + function toStyle(object) { + var key, + css = []; + + for (key in object) { + css.push(key.replace(hyphen, ized), ':', object[key], ';'); + } + + return css.join(''); + } + + function update(style, isSVG) { + var oldType, oldValue; + return function (newValue) { + var info, key, styleValue, value; + + switch (typeof(newValue)) { + case 'object': + if (newValue) { + if (oldType === 'object') { + if (!isSVG) { + if (oldValue !== newValue) { + for (key in oldValue) { + if (!(key in newValue)) { + style[key] = ''; + } + } + } + } + } else { + if (isSVG) style.value = '';else style.cssText = ''; + } + + info = isSVG ? {} : style; + + for (key in newValue) { + value = newValue[key]; + styleValue = typeof value === 'number' && !IS_NON_DIMENSIONAL.test(key) ? value + 'px' : value; + if (!isSVG && /^--/.test(key)) info.setProperty(key, styleValue);else info[key] = styleValue; + } + + oldType = 'object'; + if (isSVG) style.value = toStyle(oldValue = info);else oldValue = newValue; + break; + } + + default: + if (oldValue != newValue) { + oldType = 'string'; + oldValue = newValue; + if (isSVG) style.value = newValue || '';else style.cssText = newValue || ''; + } + + break; + } + }; + } + }(); + + /*! (c) Andrea Giammarchi - ISC */ + var Wire = function (slice, proto) { + proto = Wire.prototype; + proto.ELEMENT_NODE = 1; + proto.nodeType = 111; + + proto.remove = function (keepFirst) { + var childNodes = this.childNodes; + var first = this.firstChild; + var last = this.lastChild; + this._ = null; + + if (keepFirst && childNodes.length === 2) { + last.parentNode.removeChild(last); + } else { + var range = this.ownerDocument.createRange(); + range.setStartBefore(keepFirst ? childNodes[1] : first); + range.setEndAfter(last); + range.deleteContents(); + } + + return first; + }; + + proto.valueOf = function (forceAppend) { + var fragment = this._; + var noFragment = fragment == null; + if (noFragment) fragment = this._ = this.ownerDocument.createDocumentFragment(); + + if (noFragment || forceAppend) { + for (var n = this.childNodes, i = 0, l = n.length; i < l; i++) { + fragment.appendChild(n[i]); + } + } + + return fragment; + }; + + return Wire; + + function Wire(childNodes) { + var nodes = this.childNodes = slice.call(childNodes, 0); + this.firstChild = nodes[0]; + this.lastChild = nodes[nodes.length - 1]; + this.ownerDocument = nodes[0].ownerDocument; + this._ = null; + } + }([].slice); + + // Node.CONSTANTS + var DOCUMENT_FRAGMENT_NODE = 11; // SVG related constants + + var OWNER_SVG_ELEMENT = 'ownerSVGElement'; // Custom Elements / MutationObserver constants + + var CONNECTED = 'connected'; + var DISCONNECTED = 'dis' + CONNECTED; + + var componentType = Component.prototype.nodeType; + var wireType = Wire.prototype.nodeType; + var observe = disconnected({ + Event: CustomEvent$1, + WeakSet: WeakSet$1 + }); + + var asHTML = function asHTML(html) { + return { + html: html + }; + }; // returns nodes from wires and components + + + var asNode = function asNode(item, i) { + switch (item.nodeType) { + case wireType: + // in the Wire case, the content can be + // removed, post-pended, inserted, or pre-pended and + // all these cases are handled by domdiff already + + /* istanbul ignore next */ + return 1 / i < 0 ? i ? item.remove(true) : item.lastChild : i ? item.valueOf(true) : item.firstChild; + + case componentType: + return asNode(item.render(), i); + + default: + return item; + } + }; // returns true if domdiff can handle the value + + + var canDiff = function canDiff(value) { + return 'ELEMENT_NODE' in value; + }; // borrowed from uhandlers + // https://github.com/WebReflection/uhandlers + + + var booleanSetter = function booleanSetter(node, key, oldValue) { + return function (newValue) { + if (oldValue !== !!newValue) { + if (oldValue = !!newValue) node.setAttribute(key, '');else node.removeAttribute(key); + } + }; + }; + + var hyperSetter = function hyperSetter(node, name, svg) { + return svg ? function (value) { + try { + node[name] = value; + } catch (nope) { + node.setAttribute(name, value); + } + } : function (value) { + node[name] = value; + }; + }; // when a Promise is used as interpolation value + // its result must be parsed once resolved. + // This callback is in charge of understanding what to do + // with a returned value once the promise is resolved. + + + var invokeAtDistance = function invokeAtDistance(value, callback) { + callback(value.placeholder); + + if ('text' in value) { + Promise.resolve(value.text).then(String).then(callback); + } else if ('any' in value) { + Promise.resolve(value.any).then(callback); + } else if ('html' in value) { + Promise.resolve(value.html).then(asHTML).then(callback); + } else { + Promise.resolve(Intent.invoke(value, callback)).then(callback); + } + }; // quick and dirty way to check for Promise/ish values + + + var isPromise_ish = function isPromise_ish(value) { + return value != null && 'then' in value; + }; // list of attributes that should not be directly assigned + + + var readOnly = /^(?:form|list)$/i; // reused every slice time + + var slice = [].slice; // simplifies text node creation + + var text = function text(node, _text) { + return node.ownerDocument.createTextNode(_text); + }; + + function Tagger(type) { + this.type = type; + return domtagger(this); + } + + Tagger.prototype = { + // there are four kind of attributes, and related behavior: + // * events, with a name starting with `on`, to add/remove event listeners + // * special, with a name present in their inherited prototype, accessed directly + // * regular, accessed through get/setAttribute standard DOM methods + // * style, the only regular attribute that also accepts an object as value + // so that you can style=${{width: 120}}. In this case, the behavior has been + // fully inspired by Preact library and its simplicity. + attribute: function attribute(node, name, original) { + var isSVG = (OWNER_SVG_ELEMENT in node); + var oldValue; // if the attribute is the style one + // handle it differently from others + + if (name === 'style') return hyperStyle(node, original, isSVG); // direct accessors for and friends + else if (name.slice(0, 1) === '.') return hyperSetter(node, name.slice(1), isSVG); // boolean accessors for and friends + else if (name.slice(0, 1) === '?') return booleanSetter(node, name.slice(1)); // the name is an event one, + // add/remove event listeners accordingly + else if (/^on/.test(name)) { + var type = name.slice(2); + + if (type === CONNECTED || type === DISCONNECTED) { + observe(node); + } else if (name.toLowerCase() in node) { + type = type.toLowerCase(); + } + + return function (newValue) { + if (oldValue !== newValue) { + if (oldValue) node.removeEventListener(type, oldValue, false); + oldValue = newValue; + if (newValue) node.addEventListener(type, newValue, false); + } + }; + } // the attribute is special ('value' in input) + // and it's not SVG *or* the name is exactly data, + // in this case assign the value directly + else if (name === 'data' || !isSVG && name in node && !readOnly.test(name)) { + return function (newValue) { + if (oldValue !== newValue) { + oldValue = newValue; + + if (node[name] !== newValue && newValue == null) { + // cleanup on null to avoid silly IE/Edge bug + node[name] = ''; + node.removeAttribute(name); + } else node[name] = newValue; + } + }; + } else if (name in Intent.attributes) { + return function (any) { + var newValue = Intent.attributes[name](node, any); + + if (oldValue !== newValue) { + oldValue = newValue; + if (newValue == null) node.removeAttribute(name);else node.setAttribute(name, newValue); + } + }; + } // in every other case, use the attribute node as it is + // update only the value, set it as node only when/if needed + else { + var owner = false; + var attribute = original.cloneNode(true); + return function (newValue) { + if (oldValue !== newValue) { + oldValue = newValue; + + if (attribute.value !== newValue) { + if (newValue == null) { + if (owner) { + owner = false; + node.removeAttributeNode(attribute); + } + + attribute.value = newValue; + } else { + attribute.value = newValue; + + if (!owner) { + owner = true; + node.setAttributeNode(attribute); + } + } + } + } + }; + } + }, + // in a hyper(node)`
${content}
` case + // everything could happen: + // * it's a JS primitive, stored as text + // * it's null or undefined, the node should be cleaned + // * it's a component, update the content by rendering it + // * it's a promise, update the content once resolved + // * it's an explicit intent, perform the desired operation + // * it's an Array, resolve all values if Promises and/or + // update the node with the resulting list of content + any: function any(node, childNodes) { + var diffOptions = { + node: asNode, + before: node + }; + var nodeType = OWNER_SVG_ELEMENT in node ? + /* istanbul ignore next */ + 'svg' : 'html'; + var fastPath = false; + var oldValue; + + var anyContent = function anyContent(value) { + switch (typeof(value)) { + case 'string': + case 'number': + case 'boolean': + if (fastPath) { + if (oldValue !== value) { + oldValue = value; + childNodes[0].textContent = value; + } + } else { + fastPath = true; + oldValue = value; + childNodes = domdiff(node.parentNode, childNodes, [text(node, value)], diffOptions); + } + + break; + + case 'function': + anyContent(value(node)); + break; + + case 'object': + case 'undefined': + if (value == null) { + fastPath = false; + childNodes = domdiff(node.parentNode, childNodes, [], diffOptions); + break; + } + + default: + fastPath = false; + oldValue = value; + + if (isArray(value)) { + if (value.length === 0) { + if (childNodes.length) { + childNodes = domdiff(node.parentNode, childNodes, [], diffOptions); + } + } else { + switch (typeof(value[0])) { + case 'string': + case 'number': + case 'boolean': + anyContent({ + html: value + }); + break; + + case 'object': + if (isArray(value[0])) { + value = value.concat.apply([], value); + } + + if (isPromise_ish(value[0])) { + Promise.all(value).then(anyContent); + break; + } + + default: + childNodes = domdiff(node.parentNode, childNodes, value, diffOptions); + break; + } + } + } else if (canDiff(value)) { + childNodes = domdiff(node.parentNode, childNodes, value.nodeType === DOCUMENT_FRAGMENT_NODE ? slice.call(value.childNodes) : [value], diffOptions); + } else if (isPromise_ish(value)) { + value.then(anyContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, anyContent); + } else if ('text' in value) { + anyContent(String(value.text)); + } else if ('any' in value) { + anyContent(value.any); + } else if ('html' in value) { + childNodes = domdiff(node.parentNode, childNodes, slice.call(createContent([].concat(value.html).join(''), nodeType).childNodes), diffOptions); + } else if ('length' in value) { + anyContent(slice.call(value)); + } else { + anyContent(Intent.invoke(value, anyContent)); + } + + break; + } + }; + + return anyContent; + }, + // style or textareas don't accept HTML as content + // it's pointless to transform or analyze anything + // different from text there but it's worth checking + // for possible defined intents. + text: function text(node) { + var oldValue; + + var textContent = function textContent(value) { + if (oldValue !== value) { + oldValue = value; + + var type = typeof(value); + + if (type === 'object' && value) { + if (isPromise_ish(value)) { + value.then(textContent); + } else if ('placeholder' in value) { + invokeAtDistance(value, textContent); + } else if ('text' in value) { + textContent(String(value.text)); + } else if ('any' in value) { + textContent(value.any); + } else if ('html' in value) { + textContent([].concat(value.html).join('')); + } else if ('length' in value) { + textContent(slice.call(value).join('')); + } else { + textContent(Intent.invoke(value, textContent)); + } + } else if (type === 'function') { + textContent(value(node)); + } else { + node.textContent = value == null ? '' : value; + } + } + }; + + return textContent; + } + }; + + var isNoOp = false; + + var _templateLiteral = function templateLiteral(tl) { + var RAW = 'raw'; + + var isBroken = function isBroken(UA) { + return /(Firefox|Safari)\/(\d+)/.test(UA) && !/(Chrom[eium]+|Android)\/(\d+)/.test(UA); + }; + + var broken = isBroken((document.defaultView.navigator || {}).userAgent); + var FTS = !(RAW in tl) || tl.propertyIsEnumerable(RAW) || !Object.isFrozen(tl[RAW]); + + if (broken || FTS) { + var forever = {}; + + var foreverCache = function foreverCache(tl) { + for (var key = '.', i = 0; i < tl.length; i++) { + key += tl[i].length + '.' + tl[i]; + } + + return forever[key] || (forever[key] = tl); + }; // Fallback TypeScript shenanigans + + + if (FTS) _templateLiteral = foreverCache; // try fast path for other browsers: + // store the template as WeakMap key + // and forever cache it only when it's not there. + // this way performance is still optimal, + // penalized only when there are GC issues + else { + var wm = new WeakMap$1(); + + var set = function set(tl, unique) { + wm.set(tl, unique); + return unique; + }; + + _templateLiteral = function templateLiteral(tl) { + return wm.get(tl) || set(tl, foreverCache(tl)); + }; + } + } else { + isNoOp = true; + } + + return TL(tl); + }; + + function TL(tl) { + return isNoOp ? tl : _templateLiteral(tl); + } + + function tta (template) { + var length = arguments.length; + var args = [TL(template)]; + var i = 1; + + while (i < length) { + args.push(arguments[i++]); + } + + return args; + } + /** + * best benchmark goes here + * https://jsperf.com/tta-bench + * I should probably have an @ungap/template-literal-es too + export default (...args) => { + args[0] = unique(args[0]); + return args; + }; + */ + + var wires = new WeakMap$1(); // A wire is a callback used as tag function + // to lazily relate a generic object to a template literal. + // hyper.wire(user)`
${user.name}
`; => the div#user + // This provides the ability to have a unique DOM structure + // related to a unique JS object through a reusable template literal. + // A wire can specify a type, as svg or html, and also an id + // via html:id or :id convention. Such :id allows same JS objects + // to be associated to different DOM structures accordingly with + // the used template literal without losing previously rendered parts. + + var wire = function wire(obj, type) { + return obj == null ? content(type || 'html') : weakly(obj, type || 'html'); + }; // A wire content is a virtual reference to one or more nodes. + // It's represented by either a DOM node, or an Array. + // In both cases, the wire content role is to simply update + // all nodes through the list of related callbacks. + // In few words, a wire content is like an invisible parent node + // in charge of updating its content like a bound element would do. + + + var content = function content(type) { + var wire, tagger, template; + return function () { + var args = tta.apply(null, arguments); + + if (template !== args[0]) { + template = args[0]; + tagger = new Tagger(type); + wire = wireContent(tagger.apply(tagger, args)); + } else { + tagger.apply(tagger, args); + } + + return wire; + }; + }; // wires are weakly created through objects. + // Each object can have multiple wires associated + // and this is thanks to the type + :id feature. + + + var weakly = function weakly(obj, type) { + var i = type.indexOf(':'); + var wire = wires.get(obj); + var id = type; + + if (-1 < i) { + id = type.slice(i + 1); + type = type.slice(0, i) || 'html'; + } + + if (!wire) wires.set(obj, wire = {}); + return wire[id] || (wire[id] = content(type)); + }; // A document fragment loses its nodes + // as soon as it is appended into another node. + // This has the undesired effect of losing wired content + // on a second render call, because (by then) the fragment would be empty: + // no longer providing access to those sub-nodes that ultimately need to + // stay associated with the original interpolation. + // To prevent hyperHTML from forgetting about a fragment's sub-nodes, + // fragments are instead returned as an Array of nodes or, if there's only one entry, + // as a single referenced node which, unlike fragments, will indeed persist + // wire content throughout multiple renderings. + // The initial fragment, at this point, would be used as unique reference to this + // array of nodes or to this single referenced node. + + + var wireContent = function wireContent(node) { + var childNodes = node.childNodes; + var length = childNodes.length; + return length === 1 ? childNodes[0] : length ? new Wire(childNodes) : node; + }; + + // are already known to hyperHTML + + var bewitched = new WeakMap$1(); // better known as hyper.bind(node), the render is + // the main tag function in charge of fully upgrading + // or simply updating, contexts used as hyperHTML targets. + // The `this` context is either a regular DOM node or a fragment. + + function render() { + var wicked = bewitched.get(this); + var args = tta.apply(null, arguments); + + if (wicked && wicked.template === args[0]) { + wicked.tagger.apply(null, args); + } else { + upgrade.apply(this, args); + } + + return this; + } // an upgrade is in charge of collecting template info, + // parse it once, if unknown, to map all interpolations + // as single DOM callbacks, relate such template + // to the current context, and render it after cleaning the context up + + + function upgrade(template) { + var type = OWNER_SVG_ELEMENT in this ? 'svg' : 'html'; + var tagger = new Tagger(type); + bewitched.set(this, { + tagger: tagger, + template: template + }); + this.textContent = ''; + this.appendChild(tagger.apply(null, arguments)); + } + + /*! (c) Andrea Giammarchi (ISC) */ + // you can do the following + // const {bind, wire} = hyperHTML; + // and use them right away: bind(node)`hello!`; + + var bind = function bind(context) { + return render.bind(context); + }; + + var define = Intent.define; + var tagger = Tagger.prototype; + hyper.Component = Component; + hyper.bind = bind; + hyper.define = define; + hyper.diff = domdiff; + hyper.hyper = hyper; + hyper.observe = observe; + hyper.tagger = tagger; + hyper.wire = wire; // exported as shared utils + // for projects based on hyperHTML + // that don't necessarily need upfront polyfills + // i.e. those still targeting IE + + hyper._ = { + WeakMap: WeakMap$1, + WeakSet: WeakSet$1 + }; // the wire content is the lazy defined + // html or svg property of each hyper.Component + + setup(content); // everything is exported directly or through the + // that "magically" understands what's the best + // thing to do with passed arguments + + function hyper(HTML) { + return arguments.length < 2 ? HTML == null ? content('html') : typeof HTML === 'string' ? hyper.wire(null, HTML) : 'raw' in HTML ? content('html')(HTML) : 'nodeType' in HTML ? hyper.bind(HTML) : weakly(HTML, 'html') : ('raw' in HTML ? content('html') : hyper.wire).apply(null, arguments); + } + + + + + + + + + + + + return hyper; + +}(document)); diff --git a/logo.txt b/logo.txt new file mode 100644 index 00000000..6f6947c3 --- /dev/null +++ b/logo.txt @@ -0,0 +1,20 @@ + .,,. + .;srrrrr: + .si, .;S; + ,;;rrS; .is + :ss;,,,ri;...,ri: + .ri;. :rrrrr;. + ;ir. + .. ,:;;;si: .. + .,:;rr: ,ss;::;ii, :rr;:,. + ;ssr:,. .is. .ii. .,:rss; + :;rr;:,. .is. .ii. .,:;rr;: + .,:;r; ,is;::;ss, ;r;:,. + :is;;;:, + .ri;. + .;rrrrr: ;ir. + :ir,...;ir,,,;ss: + si. ;Ssr;;, + ;S;. ,is. + :rrrrrs;. + .,,. diff --git a/logo/basichtml.inkscape.svg b/logo/basichtml.inkscape.svg new file mode 100644 index 00000000..6b235e40 --- /dev/null +++ b/logo/basichtml.inkscape.svg @@ -0,0 +1,201 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/basichtml.png b/logo/basichtml.png new file mode 100644 index 00000000..5a0179ad Binary files /dev/null and b/logo/basichtml.png differ diff --git a/logo/basichtml.svg b/logo/basichtml.svg new file mode 100644 index 00000000..95f949d7 --- /dev/null +++ b/logo/basichtml.svg @@ -0,0 +1,157 @@ + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/creepy-html.jpg b/logo/creepy-html.jpg new file mode 100644 index 00000000..7c3bdb80 Binary files /dev/null and b/logo/creepy-html.jpg differ diff --git a/logo/hyperhtml.inkscape.svg b/logo/hyperhtml.inkscape.svg new file mode 100644 index 00000000..ad713d76 --- /dev/null +++ b/logo/hyperhtml.inkscape.svg @@ -0,0 +1,198 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/hyperhtml.png b/logo/hyperhtml.png new file mode 100644 index 00000000..f4b6b10e Binary files /dev/null and b/logo/hyperhtml.png differ diff --git a/logo/hyperhtml.svg b/logo/hyperhtml.svg new file mode 100644 index 00000000..c0c1fd98 --- /dev/null +++ b/logo/hyperhtml.svg @@ -0,0 +1,154 @@ + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/nativehtml.inkscape.svg b/logo/nativehtml.inkscape.svg new file mode 100644 index 00000000..d5f4d7b3 --- /dev/null +++ b/logo/nativehtml.inkscape.svg @@ -0,0 +1,217 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/nativehtml.png b/logo/nativehtml.png new file mode 100644 index 00000000..eb08ceab Binary files /dev/null and b/logo/nativehtml.png differ diff --git a/logo/nativehtml.svg b/logo/nativehtml.svg new file mode 100644 index 00000000..111aea0c --- /dev/null +++ b/logo/nativehtml.svg @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/viper.png b/logo/viper.png new file mode 100644 index 00000000..dd8041bf Binary files /dev/null and b/logo/viper.png differ diff --git a/logo/viper.svg b/logo/viper.svg new file mode 100644 index 00000000..13d27cad --- /dev/null +++ b/logo/viper.svg @@ -0,0 +1,456 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/viperhtml.inkscape.svg b/logo/viperhtml.inkscape.svg new file mode 100644 index 00000000..c4fc83cf --- /dev/null +++ b/logo/viperhtml.inkscape.svg @@ -0,0 +1,192 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/logo/viperhtml.png b/logo/viperhtml.png new file mode 100644 index 00000000..e5cda487 Binary files /dev/null and b/logo/viperhtml.png differ diff --git a/logo/viperhtml.svg b/logo/viperhtml.svg new file mode 100644 index 00000000..c5df5091 --- /dev/null +++ b/logo/viperhtml.svg @@ -0,0 +1,148 @@ + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/min.js b/min.js index 71aa2e50..c31bd388 100644 --- a/min.js +++ b/min.js @@ -1,2 +1 @@ -var hyperHTML=function(){"use strict";/*! (C) 2017 Andrea Giammarchi @WebReflection (MIT) */ -function e(e){return b in this&&this[b].s===e?m.apply(this,arguments):v.apply(this,arguments)}function t(e,t){for(var n,r=k.call(e.attributes),i=0,a=r.length;i",w=b.trim||function(){return this.replace(/^\s+|\s+$/g,"")},k=[].slice,x=typeof WeakMap==typeof x?{get:function(e){return e[b]},set:function(e,t){Object.defineProperty(e,b,{configurable:!0,value:t})}}:new WeakMap;return e.SPECIAL_ATTRIBUTE=T,e}();try{module.exports=hyperHTML}catch(e){} \ No newline at end of file +/*! (c) Andrea Giammarchi (ISC) */var hyperHTML=function(N){"use strict";var t={};try{t.WeakMap=WeakMap}catch(e){t.WeakMap=function(t,e){var n=e.defineProperty,r=e.hasOwnProperty,i=a.prototype;return i.delete=function(e){return this.has(e)&&delete e[this._]},i.get=function(e){return this.has(e)?e[this._]:void 0},i.has=function(e){return r.call(e,this._)},i.set=function(e,t){return n(e,this._,{configurable:!0,value:t}),this},a;function a(e){n(this,"_",{value:"_@ungap/weakmap"+t++}),e&&e.forEach(o,this)}function o(e){this.set(e[0],e[1])}}(Math.random(),Object)}var s=t.WeakMap,i={};try{i.WeakSet=WeakSet}catch(e){!function(e,t){var n=r.prototype;function r(){t(this,"_",{value:"_@ungap/weakmap"+e++})}n.add=function(e){return this.has(e)||t(e,this._,{value:!0,configurable:!0}),this},n.has=function(e){return this.hasOwnProperty.call(e,this._)},n.delete=function(e){return this.has(e)&&delete e[this._]},i.WeakSet=r}(Math.random(),Object.defineProperty)}function m(e,t,n,r,i,a){for(var o=("selectedIndex"in t),u=o;ro;)--c;l=u+r-c;var m=Array(l),y=s[c];for(--n;y;){for(var b=y.newi,w=y.oldi;b>>0;n"+e+"",r.querySelectorAll(t)):(r.innerHTML=e,r.childNodes)),n},function(e,t){return("svg"===t?function(e){var t=H(O),n=H("div");return n.innerHTML=''+e+"",F(t,n.firstChild.childNodes),t}:M)(e)});function F(e,t){for(var n=t.length;n--;)e.appendChild(t[0])}function H(e){return e===O?S.createDocumentFragment():S.createElementNS("http://www.w3.org/1999/xhtml",e)}var I,z,V,Z,G,q,B,J,K,Q,U=(z="appendChild",V="cloneNode",Z="createTextNode",q=(G="importNode")in(I=N),(B=I.createDocumentFragment())[z](I[Z]("g")),B[z](I[Z]("")),(q?I[G](B,!0):B[V](!0)).childNodes.length<2?function e(t,n){for(var r=t[V](),i=t.childNodes||[],a=i.length,o=0;n&&o

',J[K].childNodes[0].getAttribute(Q)==Y)||(Y="_dt: "+Y.slice(1,-1)+";",ee=!0)}catch(e){}var te="\x3c!--"+Y+"--\x3e",ne=8,re=1,ie=3,ae=/^(?:style|textarea)$/i,oe=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i;var ue=" \\f\\n\\r\\t",ce="[^"+ue+"\\/>\"'=]+",le="["+ue+"]+"+ce,se="<([A-Za-z]+[A-Za-z0-9:._-]*)((?:",fe="(?:\\s*=\\s*(?:'[^']*?'|\"[^\"]*?\"|<[^>]*?>|"+ce.replace("\\/","")+"))?)",he=new RegExp(se+le+fe+"+)(["+ue+"]*/?>)","g"),de=new RegExp(se+le+fe+"*)(["+ue+"]*/>)","g"),ve=new RegExp("("+le+"\\s*=\\s*)(['\"]?)"+te+"\\2","gi");function pe(e,t,n,r){return"<"+t+n.replace(ve,ge)+r}function ge(e,t,n){return t+(n||'"')+Y+(n||'"')}function me(e,t,n){return oe.test(t)?e:"<"+t+n+">"}var ye=ee?function(e,t){var n=t.join(" ");return t.slice.call(e,0).sort(function(e,t){return n.indexOf(e.name)<=n.indexOf(t.name)?-1:1})}:function(e,t){return t.slice.call(e,0)};function be(e,t,n,r){for(var i=e.childNodes,a=i.length,o=0;o=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.15.0", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.15.0.tgz", + "integrity": "sha512-0NqAC1IJE0S0+lL1SWFMxMkz1pKCNCjI4tr2Zx4LJSXxCLAdr6KyArnY+sno5m3yH9g737ygOyPABDsnXkpxiA==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.10.3", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.10.3.tgz", + "integrity": "sha512-5YqWxYE3pyhIi84L84YcwjeEgS+fa7ZjK6IBVGTjDVfm64njkR2lfDhVR5OudLk8x2GK59YoSyVv+L/03k1q9w==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.10.3", + "@babel/generator": "^7.10.3", + "@babel/helper-module-transforms": "^7.10.1", + "@babel/helpers": "^7.10.1", + "@babel/parser": "^7.10.3", + "@babel/template": "^7.10.3", + "@babel/traverse": "^7.10.3", + "@babel/types": "^7.10.3", + "convert-source-map": "^1.7.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.1", + "json5": "^2.1.2", + "lodash": "^4.17.13", + "resolve": "^1.3.2", + "semver": "^5.4.1", + "source-map": "^0.5.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/generator": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.15.4.tgz", + "integrity": "sha512-d3itta0tu+UayjEORPNz6e1T3FtvWlP5N4V5M+lhp/CxT4oAA7/NcScnpRyspUMLK6tu9MNHmQHxRykuN2R7hw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4", + "jsesc": "^2.5.1", + "source-map": "^0.5.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-annotate-as-pure": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.15.4.tgz", + "integrity": "sha512-QwrtdNvUNsPCj2lfNQacsGSQvGX8ee1ttrBrcozUP2Sv/jylewBP/8QFe6ZkBsC8T/GYWonNAWJV4aRR9AL2DA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-builder-binary-assignment-operator-visitor": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.15.4.tgz", + "integrity": "sha512-P8o7JP2Mzi0SdC6eWr1zF+AEYvrsZa7GSY1lTayjF5XJhVH0kjLYUZPvTMflP7tBgZoe9gIhTa60QwFpqh/E0Q==", + "dev": true, + "dependencies": { + "@babel/helper-explode-assignable-expression": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.8.8", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.8.8.tgz", + "integrity": "sha512-LYVPdwkrQEiX9+1R29Ld/wTrmQu1SSKYnuOk3g0CkcZMA1p0gsNxJFj/3gBdaJ7Cg0Fnek5z0DsMULePP7Lrqg==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.8.3", + "@babel/helper-regex": "^7.8.3", + "regexpu-core": "^4.7.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-explode-assignable-expression": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.15.4.tgz", + "integrity": "sha512-J14f/vq8+hdC2KoWLIQSsGrC9EFBKE4NFts8pfMpymfApds+fPqR30AOUWc4tyr56h9l/GA1Sxv2q3dLZWbQ/g==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-function-name": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.15.4.tgz", + "integrity": "sha512-Z91cOMM4DseLIGOnog+Z8OI6YseR9bua+HpvLAQ2XayUGU+neTtX+97caALaLdyu53I/fjhbeCnWnRH1O3jFOw==", + "dev": true, + "dependencies": { + "@babel/helper-get-function-arity": "^7.15.4", + "@babel/template": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-get-function-arity": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.15.4.tgz", + "integrity": "sha512-1/AlxSF92CmGZzHnC515hm4SirTxtpDnLEJ0UyEMgTMZN+6bxXKg04dKhiRx5Enel+SUA1G1t5Ed/yQia0efrA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-hoist-variables": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.15.4.tgz", + "integrity": "sha512-VTy085egb3jUGVK9ycIxQiPbquesq0HUQ+tPO0uv5mPEBZipk+5FkRKiWq5apuyTE9FUrjENB0rCf8y+n+UuhA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-member-expression-to-functions": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.15.4.tgz", + "integrity": "sha512-cokOMkxC/BTyNP1AlY25HuBWM32iCEsLPI4BHDpJCHHm1FU2E7dKWWIXJgQgSFiu4lp8q3bL1BIKwqkSUviqtA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.15.4.tgz", + "integrity": "sha512-jeAHZbzUwdW/xHgHQ3QmWR4Jg6j15q4w/gCfwZvtqOxoo5DKtLHk8Bsf4c5RZRC7NmLEs+ohkdq8jFefuvIxAA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.15.4.tgz", + "integrity": "sha512-9fHHSGE9zTC++KuXLZcB5FKgvlV83Ox+NLUmQTawovwlJ85+QMhk1CnVk406CQVj97LaWod6KVjl2Sfgw9Aktw==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-simple-access": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "@babel/helper-validator-identifier": "^7.14.9", + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-optimise-call-expression": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.15.4.tgz", + "integrity": "sha512-E/z9rfbAOt1vDW1DR7k4SzhzotVV5+qMciWV6LaG1g4jeFrkDlJedjtV4h0i4Q/ITnUu+Pk08M7fczsB9GXBDw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz", + "integrity": "sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-regex": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.8.3.tgz", + "integrity": "sha512-BWt0QtYv/cg/NecOAZMdcn/waj/5P26DR4mVLXfFtDokSR6fyuG0Pj+e2FqtSME+MqED1khnSMulkmGl8qWiUQ==", + "dev": true, + "dependencies": { + "lodash": "^4.17.13" + } + }, + "node_modules/@babel/helper-remap-async-to-generator": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.15.4.tgz", + "integrity": "sha512-v53MxgvMK/HCwckJ1bZrq6dNKlmwlyRNYM6ypaRTdXWGOE2c1/SCa6dL/HimhPulGhZKw9W0QhREM583F/t0vQ==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-wrap-function": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-replace-supers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.15.4.tgz", + "integrity": "sha512-/ztT6khaXF37MS47fufrKvIsiQkx1LBRvSJNzRqmbyeZnTwU9qBxXYLaaT/6KaxfKhjs2Wy8kG8ZdsFUuWBjzw==", + "dev": true, + "dependencies": { + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-simple-access": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.15.4.tgz", + "integrity": "sha512-UzazrDoIVOZZcTeHHEPYrr1MvTR/K+wgLg6MY6e1CJyaRhbibftF6fR2KU2sFRtI/nERUZR9fBd6aKgBlIBaPg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.15.4.tgz", + "integrity": "sha512-BMRLsdh+D1/aap19TycS4eD1qELGrCBJwzaY9IE8LrpJtJb+H7rQkPIdsfgnMtLBA6DJls7X9z93Z4U8h7xw0A==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.15.4.tgz", + "integrity": "sha512-HsFqhLDZ08DxCpBdEVtKmywj6PQbwnF6HHybur0MAnkAKnlS6uHkwnmRIkElB2Owpfb4xL4NwDmDLFubueDXsw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.14.9", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.9.tgz", + "integrity": "sha512-pQYxPY0UP6IHISRitNe8bsijHex4TWZXi2HwKVsjPiltzlhse2znVcm9Ace510VT1kxIHjGJCZZQBX2gJDbo0g==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.14.5.tgz", + "integrity": "sha512-OX8D5eeX4XwcroVW45NMvoYaIuFI+GQpA2a8Gi+X/U/cDUIRsV37qQfF905F0htTRCREQIB4KqPeaveRJUl3Ow==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-wrap-function": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.15.4.tgz", + "integrity": "sha512-Y2o+H/hRV5W8QhIfTpRIBwl57y8PrZt6JM3V8FOo5qarjshHItyH5lXlpMfBfmBefOqSCpKZs/6Dxqp0E/U+uw==", + "dev": true, + "dependencies": { + "@babel/helper-function-name": "^7.15.4", + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.15.4.tgz", + "integrity": "sha512-V45u6dqEJ3w2rlryYYXf6i9rQ5YMNu4FLS6ngs8ikblhu2VdR1AqAd6aJjBzmf2Qzh6KOLqKHxEN9+TFbAkAVQ==", + "dev": true, + "dependencies": { + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.14.5.tgz", + "integrity": "sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg==", + "dev": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.14.5", + "chalk": "^2.0.0", + "js-tokens": "^4.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.15.6.tgz", + "integrity": "sha512-S/TSCcsRuCkmpUuoWijua0Snt+f3ewU/8spLo+4AXJCZfT0bVCzLD5MuOKdrx0mlAptbKzn5AdgEIIKXxXkz9Q==", + "dev": true, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-proposal-unicode-property-regex": { + "version": "7.8.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.8.8.tgz", + "integrity": "sha512-EVhjVsMpbhLw9ZfHWSx2iy13Q8Z/eg8e8ccVWt23sWQK5l1UdkoLJPN5w69UA4uITGBnEZD2JOe4QOHycYKv8A==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.8.8", + "@babel/helper-plugin-utils": "^7.8.3" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-dotall-regex": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.8.3.tgz", + "integrity": "sha512-kLs1j9Nn4MQoBYdRXH6AeaXMbEJFaFu/v1nQkvib6QzTj8MZI5OQzqmD83/2jEM1z0DLilra5aWO5YpyC0ALIw==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.8.3", + "@babel/helper-plugin-utils": "^7.8.3" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env": { + "version": "7.10.3", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.10.3.tgz", + "integrity": "sha512-jHaSUgiewTmly88bJtMHbOd1bJf2ocYxb5BWKSDQIP5tmgFuS/n0gl+nhSrYDhT33m0vPxp+rP8oYYgPgMNQlg==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.10.3", + "@babel/helper-compilation-targets": "^7.10.2", + "@babel/helper-module-imports": "^7.10.3", + "@babel/helper-plugin-utils": "^7.10.3", + "@babel/plugin-proposal-async-generator-functions": "^7.10.3", + "@babel/plugin-proposal-class-properties": "^7.10.1", + "@babel/plugin-proposal-dynamic-import": "^7.10.1", + "@babel/plugin-proposal-json-strings": "^7.10.1", + "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.1", + "@babel/plugin-proposal-numeric-separator": "^7.10.1", + "@babel/plugin-proposal-object-rest-spread": "^7.10.3", + "@babel/plugin-proposal-optional-catch-binding": "^7.10.1", + "@babel/plugin-proposal-optional-chaining": "^7.10.3", + "@babel/plugin-proposal-private-methods": "^7.10.1", + "@babel/plugin-proposal-unicode-property-regex": "^7.10.1", + "@babel/plugin-syntax-async-generators": "^7.8.0", + "@babel/plugin-syntax-class-properties": "^7.10.1", + "@babel/plugin-syntax-dynamic-import": "^7.8.0", + "@babel/plugin-syntax-json-strings": "^7.8.0", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0", + "@babel/plugin-syntax-numeric-separator": "^7.10.1", + "@babel/plugin-syntax-object-rest-spread": "^7.8.0", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.0", + "@babel/plugin-syntax-optional-chaining": "^7.8.0", + "@babel/plugin-syntax-top-level-await": "^7.10.1", + "@babel/plugin-transform-arrow-functions": "^7.10.1", + "@babel/plugin-transform-async-to-generator": "^7.10.1", + "@babel/plugin-transform-block-scoped-functions": "^7.10.1", + "@babel/plugin-transform-block-scoping": "^7.10.1", + "@babel/plugin-transform-classes": "^7.10.3", + "@babel/plugin-transform-computed-properties": "^7.10.3", + "@babel/plugin-transform-destructuring": "^7.10.1", + "@babel/plugin-transform-dotall-regex": "^7.10.1", + "@babel/plugin-transform-duplicate-keys": "^7.10.1", + "@babel/plugin-transform-exponentiation-operator": "^7.10.1", + "@babel/plugin-transform-for-of": "^7.10.1", + "@babel/plugin-transform-function-name": "^7.10.1", + "@babel/plugin-transform-literals": "^7.10.1", + "@babel/plugin-transform-member-expression-literals": "^7.10.1", + "@babel/plugin-transform-modules-amd": "^7.10.1", + "@babel/plugin-transform-modules-commonjs": "^7.10.1", + "@babel/plugin-transform-modules-systemjs": "^7.10.3", + "@babel/plugin-transform-modules-umd": "^7.10.1", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.10.3", + "@babel/plugin-transform-new-target": "^7.10.1", + "@babel/plugin-transform-object-super": "^7.10.1", + "@babel/plugin-transform-parameters": "^7.10.1", + "@babel/plugin-transform-property-literals": "^7.10.1", + "@babel/plugin-transform-regenerator": "^7.10.3", + "@babel/plugin-transform-reserved-words": "^7.10.1", + "@babel/plugin-transform-shorthand-properties": "^7.10.1", + "@babel/plugin-transform-spread": "^7.10.1", + "@babel/plugin-transform-sticky-regex": "^7.10.1", + "@babel/plugin-transform-template-literals": "^7.10.3", + "@babel/plugin-transform-typeof-symbol": "^7.10.1", + "@babel/plugin-transform-unicode-escapes": "^7.10.1", + "@babel/plugin-transform-unicode-regex": "^7.10.1", + "@babel/preset-modules": "^0.1.3", + "@babel/types": "^7.10.3", + "browserslist": "^4.12.0", + "core-js-compat": "^3.6.2", + "invariant": "^2.2.2", + "levenary": "^1.1.1", + "semver": "^5.5.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/helper-compilation-targets": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.15.4.tgz", + "integrity": "sha512-rMWPCirulnPSe4d+gwdWXLfAXTTBj8M3guAf5xFQJ0nvFY7tfNAFnWdqaHegHlgDZOCT4qvhF3BYlSJag8yhqQ==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.15.0", + "@babel/helper-validator-option": "^7.14.5", + "browserslist": "^4.16.6", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/helper-compilation-targets/node_modules/semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-async-generator-functions": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.15.4.tgz", + "integrity": "sha512-2zt2g5vTXpMC3OmK6uyjvdXptbhBXfA77XGrd3gh93zwG8lZYBLOBImiGBEG0RANu3JqKEACCz5CGk73OJROBw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-remap-async-to-generator": "^7.15.4", + "@babel/plugin-syntax-async-generators": "^7.8.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-class-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.14.5.tgz", + "integrity": "sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-class-properties/node_modules/@babel/helper-create-class-features-plugin": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.15.4.tgz", + "integrity": "sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-dynamic-import": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.14.5.tgz", + "integrity": "sha512-ExjiNYc3HDN5PXJx+bwC50GIx/KKanX2HiggnIUAYedbARdImiCU4RhhHfdf0Kd7JNXGpsBBBCOm+bBVy3Gb0g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-dynamic-import": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-json-strings": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.14.5.tgz", + "integrity": "sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-json-strings": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-nullish-coalescing-operator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.14.5.tgz", + "integrity": "sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-numeric-separator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.14.5.tgz", + "integrity": "sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-numeric-separator": "^7.10.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-object-rest-spread": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.15.6.tgz", + "integrity": "sha512-qtOHo7A1Vt+O23qEAX+GdBpqaIuD3i9VRrWgCJeq7WO6H2d14EK3q11urj5Te2MAeK97nMiIdRpwd/ST4JFbNg==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.15.0", + "@babel/helper-compilation-targets": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-transform-parameters": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-optional-catch-binding": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.14.5.tgz", + "integrity": "sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-optional-chaining": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.14.5.tgz", + "integrity": "sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.14.5", + "@babel/plugin-syntax-optional-chaining": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-private-methods": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.14.5.tgz", + "integrity": "sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-private-methods/node_modules/@babel/helper-create-class-features-plugin": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.15.4.tgz", + "integrity": "sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-unicode-property-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.14.5.tgz", + "integrity": "sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-unicode-property-regex/node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-dynamic-import": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", + "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-arrow-functions": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.14.5.tgz", + "integrity": "sha512-KOnO0l4+tD5IfOdi4x8C1XmEIRWUjNRV8wc6K2vz/3e8yAOoZZvsRXRRIF/yo/MAOFb4QjtAw9xSxMXbSMRy8A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-async-to-generator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.14.5.tgz", + "integrity": "sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-remap-async-to-generator": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-block-scoped-functions": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.14.5.tgz", + "integrity": "sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-block-scoping": { + "version": "7.15.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.15.3.tgz", + "integrity": "sha512-nBAzfZwZb4DkaGtOes1Up1nOAp9TDRRFw4XBzBBSG9QK7KVFmYzgj9o9sbPv7TX5ofL4Auq4wZnxCoPnI/lz2Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-classes": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.15.4.tgz", + "integrity": "sha512-Yjvhex8GzBmmPQUvpXRPWQ9WnxXgAFuZSrqOK/eJlOGIXwvv8H3UEdUigl1gb/bnjTrln+e8bkZUYCBt/xYlBg==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-computed-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.14.5.tgz", + "integrity": "sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-destructuring": { + "version": "7.14.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.14.7.tgz", + "integrity": "sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-dotall-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.14.5.tgz", + "integrity": "sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-dotall-regex/node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-duplicate-keys": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.14.5.tgz", + "integrity": "sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-exponentiation-operator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.14.5.tgz", + "integrity": "sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA==", + "dev": true, + "dependencies": { + "@babel/helper-builder-binary-assignment-operator-visitor": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-for-of": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.15.4.tgz", + "integrity": "sha512-DRTY9fA751AFBDh2oxydvVm4SYevs5ILTWLs6xKXps4Re/KG5nfUkr+TdHCrRWB8C69TlzVgA9b3RmGWmgN9LA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-function-name": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.14.5.tgz", + "integrity": "sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ==", + "dev": true, + "dependencies": { + "@babel/helper-function-name": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.14.5.tgz", + "integrity": "sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-member-expression-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.14.5.tgz", + "integrity": "sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-modules-amd": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.14.5.tgz", + "integrity": "sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-modules-commonjs": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.15.4.tgz", + "integrity": "sha512-qg4DPhwG8hKp4BbVDvX1s8cohM8a6Bvptu4l6Iingq5rW+yRUAhe/YRup/YcW2zCOlrysEWVhftIcKzrEZv3sA==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-simple-access": "^7.15.4", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-modules-systemjs": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.15.4.tgz", + "integrity": "sha512-fJUnlQrl/mezMneR72CKCgtOoahqGJNVKpompKwzv3BrEXdlPspTcyxrZ1XmDTIr9PpULrgEQo3qNKp6dW7ssw==", + "dev": true, + "dependencies": { + "@babel/helper-hoist-variables": "^7.15.4", + "@babel/helper-module-transforms": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-validator-identifier": "^7.14.9", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-modules-umd": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.14.5.tgz", + "integrity": "sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.14.9", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.14.9.tgz", + "integrity": "sha512-l666wCVYO75mlAtGFfyFwnWmIXQm3kSH0C3IRnJqWcZbWkoihyAdDhFm2ZWaxWTqvBvhVFfJjMRQ0ez4oN1yYA==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-named-capturing-groups-regex/node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-new-target": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.14.5.tgz", + "integrity": "sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-object-super": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.14.5.tgz", + "integrity": "sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-replace-supers": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-parameters": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.15.4.tgz", + "integrity": "sha512-9WB/GUTO6lvJU3XQsSr6J/WKvBC2hcs4Pew8YxZagi6GkTdniyqp8On5kqdK8MN0LMeu0mGbhPN+O049NV/9FQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-property-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.14.5.tgz", + "integrity": "sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-regenerator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.14.5.tgz", + "integrity": "sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg==", + "dev": true, + "dependencies": { + "regenerator-transform": "^0.14.2" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-reserved-words": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.14.5.tgz", + "integrity": "sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-shorthand-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.14.5.tgz", + "integrity": "sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-spread": { + "version": "7.14.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.14.6.tgz", + "integrity": "sha512-Zr0x0YroFJku7n7+/HH3A2eIrGMjbmAIbJSVv0IZ+t3U2WUQUA64S/oeied2e+MaGSjmt4alzBCsK9E8gh+fag==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-sticky-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.14.5.tgz", + "integrity": "sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-template-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.14.5.tgz", + "integrity": "sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-typeof-symbol": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.14.5.tgz", + "integrity": "sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-unicode-escapes": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.14.5.tgz", + "integrity": "sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-unicode-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.14.5.tgz", + "integrity": "sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env/node_modules/@babel/plugin-transform-unicode-regex/node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-modules": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", + "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", + "@babel/plugin-transform-dotall-regex": "^7.4.4", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/runtime": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.15.4.tgz", + "integrity": "sha512-99catp6bHCaxr4sJ/DbTGgHS4+Rs2RVd2g7iOap6SLGPDknRK9ztKNsE/Fg6QhSeh1FGE5f6gHGQmvvn3I3xhw==", + "dev": true, + "dependencies": { + "regenerator-runtime": "^0.13.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/template": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.15.4.tgz", + "integrity": "sha512-UgBAfEa1oGuYgDIPM2G+aHa4Nlo9Lh6mGD2bDBGMTbYnc38vulXPuC1MGjYILIEmlwl6Rd+BPR9ee3gm20CBtg==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.14.5", + "@babel/parser": "^7.15.4", + "@babel/types": "^7.15.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.15.4.tgz", + "integrity": "sha512-W6lQD8l4rUbQR/vYgSuCAE75ADyyQvOpFVsvPPdkhf6lATXAsQIG9YdtOcu8BB1dZ0LKu+Zo3c1wEcbKeuhdlA==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.14.5", + "@babel/generator": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-hoist-variables": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "@babel/parser": "^7.15.4", + "@babel/types": "^7.15.4", + "debug": "^4.1.0", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.15.6.tgz", + "integrity": "sha512-BPU+7QhqNjmWyDO0/vitH/CuhpV8ZmK1wpKva8nuyNF5MJfuRNWMc+hc14+u9xT93kvykMdncrJT19h74uB1Ig==", + "dev": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.14.9", + "to-fast-properties": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@types/node": { + "version": "13.9.3", + "resolved": "https://registry.npmjs.org/@types/node/-/node-13.9.3.tgz", + "integrity": "sha512-01s+ac4qerwd6RHD+mVbOEsraDHSgUaefQlEdBbUolnQFjKwCr7luvAlEwW1RFojh67u0z4OUTjPn9LEl4zIkA==", + "dev": true + }, + "node_modules/@types/resolve": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-0.0.8.tgz", + "integrity": "sha512-auApPaJf3NPfe18hSoJkp8EbZzer2ISk7o8mCC3M9he/a04+gbMF97NkpD2S8riMGvm4BMRI59/SZQSaLTKpsQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@ungap/create-content": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/create-content/-/create-content-0.2.0.tgz", + "integrity": "sha512-CvmX0Mr5PfFARDBbSef0B+SAqSeMKaHOG/twJi9nbPtp/MiNPgyBLqZndiyO3RXQ0RXy6TqwarvB6KWzTmc4MQ==" + }, + "node_modules/@ungap/custom-event": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@ungap/custom-event/-/custom-event-0.3.1.tgz", + "integrity": "sha512-6iFFSuCelNPovoqS53N6f2ohbILf5qqk1YPLgcs67rOTfUlkOJs7xWcX0ygk/iWEmCWkC38+bRNTzjM02eP8iw==" + }, + "node_modules/@ungap/essential-map": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@ungap/essential-map/-/essential-map-0.3.2.tgz", + "integrity": "sha512-3nKB3JV6GXjWfdRPvx1V8KQsyEtdYf9jmrpXu8U8G4RV4EzYWHcYVPHthiN+eYhtCXB7Qrzu+CPxHKPn8WBJ0Q==" + }, + "node_modules/@ungap/essential-weakset": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/@ungap/essential-weakset/-/essential-weakset-0.2.1.tgz", + "integrity": "sha512-h5HsksOZ7KDYqr+oMtAIR3ZQgaEbbSD6p4tVqaM1jCzWhbXkW6X6RpwfLQLqjfrRNTRqQtcwfsdwQMrpWbdp5A==" + }, + "node_modules/@ungap/import-node": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/import-node/-/import-node-0.2.0.tgz", + "integrity": "sha512-VuWVBAMRjoOc63n8Cc19brS7KlhYJ+57790LF+lVw60nMRemCrz1T6HnoNx74IEW3FS+TM+vveJ70C6NyTKODQ==" + }, + "node_modules/@ungap/is-array": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/is-array/-/is-array-0.2.0.tgz", + "integrity": "sha512-585x6xT7DmZDWzSog3ZEGJryN175zxPRQh8JvEqItlhOowGYU4xcv6qh/8623doCYI7vohJc/0R5OO2EqrV3+w==" + }, + "node_modules/@ungap/template-literal": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@ungap/template-literal/-/template-literal-0.6.0.tgz", + "integrity": "sha512-J8+vZofH0TWM8M0ZU8qN/3fl6ct5mrB82+OSLSYXYZI0abi8a0FYPC65YViU1D2gRHdHQ7zXSv+LJiTM212rDw==", + "dependencies": { + "@ungap/weakmap": "^0.2.1" + } + }, + "node_modules/@ungap/template-tag-arguments": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@ungap/template-tag-arguments/-/template-tag-arguments-0.5.0.tgz", + "integrity": "sha512-hyvUZuGy60qOLdg95BjxgwehbJ4UoIG+sAj7yie9coxeK/qLIcwKXp8cn2Cwm3ouLB9UKL2v/+eq9oRUjuBPJg==", + "dependencies": { + "@ungap/template-literal": "^0.6.0" + } + }, + "node_modules/@ungap/trim": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/trim/-/trim-0.2.0.tgz", + "integrity": "sha512-CfsUxeZ2R/O3EGCOe+IkAU32yHOdO+mCRmtavSIQ4HZN3Jiq/ynGzq8/asyamd28U26UJmpSV/TC7+p7qELKrg==" + }, + "node_modules/@ungap/weakmap": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/@ungap/weakmap/-/weakmap-0.2.1.tgz", + "integrity": "sha512-GmVAWB+JuFKqSbzlofYK4qxk955gEv4Kd9/aj2hLOxneXMAm/J7OXcl5DlElS9tmkqwCcxGysSZGOrjzNvmjFQ==" + }, + "node_modules/@webreflection/interface": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/@webreflection/interface/-/interface-0.1.1.tgz", + "integrity": "sha1-ryqR2vOBeWVgcqb5Lp+SEWWPhWY=", + "dev": true + }, + "node_modules/abbrev": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz", + "integrity": "sha1-kbR5JYinc4wl813W9jdSovh3YTU=", + "dev": true + }, + "node_modules/amdefine": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", + "integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU=", + "dev": true, + "optional": true, + "engines": { + "node": ">=0.4.2" + } + }, + "node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/ascjs": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/ascjs/-/ascjs-4.0.1.tgz", + "integrity": "sha512-E/JuvSEe3EfuCZ52Ff142b8lwmuCrSCR+FaDPryIL2svqCiWmDCbzFCcOB+dfFeD2QHMS7zzQ+rWFw73ZUoZjA==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.9.6" + }, + "bin": { + "ascjs": "bin.js" + } + }, + "node_modules/async": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz", + "integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo=", + "dev": true + }, + "node_modules/babel-plugin-dynamic-import-node": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", + "integrity": "sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ==", + "dev": true, + "dependencies": { + "object.assign": "^4.1.0" + } + }, + "node_modules/balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "node_modules/basichtml": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/basichtml/-/basichtml-2.3.0.tgz", + "integrity": "sha512-4OwuvFO4Lbcm+DquFlYMiEIvsrJtMNtEeG41k6swojGmQsfPnlunNuk6/xwUKYbyfXgAxiYFhJv3xT7FeQwh4A==", + "deprecated": "The effort has moved into LinkeDOM module: https://www.npmjs.com/package/linkedom", + "dev": true, + "dependencies": { + "@webreflection/interface": "^0.1.1", + "broadcast": "^3.0.0", + "html-escaper": "^3.0.0", + "htmlparser2": "^4.1.0" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/broadcast": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/broadcast/-/broadcast-3.0.0.tgz", + "integrity": "sha512-q//26zihgUvAtvSBRD1xtk/9KBVNfiUrS8Phz8dN95Y5mqINO/gFT6181b4Yvhoeal3Aa9+rsFnKzA6a6UTHfg==", + "dev": true + }, + "node_modules/browserslist": { + "version": "4.17.0", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.17.0.tgz", + "integrity": "sha512-g2BJ2a0nEYvEFQC208q8mVAhfNwpZ5Mu8BwgtCdZKO3qx98HChmeg448fPdUzld8aFmfLgVh7yymqV+q1lJZ5g==", + "dev": true, + "dependencies": { + "caniuse-lite": "^1.0.30001254", + "colorette": "^1.3.0", + "electron-to-chromium": "^1.3.830", + "escalade": "^3.1.1", + "node-releases": "^1.1.75" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + } + }, + "node_modules/builtin-modules": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.1.0.tgz", + "integrity": "sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001257", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001257.tgz", + "integrity": "sha512-JN49KplOgHSXpIsVSF+LUyhD8PUp6xPpAXeRrrcBh4KBeP7W864jHn6RvzJgDlrReyeVjMFJL3PLpPvKIxlIHA==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + } + }, + "node_modules/chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "node_modules/colorette": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", + "integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==", + "dev": true + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "node_modules/consolemd": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/consolemd/-/consolemd-0.1.3.tgz", + "integrity": "sha512-UHKTgtvAtikE0UIvqP9Rj0b+rZ5AHIvbfL+GSjYhH2UOJWfnoIJ0+zygI/l/7cOB8p9JrGrIkC1BgQXBNzEQQA==", + "dev": true, + "dependencies": { + "echomd": "^0.1.2" + } + }, + "node_modules/convert-source-map": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", + "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.1" + } + }, + "node_modules/core-js-compat": { + "version": "3.6.4", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.6.4.tgz", + "integrity": "sha512-zAa3IZPvsJ0slViBQ2z+vgyyTuhd3MFn1rBQjZSKVEgB0UMYhUkCj9jJUVPgGTGqWvsBVmfnruXgTcNyTlEiSA==", + "dev": true, + "dependencies": { + "browserslist": "^4.8.3", + "semver": "7.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-js-compat/node_modules/semver": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.0.0.tgz", + "integrity": "sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "deprecated": "Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/deep-is": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", + "dev": true + }, + "node_modules/define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "dependencies": { + "object-keys": "^1.0.12" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/disconnected": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/disconnected/-/disconnected-0.2.1.tgz", + "integrity": "sha512-483TUpj4dA7Ye42xrErztbw3PKpkboPf1aB9mG4+S+RGGxFVv72hQBbS8MqN8LZLWHzfcmk2tMTRR5CoyxNglg==" + }, + "node_modules/dom-serializer": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.2.2.tgz", + "integrity": "sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "entities": "^2.0.0" + } + }, + "node_modules/domconstants": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/domconstants/-/domconstants-0.1.1.tgz", + "integrity": "sha512-Pk4K6tLOzSh0cZDuh7TQivZtYLC6Z8dNissoDyy2tQoVNg8ewScxG3AVJO76kLcTta/u7bgEO6xbIR97MiInfA==" + }, + "node_modules/domdiff": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/domdiff/-/domdiff-2.2.2.tgz", + "integrity": "sha512-Pv7aH5JfjNIkLRKkah+T3Kd41Gy+7GU+5dmPsOZZXsCJ34QR1i7CCiWraUn1c/a40htShxAQ8mHJR2OqPd12+Q==", + "dependencies": { + "uarray": "^1.0.0" + } + }, + "node_modules/domelementtype": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.0.1.tgz", + "integrity": "sha512-5HOHUDsYZWV8FGWN0Njbr/Rn7f/eWSQi1v7+HsUVwXgn8nWWlL64zKDkS0n8ZmQ3mlWOMuXOnR+7Nx/5tMO5AQ==", + "dev": true + }, + "node_modules/domhandler": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-3.0.0.tgz", + "integrity": "sha512-eKLdI5v9m67kbXQbJSNn1zjh0SDzvzWVWtX+qEI3eMjZw8daH9k8rlj1FZY9memPwjiskQFbe7vHVVJIAqoEhw==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1" + }, + "engines": { + "node": ">= 4" + } + }, + "node_modules/domsanitizer": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/domsanitizer/-/domsanitizer-0.2.2.tgz", + "integrity": "sha512-2nqCaLWi+tpT7oOa862BVrG7bHzYlWFZ5ltmvt4LXECxe5FnwF/zKGs/gWanZWGmv1pwdUTkO9TamoZMqI0Pmg==", + "dependencies": { + "domconstants": "^0.1.1" + } + }, + "node_modules/domtagger": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/domtagger/-/domtagger-0.7.0.tgz", + "integrity": "sha512-ljf2FYn4DPbMP2RN2YD8VsuW1Rm5N7x3iV0QRmlu5JqoY6Zn/gcwI8j4NV91YOlmqIHzONA+TEFOWQ4oX89G4Q==", + "dependencies": { + "@ungap/create-content": "^0.2.0", + "@ungap/import-node": "^0.2.0", + "@ungap/trim": "^0.2.0", + "@ungap/weakmap": "^0.2.1", + "domconstants": "^0.1.1", + "domsanitizer": "^0.2.2", + "umap": "^1.0.2" + } + }, + "node_modules/domutils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.0.0.tgz", + "integrity": "sha512-n5SelJ1axbO636c2yUtOGia/IcJtVtlhQbFiVDBZHKV5ReJO1ViX7sFEemtuyoAnBxk5meNSYgA8V4s0271efg==", + "dev": true, + "dependencies": { + "dom-serializer": "^0.2.1", + "domelementtype": "^2.0.1", + "domhandler": "^3.0.0" + } + }, + "node_modules/drop-babel-typeof": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/drop-babel-typeof/-/drop-babel-typeof-1.0.3.tgz", + "integrity": "sha512-nmhRIvZrHSzEv8sc6kqh+2pG7ZAg9ZRjFyY4YavbIzvF/6SYdsH4SDFJAYLWTAh1XoVfdbe3Kmy44h/KB7gv+Q==", + "dev": true, + "bin": { + "drop-babel-typeof": "index.js" + } + }, + "node_modules/echomd": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/echomd/-/echomd-0.1.2.tgz", + "integrity": "sha1-kNPPD55Fkwb0wdkKArZelxkj9v8=", + "dev": true, + "bin": { + "echomd": "js/echomd" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.3.838", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.838.tgz", + "integrity": "sha512-65O6UJiyohFAdX/nc6KJ0xG/4zOn7XCO03kQNNbCeMRGxlWTLzc6Uyi0tFNQuuGWqySZJi8CD2KXPXySVYmzMA==", + "dev": true + }, + "node_modules/entities": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.0.0.tgz", + "integrity": "sha512-D9f7V0JSRwIxlRI2mjMqufDrRDnx8p+eEOz7aUM9SuvF8gsBzra0/6tbjl1m8eQHrZlYj6PxqE00hZ1SAIKPLw==", + "dev": true + }, + "node_modules/escalade": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/escodegen": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.8.1.tgz", + "integrity": "sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg=", + "dev": true, + "dependencies": { + "esprima": "^2.7.1", + "estraverse": "^1.9.1", + "esutils": "^2.0.2", + "optionator": "^0.8.1" + }, + "bin": { + "escodegen": "bin/escodegen.js", + "esgenerate": "bin/esgenerate.js" + }, + "engines": { + "node": ">=0.12.0" + }, + "optionalDependencies": { + "source-map": "~0.2.0" + } + }, + "node_modules/escodegen/node_modules/esprima": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", + "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/escodegen/node_modules/source-map": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.2.0.tgz", + "integrity": "sha1-2rc/vPwrqBm03gO9b26qSBZLP50=", + "dev": true, + "optional": true, + "dependencies": { + "amdefine": ">=0.0.4" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/estraverse": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-1.9.3.tgz", + "integrity": "sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/estree-walker": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-0.6.1.tgz", + "integrity": "sha512-SqmZANLWS0mnatqbSfRP5g8OXZC12Fgg1IwNtLsyHDzJizORW4khDfjPqJZsemPWBB2uqykUah5YpQ6epsqC/w==", + "dev": true + }, + "node_modules/esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", + "dev": true + }, + "node_modules/fsevents": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", + "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", + "deprecated": "\"Please update to latest v2.3 or v2.2\"", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "node_modules/gensync": { + "version": "1.0.0-beta.1", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz", + "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-intrinsic": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", + "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/glob": { + "version": "5.0.15", + "resolved": "https://registry.npmjs.org/glob/-/glob-5.0.15.tgz", + "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=", + "dev": true, + "dependencies": { + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "2 || 3", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + } + }, + "node_modules/globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/handlebars": { + "version": "4.7.7", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.7.tgz", + "integrity": "sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==", + "dev": true, + "dependencies": { + "minimist": "^1.2.5", + "neo-async": "^2.6.0", + "source-map": "^0.6.1", + "wordwrap": "^1.0.0" + }, + "bin": { + "handlebars": "bin/handlebars" + }, + "engines": { + "node": ">=0.4.7" + }, + "optionalDependencies": { + "uglify-js": "^3.1.4" + } + }, + "node_modules/handlebars/node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/has-symbols": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", + "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/html-escaper": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-3.0.3.tgz", + "integrity": "sha512-RuMffC89BOWQoY0WKGpIhn5gX3iI54O6nRA0yC124NYVtzjmFWBIiFd8M0x+ZdX0P9R4lADg1mgP8C7PxGOWuQ==", + "dev": true + }, + "node_modules/htmlparser2": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-4.1.0.tgz", + "integrity": "sha512-4zDq1a1zhE4gQso/c5LP1OtrhYTncXNSpvJYtWJBtXAETPlMfi3IFNjGuQbYLuVY4ZR0QMqRVvo4Pdy9KLyP8Q==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^3.0.0", + "domutils": "^2.0.0", + "entities": "^2.0.0" + } + }, + "node_modules/hyperhtml-style": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/hyperhtml-style/-/hyperhtml-style-0.1.2.tgz", + "integrity": "sha512-ZDRYNClEaqUS0a8RAED0nQRqWmZk7ctdyij3Iw/PqUUef6xhYO87nx9vJNuxg7Yc6J2FdJjXRKbB0iud2ZyzwQ==" + }, + "node_modules/hyperhtml-wire": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/hyperhtml-wire/-/hyperhtml-wire-2.1.1.tgz", + "integrity": "sha512-6rOTnb+BSWIsNaqiji01BdV8qyhwyCT38aGmG5k37JQeI9n+lwgvFsq0/G7wNAh5NuGdAaWUl1umbjrW7fj++w==" + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "node_modules/invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "dev": true, + "dependencies": { + "loose-envify": "^1.0.0" + } + }, + "node_modules/is-module": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-module/-/is-module-1.0.0.tgz", + "integrity": "sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE=", + "dev": true + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "node_modules/istanbul": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/istanbul/-/istanbul-0.4.5.tgz", + "integrity": "sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs=", + "deprecated": "This module is no longer maintained, try this instead:\n npm i nyc\nVisit https://istanbul.js.org/integrations for other alternatives.", + "dev": true, + "dependencies": { + "abbrev": "1.0.x", + "async": "1.x", + "escodegen": "1.8.x", + "esprima": "2.7.x", + "glob": "^5.0.15", + "handlebars": "^4.0.1", + "js-yaml": "3.x", + "mkdirp": "0.5.x", + "nopt": "3.x", + "once": "1.x", + "resolve": "1.1.x", + "supports-color": "^3.1.0", + "which": "^1.1.1", + "wordwrap": "^1.0.0" + }, + "bin": { + "istanbul": "lib/cli.js" + } + }, + "node_modules/istanbul/node_modules/esprima": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", + "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/istanbul/node_modules/has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/istanbul/node_modules/resolve": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", + "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=", + "dev": true + }, + "node_modules/istanbul/node_modules/supports-color": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", + "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", + "dev": true, + "dependencies": { + "has-flag": "^1.0.0" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "node_modules/js-yaml": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", + "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/json5": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.1.2.tgz", + "integrity": "sha512-MoUOQ4WdiN3yxhm7NEVJSJrieAo5hNSLQ5sj05OTRHPL9HOBy8u4Bu88jsC1jvqAdN+E1bJmsUcZH+1HQxliqQ==", + "dev": true, + "dependencies": { + "minimist": "^1.2.5" + }, + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/levenary": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/levenary/-/levenary-1.1.1.tgz", + "integrity": "sha512-mkAdOIt79FD6irqjYSs4rdbnlT5vRonMEvBVPVb3XmevfS8kgRXwfes0dhPdEtzTWD/1eNE/Bm/G1iRt6DcnQQ==", + "dev": true, + "dependencies": { + "leven": "^3.1.0" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "dev": true, + "dependencies": { + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, + "node_modules/loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "dev": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "node_modules/minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", + "dev": true + }, + "node_modules/mkdirp": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.3.tgz", + "integrity": "sha512-P+2gwrFqx8lhew375MQHHeTlY8AuOJSrGf0R5ddkEndUkmwpgUob/vQuBD1V22/Cw1/lJr4x+EjllSezBThzBg==", + "deprecated": "Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)", + "dev": true, + "dependencies": { + "minimist": "^1.2.5" + }, + "bin": { + "mkdirp": "bin/cmd.js" + } + }, + "node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/neo-async": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz", + "integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==", + "dev": true + }, + "node_modules/node-releases": { + "version": "1.1.75", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.75.tgz", + "integrity": "sha512-Qe5OUajvqrqDSy6wrWFmMwfJ0jVgwiw4T3KqmbTcZ62qW0gQkheXYhcFM1+lOVcGUoRxcEcfyvFMAnDgaF1VWw==", + "dev": true + }, + "node_modules/nopt": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz", + "integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=", + "dev": true, + "dependencies": { + "abbrev": "1" + }, + "bin": { + "nopt": "bin/nopt.js" + } + }, + "node_modules/npm-dollar": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/npm-dollar/-/npm-dollar-2.2.1.tgz", + "integrity": "sha512-14pKEYwVWmrbGs8XtPKesSMF9okTy+aRniI1fjwyMoJIVc4wsawCRrR2i8AAubxfNBP1I2lesue5xT6cEm6sMQ==", + "dev": true, + "bin": { + "npm-dollar": "index.js" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.2.tgz", + "integrity": "sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.0", + "define-properties": "^1.1.3", + "has-symbols": "^1.0.1", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/optionator": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", + "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "dev": true, + "dependencies": { + "deep-is": "~0.1.3", + "fast-levenshtein": "~2.0.6", + "levn": "~0.3.0", + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2", + "word-wrap": "~1.2.3" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "node_modules/prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/regenerate": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.0.tgz", + "integrity": "sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg==", + "dev": true + }, + "node_modules/regenerate-unicode-properties": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz", + "integrity": "sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA==", + "dev": true, + "dependencies": { + "regenerate": "^1.4.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regenerator-runtime": { + "version": "0.13.9", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz", + "integrity": "sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==", + "dev": true + }, + "node_modules/regenerator-transform": { + "version": "0.14.5", + "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.5.tgz", + "integrity": "sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.8.4" + } + }, + "node_modules/regexpu-core": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-4.7.1.tgz", + "integrity": "sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ==", + "dev": true, + "dependencies": { + "regenerate": "^1.4.0", + "regenerate-unicode-properties": "^8.2.0", + "regjsgen": "^0.5.1", + "regjsparser": "^0.6.4", + "unicode-match-property-ecmascript": "^1.0.4", + "unicode-match-property-value-ecmascript": "^1.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regjsgen": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/regjsgen/-/regjsgen-0.5.1.tgz", + "integrity": "sha512-5qxzGZjDs9w4tzT3TPhCJqWdCc3RLYwy9J2NB0nm5Lz+S273lvWcpjaTGHsT1dc6Hhfq41uSEOw8wBmxrKOuyg==", + "dev": true + }, + "node_modules/regjsparser": { + "version": "0.6.4", + "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.6.4.tgz", + "integrity": "sha512-64O87/dPDgfk8/RQqC4gkZoGyyWFIEUTTh80CU6CWuK5vkCGyekIx+oKcEIYtP/RAxSQltCZHCNu/mdd7fqlJw==", + "dev": true, + "dependencies": { + "jsesc": "~0.5.0" + }, + "bin": { + "regjsparser": "bin/parser" + } + }, + "node_modules/regjsparser/node_modules/jsesc": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", + "integrity": "sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0=", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + } + }, + "node_modules/resolve": { + "version": "1.15.1", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.15.1.tgz", + "integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==", + "dev": true, + "dependencies": { + "path-parse": "^1.0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/rollup": { + "version": "2.18.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.18.1.tgz", + "integrity": "sha512-w4X77ADA+WTGlapC8Z6yggdJtODw3SBl6R2LSkA7ZW5MtdkgcB7sfaSD1UWyx8diXbMcGIb0eI9gCx/dyqOgNQ==", + "dev": true, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=10.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.1.2" + } + }, + "node_modules/rollup-plugin-babel": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/rollup-plugin-babel/-/rollup-plugin-babel-4.4.0.tgz", + "integrity": "sha512-Lek/TYp1+7g7I+uMfJnnSJ7YWoD58ajo6Oarhlex7lvUce+RCKRuGRSgztDO3/MF/PuGKmUL5iTHKf208UNszw==", + "deprecated": "This package has been deprecated and is no longer maintained. Please use @rollup/plugin-babel.", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.0.0", + "rollup-pluginutils": "^2.8.1" + }, + "peerDependencies": { + "@babel/core": "7 || ^7.0.0-rc.2", + "rollup": ">=0.60.0 <3" + } + }, + "node_modules/rollup-plugin-node-resolve": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/rollup-plugin-node-resolve/-/rollup-plugin-node-resolve-5.2.0.tgz", + "integrity": "sha512-jUlyaDXts7TW2CqQ4GaO5VJ4PwwaV8VUGA7+km3n6k6xtOEacf61u0VXwN80phY/evMcaS+9eIeJ9MOyDxt5Zw==", + "deprecated": "This package has been deprecated and is no longer maintained. Please use @rollup/plugin-node-resolve.", + "dev": true, + "dependencies": { + "@types/resolve": "0.0.8", + "builtin-modules": "^3.1.0", + "is-module": "^1.0.0", + "resolve": "^1.11.1", + "rollup-pluginutils": "^2.8.1" + }, + "peerDependencies": { + "rollup": ">=1.11.0" + } + }, + "node_modules/rollup-pluginutils": { + "version": "2.8.2", + "resolved": "https://registry.npmjs.org/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz", + "integrity": "sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ==", + "dev": true, + "dependencies": { + "estree-walker": "^0.6.1" + } + }, + "node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "dev": true, + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/tressa": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/tressa/-/tressa-0.3.1.tgz", + "integrity": "sha1-OhdV5a7cQ0+tmntp0EGrztdJatI=", + "dev": true, + "dependencies": { + "consolemd": "^0.1.2" + } + }, + "node_modules/type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "dev": true, + "dependencies": { + "prelude-ls": "~1.1.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/uarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/uarray/-/uarray-1.0.0.tgz", + "integrity": "sha512-LHmiAd5QuAv7pU2vbh+Zq9YOnqVK0H764p2Ozinpfy9ka58OID4IsGLiXsitqH7n0NAIDxvax1A/kDXpii/Ckg==" + }, + "node_modules/uglify-js": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.10.0.tgz", + "integrity": "sha512-Esj5HG5WAyrLIdYU74Z3JdG2PxdIusvj6IWHMtlyESxc7kcDz7zYlYjpnSokn1UbpV0d/QX9fan7gkCNd/9BQA==", + "dev": true, + "bin": { + "uglifyjs": "bin/uglifyjs" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/umap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/umap/-/umap-1.0.2.tgz", + "integrity": "sha512-bW127HgG4H4VAD6qlqO5vCC+7bnlYvZ6A6BdwyGblkWvlEG7VYpj1bcpf3iJpvyKmkPZWDIeZDmoULz67ec7NA==" + }, + "node_modules/unicode-canonical-property-names-ecmascript": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", + "integrity": "sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-ecmascript": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz", + "integrity": "sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg==", + "dev": true, + "dependencies": { + "unicode-canonical-property-names-ecmascript": "^1.0.4", + "unicode-property-aliases-ecmascript": "^1.0.4" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-value-ecmascript": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz", + "integrity": "sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-property-aliases-ecmascript": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz", + "integrity": "sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "which": "bin/which" + } + }, + "node_modules/word-wrap": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", + "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=", + "dev": true + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + } + }, + "dependencies": { + "@babel/code-frame": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.14.5.tgz", + "integrity": "sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw==", + "dev": true, + "requires": { + "@babel/highlight": "^7.14.5" + } + }, + "@babel/compat-data": { + "version": "7.15.0", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.15.0.tgz", + "integrity": "sha512-0NqAC1IJE0S0+lL1SWFMxMkz1pKCNCjI4tr2Zx4LJSXxCLAdr6KyArnY+sno5m3yH9g737ygOyPABDsnXkpxiA==", + "dev": true + }, + "@babel/core": { + "version": "7.10.3", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.10.3.tgz", + "integrity": "sha512-5YqWxYE3pyhIi84L84YcwjeEgS+fa7ZjK6IBVGTjDVfm64njkR2lfDhVR5OudLk8x2GK59YoSyVv+L/03k1q9w==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.10.3", + "@babel/generator": "^7.10.3", + "@babel/helper-module-transforms": "^7.10.1", + "@babel/helpers": "^7.10.1", + "@babel/parser": "^7.10.3", + "@babel/template": "^7.10.3", + "@babel/traverse": "^7.10.3", + "@babel/types": "^7.10.3", + "convert-source-map": "^1.7.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.1", + "json5": "^2.1.2", + "lodash": "^4.17.13", + "resolve": "^1.3.2", + "semver": "^5.4.1", + "source-map": "^0.5.0" + } + }, + "@babel/generator": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.15.4.tgz", + "integrity": "sha512-d3itta0tu+UayjEORPNz6e1T3FtvWlP5N4V5M+lhp/CxT4oAA7/NcScnpRyspUMLK6tu9MNHmQHxRykuN2R7hw==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4", + "jsesc": "^2.5.1", + "source-map": "^0.5.0" + } + }, + "@babel/helper-annotate-as-pure": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.15.4.tgz", + "integrity": "sha512-QwrtdNvUNsPCj2lfNQacsGSQvGX8ee1ttrBrcozUP2Sv/jylewBP/8QFe6ZkBsC8T/GYWonNAWJV4aRR9AL2DA==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-builder-binary-assignment-operator-visitor": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.15.4.tgz", + "integrity": "sha512-P8o7JP2Mzi0SdC6eWr1zF+AEYvrsZa7GSY1lTayjF5XJhVH0kjLYUZPvTMflP7tBgZoe9gIhTa60QwFpqh/E0Q==", + "dev": true, + "requires": { + "@babel/helper-explode-assignable-expression": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-create-regexp-features-plugin": { + "version": "7.8.8", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.8.8.tgz", + "integrity": "sha512-LYVPdwkrQEiX9+1R29Ld/wTrmQu1SSKYnuOk3g0CkcZMA1p0gsNxJFj/3gBdaJ7Cg0Fnek5z0DsMULePP7Lrqg==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.8.3", + "@babel/helper-regex": "^7.8.3", + "regexpu-core": "^4.7.0" + } + }, + "@babel/helper-explode-assignable-expression": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.15.4.tgz", + "integrity": "sha512-J14f/vq8+hdC2KoWLIQSsGrC9EFBKE4NFts8pfMpymfApds+fPqR30AOUWc4tyr56h9l/GA1Sxv2q3dLZWbQ/g==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-function-name": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.15.4.tgz", + "integrity": "sha512-Z91cOMM4DseLIGOnog+Z8OI6YseR9bua+HpvLAQ2XayUGU+neTtX+97caALaLdyu53I/fjhbeCnWnRH1O3jFOw==", + "dev": true, + "requires": { + "@babel/helper-get-function-arity": "^7.15.4", + "@babel/template": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-get-function-arity": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.15.4.tgz", + "integrity": "sha512-1/AlxSF92CmGZzHnC515hm4SirTxtpDnLEJ0UyEMgTMZN+6bxXKg04dKhiRx5Enel+SUA1G1t5Ed/yQia0efrA==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-hoist-variables": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.15.4.tgz", + "integrity": "sha512-VTy085egb3jUGVK9ycIxQiPbquesq0HUQ+tPO0uv5mPEBZipk+5FkRKiWq5apuyTE9FUrjENB0rCf8y+n+UuhA==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-member-expression-to-functions": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.15.4.tgz", + "integrity": "sha512-cokOMkxC/BTyNP1AlY25HuBWM32iCEsLPI4BHDpJCHHm1FU2E7dKWWIXJgQgSFiu4lp8q3bL1BIKwqkSUviqtA==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-module-imports": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.15.4.tgz", + "integrity": "sha512-jeAHZbzUwdW/xHgHQ3QmWR4Jg6j15q4w/gCfwZvtqOxoo5DKtLHk8Bsf4c5RZRC7NmLEs+ohkdq8jFefuvIxAA==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-module-transforms": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.15.4.tgz", + "integrity": "sha512-9fHHSGE9zTC++KuXLZcB5FKgvlV83Ox+NLUmQTawovwlJ85+QMhk1CnVk406CQVj97LaWod6KVjl2Sfgw9Aktw==", + "dev": true, + "requires": { + "@babel/helper-module-imports": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-simple-access": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "@babel/helper-validator-identifier": "^7.14.9", + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-optimise-call-expression": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.15.4.tgz", + "integrity": "sha512-E/z9rfbAOt1vDW1DR7k4SzhzotVV5+qMciWV6LaG1g4jeFrkDlJedjtV4h0i4Q/ITnUu+Pk08M7fczsB9GXBDw==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-plugin-utils": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz", + "integrity": "sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ==", + "dev": true + }, + "@babel/helper-regex": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.8.3.tgz", + "integrity": "sha512-BWt0QtYv/cg/NecOAZMdcn/waj/5P26DR4mVLXfFtDokSR6fyuG0Pj+e2FqtSME+MqED1khnSMulkmGl8qWiUQ==", + "dev": true, + "requires": { + "lodash": "^4.17.13" + } + }, + "@babel/helper-remap-async-to-generator": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.15.4.tgz", + "integrity": "sha512-v53MxgvMK/HCwckJ1bZrq6dNKlmwlyRNYM6ypaRTdXWGOE2c1/SCa6dL/HimhPulGhZKw9W0QhREM583F/t0vQ==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-wrap-function": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-replace-supers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.15.4.tgz", + "integrity": "sha512-/ztT6khaXF37MS47fufrKvIsiQkx1LBRvSJNzRqmbyeZnTwU9qBxXYLaaT/6KaxfKhjs2Wy8kG8ZdsFUuWBjzw==", + "dev": true, + "requires": { + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-simple-access": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.15.4.tgz", + "integrity": "sha512-UzazrDoIVOZZcTeHHEPYrr1MvTR/K+wgLg6MY6e1CJyaRhbibftF6fR2KU2sFRtI/nERUZR9fBd6aKgBlIBaPg==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.15.4.tgz", + "integrity": "sha512-BMRLsdh+D1/aap19TycS4eD1qELGrCBJwzaY9IE8LrpJtJb+H7rQkPIdsfgnMtLBA6DJls7X9z93Z4U8h7xw0A==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-split-export-declaration": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.15.4.tgz", + "integrity": "sha512-HsFqhLDZ08DxCpBdEVtKmywj6PQbwnF6HHybur0MAnkAKnlS6uHkwnmRIkElB2Owpfb4xL4NwDmDLFubueDXsw==", + "dev": true, + "requires": { + "@babel/types": "^7.15.4" + } + }, + "@babel/helper-validator-identifier": { + "version": "7.14.9", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.9.tgz", + "integrity": "sha512-pQYxPY0UP6IHISRitNe8bsijHex4TWZXi2HwKVsjPiltzlhse2znVcm9Ace510VT1kxIHjGJCZZQBX2gJDbo0g==", + "dev": true + }, + "@babel/helper-validator-option": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.14.5.tgz", + "integrity": "sha512-OX8D5eeX4XwcroVW45NMvoYaIuFI+GQpA2a8Gi+X/U/cDUIRsV37qQfF905F0htTRCREQIB4KqPeaveRJUl3Ow==", + "dev": true + }, + "@babel/helper-wrap-function": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.15.4.tgz", + "integrity": "sha512-Y2o+H/hRV5W8QhIfTpRIBwl57y8PrZt6JM3V8FOo5qarjshHItyH5lXlpMfBfmBefOqSCpKZs/6Dxqp0E/U+uw==", + "dev": true, + "requires": { + "@babel/helper-function-name": "^7.15.4", + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/helpers": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.15.4.tgz", + "integrity": "sha512-V45u6dqEJ3w2rlryYYXf6i9rQ5YMNu4FLS6ngs8ikblhu2VdR1AqAd6aJjBzmf2Qzh6KOLqKHxEN9+TFbAkAVQ==", + "dev": true, + "requires": { + "@babel/template": "^7.15.4", + "@babel/traverse": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/highlight": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.14.5.tgz", + "integrity": "sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg==", + "dev": true, + "requires": { + "@babel/helper-validator-identifier": "^7.14.5", + "chalk": "^2.0.0", + "js-tokens": "^4.0.0" + } + }, + "@babel/parser": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.15.6.tgz", + "integrity": "sha512-S/TSCcsRuCkmpUuoWijua0Snt+f3ewU/8spLo+4AXJCZfT0bVCzLD5MuOKdrx0mlAptbKzn5AdgEIIKXxXkz9Q==", + "dev": true + }, + "@babel/plugin-proposal-unicode-property-regex": { + "version": "7.8.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.8.8.tgz", + "integrity": "sha512-EVhjVsMpbhLw9ZfHWSx2iy13Q8Z/eg8e8ccVWt23sWQK5l1UdkoLJPN5w69UA4uITGBnEZD2JOe4QOHycYKv8A==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.8.8", + "@babel/helper-plugin-utils": "^7.8.3" + } + }, + "@babel/plugin-transform-dotall-regex": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.8.3.tgz", + "integrity": "sha512-kLs1j9Nn4MQoBYdRXH6AeaXMbEJFaFu/v1nQkvib6QzTj8MZI5OQzqmD83/2jEM1z0DLilra5aWO5YpyC0ALIw==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.8.3", + "@babel/helper-plugin-utils": "^7.8.3" + } + }, + "@babel/preset-env": { + "version": "7.10.3", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.10.3.tgz", + "integrity": "sha512-jHaSUgiewTmly88bJtMHbOd1bJf2ocYxb5BWKSDQIP5tmgFuS/n0gl+nhSrYDhT33m0vPxp+rP8oYYgPgMNQlg==", + "dev": true, + "requires": { + "@babel/compat-data": "^7.10.3", + "@babel/helper-compilation-targets": "^7.10.2", + "@babel/helper-module-imports": "^7.10.3", + "@babel/helper-plugin-utils": "^7.10.3", + "@babel/plugin-proposal-async-generator-functions": "^7.10.3", + "@babel/plugin-proposal-class-properties": "^7.10.1", + "@babel/plugin-proposal-dynamic-import": "^7.10.1", + "@babel/plugin-proposal-json-strings": "^7.10.1", + "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.1", + "@babel/plugin-proposal-numeric-separator": "^7.10.1", + "@babel/plugin-proposal-object-rest-spread": "^7.10.3", + "@babel/plugin-proposal-optional-catch-binding": "^7.10.1", + "@babel/plugin-proposal-optional-chaining": "^7.10.3", + "@babel/plugin-proposal-private-methods": "^7.10.1", + "@babel/plugin-proposal-unicode-property-regex": "^7.10.1", + "@babel/plugin-syntax-async-generators": "^7.8.0", + "@babel/plugin-syntax-class-properties": "^7.10.1", + "@babel/plugin-syntax-dynamic-import": "^7.8.0", + "@babel/plugin-syntax-json-strings": "^7.8.0", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0", + "@babel/plugin-syntax-numeric-separator": "^7.10.1", + "@babel/plugin-syntax-object-rest-spread": "^7.8.0", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.0", + "@babel/plugin-syntax-optional-chaining": "^7.8.0", + "@babel/plugin-syntax-top-level-await": "^7.10.1", + "@babel/plugin-transform-arrow-functions": "^7.10.1", + "@babel/plugin-transform-async-to-generator": "^7.10.1", + "@babel/plugin-transform-block-scoped-functions": "^7.10.1", + "@babel/plugin-transform-block-scoping": "^7.10.1", + "@babel/plugin-transform-classes": "^7.10.3", + "@babel/plugin-transform-computed-properties": "^7.10.3", + "@babel/plugin-transform-destructuring": "^7.10.1", + "@babel/plugin-transform-dotall-regex": "^7.10.1", + "@babel/plugin-transform-duplicate-keys": "^7.10.1", + "@babel/plugin-transform-exponentiation-operator": "^7.10.1", + "@babel/plugin-transform-for-of": "^7.10.1", + "@babel/plugin-transform-function-name": "^7.10.1", + "@babel/plugin-transform-literals": "^7.10.1", + "@babel/plugin-transform-member-expression-literals": "^7.10.1", + "@babel/plugin-transform-modules-amd": "^7.10.1", + "@babel/plugin-transform-modules-commonjs": "^7.10.1", + "@babel/plugin-transform-modules-systemjs": "^7.10.3", + "@babel/plugin-transform-modules-umd": "^7.10.1", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.10.3", + "@babel/plugin-transform-new-target": "^7.10.1", + "@babel/plugin-transform-object-super": "^7.10.1", + "@babel/plugin-transform-parameters": "^7.10.1", + "@babel/plugin-transform-property-literals": "^7.10.1", + "@babel/plugin-transform-regenerator": "^7.10.3", + "@babel/plugin-transform-reserved-words": "^7.10.1", + "@babel/plugin-transform-shorthand-properties": "^7.10.1", + "@babel/plugin-transform-spread": "^7.10.1", + "@babel/plugin-transform-sticky-regex": "^7.10.1", + "@babel/plugin-transform-template-literals": "^7.10.3", + "@babel/plugin-transform-typeof-symbol": "^7.10.1", + "@babel/plugin-transform-unicode-escapes": "^7.10.1", + "@babel/plugin-transform-unicode-regex": "^7.10.1", + "@babel/preset-modules": "^0.1.3", + "@babel/types": "^7.10.3", + "browserslist": "^4.12.0", + "core-js-compat": "^3.6.2", + "invariant": "^2.2.2", + "levenary": "^1.1.1", + "semver": "^5.5.0" + }, + "dependencies": { + "@babel/helper-compilation-targets": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.15.4.tgz", + "integrity": "sha512-rMWPCirulnPSe4d+gwdWXLfAXTTBj8M3guAf5xFQJ0nvFY7tfNAFnWdqaHegHlgDZOCT4qvhF3BYlSJag8yhqQ==", + "dev": true, + "requires": { + "@babel/compat-data": "^7.15.0", + "@babel/helper-validator-option": "^7.14.5", + "browserslist": "^4.16.6", + "semver": "^6.3.0" + }, + "dependencies": { + "semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true + } + } + }, + "@babel/plugin-proposal-async-generator-functions": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.15.4.tgz", + "integrity": "sha512-2zt2g5vTXpMC3OmK6uyjvdXptbhBXfA77XGrd3gh93zwG8lZYBLOBImiGBEG0RANu3JqKEACCz5CGk73OJROBw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-remap-async-to-generator": "^7.15.4", + "@babel/plugin-syntax-async-generators": "^7.8.4" + } + }, + "@babel/plugin-proposal-class-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.14.5.tgz", + "integrity": "sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg==", + "dev": true, + "requires": { + "@babel/helper-create-class-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-class-features-plugin": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.15.4.tgz", + "integrity": "sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4" + } + } + } + }, + "@babel/plugin-proposal-dynamic-import": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.14.5.tgz", + "integrity": "sha512-ExjiNYc3HDN5PXJx+bwC50GIx/KKanX2HiggnIUAYedbARdImiCU4RhhHfdf0Kd7JNXGpsBBBCOm+bBVy3Gb0g==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-dynamic-import": "^7.8.3" + } + }, + "@babel/plugin-proposal-json-strings": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.14.5.tgz", + "integrity": "sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-json-strings": "^7.8.3" + } + }, + "@babel/plugin-proposal-nullish-coalescing-operator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.14.5.tgz", + "integrity": "sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3" + } + }, + "@babel/plugin-proposal-numeric-separator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.14.5.tgz", + "integrity": "sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-numeric-separator": "^7.10.4" + } + }, + "@babel/plugin-proposal-object-rest-spread": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.15.6.tgz", + "integrity": "sha512-qtOHo7A1Vt+O23qEAX+GdBpqaIuD3i9VRrWgCJeq7WO6H2d14EK3q11urj5Te2MAeK97nMiIdRpwd/ST4JFbNg==", + "dev": true, + "requires": { + "@babel/compat-data": "^7.15.0", + "@babel/helper-compilation-targets": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-transform-parameters": "^7.15.4" + } + }, + "@babel/plugin-proposal-optional-catch-binding": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.14.5.tgz", + "integrity": "sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3" + } + }, + "@babel/plugin-proposal-optional-chaining": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.14.5.tgz", + "integrity": "sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.14.5", + "@babel/plugin-syntax-optional-chaining": "^7.8.3" + } + }, + "@babel/plugin-proposal-private-methods": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.14.5.tgz", + "integrity": "sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g==", + "dev": true, + "requires": { + "@babel/helper-create-class-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-class-features-plugin": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.15.4.tgz", + "integrity": "sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-member-expression-to-functions": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4" + } + } + } + }, + "@babel/plugin-proposal-unicode-property-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.14.5.tgz", + "integrity": "sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + } + } + } + }, + "@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.12.13" + } + }, + "@babel/plugin-syntax-dynamic-import": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", + "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-arrow-functions": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.14.5.tgz", + "integrity": "sha512-KOnO0l4+tD5IfOdi4x8C1XmEIRWUjNRV8wc6K2vz/3e8yAOoZZvsRXRRIF/yo/MAOFb4QjtAw9xSxMXbSMRy8A==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-async-to-generator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.14.5.tgz", + "integrity": "sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA==", + "dev": true, + "requires": { + "@babel/helper-module-imports": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-remap-async-to-generator": "^7.14.5" + } + }, + "@babel/plugin-transform-block-scoped-functions": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.14.5.tgz", + "integrity": "sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-block-scoping": { + "version": "7.15.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.15.3.tgz", + "integrity": "sha512-nBAzfZwZb4DkaGtOes1Up1nOAp9TDRRFw4XBzBBSG9QK7KVFmYzgj9o9sbPv7TX5ofL4Auq4wZnxCoPnI/lz2Q==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-classes": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.15.4.tgz", + "integrity": "sha512-Yjvhex8GzBmmPQUvpXRPWQ9WnxXgAFuZSrqOK/eJlOGIXwvv8H3UEdUigl1gb/bnjTrln+e8bkZUYCBt/xYlBg==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-optimise-call-expression": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-replace-supers": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "globals": "^11.1.0" + } + }, + "@babel/plugin-transform-computed-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.14.5.tgz", + "integrity": "sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-destructuring": { + "version": "7.14.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.14.7.tgz", + "integrity": "sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-dotall-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.14.5.tgz", + "integrity": "sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + } + } + } + }, + "@babel/plugin-transform-duplicate-keys": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.14.5.tgz", + "integrity": "sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-exponentiation-operator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.14.5.tgz", + "integrity": "sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA==", + "dev": true, + "requires": { + "@babel/helper-builder-binary-assignment-operator-visitor": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-for-of": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.15.4.tgz", + "integrity": "sha512-DRTY9fA751AFBDh2oxydvVm4SYevs5ILTWLs6xKXps4Re/KG5nfUkr+TdHCrRWB8C69TlzVgA9b3RmGWmgN9LA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-function-name": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.14.5.tgz", + "integrity": "sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ==", + "dev": true, + "requires": { + "@babel/helper-function-name": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.14.5.tgz", + "integrity": "sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-member-expression-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.14.5.tgz", + "integrity": "sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-modules-amd": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.14.5.tgz", + "integrity": "sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g==", + "dev": true, + "requires": { + "@babel/helper-module-transforms": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-commonjs": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.15.4.tgz", + "integrity": "sha512-qg4DPhwG8hKp4BbVDvX1s8cohM8a6Bvptu4l6Iingq5rW+yRUAhe/YRup/YcW2zCOlrysEWVhftIcKzrEZv3sA==", + "dev": true, + "requires": { + "@babel/helper-module-transforms": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-simple-access": "^7.15.4", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-systemjs": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.15.4.tgz", + "integrity": "sha512-fJUnlQrl/mezMneR72CKCgtOoahqGJNVKpompKwzv3BrEXdlPspTcyxrZ1XmDTIr9PpULrgEQo3qNKp6dW7ssw==", + "dev": true, + "requires": { + "@babel/helper-hoist-variables": "^7.15.4", + "@babel/helper-module-transforms": "^7.15.4", + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-validator-identifier": "^7.14.9", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-umd": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.14.5.tgz", + "integrity": "sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA==", + "dev": true, + "requires": { + "@babel/helper-module-transforms": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.14.9", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.14.9.tgz", + "integrity": "sha512-l666wCVYO75mlAtGFfyFwnWmIXQm3kSH0C3IRnJqWcZbWkoihyAdDhFm2ZWaxWTqvBvhVFfJjMRQ0ez4oN1yYA==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + } + } + } + }, + "@babel/plugin-transform-new-target": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.14.5.tgz", + "integrity": "sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-object-super": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.14.5.tgz", + "integrity": "sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-replace-supers": "^7.14.5" + } + }, + "@babel/plugin-transform-parameters": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.15.4.tgz", + "integrity": "sha512-9WB/GUTO6lvJU3XQsSr6J/WKvBC2hcs4Pew8YxZagi6GkTdniyqp8On5kqdK8MN0LMeu0mGbhPN+O049NV/9FQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-property-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.14.5.tgz", + "integrity": "sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-regenerator": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.14.5.tgz", + "integrity": "sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg==", + "dev": true, + "requires": { + "regenerator-transform": "^0.14.2" + } + }, + "@babel/plugin-transform-reserved-words": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.14.5.tgz", + "integrity": "sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-shorthand-properties": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.14.5.tgz", + "integrity": "sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-spread": { + "version": "7.14.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.14.6.tgz", + "integrity": "sha512-Zr0x0YroFJku7n7+/HH3A2eIrGMjbmAIbJSVv0IZ+t3U2WUQUA64S/oeied2e+MaGSjmt4alzBCsK9E8gh+fag==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.14.5" + } + }, + "@babel/plugin-transform-sticky-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.14.5.tgz", + "integrity": "sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-template-literals": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.14.5.tgz", + "integrity": "sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-typeof-symbol": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.14.5.tgz", + "integrity": "sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-unicode-escapes": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.14.5.tgz", + "integrity": "sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-transform-unicode-regex": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.14.5.tgz", + "integrity": "sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw==", + "dev": true, + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.14.5", + "@babel/helper-plugin-utils": "^7.14.5" + }, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz", + "integrity": "sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==", + "dev": true, + "requires": { + "@babel/helper-annotate-as-pure": "^7.14.5", + "regexpu-core": "^4.7.1" + } + } + } + } + } + }, + "@babel/preset-modules": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", + "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", + "@babel/plugin-transform-dotall-regex": "^7.4.4", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + } + }, + "@babel/runtime": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.15.4.tgz", + "integrity": "sha512-99catp6bHCaxr4sJ/DbTGgHS4+Rs2RVd2g7iOap6SLGPDknRK9ztKNsE/Fg6QhSeh1FGE5f6gHGQmvvn3I3xhw==", + "dev": true, + "requires": { + "regenerator-runtime": "^0.13.4" + } + }, + "@babel/template": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.15.4.tgz", + "integrity": "sha512-UgBAfEa1oGuYgDIPM2G+aHa4Nlo9Lh6mGD2bDBGMTbYnc38vulXPuC1MGjYILIEmlwl6Rd+BPR9ee3gm20CBtg==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.14.5", + "@babel/parser": "^7.15.4", + "@babel/types": "^7.15.4" + } + }, + "@babel/traverse": { + "version": "7.15.4", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.15.4.tgz", + "integrity": "sha512-W6lQD8l4rUbQR/vYgSuCAE75ADyyQvOpFVsvPPdkhf6lATXAsQIG9YdtOcu8BB1dZ0LKu+Zo3c1wEcbKeuhdlA==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.14.5", + "@babel/generator": "^7.15.4", + "@babel/helper-function-name": "^7.15.4", + "@babel/helper-hoist-variables": "^7.15.4", + "@babel/helper-split-export-declaration": "^7.15.4", + "@babel/parser": "^7.15.4", + "@babel/types": "^7.15.4", + "debug": "^4.1.0", + "globals": "^11.1.0" + } + }, + "@babel/types": { + "version": "7.15.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.15.6.tgz", + "integrity": "sha512-BPU+7QhqNjmWyDO0/vitH/CuhpV8ZmK1wpKva8nuyNF5MJfuRNWMc+hc14+u9xT93kvykMdncrJT19h74uB1Ig==", + "dev": true, + "requires": { + "@babel/helper-validator-identifier": "^7.14.9", + "to-fast-properties": "^2.0.0" + } + }, + "@types/node": { + "version": "13.9.3", + "resolved": "https://registry.npmjs.org/@types/node/-/node-13.9.3.tgz", + "integrity": "sha512-01s+ac4qerwd6RHD+mVbOEsraDHSgUaefQlEdBbUolnQFjKwCr7luvAlEwW1RFojh67u0z4OUTjPn9LEl4zIkA==", + "dev": true + }, + "@types/resolve": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-0.0.8.tgz", + "integrity": "sha512-auApPaJf3NPfe18hSoJkp8EbZzer2ISk7o8mCC3M9he/a04+gbMF97NkpD2S8riMGvm4BMRI59/SZQSaLTKpsQ==", + "dev": true, + "requires": { + "@types/node": "*" + } + }, + "@ungap/create-content": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/create-content/-/create-content-0.2.0.tgz", + "integrity": "sha512-CvmX0Mr5PfFARDBbSef0B+SAqSeMKaHOG/twJi9nbPtp/MiNPgyBLqZndiyO3RXQ0RXy6TqwarvB6KWzTmc4MQ==" + }, + "@ungap/custom-event": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@ungap/custom-event/-/custom-event-0.3.1.tgz", + "integrity": "sha512-6iFFSuCelNPovoqS53N6f2ohbILf5qqk1YPLgcs67rOTfUlkOJs7xWcX0ygk/iWEmCWkC38+bRNTzjM02eP8iw==" + }, + "@ungap/essential-map": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@ungap/essential-map/-/essential-map-0.3.2.tgz", + "integrity": "sha512-3nKB3JV6GXjWfdRPvx1V8KQsyEtdYf9jmrpXu8U8G4RV4EzYWHcYVPHthiN+eYhtCXB7Qrzu+CPxHKPn8WBJ0Q==" + }, + "@ungap/essential-weakset": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/@ungap/essential-weakset/-/essential-weakset-0.2.1.tgz", + "integrity": "sha512-h5HsksOZ7KDYqr+oMtAIR3ZQgaEbbSD6p4tVqaM1jCzWhbXkW6X6RpwfLQLqjfrRNTRqQtcwfsdwQMrpWbdp5A==" + }, + "@ungap/import-node": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/import-node/-/import-node-0.2.0.tgz", + "integrity": "sha512-VuWVBAMRjoOc63n8Cc19brS7KlhYJ+57790LF+lVw60nMRemCrz1T6HnoNx74IEW3FS+TM+vveJ70C6NyTKODQ==" + }, + "@ungap/is-array": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/is-array/-/is-array-0.2.0.tgz", + "integrity": "sha512-585x6xT7DmZDWzSog3ZEGJryN175zxPRQh8JvEqItlhOowGYU4xcv6qh/8623doCYI7vohJc/0R5OO2EqrV3+w==" + }, + "@ungap/template-literal": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@ungap/template-literal/-/template-literal-0.6.0.tgz", + "integrity": "sha512-J8+vZofH0TWM8M0ZU8qN/3fl6ct5mrB82+OSLSYXYZI0abi8a0FYPC65YViU1D2gRHdHQ7zXSv+LJiTM212rDw==", + "requires": { + "@ungap/weakmap": "^0.2.1" + } + }, + "@ungap/template-tag-arguments": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@ungap/template-tag-arguments/-/template-tag-arguments-0.5.0.tgz", + "integrity": "sha512-hyvUZuGy60qOLdg95BjxgwehbJ4UoIG+sAj7yie9coxeK/qLIcwKXp8cn2Cwm3ouLB9UKL2v/+eq9oRUjuBPJg==", + "requires": { + "@ungap/template-literal": "^0.6.0" + } + }, + "@ungap/trim": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@ungap/trim/-/trim-0.2.0.tgz", + "integrity": "sha512-CfsUxeZ2R/O3EGCOe+IkAU32yHOdO+mCRmtavSIQ4HZN3Jiq/ynGzq8/asyamd28U26UJmpSV/TC7+p7qELKrg==" + }, + "@ungap/weakmap": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/@ungap/weakmap/-/weakmap-0.2.1.tgz", + "integrity": "sha512-GmVAWB+JuFKqSbzlofYK4qxk955gEv4Kd9/aj2hLOxneXMAm/J7OXcl5DlElS9tmkqwCcxGysSZGOrjzNvmjFQ==" + }, + "@webreflection/interface": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/@webreflection/interface/-/interface-0.1.1.tgz", + "integrity": "sha1-ryqR2vOBeWVgcqb5Lp+SEWWPhWY=", + "dev": true + }, + "abbrev": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz", + "integrity": "sha1-kbR5JYinc4wl813W9jdSovh3YTU=", + "dev": true + }, + "amdefine": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", + "integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU=", + "dev": true, + "optional": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "ascjs": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/ascjs/-/ascjs-4.0.1.tgz", + "integrity": "sha512-E/JuvSEe3EfuCZ52Ff142b8lwmuCrSCR+FaDPryIL2svqCiWmDCbzFCcOB+dfFeD2QHMS7zzQ+rWFw73ZUoZjA==", + "dev": true, + "requires": { + "@babel/parser": "^7.9.6" + } + }, + "async": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz", + "integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo=", + "dev": true + }, + "babel-plugin-dynamic-import-node": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", + "integrity": "sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ==", + "dev": true, + "requires": { + "object.assign": "^4.1.0" + } + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "basichtml": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/basichtml/-/basichtml-2.3.0.tgz", + "integrity": "sha512-4OwuvFO4Lbcm+DquFlYMiEIvsrJtMNtEeG41k6swojGmQsfPnlunNuk6/xwUKYbyfXgAxiYFhJv3xT7FeQwh4A==", + "dev": true, + "requires": { + "@webreflection/interface": "^0.1.1", + "broadcast": "^3.0.0", + "html-escaper": "^3.0.0", + "htmlparser2": "^4.1.0" + } + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "broadcast": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/broadcast/-/broadcast-3.0.0.tgz", + "integrity": "sha512-q//26zihgUvAtvSBRD1xtk/9KBVNfiUrS8Phz8dN95Y5mqINO/gFT6181b4Yvhoeal3Aa9+rsFnKzA6a6UTHfg==", + "dev": true + }, + "browserslist": { + "version": "4.17.0", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.17.0.tgz", + "integrity": "sha512-g2BJ2a0nEYvEFQC208q8mVAhfNwpZ5Mu8BwgtCdZKO3qx98HChmeg448fPdUzld8aFmfLgVh7yymqV+q1lJZ5g==", + "dev": true, + "requires": { + "caniuse-lite": "^1.0.30001254", + "colorette": "^1.3.0", + "electron-to-chromium": "^1.3.830", + "escalade": "^3.1.1", + "node-releases": "^1.1.75" + } + }, + "builtin-modules": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.1.0.tgz", + "integrity": "sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw==", + "dev": true + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dev": true, + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, + "caniuse-lite": { + "version": "1.0.30001257", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001257.tgz", + "integrity": "sha512-JN49KplOgHSXpIsVSF+LUyhD8PUp6xPpAXeRrrcBh4KBeP7W864jHn6RvzJgDlrReyeVjMFJL3PLpPvKIxlIHA==", + "dev": true + }, + "chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "colorette": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", + "integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "consolemd": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/consolemd/-/consolemd-0.1.3.tgz", + "integrity": "sha512-UHKTgtvAtikE0UIvqP9Rj0b+rZ5AHIvbfL+GSjYhH2UOJWfnoIJ0+zygI/l/7cOB8p9JrGrIkC1BgQXBNzEQQA==", + "dev": true, + "requires": { + "echomd": "^0.1.2" + } + }, + "convert-source-map": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", + "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", + "dev": true, + "requires": { + "safe-buffer": "~5.1.1" + } + }, + "core-js-compat": { + "version": "3.6.4", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.6.4.tgz", + "integrity": "sha512-zAa3IZPvsJ0slViBQ2z+vgyyTuhd3MFn1rBQjZSKVEgB0UMYhUkCj9jJUVPgGTGqWvsBVmfnruXgTcNyTlEiSA==", + "dev": true, + "requires": { + "browserslist": "^4.8.3", + "semver": "7.0.0" + }, + "dependencies": { + "semver": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.0.0.tgz", + "integrity": "sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A==", + "dev": true + } + } + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "deep-is": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", + "dev": true + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "disconnected": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/disconnected/-/disconnected-0.2.1.tgz", + "integrity": "sha512-483TUpj4dA7Ye42xrErztbw3PKpkboPf1aB9mG4+S+RGGxFVv72hQBbS8MqN8LZLWHzfcmk2tMTRR5CoyxNglg==" + }, + "dom-serializer": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.2.2.tgz", + "integrity": "sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g==", + "dev": true, + "requires": { + "domelementtype": "^2.0.1", + "entities": "^2.0.0" + } + }, + "domconstants": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/domconstants/-/domconstants-0.1.1.tgz", + "integrity": "sha512-Pk4K6tLOzSh0cZDuh7TQivZtYLC6Z8dNissoDyy2tQoVNg8ewScxG3AVJO76kLcTta/u7bgEO6xbIR97MiInfA==" + }, + "domdiff": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/domdiff/-/domdiff-2.2.2.tgz", + "integrity": "sha512-Pv7aH5JfjNIkLRKkah+T3Kd41Gy+7GU+5dmPsOZZXsCJ34QR1i7CCiWraUn1c/a40htShxAQ8mHJR2OqPd12+Q==", + "requires": { + "uarray": "^1.0.0" + } + }, + "domelementtype": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.0.1.tgz", + "integrity": "sha512-5HOHUDsYZWV8FGWN0Njbr/Rn7f/eWSQi1v7+HsUVwXgn8nWWlL64zKDkS0n8ZmQ3mlWOMuXOnR+7Nx/5tMO5AQ==", + "dev": true + }, + "domhandler": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-3.0.0.tgz", + "integrity": "sha512-eKLdI5v9m67kbXQbJSNn1zjh0SDzvzWVWtX+qEI3eMjZw8daH9k8rlj1FZY9memPwjiskQFbe7vHVVJIAqoEhw==", + "dev": true, + "requires": { + "domelementtype": "^2.0.1" + } + }, + "domsanitizer": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/domsanitizer/-/domsanitizer-0.2.2.tgz", + "integrity": "sha512-2nqCaLWi+tpT7oOa862BVrG7bHzYlWFZ5ltmvt4LXECxe5FnwF/zKGs/gWanZWGmv1pwdUTkO9TamoZMqI0Pmg==", + "requires": { + "domconstants": "^0.1.1" + } + }, + "domtagger": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/domtagger/-/domtagger-0.7.0.tgz", + "integrity": "sha512-ljf2FYn4DPbMP2RN2YD8VsuW1Rm5N7x3iV0QRmlu5JqoY6Zn/gcwI8j4NV91YOlmqIHzONA+TEFOWQ4oX89G4Q==", + "requires": { + "@ungap/create-content": "^0.2.0", + "@ungap/import-node": "^0.2.0", + "@ungap/trim": "^0.2.0", + "@ungap/weakmap": "^0.2.1", + "domconstants": "^0.1.1", + "domsanitizer": "^0.2.2", + "umap": "^1.0.2" + } + }, + "domutils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.0.0.tgz", + "integrity": "sha512-n5SelJ1axbO636c2yUtOGia/IcJtVtlhQbFiVDBZHKV5ReJO1ViX7sFEemtuyoAnBxk5meNSYgA8V4s0271efg==", + "dev": true, + "requires": { + "dom-serializer": "^0.2.1", + "domelementtype": "^2.0.1", + "domhandler": "^3.0.0" + } + }, + "drop-babel-typeof": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/drop-babel-typeof/-/drop-babel-typeof-1.0.3.tgz", + "integrity": "sha512-nmhRIvZrHSzEv8sc6kqh+2pG7ZAg9ZRjFyY4YavbIzvF/6SYdsH4SDFJAYLWTAh1XoVfdbe3Kmy44h/KB7gv+Q==", + "dev": true + }, + "echomd": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/echomd/-/echomd-0.1.2.tgz", + "integrity": "sha1-kNPPD55Fkwb0wdkKArZelxkj9v8=", + "dev": true + }, + "electron-to-chromium": { + "version": "1.3.838", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.838.tgz", + "integrity": "sha512-65O6UJiyohFAdX/nc6KJ0xG/4zOn7XCO03kQNNbCeMRGxlWTLzc6Uyi0tFNQuuGWqySZJi8CD2KXPXySVYmzMA==", + "dev": true + }, + "entities": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.0.0.tgz", + "integrity": "sha512-D9f7V0JSRwIxlRI2mjMqufDrRDnx8p+eEOz7aUM9SuvF8gsBzra0/6tbjl1m8eQHrZlYj6PxqE00hZ1SAIKPLw==", + "dev": true + }, + "escalade": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "dev": true + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true + }, + "escodegen": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.8.1.tgz", + "integrity": "sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg=", + "dev": true, + "requires": { + "esprima": "^2.7.1", + "estraverse": "^1.9.1", + "esutils": "^2.0.2", + "optionator": "^0.8.1", + "source-map": "~0.2.0" + }, + "dependencies": { + "esprima": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", + "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", + "dev": true + }, + "source-map": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.2.0.tgz", + "integrity": "sha1-2rc/vPwrqBm03gO9b26qSBZLP50=", + "dev": true, + "optional": true, + "requires": { + "amdefine": ">=0.0.4" + } + } + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "estraverse": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-1.9.3.tgz", + "integrity": "sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q=", + "dev": true + }, + "estree-walker": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-0.6.1.tgz", + "integrity": "sha512-SqmZANLWS0mnatqbSfRP5g8OXZC12Fgg1IwNtLsyHDzJizORW4khDfjPqJZsemPWBB2uqykUah5YpQ6epsqC/w==", + "dev": true + }, + "esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true + }, + "fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", + "dev": true + }, + "fsevents": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", + "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "gensync": { + "version": "1.0.0-beta.1", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz", + "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg==", + "dev": true + }, + "get-intrinsic": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", + "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "dev": true, + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1" + } + }, + "glob": { + "version": "5.0.15", + "resolved": "https://registry.npmjs.org/glob/-/glob-5.0.15.tgz", + "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=", + "dev": true, + "requires": { + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "2 || 3", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "dev": true + }, + "handlebars": { + "version": "4.7.7", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.7.tgz", + "integrity": "sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==", + "dev": true, + "requires": { + "minimist": "^1.2.5", + "neo-async": "^2.6.0", + "source-map": "^0.6.1", + "uglify-js": "^3.1.4", + "wordwrap": "^1.0.0" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + } + } + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "dev": true + }, + "has-symbols": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", + "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", + "dev": true + }, + "html-escaper": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-3.0.3.tgz", + "integrity": "sha512-RuMffC89BOWQoY0WKGpIhn5gX3iI54O6nRA0yC124NYVtzjmFWBIiFd8M0x+ZdX0P9R4lADg1mgP8C7PxGOWuQ==", + "dev": true + }, + "htmlparser2": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-4.1.0.tgz", + "integrity": "sha512-4zDq1a1zhE4gQso/c5LP1OtrhYTncXNSpvJYtWJBtXAETPlMfi3IFNjGuQbYLuVY4ZR0QMqRVvo4Pdy9KLyP8Q==", + "dev": true, + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^3.0.0", + "domutils": "^2.0.0", + "entities": "^2.0.0" + } + }, + "hyperhtml-style": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/hyperhtml-style/-/hyperhtml-style-0.1.2.tgz", + "integrity": "sha512-ZDRYNClEaqUS0a8RAED0nQRqWmZk7ctdyij3Iw/PqUUef6xhYO87nx9vJNuxg7Yc6J2FdJjXRKbB0iud2ZyzwQ==" + }, + "hyperhtml-wire": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/hyperhtml-wire/-/hyperhtml-wire-2.1.1.tgz", + "integrity": "sha512-6rOTnb+BSWIsNaqiji01BdV8qyhwyCT38aGmG5k37JQeI9n+lwgvFsq0/G7wNAh5NuGdAaWUl1umbjrW7fj++w==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "dev": true, + "requires": { + "loose-envify": "^1.0.0" + } + }, + "is-module": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-module/-/is-module-1.0.0.tgz", + "integrity": "sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE=", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "istanbul": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/istanbul/-/istanbul-0.4.5.tgz", + "integrity": "sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs=", + "dev": true, + "requires": { + "abbrev": "1.0.x", + "async": "1.x", + "escodegen": "1.8.x", + "esprima": "2.7.x", + "glob": "^5.0.15", + "handlebars": "^4.0.1", + "js-yaml": "3.x", + "mkdirp": "0.5.x", + "nopt": "3.x", + "once": "1.x", + "resolve": "1.1.x", + "supports-color": "^3.1.0", + "which": "^1.1.1", + "wordwrap": "^1.0.0" + }, + "dependencies": { + "esprima": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", + "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", + "dev": true + }, + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true + }, + "resolve": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", + "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=", + "dev": true + }, + "supports-color": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", + "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", + "dev": true, + "requires": { + "has-flag": "^1.0.0" + } + } + } + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "js-yaml": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", + "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", + "dev": true + }, + "json5": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.1.2.tgz", + "integrity": "sha512-MoUOQ4WdiN3yxhm7NEVJSJrieAo5hNSLQ5sj05OTRHPL9HOBy8u4Bu88jsC1jvqAdN+E1bJmsUcZH+1HQxliqQ==", + "dev": true, + "requires": { + "minimist": "^1.2.5" + } + }, + "leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true + }, + "levenary": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/levenary/-/levenary-1.1.1.tgz", + "integrity": "sha512-mkAdOIt79FD6irqjYSs4rdbnlT5vRonMEvBVPVb3XmevfS8kgRXwfes0dhPdEtzTWD/1eNE/Bm/G1iRt6DcnQQ==", + "dev": true, + "requires": { + "leven": "^3.1.0" + } + }, + "levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "dev": true, + "requires": { + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, + "loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "dev": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", + "dev": true + }, + "mkdirp": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.3.tgz", + "integrity": "sha512-P+2gwrFqx8lhew375MQHHeTlY8AuOJSrGf0R5ddkEndUkmwpgUob/vQuBD1V22/Cw1/lJr4x+EjllSezBThzBg==", + "dev": true, + "requires": { + "minimist": "^1.2.5" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "neo-async": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz", + "integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==", + "dev": true + }, + "node-releases": { + "version": "1.1.75", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.75.tgz", + "integrity": "sha512-Qe5OUajvqrqDSy6wrWFmMwfJ0jVgwiw4T3KqmbTcZ62qW0gQkheXYhcFM1+lOVcGUoRxcEcfyvFMAnDgaF1VWw==", + "dev": true + }, + "nopt": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz", + "integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=", + "dev": true, + "requires": { + "abbrev": "1" + } + }, + "npm-dollar": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/npm-dollar/-/npm-dollar-2.2.1.tgz", + "integrity": "sha512-14pKEYwVWmrbGs8XtPKesSMF9okTy+aRniI1fjwyMoJIVc4wsawCRrR2i8AAubxfNBP1I2lesue5xT6cEm6sMQ==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.2.tgz", + "integrity": "sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ==", + "dev": true, + "requires": { + "call-bind": "^1.0.0", + "define-properties": "^1.1.3", + "has-symbols": "^1.0.1", + "object-keys": "^1.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "optionator": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", + "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "dev": true, + "requires": { + "deep-is": "~0.1.3", + "fast-levenshtein": "~2.0.6", + "levn": "~0.3.0", + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2", + "word-wrap": "~1.2.3" + } + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", + "dev": true + }, + "regenerate": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.0.tgz", + "integrity": "sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg==", + "dev": true + }, + "regenerate-unicode-properties": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz", + "integrity": "sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA==", + "dev": true, + "requires": { + "regenerate": "^1.4.0" + } + }, + "regenerator-runtime": { + "version": "0.13.9", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz", + "integrity": "sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==", + "dev": true + }, + "regenerator-transform": { + "version": "0.14.5", + "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.5.tgz", + "integrity": "sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw==", + "dev": true, + "requires": { + "@babel/runtime": "^7.8.4" + } + }, + "regexpu-core": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-4.7.1.tgz", + "integrity": "sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ==", + "dev": true, + "requires": { + "regenerate": "^1.4.0", + "regenerate-unicode-properties": "^8.2.0", + "regjsgen": "^0.5.1", + "regjsparser": "^0.6.4", + "unicode-match-property-ecmascript": "^1.0.4", + "unicode-match-property-value-ecmascript": "^1.2.0" + } + }, + "regjsgen": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/regjsgen/-/regjsgen-0.5.1.tgz", + "integrity": "sha512-5qxzGZjDs9w4tzT3TPhCJqWdCc3RLYwy9J2NB0nm5Lz+S273lvWcpjaTGHsT1dc6Hhfq41uSEOw8wBmxrKOuyg==", + "dev": true + }, + "regjsparser": { + "version": "0.6.4", + "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.6.4.tgz", + "integrity": "sha512-64O87/dPDgfk8/RQqC4gkZoGyyWFIEUTTh80CU6CWuK5vkCGyekIx+oKcEIYtP/RAxSQltCZHCNu/mdd7fqlJw==", + "dev": true, + "requires": { + "jsesc": "~0.5.0" + }, + "dependencies": { + "jsesc": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", + "integrity": "sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0=", + "dev": true + } + } + }, + "resolve": { + "version": "1.15.1", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.15.1.tgz", + "integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==", + "dev": true, + "requires": { + "path-parse": "^1.0.6" + } + }, + "rollup": { + "version": "2.18.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.18.1.tgz", + "integrity": "sha512-w4X77ADA+WTGlapC8Z6yggdJtODw3SBl6R2LSkA7ZW5MtdkgcB7sfaSD1UWyx8diXbMcGIb0eI9gCx/dyqOgNQ==", + "dev": true, + "requires": { + "fsevents": "~2.1.2" + } + }, + "rollup-plugin-babel": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/rollup-plugin-babel/-/rollup-plugin-babel-4.4.0.tgz", + "integrity": "sha512-Lek/TYp1+7g7I+uMfJnnSJ7YWoD58ajo6Oarhlex7lvUce+RCKRuGRSgztDO3/MF/PuGKmUL5iTHKf208UNszw==", + "dev": true, + "requires": { + "@babel/helper-module-imports": "^7.0.0", + "rollup-pluginutils": "^2.8.1" + } + }, + "rollup-plugin-node-resolve": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/rollup-plugin-node-resolve/-/rollup-plugin-node-resolve-5.2.0.tgz", + "integrity": "sha512-jUlyaDXts7TW2CqQ4GaO5VJ4PwwaV8VUGA7+km3n6k6xtOEacf61u0VXwN80phY/evMcaS+9eIeJ9MOyDxt5Zw==", + "dev": true, + "requires": { + "@types/resolve": "0.0.8", + "builtin-modules": "^3.1.0", + "is-module": "^1.0.0", + "resolve": "^1.11.1", + "rollup-pluginutils": "^2.8.1" + } + }, + "rollup-pluginutils": { + "version": "2.8.2", + "resolved": "https://registry.npmjs.org/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz", + "integrity": "sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ==", + "dev": true, + "requires": { + "estree-walker": "^0.6.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "dev": true + }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", + "dev": true + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + }, + "to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true + }, + "tressa": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/tressa/-/tressa-0.3.1.tgz", + "integrity": "sha1-OhdV5a7cQ0+tmntp0EGrztdJatI=", + "dev": true, + "requires": { + "consolemd": "^0.1.2" + } + }, + "type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "dev": true, + "requires": { + "prelude-ls": "~1.1.2" + } + }, + "uarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/uarray/-/uarray-1.0.0.tgz", + "integrity": "sha512-LHmiAd5QuAv7pU2vbh+Zq9YOnqVK0H764p2Ozinpfy9ka58OID4IsGLiXsitqH7n0NAIDxvax1A/kDXpii/Ckg==" + }, + "uglify-js": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.10.0.tgz", + "integrity": "sha512-Esj5HG5WAyrLIdYU74Z3JdG2PxdIusvj6IWHMtlyESxc7kcDz7zYlYjpnSokn1UbpV0d/QX9fan7gkCNd/9BQA==", + "dev": true + }, + "umap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/umap/-/umap-1.0.2.tgz", + "integrity": "sha512-bW127HgG4H4VAD6qlqO5vCC+7bnlYvZ6A6BdwyGblkWvlEG7VYpj1bcpf3iJpvyKmkPZWDIeZDmoULz67ec7NA==" + }, + "unicode-canonical-property-names-ecmascript": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", + "integrity": "sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ==", + "dev": true + }, + "unicode-match-property-ecmascript": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz", + "integrity": "sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg==", + "dev": true, + "requires": { + "unicode-canonical-property-names-ecmascript": "^1.0.4", + "unicode-property-aliases-ecmascript": "^1.0.4" + } + }, + "unicode-match-property-value-ecmascript": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz", + "integrity": "sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ==", + "dev": true + }, + "unicode-property-aliases-ecmascript": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz", + "integrity": "sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg==", + "dev": true + }, + "which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "word-wrap": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", + "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", + "dev": true + }, + "wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=", + "dev": true + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + } + } +} diff --git a/package.json b/package.json index 26451a40..1210de5e 100644 --- a/package.json +++ b/package.json @@ -1,13 +1,100 @@ { "name": "hyperhtml", - "version": "0.7.2", + "version": "2.34.2", "description": "A Fast & Light Virtual DOM Alternative", - "main": "hyperhtml.js", + "homepage": "https://viperhtml.js.org/hyper.html", + "unpkg": "min.js", + "main": "cjs/index.js", + "module": "esm/index.js", + "types": "index.d.ts", "scripts": { - "build": "npm run minify && npm test && npm run size", - "test": "node test/runner.js", - "minify": "uglifyjs hyperhtml.js --comments=/^!/ --compress --mangle -o min.js", - "size": "cat hyperhtml.js | wc -c;cat min.js | wc -c;gzip -c min.js | wc -c" + "$": "npm-dollar", + "build": "npm run $ build", + "bundle": "npm run $ bundle", + "test": "npm run $ test" + }, + "$": { + "bundle": { + "max": [ + "rollup --config rollup.config.js", + "$ clean.esm", + "drop-babel-typeof index.js" + ], + "min": [ + [ + "echo \"/*! (c) Andrea Giammarchi (ISC) */$(", + "uglifyjs index.js -c -m", + ")\" > min.js" + ] + ], + "ie": [ + [ + "rollup --config rollup.ie.js" + ] + ], + "umd": [ + [ + "echo \"(function(A,G){if(typeof define=='function'&&define.amd)define([],G);else", + "if(typeof module=='object'&&module.exports)module.exports=G();else", + "A.hyperHTML=G()}(typeof self!='undefined'?self:this,function(){\">umd.js;cat", + "min.js>>umd.js;echo \"return hyperHTML}));\">>umd.js" + ] + ], + "esm": [ + "cp min.js esm.js", + "echo 'export default hyperHTML;' >> esm.js", + "echo 'export const {Component, bind, define, diff, hyper, wire} = hyperHTML;' >> esm.js" + ] + }, + "build": [ + "$ cjs", + "$ clean.cjs index.js", + "$ clean.cjs classes/Component.js", + "$ clean.cjs hyper/render.js", + "$ clean.cjs objects/Updates.js", + "$ clean.cjs shared/utils.js", + "$ clean.cjs hyper/wire.js", + "$ bundle.max", + "$ bundle.min", + "$ bundle.umd", + "$ bundle.esm", + "$ bundle.ie", + "$ test", + "$ size" + ], + "clean": { + "cjs": "sed -i.bck 's/m.default : m/\\/* istanbul ignore next *\\/ m.default : \\/* istanbul ignore next *\\/ m/g' cjs/$1 && rm -f cjs/$1.bck", + "esm": [ + [ + "cat index.js |", + "sed 's/(exports)/(document)/' |", + "sed 's/return exports;/return hyper;/' |", + "sed -e 's/exports.*;//g' |", + "sed '/var createContent$1 =/,/(document);/d' |", + "sed 's/createContent$1/createContent/' |", + "sed 's/({})/(document)/' |", + "sed -e 's/var isNoOp =.*/var isNoOp = false;/' > index.clean" + ], + "mv index.clean index.js" + ] + }, + "cjs": [ + "ascjs ./esm ./cjs" + ], + "size": { + "gzip": [ + [ + "cat index.js |", + "wc -c;cat min.js |", + "wc -c;gzip -c9 min.js |", + "wc -c" + ] + ], + "brotli": "cat min.js | brotli | wc -c" + }, + "test": [ + "istanbul cover test/runner.js" + ] }, "repository": { "type": "git", @@ -15,20 +102,64 @@ }, "keywords": [ "dom", + "diff", + "performance", "template", + "literals", + "lightweight", "fast", - "performance", - "diff" + "react", + "virtual", + "lit-html", + "alternative" ], "author": "Andrea Giammarchi", - "license": "MIT", + "license": "ISC", "bugs": { "url": "https://github.com/WebReflection/hyperhtml/issues" }, - "homepage": "https://github.com/WebReflection/hyperhtml#readme", "devDependencies": { - "jsdom": "^9.11.0", - "tressa": "^0.3.1", - "uglify-js": "^2.8.5" + "@babel/core": "7.10.3", + "@babel/preset-env": "7.10.3", + "ascjs": "4.0.1", + "basichtml": "2.3.0", + "drop-babel-typeof": "1.0.3", + "istanbul": "0.4.5", + "npm-dollar": "2.2.1", + "rollup": "2.18.1", + "rollup-plugin-babel": "4.4.0", + "rollup-plugin-node-resolve": "5.2.0", + "tressa": "0.3.1", + "uglify-js": "3.10.0" + }, + "greenkeeper": { + "ignore": [ + "uglify-js", + "rollup", + "rollup-plugin-babel", + "rollup-plugin-node-resolve" + ] + }, + "dependencies": { + "@ungap/create-content": "0.2.0", + "@ungap/custom-event": "0.3.1", + "@ungap/essential-map": "0.3.2", + "@ungap/essential-weakset": "0.2.1", + "@ungap/is-array": "0.2.0", + "@ungap/template-tag-arguments": "0.5.0", + "@ungap/weakmap": "0.2.1", + "disconnected": "0.2.1", + "domdiff": "2.2.2", + "domtagger": "0.7.0", + "hyperhtml-style": "0.1.2", + "hyperhtml-wire": "2.1.1" + }, + "collective": { + "type": "opencollective", + "url": "https://opencollective.com/hyperhtml" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/hyperhtml" } } diff --git a/rollup.config.js b/rollup.config.js new file mode 100644 index 00000000..65f24dc2 --- /dev/null +++ b/rollup.config.js @@ -0,0 +1,18 @@ +import resolve from 'rollup-plugin-node-resolve'; +import babel from 'rollup-plugin-babel'; + +export default { + input: 'esm/index.js', + plugins: [ + resolve({module: true}), + babel({presets: ["@babel/preset-env"]}) + ], + context: 'null', + moduleContext: 'null', + output: { + exports: 'named', + file: 'index.js', + format: 'iife', + name: 'hyperHTML' + } +}; diff --git a/rollup.ie.js b/rollup.ie.js new file mode 100644 index 00000000..3f1c1a3f --- /dev/null +++ b/rollup.ie.js @@ -0,0 +1,16 @@ +import resolve from 'rollup-plugin-node-resolve'; +import babel from 'rollup-plugin-babel'; + +export default { + input: 'test/test.js', + plugins: [ + resolve({module: true}), + babel({presets: ["@babel/preset-env"]}) + ], + context: 'null', + moduleContext: 'null', + output: { + file: 'test/ie/test/test.js', + format: 'iife' + } +}; diff --git a/test/OpenExchangeRates.js b/test/OpenExchangeRates.js new file mode 100644 index 00000000..3a849c86 --- /dev/null +++ b/test/OpenExchangeRates.js @@ -0,0 +1,54 @@ +var OpenExchangeRates = function () { + /*! (c) Andrea Giammarchi */ + return function OpenExchangeRates(APP_ID) { + var cache = {}; + return { + format: (amount, currency) => + format(amount, currency), + clear: (base) => + delete cache[(base || 'USD').toUpperCase()], + convert: (amount, from, to) => + latest(from).then(info => + format(info.rates[to.toUpperCase()] * amount, to)), + currencies: () => + cache.currencies || (cache.currencies = new Promise((res, rej) => { + load(urlFor('currencies'), res, rej); + })), + latest: (base) => { + base = (base || 'USD').toUpperCase(); + return cache[base] || (cache[base] = new Promise((res, rej) => { + load(`${urlFor('latest')}&base=${base}`, res, rej); + })); + } + }; + function urlFor(key) { + return `https://openexchangerates.org/api/${key}.json?app_id=${APP_ID}`; + } + function latest(base) { + base = (base || 'USD').toUpperCase(); + return cache[base] || (cache[base] = new Promise((res, rej) => { + load(`${urlFor('latest')}&base=${base}`, res, rej); + })); + } + + }; + function format(amount, currency) { + return new Intl.NumberFormat('en-US', { + style: 'currency', + currency: currency, + minimumFractionDigits: 2, + maximumFractionDigits: 8 + }) + .format(amount) + .replace(/^NaN$/, '') + .replace(/^(\D+)/, '$1 ') + .replace('BTC', 'โ‚ฟ'); + } + function load(url, res, rej) { + var xhr = new XMLHttpRequest(); + xhr.open('get', url, true); + xhr.onload = () => res(JSON.parse(xhr.responseText)); + xhr.onerror = rej; + xhr.send(null); + } +}(); \ No newline at end of file diff --git a/test/abstracts.md b/test/abstracts.md new file mode 100644 index 00000000..58f976f4 --- /dev/null +++ b/test/abstracts.md @@ -0,0 +1,137 @@ +# Abstract + +The following content represents ideal steps +performed by hyperHTML to grant performance, +recycle everything it can, and update layouts. + +It's rather a specification than current implementation, +but the goal is to optimize such specification as much as possible +and achieve best performance on top of that. + + + +### Definitions + +`hyperHTML` is a function tag for template literals. + +Its unique `templateObject` argument is generated once +implicitly invoked as template literal function-tag. +http://www.ecma-international.org/ecma-262/6.0/#sec-gettemplateobject + +Its `context` MUST be a DOM Element. + +`hyperHTML.bind(context)` creates a new function-tag for such `context`. + +```js +const render = hyperHTML.bind(context); +render` + +`; +``` + +A list of `paths` is an array of instructions used to address a specific target node. +Each instruction also includes the kind of update operation to be performed on the target node. + +```js +// paths example +[ + {type: 'attr', path: ['children', 1, 'attributes', 2]}, + {type: 'text', path: ['children', 1, 'childNodes', 0]}, + {type: 'any', path: ['children', 5]}, + {type: 'virtual', path: ['children', 1, 'children', 3, 'childNodes', 2]} +] +``` + +Retrieving a node through a path can be done by reducing its values. + +Updates are similarly defined through the following procedure. + +```js +paths.forEach((info, i) => { + const target = info.path.reduce( + (node, accessor) => node[accessor], + fragment + ); + switch (info.type) { + case 'attr': updates[i] = setAttribute(target); break; + case 'any': updates[i] = setAnyContent(target); break; + case 'text': updates[i] = setText(target); break; + case 'virtual': updates[i] = setVirtualContent(target); break; + } +}); +``` + +The list of `updates` is an array containing functions in charge of updating each path through interpolations. +```js +// updates through interpolated values +interpolations.forEach((value, i) => updates[i](value)); +``` + + +### hyperHTML operations +``` +hyperHTML(templateObject, ...interpolations) +โ”‚ +โ””โ–ถ is current `context` known ? + โ”‚ + โ”œโ–ถ YES + โ”‚ + โ”‚ is current `context` representing `templateObject` ? + โ”‚ โ”‚ + โ”‚ โ”œโ–ถ YES โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” + โ”‚ โ”‚ โ–ผ โ”‚ + โ”‚ โ”‚ invoke `updates` through `interpolations` โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ return the current `context` โ”‚ + โ”‚ โ”‚ โ”‚ + โ””โ”€โ”€โ”€โ”ดโ–ถ NO โ”‚ + โ”‚ + is `templateObject` known ? โ”‚ + โ”‚ โ”‚ + โ”Œโ”€โ”€โ”€โ”ผโ–ถ YES โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ clone deeply the `templateObject` `fragment` โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ replace `context` content with the `fragment` โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ retrieve via `paths` the nodes to update โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ create a list of `updates` โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ relate `templateObject` to current `context` โ”‚ + โ”‚ โ”‚ โ”‚ + โ”‚ โ”‚ relate `updates` to current `context` โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ + โ”‚ โ”‚ + โ”‚ โ””โ–ถ NO + โ”‚ + โ”‚ create a `fragment` through `templateObject` + โ”‚ + โ”‚ create a list of `paths` to find out nodes + โ”‚ + โ”‚ relate `fragment` to current `templateObject` + โ”‚ + โ”‚ relate `paths` to current `templateObject` โ”€โ”€โ” + โ”‚ โ”‚ + โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ +``` + +### Weakly referenced + +``` +context + โ”œโ–ถ templateObject + โ””โ–ถ updates + +any + โ””โ–ถ wires +``` + +### Strongly referenced + +Template literals are _forever_, there's no reason to create extra GC pressure. + +``` +templateObject + โ”œโ–ถ fragment + โ””โ–ถ paths +``` diff --git a/test/adopt.html b/test/adopt.html new file mode 100644 index 00000000..373ec499 --- /dev/null +++ b/test/adopt.html @@ -0,0 +1,42 @@ + + + + + + +
before +
    +
  • lonely
  • +
NO
+
+ + + \ No newline at end of file diff --git a/test/adopt.js b/test/adopt.js new file mode 100644 index 00000000..fdb5ea5b --- /dev/null +++ b/test/adopt.js @@ -0,0 +1,37 @@ +var wrap = document.body.appendChild(document.createElement('div')); +wrap = document.createElement('div'); +wrap.innerHTML = '
before
  • lonely
NO
'; + +var div = wrap.firstElementChild; +var text = div.firstChild; +var ul = div.firstElementChild; +var hr = div.lastElementChild; +var render = hyperHTML.adopt(wrap); +var model = { + test: 'after', + text: 'after', + list: [ + {name: 'first'}, + {name: 'second'} + ], + inBetween: 'OK' +}; + +function update(render, model) { + render` +
+ ${model.text} +
    ${ + model.list.map(item => `
  • ${item.name}
  • `) + }
${ + model.inBetween + }
+
+ `; +} + +console.log('-----------------------------------------------------------------'); + +setTimeout(() => { + update(render, model); +}, 1000); \ No newline at end of file diff --git a/test/article.html b/test/article.html index 79dacba0..706a7f9f 100644 --- a/test/article.html +++ b/test/article.html @@ -13,26 +13,26 @@

${state.title}

List of ${state.paragraphs.length} paragraphs: -
    ${ - state.paragraphs - .map(p => `
  • ${p.title}
  • `) - }
+
    + ${state.paragraphs.map( + p => hyperHTML.wire(p)` +
  • ${p.title}
  • `)} +
`; } - var articleElement = document.querySelector('article'); - update( - hyperHTML.bind(articleElement), - { - title: 'True story', - magic: true, - paragraphs: [ - {title: 'touching'}, - {title: 'incredible'}, - {title: 'doge'} - ] - } - ); + const articleElement = document.querySelector('article'); + const state = { + title: 'True story', + magic: true, + paragraphs: [ + {title: 'touching'}, + {title: 'incredible'}, + {title: 'doge'} + ] + }; + const render = hyperHTML.bind(articleElement); + update(render, state); diff --git a/test/attributes.html b/test/attributes.html new file mode 100644 index 00000000..cdffc355 --- /dev/null +++ b/test/attributes.html @@ -0,0 +1,65 @@ + + + + Attributes Order + + + + + +

+ some content, also an input. + +

+ + diff --git a/test/basic.html b/test/basic.html new file mode 100644 index 00000000..5cb6b3c9 --- /dev/null +++ b/test/basic.html @@ -0,0 +1,19 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/test/boot-speed.html b/test/boot-speed.html index d3aeac19..6ae9e9cb 100644 --- a/test/boot-speed.html +++ b/test/boot-speed.html @@ -2,7 +2,7 @@ - + +
+
+ + + + \ No newline at end of file diff --git a/test/dist/double-rainbow.js b/test/dist/double-rainbow.js new file mode 100644 index 00000000..32832fef --- /dev/null +++ b/test/dist/double-rainbow.js @@ -0,0 +1,258 @@ +'use strict'; + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); + +var _createClass = 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; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _templateObject = _taggedTemplateLiteral(['\n
', '
\n # Points\n \n ', '\n \n
\n
\n Demo by Andrea Giammarchi,\n based on the Preact demo by Jason Miller,\n based on the Glimmer demo by Michael Lange.\n
\n
'], ['\n
', '
\n # Points\n \n ', '\n \n
\n
\n Demo by Andrea Giammarchi,\n based on the Preact demo by Jason Miller,\n based on the Glimmer demo by Michael Lange.\n
\n
']), + _templateObject2 = _taggedTemplateLiteral(['\n \n ', '\n '], ['\n \n ', '\n ']), + _templateObject3 = _taggedTemplateLiteral(['\n '], ['\n ']); + +function _taggedTemplateLiteral(strings, raw) { return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var Demo = function () { + function Demo(numPoints) { + _classCallCheck(this, Demo); + + this.numPoints = numPoints; + this.update = this.update.bind(this); + this.vd = new VizDemo(numPoints, false); + } + + _createClass(Demo, [{ + key: 'update', + value: function update(e) { + var prop = e.currentTarget.name; + this[prop] = e.currentTarget[prop === 'async' ? 'checked' : 'value']; + this.vd.update(+this.numPoints, this.async); + this.render(); + } + }, { + key: 'render', + value: function render() { + return hyperHTML.wire(this)(_templateObject, this.vd.render(), this.numPoints, this.update, this.numPoints, this.update); + } + }]); + + return Demo; +}(); + +var Layout = { + PHYLLOTAXIS: 0, + GRID: 1, + WAVE: 2, + SPIRAL: 3 +}; + +var LAYOUT_ORDER = [Layout.PHYLLOTAXIS, Layout.SPIRAL, Layout.PHYLLOTAXIS, Layout.GRID, Layout.WAVE]; + +var VizDemo = function () { + function VizDemo(count, async) { + _classCallCheck(this, VizDemo); + + this.layout = 0; + this.step = 0; + this.numSteps = 60 * 2; + + this.points = []; + + this.update(count, async); + + (this.next = this.next.bind(this))(); + } + + _createClass(VizDemo, [{ + key: 'next', + value: function next() { + var _this = this; + + requestAnimationFrame(this.next); + + this.step = (this.step + 1) % this.numSteps; + + if (this.step === 0) { + this.layout = (this.layout + 1) % LAYOUT_ORDER.length; + } + + // Clamp the linear interpolation at 80% for a pause at each finished layout state + var pct = Math.min(1, this.step / (this.numSteps * 0.8)); + + var currentLayout = LAYOUT_ORDER[this.layout]; + var nextLayout = LAYOUT_ORDER[(this.layout + 1) % LAYOUT_ORDER.length]; + + // Keep these redundant computations out of the loop + var pxProp = xForLayout(currentLayout); + var nxProp = xForLayout(nextLayout); + var pyProp = yForLayout(currentLayout); + var nyProp = yForLayout(nextLayout); + + this.points.forEach(function (point) { + point.x = lerp(point, pct, pxProp, nxProp); + point.y = lerp(point, pct, pyProp, nyProp); + }); + + if (this.async) { + if (!this.ric) this.ric = requestIdleCallback(function () { + _this.ric = 0;_this.render(); + }, { timeout: 50 }); + } else { + this.render(); + } + } + }, { + key: 'makePoints', + value: function makePoints() { + var newPoints = []; + for (var i = 0; i < this.count; i++) { + newPoints.push({ + x: 0, + y: 0, + color: d3.interpolateViridis(i / this.count) + }); + } + this.points = newPoints; + this.setAnchors(); + } + }, { + key: 'setAnchors', + value: function setAnchors() { + var _this2 = this; + + this.points.forEach(function (p, index) { + var _project = project(_this2.grid(index)), + _project2 = _slicedToArray(_project, 2), + gx = _project2[0], + gy = _project2[1]; + + var _project3 = project(_this2.wave(index)), + _project4 = _slicedToArray(_project3, 2), + wx = _project4[0], + wy = _project4[1]; + + var _project5 = project(_this2.spiral(index)), + _project6 = _slicedToArray(_project5, 2), + sx = _project6[0], + sy = _project6[1]; + + var _project7 = project(_this2.phyllotaxis(index)), + _project8 = _slicedToArray(_project7, 2), + px = _project8[0], + py = _project8[1]; + + Object.assign(p, { gx: gx, gy: gy, wx: wx, wy: wy, sx: sx, sy: sy, px: px, py: py }); + }); + } + }, { + key: 'update', + value: function update(count, async) { + this.count = count; + this.async = async; + + this.phyllotaxis = genPhyllotaxis(count); + this.grid = genGrid(count); + this.wave = genWave(count); + this.spiral = genSpiral(count); + + this.makePoints(); + } + }, { + key: 'render', + value: function render() { + return hyperHTML.wire(this)(_templateObject2, this.points.map(renderPoint)); + } + }]); + + return VizDemo; +}(); + +// utilities + +function renderPoint(point) { + return hyperHTML.wire(point, 'svg')(_templateObject3, point.color, 'translate(' + point.x + ', ' + point.y + ')'); +} + +var theta = Math.PI * (3 - Math.sqrt(5)); + +function xForLayout(layout) { + switch (layout) { + case Layout.PHYLLOTAXIS: + return 'px'; + case Layout.GRID: + return 'gx'; + case Layout.WAVE: + return 'wx'; + case Layout.SPIRAL: + return 'sx'; + } +} + +function yForLayout(layout) { + switch (layout) { + case Layout.PHYLLOTAXIS: + return 'py'; + case Layout.GRID: + return 'gy'; + case Layout.WAVE: + return 'wy'; + case Layout.SPIRAL: + return 'sy'; + } +} + +function lerp(obj, percent, startProp, endProp) { + var px = obj[startProp]; + return px + (obj[endProp] - px) * percent; +} + +function genPhyllotaxis(n) { + return function (i) { + var r = Math.sqrt(i / n); + var th = i * theta; + return [r * Math.cos(th), r * Math.sin(th)]; + }; +} + +function genGrid(n) { + var rowLength = Math.round(Math.sqrt(n)); + return function (i) { + return [-0.8 + 1.6 / rowLength * (i % rowLength), -0.8 + 1.6 / rowLength * Math.floor(i / rowLength)]; + }; +} + +function genWave(n) { + var xScale = 2 / (n - 1); + return function (i) { + var x = -1 + i * xScale; + return [x, Math.sin(x * Math.PI * 3) * 0.3]; + }; +} + +function genSpiral(n) { + return function (i) { + var t = Math.sqrt(i / (n - 1)), + phi = t * Math.PI * 10; + return [t * Math.cos(phi), t * Math.sin(phi)]; + }; +} + +function scale(magnitude, vector) { + return vector.map(function (p) { + return p * magnitude; + }); +} + +function translate(translation, vector) { + return vector.map(function (p, i) { + return p + translation[i]; + }); +} + +function project(vector) { + var wh = window.innerHeight / 2; + var ww = window.innerWidth / 2; + return translate([ww, wh], scale(Math.min(wh, ww), vector)); +} + +document.body.appendChild(new Demo(1000).render()); \ No newline at end of file diff --git a/test/dist/hyper.js b/test/dist/hyper.js new file mode 100644 index 00000000..262bc6fc --- /dev/null +++ b/test/dist/hyper.js @@ -0,0 +1,41 @@ +'use strict'; + +var _createClass = 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; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +// A Basic Hyper Class +var Hyper = function (_HTMLElement) { + _inherits(Hyper, _HTMLElement); + + function Hyper() { + _classCallCheck(this, Hyper); + + return _possibleConstructorReturn(this, (Hyper.__proto__ || Object.getPrototypeOf(Hyper)).apply(this, arguments)); + } + + _createClass(Hyper, [{ + key: '_initHyper', + value: function _initHyper() { + if ('hyper' in this) return; + this.hyper = hyperHTML.wire(); + this.appendChild(this.render()); + } + }, { + key: 'attributeChangedCallback', + value: function attributeChangedCallback() { + this._initHyper(); + } + }, { + key: 'connectedCallback', + value: function connectedCallback() { + this._initHyper(); + } + }]); + + return Hyper; +}(HTMLElement); \ No newline at end of file diff --git a/test/dist/ie.js b/test/dist/ie.js new file mode 100644 index 00000000..621dacb5 --- /dev/null +++ b/test/dist/ie.js @@ -0,0 +1,32 @@ +'use strict'; + +var _templateObject = _taggedTemplateLiteral(['\n \n

', '

\n List of ', ' paragraphs:\n
    ', '
\n \n '], ['\n \n

', '

\n List of ', ' paragraphs:\n
    ', '
\n \n ']), + _templateObject2 = _taggedTemplateLiteral(['
  • ', '
  • '], ['
  • ', '
  • ']), + _templateObject3 = _taggedTemplateLiteral(['\n \n even\n IE\n \n \n \n can do partial ', '\n \n \n '], ['\n \n even\n IE\n \n \n \n can do partial ', '\n \n \n ']); + +function _taggedTemplateLiteral(strings, raw) { return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); } + +window.onload = function () { + + var articleElement = document.querySelector('article'); + + var update = function update(render, state) { + return render(_templateObject, state.magic, state.id, state.class, state.title, state.paragraphs.length, function (e) { + return alert(e.target.innerHTML); + }, state.paragraphs.map(function (p) { + return hyperHTML.wire(p)(_templateObject2, p.title); + })); + }; + + update(hyperHTML.bind(articleElement), { + id: 'completely-random', + class: 'it-does-not-matter', + title: 'True story', + magic: true, + paragraphs: [{ title: 'touching' }, { title: 'incredible' }, { title: 'doge' }] + }); + + var tbody = hyperHTML.bind(document.body.appendChild(document.createElement('table')).appendChild(document.createElement('tbody'))); + + tbody(_templateObject3, ''); +}; \ No newline at end of file diff --git a/test/dom-splicer.js b/test/dom-splicer.js new file mode 100644 index 00000000..a258449e --- /dev/null +++ b/test/dom-splicer.js @@ -0,0 +1,90 @@ +var splicer = new DOMSplicer({ + target: document.documentElement +}); + +var a = document.createTextNode('a'); +var b = document.createTextNode('b'); +var c = document.createTextNode('c'); +var d = document.createTextNode('d'); +var e = document.createTextNode('e'); +var f = document.createTextNode('f'); +var g = document.createTextNode('g'); +var h = document.createTextNode('h'); +var i = document.createTextNode('i'); + +console.time(); +splicer.splice(0, 0, a, b, c, d, e); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(2, 1, g); +console.timeEnd(); +verify(splicer); + +splicer = new DOMSplicer({ + target: document.createElement('div'), + childNodes: [] +}); + +console.time(); +splicer.splice(0, 0, a, b, c, d, e); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(2, 1, g); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(1, 1); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(10); +console.timeEnd(); +verify(splicer); + +console.time(); +splicer.splice(-1); +console.timeEnd(); +verify(splicer); + +const fragment = document.createDocumentFragment(); +fragment.appendChild(document.createComment('placeholder')); +splicer = new DOMSplicer({ + before: fragment.childNodes[0] +}); +splicer.splice(0, 0, a, b, c, d, e); + +splicer = new DOMSplicer({ + target: fragment, + childNodes: {length: 0} +}); +splicer.splice(0, 100); + +function verify(splicer) { + console.assert( + [].slice.call(splicer.childNodes).every( + function (node, i) { + return splicer.target.childNodes[i] === node; + } + ), + 'splicer.childNodes same as splicer.target.childNodes' + ); + console.assert( + [].slice.call(splicer.target.childNodes).every( + function (node, i) { + return splicer.childNodes[i] === node; + } + ), + 'splicer.target.childNodes same as splicer.childNodes' + ); +} \ No newline at end of file diff --git a/test/domdiff.js b/test/domdiff.js new file mode 100644 index 00000000..975142fa --- /dev/null +++ b/test/domdiff.js @@ -0,0 +1,1218 @@ +var domdiff = hyperHTML.diff; + +var assert = tressa.assert; +var clean = function () { + for (var cn = document.body.childNodes, i = cn.length; i--;) { + document.body.removeChild(cn[i]); + } +}; +var compare = function (state, value) { + assert( + state.length === value.length && + value.split('').every(function (v, i) { + return state[i] === nodes[v]; + }), + value || '[empy]' + ); +}; + +var notNull = function (any) { return any != null; }; + +tressa.title('domdiff'); + +assert(typeof domdiff === 'function', 'is a function'); + +var nodes = { + 'a': document.createTextNode('a'), + 'b': document.createTextNode('b'), + 'c': document.createTextNode('c'), + 'd': document.createTextNode('d'), + 'e': document.createTextNode('e'), + 'f': document.createTextNode('f'), + 'g': document.createTextNode('g'), + 'h': document.createTextNode('h'), + 'i': document.createTextNode('i'), + 'j': document.createTextNode('j'), + 'k': document.createTextNode('k') +}; + +clean(); + +var options = {before: document.createTextNode('-')}; +var futureState = domdiff( + document.body, + [], + [nodes.b, nodes.c, nodes.d] +); +compare(futureState, 'bcd'); + +// same list, no changes +futureState = domdiff( + document.body, + futureState, + [nodes.b, nodes.c, nodes.d] +); +compare(futureState, 'bcd'); + +// more on the left +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d] +); +compare(futureState, 'abcd'); + +// more on the right +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f] +); +compare(futureState, 'abcdef'); + +// more in the middle +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e, nodes.f] +); +compare(futureState, 'abcghidef'); + +// drop from right +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e] +); +compare(futureState, 'abcghide'); + +// drop from left +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e] +); +compare(futureState, 'cghide'); + +// drop in between +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.g, nodes.d, nodes.e] +); +compare(futureState, 'cgde'); + +// drop all nodes +futureState = domdiff( + document.body, + futureState, + [] +); +compare(futureState, ''); + +domdiff( + document.body, + futureState, + [options.before] +); + +futureState = domdiff( + document.body, + futureState, + [nodes.b, nodes.c, nodes.d], + options +); +compare(futureState, 'bcd'); + +// same list, no changes with before +futureState = domdiff( + document.body, + futureState, + [nodes.b, nodes.c, nodes.d], + options +); +compare(futureState, 'bcd'); + +// more on the left with before +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d], + options +); +compare(futureState, 'abcd'); + +// more on the right with before +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abcdef'); + +// more in the middle with before +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abcghidef'); + +// drop from right with before +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e], + options +); +compare(futureState, 'abcghide'); + +// drop from left with before +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.g, nodes.h, nodes.i, nodes.d, nodes.e], + options +); +compare(futureState, 'cghide'); + +// drop in between with before +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.g, nodes.d, nodes.e], + options +); +compare(futureState, 'cgde'); + + +// drop one in between with before +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.g, nodes.e], + options +); +compare(futureState, 'cge'); + +// drop all nodes with before +futureState = domdiff( + document.body, + futureState, + [], + options +); +compare(futureState, ''); + +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abcdef'); + +// partial substitution one to many +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.g, nodes.i, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abgidef'); + +// partial substitution many to o e +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abcdef'); + +// inner diff +futureState = domdiff( + document.body, + futureState, + [nodes.j, nodes.g, nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f, nodes.h, nodes.i], + options +); +compare(futureState, 'jgabcdefhi'); + +// outer diff +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + options +); +compare(futureState, 'abcdef'); + +// fuzzy diff +futureState = domdiff( + document.body, + futureState, + [nodes.a, nodes.g, nodes.c, nodes.d, nodes.h, nodes.i], + options +); +compare(futureState, 'agcdhi'); + +// fuzzy diff +futureState = domdiff( + document.body, + futureState, + [nodes.i, nodes.g, nodes.a, nodes.d, nodes.h, nodes.c], + options +); +compare(futureState, 'igadhc'); + +// reversed diff +futureState = domdiff( + document.body, + futureState, + [nodes.c, nodes.h, nodes.d, nodes.a, nodes.g, nodes.i], + options +); +compare(futureState, 'chdagi'); + +clean(); + +var newState = domdiff( + document.body, + [], + [nodes.d, nodes.f, nodes.g] +); +compare(newState, 'dfg'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c].concat(newState) +); +compare(newState, 'abcdfg'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.b, nodes.c, + nodes.d, nodes.e, nodes.f, + nodes.g + ] +); +compare(newState, 'abcdefg'); + +newState = domdiff( + document.body, + newState, + newState.slice().reverse() +); +compare(newState, 'gfedcba'); + +newState = domdiff( + document.body, + newState, + [ + nodes.f, nodes.d, nodes.b, + nodes.a, nodes.e, nodes.g + ] +); +compare(newState, 'fdbaeg'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.b, nodes.c, + nodes.d, nodes.e, nodes.f + ] +); +compare(newState, 'abcdef'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.b, nodes.c, + nodes.d, nodes.e, nodes.f, + nodes.h, nodes.i, nodes.j + ] +); +compare(newState, 'abcdefhij'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.b, nodes.c, + nodes.d, nodes.e, nodes.f, + nodes.g, nodes.h, nodes.i, + nodes.j, nodes.k + ], + {node: Object, compare: (a, b) => a === b} +); +compare(newState, 'abcdefghijk'); + +newState = domdiff( + document.body, + newState, + [ + nodes.g, nodes.h, nodes.i + ], + {node: Object} +); +compare(newState, 'ghi'); + +document.body.insertBefore(nodes.f, nodes.g); +if ('onclick' in document.body) { + console.log('browser only'); + compare([].slice.call(document.body.childNodes), 'fghi'); +} + +clean(); +document.body.insertBefore(nodes.k, null); +newState = domdiff( + document.body, + [], + [ + nodes.c, nodes.d, nodes.e + ], + {before: nodes.k} +); +compare(newState, 'cde'); + +/* +newState = domdiff( + document.body, + newState, + [ + null, nodes.c, nodes.d, nodes.e, null + ], + {before: nodes.k} +); +compare(newState.filter(notNull), 'cde'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.c, null, nodes.e, nodes.f + ], + {before: nodes.k} +); +compare(newState.filter(notNull), 'acef'); +*/ + +newState = domdiff( + document.body, + newState, + [ + nodes.c, nodes.d, nodes.e, + nodes.g, nodes.h, nodes.i + ], + {before: nodes.k} +); +compare(newState, 'cdeghi'); + +newState = domdiff( + document.body, + newState, + [ + nodes.a, nodes.b, nodes.c, + nodes.d, nodes.e, nodes.f, + nodes.g, nodes.h, nodes.i + ], + {before: nodes.k} +); +compare(newState, 'abcdefghi'); + +newState = domdiff( + document.body, + newState, + [ + nodes.b, nodes.a, nodes.c, + nodes.d, nodes.e, nodes.f, + nodes.g, nodes.i, nodes.h + ], + {before: nodes.k} +); +compare(newState, 'bacdefgih'); + +newState = domdiff( + document.body, + newState, + [], + {before: nodes.k} +); +compare(newState, ''); + +// https://github.com/snabbdom/snabbdom/blob/master/test/core.js +tressa.log('## snabbdom - updating children'); +newState = domdiff( + document.body, + newState, + [nodes.a], + {before: nodes.k} +); +compare(newState, 'a'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'de'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.d], + {before: nodes.k} +); +compare(newState, 'bcd'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [], + {before: nodes.k} +); +compare(newState, ''); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, document.createTextNode('b'), nodes.c], + {before: nodes.k} +); +assert( + newState[1] !== nodes.b && + newState.length === 3 && + newState[0] === nodes.a && + newState[2] === nodes.c, + 'replace one child' +); + +tressa.log('## snabbdom - removal of elements'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'cde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abde'); + +tressa.log('## snabbdom - element reordering'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d], + {before: nodes.k} +); +compare(newState, 'abcd'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.a, nodes.d], + {before: nodes.k} +); +compare(newState, 'bcad'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.a, nodes.d], + {before: nodes.k} +); +compare(newState, 'bcad'); + +newState = domdiff( + document.body, + newState, + [nodes.c, nodes.b, nodes.d], + {before: nodes.k} +); +compare(newState, 'cbd'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.a], + {before: nodes.k} +); +compare(newState, 'bca'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d], + {before: nodes.k} +); +compare(newState, 'abcd'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'adbc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'adbc'); + +tressa.log('## snabbdom - combination'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.a, nodes.b, nodes.c, nodes.f], + {before: nodes.k} +); +compare(newState, 'dabcf'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'ade'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.f], + {before: nodes.k} +); +compare(newState, 'df'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.d, nodes.e], + {before: nodes.k} +); +compare(newState, 'bde'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.e, nodes.c], + {before: nodes.k} +); +compare(newState, 'dec'); + +newState = domdiff( + document.body, + newState, + [nodes.j, nodes.a, nodes.b, nodes.c], + {before: nodes.k} +); +compare(newState, 'jabc'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.a, nodes.b, nodes.c, nodes.j, nodes.e], + {before: nodes.k} +); +compare(newState, 'dabcje'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f, nodes.g, nodes.h], + {before: nodes.k} +); +compare(newState, 'abcdefgh'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f, nodes.g, nodes.h].reverse(), + {before: nodes.k} +); +compare(newState, 'hgfedcba'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + {before: nodes.k} +); +compare(newState, 'abcdef'); + +newState = domdiff( + document.body, + newState, + [nodes.e, nodes.d, nodes.c, nodes.b, nodes.f, nodes.a], + {before: nodes.k} +); +compare(newState, 'edcbfa'); + +tressa.log('## snabbdom - random values'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + {before: nodes.k} +); +compare(newState, 'abcdef'); + +/* +newState = domdiff( + document.body, + newState, + [null, nodes.c, undefined, null, nodes.b, nodes.a, null, nodes.f, nodes.e, null, nodes.d, undefined], + {before: nodes.k} +); +compare(newState.filter(notNull), 'cbafed'); +*/ + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f], + {before: nodes.k} +); +compare(newState, 'abcdef'); + +/* +newState = domdiff( + document.body, + newState, + [null, null, undefined, null, null, undefined], + {before: nodes.k} +); +compare(newState.filter(notNull), ''); +*/ + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f].reverse(), + {before: nodes.k} +); +compare(newState, 'fedcba'); + +clean(); +tressa.log('## snabbdom - updating children (unpinned)'); +newState = domdiff( + document.body, + [], + [nodes.a] +); +compare(newState, 'a'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c] +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.e] +); +compare(newState, 'de'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.d, nodes.e] +); +compare(newState, 'abde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.d] +); +compare(newState, 'bcd'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [] +); +compare(newState, ''); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c] +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, document.createTextNode('b'), nodes.c] +); +assert( + newState[1] !== nodes.b && + newState.length === 3 && + newState[0] === nodes.a && + newState[2] === nodes.c, + 'replace one child' +); + +tressa.log('## snabbdom - removal of elements (unpinned)'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.c, nodes.d, nodes.e] +); +compare(newState, 'cde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c] +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.d, nodes.e] +); +compare(newState, 'abde'); + +tressa.log('## snabbdom - element reordering (unpinned)'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d] +); +compare(newState, 'abcd'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.a, nodes.d] +); +compare(newState, 'bcad'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c] +); +compare(newState, 'abc'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.a] +); +compare(newState, 'bca'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d] +); +compare(newState, 'abcd'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.b, nodes.c] +); +compare(newState, 'adbc'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.b, nodes.c] +); +compare(newState, 'adbc'); + +tressa.log('## snabbdom - combination (unpinned)'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e] +); +compare(newState, 'abcde'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.a, nodes.b, nodes.c, nodes.f] +); +compare(newState, 'dabcf'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.d, nodes.e] +); +compare(newState, 'ade'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.f] +); +compare(newState, 'df'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.d, nodes.e] +); +compare(newState, 'bde'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.e, nodes.c] +); +compare(newState, 'dec'); + +newState = domdiff( + document.body, + newState, + [nodes.j, nodes.a, nodes.b, nodes.c] +); +compare(newState, 'jabc'); + +newState = domdiff( + document.body, + newState, + [nodes.d, nodes.a, nodes.b, nodes.c, nodes.j, nodes.e] +); +compare(newState, 'dabcje'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f, nodes.g, nodes.h] +); +compare(newState, 'abcdefgh'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f, nodes.g, nodes.h].reverse() +); +compare(newState, 'hgfedcba'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f] +); +compare(newState, 'abcdef'); + +newState = domdiff( + document.body, + newState, + [nodes.e, nodes.d, nodes.c, nodes.b, nodes.f, nodes.a] +); +compare(newState, 'edcbfa'); + +tressa.log('## snabbdom - random values (unpinned)'); + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f] +); +compare(newState, 'abcdef'); + +/* +newState = domdiff( + document.body, + newState, + [null, nodes.c, undefined, null, nodes.b, nodes.a, null, nodes.f, nodes.e, null, nodes.d, undefined] +); +compare(newState.filter(notNull), 'cbafed'); +*/ + +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f] +); +compare(newState, 'abcdef'); + +/* +newState = domdiff( + document.body, + newState, + [null, null, undefined, null, null, undefined] +); +compare(newState.filter(notNull), ''); +*/ + +console.time('average'); +newState = domdiff( + document.body, + newState, + [nodes.a, nodes.b, nodes.c, nodes.d, nodes.e, nodes.f].reverse() +); +compare(newState, 'fedcba'); +console.timeEnd('average'); + +newState = domdiff( + document.body, + newState, + [nodes.a] +); +compare(newState, 'a'); + +newState = domdiff( + document.body, + newState, + [nodes.b, nodes.c, nodes.d] +); +compare(newState, 'bcd'); + +newState = domdiff( + document.body, + newState, + [nodes.a] +); +compare(newState, 'a'); + +newState = domdiff( + document.body, + newState, + [] +); + +var data = [ + {"id": 4054, "title": "Serie 2"}, + {"id": 3982, "title": "Serie 3"}, + {"id": 4016, "title": "Gracias"}, + {"id":3984, "title": "Comparte"}, + {"id":3952, "title": "Lecciรณn 1"}, + {"id":3955, "title": "Lecciรณn 2"} +]; + +var wm = {}; + +var getItem = function (item) { return wm[item.id]; }; + +data.forEach(function (item) { + wm[item.id] = document.createTextNode(item.id + ': ' + item.title); +}); + +newState = domdiff( + document.body, + newState, + data.slice().map(getItem) +); + +newState = domdiff( + document.body, + newState, + data.slice().sort(function (a, b) { + return a.title.localeCompare(b.title); + }).map(getItem) +); + +newState = domdiff( + document.body, + newState, + Array(1000).join('.').split('.').map(function (v, i) { + return document.createTextNode('' + i); + }) +); + +console.time('random'); +newState = domdiff( + document.body, + newState, + newState.slice().sort(function () { + return Math.random() < .5 ? 1 : -1; + }) +); +console.timeEnd('random'); + +console.time('reversed'); +newState = domdiff( + document.body, + newState, + newState.slice().reverse() +); +console.timeEnd('reversed'); + +// */ + +tressa.end(); diff --git a/test/double-rainbow.html b/test/double-rainbow.html new file mode 100644 index 00000000..75e63fde --- /dev/null +++ b/test/double-rainbow.html @@ -0,0 +1,72 @@ + + + + hyperHTML Double Rainbow + + + + + + + + \ No newline at end of file diff --git a/test/e-icon.html b/test/e-icon.html new file mode 100644 index 00000000..865d109f --- /dev/null +++ b/test/e-icon.html @@ -0,0 +1,71 @@ + + + + \ No newline at end of file diff --git a/test/edge.html b/test/edge.html new file mode 100644 index 00000000..b2b36711 --- /dev/null +++ b/test/edge.html @@ -0,0 +1,13 @@ + + + + Edge test + + + + + \ No newline at end of file diff --git a/test/esm.html b/test/esm.html new file mode 100644 index 00000000..3f8c0543 --- /dev/null +++ b/test/esm.html @@ -0,0 +1,5 @@ + + \ No newline at end of file diff --git a/test/exchange.html b/test/exchange.html new file mode 100644 index 00000000..f10984b7 --- /dev/null +++ b/test/exchange.html @@ -0,0 +1,101 @@ + + + + + + OpenExchangeRates hyperHTML Demo + + + + + + + + + +

    + powered by hyper(HTML) +

    +
    +
    +
    + + + \ No newline at end of file diff --git a/test/fuzzysort.html b/test/fuzzysort.html new file mode 100644 index 00000000..ed4c2cb1 --- /dev/null +++ b/test/fuzzysort.html @@ -0,0 +1,97 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/test/haunted.html b/test/haunted.html new file mode 100644 index 00000000..188be5be --- /dev/null +++ b/test/haunted.html @@ -0,0 +1,27 @@ + + + + + + + hyperHTML & haunted + + + + + + \ No newline at end of file diff --git a/test/hello-world-ce.html b/test/hello-world-ce.html new file mode 100644 index 00000000..52e2ee5b --- /dev/null +++ b/test/hello-world-ce.html @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + diff --git a/test/ie.html b/test/ie.html new file mode 100644 index 00000000..48cea356 --- /dev/null +++ b/test/ie.html @@ -0,0 +1,10 @@ + + + + + + + + +
    + diff --git a/test/ie/index.html b/test/ie/index.html new file mode 100644 index 00000000..ee2f0823 --- /dev/null +++ b/test/ie/index.html @@ -0,0 +1,58 @@ + + + + + + + + + + + + + +

    results in console

    + + + + + + \ No newline at end of file diff --git a/test/ie/test/test.js b/test/ie/test/test.js new file mode 100644 index 00000000..0b3662a0 --- /dev/null +++ b/test/ie/test/test.js @@ -0,0 +1,3051 @@ +(function () { + 'use strict'; + + function _classCallCheck(instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a 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; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + + function _createClass(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties(Constructor.prototype, protoProps); + if (staticProps) _defineProperties(Constructor, staticProps); + return Constructor; + } + + function _inherits(subClass, superClass) { + if (typeof superClass !== "function" && superClass !== null) { + throw new TypeError("Super expression must either be null or a function"); + } + + subClass.prototype = Object.create(superClass && superClass.prototype, { + constructor: { + value: subClass, + writable: true, + configurable: true + } + }); + if (superClass) _setPrototypeOf(subClass, superClass); + } + + function _getPrototypeOf(o) { + _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { + return o.__proto__ || Object.getPrototypeOf(o); + }; + return _getPrototypeOf(o); + } + + function _setPrototypeOf(o, p) { + _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { + o.__proto__ = p; + return o; + }; + + return _setPrototypeOf(o, p); + } + + function _isNativeReflectConstruct() { + if (typeof Reflect === "undefined" || !Reflect.construct) return false; + if (Reflect.construct.sham) return false; + if (typeof Proxy === "function") return true; + + try { + Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); + return true; + } catch (e) { + return false; + } + } + + function _assertThisInitialized(self) { + if (self === void 0) { + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + } + + return self; + } + + function _possibleConstructorReturn(self, call) { + if (call && (typeof call === "object" || typeof call === "function")) { + return call; + } + + return _assertThisInitialized(self); + } + + function _createSuper(Derived) { + var hasNativeReflectConstruct = _isNativeReflectConstruct(); + + return function _createSuperInternal() { + var Super = _getPrototypeOf(Derived), + result; + + if (hasNativeReflectConstruct) { + var NewTarget = _getPrototypeOf(this).constructor; + + result = Reflect.construct(Super, arguments, NewTarget); + } else { + result = Super.apply(this, arguments); + } + + return _possibleConstructorReturn(this, result); + }; + } + + function _taggedTemplateLiteral(strings, raw) { + if (!raw) { + raw = strings.slice(0); + } + + return Object.freeze(Object.defineProperties(strings, { + raw: { + value: Object.freeze(raw) + } + })); + } + + function _templateObject130() { + var data = _taggedTemplateLiteral([""]); + + _templateObject130 = function _templateObject130() { + return data; + }; + + return data; + } + + function _templateObject129() { + var data = _taggedTemplateLiteral([""]); + + _templateObject129 = function _templateObject129() { + return data; + }; + + return data; + } + + function _templateObject128() { + var data = _taggedTemplateLiteral([""]); + + _templateObject128 = function _templateObject128() { + return data; + }; + + return data; + } + + function _templateObject127() { + var data = _taggedTemplateLiteral(["

    "]); + + _templateObject127 = function _templateObject127() { + return data; + }; + + return data; + } + + function _templateObject126() { + var data = _taggedTemplateLiteral(["", " - ", ""]); + + _templateObject126 = function _templateObject126() { + return data; + }; + + return data; + } + + function _templateObject125() { + var data = _taggedTemplateLiteral(["", ""]); + + _templateObject125 = function _templateObject125() { + return data; + }; + + return data; + } + + function _templateObject124() { + var data = _taggedTemplateLiteral(["

    c

    "]); + + _templateObject124 = function _templateObject124() { + return data; + }; + + return data; + } + + function _templateObject123() { + var data = _taggedTemplateLiteral(["

    a

    b

    "]); + + _templateObject123 = function _templateObject123() { + return data; + }; + + return data; + } + + function _templateObject122() { + var data = _taggedTemplateLiteral(["", ""]); + + _templateObject122 = function _templateObject122() { + return data; + }; + + return data; + } + + function _templateObject121() { + var data = _taggedTemplateLiteral(["", ""]); + + _templateObject121 = function _templateObject121() { + return data; + }; + + return data; + } + + function _templateObject120() { + var data = _taggedTemplateLiteral(["\n
  • ", "
  • \n "]); + + _templateObject120 = function _templateObject120() { + return data; + }; + + return data; + } + + function _templateObject119() { + var data = _taggedTemplateLiteral(["\n
    A simple menu
    \n
      \n ", "\n
    \n "]); + + _templateObject119 = function _templateObject119() { + return data; + }; + + return data; + } + + function _templateObject118() { + var data = _taggedTemplateLiteral(["\n
    A simple menu
    \n
      \n ", "\n
    \n "]); + + _templateObject118 = function _templateObject118() { + return data; + }; + + return data; + } + + function _templateObject117() { + var data = _taggedTemplateLiteral(["\n
    I'm parent\n ", "\n
    \n "]); + + _templateObject117 = function _templateObject117() { + return data; + }; + + return data; + } + + function _templateObject116() { + var data = _taggedTemplateLiteral(["\n
    I'm child\n ", "\n
    \n "]); + + _templateObject116 = function _templateObject116() { + return data; + }; + + return data; + } + + function _templateObject115() { + var data = _taggedTemplateLiteral(["\n

    I'm grand child

    "]); + + _templateObject115 = function _templateObject115() { + return data; + }; + + return data; + } + + function _templateObject114() { + var data = _taggedTemplateLiteral(["\n
    \n