Version Description
Download this release
Release Info
| Developer | metaslider |
| Plugin | |
| Version | 3.27.9 |
| Comparing to | |
| See all releases | |
Code changes from version 3.27.9-beta.3 to 3.27.9
- .buildignore +56 -0
- admin/assets/tether-shepherd/README.md +69 -0
- admin/assets/tether-shepherd/package.json +37 -0
- composer.json +0 -80
- composer.lock +0 -1503
- dist/.gitignore +2 -0
- extendify-sdk/jsconfig.json +8 -0
- languages/ml-slider-js.pot +0 -24
- lib/appsero/.gitignore +16 -0
- lib/htmlpurifier/README.md +29 -0
- metagallery/public/build/metagallery-scripts.js +6345 -21
- metagallery/public/build/metagallery.js +8159 -22
.buildignore
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.babelrc
|
| 2 |
+
.buildignore
|
| 3 |
+
.eslintrc.js
|
| 4 |
+
.git
|
| 5 |
+
.gitattributes
|
| 6 |
+
.github
|
| 7 |
+
.gitignore
|
| 8 |
+
.idea
|
| 9 |
+
.php-cs-fixer.cache
|
| 10 |
+
.phpcs.xml
|
| 11 |
+
.phplint-cache
|
| 12 |
+
.phplint.yml
|
| 13 |
+
.vscode
|
| 14 |
+
.wordpress-org
|
| 15 |
+
*.code-workspace
|
| 16 |
+
/dist
|
| 17 |
+
/metagallery/.editorconfig
|
| 18 |
+
/metagallery/.github
|
| 19 |
+
/metagallery/.gitignore
|
| 20 |
+
/metagallery/.phpcs.xml.dist
|
| 21 |
+
/metagallery/.prettierrc.js
|
| 22 |
+
/metagallery/babel.config.js
|
| 23 |
+
/metagallery/composer.json
|
| 24 |
+
/metagallery/composer.lock
|
| 25 |
+
/metagallery/cypress
|
| 26 |
+
/metagallery/cypress.json
|
| 27 |
+
/metagallery/package-lock.json
|
| 28 |
+
/metagallery/package.json
|
| 29 |
+
/metagallery/README.md
|
| 30 |
+
/metagallery/rollup.config.js
|
| 31 |
+
/metagallery/tailwind.config.js
|
| 32 |
+
/mix
|
| 33 |
+
bin
|
| 34 |
+
builder
|
| 35 |
+
builder.yml
|
| 36 |
+
codeception.dist.yml
|
| 37 |
+
cypress
|
| 38 |
+
cypress.json
|
| 39 |
+
Gruntfile.js
|
| 40 |
+
jsconfig.json
|
| 41 |
+
mix-manifest.json
|
| 42 |
+
node_modules
|
| 43 |
+
package-lock.json
|
| 44 |
+
package.json
|
| 45 |
+
psalm.xml
|
| 46 |
+
ray-dist.php
|
| 47 |
+
ray.php
|
| 48 |
+
README-build.md
|
| 49 |
+
README.md
|
| 50 |
+
RoboFile.php
|
| 51 |
+
screenshot-*.png
|
| 52 |
+
scripts
|
| 53 |
+
tailwind.config.js
|
| 54 |
+
tests
|
| 55 |
+
webpack.config.js
|
| 56 |
+
webpack.mix.js
|
admin/assets/tether-shepherd/README.md
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
## Shepherd
|
| 2 |
+
|
| 3 |
+
[](http://badge.fury.io/gh/HubSpot%2Fshepherd)
|
| 5 |
+
|
| 6 |
+
|
| 7 |
+
[](http://github.hubspot.com/shepherd/docs/welcome)
|
| 8 |
+
|
| 9 |
+
|
| 10 |
+
## Install
|
| 11 |
+
|
| 12 |
+
__Dependencies__
|
| 13 |
+
|
| 14 |
+
* __[Tether](https://github.com/HubSpot/tether)__
|
| 15 |
+
|
| 16 |
+
Installing via `npm` and `bower` will bring in the above dependencies as well.
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
__npm__
|
| 20 |
+
```sh
|
| 21 |
+
$ npm install tether-shepherd
|
| 22 |
+
```
|
| 23 |
+
|
| 24 |
+
__bower__
|
| 25 |
+
```sh
|
| 26 |
+
$ bower install tether-shepherd
|
| 27 |
+
```
|
| 28 |
+
|
| 29 |
+
__Eager__
|
| 30 |
+
|
| 31 |
+
The easiest way to add a Shepherd tour to your site is with [Eager](http://eager.io).
|
| 32 |
+
Click Install to create a tour right on your site with no coding required.
|
| 33 |
+
|
| 34 |
+
<a href="https://eager.io/app/AalP5veMma6s/install?source=button">
|
| 35 |
+
<img src="https://install.eager.io/install-button.png" border="0" width="126">
|
| 36 |
+
</a>
|
| 37 |
+
|
| 38 |
+
|
| 39 |
+
## Usage
|
| 40 |
+
|
| 41 |
+
```javascript
|
| 42 |
+
let tour = new Shepherd.Tour({
|
| 43 |
+
defaults: {
|
| 44 |
+
classes: 'shepherd-theme-arrows'
|
| 45 |
+
}
|
| 46 |
+
});
|
| 47 |
+
|
| 48 |
+
tour.addStep('example', {
|
| 49 |
+
title: 'Example Shepherd',
|
| 50 |
+
text: 'Creating a Shepherd is easy too! Just create ...',
|
| 51 |
+
attachTo: '.hero-example bottom',
|
| 52 |
+
advanceOn: '.docs-link click'
|
| 53 |
+
});
|
| 54 |
+
|
| 55 |
+
tour.start();
|
| 56 |
+
```
|
| 57 |
+
|
| 58 |
+
[API documentation](http://github.hubspot.com/shepherd/)
|
| 59 |
+
|
| 60 |
+
[Demo](http://github.hubspot.com/shepherd/docs/welcome/)
|
| 61 |
+
|
| 62 |
+
|
| 63 |
+
## Contributing
|
| 64 |
+
|
| 65 |
+
We encourage contributions of all kinds. If you would like to contribute in some way, please review our [guidelines for contributing](CONTRIBUTING.md).
|
| 66 |
+
|
| 67 |
+
|
| 68 |
+
## License
|
| 69 |
+
Copyright © 2015 HubSpot - [MIT License](LICENSE)
|
admin/assets/tether-shepherd/package.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"name": "tether-shepherd",
|
| 3 |
+
"version": "1.8.1",
|
| 4 |
+
"description": "Guide your users through a tour of your app.",
|
| 5 |
+
"authors": [
|
| 6 |
+
"Adam Schwartz <adam.flynn.schwartz@gmail.com>",
|
| 7 |
+
"Zack Bloom <zackbloom@gmail.com>"
|
| 8 |
+
],
|
| 9 |
+
"maintainers": [
|
| 10 |
+
"Nicholas Hwang <nick.joosung.hwang@gmail.com>",
|
| 11 |
+
"Geoff Daigle <geoffreydaigle@gmail.com>"
|
| 12 |
+
],
|
| 13 |
+
"scripts": {
|
| 14 |
+
"build": "gulp build"
|
| 15 |
+
},
|
| 16 |
+
"license": "MIT",
|
| 17 |
+
"main": "dist/js/shepherd.js",
|
| 18 |
+
"spm": {
|
| 19 |
+
"main": "shepherd.js"
|
| 20 |
+
},
|
| 21 |
+
"devDependencies": {
|
| 22 |
+
"del": "^1.2.0",
|
| 23 |
+
"gulp": "^3.9.0",
|
| 24 |
+
"gulp-autoprefixer": "^2.3.1",
|
| 25 |
+
"gulp-babel": "^5.1.0",
|
| 26 |
+
"gulp-bump": "^0.3.1",
|
| 27 |
+
"gulp-coffee": "^2.3.1",
|
| 28 |
+
"gulp-header": "^1.2.2",
|
| 29 |
+
"gulp-rename": "^1.2.2",
|
| 30 |
+
"gulp-sass": "^2.0.1",
|
| 31 |
+
"gulp-uglify": "^1.2.0",
|
| 32 |
+
"gulp-wrap-umd": "^0.2.1"
|
| 33 |
+
},
|
| 34 |
+
"dependencies": {
|
| 35 |
+
"tether": "^1.0.1"
|
| 36 |
+
}
|
| 37 |
+
}
|
composer.json
DELETED
|
@@ -1,80 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"name": "metaslider/ml-slider",
|
| 3 |
-
"type": "wordpress-plugin",
|
| 4 |
-
"license": "GPL-2.0-or-later",
|
| 5 |
-
"description" : "metaslider Project",
|
| 6 |
-
"repositories": [
|
| 7 |
-
{
|
| 8 |
-
"type": "vcs",
|
| 9 |
-
"url": "https://github.com/metaslider/flexslider"
|
| 10 |
-
},
|
| 11 |
-
{
|
| 12 |
-
"type": "package",
|
| 13 |
-
"package": {
|
| 14 |
-
"name": "metaslider/coin-slider",
|
| 15 |
-
"version": "1.0",
|
| 16 |
-
"type": "package",
|
| 17 |
-
"source": {
|
| 18 |
-
"url": "https://github.com/metaslider/coin-slider.git",
|
| 19 |
-
"type": "git",
|
| 20 |
-
"reference": "master"
|
| 21 |
-
}
|
| 22 |
-
}
|
| 23 |
-
},
|
| 24 |
-
{
|
| 25 |
-
"type": "package",
|
| 26 |
-
"package": {
|
| 27 |
-
"name": "metaslider/nivo-slider",
|
| 28 |
-
"version": "1.0",
|
| 29 |
-
"type": "package",
|
| 30 |
-
"source": {
|
| 31 |
-
"url": "https://github.com/metaslider/nivo-slider-jquery.git",
|
| 32 |
-
"type": "git",
|
| 33 |
-
"reference": "master"
|
| 34 |
-
}
|
| 35 |
-
}
|
| 36 |
-
},
|
| 37 |
-
{
|
| 38 |
-
"type": "vcs",
|
| 39 |
-
"url": "https://github.com/andergmartins/wordpress-ray"
|
| 40 |
-
},
|
| 41 |
-
{
|
| 42 |
-
"type": "vcs",
|
| 43 |
-
"url": "https://github.com/publishpress/publishpress-phpcs-standards"
|
| 44 |
-
}
|
| 45 |
-
],
|
| 46 |
-
"require": {
|
| 47 |
-
"php": ">=5.6.20",
|
| 48 |
-
"woocommerce/flexslider": "dev-master",
|
| 49 |
-
"metaslider/coin-slider": "^1.0",
|
| 50 |
-
"metaslider/nivo-slider": "^1.0",
|
| 51 |
-
"ext-json": "*",
|
| 52 |
-
"ext-fileinfo": "*"
|
| 53 |
-
},
|
| 54 |
-
"require-dev": {
|
| 55 |
-
"spatie/ray": "*",
|
| 56 |
-
"spatie/wordpress-ray": "dev-patch-1",
|
| 57 |
-
"phpcompatibility/php-compatibility": "*",
|
| 58 |
-
"squizlabs/php_codesniffer": "3.*",
|
| 59 |
-
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.0",
|
| 60 |
-
"publishpress/publishpress-phpcs-standards": "dev-main"
|
| 61 |
-
},
|
| 62 |
-
"prefer-stable" : true,
|
| 63 |
-
"config": {
|
| 64 |
-
"allow-plugins": {
|
| 65 |
-
"dealerdirect/phpcodesniffer-composer-installer": true
|
| 66 |
-
}
|
| 67 |
-
},
|
| 68 |
-
"scripts": {
|
| 69 |
-
"build-dir": "docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run prod && builder/docker/scripts/build build-dir",
|
| 70 |
-
"build": "docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run prod && builder/docker/scripts/build build",
|
| 71 |
-
"build-clean": "builder/docker/scripts/build clean",
|
| 72 |
-
"compile": "docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run prod && cd metagallery && docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run build",
|
| 73 |
-
"compile-dev": "docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run dev && cd metagallery && docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run build-dev",
|
| 74 |
-
"deploy": "docker run -it --rm -v $(PWD):/usr/src/app -w /usr/src/app node:14.19.3 npm run production && git add . && git commit -m 'wip:deployed' && git push"
|
| 75 |
-
},
|
| 76 |
-
"extra": {
|
| 77 |
-
"plugin-name": "metaslider",
|
| 78 |
-
"plugin-slug": "ml-slider"
|
| 79 |
-
}
|
| 80 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
composer.lock
DELETED
|
@@ -1,1503 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"_readme": [
|
| 3 |
-
"This file locks the dependencies of your project to a known state",
|
| 4 |
-
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
| 5 |
-
"This file is @generated automatically"
|
| 6 |
-
],
|
| 7 |
-
"content-hash": "1d755a532e4671904be54db9dd14b3f7",
|
| 8 |
-
"packages": [
|
| 9 |
-
{
|
| 10 |
-
"name": "metaslider/coin-slider",
|
| 11 |
-
"version": "1.0",
|
| 12 |
-
"source": {
|
| 13 |
-
"type": "git",
|
| 14 |
-
"url": "https://github.com/metaslider/coin-slider.git",
|
| 15 |
-
"reference": "master"
|
| 16 |
-
},
|
| 17 |
-
"type": "package"
|
| 18 |
-
},
|
| 19 |
-
{
|
| 20 |
-
"name": "metaslider/nivo-slider",
|
| 21 |
-
"version": "1.0",
|
| 22 |
-
"source": {
|
| 23 |
-
"type": "git",
|
| 24 |
-
"url": "https://github.com/metaslider/nivo-slider-jquery.git",
|
| 25 |
-
"reference": "master"
|
| 26 |
-
},
|
| 27 |
-
"type": "package"
|
| 28 |
-
},
|
| 29 |
-
{
|
| 30 |
-
"name": "woocommerce/FlexSlider",
|
| 31 |
-
"version": "dev-master",
|
| 32 |
-
"source": {
|
| 33 |
-
"type": "git",
|
| 34 |
-
"url": "https://github.com/MetaSlider/FlexSlider.git",
|
| 35 |
-
"reference": "b98022c57e9c72f2565a8dd78b8b1d7f368a41af"
|
| 36 |
-
},
|
| 37 |
-
"dist": {
|
| 38 |
-
"type": "zip",
|
| 39 |
-
"url": "https://api.github.com/repos/MetaSlider/FlexSlider/zipball/b98022c57e9c72f2565a8dd78b8b1d7f368a41af",
|
| 40 |
-
"reference": "b98022c57e9c72f2565a8dd78b8b1d7f368a41af",
|
| 41 |
-
"shasum": ""
|
| 42 |
-
},
|
| 43 |
-
"default-branch": true,
|
| 44 |
-
"type": "library",
|
| 45 |
-
"description": "An awesome, fully responsive jQuery slider toolkit.",
|
| 46 |
-
"homepage": "https://github.com/woocommerce/FlexSlider",
|
| 47 |
-
"keywords": [
|
| 48 |
-
"automattic",
|
| 49 |
-
"flexslider",
|
| 50 |
-
"jquery",
|
| 51 |
-
"slider",
|
| 52 |
-
"woocommerce"
|
| 53 |
-
],
|
| 54 |
-
"support": {
|
| 55 |
-
"source": "https://github.com/MetaSlider/FlexSlider/tree/master"
|
| 56 |
-
},
|
| 57 |
-
"time": "2020-11-10T10:53:23+00:00"
|
| 58 |
-
}
|
| 59 |
-
],
|
| 60 |
-
"packages-dev": [
|
| 61 |
-
{
|
| 62 |
-
"name": "brick/math",
|
| 63 |
-
"version": "0.9.3",
|
| 64 |
-
"source": {
|
| 65 |
-
"type": "git",
|
| 66 |
-
"url": "https://github.com/brick/math.git",
|
| 67 |
-
"reference": "ca57d18f028f84f777b2168cd1911b0dee2343ae"
|
| 68 |
-
},
|
| 69 |
-
"dist": {
|
| 70 |
-
"type": "zip",
|
| 71 |
-
"url": "https://api.github.com/repos/brick/math/zipball/ca57d18f028f84f777b2168cd1911b0dee2343ae",
|
| 72 |
-
"reference": "ca57d18f028f84f777b2168cd1911b0dee2343ae",
|
| 73 |
-
"shasum": ""
|
| 74 |
-
},
|
| 75 |
-
"require": {
|
| 76 |
-
"ext-json": "*",
|
| 77 |
-
"php": "^7.1 || ^8.0"
|
| 78 |
-
},
|
| 79 |
-
"require-dev": {
|
| 80 |
-
"php-coveralls/php-coveralls": "^2.2",
|
| 81 |
-
"phpunit/phpunit": "^7.5.15 || ^8.5 || ^9.0",
|
| 82 |
-
"vimeo/psalm": "4.9.2"
|
| 83 |
-
},
|
| 84 |
-
"type": "library",
|
| 85 |
-
"autoload": {
|
| 86 |
-
"psr-4": {
|
| 87 |
-
"Brick\\Math\\": "src/"
|
| 88 |
-
}
|
| 89 |
-
},
|
| 90 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 91 |
-
"license": [
|
| 92 |
-
"MIT"
|
| 93 |
-
],
|
| 94 |
-
"description": "Arbitrary-precision arithmetic library",
|
| 95 |
-
"keywords": [
|
| 96 |
-
"Arbitrary-precision",
|
| 97 |
-
"BigInteger",
|
| 98 |
-
"BigRational",
|
| 99 |
-
"arithmetic",
|
| 100 |
-
"bigdecimal",
|
| 101 |
-
"bignum",
|
| 102 |
-
"brick",
|
| 103 |
-
"math"
|
| 104 |
-
],
|
| 105 |
-
"support": {
|
| 106 |
-
"issues": "https://github.com/brick/math/issues",
|
| 107 |
-
"source": "https://github.com/brick/math/tree/0.9.3"
|
| 108 |
-
},
|
| 109 |
-
"funding": [
|
| 110 |
-
{
|
| 111 |
-
"url": "https://github.com/BenMorel",
|
| 112 |
-
"type": "github"
|
| 113 |
-
},
|
| 114 |
-
{
|
| 115 |
-
"url": "https://tidelift.com/funding/github/packagist/brick/math",
|
| 116 |
-
"type": "tidelift"
|
| 117 |
-
}
|
| 118 |
-
],
|
| 119 |
-
"time": "2021-08-15T20:50:18+00:00"
|
| 120 |
-
},
|
| 121 |
-
{
|
| 122 |
-
"name": "dealerdirect/phpcodesniffer-composer-installer",
|
| 123 |
-
"version": "v0.7.2",
|
| 124 |
-
"source": {
|
| 125 |
-
"type": "git",
|
| 126 |
-
"url": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer.git",
|
| 127 |
-
"reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db"
|
| 128 |
-
},
|
| 129 |
-
"dist": {
|
| 130 |
-
"type": "zip",
|
| 131 |
-
"url": "https://api.github.com/repos/Dealerdirect/phpcodesniffer-composer-installer/zipball/1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
|
| 132 |
-
"reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
|
| 133 |
-
"shasum": ""
|
| 134 |
-
},
|
| 135 |
-
"require": {
|
| 136 |
-
"composer-plugin-api": "^1.0 || ^2.0",
|
| 137 |
-
"php": ">=5.3",
|
| 138 |
-
"squizlabs/php_codesniffer": "^2.0 || ^3.1.0 || ^4.0"
|
| 139 |
-
},
|
| 140 |
-
"require-dev": {
|
| 141 |
-
"composer/composer": "*",
|
| 142 |
-
"php-parallel-lint/php-parallel-lint": "^1.3.1",
|
| 143 |
-
"phpcompatibility/php-compatibility": "^9.0"
|
| 144 |
-
},
|
| 145 |
-
"type": "composer-plugin",
|
| 146 |
-
"extra": {
|
| 147 |
-
"class": "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin"
|
| 148 |
-
},
|
| 149 |
-
"autoload": {
|
| 150 |
-
"psr-4": {
|
| 151 |
-
"Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\": "src/"
|
| 152 |
-
}
|
| 153 |
-
},
|
| 154 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 155 |
-
"license": [
|
| 156 |
-
"MIT"
|
| 157 |
-
],
|
| 158 |
-
"authors": [
|
| 159 |
-
{
|
| 160 |
-
"name": "Franck Nijhof",
|
| 161 |
-
"email": "franck.nijhof@dealerdirect.com",
|
| 162 |
-
"homepage": "http://www.frenck.nl",
|
| 163 |
-
"role": "Developer / IT Manager"
|
| 164 |
-
},
|
| 165 |
-
{
|
| 166 |
-
"name": "Contributors",
|
| 167 |
-
"homepage": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer/graphs/contributors"
|
| 168 |
-
}
|
| 169 |
-
],
|
| 170 |
-
"description": "PHP_CodeSniffer Standards Composer Installer Plugin",
|
| 171 |
-
"homepage": "http://www.dealerdirect.com",
|
| 172 |
-
"keywords": [
|
| 173 |
-
"PHPCodeSniffer",
|
| 174 |
-
"PHP_CodeSniffer",
|
| 175 |
-
"code quality",
|
| 176 |
-
"codesniffer",
|
| 177 |
-
"composer",
|
| 178 |
-
"installer",
|
| 179 |
-
"phpcbf",
|
| 180 |
-
"phpcs",
|
| 181 |
-
"plugin",
|
| 182 |
-
"qa",
|
| 183 |
-
"quality",
|
| 184 |
-
"standard",
|
| 185 |
-
"standards",
|
| 186 |
-
"style guide",
|
| 187 |
-
"stylecheck",
|
| 188 |
-
"tests"
|
| 189 |
-
],
|
| 190 |
-
"support": {
|
| 191 |
-
"issues": "https://github.com/dealerdirect/phpcodesniffer-composer-installer/issues",
|
| 192 |
-
"source": "https://github.com/dealerdirect/phpcodesniffer-composer-installer"
|
| 193 |
-
},
|
| 194 |
-
"time": "2022-02-04T12:51:07+00:00"
|
| 195 |
-
},
|
| 196 |
-
{
|
| 197 |
-
"name": "phpcompatibility/php-compatibility",
|
| 198 |
-
"version": "9.3.5",
|
| 199 |
-
"source": {
|
| 200 |
-
"type": "git",
|
| 201 |
-
"url": "https://github.com/PHPCompatibility/PHPCompatibility.git",
|
| 202 |
-
"reference": "9fb324479acf6f39452e0655d2429cc0d3914243"
|
| 203 |
-
},
|
| 204 |
-
"dist": {
|
| 205 |
-
"type": "zip",
|
| 206 |
-
"url": "https://api.github.com/repos/PHPCompatibility/PHPCompatibility/zipball/9fb324479acf6f39452e0655d2429cc0d3914243",
|
| 207 |
-
"reference": "9fb324479acf6f39452e0655d2429cc0d3914243",
|
| 208 |
-
"shasum": ""
|
| 209 |
-
},
|
| 210 |
-
"require": {
|
| 211 |
-
"php": ">=5.3",
|
| 212 |
-
"squizlabs/php_codesniffer": "^2.3 || ^3.0.2"
|
| 213 |
-
},
|
| 214 |
-
"conflict": {
|
| 215 |
-
"squizlabs/php_codesniffer": "2.6.2"
|
| 216 |
-
},
|
| 217 |
-
"require-dev": {
|
| 218 |
-
"phpunit/phpunit": "~4.5 || ^5.0 || ^6.0 || ^7.0"
|
| 219 |
-
},
|
| 220 |
-
"suggest": {
|
| 221 |
-
"dealerdirect/phpcodesniffer-composer-installer": "^0.5 || This Composer plugin will sort out the PHPCS 'installed_paths' automatically.",
|
| 222 |
-
"roave/security-advisories": "dev-master || Helps prevent installing dependencies with known security issues."
|
| 223 |
-
},
|
| 224 |
-
"type": "phpcodesniffer-standard",
|
| 225 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 226 |
-
"license": [
|
| 227 |
-
"LGPL-3.0-or-later"
|
| 228 |
-
],
|
| 229 |
-
"authors": [
|
| 230 |
-
{
|
| 231 |
-
"name": "Wim Godden",
|
| 232 |
-
"homepage": "https://github.com/wimg",
|
| 233 |
-
"role": "lead"
|
| 234 |
-
},
|
| 235 |
-
{
|
| 236 |
-
"name": "Juliette Reinders Folmer",
|
| 237 |
-
"homepage": "https://github.com/jrfnl",
|
| 238 |
-
"role": "lead"
|
| 239 |
-
},
|
| 240 |
-
{
|
| 241 |
-
"name": "Contributors",
|
| 242 |
-
"homepage": "https://github.com/PHPCompatibility/PHPCompatibility/graphs/contributors"
|
| 243 |
-
}
|
| 244 |
-
],
|
| 245 |
-
"description": "A set of sniffs for PHP_CodeSniffer that checks for PHP cross-version compatibility.",
|
| 246 |
-
"homepage": "http://techblog.wimgodden.be/tag/codesniffer/",
|
| 247 |
-
"keywords": [
|
| 248 |
-
"compatibility",
|
| 249 |
-
"phpcs",
|
| 250 |
-
"standards"
|
| 251 |
-
],
|
| 252 |
-
"support": {
|
| 253 |
-
"issues": "https://github.com/PHPCompatibility/PHPCompatibility/issues",
|
| 254 |
-
"source": "https://github.com/PHPCompatibility/PHPCompatibility"
|
| 255 |
-
},
|
| 256 |
-
"time": "2019-12-27T09:44:58+00:00"
|
| 257 |
-
},
|
| 258 |
-
{
|
| 259 |
-
"name": "psr/container",
|
| 260 |
-
"version": "1.1.2",
|
| 261 |
-
"source": {
|
| 262 |
-
"type": "git",
|
| 263 |
-
"url": "https://github.com/php-fig/container.git",
|
| 264 |
-
"reference": "513e0666f7216c7459170d56df27dfcefe1689ea"
|
| 265 |
-
},
|
| 266 |
-
"dist": {
|
| 267 |
-
"type": "zip",
|
| 268 |
-
"url": "https://api.github.com/repos/php-fig/container/zipball/513e0666f7216c7459170d56df27dfcefe1689ea",
|
| 269 |
-
"reference": "513e0666f7216c7459170d56df27dfcefe1689ea",
|
| 270 |
-
"shasum": ""
|
| 271 |
-
},
|
| 272 |
-
"require": {
|
| 273 |
-
"php": ">=7.4.0"
|
| 274 |
-
},
|
| 275 |
-
"type": "library",
|
| 276 |
-
"autoload": {
|
| 277 |
-
"psr-4": {
|
| 278 |
-
"Psr\\Container\\": "src/"
|
| 279 |
-
}
|
| 280 |
-
},
|
| 281 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 282 |
-
"license": [
|
| 283 |
-
"MIT"
|
| 284 |
-
],
|
| 285 |
-
"authors": [
|
| 286 |
-
{
|
| 287 |
-
"name": "PHP-FIG",
|
| 288 |
-
"homepage": "https://www.php-fig.org/"
|
| 289 |
-
}
|
| 290 |
-
],
|
| 291 |
-
"description": "Common Container Interface (PHP FIG PSR-11)",
|
| 292 |
-
"homepage": "https://github.com/php-fig/container",
|
| 293 |
-
"keywords": [
|
| 294 |
-
"PSR-11",
|
| 295 |
-
"container",
|
| 296 |
-
"container-interface",
|
| 297 |
-
"container-interop",
|
| 298 |
-
"psr"
|
| 299 |
-
],
|
| 300 |
-
"support": {
|
| 301 |
-
"issues": "https://github.com/php-fig/container/issues",
|
| 302 |
-
"source": "https://github.com/php-fig/container/tree/1.1.2"
|
| 303 |
-
},
|
| 304 |
-
"time": "2021-11-05T16:50:12+00:00"
|
| 305 |
-
},
|
| 306 |
-
{
|
| 307 |
-
"name": "publishpress/publishpress-phpcs-standards",
|
| 308 |
-
"version": "dev-main",
|
| 309 |
-
"source": {
|
| 310 |
-
"type": "git",
|
| 311 |
-
"url": "https://github.com/publishpress/publishpress-phpcs-standards.git",
|
| 312 |
-
"reference": "295d46f2fdb9945f34ebfd34914e92d22d479330"
|
| 313 |
-
},
|
| 314 |
-
"dist": {
|
| 315 |
-
"type": "zip",
|
| 316 |
-
"url": "https://api.github.com/repos/publishpress/publishpress-phpcs-standards/zipball/295d46f2fdb9945f34ebfd34914e92d22d479330",
|
| 317 |
-
"reference": "295d46f2fdb9945f34ebfd34914e92d22d479330",
|
| 318 |
-
"shasum": ""
|
| 319 |
-
},
|
| 320 |
-
"require": {
|
| 321 |
-
"php": ">=5.6.20"
|
| 322 |
-
},
|
| 323 |
-
"require-dev": {
|
| 324 |
-
"dealerdirect/phpcodesniffer-composer-installer": "*",
|
| 325 |
-
"friendsofphp/php-cs-fixer": "^3.4",
|
| 326 |
-
"overtrue/phplint": "^2.1",
|
| 327 |
-
"phpcompatibility/php-compatibility": "*",
|
| 328 |
-
"phpmd/phpmd": "^2.8",
|
| 329 |
-
"sebastian/phpcpd": "^5.0",
|
| 330 |
-
"spatie/ray": "*",
|
| 331 |
-
"spatie/wordpress-ray": "dev-patch-1",
|
| 332 |
-
"squizlabs/php_codesniffer": "^3.5",
|
| 333 |
-
"vimeo/psalm": "^4.17"
|
| 334 |
-
},
|
| 335 |
-
"default-branch": true,
|
| 336 |
-
"type": "library",
|
| 337 |
-
"scripts": {
|
| 338 |
-
"post-install-cmd": [
|
| 339 |
-
"vendor/bin/phpcs --config-set installed_paths standards/PublishPressStandards"
|
| 340 |
-
],
|
| 341 |
-
"post-update-cmd": [
|
| 342 |
-
"vendor/bin/phpcs --config-set installed_paths standards/PublishPressStandards"
|
| 343 |
-
]
|
| 344 |
-
},
|
| 345 |
-
"license": [
|
| 346 |
-
"GPL-3.0-or-later"
|
| 347 |
-
],
|
| 348 |
-
"authors": [
|
| 349 |
-
{
|
| 350 |
-
"name": "PublishPress",
|
| 351 |
-
"email": "help@publishpress.com",
|
| 352 |
-
"homepage": "https://publishpress.com",
|
| 353 |
-
"role": "Developer"
|
| 354 |
-
}
|
| 355 |
-
],
|
| 356 |
-
"support": {
|
| 357 |
-
"source": "https://github.com/publishpress/publishpress-phpcs-standards/tree/main",
|
| 358 |
-
"issues": "https://github.com/publishpress/publishpress-phpcs-standards/issues"
|
| 359 |
-
},
|
| 360 |
-
"time": "2022-06-24T19:58:54+00:00"
|
| 361 |
-
},
|
| 362 |
-
{
|
| 363 |
-
"name": "ramsey/collection",
|
| 364 |
-
"version": "1.2.2",
|
| 365 |
-
"source": {
|
| 366 |
-
"type": "git",
|
| 367 |
-
"url": "https://github.com/ramsey/collection.git",
|
| 368 |
-
"reference": "cccc74ee5e328031b15640b51056ee8d3bb66c0a"
|
| 369 |
-
},
|
| 370 |
-
"dist": {
|
| 371 |
-
"type": "zip",
|
| 372 |
-
"url": "https://api.github.com/repos/ramsey/collection/zipball/cccc74ee5e328031b15640b51056ee8d3bb66c0a",
|
| 373 |
-
"reference": "cccc74ee5e328031b15640b51056ee8d3bb66c0a",
|
| 374 |
-
"shasum": ""
|
| 375 |
-
},
|
| 376 |
-
"require": {
|
| 377 |
-
"php": "^7.3 || ^8",
|
| 378 |
-
"symfony/polyfill-php81": "^1.23"
|
| 379 |
-
},
|
| 380 |
-
"require-dev": {
|
| 381 |
-
"captainhook/captainhook": "^5.3",
|
| 382 |
-
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.0",
|
| 383 |
-
"ergebnis/composer-normalize": "^2.6",
|
| 384 |
-
"fakerphp/faker": "^1.5",
|
| 385 |
-
"hamcrest/hamcrest-php": "^2",
|
| 386 |
-
"jangregor/phpstan-prophecy": "^0.8",
|
| 387 |
-
"mockery/mockery": "^1.3",
|
| 388 |
-
"phpspec/prophecy-phpunit": "^2.0",
|
| 389 |
-
"phpstan/extension-installer": "^1",
|
| 390 |
-
"phpstan/phpstan": "^0.12.32",
|
| 391 |
-
"phpstan/phpstan-mockery": "^0.12.5",
|
| 392 |
-
"phpstan/phpstan-phpunit": "^0.12.11",
|
| 393 |
-
"phpunit/phpunit": "^8.5 || ^9",
|
| 394 |
-
"psy/psysh": "^0.10.4",
|
| 395 |
-
"slevomat/coding-standard": "^6.3",
|
| 396 |
-
"squizlabs/php_codesniffer": "^3.5",
|
| 397 |
-
"vimeo/psalm": "^4.4"
|
| 398 |
-
},
|
| 399 |
-
"type": "library",
|
| 400 |
-
"autoload": {
|
| 401 |
-
"psr-4": {
|
| 402 |
-
"Ramsey\\Collection\\": "src/"
|
| 403 |
-
}
|
| 404 |
-
},
|
| 405 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 406 |
-
"license": [
|
| 407 |
-
"MIT"
|
| 408 |
-
],
|
| 409 |
-
"authors": [
|
| 410 |
-
{
|
| 411 |
-
"name": "Ben Ramsey",
|
| 412 |
-
"email": "ben@benramsey.com",
|
| 413 |
-
"homepage": "https://benramsey.com"
|
| 414 |
-
}
|
| 415 |
-
],
|
| 416 |
-
"description": "A PHP library for representing and manipulating collections.",
|
| 417 |
-
"keywords": [
|
| 418 |
-
"array",
|
| 419 |
-
"collection",
|
| 420 |
-
"hash",
|
| 421 |
-
"map",
|
| 422 |
-
"queue",
|
| 423 |
-
"set"
|
| 424 |
-
],
|
| 425 |
-
"support": {
|
| 426 |
-
"issues": "https://github.com/ramsey/collection/issues",
|
| 427 |
-
"source": "https://github.com/ramsey/collection/tree/1.2.2"
|
| 428 |
-
},
|
| 429 |
-
"funding": [
|
| 430 |
-
{
|
| 431 |
-
"url": "https://github.com/ramsey",
|
| 432 |
-
"type": "github"
|
| 433 |
-
},
|
| 434 |
-
{
|
| 435 |
-
"url": "https://tidelift.com/funding/github/packagist/ramsey/collection",
|
| 436 |
-
"type": "tidelift"
|
| 437 |
-
}
|
| 438 |
-
],
|
| 439 |
-
"time": "2021-10-10T03:01:02+00:00"
|
| 440 |
-
},
|
| 441 |
-
{
|
| 442 |
-
"name": "ramsey/uuid",
|
| 443 |
-
"version": "4.2.3",
|
| 444 |
-
"source": {
|
| 445 |
-
"type": "git",
|
| 446 |
-
"url": "https://github.com/ramsey/uuid.git",
|
| 447 |
-
"reference": "fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df"
|
| 448 |
-
},
|
| 449 |
-
"dist": {
|
| 450 |
-
"type": "zip",
|
| 451 |
-
"url": "https://api.github.com/repos/ramsey/uuid/zipball/fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df",
|
| 452 |
-
"reference": "fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df",
|
| 453 |
-
"shasum": ""
|
| 454 |
-
},
|
| 455 |
-
"require": {
|
| 456 |
-
"brick/math": "^0.8 || ^0.9",
|
| 457 |
-
"ext-json": "*",
|
| 458 |
-
"php": "^7.2 || ^8.0",
|
| 459 |
-
"ramsey/collection": "^1.0",
|
| 460 |
-
"symfony/polyfill-ctype": "^1.8",
|
| 461 |
-
"symfony/polyfill-php80": "^1.14"
|
| 462 |
-
},
|
| 463 |
-
"replace": {
|
| 464 |
-
"rhumsaa/uuid": "self.version"
|
| 465 |
-
},
|
| 466 |
-
"require-dev": {
|
| 467 |
-
"captainhook/captainhook": "^5.10",
|
| 468 |
-
"captainhook/plugin-composer": "^5.3",
|
| 469 |
-
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.0",
|
| 470 |
-
"doctrine/annotations": "^1.8",
|
| 471 |
-
"ergebnis/composer-normalize": "^2.15",
|
| 472 |
-
"mockery/mockery": "^1.3",
|
| 473 |
-
"moontoast/math": "^1.1",
|
| 474 |
-
"paragonie/random-lib": "^2",
|
| 475 |
-
"php-mock/php-mock": "^2.2",
|
| 476 |
-
"php-mock/php-mock-mockery": "^1.3",
|
| 477 |
-
"php-parallel-lint/php-parallel-lint": "^1.1",
|
| 478 |
-
"phpbench/phpbench": "^1.0",
|
| 479 |
-
"phpstan/extension-installer": "^1.0",
|
| 480 |
-
"phpstan/phpstan": "^0.12",
|
| 481 |
-
"phpstan/phpstan-mockery": "^0.12",
|
| 482 |
-
"phpstan/phpstan-phpunit": "^0.12",
|
| 483 |
-
"phpunit/phpunit": "^8.5 || ^9",
|
| 484 |
-
"slevomat/coding-standard": "^7.0",
|
| 485 |
-
"squizlabs/php_codesniffer": "^3.5",
|
| 486 |
-
"vimeo/psalm": "^4.9"
|
| 487 |
-
},
|
| 488 |
-
"suggest": {
|
| 489 |
-
"ext-bcmath": "Enables faster math with arbitrary-precision integers using BCMath.",
|
| 490 |
-
"ext-ctype": "Enables faster processing of character classification using ctype functions.",
|
| 491 |
-
"ext-gmp": "Enables faster math with arbitrary-precision integers using GMP.",
|
| 492 |
-
"ext-uuid": "Enables the use of PeclUuidTimeGenerator and PeclUuidRandomGenerator.",
|
| 493 |
-
"paragonie/random-lib": "Provides RandomLib for use with the RandomLibAdapter",
|
| 494 |
-
"ramsey/uuid-doctrine": "Allows the use of Ramsey\\Uuid\\Uuid as Doctrine field type."
|
| 495 |
-
},
|
| 496 |
-
"type": "library",
|
| 497 |
-
"extra": {
|
| 498 |
-
"branch-alias": {
|
| 499 |
-
"dev-main": "4.x-dev"
|
| 500 |
-
},
|
| 501 |
-
"captainhook": {
|
| 502 |
-
"force-install": true
|
| 503 |
-
}
|
| 504 |
-
},
|
| 505 |
-
"autoload": {
|
| 506 |
-
"files": [
|
| 507 |
-
"src/functions.php"
|
| 508 |
-
],
|
| 509 |
-
"psr-4": {
|
| 510 |
-
"Ramsey\\Uuid\\": "src/"
|
| 511 |
-
}
|
| 512 |
-
},
|
| 513 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 514 |
-
"license": [
|
| 515 |
-
"MIT"
|
| 516 |
-
],
|
| 517 |
-
"description": "A PHP library for generating and working with universally unique identifiers (UUIDs).",
|
| 518 |
-
"keywords": [
|
| 519 |
-
"guid",
|
| 520 |
-
"identifier",
|
| 521 |
-
"uuid"
|
| 522 |
-
],
|
| 523 |
-
"support": {
|
| 524 |
-
"issues": "https://github.com/ramsey/uuid/issues",
|
| 525 |
-
"source": "https://github.com/ramsey/uuid/tree/4.2.3"
|
| 526 |
-
},
|
| 527 |
-
"funding": [
|
| 528 |
-
{
|
| 529 |
-
"url": "https://github.com/ramsey",
|
| 530 |
-
"type": "github"
|
| 531 |
-
},
|
| 532 |
-
{
|
| 533 |
-
"url": "https://tidelift.com/funding/github/packagist/ramsey/uuid",
|
| 534 |
-
"type": "tidelift"
|
| 535 |
-
}
|
| 536 |
-
],
|
| 537 |
-
"time": "2021-09-25T23:10:38+00:00"
|
| 538 |
-
},
|
| 539 |
-
{
|
| 540 |
-
"name": "spatie/backtrace",
|
| 541 |
-
"version": "1.2.1",
|
| 542 |
-
"source": {
|
| 543 |
-
"type": "git",
|
| 544 |
-
"url": "https://github.com/spatie/backtrace.git",
|
| 545 |
-
"reference": "4ee7d41aa5268107906ea8a4d9ceccde136dbd5b"
|
| 546 |
-
},
|
| 547 |
-
"dist": {
|
| 548 |
-
"type": "zip",
|
| 549 |
-
"url": "https://api.github.com/repos/spatie/backtrace/zipball/4ee7d41aa5268107906ea8a4d9ceccde136dbd5b",
|
| 550 |
-
"reference": "4ee7d41aa5268107906ea8a4d9ceccde136dbd5b",
|
| 551 |
-
"shasum": ""
|
| 552 |
-
},
|
| 553 |
-
"require": {
|
| 554 |
-
"php": "^7.3|^8.0"
|
| 555 |
-
},
|
| 556 |
-
"require-dev": {
|
| 557 |
-
"ext-json": "*",
|
| 558 |
-
"phpunit/phpunit": "^9.3",
|
| 559 |
-
"symfony/var-dumper": "^5.1"
|
| 560 |
-
},
|
| 561 |
-
"type": "library",
|
| 562 |
-
"autoload": {
|
| 563 |
-
"psr-4": {
|
| 564 |
-
"Spatie\\Backtrace\\": "src"
|
| 565 |
-
}
|
| 566 |
-
},
|
| 567 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 568 |
-
"license": [
|
| 569 |
-
"MIT"
|
| 570 |
-
],
|
| 571 |
-
"authors": [
|
| 572 |
-
{
|
| 573 |
-
"name": "Freek Van de Herten",
|
| 574 |
-
"email": "freek@spatie.be",
|
| 575 |
-
"homepage": "https://spatie.be",
|
| 576 |
-
"role": "Developer"
|
| 577 |
-
}
|
| 578 |
-
],
|
| 579 |
-
"description": "A better backtrace",
|
| 580 |
-
"homepage": "https://github.com/spatie/backtrace",
|
| 581 |
-
"keywords": [
|
| 582 |
-
"Backtrace",
|
| 583 |
-
"spatie"
|
| 584 |
-
],
|
| 585 |
-
"support": {
|
| 586 |
-
"issues": "https://github.com/spatie/backtrace/issues",
|
| 587 |
-
"source": "https://github.com/spatie/backtrace/tree/1.2.1"
|
| 588 |
-
},
|
| 589 |
-
"funding": [
|
| 590 |
-
{
|
| 591 |
-
"url": "https://github.com/sponsors/spatie",
|
| 592 |
-
"type": "github"
|
| 593 |
-
},
|
| 594 |
-
{
|
| 595 |
-
"url": "https://spatie.be/open-source/support-us",
|
| 596 |
-
"type": "other"
|
| 597 |
-
}
|
| 598 |
-
],
|
| 599 |
-
"time": "2021-11-09T10:57:15+00:00"
|
| 600 |
-
},
|
| 601 |
-
{
|
| 602 |
-
"name": "spatie/macroable",
|
| 603 |
-
"version": "1.0.1",
|
| 604 |
-
"source": {
|
| 605 |
-
"type": "git",
|
| 606 |
-
"url": "https://github.com/spatie/macroable.git",
|
| 607 |
-
"reference": "7a99549fc001c925714b329220dea680c04bfa48"
|
| 608 |
-
},
|
| 609 |
-
"dist": {
|
| 610 |
-
"type": "zip",
|
| 611 |
-
"url": "https://api.github.com/repos/spatie/macroable/zipball/7a99549fc001c925714b329220dea680c04bfa48",
|
| 612 |
-
"reference": "7a99549fc001c925714b329220dea680c04bfa48",
|
| 613 |
-
"shasum": ""
|
| 614 |
-
},
|
| 615 |
-
"require": {
|
| 616 |
-
"php": "^7.2|^8.0"
|
| 617 |
-
},
|
| 618 |
-
"require-dev": {
|
| 619 |
-
"phpunit/phpunit": "^8.0|^9.3"
|
| 620 |
-
},
|
| 621 |
-
"type": "library",
|
| 622 |
-
"autoload": {
|
| 623 |
-
"psr-4": {
|
| 624 |
-
"Spatie\\Macroable\\": "src"
|
| 625 |
-
}
|
| 626 |
-
},
|
| 627 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 628 |
-
"license": [
|
| 629 |
-
"MIT"
|
| 630 |
-
],
|
| 631 |
-
"authors": [
|
| 632 |
-
{
|
| 633 |
-
"name": "Freek Van der Herten",
|
| 634 |
-
"email": "freek@spatie.be",
|
| 635 |
-
"homepage": "https://spatie.be",
|
| 636 |
-
"role": "Developer"
|
| 637 |
-
}
|
| 638 |
-
],
|
| 639 |
-
"description": "A trait to dynamically add methods to a class",
|
| 640 |
-
"homepage": "https://github.com/spatie/macroable",
|
| 641 |
-
"keywords": [
|
| 642 |
-
"macroable",
|
| 643 |
-
"spatie"
|
| 644 |
-
],
|
| 645 |
-
"support": {
|
| 646 |
-
"issues": "https://github.com/spatie/macroable/issues",
|
| 647 |
-
"source": "https://github.com/spatie/macroable/tree/1.0.1"
|
| 648 |
-
},
|
| 649 |
-
"time": "2020-11-03T10:15:05+00:00"
|
| 650 |
-
},
|
| 651 |
-
{
|
| 652 |
-
"name": "spatie/ray",
|
| 653 |
-
"version": "1.34.5",
|
| 654 |
-
"source": {
|
| 655 |
-
"type": "git",
|
| 656 |
-
"url": "https://github.com/spatie/ray.git",
|
| 657 |
-
"reference": "2d64ea264eecbdc7ec01e4e8b45978cae80815d2"
|
| 658 |
-
},
|
| 659 |
-
"dist": {
|
| 660 |
-
"type": "zip",
|
| 661 |
-
"url": "https://api.github.com/repos/spatie/ray/zipball/2d64ea264eecbdc7ec01e4e8b45978cae80815d2",
|
| 662 |
-
"reference": "2d64ea264eecbdc7ec01e4e8b45978cae80815d2",
|
| 663 |
-
"shasum": ""
|
| 664 |
-
},
|
| 665 |
-
"require": {
|
| 666 |
-
"ext-curl": "*",
|
| 667 |
-
"ext-json": "*",
|
| 668 |
-
"php": "^7.3|^8.0",
|
| 669 |
-
"ramsey/uuid": "^3.0|^4.1",
|
| 670 |
-
"spatie/backtrace": "^1.1",
|
| 671 |
-
"spatie/macroable": "^1.0|^2.0",
|
| 672 |
-
"symfony/stopwatch": "^4.0|^5.1|^6.0",
|
| 673 |
-
"symfony/var-dumper": "^4.2|^5.1|^6.0"
|
| 674 |
-
},
|
| 675 |
-
"require-dev": {
|
| 676 |
-
"illuminate/support": "6.x|^8.18|^9.0",
|
| 677 |
-
"nesbot/carbon": "^2.43",
|
| 678 |
-
"phpstan/phpstan": "^0.12.92",
|
| 679 |
-
"phpunit/phpunit": "^9.5",
|
| 680 |
-
"spatie/phpunit-snapshot-assertions": "^4.2",
|
| 681 |
-
"spatie/test-time": "^1.2"
|
| 682 |
-
},
|
| 683 |
-
"type": "library",
|
| 684 |
-
"autoload": {
|
| 685 |
-
"files": [
|
| 686 |
-
"src/helpers.php"
|
| 687 |
-
],
|
| 688 |
-
"psr-4": {
|
| 689 |
-
"Spatie\\Ray\\": "src"
|
| 690 |
-
}
|
| 691 |
-
},
|
| 692 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 693 |
-
"license": [
|
| 694 |
-
"MIT"
|
| 695 |
-
],
|
| 696 |
-
"authors": [
|
| 697 |
-
{
|
| 698 |
-
"name": "Freek Van der Herten",
|
| 699 |
-
"email": "freek@spatie.be",
|
| 700 |
-
"homepage": "https://spatie.be",
|
| 701 |
-
"role": "Developer"
|
| 702 |
-
}
|
| 703 |
-
],
|
| 704 |
-
"description": "Debug with Ray to fix problems faster",
|
| 705 |
-
"homepage": "https://github.com/spatie/ray",
|
| 706 |
-
"keywords": [
|
| 707 |
-
"ray",
|
| 708 |
-
"spatie"
|
| 709 |
-
],
|
| 710 |
-
"support": {
|
| 711 |
-
"issues": "https://github.com/spatie/ray/issues",
|
| 712 |
-
"source": "https://github.com/spatie/ray/tree/1.34.5"
|
| 713 |
-
},
|
| 714 |
-
"funding": [
|
| 715 |
-
{
|
| 716 |
-
"url": "https://github.com/sponsors/spatie",
|
| 717 |
-
"type": "github"
|
| 718 |
-
},
|
| 719 |
-
{
|
| 720 |
-
"url": "https://spatie.be/open-source/support-us",
|
| 721 |
-
"type": "other"
|
| 722 |
-
}
|
| 723 |
-
],
|
| 724 |
-
"time": "2022-06-03T12:32:57+00:00"
|
| 725 |
-
},
|
| 726 |
-
{
|
| 727 |
-
"name": "spatie/wordpress-ray",
|
| 728 |
-
"version": "dev-patch-1",
|
| 729 |
-
"source": {
|
| 730 |
-
"type": "git",
|
| 731 |
-
"url": "https://github.com/andergmartins/wordpress-ray.git",
|
| 732 |
-
"reference": "965cfdc86dd3fe4c21bc7cfe60618bbbf07fd465"
|
| 733 |
-
},
|
| 734 |
-
"dist": {
|
| 735 |
-
"type": "zip",
|
| 736 |
-
"url": "https://api.github.com/repos/andergmartins/wordpress-ray/zipball/965cfdc86dd3fe4c21bc7cfe60618bbbf07fd465",
|
| 737 |
-
"reference": "965cfdc86dd3fe4c21bc7cfe60618bbbf07fd465",
|
| 738 |
-
"shasum": ""
|
| 739 |
-
},
|
| 740 |
-
"require": {
|
| 741 |
-
"php": "^7.3|^8.0",
|
| 742 |
-
"spatie/backtrace": "^1.2.0",
|
| 743 |
-
"spatie/ray": "^1.33.2"
|
| 744 |
-
},
|
| 745 |
-
"require-dev": {
|
| 746 |
-
"bamarni/composer-bin-plugin": "^1.4",
|
| 747 |
-
"composer/installers": "^1.9",
|
| 748 |
-
"phpunit/phpunit": "^9.5"
|
| 749 |
-
},
|
| 750 |
-
"type": "wordpress-plugin",
|
| 751 |
-
"autoload": {
|
| 752 |
-
"psr-4": {
|
| 753 |
-
"Spatie\\WordPressRay\\": "src"
|
| 754 |
-
}
|
| 755 |
-
},
|
| 756 |
-
"autoload-dev": {
|
| 757 |
-
"psr-4": {
|
| 758 |
-
"Spatie\\WordPressRay\\Tests\\": "tests"
|
| 759 |
-
}
|
| 760 |
-
},
|
| 761 |
-
"scripts": {
|
| 762 |
-
"psalm": [
|
| 763 |
-
"vendor/bin/psalm"
|
| 764 |
-
],
|
| 765 |
-
"test": [
|
| 766 |
-
"vendor/bin/phpunit"
|
| 767 |
-
],
|
| 768 |
-
"test-coverage": [
|
| 769 |
-
"vendor/bin/phpunit --coverage-html coverage"
|
| 770 |
-
],
|
| 771 |
-
"format": [
|
| 772 |
-
"vendor/bin/php-cs-fixer fix --allow-risky=yes"
|
| 773 |
-
]
|
| 774 |
-
},
|
| 775 |
-
"license": [
|
| 776 |
-
"MIT"
|
| 777 |
-
],
|
| 778 |
-
"authors": [
|
| 779 |
-
{
|
| 780 |
-
"name": "Freek Van der Herten",
|
| 781 |
-
"email": "freek@spatie.be",
|
| 782 |
-
"homepage": "https://spatie.be",
|
| 783 |
-
"role": "Developer"
|
| 784 |
-
}
|
| 785 |
-
],
|
| 786 |
-
"description": "Debug WordPress apps with ease",
|
| 787 |
-
"homepage": "https://github.com/spatie/wordpress-ray",
|
| 788 |
-
"keywords": [
|
| 789 |
-
"debugging",
|
| 790 |
-
"ray",
|
| 791 |
-
"spatie"
|
| 792 |
-
],
|
| 793 |
-
"support": {
|
| 794 |
-
"source": "https://github.com/andergmartins/wordpress-ray/tree/patch-1"
|
| 795 |
-
},
|
| 796 |
-
"funding": [
|
| 797 |
-
{
|
| 798 |
-
"type": "github",
|
| 799 |
-
"url": "https://github.com/sponsors/spatie"
|
| 800 |
-
}
|
| 801 |
-
],
|
| 802 |
-
"time": "2022-06-23T14:06:17+00:00"
|
| 803 |
-
},
|
| 804 |
-
{
|
| 805 |
-
"name": "squizlabs/php_codesniffer",
|
| 806 |
-
"version": "3.7.1",
|
| 807 |
-
"source": {
|
| 808 |
-
"type": "git",
|
| 809 |
-
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
|
| 810 |
-
"reference": "1359e176e9307e906dc3d890bcc9603ff6d90619"
|
| 811 |
-
},
|
| 812 |
-
"dist": {
|
| 813 |
-
"type": "zip",
|
| 814 |
-
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/1359e176e9307e906dc3d890bcc9603ff6d90619",
|
| 815 |
-
"reference": "1359e176e9307e906dc3d890bcc9603ff6d90619",
|
| 816 |
-
"shasum": ""
|
| 817 |
-
},
|
| 818 |
-
"require": {
|
| 819 |
-
"ext-simplexml": "*",
|
| 820 |
-
"ext-tokenizer": "*",
|
| 821 |
-
"ext-xmlwriter": "*",
|
| 822 |
-
"php": ">=5.4.0"
|
| 823 |
-
},
|
| 824 |
-
"require-dev": {
|
| 825 |
-
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
|
| 826 |
-
},
|
| 827 |
-
"bin": [
|
| 828 |
-
"bin/phpcs",
|
| 829 |
-
"bin/phpcbf"
|
| 830 |
-
],
|
| 831 |
-
"type": "library",
|
| 832 |
-
"extra": {
|
| 833 |
-
"branch-alias": {
|
| 834 |
-
"dev-master": "3.x-dev"
|
| 835 |
-
}
|
| 836 |
-
},
|
| 837 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 838 |
-
"license": [
|
| 839 |
-
"BSD-3-Clause"
|
| 840 |
-
],
|
| 841 |
-
"authors": [
|
| 842 |
-
{
|
| 843 |
-
"name": "Greg Sherwood",
|
| 844 |
-
"role": "lead"
|
| 845 |
-
}
|
| 846 |
-
],
|
| 847 |
-
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
|
| 848 |
-
"homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
|
| 849 |
-
"keywords": [
|
| 850 |
-
"phpcs",
|
| 851 |
-
"standards"
|
| 852 |
-
],
|
| 853 |
-
"support": {
|
| 854 |
-
"issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
|
| 855 |
-
"source": "https://github.com/squizlabs/PHP_CodeSniffer",
|
| 856 |
-
"wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
|
| 857 |
-
},
|
| 858 |
-
"time": "2022-06-18T07:21:10+00:00"
|
| 859 |
-
},
|
| 860 |
-
{
|
| 861 |
-
"name": "symfony/deprecation-contracts",
|
| 862 |
-
"version": "v2.5.2",
|
| 863 |
-
"source": {
|
| 864 |
-
"type": "git",
|
| 865 |
-
"url": "https://github.com/symfony/deprecation-contracts.git",
|
| 866 |
-
"reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66"
|
| 867 |
-
},
|
| 868 |
-
"dist": {
|
| 869 |
-
"type": "zip",
|
| 870 |
-
"url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
|
| 871 |
-
"reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
|
| 872 |
-
"shasum": ""
|
| 873 |
-
},
|
| 874 |
-
"require": {
|
| 875 |
-
"php": ">=7.1"
|
| 876 |
-
},
|
| 877 |
-
"type": "library",
|
| 878 |
-
"extra": {
|
| 879 |
-
"branch-alias": {
|
| 880 |
-
"dev-main": "2.5-dev"
|
| 881 |
-
},
|
| 882 |
-
"thanks": {
|
| 883 |
-
"name": "symfony/contracts",
|
| 884 |
-
"url": "https://github.com/symfony/contracts"
|
| 885 |
-
}
|
| 886 |
-
},
|
| 887 |
-
"autoload": {
|
| 888 |
-
"files": [
|
| 889 |
-
"function.php"
|
| 890 |
-
]
|
| 891 |
-
},
|
| 892 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 893 |
-
"license": [
|
| 894 |
-
"MIT"
|
| 895 |
-
],
|
| 896 |
-
"authors": [
|
| 897 |
-
{
|
| 898 |
-
"name": "Nicolas Grekas",
|
| 899 |
-
"email": "p@tchwork.com"
|
| 900 |
-
},
|
| 901 |
-
{
|
| 902 |
-
"name": "Symfony Community",
|
| 903 |
-
"homepage": "https://symfony.com/contributors"
|
| 904 |
-
}
|
| 905 |
-
],
|
| 906 |
-
"description": "A generic function and convention to trigger deprecation notices",
|
| 907 |
-
"homepage": "https://symfony.com",
|
| 908 |
-
"support": {
|
| 909 |
-
"source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.2"
|
| 910 |
-
},
|
| 911 |
-
"funding": [
|
| 912 |
-
{
|
| 913 |
-
"url": "https://symfony.com/sponsor",
|
| 914 |
-
"type": "custom"
|
| 915 |
-
},
|
| 916 |
-
{
|
| 917 |
-
"url": "https://github.com/fabpot",
|
| 918 |
-
"type": "github"
|
| 919 |
-
},
|
| 920 |
-
{
|
| 921 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 922 |
-
"type": "tidelift"
|
| 923 |
-
}
|
| 924 |
-
],
|
| 925 |
-
"time": "2022-01-02T09:53:40+00:00"
|
| 926 |
-
},
|
| 927 |
-
{
|
| 928 |
-
"name": "symfony/polyfill-ctype",
|
| 929 |
-
"version": "v1.26.0",
|
| 930 |
-
"source": {
|
| 931 |
-
"type": "git",
|
| 932 |
-
"url": "https://github.com/symfony/polyfill-ctype.git",
|
| 933 |
-
"reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4"
|
| 934 |
-
},
|
| 935 |
-
"dist": {
|
| 936 |
-
"type": "zip",
|
| 937 |
-
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4",
|
| 938 |
-
"reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4",
|
| 939 |
-
"shasum": ""
|
| 940 |
-
},
|
| 941 |
-
"require": {
|
| 942 |
-
"php": ">=7.1"
|
| 943 |
-
},
|
| 944 |
-
"provide": {
|
| 945 |
-
"ext-ctype": "*"
|
| 946 |
-
},
|
| 947 |
-
"suggest": {
|
| 948 |
-
"ext-ctype": "For best performance"
|
| 949 |
-
},
|
| 950 |
-
"type": "library",
|
| 951 |
-
"extra": {
|
| 952 |
-
"branch-alias": {
|
| 953 |
-
"dev-main": "1.26-dev"
|
| 954 |
-
},
|
| 955 |
-
"thanks": {
|
| 956 |
-
"name": "symfony/polyfill",
|
| 957 |
-
"url": "https://github.com/symfony/polyfill"
|
| 958 |
-
}
|
| 959 |
-
},
|
| 960 |
-
"autoload": {
|
| 961 |
-
"files": [
|
| 962 |
-
"bootstrap.php"
|
| 963 |
-
],
|
| 964 |
-
"psr-4": {
|
| 965 |
-
"Symfony\\Polyfill\\Ctype\\": ""
|
| 966 |
-
}
|
| 967 |
-
},
|
| 968 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 969 |
-
"license": [
|
| 970 |
-
"MIT"
|
| 971 |
-
],
|
| 972 |
-
"authors": [
|
| 973 |
-
{
|
| 974 |
-
"name": "Gert de Pagter",
|
| 975 |
-
"email": "BackEndTea@gmail.com"
|
| 976 |
-
},
|
| 977 |
-
{
|
| 978 |
-
"name": "Symfony Community",
|
| 979 |
-
"homepage": "https://symfony.com/contributors"
|
| 980 |
-
}
|
| 981 |
-
],
|
| 982 |
-
"description": "Symfony polyfill for ctype functions",
|
| 983 |
-
"homepage": "https://symfony.com",
|
| 984 |
-
"keywords": [
|
| 985 |
-
"compatibility",
|
| 986 |
-
"ctype",
|
| 987 |
-
"polyfill",
|
| 988 |
-
"portable"
|
| 989 |
-
],
|
| 990 |
-
"support": {
|
| 991 |
-
"source": "https://github.com/symfony/polyfill-ctype/tree/v1.26.0"
|
| 992 |
-
},
|
| 993 |
-
"funding": [
|
| 994 |
-
{
|
| 995 |
-
"url": "https://symfony.com/sponsor",
|
| 996 |
-
"type": "custom"
|
| 997 |
-
},
|
| 998 |
-
{
|
| 999 |
-
"url": "https://github.com/fabpot",
|
| 1000 |
-
"type": "github"
|
| 1001 |
-
},
|
| 1002 |
-
{
|
| 1003 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1004 |
-
"type": "tidelift"
|
| 1005 |
-
}
|
| 1006 |
-
],
|
| 1007 |
-
"time": "2022-05-24T11:49:31+00:00"
|
| 1008 |
-
},
|
| 1009 |
-
{
|
| 1010 |
-
"name": "symfony/polyfill-mbstring",
|
| 1011 |
-
"version": "v1.26.0",
|
| 1012 |
-
"source": {
|
| 1013 |
-
"type": "git",
|
| 1014 |
-
"url": "https://github.com/symfony/polyfill-mbstring.git",
|
| 1015 |
-
"reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e"
|
| 1016 |
-
},
|
| 1017 |
-
"dist": {
|
| 1018 |
-
"type": "zip",
|
| 1019 |
-
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e",
|
| 1020 |
-
"reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e",
|
| 1021 |
-
"shasum": ""
|
| 1022 |
-
},
|
| 1023 |
-
"require": {
|
| 1024 |
-
"php": ">=7.1"
|
| 1025 |
-
},
|
| 1026 |
-
"provide": {
|
| 1027 |
-
"ext-mbstring": "*"
|
| 1028 |
-
},
|
| 1029 |
-
"suggest": {
|
| 1030 |
-
"ext-mbstring": "For best performance"
|
| 1031 |
-
},
|
| 1032 |
-
"type": "library",
|
| 1033 |
-
"extra": {
|
| 1034 |
-
"branch-alias": {
|
| 1035 |
-
"dev-main": "1.26-dev"
|
| 1036 |
-
},
|
| 1037 |
-
"thanks": {
|
| 1038 |
-
"name": "symfony/polyfill",
|
| 1039 |
-
"url": "https://github.com/symfony/polyfill"
|
| 1040 |
-
}
|
| 1041 |
-
},
|
| 1042 |
-
"autoload": {
|
| 1043 |
-
"files": [
|
| 1044 |
-
"bootstrap.php"
|
| 1045 |
-
],
|
| 1046 |
-
"psr-4": {
|
| 1047 |
-
"Symfony\\Polyfill\\Mbstring\\": ""
|
| 1048 |
-
}
|
| 1049 |
-
},
|
| 1050 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1051 |
-
"license": [
|
| 1052 |
-
"MIT"
|
| 1053 |
-
],
|
| 1054 |
-
"authors": [
|
| 1055 |
-
{
|
| 1056 |
-
"name": "Nicolas Grekas",
|
| 1057 |
-
"email": "p@tchwork.com"
|
| 1058 |
-
},
|
| 1059 |
-
{
|
| 1060 |
-
"name": "Symfony Community",
|
| 1061 |
-
"homepage": "https://symfony.com/contributors"
|
| 1062 |
-
}
|
| 1063 |
-
],
|
| 1064 |
-
"description": "Symfony polyfill for the Mbstring extension",
|
| 1065 |
-
"homepage": "https://symfony.com",
|
| 1066 |
-
"keywords": [
|
| 1067 |
-
"compatibility",
|
| 1068 |
-
"mbstring",
|
| 1069 |
-
"polyfill",
|
| 1070 |
-
"portable",
|
| 1071 |
-
"shim"
|
| 1072 |
-
],
|
| 1073 |
-
"support": {
|
| 1074 |
-
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.26.0"
|
| 1075 |
-
},
|
| 1076 |
-
"funding": [
|
| 1077 |
-
{
|
| 1078 |
-
"url": "https://symfony.com/sponsor",
|
| 1079 |
-
"type": "custom"
|
| 1080 |
-
},
|
| 1081 |
-
{
|
| 1082 |
-
"url": "https://github.com/fabpot",
|
| 1083 |
-
"type": "github"
|
| 1084 |
-
},
|
| 1085 |
-
{
|
| 1086 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1087 |
-
"type": "tidelift"
|
| 1088 |
-
}
|
| 1089 |
-
],
|
| 1090 |
-
"time": "2022-05-24T11:49:31+00:00"
|
| 1091 |
-
},
|
| 1092 |
-
{
|
| 1093 |
-
"name": "symfony/polyfill-php80",
|
| 1094 |
-
"version": "v1.26.0",
|
| 1095 |
-
"source": {
|
| 1096 |
-
"type": "git",
|
| 1097 |
-
"url": "https://github.com/symfony/polyfill-php80.git",
|
| 1098 |
-
"reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace"
|
| 1099 |
-
},
|
| 1100 |
-
"dist": {
|
| 1101 |
-
"type": "zip",
|
| 1102 |
-
"url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace",
|
| 1103 |
-
"reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace",
|
| 1104 |
-
"shasum": ""
|
| 1105 |
-
},
|
| 1106 |
-
"require": {
|
| 1107 |
-
"php": ">=7.1"
|
| 1108 |
-
},
|
| 1109 |
-
"type": "library",
|
| 1110 |
-
"extra": {
|
| 1111 |
-
"branch-alias": {
|
| 1112 |
-
"dev-main": "1.26-dev"
|
| 1113 |
-
},
|
| 1114 |
-
"thanks": {
|
| 1115 |
-
"name": "symfony/polyfill",
|
| 1116 |
-
"url": "https://github.com/symfony/polyfill"
|
| 1117 |
-
}
|
| 1118 |
-
},
|
| 1119 |
-
"autoload": {
|
| 1120 |
-
"files": [
|
| 1121 |
-
"bootstrap.php"
|
| 1122 |
-
],
|
| 1123 |
-
"psr-4": {
|
| 1124 |
-
"Symfony\\Polyfill\\Php80\\": ""
|
| 1125 |
-
},
|
| 1126 |
-
"classmap": [
|
| 1127 |
-
"Resources/stubs"
|
| 1128 |
-
]
|
| 1129 |
-
},
|
| 1130 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1131 |
-
"license": [
|
| 1132 |
-
"MIT"
|
| 1133 |
-
],
|
| 1134 |
-
"authors": [
|
| 1135 |
-
{
|
| 1136 |
-
"name": "Ion Bazan",
|
| 1137 |
-
"email": "ion.bazan@gmail.com"
|
| 1138 |
-
},
|
| 1139 |
-
{
|
| 1140 |
-
"name": "Nicolas Grekas",
|
| 1141 |
-
"email": "p@tchwork.com"
|
| 1142 |
-
},
|
| 1143 |
-
{
|
| 1144 |
-
"name": "Symfony Community",
|
| 1145 |
-
"homepage": "https://symfony.com/contributors"
|
| 1146 |
-
}
|
| 1147 |
-
],
|
| 1148 |
-
"description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions",
|
| 1149 |
-
"homepage": "https://symfony.com",
|
| 1150 |
-
"keywords": [
|
| 1151 |
-
"compatibility",
|
| 1152 |
-
"polyfill",
|
| 1153 |
-
"portable",
|
| 1154 |
-
"shim"
|
| 1155 |
-
],
|
| 1156 |
-
"support": {
|
| 1157 |
-
"source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0"
|
| 1158 |
-
},
|
| 1159 |
-
"funding": [
|
| 1160 |
-
{
|
| 1161 |
-
"url": "https://symfony.com/sponsor",
|
| 1162 |
-
"type": "custom"
|
| 1163 |
-
},
|
| 1164 |
-
{
|
| 1165 |
-
"url": "https://github.com/fabpot",
|
| 1166 |
-
"type": "github"
|
| 1167 |
-
},
|
| 1168 |
-
{
|
| 1169 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1170 |
-
"type": "tidelift"
|
| 1171 |
-
}
|
| 1172 |
-
],
|
| 1173 |
-
"time": "2022-05-10T07:21:04+00:00"
|
| 1174 |
-
},
|
| 1175 |
-
{
|
| 1176 |
-
"name": "symfony/polyfill-php81",
|
| 1177 |
-
"version": "v1.26.0",
|
| 1178 |
-
"source": {
|
| 1179 |
-
"type": "git",
|
| 1180 |
-
"url": "https://github.com/symfony/polyfill-php81.git",
|
| 1181 |
-
"reference": "13f6d1271c663dc5ae9fb843a8f16521db7687a1"
|
| 1182 |
-
},
|
| 1183 |
-
"dist": {
|
| 1184 |
-
"type": "zip",
|
| 1185 |
-
"url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/13f6d1271c663dc5ae9fb843a8f16521db7687a1",
|
| 1186 |
-
"reference": "13f6d1271c663dc5ae9fb843a8f16521db7687a1",
|
| 1187 |
-
"shasum": ""
|
| 1188 |
-
},
|
| 1189 |
-
"require": {
|
| 1190 |
-
"php": ">=7.1"
|
| 1191 |
-
},
|
| 1192 |
-
"type": "library",
|
| 1193 |
-
"extra": {
|
| 1194 |
-
"branch-alias": {
|
| 1195 |
-
"dev-main": "1.26-dev"
|
| 1196 |
-
},
|
| 1197 |
-
"thanks": {
|
| 1198 |
-
"name": "symfony/polyfill",
|
| 1199 |
-
"url": "https://github.com/symfony/polyfill"
|
| 1200 |
-
}
|
| 1201 |
-
},
|
| 1202 |
-
"autoload": {
|
| 1203 |
-
"files": [
|
| 1204 |
-
"bootstrap.php"
|
| 1205 |
-
],
|
| 1206 |
-
"psr-4": {
|
| 1207 |
-
"Symfony\\Polyfill\\Php81\\": ""
|
| 1208 |
-
},
|
| 1209 |
-
"classmap": [
|
| 1210 |
-
"Resources/stubs"
|
| 1211 |
-
]
|
| 1212 |
-
},
|
| 1213 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1214 |
-
"license": [
|
| 1215 |
-
"MIT"
|
| 1216 |
-
],
|
| 1217 |
-
"authors": [
|
| 1218 |
-
{
|
| 1219 |
-
"name": "Nicolas Grekas",
|
| 1220 |
-
"email": "p@tchwork.com"
|
| 1221 |
-
},
|
| 1222 |
-
{
|
| 1223 |
-
"name": "Symfony Community",
|
| 1224 |
-
"homepage": "https://symfony.com/contributors"
|
| 1225 |
-
}
|
| 1226 |
-
],
|
| 1227 |
-
"description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions",
|
| 1228 |
-
"homepage": "https://symfony.com",
|
| 1229 |
-
"keywords": [
|
| 1230 |
-
"compatibility",
|
| 1231 |
-
"polyfill",
|
| 1232 |
-
"portable",
|
| 1233 |
-
"shim"
|
| 1234 |
-
],
|
| 1235 |
-
"support": {
|
| 1236 |
-
"source": "https://github.com/symfony/polyfill-php81/tree/v1.26.0"
|
| 1237 |
-
},
|
| 1238 |
-
"funding": [
|
| 1239 |
-
{
|
| 1240 |
-
"url": "https://symfony.com/sponsor",
|
| 1241 |
-
"type": "custom"
|
| 1242 |
-
},
|
| 1243 |
-
{
|
| 1244 |
-
"url": "https://github.com/fabpot",
|
| 1245 |
-
"type": "github"
|
| 1246 |
-
},
|
| 1247 |
-
{
|
| 1248 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1249 |
-
"type": "tidelift"
|
| 1250 |
-
}
|
| 1251 |
-
],
|
| 1252 |
-
"time": "2022-05-24T11:49:31+00:00"
|
| 1253 |
-
},
|
| 1254 |
-
{
|
| 1255 |
-
"name": "symfony/service-contracts",
|
| 1256 |
-
"version": "v2.5.2",
|
| 1257 |
-
"source": {
|
| 1258 |
-
"type": "git",
|
| 1259 |
-
"url": "https://github.com/symfony/service-contracts.git",
|
| 1260 |
-
"reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c"
|
| 1261 |
-
},
|
| 1262 |
-
"dist": {
|
| 1263 |
-
"type": "zip",
|
| 1264 |
-
"url": "https://api.github.com/repos/symfony/service-contracts/zipball/4b426aac47d6427cc1a1d0f7e2ac724627f5966c",
|
| 1265 |
-
"reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c",
|
| 1266 |
-
"shasum": ""
|
| 1267 |
-
},
|
| 1268 |
-
"require": {
|
| 1269 |
-
"php": ">=7.2.5",
|
| 1270 |
-
"psr/container": "^1.1",
|
| 1271 |
-
"symfony/deprecation-contracts": "^2.1|^3"
|
| 1272 |
-
},
|
| 1273 |
-
"conflict": {
|
| 1274 |
-
"ext-psr": "<1.1|>=2"
|
| 1275 |
-
},
|
| 1276 |
-
"suggest": {
|
| 1277 |
-
"symfony/service-implementation": ""
|
| 1278 |
-
},
|
| 1279 |
-
"type": "library",
|
| 1280 |
-
"extra": {
|
| 1281 |
-
"branch-alias": {
|
| 1282 |
-
"dev-main": "2.5-dev"
|
| 1283 |
-
},
|
| 1284 |
-
"thanks": {
|
| 1285 |
-
"name": "symfony/contracts",
|
| 1286 |
-
"url": "https://github.com/symfony/contracts"
|
| 1287 |
-
}
|
| 1288 |
-
},
|
| 1289 |
-
"autoload": {
|
| 1290 |
-
"psr-4": {
|
| 1291 |
-
"Symfony\\Contracts\\Service\\": ""
|
| 1292 |
-
}
|
| 1293 |
-
},
|
| 1294 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1295 |
-
"license": [
|
| 1296 |
-
"MIT"
|
| 1297 |
-
],
|
| 1298 |
-
"authors": [
|
| 1299 |
-
{
|
| 1300 |
-
"name": "Nicolas Grekas",
|
| 1301 |
-
"email": "p@tchwork.com"
|
| 1302 |
-
},
|
| 1303 |
-
{
|
| 1304 |
-
"name": "Symfony Community",
|
| 1305 |
-
"homepage": "https://symfony.com/contributors"
|
| 1306 |
-
}
|
| 1307 |
-
],
|
| 1308 |
-
"description": "Generic abstractions related to writing services",
|
| 1309 |
-
"homepage": "https://symfony.com",
|
| 1310 |
-
"keywords": [
|
| 1311 |
-
"abstractions",
|
| 1312 |
-
"contracts",
|
| 1313 |
-
"decoupling",
|
| 1314 |
-
"interfaces",
|
| 1315 |
-
"interoperability",
|
| 1316 |
-
"standards"
|
| 1317 |
-
],
|
| 1318 |
-
"support": {
|
| 1319 |
-
"source": "https://github.com/symfony/service-contracts/tree/v2.5.2"
|
| 1320 |
-
},
|
| 1321 |
-
"funding": [
|
| 1322 |
-
{
|
| 1323 |
-
"url": "https://symfony.com/sponsor",
|
| 1324 |
-
"type": "custom"
|
| 1325 |
-
},
|
| 1326 |
-
{
|
| 1327 |
-
"url": "https://github.com/fabpot",
|
| 1328 |
-
"type": "github"
|
| 1329 |
-
},
|
| 1330 |
-
{
|
| 1331 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1332 |
-
"type": "tidelift"
|
| 1333 |
-
}
|
| 1334 |
-
],
|
| 1335 |
-
"time": "2022-05-30T19:17:29+00:00"
|
| 1336 |
-
},
|
| 1337 |
-
{
|
| 1338 |
-
"name": "symfony/stopwatch",
|
| 1339 |
-
"version": "v5.4.5",
|
| 1340 |
-
"source": {
|
| 1341 |
-
"type": "git",
|
| 1342 |
-
"url": "https://github.com/symfony/stopwatch.git",
|
| 1343 |
-
"reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30"
|
| 1344 |
-
},
|
| 1345 |
-
"dist": {
|
| 1346 |
-
"type": "zip",
|
| 1347 |
-
"url": "https://api.github.com/repos/symfony/stopwatch/zipball/4d04b5c24f3c9a1a168a131f6cbe297155bc0d30",
|
| 1348 |
-
"reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30",
|
| 1349 |
-
"shasum": ""
|
| 1350 |
-
},
|
| 1351 |
-
"require": {
|
| 1352 |
-
"php": ">=7.2.5",
|
| 1353 |
-
"symfony/service-contracts": "^1|^2|^3"
|
| 1354 |
-
},
|
| 1355 |
-
"type": "library",
|
| 1356 |
-
"autoload": {
|
| 1357 |
-
"psr-4": {
|
| 1358 |
-
"Symfony\\Component\\Stopwatch\\": ""
|
| 1359 |
-
},
|
| 1360 |
-
"exclude-from-classmap": [
|
| 1361 |
-
"/Tests/"
|
| 1362 |
-
]
|
| 1363 |
-
},
|
| 1364 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1365 |
-
"license": [
|
| 1366 |
-
"MIT"
|
| 1367 |
-
],
|
| 1368 |
-
"authors": [
|
| 1369 |
-
{
|
| 1370 |
-
"name": "Fabien Potencier",
|
| 1371 |
-
"email": "fabien@symfony.com"
|
| 1372 |
-
},
|
| 1373 |
-
{
|
| 1374 |
-
"name": "Symfony Community",
|
| 1375 |
-
"homepage": "https://symfony.com/contributors"
|
| 1376 |
-
}
|
| 1377 |
-
],
|
| 1378 |
-
"description": "Provides a way to profile code",
|
| 1379 |
-
"homepage": "https://symfony.com",
|
| 1380 |
-
"support": {
|
| 1381 |
-
"source": "https://github.com/symfony/stopwatch/tree/v5.4.5"
|
| 1382 |
-
},
|
| 1383 |
-
"funding": [
|
| 1384 |
-
{
|
| 1385 |
-
"url": "https://symfony.com/sponsor",
|
| 1386 |
-
"type": "custom"
|
| 1387 |
-
},
|
| 1388 |
-
{
|
| 1389 |
-
"url": "https://github.com/fabpot",
|
| 1390 |
-
"type": "github"
|
| 1391 |
-
},
|
| 1392 |
-
{
|
| 1393 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1394 |
-
"type": "tidelift"
|
| 1395 |
-
}
|
| 1396 |
-
],
|
| 1397 |
-
"time": "2022-02-18T16:06:09+00:00"
|
| 1398 |
-
},
|
| 1399 |
-
{
|
| 1400 |
-
"name": "symfony/var-dumper",
|
| 1401 |
-
"version": "v5.4.9",
|
| 1402 |
-
"source": {
|
| 1403 |
-
"type": "git",
|
| 1404 |
-
"url": "https://github.com/symfony/var-dumper.git",
|
| 1405 |
-
"reference": "af52239a330fafd192c773795520dc2dd62b5657"
|
| 1406 |
-
},
|
| 1407 |
-
"dist": {
|
| 1408 |
-
"type": "zip",
|
| 1409 |
-
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/af52239a330fafd192c773795520dc2dd62b5657",
|
| 1410 |
-
"reference": "af52239a330fafd192c773795520dc2dd62b5657",
|
| 1411 |
-
"shasum": ""
|
| 1412 |
-
},
|
| 1413 |
-
"require": {
|
| 1414 |
-
"php": ">=7.2.5",
|
| 1415 |
-
"symfony/polyfill-mbstring": "~1.0",
|
| 1416 |
-
"symfony/polyfill-php80": "^1.16"
|
| 1417 |
-
},
|
| 1418 |
-
"conflict": {
|
| 1419 |
-
"phpunit/phpunit": "<5.4.3",
|
| 1420 |
-
"symfony/console": "<4.4"
|
| 1421 |
-
},
|
| 1422 |
-
"require-dev": {
|
| 1423 |
-
"ext-iconv": "*",
|
| 1424 |
-
"symfony/console": "^4.4|^5.0|^6.0",
|
| 1425 |
-
"symfony/process": "^4.4|^5.0|^6.0",
|
| 1426 |
-
"symfony/uid": "^5.1|^6.0",
|
| 1427 |
-
"twig/twig": "^2.13|^3.0.4"
|
| 1428 |
-
},
|
| 1429 |
-
"suggest": {
|
| 1430 |
-
"ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).",
|
| 1431 |
-
"ext-intl": "To show region name in time zone dump",
|
| 1432 |
-
"symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script"
|
| 1433 |
-
},
|
| 1434 |
-
"bin": [
|
| 1435 |
-
"Resources/bin/var-dump-server"
|
| 1436 |
-
],
|
| 1437 |
-
"type": "library",
|
| 1438 |
-
"autoload": {
|
| 1439 |
-
"files": [
|
| 1440 |
-
"Resources/functions/dump.php"
|
| 1441 |
-
],
|
| 1442 |
-
"psr-4": {
|
| 1443 |
-
"Symfony\\Component\\VarDumper\\": ""
|
| 1444 |
-
},
|
| 1445 |
-
"exclude-from-classmap": [
|
| 1446 |
-
"/Tests/"
|
| 1447 |
-
]
|
| 1448 |
-
},
|
| 1449 |
-
"notification-url": "https://packagist.org/downloads/",
|
| 1450 |
-
"license": [
|
| 1451 |
-
"MIT"
|
| 1452 |
-
],
|
| 1453 |
-
"authors": [
|
| 1454 |
-
{
|
| 1455 |
-
"name": "Nicolas Grekas",
|
| 1456 |
-
"email": "p@tchwork.com"
|
| 1457 |
-
},
|
| 1458 |
-
{
|
| 1459 |
-
"name": "Symfony Community",
|
| 1460 |
-
"homepage": "https://symfony.com/contributors"
|
| 1461 |
-
}
|
| 1462 |
-
],
|
| 1463 |
-
"description": "Provides mechanisms for walking through any arbitrary PHP variable",
|
| 1464 |
-
"homepage": "https://symfony.com",
|
| 1465 |
-
"keywords": [
|
| 1466 |
-
"debug",
|
| 1467 |
-
"dump"
|
| 1468 |
-
],
|
| 1469 |
-
"support": {
|
| 1470 |
-
"source": "https://github.com/symfony/var-dumper/tree/v5.4.9"
|
| 1471 |
-
},
|
| 1472 |
-
"funding": [
|
| 1473 |
-
{
|
| 1474 |
-
"url": "https://symfony.com/sponsor",
|
| 1475 |
-
"type": "custom"
|
| 1476 |
-
},
|
| 1477 |
-
{
|
| 1478 |
-
"url": "https://github.com/fabpot",
|
| 1479 |
-
"type": "github"
|
| 1480 |
-
},
|
| 1481 |
-
{
|
| 1482 |
-
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
| 1483 |
-
"type": "tidelift"
|
| 1484 |
-
}
|
| 1485 |
-
],
|
| 1486 |
-
"time": "2022-05-21T10:24:18+00:00"
|
| 1487 |
-
}
|
| 1488 |
-
],
|
| 1489 |
-
"aliases": [],
|
| 1490 |
-
"minimum-stability": "stable",
|
| 1491 |
-
"stability-flags": {
|
| 1492 |
-
"woocommerce/flexslider": 20,
|
| 1493 |
-
"spatie/wordpress-ray": 20,
|
| 1494 |
-
"publishpress/publishpress-phpcs-standards": 20
|
| 1495 |
-
},
|
| 1496 |
-
"prefer-stable": true,
|
| 1497 |
-
"prefer-lowest": false,
|
| 1498 |
-
"platform": {
|
| 1499 |
-
"php": ">=5.6.20"
|
| 1500 |
-
},
|
| 1501 |
-
"platform-dev": [],
|
| 1502 |
-
"plugin-api-version": "2.3.0"
|
| 1503 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
dist/.gitignore
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
| 1 |
+
*
|
| 2 |
+
!.gitignore
|
extendify-sdk/jsconfig.json
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"compilerOptions": {
|
| 3 |
+
"baseUrl": "./",
|
| 4 |
+
"paths": {
|
| 5 |
+
"@extendify/*": ["src/*"]
|
| 6 |
+
}
|
| 7 |
+
}
|
| 8 |
+
}
|
languages/ml-slider-js.pot
DELETED
|
@@ -1,24 +0,0 @@
|
|
| 1 |
-
msgid ""
|
| 2 |
-
msgstr ""
|
| 3 |
-
"Content-Type: text/plain; charset=utf-8\n"
|
| 4 |
-
"X-Generator: babel-plugin-makepot\n"
|
| 5 |
-
|
| 6 |
-
#: admin/assets/js/app/globals.js:107
|
| 7 |
-
msgid "Success"
|
| 8 |
-
msgstr ""
|
| 9 |
-
|
| 10 |
-
#: admin/assets/js/app/globals.js:115
|
| 11 |
-
msgid "Undefined error occurred"
|
| 12 |
-
msgstr ""
|
| 13 |
-
|
| 14 |
-
#: admin/assets/js/app/globals.js:171
|
| 15 |
-
msgid "No error message reported."
|
| 16 |
-
msgstr ""
|
| 17 |
-
|
| 18 |
-
#: admin/assets/js/app/globals.js:90
|
| 19 |
-
msgid "Doing something..."
|
| 20 |
-
msgstr ""
|
| 21 |
-
|
| 22 |
-
#: admin/assets/js/app/globals.js:98
|
| 23 |
-
msgid "No error message provided."
|
| 24 |
-
msgstr ""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
lib/appsero/.gitignore
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
/node_modules
|
| 2 |
+
/public/hot
|
| 3 |
+
/public/storage
|
| 4 |
+
/storage/*.key
|
| 5 |
+
/vendor
|
| 6 |
+
/.idea
|
| 7 |
+
/.vscode
|
| 8 |
+
/nbproject
|
| 9 |
+
/.vagrant
|
| 10 |
+
Homestead.json
|
| 11 |
+
Homestead.yaml
|
| 12 |
+
npm-debug.log
|
| 13 |
+
yarn-error.log
|
| 14 |
+
.env
|
| 15 |
+
.phpunit.result.cache
|
| 16 |
+
.DS_Store
|
lib/htmlpurifier/README.md
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
HTML Purifier [](http://travis-ci.org/ezyang/htmlpurifier)
|
| 2 |
+
=============
|
| 3 |
+
|
| 4 |
+
HTML Purifier is an HTML filtering solution that uses a unique combination
|
| 5 |
+
of robust whitelists and aggressive parsing to ensure that not only are
|
| 6 |
+
XSS attacks thwarted, but the resulting HTML is standards compliant.
|
| 7 |
+
|
| 8 |
+
HTML Purifier is oriented towards richly formatted documents from
|
| 9 |
+
untrusted sources that require CSS and a full tag-set. This library can
|
| 10 |
+
be configured to accept a more restrictive set of tags, but it won't be
|
| 11 |
+
as efficient as more bare-bones parsers. It will, however, do the job
|
| 12 |
+
right, which may be more important.
|
| 13 |
+
|
| 14 |
+
Places to go:
|
| 15 |
+
|
| 16 |
+
* See INSTALL for a quick installation guide
|
| 17 |
+
* See docs/ for developer-oriented documentation, code examples and
|
| 18 |
+
an in-depth installation guide.
|
| 19 |
+
* See WYSIWYG for information on editors like TinyMCE and FCKeditor
|
| 20 |
+
|
| 21 |
+
HTML Purifier can be found on the web at: [http://htmlpurifier.org/](http://htmlpurifier.org/)
|
| 22 |
+
|
| 23 |
+
## Installation
|
| 24 |
+
|
| 25 |
+
Package available on [Composer](https://packagist.org/packages/ezyang/htmlpurifier).
|
| 26 |
+
|
| 27 |
+
If you're using Composer to manage dependencies, you can use
|
| 28 |
+
|
| 29 |
+
$ composer require ezyang/htmlpurifier
|
metagallery/public/build/metagallery-scripts.js
CHANGED
|
@@ -1,21 +1,6345 @@
|
|
| 1 |
-
!
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
*/var t={},e="function"==typeof Map?new Map:null,i="swap",n="move",r="layoutStart",s="layoutEnd",o="layoutAbort",a="remove",h="hideStart",l="filter",u="sort",d="move",c="send",_="beforeSend",f="receive",p="beforeReceive",m="dragReleaseEnd",g="ontouchstart"in window,v=!!window.PointerEvent,y=!!window.navigator.msPointerEnabled;function b(){this._events={},this._queue=[],this._counter=0,this._clearOnEmit=!1}b.prototype.on=function(t,e){if(!this._events||!t||!e)return this;var i=this._events[t];return i||(i=this._events[t]=[]),i.push(e),this},b.prototype.off=function(t,e){if(!this._events||!t||!e)return this;var i,n=this._events[t];if(!n||!n.length)return this;for(;-1!==(i=n.indexOf(e));)n.splice(i,1);return this},b.prototype.clear=function(t){if(!this._events||!t)return this;var e=this._events[t];return e&&(e.length=0,delete this._events[t]),this},b.prototype.emit=function(t){if(!this._events||!t)return this._clearOnEmit=!1,this;var e=this._events[t];if(!e||!e.length)return this._clearOnEmit=!1,this;var i,n=this._queue,r=n.length,s=arguments.length-1;s>3&&((i=[]).push.apply(i,arguments),i.shift()),n.push.apply(n,e),this._clearOnEmit&&(e.length=0,this._clearOnEmit=!1),++this._counter;for(var o=r,a=n.length;o<a;o++)if(0===s?n[o]():1===s?n[o](arguments[1]):2===s?n[o](arguments[1],arguments[2]):3===s?n[o](arguments[1],arguments[2],arguments[3]):n[o].apply(null,i),!this._events)return this;return--this._counter,this._counter||(n.length=0),this},b.prototype.burst=function(){return this._events?(this._clearOnEmit=!0,this.emit.apply(this,arguments),this):this},b.prototype.countListeners=function(t){if(!this._events)return 0;var e=this._events[t];return e?e.length:0},b.prototype.destroy=function(){return this._events?(this._queue.length=this._counter=0,this._events=null,this):this};var w=v?"pointerout":y?"MSPointerOut":"";function S(t){w&&(this._dragger=t,this._timeout=null,this._outEvent=null,this._isActive=!1,this._addBehaviour=this._addBehaviour.bind(this),this._removeBehaviour=this._removeBehaviour.bind(this),this._onTimeout=this._onTimeout.bind(this),this._resetData=this._resetData.bind(this),this._onStart=this._onStart.bind(this),this._onOut=this._onOut.bind(this),this._dragger.on("start",this._onStart))}S.prototype._addBehaviour=function(){this._isActive||(this._isActive=!0,this._dragger.on("move",this._resetData),this._dragger.on("cancel",this._removeBehaviour),this._dragger.on("end",this._removeBehaviour),window.addEventListener(w,this._onOut))},S.prototype._removeBehaviour=function(){this._isActive&&(this._dragger.off("move",this._resetData),this._dragger.off("cancel",this._removeBehaviour),this._dragger.off("end",this._removeBehaviour),window.removeEventListener(w,this._onOut),this._resetData(),this._isActive=!1)},S.prototype._resetData=function(){window.clearTimeout(this._timeout),this._timeout=null,this._outEvent=null},S.prototype._onStart=function(t){"mouse"!==t.pointerType&&this._addBehaviour()},S.prototype._onOut=function(t){this._dragger._getTrackedTouch(t)&&(this._resetData(),this._outEvent=t,this._timeout=window.setTimeout(this._onTimeout,100))},S.prototype._onTimeout=function(){var t=this._outEvent;this._resetData(),this._dragger.isActive()&&this._dragger._onCancel(t)},S.prototype.destroy=function(){w&&(this._dragger.off("start",this._onStart),this._removeBehaviour())};var T=["","webkit","moz","ms","o","Webkit","Moz","MS","O"],D={};function x(t,e){var i=D[e]||"";if(i)return i;for(var n=e[0].toUpperCase()+e.slice(1),r=0;r<T.length;){if((i=T[r]?T[r]+n:e)in t)return D[e]=i,i;++r}return""}function A(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("testPassive",null,e),window.removeEventListener("testPassive",null,e)}catch(t){}return t}var k=window.navigator.userAgent.toLowerCase(),E=k.indexOf("edge")>-1,R=k.indexOf("trident")>-1,L=k.indexOf("firefox")>-1,P=k.indexOf("android")>-1,M=!!A()&&{passive:!0},I="touchAction",C=x(document.documentElement.style,I);function N(t,e){this._element=t,this._emitter=new b,this._isDestroyed=!1,this._cssProps={},this._touchAction="",this._isActive=!1,this._pointerId=null,this._startTime=0,this._startX=0,this._startY=0,this._currentX=0,this._currentY=0,this._onStart=this._onStart.bind(this),this._onMove=this._onMove.bind(this),this._onCancel=this._onCancel.bind(this),this._onEnd=this._onEnd.bind(this),this._edgeHack=null,(E||R)&&(v||y)&&(this._edgeHack=new S(this)),this.setCssProps(e),this._touchAction||this.setTouchAction("auto"),t.addEventListener("dragstart",N._preventDefault,!1),t.addEventListener(N._inputEvents.start,this._onStart,M)}N._pointerEvents={start:"pointerdown",move:"pointermove",cancel:"pointercancel",end:"pointerup"},N._msPointerEvents={start:"MSPointerDown",move:"MSPointerMove",cancel:"MSPointerCancel",end:"MSPointerUp"},N._touchEvents={start:"touchstart",move:"touchmove",cancel:"touchcancel",end:"touchend"},N._mouseEvents={start:"mousedown",move:"mousemove",cancel:"",end:"mouseup"},N._inputEvents=g?N._touchEvents:v?N._pointerEvents:y?N._msPointerEvents:N._mouseEvents,N._emitter=new b,N._emitterEvents={start:"start",move:"move",end:"end",cancel:"cancel"},N._activeInstances=[],N._preventDefault=function(t){t.preventDefault&&!1!==t.cancelable&&t.preventDefault()},N._activateInstance=function(t){N._activeInstances.indexOf(t)>-1||(N._activeInstances.push(t),N._emitter.on(N._emitterEvents.move,t._onMove),N._emitter.on(N._emitterEvents.cancel,t._onCancel),N._emitter.on(N._emitterEvents.end,t._onEnd),1===N._activeInstances.length&&N._bindListeners())},N._deactivateInstance=function(t){var e=N._activeInstances.indexOf(t);-1!==e&&(N._activeInstances.splice(e,1),N._emitter.off(N._emitterEvents.move,t._onMove),N._emitter.off(N._emitterEvents.cancel,t._onCancel),N._emitter.off(N._emitterEvents.end,t._onEnd),N._activeInstances.length||N._unbindListeners())},N._bindListeners=function(){window.addEventListener(N._inputEvents.move,N._onMove,M),window.addEventListener(N._inputEvents.end,N._onEnd,M),N._inputEvents.cancel&&window.addEventListener(N._inputEvents.cancel,N._onCancel,M)},N._unbindListeners=function(){window.removeEventListener(N._inputEvents.move,N._onMove,M),window.removeEventListener(N._inputEvents.end,N._onEnd,M),N._inputEvents.cancel&&window.removeEventListener(N._inputEvents.cancel,N._onCancel,M)},N._getEventPointerId=function(t){return"number"==typeof t.pointerId?t.pointerId:t.changedTouches?t.changedTouches[0]?t.changedTouches[0].identifier:null:1},N._getTouchById=function(t,e){if("number"==typeof t.pointerId)return t.pointerId===e?t:null;if(t.changedTouches){for(var i=0;i<t.changedTouches.length;i++)if(t.changedTouches[i].identifier===e)return t.changedTouches[i];return null}return t},N._onMove=function(t){N._emitter.emit(N._emitterEvents.move,t)},N._onCancel=function(t){N._emitter.emit(N._emitterEvents.cancel,t)},N._onEnd=function(t){N._emitter.emit(N._emitterEvents.end,t)},N.prototype._reset=function(){this._pointerId=null,this._startTime=0,this._startX=0,this._startY=0,this._currentX=0,this._currentY=0,this._isActive=!1,N._deactivateInstance(this)},N.prototype._createEvent=function(t,e){var i=this._getTrackedTouch(e);return{type:t,srcEvent:e,distance:this.getDistance(),deltaX:this.getDeltaX(),deltaY:this.getDeltaY(),deltaTime:t===N._emitterEvents.start?0:this.getDeltaTime(),isFirst:t===N._emitterEvents.start,isFinal:t===N._emitterEvents.end||t===N._emitterEvents.cancel,pointerType:e.pointerType||(e.touches?"touch":"mouse"),identifier:this._pointerId,screenX:i.screenX,screenY:i.screenY,clientX:i.clientX,clientY:i.clientY,pageX:i.pageX,pageY:i.pageY,target:i.target}},N.prototype._emit=function(t,e){this._emitter.emit(t,this._createEvent(t,e))},N.prototype._getTrackedTouch=function(t){return null===this._pointerId?null:N._getTouchById(t,this._pointerId)},N.prototype._onStart=function(t){if(!this._isDestroyed&&null===this._pointerId&&(this._pointerId=N._getEventPointerId(t),null!==this._pointerId)){var e=this._getTrackedTouch(t);this._startX=this._currentX=e.clientX,this._startY=this._currentY=e.clientY,this._startTime=Date.now(),this._isActive=!0,this._emit(N._emitterEvents.start,t),this._isActive&&N._activateInstance(this)}},N.prototype._onMove=function(t){var e=this._getTrackedTouch(t);e&&(this._currentX=e.clientX,this._currentY=e.clientY,this._emit(N._emitterEvents.move,t))},N.prototype._onCancel=function(t){this._getTrackedTouch(t)&&(this._emit(N._emitterEvents.cancel,t),this._reset())},N.prototype._onEnd=function(t){this._getTrackedTouch(t)&&(this._emit(N._emitterEvents.end,t),this._reset())},N.prototype.isActive=function(){return this._isActive},N.prototype.setTouchAction=function(t){this._touchAction=t,C&&(this._cssProps[C]="",this._element.style[C]=t),g&&(this._element.removeEventListener(N._touchEvents.start,N._preventDefault,!0),(this._element.style[C]!==t||L&&P)&&this._element.addEventListener(N._touchEvents.start,N._preventDefault,!0))},N.prototype.setCssProps=function(t){if(t){var e,i,n=this._cssProps,r=this._element;for(e in n)r.style[e]=n[e],delete n[e];for(e in t)t[e]&&(e!==I?(i=x(r.style,e))&&(n[i]="",r.style[i]=t[e]):this.setTouchAction(t[e]))}},N.prototype.getDeltaX=function(){return this._currentX-this._startX},N.prototype.getDeltaY=function(){return this._currentY-this._startY},N.prototype.getDistance=function(){var t=this.getDeltaX(),e=this.getDeltaY();return Math.sqrt(t*t+e*e)},N.prototype.getDeltaTime=function(){return this._startTime?Date.now()-this._startTime:0},N.prototype.on=function(t,e){this._emitter.on(t,e)},N.prototype.off=function(t,e){this._emitter.off(t,e)},N.prototype.destroy=function(){if(!this._isDestroyed){var t=this._element;for(var e in this._edgeHack&&this._edgeHack.destroy(),this._reset(),this._emitter.destroy(),t.removeEventListener(N._inputEvents.start,this._onStart,M),t.removeEventListener("dragstart",N._preventDefault,!1),t.removeEventListener(N._touchEvents.start,N._preventDefault,!0),this._cssProps)t.style[e]=this._cssProps[e],delete this._cssProps[e];this._element=null,this._isDestroyed=!0}};var O=(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return this.setTimeout((function(){t(Date.now())}),16.666666666666668)}).bind(window);function X(t){this._nextStep=null,this._lanes=[],this._stepQueue=[],this._stepCallbacks={},this._step=this._step.bind(this);for(var e=0;e<t;e++)this._lanes.push(new Y)}function Y(){this.queue=[],this.indices={},this.callbacks={}}X.prototype._step=function(t){var e,i,n,r,s,o,a=this._lanes,h=this._stepQueue,l=this._stepCallbacks;for(this._nextStep=null,e=0;e<a.length;e++){for(r=a[e].queue,s=a[e].callbacks,o=a[e].indices,i=0;i<r.length;i++)(n=r[i])&&(h.push(n),l[n]=s[n],delete s[n],delete o[n]);r.length=0}for(e=0;e<h.length;e++)l[n=h[e]]&&l[n](t),delete l[n];h.length=0},X.prototype.add=function(t,e,i){this._lanes[t].add(e,i),this._nextStep||(this._nextStep=O(this._step))},X.prototype.remove=function(t,e){this._lanes[t].remove(e)},Y.prototype.add=function(t,e){var i=this.indices[t];void 0!==i&&(this.queue[i]=void 0),this.queue.push(t),this.callbacks[t]=e,this.indices[t]=this.queue.length-1},Y.prototype.remove=function(t){var e=this.indices[t];void 0!==e&&(this.queue[e]=void 0,delete this.callbacks[t],delete this.indices[t])};var q="layoutRead",H="layoutWrite",F="visibilityRead",W="visibilityWrite",B="dragStartRead",G="dragStartWrite",z="dragMoveRead",V="dragMoveWrite",j="dragScrollRead",U="dragScrollWrite",Q="dragSortRead",K="placeholderLayoutRead",$="placeholderLayoutWrite",Z="placeholderResizeWrite",J="autoScrollRead",tt="autoScrollWrite",et="debounceRead",it=new X(3);function nt(t){it.remove(0,q+t),it.remove(2,H+t)}function rt(t){it.remove(0,F+t),it.remove(2,W+t)}function st(t){it.remove(0,B+t),it.remove(2,G+t)}function ot(t){it.remove(0,z+t),it.remove(2,V+t)}function at(t){it.remove(0,j+t),it.remove(2,U+t)}function ht(t,e){it.add(1,Q+t,e)}function lt(t){it.remove(0,K+t),it.remove(2,$+t)}function ut(t,e){it.add(0,J,t),it.add(2,tt,e)}function dt(t){return"function"==typeof t}var ct,_t="function"==typeof WeakMap,ft=_t?new WeakMap:null,pt=!0,mt=function(){pt?(ct=window.clearInterval(ct),ft=_t?new WeakMap:null):pt=!0};function gt(t,e){var i=ft&&ft.get(t);return i||(i=window.getComputedStyle(t,null),ft&&ft.set(t,i)),ft&&(ct?pt=!1:ct=window.setInterval(mt,3e3)),i.getPropertyValue(e)}function vt(t,e){return parseFloat(gt(t,e))||0}var yt,bt=document.documentElement,wt=document.body,St={value:0,offset:0};function Tt(t){return t===window||t===bt||t===wt?window:t}function Dt(t){return t===window?t.pageXOffset:t.scrollLeft}function xt(t){return t===window?t.pageYOffset:t.scrollTop}function At(t){return t===window?bt.scrollWidth-bt.clientWidth:t.scrollWidth-t.clientWidth}function kt(t){return t===window?bt.scrollHeight-bt.clientHeight:t.scrollHeight-t.clientHeight}function Et(t,e){if(e=e||{},t===window)e.width=bt.clientWidth,e.height=bt.clientHeight,e.left=0,e.right=e.width,e.top=0,e.bottom=e.height;else{var i=t.getBoundingClientRect(),n=t.clientLeft||vt(t,"border-left-width"),r=t.clientTop||vt(t,"border-top-width");e.width=t.clientWidth,e.height=t.clientHeight,e.left=i.left+n,e.right=e.left+e.width,e.top=i.top+r,e.bottom=e.top+e.height}return e}function Rt(t){return t._drag._getGrid()._settings.dragAutoScroll}function Lt(t){t._drag&&t._drag._prepareScroll()}function Pt(t){if(t._drag&&t._isActive){var e=t._drag;e._scrollDiffX=e._scrollDiffY=0,t._setTranslate(e._left,e._top)}}function Mt(t,e,i,n){return St.value=Math.min(n/2,t),St.offset=Math.max(0,i+2*St.value+n*e-n)/2,St}function It(){this.reset()}function Ct(){this.element=null,this.requestX=null,this.requestY=null,this.scrollLeft=0,this.scrollTop=0}function Nt(t,e){this.pool=[],this.createItem=t,this.releaseItem=e}function Ot(t,e){var i=function(t,e){return function(t,e){return!(t.left+t.width<=e.left||e.left+e.width<=t.left||t.top+t.height<=e.top||e.top+e.height<=t.top)}(t,e)?(Math.min(t.left+t.width,e.left+e.width)-Math.max(t.left,e.left))*(Math.min(t.top+t.height,e.top+e.height)-Math.max(t.top,e.top)):0}(t,e);return i?i/(Math.min(t.width,e.width)*Math.min(t.height,e.height))*100:0}It.prototype.reset=function(){this.isActive&&this.onStop(),this.item=null,this.element=null,this.isActive=!1,this.isEnding=!1,this.direction=null,this.value=null,this.maxValue=0,this.threshold=0,this.distance=0,this.speed=0,this.duration=0,this.action=null},It.prototype.hasReachedEnd=function(){return 4&this.direction?this.value>=this.maxValue:this.value<=0},It.prototype.computeCurrentScrollValue=function(){return null===this.value?1&this.direction?Dt(this.element):xt(this.element):Math.max(0,Math.min(this.value,this.maxValue))},It.prototype.computeNextScrollValue=function(t){var e=this.speed*(t/1e3),i=4&this.direction?this.value+e:this.value-e;return Math.max(0,Math.min(i,this.maxValue))},It.prototype.computeSpeed=(yt={direction:null,threshold:0,distance:0,value:0,maxValue:0,deltaTime:0,duration:0,isEnding:!1},function(t){var e=this.item,i=Rt(e).speed;return dt(i)?(yt.direction=this.direction,yt.threshold=this.threshold,yt.distance=this.distance,yt.value=this.value,yt.maxValue=this.maxValue,yt.duration=this.duration,yt.speed=this.speed,yt.deltaTime=t,yt.isEnding=this.isEnding,i(e,this.element,yt)):i}),It.prototype.tick=function(t){return this.isActive||(this.isActive=!0,this.onStart()),this.value=this.computeCurrentScrollValue(),this.speed=this.computeSpeed(t),this.value=this.computeNextScrollValue(t),this.duration+=t,this.value},It.prototype.onStart=function(){var t=this.item,e=Rt(t).onStart;dt(e)&&e(t,this.element,this.direction)},It.prototype.onStop=function(){var t=this.item,e=Rt(t).onStop;dt(e)&&e(t,this.element,this.direction),t._drag&&t._drag.sort()},Ct.prototype.reset=function(){this.requestX&&(this.requestX.action=null),this.requestY&&(this.requestY.action=null),this.element=null,this.requestX=null,this.requestY=null,this.scrollLeft=0,this.scrollTop=0},Ct.prototype.addRequest=function(t){1&t.direction?(this.removeRequest(this.requestX),this.requestX=t):(this.removeRequest(this.requestY),this.requestY=t),t.action=this},Ct.prototype.removeRequest=function(t){t&&(this.requestX===t?(this.requestX=null,t.action=null):this.requestY===t&&(this.requestY=null,t.action=null))},Ct.prototype.computeScrollValues=function(){this.scrollLeft=this.requestX?this.requestX.value:Dt(this.element),this.scrollTop=this.requestY?this.requestY.value:xt(this.element)},Ct.prototype.scroll=function(){var t=this.element;t&&(t.scrollTo?t.scrollTo(this.scrollLeft,this.scrollTop):(t.scrollLeft=this.scrollLeft,t.scrollTop=this.scrollTop))},Nt.prototype.pick=function(){return this.pool.pop()||this.createItem()},Nt.prototype.release=function(t){this.releaseItem(t),-1===this.pool.indexOf(t)&&this.pool.push(t)},Nt.prototype.reset=function(){this.pool.length=0};var Xt={width:0,height:0,left:0,right:0,top:0,bottom:0},Yt={width:0,height:0,left:0,right:0,top:0,bottom:0};function qt(){this._isDestroyed=!1,this._isTicking=!1,this._tickTime=0,this._tickDeltaTime=0,this._items=[],this._actions=[],this._requests={},this._requests[1]={},this._requests[2]={},this._requestOverlapCheck={},this._dragPositions={},this._dragDirections={},this._overlapCheckInterval=150,this._requestPool=new Nt((function(){return new It}),(function(t){t.reset()})),this._actionPool=new Nt((function(){return new Ct}),(function(t){t.reset()})),this._readTick=this._readTick.bind(this),this._writeTick=this._writeTick.bind(this)}qt.AXIS_X=1,qt.AXIS_Y=2,qt.FORWARD=4,qt.BACKWARD=8,qt.LEFT=9,qt.RIGHT=5,qt.UP=10,qt.DOWN=6,qt.smoothSpeed=function(t,e,i){return function(n,r,s){var o=0;if(!s.isEnding)if(s.threshold>0){var a=s.threshold-Math.max(0,s.distance);o=t/s.threshold*a}else o=t;var h=s.speed,l=o;return h===o?l:h<o?(l=h+e*(s.deltaTime/1e3),Math.min(o,l)):(l=h-i*(s.deltaTime/1e3),Math.max(o,l))}},qt.pointerHandle=function(t){var e={left:0,top:0,width:0,height:0},i=t||1;return function(t,n,r,s,o,a,h){return e.left=a-.5*i,e.top=h-.5*i,e.width=i,e.height=i,e}},qt.prototype._readTick=function(t){this._isDestroyed||(t&&this._tickTime?(this._tickDeltaTime=t-this._tickTime,this._tickTime=t,this._updateRequests(),this._updateActions()):(this._tickTime=t,this._tickDeltaTime=0))},qt.prototype._writeTick=function(){this._isDestroyed||(this._applyActions(),ut(this._readTick,this._writeTick))},qt.prototype._startTicking=function(){this._isTicking=!0,ut(this._readTick,this._writeTick)},qt.prototype._stopTicking=function(){this._isTicking=!1,this._tickTime=0,this._tickDeltaTime=0,it.remove(0,J),it.remove(2,tt)},qt.prototype._getItemHandleRect=function(t,e,i){var n=t._drag;if(e){var r=n._dragMoveEvent||n._dragStartEvent,s=e(t,n._clientX,n._clientY,t._width,t._height,r.clientX,r.clientY);i.left=s.left,i.top=s.top,i.width=s.width,i.height=s.height}else i.left=n._clientX,i.top=n._clientY,i.width=t._width,i.height=t._height;return i.right=i.left+i.width,i.bottom=i.top+i.height,i},qt.prototype._requestItemScroll=function(t,e,i,n,r,s,o){var a=this._requests[e],h=a[t._id];h?h.element===i&&h.direction===n||h.reset():h=this._requestPool.pick(),h.item=t,h.element=i,h.direction=n,h.threshold=r,h.distance=s,h.maxValue=o,a[t._id]=h},qt.prototype._cancelItemScroll=function(t,e){var i=this._requests[e],n=i[t._id];n&&(n.action&&n.action.removeRequest(n),this._requestPool.release(n),delete i[t._id])},qt.prototype._checkItemOverlap=function(t,e,i){var n=Rt(t),r=dt(n.targets)?n.targets(t):n.targets,s=n.threshold,o=n.safeZone;if(!r||!r.length)return e&&this._cancelItemScroll(t,1),void(i&&this._cancelItemScroll(t,2));var a=this._dragDirections[t._id],h=a[0],l=a[1];if(!h&&!l)return e&&this._cancelItemScroll(t,1),void(i&&this._cancelItemScroll(t,2));for(var u=this._getItemHandleRect(t,n.handle,Xt),d=Yt,c=null,_=null,f=!0,p=!0,m=0,g=0,v=null,y=null,b=0,w=0,S=0,T=null,D=-1/0,x=0,A=0,k=null,E=0,R=0,L=null,P=-1/0,M=0,I=0,C=null,N=0,O=0,X=0;X<r.length;X++)c=r[X],f=e&&h&&2!==c.axis,p=i&&l&&1!==c.axis,g=c.priority||0,(!f||g<D)&&(!p||g<P)||(_=Tt(c.element||c),w=f?At(_):-1,S=p?kt(_):-1,(w||S)&&((m=Ot(u,d=Et(_,d)))<=0||(f&&g>=D&&w>0&&(g>D||m>A)&&(y=null,v=Mt("number"==typeof c.threshold?c.threshold:s,o,u.width,d.width),5===h?(b=d.right+v.offset-u.right)<=v.value&&Dt(_)<w&&(y=5):9===h&&(b=u.left-(d.left-v.offset))<=v.value&&Dt(_)>0&&(y=9),null!==y&&(T=_,D=g,x=v.value,A=m,k=y,E=b,R=w)),p&&g>=P&&S>0&&(g>P||m>I)&&(y=null,v=Mt("number"==typeof c.threshold?c.threshold:s,o,u.height,d.height),6===l?(b=d.bottom+v.offset-u.bottom)<=v.value&&xt(_)<S&&(y=6):10===l&&(b=u.top-(d.top-v.offset))<=v.value&&xt(_)>0&&(y=10),null!==y&&(L=_,P=g,M=v.value,I=m,C=y,N=b,O=S)))));e&&(T?this._requestItemScroll(t,1,T,k,x,E,R):this._cancelItemScroll(t,1)),i&&(L?this._requestItemScroll(t,2,L,C,M,N,O):this._cancelItemScroll(t,2))},qt.prototype._updateScrollRequest=function(t){for(var e=t.item,i=Rt(e),n=dt(i.targets)?i.targets(e):i.targets,r=n&&n.length||0,s=i.threshold,o=i.safeZone,a=this._getItemHandleRect(e,i.handle,Xt),h=Yt,l=null,u=null,d=!1,c=null,_=null,f=null,p=null,m=null,g=0;g<r;g++)if((u=Tt((l=n[g]).element||l))===t.element){if(d=!!(1&t.direction)){if(2===l.axis)continue}else if(1===l.axis)continue;if((p=d?At(u):kt(u))<=0)break;if(Ot(a,h=Et(u,h))<=0)break;if(c=Mt("number"==typeof l.threshold?l.threshold:s,o,d?a.width:a.height,d?h.width:h.height),(_=9===t.direction?a.left-(h.left-c.offset):5===t.direction?h.right+c.offset-a.right:10===t.direction?a.top-(h.top-c.offset):h.bottom+c.offset-a.bottom)>c.value)break;if(f=d?Dt(u):xt(u),m=4&t.direction?f>=p:f<=0)break;return t.maxValue=p,t.threshold=c.value,t.distance=_,t.isEnding=!1,!0}return!0===i.smoothStop&&t.speed>0?(null===m&&(m=t.hasReachedEnd()),t.isEnding=!m):t.isEnding=!1,t.isEnding},qt.prototype._updateRequests=function(){for(var t,e,i,n,r,s,o,a=this._items,h=this._requests[1],l=this._requests[2],u=0;u<a.length;u++)t=a[u],r=(n=this._requestOverlapCheck[t._id])>0&&this._tickTime-n>this._overlapCheckInterval,s=!0,(e=h[t._id])&&e.isActive&&(s=!this._updateScrollRequest(e))&&(r=!0,this._cancelItemScroll(t,1)),o=!0,(i=l[t._id])&&i.isActive&&(o=!this._updateScrollRequest(i))&&(r=!0,this._cancelItemScroll(t,2)),r&&(this._requestOverlapCheck[t._id]=0,this._checkItemOverlap(t,s,o))},qt.prototype._requestAction=function(t,e){for(var i=this._actions,n=1===e,r=null,s=0;s<i.length;s++){if(r=i[s],t.element===r.element){if(n?r.requestX:r.requestY)return void this._cancelItemScroll(t.item,e);break}r=null}r||(r=this._actionPool.pick()),r.element=t.element,r.addRequest(t),t.tick(this._tickDeltaTime),i.push(r)},qt.prototype._updateActions=function(){var t,e,i,n,r=this._items,s=this._requests,o=this._actions;for(n=0;n<r.length;n++)t=r[n]._id,e=s[1][t],i=s[2][t],e&&this._requestAction(e,1),i&&this._requestAction(i,2);for(n=0;n<o.length;n++)o[n].computeScrollValues()},qt.prototype._applyActions=function(){var t,e=this._actions,i=this._items;if(e.length){for(t=0;t<e.length;t++)e[t].scroll(),this._actionPool.release(e[t]);for(e.length=0,t=0;t<i.length;t++)Lt(i[t]);for(t=0;t<i.length;t++)Pt(i[t])}},qt.prototype._updateDragDirection=function(t){var e=this._dragPositions[t._id],i=this._dragDirections[t._id],n=t._drag._left,r=t._drag._top;if(e.length){var s=e[0],o=e[1];i[0]=n>s?5:n<s?9:i[0]||0,i[1]=r>o?6:r<o?10:i[1]||0}e[0]=n,e[1]=r},qt.prototype.addItem=function(t){this._isDestroyed||-1===this._items.indexOf(t)&&(this._items.push(t),this._requestOverlapCheck[t._id]=this._tickTime,this._dragDirections[t._id]=[0,0],this._dragPositions[t._id]=[],this._isTicking||this._startTicking())},qt.prototype.updateItem=function(t){this._isDestroyed||this._dragDirections[t._id]&&(this._updateDragDirection(t),this._requestOverlapCheck[t._id]||(this._requestOverlapCheck[t._id]=this._tickTime))},qt.prototype.removeItem=function(t){if(!this._isDestroyed){var e=this._items.indexOf(t);if(-1!==e){var i=t._id;this._requests[1][i]&&(this._cancelItemScroll(t,1),delete this._requests[1][i]),this._requests[2][i]&&(this._cancelItemScroll(t,2),delete this._requests[2][i]),delete this._requestOverlapCheck[i],delete this._dragPositions[i],delete this._dragDirections[i],this._items.splice(e,1),this._isTicking&&!this._items.length&&this._stopTicking()}}},qt.prototype.isItemScrollingX=function(t){var e=this._requests[1][t._id];return!(!e||!e.isActive)},qt.prototype.isItemScrollingY=function(t){var e=this._requests[2][t._id];return!(!e||!e.isActive)},qt.prototype.isItemScrolling=function(t){return this.isItemScrollingX(t)||this.isItemScrollingY(t)},qt.prototype.destroy=function(){if(!this._isDestroyed){for(var t=this._items.slice(0),e=0;e<t.length;e++)this.removeItem(t[e]);this._actions.length=0,this._requestPool.reset(),this._actionPool.reset(),this._isDestroyed=!0}};var Ht=window.Element.prototype,Ft=Ht.matches||Ht.matchesSelector||Ht.webkitMatchesSelector||Ht.mozMatchesSelector||Ht.msMatchesSelector||Ht.oMatchesSelector||function(){return!1};function Wt(t,e){return Ft.call(t,e)}function Bt(t,e){e&&(t.classList?t.classList.add(e):Wt(t,"."+e)||(t.className+=" "+e))}var Gt=[];function zt(t,e,i){var n="number"==typeof i?i:-1;n<0&&(n=t.length-n+1),t.splice.apply(t,Gt.concat(n,0,e)),Gt.length=0}function Vt(t,e,i){var n=Math.max(0,t.length-1+(i||0));return e>n?n:e<0?Math.max(n+e+1,0):e}function jt(t,e,i){if(!(t.length<2)){var n=Vt(t,e),r=Vt(t,i);n!==r&&t.splice(r,0,t.splice(n,1)[0])}}function Ut(t,e,i){if(!(t.length<2)){var n,r=Vt(t,e),s=Vt(t,i);r!==s&&(n=t[r],t[r]=t[s],t[s]=n)}}var Qt=x(document.documentElement.style,"transform")||"transform",Kt=/([A-Z])/g,$t=/^(webkit-|moz-|ms-|o-)/,Zt=/^(-m-s-)/;function Jt(t){var e=t.replace(Kt,"-$1").toLowerCase();return e=(e=e.replace($t,"-$1")).replace(Zt,"-ms-")}var te=Jt(Qt);function ee(t){var e=gt(t,te);if(!e||"none"===e)return!1;var i=gt(t,"display");return"inline"!==i&&"none"!==i}function ie(t){for(var e=document,i=t||e;i&&i!==e&&"static"===gt(i,"position")&&!ee(i);)i=i.parentElement||e;return i}var ne={},re={},se={};function oe(t,e){var i,n=e||{};return n.left=0,n.top=0,t===document?n:(n.left=window.pageXOffset||0,n.top=window.pageYOffset||0,t.self===window.self||(i=t.getBoundingClientRect(),n.left+=i.left,n.top+=i.top,n.left+=vt(t,"border-left-width"),n.top+=vt(t,"border-top-width")),n)}function ae(t,e,i){return se.left=0,se.top=0,t===e||i&&(t=ie(t))===(e=ie(e))||(oe(t,ne),oe(e,re),se.left=re.left-ne.left,se.top=re.top-ne.top),se}function he(t){return"auto"===t||"scroll"===t||"overlay"===t}function le(t){return he(gt(t,"overflow"))||he(gt(t,"overflow-x"))||he(gt(t,"overflow-y"))}function ue(t,e){for(e=e||[];t&&t!==document;)t.getRootNode&&t instanceof DocumentFragment?t=t.getRootNode().host:(le(t)&&e.push(t),t=t.parentNode);return e.push(window),e}var de={},ce=/^matrix3d/,_e=/([^,]*,){4}/,fe=/([^,]*,){12}/,pe=/[^,]*,/;function me(t){de.x=0,de.y=0;var e=gt(t,te);if(!e||"none"===e)return de;var i=ce.test(e),n=e.replace(i?fe:_e,""),r=n.replace(pe,"");return de.x=parseFloat(n)||0,de.y=parseFloat(r)||0,de}function ge(t,e){e&&(t.classList?t.classList.remove(e):Wt(t,"."+e)&&(t.className=(" "+t.className+" ").replace(" "+e+" "," ").trim()))}var ve,ye,be,we,Se=/^(iPad|iPhone|iPod)/.test(window.navigator.platform)||/^Mac/.test(window.navigator.platform)&&window.navigator.maxTouchPoints>1,Te=!!A()&&{passive:!0};function De(t){var e=t._element,i=t.getGrid(),n=i._settings;this._item=t,this._gridId=i._id,this._isDestroyed=!1,this._isMigrating=!1,this._startPredicate=dt(n.dragStartPredicate)?n.dragStartPredicate:De.defaultStartPredicate,this._startPredicateState=0,this._startPredicateResult=void 0,this._isSortNeeded=!1,this._sortTimer=void 0,this._blockedSortIndex=null,this._sortX1=0,this._sortX2=0,this._sortY1=0,this._sortY2=0,this._reset(),this._preStartCheck=this._preStartCheck.bind(this),this._preEndCheck=this._preEndCheck.bind(this),this._onScroll=this._onScroll.bind(this),this._prepareStart=this._prepareStart.bind(this),this._applyStart=this._applyStart.bind(this),this._prepareMove=this._prepareMove.bind(this),this._applyMove=this._applyMove.bind(this),this._prepareScroll=this._prepareScroll.bind(this),this._applyScroll=this._applyScroll.bind(this),this._handleSort=this._handleSort.bind(this),this._handleSortDelayed=this._handleSortDelayed.bind(this),this._handle=n.dragHandle&&e.querySelector(n.dragHandle)||e,this._dragger=new N(this._handle,n.dragCssProps),this._dragger.on("start",this._preStartCheck),this._dragger.on("move",this._preStartCheck),this._dragger.on("cancel",this._preEndCheck),this._dragger.on("end",this._preEndCheck)}function xe(t,e){var i,n,r={};if(Array.isArray(e))for(n=0;n<e.length;n++)r[i=e[n]]=gt(t,Jt(i));else for(i in e)r[i]=gt(t,Jt(i));return r}De.autoScroller=new qt,De.defaultStartPredicate=function(t,e,i){var n=t._drag;if(e.isFirst&&e.srcEvent.button)return!1;if(!Se&&e.isFirst&&!0===e.srcEvent.isTrusted&&!1===e.srcEvent.defaultPrevented&&!1===e.srcEvent.cancelable)return!1;if(!e.isFinal){var r=n._startPredicateData;if(!r){var s=i||n._getGrid()._settings.dragStartPredicate||{};n._startPredicateData=r={distance:Math.max(s.distance,0)||0,delay:Math.max(s.delay,0)||0}}return r.delay&&(r.event=e,r.delayTimer||(r.delayTimer=window.setTimeout((function(){r.delay=0,n._resolveStartPredicate(r.event)&&(n._forceResolveStartPredicate(r.event),n._resetStartPredicate())}),r.delay))),n._resolveStartPredicate(e)}n._finishStartPredicate(e)},De.defaultSortPredicate=(ve={},ye={},be={},we=[],function(t,e){var r=t._drag,s=r._getGrid(),o=e&&"number"==typeof e.threshold?e.threshold:50,a=e&&e.action===i?i:n,h=e&&e.migrateAction===i?i:n;o=Math.min(Math.max(o,1),100),ve.width=t._width,ve.height=t._height,ve.left=r._clientX,ve.top=r._clientY;var l=function(t,e,i){var n,r,s,o,a,h,l,u,d,c,_=null,f=e._settings.dragSort,p=-1;if(!0===f?(we[0]=e,r=we):dt(f)&&(r=f.call(e,t)),!r||!Array.isArray(r)||!r.length)return _;for(c=0;c<r.length;c++)if(!(s=r[c])._isDestroyed){for(s._updateBoundingRect(),h=Math.max(0,s._left),l=Math.max(0,s._top),u=Math.min(window.innerWidth,s._right),d=Math.min(window.innerHeight,s._bottom),o=s._element.parentNode;o&&o!==document&&o!==document.documentElement&&o!==document.body;)if(o.getRootNode&&o instanceof DocumentFragment)o=o.getRootNode().host;else{if("visible"!==gt(o,"overflow")&&(a=o.getBoundingClientRect(),h=Math.max(h,a.left),l=Math.max(l,a.top),u=Math.min(u,a.right),d=Math.min(d,a.bottom)),"fixed"===gt(o,"position"))break;o=o.parentNode}h>=u||l>=d||(ye.left=h,ye.top=l,ye.width=u-h,ye.height=d-l,(n=Ot(ve,ye))>i&&n>p&&(p=n,_=s))}return we.length=0,_}(t,s,o);if(!l)return null;var u,d,c,_=t.getGrid()!==l,f=0,p=0,m=0,g=-1,v=!1;for(l===s?(ve.left=r._gridX+t._marginLeft,ve.top=r._gridY+t._marginTop):(l._updateBorders(1,0,1,0),f=l._left+l._borderLeft,p=l._top+l._borderTop),c=0;c<l._items.length;c++)(u=l._items[c])._isActive&&u!==t&&(v=!0,ye.width=u._width,ye.height=u._height,ye.left=u._left+u._marginLeft+f,ye.top=u._top+u._marginTop+p,(d=Ot(ve,ye))>m&&(g=c,m=d));return _&&m<o&&(g=v?g:0,m=o),m>=o?(be.grid=l,be.index=g,be.action=_?h:a,be):null}),De.prototype.stop=function(){if(this._isActive)if(this._isMigrating)this._finishMigration();else{De.autoScroller.removeItem(this._item);var t=this._item._id;if(st(t),ot(t),at(t),this._cancelSort(),this._isStarted){this._unbindScrollListeners();var e=item._element,i=this._getGrid(),n=i._settings.itemDraggingClass;e.parentNode!==i._element&&(i._element.appendChild(e),item._setTranslate(this._gridX,this._gridY)),ge(e,n)}this._reset()}},De.prototype.sort=function(t){var e=this._item;this._isActive&&e._isActive&&this._dragMoveEvent&&(!0===t?this._handleSort():ht(e._id,this._handleSort))},De.prototype.destroy=function(){this._isDestroyed||(this.stop(),this._dragger.destroy(),De.autoScroller.removeItem(this._item),this._isDestroyed=!0)},De.prototype._getGrid=function(){return t[this._gridId]||null},De.prototype._reset=function(){this._isActive=!1,this._isStarted=!1,this._container=null,this._containingBlock=null,this._dragStartEvent=null,this._dragMoveEvent=null,this._dragPrevMoveEvent=null,this._scrollEvent=null,this._scrollers=[],this._left=0,this._top=0,this._gridX=0,this._gridY=0,this._clientX=0,this._clientY=0,this._scrollDiffX=0,this._scrollDiffY=0,this._moveDiffX=0,this._moveDiffY=0,this._containerDiffX=0,this._containerDiffY=0},De.prototype._bindScrollListeners=function(){var t,e,i=this._getGrid()._element,n=this._container,r=this._scrollers;if(r.length=0,ue(this._item._element.parentNode,r),n!==i)for(ue(i,t=[]),e=0;e<t.length;e++)r.indexOf(t[e])<0&&r.push(t[e]);for(e=0;e<r.length;e++)r[e].addEventListener("scroll",this._onScroll,Te)},De.prototype._unbindScrollListeners=function(){var t,e=this._scrollers;for(t=0;t<e.length;t++)e[t].removeEventListener("scroll",this._onScroll,Te);e.length=0},De.prototype._resolveStartPredicate=function(t){var e=this._startPredicateData;if(!(t.distance<e.distance||e.delay))return this._resetStartPredicate(),!0},De.prototype._forceResolveStartPredicate=function(t){this._isDestroyed||1!==this._startPredicateState||(this._startPredicateState=2,this._onStart(t))},De.prototype._finishStartPredicate=function(t){var e=this._item._element,i=Math.abs(t.deltaX)<2&&Math.abs(t.deltaY)<2&&t.deltaTime<200;this._resetStartPredicate(),i&&function(t){if("a"!==t.tagName.toLowerCase())return;var e=t.getAttribute("href");if(!e)return;var i=t.getAttribute("target");i&&"_self"!==i?window.open(e,i):window.location.href=e}(e)},De.prototype._resetHeuristics=function(t,e){this._blockedSortIndex=null,this._sortX1=this._sortX2=t,this._sortY1=this._sortY2=e},De.prototype._checkHeuristics=function(t,e){var i=this._getGrid()._settings.dragSortHeuristics,n=i.minDragDistance;if(n<=0)return this._blockedSortIndex=null,!0;var r=t-this._sortX2,s=e-this._sortY2,o=n>3&&i.minBounceBackAngle>0;if(o||(this._blockedSortIndex=null),Math.abs(r)>n||Math.abs(s)>n){if(o){var a=Math.atan2(r,s),h=Math.atan2(this._sortX2-this._sortX1,this._sortY2-this._sortY1),l=Math.atan2(Math.sin(a-h),Math.cos(a-h));Math.abs(l)>i.minBounceBackAngle&&(this._blockedSortIndex=null)}return this._sortX1=this._sortX2,this._sortY1=this._sortY2,this._sortX2=t,this._sortY2=e,!0}return!1},De.prototype._resetStartPredicate=function(){var t=this._startPredicateData;t&&(t.delayTimer&&(t.delayTimer=window.clearTimeout(t.delayTimer)),this._startPredicateData=null)},De.prototype._handleSort=function(){if(this._isActive){var t=this._getGrid()._settings;if(!t.dragSort||!t.dragAutoScroll.sortDuringScroll&&De.autoScroller.isItemScrolling(this._item))return this._sortX1=this._sortX2=this._gridX,this._sortY1=this._sortY2=this._gridY,this._isSortNeeded=!0,void(void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)));var e=this._checkHeuristics(this._gridX,this._gridY);if(this._isSortNeeded||e){var i=t.dragSortHeuristics.sortInterval;i<=0||this._isSortNeeded?(this._isSortNeeded=!1,void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)),this._checkOverlap()):void 0===this._sortTimer&&(this._sortTimer=window.setTimeout(this._handleSortDelayed,i))}}},De.prototype._handleSortDelayed=function(){this._isSortNeeded=!0,this._sortTimer=void 0,ht(this._item._id,this._handleSort)},De.prototype._cancelSort=function(){var t;this._isSortNeeded=!1,void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)),t=this._item._id,it.remove(1,Q+t)},De.prototype._finishSort=function(){var t=this._getGrid()._settings.dragSort&&(this._isSortNeeded||void 0!==this._sortTimer);this._cancelSort(),t&&this._checkOverlap()},De.prototype._checkOverlap=function(){if(this._isActive){var t,e,r,s,o,a,h,l,u=this._item,m=this._getGrid()._settings;(t=dt(m.dragSortPredicate)?m.dragSortPredicate(u,this._dragMoveEvent):De.defaultSortPredicate(u,m.dragSortPredicate))&&"number"==typeof t.index&&(h=t.action===i?i:n,l=(e=u.getGrid())!==(s=t.grid||e),r=e._items.indexOf(u),o=Vt(s._items,t.index,l&&h===n?1:0),(l||o!==this._blockedSortIndex)&&(l?(this._blockedSortIndex=null,a=s._items[o],e._hasListeners(_)&&e._emit(_,{item:u,fromGrid:e,fromIndex:r,toGrid:s,toIndex:o}),s._hasListeners(p)&&s._emit(p,{item:u,fromGrid:e,fromIndex:r,toGrid:s,toIndex:o}),u._gridId=s._id,this._isMigrating=u._gridId!==this._gridId,e._items.splice(r,1),zt(s._items,u,o),u._sortData=null,e._hasListeners(c)&&e._emit(c,{item:u,fromGrid:e,fromIndex:r,toGrid:s,toIndex:o}),s._hasListeners(f)&&s._emit(f,{item:u,fromGrid:e,fromIndex:r,toGrid:s,toIndex:o}),h===i&&a&&a.isActive()&&s._items.indexOf(a)>-1&&s.send(a,e,r,{appendTo:this._container||document.body,layoutSender:!1,layoutReceiver:!1}),e.layout(),s.layout()):r!==o&&(this._blockedSortIndex=r,(h===i?Ut:jt)(e._items,r,o),e._hasListeners(d)&&e._emit(d,{item:u,fromIndex:r,toIndex:o,action:h}),e.layout())))}},De.prototype._finishMigration=function(){var t,e,i=this._item,n=i._dragRelease,r=i._element,s=i._isActive,o=i.getGrid(),a=o._element,h=o._settings,l=h.dragContainer||a,u=this._getGrid()._settings,d=r.parentNode,c=s?u.itemVisibleClass:u.itemHiddenClass,_=s?h.itemVisibleClass:h.itemHiddenClass;this._isMigrating=!1,this.destroy(),u.itemClass!==h.itemClass&&(ge(r,u.itemClass),Bt(r,h.itemClass)),c!==_&&(ge(r,c),Bt(r,_)),l!==d&&(l.appendChild(r),e=ae(d,l,!0),(t=me(r)).x-=e.left,t.y-=e.top),i._refreshDimensions(),e=ae(l,a,!0),n._containerDiffX=e.left,n._containerDiffY=e.top,i._drag=h.dragEnabled?new De(i):null,l!==d&&i._setTranslate(t.x,t.y),i._visibility.setStyles(s?h.visibleStyles:h.hiddenStyles),n.start()},De.prototype._preStartCheck=function(t){0===this._startPredicateState&&(this._startPredicateState=1),1===this._startPredicateState?(this._startPredicateResult=this._startPredicate(this._item,t),!0===this._startPredicateResult?(this._startPredicateState=2,this._onStart(t)):!1===this._startPredicateResult&&(this._resetStartPredicate(t),this._dragger._reset(),this._startPredicateState=0)):2===this._startPredicateState&&this._isActive&&this._onMove(t)},De.prototype._preEndCheck=function(t){var e=2===this._startPredicateState;this._startPredicate(this._item,t),this._startPredicateState=0,e&&this._isActive&&(this._isStarted?this._onEnd(t):this.stop())},De.prototype._onStart=function(t){var e,i,n,r=this._item;r._isActive&&(this._isActive=!0,this._dragStartEvent=t,De.autoScroller.addItem(r),e=r._id,i=this._prepareStart,n=this._applyStart,it.add(0,B+e,i),it.add(2,G+e,n))},De.prototype._prepareStart=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=t._element,i=this._getGrid(),n=i._settings,r=i._element,s=n.dragContainer||r,o=ie(s),a=me(e),h=e.getBoundingClientRect(),l=s!==r;if(this._container=s,this._containingBlock=o,this._clientX=h.left,this._clientY=h.top,this._left=this._gridX=a.x,this._top=this._gridY=a.y,this._scrollDiffX=this._scrollDiffY=0,this._moveDiffX=this._moveDiffY=0,this._resetHeuristics(this._gridX,this._gridY),l){var u=ae(o,r);this._containerDiffX=u.left,this._containerDiffY=u.top}}}},De.prototype._applyStart=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=this._getGrid(),i=t._element,n=t._dragRelease,r=t._migrate,s=this._container!==e._element;t.isPositioning()&&t._layout.stop(!0,this._left,this._top),r._isActive&&(this._left-=r._containerDiffX,this._top-=r._containerDiffY,this._gridX-=r._containerDiffX,this._gridY-=r._containerDiffY,r.stop(!0,this._left,this._top)),t.isReleasing()&&n._reset(),e._settings.dragPlaceholder.enabled&&t._dragPlaceholder.create(),this._isStarted=!0,e._emit("dragInit",t,this._dragStartEvent),s&&(i.parentNode===this._container?(this._gridX-=this._containerDiffX,this._gridY-=this._containerDiffY):(this._left+=this._containerDiffX,this._top+=this._containerDiffY,this._container.appendChild(i),t._setTranslate(this._left,this._top))),Bt(i,e._settings.itemDraggingClass),this._bindScrollListeners(),e._emit("dragStart",t,this._dragStartEvent)}}},De.prototype._onMove=function(t){var e,i,n,r=this._item;r._isActive?(this._dragMoveEvent=t,e=r._id,i=this._prepareMove,n=this._applyMove,it.add(0,z+e,i),it.add(2,V+e,n),ht(r._id,this._handleSort)):this.stop()},De.prototype._prepareMove=function(){if(this._isActive&&this._item._isActive){var t=this._getGrid()._settings.dragAxis,e=this._dragMoveEvent,i=this._dragPrevMoveEvent||this._dragStartEvent||e;if("y"!==t){var n=e.clientX-i.clientX;this._left=this._left-this._moveDiffX+n,this._gridX=this._gridX-this._moveDiffX+n,this._clientX=this._clientX-this._moveDiffX+n,this._moveDiffX=n}if("x"!==t){var r=e.clientY-i.clientY;this._top=this._top-this._moveDiffY+r,this._gridY=this._gridY-this._moveDiffY+r,this._clientY=this._clientY-this._moveDiffY+r,this._moveDiffY=r}this._dragPrevMoveEvent=e}},De.prototype._applyMove=function(){if(this._isActive){var t=this._item;t._isActive&&(this._moveDiffX=this._moveDiffY=0,t._setTranslate(this._left,this._top),this._getGrid()._emit("dragMove",t,this._dragMoveEvent),De.autoScroller.updateItem(t))}},De.prototype._onScroll=function(t){var e,i,n,r=this._item;r._isActive?(this._scrollEvent=t,e=r._id,i=this._prepareScroll,n=this._applyScroll,it.add(0,j+e,i),it.add(2,U+e,n),ht(r._id,this._handleSort)):this.stop()},De.prototype._prepareScroll=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=t._element,i=this._getGrid(),n=i._element,r=i._settings.dragAxis,s="y"!==r,o="x"!==r,a=e.getBoundingClientRect();if(this._container!==n){var h=ae(this._containingBlock,n);this._containerDiffX=h.left,this._containerDiffY=h.top}if(s){var l=this._clientX-this._moveDiffX-this._scrollDiffX-a.left;this._left=this._left-this._scrollDiffX+l,this._scrollDiffX=l}if(o){var u=this._clientY-this._moveDiffY-this._scrollDiffY-a.top;this._top=this._top-this._scrollDiffY+u,this._scrollDiffY=u}this._gridX=this._left-this._containerDiffX,this._gridY=this._top-this._containerDiffY}}},De.prototype._applyScroll=function(){if(this._isActive){var t=this._item;t._isActive&&(this._scrollDiffX=this._scrollDiffY=0,t._setTranslate(this._left,this._top),this._getGrid()._emit("dragScroll",t,this._scrollEvent))}},De.prototype._onEnd=function(t){var e=this._item,i=e._element,n=this._getGrid(),r=n._settings,s=e._dragRelease;e._isActive?(st(e._id),ot(e._id),at(e._id),this._finishSort(),this._unbindScrollListeners(),s._containerDiffX=this._containerDiffX,s._containerDiffY=this._containerDiffY,this._reset(),ge(i,r.itemDraggingClass),De.autoScroller.removeItem(e),n._emit("dragEnd",e,t),this._isMigrating?this._finishMigration():s.start()):this.stop()};var Ae=/^(webkit|moz|ms|o|Webkit|Moz|MS|O)(?=[A-Z])/,ke={};function Ee(t){var e=ke[t];return e||((e=t.replace(Ae,""))!==t&&(e=e[0].toLowerCase()+e.slice(1)),ke[t]=e,e)}function Re(t,e){for(var i in e)t.style[i]=e[i]}var Le,Pe,Me=!(!Element||!dt(Element.prototype.animate)),Ie=!!(Element&&(Le=Element.prototype.animate,Pe=window.Symbol,Le&&dt(Pe)&&dt(Pe.toString)&&Pe(Le).toString().indexOf("[native code]")>-1));function Ce(t){this._element=t,this._animation=null,this._duration=0,this._easing="",this._callback=null,this._props=[],this._values=[],this._isDestroyed=!1,this._onFinish=this._onFinish.bind(this)}function Ne(t,e){var i={};for(var n in t)i[e?n:Ee(n)]=t[n];return i}function Oe(t,e){return"translateX("+t+"px) translateY("+e+"px)"}function Xe(t){this._item=t,this._animation=new Ce,this._element=null,this._className="",this._didMigrate=!1,this._resetAfterLayout=!1,this._left=0,this._top=0,this._transX=0,this._transY=0,this._nextTransX=0,this._nextTransY=0,this._setupAnimation=this._setupAnimation.bind(this),this._startAnimation=this._startAnimation.bind(this),this._updateDimensions=this._updateDimensions.bind(this),this._onLayoutStart=this._onLayoutStart.bind(this),this._onLayoutEnd=this._onLayoutEnd.bind(this),this._onReleaseEnd=this._onReleaseEnd.bind(this),this._onMigrate=this._onMigrate.bind(this),this._onHide=this._onHide.bind(this)}function Ye(t){this._item=t,this._isActive=!1,this._isDestroyed=!1,this._isPositioningStarted=!1,this._containerDiffX=0,this._containerDiffY=0}Ce.prototype.start=function(t,e,i){if(!this._isDestroyed){var n=this._element,r=i||{};if(!Me)return Re(n,e),this._callback=dt(r.onFinish)?r.onFinish:null,void this._onFinish();var s,o,a,h=this._animation,l=this._props,u=this._values,d=r.duration||300,c=r.easing||"ease",_=!1;if(h&&(o=0,d===this._duration&&c===this._easing||(_=!0),!_)){for(s in e)if(++o,-1===(a=l.indexOf(s))||e[s]!==u[a]){_=!0;break}o!==l.length&&(_=!0)}if(_&&h.cancel(),this._callback=dt(r.onFinish)?r.onFinish:null,!h||_){for(s in l.length=u.length=0,e)l.push(s),u.push(e[s]);this._duration=d,this._easing=c,this._animation=n.animate([Ne(t,Ie),Ne(e,Ie)],{duration:d,easing:c}),this._animation.onfinish=this._onFinish,Re(n,e)}}},Ce.prototype.stop=function(){!this._isDestroyed&&this._animation&&(this._animation.cancel(),this._animation=this._callback=null,this._props.length=this._values.length=0)},Ce.prototype.getCurrentStyles=function(){return xe(element,currentProps)},Ce.prototype.isAnimating=function(){return!!this._animation},Ce.prototype.destroy=function(){this._isDestroyed||(this.stop(),this._element=null,this._isDestroyed=!0)},Ce.prototype._onFinish=function(){var t=this._callback;this._animation=this._callback=null,this._props.length=this._values.length=0,t&&t()},Xe.prototype._updateDimensions=function(){this.isActive()&&Re(this._element,{width:this._item._width+"px",height:this._item._height+"px"})},Xe.prototype._onLayoutStart=function(t,e){var i=this._item;if(-1!==t.indexOf(i)){var n=i._left,r=i._top,s=this._left,o=this._top;if(this._left=n,this._top=r,e||this._didMigrate||s!==n||o!==r){var a,h,l,u=n+i._marginLeft,d=r+i._marginTop,c=i.getGrid();if(!(!e&&c._settings.layoutDuration>0)||this._didMigrate)return lt(i._id),this._element.style[Qt]=Oe(u,d),this._animation.stop(),void(this._didMigrate&&(c.getElement().appendChild(this._element),this._didMigrate=!1));this._nextTransX=u,this._nextTransY=d,a=i._id,h=this._setupAnimation,l=this._startAnimation,it.add(0,K+a,h),it.add(2,$+a,l)}}else this.reset()},Xe.prototype._setupAnimation=function(){if(this.isActive()){var t=me(this._element);this._transX=t.x,this._transY=t.y}},Xe.prototype._startAnimation=function(){if(this.isActive()){var t=this._animation,e=this._transX,i=this._transY,n=this._nextTransX,r=this._nextTransY;if(e!==n||i!==r){var s=this._item.getGrid()._settings,o={},a={};o[Qt]=Oe(e,i),a[Qt]=Oe(n,r),t.start(o,a,{duration:s.layoutDuration,easing:s.layoutEasing,onFinish:this._onLayoutEnd})}else t.isAnimating()&&(this._element.style[Qt]=Oe(n,r),t.stop())}},Xe.prototype._onLayoutEnd=function(){this._resetAfterLayout&&this.reset()},Xe.prototype._onReleaseEnd=function(t){if(t._id===this._item._id){if(!this._animation.isAnimating())return void this.reset();this._resetAfterLayout=!0}},Xe.prototype._onMigrate=function(t){if(t.item===this._item){var e=this._item.getGrid(),i=t.toGrid;e.off(m,this._onReleaseEnd),e.off(r,this._onLayoutStart),e.off(_,this._onMigrate),e.off(h,this._onHide),i.on(m,this._onReleaseEnd),i.on(r,this._onLayoutStart),i.on(_,this._onMigrate),i.on(h,this._onHide),this._didMigrate=!0}},Xe.prototype._onHide=function(t){t.indexOf(this._item)>-1&&this.reset()},Xe.prototype.create=function(){if(this.isActive())this._resetAfterLayout=!1;else{var t,e=this._item,i=e.getGrid(),n=i._settings,s=this._animation;this._left=e._left,this._top=e._top,t=dt(n.dragPlaceholder.createElement)?n.dragPlaceholder.createElement(e):document.createElement("div"),this._element=t,s._element=t,this._className=n.itemPlaceholderClass||"",this._className&&Bt(t,this._className),Re(t,{position:"absolute",left:"0px",top:"0px",width:e._width+"px",height:e._height+"px"}),t.style[Qt]=Oe(e._left+e._marginLeft,e._top+e._marginTop),i.on(r,this._onLayoutStart),i.on(m,this._onReleaseEnd),i.on(_,this._onMigrate),i.on(h,this._onHide),dt(n.dragPlaceholder.onCreate)&&n.dragPlaceholder.onCreate(e,t),i.getElement().appendChild(t)}},Xe.prototype.reset=function(){if(this.isActive()){var t,e=this._element,i=this._item,n=i.getGrid(),s=n._settings,o=this._animation;this._resetAfterLayout=!1,lt(i._id),t=i._id,it.remove(2,Z+t),o.stop(),o._element=null,n.off(m,this._onReleaseEnd),n.off(r,this._onLayoutStart),n.off(_,this._onMigrate),n.off(h,this._onHide),this._className&&(ge(e,this._className),this._className=""),e.parentNode.removeChild(e),this._element=null,dt(s.dragPlaceholder.onRemove)&&s.dragPlaceholder.onRemove(i,e)}},Xe.prototype.isActive=function(){return!!this._element},Xe.prototype.getElement=function(){return this._element},Xe.prototype.updateDimensions=function(){var t,e;this.isActive()&&(t=this._item._id,e=this._updateDimensions,it.add(2,Z+t,e))},Xe.prototype.destroy=function(){this.reset(),this._animation.destroy(),this._item=this._animation=null},Ye.prototype.start=function(){if(!this._isDestroyed&&!this._isActive){var t=this._item,e=t.getGrid(),i=e._settings;this._isActive=!0,Bt(t._element,i.itemReleasingClass),i.dragRelease.useDragContainer||this._placeToGrid(),e._emit("dragReleaseStart",t),e._nextLayoutData||t._layout.start(!1)}},Ye.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n=this._item,r=n.getGrid();t||void 0!==e&&void 0!==i||(e=n._left,i=n._top);var s=this._placeToGrid(e,i);this._reset(s),t||r._emit(m,n)}},Ye.prototype.isJustReleased=function(){return this._isActive&&!1===this._isPositioningStarted},Ye.prototype.destroy=function(){this._isDestroyed||(this.stop(!0),this._item=null,this._isDestroyed=!0)},Ye.prototype._placeToGrid=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=i.getGrid()._element,s=!1;if(n.parentNode!==r){if(void 0===t||void 0===e){var o=me(n);t=o.x-this._containerDiffX,e=o.y-this._containerDiffY}r.appendChild(n),i._setTranslate(t,e),s=!0}return this._containerDiffX=0,this._containerDiffY=0,s}},Ye.prototype._reset=function(t){if(!this._isDestroyed){var e=this._item,i=e.getGrid()._settings.itemReleasingClass;this._isActive=!1,this._isPositioningStarted=!1,this._containerDiffX=0,this._containerDiffY=0,i&&ge(e._element,i)}};function qe(t){var e=t._element,i=e.style;this._item=t,this._isActive=!1,this._isDestroyed=!1,this._isInterrupted=!1,this._currentStyles={},this._targetStyles={},this._nextLeft=0,this._nextTop=0,this._offsetLeft=0,this._offsetTop=0,this._skipNextAnimation=!1,this._animOptions={onFinish:this._finish.bind(this),duration:0,easing:0},i.left="0px",i.top="0px",t._setTranslate(0,0),this._animation=new Ce(e),this._queue="layout-"+t._id,this._setupAnimation=this._setupAnimation.bind(this),this._startAnimation=this._startAnimation.bind(this)}function He(t){this._item=t,this._isActive=!1,this._isDestroyed=!1,this._container=!1,this._containerDiffX=0,this._containerDiffY=0}function Fe(t){var e=t._isActive,i=t._element,n=i.children[0],r=t.getGrid()._settings;if(!n)throw new Error("No valid child element found within item element.");this._item=t,this._isDestroyed=!1,this._isHidden=!e,this._isHiding=!1,this._isShowing=!1,this._childElement=n,this._currentStyleProps=[],this._animation=new Ce(n),this._queue="visibility-"+t._id,this._finishShow=this._finishShow.bind(this),this._finishHide=this._finishHide.bind(this),i.style.display=e?"":"none",Bt(i,e?r.itemVisibleClass:r.itemHiddenClass),this.setStyles(e?r.visibleStyles:r.hiddenStyles)}qe.prototype.start=function(t,e){if(!this._isDestroyed){var i,n,r,s=this._item,o=s._dragRelease,a=s.getGrid()._settings,h=this._isActive,l=o.isJustReleased(),u=l?a.dragRelease.duration:a.layoutDuration,d=l?a.dragRelease.easing:a.layoutEasing,c=!t&&!this._skipNextAnimation&&u>0;if(h&&(nt(s._id),s._emitter.burst(this._queue,!0,s)),l&&(o._isPositioningStarted=!0),dt(e)&&s._emitter.on(this._queue,e),this._skipNextAnimation=!1,!c)return this._updateOffsets(),s._setTranslate(this._nextLeft,this._nextTop),this._animation.stop(),void this._finish();this._animation.isAnimating()&&(this._animation._animation.onfinish=null),this._isActive=!0,this._animOptions.easing=d,this._animOptions.duration=u,this._isInterrupted=h,i=s._id,n=this._setupAnimation,r=this._startAnimation,it.add(0,q+i,n),it.add(2,H+i,r)}},qe.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n=this._item;if(nt(n._id),this._animation.isAnimating()){if(void 0===e||void 0===i){var r=me(n._element);e=r.x,i=r.y}n._setTranslate(e,i),this._animation.stop()}ge(n._element,n.getGrid()._settings.itemPositioningClass),this._isActive=!1,t&&n._emitter.burst(this._queue,!0,n)}},qe.prototype.destroy=function(){if(!this._isDestroyed){var t=this._item._element.style;this.stop(!0,0,0),this._item._emitter.clear(this._queue),this._animation.destroy(),t[Qt]="",t.left="",t.top="",this._item=null,this._currentStyles=null,this._targetStyles=null,this._animOptions=null,this._isDestroyed=!0}},qe.prototype._updateOffsets=function(){if(!this._isDestroyed){var t=this._item,e=t._migrate,i=t._dragRelease;this._offsetLeft=i._isActive?i._containerDiffX:e._isActive?e._containerDiffX:0,this._offsetTop=i._isActive?i._containerDiffY:e._isActive?e._containerDiffY:0,this._nextLeft=this._item._left+this._offsetLeft,this._nextTop=this._item._top+this._offsetTop}},qe.prototype._finish=function(){if(!this._isDestroyed){var t=this._item,e=t._migrate,i=t._dragRelease;t._tX=this._nextLeft,t._tY=this._nextTop,this._isActive&&(this._isActive=!1,ge(t._element,t.getGrid()._settings.itemPositioningClass)),i._isActive&&i.stop(),e._isActive&&e.stop(),t._emitter.burst(this._queue,!1,t)}},qe.prototype._setupAnimation=function(){var t=this._item;if(void 0===t._tX||void 0===t._tY){var e=me(t._element);t._tX=e.x,t._tY=e.y}},qe.prototype._startAnimation=function(){var t=this._item,e=t.getGrid()._settings,i=this._animOptions.duration<=0;this._updateOffsets();var n=Math.abs(t._left-(t._tX-this._offsetLeft)),r=Math.abs(t._top-(t._tY-this._offsetTop));if(i||n<2&&r<2)return(n||r||this._isInterrupted)&&t._setTranslate(this._nextLeft,this._nextTop),this._animation.stop(),void this._finish();this._isInterrupted||Bt(t._element,e.itemPositioningClass),this._currentStyles[Qt]=Oe(t._tX,t._tY),this._targetStyles[Qt]=Oe(this._nextLeft,this._nextTop),t._tX=t._tY=void 0,this._animation.start(this._currentStyles,this._targetStyles,this._animOptions)},He.prototype.start=function(t,e,i){if(!this._isDestroyed){var n,r,s,o,a,h,l,u,d,m,g=this._item,v=g._element,y=g.isActive(),b=g.isVisible(),w=g.getGrid(),S=w._settings,T=t._settings,D=t._element,x=t._items,A=w._items.indexOf(g),k=i||document.body;if("number"==typeof e)n=Vt(x,e,1);else{if(!(r=t.getItem(e)))return;n=x.indexOf(r)}(g.isPositioning()||this._isActive||g.isReleasing())&&(l=(h=me(v)).x,u=h.y),g.isPositioning()&&g._layout.stop(!0,l,u),this._isActive&&(l-=this._containerDiffX,u-=this._containerDiffY,this.stop(!0,l,u)),g.isReleasing()&&(l-=g._dragRelease._containerDiffX,u-=g._dragRelease._containerDiffY,g._dragRelease.stop(!0,l,u)),g._visibility.stop(!0),g._drag&&g._drag.destroy(),w._hasListeners(_)&&w._emit(_,{item:g,fromGrid:w,fromIndex:A,toGrid:t,toIndex:n}),t._hasListeners(p)&&t._emit(p,{item:g,fromGrid:w,fromIndex:A,toGrid:t,toIndex:n}),S.itemClass!==T.itemClass&&(ge(v,S.itemClass),Bt(v,T.itemClass)),(d=b?S.itemVisibleClass:S.itemHiddenClass)!==(m=b?T.itemVisibleClass:T.itemHiddenClass)&&(ge(v,d),Bt(v,m)),w._items.splice(A,1),zt(x,g,n),g._gridId=t._id,y?k!==(s=v.parentNode)&&(k.appendChild(v),o=ae(k,s,!0),h||(l=(h=me(v)).x,u=h.y),g._setTranslate(l+o.left,u+o.top)):D.appendChild(v),g._visibility.setStyles(b?T.visibleStyles:T.hiddenStyles),y&&(a=ae(k,D,!0)),g._refreshDimensions(),g._sortData=null,g._drag=T.dragEnabled?new De(g):null,y?(this._isActive=!0,this._container=k,this._containerDiffX=a.left,this._containerDiffY=a.top):(this._isActive=!1,this._container=null,this._containerDiffX=0,this._containerDiffY=0),w._hasListeners(c)&&w._emit(c,{item:g,fromGrid:w,fromIndex:A,toGrid:t,toIndex:n}),t._hasListeners(f)&&t._emit(f,{item:g,fromGrid:w,fromIndex:A,toGrid:t,toIndex:n})}},He.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n,r=this._item,s=r._element,o=r.getGrid()._element;this._container!==o&&(void 0!==e&&void 0!==i||(t?(e=(n=me(s)).x-this._containerDiffX,i=n.y-this._containerDiffY):(e=r._left,i=r._top)),o.appendChild(s),r._setTranslate(e,i)),this._isActive=!1,this._container=null,this._containerDiffX=0,this._containerDiffY=0}},He.prototype.destroy=function(){this._isDestroyed||(this.stop(!0),this._item=null,this._isDestroyed=!0)},Fe.prototype.show=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=dt(e)?e:null,s=i.getGrid()._settings;this._isShowing||this._isHidden?!this._isShowing||t?(this._isShowing||(i._emitter.burst(this._queue,!0,i),ge(n,s.itemHiddenClass),Bt(n,s.itemVisibleClass),this._isHiding||(n.style.display="")),r&&i._emitter.on(this._queue,r),this._isShowing=!0,this._isHiding=this._isHidden=!1,this._startAnimation(!0,t,this._finishShow)):r&&i._emitter.on(this._queue,r):r&&r(!1,i)}},Fe.prototype.hide=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=dt(e)?e:null,s=i.getGrid()._settings;this._isHiding||!this._isHidden?!this._isHiding||t?(this._isHiding||(i._emitter.burst(this._queue,!0,i),Bt(n,s.itemHiddenClass),ge(n,s.itemVisibleClass)),r&&i._emitter.on(this._queue,r),this._isHidden=this._isHiding=!0,this._isShowing=!1,this._startAnimation(!1,t,this._finishHide)):r&&i._emitter.on(this._queue,r):r&&r(!1,i)}},Fe.prototype.stop=function(t){if(!this._isDestroyed&&(this._isHiding||this._isShowing)){var e=this._item;rt(e._id),this._animation.stop(),t&&e._emitter.burst(this._queue,!0,e)}},Fe.prototype.setStyles=function(t){var e=this._childElement,i=this._currentStyleProps;for(var n in this._removeCurrentStyles(),t)i.push(n),e.style[n]=t[n]},Fe.prototype.destroy=function(){if(!this._isDestroyed){var t=this._item,e=t._element,i=t.getGrid()._settings;this.stop(!0),t._emitter.clear(this._queue),this._animation.destroy(),this._removeCurrentStyles(),ge(e,i.itemVisibleClass),ge(e,i.itemHiddenClass),e.style.display="",this._isHiding=this._isShowing=!1,this._isDestroyed=this._isHidden=!0}},Fe.prototype._startAnimation=function(t,e,i){if(!this._isDestroyed){var n,r=this._item,s=this._animation,o=this._childElement,a=r.getGrid()._settings,h=t?a.visibleStyles:a.hiddenStyles,l=t?a.showDuration:a.hideDuration,u=t?a.showEasing:a.hideEasing,d=e||l<=0;if(h){if(rt(r._id),d)return Re(o,h),s.stop(),void(i&&i());var c,_,f;s.isAnimating()&&(s._animation.onfinish=null),c=r._id,_=function(){n=xe(o,h)},f=function(){s.start(n,h,{duration:l,easing:u,onFinish:i})},it.add(0,F+c,_),it.add(2,W+c,f)}else i&&i()}},Fe.prototype._finishShow=function(){this._isHidden||(this._isShowing=!1,this._item._emitter.burst(this._queue,!1,this._item))},Fe.prototype._finishHide=function(){if(this._isHidden){var t=this._item;this._isHiding=!1,t._layout.stop(!0,0,0),t._element.style.display="none",t._emitter.burst(this._queue,!1,t)}},Fe.prototype._removeCurrentStyles=function(){for(var t=this._childElement,e=this._currentStyleProps,i=0;i<e.length;i++)t.style[e[i]]="";e.length=0};var We=0;function Be(){return++We}function Ge(t,i,n){var r=t._settings;if(e){if(e.has(i))throw new Error("You can only create one Muuri Item per element!");e.set(i,this)}this._id=Be(),this._gridId=t._id,this._element=i,this._isDestroyed=!1,this._left=0,this._top=0,this._width=0,this._height=0,this._marginLeft=0,this._marginRight=0,this._marginTop=0,this._marginBottom=0,this._tX=void 0,this._tY=void 0,this._sortData=null,this._emitter=new b,i.parentNode!==t._element&&t._element.appendChild(i),Bt(i,r.itemClass),"boolean"!=typeof n&&(n="none"!==gt(i,"display")),this._isActive=n,this._visibility=new Fe(this),this._layout=new qe(this),this._migrate=new He(this),this._drag=r.dragEnabled?new De(this):null,this._dragRelease=new Ye(this),this._dragPlaceholder=new Xe(this)}function ze(t){var e,i,n,r,s,o=.001,a=.5;function h(t){return((1e3*t+.5<<0)/10<<0)/100}function l(){this.currentRects=[],this.nextRects=[],this.rectTarget={},this.rectStore=[],this.slotSizes=[],this.rectId=0,this.slotIndex=-1,this.slotData={left:0,top:0,width:0,height:0},this.sortRectsLeftTop=this.sortRectsLeftTop.bind(this),this.sortRectsTopLeft=this.sortRectsTopLeft.bind(this)}if(l.prototype.computeLayout=function(t,e){var i,n,r,s,o,a,l=t.items,u=t.slots,d=!!(1&e),c=!!(2&e),_=!!(4&e),f=!!(8&e),p=!!(16&e),m="number"==typeof l[0];if(!l.length)return t;for(n=m?2:1,i=0;i<l.length;i+=n)m?(s=l[i],o=l[i+1]):(s=(r=l[i])._width+r._marginLeft+r._marginRight,o=r._height+r._marginTop+r._marginBottom),p&&(s=h(s),o=h(o)),a=this.computeNextSlot(t,s,o,d,c),c?a.left+a.width>t.width&&(t.width=a.left+a.width):a.top+a.height>t.height&&(t.height=a.top+a.height),u[++this.slotIndex]=a.left,u[++this.slotIndex]=a.top,(_||f)&&this.slotSizes.push(a.width,a.height);if(_)for(i=0;i<u.length;i+=2)u[i]=t.width-(u[i]+this.slotSizes[i]);if(f)for(i=1;i<u.length;i+=2)u[i]=t.height-(u[i]+this.slotSizes[i]);return this.slotSizes.length=0,this.currentRects.length=0,this.nextRects.length=0,this.rectId=0,this.slotIndex=-1,t},l.prototype.computeNextSlot=function(t,e,i,n,r){var s,h,l,u,d,c=this.slotData,_=this.currentRects,f=this.nextRects,p=!1;for(f.length=0,c.left=null,c.top=null,c.width=e,c.height=i,u=0;u<_.length;u++)if((h=_[u])&&(s=this.getRect(h),c.width<=s.width+o&&c.height<=s.height+o)){c.left=s.left,c.top=s.top;break}if(null===c.left&&(r?(c.left=t.width,c.top=0):(c.left=0,c.top=t.height),n||(p=!0)),!r&&c.top+c.height>t.height+o&&(c.left>a&&f.push(this.addRect(0,t.height,c.left,1/0)),c.left+c.width<t.width-a&&f.push(this.addRect(c.left+c.width,t.height,t.width-c.left-c.width,1/0)),t.height=c.top+c.height),r&&c.left+c.width>t.width+o&&(c.top>a&&f.push(this.addRect(t.width,0,1/0,c.top)),c.top+c.height<t.height-a&&f.push(this.addRect(t.width,c.top+c.height,1/0,t.height-c.top-c.height)),t.width=c.left+c.width),!p)for(n&&(u=0);u<_.length;u++)if(h=_[u])for(s=this.getRect(h),l=this.splitRect(s,c),d=0;d<l.length;d++)h=l[d],s=this.getRect(h),(r?s.left+o<t.width-o:s.top+o<t.height-o)&&f.push(h);return f.length>1&&this.purgeRects(f).sort(r?this.sortRectsLeftTop:this.sortRectsTopLeft),this.currentRects=f,this.nextRects=_,c},l.prototype.addRect=function(t,e,i,n){var r=++this.rectId;return this.rectStore[r]=t||0,this.rectStore[++this.rectId]=e||0,this.rectStore[++this.rectId]=i||0,this.rectStore[++this.rectId]=n||0,r},l.prototype.getRect=function(t,e){return e||(e=this.rectTarget),e.left=this.rectStore[t]||0,e.top=this.rectStore[++t]||0,e.width=this.rectStore[++t]||0,e.height=this.rectStore[++t]||0,e},l.prototype.splitRect=(e=[],i=0,n=0,function(t,r){return e.length=0,t.left+t.width<=r.left+o||r.left+r.width<=t.left+o||t.top+t.height<=r.top+o||r.top+r.height<=t.top+o?(e.push(this.addRect(t.left,t.top,t.width,t.height)),e):((i=r.left-t.left)>=a&&e.push(this.addRect(t.left,t.top,i,t.height)),(i=t.left+t.width-(r.left+r.width))>=a&&e.push(this.addRect(r.left+r.width,t.top,i,t.height)),(n=r.top-t.top)>=a&&e.push(this.addRect(t.left,t.top,t.width,n)),(n=t.top+t.height-(r.top+r.height))>=a&&e.push(this.addRect(t.left,r.top+r.height,t.width,n)),e)}),l.prototype.isRectAWithinRectB=function(t,e){return t.left+o>=e.left&&t.top+o>=e.top&&t.left+t.width-o<=e.left+e.width&&t.top+t.height-o<=e.top+e.height},l.prototype.purgeRects=(r={},s={},function(t){for(var e,i=t.length;i--;)if(e=t.length,t[i])for(this.getRect(t[i],r);e--;)if(t[e]&&i!==e&&(this.getRect(t[e],s),this.isRectAWithinRectB(r,s))){t[i]=0;break}return t}),l.prototype.sortRectsTopLeft=function(){var t={},e={};return function(i,n){return this.getRect(i,t),this.getRect(n,e),t.top<e.top&&t.top+o<e.top?-1:t.top>e.top&&t.top-o>e.top?1:t.left<e.left&&t.left+o<e.left?-1:t.left>e.left&&t.left-o>e.left?1:0}}(),l.prototype.sortRectsLeftTop=function(){var t={},e={};return function(i,n){return this.getRect(i,t),this.getRect(n,e),t.left<e.left&&t.left+o<e.left?-1:t.left>e.left&&t.left-o<e.left?1:t.top<e.top&&t.top+o<e.top?-1:t.top>e.top&&t.top-o>e.top?1:0}}(),t){var u=new l;self.onmessage=function(t){var e=new Float32Array(t.data),i=e.subarray(4,e.length),n=new Float32Array(i.length),r=e[3],s={items:i,slots:n,width:e[1],height:e[2]};u.computeLayout(s,r),e[1]=s.width,e[2]=s.height,e.set(s.slots,4),postMessage(e.buffer,[e.buffer])}}return l}Ge.prototype.getGrid=function(){return t[this._gridId]},Ge.prototype.getElement=function(){return this._element},Ge.prototype.getWidth=function(){return this._width},Ge.prototype.getHeight=function(){return this._height},Ge.prototype.getMargin=function(){return{left:this._marginLeft,right:this._marginRight,top:this._marginTop,bottom:this._marginBottom}},Ge.prototype.getPosition=function(){return{left:this._left,top:this._top}},Ge.prototype.isActive=function(){return this._isActive},Ge.prototype.isVisible=function(){return!!this._visibility&&!this._visibility._isHidden},Ge.prototype.isShowing=function(){return!(!this._visibility||!this._visibility._isShowing)},Ge.prototype.isHiding=function(){return!(!this._visibility||!this._visibility._isHiding)},Ge.prototype.isPositioning=function(){return!(!this._layout||!this._layout._isActive)},Ge.prototype.isDragging=function(){return!(!this._drag||!this._drag._isActive)},Ge.prototype.isReleasing=function(){return!(!this._dragRelease||!this._dragRelease._isActive)},Ge.prototype.isDestroyed=function(){return this._isDestroyed},Ge.prototype._refreshDimensions=function(t){if(!(this._isDestroyed||!0!==t&&this._visibility._isHidden)){var e=this._element,i=this._dragPlaceholder,n=e.getBoundingClientRect();this._width=n.width,this._height=n.height,this._marginLeft=Math.max(0,vt(e,"margin-left")),this._marginRight=Math.max(0,vt(e,"margin-right")),this._marginTop=Math.max(0,vt(e,"margin-top")),this._marginBottom=Math.max(0,vt(e,"margin-bottom")),i&&i.updateDimensions()}},Ge.prototype._refreshSortData=function(){if(!this._isDestroyed){var t,e=this._sortData={},i=this.getGrid()._settings.sortData;for(t in i)e[t]=i[t](this,this._element)}},Ge.prototype._addToLayout=function(t,e){!0!==this._isActive&&(this._isActive=!0,this._left=t||0,this._top=e||0)},Ge.prototype._removeFromLayout=function(){!1!==this._isActive&&(this._isActive=!1,this._left=0,this._top=0)},Ge.prototype._canSkipLayout=function(t,e){return this._left===t&&this._top===e&&!this._migrate._isActive&&!this._layout._skipNextAnimation&&!this._dragRelease.isJustReleased()},Ge.prototype._setTranslate=function(t,e){return(this._tX!==t||this._tY!==e)&&(this._tX=t,this._tY=e,this._element.style[Qt]=Oe(t,e),!0)},Ge.prototype._destroy=function(t){if(!this._isDestroyed){var i=this._element,n=this.getGrid()._settings;this._dragPlaceholder.destroy(),this._dragRelease.destroy(),this._migrate.destroy(),this._layout.destroy(),this._visibility.destroy(),this._drag&&this._drag.destroy(),this._emitter.destroy(),ge(i,n.itemClass),t&&i.parentNode.removeChild(i),e&&e.delete(i),this._isActive=!1,this._isDestroyed=!0}};var Ve=ze(),je=null,Ue=[];function Qe(t,e){if(this._options=0,this._processor=null,this._layoutQueue=[],this._layouts={},this._layoutCallbacks={},this._layoutWorkers={},this._layoutWorkerData={},this._workers=[],this._onWorkerMessage=this._onWorkerMessage.bind(this),this.setOptions(e),(t="number"==typeof t?Math.max(0,t):0)&&window.Worker&&window.URL&&window.Blob)try{this._workers=function(t,e){var i=[];if(t>0){je||(je=URL.createObjectURL(new Blob(["("+ze.toString()+")(true)"],{type:"application/javascript"})));for(var n,r=0;r<t;r++)n=new Worker(je),e&&(n.onmessage=e),i.push(n),Ue.push(n)}return i}(t,this._onWorkerMessage)}catch(t){this._processor=new Ve}else this._processor=new Ve}Qe.prototype._sendToWorker=function(){if(this._layoutQueue.length&&this._workers.length){var t=this._layoutQueue.shift(),e=this._workers.pop(),i=this._layoutWorkerData[t];delete this._layoutWorkerData[t],this._layoutWorkers[t]=e,e.postMessage(i.buffer,[i.buffer])}},Qe.prototype._onWorkerMessage=function(t){var e=new Float32Array(t.data),i=e[0],n=this._layouts[i],r=this._layoutCallbacks[i],s=this._layoutWorkers[i];n&&delete this._layoutCallbacks[i],r&&delete this._layoutCallbacks[i],s&&delete this._layoutWorkers[i],n&&r&&(n.width=e[1],n.height=e[2],n.slots=e.subarray(4,e.length),this._finalizeLayout(n),r(n)),s&&(this._workers.push(s),this._sendToWorker())},Qe.prototype._finalizeLayout=function(t){var e=t._grid,i=2&t._settings,n="border-box"===e._boxSizing;return delete t._grid,delete t._settings,t.styles={},i?t.styles.width=(n?t.width+e._borderLeft+e._borderRight:t.width)+"px":t.styles.height=(n?t.height+e._borderTop+e._borderBottom:t.height)+"px",t},Qe.prototype.setOptions=function(t){var e,i,n,r,s;t&&(e="boolean"==typeof t.fillGaps?t.fillGaps?1:0:1&this._options,i="boolean"==typeof t.horizontal?t.horizontal?2:0:2&this._options,n="boolean"==typeof t.alignRight?t.alignRight?4:0:4&this._options,r="boolean"==typeof t.alignBottom?t.alignBottom?8:0:8&this._options,s="boolean"==typeof t.rounding?t.rounding?16:0:16&this._options,this._options=e|i|n|r|s)},Qe.prototype.createLayout=function(t,e,i,n,r,s){if(this._layouts[e])throw new Error("A layout with the provided id is currently being processed.");var o=2&this._options,a={id:e,items:i,slots:null,width:o?0:n,height:o?r:0,_grid:t,_settings:this._options};if(!i.length)return a.slots=[],this._finalizeLayout(a),void s(a);if(this._processor)return a.slots=window.Float32Array?new Float32Array(2*i.length):new Array(2*i.length),this._processor.computeLayout(a,a._settings),this._finalizeLayout(a),void s(a);var h,l,u,d=new Float32Array(4+2*i.length);for(d[0]=e,d[1]=a.width,d[2]=a.height,d[3]=a._settings,h=0,l=3;h<i.length;h++)u=i[h],d[++l]=u._width+u._marginLeft+u._marginRight,d[++l]=u._height+u._marginTop+u._marginBottom;return this._layoutQueue.push(e),this._layouts[e]=a,this._layoutCallbacks[e]=s,this._layoutWorkerData[e]=d,this._sendToWorker(),this.cancelLayout.bind(this,e)},Qe.prototype.cancelLayout=function(t){if(this._layouts[t]&&(delete this._layouts[t],delete this._layoutCallbacks[t],this._layoutWorkerData[t])){delete this._layoutWorkerData[t];var e=this._layoutQueue.indexOf(t);e>-1&&this._layoutQueue.splice(e,1)}},Qe.prototype.destroy=function(){for(var t in this._layoutWorkers)this._workers.push(this._layoutWorkers[t]);!function(t){for(var e,i,n=0;n<t.length;n++)(e=t[n]).onmessage=null,e.onerror=null,e.onmessageerror=null,e.terminate(),(i=Ue.indexOf(e))>-1&&Ue.splice(i,1);je&&!Ue.length&&(URL.revokeObjectURL(je),je=null)}(this._workers),this._workers.length=0,this._layoutQueue.length=0,this._layouts={},this._layoutCallbacks={},this._layoutWorkers={},this._layoutWorkerData={}};var Ke=0;function $e(t,e){var i=++Ke,n=0,r=0,s=!1,o=function(e){s||(r&&(n-=e-r),r=e,n>0?function(t,e){it.add(0,et+t,e)}(i,o):(n=r=0,t()))};return function(a){if(!s){if(!(e<=0))return!0===a?(s=!0,n=r=0,o=void 0,void function(t){it.remove(0,et+t)}(i)):void(n<=0?(n=e,o(0)):n=e);!0!==a&&t()}}}function Ze(t){var e=Object.prototype.toString.call(t);return"[object HTMLCollection]"===e||"[object NodeList]"===e}var Je=Object.prototype.toString;function ti(t){return"object"==typeof t&&"[object Object]"===Je.call(t)}function ei(){}var ii,ni,ri,si="number",oi="string",ai="instant",hi=0;function li(e,i){if(typeof e===oi&&(e=document.querySelector(e)),!(e.getRootNode?e.getRootNode({composed:!0})===document:document.body.contains(e))||e===document.documentElement)throw new Error("Container element must be an existing DOM element.");var n=function(t,e){var i=ui({},t);e&&(i=ui(i,e));e&&e.visibleStyles?i.visibleStyles=e.visibleStyles:t&&t.visibleStyles&&(i.visibleStyles=t.visibleStyles);e&&e.hiddenStyles?i.hiddenStyles=e.hiddenStyles:t&&t.hiddenStyles&&(i.hiddenStyles=t.hiddenStyles);return i}(li.defaultOptions,i);n.visibleStyles=di(n.visibleStyles),n.hiddenStyles=di(n.hiddenStyles),dt(n.dragSort)||(n.dragSort=!!n.dragSort),this._id=Be(),this._element=e,this._settings=n,this._isDestroyed=!1,this._items=[],this._layout={id:0,items:[],slots:[]},this._isLayoutFinished=!0,this._nextLayoutData=null,this._emitter=new b,this._onLayoutDataReceived=this._onLayoutDataReceived.bind(this),t[this._id]=this,Bt(e,n.containerClass),function(t,e){typeof e!==si&&(e=!0===e?0:-1);e>=0&&(t._resizeHandler=$e((function(){t.refreshItems().layout()}),e),window.addEventListener("resize",t._resizeHandler))}(this,n.layoutOnResize),this.add(function(t,e){if("*"===e)return t.children;if(typeof e===oi){for(var i=[],n=t.children,r=0;r<n.length;r++)Wt(n[r],e)&&i.push(n[r]);return i}if(Array.isArray(e)||Ze(e))return e;return[]}(e,n.items),{layout:!1}),n.layoutOnInit&&this.layout(!0)}function ui(t,e){var i,n,r,s=Object.keys(e),o=s.length;for(r=0;r<o;r++)i=ti(e[n=s[r]]),ti(t[n])&&i?t[n]=ui(ui({},t[n]),e[n]):i?t[n]=ui({},e[n]):Array.isArray(e[n])?t[n]=e[n].slice(0):t[n]=e[n];return t}function di(t){var e,i,n={},r=document.documentElement.style;for(e in t)t[e]&&(i=x(r,e))&&(n[i]=t[e]);return n}function ci(t){for(var e={},i=0;i<t.length;i++)e[t[i]._id]=i;return e}function _i(t,e,i){return t[e._id]-t[i._id]}li.Item=Ge,li.ItemLayout=qe,li.ItemVisibility=Fe,li.ItemMigrate=He,li.ItemDrag=De,li.ItemDragRelease=Ye,li.ItemDragPlaceholder=Xe,li.Emitter=b,li.Animator=Ce,li.Dragger=N,li.Packer=Qe,li.AutoScroller=qt,li.defaultPacker=new Qe(2),li.defaultOptions={items:"*",showDuration:300,showEasing:"ease",hideDuration:300,hideEasing:"ease",visibleStyles:{opacity:"1",transform:"scale(1)"},hiddenStyles:{opacity:"0",transform:"scale(0.5)"},layout:{fillGaps:!1,horizontal:!1,alignRight:!1,alignBottom:!1,rounding:!1},layoutOnResize:150,layoutOnInit:!0,layoutDuration:300,layoutEasing:"ease",sortData:null,dragEnabled:!1,dragContainer:null,dragHandle:null,dragStartPredicate:{distance:0,delay:0},dragAxis:"xy",dragSort:!0,dragSortHeuristics:{sortInterval:100,minDragDistance:10,minBounceBackAngle:1},dragSortPredicate:{threshold:50,action:n,migrateAction:n},dragRelease:{duration:300,easing:"ease",useDragContainer:!0},dragCssProps:{touchAction:"none",userSelect:"none",userDrag:"none",tapHighlightColor:"rgba(0, 0, 0, 0)",touchCallout:"none",contentZooming:"none"},dragPlaceholder:{enabled:!1,createElement:null,onCreate:null,onRemove:null},dragAutoScroll:{targets:[],handle:null,threshold:50,safeZone:.2,speed:qt.smoothSpeed(1e3,2e3,2500),sortDuringScroll:!0,smoothStop:!1,onStart:null,onStop:null},containerClass:"muuri",itemClass:"muuri-item",itemVisibleClass:"muuri-item-shown",itemHiddenClass:"muuri-item-hidden",itemPositioningClass:"muuri-item-positioning",itemDraggingClass:"muuri-item-dragging",itemReleasingClass:"muuri-item-releasing",itemPlaceholderClass:"muuri-item-placeholder"},li.prototype.on=function(t,e){return this._emitter.on(t,e),this},li.prototype.off=function(t,e){return this._emitter.off(t,e),this},li.prototype.getElement=function(){return this._element},li.prototype.getItem=function(t){if(this._isDestroyed||!t&&0!==t)return null;if(typeof t===si)return this._items[t>-1?t:this._items.length+t]||null;if(t instanceof Ge)return t._gridId===this._id?t:null;if(e){var i=e.get(t);return i&&i._gridId===this._id?i:null}for(var n=0;n<this._items.length;n++)if(this._items[n]._element===t)return this._items[n];return null},li.prototype.getItems=function(t){if(this._isDestroyed||void 0===t)return this._items.slice(0);var e,i,n=[];if(Array.isArray(t)||Ze(t))for(e=0;e<t.length;e++)(i=this.getItem(t[e]))&&n.push(i);else(i=this.getItem(t))&&n.push(i);return n},li.prototype.refreshItems=function(t,e){if(this._isDestroyed)return this;var i,n,r,s,o=t||this._items;if(!0===e)for(s=[],i=0;i<o.length;i++)(n=o[i]).isVisible()||n.isHiding()||((r=n.getElement().style).visibility="hidden",r.display="",s.push(r));for(i=0;i<o.length;i++)o[i]._refreshDimensions(e);if(!0===e){for(i=0;i<s.length;i++)(r=s[i]).visibility="",r.display="none";s.length=0}return this},li.prototype.refreshSortData=function(t){if(this._isDestroyed)return this;for(var e=t||this._items,i=0;i<e.length;i++)e[i]._refreshSortData();return this},li.prototype.synchronize=function(){if(this._isDestroyed)return this;var t,e,i=this._items;if(!i.length)return this;for(var n=0;n<i.length;n++)(e=i[n]._element).parentNode===this._element&&(t=t||document.createDocumentFragment()).appendChild(e);return t?(this._element.appendChild(t),this._emit("synchronize"),this):this},li.prototype.layout=function(t,e){if(this._isDestroyed)return this;var i=this._nextLayoutData;i&&dt(i.cancel)&&i.cancel();var n=hi=hi%16777216+1;this._nextLayoutData={id:n,instant:t,onFinish:e,cancel:null};for(var r=this._items,s=[],o=0;o<r.length;o++)r[o]._isActive&&s.push(r[o]);this._refreshDimensions();var a,h=this._width-this._borderLeft-this._borderRight,l=this._height-this._borderTop-this._borderBottom,u=this._settings.layout;return dt(u)?a=u(this,n,s,h,l,this._onLayoutDataReceived):(li.defaultPacker.setOptions(u),a=li.defaultPacker.createLayout(this,n,s,h,l,this._onLayoutDataReceived)),dt(a)&&this._nextLayoutData&&this._nextLayoutData.id===n&&(this._nextLayoutData.cancel=a),this},li.prototype.add=function(t,e){if(this._isDestroyed||!t)return[];var i,n=Ze(i=t)?Array.prototype.slice.call(i):Array.prototype.concat(i);if(!n.length)return n;var r,s,o,a,h=e||{},l=h.layout?h.layout:void 0===h.layout,u=this._items,d=!1;for(a=0;a<n.length;a++)(s=n[a]).parentNode!==this._element&&(r=r||document.createDocumentFragment()).appendChild(s);for(r&&this._element.appendChild(r),a=0;a<n.length;a++)s=n[a],(o=n[a]=new Ge(this,s,h.active))._isActive&&(d=!0,o._layout._skipNextAnimation=!0);for(a=0;a<n.length;a++)(o=n[a])._refreshDimensions(),o._refreshSortData();return zt(u,n,h.index),this._hasListeners("add")&&this._emit("add",n.slice(0)),d&&l&&this.layout(l===ai,dt(l)?l:void 0),n},li.prototype.remove=function(t,e){if(this._isDestroyed||!t.length)return[];var i,n,r,s=e||{},o=s.layout?s.layout:void 0===s.layout,h=!1,l=this.getItems(),u=[],d=[];for(r=0;r<t.length;r++)(n=t[r])._isDestroyed||-1!==(i=this._items.indexOf(n))&&(n._isActive&&(h=!0),u.push(n),d.push(l.indexOf(n)),n._destroy(s.removeElements),this._items.splice(i,1));return this._hasListeners(a)&&this._emit(a,u.slice(0),d),h&&o&&this.layout(o===ai,dt(o)?o:void 0),u},li.prototype.show=function(t,e){return!this._isDestroyed&&t.length&&this._setItemsVisibility(t,!0,e),this},li.prototype.hide=function(t,e){return!this._isDestroyed&&t.length&&this._setItemsVisibility(t,!1,e),this},li.prototype.filter=function(t,e){if(this._isDestroyed||!this._items.length)return this;var i,n,r=[],s=[],o=typeof t===oi,a=dt(t),h=e||{},u=!0===h.instant,d=h.syncWithLayout,c=h.layout?h.layout:void 0===h.layout,_=dt(h.onFinish)?h.onFinish:null,f=-1,p=ei;if(_&&(p=function(){++f&&_(r.slice(0),s.slice(0))}),a||o)for(n=0;n<this._items.length;n++)i=this._items[n],(a?t(i):Wt(i._element,t))?r.push(i):s.push(i);return r.length?this.show(r,{instant:u,syncWithLayout:d,onFinish:p,layout:!1}):p(),s.length?this.hide(s,{instant:u,syncWithLayout:d,onFinish:p,layout:!1}):p(),(r.length||s.length)&&(this._hasListeners(l)&&this._emit(l,r.slice(0),s.slice(0)),c&&this.layout(c===ai,dt(c)?c:void 0)),this},li.prototype.sort=function(){var t,e,i,n;function r(r,s){for(var o,a,h,l,u=0,d=0;d<t.length;d++)if(o=t[d][0],a=t[d][1],h=(r._sortData?r:r._refreshSortData())._sortData[o],l=(s._sortData?s:s._refreshSortData())._sortData[o],u="desc"===a||!a&&e?l<h?-1:l>h?1:0:h<l?-1:h>l?1:0)return u;return u||(n||(n=ci(i)),u=e?_i(n,s,r):_i(n,r,s)),u}function s(r,s){var o=e?-t(r,s):t(r,s);return o||(n||(n=ci(i)),o=e?_i(n,s,r):_i(n,r,s)),o}return function(o,a){if(this._isDestroyed||this._items.length<2)return this;var h=this._items,l=a||{},d=l.layout?l.layout:void 0===l.layout;if(e=!!l.descending,i=h.slice(0),n=null,dt(o))t=o,h.sort(s);else if(typeof o===oi)t=o.trim().split(" ").filter((function(t){return t})).map((function(t){return t.split(":")})),h.sort(r);else{if(!Array.isArray(o))throw t=e=i=n=null,new Error("Invalid comparer argument provided.");h.length=0,h.push.apply(h,o)}return this._hasListeners(u)&&this._emit(u,h.slice(0),i),d&&this.layout(d===ai,dt(d)?d:void 0),t=e=i=n=null,this}}(),li.prototype.move=function(t,e,r){if(this._isDestroyed||this._items.length<2)return this;var s,o,a=this._items,h=r||{},l=h.layout?h.layout:void 0===h.layout,u=h.action===i,c=u?i:n,_=this.getItem(t),f=this.getItem(e);return _&&f&&_!==f&&(s=a.indexOf(_),o=a.indexOf(f),u?Ut(a,s,o):jt(a,s,o),this._hasListeners(d)&&this._emit(d,{item:_,fromIndex:s,toIndex:o,action:c}),l&&this.layout(l===ai,dt(l)?l:void 0)),this},li.prototype.send=function(t,e,i,n){if(this._isDestroyed||e._isDestroyed||this===e)return this;if(!(t=this.getItem(t)))return this;var r=n||{},s=r.appendTo||document.body,o=r.layoutSender?r.layoutSender:void 0===r.layoutSender,a=r.layoutReceiver?r.layoutReceiver:void 0===r.layoutReceiver;return t._migrate.start(e,i,s),t._migrate._isActive&&t._isActive&&(o&&this.layout(o===ai,dt(o)?o:void 0),a&&e.layout(a===ai,dt(a)?a:void 0)),this},li.prototype.destroy=function(e){if(this._isDestroyed)return this;var i,n,r,s=this._element,o=this._items.slice(0),a=this._layout&&this._layout.styles||{};for((r=this)._resizeHandler&&(r._resizeHandler(!0),window.removeEventListener("resize",r._resizeHandler),r._resizeHandler=null),i=0;i<o.length;i++)o[i]._destroy(e);for(n in this._items.length=0,ge(s,this._settings.containerClass),a)s.style[n]="";return this._emit("destroy"),this._emitter.destroy(),delete t[this._id],this._isDestroyed=!0,this},li.prototype._emit=function(){this._isDestroyed||this._emitter.emit.apply(this._emitter,arguments)},li.prototype._hasListeners=function(t){return!this._isDestroyed&&this._emitter.countListeners(t)>0},li.prototype._updateBoundingRect=function(){var t=this._element.getBoundingClientRect();this._width=t.width,this._height=t.height,this._left=t.left,this._top=t.top,this._right=t.right,this._bottom=t.bottom},li.prototype._updateBorders=function(t,e,i,n){var r=this._element;t&&(this._borderLeft=vt(r,"border-left-width")),e&&(this._borderRight=vt(r,"border-right-width")),i&&(this._borderTop=vt(r,"border-top-width")),n&&(this._borderBottom=vt(r,"border-bottom-width"))},li.prototype._refreshDimensions=function(){this._updateBoundingRect(),this._updateBorders(1,1,1,1),this._boxSizing=gt(this._element,"box-sizing")},li.prototype._onLayoutDataReceived=(ii=[],function(t){if(!this._isDestroyed&&this._nextLayoutData&&this._nextLayoutData.id===t.id){var e,i,n,a,h=this,l=this._nextLayoutData.instant,u=this._nextLayoutData.onFinish,d=t.items.length,c=d;for(this._nextLayoutData=null,!this._isLayoutFinished&&this._hasListeners(o)&&this._emit(o,this._layout.items.slice(0)),this._layout=t,ii.length=0,a=0;a<d;a++)(e=t.items[a])?(i=t.slots[2*a],n=t.slots[2*a+1],e._canSkipLayout(i,n)?--c:(e._left=i,e._top=n,e.isActive()&&!e.isDragging()?ii.push(e):--c)):--c;if(t.styles&&Re(this._element,t.styles),!this._hasListeners(r)||(this._emit(r,t.items.slice(0),!0===l),this._layout.id===t.id)){var _=function(){if(!(--c>0)){var e=h._layout.id!==t.id,i=dt(l)?l:u;e||(h._isLayoutFinished=!0),dt(i)&&i(t.items.slice(0),e),!e&&h._hasListeners(s)&&h._emit(s,t.items.slice(0))}};if(!ii.length)return _(),this;for(this._isLayoutFinished=!1,a=0;a<ii.length&&this._layout.id===t.id;a++)ii[a]._layout.start(!0===l,_);return this._layout.id===t.id&&(ii.length=0),this}}}),li.prototype._setItemsVisibility=function(t,e,i){var n,s,o=this,a=t.slice(0),l=i||{},u=!0===l.instant,d=l.onFinish,c=l.layout?l.layout:void 0===l.layout,_=a.length,f=e?"showStart":h,p=e?"showEnd":"hideEnd",m=e?"show":"hide",g=!1,v=[],y=[];if(_){for(s=0;s<a.length;s++)n=a[s],(e&&!n._isActive||!e&&n._isActive)&&(g=!0),n._layout._skipNextAnimation=!(!e||n._isActive),e&&n._visibility._isHidden&&y.push(n),e?n._addToLayout():n._removeFromLayout();y.length&&(this.refreshItems(y,!0),y.length=0),g&&!1!==l.syncWithLayout?this.on(r,b):b(),g&&c&&this.layout(c===ai,dt(c)?c:void 0)}else dt(d)&&d(a);function b(){for(g&&!1!==l.syncWithLayout&&o.off(r,b),o._hasListeners(f)&&o._emit(f,a.slice(0)),s=0;s<a.length;s++)a[s]._gridId===o._id?a[s]._visibility[m](u,(function(t,e){t||v.push(e),--_<1&&(dt(d)&&d(v.slice(0)),o._hasListeners(p)&&o._emit(p,v.slice(0)))})):--_<1&&(dt(d)&&d(v.slice(0)),o._hasListeners(p)&&o._emit(p,v.slice(0)))}},ri={},function(t,e){function i(){this._delay=0,this._endDelay=0,this._fill="none",this._iterationStart=0,this._iterations=1,this._duration=0,this._playbackRate=1,this._direction="normal",this._easing="linear",this._easingFunction=c}function n(){return t.isDeprecated("Invalid timing inputs","2016-03-02","TypeError exceptions will be thrown instead.",!0)}function r(e,n,r){var s=new i;return n&&(s.fill="both",s.duration="auto"),"number"!=typeof e||isNaN(e)?void 0!==e&&Object.getOwnPropertyNames(e).forEach((function(i){if("auto"!=e[i]){if(("number"==typeof s[i]||"duration"==i)&&("number"!=typeof e[i]||isNaN(e[i])))return;if("fill"==i&&-1==u.indexOf(e[i]))return;if("direction"==i&&-1==d.indexOf(e[i]))return;if("playbackRate"==i&&1!==e[i]&&t.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;s[i]=e[i]}})):s.duration=e,s}function s(t,e,i,n){return t<0||t>1||i<0||i>1?c:function(r){function s(t,e,i){return 3*t*(1-i)*(1-i)*i+3*e*(1-i)*i*i+i*i*i}if(r<=0){var o=0;return t>0?o=e/t:!e&&i>0&&(o=n/i),o*r}if(r>=1){var a=0;return i<1?a=(n-1)/(i-1):1==i&&t<1&&(a=(e-1)/(t-1)),1+a*(r-1)}for(var h=0,l=1;h<l;){var u=(h+l)/2,d=s(t,i,u);if(Math.abs(r-d)<1e-5)return s(e,n,u);d<r?h=u:l=u}return s(e,n,u)}}function o(t,e){return function(i){if(i>=1)return 1;var n=1/t;return(i+=e*n)-i%n}}function a(t){g||(g=document.createElement("div").style),g.animationTimingFunction="",g.animationTimingFunction=t;var e=g.animationTimingFunction;if(""==e&&n())throw new TypeError(t+" is not a valid value for easing");return e}function h(t){if("linear"==t)return c;var e=y.exec(t);if(e)return s.apply(this,e.slice(1).map(Number));var i=b.exec(t);if(i)return o(Number(i[1]),p);var n=w.exec(t);return n?o(Number(n[1]),{start:_,middle:f,end:p}[n[2]]):m[t]||c}function l(t,e,i){if(null==e)return S;var n=i.delay+t+i.endDelay;return e<Math.min(i.delay,n)?T:e>=Math.min(i.delay+t,n)?D:x}var u="backwards|forwards|both|none".split("|"),d="reverse|alternate|alternate-reverse".split("|"),c=function(t){return t};i.prototype={_setMember:function(e,i){this["_"+e]=i,this._effect&&(this._effect._timingInput[e]=i,this._effect._timing=t.normalizeTimingInput(this._effect._timingInput),this._effect.activeDuration=t.calculateActiveDuration(this._effect._timing),this._effect._animation&&this._effect._animation._rebuildUnderlyingAnimation())},get playbackRate(){return this._playbackRate},set delay(t){this._setMember("delay",t)},get delay(){return this._delay},set endDelay(t){this._setMember("endDelay",t)},get endDelay(){return this._endDelay},set fill(t){this._setMember("fill",t)},get fill(){return this._fill},set iterationStart(t){if((isNaN(t)||t<0)&&n())throw new TypeError("iterationStart must be a non-negative number, received: "+t);this._setMember("iterationStart",t)},get iterationStart(){return this._iterationStart},set duration(t){if("auto"!=t&&(isNaN(t)||t<0)&&n())throw new TypeError("duration must be non-negative or auto, received: "+t);this._setMember("duration",t)},get duration(){return this._duration},set direction(t){this._setMember("direction",t)},get direction(){return this._direction},set easing(t){this._easingFunction=h(a(t)),this._setMember("easing",t)},get easing(){return this._easing},set iterations(t){if((isNaN(t)||t<0)&&n())throw new TypeError("iterations must be non-negative, received: "+t);this._setMember("iterations",t)},get iterations(){return this._iterations}};var _=1,f=.5,p=0,m={ease:s(.25,.1,.25,1),"ease-in":s(.42,0,1,1),"ease-out":s(0,0,.58,1),"ease-in-out":s(.42,0,.58,1),"step-start":o(1,_),"step-middle":o(1,f),"step-end":o(1,p)},g=null,v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",y=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),b=/steps\(\s*(\d+)\s*\)/,w=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,S=0,T=1,D=2,x=3;t.cloneTimingInput=function(t){if("number"==typeof t)return t;var e={};for(var i in t)e[i]=t[i];return e},t.makeTiming=r,t.numericTimingToObject=function(t){return"number"==typeof t&&(t=isNaN(t)?{duration:0}:{duration:t}),t},t.normalizeTimingInput=function(e,i){return r(e=t.numericTimingToObject(e),i)},t.calculateActiveDuration=function(t){return Math.abs(function(t){return 0===t.duration||0===t.iterations?0:t.duration*t.iterations}(t)/t.playbackRate)},t.calculateIterationProgress=function(t,e,i){var n=l(t,e,i),r=function(t,e,i,n,r){switch(n){case T:return"backwards"==e||"both"==e?0:null;case x:return i-r;case D:return"forwards"==e||"both"==e?t:null;case S:return null}}(t,i.fill,e,n,i.delay);if(null===r)return null;var s=function(t,e,i,n,r){var s=r;return 0===t?e!==T&&(s+=i):s+=n/t,s}(i.duration,n,i.iterations,r,i.iterationStart),o=function(t,e,i,n,r,s){var o=t===1/0?e%1:t%1;return 0!==o||i!==D||0===n||0===r&&0!==s||(o=1),o}(s,i.iterationStart,n,i.iterations,r,i.duration),a=function(t,e,i,n){return t===D&&e===1/0?1/0:1===i?Math.floor(n)-1:Math.floor(n)}(n,i.iterations,o,s),h=function(t,e,i){var n=t;if("normal"!==t&&"reverse"!==t){var r=e;"alternate-reverse"===t&&(r+=1),n="normal",r!==1/0&&r%2!=0&&(n="reverse")}return"normal"===n?i:1-i}(i.direction,a,o);return i._easingFunction(h)},t.calculatePhase=l,t.normalizeEasing=a,t.parseEasingFunction=h}(ni={}),function(t,e){function i(t,e){return t in h&&h[t][e]||e}function n(t,e,n){if(!function(t){return"display"===t||0===t.lastIndexOf("animation",0)||0===t.lastIndexOf("transition",0)}(t)){var r=s[t];if(r)for(var a in o.style[t]=e,r){var h=r[a],l=o.style[h];n[h]=i(h,l)}else n[t]=i(t,e)}}function r(t){var e=[];for(var i in t)if(!(i in["easing","offset","composite"])){var n=t[i];Array.isArray(n)||(n=[n]);for(var r,s=n.length,o=0;o<s;o++)(r={}).offset="offset"in t?t.offset:1==s?1:o/(s-1),"easing"in t&&(r.easing=t.easing),"composite"in t&&(r.composite=t.composite),r[i]=n[o],e.push(r)}return e.sort((function(t,e){return t.offset-e.offset})),e}var s={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},o=document.createElementNS("http://www.w3.org/1999/xhtml","div"),a={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:a,borderLeftWidth:a,borderRightWidth:a,borderTopWidth:a,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:a,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};t.convertToArrayForm=r,t.normalizeKeyframes=function(e){if(null==e)return[];window.Symbol&&Symbol.iterator&&Array.prototype.from&&e[Symbol.iterator]&&(e=Array.from(e)),Array.isArray(e)||(e=r(e));for(var i=e.map((function(e){var i={};for(var r in e){var s=e[r];if("offset"==r){if(null!=s){if(s=Number(s),!isFinite(s))throw new TypeError("Keyframe offsets must be numbers.");if(s<0||s>1)throw new TypeError("Keyframe offsets must be between 0 and 1.")}}else if("composite"==r){if("add"==s||"accumulate"==s)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};if("replace"!=s)throw new TypeError("Invalid composite mode "+s+".")}else s="easing"==r?t.normalizeEasing(s):""+s;n(r,s,i)}return null==i.offset&&(i.offset=null),null==i.easing&&(i.easing="linear"),i})),s=!0,o=-1/0,a=0;a<i.length;a++){var h=i[a].offset;if(null!=h){if(h<o)throw new TypeError("Keyframes are not loosely sorted by offset. Sort or specify offsets.");o=h}else s=!1}return i=i.filter((function(t){return t.offset>=0&&t.offset<=1})),s||function(){var t=i.length;null==i[t-1].offset&&(i[t-1].offset=1),t>1&&null==i[0].offset&&(i[0].offset=0);for(var e=0,n=i[0].offset,r=1;r<t;r++){var s=i[r].offset;if(null!=s){for(var o=1;o<r-e;o++)i[e+o].offset=n+(s-n)*o/(r-e);e=r,n=s}}}(),i}}(ni),function(t){var e={};t.isDeprecated=function(t,i,n,r){var s=r?"are":"is",o=new Date,a=new Date(i);return a.setMonth(a.getMonth()+3),!(o<a&&(t in e||console.warn("Web Animations: "+t+" "+s+" deprecated and will stop working on "+a.toDateString()+". "+n),e[t]=!0,1))},t.deprecated=function(e,i,n,r){var s=r?"are":"is";if(t.isDeprecated(e,i,n,r))throw new Error(e+" "+s+" no longer supported. "+n)}}(ni),function(){if(document.documentElement.animate){var t=document.documentElement.animate([],0),e=!0;if(t&&(e=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach((function(i){void 0===t[i]&&(e=!0)}))),!e)return}!function(t,e,i){e.convertEffectInput=function(i){var n=function(t){for(var e={},i=0;i<t.length;i++)for(var n in t[i])if("offset"!=n&&"easing"!=n&&"composite"!=n){var r={offset:t[i].offset,easing:t[i].easing,value:t[i][n]};e[n]=e[n]||[],e[n].push(r)}for(var s in e){var o=e[s];if(0!=o[0].offset||1!=o[o.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return e}(t.normalizeKeyframes(i)),r=function(i){var n=[];for(var r in i)for(var s=i[r],o=0;o<s.length-1;o++){var a=o,h=o+1,l=s[a].offset,u=s[h].offset,d=l,c=u;0==o&&(d=-1/0,0==u&&(h=a)),o==s.length-2&&(c=1/0,1==l&&(a=h)),n.push({applyFrom:d,applyTo:c,startOffset:s[a].offset,endOffset:s[h].offset,easingFunction:t.parseEasingFunction(s[a].easing),property:r,interpolation:e.propertyInterpolation(r,s[a].value,s[h].value)})}return n.sort((function(t,e){return t.startOffset-e.startOffset})),n}(n);return function(t,i){if(null!=i)r.filter((function(t){return i>=t.applyFrom&&i<t.applyTo})).forEach((function(n){var r=i-n.startOffset,s=n.endOffset-n.startOffset,o=0==s?0:n.easingFunction(r/s);e.apply(t,n.property,n.interpolation(o))}));else for(var s in n)"offset"!=s&&"easing"!=s&&"composite"!=s&&e.clear(t,s)}}}(ni,ri),function(t,e,i){function n(t){return t.replace(/-(.)/g,(function(t,e){return e.toUpperCase()}))}function r(t,e,i){s[i]=s[i]||[],s[i].push([t,e])}var s={};e.addPropertiesHandler=function(t,e,i){for(var s=0;s<i.length;s++)r(t,e,n(i[s]))};var o={backgroundColor:"transparent",backgroundPosition:"0% 0%",borderBottomColor:"currentColor",borderBottomLeftRadius:"0px",borderBottomRightRadius:"0px",borderBottomWidth:"3px",borderLeftColor:"currentColor",borderLeftWidth:"3px",borderRightColor:"currentColor",borderRightWidth:"3px",borderSpacing:"2px",borderTopColor:"currentColor",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderTopWidth:"3px",bottom:"auto",clip:"rect(0px, 0px, 0px, 0px)",color:"black",fontSize:"100%",fontWeight:"400",height:"auto",left:"auto",letterSpacing:"normal",lineHeight:"120%",marginBottom:"0px",marginLeft:"0px",marginRight:"0px",marginTop:"0px",maxHeight:"none",maxWidth:"none",minHeight:"0px",minWidth:"0px",opacity:"1.0",outlineColor:"invert",outlineOffset:"0px",outlineWidth:"3px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",paddingTop:"0px",right:"auto",strokeDasharray:"none",strokeDashoffset:"0px",textIndent:"0px",textShadow:"0px 0px 0px transparent",top:"auto",transform:"",verticalAlign:"0px",visibility:"visible",width:"auto",wordSpacing:"normal",zIndex:"auto"};e.propertyInterpolation=function(i,r,a){var h=i;/-/.test(i)&&!t.isDeprecated("Hyphenated property names","2016-03-22","Use camelCase instead.",!0)&&(h=n(i)),"initial"!=r&&"initial"!=a||("initial"==r&&(r=o[h]),"initial"==a&&(a=o[h]));for(var l=r==a?[]:s[h],u=0;l&&u<l.length;u++){var d=l[u][0](r),c=l[u][0](a);if(void 0!==d&&void 0!==c){var _=l[u][1](d,c);if(_){var f=e.Interpolation.apply(null,_);return function(t){return 0==t?r:1==t?a:f(t)}}}}return e.Interpolation(!1,!0,(function(t){return t?a:r}))}}(ni,ri),function(t,e,i){e.KeyframeEffect=function(i,n,r,s){var o,a=function(e){var i=t.calculateActiveDuration(e),n=function(n){return t.calculateIterationProgress(i,n,e)};return n._totalDuration=e.delay+i+e.endDelay,n}(t.normalizeTimingInput(r)),h=e.convertEffectInput(n),l=function(){h(i,o)};return l._update=function(t){return null!==(o=a(t))},l._clear=function(){h(i,null)},l._hasSameTarget=function(t){return i===t},l._target=i,l._totalDuration=a._totalDuration,l._id=s,l}}(ni,ri),function(t,e){function i(t,e,i){i.enumerable=!0,i.configurable=!0,Object.defineProperty(t,e,i)}function n(t){this._element=t,this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=t.style,this._length=0,this._isAnimatedProperty={},this._updateSvgTransformAttr=function(t,e){return!(!e.namespaceURI||-1==e.namespaceURI.indexOf("/svg"))&&(s in t||(t[s]=/Trident|MSIE|IEMobile|Edge|Android 4/i.test(t.navigator.userAgent)),t[s])}(window,t),this._savedTransformAttr=null;for(var e=0;e<this._style.length;e++){var i=this._style[e];this._surrogateStyle[i]=this._style[i]}this._updateIndices()}function r(t){if(!t._webAnimationsPatchedStyle){var e=new n(t);try{i(t,"style",{get:function(){return e}})}catch(e){t.style._set=function(e,i){t.style[e]=i},t.style._clear=function(e){t.style[e]=""}}t._webAnimationsPatchedStyle=t.style}}var s="_webAnimationsUpdateSvgTransformAttr",o={cssText:1,length:1,parentRule:1},a={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},h={removeProperty:1,setProperty:1};for(var l in n.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(t){for(var e={},i=0;i<this._surrogateStyle.length;i++)e[this._surrogateStyle[i]]=!0;for(this._surrogateStyle.cssText=t,this._updateIndices(),i=0;i<this._surrogateStyle.length;i++)e[this._surrogateStyle[i]]=!0;for(var n in e)this._isAnimatedProperty[n]||this._style.setProperty(n,this._surrogateStyle.getPropertyValue(n))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(t){return function(){return this._surrogateStyle[t]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(e,i){this._style[e]=i,this._isAnimatedProperty[e]=!0,this._updateSvgTransformAttr&&"transform"==t.unprefixedPropertyName(e)&&(null==this._savedTransformAttr&&(this._savedTransformAttr=this._element.getAttribute("transform")),this._element.setAttribute("transform",t.transformToSvgMatrix(i)))},_clear:function(e){this._style[e]=this._surrogateStyle[e],this._updateSvgTransformAttr&&"transform"==t.unprefixedPropertyName(e)&&(this._savedTransformAttr?this._element.setAttribute("transform",this._savedTransformAttr):this._element.removeAttribute("transform"),this._savedTransformAttr=null),delete this._isAnimatedProperty[e]}},a)n.prototype[l]=function(t,e){return function(){var i=this._surrogateStyle[t].apply(this._surrogateStyle,arguments);return e&&(this._isAnimatedProperty[arguments[0]]||this._style[t].apply(this._style,arguments),this._updateIndices()),i}}(l,l in h);for(var u in document.documentElement.style)u in o||u in a||function(t){i(n.prototype,t,{get:function(){return this._surrogateStyle[t]},set:function(e){this._surrogateStyle[t]=e,this._updateIndices(),this._isAnimatedProperty[t]||(this._style[t]=e)}})}(u);t.apply=function(e,i,n){r(e),e.style._set(t.propertyName(i),n)},t.clear=function(e,i){e._webAnimationsPatchedStyle&&e.style._clear(t.propertyName(i))}}(ri),function(t){window.Element.prototype.animate=function(e,i){var n="";return i&&i.id&&(n=i.id),t.timeline._play(t.KeyframeEffect(this,e,i,n))}}(ri),function(t,e){function i(t,e,n){if("number"==typeof t&&"number"==typeof e)return t*(1-n)+e*n;if("boolean"==typeof t&&"boolean"==typeof e)return n<.5?t:e;if(t.length==e.length){for(var r=[],s=0;s<t.length;s++)r.push(i(t[s],e[s],n));return r}throw"Mismatched interpolation arguments "+t+":"+e}t.Interpolation=function(t,e,n){return function(r){return n(i(t,e,r))}}}(ri),function(t,e){var i=function(){function t(t,e){for(var i=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],n=0;n<4;n++)for(var r=0;r<4;r++)for(var s=0;s<4;s++)i[n][r]+=e[n][s]*t[s][r];return i}return function(e,i,n,r,s){for(var o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],a=0;a<4;a++)o[a][3]=s[a];for(a=0;a<3;a++)for(var h=0;h<3;h++)o[3][a]+=e[h]*o[h][a];var l=r[0],u=r[1],d=r[2],c=r[3],_=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];_[0][0]=1-2*(u*u+d*d),_[0][1]=2*(l*u-d*c),_[0][2]=2*(l*d+u*c),_[1][0]=2*(l*u+d*c),_[1][1]=1-2*(l*l+d*d),_[1][2]=2*(u*d-l*c),_[2][0]=2*(l*d-u*c),_[2][1]=2*(u*d+l*c),_[2][2]=1-2*(l*l+u*u),o=t(o,_);var f=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];for(n[2]&&(f[2][1]=n[2],o=t(o,f)),n[1]&&(f[2][1]=0,f[2][0]=n[0],o=t(o,f)),n[0]&&(f[2][0]=0,f[1][0]=n[0],o=t(o,f)),a=0;a<3;a++)for(h=0;h<3;h++)o[a][h]*=i[a];return function(t){return 0==t[0][2]&&0==t[0][3]&&0==t[1][2]&&0==t[1][3]&&0==t[2][0]&&0==t[2][1]&&1==t[2][2]&&0==t[2][3]&&0==t[3][2]&&1==t[3][3]}(o)?[o[0][0],o[0][1],o[1][0],o[1][1],o[3][0],o[3][1]]:o[0].concat(o[1],o[2],o[3])}}();t.composeMatrix=i,t.quat=function(e,i,n){var r=t.dot(e,i);r=function(t,e,i){return Math.max(Math.min(t,i),e)}(r,-1,1);var s=[];if(1===r)s=e;else for(var o=Math.acos(r),a=1*Math.sin(n*o)/Math.sqrt(1-r*r),h=0;h<4;h++)s.push(e[h]*(Math.cos(n*o)-r*a)+i[h]*a);return s}}(ri),function(t,e,i){t.sequenceNumber=0;var n=function(t,e,i){this.target=t,this.currentTime=e,this.timelineTime=i,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=t,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};e.Animation=function(e){this.id="",e&&e._id&&(this.id=e._id),this._sequenceNumber=t.sequenceNumber++,this._currentTime=0,this._startTime=null,this._paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!0,this.onfinish=null,this._finishHandlers=[],this._effect=e,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},e.Animation.prototype={_ensureAlive:function(){this.playbackRate<0&&0===this.currentTime?this._inEffect=this._effect._update(-1):this._inEffect=this._effect._update(this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,e.timeline._animations.push(this))},_tickCurrentTime:function(t,e){t!=this._currentTime&&(this._currentTime=t,this._isFinished&&!e&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(t){t=+t,isNaN(t)||(e.restart(),this._paused||null==this._startTime||(this._startTime=this._timeline.currentTime-t/this._playbackRate),this._currentTimePending=!1,this._currentTime!=t&&(this._idle&&(this._idle=!1,this._paused=!0),this._tickCurrentTime(t,!0),e.applyDirtiedAnimation(this)))},get startTime(){return this._startTime},set startTime(t){t=+t,isNaN(t)||this._paused||this._idle||(this._startTime=t,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),e.applyDirtiedAnimation(this))},get playbackRate(){return this._playbackRate},set playbackRate(t){if(t!=this._playbackRate){var i=this.currentTime;this._playbackRate=t,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&(this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),e.applyDirtiedAnimation(this)),null!=i&&(this.currentTime=i)}},get _isFinished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this._paused&&0!=this.playbackRate||this._currentTimePending?"pending":this._paused?"paused":this._isFinished?"finished":"running"},_rewind:function(){if(this._playbackRate>=0)this._currentTime=0;else{if(!(this._totalDuration<1/0))throw new DOMException("Unable to rewind negative playback rate animation with infinite duration","InvalidStateError");this._currentTime=this._totalDuration}},play:function(){this._paused=!1,(this._isFinished||this._idle)&&(this._rewind(),this._startTime=null),this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),e.applyDirtiedAnimation(this)},pause:function(){this._isFinished||this._paused||this._idle?this._idle&&(this._rewind(),this._idle=!1):this._currentTimePending=!0,this._startTime=null,this._paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1,e.applyDirtiedAnimation(this))},cancel:function(){this._inEffect&&(this._inEffect=!1,this._idle=!0,this._paused=!1,this._finishedFlag=!0,this._currentTime=0,this._startTime=null,this._effect._update(null),e.applyDirtiedAnimation(this))},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(t,e){"function"==typeof e&&"finish"==t&&this._finishHandlers.push(e)},removeEventListener:function(t,e){if("finish"==t){var i=this._finishHandlers.indexOf(e);i>=0&&this._finishHandlers.splice(i,1)}},_fireEvents:function(t){if(this._isFinished){if(!this._finishedFlag){var e=new n(this,this._currentTime,t),i=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout((function(){i.forEach((function(t){t.call(e.target,e)}))}),0),this._finishedFlag=!0}}else this._finishedFlag=!1},_tick:function(t,e){this._idle||this._paused||(null==this._startTime?e&&(this.startTime=t-this._currentTime/this.playbackRate):this._isFinished||this._tickCurrentTime((t-this._startTime)*this.playbackRate)),e&&(this._currentTimePending=!1,this._fireEvents(t))},get _needsTick(){return this.playState in{pending:1,running:1}||!this._finishedFlag},_targetAnimations:function(){var t=this._effect._target;return t._activeAnimations||(t._activeAnimations=[]),t._activeAnimations},_markTarget:function(){var t=this._targetAnimations();-1===t.indexOf(this)&&t.push(this)},_unmarkTarget:function(){var t=this._targetAnimations(),e=t.indexOf(this);-1!==e&&t.splice(e,1)}}}(ni,ri),function(t,e,i){function n(t){var e=l;l=[],t<p.currentTime&&(t=p.currentTime),p._animations.sort(r),p._animations=a(t,!0,p._animations)[0],e.forEach((function(e){e[1](t)})),o()}function r(t,e){return t._sequenceNumber-e._sequenceNumber}function s(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function o(){_.forEach((function(t){t()})),_.length=0}function a(t,i,n){f=!0,c=!1,e.timeline.currentTime=t,d=!1;var r=[],s=[],o=[],a=[];return n.forEach((function(e){e._tick(t,i),e._inEffect?(s.push(e._effect),e._markTarget()):(r.push(e._effect),e._unmarkTarget()),e._needsTick&&(d=!0);var n=e._inEffect||e._needsTick;e._inTimeline=n,n?o.push(e):a.push(e)})),_.push.apply(_,r),_.push.apply(_,s),d&&requestAnimationFrame((function(){})),f=!1,[o,a]}var h=window.requestAnimationFrame,l=[],u=0;window.requestAnimationFrame=function(t){var e=u++;return 0==l.length&&h(n),l.push([e,t]),e},window.cancelAnimationFrame=function(t){l.forEach((function(e){e[0]==t&&(e[1]=function(){})}))},s.prototype={_play:function(i){i._timing=t.normalizeTimingInput(i.timing);var n=new e.Animation(i);return n._idle=!1,n._timeline=this,this._animations.push(n),e.restart(),e.applyDirtiedAnimation(n),n}};var d=!1,c=!1;e.restart=function(){return d||(d=!0,requestAnimationFrame((function(){})),c=!0),c},e.applyDirtiedAnimation=function(t){if(!f){t._markTarget();var i=t._targetAnimations();i.sort(r),a(e.timeline.currentTime,!1,i.slice())[1].forEach((function(t){var e=p._animations.indexOf(t);-1!==e&&p._animations.splice(e,1)})),o()}};var _=[],f=!1,p=new s;e.timeline=p}(ni,ri),function(t,e){function i(t,e){for(var i=0,n=0;n<t.length;n++)i+=t[n]*e[n];return i}function n(t,e){return[t[0]*e[0]+t[4]*e[1]+t[8]*e[2]+t[12]*e[3],t[1]*e[0]+t[5]*e[1]+t[9]*e[2]+t[13]*e[3],t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]*e[3],t[3]*e[0]+t[7]*e[1]+t[11]*e[2]+t[15]*e[3],t[0]*e[4]+t[4]*e[5]+t[8]*e[6]+t[12]*e[7],t[1]*e[4]+t[5]*e[5]+t[9]*e[6]+t[13]*e[7],t[2]*e[4]+t[6]*e[5]+t[10]*e[6]+t[14]*e[7],t[3]*e[4]+t[7]*e[5]+t[11]*e[6]+t[15]*e[7],t[0]*e[8]+t[4]*e[9]+t[8]*e[10]+t[12]*e[11],t[1]*e[8]+t[5]*e[9]+t[9]*e[10]+t[13]*e[11],t[2]*e[8]+t[6]*e[9]+t[10]*e[10]+t[14]*e[11],t[3]*e[8]+t[7]*e[9]+t[11]*e[10]+t[15]*e[11],t[0]*e[12]+t[4]*e[13]+t[8]*e[14]+t[12]*e[15],t[1]*e[12]+t[5]*e[13]+t[9]*e[14]+t[13]*e[15],t[2]*e[12]+t[6]*e[13]+t[10]*e[14]+t[14]*e[15],t[3]*e[12]+t[7]*e[13]+t[11]*e[14]+t[15]*e[15]]}function r(t){var e=t.rad||0;return((t.deg||0)/360+(t.grad||0)/400+(t.turn||0))*(2*Math.PI)+e}function s(t){switch(t.t){case"rotatex":var e=r(t.d[0]);return[1,0,0,0,0,Math.cos(e),Math.sin(e),0,0,-Math.sin(e),Math.cos(e),0,0,0,0,1];case"rotatey":return e=r(t.d[0]),[Math.cos(e),0,-Math.sin(e),0,0,1,0,0,Math.sin(e),0,Math.cos(e),0,0,0,0,1];case"rotate":case"rotatez":return e=r(t.d[0]),[Math.cos(e),Math.sin(e),0,0,-Math.sin(e),Math.cos(e),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var i=t.d[0],n=t.d[1],s=t.d[2],o=(e=r(t.d[3]),i*i+n*n+s*s);if(0===o)i=1,n=0,s=0;else if(1!==o){var a=Math.sqrt(o);i/=a,n/=a,s/=a}var h=Math.sin(e/2),l=h*Math.cos(e/2),u=h*h;return[1-2*(n*n+s*s)*u,2*(i*n*u+s*l),2*(i*s*u-n*l),0,2*(i*n*u-s*l),1-2*(i*i+s*s)*u,2*(n*s*u+i*l),0,2*(i*s*u+n*l),2*(n*s*u-i*l),1-2*(i*i+n*n)*u,0,0,0,0,1];case"scale":return[t.d[0],0,0,0,0,t.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[t.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,t.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,t.d[0],0,0,0,0,1];case"scale3d":return[t.d[0],0,0,0,0,t.d[1],0,0,0,0,t.d[2],0,0,0,0,1];case"skew":var d=r(t.d[0]),c=r(t.d[1]);return[1,Math.tan(c),0,0,Math.tan(d),1,0,0,0,0,1,0,0,0,0,1];case"skewx":return e=r(t.d[0]),[1,0,0,0,Math.tan(e),1,0,0,0,0,1,0,0,0,0,1];case"skewy":return e=r(t.d[0]),[1,Math.tan(e),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,n=t.d[1].px||0,0,1];case"translatex":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,0,0,1];case"translatey":return[1,0,0,0,0,1,0,0,0,0,1,0,0,n=t.d[0].px||0,0,1];case"translatez":return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,s=t.d[0].px||0,1];case"translate3d":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,n=t.d[1].px||0,s=t.d[2].px||0,1];case"perspective":return[1,0,0,0,0,1,0,0,0,0,1,t.d[0].px?-1/t.d[0].px:0,0,0,0,1];case"matrix":return[t.d[0],t.d[1],0,0,t.d[2],t.d[3],0,0,0,0,1,0,t.d[4],t.d[5],0,1];case"matrix3d":return t.d}}function o(t){return 0===t.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:t.map(s).reduce(n)}var a=function(){function t(t){return t[0][0]*t[1][1]*t[2][2]+t[1][0]*t[2][1]*t[0][2]+t[2][0]*t[0][1]*t[1][2]-t[0][2]*t[1][1]*t[2][0]-t[1][2]*t[2][1]*t[0][0]-t[2][2]*t[0][1]*t[1][0]}function e(t){var e=n(t);return[t[0]/e,t[1]/e,t[2]/e]}function n(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2])}function r(t,e,i,n){return[i*t[0]+n*e[0],i*t[1]+n*e[1],i*t[2]+n*e[2]]}return function(s){var o=[s.slice(0,4),s.slice(4,8),s.slice(8,12),s.slice(12,16)];if(1!==o[3][3])return null;for(var a=[],h=0;h<4;h++)a.push(o[h].slice());for(h=0;h<3;h++)a[h][3]=0;if(0===t(a))return null;var l,u=[];o[0][3]||o[1][3]||o[2][3]?(u.push(o[0][3]),u.push(o[1][3]),u.push(o[2][3]),u.push(o[3][3]),l=function(t,e){for(var i=[],n=0;n<4;n++){for(var r=0,s=0;s<4;s++)r+=t[s]*e[s][n];i.push(r)}return i}(u,function(t){return[[t[0][0],t[1][0],t[2][0],t[3][0]],[t[0][1],t[1][1],t[2][1],t[3][1]],[t[0][2],t[1][2],t[2][2],t[3][2]],[t[0][3],t[1][3],t[2][3],t[3][3]]]}(function(e){for(var i=1/t(e),n=e[0][0],r=e[0][1],s=e[0][2],o=e[1][0],a=e[1][1],h=e[1][2],l=e[2][0],u=e[2][1],d=e[2][2],c=[[(a*d-h*u)*i,(s*u-r*d)*i,(r*h-s*a)*i,0],[(h*l-o*d)*i,(n*d-s*l)*i,(s*o-n*h)*i,0],[(o*u-a*l)*i,(l*r-n*u)*i,(n*a-r*o)*i,0]],_=[],f=0;f<3;f++){for(var p=0,m=0;m<3;m++)p+=e[3][m]*c[m][f];_.push(p)}return _.push(1),c.push(_),c}(a)))):l=[0,0,0,1];var d=o[3].slice(0,3),c=[];c.push(o[0].slice(0,3));var _=[];_.push(n(c[0])),c[0]=e(c[0]);var f=[];c.push(o[1].slice(0,3)),f.push(i(c[0],c[1])),c[1]=r(c[1],c[0],1,-f[0]),_.push(n(c[1])),c[1]=e(c[1]),f[0]/=_[1],c.push(o[2].slice(0,3)),f.push(i(c[0],c[2])),c[2]=r(c[2],c[0],1,-f[1]),f.push(i(c[1],c[2])),c[2]=r(c[2],c[1],1,-f[2]),_.push(n(c[2])),c[2]=e(c[2]),f[1]/=_[2],f[2]/=_[2];var p=function(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}(c[1],c[2]);if(i(c[0],p)<0)for(h=0;h<3;h++)_[h]*=-1,c[h][0]*=-1,c[h][1]*=-1,c[h][2]*=-1;var m,g,v=c[0][0]+c[1][1]+c[2][2]+1;return v>1e-4?(m=.5/Math.sqrt(v),g=[(c[2][1]-c[1][2])*m,(c[0][2]-c[2][0])*m,(c[1][0]-c[0][1])*m,.25/m]):c[0][0]>c[1][1]&&c[0][0]>c[2][2]?g=[.25*(m=2*Math.sqrt(1+c[0][0]-c[1][1]-c[2][2])),(c[0][1]+c[1][0])/m,(c[0][2]+c[2][0])/m,(c[2][1]-c[1][2])/m]:c[1][1]>c[2][2]?(m=2*Math.sqrt(1+c[1][1]-c[0][0]-c[2][2]),g=[(c[0][1]+c[1][0])/m,.25*m,(c[1][2]+c[2][1])/m,(c[0][2]-c[2][0])/m]):(m=2*Math.sqrt(1+c[2][2]-c[0][0]-c[1][1]),g=[(c[0][2]+c[2][0])/m,(c[1][2]+c[2][1])/m,.25*m,(c[1][0]-c[0][1])/m]),[d,_,f,g,l]}}();t.dot=i,t.makeMatrixDecomposition=function(t){return[a(o(t))]},t.transformListToMatrix=o}(ri),function(t){function e(t,e){var i=t.exec(e);if(i)return[i=t.ignoreCase?i[0].toLowerCase():i[0],e.substr(i.length)]}function i(t,e){var i=t(e=e.replace(/^\s*/,""));if(i)return[i[0],i[1].replace(/^\s*/,"")]}function n(t,e,i,n,r){for(var s=[],o=[],a=[],h=function(t,e){for(var i=t,n=e;i&&n;)i>n?i%=n:n%=i;return t*e/(i+n)}(n.length,r.length),l=0;l<h;l++){var u=e(n[l%n.length],r[l%r.length]);if(!u)return;s.push(u[0]),o.push(u[1]),a.push(u[2])}return[s,o,function(e){var n=e.map((function(t,e){return a[e](t)})).join(i);return t?t(n):n}]}t.consumeToken=e,t.consumeTrimmed=i,t.consumeRepeated=function(t,n,r){t=i.bind(null,t);for(var s=[];;){var o=t(r);if(!o)return[s,r];if(s.push(o[0]),!(o=e(n,r=o[1]))||""==o[1])return[s,r];r=o[1]}},t.consumeParenthesised=function(t,e){for(var i=0,n=0;n<e.length&&(!/\s|,/.test(e[n])||0!=i);n++)if("("==e[n])i++;else if(")"==e[n]&&(0==--i&&n++,i<=0))break;var r=t(e.substr(0,n));return null==r?void 0:[r,e.substr(n)]},t.ignore=function(t){return function(e){var i=t(e);return i&&(i[0]=void 0),i}},t.optional=function(t,e){return function(i){return t(i)||[e,i]}},t.consumeList=function(e,i){for(var n=[],r=0;r<e.length;r++){var s=t.consumeTrimmed(e[r],i);if(!s||""==s[0])return;void 0!==s[0]&&n.push(s[0]),i=s[1]}if(""==i)return n},t.mergeNestedRepeated=n.bind(null,null),t.mergeWrappedNestedRepeated=n,t.mergeList=function(t,e,i){for(var n=[],r=[],s=[],o=0,a=0;a<i.length;a++)if("function"==typeof i[a]){var h=i[a](t[o],e[o++]);n.push(h[0]),r.push(h[1]),s.push(h[2])}else!function(t){n.push(!1),r.push(!1),s.push((function(){return i[t]}))}(a);return[n,r,function(t){for(var e="",i=0;i<t.length;i++)e+=s[i](t[i]);return e}]}}(ri),function(t){function e(e){var i={inset:!1,lengths:[],color:null},n=t.consumeRepeated((function(e){var n=t.consumeToken(/^inset/i,e);return n?(i.inset=!0,n):(n=t.consumeLengthOrPercent(e))?(i.lengths.push(n[0]),n):(n=t.consumeColor(e))?(i.color=n[0],n):void 0}),/^/,e);if(n&&n[0].length)return[i,n[1]]}var i=function(e,i,n,r){function s(t){return{inset:t,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var o=[],a=[],h=0;h<n.length||h<r.length;h++){var l=n[h]||s(r[h].inset),u=r[h]||s(n[h].inset);o.push(l),a.push(u)}return t.mergeNestedRepeated(e,i,o,a)}.bind(null,(function(e,i){for(;e.lengths.length<Math.max(e.lengths.length,i.lengths.length);)e.lengths.push({px:0});for(;i.lengths.length<Math.max(e.lengths.length,i.lengths.length);)i.lengths.push({px:0});if(e.inset==i.inset&&!!e.color==!!i.color){for(var n,r=[],s=[[],0],o=[[],0],a=0;a<e.lengths.length;a++){var h=t.mergeDimensions(e.lengths[a],i.lengths[a],2==a);s[0].push(h[0]),o[0].push(h[1]),r.push(h[2])}if(e.color&&i.color){var l=t.mergeColors(e.color,i.color);s[1]=l[0],o[1]=l[1],n=l[2]}return[s,o,function(t){for(var i=e.inset?"inset ":" ",s=0;s<r.length;s++)i+=r[s](t[0][s])+" ";return n&&(i+=n(t[1])),i}]}}),", ");t.addPropertiesHandler((function(i){var n=t.consumeRepeated(e,/^,/,i);if(n&&""==n[1])return n[0]}),i,["box-shadow","text-shadow"])}(ri),function(t,e){function i(t){return t.toFixed(3).replace(/0+$/,"").replace(/\.$/,"")}function n(t,e,i){return Math.min(e,Math.max(t,i))}function r(t){if(/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t))return Number(t)}function s(t,e){return function(r,s){return[r,s,function(r){return i(n(t,e,r))}]}}function o(t){var e=t.trim().split(/\s*[\s,]\s*/);if(0!==e.length){for(var i=[],n=0;n<e.length;n++){var s=r(e[n]);if(void 0===s)return;i.push(s)}return i}}t.clamp=n,t.addPropertiesHandler(o,(function(t,e){if(t.length==e.length)return[t,e,function(t){return t.map(i).join(" ")}]}),["stroke-dasharray"]),t.addPropertiesHandler(r,s(0,1/0),["border-image-width","line-height"]),t.addPropertiesHandler(r,s(0,1),["opacity","shape-image-threshold"]),t.addPropertiesHandler(r,(function(t,e){if(0!=t)return s(0,1/0)(t,e)}),["flex-grow","flex-shrink"]),t.addPropertiesHandler(r,(function(t,e){return[t,e,function(t){return Math.round(n(1,1/0,t))}]}),["orphans","widows"]),t.addPropertiesHandler(r,(function(t,e){return[t,e,Math.round]}),["z-index"]),t.parseNumber=r,t.parseNumberList=o,t.mergeNumbers=function(t,e){return[t,e,i]},t.numberToString=i}(ri),function(t,e){t.addPropertiesHandler(String,(function(t,e){if("visible"==t||"visible"==e)return[0,1,function(i){return i<=0?t:i>=1?e:"visible"}]}),["visibility"])}(ri),function(t,e){function i(t){t=t.trim(),s.fillStyle="#000",s.fillStyle=t;var e=s.fillStyle;if(s.fillStyle="#fff",s.fillStyle=t,e==s.fillStyle){s.fillRect(0,0,1,1);var i=s.getImageData(0,0,1,1).data;s.clearRect(0,0,1,1);var n=i[3]/255;return[i[0]*n,i[1]*n,i[2]*n,n]}}function n(e,i){return[e,i,function(e){function i(t){return Math.max(0,Math.min(255,t))}if(e[3])for(var n=0;n<3;n++)e[n]=Math.round(i(e[n]/e[3]));return e[3]=t.numberToString(t.clamp(0,1,e[3])),"rgba("+e.join(",")+")"}]}var r=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");r.width=r.height=1;var s=r.getContext("2d");t.addPropertiesHandler(i,n,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","fill","flood-color","lighting-color","outline-color","stop-color","stroke","text-decoration-color"]),t.consumeColor=t.consumeParenthesised.bind(null,i),t.mergeColors=n}(ri),function(t,e){function i(t){function e(){var e=o.exec(t);s=e?e[0]:void 0}function i(){if("("!==s)return function(){var t=Number(s);return e(),t}();e();var t=r();return")"!==s?NaN:(e(),t)}function n(){for(var t=i();"*"===s||"/"===s;){var n=s;e();var r=i();"*"===n?t*=r:t/=r}return t}function r(){for(var t=n();"+"===s||"-"===s;){var i=s;e();var r=n();"+"===i?t+=r:t-=r}return t}var s,o=/([\+\-\w\.]+|[\(\)\*\/])/g;return e(),r()}function n(t,e){if("0"==(e=e.trim().toLowerCase())&&"px".search(t)>=0)return{px:0};if(/^[^(]*$|^calc/.test(e)){e=e.replace(/calc\(/g,"(");var n={};e=e.replace(t,(function(t){return n[t]=null,"U"+t}));for(var r="U("+t.source+")",s=e.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g,"N").replace(new RegExp("N"+r,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),o=[/N\*(D)/g,/(N|D)[*\/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],a=0;a<o.length;)o[a].test(s)?(s=s.replace(o[a],"$1"),a=0):a++;if("D"==s){for(var h in n){var l=i(e.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(r,"g"),"*0"));if(!isFinite(l))return;n[h]=l}return n}}}function r(t,e){return s(t,e,!0)}function s(e,i,n){var r,s=[];for(r in e)s.push(r);for(r in i)s.indexOf(r)<0&&s.push(r);return e=s.map((function(t){return e[t]||0})),i=s.map((function(t){return i[t]||0})),[e,i,function(e){var i=e.map((function(i,r){return 1==e.length&&n&&(i=Math.max(i,0)),t.numberToString(i)+s[r]})).join(" + ");return e.length>1?"calc("+i+")":i}]}var o="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",a=n.bind(null,new RegExp(o,"g")),h=n.bind(null,new RegExp(o+"|%","g")),l=n.bind(null,/deg|rad|grad|turn/g);t.parseLength=a,t.parseLengthOrPercent=h,t.consumeLengthOrPercent=t.consumeParenthesised.bind(null,h),t.parseAngle=l,t.mergeDimensions=s;var u=t.consumeParenthesised.bind(null,a),d=t.consumeRepeated.bind(void 0,u,/^/),c=t.consumeRepeated.bind(void 0,d,/^,/);t.consumeSizePairList=c;var _=t.mergeNestedRepeated.bind(void 0,r," "),f=t.mergeNestedRepeated.bind(void 0,_,",");t.mergeNonNegativeSizePair=_,t.addPropertiesHandler((function(t){var e=c(t);if(e&&""==e[1])return e[0]}),f,["background-size"]),t.addPropertiesHandler(h,r,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),t.addPropertiesHandler(h,s,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","stroke-dashoffset","text-indent","top","vertical-align","word-spacing"])}(ri),function(t,e){function i(e){return t.consumeLengthOrPercent(e)||t.consumeToken(/^auto/,e)}function n(e){var n=t.consumeList([t.ignore(t.consumeToken.bind(null,/^rect/)),t.ignore(t.consumeToken.bind(null,/^\(/)),t.consumeRepeated.bind(null,i,/^,/),t.ignore(t.consumeToken.bind(null,/^\)/))],e);if(n&&4==n[0].length)return n[0]}var r=t.mergeWrappedNestedRepeated.bind(null,(function(t){return"rect("+t+")"}),(function(e,i){return"auto"==e||"auto"==i?[!0,!1,function(n){var r=n?e:i;if("auto"==r)return"auto";var s=t.mergeDimensions(r,r);return s[2](s[0])}]:t.mergeDimensions(e,i)}),", ");t.parseBox=n,t.mergeBoxes=r,t.addPropertiesHandler(n,r,["clip"])}(ri),function(t,e){function i(t){return function(e){var i=0;return t.map((function(t){return t===l?e[i++]:t}))}}function n(t){return t}function r(e){if("none"==(e=e.toLowerCase().trim()))return[];for(var i,n=/\s*(\w+)\(([^)]*)\)/g,r=[],s=0;i=n.exec(e);){if(i.index!=s)return;s=i.index+i[0].length;var o=i[1],a=c[o];if(!a)return;var h=i[2].split(","),l=a[0];if(l.length<h.length)return;for(var _=[],f=0;f<l.length;f++){var p,m=h[f],g=l[f];if(void 0===(p=m?{A:function(e){return"0"==e.trim()?d:t.parseAngle(e)},N:t.parseNumber,T:t.parseLengthOrPercent,L:t.parseLength}[g.toUpperCase()](m):{a:d,n:_[0],t:u}[g]))return;_.push(p)}if(r.push({t:o,d:_}),n.lastIndex==e.length)return r}}function s(t){return t.toFixed(6).replace(".000000","")}function o(e,i){if(e.decompositionPair!==i){e.decompositionPair=i;var n=t.makeMatrixDecomposition(e)}if(i.decompositionPair!==e){i.decompositionPair=e;var r=t.makeMatrixDecomposition(i)}return null==n[0]||null==r[0]?[[!1],[!0],function(t){return t?i[0].d:e[0].d}]:(n[0].push(0),r[0].push(1),[n,r,function(e){var i=t.quat(n[0][3],r[0][3],e[5]);return t.composeMatrix(e[0],e[1],e[2],i,e[4]).map(s).join(",")}])}function a(t){return t.replace(/[xy]/,"")}function h(t){return t.replace(/(x|y|z|3d)?$/,"3d")}var l=null,u={px:0},d={deg:0},c={matrix:["NNNNNN",[l,l,0,0,l,l,0,0,0,0,1,0,l,l,0,1],n],matrix3d:["NNNNNNNNNNNNNNNN",n],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",i([l,l,1]),n],scalex:["N",i([l,1,1]),i([l,1])],scaley:["N",i([1,l,1]),i([1,l])],scalez:["N",i([1,1,l])],scale3d:["NNN",n],skew:["Aa",null,n],skewx:["A",null,i([l,d])],skewy:["A",null,i([d,l])],translate:["Tt",i([l,l,u]),n],translatex:["T",i([l,u,u]),i([l,u])],translatey:["T",i([u,l,u]),i([u,l])],translatez:["L",i([u,u,l])],translate3d:["TTL",n]};t.addPropertiesHandler(r,(function(e,i){var n=t.makeMatrixDecomposition&&!0,r=!1;if(!e.length||!i.length){e.length||(r=!0,e=i,i=[]);for(var s=0;s<e.length;s++){var l=e[s].t,u=e[s].d,d="scale"==l.substr(0,5)?1:0;i.push({t:l,d:u.map((function(t){if("number"==typeof t)return d;var e={};for(var i in t)e[i]=d;return e}))})}}var _=function(t,e){return"perspective"==t&&"perspective"==e||("matrix"==t||"matrix3d"==t)&&("matrix"==e||"matrix3d"==e)},f=[],p=[],m=[];if(e.length!=i.length){if(!n)return;f=[(T=o(e,i))[0]],p=[T[1]],m=[["matrix",[T[2]]]]}else for(s=0;s<e.length;s++){var g=e[s].t,v=i[s].t,y=e[s].d,b=i[s].d,w=c[g],S=c[v];if(_(g,v)){if(!n)return;var T=o([e[s]],[i[s]]);f.push(T[0]),p.push(T[1]),m.push(["matrix",[T[2]]])}else{if(g==v)l=g;else if(w[2]&&S[2]&&a(g)==a(v))l=a(g),y=w[2](y),b=S[2](b);else{if(!w[1]||!S[1]||h(g)!=h(v)){if(!n)return;f=[(T=o(e,i))[0]],p=[T[1]],m=[["matrix",[T[2]]]];break}l=h(g),y=w[1](y),b=S[1](b)}for(var D=[],x=[],A=[],k=0;k<y.length;k++)T=("number"==typeof y[k]?t.mergeNumbers:t.mergeDimensions)(y[k],b[k]),D[k]=T[0],x[k]=T[1],A.push(T[2]);f.push(D),p.push(x),m.push([l,A])}}if(r){var E=f;f=p,p=E}return[f,p,function(t){return t.map((function(t,e){var i=t.map((function(t,i){return m[e][1][i](t)})).join(",");return"matrix"==m[e][0]&&16==i.split(",").length&&(m[e][0]="matrix3d"),m[e][0]+"("+i+")"})).join(" ")}]}),["transform"]),t.transformToSvgMatrix=function(e){var i=t.transformListToMatrix(r(e));return"matrix("+s(i[0])+" "+s(i[1])+" "+s(i[4])+" "+s(i[5])+" "+s(i[12])+" "+s(i[13])+")"}}(ri),function(t){function e(e){return e=100*Math.round(e/100),400===(e=t.clamp(100,900,e))?"normal":700===e?"bold":String(e)}t.addPropertiesHandler((function(t){var e=Number(t);if(!(isNaN(e)||e<100||e>900||e%100!=0))return e}),(function(t,i){return[t,i,e]}),["font-weight"])}(ri),function(t){function e(t){var e={};for(var i in t)e[i]=-t[i];return e}function i(e){return t.consumeToken(/^(left|center|right|top|bottom)\b/i,e)||t.consumeLengthOrPercent(e)}function n(e,n){var r=t.consumeRepeated(i,/^/,n);if(r&&""==r[1]){var o=r[0];if(o[0]=o[0]||"center",o[1]=o[1]||"center",3==e&&(o[2]=o[2]||{px:0}),o.length==e){if(/top|bottom/.test(o[0])||/left|right/.test(o[1])){var a=o[0];o[0]=o[1],o[1]=a}if(/left|right|center|Object/.test(o[0])&&/top|bottom|center|Object/.test(o[1]))return o.map((function(t){return"object"==typeof t?t:s[t]}))}}}function r(n){var r=t.consumeRepeated(i,/^/,n);if(r){for(var o=r[0],a=[{"%":50},{"%":50}],h=0,l=!1,u=0;u<o.length;u++){var d=o[u];"string"==typeof d?(l=/bottom|right/.test(d),a[h={left:0,right:0,center:h,top:1,bottom:1}[d]]=s[d],"center"==d&&h++):(l&&((d=e(d))["%"]=(d["%"]||0)+100),a[h]=d,h++,l=!1)}return[a,r[1]]}}var s={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},o=t.mergeNestedRepeated.bind(null,t.mergeDimensions," ");t.addPropertiesHandler(n.bind(null,3),o,["transform-origin"]),t.addPropertiesHandler(n.bind(null,2),o,["perspective-origin"]),t.consumePosition=r,t.mergeOffsetList=o;var a=t.mergeNestedRepeated.bind(null,o,", ");t.addPropertiesHandler((function(e){var i=t.consumeRepeated(r,/^,/,e);if(i&&""==i[1])return i[0]}),a,["background-position","object-position"])}(ri),function(t){var e=t.consumeParenthesised.bind(null,t.parseLengthOrPercent),i=t.consumeRepeated.bind(void 0,e,/^/),n=t.mergeNestedRepeated.bind(void 0,t.mergeDimensions," "),r=t.mergeNestedRepeated.bind(void 0,n,",");t.addPropertiesHandler((function(n){var r=t.consumeToken(/^circle/,n);if(r&&r[0])return["circle"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),e,t.ignore(t.consumeToken.bind(void 0,/^at/)),t.consumePosition,t.ignore(t.consumeToken.bind(void 0,/^\)/))],r[1]));var s=t.consumeToken(/^ellipse/,n);if(s&&s[0])return["ellipse"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),i,t.ignore(t.consumeToken.bind(void 0,/^at/)),t.consumePosition,t.ignore(t.consumeToken.bind(void 0,/^\)/))],s[1]));var o=t.consumeToken(/^polygon/,n);return o&&o[0]?["polygon"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),t.optional(t.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),t.consumeSizePairList,t.ignore(t.consumeToken.bind(void 0,/^\)/))],o[1])):void 0}),(function(e,i){if(e[0]===i[0])return"circle"==e[0]?t.mergeList(e.slice(1),i.slice(1),["circle(",t.mergeDimensions," at ",t.mergeOffsetList,")"]):"ellipse"==e[0]?t.mergeList(e.slice(1),i.slice(1),["ellipse(",t.mergeNonNegativeSizePair," at ",t.mergeOffsetList,")"]):"polygon"==e[0]&&e[1]==i[1]?t.mergeList(e.slice(2),i.slice(2),["polygon(",e[1],r,")"]):void 0}),["shape-outside"])}(ri),function(t,e){function i(t,e){e.concat([t]).forEach((function(e){e in document.documentElement.style&&(n[t]=e),r[e]=t}))}var n={},r={};i("transform",["webkitTransform","msTransform"]),i("transformOrigin",["webkitTransformOrigin"]),i("perspective",["webkitPerspective"]),i("perspectiveOrigin",["webkitPerspectiveOrigin"]),t.propertyName=function(t){return n[t]||t},t.unprefixedPropertyName=function(t){return r[t]||t}}(ri)}(),function(){if(void 0===document.createElement("div").animate([]).oncancel){if(window.performance&&performance.now)var t=function(){return performance.now()};else t=function(){return Date.now()};var e=function(t,e,i){this.target=t,this.currentTime=e,this.timelineTime=i,this.type="cancel",this.bubbles=!1,this.cancelable=!1,this.currentTarget=t,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()},i=window.Element.prototype.animate;window.Element.prototype.animate=function(n,r){var s=i.call(this,n,r);s._cancelHandlers=[],s.oncancel=null;var o=s.cancel;s.cancel=function(){o.call(this);var i=new e(this,null,t()),n=this._cancelHandlers.concat(this.oncancel?[this.oncancel]:[]);setTimeout((function(){n.forEach((function(t){t.call(i.target,i)}))}),0)};var a=s.addEventListener;s.addEventListener=function(t,e){"function"==typeof e&&"cancel"==t?this._cancelHandlers.push(e):a.call(this,t,e)};var h=s.removeEventListener;return s.removeEventListener=function(t,e){if("cancel"==t){var i=this._cancelHandlers.indexOf(e);i>=0&&this._cancelHandlers.splice(i,1)}else h.call(this,t,e)},s}}}(),function(t){var e=document.documentElement,i=null,n=!1;try{var r="0"==getComputedStyle(e).getPropertyValue("opacity")?"1":"0";(i=e.animate({opacity:[r,r]},{duration:1})).currentTime=0,n=getComputedStyle(e).getPropertyValue("opacity")==r}catch(t){}finally{i&&i.cancel()}if(!n){var s=window.Element.prototype.animate;window.Element.prototype.animate=function(e,i){return window.Symbol&&Symbol.iterator&&Array.prototype.from&&e[Symbol.iterator]&&(e=Array.from(e)),Array.isArray(e)||null===e||(e=t.convertToArrayForm(e)),s.call(this,e,i)}}}(ni),window.MetaGallery=li}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
!(function (t) {
|
| 2 |
+
'function' == typeof define && define.amd ? define(t) : t()
|
| 3 |
+
})(function () {
|
| 4 |
+
'use strict'
|
| 5 |
+
/**
|
| 6 |
+
* Muuri v0.9.3
|
| 7 |
+
* https://muuri.dev/
|
| 8 |
+
* Copyright (c) 2015-present, Haltu Oy
|
| 9 |
+
* Released under the MIT license
|
| 10 |
+
* https://github.com/haltu/muuri/blob/master/LICENSE.md
|
| 11 |
+
* @license MIT
|
| 12 |
+
*
|
| 13 |
+
* Muuri Packer
|
| 14 |
+
* Copyright (c) 2016-present, Niklas Rämö <inramo@gmail.com>
|
| 15 |
+
* @license MIT
|
| 16 |
+
*
|
| 17 |
+
* Muuri Ticker / Muuri Emitter / Muuri Dragger
|
| 18 |
+
* Copyright (c) 2018-present, Niklas Rämö <inramo@gmail.com>
|
| 19 |
+
* @license MIT
|
| 20 |
+
*
|
| 21 |
+
* Muuri AutoScroller
|
| 22 |
+
* Copyright (c) 2019-present, Niklas Rämö <inramo@gmail.com>
|
| 23 |
+
* @license MIT
|
| 24 |
+
*/ var t = {},
|
| 25 |
+
e = 'function' == typeof Map ? new Map() : null,
|
| 26 |
+
i = 'swap',
|
| 27 |
+
n = 'move',
|
| 28 |
+
r = 'layoutStart',
|
| 29 |
+
s = 'layoutEnd',
|
| 30 |
+
o = 'layoutAbort',
|
| 31 |
+
a = 'remove',
|
| 32 |
+
h = 'hideStart',
|
| 33 |
+
l = 'filter',
|
| 34 |
+
u = 'sort',
|
| 35 |
+
d = 'move',
|
| 36 |
+
c = 'send',
|
| 37 |
+
_ = 'beforeSend',
|
| 38 |
+
f = 'receive',
|
| 39 |
+
p = 'beforeReceive',
|
| 40 |
+
m = 'dragReleaseEnd',
|
| 41 |
+
g = 'ontouchstart' in window,
|
| 42 |
+
v = !!window.PointerEvent,
|
| 43 |
+
y = !!window.navigator.msPointerEnabled
|
| 44 |
+
function b() {
|
| 45 |
+
;(this._events = {}), (this._queue = []), (this._counter = 0), (this._clearOnEmit = !1)
|
| 46 |
+
}
|
| 47 |
+
;(b.prototype.on = function (t, e) {
|
| 48 |
+
if (!this._events || !t || !e) return this
|
| 49 |
+
var i = this._events[t]
|
| 50 |
+
return i || (i = this._events[t] = []), i.push(e), this
|
| 51 |
+
}),
|
| 52 |
+
(b.prototype.off = function (t, e) {
|
| 53 |
+
if (!this._events || !t || !e) return this
|
| 54 |
+
var i,
|
| 55 |
+
n = this._events[t]
|
| 56 |
+
if (!n || !n.length) return this
|
| 57 |
+
for (; -1 !== (i = n.indexOf(e)); ) n.splice(i, 1)
|
| 58 |
+
return this
|
| 59 |
+
}),
|
| 60 |
+
(b.prototype.clear = function (t) {
|
| 61 |
+
if (!this._events || !t) return this
|
| 62 |
+
var e = this._events[t]
|
| 63 |
+
return e && ((e.length = 0), delete this._events[t]), this
|
| 64 |
+
}),
|
| 65 |
+
(b.prototype.emit = function (t) {
|
| 66 |
+
if (!this._events || !t) return (this._clearOnEmit = !1), this
|
| 67 |
+
var e = this._events[t]
|
| 68 |
+
if (!e || !e.length) return (this._clearOnEmit = !1), this
|
| 69 |
+
var i,
|
| 70 |
+
n = this._queue,
|
| 71 |
+
r = n.length,
|
| 72 |
+
s = arguments.length - 1
|
| 73 |
+
s > 3 && ((i = []).push.apply(i, arguments), i.shift()),
|
| 74 |
+
n.push.apply(n, e),
|
| 75 |
+
this._clearOnEmit && ((e.length = 0), (this._clearOnEmit = !1)),
|
| 76 |
+
++this._counter
|
| 77 |
+
for (var o = r, a = n.length; o < a; o++)
|
| 78 |
+
if (
|
| 79 |
+
(0 === s
|
| 80 |
+
? n[o]()
|
| 81 |
+
: 1 === s
|
| 82 |
+
? n[o](arguments[1])
|
| 83 |
+
: 2 === s
|
| 84 |
+
? n[o](arguments[1], arguments[2])
|
| 85 |
+
: 3 === s
|
| 86 |
+
? n[o](arguments[1], arguments[2], arguments[3])
|
| 87 |
+
: n[o].apply(null, i),
|
| 88 |
+
!this._events)
|
| 89 |
+
)
|
| 90 |
+
return this
|
| 91 |
+
return --this._counter, this._counter || (n.length = 0), this
|
| 92 |
+
}),
|
| 93 |
+
(b.prototype.burst = function () {
|
| 94 |
+
return this._events ? ((this._clearOnEmit = !0), this.emit.apply(this, arguments), this) : this
|
| 95 |
+
}),
|
| 96 |
+
(b.prototype.countListeners = function (t) {
|
| 97 |
+
if (!this._events) return 0
|
| 98 |
+
var e = this._events[t]
|
| 99 |
+
return e ? e.length : 0
|
| 100 |
+
}),
|
| 101 |
+
(b.prototype.destroy = function () {
|
| 102 |
+
return this._events ? ((this._queue.length = this._counter = 0), (this._events = null), this) : this
|
| 103 |
+
})
|
| 104 |
+
var w = v ? 'pointerout' : y ? 'MSPointerOut' : ''
|
| 105 |
+
function S(t) {
|
| 106 |
+
w &&
|
| 107 |
+
((this._dragger = t),
|
| 108 |
+
(this._timeout = null),
|
| 109 |
+
(this._outEvent = null),
|
| 110 |
+
(this._isActive = !1),
|
| 111 |
+
(this._addBehaviour = this._addBehaviour.bind(this)),
|
| 112 |
+
(this._removeBehaviour = this._removeBehaviour.bind(this)),
|
| 113 |
+
(this._onTimeout = this._onTimeout.bind(this)),
|
| 114 |
+
(this._resetData = this._resetData.bind(this)),
|
| 115 |
+
(this._onStart = this._onStart.bind(this)),
|
| 116 |
+
(this._onOut = this._onOut.bind(this)),
|
| 117 |
+
this._dragger.on('start', this._onStart))
|
| 118 |
+
}
|
| 119 |
+
;(S.prototype._addBehaviour = function () {
|
| 120 |
+
this._isActive ||
|
| 121 |
+
((this._isActive = !0),
|
| 122 |
+
this._dragger.on('move', this._resetData),
|
| 123 |
+
this._dragger.on('cancel', this._removeBehaviour),
|
| 124 |
+
this._dragger.on('end', this._removeBehaviour),
|
| 125 |
+
window.addEventListener(w, this._onOut))
|
| 126 |
+
}),
|
| 127 |
+
(S.prototype._removeBehaviour = function () {
|
| 128 |
+
this._isActive &&
|
| 129 |
+
(this._dragger.off('move', this._resetData),
|
| 130 |
+
this._dragger.off('cancel', this._removeBehaviour),
|
| 131 |
+
this._dragger.off('end', this._removeBehaviour),
|
| 132 |
+
window.removeEventListener(w, this._onOut),
|
| 133 |
+
this._resetData(),
|
| 134 |
+
(this._isActive = !1))
|
| 135 |
+
}),
|
| 136 |
+
(S.prototype._resetData = function () {
|
| 137 |
+
window.clearTimeout(this._timeout), (this._timeout = null), (this._outEvent = null)
|
| 138 |
+
}),
|
| 139 |
+
(S.prototype._onStart = function (t) {
|
| 140 |
+
'mouse' !== t.pointerType && this._addBehaviour()
|
| 141 |
+
}),
|
| 142 |
+
(S.prototype._onOut = function (t) {
|
| 143 |
+
this._dragger._getTrackedTouch(t) &&
|
| 144 |
+
(this._resetData(), (this._outEvent = t), (this._timeout = window.setTimeout(this._onTimeout, 100)))
|
| 145 |
+
}),
|
| 146 |
+
(S.prototype._onTimeout = function () {
|
| 147 |
+
var t = this._outEvent
|
| 148 |
+
this._resetData(), this._dragger.isActive() && this._dragger._onCancel(t)
|
| 149 |
+
}),
|
| 150 |
+
(S.prototype.destroy = function () {
|
| 151 |
+
w && (this._dragger.off('start', this._onStart), this._removeBehaviour())
|
| 152 |
+
})
|
| 153 |
+
var T = ['', 'webkit', 'moz', 'ms', 'o', 'Webkit', 'Moz', 'MS', 'O'],
|
| 154 |
+
D = {}
|
| 155 |
+
function x(t, e) {
|
| 156 |
+
var i = D[e] || ''
|
| 157 |
+
if (i) return i
|
| 158 |
+
for (var n = e[0].toUpperCase() + e.slice(1), r = 0; r < T.length; ) {
|
| 159 |
+
if ((i = T[r] ? T[r] + n : e) in t) return (D[e] = i), i
|
| 160 |
+
++r
|
| 161 |
+
}
|
| 162 |
+
return ''
|
| 163 |
+
}
|
| 164 |
+
function A() {
|
| 165 |
+
var t = !1
|
| 166 |
+
try {
|
| 167 |
+
var e = Object.defineProperty({}, 'passive', {
|
| 168 |
+
get: function () {
|
| 169 |
+
t = !0
|
| 170 |
+
},
|
| 171 |
+
})
|
| 172 |
+
window.addEventListener('testPassive', null, e), window.removeEventListener('testPassive', null, e)
|
| 173 |
+
} catch (t) {}
|
| 174 |
+
return t
|
| 175 |
+
}
|
| 176 |
+
var k = window.navigator.userAgent.toLowerCase(),
|
| 177 |
+
E = k.indexOf('edge') > -1,
|
| 178 |
+
R = k.indexOf('trident') > -1,
|
| 179 |
+
L = k.indexOf('firefox') > -1,
|
| 180 |
+
P = k.indexOf('android') > -1,
|
| 181 |
+
M = !!A() && { passive: !0 },
|
| 182 |
+
I = 'touchAction',
|
| 183 |
+
C = x(document.documentElement.style, I)
|
| 184 |
+
function N(t, e) {
|
| 185 |
+
;(this._element = t),
|
| 186 |
+
(this._emitter = new b()),
|
| 187 |
+
(this._isDestroyed = !1),
|
| 188 |
+
(this._cssProps = {}),
|
| 189 |
+
(this._touchAction = ''),
|
| 190 |
+
(this._isActive = !1),
|
| 191 |
+
(this._pointerId = null),
|
| 192 |
+
(this._startTime = 0),
|
| 193 |
+
(this._startX = 0),
|
| 194 |
+
(this._startY = 0),
|
| 195 |
+
(this._currentX = 0),
|
| 196 |
+
(this._currentY = 0),
|
| 197 |
+
(this._onStart = this._onStart.bind(this)),
|
| 198 |
+
(this._onMove = this._onMove.bind(this)),
|
| 199 |
+
(this._onCancel = this._onCancel.bind(this)),
|
| 200 |
+
(this._onEnd = this._onEnd.bind(this)),
|
| 201 |
+
(this._edgeHack = null),
|
| 202 |
+
(E || R) && (v || y) && (this._edgeHack = new S(this)),
|
| 203 |
+
this.setCssProps(e),
|
| 204 |
+
this._touchAction || this.setTouchAction('auto'),
|
| 205 |
+
t.addEventListener('dragstart', N._preventDefault, !1),
|
| 206 |
+
t.addEventListener(N._inputEvents.start, this._onStart, M)
|
| 207 |
+
}
|
| 208 |
+
;(N._pointerEvents = { start: 'pointerdown', move: 'pointermove', cancel: 'pointercancel', end: 'pointerup' }),
|
| 209 |
+
(N._msPointerEvents = {
|
| 210 |
+
start: 'MSPointerDown',
|
| 211 |
+
move: 'MSPointerMove',
|
| 212 |
+
cancel: 'MSPointerCancel',
|
| 213 |
+
end: 'MSPointerUp',
|
| 214 |
+
}),
|
| 215 |
+
(N._touchEvents = { start: 'touchstart', move: 'touchmove', cancel: 'touchcancel', end: 'touchend' }),
|
| 216 |
+
(N._mouseEvents = { start: 'mousedown', move: 'mousemove', cancel: '', end: 'mouseup' }),
|
| 217 |
+
(N._inputEvents = g ? N._touchEvents : v ? N._pointerEvents : y ? N._msPointerEvents : N._mouseEvents),
|
| 218 |
+
(N._emitter = new b()),
|
| 219 |
+
(N._emitterEvents = { start: 'start', move: 'move', end: 'end', cancel: 'cancel' }),
|
| 220 |
+
(N._activeInstances = []),
|
| 221 |
+
(N._preventDefault = function (t) {
|
| 222 |
+
t.preventDefault && !1 !== t.cancelable && t.preventDefault()
|
| 223 |
+
}),
|
| 224 |
+
(N._activateInstance = function (t) {
|
| 225 |
+
N._activeInstances.indexOf(t) > -1 ||
|
| 226 |
+
(N._activeInstances.push(t),
|
| 227 |
+
N._emitter.on(N._emitterEvents.move, t._onMove),
|
| 228 |
+
N._emitter.on(N._emitterEvents.cancel, t._onCancel),
|
| 229 |
+
N._emitter.on(N._emitterEvents.end, t._onEnd),
|
| 230 |
+
1 === N._activeInstances.length && N._bindListeners())
|
| 231 |
+
}),
|
| 232 |
+
(N._deactivateInstance = function (t) {
|
| 233 |
+
var e = N._activeInstances.indexOf(t)
|
| 234 |
+
;-1 !== e &&
|
| 235 |
+
(N._activeInstances.splice(e, 1),
|
| 236 |
+
N._emitter.off(N._emitterEvents.move, t._onMove),
|
| 237 |
+
N._emitter.off(N._emitterEvents.cancel, t._onCancel),
|
| 238 |
+
N._emitter.off(N._emitterEvents.end, t._onEnd),
|
| 239 |
+
N._activeInstances.length || N._unbindListeners())
|
| 240 |
+
}),
|
| 241 |
+
(N._bindListeners = function () {
|
| 242 |
+
window.addEventListener(N._inputEvents.move, N._onMove, M),
|
| 243 |
+
window.addEventListener(N._inputEvents.end, N._onEnd, M),
|
| 244 |
+
N._inputEvents.cancel && window.addEventListener(N._inputEvents.cancel, N._onCancel, M)
|
| 245 |
+
}),
|
| 246 |
+
(N._unbindListeners = function () {
|
| 247 |
+
window.removeEventListener(N._inputEvents.move, N._onMove, M),
|
| 248 |
+
window.removeEventListener(N._inputEvents.end, N._onEnd, M),
|
| 249 |
+
N._inputEvents.cancel && window.removeEventListener(N._inputEvents.cancel, N._onCancel, M)
|
| 250 |
+
}),
|
| 251 |
+
(N._getEventPointerId = function (t) {
|
| 252 |
+
return 'number' == typeof t.pointerId
|
| 253 |
+
? t.pointerId
|
| 254 |
+
: t.changedTouches
|
| 255 |
+
? t.changedTouches[0]
|
| 256 |
+
? t.changedTouches[0].identifier
|
| 257 |
+
: null
|
| 258 |
+
: 1
|
| 259 |
+
}),
|
| 260 |
+
(N._getTouchById = function (t, e) {
|
| 261 |
+
if ('number' == typeof t.pointerId) return t.pointerId === e ? t : null
|
| 262 |
+
if (t.changedTouches) {
|
| 263 |
+
for (var i = 0; i < t.changedTouches.length; i++)
|
| 264 |
+
if (t.changedTouches[i].identifier === e) return t.changedTouches[i]
|
| 265 |
+
return null
|
| 266 |
+
}
|
| 267 |
+
return t
|
| 268 |
+
}),
|
| 269 |
+
(N._onMove = function (t) {
|
| 270 |
+
N._emitter.emit(N._emitterEvents.move, t)
|
| 271 |
+
}),
|
| 272 |
+
(N._onCancel = function (t) {
|
| 273 |
+
N._emitter.emit(N._emitterEvents.cancel, t)
|
| 274 |
+
}),
|
| 275 |
+
(N._onEnd = function (t) {
|
| 276 |
+
N._emitter.emit(N._emitterEvents.end, t)
|
| 277 |
+
}),
|
| 278 |
+
(N.prototype._reset = function () {
|
| 279 |
+
;(this._pointerId = null),
|
| 280 |
+
(this._startTime = 0),
|
| 281 |
+
(this._startX = 0),
|
| 282 |
+
(this._startY = 0),
|
| 283 |
+
(this._currentX = 0),
|
| 284 |
+
(this._currentY = 0),
|
| 285 |
+
(this._isActive = !1),
|
| 286 |
+
N._deactivateInstance(this)
|
| 287 |
+
}),
|
| 288 |
+
(N.prototype._createEvent = function (t, e) {
|
| 289 |
+
var i = this._getTrackedTouch(e)
|
| 290 |
+
return {
|
| 291 |
+
type: t,
|
| 292 |
+
srcEvent: e,
|
| 293 |
+
distance: this.getDistance(),
|
| 294 |
+
deltaX: this.getDeltaX(),
|
| 295 |
+
deltaY: this.getDeltaY(),
|
| 296 |
+
deltaTime: t === N._emitterEvents.start ? 0 : this.getDeltaTime(),
|
| 297 |
+
isFirst: t === N._emitterEvents.start,
|
| 298 |
+
isFinal: t === N._emitterEvents.end || t === N._emitterEvents.cancel,
|
| 299 |
+
pointerType: e.pointerType || (e.touches ? 'touch' : 'mouse'),
|
| 300 |
+
identifier: this._pointerId,
|
| 301 |
+
screenX: i.screenX,
|
| 302 |
+
screenY: i.screenY,
|
| 303 |
+
clientX: i.clientX,
|
| 304 |
+
clientY: i.clientY,
|
| 305 |
+
pageX: i.pageX,
|
| 306 |
+
pageY: i.pageY,
|
| 307 |
+
target: i.target,
|
| 308 |
+
}
|
| 309 |
+
}),
|
| 310 |
+
(N.prototype._emit = function (t, e) {
|
| 311 |
+
this._emitter.emit(t, this._createEvent(t, e))
|
| 312 |
+
}),
|
| 313 |
+
(N.prototype._getTrackedTouch = function (t) {
|
| 314 |
+
return null === this._pointerId ? null : N._getTouchById(t, this._pointerId)
|
| 315 |
+
}),
|
| 316 |
+
(N.prototype._onStart = function (t) {
|
| 317 |
+
if (
|
| 318 |
+
!this._isDestroyed &&
|
| 319 |
+
null === this._pointerId &&
|
| 320 |
+
((this._pointerId = N._getEventPointerId(t)), null !== this._pointerId)
|
| 321 |
+
) {
|
| 322 |
+
var e = this._getTrackedTouch(t)
|
| 323 |
+
;(this._startX = this._currentX = e.clientX),
|
| 324 |
+
(this._startY = this._currentY = e.clientY),
|
| 325 |
+
(this._startTime = Date.now()),
|
| 326 |
+
(this._isActive = !0),
|
| 327 |
+
this._emit(N._emitterEvents.start, t),
|
| 328 |
+
this._isActive && N._activateInstance(this)
|
| 329 |
+
}
|
| 330 |
+
}),
|
| 331 |
+
(N.prototype._onMove = function (t) {
|
| 332 |
+
var e = this._getTrackedTouch(t)
|
| 333 |
+
e && ((this._currentX = e.clientX), (this._currentY = e.clientY), this._emit(N._emitterEvents.move, t))
|
| 334 |
+
}),
|
| 335 |
+
(N.prototype._onCancel = function (t) {
|
| 336 |
+
this._getTrackedTouch(t) && (this._emit(N._emitterEvents.cancel, t), this._reset())
|
| 337 |
+
}),
|
| 338 |
+
(N.prototype._onEnd = function (t) {
|
| 339 |
+
this._getTrackedTouch(t) && (this._emit(N._emitterEvents.end, t), this._reset())
|
| 340 |
+
}),
|
| 341 |
+
(N.prototype.isActive = function () {
|
| 342 |
+
return this._isActive
|
| 343 |
+
}),
|
| 344 |
+
(N.prototype.setTouchAction = function (t) {
|
| 345 |
+
;(this._touchAction = t),
|
| 346 |
+
C && ((this._cssProps[C] = ''), (this._element.style[C] = t)),
|
| 347 |
+
g &&
|
| 348 |
+
(this._element.removeEventListener(N._touchEvents.start, N._preventDefault, !0),
|
| 349 |
+
(this._element.style[C] !== t || (L && P)) &&
|
| 350 |
+
this._element.addEventListener(N._touchEvents.start, N._preventDefault, !0))
|
| 351 |
+
}),
|
| 352 |
+
(N.prototype.setCssProps = function (t) {
|
| 353 |
+
if (t) {
|
| 354 |
+
var e,
|
| 355 |
+
i,
|
| 356 |
+
n = this._cssProps,
|
| 357 |
+
r = this._element
|
| 358 |
+
for (e in n) (r.style[e] = n[e]), delete n[e]
|
| 359 |
+
for (e in t)
|
| 360 |
+
t[e] &&
|
| 361 |
+
(e !== I
|
| 362 |
+
? (i = x(r.style, e)) && ((n[i] = ''), (r.style[i] = t[e]))
|
| 363 |
+
: this.setTouchAction(t[e]))
|
| 364 |
+
}
|
| 365 |
+
}),
|
| 366 |
+
(N.prototype.getDeltaX = function () {
|
| 367 |
+
return this._currentX - this._startX
|
| 368 |
+
}),
|
| 369 |
+
(N.prototype.getDeltaY = function () {
|
| 370 |
+
return this._currentY - this._startY
|
| 371 |
+
}),
|
| 372 |
+
(N.prototype.getDistance = function () {
|
| 373 |
+
var t = this.getDeltaX(),
|
| 374 |
+
e = this.getDeltaY()
|
| 375 |
+
return Math.sqrt(t * t + e * e)
|
| 376 |
+
}),
|
| 377 |
+
(N.prototype.getDeltaTime = function () {
|
| 378 |
+
return this._startTime ? Date.now() - this._startTime : 0
|
| 379 |
+
}),
|
| 380 |
+
(N.prototype.on = function (t, e) {
|
| 381 |
+
this._emitter.on(t, e)
|
| 382 |
+
}),
|
| 383 |
+
(N.prototype.off = function (t, e) {
|
| 384 |
+
this._emitter.off(t, e)
|
| 385 |
+
}),
|
| 386 |
+
(N.prototype.destroy = function () {
|
| 387 |
+
if (!this._isDestroyed) {
|
| 388 |
+
var t = this._element
|
| 389 |
+
for (var e in (this._edgeHack && this._edgeHack.destroy(),
|
| 390 |
+
this._reset(),
|
| 391 |
+
this._emitter.destroy(),
|
| 392 |
+
t.removeEventListener(N._inputEvents.start, this._onStart, M),
|
| 393 |
+
t.removeEventListener('dragstart', N._preventDefault, !1),
|
| 394 |
+
t.removeEventListener(N._touchEvents.start, N._preventDefault, !0),
|
| 395 |
+
this._cssProps))
|
| 396 |
+
(t.style[e] = this._cssProps[e]), delete this._cssProps[e]
|
| 397 |
+
;(this._element = null), (this._isDestroyed = !0)
|
| 398 |
+
}
|
| 399 |
+
})
|
| 400 |
+
var O = (
|
| 401 |
+
window.requestAnimationFrame ||
|
| 402 |
+
window.webkitRequestAnimationFrame ||
|
| 403 |
+
window.mozRequestAnimationFrame ||
|
| 404 |
+
window.msRequestAnimationFrame ||
|
| 405 |
+
function (t) {
|
| 406 |
+
return this.setTimeout(function () {
|
| 407 |
+
t(Date.now())
|
| 408 |
+
}, 16.666666666666668)
|
| 409 |
+
}
|
| 410 |
+
).bind(window)
|
| 411 |
+
function X(t) {
|
| 412 |
+
;(this._nextStep = null),
|
| 413 |
+
(this._lanes = []),
|
| 414 |
+
(this._stepQueue = []),
|
| 415 |
+
(this._stepCallbacks = {}),
|
| 416 |
+
(this._step = this._step.bind(this))
|
| 417 |
+
for (var e = 0; e < t; e++) this._lanes.push(new Y())
|
| 418 |
+
}
|
| 419 |
+
function Y() {
|
| 420 |
+
;(this.queue = []), (this.indices = {}), (this.callbacks = {})
|
| 421 |
+
}
|
| 422 |
+
;(X.prototype._step = function (t) {
|
| 423 |
+
var e,
|
| 424 |
+
i,
|
| 425 |
+
n,
|
| 426 |
+
r,
|
| 427 |
+
s,
|
| 428 |
+
o,
|
| 429 |
+
a = this._lanes,
|
| 430 |
+
h = this._stepQueue,
|
| 431 |
+
l = this._stepCallbacks
|
| 432 |
+
for (this._nextStep = null, e = 0; e < a.length; e++) {
|
| 433 |
+
for (r = a[e].queue, s = a[e].callbacks, o = a[e].indices, i = 0; i < r.length; i++)
|
| 434 |
+
(n = r[i]) && (h.push(n), (l[n] = s[n]), delete s[n], delete o[n])
|
| 435 |
+
r.length = 0
|
| 436 |
+
}
|
| 437 |
+
for (e = 0; e < h.length; e++) l[(n = h[e])] && l[n](t), delete l[n]
|
| 438 |
+
h.length = 0
|
| 439 |
+
}),
|
| 440 |
+
(X.prototype.add = function (t, e, i) {
|
| 441 |
+
this._lanes[t].add(e, i), this._nextStep || (this._nextStep = O(this._step))
|
| 442 |
+
}),
|
| 443 |
+
(X.prototype.remove = function (t, e) {
|
| 444 |
+
this._lanes[t].remove(e)
|
| 445 |
+
}),
|
| 446 |
+
(Y.prototype.add = function (t, e) {
|
| 447 |
+
var i = this.indices[t]
|
| 448 |
+
void 0 !== i && (this.queue[i] = void 0),
|
| 449 |
+
this.queue.push(t),
|
| 450 |
+
(this.callbacks[t] = e),
|
| 451 |
+
(this.indices[t] = this.queue.length - 1)
|
| 452 |
+
}),
|
| 453 |
+
(Y.prototype.remove = function (t) {
|
| 454 |
+
var e = this.indices[t]
|
| 455 |
+
void 0 !== e && ((this.queue[e] = void 0), delete this.callbacks[t], delete this.indices[t])
|
| 456 |
+
})
|
| 457 |
+
var q = 'layoutRead',
|
| 458 |
+
H = 'layoutWrite',
|
| 459 |
+
F = 'visibilityRead',
|
| 460 |
+
W = 'visibilityWrite',
|
| 461 |
+
B = 'dragStartRead',
|
| 462 |
+
G = 'dragStartWrite',
|
| 463 |
+
z = 'dragMoveRead',
|
| 464 |
+
V = 'dragMoveWrite',
|
| 465 |
+
j = 'dragScrollRead',
|
| 466 |
+
U = 'dragScrollWrite',
|
| 467 |
+
Q = 'dragSortRead',
|
| 468 |
+
K = 'placeholderLayoutRead',
|
| 469 |
+
$ = 'placeholderLayoutWrite',
|
| 470 |
+
Z = 'placeholderResizeWrite',
|
| 471 |
+
J = 'autoScrollRead',
|
| 472 |
+
tt = 'autoScrollWrite',
|
| 473 |
+
et = 'debounceRead',
|
| 474 |
+
it = new X(3)
|
| 475 |
+
function nt(t) {
|
| 476 |
+
it.remove(0, q + t), it.remove(2, H + t)
|
| 477 |
+
}
|
| 478 |
+
function rt(t) {
|
| 479 |
+
it.remove(0, F + t), it.remove(2, W + t)
|
| 480 |
+
}
|
| 481 |
+
function st(t) {
|
| 482 |
+
it.remove(0, B + t), it.remove(2, G + t)
|
| 483 |
+
}
|
| 484 |
+
function ot(t) {
|
| 485 |
+
it.remove(0, z + t), it.remove(2, V + t)
|
| 486 |
+
}
|
| 487 |
+
function at(t) {
|
| 488 |
+
it.remove(0, j + t), it.remove(2, U + t)
|
| 489 |
+
}
|
| 490 |
+
function ht(t, e) {
|
| 491 |
+
it.add(1, Q + t, e)
|
| 492 |
+
}
|
| 493 |
+
function lt(t) {
|
| 494 |
+
it.remove(0, K + t), it.remove(2, $ + t)
|
| 495 |
+
}
|
| 496 |
+
function ut(t, e) {
|
| 497 |
+
it.add(0, J, t), it.add(2, tt, e)
|
| 498 |
+
}
|
| 499 |
+
function dt(t) {
|
| 500 |
+
return 'function' == typeof t
|
| 501 |
+
}
|
| 502 |
+
var ct,
|
| 503 |
+
_t = 'function' == typeof WeakMap,
|
| 504 |
+
ft = _t ? new WeakMap() : null,
|
| 505 |
+
pt = !0,
|
| 506 |
+
mt = function () {
|
| 507 |
+
pt ? ((ct = window.clearInterval(ct)), (ft = _t ? new WeakMap() : null)) : (pt = !0)
|
| 508 |
+
}
|
| 509 |
+
function gt(t, e) {
|
| 510 |
+
var i = ft && ft.get(t)
|
| 511 |
+
return (
|
| 512 |
+
i || ((i = window.getComputedStyle(t, null)), ft && ft.set(t, i)),
|
| 513 |
+
ft && (ct ? (pt = !1) : (ct = window.setInterval(mt, 3e3))),
|
| 514 |
+
i.getPropertyValue(e)
|
| 515 |
+
)
|
| 516 |
+
}
|
| 517 |
+
function vt(t, e) {
|
| 518 |
+
return parseFloat(gt(t, e)) || 0
|
| 519 |
+
}
|
| 520 |
+
var yt,
|
| 521 |
+
bt = document.documentElement,
|
| 522 |
+
wt = document.body,
|
| 523 |
+
St = { value: 0, offset: 0 }
|
| 524 |
+
function Tt(t) {
|
| 525 |
+
return t === window || t === bt || t === wt ? window : t
|
| 526 |
+
}
|
| 527 |
+
function Dt(t) {
|
| 528 |
+
return t === window ? t.pageXOffset : t.scrollLeft
|
| 529 |
+
}
|
| 530 |
+
function xt(t) {
|
| 531 |
+
return t === window ? t.pageYOffset : t.scrollTop
|
| 532 |
+
}
|
| 533 |
+
function At(t) {
|
| 534 |
+
return t === window ? bt.scrollWidth - bt.clientWidth : t.scrollWidth - t.clientWidth
|
| 535 |
+
}
|
| 536 |
+
function kt(t) {
|
| 537 |
+
return t === window ? bt.scrollHeight - bt.clientHeight : t.scrollHeight - t.clientHeight
|
| 538 |
+
}
|
| 539 |
+
function Et(t, e) {
|
| 540 |
+
if (((e = e || {}), t === window))
|
| 541 |
+
(e.width = bt.clientWidth),
|
| 542 |
+
(e.height = bt.clientHeight),
|
| 543 |
+
(e.left = 0),
|
| 544 |
+
(e.right = e.width),
|
| 545 |
+
(e.top = 0),
|
| 546 |
+
(e.bottom = e.height)
|
| 547 |
+
else {
|
| 548 |
+
var i = t.getBoundingClientRect(),
|
| 549 |
+
n = t.clientLeft || vt(t, 'border-left-width'),
|
| 550 |
+
r = t.clientTop || vt(t, 'border-top-width')
|
| 551 |
+
;(e.width = t.clientWidth),
|
| 552 |
+
(e.height = t.clientHeight),
|
| 553 |
+
(e.left = i.left + n),
|
| 554 |
+
(e.right = e.left + e.width),
|
| 555 |
+
(e.top = i.top + r),
|
| 556 |
+
(e.bottom = e.top + e.height)
|
| 557 |
+
}
|
| 558 |
+
return e
|
| 559 |
+
}
|
| 560 |
+
function Rt(t) {
|
| 561 |
+
return t._drag._getGrid()._settings.dragAutoScroll
|
| 562 |
+
}
|
| 563 |
+
function Lt(t) {
|
| 564 |
+
t._drag && t._drag._prepareScroll()
|
| 565 |
+
}
|
| 566 |
+
function Pt(t) {
|
| 567 |
+
if (t._drag && t._isActive) {
|
| 568 |
+
var e = t._drag
|
| 569 |
+
;(e._scrollDiffX = e._scrollDiffY = 0), t._setTranslate(e._left, e._top)
|
| 570 |
+
}
|
| 571 |
+
}
|
| 572 |
+
function Mt(t, e, i, n) {
|
| 573 |
+
return (St.value = Math.min(n / 2, t)), (St.offset = Math.max(0, i + 2 * St.value + n * e - n) / 2), St
|
| 574 |
+
}
|
| 575 |
+
function It() {
|
| 576 |
+
this.reset()
|
| 577 |
+
}
|
| 578 |
+
function Ct() {
|
| 579 |
+
;(this.element = null),
|
| 580 |
+
(this.requestX = null),
|
| 581 |
+
(this.requestY = null),
|
| 582 |
+
(this.scrollLeft = 0),
|
| 583 |
+
(this.scrollTop = 0)
|
| 584 |
+
}
|
| 585 |
+
function Nt(t, e) {
|
| 586 |
+
;(this.pool = []), (this.createItem = t), (this.releaseItem = e)
|
| 587 |
+
}
|
| 588 |
+
function Ot(t, e) {
|
| 589 |
+
var i = (function (t, e) {
|
| 590 |
+
return (function (t, e) {
|
| 591 |
+
return !(
|
| 592 |
+
t.left + t.width <= e.left ||
|
| 593 |
+
e.left + e.width <= t.left ||
|
| 594 |
+
t.top + t.height <= e.top ||
|
| 595 |
+
e.top + e.height <= t.top
|
| 596 |
+
)
|
| 597 |
+
})(t, e)
|
| 598 |
+
? (Math.min(t.left + t.width, e.left + e.width) - Math.max(t.left, e.left)) *
|
| 599 |
+
(Math.min(t.top + t.height, e.top + e.height) - Math.max(t.top, e.top))
|
| 600 |
+
: 0
|
| 601 |
+
})(t, e)
|
| 602 |
+
return i ? (i / (Math.min(t.width, e.width) * Math.min(t.height, e.height))) * 100 : 0
|
| 603 |
+
}
|
| 604 |
+
;(It.prototype.reset = function () {
|
| 605 |
+
this.isActive && this.onStop(),
|
| 606 |
+
(this.item = null),
|
| 607 |
+
(this.element = null),
|
| 608 |
+
(this.isActive = !1),
|
| 609 |
+
(this.isEnding = !1),
|
| 610 |
+
(this.direction = null),
|
| 611 |
+
(this.value = null),
|
| 612 |
+
(this.maxValue = 0),
|
| 613 |
+
(this.threshold = 0),
|
| 614 |
+
(this.distance = 0),
|
| 615 |
+
(this.speed = 0),
|
| 616 |
+
(this.duration = 0),
|
| 617 |
+
(this.action = null)
|
| 618 |
+
}),
|
| 619 |
+
(It.prototype.hasReachedEnd = function () {
|
| 620 |
+
return 4 & this.direction ? this.value >= this.maxValue : this.value <= 0
|
| 621 |
+
}),
|
| 622 |
+
(It.prototype.computeCurrentScrollValue = function () {
|
| 623 |
+
return null === this.value
|
| 624 |
+
? 1 & this.direction
|
| 625 |
+
? Dt(this.element)
|
| 626 |
+
: xt(this.element)
|
| 627 |
+
: Math.max(0, Math.min(this.value, this.maxValue))
|
| 628 |
+
}),
|
| 629 |
+
(It.prototype.computeNextScrollValue = function (t) {
|
| 630 |
+
var e = this.speed * (t / 1e3),
|
| 631 |
+
i = 4 & this.direction ? this.value + e : this.value - e
|
| 632 |
+
return Math.max(0, Math.min(i, this.maxValue))
|
| 633 |
+
}),
|
| 634 |
+
(It.prototype.computeSpeed =
|
| 635 |
+
((yt = {
|
| 636 |
+
direction: null,
|
| 637 |
+
threshold: 0,
|
| 638 |
+
distance: 0,
|
| 639 |
+
value: 0,
|
| 640 |
+
maxValue: 0,
|
| 641 |
+
deltaTime: 0,
|
| 642 |
+
duration: 0,
|
| 643 |
+
isEnding: !1,
|
| 644 |
+
}),
|
| 645 |
+
function (t) {
|
| 646 |
+
var e = this.item,
|
| 647 |
+
i = Rt(e).speed
|
| 648 |
+
return dt(i)
|
| 649 |
+
? ((yt.direction = this.direction),
|
| 650 |
+
(yt.threshold = this.threshold),
|
| 651 |
+
(yt.distance = this.distance),
|
| 652 |
+
(yt.value = this.value),
|
| 653 |
+
(yt.maxValue = this.maxValue),
|
| 654 |
+
(yt.duration = this.duration),
|
| 655 |
+
(yt.speed = this.speed),
|
| 656 |
+
(yt.deltaTime = t),
|
| 657 |
+
(yt.isEnding = this.isEnding),
|
| 658 |
+
i(e, this.element, yt))
|
| 659 |
+
: i
|
| 660 |
+
})),
|
| 661 |
+
(It.prototype.tick = function (t) {
|
| 662 |
+
return (
|
| 663 |
+
this.isActive || ((this.isActive = !0), this.onStart()),
|
| 664 |
+
(this.value = this.computeCurrentScrollValue()),
|
| 665 |
+
(this.speed = this.computeSpeed(t)),
|
| 666 |
+
(this.value = this.computeNextScrollValue(t)),
|
| 667 |
+
(this.duration += t),
|
| 668 |
+
this.value
|
| 669 |
+
)
|
| 670 |
+
}),
|
| 671 |
+
(It.prototype.onStart = function () {
|
| 672 |
+
var t = this.item,
|
| 673 |
+
e = Rt(t).onStart
|
| 674 |
+
dt(e) && e(t, this.element, this.direction)
|
| 675 |
+
}),
|
| 676 |
+
(It.prototype.onStop = function () {
|
| 677 |
+
var t = this.item,
|
| 678 |
+
e = Rt(t).onStop
|
| 679 |
+
dt(e) && e(t, this.element, this.direction), t._drag && t._drag.sort()
|
| 680 |
+
}),
|
| 681 |
+
(Ct.prototype.reset = function () {
|
| 682 |
+
this.requestX && (this.requestX.action = null),
|
| 683 |
+
this.requestY && (this.requestY.action = null),
|
| 684 |
+
(this.element = null),
|
| 685 |
+
(this.requestX = null),
|
| 686 |
+
(this.requestY = null),
|
| 687 |
+
(this.scrollLeft = 0),
|
| 688 |
+
(this.scrollTop = 0)
|
| 689 |
+
}),
|
| 690 |
+
(Ct.prototype.addRequest = function (t) {
|
| 691 |
+
1 & t.direction
|
| 692 |
+
? (this.removeRequest(this.requestX), (this.requestX = t))
|
| 693 |
+
: (this.removeRequest(this.requestY), (this.requestY = t)),
|
| 694 |
+
(t.action = this)
|
| 695 |
+
}),
|
| 696 |
+
(Ct.prototype.removeRequest = function (t) {
|
| 697 |
+
t &&
|
| 698 |
+
(this.requestX === t
|
| 699 |
+
? ((this.requestX = null), (t.action = null))
|
| 700 |
+
: this.requestY === t && ((this.requestY = null), (t.action = null)))
|
| 701 |
+
}),
|
| 702 |
+
(Ct.prototype.computeScrollValues = function () {
|
| 703 |
+
;(this.scrollLeft = this.requestX ? this.requestX.value : Dt(this.element)),
|
| 704 |
+
(this.scrollTop = this.requestY ? this.requestY.value : xt(this.element))
|
| 705 |
+
}),
|
| 706 |
+
(Ct.prototype.scroll = function () {
|
| 707 |
+
var t = this.element
|
| 708 |
+
t &&
|
| 709 |
+
(t.scrollTo
|
| 710 |
+
? t.scrollTo(this.scrollLeft, this.scrollTop)
|
| 711 |
+
: ((t.scrollLeft = this.scrollLeft), (t.scrollTop = this.scrollTop)))
|
| 712 |
+
}),
|
| 713 |
+
(Nt.prototype.pick = function () {
|
| 714 |
+
return this.pool.pop() || this.createItem()
|
| 715 |
+
}),
|
| 716 |
+
(Nt.prototype.release = function (t) {
|
| 717 |
+
this.releaseItem(t), -1 === this.pool.indexOf(t) && this.pool.push(t)
|
| 718 |
+
}),
|
| 719 |
+
(Nt.prototype.reset = function () {
|
| 720 |
+
this.pool.length = 0
|
| 721 |
+
})
|
| 722 |
+
var Xt = { width: 0, height: 0, left: 0, right: 0, top: 0, bottom: 0 },
|
| 723 |
+
Yt = { width: 0, height: 0, left: 0, right: 0, top: 0, bottom: 0 }
|
| 724 |
+
function qt() {
|
| 725 |
+
;(this._isDestroyed = !1),
|
| 726 |
+
(this._isTicking = !1),
|
| 727 |
+
(this._tickTime = 0),
|
| 728 |
+
(this._tickDeltaTime = 0),
|
| 729 |
+
(this._items = []),
|
| 730 |
+
(this._actions = []),
|
| 731 |
+
(this._requests = {}),
|
| 732 |
+
(this._requests[1] = {}),
|
| 733 |
+
(this._requests[2] = {}),
|
| 734 |
+
(this._requestOverlapCheck = {}),
|
| 735 |
+
(this._dragPositions = {}),
|
| 736 |
+
(this._dragDirections = {}),
|
| 737 |
+
(this._overlapCheckInterval = 150),
|
| 738 |
+
(this._requestPool = new Nt(
|
| 739 |
+
function () {
|
| 740 |
+
return new It()
|
| 741 |
+
},
|
| 742 |
+
function (t) {
|
| 743 |
+
t.reset()
|
| 744 |
+
},
|
| 745 |
+
)),
|
| 746 |
+
(this._actionPool = new Nt(
|
| 747 |
+
function () {
|
| 748 |
+
return new Ct()
|
| 749 |
+
},
|
| 750 |
+
function (t) {
|
| 751 |
+
t.reset()
|
| 752 |
+
},
|
| 753 |
+
)),
|
| 754 |
+
(this._readTick = this._readTick.bind(this)),
|
| 755 |
+
(this._writeTick = this._writeTick.bind(this))
|
| 756 |
+
}
|
| 757 |
+
;(qt.AXIS_X = 1),
|
| 758 |
+
(qt.AXIS_Y = 2),
|
| 759 |
+
(qt.FORWARD = 4),
|
| 760 |
+
(qt.BACKWARD = 8),
|
| 761 |
+
(qt.LEFT = 9),
|
| 762 |
+
(qt.RIGHT = 5),
|
| 763 |
+
(qt.UP = 10),
|
| 764 |
+
(qt.DOWN = 6),
|
| 765 |
+
(qt.smoothSpeed = function (t, e, i) {
|
| 766 |
+
return function (n, r, s) {
|
| 767 |
+
var o = 0
|
| 768 |
+
if (!s.isEnding)
|
| 769 |
+
if (s.threshold > 0) {
|
| 770 |
+
var a = s.threshold - Math.max(0, s.distance)
|
| 771 |
+
o = (t / s.threshold) * a
|
| 772 |
+
} else o = t
|
| 773 |
+
var h = s.speed,
|
| 774 |
+
l = o
|
| 775 |
+
return h === o
|
| 776 |
+
? l
|
| 777 |
+
: h < o
|
| 778 |
+
? ((l = h + e * (s.deltaTime / 1e3)), Math.min(o, l))
|
| 779 |
+
: ((l = h - i * (s.deltaTime / 1e3)), Math.max(o, l))
|
| 780 |
+
}
|
| 781 |
+
}),
|
| 782 |
+
(qt.pointerHandle = function (t) {
|
| 783 |
+
var e = { left: 0, top: 0, width: 0, height: 0 },
|
| 784 |
+
i = t || 1
|
| 785 |
+
return function (t, n, r, s, o, a, h) {
|
| 786 |
+
return (e.left = a - 0.5 * i), (e.top = h - 0.5 * i), (e.width = i), (e.height = i), e
|
| 787 |
+
}
|
| 788 |
+
}),
|
| 789 |
+
(qt.prototype._readTick = function (t) {
|
| 790 |
+
this._isDestroyed ||
|
| 791 |
+
(t && this._tickTime
|
| 792 |
+
? ((this._tickDeltaTime = t - this._tickTime),
|
| 793 |
+
(this._tickTime = t),
|
| 794 |
+
this._updateRequests(),
|
| 795 |
+
this._updateActions())
|
| 796 |
+
: ((this._tickTime = t), (this._tickDeltaTime = 0)))
|
| 797 |
+
}),
|
| 798 |
+
(qt.prototype._writeTick = function () {
|
| 799 |
+
this._isDestroyed || (this._applyActions(), ut(this._readTick, this._writeTick))
|
| 800 |
+
}),
|
| 801 |
+
(qt.prototype._startTicking = function () {
|
| 802 |
+
;(this._isTicking = !0), ut(this._readTick, this._writeTick)
|
| 803 |
+
}),
|
| 804 |
+
(qt.prototype._stopTicking = function () {
|
| 805 |
+
;(this._isTicking = !1), (this._tickTime = 0), (this._tickDeltaTime = 0), it.remove(0, J), it.remove(2, tt)
|
| 806 |
+
}),
|
| 807 |
+
(qt.prototype._getItemHandleRect = function (t, e, i) {
|
| 808 |
+
var n = t._drag
|
| 809 |
+
if (e) {
|
| 810 |
+
var r = n._dragMoveEvent || n._dragStartEvent,
|
| 811 |
+
s = e(t, n._clientX, n._clientY, t._width, t._height, r.clientX, r.clientY)
|
| 812 |
+
;(i.left = s.left), (i.top = s.top), (i.width = s.width), (i.height = s.height)
|
| 813 |
+
} else (i.left = n._clientX), (i.top = n._clientY), (i.width = t._width), (i.height = t._height)
|
| 814 |
+
return (i.right = i.left + i.width), (i.bottom = i.top + i.height), i
|
| 815 |
+
}),
|
| 816 |
+
(qt.prototype._requestItemScroll = function (t, e, i, n, r, s, o) {
|
| 817 |
+
var a = this._requests[e],
|
| 818 |
+
h = a[t._id]
|
| 819 |
+
h ? (h.element === i && h.direction === n) || h.reset() : (h = this._requestPool.pick()),
|
| 820 |
+
(h.item = t),
|
| 821 |
+
(h.element = i),
|
| 822 |
+
(h.direction = n),
|
| 823 |
+
(h.threshold = r),
|
| 824 |
+
(h.distance = s),
|
| 825 |
+
(h.maxValue = o),
|
| 826 |
+
(a[t._id] = h)
|
| 827 |
+
}),
|
| 828 |
+
(qt.prototype._cancelItemScroll = function (t, e) {
|
| 829 |
+
var i = this._requests[e],
|
| 830 |
+
n = i[t._id]
|
| 831 |
+
n && (n.action && n.action.removeRequest(n), this._requestPool.release(n), delete i[t._id])
|
| 832 |
+
}),
|
| 833 |
+
(qt.prototype._checkItemOverlap = function (t, e, i) {
|
| 834 |
+
var n = Rt(t),
|
| 835 |
+
r = dt(n.targets) ? n.targets(t) : n.targets,
|
| 836 |
+
s = n.threshold,
|
| 837 |
+
o = n.safeZone
|
| 838 |
+
if (!r || !r.length) return e && this._cancelItemScroll(t, 1), void (i && this._cancelItemScroll(t, 2))
|
| 839 |
+
var a = this._dragDirections[t._id],
|
| 840 |
+
h = a[0],
|
| 841 |
+
l = a[1]
|
| 842 |
+
if (!h && !l) return e && this._cancelItemScroll(t, 1), void (i && this._cancelItemScroll(t, 2))
|
| 843 |
+
for (
|
| 844 |
+
var u = this._getItemHandleRect(t, n.handle, Xt),
|
| 845 |
+
d = Yt,
|
| 846 |
+
c = null,
|
| 847 |
+
_ = null,
|
| 848 |
+
f = !0,
|
| 849 |
+
p = !0,
|
| 850 |
+
m = 0,
|
| 851 |
+
g = 0,
|
| 852 |
+
v = null,
|
| 853 |
+
y = null,
|
| 854 |
+
b = 0,
|
| 855 |
+
w = 0,
|
| 856 |
+
S = 0,
|
| 857 |
+
T = null,
|
| 858 |
+
D = -1 / 0,
|
| 859 |
+
x = 0,
|
| 860 |
+
A = 0,
|
| 861 |
+
k = null,
|
| 862 |
+
E = 0,
|
| 863 |
+
R = 0,
|
| 864 |
+
L = null,
|
| 865 |
+
P = -1 / 0,
|
| 866 |
+
M = 0,
|
| 867 |
+
I = 0,
|
| 868 |
+
C = null,
|
| 869 |
+
N = 0,
|
| 870 |
+
O = 0,
|
| 871 |
+
X = 0;
|
| 872 |
+
X < r.length;
|
| 873 |
+
X++
|
| 874 |
+
)
|
| 875 |
+
(c = r[X]),
|
| 876 |
+
(f = e && h && 2 !== c.axis),
|
| 877 |
+
(p = i && l && 1 !== c.axis),
|
| 878 |
+
(g = c.priority || 0),
|
| 879 |
+
((!f || g < D) && (!p || g < P)) ||
|
| 880 |
+
((_ = Tt(c.element || c)),
|
| 881 |
+
(w = f ? At(_) : -1),
|
| 882 |
+
(S = p ? kt(_) : -1),
|
| 883 |
+
(w || S) &&
|
| 884 |
+
((m = Ot(u, (d = Et(_, d)))) <= 0 ||
|
| 885 |
+
(f &&
|
| 886 |
+
g >= D &&
|
| 887 |
+
w > 0 &&
|
| 888 |
+
(g > D || m > A) &&
|
| 889 |
+
((y = null),
|
| 890 |
+
(v = Mt('number' == typeof c.threshold ? c.threshold : s, o, u.width, d.width)),
|
| 891 |
+
5 === h
|
| 892 |
+
? (b = d.right + v.offset - u.right) <= v.value && Dt(_) < w && (y = 5)
|
| 893 |
+
: 9 === h &&
|
| 894 |
+
(b = u.left - (d.left - v.offset)) <= v.value &&
|
| 895 |
+
Dt(_) > 0 &&
|
| 896 |
+
(y = 9),
|
| 897 |
+
null !== y &&
|
| 898 |
+
((T = _), (D = g), (x = v.value), (A = m), (k = y), (E = b), (R = w))),
|
| 899 |
+
p &&
|
| 900 |
+
g >= P &&
|
| 901 |
+
S > 0 &&
|
| 902 |
+
(g > P || m > I) &&
|
| 903 |
+
((y = null),
|
| 904 |
+
(v = Mt('number' == typeof c.threshold ? c.threshold : s, o, u.height, d.height)),
|
| 905 |
+
6 === l
|
| 906 |
+
? (b = d.bottom + v.offset - u.bottom) <= v.value && xt(_) < S && (y = 6)
|
| 907 |
+
: 10 === l &&
|
| 908 |
+
(b = u.top - (d.top - v.offset)) <= v.value &&
|
| 909 |
+
xt(_) > 0 &&
|
| 910 |
+
(y = 10),
|
| 911 |
+
null !== y &&
|
| 912 |
+
((L = _), (P = g), (M = v.value), (I = m), (C = y), (N = b), (O = S))))))
|
| 913 |
+
e && (T ? this._requestItemScroll(t, 1, T, k, x, E, R) : this._cancelItemScroll(t, 1)),
|
| 914 |
+
i && (L ? this._requestItemScroll(t, 2, L, C, M, N, O) : this._cancelItemScroll(t, 2))
|
| 915 |
+
}),
|
| 916 |
+
(qt.prototype._updateScrollRequest = function (t) {
|
| 917 |
+
for (
|
| 918 |
+
var e = t.item,
|
| 919 |
+
i = Rt(e),
|
| 920 |
+
n = dt(i.targets) ? i.targets(e) : i.targets,
|
| 921 |
+
r = (n && n.length) || 0,
|
| 922 |
+
s = i.threshold,
|
| 923 |
+
o = i.safeZone,
|
| 924 |
+
a = this._getItemHandleRect(e, i.handle, Xt),
|
| 925 |
+
h = Yt,
|
| 926 |
+
l = null,
|
| 927 |
+
u = null,
|
| 928 |
+
d = !1,
|
| 929 |
+
c = null,
|
| 930 |
+
_ = null,
|
| 931 |
+
f = null,
|
| 932 |
+
p = null,
|
| 933 |
+
m = null,
|
| 934 |
+
g = 0;
|
| 935 |
+
g < r;
|
| 936 |
+
g++
|
| 937 |
+
)
|
| 938 |
+
if ((u = Tt((l = n[g]).element || l)) === t.element) {
|
| 939 |
+
if ((d = !!(1 & t.direction))) {
|
| 940 |
+
if (2 === l.axis) continue
|
| 941 |
+
} else if (1 === l.axis) continue
|
| 942 |
+
if ((p = d ? At(u) : kt(u)) <= 0) break
|
| 943 |
+
if (Ot(a, (h = Et(u, h))) <= 0) break
|
| 944 |
+
if (
|
| 945 |
+
((c = Mt(
|
| 946 |
+
'number' == typeof l.threshold ? l.threshold : s,
|
| 947 |
+
o,
|
| 948 |
+
d ? a.width : a.height,
|
| 949 |
+
d ? h.width : h.height,
|
| 950 |
+
)),
|
| 951 |
+
(_ =
|
| 952 |
+
9 === t.direction
|
| 953 |
+
? a.left - (h.left - c.offset)
|
| 954 |
+
: 5 === t.direction
|
| 955 |
+
? h.right + c.offset - a.right
|
| 956 |
+
: 10 === t.direction
|
| 957 |
+
? a.top - (h.top - c.offset)
|
| 958 |
+
: h.bottom + c.offset - a.bottom) > c.value)
|
| 959 |
+
)
|
| 960 |
+
break
|
| 961 |
+
if (((f = d ? Dt(u) : xt(u)), (m = 4 & t.direction ? f >= p : f <= 0))) break
|
| 962 |
+
return (t.maxValue = p), (t.threshold = c.value), (t.distance = _), (t.isEnding = !1), !0
|
| 963 |
+
}
|
| 964 |
+
return (
|
| 965 |
+
!0 === i.smoothStop && t.speed > 0
|
| 966 |
+
? (null === m && (m = t.hasReachedEnd()), (t.isEnding = !m))
|
| 967 |
+
: (t.isEnding = !1),
|
| 968 |
+
t.isEnding
|
| 969 |
+
)
|
| 970 |
+
}),
|
| 971 |
+
(qt.prototype._updateRequests = function () {
|
| 972 |
+
for (
|
| 973 |
+
var t, e, i, n, r, s, o, a = this._items, h = this._requests[1], l = this._requests[2], u = 0;
|
| 974 |
+
u < a.length;
|
| 975 |
+
u++
|
| 976 |
+
)
|
| 977 |
+
(t = a[u]),
|
| 978 |
+
(r = (n = this._requestOverlapCheck[t._id]) > 0 && this._tickTime - n > this._overlapCheckInterval),
|
| 979 |
+
(s = !0),
|
| 980 |
+
(e = h[t._id]) &&
|
| 981 |
+
e.isActive &&
|
| 982 |
+
(s = !this._updateScrollRequest(e)) &&
|
| 983 |
+
((r = !0), this._cancelItemScroll(t, 1)),
|
| 984 |
+
(o = !0),
|
| 985 |
+
(i = l[t._id]) &&
|
| 986 |
+
i.isActive &&
|
| 987 |
+
(o = !this._updateScrollRequest(i)) &&
|
| 988 |
+
((r = !0), this._cancelItemScroll(t, 2)),
|
| 989 |
+
r && ((this._requestOverlapCheck[t._id] = 0), this._checkItemOverlap(t, s, o))
|
| 990 |
+
}),
|
| 991 |
+
(qt.prototype._requestAction = function (t, e) {
|
| 992 |
+
for (var i = this._actions, n = 1 === e, r = null, s = 0; s < i.length; s++) {
|
| 993 |
+
if (((r = i[s]), t.element === r.element)) {
|
| 994 |
+
if (n ? r.requestX : r.requestY) return void this._cancelItemScroll(t.item, e)
|
| 995 |
+
break
|
| 996 |
+
}
|
| 997 |
+
r = null
|
| 998 |
+
}
|
| 999 |
+
r || (r = this._actionPool.pick()),
|
| 1000 |
+
(r.element = t.element),
|
| 1001 |
+
r.addRequest(t),
|
| 1002 |
+
t.tick(this._tickDeltaTime),
|
| 1003 |
+
i.push(r)
|
| 1004 |
+
}),
|
| 1005 |
+
(qt.prototype._updateActions = function () {
|
| 1006 |
+
var t,
|
| 1007 |
+
e,
|
| 1008 |
+
i,
|
| 1009 |
+
n,
|
| 1010 |
+
r = this._items,
|
| 1011 |
+
s = this._requests,
|
| 1012 |
+
o = this._actions
|
| 1013 |
+
for (n = 0; n < r.length; n++)
|
| 1014 |
+
(t = r[n]._id),
|
| 1015 |
+
(e = s[1][t]),
|
| 1016 |
+
(i = s[2][t]),
|
| 1017 |
+
e && this._requestAction(e, 1),
|
| 1018 |
+
i && this._requestAction(i, 2)
|
| 1019 |
+
for (n = 0; n < o.length; n++) o[n].computeScrollValues()
|
| 1020 |
+
}),
|
| 1021 |
+
(qt.prototype._applyActions = function () {
|
| 1022 |
+
var t,
|
| 1023 |
+
e = this._actions,
|
| 1024 |
+
i = this._items
|
| 1025 |
+
if (e.length) {
|
| 1026 |
+
for (t = 0; t < e.length; t++) e[t].scroll(), this._actionPool.release(e[t])
|
| 1027 |
+
for (e.length = 0, t = 0; t < i.length; t++) Lt(i[t])
|
| 1028 |
+
for (t = 0; t < i.length; t++) Pt(i[t])
|
| 1029 |
+
}
|
| 1030 |
+
}),
|
| 1031 |
+
(qt.prototype._updateDragDirection = function (t) {
|
| 1032 |
+
var e = this._dragPositions[t._id],
|
| 1033 |
+
i = this._dragDirections[t._id],
|
| 1034 |
+
n = t._drag._left,
|
| 1035 |
+
r = t._drag._top
|
| 1036 |
+
if (e.length) {
|
| 1037 |
+
var s = e[0],
|
| 1038 |
+
o = e[1]
|
| 1039 |
+
;(i[0] = n > s ? 5 : n < s ? 9 : i[0] || 0), (i[1] = r > o ? 6 : r < o ? 10 : i[1] || 0)
|
| 1040 |
+
}
|
| 1041 |
+
;(e[0] = n), (e[1] = r)
|
| 1042 |
+
}),
|
| 1043 |
+
(qt.prototype.addItem = function (t) {
|
| 1044 |
+
this._isDestroyed ||
|
| 1045 |
+
(-1 === this._items.indexOf(t) &&
|
| 1046 |
+
(this._items.push(t),
|
| 1047 |
+
(this._requestOverlapCheck[t._id] = this._tickTime),
|
| 1048 |
+
(this._dragDirections[t._id] = [0, 0]),
|
| 1049 |
+
(this._dragPositions[t._id] = []),
|
| 1050 |
+
this._isTicking || this._startTicking()))
|
| 1051 |
+
}),
|
| 1052 |
+
(qt.prototype.updateItem = function (t) {
|
| 1053 |
+
this._isDestroyed ||
|
| 1054 |
+
(this._dragDirections[t._id] &&
|
| 1055 |
+
(this._updateDragDirection(t),
|
| 1056 |
+
this._requestOverlapCheck[t._id] || (this._requestOverlapCheck[t._id] = this._tickTime)))
|
| 1057 |
+
}),
|
| 1058 |
+
(qt.prototype.removeItem = function (t) {
|
| 1059 |
+
if (!this._isDestroyed) {
|
| 1060 |
+
var e = this._items.indexOf(t)
|
| 1061 |
+
if (-1 !== e) {
|
| 1062 |
+
var i = t._id
|
| 1063 |
+
this._requests[1][i] && (this._cancelItemScroll(t, 1), delete this._requests[1][i]),
|
| 1064 |
+
this._requests[2][i] && (this._cancelItemScroll(t, 2), delete this._requests[2][i]),
|
| 1065 |
+
delete this._requestOverlapCheck[i],
|
| 1066 |
+
delete this._dragPositions[i],
|
| 1067 |
+
delete this._dragDirections[i],
|
| 1068 |
+
this._items.splice(e, 1),
|
| 1069 |
+
this._isTicking && !this._items.length && this._stopTicking()
|
| 1070 |
+
}
|
| 1071 |
+
}
|
| 1072 |
+
}),
|
| 1073 |
+
(qt.prototype.isItemScrollingX = function (t) {
|
| 1074 |
+
var e = this._requests[1][t._id]
|
| 1075 |
+
return !(!e || !e.isActive)
|
| 1076 |
+
}),
|
| 1077 |
+
(qt.prototype.isItemScrollingY = function (t) {
|
| 1078 |
+
var e = this._requests[2][t._id]
|
| 1079 |
+
return !(!e || !e.isActive)
|
| 1080 |
+
}),
|
| 1081 |
+
(qt.prototype.isItemScrolling = function (t) {
|
| 1082 |
+
return this.isItemScrollingX(t) || this.isItemScrollingY(t)
|
| 1083 |
+
}),
|
| 1084 |
+
(qt.prototype.destroy = function () {
|
| 1085 |
+
if (!this._isDestroyed) {
|
| 1086 |
+
for (var t = this._items.slice(0), e = 0; e < t.length; e++) this.removeItem(t[e])
|
| 1087 |
+
;(this._actions.length = 0),
|
| 1088 |
+
this._requestPool.reset(),
|
| 1089 |
+
this._actionPool.reset(),
|
| 1090 |
+
(this._isDestroyed = !0)
|
| 1091 |
+
}
|
| 1092 |
+
})
|
| 1093 |
+
var Ht = window.Element.prototype,
|
| 1094 |
+
Ft =
|
| 1095 |
+
Ht.matches ||
|
| 1096 |
+
Ht.matchesSelector ||
|
| 1097 |
+
Ht.webkitMatchesSelector ||
|
| 1098 |
+
Ht.mozMatchesSelector ||
|
| 1099 |
+
Ht.msMatchesSelector ||
|
| 1100 |
+
Ht.oMatchesSelector ||
|
| 1101 |
+
function () {
|
| 1102 |
+
return !1
|
| 1103 |
+
}
|
| 1104 |
+
function Wt(t, e) {
|
| 1105 |
+
return Ft.call(t, e)
|
| 1106 |
+
}
|
| 1107 |
+
function Bt(t, e) {
|
| 1108 |
+
e && (t.classList ? t.classList.add(e) : Wt(t, '.' + e) || (t.className += ' ' + e))
|
| 1109 |
+
}
|
| 1110 |
+
var Gt = []
|
| 1111 |
+
function zt(t, e, i) {
|
| 1112 |
+
var n = 'number' == typeof i ? i : -1
|
| 1113 |
+
n < 0 && (n = t.length - n + 1), t.splice.apply(t, Gt.concat(n, 0, e)), (Gt.length = 0)
|
| 1114 |
+
}
|
| 1115 |
+
function Vt(t, e, i) {
|
| 1116 |
+
var n = Math.max(0, t.length - 1 + (i || 0))
|
| 1117 |
+
return e > n ? n : e < 0 ? Math.max(n + e + 1, 0) : e
|
| 1118 |
+
}
|
| 1119 |
+
function jt(t, e, i) {
|
| 1120 |
+
if (!(t.length < 2)) {
|
| 1121 |
+
var n = Vt(t, e),
|
| 1122 |
+
r = Vt(t, i)
|
| 1123 |
+
n !== r && t.splice(r, 0, t.splice(n, 1)[0])
|
| 1124 |
+
}
|
| 1125 |
+
}
|
| 1126 |
+
function Ut(t, e, i) {
|
| 1127 |
+
if (!(t.length < 2)) {
|
| 1128 |
+
var n,
|
| 1129 |
+
r = Vt(t, e),
|
| 1130 |
+
s = Vt(t, i)
|
| 1131 |
+
r !== s && ((n = t[r]), (t[r] = t[s]), (t[s] = n))
|
| 1132 |
+
}
|
| 1133 |
+
}
|
| 1134 |
+
var Qt = x(document.documentElement.style, 'transform') || 'transform',
|
| 1135 |
+
Kt = /([A-Z])/g,
|
| 1136 |
+
$t = /^(webkit-|moz-|ms-|o-)/,
|
| 1137 |
+
Zt = /^(-m-s-)/
|
| 1138 |
+
function Jt(t) {
|
| 1139 |
+
var e = t.replace(Kt, '-$1').toLowerCase()
|
| 1140 |
+
return (e = (e = e.replace($t, '-$1')).replace(Zt, '-ms-'))
|
| 1141 |
+
}
|
| 1142 |
+
var te = Jt(Qt)
|
| 1143 |
+
function ee(t) {
|
| 1144 |
+
var e = gt(t, te)
|
| 1145 |
+
if (!e || 'none' === e) return !1
|
| 1146 |
+
var i = gt(t, 'display')
|
| 1147 |
+
return 'inline' !== i && 'none' !== i
|
| 1148 |
+
}
|
| 1149 |
+
function ie(t) {
|
| 1150 |
+
for (var e = document, i = t || e; i && i !== e && 'static' === gt(i, 'position') && !ee(i); )
|
| 1151 |
+
i = i.parentElement || e
|
| 1152 |
+
return i
|
| 1153 |
+
}
|
| 1154 |
+
var ne = {},
|
| 1155 |
+
re = {},
|
| 1156 |
+
se = {}
|
| 1157 |
+
function oe(t, e) {
|
| 1158 |
+
var i,
|
| 1159 |
+
n = e || {}
|
| 1160 |
+
return (
|
| 1161 |
+
(n.left = 0),
|
| 1162 |
+
(n.top = 0),
|
| 1163 |
+
t === document
|
| 1164 |
+
? n
|
| 1165 |
+
: ((n.left = window.pageXOffset || 0),
|
| 1166 |
+
(n.top = window.pageYOffset || 0),
|
| 1167 |
+
t.self === window.self ||
|
| 1168 |
+
((i = t.getBoundingClientRect()),
|
| 1169 |
+
(n.left += i.left),
|
| 1170 |
+
(n.top += i.top),
|
| 1171 |
+
(n.left += vt(t, 'border-left-width')),
|
| 1172 |
+
(n.top += vt(t, 'border-top-width'))),
|
| 1173 |
+
n)
|
| 1174 |
+
)
|
| 1175 |
+
}
|
| 1176 |
+
function ae(t, e, i) {
|
| 1177 |
+
return (
|
| 1178 |
+
(se.left = 0),
|
| 1179 |
+
(se.top = 0),
|
| 1180 |
+
t === e ||
|
| 1181 |
+
(i && (t = ie(t)) === (e = ie(e))) ||
|
| 1182 |
+
(oe(t, ne), oe(e, re), (se.left = re.left - ne.left), (se.top = re.top - ne.top)),
|
| 1183 |
+
se
|
| 1184 |
+
)
|
| 1185 |
+
}
|
| 1186 |
+
function he(t) {
|
| 1187 |
+
return 'auto' === t || 'scroll' === t || 'overlay' === t
|
| 1188 |
+
}
|
| 1189 |
+
function le(t) {
|
| 1190 |
+
return he(gt(t, 'overflow')) || he(gt(t, 'overflow-x')) || he(gt(t, 'overflow-y'))
|
| 1191 |
+
}
|
| 1192 |
+
function ue(t, e) {
|
| 1193 |
+
for (e = e || []; t && t !== document; )
|
| 1194 |
+
t.getRootNode && t instanceof DocumentFragment
|
| 1195 |
+
? (t = t.getRootNode().host)
|
| 1196 |
+
: (le(t) && e.push(t), (t = t.parentNode))
|
| 1197 |
+
return e.push(window), e
|
| 1198 |
+
}
|
| 1199 |
+
var de = {},
|
| 1200 |
+
ce = /^matrix3d/,
|
| 1201 |
+
_e = /([^,]*,){4}/,
|
| 1202 |
+
fe = /([^,]*,){12}/,
|
| 1203 |
+
pe = /[^,]*,/
|
| 1204 |
+
function me(t) {
|
| 1205 |
+
;(de.x = 0), (de.y = 0)
|
| 1206 |
+
var e = gt(t, te)
|
| 1207 |
+
if (!e || 'none' === e) return de
|
| 1208 |
+
var i = ce.test(e),
|
| 1209 |
+
n = e.replace(i ? fe : _e, ''),
|
| 1210 |
+
r = n.replace(pe, '')
|
| 1211 |
+
return (de.x = parseFloat(n) || 0), (de.y = parseFloat(r) || 0), de
|
| 1212 |
+
}
|
| 1213 |
+
function ge(t, e) {
|
| 1214 |
+
e &&
|
| 1215 |
+
(t.classList
|
| 1216 |
+
? t.classList.remove(e)
|
| 1217 |
+
: Wt(t, '.' + e) && (t.className = (' ' + t.className + ' ').replace(' ' + e + ' ', ' ').trim()))
|
| 1218 |
+
}
|
| 1219 |
+
var ve,
|
| 1220 |
+
ye,
|
| 1221 |
+
be,
|
| 1222 |
+
we,
|
| 1223 |
+
Se =
|
| 1224 |
+
/^(iPad|iPhone|iPod)/.test(window.navigator.platform) ||
|
| 1225 |
+
(/^Mac/.test(window.navigator.platform) && window.navigator.maxTouchPoints > 1),
|
| 1226 |
+
Te = !!A() && { passive: !0 }
|
| 1227 |
+
function De(t) {
|
| 1228 |
+
var e = t._element,
|
| 1229 |
+
i = t.getGrid(),
|
| 1230 |
+
n = i._settings
|
| 1231 |
+
;(this._item = t),
|
| 1232 |
+
(this._gridId = i._id),
|
| 1233 |
+
(this._isDestroyed = !1),
|
| 1234 |
+
(this._isMigrating = !1),
|
| 1235 |
+
(this._startPredicate = dt(n.dragStartPredicate) ? n.dragStartPredicate : De.defaultStartPredicate),
|
| 1236 |
+
(this._startPredicateState = 0),
|
| 1237 |
+
(this._startPredicateResult = void 0),
|
| 1238 |
+
(this._isSortNeeded = !1),
|
| 1239 |
+
(this._sortTimer = void 0),
|
| 1240 |
+
(this._blockedSortIndex = null),
|
| 1241 |
+
(this._sortX1 = 0),
|
| 1242 |
+
(this._sortX2 = 0),
|
| 1243 |
+
(this._sortY1 = 0),
|
| 1244 |
+
(this._sortY2 = 0),
|
| 1245 |
+
this._reset(),
|
| 1246 |
+
(this._preStartCheck = this._preStartCheck.bind(this)),
|
| 1247 |
+
(this._preEndCheck = this._preEndCheck.bind(this)),
|
| 1248 |
+
(this._onScroll = this._onScroll.bind(this)),
|
| 1249 |
+
(this._prepareStart = this._prepareStart.bind(this)),
|
| 1250 |
+
(this._applyStart = this._applyStart.bind(this)),
|
| 1251 |
+
(this._prepareMove = this._prepareMove.bind(this)),
|
| 1252 |
+
(this._applyMove = this._applyMove.bind(this)),
|
| 1253 |
+
(this._prepareScroll = this._prepareScroll.bind(this)),
|
| 1254 |
+
(this._applyScroll = this._applyScroll.bind(this)),
|
| 1255 |
+
(this._handleSort = this._handleSort.bind(this)),
|
| 1256 |
+
(this._handleSortDelayed = this._handleSortDelayed.bind(this)),
|
| 1257 |
+
(this._handle = (n.dragHandle && e.querySelector(n.dragHandle)) || e),
|
| 1258 |
+
(this._dragger = new N(this._handle, n.dragCssProps)),
|
| 1259 |
+
this._dragger.on('start', this._preStartCheck),
|
| 1260 |
+
this._dragger.on('move', this._preStartCheck),
|
| 1261 |
+
this._dragger.on('cancel', this._preEndCheck),
|
| 1262 |
+
this._dragger.on('end', this._preEndCheck)
|
| 1263 |
+
}
|
| 1264 |
+
function xe(t, e) {
|
| 1265 |
+
var i,
|
| 1266 |
+
n,
|
| 1267 |
+
r = {}
|
| 1268 |
+
if (Array.isArray(e)) for (n = 0; n < e.length; n++) r[(i = e[n])] = gt(t, Jt(i))
|
| 1269 |
+
else for (i in e) r[i] = gt(t, Jt(i))
|
| 1270 |
+
return r
|
| 1271 |
+
}
|
| 1272 |
+
;(De.autoScroller = new qt()),
|
| 1273 |
+
(De.defaultStartPredicate = function (t, e, i) {
|
| 1274 |
+
var n = t._drag
|
| 1275 |
+
if (e.isFirst && e.srcEvent.button) return !1
|
| 1276 |
+
if (
|
| 1277 |
+
!Se &&
|
| 1278 |
+
e.isFirst &&
|
| 1279 |
+
!0 === e.srcEvent.isTrusted &&
|
| 1280 |
+
!1 === e.srcEvent.defaultPrevented &&
|
| 1281 |
+
!1 === e.srcEvent.cancelable
|
| 1282 |
+
)
|
| 1283 |
+
return !1
|
| 1284 |
+
if (!e.isFinal) {
|
| 1285 |
+
var r = n._startPredicateData
|
| 1286 |
+
if (!r) {
|
| 1287 |
+
var s = i || n._getGrid()._settings.dragStartPredicate || {}
|
| 1288 |
+
n._startPredicateData = r = {
|
| 1289 |
+
distance: Math.max(s.distance, 0) || 0,
|
| 1290 |
+
delay: Math.max(s.delay, 0) || 0,
|
| 1291 |
+
}
|
| 1292 |
+
}
|
| 1293 |
+
return (
|
| 1294 |
+
r.delay &&
|
| 1295 |
+
((r.event = e),
|
| 1296 |
+
r.delayTimer ||
|
| 1297 |
+
(r.delayTimer = window.setTimeout(function () {
|
| 1298 |
+
;(r.delay = 0),
|
| 1299 |
+
n._resolveStartPredicate(r.event) &&
|
| 1300 |
+
(n._forceResolveStartPredicate(r.event), n._resetStartPredicate())
|
| 1301 |
+
}, r.delay))),
|
| 1302 |
+
n._resolveStartPredicate(e)
|
| 1303 |
+
)
|
| 1304 |
+
}
|
| 1305 |
+
n._finishStartPredicate(e)
|
| 1306 |
+
}),
|
| 1307 |
+
(De.defaultSortPredicate =
|
| 1308 |
+
((ve = {}),
|
| 1309 |
+
(ye = {}),
|
| 1310 |
+
(be = {}),
|
| 1311 |
+
(we = []),
|
| 1312 |
+
function (t, e) {
|
| 1313 |
+
var r = t._drag,
|
| 1314 |
+
s = r._getGrid(),
|
| 1315 |
+
o = e && 'number' == typeof e.threshold ? e.threshold : 50,
|
| 1316 |
+
a = e && e.action === i ? i : n,
|
| 1317 |
+
h = e && e.migrateAction === i ? i : n
|
| 1318 |
+
;(o = Math.min(Math.max(o, 1), 100)),
|
| 1319 |
+
(ve.width = t._width),
|
| 1320 |
+
(ve.height = t._height),
|
| 1321 |
+
(ve.left = r._clientX),
|
| 1322 |
+
(ve.top = r._clientY)
|
| 1323 |
+
var l = (function (t, e, i) {
|
| 1324 |
+
var n,
|
| 1325 |
+
r,
|
| 1326 |
+
s,
|
| 1327 |
+
o,
|
| 1328 |
+
a,
|
| 1329 |
+
h,
|
| 1330 |
+
l,
|
| 1331 |
+
u,
|
| 1332 |
+
d,
|
| 1333 |
+
c,
|
| 1334 |
+
_ = null,
|
| 1335 |
+
f = e._settings.dragSort,
|
| 1336 |
+
p = -1
|
| 1337 |
+
if (
|
| 1338 |
+
(!0 === f ? ((we[0] = e), (r = we)) : dt(f) && (r = f.call(e, t)),
|
| 1339 |
+
!r || !Array.isArray(r) || !r.length)
|
| 1340 |
+
)
|
| 1341 |
+
return _
|
| 1342 |
+
for (c = 0; c < r.length; c++)
|
| 1343 |
+
if (!(s = r[c])._isDestroyed) {
|
| 1344 |
+
for (
|
| 1345 |
+
s._updateBoundingRect(),
|
| 1346 |
+
h = Math.max(0, s._left),
|
| 1347 |
+
l = Math.max(0, s._top),
|
| 1348 |
+
u = Math.min(window.innerWidth, s._right),
|
| 1349 |
+
d = Math.min(window.innerHeight, s._bottom),
|
| 1350 |
+
o = s._element.parentNode;
|
| 1351 |
+
o && o !== document && o !== document.documentElement && o !== document.body;
|
| 1352 |
+
|
| 1353 |
+
)
|
| 1354 |
+
if (o.getRootNode && o instanceof DocumentFragment) o = o.getRootNode().host
|
| 1355 |
+
else {
|
| 1356 |
+
if (
|
| 1357 |
+
('visible' !== gt(o, 'overflow') &&
|
| 1358 |
+
((a = o.getBoundingClientRect()),
|
| 1359 |
+
(h = Math.max(h, a.left)),
|
| 1360 |
+
(l = Math.max(l, a.top)),
|
| 1361 |
+
(u = Math.min(u, a.right)),
|
| 1362 |
+
(d = Math.min(d, a.bottom))),
|
| 1363 |
+
'fixed' === gt(o, 'position'))
|
| 1364 |
+
)
|
| 1365 |
+
break
|
| 1366 |
+
o = o.parentNode
|
| 1367 |
+
}
|
| 1368 |
+
h >= u ||
|
| 1369 |
+
l >= d ||
|
| 1370 |
+
((ye.left = h),
|
| 1371 |
+
(ye.top = l),
|
| 1372 |
+
(ye.width = u - h),
|
| 1373 |
+
(ye.height = d - l),
|
| 1374 |
+
(n = Ot(ve, ye)) > i && n > p && ((p = n), (_ = s)))
|
| 1375 |
+
}
|
| 1376 |
+
return (we.length = 0), _
|
| 1377 |
+
})(t, s, o)
|
| 1378 |
+
if (!l) return null
|
| 1379 |
+
var u,
|
| 1380 |
+
d,
|
| 1381 |
+
c,
|
| 1382 |
+
_ = t.getGrid() !== l,
|
| 1383 |
+
f = 0,
|
| 1384 |
+
p = 0,
|
| 1385 |
+
m = 0,
|
| 1386 |
+
g = -1,
|
| 1387 |
+
v = !1
|
| 1388 |
+
for (
|
| 1389 |
+
l === s
|
| 1390 |
+
? ((ve.left = r._gridX + t._marginLeft), (ve.top = r._gridY + t._marginTop))
|
| 1391 |
+
: (l._updateBorders(1, 0, 1, 0), (f = l._left + l._borderLeft), (p = l._top + l._borderTop)),
|
| 1392 |
+
c = 0;
|
| 1393 |
+
c < l._items.length;
|
| 1394 |
+
c++
|
| 1395 |
+
)
|
| 1396 |
+
(u = l._items[c])._isActive &&
|
| 1397 |
+
u !== t &&
|
| 1398 |
+
((v = !0),
|
| 1399 |
+
(ye.width = u._width),
|
| 1400 |
+
(ye.height = u._height),
|
| 1401 |
+
(ye.left = u._left + u._marginLeft + f),
|
| 1402 |
+
(ye.top = u._top + u._marginTop + p),
|
| 1403 |
+
(d = Ot(ve, ye)) > m && ((g = c), (m = d)))
|
| 1404 |
+
return (
|
| 1405 |
+
_ && m < o && ((g = v ? g : 0), (m = o)),
|
| 1406 |
+
m >= o ? ((be.grid = l), (be.index = g), (be.action = _ ? h : a), be) : null
|
| 1407 |
+
)
|
| 1408 |
+
})),
|
| 1409 |
+
(De.prototype.stop = function () {
|
| 1410 |
+
if (this._isActive)
|
| 1411 |
+
if (this._isMigrating) this._finishMigration()
|
| 1412 |
+
else {
|
| 1413 |
+
De.autoScroller.removeItem(this._item)
|
| 1414 |
+
var t = this._item._id
|
| 1415 |
+
if ((st(t), ot(t), at(t), this._cancelSort(), this._isStarted)) {
|
| 1416 |
+
this._unbindScrollListeners()
|
| 1417 |
+
var e = item._element,
|
| 1418 |
+
i = this._getGrid(),
|
| 1419 |
+
n = i._settings.itemDraggingClass
|
| 1420 |
+
e.parentNode !== i._element &&
|
| 1421 |
+
(i._element.appendChild(e), item._setTranslate(this._gridX, this._gridY)),
|
| 1422 |
+
ge(e, n)
|
| 1423 |
+
}
|
| 1424 |
+
this._reset()
|
| 1425 |
+
}
|
| 1426 |
+
}),
|
| 1427 |
+
(De.prototype.sort = function (t) {
|
| 1428 |
+
var e = this._item
|
| 1429 |
+
this._isActive &&
|
| 1430 |
+
e._isActive &&
|
| 1431 |
+
this._dragMoveEvent &&
|
| 1432 |
+
(!0 === t ? this._handleSort() : ht(e._id, this._handleSort))
|
| 1433 |
+
}),
|
| 1434 |
+
(De.prototype.destroy = function () {
|
| 1435 |
+
this._isDestroyed ||
|
| 1436 |
+
(this.stop(), this._dragger.destroy(), De.autoScroller.removeItem(this._item), (this._isDestroyed = !0))
|
| 1437 |
+
}),
|
| 1438 |
+
(De.prototype._getGrid = function () {
|
| 1439 |
+
return t[this._gridId] || null
|
| 1440 |
+
}),
|
| 1441 |
+
(De.prototype._reset = function () {
|
| 1442 |
+
;(this._isActive = !1),
|
| 1443 |
+
(this._isStarted = !1),
|
| 1444 |
+
(this._container = null),
|
| 1445 |
+
(this._containingBlock = null),
|
| 1446 |
+
(this._dragStartEvent = null),
|
| 1447 |
+
(this._dragMoveEvent = null),
|
| 1448 |
+
(this._dragPrevMoveEvent = null),
|
| 1449 |
+
(this._scrollEvent = null),
|
| 1450 |
+
(this._scrollers = []),
|
| 1451 |
+
(this._left = 0),
|
| 1452 |
+
(this._top = 0),
|
| 1453 |
+
(this._gridX = 0),
|
| 1454 |
+
(this._gridY = 0),
|
| 1455 |
+
(this._clientX = 0),
|
| 1456 |
+
(this._clientY = 0),
|
| 1457 |
+
(this._scrollDiffX = 0),
|
| 1458 |
+
(this._scrollDiffY = 0),
|
| 1459 |
+
(this._moveDiffX = 0),
|
| 1460 |
+
(this._moveDiffY = 0),
|
| 1461 |
+
(this._containerDiffX = 0),
|
| 1462 |
+
(this._containerDiffY = 0)
|
| 1463 |
+
}),
|
| 1464 |
+
(De.prototype._bindScrollListeners = function () {
|
| 1465 |
+
var t,
|
| 1466 |
+
e,
|
| 1467 |
+
i = this._getGrid()._element,
|
| 1468 |
+
n = this._container,
|
| 1469 |
+
r = this._scrollers
|
| 1470 |
+
if (((r.length = 0), ue(this._item._element.parentNode, r), n !== i))
|
| 1471 |
+
for (ue(i, (t = [])), e = 0; e < t.length; e++) r.indexOf(t[e]) < 0 && r.push(t[e])
|
| 1472 |
+
for (e = 0; e < r.length; e++) r[e].addEventListener('scroll', this._onScroll, Te)
|
| 1473 |
+
}),
|
| 1474 |
+
(De.prototype._unbindScrollListeners = function () {
|
| 1475 |
+
var t,
|
| 1476 |
+
e = this._scrollers
|
| 1477 |
+
for (t = 0; t < e.length; t++) e[t].removeEventListener('scroll', this._onScroll, Te)
|
| 1478 |
+
e.length = 0
|
| 1479 |
+
}),
|
| 1480 |
+
(De.prototype._resolveStartPredicate = function (t) {
|
| 1481 |
+
var e = this._startPredicateData
|
| 1482 |
+
if (!(t.distance < e.distance || e.delay)) return this._resetStartPredicate(), !0
|
| 1483 |
+
}),
|
| 1484 |
+
(De.prototype._forceResolveStartPredicate = function (t) {
|
| 1485 |
+
this._isDestroyed || 1 !== this._startPredicateState || ((this._startPredicateState = 2), this._onStart(t))
|
| 1486 |
+
}),
|
| 1487 |
+
(De.prototype._finishStartPredicate = function (t) {
|
| 1488 |
+
var e = this._item._element,
|
| 1489 |
+
i = Math.abs(t.deltaX) < 2 && Math.abs(t.deltaY) < 2 && t.deltaTime < 200
|
| 1490 |
+
this._resetStartPredicate(),
|
| 1491 |
+
i &&
|
| 1492 |
+
(function (t) {
|
| 1493 |
+
if ('a' !== t.tagName.toLowerCase()) return
|
| 1494 |
+
var e = t.getAttribute('href')
|
| 1495 |
+
if (!e) return
|
| 1496 |
+
var i = t.getAttribute('target')
|
| 1497 |
+
i && '_self' !== i ? window.open(e, i) : (window.location.href = e)
|
| 1498 |
+
})(e)
|
| 1499 |
+
}),
|
| 1500 |
+
(De.prototype._resetHeuristics = function (t, e) {
|
| 1501 |
+
;(this._blockedSortIndex = null), (this._sortX1 = this._sortX2 = t), (this._sortY1 = this._sortY2 = e)
|
| 1502 |
+
}),
|
| 1503 |
+
(De.prototype._checkHeuristics = function (t, e) {
|
| 1504 |
+
var i = this._getGrid()._settings.dragSortHeuristics,
|
| 1505 |
+
n = i.minDragDistance
|
| 1506 |
+
if (n <= 0) return (this._blockedSortIndex = null), !0
|
| 1507 |
+
var r = t - this._sortX2,
|
| 1508 |
+
s = e - this._sortY2,
|
| 1509 |
+
o = n > 3 && i.minBounceBackAngle > 0
|
| 1510 |
+
if ((o || (this._blockedSortIndex = null), Math.abs(r) > n || Math.abs(s) > n)) {
|
| 1511 |
+
if (o) {
|
| 1512 |
+
var a = Math.atan2(r, s),
|
| 1513 |
+
h = Math.atan2(this._sortX2 - this._sortX1, this._sortY2 - this._sortY1),
|
| 1514 |
+
l = Math.atan2(Math.sin(a - h), Math.cos(a - h))
|
| 1515 |
+
Math.abs(l) > i.minBounceBackAngle && (this._blockedSortIndex = null)
|
| 1516 |
+
}
|
| 1517 |
+
return (
|
| 1518 |
+
(this._sortX1 = this._sortX2),
|
| 1519 |
+
(this._sortY1 = this._sortY2),
|
| 1520 |
+
(this._sortX2 = t),
|
| 1521 |
+
(this._sortY2 = e),
|
| 1522 |
+
!0
|
| 1523 |
+
)
|
| 1524 |
+
}
|
| 1525 |
+
return !1
|
| 1526 |
+
}),
|
| 1527 |
+
(De.prototype._resetStartPredicate = function () {
|
| 1528 |
+
var t = this._startPredicateData
|
| 1529 |
+
t && (t.delayTimer && (t.delayTimer = window.clearTimeout(t.delayTimer)), (this._startPredicateData = null))
|
| 1530 |
+
}),
|
| 1531 |
+
(De.prototype._handleSort = function () {
|
| 1532 |
+
if (this._isActive) {
|
| 1533 |
+
var t = this._getGrid()._settings
|
| 1534 |
+
if (!t.dragSort || (!t.dragAutoScroll.sortDuringScroll && De.autoScroller.isItemScrolling(this._item)))
|
| 1535 |
+
return (
|
| 1536 |
+
(this._sortX1 = this._sortX2 = this._gridX),
|
| 1537 |
+
(this._sortY1 = this._sortY2 = this._gridY),
|
| 1538 |
+
(this._isSortNeeded = !0),
|
| 1539 |
+
void (void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)))
|
| 1540 |
+
)
|
| 1541 |
+
var e = this._checkHeuristics(this._gridX, this._gridY)
|
| 1542 |
+
if (this._isSortNeeded || e) {
|
| 1543 |
+
var i = t.dragSortHeuristics.sortInterval
|
| 1544 |
+
i <= 0 || this._isSortNeeded
|
| 1545 |
+
? ((this._isSortNeeded = !1),
|
| 1546 |
+
void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)),
|
| 1547 |
+
this._checkOverlap())
|
| 1548 |
+
: void 0 === this._sortTimer &&
|
| 1549 |
+
(this._sortTimer = window.setTimeout(this._handleSortDelayed, i))
|
| 1550 |
+
}
|
| 1551 |
+
}
|
| 1552 |
+
}),
|
| 1553 |
+
(De.prototype._handleSortDelayed = function () {
|
| 1554 |
+
;(this._isSortNeeded = !0), (this._sortTimer = void 0), ht(this._item._id, this._handleSort)
|
| 1555 |
+
}),
|
| 1556 |
+
(De.prototype._cancelSort = function () {
|
| 1557 |
+
var t
|
| 1558 |
+
;(this._isSortNeeded = !1),
|
| 1559 |
+
void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)),
|
| 1560 |
+
(t = this._item._id),
|
| 1561 |
+
it.remove(1, Q + t)
|
| 1562 |
+
}),
|
| 1563 |
+
(De.prototype._finishSort = function () {
|
| 1564 |
+
var t = this._getGrid()._settings.dragSort && (this._isSortNeeded || void 0 !== this._sortTimer)
|
| 1565 |
+
this._cancelSort(), t && this._checkOverlap()
|
| 1566 |
+
}),
|
| 1567 |
+
(De.prototype._checkOverlap = function () {
|
| 1568 |
+
if (this._isActive) {
|
| 1569 |
+
var t,
|
| 1570 |
+
e,
|
| 1571 |
+
r,
|
| 1572 |
+
s,
|
| 1573 |
+
o,
|
| 1574 |
+
a,
|
| 1575 |
+
h,
|
| 1576 |
+
l,
|
| 1577 |
+
u = this._item,
|
| 1578 |
+
m = this._getGrid()._settings
|
| 1579 |
+
;(t = dt(m.dragSortPredicate)
|
| 1580 |
+
? m.dragSortPredicate(u, this._dragMoveEvent)
|
| 1581 |
+
: De.defaultSortPredicate(u, m.dragSortPredicate)) &&
|
| 1582 |
+
'number' == typeof t.index &&
|
| 1583 |
+
((h = t.action === i ? i : n),
|
| 1584 |
+
(l = (e = u.getGrid()) !== (s = t.grid || e)),
|
| 1585 |
+
(r = e._items.indexOf(u)),
|
| 1586 |
+
(o = Vt(s._items, t.index, l && h === n ? 1 : 0)),
|
| 1587 |
+
(l || o !== this._blockedSortIndex) &&
|
| 1588 |
+
(l
|
| 1589 |
+
? ((this._blockedSortIndex = null),
|
| 1590 |
+
(a = s._items[o]),
|
| 1591 |
+
e._hasListeners(_) &&
|
| 1592 |
+
e._emit(_, { item: u, fromGrid: e, fromIndex: r, toGrid: s, toIndex: o }),
|
| 1593 |
+
s._hasListeners(p) &&
|
| 1594 |
+
s._emit(p, { item: u, fromGrid: e, fromIndex: r, toGrid: s, toIndex: o }),
|
| 1595 |
+
(u._gridId = s._id),
|
| 1596 |
+
(this._isMigrating = u._gridId !== this._gridId),
|
| 1597 |
+
e._items.splice(r, 1),
|
| 1598 |
+
zt(s._items, u, o),
|
| 1599 |
+
(u._sortData = null),
|
| 1600 |
+
e._hasListeners(c) &&
|
| 1601 |
+
e._emit(c, { item: u, fromGrid: e, fromIndex: r, toGrid: s, toIndex: o }),
|
| 1602 |
+
s._hasListeners(f) &&
|
| 1603 |
+
s._emit(f, { item: u, fromGrid: e, fromIndex: r, toGrid: s, toIndex: o }),
|
| 1604 |
+
h === i &&
|
| 1605 |
+
a &&
|
| 1606 |
+
a.isActive() &&
|
| 1607 |
+
s._items.indexOf(a) > -1 &&
|
| 1608 |
+
s.send(a, e, r, {
|
| 1609 |
+
appendTo: this._container || document.body,
|
| 1610 |
+
layoutSender: !1,
|
| 1611 |
+
layoutReceiver: !1,
|
| 1612 |
+
}),
|
| 1613 |
+
e.layout(),
|
| 1614 |
+
s.layout())
|
| 1615 |
+
: r !== o &&
|
| 1616 |
+
((this._blockedSortIndex = r),
|
| 1617 |
+
(h === i ? Ut : jt)(e._items, r, o),
|
| 1618 |
+
e._hasListeners(d) && e._emit(d, { item: u, fromIndex: r, toIndex: o, action: h }),
|
| 1619 |
+
e.layout())))
|
| 1620 |
+
}
|
| 1621 |
+
}),
|
| 1622 |
+
(De.prototype._finishMigration = function () {
|
| 1623 |
+
var t,
|
| 1624 |
+
e,
|
| 1625 |
+
i = this._item,
|
| 1626 |
+
n = i._dragRelease,
|
| 1627 |
+
r = i._element,
|
| 1628 |
+
s = i._isActive,
|
| 1629 |
+
o = i.getGrid(),
|
| 1630 |
+
a = o._element,
|
| 1631 |
+
h = o._settings,
|
| 1632 |
+
l = h.dragContainer || a,
|
| 1633 |
+
u = this._getGrid()._settings,
|
| 1634 |
+
d = r.parentNode,
|
| 1635 |
+
c = s ? u.itemVisibleClass : u.itemHiddenClass,
|
| 1636 |
+
_ = s ? h.itemVisibleClass : h.itemHiddenClass
|
| 1637 |
+
;(this._isMigrating = !1),
|
| 1638 |
+
this.destroy(),
|
| 1639 |
+
u.itemClass !== h.itemClass && (ge(r, u.itemClass), Bt(r, h.itemClass)),
|
| 1640 |
+
c !== _ && (ge(r, c), Bt(r, _)),
|
| 1641 |
+
l !== d && (l.appendChild(r), (e = ae(d, l, !0)), ((t = me(r)).x -= e.left), (t.y -= e.top)),
|
| 1642 |
+
i._refreshDimensions(),
|
| 1643 |
+
(e = ae(l, a, !0)),
|
| 1644 |
+
(n._containerDiffX = e.left),
|
| 1645 |
+
(n._containerDiffY = e.top),
|
| 1646 |
+
(i._drag = h.dragEnabled ? new De(i) : null),
|
| 1647 |
+
l !== d && i._setTranslate(t.x, t.y),
|
| 1648 |
+
i._visibility.setStyles(s ? h.visibleStyles : h.hiddenStyles),
|
| 1649 |
+
n.start()
|
| 1650 |
+
}),
|
| 1651 |
+
(De.prototype._preStartCheck = function (t) {
|
| 1652 |
+
0 === this._startPredicateState && (this._startPredicateState = 1),
|
| 1653 |
+
1 === this._startPredicateState
|
| 1654 |
+
? ((this._startPredicateResult = this._startPredicate(this._item, t)),
|
| 1655 |
+
!0 === this._startPredicateResult
|
| 1656 |
+
? ((this._startPredicateState = 2), this._onStart(t))
|
| 1657 |
+
: !1 === this._startPredicateResult &&
|
| 1658 |
+
(this._resetStartPredicate(t), this._dragger._reset(), (this._startPredicateState = 0)))
|
| 1659 |
+
: 2 === this._startPredicateState && this._isActive && this._onMove(t)
|
| 1660 |
+
}),
|
| 1661 |
+
(De.prototype._preEndCheck = function (t) {
|
| 1662 |
+
var e = 2 === this._startPredicateState
|
| 1663 |
+
this._startPredicate(this._item, t),
|
| 1664 |
+
(this._startPredicateState = 0),
|
| 1665 |
+
e && this._isActive && (this._isStarted ? this._onEnd(t) : this.stop())
|
| 1666 |
+
}),
|
| 1667 |
+
(De.prototype._onStart = function (t) {
|
| 1668 |
+
var e,
|
| 1669 |
+
i,
|
| 1670 |
+
n,
|
| 1671 |
+
r = this._item
|
| 1672 |
+
r._isActive &&
|
| 1673 |
+
((this._isActive = !0),
|
| 1674 |
+
(this._dragStartEvent = t),
|
| 1675 |
+
De.autoScroller.addItem(r),
|
| 1676 |
+
(e = r._id),
|
| 1677 |
+
(i = this._prepareStart),
|
| 1678 |
+
(n = this._applyStart),
|
| 1679 |
+
it.add(0, B + e, i),
|
| 1680 |
+
it.add(2, G + e, n))
|
| 1681 |
+
}),
|
| 1682 |
+
(De.prototype._prepareStart = function () {
|
| 1683 |
+
if (this._isActive) {
|
| 1684 |
+
var t = this._item
|
| 1685 |
+
if (t._isActive) {
|
| 1686 |
+
var e = t._element,
|
| 1687 |
+
i = this._getGrid(),
|
| 1688 |
+
n = i._settings,
|
| 1689 |
+
r = i._element,
|
| 1690 |
+
s = n.dragContainer || r,
|
| 1691 |
+
o = ie(s),
|
| 1692 |
+
a = me(e),
|
| 1693 |
+
h = e.getBoundingClientRect(),
|
| 1694 |
+
l = s !== r
|
| 1695 |
+
if (
|
| 1696 |
+
((this._container = s),
|
| 1697 |
+
(this._containingBlock = o),
|
| 1698 |
+
(this._clientX = h.left),
|
| 1699 |
+
(this._clientY = h.top),
|
| 1700 |
+
(this._left = this._gridX = a.x),
|
| 1701 |
+
(this._top = this._gridY = a.y),
|
| 1702 |
+
(this._scrollDiffX = this._scrollDiffY = 0),
|
| 1703 |
+
(this._moveDiffX = this._moveDiffY = 0),
|
| 1704 |
+
this._resetHeuristics(this._gridX, this._gridY),
|
| 1705 |
+
l)
|
| 1706 |
+
) {
|
| 1707 |
+
var u = ae(o, r)
|
| 1708 |
+
;(this._containerDiffX = u.left), (this._containerDiffY = u.top)
|
| 1709 |
+
}
|
| 1710 |
+
}
|
| 1711 |
+
}
|
| 1712 |
+
}),
|
| 1713 |
+
(De.prototype._applyStart = function () {
|
| 1714 |
+
if (this._isActive) {
|
| 1715 |
+
var t = this._item
|
| 1716 |
+
if (t._isActive) {
|
| 1717 |
+
var e = this._getGrid(),
|
| 1718 |
+
i = t._element,
|
| 1719 |
+
n = t._dragRelease,
|
| 1720 |
+
r = t._migrate,
|
| 1721 |
+
s = this._container !== e._element
|
| 1722 |
+
t.isPositioning() && t._layout.stop(!0, this._left, this._top),
|
| 1723 |
+
r._isActive &&
|
| 1724 |
+
((this._left -= r._containerDiffX),
|
| 1725 |
+
(this._top -= r._containerDiffY),
|
| 1726 |
+
(this._gridX -= r._containerDiffX),
|
| 1727 |
+
(this._gridY -= r._containerDiffY),
|
| 1728 |
+
r.stop(!0, this._left, this._top)),
|
| 1729 |
+
t.isReleasing() && n._reset(),
|
| 1730 |
+
e._settings.dragPlaceholder.enabled && t._dragPlaceholder.create(),
|
| 1731 |
+
(this._isStarted = !0),
|
| 1732 |
+
e._emit('dragInit', t, this._dragStartEvent),
|
| 1733 |
+
s &&
|
| 1734 |
+
(i.parentNode === this._container
|
| 1735 |
+
? ((this._gridX -= this._containerDiffX), (this._gridY -= this._containerDiffY))
|
| 1736 |
+
: ((this._left += this._containerDiffX),
|
| 1737 |
+
(this._top += this._containerDiffY),
|
| 1738 |
+
this._container.appendChild(i),
|
| 1739 |
+
t._setTranslate(this._left, this._top))),
|
| 1740 |
+
Bt(i, e._settings.itemDraggingClass),
|
| 1741 |
+
this._bindScrollListeners(),
|
| 1742 |
+
e._emit('dragStart', t, this._dragStartEvent)
|
| 1743 |
+
}
|
| 1744 |
+
}
|
| 1745 |
+
}),
|
| 1746 |
+
(De.prototype._onMove = function (t) {
|
| 1747 |
+
var e,
|
| 1748 |
+
i,
|
| 1749 |
+
n,
|
| 1750 |
+
r = this._item
|
| 1751 |
+
r._isActive
|
| 1752 |
+
? ((this._dragMoveEvent = t),
|
| 1753 |
+
(e = r._id),
|
| 1754 |
+
(i = this._prepareMove),
|
| 1755 |
+
(n = this._applyMove),
|
| 1756 |
+
it.add(0, z + e, i),
|
| 1757 |
+
it.add(2, V + e, n),
|
| 1758 |
+
ht(r._id, this._handleSort))
|
| 1759 |
+
: this.stop()
|
| 1760 |
+
}),
|
| 1761 |
+
(De.prototype._prepareMove = function () {
|
| 1762 |
+
if (this._isActive && this._item._isActive) {
|
| 1763 |
+
var t = this._getGrid()._settings.dragAxis,
|
| 1764 |
+
e = this._dragMoveEvent,
|
| 1765 |
+
i = this._dragPrevMoveEvent || this._dragStartEvent || e
|
| 1766 |
+
if ('y' !== t) {
|
| 1767 |
+
var n = e.clientX - i.clientX
|
| 1768 |
+
;(this._left = this._left - this._moveDiffX + n),
|
| 1769 |
+
(this._gridX = this._gridX - this._moveDiffX + n),
|
| 1770 |
+
(this._clientX = this._clientX - this._moveDiffX + n),
|
| 1771 |
+
(this._moveDiffX = n)
|
| 1772 |
+
}
|
| 1773 |
+
if ('x' !== t) {
|
| 1774 |
+
var r = e.clientY - i.clientY
|
| 1775 |
+
;(this._top = this._top - this._moveDiffY + r),
|
| 1776 |
+
(this._gridY = this._gridY - this._moveDiffY + r),
|
| 1777 |
+
(this._clientY = this._clientY - this._moveDiffY + r),
|
| 1778 |
+
(this._moveDiffY = r)
|
| 1779 |
+
}
|
| 1780 |
+
this._dragPrevMoveEvent = e
|
| 1781 |
+
}
|
| 1782 |
+
}),
|
| 1783 |
+
(De.prototype._applyMove = function () {
|
| 1784 |
+
if (this._isActive) {
|
| 1785 |
+
var t = this._item
|
| 1786 |
+
t._isActive &&
|
| 1787 |
+
((this._moveDiffX = this._moveDiffY = 0),
|
| 1788 |
+
t._setTranslate(this._left, this._top),
|
| 1789 |
+
this._getGrid()._emit('dragMove', t, this._dragMoveEvent),
|
| 1790 |
+
De.autoScroller.updateItem(t))
|
| 1791 |
+
}
|
| 1792 |
+
}),
|
| 1793 |
+
(De.prototype._onScroll = function (t) {
|
| 1794 |
+
var e,
|
| 1795 |
+
i,
|
| 1796 |
+
n,
|
| 1797 |
+
r = this._item
|
| 1798 |
+
r._isActive
|
| 1799 |
+
? ((this._scrollEvent = t),
|
| 1800 |
+
(e = r._id),
|
| 1801 |
+
(i = this._prepareScroll),
|
| 1802 |
+
(n = this._applyScroll),
|
| 1803 |
+
it.add(0, j + e, i),
|
| 1804 |
+
it.add(2, U + e, n),
|
| 1805 |
+
ht(r._id, this._handleSort))
|
| 1806 |
+
: this.stop()
|
| 1807 |
+
}),
|
| 1808 |
+
(De.prototype._prepareScroll = function () {
|
| 1809 |
+
if (this._isActive) {
|
| 1810 |
+
var t = this._item
|
| 1811 |
+
if (t._isActive) {
|
| 1812 |
+
var e = t._element,
|
| 1813 |
+
i = this._getGrid(),
|
| 1814 |
+
n = i._element,
|
| 1815 |
+
r = i._settings.dragAxis,
|
| 1816 |
+
s = 'y' !== r,
|
| 1817 |
+
o = 'x' !== r,
|
| 1818 |
+
a = e.getBoundingClientRect()
|
| 1819 |
+
if (this._container !== n) {
|
| 1820 |
+
var h = ae(this._containingBlock, n)
|
| 1821 |
+
;(this._containerDiffX = h.left), (this._containerDiffY = h.top)
|
| 1822 |
+
}
|
| 1823 |
+
if (s) {
|
| 1824 |
+
var l = this._clientX - this._moveDiffX - this._scrollDiffX - a.left
|
| 1825 |
+
;(this._left = this._left - this._scrollDiffX + l), (this._scrollDiffX = l)
|
| 1826 |
+
}
|
| 1827 |
+
if (o) {
|
| 1828 |
+
var u = this._clientY - this._moveDiffY - this._scrollDiffY - a.top
|
| 1829 |
+
;(this._top = this._top - this._scrollDiffY + u), (this._scrollDiffY = u)
|
| 1830 |
+
}
|
| 1831 |
+
;(this._gridX = this._left - this._containerDiffX), (this._gridY = this._top - this._containerDiffY)
|
| 1832 |
+
}
|
| 1833 |
+
}
|
| 1834 |
+
}),
|
| 1835 |
+
(De.prototype._applyScroll = function () {
|
| 1836 |
+
if (this._isActive) {
|
| 1837 |
+
var t = this._item
|
| 1838 |
+
t._isActive &&
|
| 1839 |
+
((this._scrollDiffX = this._scrollDiffY = 0),
|
| 1840 |
+
t._setTranslate(this._left, this._top),
|
| 1841 |
+
this._getGrid()._emit('dragScroll', t, this._scrollEvent))
|
| 1842 |
+
}
|
| 1843 |
+
}),
|
| 1844 |
+
(De.prototype._onEnd = function (t) {
|
| 1845 |
+
var e = this._item,
|
| 1846 |
+
i = e._element,
|
| 1847 |
+
n = this._getGrid(),
|
| 1848 |
+
r = n._settings,
|
| 1849 |
+
s = e._dragRelease
|
| 1850 |
+
e._isActive
|
| 1851 |
+
? (st(e._id),
|
| 1852 |
+
ot(e._id),
|
| 1853 |
+
at(e._id),
|
| 1854 |
+
this._finishSort(),
|
| 1855 |
+
this._unbindScrollListeners(),
|
| 1856 |
+
(s._containerDiffX = this._containerDiffX),
|
| 1857 |
+
(s._containerDiffY = this._containerDiffY),
|
| 1858 |
+
this._reset(),
|
| 1859 |
+
ge(i, r.itemDraggingClass),
|
| 1860 |
+
De.autoScroller.removeItem(e),
|
| 1861 |
+
n._emit('dragEnd', e, t),
|
| 1862 |
+
this._isMigrating ? this._finishMigration() : s.start())
|
| 1863 |
+
: this.stop()
|
| 1864 |
+
})
|
| 1865 |
+
var Ae = /^(webkit|moz|ms|o|Webkit|Moz|MS|O)(?=[A-Z])/,
|
| 1866 |
+
ke = {}
|
| 1867 |
+
function Ee(t) {
|
| 1868 |
+
var e = ke[t]
|
| 1869 |
+
return e || ((e = t.replace(Ae, '')) !== t && (e = e[0].toLowerCase() + e.slice(1)), (ke[t] = e), e)
|
| 1870 |
+
}
|
| 1871 |
+
function Re(t, e) {
|
| 1872 |
+
for (var i in e) t.style[i] = e[i]
|
| 1873 |
+
}
|
| 1874 |
+
var Le,
|
| 1875 |
+
Pe,
|
| 1876 |
+
Me = !(!Element || !dt(Element.prototype.animate)),
|
| 1877 |
+
Ie = !!(
|
| 1878 |
+
Element &&
|
| 1879 |
+
((Le = Element.prototype.animate),
|
| 1880 |
+
(Pe = window.Symbol),
|
| 1881 |
+
Le && dt(Pe) && dt(Pe.toString) && Pe(Le).toString().indexOf('[native code]') > -1)
|
| 1882 |
+
)
|
| 1883 |
+
function Ce(t) {
|
| 1884 |
+
;(this._element = t),
|
| 1885 |
+
(this._animation = null),
|
| 1886 |
+
(this._duration = 0),
|
| 1887 |
+
(this._easing = ''),
|
| 1888 |
+
(this._callback = null),
|
| 1889 |
+
(this._props = []),
|
| 1890 |
+
(this._values = []),
|
| 1891 |
+
(this._isDestroyed = !1),
|
| 1892 |
+
(this._onFinish = this._onFinish.bind(this))
|
| 1893 |
+
}
|
| 1894 |
+
function Ne(t, e) {
|
| 1895 |
+
var i = {}
|
| 1896 |
+
for (var n in t) i[e ? n : Ee(n)] = t[n]
|
| 1897 |
+
return i
|
| 1898 |
+
}
|
| 1899 |
+
function Oe(t, e) {
|
| 1900 |
+
return 'translateX(' + t + 'px) translateY(' + e + 'px)'
|
| 1901 |
+
}
|
| 1902 |
+
function Xe(t) {
|
| 1903 |
+
;(this._item = t),
|
| 1904 |
+
(this._animation = new Ce()),
|
| 1905 |
+
(this._element = null),
|
| 1906 |
+
(this._className = ''),
|
| 1907 |
+
(this._didMigrate = !1),
|
| 1908 |
+
(this._resetAfterLayout = !1),
|
| 1909 |
+
(this._left = 0),
|
| 1910 |
+
(this._top = 0),
|
| 1911 |
+
(this._transX = 0),
|
| 1912 |
+
(this._transY = 0),
|
| 1913 |
+
(this._nextTransX = 0),
|
| 1914 |
+
(this._nextTransY = 0),
|
| 1915 |
+
(this._setupAnimation = this._setupAnimation.bind(this)),
|
| 1916 |
+
(this._startAnimation = this._startAnimation.bind(this)),
|
| 1917 |
+
(this._updateDimensions = this._updateDimensions.bind(this)),
|
| 1918 |
+
(this._onLayoutStart = this._onLayoutStart.bind(this)),
|
| 1919 |
+
(this._onLayoutEnd = this._onLayoutEnd.bind(this)),
|
| 1920 |
+
(this._onReleaseEnd = this._onReleaseEnd.bind(this)),
|
| 1921 |
+
(this._onMigrate = this._onMigrate.bind(this)),
|
| 1922 |
+
(this._onHide = this._onHide.bind(this))
|
| 1923 |
+
}
|
| 1924 |
+
function Ye(t) {
|
| 1925 |
+
;(this._item = t),
|
| 1926 |
+
(this._isActive = !1),
|
| 1927 |
+
(this._isDestroyed = !1),
|
| 1928 |
+
(this._isPositioningStarted = !1),
|
| 1929 |
+
(this._containerDiffX = 0),
|
| 1930 |
+
(this._containerDiffY = 0)
|
| 1931 |
+
}
|
| 1932 |
+
;(Ce.prototype.start = function (t, e, i) {
|
| 1933 |
+
if (!this._isDestroyed) {
|
| 1934 |
+
var n = this._element,
|
| 1935 |
+
r = i || {}
|
| 1936 |
+
if (!Me) return Re(n, e), (this._callback = dt(r.onFinish) ? r.onFinish : null), void this._onFinish()
|
| 1937 |
+
var s,
|
| 1938 |
+
o,
|
| 1939 |
+
a,
|
| 1940 |
+
h = this._animation,
|
| 1941 |
+
l = this._props,
|
| 1942 |
+
u = this._values,
|
| 1943 |
+
d = r.duration || 300,
|
| 1944 |
+
c = r.easing || 'ease',
|
| 1945 |
+
_ = !1
|
| 1946 |
+
if (h && ((o = 0), (d === this._duration && c === this._easing) || (_ = !0), !_)) {
|
| 1947 |
+
for (s in e)
|
| 1948 |
+
if ((++o, -1 === (a = l.indexOf(s)) || e[s] !== u[a])) {
|
| 1949 |
+
_ = !0
|
| 1950 |
+
break
|
| 1951 |
+
}
|
| 1952 |
+
o !== l.length && (_ = !0)
|
| 1953 |
+
}
|
| 1954 |
+
if ((_ && h.cancel(), (this._callback = dt(r.onFinish) ? r.onFinish : null), !h || _)) {
|
| 1955 |
+
for (s in ((l.length = u.length = 0), e)) l.push(s), u.push(e[s])
|
| 1956 |
+
;(this._duration = d),
|
| 1957 |
+
(this._easing = c),
|
| 1958 |
+
(this._animation = n.animate([Ne(t, Ie), Ne(e, Ie)], { duration: d, easing: c })),
|
| 1959 |
+
(this._animation.onfinish = this._onFinish),
|
| 1960 |
+
Re(n, e)
|
| 1961 |
+
}
|
| 1962 |
+
}
|
| 1963 |
+
}),
|
| 1964 |
+
(Ce.prototype.stop = function () {
|
| 1965 |
+
!this._isDestroyed &&
|
| 1966 |
+
this._animation &&
|
| 1967 |
+
(this._animation.cancel(),
|
| 1968 |
+
(this._animation = this._callback = null),
|
| 1969 |
+
(this._props.length = this._values.length = 0))
|
| 1970 |
+
}),
|
| 1971 |
+
(Ce.prototype.getCurrentStyles = function () {
|
| 1972 |
+
return xe(element, currentProps)
|
| 1973 |
+
}),
|
| 1974 |
+
(Ce.prototype.isAnimating = function () {
|
| 1975 |
+
return !!this._animation
|
| 1976 |
+
}),
|
| 1977 |
+
(Ce.prototype.destroy = function () {
|
| 1978 |
+
this._isDestroyed || (this.stop(), (this._element = null), (this._isDestroyed = !0))
|
| 1979 |
+
}),
|
| 1980 |
+
(Ce.prototype._onFinish = function () {
|
| 1981 |
+
var t = this._callback
|
| 1982 |
+
;(this._animation = this._callback = null), (this._props.length = this._values.length = 0), t && t()
|
| 1983 |
+
}),
|
| 1984 |
+
(Xe.prototype._updateDimensions = function () {
|
| 1985 |
+
this.isActive() && Re(this._element, { width: this._item._width + 'px', height: this._item._height + 'px' })
|
| 1986 |
+
}),
|
| 1987 |
+
(Xe.prototype._onLayoutStart = function (t, e) {
|
| 1988 |
+
var i = this._item
|
| 1989 |
+
if (-1 !== t.indexOf(i)) {
|
| 1990 |
+
var n = i._left,
|
| 1991 |
+
r = i._top,
|
| 1992 |
+
s = this._left,
|
| 1993 |
+
o = this._top
|
| 1994 |
+
if (((this._left = n), (this._top = r), e || this._didMigrate || s !== n || o !== r)) {
|
| 1995 |
+
var a,
|
| 1996 |
+
h,
|
| 1997 |
+
l,
|
| 1998 |
+
u = n + i._marginLeft,
|
| 1999 |
+
d = r + i._marginTop,
|
| 2000 |
+
c = i.getGrid()
|
| 2001 |
+
if (!(!e && c._settings.layoutDuration > 0) || this._didMigrate)
|
| 2002 |
+
return (
|
| 2003 |
+
lt(i._id),
|
| 2004 |
+
(this._element.style[Qt] = Oe(u, d)),
|
| 2005 |
+
this._animation.stop(),
|
| 2006 |
+
void (
|
| 2007 |
+
this._didMigrate && (c.getElement().appendChild(this._element), (this._didMigrate = !1))
|
| 2008 |
+
)
|
| 2009 |
+
)
|
| 2010 |
+
;(this._nextTransX = u),
|
| 2011 |
+
(this._nextTransY = d),
|
| 2012 |
+
(a = i._id),
|
| 2013 |
+
(h = this._setupAnimation),
|
| 2014 |
+
(l = this._startAnimation),
|
| 2015 |
+
it.add(0, K + a, h),
|
| 2016 |
+
it.add(2, $ + a, l)
|
| 2017 |
+
}
|
| 2018 |
+
} else this.reset()
|
| 2019 |
+
}),
|
| 2020 |
+
(Xe.prototype._setupAnimation = function () {
|
| 2021 |
+
if (this.isActive()) {
|
| 2022 |
+
var t = me(this._element)
|
| 2023 |
+
;(this._transX = t.x), (this._transY = t.y)
|
| 2024 |
+
}
|
| 2025 |
+
}),
|
| 2026 |
+
(Xe.prototype._startAnimation = function () {
|
| 2027 |
+
if (this.isActive()) {
|
| 2028 |
+
var t = this._animation,
|
| 2029 |
+
e = this._transX,
|
| 2030 |
+
i = this._transY,
|
| 2031 |
+
n = this._nextTransX,
|
| 2032 |
+
r = this._nextTransY
|
| 2033 |
+
if (e !== n || i !== r) {
|
| 2034 |
+
var s = this._item.getGrid()._settings,
|
| 2035 |
+
o = {},
|
| 2036 |
+
a = {}
|
| 2037 |
+
;(o[Qt] = Oe(e, i)),
|
| 2038 |
+
(a[Qt] = Oe(n, r)),
|
| 2039 |
+
t.start(o, a, {
|
| 2040 |
+
duration: s.layoutDuration,
|
| 2041 |
+
easing: s.layoutEasing,
|
| 2042 |
+
onFinish: this._onLayoutEnd,
|
| 2043 |
+
})
|
| 2044 |
+
} else t.isAnimating() && ((this._element.style[Qt] = Oe(n, r)), t.stop())
|
| 2045 |
+
}
|
| 2046 |
+
}),
|
| 2047 |
+
(Xe.prototype._onLayoutEnd = function () {
|
| 2048 |
+
this._resetAfterLayout && this.reset()
|
| 2049 |
+
}),
|
| 2050 |
+
(Xe.prototype._onReleaseEnd = function (t) {
|
| 2051 |
+
if (t._id === this._item._id) {
|
| 2052 |
+
if (!this._animation.isAnimating()) return void this.reset()
|
| 2053 |
+
this._resetAfterLayout = !0
|
| 2054 |
+
}
|
| 2055 |
+
}),
|
| 2056 |
+
(Xe.prototype._onMigrate = function (t) {
|
| 2057 |
+
if (t.item === this._item) {
|
| 2058 |
+
var e = this._item.getGrid(),
|
| 2059 |
+
i = t.toGrid
|
| 2060 |
+
e.off(m, this._onReleaseEnd),
|
| 2061 |
+
e.off(r, this._onLayoutStart),
|
| 2062 |
+
e.off(_, this._onMigrate),
|
| 2063 |
+
e.off(h, this._onHide),
|
| 2064 |
+
i.on(m, this._onReleaseEnd),
|
| 2065 |
+
i.on(r, this._onLayoutStart),
|
| 2066 |
+
i.on(_, this._onMigrate),
|
| 2067 |
+
i.on(h, this._onHide),
|
| 2068 |
+
(this._didMigrate = !0)
|
| 2069 |
+
}
|
| 2070 |
+
}),
|
| 2071 |
+
(Xe.prototype._onHide = function (t) {
|
| 2072 |
+
t.indexOf(this._item) > -1 && this.reset()
|
| 2073 |
+
}),
|
| 2074 |
+
(Xe.prototype.create = function () {
|
| 2075 |
+
if (this.isActive()) this._resetAfterLayout = !1
|
| 2076 |
+
else {
|
| 2077 |
+
var t,
|
| 2078 |
+
e = this._item,
|
| 2079 |
+
i = e.getGrid(),
|
| 2080 |
+
n = i._settings,
|
| 2081 |
+
s = this._animation
|
| 2082 |
+
;(this._left = e._left),
|
| 2083 |
+
(this._top = e._top),
|
| 2084 |
+
(t = dt(n.dragPlaceholder.createElement)
|
| 2085 |
+
? n.dragPlaceholder.createElement(e)
|
| 2086 |
+
: document.createElement('div')),
|
| 2087 |
+
(this._element = t),
|
| 2088 |
+
(s._element = t),
|
| 2089 |
+
(this._className = n.itemPlaceholderClass || ''),
|
| 2090 |
+
this._className && Bt(t, this._className),
|
| 2091 |
+
Re(t, {
|
| 2092 |
+
position: 'absolute',
|
| 2093 |
+
left: '0px',
|
| 2094 |
+
top: '0px',
|
| 2095 |
+
width: e._width + 'px',
|
| 2096 |
+
height: e._height + 'px',
|
| 2097 |
+
}),
|
| 2098 |
+
(t.style[Qt] = Oe(e._left + e._marginLeft, e._top + e._marginTop)),
|
| 2099 |
+
i.on(r, this._onLayoutStart),
|
| 2100 |
+
i.on(m, this._onReleaseEnd),
|
| 2101 |
+
i.on(_, this._onMigrate),
|
| 2102 |
+
i.on(h, this._onHide),
|
| 2103 |
+
dt(n.dragPlaceholder.onCreate) && n.dragPlaceholder.onCreate(e, t),
|
| 2104 |
+
i.getElement().appendChild(t)
|
| 2105 |
+
}
|
| 2106 |
+
}),
|
| 2107 |
+
(Xe.prototype.reset = function () {
|
| 2108 |
+
if (this.isActive()) {
|
| 2109 |
+
var t,
|
| 2110 |
+
e = this._element,
|
| 2111 |
+
i = this._item,
|
| 2112 |
+
n = i.getGrid(),
|
| 2113 |
+
s = n._settings,
|
| 2114 |
+
o = this._animation
|
| 2115 |
+
;(this._resetAfterLayout = !1),
|
| 2116 |
+
lt(i._id),
|
| 2117 |
+
(t = i._id),
|
| 2118 |
+
it.remove(2, Z + t),
|
| 2119 |
+
o.stop(),
|
| 2120 |
+
(o._element = null),
|
| 2121 |
+
n.off(m, this._onReleaseEnd),
|
| 2122 |
+
n.off(r, this._onLayoutStart),
|
| 2123 |
+
n.off(_, this._onMigrate),
|
| 2124 |
+
n.off(h, this._onHide),
|
| 2125 |
+
this._className && (ge(e, this._className), (this._className = '')),
|
| 2126 |
+
e.parentNode.removeChild(e),
|
| 2127 |
+
(this._element = null),
|
| 2128 |
+
dt(s.dragPlaceholder.onRemove) && s.dragPlaceholder.onRemove(i, e)
|
| 2129 |
+
}
|
| 2130 |
+
}),
|
| 2131 |
+
(Xe.prototype.isActive = function () {
|
| 2132 |
+
return !!this._element
|
| 2133 |
+
}),
|
| 2134 |
+
(Xe.prototype.getElement = function () {
|
| 2135 |
+
return this._element
|
| 2136 |
+
}),
|
| 2137 |
+
(Xe.prototype.updateDimensions = function () {
|
| 2138 |
+
var t, e
|
| 2139 |
+
this.isActive() && ((t = this._item._id), (e = this._updateDimensions), it.add(2, Z + t, e))
|
| 2140 |
+
}),
|
| 2141 |
+
(Xe.prototype.destroy = function () {
|
| 2142 |
+
this.reset(), this._animation.destroy(), (this._item = this._animation = null)
|
| 2143 |
+
}),
|
| 2144 |
+
(Ye.prototype.start = function () {
|
| 2145 |
+
if (!this._isDestroyed && !this._isActive) {
|
| 2146 |
+
var t = this._item,
|
| 2147 |
+
e = t.getGrid(),
|
| 2148 |
+
i = e._settings
|
| 2149 |
+
;(this._isActive = !0),
|
| 2150 |
+
Bt(t._element, i.itemReleasingClass),
|
| 2151 |
+
i.dragRelease.useDragContainer || this._placeToGrid(),
|
| 2152 |
+
e._emit('dragReleaseStart', t),
|
| 2153 |
+
e._nextLayoutData || t._layout.start(!1)
|
| 2154 |
+
}
|
| 2155 |
+
}),
|
| 2156 |
+
(Ye.prototype.stop = function (t, e, i) {
|
| 2157 |
+
if (!this._isDestroyed && this._isActive) {
|
| 2158 |
+
var n = this._item,
|
| 2159 |
+
r = n.getGrid()
|
| 2160 |
+
t || (void 0 !== e && void 0 !== i) || ((e = n._left), (i = n._top))
|
| 2161 |
+
var s = this._placeToGrid(e, i)
|
| 2162 |
+
this._reset(s), t || r._emit(m, n)
|
| 2163 |
+
}
|
| 2164 |
+
}),
|
| 2165 |
+
(Ye.prototype.isJustReleased = function () {
|
| 2166 |
+
return this._isActive && !1 === this._isPositioningStarted
|
| 2167 |
+
}),
|
| 2168 |
+
(Ye.prototype.destroy = function () {
|
| 2169 |
+
this._isDestroyed || (this.stop(!0), (this._item = null), (this._isDestroyed = !0))
|
| 2170 |
+
}),
|
| 2171 |
+
(Ye.prototype._placeToGrid = function (t, e) {
|
| 2172 |
+
if (!this._isDestroyed) {
|
| 2173 |
+
var i = this._item,
|
| 2174 |
+
n = i._element,
|
| 2175 |
+
r = i.getGrid()._element,
|
| 2176 |
+
s = !1
|
| 2177 |
+
if (n.parentNode !== r) {
|
| 2178 |
+
if (void 0 === t || void 0 === e) {
|
| 2179 |
+
var o = me(n)
|
| 2180 |
+
;(t = o.x - this._containerDiffX), (e = o.y - this._containerDiffY)
|
| 2181 |
+
}
|
| 2182 |
+
r.appendChild(n), i._setTranslate(t, e), (s = !0)
|
| 2183 |
+
}
|
| 2184 |
+
return (this._containerDiffX = 0), (this._containerDiffY = 0), s
|
| 2185 |
+
}
|
| 2186 |
+
}),
|
| 2187 |
+
(Ye.prototype._reset = function (t) {
|
| 2188 |
+
if (!this._isDestroyed) {
|
| 2189 |
+
var e = this._item,
|
| 2190 |
+
i = e.getGrid()._settings.itemReleasingClass
|
| 2191 |
+
;(this._isActive = !1),
|
| 2192 |
+
(this._isPositioningStarted = !1),
|
| 2193 |
+
(this._containerDiffX = 0),
|
| 2194 |
+
(this._containerDiffY = 0),
|
| 2195 |
+
i && ge(e._element, i)
|
| 2196 |
+
}
|
| 2197 |
+
})
|
| 2198 |
+
function qe(t) {
|
| 2199 |
+
var e = t._element,
|
| 2200 |
+
i = e.style
|
| 2201 |
+
;(this._item = t),
|
| 2202 |
+
(this._isActive = !1),
|
| 2203 |
+
(this._isDestroyed = !1),
|
| 2204 |
+
(this._isInterrupted = !1),
|
| 2205 |
+
(this._currentStyles = {}),
|
| 2206 |
+
(this._targetStyles = {}),
|
| 2207 |
+
(this._nextLeft = 0),
|
| 2208 |
+
(this._nextTop = 0),
|
| 2209 |
+
(this._offsetLeft = 0),
|
| 2210 |
+
(this._offsetTop = 0),
|
| 2211 |
+
(this._skipNextAnimation = !1),
|
| 2212 |
+
(this._animOptions = { onFinish: this._finish.bind(this), duration: 0, easing: 0 }),
|
| 2213 |
+
(i.left = '0px'),
|
| 2214 |
+
(i.top = '0px'),
|
| 2215 |
+
t._setTranslate(0, 0),
|
| 2216 |
+
(this._animation = new Ce(e)),
|
| 2217 |
+
(this._queue = 'layout-' + t._id),
|
| 2218 |
+
(this._setupAnimation = this._setupAnimation.bind(this)),
|
| 2219 |
+
(this._startAnimation = this._startAnimation.bind(this))
|
| 2220 |
+
}
|
| 2221 |
+
function He(t) {
|
| 2222 |
+
;(this._item = t),
|
| 2223 |
+
(this._isActive = !1),
|
| 2224 |
+
(this._isDestroyed = !1),
|
| 2225 |
+
(this._container = !1),
|
| 2226 |
+
(this._containerDiffX = 0),
|
| 2227 |
+
(this._containerDiffY = 0)
|
| 2228 |
+
}
|
| 2229 |
+
function Fe(t) {
|
| 2230 |
+
var e = t._isActive,
|
| 2231 |
+
i = t._element,
|
| 2232 |
+
n = i.children[0],
|
| 2233 |
+
r = t.getGrid()._settings
|
| 2234 |
+
if (!n) throw new Error('No valid child element found within item element.')
|
| 2235 |
+
;(this._item = t),
|
| 2236 |
+
(this._isDestroyed = !1),
|
| 2237 |
+
(this._isHidden = !e),
|
| 2238 |
+
(this._isHiding = !1),
|
| 2239 |
+
(this._isShowing = !1),
|
| 2240 |
+
(this._childElement = n),
|
| 2241 |
+
(this._currentStyleProps = []),
|
| 2242 |
+
(this._animation = new Ce(n)),
|
| 2243 |
+
(this._queue = 'visibility-' + t._id),
|
| 2244 |
+
(this._finishShow = this._finishShow.bind(this)),
|
| 2245 |
+
(this._finishHide = this._finishHide.bind(this)),
|
| 2246 |
+
(i.style.display = e ? '' : 'none'),
|
| 2247 |
+
Bt(i, e ? r.itemVisibleClass : r.itemHiddenClass),
|
| 2248 |
+
this.setStyles(e ? r.visibleStyles : r.hiddenStyles)
|
| 2249 |
+
}
|
| 2250 |
+
;(qe.prototype.start = function (t, e) {
|
| 2251 |
+
if (!this._isDestroyed) {
|
| 2252 |
+
var i,
|
| 2253 |
+
n,
|
| 2254 |
+
r,
|
| 2255 |
+
s = this._item,
|
| 2256 |
+
o = s._dragRelease,
|
| 2257 |
+
a = s.getGrid()._settings,
|
| 2258 |
+
h = this._isActive,
|
| 2259 |
+
l = o.isJustReleased(),
|
| 2260 |
+
u = l ? a.dragRelease.duration : a.layoutDuration,
|
| 2261 |
+
d = l ? a.dragRelease.easing : a.layoutEasing,
|
| 2262 |
+
c = !t && !this._skipNextAnimation && u > 0
|
| 2263 |
+
if (
|
| 2264 |
+
(h && (nt(s._id), s._emitter.burst(this._queue, !0, s)),
|
| 2265 |
+
l && (o._isPositioningStarted = !0),
|
| 2266 |
+
dt(e) && s._emitter.on(this._queue, e),
|
| 2267 |
+
(this._skipNextAnimation = !1),
|
| 2268 |
+
!c)
|
| 2269 |
+
)
|
| 2270 |
+
return (
|
| 2271 |
+
this._updateOffsets(),
|
| 2272 |
+
s._setTranslate(this._nextLeft, this._nextTop),
|
| 2273 |
+
this._animation.stop(),
|
| 2274 |
+
void this._finish()
|
| 2275 |
+
)
|
| 2276 |
+
this._animation.isAnimating() && (this._animation._animation.onfinish = null),
|
| 2277 |
+
(this._isActive = !0),
|
| 2278 |
+
(this._animOptions.easing = d),
|
| 2279 |
+
(this._animOptions.duration = u),
|
| 2280 |
+
(this._isInterrupted = h),
|
| 2281 |
+
(i = s._id),
|
| 2282 |
+
(n = this._setupAnimation),
|
| 2283 |
+
(r = this._startAnimation),
|
| 2284 |
+
it.add(0, q + i, n),
|
| 2285 |
+
it.add(2, H + i, r)
|
| 2286 |
+
}
|
| 2287 |
+
}),
|
| 2288 |
+
(qe.prototype.stop = function (t, e, i) {
|
| 2289 |
+
if (!this._isDestroyed && this._isActive) {
|
| 2290 |
+
var n = this._item
|
| 2291 |
+
if ((nt(n._id), this._animation.isAnimating())) {
|
| 2292 |
+
if (void 0 === e || void 0 === i) {
|
| 2293 |
+
var r = me(n._element)
|
| 2294 |
+
;(e = r.x), (i = r.y)
|
| 2295 |
+
}
|
| 2296 |
+
n._setTranslate(e, i), this._animation.stop()
|
| 2297 |
+
}
|
| 2298 |
+
ge(n._element, n.getGrid()._settings.itemPositioningClass),
|
| 2299 |
+
(this._isActive = !1),
|
| 2300 |
+
t && n._emitter.burst(this._queue, !0, n)
|
| 2301 |
+
}
|
| 2302 |
+
}),
|
| 2303 |
+
(qe.prototype.destroy = function () {
|
| 2304 |
+
if (!this._isDestroyed) {
|
| 2305 |
+
var t = this._item._element.style
|
| 2306 |
+
this.stop(!0, 0, 0),
|
| 2307 |
+
this._item._emitter.clear(this._queue),
|
| 2308 |
+
this._animation.destroy(),
|
| 2309 |
+
(t[Qt] = ''),
|
| 2310 |
+
(t.left = ''),
|
| 2311 |
+
(t.top = ''),
|
| 2312 |
+
(this._item = null),
|
| 2313 |
+
(this._currentStyles = null),
|
| 2314 |
+
(this._targetStyles = null),
|
| 2315 |
+
(this._animOptions = null),
|
| 2316 |
+
(this._isDestroyed = !0)
|
| 2317 |
+
}
|
| 2318 |
+
}),
|
| 2319 |
+
(qe.prototype._updateOffsets = function () {
|
| 2320 |
+
if (!this._isDestroyed) {
|
| 2321 |
+
var t = this._item,
|
| 2322 |
+
e = t._migrate,
|
| 2323 |
+
i = t._dragRelease
|
| 2324 |
+
;(this._offsetLeft = i._isActive ? i._containerDiffX : e._isActive ? e._containerDiffX : 0),
|
| 2325 |
+
(this._offsetTop = i._isActive ? i._containerDiffY : e._isActive ? e._containerDiffY : 0),
|
| 2326 |
+
(this._nextLeft = this._item._left + this._offsetLeft),
|
| 2327 |
+
(this._nextTop = this._item._top + this._offsetTop)
|
| 2328 |
+
}
|
| 2329 |
+
}),
|
| 2330 |
+
(qe.prototype._finish = function () {
|
| 2331 |
+
if (!this._isDestroyed) {
|
| 2332 |
+
var t = this._item,
|
| 2333 |
+
e = t._migrate,
|
| 2334 |
+
i = t._dragRelease
|
| 2335 |
+
;(t._tX = this._nextLeft),
|
| 2336 |
+
(t._tY = this._nextTop),
|
| 2337 |
+
this._isActive &&
|
| 2338 |
+
((this._isActive = !1), ge(t._element, t.getGrid()._settings.itemPositioningClass)),
|
| 2339 |
+
i._isActive && i.stop(),
|
| 2340 |
+
e._isActive && e.stop(),
|
| 2341 |
+
t._emitter.burst(this._queue, !1, t)
|
| 2342 |
+
}
|
| 2343 |
+
}),
|
| 2344 |
+
(qe.prototype._setupAnimation = function () {
|
| 2345 |
+
var t = this._item
|
| 2346 |
+
if (void 0 === t._tX || void 0 === t._tY) {
|
| 2347 |
+
var e = me(t._element)
|
| 2348 |
+
;(t._tX = e.x), (t._tY = e.y)
|
| 2349 |
+
}
|
| 2350 |
+
}),
|
| 2351 |
+
(qe.prototype._startAnimation = function () {
|
| 2352 |
+
var t = this._item,
|
| 2353 |
+
e = t.getGrid()._settings,
|
| 2354 |
+
i = this._animOptions.duration <= 0
|
| 2355 |
+
this._updateOffsets()
|
| 2356 |
+
var n = Math.abs(t._left - (t._tX - this._offsetLeft)),
|
| 2357 |
+
r = Math.abs(t._top - (t._tY - this._offsetTop))
|
| 2358 |
+
if (i || (n < 2 && r < 2))
|
| 2359 |
+
return (
|
| 2360 |
+
(n || r || this._isInterrupted) && t._setTranslate(this._nextLeft, this._nextTop),
|
| 2361 |
+
this._animation.stop(),
|
| 2362 |
+
void this._finish()
|
| 2363 |
+
)
|
| 2364 |
+
this._isInterrupted || Bt(t._element, e.itemPositioningClass),
|
| 2365 |
+
(this._currentStyles[Qt] = Oe(t._tX, t._tY)),
|
| 2366 |
+
(this._targetStyles[Qt] = Oe(this._nextLeft, this._nextTop)),
|
| 2367 |
+
(t._tX = t._tY = void 0),
|
| 2368 |
+
this._animation.start(this._currentStyles, this._targetStyles, this._animOptions)
|
| 2369 |
+
}),
|
| 2370 |
+
(He.prototype.start = function (t, e, i) {
|
| 2371 |
+
if (!this._isDestroyed) {
|
| 2372 |
+
var n,
|
| 2373 |
+
r,
|
| 2374 |
+
s,
|
| 2375 |
+
o,
|
| 2376 |
+
a,
|
| 2377 |
+
h,
|
| 2378 |
+
l,
|
| 2379 |
+
u,
|
| 2380 |
+
d,
|
| 2381 |
+
m,
|
| 2382 |
+
g = this._item,
|
| 2383 |
+
v = g._element,
|
| 2384 |
+
y = g.isActive(),
|
| 2385 |
+
b = g.isVisible(),
|
| 2386 |
+
w = g.getGrid(),
|
| 2387 |
+
S = w._settings,
|
| 2388 |
+
T = t._settings,
|
| 2389 |
+
D = t._element,
|
| 2390 |
+
x = t._items,
|
| 2391 |
+
A = w._items.indexOf(g),
|
| 2392 |
+
k = i || document.body
|
| 2393 |
+
if ('number' == typeof e) n = Vt(x, e, 1)
|
| 2394 |
+
else {
|
| 2395 |
+
if (!(r = t.getItem(e))) return
|
| 2396 |
+
n = x.indexOf(r)
|
| 2397 |
+
}
|
| 2398 |
+
;(g.isPositioning() || this._isActive || g.isReleasing()) && ((l = (h = me(v)).x), (u = h.y)),
|
| 2399 |
+
g.isPositioning() && g._layout.stop(!0, l, u),
|
| 2400 |
+
this._isActive && ((l -= this._containerDiffX), (u -= this._containerDiffY), this.stop(!0, l, u)),
|
| 2401 |
+
g.isReleasing() &&
|
| 2402 |
+
((l -= g._dragRelease._containerDiffX),
|
| 2403 |
+
(u -= g._dragRelease._containerDiffY),
|
| 2404 |
+
g._dragRelease.stop(!0, l, u)),
|
| 2405 |
+
g._visibility.stop(!0),
|
| 2406 |
+
g._drag && g._drag.destroy(),
|
| 2407 |
+
w._hasListeners(_) && w._emit(_, { item: g, fromGrid: w, fromIndex: A, toGrid: t, toIndex: n }),
|
| 2408 |
+
t._hasListeners(p) && t._emit(p, { item: g, fromGrid: w, fromIndex: A, toGrid: t, toIndex: n }),
|
| 2409 |
+
S.itemClass !== T.itemClass && (ge(v, S.itemClass), Bt(v, T.itemClass)),
|
| 2410 |
+
(d = b ? S.itemVisibleClass : S.itemHiddenClass) !==
|
| 2411 |
+
(m = b ? T.itemVisibleClass : T.itemHiddenClass) && (ge(v, d), Bt(v, m)),
|
| 2412 |
+
w._items.splice(A, 1),
|
| 2413 |
+
zt(x, g, n),
|
| 2414 |
+
(g._gridId = t._id),
|
| 2415 |
+
y
|
| 2416 |
+
? k !== (s = v.parentNode) &&
|
| 2417 |
+
(k.appendChild(v),
|
| 2418 |
+
(o = ae(k, s, !0)),
|
| 2419 |
+
h || ((l = (h = me(v)).x), (u = h.y)),
|
| 2420 |
+
g._setTranslate(l + o.left, u + o.top))
|
| 2421 |
+
: D.appendChild(v),
|
| 2422 |
+
g._visibility.setStyles(b ? T.visibleStyles : T.hiddenStyles),
|
| 2423 |
+
y && (a = ae(k, D, !0)),
|
| 2424 |
+
g._refreshDimensions(),
|
| 2425 |
+
(g._sortData = null),
|
| 2426 |
+
(g._drag = T.dragEnabled ? new De(g) : null),
|
| 2427 |
+
y
|
| 2428 |
+
? ((this._isActive = !0),
|
| 2429 |
+
(this._container = k),
|
| 2430 |
+
(this._containerDiffX = a.left),
|
| 2431 |
+
(this._containerDiffY = a.top))
|
| 2432 |
+
: ((this._isActive = !1),
|
| 2433 |
+
(this._container = null),
|
| 2434 |
+
(this._containerDiffX = 0),
|
| 2435 |
+
(this._containerDiffY = 0)),
|
| 2436 |
+
w._hasListeners(c) && w._emit(c, { item: g, fromGrid: w, fromIndex: A, toGrid: t, toIndex: n }),
|
| 2437 |
+
t._hasListeners(f) && t._emit(f, { item: g, fromGrid: w, fromIndex: A, toGrid: t, toIndex: n })
|
| 2438 |
+
}
|
| 2439 |
+
}),
|
| 2440 |
+
(He.prototype.stop = function (t, e, i) {
|
| 2441 |
+
if (!this._isDestroyed && this._isActive) {
|
| 2442 |
+
var n,
|
| 2443 |
+
r = this._item,
|
| 2444 |
+
s = r._element,
|
| 2445 |
+
o = r.getGrid()._element
|
| 2446 |
+
this._container !== o &&
|
| 2447 |
+
((void 0 !== e && void 0 !== i) ||
|
| 2448 |
+
(t
|
| 2449 |
+
? ((e = (n = me(s)).x - this._containerDiffX), (i = n.y - this._containerDiffY))
|
| 2450 |
+
: ((e = r._left), (i = r._top))),
|
| 2451 |
+
o.appendChild(s),
|
| 2452 |
+
r._setTranslate(e, i)),
|
| 2453 |
+
(this._isActive = !1),
|
| 2454 |
+
(this._container = null),
|
| 2455 |
+
(this._containerDiffX = 0),
|
| 2456 |
+
(this._containerDiffY = 0)
|
| 2457 |
+
}
|
| 2458 |
+
}),
|
| 2459 |
+
(He.prototype.destroy = function () {
|
| 2460 |
+
this._isDestroyed || (this.stop(!0), (this._item = null), (this._isDestroyed = !0))
|
| 2461 |
+
}),
|
| 2462 |
+
(Fe.prototype.show = function (t, e) {
|
| 2463 |
+
if (!this._isDestroyed) {
|
| 2464 |
+
var i = this._item,
|
| 2465 |
+
n = i._element,
|
| 2466 |
+
r = dt(e) ? e : null,
|
| 2467 |
+
s = i.getGrid()._settings
|
| 2468 |
+
this._isShowing || this._isHidden
|
| 2469 |
+
? !this._isShowing || t
|
| 2470 |
+
? (this._isShowing ||
|
| 2471 |
+
(i._emitter.burst(this._queue, !0, i),
|
| 2472 |
+
ge(n, s.itemHiddenClass),
|
| 2473 |
+
Bt(n, s.itemVisibleClass),
|
| 2474 |
+
this._isHiding || (n.style.display = '')),
|
| 2475 |
+
r && i._emitter.on(this._queue, r),
|
| 2476 |
+
(this._isShowing = !0),
|
| 2477 |
+
(this._isHiding = this._isHidden = !1),
|
| 2478 |
+
this._startAnimation(!0, t, this._finishShow))
|
| 2479 |
+
: r && i._emitter.on(this._queue, r)
|
| 2480 |
+
: r && r(!1, i)
|
| 2481 |
+
}
|
| 2482 |
+
}),
|
| 2483 |
+
(Fe.prototype.hide = function (t, e) {
|
| 2484 |
+
if (!this._isDestroyed) {
|
| 2485 |
+
var i = this._item,
|
| 2486 |
+
n = i._element,
|
| 2487 |
+
r = dt(e) ? e : null,
|
| 2488 |
+
s = i.getGrid()._settings
|
| 2489 |
+
this._isHiding || !this._isHidden
|
| 2490 |
+
? !this._isHiding || t
|
| 2491 |
+
? (this._isHiding ||
|
| 2492 |
+
(i._emitter.burst(this._queue, !0, i),
|
| 2493 |
+
Bt(n, s.itemHiddenClass),
|
| 2494 |
+
ge(n, s.itemVisibleClass)),
|
| 2495 |
+
r && i._emitter.on(this._queue, r),
|
| 2496 |
+
(this._isHidden = this._isHiding = !0),
|
| 2497 |
+
(this._isShowing = !1),
|
| 2498 |
+
this._startAnimation(!1, t, this._finishHide))
|
| 2499 |
+
: r && i._emitter.on(this._queue, r)
|
| 2500 |
+
: r && r(!1, i)
|
| 2501 |
+
}
|
| 2502 |
+
}),
|
| 2503 |
+
(Fe.prototype.stop = function (t) {
|
| 2504 |
+
if (!this._isDestroyed && (this._isHiding || this._isShowing)) {
|
| 2505 |
+
var e = this._item
|
| 2506 |
+
rt(e._id), this._animation.stop(), t && e._emitter.burst(this._queue, !0, e)
|
| 2507 |
+
}
|
| 2508 |
+
}),
|
| 2509 |
+
(Fe.prototype.setStyles = function (t) {
|
| 2510 |
+
var e = this._childElement,
|
| 2511 |
+
i = this._currentStyleProps
|
| 2512 |
+
for (var n in (this._removeCurrentStyles(), t)) i.push(n), (e.style[n] = t[n])
|
| 2513 |
+
}),
|
| 2514 |
+
(Fe.prototype.destroy = function () {
|
| 2515 |
+
if (!this._isDestroyed) {
|
| 2516 |
+
var t = this._item,
|
| 2517 |
+
e = t._element,
|
| 2518 |
+
i = t.getGrid()._settings
|
| 2519 |
+
this.stop(!0),
|
| 2520 |
+
t._emitter.clear(this._queue),
|
| 2521 |
+
this._animation.destroy(),
|
| 2522 |
+
this._removeCurrentStyles(),
|
| 2523 |
+
ge(e, i.itemVisibleClass),
|
| 2524 |
+
ge(e, i.itemHiddenClass),
|
| 2525 |
+
(e.style.display = ''),
|
| 2526 |
+
(this._isHiding = this._isShowing = !1),
|
| 2527 |
+
(this._isDestroyed = this._isHidden = !0)
|
| 2528 |
+
}
|
| 2529 |
+
}),
|
| 2530 |
+
(Fe.prototype._startAnimation = function (t, e, i) {
|
| 2531 |
+
if (!this._isDestroyed) {
|
| 2532 |
+
var n,
|
| 2533 |
+
r = this._item,
|
| 2534 |
+
s = this._animation,
|
| 2535 |
+
o = this._childElement,
|
| 2536 |
+
a = r.getGrid()._settings,
|
| 2537 |
+
h = t ? a.visibleStyles : a.hiddenStyles,
|
| 2538 |
+
l = t ? a.showDuration : a.hideDuration,
|
| 2539 |
+
u = t ? a.showEasing : a.hideEasing,
|
| 2540 |
+
d = e || l <= 0
|
| 2541 |
+
if (h) {
|
| 2542 |
+
if ((rt(r._id), d)) return Re(o, h), s.stop(), void (i && i())
|
| 2543 |
+
var c, _, f
|
| 2544 |
+
s.isAnimating() && (s._animation.onfinish = null),
|
| 2545 |
+
(c = r._id),
|
| 2546 |
+
(_ = function () {
|
| 2547 |
+
n = xe(o, h)
|
| 2548 |
+
}),
|
| 2549 |
+
(f = function () {
|
| 2550 |
+
s.start(n, h, { duration: l, easing: u, onFinish: i })
|
| 2551 |
+
}),
|
| 2552 |
+
it.add(0, F + c, _),
|
| 2553 |
+
it.add(2, W + c, f)
|
| 2554 |
+
} else i && i()
|
| 2555 |
+
}
|
| 2556 |
+
}),
|
| 2557 |
+
(Fe.prototype._finishShow = function () {
|
| 2558 |
+
this._isHidden || ((this._isShowing = !1), this._item._emitter.burst(this._queue, !1, this._item))
|
| 2559 |
+
}),
|
| 2560 |
+
(Fe.prototype._finishHide = function () {
|
| 2561 |
+
if (this._isHidden) {
|
| 2562 |
+
var t = this._item
|
| 2563 |
+
;(this._isHiding = !1),
|
| 2564 |
+
t._layout.stop(!0, 0, 0),
|
| 2565 |
+
(t._element.style.display = 'none'),
|
| 2566 |
+
t._emitter.burst(this._queue, !1, t)
|
| 2567 |
+
}
|
| 2568 |
+
}),
|
| 2569 |
+
(Fe.prototype._removeCurrentStyles = function () {
|
| 2570 |
+
for (var t = this._childElement, e = this._currentStyleProps, i = 0; i < e.length; i++) t.style[e[i]] = ''
|
| 2571 |
+
e.length = 0
|
| 2572 |
+
})
|
| 2573 |
+
var We = 0
|
| 2574 |
+
function Be() {
|
| 2575 |
+
return ++We
|
| 2576 |
+
}
|
| 2577 |
+
function Ge(t, i, n) {
|
| 2578 |
+
var r = t._settings
|
| 2579 |
+
if (e) {
|
| 2580 |
+
if (e.has(i)) throw new Error('You can only create one Muuri Item per element!')
|
| 2581 |
+
e.set(i, this)
|
| 2582 |
+
}
|
| 2583 |
+
;(this._id = Be()),
|
| 2584 |
+
(this._gridId = t._id),
|
| 2585 |
+
(this._element = i),
|
| 2586 |
+
(this._isDestroyed = !1),
|
| 2587 |
+
(this._left = 0),
|
| 2588 |
+
(this._top = 0),
|
| 2589 |
+
(this._width = 0),
|
| 2590 |
+
(this._height = 0),
|
| 2591 |
+
(this._marginLeft = 0),
|
| 2592 |
+
(this._marginRight = 0),
|
| 2593 |
+
(this._marginTop = 0),
|
| 2594 |
+
(this._marginBottom = 0),
|
| 2595 |
+
(this._tX = void 0),
|
| 2596 |
+
(this._tY = void 0),
|
| 2597 |
+
(this._sortData = null),
|
| 2598 |
+
(this._emitter = new b()),
|
| 2599 |
+
i.parentNode !== t._element && t._element.appendChild(i),
|
| 2600 |
+
Bt(i, r.itemClass),
|
| 2601 |
+
'boolean' != typeof n && (n = 'none' !== gt(i, 'display')),
|
| 2602 |
+
(this._isActive = n),
|
| 2603 |
+
(this._visibility = new Fe(this)),
|
| 2604 |
+
(this._layout = new qe(this)),
|
| 2605 |
+
(this._migrate = new He(this)),
|
| 2606 |
+
(this._drag = r.dragEnabled ? new De(this) : null),
|
| 2607 |
+
(this._dragRelease = new Ye(this)),
|
| 2608 |
+
(this._dragPlaceholder = new Xe(this))
|
| 2609 |
+
}
|
| 2610 |
+
function ze(t) {
|
| 2611 |
+
var e,
|
| 2612 |
+
i,
|
| 2613 |
+
n,
|
| 2614 |
+
r,
|
| 2615 |
+
s,
|
| 2616 |
+
o = 0.001,
|
| 2617 |
+
a = 0.5
|
| 2618 |
+
function h(t) {
|
| 2619 |
+
return ((((1e3 * t + 0.5) << 0) / 10) << 0) / 100
|
| 2620 |
+
}
|
| 2621 |
+
function l() {
|
| 2622 |
+
;(this.currentRects = []),
|
| 2623 |
+
(this.nextRects = []),
|
| 2624 |
+
(this.rectTarget = {}),
|
| 2625 |
+
(this.rectStore = []),
|
| 2626 |
+
(this.slotSizes = []),
|
| 2627 |
+
(this.rectId = 0),
|
| 2628 |
+
(this.slotIndex = -1),
|
| 2629 |
+
(this.slotData = { left: 0, top: 0, width: 0, height: 0 }),
|
| 2630 |
+
(this.sortRectsLeftTop = this.sortRectsLeftTop.bind(this)),
|
| 2631 |
+
(this.sortRectsTopLeft = this.sortRectsTopLeft.bind(this))
|
| 2632 |
+
}
|
| 2633 |
+
if (
|
| 2634 |
+
((l.prototype.computeLayout = function (t, e) {
|
| 2635 |
+
var i,
|
| 2636 |
+
n,
|
| 2637 |
+
r,
|
| 2638 |
+
s,
|
| 2639 |
+
o,
|
| 2640 |
+
a,
|
| 2641 |
+
l = t.items,
|
| 2642 |
+
u = t.slots,
|
| 2643 |
+
d = !!(1 & e),
|
| 2644 |
+
c = !!(2 & e),
|
| 2645 |
+
_ = !!(4 & e),
|
| 2646 |
+
f = !!(8 & e),
|
| 2647 |
+
p = !!(16 & e),
|
| 2648 |
+
m = 'number' == typeof l[0]
|
| 2649 |
+
if (!l.length) return t
|
| 2650 |
+
for (n = m ? 2 : 1, i = 0; i < l.length; i += n)
|
| 2651 |
+
m
|
| 2652 |
+
? ((s = l[i]), (o = l[i + 1]))
|
| 2653 |
+
: ((s = (r = l[i])._width + r._marginLeft + r._marginRight),
|
| 2654 |
+
(o = r._height + r._marginTop + r._marginBottom)),
|
| 2655 |
+
p && ((s = h(s)), (o = h(o))),
|
| 2656 |
+
(a = this.computeNextSlot(t, s, o, d, c)),
|
| 2657 |
+
c
|
| 2658 |
+
? a.left + a.width > t.width && (t.width = a.left + a.width)
|
| 2659 |
+
: a.top + a.height > t.height && (t.height = a.top + a.height),
|
| 2660 |
+
(u[++this.slotIndex] = a.left),
|
| 2661 |
+
(u[++this.slotIndex] = a.top),
|
| 2662 |
+
(_ || f) && this.slotSizes.push(a.width, a.height)
|
| 2663 |
+
if (_) for (i = 0; i < u.length; i += 2) u[i] = t.width - (u[i] + this.slotSizes[i])
|
| 2664 |
+
if (f) for (i = 1; i < u.length; i += 2) u[i] = t.height - (u[i] + this.slotSizes[i])
|
| 2665 |
+
return (
|
| 2666 |
+
(this.slotSizes.length = 0),
|
| 2667 |
+
(this.currentRects.length = 0),
|
| 2668 |
+
(this.nextRects.length = 0),
|
| 2669 |
+
(this.rectId = 0),
|
| 2670 |
+
(this.slotIndex = -1),
|
| 2671 |
+
t
|
| 2672 |
+
)
|
| 2673 |
+
}),
|
| 2674 |
+
(l.prototype.computeNextSlot = function (t, e, i, n, r) {
|
| 2675 |
+
var s,
|
| 2676 |
+
h,
|
| 2677 |
+
l,
|
| 2678 |
+
u,
|
| 2679 |
+
d,
|
| 2680 |
+
c = this.slotData,
|
| 2681 |
+
_ = this.currentRects,
|
| 2682 |
+
f = this.nextRects,
|
| 2683 |
+
p = !1
|
| 2684 |
+
for (f.length = 0, c.left = null, c.top = null, c.width = e, c.height = i, u = 0; u < _.length; u++)
|
| 2685 |
+
if ((h = _[u]) && ((s = this.getRect(h)), c.width <= s.width + o && c.height <= s.height + o)) {
|
| 2686 |
+
;(c.left = s.left), (c.top = s.top)
|
| 2687 |
+
break
|
| 2688 |
+
}
|
| 2689 |
+
if (
|
| 2690 |
+
(null === c.left &&
|
| 2691 |
+
(r ? ((c.left = t.width), (c.top = 0)) : ((c.left = 0), (c.top = t.height)), n || (p = !0)),
|
| 2692 |
+
!r &&
|
| 2693 |
+
c.top + c.height > t.height + o &&
|
| 2694 |
+
(c.left > a && f.push(this.addRect(0, t.height, c.left, 1 / 0)),
|
| 2695 |
+
c.left + c.width < t.width - a &&
|
| 2696 |
+
f.push(this.addRect(c.left + c.width, t.height, t.width - c.left - c.width, 1 / 0)),
|
| 2697 |
+
(t.height = c.top + c.height)),
|
| 2698 |
+
r &&
|
| 2699 |
+
c.left + c.width > t.width + o &&
|
| 2700 |
+
(c.top > a && f.push(this.addRect(t.width, 0, 1 / 0, c.top)),
|
| 2701 |
+
c.top + c.height < t.height - a &&
|
| 2702 |
+
f.push(this.addRect(t.width, c.top + c.height, 1 / 0, t.height - c.top - c.height)),
|
| 2703 |
+
(t.width = c.left + c.width)),
|
| 2704 |
+
!p)
|
| 2705 |
+
)
|
| 2706 |
+
for (n && (u = 0); u < _.length; u++)
|
| 2707 |
+
if ((h = _[u]))
|
| 2708 |
+
for (s = this.getRect(h), l = this.splitRect(s, c), d = 0; d < l.length; d++)
|
| 2709 |
+
(h = l[d]),
|
| 2710 |
+
(s = this.getRect(h)),
|
| 2711 |
+
(r ? s.left + o < t.width - o : s.top + o < t.height - o) && f.push(h)
|
| 2712 |
+
return (
|
| 2713 |
+
f.length > 1 && this.purgeRects(f).sort(r ? this.sortRectsLeftTop : this.sortRectsTopLeft),
|
| 2714 |
+
(this.currentRects = f),
|
| 2715 |
+
(this.nextRects = _),
|
| 2716 |
+
c
|
| 2717 |
+
)
|
| 2718 |
+
}),
|
| 2719 |
+
(l.prototype.addRect = function (t, e, i, n) {
|
| 2720 |
+
var r = ++this.rectId
|
| 2721 |
+
return (
|
| 2722 |
+
(this.rectStore[r] = t || 0),
|
| 2723 |
+
(this.rectStore[++this.rectId] = e || 0),
|
| 2724 |
+
(this.rectStore[++this.rectId] = i || 0),
|
| 2725 |
+
(this.rectStore[++this.rectId] = n || 0),
|
| 2726 |
+
r
|
| 2727 |
+
)
|
| 2728 |
+
}),
|
| 2729 |
+
(l.prototype.getRect = function (t, e) {
|
| 2730 |
+
return (
|
| 2731 |
+
e || (e = this.rectTarget),
|
| 2732 |
+
(e.left = this.rectStore[t] || 0),
|
| 2733 |
+
(e.top = this.rectStore[++t] || 0),
|
| 2734 |
+
(e.width = this.rectStore[++t] || 0),
|
| 2735 |
+
(e.height = this.rectStore[++t] || 0),
|
| 2736 |
+
e
|
| 2737 |
+
)
|
| 2738 |
+
}),
|
| 2739 |
+
(l.prototype.splitRect =
|
| 2740 |
+
((e = []),
|
| 2741 |
+
(i = 0),
|
| 2742 |
+
(n = 0),
|
| 2743 |
+
function (t, r) {
|
| 2744 |
+
return (
|
| 2745 |
+
(e.length = 0),
|
| 2746 |
+
t.left + t.width <= r.left + o ||
|
| 2747 |
+
r.left + r.width <= t.left + o ||
|
| 2748 |
+
t.top + t.height <= r.top + o ||
|
| 2749 |
+
r.top + r.height <= t.top + o
|
| 2750 |
+
? (e.push(this.addRect(t.left, t.top, t.width, t.height)), e)
|
| 2751 |
+
: ((i = r.left - t.left) >= a && e.push(this.addRect(t.left, t.top, i, t.height)),
|
| 2752 |
+
(i = t.left + t.width - (r.left + r.width)) >= a &&
|
| 2753 |
+
e.push(this.addRect(r.left + r.width, t.top, i, t.height)),
|
| 2754 |
+
(n = r.top - t.top) >= a && e.push(this.addRect(t.left, t.top, t.width, n)),
|
| 2755 |
+
(n = t.top + t.height - (r.top + r.height)) >= a &&
|
| 2756 |
+
e.push(this.addRect(t.left, r.top + r.height, t.width, n)),
|
| 2757 |
+
e)
|
| 2758 |
+
)
|
| 2759 |
+
})),
|
| 2760 |
+
(l.prototype.isRectAWithinRectB = function (t, e) {
|
| 2761 |
+
return (
|
| 2762 |
+
t.left + o >= e.left &&
|
| 2763 |
+
t.top + o >= e.top &&
|
| 2764 |
+
t.left + t.width - o <= e.left + e.width &&
|
| 2765 |
+
t.top + t.height - o <= e.top + e.height
|
| 2766 |
+
)
|
| 2767 |
+
}),
|
| 2768 |
+
(l.prototype.purgeRects =
|
| 2769 |
+
((r = {}),
|
| 2770 |
+
(s = {}),
|
| 2771 |
+
function (t) {
|
| 2772 |
+
for (var e, i = t.length; i--; )
|
| 2773 |
+
if (((e = t.length), t[i]))
|
| 2774 |
+
for (this.getRect(t[i], r); e--; )
|
| 2775 |
+
if (t[e] && i !== e && (this.getRect(t[e], s), this.isRectAWithinRectB(r, s))) {
|
| 2776 |
+
t[i] = 0
|
| 2777 |
+
break
|
| 2778 |
+
}
|
| 2779 |
+
return t
|
| 2780 |
+
})),
|
| 2781 |
+
(l.prototype.sortRectsTopLeft = (function () {
|
| 2782 |
+
var t = {},
|
| 2783 |
+
e = {}
|
| 2784 |
+
return function (i, n) {
|
| 2785 |
+
return (
|
| 2786 |
+
this.getRect(i, t),
|
| 2787 |
+
this.getRect(n, e),
|
| 2788 |
+
t.top < e.top && t.top + o < e.top
|
| 2789 |
+
? -1
|
| 2790 |
+
: t.top > e.top && t.top - o > e.top
|
| 2791 |
+
? 1
|
| 2792 |
+
: t.left < e.left && t.left + o < e.left
|
| 2793 |
+
? -1
|
| 2794 |
+
: t.left > e.left && t.left - o > e.left
|
| 2795 |
+
? 1
|
| 2796 |
+
: 0
|
| 2797 |
+
)
|
| 2798 |
+
}
|
| 2799 |
+
})()),
|
| 2800 |
+
(l.prototype.sortRectsLeftTop = (function () {
|
| 2801 |
+
var t = {},
|
| 2802 |
+
e = {}
|
| 2803 |
+
return function (i, n) {
|
| 2804 |
+
return (
|
| 2805 |
+
this.getRect(i, t),
|
| 2806 |
+
this.getRect(n, e),
|
| 2807 |
+
t.left < e.left && t.left + o < e.left
|
| 2808 |
+
? -1
|
| 2809 |
+
: t.left > e.left && t.left - o < e.left
|
| 2810 |
+
? 1
|
| 2811 |
+
: t.top < e.top && t.top + o < e.top
|
| 2812 |
+
? -1
|
| 2813 |
+
: t.top > e.top && t.top - o > e.top
|
| 2814 |
+
? 1
|
| 2815 |
+
: 0
|
| 2816 |
+
)
|
| 2817 |
+
}
|
| 2818 |
+
})()),
|
| 2819 |
+
t)
|
| 2820 |
+
) {
|
| 2821 |
+
var u = new l()
|
| 2822 |
+
self.onmessage = function (t) {
|
| 2823 |
+
var e = new Float32Array(t.data),
|
| 2824 |
+
i = e.subarray(4, e.length),
|
| 2825 |
+
n = new Float32Array(i.length),
|
| 2826 |
+
r = e[3],
|
| 2827 |
+
s = { items: i, slots: n, width: e[1], height: e[2] }
|
| 2828 |
+
u.computeLayout(s, r),
|
| 2829 |
+
(e[1] = s.width),
|
| 2830 |
+
(e[2] = s.height),
|
| 2831 |
+
e.set(s.slots, 4),
|
| 2832 |
+
postMessage(e.buffer, [e.buffer])
|
| 2833 |
+
}
|
| 2834 |
+
}
|
| 2835 |
+
return l
|
| 2836 |
+
}
|
| 2837 |
+
;(Ge.prototype.getGrid = function () {
|
| 2838 |
+
return t[this._gridId]
|
| 2839 |
+
}),
|
| 2840 |
+
(Ge.prototype.getElement = function () {
|
| 2841 |
+
return this._element
|
| 2842 |
+
}),
|
| 2843 |
+
(Ge.prototype.getWidth = function () {
|
| 2844 |
+
return this._width
|
| 2845 |
+
}),
|
| 2846 |
+
(Ge.prototype.getHeight = function () {
|
| 2847 |
+
return this._height
|
| 2848 |
+
}),
|
| 2849 |
+
(Ge.prototype.getMargin = function () {
|
| 2850 |
+
return {
|
| 2851 |
+
left: this._marginLeft,
|
| 2852 |
+
right: this._marginRight,
|
| 2853 |
+
top: this._marginTop,
|
| 2854 |
+
bottom: this._marginBottom,
|
| 2855 |
+
}
|
| 2856 |
+
}),
|
| 2857 |
+
(Ge.prototype.getPosition = function () {
|
| 2858 |
+
return { left: this._left, top: this._top }
|
| 2859 |
+
}),
|
| 2860 |
+
(Ge.prototype.isActive = function () {
|
| 2861 |
+
return this._isActive
|
| 2862 |
+
}),
|
| 2863 |
+
(Ge.prototype.isVisible = function () {
|
| 2864 |
+
return !!this._visibility && !this._visibility._isHidden
|
| 2865 |
+
}),
|
| 2866 |
+
(Ge.prototype.isShowing = function () {
|
| 2867 |
+
return !(!this._visibility || !this._visibility._isShowing)
|
| 2868 |
+
}),
|
| 2869 |
+
(Ge.prototype.isHiding = function () {
|
| 2870 |
+
return !(!this._visibility || !this._visibility._isHiding)
|
| 2871 |
+
}),
|
| 2872 |
+
(Ge.prototype.isPositioning = function () {
|
| 2873 |
+
return !(!this._layout || !this._layout._isActive)
|
| 2874 |
+
}),
|
| 2875 |
+
(Ge.prototype.isDragging = function () {
|
| 2876 |
+
return !(!this._drag || !this._drag._isActive)
|
| 2877 |
+
}),
|
| 2878 |
+
(Ge.prototype.isReleasing = function () {
|
| 2879 |
+
return !(!this._dragRelease || !this._dragRelease._isActive)
|
| 2880 |
+
}),
|
| 2881 |
+
(Ge.prototype.isDestroyed = function () {
|
| 2882 |
+
return this._isDestroyed
|
| 2883 |
+
}),
|
| 2884 |
+
(Ge.prototype._refreshDimensions = function (t) {
|
| 2885 |
+
if (!(this._isDestroyed || (!0 !== t && this._visibility._isHidden))) {
|
| 2886 |
+
var e = this._element,
|
| 2887 |
+
i = this._dragPlaceholder,
|
| 2888 |
+
n = e.getBoundingClientRect()
|
| 2889 |
+
;(this._width = n.width),
|
| 2890 |
+
(this._height = n.height),
|
| 2891 |
+
(this._marginLeft = Math.max(0, vt(e, 'margin-left'))),
|
| 2892 |
+
(this._marginRight = Math.max(0, vt(e, 'margin-right'))),
|
| 2893 |
+
(this._marginTop = Math.max(0, vt(e, 'margin-top'))),
|
| 2894 |
+
(this._marginBottom = Math.max(0, vt(e, 'margin-bottom'))),
|
| 2895 |
+
i && i.updateDimensions()
|
| 2896 |
+
}
|
| 2897 |
+
}),
|
| 2898 |
+
(Ge.prototype._refreshSortData = function () {
|
| 2899 |
+
if (!this._isDestroyed) {
|
| 2900 |
+
var t,
|
| 2901 |
+
e = (this._sortData = {}),
|
| 2902 |
+
i = this.getGrid()._settings.sortData
|
| 2903 |
+
for (t in i) e[t] = i[t](this, this._element)
|
| 2904 |
+
}
|
| 2905 |
+
}),
|
| 2906 |
+
(Ge.prototype._addToLayout = function (t, e) {
|
| 2907 |
+
!0 !== this._isActive && ((this._isActive = !0), (this._left = t || 0), (this._top = e || 0))
|
| 2908 |
+
}),
|
| 2909 |
+
(Ge.prototype._removeFromLayout = function () {
|
| 2910 |
+
!1 !== this._isActive && ((this._isActive = !1), (this._left = 0), (this._top = 0))
|
| 2911 |
+
}),
|
| 2912 |
+
(Ge.prototype._canSkipLayout = function (t, e) {
|
| 2913 |
+
return (
|
| 2914 |
+
this._left === t &&
|
| 2915 |
+
this._top === e &&
|
| 2916 |
+
!this._migrate._isActive &&
|
| 2917 |
+
!this._layout._skipNextAnimation &&
|
| 2918 |
+
!this._dragRelease.isJustReleased()
|
| 2919 |
+
)
|
| 2920 |
+
}),
|
| 2921 |
+
(Ge.prototype._setTranslate = function (t, e) {
|
| 2922 |
+
return (
|
| 2923 |
+
(this._tX !== t || this._tY !== e) &&
|
| 2924 |
+
((this._tX = t), (this._tY = e), (this._element.style[Qt] = Oe(t, e)), !0)
|
| 2925 |
+
)
|
| 2926 |
+
}),
|
| 2927 |
+
(Ge.prototype._destroy = function (t) {
|
| 2928 |
+
if (!this._isDestroyed) {
|
| 2929 |
+
var i = this._element,
|
| 2930 |
+
n = this.getGrid()._settings
|
| 2931 |
+
this._dragPlaceholder.destroy(),
|
| 2932 |
+
this._dragRelease.destroy(),
|
| 2933 |
+
this._migrate.destroy(),
|
| 2934 |
+
this._layout.destroy(),
|
| 2935 |
+
this._visibility.destroy(),
|
| 2936 |
+
this._drag && this._drag.destroy(),
|
| 2937 |
+
this._emitter.destroy(),
|
| 2938 |
+
ge(i, n.itemClass),
|
| 2939 |
+
t && i.parentNode.removeChild(i),
|
| 2940 |
+
e && e.delete(i),
|
| 2941 |
+
(this._isActive = !1),
|
| 2942 |
+
(this._isDestroyed = !0)
|
| 2943 |
+
}
|
| 2944 |
+
})
|
| 2945 |
+
var Ve = ze(),
|
| 2946 |
+
je = null,
|
| 2947 |
+
Ue = []
|
| 2948 |
+
function Qe(t, e) {
|
| 2949 |
+
if (
|
| 2950 |
+
((this._options = 0),
|
| 2951 |
+
(this._processor = null),
|
| 2952 |
+
(this._layoutQueue = []),
|
| 2953 |
+
(this._layouts = {}),
|
| 2954 |
+
(this._layoutCallbacks = {}),
|
| 2955 |
+
(this._layoutWorkers = {}),
|
| 2956 |
+
(this._layoutWorkerData = {}),
|
| 2957 |
+
(this._workers = []),
|
| 2958 |
+
(this._onWorkerMessage = this._onWorkerMessage.bind(this)),
|
| 2959 |
+
this.setOptions(e),
|
| 2960 |
+
(t = 'number' == typeof t ? Math.max(0, t) : 0) && window.Worker && window.URL && window.Blob)
|
| 2961 |
+
)
|
| 2962 |
+
try {
|
| 2963 |
+
this._workers = (function (t, e) {
|
| 2964 |
+
var i = []
|
| 2965 |
+
if (t > 0) {
|
| 2966 |
+
je ||
|
| 2967 |
+
(je = URL.createObjectURL(
|
| 2968 |
+
new Blob(['(' + ze.toString() + ')(true)'], { type: 'application/javascript' }),
|
| 2969 |
+
))
|
| 2970 |
+
for (var n, r = 0; r < t; r++)
|
| 2971 |
+
(n = new Worker(je)), e && (n.onmessage = e), i.push(n), Ue.push(n)
|
| 2972 |
+
}
|
| 2973 |
+
return i
|
| 2974 |
+
})(t, this._onWorkerMessage)
|
| 2975 |
+
} catch (t) {
|
| 2976 |
+
this._processor = new Ve()
|
| 2977 |
+
}
|
| 2978 |
+
else this._processor = new Ve()
|
| 2979 |
+
}
|
| 2980 |
+
;(Qe.prototype._sendToWorker = function () {
|
| 2981 |
+
if (this._layoutQueue.length && this._workers.length) {
|
| 2982 |
+
var t = this._layoutQueue.shift(),
|
| 2983 |
+
e = this._workers.pop(),
|
| 2984 |
+
i = this._layoutWorkerData[t]
|
| 2985 |
+
delete this._layoutWorkerData[t], (this._layoutWorkers[t] = e), e.postMessage(i.buffer, [i.buffer])
|
| 2986 |
+
}
|
| 2987 |
+
}),
|
| 2988 |
+
(Qe.prototype._onWorkerMessage = function (t) {
|
| 2989 |
+
var e = new Float32Array(t.data),
|
| 2990 |
+
i = e[0],
|
| 2991 |
+
n = this._layouts[i],
|
| 2992 |
+
r = this._layoutCallbacks[i],
|
| 2993 |
+
s = this._layoutWorkers[i]
|
| 2994 |
+
n && delete this._layoutCallbacks[i],
|
| 2995 |
+
r && delete this._layoutCallbacks[i],
|
| 2996 |
+
s && delete this._layoutWorkers[i],
|
| 2997 |
+
n &&
|
| 2998 |
+
r &&
|
| 2999 |
+
((n.width = e[1]),
|
| 3000 |
+
(n.height = e[2]),
|
| 3001 |
+
(n.slots = e.subarray(4, e.length)),
|
| 3002 |
+
this._finalizeLayout(n),
|
| 3003 |
+
r(n)),
|
| 3004 |
+
s && (this._workers.push(s), this._sendToWorker())
|
| 3005 |
+
}),
|
| 3006 |
+
(Qe.prototype._finalizeLayout = function (t) {
|
| 3007 |
+
var e = t._grid,
|
| 3008 |
+
i = 2 & t._settings,
|
| 3009 |
+
n = 'border-box' === e._boxSizing
|
| 3010 |
+
return (
|
| 3011 |
+
delete t._grid,
|
| 3012 |
+
delete t._settings,
|
| 3013 |
+
(t.styles = {}),
|
| 3014 |
+
i
|
| 3015 |
+
? (t.styles.width = (n ? t.width + e._borderLeft + e._borderRight : t.width) + 'px')
|
| 3016 |
+
: (t.styles.height = (n ? t.height + e._borderTop + e._borderBottom : t.height) + 'px'),
|
| 3017 |
+
t
|
| 3018 |
+
)
|
| 3019 |
+
}),
|
| 3020 |
+
(Qe.prototype.setOptions = function (t) {
|
| 3021 |
+
var e, i, n, r, s
|
| 3022 |
+
t &&
|
| 3023 |
+
((e = 'boolean' == typeof t.fillGaps ? (t.fillGaps ? 1 : 0) : 1 & this._options),
|
| 3024 |
+
(i = 'boolean' == typeof t.horizontal ? (t.horizontal ? 2 : 0) : 2 & this._options),
|
| 3025 |
+
(n = 'boolean' == typeof t.alignRight ? (t.alignRight ? 4 : 0) : 4 & this._options),
|
| 3026 |
+
(r = 'boolean' == typeof t.alignBottom ? (t.alignBottom ? 8 : 0) : 8 & this._options),
|
| 3027 |
+
(s = 'boolean' == typeof t.rounding ? (t.rounding ? 16 : 0) : 16 & this._options),
|
| 3028 |
+
(this._options = e | i | n | r | s))
|
| 3029 |
+
}),
|
| 3030 |
+
(Qe.prototype.createLayout = function (t, e, i, n, r, s) {
|
| 3031 |
+
if (this._layouts[e]) throw new Error('A layout with the provided id is currently being processed.')
|
| 3032 |
+
var o = 2 & this._options,
|
| 3033 |
+
a = {
|
| 3034 |
+
id: e,
|
| 3035 |
+
items: i,
|
| 3036 |
+
slots: null,
|
| 3037 |
+
width: o ? 0 : n,
|
| 3038 |
+
height: o ? r : 0,
|
| 3039 |
+
_grid: t,
|
| 3040 |
+
_settings: this._options,
|
| 3041 |
+
}
|
| 3042 |
+
if (!i.length) return (a.slots = []), this._finalizeLayout(a), void s(a)
|
| 3043 |
+
if (this._processor)
|
| 3044 |
+
return (
|
| 3045 |
+
(a.slots = window.Float32Array ? new Float32Array(2 * i.length) : new Array(2 * i.length)),
|
| 3046 |
+
this._processor.computeLayout(a, a._settings),
|
| 3047 |
+
this._finalizeLayout(a),
|
| 3048 |
+
void s(a)
|
| 3049 |
+
)
|
| 3050 |
+
var h,
|
| 3051 |
+
l,
|
| 3052 |
+
u,
|
| 3053 |
+
d = new Float32Array(4 + 2 * i.length)
|
| 3054 |
+
for (d[0] = e, d[1] = a.width, d[2] = a.height, d[3] = a._settings, h = 0, l = 3; h < i.length; h++)
|
| 3055 |
+
(u = i[h]),
|
| 3056 |
+
(d[++l] = u._width + u._marginLeft + u._marginRight),
|
| 3057 |
+
(d[++l] = u._height + u._marginTop + u._marginBottom)
|
| 3058 |
+
return (
|
| 3059 |
+
this._layoutQueue.push(e),
|
| 3060 |
+
(this._layouts[e] = a),
|
| 3061 |
+
(this._layoutCallbacks[e] = s),
|
| 3062 |
+
(this._layoutWorkerData[e] = d),
|
| 3063 |
+
this._sendToWorker(),
|
| 3064 |
+
this.cancelLayout.bind(this, e)
|
| 3065 |
+
)
|
| 3066 |
+
}),
|
| 3067 |
+
(Qe.prototype.cancelLayout = function (t) {
|
| 3068 |
+
if (
|
| 3069 |
+
this._layouts[t] &&
|
| 3070 |
+
(delete this._layouts[t], delete this._layoutCallbacks[t], this._layoutWorkerData[t])
|
| 3071 |
+
) {
|
| 3072 |
+
delete this._layoutWorkerData[t]
|
| 3073 |
+
var e = this._layoutQueue.indexOf(t)
|
| 3074 |
+
e > -1 && this._layoutQueue.splice(e, 1)
|
| 3075 |
+
}
|
| 3076 |
+
}),
|
| 3077 |
+
(Qe.prototype.destroy = function () {
|
| 3078 |
+
for (var t in this._layoutWorkers) this._workers.push(this._layoutWorkers[t])
|
| 3079 |
+
!(function (t) {
|
| 3080 |
+
for (var e, i, n = 0; n < t.length; n++)
|
| 3081 |
+
((e = t[n]).onmessage = null),
|
| 3082 |
+
(e.onerror = null),
|
| 3083 |
+
(e.onmessageerror = null),
|
| 3084 |
+
e.terminate(),
|
| 3085 |
+
(i = Ue.indexOf(e)) > -1 && Ue.splice(i, 1)
|
| 3086 |
+
je && !Ue.length && (URL.revokeObjectURL(je), (je = null))
|
| 3087 |
+
})(this._workers),
|
| 3088 |
+
(this._workers.length = 0),
|
| 3089 |
+
(this._layoutQueue.length = 0),
|
| 3090 |
+
(this._layouts = {}),
|
| 3091 |
+
(this._layoutCallbacks = {}),
|
| 3092 |
+
(this._layoutWorkers = {}),
|
| 3093 |
+
(this._layoutWorkerData = {})
|
| 3094 |
+
})
|
| 3095 |
+
var Ke = 0
|
| 3096 |
+
function $e(t, e) {
|
| 3097 |
+
var i = ++Ke,
|
| 3098 |
+
n = 0,
|
| 3099 |
+
r = 0,
|
| 3100 |
+
s = !1,
|
| 3101 |
+
o = function (e) {
|
| 3102 |
+
s ||
|
| 3103 |
+
(r && (n -= e - r),
|
| 3104 |
+
(r = e),
|
| 3105 |
+
n > 0
|
| 3106 |
+
? (function (t, e) {
|
| 3107 |
+
it.add(0, et + t, e)
|
| 3108 |
+
})(i, o)
|
| 3109 |
+
: ((n = r = 0), t()))
|
| 3110 |
+
}
|
| 3111 |
+
return function (a) {
|
| 3112 |
+
if (!s) {
|
| 3113 |
+
if (!(e <= 0))
|
| 3114 |
+
return !0 === a
|
| 3115 |
+
? ((s = !0),
|
| 3116 |
+
(n = r = 0),
|
| 3117 |
+
(o = void 0),
|
| 3118 |
+
void (function (t) {
|
| 3119 |
+
it.remove(0, et + t)
|
| 3120 |
+
})(i))
|
| 3121 |
+
: void (n <= 0 ? ((n = e), o(0)) : (n = e))
|
| 3122 |
+
!0 !== a && t()
|
| 3123 |
+
}
|
| 3124 |
+
}
|
| 3125 |
+
}
|
| 3126 |
+
function Ze(t) {
|
| 3127 |
+
var e = Object.prototype.toString.call(t)
|
| 3128 |
+
return '[object HTMLCollection]' === e || '[object NodeList]' === e
|
| 3129 |
+
}
|
| 3130 |
+
var Je = Object.prototype.toString
|
| 3131 |
+
function ti(t) {
|
| 3132 |
+
return 'object' == typeof t && '[object Object]' === Je.call(t)
|
| 3133 |
+
}
|
| 3134 |
+
function ei() {}
|
| 3135 |
+
var ii,
|
| 3136 |
+
ni,
|
| 3137 |
+
ri,
|
| 3138 |
+
si = 'number',
|
| 3139 |
+
oi = 'string',
|
| 3140 |
+
ai = 'instant',
|
| 3141 |
+
hi = 0
|
| 3142 |
+
function li(e, i) {
|
| 3143 |
+
if (
|
| 3144 |
+
(typeof e === oi && (e = document.querySelector(e)),
|
| 3145 |
+
!(e.getRootNode ? e.getRootNode({ composed: !0 }) === document : document.body.contains(e)) ||
|
| 3146 |
+
e === document.documentElement)
|
| 3147 |
+
)
|
| 3148 |
+
throw new Error('Container element must be an existing DOM element.')
|
| 3149 |
+
var n = (function (t, e) {
|
| 3150 |
+
var i = ui({}, t)
|
| 3151 |
+
e && (i = ui(i, e))
|
| 3152 |
+
e && e.visibleStyles
|
| 3153 |
+
? (i.visibleStyles = e.visibleStyles)
|
| 3154 |
+
: t && t.visibleStyles && (i.visibleStyles = t.visibleStyles)
|
| 3155 |
+
e && e.hiddenStyles
|
| 3156 |
+
? (i.hiddenStyles = e.hiddenStyles)
|
| 3157 |
+
: t && t.hiddenStyles && (i.hiddenStyles = t.hiddenStyles)
|
| 3158 |
+
return i
|
| 3159 |
+
})(li.defaultOptions, i)
|
| 3160 |
+
;(n.visibleStyles = di(n.visibleStyles)),
|
| 3161 |
+
(n.hiddenStyles = di(n.hiddenStyles)),
|
| 3162 |
+
dt(n.dragSort) || (n.dragSort = !!n.dragSort),
|
| 3163 |
+
(this._id = Be()),
|
| 3164 |
+
(this._element = e),
|
| 3165 |
+
(this._settings = n),
|
| 3166 |
+
(this._isDestroyed = !1),
|
| 3167 |
+
(this._items = []),
|
| 3168 |
+
(this._layout = { id: 0, items: [], slots: [] }),
|
| 3169 |
+
(this._isLayoutFinished = !0),
|
| 3170 |
+
(this._nextLayoutData = null),
|
| 3171 |
+
(this._emitter = new b()),
|
| 3172 |
+
(this._onLayoutDataReceived = this._onLayoutDataReceived.bind(this)),
|
| 3173 |
+
(t[this._id] = this),
|
| 3174 |
+
Bt(e, n.containerClass),
|
| 3175 |
+
(function (t, e) {
|
| 3176 |
+
typeof e !== si && (e = !0 === e ? 0 : -1)
|
| 3177 |
+
e >= 0 &&
|
| 3178 |
+
((t._resizeHandler = $e(function () {
|
| 3179 |
+
t.refreshItems().layout()
|
| 3180 |
+
}, e)),
|
| 3181 |
+
window.addEventListener('resize', t._resizeHandler))
|
| 3182 |
+
})(this, n.layoutOnResize),
|
| 3183 |
+
this.add(
|
| 3184 |
+
(function (t, e) {
|
| 3185 |
+
if ('*' === e) return t.children
|
| 3186 |
+
if (typeof e === oi) {
|
| 3187 |
+
for (var i = [], n = t.children, r = 0; r < n.length; r++) Wt(n[r], e) && i.push(n[r])
|
| 3188 |
+
return i
|
| 3189 |
+
}
|
| 3190 |
+
if (Array.isArray(e) || Ze(e)) return e
|
| 3191 |
+
return []
|
| 3192 |
+
})(e, n.items),
|
| 3193 |
+
{ layout: !1 },
|
| 3194 |
+
),
|
| 3195 |
+
n.layoutOnInit && this.layout(!0)
|
| 3196 |
+
}
|
| 3197 |
+
function ui(t, e) {
|
| 3198 |
+
var i,
|
| 3199 |
+
n,
|
| 3200 |
+
r,
|
| 3201 |
+
s = Object.keys(e),
|
| 3202 |
+
o = s.length
|
| 3203 |
+
for (r = 0; r < o; r++)
|
| 3204 |
+
(i = ti(e[(n = s[r])])),
|
| 3205 |
+
ti(t[n]) && i
|
| 3206 |
+
? (t[n] = ui(ui({}, t[n]), e[n]))
|
| 3207 |
+
: i
|
| 3208 |
+
? (t[n] = ui({}, e[n]))
|
| 3209 |
+
: Array.isArray(e[n])
|
| 3210 |
+
? (t[n] = e[n].slice(0))
|
| 3211 |
+
: (t[n] = e[n])
|
| 3212 |
+
return t
|
| 3213 |
+
}
|
| 3214 |
+
function di(t) {
|
| 3215 |
+
var e,
|
| 3216 |
+
i,
|
| 3217 |
+
n = {},
|
| 3218 |
+
r = document.documentElement.style
|
| 3219 |
+
for (e in t) t[e] && (i = x(r, e)) && (n[i] = t[e])
|
| 3220 |
+
return n
|
| 3221 |
+
}
|
| 3222 |
+
function ci(t) {
|
| 3223 |
+
for (var e = {}, i = 0; i < t.length; i++) e[t[i]._id] = i
|
| 3224 |
+
return e
|
| 3225 |
+
}
|
| 3226 |
+
function _i(t, e, i) {
|
| 3227 |
+
return t[e._id] - t[i._id]
|
| 3228 |
+
}
|
| 3229 |
+
;(li.Item = Ge),
|
| 3230 |
+
(li.ItemLayout = qe),
|
| 3231 |
+
(li.ItemVisibility = Fe),
|
| 3232 |
+
(li.ItemMigrate = He),
|
| 3233 |
+
(li.ItemDrag = De),
|
| 3234 |
+
(li.ItemDragRelease = Ye),
|
| 3235 |
+
(li.ItemDragPlaceholder = Xe),
|
| 3236 |
+
(li.Emitter = b),
|
| 3237 |
+
(li.Animator = Ce),
|
| 3238 |
+
(li.Dragger = N),
|
| 3239 |
+
(li.Packer = Qe),
|
| 3240 |
+
(li.AutoScroller = qt),
|
| 3241 |
+
(li.defaultPacker = new Qe(2)),
|
| 3242 |
+
(li.defaultOptions = {
|
| 3243 |
+
items: '*',
|
| 3244 |
+
showDuration: 300,
|
| 3245 |
+
showEasing: 'ease',
|
| 3246 |
+
hideDuration: 300,
|
| 3247 |
+
hideEasing: 'ease',
|
| 3248 |
+
visibleStyles: { opacity: '1', transform: 'scale(1)' },
|
| 3249 |
+
hiddenStyles: { opacity: '0', transform: 'scale(0.5)' },
|
| 3250 |
+
layout: { fillGaps: !1, horizontal: !1, alignRight: !1, alignBottom: !1, rounding: !1 },
|
| 3251 |
+
layoutOnResize: 150,
|
| 3252 |
+
layoutOnInit: !0,
|
| 3253 |
+
layoutDuration: 300,
|
| 3254 |
+
layoutEasing: 'ease',
|
| 3255 |
+
sortData: null,
|
| 3256 |
+
dragEnabled: !1,
|
| 3257 |
+
dragContainer: null,
|
| 3258 |
+
dragHandle: null,
|
| 3259 |
+
dragStartPredicate: { distance: 0, delay: 0 },
|
| 3260 |
+
dragAxis: 'xy',
|
| 3261 |
+
dragSort: !0,
|
| 3262 |
+
dragSortHeuristics: { sortInterval: 100, minDragDistance: 10, minBounceBackAngle: 1 },
|
| 3263 |
+
dragSortPredicate: { threshold: 50, action: n, migrateAction: n },
|
| 3264 |
+
dragRelease: { duration: 300, easing: 'ease', useDragContainer: !0 },
|
| 3265 |
+
dragCssProps: {
|
| 3266 |
+
touchAction: 'none',
|
| 3267 |
+
userSelect: 'none',
|
| 3268 |
+
userDrag: 'none',
|
| 3269 |
+
tapHighlightColor: 'rgba(0, 0, 0, 0)',
|
| 3270 |
+
touchCallout: 'none',
|
| 3271 |
+
contentZooming: 'none',
|
| 3272 |
+
},
|
| 3273 |
+
dragPlaceholder: { enabled: !1, createElement: null, onCreate: null, onRemove: null },
|
| 3274 |
+
dragAutoScroll: {
|
| 3275 |
+
targets: [],
|
| 3276 |
+
handle: null,
|
| 3277 |
+
threshold: 50,
|
| 3278 |
+
safeZone: 0.2,
|
| 3279 |
+
speed: qt.smoothSpeed(1e3, 2e3, 2500),
|
| 3280 |
+
sortDuringScroll: !0,
|
| 3281 |
+
smoothStop: !1,
|
| 3282 |
+
onStart: null,
|
| 3283 |
+
onStop: null,
|
| 3284 |
+
},
|
| 3285 |
+
containerClass: 'muuri',
|
| 3286 |
+
itemClass: 'muuri-item',
|
| 3287 |
+
itemVisibleClass: 'muuri-item-shown',
|
| 3288 |
+
itemHiddenClass: 'muuri-item-hidden',
|
| 3289 |
+
itemPositioningClass: 'muuri-item-positioning',
|
| 3290 |
+
itemDraggingClass: 'muuri-item-dragging',
|
| 3291 |
+
itemReleasingClass: 'muuri-item-releasing',
|
| 3292 |
+
itemPlaceholderClass: 'muuri-item-placeholder',
|
| 3293 |
+
}),
|
| 3294 |
+
(li.prototype.on = function (t, e) {
|
| 3295 |
+
return this._emitter.on(t, e), this
|
| 3296 |
+
}),
|
| 3297 |
+
(li.prototype.off = function (t, e) {
|
| 3298 |
+
return this._emitter.off(t, e), this
|
| 3299 |
+
}),
|
| 3300 |
+
(li.prototype.getElement = function () {
|
| 3301 |
+
return this._element
|
| 3302 |
+
}),
|
| 3303 |
+
(li.prototype.getItem = function (t) {
|
| 3304 |
+
if (this._isDestroyed || (!t && 0 !== t)) return null
|
| 3305 |
+
if (typeof t === si) return this._items[t > -1 ? t : this._items.length + t] || null
|
| 3306 |
+
if (t instanceof Ge) return t._gridId === this._id ? t : null
|
| 3307 |
+
if (e) {
|
| 3308 |
+
var i = e.get(t)
|
| 3309 |
+
return i && i._gridId === this._id ? i : null
|
| 3310 |
+
}
|
| 3311 |
+
for (var n = 0; n < this._items.length; n++) if (this._items[n]._element === t) return this._items[n]
|
| 3312 |
+
return null
|
| 3313 |
+
}),
|
| 3314 |
+
(li.prototype.getItems = function (t) {
|
| 3315 |
+
if (this._isDestroyed || void 0 === t) return this._items.slice(0)
|
| 3316 |
+
var e,
|
| 3317 |
+
i,
|
| 3318 |
+
n = []
|
| 3319 |
+
if (Array.isArray(t) || Ze(t)) for (e = 0; e < t.length; e++) (i = this.getItem(t[e])) && n.push(i)
|
| 3320 |
+
else (i = this.getItem(t)) && n.push(i)
|
| 3321 |
+
return n
|
| 3322 |
+
}),
|
| 3323 |
+
(li.prototype.refreshItems = function (t, e) {
|
| 3324 |
+
if (this._isDestroyed) return this
|
| 3325 |
+
var i,
|
| 3326 |
+
n,
|
| 3327 |
+
r,
|
| 3328 |
+
s,
|
| 3329 |
+
o = t || this._items
|
| 3330 |
+
if (!0 === e)
|
| 3331 |
+
for (s = [], i = 0; i < o.length; i++)
|
| 3332 |
+
(n = o[i]).isVisible() ||
|
| 3333 |
+
n.isHiding() ||
|
| 3334 |
+
(((r = n.getElement().style).visibility = 'hidden'), (r.display = ''), s.push(r))
|
| 3335 |
+
for (i = 0; i < o.length; i++) o[i]._refreshDimensions(e)
|
| 3336 |
+
if (!0 === e) {
|
| 3337 |
+
for (i = 0; i < s.length; i++) ((r = s[i]).visibility = ''), (r.display = 'none')
|
| 3338 |
+
s.length = 0
|
| 3339 |
+
}
|
| 3340 |
+
return this
|
| 3341 |
+
}),
|
| 3342 |
+
(li.prototype.refreshSortData = function (t) {
|
| 3343 |
+
if (this._isDestroyed) return this
|
| 3344 |
+
for (var e = t || this._items, i = 0; i < e.length; i++) e[i]._refreshSortData()
|
| 3345 |
+
return this
|
| 3346 |
+
}),
|
| 3347 |
+
(li.prototype.synchronize = function () {
|
| 3348 |
+
if (this._isDestroyed) return this
|
| 3349 |
+
var t,
|
| 3350 |
+
e,
|
| 3351 |
+
i = this._items
|
| 3352 |
+
if (!i.length) return this
|
| 3353 |
+
for (var n = 0; n < i.length; n++)
|
| 3354 |
+
(e = i[n]._element).parentNode === this._element &&
|
| 3355 |
+
(t = t || document.createDocumentFragment()).appendChild(e)
|
| 3356 |
+
return t ? (this._element.appendChild(t), this._emit('synchronize'), this) : this
|
| 3357 |
+
}),
|
| 3358 |
+
(li.prototype.layout = function (t, e) {
|
| 3359 |
+
if (this._isDestroyed) return this
|
| 3360 |
+
var i = this._nextLayoutData
|
| 3361 |
+
i && dt(i.cancel) && i.cancel()
|
| 3362 |
+
var n = (hi = (hi % 16777216) + 1)
|
| 3363 |
+
this._nextLayoutData = { id: n, instant: t, onFinish: e, cancel: null }
|
| 3364 |
+
for (var r = this._items, s = [], o = 0; o < r.length; o++) r[o]._isActive && s.push(r[o])
|
| 3365 |
+
this._refreshDimensions()
|
| 3366 |
+
var a,
|
| 3367 |
+
h = this._width - this._borderLeft - this._borderRight,
|
| 3368 |
+
l = this._height - this._borderTop - this._borderBottom,
|
| 3369 |
+
u = this._settings.layout
|
| 3370 |
+
return (
|
| 3371 |
+
dt(u)
|
| 3372 |
+
? (a = u(this, n, s, h, l, this._onLayoutDataReceived))
|
| 3373 |
+
: (li.defaultPacker.setOptions(u),
|
| 3374 |
+
(a = li.defaultPacker.createLayout(this, n, s, h, l, this._onLayoutDataReceived))),
|
| 3375 |
+
dt(a) && this._nextLayoutData && this._nextLayoutData.id === n && (this._nextLayoutData.cancel = a),
|
| 3376 |
+
this
|
| 3377 |
+
)
|
| 3378 |
+
}),
|
| 3379 |
+
(li.prototype.add = function (t, e) {
|
| 3380 |
+
if (this._isDestroyed || !t) return []
|
| 3381 |
+
var i,
|
| 3382 |
+
n = Ze((i = t)) ? Array.prototype.slice.call(i) : Array.prototype.concat(i)
|
| 3383 |
+
if (!n.length) return n
|
| 3384 |
+
var r,
|
| 3385 |
+
s,
|
| 3386 |
+
o,
|
| 3387 |
+
a,
|
| 3388 |
+
h = e || {},
|
| 3389 |
+
l = h.layout ? h.layout : void 0 === h.layout,
|
| 3390 |
+
u = this._items,
|
| 3391 |
+
d = !1
|
| 3392 |
+
for (a = 0; a < n.length; a++)
|
| 3393 |
+
(s = n[a]).parentNode !== this._element && (r = r || document.createDocumentFragment()).appendChild(s)
|
| 3394 |
+
for (r && this._element.appendChild(r), a = 0; a < n.length; a++)
|
| 3395 |
+
(s = n[a]),
|
| 3396 |
+
(o = n[a] = new Ge(this, s, h.active))._isActive && ((d = !0), (o._layout._skipNextAnimation = !0))
|
| 3397 |
+
for (a = 0; a < n.length; a++) (o = n[a])._refreshDimensions(), o._refreshSortData()
|
| 3398 |
+
return (
|
| 3399 |
+
zt(u, n, h.index),
|
| 3400 |
+
this._hasListeners('add') && this._emit('add', n.slice(0)),
|
| 3401 |
+
d && l && this.layout(l === ai, dt(l) ? l : void 0),
|
| 3402 |
+
n
|
| 3403 |
+
)
|
| 3404 |
+
}),
|
| 3405 |
+
(li.prototype.remove = function (t, e) {
|
| 3406 |
+
if (this._isDestroyed || !t.length) return []
|
| 3407 |
+
var i,
|
| 3408 |
+
n,
|
| 3409 |
+
r,
|
| 3410 |
+
s = e || {},
|
| 3411 |
+
o = s.layout ? s.layout : void 0 === s.layout,
|
| 3412 |
+
h = !1,
|
| 3413 |
+
l = this.getItems(),
|
| 3414 |
+
u = [],
|
| 3415 |
+
d = []
|
| 3416 |
+
for (r = 0; r < t.length; r++)
|
| 3417 |
+
(n = t[r])._isDestroyed ||
|
| 3418 |
+
(-1 !== (i = this._items.indexOf(n)) &&
|
| 3419 |
+
(n._isActive && (h = !0),
|
| 3420 |
+
u.push(n),
|
| 3421 |
+
d.push(l.indexOf(n)),
|
| 3422 |
+
n._destroy(s.removeElements),
|
| 3423 |
+
this._items.splice(i, 1)))
|
| 3424 |
+
return (
|
| 3425 |
+
this._hasListeners(a) && this._emit(a, u.slice(0), d),
|
| 3426 |
+
h && o && this.layout(o === ai, dt(o) ? o : void 0),
|
| 3427 |
+
u
|
| 3428 |
+
)
|
| 3429 |
+
}),
|
| 3430 |
+
(li.prototype.show = function (t, e) {
|
| 3431 |
+
return !this._isDestroyed && t.length && this._setItemsVisibility(t, !0, e), this
|
| 3432 |
+
}),
|
| 3433 |
+
(li.prototype.hide = function (t, e) {
|
| 3434 |
+
return !this._isDestroyed && t.length && this._setItemsVisibility(t, !1, e), this
|
| 3435 |
+
}),
|
| 3436 |
+
(li.prototype.filter = function (t, e) {
|
| 3437 |
+
if (this._isDestroyed || !this._items.length) return this
|
| 3438 |
+
var i,
|
| 3439 |
+
n,
|
| 3440 |
+
r = [],
|
| 3441 |
+
s = [],
|
| 3442 |
+
o = typeof t === oi,
|
| 3443 |
+
a = dt(t),
|
| 3444 |
+
h = e || {},
|
| 3445 |
+
u = !0 === h.instant,
|
| 3446 |
+
d = h.syncWithLayout,
|
| 3447 |
+
c = h.layout ? h.layout : void 0 === h.layout,
|
| 3448 |
+
_ = dt(h.onFinish) ? h.onFinish : null,
|
| 3449 |
+
f = -1,
|
| 3450 |
+
p = ei
|
| 3451 |
+
if (
|
| 3452 |
+
(_ &&
|
| 3453 |
+
(p = function () {
|
| 3454 |
+
++f && _(r.slice(0), s.slice(0))
|
| 3455 |
+
}),
|
| 3456 |
+
a || o)
|
| 3457 |
+
)
|
| 3458 |
+
for (n = 0; n < this._items.length; n++)
|
| 3459 |
+
(i = this._items[n]), (a ? t(i) : Wt(i._element, t)) ? r.push(i) : s.push(i)
|
| 3460 |
+
return (
|
| 3461 |
+
r.length ? this.show(r, { instant: u, syncWithLayout: d, onFinish: p, layout: !1 }) : p(),
|
| 3462 |
+
s.length ? this.hide(s, { instant: u, syncWithLayout: d, onFinish: p, layout: !1 }) : p(),
|
| 3463 |
+
(r.length || s.length) &&
|
| 3464 |
+
(this._hasListeners(l) && this._emit(l, r.slice(0), s.slice(0)),
|
| 3465 |
+
c && this.layout(c === ai, dt(c) ? c : void 0)),
|
| 3466 |
+
this
|
| 3467 |
+
)
|
| 3468 |
+
}),
|
| 3469 |
+
(li.prototype.sort = (function () {
|
| 3470 |
+
var t, e, i, n
|
| 3471 |
+
function r(r, s) {
|
| 3472 |
+
for (var o, a, h, l, u = 0, d = 0; d < t.length; d++)
|
| 3473 |
+
if (
|
| 3474 |
+
((o = t[d][0]),
|
| 3475 |
+
(a = t[d][1]),
|
| 3476 |
+
(h = (r._sortData ? r : r._refreshSortData())._sortData[o]),
|
| 3477 |
+
(l = (s._sortData ? s : s._refreshSortData())._sortData[o]),
|
| 3478 |
+
(u = 'desc' === a || (!a && e) ? (l < h ? -1 : l > h ? 1 : 0) : h < l ? -1 : h > l ? 1 : 0))
|
| 3479 |
+
)
|
| 3480 |
+
return u
|
| 3481 |
+
return u || (n || (n = ci(i)), (u = e ? _i(n, s, r) : _i(n, r, s))), u
|
| 3482 |
+
}
|
| 3483 |
+
function s(r, s) {
|
| 3484 |
+
var o = e ? -t(r, s) : t(r, s)
|
| 3485 |
+
return o || (n || (n = ci(i)), (o = e ? _i(n, s, r) : _i(n, r, s))), o
|
| 3486 |
+
}
|
| 3487 |
+
return function (o, a) {
|
| 3488 |
+
if (this._isDestroyed || this._items.length < 2) return this
|
| 3489 |
+
var h = this._items,
|
| 3490 |
+
l = a || {},
|
| 3491 |
+
d = l.layout ? l.layout : void 0 === l.layout
|
| 3492 |
+
if (((e = !!l.descending), (i = h.slice(0)), (n = null), dt(o))) (t = o), h.sort(s)
|
| 3493 |
+
else if (typeof o === oi)
|
| 3494 |
+
(t = o
|
| 3495 |
+
.trim()
|
| 3496 |
+
.split(' ')
|
| 3497 |
+
.filter(function (t) {
|
| 3498 |
+
return t
|
| 3499 |
+
})
|
| 3500 |
+
.map(function (t) {
|
| 3501 |
+
return t.split(':')
|
| 3502 |
+
})),
|
| 3503 |
+
h.sort(r)
|
| 3504 |
+
else {
|
| 3505 |
+
if (!Array.isArray(o))
|
| 3506 |
+
throw ((t = e = i = n = null), new Error('Invalid comparer argument provided.'))
|
| 3507 |
+
;(h.length = 0), h.push.apply(h, o)
|
| 3508 |
+
}
|
| 3509 |
+
return (
|
| 3510 |
+
this._hasListeners(u) && this._emit(u, h.slice(0), i),
|
| 3511 |
+
d && this.layout(d === ai, dt(d) ? d : void 0),
|
| 3512 |
+
(t = e = i = n = null),
|
| 3513 |
+
this
|
| 3514 |
+
)
|
| 3515 |
+
}
|
| 3516 |
+
})()),
|
| 3517 |
+
(li.prototype.move = function (t, e, r) {
|
| 3518 |
+
if (this._isDestroyed || this._items.length < 2) return this
|
| 3519 |
+
var s,
|
| 3520 |
+
o,
|
| 3521 |
+
a = this._items,
|
| 3522 |
+
h = r || {},
|
| 3523 |
+
l = h.layout ? h.layout : void 0 === h.layout,
|
| 3524 |
+
u = h.action === i,
|
| 3525 |
+
c = u ? i : n,
|
| 3526 |
+
_ = this.getItem(t),
|
| 3527 |
+
f = this.getItem(e)
|
| 3528 |
+
return (
|
| 3529 |
+
_ &&
|
| 3530 |
+
f &&
|
| 3531 |
+
_ !== f &&
|
| 3532 |
+
((s = a.indexOf(_)),
|
| 3533 |
+
(o = a.indexOf(f)),
|
| 3534 |
+
u ? Ut(a, s, o) : jt(a, s, o),
|
| 3535 |
+
this._hasListeners(d) && this._emit(d, { item: _, fromIndex: s, toIndex: o, action: c }),
|
| 3536 |
+
l && this.layout(l === ai, dt(l) ? l : void 0)),
|
| 3537 |
+
this
|
| 3538 |
+
)
|
| 3539 |
+
}),
|
| 3540 |
+
(li.prototype.send = function (t, e, i, n) {
|
| 3541 |
+
if (this._isDestroyed || e._isDestroyed || this === e) return this
|
| 3542 |
+
if (!(t = this.getItem(t))) return this
|
| 3543 |
+
var r = n || {},
|
| 3544 |
+
s = r.appendTo || document.body,
|
| 3545 |
+
o = r.layoutSender ? r.layoutSender : void 0 === r.layoutSender,
|
| 3546 |
+
a = r.layoutReceiver ? r.layoutReceiver : void 0 === r.layoutReceiver
|
| 3547 |
+
return (
|
| 3548 |
+
t._migrate.start(e, i, s),
|
| 3549 |
+
t._migrate._isActive &&
|
| 3550 |
+
t._isActive &&
|
| 3551 |
+
(o && this.layout(o === ai, dt(o) ? o : void 0), a && e.layout(a === ai, dt(a) ? a : void 0)),
|
| 3552 |
+
this
|
| 3553 |
+
)
|
| 3554 |
+
}),
|
| 3555 |
+
(li.prototype.destroy = function (e) {
|
| 3556 |
+
if (this._isDestroyed) return this
|
| 3557 |
+
var i,
|
| 3558 |
+
n,
|
| 3559 |
+
r,
|
| 3560 |
+
s = this._element,
|
| 3561 |
+
o = this._items.slice(0),
|
| 3562 |
+
a = (this._layout && this._layout.styles) || {}
|
| 3563 |
+
for (
|
| 3564 |
+
(r = this)._resizeHandler &&
|
| 3565 |
+
(r._resizeHandler(!0),
|
| 3566 |
+
window.removeEventListener('resize', r._resizeHandler),
|
| 3567 |
+
(r._resizeHandler = null)),
|
| 3568 |
+
i = 0;
|
| 3569 |
+
i < o.length;
|
| 3570 |
+
i++
|
| 3571 |
+
)
|
| 3572 |
+
o[i]._destroy(e)
|
| 3573 |
+
for (n in ((this._items.length = 0), ge(s, this._settings.containerClass), a)) s.style[n] = ''
|
| 3574 |
+
return this._emit('destroy'), this._emitter.destroy(), delete t[this._id], (this._isDestroyed = !0), this
|
| 3575 |
+
}),
|
| 3576 |
+
(li.prototype._emit = function () {
|
| 3577 |
+
this._isDestroyed || this._emitter.emit.apply(this._emitter, arguments)
|
| 3578 |
+
}),
|
| 3579 |
+
(li.prototype._hasListeners = function (t) {
|
| 3580 |
+
return !this._isDestroyed && this._emitter.countListeners(t) > 0
|
| 3581 |
+
}),
|
| 3582 |
+
(li.prototype._updateBoundingRect = function () {
|
| 3583 |
+
var t = this._element.getBoundingClientRect()
|
| 3584 |
+
;(this._width = t.width),
|
| 3585 |
+
(this._height = t.height),
|
| 3586 |
+
(this._left = t.left),
|
| 3587 |
+
(this._top = t.top),
|
| 3588 |
+
(this._right = t.right),
|
| 3589 |
+
(this._bottom = t.bottom)
|
| 3590 |
+
}),
|
| 3591 |
+
(li.prototype._updateBorders = function (t, e, i, n) {
|
| 3592 |
+
var r = this._element
|
| 3593 |
+
t && (this._borderLeft = vt(r, 'border-left-width')),
|
| 3594 |
+
e && (this._borderRight = vt(r, 'border-right-width')),
|
| 3595 |
+
i && (this._borderTop = vt(r, 'border-top-width')),
|
| 3596 |
+
n && (this._borderBottom = vt(r, 'border-bottom-width'))
|
| 3597 |
+
}),
|
| 3598 |
+
(li.prototype._refreshDimensions = function () {
|
| 3599 |
+
this._updateBoundingRect(),
|
| 3600 |
+
this._updateBorders(1, 1, 1, 1),
|
| 3601 |
+
(this._boxSizing = gt(this._element, 'box-sizing'))
|
| 3602 |
+
}),
|
| 3603 |
+
(li.prototype._onLayoutDataReceived =
|
| 3604 |
+
((ii = []),
|
| 3605 |
+
function (t) {
|
| 3606 |
+
if (!this._isDestroyed && this._nextLayoutData && this._nextLayoutData.id === t.id) {
|
| 3607 |
+
var e,
|
| 3608 |
+
i,
|
| 3609 |
+
n,
|
| 3610 |
+
a,
|
| 3611 |
+
h = this,
|
| 3612 |
+
l = this._nextLayoutData.instant,
|
| 3613 |
+
u = this._nextLayoutData.onFinish,
|
| 3614 |
+
d = t.items.length,
|
| 3615 |
+
c = d
|
| 3616 |
+
for (
|
| 3617 |
+
this._nextLayoutData = null,
|
| 3618 |
+
!this._isLayoutFinished &&
|
| 3619 |
+
this._hasListeners(o) &&
|
| 3620 |
+
this._emit(o, this._layout.items.slice(0)),
|
| 3621 |
+
this._layout = t,
|
| 3622 |
+
ii.length = 0,
|
| 3623 |
+
a = 0;
|
| 3624 |
+
a < d;
|
| 3625 |
+
a++
|
| 3626 |
+
)
|
| 3627 |
+
(e = t.items[a])
|
| 3628 |
+
? ((i = t.slots[2 * a]),
|
| 3629 |
+
(n = t.slots[2 * a + 1]),
|
| 3630 |
+
e._canSkipLayout(i, n)
|
| 3631 |
+
? --c
|
| 3632 |
+
: ((e._left = i), (e._top = n), e.isActive() && !e.isDragging() ? ii.push(e) : --c))
|
| 3633 |
+
: --c
|
| 3634 |
+
if (
|
| 3635 |
+
(t.styles && Re(this._element, t.styles),
|
| 3636 |
+
!this._hasListeners(r) || (this._emit(r, t.items.slice(0), !0 === l), this._layout.id === t.id))
|
| 3637 |
+
) {
|
| 3638 |
+
var _ = function () {
|
| 3639 |
+
if (!(--c > 0)) {
|
| 3640 |
+
var e = h._layout.id !== t.id,
|
| 3641 |
+
i = dt(l) ? l : u
|
| 3642 |
+
e || (h._isLayoutFinished = !0),
|
| 3643 |
+
dt(i) && i(t.items.slice(0), e),
|
| 3644 |
+
!e && h._hasListeners(s) && h._emit(s, t.items.slice(0))
|
| 3645 |
+
}
|
| 3646 |
+
}
|
| 3647 |
+
if (!ii.length) return _(), this
|
| 3648 |
+
for (this._isLayoutFinished = !1, a = 0; a < ii.length && this._layout.id === t.id; a++)
|
| 3649 |
+
ii[a]._layout.start(!0 === l, _)
|
| 3650 |
+
return this._layout.id === t.id && (ii.length = 0), this
|
| 3651 |
+
}
|
| 3652 |
+
}
|
| 3653 |
+
})),
|
| 3654 |
+
(li.prototype._setItemsVisibility = function (t, e, i) {
|
| 3655 |
+
var n,
|
| 3656 |
+
s,
|
| 3657 |
+
o = this,
|
| 3658 |
+
a = t.slice(0),
|
| 3659 |
+
l = i || {},
|
| 3660 |
+
u = !0 === l.instant,
|
| 3661 |
+
d = l.onFinish,
|
| 3662 |
+
c = l.layout ? l.layout : void 0 === l.layout,
|
| 3663 |
+
_ = a.length,
|
| 3664 |
+
f = e ? 'showStart' : h,
|
| 3665 |
+
p = e ? 'showEnd' : 'hideEnd',
|
| 3666 |
+
m = e ? 'show' : 'hide',
|
| 3667 |
+
g = !1,
|
| 3668 |
+
v = [],
|
| 3669 |
+
y = []
|
| 3670 |
+
if (_) {
|
| 3671 |
+
for (s = 0; s < a.length; s++)
|
| 3672 |
+
(n = a[s]),
|
| 3673 |
+
((e && !n._isActive) || (!e && n._isActive)) && (g = !0),
|
| 3674 |
+
(n._layout._skipNextAnimation = !(!e || n._isActive)),
|
| 3675 |
+
e && n._visibility._isHidden && y.push(n),
|
| 3676 |
+
e ? n._addToLayout() : n._removeFromLayout()
|
| 3677 |
+
y.length && (this.refreshItems(y, !0), (y.length = 0)),
|
| 3678 |
+
g && !1 !== l.syncWithLayout ? this.on(r, b) : b(),
|
| 3679 |
+
g && c && this.layout(c === ai, dt(c) ? c : void 0)
|
| 3680 |
+
} else dt(d) && d(a)
|
| 3681 |
+
function b() {
|
| 3682 |
+
for (
|
| 3683 |
+
g && !1 !== l.syncWithLayout && o.off(r, b), o._hasListeners(f) && o._emit(f, a.slice(0)), s = 0;
|
| 3684 |
+
s < a.length;
|
| 3685 |
+
s++
|
| 3686 |
+
)
|
| 3687 |
+
a[s]._gridId === o._id
|
| 3688 |
+
? a[s]._visibility[m](u, function (t, e) {
|
| 3689 |
+
t || v.push(e),
|
| 3690 |
+
--_ < 1 && (dt(d) && d(v.slice(0)), o._hasListeners(p) && o._emit(p, v.slice(0)))
|
| 3691 |
+
})
|
| 3692 |
+
: --_ < 1 && (dt(d) && d(v.slice(0)), o._hasListeners(p) && o._emit(p, v.slice(0)))
|
| 3693 |
+
}
|
| 3694 |
+
}),
|
| 3695 |
+
(ri = {}),
|
| 3696 |
+
(function (t, e) {
|
| 3697 |
+
function i() {
|
| 3698 |
+
;(this._delay = 0),
|
| 3699 |
+
(this._endDelay = 0),
|
| 3700 |
+
(this._fill = 'none'),
|
| 3701 |
+
(this._iterationStart = 0),
|
| 3702 |
+
(this._iterations = 1),
|
| 3703 |
+
(this._duration = 0),
|
| 3704 |
+
(this._playbackRate = 1),
|
| 3705 |
+
(this._direction = 'normal'),
|
| 3706 |
+
(this._easing = 'linear'),
|
| 3707 |
+
(this._easingFunction = c)
|
| 3708 |
+
}
|
| 3709 |
+
function n() {
|
| 3710 |
+
return t.isDeprecated(
|
| 3711 |
+
'Invalid timing inputs',
|
| 3712 |
+
'2016-03-02',
|
| 3713 |
+
'TypeError exceptions will be thrown instead.',
|
| 3714 |
+
!0,
|
| 3715 |
+
)
|
| 3716 |
+
}
|
| 3717 |
+
function r(e, n, r) {
|
| 3718 |
+
var s = new i()
|
| 3719 |
+
return (
|
| 3720 |
+
n && ((s.fill = 'both'), (s.duration = 'auto')),
|
| 3721 |
+
'number' != typeof e || isNaN(e)
|
| 3722 |
+
? void 0 !== e &&
|
| 3723 |
+
Object.getOwnPropertyNames(e).forEach(function (i) {
|
| 3724 |
+
if ('auto' != e[i]) {
|
| 3725 |
+
if (
|
| 3726 |
+
('number' == typeof s[i] || 'duration' == i) &&
|
| 3727 |
+
('number' != typeof e[i] || isNaN(e[i]))
|
| 3728 |
+
)
|
| 3729 |
+
return
|
| 3730 |
+
if ('fill' == i && -1 == u.indexOf(e[i])) return
|
| 3731 |
+
if ('direction' == i && -1 == d.indexOf(e[i])) return
|
| 3732 |
+
if (
|
| 3733 |
+
'playbackRate' == i &&
|
| 3734 |
+
1 !== e[i] &&
|
| 3735 |
+
t.isDeprecated(
|
| 3736 |
+
'AnimationEffectTiming.playbackRate',
|
| 3737 |
+
'2014-11-28',
|
| 3738 |
+
'Use Animation.playbackRate instead.',
|
| 3739 |
+
)
|
| 3740 |
+
)
|
| 3741 |
+
return
|
| 3742 |
+
s[i] = e[i]
|
| 3743 |
+
}
|
| 3744 |
+
})
|
| 3745 |
+
: (s.duration = e),
|
| 3746 |
+
s
|
| 3747 |
+
)
|
| 3748 |
+
}
|
| 3749 |
+
function s(t, e, i, n) {
|
| 3750 |
+
return t < 0 || t > 1 || i < 0 || i > 1
|
| 3751 |
+
? c
|
| 3752 |
+
: function (r) {
|
| 3753 |
+
function s(t, e, i) {
|
| 3754 |
+
return 3 * t * (1 - i) * (1 - i) * i + 3 * e * (1 - i) * i * i + i * i * i
|
| 3755 |
+
}
|
| 3756 |
+
if (r <= 0) {
|
| 3757 |
+
var o = 0
|
| 3758 |
+
return t > 0 ? (o = e / t) : !e && i > 0 && (o = n / i), o * r
|
| 3759 |
+
}
|
| 3760 |
+
if (r >= 1) {
|
| 3761 |
+
var a = 0
|
| 3762 |
+
return (
|
| 3763 |
+
i < 1 ? (a = (n - 1) / (i - 1)) : 1 == i && t < 1 && (a = (e - 1) / (t - 1)),
|
| 3764 |
+
1 + a * (r - 1)
|
| 3765 |
+
)
|
| 3766 |
+
}
|
| 3767 |
+
for (var h = 0, l = 1; h < l; ) {
|
| 3768 |
+
var u = (h + l) / 2,
|
| 3769 |
+
d = s(t, i, u)
|
| 3770 |
+
if (Math.abs(r - d) < 1e-5) return s(e, n, u)
|
| 3771 |
+
d < r ? (h = u) : (l = u)
|
| 3772 |
+
}
|
| 3773 |
+
return s(e, n, u)
|
| 3774 |
+
}
|
| 3775 |
+
}
|
| 3776 |
+
function o(t, e) {
|
| 3777 |
+
return function (i) {
|
| 3778 |
+
if (i >= 1) return 1
|
| 3779 |
+
var n = 1 / t
|
| 3780 |
+
return (i += e * n) - (i % n)
|
| 3781 |
+
}
|
| 3782 |
+
}
|
| 3783 |
+
function a(t) {
|
| 3784 |
+
g || (g = document.createElement('div').style),
|
| 3785 |
+
(g.animationTimingFunction = ''),
|
| 3786 |
+
(g.animationTimingFunction = t)
|
| 3787 |
+
var e = g.animationTimingFunction
|
| 3788 |
+
if ('' == e && n()) throw new TypeError(t + ' is not a valid value for easing')
|
| 3789 |
+
return e
|
| 3790 |
+
}
|
| 3791 |
+
function h(t) {
|
| 3792 |
+
if ('linear' == t) return c
|
| 3793 |
+
var e = y.exec(t)
|
| 3794 |
+
if (e) return s.apply(this, e.slice(1).map(Number))
|
| 3795 |
+
var i = b.exec(t)
|
| 3796 |
+
if (i) return o(Number(i[1]), p)
|
| 3797 |
+
var n = w.exec(t)
|
| 3798 |
+
return n ? o(Number(n[1]), { start: _, middle: f, end: p }[n[2]]) : m[t] || c
|
| 3799 |
+
}
|
| 3800 |
+
function l(t, e, i) {
|
| 3801 |
+
if (null == e) return S
|
| 3802 |
+
var n = i.delay + t + i.endDelay
|
| 3803 |
+
return e < Math.min(i.delay, n) ? T : e >= Math.min(i.delay + t, n) ? D : x
|
| 3804 |
+
}
|
| 3805 |
+
var u = 'backwards|forwards|both|none'.split('|'),
|
| 3806 |
+
d = 'reverse|alternate|alternate-reverse'.split('|'),
|
| 3807 |
+
c = function (t) {
|
| 3808 |
+
return t
|
| 3809 |
+
}
|
| 3810 |
+
i.prototype = {
|
| 3811 |
+
_setMember: function (e, i) {
|
| 3812 |
+
;(this['_' + e] = i),
|
| 3813 |
+
this._effect &&
|
| 3814 |
+
((this._effect._timingInput[e] = i),
|
| 3815 |
+
(this._effect._timing = t.normalizeTimingInput(this._effect._timingInput)),
|
| 3816 |
+
(this._effect.activeDuration = t.calculateActiveDuration(this._effect._timing)),
|
| 3817 |
+
this._effect._animation && this._effect._animation._rebuildUnderlyingAnimation())
|
| 3818 |
+
},
|
| 3819 |
+
get playbackRate() {
|
| 3820 |
+
return this._playbackRate
|
| 3821 |
+
},
|
| 3822 |
+
set delay(t) {
|
| 3823 |
+
this._setMember('delay', t)
|
| 3824 |
+
},
|
| 3825 |
+
get delay() {
|
| 3826 |
+
return this._delay
|
| 3827 |
+
},
|
| 3828 |
+
set endDelay(t) {
|
| 3829 |
+
this._setMember('endDelay', t)
|
| 3830 |
+
},
|
| 3831 |
+
get endDelay() {
|
| 3832 |
+
return this._endDelay
|
| 3833 |
+
},
|
| 3834 |
+
set fill(t) {
|
| 3835 |
+
this._setMember('fill', t)
|
| 3836 |
+
},
|
| 3837 |
+
get fill() {
|
| 3838 |
+
return this._fill
|
| 3839 |
+
},
|
| 3840 |
+
set iterationStart(t) {
|
| 3841 |
+
if ((isNaN(t) || t < 0) && n())
|
| 3842 |
+
throw new TypeError('iterationStart must be a non-negative number, received: ' + t)
|
| 3843 |
+
this._setMember('iterationStart', t)
|
| 3844 |
+
},
|
| 3845 |
+
get iterationStart() {
|
| 3846 |
+
return this._iterationStart
|
| 3847 |
+
},
|
| 3848 |
+
set duration(t) {
|
| 3849 |
+
if ('auto' != t && (isNaN(t) || t < 0) && n())
|
| 3850 |
+
throw new TypeError('duration must be non-negative or auto, received: ' + t)
|
| 3851 |
+
this._setMember('duration', t)
|
| 3852 |
+
},
|
| 3853 |
+
get duration() {
|
| 3854 |
+
return this._duration
|
| 3855 |
+
},
|
| 3856 |
+
set direction(t) {
|
| 3857 |
+
this._setMember('direction', t)
|
| 3858 |
+
},
|
| 3859 |
+
get direction() {
|
| 3860 |
+
return this._direction
|
| 3861 |
+
},
|
| 3862 |
+
set easing(t) {
|
| 3863 |
+
;(this._easingFunction = h(a(t))), this._setMember('easing', t)
|
| 3864 |
+
},
|
| 3865 |
+
get easing() {
|
| 3866 |
+
return this._easing
|
| 3867 |
+
},
|
| 3868 |
+
set iterations(t) {
|
| 3869 |
+
if ((isNaN(t) || t < 0) && n())
|
| 3870 |
+
throw new TypeError('iterations must be non-negative, received: ' + t)
|
| 3871 |
+
this._setMember('iterations', t)
|
| 3872 |
+
},
|
| 3873 |
+
get iterations() {
|
| 3874 |
+
return this._iterations
|
| 3875 |
+
},
|
| 3876 |
+
}
|
| 3877 |
+
var _ = 1,
|
| 3878 |
+
f = 0.5,
|
| 3879 |
+
p = 0,
|
| 3880 |
+
m = {
|
| 3881 |
+
ease: s(0.25, 0.1, 0.25, 1),
|
| 3882 |
+
'ease-in': s(0.42, 0, 1, 1),
|
| 3883 |
+
'ease-out': s(0, 0, 0.58, 1),
|
| 3884 |
+
'ease-in-out': s(0.42, 0, 0.58, 1),
|
| 3885 |
+
'step-start': o(1, _),
|
| 3886 |
+
'step-middle': o(1, f),
|
| 3887 |
+
'step-end': o(1, p),
|
| 3888 |
+
},
|
| 3889 |
+
g = null,
|
| 3890 |
+
v = '\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*',
|
| 3891 |
+
y = new RegExp('cubic-bezier\\(' + v + ',' + v + ',' + v + ',' + v + '\\)'),
|
| 3892 |
+
b = /steps\(\s*(\d+)\s*\)/,
|
| 3893 |
+
w = /steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,
|
| 3894 |
+
S = 0,
|
| 3895 |
+
T = 1,
|
| 3896 |
+
D = 2,
|
| 3897 |
+
x = 3
|
| 3898 |
+
;(t.cloneTimingInput = function (t) {
|
| 3899 |
+
if ('number' == typeof t) return t
|
| 3900 |
+
var e = {}
|
| 3901 |
+
for (var i in t) e[i] = t[i]
|
| 3902 |
+
return e
|
| 3903 |
+
}),
|
| 3904 |
+
(t.makeTiming = r),
|
| 3905 |
+
(t.numericTimingToObject = function (t) {
|
| 3906 |
+
return 'number' == typeof t && (t = isNaN(t) ? { duration: 0 } : { duration: t }), t
|
| 3907 |
+
}),
|
| 3908 |
+
(t.normalizeTimingInput = function (e, i) {
|
| 3909 |
+
return r((e = t.numericTimingToObject(e)), i)
|
| 3910 |
+
}),
|
| 3911 |
+
(t.calculateActiveDuration = function (t) {
|
| 3912 |
+
return Math.abs(
|
| 3913 |
+
(function (t) {
|
| 3914 |
+
return 0 === t.duration || 0 === t.iterations ? 0 : t.duration * t.iterations
|
| 3915 |
+
})(t) / t.playbackRate,
|
| 3916 |
+
)
|
| 3917 |
+
}),
|
| 3918 |
+
(t.calculateIterationProgress = function (t, e, i) {
|
| 3919 |
+
var n = l(t, e, i),
|
| 3920 |
+
r = (function (t, e, i, n, r) {
|
| 3921 |
+
switch (n) {
|
| 3922 |
+
case T:
|
| 3923 |
+
return 'backwards' == e || 'both' == e ? 0 : null
|
| 3924 |
+
case x:
|
| 3925 |
+
return i - r
|
| 3926 |
+
case D:
|
| 3927 |
+
return 'forwards' == e || 'both' == e ? t : null
|
| 3928 |
+
case S:
|
| 3929 |
+
return null
|
| 3930 |
+
}
|
| 3931 |
+
})(t, i.fill, e, n, i.delay)
|
| 3932 |
+
if (null === r) return null
|
| 3933 |
+
var s = (function (t, e, i, n, r) {
|
| 3934 |
+
var s = r
|
| 3935 |
+
return 0 === t ? e !== T && (s += i) : (s += n / t), s
|
| 3936 |
+
})(i.duration, n, i.iterations, r, i.iterationStart),
|
| 3937 |
+
o = (function (t, e, i, n, r, s) {
|
| 3938 |
+
var o = t === 1 / 0 ? e % 1 : t % 1
|
| 3939 |
+
return 0 !== o || i !== D || 0 === n || (0 === r && 0 !== s) || (o = 1), o
|
| 3940 |
+
})(s, i.iterationStart, n, i.iterations, r, i.duration),
|
| 3941 |
+
a = (function (t, e, i, n) {
|
| 3942 |
+
return t === D && e === 1 / 0 ? 1 / 0 : 1 === i ? Math.floor(n) - 1 : Math.floor(n)
|
| 3943 |
+
})(n, i.iterations, o, s),
|
| 3944 |
+
h = (function (t, e, i) {
|
| 3945 |
+
var n = t
|
| 3946 |
+
if ('normal' !== t && 'reverse' !== t) {
|
| 3947 |
+
var r = e
|
| 3948 |
+
'alternate-reverse' === t && (r += 1),
|
| 3949 |
+
(n = 'normal'),
|
| 3950 |
+
r !== 1 / 0 && r % 2 != 0 && (n = 'reverse')
|
| 3951 |
+
}
|
| 3952 |
+
return 'normal' === n ? i : 1 - i
|
| 3953 |
+
})(i.direction, a, o)
|
| 3954 |
+
return i._easingFunction(h)
|
| 3955 |
+
}),
|
| 3956 |
+
(t.calculatePhase = l),
|
| 3957 |
+
(t.normalizeEasing = a),
|
| 3958 |
+
(t.parseEasingFunction = h)
|
| 3959 |
+
})((ni = {})),
|
| 3960 |
+
(function (t, e) {
|
| 3961 |
+
function i(t, e) {
|
| 3962 |
+
return (t in h && h[t][e]) || e
|
| 3963 |
+
}
|
| 3964 |
+
function n(t, e, n) {
|
| 3965 |
+
if (
|
| 3966 |
+
!(function (t) {
|
| 3967 |
+
return (
|
| 3968 |
+
'display' === t ||
|
| 3969 |
+
0 === t.lastIndexOf('animation', 0) ||
|
| 3970 |
+
0 === t.lastIndexOf('transition', 0)
|
| 3971 |
+
)
|
| 3972 |
+
})(t)
|
| 3973 |
+
) {
|
| 3974 |
+
var r = s[t]
|
| 3975 |
+
if (r)
|
| 3976 |
+
for (var a in ((o.style[t] = e), r)) {
|
| 3977 |
+
var h = r[a],
|
| 3978 |
+
l = o.style[h]
|
| 3979 |
+
n[h] = i(h, l)
|
| 3980 |
+
}
|
| 3981 |
+
else n[t] = i(t, e)
|
| 3982 |
+
}
|
| 3983 |
+
}
|
| 3984 |
+
function r(t) {
|
| 3985 |
+
var e = []
|
| 3986 |
+
for (var i in t)
|
| 3987 |
+
if (!(i in ['easing', 'offset', 'composite'])) {
|
| 3988 |
+
var n = t[i]
|
| 3989 |
+
Array.isArray(n) || (n = [n])
|
| 3990 |
+
for (var r, s = n.length, o = 0; o < s; o++)
|
| 3991 |
+
((r = {}).offset = 'offset' in t ? t.offset : 1 == s ? 1 : o / (s - 1)),
|
| 3992 |
+
'easing' in t && (r.easing = t.easing),
|
| 3993 |
+
'composite' in t && (r.composite = t.composite),
|
| 3994 |
+
(r[i] = n[o]),
|
| 3995 |
+
e.push(r)
|
| 3996 |
+
}
|
| 3997 |
+
return (
|
| 3998 |
+
e.sort(function (t, e) {
|
| 3999 |
+
return t.offset - e.offset
|
| 4000 |
+
}),
|
| 4001 |
+
e
|
| 4002 |
+
)
|
| 4003 |
+
}
|
| 4004 |
+
var s = {
|
| 4005 |
+
background: [
|
| 4006 |
+
'backgroundImage',
|
| 4007 |
+
'backgroundPosition',
|
| 4008 |
+
'backgroundSize',
|
| 4009 |
+
'backgroundRepeat',
|
| 4010 |
+
'backgroundAttachment',
|
| 4011 |
+
'backgroundOrigin',
|
| 4012 |
+
'backgroundClip',
|
| 4013 |
+
'backgroundColor',
|
| 4014 |
+
],
|
| 4015 |
+
border: [
|
| 4016 |
+
'borderTopColor',
|
| 4017 |
+
'borderTopStyle',
|
| 4018 |
+
'borderTopWidth',
|
| 4019 |
+
'borderRightColor',
|
| 4020 |
+
'borderRightStyle',
|
| 4021 |
+
'borderRightWidth',
|
| 4022 |
+
'borderBottomColor',
|
| 4023 |
+
'borderBottomStyle',
|
| 4024 |
+
'borderBottomWidth',
|
| 4025 |
+
'borderLeftColor',
|
| 4026 |
+
'borderLeftStyle',
|
| 4027 |
+
'borderLeftWidth',
|
| 4028 |
+
],
|
| 4029 |
+
borderBottom: ['borderBottomWidth', 'borderBottomStyle', 'borderBottomColor'],
|
| 4030 |
+
borderColor: ['borderTopColor', 'borderRightColor', 'borderBottomColor', 'borderLeftColor'],
|
| 4031 |
+
borderLeft: ['borderLeftWidth', 'borderLeftStyle', 'borderLeftColor'],
|
| 4032 |
+
borderRadius: [
|
| 4033 |
+
'borderTopLeftRadius',
|
| 4034 |
+
'borderTopRightRadius',
|
| 4035 |
+
'borderBottomRightRadius',
|
| 4036 |
+
'borderBottomLeftRadius',
|
| 4037 |
+
],
|
| 4038 |
+
borderRight: ['borderRightWidth', 'borderRightStyle', 'borderRightColor'],
|
| 4039 |
+
borderTop: ['borderTopWidth', 'borderTopStyle', 'borderTopColor'],
|
| 4040 |
+
borderWidth: ['borderTopWidth', 'borderRightWidth', 'borderBottomWidth', 'borderLeftWidth'],
|
| 4041 |
+
flex: ['flexGrow', 'flexShrink', 'flexBasis'],
|
| 4042 |
+
font: ['fontFamily', 'fontSize', 'fontStyle', 'fontVariant', 'fontWeight', 'lineHeight'],
|
| 4043 |
+
margin: ['marginTop', 'marginRight', 'marginBottom', 'marginLeft'],
|
| 4044 |
+
outline: ['outlineColor', 'outlineStyle', 'outlineWidth'],
|
| 4045 |
+
padding: ['paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft'],
|
| 4046 |
+
},
|
| 4047 |
+
o = document.createElementNS('http://www.w3.org/1999/xhtml', 'div'),
|
| 4048 |
+
a = { thin: '1px', medium: '3px', thick: '5px' },
|
| 4049 |
+
h = {
|
| 4050 |
+
borderBottomWidth: a,
|
| 4051 |
+
borderLeftWidth: a,
|
| 4052 |
+
borderRightWidth: a,
|
| 4053 |
+
borderTopWidth: a,
|
| 4054 |
+
fontSize: {
|
| 4055 |
+
'xx-small': '60%',
|
| 4056 |
+
'x-small': '75%',
|
| 4057 |
+
small: '89%',
|
| 4058 |
+
medium: '100%',
|
| 4059 |
+
large: '120%',
|
| 4060 |
+
'x-large': '150%',
|
| 4061 |
+
'xx-large': '200%',
|
| 4062 |
+
},
|
| 4063 |
+
fontWeight: { normal: '400', bold: '700' },
|
| 4064 |
+
outlineWidth: a,
|
| 4065 |
+
textShadow: { none: '0px 0px 0px transparent' },
|
| 4066 |
+
boxShadow: { none: '0px 0px 0px 0px transparent' },
|
| 4067 |
+
}
|
| 4068 |
+
;(t.convertToArrayForm = r),
|
| 4069 |
+
(t.normalizeKeyframes = function (e) {
|
| 4070 |
+
if (null == e) return []
|
| 4071 |
+
window.Symbol &&
|
| 4072 |
+
Symbol.iterator &&
|
| 4073 |
+
Array.prototype.from &&
|
| 4074 |
+
e[Symbol.iterator] &&
|
| 4075 |
+
(e = Array.from(e)),
|
| 4076 |
+
Array.isArray(e) || (e = r(e))
|
| 4077 |
+
for (
|
| 4078 |
+
var i = e.map(function (e) {
|
| 4079 |
+
var i = {}
|
| 4080 |
+
for (var r in e) {
|
| 4081 |
+
var s = e[r]
|
| 4082 |
+
if ('offset' == r) {
|
| 4083 |
+
if (null != s) {
|
| 4084 |
+
if (((s = Number(s)), !isFinite(s)))
|
| 4085 |
+
throw new TypeError('Keyframe offsets must be numbers.')
|
| 4086 |
+
if (s < 0 || s > 1)
|
| 4087 |
+
throw new TypeError('Keyframe offsets must be between 0 and 1.')
|
| 4088 |
+
}
|
| 4089 |
+
} else if ('composite' == r) {
|
| 4090 |
+
if ('add' == s || 'accumulate' == s)
|
| 4091 |
+
throw {
|
| 4092 |
+
type: DOMException.NOT_SUPPORTED_ERR,
|
| 4093 |
+
name: 'NotSupportedError',
|
| 4094 |
+
message: 'add compositing is not supported',
|
| 4095 |
+
}
|
| 4096 |
+
if ('replace' != s) throw new TypeError('Invalid composite mode ' + s + '.')
|
| 4097 |
+
} else s = 'easing' == r ? t.normalizeEasing(s) : '' + s
|
| 4098 |
+
n(r, s, i)
|
| 4099 |
+
}
|
| 4100 |
+
return (
|
| 4101 |
+
null == i.offset && (i.offset = null), null == i.easing && (i.easing = 'linear'), i
|
| 4102 |
+
)
|
| 4103 |
+
}),
|
| 4104 |
+
s = !0,
|
| 4105 |
+
o = -1 / 0,
|
| 4106 |
+
a = 0;
|
| 4107 |
+
a < i.length;
|
| 4108 |
+
a++
|
| 4109 |
+
) {
|
| 4110 |
+
var h = i[a].offset
|
| 4111 |
+
if (null != h) {
|
| 4112 |
+
if (h < o)
|
| 4113 |
+
throw new TypeError(
|
| 4114 |
+
'Keyframes are not loosely sorted by offset. Sort or specify offsets.',
|
| 4115 |
+
)
|
| 4116 |
+
o = h
|
| 4117 |
+
} else s = !1
|
| 4118 |
+
}
|
| 4119 |
+
return (
|
| 4120 |
+
(i = i.filter(function (t) {
|
| 4121 |
+
return t.offset >= 0 && t.offset <= 1
|
| 4122 |
+
})),
|
| 4123 |
+
s ||
|
| 4124 |
+
(function () {
|
| 4125 |
+
var t = i.length
|
| 4126 |
+
null == i[t - 1].offset && (i[t - 1].offset = 1),
|
| 4127 |
+
t > 1 && null == i[0].offset && (i[0].offset = 0)
|
| 4128 |
+
for (var e = 0, n = i[0].offset, r = 1; r < t; r++) {
|
| 4129 |
+
var s = i[r].offset
|
| 4130 |
+
if (null != s) {
|
| 4131 |
+
for (var o = 1; o < r - e; o++) i[e + o].offset = n + ((s - n) * o) / (r - e)
|
| 4132 |
+
;(e = r), (n = s)
|
| 4133 |
+
}
|
| 4134 |
+
}
|
| 4135 |
+
})(),
|
| 4136 |
+
i
|
| 4137 |
+
)
|
| 4138 |
+
})
|
| 4139 |
+
})(ni),
|
| 4140 |
+
(function (t) {
|
| 4141 |
+
var e = {}
|
| 4142 |
+
;(t.isDeprecated = function (t, i, n, r) {
|
| 4143 |
+
var s = r ? 'are' : 'is',
|
| 4144 |
+
o = new Date(),
|
| 4145 |
+
a = new Date(i)
|
| 4146 |
+
return (
|
| 4147 |
+
a.setMonth(a.getMonth() + 3),
|
| 4148 |
+
!(
|
| 4149 |
+
o < a &&
|
| 4150 |
+
(t in e ||
|
| 4151 |
+
console.warn(
|
| 4152 |
+
'Web Animations: ' +
|
| 4153 |
+
t +
|
| 4154 |
+
' ' +
|
| 4155 |
+
s +
|
| 4156 |
+
' deprecated and will stop working on ' +
|
| 4157 |
+
a.toDateString() +
|
| 4158 |
+
'. ' +
|
| 4159 |
+
n,
|
| 4160 |
+
),
|
| 4161 |
+
(e[t] = !0),
|
| 4162 |
+
1)
|
| 4163 |
+
)
|
| 4164 |
+
)
|
| 4165 |
+
}),
|
| 4166 |
+
(t.deprecated = function (e, i, n, r) {
|
| 4167 |
+
var s = r ? 'are' : 'is'
|
| 4168 |
+
if (t.isDeprecated(e, i, n, r)) throw new Error(e + ' ' + s + ' no longer supported. ' + n)
|
| 4169 |
+
})
|
| 4170 |
+
})(ni),
|
| 4171 |
+
(function () {
|
| 4172 |
+
if (document.documentElement.animate) {
|
| 4173 |
+
var t = document.documentElement.animate([], 0),
|
| 4174 |
+
e = !0
|
| 4175 |
+
if (
|
| 4176 |
+
(t &&
|
| 4177 |
+
((e = !1),
|
| 4178 |
+
'play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState'
|
| 4179 |
+
.split('|')
|
| 4180 |
+
.forEach(function (i) {
|
| 4181 |
+
void 0 === t[i] && (e = !0)
|
| 4182 |
+
})),
|
| 4183 |
+
!e)
|
| 4184 |
+
)
|
| 4185 |
+
return
|
| 4186 |
+
}
|
| 4187 |
+
!(function (t, e, i) {
|
| 4188 |
+
e.convertEffectInput = function (i) {
|
| 4189 |
+
var n = (function (t) {
|
| 4190 |
+
for (var e = {}, i = 0; i < t.length; i++)
|
| 4191 |
+
for (var n in t[i])
|
| 4192 |
+
if ('offset' != n && 'easing' != n && 'composite' != n) {
|
| 4193 |
+
var r = { offset: t[i].offset, easing: t[i].easing, value: t[i][n] }
|
| 4194 |
+
;(e[n] = e[n] || []), e[n].push(r)
|
| 4195 |
+
}
|
| 4196 |
+
for (var s in e) {
|
| 4197 |
+
var o = e[s]
|
| 4198 |
+
if (0 != o[0].offset || 1 != o[o.length - 1].offset)
|
| 4199 |
+
throw {
|
| 4200 |
+
type: DOMException.NOT_SUPPORTED_ERR,
|
| 4201 |
+
name: 'NotSupportedError',
|
| 4202 |
+
message: 'Partial keyframes are not supported',
|
| 4203 |
+
}
|
| 4204 |
+
}
|
| 4205 |
+
return e
|
| 4206 |
+
})(t.normalizeKeyframes(i)),
|
| 4207 |
+
r = (function (i) {
|
| 4208 |
+
var n = []
|
| 4209 |
+
for (var r in i)
|
| 4210 |
+
for (var s = i[r], o = 0; o < s.length - 1; o++) {
|
| 4211 |
+
var a = o,
|
| 4212 |
+
h = o + 1,
|
| 4213 |
+
l = s[a].offset,
|
| 4214 |
+
u = s[h].offset,
|
| 4215 |
+
d = l,
|
| 4216 |
+
c = u
|
| 4217 |
+
0 == o && ((d = -1 / 0), 0 == u && (h = a)),
|
| 4218 |
+
o == s.length - 2 && ((c = 1 / 0), 1 == l && (a = h)),
|
| 4219 |
+
n.push({
|
| 4220 |
+
applyFrom: d,
|
| 4221 |
+
applyTo: c,
|
| 4222 |
+
startOffset: s[a].offset,
|
| 4223 |
+
endOffset: s[h].offset,
|
| 4224 |
+
easingFunction: t.parseEasingFunction(s[a].easing),
|
| 4225 |
+
property: r,
|
| 4226 |
+
interpolation: e.propertyInterpolation(r, s[a].value, s[h].value),
|
| 4227 |
+
})
|
| 4228 |
+
}
|
| 4229 |
+
return (
|
| 4230 |
+
n.sort(function (t, e) {
|
| 4231 |
+
return t.startOffset - e.startOffset
|
| 4232 |
+
}),
|
| 4233 |
+
n
|
| 4234 |
+
)
|
| 4235 |
+
})(n)
|
| 4236 |
+
return function (t, i) {
|
| 4237 |
+
if (null != i)
|
| 4238 |
+
r.filter(function (t) {
|
| 4239 |
+
return i >= t.applyFrom && i < t.applyTo
|
| 4240 |
+
}).forEach(function (n) {
|
| 4241 |
+
var r = i - n.startOffset,
|
| 4242 |
+
s = n.endOffset - n.startOffset,
|
| 4243 |
+
o = 0 == s ? 0 : n.easingFunction(r / s)
|
| 4244 |
+
e.apply(t, n.property, n.interpolation(o))
|
| 4245 |
+
})
|
| 4246 |
+
else for (var s in n) 'offset' != s && 'easing' != s && 'composite' != s && e.clear(t, s)
|
| 4247 |
+
}
|
| 4248 |
+
}
|
| 4249 |
+
})(ni, ri),
|
| 4250 |
+
(function (t, e, i) {
|
| 4251 |
+
function n(t) {
|
| 4252 |
+
return t.replace(/-(.)/g, function (t, e) {
|
| 4253 |
+
return e.toUpperCase()
|
| 4254 |
+
})
|
| 4255 |
+
}
|
| 4256 |
+
function r(t, e, i) {
|
| 4257 |
+
;(s[i] = s[i] || []), s[i].push([t, e])
|
| 4258 |
+
}
|
| 4259 |
+
var s = {}
|
| 4260 |
+
e.addPropertiesHandler = function (t, e, i) {
|
| 4261 |
+
for (var s = 0; s < i.length; s++) r(t, e, n(i[s]))
|
| 4262 |
+
}
|
| 4263 |
+
var o = {
|
| 4264 |
+
backgroundColor: 'transparent',
|
| 4265 |
+
backgroundPosition: '0% 0%',
|
| 4266 |
+
borderBottomColor: 'currentColor',
|
| 4267 |
+
borderBottomLeftRadius: '0px',
|
| 4268 |
+
borderBottomRightRadius: '0px',
|
| 4269 |
+
borderBottomWidth: '3px',
|
| 4270 |
+
borderLeftColor: 'currentColor',
|
| 4271 |
+
borderLeftWidth: '3px',
|
| 4272 |
+
borderRightColor: 'currentColor',
|
| 4273 |
+
borderRightWidth: '3px',
|
| 4274 |
+
borderSpacing: '2px',
|
| 4275 |
+
borderTopColor: 'currentColor',
|
| 4276 |
+
borderTopLeftRadius: '0px',
|
| 4277 |
+
borderTopRightRadius: '0px',
|
| 4278 |
+
borderTopWidth: '3px',
|
| 4279 |
+
bottom: 'auto',
|
| 4280 |
+
clip: 'rect(0px, 0px, 0px, 0px)',
|
| 4281 |
+
color: 'black',
|
| 4282 |
+
fontSize: '100%',
|
| 4283 |
+
fontWeight: '400',
|
| 4284 |
+
height: 'auto',
|
| 4285 |
+
left: 'auto',
|
| 4286 |
+
letterSpacing: 'normal',
|
| 4287 |
+
lineHeight: '120%',
|
| 4288 |
+
marginBottom: '0px',
|
| 4289 |
+
marginLeft: '0px',
|
| 4290 |
+
marginRight: '0px',
|
| 4291 |
+
marginTop: '0px',
|
| 4292 |
+
maxHeight: 'none',
|
| 4293 |
+
maxWidth: 'none',
|
| 4294 |
+
minHeight: '0px',
|
| 4295 |
+
minWidth: '0px',
|
| 4296 |
+
opacity: '1.0',
|
| 4297 |
+
outlineColor: 'invert',
|
| 4298 |
+
outlineOffset: '0px',
|
| 4299 |
+
outlineWidth: '3px',
|
| 4300 |
+
paddingBottom: '0px',
|
| 4301 |
+
paddingLeft: '0px',
|
| 4302 |
+
paddingRight: '0px',
|
| 4303 |
+
paddingTop: '0px',
|
| 4304 |
+
right: 'auto',
|
| 4305 |
+
strokeDasharray: 'none',
|
| 4306 |
+
strokeDashoffset: '0px',
|
| 4307 |
+
textIndent: '0px',
|
| 4308 |
+
textShadow: '0px 0px 0px transparent',
|
| 4309 |
+
top: 'auto',
|
| 4310 |
+
transform: '',
|
| 4311 |
+
verticalAlign: '0px',
|
| 4312 |
+
visibility: 'visible',
|
| 4313 |
+
width: 'auto',
|
| 4314 |
+
wordSpacing: 'normal',
|
| 4315 |
+
zIndex: 'auto',
|
| 4316 |
+
}
|
| 4317 |
+
e.propertyInterpolation = function (i, r, a) {
|
| 4318 |
+
var h = i
|
| 4319 |
+
;/-/.test(i) &&
|
| 4320 |
+
!t.isDeprecated('Hyphenated property names', '2016-03-22', 'Use camelCase instead.', !0) &&
|
| 4321 |
+
(h = n(i)),
|
| 4322 |
+
('initial' != r && 'initial' != a) ||
|
| 4323 |
+
('initial' == r && (r = o[h]), 'initial' == a && (a = o[h]))
|
| 4324 |
+
for (var l = r == a ? [] : s[h], u = 0; l && u < l.length; u++) {
|
| 4325 |
+
var d = l[u][0](r),
|
| 4326 |
+
c = l[u][0](a)
|
| 4327 |
+
if (void 0 !== d && void 0 !== c) {
|
| 4328 |
+
var _ = l[u][1](d, c)
|
| 4329 |
+
if (_) {
|
| 4330 |
+
var f = e.Interpolation.apply(null, _)
|
| 4331 |
+
return function (t) {
|
| 4332 |
+
return 0 == t ? r : 1 == t ? a : f(t)
|
| 4333 |
+
}
|
| 4334 |
+
}
|
| 4335 |
+
}
|
| 4336 |
+
}
|
| 4337 |
+
return e.Interpolation(!1, !0, function (t) {
|
| 4338 |
+
return t ? a : r
|
| 4339 |
+
})
|
| 4340 |
+
}
|
| 4341 |
+
})(ni, ri),
|
| 4342 |
+
(function (t, e, i) {
|
| 4343 |
+
e.KeyframeEffect = function (i, n, r, s) {
|
| 4344 |
+
var o,
|
| 4345 |
+
a = (function (e) {
|
| 4346 |
+
var i = t.calculateActiveDuration(e),
|
| 4347 |
+
n = function (n) {
|
| 4348 |
+
return t.calculateIterationProgress(i, n, e)
|
| 4349 |
+
}
|
| 4350 |
+
return (n._totalDuration = e.delay + i + e.endDelay), n
|
| 4351 |
+
})(t.normalizeTimingInput(r)),
|
| 4352 |
+
h = e.convertEffectInput(n),
|
| 4353 |
+
l = function () {
|
| 4354 |
+
h(i, o)
|
| 4355 |
+
}
|
| 4356 |
+
return (
|
| 4357 |
+
(l._update = function (t) {
|
| 4358 |
+
return null !== (o = a(t))
|
| 4359 |
+
}),
|
| 4360 |
+
(l._clear = function () {
|
| 4361 |
+
h(i, null)
|
| 4362 |
+
}),
|
| 4363 |
+
(l._hasSameTarget = function (t) {
|
| 4364 |
+
return i === t
|
| 4365 |
+
}),
|
| 4366 |
+
(l._target = i),
|
| 4367 |
+
(l._totalDuration = a._totalDuration),
|
| 4368 |
+
(l._id = s),
|
| 4369 |
+
l
|
| 4370 |
+
)
|
| 4371 |
+
}
|
| 4372 |
+
})(ni, ri),
|
| 4373 |
+
(function (t, e) {
|
| 4374 |
+
function i(t, e, i) {
|
| 4375 |
+
;(i.enumerable = !0), (i.configurable = !0), Object.defineProperty(t, e, i)
|
| 4376 |
+
}
|
| 4377 |
+
function n(t) {
|
| 4378 |
+
;(this._element = t),
|
| 4379 |
+
(this._surrogateStyle = document.createElementNS(
|
| 4380 |
+
'http://www.w3.org/1999/xhtml',
|
| 4381 |
+
'div',
|
| 4382 |
+
).style),
|
| 4383 |
+
(this._style = t.style),
|
| 4384 |
+
(this._length = 0),
|
| 4385 |
+
(this._isAnimatedProperty = {}),
|
| 4386 |
+
(this._updateSvgTransformAttr = (function (t, e) {
|
| 4387 |
+
return (
|
| 4388 |
+
!(!e.namespaceURI || -1 == e.namespaceURI.indexOf('/svg')) &&
|
| 4389 |
+
(s in t ||
|
| 4390 |
+
(t[s] = /Trident|MSIE|IEMobile|Edge|Android 4/i.test(t.navigator.userAgent)),
|
| 4391 |
+
t[s])
|
| 4392 |
+
)
|
| 4393 |
+
})(window, t)),
|
| 4394 |
+
(this._savedTransformAttr = null)
|
| 4395 |
+
for (var e = 0; e < this._style.length; e++) {
|
| 4396 |
+
var i = this._style[e]
|
| 4397 |
+
this._surrogateStyle[i] = this._style[i]
|
| 4398 |
+
}
|
| 4399 |
+
this._updateIndices()
|
| 4400 |
+
}
|
| 4401 |
+
function r(t) {
|
| 4402 |
+
if (!t._webAnimationsPatchedStyle) {
|
| 4403 |
+
var e = new n(t)
|
| 4404 |
+
try {
|
| 4405 |
+
i(t, 'style', {
|
| 4406 |
+
get: function () {
|
| 4407 |
+
return e
|
| 4408 |
+
},
|
| 4409 |
+
})
|
| 4410 |
+
} catch (e) {
|
| 4411 |
+
;(t.style._set = function (e, i) {
|
| 4412 |
+
t.style[e] = i
|
| 4413 |
+
}),
|
| 4414 |
+
(t.style._clear = function (e) {
|
| 4415 |
+
t.style[e] = ''
|
| 4416 |
+
})
|
| 4417 |
+
}
|
| 4418 |
+
t._webAnimationsPatchedStyle = t.style
|
| 4419 |
+
}
|
| 4420 |
+
}
|
| 4421 |
+
var s = '_webAnimationsUpdateSvgTransformAttr',
|
| 4422 |
+
o = { cssText: 1, length: 1, parentRule: 1 },
|
| 4423 |
+
a = {
|
| 4424 |
+
getPropertyCSSValue: 1,
|
| 4425 |
+
getPropertyPriority: 1,
|
| 4426 |
+
getPropertyValue: 1,
|
| 4427 |
+
item: 1,
|
| 4428 |
+
removeProperty: 1,
|
| 4429 |
+
setProperty: 1,
|
| 4430 |
+
},
|
| 4431 |
+
h = { removeProperty: 1, setProperty: 1 }
|
| 4432 |
+
for (var l in ((n.prototype = {
|
| 4433 |
+
get cssText() {
|
| 4434 |
+
return this._surrogateStyle.cssText
|
| 4435 |
+
},
|
| 4436 |
+
set cssText(t) {
|
| 4437 |
+
for (var e = {}, i = 0; i < this._surrogateStyle.length; i++)
|
| 4438 |
+
e[this._surrogateStyle[i]] = !0
|
| 4439 |
+
for (
|
| 4440 |
+
this._surrogateStyle.cssText = t, this._updateIndices(), i = 0;
|
| 4441 |
+
i < this._surrogateStyle.length;
|
| 4442 |
+
i++
|
| 4443 |
+
)
|
| 4444 |
+
e[this._surrogateStyle[i]] = !0
|
| 4445 |
+
for (var n in e)
|
| 4446 |
+
this._isAnimatedProperty[n] ||
|
| 4447 |
+
this._style.setProperty(n, this._surrogateStyle.getPropertyValue(n))
|
| 4448 |
+
},
|
| 4449 |
+
get length() {
|
| 4450 |
+
return this._surrogateStyle.length
|
| 4451 |
+
},
|
| 4452 |
+
get parentRule() {
|
| 4453 |
+
return this._style.parentRule
|
| 4454 |
+
},
|
| 4455 |
+
_updateIndices: function () {
|
| 4456 |
+
for (; this._length < this._surrogateStyle.length; )
|
| 4457 |
+
Object.defineProperty(this, this._length, {
|
| 4458 |
+
configurable: !0,
|
| 4459 |
+
enumerable: !1,
|
| 4460 |
+
get: (function (t) {
|
| 4461 |
+
return function () {
|
| 4462 |
+
return this._surrogateStyle[t]
|
| 4463 |
+
}
|
| 4464 |
+
})(this._length),
|
| 4465 |
+
}),
|
| 4466 |
+
this._length++
|
| 4467 |
+
for (; this._length > this._surrogateStyle.length; )
|
| 4468 |
+
this._length--,
|
| 4469 |
+
Object.defineProperty(this, this._length, {
|
| 4470 |
+
configurable: !0,
|
| 4471 |
+
enumerable: !1,
|
| 4472 |
+
value: void 0,
|
| 4473 |
+
})
|
| 4474 |
+
},
|
| 4475 |
+
_set: function (e, i) {
|
| 4476 |
+
;(this._style[e] = i),
|
| 4477 |
+
(this._isAnimatedProperty[e] = !0),
|
| 4478 |
+
this._updateSvgTransformAttr &&
|
| 4479 |
+
'transform' == t.unprefixedPropertyName(e) &&
|
| 4480 |
+
(null == this._savedTransformAttr &&
|
| 4481 |
+
(this._savedTransformAttr = this._element.getAttribute('transform')),
|
| 4482 |
+
this._element.setAttribute('transform', t.transformToSvgMatrix(i)))
|
| 4483 |
+
},
|
| 4484 |
+
_clear: function (e) {
|
| 4485 |
+
;(this._style[e] = this._surrogateStyle[e]),
|
| 4486 |
+
this._updateSvgTransformAttr &&
|
| 4487 |
+
'transform' == t.unprefixedPropertyName(e) &&
|
| 4488 |
+
(this._savedTransformAttr
|
| 4489 |
+
? this._element.setAttribute('transform', this._savedTransformAttr)
|
| 4490 |
+
: this._element.removeAttribute('transform'),
|
| 4491 |
+
(this._savedTransformAttr = null)),
|
| 4492 |
+
delete this._isAnimatedProperty[e]
|
| 4493 |
+
},
|
| 4494 |
+
}),
|
| 4495 |
+
a))
|
| 4496 |
+
n.prototype[l] = (function (t, e) {
|
| 4497 |
+
return function () {
|
| 4498 |
+
var i = this._surrogateStyle[t].apply(this._surrogateStyle, arguments)
|
| 4499 |
+
return (
|
| 4500 |
+
e &&
|
| 4501 |
+
(this._isAnimatedProperty[arguments[0]] ||
|
| 4502 |
+
this._style[t].apply(this._style, arguments),
|
| 4503 |
+
this._updateIndices()),
|
| 4504 |
+
i
|
| 4505 |
+
)
|
| 4506 |
+
}
|
| 4507 |
+
})(l, l in h)
|
| 4508 |
+
for (var u in document.documentElement.style)
|
| 4509 |
+
u in o ||
|
| 4510 |
+
u in a ||
|
| 4511 |
+
(function (t) {
|
| 4512 |
+
i(n.prototype, t, {
|
| 4513 |
+
get: function () {
|
| 4514 |
+
return this._surrogateStyle[t]
|
| 4515 |
+
},
|
| 4516 |
+
set: function (e) {
|
| 4517 |
+
;(this._surrogateStyle[t] = e),
|
| 4518 |
+
this._updateIndices(),
|
| 4519 |
+
this._isAnimatedProperty[t] || (this._style[t] = e)
|
| 4520 |
+
},
|
| 4521 |
+
})
|
| 4522 |
+
})(u)
|
| 4523 |
+
;(t.apply = function (e, i, n) {
|
| 4524 |
+
r(e), e.style._set(t.propertyName(i), n)
|
| 4525 |
+
}),
|
| 4526 |
+
(t.clear = function (e, i) {
|
| 4527 |
+
e._webAnimationsPatchedStyle && e.style._clear(t.propertyName(i))
|
| 4528 |
+
})
|
| 4529 |
+
})(ri),
|
| 4530 |
+
(function (t) {
|
| 4531 |
+
window.Element.prototype.animate = function (e, i) {
|
| 4532 |
+
var n = ''
|
| 4533 |
+
return i && i.id && (n = i.id), t.timeline._play(t.KeyframeEffect(this, e, i, n))
|
| 4534 |
+
}
|
| 4535 |
+
})(ri),
|
| 4536 |
+
(function (t, e) {
|
| 4537 |
+
function i(t, e, n) {
|
| 4538 |
+
if ('number' == typeof t && 'number' == typeof e) return t * (1 - n) + e * n
|
| 4539 |
+
if ('boolean' == typeof t && 'boolean' == typeof e) return n < 0.5 ? t : e
|
| 4540 |
+
if (t.length == e.length) {
|
| 4541 |
+
for (var r = [], s = 0; s < t.length; s++) r.push(i(t[s], e[s], n))
|
| 4542 |
+
return r
|
| 4543 |
+
}
|
| 4544 |
+
throw 'Mismatched interpolation arguments ' + t + ':' + e
|
| 4545 |
+
}
|
| 4546 |
+
t.Interpolation = function (t, e, n) {
|
| 4547 |
+
return function (r) {
|
| 4548 |
+
return n(i(t, e, r))
|
| 4549 |
+
}
|
| 4550 |
+
}
|
| 4551 |
+
})(ri),
|
| 4552 |
+
(function (t, e) {
|
| 4553 |
+
var i = (function () {
|
| 4554 |
+
function t(t, e) {
|
| 4555 |
+
for (
|
| 4556 |
+
var i = [
|
| 4557 |
+
[0, 0, 0, 0],
|
| 4558 |
+
[0, 0, 0, 0],
|
| 4559 |
+
[0, 0, 0, 0],
|
| 4560 |
+
[0, 0, 0, 0],
|
| 4561 |
+
],
|
| 4562 |
+
n = 0;
|
| 4563 |
+
n < 4;
|
| 4564 |
+
n++
|
| 4565 |
+
)
|
| 4566 |
+
for (var r = 0; r < 4; r++) for (var s = 0; s < 4; s++) i[n][r] += e[n][s] * t[s][r]
|
| 4567 |
+
return i
|
| 4568 |
+
}
|
| 4569 |
+
return function (e, i, n, r, s) {
|
| 4570 |
+
for (
|
| 4571 |
+
var o = [
|
| 4572 |
+
[1, 0, 0, 0],
|
| 4573 |
+
[0, 1, 0, 0],
|
| 4574 |
+
[0, 0, 1, 0],
|
| 4575 |
+
[0, 0, 0, 1],
|
| 4576 |
+
],
|
| 4577 |
+
a = 0;
|
| 4578 |
+
a < 4;
|
| 4579 |
+
a++
|
| 4580 |
+
)
|
| 4581 |
+
o[a][3] = s[a]
|
| 4582 |
+
for (a = 0; a < 3; a++) for (var h = 0; h < 3; h++) o[3][a] += e[h] * o[h][a]
|
| 4583 |
+
var l = r[0],
|
| 4584 |
+
u = r[1],
|
| 4585 |
+
d = r[2],
|
| 4586 |
+
c = r[3],
|
| 4587 |
+
_ = [
|
| 4588 |
+
[1, 0, 0, 0],
|
| 4589 |
+
[0, 1, 0, 0],
|
| 4590 |
+
[0, 0, 1, 0],
|
| 4591 |
+
[0, 0, 0, 1],
|
| 4592 |
+
]
|
| 4593 |
+
;(_[0][0] = 1 - 2 * (u * u + d * d)),
|
| 4594 |
+
(_[0][1] = 2 * (l * u - d * c)),
|
| 4595 |
+
(_[0][2] = 2 * (l * d + u * c)),
|
| 4596 |
+
(_[1][0] = 2 * (l * u + d * c)),
|
| 4597 |
+
(_[1][1] = 1 - 2 * (l * l + d * d)),
|
| 4598 |
+
(_[1][2] = 2 * (u * d - l * c)),
|
| 4599 |
+
(_[2][0] = 2 * (l * d - u * c)),
|
| 4600 |
+
(_[2][1] = 2 * (u * d + l * c)),
|
| 4601 |
+
(_[2][2] = 1 - 2 * (l * l + u * u)),
|
| 4602 |
+
(o = t(o, _))
|
| 4603 |
+
var f = [
|
| 4604 |
+
[1, 0, 0, 0],
|
| 4605 |
+
[0, 1, 0, 0],
|
| 4606 |
+
[0, 0, 1, 0],
|
| 4607 |
+
[0, 0, 0, 1],
|
| 4608 |
+
]
|
| 4609 |
+
for (
|
| 4610 |
+
n[2] && ((f[2][1] = n[2]), (o = t(o, f))),
|
| 4611 |
+
n[1] && ((f[2][1] = 0), (f[2][0] = n[0]), (o = t(o, f))),
|
| 4612 |
+
n[0] && ((f[2][0] = 0), (f[1][0] = n[0]), (o = t(o, f))),
|
| 4613 |
+
a = 0;
|
| 4614 |
+
a < 3;
|
| 4615 |
+
a++
|
| 4616 |
+
)
|
| 4617 |
+
for (h = 0; h < 3; h++) o[a][h] *= i[a]
|
| 4618 |
+
return (function (t) {
|
| 4619 |
+
return (
|
| 4620 |
+
0 == t[0][2] &&
|
| 4621 |
+
0 == t[0][3] &&
|
| 4622 |
+
0 == t[1][2] &&
|
| 4623 |
+
0 == t[1][3] &&
|
| 4624 |
+
0 == t[2][0] &&
|
| 4625 |
+
0 == t[2][1] &&
|
| 4626 |
+
1 == t[2][2] &&
|
| 4627 |
+
0 == t[2][3] &&
|
| 4628 |
+
0 == t[3][2] &&
|
| 4629 |
+
1 == t[3][3]
|
| 4630 |
+
)
|
| 4631 |
+
})(o)
|
| 4632 |
+
? [o[0][0], o[0][1], o[1][0], o[1][1], o[3][0], o[3][1]]
|
| 4633 |
+
: o[0].concat(o[1], o[2], o[3])
|
| 4634 |
+
}
|
| 4635 |
+
})()
|
| 4636 |
+
;(t.composeMatrix = i),
|
| 4637 |
+
(t.quat = function (e, i, n) {
|
| 4638 |
+
var r = t.dot(e, i)
|
| 4639 |
+
r = (function (t, e, i) {
|
| 4640 |
+
return Math.max(Math.min(t, i), e)
|
| 4641 |
+
})(r, -1, 1)
|
| 4642 |
+
var s = []
|
| 4643 |
+
if (1 === r) s = e
|
| 4644 |
+
else
|
| 4645 |
+
for (
|
| 4646 |
+
var o = Math.acos(r), a = (1 * Math.sin(n * o)) / Math.sqrt(1 - r * r), h = 0;
|
| 4647 |
+
h < 4;
|
| 4648 |
+
h++
|
| 4649 |
+
)
|
| 4650 |
+
s.push(e[h] * (Math.cos(n * o) - r * a) + i[h] * a)
|
| 4651 |
+
return s
|
| 4652 |
+
})
|
| 4653 |
+
})(ri),
|
| 4654 |
+
(function (t, e, i) {
|
| 4655 |
+
t.sequenceNumber = 0
|
| 4656 |
+
var n = function (t, e, i) {
|
| 4657 |
+
;(this.target = t),
|
| 4658 |
+
(this.currentTime = e),
|
| 4659 |
+
(this.timelineTime = i),
|
| 4660 |
+
(this.type = 'finish'),
|
| 4661 |
+
(this.bubbles = !1),
|
| 4662 |
+
(this.cancelable = !1),
|
| 4663 |
+
(this.currentTarget = t),
|
| 4664 |
+
(this.defaultPrevented = !1),
|
| 4665 |
+
(this.eventPhase = Event.AT_TARGET),
|
| 4666 |
+
(this.timeStamp = Date.now())
|
| 4667 |
+
}
|
| 4668 |
+
;(e.Animation = function (e) {
|
| 4669 |
+
;(this.id = ''),
|
| 4670 |
+
e && e._id && (this.id = e._id),
|
| 4671 |
+
(this._sequenceNumber = t.sequenceNumber++),
|
| 4672 |
+
(this._currentTime = 0),
|
| 4673 |
+
(this._startTime = null),
|
| 4674 |
+
(this._paused = !1),
|
| 4675 |
+
(this._playbackRate = 1),
|
| 4676 |
+
(this._inTimeline = !0),
|
| 4677 |
+
(this._finishedFlag = !0),
|
| 4678 |
+
(this.onfinish = null),
|
| 4679 |
+
(this._finishHandlers = []),
|
| 4680 |
+
(this._effect = e),
|
| 4681 |
+
(this._inEffect = this._effect._update(0)),
|
| 4682 |
+
(this._idle = !0),
|
| 4683 |
+
(this._currentTimePending = !1)
|
| 4684 |
+
}),
|
| 4685 |
+
(e.Animation.prototype = {
|
| 4686 |
+
_ensureAlive: function () {
|
| 4687 |
+
this.playbackRate < 0 && 0 === this.currentTime
|
| 4688 |
+
? (this._inEffect = this._effect._update(-1))
|
| 4689 |
+
: (this._inEffect = this._effect._update(this.currentTime)),
|
| 4690 |
+
this._inTimeline ||
|
| 4691 |
+
(!this._inEffect && this._finishedFlag) ||
|
| 4692 |
+
((this._inTimeline = !0), e.timeline._animations.push(this))
|
| 4693 |
+
},
|
| 4694 |
+
_tickCurrentTime: function (t, e) {
|
| 4695 |
+
t != this._currentTime &&
|
| 4696 |
+
((this._currentTime = t),
|
| 4697 |
+
this._isFinished &&
|
| 4698 |
+
!e &&
|
| 4699 |
+
(this._currentTime = this._playbackRate > 0 ? this._totalDuration : 0),
|
| 4700 |
+
this._ensureAlive())
|
| 4701 |
+
},
|
| 4702 |
+
get currentTime() {
|
| 4703 |
+
return this._idle || this._currentTimePending ? null : this._currentTime
|
| 4704 |
+
},
|
| 4705 |
+
set currentTime(t) {
|
| 4706 |
+
;(t = +t),
|
| 4707 |
+
isNaN(t) ||
|
| 4708 |
+
(e.restart(),
|
| 4709 |
+
this._paused ||
|
| 4710 |
+
null == this._startTime ||
|
| 4711 |
+
(this._startTime = this._timeline.currentTime - t / this._playbackRate),
|
| 4712 |
+
(this._currentTimePending = !1),
|
| 4713 |
+
this._currentTime != t &&
|
| 4714 |
+
(this._idle && ((this._idle = !1), (this._paused = !0)),
|
| 4715 |
+
this._tickCurrentTime(t, !0),
|
| 4716 |
+
e.applyDirtiedAnimation(this)))
|
| 4717 |
+
},
|
| 4718 |
+
get startTime() {
|
| 4719 |
+
return this._startTime
|
| 4720 |
+
},
|
| 4721 |
+
set startTime(t) {
|
| 4722 |
+
;(t = +t),
|
| 4723 |
+
isNaN(t) ||
|
| 4724 |
+
this._paused ||
|
| 4725 |
+
this._idle ||
|
| 4726 |
+
((this._startTime = t),
|
| 4727 |
+
this._tickCurrentTime(
|
| 4728 |
+
(this._timeline.currentTime - this._startTime) * this.playbackRate,
|
| 4729 |
+
),
|
| 4730 |
+
e.applyDirtiedAnimation(this))
|
| 4731 |
+
},
|
| 4732 |
+
get playbackRate() {
|
| 4733 |
+
return this._playbackRate
|
| 4734 |
+
},
|
| 4735 |
+
set playbackRate(t) {
|
| 4736 |
+
if (t != this._playbackRate) {
|
| 4737 |
+
var i = this.currentTime
|
| 4738 |
+
;(this._playbackRate = t),
|
| 4739 |
+
(this._startTime = null),
|
| 4740 |
+
'paused' != this.playState &&
|
| 4741 |
+
'idle' != this.playState &&
|
| 4742 |
+
((this._finishedFlag = !1),
|
| 4743 |
+
(this._idle = !1),
|
| 4744 |
+
this._ensureAlive(),
|
| 4745 |
+
e.applyDirtiedAnimation(this)),
|
| 4746 |
+
null != i && (this.currentTime = i)
|
| 4747 |
+
}
|
| 4748 |
+
},
|
| 4749 |
+
get _isFinished() {
|
| 4750 |
+
return (
|
| 4751 |
+
!this._idle &&
|
| 4752 |
+
((this._playbackRate > 0 && this._currentTime >= this._totalDuration) ||
|
| 4753 |
+
(this._playbackRate < 0 && this._currentTime <= 0))
|
| 4754 |
+
)
|
| 4755 |
+
},
|
| 4756 |
+
get _totalDuration() {
|
| 4757 |
+
return this._effect._totalDuration
|
| 4758 |
+
},
|
| 4759 |
+
get playState() {
|
| 4760 |
+
return this._idle
|
| 4761 |
+
? 'idle'
|
| 4762 |
+
: (null == this._startTime && !this._paused && 0 != this.playbackRate) ||
|
| 4763 |
+
this._currentTimePending
|
| 4764 |
+
? 'pending'
|
| 4765 |
+
: this._paused
|
| 4766 |
+
? 'paused'
|
| 4767 |
+
: this._isFinished
|
| 4768 |
+
? 'finished'
|
| 4769 |
+
: 'running'
|
| 4770 |
+
},
|
| 4771 |
+
_rewind: function () {
|
| 4772 |
+
if (this._playbackRate >= 0) this._currentTime = 0
|
| 4773 |
+
else {
|
| 4774 |
+
if (!(this._totalDuration < 1 / 0))
|
| 4775 |
+
throw new DOMException(
|
| 4776 |
+
'Unable to rewind negative playback rate animation with infinite duration',
|
| 4777 |
+
'InvalidStateError',
|
| 4778 |
+
)
|
| 4779 |
+
this._currentTime = this._totalDuration
|
| 4780 |
+
}
|
| 4781 |
+
},
|
| 4782 |
+
play: function () {
|
| 4783 |
+
;(this._paused = !1),
|
| 4784 |
+
(this._isFinished || this._idle) && (this._rewind(), (this._startTime = null)),
|
| 4785 |
+
(this._finishedFlag = !1),
|
| 4786 |
+
(this._idle = !1),
|
| 4787 |
+
this._ensureAlive(),
|
| 4788 |
+
e.applyDirtiedAnimation(this)
|
| 4789 |
+
},
|
| 4790 |
+
pause: function () {
|
| 4791 |
+
this._isFinished || this._paused || this._idle
|
| 4792 |
+
? this._idle && (this._rewind(), (this._idle = !1))
|
| 4793 |
+
: (this._currentTimePending = !0),
|
| 4794 |
+
(this._startTime = null),
|
| 4795 |
+
(this._paused = !0)
|
| 4796 |
+
},
|
| 4797 |
+
finish: function () {
|
| 4798 |
+
this._idle ||
|
| 4799 |
+
((this.currentTime = this._playbackRate > 0 ? this._totalDuration : 0),
|
| 4800 |
+
(this._startTime = this._totalDuration - this.currentTime),
|
| 4801 |
+
(this._currentTimePending = !1),
|
| 4802 |
+
e.applyDirtiedAnimation(this))
|
| 4803 |
+
},
|
| 4804 |
+
cancel: function () {
|
| 4805 |
+
this._inEffect &&
|
| 4806 |
+
((this._inEffect = !1),
|
| 4807 |
+
(this._idle = !0),
|
| 4808 |
+
(this._paused = !1),
|
| 4809 |
+
(this._finishedFlag = !0),
|
| 4810 |
+
(this._currentTime = 0),
|
| 4811 |
+
(this._startTime = null),
|
| 4812 |
+
this._effect._update(null),
|
| 4813 |
+
e.applyDirtiedAnimation(this))
|
| 4814 |
+
},
|
| 4815 |
+
reverse: function () {
|
| 4816 |
+
;(this.playbackRate *= -1), this.play()
|
| 4817 |
+
},
|
| 4818 |
+
addEventListener: function (t, e) {
|
| 4819 |
+
'function' == typeof e && 'finish' == t && this._finishHandlers.push(e)
|
| 4820 |
+
},
|
| 4821 |
+
removeEventListener: function (t, e) {
|
| 4822 |
+
if ('finish' == t) {
|
| 4823 |
+
var i = this._finishHandlers.indexOf(e)
|
| 4824 |
+
i >= 0 && this._finishHandlers.splice(i, 1)
|
| 4825 |
+
}
|
| 4826 |
+
},
|
| 4827 |
+
_fireEvents: function (t) {
|
| 4828 |
+
if (this._isFinished) {
|
| 4829 |
+
if (!this._finishedFlag) {
|
| 4830 |
+
var e = new n(this, this._currentTime, t),
|
| 4831 |
+
i = this._finishHandlers.concat(this.onfinish ? [this.onfinish] : [])
|
| 4832 |
+
setTimeout(function () {
|
| 4833 |
+
i.forEach(function (t) {
|
| 4834 |
+
t.call(e.target, e)
|
| 4835 |
+
})
|
| 4836 |
+
}, 0),
|
| 4837 |
+
(this._finishedFlag = !0)
|
| 4838 |
+
}
|
| 4839 |
+
} else this._finishedFlag = !1
|
| 4840 |
+
},
|
| 4841 |
+
_tick: function (t, e) {
|
| 4842 |
+
this._idle ||
|
| 4843 |
+
this._paused ||
|
| 4844 |
+
(null == this._startTime
|
| 4845 |
+
? e && (this.startTime = t - this._currentTime / this.playbackRate)
|
| 4846 |
+
: this._isFinished ||
|
| 4847 |
+
this._tickCurrentTime((t - this._startTime) * this.playbackRate)),
|
| 4848 |
+
e && ((this._currentTimePending = !1), this._fireEvents(t))
|
| 4849 |
+
},
|
| 4850 |
+
get _needsTick() {
|
| 4851 |
+
return this.playState in { pending: 1, running: 1 } || !this._finishedFlag
|
| 4852 |
+
},
|
| 4853 |
+
_targetAnimations: function () {
|
| 4854 |
+
var t = this._effect._target
|
| 4855 |
+
return t._activeAnimations || (t._activeAnimations = []), t._activeAnimations
|
| 4856 |
+
},
|
| 4857 |
+
_markTarget: function () {
|
| 4858 |
+
var t = this._targetAnimations()
|
| 4859 |
+
;-1 === t.indexOf(this) && t.push(this)
|
| 4860 |
+
},
|
| 4861 |
+
_unmarkTarget: function () {
|
| 4862 |
+
var t = this._targetAnimations(),
|
| 4863 |
+
e = t.indexOf(this)
|
| 4864 |
+
;-1 !== e && t.splice(e, 1)
|
| 4865 |
+
},
|
| 4866 |
+
})
|
| 4867 |
+
})(ni, ri),
|
| 4868 |
+
(function (t, e, i) {
|
| 4869 |
+
function n(t) {
|
| 4870 |
+
var e = l
|
| 4871 |
+
;(l = []),
|
| 4872 |
+
t < p.currentTime && (t = p.currentTime),
|
| 4873 |
+
p._animations.sort(r),
|
| 4874 |
+
(p._animations = a(t, !0, p._animations)[0]),
|
| 4875 |
+
e.forEach(function (e) {
|
| 4876 |
+
e[1](t)
|
| 4877 |
+
}),
|
| 4878 |
+
o()
|
| 4879 |
+
}
|
| 4880 |
+
function r(t, e) {
|
| 4881 |
+
return t._sequenceNumber - e._sequenceNumber
|
| 4882 |
+
}
|
| 4883 |
+
function s() {
|
| 4884 |
+
;(this._animations = []),
|
| 4885 |
+
(this.currentTime = window.performance && performance.now ? performance.now() : 0)
|
| 4886 |
+
}
|
| 4887 |
+
function o() {
|
| 4888 |
+
_.forEach(function (t) {
|
| 4889 |
+
t()
|
| 4890 |
+
}),
|
| 4891 |
+
(_.length = 0)
|
| 4892 |
+
}
|
| 4893 |
+
function a(t, i, n) {
|
| 4894 |
+
;(f = !0), (c = !1), (e.timeline.currentTime = t), (d = !1)
|
| 4895 |
+
var r = [],
|
| 4896 |
+
s = [],
|
| 4897 |
+
o = [],
|
| 4898 |
+
a = []
|
| 4899 |
+
return (
|
| 4900 |
+
n.forEach(function (e) {
|
| 4901 |
+
e._tick(t, i),
|
| 4902 |
+
e._inEffect
|
| 4903 |
+
? (s.push(e._effect), e._markTarget())
|
| 4904 |
+
: (r.push(e._effect), e._unmarkTarget()),
|
| 4905 |
+
e._needsTick && (d = !0)
|
| 4906 |
+
var n = e._inEffect || e._needsTick
|
| 4907 |
+
;(e._inTimeline = n), n ? o.push(e) : a.push(e)
|
| 4908 |
+
}),
|
| 4909 |
+
_.push.apply(_, r),
|
| 4910 |
+
_.push.apply(_, s),
|
| 4911 |
+
d && requestAnimationFrame(function () {}),
|
| 4912 |
+
(f = !1),
|
| 4913 |
+
[o, a]
|
| 4914 |
+
)
|
| 4915 |
+
}
|
| 4916 |
+
var h = window.requestAnimationFrame,
|
| 4917 |
+
l = [],
|
| 4918 |
+
u = 0
|
| 4919 |
+
;(window.requestAnimationFrame = function (t) {
|
| 4920 |
+
var e = u++
|
| 4921 |
+
return 0 == l.length && h(n), l.push([e, t]), e
|
| 4922 |
+
}),
|
| 4923 |
+
(window.cancelAnimationFrame = function (t) {
|
| 4924 |
+
l.forEach(function (e) {
|
| 4925 |
+
e[0] == t && (e[1] = function () {})
|
| 4926 |
+
})
|
| 4927 |
+
}),
|
| 4928 |
+
(s.prototype = {
|
| 4929 |
+
_play: function (i) {
|
| 4930 |
+
i._timing = t.normalizeTimingInput(i.timing)
|
| 4931 |
+
var n = new e.Animation(i)
|
| 4932 |
+
return (
|
| 4933 |
+
(n._idle = !1),
|
| 4934 |
+
(n._timeline = this),
|
| 4935 |
+
this._animations.push(n),
|
| 4936 |
+
e.restart(),
|
| 4937 |
+
e.applyDirtiedAnimation(n),
|
| 4938 |
+
n
|
| 4939 |
+
)
|
| 4940 |
+
},
|
| 4941 |
+
})
|
| 4942 |
+
var d = !1,
|
| 4943 |
+
c = !1
|
| 4944 |
+
;(e.restart = function () {
|
| 4945 |
+
return d || ((d = !0), requestAnimationFrame(function () {}), (c = !0)), c
|
| 4946 |
+
}),
|
| 4947 |
+
(e.applyDirtiedAnimation = function (t) {
|
| 4948 |
+
if (!f) {
|
| 4949 |
+
t._markTarget()
|
| 4950 |
+
var i = t._targetAnimations()
|
| 4951 |
+
i.sort(r),
|
| 4952 |
+
a(e.timeline.currentTime, !1, i.slice())[1].forEach(function (t) {
|
| 4953 |
+
var e = p._animations.indexOf(t)
|
| 4954 |
+
;-1 !== e && p._animations.splice(e, 1)
|
| 4955 |
+
}),
|
| 4956 |
+
o()
|
| 4957 |
+
}
|
| 4958 |
+
})
|
| 4959 |
+
var _ = [],
|
| 4960 |
+
f = !1,
|
| 4961 |
+
p = new s()
|
| 4962 |
+
e.timeline = p
|
| 4963 |
+
})(ni, ri),
|
| 4964 |
+
(function (t, e) {
|
| 4965 |
+
function i(t, e) {
|
| 4966 |
+
for (var i = 0, n = 0; n < t.length; n++) i += t[n] * e[n]
|
| 4967 |
+
return i
|
| 4968 |
+
}
|
| 4969 |
+
function n(t, e) {
|
| 4970 |
+
return [
|
| 4971 |
+
t[0] * e[0] + t[4] * e[1] + t[8] * e[2] + t[12] * e[3],
|
| 4972 |
+
t[1] * e[0] + t[5] * e[1] + t[9] * e[2] + t[13] * e[3],
|
| 4973 |
+
t[2] * e[0] + t[6] * e[1] + t[10] * e[2] + t[14] * e[3],
|
| 4974 |
+
t[3] * e[0] + t[7] * e[1] + t[11] * e[2] + t[15] * e[3],
|
| 4975 |
+
t[0] * e[4] + t[4] * e[5] + t[8] * e[6] + t[12] * e[7],
|
| 4976 |
+
t[1] * e[4] + t[5] * e[5] + t[9] * e[6] + t[13] * e[7],
|
| 4977 |
+
t[2] * e[4] + t[6] * e[5] + t[10] * e[6] + t[14] * e[7],
|
| 4978 |
+
t[3] * e[4] + t[7] * e[5] + t[11] * e[6] + t[15] * e[7],
|
| 4979 |
+
t[0] * e[8] + t[4] * e[9] + t[8] * e[10] + t[12] * e[11],
|
| 4980 |
+
t[1] * e[8] + t[5] * e[9] + t[9] * e[10] + t[13] * e[11],
|
| 4981 |
+
t[2] * e[8] + t[6] * e[9] + t[10] * e[10] + t[14] * e[11],
|
| 4982 |
+
t[3] * e[8] + t[7] * e[9] + t[11] * e[10] + t[15] * e[11],
|
| 4983 |
+
t[0] * e[12] + t[4] * e[13] + t[8] * e[14] + t[12] * e[15],
|
| 4984 |
+
t[1] * e[12] + t[5] * e[13] + t[9] * e[14] + t[13] * e[15],
|
| 4985 |
+
t[2] * e[12] + t[6] * e[13] + t[10] * e[14] + t[14] * e[15],
|
| 4986 |
+
t[3] * e[12] + t[7] * e[13] + t[11] * e[14] + t[15] * e[15],
|
| 4987 |
+
]
|
| 4988 |
+
}
|
| 4989 |
+
function r(t) {
|
| 4990 |
+
var e = t.rad || 0
|
| 4991 |
+
return ((t.deg || 0) / 360 + (t.grad || 0) / 400 + (t.turn || 0)) * (2 * Math.PI) + e
|
| 4992 |
+
}
|
| 4993 |
+
function s(t) {
|
| 4994 |
+
switch (t.t) {
|
| 4995 |
+
case 'rotatex':
|
| 4996 |
+
var e = r(t.d[0])
|
| 4997 |
+
return [
|
| 4998 |
+
1,
|
| 4999 |
+
0,
|
| 5000 |
+
0,
|
| 5001 |
+
0,
|
| 5002 |
+
0,
|
| 5003 |
+
Math.cos(e),
|
| 5004 |
+
Math.sin(e),
|
| 5005 |
+
0,
|
| 5006 |
+
0,
|
| 5007 |
+
-Math.sin(e),
|
| 5008 |
+
Math.cos(e),
|
| 5009 |
+
0,
|
| 5010 |
+
0,
|
| 5011 |
+
0,
|
| 5012 |
+
0,
|
| 5013 |
+
1,
|
| 5014 |
+
]
|
| 5015 |
+
case 'rotatey':
|
| 5016 |
+
return (
|
| 5017 |
+
(e = r(t.d[0])),
|
| 5018 |
+
[
|
| 5019 |
+
Math.cos(e),
|
| 5020 |
+
0,
|
| 5021 |
+
-Math.sin(e),
|
| 5022 |
+
0,
|
| 5023 |
+
0,
|
| 5024 |
+
1,
|
| 5025 |
+
0,
|
| 5026 |
+
0,
|
| 5027 |
+
Math.sin(e),
|
| 5028 |
+
0,
|
| 5029 |
+
Math.cos(e),
|
| 5030 |
+
0,
|
| 5031 |
+
0,
|
| 5032 |
+
0,
|
| 5033 |
+
0,
|
| 5034 |
+
1,
|
| 5035 |
+
]
|
| 5036 |
+
)
|
| 5037 |
+
case 'rotate':
|
| 5038 |
+
case 'rotatez':
|
| 5039 |
+
return (
|
| 5040 |
+
(e = r(t.d[0])),
|
| 5041 |
+
[
|
| 5042 |
+
Math.cos(e),
|
| 5043 |
+
Math.sin(e),
|
| 5044 |
+
0,
|
| 5045 |
+
0,
|
| 5046 |
+
-Math.sin(e),
|
| 5047 |
+
Math.cos(e),
|
| 5048 |
+
0,
|
| 5049 |
+
0,
|
| 5050 |
+
0,
|
| 5051 |
+
0,
|
| 5052 |
+
1,
|
| 5053 |
+
0,
|
| 5054 |
+
0,
|
| 5055 |
+
0,
|
| 5056 |
+
0,
|
| 5057 |
+
1,
|
| 5058 |
+
]
|
| 5059 |
+
)
|
| 5060 |
+
case 'rotate3d':
|
| 5061 |
+
var i = t.d[0],
|
| 5062 |
+
n = t.d[1],
|
| 5063 |
+
s = t.d[2],
|
| 5064 |
+
o = ((e = r(t.d[3])), i * i + n * n + s * s)
|
| 5065 |
+
if (0 === o) (i = 1), (n = 0), (s = 0)
|
| 5066 |
+
else if (1 !== o) {
|
| 5067 |
+
var a = Math.sqrt(o)
|
| 5068 |
+
;(i /= a), (n /= a), (s /= a)
|
| 5069 |
+
}
|
| 5070 |
+
var h = Math.sin(e / 2),
|
| 5071 |
+
l = h * Math.cos(e / 2),
|
| 5072 |
+
u = h * h
|
| 5073 |
+
return [
|
| 5074 |
+
1 - 2 * (n * n + s * s) * u,
|
| 5075 |
+
2 * (i * n * u + s * l),
|
| 5076 |
+
2 * (i * s * u - n * l),
|
| 5077 |
+
0,
|
| 5078 |
+
2 * (i * n * u - s * l),
|
| 5079 |
+
1 - 2 * (i * i + s * s) * u,
|
| 5080 |
+
2 * (n * s * u + i * l),
|
| 5081 |
+
0,
|
| 5082 |
+
2 * (i * s * u + n * l),
|
| 5083 |
+
2 * (n * s * u - i * l),
|
| 5084 |
+
1 - 2 * (i * i + n * n) * u,
|
| 5085 |
+
0,
|
| 5086 |
+
0,
|
| 5087 |
+
0,
|
| 5088 |
+
0,
|
| 5089 |
+
1,
|
| 5090 |
+
]
|
| 5091 |
+
case 'scale':
|
| 5092 |
+
return [t.d[0], 0, 0, 0, 0, t.d[1], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5093 |
+
case 'scalex':
|
| 5094 |
+
return [t.d[0], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5095 |
+
case 'scaley':
|
| 5096 |
+
return [1, 0, 0, 0, 0, t.d[0], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5097 |
+
case 'scalez':
|
| 5098 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, t.d[0], 0, 0, 0, 0, 1]
|
| 5099 |
+
case 'scale3d':
|
| 5100 |
+
return [t.d[0], 0, 0, 0, 0, t.d[1], 0, 0, 0, 0, t.d[2], 0, 0, 0, 0, 1]
|
| 5101 |
+
case 'skew':
|
| 5102 |
+
var d = r(t.d[0]),
|
| 5103 |
+
c = r(t.d[1])
|
| 5104 |
+
return [1, Math.tan(c), 0, 0, Math.tan(d), 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5105 |
+
case 'skewx':
|
| 5106 |
+
return (e = r(t.d[0])), [1, 0, 0, 0, Math.tan(e), 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5107 |
+
case 'skewy':
|
| 5108 |
+
return (e = r(t.d[0])), [1, Math.tan(e), 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 5109 |
+
case 'translate':
|
| 5110 |
+
return [
|
| 5111 |
+
1,
|
| 5112 |
+
0,
|
| 5113 |
+
0,
|
| 5114 |
+
0,
|
| 5115 |
+
0,
|
| 5116 |
+
1,
|
| 5117 |
+
0,
|
| 5118 |
+
0,
|
| 5119 |
+
0,
|
| 5120 |
+
0,
|
| 5121 |
+
1,
|
| 5122 |
+
0,
|
| 5123 |
+
(i = t.d[0].px || 0),
|
| 5124 |
+
(n = t.d[1].px || 0),
|
| 5125 |
+
0,
|
| 5126 |
+
1,
|
| 5127 |
+
]
|
| 5128 |
+
case 'translatex':
|
| 5129 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, (i = t.d[0].px || 0), 0, 0, 1]
|
| 5130 |
+
case 'translatey':
|
| 5131 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, (n = t.d[0].px || 0), 0, 1]
|
| 5132 |
+
case 'translatez':
|
| 5133 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, (s = t.d[0].px || 0), 1]
|
| 5134 |
+
case 'translate3d':
|
| 5135 |
+
return [
|
| 5136 |
+
1,
|
| 5137 |
+
0,
|
| 5138 |
+
0,
|
| 5139 |
+
0,
|
| 5140 |
+
0,
|
| 5141 |
+
1,
|
| 5142 |
+
0,
|
| 5143 |
+
0,
|
| 5144 |
+
0,
|
| 5145 |
+
0,
|
| 5146 |
+
1,
|
| 5147 |
+
0,
|
| 5148 |
+
(i = t.d[0].px || 0),
|
| 5149 |
+
(n = t.d[1].px || 0),
|
| 5150 |
+
(s = t.d[2].px || 0),
|
| 5151 |
+
1,
|
| 5152 |
+
]
|
| 5153 |
+
case 'perspective':
|
| 5154 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, t.d[0].px ? -1 / t.d[0].px : 0, 0, 0, 0, 1]
|
| 5155 |
+
case 'matrix':
|
| 5156 |
+
return [t.d[0], t.d[1], 0, 0, t.d[2], t.d[3], 0, 0, 0, 0, 1, 0, t.d[4], t.d[5], 0, 1]
|
| 5157 |
+
case 'matrix3d':
|
| 5158 |
+
return t.d
|
| 5159 |
+
}
|
| 5160 |
+
}
|
| 5161 |
+
function o(t) {
|
| 5162 |
+
return 0 === t.length ? [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1] : t.map(s).reduce(n)
|
| 5163 |
+
}
|
| 5164 |
+
var a = (function () {
|
| 5165 |
+
function t(t) {
|
| 5166 |
+
return (
|
| 5167 |
+
t[0][0] * t[1][1] * t[2][2] +
|
| 5168 |
+
t[1][0] * t[2][1] * t[0][2] +
|
| 5169 |
+
t[2][0] * t[0][1] * t[1][2] -
|
| 5170 |
+
t[0][2] * t[1][1] * t[2][0] -
|
| 5171 |
+
t[1][2] * t[2][1] * t[0][0] -
|
| 5172 |
+
t[2][2] * t[0][1] * t[1][0]
|
| 5173 |
+
)
|
| 5174 |
+
}
|
| 5175 |
+
function e(t) {
|
| 5176 |
+
var e = n(t)
|
| 5177 |
+
return [t[0] / e, t[1] / e, t[2] / e]
|
| 5178 |
+
}
|
| 5179 |
+
function n(t) {
|
| 5180 |
+
return Math.sqrt(t[0] * t[0] + t[1] * t[1] + t[2] * t[2])
|
| 5181 |
+
}
|
| 5182 |
+
function r(t, e, i, n) {
|
| 5183 |
+
return [i * t[0] + n * e[0], i * t[1] + n * e[1], i * t[2] + n * e[2]]
|
| 5184 |
+
}
|
| 5185 |
+
return function (s) {
|
| 5186 |
+
var o = [s.slice(0, 4), s.slice(4, 8), s.slice(8, 12), s.slice(12, 16)]
|
| 5187 |
+
if (1 !== o[3][3]) return null
|
| 5188 |
+
for (var a = [], h = 0; h < 4; h++) a.push(o[h].slice())
|
| 5189 |
+
for (h = 0; h < 3; h++) a[h][3] = 0
|
| 5190 |
+
if (0 === t(a)) return null
|
| 5191 |
+
var l,
|
| 5192 |
+
u = []
|
| 5193 |
+
o[0][3] || o[1][3] || o[2][3]
|
| 5194 |
+
? (u.push(o[0][3]),
|
| 5195 |
+
u.push(o[1][3]),
|
| 5196 |
+
u.push(o[2][3]),
|
| 5197 |
+
u.push(o[3][3]),
|
| 5198 |
+
(l = (function (t, e) {
|
| 5199 |
+
for (var i = [], n = 0; n < 4; n++) {
|
| 5200 |
+
for (var r = 0, s = 0; s < 4; s++) r += t[s] * e[s][n]
|
| 5201 |
+
i.push(r)
|
| 5202 |
+
}
|
| 5203 |
+
return i
|
| 5204 |
+
})(
|
| 5205 |
+
u,
|
| 5206 |
+
(function (t) {
|
| 5207 |
+
return [
|
| 5208 |
+
[t[0][0], t[1][0], t[2][0], t[3][0]],
|
| 5209 |
+
[t[0][1], t[1][1], t[2][1], t[3][1]],
|
| 5210 |
+
[t[0][2], t[1][2], t[2][2], t[3][2]],
|
| 5211 |
+
[t[0][3], t[1][3], t[2][3], t[3][3]],
|
| 5212 |
+
]
|
| 5213 |
+
})(
|
| 5214 |
+
(function (e) {
|
| 5215 |
+
for (
|
| 5216 |
+
var i = 1 / t(e),
|
| 5217 |
+
n = e[0][0],
|
| 5218 |
+
r = e[0][1],
|
| 5219 |
+
s = e[0][2],
|
| 5220 |
+
o = e[1][0],
|
| 5221 |
+
a = e[1][1],
|
| 5222 |
+
h = e[1][2],
|
| 5223 |
+
l = e[2][0],
|
| 5224 |
+
u = e[2][1],
|
| 5225 |
+
d = e[2][2],
|
| 5226 |
+
c = [
|
| 5227 |
+
[
|
| 5228 |
+
(a * d - h * u) * i,
|
| 5229 |
+
(s * u - r * d) * i,
|
| 5230 |
+
(r * h - s * a) * i,
|
| 5231 |
+
0,
|
| 5232 |
+
],
|
| 5233 |
+
[
|
| 5234 |
+
(h * l - o * d) * i,
|
| 5235 |
+
(n * d - s * l) * i,
|
| 5236 |
+
(s * o - n * h) * i,
|
| 5237 |
+
0,
|
| 5238 |
+
],
|
| 5239 |
+
[
|
| 5240 |
+
(o * u - a * l) * i,
|
| 5241 |
+
(l * r - n * u) * i,
|
| 5242 |
+
(n * a - r * o) * i,
|
| 5243 |
+
0,
|
| 5244 |
+
],
|
| 5245 |
+
],
|
| 5246 |
+
_ = [],
|
| 5247 |
+
f = 0;
|
| 5248 |
+
f < 3;
|
| 5249 |
+
f++
|
| 5250 |
+
) {
|
| 5251 |
+
for (var p = 0, m = 0; m < 3; m++) p += e[3][m] * c[m][f]
|
| 5252 |
+
_.push(p)
|
| 5253 |
+
}
|
| 5254 |
+
return _.push(1), c.push(_), c
|
| 5255 |
+
})(a),
|
| 5256 |
+
),
|
| 5257 |
+
)))
|
| 5258 |
+
: (l = [0, 0, 0, 1])
|
| 5259 |
+
var d = o[3].slice(0, 3),
|
| 5260 |
+
c = []
|
| 5261 |
+
c.push(o[0].slice(0, 3))
|
| 5262 |
+
var _ = []
|
| 5263 |
+
_.push(n(c[0])), (c[0] = e(c[0]))
|
| 5264 |
+
var f = []
|
| 5265 |
+
c.push(o[1].slice(0, 3)),
|
| 5266 |
+
f.push(i(c[0], c[1])),
|
| 5267 |
+
(c[1] = r(c[1], c[0], 1, -f[0])),
|
| 5268 |
+
_.push(n(c[1])),
|
| 5269 |
+
(c[1] = e(c[1])),
|
| 5270 |
+
(f[0] /= _[1]),
|
| 5271 |
+
c.push(o[2].slice(0, 3)),
|
| 5272 |
+
f.push(i(c[0], c[2])),
|
| 5273 |
+
(c[2] = r(c[2], c[0], 1, -f[1])),
|
| 5274 |
+
f.push(i(c[1], c[2])),
|
| 5275 |
+
(c[2] = r(c[2], c[1], 1, -f[2])),
|
| 5276 |
+
_.push(n(c[2])),
|
| 5277 |
+
(c[2] = e(c[2])),
|
| 5278 |
+
(f[1] /= _[2]),
|
| 5279 |
+
(f[2] /= _[2])
|
| 5280 |
+
var p = (function (t, e) {
|
| 5281 |
+
return [t[1] * e[2] - t[2] * e[1], t[2] * e[0] - t[0] * e[2], t[0] * e[1] - t[1] * e[0]]
|
| 5282 |
+
})(c[1], c[2])
|
| 5283 |
+
if (i(c[0], p) < 0)
|
| 5284 |
+
for (h = 0; h < 3; h++) (_[h] *= -1), (c[h][0] *= -1), (c[h][1] *= -1), (c[h][2] *= -1)
|
| 5285 |
+
var m,
|
| 5286 |
+
g,
|
| 5287 |
+
v = c[0][0] + c[1][1] + c[2][2] + 1
|
| 5288 |
+
return (
|
| 5289 |
+
v > 1e-4
|
| 5290 |
+
? ((m = 0.5 / Math.sqrt(v)),
|
| 5291 |
+
(g = [
|
| 5292 |
+
(c[2][1] - c[1][2]) * m,
|
| 5293 |
+
(c[0][2] - c[2][0]) * m,
|
| 5294 |
+
(c[1][0] - c[0][1]) * m,
|
| 5295 |
+
0.25 / m,
|
| 5296 |
+
]))
|
| 5297 |
+
: c[0][0] > c[1][1] && c[0][0] > c[2][2]
|
| 5298 |
+
? (g = [
|
| 5299 |
+
0.25 * (m = 2 * Math.sqrt(1 + c[0][0] - c[1][1] - c[2][2])),
|
| 5300 |
+
(c[0][1] + c[1][0]) / m,
|
| 5301 |
+
(c[0][2] + c[2][0]) / m,
|
| 5302 |
+
(c[2][1] - c[1][2]) / m,
|
| 5303 |
+
])
|
| 5304 |
+
: c[1][1] > c[2][2]
|
| 5305 |
+
? ((m = 2 * Math.sqrt(1 + c[1][1] - c[0][0] - c[2][2])),
|
| 5306 |
+
(g = [
|
| 5307 |
+
(c[0][1] + c[1][0]) / m,
|
| 5308 |
+
0.25 * m,
|
| 5309 |
+
(c[1][2] + c[2][1]) / m,
|
| 5310 |
+
(c[0][2] - c[2][0]) / m,
|
| 5311 |
+
]))
|
| 5312 |
+
: ((m = 2 * Math.sqrt(1 + c[2][2] - c[0][0] - c[1][1])),
|
| 5313 |
+
(g = [
|
| 5314 |
+
(c[0][2] + c[2][0]) / m,
|
| 5315 |
+
(c[1][2] + c[2][1]) / m,
|
| 5316 |
+
0.25 * m,
|
| 5317 |
+
(c[1][0] - c[0][1]) / m,
|
| 5318 |
+
])),
|
| 5319 |
+
[d, _, f, g, l]
|
| 5320 |
+
)
|
| 5321 |
+
}
|
| 5322 |
+
})()
|
| 5323 |
+
;(t.dot = i),
|
| 5324 |
+
(t.makeMatrixDecomposition = function (t) {
|
| 5325 |
+
return [a(o(t))]
|
| 5326 |
+
}),
|
| 5327 |
+
(t.transformListToMatrix = o)
|
| 5328 |
+
})(ri),
|
| 5329 |
+
(function (t) {
|
| 5330 |
+
function e(t, e) {
|
| 5331 |
+
var i = t.exec(e)
|
| 5332 |
+
if (i) return [(i = t.ignoreCase ? i[0].toLowerCase() : i[0]), e.substr(i.length)]
|
| 5333 |
+
}
|
| 5334 |
+
function i(t, e) {
|
| 5335 |
+
var i = t((e = e.replace(/^\s*/, '')))
|
| 5336 |
+
if (i) return [i[0], i[1].replace(/^\s*/, '')]
|
| 5337 |
+
}
|
| 5338 |
+
function n(t, e, i, n, r) {
|
| 5339 |
+
for (
|
| 5340 |
+
var s = [],
|
| 5341 |
+
o = [],
|
| 5342 |
+
a = [],
|
| 5343 |
+
h = (function (t, e) {
|
| 5344 |
+
for (var i = t, n = e; i && n; ) i > n ? (i %= n) : (n %= i)
|
| 5345 |
+
return (t * e) / (i + n)
|
| 5346 |
+
})(n.length, r.length),
|
| 5347 |
+
l = 0;
|
| 5348 |
+
l < h;
|
| 5349 |
+
l++
|
| 5350 |
+
) {
|
| 5351 |
+
var u = e(n[l % n.length], r[l % r.length])
|
| 5352 |
+
if (!u) return
|
| 5353 |
+
s.push(u[0]), o.push(u[1]), a.push(u[2])
|
| 5354 |
+
}
|
| 5355 |
+
return [
|
| 5356 |
+
s,
|
| 5357 |
+
o,
|
| 5358 |
+
function (e) {
|
| 5359 |
+
var n = e
|
| 5360 |
+
.map(function (t, e) {
|
| 5361 |
+
return a[e](t)
|
| 5362 |
+
})
|
| 5363 |
+
.join(i)
|
| 5364 |
+
return t ? t(n) : n
|
| 5365 |
+
},
|
| 5366 |
+
]
|
| 5367 |
+
}
|
| 5368 |
+
;(t.consumeToken = e),
|
| 5369 |
+
(t.consumeTrimmed = i),
|
| 5370 |
+
(t.consumeRepeated = function (t, n, r) {
|
| 5371 |
+
t = i.bind(null, t)
|
| 5372 |
+
for (var s = []; ; ) {
|
| 5373 |
+
var o = t(r)
|
| 5374 |
+
if (!o) return [s, r]
|
| 5375 |
+
if ((s.push(o[0]), !(o = e(n, (r = o[1]))) || '' == o[1])) return [s, r]
|
| 5376 |
+
r = o[1]
|
| 5377 |
+
}
|
| 5378 |
+
}),
|
| 5379 |
+
(t.consumeParenthesised = function (t, e) {
|
| 5380 |
+
for (var i = 0, n = 0; n < e.length && (!/\s|,/.test(e[n]) || 0 != i); n++)
|
| 5381 |
+
if ('(' == e[n]) i++
|
| 5382 |
+
else if (')' == e[n] && (0 == --i && n++, i <= 0)) break
|
| 5383 |
+
var r = t(e.substr(0, n))
|
| 5384 |
+
return null == r ? void 0 : [r, e.substr(n)]
|
| 5385 |
+
}),
|
| 5386 |
+
(t.ignore = function (t) {
|
| 5387 |
+
return function (e) {
|
| 5388 |
+
var i = t(e)
|
| 5389 |
+
return i && (i[0] = void 0), i
|
| 5390 |
+
}
|
| 5391 |
+
}),
|
| 5392 |
+
(t.optional = function (t, e) {
|
| 5393 |
+
return function (i) {
|
| 5394 |
+
return t(i) || [e, i]
|
| 5395 |
+
}
|
| 5396 |
+
}),
|
| 5397 |
+
(t.consumeList = function (e, i) {
|
| 5398 |
+
for (var n = [], r = 0; r < e.length; r++) {
|
| 5399 |
+
var s = t.consumeTrimmed(e[r], i)
|
| 5400 |
+
if (!s || '' == s[0]) return
|
| 5401 |
+
void 0 !== s[0] && n.push(s[0]), (i = s[1])
|
| 5402 |
+
}
|
| 5403 |
+
if ('' == i) return n
|
| 5404 |
+
}),
|
| 5405 |
+
(t.mergeNestedRepeated = n.bind(null, null)),
|
| 5406 |
+
(t.mergeWrappedNestedRepeated = n),
|
| 5407 |
+
(t.mergeList = function (t, e, i) {
|
| 5408 |
+
for (var n = [], r = [], s = [], o = 0, a = 0; a < i.length; a++)
|
| 5409 |
+
if ('function' == typeof i[a]) {
|
| 5410 |
+
var h = i[a](t[o], e[o++])
|
| 5411 |
+
n.push(h[0]), r.push(h[1]), s.push(h[2])
|
| 5412 |
+
} else
|
| 5413 |
+
!(function (t) {
|
| 5414 |
+
n.push(!1),
|
| 5415 |
+
r.push(!1),
|
| 5416 |
+
s.push(function () {
|
| 5417 |
+
return i[t]
|
| 5418 |
+
})
|
| 5419 |
+
})(a)
|
| 5420 |
+
return [
|
| 5421 |
+
n,
|
| 5422 |
+
r,
|
| 5423 |
+
function (t) {
|
| 5424 |
+
for (var e = '', i = 0; i < t.length; i++) e += s[i](t[i])
|
| 5425 |
+
return e
|
| 5426 |
+
},
|
| 5427 |
+
]
|
| 5428 |
+
})
|
| 5429 |
+
})(ri),
|
| 5430 |
+
(function (t) {
|
| 5431 |
+
function e(e) {
|
| 5432 |
+
var i = { inset: !1, lengths: [], color: null },
|
| 5433 |
+
n = t.consumeRepeated(
|
| 5434 |
+
function (e) {
|
| 5435 |
+
var n = t.consumeToken(/^inset/i, e)
|
| 5436 |
+
return n
|
| 5437 |
+
? ((i.inset = !0), n)
|
| 5438 |
+
: (n = t.consumeLengthOrPercent(e))
|
| 5439 |
+
? (i.lengths.push(n[0]), n)
|
| 5440 |
+
: (n = t.consumeColor(e))
|
| 5441 |
+
? ((i.color = n[0]), n)
|
| 5442 |
+
: void 0
|
| 5443 |
+
},
|
| 5444 |
+
/^/,
|
| 5445 |
+
e,
|
| 5446 |
+
)
|
| 5447 |
+
if (n && n[0].length) return [i, n[1]]
|
| 5448 |
+
}
|
| 5449 |
+
var i = function (e, i, n, r) {
|
| 5450 |
+
function s(t) {
|
| 5451 |
+
return {
|
| 5452 |
+
inset: t,
|
| 5453 |
+
color: [0, 0, 0, 0],
|
| 5454 |
+
lengths: [{ px: 0 }, { px: 0 }, { px: 0 }, { px: 0 }],
|
| 5455 |
+
}
|
| 5456 |
+
}
|
| 5457 |
+
for (var o = [], a = [], h = 0; h < n.length || h < r.length; h++) {
|
| 5458 |
+
var l = n[h] || s(r[h].inset),
|
| 5459 |
+
u = r[h] || s(n[h].inset)
|
| 5460 |
+
o.push(l), a.push(u)
|
| 5461 |
+
}
|
| 5462 |
+
return t.mergeNestedRepeated(e, i, o, a)
|
| 5463 |
+
}.bind(
|
| 5464 |
+
null,
|
| 5465 |
+
function (e, i) {
|
| 5466 |
+
for (; e.lengths.length < Math.max(e.lengths.length, i.lengths.length); )
|
| 5467 |
+
e.lengths.push({ px: 0 })
|
| 5468 |
+
for (; i.lengths.length < Math.max(e.lengths.length, i.lengths.length); )
|
| 5469 |
+
i.lengths.push({ px: 0 })
|
| 5470 |
+
if (e.inset == i.inset && !!e.color == !!i.color) {
|
| 5471 |
+
for (var n, r = [], s = [[], 0], o = [[], 0], a = 0; a < e.lengths.length; a++) {
|
| 5472 |
+
var h = t.mergeDimensions(e.lengths[a], i.lengths[a], 2 == a)
|
| 5473 |
+
s[0].push(h[0]), o[0].push(h[1]), r.push(h[2])
|
| 5474 |
+
}
|
| 5475 |
+
if (e.color && i.color) {
|
| 5476 |
+
var l = t.mergeColors(e.color, i.color)
|
| 5477 |
+
;(s[1] = l[0]), (o[1] = l[1]), (n = l[2])
|
| 5478 |
+
}
|
| 5479 |
+
return [
|
| 5480 |
+
s,
|
| 5481 |
+
o,
|
| 5482 |
+
function (t) {
|
| 5483 |
+
for (var i = e.inset ? 'inset ' : ' ', s = 0; s < r.length; s++)
|
| 5484 |
+
i += r[s](t[0][s]) + ' '
|
| 5485 |
+
return n && (i += n(t[1])), i
|
| 5486 |
+
},
|
| 5487 |
+
]
|
| 5488 |
+
}
|
| 5489 |
+
},
|
| 5490 |
+
', ',
|
| 5491 |
+
)
|
| 5492 |
+
t.addPropertiesHandler(
|
| 5493 |
+
function (i) {
|
| 5494 |
+
var n = t.consumeRepeated(e, /^,/, i)
|
| 5495 |
+
if (n && '' == n[1]) return n[0]
|
| 5496 |
+
},
|
| 5497 |
+
i,
|
| 5498 |
+
['box-shadow', 'text-shadow'],
|
| 5499 |
+
)
|
| 5500 |
+
})(ri),
|
| 5501 |
+
(function (t, e) {
|
| 5502 |
+
function i(t) {
|
| 5503 |
+
return t.toFixed(3).replace(/0+$/, '').replace(/\.$/, '')
|
| 5504 |
+
}
|
| 5505 |
+
function n(t, e, i) {
|
| 5506 |
+
return Math.min(e, Math.max(t, i))
|
| 5507 |
+
}
|
| 5508 |
+
function r(t) {
|
| 5509 |
+
if (/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t)) return Number(t)
|
| 5510 |
+
}
|
| 5511 |
+
function s(t, e) {
|
| 5512 |
+
return function (r, s) {
|
| 5513 |
+
return [
|
| 5514 |
+
r,
|
| 5515 |
+
s,
|
| 5516 |
+
function (r) {
|
| 5517 |
+
return i(n(t, e, r))
|
| 5518 |
+
},
|
| 5519 |
+
]
|
| 5520 |
+
}
|
| 5521 |
+
}
|
| 5522 |
+
function o(t) {
|
| 5523 |
+
var e = t.trim().split(/\s*[\s,]\s*/)
|
| 5524 |
+
if (0 !== e.length) {
|
| 5525 |
+
for (var i = [], n = 0; n < e.length; n++) {
|
| 5526 |
+
var s = r(e[n])
|
| 5527 |
+
if (void 0 === s) return
|
| 5528 |
+
i.push(s)
|
| 5529 |
+
}
|
| 5530 |
+
return i
|
| 5531 |
+
}
|
| 5532 |
+
}
|
| 5533 |
+
;(t.clamp = n),
|
| 5534 |
+
t.addPropertiesHandler(
|
| 5535 |
+
o,
|
| 5536 |
+
function (t, e) {
|
| 5537 |
+
if (t.length == e.length)
|
| 5538 |
+
return [
|
| 5539 |
+
t,
|
| 5540 |
+
e,
|
| 5541 |
+
function (t) {
|
| 5542 |
+
return t.map(i).join(' ')
|
| 5543 |
+
},
|
| 5544 |
+
]
|
| 5545 |
+
},
|
| 5546 |
+
['stroke-dasharray'],
|
| 5547 |
+
),
|
| 5548 |
+
t.addPropertiesHandler(r, s(0, 1 / 0), ['border-image-width', 'line-height']),
|
| 5549 |
+
t.addPropertiesHandler(r, s(0, 1), ['opacity', 'shape-image-threshold']),
|
| 5550 |
+
t.addPropertiesHandler(
|
| 5551 |
+
r,
|
| 5552 |
+
function (t, e) {
|
| 5553 |
+
if (0 != t) return s(0, 1 / 0)(t, e)
|
| 5554 |
+
},
|
| 5555 |
+
['flex-grow', 'flex-shrink'],
|
| 5556 |
+
),
|
| 5557 |
+
t.addPropertiesHandler(
|
| 5558 |
+
r,
|
| 5559 |
+
function (t, e) {
|
| 5560 |
+
return [
|
| 5561 |
+
t,
|
| 5562 |
+
e,
|
| 5563 |
+
function (t) {
|
| 5564 |
+
return Math.round(n(1, 1 / 0, t))
|
| 5565 |
+
},
|
| 5566 |
+
]
|
| 5567 |
+
},
|
| 5568 |
+
['orphans', 'widows'],
|
| 5569 |
+
),
|
| 5570 |
+
t.addPropertiesHandler(
|
| 5571 |
+
r,
|
| 5572 |
+
function (t, e) {
|
| 5573 |
+
return [t, e, Math.round]
|
| 5574 |
+
},
|
| 5575 |
+
['z-index'],
|
| 5576 |
+
),
|
| 5577 |
+
(t.parseNumber = r),
|
| 5578 |
+
(t.parseNumberList = o),
|
| 5579 |
+
(t.mergeNumbers = function (t, e) {
|
| 5580 |
+
return [t, e, i]
|
| 5581 |
+
}),
|
| 5582 |
+
(t.numberToString = i)
|
| 5583 |
+
})(ri),
|
| 5584 |
+
(function (t, e) {
|
| 5585 |
+
t.addPropertiesHandler(
|
| 5586 |
+
String,
|
| 5587 |
+
function (t, e) {
|
| 5588 |
+
if ('visible' == t || 'visible' == e)
|
| 5589 |
+
return [
|
| 5590 |
+
0,
|
| 5591 |
+
1,
|
| 5592 |
+
function (i) {
|
| 5593 |
+
return i <= 0 ? t : i >= 1 ? e : 'visible'
|
| 5594 |
+
},
|
| 5595 |
+
]
|
| 5596 |
+
},
|
| 5597 |
+
['visibility'],
|
| 5598 |
+
)
|
| 5599 |
+
})(ri),
|
| 5600 |
+
(function (t, e) {
|
| 5601 |
+
function i(t) {
|
| 5602 |
+
;(t = t.trim()), (s.fillStyle = '#000'), (s.fillStyle = t)
|
| 5603 |
+
var e = s.fillStyle
|
| 5604 |
+
if (((s.fillStyle = '#fff'), (s.fillStyle = t), e == s.fillStyle)) {
|
| 5605 |
+
s.fillRect(0, 0, 1, 1)
|
| 5606 |
+
var i = s.getImageData(0, 0, 1, 1).data
|
| 5607 |
+
s.clearRect(0, 0, 1, 1)
|
| 5608 |
+
var n = i[3] / 255
|
| 5609 |
+
return [i[0] * n, i[1] * n, i[2] * n, n]
|
| 5610 |
+
}
|
| 5611 |
+
}
|
| 5612 |
+
function n(e, i) {
|
| 5613 |
+
return [
|
| 5614 |
+
e,
|
| 5615 |
+
i,
|
| 5616 |
+
function (e) {
|
| 5617 |
+
function i(t) {
|
| 5618 |
+
return Math.max(0, Math.min(255, t))
|
| 5619 |
+
}
|
| 5620 |
+
if (e[3]) for (var n = 0; n < 3; n++) e[n] = Math.round(i(e[n] / e[3]))
|
| 5621 |
+
return (e[3] = t.numberToString(t.clamp(0, 1, e[3]))), 'rgba(' + e.join(',') + ')'
|
| 5622 |
+
},
|
| 5623 |
+
]
|
| 5624 |
+
}
|
| 5625 |
+
var r = document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas')
|
| 5626 |
+
r.width = r.height = 1
|
| 5627 |
+
var s = r.getContext('2d')
|
| 5628 |
+
t.addPropertiesHandler(i, n, [
|
| 5629 |
+
'background-color',
|
| 5630 |
+
'border-bottom-color',
|
| 5631 |
+
'border-left-color',
|
| 5632 |
+
'border-right-color',
|
| 5633 |
+
'border-top-color',
|
| 5634 |
+
'color',
|
| 5635 |
+
'fill',
|
| 5636 |
+
'flood-color',
|
| 5637 |
+
'lighting-color',
|
| 5638 |
+
'outline-color',
|
| 5639 |
+
'stop-color',
|
| 5640 |
+
'stroke',
|
| 5641 |
+
'text-decoration-color',
|
| 5642 |
+
]),
|
| 5643 |
+
(t.consumeColor = t.consumeParenthesised.bind(null, i)),
|
| 5644 |
+
(t.mergeColors = n)
|
| 5645 |
+
})(ri),
|
| 5646 |
+
(function (t, e) {
|
| 5647 |
+
function i(t) {
|
| 5648 |
+
function e() {
|
| 5649 |
+
var e = o.exec(t)
|
| 5650 |
+
s = e ? e[0] : void 0
|
| 5651 |
+
}
|
| 5652 |
+
function i() {
|
| 5653 |
+
if ('(' !== s)
|
| 5654 |
+
return (function () {
|
| 5655 |
+
var t = Number(s)
|
| 5656 |
+
return e(), t
|
| 5657 |
+
})()
|
| 5658 |
+
e()
|
| 5659 |
+
var t = r()
|
| 5660 |
+
return ')' !== s ? NaN : (e(), t)
|
| 5661 |
+
}
|
| 5662 |
+
function n() {
|
| 5663 |
+
for (var t = i(); '*' === s || '/' === s; ) {
|
| 5664 |
+
var n = s
|
| 5665 |
+
e()
|
| 5666 |
+
var r = i()
|
| 5667 |
+
'*' === n ? (t *= r) : (t /= r)
|
| 5668 |
+
}
|
| 5669 |
+
return t
|
| 5670 |
+
}
|
| 5671 |
+
function r() {
|
| 5672 |
+
for (var t = n(); '+' === s || '-' === s; ) {
|
| 5673 |
+
var i = s
|
| 5674 |
+
e()
|
| 5675 |
+
var r = n()
|
| 5676 |
+
'+' === i ? (t += r) : (t -= r)
|
| 5677 |
+
}
|
| 5678 |
+
return t
|
| 5679 |
+
}
|
| 5680 |
+
var s,
|
| 5681 |
+
o = /([\+\-\w\.]+|[\(\)\*\/])/g
|
| 5682 |
+
return e(), r()
|
| 5683 |
+
}
|
| 5684 |
+
function n(t, e) {
|
| 5685 |
+
if ('0' == (e = e.trim().toLowerCase()) && 'px'.search(t) >= 0) return { px: 0 }
|
| 5686 |
+
if (/^[^(]*$|^calc/.test(e)) {
|
| 5687 |
+
e = e.replace(/calc\(/g, '(')
|
| 5688 |
+
var n = {}
|
| 5689 |
+
e = e.replace(t, function (t) {
|
| 5690 |
+
return (n[t] = null), 'U' + t
|
| 5691 |
+
})
|
| 5692 |
+
for (
|
| 5693 |
+
var r = 'U(' + t.source + ')',
|
| 5694 |
+
s = e
|
| 5695 |
+
.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g, 'N')
|
| 5696 |
+
.replace(new RegExp('N' + r, 'g'), 'D')
|
| 5697 |
+
.replace(/\s[+-]\s/g, 'O')
|
| 5698 |
+
.replace(/\s/g, ''),
|
| 5699 |
+
o = [/N\*(D)/g, /(N|D)[*\/]N/g, /(N|D)O\1/g, /\((N|D)\)/g],
|
| 5700 |
+
a = 0;
|
| 5701 |
+
a < o.length;
|
| 5702 |
+
|
| 5703 |
+
)
|
| 5704 |
+
o[a].test(s) ? ((s = s.replace(o[a], '$1')), (a = 0)) : a++
|
| 5705 |
+
if ('D' == s) {
|
| 5706 |
+
for (var h in n) {
|
| 5707 |
+
var l = i(e.replace(new RegExp('U' + h, 'g'), '').replace(new RegExp(r, 'g'), '*0'))
|
| 5708 |
+
if (!isFinite(l)) return
|
| 5709 |
+
n[h] = l
|
| 5710 |
+
}
|
| 5711 |
+
return n
|
| 5712 |
+
}
|
| 5713 |
+
}
|
| 5714 |
+
}
|
| 5715 |
+
function r(t, e) {
|
| 5716 |
+
return s(t, e, !0)
|
| 5717 |
+
}
|
| 5718 |
+
function s(e, i, n) {
|
| 5719 |
+
var r,
|
| 5720 |
+
s = []
|
| 5721 |
+
for (r in e) s.push(r)
|
| 5722 |
+
for (r in i) s.indexOf(r) < 0 && s.push(r)
|
| 5723 |
+
return (
|
| 5724 |
+
(e = s.map(function (t) {
|
| 5725 |
+
return e[t] || 0
|
| 5726 |
+
})),
|
| 5727 |
+
(i = s.map(function (t) {
|
| 5728 |
+
return i[t] || 0
|
| 5729 |
+
})),
|
| 5730 |
+
[
|
| 5731 |
+
e,
|
| 5732 |
+
i,
|
| 5733 |
+
function (e) {
|
| 5734 |
+
var i = e
|
| 5735 |
+
.map(function (i, r) {
|
| 5736 |
+
return (
|
| 5737 |
+
1 == e.length && n && (i = Math.max(i, 0)), t.numberToString(i) + s[r]
|
| 5738 |
+
)
|
| 5739 |
+
})
|
| 5740 |
+
.join(' + ')
|
| 5741 |
+
return e.length > 1 ? 'calc(' + i + ')' : i
|
| 5742 |
+
},
|
| 5743 |
+
]
|
| 5744 |
+
)
|
| 5745 |
+
}
|
| 5746 |
+
var o = 'px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc',
|
| 5747 |
+
a = n.bind(null, new RegExp(o, 'g')),
|
| 5748 |
+
h = n.bind(null, new RegExp(o + '|%', 'g')),
|
| 5749 |
+
l = n.bind(null, /deg|rad|grad|turn/g)
|
| 5750 |
+
;(t.parseLength = a),
|
| 5751 |
+
(t.parseLengthOrPercent = h),
|
| 5752 |
+
(t.consumeLengthOrPercent = t.consumeParenthesised.bind(null, h)),
|
| 5753 |
+
(t.parseAngle = l),
|
| 5754 |
+
(t.mergeDimensions = s)
|
| 5755 |
+
var u = t.consumeParenthesised.bind(null, a),
|
| 5756 |
+
d = t.consumeRepeated.bind(void 0, u, /^/),
|
| 5757 |
+
c = t.consumeRepeated.bind(void 0, d, /^,/)
|
| 5758 |
+
t.consumeSizePairList = c
|
| 5759 |
+
var _ = t.mergeNestedRepeated.bind(void 0, r, ' '),
|
| 5760 |
+
f = t.mergeNestedRepeated.bind(void 0, _, ',')
|
| 5761 |
+
;(t.mergeNonNegativeSizePair = _),
|
| 5762 |
+
t.addPropertiesHandler(
|
| 5763 |
+
function (t) {
|
| 5764 |
+
var e = c(t)
|
| 5765 |
+
if (e && '' == e[1]) return e[0]
|
| 5766 |
+
},
|
| 5767 |
+
f,
|
| 5768 |
+
['background-size'],
|
| 5769 |
+
),
|
| 5770 |
+
t.addPropertiesHandler(h, r, [
|
| 5771 |
+
'border-bottom-width',
|
| 5772 |
+
'border-image-width',
|
| 5773 |
+
'border-left-width',
|
| 5774 |
+
'border-right-width',
|
| 5775 |
+
'border-top-width',
|
| 5776 |
+
'flex-basis',
|
| 5777 |
+
'font-size',
|
| 5778 |
+
'height',
|
| 5779 |
+
'line-height',
|
| 5780 |
+
'max-height',
|
| 5781 |
+
'max-width',
|
| 5782 |
+
'outline-width',
|
| 5783 |
+
'width',
|
| 5784 |
+
]),
|
| 5785 |
+
t.addPropertiesHandler(h, s, [
|
| 5786 |
+
'border-bottom-left-radius',
|
| 5787 |
+
'border-bottom-right-radius',
|
| 5788 |
+
'border-top-left-radius',
|
| 5789 |
+
'border-top-right-radius',
|
| 5790 |
+
'bottom',
|
| 5791 |
+
'left',
|
| 5792 |
+
'letter-spacing',
|
| 5793 |
+
'margin-bottom',
|
| 5794 |
+
'margin-left',
|
| 5795 |
+
'margin-right',
|
| 5796 |
+
'margin-top',
|
| 5797 |
+
'min-height',
|
| 5798 |
+
'min-width',
|
| 5799 |
+
'outline-offset',
|
| 5800 |
+
'padding-bottom',
|
| 5801 |
+
'padding-left',
|
| 5802 |
+
'padding-right',
|
| 5803 |
+
'padding-top',
|
| 5804 |
+
'perspective',
|
| 5805 |
+
'right',
|
| 5806 |
+
'shape-margin',
|
| 5807 |
+
'stroke-dashoffset',
|
| 5808 |
+
'text-indent',
|
| 5809 |
+
'top',
|
| 5810 |
+
'vertical-align',
|
| 5811 |
+
'word-spacing',
|
| 5812 |
+
])
|
| 5813 |
+
})(ri),
|
| 5814 |
+
(function (t, e) {
|
| 5815 |
+
function i(e) {
|
| 5816 |
+
return t.consumeLengthOrPercent(e) || t.consumeToken(/^auto/, e)
|
| 5817 |
+
}
|
| 5818 |
+
function n(e) {
|
| 5819 |
+
var n = t.consumeList(
|
| 5820 |
+
[
|
| 5821 |
+
t.ignore(t.consumeToken.bind(null, /^rect/)),
|
| 5822 |
+
t.ignore(t.consumeToken.bind(null, /^\(/)),
|
| 5823 |
+
t.consumeRepeated.bind(null, i, /^,/),
|
| 5824 |
+
t.ignore(t.consumeToken.bind(null, /^\)/)),
|
| 5825 |
+
],
|
| 5826 |
+
e,
|
| 5827 |
+
)
|
| 5828 |
+
if (n && 4 == n[0].length) return n[0]
|
| 5829 |
+
}
|
| 5830 |
+
var r = t.mergeWrappedNestedRepeated.bind(
|
| 5831 |
+
null,
|
| 5832 |
+
function (t) {
|
| 5833 |
+
return 'rect(' + t + ')'
|
| 5834 |
+
},
|
| 5835 |
+
function (e, i) {
|
| 5836 |
+
return 'auto' == e || 'auto' == i
|
| 5837 |
+
? [
|
| 5838 |
+
!0,
|
| 5839 |
+
!1,
|
| 5840 |
+
function (n) {
|
| 5841 |
+
var r = n ? e : i
|
| 5842 |
+
if ('auto' == r) return 'auto'
|
| 5843 |
+
var s = t.mergeDimensions(r, r)
|
| 5844 |
+
return s[2](s[0])
|
| 5845 |
+
},
|
| 5846 |
+
]
|
| 5847 |
+
: t.mergeDimensions(e, i)
|
| 5848 |
+
},
|
| 5849 |
+
', ',
|
| 5850 |
+
)
|
| 5851 |
+
;(t.parseBox = n), (t.mergeBoxes = r), t.addPropertiesHandler(n, r, ['clip'])
|
| 5852 |
+
})(ri),
|
| 5853 |
+
(function (t, e) {
|
| 5854 |
+
function i(t) {
|
| 5855 |
+
return function (e) {
|
| 5856 |
+
var i = 0
|
| 5857 |
+
return t.map(function (t) {
|
| 5858 |
+
return t === l ? e[i++] : t
|
| 5859 |
+
})
|
| 5860 |
+
}
|
| 5861 |
+
}
|
| 5862 |
+
function n(t) {
|
| 5863 |
+
return t
|
| 5864 |
+
}
|
| 5865 |
+
function r(e) {
|
| 5866 |
+
if ('none' == (e = e.toLowerCase().trim())) return []
|
| 5867 |
+
for (var i, n = /\s*(\w+)\(([^)]*)\)/g, r = [], s = 0; (i = n.exec(e)); ) {
|
| 5868 |
+
if (i.index != s) return
|
| 5869 |
+
s = i.index + i[0].length
|
| 5870 |
+
var o = i[1],
|
| 5871 |
+
a = c[o]
|
| 5872 |
+
if (!a) return
|
| 5873 |
+
var h = i[2].split(','),
|
| 5874 |
+
l = a[0]
|
| 5875 |
+
if (l.length < h.length) return
|
| 5876 |
+
for (var _ = [], f = 0; f < l.length; f++) {
|
| 5877 |
+
var p,
|
| 5878 |
+
m = h[f],
|
| 5879 |
+
g = l[f]
|
| 5880 |
+
if (
|
| 5881 |
+
void 0 ===
|
| 5882 |
+
(p = m
|
| 5883 |
+
? {
|
| 5884 |
+
A: function (e) {
|
| 5885 |
+
return '0' == e.trim() ? d : t.parseAngle(e)
|
| 5886 |
+
},
|
| 5887 |
+
N: t.parseNumber,
|
| 5888 |
+
T: t.parseLengthOrPercent,
|
| 5889 |
+
L: t.parseLength,
|
| 5890 |
+
}[g.toUpperCase()](m)
|
| 5891 |
+
: { a: d, n: _[0], t: u }[g])
|
| 5892 |
+
)
|
| 5893 |
+
return
|
| 5894 |
+
_.push(p)
|
| 5895 |
+
}
|
| 5896 |
+
if ((r.push({ t: o, d: _ }), n.lastIndex == e.length)) return r
|
| 5897 |
+
}
|
| 5898 |
+
}
|
| 5899 |
+
function s(t) {
|
| 5900 |
+
return t.toFixed(6).replace('.000000', '')
|
| 5901 |
+
}
|
| 5902 |
+
function o(e, i) {
|
| 5903 |
+
if (e.decompositionPair !== i) {
|
| 5904 |
+
e.decompositionPair = i
|
| 5905 |
+
var n = t.makeMatrixDecomposition(e)
|
| 5906 |
+
}
|
| 5907 |
+
if (i.decompositionPair !== e) {
|
| 5908 |
+
i.decompositionPair = e
|
| 5909 |
+
var r = t.makeMatrixDecomposition(i)
|
| 5910 |
+
}
|
| 5911 |
+
return null == n[0] || null == r[0]
|
| 5912 |
+
? [
|
| 5913 |
+
[!1],
|
| 5914 |
+
[!0],
|
| 5915 |
+
function (t) {
|
| 5916 |
+
return t ? i[0].d : e[0].d
|
| 5917 |
+
},
|
| 5918 |
+
]
|
| 5919 |
+
: (n[0].push(0),
|
| 5920 |
+
r[0].push(1),
|
| 5921 |
+
[
|
| 5922 |
+
n,
|
| 5923 |
+
r,
|
| 5924 |
+
function (e) {
|
| 5925 |
+
var i = t.quat(n[0][3], r[0][3], e[5])
|
| 5926 |
+
return t.composeMatrix(e[0], e[1], e[2], i, e[4]).map(s).join(',')
|
| 5927 |
+
},
|
| 5928 |
+
])
|
| 5929 |
+
}
|
| 5930 |
+
function a(t) {
|
| 5931 |
+
return t.replace(/[xy]/, '')
|
| 5932 |
+
}
|
| 5933 |
+
function h(t) {
|
| 5934 |
+
return t.replace(/(x|y|z|3d)?$/, '3d')
|
| 5935 |
+
}
|
| 5936 |
+
var l = null,
|
| 5937 |
+
u = { px: 0 },
|
| 5938 |
+
d = { deg: 0 },
|
| 5939 |
+
c = {
|
| 5940 |
+
matrix: ['NNNNNN', [l, l, 0, 0, l, l, 0, 0, 0, 0, 1, 0, l, l, 0, 1], n],
|
| 5941 |
+
matrix3d: ['NNNNNNNNNNNNNNNN', n],
|
| 5942 |
+
rotate: ['A'],
|
| 5943 |
+
rotatex: ['A'],
|
| 5944 |
+
rotatey: ['A'],
|
| 5945 |
+
rotatez: ['A'],
|
| 5946 |
+
rotate3d: ['NNNA'],
|
| 5947 |
+
perspective: ['L'],
|
| 5948 |
+
scale: ['Nn', i([l, l, 1]), n],
|
| 5949 |
+
scalex: ['N', i([l, 1, 1]), i([l, 1])],
|
| 5950 |
+
scaley: ['N', i([1, l, 1]), i([1, l])],
|
| 5951 |
+
scalez: ['N', i([1, 1, l])],
|
| 5952 |
+
scale3d: ['NNN', n],
|
| 5953 |
+
skew: ['Aa', null, n],
|
| 5954 |
+
skewx: ['A', null, i([l, d])],
|
| 5955 |
+
skewy: ['A', null, i([d, l])],
|
| 5956 |
+
translate: ['Tt', i([l, l, u]), n],
|
| 5957 |
+
translatex: ['T', i([l, u, u]), i([l, u])],
|
| 5958 |
+
translatey: ['T', i([u, l, u]), i([u, l])],
|
| 5959 |
+
translatez: ['L', i([u, u, l])],
|
| 5960 |
+
translate3d: ['TTL', n],
|
| 5961 |
+
}
|
| 5962 |
+
t.addPropertiesHandler(
|
| 5963 |
+
r,
|
| 5964 |
+
function (e, i) {
|
| 5965 |
+
var n = t.makeMatrixDecomposition && !0,
|
| 5966 |
+
r = !1
|
| 5967 |
+
if (!e.length || !i.length) {
|
| 5968 |
+
e.length || ((r = !0), (e = i), (i = []))
|
| 5969 |
+
for (var s = 0; s < e.length; s++) {
|
| 5970 |
+
var l = e[s].t,
|
| 5971 |
+
u = e[s].d,
|
| 5972 |
+
d = 'scale' == l.substr(0, 5) ? 1 : 0
|
| 5973 |
+
i.push({
|
| 5974 |
+
t: l,
|
| 5975 |
+
d: u.map(function (t) {
|
| 5976 |
+
if ('number' == typeof t) return d
|
| 5977 |
+
var e = {}
|
| 5978 |
+
for (var i in t) e[i] = d
|
| 5979 |
+
return e
|
| 5980 |
+
}),
|
| 5981 |
+
})
|
| 5982 |
+
}
|
| 5983 |
+
}
|
| 5984 |
+
var _ = function (t, e) {
|
| 5985 |
+
return (
|
| 5986 |
+
('perspective' == t && 'perspective' == e) ||
|
| 5987 |
+
(('matrix' == t || 'matrix3d' == t) && ('matrix' == e || 'matrix3d' == e))
|
| 5988 |
+
)
|
| 5989 |
+
},
|
| 5990 |
+
f = [],
|
| 5991 |
+
p = [],
|
| 5992 |
+
m = []
|
| 5993 |
+
if (e.length != i.length) {
|
| 5994 |
+
if (!n) return
|
| 5995 |
+
;(f = [(T = o(e, i))[0]]), (p = [T[1]]), (m = [['matrix', [T[2]]]])
|
| 5996 |
+
} else
|
| 5997 |
+
for (s = 0; s < e.length; s++) {
|
| 5998 |
+
var g = e[s].t,
|
| 5999 |
+
v = i[s].t,
|
| 6000 |
+
y = e[s].d,
|
| 6001 |
+
b = i[s].d,
|
| 6002 |
+
w = c[g],
|
| 6003 |
+
S = c[v]
|
| 6004 |
+
if (_(g, v)) {
|
| 6005 |
+
if (!n) return
|
| 6006 |
+
var T = o([e[s]], [i[s]])
|
| 6007 |
+
f.push(T[0]), p.push(T[1]), m.push(['matrix', [T[2]]])
|
| 6008 |
+
} else {
|
| 6009 |
+
if (g == v) l = g
|
| 6010 |
+
else if (w[2] && S[2] && a(g) == a(v)) (l = a(g)), (y = w[2](y)), (b = S[2](b))
|
| 6011 |
+
else {
|
| 6012 |
+
if (!w[1] || !S[1] || h(g) != h(v)) {
|
| 6013 |
+
if (!n) return
|
| 6014 |
+
;(f = [(T = o(e, i))[0]]), (p = [T[1]]), (m = [['matrix', [T[2]]]])
|
| 6015 |
+
break
|
| 6016 |
+
}
|
| 6017 |
+
;(l = h(g)), (y = w[1](y)), (b = S[1](b))
|
| 6018 |
+
}
|
| 6019 |
+
for (var D = [], x = [], A = [], k = 0; k < y.length; k++)
|
| 6020 |
+
(T = ('number' == typeof y[k] ? t.mergeNumbers : t.mergeDimensions)(
|
| 6021 |
+
y[k],
|
| 6022 |
+
b[k],
|
| 6023 |
+
)),
|
| 6024 |
+
(D[k] = T[0]),
|
| 6025 |
+
(x[k] = T[1]),
|
| 6026 |
+
A.push(T[2])
|
| 6027 |
+
f.push(D), p.push(x), m.push([l, A])
|
| 6028 |
+
}
|
| 6029 |
+
}
|
| 6030 |
+
if (r) {
|
| 6031 |
+
var E = f
|
| 6032 |
+
;(f = p), (p = E)
|
| 6033 |
+
}
|
| 6034 |
+
return [
|
| 6035 |
+
f,
|
| 6036 |
+
p,
|
| 6037 |
+
function (t) {
|
| 6038 |
+
return t
|
| 6039 |
+
.map(function (t, e) {
|
| 6040 |
+
var i = t
|
| 6041 |
+
.map(function (t, i) {
|
| 6042 |
+
return m[e][1][i](t)
|
| 6043 |
+
})
|
| 6044 |
+
.join(',')
|
| 6045 |
+
return (
|
| 6046 |
+
'matrix' == m[e][0] &&
|
| 6047 |
+
16 == i.split(',').length &&
|
| 6048 |
+
(m[e][0] = 'matrix3d'),
|
| 6049 |
+
m[e][0] + '(' + i + ')'
|
| 6050 |
+
)
|
| 6051 |
+
})
|
| 6052 |
+
.join(' ')
|
| 6053 |
+
},
|
| 6054 |
+
]
|
| 6055 |
+
},
|
| 6056 |
+
['transform'],
|
| 6057 |
+
),
|
| 6058 |
+
(t.transformToSvgMatrix = function (e) {
|
| 6059 |
+
var i = t.transformListToMatrix(r(e))
|
| 6060 |
+
return (
|
| 6061 |
+
'matrix(' +
|
| 6062 |
+
s(i[0]) +
|
| 6063 |
+
' ' +
|
| 6064 |
+
s(i[1]) +
|
| 6065 |
+
' ' +
|
| 6066 |
+
s(i[4]) +
|
| 6067 |
+
' ' +
|
| 6068 |
+
s(i[5]) +
|
| 6069 |
+
' ' +
|
| 6070 |
+
s(i[12]) +
|
| 6071 |
+
' ' +
|
| 6072 |
+
s(i[13]) +
|
| 6073 |
+
')'
|
| 6074 |
+
)
|
| 6075 |
+
})
|
| 6076 |
+
})(ri),
|
| 6077 |
+
(function (t) {
|
| 6078 |
+
function e(e) {
|
| 6079 |
+
return (
|
| 6080 |
+
(e = 100 * Math.round(e / 100)),
|
| 6081 |
+
400 === (e = t.clamp(100, 900, e)) ? 'normal' : 700 === e ? 'bold' : String(e)
|
| 6082 |
+
)
|
| 6083 |
+
}
|
| 6084 |
+
t.addPropertiesHandler(
|
| 6085 |
+
function (t) {
|
| 6086 |
+
var e = Number(t)
|
| 6087 |
+
if (!(isNaN(e) || e < 100 || e > 900 || e % 100 != 0)) return e
|
| 6088 |
+
},
|
| 6089 |
+
function (t, i) {
|
| 6090 |
+
return [t, i, e]
|
| 6091 |
+
},
|
| 6092 |
+
['font-weight'],
|
| 6093 |
+
)
|
| 6094 |
+
})(ri),
|
| 6095 |
+
(function (t) {
|
| 6096 |
+
function e(t) {
|
| 6097 |
+
var e = {}
|
| 6098 |
+
for (var i in t) e[i] = -t[i]
|
| 6099 |
+
return e
|
| 6100 |
+
}
|
| 6101 |
+
function i(e) {
|
| 6102 |
+
return t.consumeToken(/^(left|center|right|top|bottom)\b/i, e) || t.consumeLengthOrPercent(e)
|
| 6103 |
+
}
|
| 6104 |
+
function n(e, n) {
|
| 6105 |
+
var r = t.consumeRepeated(i, /^/, n)
|
| 6106 |
+
if (r && '' == r[1]) {
|
| 6107 |
+
var o = r[0]
|
| 6108 |
+
if (
|
| 6109 |
+
((o[0] = o[0] || 'center'),
|
| 6110 |
+
(o[1] = o[1] || 'center'),
|
| 6111 |
+
3 == e && (o[2] = o[2] || { px: 0 }),
|
| 6112 |
+
o.length == e)
|
| 6113 |
+
) {
|
| 6114 |
+
if (/top|bottom/.test(o[0]) || /left|right/.test(o[1])) {
|
| 6115 |
+
var a = o[0]
|
| 6116 |
+
;(o[0] = o[1]), (o[1] = a)
|
| 6117 |
+
}
|
| 6118 |
+
if (/left|right|center|Object/.test(o[0]) && /top|bottom|center|Object/.test(o[1]))
|
| 6119 |
+
return o.map(function (t) {
|
| 6120 |
+
return 'object' == typeof t ? t : s[t]
|
| 6121 |
+
})
|
| 6122 |
+
}
|
| 6123 |
+
}
|
| 6124 |
+
}
|
| 6125 |
+
function r(n) {
|
| 6126 |
+
var r = t.consumeRepeated(i, /^/, n)
|
| 6127 |
+
if (r) {
|
| 6128 |
+
for (
|
| 6129 |
+
var o = r[0], a = [{ '%': 50 }, { '%': 50 }], h = 0, l = !1, u = 0;
|
| 6130 |
+
u < o.length;
|
| 6131 |
+
u++
|
| 6132 |
+
) {
|
| 6133 |
+
var d = o[u]
|
| 6134 |
+
'string' == typeof d
|
| 6135 |
+
? ((l = /bottom|right/.test(d)),
|
| 6136 |
+
(a[(h = { left: 0, right: 0, center: h, top: 1, bottom: 1 }[d])] = s[d]),
|
| 6137 |
+
'center' == d && h++)
|
| 6138 |
+
: (l && ((d = e(d))['%'] = (d['%'] || 0) + 100), (a[h] = d), h++, (l = !1))
|
| 6139 |
+
}
|
| 6140 |
+
return [a, r[1]]
|
| 6141 |
+
}
|
| 6142 |
+
}
|
| 6143 |
+
var s = {
|
| 6144 |
+
left: { '%': 0 },
|
| 6145 |
+
center: { '%': 50 },
|
| 6146 |
+
right: { '%': 100 },
|
| 6147 |
+
top: { '%': 0 },
|
| 6148 |
+
bottom: { '%': 100 },
|
| 6149 |
+
},
|
| 6150 |
+
o = t.mergeNestedRepeated.bind(null, t.mergeDimensions, ' ')
|
| 6151 |
+
t.addPropertiesHandler(n.bind(null, 3), o, ['transform-origin']),
|
| 6152 |
+
t.addPropertiesHandler(n.bind(null, 2), o, ['perspective-origin']),
|
| 6153 |
+
(t.consumePosition = r),
|
| 6154 |
+
(t.mergeOffsetList = o)
|
| 6155 |
+
var a = t.mergeNestedRepeated.bind(null, o, ', ')
|
| 6156 |
+
t.addPropertiesHandler(
|
| 6157 |
+
function (e) {
|
| 6158 |
+
var i = t.consumeRepeated(r, /^,/, e)
|
| 6159 |
+
if (i && '' == i[1]) return i[0]
|
| 6160 |
+
},
|
| 6161 |
+
a,
|
| 6162 |
+
['background-position', 'object-position'],
|
| 6163 |
+
)
|
| 6164 |
+
})(ri),
|
| 6165 |
+
(function (t) {
|
| 6166 |
+
var e = t.consumeParenthesised.bind(null, t.parseLengthOrPercent),
|
| 6167 |
+
i = t.consumeRepeated.bind(void 0, e, /^/),
|
| 6168 |
+
n = t.mergeNestedRepeated.bind(void 0, t.mergeDimensions, ' '),
|
| 6169 |
+
r = t.mergeNestedRepeated.bind(void 0, n, ',')
|
| 6170 |
+
t.addPropertiesHandler(
|
| 6171 |
+
function (n) {
|
| 6172 |
+
var r = t.consumeToken(/^circle/, n)
|
| 6173 |
+
if (r && r[0])
|
| 6174 |
+
return ['circle'].concat(
|
| 6175 |
+
t.consumeList(
|
| 6176 |
+
[
|
| 6177 |
+
t.ignore(t.consumeToken.bind(void 0, /^\(/)),
|
| 6178 |
+
e,
|
| 6179 |
+
t.ignore(t.consumeToken.bind(void 0, /^at/)),
|
| 6180 |
+
t.consumePosition,
|
| 6181 |
+
t.ignore(t.consumeToken.bind(void 0, /^\)/)),
|
| 6182 |
+
],
|
| 6183 |
+
r[1],
|
| 6184 |
+
),
|
| 6185 |
+
)
|
| 6186 |
+
var s = t.consumeToken(/^ellipse/, n)
|
| 6187 |
+
if (s && s[0])
|
| 6188 |
+
return ['ellipse'].concat(
|
| 6189 |
+
t.consumeList(
|
| 6190 |
+
[
|
| 6191 |
+
t.ignore(t.consumeToken.bind(void 0, /^\(/)),
|
| 6192 |
+
i,
|
| 6193 |
+
t.ignore(t.consumeToken.bind(void 0, /^at/)),
|
| 6194 |
+
t.consumePosition,
|
| 6195 |
+
t.ignore(t.consumeToken.bind(void 0, /^\)/)),
|
| 6196 |
+
],
|
| 6197 |
+
s[1],
|
| 6198 |
+
),
|
| 6199 |
+
)
|
| 6200 |
+
var o = t.consumeToken(/^polygon/, n)
|
| 6201 |
+
return o && o[0]
|
| 6202 |
+
? ['polygon'].concat(
|
| 6203 |
+
t.consumeList(
|
| 6204 |
+
[
|
| 6205 |
+
t.ignore(t.consumeToken.bind(void 0, /^\(/)),
|
| 6206 |
+
t.optional(
|
| 6207 |
+
t.consumeToken.bind(void 0, /^nonzero\s*,|^evenodd\s*,/),
|
| 6208 |
+
'nonzero,',
|
| 6209 |
+
),
|
| 6210 |
+
t.consumeSizePairList,
|
| 6211 |
+
t.ignore(t.consumeToken.bind(void 0, /^\)/)),
|
| 6212 |
+
],
|
| 6213 |
+
o[1],
|
| 6214 |
+
),
|
| 6215 |
+
)
|
| 6216 |
+
: void 0
|
| 6217 |
+
},
|
| 6218 |
+
function (e, i) {
|
| 6219 |
+
if (e[0] === i[0])
|
| 6220 |
+
return 'circle' == e[0]
|
| 6221 |
+
? t.mergeList(e.slice(1), i.slice(1), [
|
| 6222 |
+
'circle(',
|
| 6223 |
+
t.mergeDimensions,
|
| 6224 |
+
' at ',
|
| 6225 |
+
t.mergeOffsetList,
|
| 6226 |
+
')',
|
| 6227 |
+
])
|
| 6228 |
+
: 'ellipse' == e[0]
|
| 6229 |
+
? t.mergeList(e.slice(1), i.slice(1), [
|
| 6230 |
+
'ellipse(',
|
| 6231 |
+
t.mergeNonNegativeSizePair,
|
| 6232 |
+
' at ',
|
| 6233 |
+
t.mergeOffsetList,
|
| 6234 |
+
')',
|
| 6235 |
+
])
|
| 6236 |
+
: 'polygon' == e[0] && e[1] == i[1]
|
| 6237 |
+
? t.mergeList(e.slice(2), i.slice(2), ['polygon(', e[1], r, ')'])
|
| 6238 |
+
: void 0
|
| 6239 |
+
},
|
| 6240 |
+
['shape-outside'],
|
| 6241 |
+
)
|
| 6242 |
+
})(ri),
|
| 6243 |
+
(function (t, e) {
|
| 6244 |
+
function i(t, e) {
|
| 6245 |
+
e.concat([t]).forEach(function (e) {
|
| 6246 |
+
e in document.documentElement.style && (n[t] = e), (r[e] = t)
|
| 6247 |
+
})
|
| 6248 |
+
}
|
| 6249 |
+
var n = {},
|
| 6250 |
+
r = {}
|
| 6251 |
+
i('transform', ['webkitTransform', 'msTransform']),
|
| 6252 |
+
i('transformOrigin', ['webkitTransformOrigin']),
|
| 6253 |
+
i('perspective', ['webkitPerspective']),
|
| 6254 |
+
i('perspectiveOrigin', ['webkitPerspectiveOrigin']),
|
| 6255 |
+
(t.propertyName = function (t) {
|
| 6256 |
+
return n[t] || t
|
| 6257 |
+
}),
|
| 6258 |
+
(t.unprefixedPropertyName = function (t) {
|
| 6259 |
+
return r[t] || t
|
| 6260 |
+
})
|
| 6261 |
+
})(ri)
|
| 6262 |
+
})(),
|
| 6263 |
+
(function () {
|
| 6264 |
+
if (void 0 === document.createElement('div').animate([]).oncancel) {
|
| 6265 |
+
if (window.performance && performance.now)
|
| 6266 |
+
var t = function () {
|
| 6267 |
+
return performance.now()
|
| 6268 |
+
}
|
| 6269 |
+
else
|
| 6270 |
+
t = function () {
|
| 6271 |
+
return Date.now()
|
| 6272 |
+
}
|
| 6273 |
+
var e = function (t, e, i) {
|
| 6274 |
+
;(this.target = t),
|
| 6275 |
+
(this.currentTime = e),
|
| 6276 |
+
(this.timelineTime = i),
|
| 6277 |
+
(this.type = 'cancel'),
|
| 6278 |
+
(this.bubbles = !1),
|
| 6279 |
+
(this.cancelable = !1),
|
| 6280 |
+
(this.currentTarget = t),
|
| 6281 |
+
(this.defaultPrevented = !1),
|
| 6282 |
+
(this.eventPhase = Event.AT_TARGET),
|
| 6283 |
+
(this.timeStamp = Date.now())
|
| 6284 |
+
},
|
| 6285 |
+
i = window.Element.prototype.animate
|
| 6286 |
+
window.Element.prototype.animate = function (n, r) {
|
| 6287 |
+
var s = i.call(this, n, r)
|
| 6288 |
+
;(s._cancelHandlers = []), (s.oncancel = null)
|
| 6289 |
+
var o = s.cancel
|
| 6290 |
+
s.cancel = function () {
|
| 6291 |
+
o.call(this)
|
| 6292 |
+
var i = new e(this, null, t()),
|
| 6293 |
+
n = this._cancelHandlers.concat(this.oncancel ? [this.oncancel] : [])
|
| 6294 |
+
setTimeout(function () {
|
| 6295 |
+
n.forEach(function (t) {
|
| 6296 |
+
t.call(i.target, i)
|
| 6297 |
+
})
|
| 6298 |
+
}, 0)
|
| 6299 |
+
}
|
| 6300 |
+
var a = s.addEventListener
|
| 6301 |
+
s.addEventListener = function (t, e) {
|
| 6302 |
+
'function' == typeof e && 'cancel' == t ? this._cancelHandlers.push(e) : a.call(this, t, e)
|
| 6303 |
+
}
|
| 6304 |
+
var h = s.removeEventListener
|
| 6305 |
+
return (
|
| 6306 |
+
(s.removeEventListener = function (t, e) {
|
| 6307 |
+
if ('cancel' == t) {
|
| 6308 |
+
var i = this._cancelHandlers.indexOf(e)
|
| 6309 |
+
i >= 0 && this._cancelHandlers.splice(i, 1)
|
| 6310 |
+
} else h.call(this, t, e)
|
| 6311 |
+
}),
|
| 6312 |
+
s
|
| 6313 |
+
)
|
| 6314 |
+
}
|
| 6315 |
+
}
|
| 6316 |
+
})(),
|
| 6317 |
+
(function (t) {
|
| 6318 |
+
var e = document.documentElement,
|
| 6319 |
+
i = null,
|
| 6320 |
+
n = !1
|
| 6321 |
+
try {
|
| 6322 |
+
var r = '0' == getComputedStyle(e).getPropertyValue('opacity') ? '1' : '0'
|
| 6323 |
+
;((i = e.animate({ opacity: [r, r] }, { duration: 1 })).currentTime = 0),
|
| 6324 |
+
(n = getComputedStyle(e).getPropertyValue('opacity') == r)
|
| 6325 |
+
} catch (t) {
|
| 6326 |
+
} finally {
|
| 6327 |
+
i && i.cancel()
|
| 6328 |
+
}
|
| 6329 |
+
if (!n) {
|
| 6330 |
+
var s = window.Element.prototype.animate
|
| 6331 |
+
window.Element.prototype.animate = function (e, i) {
|
| 6332 |
+
return (
|
| 6333 |
+
window.Symbol &&
|
| 6334 |
+
Symbol.iterator &&
|
| 6335 |
+
Array.prototype.from &&
|
| 6336 |
+
e[Symbol.iterator] &&
|
| 6337 |
+
(e = Array.from(e)),
|
| 6338 |
+
Array.isArray(e) || null === e || (e = t.convertToArrayForm(e)),
|
| 6339 |
+
s.call(this, e, i)
|
| 6340 |
+
)
|
| 6341 |
+
}
|
| 6342 |
+
}
|
| 6343 |
+
})(ni),
|
| 6344 |
+
(window.MetaGallery = li)
|
| 6345 |
+
})
|
metagallery/public/build/metagallery.js
CHANGED
|
@@ -1,22 +1,9023 @@
|
|
| 1 |
-
!function(t){"function"==typeof define&&define.amd?define(t):t()}((function(){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function e(t){var e={exports:{}};return t(e,e.exports),e.exports}e((function(t,e){t.exports=function(){var t=function(){if(!window.Alpine)throw new Error("[Magic Helpers] Alpine is required for the magic helpers to function correctly.");if(!window.Alpine.version||!s("2.5.0",window.Alpine.version))throw new Error("Invalid Alpine version. Please use Alpine version 2.5.0 or above")},e=function(t,e,i){e.getAttribute("x-bind:data-last-refresh")||e.setAttribute("x-bind:data-last-refresh","Date.now()");var n=function t(n){return void 0===n&&(n=null),{get:function(e,i){if(null!==e[i]&&"object"==typeof e[i]){var r=n?n+"."+i:i;return new Proxy(e[i],t(r))}return e[i]},set:function(t,r,s){if(!e.__x)throw new Error("Error communicating with observed component");var o=n?n+"."+r:r;return i.call(e,e.__x.$data,o,s),!0}}};return new Proxy(t,n())},i=function(t,e){t.getAttribute("x-bind:data-last-refresh")||t.setAttribute("x-bind:data-last-refresh","Date.now()"),new MutationObserver((function(i){for(var n=0;n<i.length;n++){var r=i[n].target.closest("[x-data]");if(!r||r.isSameNode(t))return void e()}})).observe(t,{attributes:!0,childList:!0,subtree:!0})},n=function(t,e,i){return(e=e.toString().match(/[^.[\]]+/g)||[]).slice(0,-1).reduce((function(t,i,n){return Object(t[i])!==t[i]&&(t[i]=Math.abs(e[n+1])>>0==+e[n+1]?[]:{}),t[i]}),t)[e[e.length-1]]=i,t},r=function(t){return t.__x?t.__x.getUnobservedData():o(t.getAttribute("x-data"),t)};function s(t,e){for(var i=t.split("."),n=e.split("."),r=0;r<i.length;r++)if(!n[r]||parseInt(n[r])<parseInt(i[r]))return!1;return!0}function o(t,e,i){return void 0===i&&(i={}),"function"==typeof t?t.call(e):new Function(["$data"].concat(Object.keys(i)),"var __alpine_result; with($data) { __alpine_result = "+t+" }; return __alpine_result").apply(void 0,[e].concat(Object.values(i)))}var a={start:function(){t(),Alpine.addMagicProperty("parent",(function(t){if(void 0!==t.$parent)return t.$parent;var s=t.parentNode.closest("[x-data]");if(!s)throw new Error("Parent component not found");return t.$parent=e(r(s),s,n),i(s,(function(){t.$parent=e(s.__x.getUnobservedData(),s,n),t.__x.updateElements(t)})),t.$parent})),Alpine.addMagicProperty("component",(function(t){return function(s){var o=this;if(void 0!==this[s])return this[s];var a=document.querySelector('[x-data][x-id="'+s+'"], [x-data]#'+s);if(!a)throw new Error("Component not found");return this[s]=e(r(a),a,n),i(a,(function(){o[s]=e(a.__x.getUnobservedData(),a,n),t.__x.updateElements(t)})),this[s]}}))}},l=window.deferLoadingAlpine||function(t){return t()};return window.deferLoadingAlpine=function(t){l(t),a.start()},a}()}));const i={start(){if(!window.Alpine)throw new Error("Alpine is required for `alpine-clipboard` to work.");Alpine.addMagicProperty("clipboard",(()=>function(t){let e=t;if("function"==typeof e)e=e();else if("string"!=typeof e)try{e=JSON.stringify(e)}catch(t){console.warn(t)}const i=document.createElement("textarea");if(i.value=e,i.setAttribute("readonly",""),i.style.cssText="position:fixed;pointer-events:none;z-index:-9999;opacity:0;",document.body.appendChild(i),navigator.userAgent&&navigator.userAgent.match(/ipad|ipod|iphone/i)){i.contentEditable=!0,i.readOnly=!0;const t=document.createRange();t.selectNodeContents(i);const e=window.getSelection();e.removeAllRanges(),e.addRange(t),i.setSelectionRange(0,999999)}else i.select();try{document.execCommand("copy")}catch(t){console.warn(err)}document.body.removeChild(i)}))}},n=window.deferLoadingAlpine||(t=>t());window.deferLoadingAlpine=function(t){i.start(),n(t)};e((function(t,e){t.exports=function(){function t(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function e(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,n)}return i}function i(i){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?e(Object(r),!0).forEach((function(e){t(i,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(r)):e(Object(r)).forEach((function(t){Object.defineProperty(i,t,Object.getOwnPropertyDescriptor(r,t))}))}return i}function n(){return new Promise((t=>{"loading"==document.readyState?document.addEventListener("DOMContentLoaded",t):t()}))}function r(t){return Array.from(new Set(t))}function s(){return navigator.userAgent.includes("Node.js")||navigator.userAgent.includes("jsdom")}function o(t,e){return t==e}function a(t,e){"template"!==t.tagName.toLowerCase()?console.warn(`Alpine: [${e}] directive should only be added to <template> tags. See https://github.com/alpinejs/alpine#${e}`):1!==t.content.childElementCount&&console.warn(`Alpine: <template> tag with [${e}] encountered with multiple element roots. Make sure <template> only has a single child element.`)}function l(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[_\s]/,"-").toLowerCase()}function h(t){return t.toLowerCase().replace(/-(\w)/g,((t,e)=>e.toUpperCase()))}function u(t,e){if(!1===e(t))return;let i=t.firstElementChild;for(;i;)u(i,e),i=i.nextElementSibling}function c(t,e){var i;return function(){var n=this,r=arguments,s=function(){i=null,t.apply(n,r)};clearTimeout(i),i=setTimeout(s,e)}}const d=(t,e,i)=>{if(console.warn(`Alpine Error: "${i}"\n\nExpression: "${e}"\nElement:`,t),!s())throw i};function f(t,{el:e,expression:i}){try{const n=t();return n instanceof Promise?n.catch((t=>d(e,i,t))):n}catch(t){d(e,i,t)}}function p(t,e,i,n={}){return f((()=>"function"==typeof e?e.call(i):new Function(["$data",...Object.keys(n)],`var __alpine_result; with($data) { __alpine_result = ${e} }; return __alpine_result`)(i,...Object.values(n))),{el:t,expression:e})}function _(t,e,i,n={}){return f((()=>{if("function"==typeof e)return Promise.resolve(e.call(i,n.$event));let t=Function;if(t=Object.getPrototypeOf((async function(){})).constructor,Object.keys(i).includes(e)){let t=new Function(["dataContext",...Object.keys(n)],`with(dataContext) { return ${e} }`)(i,...Object.values(n));return"function"==typeof t?Promise.resolve(t.call(i,n.$event)):Promise.resolve()}return Promise.resolve(new t(["dataContext",...Object.keys(n)],`with(dataContext) { ${e} }`)(i,...Object.values(n)))}),{el:t,expression:e})}const m=/^x-(on|bind|data|text|html|model|if|for|show|cloak|transition|ref|spread)\b/;function g(t){const e=x(t.name);return m.test(e)}function v(t,e,i){let n=Array.from(t.attributes).filter(g).map(b),r=n.filter((t=>"spread"===t.type))[0];if(r){let i=p(t,r.expression,e.$data);n=n.concat(Object.entries(i).map((([t,e])=>b({name:t,value:e}))))}return i?n.filter((t=>t.type===i)):y(n)}function y(t){let e=["bind","model","show","catch-all"];return t.sort(((t,i)=>{let n=-1===e.indexOf(t.type)?"catch-all":t.type,r=-1===e.indexOf(i.type)?"catch-all":i.type;return e.indexOf(n)-e.indexOf(r)}))}function b({name:t,value:e}){const i=x(t),n=i.match(m),r=i.match(/:([a-zA-Z0-9\-:]+)/),s=i.match(/\.[^.\]]+(?=[^\]]*$)/g)||[];return{type:n?n[1]:null,value:r?r[1]:null,modifiers:s.map((t=>t.replace(".",""))),expression:e}}function w(t){return["disabled","checked","required","readonly","hidden","open","selected","autofocus","itemscope","multiple","novalidate","allowfullscreen","allowpaymentrequest","formnovalidate","autoplay","controls","loop","muted","playsinline","default","ismap","reversed","async","defer","nomodule"].includes(t)}function x(t){return t.startsWith("@")?t.replace("@","x-on:"):t.startsWith(":")?t.replace(":","x-bind:"):t}function S(t,e=Boolean){return t.split(" ").filter(e)}const E="in",T="out",D="cancelled";function A(t,e,i,n,r=!1){if(r)return e();if(t.__x_transition&&t.__x_transition.type===E)return;const s=v(t,n,"transition"),o=v(t,n,"show")[0];if(o&&o.modifiers.includes("transition")){let n=o.modifiers;if(n.includes("out")&&!n.includes("in"))return e();const r=n.includes("in")&&n.includes("out");n=r?n.filter(((t,e)=>e<n.indexOf("out"))):n,R(t,n,e,i)}else s.some((t=>["enter","enter-start","enter-end"].includes(t.value)))?M(t,n,s,e,i):e()}function k(t,e,i,n,r=!1){if(r)return e();if(t.__x_transition&&t.__x_transition.type===T)return;const s=v(t,n,"transition"),o=v(t,n,"show")[0];if(o&&o.modifiers.includes("transition")){let n=o.modifiers;if(n.includes("in")&&!n.includes("out"))return e();const r=n.includes("in")&&n.includes("out");n=r?n.filter(((t,e)=>e>n.indexOf("out"))):n,P(t,n,r,e,i)}else s.some((t=>["leave","leave-start","leave-end"].includes(t.value)))?I(t,n,s,e,i):e()}function R(t,e,i,n){L(t,e,i,(()=>{}),n,{duration:O(e,"duration",150),origin:O(e,"origin","center"),first:{opacity:0,scale:O(e,"scale",95)},second:{opacity:1,scale:100}},E)}function P(t,e,i,n,r){L(t,e,(()=>{}),n,r,{duration:i?O(e,"duration",150):O(e,"duration",150)/2,origin:O(e,"origin","center"),first:{opacity:1,scale:100},second:{opacity:0,scale:O(e,"scale",95)}},T)}function O(t,e,i){if(-1===t.indexOf(e))return i;const n=t[t.indexOf(e)+1];if(!n)return i;if("scale"===e&&!j(n))return i;if("duration"===e){let t=n.match(/([0-9]+)ms/);if(t)return t[1]}return"origin"===e&&["top","right","left","center","bottom"].includes(t[t.indexOf(e)+2])?[n,t[t.indexOf(e)+2]].join(" "):n}function L(t,e,i,n,r,s,o){t.__x_transition&&t.__x_transition.cancel&&t.__x_transition.cancel();const a=t.style.opacity,l=t.style.transform,h=t.style.transformOrigin,u=!e.includes("opacity")&&!e.includes("scale"),c=u||e.includes("opacity"),d=u||e.includes("scale"),f={start(){c&&(t.style.opacity=s.first.opacity),d&&(t.style.transform=`scale(${s.first.scale/100})`)},during(){d&&(t.style.transformOrigin=s.origin),t.style.transitionProperty=[c?"opacity":"",d?"transform":""].join(" ").trim(),t.style.transitionDuration=s.duration/1e3+"s",t.style.transitionTimingFunction="cubic-bezier(0.4, 0.0, 0.2, 1)"},show(){i()},end(){c&&(t.style.opacity=s.second.opacity),d&&(t.style.transform=`scale(${s.second.scale/100})`)},hide(){n()},cleanup(){c&&(t.style.opacity=a),d&&(t.style.transform=l),d&&(t.style.transformOrigin=h),t.style.transitionProperty=null,t.style.transitionDuration=null,t.style.transitionTimingFunction=null}};q(t,f,o,r)}const C=(t,e,i)=>"function"==typeof t?i.evaluateReturnExpression(e,t):t;function M(t,e,i,n,r){N(t,S(C((i.find((t=>"enter"===t.value))||{expression:""}).expression,t,e)),S(C((i.find((t=>"enter-start"===t.value))||{expression:""}).expression,t,e)),S(C((i.find((t=>"enter-end"===t.value))||{expression:""}).expression,t,e)),n,(()=>{}),E,r)}function I(t,e,i,n,r){N(t,S(C((i.find((t=>"leave"===t.value))||{expression:""}).expression,t,e)),S(C((i.find((t=>"leave-start"===t.value))||{expression:""}).expression,t,e)),S(C((i.find((t=>"leave-end"===t.value))||{expression:""}).expression,t,e)),(()=>{}),n,T,r)}function N(t,e,i,n,r,s,o,a){t.__x_transition&&t.__x_transition.cancel&&t.__x_transition.cancel();const l=t.__x_original_classes||[],h={start(){t.classList.add(...i)},during(){t.classList.add(...e)},show(){r()},end(){t.classList.remove(...i.filter((t=>!l.includes(t)))),t.classList.add(...n)},hide(){s()},cleanup(){t.classList.remove(...e.filter((t=>!l.includes(t)))),t.classList.remove(...n.filter((t=>!l.includes(t))))}};q(t,h,o,a)}function q(t,e,i,n){const r=X((()=>{e.hide(),t.isConnected&&e.cleanup(),delete t.__x_transition}));t.__x_transition={type:i,cancel:X((()=>{n(D),r()})),finish:r,nextFrame:null},e.start(),e.during(),t.__x_transition.nextFrame=requestAnimationFrame((()=>{let i=1e3*Number(getComputedStyle(t).transitionDuration.replace(/,.*/,"").replace("s",""));0===i&&(i=1e3*Number(getComputedStyle(t).animationDuration.replace("s",""))),e.show(),t.__x_transition.nextFrame=requestAnimationFrame((()=>{e.end(),setTimeout(t.__x_transition.finish,i)}))}))}function j(t){return!Array.isArray(t)&&!isNaN(t)}function X(t){let e=!1;return function(){e||(e=!0,t.apply(this,arguments))}}function F(t,e,i,n,r){a(e,"x-for");let s=H("function"==typeof i?t.evaluateReturnExpression(e,i):i),o=z(t,e,s,r),l=e;o.forEach(((i,a)=>{let h=Y(s,i,a,o,r()),u=B(t,e,a,h),c=$(l.nextElementSibling,u);c?(delete c.__x_for_key,c.__x_for=h,t.updateElements(c,(()=>c.__x_for))):(c=W(e,l),A(c,(()=>{}),(()=>{}),t,n),c.__x_for=h,t.initializeElements(c,(()=>c.__x_for))),l=c,l.__x_for_key=u})),G(l,t)}function H(t){let e=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,i=/^\(|\)$/g,n=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,r=t.match(n);if(!r)return;let s={};s.items=r[2].trim();let o=r[1].trim().replace(i,""),a=o.match(e);return a?(s.item=o.replace(e,"").trim(),s.index=a[1].trim(),a[2]&&(s.collection=a[2].trim())):s.item=o,s}function Y(t,e,n,r,s){let o=s?i({},s):{};return o[t.item]=e,t.index&&(o[t.index]=n),t.collection&&(o[t.collection]=r),o}function B(t,e,i,n){let r=v(e,t,"bind").filter((t=>"key"===t.value))[0];return r?t.evaluateReturnExpression(e,r.expression,(()=>n)):i}function z(t,e,i,n){let r=v(e,t,"if")[0];if(r&&!t.evaluateReturnExpression(e,r.expression))return[];let s=t.evaluateReturnExpression(e,i.items,n);return j(s)&&s>0&&(s=Array.from(Array(s).keys(),(t=>t+1))),s}function W(t,e){let i=document.importNode(t.content,!0);return e.parentElement.insertBefore(i,e.nextElementSibling),e.nextElementSibling}function $(t,e){if(!t)return;if(void 0===t.__x_for_key)return;if(t.__x_for_key===e)return t;let i=t;for(;i;){if(i.__x_for_key===e)return i.parentElement.insertBefore(i,t);i=!(!i.nextElementSibling||void 0===i.nextElementSibling.__x_for_key)&&i.nextElementSibling}}function G(t,e){for(var i=!(!t.nextElementSibling||void 0===t.nextElementSibling.__x_for_key)&&t.nextElementSibling;i;){let t=i,n=i.nextElementSibling;k(i,(()=>{t.remove()}),(()=>{}),e),i=!(!n||void 0===n.__x_for_key)&&n}}function U(t,e,i,n,s,a,l){var u=t.evaluateReturnExpression(e,n,s);if("value"===i){if($t.ignoreFocusedForValueBinding&&document.activeElement.isSameNode(e))return;if(void 0===u&&n.match(/\./)&&(u=""),"radio"===e.type)void 0===e.attributes.value&&"bind"===a?e.value=u:"bind"!==a&&(e.checked=o(e.value,u));else if("checkbox"===e.type)"boolean"==typeof u||[null,void 0].includes(u)||"bind"!==a?"bind"!==a&&(Array.isArray(u)?e.checked=u.some((t=>o(t,e.value))):e.checked=!!u):e.value=String(u);else if("SELECT"===e.tagName)J(e,u);else{if(e.value===u)return;e.value=u}}else if("class"===i)if(Array.isArray(u)){const t=e.__x_original_classes||[];e.setAttribute("class",r(t.concat(u)).join(" "))}else if("object"==typeof u)Object.keys(u).sort(((t,e)=>u[t]-u[e])).forEach((t=>{u[t]?S(t).forEach((t=>e.classList.add(t))):S(t).forEach((t=>e.classList.remove(t)))}));else{const t=e.__x_original_classes||[],i=u?S(u):[];e.setAttribute("class",r(t.concat(i)).join(" "))}else i=l.includes("camel")?h(i):i,[null,void 0,!1].includes(u)?e.removeAttribute(i):w(i)?V(e,i,i):V(e,i,u)}function V(t,e,i){t.getAttribute(e)!=i&&t.setAttribute(e,i)}function J(t,e){const i=[].concat(e).map((t=>t+""));Array.from(t.options).forEach((t=>{t.selected=i.includes(t.value||t.text)}))}function K(t,e,i){void 0===e&&i.match(/\./)&&(e=""),t.textContent=e}function Q(t,e,i,n){e.innerHTML=t.evaluateReturnExpression(e,i,n)}function Z(t,e,i,n,r=!1){const s=()=>{e.style.display="none",e.__x_is_shown=!1},o=()=>{1===e.style.length&&"none"===e.style.display?e.removeAttribute("style"):e.style.removeProperty("display"),e.__x_is_shown=!0};if(!0===r)return void(i?o():s());const a=(n,r)=>{i?(("none"===e.style.display||e.__x_transition)&&A(e,(()=>{o()}),r,t),n((()=>{}))):"none"!==e.style.display?k(e,(()=>{n((()=>{s()}))}),r,t):n((()=>{}))};n.includes("immediate")?a((t=>t()),(()=>{})):(t.showDirectiveLastElement&&!t.showDirectiveLastElement.contains(e)&&t.executeAndClearRemainingShowDirectiveStack(),t.showDirectiveStack.push(a),t.showDirectiveLastElement=e)}function tt(t,e,i,n,r){a(e,"x-if");const s=e.nextElementSibling&&!0===e.nextElementSibling.__x_inserted_me;if(!i||s&&!e.__x_transition)!i&&s&&k(e.nextElementSibling,(()=>{e.nextElementSibling.remove()}),(()=>{}),t,n);else{const i=document.importNode(e.content,!0);e.parentElement.insertBefore(i,e.nextElementSibling),A(e.nextElementSibling,(()=>{}),(()=>{}),t,n),t.initializeElements(e.nextElementSibling,r),e.nextElementSibling.__x_inserted_me=!0}}function et(t,e,i,n,r,s={}){const o={passive:n.includes("passive")};if(n.includes("camel")&&(i=h(i)),n.includes("away")){let a=l=>{e.contains(l.target)||e.offsetWidth<1&&e.offsetHeight<1||(it(t,r,l,s),n.includes("once")&&document.removeEventListener(i,a,o))};document.addEventListener(i,a,o)}else{let a=n.includes("window")?window:n.includes("document")?document:e,l=h=>{a!==window&&a!==document||document.body.contains(e)?nt(i)&&rt(h,n)||(n.includes("prevent")&&h.preventDefault(),n.includes("stop")&&h.stopPropagation(),n.includes("self")&&h.target!==e)||it(t,r,h,s).then((t=>{!1===t?h.preventDefault():n.includes("once")&&a.removeEventListener(i,l,o)})):a.removeEventListener(i,l,o)};if(n.includes("debounce")){let t=n[n.indexOf("debounce")+1]||"invalid-wait",e=j(t.split("ms")[0])?Number(t.split("ms")[0]):250;l=c(l,e)}a.addEventListener(i,l,o)}}function it(t,e,n,r){return t.evaluateCommandExpression(n.target,e,(()=>i(i({},r()),{},{$event:n})))}function nt(t){return["keydown","keyup"].includes(t)}function rt(t,e){let i=e.filter((t=>!["window","document","prevent","stop"].includes(t)));if(i.includes("debounce")){let t=i.indexOf("debounce");i.splice(t,j((i[t+1]||"invalid-wait").split("ms")[0])?2:1)}if(0===i.length)return!1;if(1===i.length&&i[0]===st(t.key))return!1;const n=["ctrl","shift","alt","meta","cmd","super"].filter((t=>i.includes(t)));return i=i.filter((t=>!n.includes(t))),!(n.length>0&&n.filter((e=>("cmd"!==e&&"super"!==e||(e="meta"),t[`${e}Key`]))).length===n.length&&i[0]===st(t.key))}function st(t){switch(t){case"/":return"slash";case" ":case"Spacebar":return"space";default:return t&&l(t)}}function ot(t,e,n,r,s){var o="select"===e.tagName.toLowerCase()||["checkbox","radio"].includes(e.type)||n.includes("lazy")?"change":"input";et(t,e,o,n,`${r} = rightSideOfExpression($event, ${r})`,(()=>i(i({},s()),{},{rightSideOfExpression:at(e,n,r)})))}function at(t,e,i){return"radio"===t.type&&(t.hasAttribute("name")||t.setAttribute("name",i)),(i,n)=>{if(i instanceof CustomEvent&&i.detail)return i.detail;if("checkbox"===t.type){if(Array.isArray(n)){const t=e.includes("number")?lt(i.target.value):i.target.value;return i.target.checked?n.concat([t]):n.filter((e=>!o(e,t)))}return i.target.checked}if("select"===t.tagName.toLowerCase()&&t.multiple)return e.includes("number")?Array.from(i.target.selectedOptions).map((t=>lt(t.value||t.text))):Array.from(i.target.selectedOptions).map((t=>t.value||t.text));{const t=i.target.value;return e.includes("number")?lt(t):e.includes("trim")?t.trim():t}}}function lt(t){const e=t?parseFloat(t):null;return j(e)?e:t}const{isArray:ht}=Array,{getPrototypeOf:ut,create:ct,defineProperty:dt,defineProperties:ft,isExtensible:pt,getOwnPropertyDescriptor:_t,getOwnPropertyNames:mt,getOwnPropertySymbols:gt,preventExtensions:vt,hasOwnProperty:yt}=Object,{push:bt,concat:wt,map:xt}=Array.prototype;function St(t){return void 0===t}function Et(t){return"function"==typeof t}function Tt(t){return"object"==typeof t}const Dt=new WeakMap;function At(t,e){Dt.set(t,e)}const kt=t=>Dt.get(t)||t;function Rt(t,e){return t.valueIsObservable(e)?t.getProxy(e):e}function Pt(t){return yt.call(t,"value")&&(t.value=kt(t.value)),t}function Ot(t,e,i){wt.call(mt(i),gt(i)).forEach((n=>{let r=_t(i,n);r.configurable||(r=Ht(t,r,Rt)),dt(e,n,r)})),vt(e)}class Lt{constructor(t,e){this.originalTarget=e,this.membrane=t}get(t,e){const{originalTarget:i,membrane:n}=this,r=i[e],{valueObserved:s}=n;return s(i,e),n.getProxy(r)}set(t,e,i){const{originalTarget:n,membrane:{valueMutated:r}}=this;return n[e]!==i?(n[e]=i,r(n,e)):"length"===e&&ht(n)&&r(n,e),!0}deleteProperty(t,e){const{originalTarget:i,membrane:{valueMutated:n}}=this;return delete i[e],n(i,e),!0}apply(t,e,i){}construct(t,e,i){}has(t,e){const{originalTarget:i,membrane:{valueObserved:n}}=this;return n(i,e),e in i}ownKeys(t){const{originalTarget:e}=this;return wt.call(mt(e),gt(e))}isExtensible(t){const e=pt(t);if(!e)return e;const{originalTarget:i,membrane:n}=this,r=pt(i);return r||Ot(n,t,i),r}setPrototypeOf(t,e){}getPrototypeOf(t){const{originalTarget:e}=this;return ut(e)}getOwnPropertyDescriptor(t,e){const{originalTarget:i,membrane:n}=this,{valueObserved:r}=this.membrane;r(i,e);let s=_t(i,e);if(St(s))return s;const o=_t(t,e);return St(o)?(s=Ht(n,s,Rt),s.configurable||dt(t,e,s),s):o}preventExtensions(t){const{originalTarget:e,membrane:i}=this;return Ot(i,t,e),vt(e),!0}defineProperty(t,e,i){const{originalTarget:n,membrane:r}=this,{valueMutated:s}=r,{configurable:o}=i;if(yt.call(i,"writable")&&!yt.call(i,"value")){const t=_t(n,e);i.value=t.value}return dt(n,e,Pt(i)),!1===o&&dt(t,e,Ht(r,i,Rt)),s(n,e),!0}}function Ct(t,e){return t.valueIsObservable(e)?t.getReadOnlyProxy(e):e}class Mt{constructor(t,e){this.originalTarget=e,this.membrane=t}get(t,e){const{membrane:i,originalTarget:n}=this,r=n[e],{valueObserved:s}=i;return s(n,e),i.getReadOnlyProxy(r)}set(t,e,i){return!1}deleteProperty(t,e){return!1}apply(t,e,i){}construct(t,e,i){}has(t,e){const{originalTarget:i,membrane:{valueObserved:n}}=this;return n(i,e),e in i}ownKeys(t){const{originalTarget:e}=this;return wt.call(mt(e),gt(e))}setPrototypeOf(t,e){}getOwnPropertyDescriptor(t,e){const{originalTarget:i,membrane:n}=this,{valueObserved:r}=n;r(i,e);let s=_t(i,e);if(St(s))return s;const o=_t(t,e);return St(o)?(s=Ht(n,s,Ct),yt.call(s,"set")&&(s.set=void 0),s.configurable||dt(t,e,s),s):o}preventExtensions(t){return!1}defineProperty(t,e,i){return!1}}function It(t){let e;return ht(t)?e=[]:Tt(t)&&(e={}),e}const Nt=Object.prototype;function qt(t){if(null===t)return!1;if("object"!=typeof t)return!1;if(ht(t))return!0;const e=ut(t);return e===Nt||null===e||null===ut(e)}const jt=(t,e)=>{},Xt=(t,e)=>{},Ft=t=>t;function Ht(t,e,i){const{set:n,get:r}=e;return yt.call(e,"value")?e.value=i(t,e.value):(St(r)||(e.get=function(){return i(t,r.call(kt(this)))}),St(n)||(e.set=function(e){n.call(kt(this),t.unwrapProxy(e))})),e}class Yt{constructor(t){if(this.valueDistortion=Ft,this.valueMutated=Xt,this.valueObserved=jt,this.valueIsObservable=qt,this.objectGraph=new WeakMap,!St(t)){const{valueDistortion:e,valueMutated:i,valueObserved:n,valueIsObservable:r}=t;this.valueDistortion=Et(e)?e:Ft,this.valueMutated=Et(i)?i:Xt,this.valueObserved=Et(n)?n:jt,this.valueIsObservable=Et(r)?r:qt}}getProxy(t){const e=kt(t),i=this.valueDistortion(e);if(this.valueIsObservable(i)){const n=this.getReactiveState(e,i);return n.readOnly===t?t:n.reactive}return i}getReadOnlyProxy(t){t=kt(t);const e=this.valueDistortion(t);return this.valueIsObservable(e)?this.getReactiveState(t,e).readOnly:e}unwrapProxy(t){return kt(t)}getReactiveState(t,e){const{objectGraph:i}=this;let n=i.get(e);if(n)return n;const r=this;return n={get reactive(){const i=new Lt(r,e),n=new Proxy(It(e),i);return At(n,t),dt(this,"reactive",{value:n}),n},get readOnly(){const i=new Mt(r,e),n=new Proxy(It(e),i);return At(n,t),dt(this,"readOnly",{value:n}),n}},i.set(e,n),n}}function Bt(t,e){let i=new Yt({valueMutated(t,i){e(t,i)}});return{data:i.getProxy(t),membrane:i}}function zt(t,e){let i=t.unwrapProxy(e),n={};return Object.keys(i).forEach((t=>{["$el","$refs","$nextTick","$watch"].includes(t)||(n[t]=i[t])})),n}class Wt{constructor(t,e=null){this.$el=t;const i=this.$el.getAttribute("x-data"),n=""===i?"{}":i,r=this.$el.getAttribute("x-init");let s={$el:this.$el},o=e?e.$el:this.$el;Object.entries($t.magicProperties).forEach((([t,e])=>{Object.defineProperty(s,`$${t}`,{get:function(){return e(o)}})})),this.unobservedData=e?e.getUnobservedData():p(t,n,s);let{membrane:a,data:l}=this.wrapDataInObservable(this.unobservedData);var h;this.$data=l,this.membrane=a,this.unobservedData.$el=this.$el,this.unobservedData.$refs=this.getRefsProxy(),this.nextTickStack=[],this.unobservedData.$nextTick=t=>{this.nextTickStack.push(t)},this.watchers={},this.unobservedData.$watch=(t,e)=>{this.watchers[t]||(this.watchers[t]=[]),this.watchers[t].push(e)},Object.entries($t.magicProperties).forEach((([t,e])=>{Object.defineProperty(this.unobservedData,`$${t}`,{get:function(){return e(o,this.$el)}})})),this.showDirectiveStack=[],e||$t.onBeforeComponentInitializeds.forEach((t=>t(this))),r&&!e&&(this.pauseReactivity=!0,h=this.evaluateReturnExpression(this.$el,r),this.pauseReactivity=!1),this.initializeElements(this.$el),this.listenForNewElementsToInitialize(),"function"==typeof h&&h.call(this.$data),e||setTimeout((()=>{$t.onComponentInitializeds.forEach((t=>t(this)))}),0)}getUnobservedData(){return zt(this.membrane,this.$data)}wrapDataInObservable(t){var e=this;let i=c((function(){e.updateElements(e.$el)}),0);return Bt(t,((t,n)=>{e.watchers[n]?e.watchers[n].forEach((e=>e(t[n]))):Array.isArray(t)?Object.keys(e.watchers).forEach((i=>{let r=i.split(".");"length"!==n&&r.reduce(((n,r)=>(Object.is(t,n[r])&&e.watchers[i].forEach((e=>e(t))),n[r])),e.unobservedData)})):Object.keys(e.watchers).filter((t=>t.includes("."))).forEach((i=>{let r=i.split(".");n===r[r.length-1]&&r.reduce(((r,s)=>(Object.is(t,r)&&e.watchers[i].forEach((e=>e(t[n]))),r[s])),e.unobservedData)})),e.pauseReactivity||i()}))}walkAndSkipNestedComponents(t,e,i=(()=>{})){u(t,(t=>t.hasAttribute("x-data")&&!t.isSameNode(this.$el)?(t.__x||i(t),!1):e(t)))}initializeElements(t,e=(()=>{})){this.walkAndSkipNestedComponents(t,(t=>void 0===t.__x_for_key&&void 0===t.__x_inserted_me&&void this.initializeElement(t,e)),(t=>{t.__x=new Wt(t)})),this.executeAndClearRemainingShowDirectiveStack(),this.executeAndClearNextTickStack(t)}initializeElement(t,e){t.hasAttribute("class")&&v(t,this).length>0&&(t.__x_original_classes=S(t.getAttribute("class"))),this.registerListeners(t,e),this.resolveBoundAttributes(t,!0,e)}updateElements(t,e=(()=>{})){this.walkAndSkipNestedComponents(t,(t=>{if(void 0!==t.__x_for_key&&!t.isSameNode(this.$el))return!1;this.updateElement(t,e)}),(t=>{t.__x=new Wt(t)})),this.executeAndClearRemainingShowDirectiveStack(),this.executeAndClearNextTickStack(t)}executeAndClearNextTickStack(t){t===this.$el&&this.nextTickStack.length>0&&requestAnimationFrame((()=>{for(;this.nextTickStack.length>0;)this.nextTickStack.shift()()}))}executeAndClearRemainingShowDirectiveStack(){this.showDirectiveStack.reverse().map((t=>new Promise(((e,i)=>{t(e,i)})))).reduce(((t,e)=>t.then((()=>e.then((t=>{t()}))))),Promise.resolve((()=>{}))).catch((t=>{if(t!==D)throw t})),this.showDirectiveStack=[],this.showDirectiveLastElement=void 0}updateElement(t,e){this.resolveBoundAttributes(t,!1,e)}registerListeners(t,e){v(t,this).forEach((({type:i,value:n,modifiers:r,expression:s})=>{switch(i){case"on":et(this,t,n,r,s,e);break;case"model":ot(this,t,r,s,e)}}))}resolveBoundAttributes(t,e=!1,i){let n=v(t,this);n.forEach((({type:r,value:s,modifiers:o,expression:a})=>{switch(r){case"model":U(this,t,"value",a,i,r,o);break;case"bind":if("template"===t.tagName.toLowerCase()&&"key"===s)return;U(this,t,s,a,i,r,o);break;case"text":var l=this.evaluateReturnExpression(t,a,i);K(t,l,a);break;case"html":Q(this,t,a,i);break;case"show":l=this.evaluateReturnExpression(t,a,i),Z(this,t,l,o,e);break;case"if":if(n.some((t=>"for"===t.type)))return;l=this.evaluateReturnExpression(t,a,i),tt(this,t,l,e,i);break;case"for":F(this,t,a,e,i);break;case"cloak":t.removeAttribute("x-cloak")}}))}evaluateReturnExpression(t,e,n=(()=>{})){return p(t,e,this.$data,i(i({},n()),{},{$dispatch:this.getDispatchFunction(t)}))}evaluateCommandExpression(t,e,n=(()=>{})){return _(t,e,this.$data,i(i({},n()),{},{$dispatch:this.getDispatchFunction(t)}))}getDispatchFunction(t){return(e,i={})=>{t.dispatchEvent(new CustomEvent(e,{detail:i,bubbles:!0}))}}listenForNewElementsToInitialize(){const t=this.$el,e={childList:!0,attributes:!0,subtree:!0};new MutationObserver((t=>{for(let e=0;e<t.length;e++){const i=t[e].target.closest("[x-data]");if(i&&i.isSameNode(this.$el)){if("attributes"===t[e].type&&"x-data"===t[e].attributeName){const i=t[e].target.getAttribute("x-data")||"{}",n=p(this.$el,i,{$el:this.$el});Object.keys(n).forEach((t=>{this.$data[t]!==n[t]&&(this.$data[t]=n[t])}))}t[e].addedNodes.length>0&&t[e].addedNodes.forEach((t=>{1!==t.nodeType||t.__x_inserted_me||(!t.matches("[x-data]")||t.__x?this.initializeElements(t):t.__x=new Wt(t))}))}}})).observe(t,e)}getRefsProxy(){var t=this;return new Proxy({},{get(e,i){return"$isAlpineProxy"===i||(t.walkAndSkipNestedComponents(t.$el,(t=>{t.hasAttribute("x-ref")&&t.getAttribute("x-ref")===i&&(n=t)})),n);var n}})}}const $t={version:"2.8.0",pauseMutationObserver:!1,magicProperties:{},onComponentInitializeds:[],onBeforeComponentInitializeds:[],ignoreFocusedForValueBinding:!1,start:async function(){s()||await n(),this.discoverComponents((t=>{this.initializeComponent(t)})),document.addEventListener("turbolinks:load",(()=>{this.discoverUninitializedComponents((t=>{this.initializeComponent(t)}))})),this.listenForNewUninitializedComponentsAtRunTime()},discoverComponents:function(t){document.querySelectorAll("[x-data]").forEach((e=>{t(e)}))},discoverUninitializedComponents:function(t,e=null){const i=(e||document).querySelectorAll("[x-data]");Array.from(i).filter((t=>void 0===t.__x)).forEach((e=>{t(e)}))},listenForNewUninitializedComponentsAtRunTime:function(){const t=document.querySelector("body"),e={childList:!0,attributes:!0,subtree:!0};new MutationObserver((t=>{if(!this.pauseMutationObserver)for(let e=0;e<t.length;e++)t[e].addedNodes.length>0&&t[e].addedNodes.forEach((t=>{1===t.nodeType&&(t.parentElement&&t.parentElement.closest("[x-data]")||this.discoverUninitializedComponents((t=>{this.initializeComponent(t)}),t.parentElement))}))})).observe(t,e)},initializeComponent:function(t){if(!t.__x)try{t.__x=new Wt(t)}catch(t){setTimeout((()=>{throw t}),0)}},clone:function(t,e){e.__x||(e.__x=new Wt(e,t))},addMagicProperty:function(t,e){this.magicProperties[t]=e},onComponentInitialized:function(t){this.onComponentInitializeds.push(t)},onBeforeComponentInitialized:function(t){this.onBeforeComponentInitializeds.push(t)}};return s()||(window.Alpine=$t,window.deferLoadingAlpine?window.deferLoadingAlpine((function(){window.Alpine.start()})):window.Alpine.start()),$t}()}));var r=e((function(e,i){(function(){var t=function(t){return"[object Array]"===toString.call(t)},n=function(t){var e,i,n="";for(e=0;e<t.length;e+=1)switch(i=t.charAt(e)){case"<":n+="<";break;case">":n+=">";break;case"&":n+="&";break;case"/":n+="/";break;case'"':n+=""";break;case"'":n+="'";break;default:n+=i}return n},r=function(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/")},s=function(e,i){var o,a,l,h;if(function(t){return"string"==typeof t}(e))h=e.length,o="charForLoopStrategy"===i?n(e):"regexStrategy"===i||h>32?r(e):n(e);else if("number"==typeof e||function(t){return"boolean"==typeof t}(e))o=e;else if(t(e))for(o=[],l=0;l<e.length;l+=1)o.push(s(e[l]));else if(function(e){return!t(e)&&e instanceof Object}(e))for(a in o={},e)e.hasOwnProperty(a)&&(o[a]=s(e[a]));return o};e.exports&&(i=e.exports=s),i.xssEscape=s}).call(t)}));var s=function(t,e){return function(){for(var i=new Array(arguments.length),n=0;n<i.length;n++)i[n]=arguments[n];return t.apply(e,i)}},o=Object.prototype.toString;function a(t){return"[object Array]"===o.call(t)}function l(t){return void 0===t}function h(t){return null!==t&&"object"==typeof t}function u(t){if("[object Object]"!==o.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function c(t){return"[object Function]"===o.call(t)}function d(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),a(t))for(var i=0,n=t.length;i<n;i++)e.call(null,t[i],i,t);else for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.call(null,t[r],r,t)}var f={isArray:a,isArrayBuffer:function(t){return"[object ArrayBuffer]"===o.call(t)},isBuffer:function(t){return null!==t&&!l(t)&&null!==t.constructor&&!l(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){return"undefined"!=typeof FormData&&t instanceof FormData},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&t.buffer instanceof ArrayBuffer},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:h,isPlainObject:u,isUndefined:l,isDate:function(t){return"[object Date]"===o.call(t)},isFile:function(t){return"[object File]"===o.call(t)},isBlob:function(t){return"[object Blob]"===o.call(t)},isFunction:c,isStream:function(t){return h(t)&&c(t.pipe)},isURLSearchParams:function(t){return"undefined"!=typeof URLSearchParams&&t instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)},forEach:d,merge:function t(){var e={};function i(i,n){u(e[n])&&u(i)?e[n]=t(e[n],i):u(i)?e[n]=t({},i):a(i)?e[n]=i.slice():e[n]=i}for(var n=0,r=arguments.length;n<r;n++)d(arguments[n],i);return e},extend:function(t,e,i){return d(e,(function(e,n){t[n]=i&&"function"==typeof e?s(e,i):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t}};function p(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var _=function(t,e,i){if(!e)return t;var n;if(i)n=i(e);else if(f.isURLSearchParams(e))n=e.toString();else{var r=[];f.forEach(e,(function(t,e){null!=t&&(f.isArray(t)?e+="[]":t=[t],f.forEach(t,(function(t){f.isDate(t)?t=t.toISOString():f.isObject(t)&&(t=JSON.stringify(t)),r.push(p(e)+"="+p(t))})))})),n=r.join("&")}if(n){var s=t.indexOf("#");-1!==s&&(t=t.slice(0,s)),t+=(-1===t.indexOf("?")?"?":"&")+n}return t};function m(){this.handlers=[]}m.prototype.use=function(t,e,i){return this.handlers.push({fulfilled:t,rejected:e,synchronous:!!i&&i.synchronous,runWhen:i?i.runWhen:null}),this.handlers.length-1},m.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},m.prototype.forEach=function(t){f.forEach(this.handlers,(function(e){null!==e&&t(e)}))};var g=m,v=function(t,e){f.forEach(t,(function(i,n){n!==e&&n.toUpperCase()===e.toUpperCase()&&(t[e]=i,delete t[n])}))},y=function(t,e,i,n,r){return t.config=e,i&&(t.code=i),t.request=n,t.response=r,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t},b=function(t,e,i,n,r){var s=new Error(t);return y(s,e,i,n,r)},w=f.isStandardBrowserEnv()?{write:function(t,e,i,n,r,s){var o=[];o.push(t+"="+encodeURIComponent(e)),f.isNumber(i)&&o.push("expires="+new Date(i).toGMTString()),f.isString(n)&&o.push("path="+n),f.isString(r)&&o.push("domain="+r),!0===s&&o.push("secure"),document.cookie=o.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}},x=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"],S=f.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a");function n(t){var n=t;return e&&(i.setAttribute("href",n),n=i.href),i.setAttribute("href",n),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:"/"===i.pathname.charAt(0)?i.pathname:"/"+i.pathname}}return t=n(window.location.href),function(e){var i=f.isString(e)?n(e):e;return i.protocol===t.protocol&&i.host===t.host}}():function(){return!0},E=function(t){return new Promise((function(e,i){var n=t.data,r=t.headers,s=t.responseType;f.isFormData(n)&&delete r["Content-Type"];var o=new XMLHttpRequest;if(t.auth){var a=t.auth.username||"",l=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";r.Authorization="Basic "+btoa(a+":"+l)}var h,u,c=(h=t.baseURL,u=t.url,h&&!/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(u)?function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}(h,u):u);function d(){if(o){var n,r,a,l,h,u="getAllResponseHeaders"in o?(n=o.getAllResponseHeaders(),h={},n?(f.forEach(n.split("\n"),(function(t){if(l=t.indexOf(":"),r=f.trim(t.substr(0,l)).toLowerCase(),a=f.trim(t.substr(l+1)),r){if(h[r]&&x.indexOf(r)>=0)return;h[r]="set-cookie"===r?(h[r]?h[r]:[]).concat([a]):h[r]?h[r]+", "+a:a}})),h):h):null,c={data:s&&"text"!==s&&"json"!==s?o.response:o.responseText,status:o.status,statusText:o.statusText,headers:u,config:t,request:o};!function(t,e,i){var n=i.config.validateStatus;i.status&&n&&!n(i.status)?e(b("Request failed with status code "+i.status,i.config,null,i.request,i)):t(i)}(e,i,c),o=null}}if(o.open(t.method.toUpperCase(),_(c,t.params,t.paramsSerializer),!0),o.timeout=t.timeout,"onloadend"in o?o.onloadend=d:o.onreadystatechange=function(){o&&4===o.readyState&&(0!==o.status||o.responseURL&&0===o.responseURL.indexOf("file:"))&&setTimeout(d)},o.onabort=function(){o&&(i(b("Request aborted",t,"ECONNABORTED",o)),o=null)},o.onerror=function(){i(b("Network Error",t,null,o)),o=null},o.ontimeout=function(){var e="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),i(b(e,t,t.transitional&&t.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",o)),o=null},f.isStandardBrowserEnv()){var p=(t.withCredentials||S(c))&&t.xsrfCookieName?w.read(t.xsrfCookieName):void 0;p&&(r[t.xsrfHeaderName]=p)}"setRequestHeader"in o&&f.forEach(r,(function(t,e){void 0===n&&"content-type"===e.toLowerCase()?delete r[e]:o.setRequestHeader(e,t)})),f.isUndefined(t.withCredentials)||(o.withCredentials=!!t.withCredentials),s&&"json"!==s&&(o.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&o.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&o.upload&&o.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){o&&(o.abort(),i(t),o=null)})),n||(n=null),o.send(n)}))},T={"Content-Type":"application/x-www-form-urlencoded"};function D(t,e){!f.isUndefined(t)&&f.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var A,k={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(A=E),A),transformRequest:[function(t,e){return v(e,"Accept"),v(e,"Content-Type"),f.isFormData(t)||f.isArrayBuffer(t)||f.isBuffer(t)||f.isStream(t)||f.isFile(t)||f.isBlob(t)?t:f.isArrayBufferView(t)?t.buffer:f.isURLSearchParams(t)?(D(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):f.isObject(t)||e&&"application/json"===e["Content-Type"]?(D(e,"application/json"),JSON.stringify(t)):t}],transformResponse:[function(t){var e=this.transitional,i=e&&e.silentJSONParsing,n=e&&e.forcedJSONParsing,r=!i&&"json"===this.responseType;if(r||n&&f.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(r){if("SyntaxError"===t.name)throw y(t,this,"E_JSON_PARSE");throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300}};k.headers={common:{Accept:"application/json, text/plain, */*"}},f.forEach(["delete","get","head"],(function(t){k.headers[t]={}})),f.forEach(["post","put","patch"],(function(t){k.headers[t]=f.merge(T)}));var R=k,P=function(t,e,i){var n=this||R;return f.forEach(i,(function(i){t=i.call(n,t,e)})),t},O=function(t){return!(!t||!t.__CANCEL__)};function L(t){t.cancelToken&&t.cancelToken.throwIfRequested()}var C=function(t){return L(t),t.headers=t.headers||{},t.data=P.call(t,t.data,t.headers,t.transformRequest),t.headers=f.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),f.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||R.adapter)(t).then((function(e){return L(t),e.data=P.call(t,e.data,e.headers,t.transformResponse),e}),(function(e){return O(e)||(L(t),e&&e.response&&(e.response.data=P.call(t,e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))},M=function(t,e){e=e||{};var i={},n=["url","method","data"],r=["headers","auth","proxy","params"],s=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],o=["validateStatus"];function a(t,e){return f.isPlainObject(t)&&f.isPlainObject(e)?f.merge(t,e):f.isPlainObject(e)?f.merge({},e):f.isArray(e)?e.slice():e}function l(n){f.isUndefined(e[n])?f.isUndefined(t[n])||(i[n]=a(void 0,t[n])):i[n]=a(t[n],e[n])}f.forEach(n,(function(t){f.isUndefined(e[t])||(i[t]=a(void 0,e[t]))})),f.forEach(r,l),f.forEach(s,(function(n){f.isUndefined(e[n])?f.isUndefined(t[n])||(i[n]=a(void 0,t[n])):i[n]=a(void 0,e[n])})),f.forEach(o,(function(n){n in e?i[n]=a(t[n],e[n]):n in t&&(i[n]=a(void 0,t[n]))}));var h=n.concat(r).concat(s).concat(o),u=Object.keys(t).concat(Object.keys(e)).filter((function(t){return-1===h.indexOf(t)}));return f.forEach(u,l),i},I={_args:[["axios@0.21.2","/usr/src/app"]],_from:"axios@0.21.2",_id:"axios@0.21.2",_inBundle:!1,_integrity:"sha512-87otirqUw3e8CzHTMO+/9kh/FSgXt/eVDvipijwDtEuwbkySWZ9SBm6VEubmJ/kLKEoLQV/POhxXFb66bfekfg==",_location:"/axios",_phantomChildren:{},_requested:{type:"version",registry:!0,raw:"axios@0.21.2",name:"axios",escapedName:"axios",rawSpec:"0.21.2",saveSpec:null,fetchSpec:"0.21.2"},_requiredBy:["/"],_resolved:"https://registry.npmjs.org/axios/-/axios-0.21.2.tgz",_spec:"0.21.2",_where:"/usr/src/app",author:{name:"Matt Zabriskie"},browser:{"./lib/adapters/http.js":"./lib/adapters/xhr.js"},bugs:{url:"https://github.com/axios/axios/issues"},bundlesize:[{path:"./dist/axios.min.js",threshold:"5kB"}],dependencies:{"follow-redirects":"^1.14.0"},description:"Promise based HTTP client for the browser and node.js",devDependencies:{coveralls:"^3.0.0","es6-promise":"^4.2.4",grunt:"^1.3.0","grunt-banner":"^0.6.0","grunt-cli":"^1.2.0","grunt-contrib-clean":"^1.1.0","grunt-contrib-watch":"^1.0.0","grunt-eslint":"^23.0.0","grunt-karma":"^4.0.0","grunt-mocha-test":"^0.13.3","grunt-ts":"^6.0.0-beta.19","grunt-webpack":"^4.0.2","istanbul-instrumenter-loader":"^1.0.0","jasmine-core":"^2.4.1",karma:"^6.3.2","karma-chrome-launcher":"^3.1.0","karma-firefox-launcher":"^2.1.0","karma-jasmine":"^1.1.1","karma-jasmine-ajax":"^0.1.13","karma-safari-launcher":"^1.0.0","karma-sauce-launcher":"^4.3.6","karma-sinon":"^1.0.5","karma-sourcemap-loader":"^0.3.8","karma-webpack":"^4.0.2","load-grunt-tasks":"^3.5.2",minimist:"^1.2.0",mocha:"^8.2.1",sinon:"^4.5.0","terser-webpack-plugin":"^4.2.3",typescript:"^4.0.5","url-search-params":"^0.10.0",webpack:"^4.44.2","webpack-dev-server":"^3.11.0"},homepage:"https://axios-http.com",jsdelivr:"dist/axios.min.js",keywords:["xhr","http","ajax","promise","node"],license:"MIT",main:"index.js",name:"axios",repository:{type:"git",url:"git+https://github.com/axios/axios.git"},scripts:{build:"NODE_ENV=production grunt build",coveralls:"cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",examples:"node ./examples/server.js",fix:"eslint --fix lib/**/*.js",postversion:"git push && git push --tags",preversion:"npm test",start:"node ./sandbox/server.js",test:"grunt test",version:"npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json"},typings:"./index.d.ts",unpkg:"dist/axios.min.js",version:"0.21.2"},N={};["object","boolean","number","function","string","symbol"].forEach((function(t,e){N[t]=function(i){return typeof i===t||"a"+(e<1?"n ":" ")+t}}));var q={},j=I.version.split(".");function X(t,e){for(var i=e?e.split("."):j,n=t.split("."),r=0;r<3;r++){if(i[r]>n[r])return!0;if(i[r]<n[r])return!1}return!1}N.transitional=function(t,e,i){var n=e&&X(e);function r(t,e){return"[Axios v"+I.version+"] Transitional option '"+t+"'"+e+(i?". "+i:"")}return function(i,s,o){if(!1===t)throw new Error(r(s," has been removed in "+e));return n&&!q[s]&&(q[s]=!0,console.warn(r(s," has been deprecated since v"+e+" and will be removed in the near future"))),!t||t(i,s,o)}};var F={isOlderVersion:X,assertOptions:function(t,e,i){if("object"!=typeof t)throw new TypeError("options must be an object");for(var n=Object.keys(t),r=n.length;r-- >0;){var s=n[r],o=e[s];if(o){var a=t[s],l=void 0===a||o(a,s,t);if(!0!==l)throw new TypeError("option "+s+" must be "+l)}else if(!0!==i)throw Error("Unknown option "+s)}},validators:N},H=F.validators;function Y(t){this.defaults=t,this.interceptors={request:new g,response:new g}}Y.prototype.request=function(t){"string"==typeof t?(t=arguments[1]||{}).url=arguments[0]:t=t||{},(t=M(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var e=t.transitional;void 0!==e&&F.assertOptions(e,{silentJSONParsing:H.transitional(H.boolean,"1.0.0"),forcedJSONParsing:H.transitional(H.boolean,"1.0.0"),clarifyTimeoutError:H.transitional(H.boolean,"1.0.0")},!1);var i=[],n=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(n=n&&e.synchronous,i.unshift(e.fulfilled,e.rejected))}));var r,s=[];if(this.interceptors.response.forEach((function(t){s.push(t.fulfilled,t.rejected)})),!n){var o=[C,void 0];for(Array.prototype.unshift.apply(o,i),o.concat(s),r=Promise.resolve(t);o.length;)r=r.then(o.shift(),o.shift());return r}for(var a=t;i.length;){var l=i.shift(),h=i.shift();try{a=l(a)}catch(t){h(t);break}}try{r=C(a)}catch(t){return Promise.reject(t)}for(;s.length;)r=r.then(s.shift(),s.shift());return r},Y.prototype.getUri=function(t){return t=M(this.defaults,t),_(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")},f.forEach(["delete","get","head","options"],(function(t){Y.prototype[t]=function(e,i){return this.request(M(i||{},{method:t,url:e,data:(i||{}).data}))}})),f.forEach(["post","put","patch"],(function(t){Y.prototype[t]=function(e,i,n){return this.request(M(n||{},{method:t,url:e,data:i}))}}));var B=Y;function z(t){this.message=t}z.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},z.prototype.__CANCEL__=!0;var W=z;function $(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var i=this;t((function(t){i.reason||(i.reason=new W(t),e(i.reason))}))}$.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},$.source=function(){var t;return{token:new $((function(e){t=e})),cancel:t}};var G=$;function U(t){var e=new B(t),i=s(B.prototype.request,e);return f.extend(i,B.prototype,e),f.extend(i,e),i}var V=U(R);V.Axios=B,V.create=function(t){return U(M(V.defaults,t))},V.Cancel=W,V.CancelToken=G,V.isCancel=O,V.all=function(t){return Promise.all(t)},V.spread=function(t){return function(e){return t.apply(null,e)}},V.isAxiosError=function(t){return"object"==typeof t&&!0===t.isAxiosError};var J=V,K=V;J.default=K;var Q=J.create({baseURL:window.metagalleryData.root,headers:{"X-WP-Nonce":window.metagalleryData.nonce,"X-Requested-With":"XMLHttpRequest"}}),Z=function(t,e,i,n){var r=new FormData;return r.append("title",e),r.append("images",JSON.stringify(i)),r.append("settings",JSON.stringify(n)),Q.post("gallery/"+t,r,{headers:{"Content-Type":"multipart/form-data"}})};
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
var tt={},et="function"==typeof Map?new Map:null,it="swap",nt="move",rt="layoutStart",st="layoutEnd",ot="layoutAbort",at="remove",lt="hideStart",ht="filter",ut="sort",ct="move",dt="send",ft="beforeSend",pt="receive",_t="beforeReceive",mt="dragReleaseEnd",gt="ontouchstart"in window,vt=!!window.PointerEvent,yt=!!window.navigator.msPointerEnabled;function bt(){this._events={},this._queue=[],this._counter=0,this._clearOnEmit=!1}bt.prototype.on=function(t,e){if(!this._events||!t||!e)return this;var i=this._events[t];return i||(i=this._events[t]=[]),i.push(e),this},bt.prototype.off=function(t,e){if(!this._events||!t||!e)return this;var i,n=this._events[t];if(!n||!n.length)return this;for(;-1!==(i=n.indexOf(e));)n.splice(i,1);return this},bt.prototype.clear=function(t){if(!this._events||!t)return this;var e=this._events[t];return e&&(e.length=0,delete this._events[t]),this},bt.prototype.emit=function(t){if(!this._events||!t)return this._clearOnEmit=!1,this;var e=this._events[t];if(!e||!e.length)return this._clearOnEmit=!1,this;var i,n=this._queue,r=n.length,s=arguments.length-1;s>3&&((i=[]).push.apply(i,arguments),i.shift()),n.push.apply(n,e),this._clearOnEmit&&(e.length=0,this._clearOnEmit=!1),++this._counter;for(var o=r,a=n.length;o<a;o++)if(0===s?n[o]():1===s?n[o](arguments[1]):2===s?n[o](arguments[1],arguments[2]):3===s?n[o](arguments[1],arguments[2],arguments[3]):n[o].apply(null,i),!this._events)return this;return--this._counter,this._counter||(n.length=0),this},bt.prototype.burst=function(){return this._events?(this._clearOnEmit=!0,this.emit.apply(this,arguments),this):this},bt.prototype.countListeners=function(t){if(!this._events)return 0;var e=this._events[t];return e?e.length:0},bt.prototype.destroy=function(){return this._events?(this._queue.length=this._counter=0,this._events=null,this):this};var wt=vt?"pointerout":yt?"MSPointerOut":"";function xt(t){wt&&(this._dragger=t,this._timeout=null,this._outEvent=null,this._isActive=!1,this._addBehaviour=this._addBehaviour.bind(this),this._removeBehaviour=this._removeBehaviour.bind(this),this._onTimeout=this._onTimeout.bind(this),this._resetData=this._resetData.bind(this),this._onStart=this._onStart.bind(this),this._onOut=this._onOut.bind(this),this._dragger.on("start",this._onStart))}xt.prototype._addBehaviour=function(){this._isActive||(this._isActive=!0,this._dragger.on("move",this._resetData),this._dragger.on("cancel",this._removeBehaviour),this._dragger.on("end",this._removeBehaviour),window.addEventListener(wt,this._onOut))},xt.prototype._removeBehaviour=function(){this._isActive&&(this._dragger.off("move",this._resetData),this._dragger.off("cancel",this._removeBehaviour),this._dragger.off("end",this._removeBehaviour),window.removeEventListener(wt,this._onOut),this._resetData(),this._isActive=!1)},xt.prototype._resetData=function(){window.clearTimeout(this._timeout),this._timeout=null,this._outEvent=null},xt.prototype._onStart=function(t){"mouse"!==t.pointerType&&this._addBehaviour()},xt.prototype._onOut=function(t){this._dragger._getTrackedTouch(t)&&(this._resetData(),this._outEvent=t,this._timeout=window.setTimeout(this._onTimeout,100))},xt.prototype._onTimeout=function(){var t=this._outEvent;this._resetData(),this._dragger.isActive()&&this._dragger._onCancel(t)},xt.prototype.destroy=function(){wt&&(this._dragger.off("start",this._onStart),this._removeBehaviour())};var St=["","webkit","moz","ms","o","Webkit","Moz","MS","O"],Et={};function Tt(t,e){var i=Et[e]||"";if(i)return i;for(var n=e[0].toUpperCase()+e.slice(1),r=0;r<St.length;){if((i=St[r]?St[r]+n:e)in t)return Et[e]=i,i;++r}return""}function Dt(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("testPassive",null,e),window.removeEventListener("testPassive",null,e)}catch(t){}return t}var At=window.navigator.userAgent.toLowerCase(),kt=At.indexOf("edge")>-1,Rt=At.indexOf("trident")>-1,Pt=At.indexOf("firefox")>-1,Ot=At.indexOf("android")>-1,Lt=!!Dt()&&{passive:!0},Ct="touchAction",Mt=Tt(document.documentElement.style,Ct);function It(t,e){this._element=t,this._emitter=new bt,this._isDestroyed=!1,this._cssProps={},this._touchAction="",this._isActive=!1,this._pointerId=null,this._startTime=0,this._startX=0,this._startY=0,this._currentX=0,this._currentY=0,this._onStart=this._onStart.bind(this),this._onMove=this._onMove.bind(this),this._onCancel=this._onCancel.bind(this),this._onEnd=this._onEnd.bind(this),this._edgeHack=null,(kt||Rt)&&(vt||yt)&&(this._edgeHack=new xt(this)),this.setCssProps(e),this._touchAction||this.setTouchAction("auto"),t.addEventListener("dragstart",It._preventDefault,!1),t.addEventListener(It._inputEvents.start,this._onStart,Lt)}It._pointerEvents={start:"pointerdown",move:"pointermove",cancel:"pointercancel",end:"pointerup"},It._msPointerEvents={start:"MSPointerDown",move:"MSPointerMove",cancel:"MSPointerCancel",end:"MSPointerUp"},It._touchEvents={start:"touchstart",move:"touchmove",cancel:"touchcancel",end:"touchend"},It._mouseEvents={start:"mousedown",move:"mousemove",cancel:"",end:"mouseup"},It._inputEvents=gt?It._touchEvents:vt?It._pointerEvents:yt?It._msPointerEvents:It._mouseEvents,It._emitter=new bt,It._emitterEvents={start:"start",move:"move",end:"end",cancel:"cancel"},It._activeInstances=[],It._preventDefault=function(t){t.preventDefault&&!1!==t.cancelable&&t.preventDefault()},It._activateInstance=function(t){It._activeInstances.indexOf(t)>-1||(It._activeInstances.push(t),It._emitter.on(It._emitterEvents.move,t._onMove),It._emitter.on(It._emitterEvents.cancel,t._onCancel),It._emitter.on(It._emitterEvents.end,t._onEnd),1===It._activeInstances.length&&It._bindListeners())},It._deactivateInstance=function(t){var e=It._activeInstances.indexOf(t);-1!==e&&(It._activeInstances.splice(e,1),It._emitter.off(It._emitterEvents.move,t._onMove),It._emitter.off(It._emitterEvents.cancel,t._onCancel),It._emitter.off(It._emitterEvents.end,t._onEnd),It._activeInstances.length||It._unbindListeners())},It._bindListeners=function(){window.addEventListener(It._inputEvents.move,It._onMove,Lt),window.addEventListener(It._inputEvents.end,It._onEnd,Lt),It._inputEvents.cancel&&window.addEventListener(It._inputEvents.cancel,It._onCancel,Lt)},It._unbindListeners=function(){window.removeEventListener(It._inputEvents.move,It._onMove,Lt),window.removeEventListener(It._inputEvents.end,It._onEnd,Lt),It._inputEvents.cancel&&window.removeEventListener(It._inputEvents.cancel,It._onCancel,Lt)},It._getEventPointerId=function(t){return"number"==typeof t.pointerId?t.pointerId:t.changedTouches?t.changedTouches[0]?t.changedTouches[0].identifier:null:1},It._getTouchById=function(t,e){if("number"==typeof t.pointerId)return t.pointerId===e?t:null;if(t.changedTouches){for(var i=0;i<t.changedTouches.length;i++)if(t.changedTouches[i].identifier===e)return t.changedTouches[i];return null}return t},It._onMove=function(t){It._emitter.emit(It._emitterEvents.move,t)},It._onCancel=function(t){It._emitter.emit(It._emitterEvents.cancel,t)},It._onEnd=function(t){It._emitter.emit(It._emitterEvents.end,t)},It.prototype._reset=function(){this._pointerId=null,this._startTime=0,this._startX=0,this._startY=0,this._currentX=0,this._currentY=0,this._isActive=!1,It._deactivateInstance(this)},It.prototype._createEvent=function(t,e){var i=this._getTrackedTouch(e);return{type:t,srcEvent:e,distance:this.getDistance(),deltaX:this.getDeltaX(),deltaY:this.getDeltaY(),deltaTime:t===It._emitterEvents.start?0:this.getDeltaTime(),isFirst:t===It._emitterEvents.start,isFinal:t===It._emitterEvents.end||t===It._emitterEvents.cancel,pointerType:e.pointerType||(e.touches?"touch":"mouse"),identifier:this._pointerId,screenX:i.screenX,screenY:i.screenY,clientX:i.clientX,clientY:i.clientY,pageX:i.pageX,pageY:i.pageY,target:i.target}},It.prototype._emit=function(t,e){this._emitter.emit(t,this._createEvent(t,e))},It.prototype._getTrackedTouch=function(t){return null===this._pointerId?null:It._getTouchById(t,this._pointerId)},It.prototype._onStart=function(t){if(!this._isDestroyed&&null===this._pointerId&&(this._pointerId=It._getEventPointerId(t),null!==this._pointerId)){var e=this._getTrackedTouch(t);this._startX=this._currentX=e.clientX,this._startY=this._currentY=e.clientY,this._startTime=Date.now(),this._isActive=!0,this._emit(It._emitterEvents.start,t),this._isActive&&It._activateInstance(this)}},It.prototype._onMove=function(t){var e=this._getTrackedTouch(t);e&&(this._currentX=e.clientX,this._currentY=e.clientY,this._emit(It._emitterEvents.move,t))},It.prototype._onCancel=function(t){this._getTrackedTouch(t)&&(this._emit(It._emitterEvents.cancel,t),this._reset())},It.prototype._onEnd=function(t){this._getTrackedTouch(t)&&(this._emit(It._emitterEvents.end,t),this._reset())},It.prototype.isActive=function(){return this._isActive},It.prototype.setTouchAction=function(t){this._touchAction=t,Mt&&(this._cssProps[Mt]="",this._element.style[Mt]=t),gt&&(this._element.removeEventListener(It._touchEvents.start,It._preventDefault,!0),(this._element.style[Mt]!==t||Pt&&Ot)&&this._element.addEventListener(It._touchEvents.start,It._preventDefault,!0))},It.prototype.setCssProps=function(t){if(t){var e,i,n=this._cssProps,r=this._element;for(e in n)r.style[e]=n[e],delete n[e];for(e in t)t[e]&&(e!==Ct?(i=Tt(r.style,e))&&(n[i]="",r.style[i]=t[e]):this.setTouchAction(t[e]))}},It.prototype.getDeltaX=function(){return this._currentX-this._startX},It.prototype.getDeltaY=function(){return this._currentY-this._startY},It.prototype.getDistance=function(){var t=this.getDeltaX(),e=this.getDeltaY();return Math.sqrt(t*t+e*e)},It.prototype.getDeltaTime=function(){return this._startTime?Date.now()-this._startTime:0},It.prototype.on=function(t,e){this._emitter.on(t,e)},It.prototype.off=function(t,e){this._emitter.off(t,e)},It.prototype.destroy=function(){if(!this._isDestroyed){var t=this._element;for(var e in this._edgeHack&&this._edgeHack.destroy(),this._reset(),this._emitter.destroy(),t.removeEventListener(It._inputEvents.start,this._onStart,Lt),t.removeEventListener("dragstart",It._preventDefault,!1),t.removeEventListener(It._touchEvents.start,It._preventDefault,!0),this._cssProps)t.style[e]=this._cssProps[e],delete this._cssProps[e];this._element=null,this._isDestroyed=!0}};var Nt=(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return this.setTimeout((function(){t(Date.now())}),16.666666666666668)}).bind(window);function qt(t){this._nextStep=null,this._lanes=[],this._stepQueue=[],this._stepCallbacks={},this._step=this._step.bind(this);for(var e=0;e<t;e++)this._lanes.push(new jt)}function jt(){this.queue=[],this.indices={},this.callbacks={}}qt.prototype._step=function(t){var e,i,n,r,s,o,a=this._lanes,l=this._stepQueue,h=this._stepCallbacks;for(this._nextStep=null,e=0;e<a.length;e++){for(r=a[e].queue,s=a[e].callbacks,o=a[e].indices,i=0;i<r.length;i++)(n=r[i])&&(l.push(n),h[n]=s[n],delete s[n],delete o[n]);r.length=0}for(e=0;e<l.length;e++)h[n=l[e]]&&h[n](t),delete h[n];l.length=0},qt.prototype.add=function(t,e,i){this._lanes[t].add(e,i),this._nextStep||(this._nextStep=Nt(this._step))},qt.prototype.remove=function(t,e){this._lanes[t].remove(e)},jt.prototype.add=function(t,e){var i=this.indices[t];void 0!==i&&(this.queue[i]=void 0),this.queue.push(t),this.callbacks[t]=e,this.indices[t]=this.queue.length-1},jt.prototype.remove=function(t){var e=this.indices[t];void 0!==e&&(this.queue[e]=void 0,delete this.callbacks[t],delete this.indices[t])};var Xt="layoutRead",Ft="layoutWrite",Ht="visibilityRead",Yt="visibilityWrite",Bt="dragStartRead",zt="dragStartWrite",Wt="dragMoveRead",$t="dragMoveWrite",Gt="dragScrollRead",Ut="dragScrollWrite",Vt="dragSortRead",Jt="placeholderLayoutRead",Kt="placeholderLayoutWrite",Qt="placeholderResizeWrite",Zt="autoScrollRead",te="autoScrollWrite",ee="debounceRead",ie=new qt(3);function ne(t){ie.remove(0,Xt+t),ie.remove(2,Ft+t)}function re(t){ie.remove(0,Ht+t),ie.remove(2,Yt+t)}function se(t){ie.remove(0,Bt+t),ie.remove(2,zt+t)}function oe(t){ie.remove(0,Wt+t),ie.remove(2,$t+t)}function ae(t){ie.remove(0,Gt+t),ie.remove(2,Ut+t)}function le(t,e){ie.add(1,Vt+t,e)}function he(t){ie.remove(0,Jt+t),ie.remove(2,Kt+t)}function ue(t,e){ie.add(0,Zt,t),ie.add(2,te,e)}function ce(t){return"function"==typeof t}var de,fe="function"==typeof WeakMap,pe=fe?new WeakMap:null,_e=!0,me=function(){_e?(de=window.clearInterval(de),pe=fe?new WeakMap:null):_e=!0};function ge(t,e){var i=pe&&pe.get(t);return i||(i=window.getComputedStyle(t,null),pe&&pe.set(t,i)),pe&&(de?_e=!1:de=window.setInterval(me,3e3)),i.getPropertyValue(e)}function ve(t,e){return parseFloat(ge(t,e))||0}var ye,be=document.documentElement,we=document.body,xe={value:0,offset:0};function Se(t){return t===window||t===be||t===we?window:t}function Ee(t){return t===window?t.pageXOffset:t.scrollLeft}function Te(t){return t===window?t.pageYOffset:t.scrollTop}function De(t){return t===window?be.scrollWidth-be.clientWidth:t.scrollWidth-t.clientWidth}function Ae(t){return t===window?be.scrollHeight-be.clientHeight:t.scrollHeight-t.clientHeight}function ke(t,e){if(e=e||{},t===window)e.width=be.clientWidth,e.height=be.clientHeight,e.left=0,e.right=e.width,e.top=0,e.bottom=e.height;else{var i=t.getBoundingClientRect(),n=t.clientLeft||ve(t,"border-left-width"),r=t.clientTop||ve(t,"border-top-width");e.width=t.clientWidth,e.height=t.clientHeight,e.left=i.left+n,e.right=e.left+e.width,e.top=i.top+r,e.bottom=e.top+e.height}return e}function Re(t){return t._drag._getGrid()._settings.dragAutoScroll}function Pe(t){t._drag&&t._drag._prepareScroll()}function Oe(t){if(t._drag&&t._isActive){var e=t._drag;e._scrollDiffX=e._scrollDiffY=0,t._setTranslate(e._left,e._top)}}function Le(t,e,i,n){return xe.value=Math.min(n/2,t),xe.offset=Math.max(0,i+2*xe.value+n*e-n)/2,xe}function Ce(){this.reset()}function Me(){this.element=null,this.requestX=null,this.requestY=null,this.scrollLeft=0,this.scrollTop=0}function Ie(t,e){this.pool=[],this.createItem=t,this.releaseItem=e}function Ne(t,e){var i=function(t,e){return function(t,e){return!(t.left+t.width<=e.left||e.left+e.width<=t.left||t.top+t.height<=e.top||e.top+e.height<=t.top)}(t,e)?(Math.min(t.left+t.width,e.left+e.width)-Math.max(t.left,e.left))*(Math.min(t.top+t.height,e.top+e.height)-Math.max(t.top,e.top)):0}(t,e);return i?i/(Math.min(t.width,e.width)*Math.min(t.height,e.height))*100:0}Ce.prototype.reset=function(){this.isActive&&this.onStop(),this.item=null,this.element=null,this.isActive=!1,this.isEnding=!1,this.direction=null,this.value=null,this.maxValue=0,this.threshold=0,this.distance=0,this.speed=0,this.duration=0,this.action=null},Ce.prototype.hasReachedEnd=function(){return 4&this.direction?this.value>=this.maxValue:this.value<=0},Ce.prototype.computeCurrentScrollValue=function(){return null===this.value?1&this.direction?Ee(this.element):Te(this.element):Math.max(0,Math.min(this.value,this.maxValue))},Ce.prototype.computeNextScrollValue=function(t){var e=this.speed*(t/1e3),i=4&this.direction?this.value+e:this.value-e;return Math.max(0,Math.min(i,this.maxValue))},Ce.prototype.computeSpeed=(ye={direction:null,threshold:0,distance:0,value:0,maxValue:0,deltaTime:0,duration:0,isEnding:!1},function(t){var e=this.item,i=Re(e).speed;return ce(i)?(ye.direction=this.direction,ye.threshold=this.threshold,ye.distance=this.distance,ye.value=this.value,ye.maxValue=this.maxValue,ye.duration=this.duration,ye.speed=this.speed,ye.deltaTime=t,ye.isEnding=this.isEnding,i(e,this.element,ye)):i}),Ce.prototype.tick=function(t){return this.isActive||(this.isActive=!0,this.onStart()),this.value=this.computeCurrentScrollValue(),this.speed=this.computeSpeed(t),this.value=this.computeNextScrollValue(t),this.duration+=t,this.value},Ce.prototype.onStart=function(){var t=this.item,e=Re(t).onStart;ce(e)&&e(t,this.element,this.direction)},Ce.prototype.onStop=function(){var t=this.item,e=Re(t).onStop;ce(e)&&e(t,this.element,this.direction),t._drag&&t._drag.sort()},Me.prototype.reset=function(){this.requestX&&(this.requestX.action=null),this.requestY&&(this.requestY.action=null),this.element=null,this.requestX=null,this.requestY=null,this.scrollLeft=0,this.scrollTop=0},Me.prototype.addRequest=function(t){1&t.direction?(this.removeRequest(this.requestX),this.requestX=t):(this.removeRequest(this.requestY),this.requestY=t),t.action=this},Me.prototype.removeRequest=function(t){t&&(this.requestX===t?(this.requestX=null,t.action=null):this.requestY===t&&(this.requestY=null,t.action=null))},Me.prototype.computeScrollValues=function(){this.scrollLeft=this.requestX?this.requestX.value:Ee(this.element),this.scrollTop=this.requestY?this.requestY.value:Te(this.element)},Me.prototype.scroll=function(){var t=this.element;t&&(t.scrollTo?t.scrollTo(this.scrollLeft,this.scrollTop):(t.scrollLeft=this.scrollLeft,t.scrollTop=this.scrollTop))},Ie.prototype.pick=function(){return this.pool.pop()||this.createItem()},Ie.prototype.release=function(t){this.releaseItem(t),-1===this.pool.indexOf(t)&&this.pool.push(t)},Ie.prototype.reset=function(){this.pool.length=0};var qe={width:0,height:0,left:0,right:0,top:0,bottom:0},je={width:0,height:0,left:0,right:0,top:0,bottom:0};function Xe(){this._isDestroyed=!1,this._isTicking=!1,this._tickTime=0,this._tickDeltaTime=0,this._items=[],this._actions=[],this._requests={},this._requests[1]={},this._requests[2]={},this._requestOverlapCheck={},this._dragPositions={},this._dragDirections={},this._overlapCheckInterval=150,this._requestPool=new Ie((function(){return new Ce}),(function(t){t.reset()})),this._actionPool=new Ie((function(){return new Me}),(function(t){t.reset()})),this._readTick=this._readTick.bind(this),this._writeTick=this._writeTick.bind(this)}Xe.AXIS_X=1,Xe.AXIS_Y=2,Xe.FORWARD=4,Xe.BACKWARD=8,Xe.LEFT=9,Xe.RIGHT=5,Xe.UP=10,Xe.DOWN=6,Xe.smoothSpeed=function(t,e,i){return function(n,r,s){var o=0;if(!s.isEnding)if(s.threshold>0){var a=s.threshold-Math.max(0,s.distance);o=t/s.threshold*a}else o=t;var l=s.speed,h=o;return l===o?h:l<o?(h=l+e*(s.deltaTime/1e3),Math.min(o,h)):(h=l-i*(s.deltaTime/1e3),Math.max(o,h))}},Xe.pointerHandle=function(t){var e={left:0,top:0,width:0,height:0},i=t||1;return function(t,n,r,s,o,a,l){return e.left=a-.5*i,e.top=l-.5*i,e.width=i,e.height=i,e}},Xe.prototype._readTick=function(t){this._isDestroyed||(t&&this._tickTime?(this._tickDeltaTime=t-this._tickTime,this._tickTime=t,this._updateRequests(),this._updateActions()):(this._tickTime=t,this._tickDeltaTime=0))},Xe.prototype._writeTick=function(){this._isDestroyed||(this._applyActions(),ue(this._readTick,this._writeTick))},Xe.prototype._startTicking=function(){this._isTicking=!0,ue(this._readTick,this._writeTick)},Xe.prototype._stopTicking=function(){this._isTicking=!1,this._tickTime=0,this._tickDeltaTime=0,ie.remove(0,Zt),ie.remove(2,te)},Xe.prototype._getItemHandleRect=function(t,e,i){var n=t._drag;if(e){var r=n._dragMoveEvent||n._dragStartEvent,s=e(t,n._clientX,n._clientY,t._width,t._height,r.clientX,r.clientY);i.left=s.left,i.top=s.top,i.width=s.width,i.height=s.height}else i.left=n._clientX,i.top=n._clientY,i.width=t._width,i.height=t._height;return i.right=i.left+i.width,i.bottom=i.top+i.height,i},Xe.prototype._requestItemScroll=function(t,e,i,n,r,s,o){var a=this._requests[e],l=a[t._id];l?l.element===i&&l.direction===n||l.reset():l=this._requestPool.pick(),l.item=t,l.element=i,l.direction=n,l.threshold=r,l.distance=s,l.maxValue=o,a[t._id]=l},Xe.prototype._cancelItemScroll=function(t,e){var i=this._requests[e],n=i[t._id];n&&(n.action&&n.action.removeRequest(n),this._requestPool.release(n),delete i[t._id])},Xe.prototype._checkItemOverlap=function(t,e,i){var n=Re(t),r=ce(n.targets)?n.targets(t):n.targets,s=n.threshold,o=n.safeZone;if(!r||!r.length)return e&&this._cancelItemScroll(t,1),void(i&&this._cancelItemScroll(t,2));var a=this._dragDirections[t._id],l=a[0],h=a[1];if(!l&&!h)return e&&this._cancelItemScroll(t,1),void(i&&this._cancelItemScroll(t,2));for(var u=this._getItemHandleRect(t,n.handle,qe),c=je,d=null,f=null,p=!0,_=!0,m=0,g=0,v=null,y=null,b=0,w=0,x=0,S=null,E=-1/0,T=0,D=0,A=null,k=0,R=0,P=null,O=-1/0,L=0,C=0,M=null,I=0,N=0,q=0;q<r.length;q++)d=r[q],p=e&&l&&2!==d.axis,_=i&&h&&1!==d.axis,g=d.priority||0,(!p||g<E)&&(!_||g<O)||(f=Se(d.element||d),w=p?De(f):-1,x=_?Ae(f):-1,(w||x)&&((m=Ne(u,c=ke(f,c)))<=0||(p&&g>=E&&w>0&&(g>E||m>D)&&(y=null,v=Le("number"==typeof d.threshold?d.threshold:s,o,u.width,c.width),5===l?(b=c.right+v.offset-u.right)<=v.value&&Ee(f)<w&&(y=5):9===l&&(b=u.left-(c.left-v.offset))<=v.value&&Ee(f)>0&&(y=9),null!==y&&(S=f,E=g,T=v.value,D=m,A=y,k=b,R=w)),_&&g>=O&&x>0&&(g>O||m>C)&&(y=null,v=Le("number"==typeof d.threshold?d.threshold:s,o,u.height,c.height),6===h?(b=c.bottom+v.offset-u.bottom)<=v.value&&Te(f)<x&&(y=6):10===h&&(b=u.top-(c.top-v.offset))<=v.value&&Te(f)>0&&(y=10),null!==y&&(P=f,O=g,L=v.value,C=m,M=y,I=b,N=x)))));e&&(S?this._requestItemScroll(t,1,S,A,T,k,R):this._cancelItemScroll(t,1)),i&&(P?this._requestItemScroll(t,2,P,M,L,I,N):this._cancelItemScroll(t,2))},Xe.prototype._updateScrollRequest=function(t){for(var e=t.item,i=Re(e),n=ce(i.targets)?i.targets(e):i.targets,r=n&&n.length||0,s=i.threshold,o=i.safeZone,a=this._getItemHandleRect(e,i.handle,qe),l=je,h=null,u=null,c=!1,d=null,f=null,p=null,_=null,m=null,g=0;g<r;g++)if((u=Se((h=n[g]).element||h))===t.element){if(c=!!(1&t.direction)){if(2===h.axis)continue}else if(1===h.axis)continue;if((_=c?De(u):Ae(u))<=0)break;if(Ne(a,l=ke(u,l))<=0)break;if(d=Le("number"==typeof h.threshold?h.threshold:s,o,c?a.width:a.height,c?l.width:l.height),(f=9===t.direction?a.left-(l.left-d.offset):5===t.direction?l.right+d.offset-a.right:10===t.direction?a.top-(l.top-d.offset):l.bottom+d.offset-a.bottom)>d.value)break;if(p=c?Ee(u):Te(u),m=4&t.direction?p>=_:p<=0)break;return t.maxValue=_,t.threshold=d.value,t.distance=f,t.isEnding=!1,!0}return!0===i.smoothStop&&t.speed>0?(null===m&&(m=t.hasReachedEnd()),t.isEnding=!m):t.isEnding=!1,t.isEnding},Xe.prototype._updateRequests=function(){for(var t,e,i,n,r,s,o,a=this._items,l=this._requests[1],h=this._requests[2],u=0;u<a.length;u++)t=a[u],r=(n=this._requestOverlapCheck[t._id])>0&&this._tickTime-n>this._overlapCheckInterval,s=!0,(e=l[t._id])&&e.isActive&&(s=!this._updateScrollRequest(e))&&(r=!0,this._cancelItemScroll(t,1)),o=!0,(i=h[t._id])&&i.isActive&&(o=!this._updateScrollRequest(i))&&(r=!0,this._cancelItemScroll(t,2)),r&&(this._requestOverlapCheck[t._id]=0,this._checkItemOverlap(t,s,o))},Xe.prototype._requestAction=function(t,e){for(var i=this._actions,n=1===e,r=null,s=0;s<i.length;s++){if(r=i[s],t.element===r.element){if(n?r.requestX:r.requestY)return void this._cancelItemScroll(t.item,e);break}r=null}r||(r=this._actionPool.pick()),r.element=t.element,r.addRequest(t),t.tick(this._tickDeltaTime),i.push(r)},Xe.prototype._updateActions=function(){var t,e,i,n,r=this._items,s=this._requests,o=this._actions;for(n=0;n<r.length;n++)t=r[n]._id,e=s[1][t],i=s[2][t],e&&this._requestAction(e,1),i&&this._requestAction(i,2);for(n=0;n<o.length;n++)o[n].computeScrollValues()},Xe.prototype._applyActions=function(){var t,e=this._actions,i=this._items;if(e.length){for(t=0;t<e.length;t++)e[t].scroll(),this._actionPool.release(e[t]);for(e.length=0,t=0;t<i.length;t++)Pe(i[t]);for(t=0;t<i.length;t++)Oe(i[t])}},Xe.prototype._updateDragDirection=function(t){var e=this._dragPositions[t._id],i=this._dragDirections[t._id],n=t._drag._left,r=t._drag._top;if(e.length){var s=e[0],o=e[1];i[0]=n>s?5:n<s?9:i[0]||0,i[1]=r>o?6:r<o?10:i[1]||0}e[0]=n,e[1]=r},Xe.prototype.addItem=function(t){this._isDestroyed||-1===this._items.indexOf(t)&&(this._items.push(t),this._requestOverlapCheck[t._id]=this._tickTime,this._dragDirections[t._id]=[0,0],this._dragPositions[t._id]=[],this._isTicking||this._startTicking())},Xe.prototype.updateItem=function(t){this._isDestroyed||this._dragDirections[t._id]&&(this._updateDragDirection(t),this._requestOverlapCheck[t._id]||(this._requestOverlapCheck[t._id]=this._tickTime))},Xe.prototype.removeItem=function(t){if(!this._isDestroyed){var e=this._items.indexOf(t);if(-1!==e){var i=t._id;this._requests[1][i]&&(this._cancelItemScroll(t,1),delete this._requests[1][i]),this._requests[2][i]&&(this._cancelItemScroll(t,2),delete this._requests[2][i]),delete this._requestOverlapCheck[i],delete this._dragPositions[i],delete this._dragDirections[i],this._items.splice(e,1),this._isTicking&&!this._items.length&&this._stopTicking()}}},Xe.prototype.isItemScrollingX=function(t){var e=this._requests[1][t._id];return!(!e||!e.isActive)},Xe.prototype.isItemScrollingY=function(t){var e=this._requests[2][t._id];return!(!e||!e.isActive)},Xe.prototype.isItemScrolling=function(t){return this.isItemScrollingX(t)||this.isItemScrollingY(t)},Xe.prototype.destroy=function(){if(!this._isDestroyed){for(var t=this._items.slice(0),e=0;e<t.length;e++)this.removeItem(t[e]);this._actions.length=0,this._requestPool.reset(),this._actionPool.reset(),this._isDestroyed=!0}};var Fe=window.Element.prototype,He=Fe.matches||Fe.matchesSelector||Fe.webkitMatchesSelector||Fe.mozMatchesSelector||Fe.msMatchesSelector||Fe.oMatchesSelector||function(){return!1};function Ye(t,e){return He.call(t,e)}function Be(t,e){e&&(t.classList?t.classList.add(e):Ye(t,"."+e)||(t.className+=" "+e))}var ze=[];function We(t,e,i){var n="number"==typeof i?i:-1;n<0&&(n=t.length-n+1),t.splice.apply(t,ze.concat(n,0,e)),ze.length=0}function $e(t,e,i){var n=Math.max(0,t.length-1+(i||0));return e>n?n:e<0?Math.max(n+e+1,0):e}function Ge(t,e,i){if(!(t.length<2)){var n=$e(t,e),r=$e(t,i);n!==r&&t.splice(r,0,t.splice(n,1)[0])}}function Ue(t,e,i){if(!(t.length<2)){var n,r=$e(t,e),s=$e(t,i);r!==s&&(n=t[r],t[r]=t[s],t[s]=n)}}var Ve=Tt(document.documentElement.style,"transform")||"transform",Je=/([A-Z])/g,Ke=/^(webkit-|moz-|ms-|o-)/,Qe=/^(-m-s-)/;function Ze(t){var e=t.replace(Je,"-$1").toLowerCase();return e=(e=e.replace(Ke,"-$1")).replace(Qe,"-ms-")}var ti=Ze(Ve);function ei(t){var e=ge(t,ti);if(!e||"none"===e)return!1;var i=ge(t,"display");return"inline"!==i&&"none"!==i}function ii(t){for(var e=document,i=t||e;i&&i!==e&&"static"===ge(i,"position")&&!ei(i);)i=i.parentElement||e;return i}var ni={},ri={},si={};function oi(t,e){var i,n=e||{};return n.left=0,n.top=0,t===document?n:(n.left=window.pageXOffset||0,n.top=window.pageYOffset||0,t.self===window.self||(i=t.getBoundingClientRect(),n.left+=i.left,n.top+=i.top,n.left+=ve(t,"border-left-width"),n.top+=ve(t,"border-top-width")),n)}function ai(t,e,i){return si.left=0,si.top=0,t===e||i&&(t=ii(t))===(e=ii(e))||(oi(t,ni),oi(e,ri),si.left=ri.left-ni.left,si.top=ri.top-ni.top),si}function li(t){return"auto"===t||"scroll"===t||"overlay"===t}function hi(t){return li(ge(t,"overflow"))||li(ge(t,"overflow-x"))||li(ge(t,"overflow-y"))}function ui(t,e){for(e=e||[];t&&t!==document;)t.getRootNode&&t instanceof DocumentFragment?t=t.getRootNode().host:(hi(t)&&e.push(t),t=t.parentNode);return e.push(window),e}var ci={},di=/^matrix3d/,fi=/([^,]*,){4}/,pi=/([^,]*,){12}/,_i=/[^,]*,/;function mi(t){ci.x=0,ci.y=0;var e=ge(t,ti);if(!e||"none"===e)return ci;var i=di.test(e),n=e.replace(i?pi:fi,""),r=n.replace(_i,"");return ci.x=parseFloat(n)||0,ci.y=parseFloat(r)||0,ci}function gi(t,e){e&&(t.classList?t.classList.remove(e):Ye(t,"."+e)&&(t.className=(" "+t.className+" ").replace(" "+e+" "," ").trim()))}var vi,yi,bi,wi,xi=/^(iPad|iPhone|iPod)/.test(window.navigator.platform)||/^Mac/.test(window.navigator.platform)&&window.navigator.maxTouchPoints>1,Si=!!Dt()&&{passive:!0};function Ei(t){var e=t._element,i=t.getGrid(),n=i._settings;this._item=t,this._gridId=i._id,this._isDestroyed=!1,this._isMigrating=!1,this._startPredicate=ce(n.dragStartPredicate)?n.dragStartPredicate:Ei.defaultStartPredicate,this._startPredicateState=0,this._startPredicateResult=void 0,this._isSortNeeded=!1,this._sortTimer=void 0,this._blockedSortIndex=null,this._sortX1=0,this._sortX2=0,this._sortY1=0,this._sortY2=0,this._reset(),this._preStartCheck=this._preStartCheck.bind(this),this._preEndCheck=this._preEndCheck.bind(this),this._onScroll=this._onScroll.bind(this),this._prepareStart=this._prepareStart.bind(this),this._applyStart=this._applyStart.bind(this),this._prepareMove=this._prepareMove.bind(this),this._applyMove=this._applyMove.bind(this),this._prepareScroll=this._prepareScroll.bind(this),this._applyScroll=this._applyScroll.bind(this),this._handleSort=this._handleSort.bind(this),this._handleSortDelayed=this._handleSortDelayed.bind(this),this._handle=n.dragHandle&&e.querySelector(n.dragHandle)||e,this._dragger=new It(this._handle,n.dragCssProps),this._dragger.on("start",this._preStartCheck),this._dragger.on("move",this._preStartCheck),this._dragger.on("cancel",this._preEndCheck),this._dragger.on("end",this._preEndCheck)}function Ti(t,e){var i,n,r={};if(Array.isArray(e))for(n=0;n<e.length;n++)r[i=e[n]]=ge(t,Ze(i));else for(i in e)r[i]=ge(t,Ze(i));return r}Ei.autoScroller=new Xe,Ei.defaultStartPredicate=function(t,e,i){var n=t._drag;if(e.isFirst&&e.srcEvent.button)return!1;if(!xi&&e.isFirst&&!0===e.srcEvent.isTrusted&&!1===e.srcEvent.defaultPrevented&&!1===e.srcEvent.cancelable)return!1;if(!e.isFinal){var r=n._startPredicateData;if(!r){var s=i||n._getGrid()._settings.dragStartPredicate||{};n._startPredicateData=r={distance:Math.max(s.distance,0)||0,delay:Math.max(s.delay,0)||0}}return r.delay&&(r.event=e,r.delayTimer||(r.delayTimer=window.setTimeout((function(){r.delay=0,n._resolveStartPredicate(r.event)&&(n._forceResolveStartPredicate(r.event),n._resetStartPredicate())}),r.delay))),n._resolveStartPredicate(e)}n._finishStartPredicate(e)},Ei.defaultSortPredicate=(vi={},yi={},bi={},wi=[],function(t,e){var i=t._drag,n=i._getGrid(),r=e&&"number"==typeof e.threshold?e.threshold:50,s=e&&e.action===it?it:nt,o=e&&e.migrateAction===it?it:nt;r=Math.min(Math.max(r,1),100),vi.width=t._width,vi.height=t._height,vi.left=i._clientX,vi.top=i._clientY;var a=function(t,e,i){var n,r,s,o,a,l,h,u,c,d,f=null,p=e._settings.dragSort,_=-1;if(!0===p?(wi[0]=e,r=wi):ce(p)&&(r=p.call(e,t)),!r||!Array.isArray(r)||!r.length)return f;for(d=0;d<r.length;d++)if(!(s=r[d])._isDestroyed){for(s._updateBoundingRect(),l=Math.max(0,s._left),h=Math.max(0,s._top),u=Math.min(window.innerWidth,s._right),c=Math.min(window.innerHeight,s._bottom),o=s._element.parentNode;o&&o!==document&&o!==document.documentElement&&o!==document.body;)if(o.getRootNode&&o instanceof DocumentFragment)o=o.getRootNode().host;else{if("visible"!==ge(o,"overflow")&&(a=o.getBoundingClientRect(),l=Math.max(l,a.left),h=Math.max(h,a.top),u=Math.min(u,a.right),c=Math.min(c,a.bottom)),"fixed"===ge(o,"position"))break;o=o.parentNode}l>=u||h>=c||(yi.left=l,yi.top=h,yi.width=u-l,yi.height=c-h,(n=Ne(vi,yi))>i&&n>_&&(_=n,f=s))}return wi.length=0,f}(t,n,r);if(!a)return null;var l,h,u,c=t.getGrid()!==a,d=0,f=0,p=0,_=-1,m=!1;for(a===n?(vi.left=i._gridX+t._marginLeft,vi.top=i._gridY+t._marginTop):(a._updateBorders(1,0,1,0),d=a._left+a._borderLeft,f=a._top+a._borderTop),u=0;u<a._items.length;u++)(l=a._items[u])._isActive&&l!==t&&(m=!0,yi.width=l._width,yi.height=l._height,yi.left=l._left+l._marginLeft+d,yi.top=l._top+l._marginTop+f,(h=Ne(vi,yi))>p&&(_=u,p=h));return c&&p<r&&(_=m?_:0,p=r),p>=r?(bi.grid=a,bi.index=_,bi.action=c?o:s,bi):null}),Ei.prototype.stop=function(){if(this._isActive)if(this._isMigrating)this._finishMigration();else{Ei.autoScroller.removeItem(this._item);var t=this._item._id;if(se(t),oe(t),ae(t),this._cancelSort(),this._isStarted){this._unbindScrollListeners();var e=item._element,i=this._getGrid(),n=i._settings.itemDraggingClass;e.parentNode!==i._element&&(i._element.appendChild(e),item._setTranslate(this._gridX,this._gridY)),gi(e,n)}this._reset()}},Ei.prototype.sort=function(t){var e=this._item;this._isActive&&e._isActive&&this._dragMoveEvent&&(!0===t?this._handleSort():le(e._id,this._handleSort))},Ei.prototype.destroy=function(){this._isDestroyed||(this.stop(),this._dragger.destroy(),Ei.autoScroller.removeItem(this._item),this._isDestroyed=!0)},Ei.prototype._getGrid=function(){return tt[this._gridId]||null},Ei.prototype._reset=function(){this._isActive=!1,this._isStarted=!1,this._container=null,this._containingBlock=null,this._dragStartEvent=null,this._dragMoveEvent=null,this._dragPrevMoveEvent=null,this._scrollEvent=null,this._scrollers=[],this._left=0,this._top=0,this._gridX=0,this._gridY=0,this._clientX=0,this._clientY=0,this._scrollDiffX=0,this._scrollDiffY=0,this._moveDiffX=0,this._moveDiffY=0,this._containerDiffX=0,this._containerDiffY=0},Ei.prototype._bindScrollListeners=function(){var t,e,i=this._getGrid()._element,n=this._container,r=this._scrollers;if(r.length=0,ui(this._item._element.parentNode,r),n!==i)for(ui(i,t=[]),e=0;e<t.length;e++)r.indexOf(t[e])<0&&r.push(t[e]);for(e=0;e<r.length;e++)r[e].addEventListener("scroll",this._onScroll,Si)},Ei.prototype._unbindScrollListeners=function(){var t,e=this._scrollers;for(t=0;t<e.length;t++)e[t].removeEventListener("scroll",this._onScroll,Si);e.length=0},Ei.prototype._resolveStartPredicate=function(t){var e=this._startPredicateData;if(!(t.distance<e.distance||e.delay))return this._resetStartPredicate(),!0},Ei.prototype._forceResolveStartPredicate=function(t){this._isDestroyed||1!==this._startPredicateState||(this._startPredicateState=2,this._onStart(t))},Ei.prototype._finishStartPredicate=function(t){var e=this._item._element,i=Math.abs(t.deltaX)<2&&Math.abs(t.deltaY)<2&&t.deltaTime<200;this._resetStartPredicate(),i&&function(t){if("a"!==t.tagName.toLowerCase())return;var e=t.getAttribute("href");if(!e)return;var i=t.getAttribute("target");i&&"_self"!==i?window.open(e,i):window.location.href=e}(e)},Ei.prototype._resetHeuristics=function(t,e){this._blockedSortIndex=null,this._sortX1=this._sortX2=t,this._sortY1=this._sortY2=e},Ei.prototype._checkHeuristics=function(t,e){var i=this._getGrid()._settings.dragSortHeuristics,n=i.minDragDistance;if(n<=0)return this._blockedSortIndex=null,!0;var r=t-this._sortX2,s=e-this._sortY2,o=n>3&&i.minBounceBackAngle>0;if(o||(this._blockedSortIndex=null),Math.abs(r)>n||Math.abs(s)>n){if(o){var a=Math.atan2(r,s),l=Math.atan2(this._sortX2-this._sortX1,this._sortY2-this._sortY1),h=Math.atan2(Math.sin(a-l),Math.cos(a-l));Math.abs(h)>i.minBounceBackAngle&&(this._blockedSortIndex=null)}return this._sortX1=this._sortX2,this._sortY1=this._sortY2,this._sortX2=t,this._sortY2=e,!0}return!1},Ei.prototype._resetStartPredicate=function(){var t=this._startPredicateData;t&&(t.delayTimer&&(t.delayTimer=window.clearTimeout(t.delayTimer)),this._startPredicateData=null)},Ei.prototype._handleSort=function(){if(this._isActive){var t=this._getGrid()._settings;if(!t.dragSort||!t.dragAutoScroll.sortDuringScroll&&Ei.autoScroller.isItemScrolling(this._item))return this._sortX1=this._sortX2=this._gridX,this._sortY1=this._sortY2=this._gridY,this._isSortNeeded=!0,void(void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)));var e=this._checkHeuristics(this._gridX,this._gridY);if(this._isSortNeeded||e){var i=t.dragSortHeuristics.sortInterval;i<=0||this._isSortNeeded?(this._isSortNeeded=!1,void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)),this._checkOverlap()):void 0===this._sortTimer&&(this._sortTimer=window.setTimeout(this._handleSortDelayed,i))}}},Ei.prototype._handleSortDelayed=function(){this._isSortNeeded=!0,this._sortTimer=void 0,le(this._item._id,this._handleSort)},Ei.prototype._cancelSort=function(){var t;this._isSortNeeded=!1,void 0!==this._sortTimer&&(this._sortTimer=window.clearTimeout(this._sortTimer)),t=this._item._id,ie.remove(1,Vt+t)},Ei.prototype._finishSort=function(){var t=this._getGrid()._settings.dragSort&&(this._isSortNeeded||void 0!==this._sortTimer);this._cancelSort(),t&&this._checkOverlap()},Ei.prototype._checkOverlap=function(){if(this._isActive){var t,e,i,n,r,s,o,a,l=this._item,h=this._getGrid()._settings;(t=ce(h.dragSortPredicate)?h.dragSortPredicate(l,this._dragMoveEvent):Ei.defaultSortPredicate(l,h.dragSortPredicate))&&"number"==typeof t.index&&(o=t.action===it?it:nt,a=(e=l.getGrid())!==(n=t.grid||e),i=e._items.indexOf(l),r=$e(n._items,t.index,a&&o===nt?1:0),(a||r!==this._blockedSortIndex)&&(a?(this._blockedSortIndex=null,s=n._items[r],e._hasListeners(ft)&&e._emit(ft,{item:l,fromGrid:e,fromIndex:i,toGrid:n,toIndex:r}),n._hasListeners(_t)&&n._emit(_t,{item:l,fromGrid:e,fromIndex:i,toGrid:n,toIndex:r}),l._gridId=n._id,this._isMigrating=l._gridId!==this._gridId,e._items.splice(i,1),We(n._items,l,r),l._sortData=null,e._hasListeners(dt)&&e._emit(dt,{item:l,fromGrid:e,fromIndex:i,toGrid:n,toIndex:r}),n._hasListeners(pt)&&n._emit(pt,{item:l,fromGrid:e,fromIndex:i,toGrid:n,toIndex:r}),o===it&&s&&s.isActive()&&n._items.indexOf(s)>-1&&n.send(s,e,i,{appendTo:this._container||document.body,layoutSender:!1,layoutReceiver:!1}),e.layout(),n.layout()):i!==r&&(this._blockedSortIndex=i,(o===it?Ue:Ge)(e._items,i,r),e._hasListeners(ct)&&e._emit(ct,{item:l,fromIndex:i,toIndex:r,action:o}),e.layout())))}},Ei.prototype._finishMigration=function(){var t,e,i=this._item,n=i._dragRelease,r=i._element,s=i._isActive,o=i.getGrid(),a=o._element,l=o._settings,h=l.dragContainer||a,u=this._getGrid()._settings,c=r.parentNode,d=s?u.itemVisibleClass:u.itemHiddenClass,f=s?l.itemVisibleClass:l.itemHiddenClass;this._isMigrating=!1,this.destroy(),u.itemClass!==l.itemClass&&(gi(r,u.itemClass),Be(r,l.itemClass)),d!==f&&(gi(r,d),Be(r,f)),h!==c&&(h.appendChild(r),e=ai(c,h,!0),(t=mi(r)).x-=e.left,t.y-=e.top),i._refreshDimensions(),e=ai(h,a,!0),n._containerDiffX=e.left,n._containerDiffY=e.top,i._drag=l.dragEnabled?new Ei(i):null,h!==c&&i._setTranslate(t.x,t.y),i._visibility.setStyles(s?l.visibleStyles:l.hiddenStyles),n.start()},Ei.prototype._preStartCheck=function(t){0===this._startPredicateState&&(this._startPredicateState=1),1===this._startPredicateState?(this._startPredicateResult=this._startPredicate(this._item,t),!0===this._startPredicateResult?(this._startPredicateState=2,this._onStart(t)):!1===this._startPredicateResult&&(this._resetStartPredicate(t),this._dragger._reset(),this._startPredicateState=0)):2===this._startPredicateState&&this._isActive&&this._onMove(t)},Ei.prototype._preEndCheck=function(t){var e=2===this._startPredicateState;this._startPredicate(this._item,t),this._startPredicateState=0,e&&this._isActive&&(this._isStarted?this._onEnd(t):this.stop())},Ei.prototype._onStart=function(t){var e,i,n,r=this._item;r._isActive&&(this._isActive=!0,this._dragStartEvent=t,Ei.autoScroller.addItem(r),e=r._id,i=this._prepareStart,n=this._applyStart,ie.add(0,Bt+e,i),ie.add(2,zt+e,n))},Ei.prototype._prepareStart=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=t._element,i=this._getGrid(),n=i._settings,r=i._element,s=n.dragContainer||r,o=ii(s),a=mi(e),l=e.getBoundingClientRect(),h=s!==r;if(this._container=s,this._containingBlock=o,this._clientX=l.left,this._clientY=l.top,this._left=this._gridX=a.x,this._top=this._gridY=a.y,this._scrollDiffX=this._scrollDiffY=0,this._moveDiffX=this._moveDiffY=0,this._resetHeuristics(this._gridX,this._gridY),h){var u=ai(o,r);this._containerDiffX=u.left,this._containerDiffY=u.top}}}},Ei.prototype._applyStart=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=this._getGrid(),i=t._element,n=t._dragRelease,r=t._migrate,s=this._container!==e._element;t.isPositioning()&&t._layout.stop(!0,this._left,this._top),r._isActive&&(this._left-=r._containerDiffX,this._top-=r._containerDiffY,this._gridX-=r._containerDiffX,this._gridY-=r._containerDiffY,r.stop(!0,this._left,this._top)),t.isReleasing()&&n._reset(),e._settings.dragPlaceholder.enabled&&t._dragPlaceholder.create(),this._isStarted=!0,e._emit("dragInit",t,this._dragStartEvent),s&&(i.parentNode===this._container?(this._gridX-=this._containerDiffX,this._gridY-=this._containerDiffY):(this._left+=this._containerDiffX,this._top+=this._containerDiffY,this._container.appendChild(i),t._setTranslate(this._left,this._top))),Be(i,e._settings.itemDraggingClass),this._bindScrollListeners(),e._emit("dragStart",t,this._dragStartEvent)}}},Ei.prototype._onMove=function(t){var e,i,n,r=this._item;r._isActive?(this._dragMoveEvent=t,e=r._id,i=this._prepareMove,n=this._applyMove,ie.add(0,Wt+e,i),ie.add(2,$t+e,n),le(r._id,this._handleSort)):this.stop()},Ei.prototype._prepareMove=function(){if(this._isActive&&this._item._isActive){var t=this._getGrid()._settings.dragAxis,e=this._dragMoveEvent,i=this._dragPrevMoveEvent||this._dragStartEvent||e;if("y"!==t){var n=e.clientX-i.clientX;this._left=this._left-this._moveDiffX+n,this._gridX=this._gridX-this._moveDiffX+n,this._clientX=this._clientX-this._moveDiffX+n,this._moveDiffX=n}if("x"!==t){var r=e.clientY-i.clientY;this._top=this._top-this._moveDiffY+r,this._gridY=this._gridY-this._moveDiffY+r,this._clientY=this._clientY-this._moveDiffY+r,this._moveDiffY=r}this._dragPrevMoveEvent=e}},Ei.prototype._applyMove=function(){if(this._isActive){var t=this._item;t._isActive&&(this._moveDiffX=this._moveDiffY=0,t._setTranslate(this._left,this._top),this._getGrid()._emit("dragMove",t,this._dragMoveEvent),Ei.autoScroller.updateItem(t))}},Ei.prototype._onScroll=function(t){var e,i,n,r=this._item;r._isActive?(this._scrollEvent=t,e=r._id,i=this._prepareScroll,n=this._applyScroll,ie.add(0,Gt+e,i),ie.add(2,Ut+e,n),le(r._id,this._handleSort)):this.stop()},Ei.prototype._prepareScroll=function(){if(this._isActive){var t=this._item;if(t._isActive){var e=t._element,i=this._getGrid(),n=i._element,r=i._settings.dragAxis,s="y"!==r,o="x"!==r,a=e.getBoundingClientRect();if(this._container!==n){var l=ai(this._containingBlock,n);this._containerDiffX=l.left,this._containerDiffY=l.top}if(s){var h=this._clientX-this._moveDiffX-this._scrollDiffX-a.left;this._left=this._left-this._scrollDiffX+h,this._scrollDiffX=h}if(o){var u=this._clientY-this._moveDiffY-this._scrollDiffY-a.top;this._top=this._top-this._scrollDiffY+u,this._scrollDiffY=u}this._gridX=this._left-this._containerDiffX,this._gridY=this._top-this._containerDiffY}}},Ei.prototype._applyScroll=function(){if(this._isActive){var t=this._item;t._isActive&&(this._scrollDiffX=this._scrollDiffY=0,t._setTranslate(this._left,this._top),this._getGrid()._emit("dragScroll",t,this._scrollEvent))}},Ei.prototype._onEnd=function(t){var e=this._item,i=e._element,n=this._getGrid(),r=n._settings,s=e._dragRelease;e._isActive?(se(e._id),oe(e._id),ae(e._id),this._finishSort(),this._unbindScrollListeners(),s._containerDiffX=this._containerDiffX,s._containerDiffY=this._containerDiffY,this._reset(),gi(i,r.itemDraggingClass),Ei.autoScroller.removeItem(e),n._emit("dragEnd",e,t),this._isMigrating?this._finishMigration():s.start()):this.stop()};var Di=/^(webkit|moz|ms|o|Webkit|Moz|MS|O)(?=[A-Z])/,Ai={};function ki(t){var e=Ai[t];return e||((e=t.replace(Di,""))!==t&&(e=e[0].toLowerCase()+e.slice(1)),Ai[t]=e,e)}function Ri(t,e){for(var i in e)t.style[i]=e[i]}var Pi,Oi,Li=!(!Element||!ce(Element.prototype.animate)),Ci=!!(Element&&(Pi=Element.prototype.animate,Oi=window.Symbol,Pi&&ce(Oi)&&ce(Oi.toString)&&Oi(Pi).toString().indexOf("[native code]")>-1));function Mi(t){this._element=t,this._animation=null,this._duration=0,this._easing="",this._callback=null,this._props=[],this._values=[],this._isDestroyed=!1,this._onFinish=this._onFinish.bind(this)}function Ii(t,e){var i={};for(var n in t)i[e?n:ki(n)]=t[n];return i}function Ni(t,e){return"translateX("+t+"px) translateY("+e+"px)"}function qi(t){this._item=t,this._animation=new Mi,this._element=null,this._className="",this._didMigrate=!1,this._resetAfterLayout=!1,this._left=0,this._top=0,this._transX=0,this._transY=0,this._nextTransX=0,this._nextTransY=0,this._setupAnimation=this._setupAnimation.bind(this),this._startAnimation=this._startAnimation.bind(this),this._updateDimensions=this._updateDimensions.bind(this),this._onLayoutStart=this._onLayoutStart.bind(this),this._onLayoutEnd=this._onLayoutEnd.bind(this),this._onReleaseEnd=this._onReleaseEnd.bind(this),this._onMigrate=this._onMigrate.bind(this),this._onHide=this._onHide.bind(this)}function ji(t){this._item=t,this._isActive=!1,this._isDestroyed=!1,this._isPositioningStarted=!1,this._containerDiffX=0,this._containerDiffY=0}Mi.prototype.start=function(t,e,i){if(!this._isDestroyed){var n=this._element,r=i||{};if(!Li)return Ri(n,e),this._callback=ce(r.onFinish)?r.onFinish:null,void this._onFinish();var s,o,a,l=this._animation,h=this._props,u=this._values,c=r.duration||300,d=r.easing||"ease",f=!1;if(l&&(o=0,c===this._duration&&d===this._easing||(f=!0),!f)){for(s in e)if(++o,-1===(a=h.indexOf(s))||e[s]!==u[a]){f=!0;break}o!==h.length&&(f=!0)}if(f&&l.cancel(),this._callback=ce(r.onFinish)?r.onFinish:null,!l||f){for(s in h.length=u.length=0,e)h.push(s),u.push(e[s]);this._duration=c,this._easing=d,this._animation=n.animate([Ii(t,Ci),Ii(e,Ci)],{duration:c,easing:d}),this._animation.onfinish=this._onFinish,Ri(n,e)}}},Mi.prototype.stop=function(){!this._isDestroyed&&this._animation&&(this._animation.cancel(),this._animation=this._callback=null,this._props.length=this._values.length=0)},Mi.prototype.getCurrentStyles=function(){return Ti(element,currentProps)},Mi.prototype.isAnimating=function(){return!!this._animation},Mi.prototype.destroy=function(){this._isDestroyed||(this.stop(),this._element=null,this._isDestroyed=!0)},Mi.prototype._onFinish=function(){var t=this._callback;this._animation=this._callback=null,this._props.length=this._values.length=0,t&&t()},qi.prototype._updateDimensions=function(){this.isActive()&&Ri(this._element,{width:this._item._width+"px",height:this._item._height+"px"})},qi.prototype._onLayoutStart=function(t,e){var i=this._item;if(-1!==t.indexOf(i)){var n=i._left,r=i._top,s=this._left,o=this._top;if(this._left=n,this._top=r,e||this._didMigrate||s!==n||o!==r){var a,l,h,u=n+i._marginLeft,c=r+i._marginTop,d=i.getGrid();if(!(!e&&d._settings.layoutDuration>0)||this._didMigrate)return he(i._id),this._element.style[Ve]=Ni(u,c),this._animation.stop(),void(this._didMigrate&&(d.getElement().appendChild(this._element),this._didMigrate=!1));this._nextTransX=u,this._nextTransY=c,a=i._id,l=this._setupAnimation,h=this._startAnimation,ie.add(0,Jt+a,l),ie.add(2,Kt+a,h)}}else this.reset()},qi.prototype._setupAnimation=function(){if(this.isActive()){var t=mi(this._element);this._transX=t.x,this._transY=t.y}},qi.prototype._startAnimation=function(){if(this.isActive()){var t=this._animation,e=this._transX,i=this._transY,n=this._nextTransX,r=this._nextTransY;if(e!==n||i!==r){var s=this._item.getGrid()._settings,o={},a={};o[Ve]=Ni(e,i),a[Ve]=Ni(n,r),t.start(o,a,{duration:s.layoutDuration,easing:s.layoutEasing,onFinish:this._onLayoutEnd})}else t.isAnimating()&&(this._element.style[Ve]=Ni(n,r),t.stop())}},qi.prototype._onLayoutEnd=function(){this._resetAfterLayout&&this.reset()},qi.prototype._onReleaseEnd=function(t){if(t._id===this._item._id){if(!this._animation.isAnimating())return void this.reset();this._resetAfterLayout=!0}},qi.prototype._onMigrate=function(t){if(t.item===this._item){var e=this._item.getGrid(),i=t.toGrid;e.off(mt,this._onReleaseEnd),e.off(rt,this._onLayoutStart),e.off(ft,this._onMigrate),e.off(lt,this._onHide),i.on(mt,this._onReleaseEnd),i.on(rt,this._onLayoutStart),i.on(ft,this._onMigrate),i.on(lt,this._onHide),this._didMigrate=!0}},qi.prototype._onHide=function(t){t.indexOf(this._item)>-1&&this.reset()},qi.prototype.create=function(){if(this.isActive())this._resetAfterLayout=!1;else{var t,e=this._item,i=e.getGrid(),n=i._settings,r=this._animation;this._left=e._left,this._top=e._top,t=ce(n.dragPlaceholder.createElement)?n.dragPlaceholder.createElement(e):document.createElement("div"),this._element=t,r._element=t,this._className=n.itemPlaceholderClass||"",this._className&&Be(t,this._className),Ri(t,{position:"absolute",left:"0px",top:"0px",width:e._width+"px",height:e._height+"px"}),t.style[Ve]=Ni(e._left+e._marginLeft,e._top+e._marginTop),i.on(rt,this._onLayoutStart),i.on(mt,this._onReleaseEnd),i.on(ft,this._onMigrate),i.on(lt,this._onHide),ce(n.dragPlaceholder.onCreate)&&n.dragPlaceholder.onCreate(e,t),i.getElement().appendChild(t)}},qi.prototype.reset=function(){if(this.isActive()){var t,e=this._element,i=this._item,n=i.getGrid(),r=n._settings,s=this._animation;this._resetAfterLayout=!1,he(i._id),t=i._id,ie.remove(2,Qt+t),s.stop(),s._element=null,n.off(mt,this._onReleaseEnd),n.off(rt,this._onLayoutStart),n.off(ft,this._onMigrate),n.off(lt,this._onHide),this._className&&(gi(e,this._className),this._className=""),e.parentNode.removeChild(e),this._element=null,ce(r.dragPlaceholder.onRemove)&&r.dragPlaceholder.onRemove(i,e)}},qi.prototype.isActive=function(){return!!this._element},qi.prototype.getElement=function(){return this._element},qi.prototype.updateDimensions=function(){var t,e;this.isActive()&&(t=this._item._id,e=this._updateDimensions,ie.add(2,Qt+t,e))},qi.prototype.destroy=function(){this.reset(),this._animation.destroy(),this._item=this._animation=null},ji.prototype.start=function(){if(!this._isDestroyed&&!this._isActive){var t=this._item,e=t.getGrid(),i=e._settings;this._isActive=!0,Be(t._element,i.itemReleasingClass),i.dragRelease.useDragContainer||this._placeToGrid(),e._emit("dragReleaseStart",t),e._nextLayoutData||t._layout.start(!1)}},ji.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n=this._item,r=n.getGrid();t||void 0!==e&&void 0!==i||(e=n._left,i=n._top);var s=this._placeToGrid(e,i);this._reset(s),t||r._emit(mt,n)}},ji.prototype.isJustReleased=function(){return this._isActive&&!1===this._isPositioningStarted},ji.prototype.destroy=function(){this._isDestroyed||(this.stop(!0),this._item=null,this._isDestroyed=!0)},ji.prototype._placeToGrid=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=i.getGrid()._element,s=!1;if(n.parentNode!==r){if(void 0===t||void 0===e){var o=mi(n);t=o.x-this._containerDiffX,e=o.y-this._containerDiffY}r.appendChild(n),i._setTranslate(t,e),s=!0}return this._containerDiffX=0,this._containerDiffY=0,s}},ji.prototype._reset=function(t){if(!this._isDestroyed){var e=this._item,i=e.getGrid()._settings.itemReleasingClass;this._isActive=!1,this._isPositioningStarted=!1,this._containerDiffX=0,this._containerDiffY=0,i&&gi(e._element,i)}};function Xi(t){var e=t._element,i=e.style;this._item=t,this._isActive=!1,this._isDestroyed=!1,this._isInterrupted=!1,this._currentStyles={},this._targetStyles={},this._nextLeft=0,this._nextTop=0,this._offsetLeft=0,this._offsetTop=0,this._skipNextAnimation=!1,this._animOptions={onFinish:this._finish.bind(this),duration:0,easing:0},i.left="0px",i.top="0px",t._setTranslate(0,0),this._animation=new Mi(e),this._queue="layout-"+t._id,this._setupAnimation=this._setupAnimation.bind(this),this._startAnimation=this._startAnimation.bind(this)}function Fi(t){this._item=t,this._isActive=!1,this._isDestroyed=!1,this._container=!1,this._containerDiffX=0,this._containerDiffY=0}function Hi(t){var e=t._isActive,i=t._element,n=i.children[0],r=t.getGrid()._settings;if(!n)throw new Error("No valid child element found within item element.");this._item=t,this._isDestroyed=!1,this._isHidden=!e,this._isHiding=!1,this._isShowing=!1,this._childElement=n,this._currentStyleProps=[],this._animation=new Mi(n),this._queue="visibility-"+t._id,this._finishShow=this._finishShow.bind(this),this._finishHide=this._finishHide.bind(this),i.style.display=e?"":"none",Be(i,e?r.itemVisibleClass:r.itemHiddenClass),this.setStyles(e?r.visibleStyles:r.hiddenStyles)}Xi.prototype.start=function(t,e){if(!this._isDestroyed){var i,n,r,s=this._item,o=s._dragRelease,a=s.getGrid()._settings,l=this._isActive,h=o.isJustReleased(),u=h?a.dragRelease.duration:a.layoutDuration,c=h?a.dragRelease.easing:a.layoutEasing,d=!t&&!this._skipNextAnimation&&u>0;if(l&&(ne(s._id),s._emitter.burst(this._queue,!0,s)),h&&(o._isPositioningStarted=!0),ce(e)&&s._emitter.on(this._queue,e),this._skipNextAnimation=!1,!d)return this._updateOffsets(),s._setTranslate(this._nextLeft,this._nextTop),this._animation.stop(),void this._finish();this._animation.isAnimating()&&(this._animation._animation.onfinish=null),this._isActive=!0,this._animOptions.easing=c,this._animOptions.duration=u,this._isInterrupted=l,i=s._id,n=this._setupAnimation,r=this._startAnimation,ie.add(0,Xt+i,n),ie.add(2,Ft+i,r)}},Xi.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n=this._item;if(ne(n._id),this._animation.isAnimating()){if(void 0===e||void 0===i){var r=mi(n._element);e=r.x,i=r.y}n._setTranslate(e,i),this._animation.stop()}gi(n._element,n.getGrid()._settings.itemPositioningClass),this._isActive=!1,t&&n._emitter.burst(this._queue,!0,n)}},Xi.prototype.destroy=function(){if(!this._isDestroyed){var t=this._item._element.style;this.stop(!0,0,0),this._item._emitter.clear(this._queue),this._animation.destroy(),t[Ve]="",t.left="",t.top="",this._item=null,this._currentStyles=null,this._targetStyles=null,this._animOptions=null,this._isDestroyed=!0}},Xi.prototype._updateOffsets=function(){if(!this._isDestroyed){var t=this._item,e=t._migrate,i=t._dragRelease;this._offsetLeft=i._isActive?i._containerDiffX:e._isActive?e._containerDiffX:0,this._offsetTop=i._isActive?i._containerDiffY:e._isActive?e._containerDiffY:0,this._nextLeft=this._item._left+this._offsetLeft,this._nextTop=this._item._top+this._offsetTop}},Xi.prototype._finish=function(){if(!this._isDestroyed){var t=this._item,e=t._migrate,i=t._dragRelease;t._tX=this._nextLeft,t._tY=this._nextTop,this._isActive&&(this._isActive=!1,gi(t._element,t.getGrid()._settings.itemPositioningClass)),i._isActive&&i.stop(),e._isActive&&e.stop(),t._emitter.burst(this._queue,!1,t)}},Xi.prototype._setupAnimation=function(){var t=this._item;if(void 0===t._tX||void 0===t._tY){var e=mi(t._element);t._tX=e.x,t._tY=e.y}},Xi.prototype._startAnimation=function(){var t=this._item,e=t.getGrid()._settings,i=this._animOptions.duration<=0;this._updateOffsets();var n=Math.abs(t._left-(t._tX-this._offsetLeft)),r=Math.abs(t._top-(t._tY-this._offsetTop));if(i||n<2&&r<2)return(n||r||this._isInterrupted)&&t._setTranslate(this._nextLeft,this._nextTop),this._animation.stop(),void this._finish();this._isInterrupted||Be(t._element,e.itemPositioningClass),this._currentStyles[Ve]=Ni(t._tX,t._tY),this._targetStyles[Ve]=Ni(this._nextLeft,this._nextTop),t._tX=t._tY=void 0,this._animation.start(this._currentStyles,this._targetStyles,this._animOptions)},Fi.prototype.start=function(t,e,i){if(!this._isDestroyed){var n,r,s,o,a,l,h,u,c,d,f=this._item,p=f._element,_=f.isActive(),m=f.isVisible(),g=f.getGrid(),v=g._settings,y=t._settings,b=t._element,w=t._items,x=g._items.indexOf(f),S=i||document.body;if("number"==typeof e)n=$e(w,e,1);else{if(!(r=t.getItem(e)))return;n=w.indexOf(r)}(f.isPositioning()||this._isActive||f.isReleasing())&&(h=(l=mi(p)).x,u=l.y),f.isPositioning()&&f._layout.stop(!0,h,u),this._isActive&&(h-=this._containerDiffX,u-=this._containerDiffY,this.stop(!0,h,u)),f.isReleasing()&&(h-=f._dragRelease._containerDiffX,u-=f._dragRelease._containerDiffY,f._dragRelease.stop(!0,h,u)),f._visibility.stop(!0),f._drag&&f._drag.destroy(),g._hasListeners(ft)&&g._emit(ft,{item:f,fromGrid:g,fromIndex:x,toGrid:t,toIndex:n}),t._hasListeners(_t)&&t._emit(_t,{item:f,fromGrid:g,fromIndex:x,toGrid:t,toIndex:n}),v.itemClass!==y.itemClass&&(gi(p,v.itemClass),Be(p,y.itemClass)),(c=m?v.itemVisibleClass:v.itemHiddenClass)!==(d=m?y.itemVisibleClass:y.itemHiddenClass)&&(gi(p,c),Be(p,d)),g._items.splice(x,1),We(w,f,n),f._gridId=t._id,_?S!==(s=p.parentNode)&&(S.appendChild(p),o=ai(S,s,!0),l||(h=(l=mi(p)).x,u=l.y),f._setTranslate(h+o.left,u+o.top)):b.appendChild(p),f._visibility.setStyles(m?y.visibleStyles:y.hiddenStyles),_&&(a=ai(S,b,!0)),f._refreshDimensions(),f._sortData=null,f._drag=y.dragEnabled?new Ei(f):null,_?(this._isActive=!0,this._container=S,this._containerDiffX=a.left,this._containerDiffY=a.top):(this._isActive=!1,this._container=null,this._containerDiffX=0,this._containerDiffY=0),g._hasListeners(dt)&&g._emit(dt,{item:f,fromGrid:g,fromIndex:x,toGrid:t,toIndex:n}),t._hasListeners(pt)&&t._emit(pt,{item:f,fromGrid:g,fromIndex:x,toGrid:t,toIndex:n})}},Fi.prototype.stop=function(t,e,i){if(!this._isDestroyed&&this._isActive){var n,r=this._item,s=r._element,o=r.getGrid()._element;this._container!==o&&(void 0!==e&&void 0!==i||(t?(e=(n=mi(s)).x-this._containerDiffX,i=n.y-this._containerDiffY):(e=r._left,i=r._top)),o.appendChild(s),r._setTranslate(e,i)),this._isActive=!1,this._container=null,this._containerDiffX=0,this._containerDiffY=0}},Fi.prototype.destroy=function(){this._isDestroyed||(this.stop(!0),this._item=null,this._isDestroyed=!0)},Hi.prototype.show=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=ce(e)?e:null,s=i.getGrid()._settings;this._isShowing||this._isHidden?!this._isShowing||t?(this._isShowing||(i._emitter.burst(this._queue,!0,i),gi(n,s.itemHiddenClass),Be(n,s.itemVisibleClass),this._isHiding||(n.style.display="")),r&&i._emitter.on(this._queue,r),this._isShowing=!0,this._isHiding=this._isHidden=!1,this._startAnimation(!0,t,this._finishShow)):r&&i._emitter.on(this._queue,r):r&&r(!1,i)}},Hi.prototype.hide=function(t,e){if(!this._isDestroyed){var i=this._item,n=i._element,r=ce(e)?e:null,s=i.getGrid()._settings;this._isHiding||!this._isHidden?!this._isHiding||t?(this._isHiding||(i._emitter.burst(this._queue,!0,i),Be(n,s.itemHiddenClass),gi(n,s.itemVisibleClass)),r&&i._emitter.on(this._queue,r),this._isHidden=this._isHiding=!0,this._isShowing=!1,this._startAnimation(!1,t,this._finishHide)):r&&i._emitter.on(this._queue,r):r&&r(!1,i)}},Hi.prototype.stop=function(t){if(!this._isDestroyed&&(this._isHiding||this._isShowing)){var e=this._item;re(e._id),this._animation.stop(),t&&e._emitter.burst(this._queue,!0,e)}},Hi.prototype.setStyles=function(t){var e=this._childElement,i=this._currentStyleProps;for(var n in this._removeCurrentStyles(),t)i.push(n),e.style[n]=t[n]},Hi.prototype.destroy=function(){if(!this._isDestroyed){var t=this._item,e=t._element,i=t.getGrid()._settings;this.stop(!0),t._emitter.clear(this._queue),this._animation.destroy(),this._removeCurrentStyles(),gi(e,i.itemVisibleClass),gi(e,i.itemHiddenClass),e.style.display="",this._isHiding=this._isShowing=!1,this._isDestroyed=this._isHidden=!0}},Hi.prototype._startAnimation=function(t,e,i){if(!this._isDestroyed){var n,r=this._item,s=this._animation,o=this._childElement,a=r.getGrid()._settings,l=t?a.visibleStyles:a.hiddenStyles,h=t?a.showDuration:a.hideDuration,u=t?a.showEasing:a.hideEasing,c=e||h<=0;if(l){if(re(r._id),c)return Ri(o,l),s.stop(),void(i&&i());var d,f,p;s.isAnimating()&&(s._animation.onfinish=null),d=r._id,f=function(){n=Ti(o,l)},p=function(){s.start(n,l,{duration:h,easing:u,onFinish:i})},ie.add(0,Ht+d,f),ie.add(2,Yt+d,p)}else i&&i()}},Hi.prototype._finishShow=function(){this._isHidden||(this._isShowing=!1,this._item._emitter.burst(this._queue,!1,this._item))},Hi.prototype._finishHide=function(){if(this._isHidden){var t=this._item;this._isHiding=!1,t._layout.stop(!0,0,0),t._element.style.display="none",t._emitter.burst(this._queue,!1,t)}},Hi.prototype._removeCurrentStyles=function(){for(var t=this._childElement,e=this._currentStyleProps,i=0;i<e.length;i++)t.style[e[i]]="";e.length=0};var Yi=0;function Bi(){return++Yi}function zi(t,e,i){var n=t._settings;if(et){if(et.has(e))throw new Error("You can only create one Muuri Item per element!");et.set(e,this)}this._id=Bi(),this._gridId=t._id,this._element=e,this._isDestroyed=!1,this._left=0,this._top=0,this._width=0,this._height=0,this._marginLeft=0,this._marginRight=0,this._marginTop=0,this._marginBottom=0,this._tX=void 0,this._tY=void 0,this._sortData=null,this._emitter=new bt,e.parentNode!==t._element&&t._element.appendChild(e),Be(e,n.itemClass),"boolean"!=typeof i&&(i="none"!==ge(e,"display")),this._isActive=i,this._visibility=new Hi(this),this._layout=new Xi(this),this._migrate=new Fi(this),this._drag=n.dragEnabled?new Ei(this):null,this._dragRelease=new ji(this),this._dragPlaceholder=new qi(this)}function Wi(t){var e,i,n,r,s,o=.001,a=.5;function l(t){return((1e3*t+.5<<0)/10<<0)/100}function h(){this.currentRects=[],this.nextRects=[],this.rectTarget={},this.rectStore=[],this.slotSizes=[],this.rectId=0,this.slotIndex=-1,this.slotData={left:0,top:0,width:0,height:0},this.sortRectsLeftTop=this.sortRectsLeftTop.bind(this),this.sortRectsTopLeft=this.sortRectsTopLeft.bind(this)}if(h.prototype.computeLayout=function(t,e){var i,n,r,s,o,a,h=t.items,u=t.slots,c=!!(1&e),d=!!(2&e),f=!!(4&e),p=!!(8&e),_=!!(16&e),m="number"==typeof h[0];if(!h.length)return t;for(n=m?2:1,i=0;i<h.length;i+=n)m?(s=h[i],o=h[i+1]):(s=(r=h[i])._width+r._marginLeft+r._marginRight,o=r._height+r._marginTop+r._marginBottom),_&&(s=l(s),o=l(o)),a=this.computeNextSlot(t,s,o,c,d),d?a.left+a.width>t.width&&(t.width=a.left+a.width):a.top+a.height>t.height&&(t.height=a.top+a.height),u[++this.slotIndex]=a.left,u[++this.slotIndex]=a.top,(f||p)&&this.slotSizes.push(a.width,a.height);if(f)for(i=0;i<u.length;i+=2)u[i]=t.width-(u[i]+this.slotSizes[i]);if(p)for(i=1;i<u.length;i+=2)u[i]=t.height-(u[i]+this.slotSizes[i]);return this.slotSizes.length=0,this.currentRects.length=0,this.nextRects.length=0,this.rectId=0,this.slotIndex=-1,t},h.prototype.computeNextSlot=function(t,e,i,n,r){var s,l,h,u,c,d=this.slotData,f=this.currentRects,p=this.nextRects,_=!1;for(p.length=0,d.left=null,d.top=null,d.width=e,d.height=i,u=0;u<f.length;u++)if((l=f[u])&&(s=this.getRect(l),d.width<=s.width+o&&d.height<=s.height+o)){d.left=s.left,d.top=s.top;break}if(null===d.left&&(r?(d.left=t.width,d.top=0):(d.left=0,d.top=t.height),n||(_=!0)),!r&&d.top+d.height>t.height+o&&(d.left>a&&p.push(this.addRect(0,t.height,d.left,1/0)),d.left+d.width<t.width-a&&p.push(this.addRect(d.left+d.width,t.height,t.width-d.left-d.width,1/0)),t.height=d.top+d.height),r&&d.left+d.width>t.width+o&&(d.top>a&&p.push(this.addRect(t.width,0,1/0,d.top)),d.top+d.height<t.height-a&&p.push(this.addRect(t.width,d.top+d.height,1/0,t.height-d.top-d.height)),t.width=d.left+d.width),!_)for(n&&(u=0);u<f.length;u++)if(l=f[u])for(s=this.getRect(l),h=this.splitRect(s,d),c=0;c<h.length;c++)l=h[c],s=this.getRect(l),(r?s.left+o<t.width-o:s.top+o<t.height-o)&&p.push(l);return p.length>1&&this.purgeRects(p).sort(r?this.sortRectsLeftTop:this.sortRectsTopLeft),this.currentRects=p,this.nextRects=f,d},h.prototype.addRect=function(t,e,i,n){var r=++this.rectId;return this.rectStore[r]=t||0,this.rectStore[++this.rectId]=e||0,this.rectStore[++this.rectId]=i||0,this.rectStore[++this.rectId]=n||0,r},h.prototype.getRect=function(t,e){return e||(e=this.rectTarget),e.left=this.rectStore[t]||0,e.top=this.rectStore[++t]||0,e.width=this.rectStore[++t]||0,e.height=this.rectStore[++t]||0,e},h.prototype.splitRect=(e=[],i=0,n=0,function(t,r){return e.length=0,t.left+t.width<=r.left+o||r.left+r.width<=t.left+o||t.top+t.height<=r.top+o||r.top+r.height<=t.top+o?(e.push(this.addRect(t.left,t.top,t.width,t.height)),e):((i=r.left-t.left)>=a&&e.push(this.addRect(t.left,t.top,i,t.height)),(i=t.left+t.width-(r.left+r.width))>=a&&e.push(this.addRect(r.left+r.width,t.top,i,t.height)),(n=r.top-t.top)>=a&&e.push(this.addRect(t.left,t.top,t.width,n)),(n=t.top+t.height-(r.top+r.height))>=a&&e.push(this.addRect(t.left,r.top+r.height,t.width,n)),e)}),h.prototype.isRectAWithinRectB=function(t,e){return t.left+o>=e.left&&t.top+o>=e.top&&t.left+t.width-o<=e.left+e.width&&t.top+t.height-o<=e.top+e.height},h.prototype.purgeRects=(r={},s={},function(t){for(var e,i=t.length;i--;)if(e=t.length,t[i])for(this.getRect(t[i],r);e--;)if(t[e]&&i!==e&&(this.getRect(t[e],s),this.isRectAWithinRectB(r,s))){t[i]=0;break}return t}),h.prototype.sortRectsTopLeft=function(){var t={},e={};return function(i,n){return this.getRect(i,t),this.getRect(n,e),t.top<e.top&&t.top+o<e.top?-1:t.top>e.top&&t.top-o>e.top?1:t.left<e.left&&t.left+o<e.left?-1:t.left>e.left&&t.left-o>e.left?1:0}}(),h.prototype.sortRectsLeftTop=function(){var t={},e={};return function(i,n){return this.getRect(i,t),this.getRect(n,e),t.left<e.left&&t.left+o<e.left?-1:t.left>e.left&&t.left-o<e.left?1:t.top<e.top&&t.top+o<e.top?-1:t.top>e.top&&t.top-o>e.top?1:0}}(),t){var u=new h;self.onmessage=function(t){var e=new Float32Array(t.data),i=e.subarray(4,e.length),n=new Float32Array(i.length),r=e[3],s={items:i,slots:n,width:e[1],height:e[2]};u.computeLayout(s,r),e[1]=s.width,e[2]=s.height,e.set(s.slots,4),postMessage(e.buffer,[e.buffer])}}return h}zi.prototype.getGrid=function(){return tt[this._gridId]},zi.prototype.getElement=function(){return this._element},zi.prototype.getWidth=function(){return this._width},zi.prototype.getHeight=function(){return this._height},zi.prototype.getMargin=function(){return{left:this._marginLeft,right:this._marginRight,top:this._marginTop,bottom:this._marginBottom}},zi.prototype.getPosition=function(){return{left:this._left,top:this._top}},zi.prototype.isActive=function(){return this._isActive},zi.prototype.isVisible=function(){return!!this._visibility&&!this._visibility._isHidden},zi.prototype.isShowing=function(){return!(!this._visibility||!this._visibility._isShowing)},zi.prototype.isHiding=function(){return!(!this._visibility||!this._visibility._isHiding)},zi.prototype.isPositioning=function(){return!(!this._layout||!this._layout._isActive)},zi.prototype.isDragging=function(){return!(!this._drag||!this._drag._isActive)},zi.prototype.isReleasing=function(){return!(!this._dragRelease||!this._dragRelease._isActive)},zi.prototype.isDestroyed=function(){return this._isDestroyed},zi.prototype._refreshDimensions=function(t){if(!(this._isDestroyed||!0!==t&&this._visibility._isHidden)){var e=this._element,i=this._dragPlaceholder,n=e.getBoundingClientRect();this._width=n.width,this._height=n.height,this._marginLeft=Math.max(0,ve(e,"margin-left")),this._marginRight=Math.max(0,ve(e,"margin-right")),this._marginTop=Math.max(0,ve(e,"margin-top")),this._marginBottom=Math.max(0,ve(e,"margin-bottom")),i&&i.updateDimensions()}},zi.prototype._refreshSortData=function(){if(!this._isDestroyed){var t,e=this._sortData={},i=this.getGrid()._settings.sortData;for(t in i)e[t]=i[t](this,this._element)}},zi.prototype._addToLayout=function(t,e){!0!==this._isActive&&(this._isActive=!0,this._left=t||0,this._top=e||0)},zi.prototype._removeFromLayout=function(){!1!==this._isActive&&(this._isActive=!1,this._left=0,this._top=0)},zi.prototype._canSkipLayout=function(t,e){return this._left===t&&this._top===e&&!this._migrate._isActive&&!this._layout._skipNextAnimation&&!this._dragRelease.isJustReleased()},zi.prototype._setTranslate=function(t,e){return(this._tX!==t||this._tY!==e)&&(this._tX=t,this._tY=e,this._element.style[Ve]=Ni(t,e),!0)},zi.prototype._destroy=function(t){if(!this._isDestroyed){var e=this._element,i=this.getGrid()._settings;this._dragPlaceholder.destroy(),this._dragRelease.destroy(),this._migrate.destroy(),this._layout.destroy(),this._visibility.destroy(),this._drag&&this._drag.destroy(),this._emitter.destroy(),gi(e,i.itemClass),t&&e.parentNode.removeChild(e),et&&et.delete(e),this._isActive=!1,this._isDestroyed=!0}};var $i=Wi(),Gi=null,Ui=[];function Vi(t,e){if(this._options=0,this._processor=null,this._layoutQueue=[],this._layouts={},this._layoutCallbacks={},this._layoutWorkers={},this._layoutWorkerData={},this._workers=[],this._onWorkerMessage=this._onWorkerMessage.bind(this),this.setOptions(e),(t="number"==typeof t?Math.max(0,t):0)&&window.Worker&&window.URL&&window.Blob)try{this._workers=function(t,e){var i=[];if(t>0){Gi||(Gi=URL.createObjectURL(new Blob(["("+Wi.toString()+")(true)"],{type:"application/javascript"})));for(var n,r=0;r<t;r++)n=new Worker(Gi),e&&(n.onmessage=e),i.push(n),Ui.push(n)}return i}(t,this._onWorkerMessage)}catch(t){this._processor=new $i}else this._processor=new $i}Vi.prototype._sendToWorker=function(){if(this._layoutQueue.length&&this._workers.length){var t=this._layoutQueue.shift(),e=this._workers.pop(),i=this._layoutWorkerData[t];delete this._layoutWorkerData[t],this._layoutWorkers[t]=e,e.postMessage(i.buffer,[i.buffer])}},Vi.prototype._onWorkerMessage=function(t){var e=new Float32Array(t.data),i=e[0],n=this._layouts[i],r=this._layoutCallbacks[i],s=this._layoutWorkers[i];n&&delete this._layoutCallbacks[i],r&&delete this._layoutCallbacks[i],s&&delete this._layoutWorkers[i],n&&r&&(n.width=e[1],n.height=e[2],n.slots=e.subarray(4,e.length),this._finalizeLayout(n),r(n)),s&&(this._workers.push(s),this._sendToWorker())},Vi.prototype._finalizeLayout=function(t){var e=t._grid,i=2&t._settings,n="border-box"===e._boxSizing;return delete t._grid,delete t._settings,t.styles={},i?t.styles.width=(n?t.width+e._borderLeft+e._borderRight:t.width)+"px":t.styles.height=(n?t.height+e._borderTop+e._borderBottom:t.height)+"px",t},Vi.prototype.setOptions=function(t){var e,i,n,r,s;t&&(e="boolean"==typeof t.fillGaps?t.fillGaps?1:0:1&this._options,i="boolean"==typeof t.horizontal?t.horizontal?2:0:2&this._options,n="boolean"==typeof t.alignRight?t.alignRight?4:0:4&this._options,r="boolean"==typeof t.alignBottom?t.alignBottom?8:0:8&this._options,s="boolean"==typeof t.rounding?t.rounding?16:0:16&this._options,this._options=e|i|n|r|s)},Vi.prototype.createLayout=function(t,e,i,n,r,s){if(this._layouts[e])throw new Error("A layout with the provided id is currently being processed.");var o=2&this._options,a={id:e,items:i,slots:null,width:o?0:n,height:o?r:0,_grid:t,_settings:this._options};if(!i.length)return a.slots=[],this._finalizeLayout(a),void s(a);if(this._processor)return a.slots=window.Float32Array?new Float32Array(2*i.length):new Array(2*i.length),this._processor.computeLayout(a,a._settings),this._finalizeLayout(a),void s(a);var l,h,u,c=new Float32Array(4+2*i.length);for(c[0]=e,c[1]=a.width,c[2]=a.height,c[3]=a._settings,l=0,h=3;l<i.length;l++)u=i[l],c[++h]=u._width+u._marginLeft+u._marginRight,c[++h]=u._height+u._marginTop+u._marginBottom;return this._layoutQueue.push(e),this._layouts[e]=a,this._layoutCallbacks[e]=s,this._layoutWorkerData[e]=c,this._sendToWorker(),this.cancelLayout.bind(this,e)},Vi.prototype.cancelLayout=function(t){if(this._layouts[t]&&(delete this._layouts[t],delete this._layoutCallbacks[t],this._layoutWorkerData[t])){delete this._layoutWorkerData[t];var e=this._layoutQueue.indexOf(t);e>-1&&this._layoutQueue.splice(e,1)}},Vi.prototype.destroy=function(){for(var t in this._layoutWorkers)this._workers.push(this._layoutWorkers[t]);!function(t){for(var e,i,n=0;n<t.length;n++)(e=t[n]).onmessage=null,e.onerror=null,e.onmessageerror=null,e.terminate(),(i=Ui.indexOf(e))>-1&&Ui.splice(i,1);Gi&&!Ui.length&&(URL.revokeObjectURL(Gi),Gi=null)}(this._workers),this._workers.length=0,this._layoutQueue.length=0,this._layouts={},this._layoutCallbacks={},this._layoutWorkers={},this._layoutWorkerData={}};var Ji=0;function Ki(t,e){var i=++Ji,n=0,r=0,s=!1,o=function(e){s||(r&&(n-=e-r),r=e,n>0?function(t,e){ie.add(0,ee+t,e)}(i,o):(n=r=0,t()))};return function(a){if(!s){if(!(e<=0))return!0===a?(s=!0,n=r=0,o=void 0,void function(t){ie.remove(0,ee+t)}(i)):void(n<=0?(n=e,o(0)):n=e);!0!==a&&t()}}}function Qi(t){var e=Object.prototype.toString.call(t);return"[object HTMLCollection]"===e||"[object NodeList]"===e}var Zi=Object.prototype.toString;function tn(t){return"object"==typeof t&&"[object Object]"===Zi.call(t)}function en(){}var nn,rn,sn,on="number",an="string",ln="instant",hn=0;function un(t,e){if(typeof t===an&&(t=document.querySelector(t)),!(t.getRootNode?t.getRootNode({composed:!0})===document:document.body.contains(t))||t===document.documentElement)throw new Error("Container element must be an existing DOM element.");var i=function(t,e){var i=cn({},t);e&&(i=cn(i,e));e&&e.visibleStyles?i.visibleStyles=e.visibleStyles:t&&t.visibleStyles&&(i.visibleStyles=t.visibleStyles);e&&e.hiddenStyles?i.hiddenStyles=e.hiddenStyles:t&&t.hiddenStyles&&(i.hiddenStyles=t.hiddenStyles);return i}(un.defaultOptions,e);i.visibleStyles=dn(i.visibleStyles),i.hiddenStyles=dn(i.hiddenStyles),ce(i.dragSort)||(i.dragSort=!!i.dragSort),this._id=Bi(),this._element=t,this._settings=i,this._isDestroyed=!1,this._items=[],this._layout={id:0,items:[],slots:[]},this._isLayoutFinished=!0,this._nextLayoutData=null,this._emitter=new bt,this._onLayoutDataReceived=this._onLayoutDataReceived.bind(this),tt[this._id]=this,Be(t,i.containerClass),function(t,e){typeof e!==on&&(e=!0===e?0:-1);e>=0&&(t._resizeHandler=Ki((function(){t.refreshItems().layout()}),e),window.addEventListener("resize",t._resizeHandler))}(this,i.layoutOnResize),this.add(function(t,e){if("*"===e)return t.children;if(typeof e===an){for(var i=[],n=t.children,r=0;r<n.length;r++)Ye(n[r],e)&&i.push(n[r]);return i}if(Array.isArray(e)||Qi(e))return e;return[]}(t,i.items),{layout:!1}),i.layoutOnInit&&this.layout(!0)}function cn(t,e){var i,n,r,s=Object.keys(e),o=s.length;for(r=0;r<o;r++)i=tn(e[n=s[r]]),tn(t[n])&&i?t[n]=cn(cn({},t[n]),e[n]):i?t[n]=cn({},e[n]):Array.isArray(e[n])?t[n]=e[n].slice(0):t[n]=e[n];return t}function dn(t){var e,i,n={},r=document.documentElement.style;for(e in t)t[e]&&(i=Tt(r,e))&&(n[i]=t[e]);return n}function fn(t){for(var e={},i=0;i<t.length;i++)e[t[i]._id]=i;return e}function pn(t,e,i){return t[e._id]-t[i._id]}un.Item=zi,un.ItemLayout=Xi,un.ItemVisibility=Hi,un.ItemMigrate=Fi,un.ItemDrag=Ei,un.ItemDragRelease=ji,un.ItemDragPlaceholder=qi,un.Emitter=bt,un.Animator=Mi,un.Dragger=It,un.Packer=Vi,un.AutoScroller=Xe,un.defaultPacker=new Vi(2),un.defaultOptions={items:"*",showDuration:300,showEasing:"ease",hideDuration:300,hideEasing:"ease",visibleStyles:{opacity:"1",transform:"scale(1)"},hiddenStyles:{opacity:"0",transform:"scale(0.5)"},layout:{fillGaps:!1,horizontal:!1,alignRight:!1,alignBottom:!1,rounding:!1},layoutOnResize:150,layoutOnInit:!0,layoutDuration:300,layoutEasing:"ease",sortData:null,dragEnabled:!1,dragContainer:null,dragHandle:null,dragStartPredicate:{distance:0,delay:0},dragAxis:"xy",dragSort:!0,dragSortHeuristics:{sortInterval:100,minDragDistance:10,minBounceBackAngle:1},dragSortPredicate:{threshold:50,action:nt,migrateAction:nt},dragRelease:{duration:300,easing:"ease",useDragContainer:!0},dragCssProps:{touchAction:"none",userSelect:"none",userDrag:"none",tapHighlightColor:"rgba(0, 0, 0, 0)",touchCallout:"none",contentZooming:"none"},dragPlaceholder:{enabled:!1,createElement:null,onCreate:null,onRemove:null},dragAutoScroll:{targets:[],handle:null,threshold:50,safeZone:.2,speed:Xe.smoothSpeed(1e3,2e3,2500),sortDuringScroll:!0,smoothStop:!1,onStart:null,onStop:null},containerClass:"muuri",itemClass:"muuri-item",itemVisibleClass:"muuri-item-shown",itemHiddenClass:"muuri-item-hidden",itemPositioningClass:"muuri-item-positioning",itemDraggingClass:"muuri-item-dragging",itemReleasingClass:"muuri-item-releasing",itemPlaceholderClass:"muuri-item-placeholder"},un.prototype.on=function(t,e){return this._emitter.on(t,e),this},un.prototype.off=function(t,e){return this._emitter.off(t,e),this},un.prototype.getElement=function(){return this._element},un.prototype.getItem=function(t){if(this._isDestroyed||!t&&0!==t)return null;if(typeof t===on)return this._items[t>-1?t:this._items.length+t]||null;if(t instanceof zi)return t._gridId===this._id?t:null;if(et){var e=et.get(t);return e&&e._gridId===this._id?e:null}for(var i=0;i<this._items.length;i++)if(this._items[i]._element===t)return this._items[i];return null},un.prototype.getItems=function(t){if(this._isDestroyed||void 0===t)return this._items.slice(0);var e,i,n=[];if(Array.isArray(t)||Qi(t))for(e=0;e<t.length;e++)(i=this.getItem(t[e]))&&n.push(i);else(i=this.getItem(t))&&n.push(i);return n},un.prototype.refreshItems=function(t,e){if(this._isDestroyed)return this;var i,n,r,s,o=t||this._items;if(!0===e)for(s=[],i=0;i<o.length;i++)(n=o[i]).isVisible()||n.isHiding()||((r=n.getElement().style).visibility="hidden",r.display="",s.push(r));for(i=0;i<o.length;i++)o[i]._refreshDimensions(e);if(!0===e){for(i=0;i<s.length;i++)(r=s[i]).visibility="",r.display="none";s.length=0}return this},un.prototype.refreshSortData=function(t){if(this._isDestroyed)return this;for(var e=t||this._items,i=0;i<e.length;i++)e[i]._refreshSortData();return this},un.prototype.synchronize=function(){if(this._isDestroyed)return this;var t,e,i=this._items;if(!i.length)return this;for(var n=0;n<i.length;n++)(e=i[n]._element).parentNode===this._element&&(t=t||document.createDocumentFragment()).appendChild(e);return t?(this._element.appendChild(t),this._emit("synchronize"),this):this},un.prototype.layout=function(t,e){if(this._isDestroyed)return this;var i=this._nextLayoutData;i&&ce(i.cancel)&&i.cancel();var n=hn=hn%16777216+1;this._nextLayoutData={id:n,instant:t,onFinish:e,cancel:null};for(var r=this._items,s=[],o=0;o<r.length;o++)r[o]._isActive&&s.push(r[o]);this._refreshDimensions();var a,l=this._width-this._borderLeft-this._borderRight,h=this._height-this._borderTop-this._borderBottom,u=this._settings.layout;return ce(u)?a=u(this,n,s,l,h,this._onLayoutDataReceived):(un.defaultPacker.setOptions(u),a=un.defaultPacker.createLayout(this,n,s,l,h,this._onLayoutDataReceived)),ce(a)&&this._nextLayoutData&&this._nextLayoutData.id===n&&(this._nextLayoutData.cancel=a),this},un.prototype.add=function(t,e){if(this._isDestroyed||!t)return[];var i,n=Qi(i=t)?Array.prototype.slice.call(i):Array.prototype.concat(i);if(!n.length)return n;var r,s,o,a,l=e||{},h=l.layout?l.layout:void 0===l.layout,u=this._items,c=!1;for(a=0;a<n.length;a++)(s=n[a]).parentNode!==this._element&&(r=r||document.createDocumentFragment()).appendChild(s);for(r&&this._element.appendChild(r),a=0;a<n.length;a++)s=n[a],(o=n[a]=new zi(this,s,l.active))._isActive&&(c=!0,o._layout._skipNextAnimation=!0);for(a=0;a<n.length;a++)(o=n[a])._refreshDimensions(),o._refreshSortData();return We(u,n,l.index),this._hasListeners("add")&&this._emit("add",n.slice(0)),c&&h&&this.layout(h===ln,ce(h)?h:void 0),n},un.prototype.remove=function(t,e){if(this._isDestroyed||!t.length)return[];var i,n,r,s=e||{},o=s.layout?s.layout:void 0===s.layout,a=!1,l=this.getItems(),h=[],u=[];for(r=0;r<t.length;r++)(n=t[r])._isDestroyed||-1!==(i=this._items.indexOf(n))&&(n._isActive&&(a=!0),h.push(n),u.push(l.indexOf(n)),n._destroy(s.removeElements),this._items.splice(i,1));return this._hasListeners(at)&&this._emit(at,h.slice(0),u),a&&o&&this.layout(o===ln,ce(o)?o:void 0),h},un.prototype.show=function(t,e){return!this._isDestroyed&&t.length&&this._setItemsVisibility(t,!0,e),this},un.prototype.hide=function(t,e){return!this._isDestroyed&&t.length&&this._setItemsVisibility(t,!1,e),this},un.prototype.filter=function(t,e){if(this._isDestroyed||!this._items.length)return this;var i,n,r=[],s=[],o=typeof t===an,a=ce(t),l=e||{},h=!0===l.instant,u=l.syncWithLayout,c=l.layout?l.layout:void 0===l.layout,d=ce(l.onFinish)?l.onFinish:null,f=-1,p=en;if(d&&(p=function(){++f&&d(r.slice(0),s.slice(0))}),a||o)for(n=0;n<this._items.length;n++)i=this._items[n],(a?t(i):Ye(i._element,t))?r.push(i):s.push(i);return r.length?this.show(r,{instant:h,syncWithLayout:u,onFinish:p,layout:!1}):p(),s.length?this.hide(s,{instant:h,syncWithLayout:u,onFinish:p,layout:!1}):p(),(r.length||s.length)&&(this._hasListeners(ht)&&this._emit(ht,r.slice(0),s.slice(0)),c&&this.layout(c===ln,ce(c)?c:void 0)),this},un.prototype.sort=function(){var t,e,i,n;function r(r,s){for(var o,a,l,h,u=0,c=0;c<t.length;c++)if(o=t[c][0],a=t[c][1],l=(r._sortData?r:r._refreshSortData())._sortData[o],h=(s._sortData?s:s._refreshSortData())._sortData[o],u="desc"===a||!a&&e?h<l?-1:h>l?1:0:l<h?-1:l>h?1:0)return u;return u||(n||(n=fn(i)),u=e?pn(n,s,r):pn(n,r,s)),u}function s(r,s){var o=e?-t(r,s):t(r,s);return o||(n||(n=fn(i)),o=e?pn(n,s,r):pn(n,r,s)),o}return function(o,a){if(this._isDestroyed||this._items.length<2)return this;var l=this._items,h=a||{},u=h.layout?h.layout:void 0===h.layout;if(e=!!h.descending,i=l.slice(0),n=null,ce(o))t=o,l.sort(s);else if(typeof o===an)t=o.trim().split(" ").filter((function(t){return t})).map((function(t){return t.split(":")})),l.sort(r);else{if(!Array.isArray(o))throw t=e=i=n=null,new Error("Invalid comparer argument provided.");l.length=0,l.push.apply(l,o)}return this._hasListeners(ut)&&this._emit(ut,l.slice(0),i),u&&this.layout(u===ln,ce(u)?u:void 0),t=e=i=n=null,this}}(),un.prototype.move=function(t,e,i){if(this._isDestroyed||this._items.length<2)return this;var n,r,s=this._items,o=i||{},a=o.layout?o.layout:void 0===o.layout,l=o.action===it,h=l?it:nt,u=this.getItem(t),c=this.getItem(e);return u&&c&&u!==c&&(n=s.indexOf(u),r=s.indexOf(c),l?Ue(s,n,r):Ge(s,n,r),this._hasListeners(ct)&&this._emit(ct,{item:u,fromIndex:n,toIndex:r,action:h}),a&&this.layout(a===ln,ce(a)?a:void 0)),this},un.prototype.send=function(t,e,i,n){if(this._isDestroyed||e._isDestroyed||this===e)return this;if(!(t=this.getItem(t)))return this;var r=n||{},s=r.appendTo||document.body,o=r.layoutSender?r.layoutSender:void 0===r.layoutSender,a=r.layoutReceiver?r.layoutReceiver:void 0===r.layoutReceiver;return t._migrate.start(e,i,s),t._migrate._isActive&&t._isActive&&(o&&this.layout(o===ln,ce(o)?o:void 0),a&&e.layout(a===ln,ce(a)?a:void 0)),this},un.prototype.destroy=function(t){if(this._isDestroyed)return this;var e,i,n,r=this._element,s=this._items.slice(0),o=this._layout&&this._layout.styles||{};for((n=this)._resizeHandler&&(n._resizeHandler(!0),window.removeEventListener("resize",n._resizeHandler),n._resizeHandler=null),e=0;e<s.length;e++)s[e]._destroy(t);for(i in this._items.length=0,gi(r,this._settings.containerClass),o)r.style[i]="";return this._emit("destroy"),this._emitter.destroy(),delete tt[this._id],this._isDestroyed=!0,this},un.prototype._emit=function(){this._isDestroyed||this._emitter.emit.apply(this._emitter,arguments)},un.prototype._hasListeners=function(t){return!this._isDestroyed&&this._emitter.countListeners(t)>0},un.prototype._updateBoundingRect=function(){var t=this._element.getBoundingClientRect();this._width=t.width,this._height=t.height,this._left=t.left,this._top=t.top,this._right=t.right,this._bottom=t.bottom},un.prototype._updateBorders=function(t,e,i,n){var r=this._element;t&&(this._borderLeft=ve(r,"border-left-width")),e&&(this._borderRight=ve(r,"border-right-width")),i&&(this._borderTop=ve(r,"border-top-width")),n&&(this._borderBottom=ve(r,"border-bottom-width"))},un.prototype._refreshDimensions=function(){this._updateBoundingRect(),this._updateBorders(1,1,1,1),this._boxSizing=ge(this._element,"box-sizing")},un.prototype._onLayoutDataReceived=(nn=[],function(t){if(!this._isDestroyed&&this._nextLayoutData&&this._nextLayoutData.id===t.id){var e,i,n,r,s=this,o=this._nextLayoutData.instant,a=this._nextLayoutData.onFinish,l=t.items.length,h=l;for(this._nextLayoutData=null,!this._isLayoutFinished&&this._hasListeners(ot)&&this._emit(ot,this._layout.items.slice(0)),this._layout=t,nn.length=0,r=0;r<l;r++)(e=t.items[r])?(i=t.slots[2*r],n=t.slots[2*r+1],e._canSkipLayout(i,n)?--h:(e._left=i,e._top=n,e.isActive()&&!e.isDragging()?nn.push(e):--h)):--h;if(t.styles&&Ri(this._element,t.styles),!this._hasListeners(rt)||(this._emit(rt,t.items.slice(0),!0===o),this._layout.id===t.id)){var u=function(){if(!(--h>0)){var e=s._layout.id!==t.id,i=ce(o)?o:a;e||(s._isLayoutFinished=!0),ce(i)&&i(t.items.slice(0),e),!e&&s._hasListeners(st)&&s._emit(st,t.items.slice(0))}};if(!nn.length)return u(),this;for(this._isLayoutFinished=!1,r=0;r<nn.length&&this._layout.id===t.id;r++)nn[r]._layout.start(!0===o,u);return this._layout.id===t.id&&(nn.length=0),this}}}),un.prototype._setItemsVisibility=function(t,e,i){var n,r,s=this,o=t.slice(0),a=i||{},l=!0===a.instant,h=a.onFinish,u=a.layout?a.layout:void 0===a.layout,c=o.length,d=e?"showStart":lt,f=e?"showEnd":"hideEnd",p=e?"show":"hide",_=!1,m=[],g=[];if(c){for(r=0;r<o.length;r++)n=o[r],(e&&!n._isActive||!e&&n._isActive)&&(_=!0),n._layout._skipNextAnimation=!(!e||n._isActive),e&&n._visibility._isHidden&&g.push(n),e?n._addToLayout():n._removeFromLayout();g.length&&(this.refreshItems(g,!0),g.length=0),_&&!1!==a.syncWithLayout?this.on(rt,v):v(),_&&u&&this.layout(u===ln,ce(u)?u:void 0)}else ce(h)&&h(o);function v(){for(_&&!1!==a.syncWithLayout&&s.off(rt,v),s._hasListeners(d)&&s._emit(d,o.slice(0)),r=0;r<o.length;r++)o[r]._gridId===s._id?o[r]._visibility[p](l,(function(t,e){t||m.push(e),--c<1&&(ce(h)&&h(m.slice(0)),s._hasListeners(f)&&s._emit(f,m.slice(0)))})):--c<1&&(ce(h)&&h(m.slice(0)),s._hasListeners(f)&&s._emit(f,m.slice(0)))}},sn={},function(t,e){function i(){this._delay=0,this._endDelay=0,this._fill="none",this._iterationStart=0,this._iterations=1,this._duration=0,this._playbackRate=1,this._direction="normal",this._easing="linear",this._easingFunction=d}function n(){return t.isDeprecated("Invalid timing inputs","2016-03-02","TypeError exceptions will be thrown instead.",!0)}function r(e,n,r){var s=new i;return n&&(s.fill="both",s.duration="auto"),"number"!=typeof e||isNaN(e)?void 0!==e&&Object.getOwnPropertyNames(e).forEach((function(i){if("auto"!=e[i]){if(("number"==typeof s[i]||"duration"==i)&&("number"!=typeof e[i]||isNaN(e[i])))return;if("fill"==i&&-1==u.indexOf(e[i]))return;if("direction"==i&&-1==c.indexOf(e[i]))return;if("playbackRate"==i&&1!==e[i]&&t.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;s[i]=e[i]}})):s.duration=e,s}function s(t,e,i,n){return t<0||t>1||i<0||i>1?d:function(r){function s(t,e,i){return 3*t*(1-i)*(1-i)*i+3*e*(1-i)*i*i+i*i*i}if(r<=0){var o=0;return t>0?o=e/t:!e&&i>0&&(o=n/i),o*r}if(r>=1){var a=0;return i<1?a=(n-1)/(i-1):1==i&&t<1&&(a=(e-1)/(t-1)),1+a*(r-1)}for(var l=0,h=1;l<h;){var u=(l+h)/2,c=s(t,i,u);if(Math.abs(r-c)<1e-5)return s(e,n,u);c<r?l=u:h=u}return s(e,n,u)}}function o(t,e){return function(i){if(i>=1)return 1;var n=1/t;return(i+=e*n)-i%n}}function a(t){g||(g=document.createElement("div").style),g.animationTimingFunction="",g.animationTimingFunction=t;var e=g.animationTimingFunction;if(""==e&&n())throw new TypeError(t+" is not a valid value for easing");return e}function l(t){if("linear"==t)return d;var e=y.exec(t);if(e)return s.apply(this,e.slice(1).map(Number));var i=b.exec(t);if(i)return o(Number(i[1]),_);var n=w.exec(t);return n?o(Number(n[1]),{start:f,middle:p,end:_}[n[2]]):m[t]||d}function h(t,e,i){if(null==e)return x;var n=i.delay+t+i.endDelay;return e<Math.min(i.delay,n)?S:e>=Math.min(i.delay+t,n)?E:T}var u="backwards|forwards|both|none".split("|"),c="reverse|alternate|alternate-reverse".split("|"),d=function(t){return t};i.prototype={_setMember:function(e,i){this["_"+e]=i,this._effect&&(this._effect._timingInput[e]=i,this._effect._timing=t.normalizeTimingInput(this._effect._timingInput),this._effect.activeDuration=t.calculateActiveDuration(this._effect._timing),this._effect._animation&&this._effect._animation._rebuildUnderlyingAnimation())},get playbackRate(){return this._playbackRate},set delay(t){this._setMember("delay",t)},get delay(){return this._delay},set endDelay(t){this._setMember("endDelay",t)},get endDelay(){return this._endDelay},set fill(t){this._setMember("fill",t)},get fill(){return this._fill},set iterationStart(t){if((isNaN(t)||t<0)&&n())throw new TypeError("iterationStart must be a non-negative number, received: "+t);this._setMember("iterationStart",t)},get iterationStart(){return this._iterationStart},set duration(t){if("auto"!=t&&(isNaN(t)||t<0)&&n())throw new TypeError("duration must be non-negative or auto, received: "+t);this._setMember("duration",t)},get duration(){return this._duration},set direction(t){this._setMember("direction",t)},get direction(){return this._direction},set easing(t){this._easingFunction=l(a(t)),this._setMember("easing",t)},get easing(){return this._easing},set iterations(t){if((isNaN(t)||t<0)&&n())throw new TypeError("iterations must be non-negative, received: "+t);this._setMember("iterations",t)},get iterations(){return this._iterations}};var f=1,p=.5,_=0,m={ease:s(.25,.1,.25,1),"ease-in":s(.42,0,1,1),"ease-out":s(0,0,.58,1),"ease-in-out":s(.42,0,.58,1),"step-start":o(1,f),"step-middle":o(1,p),"step-end":o(1,_)},g=null,v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",y=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),b=/steps\(\s*(\d+)\s*\)/,w=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,x=0,S=1,E=2,T=3;t.cloneTimingInput=function(t){if("number"==typeof t)return t;var e={};for(var i in t)e[i]=t[i];return e},t.makeTiming=r,t.numericTimingToObject=function(t){return"number"==typeof t&&(t=isNaN(t)?{duration:0}:{duration:t}),t},t.normalizeTimingInput=function(e,i){return r(e=t.numericTimingToObject(e),i)},t.calculateActiveDuration=function(t){return Math.abs(function(t){return 0===t.duration||0===t.iterations?0:t.duration*t.iterations}(t)/t.playbackRate)},t.calculateIterationProgress=function(t,e,i){var n=h(t,e,i),r=function(t,e,i,n,r){switch(n){case S:return"backwards"==e||"both"==e?0:null;case T:return i-r;case E:return"forwards"==e||"both"==e?t:null;case x:return null}}(t,i.fill,e,n,i.delay);if(null===r)return null;var s=function(t,e,i,n,r){var s=r;return 0===t?e!==S&&(s+=i):s+=n/t,s}(i.duration,n,i.iterations,r,i.iterationStart),o=function(t,e,i,n,r,s){var o=t===1/0?e%1:t%1;return 0!==o||i!==E||0===n||0===r&&0!==s||(o=1),o}(s,i.iterationStart,n,i.iterations,r,i.duration),a=function(t,e,i,n){return t===E&&e===1/0?1/0:1===i?Math.floor(n)-1:Math.floor(n)}(n,i.iterations,o,s),l=function(t,e,i){var n=t;if("normal"!==t&&"reverse"!==t){var r=e;"alternate-reverse"===t&&(r+=1),n="normal",r!==1/0&&r%2!=0&&(n="reverse")}return"normal"===n?i:1-i}(i.direction,a,o);return i._easingFunction(l)},t.calculatePhase=h,t.normalizeEasing=a,t.parseEasingFunction=l}(rn={}),function(t,e){function i(t,e){return t in l&&l[t][e]||e}function n(t,e,n){if(!function(t){return"display"===t||0===t.lastIndexOf("animation",0)||0===t.lastIndexOf("transition",0)}(t)){var r=s[t];if(r)for(var a in o.style[t]=e,r){var l=r[a],h=o.style[l];n[l]=i(l,h)}else n[t]=i(t,e)}}function r(t){var e=[];for(var i in t)if(!(i in["easing","offset","composite"])){var n=t[i];Array.isArray(n)||(n=[n]);for(var r,s=n.length,o=0;o<s;o++)(r={}).offset="offset"in t?t.offset:1==s?1:o/(s-1),"easing"in t&&(r.easing=t.easing),"composite"in t&&(r.composite=t.composite),r[i]=n[o],e.push(r)}return e.sort((function(t,e){return t.offset-e.offset})),e}var s={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},o=document.createElementNS("http://www.w3.org/1999/xhtml","div"),a={thin:"1px",medium:"3px",thick:"5px"},l={borderBottomWidth:a,borderLeftWidth:a,borderRightWidth:a,borderTopWidth:a,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:a,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};t.convertToArrayForm=r,t.normalizeKeyframes=function(e){if(null==e)return[];window.Symbol&&Symbol.iterator&&Array.prototype.from&&e[Symbol.iterator]&&(e=Array.from(e)),Array.isArray(e)||(e=r(e));for(var i=e.map((function(e){var i={};for(var r in e){var s=e[r];if("offset"==r){if(null!=s){if(s=Number(s),!isFinite(s))throw new TypeError("Keyframe offsets must be numbers.");if(s<0||s>1)throw new TypeError("Keyframe offsets must be between 0 and 1.")}}else if("composite"==r){if("add"==s||"accumulate"==s)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};if("replace"!=s)throw new TypeError("Invalid composite mode "+s+".")}else s="easing"==r?t.normalizeEasing(s):""+s;n(r,s,i)}return null==i.offset&&(i.offset=null),null==i.easing&&(i.easing="linear"),i})),s=!0,o=-1/0,a=0;a<i.length;a++){var l=i[a].offset;if(null!=l){if(l<o)throw new TypeError("Keyframes are not loosely sorted by offset. Sort or specify offsets.");o=l}else s=!1}return i=i.filter((function(t){return t.offset>=0&&t.offset<=1})),s||function(){var t=i.length;null==i[t-1].offset&&(i[t-1].offset=1),t>1&&null==i[0].offset&&(i[0].offset=0);for(var e=0,n=i[0].offset,r=1;r<t;r++){var s=i[r].offset;if(null!=s){for(var o=1;o<r-e;o++)i[e+o].offset=n+(s-n)*o/(r-e);e=r,n=s}}}(),i}}(rn),function(t){var e={};t.isDeprecated=function(t,i,n,r){var s=r?"are":"is",o=new Date,a=new Date(i);return a.setMonth(a.getMonth()+3),!(o<a&&(t in e||console.warn("Web Animations: "+t+" "+s+" deprecated and will stop working on "+a.toDateString()+". "+n),e[t]=!0,1))},t.deprecated=function(e,i,n,r){var s=r?"are":"is";if(t.isDeprecated(e,i,n,r))throw new Error(e+" "+s+" no longer supported. "+n)}}(rn),function(){if(document.documentElement.animate){var t=document.documentElement.animate([],0),e=!0;if(t&&(e=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach((function(i){void 0===t[i]&&(e=!0)}))),!e)return}!function(t,e,i){e.convertEffectInput=function(i){var n=function(t){for(var e={},i=0;i<t.length;i++)for(var n in t[i])if("offset"!=n&&"easing"!=n&&"composite"!=n){var r={offset:t[i].offset,easing:t[i].easing,value:t[i][n]};e[n]=e[n]||[],e[n].push(r)}for(var s in e){var o=e[s];if(0!=o[0].offset||1!=o[o.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return e}(t.normalizeKeyframes(i)),r=function(i){var n=[];for(var r in i)for(var s=i[r],o=0;o<s.length-1;o++){var a=o,l=o+1,h=s[a].offset,u=s[l].offset,c=h,d=u;0==o&&(c=-1/0,0==u&&(l=a)),o==s.length-2&&(d=1/0,1==h&&(a=l)),n.push({applyFrom:c,applyTo:d,startOffset:s[a].offset,endOffset:s[l].offset,easingFunction:t.parseEasingFunction(s[a].easing),property:r,interpolation:e.propertyInterpolation(r,s[a].value,s[l].value)})}return n.sort((function(t,e){return t.startOffset-e.startOffset})),n}(n);return function(t,i){if(null!=i)r.filter((function(t){return i>=t.applyFrom&&i<t.applyTo})).forEach((function(n){var r=i-n.startOffset,s=n.endOffset-n.startOffset,o=0==s?0:n.easingFunction(r/s);e.apply(t,n.property,n.interpolation(o))}));else for(var s in n)"offset"!=s&&"easing"!=s&&"composite"!=s&&e.clear(t,s)}}}(rn,sn),function(t,e,i){function n(t){return t.replace(/-(.)/g,(function(t,e){return e.toUpperCase()}))}function r(t,e,i){s[i]=s[i]||[],s[i].push([t,e])}var s={};e.addPropertiesHandler=function(t,e,i){for(var s=0;s<i.length;s++)r(t,e,n(i[s]))};var o={backgroundColor:"transparent",backgroundPosition:"0% 0%",borderBottomColor:"currentColor",borderBottomLeftRadius:"0px",borderBottomRightRadius:"0px",borderBottomWidth:"3px",borderLeftColor:"currentColor",borderLeftWidth:"3px",borderRightColor:"currentColor",borderRightWidth:"3px",borderSpacing:"2px",borderTopColor:"currentColor",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderTopWidth:"3px",bottom:"auto",clip:"rect(0px, 0px, 0px, 0px)",color:"black",fontSize:"100%",fontWeight:"400",height:"auto",left:"auto",letterSpacing:"normal",lineHeight:"120%",marginBottom:"0px",marginLeft:"0px",marginRight:"0px",marginTop:"0px",maxHeight:"none",maxWidth:"none",minHeight:"0px",minWidth:"0px",opacity:"1.0",outlineColor:"invert",outlineOffset:"0px",outlineWidth:"3px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",paddingTop:"0px",right:"auto",strokeDasharray:"none",strokeDashoffset:"0px",textIndent:"0px",textShadow:"0px 0px 0px transparent",top:"auto",transform:"",verticalAlign:"0px",visibility:"visible",width:"auto",wordSpacing:"normal",zIndex:"auto"};e.propertyInterpolation=function(i,r,a){var l=i;/-/.test(i)&&!t.isDeprecated("Hyphenated property names","2016-03-22","Use camelCase instead.",!0)&&(l=n(i)),"initial"!=r&&"initial"!=a||("initial"==r&&(r=o[l]),"initial"==a&&(a=o[l]));for(var h=r==a?[]:s[l],u=0;h&&u<h.length;u++){var c=h[u][0](r),d=h[u][0](a);if(void 0!==c&&void 0!==d){var f=h[u][1](c,d);if(f){var p=e.Interpolation.apply(null,f);return function(t){return 0==t?r:1==t?a:p(t)}}}}return e.Interpolation(!1,!0,(function(t){return t?a:r}))}}(rn,sn),function(t,e,i){e.KeyframeEffect=function(i,n,r,s){var o,a=function(e){var i=t.calculateActiveDuration(e),n=function(n){return t.calculateIterationProgress(i,n,e)};return n._totalDuration=e.delay+i+e.endDelay,n}(t.normalizeTimingInput(r)),l=e.convertEffectInput(n),h=function(){l(i,o)};return h._update=function(t){return null!==(o=a(t))},h._clear=function(){l(i,null)},h._hasSameTarget=function(t){return i===t},h._target=i,h._totalDuration=a._totalDuration,h._id=s,h}}(rn,sn),function(t,e){function i(t,e,i){i.enumerable=!0,i.configurable=!0,Object.defineProperty(t,e,i)}function n(t){this._element=t,this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=t.style,this._length=0,this._isAnimatedProperty={},this._updateSvgTransformAttr=function(t,e){return!(!e.namespaceURI||-1==e.namespaceURI.indexOf("/svg"))&&(s in t||(t[s]=/Trident|MSIE|IEMobile|Edge|Android 4/i.test(t.navigator.userAgent)),t[s])}(window,t),this._savedTransformAttr=null;for(var e=0;e<this._style.length;e++){var i=this._style[e];this._surrogateStyle[i]=this._style[i]}this._updateIndices()}function r(t){if(!t._webAnimationsPatchedStyle){var e=new n(t);try{i(t,"style",{get:function(){return e}})}catch(e){t.style._set=function(e,i){t.style[e]=i},t.style._clear=function(e){t.style[e]=""}}t._webAnimationsPatchedStyle=t.style}}var s="_webAnimationsUpdateSvgTransformAttr",o={cssText:1,length:1,parentRule:1},a={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},l={removeProperty:1,setProperty:1};for(var h in n.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(t){for(var e={},i=0;i<this._surrogateStyle.length;i++)e[this._surrogateStyle[i]]=!0;for(this._surrogateStyle.cssText=t,this._updateIndices(),i=0;i<this._surrogateStyle.length;i++)e[this._surrogateStyle[i]]=!0;for(var n in e)this._isAnimatedProperty[n]||this._style.setProperty(n,this._surrogateStyle.getPropertyValue(n))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(t){return function(){return this._surrogateStyle[t]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(e,i){this._style[e]=i,this._isAnimatedProperty[e]=!0,this._updateSvgTransformAttr&&"transform"==t.unprefixedPropertyName(e)&&(null==this._savedTransformAttr&&(this._savedTransformAttr=this._element.getAttribute("transform")),this._element.setAttribute("transform",t.transformToSvgMatrix(i)))},_clear:function(e){this._style[e]=this._surrogateStyle[e],this._updateSvgTransformAttr&&"transform"==t.unprefixedPropertyName(e)&&(this._savedTransformAttr?this._element.setAttribute("transform",this._savedTransformAttr):this._element.removeAttribute("transform"),this._savedTransformAttr=null),delete this._isAnimatedProperty[e]}},a)n.prototype[h]=function(t,e){return function(){var i=this._surrogateStyle[t].apply(this._surrogateStyle,arguments);return e&&(this._isAnimatedProperty[arguments[0]]||this._style[t].apply(this._style,arguments),this._updateIndices()),i}}(h,h in l);for(var u in document.documentElement.style)u in o||u in a||function(t){i(n.prototype,t,{get:function(){return this._surrogateStyle[t]},set:function(e){this._surrogateStyle[t]=e,this._updateIndices(),this._isAnimatedProperty[t]||(this._style[t]=e)}})}(u);t.apply=function(e,i,n){r(e),e.style._set(t.propertyName(i),n)},t.clear=function(e,i){e._webAnimationsPatchedStyle&&e.style._clear(t.propertyName(i))}}(sn),function(t){window.Element.prototype.animate=function(e,i){var n="";return i&&i.id&&(n=i.id),t.timeline._play(t.KeyframeEffect(this,e,i,n))}}(sn),function(t,e){function i(t,e,n){if("number"==typeof t&&"number"==typeof e)return t*(1-n)+e*n;if("boolean"==typeof t&&"boolean"==typeof e)return n<.5?t:e;if(t.length==e.length){for(var r=[],s=0;s<t.length;s++)r.push(i(t[s],e[s],n));return r}throw"Mismatched interpolation arguments "+t+":"+e}t.Interpolation=function(t,e,n){return function(r){return n(i(t,e,r))}}}(sn),function(t,e){var i=function(){function t(t,e){for(var i=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],n=0;n<4;n++)for(var r=0;r<4;r++)for(var s=0;s<4;s++)i[n][r]+=e[n][s]*t[s][r];return i}return function(e,i,n,r,s){for(var o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],a=0;a<4;a++)o[a][3]=s[a];for(a=0;a<3;a++)for(var l=0;l<3;l++)o[3][a]+=e[l]*o[l][a];var h=r[0],u=r[1],c=r[2],d=r[3],f=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];f[0][0]=1-2*(u*u+c*c),f[0][1]=2*(h*u-c*d),f[0][2]=2*(h*c+u*d),f[1][0]=2*(h*u+c*d),f[1][1]=1-2*(h*h+c*c),f[1][2]=2*(u*c-h*d),f[2][0]=2*(h*c-u*d),f[2][1]=2*(u*c+h*d),f[2][2]=1-2*(h*h+u*u),o=t(o,f);var p=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];for(n[2]&&(p[2][1]=n[2],o=t(o,p)),n[1]&&(p[2][1]=0,p[2][0]=n[0],o=t(o,p)),n[0]&&(p[2][0]=0,p[1][0]=n[0],o=t(o,p)),a=0;a<3;a++)for(l=0;l<3;l++)o[a][l]*=i[a];return function(t){return 0==t[0][2]&&0==t[0][3]&&0==t[1][2]&&0==t[1][3]&&0==t[2][0]&&0==t[2][1]&&1==t[2][2]&&0==t[2][3]&&0==t[3][2]&&1==t[3][3]}(o)?[o[0][0],o[0][1],o[1][0],o[1][1],o[3][0],o[3][1]]:o[0].concat(o[1],o[2],o[3])}}();t.composeMatrix=i,t.quat=function(e,i,n){var r=t.dot(e,i);r=function(t,e,i){return Math.max(Math.min(t,i),e)}(r,-1,1);var s=[];if(1===r)s=e;else for(var o=Math.acos(r),a=1*Math.sin(n*o)/Math.sqrt(1-r*r),l=0;l<4;l++)s.push(e[l]*(Math.cos(n*o)-r*a)+i[l]*a);return s}}(sn),function(t,e,i){t.sequenceNumber=0;var n=function(t,e,i){this.target=t,this.currentTime=e,this.timelineTime=i,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=t,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};e.Animation=function(e){this.id="",e&&e._id&&(this.id=e._id),this._sequenceNumber=t.sequenceNumber++,this._currentTime=0,this._startTime=null,this._paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!0,this.onfinish=null,this._finishHandlers=[],this._effect=e,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},e.Animation.prototype={_ensureAlive:function(){this.playbackRate<0&&0===this.currentTime?this._inEffect=this._effect._update(-1):this._inEffect=this._effect._update(this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,e.timeline._animations.push(this))},_tickCurrentTime:function(t,e){t!=this._currentTime&&(this._currentTime=t,this._isFinished&&!e&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(t){t=+t,isNaN(t)||(e.restart(),this._paused||null==this._startTime||(this._startTime=this._timeline.currentTime-t/this._playbackRate),this._currentTimePending=!1,this._currentTime!=t&&(this._idle&&(this._idle=!1,this._paused=!0),this._tickCurrentTime(t,!0),e.applyDirtiedAnimation(this)))},get startTime(){return this._startTime},set startTime(t){t=+t,isNaN(t)||this._paused||this._idle||(this._startTime=t,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),e.applyDirtiedAnimation(this))},get playbackRate(){return this._playbackRate},set playbackRate(t){if(t!=this._playbackRate){var i=this.currentTime;this._playbackRate=t,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&(this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),e.applyDirtiedAnimation(this)),null!=i&&(this.currentTime=i)}},get _isFinished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this._paused&&0!=this.playbackRate||this._currentTimePending?"pending":this._paused?"paused":this._isFinished?"finished":"running"},_rewind:function(){if(this._playbackRate>=0)this._currentTime=0;else{if(!(this._totalDuration<1/0))throw new DOMException("Unable to rewind negative playback rate animation with infinite duration","InvalidStateError");this._currentTime=this._totalDuration}},play:function(){this._paused=!1,(this._isFinished||this._idle)&&(this._rewind(),this._startTime=null),this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),e.applyDirtiedAnimation(this)},pause:function(){this._isFinished||this._paused||this._idle?this._idle&&(this._rewind(),this._idle=!1):this._currentTimePending=!0,this._startTime=null,this._paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1,e.applyDirtiedAnimation(this))},cancel:function(){this._inEffect&&(this._inEffect=!1,this._idle=!0,this._paused=!1,this._finishedFlag=!0,this._currentTime=0,this._startTime=null,this._effect._update(null),e.applyDirtiedAnimation(this))},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(t,e){"function"==typeof e&&"finish"==t&&this._finishHandlers.push(e)},removeEventListener:function(t,e){if("finish"==t){var i=this._finishHandlers.indexOf(e);i>=0&&this._finishHandlers.splice(i,1)}},_fireEvents:function(t){if(this._isFinished){if(!this._finishedFlag){var e=new n(this,this._currentTime,t),i=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout((function(){i.forEach((function(t){t.call(e.target,e)}))}),0),this._finishedFlag=!0}}else this._finishedFlag=!1},_tick:function(t,e){this._idle||this._paused||(null==this._startTime?e&&(this.startTime=t-this._currentTime/this.playbackRate):this._isFinished||this._tickCurrentTime((t-this._startTime)*this.playbackRate)),e&&(this._currentTimePending=!1,this._fireEvents(t))},get _needsTick(){return this.playState in{pending:1,running:1}||!this._finishedFlag},_targetAnimations:function(){var t=this._effect._target;return t._activeAnimations||(t._activeAnimations=[]),t._activeAnimations},_markTarget:function(){var t=this._targetAnimations();-1===t.indexOf(this)&&t.push(this)},_unmarkTarget:function(){var t=this._targetAnimations(),e=t.indexOf(this);-1!==e&&t.splice(e,1)}}}(rn,sn),function(t,e,i){function n(t){var e=h;h=[],t<_.currentTime&&(t=_.currentTime),_._animations.sort(r),_._animations=a(t,!0,_._animations)[0],e.forEach((function(e){e[1](t)})),o()}function r(t,e){return t._sequenceNumber-e._sequenceNumber}function s(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function o(){f.forEach((function(t){t()})),f.length=0}function a(t,i,n){p=!0,d=!1,e.timeline.currentTime=t,c=!1;var r=[],s=[],o=[],a=[];return n.forEach((function(e){e._tick(t,i),e._inEffect?(s.push(e._effect),e._markTarget()):(r.push(e._effect),e._unmarkTarget()),e._needsTick&&(c=!0);var n=e._inEffect||e._needsTick;e._inTimeline=n,n?o.push(e):a.push(e)})),f.push.apply(f,r),f.push.apply(f,s),c&&requestAnimationFrame((function(){})),p=!1,[o,a]}var l=window.requestAnimationFrame,h=[],u=0;window.requestAnimationFrame=function(t){var e=u++;return 0==h.length&&l(n),h.push([e,t]),e},window.cancelAnimationFrame=function(t){h.forEach((function(e){e[0]==t&&(e[1]=function(){})}))},s.prototype={_play:function(i){i._timing=t.normalizeTimingInput(i.timing);var n=new e.Animation(i);return n._idle=!1,n._timeline=this,this._animations.push(n),e.restart(),e.applyDirtiedAnimation(n),n}};var c=!1,d=!1;e.restart=function(){return c||(c=!0,requestAnimationFrame((function(){})),d=!0),d},e.applyDirtiedAnimation=function(t){if(!p){t._markTarget();var i=t._targetAnimations();i.sort(r),a(e.timeline.currentTime,!1,i.slice())[1].forEach((function(t){var e=_._animations.indexOf(t);-1!==e&&_._animations.splice(e,1)})),o()}};var f=[],p=!1,_=new s;e.timeline=_}(rn,sn),function(t,e){function i(t,e){for(var i=0,n=0;n<t.length;n++)i+=t[n]*e[n];return i}function n(t,e){return[t[0]*e[0]+t[4]*e[1]+t[8]*e[2]+t[12]*e[3],t[1]*e[0]+t[5]*e[1]+t[9]*e[2]+t[13]*e[3],t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]*e[3],t[3]*e[0]+t[7]*e[1]+t[11]*e[2]+t[15]*e[3],t[0]*e[4]+t[4]*e[5]+t[8]*e[6]+t[12]*e[7],t[1]*e[4]+t[5]*e[5]+t[9]*e[6]+t[13]*e[7],t[2]*e[4]+t[6]*e[5]+t[10]*e[6]+t[14]*e[7],t[3]*e[4]+t[7]*e[5]+t[11]*e[6]+t[15]*e[7],t[0]*e[8]+t[4]*e[9]+t[8]*e[10]+t[12]*e[11],t[1]*e[8]+t[5]*e[9]+t[9]*e[10]+t[13]*e[11],t[2]*e[8]+t[6]*e[9]+t[10]*e[10]+t[14]*e[11],t[3]*e[8]+t[7]*e[9]+t[11]*e[10]+t[15]*e[11],t[0]*e[12]+t[4]*e[13]+t[8]*e[14]+t[12]*e[15],t[1]*e[12]+t[5]*e[13]+t[9]*e[14]+t[13]*e[15],t[2]*e[12]+t[6]*e[13]+t[10]*e[14]+t[14]*e[15],t[3]*e[12]+t[7]*e[13]+t[11]*e[14]+t[15]*e[15]]}function r(t){var e=t.rad||0;return((t.deg||0)/360+(t.grad||0)/400+(t.turn||0))*(2*Math.PI)+e}function s(t){switch(t.t){case"rotatex":var e=r(t.d[0]);return[1,0,0,0,0,Math.cos(e),Math.sin(e),0,0,-Math.sin(e),Math.cos(e),0,0,0,0,1];case"rotatey":return e=r(t.d[0]),[Math.cos(e),0,-Math.sin(e),0,0,1,0,0,Math.sin(e),0,Math.cos(e),0,0,0,0,1];case"rotate":case"rotatez":return e=r(t.d[0]),[Math.cos(e),Math.sin(e),0,0,-Math.sin(e),Math.cos(e),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var i=t.d[0],n=t.d[1],s=t.d[2],o=(e=r(t.d[3]),i*i+n*n+s*s);if(0===o)i=1,n=0,s=0;else if(1!==o){var a=Math.sqrt(o);i/=a,n/=a,s/=a}var l=Math.sin(e/2),h=l*Math.cos(e/2),u=l*l;return[1-2*(n*n+s*s)*u,2*(i*n*u+s*h),2*(i*s*u-n*h),0,2*(i*n*u-s*h),1-2*(i*i+s*s)*u,2*(n*s*u+i*h),0,2*(i*s*u+n*h),2*(n*s*u-i*h),1-2*(i*i+n*n)*u,0,0,0,0,1];case"scale":return[t.d[0],0,0,0,0,t.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[t.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,t.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,t.d[0],0,0,0,0,1];case"scale3d":return[t.d[0],0,0,0,0,t.d[1],0,0,0,0,t.d[2],0,0,0,0,1];case"skew":var c=r(t.d[0]),d=r(t.d[1]);return[1,Math.tan(d),0,0,Math.tan(c),1,0,0,0,0,1,0,0,0,0,1];case"skewx":return e=r(t.d[0]),[1,0,0,0,Math.tan(e),1,0,0,0,0,1,0,0,0,0,1];case"skewy":return e=r(t.d[0]),[1,Math.tan(e),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,n=t.d[1].px||0,0,1];case"translatex":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,0,0,1];case"translatey":return[1,0,0,0,0,1,0,0,0,0,1,0,0,n=t.d[0].px||0,0,1];case"translatez":return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,s=t.d[0].px||0,1];case"translate3d":return[1,0,0,0,0,1,0,0,0,0,1,0,i=t.d[0].px||0,n=t.d[1].px||0,s=t.d[2].px||0,1];case"perspective":return[1,0,0,0,0,1,0,0,0,0,1,t.d[0].px?-1/t.d[0].px:0,0,0,0,1];case"matrix":return[t.d[0],t.d[1],0,0,t.d[2],t.d[3],0,0,0,0,1,0,t.d[4],t.d[5],0,1];case"matrix3d":return t.d}}function o(t){return 0===t.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:t.map(s).reduce(n)}var a=function(){function t(t){return t[0][0]*t[1][1]*t[2][2]+t[1][0]*t[2][1]*t[0][2]+t[2][0]*t[0][1]*t[1][2]-t[0][2]*t[1][1]*t[2][0]-t[1][2]*t[2][1]*t[0][0]-t[2][2]*t[0][1]*t[1][0]}function e(t){var e=n(t);return[t[0]/e,t[1]/e,t[2]/e]}function n(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2])}function r(t,e,i,n){return[i*t[0]+n*e[0],i*t[1]+n*e[1],i*t[2]+n*e[2]]}return function(s){var o=[s.slice(0,4),s.slice(4,8),s.slice(8,12),s.slice(12,16)];if(1!==o[3][3])return null;for(var a=[],l=0;l<4;l++)a.push(o[l].slice());for(l=0;l<3;l++)a[l][3]=0;if(0===t(a))return null;var h,u=[];o[0][3]||o[1][3]||o[2][3]?(u.push(o[0][3]),u.push(o[1][3]),u.push(o[2][3]),u.push(o[3][3]),h=function(t,e){for(var i=[],n=0;n<4;n++){for(var r=0,s=0;s<4;s++)r+=t[s]*e[s][n];i.push(r)}return i}(u,function(t){return[[t[0][0],t[1][0],t[2][0],t[3][0]],[t[0][1],t[1][1],t[2][1],t[3][1]],[t[0][2],t[1][2],t[2][2],t[3][2]],[t[0][3],t[1][3],t[2][3],t[3][3]]]}(function(e){for(var i=1/t(e),n=e[0][0],r=e[0][1],s=e[0][2],o=e[1][0],a=e[1][1],l=e[1][2],h=e[2][0],u=e[2][1],c=e[2][2],d=[[(a*c-l*u)*i,(s*u-r*c)*i,(r*l-s*a)*i,0],[(l*h-o*c)*i,(n*c-s*h)*i,(s*o-n*l)*i,0],[(o*u-a*h)*i,(h*r-n*u)*i,(n*a-r*o)*i,0]],f=[],p=0;p<3;p++){for(var _=0,m=0;m<3;m++)_+=e[3][m]*d[m][p];f.push(_)}return f.push(1),d.push(f),d}(a)))):h=[0,0,0,1];var c=o[3].slice(0,3),d=[];d.push(o[0].slice(0,3));var f=[];f.push(n(d[0])),d[0]=e(d[0]);var p=[];d.push(o[1].slice(0,3)),p.push(i(d[0],d[1])),d[1]=r(d[1],d[0],1,-p[0]),f.push(n(d[1])),d[1]=e(d[1]),p[0]/=f[1],d.push(o[2].slice(0,3)),p.push(i(d[0],d[2])),d[2]=r(d[2],d[0],1,-p[1]),p.push(i(d[1],d[2])),d[2]=r(d[2],d[1],1,-p[2]),f.push(n(d[2])),d[2]=e(d[2]),p[1]/=f[2],p[2]/=f[2];var _=function(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}(d[1],d[2]);if(i(d[0],_)<0)for(l=0;l<3;l++)f[l]*=-1,d[l][0]*=-1,d[l][1]*=-1,d[l][2]*=-1;var m,g,v=d[0][0]+d[1][1]+d[2][2]+1;return v>1e-4?(m=.5/Math.sqrt(v),g=[(d[2][1]-d[1][2])*m,(d[0][2]-d[2][0])*m,(d[1][0]-d[0][1])*m,.25/m]):d[0][0]>d[1][1]&&d[0][0]>d[2][2]?g=[.25*(m=2*Math.sqrt(1+d[0][0]-d[1][1]-d[2][2])),(d[0][1]+d[1][0])/m,(d[0][2]+d[2][0])/m,(d[2][1]-d[1][2])/m]:d[1][1]>d[2][2]?(m=2*Math.sqrt(1+d[1][1]-d[0][0]-d[2][2]),g=[(d[0][1]+d[1][0])/m,.25*m,(d[1][2]+d[2][1])/m,(d[0][2]-d[2][0])/m]):(m=2*Math.sqrt(1+d[2][2]-d[0][0]-d[1][1]),g=[(d[0][2]+d[2][0])/m,(d[1][2]+d[2][1])/m,.25*m,(d[1][0]-d[0][1])/m]),[c,f,p,g,h]}}();t.dot=i,t.makeMatrixDecomposition=function(t){return[a(o(t))]},t.transformListToMatrix=o}(sn),function(t){function e(t,e){var i=t.exec(e);if(i)return[i=t.ignoreCase?i[0].toLowerCase():i[0],e.substr(i.length)]}function i(t,e){var i=t(e=e.replace(/^\s*/,""));if(i)return[i[0],i[1].replace(/^\s*/,"")]}function n(t,e,i,n,r){for(var s=[],o=[],a=[],l=function(t,e){for(var i=t,n=e;i&&n;)i>n?i%=n:n%=i;return t*e/(i+n)}(n.length,r.length),h=0;h<l;h++){var u=e(n[h%n.length],r[h%r.length]);if(!u)return;s.push(u[0]),o.push(u[1]),a.push(u[2])}return[s,o,function(e){var n=e.map((function(t,e){return a[e](t)})).join(i);return t?t(n):n}]}t.consumeToken=e,t.consumeTrimmed=i,t.consumeRepeated=function(t,n,r){t=i.bind(null,t);for(var s=[];;){var o=t(r);if(!o)return[s,r];if(s.push(o[0]),!(o=e(n,r=o[1]))||""==o[1])return[s,r];r=o[1]}},t.consumeParenthesised=function(t,e){for(var i=0,n=0;n<e.length&&(!/\s|,/.test(e[n])||0!=i);n++)if("("==e[n])i++;else if(")"==e[n]&&(0==--i&&n++,i<=0))break;var r=t(e.substr(0,n));return null==r?void 0:[r,e.substr(n)]},t.ignore=function(t){return function(e){var i=t(e);return i&&(i[0]=void 0),i}},t.optional=function(t,e){return function(i){return t(i)||[e,i]}},t.consumeList=function(e,i){for(var n=[],r=0;r<e.length;r++){var s=t.consumeTrimmed(e[r],i);if(!s||""==s[0])return;void 0!==s[0]&&n.push(s[0]),i=s[1]}if(""==i)return n},t.mergeNestedRepeated=n.bind(null,null),t.mergeWrappedNestedRepeated=n,t.mergeList=function(t,e,i){for(var n=[],r=[],s=[],o=0,a=0;a<i.length;a++)if("function"==typeof i[a]){var l=i[a](t[o],e[o++]);n.push(l[0]),r.push(l[1]),s.push(l[2])}else!function(t){n.push(!1),r.push(!1),s.push((function(){return i[t]}))}(a);return[n,r,function(t){for(var e="",i=0;i<t.length;i++)e+=s[i](t[i]);return e}]}}(sn),function(t){function e(e){var i={inset:!1,lengths:[],color:null},n=t.consumeRepeated((function(e){var n=t.consumeToken(/^inset/i,e);return n?(i.inset=!0,n):(n=t.consumeLengthOrPercent(e))?(i.lengths.push(n[0]),n):(n=t.consumeColor(e))?(i.color=n[0],n):void 0}),/^/,e);if(n&&n[0].length)return[i,n[1]]}var i=function(e,i,n,r){function s(t){return{inset:t,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var o=[],a=[],l=0;l<n.length||l<r.length;l++){var h=n[l]||s(r[l].inset),u=r[l]||s(n[l].inset);o.push(h),a.push(u)}return t.mergeNestedRepeated(e,i,o,a)}.bind(null,(function(e,i){for(;e.lengths.length<Math.max(e.lengths.length,i.lengths.length);)e.lengths.push({px:0});for(;i.lengths.length<Math.max(e.lengths.length,i.lengths.length);)i.lengths.push({px:0});if(e.inset==i.inset&&!!e.color==!!i.color){for(var n,r=[],s=[[],0],o=[[],0],a=0;a<e.lengths.length;a++){var l=t.mergeDimensions(e.lengths[a],i.lengths[a],2==a);s[0].push(l[0]),o[0].push(l[1]),r.push(l[2])}if(e.color&&i.color){var h=t.mergeColors(e.color,i.color);s[1]=h[0],o[1]=h[1],n=h[2]}return[s,o,function(t){for(var i=e.inset?"inset ":" ",s=0;s<r.length;s++)i+=r[s](t[0][s])+" ";return n&&(i+=n(t[1])),i}]}}),", ");t.addPropertiesHandler((function(i){var n=t.consumeRepeated(e,/^,/,i);if(n&&""==n[1])return n[0]}),i,["box-shadow","text-shadow"])}(sn),function(t,e){function i(t){return t.toFixed(3).replace(/0+$/,"").replace(/\.$/,"")}function n(t,e,i){return Math.min(e,Math.max(t,i))}function r(t){if(/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t))return Number(t)}function s(t,e){return function(r,s){return[r,s,function(r){return i(n(t,e,r))}]}}function o(t){var e=t.trim().split(/\s*[\s,]\s*/);if(0!==e.length){for(var i=[],n=0;n<e.length;n++){var s=r(e[n]);if(void 0===s)return;i.push(s)}return i}}t.clamp=n,t.addPropertiesHandler(o,(function(t,e){if(t.length==e.length)return[t,e,function(t){return t.map(i).join(" ")}]}),["stroke-dasharray"]),t.addPropertiesHandler(r,s(0,1/0),["border-image-width","line-height"]),t.addPropertiesHandler(r,s(0,1),["opacity","shape-image-threshold"]),t.addPropertiesHandler(r,(function(t,e){if(0!=t)return s(0,1/0)(t,e)}),["flex-grow","flex-shrink"]),t.addPropertiesHandler(r,(function(t,e){return[t,e,function(t){return Math.round(n(1,1/0,t))}]}),["orphans","widows"]),t.addPropertiesHandler(r,(function(t,e){return[t,e,Math.round]}),["z-index"]),t.parseNumber=r,t.parseNumberList=o,t.mergeNumbers=function(t,e){return[t,e,i]},t.numberToString=i}(sn),function(t,e){t.addPropertiesHandler(String,(function(t,e){if("visible"==t||"visible"==e)return[0,1,function(i){return i<=0?t:i>=1?e:"visible"}]}),["visibility"])}(sn),function(t,e){function i(t){t=t.trim(),s.fillStyle="#000",s.fillStyle=t;var e=s.fillStyle;if(s.fillStyle="#fff",s.fillStyle=t,e==s.fillStyle){s.fillRect(0,0,1,1);var i=s.getImageData(0,0,1,1).data;s.clearRect(0,0,1,1);var n=i[3]/255;return[i[0]*n,i[1]*n,i[2]*n,n]}}function n(e,i){return[e,i,function(e){function i(t){return Math.max(0,Math.min(255,t))}if(e[3])for(var n=0;n<3;n++)e[n]=Math.round(i(e[n]/e[3]));return e[3]=t.numberToString(t.clamp(0,1,e[3])),"rgba("+e.join(",")+")"}]}var r=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");r.width=r.height=1;var s=r.getContext("2d");t.addPropertiesHandler(i,n,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","fill","flood-color","lighting-color","outline-color","stop-color","stroke","text-decoration-color"]),t.consumeColor=t.consumeParenthesised.bind(null,i),t.mergeColors=n}(sn),function(t,e){function i(t){function e(){var e=o.exec(t);s=e?e[0]:void 0}function i(){if("("!==s)return function(){var t=Number(s);return e(),t}();e();var t=r();return")"!==s?NaN:(e(),t)}function n(){for(var t=i();"*"===s||"/"===s;){var n=s;e();var r=i();"*"===n?t*=r:t/=r}return t}function r(){for(var t=n();"+"===s||"-"===s;){var i=s;e();var r=n();"+"===i?t+=r:t-=r}return t}var s,o=/([\+\-\w\.]+|[\(\)\*\/])/g;return e(),r()}function n(t,e){if("0"==(e=e.trim().toLowerCase())&&"px".search(t)>=0)return{px:0};if(/^[^(]*$|^calc/.test(e)){e=e.replace(/calc\(/g,"(");var n={};e=e.replace(t,(function(t){return n[t]=null,"U"+t}));for(var r="U("+t.source+")",s=e.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g,"N").replace(new RegExp("N"+r,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),o=[/N\*(D)/g,/(N|D)[*\/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],a=0;a<o.length;)o[a].test(s)?(s=s.replace(o[a],"$1"),a=0):a++;if("D"==s){for(var l in n){var h=i(e.replace(new RegExp("U"+l,"g"),"").replace(new RegExp(r,"g"),"*0"));if(!isFinite(h))return;n[l]=h}return n}}}function r(t,e){return s(t,e,!0)}function s(e,i,n){var r,s=[];for(r in e)s.push(r);for(r in i)s.indexOf(r)<0&&s.push(r);return e=s.map((function(t){return e[t]||0})),i=s.map((function(t){return i[t]||0})),[e,i,function(e){var i=e.map((function(i,r){return 1==e.length&&n&&(i=Math.max(i,0)),t.numberToString(i)+s[r]})).join(" + ");return e.length>1?"calc("+i+")":i}]}var o="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",a=n.bind(null,new RegExp(o,"g")),l=n.bind(null,new RegExp(o+"|%","g")),h=n.bind(null,/deg|rad|grad|turn/g);t.parseLength=a,t.parseLengthOrPercent=l,t.consumeLengthOrPercent=t.consumeParenthesised.bind(null,l),t.parseAngle=h,t.mergeDimensions=s;var u=t.consumeParenthesised.bind(null,a),c=t.consumeRepeated.bind(void 0,u,/^/),d=t.consumeRepeated.bind(void 0,c,/^,/);t.consumeSizePairList=d;var f=t.mergeNestedRepeated.bind(void 0,r," "),p=t.mergeNestedRepeated.bind(void 0,f,",");t.mergeNonNegativeSizePair=f,t.addPropertiesHandler((function(t){var e=d(t);if(e&&""==e[1])return e[0]}),p,["background-size"]),t.addPropertiesHandler(l,r,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),t.addPropertiesHandler(l,s,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","stroke-dashoffset","text-indent","top","vertical-align","word-spacing"])}(sn),function(t,e){function i(e){return t.consumeLengthOrPercent(e)||t.consumeToken(/^auto/,e)}function n(e){var n=t.consumeList([t.ignore(t.consumeToken.bind(null,/^rect/)),t.ignore(t.consumeToken.bind(null,/^\(/)),t.consumeRepeated.bind(null,i,/^,/),t.ignore(t.consumeToken.bind(null,/^\)/))],e);if(n&&4==n[0].length)return n[0]}var r=t.mergeWrappedNestedRepeated.bind(null,(function(t){return"rect("+t+")"}),(function(e,i){return"auto"==e||"auto"==i?[!0,!1,function(n){var r=n?e:i;if("auto"==r)return"auto";var s=t.mergeDimensions(r,r);return s[2](s[0])}]:t.mergeDimensions(e,i)}),", ");t.parseBox=n,t.mergeBoxes=r,t.addPropertiesHandler(n,r,["clip"])}(sn),function(t,e){function i(t){return function(e){var i=0;return t.map((function(t){return t===h?e[i++]:t}))}}function n(t){return t}function r(e){if("none"==(e=e.toLowerCase().trim()))return[];for(var i,n=/\s*(\w+)\(([^)]*)\)/g,r=[],s=0;i=n.exec(e);){if(i.index!=s)return;s=i.index+i[0].length;var o=i[1],a=d[o];if(!a)return;var l=i[2].split(","),h=a[0];if(h.length<l.length)return;for(var f=[],p=0;p<h.length;p++){var _,m=l[p],g=h[p];if(void 0===(_=m?{A:function(e){return"0"==e.trim()?c:t.parseAngle(e)},N:t.parseNumber,T:t.parseLengthOrPercent,L:t.parseLength}[g.toUpperCase()](m):{a:c,n:f[0],t:u}[g]))return;f.push(_)}if(r.push({t:o,d:f}),n.lastIndex==e.length)return r}}function s(t){return t.toFixed(6).replace(".000000","")}function o(e,i){if(e.decompositionPair!==i){e.decompositionPair=i;var n=t.makeMatrixDecomposition(e)}if(i.decompositionPair!==e){i.decompositionPair=e;var r=t.makeMatrixDecomposition(i)}return null==n[0]||null==r[0]?[[!1],[!0],function(t){return t?i[0].d:e[0].d}]:(n[0].push(0),r[0].push(1),[n,r,function(e){var i=t.quat(n[0][3],r[0][3],e[5]);return t.composeMatrix(e[0],e[1],e[2],i,e[4]).map(s).join(",")}])}function a(t){return t.replace(/[xy]/,"")}function l(t){return t.replace(/(x|y|z|3d)?$/,"3d")}var h=null,u={px:0},c={deg:0},d={matrix:["NNNNNN",[h,h,0,0,h,h,0,0,0,0,1,0,h,h,0,1],n],matrix3d:["NNNNNNNNNNNNNNNN",n],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",i([h,h,1]),n],scalex:["N",i([h,1,1]),i([h,1])],scaley:["N",i([1,h,1]),i([1,h])],scalez:["N",i([1,1,h])],scale3d:["NNN",n],skew:["Aa",null,n],skewx:["A",null,i([h,c])],skewy:["A",null,i([c,h])],translate:["Tt",i([h,h,u]),n],translatex:["T",i([h,u,u]),i([h,u])],translatey:["T",i([u,h,u]),i([u,h])],translatez:["L",i([u,u,h])],translate3d:["TTL",n]};t.addPropertiesHandler(r,(function(e,i){var n=t.makeMatrixDecomposition&&!0,r=!1;if(!e.length||!i.length){e.length||(r=!0,e=i,i=[]);for(var s=0;s<e.length;s++){var h=e[s].t,u=e[s].d,c="scale"==h.substr(0,5)?1:0;i.push({t:h,d:u.map((function(t){if("number"==typeof t)return c;var e={};for(var i in t)e[i]=c;return e}))})}}var f=function(t,e){return"perspective"==t&&"perspective"==e||("matrix"==t||"matrix3d"==t)&&("matrix"==e||"matrix3d"==e)},p=[],_=[],m=[];if(e.length!=i.length){if(!n)return;p=[(S=o(e,i))[0]],_=[S[1]],m=[["matrix",[S[2]]]]}else for(s=0;s<e.length;s++){var g=e[s].t,v=i[s].t,y=e[s].d,b=i[s].d,w=d[g],x=d[v];if(f(g,v)){if(!n)return;var S=o([e[s]],[i[s]]);p.push(S[0]),_.push(S[1]),m.push(["matrix",[S[2]]])}else{if(g==v)h=g;else if(w[2]&&x[2]&&a(g)==a(v))h=a(g),y=w[2](y),b=x[2](b);else{if(!w[1]||!x[1]||l(g)!=l(v)){if(!n)return;p=[(S=o(e,i))[0]],_=[S[1]],m=[["matrix",[S[2]]]];break}h=l(g),y=w[1](y),b=x[1](b)}for(var E=[],T=[],D=[],A=0;A<y.length;A++)S=("number"==typeof y[A]?t.mergeNumbers:t.mergeDimensions)(y[A],b[A]),E[A]=S[0],T[A]=S[1],D.push(S[2]);p.push(E),_.push(T),m.push([h,D])}}if(r){var k=p;p=_,_=k}return[p,_,function(t){return t.map((function(t,e){var i=t.map((function(t,i){return m[e][1][i](t)})).join(",");return"matrix"==m[e][0]&&16==i.split(",").length&&(m[e][0]="matrix3d"),m[e][0]+"("+i+")"})).join(" ")}]}),["transform"]),t.transformToSvgMatrix=function(e){var i=t.transformListToMatrix(r(e));return"matrix("+s(i[0])+" "+s(i[1])+" "+s(i[4])+" "+s(i[5])+" "+s(i[12])+" "+s(i[13])+")"}}(sn),function(t){function e(e){return e=100*Math.round(e/100),400===(e=t.clamp(100,900,e))?"normal":700===e?"bold":String(e)}t.addPropertiesHandler((function(t){var e=Number(t);if(!(isNaN(e)||e<100||e>900||e%100!=0))return e}),(function(t,i){return[t,i,e]}),["font-weight"])}(sn),function(t){function e(t){var e={};for(var i in t)e[i]=-t[i];return e}function i(e){return t.consumeToken(/^(left|center|right|top|bottom)\b/i,e)||t.consumeLengthOrPercent(e)}function n(e,n){var r=t.consumeRepeated(i,/^/,n);if(r&&""==r[1]){var o=r[0];if(o[0]=o[0]||"center",o[1]=o[1]||"center",3==e&&(o[2]=o[2]||{px:0}),o.length==e){if(/top|bottom/.test(o[0])||/left|right/.test(o[1])){var a=o[0];o[0]=o[1],o[1]=a}if(/left|right|center|Object/.test(o[0])&&/top|bottom|center|Object/.test(o[1]))return o.map((function(t){return"object"==typeof t?t:s[t]}))}}}function r(n){var r=t.consumeRepeated(i,/^/,n);if(r){for(var o=r[0],a=[{"%":50},{"%":50}],l=0,h=!1,u=0;u<o.length;u++){var c=o[u];"string"==typeof c?(h=/bottom|right/.test(c),a[l={left:0,right:0,center:l,top:1,bottom:1}[c]]=s[c],"center"==c&&l++):(h&&((c=e(c))["%"]=(c["%"]||0)+100),a[l]=c,l++,h=!1)}return[a,r[1]]}}var s={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},o=t.mergeNestedRepeated.bind(null,t.mergeDimensions," ");t.addPropertiesHandler(n.bind(null,3),o,["transform-origin"]),t.addPropertiesHandler(n.bind(null,2),o,["perspective-origin"]),t.consumePosition=r,t.mergeOffsetList=o;var a=t.mergeNestedRepeated.bind(null,o,", ");t.addPropertiesHandler((function(e){var i=t.consumeRepeated(r,/^,/,e);if(i&&""==i[1])return i[0]}),a,["background-position","object-position"])}(sn),function(t){var e=t.consumeParenthesised.bind(null,t.parseLengthOrPercent),i=t.consumeRepeated.bind(void 0,e,/^/),n=t.mergeNestedRepeated.bind(void 0,t.mergeDimensions," "),r=t.mergeNestedRepeated.bind(void 0,n,",");t.addPropertiesHandler((function(n){var r=t.consumeToken(/^circle/,n);if(r&&r[0])return["circle"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),e,t.ignore(t.consumeToken.bind(void 0,/^at/)),t.consumePosition,t.ignore(t.consumeToken.bind(void 0,/^\)/))],r[1]));var s=t.consumeToken(/^ellipse/,n);if(s&&s[0])return["ellipse"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),i,t.ignore(t.consumeToken.bind(void 0,/^at/)),t.consumePosition,t.ignore(t.consumeToken.bind(void 0,/^\)/))],s[1]));var o=t.consumeToken(/^polygon/,n);return o&&o[0]?["polygon"].concat(t.consumeList([t.ignore(t.consumeToken.bind(void 0,/^\(/)),t.optional(t.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),t.consumeSizePairList,t.ignore(t.consumeToken.bind(void 0,/^\)/))],o[1])):void 0}),(function(e,i){if(e[0]===i[0])return"circle"==e[0]?t.mergeList(e.slice(1),i.slice(1),["circle(",t.mergeDimensions," at ",t.mergeOffsetList,")"]):"ellipse"==e[0]?t.mergeList(e.slice(1),i.slice(1),["ellipse(",t.mergeNonNegativeSizePair," at ",t.mergeOffsetList,")"]):"polygon"==e[0]&&e[1]==i[1]?t.mergeList(e.slice(2),i.slice(2),["polygon(",e[1],r,")"]):void 0}),["shape-outside"])}(sn),function(t,e){function i(t,e){e.concat([t]).forEach((function(e){e in document.documentElement.style&&(n[t]=e),r[e]=t}))}var n={},r={};i("transform",["webkitTransform","msTransform"]),i("transformOrigin",["webkitTransformOrigin"]),i("perspective",["webkitPerspective"]),i("perspectiveOrigin",["webkitPerspectiveOrigin"]),t.propertyName=function(t){return n[t]||t},t.unprefixedPropertyName=function(t){return r[t]||t}}(sn)}(),function(){if(void 0===document.createElement("div").animate([]).oncancel){if(window.performance&&performance.now)var t=function(){return performance.now()};else t=function(){return Date.now()};var e=function(t,e,i){this.target=t,this.currentTime=e,this.timelineTime=i,this.type="cancel",this.bubbles=!1,this.cancelable=!1,this.currentTarget=t,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()},i=window.Element.prototype.animate;window.Element.prototype.animate=function(n,r){var s=i.call(this,n,r);s._cancelHandlers=[],s.oncancel=null;var o=s.cancel;s.cancel=function(){o.call(this);var i=new e(this,null,t()),n=this._cancelHandlers.concat(this.oncancel?[this.oncancel]:[]);setTimeout((function(){n.forEach((function(t){t.call(i.target,i)}))}),0)};var a=s.addEventListener;s.addEventListener=function(t,e){"function"==typeof e&&"cancel"==t?this._cancelHandlers.push(e):a.call(this,t,e)};var l=s.removeEventListener;return s.removeEventListener=function(t,e){if("cancel"==t){var i=this._cancelHandlers.indexOf(e);i>=0&&this._cancelHandlers.splice(i,1)}else l.call(this,t,e)},s}}}(),function(t){var e=document.documentElement,i=null,n=!1;try{var r="0"==getComputedStyle(e).getPropertyValue("opacity")?"1":"0";(i=e.animate({opacity:[r,r]},{duration:1})).currentTime=0,n=getComputedStyle(e).getPropertyValue("opacity")==r}catch(t){}finally{i&&i.cancel()}if(!n){var s=window.Element.prototype.animate;window.Element.prototype.animate=function(e,i){return window.Symbol&&Symbol.iterator&&Array.prototype.from&&e[Symbol.iterator]&&(e=Array.from(e)),Array.isArray(e)||null===e||(e=t.convertToArrayForm(e)),s.call(this,e,i)}}}(rn),Array.from(document.querySelectorAll("#wpbody-content > *:not(.metagallery-allowed)")).forEach((function(t){return t.style.setProperty("display","none","important")})),window.__=function(t,e){return t},window.CurrentGallery=function(t){return{data:t,title:"",dirty:!1,saving:!1,images:[{_uid:0,height:0,width:0,title:"",alt:"",caption:""}],settings:{maxImageWidth:"600",minImageWidth:"315",percentImageWidth:"25",imageSpacing:"15"},init:function(){this.title=this.data.meta.title,this.images=this.data.meta.images,this.settings=Object.assign(this.settings,this.data.meta.settings)},save:async function(){console.log("MetaGallery: Saving..."),await new Promise((function(t){return setTimeout(t,250)})),window.metagalleryGrid&&this.updateImageOrder(window.metagalleryGrid.getItems()),this.saving=!0,this.dirty=!1,await Z(this.data.ID,this.title,this.images,this.settings),await new Promise((function(t){return setTimeout(t,1500)})),this.saving=!1},updateTitle:function(t){console.log("MetaGallery: Updating title to:",t),this.dirty=!0,this.title=t},updateSetting:function(t,e){console.log("MetaGallery: Updating "+t+" to:",e),this.dirty=!0,this.settings[t]=parseInt(e,10)<0?0:e,this.updateLayout()},updateImageSetting:function(t,e,i){console.log("MetaGallery: Updating image "+t+" "+e+" to:",i),this.dirty=!0,this.images.find((function(e){return e._uid==t})).alt=i,this.updateLayout()},addImages:function(t){var e;console.log("MetaGallery: Adding "+t.length+" "+(t.length>1?"images":"image")),this.dirty=!0,(e=this.images).push.apply(e,t),window.dispatchEvent(new CustomEvent("metagallery-images-added",{detail:{images:t},bubbles:!0}))},updateImageOrder:function(t){var e=this;t=t.map((function(t){return t.getElement().querySelector("[x-data]").__x.getUnobservedData()._uid})),this.images=t.reduce((function(t,i,n){return t[n]=e.images.find((function(t){return t._uid==i})),t}),[])},updateLayout:function(){setTimeout((function(){window.dispatchEvent(new CustomEvent("reset-layout",{detail:{},bubbles:!0}))}),0)}}},window.Gallery=function(){return{muuri:null,images:[],init:function(){var t=this;this.images=JSON.parse(JSON.stringify(this.$component("current").images)),this.images.length&&(window.metagalleryGrid=new window.Muuri("[id=metagallery-grid-"+this.$component("current").data.ID+"]",{items:this.images.map((function(e){return t.buildImage(e)})),dragSortPredicate:{action:"move"},dragEnabled:!0,layout:{fillGaps:!0}}),window.metagalleryGrid.on("move",(function(e){t.$component("current").dirty=!0})))},get containerStyles(){return"\n margin: 0 -"+this.$component("current").settings.imageSpacing+"px;\n "},addImages:function(t){var e=this;if(!window.metagalleryGrid)return this.init();window.metagalleryGrid.add(t.map((function(t){return e.buildImage(t)})),{index:0})},removeImages:function(t){this.$component("current").dirty=!0;var e=window.metagalleryGrid.getItems();window.metagalleryGrid.remove(t.map((function(t){return e.find((function(e){return e.getElement().querySelector("[x-data]").__x.getUnobservedData()._uid==t}))})),{removeElements:!0})},buildImage:function(t){var e=document.createElement("div"),i=function(t){return"<div\n x-title=\"Image Wrapper\"\n x-data=\"{\n get itemWrapper() {\n return $el.style.cssText +\n 'width:' + this.$component('current').settings.percentImageWidth + '%;' +\n 'min-width:' + this.$component('current').settings.minImageWidth + 'px;' +\n 'max-width:' + this.$component('current').settings.maxImageWidth + 'px;'\n },\n\n }\"\n class=\"item absolute overflow-hidden\"\n :style=\"itemWrapper\">\n <div class=\"item-content relative h-full w-full\">\n <div\n x-title=\"Gallery Image\"\n x-data=\"GalleryImage("+t._uid+')"\n x-init="init()"\n class="group cursor-move">\n <button\n x-cloak\n class="transition p-2 rounded-full duration-200 bg-nord0 text-nord13 absolute top-2 right-2 opacity-0 group-hover:opacity-100 focus:outline-none ring-2 ring-nord2 focus:ring-nord9 ring-opacity-70 focus:ring-opacity-100 focus:text-nord9"\n :class="{ \'opacity-100 ring-4\': open }"\n :style="buttonStyles"\n @click="$dispatch(\'open-image-settings\', { image: '+t._uid+' })">\n <svg class="w-6 h-6 block" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6h16M4 12h16m-7 6h7" />\n </svg>\n <span class="sr-only">'+window.__("edit","metagallery")+'</span>\n </button>\n <img\n class="border-0"\n :style="imageStyles"\n width="'+t.width+'"\n height="'+t.height+'"\n src="'+t.src.main.url+'"\n alt="'+r.xssEscape(t.alt)+'"/>\n </div>\n </div>\n </div>'}(t);return e.innerHTML=i,e.firstChild}}},window.GalleryImage=function(t){return{_uid:t,get open(){return this.$component("image-settings").imageId==this._uid},get imageStyles(){return"\n padding:"+this.$component("current").settings.imageSpacing+"px;\n "},get buttonStyles(){return"\n margin-top: "+this.$component("current").settings.imageSpacing+"px;\n margin-right: "+this.$component("current").settings.imageSpacing+"px;\n "},init:function(){setTimeout((function(){window.dispatchEvent(new CustomEvent("reset-layout",{detail:{},bubbles:!0}))}),0)}}},window.MediaLibrary=function(){return{manager:{},init:function(){var t=this;this.manager=wp.media.frames.file_frame=wp.media({title:__("Select Images","metagallery"),multiple:!0,library:{type:"image"}});var e=this.manager.states.models.filter((function(t){return!["library"].includes(t.id)}));this.manager.states.remove(e),this.manager.on("select",(function(){var e=t.manager.state().get("selection").toJSON().filter((function(t){return"image"===t.type})).map((function(t){return{_uid:parseInt(Date.now()+Math.floor(1e6*Math.random()),10),height:t.height,width:t.width,title:t.title,alt:r.xssEscape(t.alt),caption:t.caption,src:{main:t.sizes.full,thumbnail:t.sizes.thumbnail},WP:{id:t.id}}}));t.$component("current").addImages(e)}))}}},window.Alpine.pauseMutationObserver=!0,window.Muuri=un}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
!(function (t) {
|
| 2 |
+
'function' == typeof define && define.amd ? define(t) : t()
|
| 3 |
+
})(function () {
|
| 4 |
+
'use strict'
|
| 5 |
+
var t =
|
| 6 |
+
'undefined' != typeof globalThis
|
| 7 |
+
? globalThis
|
| 8 |
+
: 'undefined' != typeof window
|
| 9 |
+
? window
|
| 10 |
+
: 'undefined' != typeof global
|
| 11 |
+
? global
|
| 12 |
+
: 'undefined' != typeof self
|
| 13 |
+
? self
|
| 14 |
+
: {}
|
| 15 |
+
function e(t) {
|
| 16 |
+
var e = { exports: {} }
|
| 17 |
+
return t(e, e.exports), e.exports
|
| 18 |
+
}
|
| 19 |
+
e(function (t, e) {
|
| 20 |
+
t.exports = (function () {
|
| 21 |
+
var t = function () {
|
| 22 |
+
if (!window.Alpine)
|
| 23 |
+
throw new Error(
|
| 24 |
+
'[Magic Helpers] Alpine is required for the magic helpers to function correctly.',
|
| 25 |
+
)
|
| 26 |
+
if (!window.Alpine.version || !s('2.5.0', window.Alpine.version))
|
| 27 |
+
throw new Error('Invalid Alpine version. Please use Alpine version 2.5.0 or above')
|
| 28 |
+
},
|
| 29 |
+
e = function (t, e, i) {
|
| 30 |
+
e.getAttribute('x-bind:data-last-refresh') ||
|
| 31 |
+
e.setAttribute('x-bind:data-last-refresh', 'Date.now()')
|
| 32 |
+
var n = function t(n) {
|
| 33 |
+
return (
|
| 34 |
+
void 0 === n && (n = null),
|
| 35 |
+
{
|
| 36 |
+
get: function (e, i) {
|
| 37 |
+
if (null !== e[i] && 'object' == typeof e[i]) {
|
| 38 |
+
var r = n ? n + '.' + i : i
|
| 39 |
+
return new Proxy(e[i], t(r))
|
| 40 |
+
}
|
| 41 |
+
return e[i]
|
| 42 |
+
},
|
| 43 |
+
set: function (t, r, s) {
|
| 44 |
+
if (!e.__x) throw new Error('Error communicating with observed component')
|
| 45 |
+
var o = n ? n + '.' + r : r
|
| 46 |
+
return i.call(e, e.__x.$data, o, s), !0
|
| 47 |
+
},
|
| 48 |
+
}
|
| 49 |
+
)
|
| 50 |
+
}
|
| 51 |
+
return new Proxy(t, n())
|
| 52 |
+
},
|
| 53 |
+
i = function (t, e) {
|
| 54 |
+
t.getAttribute('x-bind:data-last-refresh') ||
|
| 55 |
+
t.setAttribute('x-bind:data-last-refresh', 'Date.now()'),
|
| 56 |
+
new MutationObserver(function (i) {
|
| 57 |
+
for (var n = 0; n < i.length; n++) {
|
| 58 |
+
var r = i[n].target.closest('[x-data]')
|
| 59 |
+
if (!r || r.isSameNode(t)) return void e()
|
| 60 |
+
}
|
| 61 |
+
}).observe(t, { attributes: !0, childList: !0, subtree: !0 })
|
| 62 |
+
},
|
| 63 |
+
n = function (t, e, i) {
|
| 64 |
+
return (
|
| 65 |
+
((e = e.toString().match(/[^.[\]]+/g) || []).slice(0, -1).reduce(function (t, i, n) {
|
| 66 |
+
return (
|
| 67 |
+
Object(t[i]) !== t[i] && (t[i] = Math.abs(e[n + 1]) >> 0 == +e[n + 1] ? [] : {}), t[i]
|
| 68 |
+
)
|
| 69 |
+
}, t)[e[e.length - 1]] = i),
|
| 70 |
+
t
|
| 71 |
+
)
|
| 72 |
+
},
|
| 73 |
+
r = function (t) {
|
| 74 |
+
return t.__x ? t.__x.getUnobservedData() : o(t.getAttribute('x-data'), t)
|
| 75 |
+
}
|
| 76 |
+
function s(t, e) {
|
| 77 |
+
for (var i = t.split('.'), n = e.split('.'), r = 0; r < i.length; r++)
|
| 78 |
+
if (!n[r] || parseInt(n[r]) < parseInt(i[r])) return !1
|
| 79 |
+
return !0
|
| 80 |
+
}
|
| 81 |
+
function o(t, e, i) {
|
| 82 |
+
return (
|
| 83 |
+
void 0 === i && (i = {}),
|
| 84 |
+
'function' == typeof t
|
| 85 |
+
? t.call(e)
|
| 86 |
+
: new Function(
|
| 87 |
+
['$data'].concat(Object.keys(i)),
|
| 88 |
+
'var __alpine_result; with($data) { __alpine_result = ' +
|
| 89 |
+
t +
|
| 90 |
+
' }; return __alpine_result',
|
| 91 |
+
).apply(void 0, [e].concat(Object.values(i)))
|
| 92 |
+
)
|
| 93 |
+
}
|
| 94 |
+
var a = {
|
| 95 |
+
start: function () {
|
| 96 |
+
t(),
|
| 97 |
+
Alpine.addMagicProperty('parent', function (t) {
|
| 98 |
+
if (void 0 !== t.$parent) return t.$parent
|
| 99 |
+
var s = t.parentNode.closest('[x-data]')
|
| 100 |
+
if (!s) throw new Error('Parent component not found')
|
| 101 |
+
return (
|
| 102 |
+
(t.$parent = e(r(s), s, n)),
|
| 103 |
+
i(s, function () {
|
| 104 |
+
;(t.$parent = e(s.__x.getUnobservedData(), s, n)), t.__x.updateElements(t)
|
| 105 |
+
}),
|
| 106 |
+
t.$parent
|
| 107 |
+
)
|
| 108 |
+
}),
|
| 109 |
+
Alpine.addMagicProperty('component', function (t) {
|
| 110 |
+
return function (s) {
|
| 111 |
+
var o = this
|
| 112 |
+
if (void 0 !== this[s]) return this[s]
|
| 113 |
+
var a = document.querySelector('[x-data][x-id="' + s + '"], [x-data]#' + s)
|
| 114 |
+
if (!a) throw new Error('Component not found')
|
| 115 |
+
return (
|
| 116 |
+
(this[s] = e(r(a), a, n)),
|
| 117 |
+
i(a, function () {
|
| 118 |
+
;(o[s] = e(a.__x.getUnobservedData(), a, n)), t.__x.updateElements(t)
|
| 119 |
+
}),
|
| 120 |
+
this[s]
|
| 121 |
+
)
|
| 122 |
+
}
|
| 123 |
+
})
|
| 124 |
+
},
|
| 125 |
+
},
|
| 126 |
+
l =
|
| 127 |
+
window.deferLoadingAlpine ||
|
| 128 |
+
function (t) {
|
| 129 |
+
return t()
|
| 130 |
+
}
|
| 131 |
+
return (
|
| 132 |
+
(window.deferLoadingAlpine = function (t) {
|
| 133 |
+
l(t), a.start()
|
| 134 |
+
}),
|
| 135 |
+
a
|
| 136 |
+
)
|
| 137 |
+
})()
|
| 138 |
+
})
|
| 139 |
+
const i = {
|
| 140 |
+
start() {
|
| 141 |
+
if (!window.Alpine) throw new Error('Alpine is required for `alpine-clipboard` to work.')
|
| 142 |
+
Alpine.addMagicProperty(
|
| 143 |
+
'clipboard',
|
| 144 |
+
() =>
|
| 145 |
+
function (t) {
|
| 146 |
+
let e = t
|
| 147 |
+
if ('function' == typeof e) e = e()
|
| 148 |
+
else if ('string' != typeof e)
|
| 149 |
+
try {
|
| 150 |
+
e = JSON.stringify(e)
|
| 151 |
+
} catch (t) {
|
| 152 |
+
console.warn(t)
|
| 153 |
+
}
|
| 154 |
+
const i = document.createElement('textarea')
|
| 155 |
+
if (
|
| 156 |
+
((i.value = e),
|
| 157 |
+
i.setAttribute('readonly', ''),
|
| 158 |
+
(i.style.cssText = 'position:fixed;pointer-events:none;z-index:-9999;opacity:0;'),
|
| 159 |
+
document.body.appendChild(i),
|
| 160 |
+
navigator.userAgent && navigator.userAgent.match(/ipad|ipod|iphone/i))
|
| 161 |
+
) {
|
| 162 |
+
;(i.contentEditable = !0), (i.readOnly = !0)
|
| 163 |
+
const t = document.createRange()
|
| 164 |
+
t.selectNodeContents(i)
|
| 165 |
+
const e = window.getSelection()
|
| 166 |
+
e.removeAllRanges(), e.addRange(t), i.setSelectionRange(0, 999999)
|
| 167 |
+
} else i.select()
|
| 168 |
+
try {
|
| 169 |
+
document.execCommand('copy')
|
| 170 |
+
} catch (t) {
|
| 171 |
+
console.warn(err)
|
| 172 |
+
}
|
| 173 |
+
document.body.removeChild(i)
|
| 174 |
+
},
|
| 175 |
+
)
|
| 176 |
+
},
|
| 177 |
+
},
|
| 178 |
+
n = window.deferLoadingAlpine || ((t) => t())
|
| 179 |
+
window.deferLoadingAlpine = function (t) {
|
| 180 |
+
i.start(), n(t)
|
| 181 |
+
}
|
| 182 |
+
e(function (t, e) {
|
| 183 |
+
t.exports = (function () {
|
| 184 |
+
function t(t, e, i) {
|
| 185 |
+
return (
|
| 186 |
+
e in t
|
| 187 |
+
? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 })
|
| 188 |
+
: (t[e] = i),
|
| 189 |
+
t
|
| 190 |
+
)
|
| 191 |
+
}
|
| 192 |
+
function e(t, e) {
|
| 193 |
+
var i = Object.keys(t)
|
| 194 |
+
if (Object.getOwnPropertySymbols) {
|
| 195 |
+
var n = Object.getOwnPropertySymbols(t)
|
| 196 |
+
e &&
|
| 197 |
+
(n = n.filter(function (e) {
|
| 198 |
+
return Object.getOwnPropertyDescriptor(t, e).enumerable
|
| 199 |
+
})),
|
| 200 |
+
i.push.apply(i, n)
|
| 201 |
+
}
|
| 202 |
+
return i
|
| 203 |
+
}
|
| 204 |
+
function i(i) {
|
| 205 |
+
for (var n = 1; n < arguments.length; n++) {
|
| 206 |
+
var r = null != arguments[n] ? arguments[n] : {}
|
| 207 |
+
n % 2
|
| 208 |
+
? e(Object(r), !0).forEach(function (e) {
|
| 209 |
+
t(i, e, r[e])
|
| 210 |
+
})
|
| 211 |
+
: Object.getOwnPropertyDescriptors
|
| 212 |
+
? Object.defineProperties(i, Object.getOwnPropertyDescriptors(r))
|
| 213 |
+
: e(Object(r)).forEach(function (t) {
|
| 214 |
+
Object.defineProperty(i, t, Object.getOwnPropertyDescriptor(r, t))
|
| 215 |
+
})
|
| 216 |
+
}
|
| 217 |
+
return i
|
| 218 |
+
}
|
| 219 |
+
function n() {
|
| 220 |
+
return new Promise((t) => {
|
| 221 |
+
'loading' == document.readyState ? document.addEventListener('DOMContentLoaded', t) : t()
|
| 222 |
+
})
|
| 223 |
+
}
|
| 224 |
+
function r(t) {
|
| 225 |
+
return Array.from(new Set(t))
|
| 226 |
+
}
|
| 227 |
+
function s() {
|
| 228 |
+
return navigator.userAgent.includes('Node.js') || navigator.userAgent.includes('jsdom')
|
| 229 |
+
}
|
| 230 |
+
function o(t, e) {
|
| 231 |
+
return t == e
|
| 232 |
+
}
|
| 233 |
+
function a(t, e) {
|
| 234 |
+
'template' !== t.tagName.toLowerCase()
|
| 235 |
+
? console.warn(
|
| 236 |
+
`Alpine: [${e}] directive should only be added to <template> tags. See https://github.com/alpinejs/alpine#${e}`,
|
| 237 |
+
)
|
| 238 |
+
: 1 !== t.content.childElementCount &&
|
| 239 |
+
console.warn(
|
| 240 |
+
`Alpine: <template> tag with [${e}] encountered with multiple element roots. Make sure <template> only has a single child element.`,
|
| 241 |
+
)
|
| 242 |
+
}
|
| 243 |
+
function l(t) {
|
| 244 |
+
return t
|
| 245 |
+
.replace(/([a-z])([A-Z])/g, '$1-$2')
|
| 246 |
+
.replace(/[_\s]/, '-')
|
| 247 |
+
.toLowerCase()
|
| 248 |
+
}
|
| 249 |
+
function h(t) {
|
| 250 |
+
return t.toLowerCase().replace(/-(\w)/g, (t, e) => e.toUpperCase())
|
| 251 |
+
}
|
| 252 |
+
function u(t, e) {
|
| 253 |
+
if (!1 === e(t)) return
|
| 254 |
+
let i = t.firstElementChild
|
| 255 |
+
for (; i; ) u(i, e), (i = i.nextElementSibling)
|
| 256 |
+
}
|
| 257 |
+
function c(t, e) {
|
| 258 |
+
var i
|
| 259 |
+
return function () {
|
| 260 |
+
var n = this,
|
| 261 |
+
r = arguments,
|
| 262 |
+
s = function () {
|
| 263 |
+
;(i = null), t.apply(n, r)
|
| 264 |
+
}
|
| 265 |
+
clearTimeout(i), (i = setTimeout(s, e))
|
| 266 |
+
}
|
| 267 |
+
}
|
| 268 |
+
const d = (t, e, i) => {
|
| 269 |
+
if ((console.warn(`Alpine Error: "${i}"\n\nExpression: "${e}"\nElement:`, t), !s())) throw i
|
| 270 |
+
}
|
| 271 |
+
function f(t, { el: e, expression: i }) {
|
| 272 |
+
try {
|
| 273 |
+
const n = t()
|
| 274 |
+
return n instanceof Promise ? n.catch((t) => d(e, i, t)) : n
|
| 275 |
+
} catch (t) {
|
| 276 |
+
d(e, i, t)
|
| 277 |
+
}
|
| 278 |
+
}
|
| 279 |
+
function p(t, e, i, n = {}) {
|
| 280 |
+
return f(
|
| 281 |
+
() =>
|
| 282 |
+
'function' == typeof e
|
| 283 |
+
? e.call(i)
|
| 284 |
+
: new Function(
|
| 285 |
+
['$data', ...Object.keys(n)],
|
| 286 |
+
`var __alpine_result; with($data) { __alpine_result = ${e} }; return __alpine_result`,
|
| 287 |
+
)(i, ...Object.values(n)),
|
| 288 |
+
{ el: t, expression: e },
|
| 289 |
+
)
|
| 290 |
+
}
|
| 291 |
+
function _(t, e, i, n = {}) {
|
| 292 |
+
return f(
|
| 293 |
+
() => {
|
| 294 |
+
if ('function' == typeof e) return Promise.resolve(e.call(i, n.$event))
|
| 295 |
+
let t = Function
|
| 296 |
+
if (
|
| 297 |
+
((t = Object.getPrototypeOf(async function () {}).constructor), Object.keys(i).includes(e))
|
| 298 |
+
) {
|
| 299 |
+
let t = new Function(
|
| 300 |
+
['dataContext', ...Object.keys(n)],
|
| 301 |
+
`with(dataContext) { return ${e} }`,
|
| 302 |
+
)(i, ...Object.values(n))
|
| 303 |
+
return 'function' == typeof t ? Promise.resolve(t.call(i, n.$event)) : Promise.resolve()
|
| 304 |
+
}
|
| 305 |
+
return Promise.resolve(
|
| 306 |
+
new t(['dataContext', ...Object.keys(n)], `with(dataContext) { ${e} }`)(
|
| 307 |
+
i,
|
| 308 |
+
...Object.values(n),
|
| 309 |
+
),
|
| 310 |
+
)
|
| 311 |
+
},
|
| 312 |
+
{ el: t, expression: e },
|
| 313 |
+
)
|
| 314 |
+
}
|
| 315 |
+
const m = /^x-(on|bind|data|text|html|model|if|for|show|cloak|transition|ref|spread)\b/
|
| 316 |
+
function g(t) {
|
| 317 |
+
const e = x(t.name)
|
| 318 |
+
return m.test(e)
|
| 319 |
+
}
|
| 320 |
+
function v(t, e, i) {
|
| 321 |
+
let n = Array.from(t.attributes).filter(g).map(b),
|
| 322 |
+
r = n.filter((t) => 'spread' === t.type)[0]
|
| 323 |
+
if (r) {
|
| 324 |
+
let i = p(t, r.expression, e.$data)
|
| 325 |
+
n = n.concat(Object.entries(i).map(([t, e]) => b({ name: t, value: e })))
|
| 326 |
+
}
|
| 327 |
+
return i ? n.filter((t) => t.type === i) : y(n)
|
| 328 |
+
}
|
| 329 |
+
function y(t) {
|
| 330 |
+
let e = ['bind', 'model', 'show', 'catch-all']
|
| 331 |
+
return t.sort((t, i) => {
|
| 332 |
+
let n = -1 === e.indexOf(t.type) ? 'catch-all' : t.type,
|
| 333 |
+
r = -1 === e.indexOf(i.type) ? 'catch-all' : i.type
|
| 334 |
+
return e.indexOf(n) - e.indexOf(r)
|
| 335 |
+
})
|
| 336 |
+
}
|
| 337 |
+
function b({ name: t, value: e }) {
|
| 338 |
+
const i = x(t),
|
| 339 |
+
n = i.match(m),
|
| 340 |
+
r = i.match(/:([a-zA-Z0-9\-:]+)/),
|
| 341 |
+
s = i.match(/\.[^.\]]+(?=[^\]]*$)/g) || []
|
| 342 |
+
return {
|
| 343 |
+
type: n ? n[1] : null,
|
| 344 |
+
value: r ? r[1] : null,
|
| 345 |
+
modifiers: s.map((t) => t.replace('.', '')),
|
| 346 |
+
expression: e,
|
| 347 |
+
}
|
| 348 |
+
}
|
| 349 |
+
function w(t) {
|
| 350 |
+
return [
|
| 351 |
+
'disabled',
|
| 352 |
+
'checked',
|
| 353 |
+
'required',
|
| 354 |
+
'readonly',
|
| 355 |
+
'hidden',
|
| 356 |
+
'open',
|
| 357 |
+
'selected',
|
| 358 |
+
'autofocus',
|
| 359 |
+
'itemscope',
|
| 360 |
+
'multiple',
|
| 361 |
+
'novalidate',
|
| 362 |
+
'allowfullscreen',
|
| 363 |
+
'allowpaymentrequest',
|
| 364 |
+
'formnovalidate',
|
| 365 |
+
'autoplay',
|
| 366 |
+
'controls',
|
| 367 |
+
'loop',
|
| 368 |
+
'muted',
|
| 369 |
+
'playsinline',
|
| 370 |
+
'default',
|
| 371 |
+
'ismap',
|
| 372 |
+
'reversed',
|
| 373 |
+
'async',
|
| 374 |
+
'defer',
|
| 375 |
+
'nomodule',
|
| 376 |
+
].includes(t)
|
| 377 |
+
}
|
| 378 |
+
function x(t) {
|
| 379 |
+
return t.startsWith('@') ? t.replace('@', 'x-on:') : t.startsWith(':') ? t.replace(':', 'x-bind:') : t
|
| 380 |
+
}
|
| 381 |
+
function S(t, e = Boolean) {
|
| 382 |
+
return t.split(' ').filter(e)
|
| 383 |
+
}
|
| 384 |
+
const E = 'in',
|
| 385 |
+
T = 'out',
|
| 386 |
+
D = 'cancelled'
|
| 387 |
+
function A(t, e, i, n, r = !1) {
|
| 388 |
+
if (r) return e()
|
| 389 |
+
if (t.__x_transition && t.__x_transition.type === E) return
|
| 390 |
+
const s = v(t, n, 'transition'),
|
| 391 |
+
o = v(t, n, 'show')[0]
|
| 392 |
+
if (o && o.modifiers.includes('transition')) {
|
| 393 |
+
let n = o.modifiers
|
| 394 |
+
if (n.includes('out') && !n.includes('in')) return e()
|
| 395 |
+
const r = n.includes('in') && n.includes('out')
|
| 396 |
+
;(n = r ? n.filter((t, e) => e < n.indexOf('out')) : n), R(t, n, e, i)
|
| 397 |
+
} else s.some((t) => ['enter', 'enter-start', 'enter-end'].includes(t.value)) ? M(t, n, s, e, i) : e()
|
| 398 |
+
}
|
| 399 |
+
function k(t, e, i, n, r = !1) {
|
| 400 |
+
if (r) return e()
|
| 401 |
+
if (t.__x_transition && t.__x_transition.type === T) return
|
| 402 |
+
const s = v(t, n, 'transition'),
|
| 403 |
+
o = v(t, n, 'show')[0]
|
| 404 |
+
if (o && o.modifiers.includes('transition')) {
|
| 405 |
+
let n = o.modifiers
|
| 406 |
+
if (n.includes('in') && !n.includes('out')) return e()
|
| 407 |
+
const r = n.includes('in') && n.includes('out')
|
| 408 |
+
;(n = r ? n.filter((t, e) => e > n.indexOf('out')) : n), P(t, n, r, e, i)
|
| 409 |
+
} else s.some((t) => ['leave', 'leave-start', 'leave-end'].includes(t.value)) ? I(t, n, s, e, i) : e()
|
| 410 |
+
}
|
| 411 |
+
function R(t, e, i, n) {
|
| 412 |
+
L(
|
| 413 |
+
t,
|
| 414 |
+
e,
|
| 415 |
+
i,
|
| 416 |
+
() => {},
|
| 417 |
+
n,
|
| 418 |
+
{
|
| 419 |
+
duration: O(e, 'duration', 150),
|
| 420 |
+
origin: O(e, 'origin', 'center'),
|
| 421 |
+
first: { opacity: 0, scale: O(e, 'scale', 95) },
|
| 422 |
+
second: { opacity: 1, scale: 100 },
|
| 423 |
+
},
|
| 424 |
+
E,
|
| 425 |
+
)
|
| 426 |
+
}
|
| 427 |
+
function P(t, e, i, n, r) {
|
| 428 |
+
L(
|
| 429 |
+
t,
|
| 430 |
+
e,
|
| 431 |
+
() => {},
|
| 432 |
+
n,
|
| 433 |
+
r,
|
| 434 |
+
{
|
| 435 |
+
duration: i ? O(e, 'duration', 150) : O(e, 'duration', 150) / 2,
|
| 436 |
+
origin: O(e, 'origin', 'center'),
|
| 437 |
+
first: { opacity: 1, scale: 100 },
|
| 438 |
+
second: { opacity: 0, scale: O(e, 'scale', 95) },
|
| 439 |
+
},
|
| 440 |
+
T,
|
| 441 |
+
)
|
| 442 |
+
}
|
| 443 |
+
function O(t, e, i) {
|
| 444 |
+
if (-1 === t.indexOf(e)) return i
|
| 445 |
+
const n = t[t.indexOf(e) + 1]
|
| 446 |
+
if (!n) return i
|
| 447 |
+
if ('scale' === e && !j(n)) return i
|
| 448 |
+
if ('duration' === e) {
|
| 449 |
+
let t = n.match(/([0-9]+)ms/)
|
| 450 |
+
if (t) return t[1]
|
| 451 |
+
}
|
| 452 |
+
return 'origin' === e && ['top', 'right', 'left', 'center', 'bottom'].includes(t[t.indexOf(e) + 2])
|
| 453 |
+
? [n, t[t.indexOf(e) + 2]].join(' ')
|
| 454 |
+
: n
|
| 455 |
+
}
|
| 456 |
+
function L(t, e, i, n, r, s, o) {
|
| 457 |
+
t.__x_transition && t.__x_transition.cancel && t.__x_transition.cancel()
|
| 458 |
+
const a = t.style.opacity,
|
| 459 |
+
l = t.style.transform,
|
| 460 |
+
h = t.style.transformOrigin,
|
| 461 |
+
u = !e.includes('opacity') && !e.includes('scale'),
|
| 462 |
+
c = u || e.includes('opacity'),
|
| 463 |
+
d = u || e.includes('scale'),
|
| 464 |
+
f = {
|
| 465 |
+
start() {
|
| 466 |
+
c && (t.style.opacity = s.first.opacity),
|
| 467 |
+
d && (t.style.transform = `scale(${s.first.scale / 100})`)
|
| 468 |
+
},
|
| 469 |
+
during() {
|
| 470 |
+
d && (t.style.transformOrigin = s.origin),
|
| 471 |
+
(t.style.transitionProperty = [c ? 'opacity' : '', d ? 'transform' : '']
|
| 472 |
+
.join(' ')
|
| 473 |
+
.trim()),
|
| 474 |
+
(t.style.transitionDuration = s.duration / 1e3 + 's'),
|
| 475 |
+
(t.style.transitionTimingFunction = 'cubic-bezier(0.4, 0.0, 0.2, 1)')
|
| 476 |
+
},
|
| 477 |
+
show() {
|
| 478 |
+
i()
|
| 479 |
+
},
|
| 480 |
+
end() {
|
| 481 |
+
c && (t.style.opacity = s.second.opacity),
|
| 482 |
+
d && (t.style.transform = `scale(${s.second.scale / 100})`)
|
| 483 |
+
},
|
| 484 |
+
hide() {
|
| 485 |
+
n()
|
| 486 |
+
},
|
| 487 |
+
cleanup() {
|
| 488 |
+
c && (t.style.opacity = a),
|
| 489 |
+
d && (t.style.transform = l),
|
| 490 |
+
d && (t.style.transformOrigin = h),
|
| 491 |
+
(t.style.transitionProperty = null),
|
| 492 |
+
(t.style.transitionDuration = null),
|
| 493 |
+
(t.style.transitionTimingFunction = null)
|
| 494 |
+
},
|
| 495 |
+
}
|
| 496 |
+
q(t, f, o, r)
|
| 497 |
+
}
|
| 498 |
+
const C = (t, e, i) => ('function' == typeof t ? i.evaluateReturnExpression(e, t) : t)
|
| 499 |
+
function M(t, e, i, n, r) {
|
| 500 |
+
N(
|
| 501 |
+
t,
|
| 502 |
+
S(C((i.find((t) => 'enter' === t.value) || { expression: '' }).expression, t, e)),
|
| 503 |
+
S(C((i.find((t) => 'enter-start' === t.value) || { expression: '' }).expression, t, e)),
|
| 504 |
+
S(C((i.find((t) => 'enter-end' === t.value) || { expression: '' }).expression, t, e)),
|
| 505 |
+
n,
|
| 506 |
+
() => {},
|
| 507 |
+
E,
|
| 508 |
+
r,
|
| 509 |
+
)
|
| 510 |
+
}
|
| 511 |
+
function I(t, e, i, n, r) {
|
| 512 |
+
N(
|
| 513 |
+
t,
|
| 514 |
+
S(C((i.find((t) => 'leave' === t.value) || { expression: '' }).expression, t, e)),
|
| 515 |
+
S(C((i.find((t) => 'leave-start' === t.value) || { expression: '' }).expression, t, e)),
|
| 516 |
+
S(C((i.find((t) => 'leave-end' === t.value) || { expression: '' }).expression, t, e)),
|
| 517 |
+
() => {},
|
| 518 |
+
n,
|
| 519 |
+
T,
|
| 520 |
+
r,
|
| 521 |
+
)
|
| 522 |
+
}
|
| 523 |
+
function N(t, e, i, n, r, s, o, a) {
|
| 524 |
+
t.__x_transition && t.__x_transition.cancel && t.__x_transition.cancel()
|
| 525 |
+
const l = t.__x_original_classes || [],
|
| 526 |
+
h = {
|
| 527 |
+
start() {
|
| 528 |
+
t.classList.add(...i)
|
| 529 |
+
},
|
| 530 |
+
during() {
|
| 531 |
+
t.classList.add(...e)
|
| 532 |
+
},
|
| 533 |
+
show() {
|
| 534 |
+
r()
|
| 535 |
+
},
|
| 536 |
+
end() {
|
| 537 |
+
t.classList.remove(...i.filter((t) => !l.includes(t))), t.classList.add(...n)
|
| 538 |
+
},
|
| 539 |
+
hide() {
|
| 540 |
+
s()
|
| 541 |
+
},
|
| 542 |
+
cleanup() {
|
| 543 |
+
t.classList.remove(...e.filter((t) => !l.includes(t))),
|
| 544 |
+
t.classList.remove(...n.filter((t) => !l.includes(t)))
|
| 545 |
+
},
|
| 546 |
+
}
|
| 547 |
+
q(t, h, o, a)
|
| 548 |
+
}
|
| 549 |
+
function q(t, e, i, n) {
|
| 550 |
+
const r = X(() => {
|
| 551 |
+
e.hide(), t.isConnected && e.cleanup(), delete t.__x_transition
|
| 552 |
+
})
|
| 553 |
+
;(t.__x_transition = {
|
| 554 |
+
type: i,
|
| 555 |
+
cancel: X(() => {
|
| 556 |
+
n(D), r()
|
| 557 |
+
}),
|
| 558 |
+
finish: r,
|
| 559 |
+
nextFrame: null,
|
| 560 |
+
}),
|
| 561 |
+
e.start(),
|
| 562 |
+
e.during(),
|
| 563 |
+
(t.__x_transition.nextFrame = requestAnimationFrame(() => {
|
| 564 |
+
let i = 1e3 * Number(getComputedStyle(t).transitionDuration.replace(/,.*/, '').replace('s', ''))
|
| 565 |
+
0 === i && (i = 1e3 * Number(getComputedStyle(t).animationDuration.replace('s', ''))),
|
| 566 |
+
e.show(),
|
| 567 |
+
(t.__x_transition.nextFrame = requestAnimationFrame(() => {
|
| 568 |
+
e.end(), setTimeout(t.__x_transition.finish, i)
|
| 569 |
+
}))
|
| 570 |
+
}))
|
| 571 |
+
}
|
| 572 |
+
function j(t) {
|
| 573 |
+
return !Array.isArray(t) && !isNaN(t)
|
| 574 |
+
}
|
| 575 |
+
function X(t) {
|
| 576 |
+
let e = !1
|
| 577 |
+
return function () {
|
| 578 |
+
e || ((e = !0), t.apply(this, arguments))
|
| 579 |
+
}
|
| 580 |
+
}
|
| 581 |
+
function F(t, e, i, n, r) {
|
| 582 |
+
a(e, 'x-for')
|
| 583 |
+
let s = H('function' == typeof i ? t.evaluateReturnExpression(e, i) : i),
|
| 584 |
+
o = z(t, e, s, r),
|
| 585 |
+
l = e
|
| 586 |
+
o.forEach((i, a) => {
|
| 587 |
+
let h = Y(s, i, a, o, r()),
|
| 588 |
+
u = B(t, e, a, h),
|
| 589 |
+
c = $(l.nextElementSibling, u)
|
| 590 |
+
c
|
| 591 |
+
? (delete c.__x_for_key, (c.__x_for = h), t.updateElements(c, () => c.__x_for))
|
| 592 |
+
: ((c = W(e, l)),
|
| 593 |
+
A(
|
| 594 |
+
c,
|
| 595 |
+
() => {},
|
| 596 |
+
() => {},
|
| 597 |
+
t,
|
| 598 |
+
n,
|
| 599 |
+
),
|
| 600 |
+
(c.__x_for = h),
|
| 601 |
+
t.initializeElements(c, () => c.__x_for)),
|
| 602 |
+
(l = c),
|
| 603 |
+
(l.__x_for_key = u)
|
| 604 |
+
}),
|
| 605 |
+
G(l, t)
|
| 606 |
+
}
|
| 607 |
+
function H(t) {
|
| 608 |
+
let e = /,([^,\}\]]*)(?:,([^,\}\]]*))?$/,
|
| 609 |
+
i = /^\(|\)$/g,
|
| 610 |
+
n = /([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,
|
| 611 |
+
r = t.match(n)
|
| 612 |
+
if (!r) return
|
| 613 |
+
let s = {}
|
| 614 |
+
s.items = r[2].trim()
|
| 615 |
+
let o = r[1].trim().replace(i, ''),
|
| 616 |
+
a = o.match(e)
|
| 617 |
+
return (
|
| 618 |
+
a
|
| 619 |
+
? ((s.item = o.replace(e, '').trim()),
|
| 620 |
+
(s.index = a[1].trim()),
|
| 621 |
+
a[2] && (s.collection = a[2].trim()))
|
| 622 |
+
: (s.item = o),
|
| 623 |
+
s
|
| 624 |
+
)
|
| 625 |
+
}
|
| 626 |
+
function Y(t, e, n, r, s) {
|
| 627 |
+
let o = s ? i({}, s) : {}
|
| 628 |
+
return (o[t.item] = e), t.index && (o[t.index] = n), t.collection && (o[t.collection] = r), o
|
| 629 |
+
}
|
| 630 |
+
function B(t, e, i, n) {
|
| 631 |
+
let r = v(e, t, 'bind').filter((t) => 'key' === t.value)[0]
|
| 632 |
+
return r ? t.evaluateReturnExpression(e, r.expression, () => n) : i
|
| 633 |
+
}
|
| 634 |
+
function z(t, e, i, n) {
|
| 635 |
+
let r = v(e, t, 'if')[0]
|
| 636 |
+
if (r && !t.evaluateReturnExpression(e, r.expression)) return []
|
| 637 |
+
let s = t.evaluateReturnExpression(e, i.items, n)
|
| 638 |
+
return j(s) && s > 0 && (s = Array.from(Array(s).keys(), (t) => t + 1)), s
|
| 639 |
+
}
|
| 640 |
+
function W(t, e) {
|
| 641 |
+
let i = document.importNode(t.content, !0)
|
| 642 |
+
return e.parentElement.insertBefore(i, e.nextElementSibling), e.nextElementSibling
|
| 643 |
+
}
|
| 644 |
+
function $(t, e) {
|
| 645 |
+
if (!t) return
|
| 646 |
+
if (void 0 === t.__x_for_key) return
|
| 647 |
+
if (t.__x_for_key === e) return t
|
| 648 |
+
let i = t
|
| 649 |
+
for (; i; ) {
|
| 650 |
+
if (i.__x_for_key === e) return i.parentElement.insertBefore(i, t)
|
| 651 |
+
i = !(!i.nextElementSibling || void 0 === i.nextElementSibling.__x_for_key) && i.nextElementSibling
|
| 652 |
+
}
|
| 653 |
+
}
|
| 654 |
+
function G(t, e) {
|
| 655 |
+
for (
|
| 656 |
+
var i =
|
| 657 |
+
!(!t.nextElementSibling || void 0 === t.nextElementSibling.__x_for_key) && t.nextElementSibling;
|
| 658 |
+
i;
|
| 659 |
+
|
| 660 |
+
) {
|
| 661 |
+
let t = i,
|
| 662 |
+
n = i.nextElementSibling
|
| 663 |
+
k(
|
| 664 |
+
i,
|
| 665 |
+
() => {
|
| 666 |
+
t.remove()
|
| 667 |
+
},
|
| 668 |
+
() => {},
|
| 669 |
+
e,
|
| 670 |
+
),
|
| 671 |
+
(i = !(!n || void 0 === n.__x_for_key) && n)
|
| 672 |
+
}
|
| 673 |
+
}
|
| 674 |
+
function U(t, e, i, n, s, a, l) {
|
| 675 |
+
var u = t.evaluateReturnExpression(e, n, s)
|
| 676 |
+
if ('value' === i) {
|
| 677 |
+
if ($t.ignoreFocusedForValueBinding && document.activeElement.isSameNode(e)) return
|
| 678 |
+
if ((void 0 === u && n.match(/\./) && (u = ''), 'radio' === e.type))
|
| 679 |
+
void 0 === e.attributes.value && 'bind' === a
|
| 680 |
+
? (e.value = u)
|
| 681 |
+
: 'bind' !== a && (e.checked = o(e.value, u))
|
| 682 |
+
else if ('checkbox' === e.type)
|
| 683 |
+
'boolean' == typeof u || [null, void 0].includes(u) || 'bind' !== a
|
| 684 |
+
? 'bind' !== a &&
|
| 685 |
+
(Array.isArray(u) ? (e.checked = u.some((t) => o(t, e.value))) : (e.checked = !!u))
|
| 686 |
+
: (e.value = String(u))
|
| 687 |
+
else if ('SELECT' === e.tagName) J(e, u)
|
| 688 |
+
else {
|
| 689 |
+
if (e.value === u) return
|
| 690 |
+
e.value = u
|
| 691 |
+
}
|
| 692 |
+
} else if ('class' === i)
|
| 693 |
+
if (Array.isArray(u)) {
|
| 694 |
+
const t = e.__x_original_classes || []
|
| 695 |
+
e.setAttribute('class', r(t.concat(u)).join(' '))
|
| 696 |
+
} else if ('object' == typeof u)
|
| 697 |
+
Object.keys(u)
|
| 698 |
+
.sort((t, e) => u[t] - u[e])
|
| 699 |
+
.forEach((t) => {
|
| 700 |
+
u[t]
|
| 701 |
+
? S(t).forEach((t) => e.classList.add(t))
|
| 702 |
+
: S(t).forEach((t) => e.classList.remove(t))
|
| 703 |
+
})
|
| 704 |
+
else {
|
| 705 |
+
const t = e.__x_original_classes || [],
|
| 706 |
+
i = u ? S(u) : []
|
| 707 |
+
e.setAttribute('class', r(t.concat(i)).join(' '))
|
| 708 |
+
}
|
| 709 |
+
else
|
| 710 |
+
(i = l.includes('camel') ? h(i) : i),
|
| 711 |
+
[null, void 0, !1].includes(u) ? e.removeAttribute(i) : w(i) ? V(e, i, i) : V(e, i, u)
|
| 712 |
+
}
|
| 713 |
+
function V(t, e, i) {
|
| 714 |
+
t.getAttribute(e) != i && t.setAttribute(e, i)
|
| 715 |
+
}
|
| 716 |
+
function J(t, e) {
|
| 717 |
+
const i = [].concat(e).map((t) => t + '')
|
| 718 |
+
Array.from(t.options).forEach((t) => {
|
| 719 |
+
t.selected = i.includes(t.value || t.text)
|
| 720 |
+
})
|
| 721 |
+
}
|
| 722 |
+
function K(t, e, i) {
|
| 723 |
+
void 0 === e && i.match(/\./) && (e = ''), (t.textContent = e)
|
| 724 |
+
}
|
| 725 |
+
function Q(t, e, i, n) {
|
| 726 |
+
e.innerHTML = t.evaluateReturnExpression(e, i, n)
|
| 727 |
+
}
|
| 728 |
+
function Z(t, e, i, n, r = !1) {
|
| 729 |
+
const s = () => {
|
| 730 |
+
;(e.style.display = 'none'), (e.__x_is_shown = !1)
|
| 731 |
+
},
|
| 732 |
+
o = () => {
|
| 733 |
+
1 === e.style.length && 'none' === e.style.display
|
| 734 |
+
? e.removeAttribute('style')
|
| 735 |
+
: e.style.removeProperty('display'),
|
| 736 |
+
(e.__x_is_shown = !0)
|
| 737 |
+
}
|
| 738 |
+
if (!0 === r) return void (i ? o() : s())
|
| 739 |
+
const a = (n, r) => {
|
| 740 |
+
i
|
| 741 |
+
? (('none' === e.style.display || e.__x_transition) &&
|
| 742 |
+
A(
|
| 743 |
+
e,
|
| 744 |
+
() => {
|
| 745 |
+
o()
|
| 746 |
+
},
|
| 747 |
+
r,
|
| 748 |
+
t,
|
| 749 |
+
),
|
| 750 |
+
n(() => {}))
|
| 751 |
+
: 'none' !== e.style.display
|
| 752 |
+
? k(
|
| 753 |
+
e,
|
| 754 |
+
() => {
|
| 755 |
+
n(() => {
|
| 756 |
+
s()
|
| 757 |
+
})
|
| 758 |
+
},
|
| 759 |
+
r,
|
| 760 |
+
t,
|
| 761 |
+
)
|
| 762 |
+
: n(() => {})
|
| 763 |
+
}
|
| 764 |
+
n.includes('immediate')
|
| 765 |
+
? a(
|
| 766 |
+
(t) => t(),
|
| 767 |
+
() => {},
|
| 768 |
+
)
|
| 769 |
+
: (t.showDirectiveLastElement &&
|
| 770 |
+
!t.showDirectiveLastElement.contains(e) &&
|
| 771 |
+
t.executeAndClearRemainingShowDirectiveStack(),
|
| 772 |
+
t.showDirectiveStack.push(a),
|
| 773 |
+
(t.showDirectiveLastElement = e))
|
| 774 |
+
}
|
| 775 |
+
function tt(t, e, i, n, r) {
|
| 776 |
+
a(e, 'x-if')
|
| 777 |
+
const s = e.nextElementSibling && !0 === e.nextElementSibling.__x_inserted_me
|
| 778 |
+
if (!i || (s && !e.__x_transition))
|
| 779 |
+
!i &&
|
| 780 |
+
s &&
|
| 781 |
+
k(
|
| 782 |
+
e.nextElementSibling,
|
| 783 |
+
() => {
|
| 784 |
+
e.nextElementSibling.remove()
|
| 785 |
+
},
|
| 786 |
+
() => {},
|
| 787 |
+
t,
|
| 788 |
+
n,
|
| 789 |
+
)
|
| 790 |
+
else {
|
| 791 |
+
const i = document.importNode(e.content, !0)
|
| 792 |
+
e.parentElement.insertBefore(i, e.nextElementSibling),
|
| 793 |
+
A(
|
| 794 |
+
e.nextElementSibling,
|
| 795 |
+
() => {},
|
| 796 |
+
() => {},
|
| 797 |
+
t,
|
| 798 |
+
n,
|
| 799 |
+
),
|
| 800 |
+
t.initializeElements(e.nextElementSibling, r),
|
| 801 |
+
(e.nextElementSibling.__x_inserted_me = !0)
|
| 802 |
+
}
|
| 803 |
+
}
|
| 804 |
+
function et(t, e, i, n, r, s = {}) {
|
| 805 |
+
const o = { passive: n.includes('passive') }
|
| 806 |
+
if ((n.includes('camel') && (i = h(i)), n.includes('away'))) {
|
| 807 |
+
let a = (l) => {
|
| 808 |
+
e.contains(l.target) ||
|
| 809 |
+
(e.offsetWidth < 1 && e.offsetHeight < 1) ||
|
| 810 |
+
(it(t, r, l, s), n.includes('once') && document.removeEventListener(i, a, o))
|
| 811 |
+
}
|
| 812 |
+
document.addEventListener(i, a, o)
|
| 813 |
+
} else {
|
| 814 |
+
let a = n.includes('window') ? window : n.includes('document') ? document : e,
|
| 815 |
+
l = (h) => {
|
| 816 |
+
;(a !== window && a !== document) || document.body.contains(e)
|
| 817 |
+
? (nt(i) && rt(h, n)) ||
|
| 818 |
+
(n.includes('prevent') && h.preventDefault(),
|
| 819 |
+
n.includes('stop') && h.stopPropagation(),
|
| 820 |
+
n.includes('self') && h.target !== e) ||
|
| 821 |
+
it(t, r, h, s).then((t) => {
|
| 822 |
+
!1 === t
|
| 823 |
+
? h.preventDefault()
|
| 824 |
+
: n.includes('once') && a.removeEventListener(i, l, o)
|
| 825 |
+
})
|
| 826 |
+
: a.removeEventListener(i, l, o)
|
| 827 |
+
}
|
| 828 |
+
if (n.includes('debounce')) {
|
| 829 |
+
let t = n[n.indexOf('debounce') + 1] || 'invalid-wait',
|
| 830 |
+
e = j(t.split('ms')[0]) ? Number(t.split('ms')[0]) : 250
|
| 831 |
+
l = c(l, e)
|
| 832 |
+
}
|
| 833 |
+
a.addEventListener(i, l, o)
|
| 834 |
+
}
|
| 835 |
+
}
|
| 836 |
+
function it(t, e, n, r) {
|
| 837 |
+
return t.evaluateCommandExpression(n.target, e, () => i(i({}, r()), {}, { $event: n }))
|
| 838 |
+
}
|
| 839 |
+
function nt(t) {
|
| 840 |
+
return ['keydown', 'keyup'].includes(t)
|
| 841 |
+
}
|
| 842 |
+
function rt(t, e) {
|
| 843 |
+
let i = e.filter((t) => !['window', 'document', 'prevent', 'stop'].includes(t))
|
| 844 |
+
if (i.includes('debounce')) {
|
| 845 |
+
let t = i.indexOf('debounce')
|
| 846 |
+
i.splice(t, j((i[t + 1] || 'invalid-wait').split('ms')[0]) ? 2 : 1)
|
| 847 |
+
}
|
| 848 |
+
if (0 === i.length) return !1
|
| 849 |
+
if (1 === i.length && i[0] === st(t.key)) return !1
|
| 850 |
+
const n = ['ctrl', 'shift', 'alt', 'meta', 'cmd', 'super'].filter((t) => i.includes(t))
|
| 851 |
+
return (
|
| 852 |
+
(i = i.filter((t) => !n.includes(t))),
|
| 853 |
+
!(
|
| 854 |
+
n.length > 0 &&
|
| 855 |
+
n.filter((e) => (('cmd' !== e && 'super' !== e) || (e = 'meta'), t[`${e}Key`])).length ===
|
| 856 |
+
n.length &&
|
| 857 |
+
i[0] === st(t.key)
|
| 858 |
+
)
|
| 859 |
+
)
|
| 860 |
+
}
|
| 861 |
+
function st(t) {
|
| 862 |
+
switch (t) {
|
| 863 |
+
case '/':
|
| 864 |
+
return 'slash'
|
| 865 |
+
case ' ':
|
| 866 |
+
case 'Spacebar':
|
| 867 |
+
return 'space'
|
| 868 |
+
default:
|
| 869 |
+
return t && l(t)
|
| 870 |
+
}
|
| 871 |
+
}
|
| 872 |
+
function ot(t, e, n, r, s) {
|
| 873 |
+
var o =
|
| 874 |
+
'select' === e.tagName.toLowerCase() || ['checkbox', 'radio'].includes(e.type) || n.includes('lazy')
|
| 875 |
+
? 'change'
|
| 876 |
+
: 'input'
|
| 877 |
+
et(t, e, o, n, `${r} = rightSideOfExpression($event, ${r})`, () =>
|
| 878 |
+
i(i({}, s()), {}, { rightSideOfExpression: at(e, n, r) }),
|
| 879 |
+
)
|
| 880 |
+
}
|
| 881 |
+
function at(t, e, i) {
|
| 882 |
+
return (
|
| 883 |
+
'radio' === t.type && (t.hasAttribute('name') || t.setAttribute('name', i)),
|
| 884 |
+
(i, n) => {
|
| 885 |
+
if (i instanceof CustomEvent && i.detail) return i.detail
|
| 886 |
+
if ('checkbox' === t.type) {
|
| 887 |
+
if (Array.isArray(n)) {
|
| 888 |
+
const t = e.includes('number') ? lt(i.target.value) : i.target.value
|
| 889 |
+
return i.target.checked ? n.concat([t]) : n.filter((e) => !o(e, t))
|
| 890 |
+
}
|
| 891 |
+
return i.target.checked
|
| 892 |
+
}
|
| 893 |
+
if ('select' === t.tagName.toLowerCase() && t.multiple)
|
| 894 |
+
return e.includes('number')
|
| 895 |
+
? Array.from(i.target.selectedOptions).map((t) => lt(t.value || t.text))
|
| 896 |
+
: Array.from(i.target.selectedOptions).map((t) => t.value || t.text)
|
| 897 |
+
{
|
| 898 |
+
const t = i.target.value
|
| 899 |
+
return e.includes('number') ? lt(t) : e.includes('trim') ? t.trim() : t
|
| 900 |
+
}
|
| 901 |
+
}
|
| 902 |
+
)
|
| 903 |
+
}
|
| 904 |
+
function lt(t) {
|
| 905 |
+
const e = t ? parseFloat(t) : null
|
| 906 |
+
return j(e) ? e : t
|
| 907 |
+
}
|
| 908 |
+
const { isArray: ht } = Array,
|
| 909 |
+
{
|
| 910 |
+
getPrototypeOf: ut,
|
| 911 |
+
create: ct,
|
| 912 |
+
defineProperty: dt,
|
| 913 |
+
defineProperties: ft,
|
| 914 |
+
isExtensible: pt,
|
| 915 |
+
getOwnPropertyDescriptor: _t,
|
| 916 |
+
getOwnPropertyNames: mt,
|
| 917 |
+
getOwnPropertySymbols: gt,
|
| 918 |
+
preventExtensions: vt,
|
| 919 |
+
hasOwnProperty: yt,
|
| 920 |
+
} = Object,
|
| 921 |
+
{ push: bt, concat: wt, map: xt } = Array.prototype
|
| 922 |
+
function St(t) {
|
| 923 |
+
return void 0 === t
|
| 924 |
+
}
|
| 925 |
+
function Et(t) {
|
| 926 |
+
return 'function' == typeof t
|
| 927 |
+
}
|
| 928 |
+
function Tt(t) {
|
| 929 |
+
return 'object' == typeof t
|
| 930 |
+
}
|
| 931 |
+
const Dt = new WeakMap()
|
| 932 |
+
function At(t, e) {
|
| 933 |
+
Dt.set(t, e)
|
| 934 |
+
}
|
| 935 |
+
const kt = (t) => Dt.get(t) || t
|
| 936 |
+
function Rt(t, e) {
|
| 937 |
+
return t.valueIsObservable(e) ? t.getProxy(e) : e
|
| 938 |
+
}
|
| 939 |
+
function Pt(t) {
|
| 940 |
+
return yt.call(t, 'value') && (t.value = kt(t.value)), t
|
| 941 |
+
}
|
| 942 |
+
function Ot(t, e, i) {
|
| 943 |
+
wt.call(mt(i), gt(i)).forEach((n) => {
|
| 944 |
+
let r = _t(i, n)
|
| 945 |
+
r.configurable || (r = Ht(t, r, Rt)), dt(e, n, r)
|
| 946 |
+
}),
|
| 947 |
+
vt(e)
|
| 948 |
+
}
|
| 949 |
+
class Lt {
|
| 950 |
+
constructor(t, e) {
|
| 951 |
+
;(this.originalTarget = e), (this.membrane = t)
|
| 952 |
+
}
|
| 953 |
+
get(t, e) {
|
| 954 |
+
const { originalTarget: i, membrane: n } = this,
|
| 955 |
+
r = i[e],
|
| 956 |
+
{ valueObserved: s } = n
|
| 957 |
+
return s(i, e), n.getProxy(r)
|
| 958 |
+
}
|
| 959 |
+
set(t, e, i) {
|
| 960 |
+
const {
|
| 961 |
+
originalTarget: n,
|
| 962 |
+
membrane: { valueMutated: r },
|
| 963 |
+
} = this
|
| 964 |
+
return n[e] !== i ? ((n[e] = i), r(n, e)) : 'length' === e && ht(n) && r(n, e), !0
|
| 965 |
+
}
|
| 966 |
+
deleteProperty(t, e) {
|
| 967 |
+
const {
|
| 968 |
+
originalTarget: i,
|
| 969 |
+
membrane: { valueMutated: n },
|
| 970 |
+
} = this
|
| 971 |
+
return delete i[e], n(i, e), !0
|
| 972 |
+
}
|
| 973 |
+
apply(t, e, i) {}
|
| 974 |
+
construct(t, e, i) {}
|
| 975 |
+
has(t, e) {
|
| 976 |
+
const {
|
| 977 |
+
originalTarget: i,
|
| 978 |
+
membrane: { valueObserved: n },
|
| 979 |
+
} = this
|
| 980 |
+
return n(i, e), e in i
|
| 981 |
+
}
|
| 982 |
+
ownKeys(t) {
|
| 983 |
+
const { originalTarget: e } = this
|
| 984 |
+
return wt.call(mt(e), gt(e))
|
| 985 |
+
}
|
| 986 |
+
isExtensible(t) {
|
| 987 |
+
const e = pt(t)
|
| 988 |
+
if (!e) return e
|
| 989 |
+
const { originalTarget: i, membrane: n } = this,
|
| 990 |
+
r = pt(i)
|
| 991 |
+
return r || Ot(n, t, i), r
|
| 992 |
+
}
|
| 993 |
+
setPrototypeOf(t, e) {}
|
| 994 |
+
getPrototypeOf(t) {
|
| 995 |
+
const { originalTarget: e } = this
|
| 996 |
+
return ut(e)
|
| 997 |
+
}
|
| 998 |
+
getOwnPropertyDescriptor(t, e) {
|
| 999 |
+
const { originalTarget: i, membrane: n } = this,
|
| 1000 |
+
{ valueObserved: r } = this.membrane
|
| 1001 |
+
r(i, e)
|
| 1002 |
+
let s = _t(i, e)
|
| 1003 |
+
if (St(s)) return s
|
| 1004 |
+
const o = _t(t, e)
|
| 1005 |
+
return St(o) ? ((s = Ht(n, s, Rt)), s.configurable || dt(t, e, s), s) : o
|
| 1006 |
+
}
|
| 1007 |
+
preventExtensions(t) {
|
| 1008 |
+
const { originalTarget: e, membrane: i } = this
|
| 1009 |
+
return Ot(i, t, e), vt(e), !0
|
| 1010 |
+
}
|
| 1011 |
+
defineProperty(t, e, i) {
|
| 1012 |
+
const { originalTarget: n, membrane: r } = this,
|
| 1013 |
+
{ valueMutated: s } = r,
|
| 1014 |
+
{ configurable: o } = i
|
| 1015 |
+
if (yt.call(i, 'writable') && !yt.call(i, 'value')) {
|
| 1016 |
+
const t = _t(n, e)
|
| 1017 |
+
i.value = t.value
|
| 1018 |
+
}
|
| 1019 |
+
return dt(n, e, Pt(i)), !1 === o && dt(t, e, Ht(r, i, Rt)), s(n, e), !0
|
| 1020 |
+
}
|
| 1021 |
+
}
|
| 1022 |
+
function Ct(t, e) {
|
| 1023 |
+
return t.valueIsObservable(e) ? t.getReadOnlyProxy(e) : e
|
| 1024 |
+
}
|
| 1025 |
+
class Mt {
|
| 1026 |
+
constructor(t, e) {
|
| 1027 |
+
;(this.originalTarget = e), (this.membrane = t)
|
| 1028 |
+
}
|
| 1029 |
+
get(t, e) {
|
| 1030 |
+
const { membrane: i, originalTarget: n } = this,
|
| 1031 |
+
r = n[e],
|
| 1032 |
+
{ valueObserved: s } = i
|
| 1033 |
+
return s(n, e), i.getReadOnlyProxy(r)
|
| 1034 |
+
}
|
| 1035 |
+
set(t, e, i) {
|
| 1036 |
+
return !1
|
| 1037 |
+
}
|
| 1038 |
+
deleteProperty(t, e) {
|
| 1039 |
+
return !1
|
| 1040 |
+
}
|
| 1041 |
+
apply(t, e, i) {}
|
| 1042 |
+
construct(t, e, i) {}
|
| 1043 |
+
has(t, e) {
|
| 1044 |
+
const {
|
| 1045 |
+
originalTarget: i,
|
| 1046 |
+
membrane: { valueObserved: n },
|
| 1047 |
+
} = this
|
| 1048 |
+
return n(i, e), e in i
|
| 1049 |
+
}
|
| 1050 |
+
ownKeys(t) {
|
| 1051 |
+
const { originalTarget: e } = this
|
| 1052 |
+
return wt.call(mt(e), gt(e))
|
| 1053 |
+
}
|
| 1054 |
+
setPrototypeOf(t, e) {}
|
| 1055 |
+
getOwnPropertyDescriptor(t, e) {
|
| 1056 |
+
const { originalTarget: i, membrane: n } = this,
|
| 1057 |
+
{ valueObserved: r } = n
|
| 1058 |
+
r(i, e)
|
| 1059 |
+
let s = _t(i, e)
|
| 1060 |
+
if (St(s)) return s
|
| 1061 |
+
const o = _t(t, e)
|
| 1062 |
+
return St(o)
|
| 1063 |
+
? ((s = Ht(n, s, Ct)), yt.call(s, 'set') && (s.set = void 0), s.configurable || dt(t, e, s), s)
|
| 1064 |
+
: o
|
| 1065 |
+
}
|
| 1066 |
+
preventExtensions(t) {
|
| 1067 |
+
return !1
|
| 1068 |
+
}
|
| 1069 |
+
defineProperty(t, e, i) {
|
| 1070 |
+
return !1
|
| 1071 |
+
}
|
| 1072 |
+
}
|
| 1073 |
+
function It(t) {
|
| 1074 |
+
let e
|
| 1075 |
+
return ht(t) ? (e = []) : Tt(t) && (e = {}), e
|
| 1076 |
+
}
|
| 1077 |
+
const Nt = Object.prototype
|
| 1078 |
+
function qt(t) {
|
| 1079 |
+
if (null === t) return !1
|
| 1080 |
+
if ('object' != typeof t) return !1
|
| 1081 |
+
if (ht(t)) return !0
|
| 1082 |
+
const e = ut(t)
|
| 1083 |
+
return e === Nt || null === e || null === ut(e)
|
| 1084 |
+
}
|
| 1085 |
+
const jt = (t, e) => {},
|
| 1086 |
+
Xt = (t, e) => {},
|
| 1087 |
+
Ft = (t) => t
|
| 1088 |
+
function Ht(t, e, i) {
|
| 1089 |
+
const { set: n, get: r } = e
|
| 1090 |
+
return (
|
| 1091 |
+
yt.call(e, 'value')
|
| 1092 |
+
? (e.value = i(t, e.value))
|
| 1093 |
+
: (St(r) ||
|
| 1094 |
+
(e.get = function () {
|
| 1095 |
+
return i(t, r.call(kt(this)))
|
| 1096 |
+
}),
|
| 1097 |
+
St(n) ||
|
| 1098 |
+
(e.set = function (e) {
|
| 1099 |
+
n.call(kt(this), t.unwrapProxy(e))
|
| 1100 |
+
})),
|
| 1101 |
+
e
|
| 1102 |
+
)
|
| 1103 |
+
}
|
| 1104 |
+
class Yt {
|
| 1105 |
+
constructor(t) {
|
| 1106 |
+
if (
|
| 1107 |
+
((this.valueDistortion = Ft),
|
| 1108 |
+
(this.valueMutated = Xt),
|
| 1109 |
+
(this.valueObserved = jt),
|
| 1110 |
+
(this.valueIsObservable = qt),
|
| 1111 |
+
(this.objectGraph = new WeakMap()),
|
| 1112 |
+
!St(t))
|
| 1113 |
+
) {
|
| 1114 |
+
const { valueDistortion: e, valueMutated: i, valueObserved: n, valueIsObservable: r } = t
|
| 1115 |
+
;(this.valueDistortion = Et(e) ? e : Ft),
|
| 1116 |
+
(this.valueMutated = Et(i) ? i : Xt),
|
| 1117 |
+
(this.valueObserved = Et(n) ? n : jt),
|
| 1118 |
+
(this.valueIsObservable = Et(r) ? r : qt)
|
| 1119 |
+
}
|
| 1120 |
+
}
|
| 1121 |
+
getProxy(t) {
|
| 1122 |
+
const e = kt(t),
|
| 1123 |
+
i = this.valueDistortion(e)
|
| 1124 |
+
if (this.valueIsObservable(i)) {
|
| 1125 |
+
const n = this.getReactiveState(e, i)
|
| 1126 |
+
return n.readOnly === t ? t : n.reactive
|
| 1127 |
+
}
|
| 1128 |
+
return i
|
| 1129 |
+
}
|
| 1130 |
+
getReadOnlyProxy(t) {
|
| 1131 |
+
t = kt(t)
|
| 1132 |
+
const e = this.valueDistortion(t)
|
| 1133 |
+
return this.valueIsObservable(e) ? this.getReactiveState(t, e).readOnly : e
|
| 1134 |
+
}
|
| 1135 |
+
unwrapProxy(t) {
|
| 1136 |
+
return kt(t)
|
| 1137 |
+
}
|
| 1138 |
+
getReactiveState(t, e) {
|
| 1139 |
+
const { objectGraph: i } = this
|
| 1140 |
+
let n = i.get(e)
|
| 1141 |
+
if (n) return n
|
| 1142 |
+
const r = this
|
| 1143 |
+
return (
|
| 1144 |
+
(n = {
|
| 1145 |
+
get reactive() {
|
| 1146 |
+
const i = new Lt(r, e),
|
| 1147 |
+
n = new Proxy(It(e), i)
|
| 1148 |
+
return At(n, t), dt(this, 'reactive', { value: n }), n
|
| 1149 |
+
},
|
| 1150 |
+
get readOnly() {
|
| 1151 |
+
const i = new Mt(r, e),
|
| 1152 |
+
n = new Proxy(It(e), i)
|
| 1153 |
+
return At(n, t), dt(this, 'readOnly', { value: n }), n
|
| 1154 |
+
},
|
| 1155 |
+
}),
|
| 1156 |
+
i.set(e, n),
|
| 1157 |
+
n
|
| 1158 |
+
)
|
| 1159 |
+
}
|
| 1160 |
+
}
|
| 1161 |
+
function Bt(t, e) {
|
| 1162 |
+
let i = new Yt({
|
| 1163 |
+
valueMutated(t, i) {
|
| 1164 |
+
e(t, i)
|
| 1165 |
+
},
|
| 1166 |
+
})
|
| 1167 |
+
return { data: i.getProxy(t), membrane: i }
|
| 1168 |
+
}
|
| 1169 |
+
function zt(t, e) {
|
| 1170 |
+
let i = t.unwrapProxy(e),
|
| 1171 |
+
n = {}
|
| 1172 |
+
return (
|
| 1173 |
+
Object.keys(i).forEach((t) => {
|
| 1174 |
+
;['$el', '$refs', '$nextTick', '$watch'].includes(t) || (n[t] = i[t])
|
| 1175 |
+
}),
|
| 1176 |
+
n
|
| 1177 |
+
)
|
| 1178 |
+
}
|
| 1179 |
+
class Wt {
|
| 1180 |
+
constructor(t, e = null) {
|
| 1181 |
+
this.$el = t
|
| 1182 |
+
const i = this.$el.getAttribute('x-data'),
|
| 1183 |
+
n = '' === i ? '{}' : i,
|
| 1184 |
+
r = this.$el.getAttribute('x-init')
|
| 1185 |
+
let s = { $el: this.$el },
|
| 1186 |
+
o = e ? e.$el : this.$el
|
| 1187 |
+
Object.entries($t.magicProperties).forEach(([t, e]) => {
|
| 1188 |
+
Object.defineProperty(s, `$${t}`, {
|
| 1189 |
+
get: function () {
|
| 1190 |
+
return e(o)
|
| 1191 |
+
},
|
| 1192 |
+
})
|
| 1193 |
+
}),
|
| 1194 |
+
(this.unobservedData = e ? e.getUnobservedData() : p(t, n, s))
|
| 1195 |
+
let { membrane: a, data: l } = this.wrapDataInObservable(this.unobservedData)
|
| 1196 |
+
var h
|
| 1197 |
+
;(this.$data = l),
|
| 1198 |
+
(this.membrane = a),
|
| 1199 |
+
(this.unobservedData.$el = this.$el),
|
| 1200 |
+
(this.unobservedData.$refs = this.getRefsProxy()),
|
| 1201 |
+
(this.nextTickStack = []),
|
| 1202 |
+
(this.unobservedData.$nextTick = (t) => {
|
| 1203 |
+
this.nextTickStack.push(t)
|
| 1204 |
+
}),
|
| 1205 |
+
(this.watchers = {}),
|
| 1206 |
+
(this.unobservedData.$watch = (t, e) => {
|
| 1207 |
+
this.watchers[t] || (this.watchers[t] = []), this.watchers[t].push(e)
|
| 1208 |
+
}),
|
| 1209 |
+
Object.entries($t.magicProperties).forEach(([t, e]) => {
|
| 1210 |
+
Object.defineProperty(this.unobservedData, `$${t}`, {
|
| 1211 |
+
get: function () {
|
| 1212 |
+
return e(o, this.$el)
|
| 1213 |
+
},
|
| 1214 |
+
})
|
| 1215 |
+
}),
|
| 1216 |
+
(this.showDirectiveStack = []),
|
| 1217 |
+
e || $t.onBeforeComponentInitializeds.forEach((t) => t(this)),
|
| 1218 |
+
r &&
|
| 1219 |
+
!e &&
|
| 1220 |
+
((this.pauseReactivity = !0),
|
| 1221 |
+
(h = this.evaluateReturnExpression(this.$el, r)),
|
| 1222 |
+
(this.pauseReactivity = !1)),
|
| 1223 |
+
this.initializeElements(this.$el),
|
| 1224 |
+
this.listenForNewElementsToInitialize(),
|
| 1225 |
+
'function' == typeof h && h.call(this.$data),
|
| 1226 |
+
e ||
|
| 1227 |
+
setTimeout(() => {
|
| 1228 |
+
$t.onComponentInitializeds.forEach((t) => t(this))
|
| 1229 |
+
}, 0)
|
| 1230 |
+
}
|
| 1231 |
+
getUnobservedData() {
|
| 1232 |
+
return zt(this.membrane, this.$data)
|
| 1233 |
+
}
|
| 1234 |
+
wrapDataInObservable(t) {
|
| 1235 |
+
var e = this
|
| 1236 |
+
let i = c(function () {
|
| 1237 |
+
e.updateElements(e.$el)
|
| 1238 |
+
}, 0)
|
| 1239 |
+
return Bt(t, (t, n) => {
|
| 1240 |
+
e.watchers[n]
|
| 1241 |
+
? e.watchers[n].forEach((e) => e(t[n]))
|
| 1242 |
+
: Array.isArray(t)
|
| 1243 |
+
? Object.keys(e.watchers).forEach((i) => {
|
| 1244 |
+
let r = i.split('.')
|
| 1245 |
+
'length' !== n &&
|
| 1246 |
+
r.reduce(
|
| 1247 |
+
(n, r) => (Object.is(t, n[r]) && e.watchers[i].forEach((e) => e(t)), n[r]),
|
| 1248 |
+
e.unobservedData,
|
| 1249 |
+
)
|
| 1250 |
+
})
|
| 1251 |
+
: Object.keys(e.watchers)
|
| 1252 |
+
.filter((t) => t.includes('.'))
|
| 1253 |
+
.forEach((i) => {
|
| 1254 |
+
let r = i.split('.')
|
| 1255 |
+
n === r[r.length - 1] &&
|
| 1256 |
+
r.reduce(
|
| 1257 |
+
(r, s) => (
|
| 1258 |
+
Object.is(t, r) && e.watchers[i].forEach((e) => e(t[n])), r[s]
|
| 1259 |
+
),
|
| 1260 |
+
e.unobservedData,
|
| 1261 |
+
)
|
| 1262 |
+
}),
|
| 1263 |
+
e.pauseReactivity || i()
|
| 1264 |
+
})
|
| 1265 |
+
}
|
| 1266 |
+
walkAndSkipNestedComponents(t, e, i = () => {}) {
|
| 1267 |
+
u(t, (t) => (t.hasAttribute('x-data') && !t.isSameNode(this.$el) ? (t.__x || i(t), !1) : e(t)))
|
| 1268 |
+
}
|
| 1269 |
+
initializeElements(t, e = () => {}) {
|
| 1270 |
+
this.walkAndSkipNestedComponents(
|
| 1271 |
+
t,
|
| 1272 |
+
(t) =>
|
| 1273 |
+
void 0 === t.__x_for_key &&
|
| 1274 |
+
void 0 === t.__x_inserted_me &&
|
| 1275 |
+
void this.initializeElement(t, e),
|
| 1276 |
+
(t) => {
|
| 1277 |
+
t.__x = new Wt(t)
|
| 1278 |
+
},
|
| 1279 |
+
),
|
| 1280 |
+
this.executeAndClearRemainingShowDirectiveStack(),
|
| 1281 |
+
this.executeAndClearNextTickStack(t)
|
| 1282 |
+
}
|
| 1283 |
+
initializeElement(t, e) {
|
| 1284 |
+
t.hasAttribute('class') &&
|
| 1285 |
+
v(t, this).length > 0 &&
|
| 1286 |
+
(t.__x_original_classes = S(t.getAttribute('class'))),
|
| 1287 |
+
this.registerListeners(t, e),
|
| 1288 |
+
this.resolveBoundAttributes(t, !0, e)
|
| 1289 |
+
}
|
| 1290 |
+
updateElements(t, e = () => {}) {
|
| 1291 |
+
this.walkAndSkipNestedComponents(
|
| 1292 |
+
t,
|
| 1293 |
+
(t) => {
|
| 1294 |
+
if (void 0 !== t.__x_for_key && !t.isSameNode(this.$el)) return !1
|
| 1295 |
+
this.updateElement(t, e)
|
| 1296 |
+
},
|
| 1297 |
+
(t) => {
|
| 1298 |
+
t.__x = new Wt(t)
|
| 1299 |
+
},
|
| 1300 |
+
),
|
| 1301 |
+
this.executeAndClearRemainingShowDirectiveStack(),
|
| 1302 |
+
this.executeAndClearNextTickStack(t)
|
| 1303 |
+
}
|
| 1304 |
+
executeAndClearNextTickStack(t) {
|
| 1305 |
+
t === this.$el &&
|
| 1306 |
+
this.nextTickStack.length > 0 &&
|
| 1307 |
+
requestAnimationFrame(() => {
|
| 1308 |
+
for (; this.nextTickStack.length > 0; ) this.nextTickStack.shift()()
|
| 1309 |
+
})
|
| 1310 |
+
}
|
| 1311 |
+
executeAndClearRemainingShowDirectiveStack() {
|
| 1312 |
+
this.showDirectiveStack
|
| 1313 |
+
.reverse()
|
| 1314 |
+
.map(
|
| 1315 |
+
(t) =>
|
| 1316 |
+
new Promise((e, i) => {
|
| 1317 |
+
t(e, i)
|
| 1318 |
+
}),
|
| 1319 |
+
)
|
| 1320 |
+
.reduce(
|
| 1321 |
+
(t, e) =>
|
| 1322 |
+
t.then(() =>
|
| 1323 |
+
e.then((t) => {
|
| 1324 |
+
t()
|
| 1325 |
+
}),
|
| 1326 |
+
),
|
| 1327 |
+
Promise.resolve(() => {}),
|
| 1328 |
+
)
|
| 1329 |
+
.catch((t) => {
|
| 1330 |
+
if (t !== D) throw t
|
| 1331 |
+
}),
|
| 1332 |
+
(this.showDirectiveStack = []),
|
| 1333 |
+
(this.showDirectiveLastElement = void 0)
|
| 1334 |
+
}
|
| 1335 |
+
updateElement(t, e) {
|
| 1336 |
+
this.resolveBoundAttributes(t, !1, e)
|
| 1337 |
+
}
|
| 1338 |
+
registerListeners(t, e) {
|
| 1339 |
+
v(t, this).forEach(({ type: i, value: n, modifiers: r, expression: s }) => {
|
| 1340 |
+
switch (i) {
|
| 1341 |
+
case 'on':
|
| 1342 |
+
et(this, t, n, r, s, e)
|
| 1343 |
+
break
|
| 1344 |
+
case 'model':
|
| 1345 |
+
ot(this, t, r, s, e)
|
| 1346 |
+
}
|
| 1347 |
+
})
|
| 1348 |
+
}
|
| 1349 |
+
resolveBoundAttributes(t, e = !1, i) {
|
| 1350 |
+
let n = v(t, this)
|
| 1351 |
+
n.forEach(({ type: r, value: s, modifiers: o, expression: a }) => {
|
| 1352 |
+
switch (r) {
|
| 1353 |
+
case 'model':
|
| 1354 |
+
U(this, t, 'value', a, i, r, o)
|
| 1355 |
+
break
|
| 1356 |
+
case 'bind':
|
| 1357 |
+
if ('template' === t.tagName.toLowerCase() && 'key' === s) return
|
| 1358 |
+
U(this, t, s, a, i, r, o)
|
| 1359 |
+
break
|
| 1360 |
+
case 'text':
|
| 1361 |
+
var l = this.evaluateReturnExpression(t, a, i)
|
| 1362 |
+
K(t, l, a)
|
| 1363 |
+
break
|
| 1364 |
+
case 'html':
|
| 1365 |
+
Q(this, t, a, i)
|
| 1366 |
+
break
|
| 1367 |
+
case 'show':
|
| 1368 |
+
;(l = this.evaluateReturnExpression(t, a, i)), Z(this, t, l, o, e)
|
| 1369 |
+
break
|
| 1370 |
+
case 'if':
|
| 1371 |
+
if (n.some((t) => 'for' === t.type)) return
|
| 1372 |
+
;(l = this.evaluateReturnExpression(t, a, i)), tt(this, t, l, e, i)
|
| 1373 |
+
break
|
| 1374 |
+
case 'for':
|
| 1375 |
+
F(this, t, a, e, i)
|
| 1376 |
+
break
|
| 1377 |
+
case 'cloak':
|
| 1378 |
+
t.removeAttribute('x-cloak')
|
| 1379 |
+
}
|
| 1380 |
+
})
|
| 1381 |
+
}
|
| 1382 |
+
evaluateReturnExpression(t, e, n = () => {}) {
|
| 1383 |
+
return p(t, e, this.$data, i(i({}, n()), {}, { $dispatch: this.getDispatchFunction(t) }))
|
| 1384 |
+
}
|
| 1385 |
+
evaluateCommandExpression(t, e, n = () => {}) {
|
| 1386 |
+
return _(t, e, this.$data, i(i({}, n()), {}, { $dispatch: this.getDispatchFunction(t) }))
|
| 1387 |
+
}
|
| 1388 |
+
getDispatchFunction(t) {
|
| 1389 |
+
return (e, i = {}) => {
|
| 1390 |
+
t.dispatchEvent(new CustomEvent(e, { detail: i, bubbles: !0 }))
|
| 1391 |
+
}
|
| 1392 |
+
}
|
| 1393 |
+
listenForNewElementsToInitialize() {
|
| 1394 |
+
const t = this.$el,
|
| 1395 |
+
e = { childList: !0, attributes: !0, subtree: !0 }
|
| 1396 |
+
new MutationObserver((t) => {
|
| 1397 |
+
for (let e = 0; e < t.length; e++) {
|
| 1398 |
+
const i = t[e].target.closest('[x-data]')
|
| 1399 |
+
if (i && i.isSameNode(this.$el)) {
|
| 1400 |
+
if ('attributes' === t[e].type && 'x-data' === t[e].attributeName) {
|
| 1401 |
+
const i = t[e].target.getAttribute('x-data') || '{}',
|
| 1402 |
+
n = p(this.$el, i, { $el: this.$el })
|
| 1403 |
+
Object.keys(n).forEach((t) => {
|
| 1404 |
+
this.$data[t] !== n[t] && (this.$data[t] = n[t])
|
| 1405 |
+
})
|
| 1406 |
+
}
|
| 1407 |
+
t[e].addedNodes.length > 0 &&
|
| 1408 |
+
t[e].addedNodes.forEach((t) => {
|
| 1409 |
+
1 !== t.nodeType ||
|
| 1410 |
+
t.__x_inserted_me ||
|
| 1411 |
+
(!t.matches('[x-data]') || t.__x
|
| 1412 |
+
? this.initializeElements(t)
|
| 1413 |
+
: (t.__x = new Wt(t)))
|
| 1414 |
+
})
|
| 1415 |
+
}
|
| 1416 |
+
}
|
| 1417 |
+
}).observe(t, e)
|
| 1418 |
+
}
|
| 1419 |
+
getRefsProxy() {
|
| 1420 |
+
var t = this
|
| 1421 |
+
return new Proxy(
|
| 1422 |
+
{},
|
| 1423 |
+
{
|
| 1424 |
+
get(e, i) {
|
| 1425 |
+
return (
|
| 1426 |
+
'$isAlpineProxy' === i ||
|
| 1427 |
+
(t.walkAndSkipNestedComponents(t.$el, (t) => {
|
| 1428 |
+
t.hasAttribute('x-ref') && t.getAttribute('x-ref') === i && (n = t)
|
| 1429 |
+
}),
|
| 1430 |
+
n)
|
| 1431 |
+
)
|
| 1432 |
+
var n
|
| 1433 |
+
},
|
| 1434 |
+
},
|
| 1435 |
+
)
|
| 1436 |
+
}
|
| 1437 |
+
}
|
| 1438 |
+
const $t = {
|
| 1439 |
+
version: '2.8.0',
|
| 1440 |
+
pauseMutationObserver: !1,
|
| 1441 |
+
magicProperties: {},
|
| 1442 |
+
onComponentInitializeds: [],
|
| 1443 |
+
onBeforeComponentInitializeds: [],
|
| 1444 |
+
ignoreFocusedForValueBinding: !1,
|
| 1445 |
+
start: async function () {
|
| 1446 |
+
s() || (await n()),
|
| 1447 |
+
this.discoverComponents((t) => {
|
| 1448 |
+
this.initializeComponent(t)
|
| 1449 |
+
}),
|
| 1450 |
+
document.addEventListener('turbolinks:load', () => {
|
| 1451 |
+
this.discoverUninitializedComponents((t) => {
|
| 1452 |
+
this.initializeComponent(t)
|
| 1453 |
+
})
|
| 1454 |
+
}),
|
| 1455 |
+
this.listenForNewUninitializedComponentsAtRunTime()
|
| 1456 |
+
},
|
| 1457 |
+
discoverComponents: function (t) {
|
| 1458 |
+
document.querySelectorAll('[x-data]').forEach((e) => {
|
| 1459 |
+
t(e)
|
| 1460 |
+
})
|
| 1461 |
+
},
|
| 1462 |
+
discoverUninitializedComponents: function (t, e = null) {
|
| 1463 |
+
const i = (e || document).querySelectorAll('[x-data]')
|
| 1464 |
+
Array.from(i)
|
| 1465 |
+
.filter((t) => void 0 === t.__x)
|
| 1466 |
+
.forEach((e) => {
|
| 1467 |
+
t(e)
|
| 1468 |
+
})
|
| 1469 |
+
},
|
| 1470 |
+
listenForNewUninitializedComponentsAtRunTime: function () {
|
| 1471 |
+
const t = document.querySelector('body'),
|
| 1472 |
+
e = { childList: !0, attributes: !0, subtree: !0 }
|
| 1473 |
+
new MutationObserver((t) => {
|
| 1474 |
+
if (!this.pauseMutationObserver)
|
| 1475 |
+
for (let e = 0; e < t.length; e++)
|
| 1476 |
+
t[e].addedNodes.length > 0 &&
|
| 1477 |
+
t[e].addedNodes.forEach((t) => {
|
| 1478 |
+
1 === t.nodeType &&
|
| 1479 |
+
((t.parentElement && t.parentElement.closest('[x-data]')) ||
|
| 1480 |
+
this.discoverUninitializedComponents((t) => {
|
| 1481 |
+
this.initializeComponent(t)
|
| 1482 |
+
}, t.parentElement))
|
| 1483 |
+
})
|
| 1484 |
+
}).observe(t, e)
|
| 1485 |
+
},
|
| 1486 |
+
initializeComponent: function (t) {
|
| 1487 |
+
if (!t.__x)
|
| 1488 |
+
try {
|
| 1489 |
+
t.__x = new Wt(t)
|
| 1490 |
+
} catch (t) {
|
| 1491 |
+
setTimeout(() => {
|
| 1492 |
+
throw t
|
| 1493 |
+
}, 0)
|
| 1494 |
+
}
|
| 1495 |
+
},
|
| 1496 |
+
clone: function (t, e) {
|
| 1497 |
+
e.__x || (e.__x = new Wt(e, t))
|
| 1498 |
+
},
|
| 1499 |
+
addMagicProperty: function (t, e) {
|
| 1500 |
+
this.magicProperties[t] = e
|
| 1501 |
+
},
|
| 1502 |
+
onComponentInitialized: function (t) {
|
| 1503 |
+
this.onComponentInitializeds.push(t)
|
| 1504 |
+
},
|
| 1505 |
+
onBeforeComponentInitialized: function (t) {
|
| 1506 |
+
this.onBeforeComponentInitializeds.push(t)
|
| 1507 |
+
},
|
| 1508 |
+
}
|
| 1509 |
+
return (
|
| 1510 |
+
s() ||
|
| 1511 |
+
((window.Alpine = $t),
|
| 1512 |
+
window.deferLoadingAlpine
|
| 1513 |
+
? window.deferLoadingAlpine(function () {
|
| 1514 |
+
window.Alpine.start()
|
| 1515 |
+
})
|
| 1516 |
+
: window.Alpine.start()),
|
| 1517 |
+
$t
|
| 1518 |
+
)
|
| 1519 |
+
})()
|
| 1520 |
+
})
|
| 1521 |
+
var r = e(function (e, i) {
|
| 1522 |
+
;(function () {
|
| 1523 |
+
var t = function (t) {
|
| 1524 |
+
return '[object Array]' === toString.call(t)
|
| 1525 |
+
},
|
| 1526 |
+
n = function (t) {
|
| 1527 |
+
var e,
|
| 1528 |
+
i,
|
| 1529 |
+
n = ''
|
| 1530 |
+
for (e = 0; e < t.length; e += 1)
|
| 1531 |
+
switch ((i = t.charAt(e))) {
|
| 1532 |
+
case '<':
|
| 1533 |
+
n += '<'
|
| 1534 |
+
break
|
| 1535 |
+
case '>':
|
| 1536 |
+
n += '>'
|
| 1537 |
+
break
|
| 1538 |
+
case '&':
|
| 1539 |
+
n += '&'
|
| 1540 |
+
break
|
| 1541 |
+
case '/':
|
| 1542 |
+
n += '/'
|
| 1543 |
+
break
|
| 1544 |
+
case '"':
|
| 1545 |
+
n += '"'
|
| 1546 |
+
break
|
| 1547 |
+
case "'":
|
| 1548 |
+
n += '''
|
| 1549 |
+
break
|
| 1550 |
+
default:
|
| 1551 |
+
n += i
|
| 1552 |
+
}
|
| 1553 |
+
return n
|
| 1554 |
+
},
|
| 1555 |
+
r = function (t) {
|
| 1556 |
+
return t
|
| 1557 |
+
.replace(/&/g, '&')
|
| 1558 |
+
.replace(/</g, '<')
|
| 1559 |
+
.replace(/>/g, '>')
|
| 1560 |
+
.replace(/"/g, '"')
|
| 1561 |
+
.replace(/'/g, ''')
|
| 1562 |
+
.replace(/\//g, '/')
|
| 1563 |
+
},
|
| 1564 |
+
s = function (e, i) {
|
| 1565 |
+
var o, a, l, h
|
| 1566 |
+
if (
|
| 1567 |
+
(function (t) {
|
| 1568 |
+
return 'string' == typeof t
|
| 1569 |
+
})(e)
|
| 1570 |
+
)
|
| 1571 |
+
(h = e.length),
|
| 1572 |
+
(o = 'charForLoopStrategy' === i ? n(e) : 'regexStrategy' === i || h > 32 ? r(e) : n(e))
|
| 1573 |
+
else if (
|
| 1574 |
+
'number' == typeof e ||
|
| 1575 |
+
(function (t) {
|
| 1576 |
+
return 'boolean' == typeof t
|
| 1577 |
+
})(e)
|
| 1578 |
+
)
|
| 1579 |
+
o = e
|
| 1580 |
+
else if (t(e)) for (o = [], l = 0; l < e.length; l += 1) o.push(s(e[l]))
|
| 1581 |
+
else if (
|
| 1582 |
+
(function (e) {
|
| 1583 |
+
return !t(e) && e instanceof Object
|
| 1584 |
+
})(e)
|
| 1585 |
+
)
|
| 1586 |
+
for (a in ((o = {}), e)) e.hasOwnProperty(a) && (o[a] = s(e[a]))
|
| 1587 |
+
return o
|
| 1588 |
+
}
|
| 1589 |
+
e.exports && (i = e.exports = s), (i.xssEscape = s)
|
| 1590 |
+
}.call(t))
|
| 1591 |
+
})
|
| 1592 |
+
var s = function (t, e) {
|
| 1593 |
+
return function () {
|
| 1594 |
+
for (var i = new Array(arguments.length), n = 0; n < i.length; n++) i[n] = arguments[n]
|
| 1595 |
+
return t.apply(e, i)
|
| 1596 |
+
}
|
| 1597 |
+
},
|
| 1598 |
+
o = Object.prototype.toString
|
| 1599 |
+
function a(t) {
|
| 1600 |
+
return '[object Array]' === o.call(t)
|
| 1601 |
+
}
|
| 1602 |
+
function l(t) {
|
| 1603 |
+
return void 0 === t
|
| 1604 |
+
}
|
| 1605 |
+
function h(t) {
|
| 1606 |
+
return null !== t && 'object' == typeof t
|
| 1607 |
+
}
|
| 1608 |
+
function u(t) {
|
| 1609 |
+
if ('[object Object]' !== o.call(t)) return !1
|
| 1610 |
+
var e = Object.getPrototypeOf(t)
|
| 1611 |
+
return null === e || e === Object.prototype
|
| 1612 |
+
}
|
| 1613 |
+
function c(t) {
|
| 1614 |
+
return '[object Function]' === o.call(t)
|
| 1615 |
+
}
|
| 1616 |
+
function d(t, e) {
|
| 1617 |
+
if (null != t)
|
| 1618 |
+
if (('object' != typeof t && (t = [t]), a(t)))
|
| 1619 |
+
for (var i = 0, n = t.length; i < n; i++) e.call(null, t[i], i, t)
|
| 1620 |
+
else for (var r in t) Object.prototype.hasOwnProperty.call(t, r) && e.call(null, t[r], r, t)
|
| 1621 |
+
}
|
| 1622 |
+
var f = {
|
| 1623 |
+
isArray: a,
|
| 1624 |
+
isArrayBuffer: function (t) {
|
| 1625 |
+
return '[object ArrayBuffer]' === o.call(t)
|
| 1626 |
+
},
|
| 1627 |
+
isBuffer: function (t) {
|
| 1628 |
+
return (
|
| 1629 |
+
null !== t &&
|
| 1630 |
+
!l(t) &&
|
| 1631 |
+
null !== t.constructor &&
|
| 1632 |
+
!l(t.constructor) &&
|
| 1633 |
+
'function' == typeof t.constructor.isBuffer &&
|
| 1634 |
+
t.constructor.isBuffer(t)
|
| 1635 |
+
)
|
| 1636 |
+
},
|
| 1637 |
+
isFormData: function (t) {
|
| 1638 |
+
return 'undefined' != typeof FormData && t instanceof FormData
|
| 1639 |
+
},
|
| 1640 |
+
isArrayBufferView: function (t) {
|
| 1641 |
+
return 'undefined' != typeof ArrayBuffer && ArrayBuffer.isView
|
| 1642 |
+
? ArrayBuffer.isView(t)
|
| 1643 |
+
: t && t.buffer && t.buffer instanceof ArrayBuffer
|
| 1644 |
+
},
|
| 1645 |
+
isString: function (t) {
|
| 1646 |
+
return 'string' == typeof t
|
| 1647 |
+
},
|
| 1648 |
+
isNumber: function (t) {
|
| 1649 |
+
return 'number' == typeof t
|
| 1650 |
+
},
|
| 1651 |
+
isObject: h,
|
| 1652 |
+
isPlainObject: u,
|
| 1653 |
+
isUndefined: l,
|
| 1654 |
+
isDate: function (t) {
|
| 1655 |
+
return '[object Date]' === o.call(t)
|
| 1656 |
+
},
|
| 1657 |
+
isFile: function (t) {
|
| 1658 |
+
return '[object File]' === o.call(t)
|
| 1659 |
+
},
|
| 1660 |
+
isBlob: function (t) {
|
| 1661 |
+
return '[object Blob]' === o.call(t)
|
| 1662 |
+
},
|
| 1663 |
+
isFunction: c,
|
| 1664 |
+
isStream: function (t) {
|
| 1665 |
+
return h(t) && c(t.pipe)
|
| 1666 |
+
},
|
| 1667 |
+
isURLSearchParams: function (t) {
|
| 1668 |
+
return 'undefined' != typeof URLSearchParams && t instanceof URLSearchParams
|
| 1669 |
+
},
|
| 1670 |
+
isStandardBrowserEnv: function () {
|
| 1671 |
+
return (
|
| 1672 |
+
('undefined' == typeof navigator ||
|
| 1673 |
+
('ReactNative' !== navigator.product &&
|
| 1674 |
+
'NativeScript' !== navigator.product &&
|
| 1675 |
+
'NS' !== navigator.product)) &&
|
| 1676 |
+
'undefined' != typeof window &&
|
| 1677 |
+
'undefined' != typeof document
|
| 1678 |
+
)
|
| 1679 |
+
},
|
| 1680 |
+
forEach: d,
|
| 1681 |
+
merge: function t() {
|
| 1682 |
+
var e = {}
|
| 1683 |
+
function i(i, n) {
|
| 1684 |
+
u(e[n]) && u(i)
|
| 1685 |
+
? (e[n] = t(e[n], i))
|
| 1686 |
+
: u(i)
|
| 1687 |
+
? (e[n] = t({}, i))
|
| 1688 |
+
: a(i)
|
| 1689 |
+
? (e[n] = i.slice())
|
| 1690 |
+
: (e[n] = i)
|
| 1691 |
+
}
|
| 1692 |
+
for (var n = 0, r = arguments.length; n < r; n++) d(arguments[n], i)
|
| 1693 |
+
return e
|
| 1694 |
+
},
|
| 1695 |
+
extend: function (t, e, i) {
|
| 1696 |
+
return (
|
| 1697 |
+
d(e, function (e, n) {
|
| 1698 |
+
t[n] = i && 'function' == typeof e ? s(e, i) : e
|
| 1699 |
+
}),
|
| 1700 |
+
t
|
| 1701 |
+
)
|
| 1702 |
+
},
|
| 1703 |
+
trim: function (t) {
|
| 1704 |
+
return t.trim ? t.trim() : t.replace(/^\s+|\s+$/g, '')
|
| 1705 |
+
},
|
| 1706 |
+
stripBOM: function (t) {
|
| 1707 |
+
return 65279 === t.charCodeAt(0) && (t = t.slice(1)), t
|
| 1708 |
+
},
|
| 1709 |
+
}
|
| 1710 |
+
function p(t) {
|
| 1711 |
+
return encodeURIComponent(t)
|
| 1712 |
+
.replace(/%3A/gi, ':')
|
| 1713 |
+
.replace(/%24/g, '$')
|
| 1714 |
+
.replace(/%2C/gi, ',')
|
| 1715 |
+
.replace(/%20/g, '+')
|
| 1716 |
+
.replace(/%5B/gi, '[')
|
| 1717 |
+
.replace(/%5D/gi, ']')
|
| 1718 |
+
}
|
| 1719 |
+
var _ = function (t, e, i) {
|
| 1720 |
+
if (!e) return t
|
| 1721 |
+
var n
|
| 1722 |
+
if (i) n = i(e)
|
| 1723 |
+
else if (f.isURLSearchParams(e)) n = e.toString()
|
| 1724 |
+
else {
|
| 1725 |
+
var r = []
|
| 1726 |
+
f.forEach(e, function (t, e) {
|
| 1727 |
+
null != t &&
|
| 1728 |
+
(f.isArray(t) ? (e += '[]') : (t = [t]),
|
| 1729 |
+
f.forEach(t, function (t) {
|
| 1730 |
+
f.isDate(t) ? (t = t.toISOString()) : f.isObject(t) && (t = JSON.stringify(t)),
|
| 1731 |
+
r.push(p(e) + '=' + p(t))
|
| 1732 |
+
}))
|
| 1733 |
+
}),
|
| 1734 |
+
(n = r.join('&'))
|
| 1735 |
+
}
|
| 1736 |
+
if (n) {
|
| 1737 |
+
var s = t.indexOf('#')
|
| 1738 |
+
;-1 !== s && (t = t.slice(0, s)), (t += (-1 === t.indexOf('?') ? '?' : '&') + n)
|
| 1739 |
+
}
|
| 1740 |
+
return t
|
| 1741 |
+
}
|
| 1742 |
+
function m() {
|
| 1743 |
+
this.handlers = []
|
| 1744 |
+
}
|
| 1745 |
+
;(m.prototype.use = function (t, e, i) {
|
| 1746 |
+
return (
|
| 1747 |
+
this.handlers.push({
|
| 1748 |
+
fulfilled: t,
|
| 1749 |
+
rejected: e,
|
| 1750 |
+
synchronous: !!i && i.synchronous,
|
| 1751 |
+
runWhen: i ? i.runWhen : null,
|
| 1752 |
+
}),
|
| 1753 |
+
this.handlers.length - 1
|
| 1754 |
+
)
|
| 1755 |
+
}),
|
| 1756 |
+
(m.prototype.eject = function (t) {
|
| 1757 |
+
this.handlers[t] && (this.handlers[t] = null)
|
| 1758 |
+
}),
|
| 1759 |
+
(m.prototype.forEach = function (t) {
|
| 1760 |
+
f.forEach(this.handlers, function (e) {
|
| 1761 |
+
null !== e && t(e)
|
| 1762 |
+
})
|
| 1763 |
+
})
|
| 1764 |
+
var g = m,
|
| 1765 |
+
v = function (t, e) {
|
| 1766 |
+
f.forEach(t, function (i, n) {
|
| 1767 |
+
n !== e && n.toUpperCase() === e.toUpperCase() && ((t[e] = i), delete t[n])
|
| 1768 |
+
})
|
| 1769 |
+
},
|
| 1770 |
+
y = function (t, e, i, n, r) {
|
| 1771 |
+
return (
|
| 1772 |
+
(t.config = e),
|
| 1773 |
+
i && (t.code = i),
|
| 1774 |
+
(t.request = n),
|
| 1775 |
+
(t.response = r),
|
| 1776 |
+
(t.isAxiosError = !0),
|
| 1777 |
+
(t.toJSON = function () {
|
| 1778 |
+
return {
|
| 1779 |
+
message: this.message,
|
| 1780 |
+
name: this.name,
|
| 1781 |
+
description: this.description,
|
| 1782 |
+
number: this.number,
|
| 1783 |
+
fileName: this.fileName,
|
| 1784 |
+
lineNumber: this.lineNumber,
|
| 1785 |
+
columnNumber: this.columnNumber,
|
| 1786 |
+
stack: this.stack,
|
| 1787 |
+
config: this.config,
|
| 1788 |
+
code: this.code,
|
| 1789 |
+
}
|
| 1790 |
+
}),
|
| 1791 |
+
t
|
| 1792 |
+
)
|
| 1793 |
+
},
|
| 1794 |
+
b = function (t, e, i, n, r) {
|
| 1795 |
+
var s = new Error(t)
|
| 1796 |
+
return y(s, e, i, n, r)
|
| 1797 |
+
},
|
| 1798 |
+
w = f.isStandardBrowserEnv()
|
| 1799 |
+
? {
|
| 1800 |
+
write: function (t, e, i, n, r, s) {
|
| 1801 |
+
var o = []
|
| 1802 |
+
o.push(t + '=' + encodeURIComponent(e)),
|
| 1803 |
+
f.isNumber(i) && o.push('expires=' + new Date(i).toGMTString()),
|
| 1804 |
+
f.isString(n) && o.push('path=' + n),
|
| 1805 |
+
f.isString(r) && o.push('domain=' + r),
|
| 1806 |
+
!0 === s && o.push('secure'),
|
| 1807 |
+
(document.cookie = o.join('; '))
|
| 1808 |
+
},
|
| 1809 |
+
read: function (t) {
|
| 1810 |
+
var e = document.cookie.match(new RegExp('(^|;\\s*)(' + t + ')=([^;]*)'))
|
| 1811 |
+
return e ? decodeURIComponent(e[3]) : null
|
| 1812 |
+
},
|
| 1813 |
+
remove: function (t) {
|
| 1814 |
+
this.write(t, '', Date.now() - 864e5)
|
| 1815 |
+
},
|
| 1816 |
+
}
|
| 1817 |
+
: {
|
| 1818 |
+
write: function () {},
|
| 1819 |
+
read: function () {
|
| 1820 |
+
return null
|
| 1821 |
+
},
|
| 1822 |
+
remove: function () {},
|
| 1823 |
+
},
|
| 1824 |
+
x = [
|
| 1825 |
+
'age',
|
| 1826 |
+
'authorization',
|
| 1827 |
+
'content-length',
|
| 1828 |
+
'content-type',
|
| 1829 |
+
'etag',
|
| 1830 |
+
'expires',
|
| 1831 |
+
'from',
|
| 1832 |
+
'host',
|
| 1833 |
+
'if-modified-since',
|
| 1834 |
+
'if-unmodified-since',
|
| 1835 |
+
'last-modified',
|
| 1836 |
+
'location',
|
| 1837 |
+
'max-forwards',
|
| 1838 |
+
'proxy-authorization',
|
| 1839 |
+
'referer',
|
| 1840 |
+
'retry-after',
|
| 1841 |
+
'user-agent',
|
| 1842 |
+
],
|
| 1843 |
+
S = f.isStandardBrowserEnv()
|
| 1844 |
+
? (function () {
|
| 1845 |
+
var t,
|
| 1846 |
+
e = /(msie|trident)/i.test(navigator.userAgent),
|
| 1847 |
+
i = document.createElement('a')
|
| 1848 |
+
function n(t) {
|
| 1849 |
+
var n = t
|
| 1850 |
+
return (
|
| 1851 |
+
e && (i.setAttribute('href', n), (n = i.href)),
|
| 1852 |
+
i.setAttribute('href', n),
|
| 1853 |
+
{
|
| 1854 |
+
href: i.href,
|
| 1855 |
+
protocol: i.protocol ? i.protocol.replace(/:$/, '') : '',
|
| 1856 |
+
host: i.host,
|
| 1857 |
+
search: i.search ? i.search.replace(/^\?/, '') : '',
|
| 1858 |
+
hash: i.hash ? i.hash.replace(/^#/, '') : '',
|
| 1859 |
+
hostname: i.hostname,
|
| 1860 |
+
port: i.port,
|
| 1861 |
+
pathname: '/' === i.pathname.charAt(0) ? i.pathname : '/' + i.pathname,
|
| 1862 |
+
}
|
| 1863 |
+
)
|
| 1864 |
+
}
|
| 1865 |
+
return (
|
| 1866 |
+
(t = n(window.location.href)),
|
| 1867 |
+
function (e) {
|
| 1868 |
+
var i = f.isString(e) ? n(e) : e
|
| 1869 |
+
return i.protocol === t.protocol && i.host === t.host
|
| 1870 |
+
}
|
| 1871 |
+
)
|
| 1872 |
+
})()
|
| 1873 |
+
: function () {
|
| 1874 |
+
return !0
|
| 1875 |
+
},
|
| 1876 |
+
E = function (t) {
|
| 1877 |
+
return new Promise(function (e, i) {
|
| 1878 |
+
var n = t.data,
|
| 1879 |
+
r = t.headers,
|
| 1880 |
+
s = t.responseType
|
| 1881 |
+
f.isFormData(n) && delete r['Content-Type']
|
| 1882 |
+
var o = new XMLHttpRequest()
|
| 1883 |
+
if (t.auth) {
|
| 1884 |
+
var a = t.auth.username || '',
|
| 1885 |
+
l = t.auth.password ? unescape(encodeURIComponent(t.auth.password)) : ''
|
| 1886 |
+
r.Authorization = 'Basic ' + btoa(a + ':' + l)
|
| 1887 |
+
}
|
| 1888 |
+
var h,
|
| 1889 |
+
u,
|
| 1890 |
+
c =
|
| 1891 |
+
((h = t.baseURL),
|
| 1892 |
+
(u = t.url),
|
| 1893 |
+
h && !/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(u)
|
| 1894 |
+
? (function (t, e) {
|
| 1895 |
+
return e ? t.replace(/\/+$/, '') + '/' + e.replace(/^\/+/, '') : t
|
| 1896 |
+
})(h, u)
|
| 1897 |
+
: u)
|
| 1898 |
+
function d() {
|
| 1899 |
+
if (o) {
|
| 1900 |
+
var n,
|
| 1901 |
+
r,
|
| 1902 |
+
a,
|
| 1903 |
+
l,
|
| 1904 |
+
h,
|
| 1905 |
+
u =
|
| 1906 |
+
'getAllResponseHeaders' in o
|
| 1907 |
+
? ((n = o.getAllResponseHeaders()),
|
| 1908 |
+
(h = {}),
|
| 1909 |
+
n
|
| 1910 |
+
? (f.forEach(n.split('\n'), function (t) {
|
| 1911 |
+
if (
|
| 1912 |
+
((l = t.indexOf(':')),
|
| 1913 |
+
(r = f.trim(t.substr(0, l)).toLowerCase()),
|
| 1914 |
+
(a = f.trim(t.substr(l + 1))),
|
| 1915 |
+
r)
|
| 1916 |
+
) {
|
| 1917 |
+
if (h[r] && x.indexOf(r) >= 0) return
|
| 1918 |
+
h[r] =
|
| 1919 |
+
'set-cookie' === r
|
| 1920 |
+
? (h[r] ? h[r] : []).concat([a])
|
| 1921 |
+
: h[r]
|
| 1922 |
+
? h[r] + ', ' + a
|
| 1923 |
+
: a
|
| 1924 |
+
}
|
| 1925 |
+
}),
|
| 1926 |
+
h)
|
| 1927 |
+
: h)
|
| 1928 |
+
: null,
|
| 1929 |
+
c = {
|
| 1930 |
+
data: s && 'text' !== s && 'json' !== s ? o.response : o.responseText,
|
| 1931 |
+
status: o.status,
|
| 1932 |
+
statusText: o.statusText,
|
| 1933 |
+
headers: u,
|
| 1934 |
+
config: t,
|
| 1935 |
+
request: o,
|
| 1936 |
+
}
|
| 1937 |
+
!(function (t, e, i) {
|
| 1938 |
+
var n = i.config.validateStatus
|
| 1939 |
+
i.status && n && !n(i.status)
|
| 1940 |
+
? e(b('Request failed with status code ' + i.status, i.config, null, i.request, i))
|
| 1941 |
+
: t(i)
|
| 1942 |
+
})(e, i, c),
|
| 1943 |
+
(o = null)
|
| 1944 |
+
}
|
| 1945 |
+
}
|
| 1946 |
+
if (
|
| 1947 |
+
(o.open(t.method.toUpperCase(), _(c, t.params, t.paramsSerializer), !0),
|
| 1948 |
+
(o.timeout = t.timeout),
|
| 1949 |
+
'onloadend' in o
|
| 1950 |
+
? (o.onloadend = d)
|
| 1951 |
+
: (o.onreadystatechange = function () {
|
| 1952 |
+
o &&
|
| 1953 |
+
4 === o.readyState &&
|
| 1954 |
+
(0 !== o.status || (o.responseURL && 0 === o.responseURL.indexOf('file:'))) &&
|
| 1955 |
+
setTimeout(d)
|
| 1956 |
+
}),
|
| 1957 |
+
(o.onabort = function () {
|
| 1958 |
+
o && (i(b('Request aborted', t, 'ECONNABORTED', o)), (o = null))
|
| 1959 |
+
}),
|
| 1960 |
+
(o.onerror = function () {
|
| 1961 |
+
i(b('Network Error', t, null, o)), (o = null)
|
| 1962 |
+
}),
|
| 1963 |
+
(o.ontimeout = function () {
|
| 1964 |
+
var e = 'timeout of ' + t.timeout + 'ms exceeded'
|
| 1965 |
+
t.timeoutErrorMessage && (e = t.timeoutErrorMessage),
|
| 1966 |
+
i(
|
| 1967 |
+
b(
|
| 1968 |
+
e,
|
| 1969 |
+
t,
|
| 1970 |
+
t.transitional && t.transitional.clarifyTimeoutError ? 'ETIMEDOUT' : 'ECONNABORTED',
|
| 1971 |
+
o,
|
| 1972 |
+
),
|
| 1973 |
+
),
|
| 1974 |
+
(o = null)
|
| 1975 |
+
}),
|
| 1976 |
+
f.isStandardBrowserEnv())
|
| 1977 |
+
) {
|
| 1978 |
+
var p = (t.withCredentials || S(c)) && t.xsrfCookieName ? w.read(t.xsrfCookieName) : void 0
|
| 1979 |
+
p && (r[t.xsrfHeaderName] = p)
|
| 1980 |
+
}
|
| 1981 |
+
'setRequestHeader' in o &&
|
| 1982 |
+
f.forEach(r, function (t, e) {
|
| 1983 |
+
void 0 === n && 'content-type' === e.toLowerCase() ? delete r[e] : o.setRequestHeader(e, t)
|
| 1984 |
+
}),
|
| 1985 |
+
f.isUndefined(t.withCredentials) || (o.withCredentials = !!t.withCredentials),
|
| 1986 |
+
s && 'json' !== s && (o.responseType = t.responseType),
|
| 1987 |
+
'function' == typeof t.onDownloadProgress && o.addEventListener('progress', t.onDownloadProgress),
|
| 1988 |
+
'function' == typeof t.onUploadProgress &&
|
| 1989 |
+
o.upload &&
|
| 1990 |
+
o.upload.addEventListener('progress', t.onUploadProgress),
|
| 1991 |
+
t.cancelToken &&
|
| 1992 |
+
t.cancelToken.promise.then(function (t) {
|
| 1993 |
+
o && (o.abort(), i(t), (o = null))
|
| 1994 |
+
}),
|
| 1995 |
+
n || (n = null),
|
| 1996 |
+
o.send(n)
|
| 1997 |
+
})
|
| 1998 |
+
},
|
| 1999 |
+
T = { 'Content-Type': 'application/x-www-form-urlencoded' }
|
| 2000 |
+
function D(t, e) {
|
| 2001 |
+
!f.isUndefined(t) && f.isUndefined(t['Content-Type']) && (t['Content-Type'] = e)
|
| 2002 |
+
}
|
| 2003 |
+
var A,
|
| 2004 |
+
k = {
|
| 2005 |
+
transitional: { silentJSONParsing: !0, forcedJSONParsing: !0, clarifyTimeoutError: !1 },
|
| 2006 |
+
adapter:
|
| 2007 |
+
(('undefined' != typeof XMLHttpRequest ||
|
| 2008 |
+
('undefined' != typeof process &&
|
| 2009 |
+
'[object process]' === Object.prototype.toString.call(process))) &&
|
| 2010 |
+
(A = E),
|
| 2011 |
+
A),
|
| 2012 |
+
transformRequest: [
|
| 2013 |
+
function (t, e) {
|
| 2014 |
+
return (
|
| 2015 |
+
v(e, 'Accept'),
|
| 2016 |
+
v(e, 'Content-Type'),
|
| 2017 |
+
f.isFormData(t) ||
|
| 2018 |
+
f.isArrayBuffer(t) ||
|
| 2019 |
+
f.isBuffer(t) ||
|
| 2020 |
+
f.isStream(t) ||
|
| 2021 |
+
f.isFile(t) ||
|
| 2022 |
+
f.isBlob(t)
|
| 2023 |
+
? t
|
| 2024 |
+
: f.isArrayBufferView(t)
|
| 2025 |
+
? t.buffer
|
| 2026 |
+
: f.isURLSearchParams(t)
|
| 2027 |
+
? (D(e, 'application/x-www-form-urlencoded;charset=utf-8'), t.toString())
|
| 2028 |
+
: f.isObject(t) || (e && 'application/json' === e['Content-Type'])
|
| 2029 |
+
? (D(e, 'application/json'), JSON.stringify(t))
|
| 2030 |
+
: t
|
| 2031 |
+
)
|
| 2032 |
+
},
|
| 2033 |
+
],
|
| 2034 |
+
transformResponse: [
|
| 2035 |
+
function (t) {
|
| 2036 |
+
var e = this.transitional,
|
| 2037 |
+
i = e && e.silentJSONParsing,
|
| 2038 |
+
n = e && e.forcedJSONParsing,
|
| 2039 |
+
r = !i && 'json' === this.responseType
|
| 2040 |
+
if (r || (n && f.isString(t) && t.length))
|
| 2041 |
+
try {
|
| 2042 |
+
return JSON.parse(t)
|
| 2043 |
+
} catch (t) {
|
| 2044 |
+
if (r) {
|
| 2045 |
+
if ('SyntaxError' === t.name) throw y(t, this, 'E_JSON_PARSE')
|
| 2046 |
+
throw t
|
| 2047 |
+
}
|
| 2048 |
+
}
|
| 2049 |
+
return t
|
| 2050 |
+
},
|
| 2051 |
+
],
|
| 2052 |
+
timeout: 0,
|
| 2053 |
+
xsrfCookieName: 'XSRF-TOKEN',
|
| 2054 |
+
xsrfHeaderName: 'X-XSRF-TOKEN',
|
| 2055 |
+
maxContentLength: -1,
|
| 2056 |
+
maxBodyLength: -1,
|
| 2057 |
+
validateStatus: function (t) {
|
| 2058 |
+
return t >= 200 && t < 300
|
| 2059 |
+
},
|
| 2060 |
+
}
|
| 2061 |
+
;(k.headers = { common: { Accept: 'application/json, text/plain, */*' } }),
|
| 2062 |
+
f.forEach(['delete', 'get', 'head'], function (t) {
|
| 2063 |
+
k.headers[t] = {}
|
| 2064 |
+
}),
|
| 2065 |
+
f.forEach(['post', 'put', 'patch'], function (t) {
|
| 2066 |
+
k.headers[t] = f.merge(T)
|
| 2067 |
+
})
|
| 2068 |
+
var R = k,
|
| 2069 |
+
P = function (t, e, i) {
|
| 2070 |
+
var n = this || R
|
| 2071 |
+
return (
|
| 2072 |
+
f.forEach(i, function (i) {
|
| 2073 |
+
t = i.call(n, t, e)
|
| 2074 |
+
}),
|
| 2075 |
+
t
|
| 2076 |
+
)
|
| 2077 |
+
},
|
| 2078 |
+
O = function (t) {
|
| 2079 |
+
return !(!t || !t.__CANCEL__)
|
| 2080 |
+
}
|
| 2081 |
+
function L(t) {
|
| 2082 |
+
t.cancelToken && t.cancelToken.throwIfRequested()
|
| 2083 |
+
}
|
| 2084 |
+
var C = function (t) {
|
| 2085 |
+
return (
|
| 2086 |
+
L(t),
|
| 2087 |
+
(t.headers = t.headers || {}),
|
| 2088 |
+
(t.data = P.call(t, t.data, t.headers, t.transformRequest)),
|
| 2089 |
+
(t.headers = f.merge(t.headers.common || {}, t.headers[t.method] || {}, t.headers)),
|
| 2090 |
+
f.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], function (e) {
|
| 2091 |
+
delete t.headers[e]
|
| 2092 |
+
}),
|
| 2093 |
+
(t.adapter || R.adapter)(t).then(
|
| 2094 |
+
function (e) {
|
| 2095 |
+
return L(t), (e.data = P.call(t, e.data, e.headers, t.transformResponse)), e
|
| 2096 |
+
},
|
| 2097 |
+
function (e) {
|
| 2098 |
+
return (
|
| 2099 |
+
O(e) ||
|
| 2100 |
+
(L(t),
|
| 2101 |
+
e &&
|
| 2102 |
+
e.response &&
|
| 2103 |
+
(e.response.data = P.call(
|
| 2104 |
+
t,
|
| 2105 |
+
e.response.data,
|
| 2106 |
+
e.response.headers,
|
| 2107 |
+
t.transformResponse,
|
| 2108 |
+
))),
|
| 2109 |
+
Promise.reject(e)
|
| 2110 |
+
)
|
| 2111 |
+
},
|
| 2112 |
+
)
|
| 2113 |
+
)
|
| 2114 |
+
},
|
| 2115 |
+
M = function (t, e) {
|
| 2116 |
+
e = e || {}
|
| 2117 |
+
var i = {},
|
| 2118 |
+
n = ['url', 'method', 'data'],
|
| 2119 |
+
r = ['headers', 'auth', 'proxy', 'params'],
|
| 2120 |
+
s = [
|
| 2121 |
+
'baseURL',
|
| 2122 |
+
'transformRequest',
|
| 2123 |
+
'transformResponse',
|
| 2124 |
+
'paramsSerializer',
|
| 2125 |
+
'timeout',
|
| 2126 |
+
'timeoutMessage',
|
| 2127 |
+
'withCredentials',
|
| 2128 |
+
'adapter',
|
| 2129 |
+
'responseType',
|
| 2130 |
+
'xsrfCookieName',
|
| 2131 |
+
'xsrfHeaderName',
|
| 2132 |
+
'onUploadProgress',
|
| 2133 |
+
'onDownloadProgress',
|
| 2134 |
+
'decompress',
|
| 2135 |
+
'maxContentLength',
|
| 2136 |
+
'maxBodyLength',
|
| 2137 |
+
'maxRedirects',
|
| 2138 |
+
'transport',
|
| 2139 |
+
'httpAgent',
|
| 2140 |
+
'httpsAgent',
|
| 2141 |
+
'cancelToken',
|
| 2142 |
+
'socketPath',
|
| 2143 |
+
'responseEncoding',
|
| 2144 |
+
],
|
| 2145 |
+
o = ['validateStatus']
|
| 2146 |
+
function a(t, e) {
|
| 2147 |
+
return f.isPlainObject(t) && f.isPlainObject(e)
|
| 2148 |
+
? f.merge(t, e)
|
| 2149 |
+
: f.isPlainObject(e)
|
| 2150 |
+
? f.merge({}, e)
|
| 2151 |
+
: f.isArray(e)
|
| 2152 |
+
? e.slice()
|
| 2153 |
+
: e
|
| 2154 |
+
}
|
| 2155 |
+
function l(n) {
|
| 2156 |
+
f.isUndefined(e[n]) ? f.isUndefined(t[n]) || (i[n] = a(void 0, t[n])) : (i[n] = a(t[n], e[n]))
|
| 2157 |
+
}
|
| 2158 |
+
f.forEach(n, function (t) {
|
| 2159 |
+
f.isUndefined(e[t]) || (i[t] = a(void 0, e[t]))
|
| 2160 |
+
}),
|
| 2161 |
+
f.forEach(r, l),
|
| 2162 |
+
f.forEach(s, function (n) {
|
| 2163 |
+
f.isUndefined(e[n]) ? f.isUndefined(t[n]) || (i[n] = a(void 0, t[n])) : (i[n] = a(void 0, e[n]))
|
| 2164 |
+
}),
|
| 2165 |
+
f.forEach(o, function (n) {
|
| 2166 |
+
n in e ? (i[n] = a(t[n], e[n])) : n in t && (i[n] = a(void 0, t[n]))
|
| 2167 |
+
})
|
| 2168 |
+
var h = n.concat(r).concat(s).concat(o),
|
| 2169 |
+
u = Object.keys(t)
|
| 2170 |
+
.concat(Object.keys(e))
|
| 2171 |
+
.filter(function (t) {
|
| 2172 |
+
return -1 === h.indexOf(t)
|
| 2173 |
+
})
|
| 2174 |
+
return f.forEach(u, l), i
|
| 2175 |
+
},
|
| 2176 |
+
I = {
|
| 2177 |
+
_args: [['axios@0.21.2', '/usr/src/app']],
|
| 2178 |
+
_from: 'axios@0.21.2',
|
| 2179 |
+
_id: 'axios@0.21.2',
|
| 2180 |
+
_inBundle: !1,
|
| 2181 |
+
_integrity:
|
| 2182 |
+
'sha512-87otirqUw3e8CzHTMO+/9kh/FSgXt/eVDvipijwDtEuwbkySWZ9SBm6VEubmJ/kLKEoLQV/POhxXFb66bfekfg==',
|
| 2183 |
+
_location: '/axios',
|
| 2184 |
+
_phantomChildren: {},
|
| 2185 |
+
_requested: {
|
| 2186 |
+
type: 'version',
|
| 2187 |
+
registry: !0,
|
| 2188 |
+
raw: 'axios@0.21.2',
|
| 2189 |
+
name: 'axios',
|
| 2190 |
+
escapedName: 'axios',
|
| 2191 |
+
rawSpec: '0.21.2',
|
| 2192 |
+
saveSpec: null,
|
| 2193 |
+
fetchSpec: '0.21.2',
|
| 2194 |
+
},
|
| 2195 |
+
_requiredBy: ['/'],
|
| 2196 |
+
_resolved: 'https://registry.npmjs.org/axios/-/axios-0.21.2.tgz',
|
| 2197 |
+
_spec: '0.21.2',
|
| 2198 |
+
_where: '/usr/src/app',
|
| 2199 |
+
author: { name: 'Matt Zabriskie' },
|
| 2200 |
+
browser: { './lib/adapters/http.js': './lib/adapters/xhr.js' },
|
| 2201 |
+
bugs: { url: 'https://github.com/axios/axios/issues' },
|
| 2202 |
+
bundlesize: [{ path: './dist/axios.min.js', threshold: '5kB' }],
|
| 2203 |
+
dependencies: { 'follow-redirects': '^1.14.0' },
|
| 2204 |
+
description: 'Promise based HTTP client for the browser and node.js',
|
| 2205 |
+
devDependencies: {
|
| 2206 |
+
coveralls: '^3.0.0',
|
| 2207 |
+
'es6-promise': '^4.2.4',
|
| 2208 |
+
grunt: '^1.3.0',
|
| 2209 |
+
'grunt-banner': '^0.6.0',
|
| 2210 |
+
'grunt-cli': '^1.2.0',
|
| 2211 |
+
'grunt-contrib-clean': '^1.1.0',
|
| 2212 |
+
'grunt-contrib-watch': '^1.0.0',
|
| 2213 |
+
'grunt-eslint': '^23.0.0',
|
| 2214 |
+
'grunt-karma': '^4.0.0',
|
| 2215 |
+
'grunt-mocha-test': '^0.13.3',
|
| 2216 |
+
'grunt-ts': '^6.0.0-beta.19',
|
| 2217 |
+
'grunt-webpack': '^4.0.2',
|
| 2218 |
+
'istanbul-instrumenter-loader': '^1.0.0',
|
| 2219 |
+
'jasmine-core': '^2.4.1',
|
| 2220 |
+
karma: '^6.3.2',
|
| 2221 |
+
'karma-chrome-launcher': '^3.1.0',
|
| 2222 |
+
'karma-firefox-launcher': '^2.1.0',
|
| 2223 |
+
'karma-jasmine': '^1.1.1',
|
| 2224 |
+
'karma-jasmine-ajax': '^0.1.13',
|
| 2225 |
+
'karma-safari-launcher': '^1.0.0',
|
| 2226 |
+
'karma-sauce-launcher': '^4.3.6',
|
| 2227 |
+
'karma-sinon': '^1.0.5',
|
| 2228 |
+
'karma-sourcemap-loader': '^0.3.8',
|
| 2229 |
+
'karma-webpack': '^4.0.2',
|
| 2230 |
+
'load-grunt-tasks': '^3.5.2',
|
| 2231 |
+
minimist: '^1.2.0',
|
| 2232 |
+
mocha: '^8.2.1',
|
| 2233 |
+
sinon: '^4.5.0',
|
| 2234 |
+
'terser-webpack-plugin': '^4.2.3',
|
| 2235 |
+
typescript: '^4.0.5',
|
| 2236 |
+
'url-search-params': '^0.10.0',
|
| 2237 |
+
webpack: '^4.44.2',
|
| 2238 |
+
'webpack-dev-server': '^3.11.0',
|
| 2239 |
+
},
|
| 2240 |
+
homepage: 'https://axios-http.com',
|
| 2241 |
+
jsdelivr: 'dist/axios.min.js',
|
| 2242 |
+
keywords: ['xhr', 'http', 'ajax', 'promise', 'node'],
|
| 2243 |
+
license: 'MIT',
|
| 2244 |
+
main: 'index.js',
|
| 2245 |
+
name: 'axios',
|
| 2246 |
+
repository: { type: 'git', url: 'git+https://github.com/axios/axios.git' },
|
| 2247 |
+
scripts: {
|
| 2248 |
+
build: 'NODE_ENV=production grunt build',
|
| 2249 |
+
coveralls: 'cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js',
|
| 2250 |
+
examples: 'node ./examples/server.js',
|
| 2251 |
+
fix: 'eslint --fix lib/**/*.js',
|
| 2252 |
+
postversion: 'git push && git push --tags',
|
| 2253 |
+
preversion: 'npm test',
|
| 2254 |
+
start: 'node ./sandbox/server.js',
|
| 2255 |
+
test: 'grunt test',
|
| 2256 |
+
version:
|
| 2257 |
+
'npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json',
|
| 2258 |
+
},
|
| 2259 |
+
typings: './index.d.ts',
|
| 2260 |
+
unpkg: 'dist/axios.min.js',
|
| 2261 |
+
version: '0.21.2',
|
| 2262 |
+
},
|
| 2263 |
+
N = {}
|
| 2264 |
+
;['object', 'boolean', 'number', 'function', 'string', 'symbol'].forEach(function (t, e) {
|
| 2265 |
+
N[t] = function (i) {
|
| 2266 |
+
return typeof i === t || 'a' + (e < 1 ? 'n ' : ' ') + t
|
| 2267 |
+
}
|
| 2268 |
+
})
|
| 2269 |
+
var q = {},
|
| 2270 |
+
j = I.version.split('.')
|
| 2271 |
+
function X(t, e) {
|
| 2272 |
+
for (var i = e ? e.split('.') : j, n = t.split('.'), r = 0; r < 3; r++) {
|
| 2273 |
+
if (i[r] > n[r]) return !0
|
| 2274 |
+
if (i[r] < n[r]) return !1
|
| 2275 |
+
}
|
| 2276 |
+
return !1
|
| 2277 |
+
}
|
| 2278 |
+
N.transitional = function (t, e, i) {
|
| 2279 |
+
var n = e && X(e)
|
| 2280 |
+
function r(t, e) {
|
| 2281 |
+
return '[Axios v' + I.version + "] Transitional option '" + t + "'" + e + (i ? '. ' + i : '')
|
| 2282 |
+
}
|
| 2283 |
+
return function (i, s, o) {
|
| 2284 |
+
if (!1 === t) throw new Error(r(s, ' has been removed in ' + e))
|
| 2285 |
+
return (
|
| 2286 |
+
n &&
|
| 2287 |
+
!q[s] &&
|
| 2288 |
+
((q[s] = !0),
|
| 2289 |
+
console.warn(r(s, ' has been deprecated since v' + e + ' and will be removed in the near future'))),
|
| 2290 |
+
!t || t(i, s, o)
|
| 2291 |
+
)
|
| 2292 |
+
}
|
| 2293 |
+
}
|
| 2294 |
+
var F = {
|
| 2295 |
+
isOlderVersion: X,
|
| 2296 |
+
assertOptions: function (t, e, i) {
|
| 2297 |
+
if ('object' != typeof t) throw new TypeError('options must be an object')
|
| 2298 |
+
for (var n = Object.keys(t), r = n.length; r-- > 0; ) {
|
| 2299 |
+
var s = n[r],
|
| 2300 |
+
o = e[s]
|
| 2301 |
+
if (o) {
|
| 2302 |
+
var a = t[s],
|
| 2303 |
+
l = void 0 === a || o(a, s, t)
|
| 2304 |
+
if (!0 !== l) throw new TypeError('option ' + s + ' must be ' + l)
|
| 2305 |
+
} else if (!0 !== i) throw Error('Unknown option ' + s)
|
| 2306 |
+
}
|
| 2307 |
+
},
|
| 2308 |
+
validators: N,
|
| 2309 |
+
},
|
| 2310 |
+
H = F.validators
|
| 2311 |
+
function Y(t) {
|
| 2312 |
+
;(this.defaults = t), (this.interceptors = { request: new g(), response: new g() })
|
| 2313 |
+
}
|
| 2314 |
+
;(Y.prototype.request = function (t) {
|
| 2315 |
+
'string' == typeof t ? ((t = arguments[1] || {}).url = arguments[0]) : (t = t || {}),
|
| 2316 |
+
(t = M(this.defaults, t)).method
|
| 2317 |
+
? (t.method = t.method.toLowerCase())
|
| 2318 |
+
: this.defaults.method
|
| 2319 |
+
? (t.method = this.defaults.method.toLowerCase())
|
| 2320 |
+
: (t.method = 'get')
|
| 2321 |
+
var e = t.transitional
|
| 2322 |
+
void 0 !== e &&
|
| 2323 |
+
F.assertOptions(
|
| 2324 |
+
e,
|
| 2325 |
+
{
|
| 2326 |
+
silentJSONParsing: H.transitional(H.boolean, '1.0.0'),
|
| 2327 |
+
forcedJSONParsing: H.transitional(H.boolean, '1.0.0'),
|
| 2328 |
+
clarifyTimeoutError: H.transitional(H.boolean, '1.0.0'),
|
| 2329 |
+
},
|
| 2330 |
+
!1,
|
| 2331 |
+
)
|
| 2332 |
+
var i = [],
|
| 2333 |
+
n = !0
|
| 2334 |
+
this.interceptors.request.forEach(function (e) {
|
| 2335 |
+
;('function' == typeof e.runWhen && !1 === e.runWhen(t)) ||
|
| 2336 |
+
((n = n && e.synchronous), i.unshift(e.fulfilled, e.rejected))
|
| 2337 |
+
})
|
| 2338 |
+
var r,
|
| 2339 |
+
s = []
|
| 2340 |
+
if (
|
| 2341 |
+
(this.interceptors.response.forEach(function (t) {
|
| 2342 |
+
s.push(t.fulfilled, t.rejected)
|
| 2343 |
+
}),
|
| 2344 |
+
!n)
|
| 2345 |
+
) {
|
| 2346 |
+
var o = [C, void 0]
|
| 2347 |
+
for (Array.prototype.unshift.apply(o, i), o.concat(s), r = Promise.resolve(t); o.length; )
|
| 2348 |
+
r = r.then(o.shift(), o.shift())
|
| 2349 |
+
return r
|
| 2350 |
+
}
|
| 2351 |
+
for (var a = t; i.length; ) {
|
| 2352 |
+
var l = i.shift(),
|
| 2353 |
+
h = i.shift()
|
| 2354 |
+
try {
|
| 2355 |
+
a = l(a)
|
| 2356 |
+
} catch (t) {
|
| 2357 |
+
h(t)
|
| 2358 |
+
break
|
| 2359 |
+
}
|
| 2360 |
+
}
|
| 2361 |
+
try {
|
| 2362 |
+
r = C(a)
|
| 2363 |
+
} catch (t) {
|
| 2364 |
+
return Promise.reject(t)
|
| 2365 |
+
}
|
| 2366 |
+
for (; s.length; ) r = r.then(s.shift(), s.shift())
|
| 2367 |
+
return r
|
| 2368 |
+
}),
|
| 2369 |
+
(Y.prototype.getUri = function (t) {
|
| 2370 |
+
return (t = M(this.defaults, t)), _(t.url, t.params, t.paramsSerializer).replace(/^\?/, '')
|
| 2371 |
+
}),
|
| 2372 |
+
f.forEach(['delete', 'get', 'head', 'options'], function (t) {
|
| 2373 |
+
Y.prototype[t] = function (e, i) {
|
| 2374 |
+
return this.request(M(i || {}, { method: t, url: e, data: (i || {}).data }))
|
| 2375 |
+
}
|
| 2376 |
+
}),
|
| 2377 |
+
f.forEach(['post', 'put', 'patch'], function (t) {
|
| 2378 |
+
Y.prototype[t] = function (e, i, n) {
|
| 2379 |
+
return this.request(M(n || {}, { method: t, url: e, data: i }))
|
| 2380 |
+
}
|
| 2381 |
+
})
|
| 2382 |
+
var B = Y
|
| 2383 |
+
function z(t) {
|
| 2384 |
+
this.message = t
|
| 2385 |
+
}
|
| 2386 |
+
;(z.prototype.toString = function () {
|
| 2387 |
+
return 'Cancel' + (this.message ? ': ' + this.message : '')
|
| 2388 |
+
}),
|
| 2389 |
+
(z.prototype.__CANCEL__ = !0)
|
| 2390 |
+
var W = z
|
| 2391 |
+
function $(t) {
|
| 2392 |
+
if ('function' != typeof t) throw new TypeError('executor must be a function.')
|
| 2393 |
+
var e
|
| 2394 |
+
this.promise = new Promise(function (t) {
|
| 2395 |
+
e = t
|
| 2396 |
+
})
|
| 2397 |
+
var i = this
|
| 2398 |
+
t(function (t) {
|
| 2399 |
+
i.reason || ((i.reason = new W(t)), e(i.reason))
|
| 2400 |
+
})
|
| 2401 |
+
}
|
| 2402 |
+
;($.prototype.throwIfRequested = function () {
|
| 2403 |
+
if (this.reason) throw this.reason
|
| 2404 |
+
}),
|
| 2405 |
+
($.source = function () {
|
| 2406 |
+
var t
|
| 2407 |
+
return {
|
| 2408 |
+
token: new $(function (e) {
|
| 2409 |
+
t = e
|
| 2410 |
+
}),
|
| 2411 |
+
cancel: t,
|
| 2412 |
+
}
|
| 2413 |
+
})
|
| 2414 |
+
var G = $
|
| 2415 |
+
function U(t) {
|
| 2416 |
+
var e = new B(t),
|
| 2417 |
+
i = s(B.prototype.request, e)
|
| 2418 |
+
return f.extend(i, B.prototype, e), f.extend(i, e), i
|
| 2419 |
+
}
|
| 2420 |
+
var V = U(R)
|
| 2421 |
+
;(V.Axios = B),
|
| 2422 |
+
(V.create = function (t) {
|
| 2423 |
+
return U(M(V.defaults, t))
|
| 2424 |
+
}),
|
| 2425 |
+
(V.Cancel = W),
|
| 2426 |
+
(V.CancelToken = G),
|
| 2427 |
+
(V.isCancel = O),
|
| 2428 |
+
(V.all = function (t) {
|
| 2429 |
+
return Promise.all(t)
|
| 2430 |
+
}),
|
| 2431 |
+
(V.spread = function (t) {
|
| 2432 |
+
return function (e) {
|
| 2433 |
+
return t.apply(null, e)
|
| 2434 |
+
}
|
| 2435 |
+
}),
|
| 2436 |
+
(V.isAxiosError = function (t) {
|
| 2437 |
+
return 'object' == typeof t && !0 === t.isAxiosError
|
| 2438 |
+
})
|
| 2439 |
+
var J = V,
|
| 2440 |
+
K = V
|
| 2441 |
+
J.default = K
|
| 2442 |
+
var Q = J.create({
|
| 2443 |
+
baseURL: window.metagalleryData.root,
|
| 2444 |
+
headers: { 'X-WP-Nonce': window.metagalleryData.nonce, 'X-Requested-With': 'XMLHttpRequest' },
|
| 2445 |
+
}),
|
| 2446 |
+
Z = function (t, e, i, n) {
|
| 2447 |
+
var r = new FormData()
|
| 2448 |
+
return (
|
| 2449 |
+
r.append('title', e),
|
| 2450 |
+
r.append('images', JSON.stringify(i)),
|
| 2451 |
+
r.append('settings', JSON.stringify(n)),
|
| 2452 |
+
Q.post('gallery/' + t, r, { headers: { 'Content-Type': 'multipart/form-data' } })
|
| 2453 |
+
)
|
| 2454 |
+
}
|
| 2455 |
+
/**
|
| 2456 |
+
* Muuri v0.9.3
|
| 2457 |
+
* https://muuri.dev/
|
| 2458 |
+
* Copyright (c) 2015-present, Haltu Oy
|
| 2459 |
+
* Released under the MIT license
|
| 2460 |
+
* https://github.com/haltu/muuri/blob/master/LICENSE.md
|
| 2461 |
+
* @license MIT
|
| 2462 |
+
*
|
| 2463 |
+
* Muuri Packer
|
| 2464 |
+
* Copyright (c) 2016-present, Niklas Rämö <inramo@gmail.com>
|
| 2465 |
+
* @license MIT
|
| 2466 |
+
*
|
| 2467 |
+
* Muuri Ticker / Muuri Emitter / Muuri Dragger
|
| 2468 |
+
* Copyright (c) 2018-present, Niklas Rämö <inramo@gmail.com>
|
| 2469 |
+
* @license MIT
|
| 2470 |
+
*
|
| 2471 |
+
* Muuri AutoScroller
|
| 2472 |
+
* Copyright (c) 2019-present, Niklas Rämö <inramo@gmail.com>
|
| 2473 |
+
* @license MIT
|
| 2474 |
+
*/
|
| 2475 |
+
var tt = {},
|
| 2476 |
+
et = 'function' == typeof Map ? new Map() : null,
|
| 2477 |
+
it = 'swap',
|
| 2478 |
+
nt = 'move',
|
| 2479 |
+
rt = 'layoutStart',
|
| 2480 |
+
st = 'layoutEnd',
|
| 2481 |
+
ot = 'layoutAbort',
|
| 2482 |
+
at = 'remove',
|
| 2483 |
+
lt = 'hideStart',
|
| 2484 |
+
ht = 'filter',
|
| 2485 |
+
ut = 'sort',
|
| 2486 |
+
ct = 'move',
|
| 2487 |
+
dt = 'send',
|
| 2488 |
+
ft = 'beforeSend',
|
| 2489 |
+
pt = 'receive',
|
| 2490 |
+
_t = 'beforeReceive',
|
| 2491 |
+
mt = 'dragReleaseEnd',
|
| 2492 |
+
gt = 'ontouchstart' in window,
|
| 2493 |
+
vt = !!window.PointerEvent,
|
| 2494 |
+
yt = !!window.navigator.msPointerEnabled
|
| 2495 |
+
function bt() {
|
| 2496 |
+
;(this._events = {}), (this._queue = []), (this._counter = 0), (this._clearOnEmit = !1)
|
| 2497 |
+
}
|
| 2498 |
+
;(bt.prototype.on = function (t, e) {
|
| 2499 |
+
if (!this._events || !t || !e) return this
|
| 2500 |
+
var i = this._events[t]
|
| 2501 |
+
return i || (i = this._events[t] = []), i.push(e), this
|
| 2502 |
+
}),
|
| 2503 |
+
(bt.prototype.off = function (t, e) {
|
| 2504 |
+
if (!this._events || !t || !e) return this
|
| 2505 |
+
var i,
|
| 2506 |
+
n = this._events[t]
|
| 2507 |
+
if (!n || !n.length) return this
|
| 2508 |
+
for (; -1 !== (i = n.indexOf(e)); ) n.splice(i, 1)
|
| 2509 |
+
return this
|
| 2510 |
+
}),
|
| 2511 |
+
(bt.prototype.clear = function (t) {
|
| 2512 |
+
if (!this._events || !t) return this
|
| 2513 |
+
var e = this._events[t]
|
| 2514 |
+
return e && ((e.length = 0), delete this._events[t]), this
|
| 2515 |
+
}),
|
| 2516 |
+
(bt.prototype.emit = function (t) {
|
| 2517 |
+
if (!this._events || !t) return (this._clearOnEmit = !1), this
|
| 2518 |
+
var e = this._events[t]
|
| 2519 |
+
if (!e || !e.length) return (this._clearOnEmit = !1), this
|
| 2520 |
+
var i,
|
| 2521 |
+
n = this._queue,
|
| 2522 |
+
r = n.length,
|
| 2523 |
+
s = arguments.length - 1
|
| 2524 |
+
s > 3 && ((i = []).push.apply(i, arguments), i.shift()),
|
| 2525 |
+
n.push.apply(n, e),
|
| 2526 |
+
this._clearOnEmit && ((e.length = 0), (this._clearOnEmit = !1)),
|
| 2527 |
+
++this._counter
|
| 2528 |
+
for (var o = r, a = n.length; o < a; o++)
|
| 2529 |
+
if (
|
| 2530 |
+
(0 === s
|
| 2531 |
+
? n[o]()
|
| 2532 |
+
: 1 === s
|
| 2533 |
+
? n[o](arguments[1])
|
| 2534 |
+
: 2 === s
|
| 2535 |
+
? n[o](arguments[1], arguments[2])
|
| 2536 |
+
: 3 === s
|
| 2537 |
+
? n[o](arguments[1], arguments[2], arguments[3])
|
| 2538 |
+
: n[o].apply(null, i),
|
| 2539 |
+
!this._events)
|
| 2540 |
+
)
|
| 2541 |
+
return this
|
| 2542 |
+
return --this._counter, this._counter || (n.length = 0), this
|
| 2543 |
+
}),
|
| 2544 |
+
(bt.prototype.burst = function () {
|
| 2545 |
+
return this._events ? ((this._clearOnEmit = !0), this.emit.apply(this, arguments), this) : this
|
| 2546 |
+
}),
|
| 2547 |
+
(bt.prototype.countListeners = function (t) {
|
| 2548 |
+
if (!this._events) return 0
|
| 2549 |
+
var e = this._events[t]
|
| 2550 |
+
return e ? e.length : 0
|
| 2551 |
+
}),
|
| 2552 |
+
(bt.prototype.destroy = function () {
|
| 2553 |
+
return this._events ? ((this._queue.length = this._counter = 0), (this._events = null), this) : this
|
| 2554 |
+
})
|
| 2555 |
+
var wt = vt ? 'pointerout' : yt ? 'MSPointerOut' : ''
|
| 2556 |
+
function xt(t) {
|
| 2557 |
+
wt &&
|
| 2558 |
+
((this._dragger = t),
|
| 2559 |
+
(this._timeout = null),
|
| 2560 |
+
(this._outEvent = null),
|
| 2561 |
+
(this._isActive = !1),
|
| 2562 |
+
(this._addBehaviour = this._addBehaviour.bind(this)),
|
| 2563 |
+
(this._removeBehaviour = this._removeBehaviour.bind(this)),
|
| 2564 |
+
(this._onTimeout = this._onTimeout.bind(this)),
|
| 2565 |
+
(this._resetData = this._resetData.bind(this)),
|
| 2566 |
+
(this._onStart = this._onStart.bind(this)),
|
| 2567 |
+
(this._onOut = this._onOut.bind(this)),
|
| 2568 |
+
this._dragger.on('start', this._onStart))
|
| 2569 |
+
}
|
| 2570 |
+
;(xt.prototype._addBehaviour = function () {
|
| 2571 |
+
this._isActive ||
|
| 2572 |
+
((this._isActive = !0),
|
| 2573 |
+
this._dragger.on('move', this._resetData),
|
| 2574 |
+
this._dragger.on('cancel', this._removeBehaviour),
|
| 2575 |
+
this._dragger.on('end', this._removeBehaviour),
|
| 2576 |
+
window.addEventListener(wt, this._onOut))
|
| 2577 |
+
}),
|
| 2578 |
+
(xt.prototype._removeBehaviour = function () {
|
| 2579 |
+
this._isActive &&
|
| 2580 |
+
(this._dragger.off('move', this._resetData),
|
| 2581 |
+
this._dragger.off('cancel', this._removeBehaviour),
|
| 2582 |
+
this._dragger.off('end', this._removeBehaviour),
|
| 2583 |
+
window.removeEventListener(wt, this._onOut),
|
| 2584 |
+
this._resetData(),
|
| 2585 |
+
(this._isActive = !1))
|
| 2586 |
+
}),
|
| 2587 |
+
(xt.prototype._resetData = function () {
|
| 2588 |
+
window.clearTimeout(this._timeout), (this._timeout = null), (this._outEvent = null)
|
| 2589 |
+
}),
|
| 2590 |
+
(xt.prototype._onStart = function (t) {
|
| 2591 |
+
'mouse' !== t.pointerType && this._addBehaviour()
|
| 2592 |
+
}),
|
| 2593 |
+
(xt.prototype._onOut = function (t) {
|
| 2594 |
+
this._dragger._getTrackedTouch(t) &&
|
| 2595 |
+
(this._resetData(), (this._outEvent = t), (this._timeout = window.setTimeout(this._onTimeout, 100)))
|
| 2596 |
+
}),
|
| 2597 |
+
(xt.prototype._onTimeout = function () {
|
| 2598 |
+
var t = this._outEvent
|
| 2599 |
+
this._resetData(), this._dragger.isActive() && this._dragger._onCancel(t)
|
| 2600 |
+
}),
|
| 2601 |
+
(xt.prototype.destroy = function () {
|
| 2602 |
+
wt && (this._dragger.off('start', this._onStart), this._removeBehaviour())
|
| 2603 |
+
})
|
| 2604 |
+
var St = ['', 'webkit', 'moz', 'ms', 'o', 'Webkit', 'Moz', 'MS', 'O'],
|
| 2605 |
+
Et = {}
|
| 2606 |
+
function Tt(t, e) {
|
| 2607 |
+
var i = Et[e] || ''
|
| 2608 |
+
if (i) return i
|
| 2609 |
+
for (var n = e[0].toUpperCase() + e.slice(1), r = 0; r < St.length; ) {
|
| 2610 |
+
if ((i = St[r] ? St[r] + n : e) in t) return (Et[e] = i), i
|
| 2611 |
+
++r
|
| 2612 |
+
}
|
| 2613 |
+
return ''
|
| 2614 |
+
}
|
| 2615 |
+
function Dt() {
|
| 2616 |
+
var t = !1
|
| 2617 |
+
try {
|
| 2618 |
+
var e = Object.defineProperty({}, 'passive', {
|
| 2619 |
+
get: function () {
|
| 2620 |
+
t = !0
|
| 2621 |
+
},
|
| 2622 |
+
})
|
| 2623 |
+
window.addEventListener('testPassive', null, e), window.removeEventListener('testPassive', null, e)
|
| 2624 |
+
} catch (t) {}
|
| 2625 |
+
return t
|
| 2626 |
+
}
|
| 2627 |
+
var At = window.navigator.userAgent.toLowerCase(),
|
| 2628 |
+
kt = At.indexOf('edge') > -1,
|
| 2629 |
+
Rt = At.indexOf('trident') > -1,
|
| 2630 |
+
Pt = At.indexOf('firefox') > -1,
|
| 2631 |
+
Ot = At.indexOf('android') > -1,
|
| 2632 |
+
Lt = !!Dt() && { passive: !0 },
|
| 2633 |
+
Ct = 'touchAction',
|
| 2634 |
+
Mt = Tt(document.documentElement.style, Ct)
|
| 2635 |
+
function It(t, e) {
|
| 2636 |
+
;(this._element = t),
|
| 2637 |
+
(this._emitter = new bt()),
|
| 2638 |
+
(this._isDestroyed = !1),
|
| 2639 |
+
(this._cssProps = {}),
|
| 2640 |
+
(this._touchAction = ''),
|
| 2641 |
+
(this._isActive = !1),
|
| 2642 |
+
(this._pointerId = null),
|
| 2643 |
+
(this._startTime = 0),
|
| 2644 |
+
(this._startX = 0),
|
| 2645 |
+
(this._startY = 0),
|
| 2646 |
+
(this._currentX = 0),
|
| 2647 |
+
(this._currentY = 0),
|
| 2648 |
+
(this._onStart = this._onStart.bind(this)),
|
| 2649 |
+
(this._onMove = this._onMove.bind(this)),
|
| 2650 |
+
(this._onCancel = this._onCancel.bind(this)),
|
| 2651 |
+
(this._onEnd = this._onEnd.bind(this)),
|
| 2652 |
+
(this._edgeHack = null),
|
| 2653 |
+
(kt || Rt) && (vt || yt) && (this._edgeHack = new xt(this)),
|
| 2654 |
+
this.setCssProps(e),
|
| 2655 |
+
this._touchAction || this.setTouchAction('auto'),
|
| 2656 |
+
t.addEventListener('dragstart', It._preventDefault, !1),
|
| 2657 |
+
t.addEventListener(It._inputEvents.start, this._onStart, Lt)
|
| 2658 |
+
}
|
| 2659 |
+
;(It._pointerEvents = { start: 'pointerdown', move: 'pointermove', cancel: 'pointercancel', end: 'pointerup' }),
|
| 2660 |
+
(It._msPointerEvents = {
|
| 2661 |
+
start: 'MSPointerDown',
|
| 2662 |
+
move: 'MSPointerMove',
|
| 2663 |
+
cancel: 'MSPointerCancel',
|
| 2664 |
+
end: 'MSPointerUp',
|
| 2665 |
+
}),
|
| 2666 |
+
(It._touchEvents = { start: 'touchstart', move: 'touchmove', cancel: 'touchcancel', end: 'touchend' }),
|
| 2667 |
+
(It._mouseEvents = { start: 'mousedown', move: 'mousemove', cancel: '', end: 'mouseup' }),
|
| 2668 |
+
(It._inputEvents = gt ? It._touchEvents : vt ? It._pointerEvents : yt ? It._msPointerEvents : It._mouseEvents),
|
| 2669 |
+
(It._emitter = new bt()),
|
| 2670 |
+
(It._emitterEvents = { start: 'start', move: 'move', end: 'end', cancel: 'cancel' }),
|
| 2671 |
+
(It._activeInstances = []),
|
| 2672 |
+
(It._preventDefault = function (t) {
|
| 2673 |
+
t.preventDefault && !1 !== t.cancelable && t.preventDefault()
|
| 2674 |
+
}),
|
| 2675 |
+
(It._activateInstance = function (t) {
|
| 2676 |
+
It._activeInstances.indexOf(t) > -1 ||
|
| 2677 |
+
(It._activeInstances.push(t),
|
| 2678 |
+
It._emitter.on(It._emitterEvents.move, t._onMove),
|
| 2679 |
+
It._emitter.on(It._emitterEvents.cancel, t._onCancel),
|
| 2680 |
+
It._emitter.on(It._emitterEvents.end, t._onEnd),
|
| 2681 |
+
1 === It._activeInstances.length && It._bindListeners())
|
| 2682 |
+
}),
|
| 2683 |
+
(It._deactivateInstance = function (t) {
|
| 2684 |
+
var e = It._activeInstances.indexOf(t)
|
| 2685 |
+
;-1 !== e &&
|
| 2686 |
+
(It._activeInstances.splice(e, 1),
|
| 2687 |
+
It._emitter.off(It._emitterEvents.move, t._onMove),
|
| 2688 |
+
It._emitter.off(It._emitterEvents.cancel, t._onCancel),
|
| 2689 |
+
It._emitter.off(It._emitterEvents.end, t._onEnd),
|
| 2690 |
+
It._activeInstances.length || It._unbindListeners())
|
| 2691 |
+
}),
|
| 2692 |
+
(It._bindListeners = function () {
|
| 2693 |
+
window.addEventListener(It._inputEvents.move, It._onMove, Lt),
|
| 2694 |
+
window.addEventListener(It._inputEvents.end, It._onEnd, Lt),
|
| 2695 |
+
It._inputEvents.cancel && window.addEventListener(It._inputEvents.cancel, It._onCancel, Lt)
|
| 2696 |
+
}),
|
| 2697 |
+
(It._unbindListeners = function () {
|
| 2698 |
+
window.removeEventListener(It._inputEvents.move, It._onMove, Lt),
|
| 2699 |
+
window.removeEventListener(It._inputEvents.end, It._onEnd, Lt),
|
| 2700 |
+
It._inputEvents.cancel && window.removeEventListener(It._inputEvents.cancel, It._onCancel, Lt)
|
| 2701 |
+
}),
|
| 2702 |
+
(It._getEventPointerId = function (t) {
|
| 2703 |
+
return 'number' == typeof t.pointerId
|
| 2704 |
+
? t.pointerId
|
| 2705 |
+
: t.changedTouches
|
| 2706 |
+
? t.changedTouches[0]
|
| 2707 |
+
? t.changedTouches[0].identifier
|
| 2708 |
+
: null
|
| 2709 |
+
: 1
|
| 2710 |
+
}),
|
| 2711 |
+
(It._getTouchById = function (t, e) {
|
| 2712 |
+
if ('number' == typeof t.pointerId) return t.pointerId === e ? t : null
|
| 2713 |
+
if (t.changedTouches) {
|
| 2714 |
+
for (var i = 0; i < t.changedTouches.length; i++)
|
| 2715 |
+
if (t.changedTouches[i].identifier === e) return t.changedTouches[i]
|
| 2716 |
+
return null
|
| 2717 |
+
}
|
| 2718 |
+
return t
|
| 2719 |
+
}),
|
| 2720 |
+
(It._onMove = function (t) {
|
| 2721 |
+
It._emitter.emit(It._emitterEvents.move, t)
|
| 2722 |
+
}),
|
| 2723 |
+
(It._onCancel = function (t) {
|
| 2724 |
+
It._emitter.emit(It._emitterEvents.cancel, t)
|
| 2725 |
+
}),
|
| 2726 |
+
(It._onEnd = function (t) {
|
| 2727 |
+
It._emitter.emit(It._emitterEvents.end, t)
|
| 2728 |
+
}),
|
| 2729 |
+
(It.prototype._reset = function () {
|
| 2730 |
+
;(this._pointerId = null),
|
| 2731 |
+
(this._startTime = 0),
|
| 2732 |
+
(this._startX = 0),
|
| 2733 |
+
(this._startY = 0),
|
| 2734 |
+
(this._currentX = 0),
|
| 2735 |
+
(this._currentY = 0),
|
| 2736 |
+
(this._isActive = !1),
|
| 2737 |
+
It._deactivateInstance(this)
|
| 2738 |
+
}),
|
| 2739 |
+
(It.prototype._createEvent = function (t, e) {
|
| 2740 |
+
var i = this._getTrackedTouch(e)
|
| 2741 |
+
return {
|
| 2742 |
+
type: t,
|
| 2743 |
+
srcEvent: e,
|
| 2744 |
+
distance: this.getDistance(),
|
| 2745 |
+
deltaX: this.getDeltaX(),
|
| 2746 |
+
deltaY: this.getDeltaY(),
|
| 2747 |
+
deltaTime: t === It._emitterEvents.start ? 0 : this.getDeltaTime(),
|
| 2748 |
+
isFirst: t === It._emitterEvents.start,
|
| 2749 |
+
isFinal: t === It._emitterEvents.end || t === It._emitterEvents.cancel,
|
| 2750 |
+
pointerType: e.pointerType || (e.touches ? 'touch' : 'mouse'),
|
| 2751 |
+
identifier: this._pointerId,
|
| 2752 |
+
screenX: i.screenX,
|
| 2753 |
+
screenY: i.screenY,
|
| 2754 |
+
clientX: i.clientX,
|
| 2755 |
+
clientY: i.clientY,
|
| 2756 |
+
pageX: i.pageX,
|
| 2757 |
+
pageY: i.pageY,
|
| 2758 |
+
target: i.target,
|
| 2759 |
+
}
|
| 2760 |
+
}),
|
| 2761 |
+
(It.prototype._emit = function (t, e) {
|
| 2762 |
+
this._emitter.emit(t, this._createEvent(t, e))
|
| 2763 |
+
}),
|
| 2764 |
+
(It.prototype._getTrackedTouch = function (t) {
|
| 2765 |
+
return null === this._pointerId ? null : It._getTouchById(t, this._pointerId)
|
| 2766 |
+
}),
|
| 2767 |
+
(It.prototype._onStart = function (t) {
|
| 2768 |
+
if (
|
| 2769 |
+
!this._isDestroyed &&
|
| 2770 |
+
null === this._pointerId &&
|
| 2771 |
+
((this._pointerId = It._getEventPointerId(t)), null !== this._pointerId)
|
| 2772 |
+
) {
|
| 2773 |
+
var e = this._getTrackedTouch(t)
|
| 2774 |
+
;(this._startX = this._currentX = e.clientX),
|
| 2775 |
+
(this._startY = this._currentY = e.clientY),
|
| 2776 |
+
(this._startTime = Date.now()),
|
| 2777 |
+
(this._isActive = !0),
|
| 2778 |
+
this._emit(It._emitterEvents.start, t),
|
| 2779 |
+
this._isActive && It._activateInstance(this)
|
| 2780 |
+
}
|
| 2781 |
+
}),
|
| 2782 |
+
(It.prototype._onMove = function (t) {
|
| 2783 |
+
var e = this._getTrackedTouch(t)
|
| 2784 |
+
e && ((this._currentX = e.clientX), (this._currentY = e.clientY), this._emit(It._emitterEvents.move, t))
|
| 2785 |
+
}),
|
| 2786 |
+
(It.prototype._onCancel = function (t) {
|
| 2787 |
+
this._getTrackedTouch(t) && (this._emit(It._emitterEvents.cancel, t), this._reset())
|
| 2788 |
+
}),
|
| 2789 |
+
(It.prototype._onEnd = function (t) {
|
| 2790 |
+
this._getTrackedTouch(t) && (this._emit(It._emitterEvents.end, t), this._reset())
|
| 2791 |
+
}),
|
| 2792 |
+
(It.prototype.isActive = function () {
|
| 2793 |
+
return this._isActive
|
| 2794 |
+
}),
|
| 2795 |
+
(It.prototype.setTouchAction = function (t) {
|
| 2796 |
+
;(this._touchAction = t),
|
| 2797 |
+
Mt && ((this._cssProps[Mt] = ''), (this._element.style[Mt] = t)),
|
| 2798 |
+
gt &&
|
| 2799 |
+
(this._element.removeEventListener(It._touchEvents.start, It._preventDefault, !0),
|
| 2800 |
+
(this._element.style[Mt] !== t || (Pt && Ot)) &&
|
| 2801 |
+
this._element.addEventListener(It._touchEvents.start, It._preventDefault, !0))
|
| 2802 |
+
}),
|
| 2803 |
+
(It.prototype.setCssProps = function (t) {
|
| 2804 |
+
if (t) {
|
| 2805 |
+
var e,
|
| 2806 |
+
i,
|
| 2807 |
+
n = this._cssProps,
|
| 2808 |
+
r = this._element
|
| 2809 |
+
for (e in n) (r.style[e] = n[e]), delete n[e]
|
| 2810 |
+
for (e in t)
|
| 2811 |
+
t[e] &&
|
| 2812 |
+
(e !== Ct
|
| 2813 |
+
? (i = Tt(r.style, e)) && ((n[i] = ''), (r.style[i] = t[e]))
|
| 2814 |
+
: this.setTouchAction(t[e]))
|
| 2815 |
+
}
|
| 2816 |
+
}),
|
| 2817 |
+
(It.prototype.getDeltaX = function () {
|
| 2818 |
+
return this._currentX - this._startX
|
| 2819 |
+
}),
|
| 2820 |
+
(It.prototype.getDeltaY = function () {
|
| 2821 |
+
return this._currentY - this._startY
|
| 2822 |
+
}),
|
| 2823 |
+
(It.prototype.getDistance = function () {
|
| 2824 |
+
var t = this.getDeltaX(),
|
| 2825 |
+
e = this.getDeltaY()
|
| 2826 |
+
return Math.sqrt(t * t + e * e)
|
| 2827 |
+
}),
|
| 2828 |
+
(It.prototype.getDeltaTime = function () {
|
| 2829 |
+
return this._startTime ? Date.now() - this._startTime : 0
|
| 2830 |
+
}),
|
| 2831 |
+
(It.prototype.on = function (t, e) {
|
| 2832 |
+
this._emitter.on(t, e)
|
| 2833 |
+
}),
|
| 2834 |
+
(It.prototype.off = function (t, e) {
|
| 2835 |
+
this._emitter.off(t, e)
|
| 2836 |
+
}),
|
| 2837 |
+
(It.prototype.destroy = function () {
|
| 2838 |
+
if (!this._isDestroyed) {
|
| 2839 |
+
var t = this._element
|
| 2840 |
+
for (var e in (this._edgeHack && this._edgeHack.destroy(),
|
| 2841 |
+
this._reset(),
|
| 2842 |
+
this._emitter.destroy(),
|
| 2843 |
+
t.removeEventListener(It._inputEvents.start, this._onStart, Lt),
|
| 2844 |
+
t.removeEventListener('dragstart', It._preventDefault, !1),
|
| 2845 |
+
t.removeEventListener(It._touchEvents.start, It._preventDefault, !0),
|
| 2846 |
+
this._cssProps))
|
| 2847 |
+
(t.style[e] = this._cssProps[e]), delete this._cssProps[e]
|
| 2848 |
+
;(this._element = null), (this._isDestroyed = !0)
|
| 2849 |
+
}
|
| 2850 |
+
})
|
| 2851 |
+
var Nt = (
|
| 2852 |
+
window.requestAnimationFrame ||
|
| 2853 |
+
window.webkitRequestAnimationFrame ||
|
| 2854 |
+
window.mozRequestAnimationFrame ||
|
| 2855 |
+
window.msRequestAnimationFrame ||
|
| 2856 |
+
function (t) {
|
| 2857 |
+
return this.setTimeout(function () {
|
| 2858 |
+
t(Date.now())
|
| 2859 |
+
}, 16.666666666666668)
|
| 2860 |
+
}
|
| 2861 |
+
).bind(window)
|
| 2862 |
+
function qt(t) {
|
| 2863 |
+
;(this._nextStep = null),
|
| 2864 |
+
(this._lanes = []),
|
| 2865 |
+
(this._stepQueue = []),
|
| 2866 |
+
(this._stepCallbacks = {}),
|
| 2867 |
+
(this._step = this._step.bind(this))
|
| 2868 |
+
for (var e = 0; e < t; e++) this._lanes.push(new jt())
|
| 2869 |
+
}
|
| 2870 |
+
function jt() {
|
| 2871 |
+
;(this.queue = []), (this.indices = {}), (this.callbacks = {})
|
| 2872 |
+
}
|
| 2873 |
+
;(qt.prototype._step = function (t) {
|
| 2874 |
+
var e,
|
| 2875 |
+
i,
|
| 2876 |
+
n,
|
| 2877 |
+
r,
|
| 2878 |
+
s,
|
| 2879 |
+
o,
|
| 2880 |
+
a = this._lanes,
|
| 2881 |
+
l = this._stepQueue,
|
| 2882 |
+
h = this._stepCallbacks
|
| 2883 |
+
for (this._nextStep = null, e = 0; e < a.length; e++) {
|
| 2884 |
+
for (r = a[e].queue, s = a[e].callbacks, o = a[e].indices, i = 0; i < r.length; i++)
|
| 2885 |
+
(n = r[i]) && (l.push(n), (h[n] = s[n]), delete s[n], delete o[n])
|
| 2886 |
+
r.length = 0
|
| 2887 |
+
}
|
| 2888 |
+
for (e = 0; e < l.length; e++) h[(n = l[e])] && h[n](t), delete h[n]
|
| 2889 |
+
l.length = 0
|
| 2890 |
+
}),
|
| 2891 |
+
(qt.prototype.add = function (t, e, i) {
|
| 2892 |
+
this._lanes[t].add(e, i), this._nextStep || (this._nextStep = Nt(this._step))
|
| 2893 |
+
}),
|
| 2894 |
+
(qt.prototype.remove = function (t, e) {
|
| 2895 |
+
this._lanes[t].remove(e)
|
| 2896 |
+
}),
|
| 2897 |
+
(jt.prototype.add = function (t, e) {
|
| 2898 |
+
var i = this.indices[t]
|
| 2899 |
+
void 0 !== i && (this.queue[i] = void 0),
|
| 2900 |
+
this.queue.push(t),
|
| 2901 |
+
(this.callbacks[t] = e),
|
| 2902 |
+
(this.indices[t] = this.queue.length - 1)
|
| 2903 |
+
}),
|
| 2904 |
+
(jt.prototype.remove = function (t) {
|
| 2905 |
+
var e = this.indices[t]
|
| 2906 |
+
void 0 !== e && ((this.queue[e] = void 0), delete this.callbacks[t], delete this.indices[t])
|
| 2907 |
+
})
|
| 2908 |
+
var Xt = 'layoutRead',
|
| 2909 |
+
Ft = 'layoutWrite',
|
| 2910 |
+
Ht = 'visibilityRead',
|
| 2911 |
+
Yt = 'visibilityWrite',
|
| 2912 |
+
Bt = 'dragStartRead',
|
| 2913 |
+
zt = 'dragStartWrite',
|
| 2914 |
+
Wt = 'dragMoveRead',
|
| 2915 |
+
$t = 'dragMoveWrite',
|
| 2916 |
+
Gt = 'dragScrollRead',
|
| 2917 |
+
Ut = 'dragScrollWrite',
|
| 2918 |
+
Vt = 'dragSortRead',
|
| 2919 |
+
Jt = 'placeholderLayoutRead',
|
| 2920 |
+
Kt = 'placeholderLayoutWrite',
|
| 2921 |
+
Qt = 'placeholderResizeWrite',
|
| 2922 |
+
Zt = 'autoScrollRead',
|
| 2923 |
+
te = 'autoScrollWrite',
|
| 2924 |
+
ee = 'debounceRead',
|
| 2925 |
+
ie = new qt(3)
|
| 2926 |
+
function ne(t) {
|
| 2927 |
+
ie.remove(0, Xt + t), ie.remove(2, Ft + t)
|
| 2928 |
+
}
|
| 2929 |
+
function re(t) {
|
| 2930 |
+
ie.remove(0, Ht + t), ie.remove(2, Yt + t)
|
| 2931 |
+
}
|
| 2932 |
+
function se(t) {
|
| 2933 |
+
ie.remove(0, Bt + t), ie.remove(2, zt + t)
|
| 2934 |
+
}
|
| 2935 |
+
function oe(t) {
|
| 2936 |
+
ie.remove(0, Wt + t), ie.remove(2, $t + t)
|
| 2937 |
+
}
|
| 2938 |
+
function ae(t) {
|
| 2939 |
+
ie.remove(0, Gt + t), ie.remove(2, Ut + t)
|
| 2940 |
+
}
|
| 2941 |
+
function le(t, e) {
|
| 2942 |
+
ie.add(1, Vt + t, e)
|
| 2943 |
+
}
|
| 2944 |
+
function he(t) {
|
| 2945 |
+
ie.remove(0, Jt + t), ie.remove(2, Kt + t)
|
| 2946 |
+
}
|
| 2947 |
+
function ue(t, e) {
|
| 2948 |
+
ie.add(0, Zt, t), ie.add(2, te, e)
|
| 2949 |
+
}
|
| 2950 |
+
function ce(t) {
|
| 2951 |
+
return 'function' == typeof t
|
| 2952 |
+
}
|
| 2953 |
+
var de,
|
| 2954 |
+
fe = 'function' == typeof WeakMap,
|
| 2955 |
+
pe = fe ? new WeakMap() : null,
|
| 2956 |
+
_e = !0,
|
| 2957 |
+
me = function () {
|
| 2958 |
+
_e ? ((de = window.clearInterval(de)), (pe = fe ? new WeakMap() : null)) : (_e = !0)
|
| 2959 |
+
}
|
| 2960 |
+
function ge(t, e) {
|
| 2961 |
+
var i = pe && pe.get(t)
|
| 2962 |
+
return (
|
| 2963 |
+
i || ((i = window.getComputedStyle(t, null)), pe && pe.set(t, i)),
|
| 2964 |
+
pe && (de ? (_e = !1) : (de = window.setInterval(me, 3e3))),
|
| 2965 |
+
i.getPropertyValue(e)
|
| 2966 |
+
)
|
| 2967 |
+
}
|
| 2968 |
+
function ve(t, e) {
|
| 2969 |
+
return parseFloat(ge(t, e)) || 0
|
| 2970 |
+
}
|
| 2971 |
+
var ye,
|
| 2972 |
+
be = document.documentElement,
|
| 2973 |
+
we = document.body,
|
| 2974 |
+
xe = { value: 0, offset: 0 }
|
| 2975 |
+
function Se(t) {
|
| 2976 |
+
return t === window || t === be || t === we ? window : t
|
| 2977 |
+
}
|
| 2978 |
+
function Ee(t) {
|
| 2979 |
+
return t === window ? t.pageXOffset : t.scrollLeft
|
| 2980 |
+
}
|
| 2981 |
+
function Te(t) {
|
| 2982 |
+
return t === window ? t.pageYOffset : t.scrollTop
|
| 2983 |
+
}
|
| 2984 |
+
function De(t) {
|
| 2985 |
+
return t === window ? be.scrollWidth - be.clientWidth : t.scrollWidth - t.clientWidth
|
| 2986 |
+
}
|
| 2987 |
+
function Ae(t) {
|
| 2988 |
+
return t === window ? be.scrollHeight - be.clientHeight : t.scrollHeight - t.clientHeight
|
| 2989 |
+
}
|
| 2990 |
+
function ke(t, e) {
|
| 2991 |
+
if (((e = e || {}), t === window))
|
| 2992 |
+
(e.width = be.clientWidth),
|
| 2993 |
+
(e.height = be.clientHeight),
|
| 2994 |
+
(e.left = 0),
|
| 2995 |
+
(e.right = e.width),
|
| 2996 |
+
(e.top = 0),
|
| 2997 |
+
(e.bottom = e.height)
|
| 2998 |
+
else {
|
| 2999 |
+
var i = t.getBoundingClientRect(),
|
| 3000 |
+
n = t.clientLeft || ve(t, 'border-left-width'),
|
| 3001 |
+
r = t.clientTop || ve(t, 'border-top-width')
|
| 3002 |
+
;(e.width = t.clientWidth),
|
| 3003 |
+
(e.height = t.clientHeight),
|
| 3004 |
+
(e.left = i.left + n),
|
| 3005 |
+
(e.right = e.left + e.width),
|
| 3006 |
+
(e.top = i.top + r),
|
| 3007 |
+
(e.bottom = e.top + e.height)
|
| 3008 |
+
}
|
| 3009 |
+
return e
|
| 3010 |
+
}
|
| 3011 |
+
function Re(t) {
|
| 3012 |
+
return t._drag._getGrid()._settings.dragAutoScroll
|
| 3013 |
+
}
|
| 3014 |
+
function Pe(t) {
|
| 3015 |
+
t._drag && t._drag._prepareScroll()
|
| 3016 |
+
}
|
| 3017 |
+
function Oe(t) {
|
| 3018 |
+
if (t._drag && t._isActive) {
|
| 3019 |
+
var e = t._drag
|
| 3020 |
+
;(e._scrollDiffX = e._scrollDiffY = 0), t._setTranslate(e._left, e._top)
|
| 3021 |
+
}
|
| 3022 |
+
}
|
| 3023 |
+
function Le(t, e, i, n) {
|
| 3024 |
+
return (xe.value = Math.min(n / 2, t)), (xe.offset = Math.max(0, i + 2 * xe.value + n * e - n) / 2), xe
|
| 3025 |
+
}
|
| 3026 |
+
function Ce() {
|
| 3027 |
+
this.reset()
|
| 3028 |
+
}
|
| 3029 |
+
function Me() {
|
| 3030 |
+
;(this.element = null),
|
| 3031 |
+
(this.requestX = null),
|
| 3032 |
+
(this.requestY = null),
|
| 3033 |
+
(this.scrollLeft = 0),
|
| 3034 |
+
(this.scrollTop = 0)
|
| 3035 |
+
}
|
| 3036 |
+
function Ie(t, e) {
|
| 3037 |
+
;(this.pool = []), (this.createItem = t), (this.releaseItem = e)
|
| 3038 |
+
}
|
| 3039 |
+
function Ne(t, e) {
|
| 3040 |
+
var i = (function (t, e) {
|
| 3041 |
+
return (function (t, e) {
|
| 3042 |
+
return !(
|
| 3043 |
+
t.left + t.width <= e.left ||
|
| 3044 |
+
e.left + e.width <= t.left ||
|
| 3045 |
+
t.top + t.height <= e.top ||
|
| 3046 |
+
e.top + e.height <= t.top
|
| 3047 |
+
)
|
| 3048 |
+
})(t, e)
|
| 3049 |
+
? (Math.min(t.left + t.width, e.left + e.width) - Math.max(t.left, e.left)) *
|
| 3050 |
+
(Math.min(t.top + t.height, e.top + e.height) - Math.max(t.top, e.top))
|
| 3051 |
+
: 0
|
| 3052 |
+
})(t, e)
|
| 3053 |
+
return i ? (i / (Math.min(t.width, e.width) * Math.min(t.height, e.height))) * 100 : 0
|
| 3054 |
+
}
|
| 3055 |
+
;(Ce.prototype.reset = function () {
|
| 3056 |
+
this.isActive && this.onStop(),
|
| 3057 |
+
(this.item = null),
|
| 3058 |
+
(this.element = null),
|
| 3059 |
+
(this.isActive = !1),
|
| 3060 |
+
(this.isEnding = !1),
|
| 3061 |
+
(this.direction = null),
|
| 3062 |
+
(this.value = null),
|
| 3063 |
+
(this.maxValue = 0),
|
| 3064 |
+
(this.threshold = 0),
|
| 3065 |
+
(this.distance = 0),
|
| 3066 |
+
(this.speed = 0),
|
| 3067 |
+
(this.duration = 0),
|
| 3068 |
+
(this.action = null)
|
| 3069 |
+
}),
|
| 3070 |
+
(Ce.prototype.hasReachedEnd = function () {
|
| 3071 |
+
return 4 & this.direction ? this.value >= this.maxValue : this.value <= 0
|
| 3072 |
+
}),
|
| 3073 |
+
(Ce.prototype.computeCurrentScrollValue = function () {
|
| 3074 |
+
return null === this.value
|
| 3075 |
+
? 1 & this.direction
|
| 3076 |
+
? Ee(this.element)
|
| 3077 |
+
: Te(this.element)
|
| 3078 |
+
: Math.max(0, Math.min(this.value, this.maxValue))
|
| 3079 |
+
}),
|
| 3080 |
+
(Ce.prototype.computeNextScrollValue = function (t) {
|
| 3081 |
+
var e = this.speed * (t / 1e3),
|
| 3082 |
+
i = 4 & this.direction ? this.value + e : this.value - e
|
| 3083 |
+
return Math.max(0, Math.min(i, this.maxValue))
|
| 3084 |
+
}),
|
| 3085 |
+
(Ce.prototype.computeSpeed =
|
| 3086 |
+
((ye = {
|
| 3087 |
+
direction: null,
|
| 3088 |
+
threshold: 0,
|
| 3089 |
+
distance: 0,
|
| 3090 |
+
value: 0,
|
| 3091 |
+
maxValue: 0,
|
| 3092 |
+
deltaTime: 0,
|
| 3093 |
+
duration: 0,
|
| 3094 |
+
isEnding: !1,
|
| 3095 |
+
}),
|
| 3096 |
+
function (t) {
|
| 3097 |
+
var e = this.item,
|
| 3098 |
+
i = Re(e).speed
|
| 3099 |
+
return ce(i)
|
| 3100 |
+
? ((ye.direction = this.direction),
|
| 3101 |
+
(ye.threshold = this.threshold),
|
| 3102 |
+
(ye.distance = this.distance),
|
| 3103 |
+
(ye.value = this.value),
|
| 3104 |
+
(ye.maxValue = this.maxValue),
|
| 3105 |
+
(ye.duration = this.duration),
|
| 3106 |
+
(ye.speed = this.speed),
|
| 3107 |
+
(ye.deltaTime = t),
|
| 3108 |
+
(ye.isEnding = this.isEnding),
|
| 3109 |
+
i(e, this.element, ye))
|
| 3110 |
+
: i
|
| 3111 |
+
})),
|
| 3112 |
+
(Ce.prototype.tick = function (t) {
|
| 3113 |
+
return (
|
| 3114 |
+
this.isActive || ((this.isActive = !0), this.onStart()),
|
| 3115 |
+
(this.value = this.computeCurrentScrollValue()),
|
| 3116 |
+
(this.speed = this.computeSpeed(t)),
|
| 3117 |
+
(this.value = this.computeNextScrollValue(t)),
|
| 3118 |
+
(this.duration += t),
|
| 3119 |
+
this.value
|
| 3120 |
+
)
|
| 3121 |
+
}),
|
| 3122 |
+
(Ce.prototype.onStart = function () {
|
| 3123 |
+
var t = this.item,
|
| 3124 |
+
e = Re(t).onStart
|
| 3125 |
+
ce(e) && e(t, this.element, this.direction)
|
| 3126 |
+
}),
|
| 3127 |
+
(Ce.prototype.onStop = function () {
|
| 3128 |
+
var t = this.item,
|
| 3129 |
+
e = Re(t).onStop
|
| 3130 |
+
ce(e) && e(t, this.element, this.direction), t._drag && t._drag.sort()
|
| 3131 |
+
}),
|
| 3132 |
+
(Me.prototype.reset = function () {
|
| 3133 |
+
this.requestX && (this.requestX.action = null),
|
| 3134 |
+
this.requestY && (this.requestY.action = null),
|
| 3135 |
+
(this.element = null),
|
| 3136 |
+
(this.requestX = null),
|
| 3137 |
+
(this.requestY = null),
|
| 3138 |
+
(this.scrollLeft = 0),
|
| 3139 |
+
(this.scrollTop = 0)
|
| 3140 |
+
}),
|
| 3141 |
+
(Me.prototype.addRequest = function (t) {
|
| 3142 |
+
1 & t.direction
|
| 3143 |
+
? (this.removeRequest(this.requestX), (this.requestX = t))
|
| 3144 |
+
: (this.removeRequest(this.requestY), (this.requestY = t)),
|
| 3145 |
+
(t.action = this)
|
| 3146 |
+
}),
|
| 3147 |
+
(Me.prototype.removeRequest = function (t) {
|
| 3148 |
+
t &&
|
| 3149 |
+
(this.requestX === t
|
| 3150 |
+
? ((this.requestX = null), (t.action = null))
|
| 3151 |
+
: this.requestY === t && ((this.requestY = null), (t.action = null)))
|
| 3152 |
+
}),
|
| 3153 |
+
(Me.prototype.computeScrollValues = function () {
|
| 3154 |
+
;(this.scrollLeft = this.requestX ? this.requestX.value : Ee(this.element)),
|
| 3155 |
+
(this.scrollTop = this.requestY ? this.requestY.value : Te(this.element))
|
| 3156 |
+
}),
|
| 3157 |
+
(Me.prototype.scroll = function () {
|
| 3158 |
+
var t = this.element
|
| 3159 |
+
t &&
|
| 3160 |
+
(t.scrollTo
|
| 3161 |
+
? t.scrollTo(this.scrollLeft, this.scrollTop)
|
| 3162 |
+
: ((t.scrollLeft = this.scrollLeft), (t.scrollTop = this.scrollTop)))
|
| 3163 |
+
}),
|
| 3164 |
+
(Ie.prototype.pick = function () {
|
| 3165 |
+
return this.pool.pop() || this.createItem()
|
| 3166 |
+
}),
|
| 3167 |
+
(Ie.prototype.release = function (t) {
|
| 3168 |
+
this.releaseItem(t), -1 === this.pool.indexOf(t) && this.pool.push(t)
|
| 3169 |
+
}),
|
| 3170 |
+
(Ie.prototype.reset = function () {
|
| 3171 |
+
this.pool.length = 0
|
| 3172 |
+
})
|
| 3173 |
+
var qe = { width: 0, height: 0, left: 0, right: 0, top: 0, bottom: 0 },
|
| 3174 |
+
je = { width: 0, height: 0, left: 0, right: 0, top: 0, bottom: 0 }
|
| 3175 |
+
function Xe() {
|
| 3176 |
+
;(this._isDestroyed = !1),
|
| 3177 |
+
(this._isTicking = !1),
|
| 3178 |
+
(this._tickTime = 0),
|
| 3179 |
+
(this._tickDeltaTime = 0),
|
| 3180 |
+
(this._items = []),
|
| 3181 |
+
(this._actions = []),
|
| 3182 |
+
(this._requests = {}),
|
| 3183 |
+
(this._requests[1] = {}),
|
| 3184 |
+
(this._requests[2] = {}),
|
| 3185 |
+
(this._requestOverlapCheck = {}),
|
| 3186 |
+
(this._dragPositions = {}),
|
| 3187 |
+
(this._dragDirections = {}),
|
| 3188 |
+
(this._overlapCheckInterval = 150),
|
| 3189 |
+
(this._requestPool = new Ie(
|
| 3190 |
+
function () {
|
| 3191 |
+
return new Ce()
|
| 3192 |
+
},
|
| 3193 |
+
function (t) {
|
| 3194 |
+
t.reset()
|
| 3195 |
+
},
|
| 3196 |
+
)),
|
| 3197 |
+
(this._actionPool = new Ie(
|
| 3198 |
+
function () {
|
| 3199 |
+
return new Me()
|
| 3200 |
+
},
|
| 3201 |
+
function (t) {
|
| 3202 |
+
t.reset()
|
| 3203 |
+
},
|
| 3204 |
+
)),
|
| 3205 |
+
(this._readTick = this._readTick.bind(this)),
|
| 3206 |
+
(this._writeTick = this._writeTick.bind(this))
|
| 3207 |
+
}
|
| 3208 |
+
;(Xe.AXIS_X = 1),
|
| 3209 |
+
(Xe.AXIS_Y = 2),
|
| 3210 |
+
(Xe.FORWARD = 4),
|
| 3211 |
+
(Xe.BACKWARD = 8),
|
| 3212 |
+
(Xe.LEFT = 9),
|
| 3213 |
+
(Xe.RIGHT = 5),
|
| 3214 |
+
(Xe.UP = 10),
|
| 3215 |
+
(Xe.DOWN = 6),
|
| 3216 |
+
(Xe.smoothSpeed = function (t, e, i) {
|
| 3217 |
+
return function (n, r, s) {
|
| 3218 |
+
var o = 0
|
| 3219 |
+
if (!s.isEnding)
|
| 3220 |
+
if (s.threshold > 0) {
|
| 3221 |
+
var a = s.threshold - Math.max(0, s.distance)
|
| 3222 |
+
o = (t / s.threshold) * a
|
| 3223 |
+
} else o = t
|
| 3224 |
+
var l = s.speed,
|
| 3225 |
+
h = o
|
| 3226 |
+
return l === o
|
| 3227 |
+
? h
|
| 3228 |
+
: l < o
|
| 3229 |
+
? ((h = l + e * (s.deltaTime / 1e3)), Math.min(o, h))
|
| 3230 |
+
: ((h = l - i * (s.deltaTime / 1e3)), Math.max(o, h))
|
| 3231 |
+
}
|
| 3232 |
+
}),
|
| 3233 |
+
(Xe.pointerHandle = function (t) {
|
| 3234 |
+
var e = { left: 0, top: 0, width: 0, height: 0 },
|
| 3235 |
+
i = t || 1
|
| 3236 |
+
return function (t, n, r, s, o, a, l) {
|
| 3237 |
+
return (e.left = a - 0.5 * i), (e.top = l - 0.5 * i), (e.width = i), (e.height = i), e
|
| 3238 |
+
}
|
| 3239 |
+
}),
|
| 3240 |
+
(Xe.prototype._readTick = function (t) {
|
| 3241 |
+
this._isDestroyed ||
|
| 3242 |
+
(t && this._tickTime
|
| 3243 |
+
? ((this._tickDeltaTime = t - this._tickTime),
|
| 3244 |
+
(this._tickTime = t),
|
| 3245 |
+
this._updateRequests(),
|
| 3246 |
+
this._updateActions())
|
| 3247 |
+
: ((this._tickTime = t), (this._tickDeltaTime = 0)))
|
| 3248 |
+
}),
|
| 3249 |
+
(Xe.prototype._writeTick = function () {
|
| 3250 |
+
this._isDestroyed || (this._applyActions(), ue(this._readTick, this._writeTick))
|
| 3251 |
+
}),
|
| 3252 |
+
(Xe.prototype._startTicking = function () {
|
| 3253 |
+
;(this._isTicking = !0), ue(this._readTick, this._writeTick)
|
| 3254 |
+
}),
|
| 3255 |
+
(Xe.prototype._stopTicking = function () {
|
| 3256 |
+
;(this._isTicking = !1), (this._tickTime = 0), (this._tickDeltaTime = 0), ie.remove(0, Zt), ie.remove(2, te)
|
| 3257 |
+
}),
|
| 3258 |
+
(Xe.prototype._getItemHandleRect = function (t, e, i) {
|
| 3259 |
+
var n = t._drag
|
| 3260 |
+
if (e) {
|
| 3261 |
+
var r = n._dragMoveEvent || n._dragStartEvent,
|
| 3262 |
+
s = e(t, n._clientX, n._clientY, t._width, t._height, r.clientX, r.clientY)
|
| 3263 |
+
;(i.left = s.left), (i.top = s.top), (i.width = s.width), (i.height = s.height)
|
| 3264 |
+
} else (i.left = n._clientX), (i.top = n._clientY), (i.width = t._width), (i.height = t._height)
|
| 3265 |
+
return (i.right = i.left + i.width), (i.bottom = i.top + i.height), i
|
| 3266 |
+
}),
|
| 3267 |
+
(Xe.prototype._requestItemScroll = function (t, e, i, n, r, s, o) {
|
| 3268 |
+
var a = this._requests[e],
|
| 3269 |
+
l = a[t._id]
|
| 3270 |
+
l ? (l.element === i && l.direction === n) || l.reset() : (l = this._requestPool.pick()),
|
| 3271 |
+
(l.item = t),
|
| 3272 |
+
(l.element = i),
|
| 3273 |
+
(l.direction = n),
|
| 3274 |
+
(l.threshold = r),
|
| 3275 |
+
(l.distance = s),
|
| 3276 |
+
(l.maxValue = o),
|
| 3277 |
+
(a[t._id] = l)
|
| 3278 |
+
}),
|
| 3279 |
+
(Xe.prototype._cancelItemScroll = function (t, e) {
|
| 3280 |
+
var i = this._requests[e],
|
| 3281 |
+
n = i[t._id]
|
| 3282 |
+
n && (n.action && n.action.removeRequest(n), this._requestPool.release(n), delete i[t._id])
|
| 3283 |
+
}),
|
| 3284 |
+
(Xe.prototype._checkItemOverlap = function (t, e, i) {
|
| 3285 |
+
var n = Re(t),
|
| 3286 |
+
r = ce(n.targets) ? n.targets(t) : n.targets,
|
| 3287 |
+
s = n.threshold,
|
| 3288 |
+
o = n.safeZone
|
| 3289 |
+
if (!r || !r.length) return e && this._cancelItemScroll(t, 1), void (i && this._cancelItemScroll(t, 2))
|
| 3290 |
+
var a = this._dragDirections[t._id],
|
| 3291 |
+
l = a[0],
|
| 3292 |
+
h = a[1]
|
| 3293 |
+
if (!l && !h) return e && this._cancelItemScroll(t, 1), void (i && this._cancelItemScroll(t, 2))
|
| 3294 |
+
for (
|
| 3295 |
+
var u = this._getItemHandleRect(t, n.handle, qe),
|
| 3296 |
+
c = je,
|
| 3297 |
+
d = null,
|
| 3298 |
+
f = null,
|
| 3299 |
+
p = !0,
|
| 3300 |
+
_ = !0,
|
| 3301 |
+
m = 0,
|
| 3302 |
+
g = 0,
|
| 3303 |
+
v = null,
|
| 3304 |
+
y = null,
|
| 3305 |
+
b = 0,
|
| 3306 |
+
w = 0,
|
| 3307 |
+
x = 0,
|
| 3308 |
+
S = null,
|
| 3309 |
+
E = -1 / 0,
|
| 3310 |
+
T = 0,
|
| 3311 |
+
D = 0,
|
| 3312 |
+
A = null,
|
| 3313 |
+
k = 0,
|
| 3314 |
+
R = 0,
|
| 3315 |
+
P = null,
|
| 3316 |
+
O = -1 / 0,
|
| 3317 |
+
L = 0,
|
| 3318 |
+
C = 0,
|
| 3319 |
+
M = null,
|
| 3320 |
+
I = 0,
|
| 3321 |
+
N = 0,
|
| 3322 |
+
q = 0;
|
| 3323 |
+
q < r.length;
|
| 3324 |
+
q++
|
| 3325 |
+
)
|
| 3326 |
+
(d = r[q]),
|
| 3327 |
+
(p = e && l && 2 !== d.axis),
|
| 3328 |
+
(_ = i && h && 1 !== d.axis),
|
| 3329 |
+
(g = d.priority || 0),
|
| 3330 |
+
((!p || g < E) && (!_ || g < O)) ||
|
| 3331 |
+
((f = Se(d.element || d)),
|
| 3332 |
+
(w = p ? De(f) : -1),
|
| 3333 |
+
(x = _ ? Ae(f) : -1),
|
| 3334 |
+
(w || x) &&
|
| 3335 |
+
((m = Ne(u, (c = ke(f, c)))) <= 0 ||
|
| 3336 |
+
(p &&
|
| 3337 |
+
g >= E &&
|
| 3338 |
+
w > 0 &&
|
| 3339 |
+
(g > E || m > D) &&
|
| 3340 |
+
((y = null),
|
| 3341 |
+
(v = Le('number' == typeof d.threshold ? d.threshold : s, o, u.width, c.width)),
|
| 3342 |
+
5 === l
|
| 3343 |
+
? (b = c.right + v.offset - u.right) <= v.value && Ee(f) < w && (y = 5)
|
| 3344 |
+
: 9 === l &&
|
| 3345 |
+
(b = u.left - (c.left - v.offset)) <= v.value &&
|
| 3346 |
+
Ee(f) > 0 &&
|
| 3347 |
+
(y = 9),
|
| 3348 |
+
null !== y &&
|
| 3349 |
+
((S = f), (E = g), (T = v.value), (D = m), (A = y), (k = b), (R = w))),
|
| 3350 |
+
_ &&
|
| 3351 |
+
g >= O &&
|
| 3352 |
+
x > 0 &&
|
| 3353 |
+
(g > O || m > C) &&
|
| 3354 |
+
((y = null),
|
| 3355 |
+
(v = Le('number' == typeof d.threshold ? d.threshold : s, o, u.height, c.height)),
|
| 3356 |
+
6 === h
|
| 3357 |
+
? (b = c.bottom + v.offset - u.bottom) <= v.value && Te(f) < x && (y = 6)
|
| 3358 |
+
: 10 === h &&
|
| 3359 |
+
(b = u.top - (c.top - v.offset)) <= v.value &&
|
| 3360 |
+
Te(f) > 0 &&
|
| 3361 |
+
(y = 10),
|
| 3362 |
+
null !== y &&
|
| 3363 |
+
((P = f), (O = g), (L = v.value), (C = m), (M = y), (I = b), (N = x))))))
|
| 3364 |
+
e && (S ? this._requestItemScroll(t, 1, S, A, T, k, R) : this._cancelItemScroll(t, 1)),
|
| 3365 |
+
i && (P ? this._requestItemScroll(t, 2, P, M, L, I, N) : this._cancelItemScroll(t, 2))
|
| 3366 |
+
}),
|
| 3367 |
+
(Xe.prototype._updateScrollRequest = function (t) {
|
| 3368 |
+
for (
|
| 3369 |
+
var e = t.item,
|
| 3370 |
+
i = Re(e),
|
| 3371 |
+
n = ce(i.targets) ? i.targets(e) : i.targets,
|
| 3372 |
+
r = (n && n.length) || 0,
|
| 3373 |
+
s = i.threshold,
|
| 3374 |
+
o = i.safeZone,
|
| 3375 |
+
a = this._getItemHandleRect(e, i.handle, qe),
|
| 3376 |
+
l = je,
|
| 3377 |
+
h = null,
|
| 3378 |
+
u = null,
|
| 3379 |
+
c = !1,
|
| 3380 |
+
d = null,
|
| 3381 |
+
f = null,
|
| 3382 |
+
p = null,
|
| 3383 |
+
_ = null,
|
| 3384 |
+
m = null,
|
| 3385 |
+
g = 0;
|
| 3386 |
+
g < r;
|
| 3387 |
+
g++
|
| 3388 |
+
)
|
| 3389 |
+
if ((u = Se((h = n[g]).element || h)) === t.element) {
|
| 3390 |
+
if ((c = !!(1 & t.direction))) {
|
| 3391 |
+
if (2 === h.axis) continue
|
| 3392 |
+
} else if (1 === h.axis) continue
|
| 3393 |
+
if ((_ = c ? De(u) : Ae(u)) <= 0) break
|
| 3394 |
+
if (Ne(a, (l = ke(u, l))) <= 0) break
|
| 3395 |
+
if (
|
| 3396 |
+
((d = Le(
|
| 3397 |
+
'number' == typeof h.threshold ? h.threshold : s,
|
| 3398 |
+
o,
|
| 3399 |
+
c ? a.width : a.height,
|
| 3400 |
+
c ? l.width : l.height,
|
| 3401 |
+
)),
|
| 3402 |
+
(f =
|
| 3403 |
+
9 === t.direction
|
| 3404 |
+
? a.left - (l.left - d.offset)
|
| 3405 |
+
: 5 === t.direction
|
| 3406 |
+
? l.right + d.offset - a.right
|
| 3407 |
+
: 10 === t.direction
|
| 3408 |
+
? a.top - (l.top - d.offset)
|
| 3409 |
+
: l.bottom + d.offset - a.bottom) > d.value)
|
| 3410 |
+
)
|
| 3411 |
+
break
|
| 3412 |
+
if (((p = c ? Ee(u) : Te(u)), (m = 4 & t.direction ? p >= _ : p <= 0))) break
|
| 3413 |
+
return (t.maxValue = _), (t.threshold = d.value), (t.distance = f), (t.isEnding = !1), !0
|
| 3414 |
+
}
|
| 3415 |
+
return (
|
| 3416 |
+
!0 === i.smoothStop && t.speed > 0
|
| 3417 |
+
? (null === m && (m = t.hasReachedEnd()), (t.isEnding = !m))
|
| 3418 |
+
: (t.isEnding = !1),
|
| 3419 |
+
t.isEnding
|
| 3420 |
+
)
|
| 3421 |
+
}),
|
| 3422 |
+
(Xe.prototype._updateRequests = function () {
|
| 3423 |
+
for (
|
| 3424 |
+
var t, e, i, n, r, s, o, a = this._items, l = this._requests[1], h = this._requests[2], u = 0;
|
| 3425 |
+
u < a.length;
|
| 3426 |
+
u++
|
| 3427 |
+
)
|
| 3428 |
+
(t = a[u]),
|
| 3429 |
+
(r = (n = this._requestOverlapCheck[t._id]) > 0 && this._tickTime - n > this._overlapCheckInterval),
|
| 3430 |
+
(s = !0),
|
| 3431 |
+
(e = l[t._id]) &&
|
| 3432 |
+
e.isActive &&
|
| 3433 |
+
(s = !this._updateScrollRequest(e)) &&
|
| 3434 |
+
((r = !0), this._cancelItemScroll(t, 1)),
|
| 3435 |
+
(o = !0),
|
| 3436 |
+
(i = h[t._id]) &&
|
| 3437 |
+
i.isActive &&
|
| 3438 |
+
(o = !this._updateScrollRequest(i)) &&
|
| 3439 |
+
((r = !0), this._cancelItemScroll(t, 2)),
|
| 3440 |
+
r && ((this._requestOverlapCheck[t._id] = 0), this._checkItemOverlap(t, s, o))
|
| 3441 |
+
}),
|
| 3442 |
+
(Xe.prototype._requestAction = function (t, e) {
|
| 3443 |
+
for (var i = this._actions, n = 1 === e, r = null, s = 0; s < i.length; s++) {
|
| 3444 |
+
if (((r = i[s]), t.element === r.element)) {
|
| 3445 |
+
if (n ? r.requestX : r.requestY) return void this._cancelItemScroll(t.item, e)
|
| 3446 |
+
break
|
| 3447 |
+
}
|
| 3448 |
+
r = null
|
| 3449 |
+
}
|
| 3450 |
+
r || (r = this._actionPool.pick()),
|
| 3451 |
+
(r.element = t.element),
|
| 3452 |
+
r.addRequest(t),
|
| 3453 |
+
t.tick(this._tickDeltaTime),
|
| 3454 |
+
i.push(r)
|
| 3455 |
+
}),
|
| 3456 |
+
(Xe.prototype._updateActions = function () {
|
| 3457 |
+
var t,
|
| 3458 |
+
e,
|
| 3459 |
+
i,
|
| 3460 |
+
n,
|
| 3461 |
+
r = this._items,
|
| 3462 |
+
s = this._requests,
|
| 3463 |
+
o = this._actions
|
| 3464 |
+
for (n = 0; n < r.length; n++)
|
| 3465 |
+
(t = r[n]._id),
|
| 3466 |
+
(e = s[1][t]),
|
| 3467 |
+
(i = s[2][t]),
|
| 3468 |
+
e && this._requestAction(e, 1),
|
| 3469 |
+
i && this._requestAction(i, 2)
|
| 3470 |
+
for (n = 0; n < o.length; n++) o[n].computeScrollValues()
|
| 3471 |
+
}),
|
| 3472 |
+
(Xe.prototype._applyActions = function () {
|
| 3473 |
+
var t,
|
| 3474 |
+
e = this._actions,
|
| 3475 |
+
i = this._items
|
| 3476 |
+
if (e.length) {
|
| 3477 |
+
for (t = 0; t < e.length; t++) e[t].scroll(), this._actionPool.release(e[t])
|
| 3478 |
+
for (e.length = 0, t = 0; t < i.length; t++) Pe(i[t])
|
| 3479 |
+
for (t = 0; t < i.length; t++) Oe(i[t])
|
| 3480 |
+
}
|
| 3481 |
+
}),
|
| 3482 |
+
(Xe.prototype._updateDragDirection = function (t) {
|
| 3483 |
+
var e = this._dragPositions[t._id],
|
| 3484 |
+
i = this._dragDirections[t._id],
|
| 3485 |
+
n = t._drag._left,
|
| 3486 |
+
r = t._drag._top
|
| 3487 |
+
if (e.length) {
|
| 3488 |
+
var s = e[0],
|
| 3489 |
+
o = e[1]
|
| 3490 |
+
;(i[0] = n > s ? 5 : n < s ? 9 : i[0] || 0), (i[1] = r > o ? 6 : r < o ? 10 : i[1] || 0)
|
| 3491 |
+
}
|
| 3492 |
+
;(e[0] = n), (e[1] = r)
|
| 3493 |
+
}),
|
| 3494 |
+
(Xe.prototype.addItem = function (t) {
|
| 3495 |
+
this._isDestroyed ||
|
| 3496 |
+
(-1 === this._items.indexOf(t) &&
|
| 3497 |
+
(this._items.push(t),
|
| 3498 |
+
(this._requestOverlapCheck[t._id] = this._tickTime),
|
| 3499 |
+
(this._dragDirections[t._id] = [0, 0]),
|
| 3500 |
+
(this._dragPositions[t._id] = []),
|
| 3501 |
+
this._isTicking || this._startTicking()))
|
| 3502 |
+
}),
|
| 3503 |
+
(Xe.prototype.updateItem = function (t) {
|
| 3504 |
+
this._isDestroyed ||
|
| 3505 |
+
(this._dragDirections[t._id] &&
|
| 3506 |
+
(this._updateDragDirection(t),
|
| 3507 |
+
this._requestOverlapCheck[t._id] || (this._requestOverlapCheck[t._id] = this._tickTime)))
|
| 3508 |
+
}),
|
| 3509 |
+
(Xe.prototype.removeItem = function (t) {
|
| 3510 |
+
if (!this._isDestroyed) {
|
| 3511 |
+
var e = this._items.indexOf(t)
|
| 3512 |
+
if (-1 !== e) {
|
| 3513 |
+
var i = t._id
|
| 3514 |
+
this._requests[1][i] && (this._cancelItemScroll(t, 1), delete this._requests[1][i]),
|
| 3515 |
+
this._requests[2][i] && (this._cancelItemScroll(t, 2), delete this._requests[2][i]),
|
| 3516 |
+
delete this._requestOverlapCheck[i],
|
| 3517 |
+
delete this._dragPositions[i],
|
| 3518 |
+
delete this._dragDirections[i],
|
| 3519 |
+
this._items.splice(e, 1),
|
| 3520 |
+
this._isTicking && !this._items.length && this._stopTicking()
|
| 3521 |
+
}
|
| 3522 |
+
}
|
| 3523 |
+
}),
|
| 3524 |
+
(Xe.prototype.isItemScrollingX = function (t) {
|
| 3525 |
+
var e = this._requests[1][t._id]
|
| 3526 |
+
return !(!e || !e.isActive)
|
| 3527 |
+
}),
|
| 3528 |
+
(Xe.prototype.isItemScrollingY = function (t) {
|
| 3529 |
+
var e = this._requests[2][t._id]
|
| 3530 |
+
return !(!e || !e.isActive)
|
| 3531 |
+
}),
|
| 3532 |
+
(Xe.prototype.isItemScrolling = function (t) {
|
| 3533 |
+
return this.isItemScrollingX(t) || this.isItemScrollingY(t)
|
| 3534 |
+
}),
|
| 3535 |
+
(Xe.prototype.destroy = function () {
|
| 3536 |
+
if (!this._isDestroyed) {
|
| 3537 |
+
for (var t = this._items.slice(0), e = 0; e < t.length; e++) this.removeItem(t[e])
|
| 3538 |
+
;(this._actions.length = 0),
|
| 3539 |
+
this._requestPool.reset(),
|
| 3540 |
+
this._actionPool.reset(),
|
| 3541 |
+
(this._isDestroyed = !0)
|
| 3542 |
+
}
|
| 3543 |
+
})
|
| 3544 |
+
var Fe = window.Element.prototype,
|
| 3545 |
+
He =
|
| 3546 |
+
Fe.matches ||
|
| 3547 |
+
Fe.matchesSelector ||
|
| 3548 |
+
Fe.webkitMatchesSelector ||
|
| 3549 |
+
Fe.mozMatchesSelector ||
|
| 3550 |
+
Fe.msMatchesSelector ||
|
| 3551 |
+
Fe.oMatchesSelector ||
|
| 3552 |
+
function () {
|
| 3553 |
+
return !1
|
| 3554 |
+
}
|
| 3555 |
+
function Ye(t, e) {
|
| 3556 |
+
return He.call(t, e)
|
| 3557 |
+
}
|
| 3558 |
+
function Be(t, e) {
|
| 3559 |
+
e && (t.classList ? t.classList.add(e) : Ye(t, '.' + e) || (t.className += ' ' + e))
|
| 3560 |
+
}
|
| 3561 |
+
var ze = []
|
| 3562 |
+
function We(t, e, i) {
|
| 3563 |
+
var n = 'number' == typeof i ? i : -1
|
| 3564 |
+
n < 0 && (n = t.length - n + 1), t.splice.apply(t, ze.concat(n, 0, e)), (ze.length = 0)
|
| 3565 |
+
}
|
| 3566 |
+
function $e(t, e, i) {
|
| 3567 |
+
var n = Math.max(0, t.length - 1 + (i || 0))
|
| 3568 |
+
return e > n ? n : e < 0 ? Math.max(n + e + 1, 0) : e
|
| 3569 |
+
}
|
| 3570 |
+
function Ge(t, e, i) {
|
| 3571 |
+
if (!(t.length < 2)) {
|
| 3572 |
+
var n = $e(t, e),
|
| 3573 |
+
r = $e(t, i)
|
| 3574 |
+
n !== r && t.splice(r, 0, t.splice(n, 1)[0])
|
| 3575 |
+
}
|
| 3576 |
+
}
|
| 3577 |
+
function Ue(t, e, i) {
|
| 3578 |
+
if (!(t.length < 2)) {
|
| 3579 |
+
var n,
|
| 3580 |
+
r = $e(t, e),
|
| 3581 |
+
s = $e(t, i)
|
| 3582 |
+
r !== s && ((n = t[r]), (t[r] = t[s]), (t[s] = n))
|
| 3583 |
+
}
|
| 3584 |
+
}
|
| 3585 |
+
var Ve = Tt(document.documentElement.style, 'transform') || 'transform',
|
| 3586 |
+
Je = /([A-Z])/g,
|
| 3587 |
+
Ke = /^(webkit-|moz-|ms-|o-)/,
|
| 3588 |
+
Qe = /^(-m-s-)/
|
| 3589 |
+
function Ze(t) {
|
| 3590 |
+
var e = t.replace(Je, '-$1').toLowerCase()
|
| 3591 |
+
return (e = (e = e.replace(Ke, '-$1')).replace(Qe, '-ms-'))
|
| 3592 |
+
}
|
| 3593 |
+
var ti = Ze(Ve)
|
| 3594 |
+
function ei(t) {
|
| 3595 |
+
var e = ge(t, ti)
|
| 3596 |
+
if (!e || 'none' === e) return !1
|
| 3597 |
+
var i = ge(t, 'display')
|
| 3598 |
+
return 'inline' !== i && 'none' !== i
|
| 3599 |
+
}
|
| 3600 |
+
function ii(t) {
|
| 3601 |
+
for (var e = document, i = t || e; i && i !== e && 'static' === ge(i, 'position') && !ei(i); )
|
| 3602 |
+
i = i.parentElement || e
|
| 3603 |
+
return i
|
| 3604 |
+
}
|
| 3605 |
+
var ni = {},
|
| 3606 |
+
ri = {},
|
| 3607 |
+
si = {}
|
| 3608 |
+
function oi(t, e) {
|
| 3609 |
+
var i,
|
| 3610 |
+
n = e || {}
|
| 3611 |
+
return (
|
| 3612 |
+
(n.left = 0),
|
| 3613 |
+
(n.top = 0),
|
| 3614 |
+
t === document
|
| 3615 |
+
? n
|
| 3616 |
+
: ((n.left = window.pageXOffset || 0),
|
| 3617 |
+
(n.top = window.pageYOffset || 0),
|
| 3618 |
+
t.self === window.self ||
|
| 3619 |
+
((i = t.getBoundingClientRect()),
|
| 3620 |
+
(n.left += i.left),
|
| 3621 |
+
(n.top += i.top),
|
| 3622 |
+
(n.left += ve(t, 'border-left-width')),
|
| 3623 |
+
(n.top += ve(t, 'border-top-width'))),
|
| 3624 |
+
n)
|
| 3625 |
+
)
|
| 3626 |
+
}
|
| 3627 |
+
function ai(t, e, i) {
|
| 3628 |
+
return (
|
| 3629 |
+
(si.left = 0),
|
| 3630 |
+
(si.top = 0),
|
| 3631 |
+
t === e ||
|
| 3632 |
+
(i && (t = ii(t)) === (e = ii(e))) ||
|
| 3633 |
+
(oi(t, ni), oi(e, ri), (si.left = ri.left - ni.left), (si.top = ri.top - ni.top)),
|
| 3634 |
+
si
|
| 3635 |
+
)
|
| 3636 |
+
}
|
| 3637 |
+
function li(t) {
|
| 3638 |
+
return 'auto' === t || 'scroll' === t || 'overlay' === t
|
| 3639 |
+
}
|
| 3640 |
+
function hi(t) {
|
| 3641 |
+
return li(ge(t, 'overflow')) || li(ge(t, 'overflow-x')) || li(ge(t, 'overflow-y'))
|
| 3642 |
+
}
|
| 3643 |
+
function ui(t, e) {
|
| 3644 |
+
for (e = e || []; t && t !== document; )
|
| 3645 |
+
t.getRootNode && t instanceof DocumentFragment
|
| 3646 |
+
? (t = t.getRootNode().host)
|
| 3647 |
+
: (hi(t) && e.push(t), (t = t.parentNode))
|
| 3648 |
+
return e.push(window), e
|
| 3649 |
+
}
|
| 3650 |
+
var ci = {},
|
| 3651 |
+
di = /^matrix3d/,
|
| 3652 |
+
fi = /([^,]*,){4}/,
|
| 3653 |
+
pi = /([^,]*,){12}/,
|
| 3654 |
+
_i = /[^,]*,/
|
| 3655 |
+
function mi(t) {
|
| 3656 |
+
;(ci.x = 0), (ci.y = 0)
|
| 3657 |
+
var e = ge(t, ti)
|
| 3658 |
+
if (!e || 'none' === e) return ci
|
| 3659 |
+
var i = di.test(e),
|
| 3660 |
+
n = e.replace(i ? pi : fi, ''),
|
| 3661 |
+
r = n.replace(_i, '')
|
| 3662 |
+
return (ci.x = parseFloat(n) || 0), (ci.y = parseFloat(r) || 0), ci
|
| 3663 |
+
}
|
| 3664 |
+
function gi(t, e) {
|
| 3665 |
+
e &&
|
| 3666 |
+
(t.classList
|
| 3667 |
+
? t.classList.remove(e)
|
| 3668 |
+
: Ye(t, '.' + e) && (t.className = (' ' + t.className + ' ').replace(' ' + e + ' ', ' ').trim()))
|
| 3669 |
+
}
|
| 3670 |
+
var vi,
|
| 3671 |
+
yi,
|
| 3672 |
+
bi,
|
| 3673 |
+
wi,
|
| 3674 |
+
xi =
|
| 3675 |
+
/^(iPad|iPhone|iPod)/.test(window.navigator.platform) ||
|
| 3676 |
+
(/^Mac/.test(window.navigator.platform) && window.navigator.maxTouchPoints > 1),
|
| 3677 |
+
Si = !!Dt() && { passive: !0 }
|
| 3678 |
+
function Ei(t) {
|
| 3679 |
+
var e = t._element,
|
| 3680 |
+
i = t.getGrid(),
|
| 3681 |
+
n = i._settings
|
| 3682 |
+
;(this._item = t),
|
| 3683 |
+
(this._gridId = i._id),
|
| 3684 |
+
(this._isDestroyed = !1),
|
| 3685 |
+
(this._isMigrating = !1),
|
| 3686 |
+
(this._startPredicate = ce(n.dragStartPredicate) ? n.dragStartPredicate : Ei.defaultStartPredicate),
|
| 3687 |
+
(this._startPredicateState = 0),
|
| 3688 |
+
(this._startPredicateResult = void 0),
|
| 3689 |
+
(this._isSortNeeded = !1),
|
| 3690 |
+
(this._sortTimer = void 0),
|
| 3691 |
+
(this._blockedSortIndex = null),
|
| 3692 |
+
(this._sortX1 = 0),
|
| 3693 |
+
(this._sortX2 = 0),
|
| 3694 |
+
(this._sortY1 = 0),
|
| 3695 |
+
(this._sortY2 = 0),
|
| 3696 |
+
this._reset(),
|
| 3697 |
+
(this._preStartCheck = this._preStartCheck.bind(this)),
|
| 3698 |
+
(this._preEndCheck = this._preEndCheck.bind(this)),
|
| 3699 |
+
(this._onScroll = this._onScroll.bind(this)),
|
| 3700 |
+
(this._prepareStart = this._prepareStart.bind(this)),
|
| 3701 |
+
(this._applyStart = this._applyStart.bind(this)),
|
| 3702 |
+
(this._prepareMove = this._prepareMove.bind(this)),
|
| 3703 |
+
(this._applyMove = this._applyMove.bind(this)),
|
| 3704 |
+
(this._prepareScroll = this._prepareScroll.bind(this)),
|
| 3705 |
+
(this._applyScroll = this._applyScroll.bind(this)),
|
| 3706 |
+
(this._handleSort = this._handleSort.bind(this)),
|
| 3707 |
+
(this._handleSortDelayed = this._handleSortDelayed.bind(this)),
|
| 3708 |
+
(this._handle = (n.dragHandle && e.querySelector(n.dragHandle)) || e),
|
| 3709 |
+
(this._dragger = new It(this._handle, n.dragCssProps)),
|
| 3710 |
+
this._dragger.on('start', this._preStartCheck),
|
| 3711 |
+
this._dragger.on('move', this._preStartCheck),
|
| 3712 |
+
this._dragger.on('cancel', this._preEndCheck),
|
| 3713 |
+
this._dragger.on('end', this._preEndCheck)
|
| 3714 |
+
}
|
| 3715 |
+
function Ti(t, e) {
|
| 3716 |
+
var i,
|
| 3717 |
+
n,
|
| 3718 |
+
r = {}
|
| 3719 |
+
if (Array.isArray(e)) for (n = 0; n < e.length; n++) r[(i = e[n])] = ge(t, Ze(i))
|
| 3720 |
+
else for (i in e) r[i] = ge(t, Ze(i))
|
| 3721 |
+
return r
|
| 3722 |
+
}
|
| 3723 |
+
;(Ei.autoScroller = new Xe()),
|
| 3724 |
+
(Ei.defaultStartPredicate = function (t, e, i) {
|
| 3725 |
+
var n = t._drag
|
| 3726 |
+
if (e.isFirst && e.srcEvent.button) return !1
|
| 3727 |
+
if (
|
| 3728 |
+
!xi &&
|
| 3729 |
+
e.isFirst &&
|
| 3730 |
+
!0 === e.srcEvent.isTrusted &&
|
| 3731 |
+
!1 === e.srcEvent.defaultPrevented &&
|
| 3732 |
+
!1 === e.srcEvent.cancelable
|
| 3733 |
+
)
|
| 3734 |
+
return !1
|
| 3735 |
+
if (!e.isFinal) {
|
| 3736 |
+
var r = n._startPredicateData
|
| 3737 |
+
if (!r) {
|
| 3738 |
+
var s = i || n._getGrid()._settings.dragStartPredicate || {}
|
| 3739 |
+
n._startPredicateData = r = {
|
| 3740 |
+
distance: Math.max(s.distance, 0) || 0,
|
| 3741 |
+
delay: Math.max(s.delay, 0) || 0,
|
| 3742 |
+
}
|
| 3743 |
+
}
|
| 3744 |
+
return (
|
| 3745 |
+
r.delay &&
|
| 3746 |
+
((r.event = e),
|
| 3747 |
+
r.delayTimer ||
|
| 3748 |
+
(r.delayTimer = window.setTimeout(function () {
|
| 3749 |
+
;(r.delay = 0),
|
| 3750 |
+
n._resolveStartPredicate(r.event) &&
|
| 3751 |
+
(n._forceResolveStartPredicate(r.event), n._resetStartPredicate())
|
| 3752 |
+
}, r.delay))),
|
| 3753 |
+
n._resolveStartPredicate(e)
|
| 3754 |
+
)
|
| 3755 |
+
}
|
| 3756 |
+
n._finishStartPredicate(e)
|
| 3757 |
+
}),
|
| 3758 |
+
(Ei.defaultSortPredicate =
|
| 3759 |
+
((vi = {}),
|
| 3760 |
+
(yi = {}),
|
| 3761 |
+
(bi = {}),
|
| 3762 |
+
(wi = []),
|
| 3763 |
+
function (t, e) {
|
| 3764 |
+
var i = t._drag,
|
| 3765 |
+
n = i._getGrid(),
|
| 3766 |
+
r = e && 'number' == typeof e.threshold ? e.threshold : 50,
|
| 3767 |
+
s = e && e.action === it ? it : nt,
|
| 3768 |
+
o = e && e.migrateAction === it ? it : nt
|
| 3769 |
+
;(r = Math.min(Math.max(r, 1), 100)),
|
| 3770 |
+
(vi.width = t._width),
|
| 3771 |
+
(vi.height = t._height),
|
| 3772 |
+
(vi.left = i._clientX),
|
| 3773 |
+
(vi.top = i._clientY)
|
| 3774 |
+
var a = (function (t, e, i) {
|
| 3775 |
+
var n,
|
| 3776 |
+
r,
|
| 3777 |
+
s,
|
| 3778 |
+
o,
|
| 3779 |
+
a,
|
| 3780 |
+
l,
|
| 3781 |
+
h,
|
| 3782 |
+
u,
|
| 3783 |
+
c,
|
| 3784 |
+
d,
|
| 3785 |
+
f = null,
|
| 3786 |
+
p = e._settings.dragSort,
|
| 3787 |
+
_ = -1
|
| 3788 |
+
if (
|
| 3789 |
+
(!0 === p ? ((wi[0] = e), (r = wi)) : ce(p) && (r = p.call(e, t)),
|
| 3790 |
+
!r || !Array.isArray(r) || !r.length)
|
| 3791 |
+
)
|
| 3792 |
+
return f
|
| 3793 |
+
for (d = 0; d < r.length; d++)
|
| 3794 |
+
if (!(s = r[d])._isDestroyed) {
|
| 3795 |
+
for (
|
| 3796 |
+
s._updateBoundingRect(),
|
| 3797 |
+
l = Math.max(0, s._left),
|
| 3798 |
+
h = Math.max(0, s._top),
|
| 3799 |
+
u = Math.min(window.innerWidth, s._right),
|
| 3800 |
+
c = Math.min(window.innerHeight, s._bottom),
|
| 3801 |
+
o = s._element.parentNode;
|
| 3802 |
+
o && o !== document && o !== document.documentElement && o !== document.body;
|
| 3803 |
+
|
| 3804 |
+
)
|
| 3805 |
+
if (o.getRootNode && o instanceof DocumentFragment) o = o.getRootNode().host
|
| 3806 |
+
else {
|
| 3807 |
+
if (
|
| 3808 |
+
('visible' !== ge(o, 'overflow') &&
|
| 3809 |
+
((a = o.getBoundingClientRect()),
|
| 3810 |
+
(l = Math.max(l, a.left)),
|
| 3811 |
+
(h = Math.max(h, a.top)),
|
| 3812 |
+
(u = Math.min(u, a.right)),
|
| 3813 |
+
(c = Math.min(c, a.bottom))),
|
| 3814 |
+
'fixed' === ge(o, 'position'))
|
| 3815 |
+
)
|
| 3816 |
+
break
|
| 3817 |
+
o = o.parentNode
|
| 3818 |
+
}
|
| 3819 |
+
l >= u ||
|
| 3820 |
+
h >= c ||
|
| 3821 |
+
((yi.left = l),
|
| 3822 |
+
(yi.top = h),
|
| 3823 |
+
(yi.width = u - l),
|
| 3824 |
+
(yi.height = c - h),
|
| 3825 |
+
(n = Ne(vi, yi)) > i && n > _ && ((_ = n), (f = s)))
|
| 3826 |
+
}
|
| 3827 |
+
return (wi.length = 0), f
|
| 3828 |
+
})(t, n, r)
|
| 3829 |
+
if (!a) return null
|
| 3830 |
+
var l,
|
| 3831 |
+
h,
|
| 3832 |
+
u,
|
| 3833 |
+
c = t.getGrid() !== a,
|
| 3834 |
+
d = 0,
|
| 3835 |
+
f = 0,
|
| 3836 |
+
p = 0,
|
| 3837 |
+
_ = -1,
|
| 3838 |
+
m = !1
|
| 3839 |
+
for (
|
| 3840 |
+
a === n
|
| 3841 |
+
? ((vi.left = i._gridX + t._marginLeft), (vi.top = i._gridY + t._marginTop))
|
| 3842 |
+
: (a._updateBorders(1, 0, 1, 0), (d = a._left + a._borderLeft), (f = a._top + a._borderTop)),
|
| 3843 |
+
u = 0;
|
| 3844 |
+
u < a._items.length;
|
| 3845 |
+
u++
|
| 3846 |
+
)
|
| 3847 |
+
(l = a._items[u])._isActive &&
|
| 3848 |
+
l !== t &&
|
| 3849 |
+
((m = !0),
|
| 3850 |
+
(yi.width = l._width),
|
| 3851 |
+
(yi.height = l._height),
|
| 3852 |
+
(yi.left = l._left + l._marginLeft + d),
|
| 3853 |
+
(yi.top = l._top + l._marginTop + f),
|
| 3854 |
+
(h = Ne(vi, yi)) > p && ((_ = u), (p = h)))
|
| 3855 |
+
return (
|
| 3856 |
+
c && p < r && ((_ = m ? _ : 0), (p = r)),
|
| 3857 |
+
p >= r ? ((bi.grid = a), (bi.index = _), (bi.action = c ? o : s), bi) : null
|
| 3858 |
+
)
|
| 3859 |
+
})),
|
| 3860 |
+
(Ei.prototype.stop = function () {
|
| 3861 |
+
if (this._isActive)
|
| 3862 |
+
if (this._isMigrating) this._finishMigration()
|
| 3863 |
+
else {
|
| 3864 |
+
Ei.autoScroller.removeItem(this._item)
|
| 3865 |
+
var t = this._item._id
|
| 3866 |
+
if ((se(t), oe(t), ae(t), this._cancelSort(), this._isStarted)) {
|
| 3867 |
+
this._unbindScrollListeners()
|
| 3868 |
+
var e = item._element,
|
| 3869 |
+
i = this._getGrid(),
|
| 3870 |
+
n = i._settings.itemDraggingClass
|
| 3871 |
+
e.parentNode !== i._element &&
|
| 3872 |
+
(i._element.appendChild(e), item._setTranslate(this._gridX, this._gridY)),
|
| 3873 |
+
gi(e, n)
|
| 3874 |
+
}
|
| 3875 |
+
this._reset()
|
| 3876 |
+
}
|
| 3877 |
+
}),
|
| 3878 |
+
(Ei.prototype.sort = function (t) {
|
| 3879 |
+
var e = this._item
|
| 3880 |
+
this._isActive &&
|
| 3881 |
+
e._isActive &&
|
| 3882 |
+
this._dragMoveEvent &&
|
| 3883 |
+
(!0 === t ? this._handleSort() : le(e._id, this._handleSort))
|
| 3884 |
+
}),
|
| 3885 |
+
(Ei.prototype.destroy = function () {
|
| 3886 |
+
this._isDestroyed ||
|
| 3887 |
+
(this.stop(), this._dragger.destroy(), Ei.autoScroller.removeItem(this._item), (this._isDestroyed = !0))
|
| 3888 |
+
}),
|
| 3889 |
+
(Ei.prototype._getGrid = function () {
|
| 3890 |
+
return tt[this._gridId] || null
|
| 3891 |
+
}),
|
| 3892 |
+
(Ei.prototype._reset = function () {
|
| 3893 |
+
;(this._isActive = !1),
|
| 3894 |
+
(this._isStarted = !1),
|
| 3895 |
+
(this._container = null),
|
| 3896 |
+
(this._containingBlock = null),
|
| 3897 |
+
(this._dragStartEvent = null),
|
| 3898 |
+
(this._dragMoveEvent = null),
|
| 3899 |
+
(this._dragPrevMoveEvent = null),
|
| 3900 |
+
(this._scrollEvent = null),
|
| 3901 |
+
(this._scrollers = []),
|
| 3902 |
+
(this._left = 0),
|
| 3903 |
+
(this._top = 0),
|
| 3904 |
+
(this._gridX = 0),
|
| 3905 |
+
(this._gridY = 0),
|
| 3906 |
+
(this._clientX = 0),
|
| 3907 |
+
(this._clientY = 0),
|
| 3908 |
+
(this._scrollDiffX = 0),
|
| 3909 |
+
(this._scrollDiffY = 0),
|
| 3910 |
+
(this._moveDiffX = 0),
|
| 3911 |
+
(this._moveDiffY = 0),
|
| 3912 |
+
(this._containerDiffX = 0),
|
| 3913 |
+
(this._containerDiffY = 0)
|
| 3914 |
+
}),
|
| 3915 |
+
(Ei.prototype._bindScrollListeners = function () {
|
| 3916 |
+
var t,
|
| 3917 |
+
e,
|
| 3918 |
+
i = this._getGrid()._element,
|
| 3919 |
+
n = this._container,
|
| 3920 |
+
r = this._scrollers
|
| 3921 |
+
if (((r.length = 0), ui(this._item._element.parentNode, r), n !== i))
|
| 3922 |
+
for (ui(i, (t = [])), e = 0; e < t.length; e++) r.indexOf(t[e]) < 0 && r.push(t[e])
|
| 3923 |
+
for (e = 0; e < r.length; e++) r[e].addEventListener('scroll', this._onScroll, Si)
|
| 3924 |
+
}),
|
| 3925 |
+
(Ei.prototype._unbindScrollListeners = function () {
|
| 3926 |
+
var t,
|
| 3927 |
+
e = this._scrollers
|
| 3928 |
+
for (t = 0; t < e.length; t++) e[t].removeEventListener('scroll', this._onScroll, Si)
|
| 3929 |
+
e.length = 0
|
| 3930 |
+
}),
|
| 3931 |
+
(Ei.prototype._resolveStartPredicate = function (t) {
|
| 3932 |
+
var e = this._startPredicateData
|
| 3933 |
+
if (!(t.distance < e.distance || e.delay)) return this._resetStartPredicate(), !0
|
| 3934 |
+
}),
|
| 3935 |
+
(Ei.prototype._forceResolveStartPredicate = function (t) {
|
| 3936 |
+
this._isDestroyed || 1 !== this._startPredicateState || ((this._startPredicateState = 2), this._onStart(t))
|
| 3937 |
+
}),
|
| 3938 |
+
(Ei.prototype._finishStartPredicate = function (t) {
|
| 3939 |
+
var e = this._item._element,
|
| 3940 |
+
i = Math.abs(t.deltaX) < 2 && Math.abs(t.deltaY) < 2 && t.deltaTime < 200
|
| 3941 |
+
this._resetStartPredicate(),
|
| 3942 |
+
i &&
|
| 3943 |
+
(function (t) {
|
| 3944 |
+
if ('a' !== t.tagName.toLowerCase()) return
|
| 3945 |
+
var e = t.getAttribute('href')
|
| 3946 |
+
if (!e) return
|
| 3947 |
+
var i = t.getAttribute('target')
|
| 3948 |
+
i && '_self' !== i ? window.open(e, i) : (window.location.href = e)
|
| 3949 |
+
})(e)
|
| 3950 |
+
}),
|
| 3951 |
+
(Ei.prototype._resetHeuristics = function (t, e) {
|
| 3952 |
+
;(this._blockedSortIndex = null), (this._sortX1 = this._sortX2 = t), (this._sortY1 = this._sortY2 = e)
|
| 3953 |
+
}),
|
| 3954 |
+
(Ei.prototype._checkHeuristics = function (t, e) {
|
| 3955 |
+
var i = this._getGrid()._settings.dragSortHeuristics,
|
| 3956 |
+
n = i.minDragDistance
|
| 3957 |
+
if (n <= 0) return (this._blockedSortIndex = null), !0
|
| 3958 |
+
var r = t - this._sortX2,
|
| 3959 |
+
s = e - this._sortY2,
|
| 3960 |
+
o = n > 3 && i.minBounceBackAngle > 0
|
| 3961 |
+
if ((o || (this._blockedSortIndex = null), Math.abs(r) > n || Math.abs(s) > n)) {
|
| 3962 |
+
if (o) {
|
| 3963 |
+
var a = Math.atan2(r, s),
|
| 3964 |
+
l = Math.atan2(this._sortX2 - this._sortX1, this._sortY2 - this._sortY1),
|
| 3965 |
+
h = Math.atan2(Math.sin(a - l), Math.cos(a - l))
|
| 3966 |
+
Math.abs(h) > i.minBounceBackAngle && (this._blockedSortIndex = null)
|
| 3967 |
+
}
|
| 3968 |
+
return (
|
| 3969 |
+
(this._sortX1 = this._sortX2),
|
| 3970 |
+
(this._sortY1 = this._sortY2),
|
| 3971 |
+
(this._sortX2 = t),
|
| 3972 |
+
(this._sortY2 = e),
|
| 3973 |
+
!0
|
| 3974 |
+
)
|
| 3975 |
+
}
|
| 3976 |
+
return !1
|
| 3977 |
+
}),
|
| 3978 |
+
(Ei.prototype._resetStartPredicate = function () {
|
| 3979 |
+
var t = this._startPredicateData
|
| 3980 |
+
t && (t.delayTimer && (t.delayTimer = window.clearTimeout(t.delayTimer)), (this._startPredicateData = null))
|
| 3981 |
+
}),
|
| 3982 |
+
(Ei.prototype._handleSort = function () {
|
| 3983 |
+
if (this._isActive) {
|
| 3984 |
+
var t = this._getGrid()._settings
|
| 3985 |
+
if (!t.dragSort || (!t.dragAutoScroll.sortDuringScroll && Ei.autoScroller.isItemScrolling(this._item)))
|
| 3986 |
+
return (
|
| 3987 |
+
(this._sortX1 = this._sortX2 = this._gridX),
|
| 3988 |
+
(this._sortY1 = this._sortY2 = this._gridY),
|
| 3989 |
+
(this._isSortNeeded = !0),
|
| 3990 |
+
void (void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)))
|
| 3991 |
+
)
|
| 3992 |
+
var e = this._checkHeuristics(this._gridX, this._gridY)
|
| 3993 |
+
if (this._isSortNeeded || e) {
|
| 3994 |
+
var i = t.dragSortHeuristics.sortInterval
|
| 3995 |
+
i <= 0 || this._isSortNeeded
|
| 3996 |
+
? ((this._isSortNeeded = !1),
|
| 3997 |
+
void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)),
|
| 3998 |
+
this._checkOverlap())
|
| 3999 |
+
: void 0 === this._sortTimer &&
|
| 4000 |
+
(this._sortTimer = window.setTimeout(this._handleSortDelayed, i))
|
| 4001 |
+
}
|
| 4002 |
+
}
|
| 4003 |
+
}),
|
| 4004 |
+
(Ei.prototype._handleSortDelayed = function () {
|
| 4005 |
+
;(this._isSortNeeded = !0), (this._sortTimer = void 0), le(this._item._id, this._handleSort)
|
| 4006 |
+
}),
|
| 4007 |
+
(Ei.prototype._cancelSort = function () {
|
| 4008 |
+
var t
|
| 4009 |
+
;(this._isSortNeeded = !1),
|
| 4010 |
+
void 0 !== this._sortTimer && (this._sortTimer = window.clearTimeout(this._sortTimer)),
|
| 4011 |
+
(t = this._item._id),
|
| 4012 |
+
ie.remove(1, Vt + t)
|
| 4013 |
+
}),
|
| 4014 |
+
(Ei.prototype._finishSort = function () {
|
| 4015 |
+
var t = this._getGrid()._settings.dragSort && (this._isSortNeeded || void 0 !== this._sortTimer)
|
| 4016 |
+
this._cancelSort(), t && this._checkOverlap()
|
| 4017 |
+
}),
|
| 4018 |
+
(Ei.prototype._checkOverlap = function () {
|
| 4019 |
+
if (this._isActive) {
|
| 4020 |
+
var t,
|
| 4021 |
+
e,
|
| 4022 |
+
i,
|
| 4023 |
+
n,
|
| 4024 |
+
r,
|
| 4025 |
+
s,
|
| 4026 |
+
o,
|
| 4027 |
+
a,
|
| 4028 |
+
l = this._item,
|
| 4029 |
+
h = this._getGrid()._settings
|
| 4030 |
+
;(t = ce(h.dragSortPredicate)
|
| 4031 |
+
? h.dragSortPredicate(l, this._dragMoveEvent)
|
| 4032 |
+
: Ei.defaultSortPredicate(l, h.dragSortPredicate)) &&
|
| 4033 |
+
'number' == typeof t.index &&
|
| 4034 |
+
((o = t.action === it ? it : nt),
|
| 4035 |
+
(a = (e = l.getGrid()) !== (n = t.grid || e)),
|
| 4036 |
+
(i = e._items.indexOf(l)),
|
| 4037 |
+
(r = $e(n._items, t.index, a && o === nt ? 1 : 0)),
|
| 4038 |
+
(a || r !== this._blockedSortIndex) &&
|
| 4039 |
+
(a
|
| 4040 |
+
? ((this._blockedSortIndex = null),
|
| 4041 |
+
(s = n._items[r]),
|
| 4042 |
+
e._hasListeners(ft) &&
|
| 4043 |
+
e._emit(ft, { item: l, fromGrid: e, fromIndex: i, toGrid: n, toIndex: r }),
|
| 4044 |
+
n._hasListeners(_t) &&
|
| 4045 |
+
n._emit(_t, { item: l, fromGrid: e, fromIndex: i, toGrid: n, toIndex: r }),
|
| 4046 |
+
(l._gridId = n._id),
|
| 4047 |
+
(this._isMigrating = l._gridId !== this._gridId),
|
| 4048 |
+
e._items.splice(i, 1),
|
| 4049 |
+
We(n._items, l, r),
|
| 4050 |
+
(l._sortData = null),
|
| 4051 |
+
e._hasListeners(dt) &&
|
| 4052 |
+
e._emit(dt, { item: l, fromGrid: e, fromIndex: i, toGrid: n, toIndex: r }),
|
| 4053 |
+
n._hasListeners(pt) &&
|
| 4054 |
+
n._emit(pt, { item: l, fromGrid: e, fromIndex: i, toGrid: n, toIndex: r }),
|
| 4055 |
+
o === it &&
|
| 4056 |
+
s &&
|
| 4057 |
+
s.isActive() &&
|
| 4058 |
+
n._items.indexOf(s) > -1 &&
|
| 4059 |
+
n.send(s, e, i, {
|
| 4060 |
+
appendTo: this._container || document.body,
|
| 4061 |
+
layoutSender: !1,
|
| 4062 |
+
layoutReceiver: !1,
|
| 4063 |
+
}),
|
| 4064 |
+
e.layout(),
|
| 4065 |
+
n.layout())
|
| 4066 |
+
: i !== r &&
|
| 4067 |
+
((this._blockedSortIndex = i),
|
| 4068 |
+
(o === it ? Ue : Ge)(e._items, i, r),
|
| 4069 |
+
e._hasListeners(ct) && e._emit(ct, { item: l, fromIndex: i, toIndex: r, action: o }),
|
| 4070 |
+
e.layout())))
|
| 4071 |
+
}
|
| 4072 |
+
}),
|
| 4073 |
+
(Ei.prototype._finishMigration = function () {
|
| 4074 |
+
var t,
|
| 4075 |
+
e,
|
| 4076 |
+
i = this._item,
|
| 4077 |
+
n = i._dragRelease,
|
| 4078 |
+
r = i._element,
|
| 4079 |
+
s = i._isActive,
|
| 4080 |
+
o = i.getGrid(),
|
| 4081 |
+
a = o._element,
|
| 4082 |
+
l = o._settings,
|
| 4083 |
+
h = l.dragContainer || a,
|
| 4084 |
+
u = this._getGrid()._settings,
|
| 4085 |
+
c = r.parentNode,
|
| 4086 |
+
d = s ? u.itemVisibleClass : u.itemHiddenClass,
|
| 4087 |
+
f = s ? l.itemVisibleClass : l.itemHiddenClass
|
| 4088 |
+
;(this._isMigrating = !1),
|
| 4089 |
+
this.destroy(),
|
| 4090 |
+
u.itemClass !== l.itemClass && (gi(r, u.itemClass), Be(r, l.itemClass)),
|
| 4091 |
+
d !== f && (gi(r, d), Be(r, f)),
|
| 4092 |
+
h !== c && (h.appendChild(r), (e = ai(c, h, !0)), ((t = mi(r)).x -= e.left), (t.y -= e.top)),
|
| 4093 |
+
i._refreshDimensions(),
|
| 4094 |
+
(e = ai(h, a, !0)),
|
| 4095 |
+
(n._containerDiffX = e.left),
|
| 4096 |
+
(n._containerDiffY = e.top),
|
| 4097 |
+
(i._drag = l.dragEnabled ? new Ei(i) : null),
|
| 4098 |
+
h !== c && i._setTranslate(t.x, t.y),
|
| 4099 |
+
i._visibility.setStyles(s ? l.visibleStyles : l.hiddenStyles),
|
| 4100 |
+
n.start()
|
| 4101 |
+
}),
|
| 4102 |
+
(Ei.prototype._preStartCheck = function (t) {
|
| 4103 |
+
0 === this._startPredicateState && (this._startPredicateState = 1),
|
| 4104 |
+
1 === this._startPredicateState
|
| 4105 |
+
? ((this._startPredicateResult = this._startPredicate(this._item, t)),
|
| 4106 |
+
!0 === this._startPredicateResult
|
| 4107 |
+
? ((this._startPredicateState = 2), this._onStart(t))
|
| 4108 |
+
: !1 === this._startPredicateResult &&
|
| 4109 |
+
(this._resetStartPredicate(t), this._dragger._reset(), (this._startPredicateState = 0)))
|
| 4110 |
+
: 2 === this._startPredicateState && this._isActive && this._onMove(t)
|
| 4111 |
+
}),
|
| 4112 |
+
(Ei.prototype._preEndCheck = function (t) {
|
| 4113 |
+
var e = 2 === this._startPredicateState
|
| 4114 |
+
this._startPredicate(this._item, t),
|
| 4115 |
+
(this._startPredicateState = 0),
|
| 4116 |
+
e && this._isActive && (this._isStarted ? this._onEnd(t) : this.stop())
|
| 4117 |
+
}),
|
| 4118 |
+
(Ei.prototype._onStart = function (t) {
|
| 4119 |
+
var e,
|
| 4120 |
+
i,
|
| 4121 |
+
n,
|
| 4122 |
+
r = this._item
|
| 4123 |
+
r._isActive &&
|
| 4124 |
+
((this._isActive = !0),
|
| 4125 |
+
(this._dragStartEvent = t),
|
| 4126 |
+
Ei.autoScroller.addItem(r),
|
| 4127 |
+
(e = r._id),
|
| 4128 |
+
(i = this._prepareStart),
|
| 4129 |
+
(n = this._applyStart),
|
| 4130 |
+
ie.add(0, Bt + e, i),
|
| 4131 |
+
ie.add(2, zt + e, n))
|
| 4132 |
+
}),
|
| 4133 |
+
(Ei.prototype._prepareStart = function () {
|
| 4134 |
+
if (this._isActive) {
|
| 4135 |
+
var t = this._item
|
| 4136 |
+
if (t._isActive) {
|
| 4137 |
+
var e = t._element,
|
| 4138 |
+
i = this._getGrid(),
|
| 4139 |
+
n = i._settings,
|
| 4140 |
+
r = i._element,
|
| 4141 |
+
s = n.dragContainer || r,
|
| 4142 |
+
o = ii(s),
|
| 4143 |
+
a = mi(e),
|
| 4144 |
+
l = e.getBoundingClientRect(),
|
| 4145 |
+
h = s !== r
|
| 4146 |
+
if (
|
| 4147 |
+
((this._container = s),
|
| 4148 |
+
(this._containingBlock = o),
|
| 4149 |
+
(this._clientX = l.left),
|
| 4150 |
+
(this._clientY = l.top),
|
| 4151 |
+
(this._left = this._gridX = a.x),
|
| 4152 |
+
(this._top = this._gridY = a.y),
|
| 4153 |
+
(this._scrollDiffX = this._scrollDiffY = 0),
|
| 4154 |
+
(this._moveDiffX = this._moveDiffY = 0),
|
| 4155 |
+
this._resetHeuristics(this._gridX, this._gridY),
|
| 4156 |
+
h)
|
| 4157 |
+
) {
|
| 4158 |
+
var u = ai(o, r)
|
| 4159 |
+
;(this._containerDiffX = u.left), (this._containerDiffY = u.top)
|
| 4160 |
+
}
|
| 4161 |
+
}
|
| 4162 |
+
}
|
| 4163 |
+
}),
|
| 4164 |
+
(Ei.prototype._applyStart = function () {
|
| 4165 |
+
if (this._isActive) {
|
| 4166 |
+
var t = this._item
|
| 4167 |
+
if (t._isActive) {
|
| 4168 |
+
var e = this._getGrid(),
|
| 4169 |
+
i = t._element,
|
| 4170 |
+
n = t._dragRelease,
|
| 4171 |
+
r = t._migrate,
|
| 4172 |
+
s = this._container !== e._element
|
| 4173 |
+
t.isPositioning() && t._layout.stop(!0, this._left, this._top),
|
| 4174 |
+
r._isActive &&
|
| 4175 |
+
((this._left -= r._containerDiffX),
|
| 4176 |
+
(this._top -= r._containerDiffY),
|
| 4177 |
+
(this._gridX -= r._containerDiffX),
|
| 4178 |
+
(this._gridY -= r._containerDiffY),
|
| 4179 |
+
r.stop(!0, this._left, this._top)),
|
| 4180 |
+
t.isReleasing() && n._reset(),
|
| 4181 |
+
e._settings.dragPlaceholder.enabled && t._dragPlaceholder.create(),
|
| 4182 |
+
(this._isStarted = !0),
|
| 4183 |
+
e._emit('dragInit', t, this._dragStartEvent),
|
| 4184 |
+
s &&
|
| 4185 |
+
(i.parentNode === this._container
|
| 4186 |
+
? ((this._gridX -= this._containerDiffX), (this._gridY -= this._containerDiffY))
|
| 4187 |
+
: ((this._left += this._containerDiffX),
|
| 4188 |
+
(this._top += this._containerDiffY),
|
| 4189 |
+
this._container.appendChild(i),
|
| 4190 |
+
t._setTranslate(this._left, this._top))),
|
| 4191 |
+
Be(i, e._settings.itemDraggingClass),
|
| 4192 |
+
this._bindScrollListeners(),
|
| 4193 |
+
e._emit('dragStart', t, this._dragStartEvent)
|
| 4194 |
+
}
|
| 4195 |
+
}
|
| 4196 |
+
}),
|
| 4197 |
+
(Ei.prototype._onMove = function (t) {
|
| 4198 |
+
var e,
|
| 4199 |
+
i,
|
| 4200 |
+
n,
|
| 4201 |
+
r = this._item
|
| 4202 |
+
r._isActive
|
| 4203 |
+
? ((this._dragMoveEvent = t),
|
| 4204 |
+
(e = r._id),
|
| 4205 |
+
(i = this._prepareMove),
|
| 4206 |
+
(n = this._applyMove),
|
| 4207 |
+
ie.add(0, Wt + e, i),
|
| 4208 |
+
ie.add(2, $t + e, n),
|
| 4209 |
+
le(r._id, this._handleSort))
|
| 4210 |
+
: this.stop()
|
| 4211 |
+
}),
|
| 4212 |
+
(Ei.prototype._prepareMove = function () {
|
| 4213 |
+
if (this._isActive && this._item._isActive) {
|
| 4214 |
+
var t = this._getGrid()._settings.dragAxis,
|
| 4215 |
+
e = this._dragMoveEvent,
|
| 4216 |
+
i = this._dragPrevMoveEvent || this._dragStartEvent || e
|
| 4217 |
+
if ('y' !== t) {
|
| 4218 |
+
var n = e.clientX - i.clientX
|
| 4219 |
+
;(this._left = this._left - this._moveDiffX + n),
|
| 4220 |
+
(this._gridX = this._gridX - this._moveDiffX + n),
|
| 4221 |
+
(this._clientX = this._clientX - this._moveDiffX + n),
|
| 4222 |
+
(this._moveDiffX = n)
|
| 4223 |
+
}
|
| 4224 |
+
if ('x' !== t) {
|
| 4225 |
+
var r = e.clientY - i.clientY
|
| 4226 |
+
;(this._top = this._top - this._moveDiffY + r),
|
| 4227 |
+
(this._gridY = this._gridY - this._moveDiffY + r),
|
| 4228 |
+
(this._clientY = this._clientY - this._moveDiffY + r),
|
| 4229 |
+
(this._moveDiffY = r)
|
| 4230 |
+
}
|
| 4231 |
+
this._dragPrevMoveEvent = e
|
| 4232 |
+
}
|
| 4233 |
+
}),
|
| 4234 |
+
(Ei.prototype._applyMove = function () {
|
| 4235 |
+
if (this._isActive) {
|
| 4236 |
+
var t = this._item
|
| 4237 |
+
t._isActive &&
|
| 4238 |
+
((this._moveDiffX = this._moveDiffY = 0),
|
| 4239 |
+
t._setTranslate(this._left, this._top),
|
| 4240 |
+
this._getGrid()._emit('dragMove', t, this._dragMoveEvent),
|
| 4241 |
+
Ei.autoScroller.updateItem(t))
|
| 4242 |
+
}
|
| 4243 |
+
}),
|
| 4244 |
+
(Ei.prototype._onScroll = function (t) {
|
| 4245 |
+
var e,
|
| 4246 |
+
i,
|
| 4247 |
+
n,
|
| 4248 |
+
r = this._item
|
| 4249 |
+
r._isActive
|
| 4250 |
+
? ((this._scrollEvent = t),
|
| 4251 |
+
(e = r._id),
|
| 4252 |
+
(i = this._prepareScroll),
|
| 4253 |
+
(n = this._applyScroll),
|
| 4254 |
+
ie.add(0, Gt + e, i),
|
| 4255 |
+
ie.add(2, Ut + e, n),
|
| 4256 |
+
le(r._id, this._handleSort))
|
| 4257 |
+
: this.stop()
|
| 4258 |
+
}),
|
| 4259 |
+
(Ei.prototype._prepareScroll = function () {
|
| 4260 |
+
if (this._isActive) {
|
| 4261 |
+
var t = this._item
|
| 4262 |
+
if (t._isActive) {
|
| 4263 |
+
var e = t._element,
|
| 4264 |
+
i = this._getGrid(),
|
| 4265 |
+
n = i._element,
|
| 4266 |
+
r = i._settings.dragAxis,
|
| 4267 |
+
s = 'y' !== r,
|
| 4268 |
+
o = 'x' !== r,
|
| 4269 |
+
a = e.getBoundingClientRect()
|
| 4270 |
+
if (this._container !== n) {
|
| 4271 |
+
var l = ai(this._containingBlock, n)
|
| 4272 |
+
;(this._containerDiffX = l.left), (this._containerDiffY = l.top)
|
| 4273 |
+
}
|
| 4274 |
+
if (s) {
|
| 4275 |
+
var h = this._clientX - this._moveDiffX - this._scrollDiffX - a.left
|
| 4276 |
+
;(this._left = this._left - this._scrollDiffX + h), (this._scrollDiffX = h)
|
| 4277 |
+
}
|
| 4278 |
+
if (o) {
|
| 4279 |
+
var u = this._clientY - this._moveDiffY - this._scrollDiffY - a.top
|
| 4280 |
+
;(this._top = this._top - this._scrollDiffY + u), (this._scrollDiffY = u)
|
| 4281 |
+
}
|
| 4282 |
+
;(this._gridX = this._left - this._containerDiffX), (this._gridY = this._top - this._containerDiffY)
|
| 4283 |
+
}
|
| 4284 |
+
}
|
| 4285 |
+
}),
|
| 4286 |
+
(Ei.prototype._applyScroll = function () {
|
| 4287 |
+
if (this._isActive) {
|
| 4288 |
+
var t = this._item
|
| 4289 |
+
t._isActive &&
|
| 4290 |
+
((this._scrollDiffX = this._scrollDiffY = 0),
|
| 4291 |
+
t._setTranslate(this._left, this._top),
|
| 4292 |
+
this._getGrid()._emit('dragScroll', t, this._scrollEvent))
|
| 4293 |
+
}
|
| 4294 |
+
}),
|
| 4295 |
+
(Ei.prototype._onEnd = function (t) {
|
| 4296 |
+
var e = this._item,
|
| 4297 |
+
i = e._element,
|
| 4298 |
+
n = this._getGrid(),
|
| 4299 |
+
r = n._settings,
|
| 4300 |
+
s = e._dragRelease
|
| 4301 |
+
e._isActive
|
| 4302 |
+
? (se(e._id),
|
| 4303 |
+
oe(e._id),
|
| 4304 |
+
ae(e._id),
|
| 4305 |
+
this._finishSort(),
|
| 4306 |
+
this._unbindScrollListeners(),
|
| 4307 |
+
(s._containerDiffX = this._containerDiffX),
|
| 4308 |
+
(s._containerDiffY = this._containerDiffY),
|
| 4309 |
+
this._reset(),
|
| 4310 |
+
gi(i, r.itemDraggingClass),
|
| 4311 |
+
Ei.autoScroller.removeItem(e),
|
| 4312 |
+
n._emit('dragEnd', e, t),
|
| 4313 |
+
this._isMigrating ? this._finishMigration() : s.start())
|
| 4314 |
+
: this.stop()
|
| 4315 |
+
})
|
| 4316 |
+
var Di = /^(webkit|moz|ms|o|Webkit|Moz|MS|O)(?=[A-Z])/,
|
| 4317 |
+
Ai = {}
|
| 4318 |
+
function ki(t) {
|
| 4319 |
+
var e = Ai[t]
|
| 4320 |
+
return e || ((e = t.replace(Di, '')) !== t && (e = e[0].toLowerCase() + e.slice(1)), (Ai[t] = e), e)
|
| 4321 |
+
}
|
| 4322 |
+
function Ri(t, e) {
|
| 4323 |
+
for (var i in e) t.style[i] = e[i]
|
| 4324 |
+
}
|
| 4325 |
+
var Pi,
|
| 4326 |
+
Oi,
|
| 4327 |
+
Li = !(!Element || !ce(Element.prototype.animate)),
|
| 4328 |
+
Ci = !!(
|
| 4329 |
+
Element &&
|
| 4330 |
+
((Pi = Element.prototype.animate),
|
| 4331 |
+
(Oi = window.Symbol),
|
| 4332 |
+
Pi && ce(Oi) && ce(Oi.toString) && Oi(Pi).toString().indexOf('[native code]') > -1)
|
| 4333 |
+
)
|
| 4334 |
+
function Mi(t) {
|
| 4335 |
+
;(this._element = t),
|
| 4336 |
+
(this._animation = null),
|
| 4337 |
+
(this._duration = 0),
|
| 4338 |
+
(this._easing = ''),
|
| 4339 |
+
(this._callback = null),
|
| 4340 |
+
(this._props = []),
|
| 4341 |
+
(this._values = []),
|
| 4342 |
+
(this._isDestroyed = !1),
|
| 4343 |
+
(this._onFinish = this._onFinish.bind(this))
|
| 4344 |
+
}
|
| 4345 |
+
function Ii(t, e) {
|
| 4346 |
+
var i = {}
|
| 4347 |
+
for (var n in t) i[e ? n : ki(n)] = t[n]
|
| 4348 |
+
return i
|
| 4349 |
+
}
|
| 4350 |
+
function Ni(t, e) {
|
| 4351 |
+
return 'translateX(' + t + 'px) translateY(' + e + 'px)'
|
| 4352 |
+
}
|
| 4353 |
+
function qi(t) {
|
| 4354 |
+
;(this._item = t),
|
| 4355 |
+
(this._animation = new Mi()),
|
| 4356 |
+
(this._element = null),
|
| 4357 |
+
(this._className = ''),
|
| 4358 |
+
(this._didMigrate = !1),
|
| 4359 |
+
(this._resetAfterLayout = !1),
|
| 4360 |
+
(this._left = 0),
|
| 4361 |
+
(this._top = 0),
|
| 4362 |
+
(this._transX = 0),
|
| 4363 |
+
(this._transY = 0),
|
| 4364 |
+
(this._nextTransX = 0),
|
| 4365 |
+
(this._nextTransY = 0),
|
| 4366 |
+
(this._setupAnimation = this._setupAnimation.bind(this)),
|
| 4367 |
+
(this._startAnimation = this._startAnimation.bind(this)),
|
| 4368 |
+
(this._updateDimensions = this._updateDimensions.bind(this)),
|
| 4369 |
+
(this._onLayoutStart = this._onLayoutStart.bind(this)),
|
| 4370 |
+
(this._onLayoutEnd = this._onLayoutEnd.bind(this)),
|
| 4371 |
+
(this._onReleaseEnd = this._onReleaseEnd.bind(this)),
|
| 4372 |
+
(this._onMigrate = this._onMigrate.bind(this)),
|
| 4373 |
+
(this._onHide = this._onHide.bind(this))
|
| 4374 |
+
}
|
| 4375 |
+
function ji(t) {
|
| 4376 |
+
;(this._item = t),
|
| 4377 |
+
(this._isActive = !1),
|
| 4378 |
+
(this._isDestroyed = !1),
|
| 4379 |
+
(this._isPositioningStarted = !1),
|
| 4380 |
+
(this._containerDiffX = 0),
|
| 4381 |
+
(this._containerDiffY = 0)
|
| 4382 |
+
}
|
| 4383 |
+
;(Mi.prototype.start = function (t, e, i) {
|
| 4384 |
+
if (!this._isDestroyed) {
|
| 4385 |
+
var n = this._element,
|
| 4386 |
+
r = i || {}
|
| 4387 |
+
if (!Li) return Ri(n, e), (this._callback = ce(r.onFinish) ? r.onFinish : null), void this._onFinish()
|
| 4388 |
+
var s,
|
| 4389 |
+
o,
|
| 4390 |
+
a,
|
| 4391 |
+
l = this._animation,
|
| 4392 |
+
h = this._props,
|
| 4393 |
+
u = this._values,
|
| 4394 |
+
c = r.duration || 300,
|
| 4395 |
+
d = r.easing || 'ease',
|
| 4396 |
+
f = !1
|
| 4397 |
+
if (l && ((o = 0), (c === this._duration && d === this._easing) || (f = !0), !f)) {
|
| 4398 |
+
for (s in e)
|
| 4399 |
+
if ((++o, -1 === (a = h.indexOf(s)) || e[s] !== u[a])) {
|
| 4400 |
+
f = !0
|
| 4401 |
+
break
|
| 4402 |
+
}
|
| 4403 |
+
o !== h.length && (f = !0)
|
| 4404 |
+
}
|
| 4405 |
+
if ((f && l.cancel(), (this._callback = ce(r.onFinish) ? r.onFinish : null), !l || f)) {
|
| 4406 |
+
for (s in ((h.length = u.length = 0), e)) h.push(s), u.push(e[s])
|
| 4407 |
+
;(this._duration = c),
|
| 4408 |
+
(this._easing = d),
|
| 4409 |
+
(this._animation = n.animate([Ii(t, Ci), Ii(e, Ci)], { duration: c, easing: d })),
|
| 4410 |
+
(this._animation.onfinish = this._onFinish),
|
| 4411 |
+
Ri(n, e)
|
| 4412 |
+
}
|
| 4413 |
+
}
|
| 4414 |
+
}),
|
| 4415 |
+
(Mi.prototype.stop = function () {
|
| 4416 |
+
!this._isDestroyed &&
|
| 4417 |
+
this._animation &&
|
| 4418 |
+
(this._animation.cancel(),
|
| 4419 |
+
(this._animation = this._callback = null),
|
| 4420 |
+
(this._props.length = this._values.length = 0))
|
| 4421 |
+
}),
|
| 4422 |
+
(Mi.prototype.getCurrentStyles = function () {
|
| 4423 |
+
return Ti(element, currentProps)
|
| 4424 |
+
}),
|
| 4425 |
+
(Mi.prototype.isAnimating = function () {
|
| 4426 |
+
return !!this._animation
|
| 4427 |
+
}),
|
| 4428 |
+
(Mi.prototype.destroy = function () {
|
| 4429 |
+
this._isDestroyed || (this.stop(), (this._element = null), (this._isDestroyed = !0))
|
| 4430 |
+
}),
|
| 4431 |
+
(Mi.prototype._onFinish = function () {
|
| 4432 |
+
var t = this._callback
|
| 4433 |
+
;(this._animation = this._callback = null), (this._props.length = this._values.length = 0), t && t()
|
| 4434 |
+
}),
|
| 4435 |
+
(qi.prototype._updateDimensions = function () {
|
| 4436 |
+
this.isActive() && Ri(this._element, { width: this._item._width + 'px', height: this._item._height + 'px' })
|
| 4437 |
+
}),
|
| 4438 |
+
(qi.prototype._onLayoutStart = function (t, e) {
|
| 4439 |
+
var i = this._item
|
| 4440 |
+
if (-1 !== t.indexOf(i)) {
|
| 4441 |
+
var n = i._left,
|
| 4442 |
+
r = i._top,
|
| 4443 |
+
s = this._left,
|
| 4444 |
+
o = this._top
|
| 4445 |
+
if (((this._left = n), (this._top = r), e || this._didMigrate || s !== n || o !== r)) {
|
| 4446 |
+
var a,
|
| 4447 |
+
l,
|
| 4448 |
+
h,
|
| 4449 |
+
u = n + i._marginLeft,
|
| 4450 |
+
c = r + i._marginTop,
|
| 4451 |
+
d = i.getGrid()
|
| 4452 |
+
if (!(!e && d._settings.layoutDuration > 0) || this._didMigrate)
|
| 4453 |
+
return (
|
| 4454 |
+
he(i._id),
|
| 4455 |
+
(this._element.style[Ve] = Ni(u, c)),
|
| 4456 |
+
this._animation.stop(),
|
| 4457 |
+
void (
|
| 4458 |
+
this._didMigrate && (d.getElement().appendChild(this._element), (this._didMigrate = !1))
|
| 4459 |
+
)
|
| 4460 |
+
)
|
| 4461 |
+
;(this._nextTransX = u),
|
| 4462 |
+
(this._nextTransY = c),
|
| 4463 |
+
(a = i._id),
|
| 4464 |
+
(l = this._setupAnimation),
|
| 4465 |
+
(h = this._startAnimation),
|
| 4466 |
+
ie.add(0, Jt + a, l),
|
| 4467 |
+
ie.add(2, Kt + a, h)
|
| 4468 |
+
}
|
| 4469 |
+
} else this.reset()
|
| 4470 |
+
}),
|
| 4471 |
+
(qi.prototype._setupAnimation = function () {
|
| 4472 |
+
if (this.isActive()) {
|
| 4473 |
+
var t = mi(this._element)
|
| 4474 |
+
;(this._transX = t.x), (this._transY = t.y)
|
| 4475 |
+
}
|
| 4476 |
+
}),
|
| 4477 |
+
(qi.prototype._startAnimation = function () {
|
| 4478 |
+
if (this.isActive()) {
|
| 4479 |
+
var t = this._animation,
|
| 4480 |
+
e = this._transX,
|
| 4481 |
+
i = this._transY,
|
| 4482 |
+
n = this._nextTransX,
|
| 4483 |
+
r = this._nextTransY
|
| 4484 |
+
if (e !== n || i !== r) {
|
| 4485 |
+
var s = this._item.getGrid()._settings,
|
| 4486 |
+
o = {},
|
| 4487 |
+
a = {}
|
| 4488 |
+
;(o[Ve] = Ni(e, i)),
|
| 4489 |
+
(a[Ve] = Ni(n, r)),
|
| 4490 |
+
t.start(o, a, {
|
| 4491 |
+
duration: s.layoutDuration,
|
| 4492 |
+
easing: s.layoutEasing,
|
| 4493 |
+
onFinish: this._onLayoutEnd,
|
| 4494 |
+
})
|
| 4495 |
+
} else t.isAnimating() && ((this._element.style[Ve] = Ni(n, r)), t.stop())
|
| 4496 |
+
}
|
| 4497 |
+
}),
|
| 4498 |
+
(qi.prototype._onLayoutEnd = function () {
|
| 4499 |
+
this._resetAfterLayout && this.reset()
|
| 4500 |
+
}),
|
| 4501 |
+
(qi.prototype._onReleaseEnd = function (t) {
|
| 4502 |
+
if (t._id === this._item._id) {
|
| 4503 |
+
if (!this._animation.isAnimating()) return void this.reset()
|
| 4504 |
+
this._resetAfterLayout = !0
|
| 4505 |
+
}
|
| 4506 |
+
}),
|
| 4507 |
+
(qi.prototype._onMigrate = function (t) {
|
| 4508 |
+
if (t.item === this._item) {
|
| 4509 |
+
var e = this._item.getGrid(),
|
| 4510 |
+
i = t.toGrid
|
| 4511 |
+
e.off(mt, this._onReleaseEnd),
|
| 4512 |
+
e.off(rt, this._onLayoutStart),
|
| 4513 |
+
e.off(ft, this._onMigrate),
|
| 4514 |
+
e.off(lt, this._onHide),
|
| 4515 |
+
i.on(mt, this._onReleaseEnd),
|
| 4516 |
+
i.on(rt, this._onLayoutStart),
|
| 4517 |
+
i.on(ft, this._onMigrate),
|
| 4518 |
+
i.on(lt, this._onHide),
|
| 4519 |
+
(this._didMigrate = !0)
|
| 4520 |
+
}
|
| 4521 |
+
}),
|
| 4522 |
+
(qi.prototype._onHide = function (t) {
|
| 4523 |
+
t.indexOf(this._item) > -1 && this.reset()
|
| 4524 |
+
}),
|
| 4525 |
+
(qi.prototype.create = function () {
|
| 4526 |
+
if (this.isActive()) this._resetAfterLayout = !1
|
| 4527 |
+
else {
|
| 4528 |
+
var t,
|
| 4529 |
+
e = this._item,
|
| 4530 |
+
i = e.getGrid(),
|
| 4531 |
+
n = i._settings,
|
| 4532 |
+
r = this._animation
|
| 4533 |
+
;(this._left = e._left),
|
| 4534 |
+
(this._top = e._top),
|
| 4535 |
+
(t = ce(n.dragPlaceholder.createElement)
|
| 4536 |
+
? n.dragPlaceholder.createElement(e)
|
| 4537 |
+
: document.createElement('div')),
|
| 4538 |
+
(this._element = t),
|
| 4539 |
+
(r._element = t),
|
| 4540 |
+
(this._className = n.itemPlaceholderClass || ''),
|
| 4541 |
+
this._className && Be(t, this._className),
|
| 4542 |
+
Ri(t, {
|
| 4543 |
+
position: 'absolute',
|
| 4544 |
+
left: '0px',
|
| 4545 |
+
top: '0px',
|
| 4546 |
+
width: e._width + 'px',
|
| 4547 |
+
height: e._height + 'px',
|
| 4548 |
+
}),
|
| 4549 |
+
(t.style[Ve] = Ni(e._left + e._marginLeft, e._top + e._marginTop)),
|
| 4550 |
+
i.on(rt, this._onLayoutStart),
|
| 4551 |
+
i.on(mt, this._onReleaseEnd),
|
| 4552 |
+
i.on(ft, this._onMigrate),
|
| 4553 |
+
i.on(lt, this._onHide),
|
| 4554 |
+
ce(n.dragPlaceholder.onCreate) && n.dragPlaceholder.onCreate(e, t),
|
| 4555 |
+
i.getElement().appendChild(t)
|
| 4556 |
+
}
|
| 4557 |
+
}),
|
| 4558 |
+
(qi.prototype.reset = function () {
|
| 4559 |
+
if (this.isActive()) {
|
| 4560 |
+
var t,
|
| 4561 |
+
e = this._element,
|
| 4562 |
+
i = this._item,
|
| 4563 |
+
n = i.getGrid(),
|
| 4564 |
+
r = n._settings,
|
| 4565 |
+
s = this._animation
|
| 4566 |
+
;(this._resetAfterLayout = !1),
|
| 4567 |
+
he(i._id),
|
| 4568 |
+
(t = i._id),
|
| 4569 |
+
ie.remove(2, Qt + t),
|
| 4570 |
+
s.stop(),
|
| 4571 |
+
(s._element = null),
|
| 4572 |
+
n.off(mt, this._onReleaseEnd),
|
| 4573 |
+
n.off(rt, this._onLayoutStart),
|
| 4574 |
+
n.off(ft, this._onMigrate),
|
| 4575 |
+
n.off(lt, this._onHide),
|
| 4576 |
+
this._className && (gi(e, this._className), (this._className = '')),
|
| 4577 |
+
e.parentNode.removeChild(e),
|
| 4578 |
+
(this._element = null),
|
| 4579 |
+
ce(r.dragPlaceholder.onRemove) && r.dragPlaceholder.onRemove(i, e)
|
| 4580 |
+
}
|
| 4581 |
+
}),
|
| 4582 |
+
(qi.prototype.isActive = function () {
|
| 4583 |
+
return !!this._element
|
| 4584 |
+
}),
|
| 4585 |
+
(qi.prototype.getElement = function () {
|
| 4586 |
+
return this._element
|
| 4587 |
+
}),
|
| 4588 |
+
(qi.prototype.updateDimensions = function () {
|
| 4589 |
+
var t, e
|
| 4590 |
+
this.isActive() && ((t = this._item._id), (e = this._updateDimensions), ie.add(2, Qt + t, e))
|
| 4591 |
+
}),
|
| 4592 |
+
(qi.prototype.destroy = function () {
|
| 4593 |
+
this.reset(), this._animation.destroy(), (this._item = this._animation = null)
|
| 4594 |
+
}),
|
| 4595 |
+
(ji.prototype.start = function () {
|
| 4596 |
+
if (!this._isDestroyed && !this._isActive) {
|
| 4597 |
+
var t = this._item,
|
| 4598 |
+
e = t.getGrid(),
|
| 4599 |
+
i = e._settings
|
| 4600 |
+
;(this._isActive = !0),
|
| 4601 |
+
Be(t._element, i.itemReleasingClass),
|
| 4602 |
+
i.dragRelease.useDragContainer || this._placeToGrid(),
|
| 4603 |
+
e._emit('dragReleaseStart', t),
|
| 4604 |
+
e._nextLayoutData || t._layout.start(!1)
|
| 4605 |
+
}
|
| 4606 |
+
}),
|
| 4607 |
+
(ji.prototype.stop = function (t, e, i) {
|
| 4608 |
+
if (!this._isDestroyed && this._isActive) {
|
| 4609 |
+
var n = this._item,
|
| 4610 |
+
r = n.getGrid()
|
| 4611 |
+
t || (void 0 !== e && void 0 !== i) || ((e = n._left), (i = n._top))
|
| 4612 |
+
var s = this._placeToGrid(e, i)
|
| 4613 |
+
this._reset(s), t || r._emit(mt, n)
|
| 4614 |
+
}
|
| 4615 |
+
}),
|
| 4616 |
+
(ji.prototype.isJustReleased = function () {
|
| 4617 |
+
return this._isActive && !1 === this._isPositioningStarted
|
| 4618 |
+
}),
|
| 4619 |
+
(ji.prototype.destroy = function () {
|
| 4620 |
+
this._isDestroyed || (this.stop(!0), (this._item = null), (this._isDestroyed = !0))
|
| 4621 |
+
}),
|
| 4622 |
+
(ji.prototype._placeToGrid = function (t, e) {
|
| 4623 |
+
if (!this._isDestroyed) {
|
| 4624 |
+
var i = this._item,
|
| 4625 |
+
n = i._element,
|
| 4626 |
+
r = i.getGrid()._element,
|
| 4627 |
+
s = !1
|
| 4628 |
+
if (n.parentNode !== r) {
|
| 4629 |
+
if (void 0 === t || void 0 === e) {
|
| 4630 |
+
var o = mi(n)
|
| 4631 |
+
;(t = o.x - this._containerDiffX), (e = o.y - this._containerDiffY)
|
| 4632 |
+
}
|
| 4633 |
+
r.appendChild(n), i._setTranslate(t, e), (s = !0)
|
| 4634 |
+
}
|
| 4635 |
+
return (this._containerDiffX = 0), (this._containerDiffY = 0), s
|
| 4636 |
+
}
|
| 4637 |
+
}),
|
| 4638 |
+
(ji.prototype._reset = function (t) {
|
| 4639 |
+
if (!this._isDestroyed) {
|
| 4640 |
+
var e = this._item,
|
| 4641 |
+
i = e.getGrid()._settings.itemReleasingClass
|
| 4642 |
+
;(this._isActive = !1),
|
| 4643 |
+
(this._isPositioningStarted = !1),
|
| 4644 |
+
(this._containerDiffX = 0),
|
| 4645 |
+
(this._containerDiffY = 0),
|
| 4646 |
+
i && gi(e._element, i)
|
| 4647 |
+
}
|
| 4648 |
+
})
|
| 4649 |
+
function Xi(t) {
|
| 4650 |
+
var e = t._element,
|
| 4651 |
+
i = e.style
|
| 4652 |
+
;(this._item = t),
|
| 4653 |
+
(this._isActive = !1),
|
| 4654 |
+
(this._isDestroyed = !1),
|
| 4655 |
+
(this._isInterrupted = !1),
|
| 4656 |
+
(this._currentStyles = {}),
|
| 4657 |
+
(this._targetStyles = {}),
|
| 4658 |
+
(this._nextLeft = 0),
|
| 4659 |
+
(this._nextTop = 0),
|
| 4660 |
+
(this._offsetLeft = 0),
|
| 4661 |
+
(this._offsetTop = 0),
|
| 4662 |
+
(this._skipNextAnimation = !1),
|
| 4663 |
+
(this._animOptions = { onFinish: this._finish.bind(this), duration: 0, easing: 0 }),
|
| 4664 |
+
(i.left = '0px'),
|
| 4665 |
+
(i.top = '0px'),
|
| 4666 |
+
t._setTranslate(0, 0),
|
| 4667 |
+
(this._animation = new Mi(e)),
|
| 4668 |
+
(this._queue = 'layout-' + t._id),
|
| 4669 |
+
(this._setupAnimation = this._setupAnimation.bind(this)),
|
| 4670 |
+
(this._startAnimation = this._startAnimation.bind(this))
|
| 4671 |
+
}
|
| 4672 |
+
function Fi(t) {
|
| 4673 |
+
;(this._item = t),
|
| 4674 |
+
(this._isActive = !1),
|
| 4675 |
+
(this._isDestroyed = !1),
|
| 4676 |
+
(this._container = !1),
|
| 4677 |
+
(this._containerDiffX = 0),
|
| 4678 |
+
(this._containerDiffY = 0)
|
| 4679 |
+
}
|
| 4680 |
+
function Hi(t) {
|
| 4681 |
+
var e = t._isActive,
|
| 4682 |
+
i = t._element,
|
| 4683 |
+
n = i.children[0],
|
| 4684 |
+
r = t.getGrid()._settings
|
| 4685 |
+
if (!n) throw new Error('No valid child element found within item element.')
|
| 4686 |
+
;(this._item = t),
|
| 4687 |
+
(this._isDestroyed = !1),
|
| 4688 |
+
(this._isHidden = !e),
|
| 4689 |
+
(this._isHiding = !1),
|
| 4690 |
+
(this._isShowing = !1),
|
| 4691 |
+
(this._childElement = n),
|
| 4692 |
+
(this._currentStyleProps = []),
|
| 4693 |
+
(this._animation = new Mi(n)),
|
| 4694 |
+
(this._queue = 'visibility-' + t._id),
|
| 4695 |
+
(this._finishShow = this._finishShow.bind(this)),
|
| 4696 |
+
(this._finishHide = this._finishHide.bind(this)),
|
| 4697 |
+
(i.style.display = e ? '' : 'none'),
|
| 4698 |
+
Be(i, e ? r.itemVisibleClass : r.itemHiddenClass),
|
| 4699 |
+
this.setStyles(e ? r.visibleStyles : r.hiddenStyles)
|
| 4700 |
+
}
|
| 4701 |
+
;(Xi.prototype.start = function (t, e) {
|
| 4702 |
+
if (!this._isDestroyed) {
|
| 4703 |
+
var i,
|
| 4704 |
+
n,
|
| 4705 |
+
r,
|
| 4706 |
+
s = this._item,
|
| 4707 |
+
o = s._dragRelease,
|
| 4708 |
+
a = s.getGrid()._settings,
|
| 4709 |
+
l = this._isActive,
|
| 4710 |
+
h = o.isJustReleased(),
|
| 4711 |
+
u = h ? a.dragRelease.duration : a.layoutDuration,
|
| 4712 |
+
c = h ? a.dragRelease.easing : a.layoutEasing,
|
| 4713 |
+
d = !t && !this._skipNextAnimation && u > 0
|
| 4714 |
+
if (
|
| 4715 |
+
(l && (ne(s._id), s._emitter.burst(this._queue, !0, s)),
|
| 4716 |
+
h && (o._isPositioningStarted = !0),
|
| 4717 |
+
ce(e) && s._emitter.on(this._queue, e),
|
| 4718 |
+
(this._skipNextAnimation = !1),
|
| 4719 |
+
!d)
|
| 4720 |
+
)
|
| 4721 |
+
return (
|
| 4722 |
+
this._updateOffsets(),
|
| 4723 |
+
s._setTranslate(this._nextLeft, this._nextTop),
|
| 4724 |
+
this._animation.stop(),
|
| 4725 |
+
void this._finish()
|
| 4726 |
+
)
|
| 4727 |
+
this._animation.isAnimating() && (this._animation._animation.onfinish = null),
|
| 4728 |
+
(this._isActive = !0),
|
| 4729 |
+
(this._animOptions.easing = c),
|
| 4730 |
+
(this._animOptions.duration = u),
|
| 4731 |
+
(this._isInterrupted = l),
|
| 4732 |
+
(i = s._id),
|
| 4733 |
+
(n = this._setupAnimation),
|
| 4734 |
+
(r = this._startAnimation),
|
| 4735 |
+
ie.add(0, Xt + i, n),
|
| 4736 |
+
ie.add(2, Ft + i, r)
|
| 4737 |
+
}
|
| 4738 |
+
}),
|
| 4739 |
+
(Xi.prototype.stop = function (t, e, i) {
|
| 4740 |
+
if (!this._isDestroyed && this._isActive) {
|
| 4741 |
+
var n = this._item
|
| 4742 |
+
if ((ne(n._id), this._animation.isAnimating())) {
|
| 4743 |
+
if (void 0 === e || void 0 === i) {
|
| 4744 |
+
var r = mi(n._element)
|
| 4745 |
+
;(e = r.x), (i = r.y)
|
| 4746 |
+
}
|
| 4747 |
+
n._setTranslate(e, i), this._animation.stop()
|
| 4748 |
+
}
|
| 4749 |
+
gi(n._element, n.getGrid()._settings.itemPositioningClass),
|
| 4750 |
+
(this._isActive = !1),
|
| 4751 |
+
t && n._emitter.burst(this._queue, !0, n)
|
| 4752 |
+
}
|
| 4753 |
+
}),
|
| 4754 |
+
(Xi.prototype.destroy = function () {
|
| 4755 |
+
if (!this._isDestroyed) {
|
| 4756 |
+
var t = this._item._element.style
|
| 4757 |
+
this.stop(!0, 0, 0),
|
| 4758 |
+
this._item._emitter.clear(this._queue),
|
| 4759 |
+
this._animation.destroy(),
|
| 4760 |
+
(t[Ve] = ''),
|
| 4761 |
+
(t.left = ''),
|
| 4762 |
+
(t.top = ''),
|
| 4763 |
+
(this._item = null),
|
| 4764 |
+
(this._currentStyles = null),
|
| 4765 |
+
(this._targetStyles = null),
|
| 4766 |
+
(this._animOptions = null),
|
| 4767 |
+
(this._isDestroyed = !0)
|
| 4768 |
+
}
|
| 4769 |
+
}),
|
| 4770 |
+
(Xi.prototype._updateOffsets = function () {
|
| 4771 |
+
if (!this._isDestroyed) {
|
| 4772 |
+
var t = this._item,
|
| 4773 |
+
e = t._migrate,
|
| 4774 |
+
i = t._dragRelease
|
| 4775 |
+
;(this._offsetLeft = i._isActive ? i._containerDiffX : e._isActive ? e._containerDiffX : 0),
|
| 4776 |
+
(this._offsetTop = i._isActive ? i._containerDiffY : e._isActive ? e._containerDiffY : 0),
|
| 4777 |
+
(this._nextLeft = this._item._left + this._offsetLeft),
|
| 4778 |
+
(this._nextTop = this._item._top + this._offsetTop)
|
| 4779 |
+
}
|
| 4780 |
+
}),
|
| 4781 |
+
(Xi.prototype._finish = function () {
|
| 4782 |
+
if (!this._isDestroyed) {
|
| 4783 |
+
var t = this._item,
|
| 4784 |
+
e = t._migrate,
|
| 4785 |
+
i = t._dragRelease
|
| 4786 |
+
;(t._tX = this._nextLeft),
|
| 4787 |
+
(t._tY = this._nextTop),
|
| 4788 |
+
this._isActive &&
|
| 4789 |
+
((this._isActive = !1), gi(t._element, t.getGrid()._settings.itemPositioningClass)),
|
| 4790 |
+
i._isActive && i.stop(),
|
| 4791 |
+
e._isActive && e.stop(),
|
| 4792 |
+
t._emitter.burst(this._queue, !1, t)
|
| 4793 |
+
}
|
| 4794 |
+
}),
|
| 4795 |
+
(Xi.prototype._setupAnimation = function () {
|
| 4796 |
+
var t = this._item
|
| 4797 |
+
if (void 0 === t._tX || void 0 === t._tY) {
|
| 4798 |
+
var e = mi(t._element)
|
| 4799 |
+
;(t._tX = e.x), (t._tY = e.y)
|
| 4800 |
+
}
|
| 4801 |
+
}),
|
| 4802 |
+
(Xi.prototype._startAnimation = function () {
|
| 4803 |
+
var t = this._item,
|
| 4804 |
+
e = t.getGrid()._settings,
|
| 4805 |
+
i = this._animOptions.duration <= 0
|
| 4806 |
+
this._updateOffsets()
|
| 4807 |
+
var n = Math.abs(t._left - (t._tX - this._offsetLeft)),
|
| 4808 |
+
r = Math.abs(t._top - (t._tY - this._offsetTop))
|
| 4809 |
+
if (i || (n < 2 && r < 2))
|
| 4810 |
+
return (
|
| 4811 |
+
(n || r || this._isInterrupted) && t._setTranslate(this._nextLeft, this._nextTop),
|
| 4812 |
+
this._animation.stop(),
|
| 4813 |
+
void this._finish()
|
| 4814 |
+
)
|
| 4815 |
+
this._isInterrupted || Be(t._element, e.itemPositioningClass),
|
| 4816 |
+
(this._currentStyles[Ve] = Ni(t._tX, t._tY)),
|
| 4817 |
+
(this._targetStyles[Ve] = Ni(this._nextLeft, this._nextTop)),
|
| 4818 |
+
(t._tX = t._tY = void 0),
|
| 4819 |
+
this._animation.start(this._currentStyles, this._targetStyles, this._animOptions)
|
| 4820 |
+
}),
|
| 4821 |
+
(Fi.prototype.start = function (t, e, i) {
|
| 4822 |
+
if (!this._isDestroyed) {
|
| 4823 |
+
var n,
|
| 4824 |
+
r,
|
| 4825 |
+
s,
|
| 4826 |
+
o,
|
| 4827 |
+
a,
|
| 4828 |
+
l,
|
| 4829 |
+
h,
|
| 4830 |
+
u,
|
| 4831 |
+
c,
|
| 4832 |
+
d,
|
| 4833 |
+
f = this._item,
|
| 4834 |
+
p = f._element,
|
| 4835 |
+
_ = f.isActive(),
|
| 4836 |
+
m = f.isVisible(),
|
| 4837 |
+
g = f.getGrid(),
|
| 4838 |
+
v = g._settings,
|
| 4839 |
+
y = t._settings,
|
| 4840 |
+
b = t._element,
|
| 4841 |
+
w = t._items,
|
| 4842 |
+
x = g._items.indexOf(f),
|
| 4843 |
+
S = i || document.body
|
| 4844 |
+
if ('number' == typeof e) n = $e(w, e, 1)
|
| 4845 |
+
else {
|
| 4846 |
+
if (!(r = t.getItem(e))) return
|
| 4847 |
+
n = w.indexOf(r)
|
| 4848 |
+
}
|
| 4849 |
+
;(f.isPositioning() || this._isActive || f.isReleasing()) && ((h = (l = mi(p)).x), (u = l.y)),
|
| 4850 |
+
f.isPositioning() && f._layout.stop(!0, h, u),
|
| 4851 |
+
this._isActive && ((h -= this._containerDiffX), (u -= this._containerDiffY), this.stop(!0, h, u)),
|
| 4852 |
+
f.isReleasing() &&
|
| 4853 |
+
((h -= f._dragRelease._containerDiffX),
|
| 4854 |
+
(u -= f._dragRelease._containerDiffY),
|
| 4855 |
+
f._dragRelease.stop(!0, h, u)),
|
| 4856 |
+
f._visibility.stop(!0),
|
| 4857 |
+
f._drag && f._drag.destroy(),
|
| 4858 |
+
g._hasListeners(ft) && g._emit(ft, { item: f, fromGrid: g, fromIndex: x, toGrid: t, toIndex: n }),
|
| 4859 |
+
t._hasListeners(_t) && t._emit(_t, { item: f, fromGrid: g, fromIndex: x, toGrid: t, toIndex: n }),
|
| 4860 |
+
v.itemClass !== y.itemClass && (gi(p, v.itemClass), Be(p, y.itemClass)),
|
| 4861 |
+
(c = m ? v.itemVisibleClass : v.itemHiddenClass) !==
|
| 4862 |
+
(d = m ? y.itemVisibleClass : y.itemHiddenClass) && (gi(p, c), Be(p, d)),
|
| 4863 |
+
g._items.splice(x, 1),
|
| 4864 |
+
We(w, f, n),
|
| 4865 |
+
(f._gridId = t._id),
|
| 4866 |
+
_
|
| 4867 |
+
? S !== (s = p.parentNode) &&
|
| 4868 |
+
(S.appendChild(p),
|
| 4869 |
+
(o = ai(S, s, !0)),
|
| 4870 |
+
l || ((h = (l = mi(p)).x), (u = l.y)),
|
| 4871 |
+
f._setTranslate(h + o.left, u + o.top))
|
| 4872 |
+
: b.appendChild(p),
|
| 4873 |
+
f._visibility.setStyles(m ? y.visibleStyles : y.hiddenStyles),
|
| 4874 |
+
_ && (a = ai(S, b, !0)),
|
| 4875 |
+
f._refreshDimensions(),
|
| 4876 |
+
(f._sortData = null),
|
| 4877 |
+
(f._drag = y.dragEnabled ? new Ei(f) : null),
|
| 4878 |
+
_
|
| 4879 |
+
? ((this._isActive = !0),
|
| 4880 |
+
(this._container = S),
|
| 4881 |
+
(this._containerDiffX = a.left),
|
| 4882 |
+
(this._containerDiffY = a.top))
|
| 4883 |
+
: ((this._isActive = !1),
|
| 4884 |
+
(this._container = null),
|
| 4885 |
+
(this._containerDiffX = 0),
|
| 4886 |
+
(this._containerDiffY = 0)),
|
| 4887 |
+
g._hasListeners(dt) && g._emit(dt, { item: f, fromGrid: g, fromIndex: x, toGrid: t, toIndex: n }),
|
| 4888 |
+
t._hasListeners(pt) && t._emit(pt, { item: f, fromGrid: g, fromIndex: x, toGrid: t, toIndex: n })
|
| 4889 |
+
}
|
| 4890 |
+
}),
|
| 4891 |
+
(Fi.prototype.stop = function (t, e, i) {
|
| 4892 |
+
if (!this._isDestroyed && this._isActive) {
|
| 4893 |
+
var n,
|
| 4894 |
+
r = this._item,
|
| 4895 |
+
s = r._element,
|
| 4896 |
+
o = r.getGrid()._element
|
| 4897 |
+
this._container !== o &&
|
| 4898 |
+
((void 0 !== e && void 0 !== i) ||
|
| 4899 |
+
(t
|
| 4900 |
+
? ((e = (n = mi(s)).x - this._containerDiffX), (i = n.y - this._containerDiffY))
|
| 4901 |
+
: ((e = r._left), (i = r._top))),
|
| 4902 |
+
o.appendChild(s),
|
| 4903 |
+
r._setTranslate(e, i)),
|
| 4904 |
+
(this._isActive = !1),
|
| 4905 |
+
(this._container = null),
|
| 4906 |
+
(this._containerDiffX = 0),
|
| 4907 |
+
(this._containerDiffY = 0)
|
| 4908 |
+
}
|
| 4909 |
+
}),
|
| 4910 |
+
(Fi.prototype.destroy = function () {
|
| 4911 |
+
this._isDestroyed || (this.stop(!0), (this._item = null), (this._isDestroyed = !0))
|
| 4912 |
+
}),
|
| 4913 |
+
(Hi.prototype.show = function (t, e) {
|
| 4914 |
+
if (!this._isDestroyed) {
|
| 4915 |
+
var i = this._item,
|
| 4916 |
+
n = i._element,
|
| 4917 |
+
r = ce(e) ? e : null,
|
| 4918 |
+
s = i.getGrid()._settings
|
| 4919 |
+
this._isShowing || this._isHidden
|
| 4920 |
+
? !this._isShowing || t
|
| 4921 |
+
? (this._isShowing ||
|
| 4922 |
+
(i._emitter.burst(this._queue, !0, i),
|
| 4923 |
+
gi(n, s.itemHiddenClass),
|
| 4924 |
+
Be(n, s.itemVisibleClass),
|
| 4925 |
+
this._isHiding || (n.style.display = '')),
|
| 4926 |
+
r && i._emitter.on(this._queue, r),
|
| 4927 |
+
(this._isShowing = !0),
|
| 4928 |
+
(this._isHiding = this._isHidden = !1),
|
| 4929 |
+
this._startAnimation(!0, t, this._finishShow))
|
| 4930 |
+
: r && i._emitter.on(this._queue, r)
|
| 4931 |
+
: r && r(!1, i)
|
| 4932 |
+
}
|
| 4933 |
+
}),
|
| 4934 |
+
(Hi.prototype.hide = function (t, e) {
|
| 4935 |
+
if (!this._isDestroyed) {
|
| 4936 |
+
var i = this._item,
|
| 4937 |
+
n = i._element,
|
| 4938 |
+
r = ce(e) ? e : null,
|
| 4939 |
+
s = i.getGrid()._settings
|
| 4940 |
+
this._isHiding || !this._isHidden
|
| 4941 |
+
? !this._isHiding || t
|
| 4942 |
+
? (this._isHiding ||
|
| 4943 |
+
(i._emitter.burst(this._queue, !0, i),
|
| 4944 |
+
Be(n, s.itemHiddenClass),
|
| 4945 |
+
gi(n, s.itemVisibleClass)),
|
| 4946 |
+
r && i._emitter.on(this._queue, r),
|
| 4947 |
+
(this._isHidden = this._isHiding = !0),
|
| 4948 |
+
(this._isShowing = !1),
|
| 4949 |
+
this._startAnimation(!1, t, this._finishHide))
|
| 4950 |
+
: r && i._emitter.on(this._queue, r)
|
| 4951 |
+
: r && r(!1, i)
|
| 4952 |
+
}
|
| 4953 |
+
}),
|
| 4954 |
+
(Hi.prototype.stop = function (t) {
|
| 4955 |
+
if (!this._isDestroyed && (this._isHiding || this._isShowing)) {
|
| 4956 |
+
var e = this._item
|
| 4957 |
+
re(e._id), this._animation.stop(), t && e._emitter.burst(this._queue, !0, e)
|
| 4958 |
+
}
|
| 4959 |
+
}),
|
| 4960 |
+
(Hi.prototype.setStyles = function (t) {
|
| 4961 |
+
var e = this._childElement,
|
| 4962 |
+
i = this._currentStyleProps
|
| 4963 |
+
for (var n in (this._removeCurrentStyles(), t)) i.push(n), (e.style[n] = t[n])
|
| 4964 |
+
}),
|
| 4965 |
+
(Hi.prototype.destroy = function () {
|
| 4966 |
+
if (!this._isDestroyed) {
|
| 4967 |
+
var t = this._item,
|
| 4968 |
+
e = t._element,
|
| 4969 |
+
i = t.getGrid()._settings
|
| 4970 |
+
this.stop(!0),
|
| 4971 |
+
t._emitter.clear(this._queue),
|
| 4972 |
+
this._animation.destroy(),
|
| 4973 |
+
this._removeCurrentStyles(),
|
| 4974 |
+
gi(e, i.itemVisibleClass),
|
| 4975 |
+
gi(e, i.itemHiddenClass),
|
| 4976 |
+
(e.style.display = ''),
|
| 4977 |
+
(this._isHiding = this._isShowing = !1),
|
| 4978 |
+
(this._isDestroyed = this._isHidden = !0)
|
| 4979 |
+
}
|
| 4980 |
+
}),
|
| 4981 |
+
(Hi.prototype._startAnimation = function (t, e, i) {
|
| 4982 |
+
if (!this._isDestroyed) {
|
| 4983 |
+
var n,
|
| 4984 |
+
r = this._item,
|
| 4985 |
+
s = this._animation,
|
| 4986 |
+
o = this._childElement,
|
| 4987 |
+
a = r.getGrid()._settings,
|
| 4988 |
+
l = t ? a.visibleStyles : a.hiddenStyles,
|
| 4989 |
+
h = t ? a.showDuration : a.hideDuration,
|
| 4990 |
+
u = t ? a.showEasing : a.hideEasing,
|
| 4991 |
+
c = e || h <= 0
|
| 4992 |
+
if (l) {
|
| 4993 |
+
if ((re(r._id), c)) return Ri(o, l), s.stop(), void (i && i())
|
| 4994 |
+
var d, f, p
|
| 4995 |
+
s.isAnimating() && (s._animation.onfinish = null),
|
| 4996 |
+
(d = r._id),
|
| 4997 |
+
(f = function () {
|
| 4998 |
+
n = Ti(o, l)
|
| 4999 |
+
}),
|
| 5000 |
+
(p = function () {
|
| 5001 |
+
s.start(n, l, { duration: h, easing: u, onFinish: i })
|
| 5002 |
+
}),
|
| 5003 |
+
ie.add(0, Ht + d, f),
|
| 5004 |
+
ie.add(2, Yt + d, p)
|
| 5005 |
+
} else i && i()
|
| 5006 |
+
}
|
| 5007 |
+
}),
|
| 5008 |
+
(Hi.prototype._finishShow = function () {
|
| 5009 |
+
this._isHidden || ((this._isShowing = !1), this._item._emitter.burst(this._queue, !1, this._item))
|
| 5010 |
+
}),
|
| 5011 |
+
(Hi.prototype._finishHide = function () {
|
| 5012 |
+
if (this._isHidden) {
|
| 5013 |
+
var t = this._item
|
| 5014 |
+
;(this._isHiding = !1),
|
| 5015 |
+
t._layout.stop(!0, 0, 0),
|
| 5016 |
+
(t._element.style.display = 'none'),
|
| 5017 |
+
t._emitter.burst(this._queue, !1, t)
|
| 5018 |
+
}
|
| 5019 |
+
}),
|
| 5020 |
+
(Hi.prototype._removeCurrentStyles = function () {
|
| 5021 |
+
for (var t = this._childElement, e = this._currentStyleProps, i = 0; i < e.length; i++) t.style[e[i]] = ''
|
| 5022 |
+
e.length = 0
|
| 5023 |
+
})
|
| 5024 |
+
var Yi = 0
|
| 5025 |
+
function Bi() {
|
| 5026 |
+
return ++Yi
|
| 5027 |
+
}
|
| 5028 |
+
function zi(t, e, i) {
|
| 5029 |
+
var n = t._settings
|
| 5030 |
+
if (et) {
|
| 5031 |
+
if (et.has(e)) throw new Error('You can only create one Muuri Item per element!')
|
| 5032 |
+
et.set(e, this)
|
| 5033 |
+
}
|
| 5034 |
+
;(this._id = Bi()),
|
| 5035 |
+
(this._gridId = t._id),
|
| 5036 |
+
(this._element = e),
|
| 5037 |
+
(this._isDestroyed = !1),
|
| 5038 |
+
(this._left = 0),
|
| 5039 |
+
(this._top = 0),
|
| 5040 |
+
(this._width = 0),
|
| 5041 |
+
(this._height = 0),
|
| 5042 |
+
(this._marginLeft = 0),
|
| 5043 |
+
(this._marginRight = 0),
|
| 5044 |
+
(this._marginTop = 0),
|
| 5045 |
+
(this._marginBottom = 0),
|
| 5046 |
+
(this._tX = void 0),
|
| 5047 |
+
(this._tY = void 0),
|
| 5048 |
+
(this._sortData = null),
|
| 5049 |
+
(this._emitter = new bt()),
|
| 5050 |
+
e.parentNode !== t._element && t._element.appendChild(e),
|
| 5051 |
+
Be(e, n.itemClass),
|
| 5052 |
+
'boolean' != typeof i && (i = 'none' !== ge(e, 'display')),
|
| 5053 |
+
(this._isActive = i),
|
| 5054 |
+
(this._visibility = new Hi(this)),
|
| 5055 |
+
(this._layout = new Xi(this)),
|
| 5056 |
+
(this._migrate = new Fi(this)),
|
| 5057 |
+
(this._drag = n.dragEnabled ? new Ei(this) : null),
|
| 5058 |
+
(this._dragRelease = new ji(this)),
|
| 5059 |
+
(this._dragPlaceholder = new qi(this))
|
| 5060 |
+
}
|
| 5061 |
+
function Wi(t) {
|
| 5062 |
+
var e,
|
| 5063 |
+
i,
|
| 5064 |
+
n,
|
| 5065 |
+
r,
|
| 5066 |
+
s,
|
| 5067 |
+
o = 0.001,
|
| 5068 |
+
a = 0.5
|
| 5069 |
+
function l(t) {
|
| 5070 |
+
return ((((1e3 * t + 0.5) << 0) / 10) << 0) / 100
|
| 5071 |
+
}
|
| 5072 |
+
function h() {
|
| 5073 |
+
;(this.currentRects = []),
|
| 5074 |
+
(this.nextRects = []),
|
| 5075 |
+
(this.rectTarget = {}),
|
| 5076 |
+
(this.rectStore = []),
|
| 5077 |
+
(this.slotSizes = []),
|
| 5078 |
+
(this.rectId = 0),
|
| 5079 |
+
(this.slotIndex = -1),
|
| 5080 |
+
(this.slotData = { left: 0, top: 0, width: 0, height: 0 }),
|
| 5081 |
+
(this.sortRectsLeftTop = this.sortRectsLeftTop.bind(this)),
|
| 5082 |
+
(this.sortRectsTopLeft = this.sortRectsTopLeft.bind(this))
|
| 5083 |
+
}
|
| 5084 |
+
if (
|
| 5085 |
+
((h.prototype.computeLayout = function (t, e) {
|
| 5086 |
+
var i,
|
| 5087 |
+
n,
|
| 5088 |
+
r,
|
| 5089 |
+
s,
|
| 5090 |
+
o,
|
| 5091 |
+
a,
|
| 5092 |
+
h = t.items,
|
| 5093 |
+
u = t.slots,
|
| 5094 |
+
c = !!(1 & e),
|
| 5095 |
+
d = !!(2 & e),
|
| 5096 |
+
f = !!(4 & e),
|
| 5097 |
+
p = !!(8 & e),
|
| 5098 |
+
_ = !!(16 & e),
|
| 5099 |
+
m = 'number' == typeof h[0]
|
| 5100 |
+
if (!h.length) return t
|
| 5101 |
+
for (n = m ? 2 : 1, i = 0; i < h.length; i += n)
|
| 5102 |
+
m
|
| 5103 |
+
? ((s = h[i]), (o = h[i + 1]))
|
| 5104 |
+
: ((s = (r = h[i])._width + r._marginLeft + r._marginRight),
|
| 5105 |
+
(o = r._height + r._marginTop + r._marginBottom)),
|
| 5106 |
+
_ && ((s = l(s)), (o = l(o))),
|
| 5107 |
+
(a = this.computeNextSlot(t, s, o, c, d)),
|
| 5108 |
+
d
|
| 5109 |
+
? a.left + a.width > t.width && (t.width = a.left + a.width)
|
| 5110 |
+
: a.top + a.height > t.height && (t.height = a.top + a.height),
|
| 5111 |
+
(u[++this.slotIndex] = a.left),
|
| 5112 |
+
(u[++this.slotIndex] = a.top),
|
| 5113 |
+
(f || p) && this.slotSizes.push(a.width, a.height)
|
| 5114 |
+
if (f) for (i = 0; i < u.length; i += 2) u[i] = t.width - (u[i] + this.slotSizes[i])
|
| 5115 |
+
if (p) for (i = 1; i < u.length; i += 2) u[i] = t.height - (u[i] + this.slotSizes[i])
|
| 5116 |
+
return (
|
| 5117 |
+
(this.slotSizes.length = 0),
|
| 5118 |
+
(this.currentRects.length = 0),
|
| 5119 |
+
(this.nextRects.length = 0),
|
| 5120 |
+
(this.rectId = 0),
|
| 5121 |
+
(this.slotIndex = -1),
|
| 5122 |
+
t
|
| 5123 |
+
)
|
| 5124 |
+
}),
|
| 5125 |
+
(h.prototype.computeNextSlot = function (t, e, i, n, r) {
|
| 5126 |
+
var s,
|
| 5127 |
+
l,
|
| 5128 |
+
h,
|
| 5129 |
+
u,
|
| 5130 |
+
c,
|
| 5131 |
+
d = this.slotData,
|
| 5132 |
+
f = this.currentRects,
|
| 5133 |
+
p = this.nextRects,
|
| 5134 |
+
_ = !1
|
| 5135 |
+
for (p.length = 0, d.left = null, d.top = null, d.width = e, d.height = i, u = 0; u < f.length; u++)
|
| 5136 |
+
if ((l = f[u]) && ((s = this.getRect(l)), d.width <= s.width + o && d.height <= s.height + o)) {
|
| 5137 |
+
;(d.left = s.left), (d.top = s.top)
|
| 5138 |
+
break
|
| 5139 |
+
}
|
| 5140 |
+
if (
|
| 5141 |
+
(null === d.left &&
|
| 5142 |
+
(r ? ((d.left = t.width), (d.top = 0)) : ((d.left = 0), (d.top = t.height)), n || (_ = !0)),
|
| 5143 |
+
!r &&
|
| 5144 |
+
d.top + d.height > t.height + o &&
|
| 5145 |
+
(d.left > a && p.push(this.addRect(0, t.height, d.left, 1 / 0)),
|
| 5146 |
+
d.left + d.width < t.width - a &&
|
| 5147 |
+
p.push(this.addRect(d.left + d.width, t.height, t.width - d.left - d.width, 1 / 0)),
|
| 5148 |
+
(t.height = d.top + d.height)),
|
| 5149 |
+
r &&
|
| 5150 |
+
d.left + d.width > t.width + o &&
|
| 5151 |
+
(d.top > a && p.push(this.addRect(t.width, 0, 1 / 0, d.top)),
|
| 5152 |
+
d.top + d.height < t.height - a &&
|
| 5153 |
+
p.push(this.addRect(t.width, d.top + d.height, 1 / 0, t.height - d.top - d.height)),
|
| 5154 |
+
(t.width = d.left + d.width)),
|
| 5155 |
+
!_)
|
| 5156 |
+
)
|
| 5157 |
+
for (n && (u = 0); u < f.length; u++)
|
| 5158 |
+
if ((l = f[u]))
|
| 5159 |
+
for (s = this.getRect(l), h = this.splitRect(s, d), c = 0; c < h.length; c++)
|
| 5160 |
+
(l = h[c]),
|
| 5161 |
+
(s = this.getRect(l)),
|
| 5162 |
+
(r ? s.left + o < t.width - o : s.top + o < t.height - o) && p.push(l)
|
| 5163 |
+
return (
|
| 5164 |
+
p.length > 1 && this.purgeRects(p).sort(r ? this.sortRectsLeftTop : this.sortRectsTopLeft),
|
| 5165 |
+
(this.currentRects = p),
|
| 5166 |
+
(this.nextRects = f),
|
| 5167 |
+
d
|
| 5168 |
+
)
|
| 5169 |
+
}),
|
| 5170 |
+
(h.prototype.addRect = function (t, e, i, n) {
|
| 5171 |
+
var r = ++this.rectId
|
| 5172 |
+
return (
|
| 5173 |
+
(this.rectStore[r] = t || 0),
|
| 5174 |
+
(this.rectStore[++this.rectId] = e || 0),
|
| 5175 |
+
(this.rectStore[++this.rectId] = i || 0),
|
| 5176 |
+
(this.rectStore[++this.rectId] = n || 0),
|
| 5177 |
+
r
|
| 5178 |
+
)
|
| 5179 |
+
}),
|
| 5180 |
+
(h.prototype.getRect = function (t, e) {
|
| 5181 |
+
return (
|
| 5182 |
+
e || (e = this.rectTarget),
|
| 5183 |
+
(e.left = this.rectStore[t] || 0),
|
| 5184 |
+
(e.top = this.rectStore[++t] || 0),
|
| 5185 |
+
(e.width = this.rectStore[++t] || 0),
|
| 5186 |
+
(e.height = this.rectStore[++t] || 0),
|
| 5187 |
+
e
|
| 5188 |
+
)
|
| 5189 |
+
}),
|
| 5190 |
+
(h.prototype.splitRect =
|
| 5191 |
+
((e = []),
|
| 5192 |
+
(i = 0),
|
| 5193 |
+
(n = 0),
|
| 5194 |
+
function (t, r) {
|
| 5195 |
+
return (
|
| 5196 |
+
(e.length = 0),
|
| 5197 |
+
t.left + t.width <= r.left + o ||
|
| 5198 |
+
r.left + r.width <= t.left + o ||
|
| 5199 |
+
t.top + t.height <= r.top + o ||
|
| 5200 |
+
r.top + r.height <= t.top + o
|
| 5201 |
+
? (e.push(this.addRect(t.left, t.top, t.width, t.height)), e)
|
| 5202 |
+
: ((i = r.left - t.left) >= a && e.push(this.addRect(t.left, t.top, i, t.height)),
|
| 5203 |
+
(i = t.left + t.width - (r.left + r.width)) >= a &&
|
| 5204 |
+
e.push(this.addRect(r.left + r.width, t.top, i, t.height)),
|
| 5205 |
+
(n = r.top - t.top) >= a && e.push(this.addRect(t.left, t.top, t.width, n)),
|
| 5206 |
+
(n = t.top + t.height - (r.top + r.height)) >= a &&
|
| 5207 |
+
e.push(this.addRect(t.left, r.top + r.height, t.width, n)),
|
| 5208 |
+
e)
|
| 5209 |
+
)
|
| 5210 |
+
})),
|
| 5211 |
+
(h.prototype.isRectAWithinRectB = function (t, e) {
|
| 5212 |
+
return (
|
| 5213 |
+
t.left + o >= e.left &&
|
| 5214 |
+
t.top + o >= e.top &&
|
| 5215 |
+
t.left + t.width - o <= e.left + e.width &&
|
| 5216 |
+
t.top + t.height - o <= e.top + e.height
|
| 5217 |
+
)
|
| 5218 |
+
}),
|
| 5219 |
+
(h.prototype.purgeRects =
|
| 5220 |
+
((r = {}),
|
| 5221 |
+
(s = {}),
|
| 5222 |
+
function (t) {
|
| 5223 |
+
for (var e, i = t.length; i--; )
|
| 5224 |
+
if (((e = t.length), t[i]))
|
| 5225 |
+
for (this.getRect(t[i], r); e--; )
|
| 5226 |
+
if (t[e] && i !== e && (this.getRect(t[e], s), this.isRectAWithinRectB(r, s))) {
|
| 5227 |
+
t[i] = 0
|
| 5228 |
+
break
|
| 5229 |
+
}
|
| 5230 |
+
return t
|
| 5231 |
+
})),
|
| 5232 |
+
(h.prototype.sortRectsTopLeft = (function () {
|
| 5233 |
+
var t = {},
|
| 5234 |
+
e = {}
|
| 5235 |
+
return function (i, n) {
|
| 5236 |
+
return (
|
| 5237 |
+
this.getRect(i, t),
|
| 5238 |
+
this.getRect(n, e),
|
| 5239 |
+
t.top < e.top && t.top + o < e.top
|
| 5240 |
+
? -1
|
| 5241 |
+
: t.top > e.top && t.top - o > e.top
|
| 5242 |
+
? 1
|
| 5243 |
+
: t.left < e.left && t.left + o < e.left
|
| 5244 |
+
? -1
|
| 5245 |
+
: t.left > e.left && t.left - o > e.left
|
| 5246 |
+
? 1
|
| 5247 |
+
: 0
|
| 5248 |
+
)
|
| 5249 |
+
}
|
| 5250 |
+
})()),
|
| 5251 |
+
(h.prototype.sortRectsLeftTop = (function () {
|
| 5252 |
+
var t = {},
|
| 5253 |
+
e = {}
|
| 5254 |
+
return function (i, n) {
|
| 5255 |
+
return (
|
| 5256 |
+
this.getRect(i, t),
|
| 5257 |
+
this.getRect(n, e),
|
| 5258 |
+
t.left < e.left && t.left + o < e.left
|
| 5259 |
+
? -1
|
| 5260 |
+
: t.left > e.left && t.left - o < e.left
|
| 5261 |
+
? 1
|
| 5262 |
+
: t.top < e.top && t.top + o < e.top
|
| 5263 |
+
? -1
|
| 5264 |
+
: t.top > e.top && t.top - o > e.top
|
| 5265 |
+
? 1
|
| 5266 |
+
: 0
|
| 5267 |
+
)
|
| 5268 |
+
}
|
| 5269 |
+
})()),
|
| 5270 |
+
t)
|
| 5271 |
+
) {
|
| 5272 |
+
var u = new h()
|
| 5273 |
+
self.onmessage = function (t) {
|
| 5274 |
+
var e = new Float32Array(t.data),
|
| 5275 |
+
i = e.subarray(4, e.length),
|
| 5276 |
+
n = new Float32Array(i.length),
|
| 5277 |
+
r = e[3],
|
| 5278 |
+
s = { items: i, slots: n, width: e[1], height: e[2] }
|
| 5279 |
+
u.computeLayout(s, r),
|
| 5280 |
+
(e[1] = s.width),
|
| 5281 |
+
(e[2] = s.height),
|
| 5282 |
+
e.set(s.slots, 4),
|
| 5283 |
+
postMessage(e.buffer, [e.buffer])
|
| 5284 |
+
}
|
| 5285 |
+
}
|
| 5286 |
+
return h
|
| 5287 |
+
}
|
| 5288 |
+
;(zi.prototype.getGrid = function () {
|
| 5289 |
+
return tt[this._gridId]
|
| 5290 |
+
}),
|
| 5291 |
+
(zi.prototype.getElement = function () {
|
| 5292 |
+
return this._element
|
| 5293 |
+
}),
|
| 5294 |
+
(zi.prototype.getWidth = function () {
|
| 5295 |
+
return this._width
|
| 5296 |
+
}),
|
| 5297 |
+
(zi.prototype.getHeight = function () {
|
| 5298 |
+
return this._height
|
| 5299 |
+
}),
|
| 5300 |
+
(zi.prototype.getMargin = function () {
|
| 5301 |
+
return {
|
| 5302 |
+
left: this._marginLeft,
|
| 5303 |
+
right: this._marginRight,
|
| 5304 |
+
top: this._marginTop,
|
| 5305 |
+
bottom: this._marginBottom,
|
| 5306 |
+
}
|
| 5307 |
+
}),
|
| 5308 |
+
(zi.prototype.getPosition = function () {
|
| 5309 |
+
return { left: this._left, top: this._top }
|
| 5310 |
+
}),
|
| 5311 |
+
(zi.prototype.isActive = function () {
|
| 5312 |
+
return this._isActive
|
| 5313 |
+
}),
|
| 5314 |
+
(zi.prototype.isVisible = function () {
|
| 5315 |
+
return !!this._visibility && !this._visibility._isHidden
|
| 5316 |
+
}),
|
| 5317 |
+
(zi.prototype.isShowing = function () {
|
| 5318 |
+
return !(!this._visibility || !this._visibility._isShowing)
|
| 5319 |
+
}),
|
| 5320 |
+
(zi.prototype.isHiding = function () {
|
| 5321 |
+
return !(!this._visibility || !this._visibility._isHiding)
|
| 5322 |
+
}),
|
| 5323 |
+
(zi.prototype.isPositioning = function () {
|
| 5324 |
+
return !(!this._layout || !this._layout._isActive)
|
| 5325 |
+
}),
|
| 5326 |
+
(zi.prototype.isDragging = function () {
|
| 5327 |
+
return !(!this._drag || !this._drag._isActive)
|
| 5328 |
+
}),
|
| 5329 |
+
(zi.prototype.isReleasing = function () {
|
| 5330 |
+
return !(!this._dragRelease || !this._dragRelease._isActive)
|
| 5331 |
+
}),
|
| 5332 |
+
(zi.prototype.isDestroyed = function () {
|
| 5333 |
+
return this._isDestroyed
|
| 5334 |
+
}),
|
| 5335 |
+
(zi.prototype._refreshDimensions = function (t) {
|
| 5336 |
+
if (!(this._isDestroyed || (!0 !== t && this._visibility._isHidden))) {
|
| 5337 |
+
var e = this._element,
|
| 5338 |
+
i = this._dragPlaceholder,
|
| 5339 |
+
n = e.getBoundingClientRect()
|
| 5340 |
+
;(this._width = n.width),
|
| 5341 |
+
(this._height = n.height),
|
| 5342 |
+
(this._marginLeft = Math.max(0, ve(e, 'margin-left'))),
|
| 5343 |
+
(this._marginRight = Math.max(0, ve(e, 'margin-right'))),
|
| 5344 |
+
(this._marginTop = Math.max(0, ve(e, 'margin-top'))),
|
| 5345 |
+
(this._marginBottom = Math.max(0, ve(e, 'margin-bottom'))),
|
| 5346 |
+
i && i.updateDimensions()
|
| 5347 |
+
}
|
| 5348 |
+
}),
|
| 5349 |
+
(zi.prototype._refreshSortData = function () {
|
| 5350 |
+
if (!this._isDestroyed) {
|
| 5351 |
+
var t,
|
| 5352 |
+
e = (this._sortData = {}),
|
| 5353 |
+
i = this.getGrid()._settings.sortData
|
| 5354 |
+
for (t in i) e[t] = i[t](this, this._element)
|
| 5355 |
+
}
|
| 5356 |
+
}),
|
| 5357 |
+
(zi.prototype._addToLayout = function (t, e) {
|
| 5358 |
+
!0 !== this._isActive && ((this._isActive = !0), (this._left = t || 0), (this._top = e || 0))
|
| 5359 |
+
}),
|
| 5360 |
+
(zi.prototype._removeFromLayout = function () {
|
| 5361 |
+
!1 !== this._isActive && ((this._isActive = !1), (this._left = 0), (this._top = 0))
|
| 5362 |
+
}),
|
| 5363 |
+
(zi.prototype._canSkipLayout = function (t, e) {
|
| 5364 |
+
return (
|
| 5365 |
+
this._left === t &&
|
| 5366 |
+
this._top === e &&
|
| 5367 |
+
!this._migrate._isActive &&
|
| 5368 |
+
!this._layout._skipNextAnimation &&
|
| 5369 |
+
!this._dragRelease.isJustReleased()
|
| 5370 |
+
)
|
| 5371 |
+
}),
|
| 5372 |
+
(zi.prototype._setTranslate = function (t, e) {
|
| 5373 |
+
return (
|
| 5374 |
+
(this._tX !== t || this._tY !== e) &&
|
| 5375 |
+
((this._tX = t), (this._tY = e), (this._element.style[Ve] = Ni(t, e)), !0)
|
| 5376 |
+
)
|
| 5377 |
+
}),
|
| 5378 |
+
(zi.prototype._destroy = function (t) {
|
| 5379 |
+
if (!this._isDestroyed) {
|
| 5380 |
+
var e = this._element,
|
| 5381 |
+
i = this.getGrid()._settings
|
| 5382 |
+
this._dragPlaceholder.destroy(),
|
| 5383 |
+
this._dragRelease.destroy(),
|
| 5384 |
+
this._migrate.destroy(),
|
| 5385 |
+
this._layout.destroy(),
|
| 5386 |
+
this._visibility.destroy(),
|
| 5387 |
+
this._drag && this._drag.destroy(),
|
| 5388 |
+
this._emitter.destroy(),
|
| 5389 |
+
gi(e, i.itemClass),
|
| 5390 |
+
t && e.parentNode.removeChild(e),
|
| 5391 |
+
et && et.delete(e),
|
| 5392 |
+
(this._isActive = !1),
|
| 5393 |
+
(this._isDestroyed = !0)
|
| 5394 |
+
}
|
| 5395 |
+
})
|
| 5396 |
+
var $i = Wi(),
|
| 5397 |
+
Gi = null,
|
| 5398 |
+
Ui = []
|
| 5399 |
+
function Vi(t, e) {
|
| 5400 |
+
if (
|
| 5401 |
+
((this._options = 0),
|
| 5402 |
+
(this._processor = null),
|
| 5403 |
+
(this._layoutQueue = []),
|
| 5404 |
+
(this._layouts = {}),
|
| 5405 |
+
(this._layoutCallbacks = {}),
|
| 5406 |
+
(this._layoutWorkers = {}),
|
| 5407 |
+
(this._layoutWorkerData = {}),
|
| 5408 |
+
(this._workers = []),
|
| 5409 |
+
(this._onWorkerMessage = this._onWorkerMessage.bind(this)),
|
| 5410 |
+
this.setOptions(e),
|
| 5411 |
+
(t = 'number' == typeof t ? Math.max(0, t) : 0) && window.Worker && window.URL && window.Blob)
|
| 5412 |
+
)
|
| 5413 |
+
try {
|
| 5414 |
+
this._workers = (function (t, e) {
|
| 5415 |
+
var i = []
|
| 5416 |
+
if (t > 0) {
|
| 5417 |
+
Gi ||
|
| 5418 |
+
(Gi = URL.createObjectURL(
|
| 5419 |
+
new Blob(['(' + Wi.toString() + ')(true)'], { type: 'application/javascript' }),
|
| 5420 |
+
))
|
| 5421 |
+
for (var n, r = 0; r < t; r++)
|
| 5422 |
+
(n = new Worker(Gi)), e && (n.onmessage = e), i.push(n), Ui.push(n)
|
| 5423 |
+
}
|
| 5424 |
+
return i
|
| 5425 |
+
})(t, this._onWorkerMessage)
|
| 5426 |
+
} catch (t) {
|
| 5427 |
+
this._processor = new $i()
|
| 5428 |
+
}
|
| 5429 |
+
else this._processor = new $i()
|
| 5430 |
+
}
|
| 5431 |
+
;(Vi.prototype._sendToWorker = function () {
|
| 5432 |
+
if (this._layoutQueue.length && this._workers.length) {
|
| 5433 |
+
var t = this._layoutQueue.shift(),
|
| 5434 |
+
e = this._workers.pop(),
|
| 5435 |
+
i = this._layoutWorkerData[t]
|
| 5436 |
+
delete this._layoutWorkerData[t], (this._layoutWorkers[t] = e), e.postMessage(i.buffer, [i.buffer])
|
| 5437 |
+
}
|
| 5438 |
+
}),
|
| 5439 |
+
(Vi.prototype._onWorkerMessage = function (t) {
|
| 5440 |
+
var e = new Float32Array(t.data),
|
| 5441 |
+
i = e[0],
|
| 5442 |
+
n = this._layouts[i],
|
| 5443 |
+
r = this._layoutCallbacks[i],
|
| 5444 |
+
s = this._layoutWorkers[i]
|
| 5445 |
+
n && delete this._layoutCallbacks[i],
|
| 5446 |
+
r && delete this._layoutCallbacks[i],
|
| 5447 |
+
s && delete this._layoutWorkers[i],
|
| 5448 |
+
n &&
|
| 5449 |
+
r &&
|
| 5450 |
+
((n.width = e[1]),
|
| 5451 |
+
(n.height = e[2]),
|
| 5452 |
+
(n.slots = e.subarray(4, e.length)),
|
| 5453 |
+
this._finalizeLayout(n),
|
| 5454 |
+
r(n)),
|
| 5455 |
+
s && (this._workers.push(s), this._sendToWorker())
|
| 5456 |
+
}),
|
| 5457 |
+
(Vi.prototype._finalizeLayout = function (t) {
|
| 5458 |
+
var e = t._grid,
|
| 5459 |
+
i = 2 & t._settings,
|
| 5460 |
+
n = 'border-box' === e._boxSizing
|
| 5461 |
+
return (
|
| 5462 |
+
delete t._grid,
|
| 5463 |
+
delete t._settings,
|
| 5464 |
+
(t.styles = {}),
|
| 5465 |
+
i
|
| 5466 |
+
? (t.styles.width = (n ? t.width + e._borderLeft + e._borderRight : t.width) + 'px')
|
| 5467 |
+
: (t.styles.height = (n ? t.height + e._borderTop + e._borderBottom : t.height) + 'px'),
|
| 5468 |
+
t
|
| 5469 |
+
)
|
| 5470 |
+
}),
|
| 5471 |
+
(Vi.prototype.setOptions = function (t) {
|
| 5472 |
+
var e, i, n, r, s
|
| 5473 |
+
t &&
|
| 5474 |
+
((e = 'boolean' == typeof t.fillGaps ? (t.fillGaps ? 1 : 0) : 1 & this._options),
|
| 5475 |
+
(i = 'boolean' == typeof t.horizontal ? (t.horizontal ? 2 : 0) : 2 & this._options),
|
| 5476 |
+
(n = 'boolean' == typeof t.alignRight ? (t.alignRight ? 4 : 0) : 4 & this._options),
|
| 5477 |
+
(r = 'boolean' == typeof t.alignBottom ? (t.alignBottom ? 8 : 0) : 8 & this._options),
|
| 5478 |
+
(s = 'boolean' == typeof t.rounding ? (t.rounding ? 16 : 0) : 16 & this._options),
|
| 5479 |
+
(this._options = e | i | n | r | s))
|
| 5480 |
+
}),
|
| 5481 |
+
(Vi.prototype.createLayout = function (t, e, i, n, r, s) {
|
| 5482 |
+
if (this._layouts[e]) throw new Error('A layout with the provided id is currently being processed.')
|
| 5483 |
+
var o = 2 & this._options,
|
| 5484 |
+
a = {
|
| 5485 |
+
id: e,
|
| 5486 |
+
items: i,
|
| 5487 |
+
slots: null,
|
| 5488 |
+
width: o ? 0 : n,
|
| 5489 |
+
height: o ? r : 0,
|
| 5490 |
+
_grid: t,
|
| 5491 |
+
_settings: this._options,
|
| 5492 |
+
}
|
| 5493 |
+
if (!i.length) return (a.slots = []), this._finalizeLayout(a), void s(a)
|
| 5494 |
+
if (this._processor)
|
| 5495 |
+
return (
|
| 5496 |
+
(a.slots = window.Float32Array ? new Float32Array(2 * i.length) : new Array(2 * i.length)),
|
| 5497 |
+
this._processor.computeLayout(a, a._settings),
|
| 5498 |
+
this._finalizeLayout(a),
|
| 5499 |
+
void s(a)
|
| 5500 |
+
)
|
| 5501 |
+
var l,
|
| 5502 |
+
h,
|
| 5503 |
+
u,
|
| 5504 |
+
c = new Float32Array(4 + 2 * i.length)
|
| 5505 |
+
for (c[0] = e, c[1] = a.width, c[2] = a.height, c[3] = a._settings, l = 0, h = 3; l < i.length; l++)
|
| 5506 |
+
(u = i[l]),
|
| 5507 |
+
(c[++h] = u._width + u._marginLeft + u._marginRight),
|
| 5508 |
+
(c[++h] = u._height + u._marginTop + u._marginBottom)
|
| 5509 |
+
return (
|
| 5510 |
+
this._layoutQueue.push(e),
|
| 5511 |
+
(this._layouts[e] = a),
|
| 5512 |
+
(this._layoutCallbacks[e] = s),
|
| 5513 |
+
(this._layoutWorkerData[e] = c),
|
| 5514 |
+
this._sendToWorker(),
|
| 5515 |
+
this.cancelLayout.bind(this, e)
|
| 5516 |
+
)
|
| 5517 |
+
}),
|
| 5518 |
+
(Vi.prototype.cancelLayout = function (t) {
|
| 5519 |
+
if (
|
| 5520 |
+
this._layouts[t] &&
|
| 5521 |
+
(delete this._layouts[t], delete this._layoutCallbacks[t], this._layoutWorkerData[t])
|
| 5522 |
+
) {
|
| 5523 |
+
delete this._layoutWorkerData[t]
|
| 5524 |
+
var e = this._layoutQueue.indexOf(t)
|
| 5525 |
+
e > -1 && this._layoutQueue.splice(e, 1)
|
| 5526 |
+
}
|
| 5527 |
+
}),
|
| 5528 |
+
(Vi.prototype.destroy = function () {
|
| 5529 |
+
for (var t in this._layoutWorkers) this._workers.push(this._layoutWorkers[t])
|
| 5530 |
+
!(function (t) {
|
| 5531 |
+
for (var e, i, n = 0; n < t.length; n++)
|
| 5532 |
+
((e = t[n]).onmessage = null),
|
| 5533 |
+
(e.onerror = null),
|
| 5534 |
+
(e.onmessageerror = null),
|
| 5535 |
+
e.terminate(),
|
| 5536 |
+
(i = Ui.indexOf(e)) > -1 && Ui.splice(i, 1)
|
| 5537 |
+
Gi && !Ui.length && (URL.revokeObjectURL(Gi), (Gi = null))
|
| 5538 |
+
})(this._workers),
|
| 5539 |
+
(this._workers.length = 0),
|
| 5540 |
+
(this._layoutQueue.length = 0),
|
| 5541 |
+
(this._layouts = {}),
|
| 5542 |
+
(this._layoutCallbacks = {}),
|
| 5543 |
+
(this._layoutWorkers = {}),
|
| 5544 |
+
(this._layoutWorkerData = {})
|
| 5545 |
+
})
|
| 5546 |
+
var Ji = 0
|
| 5547 |
+
function Ki(t, e) {
|
| 5548 |
+
var i = ++Ji,
|
| 5549 |
+
n = 0,
|
| 5550 |
+
r = 0,
|
| 5551 |
+
s = !1,
|
| 5552 |
+
o = function (e) {
|
| 5553 |
+
s ||
|
| 5554 |
+
(r && (n -= e - r),
|
| 5555 |
+
(r = e),
|
| 5556 |
+
n > 0
|
| 5557 |
+
? (function (t, e) {
|
| 5558 |
+
ie.add(0, ee + t, e)
|
| 5559 |
+
})(i, o)
|
| 5560 |
+
: ((n = r = 0), t()))
|
| 5561 |
+
}
|
| 5562 |
+
return function (a) {
|
| 5563 |
+
if (!s) {
|
| 5564 |
+
if (!(e <= 0))
|
| 5565 |
+
return !0 === a
|
| 5566 |
+
? ((s = !0),
|
| 5567 |
+
(n = r = 0),
|
| 5568 |
+
(o = void 0),
|
| 5569 |
+
void (function (t) {
|
| 5570 |
+
ie.remove(0, ee + t)
|
| 5571 |
+
})(i))
|
| 5572 |
+
: void (n <= 0 ? ((n = e), o(0)) : (n = e))
|
| 5573 |
+
!0 !== a && t()
|
| 5574 |
+
}
|
| 5575 |
+
}
|
| 5576 |
+
}
|
| 5577 |
+
function Qi(t) {
|
| 5578 |
+
var e = Object.prototype.toString.call(t)
|
| 5579 |
+
return '[object HTMLCollection]' === e || '[object NodeList]' === e
|
| 5580 |
+
}
|
| 5581 |
+
var Zi = Object.prototype.toString
|
| 5582 |
+
function tn(t) {
|
| 5583 |
+
return 'object' == typeof t && '[object Object]' === Zi.call(t)
|
| 5584 |
+
}
|
| 5585 |
+
function en() {}
|
| 5586 |
+
var nn,
|
| 5587 |
+
rn,
|
| 5588 |
+
sn,
|
| 5589 |
+
on = 'number',
|
| 5590 |
+
an = 'string',
|
| 5591 |
+
ln = 'instant',
|
| 5592 |
+
hn = 0
|
| 5593 |
+
function un(t, e) {
|
| 5594 |
+
if (
|
| 5595 |
+
(typeof t === an && (t = document.querySelector(t)),
|
| 5596 |
+
!(t.getRootNode ? t.getRootNode({ composed: !0 }) === document : document.body.contains(t)) ||
|
| 5597 |
+
t === document.documentElement)
|
| 5598 |
+
)
|
| 5599 |
+
throw new Error('Container element must be an existing DOM element.')
|
| 5600 |
+
var i = (function (t, e) {
|
| 5601 |
+
var i = cn({}, t)
|
| 5602 |
+
e && (i = cn(i, e))
|
| 5603 |
+
e && e.visibleStyles
|
| 5604 |
+
? (i.visibleStyles = e.visibleStyles)
|
| 5605 |
+
: t && t.visibleStyles && (i.visibleStyles = t.visibleStyles)
|
| 5606 |
+
e && e.hiddenStyles
|
| 5607 |
+
? (i.hiddenStyles = e.hiddenStyles)
|
| 5608 |
+
: t && t.hiddenStyles && (i.hiddenStyles = t.hiddenStyles)
|
| 5609 |
+
return i
|
| 5610 |
+
})(un.defaultOptions, e)
|
| 5611 |
+
;(i.visibleStyles = dn(i.visibleStyles)),
|
| 5612 |
+
(i.hiddenStyles = dn(i.hiddenStyles)),
|
| 5613 |
+
ce(i.dragSort) || (i.dragSort = !!i.dragSort),
|
| 5614 |
+
(this._id = Bi()),
|
| 5615 |
+
(this._element = t),
|
| 5616 |
+
(this._settings = i),
|
| 5617 |
+
(this._isDestroyed = !1),
|
| 5618 |
+
(this._items = []),
|
| 5619 |
+
(this._layout = { id: 0, items: [], slots: [] }),
|
| 5620 |
+
(this._isLayoutFinished = !0),
|
| 5621 |
+
(this._nextLayoutData = null),
|
| 5622 |
+
(this._emitter = new bt()),
|
| 5623 |
+
(this._onLayoutDataReceived = this._onLayoutDataReceived.bind(this)),
|
| 5624 |
+
(tt[this._id] = this),
|
| 5625 |
+
Be(t, i.containerClass),
|
| 5626 |
+
(function (t, e) {
|
| 5627 |
+
typeof e !== on && (e = !0 === e ? 0 : -1)
|
| 5628 |
+
e >= 0 &&
|
| 5629 |
+
((t._resizeHandler = Ki(function () {
|
| 5630 |
+
t.refreshItems().layout()
|
| 5631 |
+
}, e)),
|
| 5632 |
+
window.addEventListener('resize', t._resizeHandler))
|
| 5633 |
+
})(this, i.layoutOnResize),
|
| 5634 |
+
this.add(
|
| 5635 |
+
(function (t, e) {
|
| 5636 |
+
if ('*' === e) return t.children
|
| 5637 |
+
if (typeof e === an) {
|
| 5638 |
+
for (var i = [], n = t.children, r = 0; r < n.length; r++) Ye(n[r], e) && i.push(n[r])
|
| 5639 |
+
return i
|
| 5640 |
+
}
|
| 5641 |
+
if (Array.isArray(e) || Qi(e)) return e
|
| 5642 |
+
return []
|
| 5643 |
+
})(t, i.items),
|
| 5644 |
+
{ layout: !1 },
|
| 5645 |
+
),
|
| 5646 |
+
i.layoutOnInit && this.layout(!0)
|
| 5647 |
+
}
|
| 5648 |
+
function cn(t, e) {
|
| 5649 |
+
var i,
|
| 5650 |
+
n,
|
| 5651 |
+
r,
|
| 5652 |
+
s = Object.keys(e),
|
| 5653 |
+
o = s.length
|
| 5654 |
+
for (r = 0; r < o; r++)
|
| 5655 |
+
(i = tn(e[(n = s[r])])),
|
| 5656 |
+
tn(t[n]) && i
|
| 5657 |
+
? (t[n] = cn(cn({}, t[n]), e[n]))
|
| 5658 |
+
: i
|
| 5659 |
+
? (t[n] = cn({}, e[n]))
|
| 5660 |
+
: Array.isArray(e[n])
|
| 5661 |
+
? (t[n] = e[n].slice(0))
|
| 5662 |
+
: (t[n] = e[n])
|
| 5663 |
+
return t
|
| 5664 |
+
}
|
| 5665 |
+
function dn(t) {
|
| 5666 |
+
var e,
|
| 5667 |
+
i,
|
| 5668 |
+
n = {},
|
| 5669 |
+
r = document.documentElement.style
|
| 5670 |
+
for (e in t) t[e] && (i = Tt(r, e)) && (n[i] = t[e])
|
| 5671 |
+
return n
|
| 5672 |
+
}
|
| 5673 |
+
function fn(t) {
|
| 5674 |
+
for (var e = {}, i = 0; i < t.length; i++) e[t[i]._id] = i
|
| 5675 |
+
return e
|
| 5676 |
+
}
|
| 5677 |
+
function pn(t, e, i) {
|
| 5678 |
+
return t[e._id] - t[i._id]
|
| 5679 |
+
}
|
| 5680 |
+
;(un.Item = zi),
|
| 5681 |
+
(un.ItemLayout = Xi),
|
| 5682 |
+
(un.ItemVisibility = Hi),
|
| 5683 |
+
(un.ItemMigrate = Fi),
|
| 5684 |
+
(un.ItemDrag = Ei),
|
| 5685 |
+
(un.ItemDragRelease = ji),
|
| 5686 |
+
(un.ItemDragPlaceholder = qi),
|
| 5687 |
+
(un.Emitter = bt),
|
| 5688 |
+
(un.Animator = Mi),
|
| 5689 |
+
(un.Dragger = It),
|
| 5690 |
+
(un.Packer = Vi),
|
| 5691 |
+
(un.AutoScroller = Xe),
|
| 5692 |
+
(un.defaultPacker = new Vi(2)),
|
| 5693 |
+
(un.defaultOptions = {
|
| 5694 |
+
items: '*',
|
| 5695 |
+
showDuration: 300,
|
| 5696 |
+
showEasing: 'ease',
|
| 5697 |
+
hideDuration: 300,
|
| 5698 |
+
hideEasing: 'ease',
|
| 5699 |
+
visibleStyles: { opacity: '1', transform: 'scale(1)' },
|
| 5700 |
+
hiddenStyles: { opacity: '0', transform: 'scale(0.5)' },
|
| 5701 |
+
layout: { fillGaps: !1, horizontal: !1, alignRight: !1, alignBottom: !1, rounding: !1 },
|
| 5702 |
+
layoutOnResize: 150,
|
| 5703 |
+
layoutOnInit: !0,
|
| 5704 |
+
layoutDuration: 300,
|
| 5705 |
+
layoutEasing: 'ease',
|
| 5706 |
+
sortData: null,
|
| 5707 |
+
dragEnabled: !1,
|
| 5708 |
+
dragContainer: null,
|
| 5709 |
+
dragHandle: null,
|
| 5710 |
+
dragStartPredicate: { distance: 0, delay: 0 },
|
| 5711 |
+
dragAxis: 'xy',
|
| 5712 |
+
dragSort: !0,
|
| 5713 |
+
dragSortHeuristics: { sortInterval: 100, minDragDistance: 10, minBounceBackAngle: 1 },
|
| 5714 |
+
dragSortPredicate: { threshold: 50, action: nt, migrateAction: nt },
|
| 5715 |
+
dragRelease: { duration: 300, easing: 'ease', useDragContainer: !0 },
|
| 5716 |
+
dragCssProps: {
|
| 5717 |
+
touchAction: 'none',
|
| 5718 |
+
userSelect: 'none',
|
| 5719 |
+
userDrag: 'none',
|
| 5720 |
+
tapHighlightColor: 'rgba(0, 0, 0, 0)',
|
| 5721 |
+
touchCallout: 'none',
|
| 5722 |
+
contentZooming: 'none',
|
| 5723 |
+
},
|
| 5724 |
+
dragPlaceholder: { enabled: !1, createElement: null, onCreate: null, onRemove: null },
|
| 5725 |
+
dragAutoScroll: {
|
| 5726 |
+
targets: [],
|
| 5727 |
+
handle: null,
|
| 5728 |
+
threshold: 50,
|
| 5729 |
+
safeZone: 0.2,
|
| 5730 |
+
speed: Xe.smoothSpeed(1e3, 2e3, 2500),
|
| 5731 |
+
sortDuringScroll: !0,
|
| 5732 |
+
smoothStop: !1,
|
| 5733 |
+
onStart: null,
|
| 5734 |
+
onStop: null,
|
| 5735 |
+
},
|
| 5736 |
+
containerClass: 'muuri',
|
| 5737 |
+
itemClass: 'muuri-item',
|
| 5738 |
+
itemVisibleClass: 'muuri-item-shown',
|
| 5739 |
+
itemHiddenClass: 'muuri-item-hidden',
|
| 5740 |
+
itemPositioningClass: 'muuri-item-positioning',
|
| 5741 |
+
itemDraggingClass: 'muuri-item-dragging',
|
| 5742 |
+
itemReleasingClass: 'muuri-item-releasing',
|
| 5743 |
+
itemPlaceholderClass: 'muuri-item-placeholder',
|
| 5744 |
+
}),
|
| 5745 |
+
(un.prototype.on = function (t, e) {
|
| 5746 |
+
return this._emitter.on(t, e), this
|
| 5747 |
+
}),
|
| 5748 |
+
(un.prototype.off = function (t, e) {
|
| 5749 |
+
return this._emitter.off(t, e), this
|
| 5750 |
+
}),
|
| 5751 |
+
(un.prototype.getElement = function () {
|
| 5752 |
+
return this._element
|
| 5753 |
+
}),
|
| 5754 |
+
(un.prototype.getItem = function (t) {
|
| 5755 |
+
if (this._isDestroyed || (!t && 0 !== t)) return null
|
| 5756 |
+
if (typeof t === on) return this._items[t > -1 ? t : this._items.length + t] || null
|
| 5757 |
+
if (t instanceof zi) return t._gridId === this._id ? t : null
|
| 5758 |
+
if (et) {
|
| 5759 |
+
var e = et.get(t)
|
| 5760 |
+
return e && e._gridId === this._id ? e : null
|
| 5761 |
+
}
|
| 5762 |
+
for (var i = 0; i < this._items.length; i++) if (this._items[i]._element === t) return this._items[i]
|
| 5763 |
+
return null
|
| 5764 |
+
}),
|
| 5765 |
+
(un.prototype.getItems = function (t) {
|
| 5766 |
+
if (this._isDestroyed || void 0 === t) return this._items.slice(0)
|
| 5767 |
+
var e,
|
| 5768 |
+
i,
|
| 5769 |
+
n = []
|
| 5770 |
+
if (Array.isArray(t) || Qi(t)) for (e = 0; e < t.length; e++) (i = this.getItem(t[e])) && n.push(i)
|
| 5771 |
+
else (i = this.getItem(t)) && n.push(i)
|
| 5772 |
+
return n
|
| 5773 |
+
}),
|
| 5774 |
+
(un.prototype.refreshItems = function (t, e) {
|
| 5775 |
+
if (this._isDestroyed) return this
|
| 5776 |
+
var i,
|
| 5777 |
+
n,
|
| 5778 |
+
r,
|
| 5779 |
+
s,
|
| 5780 |
+
o = t || this._items
|
| 5781 |
+
if (!0 === e)
|
| 5782 |
+
for (s = [], i = 0; i < o.length; i++)
|
| 5783 |
+
(n = o[i]).isVisible() ||
|
| 5784 |
+
n.isHiding() ||
|
| 5785 |
+
(((r = n.getElement().style).visibility = 'hidden'), (r.display = ''), s.push(r))
|
| 5786 |
+
for (i = 0; i < o.length; i++) o[i]._refreshDimensions(e)
|
| 5787 |
+
if (!0 === e) {
|
| 5788 |
+
for (i = 0; i < s.length; i++) ((r = s[i]).visibility = ''), (r.display = 'none')
|
| 5789 |
+
s.length = 0
|
| 5790 |
+
}
|
| 5791 |
+
return this
|
| 5792 |
+
}),
|
| 5793 |
+
(un.prototype.refreshSortData = function (t) {
|
| 5794 |
+
if (this._isDestroyed) return this
|
| 5795 |
+
for (var e = t || this._items, i = 0; i < e.length; i++) e[i]._refreshSortData()
|
| 5796 |
+
return this
|
| 5797 |
+
}),
|
| 5798 |
+
(un.prototype.synchronize = function () {
|
| 5799 |
+
if (this._isDestroyed) return this
|
| 5800 |
+
var t,
|
| 5801 |
+
e,
|
| 5802 |
+
i = this._items
|
| 5803 |
+
if (!i.length) return this
|
| 5804 |
+
for (var n = 0; n < i.length; n++)
|
| 5805 |
+
(e = i[n]._element).parentNode === this._element &&
|
| 5806 |
+
(t = t || document.createDocumentFragment()).appendChild(e)
|
| 5807 |
+
return t ? (this._element.appendChild(t), this._emit('synchronize'), this) : this
|
| 5808 |
+
}),
|
| 5809 |
+
(un.prototype.layout = function (t, e) {
|
| 5810 |
+
if (this._isDestroyed) return this
|
| 5811 |
+
var i = this._nextLayoutData
|
| 5812 |
+
i && ce(i.cancel) && i.cancel()
|
| 5813 |
+
var n = (hn = (hn % 16777216) + 1)
|
| 5814 |
+
this._nextLayoutData = { id: n, instant: t, onFinish: e, cancel: null }
|
| 5815 |
+
for (var r = this._items, s = [], o = 0; o < r.length; o++) r[o]._isActive && s.push(r[o])
|
| 5816 |
+
this._refreshDimensions()
|
| 5817 |
+
var a,
|
| 5818 |
+
l = this._width - this._borderLeft - this._borderRight,
|
| 5819 |
+
h = this._height - this._borderTop - this._borderBottom,
|
| 5820 |
+
u = this._settings.layout
|
| 5821 |
+
return (
|
| 5822 |
+
ce(u)
|
| 5823 |
+
? (a = u(this, n, s, l, h, this._onLayoutDataReceived))
|
| 5824 |
+
: (un.defaultPacker.setOptions(u),
|
| 5825 |
+
(a = un.defaultPacker.createLayout(this, n, s, l, h, this._onLayoutDataReceived))),
|
| 5826 |
+
ce(a) && this._nextLayoutData && this._nextLayoutData.id === n && (this._nextLayoutData.cancel = a),
|
| 5827 |
+
this
|
| 5828 |
+
)
|
| 5829 |
+
}),
|
| 5830 |
+
(un.prototype.add = function (t, e) {
|
| 5831 |
+
if (this._isDestroyed || !t) return []
|
| 5832 |
+
var i,
|
| 5833 |
+
n = Qi((i = t)) ? Array.prototype.slice.call(i) : Array.prototype.concat(i)
|
| 5834 |
+
if (!n.length) return n
|
| 5835 |
+
var r,
|
| 5836 |
+
s,
|
| 5837 |
+
o,
|
| 5838 |
+
a,
|
| 5839 |
+
l = e || {},
|
| 5840 |
+
h = l.layout ? l.layout : void 0 === l.layout,
|
| 5841 |
+
u = this._items,
|
| 5842 |
+
c = !1
|
| 5843 |
+
for (a = 0; a < n.length; a++)
|
| 5844 |
+
(s = n[a]).parentNode !== this._element && (r = r || document.createDocumentFragment()).appendChild(s)
|
| 5845 |
+
for (r && this._element.appendChild(r), a = 0; a < n.length; a++)
|
| 5846 |
+
(s = n[a]),
|
| 5847 |
+
(o = n[a] = new zi(this, s, l.active))._isActive && ((c = !0), (o._layout._skipNextAnimation = !0))
|
| 5848 |
+
for (a = 0; a < n.length; a++) (o = n[a])._refreshDimensions(), o._refreshSortData()
|
| 5849 |
+
return (
|
| 5850 |
+
We(u, n, l.index),
|
| 5851 |
+
this._hasListeners('add') && this._emit('add', n.slice(0)),
|
| 5852 |
+
c && h && this.layout(h === ln, ce(h) ? h : void 0),
|
| 5853 |
+
n
|
| 5854 |
+
)
|
| 5855 |
+
}),
|
| 5856 |
+
(un.prototype.remove = function (t, e) {
|
| 5857 |
+
if (this._isDestroyed || !t.length) return []
|
| 5858 |
+
var i,
|
| 5859 |
+
n,
|
| 5860 |
+
r,
|
| 5861 |
+
s = e || {},
|
| 5862 |
+
o = s.layout ? s.layout : void 0 === s.layout,
|
| 5863 |
+
a = !1,
|
| 5864 |
+
l = this.getItems(),
|
| 5865 |
+
h = [],
|
| 5866 |
+
u = []
|
| 5867 |
+
for (r = 0; r < t.length; r++)
|
| 5868 |
+
(n = t[r])._isDestroyed ||
|
| 5869 |
+
(-1 !== (i = this._items.indexOf(n)) &&
|
| 5870 |
+
(n._isActive && (a = !0),
|
| 5871 |
+
h.push(n),
|
| 5872 |
+
u.push(l.indexOf(n)),
|
| 5873 |
+
n._destroy(s.removeElements),
|
| 5874 |
+
this._items.splice(i, 1)))
|
| 5875 |
+
return (
|
| 5876 |
+
this._hasListeners(at) && this._emit(at, h.slice(0), u),
|
| 5877 |
+
a && o && this.layout(o === ln, ce(o) ? o : void 0),
|
| 5878 |
+
h
|
| 5879 |
+
)
|
| 5880 |
+
}),
|
| 5881 |
+
(un.prototype.show = function (t, e) {
|
| 5882 |
+
return !this._isDestroyed && t.length && this._setItemsVisibility(t, !0, e), this
|
| 5883 |
+
}),
|
| 5884 |
+
(un.prototype.hide = function (t, e) {
|
| 5885 |
+
return !this._isDestroyed && t.length && this._setItemsVisibility(t, !1, e), this
|
| 5886 |
+
}),
|
| 5887 |
+
(un.prototype.filter = function (t, e) {
|
| 5888 |
+
if (this._isDestroyed || !this._items.length) return this
|
| 5889 |
+
var i,
|
| 5890 |
+
n,
|
| 5891 |
+
r = [],
|
| 5892 |
+
s = [],
|
| 5893 |
+
o = typeof t === an,
|
| 5894 |
+
a = ce(t),
|
| 5895 |
+
l = e || {},
|
| 5896 |
+
h = !0 === l.instant,
|
| 5897 |
+
u = l.syncWithLayout,
|
| 5898 |
+
c = l.layout ? l.layout : void 0 === l.layout,
|
| 5899 |
+
d = ce(l.onFinish) ? l.onFinish : null,
|
| 5900 |
+
f = -1,
|
| 5901 |
+
p = en
|
| 5902 |
+
if (
|
| 5903 |
+
(d &&
|
| 5904 |
+
(p = function () {
|
| 5905 |
+
++f && d(r.slice(0), s.slice(0))
|
| 5906 |
+
}),
|
| 5907 |
+
a || o)
|
| 5908 |
+
)
|
| 5909 |
+
for (n = 0; n < this._items.length; n++)
|
| 5910 |
+
(i = this._items[n]), (a ? t(i) : Ye(i._element, t)) ? r.push(i) : s.push(i)
|
| 5911 |
+
return (
|
| 5912 |
+
r.length ? this.show(r, { instant: h, syncWithLayout: u, onFinish: p, layout: !1 }) : p(),
|
| 5913 |
+
s.length ? this.hide(s, { instant: h, syncWithLayout: u, onFinish: p, layout: !1 }) : p(),
|
| 5914 |
+
(r.length || s.length) &&
|
| 5915 |
+
(this._hasListeners(ht) && this._emit(ht, r.slice(0), s.slice(0)),
|
| 5916 |
+
c && this.layout(c === ln, ce(c) ? c : void 0)),
|
| 5917 |
+
this
|
| 5918 |
+
)
|
| 5919 |
+
}),
|
| 5920 |
+
(un.prototype.sort = (function () {
|
| 5921 |
+
var t, e, i, n
|
| 5922 |
+
function r(r, s) {
|
| 5923 |
+
for (var o, a, l, h, u = 0, c = 0; c < t.length; c++)
|
| 5924 |
+
if (
|
| 5925 |
+
((o = t[c][0]),
|
| 5926 |
+
(a = t[c][1]),
|
| 5927 |
+
(l = (r._sortData ? r : r._refreshSortData())._sortData[o]),
|
| 5928 |
+
(h = (s._sortData ? s : s._refreshSortData())._sortData[o]),
|
| 5929 |
+
(u = 'desc' === a || (!a && e) ? (h < l ? -1 : h > l ? 1 : 0) : l < h ? -1 : l > h ? 1 : 0))
|
| 5930 |
+
)
|
| 5931 |
+
return u
|
| 5932 |
+
return u || (n || (n = fn(i)), (u = e ? pn(n, s, r) : pn(n, r, s))), u
|
| 5933 |
+
}
|
| 5934 |
+
function s(r, s) {
|
| 5935 |
+
var o = e ? -t(r, s) : t(r, s)
|
| 5936 |
+
return o || (n || (n = fn(i)), (o = e ? pn(n, s, r) : pn(n, r, s))), o
|
| 5937 |
+
}
|
| 5938 |
+
return function (o, a) {
|
| 5939 |
+
if (this._isDestroyed || this._items.length < 2) return this
|
| 5940 |
+
var l = this._items,
|
| 5941 |
+
h = a || {},
|
| 5942 |
+
u = h.layout ? h.layout : void 0 === h.layout
|
| 5943 |
+
if (((e = !!h.descending), (i = l.slice(0)), (n = null), ce(o))) (t = o), l.sort(s)
|
| 5944 |
+
else if (typeof o === an)
|
| 5945 |
+
(t = o
|
| 5946 |
+
.trim()
|
| 5947 |
+
.split(' ')
|
| 5948 |
+
.filter(function (t) {
|
| 5949 |
+
return t
|
| 5950 |
+
})
|
| 5951 |
+
.map(function (t) {
|
| 5952 |
+
return t.split(':')
|
| 5953 |
+
})),
|
| 5954 |
+
l.sort(r)
|
| 5955 |
+
else {
|
| 5956 |
+
if (!Array.isArray(o))
|
| 5957 |
+
throw ((t = e = i = n = null), new Error('Invalid comparer argument provided.'))
|
| 5958 |
+
;(l.length = 0), l.push.apply(l, o)
|
| 5959 |
+
}
|
| 5960 |
+
return (
|
| 5961 |
+
this._hasListeners(ut) && this._emit(ut, l.slice(0), i),
|
| 5962 |
+
u && this.layout(u === ln, ce(u) ? u : void 0),
|
| 5963 |
+
(t = e = i = n = null),
|
| 5964 |
+
this
|
| 5965 |
+
)
|
| 5966 |
+
}
|
| 5967 |
+
})()),
|
| 5968 |
+
(un.prototype.move = function (t, e, i) {
|
| 5969 |
+
if (this._isDestroyed || this._items.length < 2) return this
|
| 5970 |
+
var n,
|
| 5971 |
+
r,
|
| 5972 |
+
s = this._items,
|
| 5973 |
+
o = i || {},
|
| 5974 |
+
a = o.layout ? o.layout : void 0 === o.layout,
|
| 5975 |
+
l = o.action === it,
|
| 5976 |
+
h = l ? it : nt,
|
| 5977 |
+
u = this.getItem(t),
|
| 5978 |
+
c = this.getItem(e)
|
| 5979 |
+
return (
|
| 5980 |
+
u &&
|
| 5981 |
+
c &&
|
| 5982 |
+
u !== c &&
|
| 5983 |
+
((n = s.indexOf(u)),
|
| 5984 |
+
(r = s.indexOf(c)),
|
| 5985 |
+
l ? Ue(s, n, r) : Ge(s, n, r),
|
| 5986 |
+
this._hasListeners(ct) && this._emit(ct, { item: u, fromIndex: n, toIndex: r, action: h }),
|
| 5987 |
+
a && this.layout(a === ln, ce(a) ? a : void 0)),
|
| 5988 |
+
this
|
| 5989 |
+
)
|
| 5990 |
+
}),
|
| 5991 |
+
(un.prototype.send = function (t, e, i, n) {
|
| 5992 |
+
if (this._isDestroyed || e._isDestroyed || this === e) return this
|
| 5993 |
+
if (!(t = this.getItem(t))) return this
|
| 5994 |
+
var r = n || {},
|
| 5995 |
+
s = r.appendTo || document.body,
|
| 5996 |
+
o = r.layoutSender ? r.layoutSender : void 0 === r.layoutSender,
|
| 5997 |
+
a = r.layoutReceiver ? r.layoutReceiver : void 0 === r.layoutReceiver
|
| 5998 |
+
return (
|
| 5999 |
+
t._migrate.start(e, i, s),
|
| 6000 |
+
t._migrate._isActive &&
|
| 6001 |
+
t._isActive &&
|
| 6002 |
+
(o && this.layout(o === ln, ce(o) ? o : void 0), a && e.layout(a === ln, ce(a) ? a : void 0)),
|
| 6003 |
+
this
|
| 6004 |
+
)
|
| 6005 |
+
}),
|
| 6006 |
+
(un.prototype.destroy = function (t) {
|
| 6007 |
+
if (this._isDestroyed) return this
|
| 6008 |
+
var e,
|
| 6009 |
+
i,
|
| 6010 |
+
n,
|
| 6011 |
+
r = this._element,
|
| 6012 |
+
s = this._items.slice(0),
|
| 6013 |
+
o = (this._layout && this._layout.styles) || {}
|
| 6014 |
+
for (
|
| 6015 |
+
(n = this)._resizeHandler &&
|
| 6016 |
+
(n._resizeHandler(!0),
|
| 6017 |
+
window.removeEventListener('resize', n._resizeHandler),
|
| 6018 |
+
(n._resizeHandler = null)),
|
| 6019 |
+
e = 0;
|
| 6020 |
+
e < s.length;
|
| 6021 |
+
e++
|
| 6022 |
+
)
|
| 6023 |
+
s[e]._destroy(t)
|
| 6024 |
+
for (i in ((this._items.length = 0), gi(r, this._settings.containerClass), o)) r.style[i] = ''
|
| 6025 |
+
return this._emit('destroy'), this._emitter.destroy(), delete tt[this._id], (this._isDestroyed = !0), this
|
| 6026 |
+
}),
|
| 6027 |
+
(un.prototype._emit = function () {
|
| 6028 |
+
this._isDestroyed || this._emitter.emit.apply(this._emitter, arguments)
|
| 6029 |
+
}),
|
| 6030 |
+
(un.prototype._hasListeners = function (t) {
|
| 6031 |
+
return !this._isDestroyed && this._emitter.countListeners(t) > 0
|
| 6032 |
+
}),
|
| 6033 |
+
(un.prototype._updateBoundingRect = function () {
|
| 6034 |
+
var t = this._element.getBoundingClientRect()
|
| 6035 |
+
;(this._width = t.width),
|
| 6036 |
+
(this._height = t.height),
|
| 6037 |
+
(this._left = t.left),
|
| 6038 |
+
(this._top = t.top),
|
| 6039 |
+
(this._right = t.right),
|
| 6040 |
+
(this._bottom = t.bottom)
|
| 6041 |
+
}),
|
| 6042 |
+
(un.prototype._updateBorders = function (t, e, i, n) {
|
| 6043 |
+
var r = this._element
|
| 6044 |
+
t && (this._borderLeft = ve(r, 'border-left-width')),
|
| 6045 |
+
e && (this._borderRight = ve(r, 'border-right-width')),
|
| 6046 |
+
i && (this._borderTop = ve(r, 'border-top-width')),
|
| 6047 |
+
n && (this._borderBottom = ve(r, 'border-bottom-width'))
|
| 6048 |
+
}),
|
| 6049 |
+
(un.prototype._refreshDimensions = function () {
|
| 6050 |
+
this._updateBoundingRect(),
|
| 6051 |
+
this._updateBorders(1, 1, 1, 1),
|
| 6052 |
+
(this._boxSizing = ge(this._element, 'box-sizing'))
|
| 6053 |
+
}),
|
| 6054 |
+
(un.prototype._onLayoutDataReceived =
|
| 6055 |
+
((nn = []),
|
| 6056 |
+
function (t) {
|
| 6057 |
+
if (!this._isDestroyed && this._nextLayoutData && this._nextLayoutData.id === t.id) {
|
| 6058 |
+
var e,
|
| 6059 |
+
i,
|
| 6060 |
+
n,
|
| 6061 |
+
r,
|
| 6062 |
+
s = this,
|
| 6063 |
+
o = this._nextLayoutData.instant,
|
| 6064 |
+
a = this._nextLayoutData.onFinish,
|
| 6065 |
+
l = t.items.length,
|
| 6066 |
+
h = l
|
| 6067 |
+
for (
|
| 6068 |
+
this._nextLayoutData = null,
|
| 6069 |
+
!this._isLayoutFinished &&
|
| 6070 |
+
this._hasListeners(ot) &&
|
| 6071 |
+
this._emit(ot, this._layout.items.slice(0)),
|
| 6072 |
+
this._layout = t,
|
| 6073 |
+
nn.length = 0,
|
| 6074 |
+
r = 0;
|
| 6075 |
+
r < l;
|
| 6076 |
+
r++
|
| 6077 |
+
)
|
| 6078 |
+
(e = t.items[r])
|
| 6079 |
+
? ((i = t.slots[2 * r]),
|
| 6080 |
+
(n = t.slots[2 * r + 1]),
|
| 6081 |
+
e._canSkipLayout(i, n)
|
| 6082 |
+
? --h
|
| 6083 |
+
: ((e._left = i), (e._top = n), e.isActive() && !e.isDragging() ? nn.push(e) : --h))
|
| 6084 |
+
: --h
|
| 6085 |
+
if (
|
| 6086 |
+
(t.styles && Ri(this._element, t.styles),
|
| 6087 |
+
!this._hasListeners(rt) ||
|
| 6088 |
+
(this._emit(rt, t.items.slice(0), !0 === o), this._layout.id === t.id))
|
| 6089 |
+
) {
|
| 6090 |
+
var u = function () {
|
| 6091 |
+
if (!(--h > 0)) {
|
| 6092 |
+
var e = s._layout.id !== t.id,
|
| 6093 |
+
i = ce(o) ? o : a
|
| 6094 |
+
e || (s._isLayoutFinished = !0),
|
| 6095 |
+
ce(i) && i(t.items.slice(0), e),
|
| 6096 |
+
!e && s._hasListeners(st) && s._emit(st, t.items.slice(0))
|
| 6097 |
+
}
|
| 6098 |
+
}
|
| 6099 |
+
if (!nn.length) return u(), this
|
| 6100 |
+
for (this._isLayoutFinished = !1, r = 0; r < nn.length && this._layout.id === t.id; r++)
|
| 6101 |
+
nn[r]._layout.start(!0 === o, u)
|
| 6102 |
+
return this._layout.id === t.id && (nn.length = 0), this
|
| 6103 |
+
}
|
| 6104 |
+
}
|
| 6105 |
+
})),
|
| 6106 |
+
(un.prototype._setItemsVisibility = function (t, e, i) {
|
| 6107 |
+
var n,
|
| 6108 |
+
r,
|
| 6109 |
+
s = this,
|
| 6110 |
+
o = t.slice(0),
|
| 6111 |
+
a = i || {},
|
| 6112 |
+
l = !0 === a.instant,
|
| 6113 |
+
h = a.onFinish,
|
| 6114 |
+
u = a.layout ? a.layout : void 0 === a.layout,
|
| 6115 |
+
c = o.length,
|
| 6116 |
+
d = e ? 'showStart' : lt,
|
| 6117 |
+
f = e ? 'showEnd' : 'hideEnd',
|
| 6118 |
+
p = e ? 'show' : 'hide',
|
| 6119 |
+
_ = !1,
|
| 6120 |
+
m = [],
|
| 6121 |
+
g = []
|
| 6122 |
+
if (c) {
|
| 6123 |
+
for (r = 0; r < o.length; r++)
|
| 6124 |
+
(n = o[r]),
|
| 6125 |
+
((e && !n._isActive) || (!e && n._isActive)) && (_ = !0),
|
| 6126 |
+
(n._layout._skipNextAnimation = !(!e || n._isActive)),
|
| 6127 |
+
e && n._visibility._isHidden && g.push(n),
|
| 6128 |
+
e ? n._addToLayout() : n._removeFromLayout()
|
| 6129 |
+
g.length && (this.refreshItems(g, !0), (g.length = 0)),
|
| 6130 |
+
_ && !1 !== a.syncWithLayout ? this.on(rt, v) : v(),
|
| 6131 |
+
_ && u && this.layout(u === ln, ce(u) ? u : void 0)
|
| 6132 |
+
} else ce(h) && h(o)
|
| 6133 |
+
function v() {
|
| 6134 |
+
for (
|
| 6135 |
+
_ && !1 !== a.syncWithLayout && s.off(rt, v), s._hasListeners(d) && s._emit(d, o.slice(0)), r = 0;
|
| 6136 |
+
r < o.length;
|
| 6137 |
+
r++
|
| 6138 |
+
)
|
| 6139 |
+
o[r]._gridId === s._id
|
| 6140 |
+
? o[r]._visibility[p](l, function (t, e) {
|
| 6141 |
+
t || m.push(e),
|
| 6142 |
+
--c < 1 && (ce(h) && h(m.slice(0)), s._hasListeners(f) && s._emit(f, m.slice(0)))
|
| 6143 |
+
})
|
| 6144 |
+
: --c < 1 && (ce(h) && h(m.slice(0)), s._hasListeners(f) && s._emit(f, m.slice(0)))
|
| 6145 |
+
}
|
| 6146 |
+
}),
|
| 6147 |
+
(sn = {}),
|
| 6148 |
+
(function (t, e) {
|
| 6149 |
+
function i() {
|
| 6150 |
+
;(this._delay = 0),
|
| 6151 |
+
(this._endDelay = 0),
|
| 6152 |
+
(this._fill = 'none'),
|
| 6153 |
+
(this._iterationStart = 0),
|
| 6154 |
+
(this._iterations = 1),
|
| 6155 |
+
(this._duration = 0),
|
| 6156 |
+
(this._playbackRate = 1),
|
| 6157 |
+
(this._direction = 'normal'),
|
| 6158 |
+
(this._easing = 'linear'),
|
| 6159 |
+
(this._easingFunction = d)
|
| 6160 |
+
}
|
| 6161 |
+
function n() {
|
| 6162 |
+
return t.isDeprecated(
|
| 6163 |
+
'Invalid timing inputs',
|
| 6164 |
+
'2016-03-02',
|
| 6165 |
+
'TypeError exceptions will be thrown instead.',
|
| 6166 |
+
!0,
|
| 6167 |
+
)
|
| 6168 |
+
}
|
| 6169 |
+
function r(e, n, r) {
|
| 6170 |
+
var s = new i()
|
| 6171 |
+
return (
|
| 6172 |
+
n && ((s.fill = 'both'), (s.duration = 'auto')),
|
| 6173 |
+
'number' != typeof e || isNaN(e)
|
| 6174 |
+
? void 0 !== e &&
|
| 6175 |
+
Object.getOwnPropertyNames(e).forEach(function (i) {
|
| 6176 |
+
if ('auto' != e[i]) {
|
| 6177 |
+
if (
|
| 6178 |
+
('number' == typeof s[i] || 'duration' == i) &&
|
| 6179 |
+
('number' != typeof e[i] || isNaN(e[i]))
|
| 6180 |
+
)
|
| 6181 |
+
return
|
| 6182 |
+
if ('fill' == i && -1 == u.indexOf(e[i])) return
|
| 6183 |
+
if ('direction' == i && -1 == c.indexOf(e[i])) return
|
| 6184 |
+
if (
|
| 6185 |
+
'playbackRate' == i &&
|
| 6186 |
+
1 !== e[i] &&
|
| 6187 |
+
t.isDeprecated(
|
| 6188 |
+
'AnimationEffectTiming.playbackRate',
|
| 6189 |
+
'2014-11-28',
|
| 6190 |
+
'Use Animation.playbackRate instead.',
|
| 6191 |
+
)
|
| 6192 |
+
)
|
| 6193 |
+
return
|
| 6194 |
+
s[i] = e[i]
|
| 6195 |
+
}
|
| 6196 |
+
})
|
| 6197 |
+
: (s.duration = e),
|
| 6198 |
+
s
|
| 6199 |
+
)
|
| 6200 |
+
}
|
| 6201 |
+
function s(t, e, i, n) {
|
| 6202 |
+
return t < 0 || t > 1 || i < 0 || i > 1
|
| 6203 |
+
? d
|
| 6204 |
+
: function (r) {
|
| 6205 |
+
function s(t, e, i) {
|
| 6206 |
+
return 3 * t * (1 - i) * (1 - i) * i + 3 * e * (1 - i) * i * i + i * i * i
|
| 6207 |
+
}
|
| 6208 |
+
if (r <= 0) {
|
| 6209 |
+
var o = 0
|
| 6210 |
+
return t > 0 ? (o = e / t) : !e && i > 0 && (o = n / i), o * r
|
| 6211 |
+
}
|
| 6212 |
+
if (r >= 1) {
|
| 6213 |
+
var a = 0
|
| 6214 |
+
return (
|
| 6215 |
+
i < 1 ? (a = (n - 1) / (i - 1)) : 1 == i && t < 1 && (a = (e - 1) / (t - 1)),
|
| 6216 |
+
1 + a * (r - 1)
|
| 6217 |
+
)
|
| 6218 |
+
}
|
| 6219 |
+
for (var l = 0, h = 1; l < h; ) {
|
| 6220 |
+
var u = (l + h) / 2,
|
| 6221 |
+
c = s(t, i, u)
|
| 6222 |
+
if (Math.abs(r - c) < 1e-5) return s(e, n, u)
|
| 6223 |
+
c < r ? (l = u) : (h = u)
|
| 6224 |
+
}
|
| 6225 |
+
return s(e, n, u)
|
| 6226 |
+
}
|
| 6227 |
+
}
|
| 6228 |
+
function o(t, e) {
|
| 6229 |
+
return function (i) {
|
| 6230 |
+
if (i >= 1) return 1
|
| 6231 |
+
var n = 1 / t
|
| 6232 |
+
return (i += e * n) - (i % n)
|
| 6233 |
+
}
|
| 6234 |
+
}
|
| 6235 |
+
function a(t) {
|
| 6236 |
+
g || (g = document.createElement('div').style),
|
| 6237 |
+
(g.animationTimingFunction = ''),
|
| 6238 |
+
(g.animationTimingFunction = t)
|
| 6239 |
+
var e = g.animationTimingFunction
|
| 6240 |
+
if ('' == e && n()) throw new TypeError(t + ' is not a valid value for easing')
|
| 6241 |
+
return e
|
| 6242 |
+
}
|
| 6243 |
+
function l(t) {
|
| 6244 |
+
if ('linear' == t) return d
|
| 6245 |
+
var e = y.exec(t)
|
| 6246 |
+
if (e) return s.apply(this, e.slice(1).map(Number))
|
| 6247 |
+
var i = b.exec(t)
|
| 6248 |
+
if (i) return o(Number(i[1]), _)
|
| 6249 |
+
var n = w.exec(t)
|
| 6250 |
+
return n ? o(Number(n[1]), { start: f, middle: p, end: _ }[n[2]]) : m[t] || d
|
| 6251 |
+
}
|
| 6252 |
+
function h(t, e, i) {
|
| 6253 |
+
if (null == e) return x
|
| 6254 |
+
var n = i.delay + t + i.endDelay
|
| 6255 |
+
return e < Math.min(i.delay, n) ? S : e >= Math.min(i.delay + t, n) ? E : T
|
| 6256 |
+
}
|
| 6257 |
+
var u = 'backwards|forwards|both|none'.split('|'),
|
| 6258 |
+
c = 'reverse|alternate|alternate-reverse'.split('|'),
|
| 6259 |
+
d = function (t) {
|
| 6260 |
+
return t
|
| 6261 |
+
}
|
| 6262 |
+
i.prototype = {
|
| 6263 |
+
_setMember: function (e, i) {
|
| 6264 |
+
;(this['_' + e] = i),
|
| 6265 |
+
this._effect &&
|
| 6266 |
+
((this._effect._timingInput[e] = i),
|
| 6267 |
+
(this._effect._timing = t.normalizeTimingInput(this._effect._timingInput)),
|
| 6268 |
+
(this._effect.activeDuration = t.calculateActiveDuration(this._effect._timing)),
|
| 6269 |
+
this._effect._animation && this._effect._animation._rebuildUnderlyingAnimation())
|
| 6270 |
+
},
|
| 6271 |
+
get playbackRate() {
|
| 6272 |
+
return this._playbackRate
|
| 6273 |
+
},
|
| 6274 |
+
set delay(t) {
|
| 6275 |
+
this._setMember('delay', t)
|
| 6276 |
+
},
|
| 6277 |
+
get delay() {
|
| 6278 |
+
return this._delay
|
| 6279 |
+
},
|
| 6280 |
+
set endDelay(t) {
|
| 6281 |
+
this._setMember('endDelay', t)
|
| 6282 |
+
},
|
| 6283 |
+
get endDelay() {
|
| 6284 |
+
return this._endDelay
|
| 6285 |
+
},
|
| 6286 |
+
set fill(t) {
|
| 6287 |
+
this._setMember('fill', t)
|
| 6288 |
+
},
|
| 6289 |
+
get fill() {
|
| 6290 |
+
return this._fill
|
| 6291 |
+
},
|
| 6292 |
+
set iterationStart(t) {
|
| 6293 |
+
if ((isNaN(t) || t < 0) && n())
|
| 6294 |
+
throw new TypeError('iterationStart must be a non-negative number, received: ' + t)
|
| 6295 |
+
this._setMember('iterationStart', t)
|
| 6296 |
+
},
|
| 6297 |
+
get iterationStart() {
|
| 6298 |
+
return this._iterationStart
|
| 6299 |
+
},
|
| 6300 |
+
set duration(t) {
|
| 6301 |
+
if ('auto' != t && (isNaN(t) || t < 0) && n())
|
| 6302 |
+
throw new TypeError('duration must be non-negative or auto, received: ' + t)
|
| 6303 |
+
this._setMember('duration', t)
|
| 6304 |
+
},
|
| 6305 |
+
get duration() {
|
| 6306 |
+
return this._duration
|
| 6307 |
+
},
|
| 6308 |
+
set direction(t) {
|
| 6309 |
+
this._setMember('direction', t)
|
| 6310 |
+
},
|
| 6311 |
+
get direction() {
|
| 6312 |
+
return this._direction
|
| 6313 |
+
},
|
| 6314 |
+
set easing(t) {
|
| 6315 |
+
;(this._easingFunction = l(a(t))), this._setMember('easing', t)
|
| 6316 |
+
},
|
| 6317 |
+
get easing() {
|
| 6318 |
+
return this._easing
|
| 6319 |
+
},
|
| 6320 |
+
set iterations(t) {
|
| 6321 |
+
if ((isNaN(t) || t < 0) && n())
|
| 6322 |
+
throw new TypeError('iterations must be non-negative, received: ' + t)
|
| 6323 |
+
this._setMember('iterations', t)
|
| 6324 |
+
},
|
| 6325 |
+
get iterations() {
|
| 6326 |
+
return this._iterations
|
| 6327 |
+
},
|
| 6328 |
+
}
|
| 6329 |
+
var f = 1,
|
| 6330 |
+
p = 0.5,
|
| 6331 |
+
_ = 0,
|
| 6332 |
+
m = {
|
| 6333 |
+
ease: s(0.25, 0.1, 0.25, 1),
|
| 6334 |
+
'ease-in': s(0.42, 0, 1, 1),
|
| 6335 |
+
'ease-out': s(0, 0, 0.58, 1),
|
| 6336 |
+
'ease-in-out': s(0.42, 0, 0.58, 1),
|
| 6337 |
+
'step-start': o(1, f),
|
| 6338 |
+
'step-middle': o(1, p),
|
| 6339 |
+
'step-end': o(1, _),
|
| 6340 |
+
},
|
| 6341 |
+
g = null,
|
| 6342 |
+
v = '\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*',
|
| 6343 |
+
y = new RegExp('cubic-bezier\\(' + v + ',' + v + ',' + v + ',' + v + '\\)'),
|
| 6344 |
+
b = /steps\(\s*(\d+)\s*\)/,
|
| 6345 |
+
w = /steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,
|
| 6346 |
+
x = 0,
|
| 6347 |
+
S = 1,
|
| 6348 |
+
E = 2,
|
| 6349 |
+
T = 3
|
| 6350 |
+
;(t.cloneTimingInput = function (t) {
|
| 6351 |
+
if ('number' == typeof t) return t
|
| 6352 |
+
var e = {}
|
| 6353 |
+
for (var i in t) e[i] = t[i]
|
| 6354 |
+
return e
|
| 6355 |
+
}),
|
| 6356 |
+
(t.makeTiming = r),
|
| 6357 |
+
(t.numericTimingToObject = function (t) {
|
| 6358 |
+
return 'number' == typeof t && (t = isNaN(t) ? { duration: 0 } : { duration: t }), t
|
| 6359 |
+
}),
|
| 6360 |
+
(t.normalizeTimingInput = function (e, i) {
|
| 6361 |
+
return r((e = t.numericTimingToObject(e)), i)
|
| 6362 |
+
}),
|
| 6363 |
+
(t.calculateActiveDuration = function (t) {
|
| 6364 |
+
return Math.abs(
|
| 6365 |
+
(function (t) {
|
| 6366 |
+
return 0 === t.duration || 0 === t.iterations ? 0 : t.duration * t.iterations
|
| 6367 |
+
})(t) / t.playbackRate,
|
| 6368 |
+
)
|
| 6369 |
+
}),
|
| 6370 |
+
(t.calculateIterationProgress = function (t, e, i) {
|
| 6371 |
+
var n = h(t, e, i),
|
| 6372 |
+
r = (function (t, e, i, n, r) {
|
| 6373 |
+
switch (n) {
|
| 6374 |
+
case S:
|
| 6375 |
+
return 'backwards' == e || 'both' == e ? 0 : null
|
| 6376 |
+
case T:
|
| 6377 |
+
return i - r
|
| 6378 |
+
case E:
|
| 6379 |
+
return 'forwards' == e || 'both' == e ? t : null
|
| 6380 |
+
case x:
|
| 6381 |
+
return null
|
| 6382 |
+
}
|
| 6383 |
+
})(t, i.fill, e, n, i.delay)
|
| 6384 |
+
if (null === r) return null
|
| 6385 |
+
var s = (function (t, e, i, n, r) {
|
| 6386 |
+
var s = r
|
| 6387 |
+
return 0 === t ? e !== S && (s += i) : (s += n / t), s
|
| 6388 |
+
})(i.duration, n, i.iterations, r, i.iterationStart),
|
| 6389 |
+
o = (function (t, e, i, n, r, s) {
|
| 6390 |
+
var o = t === 1 / 0 ? e % 1 : t % 1
|
| 6391 |
+
return 0 !== o || i !== E || 0 === n || (0 === r && 0 !== s) || (o = 1), o
|
| 6392 |
+
})(s, i.iterationStart, n, i.iterations, r, i.duration),
|
| 6393 |
+
a = (function (t, e, i, n) {
|
| 6394 |
+
return t === E && e === 1 / 0 ? 1 / 0 : 1 === i ? Math.floor(n) - 1 : Math.floor(n)
|
| 6395 |
+
})(n, i.iterations, o, s),
|
| 6396 |
+
l = (function (t, e, i) {
|
| 6397 |
+
var n = t
|
| 6398 |
+
if ('normal' !== t && 'reverse' !== t) {
|
| 6399 |
+
var r = e
|
| 6400 |
+
'alternate-reverse' === t && (r += 1),
|
| 6401 |
+
(n = 'normal'),
|
| 6402 |
+
r !== 1 / 0 && r % 2 != 0 && (n = 'reverse')
|
| 6403 |
+
}
|
| 6404 |
+
return 'normal' === n ? i : 1 - i
|
| 6405 |
+
})(i.direction, a, o)
|
| 6406 |
+
return i._easingFunction(l)
|
| 6407 |
+
}),
|
| 6408 |
+
(t.calculatePhase = h),
|
| 6409 |
+
(t.normalizeEasing = a),
|
| 6410 |
+
(t.parseEasingFunction = l)
|
| 6411 |
+
})((rn = {})),
|
| 6412 |
+
(function (t, e) {
|
| 6413 |
+
function i(t, e) {
|
| 6414 |
+
return (t in l && l[t][e]) || e
|
| 6415 |
+
}
|
| 6416 |
+
function n(t, e, n) {
|
| 6417 |
+
if (
|
| 6418 |
+
!(function (t) {
|
| 6419 |
+
return (
|
| 6420 |
+
'display' === t ||
|
| 6421 |
+
0 === t.lastIndexOf('animation', 0) ||
|
| 6422 |
+
0 === t.lastIndexOf('transition', 0)
|
| 6423 |
+
)
|
| 6424 |
+
})(t)
|
| 6425 |
+
) {
|
| 6426 |
+
var r = s[t]
|
| 6427 |
+
if (r)
|
| 6428 |
+
for (var a in ((o.style[t] = e), r)) {
|
| 6429 |
+
var l = r[a],
|
| 6430 |
+
h = o.style[l]
|
| 6431 |
+
n[l] = i(l, h)
|
| 6432 |
+
}
|
| 6433 |
+
else n[t] = i(t, e)
|
| 6434 |
+
}
|
| 6435 |
+
}
|
| 6436 |
+
function r(t) {
|
| 6437 |
+
var e = []
|
| 6438 |
+
for (var i in t)
|
| 6439 |
+
if (!(i in ['easing', 'offset', 'composite'])) {
|
| 6440 |
+
var n = t[i]
|
| 6441 |
+
Array.isArray(n) || (n = [n])
|
| 6442 |
+
for (var r, s = n.length, o = 0; o < s; o++)
|
| 6443 |
+
((r = {}).offset = 'offset' in t ? t.offset : 1 == s ? 1 : o / (s - 1)),
|
| 6444 |
+
'easing' in t && (r.easing = t.easing),
|
| 6445 |
+
'composite' in t && (r.composite = t.composite),
|
| 6446 |
+
(r[i] = n[o]),
|
| 6447 |
+
e.push(r)
|
| 6448 |
+
}
|
| 6449 |
+
return (
|
| 6450 |
+
e.sort(function (t, e) {
|
| 6451 |
+
return t.offset - e.offset
|
| 6452 |
+
}),
|
| 6453 |
+
e
|
| 6454 |
+
)
|
| 6455 |
+
}
|
| 6456 |
+
var s = {
|
| 6457 |
+
background: [
|
| 6458 |
+
'backgroundImage',
|
| 6459 |
+
'backgroundPosition',
|
| 6460 |
+
'backgroundSize',
|
| 6461 |
+
'backgroundRepeat',
|
| 6462 |
+
'backgroundAttachment',
|
| 6463 |
+
'backgroundOrigin',
|
| 6464 |
+
'backgroundClip',
|
| 6465 |
+
'backgroundColor',
|
| 6466 |
+
],
|
| 6467 |
+
border: [
|
| 6468 |
+
'borderTopColor',
|
| 6469 |
+
'borderTopStyle',
|
| 6470 |
+
'borderTopWidth',
|
| 6471 |
+
'borderRightColor',
|
| 6472 |
+
'borderRightStyle',
|
| 6473 |
+
'borderRightWidth',
|
| 6474 |
+
'borderBottomColor',
|
| 6475 |
+
'borderBottomStyle',
|
| 6476 |
+
'borderBottomWidth',
|
| 6477 |
+
'borderLeftColor',
|
| 6478 |
+
'borderLeftStyle',
|
| 6479 |
+
'borderLeftWidth',
|
| 6480 |
+
],
|
| 6481 |
+
borderBottom: ['borderBottomWidth', 'borderBottomStyle', 'borderBottomColor'],
|
| 6482 |
+
borderColor: ['borderTopColor', 'borderRightColor', 'borderBottomColor', 'borderLeftColor'],
|
| 6483 |
+
borderLeft: ['borderLeftWidth', 'borderLeftStyle', 'borderLeftColor'],
|
| 6484 |
+
borderRadius: [
|
| 6485 |
+
'borderTopLeftRadius',
|
| 6486 |
+
'borderTopRightRadius',
|
| 6487 |
+
'borderBottomRightRadius',
|
| 6488 |
+
'borderBottomLeftRadius',
|
| 6489 |
+
],
|
| 6490 |
+
borderRight: ['borderRightWidth', 'borderRightStyle', 'borderRightColor'],
|
| 6491 |
+
borderTop: ['borderTopWidth', 'borderTopStyle', 'borderTopColor'],
|
| 6492 |
+
borderWidth: ['borderTopWidth', 'borderRightWidth', 'borderBottomWidth', 'borderLeftWidth'],
|
| 6493 |
+
flex: ['flexGrow', 'flexShrink', 'flexBasis'],
|
| 6494 |
+
font: ['fontFamily', 'fontSize', 'fontStyle', 'fontVariant', 'fontWeight', 'lineHeight'],
|
| 6495 |
+
margin: ['marginTop', 'marginRight', 'marginBottom', 'marginLeft'],
|
| 6496 |
+
outline: ['outlineColor', 'outlineStyle', 'outlineWidth'],
|
| 6497 |
+
padding: ['paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft'],
|
| 6498 |
+
},
|
| 6499 |
+
o = document.createElementNS('http://www.w3.org/1999/xhtml', 'div'),
|
| 6500 |
+
a = { thin: '1px', medium: '3px', thick: '5px' },
|
| 6501 |
+
l = {
|
| 6502 |
+
borderBottomWidth: a,
|
| 6503 |
+
borderLeftWidth: a,
|
| 6504 |
+
borderRightWidth: a,
|
| 6505 |
+
borderTopWidth: a,
|
| 6506 |
+
fontSize: {
|
| 6507 |
+
'xx-small': '60%',
|
| 6508 |
+
'x-small': '75%',
|
| 6509 |
+
small: '89%',
|
| 6510 |
+
medium: '100%',
|
| 6511 |
+
large: '120%',
|
| 6512 |
+
'x-large': '150%',
|
| 6513 |
+
'xx-large': '200%',
|
| 6514 |
+
},
|
| 6515 |
+
fontWeight: { normal: '400', bold: '700' },
|
| 6516 |
+
outlineWidth: a,
|
| 6517 |
+
textShadow: { none: '0px 0px 0px transparent' },
|
| 6518 |
+
boxShadow: { none: '0px 0px 0px 0px transparent' },
|
| 6519 |
+
}
|
| 6520 |
+
;(t.convertToArrayForm = r),
|
| 6521 |
+
(t.normalizeKeyframes = function (e) {
|
| 6522 |
+
if (null == e) return []
|
| 6523 |
+
window.Symbol &&
|
| 6524 |
+
Symbol.iterator &&
|
| 6525 |
+
Array.prototype.from &&
|
| 6526 |
+
e[Symbol.iterator] &&
|
| 6527 |
+
(e = Array.from(e)),
|
| 6528 |
+
Array.isArray(e) || (e = r(e))
|
| 6529 |
+
for (
|
| 6530 |
+
var i = e.map(function (e) {
|
| 6531 |
+
var i = {}
|
| 6532 |
+
for (var r in e) {
|
| 6533 |
+
var s = e[r]
|
| 6534 |
+
if ('offset' == r) {
|
| 6535 |
+
if (null != s) {
|
| 6536 |
+
if (((s = Number(s)), !isFinite(s)))
|
| 6537 |
+
throw new TypeError('Keyframe offsets must be numbers.')
|
| 6538 |
+
if (s < 0 || s > 1)
|
| 6539 |
+
throw new TypeError('Keyframe offsets must be between 0 and 1.')
|
| 6540 |
+
}
|
| 6541 |
+
} else if ('composite' == r) {
|
| 6542 |
+
if ('add' == s || 'accumulate' == s)
|
| 6543 |
+
throw {
|
| 6544 |
+
type: DOMException.NOT_SUPPORTED_ERR,
|
| 6545 |
+
name: 'NotSupportedError',
|
| 6546 |
+
message: 'add compositing is not supported',
|
| 6547 |
+
}
|
| 6548 |
+
if ('replace' != s) throw new TypeError('Invalid composite mode ' + s + '.')
|
| 6549 |
+
} else s = 'easing' == r ? t.normalizeEasing(s) : '' + s
|
| 6550 |
+
n(r, s, i)
|
| 6551 |
+
}
|
| 6552 |
+
return (
|
| 6553 |
+
null == i.offset && (i.offset = null), null == i.easing && (i.easing = 'linear'), i
|
| 6554 |
+
)
|
| 6555 |
+
}),
|
| 6556 |
+
s = !0,
|
| 6557 |
+
o = -1 / 0,
|
| 6558 |
+
a = 0;
|
| 6559 |
+
a < i.length;
|
| 6560 |
+
a++
|
| 6561 |
+
) {
|
| 6562 |
+
var l = i[a].offset
|
| 6563 |
+
if (null != l) {
|
| 6564 |
+
if (l < o)
|
| 6565 |
+
throw new TypeError(
|
| 6566 |
+
'Keyframes are not loosely sorted by offset. Sort or specify offsets.',
|
| 6567 |
+
)
|
| 6568 |
+
o = l
|
| 6569 |
+
} else s = !1
|
| 6570 |
+
}
|
| 6571 |
+
return (
|
| 6572 |
+
(i = i.filter(function (t) {
|
| 6573 |
+
return t.offset >= 0 && t.offset <= 1
|
| 6574 |
+
})),
|
| 6575 |
+
s ||
|
| 6576 |
+
(function () {
|
| 6577 |
+
var t = i.length
|
| 6578 |
+
null == i[t - 1].offset && (i[t - 1].offset = 1),
|
| 6579 |
+
t > 1 && null == i[0].offset && (i[0].offset = 0)
|
| 6580 |
+
for (var e = 0, n = i[0].offset, r = 1; r < t; r++) {
|
| 6581 |
+
var s = i[r].offset
|
| 6582 |
+
if (null != s) {
|
| 6583 |
+
for (var o = 1; o < r - e; o++) i[e + o].offset = n + ((s - n) * o) / (r - e)
|
| 6584 |
+
;(e = r), (n = s)
|
| 6585 |
+
}
|
| 6586 |
+
}
|
| 6587 |
+
})(),
|
| 6588 |
+
i
|
| 6589 |
+
)
|
| 6590 |
+
})
|
| 6591 |
+
})(rn),
|
| 6592 |
+
(function (t) {
|
| 6593 |
+
var e = {}
|
| 6594 |
+
;(t.isDeprecated = function (t, i, n, r) {
|
| 6595 |
+
var s = r ? 'are' : 'is',
|
| 6596 |
+
o = new Date(),
|
| 6597 |
+
a = new Date(i)
|
| 6598 |
+
return (
|
| 6599 |
+
a.setMonth(a.getMonth() + 3),
|
| 6600 |
+
!(
|
| 6601 |
+
o < a &&
|
| 6602 |
+
(t in e ||
|
| 6603 |
+
console.warn(
|
| 6604 |
+
'Web Animations: ' +
|
| 6605 |
+
t +
|
| 6606 |
+
' ' +
|
| 6607 |
+
s +
|
| 6608 |
+
' deprecated and will stop working on ' +
|
| 6609 |
+
a.toDateString() +
|
| 6610 |
+
'. ' +
|
| 6611 |
+
n,
|
| 6612 |
+
),
|
| 6613 |
+
(e[t] = !0),
|
| 6614 |
+
1)
|
| 6615 |
+
)
|
| 6616 |
+
)
|
| 6617 |
+
}),
|
| 6618 |
+
(t.deprecated = function (e, i, n, r) {
|
| 6619 |
+
var s = r ? 'are' : 'is'
|
| 6620 |
+
if (t.isDeprecated(e, i, n, r)) throw new Error(e + ' ' + s + ' no longer supported. ' + n)
|
| 6621 |
+
})
|
| 6622 |
+
})(rn),
|
| 6623 |
+
(function () {
|
| 6624 |
+
if (document.documentElement.animate) {
|
| 6625 |
+
var t = document.documentElement.animate([], 0),
|
| 6626 |
+
e = !0
|
| 6627 |
+
if (
|
| 6628 |
+
(t &&
|
| 6629 |
+
((e = !1),
|
| 6630 |
+
'play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState'
|
| 6631 |
+
.split('|')
|
| 6632 |
+
.forEach(function (i) {
|
| 6633 |
+
void 0 === t[i] && (e = !0)
|
| 6634 |
+
})),
|
| 6635 |
+
!e)
|
| 6636 |
+
)
|
| 6637 |
+
return
|
| 6638 |
+
}
|
| 6639 |
+
!(function (t, e, i) {
|
| 6640 |
+
e.convertEffectInput = function (i) {
|
| 6641 |
+
var n = (function (t) {
|
| 6642 |
+
for (var e = {}, i = 0; i < t.length; i++)
|
| 6643 |
+
for (var n in t[i])
|
| 6644 |
+
if ('offset' != n && 'easing' != n && 'composite' != n) {
|
| 6645 |
+
var r = { offset: t[i].offset, easing: t[i].easing, value: t[i][n] }
|
| 6646 |
+
;(e[n] = e[n] || []), e[n].push(r)
|
| 6647 |
+
}
|
| 6648 |
+
for (var s in e) {
|
| 6649 |
+
var o = e[s]
|
| 6650 |
+
if (0 != o[0].offset || 1 != o[o.length - 1].offset)
|
| 6651 |
+
throw {
|
| 6652 |
+
type: DOMException.NOT_SUPPORTED_ERR,
|
| 6653 |
+
name: 'NotSupportedError',
|
| 6654 |
+
message: 'Partial keyframes are not supported',
|
| 6655 |
+
}
|
| 6656 |
+
}
|
| 6657 |
+
return e
|
| 6658 |
+
})(t.normalizeKeyframes(i)),
|
| 6659 |
+
r = (function (i) {
|
| 6660 |
+
var n = []
|
| 6661 |
+
for (var r in i)
|
| 6662 |
+
for (var s = i[r], o = 0; o < s.length - 1; o++) {
|
| 6663 |
+
var a = o,
|
| 6664 |
+
l = o + 1,
|
| 6665 |
+
h = s[a].offset,
|
| 6666 |
+
u = s[l].offset,
|
| 6667 |
+
c = h,
|
| 6668 |
+
d = u
|
| 6669 |
+
0 == o && ((c = -1 / 0), 0 == u && (l = a)),
|
| 6670 |
+
o == s.length - 2 && ((d = 1 / 0), 1 == h && (a = l)),
|
| 6671 |
+
n.push({
|
| 6672 |
+
applyFrom: c,
|
| 6673 |
+
applyTo: d,
|
| 6674 |
+
startOffset: s[a].offset,
|
| 6675 |
+
endOffset: s[l].offset,
|
| 6676 |
+
easingFunction: t.parseEasingFunction(s[a].easing),
|
| 6677 |
+
property: r,
|
| 6678 |
+
interpolation: e.propertyInterpolation(r, s[a].value, s[l].value),
|
| 6679 |
+
})
|
| 6680 |
+
}
|
| 6681 |
+
return (
|
| 6682 |
+
n.sort(function (t, e) {
|
| 6683 |
+
return t.startOffset - e.startOffset
|
| 6684 |
+
}),
|
| 6685 |
+
n
|
| 6686 |
+
)
|
| 6687 |
+
})(n)
|
| 6688 |
+
return function (t, i) {
|
| 6689 |
+
if (null != i)
|
| 6690 |
+
r.filter(function (t) {
|
| 6691 |
+
return i >= t.applyFrom && i < t.applyTo
|
| 6692 |
+
}).forEach(function (n) {
|
| 6693 |
+
var r = i - n.startOffset,
|
| 6694 |
+
s = n.endOffset - n.startOffset,
|
| 6695 |
+
o = 0 == s ? 0 : n.easingFunction(r / s)
|
| 6696 |
+
e.apply(t, n.property, n.interpolation(o))
|
| 6697 |
+
})
|
| 6698 |
+
else for (var s in n) 'offset' != s && 'easing' != s && 'composite' != s && e.clear(t, s)
|
| 6699 |
+
}
|
| 6700 |
+
}
|
| 6701 |
+
})(rn, sn),
|
| 6702 |
+
(function (t, e, i) {
|
| 6703 |
+
function n(t) {
|
| 6704 |
+
return t.replace(/-(.)/g, function (t, e) {
|
| 6705 |
+
return e.toUpperCase()
|
| 6706 |
+
})
|
| 6707 |
+
}
|
| 6708 |
+
function r(t, e, i) {
|
| 6709 |
+
;(s[i] = s[i] || []), s[i].push([t, e])
|
| 6710 |
+
}
|
| 6711 |
+
var s = {}
|
| 6712 |
+
e.addPropertiesHandler = function (t, e, i) {
|
| 6713 |
+
for (var s = 0; s < i.length; s++) r(t, e, n(i[s]))
|
| 6714 |
+
}
|
| 6715 |
+
var o = {
|
| 6716 |
+
backgroundColor: 'transparent',
|
| 6717 |
+
backgroundPosition: '0% 0%',
|
| 6718 |
+
borderBottomColor: 'currentColor',
|
| 6719 |
+
borderBottomLeftRadius: '0px',
|
| 6720 |
+
borderBottomRightRadius: '0px',
|
| 6721 |
+
borderBottomWidth: '3px',
|
| 6722 |
+
borderLeftColor: 'currentColor',
|
| 6723 |
+
borderLeftWidth: '3px',
|
| 6724 |
+
borderRightColor: 'currentColor',
|
| 6725 |
+
borderRightWidth: '3px',
|
| 6726 |
+
borderSpacing: '2px',
|
| 6727 |
+
borderTopColor: 'currentColor',
|
| 6728 |
+
borderTopLeftRadius: '0px',
|
| 6729 |
+
borderTopRightRadius: '0px',
|
| 6730 |
+
borderTopWidth: '3px',
|
| 6731 |
+
bottom: 'auto',
|
| 6732 |
+
clip: 'rect(0px, 0px, 0px, 0px)',
|
| 6733 |
+
color: 'black',
|
| 6734 |
+
fontSize: '100%',
|
| 6735 |
+
fontWeight: '400',
|
| 6736 |
+
height: 'auto',
|
| 6737 |
+
left: 'auto',
|
| 6738 |
+
letterSpacing: 'normal',
|
| 6739 |
+
lineHeight: '120%',
|
| 6740 |
+
marginBottom: '0px',
|
| 6741 |
+
marginLeft: '0px',
|
| 6742 |
+
marginRight: '0px',
|
| 6743 |
+
marginTop: '0px',
|
| 6744 |
+
maxHeight: 'none',
|
| 6745 |
+
maxWidth: 'none',
|
| 6746 |
+
minHeight: '0px',
|
| 6747 |
+
minWidth: '0px',
|
| 6748 |
+
opacity: '1.0',
|
| 6749 |
+
outlineColor: 'invert',
|
| 6750 |
+
outlineOffset: '0px',
|
| 6751 |
+
outlineWidth: '3px',
|
| 6752 |
+
paddingBottom: '0px',
|
| 6753 |
+
paddingLeft: '0px',
|
| 6754 |
+
paddingRight: '0px',
|
| 6755 |
+
paddingTop: '0px',
|
| 6756 |
+
right: 'auto',
|
| 6757 |
+
strokeDasharray: 'none',
|
| 6758 |
+
strokeDashoffset: '0px',
|
| 6759 |
+
textIndent: '0px',
|
| 6760 |
+
textShadow: '0px 0px 0px transparent',
|
| 6761 |
+
top: 'auto',
|
| 6762 |
+
transform: '',
|
| 6763 |
+
verticalAlign: '0px',
|
| 6764 |
+
visibility: 'visible',
|
| 6765 |
+
width: 'auto',
|
| 6766 |
+
wordSpacing: 'normal',
|
| 6767 |
+
zIndex: 'auto',
|
| 6768 |
+
}
|
| 6769 |
+
e.propertyInterpolation = function (i, r, a) {
|
| 6770 |
+
var l = i
|
| 6771 |
+
;/-/.test(i) &&
|
| 6772 |
+
!t.isDeprecated('Hyphenated property names', '2016-03-22', 'Use camelCase instead.', !0) &&
|
| 6773 |
+
(l = n(i)),
|
| 6774 |
+
('initial' != r && 'initial' != a) ||
|
| 6775 |
+
('initial' == r && (r = o[l]), 'initial' == a && (a = o[l]))
|
| 6776 |
+
for (var h = r == a ? [] : s[l], u = 0; h && u < h.length; u++) {
|
| 6777 |
+
var c = h[u][0](r),
|
| 6778 |
+
d = h[u][0](a)
|
| 6779 |
+
if (void 0 !== c && void 0 !== d) {
|
| 6780 |
+
var f = h[u][1](c, d)
|
| 6781 |
+
if (f) {
|
| 6782 |
+
var p = e.Interpolation.apply(null, f)
|
| 6783 |
+
return function (t) {
|
| 6784 |
+
return 0 == t ? r : 1 == t ? a : p(t)
|
| 6785 |
+
}
|
| 6786 |
+
}
|
| 6787 |
+
}
|
| 6788 |
+
}
|
| 6789 |
+
return e.Interpolation(!1, !0, function (t) {
|
| 6790 |
+
return t ? a : r
|
| 6791 |
+
})
|
| 6792 |
+
}
|
| 6793 |
+
})(rn, sn),
|
| 6794 |
+
(function (t, e, i) {
|
| 6795 |
+
e.KeyframeEffect = function (i, n, r, s) {
|
| 6796 |
+
var o,
|
| 6797 |
+
a = (function (e) {
|
| 6798 |
+
var i = t.calculateActiveDuration(e),
|
| 6799 |
+
n = function (n) {
|
| 6800 |
+
return t.calculateIterationProgress(i, n, e)
|
| 6801 |
+
}
|
| 6802 |
+
return (n._totalDuration = e.delay + i + e.endDelay), n
|
| 6803 |
+
})(t.normalizeTimingInput(r)),
|
| 6804 |
+
l = e.convertEffectInput(n),
|
| 6805 |
+
h = function () {
|
| 6806 |
+
l(i, o)
|
| 6807 |
+
}
|
| 6808 |
+
return (
|
| 6809 |
+
(h._update = function (t) {
|
| 6810 |
+
return null !== (o = a(t))
|
| 6811 |
+
}),
|
| 6812 |
+
(h._clear = function () {
|
| 6813 |
+
l(i, null)
|
| 6814 |
+
}),
|
| 6815 |
+
(h._hasSameTarget = function (t) {
|
| 6816 |
+
return i === t
|
| 6817 |
+
}),
|
| 6818 |
+
(h._target = i),
|
| 6819 |
+
(h._totalDuration = a._totalDuration),
|
| 6820 |
+
(h._id = s),
|
| 6821 |
+
h
|
| 6822 |
+
)
|
| 6823 |
+
}
|
| 6824 |
+
})(rn, sn),
|
| 6825 |
+
(function (t, e) {
|
| 6826 |
+
function i(t, e, i) {
|
| 6827 |
+
;(i.enumerable = !0), (i.configurable = !0), Object.defineProperty(t, e, i)
|
| 6828 |
+
}
|
| 6829 |
+
function n(t) {
|
| 6830 |
+
;(this._element = t),
|
| 6831 |
+
(this._surrogateStyle = document.createElementNS(
|
| 6832 |
+
'http://www.w3.org/1999/xhtml',
|
| 6833 |
+
'div',
|
| 6834 |
+
).style),
|
| 6835 |
+
(this._style = t.style),
|
| 6836 |
+
(this._length = 0),
|
| 6837 |
+
(this._isAnimatedProperty = {}),
|
| 6838 |
+
(this._updateSvgTransformAttr = (function (t, e) {
|
| 6839 |
+
return (
|
| 6840 |
+
!(!e.namespaceURI || -1 == e.namespaceURI.indexOf('/svg')) &&
|
| 6841 |
+
(s in t ||
|
| 6842 |
+
(t[s] = /Trident|MSIE|IEMobile|Edge|Android 4/i.test(t.navigator.userAgent)),
|
| 6843 |
+
t[s])
|
| 6844 |
+
)
|
| 6845 |
+
})(window, t)),
|
| 6846 |
+
(this._savedTransformAttr = null)
|
| 6847 |
+
for (var e = 0; e < this._style.length; e++) {
|
| 6848 |
+
var i = this._style[e]
|
| 6849 |
+
this._surrogateStyle[i] = this._style[i]
|
| 6850 |
+
}
|
| 6851 |
+
this._updateIndices()
|
| 6852 |
+
}
|
| 6853 |
+
function r(t) {
|
| 6854 |
+
if (!t._webAnimationsPatchedStyle) {
|
| 6855 |
+
var e = new n(t)
|
| 6856 |
+
try {
|
| 6857 |
+
i(t, 'style', {
|
| 6858 |
+
get: function () {
|
| 6859 |
+
return e
|
| 6860 |
+
},
|
| 6861 |
+
})
|
| 6862 |
+
} catch (e) {
|
| 6863 |
+
;(t.style._set = function (e, i) {
|
| 6864 |
+
t.style[e] = i
|
| 6865 |
+
}),
|
| 6866 |
+
(t.style._clear = function (e) {
|
| 6867 |
+
t.style[e] = ''
|
| 6868 |
+
})
|
| 6869 |
+
}
|
| 6870 |
+
t._webAnimationsPatchedStyle = t.style
|
| 6871 |
+
}
|
| 6872 |
+
}
|
| 6873 |
+
var s = '_webAnimationsUpdateSvgTransformAttr',
|
| 6874 |
+
o = { cssText: 1, length: 1, parentRule: 1 },
|
| 6875 |
+
a = {
|
| 6876 |
+
getPropertyCSSValue: 1,
|
| 6877 |
+
getPropertyPriority: 1,
|
| 6878 |
+
getPropertyValue: 1,
|
| 6879 |
+
item: 1,
|
| 6880 |
+
removeProperty: 1,
|
| 6881 |
+
setProperty: 1,
|
| 6882 |
+
},
|
| 6883 |
+
l = { removeProperty: 1, setProperty: 1 }
|
| 6884 |
+
for (var h in ((n.prototype = {
|
| 6885 |
+
get cssText() {
|
| 6886 |
+
return this._surrogateStyle.cssText
|
| 6887 |
+
},
|
| 6888 |
+
set cssText(t) {
|
| 6889 |
+
for (var e = {}, i = 0; i < this._surrogateStyle.length; i++)
|
| 6890 |
+
e[this._surrogateStyle[i]] = !0
|
| 6891 |
+
for (
|
| 6892 |
+
this._surrogateStyle.cssText = t, this._updateIndices(), i = 0;
|
| 6893 |
+
i < this._surrogateStyle.length;
|
| 6894 |
+
i++
|
| 6895 |
+
)
|
| 6896 |
+
e[this._surrogateStyle[i]] = !0
|
| 6897 |
+
for (var n in e)
|
| 6898 |
+
this._isAnimatedProperty[n] ||
|
| 6899 |
+
this._style.setProperty(n, this._surrogateStyle.getPropertyValue(n))
|
| 6900 |
+
},
|
| 6901 |
+
get length() {
|
| 6902 |
+
return this._surrogateStyle.length
|
| 6903 |
+
},
|
| 6904 |
+
get parentRule() {
|
| 6905 |
+
return this._style.parentRule
|
| 6906 |
+
},
|
| 6907 |
+
_updateIndices: function () {
|
| 6908 |
+
for (; this._length < this._surrogateStyle.length; )
|
| 6909 |
+
Object.defineProperty(this, this._length, {
|
| 6910 |
+
configurable: !0,
|
| 6911 |
+
enumerable: !1,
|
| 6912 |
+
get: (function (t) {
|
| 6913 |
+
return function () {
|
| 6914 |
+
return this._surrogateStyle[t]
|
| 6915 |
+
}
|
| 6916 |
+
})(this._length),
|
| 6917 |
+
}),
|
| 6918 |
+
this._length++
|
| 6919 |
+
for (; this._length > this._surrogateStyle.length; )
|
| 6920 |
+
this._length--,
|
| 6921 |
+
Object.defineProperty(this, this._length, {
|
| 6922 |
+
configurable: !0,
|
| 6923 |
+
enumerable: !1,
|
| 6924 |
+
value: void 0,
|
| 6925 |
+
})
|
| 6926 |
+
},
|
| 6927 |
+
_set: function (e, i) {
|
| 6928 |
+
;(this._style[e] = i),
|
| 6929 |
+
(this._isAnimatedProperty[e] = !0),
|
| 6930 |
+
this._updateSvgTransformAttr &&
|
| 6931 |
+
'transform' == t.unprefixedPropertyName(e) &&
|
| 6932 |
+
(null == this._savedTransformAttr &&
|
| 6933 |
+
(this._savedTransformAttr = this._element.getAttribute('transform')),
|
| 6934 |
+
this._element.setAttribute('transform', t.transformToSvgMatrix(i)))
|
| 6935 |
+
},
|
| 6936 |
+
_clear: function (e) {
|
| 6937 |
+
;(this._style[e] = this._surrogateStyle[e]),
|
| 6938 |
+
this._updateSvgTransformAttr &&
|
| 6939 |
+
'transform' == t.unprefixedPropertyName(e) &&
|
| 6940 |
+
(this._savedTransformAttr
|
| 6941 |
+
? this._element.setAttribute('transform', this._savedTransformAttr)
|
| 6942 |
+
: this._element.removeAttribute('transform'),
|
| 6943 |
+
(this._savedTransformAttr = null)),
|
| 6944 |
+
delete this._isAnimatedProperty[e]
|
| 6945 |
+
},
|
| 6946 |
+
}),
|
| 6947 |
+
a))
|
| 6948 |
+
n.prototype[h] = (function (t, e) {
|
| 6949 |
+
return function () {
|
| 6950 |
+
var i = this._surrogateStyle[t].apply(this._surrogateStyle, arguments)
|
| 6951 |
+
return (
|
| 6952 |
+
e &&
|
| 6953 |
+
(this._isAnimatedProperty[arguments[0]] ||
|
| 6954 |
+
this._style[t].apply(this._style, arguments),
|
| 6955 |
+
this._updateIndices()),
|
| 6956 |
+
i
|
| 6957 |
+
)
|
| 6958 |
+
}
|
| 6959 |
+
})(h, h in l)
|
| 6960 |
+
for (var u in document.documentElement.style)
|
| 6961 |
+
u in o ||
|
| 6962 |
+
u in a ||
|
| 6963 |
+
(function (t) {
|
| 6964 |
+
i(n.prototype, t, {
|
| 6965 |
+
get: function () {
|
| 6966 |
+
return this._surrogateStyle[t]
|
| 6967 |
+
},
|
| 6968 |
+
set: function (e) {
|
| 6969 |
+
;(this._surrogateStyle[t] = e),
|
| 6970 |
+
this._updateIndices(),
|
| 6971 |
+
this._isAnimatedProperty[t] || (this._style[t] = e)
|
| 6972 |
+
},
|
| 6973 |
+
})
|
| 6974 |
+
})(u)
|
| 6975 |
+
;(t.apply = function (e, i, n) {
|
| 6976 |
+
r(e), e.style._set(t.propertyName(i), n)
|
| 6977 |
+
}),
|
| 6978 |
+
(t.clear = function (e, i) {
|
| 6979 |
+
e._webAnimationsPatchedStyle && e.style._clear(t.propertyName(i))
|
| 6980 |
+
})
|
| 6981 |
+
})(sn),
|
| 6982 |
+
(function (t) {
|
| 6983 |
+
window.Element.prototype.animate = function (e, i) {
|
| 6984 |
+
var n = ''
|
| 6985 |
+
return i && i.id && (n = i.id), t.timeline._play(t.KeyframeEffect(this, e, i, n))
|
| 6986 |
+
}
|
| 6987 |
+
})(sn),
|
| 6988 |
+
(function (t, e) {
|
| 6989 |
+
function i(t, e, n) {
|
| 6990 |
+
if ('number' == typeof t && 'number' == typeof e) return t * (1 - n) + e * n
|
| 6991 |
+
if ('boolean' == typeof t && 'boolean' == typeof e) return n < 0.5 ? t : e
|
| 6992 |
+
if (t.length == e.length) {
|
| 6993 |
+
for (var r = [], s = 0; s < t.length; s++) r.push(i(t[s], e[s], n))
|
| 6994 |
+
return r
|
| 6995 |
+
}
|
| 6996 |
+
throw 'Mismatched interpolation arguments ' + t + ':' + e
|
| 6997 |
+
}
|
| 6998 |
+
t.Interpolation = function (t, e, n) {
|
| 6999 |
+
return function (r) {
|
| 7000 |
+
return n(i(t, e, r))
|
| 7001 |
+
}
|
| 7002 |
+
}
|
| 7003 |
+
})(sn),
|
| 7004 |
+
(function (t, e) {
|
| 7005 |
+
var i = (function () {
|
| 7006 |
+
function t(t, e) {
|
| 7007 |
+
for (
|
| 7008 |
+
var i = [
|
| 7009 |
+
[0, 0, 0, 0],
|
| 7010 |
+
[0, 0, 0, 0],
|
| 7011 |
+
[0, 0, 0, 0],
|
| 7012 |
+
[0, 0, 0, 0],
|
| 7013 |
+
],
|
| 7014 |
+
n = 0;
|
| 7015 |
+
n < 4;
|
| 7016 |
+
n++
|
| 7017 |
+
)
|
| 7018 |
+
for (var r = 0; r < 4; r++) for (var s = 0; s < 4; s++) i[n][r] += e[n][s] * t[s][r]
|
| 7019 |
+
return i
|
| 7020 |
+
}
|
| 7021 |
+
return function (e, i, n, r, s) {
|
| 7022 |
+
for (
|
| 7023 |
+
var o = [
|
| 7024 |
+
[1, 0, 0, 0],
|
| 7025 |
+
[0, 1, 0, 0],
|
| 7026 |
+
[0, 0, 1, 0],
|
| 7027 |
+
[0, 0, 0, 1],
|
| 7028 |
+
],
|
| 7029 |
+
a = 0;
|
| 7030 |
+
a < 4;
|
| 7031 |
+
a++
|
| 7032 |
+
)
|
| 7033 |
+
o[a][3] = s[a]
|
| 7034 |
+
for (a = 0; a < 3; a++) for (var l = 0; l < 3; l++) o[3][a] += e[l] * o[l][a]
|
| 7035 |
+
var h = r[0],
|
| 7036 |
+
u = r[1],
|
| 7037 |
+
c = r[2],
|
| 7038 |
+
d = r[3],
|
| 7039 |
+
f = [
|
| 7040 |
+
[1, 0, 0, 0],
|
| 7041 |
+
[0, 1, 0, 0],
|
| 7042 |
+
[0, 0, 1, 0],
|
| 7043 |
+
[0, 0, 0, 1],
|
| 7044 |
+
]
|
| 7045 |
+
;(f[0][0] = 1 - 2 * (u * u + c * c)),
|
| 7046 |
+
(f[0][1] = 2 * (h * u - c * d)),
|
| 7047 |
+
(f[0][2] = 2 * (h * c + u * d)),
|
| 7048 |
+
(f[1][0] = 2 * (h * u + c * d)),
|
| 7049 |
+
(f[1][1] = 1 - 2 * (h * h + c * c)),
|
| 7050 |
+
(f[1][2] = 2 * (u * c - h * d)),
|
| 7051 |
+
(f[2][0] = 2 * (h * c - u * d)),
|
| 7052 |
+
(f[2][1] = 2 * (u * c + h * d)),
|
| 7053 |
+
(f[2][2] = 1 - 2 * (h * h + u * u)),
|
| 7054 |
+
(o = t(o, f))
|
| 7055 |
+
var p = [
|
| 7056 |
+
[1, 0, 0, 0],
|
| 7057 |
+
[0, 1, 0, 0],
|
| 7058 |
+
[0, 0, 1, 0],
|
| 7059 |
+
[0, 0, 0, 1],
|
| 7060 |
+
]
|
| 7061 |
+
for (
|
| 7062 |
+
n[2] && ((p[2][1] = n[2]), (o = t(o, p))),
|
| 7063 |
+
n[1] && ((p[2][1] = 0), (p[2][0] = n[0]), (o = t(o, p))),
|
| 7064 |
+
n[0] && ((p[2][0] = 0), (p[1][0] = n[0]), (o = t(o, p))),
|
| 7065 |
+
a = 0;
|
| 7066 |
+
a < 3;
|
| 7067 |
+
a++
|
| 7068 |
+
)
|
| 7069 |
+
for (l = 0; l < 3; l++) o[a][l] *= i[a]
|
| 7070 |
+
return (function (t) {
|
| 7071 |
+
return (
|
| 7072 |
+
0 == t[0][2] &&
|
| 7073 |
+
0 == t[0][3] &&
|
| 7074 |
+
0 == t[1][2] &&
|
| 7075 |
+
0 == t[1][3] &&
|
| 7076 |
+
0 == t[2][0] &&
|
| 7077 |
+
0 == t[2][1] &&
|
| 7078 |
+
1 == t[2][2] &&
|
| 7079 |
+
0 == t[2][3] &&
|
| 7080 |
+
0 == t[3][2] &&
|
| 7081 |
+
1 == t[3][3]
|
| 7082 |
+
)
|
| 7083 |
+
})(o)
|
| 7084 |
+
? [o[0][0], o[0][1], o[1][0], o[1][1], o[3][0], o[3][1]]
|
| 7085 |
+
: o[0].concat(o[1], o[2], o[3])
|
| 7086 |
+
}
|
| 7087 |
+
})()
|
| 7088 |
+
;(t.composeMatrix = i),
|
| 7089 |
+
(t.quat = function (e, i, n) {
|
| 7090 |
+
var r = t.dot(e, i)
|
| 7091 |
+
r = (function (t, e, i) {
|
| 7092 |
+
return Math.max(Math.min(t, i), e)
|
| 7093 |
+
})(r, -1, 1)
|
| 7094 |
+
var s = []
|
| 7095 |
+
if (1 === r) s = e
|
| 7096 |
+
else
|
| 7097 |
+
for (
|
| 7098 |
+
var o = Math.acos(r), a = (1 * Math.sin(n * o)) / Math.sqrt(1 - r * r), l = 0;
|
| 7099 |
+
l < 4;
|
| 7100 |
+
l++
|
| 7101 |
+
)
|
| 7102 |
+
s.push(e[l] * (Math.cos(n * o) - r * a) + i[l] * a)
|
| 7103 |
+
return s
|
| 7104 |
+
})
|
| 7105 |
+
})(sn),
|
| 7106 |
+
(function (t, e, i) {
|
| 7107 |
+
t.sequenceNumber = 0
|
| 7108 |
+
var n = function (t, e, i) {
|
| 7109 |
+
;(this.target = t),
|
| 7110 |
+
(this.currentTime = e),
|
| 7111 |
+
(this.timelineTime = i),
|
| 7112 |
+
(this.type = 'finish'),
|
| 7113 |
+
(this.bubbles = !1),
|
| 7114 |
+
(this.cancelable = !1),
|
| 7115 |
+
(this.currentTarget = t),
|
| 7116 |
+
(this.defaultPrevented = !1),
|
| 7117 |
+
(this.eventPhase = Event.AT_TARGET),
|
| 7118 |
+
(this.timeStamp = Date.now())
|
| 7119 |
+
}
|
| 7120 |
+
;(e.Animation = function (e) {
|
| 7121 |
+
;(this.id = ''),
|
| 7122 |
+
e && e._id && (this.id = e._id),
|
| 7123 |
+
(this._sequenceNumber = t.sequenceNumber++),
|
| 7124 |
+
(this._currentTime = 0),
|
| 7125 |
+
(this._startTime = null),
|
| 7126 |
+
(this._paused = !1),
|
| 7127 |
+
(this._playbackRate = 1),
|
| 7128 |
+
(this._inTimeline = !0),
|
| 7129 |
+
(this._finishedFlag = !0),
|
| 7130 |
+
(this.onfinish = null),
|
| 7131 |
+
(this._finishHandlers = []),
|
| 7132 |
+
(this._effect = e),
|
| 7133 |
+
(this._inEffect = this._effect._update(0)),
|
| 7134 |
+
(this._idle = !0),
|
| 7135 |
+
(this._currentTimePending = !1)
|
| 7136 |
+
}),
|
| 7137 |
+
(e.Animation.prototype = {
|
| 7138 |
+
_ensureAlive: function () {
|
| 7139 |
+
this.playbackRate < 0 && 0 === this.currentTime
|
| 7140 |
+
? (this._inEffect = this._effect._update(-1))
|
| 7141 |
+
: (this._inEffect = this._effect._update(this.currentTime)),
|
| 7142 |
+
this._inTimeline ||
|
| 7143 |
+
(!this._inEffect && this._finishedFlag) ||
|
| 7144 |
+
((this._inTimeline = !0), e.timeline._animations.push(this))
|
| 7145 |
+
},
|
| 7146 |
+
_tickCurrentTime: function (t, e) {
|
| 7147 |
+
t != this._currentTime &&
|
| 7148 |
+
((this._currentTime = t),
|
| 7149 |
+
this._isFinished &&
|
| 7150 |
+
!e &&
|
| 7151 |
+
(this._currentTime = this._playbackRate > 0 ? this._totalDuration : 0),
|
| 7152 |
+
this._ensureAlive())
|
| 7153 |
+
},
|
| 7154 |
+
get currentTime() {
|
| 7155 |
+
return this._idle || this._currentTimePending ? null : this._currentTime
|
| 7156 |
+
},
|
| 7157 |
+
set currentTime(t) {
|
| 7158 |
+
;(t = +t),
|
| 7159 |
+
isNaN(t) ||
|
| 7160 |
+
(e.restart(),
|
| 7161 |
+
this._paused ||
|
| 7162 |
+
null == this._startTime ||
|
| 7163 |
+
(this._startTime = this._timeline.currentTime - t / this._playbackRate),
|
| 7164 |
+
(this._currentTimePending = !1),
|
| 7165 |
+
this._currentTime != t &&
|
| 7166 |
+
(this._idle && ((this._idle = !1), (this._paused = !0)),
|
| 7167 |
+
this._tickCurrentTime(t, !0),
|
| 7168 |
+
e.applyDirtiedAnimation(this)))
|
| 7169 |
+
},
|
| 7170 |
+
get startTime() {
|
| 7171 |
+
return this._startTime
|
| 7172 |
+
},
|
| 7173 |
+
set startTime(t) {
|
| 7174 |
+
;(t = +t),
|
| 7175 |
+
isNaN(t) ||
|
| 7176 |
+
this._paused ||
|
| 7177 |
+
this._idle ||
|
| 7178 |
+
((this._startTime = t),
|
| 7179 |
+
this._tickCurrentTime(
|
| 7180 |
+
(this._timeline.currentTime - this._startTime) * this.playbackRate,
|
| 7181 |
+
),
|
| 7182 |
+
e.applyDirtiedAnimation(this))
|
| 7183 |
+
},
|
| 7184 |
+
get playbackRate() {
|
| 7185 |
+
return this._playbackRate
|
| 7186 |
+
},
|
| 7187 |
+
set playbackRate(t) {
|
| 7188 |
+
if (t != this._playbackRate) {
|
| 7189 |
+
var i = this.currentTime
|
| 7190 |
+
;(this._playbackRate = t),
|
| 7191 |
+
(this._startTime = null),
|
| 7192 |
+
'paused' != this.playState &&
|
| 7193 |
+
'idle' != this.playState &&
|
| 7194 |
+
((this._finishedFlag = !1),
|
| 7195 |
+
(this._idle = !1),
|
| 7196 |
+
this._ensureAlive(),
|
| 7197 |
+
e.applyDirtiedAnimation(this)),
|
| 7198 |
+
null != i && (this.currentTime = i)
|
| 7199 |
+
}
|
| 7200 |
+
},
|
| 7201 |
+
get _isFinished() {
|
| 7202 |
+
return (
|
| 7203 |
+
!this._idle &&
|
| 7204 |
+
((this._playbackRate > 0 && this._currentTime >= this._totalDuration) ||
|
| 7205 |
+
(this._playbackRate < 0 && this._currentTime <= 0))
|
| 7206 |
+
)
|
| 7207 |
+
},
|
| 7208 |
+
get _totalDuration() {
|
| 7209 |
+
return this._effect._totalDuration
|
| 7210 |
+
},
|
| 7211 |
+
get playState() {
|
| 7212 |
+
return this._idle
|
| 7213 |
+
? 'idle'
|
| 7214 |
+
: (null == this._startTime && !this._paused && 0 != this.playbackRate) ||
|
| 7215 |
+
this._currentTimePending
|
| 7216 |
+
? 'pending'
|
| 7217 |
+
: this._paused
|
| 7218 |
+
? 'paused'
|
| 7219 |
+
: this._isFinished
|
| 7220 |
+
? 'finished'
|
| 7221 |
+
: 'running'
|
| 7222 |
+
},
|
| 7223 |
+
_rewind: function () {
|
| 7224 |
+
if (this._playbackRate >= 0) this._currentTime = 0
|
| 7225 |
+
else {
|
| 7226 |
+
if (!(this._totalDuration < 1 / 0))
|
| 7227 |
+
throw new DOMException(
|
| 7228 |
+
'Unable to rewind negative playback rate animation with infinite duration',
|
| 7229 |
+
'InvalidStateError',
|
| 7230 |
+
)
|
| 7231 |
+
this._currentTime = this._totalDuration
|
| 7232 |
+
}
|
| 7233 |
+
},
|
| 7234 |
+
play: function () {
|
| 7235 |
+
;(this._paused = !1),
|
| 7236 |
+
(this._isFinished || this._idle) && (this._rewind(), (this._startTime = null)),
|
| 7237 |
+
(this._finishedFlag = !1),
|
| 7238 |
+
(this._idle = !1),
|
| 7239 |
+
this._ensureAlive(),
|
| 7240 |
+
e.applyDirtiedAnimation(this)
|
| 7241 |
+
},
|
| 7242 |
+
pause: function () {
|
| 7243 |
+
this._isFinished || this._paused || this._idle
|
| 7244 |
+
? this._idle && (this._rewind(), (this._idle = !1))
|
| 7245 |
+
: (this._currentTimePending = !0),
|
| 7246 |
+
(this._startTime = null),
|
| 7247 |
+
(this._paused = !0)
|
| 7248 |
+
},
|
| 7249 |
+
finish: function () {
|
| 7250 |
+
this._idle ||
|
| 7251 |
+
((this.currentTime = this._playbackRate > 0 ? this._totalDuration : 0),
|
| 7252 |
+
(this._startTime = this._totalDuration - this.currentTime),
|
| 7253 |
+
(this._currentTimePending = !1),
|
| 7254 |
+
e.applyDirtiedAnimation(this))
|
| 7255 |
+
},
|
| 7256 |
+
cancel: function () {
|
| 7257 |
+
this._inEffect &&
|
| 7258 |
+
((this._inEffect = !1),
|
| 7259 |
+
(this._idle = !0),
|
| 7260 |
+
(this._paused = !1),
|
| 7261 |
+
(this._finishedFlag = !0),
|
| 7262 |
+
(this._currentTime = 0),
|
| 7263 |
+
(this._startTime = null),
|
| 7264 |
+
this._effect._update(null),
|
| 7265 |
+
e.applyDirtiedAnimation(this))
|
| 7266 |
+
},
|
| 7267 |
+
reverse: function () {
|
| 7268 |
+
;(this.playbackRate *= -1), this.play()
|
| 7269 |
+
},
|
| 7270 |
+
addEventListener: function (t, e) {
|
| 7271 |
+
'function' == typeof e && 'finish' == t && this._finishHandlers.push(e)
|
| 7272 |
+
},
|
| 7273 |
+
removeEventListener: function (t, e) {
|
| 7274 |
+
if ('finish' == t) {
|
| 7275 |
+
var i = this._finishHandlers.indexOf(e)
|
| 7276 |
+
i >= 0 && this._finishHandlers.splice(i, 1)
|
| 7277 |
+
}
|
| 7278 |
+
},
|
| 7279 |
+
_fireEvents: function (t) {
|
| 7280 |
+
if (this._isFinished) {
|
| 7281 |
+
if (!this._finishedFlag) {
|
| 7282 |
+
var e = new n(this, this._currentTime, t),
|
| 7283 |
+
i = this._finishHandlers.concat(this.onfinish ? [this.onfinish] : [])
|
| 7284 |
+
setTimeout(function () {
|
| 7285 |
+
i.forEach(function (t) {
|
| 7286 |
+
t.call(e.target, e)
|
| 7287 |
+
})
|
| 7288 |
+
}, 0),
|
| 7289 |
+
(this._finishedFlag = !0)
|
| 7290 |
+
}
|
| 7291 |
+
} else this._finishedFlag = !1
|
| 7292 |
+
},
|
| 7293 |
+
_tick: function (t, e) {
|
| 7294 |
+
this._idle ||
|
| 7295 |
+
this._paused ||
|
| 7296 |
+
(null == this._startTime
|
| 7297 |
+
? e && (this.startTime = t - this._currentTime / this.playbackRate)
|
| 7298 |
+
: this._isFinished ||
|
| 7299 |
+
this._tickCurrentTime((t - this._startTime) * this.playbackRate)),
|
| 7300 |
+
e && ((this._currentTimePending = !1), this._fireEvents(t))
|
| 7301 |
+
},
|
| 7302 |
+
get _needsTick() {
|
| 7303 |
+
return this.playState in { pending: 1, running: 1 } || !this._finishedFlag
|
| 7304 |
+
},
|
| 7305 |
+
_targetAnimations: function () {
|
| 7306 |
+
var t = this._effect._target
|
| 7307 |
+
return t._activeAnimations || (t._activeAnimations = []), t._activeAnimations
|
| 7308 |
+
},
|
| 7309 |
+
_markTarget: function () {
|
| 7310 |
+
var t = this._targetAnimations()
|
| 7311 |
+
;-1 === t.indexOf(this) && t.push(this)
|
| 7312 |
+
},
|
| 7313 |
+
_unmarkTarget: function () {
|
| 7314 |
+
var t = this._targetAnimations(),
|
| 7315 |
+
e = t.indexOf(this)
|
| 7316 |
+
;-1 !== e && t.splice(e, 1)
|
| 7317 |
+
},
|
| 7318 |
+
})
|
| 7319 |
+
})(rn, sn),
|
| 7320 |
+
(function (t, e, i) {
|
| 7321 |
+
function n(t) {
|
| 7322 |
+
var e = h
|
| 7323 |
+
;(h = []),
|
| 7324 |
+
t < _.currentTime && (t = _.currentTime),
|
| 7325 |
+
_._animations.sort(r),
|
| 7326 |
+
(_._animations = a(t, !0, _._animations)[0]),
|
| 7327 |
+
e.forEach(function (e) {
|
| 7328 |
+
e[1](t)
|
| 7329 |
+
}),
|
| 7330 |
+
o()
|
| 7331 |
+
}
|
| 7332 |
+
function r(t, e) {
|
| 7333 |
+
return t._sequenceNumber - e._sequenceNumber
|
| 7334 |
+
}
|
| 7335 |
+
function s() {
|
| 7336 |
+
;(this._animations = []),
|
| 7337 |
+
(this.currentTime = window.performance && performance.now ? performance.now() : 0)
|
| 7338 |
+
}
|
| 7339 |
+
function o() {
|
| 7340 |
+
f.forEach(function (t) {
|
| 7341 |
+
t()
|
| 7342 |
+
}),
|
| 7343 |
+
(f.length = 0)
|
| 7344 |
+
}
|
| 7345 |
+
function a(t, i, n) {
|
| 7346 |
+
;(p = !0), (d = !1), (e.timeline.currentTime = t), (c = !1)
|
| 7347 |
+
var r = [],
|
| 7348 |
+
s = [],
|
| 7349 |
+
o = [],
|
| 7350 |
+
a = []
|
| 7351 |
+
return (
|
| 7352 |
+
n.forEach(function (e) {
|
| 7353 |
+
e._tick(t, i),
|
| 7354 |
+
e._inEffect
|
| 7355 |
+
? (s.push(e._effect), e._markTarget())
|
| 7356 |
+
: (r.push(e._effect), e._unmarkTarget()),
|
| 7357 |
+
e._needsTick && (c = !0)
|
| 7358 |
+
var n = e._inEffect || e._needsTick
|
| 7359 |
+
;(e._inTimeline = n), n ? o.push(e) : a.push(e)
|
| 7360 |
+
}),
|
| 7361 |
+
f.push.apply(f, r),
|
| 7362 |
+
f.push.apply(f, s),
|
| 7363 |
+
c && requestAnimationFrame(function () {}),
|
| 7364 |
+
(p = !1),
|
| 7365 |
+
[o, a]
|
| 7366 |
+
)
|
| 7367 |
+
}
|
| 7368 |
+
var l = window.requestAnimationFrame,
|
| 7369 |
+
h = [],
|
| 7370 |
+
u = 0
|
| 7371 |
+
;(window.requestAnimationFrame = function (t) {
|
| 7372 |
+
var e = u++
|
| 7373 |
+
return 0 == h.length && l(n), h.push([e, t]), e
|
| 7374 |
+
}),
|
| 7375 |
+
(window.cancelAnimationFrame = function (t) {
|
| 7376 |
+
h.forEach(function (e) {
|
| 7377 |
+
e[0] == t && (e[1] = function () {})
|
| 7378 |
+
})
|
| 7379 |
+
}),
|
| 7380 |
+
(s.prototype = {
|
| 7381 |
+
_play: function (i) {
|
| 7382 |
+
i._timing = t.normalizeTimingInput(i.timing)
|
| 7383 |
+
var n = new e.Animation(i)
|
| 7384 |
+
return (
|
| 7385 |
+
(n._idle = !1),
|
| 7386 |
+
(n._timeline = this),
|
| 7387 |
+
this._animations.push(n),
|
| 7388 |
+
e.restart(),
|
| 7389 |
+
e.applyDirtiedAnimation(n),
|
| 7390 |
+
n
|
| 7391 |
+
)
|
| 7392 |
+
},
|
| 7393 |
+
})
|
| 7394 |
+
var c = !1,
|
| 7395 |
+
d = !1
|
| 7396 |
+
;(e.restart = function () {
|
| 7397 |
+
return c || ((c = !0), requestAnimationFrame(function () {}), (d = !0)), d
|
| 7398 |
+
}),
|
| 7399 |
+
(e.applyDirtiedAnimation = function (t) {
|
| 7400 |
+
if (!p) {
|
| 7401 |
+
t._markTarget()
|
| 7402 |
+
var i = t._targetAnimations()
|
| 7403 |
+
i.sort(r),
|
| 7404 |
+
a(e.timeline.currentTime, !1, i.slice())[1].forEach(function (t) {
|
| 7405 |
+
var e = _._animations.indexOf(t)
|
| 7406 |
+
;-1 !== e && _._animations.splice(e, 1)
|
| 7407 |
+
}),
|
| 7408 |
+
o()
|
| 7409 |
+
}
|
| 7410 |
+
})
|
| 7411 |
+
var f = [],
|
| 7412 |
+
p = !1,
|
| 7413 |
+
_ = new s()
|
| 7414 |
+
e.timeline = _
|
| 7415 |
+
})(rn, sn),
|
| 7416 |
+
(function (t, e) {
|
| 7417 |
+
function i(t, e) {
|
| 7418 |
+
for (var i = 0, n = 0; n < t.length; n++) i += t[n] * e[n]
|
| 7419 |
+
return i
|
| 7420 |
+
}
|
| 7421 |
+
function n(t, e) {
|
| 7422 |
+
return [
|
| 7423 |
+
t[0] * e[0] + t[4] * e[1] + t[8] * e[2] + t[12] * e[3],
|
| 7424 |
+
t[1] * e[0] + t[5] * e[1] + t[9] * e[2] + t[13] * e[3],
|
| 7425 |
+
t[2] * e[0] + t[6] * e[1] + t[10] * e[2] + t[14] * e[3],
|
| 7426 |
+
t[3] * e[0] + t[7] * e[1] + t[11] * e[2] + t[15] * e[3],
|
| 7427 |
+
t[0] * e[4] + t[4] * e[5] + t[8] * e[6] + t[12] * e[7],
|
| 7428 |
+
t[1] * e[4] + t[5] * e[5] + t[9] * e[6] + t[13] * e[7],
|
| 7429 |
+
t[2] * e[4] + t[6] * e[5] + t[10] * e[6] + t[14] * e[7],
|
| 7430 |
+
t[3] * e[4] + t[7] * e[5] + t[11] * e[6] + t[15] * e[7],
|
| 7431 |
+
t[0] * e[8] + t[4] * e[9] + t[8] * e[10] + t[12] * e[11],
|
| 7432 |
+
t[1] * e[8] + t[5] * e[9] + t[9] * e[10] + t[13] * e[11],
|
| 7433 |
+
t[2] * e[8] + t[6] * e[9] + t[10] * e[10] + t[14] * e[11],
|
| 7434 |
+
t[3] * e[8] + t[7] * e[9] + t[11] * e[10] + t[15] * e[11],
|
| 7435 |
+
t[0] * e[12] + t[4] * e[13] + t[8] * e[14] + t[12] * e[15],
|
| 7436 |
+
t[1] * e[12] + t[5] * e[13] + t[9] * e[14] + t[13] * e[15],
|
| 7437 |
+
t[2] * e[12] + t[6] * e[13] + t[10] * e[14] + t[14] * e[15],
|
| 7438 |
+
t[3] * e[12] + t[7] * e[13] + t[11] * e[14] + t[15] * e[15],
|
| 7439 |
+
]
|
| 7440 |
+
}
|
| 7441 |
+
function r(t) {
|
| 7442 |
+
var e = t.rad || 0
|
| 7443 |
+
return ((t.deg || 0) / 360 + (t.grad || 0) / 400 + (t.turn || 0)) * (2 * Math.PI) + e
|
| 7444 |
+
}
|
| 7445 |
+
function s(t) {
|
| 7446 |
+
switch (t.t) {
|
| 7447 |
+
case 'rotatex':
|
| 7448 |
+
var e = r(t.d[0])
|
| 7449 |
+
return [
|
| 7450 |
+
1,
|
| 7451 |
+
0,
|
| 7452 |
+
0,
|
| 7453 |
+
0,
|
| 7454 |
+
0,
|
| 7455 |
+
Math.cos(e),
|
| 7456 |
+
Math.sin(e),
|
| 7457 |
+
0,
|
| 7458 |
+
0,
|
| 7459 |
+
-Math.sin(e),
|
| 7460 |
+
Math.cos(e),
|
| 7461 |
+
0,
|
| 7462 |
+
0,
|
| 7463 |
+
0,
|
| 7464 |
+
0,
|
| 7465 |
+
1,
|
| 7466 |
+
]
|
| 7467 |
+
case 'rotatey':
|
| 7468 |
+
return (
|
| 7469 |
+
(e = r(t.d[0])),
|
| 7470 |
+
[
|
| 7471 |
+
Math.cos(e),
|
| 7472 |
+
0,
|
| 7473 |
+
-Math.sin(e),
|
| 7474 |
+
0,
|
| 7475 |
+
0,
|
| 7476 |
+
1,
|
| 7477 |
+
0,
|
| 7478 |
+
0,
|
| 7479 |
+
Math.sin(e),
|
| 7480 |
+
0,
|
| 7481 |
+
Math.cos(e),
|
| 7482 |
+
0,
|
| 7483 |
+
0,
|
| 7484 |
+
0,
|
| 7485 |
+
0,
|
| 7486 |
+
1,
|
| 7487 |
+
]
|
| 7488 |
+
)
|
| 7489 |
+
case 'rotate':
|
| 7490 |
+
case 'rotatez':
|
| 7491 |
+
return (
|
| 7492 |
+
(e = r(t.d[0])),
|
| 7493 |
+
[
|
| 7494 |
+
Math.cos(e),
|
| 7495 |
+
Math.sin(e),
|
| 7496 |
+
0,
|
| 7497 |
+
0,
|
| 7498 |
+
-Math.sin(e),
|
| 7499 |
+
Math.cos(e),
|
| 7500 |
+
0,
|
| 7501 |
+
0,
|
| 7502 |
+
0,
|
| 7503 |
+
0,
|
| 7504 |
+
1,
|
| 7505 |
+
0,
|
| 7506 |
+
0,
|
| 7507 |
+
0,
|
| 7508 |
+
0,
|
| 7509 |
+
1,
|
| 7510 |
+
]
|
| 7511 |
+
)
|
| 7512 |
+
case 'rotate3d':
|
| 7513 |
+
var i = t.d[0],
|
| 7514 |
+
n = t.d[1],
|
| 7515 |
+
s = t.d[2],
|
| 7516 |
+
o = ((e = r(t.d[3])), i * i + n * n + s * s)
|
| 7517 |
+
if (0 === o) (i = 1), (n = 0), (s = 0)
|
| 7518 |
+
else if (1 !== o) {
|
| 7519 |
+
var a = Math.sqrt(o)
|
| 7520 |
+
;(i /= a), (n /= a), (s /= a)
|
| 7521 |
+
}
|
| 7522 |
+
var l = Math.sin(e / 2),
|
| 7523 |
+
h = l * Math.cos(e / 2),
|
| 7524 |
+
u = l * l
|
| 7525 |
+
return [
|
| 7526 |
+
1 - 2 * (n * n + s * s) * u,
|
| 7527 |
+
2 * (i * n * u + s * h),
|
| 7528 |
+
2 * (i * s * u - n * h),
|
| 7529 |
+
0,
|
| 7530 |
+
2 * (i * n * u - s * h),
|
| 7531 |
+
1 - 2 * (i * i + s * s) * u,
|
| 7532 |
+
2 * (n * s * u + i * h),
|
| 7533 |
+
0,
|
| 7534 |
+
2 * (i * s * u + n * h),
|
| 7535 |
+
2 * (n * s * u - i * h),
|
| 7536 |
+
1 - 2 * (i * i + n * n) * u,
|
| 7537 |
+
0,
|
| 7538 |
+
0,
|
| 7539 |
+
0,
|
| 7540 |
+
0,
|
| 7541 |
+
1,
|
| 7542 |
+
]
|
| 7543 |
+
case 'scale':
|
| 7544 |
+
return [t.d[0], 0, 0, 0, 0, t.d[1], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7545 |
+
case 'scalex':
|
| 7546 |
+
return [t.d[0], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7547 |
+
case 'scaley':
|
| 7548 |
+
return [1, 0, 0, 0, 0, t.d[0], 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7549 |
+
case 'scalez':
|
| 7550 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, t.d[0], 0, 0, 0, 0, 1]
|
| 7551 |
+
case 'scale3d':
|
| 7552 |
+
return [t.d[0], 0, 0, 0, 0, t.d[1], 0, 0, 0, 0, t.d[2], 0, 0, 0, 0, 1]
|
| 7553 |
+
case 'skew':
|
| 7554 |
+
var c = r(t.d[0]),
|
| 7555 |
+
d = r(t.d[1])
|
| 7556 |
+
return [1, Math.tan(d), 0, 0, Math.tan(c), 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7557 |
+
case 'skewx':
|
| 7558 |
+
return (e = r(t.d[0])), [1, 0, 0, 0, Math.tan(e), 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7559 |
+
case 'skewy':
|
| 7560 |
+
return (e = r(t.d[0])), [1, Math.tan(e), 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]
|
| 7561 |
+
case 'translate':
|
| 7562 |
+
return [
|
| 7563 |
+
1,
|
| 7564 |
+
0,
|
| 7565 |
+
0,
|
| 7566 |
+
0,
|
| 7567 |
+
0,
|
| 7568 |
+
1,
|
| 7569 |
+
0,
|
| 7570 |
+
0,
|
| 7571 |
+
0,
|
| 7572 |
+
0,
|
| 7573 |
+
1,
|
| 7574 |
+
0,
|
| 7575 |
+
(i = t.d[0].px || 0),
|
| 7576 |
+
(n = t.d[1].px || 0),
|
| 7577 |
+
0,
|
| 7578 |
+
1,
|
| 7579 |
+
]
|
| 7580 |
+
case 'translatex':
|
| 7581 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, (i = t.d[0].px || 0), 0, 0, 1]
|
| 7582 |
+
case 'translatey':
|
| 7583 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, (n = t.d[0].px || 0), 0, 1]
|
| 7584 |
+
case 'translatez':
|
| 7585 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, (s = t.d[0].px || 0), 1]
|
| 7586 |
+
case 'translate3d':
|
| 7587 |
+
return [
|
| 7588 |
+
1,
|
| 7589 |
+
0,
|
| 7590 |
+
0,
|
| 7591 |
+
0,
|
| 7592 |
+
0,
|
| 7593 |
+
1,
|
| 7594 |
+
0,
|
| 7595 |
+
0,
|
| 7596 |
+
0,
|
| 7597 |
+
0,
|
| 7598 |
+
1,
|
| 7599 |
+
0,
|
| 7600 |
+
(i = t.d[0].px || 0),
|
| 7601 |
+
(n = t.d[1].px || 0),
|
| 7602 |
+
(s = t.d[2].px || 0),
|
| 7603 |
+
1,
|
| 7604 |
+
]
|
| 7605 |
+
case 'perspective':
|
| 7606 |
+
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, t.d[0].px ? -1 / t.d[0].px : 0, 0, 0, 0, 1]
|
| 7607 |
+
case 'matrix':
|
| 7608 |
+
return [t.d[0], t.d[1], 0, 0, t.d[2], t.d[3], 0, 0, 0, 0, 1, 0, t.d[4], t.d[5], 0, 1]
|
| 7609 |
+
case 'matrix3d':
|
| 7610 |
+
return t.d
|
| 7611 |
+
}
|
| 7612 |
+
}
|
| 7613 |
+
function o(t) {
|
| 7614 |
+
return 0 === t.length ? [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1] : t.map(s).reduce(n)
|
| 7615 |
+
}
|
| 7616 |
+
var a = (function () {
|
| 7617 |
+
function t(t) {
|
| 7618 |
+
return (
|
| 7619 |
+
t[0][0] * t[1][1] * t[2][2] +
|
| 7620 |
+
t[1][0] * t[2][1] * t[0][2] +
|
| 7621 |
+
t[2][0] * t[0][1] * t[1][2] -
|
| 7622 |
+
t[0][2] * t[1][1] * t[2][0] -
|
| 7623 |
+
t[1][2] * t[2][1] * t[0][0] -
|
| 7624 |
+
t[2][2] * t[0][1] * t[1][0]
|
| 7625 |
+
)
|
| 7626 |
+
}
|
| 7627 |
+
function e(t) {
|
| 7628 |
+
var e = n(t)
|
| 7629 |
+
return [t[0] / e, t[1] / e, t[2] / e]
|
| 7630 |
+
}
|
| 7631 |
+
function n(t) {
|
| 7632 |
+
return Math.sqrt(t[0] * t[0] + t[1] * t[1] + t[2] * t[2])
|
| 7633 |
+
}
|
| 7634 |
+
function r(t, e, i, n) {
|
| 7635 |
+
return [i * t[0] + n * e[0], i * t[1] + n * e[1], i * t[2] + n * e[2]]
|
| 7636 |
+
}
|
| 7637 |
+
return function (s) {
|
| 7638 |
+
var o = [s.slice(0, 4), s.slice(4, 8), s.slice(8, 12), s.slice(12, 16)]
|
| 7639 |
+
if (1 !== o[3][3]) return null
|
| 7640 |
+
for (var a = [], l = 0; l < 4; l++) a.push(o[l].slice())
|
| 7641 |
+
for (l = 0; l < 3; l++) a[l][3] = 0
|
| 7642 |
+
if (0 === t(a)) return null
|
| 7643 |
+
var h,
|
| 7644 |
+
u = []
|
| 7645 |
+
o[0][3] || o[1][3] || o[2][3]
|
| 7646 |
+
? (u.push(o[0][3]),
|
| 7647 |
+
u.push(o[1][3]),
|
| 7648 |
+
u.push(o[2][3]),
|
| 7649 |
+
u.push(o[3][3]),
|
| 7650 |
+
(h = (function (t, e) {
|
| 7651 |
+
for (var i = [], n = 0; n < 4; n++) {
|
| 7652 |
+
for (var r = 0, s = 0; s < 4; s++) r += t[s] * e[s][n]
|
| 7653 |
+
i.push(r)
|
| 7654 |
+
}
|
| 7655 |
+
return i
|
| 7656 |
+
})(
|
| 7657 |
+
u,
|
| 7658 |
+
(function (t) {
|
| 7659 |
+
return [
|
| 7660 |
+
[t[0][0], t[1][0], t[2][0], t[3][0]],
|
| 7661 |
+
[t[0][1], t[1][1], t[2][1], t[3][1]],
|
| 7662 |
+
[t[0][2], t[1][2], t[2][2], t[3][2]],
|
| 7663 |
+
[t[0][3], t[1][3], t[2][3], t[3][3]],
|
| 7664 |
+
]
|
| 7665 |
+
})(
|
| 7666 |
+
(function (e) {
|
| 7667 |
+
for (
|
| 7668 |
+
var i = 1 / t(e),
|
| 7669 |
+
n = e[0][0],
|
| 7670 |
+
r = e[0][1],
|
| 7671 |
+
s = e[0][2],
|
| 7672 |
+
o = e[1][0],
|
| 7673 |
+
a = e[1][1],
|
| 7674 |
+
l = e[1][2],
|
| 7675 |
+
h = e[2][0],
|
| 7676 |
+
u = e[2][1],
|
| 7677 |
+
c = e[2][2],
|
| 7678 |
+
d = [
|
| 7679 |
+
[
|
| 7680 |
+
(a * c - l * u) * i,
|
| 7681 |
+
(s * u - r * c) * i,
|
| 7682 |
+
(r * l - s * a) * i,
|
| 7683 |
+
0,
|
| 7684 |
+
],
|
| 7685 |
+
[
|
| 7686 |
+
(l * h - o * c) * i,
|
| 7687 |
+
(n * c - s * h) * i,
|
| 7688 |
+
(s * o - n * l) * i,
|
| 7689 |
+
0,
|
| 7690 |
+
],
|
| 7691 |
+
[
|
| 7692 |
+
(o * u - a * h) * i,
|
| 7693 |
+
(h * r - n * u) * i,
|
| 7694 |
+
(n * a - r * o) * i,
|
| 7695 |
+
0,
|
| 7696 |
+
],
|
| 7697 |
+
],
|
| 7698 |
+
f = [],
|
| 7699 |
+
p = 0;
|
| 7700 |
+
p < 3;
|
| 7701 |
+
p++
|
| 7702 |
+
) {
|
| 7703 |
+
for (var _ = 0, m = 0; m < 3; m++) _ += e[3][m] * d[m][p]
|
| 7704 |
+
f.push(_)
|
| 7705 |
+
}
|
| 7706 |
+
return f.push(1), d.push(f), d
|
| 7707 |
+
})(a),
|
| 7708 |
+
),
|
| 7709 |
+
)))
|
| 7710 |
+
: (h = [0, 0, 0, 1])
|
| 7711 |
+
var c = o[3].slice(0, 3),
|
| 7712 |
+
d = []
|
| 7713 |
+
d.push(o[0].slice(0, 3))
|
| 7714 |
+
var f = []
|
| 7715 |
+
f.push(n(d[0])), (d[0] = e(d[0]))
|
| 7716 |
+
var p = []
|
| 7717 |
+
d.push(o[1].slice(0, 3)),
|
| 7718 |
+
p.push(i(d[0], d[1])),
|
| 7719 |
+
(d[1] = r(d[1], d[0], 1, -p[0])),
|
| 7720 |
+
f.push(n(d[1])),
|
| 7721 |
+
(d[1] = e(d[1])),
|
| 7722 |
+
(p[0] /= f[1]),
|
| 7723 |
+
d.push(o[2].slice(0, 3)),
|
| 7724 |
+
p.push(i(d[0], d[2])),
|
| 7725 |
+
(d[2] = r(d[2], d[0], 1, -p[1])),
|
| 7726 |
+
p.push(i(d[1], d[2])),
|
| 7727 |
+
(d[2] = r(d[2], d[1], 1, -p[2])),
|
| 7728 |
+
f.push(n(d[2])),
|
| 7729 |
+
(d[2] = e(d[2])),
|
| 7730 |
+
(p[1] /= f[2]),
|
| 7731 |
+
(p[2] /= f[2])
|
| 7732 |
+
var _ = (function (t, e) {
|
| 7733 |
+
return [t[1] * e[2] - t[2] * e[1], t[2] * e[0] - t[0] * e[2], t[0] * e[1] - t[1] * e[0]]
|
| 7734 |
+
})(d[1], d[2])
|
| 7735 |
+
if (i(d[0], _) < 0)
|
| 7736 |
+
for (l = 0; l < 3; l++) (f[l] *= -1), (d[l][0] *= -1), (d[l][1] *= -1), (d[l][2] *= -1)
|
| 7737 |
+
var m,
|
| 7738 |
+
g,
|
| 7739 |
+
v = d[0][0] + d[1][1] + d[2][2] + 1
|
| 7740 |
+
return (
|
| 7741 |
+
v > 1e-4
|
| 7742 |
+
? ((m = 0.5 / Math.sqrt(v)),
|
| 7743 |
+
(g = [
|
| 7744 |
+
(d[2][1] - d[1][2]) * m,
|
| 7745 |
+
(d[0][2] - d[2][0]) * m,
|
| 7746 |
+
(d[1][0] - d[0][1]) * m,
|
| 7747 |
+
0.25 / m,
|
| 7748 |
+
]))
|
| 7749 |
+
: d[0][0] > d[1][1] && d[0][0] > d[2][2]
|
| 7750 |
+
? (g = [
|
| 7751 |
+
0.25 * (m = 2 * Math.sqrt(1 + d[0][0] - d[1][1] - d[2][2])),
|
| 7752 |
+
(d[0][1] + d[1][0]) / m,
|
| 7753 |
+
(d[0][2] + d[2][0]) / m,
|
| 7754 |
+
(d[2][1] - d[1][2]) / m,
|
| 7755 |
+
])
|
| 7756 |
+
: d[1][1] > d[2][2]
|
| 7757 |
+
? ((m = 2 * Math.sqrt(1 + d[1][1] - d[0][0] - d[2][2])),
|
| 7758 |
+
(g = [
|
| 7759 |
+
(d[0][1] + d[1][0]) / m,
|
| 7760 |
+
0.25 * m,
|
| 7761 |
+
(d[1][2] + d[2][1]) / m,
|
| 7762 |
+
(d[0][2] - d[2][0]) / m,
|
| 7763 |
+
]))
|
| 7764 |
+
: ((m = 2 * Math.sqrt(1 + d[2][2] - d[0][0] - d[1][1])),
|
| 7765 |
+
(g = [
|
| 7766 |
+
(d[0][2] + d[2][0]) / m,
|
| 7767 |
+
(d[1][2] + d[2][1]) / m,
|
| 7768 |
+
0.25 * m,
|
| 7769 |
+
(d[1][0] - d[0][1]) / m,
|
| 7770 |
+
])),
|
| 7771 |
+
[c, f, p, g, h]
|
| 7772 |
+
)
|
| 7773 |
+
}
|
| 7774 |
+
})()
|
| 7775 |
+
;(t.dot = i),
|
| 7776 |
+
(t.makeMatrixDecomposition = function (t) {
|
| 7777 |
+
return [a(o(t))]
|
| 7778 |
+
}),
|
| 7779 |
+
(t.transformListToMatrix = o)
|
| 7780 |
+
})(sn),
|
| 7781 |
+
(function (t) {
|
| 7782 |
+
function e(t, e) {
|
| 7783 |
+
var i = t.exec(e)
|
| 7784 |
+
if (i) return [(i = t.ignoreCase ? i[0].toLowerCase() : i[0]), e.substr(i.length)]
|
| 7785 |
+
}
|
| 7786 |
+
function i(t, e) {
|
| 7787 |
+
var i = t((e = e.replace(/^\s*/, '')))
|
| 7788 |
+
if (i) return [i[0], i[1].replace(/^\s*/, '')]
|
| 7789 |
+
}
|
| 7790 |
+
function n(t, e, i, n, r) {
|
| 7791 |
+
for (
|
| 7792 |
+
var s = [],
|
| 7793 |
+
o = [],
|
| 7794 |
+
a = [],
|
| 7795 |
+
l = (function (t, e) {
|
| 7796 |
+
for (var i = t, n = e; i && n; ) i > n ? (i %= n) : (n %= i)
|
| 7797 |
+
return (t * e) / (i + n)
|
| 7798 |
+
})(n.length, r.length),
|
| 7799 |
+
h = 0;
|
| 7800 |
+
h < l;
|
| 7801 |
+
h++
|
| 7802 |
+
) {
|
| 7803 |
+
var u = e(n[h % n.length], r[h % r.length])
|
| 7804 |
+
if (!u) return
|
| 7805 |
+
s.push(u[0]), o.push(u[1]), a.push(u[2])
|
| 7806 |
+
}
|
| 7807 |
+
return [
|
| 7808 |
+
s,
|
| 7809 |
+
o,
|
| 7810 |
+
function (e) {
|
| 7811 |
+
var n = e
|
| 7812 |
+
.map(function (t, e) {
|
| 7813 |
+
return a[e](t)
|
| 7814 |
+
})
|
| 7815 |
+
.join(i)
|
| 7816 |
+
return t ? t(n) : n
|
| 7817 |
+
},
|
| 7818 |
+
]
|
| 7819 |
+
}
|
| 7820 |
+
;(t.consumeToken = e),
|
| 7821 |
+
(t.consumeTrimmed = i),
|
| 7822 |
+
(t.consumeRepeated = function (t, n, r) {
|
| 7823 |
+
t = i.bind(null, t)
|
| 7824 |
+
for (var s = []; ; ) {
|
| 7825 |
+
var o = t(r)
|
| 7826 |
+
if (!o) return [s, r]
|
| 7827 |
+
if ((s.push(o[0]), !(o = e(n, (r = o[1]))) || '' == o[1])) return [s, r]
|
| 7828 |
+
r = o[1]
|
| 7829 |
+
}
|
| 7830 |
+
}),
|
| 7831 |
+
(t.consumeParenthesised = function (t, e) {
|
| 7832 |
+
for (var i = 0, n = 0; n < e.length && (!/\s|,/.test(e[n]) || 0 != i); n++)
|
| 7833 |
+
if ('(' == e[n]) i++
|
| 7834 |
+
else if (')' == e[n] && (0 == --i && n++, i <= 0)) break
|
| 7835 |
+
var r = t(e.substr(0, n))
|
| 7836 |
+
return null == r ? void 0 : [r, e.substr(n)]
|
| 7837 |
+
}),
|
| 7838 |
+
(t.ignore = function (t) {
|
| 7839 |
+
return function (e) {
|
| 7840 |
+
var i = t(e)
|
| 7841 |
+
return i && (i[0] = void 0), i
|
| 7842 |
+
}
|
| 7843 |
+
}),
|
| 7844 |
+
(t.optional = function (t, e) {
|
| 7845 |
+
return function (i) {
|
| 7846 |
+
return t(i) || [e, i]
|
| 7847 |
+
}
|
| 7848 |
+
}),
|
| 7849 |
+
(t.consumeList = function (e, i) {
|
| 7850 |
+
for (var n = [], r = 0; r < e.length; r++) {
|
| 7851 |
+
var s = t.consumeTrimmed(e[r], i)
|
| 7852 |
+
if (!s || '' == s[0]) return
|
| 7853 |
+
void 0 !== s[0] && n.push(s[0]), (i = s[1])
|
| 7854 |
+
}
|
| 7855 |
+
if ('' == i) return n
|
| 7856 |
+
}),
|
| 7857 |
+
(t.mergeNestedRepeated = n.bind(null, null)),
|
| 7858 |
+
(t.mergeWrappedNestedRepeated = n),
|
| 7859 |
+
(t.mergeList = function (t, e, i) {
|
| 7860 |
+
for (var n = [], r = [], s = [], o = 0, a = 0; a < i.length; a++)
|
| 7861 |
+
if ('function' == typeof i[a]) {
|
| 7862 |
+
var l = i[a](t[o], e[o++])
|
| 7863 |
+
n.push(l[0]), r.push(l[1]), s.push(l[2])
|
| 7864 |
+
} else
|
| 7865 |
+
!(function (t) {
|
| 7866 |
+
n.push(!1),
|
| 7867 |
+
r.push(!1),
|
| 7868 |
+
s.push(function () {
|
| 7869 |
+
return i[t]
|
| 7870 |
+
})
|
| 7871 |
+
})(a)
|
| 7872 |
+
return [
|
| 7873 |
+
n,
|
| 7874 |
+
r,
|
| 7875 |
+
function (t) {
|
| 7876 |
+
for (var e = '', i = 0; i < t.length; i++) e += s[i](t[i])
|
| 7877 |
+
return e
|
| 7878 |
+
},
|
| 7879 |
+
]
|
| 7880 |
+
})
|
| 7881 |
+
})(sn),
|
| 7882 |
+
(function (t) {
|
| 7883 |
+
function e(e) {
|
| 7884 |
+
var i = { inset: !1, lengths: [], color: null },
|
| 7885 |
+
n = t.consumeRepeated(
|
| 7886 |
+
function (e) {
|
| 7887 |
+
var n = t.consumeToken(/^inset/i, e)
|
| 7888 |
+
return n
|
| 7889 |
+
? ((i.inset = !0), n)
|
| 7890 |
+
: (n = t.consumeLengthOrPercent(e))
|
| 7891 |
+
? (i.lengths.push(n[0]), n)
|
| 7892 |
+
: (n = t.consumeColor(e))
|
| 7893 |
+
? ((i.color = n[0]), n)
|
| 7894 |
+
: void 0
|
| 7895 |
+
},
|
| 7896 |
+
/^/,
|
| 7897 |
+
e,
|
| 7898 |
+
)
|
| 7899 |
+
if (n && n[0].length) return [i, n[1]]
|
| 7900 |
+
}
|
| 7901 |
+
var i = function (e, i, n, r) {
|
| 7902 |
+
function s(t) {
|
| 7903 |
+
return {
|
| 7904 |
+
inset: t,
|
| 7905 |
+
color: [0, 0, 0, 0],
|
| 7906 |
+
lengths: [{ px: 0 }, { px: 0 }, { px: 0 }, { px: 0 }],
|
| 7907 |
+
}
|
| 7908 |
+
}
|
| 7909 |
+
for (var o = [], a = [], l = 0; l < n.length || l < r.length; l++) {
|
| 7910 |
+
var h = n[l] || s(r[l].inset),
|
| 7911 |
+
u = r[l] || s(n[l].inset)
|
| 7912 |
+
o.push(h), a.push(u)
|
| 7913 |
+
}
|
| 7914 |
+
return t.mergeNestedRepeated(e, i, o, a)
|
| 7915 |
+
}.bind(
|
| 7916 |
+
null,
|
| 7917 |
+
function (e, i) {
|
| 7918 |
+
for (; e.lengths.length < Math.max(e.lengths.length, i.lengths.length); )
|
| 7919 |
+
e.lengths.push({ px: 0 })
|
| 7920 |
+
for (; i.lengths.length < Math.max(e.lengths.length, i.lengths.length); )
|
| 7921 |
+
i.lengths.push({ px: 0 })
|
| 7922 |
+
if (e.inset == i.inset && !!e.color == !!i.color) {
|
| 7923 |
+
for (var n, r = [], s = [[], 0], o = [[], 0], a = 0; a < e.lengths.length; a++) {
|
| 7924 |
+
var l = t.mergeDimensions(e.lengths[a], i.lengths[a], 2 == a)
|
| 7925 |
+
s[0].push(l[0]), o[0].push(l[1]), r.push(l[2])
|
| 7926 |
+
}
|
| 7927 |
+
if (e.color && i.color) {
|
| 7928 |
+
var h = t.mergeColors(e.color, i.color)
|
| 7929 |
+
;(s[1] = h[0]), (o[1] = h[1]), (n = h[2])
|
| 7930 |
+
}
|
| 7931 |
+
return [
|
| 7932 |
+
s,
|
| 7933 |
+
o,
|
| 7934 |
+
function (t) {
|
| 7935 |
+
for (var i = e.inset ? 'inset ' : ' ', s = 0; s < r.length; s++)
|
| 7936 |
+
i += r[s](t[0][s]) + ' '
|
| 7937 |
+
return n && (i += n(t[1])), i
|
| 7938 |
+
},
|
| 7939 |
+
]
|
| 7940 |
+
}
|
| 7941 |
+
},
|
| 7942 |
+
', ',
|
| 7943 |
+
)
|
| 7944 |
+
t.addPropertiesHandler(
|
| 7945 |
+
function (i) {
|
| 7946 |
+
var n = t.consumeRepeated(e, /^,/, i)
|
| 7947 |
+
if (n && '' == n[1]) return n[0]
|
| 7948 |
+
},
|
| 7949 |
+
i,
|
| 7950 |
+
['box-shadow', 'text-shadow'],
|
| 7951 |
+
)
|
| 7952 |
+
})(sn),
|
| 7953 |
+
(function (t, e) {
|
| 7954 |
+
function i(t) {
|
| 7955 |
+
return t.toFixed(3).replace(/0+$/, '').replace(/\.$/, '')
|
| 7956 |
+
}
|
| 7957 |
+
function n(t, e, i) {
|
| 7958 |
+
return Math.min(e, Math.max(t, i))
|
| 7959 |
+
}
|
| 7960 |
+
function r(t) {
|
| 7961 |
+
if (/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t)) return Number(t)
|
| 7962 |
+
}
|
| 7963 |
+
function s(t, e) {
|
| 7964 |
+
return function (r, s) {
|
| 7965 |
+
return [
|
| 7966 |
+
r,
|
| 7967 |
+
s,
|
| 7968 |
+
function (r) {
|
| 7969 |
+
return i(n(t, e, r))
|
| 7970 |
+
},
|
| 7971 |
+
]
|
| 7972 |
+
}
|
| 7973 |
+
}
|
| 7974 |
+
function o(t) {
|
| 7975 |
+
var e = t.trim().split(/\s*[\s,]\s*/)
|
| 7976 |
+
if (0 !== e.length) {
|
| 7977 |
+
for (var i = [], n = 0; n < e.length; n++) {
|
| 7978 |
+
var s = r(e[n])
|
| 7979 |
+
if (void 0 === s) return
|
| 7980 |
+
i.push(s)
|
| 7981 |
+
}
|
| 7982 |
+
return i
|
| 7983 |
+
}
|
| 7984 |
+
}
|
| 7985 |
+
;(t.clamp = n),
|
| 7986 |
+
t.addPropertiesHandler(
|
| 7987 |
+
o,
|
| 7988 |
+
function (t, e) {
|
| 7989 |
+
if (t.length == e.length)
|
| 7990 |
+
return [
|
| 7991 |
+
t,
|
| 7992 |
+
e,
|
| 7993 |
+
function (t) {
|
| 7994 |
+
return t.map(i).join(' ')
|
| 7995 |
+
},
|
| 7996 |
+
]
|
| 7997 |
+
},
|
| 7998 |
+
['stroke-dasharray'],
|
| 7999 |
+
),
|
| 8000 |
+
t.addPropertiesHandler(r, s(0, 1 / 0), ['border-image-width', 'line-height']),
|
| 8001 |
+
t.addPropertiesHandler(r, s(0, 1), ['opacity', 'shape-image-threshold']),
|
| 8002 |
+
t.addPropertiesHandler(
|
| 8003 |
+
r,
|
| 8004 |
+
function (t, e) {
|
| 8005 |
+
if (0 != t) return s(0, 1 / 0)(t, e)
|
| 8006 |
+
},
|
| 8007 |
+
['flex-grow', 'flex-shrink'],
|
| 8008 |
+
),
|
| 8009 |
+
t.addPropertiesHandler(
|
| 8010 |
+
r,
|
| 8011 |
+
function (t, e) {
|
| 8012 |
+
return [
|
| 8013 |
+
t,
|
| 8014 |
+
e,
|
| 8015 |
+
function (t) {
|
| 8016 |
+
return Math.round(n(1, 1 / 0, t))
|
| 8017 |
+
},
|
| 8018 |
+
]
|
| 8019 |
+
},
|
| 8020 |
+
['orphans', 'widows'],
|
| 8021 |
+
),
|
| 8022 |
+
t.addPropertiesHandler(
|
| 8023 |
+
r,
|
| 8024 |
+
function (t, e) {
|
| 8025 |
+
return [t, e, Math.round]
|
| 8026 |
+
},
|
| 8027 |
+
['z-index'],
|
| 8028 |
+
),
|
| 8029 |
+
(t.parseNumber = r),
|
| 8030 |
+
(t.parseNumberList = o),
|
| 8031 |
+
(t.mergeNumbers = function (t, e) {
|
| 8032 |
+
return [t, e, i]
|
| 8033 |
+
}),
|
| 8034 |
+
(t.numberToString = i)
|
| 8035 |
+
})(sn),
|
| 8036 |
+
(function (t, e) {
|
| 8037 |
+
t.addPropertiesHandler(
|
| 8038 |
+
String,
|
| 8039 |
+
function (t, e) {
|
| 8040 |
+
if ('visible' == t || 'visible' == e)
|
| 8041 |
+
return [
|
| 8042 |
+
0,
|
| 8043 |
+
1,
|
| 8044 |
+
function (i) {
|
| 8045 |
+
return i <= 0 ? t : i >= 1 ? e : 'visible'
|
| 8046 |
+
},
|
| 8047 |
+
]
|
| 8048 |
+
},
|
| 8049 |
+
['visibility'],
|
| 8050 |
+
)
|
| 8051 |
+
})(sn),
|
| 8052 |
+
(function (t, e) {
|
| 8053 |
+
function i(t) {
|
| 8054 |
+
;(t = t.trim()), (s.fillStyle = '#000'), (s.fillStyle = t)
|
| 8055 |
+
var e = s.fillStyle
|
| 8056 |
+
if (((s.fillStyle = '#fff'), (s.fillStyle = t), e == s.fillStyle)) {
|
| 8057 |
+
s.fillRect(0, 0, 1, 1)
|
| 8058 |
+
var i = s.getImageData(0, 0, 1, 1).data
|
| 8059 |
+
s.clearRect(0, 0, 1, 1)
|
| 8060 |
+
var n = i[3] / 255
|
| 8061 |
+
return [i[0] * n, i[1] * n, i[2] * n, n]
|
| 8062 |
+
}
|
| 8063 |
+
}
|
| 8064 |
+
function n(e, i) {
|
| 8065 |
+
return [
|
| 8066 |
+
e,
|
| 8067 |
+
i,
|
| 8068 |
+
function (e) {
|
| 8069 |
+
function i(t) {
|
| 8070 |
+
return Math.max(0, Math.min(255, t))
|
| 8071 |
+
}
|
| 8072 |
+
if (e[3]) for (var n = 0; n < 3; n++) e[n] = Math.round(i(e[n] / e[3]))
|
| 8073 |
+
return (e[3] = t.numberToString(t.clamp(0, 1, e[3]))), 'rgba(' + e.join(',') + ')'
|
| 8074 |
+
},
|
| 8075 |
+
]
|
| 8076 |
+
}
|
| 8077 |
+
var r = document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas')
|
| 8078 |
+
r.width = r.height = 1
|
| 8079 |
+
var s = r.getContext('2d')
|
| 8080 |
+
t.addPropertiesHandler(i, n, [
|
| 8081 |
+
'background-color',
|
| 8082 |
+
'border-bottom-color',
|
| 8083 |
+
'border-left-color',
|
| 8084 |
+
'border-right-color',
|
| 8085 |
+
'border-top-color',
|
| 8086 |
+
'color',
|
| 8087 |
+
'fill',
|
| 8088 |
+
'flood-color',
|
| 8089 |
+
'lighting-color',
|
| 8090 |
+
'outline-color',
|
| 8091 |
+
'stop-color',
|
| 8092 |
+
'stroke',
|
| 8093 |
+
'text-decoration-color',
|
| 8094 |
+
]),
|
| 8095 |
+
(t.consumeColor = t.consumeParenthesised.bind(null, i)),
|
| 8096 |
+
(t.mergeColors = n)
|
| 8097 |
+
})(sn),
|
| 8098 |
+
(function (t, e) {
|
| 8099 |
+
function i(t) {
|
| 8100 |
+
function e() {
|
| 8101 |
+
var e = o.exec(t)
|
| 8102 |
+
s = e ? e[0] : void 0
|
| 8103 |
+
}
|
| 8104 |
+
function i() {
|
| 8105 |
+
if ('(' !== s)
|
| 8106 |
+
return (function () {
|
| 8107 |
+
var t = Number(s)
|
| 8108 |
+
return e(), t
|
| 8109 |
+
})()
|
| 8110 |
+
e()
|
| 8111 |
+
var t = r()
|
| 8112 |
+
return ')' !== s ? NaN : (e(), t)
|
| 8113 |
+
}
|
| 8114 |
+
function n() {
|
| 8115 |
+
for (var t = i(); '*' === s || '/' === s; ) {
|
| 8116 |
+
var n = s
|
| 8117 |
+
e()
|
| 8118 |
+
var r = i()
|
| 8119 |
+
'*' === n ? (t *= r) : (t /= r)
|
| 8120 |
+
}
|
| 8121 |
+
return t
|
| 8122 |
+
}
|
| 8123 |
+
function r() {
|
| 8124 |
+
for (var t = n(); '+' === s || '-' === s; ) {
|
| 8125 |
+
var i = s
|
| 8126 |
+
e()
|
| 8127 |
+
var r = n()
|
| 8128 |
+
'+' === i ? (t += r) : (t -= r)
|
| 8129 |
+
}
|
| 8130 |
+
return t
|
| 8131 |
+
}
|
| 8132 |
+
var s,
|
| 8133 |
+
o = /([\+\-\w\.]+|[\(\)\*\/])/g
|
| 8134 |
+
return e(), r()
|
| 8135 |
+
}
|
| 8136 |
+
function n(t, e) {
|
| 8137 |
+
if ('0' == (e = e.trim().toLowerCase()) && 'px'.search(t) >= 0) return { px: 0 }
|
| 8138 |
+
if (/^[^(]*$|^calc/.test(e)) {
|
| 8139 |
+
e = e.replace(/calc\(/g, '(')
|
| 8140 |
+
var n = {}
|
| 8141 |
+
e = e.replace(t, function (t) {
|
| 8142 |
+
return (n[t] = null), 'U' + t
|
| 8143 |
+
})
|
| 8144 |
+
for (
|
| 8145 |
+
var r = 'U(' + t.source + ')',
|
| 8146 |
+
s = e
|
| 8147 |
+
.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g, 'N')
|
| 8148 |
+
.replace(new RegExp('N' + r, 'g'), 'D')
|
| 8149 |
+
.replace(/\s[+-]\s/g, 'O')
|
| 8150 |
+
.replace(/\s/g, ''),
|
| 8151 |
+
o = [/N\*(D)/g, /(N|D)[*\/]N/g, /(N|D)O\1/g, /\((N|D)\)/g],
|
| 8152 |
+
a = 0;
|
| 8153 |
+
a < o.length;
|
| 8154 |
+
|
| 8155 |
+
)
|
| 8156 |
+
o[a].test(s) ? ((s = s.replace(o[a], '$1')), (a = 0)) : a++
|
| 8157 |
+
if ('D' == s) {
|
| 8158 |
+
for (var l in n) {
|
| 8159 |
+
var h = i(e.replace(new RegExp('U' + l
|
