clickgo 3.16.28 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -8
- package/dist/app/{demo/res/video.mp4 → demo.cga} +0 -0
- package/dist/app/task.cga +0 -0
- package/dist/control/arteditor.cgc +0 -0
- package/dist/control/box.cgc +0 -0
- package/dist/control/captcha.cgc +0 -0
- package/dist/control/common.cgc +0 -0
- package/dist/control/desc.cgc +0 -0
- package/dist/control/drawer.cgc +0 -0
- package/dist/control/echarts.cgc +0 -0
- package/dist/control/form.cgc +0 -0
- package/dist/control/iconview.cgc +0 -0
- package/dist/control/jodit.cgc +0 -0
- package/dist/control/map.cgc +0 -0
- package/dist/control/monaco.cgc +0 -0
- package/dist/control/mpegts.cgc +0 -0
- package/dist/control/nav.cgc +0 -0
- package/dist/control/novnc.cgc +0 -0
- package/dist/control/page.cgc +0 -0
- package/dist/control/pdf.cgc +0 -0
- package/dist/control/property.cgc +0 -0
- package/dist/control/qrcode.cgc +0 -0
- package/dist/control/table.cgc +0 -0
- package/dist/control/task.cgc +0 -0
- package/dist/control/tplink.cgc +0 -0
- package/dist/control/tuieditor.cgc +0 -0
- package/dist/control/tuiviewer.cgc +0 -0
- package/dist/control/tums.cgc +0 -0
- package/dist/control/xterm.cgc +0 -0
- package/dist/ext/tums-player/audio.wasm +0 -0
- package/dist/ext/tums-player/decoder.worker.js +129 -0
- package/dist/ext/tums-player/libaudio.js +1 -0
- package/dist/ext/tums-player/libaudio.wasm +0 -0
- package/dist/ext/tums-player/libffmpeg.js +1 -0
- package/dist/ext/tums-player/libffmpeg.wasm +0 -0
- package/dist/ext/tums-player/libs.worker.js +92 -0
- package/dist/ext/tums-player/tums-player.umd.min.js +35 -0
- package/dist/ext/tums-player/webgl.js +2 -0
- package/dist/ext/tums-player/webgl.worker.js +42 -0
- package/dist/global.css +1 -1
- package/dist/index.js +1 -175
- package/dist/theme/dark.cgt +0 -0
- package/dist/theme/light.cgt +0 -0
- package/package.json +16 -10
- package/dist/app/demo/app.js +0 -48
- package/dist/app/demo/config.json +0 -252
- package/dist/app/demo/form/control/alayout2/alayout2.js +0 -43
- package/dist/app/demo/form/control/alayout2/alayout2.xml +0 -16
- package/dist/app/demo/form/control/alert/alert.js +0 -43
- package/dist/app/demo/form/control/alert/alert.xml +0 -32
- package/dist/app/demo/form/control/arteditor/arteditor.js +0 -64
- package/dist/app/demo/form/control/arteditor/arteditor.xml +0 -12
- package/dist/app/demo/form/control/arteditor/img.js +0 -61
- package/dist/app/demo/form/control/arteditor/img.xml +0 -6
- package/dist/app/demo/form/control/block/block.css +0 -1
- package/dist/app/demo/form/control/block/block.scss +0 -17
- package/dist/app/demo/form/control/block/block.xml +0 -7
- package/dist/app/demo/form/control/box/box.js +0 -87
- package/dist/app/demo/form/control/box/box.xml +0 -23
- package/dist/app/demo/form/control/button/button.css +0 -1
- package/dist/app/demo/form/control/button/button.js +0 -51
- package/dist/app/demo/form/control/button/button.scss +0 -18
- package/dist/app/demo/form/control/button/button.xml +0 -133
- package/dist/app/demo/form/control/calendar/calendar.js +0 -62
- package/dist/app/demo/form/control/calendar/calendar.xml +0 -34
- package/dist/app/demo/form/control/captcha/captcha.js +0 -60
- package/dist/app/demo/form/control/captcha/captcha.xml +0 -10
- package/dist/app/demo/form/control/check/check.js +0 -54
- package/dist/app/demo/form/control/check/check.xml +0 -17
- package/dist/app/demo/form/control/circle/circle.xml +0 -36
- package/dist/app/demo/form/control/content/content.js +0 -47
- package/dist/app/demo/form/control/content/content.xml +0 -16
- package/dist/app/demo/form/control/date/date.js +0 -56
- package/dist/app/demo/form/control/date/date.xml +0 -28
- package/dist/app/demo/form/control/datepanel/datepanel.js +0 -63
- package/dist/app/demo/form/control/datepanel/datepanel.xml +0 -32
- package/dist/app/demo/form/control/daterange/daterange.js +0 -54
- package/dist/app/demo/form/control/daterange/daterange.xml +0 -22
- package/dist/app/demo/form/control/delete/delete.js +0 -47
- package/dist/app/demo/form/control/delete/delete.xml +0 -20
- package/dist/app/demo/form/control/desc/desc.js +0 -82
- package/dist/app/demo/form/control/desc/desc.xml +0 -44
- package/dist/app/demo/form/control/dialog/dialog.js +0 -49
- package/dist/app/demo/form/control/dialog/dialog.xml +0 -46
- package/dist/app/demo/form/control/drawer/drawer.js +0 -45
- package/dist/app/demo/form/control/drawer/drawer.xml +0 -34
- package/dist/app/demo/form/control/echarts/echarts.js +0 -137
- package/dist/app/demo/form/control/echarts/echarts.xml +0 -12
- package/dist/app/demo/form/control/empty/empty.js +0 -44
- package/dist/app/demo/form/control/empty/empty.xml +0 -9
- package/dist/app/demo/form/control/file/file.js +0 -60
- package/dist/app/demo/form/control/file/file.xml +0 -25
- package/dist/app/demo/form/control/flow/flow.css +0 -1
- package/dist/app/demo/form/control/flow/flow.js +0 -86
- package/dist/app/demo/form/control/flow/flow.scss +0 -18
- package/dist/app/demo/form/control/flow/flow.xml +0 -101
- package/dist/app/demo/form/control/form/form.css +0 -1
- package/dist/app/demo/form/control/form/form.js +0 -66
- package/dist/app/demo/form/control/form/form.scss +0 -5
- package/dist/app/demo/form/control/form/form.xml +0 -29
- package/dist/app/demo/form/control/grid/grid.js +0 -45
- package/dist/app/demo/form/control/grid/grid.xml +0 -27
- package/dist/app/demo/form/control/group/group.js +0 -50
- package/dist/app/demo/form/control/group/group.xml +0 -46
- package/dist/app/demo/form/control/hske/hske.js +0 -44
- package/dist/app/demo/form/control/hske/hske.xml +0 -19
- package/dist/app/demo/form/control/html/html.js +0 -70
- package/dist/app/demo/form/control/html/html.xml +0 -18
- package/dist/app/demo/form/control/icon/icon.xml +0 -49
- package/dist/app/demo/form/control/iconview/iconview.js +0 -174
- package/dist/app/demo/form/control/iconview/iconview.xml +0 -45
- package/dist/app/demo/form/control/img/img.xml +0 -26
- package/dist/app/demo/form/control/imgviewer/imgviewer.js +0 -46
- package/dist/app/demo/form/control/imgviewer/imgviewer.xml +0 -9
- package/dist/app/demo/form/control/jodit/jodit.js +0 -64
- package/dist/app/demo/form/control/jodit/jodit.xml +0 -24
- package/dist/app/demo/form/control/label/label.js +0 -51
- package/dist/app/demo/form/control/label/label.xml +0 -34
- package/dist/app/demo/form/control/layout/layout.js +0 -45
- package/dist/app/demo/form/control/layout/layout.xml +0 -18
- package/dist/app/demo/form/control/link/link.js +0 -42
- package/dist/app/demo/form/control/link/link.xml +0 -30
- package/dist/app/demo/form/control/list/list.css +0 -1
- package/dist/app/demo/form/control/list/list.js +0 -375
- package/dist/app/demo/form/control/list/list.scss +0 -7
- package/dist/app/demo/form/control/list/list.xml +0 -150
- package/dist/app/demo/form/control/loading/loading.xml +0 -8
- package/dist/app/demo/form/control/map/map.js +0 -206
- package/dist/app/demo/form/control/map/map.xml +0 -44
- package/dist/app/demo/form/control/marquee/marquee.js +0 -64
- package/dist/app/demo/form/control/marquee/marquee.xml +0 -33
- package/dist/app/demo/form/control/menu/menu.js +0 -56
- package/dist/app/demo/form/control/menu/menu.xml +0 -125
- package/dist/app/demo/form/control/monaco/monaco.js +0 -136
- package/dist/app/demo/form/control/monaco/monaco.xml +0 -28
- package/dist/app/demo/form/control/mpegts/mpegts.js +0 -70
- package/dist/app/demo/form/control/mpegts/mpegts.xml +0 -11
- package/dist/app/demo/form/control/nav/nav.js +0 -60
- package/dist/app/demo/form/control/nav/nav.xml +0 -106
- package/dist/app/demo/form/control/novnc/novnc.js +0 -75
- package/dist/app/demo/form/control/novnc/novnc.xml +0 -13
- package/dist/app/demo/form/control/page/page.js +0 -51
- package/dist/app/demo/form/control/page/page.xml +0 -22
- package/dist/app/demo/form/control/palette/palette.js +0 -46
- package/dist/app/demo/form/control/palette/palette.xml +0 -16
- package/dist/app/demo/form/control/panel/panel.js +0 -106
- package/dist/app/demo/form/control/panel/panel.xml +0 -16
- package/dist/app/demo/form/control/panel/test1.js +0 -84
- package/dist/app/demo/form/control/panel/test1.xml +0 -22
- package/dist/app/demo/form/control/panel/test2.xml +0 -4
- package/dist/app/demo/form/control/pdf/pdf.js +0 -65
- package/dist/app/demo/form/control/pdf/pdf.xml +0 -12
- package/dist/app/demo/form/control/pdf/test.pdf +0 -0
- package/dist/app/demo/form/control/progress/progress.js +0 -54
- package/dist/app/demo/form/control/progress/progress.xml +0 -9
- package/dist/app/demo/form/control/property/property.js +0 -166
- package/dist/app/demo/form/control/property/property.xml +0 -6
- package/dist/app/demo/form/control/qrcode/qrcode.js +0 -45
- package/dist/app/demo/form/control/qrcode/qrcode.xml +0 -13
- package/dist/app/demo/form/control/radio/radio.js +0 -51
- package/dist/app/demo/form/control/radio/radio.xml +0 -15
- package/dist/app/demo/form/control/scroll/scroll.js +0 -52
- package/dist/app/demo/form/control/scroll/scroll.xml +0 -38
- package/dist/app/demo/form/control/select/select.js +0 -273
- package/dist/app/demo/form/control/select/select.xml +0 -141
- package/dist/app/demo/form/control/setting/setting.xml +0 -11
- package/dist/app/demo/form/control/sgroup/sgroup.xml +0 -28
- package/dist/app/demo/form/control/step/step.js +0 -61
- package/dist/app/demo/form/control/step/step.xml +0 -16
- package/dist/app/demo/form/control/svg/svg.js +0 -61
- package/dist/app/demo/form/control/svg/svg.xml +0 -24
- package/dist/app/demo/form/control/switch/switch.js +0 -53
- package/dist/app/demo/form/control/switch/switch.xml +0 -29
- package/dist/app/demo/form/control/tab/tab.js +0 -102
- package/dist/app/demo/form/control/tab/tab.xml +0 -22
- package/dist/app/demo/form/control/table/table.js +0 -218
- package/dist/app/demo/form/control/table/table.xml +0 -97
- package/dist/app/demo/form/control/tag/tag.js +0 -44
- package/dist/app/demo/form/control/tag/tag.xml +0 -52
- package/dist/app/demo/form/control/text/text.js +0 -116
- package/dist/app/demo/form/control/text/text.xml +0 -70
- package/dist/app/demo/form/control/timeline/timeline.js +0 -43
- package/dist/app/demo/form/control/timeline/timeline.xml +0 -19
- package/dist/app/demo/form/control/tip/tip.js +0 -43
- package/dist/app/demo/form/control/tip/tip.xml +0 -42
- package/dist/app/demo/form/control/tplink/tplink.js +0 -74
- package/dist/app/demo/form/control/tplink/tplink.xml +0 -13
- package/dist/app/demo/form/control/tuieditor/tuieditor.js +0 -62
- package/dist/app/demo/form/control/tuieditor/tuieditor.xml +0 -22
- package/dist/app/demo/form/control/tuiviewer/tuiviewer.js +0 -45
- package/dist/app/demo/form/control/tuiviewer/tuiviewer.xml +0 -14
- package/dist/app/demo/form/control/uploader/uploader.js +0 -80
- package/dist/app/demo/form/control/uploader/uploader.xml +0 -15
- package/dist/app/demo/form/control/vflow/vflow.css +0 -1
- package/dist/app/demo/form/control/vflow/vflow.js +0 -101
- package/dist/app/demo/form/control/vflow/vflow.scss +0 -22
- package/dist/app/demo/form/control/vflow/vflow.xml +0 -89
- package/dist/app/demo/form/control/video/video.js +0 -47
- package/dist/app/demo/form/control/video/video.xml +0 -14
- package/dist/app/demo/form/control/web/web.js +0 -43
- package/dist/app/demo/form/control/web/web.xml +0 -4
- package/dist/app/demo/form/control/xterm/xterm.js +0 -100
- package/dist/app/demo/form/control/xterm/xterm.xml +0 -6
- package/dist/app/demo/form/event/form/form.css +0 -1
- package/dist/app/demo/form/event/form/form.js +0 -169
- package/dist/app/demo/form/event/form/form.scss +0 -24
- package/dist/app/demo/form/event/form/form.xml +0 -16
- package/dist/app/demo/form/event/other/other.js +0 -78
- package/dist/app/demo/form/event/other/other.xml +0 -5
- package/dist/app/demo/form/event/screen/screen.js +0 -86
- package/dist/app/demo/form/event/screen/screen.xml +0 -9
- package/dist/app/demo/form/event/task/task.js +0 -96
- package/dist/app/demo/form/event/task/task.xml +0 -20
- package/dist/app/demo/form/main.css +0 -1
- package/dist/app/demo/form/main.js +0 -515
- package/dist/app/demo/form/main.scss +0 -9
- package/dist/app/demo/form/main.xml +0 -163
- package/dist/app/demo/form/method/acontrol/acontrol.js +0 -42
- package/dist/app/demo/form/method/acontrol/acontrol.xml +0 -5
- package/dist/app/demo/form/method/aform/aform.js +0 -104
- package/dist/app/demo/form/method/aform/aform.xml +0 -60
- package/dist/app/demo/form/method/aform/sd.js +0 -47
- package/dist/app/demo/form/method/aform/sd.xml +0 -7
- package/dist/app/demo/form/method/core/core.js +0 -86
- package/dist/app/demo/form/method/core/core.xml +0 -23
- package/dist/app/demo/form/method/dom/dom.css +0 -1
- package/dist/app/demo/form/method/dom/dom.js +0 -228
- package/dist/app/demo/form/method/dom/dom.scss +0 -10
- package/dist/app/demo/form/method/dom/dom.xml +0 -76
- package/dist/app/demo/form/method/form/form.js +0 -244
- package/dist/app/demo/form/method/form/form.xml +0 -74
- package/dist/app/demo/form/method/form/test.xml +0 -5
- package/dist/app/demo/form/method/fs/fs.js +0 -209
- package/dist/app/demo/form/method/fs/fs.xml +0 -18
- package/dist/app/demo/form/method/fs/text.js +0 -48
- package/dist/app/demo/form/method/fs/text.xml +0 -3
- package/dist/app/demo/form/method/native/native.js +0 -100
- package/dist/app/demo/form/method/native/native.xml +0 -22
- package/dist/app/demo/form/method/storage/storage.js +0 -77
- package/dist/app/demo/form/method/storage/storage.xml +0 -18
- package/dist/app/demo/form/method/system/system.js +0 -63
- package/dist/app/demo/form/method/system/system.xml +0 -14
- package/dist/app/demo/form/method/task/locale1.json +0 -3
- package/dist/app/demo/form/method/task/locale2.json +0 -3
- package/dist/app/demo/form/method/task/task.js +0 -177
- package/dist/app/demo/form/method/task/task.xml +0 -61
- package/dist/app/demo/form/method/theme/theme.js +0 -92
- package/dist/app/demo/form/method/theme/theme.xml +0 -12
- package/dist/app/demo/form/method/tool/tool.js +0 -122
- package/dist/app/demo/form/method/tool/tool.xml +0 -40
- package/dist/app/demo/form/method/zip/zip.js +0 -126
- package/dist/app/demo/form/method/zip/zip.xml +0 -12
- package/dist/app/demo/form/solution/backpanel/backpanel.js +0 -76
- package/dist/app/demo/form/solution/backpanel/backpanel.xml +0 -31
- package/dist/app/demo/global.css +0 -3
- package/dist/app/demo/res/custombtn.cgc +0 -0
- package/dist/app/demo/res/icon.svg +0 -5
- package/dist/app/demo/res/img.jpg +0 -0
- package/dist/app/demo/res/marker.svg +0 -5
- package/dist/app/demo/res/r-1.svg +0 -32
- package/dist/app/demo/res/r-2.svg +0 -38
- package/dist/app/demo/res/sql.svg +0 -25
- package/dist/app/demo/res/txt.svg +0 -21
- package/dist/app/demo/res/zip.svg +0 -21
- package/dist/app/task/app.js +0 -46
- package/dist/app/task/config.json +0 -29
- package/dist/app/task/form/bar/bar.js +0 -406
- package/dist/app/task/form/bar/bar.xml +0 -46
- package/dist/app/task/form/desktop/desktop.xml +0 -1
- package/dist/app/task/locale/en.json +0 -11
- package/dist/app/task/locale/ja.json +0 -11
- package/dist/app/task/locale/sc.json +0 -11
- package/dist/app/task/locale/tc.json +0 -11
- package/dist/clickgo.d.ts +0 -22
- package/dist/clickgo.js +0 -109
- package/dist/index.d.ts +0 -55
- package/dist/lib/control.d.ts +0 -53
- package/dist/lib/control.js +0 -584
- package/dist/lib/core.d.ts +0 -47
- package/dist/lib/core.js +0 -1005
- package/dist/lib/dom.d.ts +0 -75
- package/dist/lib/dom.js +0 -2147
- package/dist/lib/form.d.ts +0 -222
- package/dist/lib/form.js +0 -2961
- package/dist/lib/fs.d.ts +0 -35
- package/dist/lib/fs.js +0 -1183
- package/dist/lib/native.d.ts +0 -43
- package/dist/lib/native.js +0 -197
- package/dist/lib/storage.d.ts +0 -6
- package/dist/lib/storage.js +0 -215
- package/dist/lib/task.d.ts +0 -32
- package/dist/lib/task.js +0 -1831
- package/dist/lib/theme.d.ts +0 -8
- package/dist/lib/theme.js +0 -176
- package/dist/lib/tool.d.ts +0 -122
- package/dist/lib/tool.js +0 -1021
- package/dist/lib/zip.d.ts +0 -40
- package/dist/lib/zip.js +0 -382
- package/dist/theme/blue.cgt +0 -0
- package/dist/theme/byterun.cgt +0 -0
- package/types/index.d.ts +0 -1374
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
(function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t():"function"===typeof define&&define.amd?define([],t):"object"===typeof exports?exports["tums-player"]=t():e["tums-player"]=t()})("undefined"!==typeof self?self:this,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="fb15")}({0:function(e,t){},"00b4":function(e,t,n){"use strict";n("ac1f");var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("e330"),s=n("1626"),c=n("861d"),u=function(){var e=!1,t=/[ac]/;return t.exec=function(){return e=!0,/./.exec.apply(this,arguments)},!0===t.test("abc")&&e}(),l=i.Error,f=o(/./.test);r({target:"RegExp",proto:!0,forced:!u},{test:function(e){var t=this.exec;if(!s(t))return f(this,e);var n=a(t,this,e);if(null!==n&&!c(n))throw new l("RegExp exec method returned something other than an Object or null");return!!n}})},"00bb":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.mode.CFB=function(){var t=e.lib.BlockCipherMode.extend();function n(e,t,n,r){var i,a=this._iv;a?(i=a.slice(0),this._iv=void 0):i=this._prevBlock,r.encryptBlock(i,0);for(var o=0;o<n;o++)e[t+o]^=i[o]}return t.Encryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize;n.call(this,e,t,i,r),this._prevBlock=e.slice(t,t+i)}}),t.Decryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize,a=e.slice(t,t+i);n.call(this,e,t,i,r),this._prevBlock=a}}),t}(),e.mode.CFB}))},"00ee":function(e,t,n){var r=n("b622"),i=r("toStringTag"),a={};a[i]="z",e.exports="[object z]"===String(a)},"015a":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("0a0d");r({target:"Set",proto:!0,real:!0,forced:i},{deleteAll:a})},"01b4":function(e,t){var n=function(){this.head=null,this.tail=null};n.prototype={add:function(e){var t={item:e,next:null};this.head?this.tail.next=t:this.head=t,this.tail=t},get:function(){var e=this.head;if(e)return this.head=e.next,this.tail===e&&(this.tail=null),e.item}},e.exports=n},"020f":function(e,t,n){var r=n("746f");r("matcher")},"0261":function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("8eb5"),o=Math.abs,s=Math.exp,c=Math.E,u=i((function(){return-2e-17!=Math.sinh(-2e-17)}));r({target:"Math",stat:!0,forced:u},{sinh:function(e){return o(e=+e)<1?(a(e)-a(-e))/2:(s(e-1)-s(-e-1))*(c/2)}})},"0308":function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.has,s=i.toKey;r({target:"Reflect",stat:!0},{hasOwnMetadata:function(e,t){var n=arguments.length<3?void 0:s(arguments[2]);return o(e,a(t),n)}})},"0366":function(e,t,n){var r=n("e330"),i=n("59ed"),a=n("40d5"),o=r(r.bind);e.exports=function(e,t){return i(e),void 0===t?e:a?o(e,t):function(){return e.apply(t,arguments)}}},"0466":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("d066"),o=n("59ed"),s=n("825a"),c=n("4840"),u=n("2266");r({target:"Set",proto:!0,real:!0,forced:i},{union:function(e){var t=s(this),n=new(c(t,a("Set")))(t);return u(e,o(n.add),{that:n}),n}})},"0481":function(e,t,n){"use strict";var r=n("23e7"),i=n("a2bf"),a=n("7b0b"),o=n("07fa"),s=n("5926"),c=n("65f0");r({target:"Array",proto:!0},{flat:function(){var e=arguments.length?arguments[0]:void 0,t=a(this),n=o(t),r=c(t,0);return r.length=i(r,t,t,n,0,void 0===e?1:s(e)),r}})},"04d1":function(e,t,n){var r=n("342f"),i=r.match(/firefox\/(\d+)/i);e.exports=!!i&&+i[1]},"04d3":function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("blink")},{blink:function(){return i(this,"blink","","")}})},"0538":function(e,t,n){"use strict";var r=n("da84"),i=n("e330"),a=n("59ed"),o=n("861d"),s=n("1a2d"),c=n("f36a"),u=n("40d5"),l=r.Function,f=i([].concat),h=i([].join),d={},p=function(e,t,n){if(!s(d,t)){for(var r=[],i=0;i<t;i++)r[i]="a["+i+"]";d[t]=l("C,a","return new C("+h(r,",")+")")}return d[t](e,n)};e.exports=u?l.bind:function(e){var t=a(this),n=t.prototype,r=c(arguments,1),i=function(){var n=f(r,c(arguments));return this instanceof i?p(t,n.length,n):t.apply(e,n)};return o(n)&&(i.prototype=n),i}},"0541":function(e,t,n){var r=n("23e7"),i=n("1a2d");r({target:"Object",stat:!0},{hasOwn:i})},"057f":function(e,t,n){var r=n("c6b6"),i=n("fc6a"),a=n("241c").f,o=n("4dae"),s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],c=function(e){try{return a(e)}catch(t){return o(s)}};e.exports.f=function(e){return s&&"Window"==r(e)?c(e):a(i(e))}},"0643":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("19aa"),o=n("1626"),s=n("9112"),c=n("d039"),u=n("1a2d"),l=n("b622"),f=n("ae93").IteratorPrototype,h=n("c430"),d=l("toStringTag"),p=i.Iterator,v=h||!o(p)||p.prototype!==f||!c((function(){p({})})),m=function(){a(this,f)};u(f,d)||s(f,d,"Iterator"),!v&&u(f,"constructor")&&f.constructor!==Object||s(f,"constructor",m),m.prototype=f,r({global:!0,forced:v},{Iterator:m})},"06cf":function(e,t,n){var r=n("83ab"),i=n("c65b"),a=n("d1e7"),o=n("5c6c"),s=n("fc6a"),c=n("a04b"),u=n("1a2d"),l=n("0cfb"),f=Object.getOwnPropertyDescriptor;t.f=r?f:function(e,t){if(e=s(e),t=c(t),l)try{return f(e,t)}catch(n){}if(u(e,t))return o(!i(a.f,e,t),e[t])}},"07ac":function(e,t,n){var r=n("23e7"),i=n("6f53").values;r({target:"Object",stat:!0},{values:function(e){return i(e)}})},"07fa":function(e,t,n){var r=n("50c4");e.exports=function(e){return r(e.length)}},"094c":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("0366"),s=n("c65b"),c=n("59ed"),u=n("825a"),l=n("4840"),f=n("4acb"),h=n("2266");i({target:"Map",proto:!0,real:!0,forced:r},{mapValues:function(e){var t=u(this),n=f(t),r=o(e,arguments.length>1?arguments[1]:void 0),i=new(l(t,a("Map"))),d=c(i.set);return h(n,(function(e,n){s(d,i,e,r(n,e,t))}),{AS_ENTRIES:!0,IS_ITERATOR:!0}),i}})},"0a06":function(e,t,n){"use strict";var r=n("c532"),i=n("30b5"),a=n("f6b4"),o=n("5270"),s=n("4a7b"),c=n("848b"),u=c.validators;function l(e){this.defaults=e,this.interceptors={request:new a,response:new a}}l.prototype.request=function(e){"string"===typeof e?(e=arguments[1]||{},e.url=arguments[0]):e=e||{},e=s(this.defaults,e),e.method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var t=e.transitional;void 0!==t&&c.assertOptions(t,{silentJSONParsing:u.transitional(u.boolean),forcedJSONParsing:u.transitional(u.boolean),clarifyTimeoutError:u.transitional(u.boolean)},!1);var n=[],r=!0;this.interceptors.request.forEach((function(t){"function"===typeof t.runWhen&&!1===t.runWhen(e)||(r=r&&t.synchronous,n.unshift(t.fulfilled,t.rejected))}));var i,a=[];if(this.interceptors.response.forEach((function(e){a.push(e.fulfilled,e.rejected)})),!r){var l=[o,void 0];Array.prototype.unshift.apply(l,n),l=l.concat(a),i=Promise.resolve(e);while(l.length)i=i.then(l.shift(),l.shift());return i}var f=e;while(n.length){var h=n.shift(),d=n.shift();try{f=h(f)}catch(p){d(p);break}}try{i=o(f)}catch(p){return Promise.reject(p)}while(a.length)i=i.then(a.shift(),a.shift());return i},l.prototype.getUri=function(e){return e=s(this.defaults,e),i(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(e){l.prototype[e]=function(t,n){return this.request(s(n||{},{method:e,url:t,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(e){l.prototype[e]=function(t,n,r){return this.request(s(r||{},{method:e,url:t,data:n}))}})),e.exports=l},"0a0d":function(e,t,n){"use strict";var r=n("c65b"),i=n("59ed"),a=n("825a");e.exports=function(){for(var e,t=a(this),n=i(t["delete"]),o=!0,s=0,c=arguments.length;s<c;s++)e=r(n,t,arguments[s]),o=o&&e;return!!o}},"0a8d":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("c65b"),o=n("59ed"),s=n("825a"),c=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{isSupersetOf:function(e){var t=s(this),n=o(t.has);return!c(e,(function(e,r){if(!1===a(n,t,e))return r()}),{INTERRUPTED:!0}).stopped}})},"0a90":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("d039"),o=a((function(){return 120!==new Date(16e11).getYear()})),s=i(Date.prototype.getFullYear);r({target:"Date",proto:!0,forced:o},{getYear:function(){return s(this)-1900}})},"0ac8":function(e,t,n){var r=n("23e7"),i=n("8eb5");r({target:"Math",stat:!0,forced:i!=Math.expm1},{expm1:i})},"0b25":function(e,t,n){var r=n("da84"),i=n("5926"),a=n("50c4"),o=r.RangeError;e.exports=function(e){if(void 0===e)return 0;var t=i(e),n=a(t);if(t!==n)throw o("Wrong length or index");return n}},"0b42":function(e,t,n){var r=n("da84"),i=n("e8b5"),a=n("68ee"),o=n("861d"),s=n("b622"),c=s("species"),u=r.Array;e.exports=function(e){var t;return i(e)&&(t=e.constructor,a(t)&&(t===u||i(t.prototype))?t=void 0:o(t)&&(t=t[c],null===t&&(t=void 0))),void 0===t?u:t}},"0b52":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("c65b"),o=n("59ed"),s=n("825a"),c=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{isDisjointFrom:function(e){var t=s(this),n=o(t.has);return!c(e,(function(e,r){if(!0===a(n,t,e))return r()}),{INTERRUPTED:!0}).stopped}})},"0c47":function(e,t,n){var r=n("da84"),i=n("d44e");i(r.JSON,"JSON",!0)},"0cb2":function(e,t,n){var r=n("e330"),i=n("7b0b"),a=Math.floor,o=r("".charAt),s=r("".replace),c=r("".slice),u=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,l=/\$([$&'`]|\d{1,2})/g;e.exports=function(e,t,n,r,f,h){var d=n+e.length,p=r.length,v=l;return void 0!==f&&(f=i(f),v=u),s(h,v,(function(i,s){var u;switch(o(s,0)){case"$":return"$";case"&":return e;case"`":return c(t,0,n);case"'":return c(t,d);case"<":u=f[c(s,1,-1)];break;default:var l=+s;if(0===l)return i;if(l>p){var h=a(l/10);return 0===h?i:h<=p?void 0===r[h-1]?o(s,1):r[h-1]+o(s,1):i}u=r[l-1]}return void 0===u?"":u}))}},"0ccb":function(e,t,n){var r=n("e330"),i=n("50c4"),a=n("577e"),o=n("1148"),s=n("1d80"),c=r(o),u=r("".slice),l=Math.ceil,f=function(e){return function(t,n,r){var o,f,h=a(s(t)),d=i(n),p=h.length,v=void 0===r?" ":a(r);return d<=p||""==v?h:(o=d-p,f=c(v,l(o/v.length)),f.length>o&&(f=u(f,0,o)),e?h+f:f+h)}};e.exports={start:f(!1),end:f(!0)}},"0ce4":function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("f8cd"),s=n("d195"),c=s((function(e,t){var n=this;return new e((function(r,o){var s=function(){try{e.resolve(a(i(n.next,n.iterator,n.remaining?[]:t))).then((function(e){try{a(e).done?(n.done=!0,r({done:!0,value:void 0})):n.remaining?(n.remaining--,s()):r({done:!1,value:e.value})}catch(t){o(t)}}),o)}catch(c){o(c)}};s()}))}));r({target:"AsyncIterator",proto:!0,real:!0},{drop:function(e){return new c({iterator:a(this),remaining:o(e)})}})},"0cfb":function(e,t,n){var r=n("83ab"),i=n("d039"),a=n("cc12");e.exports=!r&&!i((function(){return 7!=Object.defineProperty(a("div"),"a",{get:function(){return 7}}).a}))},"0d03":function(e,t,n){var r=n("e330"),i=n("6eeb"),a=Date.prototype,o="Invalid Date",s="toString",c=r(a[s]),u=r(a.getTime);String(new Date(NaN))!=o&&i(a,s,(function(){var e=u(this);return e===e?c(this):o}))},"0d3b":function(e,t,n){var r=n("d039"),i=n("b622"),a=n("c430"),o=i("iterator");e.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t["delete"]("b"),n+=r+e})),a&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[o]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},"0d51":function(e,t,n){var r=n("da84"),i=r.String;e.exports=function(e){try{return i(e)}catch(t){return"Object"}}},"0df6":function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},"0e13":function(e,t,n){n("a1f0")},"0eb6":function(e,t,n){"use strict";var r=n("23e7"),i=n("7c37"),a=n("d066"),o=n("d039"),s=n("7c73"),c=n("5c6c"),u=n("9bf2").f,l=n("37e8").f,f=n("6eeb"),h=n("1a2d"),d=n("19aa"),p=n("825a"),v=n("aa1f"),m=n("e391"),y=n("cf98"),g=n("c770"),b=n("69f3"),T=n("83ab"),S=n("c430"),E="DOMException",_="DATA_CLONE_ERR",k=a("Error"),w=a(E)||function(){try{var e=a("MessageChannel")||i("worker_threads").MessageChannel;(new e).port1.postMessage(new WeakMap)}catch(t){if(t.name==_&&25==t.code)return t.constructor}}(),A=w&&w.prototype,R=k.prototype,x=b.set,C=b.getterFor(E),I="stack"in k(E),P=function(e){return h(y,e)&&y[e].m?y[e].c:0},O=function(){d(this,D);var e=arguments.length,t=m(e<1?void 0:arguments[0]),n=m(e<2?void 0:arguments[1],"Error"),r=P(n);if(x(this,{type:E,name:n,message:t,code:r}),T||(this.name=n,this.message=t,this.code=r),I){var i=k(t);i.name=E,u(this,"stack",c(1,g(i.stack,1)))}},D=O.prototype=s(R),U=function(e){return{enumerable:!0,configurable:!0,get:e}},M=function(e){return U((function(){return C(this)[e]}))};T&&l(D,{name:M("name"),message:M("message"),code:M("code")}),u(D,"constructor",c(1,O));var B=o((function(){return!(new w instanceof k)})),N=B||o((function(){return R.toString!==v||"2: 1"!==String(new w(1,2))})),L=B||o((function(){return 25!==new w(1,"DataCloneError").code})),F=B||25!==w[_]||25!==A[_],j=S?N||L||F:B;r({global:!0,forced:j},{DOMException:j?O:w});var W=a(E),H=W.prototype;for(var V in N&&(S||w===W)&&f(H,"toString",v),L&&T&&w===W&&u(H,"code",U((function(){return P(p(this).name)}))),y)if(h(y,V)){var q=y[V],z=q.s,G=c(6,q.c);h(W,z)||u(W,z,G),h(H,z)||u(H,z,G)}},"0ebb":function(e,t,n){n("dbfa")},1034:function(e,t,n){var r=n("23e7"),i=n("a799"),a=n("d066"),o=n("2ba4");r({global:!0},{compositeSymbol:function(){return 1==arguments.length&&"string"==typeof arguments[0]?a("Symbol")["for"](arguments[0]):o(i,null,arguments).get("symbol",a("Symbol"))}})},"107c":function(e,t,n){var r=n("d039"),i=n("da84"),a=i.RegExp;e.exports=r((function(){var e=a("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")}))},"10b7":function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){
|
|
2
|
+
/** @preserve
|
|
3
|
+
(c) 2012 by Cédric Mesnil. All rights reserved.
|
|
4
|
+
|
|
5
|
+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
|
|
6
|
+
|
|
7
|
+
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
|
|
8
|
+
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
|
|
9
|
+
|
|
10
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
11
|
+
*/
|
|
12
|
+
return function(t){var n=e,r=n.lib,i=r.WordArray,a=r.Hasher,o=n.algo,s=i.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),c=i.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),u=i.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),l=i.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),f=i.create([0,1518500249,1859775393,2400959708,2840853838]),h=i.create([1352829926,1548603684,1836072691,2053994217,0]),d=o.RIPEMD160=a.extend({_doReset:function(){this._hash=i.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var r=t+n,i=e[r];e[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var a,o,d,T,S,E,_,k,w,A,R,x=this._hash.words,C=f.words,I=h.words,P=s.words,O=c.words,D=u.words,U=l.words;E=a=x[0],_=o=x[1],k=d=x[2],w=T=x[3],A=S=x[4];for(n=0;n<80;n+=1)R=a+e[t+P[n]]|0,R+=n<16?p(o,d,T)+C[0]:n<32?v(o,d,T)+C[1]:n<48?m(o,d,T)+C[2]:n<64?y(o,d,T)+C[3]:g(o,d,T)+C[4],R|=0,R=b(R,D[n]),R=R+S|0,a=S,S=T,T=b(d,10),d=o,o=R,R=E+e[t+O[n]]|0,R+=n<16?g(_,k,w)+I[0]:n<32?y(_,k,w)+I[1]:n<48?m(_,k,w)+I[2]:n<64?v(_,k,w)+I[3]:p(_,k,w)+I[4],R|=0,R=b(R,U[n]),R=R+A|0,E=A,A=w,w=b(k,10),k=_,_=R;R=x[1]+d+w|0,x[1]=x[2]+T+A|0,x[2]=x[3]+S+E|0,x[3]=x[4]+a+_|0,x[4]=x[0]+o+k|0,x[0]=R},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;t[r>>>5]|=128<<24-r%32,t[14+(r+64>>>9<<4)]=16711935&(n<<8|n>>>24)|4278255360&(n<<24|n>>>8),e.sigBytes=4*(t.length+1),this._process();for(var i=this._hash,a=i.words,o=0;o<5;o++){var s=a[o];a[o]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8)}return i},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}});function p(e,t,n){return e^t^n}function v(e,t,n){return e&t|~e&n}function m(e,t,n){return(e|~t)^n}function y(e,t,n){return e&n|t&~n}function g(e,t,n){return e^(t|~n)}function b(e,t){return e<<t|e>>>32-t}n.RIPEMD160=a._createHelper(d),n.HmacRIPEMD160=a._createHmacHelper(d)}(Math),e.RIPEMD160}))},"10d1":function(e,t,n){"use strict";var r,i=n("da84"),a=n("e330"),o=n("e2cc"),s=n("f183"),c=n("6d61"),u=n("acac"),l=n("861d"),f=n("4fad"),h=n("69f3").enforce,d=n("7f9a"),p=!i.ActiveXObject&&"ActiveXObject"in i,v=function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},m=c("WeakMap",v,u);if(d&&p){r=u.getConstructor(v,"WeakMap",!0),s.enable();var y=m.prototype,g=a(y["delete"]),b=a(y.has),T=a(y.get),S=a(y.set);o(y,{delete:function(e){if(l(e)&&!f(e)){var t=h(this);return t.frozen||(t.frozen=new r),g(this,e)||t.frozen["delete"](e)}return g(this,e)},has:function(e){if(l(e)&&!f(e)){var t=h(this);return t.frozen||(t.frozen=new r),b(this,e)||t.frozen.has(e)}return b(this,e)},get:function(e){if(l(e)&&!f(e)){var t=h(this);return t.frozen||(t.frozen=new r),b(this,e)?T(this,e):t.frozen.get(e)}return T(this,e)},set:function(e,t){if(l(e)&&!f(e)){var n=h(this);n.frozen||(n.frozen=new r),b(this,e)?S(this,e,t):n.frozen.set(e,t)}else S(this,e,t);return this}})}},"10d3":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n("20a2"),i=n("3eb5"),a=n("b639"),o=n("1434"),s=n("66c3");function c(e){return t.ebmlBlock(new t.Buffer(e))}function u(e,n,r){return void 0===r&&(r=!1),_([e,r?new t.Buffer("01ffffffffffffff","hex"):t.writeVint(n.length),n])}function l(e){return f(e).reduce((function(e,n){var r=t.ebmlBlock(n.data);return r.frames.reduce((function(e,t){var n=h(t),r=new Blob([n],{type:"image/webp"});return e.concat(r)}),e)}),[])}function f(e){return e.reduce((function(e,n){if("b"!==n.type)return e;if("SimpleBlock"!==n.name)return e;var r=t.ebmlBlock(n.data),i=r.frames.some((function(e){var t=e.slice(3,6).toString("hex");return"9d012a"===t}));return i?e.concat(n):e}),[])}function h(e){var n=d("VP8 ",e),r=_([new t.Buffer("WEBP","ascii"),n]);return d("RIFF",r)}function d(e,n){var r=new t.Buffer(4);return r.writeUInt32LE(n.byteLength,0),_([new t.Buffer(e.substr(0,4),"ascii"),r,n,new t.Buffer(n.byteLength%2===0?0:1)])}function p(e,n,r){var a=m("EBML",e),o=g(a),s=o+12,c=e[e.length-1].dataEnd-s,u=m("Info",e);v("Duration",u),u.splice(1,0,{name:"Duration",type:"f",data:R(n,8)});for(var l=g(u),f=m("Tracks",e),h=g(f),d=47,p=[],y=5+15*r.length,b=[],T=-1,S=10,E=function(e){var n=d,i=n+l,a=i+h,o=a+y,u=o-c;if(p=[],p.push({name:"SeekHead",type:"m",isEnd:!1}),p.push({name:"Seek",type:"m",isEnd:!1}),p.push({name:"SeekID",type:"b",data:new t.Buffer([21,73,169,102])}),p.push({name:"SeekPosition",type:"u",data:w(n)}),p.push({name:"Seek",type:"m",isEnd:!0}),p.push({name:"Seek",type:"m",isEnd:!1}),p.push({name:"SeekID",type:"b",data:new t.Buffer([22,84,174,107])}),p.push({name:"SeekPosition",type:"u",data:w(i)}),p.push({name:"Seek",type:"m",isEnd:!0}),p.push({name:"Seek",type:"m",isEnd:!1}),p.push({name:"SeekID",type:"b",data:new t.Buffer([28,83,187,107])}),p.push({name:"SeekPosition",type:"u",data:w(a)}),p.push({name:"Seek",type:"m",isEnd:!0}),p.push({name:"SeekHead",type:"m",isEnd:!0}),d=g(p),b=[],b.push({name:"Cues",type:"m",isEnd:!1}),r.forEach((function(e){var t=e.CueTrack,n=e.CueClusterPosition,r=e.CueTime;b.push({name:"CuePoint",type:"m",isEnd:!1}),b.push({name:"CueTime",type:"u",data:w(r)}),b.push({name:"CueTrackPositions",type:"m",isEnd:!1}),b.push({name:"CueTrack",type:"u",data:w(t)}),n-=s,n+=u,b.push({name:"CueClusterPosition",type:"u",data:w(n)}),b.push({name:"CueTrackPositions",type:"m",isEnd:!0}),b.push({name:"CuePoint",type:"m",isEnd:!0})})),b.push({name:"Cues",type:"m",isEnd:!0}),y=g(b),T===u)return"break";if(T=u,e===S-1)throw new Error("Failed to converge to a stable metadata size")},_=0;_<S;_++){var k=E(_);if("break"===k)break}var A=[].concat.apply([],[a,{name:"Segment",type:"m",isEnd:!1,unknownSize:!0},p,u,f,b]),x=(new i.default).encode(A);return x}function v(e,t){for(var n=-1,r=0;r<t.length;r++){var i=t[r];if(i.name===e){if("m"!==i.type)return void t.splice(r,1);if(i.isEnd){if(-1==n)throw new Error("Detected "+e+" closing element before finding the start");return void t.splice(n,r-n+1)}n=r}}}function m(e,t){for(var n=[],r=-1,i=0;i<t.length;i++){var a=t[i];if(a.name===e){if("m"!==a.type){n.push(t[i]);break}if(a.isEnd){if(-1==r)throw new Error("Detected "+e+" closing element before finding the start");n=t.slice(r,i+1);break}r=i}}return n}function y(e,n){Array.isArray(n.cueInfos)&&!Array.isArray(n.cues)&&(console.warn("putRefinedMetaData: info.cueInfos property is deprecated. please use info.cues"),n.cues=n.cueInfos);for(var r=[],a=[],o=0;o<e.length;o++){var s=e[o];if("m"===s.type&&"Segment"===s.name){if(r=e.slice(0,o),a=e.slice(o),s.unknownSize){a.shift();break}throw new Error("this metadata is not streaming webm file")}}if(!(a[a.length-1].dataEnd>0))throw new Error("metadata dataEnd has wrong number");var c,u=a[a.length-1].dataEnd,l=r[r.length-1].dataEnd,f=(new i.default).encode(r).byteLength,h=f-l,d=u-a[0].tagStart,p=(a[0].tagStart,a[0].tagStart,new t.Buffer([24,83,128,103])),v=new t.Buffer("01ffffffffffffff","hex"),m=p.byteLength+v.byteLength,y=d;for(c=1;c<20;c++){var g=l+m+y,T=g-u,S=h+T,E=b(a,S,n),_=(new i.default).encode(E).byteLength;if(_===y)return(new i.default).encode([].concat(r,[{type:"m",name:"Segment",isEnd:!1,unknownSize:!0}],E));y=_}throw new Error("unable to refine metadata, stable size could not be found in "+c+" iterations!")}function g(e){var t=new i.default;return e.reduce((function(e,n){return e.concat(t.encode([n]))}),[]).reduce((function(e,t){return e+t.byteLength}),0)}function b(e,t,n){var r=n.duration,i=n.clusterPtrs,a=n.cues,o=e.slice(0);if("number"===typeof r){var s=!1;o.forEach((function(e){"f"===e.type&&"Duration"===e.name&&(s=!0,e.data=R(r,8))})),s||E(o,"Info",[{name:"Duration",type:"f",data:R(r,8)}])}Array.isArray(a)&&E(o,"Cues",S(a,t));var c=[];return Array.isArray(i)&&(console.warn("append cluster pointers to seekhead is deprecated. please use cues"),c=T(i,t)),E(o,"SeekHead",c,!0),o}function T(e,n){var r=[];return e.forEach((function(e){r.push({name:"Seek",type:"m",isEnd:!1}),r.push({name:"SeekID",type:"b",data:new t.Buffer([31,67,182,117])}),r.push({name:"SeekPosition",type:"u",data:w(e+n)}),r.push({name:"Seek",type:"m",isEnd:!0})})),r}function S(e,t){var n=[];return e.forEach((function(e){var r=e.CueTrack,i=e.CueClusterPosition,a=e.CueTime;n.push({name:"CuePoint",type:"m",isEnd:!1}),n.push({name:"CueTime",type:"u",data:w(a)}),n.push({name:"CueTrackPositions",type:"m",isEnd:!1}),n.push({name:"CueTrack",type:"u",data:w(r)}),n.push({name:"CueClusterPosition",type:"u",data:w(i+t)}),n.push({name:"CueTrackPositions",type:"m",isEnd:!0}),n.push({name:"CuePoint",type:"m",isEnd:!0})})),n}function E(e,t,n,r){void 0===r&&(r=!1);for(var i=-1,a=0;a<e.length;a++){var o=e[a];if("m"===o.type&&o.name===t&&!1===o.isEnd){i=a;break}}i>=0?Array.prototype.splice.apply(e,[i+1,0].concat(n)):r?[].concat([{name:t,type:"m",isEnd:!1}],n,[{name:t,type:"m",isEnd:!0}]).reverse().forEach((function(t){e.unshift(t)})):(e.push({name:t,type:"m",isEnd:!1}),n.forEach((function(t){e.push(t)})),e.push({name:t,type:"m",isEnd:!0}))}function _(e){for(var n=0,r=0;n<e.length;++n)r+=e[n].length;var i=t.Buffer.allocUnsafe(r),a=0;for(n=0;n<e.length;++n){var o=e[n];o.copy(i,a),a+=o.length}return i}function k(e){var n=new t.Buffer(0);if("m"===e.type)return e;switch(e.type){case"u":n=w(e.value);break;case"i":n=A(e.value);break;case"f":n=R(e.value);break;case"s":n=new t.Buffer(e.value,"ascii");break;case"8":n=new t.Buffer(e.value,"utf8");break;case"b":n=e.value;break;case"d":n=new r.Int64BE(e.value.getTime().toString()).toBuffer();break}return Object.assign({},e,{data:n})}function w(e){for(var n=1;e>=Math.pow(2,8*n);n++);if(n>=7)return console.warn("7bit or more bigger uint not supported."),new r.Uint64BE(e).toBuffer();var i=new t.Buffer(n);return i.writeUIntBE(e,0,n),i}function A(e){for(var n=1;e>=Math.pow(2,8*n);n++);if(n>=7)return console.warn("7bit or more bigger uint not supported."),new r.Int64BE(e).toBuffer();var i=new t.Buffer(n);return i.writeIntBE(e,0,n),i}function R(e,n){if(void 0===n&&(n=8),8===n){var r=new t.Buffer(8);return r.writeDoubleBE(e,0),r}if(4===n){r=new t.Buffer(4);return r.writeFloatBE(e,0),r}throw new Error("float type bits must 4bytes or 8bytes")}function x(e){return e instanceof Date?e:new Date(new Date("2001-01-01T00:00:00.000Z").getTime()+Number(e)/1e3/1e3)}t.Buffer=a.Buffer,t.readVint=o.readVint,t.writeVint=o.writeVint,t.ebmlBlock=s,t.readBlock=c,t.encodeTag=u,t.WebPFrameFilter=l,t.WebPBlockFilter=f,t.VP8BitStreamToRiffWebPBuffer=h,t.createRIFFChunk=d,t.makeMetadataSeekable=p,t.removeElement=v,t.extractElement=m,t.putRefinedMetaData=y,t.concat=_,t.encodeValueToBuffer=k,t.createUIntBuffer=w,t.createIntBuffer=A,t.createFloatBuffer=R,t.convertEBMLDateToJSDate=x},1132:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=t.enc;i.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var i=[],a=0;a<n;a+=3)for(var o=t[a>>>2]>>>24-a%4*8&255,s=t[a+1>>>2]>>>24-(a+1)%4*8&255,c=t[a+2>>>2]>>>24-(a+2)%4*8&255,u=o<<16|s<<8|c,l=0;l<4&&a+.75*l<n;l++)i.push(r.charAt(u>>>6*(3-l)&63));var f=r.charAt(64);if(f)while(i.length%4)i.push(f);return i.join("")},parse:function(e){var t=e.length,n=this._map,r=this._reverseMap;if(!r){r=this._reverseMap=[];for(var i=0;i<n.length;i++)r[n.charCodeAt(i)]=i}var o=n.charAt(64);if(o){var s=e.indexOf(o);-1!==s&&(t=s)}return a(e,t,r)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function a(e,t,n){for(var i=[],a=0,o=0;o<t;o++)if(o%4){var s=n[e.charCodeAt(o-1)]<<o%4*2,c=n[e.charCodeAt(o)]>>>6-o%4*2,u=s|c;i[a>>>2]|=u<<24-a%4*8,a++}return r.create(i,a)}}(),e.enc.Base64}))},1148:function(e,t,n){"use strict";var r=n("da84"),i=n("5926"),a=n("577e"),o=n("1d80"),s=r.RangeError;e.exports=function(e){var t=a(o(this)),n="",r=i(e);if(r<0||r==1/0)throw s("Wrong number of repetitions");for(;r>0;(r>>>=1)&&(t+=t))1&r&&(n+=t);return n}},1276:function(e,t,n){"use strict";var r=n("2ba4"),i=n("c65b"),a=n("e330"),o=n("d784"),s=n("44e7"),c=n("825a"),u=n("1d80"),l=n("4840"),f=n("8aa5"),h=n("50c4"),d=n("577e"),p=n("dc4a"),v=n("4dae"),m=n("14c3"),y=n("9263"),g=n("9f7f"),b=n("d039"),T=g.UNSUPPORTED_Y,S=4294967295,E=Math.min,_=[].push,k=a(/./.exec),w=a(_),A=a("".slice),R=!b((function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));o("split",(function(e,t,n){var a;return a="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(e,n){var a=d(u(this)),o=void 0===n?S:n>>>0;if(0===o)return[];if(void 0===e)return[a];if(!s(e))return i(t,a,e,o);var c,l,f,h=[],p=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),m=0,g=new RegExp(e.source,p+"g");while(c=i(y,g,a)){if(l=g.lastIndex,l>m&&(w(h,A(a,m,c.index)),c.length>1&&c.index<a.length&&r(_,h,v(c,1)),f=c[0].length,m=l,h.length>=o))break;g.lastIndex===c.index&&g.lastIndex++}return m===a.length?!f&&k(g,"")||w(h,""):w(h,A(a,m)),h.length>o?v(h,0,o):h}:"0".split(void 0,0).length?function(e,n){return void 0===e&&0===n?[]:i(t,this,e,n)}:t,[function(t,n){var r=u(this),o=void 0==t?void 0:p(t,e);return o?i(o,t,r,n):i(a,d(r),t,n)},function(e,r){var i=c(this),o=d(e),s=n(a,i,o,r,a!==t);if(s.done)return s.value;var u=l(i,RegExp),p=i.unicode,v=(i.ignoreCase?"i":"")+(i.multiline?"m":"")+(i.unicode?"u":"")+(T?"g":"y"),y=new u(T?"^(?:"+i.source+")":i,v),g=void 0===r?S:r>>>0;if(0===g)return[];if(0===o.length)return null===m(y,o)?[o]:[];var b=0,_=0,k=[];while(_<o.length){y.lastIndex=T?0:_;var R,x=m(y,T?A(o,_):o);if(null===x||(R=E(h(y.lastIndex+(T?_:0)),o.length))===b)_=f(o,_,p);else{if(w(k,A(o,b,_)),k.length===g)return k;for(var C=1;C<=x.length-1;C++)if(w(k,x[C]),k.length===g)return k;_=b=R}}return w(k,A(o,b)),k}]}),!R,T)},"129f":function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},"12a8":function(e,t,n){"use strict";var r=n("23e7"),i=n("83ab"),a=n("eb1d"),o=n("59ed"),s=n("7b0b"),c=n("9bf2");i&&r({target:"Object",proto:!0,forced:a},{__defineGetter__:function(e,t){c.f(s(this),e,{get:o(t),enumerable:!0,configurable:!0})}})},"130f":function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("2cf4"),o=!i.setImmediate||!i.clearImmediate;r({global:!0,bind:!0,enumerable:!0,forced:o},{setImmediate:a.set,clearImmediate:a.clear})},"131a":function(e,t,n){var r=n("23e7"),i=n("d2bb");r({target:"Object",stat:!0},{setPrototypeOf:i})},1382:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("1132"),n("72fe"),n("2b79"),n("38ba"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.StreamCipher,i=t.algo,a=[],o=[],s=[],c=i.Rabbit=r.extend({_doReset:function(){for(var e=this._key.words,t=this.cfg.iv,n=0;n<4;n++)e[n]=16711935&(e[n]<<8|e[n]>>>24)|4278255360&(e[n]<<24|e[n]>>>8);var r=this._X=[e[0],e[3]<<16|e[2]>>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],i=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];this._b=0;for(n=0;n<4;n++)u.call(this);for(n=0;n<8;n++)i[n]^=r[n+4&7];if(t){var a=t.words,o=a[0],s=a[1],c=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;i[0]^=c,i[1]^=f,i[2]^=l,i[3]^=h,i[4]^=c,i[5]^=f,i[6]^=l,i[7]^=h;for(n=0;n<4;n++)u.call(this)}},_doProcessBlock:function(e,t){var n=this._X;u.call(this),a[0]=n[0]^n[5]>>>16^n[3]<<16,a[1]=n[2]^n[7]>>>16^n[5]<<16,a[2]=n[4]^n[1]>>>16^n[7]<<16,a[3]=n[6]^n[3]>>>16^n[1]<<16;for(var r=0;r<4;r++)a[r]=16711935&(a[r]<<8|a[r]>>>24)|4278255360&(a[r]<<24|a[r]>>>8),e[t+r]^=a[r]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,n=0;n<8;n++)o[n]=t[n];t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0<o[0]>>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0<o[1]>>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0<o[2]>>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0<o[3]>>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0<o[4]>>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0<o[5]>>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0<o[6]>>>0?1:0)|0,this._b=t[7]>>>0<o[7]>>>0?1:0;for(n=0;n<8;n++){var r=e[n]+t[n],i=65535&r,a=r>>>16,c=((i*i>>>17)+i*a>>>15)+a*a,u=((4294901760&r)*r|0)+((65535&r)*r|0);s[n]=c^u}e[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,e[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,e[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,e[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,e[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,e[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,e[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,e[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}t.Rabbit=r._createHelper(c)}(),e.Rabbit}))},1393:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("big")},{big:function(){return i(this,"big","","")}})},"13d5":function(e,t,n){"use strict";var r=n("23e7"),i=n("d58f").left,a=n("a640"),o=n("2d00"),s=n("605d"),c=a("reduce"),u=!s&&o>79&&o<83;r({target:"Array",proto:!0,forced:!c||u},{reduce:function(e){var t=arguments.length;return i(this,e,t,t>1?arguments[1]:void 0)}})},1434:function(e,t,n){(function(t){var n={readVint:function(e,t){t=t||0;for(var n=1;n<=8;n++)if(e[t]>=Math.pow(2,8-n))break;if(n>8)throw new Error("Unrepresentable length: "+n+" "+e.toString("hex",t,t+n));if(t+n>e.length)return null;for(var r=e[t]&(1<<8-n)-1,i=1;i<n;i++){if(7===i&&r>=Math.pow(2,45)&&e[t+7]>0)return{length:n,value:-1};r*=Math.pow(2,8),r+=e[t+i]}return{length:n,value:r}},writeVint:function(e){if(e<0||e>Math.pow(2,53))throw new Error("Unrepresentable value: "+e);for(var n=1;n<=8;n++)if(e<Math.pow(2,7*n)-1)break;for(var r=new t(n),i=1;i<=n;i++){var a=255&e;r[n-i]=a,e-=a,e/=Math.pow(2,8)}return r[0]=r[0]|1<<8-n,r}};e.exports=n}).call(this,n("b639").Buffer)},"143c":function(e,t,n){var r=n("74e8");r("Int32",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},"143e":function(e,t,n){"use strict";var r=n("23e7"),i=n("44d2"),a=n("4673");r({target:"Array",proto:!0},{uniqueBy:a}),i("uniqueBy")},1448:function(e,t,n){var r=n("dfb9"),i=n("b6b7");e.exports=function(e,t){return r(i(e),t)}},"145e":function(e,t,n){"use strict";var r=n("7b0b"),i=n("23cb"),a=n("07fa"),o=Math.min;e.exports=[].copyWithin||function(e,t){var n=r(this),s=a(n),c=i(e,s),u=i(t,s),l=arguments.length>2?arguments[2]:void 0,f=o((void 0===l?s:i(l,s))-u,s-c),h=1;u<c&&c<u+f&&(h=-1,u+=f-1,c+=f-1);while(f-- >0)u in n?n[c]=n[u]:delete n[c],c+=h,u+=h;return n}},"14c3":function(e,t,n){var r=n("da84"),i=n("c65b"),a=n("825a"),o=n("1626"),s=n("c6b6"),c=n("9263"),u=r.TypeError;e.exports=function(e,t){var n=e.exec;if(o(n)){var r=i(n,e,t);return null!==r&&a(r),r}if("RegExp"===s(e))return i(c,e,t);throw u("RegExp#exec called on incompatible receiver")}},"159b":function(e,t,n){var r=n("da84"),i=n("fdbc"),a=n("785a"),o=n("17c2"),s=n("9112"),c=function(e){if(e&&e.forEach!==o)try{s(e,"forEach",o)}catch(t){e.forEach=o}};for(var u in i)i[u]&&c(r[u]&&r[u].prototype);c(a)},1626:function(e,t){e.exports=function(e){return"function"==typeof e}},"170b":function(e,t,n){"use strict";var r=n("ebb5"),i=n("50c4"),a=n("23cb"),o=n("b6b7"),s=r.aTypedArray,c=r.exportTypedArrayMethod;c("subarray",(function(e,t){var n=s(this),r=n.length,c=a(e,r),u=o(n);return new u(n.buffer,n.byteOffset+c*n.BYTES_PER_ELEMENT,i((void 0===t?r:a(t,r))-c))}))},"17c2":function(e,t,n){"use strict";var r=n("b727").forEach,i=n("a640"),a=i("forEach");e.exports=a?[].forEach:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}},"17e1":function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(){if("function"==typeof ArrayBuffer){var t=e,n=t.lib,r=n.WordArray,i=r.init,a=r.init=function(e){if(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),(e instanceof Int8Array||"undefined"!==typeof Uint8ClampedArray&&e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array||e instanceof Float64Array)&&(e=new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),e instanceof Uint8Array){for(var t=e.byteLength,n=[],r=0;r<t;r++)n[r>>>2]|=e[r]<<24-r%4*8;i.call(this,n,t)}else i.apply(this,arguments)};a.prototype=r}}(),e.lib.WordArray}))},"182d":function(e,t,n){var r=n("da84"),i=n("f8cd"),a=r.RangeError;e.exports=function(e,t){var n=i(e);if(n%t)throw a("Wrong offset");return n}},"18a5":function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("anchor")},{anchor:function(e){return i(this,"a","name",e)}})},"18d5":function(e,t,n){"use strict";var r=n("d066"),i=n("5087"),a=n("a95f"),o=n("8aa7"),s=n("ebb5"),c=n("dfb9"),u=s.aTypedArrayConstructor,l=s.exportTypedArrayStaticMethod;l("fromAsync",(function(e){var t=this,n=arguments.length,o=n>1?arguments[1]:void 0,s=n>2?arguments[2]:void 0;return new(r("Promise"))((function(n){i(t),n(a(e,o,s))})).then((function(e){return c(u(t),e)}))}),o)},1913:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("fontsize")},{fontsize:function(e){return i(this,"font","size",e)}})},"191b":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("94f8"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=t.algo,a=i.SHA256,o=i.SHA224=a.extend({_doReset:function(){this._hash=new r.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var e=a._doFinalize.call(this);return e.sigBytes-=4,e}});t.SHA224=a._createHelper(o),t.HmacSHA224=a._createHmacHelper(o)}(),e.SHA224}))},"197b":function(e,t,n){var r=n("746f");r("species")},"19aa":function(e,t,n){var r=n("da84"),i=n("3a9b"),a=r.TypeError;e.exports=function(e,t){if(i(t,e))return e;throw a("Incorrect invocation")}},"1a2d":function(e,t,n){var r=n("e330"),i=n("7b0b"),a=r({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return a(i(e),t)}},"1b22":function(e,t,n){"use strict";var r=n("23e7"),i=n("dd2f").toArray;r({target:"AsyncIterator",proto:!0,real:!0},{toArray:function(){return i(this,void 0,[])}})},"1b29":function(e,t,n){"use strict";var r={128:{name:"ChapterDisplay",level:4,type:"m",multiple:!0,webm:!0,description:"Contains all possible strings to use for the chapter display."},131:{name:"TrackType",level:3,type:"u",mandatory:!0,description:"The `TrackType` defines the type of each frame found in the Track. The value **SHOULD** be stored on 1 octet."},133:{name:"ChapString",cppname:"ChapterString",level:5,type:"8",mandatory:!0,webm:!0,description:"Contains the string to use as the chapter atom."},134:{name:"CodecID",level:3,type:"s",mandatory:!0,description:"An ID corresponding to the codec, see [@!MatroskaCodec] for more info."},136:{name:"FlagDefault",cppname:"TrackFlagDefault",level:3,type:"u",mandatory:!0,default:"1",range:"0-1",description:"Set if that track (audio, video or subs) **SHOULD** be eligible for automatic selection by the player; see (#default-track-selection) for more details."},137:{name:"ChapterTrackUID",cppname:"ChapterTrackNumber",level:5,type:"u",mandatory:!0,multiple:!0,range:"not 0",description:"UID of the Track to apply this chapter to. In the absence of a control track, choosing this chapter will select the listed Tracks and deselect unlisted tracks. Absence of this Element indicates that the Chapter **SHOULD** be applied to any currently used Tracks."},142:{name:"Slices",level:3,type:"m",maxver:0,description:"Contains slices description."},143:{name:"ChapterTrack",level:4,type:"m",description:"List of tracks on which the chapter applies. If this Element is not present, all tracks apply"},145:{name:"ChapterTimeStart",level:4,type:"u",mandatory:!0,webm:!0,description:"Timestamp of the start of Chapter, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks)."},146:{name:"ChapterTimeEnd",level:4,type:"u",webm:!0,description:"Timestamp of the end of Chapter timestamp excluded, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks). The value **MUST** be greater than or equal to the `ChapterTimeStart` of the same `ChapterAtom`."},150:{name:"CueRefTime",level:5,type:"u",mandatory:!0,minver:2,description:"Timestamp of the referenced Block, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks)."},151:{name:"CueRefCluster",level:5,type:"u",mandatory:!0,minver:0,maxver:0,description:"The Segment Position of the Cluster containing the referenced Block."},152:{name:"ChapterFlagHidden",level:4,type:"u",mandatory:!0,default:"0",range:"0-1",description:"Set to 1 if a chapter is hidden. Hidden chapters **SHOULD NOT** be available to the user interface (but still to Control Tracks; see (#chapterflaghidden) on Chapter flags)."},154:{name:"FlagInterlaced",cppname:"VideoFlagInterlaced",level:4,type:"u",mandatory:!0,minver:2,webm:!0,default:"0",description:"Specify whether the video frames in this track are interlaced or not."},155:{name:"BlockDuration",level:3,type:"u",description:"The duration of the Block, expressed in Track Ticks; see (#timestamp-ticks). The BlockDuration Element can be useful at the end of a Track to define the duration of the last frame (as there is no subsequent Block available), or when there is a break in a track like for subtitle tracks."},156:{name:"FlagLacing",cppname:"TrackFlagLacing",level:3,type:"u",mandatory:!0,default:"1",range:"0-1",description:"Set to 1 if the track **MAY** contain blocks using lacing. When set to 0 all blocks **MUST** have their lacing flags set to No lacing; see (#block-lacing) on Block Lacing."},157:{name:"FieldOrder",cppname:"VideoFieldOrder",level:4,type:"u",mandatory:!0,minver:4,default:"2",description:"Specify the field ordering of video frames in this track."},159:{name:"Channels",cppname:"AudioChannels",level:4,type:"u",mandatory:!0,default:"1",range:"not 0",description:"Numbers of channels in the track."},160:{name:"BlockGroup",level:2,type:"m",multiple:!0,description:"Basic container of information containing a single Block and information specific to that Block."},161:{name:"Block",level:3,type:"b",mandatory:!0,description:"Block containing the actual data to be rendered and a timestamp relative to the Cluster Timestamp; see (#block-structure) on Block Structure."},162:{name:"BlockVirtual",level:3,type:"b",minver:0,maxver:0,description:"A Block with no data. It **MUST** be stored in the stream at the place the real Block would be in display order. "},163:{name:"SimpleBlock",level:2,type:"b",multiple:!0,minver:2,webm:!0,divx:!0,description:"Similar to Block, see (#block-structure), but without all the extra information, mostly used to reduced overhead when no extra feature is needed; see (#simpleblock-structure) on SimpleBlock Structure."},164:{name:"CodecState",level:3,type:"b",minver:2,description:"The new codec state to use. Data interpretation is private to the codec. This information **SHOULD** always be referenced by a seek entry."},165:{name:"BlockAdditional",level:5,type:"b",mandatory:!0,webm:!0,description:"Interpreted by the codec as it wishes (using the BlockAddID)."},166:{name:"BlockMore",level:4,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"Contain the BlockAdditional and some parameters."},167:{name:"Position",cppname:"ClusterPosition",level:2,type:"u",description:"The Segment Position of the Cluster in the Segment (0 in live streams). It might help to resynchronise offset on damaged streams."},170:{name:"CodecDecodeAll",level:3,type:"u",mandatory:!0,maxver:0,default:"1",range:"0-1",description:"Set to 1 if the codec can decode potentially damaged data."},171:{name:"PrevSize",cppname:"ClusterPrevSize",level:2,type:"u",description:"Size of the previous Cluster, in octets. Can be useful for backward playing."},174:{name:"TrackEntry",level:2,type:"m",mandatory:!0,multiple:!0,description:"Describes a track with all Elements."},175:{name:"EncryptedBlock",level:2,type:"b",multiple:!0,minver:0,maxver:0,description:"Similar to SimpleBlock, see (#simpleblock-structure), but the data inside the Block are Transformed (encrypt and/or signed)."},176:{name:"PixelWidth",cppname:"VideoPixelWidth",level:4,type:"u",mandatory:!0,range:"not 0",description:"Width of the encoded video frames in pixels."},178:{name:"CueDuration",level:4,type:"u",minver:4,webm:!0,description:"The duration of the block, expressed in Segment Ticks which is based on TimestampScale; see (#timestamp-ticks). If missing, the track's DefaultDuration does not apply and no duration information is available in terms of the cues."},179:{name:"CueTime",level:3,type:"u",mandatory:!0,description:"Absolute timestamp of the seek point, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks)."},181:{name:"SamplingFrequency",cppname:"AudioSamplingFreq",level:4,type:"f",mandatory:!0,default:"0x1.f4p+12",range:"> 0x0p+0",description:"Sampling frequency in Hz."},182:{name:"ChapterAtom",level:3,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"Contains the atom information to use as the chapter atom (apply to all tracks)."},183:{name:"CueTrackPositions",level:3,type:"m",mandatory:!0,multiple:!0,description:"Contain positions for different tracks corresponding to the timestamp."},185:{name:"FlagEnabled",cppname:"TrackFlagEnabled",level:3,type:"u",mandatory:!0,minver:2,webm:!0,default:"1",range:"0-1",description:"Set to 1 if the track is usable. It is possible to turn a not usable track into a usable track using chapter codecs or control tracks."},186:{name:"PixelHeight",cppname:"VideoPixelHeight",level:4,type:"u",mandatory:!0,range:"not 0",description:"Height of the encoded video frames in pixels."},187:{name:"CuePoint",level:2,type:"m",mandatory:!0,multiple:!0,description:"Contains all information relative to a seek point in the Segment."},191:{name:"CRC-32",level:-1,type:"b",minver:1,webm:!1,description:"The CRC is computed on all the data of the Master element it's in. The CRC element should be the first in it's parent master for easier reading. All level 1 elements should include a CRC-32. The CRC in use is the IEEE CRC32 Little Endian.",crc:!0},192:{name:"TrickTrackUID",level:3,type:"u",minver:0,maxver:0,divx:!0,description:"The TrackUID of the Smooth FF/RW video in the paired EBML structure corresponding to this video track. See [@?DivXTrickTrack]."},193:{name:"TrickTrackSegmentUID",level:3,type:"b",minver:0,maxver:0,divx:!0,description:"The SegmentUID of the Segment containing the track identified by TrickTrackUID. See [@?DivXTrickTrack]."},196:{name:"TrickMasterTrackSegmentUID",level:3,type:"b",minver:0,maxver:0,divx:!0,description:"The SegmentUID of the Segment containing the track identified by MasterTrackUID. See [@?DivXTrickTrack]."},198:{name:"TrickTrackFlag",level:3,type:"u",minver:0,maxver:0,divx:!0,default:"0",description:"Set to 1 if this video track is a Smooth FF/RW track. If set to 1, MasterTrackUID and MasterTrackSegUID should must be present and BlockGroups for this track must contain ReferenceFrame structures. Otherwise, TrickTrackUID and TrickTrackSegUID must be present if this track has a corresponding Smooth FF/RW track. See [@?DivXTrickTrack]."},199:{name:"TrickMasterTrackUID",level:3,type:"u",minver:0,maxver:0,divx:!0,description:"The TrackUID of the video track in the paired EBML structure that corresponds to this Smooth FF/RW track. See [@?DivXTrickTrack]."},200:{name:"ReferenceFrame",level:3,type:"m",minver:0,maxver:0,divx:!0,description:"Contains information about the last reference frame. See [@?DivXTrickTrack]."},201:{name:"ReferenceOffset",level:4,type:"u",mandatory:!0,minver:0,maxver:0,divx:!0,description:"The relative offset, in bytes, from the previous BlockGroup element for this Smooth FF/RW video track to the containing BlockGroup element. See [@?DivXTrickTrack]."},202:{name:"ReferenceTimestamp",cppname:"ReferenceTimeCode",level:4,type:"u",mandatory:!0,minver:0,maxver:0,divx:!0,description:"The timestamp of the BlockGroup pointed to by ReferenceOffset, expressed in Track Ticks; see (#timestamp-ticks). See [@?DivXTrickTrack]."},203:{name:"BlockAdditionID",cppname:"SliceBlockAddID",level:5,type:"u",minver:0,maxver:0,default:"0",description:"The ID of the BlockAdditional Element (0 is the main Block)."},204:{name:"LaceNumber",cppname:"SliceLaceNumber",level:5,type:"u",minver:0,maxver:0,description:"The reverse number of the frame in the lace (0 is the last frame, 1 is the next to last, etc). Being able to interpret this Element is not **REQUIRED** for playback."},205:{name:"FrameNumber",cppname:"SliceFrameNumber",level:5,type:"u",minver:0,maxver:0,default:"0",description:"The number of the frame to generate from this lace with this delay (allow you to generate many frames from the same Block/Frame)."},206:{name:"Delay",cppname:"SliceDelay",level:5,type:"u",minver:0,maxver:0,default:"0",description:"The delay to apply to the Element, expressed in Track Ticks; see (#timestamp-ticks)."},207:{name:"SliceDuration",level:5,type:"u",minver:0,maxver:0,default:"0",description:"The duration to apply to the Element, expressed in Track Ticks; see (#timestamp-ticks)."},215:{name:"TrackNumber",level:3,type:"u",mandatory:!0,range:"not 0",description:"The track number as used in the Block Header (using more than 127 tracks is not encouraged, though the design allows an unlimited number)."},219:{name:"CueReference",level:4,type:"m",multiple:!0,minver:2,description:"The Clusters containing the referenced Blocks."},224:{name:"Video",cppname:"TrackVideo",level:3,type:"m",description:"Video settings."},225:{name:"Audio",cppname:"TrackAudio",level:3,type:"m",description:"Audio settings."},226:{name:"TrackOperation",level:3,type:"m",minver:3,description:"Operation that needs to be applied on tracks to create this virtual track. For more details look at (#track-operation)."},227:{name:"TrackCombinePlanes",level:4,type:"m",minver:3,description:"Contains the list of all video plane tracks that need to be combined to create this 3D track"},228:{name:"TrackPlane",level:5,type:"m",mandatory:!0,multiple:!0,minver:3,description:"Contains a video plane track that need to be combined to create this 3D track"},229:{name:"TrackPlaneUID",level:6,type:"u",mandatory:!0,minver:3,range:"not 0",description:"The trackUID number of the track representing the plane."},230:{name:"TrackPlaneType",level:6,type:"u",mandatory:!0,minver:3,description:"The kind of plane this track corresponds to."},231:{name:"Timestamp",cppname:"ClusterTimecode",level:2,type:"u",mandatory:!0,description:"Absolute timestamp of the cluster, expressed in Segment Ticks which is based on TimestampScale; see (#timestamp-ticks)."},232:{name:"TimeSlice",level:4,type:"m",multiple:!0,minver:0,maxver:0,description:"Contains extra time information about the data contained in the Block. Being able to interpret this Element is not **REQUIRED** for playback."},233:{name:"TrackJoinBlocks",level:4,type:"m",minver:3,description:"Contains the list of all tracks whose Blocks need to be combined to create this virtual track"},234:{name:"CueCodecState",level:4,type:"u",mandatory:!0,minver:2,default:"0",description:"The Segment Position of the Codec State corresponding to this Cue Element. 0 means that the data is taken from the initial Track Entry."},235:{name:"CueRefCodecState",level:5,type:"u",minver:0,maxver:0,default:"0",description:"The Segment Position of the Codec State corresponding to this referenced Element. 0 means that the data is taken from the initial Track Entry."},236:{name:"Void",level:-1,type:"b",minver:1,description:"Used to void damaged data, to avoid unexpected behaviors when using damaged data. The content is discarded. Also used to reserve space in a sub-element for later use."},237:{name:"TrackJoinUID",level:5,type:"u",mandatory:!0,multiple:!0,minver:3,range:"not 0",description:"The trackUID number of a track whose blocks are used to create this virtual track."},238:{name:"BlockAddID",level:5,type:"u",mandatory:!0,webm:!0,default:"1",range:"not 0",description:"An ID to identify the BlockAdditional level. If BlockAddIDType of the corresponding block is 0, this value is also the value of BlockAddIDType for the meaning of the content of BlockAdditional."},240:{name:"CueRelativePosition",level:4,type:"u",minver:4,webm:!0,description:"The relative position inside the Cluster of the referenced SimpleBlock or BlockGroup with 0 being the first possible position for an Element inside that Cluster."},241:{name:"CueClusterPosition",level:4,type:"u",mandatory:!0,description:"The Segment Position of the Cluster containing the associated Block."},247:{name:"CueTrack",level:4,type:"u",mandatory:!0,range:"not 0",description:"The track for which a position is given."},250:{name:"ReferencePriority",level:3,type:"u",mandatory:!0,default:"0",description:"This frame is referenced and has the specified cache priority. In cache only a frame of the same or higher priority can replace this frame. A value of 0 means the frame is not referenced."},251:{name:"ReferenceBlock",level:3,type:"i",multiple:!0,description:"A timestamp value, relative to the timestamp of the Block in this BlockGroup, expressed in Track Ticks; see (#timestamp-ticks). This is used to reference other frames necessary to decode this frame. The relative value **SHOULD** correspond to a valid `Block` this `Block` depends on. Historically Matroska Writer didn't write the actual `Block(s)` this `Block` depends on, but *some* `Block` in the past. The value \"0\" **MAY** also be used to signify this `Block` cannot be decoded on its own, but without knownledge of which `Block` is necessary. In this case, other `ReferenceBlock` **MUST NOT** be found in the same `BlockGroup`. If the `BlockGroup` doesn't have any `ReferenceBlock` element, then the `Block` it contains can be decoded without using any other `Block` data."},253:{name:"ReferenceVirtual",level:3,type:"i",minver:0,maxver:0,description:"The Segment Position of the data that would otherwise be in position of the virtual block."},16804:{name:"BlockAddIDName",level:4,type:"s",minver:4,description:"A human-friendly name describing the type of BlockAdditional data, as defined by the associated Block Additional Mapping."},16868:{name:"BlockAdditionMapping",level:3,type:"m",multiple:!0,minver:4,description:"Contains elements that extend the track format, by adding content either to each frame, with BlockAddID ((#blockaddid-element)), or to the track as a whole with BlockAddIDExtraData."},16871:{name:"BlockAddIDType",level:4,type:"u",mandatory:!0,minver:4,default:"0",description:"Stores the registered identifier of the Block Additional Mapping to define how the BlockAdditional data should be handled."},16877:{name:"BlockAddIDExtraData",level:4,type:"b",minver:4,description:"Extra binary data that the BlockAddIDType can use to interpret the BlockAdditional data. The interpretation of the binary data depends on the BlockAddIDType value and the corresponding Block Additional Mapping."},16880:{name:"BlockAddIDValue",level:4,type:"u",minver:4,range:">=2",description:"If the track format extension needs content beside frames, the value refers to the BlockAddID ((#blockaddid-element)), value being described. To keep MaxBlockAdditionID as low as possible, small values **SHOULD** be used."},16980:{name:"ContentCompAlgo",level:6,type:"u",mandatory:!0,default:"0",description:"The compression algorithm used."},16981:{name:"ContentCompSettings",level:6,type:"b",description:"Settings that might be needed by the decompressor. For Header Stripping (`ContentCompAlgo`=3), the bytes that were removed from the beginning of each frames of the track."},17026:{name:"DocType",level:1,type:"s",mandatory:!0,default:"matroska",minver:1,description:"A string that describes the type of document that follows this EBML header. 'matroska' in our case or 'webm' for webm files."},17029:{name:"DocTypeReadVersion",level:1,type:"u",mandatory:!0,default:1,minver:1,description:"The minimum DocType version an interpreter has to support to read this file."},17030:{name:"EBMLVersion",level:1,type:"u",mandatory:!0,default:1,minver:1,description:"The version of EBML parser used to create the file."},17031:{name:"DocTypeVersion",level:1,type:"u",mandatory:!0,default:1,minver:1,description:"The version of DocType interpreter used to create the file."},17138:{name:"EBMLMaxIDLength",level:1,type:"u",mandatory:!0,default:"4",range:">=4"},17139:{name:"EBMLMaxSizeLength",level:1,type:"u",mandatory:!0,default:"8",range:"not 0"},17143:{name:"EBMLReadVersion",level:1,type:"u",mandatory:!0,default:1,minver:1,description:"The minimum EBML version a parser has to support to read this file."},17276:{name:"ChapLanguage",cppname:"ChapterLanguage",level:5,type:"s",mandatory:!0,multiple:!0,webm:!0,default:"eng",description:"A language corresponding to the string, in the bibliographic ISO-639-2 form [@!ISO639-2]. This Element **MUST** be ignored if a ChapLanguageIETF Element is used within the same ChapterDisplay Element."},17277:{name:"ChapLanguageIETF",level:5,type:"s",multiple:!0,minver:4,description:"Specifies a language corresponding to the ChapString in the format defined in [@!BCP47] and using the IANA Language Subtag Registry [@!IANALangRegistry]. If a ChapLanguageIETF Element is used, then any ChapLanguage and ChapCountry Elements used in the same ChapterDisplay **MUST** be ignored."},17278:{name:"ChapCountry",cppname:"ChapterCountry",level:5,type:"s",multiple:!0,webm:!0,description:"A country corresponding to the string, using the same 2 octets country-codes as in Internet domains [@!IANADomains] based on [@!ISO3166-1] alpha-2 codes. This Element **MUST** be ignored if a ChapLanguageIETF Element is used within the same ChapterDisplay Element."},17476:{name:"SegmentFamily",level:2,type:"b",multiple:!0,description:"A randomly generated unique ID that all Segments of a Linked Segment **MUST** share (128 bits)."},17505:{name:"DateUTC",level:2,type:"d",description:"The date and time that the Segment was created by the muxing application or library."},17530:{name:"TagLanguage",cppname:"TagLangue",level:4,type:"s",mandatory:!0,webm:!0,default:"und",description:"Specifies the language of the tag specified, in the Matroska languages form; see (#language-codes) on language codes. This Element **MUST** be ignored if the TagLanguageIETF Element is used within the same SimpleTag Element."},17531:{name:"TagLanguageIETF",level:4,type:"s",minver:4,description:"Specifies the language used in the TagString according to [@!BCP47] and using the IANA Language Subtag Registry [@!IANALangRegistry]. If this Element is used, then any TagLanguage Elements used in the same SimpleTag **MUST** be ignored."},17540:{name:"TagDefault",level:4,type:"u",mandatory:!0,webm:!0,default:"1",range:"0-1",description:"A boolean value to indicate if this is the default/original language to use for the given tag."},17541:{name:"TagBinary",level:4,type:"b",webm:!0,description:"The values of the Tag, if it is binary. Note that this cannot be used in the same SimpleTag as TagString."},17543:{name:"TagString",level:4,type:"8",webm:!0,description:"The value of the Tag."},17545:{name:"Duration",level:2,type:"f",range:"> 0x0p+0",description:"Duration of the Segment, expressed in Segment Ticks which is based on TimestampScale; see (#timestamp-ticks)."},17588:{name:"TagDefaultBogus",level:4,type:"u",mandatory:!0,minver:0,maxver:0,default:"1",range:"0-1",description:"A variant of the TagDefault element with a bogus Element ID; see (#tagdefault-element)."},17677:{name:"ChapProcessPrivate",cppname:"ChapterProcessPrivate",level:5,type:"b",description:'Some optional data attached to the ChapProcessCodecID information. For ChapProcessCodecID = 1, it is the "DVD level" equivalent; see (#menu-features) on DVD menus.'},17816:{name:"ChapterFlagEnabled",level:4,type:"u",mandatory:!0,default:"1",range:"0-1",description:"Set to 1 if the chapter is enabled. It can be enabled/disabled by a Control Track. When disabled, the movie **SHOULD** skip all the content between the TimeStart and TimeEnd of this chapter; see (#chapter-flags) on Chapter flags."},17827:{name:"TagName",level:4,type:"8",mandatory:!0,webm:!0,description:"The name of the Tag that is going to be stored."},17849:{name:"EditionEntry",level:2,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"Contains all information about a Segment edition."},17852:{name:"EditionUID",level:3,type:"u",range:"not 0",description:"A unique ID to identify the edition. It's useful for tagging an edition."},17853:{name:"EditionFlagHidden",level:3,type:"u",mandatory:!0,default:"0",range:"0-1",description:"Set to 1 if an edition is hidden. Hidden editions **SHOULD NOT** be available to the user interface (but still to Control Tracks; see (#chapter-flags) on Chapter flags)."},17883:{name:"EditionFlagDefault",level:3,type:"u",mandatory:!0,default:"0",range:"0-1",description:"Set to 1 if the edition **SHOULD** be used as the default one."},17885:{name:"EditionFlagOrdered",level:3,type:"u",mandatory:!0,default:"0",range:"0-1",description:"Set to 1 if the chapters can be defined multiple times and the order to play them is enforced; see (#editionflagordered)."},18012:{name:"FileData",level:3,type:"b",mandatory:!0,description:"The data of the file."},18016:{name:"FileMimeType",cppname:"MimeType",level:3,type:"s",mandatory:!0,description:"MIME type of the file."},18017:{name:"FileUsedStartTime",level:3,type:"u",minver:0,maxver:0,divx:!0,description:"The timestamp at which this optimized font attachment comes into context, expressed in Segment Ticks which is based on TimestampScale. See [@?DivXWorldFonts]."},18018:{name:"FileUsedEndTime",level:3,type:"u",minver:0,maxver:0,divx:!0,description:"The timestamp at which this optimized font attachment goes out of context, expressed in Segment Ticks which is based on TimestampScale. See [@?DivXWorldFonts]."},18030:{name:"FileName",level:3,type:"8",mandatory:!0,description:"Filename of the attached file."},18037:{name:"FileReferral",level:3,type:"b",minver:0,maxver:0,description:"A binary value that a track/codec can refer to when the attachment is needed."},18046:{name:"FileDescription",level:3,type:"8",description:"A human-friendly name for the attached file."},18094:{name:"FileUID",level:3,type:"u",mandatory:!0,range:"not 0",description:"Unique ID representing the file, as random as possible."},18401:{name:"ContentEncAlgo",level:6,type:"u",mandatory:!0,webm:!0,default:"0",description:'The encryption algorithm used. The value "0" means that the contents have not been encrypted.'},18402:{name:"ContentEncKeyID",level:6,type:"b",webm:!0,description:"For public key algorithms this is the ID of the public key the the data was encrypted with."},18403:{name:"ContentSignature",level:6,type:"b",maxver:0,description:"A cryptographic signature of the contents."},18404:{name:"ContentSigKeyID",level:6,type:"b",maxver:0,description:"This is the ID of the private key the data was signed with."},18405:{name:"ContentSigAlgo",level:6,type:"u",maxver:0,default:"0",description:"The algorithm used for the signature."},18406:{name:"ContentSigHashAlgo",level:6,type:"u",maxver:0,default:"0",description:"The hash algorithm used for the signature."},18407:{name:"ContentEncAESSettings",level:6,type:"m",minver:4,webm:!0,description:"Settings describing the encryption algorithm used. If `ContentEncAlgo` != 5 this **MUST** be ignored."},18408:{name:"AESSettingsCipherMode",level:7,type:"u",mandatory:!0,minver:4,webm:!0,description:"The AES cipher mode used in the encryption."},19840:{name:"MuxingApp",level:2,type:"8",mandatory:!0,description:'Muxing application or library (example: "libmatroska-0.4.3").'},19899:{name:"Seek",level:2,type:"m",mandatory:!0,multiple:!0,description:"Contains a single seek entry to an EBML Element."},20529:{name:"ContentEncodingOrder",level:5,type:"u",mandatory:!0,webm:!0,default:"0",description:"Tells when this modification was used during encoding/muxing starting with 0 and counting upwards. The decoder/demuxer has to start with the highest order number it finds and work its way down. This value has to be unique over all ContentEncodingOrder Elements in the TrackEntry that contains this ContentEncodingOrder element."},20530:{name:"ContentEncodingScope",level:5,type:"u",mandatory:!0,webm:!0,default:"1",description:"A bit field that describes which Elements have been modified in this way. Values (big-endian) can be OR'ed."},20531:{name:"ContentEncodingType",level:5,type:"u",mandatory:!0,webm:!0,default:"0",description:"A value describing what kind of transformation is applied."},20532:{name:"ContentCompression",level:5,type:"m",description:"Settings describing the compression used. This Element **MUST** be present if the value of ContentEncodingType is 0 and absent otherwise. Each block **MUST** be decompressable even if no previous block is available in order not to prevent seeking."},20533:{name:"ContentEncryption",level:5,type:"m",webm:!0,description:"Settings describing the encryption used. This Element **MUST** be present if the value of `ContentEncodingType` is 1 (encryption) and **MUST** be ignored otherwise."},21343:{name:"CueRefNumber",level:5,type:"u",minver:0,maxver:0,default:"1",range:"not 0",description:"Number of the referenced Block of Track X in the specified Cluster."},21358:{name:"Name",cppname:"TrackName",level:3,type:"8",description:"A human-readable track name."},21368:{name:"CueBlockNumber",level:4,type:"u",range:"not 0",description:"Number of the Block in the specified Cluster."},21375:{name:"TrackOffset",level:3,type:"i",minver:0,maxver:0,default:"0",description:"A value to add to the Block's Timestamp, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks). This can be used to adjust the playback offset of a track."},21419:{name:"SeekID",level:3,type:"b",mandatory:!0,description:"The binary ID corresponding to the Element name."},21420:{name:"SeekPosition",level:3,type:"u",mandatory:!0,description:"The Segment Position of the Element."},21432:{name:"StereoMode",cppname:"VideoStereoMode",level:4,type:"u",mandatory:!0,minver:3,webm:!0,default:"0",description:"Stereo-3D video mode. There are some more details in (#multi-planar-and-3d-videos)."},21433:{name:"OldStereoMode",level:4,type:"u",maxver:0,description:"DEPRECATED, DO NOT USE. Bogus StereoMode value used in old versions of libmatroska."},21440:{name:"AlphaMode",cppname:"VideoAlphaMode",level:4,type:"u",mandatory:!0,minver:3,webm:!0,default:"0",description:'Indicate whether the BlockAdditional Element with BlockAddID of "1" contains Alpha data, as defined by to the Codec Mapping for the `CodecID`. Undefined values **SHOULD NOT** be used as the behavior of known implementations is different (considered either as 0 or 1).'},21674:{name:"PixelCropBottom",cppname:"VideoPixelCropBottom",level:4,type:"u",mandatory:!0,default:"0",description:"The number of video pixels to remove at the bottom of the image."},21680:{name:"DisplayWidth",cppname:"VideoDisplayWidth",level:4,type:"u",range:"not 0",description:"Width of the video frames to display. Applies to the video frame after cropping (PixelCrop* Elements)."},21682:{name:"DisplayUnit",cppname:"VideoDisplayUnit",level:4,type:"u",mandatory:!0,default:"0",description:"How DisplayWidth & DisplayHeight are interpreted."},21683:{name:"AspectRatioType",cppname:"VideoAspectRatio",level:4,type:"u",minver:0,maxver:0,default:"0",description:"Specify the possible modifications to the aspect ratio."},21690:{name:"DisplayHeight",cppname:"VideoDisplayHeight",level:4,type:"u",range:"not 0",description:"Height of the video frames to display. Applies to the video frame after cropping (PixelCrop* Elements)."},21691:{name:"PixelCropTop",cppname:"VideoPixelCropTop",level:4,type:"u",mandatory:!0,default:"0",description:"The number of video pixels to remove at the top of the image."},21708:{name:"PixelCropLeft",cppname:"VideoPixelCropLeft",level:4,type:"u",mandatory:!0,default:"0",description:"The number of video pixels to remove on the left of the image."},21725:{name:"PixelCropRight",cppname:"VideoPixelCropRight",level:4,type:"u",mandatory:!0,default:"0",description:"The number of video pixels to remove on the right of the image."},21930:{name:"FlagForced",cppname:"TrackFlagForced",level:3,type:"u",mandatory:!0,default:"0",range:"0-1",description:"Applies only to subtitles. Set if that track **SHOULD** be eligible for automatic selection by the player if it matches the user's language preference, even if the user's preferences would normally not enable subtitles with the selected audio track; this can be used for tracks containing only translations of foreign-language audio or onscreen text. See (#default-track-selection) for more details."},21931:{name:"FlagHearingImpaired",level:3,type:"u",minver:4,range:"0-1",description:"Set to 1 if that track is suitable for users with hearing impairments, set to 0 if it is unsuitable for users with hearing impairments."},21932:{name:"FlagVisualImpaired",level:3,type:"u",minver:4,range:"0-1",description:"Set to 1 if that track is suitable for users with visual impairments, set to 0 if it is unsuitable for users with visual impairments."},21933:{name:"FlagTextDescriptions",level:3,type:"u",minver:4,range:"0-1",description:"Set to 1 if that track contains textual descriptions of video content, set to 0 if that track does not contain textual descriptions of video content."},21934:{name:"FlagOriginal",level:3,type:"u",minver:4,range:"0-1",description:"Set to 1 if that track is in the content's original language, set to 0 if it is a translation."},21935:{name:"FlagCommentary",level:3,type:"u",minver:4,range:"0-1",description:"Set to 1 if that track contains commentary, set to 0 if it does not contain commentary."},21936:{name:"Colour",cppname:"VideoColour",level:4,type:"m",minver:4,webm:!0,description:"Settings describing the colour format."},21937:{name:"MatrixCoefficients",cppname:"VideoColourMatrix",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"2",description:"The Matrix Coefficients of the video used to derive luma and chroma values from red, green, and blue color primaries. For clarity, the value and meanings for MatrixCoefficients are adopted from Table 4 of ISO/IEC 23001-8:2016 or ITU-T H.273."},21938:{name:"BitsPerChannel",cppname:"VideoBitsPerChannel",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"Number of decoded bits per channel. A value of 0 indicates that the BitsPerChannel is unspecified."},21939:{name:"ChromaSubsamplingHorz",cppname:"VideoChromaSubsampHorz",level:5,type:"u",minver:4,webm:!0,description:"The amount of pixels to remove in the Cr and Cb channels for every pixel not removed horizontally. Example: For video with 4:2:0 chroma subsampling, the ChromaSubsamplingHorz **SHOULD** be set to 1."},21940:{name:"ChromaSubsamplingVert",cppname:"VideoChromaSubsampVert",level:5,type:"u",minver:4,webm:!0,description:"The amount of pixels to remove in the Cr and Cb channels for every pixel not removed vertically. Example: For video with 4:2:0 chroma subsampling, the ChromaSubsamplingVert **SHOULD** be set to 1."},21941:{name:"CbSubsamplingHorz",cppname:"VideoCbSubsampHorz",level:5,type:"u",minver:4,webm:!0,description:"The amount of pixels to remove in the Cb channel for every pixel not removed horizontally. This is additive with ChromaSubsamplingHorz. Example: For video with 4:2:1 chroma subsampling, the ChromaSubsamplingHorz **SHOULD** be set to 1 and CbSubsamplingHorz **SHOULD** be set to 1."},21942:{name:"CbSubsamplingVert",cppname:"VideoCbSubsampVert",level:5,type:"u",minver:4,webm:!0,description:"The amount of pixels to remove in the Cb channel for every pixel not removed vertically. This is additive with ChromaSubsamplingVert."},21943:{name:"ChromaSitingHorz",cppname:"VideoChromaSitHorz",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"How chroma is subsampled horizontally."},21944:{name:"ChromaSitingVert",cppname:"VideoChromaSitVert",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"How chroma is subsampled vertically."},21945:{name:"Range",cppname:"VideoColourRange",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"Clipping of the color ranges."},21946:{name:"TransferCharacteristics",cppname:"VideoColourTransferCharacter",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"2",description:"The transfer characteristics of the video. For clarity, the value and meanings for TransferCharacteristics are adopted from Table 3 of ISO/IEC 23091-4 or ITU-T H.273."},21947:{name:"Primaries",cppname:"VideoColourPrimaries",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"2",description:"The colour primaries of the video. For clarity, the value and meanings for Primaries are adopted from Table 2 of ISO/IEC 23091-4 or ITU-T H.273."},21948:{name:"MaxCLL",cppname:"VideoColourMaxCLL",level:5,type:"u",minver:4,webm:!0,description:"Maximum brightness of a single pixel (Maximum Content Light Level) in candelas per square meter (cd/m^2^)."},21949:{name:"MaxFALL",cppname:"VideoColourMaxFALL",level:5,type:"u",minver:4,webm:!0,description:"Maximum brightness of a single full frame (Maximum Frame-Average Light Level) in candelas per square meter (cd/m^2^)."},21968:{name:"MasteringMetadata",cppname:"VideoColourMasterMeta",level:5,type:"m",minver:4,webm:!0,description:"SMPTE 2086 mastering data."},21969:{name:"PrimaryRChromaticityX",cppname:"VideoRChromaX",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Red X chromaticity coordinate, as defined by CIE 1931."},21970:{name:"PrimaryRChromaticityY",cppname:"VideoRChromaY",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Red Y chromaticity coordinate, as defined by CIE 1931."},21971:{name:"PrimaryGChromaticityX",cppname:"VideoGChromaX",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Green X chromaticity coordinate, as defined by CIE 1931."},21972:{name:"PrimaryGChromaticityY",cppname:"VideoGChromaY",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Green Y chromaticity coordinate, as defined by CIE 1931."},21973:{name:"PrimaryBChromaticityX",cppname:"VideoBChromaX",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Blue X chromaticity coordinate, as defined by CIE 1931."},21974:{name:"PrimaryBChromaticityY",cppname:"VideoBChromaY",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"Blue Y chromaticity coordinate, as defined by CIE 1931."},21975:{name:"WhitePointChromaticityX",cppname:"VideoWhitePointChromaX",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"White X chromaticity coordinate, as defined by CIE 1931."},21976:{name:"WhitePointChromaticityY",cppname:"VideoWhitePointChromaY",level:6,type:"f",minver:4,webm:!0,range:"0-1",description:"White Y chromaticity coordinate, as defined by CIE 1931."},21977:{name:"LuminanceMax",cppname:"VideoLuminanceMax",level:6,type:"f",minver:4,webm:!0,range:">= 0x0p+0",description:"Maximum luminance. Represented in candelas per square meter (cd/m^2^)."},21978:{name:"LuminanceMin",cppname:"VideoLuminanceMin",level:6,type:"f",minver:4,webm:!0,range:">= 0x0p+0",description:"Minimum luminance. Represented in candelas per square meter (cd/m^2^)."},21998:{name:"MaxBlockAdditionID",level:3,type:"u",mandatory:!0,default:"0",description:"The maximum value of BlockAddID ((#blockaddid-element)). A value 0 means there is no BlockAdditions ((#blockadditions-element)) for this track."},22100:{name:"ChapterStringUID",level:4,type:"8",minver:3,webm:!0,description:"A unique string ID to identify the Chapter. Use for WebVTT cue identifier storage [@!WebVTT]."},22186:{name:"CodecDelay",level:3,type:"u",mandatory:!0,minver:4,webm:!0,description:"CodecDelay is The codec-built-in delay, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks). It represents the amount of codec samples that will be discarded by the decoder during playback. This timestamp value **MUST** be subtracted from each frame timestamp in order to get the timestamp that will be actually played. The value **SHOULD** be small so the muxing of tracks with the same actual timestamp are in the same Cluster."},22203:{name:"SeekPreRoll",level:3,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"After a discontinuity, SeekPreRoll is the duration of the data the decoder **MUST** decode before the decoded data is valid, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks)."},22337:{name:"WritingApp",level:2,type:"8",mandatory:!0,description:'Writing application (example: "mkvmerge-0.3.3").'},22612:{name:"SilentTracks",cppname:"ClusterSilentTracks",level:2,type:"m",minver:0,maxver:0,description:"The list of tracks that are not used in that part of the stream. It is useful when using overlay tracks on seeking or to decide what track to use."},22743:{name:"SilentTrackNumber",cppname:"ClusterSilentTrackNumber",level:3,type:"u",multiple:!0,minver:0,maxver:0,description:"One of the track number that are not used from now on in the stream. It could change later if not specified as silent in a further Cluster."},24999:{name:"AttachedFile",cppname:"Attached",level:2,type:"m",mandatory:!0,multiple:!0,description:"An attached file."},25152:{name:"ContentEncoding",level:4,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"Settings for one content encoding like compression or encryption."},25188:{name:"BitDepth",cppname:"AudioBitDepth",level:4,type:"u",range:"not 0",description:"Bits per sample, mostly used for PCM."},25506:{name:"CodecPrivate",level:3,type:"b",description:"Private data only known to the codec."},25536:{name:"Targets",cppname:"TagTargets",level:3,type:"m",mandatory:!0,webm:!0,description:"Specifies which other elements the metadata represented by the Tag applies to. If empty or not present, then the Tag describes everything in the Segment."},25539:{name:"ChapterPhysicalEquiv",level:4,type:"u",description:'Specify the physical equivalent of this ChapterAtom like "DVD" (60) or "SIDE" (50); see (#physical-types) for a complete list of values.'},25540:{name:"TagChapterUID",level:4,type:"u",multiple:!0,default:"0",description:"A unique ID to identify the Chapter(s) the tags belong to."},25541:{name:"TagTrackUID",level:4,type:"u",multiple:!0,webm:!0,default:"0",description:"A unique ID to identify the Track(s) the tags belong to."},25542:{name:"TagAttachmentUID",level:4,type:"u",multiple:!0,default:"0",description:"A unique ID to identify the Attachment(s) the tags belong to."},25545:{name:"TagEditionUID",level:4,type:"u",multiple:!0,default:"0",description:"A unique ID to identify the EditionEntry(s) the tags belong to."},25546:{name:"TargetType",cppname:"TagTargetType",level:4,type:"s",webm:!0,description:'An informational string that can be used to display the logical level of the target like "ALBUM", "TRACK", "MOVIE", "CHAPTER", etc ; see Section 6.4 of [@!MatroskaTags].'},25906:{name:"SignedElement",level:2,type:"b",multiple:!0,webm:!1,description:"An element ID whose data will be used to compute the signature."},26148:{name:"TrackTranslate",level:3,type:"m",multiple:!0,description:"The mapping between this `TrackEntry` and a track value in the given Chapter Codec."},26277:{name:"TrackTranslateTrackID",level:4,type:"b",mandatory:!0,description:"The binary value used to represent this `TrackEntry` in the chapter codec data. The format depends on the `ChapProcessCodecID` used; see (#chapprocesscodecid-element)."},26303:{name:"TrackTranslateCodec",level:4,type:"u",mandatory:!0,description:"This `TrackTranslate` applies to this chapter codec of the given chapter edition(s); see (#chapprocesscodecid-element)."},26364:{name:"TrackTranslateEditionUID",level:4,type:"u",multiple:!0,description:"Specify a chapter edition UID on which this `TrackTranslate` applies."},26568:{name:"SimpleTag",cppname:"TagSimple",level:3,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"Contains general information about the target."},26826:{name:"TargetTypeValue",cppname:"TagTargetTypeValue",level:4,type:"u",mandatory:!0,webm:!0,default:"50",description:"A number to indicate the logical level of the target."},26897:{name:"ChapProcessCommand",cppname:"ChapterProcessCommand",level:5,type:"m",multiple:!0,description:"Contains all the commands associated to the Atom."},26914:{name:"ChapProcessTime",cppname:"ChapterProcessTime",level:6,type:"u",mandatory:!0,description:"Defines when the process command **SHOULD** be handled"},26916:{name:"ChapterTranslate",level:2,type:"m",multiple:!0,description:"The mapping between this `Segment` and a segment value in the given Chapter Codec."},26931:{name:"ChapProcessData",cppname:"ChapterProcessData",level:6,type:"b",mandatory:!0,description:"Contains the command information. The data **SHOULD** be interpreted depending on the ChapProcessCodecID value. For ChapProcessCodecID = 1, the data correspond to the binary DVD cell pre/post commands; see (#menu-features) on DVD menus."},26948:{name:"ChapProcess",cppname:"ChapterProcess",level:4,type:"m",multiple:!0,description:"Contains all the commands associated to the Atom."},26965:{name:"ChapProcessCodecID",cppname:"ChapterProcessCodecID",level:5,type:"u",mandatory:!0,default:"0",description:"Contains the type of the codec used for the processing. A value of 0 means native Matroska processing (to be defined), a value of 1 means the DVD command set is used; see (#menu-features) on DVD menus. More codec IDs can be added later."},27045:{name:"ChapterTranslateID",level:3,type:"b",mandatory:!0,description:"The binary value used to represent this Segment in the chapter codec data. The format depends on the ChapProcessCodecID used; see (#chapprocesscodecid-element)."},27071:{name:"ChapterTranslateCodec",level:3,type:"u",mandatory:!0,description:"This `ChapterTranslate` applies to this chapter codec of the given chapter edition(s); see (#chapprocesscodecid-element)."},27132:{name:"ChapterTranslateEditionUID",level:3,type:"u",multiple:!0,description:"Specify a chapter edition UID on which this `ChapterTranslate` applies."},28032:{name:"ContentEncodings",level:3,type:"m",webm:!0,description:"Settings for several content encoding mechanisms like compression or encryption."},28135:{name:"MinCache",cppname:"TrackMinCache",level:3,type:"u",mandatory:!0,default:"0",description:"The minimum number of frames a player **SHOULD** be able to cache during playback. If set to 0, the reference pseudo-cache system is not used."},28152:{name:"MaxCache",cppname:"TrackMaxCache",level:3,type:"u",description:"The maximum cache size necessary to store referenced frames in and the current frame. 0 means no cache is needed."},28263:{name:"ChapterSegmentUID",level:4,type:"b",range:">0",description:"The SegmentUID of another Segment to play during this chapter."},28348:{name:"ChapterSegmentEditionUID",level:4,type:"u",range:"not 0",description:"The EditionUID to play from the Segment linked in ChapterSegmentUID. If ChapterSegmentEditionUID is undeclared, then no Edition of the linked Segment is used; see (#medium-linking) on medium-linking Segments."},28587:{name:"TrackOverlay",level:3,type:"u",multiple:!0,description:"Specify that this track is an overlay track for the Track specified (in the u-integer). That means when this track has a gap, see (#silenttracks-element) on SilentTracks, the overlay track **SHOULD** be used instead. The order of multiple TrackOverlay matters, the first one is the one that **SHOULD** be used. If not found it **SHOULD** be the second, etc."},29555:{name:"Tag",level:2,type:"m",mandatory:!0,multiple:!0,webm:!0,description:"A single metadata descriptor."},29572:{name:"SegmentFilename",level:2,type:"8",description:"A filename corresponding to this Segment."},29604:{name:"SegmentUID",level:2,type:"b",range:"not 0",description:"A randomly generated unique ID to identify the Segment amongst many others (128 bits)."},29636:{name:"ChapterUID",level:4,type:"u",mandatory:!0,webm:!0,range:"not 0",description:"A unique ID to identify the Chapter."},29637:{name:"TrackUID",level:3,type:"u",mandatory:!0,range:"not 0",description:"A unique ID to identify the Track."},29766:{name:"AttachmentLink",cppname:"TrackAttachmentLink",level:3,type:"u",maxver:3,range:"not 0",description:"The UID of an attachment that is used by this codec."},30113:{name:"BlockAdditions",level:3,type:"m",webm:!0,description:"Contain additional blocks to complete the main one. An EBML parser that has no knowledge of the Block structure could still see and use/skip these data."},30114:{name:"DiscardPadding",level:3,type:"i",minver:4,webm:!0,description:"Duration of the silent data added to the Block, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks) (padding at the end of the Block for positive value, at the beginning of the Block for negative value). The duration of DiscardPadding is not calculated in the duration of the TrackEntry and **SHOULD** be discarded during playback."},30320:{name:"Projection",cppname:"VideoProjection",level:4,type:"m",minver:4,webm:!0,description:"Describes the video projection details. Used to render spherical, VR videos or flipping videos horizontally/vertically."},30321:{name:"ProjectionType",cppname:"VideoProjectionType",level:5,type:"u",mandatory:!0,minver:4,webm:!0,default:"0",description:"Describes the projection used for this video track."},30322:{name:"ProjectionPrivate",cppname:"VideoProjectionPrivate",level:5,type:"b",minver:4,webm:!0,description:"Private data that only applies to a specific projection. * If `ProjectionType` equals 0 (Rectangular), then this element must not be present. * If `ProjectionType` equals 1 (Equirectangular), then this element must be present and contain the same binary data that would be stored inside an ISOBMFF Equirectangular Projection Box ('equi'). * If `ProjectionType` equals 2 (Cubemap), then this element must be present and contain the same binary data that would be stored inside an ISOBMFF Cubemap Projection Box ('cbmp'). * If `ProjectionType` equals 3 (Mesh), then this element must be present and contain the same binary data that would be stored inside an ISOBMFF Mesh Projection Box ('mshp')."},30323:{name:"ProjectionPoseYaw",cppname:"VideoProjectionPoseYaw",level:5,type:"f",mandatory:!0,minver:4,webm:!0,default:"0x0p+0",range:">= -0xB4p+0, <= 0xB4p+0",description:"Specifies a yaw rotation to the projection. Value represents a clockwise rotation, in degrees, around the up vector. This rotation must be applied before any `ProjectionPosePitch` or `ProjectionPoseRoll` rotations. The value of this element **MUST** be in the -180 to 180 degree range, both included. Setting `ProjectionPoseYaw` to 180 or -180 degrees, with the `ProjectionPoseRoll` and `ProjectionPosePitch` set to 0 degrees flips the image horizontally."},30324:{name:"ProjectionPosePitch",cppname:"VideoProjectionPosePitch",level:5,type:"f",mandatory:!0,minver:4,webm:!0,default:"0x0p+0",range:">= -0x5Ap+0, <= 0x5Ap+0",description:"Specifies a pitch rotation to the projection. Value represents a counter-clockwise rotation, in degrees, around the right vector. This rotation must be applied after the `ProjectionPoseYaw` rotation and before the `ProjectionPoseRoll` rotation. The value of this element **MUST** be in the -90 to 90 degree range, both included."},30325:{name:"ProjectionPoseRoll",cppname:"VideoProjectionPoseRoll",level:5,type:"f",mandatory:!0,minver:4,webm:!0,default:"0x0p+0",range:">= -0xB4p+0, <= 0xB4p+0",description:"Specifies a roll rotation to the projection. Value represents a counter-clockwise rotation, in degrees, around the forward vector. This rotation must be applied after the `ProjectionPoseYaw` and `ProjectionPosePitch` rotations. The value of this element **MUST** be in the -180 to 180 degree range, both included. Setting `ProjectionPoseRoll` to 180 or -180 degrees, the `ProjectionPoseYaw` to 180 or -180 degrees with `ProjectionPosePitch` set to 0 degrees flips the image vertically. Setting `ProjectionPoseRoll` to 180 or -180 degrees, with the `ProjectionPoseYaw` and `ProjectionPosePitch` set to 0 degrees flips the image horizontally and vertically."},30901:{name:"OutputSamplingFrequency",cppname:"AudioOutputSamplingFreq",level:4,type:"f",range:"> 0x0p+0",description:"Real output sampling frequency in Hz (used for SBR techniques)."},31657:{name:"Title",level:2,type:"8",webm:!0,description:"General name of the Segment."},32123:{name:"ChannelPositions",cppname:"AudioPosition",level:4,type:"b",minver:0,maxver:0,description:"Table of horizontal angles for each successive channel."},32347:{name:"SignatureElements",level:1,type:"m",webm:!1,description:"Contains elements that will be used to compute the signature."},32379:{name:"SignatureElementList",level:2,type:"m",multiple:!0,webm:!1,i:"Cluster|Block|BlockAdditional",description:"A list consists of a number of consecutive elements that represent one case where data is used in signature. Ex: means that the BlockAdditional of all Blocks in all Clusters is used for encryption."},32394:{name:"SignatureAlgo",level:2,type:"u",webm:!1,description:"Signature algorithm used (1=RSA, 2=elliptic)."},32410:{name:"SignatureHash",level:2,type:"u",webm:!1,description:"Hash algorithm used (1=SHA1-160, 2=MD5)."},32421:{name:"SignaturePublicKey",level:2,type:"b",webm:!1,description:"The public key to use with the algorithm (in the case of a PKI-based signature)."},32437:{name:"Signature",level:2,type:"b",webm:!1,description:"The signature of the data (until a new."},2274716:{name:"Language",cppname:"TrackLanguage",level:3,type:"s",mandatory:!0,default:"eng",description:"Specifies the language of the track in the Matroska languages form; see (#language-codes) on language codes. This Element **MUST** be ignored if the LanguageIETF Element is used in the same TrackEntry."},2274717:{name:"LanguageIETF",level:3,type:"s",minver:4,description:"Specifies the language of the track according to [@!BCP47] and using the IANA Language Subtag Registry [@!IANALangRegistry]. If this Element is used, then any Language Elements used in the same TrackEntry **MUST** be ignored."},2306383:{name:"TrackTimestampScale",cppname:"TrackTimecodeScale",level:3,type:"f",mandatory:!0,maxver:3,default:"0x1p+0",range:"> 0x0p+0",description:"DEPRECATED, DO NOT USE. The scale to apply on this track to work at normal speed in relation with other tracks (mostly used to adjust video speed when the audio length differs)."},2313850:{name:"DefaultDecodedFieldDuration",cppname:"TrackDefaultDecodedFieldDuration",level:3,type:"u",minver:4,range:"not 0",description:"The period between two successive fields at the output of the decoding process, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks). see (#defaultdecodedfieldduration) for more information"},2327523:{name:"FrameRate",cppname:"VideoFrameRate",level:4,type:"f",minver:0,maxver:0,range:"> 0x0p+0",description:"Number of frames per second. This value is Informational only. It is intended for constant frame rate streams, and **SHOULD NOT** be used for a variable frame rate TrackEntry."},2352003:{name:"DefaultDuration",cppname:"TrackDefaultDuration",level:3,type:"u",range:"not 0",description:"Number of nanoseconds per frame, expressed in Matroska Ticks -- ie in nanoseconds; see (#timestamp-ticks) (frame in the Matroska sense -- one Element put into a (Simple)Block)."},2459272:{name:"CodecName",level:3,type:"8",description:"A human-readable string specifying the codec."},2536e3:{name:"CodecDownloadURL",level:3,type:"s",multiple:!0,minver:0,maxver:0,description:"A URL to download about the codec used."},2807729:{name:"TimestampScale",cppname:"TimecodeScale",level:2,type:"u",mandatory:!0,default:"1000000",range:"not 0",description:"Base unit for Segment Ticks and Track Ticks, in nanoseconds. A TimestampScale value of 1.000.000 means scaled timestamps in the Segment are expressed in milliseconds; see (#timestamps) on how to interpret timestamps."},2807730:{name:"TimecodeScaleDenominator",level:2,type:"u",mandatory:!0,minver:4,default:"1000000000",description:"Timestamp scale numerator, see TimecodeScale."},3061028:{name:"UncompressedFourCC",cppname:"VideoColourSpace",level:4,type:"b",description:"Specify the uncompressed pixel format used for the Track's data as a FourCC. This value is similar in scope to the biCompression value of AVI's `BITMAPINFO` [@?AVIFormat]. See the YUV video formats [@?FourCC-YUV] and RGB video formats [@?FourCC-RGB] for common values."},3126563:{name:"GammaValue",cppname:"VideoGamma",level:4,type:"f",minver:0,maxver:0,range:"> 0x0p+0",description:"Gamma Value."},3839639:{name:"CodecSettings",level:3,type:"8",minver:0,maxver:0,description:"A string describing the encoding setting used."},3883072:{name:"CodecInfoURL",level:3,type:"s",multiple:!0,minver:0,maxver:0,description:"A URL to find information about the codec used."},3965867:{name:"PrevFilename",level:2,type:"8",description:"A filename corresponding to the file of the previous Linked Segment."},3979555:{name:"PrevUID",level:2,type:"b",description:"A unique ID to identify the previous Segment of a Linked Segment (128 bits)."},4096955:{name:"NextFilename",level:2,type:"8",description:"A filename corresponding to the file of the next Linked Segment."},4110627:{name:"NextUID",level:2,type:"b",description:"A unique ID to identify the next Segment of a Linked Segment (128 bits)."},272869232:{name:"Chapters",level:1,type:"m",webm:!0,description:"A system to define basic menus and partition data. For more detailed information, look at the Chapters explanation in (#chapters)."},290298740:{name:"SeekHead",level:1,type:"m",multiple:!0,description:"Contains the Segment Position of other Top-Level Elements."},307544935:{name:"Tags",level:1,type:"m",multiple:!0,webm:!0,description:"Element containing metadata describing Tracks, Editions, Chapters, Attachments, or the Segment as a whole. A list of valid tags can be found in [@!MatroskaTags]."},357149030:{name:"Info",level:1,type:"m",mandatory:!0,description:"Contains general information about the Segment."},374648427:{name:"Tracks",level:1,type:"m",description:"A Top-Level Element of information with many tracks described."},408125543:{name:"Segment",level:0,type:"m",mandatory:!0,description:"The Root Element that contains all other Top-Level Elements (Elements defined only at Level 1). A Matroska file is composed of 1 Segment."},423732329:{name:"Attachments",level:1,type:"m",description:"Contain attached files."},440786851:{name:"EBML",level:"0",type:"m",mandatory:!0,multiple:!1,minver:1,description:"Set the EBML characteristics of the data to follow. Each EBML document has to start with this."},458458727:{name:"SignatureSlot",level:1,type:"m",multiple:!0,webm:!1,description:"Contain signature of some (coming) elements in the stream."},475249515:{name:"Cues",level:1,type:"m",description:"A Top-Level Element to speed seeking access. All entries are local to the Segment."},524531317:{name:"Cluster",level:1,type:"m",multiple:!0,description:"The Top-Level Element containing the (monolithic) Block structure."}},i={},a={byEbmlID:r,byName:i};for(var o in r){var s=r[o];i[s.name.replace("-","_")]=parseInt(o,10)}e.exports=a},"1b3b":function(e,t,n){"use strict";var r=n("df7e"),i=n("ebb5"),a=i.aTypedArray,o=i.exportTypedArrayMethod,s=i.TYPED_ARRAY_CONSTRUCTOR;o("toReversed",(function(){return r(a(this),this[s])}))},"1be4":function(e,t,n){var r=n("d066");e.exports=r("document","documentElement")},"1bf2":function(e,t,n){var r=n("23e7"),i=n("56ef");r({target:"Reflect",stat:!0},{ownKeys:i})},"1c7e":function(e,t,n){var r=n("b622"),i=r("iterator"),a=!1;try{var o=0,s={next:function(){return{done:!!o++}},return:function(){a=!0}};s[i]=function(){return this},Array.from(s,(function(){throw 2}))}catch(c){}e.exports=function(e,t){if(!t&&!a)return!1;var n=!1;try{var r={};r[i]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch(c){}return n}},"1cdc":function(e,t,n){var r=n("342f");e.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)},"1d10":function(e,t,n){"use strict";var r=n("23e7"),i=n("dd2f").some;r({target:"AsyncIterator",proto:!0,real:!0},{some:function(e){return i(this,e)}})},"1d1c":function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("37e8").f;r({target:"Object",stat:!0,forced:Object.defineProperties!==a,sham:!i},{defineProperties:a})},"1d2b":function(e,t,n){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}}},"1d80":function(e,t,n){var r=n("da84"),i=r.TypeError;e.exports=function(e){if(void 0==e)throw i("Can't call method on "+e);return e}},"1dde":function(e,t,n){var r=n("d039"),i=n("b622"),a=n("2d00"),o=i("species");e.exports=function(e){return a>=51||!r((function(){var t=[],n=t.constructor={};return n[o]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},"1e25":function(e,t,n){"use strict";var r=n("23e7"),i=n("58a8").end,a=n("c8d2"),o=a("trimEnd"),s=o?function(){return i(this)}:"".trimEnd;r({target:"String",proto:!0,name:"trimEnd",forced:o},{trimEnd:s,trimRight:s})},"1ec1":function(e,t){var n=Math.log;e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:n(1+e)}},"1fb5":function(e,t,n){"use strict";t.byteLength=l,t.toByteArray=h,t.fromByteArray=v;for(var r=[],i=[],a="undefined"!==typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=o.length;s<c;++s)r[s]=o[s],i[o.charCodeAt(s)]=s;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function l(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r}function f(e,t,n){return 3*(t+n)/4-n}function h(e){var t,n,r=u(e),o=r[0],s=r[1],c=new a(f(e,o,s)),l=0,h=s>0?o-4:o;for(n=0;n<h;n+=4)t=i[e.charCodeAt(n)]<<18|i[e.charCodeAt(n+1)]<<12|i[e.charCodeAt(n+2)]<<6|i[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;return 2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,c[l++]=255&t),1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t),c}function d(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[63&e]}function p(e,t,n){for(var r,i=[],a=t;a<n;a+=3)r=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),i.push(d(r));return i.join("")}function v(e){for(var t,n=e.length,i=n%3,a=[],o=16383,s=0,c=n-i;s<c;s+=o)a.push(p(e,s,s+o>c?c:s+o));return 1===i?(t=e[n-1],a.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],a.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},"1fe2":function(e,t,n){"use strict";var r=n("6d61"),i=n("acac");r("WeakSet",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},"20a2":function(e,t,n){(function(e){!function(t){var n,r="undefined",i=r!==typeof e&&e,a=r!==typeof Uint8Array&&Uint8Array,o=r!==typeof ArrayBuffer&&ArrayBuffer,s=[0,0,0,0,0,0,0,0],c=Array.isArray||E,u=4294967296,l=16777216;function f(e,c,f){var E=c?0:4,_=c?4:0,k=c?0:3,w=c?1:2,A=c?2:1,R=c?3:0,x=c?g:T,C=c?b:S,I=D.prototype,P="is"+e,O="_"+P;return I.buffer=void 0,I.offset=0,I[O]=!0,I.toNumber=N,I.toString=L,I.toJSON=N,I.toArray=h,i&&(I.toBuffer=d),a&&(I.toArrayBuffer=p),D[P]=U,t[e]=D,D;function D(e,t,n,r){return this instanceof D?M(this,e,t,n,r):new D(e,t,n,r)}function U(e){return!(!e||!e[O])}function M(e,t,i,c,u){if(a&&o&&(t instanceof o&&(t=new a(t)),c instanceof o&&(c=new a(c))),t||i||c||n){if(!v(t,i)){var l=n||Array;u=i,c=t,i=0,t=new l(8)}e.buffer=t,e.offset=i|=0,r!==typeof c&&("string"===typeof c?B(t,i,c,u||10):v(c,u)?m(t,i,c,u):"number"===typeof u?(F(t,i+E,c),F(t,i+_,u)):c>0?x(t,i,c):c<0?C(t,i,c):m(t,i,s,0))}else e.buffer=y(s,0)}function B(e,t,n,r){var i=0,a=n.length,o=0,s=0;"-"===n[0]&&i++;var c=i;while(i<a){var l=parseInt(n[i++],r);if(!(l>=0))break;s=s*r+l,o=o*r+Math.floor(s/u),s%=u}c&&(o=~o,s?s=u-s:o++),F(e,t+E,o),F(e,t+_,s)}function N(){var e=this.buffer,t=this.offset,n=j(e,t+E),r=j(e,t+_);return f||(n|=0),n?n*u+r:r}function L(e){var t=this.buffer,n=this.offset,r=j(t,n+E),i=j(t,n+_),a="",o=!f&&2147483648&r;o&&(r=~r,i=u-i),e=e||10;while(1){var s=r%e*u+i;if(r=Math.floor(r/e),i=Math.floor(s/e),a=(s%e).toString(e)+a,!r&&!i)break}return o&&(a="-"+a),a}function F(e,t,n){e[t+R]=255&n,n>>=8,e[t+A]=255&n,n>>=8,e[t+w]=255&n,n>>=8,e[t+k]=255&n}function j(e,t){return e[t+k]*l+(e[t+w]<<16)+(e[t+A]<<8)+e[t+R]}}function h(e){var t=this.buffer,r=this.offset;return n=null,!1!==e&&0===r&&8===t.length&&c(t)?t:y(t,r)}function d(t){var r=this.buffer,a=this.offset;if(n=i,!1!==t&&0===a&&8===r.length&&e.isBuffer(r))return r;var o=new i(8);return m(o,0,r,a),o}function p(e){var t=this.buffer,r=this.offset,i=t.buffer;if(n=a,!1!==e&&0===r&&i instanceof o&&8===i.byteLength)return i;var s=new a(8);return m(s,0,t,r),s.buffer}function v(e,t){var n=e&&e.length;return t|=0,n&&t+8<=n&&"string"!==typeof e[t]}function m(e,t,n,r){t|=0,r|=0;for(var i=0;i<8;i++)e[t++]=255&n[r++]}function y(e,t){return Array.prototype.slice.call(e,t,t+8)}function g(e,t,n){var r=t+8;while(r>t)e[--r]=255&n,n/=256}function b(e,t,n){var r=t+8;n++;while(r>t)e[--r]=255&-n^255,n/=256}function T(e,t,n){var r=t+8;while(t<r)e[t++]=255&n,n/=256}function S(e,t,n){var r=t+8;n++;while(t<r)e[t++]=255&-n^255,n/=256}function E(e){return!!e&&"[object Array]"==Object.prototype.toString.call(e)}f("Uint64BE",!0,!0),f("Int64BE",!0,!1),f("Uint64LE",!1,!0),f("Int64LE",!1,!1)}("string"!==typeof t.nodeName?t:this||{})}).call(this,n("b639").Buffer)},"20bf":function(e,t,n){"use strict";var r=n("8aa7"),i=n("ebb5").exportTypedArrayStaticMethod,a=n("a078");i("from",a,r)},"219c":function(e,t,n){"use strict";var r=n("da84"),i=n("e330"),a=n("d039"),o=n("59ed"),s=n("addb"),c=n("ebb5"),u=n("04d1"),l=n("d998"),f=n("2d00"),h=n("512c"),d=r.Array,p=c.aTypedArray,v=c.exportTypedArrayMethod,m=r.Uint16Array,y=m&&i(m.prototype.sort),g=!!y&&!(a((function(){y(new m(2),null)}))&&a((function(){y(new m(2),{})}))),b=!!y&&!a((function(){if(f)return f<74;if(u)return u<67;if(l)return!0;if(h)return h<602;var e,t,n=new m(516),r=d(516);for(e=0;e<516;e++)t=e%4,n[e]=515-e,r[e]=e-2*t+3;for(y(n,(function(e,t){return(e/4|0)-(t/4|0)})),e=0;e<516;e++)if(n[e]!==r[e])return!0})),T=function(e){return function(t,n){return void 0!==e?+e(t,n)||0:n!==n?-1:t!==t?1:0===t&&0===n?1/t>0&&1/n<0?1:-1:t>n}};v("sort",(function(e){return void 0!==e&&o(e),b?y(this,e):s(p(this),T(e))}),!b||g)},"21bf":function(e,t,n){(function(t){(function(t,n){e.exports=n()})(0,(function(){var e=e||function(e,r){var i;if("undefined"!==typeof window&&window.crypto&&(i=window.crypto),"undefined"!==typeof self&&self.crypto&&(i=self.crypto),"undefined"!==typeof globalThis&&globalThis.crypto&&(i=globalThis.crypto),!i&&"undefined"!==typeof window&&window.msCrypto&&(i=window.msCrypto),!i&&"undefined"!==typeof t&&t.crypto&&(i=t.crypto),!i)try{i=n(0)}catch(y){}var a=function(){if(i){if("function"===typeof i.getRandomValues)try{return i.getRandomValues(new Uint32Array(1))[0]}catch(y){}if("function"===typeof i.randomBytes)try{return i.randomBytes(4).readInt32LE()}catch(y){}}throw new Error("Native crypto module could not be used to get secure random number.")},o=Object.create||function(){function e(){}return function(t){var n;return e.prototype=t,n=new e,e.prototype=null,n}}(),s={},c=s.lib={},u=c.Base=function(){return{extend:function(e){var t=o(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),l=c.WordArray=u.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=t!=r?t:4*e.length},toString:function(e){return(e||h).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;if(this.clamp(),r%4)for(var a=0;a<i;a++){var o=n[a>>>2]>>>24-a%4*8&255;t[r+a>>>2]|=o<<24-(r+a)%4*8}else for(var s=0;s<i;s+=4)t[r+s>>>2]=n[s>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=u.clone.call(this);return e.words=this.words.slice(0),e},random:function(e){for(var t=[],n=0;n<e;n+=4)t.push(a());return new l.init(t,e)}}),f=s.enc={},h=f.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var a=t[i>>>2]>>>24-i%4*8&255;r.push((a>>>4).toString(16)),r.push((15&a).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new l.init(n,t/2)}},d=f.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var a=t[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(a))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new l.init(n,t)}},p=f.Utf8={stringify:function(e){try{return decodeURIComponent(escape(d.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return d.parse(unescape(encodeURIComponent(e)))}},v=c.BufferedBlockAlgorithm=u.extend({reset:function(){this._data=new l.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=p.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n,r=this._data,i=r.words,a=r.sigBytes,o=this.blockSize,s=4*o,c=a/s;c=t?e.ceil(c):e.max((0|c)-this._minBufferSize,0);var u=c*o,f=e.min(4*u,a);if(u){for(var h=0;h<u;h+=o)this._doProcessBlock(i,h);n=i.splice(0,u),r.sigBytes-=f}return new l.init(n,f)},clone:function(){var e=u.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),m=(c.Hasher=v.extend({cfg:u.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){v.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){e&&this._append(e);var t=this._doFinalize();return t},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new m.HMAC.init(e,n).finalize(t)}}}),s.algo={});return s}(Math);return e}))}).call(this,n("c8ba"))},2266:function(e,t,n){var r=n("da84"),i=n("0366"),a=n("c65b"),o=n("825a"),s=n("0d51"),c=n("e95a"),u=n("07fa"),l=n("3a9b"),f=n("9a1f"),h=n("35a1"),d=n("2a62"),p=r.TypeError,v=function(e,t){this.stopped=e,this.result=t},m=v.prototype;e.exports=function(e,t,n){var r,y,g,b,T,S,E,_=n&&n.that,k=!(!n||!n.AS_ENTRIES),w=!(!n||!n.IS_ITERATOR),A=!(!n||!n.INTERRUPTED),R=i(t,_),x=function(e){return r&&d(r,"normal",e),new v(!0,e)},C=function(e){return k?(o(e),A?R(e[0],e[1],x):R(e[0],e[1])):A?R(e,x):R(e)};if(w)r=e;else{if(y=h(e),!y)throw p(s(e)+" is not iterable");if(c(y)){for(g=0,b=u(e);b>g;g++)if(T=C(e[g]),T&&l(m,T))return T;return new v(!1)}r=f(e,y)}S=r.next;while(!(E=a(S,r)).done){try{T=C(E.value)}catch(I){d(r,"throw",I)}if("object"==typeof T&&T&&l(m,T))return T}return new v(!1)}},2315:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("strike")},{strike:function(){return i(this,"strike","","")}})},2351:function(e,t,n){var r=n("746f");r("split")},2382:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("59ed"),o=n("825a"),s=n("c5cc"),c=n("9bdd"),u=s((function(e){var t,n,r,a=this.iterator,s=this.filterer,u=this.next;while(1){if(t=o(i(u,a,e)),n=this.done=!!t.done,n)return;if(r=t.value,c(a,s,r))return r}}));r({target:"Iterator",proto:!0,real:!0},{filter:function(e){return new u({iterator:o(this),filterer:a(e)})}})},"23cb":function(e,t,n){var r=n("5926"),i=Math.max,a=Math.min;e.exports=function(e,t){var n=r(e);return n<0?i(n+t,0):a(n,t)}},"23dc":function(e,t,n){var r=n("d44e");r(Math,"Math",!0)},"23e7":function(e,t,n){var r=n("da84"),i=n("06cf").f,a=n("9112"),o=n("6eeb"),s=n("ce4e"),c=n("e893"),u=n("94ca");e.exports=function(e,t){var n,l,f,h,d,p,v=e.target,m=e.global,y=e.stat;if(l=m?r:y?r[v]||s(v,{}):(r[v]||{}).prototype,l)for(f in t){if(d=t[f],e.noTargetGet?(p=i(l,f),h=p&&p.value):h=l[f],n=u(m?f:v+(y?".":"#")+f,e.forced),!n&&void 0!==h){if(typeof d==typeof h)continue;c(d,h)}(e.sham||h&&h.sham)&&a(d,"sham",!0),o(l,f,d,e)}}},"241c":function(e,t,n){var r=n("ca84"),i=n("7839"),a=i.concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,a)}},2444:function(e,t,n){"use strict";(function(t){var r=n("c532"),i=n("c8af"),a=n("387f"),o={"Content-Type":"application/x-www-form-urlencoded"};function s(e,t){!r.isUndefined(e)&&r.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function c(){var e;return("undefined"!==typeof XMLHttpRequest||"undefined"!==typeof t&&"[object process]"===Object.prototype.toString.call(t))&&(e=n("b50d")),e}function u(e,t,n){if(r.isString(e))try{return(t||JSON.parse)(e),r.trim(e)}catch(i){if("SyntaxError"!==i.name)throw i}return(n||JSON.stringify)(e)}var l={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:c(),transformRequest:[function(e,t){return i(t,"Accept"),i(t,"Content-Type"),r.isFormData(e)||r.isArrayBuffer(e)||r.isBuffer(e)||r.isStream(e)||r.isFile(e)||r.isBlob(e)?e:r.isArrayBufferView(e)?e.buffer:r.isURLSearchParams(e)?(s(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):r.isObject(e)||t&&"application/json"===t["Content-Type"]?(s(t,"application/json"),u(e)):e}],transformResponse:[function(e){var t=this.transitional||l.transitional,n=t&&t.silentJSONParsing,i=t&&t.forcedJSONParsing,o=!n&&"json"===this.responseType;if(o||i&&r.isString(e)&&e.length)try{return JSON.parse(e)}catch(s){if(o){if("SyntaxError"===s.name)throw a(s,this,"E_JSON_PARSE");throw s}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(e){l.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){l.headers[e]=r.merge(o)})),e.exports=l}).call(this,n("4362"))},2532:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("5a34"),o=n("1d80"),s=n("577e"),c=n("ab13"),u=i("".indexOf);r({target:"String",proto:!0,forced:!c("includes")},{includes:function(e){return!!~u(s(o(this)),s(a(e)),arguments.length>1?arguments[1]:void 0)}})},"25a1":function(e,t,n){"use strict";var r=n("ebb5"),i=n("d58f").right,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("reduceRight",(function(e){var t=arguments.length;return i(a(this),e,t,t>1?arguments[1]:void 0)}))},"25eb":function(e,t,n){var r=n("23e7"),i=n("c20d");r({target:"Number",stat:!0,forced:Number.parseInt!=i},{parseInt:i})},"25f0":function(e,t,n){"use strict";var r=n("e330"),i=n("5e77").PROPER,a=n("6eeb"),o=n("825a"),s=n("3a9b"),c=n("577e"),u=n("d039"),l=n("ad6d"),f="toString",h=RegExp.prototype,d=h[f],p=r(l),v=u((function(){return"/a/b"!=d.call({source:"a",flags:"b"})})),m=i&&d.name!=f;(v||m)&&a(RegExp.prototype,f,(function(){var e=o(this),t=c(e.source),n=e.flags,r=c(void 0===n&&s(h,e)&&!("flags"in h)?p(e):n);return"/"+t+"/"+r}),{unsafe:!0})},2626:function(e,t,n){"use strict";var r=n("d066"),i=n("9bf2"),a=n("b622"),o=n("83ab"),s=a("species");e.exports=function(e){var t=r(e),n=i.f;o&&t&&!t[s]&&n(t,s,{configurable:!0,get:function(){return this}})}},"26ad":function(e,t,n){"use strict";var r=n("23e7"),i=n("dd2f").forEach;r({target:"AsyncIterator",proto:!0,real:!0},{forEach:function(e){return i(this,e)}})},"26e9":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("e8b5"),o=i([].reverse),s=[1,2];r({target:"Array",proto:!0,forced:String(s)===String(s.reverse())},{reverse:function(){return a(this)&&(this.length=this.length),o(this)}})},2705:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c430"),o=n("59ed"),s=n("825a"),c=n("5860"),u=n("2266"),l=i.TypeError;r({target:"Set",proto:!0,real:!0,forced:a},{reduce:function(e){var t=s(this),n=c(t),r=arguments.length<2,i=r?void 0:arguments[1];if(o(e),u(n,(function(n){r?(r=!1,i=n):i=e(i,n,n,t)}),{IS_ITERATOR:!0}),r)throw l("Reduce of empty set with no initial value");return i}})},2713:function(e,t,n){"use strict";var r=n("c65b"),i=n("59ed"),a=n("825a");e.exports=function(e,t){var n=a(this),o=i(n.get),s=i(n.has),c=i(n.set),u=r(s,n,e)&&"update"in t?t.update(r(o,n,e),e,n):t.insert(e,n);return r(c,n,e,u),u}},"277d":function(e,t,n){var r=n("23e7"),i=n("e8b5");r({target:"Array",stat:!0},{isArray:i})},2954:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b6b7"),a=n("d039"),o=n("f36a"),s=r.aTypedArray,c=r.exportTypedArrayMethod,u=a((function(){new Int8Array(1).slice()}));c("slice",(function(e,t){var n=o(s(this),e,t),r=i(this),a=0,c=n.length,u=new r(c);while(c>a)u[a]=n[a++];return u}),u)},"2a1b":function(e,t,n){var r=n("746f");r("match")},"2a62":function(e,t,n){var r=n("c65b"),i=n("825a"),a=n("dc4a");e.exports=function(e,t,n){var o,s;i(e);try{if(o=a(e,"return"),!o){if("throw"===t)throw n;return n}o=r(o,e)}catch(c){s=!0,o=c}if("throw"===t)throw n;if(s)throw o;return i(o),n}},"2a66":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.pad.ZeroPadding={pad:function(e,t){var n=4*t;e.clamp(),e.sigBytes+=n-(e.sigBytes%n||n)},unpad:function(e){var t=e.words,n=e.sigBytes-1;for(n=e.sigBytes-1;n>=0;n--)if(t[n>>>2]>>>24-n%4*8&255){e.sigBytes=n+1;break}}},e.pad.ZeroPadding}))},"2abc":function(e,t,n){var r=n("23e7"),i=180/Math.PI;r({target:"Math",stat:!0},{degrees:function(e){return e*i}})},"2af1":function(e,t,n){var r=n("23e7"),i=n("f748");r({target:"Math",stat:!0},{sign:i})},"2b19":function(e,t,n){var r=n("23e7"),i=n("129f");r({target:"Object",stat:!0},{is:i})},"2b3d":function(e,t,n){"use strict";n("3ca3");var r,i=n("23e7"),a=n("83ab"),o=n("0d3b"),s=n("da84"),c=n("0366"),u=n("e330"),l=n("37e8").f,f=n("6eeb"),h=n("19aa"),d=n("1a2d"),p=n("60da"),v=n("4df4"),m=n("4dae"),y=n("6547").codeAt,g=n("5fb2"),b=n("577e"),T=n("d44e"),S=n("9861"),E=n("69f3"),_=E.set,k=E.getterFor("URL"),w=S.URLSearchParams,A=S.getState,R=s.URL,x=s.TypeError,C=s.parseInt,I=Math.floor,P=Math.pow,O=u("".charAt),D=u(/./.exec),U=u([].join),M=u(1..toString),B=u([].pop),N=u([].push),L=u("".replace),F=u([].shift),j=u("".split),W=u("".slice),H=u("".toLowerCase),V=u([].unshift),q="Invalid authority",z="Invalid scheme",G="Invalid host",Y="Invalid port",K=/[a-z]/i,X=/[\d+-.a-z]/i,Q=/\d/,$=/^0x/i,Z=/^[0-7]+$/,J=/^\d+$/,ee=/^[\da-f]+$/i,te=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ne=/[\0\t\n\r #/:<>?@[\\\]^|]/,re=/^[\u0000-\u0020]+|[\u0000-\u0020]+$/g,ie=/[\t\n\r]/g,ae=function(e){var t,n,r,i,a,o,s,c=j(e,".");if(c.length&&""==c[c.length-1]&&c.length--,t=c.length,t>4)return e;for(n=[],r=0;r<t;r++){if(i=c[r],""==i)return e;if(a=10,i.length>1&&"0"==O(i,0)&&(a=D($,i)?16:8,i=W(i,8==a?1:2)),""===i)o=0;else{if(!D(10==a?J:8==a?Z:ee,i))return e;o=C(i,a)}N(n,o)}for(r=0;r<t;r++)if(o=n[r],r==t-1){if(o>=P(256,5-t))return null}else if(o>255)return null;for(s=B(n),r=0;r<n.length;r++)s+=n[r]*P(256,3-r);return s},oe=function(e){var t,n,r,i,a,o,s,c=[0,0,0,0,0,0,0,0],u=0,l=null,f=0,h=function(){return O(e,f)};if(":"==h()){if(":"!=O(e,1))return;f+=2,u++,l=u}while(h()){if(8==u)return;if(":"!=h()){t=n=0;while(n<4&&D(ee,h()))t=16*t+C(h(),16),f++,n++;if("."==h()){if(0==n)return;if(f-=n,u>6)return;r=0;while(h()){if(i=null,r>0){if(!("."==h()&&r<4))return;f++}if(!D(Q,h()))return;while(D(Q,h())){if(a=C(h(),10),null===i)i=a;else{if(0==i)return;i=10*i+a}if(i>255)return;f++}c[u]=256*c[u]+i,r++,2!=r&&4!=r||u++}if(4!=r)return;break}if(":"==h()){if(f++,!h())return}else if(h())return;c[u++]=t}else{if(null!==l)return;f++,u++,l=u}}if(null!==l){o=u-l,u=7;while(0!=u&&o>0)s=c[u],c[u--]=c[l+o-1],c[l+--o]=s}else if(8!=u)return;return c},se=function(e){for(var t=null,n=1,r=null,i=0,a=0;a<8;a++)0!==e[a]?(i>n&&(t=r,n=i),r=null,i=0):(null===r&&(r=a),++i);return i>n&&(t=r,n=i),t},ce=function(e){var t,n,r,i;if("number"==typeof e){for(t=[],n=0;n<4;n++)V(t,e%256),e=I(e/256);return U(t,".")}if("object"==typeof e){for(t="",r=se(e),n=0;n<8;n++)i&&0===e[n]||(i&&(i=!1),r===n?(t+=n?":":"::",i=!0):(t+=M(e[n],16),n<7&&(t+=":")));return"["+t+"]"}return e},ue={},le=p({},ue,{" ":1,'"':1,"<":1,">":1,"`":1}),fe=p({},le,{"#":1,"?":1,"{":1,"}":1}),he=p({},fe,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),de=function(e,t){var n=y(e,0);return n>32&&n<127&&!d(t,e)?e:encodeURIComponent(e)},pe={ftp:21,file:null,http:80,https:443,ws:80,wss:443},ve=function(e,t){var n;return 2==e.length&&D(K,O(e,0))&&(":"==(n=O(e,1))||!t&&"|"==n)},me=function(e){var t;return e.length>1&&ve(W(e,0,2))&&(2==e.length||"/"===(t=O(e,2))||"\\"===t||"?"===t||"#"===t)},ye=function(e){return"."===e||"%2e"===H(e)},ge=function(e){return e=H(e),".."===e||"%2e."===e||".%2e"===e||"%2e%2e"===e},be={},Te={},Se={},Ee={},_e={},ke={},we={},Ae={},Re={},xe={},Ce={},Ie={},Pe={},Oe={},De={},Ue={},Me={},Be={},Ne={},Le={},Fe={},je=function(e,t,n){var r,i,a,o=b(e);if(t){if(i=this.parse(o),i)throw x(i);this.searchParams=null}else{if(void 0!==n&&(r=new je(n,!0)),i=this.parse(o,null,r),i)throw x(i);a=A(new w),a.bindURL(this),this.searchParams=a}};je.prototype={type:"URL",parse:function(e,t,n){var i,a,o,s,c=this,u=t||be,l=0,f="",h=!1,p=!1,y=!1;e=b(e),t||(c.scheme="",c.username="",c.password="",c.host=null,c.port=null,c.path=[],c.query=null,c.fragment=null,c.cannotBeABaseURL=!1,e=L(e,re,"")),e=L(e,ie,""),i=v(e);while(l<=i.length){switch(a=i[l],u){case be:if(!a||!D(K,a)){if(t)return z;u=Se;continue}f+=H(a),u=Te;break;case Te:if(a&&(D(X,a)||"+"==a||"-"==a||"."==a))f+=H(a);else{if(":"!=a){if(t)return z;f="",u=Se,l=0;continue}if(t&&(c.isSpecial()!=d(pe,f)||"file"==f&&(c.includesCredentials()||null!==c.port)||"file"==c.scheme&&!c.host))return;if(c.scheme=f,t)return void(c.isSpecial()&&pe[c.scheme]==c.port&&(c.port=null));f="","file"==c.scheme?u=Oe:c.isSpecial()&&n&&n.scheme==c.scheme?u=Ee:c.isSpecial()?u=Ae:"/"==i[l+1]?(u=_e,l++):(c.cannotBeABaseURL=!0,N(c.path,""),u=Ne)}break;case Se:if(!n||n.cannotBeABaseURL&&"#"!=a)return z;if(n.cannotBeABaseURL&&"#"==a){c.scheme=n.scheme,c.path=m(n.path),c.query=n.query,c.fragment="",c.cannotBeABaseURL=!0,u=Fe;break}u="file"==n.scheme?Oe:ke;continue;case Ee:if("/"!=a||"/"!=i[l+1]){u=ke;continue}u=Re,l++;break;case _e:if("/"==a){u=xe;break}u=Be;continue;case ke:if(c.scheme=n.scheme,a==r)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=m(n.path),c.query=n.query;else if("/"==a||"\\"==a&&c.isSpecial())u=we;else if("?"==a)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=m(n.path),c.query="",u=Le;else{if("#"!=a){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=m(n.path),c.path.length--,u=Be;continue}c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=m(n.path),c.query=n.query,c.fragment="",u=Fe}break;case we:if(!c.isSpecial()||"/"!=a&&"\\"!=a){if("/"!=a){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,u=Be;continue}u=xe}else u=Re;break;case Ae:if(u=Re,"/"!=a||"/"!=O(f,l+1))continue;l++;break;case Re:if("/"!=a&&"\\"!=a){u=xe;continue}break;case xe:if("@"==a){h&&(f="%40"+f),h=!0,o=v(f);for(var g=0;g<o.length;g++){var T=o[g];if(":"!=T||y){var S=de(T,he);y?c.password+=S:c.username+=S}else y=!0}f=""}else if(a==r||"/"==a||"?"==a||"#"==a||"\\"==a&&c.isSpecial()){if(h&&""==f)return q;l-=v(f).length+1,f="",u=Ce}else f+=a;break;case Ce:case Ie:if(t&&"file"==c.scheme){u=Ue;continue}if(":"!=a||p){if(a==r||"/"==a||"?"==a||"#"==a||"\\"==a&&c.isSpecial()){if(c.isSpecial()&&""==f)return G;if(t&&""==f&&(c.includesCredentials()||null!==c.port))return;if(s=c.parseHost(f),s)return s;if(f="",u=Me,t)return;continue}"["==a?p=!0:"]"==a&&(p=!1),f+=a}else{if(""==f)return G;if(s=c.parseHost(f),s)return s;if(f="",u=Pe,t==Ie)return}break;case Pe:if(!D(Q,a)){if(a==r||"/"==a||"?"==a||"#"==a||"\\"==a&&c.isSpecial()||t){if(""!=f){var E=C(f,10);if(E>65535)return Y;c.port=c.isSpecial()&&E===pe[c.scheme]?null:E,f=""}if(t)return;u=Me;continue}return Y}f+=a;break;case Oe:if(c.scheme="file","/"==a||"\\"==a)u=De;else{if(!n||"file"!=n.scheme){u=Be;continue}if(a==r)c.host=n.host,c.path=m(n.path),c.query=n.query;else if("?"==a)c.host=n.host,c.path=m(n.path),c.query="",u=Le;else{if("#"!=a){me(U(m(i,l),""))||(c.host=n.host,c.path=m(n.path),c.shortenPath()),u=Be;continue}c.host=n.host,c.path=m(n.path),c.query=n.query,c.fragment="",u=Fe}}break;case De:if("/"==a||"\\"==a){u=Ue;break}n&&"file"==n.scheme&&!me(U(m(i,l),""))&&(ve(n.path[0],!0)?N(c.path,n.path[0]):c.host=n.host),u=Be;continue;case Ue:if(a==r||"/"==a||"\\"==a||"?"==a||"#"==a){if(!t&&ve(f))u=Be;else if(""==f){if(c.host="",t)return;u=Me}else{if(s=c.parseHost(f),s)return s;if("localhost"==c.host&&(c.host=""),t)return;f="",u=Me}continue}f+=a;break;case Me:if(c.isSpecial()){if(u=Be,"/"!=a&&"\\"!=a)continue}else if(t||"?"!=a)if(t||"#"!=a){if(a!=r&&(u=Be,"/"!=a))continue}else c.fragment="",u=Fe;else c.query="",u=Le;break;case Be:if(a==r||"/"==a||"\\"==a&&c.isSpecial()||!t&&("?"==a||"#"==a)){if(ge(f)?(c.shortenPath(),"/"==a||"\\"==a&&c.isSpecial()||N(c.path,"")):ye(f)?"/"==a||"\\"==a&&c.isSpecial()||N(c.path,""):("file"==c.scheme&&!c.path.length&&ve(f)&&(c.host&&(c.host=""),f=O(f,0)+":"),N(c.path,f)),f="","file"==c.scheme&&(a==r||"?"==a||"#"==a))while(c.path.length>1&&""===c.path[0])F(c.path);"?"==a?(c.query="",u=Le):"#"==a&&(c.fragment="",u=Fe)}else f+=de(a,fe);break;case Ne:"?"==a?(c.query="",u=Le):"#"==a?(c.fragment="",u=Fe):a!=r&&(c.path[0]+=de(a,ue));break;case Le:t||"#"!=a?a!=r&&("'"==a&&c.isSpecial()?c.query+="%27":c.query+="#"==a?"%23":de(a,ue)):(c.fragment="",u=Fe);break;case Fe:a!=r&&(c.fragment+=de(a,le));break}l++}},parseHost:function(e){var t,n,r;if("["==O(e,0)){if("]"!=O(e,e.length-1))return G;if(t=oe(W(e,1,-1)),!t)return G;this.host=t}else if(this.isSpecial()){if(e=g(e),D(te,e))return G;if(t=ae(e),null===t)return G;this.host=t}else{if(D(ne,e))return G;for(t="",n=v(e),r=0;r<n.length;r++)t+=de(n[r],ue);this.host=t}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||"file"==this.scheme},includesCredentials:function(){return""!=this.username||""!=this.password},isSpecial:function(){return d(pe,this.scheme)},shortenPath:function(){var e=this.path,t=e.length;!t||"file"==this.scheme&&1==t&&ve(e[0],!0)||e.length--},serialize:function(){var e=this,t=e.scheme,n=e.username,r=e.password,i=e.host,a=e.port,o=e.path,s=e.query,c=e.fragment,u=t+":";return null!==i?(u+="//",e.includesCredentials()&&(u+=n+(r?":"+r:"")+"@"),u+=ce(i),null!==a&&(u+=":"+a)):"file"==t&&(u+="//"),u+=e.cannotBeABaseURL?o[0]:o.length?"/"+U(o,"/"):"",null!==s&&(u+="?"+s),null!==c&&(u+="#"+c),u},setHref:function(e){var t=this.parse(e);if(t)throw x(t);this.searchParams.update()},getOrigin:function(){var e=this.scheme,t=this.port;if("blob"==e)try{return new We(e.path[0]).origin}catch(n){return"null"}return"file"!=e&&this.isSpecial()?e+"://"+ce(this.host)+(null!==t?":"+t:""):"null"},getProtocol:function(){return this.scheme+":"},setProtocol:function(e){this.parse(b(e)+":",be)},getUsername:function(){return this.username},setUsername:function(e){var t=v(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var n=0;n<t.length;n++)this.username+=de(t[n],he)}},getPassword:function(){return this.password},setPassword:function(e){var t=v(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var n=0;n<t.length;n++)this.password+=de(t[n],he)}},getHost:function(){var e=this.host,t=this.port;return null===e?"":null===t?ce(e):ce(e)+":"+t},setHost:function(e){this.cannotBeABaseURL||this.parse(e,Ce)},getHostname:function(){var e=this.host;return null===e?"":ce(e)},setHostname:function(e){this.cannotBeABaseURL||this.parse(e,Ie)},getPort:function(){var e=this.port;return null===e?"":b(e)},setPort:function(e){this.cannotHaveUsernamePasswordPort()||(e=b(e),""==e?this.port=null:this.parse(e,Pe))},getPathname:function(){var e=this.path;return this.cannotBeABaseURL?e[0]:e.length?"/"+U(e,"/"):""},setPathname:function(e){this.cannotBeABaseURL||(this.path=[],this.parse(e,Me))},getSearch:function(){var e=this.query;return e?"?"+e:""},setSearch:function(e){e=b(e),""==e?this.query=null:("?"==O(e,0)&&(e=W(e,1)),this.query="",this.parse(e,Le)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var e=this.fragment;return e?"#"+e:""},setHash:function(e){e=b(e),""!=e?("#"==O(e,0)&&(e=W(e,1)),this.fragment="",this.parse(e,Fe)):this.fragment=null},update:function(){this.query=this.searchParams.serialize()||null}};var We=function(e){var t=h(this,He),n=arguments.length>1?arguments[1]:void 0,r=_(t,new je(e,!1,n));a||(t.href=r.serialize(),t.origin=r.getOrigin(),t.protocol=r.getProtocol(),t.username=r.getUsername(),t.password=r.getPassword(),t.host=r.getHost(),t.hostname=r.getHostname(),t.port=r.getPort(),t.pathname=r.getPathname(),t.search=r.getSearch(),t.searchParams=r.getSearchParams(),t.hash=r.getHash())},He=We.prototype,Ve=function(e,t){return{get:function(){return k(this)[e]()},set:t&&function(e){return k(this)[t](e)},configurable:!0,enumerable:!0}};if(a&&l(He,{href:Ve("serialize","setHref"),origin:Ve("getOrigin"),protocol:Ve("getProtocol","setProtocol"),username:Ve("getUsername","setUsername"),password:Ve("getPassword","setPassword"),host:Ve("getHost","setHost"),hostname:Ve("getHostname","setHostname"),port:Ve("getPort","setPort"),pathname:Ve("getPathname","setPathname"),search:Ve("getSearch","setSearch"),searchParams:Ve("getSearchParams"),hash:Ve("getHash","setHash")}),f(He,"toJSON",(function(){return k(this).serialize()}),{enumerable:!0}),f(He,"toString",(function(){return k(this).serialize()}),{enumerable:!0}),R){var qe=R.createObjectURL,ze=R.revokeObjectURL;qe&&f(We,"createObjectURL",c(qe,R)),ze&&f(We,"revokeObjectURL",c(ze,R))}T(We,"URL"),i({global:!0,forced:!o,sham:!a},{URL:We})},"2b79":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("df2f"),n("5980"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.Base,i=n.WordArray,a=t.algo,o=a.MD5,s=a.EvpKDF=r.extend({cfg:r.extend({keySize:4,hasher:o,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){var n,r=this.cfg,a=r.hasher.create(),o=i.create(),s=o.words,c=r.keySize,u=r.iterations;while(s.length<c){n&&a.update(n),n=a.update(e).finalize(t),a.reset();for(var l=1;l<u;l++)n=a.finalize(n),a.reset();o.concat(n)}return o.sigBytes=4*c,o}});t.EvpKDF=function(e,t,n){return s.create(n).compute(e,t)}}(),e.EvpKDF}))},"2ba4":function(e,t,n){var r=n("40d5"),i=Function.prototype,a=i.apply,o=i.call;e.exports="object"==typeof Reflect&&Reflect.apply||(r?o.bind(a):function(){return o.apply(a,arguments)})},"2c3e":function(e,t,n){var r=n("da84"),i=n("83ab"),a=n("9f7f").MISSED_STICKY,o=n("c6b6"),s=n("9bf2").f,c=n("69f3").get,u=RegExp.prototype,l=r.TypeError;i&&a&&s(u,"sticky",{configurable:!0,get:function(){if(this!==u){if("RegExp"===o(this))return!!c(this).sticky;throw l("Incompatible receiver, RegExp required")}}})},"2ca0":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("06cf").f,o=n("50c4"),s=n("577e"),c=n("5a34"),u=n("1d80"),l=n("ab13"),f=n("c430"),h=i("".startsWith),d=i("".slice),p=Math.min,v=l("startsWith"),m=!f&&!v&&!!function(){var e=a(String.prototype,"startsWith");return e&&!e.writable}();r({target:"String",proto:!0,forced:!m&&!v},{startsWith:function(e){var t=s(u(this));c(e);var n=o(p(arguments.length>1?arguments[1]:void 0,t.length)),r=s(e);return h?h(t,r,n):d(t,n,n+r.length)===r}})},"2cf4":function(e,t,n){var r,i,a,o,s=n("da84"),c=n("2ba4"),u=n("0366"),l=n("1626"),f=n("1a2d"),h=n("d039"),d=n("1be4"),p=n("f36a"),v=n("cc12"),m=n("1cdc"),y=n("605d"),g=s.setImmediate,b=s.clearImmediate,T=s.process,S=s.Dispatch,E=s.Function,_=s.MessageChannel,k=s.String,w=0,A={},R="onreadystatechange";try{r=s.location}catch(O){}var x=function(e){if(f(A,e)){var t=A[e];delete A[e],t()}},C=function(e){return function(){x(e)}},I=function(e){x(e.data)},P=function(e){s.postMessage(k(e),r.protocol+"//"+r.host)};g&&b||(g=function(e){var t=p(arguments,1);return A[++w]=function(){c(l(e)?e:E(e),void 0,t)},i(w),w},b=function(e){delete A[e]},y?i=function(e){T.nextTick(C(e))}:S&&S.now?i=function(e){S.now(C(e))}:_&&!m?(a=new _,o=a.port2,a.port1.onmessage=I,i=u(o.postMessage,o)):s.addEventListener&&l(s.postMessage)&&!s.importScripts&&r&&"file:"!==r.protocol&&!h(P)?(i=P,s.addEventListener("message",I,!1)):i=R in v("script")?function(e){d.appendChild(v("script"))[R]=function(){d.removeChild(this),x(e)}}:function(e){setTimeout(C(e),0)}),e.exports={set:g,clear:b}},"2d00":function(e,t,n){var r,i,a=n("da84"),o=n("342f"),s=a.process,c=a.Deno,u=s&&s.versions||c&&c.version,l=u&&u.v8;l&&(r=l.split("."),i=r[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&o&&(r=o.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=o.match(/Chrome\/(\d+)/),r&&(i=+r[1]))),e.exports=i},"2d83":function(e,t,n){"use strict";var r=n("387f");e.exports=function(e,t,n,i,a){var o=new Error(e);return r(o,t,n,i,a)}},"2e67":function(e,t,n){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},"30b5":function(e,t,n){"use strict";var r=n("c532");function i(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,n){if(!t)return e;var a;if(n)a=n(t);else if(r.isURLSearchParams(t))a=t.toString();else{var o=[];r.forEach(t,(function(e,t){null!==e&&"undefined"!==typeof e&&(r.isArray(e)?t+="[]":e=[e],r.forEach(e,(function(e){r.isDate(e)?e=e.toISOString():r.isObject(e)&&(e=JSON.stringify(e)),o.push(i(t)+"="+i(e))})))})),a=o.join("&")}if(a){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+a}return e}},3252:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(t){var n=e,r=n.lib,i=r.Base,a=r.WordArray,o=n.x64={};o.Word=i.extend({init:function(e,t){this.high=e,this.low=t}}),o.WordArray=i.extend({init:function(e,n){e=this.words=e||[],this.sigBytes=n!=t?n:8*e.length},toX32:function(){for(var e=this.words,t=e.length,n=[],r=0;r<t;r++){var i=e[r];n.push(i.high),n.push(i.low)}return a.create(n,this.sigBytes)},clone:function(){for(var e=i.clone.call(this),t=e.words=this.words.slice(0),n=t.length,r=0;r<n;r++)t[r]=t[r].clone();return e}})}(),e}))},3280:function(e,t,n){"use strict";var r=n("ebb5"),i=n("2ba4"),a=n("e58c"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("lastIndexOf",(function(e){var t=arguments.length;return i(a,o(this),t>1?[e,arguments[1]]:[e])}))},3393:function(e,t,n){"use strict";var r=n("23e7"),i=n("fd81");r({target:"Number",stat:!0},{range:function(e,t,n){return new i(e,t,n,"number",0,1)}})},"33d1":function(e,t,n){"use strict";var r=n("23e7"),i=n("7b0b"),a=n("07fa"),o=n("5926"),s=n("44d2");r({target:"Array",proto:!0},{at:function(e){var t=i(this),n=a(t),r=o(e),s=r>=0?r:n+r;return s<0||s>=n?void 0:t[s]}}),s("at")},3410:function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("7b0b"),o=n("e163"),s=n("e177"),c=i((function(){o(1)}));r({target:"Object",stat:!0,forced:c,sham:!s},{getPrototypeOf:function(e){return o(a(e))}})},"342f":function(e,t,n){var r=n("d066");e.exports=r("navigator","userAgent")||""},3452:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("3252"),n("17e1"),n("a8ce"),n("1132"),n("c1bc"),n("72fe"),n("df2f"),n("94f8"),n("191b"),n("d6e6"),n("b86b"),n("e61b"),n("10b7"),n("5980"),n("7bbc"),n("2b79"),n("38ba"),n("00bb"),n("f4ea"),n("aaef"),n("4ba9"),n("81bf"),n("a817"),n("a11b"),n("8cef"),n("2a66"),n("b86c"),n("6d08"),n("c198"),n("a40e"),n("c3b6"),n("1382"),n("3d5a"))})(0,(function(e){return e}))},"34a3":function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").filterReject,a=n("44d2");r({target:"Array",proto:!0},{filterReject:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a("filterReject")},"355d":function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("825a"),o=n("e285"),s=n("9ed3"),c=n("69f3"),u="Seeded Random",l=u+" Generator",f='Math.seededPRNG() argument should have a "seed" field with a finite value.',h=c.set,d=c.getterFor(l),p=i.TypeError,v=s((function(e){h(this,{type:l,seed:e%2147483647})}),u,(function(){var e=d(this),t=e.seed=(1103515245*e.seed+12345)%2147483647;return{value:(1073741823&t)/1073741823,done:!1}}));r({target:"Math",stat:!0,forced:!0},{seededPRNG:function(e){var t=a(e).seed;if(!o(t))throw p(f);return new v(t)}})},"35a1":function(e,t,n){var r=n("f5df"),i=n("dc4a"),a=n("3f8c"),o=n("b622"),s=o("iterator");e.exports=function(e){if(void 0!=e)return i(e,s)||i(e,"@@iterator")||a[r(e)]}},"35b3":function(e,t,n){var r=n("23e7");r({target:"Number",stat:!0},{EPSILON:Math.pow(2,-52)})},"36a4":function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{isubh:function(e,t,n,r){var i=e>>>0,a=t>>>0,o=n>>>0;return a-(r>>>0)-((~i&o|~(i^o)&i-o>>>0)>>>31)|0}})},"37e8":function(e,t,n){var r=n("83ab"),i=n("aed9"),a=n("9bf2"),o=n("825a"),s=n("fc6a"),c=n("df75");t.f=r&&!i?Object.defineProperties:function(e,t){o(e);var n,r=s(t),i=c(t),u=i.length,l=0;while(u>l)a.f(e,n=i[l++],r[n]);return e}},"387f":function(e,t,n){"use strict";e.exports=function(e,t,n,r,i){return e.config=t,n&&(e.code=n),e.request=r,e.response=i,e.isAxiosError=!0,e.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,status:this.response&&this.response.status?this.response.status:null}},e}},"38ba":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("2b79"))})(0,(function(e){e.lib.Cipher||function(t){var n=e,r=n.lib,i=r.Base,a=r.WordArray,o=r.BufferedBlockAlgorithm,s=n.enc,c=(s.Utf8,s.Base64),u=n.algo,l=u.EvpKDF,f=r.Cipher=o.extend({cfg:i.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){o.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){e&&this._append(e);var t=this._doFinalize();return t},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?_:T}return function(t){return{encrypt:function(n,r,i){return e(r).encrypt(t,n,r,i)},decrypt:function(n,r,i){return e(r).decrypt(t,n,r,i)}}}}()}),h=(r.StreamCipher=f.extend({_doFinalize:function(){var e=this._process(!0);return e},blockSize:1}),n.mode={}),d=r.BlockCipherMode=i.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),p=h.CBC=function(){var e=d.extend();function n(e,n,r){var i,a=this._iv;a?(i=a,this._iv=t):i=this._prevBlock;for(var o=0;o<r;o++)e[n+o]^=i[o]}return e.Encryptor=e.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize;n.call(this,e,t,i),r.encryptBlock(e,t),this._prevBlock=e.slice(t,t+i)}}),e.Decryptor=e.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize,a=e.slice(t,t+i);r.decryptBlock(e,t),n.call(this,e,t,i),this._prevBlock=a}}),e}(),v=n.pad={},m=v.Pkcs7={pad:function(e,t){for(var n=4*t,r=n-e.sigBytes%n,i=r<<24|r<<16|r<<8|r,o=[],s=0;s<r;s+=4)o.push(i);var c=a.create(o,r);e.concat(c)},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},y=(r.BlockCipher=f.extend({cfg:f.cfg.extend({mode:p,padding:m}),reset:function(){var e;f.reset.call(this);var t=this.cfg,n=t.iv,r=t.mode;this._xformMode==this._ENC_XFORM_MODE?e=r.createEncryptor:(e=r.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==e?this._mode.init(this,n&&n.words):(this._mode=e.call(r,this,n&&n.words),this._mode.__creator=e)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e,t=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(t.pad(this._data,this.blockSize),e=this._process(!0)):(e=this._process(!0),t.unpad(e)),e},blockSize:4}),r.CipherParams=i.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),g=n.format={},b=g.OpenSSL={stringify:function(e){var t,n=e.ciphertext,r=e.salt;return t=r?a.create([1398893684,1701076831]).concat(r).concat(n):n,t.toString(c)},parse:function(e){var t,n=c.parse(e),r=n.words;return 1398893684==r[0]&&1701076831==r[1]&&(t=a.create(r.slice(2,4)),r.splice(0,4),n.sigBytes-=16),y.create({ciphertext:n,salt:t})}},T=r.SerializableCipher=i.extend({cfg:i.extend({format:b}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=e.createEncryptor(n,r),a=i.finalize(t),o=i.cfg;return y.create({ciphertext:a,key:n,iv:o.iv,algorithm:e,mode:o.mode,padding:o.padding,blockSize:e.blockSize,formatter:r.format})},decrypt:function(e,t,n,r){r=this.cfg.extend(r),t=this._parse(t,r.format);var i=e.createDecryptor(n,r).finalize(t.ciphertext);return i},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),S=n.kdf={},E=S.OpenSSL={execute:function(e,t,n,r){r||(r=a.random(8));var i=l.create({keySize:t+n}).compute(e,r),o=a.create(i.words.slice(t),4*n);return i.sigBytes=4*t,y.create({key:i,iv:o,salt:r})}},_=r.PasswordBasedCipher=T.extend({cfg:T.cfg.extend({kdf:E}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=r.kdf.execute(n,e.keySize,e.ivSize);r.iv=i.iv;var a=T.encrypt.call(this,e,t,i.key,r);return a.mixIn(i),a},decrypt:function(e,t,n,r){r=this.cfg.extend(r),t=this._parse(t,r.format);var i=r.kdf.execute(n,e.keySize,e.ivSize,t.salt);r.iv=i.iv;var a=T.decrypt.call(this,e,t,i.key,r);return a}})}()}))},"38cf":function(e,t,n){var r=n("23e7"),i=n("1148");r({target:"String",proto:!0},{repeat:i})},3934:function(e,t,n){"use strict";var r=n("c532");e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=i(window.location.href),function(t){var n=r.isString(t)?i(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return function(){return!0}}()},"39c3":function(e,t,n){"use strict";var r=n("23e7"),i=n("63fa");r({target:"Iterator",proto:!0,real:!0},{toAsync:function(){return new i(this)}})},"3a7b":function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").findIndex,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("findIndex",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},"3a9b":function(e,t,n){var r=n("e330");e.exports=r({}.isPrototypeOf)},"3bbe":function(e,t,n){var r=n("da84"),i=n("1626"),a=r.String,o=r.TypeError;e.exports=function(e){if("object"==typeof e||i(e))return e;throw o("Can't set "+a(e)+" as a prototype")}},"3c5d":function(e,t,n){"use strict";var r=n("da84"),i=n("c65b"),a=n("ebb5"),o=n("07fa"),s=n("182d"),c=n("7b0b"),u=n("d039"),l=r.RangeError,f=r.Int8Array,h=f&&f.prototype,d=h&&h.set,p=a.aTypedArray,v=a.exportTypedArrayMethod,m=!u((function(){var e=new Uint8ClampedArray(2);return i(d,e,{length:1,0:3},1),3!==e[1]})),y=m&&a.NATIVE_ARRAY_BUFFER_VIEWS&&u((function(){var e=new f(2);return e.set(1),e.set("2",1),0!==e[0]||2!==e[1]}));v("set",(function(e){p(this);var t=s(arguments.length>1?arguments[1]:void 0,1),n=c(e);if(m)return i(d,this,n,t);var r=this.length,a=o(n),u=0;if(a+t>r)throw l("Wrong length");while(u<a)this[t+u]=n[u++]}),!m||y)},"3ca3":function(e,t,n){"use strict";var r=n("6547").charAt,i=n("577e"),a=n("69f3"),o=n("7dd0"),s="String Iterator",c=a.set,u=a.getterFor(s);o(String,"String",(function(e){c(this,{type:s,string:i(e),index:0})}),(function(){var e,t=u(this),n=t.string,i=t.index;return i>=n.length?{value:void 0,done:!0}:(e=r(n,i),t.index+=e.length,{value:e,done:!1})}))},"3d5a":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("1132"),n("72fe"),n("2b79"),n("38ba"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.StreamCipher,i=t.algo,a=[],o=[],s=[],c=i.RabbitLegacy=r.extend({_doReset:function(){var e=this._key.words,t=this.cfg.iv,n=this._X=[e[0],e[3]<<16|e[2]>>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],r=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];this._b=0;for(var i=0;i<4;i++)u.call(this);for(i=0;i<8;i++)r[i]^=n[i+4&7];if(t){var a=t.words,o=a[0],s=a[1],c=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;r[0]^=c,r[1]^=f,r[2]^=l,r[3]^=h,r[4]^=c,r[5]^=f,r[6]^=l,r[7]^=h;for(i=0;i<4;i++)u.call(this)}},_doProcessBlock:function(e,t){var n=this._X;u.call(this),a[0]=n[0]^n[5]>>>16^n[3]<<16,a[1]=n[2]^n[7]>>>16^n[5]<<16,a[2]=n[4]^n[1]>>>16^n[7]<<16,a[3]=n[6]^n[3]>>>16^n[1]<<16;for(var r=0;r<4;r++)a[r]=16711935&(a[r]<<8|a[r]>>>24)|4278255360&(a[r]<<24|a[r]>>>8),e[t+r]^=a[r]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,n=0;n<8;n++)o[n]=t[n];t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0<o[0]>>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0<o[1]>>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0<o[2]>>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0<o[3]>>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0<o[4]>>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0<o[5]>>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0<o[6]>>>0?1:0)|0,this._b=t[7]>>>0<o[7]>>>0?1:0;for(n=0;n<8;n++){var r=e[n]+t[n],i=65535&r,a=r>>>16,c=((i*i>>>17)+i*a>>>15)+a*a,u=((4294901760&r)*r|0)+((65535&r)*r|0);s[n]=c^u}e[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,e[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,e[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,e[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,e[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,e[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,e[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,e[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}t.RabbitLegacy=r._createHelper(c)}(),e.RabbitLegacy}))},"3d71":function(e,t,n){"use strict";var r=n("ebb5"),i=n("e330"),a=n("59ed"),o=n("dfb9"),s=r.aTypedArray,c=r.exportTypedArrayMethod,u=r.TYPED_ARRAY_CONSTRUCTOR,l=i(r.TypedArrayPrototype.sort);c("toSorted",(function(e){void 0!==e&&a(e);var t=s(this),n=o(t[u],t);return l(n,e)}))},"3ea3":function(e,t,n){var r=n("23e7"),i=n("f748"),a=Math.abs,o=Math.pow;r({target:"Math",stat:!0},{cbrt:function(e){return i(e=+e)*o(a(e),1/3)}})},"3eb5":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n("10d3"),i=n("10d3"),a=n("1b29"),o=a.byEbmlID,s=function(){function e(){this._schema=o,this._buffers=[],this._stack=[]}return e.prototype.encode=function(e){var t=this;return r.concat(e.reduce((function(e,n){return e.concat(t.encodeChunk(n))}),[])).buffer},e.prototype.encodeChunk=function(e){return"m"===e.type?e.isEnd?this.endTag(e):this.startTag(e):this.writeTag(e),this.flush()},e.prototype.flush=function(){var e=this._buffers;return this._buffers=[],e},e.prototype.getSchemaInfo=function(e){for(var t=Object.keys(this._schema).map(Number),n=0;n<t.length;n++){var r=t[n];if(this._schema[r].name===e)return new i.Buffer(r.toString(16),"hex")}return null},e.prototype.writeTag=function(e){var t=e.name,n=this.getSchemaInfo(t),i=e.data;if(null==n)throw new Error("No schema entry found for "+t);var a=r.encodeTag(n,i);if(this._stack.length>0){var o=this._stack[this._stack.length-1];o.children.push({tagId:n,elm:e,children:[],data:a})}else this._buffers=this._buffers.concat(a)},e.prototype.startTag=function(e){var t=e.name,n=this.getSchemaInfo(t);if(null==n)throw new Error("No schema entry found for "+t);if(e.unknownSize){var a=r.encodeTag(n,new i.Buffer(0),e.unknownSize);this._buffers=this._buffers.concat(a)}else{var o={tagId:n,elm:e,children:[],data:null};this._stack.length>0&&this._stack[this._stack.length-1].children.push(o),this._stack.push(o)}},e.prototype.endTag=function(e){e.name;var t=this._stack.pop();if(null==t)throw new Error("EBML structure is broken");if(t.elm.name!==e.name)throw new Error("EBML structure is broken");var n=t.children.reduce((function(e,t){if(null===t.data)throw new Error("EBML structure is broken");return e.concat(t.data)}),[]),i=r.concat(n);"m"===t.elm.type?t.data=r.encodeTag(t.tagId,i,t.elm.unknownSize):t.data=r.encodeTag(t.tagId,i),this._stack.length<1&&(this._buffers=this._buffers.concat(t.data))},e}();t.default=s},"3f3a":function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("825a"),o=n("a04b"),s=n("9bf2"),c=n("d039"),u=c((function(){Reflect.defineProperty(s.f({},1,{value:1}),1,{value:2})}));r({target:"Reflect",stat:!0,forced:u,sham:!i},{defineProperty:function(e,t,n){a(e);var r=o(t);a(n);try{return s.f(e,r,n),!0}catch(i){return!1}}})},"3f8c":function(e,t){e.exports={}},"3fcc":function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").map,a=n("b6b7"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("map",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0,(function(e,t){return new(a(e))(t)}))}))},"3fde":function(e,t,n){"use strict";var r=n("f36a");e.exports=function(){return new this(r(arguments))}},"3ff8":function(e,t,n){var r=n("23e7"),i=n("a95f");r({target:"Array",stat:!0},{fromAsync:i})},4057:function(e,t,n){var r=n("23e7"),i=Math.hypot,a=Math.abs,o=Math.sqrt,s=!!i&&i(1/0,NaN)!==1/0;r({target:"Math",stat:!0,forced:s},{hypot:function(e,t){var n,r,i=0,s=0,c=arguments.length,u=0;while(s<c)n=a(arguments[s++]),u<n?(r=u/n,i=i*r*r+1,u=n):n>0?(r=n/u,i+=r*r):i+=n;return u===1/0?1/0:u*o(i)}})},4069:function(e,t,n){var r=n("44d2");r("flat")},"408a":function(e,t,n){var r=n("e330");e.exports=r(1..valueOf)},"40d5":function(e,t,n){var r=n("d039");e.exports=!r((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))},"40d9":function(e,t,n){var r=n("23e7"),i=Math.floor,a=Math.log,o=Math.LOG2E;r({target:"Math",stat:!0},{clz32:function(e){return(e>>>=0)?31-i(a(e+.5)*o):32}})},4160:function(e,t,n){"use strict";var r=n("23e7"),i=n("17c2");r({target:"Array",proto:!0,forced:[].forEach!=i},{forEach:i})},"428f":function(e,t,n){var r=n("da84");e.exports=r},4362:function(e,t,n){t.nextTick=function(e){var t=Array.prototype.slice.call(arguments);t.shift(),setTimeout((function(){e.apply(null,t)}),0)},t.platform=t.arch=t.execPath=t.title="browser",t.pid=1,t.browser=!0,t.env={},t.argv=[],t.binding=function(e){throw new Error("No such module. (Possibly not yet loaded)")},function(){var e,r="/";t.cwd=function(){return r},t.chdir=function(t){e||(e=n("df7c")),r=e.resolve(t,r)}}(),t.exit=t.kill=t.umask=t.dlopen=t.uptime=t.memoryUsage=t.uvCounters=function(){},t.features={}},"43b3":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("825a"),o=n("4acb"),s=n("8b85"),c=n("2266");i({target:"Map",proto:!0,real:!0,forced:r},{includes:function(e){return c(o(a(this)),(function(t,n,r){if(s(n,e))return r()}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},4417:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("f8cd"),s=n("c5cc"),c=n("2a62"),u=s((function(e){var t=this.iterator;if(!this.remaining--)return this.done=!0,c(t,"normal",void 0);var n=a(i(this.next,t,e)),r=this.done=!!n.done;return r?void 0:n.value}));r({target:"Iterator",proto:!0,real:!0},{take:function(e){return new u({iterator:a(this),remaining:o(e)})}})},"44ad":function(e,t,n){var r=n("da84"),i=n("e330"),a=n("d039"),o=n("c6b6"),s=r.Object,c=i("".split);e.exports=a((function(){return!s("z").propertyIsEnumerable(0)}))?function(e){return"String"==o(e)?c(e,""):s(e)}:s},"44d2":function(e,t,n){var r=n("b622"),i=n("7c73"),a=n("9bf2"),o=r("unscopables"),s=Array.prototype;void 0==s[o]&&a.f(s,o,{configurable:!0,value:i(null)}),e.exports=function(e){s[o][e]=!0}},"44de":function(e,t,n){var r=n("da84");e.exports=function(e,t){var n=r.console;n&&n.error&&(1==arguments.length?n.error(e):n.error(e,t))}},"44e7":function(e,t,n){var r=n("861d"),i=n("c6b6"),a=n("b622"),o=a("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[o])?!!t:"RegExp"==i(e))}},"45e3":function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b"),a=n("59ed"),o=n("825a"),s=n("d195"),c=n("a1b3"),u=s((function(e){var t,n=this,r=n.mapper;return new e((function(s,u){var l=function(){try{e.resolve(o(i(n.next,n.iterator))).then((function(i){try{o(i).done?(n.done=!0,s({done:!0,value:void 0})):e.resolve(r(i.value)).then((function(e){try{return n.innerIterator=t=c(e),n.innerNext=a(t.next),f()}catch(r){u(r)}}),u)}catch(l){u(l)}}),u)}catch(l){u(l)}},f=function(){if(t=n.innerIterator)try{e.resolve(o(i(n.innerNext,t))).then((function(e){try{o(e).done?(n.innerIterator=n.innerNext=null,l()):s({done:!1,value:e.value})}catch(t){u(t)}}),u)}catch(r){u(r)}else l()};f()}))}));r({target:"AsyncIterator",proto:!0,real:!0},{flatMap:function(e){return new u({iterator:o(this),mapper:a(e),innerIterator:null,innerNext:null})}})},"45fc":function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").some,a=n("a640"),o=a("some");r({target:"Array",proto:!0,forced:!o},{some:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},"466d":function(e,t,n){"use strict";var r=n("c65b"),i=n("d784"),a=n("825a"),o=n("50c4"),s=n("577e"),c=n("1d80"),u=n("dc4a"),l=n("8aa5"),f=n("14c3");i("match",(function(e,t,n){return[function(t){var n=c(this),i=void 0==t?void 0:u(t,e);return i?r(i,t,n):new RegExp(t)[e](s(n))},function(e){var r=a(this),i=s(e),c=n(t,r,i);if(c.done)return c.value;if(!r.global)return f(r,i);var u=r.unicode;r.lastIndex=0;var h,d=[],p=0;while(null!==(h=f(r,i))){var v=s(h[0]);d[p]=v,""===v&&(r.lastIndex=l(i,o(r.lastIndex),u)),p++}return 0===p?null:d}]}))},4673:function(e,t,n){"use strict";var r=n("d066"),i=n("e330"),a=n("59ed"),o=n("07fa"),s=n("7b0b"),c=n("65f0"),u=r("Map"),l=u.prototype,f=i(l.forEach),h=i(l.has),d=i(l.set),p=i([].push);e.exports=function(e){var t,n,r,i=s(this),l=o(i),v=c(i,0),m=new u,y=null!=e?a(e):function(e){return e};for(t=0;t<l;t++)n=i[t],r=y(n),h(m,r)||d(m,r,n);return f(m,(function(e){p(v,e)})),v}},"467f":function(e,t,n){"use strict";var r=n("2d83");e.exports=function(e,t,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?t(r("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}},"477f":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("4acb"),c=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{every:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return!c(n,(function(e,n,i){if(!r(n,e,t))return i()}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},4795:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("2ba4"),o=n("1626"),s=n("342f"),c=n("f36a"),u=/MSIE .\./.test(s),l=i.Function,f=function(e){return function(t,n){var r=arguments.length>2,i=r?c(arguments,2):void 0;return e(r?function(){a(o(t)?t:l(t),this,i)}:t,n)}};r({global:!0,bind:!0,forced:u},{setTimeout:f(i.setTimeout),setInterval:f(i.setInterval)})},4840:function(e,t,n){var r=n("825a"),i=n("5087"),a=n("b622"),o=a("species");e.exports=function(e,t){var n,a=r(e).constructor;return void 0===a||void 0==(n=r(a)[o])?t:i(n)}},"485a":function(e,t,n){var r=n("da84"),i=n("c65b"),a=n("1626"),o=n("861d"),s=r.TypeError;e.exports=function(e,t){var n,r;if("string"===t&&a(n=e.toString)&&!o(r=i(n,e)))return r;if(a(n=e.valueOf)&&!o(r=i(n,e)))return r;if("string"!==t&&a(n=e.toString)&&!o(r=i(n,e)))return r;throw s("Can't convert object to primitive value")}},"48be":function(e,t,n){var r=n("23e7"),i=n("be8c"),a=n("be8e");r({target:"Math",stat:!0},{fscale:function(e,t,n,r,o){return a(i(e,t,n,r,o))}})},4930:function(e,t,n){var r=n("2d00"),i=n("d039");e.exports=!!Object.getOwnPropertySymbols&&!i((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},"498a":function(e,t,n){"use strict";var r=n("23e7"),i=n("58a8").trim,a=n("c8d2");r({target:"String",proto:!0,forced:a("trim")},{trim:function(){return i(this)}})},"4a2e":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("c65b"),s=n("59ed"),c=n("825a"),u=n("4840"),l=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{symmetricDifference:function(e){var t=c(this),n=new(u(t,a("Set")))(t),r=s(n["delete"]),i=s(n.add);return l(e,(function(e){o(r,n,e)||o(i,n,e)})),n}})},"4a7b":function(e,t,n){"use strict";var r=n("c532");e.exports=function(e,t){t=t||{};var n={};function i(e,t){return r.isPlainObject(e)&&r.isPlainObject(t)?r.merge(e,t):r.isPlainObject(t)?r.merge({},t):r.isArray(t)?t.slice():t}function a(n){return r.isUndefined(t[n])?r.isUndefined(e[n])?void 0:i(void 0,e[n]):i(e[n],t[n])}function o(e){if(!r.isUndefined(t[e]))return i(void 0,t[e])}function s(n){return r.isUndefined(t[n])?r.isUndefined(e[n])?void 0:i(void 0,e[n]):i(void 0,t[n])}function c(n){return n in t?i(e[n],t[n]):n in e?i(void 0,e[n]):void 0}var u={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:c};return r.forEach(Object.keys(e).concat(Object.keys(t)),(function(e){var t=u[e]||a,i=t(e);r.isUndefined(i)&&t!==c||(n[e]=i)})),n}},"4a9b":function(e,t,n){var r=n("74e8");r("Float64",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},"4acb":function(e,t,n){var r=n("c65b");e.exports=function(e){return r(Map.prototype.entries,e)}},"4ae1":function(e,t,n){var r=n("23e7"),i=n("d066"),a=n("2ba4"),o=n("0538"),s=n("5087"),c=n("825a"),u=n("861d"),l=n("7c73"),f=n("d039"),h=i("Reflect","construct"),d=Object.prototype,p=[].push,v=f((function(){function e(){}return!(h((function(){}),[],e)instanceof e)})),m=!f((function(){h((function(){}))})),y=v||m;r({target:"Reflect",stat:!0,forced:y,sham:y},{construct:function(e,t){s(e),c(t);var n=arguments.length<3?e:s(arguments[2]);if(m&&!v)return h(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var r=[null];return a(p,r,t),new(a(o,e,r))}var i=n.prototype,f=l(u(i)?i:d),y=a(e,f,t);return u(y)?y:f}})},"4ba9":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.mode.OFB=function(){var t=e.lib.BlockCipherMode.extend(),n=t.Encryptor=t.extend({processBlock:function(e,t){var n=this._cipher,r=n.blockSize,i=this._iv,a=this._keystream;i&&(a=this._keystream=i.slice(0),this._iv=void 0),n.encryptBlock(a,0);for(var o=0;o<r;o++)e[t+o]^=a[o]}});return t.Decryptor=n,t}(),e.mode.OFB}))},"4c53":function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("sub")},{sub:function(){return i(this,"sub","","")}})},"4c9e":function(e,t,n){var r=n("23e7"),i=n("3fde");r({target:"WeakMap",stat:!0},{of:i})},"4d12":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("577e"),o=i("".charAt),s=i("".charCodeAt),c=i(/./.exec),u=i(1..toString),l=i("".toUpperCase),f=/[\w*+\-./@]/,h=function(e,t){var n=u(e,16);while(n.length<t)n="0"+n;return n};r({global:!0},{escape:function(e){var t,n,r=a(e),i="",u=r.length,d=0;while(d<u)t=o(r,d++),c(f,t)?i+=t:(n=s(t,0),i+=n<256?"%"+h(n,2):"%u"+l(h(n,4)));return i}})},"4d63":function(e,t,n){var r=n("83ab"),i=n("da84"),a=n("e330"),o=n("94ca"),s=n("7156"),c=n("9112"),u=n("9bf2").f,l=n("241c").f,f=n("3a9b"),h=n("44e7"),d=n("577e"),p=n("ad6d"),v=n("9f7f"),m=n("6eeb"),y=n("d039"),g=n("1a2d"),b=n("69f3").enforce,T=n("2626"),S=n("b622"),E=n("fce3"),_=n("107c"),k=S("match"),w=i.RegExp,A=w.prototype,R=i.SyntaxError,x=a(p),C=a(A.exec),I=a("".charAt),P=a("".replace),O=a("".indexOf),D=a("".slice),U=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,M=/a/g,B=/a/g,N=new w(M)!==M,L=v.MISSED_STICKY,F=v.UNSUPPORTED_Y,j=r&&(!N||L||E||_||y((function(){return B[k]=!1,w(M)!=M||w(B)==B||"/a/i"!=w(M,"i")}))),W=function(e){for(var t,n=e.length,r=0,i="",a=!1;r<=n;r++)t=I(e,r),"\\"!==t?a||"."!==t?("["===t?a=!0:"]"===t&&(a=!1),i+=t):i+="[\\s\\S]":i+=t+I(e,++r);return i},H=function(e){for(var t,n=e.length,r=0,i="",a=[],o={},s=!1,c=!1,u=0,l="";r<=n;r++){if(t=I(e,r),"\\"===t)t+=I(e,++r);else if("]"===t)s=!1;else if(!s)switch(!0){case"["===t:s=!0;break;case"("===t:C(U,D(e,r+1))&&(r+=2,c=!0),i+=t,u++;continue;case">"===t&&c:if(""===l||g(o,l))throw new R("Invalid capture group name");o[l]=!0,a[a.length]=[l,u],c=!1,l="";continue}c?l+=t:i+=t}return[i,a]};if(o("RegExp",j)){for(var V=function(e,t){var n,r,i,a,o,u,l=f(A,this),p=h(e),v=void 0===t,m=[],y=e;if(!l&&p&&v&&e.constructor===V)return e;if((p||f(A,e))&&(e=e.source,v&&(t="flags"in y?y.flags:x(y))),e=void 0===e?"":d(e),t=void 0===t?"":d(t),y=e,E&&"dotAll"in M&&(r=!!t&&O(t,"s")>-1,r&&(t=P(t,/s/g,""))),n=t,L&&"sticky"in M&&(i=!!t&&O(t,"y")>-1,i&&F&&(t=P(t,/y/g,""))),_&&(a=H(e),e=a[0],m=a[1]),o=s(w(e,t),l?this:A,V),(r||i||m.length)&&(u=b(o),r&&(u.dotAll=!0,u.raw=V(W(e),n)),i&&(u.sticky=!0),m.length&&(u.groups=m)),e!==y)try{c(o,"source",""===y?"(?:)":y)}catch(g){}return o},q=function(e){e in V||u(V,e,{configurable:!0,get:function(){return w[e]},set:function(t){w[e]=t}})},z=l(w),G=0;z.length>G;)q(z[G++]);A.constructor=V,V.prototype=A,m(i,"RegExp",V)}T("RegExp")},"4d64":function(e,t,n){var r=n("fc6a"),i=n("23cb"),a=n("07fa"),o=function(e){return function(t,n,o){var s,c=r(t),u=a(c),l=i(o,u);if(e&&n!=n){while(u>l)if(s=c[l++],s!=s)return!0}else for(;u>l;l++)if((e||l in c)&&c[l]===n)return e||l||0;return!e&&-1}};e.exports={includes:o(!0),indexOf:o(!1)}},"4d90":function(e,t,n){"use strict";var r=n("23e7"),i=n("0ccb").start,a=n("9a0c");r({target:"String",proto:!0,forced:a},{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},"4dae":function(e,t,n){var r=n("da84"),i=n("23cb"),a=n("07fa"),o=n("8418"),s=r.Array,c=Math.max;e.exports=function(e,t,n){for(var r=a(e),u=i(t,r),l=i(void 0===n?r:n,r),f=s(c(l-u,0)),h=0;u<l;u++,h++)o(f,h,e[u]);return f.length=h,f}},"4de4":function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").filter,a=n("1dde"),o=a("filter");r({target:"Array",proto:!0,forced:!o},{filter:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},"4df4":function(e,t,n){"use strict";var r=n("da84"),i=n("0366"),a=n("c65b"),o=n("7b0b"),s=n("9bdd"),c=n("e95a"),u=n("68ee"),l=n("07fa"),f=n("8418"),h=n("9a1f"),d=n("35a1"),p=r.Array;e.exports=function(e){var t=o(e),n=u(this),r=arguments.length,v=r>1?arguments[1]:void 0,m=void 0!==v;m&&(v=i(v,r>2?arguments[2]:void 0));var y,g,b,T,S,E,_=d(t),k=0;if(!_||this==p&&c(_))for(y=l(t),g=n?new this(y):p(y);y>k;k++)E=m?v(t[k],k):t[k],f(g,k,E);else for(T=h(t,_),S=T.next,g=n?new this:[];!(b=a(S,T)).done;k++)E=m?s(T,v,[b.value,k],!0):b.value,f(g,k,E);return g.length=k,g}},"4e16":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("4acb"),c=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{some:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return c(n,(function(e,n,i){if(r(n,e,t))return i()}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},"4e3e":function(e,t,n){"use strict";var r=n("23e7"),i=n("2266"),a=n("825a");r({target:"Iterator",proto:!0,real:!0},{forEach:function(e){i(a(this),e,{IS_ITERATOR:!0})}})},"4e82":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("59ed"),o=n("7b0b"),s=n("07fa"),c=n("577e"),u=n("d039"),l=n("addb"),f=n("a640"),h=n("04d1"),d=n("d998"),p=n("2d00"),v=n("512c"),m=[],y=i(m.sort),g=i(m.push),b=u((function(){m.sort(void 0)})),T=u((function(){m.sort(null)})),S=f("sort"),E=!u((function(){if(p)return p<70;if(!(h&&h>3)){if(d)return!0;if(v)return v<603;var e,t,n,r,i="";for(e=65;e<76;e++){switch(t=String.fromCharCode(e),e){case 66:case 69:case 70:case 72:n=3;break;case 68:case 71:n=4;break;default:n=2}for(r=0;r<47;r++)m.push({k:t+r,v:n})}for(m.sort((function(e,t){return t.v-e.v})),r=0;r<m.length;r++)t=m[r].k.charAt(0),i.charAt(i.length-1)!==t&&(i+=t);return"DGBEFHACIJK"!==i}})),_=b||!T||!S||!E,k=function(e){return function(t,n){return void 0===n?-1:void 0===t?1:void 0!==e?+e(t,n)||0:c(t)>c(n)?1:-1}};r({target:"Array",proto:!0,forced:_},{sort:function(e){void 0!==e&&a(e);var t=o(this);if(E)return void 0===e?y(t):y(t,e);var n,r,i=[],c=s(t);for(r=0;r<c;r++)r in t&&g(i,t[r]);l(i,k(e)),n=i.length,r=0;while(r<n)t[r]=i[r++];while(r<c)delete t[r++];return t}})},"4ec9":function(e,t,n){"use strict";var r=n("6d61"),i=n("6566");r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},"4fad":function(e,t,n){var r=n("d039"),i=n("861d"),a=n("c6b6"),o=n("d86b"),s=Object.isExtensible,c=r((function(){s(1)}));e.exports=c||o?function(e){return!!i(e)&&((!o||"ArrayBuffer"!=a(e))&&(!s||s(e)))}:s},"4fadc":function(e,t,n){var r=n("23e7"),i=n("6f53").entries;r({target:"Object",stat:!0},{entries:function(e){return i(e)}})},5087:function(e,t,n){var r=n("da84"),i=n("68ee"),a=n("0d51"),o=r.TypeError;e.exports=function(e){if(i(e))return e;throw o(a(e)+" is not a constructor")}},"50c4":function(e,t,n){var r=n("5926"),i=Math.min;e.exports=function(e){return e>0?i(r(e),9007199254740991):0}},"512a":function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(t,"__esModule",{value:!0});var i=n("faa1"),a=n("10d3"),o=function(e){function t(){var t=e.call(this)||this;return t.logGroup="",t.hasLoggingStarted=!1,t.metadataloaded=!1,t.chunks=[],t.stack=[],t.segmentOffset=0,t.last2SimpleBlockVideoTrackTimecode=[0,0],t.last2SimpleBlockAudioTrackTimecode=[0,0],t.lastClusterTimecode=0,t.lastClusterPosition=0,t.timecodeScale=1e6,t.metadataSize=0,t.metadatas=[],t.cues=[],t.firstVideoBlockRead=!1,t.firstAudioBlockRead=!1,t.currentTrack={TrackNumber:-1,TrackType:-1,DefaultDuration:null,CodecDelay:null},t.trackTypes=[],t.trackDefaultDuration=[],t.trackCodecDelay=[],t.trackInfo={type:"nothing"},t.ended=!1,t.logging=!1,t.use_duration_every_simpleblock=!1,t.use_webp=!1,t.use_segment_info=!0,t.drop_default_duration=!0,t}return r(t,e),t.prototype.stop=function(){this.ended=!0,this.emit_segment_info();while(this.stack.length)this.stack.pop(),this.logging&&console.groupEnd();this.logging&&this.hasLoggingStarted&&this.logGroup&&console.groupEnd()},t.prototype.emit_segment_info=function(){var e=this.chunks;if(this.chunks=[],this.metadataloaded){if(!this.use_segment_info)return;var t=this.lastClusterTimecode,n=this.duration,r=this.timecodeScale;this.emit("cluster",{timecode:t,data:e}),this.emit("duration",{timecodeScale:r,duration:n})}else{this.metadataloaded=!0,this.metadatas=e;var i=this.trackTypes.indexOf(1),a=this.trackTypes.indexOf(2);if(this.trackInfo=i>=0&&a>=0?{type:"both",trackNumber:i}:i>=0?{type:"video",trackNumber:i}:a>=0?{type:"audio",trackNumber:a}:{type:"nothing"},!this.use_segment_info)return;this.emit("metadata",{data:e,metadataSize:this.metadataSize})}},t.prototype.read=function(e){var t=this,n=!1;if(!this.ended){if("m"===e.type)if(e.isEnd)this.stack.pop();else{var r=this.stack[this.stack.length-1];if(null!=r&&r.level>=e.level){this.stack.pop(),this.logging&&console.groupEnd(),r.dataEnd=e.dataEnd,r.dataSize=e.dataEnd-r.dataStart,r.unknownSize=!1;var i=Object.assign({},r,{name:r.name,type:r.type,isEnd:!0});this.chunks.push(i)}this.stack.push(e)}if("m"===e.type&&"Segment"==e.name)0!=this.segmentOffset&&console.warn("Multiple segments detected!"),this.segmentOffset=e.dataStart,this.emit("segment_offset",this.segmentOffset);else if("b"===e.type&&"SimpleBlock"===e.name){var o=a.ebmlBlock(e.data),s=o.timecode,c=o.trackNumber,u=o.frames;if(1===this.trackTypes[c]){if(!this.firstVideoBlockRead&&(this.firstVideoBlockRead=!0,"both"===this.trackInfo.type||"video"===this.trackInfo.type)){var l=this.lastClusterTimecode+s;this.cues.push({CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:l}),this.emit("cue_info",{CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:this.lastClusterTimecode}),this.emit("cue",{CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:l})}this.last2SimpleBlockVideoTrackTimecode=[this.last2SimpleBlockVideoTrackTimecode[1],s]}else if(2===this.trackTypes[c]){if(!this.firstAudioBlockRead&&(this.firstAudioBlockRead=!0,"audio"===this.trackInfo.type)){l=this.lastClusterTimecode+s;this.cues.push({CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:l}),this.emit("cue_info",{CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:this.lastClusterTimecode}),this.emit("cue",{CueTrack:c,CueClusterPosition:this.lastClusterPosition,CueTime:l})}this.last2SimpleBlockAudioTrackTimecode=[this.last2SimpleBlockAudioTrackTimecode[1],s]}this.use_duration_every_simpleblock&&this.emit("duration",{timecodeScale:this.timecodeScale,duration:this.duration}),this.use_webp&&u.forEach((function(e){var n=e.slice(3,6).toString("hex");if("9d012a"===n){var r=a.VP8BitStreamToRiffWebPBuffer(e),i=new Blob([r],{type:"image/webp"}),o=t.duration;t.emit("webp",{currentTime:o,webp:i})}}))}else"m"===e.type&&"Cluster"===e.name&&!1===e.isEnd?(this.firstVideoBlockRead=!1,this.firstAudioBlockRead=!1,this.emit_segment_info(),this.emit("cluster_ptr",e.tagStart),this.lastClusterPosition=e.tagStart):"u"===e.type&&"Timecode"===e.name?this.lastClusterTimecode=e.value:"u"===e.type&&"TimecodeScale"===e.name?this.timecodeScale=e.value:"m"===e.type&&"TrackEntry"===e.name?e.isEnd?(this.trackTypes[this.currentTrack.TrackNumber]=this.currentTrack.TrackType,this.trackDefaultDuration[this.currentTrack.TrackNumber]=this.currentTrack.DefaultDuration,this.trackCodecDelay[this.currentTrack.TrackNumber]=this.currentTrack.CodecDelay):this.currentTrack={TrackNumber:-1,TrackType:-1,DefaultDuration:null,CodecDelay:null}:"u"===e.type&&"TrackType"===e.name?this.currentTrack.TrackType=e.value:"u"===e.type&&"TrackNumber"===e.name?this.currentTrack.TrackNumber=e.value:"u"===e.type&&"CodecDelay"===e.name?this.currentTrack.CodecDelay=e.value:"u"===e.type&&"DefaultDuration"===e.name?this.drop_default_duration?(console.warn("DefaultDuration detected!, remove it"),n=!0):this.currentTrack.DefaultDuration=e.value:"unknown"===e.name&&console.warn(e);!this.metadataloaded&&e.dataEnd>0&&(this.metadataSize=e.dataEnd),n||this.chunks.push(e),this.logging&&this.put(e)}},Object.defineProperty(t.prototype,"duration",{get:function(){if("nothing"===this.trackInfo.type)return console.warn("no video, no audio track"),0;var e=0,t=0,n=0,r=this.trackDefaultDuration[this.trackInfo.trackNumber];if("number"===typeof r)e=r;else if("both"===this.trackInfo.type)if(this.last2SimpleBlockAudioTrackTimecode[1]>this.last2SimpleBlockVideoTrackTimecode[1]){e=(this.last2SimpleBlockAudioTrackTimecode[1]-this.last2SimpleBlockAudioTrackTimecode[0])*this.timecodeScale;var i=this.trackCodecDelay[this.trackTypes.indexOf(2)];"number"===typeof i&&(t=i),n=this.last2SimpleBlockAudioTrackTimecode[1]}else{e=(this.last2SimpleBlockVideoTrackTimecode[1]-this.last2SimpleBlockVideoTrackTimecode[0])*this.timecodeScale;i=this.trackCodecDelay[this.trackTypes.indexOf(1)];"number"===typeof i&&(t=i),n=this.last2SimpleBlockVideoTrackTimecode[1]}else if("video"===this.trackInfo.type){e=(this.last2SimpleBlockVideoTrackTimecode[1]-this.last2SimpleBlockVideoTrackTimecode[0])*this.timecodeScale;i=this.trackCodecDelay[this.trackInfo.trackNumber];"number"===typeof i&&(t=i),n=this.last2SimpleBlockVideoTrackTimecode[1]}else if("audio"===this.trackInfo.type){e=(this.last2SimpleBlockAudioTrackTimecode[1]-this.last2SimpleBlockAudioTrackTimecode[0])*this.timecodeScale;i=this.trackCodecDelay[this.trackInfo.trackNumber];"number"===typeof i&&(t=i),n=this.last2SimpleBlockAudioTrackTimecode[1]}var a=(this.lastClusterTimecode+n)*this.timecodeScale+e-t,o=a/this.timecodeScale;return Math.floor(o)},enumerable:!0,configurable:!0}),t.prototype.addListener=function(t,n){return e.prototype.addListener.call(this,t,n)},t.prototype.put=function(e){this.hasLoggingStarted||(this.hasLoggingStarted=!0,this.logging&&this.logGroup&&console.groupCollapsed(this.logGroup)),"m"===e.type?e.isEnd?console.groupEnd():console.group(e.name+":"+e.tagStart):"b"===e.type?console.log(e.name,e.type):console.log(e.name,e.tagStart,e.type,e.value)},t}(i.EventEmitter);t.default=o},"512c":function(e,t,n){var r=n("342f"),i=r.match(/AppleWebKit\/(\d+)\./);e.exports=!!i&&+i[1]},"51cf":function(e,t,n){var r=n("da84");e.exports=function(e){return r[e].prototype}},"51eb":function(e,t,n){"use strict";var r=n("da84"),i=n("825a"),a=n("485a"),o=r.TypeError;e.exports=function(e){if(i(this),"string"===e||"default"===e)e="string";else if("number"!==e)throw o("Incorrect hint");return a(this,e)}},5270:function(e,t,n){"use strict";var r=n("c532"),i=n("c401"),a=n("2e67"),o=n("2444"),s=n("7a77");function c(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new s("canceled")}e.exports=function(e){c(e),e.headers=e.headers||{},e.data=i.call(e,e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]}));var t=e.adapter||o.adapter;return t(e).then((function(t){return c(e),t.data=i.call(e,t.data,t.headers,e.transformResponse),t}),(function(t){return a(t)||(c(e),t&&t.response&&(t.response.data=i.call(e,t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},5319:function(e,t,n){"use strict";var r=n("2ba4"),i=n("c65b"),a=n("e330"),o=n("d784"),s=n("d039"),c=n("825a"),u=n("1626"),l=n("5926"),f=n("50c4"),h=n("577e"),d=n("1d80"),p=n("8aa5"),v=n("dc4a"),m=n("0cb2"),y=n("14c3"),g=n("b622"),b=g("replace"),T=Math.max,S=Math.min,E=a([].concat),_=a([].push),k=a("".indexOf),w=a("".slice),A=function(e){return void 0===e?e:String(e)},R=function(){return"$0"==="a".replace(/./,"$0")}(),x=function(){return!!/./[b]&&""===/./[b]("a","$0")}(),C=!s((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}));o("replace",(function(e,t,n){var a=x?"$":"$0";return[function(e,n){var r=d(this),a=void 0==e?void 0:v(e,b);return a?i(a,e,r,n):i(t,h(r),e,n)},function(e,i){var o=c(this),s=h(e);if("string"==typeof i&&-1===k(i,a)&&-1===k(i,"$<")){var d=n(t,o,s,i);if(d.done)return d.value}var v=u(i);v||(i=h(i));var g=o.global;if(g){var b=o.unicode;o.lastIndex=0}var R=[];while(1){var x=y(o,s);if(null===x)break;if(_(R,x),!g)break;var C=h(x[0]);""===C&&(o.lastIndex=p(s,f(o.lastIndex),b))}for(var I="",P=0,O=0;O<R.length;O++){x=R[O];for(var D=h(x[0]),U=T(S(l(x.index),s.length),0),M=[],B=1;B<x.length;B++)_(M,A(x[B]));var N=x.groups;if(v){var L=E([D],M,U,s);void 0!==N&&_(L,N);var F=h(r(i,void 0,L))}else F=m(D,s,U,M,N,i);U>=P&&(I+=w(s,P,U)+F,P=U+D.length)}return I+w(s,P)}]}),!C||!R||x)},5327:function(e,t,n){var r=n("23e7"),i=n("1ec1"),a=Math.acosh,o=Math.log,s=Math.sqrt,c=Math.LN2,u=!a||710!=Math.floor(a(Number.MAX_VALUE))||a(1/0)!=1/0;r({target:"Math",stat:!0,forced:u},{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?o(e)+c:i(e-1+s(e-1)*s(e+1))}})},5333:function(e,t,n){"use strict";var r=n("23e7"),i=n("9ed3"),a=n("1d80"),o=n("577e"),s=n("69f3"),c=n("6547"),u=c.codeAt,l=c.charAt,f="String Iterator",h=s.set,d=s.getterFor(f),p=i((function(e){h(this,{type:f,string:e,index:0})}),"String",(function(){var e,t=d(this),n=t.string,r=t.index;return r>=n.length?{value:void 0,done:!0}:(e=l(n,r),t.index+=e.length,{value:{codePoint:u(e,0),position:r},done:!1})}));r({target:"String",proto:!0},{codePoints:function(){return new p(o(a(this)))}})},5377:function(e,t,n){var r=n("83ab"),i=n("9bf2"),a=n("ad6d"),o=n("d039"),s=RegExp.prototype,c=r&&o((function(){return"sy"!==Object.getOwnPropertyDescriptor(s,"flags").get.call({dotAll:!0,sticky:!0})}));c&&i.f(s,"flags",{configurable:!0,get:a})},"542d":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("d039"),o=n("408a"),s=i(1..toPrecision),c=a((function(){return"1"!==s(1,void 0)}))||!a((function(){s({})}));r({target:"Number",proto:!0,forced:c},{toPrecision:function(e){return void 0===e?s(o(this)):s(o(this),e)}})},"54c8":function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").filterReject,a=n("44d2");r({target:"Array",proto:!0},{filterOut:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a("filterOut")},"54ec":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c430"),o=n("825a"),s=n("59ed"),c=n("4acb"),u=n("2266"),l=i.TypeError;r({target:"Map",proto:!0,real:!0,forced:a},{reduce:function(e){var t=o(this),n=c(t),r=arguments.length<2,i=r?void 0:arguments[1];if(s(e),u(n,(function(n,a){r?(r=!1,i=a):i=e(i,a,n,t)}),{AS_ENTRIES:!0,IS_ITERATOR:!0}),r)throw l("Reduce of empty map with no initial value");return i}})},5585:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n("e1db");t.Decoder=r.default;var i=n("3eb5");t.Encoder=i.default;var a=n("512a");t.Reader=a.default;var o=n("10d3");t.tools=o;var s=n("67c0").version;t.version=s},"567a":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("4acb"),s=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{keyOf:function(e){return s(o(a(this)),(function(t,n,r){if(n===e)return r(t)}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).result}})},5692:function(e,t,n){var r=n("c430"),i=n("c6cd");(e.exports=function(e,t){return i[e]||(i[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.20.3",mode:r?"pure":"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.20.3/LICENSE",source:"https://github.com/zloirock/core-js"})},"56ef":function(e,t,n){var r=n("d066"),i=n("e330"),a=n("241c"),o=n("7418"),s=n("825a"),c=i([].concat);e.exports=r("Reflect","ownKeys")||function(e){var t=a.f(s(e)),n=o.f;return n?c(t,n(e)):t}},"577e":function(e,t,n){var r=n("da84"),i=n("f5df"),a=r.String;e.exports=function(e){if("Symbol"===i(e))throw TypeError("Cannot convert a Symbol value to a string");return a(e)}},"583b":function(e,t,n){var r=n("23e7"),i=n("eac5"),a=Math.abs;r({target:"Number",stat:!0},{isSafeInteger:function(e){return i(e)&&a(e)<=9007199254740991}})},5860:function(e,t,n){var r=n("c65b");e.exports=function(e){return r(Set.prototype.values,e)}},5899:function(e,t){e.exports="\t\n\v\f\r \u2028\u2029\ufeff"},"58a8":function(e,t,n){var r=n("e330"),i=n("1d80"),a=n("577e"),o=n("5899"),s=r("".replace),c="["+o+"]",u=RegExp("^"+c+c+"*"),l=RegExp(c+c+"*$"),f=function(e){return function(t){var n=a(i(t));return 1&e&&(n=s(n,u,"")),2&e&&(n=s(n,l,"")),n}};e.exports={start:f(1),end:f(2),trim:f(3)}},"58fc":function(e,t,n){var r=n("23e7"),i=n("be8c");r({target:"Math",stat:!0},{scale:i})},5926:function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){var t=+e;return t!==t||0===t?0:(t>0?r:n)(t)}},5980:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){(function(){var t=e,n=t.lib,r=n.Base,i=t.enc,a=i.Utf8,o=t.algo;o.HMAC=r.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=a.parse(t));var n=e.blockSize,r=4*n;t.sigBytes>r&&(t=e.finalize(t)),t.clamp();for(var i=this._oKey=t.clone(),o=this._iKey=t.clone(),s=i.words,c=o.words,u=0;u<n;u++)s[u]^=1549556828,c[u]^=909522486;i.sigBytes=o.sigBytes=r,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,n=t.finalize(e);t.reset();var r=t.finalize(this._oKey.clone().concat(n));return r}})})()}))},"59ed":function(e,t,n){var r=n("da84"),i=n("1626"),a=n("0d51"),o=r.TypeError;e.exports=function(e){if(i(e))return e;throw o(a(e)+" is not a function")}},"5a34":function(e,t,n){var r=n("da84"),i=n("44e7"),a=r.TypeError;e.exports=function(e){if(i(e))throw a("The method doesn't accept regular expressions");return e}},"5b81":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("e330"),s=n("1d80"),c=n("1626"),u=n("44e7"),l=n("577e"),f=n("dc4a"),h=n("ad6d"),d=n("0cb2"),p=n("b622"),v=n("c430"),m=p("replace"),y=RegExp.prototype,g=i.TypeError,b=o(h),T=o("".indexOf),S=o("".replace),E=o("".slice),_=Math.max,k=function(e,t,n){return n>e.length?-1:""===t?n:T(e,t,n)};r({target:"String",proto:!0},{replaceAll:function(e,t){var n,r,i,o,h,p,w,A,R,x=s(this),C=0,I=0,P="";if(null!=e){if(n=u(e),n&&(r=l(s("flags"in y?e.flags:b(e))),!~T(r,"g")))throw g("`.replaceAll` does not allow non-global regexes");if(i=f(e,m),i)return a(i,e,x,t);if(v&&n)return S(l(x),e,t)}o=l(x),h=l(e),p=c(t),p||(t=l(t)),w=h.length,A=_(1,w),C=k(o,h,0);while(-1!==C)R=p?l(t(h,C,o)):d(h,o,C,[],void 0,t),P+=E(o,I,C)+R,I=C+w,C=k(o,h,C+A);return I<o.length&&(P+=E(o,I)),P}})},"5bf7":function(e,t,n){"use strict";var r=n("23e7"),i=n("83ab"),a=n("eb1d"),o=n("7b0b"),s=n("a04b"),c=n("e163"),u=n("06cf").f;i&&r({target:"Object",proto:!0,forced:a},{__lookupSetter__:function(e){var t,n=o(this),r=s(e);do{if(t=u(n,r))return t.set}while(n=c(n))}})},"5c6c":function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},"5cc6":function(e,t,n){var r=n("74e8");r("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},"5cce":function(e,t){e.exports={version:"0.24.0"}},"5d41":function(e,t,n){var r=n("23e7"),i=n("c65b"),a=n("861d"),o=n("825a"),s=n("c60d"),c=n("06cf"),u=n("e163");function l(e,t){var n,r,f=arguments.length<3?e:arguments[2];return o(e)===f?e[t]:(n=c.f(e,t),n?s(n)?n.value:void 0===n.get?void 0:i(n.get,f):a(r=u(e))?l(r,t,f):void 0)}r({target:"Reflect",stat:!0},{get:l})},"5db7":function(e,t,n){"use strict";var r=n("23e7"),i=n("a2bf"),a=n("59ed"),o=n("7b0b"),s=n("07fa"),c=n("65f0");r({target:"Array",proto:!0},{flatMap:function(e){var t,n=o(this),r=s(n);return a(e),t=c(n,0),t.length=i(t,n,n,r,0,1,e,arguments.length>1?arguments[1]:void 0),t}})},"5ded":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("d039"),o=n("68ee"),s=n("8418"),c=i.Array,u=a((function(){function e(){}return!(c.of.call(e)instanceof e)}));r({target:"Array",stat:!0,forced:u},{of:function(){var e=0,t=arguments.length,n=new(o(this)?this:c)(t);while(t>e)s(n,e,arguments[e++]);return n.length=t,n}})},"5dfc":function(e,t,n){"use strict";var r=n("ebb5"),i=n("f36a"),a=n("ad02"),o=r.aTypedArray,s=r.exportTypedArrayMethod,c=r.TYPED_ARRAY_CONSTRUCTOR;s("toSpliced",(function(e,t){return a(o(this),this[c],i(arguments))}))},"5e77":function(e,t,n){var r=n("83ab"),i=n("1a2d"),a=Function.prototype,o=r&&Object.getOwnPropertyDescriptor,s=i(a,"name"),c=s&&"something"===function(){}.name,u=s&&(!r||r&&o(a,"name").configurable);e.exports={EXISTS:s,PROPER:c,CONFIGURABLE:u}},"5f02":function(e,t,n){"use strict";e.exports=function(e){return"object"===typeof e&&!0===e.isAxiosError}},"5f96":function(e,t,n){"use strict";var r=n("ebb5"),i=n("e330"),a=r.aTypedArray,o=r.exportTypedArrayMethod,s=i([].join);o("join",(function(e){return s(a(this),e)}))},"5fb2":function(e,t,n){"use strict";var r=n("da84"),i=n("e330"),a=2147483647,o=36,s=1,c=26,u=38,l=700,f=72,h=128,d="-",p=/[^\0-\u007E]/,v=/[.\u3002\uFF0E\uFF61]/g,m="Overflow: input needs wider integers to process",y=o-s,g=r.RangeError,b=i(v.exec),T=Math.floor,S=String.fromCharCode,E=i("".charCodeAt),_=i([].join),k=i([].push),w=i("".replace),A=i("".split),R=i("".toLowerCase),x=function(e){var t=[],n=0,r=e.length;while(n<r){var i=E(e,n++);if(i>=55296&&i<=56319&&n<r){var a=E(e,n++);56320==(64512&a)?k(t,((1023&i)<<10)+(1023&a)+65536):(k(t,i),n--)}else k(t,i)}return t},C=function(e){return e+22+75*(e<26)},I=function(e,t,n){var r=0;e=n?T(e/l):e>>1,e+=T(e/t);while(e>y*c>>1)e=T(e/y),r+=o;return T(r+(y+1)*e/(e+u))},P=function(e){var t=[];e=x(e);var n,r,i=e.length,u=h,l=0,p=f;for(n=0;n<e.length;n++)r=e[n],r<128&&k(t,S(r));var v=t.length,y=v;v&&k(t,d);while(y<i){var b=a;for(n=0;n<e.length;n++)r=e[n],r>=u&&r<b&&(b=r);var E=y+1;if(b-u>T((a-l)/E))throw g(m);for(l+=(b-u)*E,u=b,n=0;n<e.length;n++){if(r=e[n],r<u&&++l>a)throw g(m);if(r==u){var w=l,A=o;while(1){var R=A<=p?s:A>=p+c?c:A-p;if(w<R)break;var P=w-R,O=o-R;k(t,S(C(R+P%O))),w=T(P/O),A+=o}k(t,S(C(w))),p=I(l,E,y==v),l=0,y++}}l++,u++}return _(t,"")};e.exports=function(e){var t,n,r=[],i=A(w(R(e),v,"."),".");for(t=0;t<i.length;t++)n=i[t],k(r,b(p,n)?"xn--"+P(n):n);return _(r,".")}},"605d":function(e,t,n){var r=n("c6b6"),i=n("da84");e.exports="process"==r(i.process)},6062:function(e,t,n){"use strict";var r=n("6d61"),i=n("6566");r("Set",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},6069:function(e,t){e.exports="object"==typeof window},"60bd":function(e,t,n){"use strict";var r=n("da84"),i=n("d039"),a=n("e330"),o=n("ebb5"),s=n("e260"),c=n("b622"),u=c("iterator"),l=r.Uint8Array,f=a(s.values),h=a(s.keys),d=a(s.entries),p=o.aTypedArray,v=o.exportTypedArrayMethod,m=l&&l.prototype,y=!i((function(){m[u].call([1])})),g=!!m&&m.values&&m[u]===m.values&&"values"===m.values.name,b=function(){return f(p(this))};v("entries",(function(){return d(p(this))}),y),v("keys",(function(){return h(p(this))}),y),v("values",b,y||!g,{name:"values"}),v(u,b,y||!g,{name:"values"})},"60da":function(e,t,n){"use strict";var r=n("83ab"),i=n("e330"),a=n("c65b"),o=n("d039"),s=n("df75"),c=n("7418"),u=n("d1e7"),l=n("7b0b"),f=n("44ad"),h=Object.assign,d=Object.defineProperty,p=i([].concat);e.exports=!h||o((function(){if(r&&1!==h({b:1},h(d({},"a",{enumerable:!0,get:function(){d(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},n=Symbol(),i="abcdefghijklmnopqrst";return e[n]=7,i.split("").forEach((function(e){t[e]=e})),7!=h({},e)[n]||s(h({},t)).join("")!=i}))?function(e,t){var n=l(e),i=arguments.length,o=1,h=c.f,d=u.f;while(i>o){var v,m=f(arguments[o++]),y=h?p(s(m),h(m)):s(m),g=y.length,b=0;while(g>b)v=y[b++],r&&!a(d,m,v)||(n[v]=m[v])}return n}:h},"621a":function(e,t,n){"use strict";var r=n("da84"),i=n("e330"),a=n("83ab"),o=n("a981"),s=n("5e77"),c=n("9112"),u=n("e2cc"),l=n("d039"),f=n("19aa"),h=n("5926"),d=n("50c4"),p=n("0b25"),v=n("77a7"),m=n("e163"),y=n("d2bb"),g=n("241c").f,b=n("9bf2").f,T=n("81d5"),S=n("4dae"),E=n("d44e"),_=n("69f3"),k=s.PROPER,w=s.CONFIGURABLE,A=_.get,R=_.set,x="ArrayBuffer",C="DataView",I="prototype",P="Wrong length",O="Wrong index",D=r[x],U=D,M=U&&U[I],B=r[C],N=B&&B[I],L=Object.prototype,F=r.Array,j=r.RangeError,W=i(T),H=i([].reverse),V=v.pack,q=v.unpack,z=function(e){return[255&e]},G=function(e){return[255&e,e>>8&255]},Y=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},K=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},X=function(e){return V(e,23,4)},Q=function(e){return V(e,52,8)},$=function(e,t){b(e[I],t,{get:function(){return A(this)[t]}})},Z=function(e,t,n,r){var i=p(n),a=A(e);if(i+t>a.byteLength)throw j(O);var o=A(a.buffer).bytes,s=i+a.byteOffset,c=S(o,s,s+t);return r?c:H(c)},J=function(e,t,n,r,i,a){var o=p(n),s=A(e);if(o+t>s.byteLength)throw j(O);for(var c=A(s.buffer).bytes,u=o+s.byteOffset,l=r(+i),f=0;f<t;f++)c[u+f]=l[a?f:t-f-1]};if(o){var ee=k&&D.name!==x;if(l((function(){D(1)}))&&l((function(){new D(-1)}))&&!l((function(){return new D,new D(1.5),new D(NaN),ee&&!w})))ee&&w&&c(D,"name",x);else{U=function(e){return f(this,M),new D(p(e))},U[I]=M;for(var te,ne=g(D),re=0;ne.length>re;)(te=ne[re++])in U||c(U,te,D[te]);M.constructor=U}y&&m(N)!==L&&y(N,L);var ie=new B(new U(2)),ae=i(N.setInt8);ie.setInt8(0,2147483648),ie.setInt8(1,2147483649),!ie.getInt8(0)&&ie.getInt8(1)||u(N,{setInt8:function(e,t){ae(this,e,t<<24>>24)},setUint8:function(e,t){ae(this,e,t<<24>>24)}},{unsafe:!0})}else U=function(e){f(this,M);var t=p(e);R(this,{bytes:W(F(t),0),byteLength:t}),a||(this.byteLength=t)},M=U[I],B=function(e,t,n){f(this,N),f(e,M);var r=A(e).byteLength,i=h(t);if(i<0||i>r)throw j("Wrong offset");if(n=void 0===n?r-i:d(n),i+n>r)throw j(P);R(this,{buffer:e,byteLength:n,byteOffset:i}),a||(this.buffer=e,this.byteLength=n,this.byteOffset=i)},N=B[I],a&&($(U,"byteLength"),$(B,"buffer"),$(B,"byteLength"),$(B,"byteOffset")),u(N,{getInt8:function(e){return Z(this,1,e)[0]<<24>>24},getUint8:function(e){return Z(this,1,e)[0]},getInt16:function(e){var t=Z(this,2,e,arguments.length>1?arguments[1]:void 0);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=Z(this,2,e,arguments.length>1?arguments[1]:void 0);return t[1]<<8|t[0]},getInt32:function(e){return K(Z(this,4,e,arguments.length>1?arguments[1]:void 0))},getUint32:function(e){return K(Z(this,4,e,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(e){return q(Z(this,4,e,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(e){return q(Z(this,8,e,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(e,t){J(this,1,e,z,t)},setUint8:function(e,t){J(this,1,e,z,t)},setInt16:function(e,t){J(this,2,e,G,t,arguments.length>2?arguments[2]:void 0)},setUint16:function(e,t){J(this,2,e,G,t,arguments.length>2?arguments[2]:void 0)},setInt32:function(e,t){J(this,4,e,Y,t,arguments.length>2?arguments[2]:void 0)},setUint32:function(e,t){J(this,4,e,Y,t,arguments.length>2?arguments[2]:void 0)},setFloat32:function(e,t){J(this,4,e,X,t,arguments.length>2?arguments[2]:void 0)},setFloat64:function(e,t){J(this,8,e,Q,t,arguments.length>2?arguments[2]:void 0)}});E(U,x),E(B,C),e.exports={ArrayBuffer:U,DataView:B}},6380:function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.toKey,s=i.getMap,c=i.store;r({target:"Reflect",stat:!0},{deleteMetadata:function(e,t){var n=arguments.length<3?void 0:o(arguments[2]),r=s(a(t),n,!1);if(void 0===r||!r["delete"](e))return!1;if(r.size)return!0;var i=c.get(t);return i["delete"](n),!!i.size||c["delete"](t)}})},"63fa":function(e,t,n){"use strict";var r=n("2ba4"),i=n("825a"),a=n("7c73"),o=n("dc4a"),s=n("e2cc"),c=n("69f3"),u=n("d066"),l=n("a91f"),f=u("Promise"),h="AsyncFromSyncIterator",d=c.set,p=c.getterFor(h),v=function(e,t,n){var r=e.done;f.resolve(e.value).then((function(e){t({done:r,value:e})}),n)},m=function(e){d(this,{type:h,iterator:i(e),next:e.next})};m.prototype=s(a(l),{next:function(e){var t=p(this),n=!!arguments.length;return new f((function(a,o){var s=i(r(t.next,t.iterator,n?[e]:[]));v(s,a,o)}))},return:function(e){var t=p(this).iterator,n=!!arguments.length;return new f((function(a,s){var c=o(t,"return");if(void 0===c)return a({done:!0,value:e});var u=i(r(c,t,n?[e]:[]));v(u,a,s)}))},throw:function(e){var t=p(this).iterator,n=!!arguments.length;return new f((function(a,s){var c=o(t,"throw");if(void 0===c)return s(e);var u=i(r(c,t,n?[e]:[]));v(u,a,s)}))}}),e.exports=m},"649e":function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").some,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("some",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},"64e5":function(e,t,n){"use strict";var r=n("da84"),i=n("e330"),a=n("d039"),o=n("0ccb").start,s=r.RangeError,c=Math.abs,u=Date.prototype,l=u.toISOString,f=i(u.getTime),h=i(u.getUTCDate),d=i(u.getUTCFullYear),p=i(u.getUTCHours),v=i(u.getUTCMilliseconds),m=i(u.getUTCMinutes),y=i(u.getUTCMonth),g=i(u.getUTCSeconds);e.exports=a((function(){return"0385-07-25T07:06:39.999Z"!=l.call(new Date(-50000000000001))}))||!a((function(){l.call(new Date(NaN))}))?function(){if(!isFinite(f(this)))throw s("Invalid time value");var e=this,t=d(e),n=v(e),r=t<0?"-":t>9999?"+":"";return r+o(c(t),r?6:4,0)+"-"+o(y(e)+1,2,0)+"-"+o(h(e),2,0)+"T"+o(p(e),2,0)+":"+o(m(e),2,0)+":"+o(g(e),2,0)+"."+o(n,3,0)+"Z"}:l},6547:function(e,t,n){var r=n("e330"),i=n("5926"),a=n("577e"),o=n("1d80"),s=r("".charAt),c=r("".charCodeAt),u=r("".slice),l=function(e){return function(t,n){var r,l,f=a(o(t)),h=i(n),d=f.length;return h<0||h>=d?e?"":void 0:(r=c(f,h),r<55296||r>56319||h+1===d||(l=c(f,h+1))<56320||l>57343?e?s(f,h):r:e?u(f,h,h+2):l-56320+(r-55296<<10)+65536)}};e.exports={codeAt:l(!1),charAt:l(!0)}},6566:function(e,t,n){"use strict";var r=n("9bf2").f,i=n("7c73"),a=n("e2cc"),o=n("0366"),s=n("19aa"),c=n("2266"),u=n("7dd0"),l=n("2626"),f=n("83ab"),h=n("f183").fastKey,d=n("69f3"),p=d.set,v=d.getterFor;e.exports={getConstructor:function(e,t,n,u){var l=e((function(e,r){s(e,d),p(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),f||(e.size=0),void 0!=r&&c(r,e[u],{that:e,AS_ENTRIES:n})})),d=l.prototype,m=v(t),y=function(e,t,n){var r,i,a=m(e),o=g(e,t);return o?o.value=n:(a.last=o={index:i=h(t,!0),key:t,value:n,previous:r=a.last,next:void 0,removed:!1},a.first||(a.first=o),r&&(r.next=o),f?a.size++:e.size++,"F"!==i&&(a.index[i]=o)),e},g=function(e,t){var n,r=m(e),i=h(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return a(d,{clear:function(){var e=this,t=m(e),n=t.index,r=t.first;while(r)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete n[r.index],r=r.next;t.first=t.last=void 0,f?t.size=0:e.size=0},delete:function(e){var t=this,n=m(t),r=g(t,e);if(r){var i=r.next,a=r.previous;delete n.index[r.index],r.removed=!0,a&&(a.next=i),i&&(i.previous=a),n.first==r&&(n.first=i),n.last==r&&(n.last=a),f?n.size--:t.size--}return!!r},forEach:function(e){var t,n=m(this),r=o(e,arguments.length>1?arguments[1]:void 0);while(t=t?t.next:n.first){r(t.value,t.key,this);while(t&&t.removed)t=t.previous}},has:function(e){return!!g(this,e)}}),a(d,n?{get:function(e){var t=g(this,e);return t&&t.value},set:function(e,t){return y(this,0===e?0:e,t)}}:{add:function(e){return y(this,e=0===e?0:e,e)}}),f&&r(d,"size",{get:function(){return m(this).size}}),l},setStrong:function(e,t,n){var r=t+" Iterator",i=v(t),a=v(r);u(e,t,(function(e,t){p(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){var e=a(this),t=e.kind,n=e.last;while(n&&n.removed)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),l(t)}}},"658e":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("c65b"),s=n("59ed"),c=n("825a"),u=n("4840"),l=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{intersection:function(e){var t=c(this),n=new(u(t,a("Set"))),r=s(t.has),i=s(n.add);return l(e,(function(e){o(r,t,e)&&o(i,n,e)})),n}})},"65f0":function(e,t,n){var r=n("0b42");e.exports=function(e,t){return new(r(e))(0===t?0:t)}},"660e":function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("c65b"),o=n("825a"),s=n("f8cd"),c=n("d195"),u=c((function(e,t){var n,r,o=this.iterator;return this.remaining--?i(this.next,o,t):(r={done:!0,value:void 0},this.done=!0,n=o["return"],void 0!==n?e.resolve(a(n,o)).then((function(){return r})):r)}));r({target:"AsyncIterator",proto:!0,real:!0},{take:function(e){return new u({iterator:o(this),remaining:s(e)})}})},"664f":function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("sup")},{sup:function(){return i(this,"sup","","")}})},"66c1":function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=n("e163"),s=i.has,c=i.get,u=i.toKey,l=function(e,t,n){var r=s(e,t,n);if(r)return c(e,t,n);var i=o(t);return null!==i?l(e,i,n):void 0};r({target:"Reflect",stat:!0},{getMetadata:function(e,t){var n=arguments.length<3?void 0:u(arguments[2]);return l(e,a(t),n)}})},"66c3":function(e,t,n){var r=n("8104"),i=1,a=3,o=2;function s(e,t){if(!t)return[e.nextBuffer()];var n,r,s=[],c=e.nextUInt8()+1;if(t===o){if(e.length%c!==0)throw new Error("Fixed-Size Lacing Error");for(r=e.length/c,n=0;n<c;n++)s.push(e.nextBuffer(r));return s}var u=[];if(t===i)for(n=0;n<c-1;n++){var l;r=0;do{l=e.nextUInt8(),r+=l}while(255===l);u.push(r)}else if(t===a)for(r=e.nextUIntV(),u.push(r),n=1;n<c-1;n++)r+=e.nextIntV(),u.push(r);for(n=0;n<c-1;n++)s.push(e.nextBuffer(u[n]));return s.push(e.nextBuffer()),s}e.exports=function(e){var t={},n=new r(e);t.trackNumber=n.nextUIntV(),t.timecode=n.nextInt16BE();var i=n.nextUInt8();t.invisible=!!(8&i),t.keyframe=!!(128&i),t.discardable=!!(1&i);var a=(6&i)>>1;return t.frames=s(n,a),t}},6720:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("59ed"),s=n("fc6a"),c=n("dfb9"),u=n("51cf"),l=n("44d2"),f=i.Array,h=a(u("Array").sort);r({target:"Array",proto:!0},{toSorted:function(e){void 0!==e&&o(e);var t=s(this),n=c(f,t);return h(n,e)}}),l("toSorted")},6789:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("7d72");r({target:"WeakSet",proto:!0,real:!0,forced:i},{addAll:a})},"67c0":function(e){e.exports=JSON.parse('{"_args":[["ts-ebml@2.0.2","/var/lib/jenkins/workspace/tumscloud-web-vms/player"]],"_from":"ts-ebml@2.0.2","_id":"ts-ebml@2.0.2","_inBundle":false,"_integrity":"sha512-V/HdlCn3FITQrFHQlVE02XtfMiRLab2QB/YOCfkbJWqiFYG/j5v7gHKV+wem6g0PD6/uxXs5oxMQfDXILmts/Q==","_location":"/ts-ebml","_phantomChildren":{"base64-js":"1.5.1","ieee754":"1.2.1"},"_requested":{"type":"version","registry":true,"raw":"ts-ebml@2.0.2","name":"ts-ebml","escapedName":"ts-ebml","rawSpec":"2.0.2","saveSpec":null,"fetchSpec":"2.0.2"},"_requiredBy":["/"],"_resolved":"http://rdsource.tp-link.com.cn:8081/repository/npm-official/ts-ebml/-/ts-ebml-2.0.2.tgz","_spec":"2.0.2","_where":"/var/lib/jenkins/workspace/tumscloud-web-vms/player","author":{"name":"legokichi duckscallion"},"bin":{"ts-ebml":"./lib/cli.js"},"bugs":{"url":"https://github.com/legokichi/ts-ebml/issues"},"dependencies":{"buffer":"^5.0.7","commander":"^2.11.0","ebml":"^2.2.1","ebml-block":"^1.1.0","events":"^1.1.1","int64-buffer":"^0.1.9","matroska":"^2.2.3"},"description":"ebml decoder and encoder","devDependencies":{"@types/commander":"^2.9.1","@types/qunit":"^2.0.31","browserify":"^13.1.0","empower":"^1.2.3","espower-cli":"^1.1.0","power-assert":"^1.4.4","power-assert-formatter":"^1.4.1","qunit-tap":"^1.5.1","qunitjs":"^2.4.0","tslint":"^3.15.1","typedoc":"^0.5.3","typescript":"^2.4.2","watchify":"^3.7.0"},"homepage":"https://github.com/legokichi/ts-ebml#readme","keywords":["ebml","webm","mkv","matrosika","webp"],"license":"MIT","main":"./lib/index.js","name":"ts-ebml","repository":{"type":"git","url":"git+https://github.com/legokichi/ts-ebml.git"},"scripts":{"browserify":"browserify lib/index.js --standalone EBML -o dist/EBML.js","build":"npm run clean && tsc -p .; npm run browserify","check":"tsc -w --noEmit -p ./","clean":"rm -rf lib/* dist/* test/*.js; mkdir -p dist","doc":"typedoc --mode modules --out doc --disableOutputCheck","example":"tsc; browserify lib/example_seekable.js -o test/example_seekable.js","examples":"tsc; for file in `find lib -name \'example_*.js\' -type f -printf \'%f\\\\n\'`; do browserify lib/$file -o test/$file; done","examples_bsd":"tsc; for file in `find lib -name \'example_*.js\' -type f -print`; do browserify lib/$(basename $file) -o test/$(basename $file); done","init":"npm run update; npm run mkdir; npm run build","lint":"tslint -c ./tslint.json --project ./tsconfig.json --type-check","mkdir":"mkdir lib dist 2>/dev/null","reset":"rm -rf node_modules","setup":"npm install -g http-server;","start":"http-server . -s & tsc -w -p .& watchify lib/example_seekable.js -o test/example_seekable.js","stop":"killall -- node */tsc -w -p","test":"tsc; espower lib/test.js > lib/test.tmp; mv -f lib/test.tmp lib/test.js; browserify lib/test.js -o test/test.js","update":"npm run reset; npm update","watchify":"watchify lib/index.js --standalone EBML -o dist/EBMl.js -v"},"typings":"./lib/index.d.ts","version":"2.0.2"}')},6899:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").filterReject,a=n("1448"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("filterReject",(function(e){var t=i(o(this),e,arguments.length>1?arguments[1]:void 0);return a(this,t)}))},"68ee":function(e,t,n){var r=n("e330"),i=n("d039"),a=n("1626"),o=n("f5df"),s=n("d066"),c=n("8925"),u=function(){},l=[],f=s("Reflect","construct"),h=/^\s*(?:class|function)\b/,d=r(h.exec),p=!h.exec(u),v=function(e){if(!a(e))return!1;try{return f(u,l,e),!0}catch(t){return!1}},m=function(e){if(!a(e))return!1;switch(o(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return p||!!d(h,c(e))}catch(t){return!0}};m.sham=!0,e.exports=!f||i((function(){var e;return v(v.call)||!v(Object)||!v((function(){e=!0}))||e}))?m:v},"69f3":function(e,t,n){var r,i,a,o=n("7f9a"),s=n("da84"),c=n("e330"),u=n("861d"),l=n("9112"),f=n("1a2d"),h=n("c6cd"),d=n("f772"),p=n("d012"),v="Object already initialized",m=s.TypeError,y=s.WeakMap,g=function(e){return a(e)?i(e):r(e,{})},b=function(e){return function(t){var n;if(!u(t)||(n=i(t)).type!==e)throw m("Incompatible receiver, "+e+" required");return n}};if(o||h.state){var T=h.state||(h.state=new y),S=c(T.get),E=c(T.has),_=c(T.set);r=function(e,t){if(E(T,e))throw new m(v);return t.facade=e,_(T,e,t),t},i=function(e){return S(T,e)||{}},a=function(e){return E(T,e)}}else{var k=d("state");p[k]=!0,r=function(e,t){if(f(e,k))throw new m(v);return t.facade=e,l(e,k,t),t},i=function(e){return f(e,k)?e[k]:{}},a=function(e){return f(e,k)}}e.exports={set:r,get:i,has:a,enforce:g,getterFor:b}},"6a86":function(e,t,n){"use strict";var r=n("e330"),i=n("ebb5"),a=n("4673"),o=n("1448"),s=i.aTypedArray,c=i.exportTypedArrayMethod,u=r(a);c("uniqueBy",(function(e){return o(this,u(s(this),e))}))},"6a90":function(e,t,n){var r=n("746f");r("dispose")},"6b93":function(e,t,n){var r=n("23e7"),i=n("867a");r({target:"Math",stat:!0},{log10:i})},"6b9e":function(e,t,n){var r=n("746f");r("search")},"6b9f":function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{umulh:function(e,t){var n=65535,r=+e,i=+t,a=r&n,o=i&n,s=r>>>16,c=i>>>16,u=(s*o>>>0)+(a*o>>>16);return s*c+(u>>>16)+((a*c>>>0)+(u&n)>>>16)}})},"6c57":function(e,t,n){var r=n("23e7"),i=n("da84");r({global:!0},{globalThis:i})},"6d08":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return function(t){var n=e,r=n.lib,i=r.CipherParams,a=n.enc,o=a.Hex,s=n.format;s.Hex={stringify:function(e){return e.ciphertext.toString(o)},parse:function(e){var t=o.parse(e);return i.create({ciphertext:t})}}}(),e.format.Hex}))},"6d54":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("d429"),o=n("fc6a"),s=i.Array;r({target:"Array",proto:!0},{with:function(e,t){return a(o(this),s,e,t)}})},"6d61":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("94ca"),s=n("6eeb"),c=n("f183"),u=n("2266"),l=n("19aa"),f=n("1626"),h=n("861d"),d=n("d039"),p=n("1c7e"),v=n("d44e"),m=n("7156");e.exports=function(e,t,n){var y=-1!==e.indexOf("Map"),g=-1!==e.indexOf("Weak"),b=y?"set":"add",T=i[e],S=T&&T.prototype,E=T,_={},k=function(e){var t=a(S[e]);s(S,e,"add"==e?function(e){return t(this,0===e?0:e),this}:"delete"==e?function(e){return!(g&&!h(e))&&t(this,0===e?0:e)}:"get"==e?function(e){return g&&!h(e)?void 0:t(this,0===e?0:e)}:"has"==e?function(e){return!(g&&!h(e))&&t(this,0===e?0:e)}:function(e,n){return t(this,0===e?0:e,n),this})},w=o(e,!f(T)||!(g||S.forEach&&!d((function(){(new T).entries().next()}))));if(w)E=n.getConstructor(t,e,y,b),c.enable();else if(o(e,!0)){var A=new E,R=A[b](g?{}:-0,1)!=A,x=d((function(){A.has(1)})),C=p((function(e){new T(e)})),I=!g&&d((function(){var e=new T,t=5;while(t--)e[b](t,t);return!e.has(-0)}));C||(E=t((function(e,t){l(e,S);var n=m(new T,e,E);return void 0!=t&&u(t,n[b],{that:n,AS_ENTRIES:y}),n})),E.prototype=S,S.constructor=E),(x||I)&&(k("delete"),k("has"),y&&k("get")),(I||R)&&k(b),g&&S.clear&&delete S.clear}return _[e]=E,r({global:!0,forced:E!=T},_),v(E,e),g||n.setStrong(E,e,y),E}},"6dd7":function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=n("e163"),s=i.has,c=i.toKey,u=function(e,t,n){var r=s(e,t,n);if(r)return!0;var i=o(t);return null!==i&&u(e,i,n)};r({target:"Reflect",stat:!0},{hasMetadata:function(e,t){var n=arguments.length<3?void 0:c(arguments[2]);return u(e,a(t),n)}})},"6eba":function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("e330"),o=i.Date,s=a(o.prototype.getTime);r({target:"Date",stat:!0},{now:function(){return s(new o)}})},"6eeb":function(e,t,n){var r=n("da84"),i=n("1626"),a=n("1a2d"),o=n("9112"),s=n("ce4e"),c=n("8925"),u=n("69f3"),l=n("5e77").CONFIGURABLE,f=u.get,h=u.enforce,d=String(String).split("String");(e.exports=function(e,t,n,c){var u,f=!!c&&!!c.unsafe,p=!!c&&!!c.enumerable,v=!!c&&!!c.noTargetGet,m=c&&void 0!==c.name?c.name:t;i(n)&&("Symbol("===String(m).slice(0,7)&&(m="["+String(m).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!a(n,"name")||l&&n.name!==m)&&o(n,"name",m),u=h(n),u.source||(u.source=d.join("string"==typeof m?m:""))),e!==r?(f?!v&&e[t]&&(p=!0):delete e[t],p?e[t]=n:o(e,t,n)):p?e[t]=n:s(t,n)})(Function.prototype,"toString",(function(){return i(this)&&f(this).source||c(this)}))},"6f53":function(e,t,n){var r=n("83ab"),i=n("e330"),a=n("df75"),o=n("fc6a"),s=n("d1e7").f,c=i(s),u=i([].push),l=function(e){return function(t){var n,i=o(t),s=a(i),l=s.length,f=0,h=[];while(l>f)n=s[f++],r&&!c(i,n)||u(h,e?[n,i[n]]:i[n]);return h}};e.exports={entries:l(!0),values:l(!1)}},7039:function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("057f").f,o=i((function(){return!Object.getOwnPropertyNames(1)}));r({target:"Object",stat:!0,forced:o},{getOwnPropertyNames:a})},"70e3":function(e,t,n){var r=n("23e7"),i=Math.min,a=Math.max;r({target:"Math",stat:!0},{clamp:function(e,t,n){return i(n,a(t,e))}})},7156:function(e,t,n){var r=n("1626"),i=n("861d"),a=n("d2bb");e.exports=function(e,t,n){var o,s;return a&&r(o=t.constructor)&&o!==n&&i(s=o.prototype)&&s!==n.prototype&&a(e,s),e}},"71f8":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("0a0d");r({target:"WeakMap",proto:!0,real:!0,forced:i},{deleteAll:a})},7245:function(e,t,n){var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("7b0b"),s=n("3a9b"),c=n("a91f"),u=n("d195"),l=n("a1b3"),f=n("9a1f"),h=n("35a1"),d=n("dc4a"),p=n("b622"),v=n("63fa"),m=p("asyncIterator"),y=u((function(e,t){return a(i(this.next,this.iterator,t))}),!0);r({target:"AsyncIterator",stat:!0},{from:function(e){var t,n=o(e),r=d(n,m);return r&&(t=l(n,r),s(c,t))?t:void 0===t&&(r=h(n),r)?new v(f(n,r)):new y({iterator:void 0!==t?t:n})}})},"72ba":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("fc6a"),o=n("f36a"),s=n("ad02"),c=n("44d2"),u=i.Array;r({target:"Array",proto:!0},{toSpliced:function(e,t){return s(a(this),u,o(arguments))}}),c("toSpliced")},"72d0":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("0366"),s=n("c65b"),c=n("59ed"),u=n("825a"),l=n("4840"),f=n("5860"),h=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{map:function(e){var t=u(this),n=f(t),r=o(e,arguments.length>1?arguments[1]:void 0),i=new(l(t,a("Set"))),d=c(i.add);return h(n,(function(e){s(d,i,r(e,e,t))}),{IS_ITERATOR:!0}),i}})},"72f7":function(e,t,n){"use strict";var r=n("ebb5").exportTypedArrayMethod,i=n("d039"),a=n("da84"),o=n("e330"),s=a.Uint8Array,c=s&&s.prototype||{},u=[].toString,l=o([].join);i((function(){u.call({})}))&&(u=function(){return l(this)});var f=c.toString!=u;r("toString",u,f)},"72fe":function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(t){var n=e,r=n.lib,i=r.WordArray,a=r.Hasher,o=n.algo,s=[];(function(){for(var e=0;e<64;e++)s[e]=4294967296*t.abs(t.sin(e+1))|0})();var c=o.MD5=a.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var r=t+n,i=e[r];e[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var a=this._hash.words,o=e[t+0],c=e[t+1],d=e[t+2],p=e[t+3],v=e[t+4],m=e[t+5],y=e[t+6],g=e[t+7],b=e[t+8],T=e[t+9],S=e[t+10],E=e[t+11],_=e[t+12],k=e[t+13],w=e[t+14],A=e[t+15],R=a[0],x=a[1],C=a[2],I=a[3];R=u(R,x,C,I,o,7,s[0]),I=u(I,R,x,C,c,12,s[1]),C=u(C,I,R,x,d,17,s[2]),x=u(x,C,I,R,p,22,s[3]),R=u(R,x,C,I,v,7,s[4]),I=u(I,R,x,C,m,12,s[5]),C=u(C,I,R,x,y,17,s[6]),x=u(x,C,I,R,g,22,s[7]),R=u(R,x,C,I,b,7,s[8]),I=u(I,R,x,C,T,12,s[9]),C=u(C,I,R,x,S,17,s[10]),x=u(x,C,I,R,E,22,s[11]),R=u(R,x,C,I,_,7,s[12]),I=u(I,R,x,C,k,12,s[13]),C=u(C,I,R,x,w,17,s[14]),x=u(x,C,I,R,A,22,s[15]),R=l(R,x,C,I,c,5,s[16]),I=l(I,R,x,C,y,9,s[17]),C=l(C,I,R,x,E,14,s[18]),x=l(x,C,I,R,o,20,s[19]),R=l(R,x,C,I,m,5,s[20]),I=l(I,R,x,C,S,9,s[21]),C=l(C,I,R,x,A,14,s[22]),x=l(x,C,I,R,v,20,s[23]),R=l(R,x,C,I,T,5,s[24]),I=l(I,R,x,C,w,9,s[25]),C=l(C,I,R,x,p,14,s[26]),x=l(x,C,I,R,b,20,s[27]),R=l(R,x,C,I,k,5,s[28]),I=l(I,R,x,C,d,9,s[29]),C=l(C,I,R,x,g,14,s[30]),x=l(x,C,I,R,_,20,s[31]),R=f(R,x,C,I,m,4,s[32]),I=f(I,R,x,C,b,11,s[33]),C=f(C,I,R,x,E,16,s[34]),x=f(x,C,I,R,w,23,s[35]),R=f(R,x,C,I,c,4,s[36]),I=f(I,R,x,C,v,11,s[37]),C=f(C,I,R,x,g,16,s[38]),x=f(x,C,I,R,S,23,s[39]),R=f(R,x,C,I,k,4,s[40]),I=f(I,R,x,C,o,11,s[41]),C=f(C,I,R,x,p,16,s[42]),x=f(x,C,I,R,y,23,s[43]),R=f(R,x,C,I,T,4,s[44]),I=f(I,R,x,C,_,11,s[45]),C=f(C,I,R,x,A,16,s[46]),x=f(x,C,I,R,d,23,s[47]),R=h(R,x,C,I,o,6,s[48]),I=h(I,R,x,C,g,10,s[49]),C=h(C,I,R,x,w,15,s[50]),x=h(x,C,I,R,m,21,s[51]),R=h(R,x,C,I,_,6,s[52]),I=h(I,R,x,C,p,10,s[53]),C=h(C,I,R,x,S,15,s[54]),x=h(x,C,I,R,c,21,s[55]),R=h(R,x,C,I,b,6,s[56]),I=h(I,R,x,C,A,10,s[57]),C=h(C,I,R,x,y,15,s[58]),x=h(x,C,I,R,k,21,s[59]),R=h(R,x,C,I,v,6,s[60]),I=h(I,R,x,C,E,10,s[61]),C=h(C,I,R,x,d,15,s[62]),x=h(x,C,I,R,T,21,s[63]),a[0]=a[0]+R|0,a[1]=a[1]+x|0,a[2]=a[2]+C|0,a[3]=a[3]+I|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;n[i>>>5]|=128<<24-i%32;var a=t.floor(r/4294967296),o=r;n[15+(i+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),n[14+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),e.sigBytes=4*(n.length+1),this._process();for(var s=this._hash,c=s.words,u=0;u<4;u++){var l=c[u];c[u]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return s},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}});function u(e,t,n,r,i,a,o){var s=e+(t&n|~t&r)+i+o;return(s<<a|s>>>32-a)+t}function l(e,t,n,r,i,a,o){var s=e+(t&r|n&~r)+i+o;return(s<<a|s>>>32-a)+t}function f(e,t,n,r,i,a,o){var s=e+(t^n^r)+i+o;return(s<<a|s>>>32-a)+t}function h(e,t,n,r,i,a,o){var s=e+(n^(t|~r))+i+o;return(s<<a|s>>>32-a)+t}n.MD5=a._createHelper(c),n.HmacMD5=a._createHmacHelper(c)}(Math),e.MD5}))},"735e":function(e,t,n){"use strict";var r=n("ebb5"),i=n("c65b"),a=n("81d5"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("fill",(function(e){var t=arguments.length;return i(a,o(this),e,t>1?arguments[1]:void 0,t>2?arguments[2]:void 0)}))},"73d9":function(e,t,n){var r=n("44d2");r("flatMap")},7418:function(e,t){t.f=Object.getOwnPropertySymbols},"746f":function(e,t,n){var r=n("428f"),i=n("1a2d"),a=n("e538"),o=n("9bf2").f;e.exports=function(e){var t=r.Symbol||(r.Symbol={});i(t,e)||o(t,e,{value:a.f(e)})}},"74d4":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("5860"),c=n("2266");r({target:"Set",proto:!0,real:!0,forced:i},{every:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return!c(n,(function(e,n){if(!r(e,e,t))return n()}),{IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},"74e8":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("83ab"),s=n("8aa7"),c=n("ebb5"),u=n("621a"),l=n("19aa"),f=n("5c6c"),h=n("9112"),d=n("eac5"),p=n("50c4"),v=n("0b25"),m=n("182d"),y=n("a04b"),g=n("1a2d"),b=n("f5df"),T=n("861d"),S=n("d9b5"),E=n("7c73"),_=n("3a9b"),k=n("d2bb"),w=n("241c").f,A=n("a078"),R=n("b727").forEach,x=n("2626"),C=n("9bf2"),I=n("06cf"),P=n("69f3"),O=n("7156"),D=P.get,U=P.set,M=C.f,B=I.f,N=Math.round,L=i.RangeError,F=u.ArrayBuffer,j=F.prototype,W=u.DataView,H=c.NATIVE_ARRAY_BUFFER_VIEWS,V=c.TYPED_ARRAY_CONSTRUCTOR,q=c.TYPED_ARRAY_TAG,z=c.TypedArray,G=c.TypedArrayPrototype,Y=c.aTypedArrayConstructor,K=c.isTypedArray,X="BYTES_PER_ELEMENT",Q="Wrong length",$=function(e,t){Y(e);var n=0,r=t.length,i=new e(r);while(r>n)i[n]=t[n++];return i},Z=function(e,t){M(e,t,{get:function(){return D(this)[t]}})},J=function(e){var t;return _(j,e)||"ArrayBuffer"==(t=b(e))||"SharedArrayBuffer"==t},ee=function(e,t){return K(e)&&!S(t)&&t in e&&d(+t)&&t>=0},te=function(e,t){return t=y(t),ee(e,t)?f(2,e[t]):B(e,t)},ne=function(e,t,n){return t=y(t),!(ee(e,t)&&T(n)&&g(n,"value"))||g(n,"get")||g(n,"set")||n.configurable||g(n,"writable")&&!n.writable||g(n,"enumerable")&&!n.enumerable?M(e,t,n):(e[t]=n.value,e)};o?(H||(I.f=te,C.f=ne,Z(G,"buffer"),Z(G,"byteOffset"),Z(G,"byteLength"),Z(G,"length")),r({target:"Object",stat:!0,forced:!H},{getOwnPropertyDescriptor:te,defineProperty:ne}),e.exports=function(e,t,n){var o=e.match(/\d+$/)[0]/8,c=e+(n?"Clamped":"")+"Array",u="get"+e,f="set"+e,d=i[c],y=d,g=y&&y.prototype,b={},S=function(e,t){var n=D(e);return n.view[u](t*o+n.byteOffset,!0)},_=function(e,t,r){var i=D(e);n&&(r=(r=N(r))<0?0:r>255?255:255&r),i.view[f](t*o+i.byteOffset,r,!0)},C=function(e,t){M(e,t,{get:function(){return S(this,t)},set:function(e){return _(this,t,e)},enumerable:!0})};H?s&&(y=t((function(e,t,n,r){return l(e,g),O(function(){return T(t)?J(t)?void 0!==r?new d(t,m(n,o),r):void 0!==n?new d(t,m(n,o)):new d(t):K(t)?$(y,t):a(A,y,t):new d(v(t))}(),e,y)})),k&&k(y,z),R(w(d),(function(e){e in y||h(y,e,d[e])})),y.prototype=g):(y=t((function(e,t,n,r){l(e,g);var i,s,c,u=0,f=0;if(T(t)){if(!J(t))return K(t)?$(y,t):a(A,y,t);i=t,f=m(n,o);var h=t.byteLength;if(void 0===r){if(h%o)throw L(Q);if(s=h-f,s<0)throw L(Q)}else if(s=p(r)*o,s+f>h)throw L(Q);c=s/o}else c=v(t),s=c*o,i=new F(s);U(e,{buffer:i,byteOffset:f,byteLength:s,length:c,view:new W(i)});while(u<c)C(e,u++)})),k&&k(y,z),g=y.prototype=E(G)),g.constructor!==y&&h(g,"constructor",y),h(g,V,y),q&&h(g,q,c),b[c]=y,r({global:!0,forced:y!=d,sham:!H},b),X in y||h(y,X,o),X in g||h(g,X,o),x(c)}):e.exports=function(){}},"76d6":function(e,t,n){"use strict";var r=n("23e7"),i=n("2266"),a=n("59ed"),o=n("825a");r({target:"Iterator",proto:!0,real:!0},{every:function(e){return o(this),a(e),!i(this,(function(t,n){if(!e(t))return n()}),{IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},"77a7":function(e,t,n){var r=n("da84"),i=r.Array,a=Math.abs,o=Math.pow,s=Math.floor,c=Math.log,u=Math.LN2,l=function(e,t,n){var r,l,f,h=i(n),d=8*n-t-1,p=(1<<d)-1,v=p>>1,m=23===t?o(2,-24)-o(2,-77):0,y=e<0||0===e&&1/e<0?1:0,g=0;e=a(e),e!=e||e===1/0?(l=e!=e?1:0,r=p):(r=s(c(e)/u),f=o(2,-r),e*f<1&&(r--,f*=2),e+=r+v>=1?m/f:m*o(2,1-v),e*f>=2&&(r++,f/=2),r+v>=p?(l=0,r=p):r+v>=1?(l=(e*f-1)*o(2,t),r+=v):(l=e*o(2,v-1)*o(2,t),r=0));while(t>=8)h[g++]=255&l,l/=256,t-=8;r=r<<t|l,d+=t;while(d>0)h[g++]=255&r,r/=256,d-=8;return h[--g]|=128*y,h},f=function(e,t){var n,r=e.length,i=8*r-t-1,a=(1<<i)-1,s=a>>1,c=i-7,u=r-1,l=e[u--],f=127&l;l>>=7;while(c>0)f=256*f+e[u--],c-=8;n=f&(1<<-c)-1,f>>=-c,c+=t;while(c>0)n=256*n+e[u--],c-=8;if(0===f)f=1-s;else{if(f===a)return n?NaN:l?-1/0:1/0;n+=o(2,t),f-=s}return(l?-1:1)*n*o(2,f-t)};e.exports={pack:l,unpack:f}},"77d9":function(e,t,n){"use strict";var r=n("ebb5"),i=n("a258").findLastIndex,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("findLastIndex",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},7839:function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"783c":function(e,t,n){n("4ec9"),n("10d1");var r=n("d066"),i=n("e330"),a=n("5692"),o=r("Map"),s=r("WeakMap"),c=i([].push),u=a("metadata"),l=u.store||(u.store=new s),f=function(e,t,n){var r=l.get(e);if(!r){if(!n)return;l.set(e,r=new o)}var i=r.get(t);if(!i){if(!n)return;r.set(t,i=new o)}return i},h=function(e,t,n){var r=f(t,n,!1);return void 0!==r&&r.has(e)},d=function(e,t,n){var r=f(t,n,!1);return void 0===r?void 0:r.get(e)},p=function(e,t,n,r){f(n,r,!0).set(e,t)},v=function(e,t){var n=f(e,t,!1),r=[];return n&&n.forEach((function(e,t){c(r,t)})),r},m=function(e){return void 0===e||"symbol"==typeof e?e:String(e)};e.exports={store:l,getMap:f,has:h,get:d,set:p,keys:v,toKey:m}},"785a":function(e,t,n){var r=n("cc12"),i=r("span").classList,a=i&&i.constructor&&i.constructor.prototype;e.exports=a===Object.prototype?void 0:a},7898:function(e,t,n){var r=n("23e7"),i=n("8eb5"),a=Math.exp;r({target:"Math",stat:!0},{tanh:function(e){var t=i(e=+e),n=i(-e);return t==1/0?1:n==1/0?-1:(t-n)/(a(e)+a(-e))}})},"78ed":function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{imulh:function(e,t){var n=65535,r=+e,i=+t,a=r&n,o=i&n,s=r>>16,c=i>>16,u=(s*o>>>0)+(a*o>>>16);return s*c+(u>>16)+((a*c>>>0)+(u&n)>>16)}})},"79a8":function(e,t,n){var r=n("23e7"),i=Math.asinh,a=Math.log,o=Math.sqrt;function s(e){return isFinite(e=+e)&&0!=e?e<0?-s(-e):a(e+o(e*e+1)):e}r({target:"Math",stat:!0,forced:!(i&&1/i(0)>0)},{asinh:s})},"7a5b":function(e,t,n){var r=n("23e7"),i=n("68ee");r({target:"Function",stat:!0},{isConstructor:i})},"7a77":function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,e.exports=r},"7a82":function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("9bf2").f;r({target:"Object",stat:!0,forced:Object.defineProperty!==a,sham:!i},{defineProperty:a})},"7aac":function(e,t,n){"use strict";var r=n("c532");e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,a,o){var s=[];s.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),r.isString(i)&&s.push("path="+i),r.isString(a)&&s.push("domain="+a),!0===o&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},"7b0b":function(e,t,n){var r=n("da84"),i=n("1d80"),a=r.Object;e.exports=function(e){return a(i(e))}},"7b8b":function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("59ed"),o=n("825a"),s=n("d195"),c=s((function(e,t){var n=this,r=n.mapper;return e.resolve(o(i(n.next,n.iterator,t))).then((function(t){return o(t).done?(n.done=!0,{done:!0,value:void 0}):e.resolve(r(t.value)).then((function(e){return{done:!1,value:e}}))}))}));r({target:"AsyncIterator",proto:!0,real:!0},{map:function(e){return new c({iterator:o(this),mapper:a(e)})}})},"7bbc":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("df2f"),n("5980"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.Base,i=n.WordArray,a=t.algo,o=a.SHA1,s=a.HMAC,c=a.PBKDF2=r.extend({cfg:r.extend({keySize:4,hasher:o,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){var n=this.cfg,r=s.create(n.hasher,e),a=i.create(),o=i.create([1]),c=a.words,u=o.words,l=n.keySize,f=n.iterations;while(c.length<l){var h=r.update(t).finalize(o);r.reset();for(var d=h.words,p=d.length,v=h,m=1;m<f;m++){v=r.finalize(v),r.reset();for(var y=v.words,g=0;g<p;g++)d[g]^=y[g]}a.concat(h),u[0]++}return a.sigBytes=4*l,a}});t.PBKDF2=function(e,t,n){return c.create(n).compute(e,t)}}(),e.PBKDF2}))},"7c37":function(e,t,n){var r=n("605d");e.exports=function(e){try{if(r)return Function('return require("'+e+'")')()}catch(t){}}},"7c73":function(e,t,n){var r,i=n("825a"),a=n("37e8"),o=n("7839"),s=n("d012"),c=n("1be4"),u=n("cc12"),l=n("f772"),f=">",h="<",d="prototype",p="script",v=l("IE_PROTO"),m=function(){},y=function(e){return h+p+f+e+h+"/"+p+f},g=function(e){e.write(y("")),e.close();var t=e.parentWindow.Object;return e=null,t},b=function(){var e,t=u("iframe"),n="java"+p+":";return t.style.display="none",c.appendChild(t),t.src=String(n),e=t.contentWindow.document,e.open(),e.write(y("document.F=Object")),e.close(),e.F},T=function(){try{r=new ActiveXObject("htmlfile")}catch(t){}T="undefined"!=typeof document?document.domain&&r?g(r):b():g(r);var e=o.length;while(e--)delete T[d][o[e]];return T()};s[v]=!0,e.exports=Object.create||function(e,t){var n;return null!==e?(m[d]=i(e),n=new m,m[d]=null,n[v]=e):n=T(),void 0===t?n:a.f(n,t)}},"7cdf":function(e,t,n){"use strict";var r=n("23e7"),i=n("6547").charAt,a=n("d039"),o=n("1d80"),s=n("5926"),c=n("577e"),u=a((function(){return"𠮷"!=="𠮷".at(-2)}));r({target:"String",proto:!0,forced:u},{at:function(e){var t=c(o(this)),n=t.length,r=s(e),a=r>=0?r:n+r;return a<0||a>=n?void 0:i(t,a)}})},"7d72":function(e,t,n){"use strict";var r=n("c65b"),i=n("59ed"),a=n("825a");e.exports=function(){for(var e=a(this),t=i(e.add),n=0,o=arguments.length;n<o;n++)r(t,e,arguments[n]);return e}},"7db0":function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").find,a=n("44d2"),o="find",s=!0;o in[]&&Array(1)[o]((function(){s=!1})),r({target:"Array",proto:!0,forced:s},{find:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a(o)},"7dd0":function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b"),a=n("c430"),o=n("5e77"),s=n("1626"),c=n("9ed3"),u=n("e163"),l=n("d2bb"),f=n("d44e"),h=n("9112"),d=n("6eeb"),p=n("b622"),v=n("3f8c"),m=n("ae93"),y=o.PROPER,g=o.CONFIGURABLE,b=m.IteratorPrototype,T=m.BUGGY_SAFARI_ITERATORS,S=p("iterator"),E="keys",_="values",k="entries",w=function(){return this};e.exports=function(e,t,n,o,p,m,A){c(n,t,o);var R,x,C,I=function(e){if(e===p&&M)return M;if(!T&&e in D)return D[e];switch(e){case E:return function(){return new n(this,e)};case _:return function(){return new n(this,e)};case k:return function(){return new n(this,e)}}return function(){return new n(this)}},P=t+" Iterator",O=!1,D=e.prototype,U=D[S]||D["@@iterator"]||p&&D[p],M=!T&&U||I(p),B="Array"==t&&D.entries||U;if(B&&(R=u(B.call(new e)),R!==Object.prototype&&R.next&&(a||u(R)===b||(l?l(R,b):s(R[S])||d(R,S,w)),f(R,P,!0,!0),a&&(v[P]=w))),y&&p==_&&U&&U.name!==_&&(!a&&g?h(D,"name",_):(O=!0,M=function(){return i(U,this)})),p)if(x={values:I(_),keys:m?M:I(E),entries:I(k)},A)for(C in x)(T||O||!(C in D))&&d(D,C,x[C]);else r({target:t,proto:!0,forced:T||O},x);return a&&!A||D[S]===M||d(D,S,M,{name:p}),v[t]=M,x}},"7e12":function(e,t,n){var r=n("da84"),i=n("d039"),a=n("e330"),o=n("577e"),s=n("58a8").trim,c=n("5899"),u=a("".charAt),l=r.parseFloat,f=r.Symbol,h=f&&f.iterator,d=1/l(c+"-0")!==-1/0||h&&!i((function(){l(Object(h))}));e.exports=d?function(e){var t=s(o(e)),n=l(t);return 0===n&&"-"==u(t,0)?-0:n}:l},"7ed3":function(e,t,n){var r=n("23e7"),i=n("c65b"),a=n("825a"),o=n("861d"),s=n("c60d"),c=n("d039"),u=n("9bf2"),l=n("06cf"),f=n("e163"),h=n("5c6c");function d(e,t,n){var r,c,p,v=arguments.length<4?e:arguments[3],m=l.f(a(e),t);if(!m){if(o(c=f(e)))return d(c,t,n,v);m=h(0)}if(s(m)){if(!1===m.writable||!o(v))return!1;if(r=l.f(v,t)){if(r.get||r.set||!1===r.writable)return!1;r.value=n,u.f(v,t,r)}else u.f(v,t,h(0,n))}else{if(p=m.set,void 0===p)return!1;i(p,v,n)}return!0}var p=c((function(){var e=function(){},t=u.f(new e,"a",{configurable:!0});return!1!==Reflect.set(e.prototype,"a",1,t)}));r({target:"Reflect",stat:!0,forced:p},{set:d})},"7f78":function(e,t,n){var r=n("23e7"),i=n("825a"),a=n("e163"),o=n("e177");r({target:"Reflect",stat:!0,sham:!o},{getPrototypeOf:function(e){return a(i(e))}})},"7f9a":function(e,t,n){var r=n("da84"),i=n("1626"),a=n("8925"),o=r.WeakMap;e.exports=i(o)&&/native code/.test(a(o))},8009:function(e,t,n){var r=n("746f");r("replaceAll")},"802d":function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("fc6a"),s=n("577e"),c=n("07fa"),u=i.TypeError,l=Array.prototype,f=a(l.push),h=a(l.join);r({target:"String",stat:!0},{cooked:function(e){var t=o(e),n=c(t),r=arguments.length,i=[],a=0;while(n>a){var l=t[a++];if(void 0===l)throw u("Incorrect template");if(f(i,s(l)),a===n)return h(i,"");a<r&&f(i,s(arguments[a]))}}})},"80e0":function(e,t,n){var r=n("746f");r("replace")},8104:function(e,t,n){var r=n("ea85");function i(e){this.buffer=e,this.offset=0}i.prototype.nextInt16BE=function(){var e=this.buffer.readInt16BE(this.offset);return this.offset+=2,e},i.prototype.nextUInt8=function(){var e=this.buffer.readUInt8(this.offset);return this.offset+=1,e},i.prototype.nextUIntV=function(){var e=r(this.buffer,this.offset);return this.offset+=e.length,e.value},i.prototype.nextIntV=function(){var e=r(this.buffer,this.offset,!0);return this.offset+=e.length,e.value},i.prototype.nextBuffer=function(e){var t=e?this.buffer.slice(this.offset,this.offset+e):this.buffer.slice(this.offset);return this.offset+=e||this.length,t},Object.defineProperty(i.prototype,"length",{get:function(){return this.buffer.length-this.offset}}),e.exports=i},8172:function(e,t,n){var r=n("746f");r("toPrimitive")},8182:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("2ba4"),o=n("a799"),s=n("d066"),c=n("7c73"),u=i.Object,l=function(){var e=s("Object","freeze");return e?e(c(null)):c(null)};r({global:!0},{compositeKey:function(){return a(o,u,arguments).get("object",l)}})},"81b8":function(e,t,n){var r=n("746f");r("unscopables")},"81bf":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.mode.ECB=function(){var t=e.lib.BlockCipherMode.extend();return t.Encryptor=t.extend({processBlock:function(e,t){this._cipher.encryptBlock(e,t)}}),t.Decryptor=t.extend({processBlock:function(e,t){this._cipher.decryptBlock(e,t)}}),t}(),e.mode.ECB}))},"81d5":function(e,t,n){"use strict";var r=n("7b0b"),i=n("23cb"),a=n("07fa");e.exports=function(e){var t=r(this),n=a(t),o=arguments.length,s=i(o>1?arguments[1]:void 0,n),c=o>2?arguments[2]:void 0,u=void 0===c?n:i(c,n);while(u>s)t[s++]=e;return t}},"820e":function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b"),a=n("59ed"),o=n("f069"),s=n("e667"),c=n("2266");r({target:"Promise",stat:!0},{allSettled:function(e){var t=this,n=o.f(t),r=n.resolve,u=n.reject,l=s((function(){var n=a(t.resolve),o=[],s=0,u=1;c(e,(function(e){var a=s++,c=!1;u++,i(n,t,e).then((function(e){c||(c=!0,o[a]={status:"fulfilled",value:e},--u||r(o))}),(function(e){c||(c=!0,o[a]={status:"rejected",reason:e},--u||r(o))}))})),--u||r(o)}));return l.error&&u(l.value),n.promise}})},"825a":function(e,t,n){var r=n("da84"),i=n("861d"),a=r.String,o=r.TypeError;e.exports=function(e){if(i(e))return e;throw o(a(e)+" is not an object")}},8260:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("59ed"),s=n("825a"),c=n("d066"),u=c("Promise"),l=i.TypeError;r({target:"AsyncIterator",proto:!0,real:!0},{reduce:function(e){var t=s(this),n=o(t.next),r=arguments.length<2,i=r?void 0:arguments[1];return o(e),new u((function(o,c){var f=function(){try{u.resolve(s(a(n,t))).then((function(t){try{if(s(t).done)r?c(l("Reduce of empty iterator with no initial value")):o(i);else{var n=t.value;r?(r=!1,i=n,f()):u.resolve(e(i,n)).then((function(e){i=e,f()}),c)}}catch(a){c(a)}}),c)}catch(h){c(h)}};f()}))}})},"82da":function(e,t,n){var r=n("23e7"),i=n("ebb5"),a=i.NATIVE_ARRAY_BUFFER_VIEWS;r({target:"ArrayBuffer",stat:!0,forced:!a},{isView:i.isView})},"82f8":function(e,t,n){"use strict";var r=n("ebb5"),i=n("4d64").includes,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("includes",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},"83ab":function(e,t,n){var r=n("d039");e.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},"83b9":function(e,t,n){"use strict";var r=n("d925"),i=n("e683");e.exports=function(e,t){return e&&!r(t)?i(e,t):t}},"83e6":function(e,t,n){var r=n("23e7"),i=n("e8b5"),a=Object.isFrozen,o=function(e,t){if(!a||!i(e)||!a(e))return!1;var n,r=0,o=e.length;while(r<o)if(n=e[r++],!("string"==typeof n||t&&"undefined"==typeof n))return!1;return 0!==o};r({target:"Array",stat:!0},{isTemplateObject:function(e){if(!o(e,!0))return!1;var t=e.raw;return!(t.length!==e.length||!o(t,!1))}})},"83f2":function(e,t,n){"use strict";var r=n("23e7"),i=n("a4f2"),a=n("44d2");r({target:"Array",proto:!0},{groupBy:function(e){var t=arguments.length>1?arguments[1]:void 0;return i(this,e,t)}}),a("groupBy")},8418:function(e,t,n){"use strict";var r=n("a04b"),i=n("9bf2"),a=n("5c6c");e.exports=function(e,t,n){var o=r(t);o in e?i.f(e,o,a(0,n)):e[o]=n}},"841c":function(e,t,n){"use strict";var r=n("c65b"),i=n("d784"),a=n("825a"),o=n("1d80"),s=n("129f"),c=n("577e"),u=n("dc4a"),l=n("14c3");i("search",(function(e,t,n){return[function(t){var n=o(this),i=void 0==t?void 0:u(t,e);return i?r(i,t,n):new RegExp(t)[e](c(n))},function(e){var r=a(this),i=c(e),o=n(t,r,i);if(o.done)return o.value;var u=r.lastIndex;s(u,0)||(r.lastIndex=0);var f=l(r,i);return s(r.lastIndex,u)||(r.lastIndex=u),null===f?-1:f.index}]}))},"843c":function(e,t,n){"use strict";var r=n("23e7"),i=n("0ccb").end,a=n("9a0c");r({target:"String",proto:!0,forced:a},{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},"848b":function(e,t,n){"use strict";var r=n("5cce").version,i={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){i[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));var a={};function o(e,t,n){if("object"!==typeof e)throw new TypeError("options must be an object");var r=Object.keys(e),i=r.length;while(i-- >0){var a=r[i],o=t[a];if(o){var s=e[a],c=void 0===s||o(s,a,e);if(!0!==c)throw new TypeError("option "+a+" must be "+c)}else if(!0!==n)throw Error("Unknown option "+a)}}i.transitional=function(e,t,n){function i(e,t){return"[Axios v"+r+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return function(n,r,o){if(!1===e)throw new Error(i(r," has been removed"+(t?" in "+t:"")));return t&&!a[r]&&(a[r]=!0,console.warn(i(r," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,r,o)}},e.exports={assertOptions:o,validators:i}},"84c3":function(e,t,n){var r=n("74e8");r("Uint16",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},"857a":function(e,t,n){var r=n("e330"),i=n("1d80"),a=n("577e"),o=/"/g,s=r("".replace);e.exports=function(e,t,n,r){var c=a(i(e)),u="<"+t;return""!==n&&(u+=" "+n+'="'+s(a(r),o,""")+'"'),u+">"+c+"</"+t+">"}},"85ca":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("c65b"),s=n("59ed"),c=n("825a"),u=n("4840"),l=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{difference:function(e){var t=c(this),n=new(u(t,a("Set")))(t),r=s(n["delete"]);return l(e,(function(e){o(r,n,e)})),n}})},"861d":function(e,t,n){var r=n("1626");e.exports=function(e){return"object"==typeof e?null!==e:r(e)}},"867a":function(e,t){var n=Math.log,r=Math.LOG10E;e.exports=Math.log10||function(e){return n(e)*r}},8875:function(e,t,n){var r,i,a;(function(n,o){i=[],r=o,a="function"===typeof r?r.apply(t,i):r,void 0===a||(e.exports=a)})("undefined"!==typeof self&&self,(function(){function e(){var t=Object.getOwnPropertyDescriptor(document,"currentScript");if(!t&&"currentScript"in document&&document.currentScript)return document.currentScript;if(t&&t.get!==e&&document.currentScript)return document.currentScript;try{throw new Error}catch(d){var n,r,i,a=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,o=/@([^@]*):(\d+):(\d+)\s*$/gi,s=a.exec(d.stack)||o.exec(d.stack),c=s&&s[1]||!1,u=s&&s[2]||!1,l=document.location.href.replace(document.location.hash,""),f=document.getElementsByTagName("script");c===l&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(u-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),i=n.replace(r,"$1").trim());for(var h=0;h<f.length;h++){if("interactive"===f[h].readyState)return f[h];if(f[h].src===c)return f[h];if(c===l&&f[h].innerHTML&&f[h].innerHTML.trim()===i)return f[h]}return null}}return e}))},8883:function(e,t,n){"use strict";var r=n("83ab"),i=n("44d2"),a=n("7b0b"),o=n("07fa"),s=n("9bf2").f;r&&!("lastIndex"in[])&&(s(Array.prototype,"lastIndex",{configurable:!0,get:function(){var e=a(this),t=o(e);return 0==t?0:t-1}}),i("lastIndex"))},8925:function(e,t,n){var r=n("e330"),i=n("1626"),a=n("c6cd"),o=r(Function.toString);i(a.inspectSource)||(a.inspectSource=function(e){return o(e)}),e.exports=a.inspectSource},"8a1a":function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b"),a=n("e330"),o=n("59ed"),s=n("9a1f"),c=n("2266"),u=a([].push);r({target:"Map",stat:!0},{groupBy:function(e,t){o(t);var n=s(e),r=new this,a=o(r.has),l=o(r.get),f=o(r.set);return c(n,(function(e){var n=t(e);i(a,r,n)?u(i(l,r,n),e):i(f,r,n,[e])}),{IS_ITERATOR:!0}),r}})},"8a59":function(e,t,n){var r=n("74e8");r("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}),!0)},"8a79":function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("06cf").f,o=n("50c4"),s=n("577e"),c=n("5a34"),u=n("1d80"),l=n("ab13"),f=n("c430"),h=i("".endsWith),d=i("".slice),p=Math.min,v=l("endsWith"),m=!f&&!v&&!!function(){var e=a(String.prototype,"endsWith");return e&&!e.writable}();r({target:"String",proto:!0,forced:!m&&!v},{endsWith:function(e){var t=s(u(this));c(e);var n=arguments.length>1?arguments[1]:void 0,r=t.length,i=void 0===n?r:p(o(n),r),a=s(e);return h?h(t,a,i):d(t,i-a.length,i)===a}})},"8aa5":function(e,t,n){"use strict";var r=n("6547").charAt;e.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},"8aa7":function(e,t,n){var r=n("da84"),i=n("d039"),a=n("1c7e"),o=n("ebb5").NATIVE_ARRAY_BUFFER_VIEWS,s=r.ArrayBuffer,c=r.Int8Array;e.exports=!o||!i((function(){c(1)}))||!i((function(){new c(-1)}))||!a((function(e){new c,new c(null),new c(1.5),new c(e)}),!0)||i((function(){return 1!==new c(new s(2),1,void 0).length}))},"8b09":function(e,t,n){var r=n("74e8");r("Int16",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},"8b85":function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},"8b9a":function(e,t,n){var r=n("23e7"),i=n("825a"),a=n("3bbe"),o=n("d2bb");o&&r({target:"Reflect",stat:!0},{setPrototypeOf:function(e,t){i(e),a(t);try{return o(e,t),!0}catch(n){return!1}}})},"8ba4":function(e,t,n){var r=n("23e7"),i=n("eac5");r({target:"Number",stat:!0},{isInteger:i})},"8bd4":function(e,t,n){var r=n("d066"),i=n("d44e"),a="DOMException";i(r(a),a)},"8cef":function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.pad.Iso97971={pad:function(t,n){t.concat(e.lib.WordArray.create([2147483648],1)),e.pad.ZeroPadding.pad(t,n)},unpad:function(t){e.pad.ZeroPadding.unpad(t),t.sigBytes--}},e.pad.Iso97971}))},"8df4":function(e,t,n){"use strict";var r=n("7a77");function i(e){if("function"!==typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;this.promise.then((function(e){if(n._listeners){var t,r=n._listeners.length;for(t=0;t<r;t++)n._listeners[t](e);n._listeners=null}})),this.promise.then=function(e){var t,r=new Promise((function(e){n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.prototype.subscribe=function(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]},i.prototype.unsubscribe=function(e){if(this._listeners){var t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}},i.source=function(){var e,t=new i((function(t){e=t}));return{token:t,cancel:e}},e.exports=i},"8eb5":function(e,t){var n=Math.expm1,r=Math.exp;e.exports=!n||n(10)>22025.465794806718||n(10)<22025.465794806718||-2e-17!=n(-2e-17)?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:r(e)-1}:n},"8edd":function(e,t,n){var r=n("746f");r("matchAll")},"8f40":function(e,t,n){n("33d1")},"8fe5":function(e,t,n){n("6c57")},9013:function(e,t,n){"use strict";var r=n("23e7"),i=n("19aa"),a=n("9112"),o=n("1a2d"),s=n("b622"),c=n("a91f"),u=n("c430"),l=s("toStringTag"),f=function(){i(this,c)};f.prototype=c,o(c,l)||a(c,l,"AsyncIterator"),!u&&o(c,"constructor")&&c.constructor!==Object||a(c,"constructor",f),r({global:!0,forced:u},{AsyncIterator:f})},9029:function(e,t,n){"use strict";var r=n("23e7"),i=n("f069"),a=n("e667");r({target:"Promise",stat:!0},{try:function(e){var t=i.f(this),n=a(e);return(n.error?t.reject:t.resolve)(n.value),t.promise}})},"907a":function(e,t,n){"use strict";var r=n("ebb5"),i=n("07fa"),a=n("5926"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("at",(function(e){var t=o(this),n=i(t),r=a(e),s=r>=0?r:n+r;return s<0||s>=n?void 0:t[s]}))},"90d7":function(e,t,n){var r=n("23e7"),i=Math.log,a=Math.LN2;r({target:"Math",stat:!0},{log2:function(e){return i(e)/a}})},"90e3":function(e,t,n){var r=n("e330"),i=0,a=Math.random(),o=r(1..toString);e.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+o(++i+a,36)}},9112:function(e,t,n){var r=n("83ab"),i=n("9bf2"),a=n("5c6c");e.exports=r?function(e,t,n){return i.f(e,t,a(1,n))}:function(e,t,n){return e[t]=n,e}},9129:function(e,t,n){var r=n("23e7");r({target:"Number",stat:!0},{isNaN:function(e){return e!=e}})},9152:function(e,t){
|
|
13
|
+
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
14
|
+
t.read=function(e,t,n,r,i){var a,o,s=8*i-r-1,c=(1<<s)-1,u=c>>1,l=-7,f=n?i-1:0,h=n?-1:1,d=e[t+f];for(f+=h,a=d&(1<<-l)-1,d>>=-l,l+=s;l>0;a=256*a+e[t+f],f+=h,l-=8);for(o=a&(1<<-l)-1,a>>=-l,l+=r;l>0;o=256*o+e[t+f],f+=h,l-=8);if(0===a)a=1-u;else{if(a===c)return o?NaN:1/0*(d?-1:1);o+=Math.pow(2,r),a-=u}return(d?-1:1)*o*Math.pow(2,a-r)},t.write=function(e,t,n,r,i,a){var o,s,c,u=8*a-i-1,l=(1<<u)-1,f=l>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:a-1,p=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,o=l):(o=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-o))<1&&(o--,c*=2),t+=o+f>=1?h/c:h*Math.pow(2,1-f),t*c>=2&&(o++,c/=2),o+f>=l?(s=0,o=l):o+f>=1?(s=(t*c-1)*Math.pow(2,i),o+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),o=0));i>=8;e[n+d]=255&s,d+=p,s/=256,i-=8);for(o=o<<i|s,u+=i;u>0;e[n+d]=255&o,d+=p,o/=256,u-=8);e[n+d-p]|=128*v}},9224:function(e){e.exports=JSON.parse('{"name":"smbcloudsdk_webplayer_openapi","version":"2.0.11","private":true,"scripts":{"serve":"vue-cli-service serve example/server/main.js","local":"vue-cli-service serve example/local/main.js","build":"cross-env BUILD_ENV=SDK vue-cli-service build --target lib --name tums-player src/index.js --dest dist/temp && node build/build.js","build:serve":"vue-cli-service build example/server/main.js --dest dist/tums-player-serve && node build/buildTest.js && node build/copyPublicDemo.js","build:local":"vue-cli-service build example/local/main.js --dest dist/tums-player-serve && node build/buildTest.js && node build/copyPrivateDemo.js","build:webgl":"vue-cli-service build --target lib --name webgl src/player/webglPlayer/webgl.js --dest dist/temp && node build/buildWebgl.js","lint":"vue-cli-service lint"},"dependencies":{"axios":"^0.24.0","core-js":"^3.6.5","crypto-js":"^4.1.1","localforage":"^1.10.0","ts-ebml":"^2.0.2","video.js":"^7.15.4","vue":"^2.6.11","vuedraggable":"^2.24.3"},"devDependencies":{"@vue/cli-plugin-babel":"~4.5.0","@vue/cli-plugin-eslint":"~4.5.0","@vue/cli-service":"~4.5.0","add-asset-html-webpack-plugin":"^3.2.0","babel-eslint":"^10.1.0","copy-webpack-plugin":"^5.1.1","cross-env":"^7.0.3","eslint":"^6.7.2","eslint-config-standard":"^16.0.3","eslint-plugin-vue":"^6.2.2","html-webpack-plugin":"^3.2.0","sass":"^1.53.0","sass-loader":"^7.3.0","vconsole":"^3.15.0","vue-template-compiler":"^2.6.11","worker-loader":"^3.0.8"},"eslintConfig":{"root":true,"env":{"node":true},"extends":["plugin:vue/essential","eslint:recommended"],"parserOptions":{"parser":"babel-eslint"},"rules":{}},"browserslist":["> 1%","last 2 versions","not dead"]}')},9257:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("577e"),o=String.fromCharCode,s=i("".charAt),c=i(/./.exec),u=i("".slice),l=/^[\da-f]{2}$/i,f=/^[\da-f]{4}$/i;r({global:!0},{unescape:function(e){var t,n,r=a(e),i="",h=r.length,d=0;while(d<h){if(t=s(r,d++),"%"===t)if("u"===s(r,d)){if(n=u(r,d+1,d+5),c(f,n)){i+=o(parseInt(n,16)),d+=5;continue}}else if(n=u(r,d,d+2),c(l,n)){i+=o(parseInt(n,16)),d+=2;continue}i+=t}return i}})},9263:function(e,t,n){"use strict";var r=n("c65b"),i=n("e330"),a=n("577e"),o=n("ad6d"),s=n("9f7f"),c=n("5692"),u=n("7c73"),l=n("69f3").get,f=n("fce3"),h=n("107c"),d=c("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,v=p,m=i("".charAt),y=i("".indexOf),g=i("".replace),b=i("".slice),T=function(){var e=/a/,t=/b*/g;return r(p,e,"a"),r(p,t,"a"),0!==e.lastIndex||0!==t.lastIndex}(),S=s.BROKEN_CARET,E=void 0!==/()??/.exec("")[1],_=T||E||S||f||h;_&&(v=function(e){var t,n,i,s,c,f,h,_=this,k=l(_),w=a(e),A=k.raw;if(A)return A.lastIndex=_.lastIndex,t=r(v,A,w),_.lastIndex=A.lastIndex,t;var R=k.groups,x=S&&_.sticky,C=r(o,_),I=_.source,P=0,O=w;if(x&&(C=g(C,"y",""),-1===y(C,"g")&&(C+="g"),O=b(w,_.lastIndex),_.lastIndex>0&&(!_.multiline||_.multiline&&"\n"!==m(w,_.lastIndex-1))&&(I="(?: "+I+")",O=" "+O,P++),n=new RegExp("^(?:"+I+")",C)),E&&(n=new RegExp("^"+I+"$(?!\\s)",C)),T&&(i=_.lastIndex),s=r(p,x?n:_,O),x?s?(s.input=b(s.input,P),s[0]=b(s[0],P),s.index=_.lastIndex,_.lastIndex+=s[0].length):_.lastIndex=0:T&&s&&(_.lastIndex=_.global?s.index+s[0].length:i),E&&s&&s.length>1&&r(d,s[0],n,(function(){for(c=1;c<arguments.length-2;c++)void 0===arguments[c]&&(s[c]=void 0)})),s&&R)for(s.groups=f=u(null),c=0;c<R.length;c++)h=R[c],f[h[0]]=s[h[1]];return s}),e.exports=v},9321:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("5926"),o=Date.prototype,s=i(o.getTime),c=i(o.setFullYear);r({target:"Date",proto:!0},{setYear:function(e){s(this);var t=a(e),n=0<=t&&t<=99?t+1900:t;return c(this,n)}})},9446:function(e,t,n){n("a4d3"),n("e01a"),n("b636"),n("dc8d"),n("efe9"),n("d28b"),n("2a1b"),n("8edd"),n("80e0"),n("6b9e"),n("197b"),n("2351"),n("8172"),n("944a"),n("81b8"),n("d9e2"),n("d401"),n("967a"),n("9fbf"),n("33d1"),n("99af"),n("a874"),n("a623"),n("cb29"),n("4de4"),n("7db0"),n("c740"),n("0481"),n("5db7"),n("4160"),n("a630"),n("caad"),n("c975"),n("277d"),n("e260"),n("a15b"),n("baa5"),n("d81d"),n("5ded"),n("13d5"),n("f4dd"),n("26e9"),n("fb6a"),n("45fc"),n("4e82"),n("f785"),n("a434"),n("4069"),n("73d9"),n("c19f"),n("82da"),n("ace4"),n("b420"),n("0a90"),n("6eba"),n("9321"),n("d1ba"),n("accc"),n("f4b3"),n("efec"),n("0d03"),n("4d12"),n("c0b6"),n("b56e"),n("b0c0"),n("6c57"),n("e9c4"),n("0c47"),n("4ec9"),n("5327"),n("79a8"),n("9ff9"),n("3ea3"),n("40d9"),n("ff9c"),n("0ac8"),n("f664"),n("4057"),n("bc01"),n("6b93"),n("ca21"),n("90d7"),n("2af1"),n("0261"),n("7898"),n("23dc"),n("b65f"),n("a9e3"),n("35b3"),n("f00c"),n("8ba4"),n("9129"),n("583b"),n("aff5"),n("e6e1"),n("c35a"),n("25eb"),n("a3a2"),n("b680"),n("542d"),n("cca6"),n("b8bf"),n("12a8"),n("1d1c"),n("7a82"),n("e71b"),n("4fadc"),n("dca8"),n("c1f9"),n("e439"),n("dbb4"),n("7039"),n("3410"),n("0541"),n("2b19"),n("c906"),n("e21d"),n("e43e"),n("b64b"),n("bf96"),n("5bf7"),n("cee8"),n("af93"),n("131a"),n("d3b7"),n("07ac"),n("acd8"),n("e25e"),n("e6cf"),n("820e"),n("dbfa"),n("a79d"),n("a6fd"),n("4ae1"),n("3f3a"),n("ac16"),n("5d41"),n("9e4a"),n("7f78"),n("c760"),n("db96"),n("1bf2"),n("d6dd"),n("7ed3"),n("8b9a"),n("f8c9"),n("4d63"),n("c607"),n("ac1f"),n("5377"),n("2c3e"),n("00b4"),n("25f0"),n("6062"),n("ea98"),n("f5b2"),n("8a79"),n("f6d6"),n("2532"),n("3ca3"),n("466d"),n("a1f0"),n("843c"),n("4d90"),n("d80f"),n("38cf"),n("5319"),n("5b81"),n("841c"),n("1276"),n("2ca0"),n("e323"),n("498a"),n("1e25"),n("eee7"),n("18a5"),n("1393"),n("04d3"),n("cc71"),n("c7cd"),n("9767"),n("1913"),n("c5d0"),n("9911"),n("c96a"),n("2315"),n("4c53"),n("664f"),n("cfc3"),n("4a9b"),n("fd87"),n("8b09"),n("143c"),n("5cc6"),n("8a59"),n("84c3"),n("fb2c"),n("907a"),n("9a8c"),n("a975"),n("735e"),n("c1ac"),n("d139"),n("3a7b"),n("d5d6"),n("20bf"),n("82f8"),n("e91f"),n("60bd"),n("5f96"),n("3280"),n("3fcc"),n("ec97"),n("ca91"),n("25a1"),n("cd26"),n("3c5d"),n("2954"),n("649e"),n("219c"),n("170b"),n("b39a"),n("72f7"),n("9257"),n("10d1"),n("1fe2"),n("eba5"),n("3ff8"),n("8f40"),n("54c8"),n("34a3"),n("c2bc"),n("dc56"),n("83f2"),n("b38e"),n("83e6"),n("8883"),n("dad3"),n("978f"),n("6720"),n("72ba"),n("143e"),n("6d54"),n("9013"),n("dab0"),n("0ce4"),n("f93b"),n("ddd7"),n("f646"),n("45e3"),n("26ad"),n("7245"),n("7b8b"),n("8260"),n("1d10"),n("660e"),n("1b22"),n("dfa4"),n("8182"),n("1034"),n("e74c"),n("7a5b"),n("b2ff"),n("8fe5"),n("0643"),n("b24c"),n("ab3c"),n("76d6"),n("2382"),n("fffc"),n("cd1a"),n("4e3e"),n("a093"),n("a573"),n("9d4a"),n("9a9a"),n("4417"),n("cbc8"),n("39c3"),n("c206"),n("bffa"),n("477f"),n("97fb"),n("d2af"),n("9f9a"),n("ceef"),n("8a1a"),n("43b3"),n("ba74"),n("567a"),n("9c87"),n("094c"),n("a9cd"),n("e7dd"),n("54ec"),n("4e16"),n("f43e"),n("b423"),n("b881"),n("70e3"),n("bdd4"),n("2abc"),n("48be"),n("95e8"),n("78ed"),n("36a4"),n("c3bb"),n("b968"),n("58fc"),n("355d"),n("9f2f"),n("6b9f"),n("bf3c"),n("3393"),n("daf2"),n("ce8c"),n("c877"),n("a454"),n("a5eb"),n("f20a"),n("0ebb"),n("9029"),n("fbec"),n("6380"),n("66c1"),n("bd98"),n("e6bd"),n("b10f"),n("6dd7"),n("0308"),n("aa01"),n("e3df"),n("015a"),n("85ca"),n("74d4"),n("dee5"),n("b628"),n("d644"),n("658e"),n("0b52"),n("9661"),n("0a8d"),n("e495"),n("72d0"),n("f2be"),n("2705"),n("a9a1"),n("4a2e"),n("0466"),n("7cdf"),n("802d"),n("5333"),n("0e13"),n("ad9d"),n("a7f4"),n("6a90"),n("020f"),n("e8eb"),n("e176"),n("e95e"),n("8009"),n("18d5"),n("acef"),n("a529"),n("6899"),n("fa9e"),n("77d9"),n("cd7c"),n("1b3b"),n("3d71"),n("5dfc"),n("6a86"),n("c6e3"),n("71f8"),n("ef4d"),n("4c9e"),n("9e6b"),n("e555"),n("6789"),n("f124"),n("b294"),n("adbd"),n("159b"),n("ddb0"),n("0eb6"),n("b7ef"),n("8bd4"),n("130f"),n("9f96"),n("ad1f"),n("4795"),n("2b3d"),n("bf19"),n("9861"),e.exports=n("428f")},"944a":function(e,t,n){var r=n("746f");r("toStringTag")},"94ca":function(e,t,n){var r=n("d039"),i=n("1626"),a=/#|\.prototype\./,o=function(e,t){var n=c[s(e)];return n==l||n!=u&&(i(t)?r(t):!!t)},s=o.normalize=function(e){return String(e).replace(a,".").toLowerCase()},c=o.data={},u=o.NATIVE="N",l=o.POLYFILL="P";e.exports=o},"94f8":function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(t){var n=e,r=n.lib,i=r.WordArray,a=r.Hasher,o=n.algo,s=[],c=[];(function(){function e(e){for(var n=t.sqrt(e),r=2;r<=n;r++)if(!(e%r))return!1;return!0}function n(e){return 4294967296*(e-(0|e))|0}var r=2,i=0;while(i<64)e(r)&&(i<8&&(s[i]=n(t.pow(r,.5))),c[i]=n(t.pow(r,1/3)),i++),r++})();var u=[],l=o.SHA256=a.extend({_doReset:function(){this._hash=new i.init(s.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],l=n[5],f=n[6],h=n[7],d=0;d<64;d++){if(d<16)u[d]=0|e[t+d];else{var p=u[d-15],v=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,m=u[d-2],y=(m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10;u[d]=v+u[d-7]+y+u[d-16]}var g=s&l^~s&f,b=r&i^r&a^i&a,T=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),S=(s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25),E=h+S+g+c[d]+u[d],_=T+b;h=f,f=l,l=s,s=o+E|0,o=a,a=i,i=r,r=E+_|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+a|0,n[3]=n[3]+o|0,n[4]=n[4]+s|0,n[5]=n[5]+l|0,n[6]=n[6]+f|0,n[7]=n[7]+h|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;return n[i>>>5]|=128<<24-i%32,n[14+(i+64>>>9<<4)]=t.floor(r/4294967296),n[15+(i+64>>>9<<4)]=r,e.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}});n.SHA256=a._createHelper(l),n.HmacSHA256=a._createHmacHelper(l)}(Math),e.SHA256}))},"95e8":function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{iaddh:function(e,t,n,r){var i=e>>>0,a=t>>>0,o=n>>>0;return a+(r>>>0)+((i&o|(i|o)&~(i+o>>>0))>>>31)|0}})},9661:function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("c65b"),s=n("59ed"),c=n("1626"),u=n("825a"),l=n("9a1f"),f=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{isSubsetOf:function(e){var t=l(this),n=u(e),r=n.has;return c(r)||(n=new(a("Set"))(e),r=s(n.has)),!f(t,(function(e,t){if(!1===o(r,n,e))return t()}),{IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},"967a":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("3a9b"),o=n("e163"),s=n("d2bb"),c=n("e893"),u=n("7c73"),l=n("9112"),f=n("5c6c"),h=n("c770"),d=n("ab36"),p=n("2266"),v=n("e391"),m=n("b622"),y=n("b980"),g=m("toStringTag"),b=i.Error,T=[].push,S=function(e,t){var n,r=arguments.length>2?arguments[2]:void 0,i=a(E,this);s?n=s(new b,i?o(this):E):(n=i?this:u(E),l(n,g,"Error")),void 0!==t&&l(n,"message",v(t)),y&&l(n,"stack",h(n.stack,1)),d(n,r);var c=[];return p(e,T,{that:c}),l(n,"errors",c),n};s?s(S,b):c(S,b,{name:!0});var E=S.prototype=u(b.prototype,{constructor:f(1,S),message:f(1,""),name:f(1,"AggregateError")});r({global:!0},{AggregateError:S})},"96cf":function(e,t,n){var r=function(e){"use strict";var t,n=Object.prototype,r=n.hasOwnProperty,i="function"===typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",o=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(O){c=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var i=t&&t.prototype instanceof m?t:m,a=Object.create(i.prototype),o=new C(r||[]);return a._invoke=w(e,n,o),a}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(O){return{type:"throw",arg:O}}}e.wrap=u;var f="suspendedStart",h="suspendedYield",d="executing",p="completed",v={};function m(){}function y(){}function g(){}var b={};c(b,a,(function(){return this}));var T=Object.getPrototypeOf,S=T&&T(T(I([])));S&&S!==n&&r.call(S,a)&&(b=S);var E=g.prototype=m.prototype=Object.create(b);function _(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function n(i,a,o,s){var c=l(e[i],e,a);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"===typeof f&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,o,s)}),(function(e){n("throw",e,o,s)})):t.resolve(f).then((function(e){u.value=e,o(u)}),(function(e){return n("throw",e,o,s)}))}s(c.arg)}var i;function a(e,r){function a(){return new t((function(t,i){n(e,r,t,i)}))}return i=i?i.then(a,a):a()}this._invoke=a}function w(e,t,n){var r=f;return function(i,a){if(r===d)throw new Error("Generator is already running");if(r===p){if("throw"===i)throw a;return P()}n.method=i,n.arg=a;while(1){var o=n.delegate;if(o){var s=A(o,n);if(s){if(s===v)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===f)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=d;var c=l(e,t,n);if("normal"===c.type){if(r=n.done?p:h,c.arg===v)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r=p,n.method="throw",n.arg=c.arg)}}}function A(e,n){var r=e.iterator[n.method];if(r===t){if(n.delegate=null,"throw"===n.method){if(e.iterator["return"]&&(n.method="return",n.arg=t,A(e,n),"throw"===n.method))return v;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var i=l(r,e.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,v;var a=i.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,v):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,v)}function R(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function x(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function C(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(R,this),this.reset(!0)}function I(e){if(e){var n=e[a];if(n)return n.call(e);if("function"===typeof e.next)return e;if(!isNaN(e.length)){var i=-1,o=function n(){while(++i<e.length)if(r.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return o.next=o}}return{next:P}}function P(){return{value:t,done:!0}}return y.prototype=g,c(E,"constructor",g),c(g,"constructor",y),y.displayName=c(g,s,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"===typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,g):(e.__proto__=g,c(e,s,"GeneratorFunction")),e.prototype=Object.create(E),e},e.awrap=function(e){return{__await:e}},_(k.prototype),c(k.prototype,o,(function(){return this})),e.AsyncIterator=k,e.async=function(t,n,r,i,a){void 0===a&&(a=Promise);var o=new k(u(t,n,r,i),a);return e.isGeneratorFunction(n)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},_(E),c(E,s,"Generator"),c(E,a,(function(){return this})),c(E,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){while(t.length){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=I,C.prototype={constructor:C,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(x),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0],t=e.completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function i(r,i){return s.type="throw",s.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],s=o.completion;if("root"===o.tryLoc)return i("end");if(o.tryLoc<=this.prev){var c=r.call(o,"catchLoc"),u=r.call(o,"finallyLoc");if(c&&u){if(this.prev<o.catchLoc)return i(o.catchLoc,!0);if(this.prev<o.finallyLoc)return i(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return i(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return i(o.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var o=a?a.completion:{};return o.type=e,o.arg=t,a?(this.method="next",this.next=a.finallyLoc,v):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),x(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;x(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:I(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),v}},e}(e.exports);try{regeneratorRuntime=r}catch(i){"object"===typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},9767:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("fontcolor")},{fontcolor:function(e){return i(this,"font","color",e)}})},"978f":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("df7e"),o=n("fc6a"),s=n("44d2"),c=i.Array;r({target:"Array",proto:!0},{toReversed:function(){return a(o(this),c)}}),s("toReversed")},"97fb":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("0366"),s=n("c65b"),c=n("59ed"),u=n("825a"),l=n("4840"),f=n("4acb"),h=n("2266");i({target:"Map",proto:!0,real:!0,forced:r},{filter:function(e){var t=u(this),n=f(t),r=o(e,arguments.length>1?arguments[1]:void 0),i=new(l(t,a("Map"))),d=c(i.set);return h(n,(function(e,n){r(n,e,t)&&s(d,i,e,n)}),{AS_ENTRIES:!0,IS_ITERATOR:!0}),i}})},9861:function(e,t,n){"use strict";n("e260");var r=n("23e7"),i=n("da84"),a=n("d066"),o=n("c65b"),s=n("e330"),c=n("0d3b"),u=n("6eeb"),l=n("e2cc"),f=n("d44e"),h=n("9ed3"),d=n("69f3"),p=n("19aa"),v=n("1626"),m=n("1a2d"),y=n("0366"),g=n("f5df"),b=n("825a"),T=n("861d"),S=n("577e"),E=n("7c73"),_=n("5c6c"),k=n("9a1f"),w=n("35a1"),A=n("d6d6"),R=n("b622"),x=n("addb"),C=R("iterator"),I="URLSearchParams",P=I+"Iterator",O=d.set,D=d.getterFor(I),U=d.getterFor(P),M=a("fetch"),B=a("Request"),N=a("Headers"),L=B&&B.prototype,F=N&&N.prototype,j=i.RegExp,W=i.TypeError,H=i.decodeURIComponent,V=i.encodeURIComponent,q=s("".charAt),z=s([].join),G=s([].push),Y=s("".replace),K=s([].shift),X=s([].splice),Q=s("".split),$=s("".slice),Z=/\+/g,J=Array(4),ee=function(e){return J[e-1]||(J[e-1]=j("((?:%[\\da-f]{2}){"+e+"})","gi"))},te=function(e){try{return H(e)}catch(t){return e}},ne=function(e){var t=Y(e,Z," "),n=4;try{return H(t)}catch(r){while(n)t=Y(t,ee(n--),te);return t}},re=/[!'()~]|%20/g,ie={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},ae=function(e){return ie[e]},oe=function(e){return Y(V(e),re,ae)},se=h((function(e,t){O(this,{type:P,iterator:k(D(e).entries),kind:t})}),"Iterator",(function(){var e=U(this),t=e.kind,n=e.iterator.next(),r=n.value;return n.done||(n.value="keys"===t?r.key:"values"===t?r.value:[r.key,r.value]),n}),!0),ce=function(e){this.entries=[],this.url=null,void 0!==e&&(T(e)?this.parseObject(e):this.parseQuery("string"==typeof e?"?"===q(e,0)?$(e,1):e:S(e)))};ce.prototype={type:I,bindURL:function(e){this.url=e,this.update()},parseObject:function(e){var t,n,r,i,a,s,c,u=w(e);if(u){t=k(e,u),n=t.next;while(!(r=o(n,t)).done){if(i=k(b(r.value)),a=i.next,(s=o(a,i)).done||(c=o(a,i)).done||!o(a,i).done)throw W("Expected sequence with length 2");G(this.entries,{key:S(s.value),value:S(c.value)})}}else for(var l in e)m(e,l)&&G(this.entries,{key:l,value:S(e[l])})},parseQuery:function(e){if(e){var t,n,r=Q(e,"&"),i=0;while(i<r.length)t=r[i++],t.length&&(n=Q(t,"="),G(this.entries,{key:ne(K(n)),value:ne(z(n,"="))}))}},serialize:function(){var e,t=this.entries,n=[],r=0;while(r<t.length)e=t[r++],G(n,oe(e.key)+"="+oe(e.value));return z(n,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var ue=function(){p(this,le);var e=arguments.length>0?arguments[0]:void 0;O(this,new ce(e))},le=ue.prototype;if(l(le,{append:function(e,t){A(arguments.length,2);var n=D(this);G(n.entries,{key:S(e),value:S(t)}),n.updateURL()},delete:function(e){A(arguments.length,1);var t=D(this),n=t.entries,r=S(e),i=0;while(i<n.length)n[i].key===r?X(n,i,1):i++;t.updateURL()},get:function(e){A(arguments.length,1);for(var t=D(this).entries,n=S(e),r=0;r<t.length;r++)if(t[r].key===n)return t[r].value;return null},getAll:function(e){A(arguments.length,1);for(var t=D(this).entries,n=S(e),r=[],i=0;i<t.length;i++)t[i].key===n&&G(r,t[i].value);return r},has:function(e){A(arguments.length,1);var t=D(this).entries,n=S(e),r=0;while(r<t.length)if(t[r++].key===n)return!0;return!1},set:function(e,t){A(arguments.length,1);for(var n,r=D(this),i=r.entries,a=!1,o=S(e),s=S(t),c=0;c<i.length;c++)n=i[c],n.key===o&&(a?X(i,c--,1):(a=!0,n.value=s));a||G(i,{key:o,value:s}),r.updateURL()},sort:function(){var e=D(this);x(e.entries,(function(e,t){return e.key>t.key?1:-1})),e.updateURL()},forEach:function(e){var t,n=D(this).entries,r=y(e,arguments.length>1?arguments[1]:void 0),i=0;while(i<n.length)t=n[i++],r(t.value,t.key,this)},keys:function(){return new se(this,"keys")},values:function(){return new se(this,"values")},entries:function(){return new se(this,"entries")}},{enumerable:!0}),u(le,C,le.entries,{name:"entries"}),u(le,"toString",(function(){return D(this).serialize()}),{enumerable:!0}),f(ue,I),r({global:!0,forced:!c},{URLSearchParams:ue}),!c&&v(N)){var fe=s(F.has),he=s(F.set),de=function(e){if(T(e)){var t,n=e.body;if(g(n)===I)return t=e.headers?new N(e.headers):new N,fe(t,"content-type")||he(t,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),E(e,{body:_(0,S(n)),headers:_(0,t)})}return e};if(v(M)&&r({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return M(e,arguments.length>1?de(arguments[1]):{})}}),v(B)){var pe=function(e){return p(this,L),new B(e,arguments.length>1?de(arguments[1]):{})};L.constructor=pe,pe.prototype=L,r({global:!0,forced:!0},{Request:pe})}}e.exports={URLSearchParams:ue,getState:D}},9911:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("link")},{link:function(e){return i(this,"a","href",e)}})},"99af":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("d039"),o=n("e8b5"),s=n("861d"),c=n("7b0b"),u=n("07fa"),l=n("8418"),f=n("65f0"),h=n("1dde"),d=n("b622"),p=n("2d00"),v=d("isConcatSpreadable"),m=9007199254740991,y="Maximum allowed index exceeded",g=i.TypeError,b=p>=51||!a((function(){var e=[];return e[v]=!1,e.concat()[0]!==e})),T=h("concat"),S=function(e){if(!s(e))return!1;var t=e[v];return void 0!==t?!!t:o(e)},E=!b||!T;r({target:"Array",proto:!0,forced:E},{concat:function(e){var t,n,r,i,a,o=c(this),s=f(o,0),h=0;for(t=-1,r=arguments.length;t<r;t++)if(a=-1===t?o:arguments[t],S(a)){if(i=u(a),h+i>m)throw g(y);for(n=0;n<i;n++,h++)n in a&&l(s,h,a[n])}else{if(h>=m)throw g(y);l(s,h++,a)}return s.length=h,s}})},"9a0c":function(e,t,n){var r=n("342f");e.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(r)},"9a1f":function(e,t,n){var r=n("da84"),i=n("c65b"),a=n("59ed"),o=n("825a"),s=n("0d51"),c=n("35a1"),u=r.TypeError;e.exports=function(e,t){var n=arguments.length<2?c(e):t;if(a(n))return o(i(n,e));throw u(s(e)+" is not iterable")}},"9a8c":function(e,t,n){"use strict";var r=n("e330"),i=n("ebb5"),a=n("145e"),o=r(a),s=i.aTypedArray,c=i.exportTypedArrayMethod;c("copyWithin",(function(e,t){return o(s(this),e,t,arguments.length>2?arguments[2]:void 0)}))},"9a9a":function(e,t,n){"use strict";var r=n("23e7"),i=n("2266"),a=n("59ed"),o=n("825a");r({target:"Iterator",proto:!0,real:!0},{some:function(e){return o(this),a(e),i(this,(function(t,n){if(e(t))return n()}),{IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},"9bdd":function(e,t,n){var r=n("825a"),i=n("2a62");e.exports=function(e,t,n,a){try{return a?t(r(n)[0],n[1]):t(n)}catch(o){i(e,"throw",o)}}},"9bf2":function(e,t,n){var r=n("da84"),i=n("83ab"),a=n("0cfb"),o=n("aed9"),s=n("825a"),c=n("a04b"),u=r.TypeError,l=Object.defineProperty,f=Object.getOwnPropertyDescriptor,h="enumerable",d="configurable",p="writable";t.f=i?o?function(e,t,n){if(s(e),t=c(t),s(n),"function"===typeof e&&"prototype"===t&&"value"in n&&p in n&&!n[p]){var r=f(e,t);r&&r[p]&&(e[t]=n.value,n={configurable:d in n?n[d]:r[d],enumerable:h in n?n[h]:r[h],writable:!1})}return l(e,t,n)}:l:function(e,t,n){if(s(e),t=c(t),s(n),a)try{return l(e,t,n)}catch(r){}if("get"in n||"set"in n)throw u("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},"9c87":function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("0366"),s=n("c65b"),c=n("59ed"),u=n("825a"),l=n("4840"),f=n("4acb"),h=n("2266");i({target:"Map",proto:!0,real:!0,forced:r},{mapKeys:function(e){var t=u(this),n=f(t),r=o(e,arguments.length>1?arguments[1]:void 0),i=new(l(t,a("Map"))),d=c(i.set);return h(n,(function(e,n){s(d,i,r(n,e,t),n)}),{AS_ENTRIES:!0,IS_ITERATOR:!0}),i}})},"9d4a":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("2266"),o=n("59ed"),s=n("825a"),c=i.TypeError;r({target:"Iterator",proto:!0,real:!0},{reduce:function(e){s(this),o(e);var t=arguments.length<2,n=t?void 0:arguments[1];if(a(this,(function(r){t?(t=!1,n=r):n=e(n,r)}),{IS_ITERATOR:!0}),t)throw c("Reduce of empty iterator with no initial value");return n}})},"9e4a":function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("825a"),o=n("06cf");r({target:"Reflect",stat:!0,sham:!i},{getOwnPropertyDescriptor:function(e,t){return o.f(a(e),t)}})},"9e6b":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("2713");r({target:"WeakMap",proto:!0,real:!0,forced:i},{emplace:a})},"9ed3":function(e,t,n){"use strict";var r=n("ae93").IteratorPrototype,i=n("7c73"),a=n("5c6c"),o=n("d44e"),s=n("3f8c"),c=function(){return this};e.exports=function(e,t,n,u){var l=t+" Iterator";return e.prototype=i(r,{next:a(+!u,n)}),o(e,l,!1,!0),s[l]=c,e}},"9f2f":function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{signbit:function(e){return(e=+e)==e&&0==e?1/e==-1/0:e<0}})},"9f7f":function(e,t,n){var r=n("d039"),i=n("da84"),a=i.RegExp,o=r((function(){var e=a("a","y");return e.lastIndex=2,null!=e.exec("abcd")})),s=o||r((function(){return!a("a","y").sticky})),c=o||r((function(){var e=a("^r","gy");return e.lastIndex=2,null!=e.exec("str")}));e.exports={BROKEN_CARET:c,MISSED_STICKY:s,UNSUPPORTED_Y:o}},"9f96":function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("b575"),o=n("605d"),s=i.process;r({global:!0,enumerable:!0,noTargetGet:!0},{queueMicrotask:function(e){var t=o&&s.domain;a(t?t.bind(e):e)}})},"9f9a":function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("4acb"),c=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{findKey:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return c(n,(function(e,n,i){if(r(n,e,t))return i(e)}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).result}})},"9fbf":function(e,t,n){var r=n("23e7"),i=n("d066"),a=n("2ba4"),o=n("d039"),s=n("e5cb"),c="AggregateError",u=i(c),l=!o((function(){return 1!==u([1]).errors[0]}))&&o((function(){return 7!==u([1],c,{cause:7}).cause}));r({global:!0,forced:l},{AggregateError:s(c,(function(e){return function(t,n){return a(e,this,arguments)}}),l,!0)})},"9ff9":function(e,t,n){var r=n("23e7"),i=Math.atanh,a=Math.log;r({target:"Math",stat:!0,forced:!(i&&1/i(-0)<0)},{atanh:function(e){return 0==(e=+e)?e:a((1+e)/(1-e))/2}})},a002:function(e,t,n){(function(t){var n;
|
|
15
|
+
/*!
|
|
16
|
+
localForage -- Offline Storage, Improved
|
|
17
|
+
Version 1.10.0
|
|
18
|
+
https://localforage.github.io/localForage
|
|
19
|
+
(c) 2013-2017 Mozilla, Apache License 2.0
|
|
20
|
+
*/
|
|
21
|
+
(function(t){e.exports=t()})((function(){return function e(t,r,i){function a(s,c){if(!r[s]){if(!t[s]){var u="function"==typeof n&&n;if(!c&&u)return n(s,!0);if(o)return o(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var f=r[s]={exports:{}};t[s][0].call(f.exports,(function(e){var n=t[s][1][e];return a(n||e)}),f,f.exports,e,t,r,i)}return r[s].exports}for(var o="function"==typeof n&&n,s=0;s<i.length;s++)a(i[s]);return a}({1:[function(e,n,r){(function(e){"use strict";var t,r,i=e.MutationObserver||e.WebKitMutationObserver;if(i){var a=0,o=new i(l),s=e.document.createTextNode("");o.observe(s,{characterData:!0}),t=function(){s.data=a=++a%2}}else if(e.setImmediate||"undefined"===typeof e.MessageChannel)t="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){l(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(l,0)};else{var c=new e.MessageChannel;c.port1.onmessage=l,t=function(){c.port2.postMessage(0)}}var u=[];function l(){var e,t;r=!0;var n=u.length;while(n){t=u,u=[],e=-1;while(++e<n)t[e]();n=u.length}r=!1}function f(e){1!==u.push(e)||r||t()}n.exports=f}).call(this,"undefined"!==typeof t?t:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{}],2:[function(e,t,n){"use strict";var r=e(1);function i(){}var a={},o=["REJECTED"],s=["FULFILLED"],c=["PENDING"];function u(e){if("function"!==typeof e)throw new TypeError("resolver must be a function");this.state=c,this.queue=[],this.outcome=void 0,e!==i&&d(this,e)}function l(e,t,n){this.promise=e,"function"===typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"===typeof n&&(this.onRejected=n,this.callRejected=this.otherCallRejected)}function f(e,t,n){r((function(){var r;try{r=t(n)}catch(i){return a.reject(e,i)}r===e?a.reject(e,new TypeError("Cannot resolve promise with itself")):a.resolve(e,r)}))}function h(e){var t=e&&e.then;if(e&&("object"===typeof e||"function"===typeof e)&&"function"===typeof t)return function(){t.apply(e,arguments)}}function d(e,t){var n=!1;function r(t){n||(n=!0,a.reject(e,t))}function i(t){n||(n=!0,a.resolve(e,t))}function o(){t(i,r)}var s=p(o);"error"===s.status&&r(s.value)}function p(e,t){var n={};try{n.value=e(t),n.status="success"}catch(r){n.status="error",n.value=r}return n}function v(e){return e instanceof this?e:a.resolve(new this(i),e)}function m(e){var t=new this(i);return a.reject(t,e)}function y(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);var o=new Array(n),s=0,c=-1,u=new this(i);while(++c<n)l(e[c],c);return u;function l(e,i){function c(e){o[i]=e,++s!==n||r||(r=!0,a.resolve(u,o))}t.resolve(e).then(c,(function(e){r||(r=!0,a.reject(u,e))}))}}function g(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);var o=-1,s=new this(i);while(++o<n)c(e[o]);return s;function c(e){t.resolve(e).then((function(e){r||(r=!0,a.resolve(s,e))}),(function(e){r||(r=!0,a.reject(s,e))}))}}t.exports=u,u.prototype["catch"]=function(e){return this.then(null,e)},u.prototype.then=function(e,t){if("function"!==typeof e&&this.state===s||"function"!==typeof t&&this.state===o)return this;var n=new this.constructor(i);if(this.state!==c){var r=this.state===s?e:t;f(n,r,this.outcome)}else this.queue.push(new l(n,e,t));return n},l.prototype.callFulfilled=function(e){a.resolve(this.promise,e)},l.prototype.otherCallFulfilled=function(e){f(this.promise,this.onFulfilled,e)},l.prototype.callRejected=function(e){a.reject(this.promise,e)},l.prototype.otherCallRejected=function(e){f(this.promise,this.onRejected,e)},a.resolve=function(e,t){var n=p(h,t);if("error"===n.status)return a.reject(e,n.value);var r=n.value;if(r)d(e,r);else{e.state=s,e.outcome=t;var i=-1,o=e.queue.length;while(++i<o)e.queue[i].callFulfilled(t)}return e},a.reject=function(e,t){e.state=o,e.outcome=t;var n=-1,r=e.queue.length;while(++n<r)e.queue[n].callRejected(t);return e},u.resolve=v,u.reject=m,u.all=y,u.race=g},{1:1}],3:[function(e,n,r){(function(t){"use strict";"function"!==typeof t.Promise&&(t.Promise=e(2))}).call(this,"undefined"!==typeof t?t:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{2:2}],4:[function(e,t,n){"use strict";var r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(){try{if("undefined"!==typeof indexedDB)return indexedDB;if("undefined"!==typeof webkitIndexedDB)return webkitIndexedDB;if("undefined"!==typeof mozIndexedDB)return mozIndexedDB;if("undefined"!==typeof OIndexedDB)return OIndexedDB;if("undefined"!==typeof msIndexedDB)return msIndexedDB}catch(e){return}}var o=a();function s(){try{if(!o||!o.open)return!1;var e="undefined"!==typeof openDatabase&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),t="function"===typeof fetch&&-1!==fetch.toString().indexOf("[native code");return(!e||t)&&"undefined"!==typeof indexedDB&&"undefined"!==typeof IDBKeyRange}catch(n){return!1}}function c(e,t){e=e||[],t=t||{};try{return new Blob(e,t)}catch(a){if("TypeError"!==a.name)throw a;for(var n="undefined"!==typeof BlobBuilder?BlobBuilder:"undefined"!==typeof MSBlobBuilder?MSBlobBuilder:"undefined"!==typeof MozBlobBuilder?MozBlobBuilder:WebKitBlobBuilder,r=new n,i=0;i<e.length;i+=1)r.append(e[i]);return r.getBlob(t.type)}}"undefined"===typeof Promise&&e(3);var u=Promise;function l(e,t){t&&e.then((function(e){t(null,e)}),(function(e){t(e)}))}function f(e,t,n){"function"===typeof t&&e.then(t),"function"===typeof n&&e["catch"](n)}function h(e){return"string"!==typeof e&&(console.warn(e+" used as a key, but it is not a string."),e=String(e)),e}function d(){if(arguments.length&&"function"===typeof arguments[arguments.length-1])return arguments[arguments.length-1]}var p="local-forage-detect-blob-support",v=void 0,m={},y=Object.prototype.toString,g="readonly",b="readwrite";function T(e){for(var t=e.length,n=new ArrayBuffer(t),r=new Uint8Array(n),i=0;i<t;i++)r[i]=e.charCodeAt(i);return n}function S(e){return new u((function(t){var n=e.transaction(p,b),r=c([""]);n.objectStore(p).put(r,"key"),n.onabort=function(e){e.preventDefault(),e.stopPropagation(),t(!1)},n.oncomplete=function(){var e=navigator.userAgent.match(/Chrome\/(\d+)/),n=navigator.userAgent.match(/Edge\//);t(n||!e||parseInt(e[1],10)>=43)}}))["catch"]((function(){return!1}))}function E(e){return"boolean"===typeof v?u.resolve(v):S(e).then((function(e){return v=e,v}))}function _(e){var t=m[e.name],n={};n.promise=new u((function(e,t){n.resolve=e,n.reject=t})),t.deferredOperations.push(n),t.dbReady?t.dbReady=t.dbReady.then((function(){return n.promise})):t.dbReady=n.promise}function k(e){var t=m[e.name],n=t.deferredOperations.pop();if(n)return n.resolve(),n.promise}function w(e,t){var n=m[e.name],r=n.deferredOperations.pop();if(r)return r.reject(t),r.promise}function A(e,t){return new u((function(n,r){if(m[e.name]=m[e.name]||B(),e.db){if(!t)return n(e.db);_(e),e.db.close()}var i=[e.name];t&&i.push(e.version);var a=o.open.apply(o,i);t&&(a.onupgradeneeded=function(t){var n=a.result;try{n.createObjectStore(e.storeName),t.oldVersion<=1&&n.createObjectStore(p)}catch(r){if("ConstraintError"!==r.name)throw r;console.warn('The database "'+e.name+'" has been upgraded from version '+t.oldVersion+" to version "+t.newVersion+', but the storage "'+e.storeName+'" already exists.')}}),a.onerror=function(e){e.preventDefault(),r(a.error)},a.onsuccess=function(){var t=a.result;t.onversionchange=function(e){e.target.close()},n(t),k(e)}}))}function R(e){return A(e,!1)}function x(e){return A(e,!0)}function C(e,t){if(!e.db)return!0;var n=!e.db.objectStoreNames.contains(e.storeName),r=e.version<e.db.version,i=e.version>e.db.version;if(r&&(e.version!==t&&console.warn('The database "'+e.name+"\" can't be downgraded from version "+e.db.version+" to version "+e.version+"."),e.version=e.db.version),i||n){if(n){var a=e.db.version+1;a>e.version&&(e.version=a)}return!0}return!1}function I(e){return new u((function(t,n){var r=new FileReader;r.onerror=n,r.onloadend=function(n){var r=btoa(n.target.result||"");t({__local_forage_encoded_blob:!0,data:r,type:e.type})},r.readAsBinaryString(e)}))}function P(e){var t=T(atob(e.data));return c([t],{type:e.type})}function O(e){return e&&e.__local_forage_encoded_blob}function D(e){var t=this,n=t._initReady().then((function(){var e=m[t._dbInfo.name];if(e&&e.dbReady)return e.dbReady}));return f(n,e,e),n}function U(e){_(e);for(var t=m[e.name],n=t.forages,r=0;r<n.length;r++){var i=n[r];i._dbInfo.db&&(i._dbInfo.db.close(),i._dbInfo.db=null)}return e.db=null,R(e).then((function(t){return e.db=t,C(e)?x(e):t})).then((function(r){e.db=t.db=r;for(var i=0;i<n.length;i++)n[i]._dbInfo.db=r}))["catch"]((function(t){throw w(e,t),t}))}function M(e,t,n,r){void 0===r&&(r=1);try{var i=e.db.transaction(e.storeName,t);n(null,i)}catch(a){if(r>0&&(!e.db||"InvalidStateError"===a.name||"NotFoundError"===a.name))return u.resolve().then((function(){if(!e.db||"NotFoundError"===a.name&&!e.db.objectStoreNames.contains(e.storeName)&&e.version<=e.db.version)return e.db&&(e.version=e.db.version+1),x(e)})).then((function(){return U(e).then((function(){M(e,t,n,r-1)}))}))["catch"](n);n(a)}}function B(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function N(e){var t=this,n={db:null};if(e)for(var r in e)n[r]=e[r];var i=m[n.name];i||(i=B(),m[n.name]=i),i.forages.push(t),t._initReady||(t._initReady=t.ready,t.ready=D);var a=[];function o(){return u.resolve()}for(var s=0;s<i.forages.length;s++){var c=i.forages[s];c!==t&&a.push(c._initReady()["catch"](o))}var l=i.forages.slice(0);return u.all(a).then((function(){return n.db=i.db,R(n)})).then((function(e){return n.db=e,C(n,t._defaultConfig.version)?x(n):e})).then((function(e){n.db=i.db=e,t._dbInfo=n;for(var r=0;r<l.length;r++){var a=l[r];a!==t&&(a._dbInfo.db=n.db,a._dbInfo.version=n.version)}}))}function L(e,t){var n=this;e=h(e);var r=new u((function(t,r){n.ready().then((function(){M(n._dbInfo,g,(function(i,a){if(i)return r(i);try{var o=a.objectStore(n._dbInfo.storeName),s=o.get(e);s.onsuccess=function(){var e=s.result;void 0===e&&(e=null),O(e)&&(e=P(e)),t(e)},s.onerror=function(){r(s.error)}}catch(c){r(c)}}))}))["catch"](r)}));return l(r,t),r}function F(e,t){var n=this,r=new u((function(t,r){n.ready().then((function(){M(n._dbInfo,g,(function(i,a){if(i)return r(i);try{var o=a.objectStore(n._dbInfo.storeName),s=o.openCursor(),c=1;s.onsuccess=function(){var n=s.result;if(n){var r=n.value;O(r)&&(r=P(r));var i=e(r,n.key,c++);void 0!==i?t(i):n["continue"]()}else t()},s.onerror=function(){r(s.error)}}catch(u){r(u)}}))}))["catch"](r)}));return l(r,t),r}function j(e,t,n){var r=this;e=h(e);var i=new u((function(n,i){var a;r.ready().then((function(){return a=r._dbInfo,"[object Blob]"===y.call(t)?E(a.db).then((function(e){return e?t:I(t)})):t})).then((function(t){M(r._dbInfo,b,(function(a,o){if(a)return i(a);try{var s=o.objectStore(r._dbInfo.storeName);null===t&&(t=void 0);var c=s.put(t,e);o.oncomplete=function(){void 0===t&&(t=null),n(t)},o.onabort=o.onerror=function(){var e=c.error?c.error:c.transaction.error;i(e)}}catch(u){i(u)}}))}))["catch"](i)}));return l(i,n),i}function W(e,t){var n=this;e=h(e);var r=new u((function(t,r){n.ready().then((function(){M(n._dbInfo,b,(function(i,a){if(i)return r(i);try{var o=a.objectStore(n._dbInfo.storeName),s=o["delete"](e);a.oncomplete=function(){t()},a.onerror=function(){r(s.error)},a.onabort=function(){var e=s.error?s.error:s.transaction.error;r(e)}}catch(c){r(c)}}))}))["catch"](r)}));return l(r,t),r}function H(e){var t=this,n=new u((function(e,n){t.ready().then((function(){M(t._dbInfo,b,(function(r,i){if(r)return n(r);try{var a=i.objectStore(t._dbInfo.storeName),o=a.clear();i.oncomplete=function(){e()},i.onabort=i.onerror=function(){var e=o.error?o.error:o.transaction.error;n(e)}}catch(s){n(s)}}))}))["catch"](n)}));return l(n,e),n}function V(e){var t=this,n=new u((function(e,n){t.ready().then((function(){M(t._dbInfo,g,(function(r,i){if(r)return n(r);try{var a=i.objectStore(t._dbInfo.storeName),o=a.count();o.onsuccess=function(){e(o.result)},o.onerror=function(){n(o.error)}}catch(s){n(s)}}))}))["catch"](n)}));return l(n,e),n}function q(e,t){var n=this,r=new u((function(t,r){e<0?t(null):n.ready().then((function(){M(n._dbInfo,g,(function(i,a){if(i)return r(i);try{var o=a.objectStore(n._dbInfo.storeName),s=!1,c=o.openKeyCursor();c.onsuccess=function(){var n=c.result;n?0===e||s?t(n.key):(s=!0,n.advance(e)):t(null)},c.onerror=function(){r(c.error)}}catch(u){r(u)}}))}))["catch"](r)}));return l(r,t),r}function z(e){var t=this,n=new u((function(e,n){t.ready().then((function(){M(t._dbInfo,g,(function(r,i){if(r)return n(r);try{var a=i.objectStore(t._dbInfo.storeName),o=a.openKeyCursor(),s=[];o.onsuccess=function(){var t=o.result;t?(s.push(t.key),t["continue"]()):e(s)},o.onerror=function(){n(o.error)}}catch(c){n(c)}}))}))["catch"](n)}));return l(n,e),n}function G(e,t){t=d.apply(this,arguments);var n=this.config();e="function"!==typeof e&&e||{},e.name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,i=this;if(e.name){var a=e.name===n.name&&i._dbInfo.db,s=a?u.resolve(i._dbInfo.db):R(e).then((function(t){var n=m[e.name],r=n.forages;n.db=t;for(var i=0;i<r.length;i++)r[i]._dbInfo.db=t;return t}));r=e.storeName?s.then((function(t){if(t.objectStoreNames.contains(e.storeName)){var n=t.version+1;_(e);var r=m[e.name],i=r.forages;t.close();for(var a=0;a<i.length;a++){var s=i[a];s._dbInfo.db=null,s._dbInfo.version=n}var c=new u((function(t,r){var i=o.open(e.name,n);i.onerror=function(e){var t=i.result;t.close(),r(e)},i.onupgradeneeded=function(){var t=i.result;t.deleteObjectStore(e.storeName)},i.onsuccess=function(){var e=i.result;e.close(),t(e)}}));return c.then((function(e){r.db=e;for(var t=0;t<i.length;t++){var n=i[t];n._dbInfo.db=e,k(n._dbInfo)}}))["catch"]((function(t){throw(w(e,t)||u.resolve())["catch"]((function(){})),t}))}})):s.then((function(t){_(e);var n=m[e.name],r=n.forages;t.close();for(var i=0;i<r.length;i++){var a=r[i];a._dbInfo.db=null}var s=new u((function(t,n){var r=o.deleteDatabase(e.name);r.onerror=function(){var e=r.result;e&&e.close(),n(r.error)},r.onblocked=function(){console.warn('dropInstance blocked for database "'+e.name+'" until all open connections are closed')},r.onsuccess=function(){var e=r.result;e&&e.close(),t(e)}}));return s.then((function(e){n.db=e;for(var t=0;t<r.length;t++){var i=r[t];k(i._dbInfo)}}))["catch"]((function(t){throw(w(e,t)||u.resolve())["catch"]((function(){})),t}))}))}else r=u.reject("Invalid arguments");return l(r,t),r}var Y={_driver:"asyncStorage",_initStorage:N,_support:s(),iterate:F,getItem:L,setItem:j,removeItem:W,clear:H,length:V,key:q,keys:z,dropInstance:G};function K(){return"function"===typeof openDatabase}var X="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Q="~~local_forage_type~",$=/^~~local_forage_type~([^~]+)~/,Z="__lfsc__:",J=Z.length,ee="arbf",te="blob",ne="si08",re="ui08",ie="uic8",ae="si16",oe="si32",se="ur16",ce="ui32",ue="fl32",le="fl64",fe=J+ee.length,he=Object.prototype.toString;function de(e){var t,n,r,i,a,o=.75*e.length,s=e.length,c=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);var u=new ArrayBuffer(o),l=new Uint8Array(u);for(t=0;t<s;t+=4)n=X.indexOf(e[t]),r=X.indexOf(e[t+1]),i=X.indexOf(e[t+2]),a=X.indexOf(e[t+3]),l[c++]=n<<2|r>>4,l[c++]=(15&r)<<4|i>>2,l[c++]=(3&i)<<6|63&a;return u}function pe(e){var t,n=new Uint8Array(e),r="";for(t=0;t<n.length;t+=3)r+=X[n[t]>>2],r+=X[(3&n[t])<<4|n[t+1]>>4],r+=X[(15&n[t+1])<<2|n[t+2]>>6],r+=X[63&n[t+2]];return n.length%3===2?r=r.substring(0,r.length-1)+"=":n.length%3===1&&(r=r.substring(0,r.length-2)+"=="),r}function ve(e,t){var n="";if(e&&(n=he.call(e)),e&&("[object ArrayBuffer]"===n||e.buffer&&"[object ArrayBuffer]"===he.call(e.buffer))){var r,i=Z;e instanceof ArrayBuffer?(r=e,i+=ee):(r=e.buffer,"[object Int8Array]"===n?i+=ne:"[object Uint8Array]"===n?i+=re:"[object Uint8ClampedArray]"===n?i+=ie:"[object Int16Array]"===n?i+=ae:"[object Uint16Array]"===n?i+=se:"[object Int32Array]"===n?i+=oe:"[object Uint32Array]"===n?i+=ce:"[object Float32Array]"===n?i+=ue:"[object Float64Array]"===n?i+=le:t(new Error("Failed to get type for BinaryArray"))),t(i+pe(r))}else if("[object Blob]"===n){var a=new FileReader;a.onload=function(){var n=Q+e.type+"~"+pe(this.result);t(Z+te+n)},a.readAsArrayBuffer(e)}else try{t(JSON.stringify(e))}catch(o){console.error("Couldn't convert value into a JSON string: ",e),t(null,o)}}function me(e){if(e.substring(0,J)!==Z)return JSON.parse(e);var t,n=e.substring(fe),r=e.substring(J,fe);if(r===te&&$.test(n)){var i=n.match($);t=i[1],n=n.substring(i[0].length)}var a=de(n);switch(r){case ee:return a;case te:return c([a],{type:t});case ne:return new Int8Array(a);case re:return new Uint8Array(a);case ie:return new Uint8ClampedArray(a);case ae:return new Int16Array(a);case se:return new Uint16Array(a);case oe:return new Int32Array(a);case ce:return new Uint32Array(a);case ue:return new Float32Array(a);case le:return new Float64Array(a);default:throw new Error("Unkown type: "+r)}}var ye={serialize:ve,deserialize:me,stringToBuffer:de,bufferToString:pe};function ge(e,t,n,r){e.executeSql("CREATE TABLE IF NOT EXISTS "+t.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],n,r)}function be(e){var t=this,n={db:null};if(e)for(var r in e)n[r]="string"!==typeof e[r]?e[r].toString():e[r];var i=new u((function(e,r){try{n.db=openDatabase(n.name,String(n.version),n.description,n.size)}catch(i){return r(i)}n.db.transaction((function(i){ge(i,n,(function(){t._dbInfo=n,e()}),(function(e,t){r(t)}))}),r)}));return n.serializer=ye,i}function Te(e,t,n,r,i,a){e.executeSql(n,r,i,(function(e,o){o.code===o.SYNTAX_ERR?e.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[t.storeName],(function(e,s){s.rows.length?a(e,o):ge(e,t,(function(){e.executeSql(n,r,i,a)}),a)}),a):a(e,o)}),a)}function Se(e,t){var n=this;e=h(e);var r=new u((function(t,r){n.ready().then((function(){var i=n._dbInfo;i.db.transaction((function(n){Te(n,i,"SELECT * FROM "+i.storeName+" WHERE key = ? LIMIT 1",[e],(function(e,n){var r=n.rows.length?n.rows.item(0).value:null;r&&(r=i.serializer.deserialize(r)),t(r)}),(function(e,t){r(t)}))}))}))["catch"](r)}));return l(r,t),r}function Ee(e,t){var n=this,r=new u((function(t,r){n.ready().then((function(){var i=n._dbInfo;i.db.transaction((function(n){Te(n,i,"SELECT * FROM "+i.storeName,[],(function(n,r){for(var a=r.rows,o=a.length,s=0;s<o;s++){var c=a.item(s),u=c.value;if(u&&(u=i.serializer.deserialize(u)),u=e(u,c.key,s+1),void 0!==u)return void t(u)}t()}),(function(e,t){r(t)}))}))}))["catch"](r)}));return l(r,t),r}function _e(e,t,n,r){var i=this;e=h(e);var a=new u((function(a,o){i.ready().then((function(){void 0===t&&(t=null);var s=t,c=i._dbInfo;c.serializer.serialize(t,(function(t,u){u?o(u):c.db.transaction((function(n){Te(n,c,"INSERT OR REPLACE INTO "+c.storeName+" (key, value) VALUES (?, ?)",[e,t],(function(){a(s)}),(function(e,t){o(t)}))}),(function(t){if(t.code===t.QUOTA_ERR){if(r>0)return void a(_e.apply(i,[e,s,n,r-1]));o(t)}}))}))}))["catch"](o)}));return l(a,n),a}function ke(e,t,n){return _e.apply(this,[e,t,n,1])}function we(e,t){var n=this;e=h(e);var r=new u((function(t,r){n.ready().then((function(){var i=n._dbInfo;i.db.transaction((function(n){Te(n,i,"DELETE FROM "+i.storeName+" WHERE key = ?",[e],(function(){t()}),(function(e,t){r(t)}))}))}))["catch"](r)}));return l(r,t),r}function Ae(e){var t=this,n=new u((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Te(t,r,"DELETE FROM "+r.storeName,[],(function(){e()}),(function(e,t){n(t)}))}))}))["catch"](n)}));return l(n,e),n}function Re(e){var t=this,n=new u((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Te(t,r,"SELECT COUNT(key) as c FROM "+r.storeName,[],(function(t,n){var r=n.rows.item(0).c;e(r)}),(function(e,t){n(t)}))}))}))["catch"](n)}));return l(n,e),n}function xe(e,t){var n=this,r=new u((function(t,r){n.ready().then((function(){var i=n._dbInfo;i.db.transaction((function(n){Te(n,i,"SELECT key FROM "+i.storeName+" WHERE id = ? LIMIT 1",[e+1],(function(e,n){var r=n.rows.length?n.rows.item(0).key:null;t(r)}),(function(e,t){r(t)}))}))}))["catch"](r)}));return l(r,t),r}function Ce(e){var t=this,n=new u((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Te(t,r,"SELECT key FROM "+r.storeName,[],(function(t,n){for(var r=[],i=0;i<n.rows.length;i++)r.push(n.rows.item(i).key);e(r)}),(function(e,t){n(t)}))}))}))["catch"](n)}));return l(n,e),n}function Ie(e){return new u((function(t,n){e.transaction((function(r){r.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],(function(n,r){for(var i=[],a=0;a<r.rows.length;a++)i.push(r.rows.item(a).name);t({db:e,storeNames:i})}),(function(e,t){n(t)}))}),(function(e){n(e)}))}))}function Pe(e,t){t=d.apply(this,arguments);var n=this.config();e="function"!==typeof e&&e||{},e.name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,i=this;return r=e.name?new u((function(t){var r;r=e.name===n.name?i._dbInfo.db:openDatabase(e.name,"","",0),e.storeName?t({db:r,storeNames:[e.storeName]}):t(Ie(r))})).then((function(e){return new u((function(t,n){e.db.transaction((function(r){function i(e){return new u((function(t,n){r.executeSql("DROP TABLE IF EXISTS "+e,[],(function(){t()}),(function(e,t){n(t)}))}))}for(var a=[],o=0,s=e.storeNames.length;o<s;o++)a.push(i(e.storeNames[o]));u.all(a).then((function(){t()}))["catch"]((function(e){n(e)}))}),(function(e){n(e)}))}))})):u.reject("Invalid arguments"),l(r,t),r}var Oe={_driver:"webSQLStorage",_initStorage:be,_support:K(),iterate:Ee,getItem:Se,setItem:ke,removeItem:we,clear:Ae,length:Re,key:xe,keys:Ce,dropInstance:Pe};function De(){try{return"undefined"!==typeof localStorage&&"setItem"in localStorage&&!!localStorage.setItem}catch(e){return!1}}function Ue(e,t){var n=e.name+"/";return e.storeName!==t.storeName&&(n+=e.storeName+"/"),n}function Me(){var e="_localforage_support_test";try{return localStorage.setItem(e,!0),localStorage.removeItem(e),!1}catch(t){return!0}}function Be(){return!Me()||localStorage.length>0}function Ne(e){var t=this,n={};if(e)for(var r in e)n[r]=e[r];return n.keyPrefix=Ue(e,t._defaultConfig),Be()?(t._dbInfo=n,n.serializer=ye,u.resolve()):u.reject()}function Le(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo.keyPrefix,n=localStorage.length-1;n>=0;n--){var r=localStorage.key(n);0===r.indexOf(e)&&localStorage.removeItem(r)}}));return l(n,e),n}function Fe(e,t){var n=this;e=h(e);var r=n.ready().then((function(){var t=n._dbInfo,r=localStorage.getItem(t.keyPrefix+e);return r&&(r=t.serializer.deserialize(r)),r}));return l(r,t),r}function je(e,t){var n=this,r=n.ready().then((function(){for(var t=n._dbInfo,r=t.keyPrefix,i=r.length,a=localStorage.length,o=1,s=0;s<a;s++){var c=localStorage.key(s);if(0===c.indexOf(r)){var u=localStorage.getItem(c);if(u&&(u=t.serializer.deserialize(u)),u=e(u,c.substring(i),o++),void 0!==u)return u}}}));return l(r,t),r}function We(e,t){var n=this,r=n.ready().then((function(){var t,r=n._dbInfo;try{t=localStorage.key(e)}catch(i){t=null}return t&&(t=t.substring(r.keyPrefix.length)),t}));return l(r,t),r}function He(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo,n=localStorage.length,r=[],i=0;i<n;i++){var a=localStorage.key(i);0===a.indexOf(e.keyPrefix)&&r.push(a.substring(e.keyPrefix.length))}return r}));return l(n,e),n}function Ve(e){var t=this,n=t.keys().then((function(e){return e.length}));return l(n,e),n}function qe(e,t){var n=this;e=h(e);var r=n.ready().then((function(){var t=n._dbInfo;localStorage.removeItem(t.keyPrefix+e)}));return l(r,t),r}function ze(e,t,n){var r=this;e=h(e);var i=r.ready().then((function(){void 0===t&&(t=null);var n=t;return new u((function(i,a){var o=r._dbInfo;o.serializer.serialize(t,(function(t,r){if(r)a(r);else try{localStorage.setItem(o.keyPrefix+e,t),i(n)}catch(s){"QuotaExceededError"!==s.name&&"NS_ERROR_DOM_QUOTA_REACHED"!==s.name||a(s),a(s)}}))}))}));return l(i,n),i}function Ge(e,t){if(t=d.apply(this,arguments),e="function"!==typeof e&&e||{},!e.name){var n=this.config();e.name=e.name||n.name,e.storeName=e.storeName||n.storeName}var r,i=this;return r=e.name?new u((function(t){e.storeName?t(Ue(e,i._defaultConfig)):t(e.name+"/")})).then((function(e){for(var t=localStorage.length-1;t>=0;t--){var n=localStorage.key(t);0===n.indexOf(e)&&localStorage.removeItem(n)}})):u.reject("Invalid arguments"),l(r,t),r}var Ye={_driver:"localStorageWrapper",_initStorage:Ne,_support:De(),iterate:je,getItem:Fe,setItem:ze,removeItem:qe,clear:Le,length:Ve,key:We,keys:He,dropInstance:Ge},Ke=function(e,t){return e===t||"number"===typeof e&&"number"===typeof t&&isNaN(e)&&isNaN(t)},Xe=function(e,t){var n=e.length,r=0;while(r<n){if(Ke(e[r],t))return!0;r++}return!1},Qe=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},$e={},Ze={},Je={INDEXEDDB:Y,WEBSQL:Oe,LOCALSTORAGE:Ye},et=[Je.INDEXEDDB._driver,Je.WEBSQL._driver,Je.LOCALSTORAGE._driver],tt=["dropInstance"],nt=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(tt),rt={description:"",driver:et.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function it(e,t){e[t]=function(){var n=arguments;return e.ready().then((function(){return e[t].apply(e,n)}))}}function at(){for(var e=1;e<arguments.length;e++){var t=arguments[e];if(t)for(var n in t)t.hasOwnProperty(n)&&(Qe(t[n])?arguments[0][n]=t[n].slice():arguments[0][n]=t[n])}return arguments[0]}var ot=function(){function e(t){for(var n in i(this,e),Je)if(Je.hasOwnProperty(n)){var r=Je[n],a=r._driver;this[n]=a,$e[a]||this.defineDriver(r)}this._defaultConfig=at({},rt),this._config=at({},this._defaultConfig,t),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver)["catch"]((function(){}))}return e.prototype.config=function(e){if("object"===("undefined"===typeof e?"undefined":r(e))){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var t in e){if("storeName"===t&&(e[t]=e[t].replace(/\W/g,"_")),"version"===t&&"number"!==typeof e[t])return new Error("Database version must be a number.");this._config[t]=e[t]}return!("driver"in e)||!e.driver||this.setDriver(this._config.driver)}return"string"===typeof e?this._config[e]:this._config},e.prototype.defineDriver=function(e,t,n){var r=new u((function(t,n){try{var r=e._driver,i=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!e._driver)return void n(i);for(var a=nt.concat("_initStorage"),o=0,s=a.length;o<s;o++){var c=a[o],f=!Xe(tt,c);if((f||e[c])&&"function"!==typeof e[c])return void n(i)}var h=function(){for(var t=function(e){return function(){var t=new Error("Method "+e+" is not implemented by the current driver"),n=u.reject(t);return l(n,arguments[arguments.length-1]),n}},n=0,r=tt.length;n<r;n++){var i=tt[n];e[i]||(e[i]=t(i))}};h();var d=function(n){$e[r]&&console.info("Redefining LocalForage driver: "+r),$e[r]=e,Ze[r]=n,t()};"_support"in e?e._support&&"function"===typeof e._support?e._support().then(d,n):d(!!e._support):d(!0)}catch(p){n(p)}}));return f(r,t,n),r},e.prototype.driver=function(){return this._driver||null},e.prototype.getDriver=function(e,t,n){var r=$e[e]?u.resolve($e[e]):u.reject(new Error("Driver not found."));return f(r,t,n),r},e.prototype.getSerializer=function(e){var t=u.resolve(ye);return f(t,e),t},e.prototype.ready=function(e){var t=this,n=t._driverSet.then((function(){return null===t._ready&&(t._ready=t._initDriver()),t._ready}));return f(n,e,e),n},e.prototype.setDriver=function(e,t,n){var r=this;Qe(e)||(e=[e]);var i=this._getSupportedDrivers(e);function a(){r._config.driver=r.driver()}function o(e){return r._extend(e),a(),r._ready=r._initStorage(r._config),r._ready}function s(e){return function(){var t=0;function n(){while(t<e.length){var i=e[t];return t++,r._dbInfo=null,r._ready=null,r.getDriver(i).then(o)["catch"](n)}a();var s=new Error("No available storage method found.");return r._driverSet=u.reject(s),r._driverSet}return n()}}var c=null!==this._driverSet?this._driverSet["catch"]((function(){return u.resolve()})):u.resolve();return this._driverSet=c.then((function(){var e=i[0];return r._dbInfo=null,r._ready=null,r.getDriver(e).then((function(e){r._driver=e._driver,a(),r._wrapLibraryMethodsWithReady(),r._initDriver=s(i)}))}))["catch"]((function(){a();var e=new Error("No available storage method found.");return r._driverSet=u.reject(e),r._driverSet})),f(this._driverSet,t,n),this._driverSet},e.prototype.supports=function(e){return!!Ze[e]},e.prototype._extend=function(e){at(this,e)},e.prototype._getSupportedDrivers=function(e){for(var t=[],n=0,r=e.length;n<r;n++){var i=e[n];this.supports(i)&&t.push(i)}return t},e.prototype._wrapLibraryMethodsWithReady=function(){for(var e=0,t=nt.length;e<t;e++)it(this,nt[e])},e.prototype.createInstance=function(t){return new e(t)},e}(),st=new ot;t.exports=st},{3:3}]},{},[4])(4)}))}).call(this,n("c8ba"))},a04b:function(e,t,n){var r=n("c04e"),i=n("d9b5");e.exports=function(e){var t=r(e,"string");return i(t)?t:t+""}},a078:function(e,t,n){var r=n("0366"),i=n("c65b"),a=n("5087"),o=n("7b0b"),s=n("07fa"),c=n("9a1f"),u=n("35a1"),l=n("e95a"),f=n("ebb5").aTypedArrayConstructor;e.exports=function(e){var t,n,h,d,p,v,m=a(this),y=o(e),g=arguments.length,b=g>1?arguments[1]:void 0,T=void 0!==b,S=u(y);if(S&&!l(S)){p=c(y,S),v=p.next,y=[];while(!(d=i(v,p)).done)y.push(d.value)}for(T&&g>2&&(b=r(b,arguments[2])),n=s(y),h=new(f(m))(n),t=0;n>t;t++)h[t]=T?b(y[t],t):y[t];return h}},a093:function(e,t,n){var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("7b0b"),s=n("3a9b"),c=n("ae93").IteratorPrototype,u=n("c5cc"),l=n("9a1f"),f=n("35a1"),h=u((function(e){var t=a(i(this.next,this.iterator,e)),n=this.done=!!t.done;if(!n)return t.value}),!0);r({target:"Iterator",stat:!0},{from:function(e){var t,n=o(e),r=f(n);if(r){if(t=l(n,r),s(c,t))return t}else t=n;return new h({iterator:t})}})},a11b:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.pad.Iso10126={pad:function(t,n){var r=4*n,i=r-t.sigBytes%r;t.concat(e.lib.WordArray.random(i-1)).concat(e.lib.WordArray.create([i<<24],1))},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},e.pad.Iso10126}))},a15b:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("44ad"),o=n("fc6a"),s=n("a640"),c=i([].join),u=a!=Object,l=s("join",",");r({target:"Array",proto:!0,forced:u||!l},{join:function(e){return c(o(this),void 0===e?",":e)}})},a1b3:function(e,t,n){var r=n("c65b"),i=n("63fa"),a=n("825a"),o=n("9a1f"),s=n("dc4a"),c=n("b622"),u=c("asyncIterator");e.exports=function(e,t){var n=arguments.length<2?s(e,u):t;return n?a(r(n,e)):new i(o(e))}},a1f0:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("e330"),s=n("9ed3"),c=n("1d80"),u=n("50c4"),l=n("577e"),f=n("825a"),h=n("c6b6"),d=n("3a9b"),p=n("44e7"),v=n("ad6d"),m=n("dc4a"),y=n("6eeb"),g=n("d039"),b=n("b622"),T=n("4840"),S=n("8aa5"),E=n("14c3"),_=n("69f3"),k=n("c430"),w=b("matchAll"),A="RegExp String",R=A+" Iterator",x=_.set,C=_.getterFor(R),I=RegExp.prototype,P=i.TypeError,O=o(v),D=o("".indexOf),U=o("".matchAll),M=!!U&&!g((function(){U("a",/./)})),B=s((function(e,t,n,r){x(this,{type:R,regexp:e,string:t,global:n,unicode:r,done:!1})}),A,(function(){var e=C(this);if(e.done)return{value:void 0,done:!0};var t=e.regexp,n=e.string,r=E(t,n);return null===r?{value:void 0,done:e.done=!0}:e.global?(""===l(r[0])&&(t.lastIndex=S(n,u(t.lastIndex),e.unicode)),{value:r,done:!1}):(e.done=!0,{value:r,done:!1})})),N=function(e){var t,n,r,i,a,o,s=f(this),c=l(e);return t=T(s,RegExp),n=s.flags,void 0===n&&d(I,s)&&!("flags"in I)&&(n=O(s)),r=void 0===n?"":l(n),i=new t(t===RegExp?s.source:s,r),a=!!~D(r,"g"),o=!!~D(r,"u"),i.lastIndex=u(s.lastIndex),new B(i,c,a,o)};r({target:"String",proto:!0,forced:M},{matchAll:function(e){var t,n,r,i,o=c(this);if(null!=e){if(p(e)&&(t=l(c("flags"in I?e.flags:O(e))),!~D(t,"g")))throw P("`.matchAll` does not allow non-global regexes");if(M)return U(o,e);if(r=m(e,w),void 0===r&&k&&"RegExp"==h(e)&&(r=N),r)return a(r,e,o)}else if(M)return U(o,e);return n=l(o),i=new RegExp(e,"g"),k?a(N,i,n):i[w](n)}}),k||w in I||y(I,w,N)},a258:function(e,t,n){var r=n("0366"),i=n("44ad"),a=n("7b0b"),o=n("07fa"),s=function(e){var t=1==e;return function(n,s,c){var u,l,f=a(n),h=i(f),d=r(s,c),p=o(h);while(p-- >0)if(u=h[p],l=d(u,p,f),l)switch(e){case 0:return u;case 1:return p}return t?-1:void 0}};e.exports={findLast:s(0),findLastIndex:s(1)}},a2bf:function(e,t,n){"use strict";var r=n("da84"),i=n("e8b5"),a=n("07fa"),o=n("0366"),s=r.TypeError,c=function(e,t,n,r,u,l,f,h){var d,p,v=u,m=0,y=!!f&&o(f,h);while(m<r){if(m in n){if(d=y?y(n[m],m,t):n[m],l>0&&i(d))p=a(d),v=c(e,t,d,p,v,l-1)-1;else{if(v>=9007199254740991)throw s("Exceed the acceptable array length");e[v]=d}v++}m++}return v};e.exports=c},a3a2:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("5926"),s=n("408a"),c=n("1148"),u=n("867a"),l=n("d039"),f=i.RangeError,h=i.String,d=i.isFinite,p=Math.abs,v=Math.floor,m=Math.pow,y=Math.round,g=a(1..toExponential),b=a(c),T=a("".slice),S="-6.9000e-11"===g(-69e-12,4)&&"1.25e+0"===g(1.255,2)&&"1.235e+4"===g(12345,3)&&"3e+1"===g(25,0),E=l((function(){g(1,1/0)}))&&l((function(){g(1,-1/0)})),_=!l((function(){g(1/0,1/0)}))&&!l((function(){g(NaN,1/0)})),k=!S||!E||!_;r({target:"Number",proto:!0,forced:k},{toExponential:function(e){var t=s(this);if(void 0===e)return g(t);var n=o(e);if(!d(t))return h(t);if(n<0||n>20)throw f("Incorrect fraction digits");if(S)return g(t,n);var r="",i="",a=0,c="",l="";if(t<0&&(r="-",t=-t),0===t)a=0,i=b("0",n+1);else{var E=u(t);a=v(E);var _=0,k=m(10,a-n);_=y(t/k),2*t>=(2*_+1)*k&&(_+=1),_>=m(10,n+1)&&(_/=10,a+=1),i=h(_)}return 0!==n&&(i=T(i,0,1)+"."+T(i,1)),0===a?(c="+",l="0"):(c=a>0?"+":"-",l=h(p(a))),i+="e"+c+l,r+i}})},a40e:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("1132"),n("72fe"),n("2b79"),n("38ba"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=n.BlockCipher,a=t.algo,o=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],c=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],u=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],l=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],f=a.DES=i.extend({_doReset:function(){for(var e=this._key,t=e.words,n=[],r=0;r<56;r++){var i=o[r]-1;n[r]=t[i>>>5]>>>31-i%32&1}for(var a=this._subKeys=[],u=0;u<16;u++){var l=a[u]=[],f=c[u];for(r=0;r<24;r++)l[r/6|0]|=n[(s[r]-1+f)%28]<<31-r%6,l[4+(r/6|0)]|=n[28+(s[r+24]-1+f)%28]<<31-r%6;l[0]=l[0]<<1|l[0]>>>31;for(r=1;r<7;r++)l[r]=l[r]>>>4*(r-1)+3;l[7]=l[7]<<5|l[7]>>>27}var h=this._invSubKeys=[];for(r=0;r<16;r++)h[r]=a[15-r]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._subKeys)},decryptBlock:function(e,t){this._doCryptBlock(e,t,this._invSubKeys)},_doCryptBlock:function(e,t,n){this._lBlock=e[t],this._rBlock=e[t+1],h.call(this,4,252645135),h.call(this,16,65535),d.call(this,2,858993459),d.call(this,8,16711935),h.call(this,1,1431655765);for(var r=0;r<16;r++){for(var i=n[r],a=this._lBlock,o=this._rBlock,s=0,c=0;c<8;c++)s|=u[c][((o^i[c])&l[c])>>>0];this._lBlock=o,this._rBlock=a^s}var f=this._lBlock;this._lBlock=this._rBlock,this._rBlock=f,h.call(this,1,1431655765),d.call(this,8,16711935),d.call(this,2,858993459),h.call(this,16,65535),h.call(this,4,252645135),e[t]=this._lBlock,e[t+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});function h(e,t){var n=(this._lBlock>>>e^this._rBlock)&t;this._rBlock^=n,this._lBlock^=n<<e}function d(e,t){var n=(this._rBlock>>>e^this._lBlock)&t;this._lBlock^=n,this._rBlock^=n<<e}t.DES=i._createHelper(f);var p=a.TripleDES=i.extend({_doReset:function(){var e=this._key,t=e.words;if(2!==t.length&&4!==t.length&&t.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var n=t.slice(0,2),i=t.length<4?t.slice(0,2):t.slice(2,4),a=t.length<6?t.slice(0,2):t.slice(4,6);this._des1=f.createEncryptor(r.create(n)),this._des2=f.createEncryptor(r.create(i)),this._des3=f.createEncryptor(r.create(a))},encryptBlock:function(e,t){this._des1.encryptBlock(e,t),this._des2.decryptBlock(e,t),this._des3.encryptBlock(e,t)},decryptBlock:function(e,t){this._des3.decryptBlock(e,t),this._des2.encryptBlock(e,t),this._des1.decryptBlock(e,t)},keySize:6,ivSize:2,blockSize:2});t.TripleDES=i._createHelper(p)}(),e.TripleDES}))},a434:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("23cb"),o=n("5926"),s=n("07fa"),c=n("7b0b"),u=n("65f0"),l=n("8418"),f=n("1dde"),h=f("splice"),d=i.TypeError,p=Math.max,v=Math.min,m=9007199254740991,y="Maximum allowed length exceeded";r({target:"Array",proto:!0,forced:!h},{splice:function(e,t){var n,r,i,f,h,g,b=c(this),T=s(b),S=a(e,T),E=arguments.length;if(0===E?n=r=0:1===E?(n=0,r=T-S):(n=E-2,r=v(p(o(t),0),T-S)),T+n-r>m)throw d(y);for(i=u(b,r),f=0;f<r;f++)h=S+f,h in b&&l(i,f,b[h]);if(i.length=r,n<r){for(f=S;f<T-r;f++)h=f+r,g=f+n,h in b?b[g]=b[h]:delete b[g];for(f=T;f>T-r+n;f--)delete b[f-1]}else if(n>r)for(f=T-r;f>S;f--)h=f+r-1,g=f+n-1,h in b?b[g]=b[h]:delete b[g];for(f=0;f<n;f++)b[f+S]=arguments[f+2];return b.length=T-r+n,i}})},a454:function(e,t,n){"use strict";var r=n("23e7"),i=n("c885");r({target:"Object",stat:!0},{iterateValues:function(e){return new i(e,"values")}})},a4b4:function(e,t,n){var r=n("342f");e.exports=/web0s(?!.*chrome)/i.test(r)},a4d3:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("d066"),o=n("2ba4"),s=n("c65b"),c=n("e330"),u=n("c430"),l=n("83ab"),f=n("4930"),h=n("d039"),d=n("1a2d"),p=n("e8b5"),v=n("1626"),m=n("861d"),y=n("3a9b"),g=n("d9b5"),b=n("825a"),T=n("7b0b"),S=n("fc6a"),E=n("a04b"),_=n("577e"),k=n("5c6c"),w=n("7c73"),A=n("df75"),R=n("241c"),x=n("057f"),C=n("7418"),I=n("06cf"),P=n("9bf2"),O=n("37e8"),D=n("d1e7"),U=n("f36a"),M=n("6eeb"),B=n("5692"),N=n("f772"),L=n("d012"),F=n("90e3"),j=n("b622"),W=n("e538"),H=n("746f"),V=n("d44e"),q=n("69f3"),z=n("b727").forEach,G=N("hidden"),Y="Symbol",K="prototype",X=j("toPrimitive"),Q=q.set,$=q.getterFor(Y),Z=Object[K],J=i.Symbol,ee=J&&J[K],te=i.TypeError,ne=i.QObject,re=a("JSON","stringify"),ie=I.f,ae=P.f,oe=x.f,se=D.f,ce=c([].push),ue=B("symbols"),le=B("op-symbols"),fe=B("string-to-symbol-registry"),he=B("symbol-to-string-registry"),de=B("wks"),pe=!ne||!ne[K]||!ne[K].findChild,ve=l&&h((function(){return 7!=w(ae({},"a",{get:function(){return ae(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=ie(Z,t);r&&delete Z[t],ae(e,t,n),r&&e!==Z&&ae(Z,t,r)}:ae,me=function(e,t){var n=ue[e]=w(ee);return Q(n,{type:Y,tag:e,description:t}),l||(n.description=t),n},ye=function(e,t,n){e===Z&&ye(le,t,n),b(e);var r=E(t);return b(n),d(ue,r)?(n.enumerable?(d(e,G)&&e[G][r]&&(e[G][r]=!1),n=w(n,{enumerable:k(0,!1)})):(d(e,G)||ae(e,G,k(1,{})),e[G][r]=!0),ve(e,r,n)):ae(e,r,n)},ge=function(e,t){b(e);var n=S(t),r=A(n).concat(_e(n));return z(r,(function(t){l&&!s(Te,n,t)||ye(e,t,n[t])})),e},be=function(e,t){return void 0===t?w(e):ge(w(e),t)},Te=function(e){var t=E(e),n=s(se,this,t);return!(this===Z&&d(ue,t)&&!d(le,t))&&(!(n||!d(this,t)||!d(ue,t)||d(this,G)&&this[G][t])||n)},Se=function(e,t){var n=S(e),r=E(t);if(n!==Z||!d(ue,r)||d(le,r)){var i=ie(n,r);return!i||!d(ue,r)||d(n,G)&&n[G][r]||(i.enumerable=!0),i}},Ee=function(e){var t=oe(S(e)),n=[];return z(t,(function(e){d(ue,e)||d(L,e)||ce(n,e)})),n},_e=function(e){var t=e===Z,n=oe(t?le:S(e)),r=[];return z(n,(function(e){!d(ue,e)||t&&!d(Z,e)||ce(r,ue[e])})),r};if(f||(J=function(){if(y(ee,this))throw te("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?_(arguments[0]):void 0,t=F(e),n=function(e){this===Z&&s(n,le,e),d(this,G)&&d(this[G],t)&&(this[G][t]=!1),ve(this,t,k(1,e))};return l&&pe&&ve(Z,t,{configurable:!0,set:n}),me(t,e)},ee=J[K],M(ee,"toString",(function(){return $(this).tag})),M(J,"withoutSetter",(function(e){return me(F(e),e)})),D.f=Te,P.f=ye,O.f=ge,I.f=Se,R.f=x.f=Ee,C.f=_e,W.f=function(e){return me(j(e),e)},l&&(ae(ee,"description",{configurable:!0,get:function(){return $(this).description}}),u||M(Z,"propertyIsEnumerable",Te,{unsafe:!0}))),r({global:!0,wrap:!0,forced:!f,sham:!f},{Symbol:J}),z(A(de),(function(e){H(e)})),r({target:Y,stat:!0,forced:!f},{for:function(e){var t=_(e);if(d(fe,t))return fe[t];var n=J(t);return fe[t]=n,he[n]=t,n},keyFor:function(e){if(!g(e))throw te(e+" is not a symbol");if(d(he,e))return he[e]},useSetter:function(){pe=!0},useSimple:function(){pe=!1}}),r({target:"Object",stat:!0,forced:!f,sham:!l},{create:be,defineProperty:ye,defineProperties:ge,getOwnPropertyDescriptor:Se}),r({target:"Object",stat:!0,forced:!f},{getOwnPropertyNames:Ee,getOwnPropertySymbols:_e}),r({target:"Object",stat:!0,forced:h((function(){C.f(1)}))},{getOwnPropertySymbols:function(e){return C.f(T(e))}}),re){var ke=!f||h((function(){var e=J();return"[null]"!=re([e])||"{}"!=re({a:e})||"{}"!=re(Object(e))}));r({target:"JSON",stat:!0,forced:ke},{stringify:function(e,t,n){var r=U(arguments),i=t;if((m(t)||void 0!==e)&&!g(e))return p(t)||(t=function(e,t){if(v(i)&&(t=s(i,this,e,t)),!g(t))return t}),r[1]=t,o(re,null,r)}})}if(!ee[X]){var we=ee.valueOf;M(ee,X,(function(e){return s(we,this)}))}V(J,Y),L[G]=!0},a4f2:function(e,t,n){var r=n("da84"),i=n("0366"),a=n("e330"),o=n("44ad"),s=n("7b0b"),c=n("a04b"),u=n("07fa"),l=n("7c73"),f=n("dfb9"),h=r.Array,d=a([].push);e.exports=function(e,t,n,r){for(var a,p,v,m=s(e),y=o(m),g=i(t,n),b=l(null),T=u(y),S=0;T>S;S++)v=y[S],p=c(g(v,S,m)),p in b?d(b[p],v):b[p]=[v];if(r&&(a=r(m),a!==h))for(p in b)b[p]=f(a,b[p]);return b}},a529:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").filterReject,a=n("1448"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("filterOut",(function(e){var t=i(o(this),e,arguments.length>1?arguments[1]:void 0);return a(this,t)}))},a573:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("59ed"),o=n("825a"),s=n("c5cc"),c=n("9bdd"),u=s((function(e){var t=this.iterator,n=o(i(this.next,t,e)),r=this.done=!!n.done;if(!r)return c(t,this.mapper,n.value)}));r({target:"Iterator",proto:!0,real:!0},{map:function(e){return new u({iterator:o(this),mapper:a(e)})}})},a5eb:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("83ab"),s=n("2626"),c=n("59ed"),u=n("1626"),l=n("68ee"),f=n("825a"),h=n("861d"),d=n("19aa"),p=n("9bf2").f,v=n("6eeb"),m=n("e2cc"),y=n("9a1f"),g=n("dc4a"),b=n("2266"),T=n("44de"),S=n("b622"),E=n("69f3"),_=S("observable"),k="Observable",w="Subscription",A="SubscriptionObserver",R=E.getterFor,x=E.set,C=R(k),I=R(w),P=R(A),O=i.Array,D=function(e){this.observer=f(e),this.cleanup=void 0,this.subscriptionObserver=void 0};D.prototype={type:w,clean:function(){var e=this.cleanup;if(e){this.cleanup=void 0;try{e()}catch(t){T(t)}}},close:function(){if(!o){var e=this.facade,t=this.subscriptionObserver;e.closed=!0,t&&(t.closed=!0)}this.observer=void 0},isClosed:function(){return void 0===this.observer}};var U=function(e,t){var n,r=x(this,new D(e));o||(this.closed=!1);try{(n=g(e,"start"))&&a(n,e,this)}catch(f){T(f)}if(!r.isClosed()){var i=r.subscriptionObserver=new M(r);try{var s=t(i),l=s;null!=s&&(r.cleanup=u(s.unsubscribe)?function(){l.unsubscribe()}:c(s))}catch(f){return void i.error(f)}r.isClosed()&&r.clean()}};U.prototype=m({},{unsubscribe:function(){var e=I(this);e.isClosed()||(e.close(),e.clean())}}),o&&p(U.prototype,"closed",{configurable:!0,get:function(){return I(this).isClosed()}});var M=function(e){x(this,{type:A,subscriptionState:e}),o||(this.closed=!1)};M.prototype=m({},{next:function(e){var t=P(this).subscriptionState;if(!t.isClosed()){var n=t.observer;try{var r=g(n,"next");r&&a(r,n,e)}catch(i){T(i)}}},error:function(e){var t=P(this).subscriptionState;if(!t.isClosed()){var n=t.observer;t.close();try{var r=g(n,"error");r?a(r,n,e):T(e)}catch(i){T(i)}t.clean()}},complete:function(){var e=P(this).subscriptionState;if(!e.isClosed()){var t=e.observer;e.close();try{var n=g(t,"complete");n&&a(n,t)}catch(r){T(r)}e.clean()}}}),o&&p(M.prototype,"closed",{configurable:!0,get:function(){return P(this).subscriptionState.isClosed()}});var B=function(e){d(this,N),x(this,{type:k,subscriber:c(e)})},N=B.prototype;m(N,{subscribe:function(e){var t=arguments.length;return new U(u(e)?{next:e,error:t>1?arguments[1]:void 0,complete:t>2?arguments[2]:void 0}:h(e)?e:{},C(this).subscriber)}}),m(B,{from:function(e){var t=l(this)?this:B,n=g(f(e),_);if(n){var r=f(a(n,e));return r.constructor===t?r:new t((function(e){return r.subscribe(e)}))}var i=y(e);return new t((function(e){b(i,(function(t,n){if(e.next(t),e.closed)return n()}),{IS_ITERATOR:!0,INTERRUPTED:!0}),e.complete()}))},of:function(){var e=l(this)?this:B,t=arguments.length,n=O(t),r=0;while(r<t)n[r]=arguments[r++];return new e((function(e){for(var r=0;r<t;r++)if(e.next(n[r]),e.closed)return;e.complete()}))}}),v(N,_,(function(){return this})),r({global:!0},{Observable:B}),s(k)},a623:function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").every,a=n("a640"),o=a("every");r({target:"Array",proto:!0,forced:!o},{every:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},a630:function(e,t,n){var r=n("23e7"),i=n("4df4"),a=n("1c7e"),o=!a((function(e){Array.from(e)}));r({target:"Array",stat:!0,forced:o},{from:i})},a640:function(e,t,n){"use strict";var r=n("d039");e.exports=function(e,t){var n=[][e];return!!n&&r((function(){n.call(null,t||function(){throw 1},1)}))}},a6fd:function(e,t,n){var r=n("23e7"),i=n("2ba4"),a=n("59ed"),o=n("825a"),s=n("d039"),c=!s((function(){Reflect.apply((function(){}))}));r({target:"Reflect",stat:!0,forced:c},{apply:function(e,t,n){return i(a(e),t,o(n))}})},a799:function(e,t,n){n("4ec9"),n("10d1");var r=n("da84"),i=n("d066"),a=n("7c73"),o=n("861d"),s=r.Object,c=r.TypeError,u=i("Map"),l=i("WeakMap"),f=function(){this.object=null,this.symbol=null,this.primitives=null,this.objectsByIndex=a(null)};f.prototype.get=function(e,t){return this[e]||(this[e]=t())},f.prototype.next=function(e,t,n){var r=n?this.objectsByIndex[e]||(this.objectsByIndex[e]=new l):this.primitives||(this.primitives=new u),i=r.get(t);return i||r.set(t,i=new f),i};var h=new f;e.exports=function(){var e,t,n=h,r=arguments.length;for(e=0;e<r;e++)o(t=arguments[e])&&(n=n.next(e,t,!0));if(this===s&&n===h)throw c("Composite keys must contain a non-primitive component");for(e=0;e<r;e++)o(t=arguments[e])||(n=n.next(e,t,!1));return n}},a79d:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("fea9"),o=n("d039"),s=n("d066"),c=n("1626"),u=n("4840"),l=n("cdf9"),f=n("6eeb"),h=!!a&&o((function(){a.prototype["finally"].call({then:function(){}},(function(){}))}));if(r({target:"Promise",proto:!0,real:!0,forced:h},{finally:function(e){var t=u(this,s("Promise")),n=c(e);return this.then(n?function(n){return l(t,e()).then((function(){return n}))}:e,n?function(n){return l(t,e()).then((function(){throw n}))}:e)}}),!i&&c(a)){var d=s("Promise").prototype["finally"];a.prototype["finally"]!==d&&f(a.prototype,"finally",d,{unsafe:!0})}},a7f4:function(e,t,n){var r=n("746f");r("asyncDispose")},a817:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.pad.AnsiX923={pad:function(e,t){var n=e.sigBytes,r=4*t,i=r-n%r,a=n+i-1;e.clamp(),e.words[a>>>2]|=i<<24-a%4*8,e.sigBytes+=i},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},e.pad.Ansix923}))},a874:function(e,t,n){var r=n("23e7"),i=n("145e"),a=n("44d2");r({target:"Array",proto:!0},{copyWithin:i}),a("copyWithin")},a8ce:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=t.enc;i.Utf16=i.Utf16BE={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i+=2){var a=t[i>>>2]>>>16-i%4*8&65535;r.push(String.fromCharCode(a))}return r.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i++)n[i>>>1]|=e.charCodeAt(i)<<16-i%2*16;return r.create(n,2*t)}};function a(e){return e<<8&4278255360|e>>>8&16711935}i.Utf16LE={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i+=2){var o=a(t[i>>>2]>>>16-i%4*8&65535);r.push(String.fromCharCode(o))}return r.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i++)n[i>>>1]|=a(e.charCodeAt(i)<<16-i%2*16);return r.create(n,2*t)}}}(),e.enc.Utf16}))},a91f:function(e,t,n){var r,i,a=n("da84"),o=n("c6cd"),s=n("1626"),c=n("7c73"),u=n("e163"),l=n("6eeb"),f=n("b622"),h=n("c430"),d="USE_FUNCTION_CONSTRUCTOR",p=f("asyncIterator"),v=a.AsyncIterator,m=o.AsyncIteratorPrototype;if(m)r=m;else if(s(v))r=v.prototype;else if(o[d]||a[d])try{i=u(u(u(Function("return async function*(){}()")()))),u(i)===Object.prototype&&(r=i)}catch(y){}r?h&&(r=c(r)):r={},s(r[p])||l(r,p,(function(){return this})),e.exports=r},a95f:function(e,t,n){"use strict";var r=n("0366"),i=n("7b0b"),a=n("68ee"),o=n("a1b3"),s=n("9a1f"),c=n("35a1"),u=n("dc4a"),l=n("51cf"),f=n("d066"),h=n("b622"),d=n("63fa"),p=n("dd2f").toArray,v=h("asyncIterator"),m=l("Array").values;e.exports=function(e){var t=this,n=arguments.length,l=n>1?arguments[1]:void 0,h=n>2?arguments[2]:void 0;return new(f("Promise"))((function(n){var f=i(e);void 0!==l&&(l=r(l,h));var y=u(f,v),g=y?void 0:c(f)||m,b=a(t)?new t:[],T=y?o(f,y):new d(s(f,g));n(p(T,l,b))}))}},a975:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").every,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("every",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},a981:function(e,t){e.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},a98e:function(e,t,n){"use strict";var r=n("0366"),i=n("c65b"),a=n("59ed"),o=n("5087"),s=n("2266"),c=[].push;e.exports=function(e){var t,n,u,l,f=arguments.length,h=f>1?arguments[1]:void 0;return o(this),t=void 0!==h,t&&a(h),void 0==e?new this:(n=[],t?(u=0,l=r(h,f>2?arguments[2]:void 0),s(e,(function(e){i(c,n,l(e,u++))}))):s(e,c,{that:n}),new this(n))}},a9a1:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("5860"),c=n("2266");r({target:"Set",proto:!0,real:!0,forced:i},{some:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return c(n,(function(e,n){if(r(e,e,t))return n()}),{IS_ITERATOR:!0,INTERRUPTED:!0}).stopped}})},a9cd:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("59ed"),o=n("825a"),s=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{merge:function(e){var t=o(this),n=a(t.set),r=arguments.length,i=0;while(i<r)s(arguments[i++],n,{that:t,AS_ENTRIES:!0});return t}})},a9e3:function(e,t,n){"use strict";var r=n("83ab"),i=n("da84"),a=n("e330"),o=n("94ca"),s=n("6eeb"),c=n("1a2d"),u=n("7156"),l=n("3a9b"),f=n("d9b5"),h=n("c04e"),d=n("d039"),p=n("241c").f,v=n("06cf").f,m=n("9bf2").f,y=n("408a"),g=n("58a8").trim,b="Number",T=i[b],S=T.prototype,E=i.TypeError,_=a("".slice),k=a("".charCodeAt),w=function(e){var t=h(e,"number");return"bigint"==typeof t?t:A(t)},A=function(e){var t,n,r,i,a,o,s,c,u=h(e,"number");if(f(u))throw E("Cannot convert a Symbol value to a number");if("string"==typeof u&&u.length>2)if(u=g(u),t=k(u,0),43===t||45===t){if(n=k(u,2),88===n||120===n)return NaN}else if(48===t){switch(k(u,1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+u}for(a=_(u,2),o=a.length,s=0;s<o;s++)if(c=k(a,s),c<48||c>i)return NaN;return parseInt(a,r)}return+u};if(o(b,!T(" 0o1")||!T("0b1")||T("+0x1"))){for(var R,x=function(e){var t=arguments.length<1?0:T(w(e)),n=this;return l(S,n)&&d((function(){y(n)}))?u(Object(t),n,x):t},C=r?p(T):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),I=0;C.length>I;I++)c(T,R=C[I])&&!c(x,R)&&m(x,R,v(T,R));x.prototype=S,S.constructor=x,s(i,b,x)}},aa01:function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.toKey,s=i.set;r({target:"Reflect",stat:!0},{metadata:function(e,t){return function(n,r){s(e,t,a(n),o(r))}}})},aa1f:function(e,t,n){"use strict";var r=n("83ab"),i=n("d039"),a=n("825a"),o=n("7c73"),s=n("e391"),c=Error.prototype.toString,u=i((function(){if(r){var e=o(Object.defineProperty({},"name",{get:function(){return this===e}}));if("true"!==c.call(e))return!0}return"2: 1"!==c.call({message:1,name:2})||"Error"!==c.call({})}));e.exports=u?function(){var e=a(this),t=s(e.name,"Error"),n=s(e.message);return t?n?t+": "+n:t:n}:c},aaef:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){
|
|
22
|
+
/** @preserve
|
|
23
|
+
* Counter block mode compatible with Dr Brian Gladman fileenc.c
|
|
24
|
+
* derived from CryptoJS.mode.CTR
|
|
25
|
+
* Jan Hruby jhruby.web@gmail.com
|
|
26
|
+
*/
|
|
27
|
+
return e.mode.CTRGladman=function(){var t=e.lib.BlockCipherMode.extend();function n(e){if(255===(e>>24&255)){var t=e>>16&255,n=e>>8&255,r=255&e;255===t?(t=0,255===n?(n=0,255===r?r=0:++r):++n):++t,e=0,e+=t<<16,e+=n<<8,e+=r}else e+=1<<24;return e}function r(e){return 0===(e[0]=n(e[0]))&&(e[1]=n(e[1])),e}var i=t.Encryptor=t.extend({processBlock:function(e,t){var n=this._cipher,i=n.blockSize,a=this._iv,o=this._counter;a&&(o=this._counter=a.slice(0),this._iv=void 0),r(o);var s=o.slice(0);n.encryptBlock(s,0);for(var c=0;c<i;c++)e[t+c]^=s[c]}});return t.Decryptor=i,t}(),e.mode.CTRGladman}))},ab13:function(e,t,n){var r=n("b622"),i=r("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[i]=!1,"/./"[e](t)}catch(r){}}return!1}},ab36:function(e,t,n){var r=n("861d"),i=n("9112");e.exports=function(e,t){r(t)&&"cause"in t&&i(e,"cause",t.cause)}},ab3c:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("c65b"),o=n("825a"),s=n("f8cd"),c=n("c5cc"),u=c((function(e){var t,n,r=this.iterator,s=this.next;while(this.remaining)if(this.remaining--,t=o(a(s,r)),n=this.done=!!t.done,n)return;if(t=o(i(s,r,e)),n=this.done=!!t.done,!n)return t.value}));r({target:"Iterator",proto:!0,real:!0},{drop:function(e){return new u({iterator:o(this),remaining:s(e)})}})},ac16:function(e,t,n){var r=n("23e7"),i=n("825a"),a=n("06cf").f;r({target:"Reflect",stat:!0},{deleteProperty:function(e,t){var n=a(i(e),t);return!(n&&!n.configurable)&&delete e[t]}})},ac1f:function(e,t,n){"use strict";var r=n("23e7"),i=n("9263");r({target:"RegExp",proto:!0,forced:/./.exec!==i},{exec:i})},acac:function(e,t,n){"use strict";var r=n("e330"),i=n("e2cc"),a=n("f183").getWeakData,o=n("825a"),s=n("861d"),c=n("19aa"),u=n("2266"),l=n("b727"),f=n("1a2d"),h=n("69f3"),d=h.set,p=h.getterFor,v=l.find,m=l.findIndex,y=r([].splice),g=0,b=function(e){return e.frozen||(e.frozen=new T)},T=function(){this.entries=[]},S=function(e,t){return v(e.entries,(function(e){return e[0]===t}))};T.prototype={get:function(e){var t=S(this,e);if(t)return t[1]},has:function(e){return!!S(this,e)},set:function(e,t){var n=S(this,e);n?n[1]=t:this.entries.push([e,t])},delete:function(e){var t=m(this.entries,(function(t){return t[0]===e}));return~t&&y(this.entries,t,1),!!~t}},e.exports={getConstructor:function(e,t,n,r){var l=e((function(e,i){c(e,h),d(e,{type:t,id:g++,frozen:void 0}),void 0!=i&&u(i,e[r],{that:e,AS_ENTRIES:n})})),h=l.prototype,v=p(t),m=function(e,t,n){var r=v(e),i=a(o(t),!0);return!0===i?b(r).set(t,n):i[r.id]=n,e};return i(h,{delete:function(e){var t=v(this);if(!s(e))return!1;var n=a(e);return!0===n?b(t)["delete"](e):n&&f(n,t.id)&&delete n[t.id]},has:function(e){var t=v(this);if(!s(e))return!1;var n=a(e);return!0===n?b(t).has(e):n&&f(n,t.id)}}),i(h,n?{get:function(e){var t=v(this);if(s(e)){var n=a(e);return!0===n?b(t).get(e):n?n[t.id]:void 0}},set:function(e,t){return m(this,e,t)}}:{add:function(e){return m(this,e,!0)}}),l}}},accc:function(e,t,n){var r=n("23e7"),i=n("64e5");r({target:"Date",proto:!0,forced:Date.prototype.toISOString!==i},{toISOString:i})},acd8:function(e,t,n){var r=n("23e7"),i=n("7e12");r({global:!0,forced:parseFloat!=i},{parseFloat:i})},ace4:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("d039"),o=n("621a"),s=n("825a"),c=n("23cb"),u=n("50c4"),l=n("4840"),f=o.ArrayBuffer,h=o.DataView,d=h.prototype,p=i(f.prototype.slice),v=i(d.getUint8),m=i(d.setUint8),y=a((function(){return!new f(2).slice(1,void 0).byteLength}));r({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:y},{slice:function(e,t){if(p&&void 0===t)return p(s(this),e);var n=s(this).byteLength,r=c(e,n),i=c(void 0===t?n:t,n),a=new(l(this,f))(u(i-r)),o=new h(this),d=new h(a),y=0;while(r<i)m(d,y++,v(o,r++));return a}})},acef:function(e,t,n){n("907a")},ad02:function(e,t,n){var r=n("07fa"),i=n("23cb"),a=n("5926"),o=Math.max,s=Math.min;e.exports=function(e,t,n){var c,u,l,f,h=n[0],d=n[1],p=r(e),v=i(h,p),m=n.length,y=0;for(0===m?c=u=0:1===m?(c=0,u=p-v):(c=m-2,u=s(o(a(d),0),p-v)),l=p+c-u,f=new t(l);y<v;y++)f[y]=e[y];for(;y<v+c;y++)f[y]=n[y-v+2];for(;y<l;y++)f[y]=e[y+u-c];return f}},ad1f:function(e,t,n){var r=n("c430"),i=n("23e7"),a=n("da84"),o=n("d066"),s=n("e330"),c=n("d039"),u=n("90e3"),l=n("1626"),f=n("68ee"),h=n("861d"),d=n("d9b5"),p=n("2266"),v=n("825a"),m=n("f5df"),y=n("1a2d"),g=n("8418"),b=n("9112"),T=n("07fa"),S=n("d6d6"),E=n("ad6d"),_=n("b980"),k=a.Object,w=a.Date,A=a.Error,R=a.EvalError,x=a.RangeError,C=a.ReferenceError,I=a.SyntaxError,P=a.TypeError,O=a.URIError,D=a.PerformanceMark,U=a.WebAssembly,M=U&&U.CompileError||A,B=U&&U.LinkError||A,N=U&&U.RuntimeError||A,L=o("DOMException"),F=o("Set"),j=o("Map"),W=j.prototype,H=s(W.has),V=s(W.get),q=s(W.set),z=s(F.prototype.add),G=o("Object","keys"),Y=s([].push),K=s((!0).valueOf),X=s(1..valueOf),Q=s("".valueOf),$=s(E),Z=s(w.prototype.getTime),J=u("structuredClone"),ee="DataCloneError",te="Transferring",ne=function(e){return!c((function(){var t=new a.Set([7]),n=e(t),r=e(k(7));return n==t||!n.has(7)||"object"!=typeof r||7!=r}))&&e},re=function(e){return!c((function(){var t=e(new a.AggregateError([1],J,{cause:3}));return"AggregateError"!=t.name||1!=t.errors[0]||t.message!=J||3!=t.cause}))&&e},ie=a.structuredClone,ae=r||!re(ie),oe=!ie&&ne((function(e){return new D(J,{detail:e}).detail})),se=ne(ie)||oe,ce=function(e){throw new L("Uncloneable type: "+e,ee)},ue=function(e,t){throw new L((t||"Cloning")+" of "+e+" cannot be properly polyfilled in this engine",ee)},le=function(e,t){if(d(e)&&ce("Symbol"),!h(e))return e;if(t){if(H(t,e))return V(t,e)}else t=new j;var n,r,i,s,c,u,p,v,S,E,D=m(e),U=!1;switch(D){case"Array":i=[],U=!0;break;case"Object":i={},U=!0;break;case"Map":i=new j,U=!0;break;case"Set":i=new F,U=!0;break;case"RegExp":i=new RegExp(e.source,"flags"in e?e.flags:$(e));break;case"Error":switch(r=e.name,r){case"AggregateError":i=o("AggregateError")([]);break;case"EvalError":i=R();break;case"RangeError":i=x();break;case"ReferenceError":i=C();break;case"SyntaxError":i=I();break;case"TypeError":i=P();break;case"URIError":i=O();break;case"CompileError":i=M();break;case"LinkError":i=B();break;case"RuntimeError":i=N();break;default:i=A()}U=!0;break;case"DOMException":i=new L(e.message,e.name),U=!0;break;case"DataView":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"BigInt64Array":case"BigUint64Array":n=a[D],h(n)||ue(D),i=new n(le(e.buffer,t),e.byteOffset,"DataView"===D?e.byteLength:e.length);break;case"DOMQuad":try{i=new DOMQuad(le(e.p1,t),le(e.p2,t),le(e.p3,t),le(e.p4,t))}catch(W){se?i=se(e):ue(D)}break;case"FileList":if(n=a.DataTransfer,f(n)){for(s=new n,c=0,u=T(e);c<u;c++)s.items.add(le(e[c],t));i=s.files}else se?i=se(e):ue(D);break;case"ImageData":try{i=new ImageData(le(e.data,t),e.width,e.height,{colorSpace:e.colorSpace})}catch(W){se?i=se(e):ue(D)}break;default:if(se)i=se(e);else switch(D){case"BigInt":i=k(e.valueOf());break;case"Boolean":i=k(K(e));break;case"Number":i=k(X(e));break;case"String":i=k(Q(e));break;case"Date":i=new w(Z(e));break;case"ArrayBuffer":n=a.DataView,n||"function"==typeof e.slice||ue(D);try{if("function"==typeof e.slice)i=e.slice(0);else for(u=e.byteLength,i=new ArrayBuffer(u),S=new n(e),E=new n(i),c=0;c<u;c++)E.setUint8(c,S.getUint8(c))}catch(W){throw new L("ArrayBuffer is detached",ee)}break;case"SharedArrayBuffer":i=e;break;case"Blob":try{i=e.slice(0,e.size,e.type)}catch(W){ue(D)}break;case"DOMPoint":case"DOMPointReadOnly":n=a[D];try{i=n.fromPoint?n.fromPoint(e):new n(e.x,e.y,e.z,e.w)}catch(W){ue(D)}break;case"DOMRect":case"DOMRectReadOnly":n=a[D];try{i=n.fromRect?n.fromRect(e):new n(e.x,e.y,e.width,e.height)}catch(W){ue(D)}break;case"DOMMatrix":case"DOMMatrixReadOnly":n=a[D];try{i=n.fromMatrix?n.fromMatrix(e):new n(e)}catch(W){ue(D)}break;case"AudioData":case"VideoFrame":l(e.clone)||ue(D);try{i=e.clone()}catch(W){ce(D)}break;case"File":try{i=new File([e],e.name,e)}catch(W){ue(D)}break;case"CryptoKey":case"GPUCompilationMessage":case"GPUCompilationInfo":case"ImageBitmap":case"RTCCertificate":case"WebAssembly.Module":ue(D);default:ce(D)}}if(q(t,e,i),U)switch(D){case"Array":case"Object":for(p=G(e),c=0,u=T(p);c<u;c++)v=p[c],g(i,v,le(e[v],t));break;case"Map":e.forEach((function(e,n){q(i,le(n,t),le(e,t))}));break;case"Set":e.forEach((function(e){z(i,le(e,t))}));break;case"Error":b(i,"message",le(e.message,t)),y(e,"cause")&&b(i,"cause",le(e.cause,t)),"AggregateError"==r&&(i.errors=le(e.errors,t));case"DOMException":_&&b(i,"stack",le(e.stack,t))}return i},fe=ie&&!c((function(){var e=new ArrayBuffer(8),t=ie(e,{transfer:[e]});return 0!=e.byteLength||8!=t.byteLength})),he=function(e,t){if(!h(e))throw P("Transfer option cannot be converted to a sequence");var n=[];p(e,(function(e){Y(n,v(e))}));var r,i,o,s,c,u,d,y=0,g=T(n);if(fe){s=ie(n,{transfer:n});while(y<g)q(t,n[y],s[y++])}else while(y<g){if(r=n[y++],H(t,r))throw new L("Duplicate transferable",ee);switch(i=m(r),i){case"ImageBitmap":o=a.OffscreenCanvas,f(o)||ue(i,te);try{u=new o(r.width,r.height),d=u.getContext("bitmaprenderer"),d.transferFromImageBitmap(r),c=u.transferToImageBitmap()}catch(b){}break;case"AudioData":case"VideoFrame":l(r.clone)&&l(r.close)||ue(i,te);try{c=r.clone(),r.close()}catch(b){}break;case"ArrayBuffer":case"MessagePort":case"OffscreenCanvas":case"ReadableStream":case"TransformStream":case"WritableStream":ue(i,te)}if(void 0===c)throw new L("This object cannot be transferred: "+i,ee);q(t,r,c)}};i({global:!0,enumerable:!0,sham:!fe,forced:ae},{structuredClone:function(e){var t,n=S(arguments.length,1)>1?v(arguments[1]):void 0,r=n?n.transfer:void 0;return void 0!==r&&(t=new j,he(r,t)),le(e,t)}})},ad6d:function(e,t,n){"use strict";var r=n("825a");e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},ad9d:function(e,t,n){n("5b81")},adbd:function(e,t,n){var r=n("23e7"),i=n("3fde");r({target:"WeakSet",stat:!0},{of:i})},addb:function(e,t,n){var r=n("4dae"),i=Math.floor,a=function(e,t){var n=e.length,c=i(n/2);return n<8?o(e,t):s(e,a(r(e,0,c),t),a(r(e,c),t),t)},o=function(e,t){var n,r,i=e.length,a=1;while(a<i){r=a,n=e[a];while(r&&t(e[r-1],n)>0)e[r]=e[--r];r!==a++&&(e[r]=n)}return e},s=function(e,t,n,r){var i=t.length,a=n.length,o=0,s=0;while(o<i||s<a)e[o+s]=o<i&&s<a?r(t[o],n[s])<=0?t[o++]:n[s++]:o<i?t[o++]:n[s++];return e};e.exports=a},ae93:function(e,t,n){"use strict";var r,i,a,o=n("d039"),s=n("1626"),c=n("7c73"),u=n("e163"),l=n("6eeb"),f=n("b622"),h=n("c430"),d=f("iterator"),p=!1;[].keys&&(a=[].keys(),"next"in a?(i=u(u(a)),i!==Object.prototype&&(r=i)):p=!0);var v=void 0==r||o((function(){var e={};return r[d].call(e)!==e}));v?r={}:h&&(r=c(r)),s(r[d])||l(r,d,(function(){return this})),e.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:p}},aed9:function(e,t,n){var r=n("83ab"),i=n("d039");e.exports=r&&i((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},af03:function(e,t,n){var r=n("d039");e.exports=function(e){return r((function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}))}},af87:function(e,t,n){e.exports=n("9446")},af93:function(e,t,n){var r=n("23e7"),i=n("861d"),a=n("f183").onFreeze,o=n("bb2f"),s=n("d039"),c=Object.seal,u=s((function(){c(1)}));r({target:"Object",stat:!0,forced:u,sham:!o},{seal:function(e){return c&&i(e)?c(a(e)):e}})},aff5:function(e,t,n){var r=n("23e7");r({target:"Number",stat:!0},{MAX_SAFE_INTEGER:9007199254740991})},b041:function(e,t,n){"use strict";var r=n("00ee"),i=n("f5df");e.exports=r?{}.toString:function(){return"[object "+i(this)+"]"}},b0c0:function(e,t,n){var r=n("83ab"),i=n("5e77").EXISTS,a=n("e330"),o=n("9bf2").f,s=Function.prototype,c=a(s.toString),u=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,l=a(u.exec),f="name";r&&!i&&o(s,f,{configurable:!0,get:function(){try{return l(u,c(this))[1]}catch(e){return""}}})},b10f:function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.keys,s=i.toKey;r({target:"Reflect",stat:!0},{getOwnMetadataKeys:function(e){var t=arguments.length<2?void 0:s(arguments[1]);return o(a(e),t)}})},b24c:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("c5cc"),s=o((function(e){var t=a(i(this.next,this.iterator,e)),n=this.done=!!t.done;if(!n)return[this.index++,t.value]}));r({target:"Iterator",proto:!0,real:!0},{asIndexedPairs:function(){return new s({iterator:a(this),index:0})}})},b294:function(e,t,n){var r=n("23e7"),i=n("a98e");r({target:"WeakSet",stat:!0},{from:i})},b2ff:function(e,t,n){var r=n("23e7"),i=n("e330"),a=n("59ed");r({target:"Function",proto:!0},{unThis:function(){return i(a(this))}})},b38e:function(e,t,n){"use strict";var r=n("23e7"),i=n("d066"),a=n("0366"),o=n("e330"),s=n("44ad"),c=n("7b0b"),u=n("07fa"),l=n("44d2"),f=i("Map"),h=f.prototype,d=o(h.get),p=o(h.has),v=o(h.set),m=o([].push);r({target:"Array",proto:!0},{groupByToMap:function(e){for(var t,n,r=c(this),i=s(r),o=a(e,arguments.length>1?arguments[1]:void 0),l=new f,h=u(i),y=0;h>y;y++)n=i[y],t=o(n,y,r),p(l,t)?m(d(l,t),n):v(l,t,[n]);return l}}),l("groupByToMap")},b39a:function(e,t,n){"use strict";var r=n("da84"),i=n("2ba4"),a=n("ebb5"),o=n("d039"),s=n("f36a"),c=r.Int8Array,u=a.aTypedArray,l=a.exportTypedArrayMethod,f=[].toLocaleString,h=!!c&&o((function(){f.call(new c(1))})),d=o((function(){return[1,2].toLocaleString()!=new c([1,2]).toLocaleString()}))||!o((function(){c.prototype.toLocaleString.call([1,2])}));l("toLocaleString",(function(){return i(f,h?s(u(this)):u(this),s(arguments))}),d)},b420:function(e,t,n){var r=n("23e7"),i=n("621a"),a=n("a981");r({global:!0,forced:!a},{DataView:i.DataView})},b423:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("e9e0");r({target:"Map",proto:!0,real:!0,name:"upsert",forced:i},{updateOrInsert:a})},b50d:function(e,t,n){"use strict";var r=n("c532"),i=n("467f"),a=n("7aac"),o=n("30b5"),s=n("83b9"),c=n("c345"),u=n("3934"),l=n("2d83"),f=n("2444"),h=n("7a77");e.exports=function(e){return new Promise((function(t,n){var d,p=e.data,v=e.headers,m=e.responseType;function y(){e.cancelToken&&e.cancelToken.unsubscribe(d),e.signal&&e.signal.removeEventListener("abort",d)}r.isFormData(p)&&delete v["Content-Type"];var g=new XMLHttpRequest;if(e.auth){var b=e.auth.username||"",T=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";v.Authorization="Basic "+btoa(b+":"+T)}var S=s(e.baseURL,e.url);function E(){if(g){var r="getAllResponseHeaders"in g?c(g.getAllResponseHeaders()):null,a=m&&"text"!==m&&"json"!==m?g.response:g.responseText,o={data:a,status:g.status,statusText:g.statusText,headers:r,config:e,request:g};i((function(e){t(e),y()}),(function(e){n(e),y()}),o),g=null}}if(g.open(e.method.toUpperCase(),o(S,e.params,e.paramsSerializer),!0),g.timeout=e.timeout,"onloadend"in g?g.onloadend=E:g.onreadystatechange=function(){g&&4===g.readyState&&(0!==g.status||g.responseURL&&0===g.responseURL.indexOf("file:"))&&setTimeout(E)},g.onabort=function(){g&&(n(l("Request aborted",e,"ECONNABORTED",g)),g=null)},g.onerror=function(){n(l("Network Error",e,null,g)),g=null},g.ontimeout=function(){var t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",r=e.transitional||f.transitional;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(l(t,e,r.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",g)),g=null},r.isStandardBrowserEnv()){var _=(e.withCredentials||u(S))&&e.xsrfCookieName?a.read(e.xsrfCookieName):void 0;_&&(v[e.xsrfHeaderName]=_)}"setRequestHeader"in g&&r.forEach(v,(function(e,t){"undefined"===typeof p&&"content-type"===t.toLowerCase()?delete v[t]:g.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(g.withCredentials=!!e.withCredentials),m&&"json"!==m&&(g.responseType=e.responseType),"function"===typeof e.onDownloadProgress&&g.addEventListener("progress",e.onDownloadProgress),"function"===typeof e.onUploadProgress&&g.upload&&g.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(d=function(e){g&&(n(!e||e&&e.type?new h("canceled"):e),g.abort(),g=null)},e.cancelToken&&e.cancelToken.subscribe(d),e.signal&&(e.signal.aborted?d():e.signal.addEventListener("abort",d))),p||(p=null),g.send(p)}))}},b56e:function(e,t,n){"use strict";var r=n("1626"),i=n("861d"),a=n("9bf2"),o=n("e163"),s=n("b622"),c=s("hasInstance"),u=Function.prototype;c in u||a.f(u,c,{value:function(e){if(!r(this)||!i(e))return!1;var t=this.prototype;if(!i(t))return e instanceof this;while(e=o(e))if(t===e)return!0;return!1}})},b575:function(e,t,n){var r,i,a,o,s,c,u,l,f=n("da84"),h=n("0366"),d=n("06cf").f,p=n("2cf4").set,v=n("1cdc"),m=n("d4c3"),y=n("a4b4"),g=n("605d"),b=f.MutationObserver||f.WebKitMutationObserver,T=f.document,S=f.process,E=f.Promise,_=d(f,"queueMicrotask"),k=_&&_.value;k||(r=function(){var e,t;g&&(e=S.domain)&&e.exit();while(i){t=i.fn,i=i.next;try{t()}catch(n){throw i?o():a=void 0,n}}a=void 0,e&&e.enter()},v||g||y||!b||!T?!m&&E&&E.resolve?(u=E.resolve(void 0),u.constructor=E,l=h(u.then,u),o=function(){l(r)}):g?o=function(){S.nextTick(r)}:(p=h(p,f),o=function(){p(r)}):(s=!0,c=T.createTextNode(""),new b(r).observe(c,{characterData:!0}),o=function(){c.data=s=!s})),e.exports=k||function(e){var t={fn:e,next:void 0};a&&(a.next=t),i||(i=t,o()),a=t}},b622:function(e,t,n){var r=n("da84"),i=n("5692"),a=n("1a2d"),o=n("90e3"),s=n("4930"),c=n("fdbf"),u=i("wks"),l=r.Symbol,f=l&&l["for"],h=c?l:l&&l.withoutSetter||o;e.exports=function(e){if(!a(u,e)||!s&&"string"!=typeof u[e]){var t="Symbol."+e;s&&a(l,e)?u[e]=l[e]:u[e]=c&&f?f(t):h(t)}return u[e]}},b628:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("5860"),c=n("2266");r({target:"Set",proto:!0,real:!0,forced:i},{find:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return c(n,(function(e,n){if(r(e,e,t))return n(e)}),{IS_ITERATOR:!0,INTERRUPTED:!0}).result}})},b636:function(e,t,n){var r=n("746f");r("asyncIterator")},b639:function(e,t,n){"use strict";(function(e){
|
|
28
|
+
/*!
|
|
29
|
+
* The buffer module from node.js, for the browser.
|
|
30
|
+
*
|
|
31
|
+
* @author Feross Aboukhadijeh <http://feross.org>
|
|
32
|
+
* @license MIT
|
|
33
|
+
*/
|
|
34
|
+
var r=n("1fb5"),i=n("9152"),a=n("e3db");function o(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"===typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(t){return!1}}function s(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function c(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t),e.__proto__=u.prototype):(null===e&&(e=new u(t)),e.length=t),e}function u(e,t,n){if(!u.TYPED_ARRAY_SUPPORT&&!(this instanceof u))return new u(e,t,n);if("number"===typeof e){if("string"===typeof t)throw new Error("If encoding is specified then the first argument must be a string");return d(this,e)}return l(this,e,t,n)}function l(e,t,n,r){if("number"===typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!==typeof ArrayBuffer&&t instanceof ArrayBuffer?m(e,t,n,r):"string"===typeof t?p(e,t,n):y(e,t)}function f(e){if("number"!==typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function h(e,t,n,r){return f(t),t<=0?c(e,t):void 0!==n?"string"===typeof r?c(e,t).fill(n,r):c(e,t).fill(n):c(e,t)}function d(e,t){if(f(t),e=c(e,t<0?0:0|g(t)),!u.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function p(e,t,n){if("string"===typeof n&&""!==n||(n="utf8"),!u.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|T(t,n);e=c(e,r);var i=e.write(t,n);return i!==r&&(e=e.slice(0,i)),e}function v(e,t){var n=t.length<0?0:0|g(t.length);e=c(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function m(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");return t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r),u.TYPED_ARRAY_SUPPORT?(e=t,e.__proto__=u.prototype):e=v(e,t),e}function y(e,t){if(u.isBuffer(t)){var n=0|g(t.length);return e=c(e,n),0===e.length?e:(t.copy(e,0,0,n),e)}if(t){if("undefined"!==typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!==typeof t.length||te(t.length)?c(e,0):v(e,t);if("Buffer"===t.type&&a(t.data))return v(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function g(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function b(e){return+e!=e&&(e=0),u.alloc(+e)}function T(e,t){if(u.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return Q(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return J(e).length;default:if(r)return Q(e).length;t=(""+t).toLowerCase(),r=!0}}function S(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";e||(e="utf8");while(1)switch(e){case"hex":return N(this,t,n);case"utf8":case"utf-8":return O(this,t,n);case"ascii":return M(this,t,n);case"latin1":case"binary":return B(this,t,n);case"base64":return P(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function E(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function _(e,t,n,r,i){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"===typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:k(e,t,n,r,i);if("number"===typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):k(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function k(e,t,n,r,i){var a,o=1,s=e.length,c=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;o=2,s/=2,c/=2,n/=2}function u(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(i){var l=-1;for(a=n;a<s;a++)if(u(e,a)===u(t,-1===l?0:a-l)){if(-1===l&&(l=a),a-l+1===c)return l*o}else-1!==l&&(a-=a-l),l=-1}else for(n+c>s&&(n=s-c),a=n;a>=0;a--){for(var f=!0,h=0;h<c;h++)if(u(e,a+h)!==u(t,h)){f=!1;break}if(f)return a}return-1}function w(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;var a=t.length;if(a%2!==0)throw new TypeError("Invalid hex string");r>a/2&&(r=a/2);for(var o=0;o<r;++o){var s=parseInt(t.substr(2*o,2),16);if(isNaN(s))return o;e[n+o]=s}return o}function A(e,t,n,r){return ee(Q(t,e.length-n),e,n,r)}function R(e,t,n,r){return ee($(t),e,n,r)}function x(e,t,n,r){return R(e,t,n,r)}function C(e,t,n,r){return ee(J(t),e,n,r)}function I(e,t,n,r){return ee(Z(t,e.length-n),e,n,r)}function P(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function O(e,t,n){n=Math.min(e.length,n);var r=[],i=t;while(i<n){var a,o,s,c,u=e[i],l=null,f=u>239?4:u>223?3:u>191?2:1;if(i+f<=n)switch(f){case 1:u<128&&(l=u);break;case 2:a=e[i+1],128===(192&a)&&(c=(31&u)<<6|63&a,c>127&&(l=c));break;case 3:a=e[i+1],o=e[i+2],128===(192&a)&&128===(192&o)&&(c=(15&u)<<12|(63&a)<<6|63&o,c>2047&&(c<55296||c>57343)&&(l=c));break;case 4:a=e[i+1],o=e[i+2],s=e[i+3],128===(192&a)&&128===(192&o)&&128===(192&s)&&(c=(15&u)<<18|(63&a)<<12|(63&o)<<6|63&s,c>65535&&c<1114112&&(l=c))}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),i+=f}return U(r)}t.Buffer=u,t.SlowBuffer=b,t.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:o(),t.kMaxLength=s(),u.poolSize=8192,u._augment=function(e){return e.__proto__=u.prototype,e},u.from=function(e,t,n){return l(null,e,t,n)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!==typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(e,t,n){return h(null,e,t,n)},u.allocUnsafe=function(e){return d(null,e)},u.allocUnsafeSlow=function(e){return d(null,e)},u.isBuffer=function(e){return!(null==e||!e._isBuffer)},u.compare=function(e,t){if(!u.isBuffer(e)||!u.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,i=0,a=Math.min(n,r);i<a;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0},u.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(e,t){if(!a(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return u.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=u.allocUnsafe(t),i=0;for(n=0;n<e.length;++n){var o=e[n];if(!u.isBuffer(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(r,i),i+=o.length}return r},u.byteLength=T,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)E(this,t,t+1);return this},u.prototype.swap32=function(){var e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)E(this,t,t+3),E(this,t+1,t+2);return this},u.prototype.swap64=function(){var e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)E(this,t,t+7),E(this,t+1,t+6),E(this,t+2,t+5),E(this,t+3,t+4);return this},u.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?O(this,0,e):S.apply(this,arguments)},u.prototype.equals=function(e){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===u.compare(this,e)},u.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},u.prototype.compare=function(e,t,n,r,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;for(var a=i-r,o=n-t,s=Math.min(a,o),c=this.slice(r,i),l=e.slice(t,n),f=0;f<s;++f)if(c[f]!==l[f]){a=c[f],o=l[f];break}return a<o?-1:o<a?1:0},u.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},u.prototype.indexOf=function(e,t,n){return _(this,e,t,n,!0)},u.prototype.lastIndexOf=function(e,t,n){return _(this,e,t,n,!1)},u.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"===typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var i=this.length-t;if((void 0===n||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var a=!1;;)switch(r){case"hex":return w(this,e,t,n);case"utf8":case"utf-8":return A(this,e,t,n);case"ascii":return R(this,e,t,n);case"latin1":case"binary":return x(this,e,t,n);case"base64":return C(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,e,t,n);default:if(a)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),a=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var D=4096;function U(e){var t=e.length;if(t<=D)return String.fromCharCode.apply(String,e);var n="",r=0;while(r<t)n+=String.fromCharCode.apply(String,e.slice(r,r+=D));return n}function M(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(127&e[i]);return r}function B(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function N(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var i="",a=t;a<n;++a)i+=X(e[a]);return i}function L(e,t,n){for(var r=e.slice(t,n),i="",a=0;a<r.length;a+=2)i+=String.fromCharCode(r[a]+256*r[a+1]);return i}function F(e,t,n){if(e%1!==0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,n,r,i,a){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<a)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function W(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,a=Math.min(e.length-n,2);i<a;++i)e[n+i]=(t&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function H(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,a=Math.min(e.length-n,4);i<a;++i)e[n+i]=t>>>8*(r?i:3-i)&255}function V(e,t,n,r,i,a){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function q(e,t,n,r,a){return a||V(e,t,n,4,34028234663852886e22,-34028234663852886e22),i.write(e,t,n,r,23,4),n+4}function z(e,t,n,r,a){return a||V(e,t,n,8,17976931348623157e292,-17976931348623157e292),i.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if(e=~~e,t=void 0===t?r:~~t,e<0?(e+=r,e<0&&(e=0)):e>r&&(e=r),t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),t<e&&(t=e),u.TYPED_ARRAY_SUPPORT)n=this.subarray(e,t),n.__proto__=u.prototype;else{var i=t-e;n=new u(i,void 0);for(var a=0;a<i;++a)n[a]=this[a+e]}return n},u.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);var r=this[e],i=1,a=0;while(++a<t&&(i*=256))r+=this[e+a]*i;return r},u.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);var r=this[e+--t],i=1;while(t>0&&(i*=256))r+=this[e+--t]*i;return r},u.prototype.readUInt8=function(e,t){return t||F(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||F(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||F(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||F(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||F(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);var r=this[e],i=1,a=0;while(++a<t&&(i*=256))r+=this[e+a]*i;return i*=128,r>=i&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);var r=t,i=1,a=this[e+--r];while(r>0&&(i*=256))a+=this[e+--r]*i;return i*=128,a>=i&&(a-=Math.pow(2,8*t)),a},u.prototype.readInt8=function(e,t){return t||F(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||F(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||F(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||F(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||F(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||F(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||F(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||F(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||F(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t|=0,n|=0,!r){var i=Math.pow(2,8*n)-1;j(this,e,t,n,i,0)}var a=1,o=0;this[t]=255&e;while(++o<n&&(a*=256))this[t+o]=e/a&255;return t+n},u.prototype.writeUIntBE=function(e,t,n,r){if(e=+e,t|=0,n|=0,!r){var i=Math.pow(2,8*n)-1;j(this,e,t,n,i,0)}var a=n-1,o=1;this[t+a]=255&e;while(--a>=0&&(o*=256))this[t+a]=e/o&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):W(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):W(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):H(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):H(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);j(this,e,t,n,i-1,-i)}var a=0,o=1,s=0;this[t]=255&e;while(++a<n&&(o*=256))e<0&&0===s&&0!==this[t+a-1]&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);j(this,e,t,n,i-1,-i)}var a=n-1,o=1,s=0;this[t+a]=255&e;while(--a>=0&&(o*=256))e<0&&0===s&&0!==this[t+a+1]&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):W(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):W(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):H(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):H(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return q(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return q(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return z(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return z(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var i,a=r-n;if(this===e&&n<t&&t<r)for(i=a-1;i>=0;--i)e[i+t]=this[i+n];else if(a<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i<a;++i)e[i+t]=this[i+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+a),t);return a},u.prototype.fill=function(e,t,n,r){if("string"===typeof e){if("string"===typeof t?(r=t,t=0,n=this.length):"string"===typeof n&&(r=n,n=this.length),1===e.length){var i=e.charCodeAt(0);i<256&&(e=i)}if(void 0!==r&&"string"!==typeof r)throw new TypeError("encoding must be a string");if("string"===typeof r&&!u.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"===typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var a;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(a=t;a<n;++a)this[a]=e;else{var o=u.isBuffer(e)?e:Q(new u(e,r).toString()),s=o.length;for(a=0;a<n-t;++a)this[a+t]=o[a%s]}return this};var G=/[^+\/0-9A-Za-z-_]/g;function Y(e){if(e=K(e).replace(G,""),e.length<2)return"";while(e.length%4!==0)e+="=";return e}function K(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function X(e){return e<16?"0"+e.toString(16):e.toString(16)}function Q(e,t){var n;t=t||1/0;for(var r=e.length,i=null,a=[],o=0;o<r;++o){if(n=e.charCodeAt(o),n>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}if(o+1===r){(t-=3)>-1&&a.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return a}function $(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}function Z(e,t){for(var n,r,i,a=[],o=0;o<e.length;++o){if((t-=2)<0)break;n=e.charCodeAt(o),r=n>>8,i=n%256,a.push(i),a.push(r)}return a}function J(e){return r.toByteArray(Y(e))}function ee(e,t,n,r){for(var i=0;i<r;++i){if(i+n>=t.length||i>=e.length)break;t[i+n]=e[i]}return i}function te(e){return e!==e}}).call(this,n("c8ba"))},b64b:function(e,t,n){var r=n("23e7"),i=n("7b0b"),a=n("df75"),o=n("d039"),s=o((function(){a(1)}));r({target:"Object",stat:!0,forced:s},{keys:function(e){return a(i(e))}})},b65f:function(e,t,n){var r=n("23e7"),i=Math.ceil,a=Math.floor;r({target:"Math",stat:!0},{trunc:function(e){return(e>0?a:i)(e)}})},b680:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("5926"),s=n("408a"),c=n("1148"),u=n("d039"),l=i.RangeError,f=i.String,h=Math.floor,d=a(c),p=a("".slice),v=a(1..toFixed),m=function(e,t,n){return 0===t?n:t%2===1?m(e,t-1,n*e):m(e*e,t/2,n)},y=function(e){var t=0,n=e;while(n>=4096)t+=12,n/=4096;while(n>=2)t+=1,n/=2;return t},g=function(e,t,n){var r=-1,i=n;while(++r<6)i+=t*e[r],e[r]=i%1e7,i=h(i/1e7)},b=function(e,t){var n=6,r=0;while(--n>=0)r+=e[n],e[n]=h(r/t),r=r%t*1e7},T=function(e){var t=6,n="";while(--t>=0)if(""!==n||0===t||0!==e[t]){var r=f(e[t]);n=""===n?r:n+d("0",7-r.length)+r}return n},S=u((function(){return"0.000"!==v(8e-5,3)||"1"!==v(.9,0)||"1.25"!==v(1.255,2)||"1000000000000000128"!==v(0xde0b6b3a7640080,0)}))||!u((function(){v({})}));r({target:"Number",proto:!0,forced:S},{toFixed:function(e){var t,n,r,i,a=s(this),c=o(e),u=[0,0,0,0,0,0],h="",v="0";if(c<0||c>20)throw l("Incorrect fraction digits");if(a!=a)return"NaN";if(a<=-1e21||a>=1e21)return f(a);if(a<0&&(h="-",a=-a),a>1e-21)if(t=y(a*m(2,69,1))-69,n=t<0?a*m(2,-t,1):a/m(2,t,1),n*=4503599627370496,t=52-t,t>0){g(u,0,n),r=c;while(r>=7)g(u,1e7,0),r-=7;g(u,m(10,r,1),0),r=t-1;while(r>=23)b(u,1<<23),r-=23;b(u,1<<r),g(u,1,1),b(u,2),v=T(u)}else g(u,0,n),g(u,1<<-t,0),v=T(u)+d("0",c);return c>0?(i=v.length,v=h+(i<=c?"0."+d("0",c-i)+v:p(v,0,i-c)+"."+p(v,i-c))):v=h+v,v}})},b6b7:function(e,t,n){var r=n("ebb5"),i=n("4840"),a=r.TYPED_ARRAY_CONSTRUCTOR,o=r.aTypedArrayConstructor;e.exports=function(e){return o(i(e,e[a]))}},b727:function(e,t,n){var r=n("0366"),i=n("e330"),a=n("44ad"),o=n("7b0b"),s=n("07fa"),c=n("65f0"),u=i([].push),l=function(e){var t=1==e,n=2==e,i=3==e,l=4==e,f=6==e,h=7==e,d=5==e||f;return function(p,v,m,y){for(var g,b,T=o(p),S=a(T),E=r(v,m),_=s(S),k=0,w=y||c,A=t?w(p,_):n||h?w(p,0):void 0;_>k;k++)if((d||k in S)&&(g=S[k],b=E(g,k,T),e))if(t)A[k]=b;else if(b)switch(e){case 3:return!0;case 5:return g;case 6:return k;case 2:u(A,g)}else switch(e){case 4:return!1;case 7:u(A,g)}return f?-1:i||l?l:A}};e.exports={forEach:l(0),map:l(1),filter:l(2),some:l(3),every:l(4),find:l(5),findIndex:l(6),filterReject:l(7)}},b7ef:function(e,t,n){"use strict";var r=n("23e7"),i=n("d066"),a=n("5c6c"),o=n("9bf2").f,s=n("1a2d"),c=n("19aa"),u=n("7156"),l=n("e391"),f=n("cf98"),h=n("c770"),d=n("c430"),p="DOMException",v=i("Error"),m=i(p),y=function(){c(this,g);var e=arguments.length,t=l(e<1?void 0:arguments[0]),n=l(e<2?void 0:arguments[1],"Error"),r=new m(t,n),i=v(t);return i.name=p,o(r,"stack",a(1,h(i.stack,1))),u(r,this,y),r},g=y.prototype=m.prototype,b="stack"in v(p),T="stack"in new m(1,2),S=b&&!T;r({global:!0,forced:d||S},{DOMException:S?y:m});var E=i(p),_=E.prototype;if(_.constructor!==E)for(var k in d||o(_,"constructor",a(1,E)),f)if(s(f,k)){var w=f[k],A=w.s;s(E,A)||o(E,A,a(6,w.c))}},b86b:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("3252"),n("d6e6"))})(0,(function(e){return function(){var t=e,n=t.x64,r=n.Word,i=n.WordArray,a=t.algo,o=a.SHA512,s=a.SHA384=o.extend({_doReset:function(){this._hash=new i.init([new r.init(3418070365,3238371032),new r.init(1654270250,914150663),new r.init(2438529370,812702999),new r.init(355462360,4144912697),new r.init(1731405415,4290775857),new r.init(2394180231,1750603025),new r.init(3675008525,1694076839),new r.init(1203062813,3204075428)])},_doFinalize:function(){var e=o._doFinalize.call(this);return e.sigBytes-=16,e}});t.SHA384=o._createHelper(s),t.HmacSHA384=o._createHmacHelper(s)}(),e.SHA384}))},b86c:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.pad.NoPadding={pad:function(){},unpad:function(){}},e.pad.NoPadding}))},b881:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("e9e0");r({target:"Map",proto:!0,real:!0,forced:i},{upsert:a})},b8bf:function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("7c73");r({target:"Object",stat:!0,sham:!i},{create:a})},b968:function(e,t,n){var r=n("23e7"),i=Math.PI/180;r({target:"Math",stat:!0},{radians:function(e){return e*i}})},b980:function(e,t,n){var r=n("d039"),i=n("5c6c");e.exports=!r((function(){var e=Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",i(1,7)),7!==e.stack)}))},ba74:function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b"),a=n("2266"),o=n("59ed");r({target:"Map",stat:!0},{keyBy:function(e,t){var n=new this;o(t);var r=o(n.set);return a(e,(function(e){i(r,n,t(e),e)})),n}})},baa5:function(e,t,n){var r=n("23e7"),i=n("e58c");r({target:"Array",proto:!0,forced:i!==[].lastIndexOf},{lastIndexOf:i})},bb2f:function(e,t,n){var r=n("d039");e.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},bc01:function(e,t,n){var r=n("23e7"),i=n("d039"),a=Math.imul,o=i((function(){return-5!=a(4294967295,5)||2!=a.length}));r({target:"Math",stat:!0,forced:o},{imul:function(e,t){var n=65535,r=+e,i=+t,a=n&r,o=n&i;return 0|a*o+((n&r>>>16)*o+a*(n&i>>>16)<<16>>>0)}})},bc3a:function(e,t,n){e.exports=n("cee4")},bd98:function(e,t,n){var r=n("23e7"),i=n("e330"),a=n("783c"),o=n("825a"),s=n("e163"),c=n("4673"),u=i(c),l=i([].concat),f=a.keys,h=a.toKey,d=function(e,t){var n=f(e,t),r=s(e);if(null===r)return n;var i=d(r,t);return i.length?n.length?u(l(n,i)):i:n};r({target:"Reflect",stat:!0},{getMetadataKeys:function(e){var t=arguments.length<2?void 0:h(arguments[1]);return d(o(e),t)}})},bdd4:function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{DEG_PER_RAD:Math.PI/180})},be8c:function(e,t){e.exports=Math.scale||function(e,t,n,r,i){var a=+e,o=+t,s=+n,c=+r,u=+i;return a!=a||o!=o||s!=s||c!=c||u!=u?NaN:a===1/0||a===-1/0?a:(a-o)*(u-c)/(s-o)+c}},be8e:function(e,t,n){var r=n("f748"),i=Math.abs,a=Math.pow,o=a(2,-52),s=a(2,-23),c=a(2,127)*(2-s),u=a(2,-126),l=function(e){return e+1/o-1/o};e.exports=Math.fround||function(e){var t,n,a=i(e),f=r(e);return a<u?f*l(a/u/s)*u*s:(t=(1+s/o)*a,n=t-(t-a),n>c||n!=n?f*(1/0):f*n)}},bf19:function(e,t,n){"use strict";var r=n("23e7"),i=n("c65b");r({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return i(URL.prototype.toString,this)}})},bf3c:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("5926"),s=n("c20d"),c="Invalid number representation",u="Invalid radix",l=i.RangeError,f=i.SyntaxError,h=i.TypeError,d=/^[\da-z]+$/,p=a("".charAt),v=a(d.exec),m=a(1..toString),y=a("".slice);r({target:"Number",stat:!0},{fromString:function(e,t){var n,r,i=1;if("string"!=typeof e)throw h(c);if(!e.length)throw f(c);if("-"==p(e,0)&&(i=-1,e=y(e,1),!e.length))throw f(c);if(n=void 0===t?10:o(t),n<2||n>36)throw l(u);if(!v(d,e)||m(r=s(e,n),n)!==e)throw f(c);return i*r}})},bf96:function(e,t,n){"use strict";var r=n("23e7"),i=n("83ab"),a=n("eb1d"),o=n("7b0b"),s=n("a04b"),c=n("e163"),u=n("06cf").f;i&&r({target:"Object",proto:!0,forced:a},{__lookupGetter__:function(e){var t,n=o(this),r=s(e);do{if(t=u(n,r))return t.get}while(n=c(n))}})},bffa:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("2713");r({target:"Map",proto:!0,real:!0,forced:i},{emplace:a})},c04e:function(e,t,n){var r=n("da84"),i=n("c65b"),a=n("861d"),o=n("d9b5"),s=n("dc4a"),c=n("485a"),u=n("b622"),l=r.TypeError,f=u("toPrimitive");e.exports=function(e,t){if(!a(e)||o(e))return e;var n,r=s(e,f);if(r){if(void 0===t&&(t="default"),n=i(r,e,t),!a(n)||o(n))return n;throw l("Can't convert object to primitive value")}return void 0===t&&(t="number"),c(e,t)}},c0b6:function(e,t,n){var r=n("23e7"),i=n("0538");r({target:"Function",proto:!0,forced:Function.bind!==i},{bind:i})},c198:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("1132"),n("72fe"),n("2b79"),n("38ba"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.BlockCipher,i=t.algo,a=[],o=[],s=[],c=[],u=[],l=[],f=[],h=[],d=[],p=[];(function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;var n=0,r=0;for(t=0;t<256;t++){var i=r^r<<1^r<<2^r<<3^r<<4;i=i>>>8^255&i^99,a[n]=i,o[i]=n;var v=e[n],m=e[v],y=e[m],g=257*e[i]^16843008*i;s[n]=g<<24|g>>>8,c[n]=g<<16|g>>>16,u[n]=g<<8|g>>>24,l[n]=g;g=16843009*y^65537*m^257*v^16843008*n;f[i]=g<<24|g>>>8,h[i]=g<<16|g>>>16,d[i]=g<<8|g>>>24,p[i]=g,n?(n=v^e[e[e[y^v]]],r^=e[e[r]]):n=r=1}})();var v=[0,1,2,4,8,16,32,64,128,27,54],m=i.AES=r.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var e=this._keyPriorReset=this._key,t=e.words,n=e.sigBytes/4,r=this._nRounds=n+6,i=4*(r+1),o=this._keySchedule=[],s=0;s<i;s++)s<n?o[s]=t[s]:(l=o[s-1],s%n?n>6&&s%n==4&&(l=a[l>>>24]<<24|a[l>>>16&255]<<16|a[l>>>8&255]<<8|a[255&l]):(l=l<<8|l>>>24,l=a[l>>>24]<<24|a[l>>>16&255]<<16|a[l>>>8&255]<<8|a[255&l],l^=v[s/n|0]<<24),o[s]=o[s-n]^l);for(var c=this._invKeySchedule=[],u=0;u<i;u++){s=i-u;if(u%4)var l=o[s];else l=o[s-4];c[u]=u<4||s<=4?l:f[a[l>>>24]]^h[a[l>>>16&255]]^d[a[l>>>8&255]]^p[a[255&l]]}}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,s,c,u,l,a)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,f,h,d,p,o);n=e[t+1];e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,r,i,a,o,s){for(var c=this._nRounds,u=e[t]^n[0],l=e[t+1]^n[1],f=e[t+2]^n[2],h=e[t+3]^n[3],d=4,p=1;p<c;p++){var v=r[u>>>24]^i[l>>>16&255]^a[f>>>8&255]^o[255&h]^n[d++],m=r[l>>>24]^i[f>>>16&255]^a[h>>>8&255]^o[255&u]^n[d++],y=r[f>>>24]^i[h>>>16&255]^a[u>>>8&255]^o[255&l]^n[d++],g=r[h>>>24]^i[u>>>16&255]^a[l>>>8&255]^o[255&f]^n[d++];u=v,l=m,f=y,h=g}v=(s[u>>>24]<<24|s[l>>>16&255]<<16|s[f>>>8&255]<<8|s[255&h])^n[d++],m=(s[l>>>24]<<24|s[f>>>16&255]<<16|s[h>>>8&255]<<8|s[255&u])^n[d++],y=(s[f>>>24]<<24|s[h>>>16&255]<<16|s[u>>>8&255]<<8|s[255&l])^n[d++],g=(s[h>>>24]<<24|s[u>>>16&255]<<16|s[l>>>8&255]<<8|s[255&f])^n[d++];e[t]=v,e[t+1]=m,e[t+2]=y,e[t+3]=g},keySize:8});t.AES=r._createHelper(m)}(),e.AES}))},c19f:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("621a"),o=n("2626"),s="ArrayBuffer",c=a[s],u=i[s];r({global:!0,forced:u!==c},{ArrayBuffer:c}),o(s)},c1ac:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").filter,a=n("1448"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("filter",(function(e){var t=i(o(this),e,arguments.length>1?arguments[1]:void 0);return a(this,t)}))},c1bc:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=t.enc;i.Base64url={stringify:function(e,t=!0){var n=e.words,r=e.sigBytes,i=t?this._safe_map:this._map;e.clamp();for(var a=[],o=0;o<r;o+=3)for(var s=n[o>>>2]>>>24-o%4*8&255,c=n[o+1>>>2]>>>24-(o+1)%4*8&255,u=n[o+2>>>2]>>>24-(o+2)%4*8&255,l=s<<16|c<<8|u,f=0;f<4&&o+.75*f<r;f++)a.push(i.charAt(l>>>6*(3-f)&63));var h=i.charAt(64);if(h)while(a.length%4)a.push(h);return a.join("")},parse:function(e,t=!0){var n=e.length,r=t?this._safe_map:this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o<r.length;o++)i[r.charCodeAt(o)]=o}var s=r.charAt(64);if(s){var c=e.indexOf(s);-1!==c&&(n=c)}return a(e,n,i)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function a(e,t,n){for(var i=[],a=0,o=0;o<t;o++)if(o%4){var s=n[e.charCodeAt(o-1)]<<o%4*2,c=n[e.charCodeAt(o)]>>>6-o%4*2,u=s|c;i[a>>>2]|=u<<24-a%4*8,a++}return r.create(i,a)}}(),e.enc.Base64url}))},c1f9:function(e,t,n){var r=n("23e7"),i=n("2266"),a=n("8418");r({target:"Object",stat:!0},{fromEntries:function(e){var t={};return i(e,(function(e,n){a(t,e,n)}),{AS_ENTRIES:!0}),t}})},c206:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("0a0d");r({target:"Map",proto:!0,real:!0,forced:i},{deleteAll:a})},c20d:function(e,t,n){var r=n("da84"),i=n("d039"),a=n("e330"),o=n("577e"),s=n("58a8").trim,c=n("5899"),u=r.parseInt,l=r.Symbol,f=l&&l.iterator,h=/^[+-]?0x/i,d=a(h.exec),p=8!==u(c+"08")||22!==u(c+"0x16")||f&&!i((function(){u(Object(f))}));e.exports=p?function(e,t){var n=s(o(e));return u(n,t>>>0||(d(h,n)?16:10))}:u},c2bc:function(e,t,n){"use strict";var r=n("23e7"),i=n("a258").findLast,a=n("44d2");r({target:"Array",proto:!0},{findLast:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a("findLast")},c345:function(e,t,n){"use strict";var r=n("c532"),i=["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"];e.exports=function(e){var t,n,a,o={};return e?(r.forEach(e.split("\n"),(function(e){if(a=e.indexOf(":"),t=r.trim(e.substr(0,a)).toLowerCase(),n=r.trim(e.substr(a+1)),t){if(o[t]&&i.indexOf(t)>=0)return;o[t]="set-cookie"===t?(o[t]?o[t]:[]).concat([n]):o[t]?o[t]+", "+n:n}})),o):o}},c35a:function(e,t,n){var r=n("23e7"),i=n("7e12");r({target:"Number",stat:!0,forced:Number.parseFloat!=i},{parseFloat:i})},c3b6:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("1132"),n("72fe"),n("2b79"),n("38ba"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.StreamCipher,i=t.algo,a=i.RC4=r.extend({_doReset:function(){for(var e=this._key,t=e.words,n=e.sigBytes,r=this._S=[],i=0;i<256;i++)r[i]=i;i=0;for(var a=0;i<256;i++){var o=i%n,s=t[o>>>2]>>>24-o%4*8&255;a=(a+r[i]+s)%256;var c=r[i];r[i]=r[a],r[a]=c}this._i=this._j=0},_doProcessBlock:function(e,t){e[t]^=o.call(this)},keySize:8,ivSize:0});function o(){for(var e=this._S,t=this._i,n=this._j,r=0,i=0;i<4;i++){t=(t+1)%256,n=(n+e[t])%256;var a=e[t];e[t]=e[n],e[n]=a,r|=e[(e[t]+e[n])%256]<<24-8*i}return this._i=t,this._j=n,r}t.RC4=r._createHelper(a);var s=i.RC4Drop=a.extend({cfg:a.cfg.extend({drop:192}),_doReset:function(){a._doReset.call(this);for(var e=this.cfg.drop;e>0;e--)o.call(this)}});t.RC4Drop=r._createHelper(s)}(),e.RC4}))},c3bb:function(e,t,n){var r=n("23e7");r({target:"Math",stat:!0},{RAD_PER_DEG:180/Math.PI})},c401:function(e,t,n){"use strict";var r=n("c532"),i=n("2444");e.exports=function(e,t,n){var a=this||i;return r.forEach(n,(function(n){e=n.call(a,e,t)})),e}},c430:function(e,t){e.exports=!1},c532:function(e,t,n){"use strict";var r=n("1d2b"),i=Object.prototype.toString;function a(e){return"[object Array]"===i.call(e)}function o(e){return"undefined"===typeof e}function s(e){return null!==e&&!o(e)&&null!==e.constructor&&!o(e.constructor)&&"function"===typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function c(e){return"[object ArrayBuffer]"===i.call(e)}function u(e){return"undefined"!==typeof FormData&&e instanceof FormData}function l(e){var t;return t="undefined"!==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer,t}function f(e){return"string"===typeof e}function h(e){return"number"===typeof e}function d(e){return null!==e&&"object"===typeof e}function p(e){if("[object Object]"!==i.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function v(e){return"[object Date]"===i.call(e)}function m(e){return"[object File]"===i.call(e)}function y(e){return"[object Blob]"===i.call(e)}function g(e){return"[object Function]"===i.call(e)}function b(e){return d(e)&&g(e.pipe)}function T(e){return"undefined"!==typeof URLSearchParams&&e instanceof URLSearchParams}function S(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function E(){return("undefined"===typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!==typeof window&&"undefined"!==typeof document)}function _(e,t){if(null!==e&&"undefined"!==typeof e)if("object"!==typeof e&&(e=[e]),a(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.call(null,e[i],i,e)}function k(){var e={};function t(t,n){p(e[n])&&p(t)?e[n]=k(e[n],t):p(t)?e[n]=k({},t):a(t)?e[n]=t.slice():e[n]=t}for(var n=0,r=arguments.length;n<r;n++)_(arguments[n],t);return e}function w(e,t,n){return _(t,(function(t,i){e[i]=n&&"function"===typeof t?r(t,n):t})),e}function A(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e}e.exports={isArray:a,isArrayBuffer:c,isBuffer:s,isFormData:u,isArrayBufferView:l,isString:f,isNumber:h,isObject:d,isPlainObject:p,isUndefined:o,isDate:v,isFile:m,isBlob:y,isFunction:g,isStream:b,isURLSearchParams:T,isStandardBrowserEnv:E,forEach:_,merge:k,extend:w,trim:S,stripBOM:A}},c5cc:function(e,t,n){"use strict";var r=n("c65b"),i=n("59ed"),a=n("825a"),o=n("7c73"),s=n("9112"),c=n("e2cc"),u=n("b622"),l=n("69f3"),f=n("dc4a"),h=n("ae93").IteratorPrototype,d="IteratorProxy",p=l.set,v=l.getterFor(d),m=u("toStringTag");e.exports=function(e,t){var n=function(e){e.type=d,e.next=i(e.iterator.next),e.done=!1,e.ignoreArg=!t,p(this,e)};return n.prototype=c(o(h),{next:function(n){var i=v(this),a=arguments.length?[i.ignoreArg?void 0:n]:t?[]:[void 0];i.ignoreArg=!1;var o=i.done?void 0:r(e,i,a);return{done:i.done,value:o}},return:function(e){var t=v(this),n=t.iterator;t.done=!0;var i=f(n,"return");return{done:!0,value:i?a(r(i,n,e)).value:e}},throw:function(e){var t=v(this),n=t.iterator;t.done=!0;var i=f(n,"throw");if(i)return r(i,n,e);throw e}}),t||s(n.prototype,m,"Generator"),n}},c5d0:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("italics")},{italics:function(){return i(this,"i","","")}})},c607:function(e,t,n){var r=n("da84"),i=n("83ab"),a=n("fce3"),o=n("c6b6"),s=n("9bf2").f,c=n("69f3").get,u=RegExp.prototype,l=r.TypeError;i&&a&&s(u,"dotAll",{configurable:!0,get:function(){if(this!==u){if("RegExp"===o(this))return!!c(this).dotAll;throw l("Incompatible receiver, RegExp required")}}})},c60d:function(e,t,n){var r=n("1a2d");e.exports=function(e){return void 0!==e&&(r(e,"value")||r(e,"writable"))}},c65b:function(e,t,n){var r=n("40d5"),i=Function.prototype.call;e.exports=r?i.bind(i):function(){return i.apply(i,arguments)}},c6b6:function(e,t,n){var r=n("e330"),i=r({}.toString),a=r("".slice);e.exports=function(e){return a(i(e),8,-1)}},c6cd:function(e,t,n){var r=n("da84"),i=n("ce4e"),a="__core-js_shared__",o=r[a]||i(a,{});e.exports=o},c6e3:function(e,t,n){"use strict";var r=n("d429"),i=n("ebb5"),a=i.aTypedArray,o=i.exportTypedArrayMethod,s=i.TYPED_ARRAY_CONSTRUCTOR;o("with",{with:function(e,t){return r(a(this),this[s],e,t)}}["with"])},c740:function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").findIndex,a=n("44d2"),o="findIndex",s=!0;o in[]&&Array(1)[o]((function(){s=!1})),r({target:"Array",proto:!0,forced:s},{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a(o)},c760:function(e,t,n){var r=n("23e7");r({target:"Reflect",stat:!0},{has:function(e,t){return t in e}})},c770:function(e,t,n){var r=n("e330"),i=r("".replace),a=function(e){return String(Error(e).stack)}("zxcasd"),o=/\n\s*at [^:]*:[^\n]*/,s=o.test(a);e.exports=function(e,t){if(s&&"string"==typeof e)while(t--)e=i(e,o,"");return e}},c7cd:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("fixed")},{fixed:function(){return i(this,"tt","","")}})},c877:function(e,t,n){"use strict";var r=n("23e7"),i=n("c885");r({target:"Object",stat:!0},{iterateKeys:function(e){return new i(e,"keys")}})},c885:function(e,t,n){"use strict";var r=n("69f3"),i=n("9ed3"),a=n("1a2d"),o=n("df75"),s=n("7b0b"),c="Object Iterator",u=r.set,l=r.getterFor(c);e.exports=i((function(e,t){var n=s(e);u(this,{type:c,mode:t,object:n,keys:o(n),index:0})}),"Object",(function(){var e=l(this),t=e.keys;while(1){if(null===t||e.index>=t.length)return e.object=e.keys=null,{value:void 0,done:!0};var n=t[e.index++],r=e.object;if(a(r,n)){switch(e.mode){case"keys":return{value:n,done:!1};case"values":return{value:r[n],done:!1}}return{value:[n,r[n]],done:!1}}}}))},c8af:function(e,t,n){"use strict";var r=n("c532");e.exports=function(e,t){r.forEach(e,(function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])}))}},c8ba:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},c8d2:function(e,t,n){var r=n("5e77").PROPER,i=n("d039"),a=n("5899"),o="
";e.exports=function(e){return i((function(){return!!a[e]()||o[e]()!==o||r&&a[e].name!==e}))}},c906:function(e,t,n){var r=n("23e7"),i=n("4fad");r({target:"Object",stat:!0,forced:Object.isExtensible!==i},{isExtensible:i})},c96a:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("small")},{small:function(){return i(this,"small","","")}})},c975:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("4d64").indexOf,o=n("a640"),s=i([].indexOf),c=!!s&&1/s([1],1,-0)<0,u=o("indexOf");r({target:"Array",proto:!0,forced:c||!u},{indexOf:function(e){var t=arguments.length>1?arguments[1]:void 0;return c?s(this,e,t)||0:a(this,e,t)}})},ca21:function(e,t,n){var r=n("23e7"),i=n("1ec1");r({target:"Math",stat:!0},{log1p:i})},ca84:function(e,t,n){var r=n("e330"),i=n("1a2d"),a=n("fc6a"),o=n("4d64").indexOf,s=n("d012"),c=r([].push);e.exports=function(e,t){var n,r=a(e),u=0,l=[];for(n in r)!i(s,n)&&i(r,n)&&c(l,n);while(t.length>u)i(r,n=t[u++])&&(~o(l,n)||c(l,n));return l}},ca91:function(e,t,n){"use strict";var r=n("ebb5"),i=n("d58f").left,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("reduce",(function(e){var t=arguments.length;return i(a(this),e,t,t>1?arguments[1]:void 0)}))},caad:function(e,t,n){"use strict";var r=n("23e7"),i=n("4d64").includes,a=n("44d2");r({target:"Array",proto:!0},{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a("includes")},cb29:function(e,t,n){var r=n("23e7"),i=n("81d5"),a=n("44d2");r({target:"Array",proto:!0},{fill:i}),a("fill")},cbc8:function(e,t,n){"use strict";var r=n("23e7"),i=n("2266"),a=n("825a"),o=[].push;r({target:"Iterator",proto:!0,real:!0},{toArray:function(){var e=[];return i(a(this),o,{that:e,IS_ITERATOR:!0}),e}})},cc12:function(e,t,n){var r=n("da84"),i=n("861d"),a=r.document,o=i(a)&&i(a.createElement);e.exports=function(e){return o?a.createElement(e):{}}},cc71:function(e,t,n){"use strict";var r=n("23e7"),i=n("857a"),a=n("af03");r({target:"String",proto:!0,forced:a("bold")},{bold:function(){return i(this,"b","","")}})},cca6:function(e,t,n){var r=n("23e7"),i=n("60da");r({target:"Object",stat:!0,forced:Object.assign!==i},{assign:i})},cd1a:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("c65b"),o=n("59ed"),s=n("825a"),c=n("35a1"),u=n("c5cc"),l=n("2a62"),f=i.TypeError,h=u((function(){var e,t,n,r,i=this.iterator,u=this.mapper;while(1)try{if(r=this.innerIterator){if(e=s(a(this.innerNext,r)),!e.done)return e.value;this.innerIterator=this.innerNext=null}if(e=s(a(this.next,i)),this.done=!!e.done)return;if(t=u(e.value),n=c(t),!n)throw f(".flatMap callback should return an iterable object");this.innerIterator=r=s(a(n,t)),this.innerNext=o(r.next)}catch(h){l(i,"throw",h)}}));r({target:"Iterator",proto:!0,real:!0},{flatMap:function(e){return new h({iterator:s(this),mapper:o(e),innerIterator:null,innerNext:null})}})},cd26:function(e,t,n){"use strict";var r=n("ebb5"),i=r.aTypedArray,a=r.exportTypedArrayMethod,o=Math.floor;a("reverse",(function(){var e,t=this,n=i(t).length,r=o(n/2),a=0;while(a<r)e=t[a],t[a++]=t[--n],t[n]=e;return t}))},cd7c:function(e,t,n){"use strict";var r=n("ebb5"),i=n("a4f2"),a=n("b6b7"),o=r.aTypedArray,s=r.exportTypedArrayMethod;s("groupBy",(function(e){var t=arguments.length>1?arguments[1]:void 0;return i(o(this),e,t,a)}))},cdf9:function(e,t,n){var r=n("825a"),i=n("861d"),a=n("f069");e.exports=function(e,t){if(r(e),i(t)&&t.constructor===e)return t;var n=a.f(e),o=n.resolve;return o(t),n.promise}},ce4e:function(e,t,n){var r=n("da84"),i=Object.defineProperty;e.exports=function(e,t){try{i(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},ce8c:function(e,t,n){"use strict";var r=n("23e7"),i=n("c885");r({target:"Object",stat:!0},{iterateEntries:function(e){return new i(e,"entries")}})},cee4:function(e,t,n){"use strict";var r=n("c532"),i=n("1d2b"),a=n("0a06"),o=n("4a7b"),s=n("2444");function c(e){var t=new a(e),n=i(a.prototype.request,t);return r.extend(n,a.prototype,t),r.extend(n,t),n.create=function(t){return c(o(e,t))},n}var u=c(s);u.Axios=a,u.Cancel=n("7a77"),u.CancelToken=n("8df4"),u.isCancel=n("2e67"),u.VERSION=n("5cce").version,u.all=function(e){return Promise.all(e)},u.spread=n("0df6"),u.isAxiosError=n("5f02"),e.exports=u,e.exports.default=u},cee8:function(e,t,n){var r=n("23e7"),i=n("861d"),a=n("f183").onFreeze,o=n("bb2f"),s=n("d039"),c=Object.preventExtensions,u=s((function(){c(1)}));r({target:"Object",stat:!0,forced:u,sham:!o},{preventExtensions:function(e){return c&&i(e)?c(a(e)):e}})},ceef:function(e,t,n){var r=n("23e7"),i=n("a98e");r({target:"Map",stat:!0},{from:i})},cf98:function(e,t){e.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},cfc3:function(e,t,n){var r=n("74e8");r("Float32",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},d012:function(e,t){e.exports={}},d039:function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},d066:function(e,t,n){var r=n("da84"),i=n("1626"),a=function(e){return i(e)?e:void 0};e.exports=function(e,t){return arguments.length<2?a(r[e]):r[e]&&r[e][t]}},d139:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").find,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("find",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},d195:function(e,t,n){"use strict";var r=n("c65b"),i=n("59ed"),a=n("825a"),o=n("7c73"),s=n("9112"),c=n("e2cc"),u=n("b622"),l=n("69f3"),f=n("d066"),h=n("dc4a"),d=n("a91f"),p=f("Promise"),v="AsyncIteratorProxy",m=l.set,y=l.getterFor(v),g=u("toStringTag");e.exports=function(e,t){var n=function(e){e.type=v,e.next=i(e.iterator.next),e.done=!1,e.ignoreArgument=!t,m(this,e)};return n.prototype=c(o(d),{next:function(n){var i=this,o=!!arguments.length;return new p((function(s){var c=y(i),u=o?[c.ignoreArgument?void 0:n]:t?[]:[void 0];c.ignoreArgument=!1,s(c.done?{done:!0,value:void 0}:a(r(e,c,p,u)))}))},return:function(e){var t=this;return new p((function(n,i){var o=y(t),s=o.iterator;o.done=!0;var c=h(s,"return");if(void 0===c)return n({done:!0,value:e});p.resolve(r(c,s,e)).then((function(t){a(t),n({done:!0,value:e})}),i)}))},throw:function(e){var t=this;return new p((function(n,i){var a=y(t),o=a.iterator;a.done=!0;var s=h(o,"throw");if(void 0===s)return i(e);n(r(s,o,e))}))}}),t||s(n.prototype,g,"Generator"),n}},d1ba:function(e,t,n){var r=n("23e7");r({target:"Date",proto:!0},{toGMTString:Date.prototype.toUTCString})},d1e7:function(e,t,n){"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,a=i&&!r.call({1:2},1);t.f=a?function(e){var t=i(this,e);return!!t&&t.enumerable}:r},d28b:function(e,t,n){var r=n("746f");r("iterator")},d2af:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("825a"),o=n("0366"),s=n("4acb"),c=n("2266");r({target:"Map",proto:!0,real:!0,forced:i},{find:function(e){var t=a(this),n=s(t),r=o(e,arguments.length>1?arguments[1]:void 0);return c(n,(function(e,n,i){if(r(n,e,t))return i(n)}),{AS_ENTRIES:!0,IS_ITERATOR:!0,INTERRUPTED:!0}).result}})},d2bb:function(e,t,n){var r=n("e330"),i=n("825a"),a=n("3bbe");e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{e=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set),e(n,[]),t=n instanceof Array}catch(o){}return function(n,r){return i(n),a(r),t?e(n,r):n.__proto__=r,n}}():void 0)},d3b7:function(e,t,n){var r=n("00ee"),i=n("6eeb"),a=n("b041");r||i(Object.prototype,"toString",a,{unsafe:!0})},d401:function(e,t,n){var r=n("6eeb"),i=n("aa1f"),a=Error.prototype;a.toString!==i&&r(a,"toString",i)},d429:function(e,t,n){var r=n("da84"),i=n("07fa"),a=n("5926"),o=r.RangeError;e.exports=function(e,t,n,r){var s=i(e),c=a(n),u=c<0?s+c:c;if(u>=s||u<0)throw o("Incorrect index");for(var l=new t(s),f=0;f<s;f++)l[f]=f===u?r:e[f];return l}},d44e:function(e,t,n){var r=n("9bf2").f,i=n("1a2d"),a=n("b622"),o=a("toStringTag");e.exports=function(e,t,n){e&&!n&&(e=e.prototype),e&&!i(e,o)&&r(e,o,{configurable:!0,value:t})}},d4c3:function(e,t,n){var r=n("342f"),i=n("da84");e.exports=/ipad|iphone|ipod/i.test(r)&&void 0!==i.Pebble},d58f:function(e,t,n){var r=n("da84"),i=n("59ed"),a=n("7b0b"),o=n("44ad"),s=n("07fa"),c=r.TypeError,u=function(e){return function(t,n,r,u){i(n);var l=a(t),f=o(l),h=s(l),d=e?h-1:0,p=e?-1:1;if(r<2)while(1){if(d in f){u=f[d],d+=p;break}if(d+=p,e?d<0:h<=d)throw c("Reduce of empty array with no initial value")}for(;e?d>=0:h>d;d+=p)d in f&&(u=n(u,f[d],d,l));return u}};e.exports={left:u(!1),right:u(!0)}},d5d6:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").forEach,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("forEach",(function(e){i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},d644:function(e,t,n){var r=n("23e7"),i=n("a98e");r({target:"Set",stat:!0},{from:i})},d6d6:function(e,t,n){var r=n("da84"),i=r.TypeError;e.exports=function(e,t){if(e<t)throw i("Not enough arguments");return e}},d6dd:function(e,t,n){var r=n("23e7"),i=n("d066"),a=n("825a"),o=n("bb2f");r({target:"Reflect",stat:!0,sham:!o},{preventExtensions:function(e){a(e);try{var t=i("Object","preventExtensions");return t&&t(e),!0}catch(n){return!1}}})},d6e6:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("3252"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.Hasher,i=t.x64,a=i.Word,o=i.WordArray,s=t.algo;function c(){return a.create.apply(a,arguments)}var u=[c(1116352408,3609767458),c(1899447441,602891725),c(3049323471,3964484399),c(3921009573,2173295548),c(961987163,4081628472),c(1508970993,3053834265),c(2453635748,2937671579),c(2870763221,3664609560),c(3624381080,2734883394),c(310598401,1164996542),c(607225278,1323610764),c(1426881987,3590304994),c(1925078388,4068182383),c(2162078206,991336113),c(2614888103,633803317),c(3248222580,3479774868),c(3835390401,2666613458),c(4022224774,944711139),c(264347078,2341262773),c(604807628,2007800933),c(770255983,1495990901),c(1249150122,1856431235),c(1555081692,3175218132),c(1996064986,2198950837),c(2554220882,3999719339),c(2821834349,766784016),c(2952996808,2566594879),c(3210313671,3203337956),c(3336571891,1034457026),c(3584528711,2466948901),c(113926993,3758326383),c(338241895,168717936),c(666307205,1188179964),c(773529912,1546045734),c(1294757372,1522805485),c(1396182291,2643833823),c(1695183700,2343527390),c(1986661051,1014477480),c(2177026350,1206759142),c(2456956037,344077627),c(2730485921,1290863460),c(2820302411,3158454273),c(3259730800,3505952657),c(3345764771,106217008),c(3516065817,3606008344),c(3600352804,1432725776),c(4094571909,1467031594),c(275423344,851169720),c(430227734,3100823752),c(506948616,1363258195),c(659060556,3750685593),c(883997877,3785050280),c(958139571,3318307427),c(1322822218,3812723403),c(1537002063,2003034995),c(1747873779,3602036899),c(1955562222,1575990012),c(2024104815,1125592928),c(2227730452,2716904306),c(2361852424,442776044),c(2428436474,593698344),c(2756734187,3733110249),c(3204031479,2999351573),c(3329325298,3815920427),c(3391569614,3928383900),c(3515267271,566280711),c(3940187606,3454069534),c(4118630271,4000239992),c(116418474,1914138554),c(174292421,2731055270),c(289380356,3203993006),c(460393269,320620315),c(685471733,587496836),c(852142971,1086792851),c(1017036298,365543100),c(1126000580,2618297676),c(1288033470,3409855158),c(1501505948,4234509866),c(1607167915,987167468),c(1816402316,1246189591)],l=[];(function(){for(var e=0;e<80;e++)l[e]=c()})();var f=s.SHA512=r.extend({_doReset:function(){this._hash=new o.init([new a.init(1779033703,4089235720),new a.init(3144134277,2227873595),new a.init(1013904242,4271175723),new a.init(2773480762,1595750129),new a.init(1359893119,2917565137),new a.init(2600822924,725511199),new a.init(528734635,4215389547),new a.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],c=n[5],f=n[6],h=n[7],d=r.high,p=r.low,v=i.high,m=i.low,y=a.high,g=a.low,b=o.high,T=o.low,S=s.high,E=s.low,_=c.high,k=c.low,w=f.high,A=f.low,R=h.high,x=h.low,C=d,I=p,P=v,O=m,D=y,U=g,M=b,B=T,N=S,L=E,F=_,j=k,W=w,H=A,V=R,q=x,z=0;z<80;z++){var G,Y,K=l[z];if(z<16)Y=K.high=0|e[t+2*z],G=K.low=0|e[t+2*z+1];else{var X=l[z-15],Q=X.high,$=X.low,Z=(Q>>>1|$<<31)^(Q>>>8|$<<24)^Q>>>7,J=($>>>1|Q<<31)^($>>>8|Q<<24)^($>>>7|Q<<25),ee=l[z-2],te=ee.high,ne=ee.low,re=(te>>>19|ne<<13)^(te<<3|ne>>>29)^te>>>6,ie=(ne>>>19|te<<13)^(ne<<3|te>>>29)^(ne>>>6|te<<26),ae=l[z-7],oe=ae.high,se=ae.low,ce=l[z-16],ue=ce.high,le=ce.low;G=J+se,Y=Z+oe+(G>>>0<J>>>0?1:0),G+=ie,Y=Y+re+(G>>>0<ie>>>0?1:0),G+=le,Y=Y+ue+(G>>>0<le>>>0?1:0),K.high=Y,K.low=G}var fe=N&F^~N&W,he=L&j^~L&H,de=C&P^C&D^P&D,pe=I&O^I&U^O&U,ve=(C>>>28|I<<4)^(C<<30|I>>>2)^(C<<25|I>>>7),me=(I>>>28|C<<4)^(I<<30|C>>>2)^(I<<25|C>>>7),ye=(N>>>14|L<<18)^(N>>>18|L<<14)^(N<<23|L>>>9),ge=(L>>>14|N<<18)^(L>>>18|N<<14)^(L<<23|N>>>9),be=u[z],Te=be.high,Se=be.low,Ee=q+ge,_e=V+ye+(Ee>>>0<q>>>0?1:0),ke=(Ee=Ee+he,_e=_e+fe+(Ee>>>0<he>>>0?1:0),Ee=Ee+Se,_e=_e+Te+(Ee>>>0<Se>>>0?1:0),Ee=Ee+G,_e=_e+Y+(Ee>>>0<G>>>0?1:0),me+pe),we=ve+de+(ke>>>0<me>>>0?1:0);V=W,q=H,W=F,H=j,F=N,j=L,L=B+Ee|0,N=M+_e+(L>>>0<B>>>0?1:0)|0,M=D,B=U,D=P,U=O,P=C,O=I,I=Ee+ke|0,C=_e+we+(I>>>0<Ee>>>0?1:0)|0}p=r.low=p+I,r.high=d+C+(p>>>0<I>>>0?1:0),m=i.low=m+O,i.high=v+P+(m>>>0<O>>>0?1:0),g=a.low=g+U,a.high=y+D+(g>>>0<U>>>0?1:0),T=o.low=T+B,o.high=b+M+(T>>>0<B>>>0?1:0),E=s.low=E+L,s.high=S+N+(E>>>0<L>>>0?1:0),k=c.low=k+j,c.high=_+F+(k>>>0<j>>>0?1:0),A=f.low=A+H,f.high=w+W+(A>>>0<H>>>0?1:0),x=h.low=x+q,h.high=R+V+(x>>>0<q>>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;t[r>>>5]|=128<<24-r%32,t[30+(r+128>>>10<<5)]=Math.floor(n/4294967296),t[31+(r+128>>>10<<5)]=n,e.sigBytes=4*t.length,this._process();var i=this._hash.toX32();return i},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32});t.SHA512=r._createHelper(f),t.HmacSHA512=r._createHmacHelper(f)}(),e.SHA512}))},d784:function(e,t,n){"use strict";n("ac1f");var r=n("e330"),i=n("6eeb"),a=n("9263"),o=n("d039"),s=n("b622"),c=n("9112"),u=s("species"),l=RegExp.prototype;e.exports=function(e,t,n,f){var h=s(e),d=!o((function(){var t={};return t[h]=function(){return 7},7!=""[e](t)})),p=d&&!o((function(){var t=!1,n=/a/;return"split"===e&&(n={},n.constructor={},n.constructor[u]=function(){return n},n.flags="",n[h]=/./[h]),n.exec=function(){return t=!0,null},n[h](""),!t}));if(!d||!p||n){var v=r(/./[h]),m=t(h,""[e],(function(e,t,n,i,o){var s=r(e),c=t.exec;return c===a||c===l.exec?d&&!o?{done:!0,value:v(t,n,i)}:{done:!0,value:s(n,t,i)}:{done:!1}}));i(String.prototype,e,m[0]),i(l,h,m[1])}f&&c(l[h],"sham",!0)}},d80f:function(e,t,n){var r=n("23e7"),i=n("e330"),a=n("fc6a"),o=n("7b0b"),s=n("577e"),c=n("07fa"),u=i([].push),l=i([].join);r({target:"String",stat:!0},{raw:function(e){var t=a(o(e).raw),n=c(t),r=arguments.length,i=[],f=0;while(n>f){if(u(i,s(t[f++])),f===n)return l(i,"");f<r&&u(i,s(arguments[f]))}}})},d81d:function(e,t,n){"use strict";var r=n("23e7"),i=n("b727").map,a=n("1dde"),o=a("map");r({target:"Array",proto:!0,forced:!o},{map:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},d86b:function(e,t,n){var r=n("d039");e.exports=r((function(){if("function"==typeof ArrayBuffer){var e=new ArrayBuffer(8);Object.isExtensible(e)&&Object.defineProperty(e,"a",{value:8})}}))},d925:function(e,t,n){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},d998:function(e,t,n){var r=n("342f");e.exports=/MSIE|Trident/.test(r)},d9b5:function(e,t,n){var r=n("da84"),i=n("d066"),a=n("1626"),o=n("3a9b"),s=n("fdbf"),c=r.Object;e.exports=s?function(e){return"symbol"==typeof e}:function(e){var t=i("Symbol");return a(t)&&o(t.prototype,c(e))}},d9e2:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("2ba4"),o=n("e5cb"),s="WebAssembly",c=i[s],u=7!==Error("e",{cause:7}).cause,l=function(e,t){var n={};n[e]=o(e,t,u),r({global:!0,forced:u},n)},f=function(e,t){if(c&&c[e]){var n={};n[e]=o(s+"."+e,t,u),r({target:s,stat:!0,forced:u},n)}};l("Error",(function(e){return function(t){return a(e,this,arguments)}})),l("EvalError",(function(e){return function(t){return a(e,this,arguments)}})),l("RangeError",(function(e){return function(t){return a(e,this,arguments)}})),l("ReferenceError",(function(e){return function(t){return a(e,this,arguments)}})),l("SyntaxError",(function(e){return function(t){return a(e,this,arguments)}})),l("TypeError",(function(e){return function(t){return a(e,this,arguments)}})),l("URIError",(function(e){return function(t){return a(e,this,arguments)}})),f("CompileError",(function(e){return function(t){return a(e,this,arguments)}})),f("LinkError",(function(e){return function(t){return a(e,this,arguments)}})),f("RuntimeError",(function(e){return function(t){return a(e,this,arguments)}}))},da84:function(e,t,n){(function(t){var n=function(e){return e&&e.Math==Math&&e};e.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof t&&t)||function(){return this}()||Function("return this")()}).call(this,n("c8ba"))},dab0:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("825a"),o=n("d195"),s=o((function(e,t){var n=this,r=n.iterator;return e.resolve(a(i(n.next,r,t))).then((function(e){return a(e).done?(n.done=!0,{done:!0,value:void 0}):{done:!1,value:[n.index++,e.value]}}))}));r({target:"AsyncIterator",proto:!0,real:!0},{asIndexedPairs:function(){return new s({iterator:a(this),index:0})}})},dad3:function(e,t,n){"use strict";var r=n("83ab"),i=n("44d2"),a=n("7b0b"),o=n("07fa"),s=n("9bf2").f;r&&!("lastItem"in[])&&(s(Array.prototype,"lastItem",{configurable:!0,get:function(){var e=a(this),t=o(e);return 0==t?void 0:e[t-1]},set:function(e){var t=a(this),n=o(t);return t[0==n?0:n-1]=e}}),i("lastItem"))},daf2:function(e,t,n){n("0541")},db96:function(e,t,n){var r=n("23e7"),i=n("825a"),a=n("4fad");r({target:"Reflect",stat:!0},{isExtensible:function(e){return i(e),a(e)}})},dbb4:function(e,t,n){var r=n("23e7"),i=n("83ab"),a=n("56ef"),o=n("fc6a"),s=n("06cf"),c=n("8418");r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(e){var t,n,r=o(e),i=s.f,u=a(r),l={},f=0;while(u.length>f)n=i(r,t=u[f++]),void 0!==n&&c(l,t,n);return l}})},dbfa:function(e,t,n){"use strict";var r=n("23e7"),i=n("59ed"),a=n("d066"),o=n("c65b"),s=n("f069"),c=n("e667"),u=n("2266"),l="No one promise resolved";r({target:"Promise",stat:!0},{any:function(e){var t=this,n=a("AggregateError"),r=s.f(t),f=r.resolve,h=r.reject,d=c((function(){var r=i(t.resolve),a=[],s=0,c=1,d=!1;u(e,(function(e){var i=s++,u=!1;c++,o(r,t,e).then((function(e){u||d||(d=!0,f(e))}),(function(e){u||d||(u=!0,a[i]=e,--c||h(new n(a,l)))}))})),--c||h(new n(a,l))}));return d.error&&h(d.value),r.promise}})},dc4a:function(e,t,n){var r=n("59ed");e.exports=function(e,t){var n=e[t];return null==n?void 0:r(n)}},dc56:function(e,t,n){"use strict";var r=n("23e7"),i=n("a258").findLastIndex,a=n("44d2");r({target:"Array",proto:!0},{findLastIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),a("findLastIndex")},dc8d:function(e,t,n){var r=n("746f");r("hasInstance")},dca8:function(e,t,n){var r=n("23e7"),i=n("bb2f"),a=n("d039"),o=n("861d"),s=n("f183").onFreeze,c=Object.freeze,u=a((function(){c(1)}));r({target:"Object",stat:!0,forced:u,sham:!i},{freeze:function(e){return c&&o(e)?c(s(e)):e}})},dd2f:function(e,t,n){"use strict";var r=n("da84"),i=n("c65b"),a=n("59ed"),o=n("825a"),s=n("d066"),c=n("dc4a"),u=9007199254740991,l=r.TypeError,f=function(e){var t=0==e,n=1==e,r=2==e,f=3==e;return function(e,h,d){o(e);var p=s("Promise"),v=a(e.next),m=0,y=void 0!==h;return!y&&t||a(h),new p((function(a,s){var g=function(t,n){try{var r=c(e,"return");if(r)return p.resolve(i(r,e)).then((function(){t(n)}),(function(e){s(e)}))}catch(a){return s(a)}t(n)},b=function(e){g(s,e)},T=function(){try{if(t&&m>u&&y)throw l("The allowed number of iterations has been exceeded");p.resolve(o(i(v,e))).then((function(e){try{if(o(e).done)t?(d.length=m,a(d)):a(!f&&(r||void 0));else{var i=e.value;y?p.resolve(t?h(i,m):h(i)).then((function(e){n?T():r?e?T():g(a,!1):t?(d[m++]=e,T()):e?g(a,f||i):T()}),b):(d[m++]=i,T())}}catch(s){b(s)}}),b)}catch(s){b(s)}};T()}))}};e.exports={toArray:f(0),forEach:f(1),every:f(2),some:f(3),find:f(4)}},ddb0:function(e,t,n){var r=n("da84"),i=n("fdbc"),a=n("785a"),o=n("e260"),s=n("9112"),c=n("b622"),u=c("iterator"),l=c("toStringTag"),f=o.values,h=function(e,t){if(e){if(e[u]!==f)try{s(e,u,f)}catch(r){e[u]=f}if(e[l]||s(e,l,t),i[t])for(var n in o)if(e[n]!==o[n])try{s(e,n,o[n])}catch(r){e[n]=o[n]}}};for(var d in i)h(r[d]&&r[d].prototype,d);h(a,"DOMTokenList")},ddd7:function(e,t,n){"use strict";var r=n("23e7"),i=n("2ba4"),a=n("59ed"),o=n("825a"),s=n("d195"),c=s((function(e,t){var n=this,r=n.filterer;return new e((function(a,s){var c=function(){try{e.resolve(o(i(n.next,n.iterator,t))).then((function(t){try{if(o(t).done)n.done=!0,a({done:!0,value:void 0});else{var i=t.value;e.resolve(r(i)).then((function(e){e?a({done:!1,value:i}):c()}),s)}}catch(u){s(u)}}),s)}catch(u){s(u)}};c()}))}));r({target:"AsyncIterator",proto:!0,real:!0},{filter:function(e){return new c({iterator:o(this),filterer:a(e)})}})},dee5:function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("d066"),o=n("c65b"),s=n("59ed"),c=n("825a"),u=n("0366"),l=n("4840"),f=n("5860"),h=n("2266");i({target:"Set",proto:!0,real:!0,forced:r},{filter:function(e){var t=c(this),n=f(t),r=u(e,arguments.length>1?arguments[1]:void 0),i=new(l(t,a("Set"))),d=s(i.add);return h(n,(function(e){r(e,e,t)&&o(d,i,e)}),{IS_ITERATOR:!0}),i}})},df2f:function(e,t,n){(function(t,r){e.exports=r(n("21bf"))})(0,(function(e){return function(){var t=e,n=t.lib,r=n.WordArray,i=n.Hasher,a=t.algo,o=[],s=a.SHA1=i.extend({_doReset:function(){this._hash=new r.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],a=n[2],s=n[3],c=n[4],u=0;u<80;u++){if(u<16)o[u]=0|e[t+u];else{var l=o[u-3]^o[u-8]^o[u-14]^o[u-16];o[u]=l<<1|l>>>31}var f=(r<<5|r>>>27)+c+o[u];f+=u<20?1518500249+(i&a|~i&s):u<40?1859775393+(i^a^s):u<60?(i&a|i&s|a&s)-1894007588:(i^a^s)-899497514,c=s,s=a,a=i<<30|i>>>2,i=r,r=f}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+a|0,n[3]=n[3]+s|0,n[4]=n[4]+c|0},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;return t[r>>>5]|=128<<24-r%32,t[14+(r+64>>>9<<4)]=Math.floor(n/4294967296),t[15+(r+64>>>9<<4)]=n,e.sigBytes=4*t.length,this._process(),this._hash},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA1=i._createHelper(s),t.HmacSHA1=i._createHmacHelper(s)}(),e.SHA1}))},df75:function(e,t,n){var r=n("ca84"),i=n("7839");e.exports=Object.keys||function(e){return r(e,i)}},df7c:function(e,t,n){(function(e){function n(e,t){for(var n=0,r=e.length-1;r>=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e){"string"!==typeof e&&(e+="");var t,n=0,r=-1,i=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!i){n=t+1;break}}else-1===r&&(i=!1,r=t+1);return-1===r?"":e.slice(n,r)}function i(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r<e.length;r++)t(e[r],r,e)&&n.push(e[r]);return n}t.resolve=function(){for(var t="",r=!1,a=arguments.length-1;a>=-1&&!r;a--){var o=a>=0?arguments[a]:e.cwd();if("string"!==typeof o)throw new TypeError("Arguments to path.resolve must be strings");o&&(t=o+"/"+t,r="/"===o.charAt(0))}return t=n(i(t.split("/"),(function(e){return!!e})),!r).join("/"),(r?"/":"")+t||"."},t.normalize=function(e){var r=t.isAbsolute(e),o="/"===a(e,-1);return e=n(i(e.split("/"),(function(e){return!!e})),!r).join("/"),e||r||(e="."),e&&o&&(e+="/"),(r?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(i(e,(function(e,t){if("string"!==typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t<e.length;t++)if(""!==e[t])break;for(var n=e.length-1;n>=0;n--)if(""!==e[n])break;return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),a=r(n.split("/")),o=Math.min(i.length,a.length),s=o,c=0;c<o;c++)if(i[c]!==a[c]){s=c;break}var u=[];for(c=s;c<i.length;c++)u.push("..");return u=u.concat(a.slice(s)),u.join("/")},t.sep="/",t.delimiter=":",t.dirname=function(e){if("string"!==typeof e&&(e+=""),0===e.length)return".";for(var t=e.charCodeAt(0),n=47===t,r=-1,i=!0,a=e.length-1;a>=1;--a)if(t=e.charCodeAt(a),47===t){if(!i){r=a;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=r(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!==typeof e&&(e+="");for(var t=-1,n=0,r=-1,i=!0,a=0,o=e.length-1;o>=0;--o){var s=e.charCodeAt(o);if(47!==s)-1===r&&(i=!1,r=o+1),46===s?-1===t?t=o:1!==a&&(a=1):-1!==t&&(a=-1);else if(!i){n=o+1;break}}return-1===t||-1===r||0===a||1===a&&t===r-1&&t===n+1?"":e.slice(t,r)};var a="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n("4362"))},df7e:function(e,t,n){var r=n("07fa");e.exports=function(e,t){for(var n=r(e),i=new t(n),a=0;a<n;a++)i[a]=e[n-a-1];return i}},dfa4:function(e,t,n){"use strict";var r=n("23e7"),i=n("fd81");"function"==typeof BigInt&&r({target:"BigInt",stat:!0},{range:function(e,t,n){return new i(e,t,n,"bigint",BigInt(0),BigInt(1))}})},dfb9:function(e,t,n){var r=n("07fa");e.exports=function(e,t){var n=0,i=r(t),a=new e(i);while(i>n)a[n]=t[n++];return a}},e01a:function(e,t,n){"use strict";var r=n("23e7"),i=n("83ab"),a=n("da84"),o=n("e330"),s=n("1a2d"),c=n("1626"),u=n("3a9b"),l=n("577e"),f=n("9bf2").f,h=n("e893"),d=a.Symbol,p=d&&d.prototype;if(i&&c(d)&&(!("description"in p)||void 0!==d().description)){var v={},m=function(){var e=arguments.length<1||void 0===arguments[0]?void 0:l(arguments[0]),t=u(p,this)?new d(e):void 0===e?d():d(e);return""===e&&(v[t]=!0),t};h(m,d),m.prototype=p,p.constructor=m;var y="Symbol(test)"==String(d("test")),g=o(p.toString),b=o(p.valueOf),T=/^Symbol\((.*)\)[^)]+$/,S=o("".replace),E=o("".slice);f(p,"description",{configurable:!0,get:function(){var e=b(this),t=g(e);if(s(v,e))return"";var n=y?E(t,7,-1):S(t,T,"$1");return""===n?void 0:n}}),r({global:!0,forced:!0},{Symbol:m})}},e163:function(e,t,n){var r=n("da84"),i=n("1a2d"),a=n("1626"),o=n("7b0b"),s=n("f772"),c=n("e177"),u=s("IE_PROTO"),l=r.Object,f=l.prototype;e.exports=c?l.getPrototypeOf:function(e){var t=o(e);if(i(t,u))return t[u];var n=t.constructor;return a(n)&&t instanceof n?n.prototype:t instanceof l?f:null}},e176:function(e,t,n){var r=n("746f");r("observable")},e177:function(e,t,n){var r=n("d039");e.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},e1db:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n("10d3"),a=n("20a2"),o=n("10d3"),s=n("1b29"),c=s.byEbmlID;(function(e){e[e["STATE_TAG"]=1]="STATE_TAG",e[e["STATE_SIZE"]=2]="STATE_SIZE",e[e["STATE_CONTENT"]=3]="STATE_CONTENT"})(r||(r={}));var u=function(){function e(){this._buffer=new i.Buffer(0),this._tag_stack=[],this._state=r.STATE_TAG,this._cursor=0,this._total=0,this._schema=c,this._result=[]}return e.prototype.decode=function(e){this.readChunk(e);var t=this._result;return this._result=[],t},e.prototype.readChunk=function(e){this._buffer=o.concat([this._buffer,new i.Buffer(e)]);while(this._cursor<this._buffer.length){if(this._state===r.STATE_TAG&&!this.readTag())break;if(this._state===r.STATE_SIZE&&!this.readSize())break;if(this._state===r.STATE_CONTENT&&!this.readContent())break}},e.prototype.getSchemaInfo=function(e){return this._schema[e]||{name:"unknown",level:-1,type:"unknown",description:"unknown"}},e.prototype.readTag=function(){if(this._cursor>=this._buffer.length)return!1;var e=i.readVint(this._buffer,this._cursor);if(null==e)return!1;var t=this._buffer.slice(this._cursor,this._cursor+e.length),n=t.reduce((function(e,t,n,r){return e+t*Math.pow(16,2*(r.length-1-n))}),0),a=this.getSchemaInfo(n),o={EBML_ID:n.toString(16),schema:a,type:a.type,name:a.name,level:a.level,tagStart:this._total,tagEnd:this._total+e.length,sizeStart:this._total+e.length,sizeEnd:null,dataStart:null,dataEnd:null,dataSize:null,data:null};return this._tag_stack.push(o),this._cursor+=e.length,this._total+=e.length,this._state=r.STATE_SIZE,!0},e.prototype.readSize=function(){if(this._cursor>=this._buffer.length)return!1;var e=i.readVint(this._buffer,this._cursor);if(null==e)return!1;var t=this._tag_stack[this._tag_stack.length-1];return t.sizeEnd=t.sizeStart+e.length,t.dataStart=t.sizeEnd,t.dataSize=e.value,-1===e.value?(t.dataEnd=-1,"m"===t.type&&(t.unknownSize=!0)):t.dataEnd=t.sizeEnd+e.value,this._cursor+=e.length,this._total+=e.length,this._state=r.STATE_CONTENT,!0},e.prototype.readContent=function(){var e=this._tag_stack[this._tag_stack.length-1];if("m"===e.type){if(e.isEnd=!1,this._result.push(e),this._state=r.STATE_TAG,0===e.dataSize){var t=Object.assign({},e,{isEnd:!0});this._result.push(t),this._tag_stack.pop()}return!0}if(this._buffer.length<this._cursor+e.dataSize)return!1;var n=this._buffer.slice(this._cursor,this._cursor+e.dataSize);switch(this._buffer=this._buffer.slice(this._cursor+e.dataSize),e.data=n,e.type){case"u":e.value=n.readUIntBE(0,n.length);break;case"i":e.value=n.readIntBE(0,n.length);break;case"f":e.value=4===e.dataSize?n.readFloatBE(0):8===e.dataSize?n.readDoubleBE(0):(console.warn("cannot read "+e.dataSize+" octets float. failback to 0"),0);break;case"s":e.value=n.toString("ascii");break;case"8":e.value=n.toString("utf8");break;case"b":e.value=n;break;case"d":e.value=i.convertEBMLDateToJSDate(new a.Int64BE(n).toNumber());break}if(null===e.value)throw new Error("unknown tag type:"+e.type);this._result.push(e),this._total+=e.dataSize,this._state=r.STATE_TAG,this._cursor=0,this._tag_stack.pop();while(this._tag_stack.length>0){var o=this._tag_stack[this._tag_stack.length-1];if(o.dataEnd<0)return this._tag_stack.pop(),!0;if(this._total<o.dataEnd)break;if("m"!==o.type)throw new Error("parent element is not master element");t=Object.assign({},o,{isEnd:!0});this._result.push(t),this._tag_stack.pop()}return!0},e}();t.default=u},e21d:function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("861d"),o=n("c6b6"),s=n("d86b"),c=Object.isFrozen,u=i((function(){c(1)}));r({target:"Object",stat:!0,forced:u||s},{isFrozen:function(e){return!a(e)||(!(!s||"ArrayBuffer"!=o(e))||!!c&&c(e))}})},e25e:function(e,t,n){var r=n("23e7"),i=n("c20d");r({global:!0,forced:parseInt!=i},{parseInt:i})},e260:function(e,t,n){"use strict";var r=n("fc6a"),i=n("44d2"),a=n("3f8c"),o=n("69f3"),s=n("9bf2").f,c=n("7dd0"),u=n("c430"),l=n("83ab"),f="Array Iterator",h=o.set,d=o.getterFor(f);e.exports=c(Array,"Array",(function(e,t){h(this,{type:f,target:r(e),index:0,kind:t})}),(function(){var e=d(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values");var p=a.Arguments=a.Array;if(i("keys"),i("values"),i("entries"),!u&&l&&"values"!==p.name)try{s(p,"name",{value:"values"})}catch(v){}},e285:function(e,t,n){var r=n("da84"),i=r.isFinite;e.exports=Number.isFinite||function(e){return"number"==typeof e&&i(e)}},e2cc:function(e,t,n){var r=n("6eeb");e.exports=function(e,t,n){for(var i in t)r(e,i,t[i],n);return e}},e323:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("1d80"),o=n("5926"),s=n("577e"),c=i("".slice),u=Math.max,l=Math.min,f=!"".substr||"b"!=="ab".substr(-1);r({target:"String",proto:!0,forced:f},{substr:function(e,t){var n,r,i=s(a(this)),f=i.length,h=o(e);return h===1/0&&(h=0),h<0&&(h=u(f+h,0)),n=void 0===t?f:o(t),n<=0||n===1/0?"":(r=l(h+n,f),h>=r?"":c(i,h,r))}})},e330:function(e,t,n){var r=n("40d5"),i=Function.prototype,a=i.bind,o=i.call,s=r&&a.bind(o,o);e.exports=r?function(e){return e&&s(e)}:function(e){return e&&function(){return o.apply(e,arguments)}}},e391:function(e,t,n){var r=n("577e");e.exports=function(e,t){return void 0===e?arguments.length<2?"":t:r(e)}},e3db:function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},e3df:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("7d72");r({target:"Set",proto:!0,real:!0,forced:i},{addAll:a})},e439:function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("fc6a"),o=n("06cf").f,s=n("83ab"),c=i((function(){o(1)})),u=!s||c;r({target:"Object",stat:!0,forced:u,sham:!s},{getOwnPropertyDescriptor:function(e,t){return o(a(e),t)}})},e43e:function(e,t,n){var r=n("23e7"),i=n("d039"),a=n("861d"),o=n("c6b6"),s=n("d86b"),c=Object.isSealed,u=i((function(){c(1)}));r({target:"Object",stat:!0,forced:u||s},{isSealed:function(e){return!a(e)||(!(!s||"ArrayBuffer"!=o(e))||!!c&&c(e))}})},e495:function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("e330"),o=n("825a"),s=n("577e"),c=n("5860"),u=n("2266"),l=a([].join),f=[].push;i({target:"Set",proto:!0,real:!0,forced:r},{join:function(e){var t=o(this),n=c(t),r=void 0===e?",":s(e),i=[];return u(n,f,{that:i,IS_ITERATOR:!0}),l(i,r)}})},e538:function(e,t,n){var r=n("b622");t.f=r},e555:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("e9e0");r({target:"WeakMap",proto:!0,real:!0,forced:i},{upsert:a})},e58c:function(e,t,n){"use strict";var r=n("2ba4"),i=n("fc6a"),a=n("5926"),o=n("07fa"),s=n("a640"),c=Math.min,u=[].lastIndexOf,l=!!u&&1/[1].lastIndexOf(1,-0)<0,f=s("lastIndexOf"),h=l||!f;e.exports=h?function(e){if(l)return r(u,this,arguments)||0;var t=i(this),n=o(t),s=n-1;for(arguments.length>1&&(s=c(s,a(arguments[1]))),s<0&&(s=n+s);s>=0;s--)if(s in t&&t[s]===e)return s||0;return-1}:u},e5cb:function(e,t,n){"use strict";var r=n("d066"),i=n("1a2d"),a=n("9112"),o=n("3a9b"),s=n("d2bb"),c=n("e893"),u=n("7156"),l=n("e391"),f=n("ab36"),h=n("c770"),d=n("b980"),p=n("c430");e.exports=function(e,t,n,v){var m=v?2:1,y=e.split("."),g=y[y.length-1],b=r.apply(null,y);if(b){var T=b.prototype;if(!p&&i(T,"cause")&&delete T.cause,!n)return b;var S=r("Error"),E=t((function(e,t){var n=l(v?t:e,void 0),r=v?new b(e):new b;return void 0!==n&&a(r,"message",n),d&&a(r,"stack",h(r.stack,2)),this&&o(T,this)&&u(r,this,E),arguments.length>m&&f(r,arguments[m]),r}));if(E.prototype=T,"Error"!==g&&(s?s(E,S):c(E,S,{name:!0})),c(E,b),!p)try{T.name!==g&&a(T,"name",g),T.constructor=E}catch(_){}return E}}},e61b:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("3252"))})(0,(function(e){return function(t){var n=e,r=n.lib,i=r.WordArray,a=r.Hasher,o=n.x64,s=o.Word,c=n.algo,u=[],l=[],f=[];(function(){for(var e=1,t=0,n=0;n<24;n++){u[e+5*t]=(n+1)*(n+2)/2%64;var r=t%5,i=(2*e+3*t)%5;e=r,t=i}for(e=0;e<5;e++)for(t=0;t<5;t++)l[e+5*t]=t+(2*e+3*t)%5*5;for(var a=1,o=0;o<24;o++){for(var c=0,h=0,d=0;d<7;d++){if(1&a){var p=(1<<d)-1;p<32?h^=1<<p:c^=1<<p-32}128&a?a=a<<1^113:a<<=1}f[o]=s.create(c,h)}})();var h=[];(function(){for(var e=0;e<25;e++)h[e]=s.create()})();var d=c.SHA3=a.extend({cfg:a.cfg.extend({outputLength:512}),_doReset:function(){for(var e=this._state=[],t=0;t<25;t++)e[t]=new s.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(e,t){for(var n=this._state,r=this.blockSize/2,i=0;i<r;i++){var a=e[t+2*i],o=e[t+2*i+1];a=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),o=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8);var s=n[i];s.high^=o,s.low^=a}for(var c=0;c<24;c++){for(var d=0;d<5;d++){for(var p=0,v=0,m=0;m<5;m++){s=n[d+5*m];p^=s.high,v^=s.low}var y=h[d];y.high=p,y.low=v}for(d=0;d<5;d++){var g=h[(d+4)%5],b=h[(d+1)%5],T=b.high,S=b.low;for(p=g.high^(T<<1|S>>>31),v=g.low^(S<<1|T>>>31),m=0;m<5;m++){s=n[d+5*m];s.high^=p,s.low^=v}}for(var E=1;E<25;E++){s=n[E];var _=s.high,k=s.low,w=u[E];w<32?(p=_<<w|k>>>32-w,v=k<<w|_>>>32-w):(p=k<<w-32|_>>>64-w,v=_<<w-32|k>>>64-w);var A=h[l[E]];A.high=p,A.low=v}var R=h[0],x=n[0];R.high=x.high,R.low=x.low;for(d=0;d<5;d++)for(m=0;m<5;m++){E=d+5*m,s=n[E];var C=h[E],I=h[(d+1)%5+5*m],P=h[(d+2)%5+5*m];s.high=C.high^~I.high&P.high,s.low=C.low^~I.low&P.low}s=n[0];var O=f[c];s.high^=O.high,s.low^=O.low}},_doFinalize:function(){var e=this._data,n=e.words,r=(this._nDataBytes,8*e.sigBytes),a=32*this.blockSize;n[r>>>5]|=1<<24-r%32,n[(t.ceil((r+1)/a)*a>>>5)-1]|=128,e.sigBytes=4*n.length,this._process();for(var o=this._state,s=this.cfg.outputLength/8,c=s/8,u=[],l=0;l<c;l++){var f=o[l],h=f.high,d=f.low;h=16711935&(h<<8|h>>>24)|4278255360&(h<<24|h>>>8),d=16711935&(d<<8|d>>>24)|4278255360&(d<<24|d>>>8),u.push(d),u.push(h)}return new i.init(u,s)},clone:function(){for(var e=a.clone.call(this),t=e._state=this._state.slice(0),n=0;n<25;n++)t[n]=t[n].clone();return e}});n.SHA3=a._createHelper(d),n.HmacSHA3=a._createHmacHelper(d)}(Math),e.SHA3}))},e667:function(e,t){e.exports=function(e){try{return{error:!1,value:e()}}catch(t){return{error:!0,value:t}}}},e683:function(e,t,n){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},e6bd:function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.get,s=i.toKey;r({target:"Reflect",stat:!0},{getOwnMetadata:function(e,t){var n=arguments.length<3?void 0:s(arguments[2]);return o(e,a(t),n)}})},e6cf:function(e,t,n){"use strict";var r,i,a,o,s=n("23e7"),c=n("c430"),u=n("da84"),l=n("d066"),f=n("c65b"),h=n("fea9"),d=n("6eeb"),p=n("e2cc"),v=n("d2bb"),m=n("d44e"),y=n("2626"),g=n("59ed"),b=n("1626"),T=n("861d"),S=n("19aa"),E=n("8925"),_=n("2266"),k=n("1c7e"),w=n("4840"),A=n("2cf4").set,R=n("b575"),x=n("cdf9"),C=n("44de"),I=n("f069"),P=n("e667"),O=n("01b4"),D=n("69f3"),U=n("94ca"),M=n("b622"),B=n("6069"),N=n("605d"),L=n("2d00"),F=M("species"),j="Promise",W=D.getterFor(j),H=D.set,V=D.getterFor(j),q=h&&h.prototype,z=h,G=q,Y=u.TypeError,K=u.document,X=u.process,Q=I.f,$=Q,Z=!!(K&&K.createEvent&&u.dispatchEvent),J=b(u.PromiseRejectionEvent),ee="unhandledrejection",te="rejectionhandled",ne=0,re=1,ie=2,ae=1,oe=2,se=!1,ce=U(j,(function(){var e=E(z),t=e!==String(z);if(!t&&66===L)return!0;if(c&&!G["finally"])return!0;if(L>=51&&/native code/.test(e))return!1;var n=new z((function(e){e(1)})),r=function(e){e((function(){}),(function(){}))},i=n.constructor={};return i[F]=r,se=n.then((function(){}))instanceof r,!se||!t&&B&&!J})),ue=ce||!k((function(e){z.all(e)["catch"]((function(){}))})),le=function(e){var t;return!(!T(e)||!b(t=e.then))&&t},fe=function(e,t){var n,r,i,a=t.value,o=t.state==re,s=o?e.ok:e.fail,c=e.resolve,u=e.reject,l=e.domain;try{s?(o||(t.rejection===oe&&me(t),t.rejection=ae),!0===s?n=a:(l&&l.enter(),n=s(a),l&&(l.exit(),i=!0)),n===e.promise?u(Y("Promise-chain cycle")):(r=le(n))?f(r,n,c,u):c(n)):u(a)}catch(h){l&&!i&&l.exit(),u(h)}},he=function(e,t){e.notified||(e.notified=!0,R((function(){var n,r=e.reactions;while(n=r.get())fe(n,e);e.notified=!1,t&&!e.rejection&&pe(e)})))},de=function(e,t,n){var r,i;Z?(r=K.createEvent("Event"),r.promise=t,r.reason=n,r.initEvent(e,!1,!0),u.dispatchEvent(r)):r={promise:t,reason:n},!J&&(i=u["on"+e])?i(r):e===ee&&C("Unhandled promise rejection",n)},pe=function(e){f(A,u,(function(){var t,n=e.facade,r=e.value,i=ve(e);if(i&&(t=P((function(){N?X.emit("unhandledRejection",r,n):de(ee,n,r)})),e.rejection=N||ve(e)?oe:ae,t.error))throw t.value}))},ve=function(e){return e.rejection!==ae&&!e.parent},me=function(e){f(A,u,(function(){var t=e.facade;N?X.emit("rejectionHandled",t):de(te,t,e.value)}))},ye=function(e,t,n){return function(r){e(t,r,n)}},ge=function(e,t,n){e.done||(e.done=!0,n&&(e=n),e.value=t,e.state=ie,he(e,!0))},be=function(e,t,n){if(!e.done){e.done=!0,n&&(e=n);try{if(e.facade===t)throw Y("Promise can't be resolved itself");var r=le(t);r?R((function(){var n={done:!1};try{f(r,t,ye(be,n,e),ye(ge,n,e))}catch(i){ge(n,i,e)}})):(e.value=t,e.state=re,he(e,!1))}catch(i){ge({done:!1},i,e)}}};if(ce&&(z=function(e){S(this,G),g(e),f(r,this);var t=W(this);try{e(ye(be,t),ye(ge,t))}catch(n){ge(t,n)}},G=z.prototype,r=function(e){H(this,{type:j,done:!1,notified:!1,parent:!1,reactions:new O,rejection:!1,state:ne,value:void 0})},r.prototype=p(G,{then:function(e,t){var n=V(this),r=Q(w(this,z));return n.parent=!0,r.ok=!b(e)||e,r.fail=b(t)&&t,r.domain=N?X.domain:void 0,n.state==ne?n.reactions.add(r):R((function(){fe(r,n)})),r.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new r,t=W(e);this.promise=e,this.resolve=ye(be,t),this.reject=ye(ge,t)},I.f=Q=function(e){return e===z||e===a?new i(e):$(e)},!c&&b(h)&&q!==Object.prototype)){o=q.then,se||(d(q,"then",(function(e,t){var n=this;return new z((function(e,t){f(o,n,e,t)})).then(e,t)}),{unsafe:!0}),d(q,"catch",G["catch"],{unsafe:!0}));try{delete q.constructor}catch(Te){}v&&v(q,G)}s({global:!0,wrap:!0,forced:ce},{Promise:z}),m(z,j,!1,!0),y(j),a=l(j),s({target:j,stat:!0,forced:ce},{reject:function(e){var t=Q(this);return f(t.reject,void 0,e),t.promise}}),s({target:j,stat:!0,forced:c||ce},{resolve:function(e){return x(c&&this===a?z:this,e)}}),s({target:j,stat:!0,forced:ue},{all:function(e){var t=this,n=Q(t),r=n.resolve,i=n.reject,a=P((function(){var n=g(t.resolve),a=[],o=0,s=1;_(e,(function(e){var c=o++,u=!1;s++,f(n,t,e).then((function(e){u||(u=!0,a[c]=e,--s||r(a))}),i)})),--s||r(a)}));return a.error&&i(a.value),n.promise},race:function(e){var t=this,n=Q(t),r=n.reject,i=P((function(){var i=g(t.resolve);_(e,(function(e){f(i,t,e).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},e6e1:function(e,t,n){var r=n("23e7");r({target:"Number",stat:!0},{MIN_SAFE_INTEGER:-9007199254740991})},e71b:function(e,t,n){"use strict";var r=n("23e7"),i=n("83ab"),a=n("eb1d"),o=n("59ed"),s=n("7b0b"),c=n("9bf2");i&&r({target:"Object",proto:!0,forced:a},{__defineSetter__:function(e,t){c.f(s(this),e,{set:o(t),enumerable:!0,configurable:!0})}})},e74c:function(e,t,n){var r=n("23e7"),i=n("e330"),a=n("1626"),o=n("8925"),s=n("1a2d"),c=n("83ab"),u=Object.getOwnPropertyDescriptor,l=/^\s*class\b/,f=i(l.exec),h=function(e){try{if(!c||!f(l,o(e)))return!1}catch(n){}var t=u(e,"prototype");return!!t&&s(t,"writable")&&!t.writable};r({target:"Function",stat:!0,sham:!0},{isCallable:function(e){return a(e)&&!h(e)}})},e7dd:function(e,t,n){var r=n("23e7"),i=n("3fde");r({target:"Map",stat:!0},{of:i})},e893:function(e,t,n){var r=n("1a2d"),i=n("56ef"),a=n("06cf"),o=n("9bf2");e.exports=function(e,t,n){for(var s=i(t),c=o.f,u=a.f,l=0;l<s.length;l++){var f=s[l];r(e,f)||n&&r(n,f)||c(e,f,u(t,f))}}},e8b5:function(e,t,n){var r=n("c6b6");e.exports=Array.isArray||function(e){return"Array"==r(e)}},e8eb:function(e,t,n){var r=n("746f");r("metadata")},e91f:function(e,t,n){"use strict";var r=n("ebb5"),i=n("4d64").indexOf,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("indexOf",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},e95a:function(e,t,n){var r=n("b622"),i=n("3f8c"),a=r("iterator"),o=Array.prototype;e.exports=function(e){return void 0!==e&&(i.Array===e||o[a]===e)}},e95e:function(e,t,n){var r=n("746f");r("patternMatch")},e9c4:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("d066"),o=n("2ba4"),s=n("e330"),c=n("d039"),u=i.Array,l=a("JSON","stringify"),f=s(/./.exec),h=s("".charAt),d=s("".charCodeAt),p=s("".replace),v=s(1..toString),m=/[\uD800-\uDFFF]/g,y=/^[\uD800-\uDBFF]$/,g=/^[\uDC00-\uDFFF]$/,b=function(e,t,n){var r=h(n,t-1),i=h(n,t+1);return f(y,e)&&!f(g,i)||f(g,e)&&!f(y,r)?"\\u"+v(d(e,0),16):e},T=c((function(){return'"\\udf06\\ud834"'!==l("\udf06\ud834")||'"\\udead"'!==l("\udead")}));l&&r({target:"JSON",stat:!0,forced:T},{stringify:function(e,t,n){for(var r=0,i=arguments.length,a=u(i);r<i;r++)a[r]=arguments[r];var s=o(l,null,a);return"string"==typeof s?p(s,m,b):s}})},e9e0:function(e,t,n){"use strict";var r=n("da84"),i=n("c65b"),a=n("59ed"),o=n("1626"),s=n("825a"),c=r.TypeError;e.exports=function(e,t){var n,r=s(this),u=a(r.get),l=a(r.has),f=a(r.set),h=arguments.length>2?arguments[2]:void 0;if(!o(t)&&!o(h))throw c("At least one callback required");return i(l,r,e)?(n=i(u,r,e),o(t)&&(n=t(n),i(f,r,e,n))):o(h)&&(n=h(),i(f,r,e,n)),n}},ea85:function(e,t){e.exports=function(e,t,n){t=t||0;for(var r=1;r<=8;r++)if(e[t]>=Math.pow(2,8-r))break;if(r>8)throw new Error("Unrepresentable length: "+r+" "+e.toString("hex",t,t+r));if(t+r>e.length)return null;var i,a=e[t]&(1<<8-r)-1;for(i=1;i<r;i++){if(7===i&&a>=Math.pow(2,45)&&e[t+7]>0)return{length:r,value:-1};a*=Math.pow(2,8),a+=e[t+i]}return n&&(a-=Math.pow(2,7*r-1)-1),{length:r,value:a}}},ea98:function(e,t,n){"use strict";var r=n("23e7"),i=n("e330"),a=n("1d80"),o=n("5926"),s=n("577e"),c=n("d039"),u=i("".charAt),l=c((function(){return"\ud842"!=="𠮷".at(-2)}));r({target:"String",proto:!0,forced:l},{at:function(e){var t=s(a(this)),n=t.length,r=o(e),i=r>=0?r:n+r;return i<0||i>=n?void 0:u(t,i)}})},eac5:function(e,t,n){var r=n("861d"),i=Math.floor;e.exports=Number.isInteger||function(e){return!r(e)&&isFinite(e)&&i(e)===e}},eb1d:function(e,t,n){"use strict";var r=n("c430"),i=n("da84"),a=n("d039"),o=n("512c");e.exports=r||!a((function(){if(!(o&&o<535)){var e=Math.random();__defineSetter__.call(null,e,(function(){})),delete i[e]}}))},eba5:function(e,t,n){n("967a")},ebb5:function(e,t,n){"use strict";var r,i,a,o=n("a981"),s=n("83ab"),c=n("da84"),u=n("1626"),l=n("861d"),f=n("1a2d"),h=n("f5df"),d=n("0d51"),p=n("9112"),v=n("6eeb"),m=n("9bf2").f,y=n("3a9b"),g=n("e163"),b=n("d2bb"),T=n("b622"),S=n("90e3"),E=c.Int8Array,_=E&&E.prototype,k=c.Uint8ClampedArray,w=k&&k.prototype,A=E&&g(E),R=_&&g(_),x=Object.prototype,C=c.TypeError,I=T("toStringTag"),P=S("TYPED_ARRAY_TAG"),O=S("TYPED_ARRAY_CONSTRUCTOR"),D=o&&!!b&&"Opera"!==h(c.opera),U=!1,M={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},B={BigInt64Array:8,BigUint64Array:8},N=function(e){if(!l(e))return!1;var t=h(e);return"DataView"===t||f(M,t)||f(B,t)},L=function(e){if(!l(e))return!1;var t=h(e);return f(M,t)||f(B,t)},F=function(e){if(L(e))return e;throw C("Target is not a typed array")},j=function(e){if(u(e)&&(!b||y(A,e)))return e;throw C(d(e)+" is not a typed array constructor")},W=function(e,t,n,r){if(s){if(n)for(var i in M){var a=c[i];if(a&&f(a.prototype,e))try{delete a.prototype[e]}catch(o){try{a.prototype[e]=t}catch(u){}}}R[e]&&!n||v(R,e,n?t:D&&_[e]||t,r)}},H=function(e,t,n){var r,i;if(s){if(b){if(n)for(r in M)if(i=c[r],i&&f(i,e))try{delete i[e]}catch(a){}if(A[e]&&!n)return;try{return v(A,e,n?t:D&&A[e]||t)}catch(a){}}for(r in M)i=c[r],!i||i[e]&&!n||v(i,e,t)}};for(r in M)i=c[r],a=i&&i.prototype,a?p(a,O,i):D=!1;for(r in B)i=c[r],a=i&&i.prototype,a&&p(a,O,i);if((!D||!u(A)||A===Function.prototype)&&(A=function(){throw C("Incorrect invocation")},D))for(r in M)c[r]&&b(c[r],A);if((!D||!R||R===x)&&(R=A.prototype,D))for(r in M)c[r]&&b(c[r].prototype,R);if(D&&g(w)!==R&&b(w,R),s&&!f(R,I))for(r in U=!0,m(R,I,{get:function(){return l(this)?this[P]:void 0}}),M)c[r]&&p(c[r],P,r);e.exports={NATIVE_ARRAY_BUFFER_VIEWS:D,TYPED_ARRAY_CONSTRUCTOR:O,TYPED_ARRAY_TAG:U&&P,aTypedArray:F,aTypedArrayConstructor:j,exportTypedArrayMethod:W,exportTypedArrayStaticMethod:H,isView:N,isTypedArray:L,TypedArray:A,TypedArrayPrototype:R}},ec97:function(e,t,n){"use strict";var r=n("ebb5"),i=n("8aa7"),a=r.aTypedArrayConstructor,o=r.exportTypedArrayStaticMethod;o("of",(function(){var e=0,t=arguments.length,n=new(a(this))(t);while(t>e)n[e]=arguments[e++];return n}),i)},eee7:function(e,t,n){"use strict";var r=n("23e7"),i=n("58a8").start,a=n("c8d2"),o=a("trimStart"),s=o?function(){return i(this)}:"".trimStart;r({target:"String",proto:!0,name:"trimStart",forced:o},{trimStart:s,trimLeft:s})},ef4d:function(e,t,n){var r=n("23e7"),i=n("a98e");r({target:"WeakMap",stat:!0},{from:i})},efe9:function(e,t,n){var r=n("746f");r("isConcatSpreadable")},efec:function(e,t,n){var r=n("1a2d"),i=n("6eeb"),a=n("51eb"),o=n("b622"),s=o("toPrimitive"),c=Date.prototype;r(c,s)||i(c,s,a)},f00c:function(e,t,n){var r=n("23e7"),i=n("e285");r({target:"Number",stat:!0},{isFinite:i})},f069:function(e,t,n){"use strict";var r=n("59ed"),i=function(e){var t,n;this.promise=new e((function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r})),this.resolve=r(t),this.reject=r(n)};e.exports.f=function(e){return new i(e)}},f124:function(e,t,n){"use strict";var r=n("23e7"),i=n("c430"),a=n("0a0d");r({target:"WeakSet",proto:!0,real:!0,forced:i},{deleteAll:a})},f183:function(e,t,n){var r=n("23e7"),i=n("e330"),a=n("d012"),o=n("861d"),s=n("1a2d"),c=n("9bf2").f,u=n("241c"),l=n("057f"),f=n("4fad"),h=n("90e3"),d=n("bb2f"),p=!1,v=h("meta"),m=0,y=function(e){c(e,v,{value:{objectID:"O"+m++,weakData:{}}})},g=function(e,t){if(!o(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!s(e,v)){if(!f(e))return"F";if(!t)return"E";y(e)}return e[v].objectID},b=function(e,t){if(!s(e,v)){if(!f(e))return!0;if(!t)return!1;y(e)}return e[v].weakData},T=function(e){return d&&p&&f(e)&&!s(e,v)&&y(e),e},S=function(){E.enable=function(){},p=!0;var e=u.f,t=i([].splice),n={};n[v]=1,e(n).length&&(u.f=function(n){for(var r=e(n),i=0,a=r.length;i<a;i++)if(r[i]===v){t(r,i,1);break}return r},r({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:l.f}))},E=e.exports={enable:S,fastKey:g,getWeakData:b,onFreeze:T};a[v]=!0},f20a:function(e,t,n){n("820e")},f2be:function(e,t,n){var r=n("23e7"),i=n("3fde");r({target:"Set",stat:!0},{of:i})},f36a:function(e,t,n){var r=n("e330");e.exports=r([].slice)},f43e:function(e,t,n){"use strict";var r=n("c430"),i=n("23e7"),a=n("da84"),o=n("c65b"),s=n("825a"),c=n("59ed"),u=a.TypeError;i({target:"Map",proto:!0,real:!0,forced:r},{update:function(e,t){var n=s(this),r=c(n.get),i=c(n.has),a=c(n.set),l=arguments.length;c(t);var f=o(i,n,e);if(!f&&l<3)throw u("Updating absent value");var h=f?o(r,n,e):c(l>2?arguments[2]:void 0)(e,n);return o(a,n,e,t(h,e,n)),n}})},f4b3:function(e,t,n){"use strict";var r=n("23e7"),i=n("d039"),a=n("7b0b"),o=n("c04e"),s=i((function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}));r({target:"Date",proto:!0,forced:s},{toJSON:function(e){var t=a(this),n=o(t,"number");return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},f4dd:function(e,t,n){"use strict";var r=n("23e7"),i=n("d58f").right,a=n("a640"),o=n("2d00"),s=n("605d"),c=a("reduceRight"),u=!s&&o>79&&o<83;r({target:"Array",proto:!0,forced:!c||u},{reduceRight:function(e){return i(this,e,arguments.length,arguments.length>1?arguments[1]:void 0)}})},f4ea:function(e,t,n){(function(t,r,i){e.exports=r(n("21bf"),n("38ba"))})(0,(function(e){return e.mode.CTR=function(){var t=e.lib.BlockCipherMode.extend(),n=t.Encryptor=t.extend({processBlock:function(e,t){var n=this._cipher,r=n.blockSize,i=this._iv,a=this._counter;i&&(a=this._counter=i.slice(0),this._iv=void 0);var o=a.slice(0);n.encryptBlock(o,0),a[r-1]=a[r-1]+1|0;for(var s=0;s<r;s++)e[t+s]^=o[s]}});return t.Decryptor=n,t}(),e.mode.CTR}))},f5b2:function(e,t,n){"use strict";var r=n("23e7"),i=n("6547").codeAt;r({target:"String",proto:!0},{codePointAt:function(e){return i(this,e)}})},f5df:function(e,t,n){var r=n("da84"),i=n("00ee"),a=n("1626"),o=n("c6b6"),s=n("b622"),c=s("toStringTag"),u=r.Object,l="Arguments"==o(function(){return arguments}()),f=function(e,t){try{return e[t]}catch(n){}};e.exports=i?o:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=f(t=u(e),c))?n:l?o(t):"Object"==(r=o(t))&&a(t.callee)?"Arguments":r}},f646:function(e,t,n){"use strict";var r=n("23e7"),i=n("dd2f").find;r({target:"AsyncIterator",proto:!0,real:!0},{find:function(e){return i(this,e)}})},f664:function(e,t,n){var r=n("23e7"),i=n("be8e");r({target:"Math",stat:!0},{fround:i})},f6b4:function(e,t,n){"use strict";var r=n("c532");function i(){this.handlers=[]}i.prototype.use=function(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},i.prototype.forEach=function(e){r.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=i},f6d6:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("e330"),o=n("23cb"),s=i.RangeError,c=String.fromCharCode,u=String.fromCodePoint,l=a([].join),f=!!u&&1!=u.length;r({target:"String",stat:!0,forced:f},{fromCodePoint:function(e){var t,n=[],r=arguments.length,i=0;while(r>i){if(t=+arguments[i++],o(t,1114111)!==t)throw s(t+" is not a valid code point");n[i]=t<65536?c(t):c(55296+((t-=65536)>>10),t%1024+56320)}return l(n,"")}})},f748:function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},f772:function(e,t,n){var r=n("5692"),i=n("90e3"),a=r("keys");e.exports=function(e){return a[e]||(a[e]=i(e))}},f785:function(e,t,n){var r=n("2626");r("Array")},f8c9:function(e,t,n){var r=n("23e7"),i=n("da84"),a=n("d44e");r({global:!0},{Reflect:{}}),a(i.Reflect,"Reflect",!0)},f8cd:function(e,t,n){var r=n("da84"),i=n("5926"),a=r.RangeError;e.exports=function(e){var t=i(e);if(t<0)throw a("The argument can't be less than 0");return t}},f93b:function(e,t,n){"use strict";var r=n("23e7"),i=n("dd2f").every;r({target:"AsyncIterator",proto:!0,real:!0},{every:function(e){return i(this,e)}})},fa9e:function(e,t,n){"use strict";var r=n("ebb5"),i=n("a258").findLast,a=r.aTypedArray,o=r.exportTypedArrayMethod;o("findLast",(function(e){return i(a(this),e,arguments.length>1?arguments[1]:void 0)}))},faa1:function(e,t,n){"use strict";var r,i="object"===typeof Reflect?Reflect:null,a=i&&"function"===typeof i.apply?i.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};function o(e){console&&console.warn&&console.warn(e)}r=i&&"function"===typeof i.ownKeys?i.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var s=Number.isNaN||function(e){return e!==e};function c(){c.init.call(this)}e.exports=c,e.exports.once=T,c.EventEmitter=c,c.prototype._events=void 0,c.prototype._eventsCount=0,c.prototype._maxListeners=void 0;var u=10;function l(e){if("function"!==typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function f(e){return void 0===e._maxListeners?c.defaultMaxListeners:e._maxListeners}function h(e,t,n,r){var i,a,s;if(l(n),a=e._events,void 0===a?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),a=e._events),s=a[t]),void 0===s)s=a[t]=n,++e._eventsCount;else if("function"===typeof s?s=a[t]=r?[n,s]:[s,n]:r?s.unshift(n):s.push(n),i=f(e),i>0&&s.length>i&&!s.warned){s.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=s.length,o(c)}return e}function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=d.bind(r);return i.listener=n,r.wrapFn=i,i}function v(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"===typeof i?n?[i.listener||i]:[i]:n?b(i):y(i,i.length)}function m(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"===typeof n)return 1;if(void 0!==n)return n.length}return 0}function y(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function g(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function b(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}function T(e,t){return new Promise((function(n,r){function i(n){e.removeListener(t,a),r(n)}function a(){"function"===typeof e.removeListener&&e.removeListener("error",i),n([].slice.call(arguments))}E(e,t,a,{once:!0}),"error"!==t&&S(e,i,{once:!0})}))}function S(e,t,n){"function"===typeof e.on&&E(e,"error",t,n)}function E(e,t,n,r){if("function"===typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!==typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function i(a){r.once&&e.removeEventListener(t,i),n(a)}))}}Object.defineProperty(c,"defaultMaxListeners",{enumerable:!0,get:function(){return u},set:function(e){if("number"!==typeof e||e<0||s(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");u=e}}),c.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},c.prototype.setMaxListeners=function(e){if("number"!==typeof e||e<0||s(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},c.prototype.getMaxListeners=function(){return f(this)},c.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var r="error"===e,i=this._events;if(void 0!==i)r=r&&void 0===i.error;else if(!r)return!1;if(r){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var c=i[e];if(void 0===c)return!1;if("function"===typeof c)a(c,this,t);else{var u=c.length,l=y(c,u);for(n=0;n<u;++n)a(l[n],this,t)}return!0},c.prototype.addListener=function(e,t){return h(this,e,t,!1)},c.prototype.on=c.prototype.addListener,c.prototype.prependListener=function(e,t){return h(this,e,t,!0)},c.prototype.once=function(e,t){return l(t),this.on(e,p(this,e,t)),this},c.prototype.prependOnceListener=function(e,t){return l(t),this.prependListener(e,p(this,e,t)),this},c.prototype.removeListener=function(e,t){var n,r,i,a,o;if(l(t),r=this._events,void 0===r)return this;if(n=r[e],void 0===n)return this;if(n===t||n.listener===t)0===--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!==typeof n){for(i=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){o=n[a].listener,i=a;break}if(i<0)return this;0===i?n.shift():g(n,i),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,o||t)}return this},c.prototype.off=c.prototype.removeListener,c.prototype.removeAllListeners=function(e){var t,n,r;if(n=this._events,void 0===n)return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0===--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var i,a=Object.keys(n);for(r=0;r<a.length;++r)i=a[r],"removeListener"!==i&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(t=n[e],"function"===typeof t)this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},c.prototype.listeners=function(e){return v(this,e,!0)},c.prototype.rawListeners=function(e){return v(this,e,!1)},c.listenerCount=function(e,t){return"function"===typeof e.listenerCount?e.listenerCount(t):m.call(e,t)},c.prototype.listenerCount=m,c.prototype.eventNames=function(){return this._eventsCount>0?r(this._events):[]}},fb15:function(e,t,n){"use strict";if(n.r(t),"undefined"!==typeof window){var r=window.document.currentScript,i=n("8875");r=i(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:i});var a=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);a&&(n.p=a[1])}n("a4d3"),n("e01a"),n("d3b7"),n("d28b"),n("e260"),n("3ca3"),n("ddb0"),n("d9e2"),n("fb6a"),n("b0c0"),n("a630"),n("ac1f"),n("00b4");function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function s(e,t){if(e){if("string"===typeof e)return o(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}function c(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=s(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,a=e},f:function(){try{o||null==n["return"]||n["return"]()}finally{if(c)throw a}}}}n("e6cf");function u(e,t,n,r,i,a,o){try{var s=e[a](o),c=s.value}catch(u){return void n(u)}s.done?t(c):Promise.resolve(c).then(r,i)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var a=e.apply(t,n);function o(e){u(a,r,i,o,s,"next",e)}function s(e){u(a,r,i,o,s,"throw",e)}o(void 0)}))}}function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function p(e,t,n){return t&&d(e.prototype,t),n&&d(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n("96cf"),n("99af"),n("cca6"),n("d81d"),n("25f0"),n("8b09"),n("907a"),n("9a8c"),n("a975"),n("735e"),n("c1ac"),n("d139"),n("3a7b"),n("d5d6"),n("82f8"),n("e91f"),n("60bd"),n("5f96"),n("3280"),n("3fcc"),n("ca91"),n("25a1"),n("cd26"),n("3c5d"),n("2954"),n("649e"),n("219c"),n("170b"),n("b39a"),n("72f7"),n("159b"),n("5cc6");function m(e,t){var n=new Uint8Array((0|e.byteLength)+(0|t.byteLength));return n.set(e,0),n.set(t,0|e.byteLength),n}function y(e){for(var t=window.atob(e),n=t.length,r=new Uint8Array(n),i=0;i<n;i++)r[i]=t.charCodeAt(i);return r.buffer}function g(e){for(var t=e.length>>1,n=new Uint8Array(t),r=0;r<t;r++)n[r]=parseInt(e.substr(r<<1,2),16);return n}function b(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:8*e.byteLength,r=Math.ceil((n-t)/8),i=new Uint8Array(r),a=t>>>3,o=(n>>>3)-1,s=7&t,c=8-s,u=8-n&7,l=0;l<r;++l){var f=0;l<o&&(f=e[a+l+1]>>c,l==o-1&&u<8&&(f>>=u,f<<=u)),i[l]=e[a+l]<<s|f}return i}function T(e){for(var t="",n=8192,r=0;r<e.length/n;r++)t+=String.fromCharCode.apply(null,e.slice(r*n,(r+1)*n));return t+=String.fromCharCode.apply(null,e.slice(r*n)),t}var S=function(){function e(t){h(this,e),this.src=new DataView(t.buffer,t.byteOffset,t.byteLength),this.bitpos=0,this.byte=this.src.getUint8(0),this.bytepos=0}return p(e,[{key:"readBits",value:function(e){if(64<(0|e)||0===(0|e))throw new Error("too big");for(var t=0,n=e;n>0;--n)t=(0|t)<<1|(0|this.byte)>>8-++this.bitpos&1,(0|this.bitpos)>=8&&(this.byte=this.src.getUint8(++this.bytepos),this.bitpos&=7);return t}},{key:"skipBits",value:function(e){return this.bitpos+=7&(0|e),this.bytepos+=(0|e)>>>3,this.bitpos>7&&(this.bitpos&=7,++this.bytepos),this.finished()?this.bytepos-this.src.byteLength-this.src.bitpos:(this.byte=this.src.getUint8(this.bytepos),0)}},{key:"finished",value:function(){return this.bytepos>=this.src.byteLength}}]),e}();function E(e,t){var n,r=[0,79764919,159529838,222504665,319059676,398814059,445009330,507990021,638119352,583659535,797628118,726387553,890018660,835552979,1015980042,944750013,1276238704,1221641927,1167319070,1095957929,1595256236,1540665371,1452775106,1381403509,1780037320,1859660671,1671105958,1733955601,2031960084,2111593891,1889500026,1952343757,2552477408,2632100695,2443283854,2506133561,2334638140,2414271883,2191915858,2254759653,3190512472,3135915759,3081330742,3009969537,2905550212,2850959411,2762807018,2691435357,3560074640,3505614887,3719321342,3648080713,3342211916,3287746299,3467911202,3396681109,4063920168,4143685023,4223187782,4286162673,3779000052,3858754371,3904687514,3967668269,881225847,809987520,1023691545,969234094,662832811,591600412,771767749,717299826,311336399,374308984,453813921,533576470,25881363,88864420,134795389,214552010,2023205639,2086057648,1897238633,1976864222,1804852699,1867694188,1645340341,1724971778,1587496639,1516133128,1461550545,1406951526,1302016099,1230646740,1142491917,1087903418,2896545431,2825181984,2770861561,2716262478,3215044683,3143675388,3055782693,3001194130,2326604591,2389456536,2200899649,2280525302,2578013683,2640855108,2418763421,2498394922,3769900519,3832873040,3912640137,3992402750,4088425275,4151408268,4197601365,4277358050,3334271071,3263032808,3476998961,3422541446,3585640067,3514407732,3694837229,3640369242,1762451694,1842216281,1619975040,1682949687,2047383090,2127137669,1938468188,2001449195,1325665622,1271206113,1183200824,1111960463,1543535498,1489069629,1434599652,1363369299,622672798,568075817,748617968,677256519,907627842,853037301,1067152940,995781531,51762726,131386257,177728840,240578815,269590778,349224269,429104020,491947555,4046411278,4126034873,4172115296,4234965207,3794477266,3874110821,3953728444,4016571915,3609705398,3555108353,3735388376,3664026991,3290680682,3236090077,3449943556,3378572211,3174993278,3120533705,3032266256,2961025959,2923101090,2868635157,2813903052,2742672763,2604032198,2683796849,2461293480,2524268063,2284983834,2364738477,2175806836,2238787779,1569362073,1498123566,1409854455,1355396672,1317987909,1246755826,1192025387,1137557660,2072149281,2135122070,1912620623,1992383480,1753615357,1816598090,1627664531,1707420964,295390185,358241886,404320391,483945776,43990325,106832002,186451547,266083308,932423249,861060070,1041341759,986742920,613929101,542559546,756411363,701822548,3316196985,3244833742,3425377559,3370778784,3601682597,3530312978,3744426955,3689838204,3819031489,3881883254,3928223919,4007849240,4037393693,4100235434,4180117107,4259748804,2310601993,2373574846,2151335527,2231098320,2596047829,2659030626,2470359227,2550115596,2947551409,2876312838,2788305887,2733848168,3165939309,3094707162,3040238851,2985771188],i=4294967295;for(n=0;n<t;n++)i=i<<8^r[255&(i>>24^e[n])];return i}function _(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=e.getUint32(t,n),i=e.getUint32(t+4,n),a=n?r+Math.pow(2,32)*i:Math.pow(2,32)*r+i;return a}var k=function(){function e(){h(this,e)}return p(e,null,[{key:"H264",get:function(){return 1}},{key:"AAC",get:function(){return 2}},{key:"H265",get:function(){return 3}},{key:"G711A",get:function(){return 4}},{key:"PCMA_W",get:function(){return 5}},{key:"map",get:function(){var t;return t={},v(t,e.H264,"video"),v(t,e.H265,"video"),v(t,e.AAC,"audio"),v(t,e.G711A,"audio"),v(t,e.PCMA_W,"audio"),v(t,e.PCMA,"audio"),t}},{key:"string_map",get:function(){return{H264:e.H264,H265:e.H265,AAC:e.AAC,PCMA:e.G711A,"MP4A-LATM":e.AAC,"MPEG4-GENERIC":e.AAC,G711alaw:e.G711A,PCMA_W:e.PCMA_W}}}]),e}(),w=k,A=[0,0,0,1],R=function(){function e(t,n,r,i,a,o){h(this,e),this.data=new Uint8Array(A.length+n.length),this.data.set(A,0),this.data.set(n,A.length),this.dts=r,this.pts=i||this.dts,this.ntype=t,this.nri=a,this.payloadType=o}return p(e,[{key:"appendData",value:function(e){this.data=m(this.data,e)}},{key:"toString",value:function(){return"".concat(e.type(this),"(").concat(this.data.byteLength,"): NRI: ").concat(this.getNri(),", PTS: ").concat(this.pts,", DTS: ").concat(this.dts)}},{key:"getNri",value:function(){return this.nri>>5}},{key:"type",value:function(){return this.ntype}},{key:"isKeyframe",value:function(){return this.payloadType===w.H264?this.ntype==e.IDR:this.ntype>=16&&this.ntype<=20}},{key:"isParameterSet",value:function(){return this.payloadType===w.H264?this.ntype===e.SPS||this.ntype===e.PPS:this.ntype===e.VPS||this.ntype===e.HEVC_SPS||this.ntype===e.HEVC_PPS}},{key:"getSize",value:function(){return 5+this.data.byteLength}},{key:"getData",value:function(){var e=new Uint8Array(5+this.data.byteLength),t=new DataView(e.buffer);return t.setUint32(0,this.data.byteLength+1),t.setUint8(4,0|96&this.nri|31&this.ntype),e.set(this.data,5),e}}],[{key:"NDR",get:function(){return 1}},{key:"IDR",get:function(){return 5}},{key:"SEI",get:function(){return 6}},{key:"SPS",get:function(){return 7}},{key:"PPS",get:function(){return 8}},{key:"STAP_A",get:function(){return 24}},{key:"STAP_B",get:function(){return 25}},{key:"FU_A",get:function(){return 28}},{key:"FU_B",get:function(){return 29}},{key:"VPS",get:function(){return 32}},{key:"HEVC_SPS",get:function(){return 33}},{key:"HEVC_PPS",get:function(){return 34}},{key:"TYPES",get:function(){var t;return t={},v(t,e.IDR,"IDR"),v(t,e.SEI,"SEI"),v(t,e.SPS,"SPS"),v(t,e.PPS,"PPS"),v(t,e.NDR,"NDR"),v(t,e.VPS,"VPS"),v(t,e.HEVC_SPS,"SPS"),v(t,e.HEVC_PPS,"PPS"),t}},{key:"type",value:function(t){return t.ntype in e.TYPES?e.TYPES[t.ntype]:"UNKNOWN"}}]),e}(),x=(n("466d"),n("a15b"),function(){function e(t){h(this,e),this.data=t,this.bytesAvailable=this.data.byteLength,this.word=0,this.bitsAvailable=0}return p(e,[{key:"loadWord",value:function(){var e=this.data.byteLength-this.bytesAvailable,t=new Uint8Array(4),n=Math.min(4,this.bytesAvailable);if(0===n)throw new Error("no bytes available");t.set(this.data.subarray(e,e+n)),this.word=new DataView(t.buffer,t.byteOffset,t.byteLength).getUint32(0),this.bitsAvailable=8*n,this.bytesAvailable-=n}},{key:"skipBits",value:function(e){var t;this.bitsAvailable>e?(this.word<<=e,this.bitsAvailable-=e):(e-=this.bitsAvailable,t=e>>3,e-=t<<3,this.bytesAvailable-=t,this.loadWord(),this.word<<=e,this.bitsAvailable-=e)}},{key:"readBits",value:function(e){var t=Math.min(this.bitsAvailable,e),n=this.word>>>32-t;return e>32&&Log$3.error("Cannot read more than 32 bits at a time"),this.bitsAvailable-=t,this.bitsAvailable>0?this.word<<=t:this.bytesAvailable>0&&this.loadWord(),t=e-t,t>0?n<<t|this.readBits(t):n}},{key:"readByte",value:function(){return this.readBits(8)}},{key:"skipLZ",value:function(){var e;for(e=0;e<this.bitsAvailable;++e)if(0!==(this.word&2147483648>>>e))return this.word<<=e,this.bitsAvailable-=e,e;return this.loadWord(),e+this.skipLZ()}},{key:"skipUEG",value:function(){this.skipBits(1+this.skipLZ())}},{key:"skipEG",value:function(){this.skipBits(1+this.skipLZ())}},{key:"readUEG",value:function(){var e=this.skipLZ();return this.readBits(e+1)-1}},{key:"readEG",value:function(){var e=this.readUEG();return 1&e?1+e>>>1:-1*(e>>>1)}},{key:"readBoolean",value:function(){return 1===this.readBits(1)}},{key:"readUByte",value:function(){return this.readBits(8)}},{key:"readUShort",value:function(){return this.readBits(16)}},{key:"readUInt",value:function(){return this.readBits(32)}},{key:"destroy",value:function(){}}]),e}()),C=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};h(this,e),this.remuxer=t,this.track=t.mp4track||{},this.firstFound=!1}return p(e,[{key:"msToScaled",value:function(e){return(e-this.remuxer.timeOffset)*this.remuxer.scaleFactor}},{key:"parseSPS",value:function(t){var n=e.readSPS(new Uint8Array(t));this.track.width=n.width,this.track.height=n.height,this.track.sps=[new Uint8Array(t)],this.track.codec="avc1.";for(var r=new DataView(t.buffer,t.byteOffset+1,4),i=0;i<3;++i){var a=r.getUint8(i).toString(16);a.length<2&&(a="0"+a),this.track.codec+=a}}},{key:"parsePPS",value:function(e){this.track.pps=[new Uint8Array(e)]}},{key:"parseNAL",value:function(t){if(!t)return!1;var n,r,i,a,o,s,c=null;switch(t.type()){case R.NDR:case R.IDR:t.sliceType=e.parceSliceHeader(t.data),t.isKeyframe()&&!this.firstFound&&(this.firstFound=!0),c=!!this.firstFound;break;case R.PPS:c=!1,this.track.pps||(this.parsePPS(t.getData().subarray(4)),!this.remuxer.readyToDecode&&this.track.pps&&this.track.sps&&(this.remuxer.readyToDecode=!0));break;case R.SPS:c=!1,this.firstFound||navigator.vendor.match(/apple/i)||navigator.platform.match(/linux/i)||(this.firstFound=!0,c=!0),this.track.sps||(this.parseSPS(t.getData().subarray(4)),!this.remuxer.readyToDecode&&this.track.pps&&this.track.sps&&(this.remuxer.readyToDecode=!0));break;case R.SEI:c=!1,n=new DataView(t.data.buffer,t.data.byteOffset,t.data.byteLength),r=0,i=n.getUint8(r),++r,a=0,s=n.getUint8(r),++r;while(255===s)a+=s,s=n.getUint8(r),++r;a+=s,o=t.data.subarray(r,r+16),r+=16,console.log("PT: ".concat(i,", PS: ").concat(a,", UUID: ").concat(Array.from(o).map((function(e){return("0"+e.toString(16)).slice(-2)})).join("")));break;case R.EOSEQ:case R.EOSTR:c=!1;default:}return null===c&&t.getNri()>0&&(c=!0),c}}],[{key:"parceSliceHeader",value:function(e){var t=new x(e);t.readUEG();var n=t.readUEG();return t.readUEG(),t.readUByte(),n}},{key:"skipScalingList",value:function(e,t){for(var n,r=8,i=8,a=0;a<t;a++)0!==i&&(n=e.readEG(),i=(r+n+256)%256),r=0===i?r:i}},{key:"readSPS",value:function(t){var n,r,i,a,o,s,c=new x(t),u=0,l=0,f=0,h=0,d=1;if(c.readUByte(),n=c.readUByte(),c.readBits(5),c.skipBits(3),c.readUByte(),c.skipUEG(),100===n||110===n||122===n||244===n||44===n||83===n||86===n||118===n||128===n){var p=c.readUEG();if(3===p&&c.skipBits(1),c.skipUEG(),c.skipUEG(),c.skipBits(1),c.readBoolean()){s=3!==p?8:12;for(var v=0;v<s;++v)c.readBoolean()&&(v<6?e.skipScalingList(c,16):e.skipScalingList(c,64))}}c.skipUEG();var m=c.readUEG();if(0===m)c.readUEG();else if(1===m){c.skipBits(1),c.skipEG(),c.skipEG(),r=c.readUEG();for(var y=0;y<r;++y)c.skipEG()}if(c.skipUEG(),c.skipBits(1),i=c.readUEG(),a=c.readUEG(),o=c.readBits(1),0===o&&c.skipBits(1),c.skipBits(1),c.readBoolean()&&(u=c.readUEG(),l=c.readUEG(),f=c.readUEG(),h=c.readUEG()),c.readBoolean()){if(c.readBoolean()){var g,b=c.readUByte();switch(b){case 1:g=[1,1];break;case 2:g=[12,11];break;case 3:g=[10,11];break;case 4:g=[16,11];break;case 5:g=[40,33];break;case 6:g=[24,11];break;case 7:g=[20,11];break;case 8:g=[32,11];break;case 9:g=[80,33];break;case 10:g=[18,11];break;case 11:g=[15,11];break;case 12:g=[64,33];break;case 13:g=[160,99];break;case 14:g=[4,3];break;case 15:g=[3,2];break;case 16:g=[2,1];break;case 255:g=[c.readUByte()<<8|c.readUByte(),c.readUByte()<<8|c.readUByte()];break}g&&(d=g[0]/g[1])}if(c.readBoolean()&&c.skipBits(1),c.readBoolean()&&(c.skipBits(4),c.readBoolean()&&c.skipBits(24)),c.readBoolean()&&(c.skipUEG(),c.skipUEG()),c.readBoolean()){var T=c.readUInt(),S=c.readUInt(),E=c.readBoolean(),_=S/(2*T);console.log("timescale: ".concat(S,"; unitsInTick: ").concat(T,"; fixedFramerate: ").concat(E,"; avgFrameDuration: ").concat(_))}}return{width:Math.ceil((16*(i+1)-2*u-2*l)*d),height:(2-o)*(a+1)*16-(o?2:4)*(f+h)}}},{key:"readSliceType",value:function(e){return e.readUByte(),e.readUEG(),e.readUEG()}}]),e}(),I=(n("b680"),function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};h(this,e),this.remuxer=t,this.track=t.mp4track||{}}return p(e,[{key:"parseSPS",value:function(e){var t=this.readSPS(e);this.track={width:t.codec_size.width,height:t.codec_size.height,codec:"hvc1.".concat(t.profile_idc,".1.L").concat(t.level_idc,".B0")}}},{key:"readSPS",value:function(e){var t=this.ebsp2rbsp(e),n=new x(t),r={};n.readBits(16),n.readBits(4);var i=n.readBits(3);n.readBits(1),this._hvcc_parse_ptl(n,r,i),n.readUEG();var a=0,o=n.readUEG();3==o&&(a=n.readBits(1)),r.sar_width=r.sar_height=1,r.conf_win_left_offset=r.conf_win_right_offset=r.conf_win_top_offset=r.conf_win_bottom_offset=0,r.def_disp_win_left_offset=r.def_disp_win_right_offset=r.def_disp_win_top_offset=r.def_disp_win_bottom_offset=0;var s=n.readUEG(),c=n.readUEG(),u=n.readBits(1);u&&(r.conf_win_left_offset=n.readUEG(),r.conf_win_right_offset=n.readUEG(),r.conf_win_top_offset=n.readUEG(),r.conf_win_bottom_offset=n.readUEG(),1===r.default_display_window_flag&&(r.conf_win_left_offset+r.def_disp_win_left_offset,r.conf_win_right_offset+r.def_disp_win_right_offset,r.conf_win_top_offset+r.def_disp_win_top_offset,r.conf_win_bottom_offset,r.def_disp_win_bottom_offset));var l=n.readUEG()+8;n.readUEG();for(var f=n.readUEG(),h=n.readBits(1)?0:i;h<=i;h++)this._skip_sub_layer_ordering_info(n);n.readUEG(),n.readUEG(),n.readUEG(),n.readUEG(),n.readUEG(),n.readUEG(),n.readBits(1)&&n.readBits(1)&&this._skip_scaling_list_data(n),n.readBits(1),n.readBits(1),n.readBits(1)&&(n.readBits(4),n.readBits(4),n.readUEG(),n.readUEG(),n.readBits(1));for(var d=[],p=n.readUEG(),v=0;v<p;v++){var m=this._parse_rps(n,v,p,d);if(m<0)return m}if(n.readBits(1))for(var y=n.readUEG(),g=0;g<y;g++){var b=Math.min(f+4,16);if(b>32){for(var T=b/32,S=b%32,E=0;E<T;E++)n.readBits(32);n.readBits(S)}else n.readBits(b);n.readBits(1)}var _=1;n.readBits(1),n.readBits(1),n.readBits(1)&&this._hvcc_parse_vui(n,r,i);var k=this.getProfileString(r.profile_idc),w=this.getLevelString(r.level_idc),A=1;1===r.sar_width&&1===r.sar_height||(A=r.sar_width/r.sar_height);var R=s,C=c,I=1!==o&&2!=o||0!==a?1:2,P=1===o&&0===a?2:1;R-=I*(r.conf_win_left_offset+r.conf_win_right_offset),C-=P*(r.conf_win_top_offset+r.conf_win_bottom_offset);var O=Math.ceil(R*A);return n.destroy(),n=null,{profile_string:k,level_string:w,profile_idc:r.profile_idc,level_idc:r.level_idc,bit_depth:l,ref_frames:_,chroma_format:o,chroma_format_string:this.getChromaFormatString(o),frame_rate:{fixed:r.fps_fixed,fps:r.fps,fps_den:r.fps_den,fps_num:r.fps_num},sar_ratio:{width:r.sar_width,height:r.sar_height},codec_size:{width:R,height:C},present_size:{width:O,height:C}}}},{key:"ebsp2rbsp",value:function(e){for(var t=e,n=t.byteLength,r=new Uint8Array(n),i=0,a=0;a<n;a++)a>=2&&3===t[a]&&0===t[a-1]&&0===t[a-2]||(r[i]=t[a],i++);return new Uint8Array(r.buffer,0,i)}},{key:"_hvcc_parse_ptl",value:function(e,t,n){e.readBits(2);var r=e.readBits(1),i=e.readBits(5);e.readBits(32),e.readBits(32),e.readBits(16);var a=e.readByte();void 0===t.tier_flag||void 0===t.level_idc||t.tier_flag<r?t.level_idc=a:t.level_idc=Math.max(t.level_idc,a),t.profile_idc=Math.max(void 0===t.profile_idc?0:t.profile_idc,i);for(var o=[],s=[],c=0;c<n;c++)o.push(e.readBits(1)),s.push(e.readBits(1));if(n>0)for(var u=n;u<8;u++)e.readBits(2);for(var l=0;l<n;l++)o[l]&&(e.readBits(32),e.readBits(32),e.readBits(24)),s[l]&&e.readByte()}},{key:"_parse_rps",value:function(e,t,n,r){if(t&&e.readBits(1)){if(t>=n)return-1;e.readBits(1),e.readUEG(),r[t]=0;for(var i=0;i<=r[t-1];i++){var a=0,o=e.readBits(1);o||(a=e.readBits(1)),(o||a)&&r[t]++}}else{var s=e.readUEG(),c=e.readUEG();r[t]=s+c;for(var u=0;u<s;u++)e.readUEG(),e.readBits(1);for(var l=0;l<c;l++)e.readUEG(),e.readBits(1)}return 0}},{key:"_hvcc_parse_vui",value:function(e,t,n){e.readBits(1)&&255==e.readByte()&&(t.sar_width=e.readBits(16),t.sar_height=e.readBits(16)),e.readBits(1)&&e.readBits(1),e.readBits(1)&&(e.readBits(4),e.readBits(1)&&e.readBits(24)),e.readBits(1)&&(e.readUEG(),e.readUEG()),e.readBits(3),t.default_display_window_flag=e.readBits(1),t.default_display_window_flag&&(t.def_disp_win_left_offset=e.readUEG(),t.def_disp_win_right_offset=e.readUEG(),t.def_disp_win_top_offset=e.readUEG(),t.def_disp_win_bottom_offset=e.readUEG()),e.readBits(1)&&(this._skip_timing_info(e,t),e.readBits(1)&&this._skip_hrd_parameters(e,t,1,n)),e.readBits(1)&&(e.readBits(3),e.readUEG(),e.readUEG(),e.readUEG(),e.readUEG(),e.readUEG())}},{key:"_skip_sub_layer_ordering_info",value:function(e){e.readUEG(),e.readUEG(),e.readUEG()}},{key:"_skip_scaling_list_data",value:function(e,t,n){for(var r=0;r<=t;r++)e.readUEG(),e.readUEG(),n&&(e.readUEG(),e.readUEG()),e.readBits(1)}},{key:"_skip_timing_info",value:function(e,t){t.fps_den=e.readBits(32),t.fps_num=e.readBits(32),t.fps_den>0&&(t.fps=t.fps_num/t.fps_den);var n=0;e.readBits(1)&&(n=e.readUEG(),n>=0&&(t.fps/=n+1))}},{key:"_skip_hrd_parameters",value:function(e,t,n,r){var i=0,a=0,o=0;if(n&&(a=e.readBits(1),o=e.readBits(1),a||o)){var s=e.readBits(1);s&&e.readBits(19),e.readByte(),s&&e.readBits(4),e.readBits(15)}for(var c=0;c<=r;c++){var u=0,l=0,f=0,h=e.readBits(1);t.fps_fixed=h,h||(f=e.readBits(1)),f?e.readUEG():l=e.readBits(1),l||(u=e.readUEG(e)),a&&this._skip_sub_layer_hrd_parameters(e,u,i),o&&this._skip_sub_layer_hrd_parameters(e,u,i)}}},{key:"_skip_sub_layer_hrd_parameters",value:function(e,t,n){for(var r=0;r<=t;r++)e.readUEG(),e.readUEG(),n&&(e.readUEG(),e.readUEG()),e.readBits(1)}},{key:"getProfileString",value:function(e){switch(e){case 1:return"Main";case 2:return"Main10";case 3:return"MainSP";case 4:return"Rext";case 9:return"SCC";default:return"Unknown"}}},{key:"getLevelString",value:function(e){return(e/30).toFixed(1)}},{key:"getChromaFormatString",value:function(e){switch(e){case 0:return"4:0:0";case 1:return"4:2:0";case 2:return"4:2:2";case 3:return"4:4:4";default:return"Unknown"}}}]),e}()),P=(n("cfc3"),function(){function e(t){h(this,e),this.audioType=t.audioType,this.samples=new Float32Array,this.flushingTime=t.flushingTime||50,this.channels=t.channels||1,this.sampleRate=t.sampleRate||8e3,this.flush=this.flush.bind(this),this.audioCtx=new(window.AudioContext||window.webkitAudioContext),this.gainNode=this.audioCtx.createGain(),this.gainNode.gain.value=t.volume?(t.volume/100).toFixed(2):0,this.gainNode.connect(this.audioCtx.destination),this.startTime=this.audioCtx.currentTime,this.interval=setInterval(this.flush,this.flushingTime)}return p(e,[{key:"play",value:function(t){var n=e.shortToFloatData(t);this.feed(n)}},{key:"setVolume",value:function(e){this.gainNode.gain.value=(e/100).toFixed(2)}},{key:"getVolume",value:function(){return parseInt(100*this.gainNode.gain.value)}},{key:"pause",value:function(){"running"===this.audioCtx.state&&this.audioCtx.suspend()}},{key:"resume",value:function(){"suspended"===this.audioCtx.state&&this.audioCtx.resume()}},{key:"close",value:function(){this.interval&&clearInterval(this.interval),this.audioCtx.close(),this.samples=null,this.audioCtx=null}},{key:"getTimestamp",value:function(){return this.audioCtx?this.audioCtx.currentTime:0}},{key:"feed",value:function(e){var t=new Float32Array(this.samples.length+e.length);t.set(this.samples,0),t.set(e,this.samples.length),this.samples=t}},{key:"flush",value:function(){if(this.channels&&this.sampleRate&&this.samples.length){for(var e=this.audioCtx.createBufferSource(),t=this.samples.length/this.channels,n=this.audioCtx.createBuffer(this.channels,t,this.sampleRate),r=0;r!=this.channels;++r)for(var i=n.getChannelData(r),a=r,o=50,s=0;s!=t;++s)i[s]=this.samples[a],s<50&&(i[s]=i[s]*s/50),s>=t-51&&(i[s]=i[s]*o--/50),a+=this.channels;this.startTime<this.audioCtx.currentTime&&(this.startTime=this.audioCtx.currentTime),e.buffer=n,e.connect(this.gainNode),e.start(this.startTime),this.startTime+=n.duration,this.samples=new Float32Array}}},{key:"createMediaStream",value:function(){var e=this.audioCtx.createMediaStreamDestination();return this.gainNode.connect(e),e}}],[{key:"isSupported",get:function(){return!(!window.AudioContext&&!window.webkitAudioContext)}},{key:"shortToFloatData",value:function(e){for(var t=e.length,n=new Float32Array(t),r=0;r!=t;++r)n[r]=e[r]/32768;return n}}]),e}()),O=P,D=(n("a9e3"),n("5319"),n("1276"),n("4de4"),/([:\-_]+(.))/g),U=/^moz([A-Z])/,M=Number(document.documentMode),B=function(e){return e.replace(D,(function(e,t,n,r){return r?n.toUpperCase():n})).replace(U,"Moz$1")};(function(){document.addEventListener})(),function(){document.removeEventListener}();function N(e,t,n){if(e&&t)if(e.length){var r,i=c(e);try{for(i.s();!(r=i.n()).done;){var a=r.value;N(a,t,n)}}catch(s){i.e(s)}finally{i.f()}}else if("object"===f(t))for(var o in t)t.hasOwnProperty(o)&&N(e,o,t[o]);else t=B(t),"opacity"===t&&M<9?e.style.filter=isNaN(n)?"":"alpha(opacity="+100*n+")":e.style[t]=n}var L=function(){var e=function(){return(65536*(1+Math.random())|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()},F=function(){return navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)},j=function(e){return"string"===typeof e?document.querySelector(e):e},W="\n .__is_full__ {\n position: absolute;\n touch-action: none;\n overflow: hidden;\n width: 100%!important;\n height: 100%!important;\n margin: 0;\n }\n ",H=function(){var e=document.createElement("style");e.appendChild(document.createTextNode(W));var t=document.getElementsByTagName("head")[0];return t.appendChild(e),e},V=function(e){var t=t;function n(e){t&&t.classList.contains("__is_full__")&&e.preventDefault()}return e.addEventListener("touchmove",n,{passive:!1}),function(){e.removeEventListener("touchmove",n)}},q="\n position: fixed;\n z-index: 999;\n left: 0;\n height: 100%;\n width: 100%;\n top: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n background: #000;\n ",z=function(e){return"\n position: fixed;\n z-index: 999;\n left: 0px;\n display: flex;\n align-items: center;\n justify-content: center;\n height: ".concat(e.offsetWidth,"px;\n width: ").concat(e.offsetHeight,"px;\n top: 0px;\n transform: rotate(90deg);\n transform-origin: 0 0;\n margin-left: ").concat(e.offsetWidth,"px;\n background: #000;\n ")},G=function(){return f(window.orientation)?window.orientation:screen.orientation?screen.orientation.angle:0},Y=function(){var e=G();return"\n position: fixed;\n z-index: 999;\n left: 0px;\n display: flex;\n align-items: center;\n justify-content: center;\n height: ".concat(window.innerWidth,"px;\n width: ").concat(window.innerHeight,"px;\n top: 0px;\n transform: rotate(").concat(90==e?-90:90,"deg);\n transform-origin: ").concat(90==e?"right":0," 0;\n margin-left: ").concat(90==e?-window.innerHeight:window.innerWidth,"px;\n background: #000;\n ")},K=function(e){return e.requestFullscreen?(e.requestFullscreen(),!0):e.msRequestFullscreen?(e.msRequestFullscreen(),!0):e.mozRequestFullScreen?(e.mozRequestFullScreen(),!0):!!e.webkitRequestFullScreen&&(e.webkitRequestFullScreen(),!0)},X=function(){document.exitFullscreen?document.exitFullscreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen&&document.webkitCancelFullScreen()},Q=document.body,$=function(){function e(t){var n=this;if(h(this,e),this.$el=j(t.el),!(this.$el instanceof HTMLElement))throw"el must be Element or Selector!";if(t.toggle&&(this.$toggle=j(t.toggle),!(this.$toggle instanceof HTMLElement)))throw"toggle must be Element or Selector!";this.cssText=this.$el.style.cssText,this.config=t,this.is_full=!1,this.__style__=H(),this.isNative=t.nativeFirst&&document.fullscreenEnabled,this.disableScroll&&(this.__un_bind_touchmove__=V(this.$el)),this.__need3__()&&this.__setCss__(3);var r=function(){Q&&!Q.classList.contains("__is_full__")?n.requestFullscreen():n.exitFullScreen()};this.toggle=r.bind(this),this.$toggle instanceof HTMLElement&&this.$toggle.addEventListener("click",r,!1);var i=window.matchMedia("(orientation: landscape)"),a=function(e){if(e.matches){if(n.isLock)return void("landscape"===n.lockOr?n.__setCss__(3):n.__setCss__(4));n.is_full?n.isNative?n.__setCss__(1):n.__setCss__(3):t.autoRotate&&F()&&n.__setCss__(3)}else{if(n.isLock)return void("landscape"===n.lockOr?n.__setCss__(4):n.__setCss__(3));n.is_full?t.forceRotate&&(n.isNative?n.__setCss__(1):n.__setCss__(2)):t.autoRotate&&F()&&n.__setCss__(1)}};i.addEventListener("change",a);var o=function(){document.fullscreenElement?(Q&&Q.classList.add("__is_full__"),n.is_full=!0):(Q&&Q.classList.remove("__is_full__"),n.is_full=!1)};this.$el.addEventListener("fullscreenchange",o),this.__destroy__=function(){i.removeEventListener("change",a),n.$toggle&&n.$toggle.removeEventListener("click",r),n.$el.removeEventListener("fullscreenchange",o),n.toggle=null,n.$toggle=null,n.$el=null,n.__destroy__=null,n.__style__.parentNode.removeChild(n.__style__),n.__style__=null,r=null,a=null,o=null}}return p(e,[{key:"canLock",value:function(){return F()}},{key:"lock",value:function(e){F()&&(this.isLock||(e||(e=window.innerWidth>window.innerHeight?"landscape":"portrait"),this.isLock=!0,this.lockOr=e,this.config.nativeFirst&&screen.orientation&&document.fullscreenEnabled?(document.fullscreenElement||(this.__lock_need_exit=!0,this.requestFullscreen()),screen.orientation.lock("".concat(e,"-primary"))):"portrait"===e&&this.__setCss__(3)))}},{key:"unlock",value:function(){F()&&this.isLock&&(this.isLock=!1,this.config.nativeFirst&&screen.orientation&&document.fullscreenElement?(this.__lock_need_exit&&(this.exitFullScreen(),this.__lock_need_exit=!1),screen.orientation.unlock()):(this.is_full=!1,Q&&Q.classList.remove("__is_full__"),this.__need3__()?this.__setCss__(3):this.__setCss__(1)))}},{key:"requestFullscreen",value:function(){if(Q&&Q.classList.add("__is_full__"),this.is_full=!0,this.isNative)K(this.$el),this.config.forceRotate&&F()&&screen.orientation&&screen.orientation.lock("landscape-primary");else{if(this.__full__)return;this.$el.style.cssText=this.config.forceRotate&&window.innerHeight>window.innerWidth?z(Q):q,this.onUpdate&&this.onUpdate()}}},{key:"exitFullScreen",value:function(){Q&&Q.classList.remove("__is_full__"),this.is_full=!1,this.isLock=!1,this.isNative?(X(),this.__need3__()&&this.__setCss__(3)):this.__need3__()?this.__setCss__(3):this.__setCss__(1)}},{key:"__need3__",value:function(){return this.config.autoRotate&&F()&&window.innerHeight<window.innerWidth}},{key:"__setCss__",value:function(e){switch(e){case 1:this.$el.style.cssText=this.cssText,this.__full__=!1;break;case 2:this.$el.style.cssText=z(Q),this.__full__=!1;break;case 3:this.__full__=!0,this.$el.style.cssText=q;break;case 4:this.$el.style.cssText=Y();break}this.onUpdate&&this.onUpdate()}},{key:"onUpdate",value:function(){}},{key:"destroy",value:function(){this.$el.style.cssText=this.cssText,this.__destroy__(),this.__un_bind_touchmove__&&this.__un_bind_touchmove__()}}]),e}(),Z=$,J=(n("4ec9"),{Error:0,Warn:1,Log:2,Debug:3}),ee=J.Debug,te=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ee,n=arguments.length>1?arguments[1]:void 0;h(this,e),this.tag=n,this.setLevel(t)}return p(e,[{key:"setLevel",value:function(e){this.level=e}},{key:"_log",value:function(t,n){n=Array.prototype.slice.call(n),this.tag&&n.unshift("[".concat(this.tag,"]")),window.__SHOW_LOG__?console[e.level_map[t]].apply(console,n):this.level}},{key:"log",value:function(){this._log(J.Log,arguments)}},{key:"debug",value:function(){this._log(J.Debug,arguments)}},{key:"error",value:function(){this._log(J.Error,arguments)}},{key:"warn",value:function(){this._log(J.Warn,arguments)}}],[{key:"level_map",get:function(){var e;return e={},v(e,J.Debug,"log"),v(e,J.Log,"log"),v(e,J.Warn,"warn"),v(e,J.Error,"error"),e}}]),e}(),ne=new Map;function re(e){return ne.has(e)||ne.set(e,new te(ee,e)),ne.get(e)}var ie=te;n("b64b");function ae(e){if(e instanceof ae)return e;"number"===typeof e?this.code=e:"string"===typeof e&&(this.code=ae.errorTypes.COMMON_ERR_CUSTOM,this.message=e),this.message||(this.message=ae.defaultMessages[this.code]||"")}ae.prototype.code=0,ae.prototype.message="",ae.errorTypes={MEDIA_ERR_CUSTOM:1e3,MEDIA_ERR_ABORTED:1001,MEDIA_ERR_NETWORK:1002,MEDIA_ERR_DECODE:1003,MEDIA_ERR_SRC_NOT_SUPPORTED:1004,MEDIA_ERR_ENCRYPTED:1005,MEDIA_ERR_TRANSPORT:1006,MEDIA_ERR_CONNECT:1007,MEDIA_ERR_DECODER:1008,CLOUD_ERR_SERVER:1101,CLOUD_ERR_TOKEN:1102,CLOUD_ERR_DEVID:1104,CLOUD_ERR_BANDWIDTH:1105,CLOUD_ERR_PARAM:1106,CLOUD_ERR_DEV_RELAY:1107,CLOUD_ERR_STREAM:1108,CLOUD_ERR_VERSION:1109,CLOUD_ERR_STREAM_LIMIT:1110,CLOUD_ERR_FREE:1111,CLOUD_ERR_WINDOW_LIMIT:1112,CLOUD_ERR_CLIENT_LIMIT:1113,CLOUD_ERR_SHARE_FINISH:1114,CLOUD_ERR_PERMISSION:1115,CLOUD_ERR_ENCRYPT_CHANGED:1120,CLOUD_ERR_TALK_BUSY:1121,CLOUD_ERR_UNBIND:1122,AUDIO_ERR_AUDIO_ENABLE:1201,AUDIO_ERR_PERMISSION_DENIED:1202,AUDIO_ERR_NOT_SUPPORTED_ERROR:1203,AUDIO_ERR_MANDATORY_UNSATISFIED_ERROR:1204,AUDIO_ERR_NOT_FOUND_ERR:1205,AUDIO_ERR_AUDIO_NOSUPPORTED:1206,AUDIO_ERR_AUDIO_BUSY:1207,AUDIO_ERR_NOT_ALLOW:1208,DEVICE_ERR_CHN_OFFLINE:1301,DEVICE_ERR_CHN_INVALID:1302,DEVICE_ERR_PWD_CHANGED:1303,COMMON_ERR_CUSTOM:1401,COMMON_ERR_TIME_OUT:1402,COMMON_ERR_NETWORK:1403,COMMON_ERR_INTERNAL:1404,COMMON_ERR_SESSION:1405,LOCAL_ERR_CONFIG_PLAYBACK:1501,VIDEO_RES_WARNING:2001,NETWORK_UNSTABLE_WARNING:2002,DECODE_WARNING:2003},ae.defaultMessages={1001:"The fetching of the associated resource was aborted by the user's request.",1002:"Some kind of network error occurred which prevented the media from being successfully fetched, despite having previously been available.",1003:"Despite having previously been determined to be usable, an error occurred while trying to decode the media resource, resulting in an error.",1004:"The associated resource or media provider object (such as a MediaStream) has been found to be unsuitable.",1005:"The media is encrypted and we do not have the keys to decrypt it.",1006:"Transport error",1007:"Websocket connection to server failed",1008:"Unsupported decoder type",1101:"Some error occurred in cloud server",1102:"Token overdued or non-existent",1104:"Invalid device id",1105:"Bandwidth limitted",1106:"The parameter of request has error",1107:"Device cannot connect to relay server",1108:"Fail to get stream",1109:"Unsupported relay protocol version",1110:"The request of stream has limitted",1111:"Had watch for a long time",1112:"Too many vip windows",1113:"Too many vip clients",1114:"Share time has finished",1115:"Permission deny",1120:"The status of media encrypt has been changed",1121:"Device is on calling",1123:"Device has been unbind",1201:"Device does not support voice intercom",1202:"Permission denied error",1203:"Not supported error",1204:"Mandatory unsatisfied error",1205:"Requested device not found",1206:"Call mode not supported",1207:"The audio device is busy and cannot initiate a call",1208:"Permission denied by system",1301:"Device offline",1302:"Device invalid",1303:"The password of the device has been changed",1401:"Unknown error",1402:"Time out",1403:"Network error",1404:"Server internal error",1405:"Session overdued or non-existent",1501:"Config error",2001:"Resolution too high",2002:"Network unstable",2003:"Decode performance insufficient"},Object.keys(ae.errorTypes).forEach((function(e){ae[e]=ae.errorTypes[e],ae.prototype[e]=ae.errorTypes[e]}));var oe=ae,se="ORIGIN",ce="FISHEYE_CYLINDER",ue="FISHEYE_360D",le="FISHEYE_180D",fe="FISHEYE_LONGITUDE",he="FISHEYE_LATITUDE",de="FISHEYE_CALIB",pe="FISHEYE_WIN_PLANE_TOP_QUAD",ve="FISHEYE_WIN_PLANE_TOP",me="FISHEYE_WIN_PLANE_WALL",ye="YUV_FRAME",ge="VIDEO_FRAME",be=(Math.PI,1),Te=(Math.PI,Math.PI,Math.PI,.002),Se=[1,1,0,-1,1,0,1,-1,0,-1,-1,0],Ee=[1,0,0,0,1,1,0,1],_e=Math.PI/2,ke=1,we=-.9,Ae=[0,Math.PI/2,Math.PI,3*Math.PI/2],Re=.8,xe=.4,Ce=0,Ie=0,Pe=be,Oe=be,De=0,Ue=1;n("cb29");function Me(e){if(Array.isArray(e))return o(e)}function Be(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function Ne(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Le(e){return Me(e)||Be(e)||s(e)||Ne()}var Fe=["attribute highp vec4 aVertexPosition;","attribute vec2 aTextureCoord;","varying highp vec2 vTextureCoord;","void main(void) {","gl_Position = aVertexPosition;","vTextureCoord = aTextureCoord;","}"].join("\n"),je=["precision highp float;","varying lowp vec2 vTextureCoord;"].join("\n"),We=["uniform sampler2D YTexture;","uniform sampler2D UTexture;","uniform sampler2D VTexture;"].join("\n"),He="uniform sampler2D videoTexture;\n",Ve="uniform float fAngle;\n",qe=["uniform float fAngle;","uniform float unfoldPara;","uniform float heightOverWidthOfScreen;"].join("\n"),ze=["uniform float heightOverWidthOfVideo;","uniform float unfoldPara;","uniform int projMode;","uniform float coefficient;"].join("\n"),Ge=["uniform float heightOverWidthOfVideo;","uniform float unfoldPara;","uniform int projMode;","uniform float coefficient;"].join("\n"),Ye=["uniform float alpha;","uniform float beta;","uniform float sizeOverPointZ;","uniform float viewPointZ;","uniform float heightOverWidthOfScreen;","uniform float heightOverWidthOfVideo;","uniform int projMode;","uniform float coefficient;"].join("\n"),Ke=["uniform float hazermA;","uniform int hazermWidth;","uniform int hazermHeight;"].join("\n"),Xe=["vec2 cylinder(in vec2 tc, in float fAngle, in float unfoldPara, in float heightOverWidthOfScreen){","vec2 tcOut = vec2(-1.0, -1.0);","float fInclineAngle = 0.18 * (2.0 - unfoldPara);","float x1 = (tc.x - (1.0 - heightOverWidthOfScreen * unfoldPara * (0.6 * unfoldPara + 0.4)) / 2.0) / (heightOverWidthOfScreen * unfoldPara * (0.6 * unfoldPara + 0.4));","float y1 = 1.0 - tc.y;","float x2, y2;","float x3, y3;","if(y1 >= fInclineAngle + sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle && y1 <= (1.0- fInclineAngle) + sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle && ((x1>=0.0 && x1<=(1.0/unfoldPara-0.5)) || (x1 >=(1.5-1.0/unfoldPara) && x1<=1.0))){","x2 = x1;","y2 = (y1 - sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle - fInclineAngle) / (1.0 - 2.0 * fInclineAngle);","if(x2 < (1.0 / unfoldPara - 0.5)){","x3 = 0.0 - ((asin((x2 - (1.0 / unfoldPara - 0.5)) / (1.0 / unfoldPara - 0.5)) * 2.0 / 3.1415926) * (1.0 - 0.5 * unfoldPara) / 2.0);","y3 = y2;","}else{","x3 = 1.0 - (asin((x2 - (1.5 - 1.0 / unfoldPara)) / (1.0 / unfoldPara - 0.5)) * 2.0 / 3.1415926) * (1.0 - 0.5 * unfoldPara) / 2.0;","y3 = y2;","}","tcOut.x = (1.0 + (y3 * 0.8 + 0.2) * cos(x3 * 2.0 * 3.1415926 + fAngle)) / 2.0;","tcOut.y = (1.0 + (y3 * 0.8 + 0.2) * sin(x3 * 2.0 * 3.1415926 + fAngle)) / 2.0;","}","if(y1 >= fInclineAngle - sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle && y1 <= (1.0- fInclineAngle) - sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle && x1>=0.0 && x1<=1.0){","x2 = x1;","y2 = (y1 + sqrt(x1 - x1 * x1) * 2.0 * fInclineAngle - fInclineAngle) / (1.0 - 2.0 * fInclineAngle);","x3 = (asin((x2 - 0.5) / 0.5) * 2.0 / 3.1415926 * 0.25 * unfoldPara + 0.5) * (2.0 - unfoldPara) + x2 * (unfoldPara - 1.0);","y3 = y2;","tcOut.x = (1.0 + (y3 * 0.8 + 0.2) * cos(x3 * 2.0 * 3.1415926 + fAngle)) / 2.0;","tcOut.y = (1.0 + (y3 * 0.8 + 0.2) * sin(x3 * 2.0 * 3.1415926 + fAngle)) / 2.0;","}","return tcOut;","}"].join("\n"),Qe=["vec2 fishEye(in vec2 tc, in float fAngle){","vec2 tcOut;","tcOut.x = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * cos(tc.x * 2.0 * 3.1415926 + fAngle);","tcOut.y = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * sin(tc.x * 2.0 * 3.1415926 + fAngle);","return tcOut;","}"].join("\n"),$e=["vec2 fishEye(in vec2 tc, in float fAngle){","vec2 tcOut;","tcOut.x = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * cos(tc.x * 3.1415926 + fAngle);","tcOut.y = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * sin(tc.x * 3.1415926 + fAngle);","return tcOut;","}"].join("\n"),Ze=["vec2 fishEye(in vec2 tc, in float fAngle){","vec2 tcOut;","tcOut.x = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * cos((tc.x / 2.0 + 0.5) * 2.0 * 3.1415926 + fAngle);","tcOut.y = 0.5 + (1.0 - tc.y * 0.8) / 2.0 * sin((tc.x / 2.0 + 0.5) * 2.0 * 3.1415926 + fAngle);","return tcOut;","}"].join("\n"),Je=["vec2 longitude(in vec2 tc, in float heightOverWidthOfVideo, in float unfoldPara, in int projMode, in float coefficient){","vec2 tcOut;","float cutFactor;","if (heightOverWidthOfVideo > 0.75)","cutFactor = 0.5 - 0.5 * 9.0 / 16.0 / heightOverWidthOfVideo;","else","cutFactor = 0.05 / heightOverWidthOfVideo;","cutFactor = unfoldPara*cutFactor;","tc.y = (1.0-2.0*cutFactor)*tc.y+cutFactor;","tc.y = tc.y * heightOverWidthOfVideo + 0.5 - 0.5 * heightOverWidthOfVideo;","tcOut.x = 0.5 + (tc.x - 0.5) * sqrt(0.25 - (tc.y - 0.5)*(tc.y-0.5)*(1.0+(unfoldPara-1.0)*(unfoldPara-1.0)*(unfoldPara-1.0)))/0.5;","tcOut.y = tc.y;","tcOut.y = (tcOut.y - 0.5 + 0.5 * heightOverWidthOfVideo) / heightOverWidthOfVideo;","tcOut = winplane(tcOut, 0.0, 0.0, 2.0, 1.0, heightOverWidthOfVideo, heightOverWidthOfVideo, projMode, coefficient);","return tcOut;","}"].join("\n"),et=["vec2 latitude(in vec2 tc, in float heightOverWidthOfVideo, in float unfoldPara, in int projMode, in float coefficient){","vec2 tcOut;","float cutFactor;","if (heightOverWidthOfVideo < 1.33)","cutFactor = 0.5 - 0.5 * 9.0 / 16.0 * heightOverWidthOfVideo;","else","cutFactor = 0.05 * heightOverWidthOfVideo;","cutFactor = unfoldPara*cutFactor;","tc.x = (1.0-2.0*cutFactor)*tc.x+cutFactor;","tc.x = tc.x / heightOverWidthOfVideo + 0.5 - 0.5 / heightOverWidthOfVideo;","tcOut.y = 0.5 + (tc.y - 0.5) * sqrt(0.25 - (tc.x - 0.5)*(tc.x-0.5)*(1.0+(unfoldPara-1.0)*(unfoldPara-1.0)*(unfoldPara-1.0)))/0.5;","tcOut.x = tc.x;","tcOut.x = (tcOut.x - 0.5 + 0.5 / heightOverWidthOfVideo) * heightOverWidthOfVideo;","tcOut = winplane(tcOut, 0.0, 0.0, 2.0, 1.0, heightOverWidthOfVideo, heightOverWidthOfVideo, projMode, coefficient);","return tcOut;","}"].join("\n"),tt=["vec2 fishEye(in vec2 tc, in float fAngle){","vec2 tcOut;","float fFactorx = 1.2;","float fFactory = 1.2;","float fFocalx = 0.331095;","float fCenterx = 0.538893;","float fFocaly = 0.331699;","float fCentery = 0.476102;","float fK1 = -0.00712683;","float fK2 = -0.00954012;","float fK3 = 0.00416203;","float fK4 = -0.00246566;","float fCamx = (tc.x - fCenterx) / fFocalx;","float fCamy = (tc.y - fCentery) / fFocaly;","if(fCamx * fCamx + fCamy * fCamy < 0.0001){","tcOut.x = fFactorx * (tc.x - fCenterx) + fCenterx;","tcOut.y = fFactory * (tc.y - fCentery) + fCentery;","return tcOut;","}","float fTheta = atan(sqrt(fCamx * fCamx + fCamy * fCamy));","float fThetad = fTheta + fK1 * fTheta * fTheta * fTheta;","fThetad += fK2 * fTheta * fTheta * fTheta * fTheta * fTheta;","fThetad += fK3 * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta;","fThetad += fK4 * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta * fTheta;","float fCameraX = fThetad * fCamx / sqrt(fCamx * fCamx + fCamy * fCamy);","float fCameraY = fThetad * fCamy / sqrt(fCamx * fCamx + fCamy * fCamy);","tcOut.x = fCameraX * fFocalx * fFactorx + fCenterx;","tcOut.y = fCameraY * fFocaly * fFactory + fCentery;","return tcOut;","}"].join("\n"),nt=["vec2 winplane(in vec2 tc, in float alpha, in float beta, in float sizeOverPointZ,in float viewPointZ,in float heightOverWidthOfScreen, in float heightOverWidthOfVideo, in int projMode, in float coefficient) {","vec2 tcOut = vec2(-1.0, -1.0);","int boxingMode = 0;","int baseOnHeight = 1;","if (boxingMode == 0){","if (heightOverWidthOfScreen > heightOverWidthOfVideo)","baseOnHeight = 0;","}","else if (boxingMode == 2) {","baseOnHeight = 0;","}","float x1, y1;","if (baseOnHeight == 1) {","x1=(tc.x-0.5)*sizeOverPointZ*heightOverWidthOfVideo/heightOverWidthOfScreen;","y1=(tc.y-0.5)*sizeOverPointZ*heightOverWidthOfVideo;","}","else {","x1=(tc.x-0.5)*sizeOverPointZ;","y1=(tc.y-0.5)*sizeOverPointZ*heightOverWidthOfScreen;","}","float a,b,c,delta,t,fTmp;","a=x1*x1+y1*y1+1.0;","c=1.0-1.0/(viewPointZ*viewPointZ);","delta = 1.0 - a * c;","if(delta >= 0.0){","float x2,y2,z2;","t= (1.0 + sqrt(delta)) / a;","x2 = t * x1;","y2 = t * y1;","z2 = (1.0 - t);","float x3,y3,z3,x4,y4,z4;","x3 = x2;","y3 = y2 * cos(alpha) - z2 * sin(alpha);","z3 = y2 * sin(alpha) + z2 * cos(alpha);","x4 = x3 * cos(beta) - y3 * sin(beta);","y4 = x3 * sin(beta) + y3 * cos(beta);","z4 = z3;","if(z4<0.0){","float s,t,fSinThita,fThita,x5,y5;","s=x4*x4+y4*y4;","fSinThita=sqrt(s);","fThita=asin(fSinThita*viewPointZ);","x5 = x4 / fSinThita;","y5 = y4 / fSinThita;","if (projMode == 0) ","t = 0.63662 * fThita;","else if (projMode == 1)","t = sin(fThita);","else if (projMode == 2)","t = sqrt(2.0) * sin(fThita / 2.0);","else if (projMode == 3)","t = tan(fThita / 2.0);","else if (projMode == 4)","t = 0.63662 * fThita * coefficient + tan(fThita / 2.0) * (1.0 - coefficient);","else if (projMode == 5)","t = 0.63662 * fThita * coefficient + sin(fThita) * (1.0 - coefficient);","else ","t = 0.63662 * fThita;","x5 = t*x5;","y5 = t*y5;","tcOut.x=(x5+1.0)/2.0;","tcOut.y=(y5+1.0)/2.0;","if(tcOut.y < 0.5 - 0.5 * heightOverWidthOfVideo || tcOut.y > 0.5 + 0.5 * heightOverWidthOfVideo)","{","tcOut.x = -1.0;","tcOut.y = -1.0;","}","else","{","tcOut.y = (tcOut.y - 0.5 + 0.5 * heightOverWidthOfVideo) / (heightOverWidthOfVideo);","}","}","}","return tcOut;","}"].join("\n"),rt=["vec2 winplane(in vec2 tc, in float alpha, in float beta, in float sizeOverPointZ,in float viewPointZ,in float heightOverWidthOfScreen, in float heightOverWidthOfVideo, in int projMode, in float coefficient) {","vec2 tcOut = vec2(-1.0, -1.0);","int boxingMode = 0;","int baseOnHeight = 1;","if (boxingMode == 0){","if (heightOverWidthOfScreen > heightOverWidthOfVideo)","baseOnHeight = 0;","}","else if (boxingMode == 2) {","baseOnHeight = 0;","}","float x1, y1;","if (baseOnHeight == 1) {","x1=(tc.x-0.5)*sizeOverPointZ*heightOverWidthOfVideo/heightOverWidthOfScreen;","y1=(tc.y-0.5)*sizeOverPointZ*heightOverWidthOfVideo;","}","else {","x1=(tc.x-0.5)*sizeOverPointZ;","y1=(tc.y-0.5)*sizeOverPointZ*heightOverWidthOfScreen;","}","float a,b,c,delta,t,fTmp;","a=x1*x1+y1*y1+1.0;","c=1.0-1.0/(viewPointZ*viewPointZ);","delta = 1.0 - a * c;","if(delta >= 0.0){","float x2,y2,z2;","t= (1.0 + sqrt(delta)) / a;","x2 = t * x1;","y2 = t * y1;","z2 = (1.0 - t);","float x3,y3,z3,x4,y4,z4;","x3 = x2;","y3 = y2 * cos(alpha) - z2 * sin(alpha);","z3 = y2 * sin(alpha) + z2 * cos(alpha);","x4 = x3 * cos(beta) - z3 * sin(beta);","y4 = y3;","z4 = x3 * sin(beta) + z3 * cos(beta);","if(z4<0.0){","float s,t,fSinThita,fThita,x5,y5;","s=x4*x4+y4*y4;","fSinThita=sqrt(s);","fThita=asin(fSinThita*viewPointZ);","x5 = x4 / fSinThita;","y5 = y4 / fSinThita;","if (projMode == 0) ","t = 0.63662 * fThita;","else if (projMode == 1)","t = sin(fThita);","else if (projMode == 2)","t = sqrt(2.0) * sin(fThita / 2.0);","else if (projMode == 3)","t = tan(fThita / 2.0);","else if (projMode == 4)","t = 0.63662 * fThita * coefficient + tan(fThita / 2.0) * (1.0 - coefficient);","else if (projMode == 5)","t = 0.63662 * fThita * coefficient + sin(fThita) * (1.0 - coefficient);","else ","t = 0.63662 * fThita;","x5 = t*x5;","y5 = t*y5;","tcOut.x=(x5+1.0)/2.0;","tcOut.y=(y5+1.0)/2.0;","if(tcOut.y < 0.5 - 0.5 * heightOverWidthOfVideo || tcOut.y > 0.5 + 0.5 * heightOverWidthOfVideo)","{","tcOut.x = -1.0;","tcOut.y = -1.0;","}","else","{","tcOut.y = (tcOut.y - 0.5 + 0.5 * heightOverWidthOfVideo) / (heightOverWidthOfVideo);","}","}","}","return tcOut;","}"].join("\n"),it=["const mat4 YUV2RGB = mat4","("," 1.1643828125, 0, 1.59602734375, -.87078515625,"," 1.1643828125, -.39176171875, -.81296875, .52959375,"," 1.1643828125, 2.017234375, 0, -1.081390625,"," 0, 0, 0, 1",");"].join("\n"),at=["void main() {","vec2 tc = vTextureCoord;"].join("\n"),ot="tc.y = 1.0 - tc.y;\n",st="tc.x = 1.0 - tc.x;\n",ct="tc = dewrap(tc);\n",ut="tc = fishEye(tc, fAngle);\n",lt="tc = cylinder(tc, fAngle, unfoldPara + 1.0, heightOverWidthOfScreen);\n",ft="tc = longitude(tc, heightOverWidthOfVideo, unfoldPara, projMode, coefficient);\n",ht="tc = latitude(tc, heightOverWidthOfVideo, unfoldPara, projMode, coefficient);\n",dt="tc = winplane(tc, alpha, beta, sizeOverPointZ, viewPointZ, heightOverWidthOfScreen, heightOverWidthOfVideo, projMode, coefficient);\n",pt=["vec3 yuv;","yuv.x = texture2D(YTexture, tc).x;","yuv.y = texture2D(UTexture, tc).x;","yuv.z = texture2D(VTexture, tc).x;"].join("\n"),vt=["vec2 tc1;","float stepW = 1.0 / float(hazermWidth);","float stepH = 1.0 / float(hazermHeight);","int x,y;","float tx;","float tMin = 0.15;","float sqr_tMin_minus_half = (tMin - 0.5) * (tMin - 0.5);","int winSize= 5;","float sumY = 0.0;","float scaleConMax = 2.0;","float scaleSatMax = 3.0;","float scaleCon;","float scaleSat;","if (hazermA > 0.0) {","tx = ((0.5 - tMin) * 9.0 * pow(yuv.x - hazermA, 2.0) / (hazermA * hazermA) + tMin);","tx = min(1.0, tx);","tx *= pow(abs(yuv.y) + abs(yuv.z), 2.0) / 0.03125 + 0.5;","tx = clamp(tx, tMin, 1.0);","for (y = -winSize / 2; y <= winSize / 2; y++) {","for (x = -winSize / 2; x <= winSize / 2; x++) {","tc1 = tc + vec2(float(x) * stepW, float(y) * stepH);","sumY += texture2D(YTexture, tc1).x;","}}","scaleCon = scaleConMax * (1.0 - pow(tx - 0.5, 2.0) / sqr_tMin_minus_half);","scaleCon = max(0.0, scaleCon);","yuv.x = yuv.x + (yuv.x - sumY / float(winSize * winSize)) * scaleCon;","yuv.x = clamp(yuv.x, 0.0, 1.0);","scaleSat = scaleSatMax + (1.0 - scaleSatMax) * pow(tx - 0.5, 2.0) / sqr_tMin_minus_half;","scaleSat = max(1.0, scaleSat);","yuv.y *= scaleSat;","yuv.z *= scaleSat;","yuv.y = clamp(yuv.y, -0.5, 0.5);","yuv.z = clamp(yuv.z, -0.5, 0.5);","}"].join("\n"),mt="gl_FragColor = vec4(yuv, 1) * YUV2RGB;\n",yt="gl_FragColor = texture2D(videoTexture, tc);\n",gt=function(e){return["mediump vec2 dewarp(in vec2 tc){","mediump vec4 k = vec4(".concat(e.fK1,",").concat(e.fK2,",").concat(e.fK3,",").concat(e.fK4,");"),"mediump vec2 center1 = vec2(".concat(e.fCenter1x,",").concat(e.fCenter1y,");"),"mediump vec2 focal1 = vec2(".concat(e.fFocal1x,",").concat(e.fFocal1y,");"),"mediump vec2 center2 = vec2(".concat(e.fCenter2x,",").concat(e.fCenter2y,");"),"mediump vec2 focal2 = vec2(".concat(e.fFocal2x,",").concat(e.fFocal2y,");"),"mediump vec2 tc1 = (tc - center2) / focal2;","float r = sqrt(dot(tc1, tc1));","float theta = atan(r);","float theta2 = theta * theta;","float theta4 = theta2 * theta2;","float theta6 = theta4 * theta2;","float theta8 = theta4 * theta4;","float theta_d = theta * (1.0 + k.x * theta2 + k.y * theta4 + k.z * theta6 + k.w * theta8);","float scale = 1.0;","if (r > 0.0001) scale = theta_d / r;","mediump vec2 tc2 = scale * focal1 * tc1 + center1;","return tc2;","}"].join("\n")},bt="}",Tt=function(){function e(t,n){h(this,e),this.gl=t,this.options=n,this.programHandle=null,this.vertexPositionHandle=-1,this.textureCoordsHandle=-1,this.vertextAttribNeedUpdate=0,this.heightOverWidthOfScreenHandle=null,this.heightOverWidthOfScreenNeedUpdate=0,this.fAngleHandle=null,this.fishEyeAngleNeedUpdate=0,this.unfoldParaHandle=null,this.unfoldParaNeedUpdate=0,this.heightOverWidthOfVideoHandle=null,this.fishEyeHeightOverWidthOfVideoNeedUpdate=0,this.winPlaneAlphaHandle=null,this.winPlaneBetaHandle=null,this.winPlaneSizeOverPointZHandle=null,this.winPlaneViewPointZHandle=null,this.winPlaneProjModeHandle=null,this.winPlaneCoefficientHandle=null,this.fishEyeWinPlaneParamsNeedUpdate=0}return p(e,[{key:"initProgram",value:function(){this.vertextAttribNeedUpdate=1,this.heightOverWidthOfScreenNeedUpdate=1,this.fishEyeAngleNeedUpdate=1,this.unfoldParaNeedUpdate=1,this.fishEyeHeightOverWidthOfVideoNeedUpdate=1,this.fishEyeWinPlaneParamsNeedUpdate=1;var e=this.options.programIndex,t=void 0===e?0:e,n=this.getVertexShaderSource(),r=this.getFragmentShaderSource(t);this.programHandle=this.createProgram(n,r),this.getBaseHandles()}},{key:"getVertexShaderSource",value:function(){return Fe}},{key:"getFragmentShaderSource",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=this.options,n=Le(new Array(15).fill("")),r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],c=n[5],u=n[6],l=n[7],f=n[8],h=n[9],d=n[10],p=n[11],v=n[12],m=n[13],y=n[14];switch(t.verticalMirror&&(i=ot),t.horizontalMirror&&(a=st),t.dewarp&&(o=gt(t.dewarpParameter),s=ct),t.displayMode){case ce:f=Xe,u=qe,h=lt;break;case ue:f=Qe;break;case le:f=0==e?$e:Ze;break;case fe:case he:l=rt,t.displayMode==fe?(f=Je,u=ze,h=ft):(f=et,d=Ge,h=ht);break;case de:f=tt;break;case pe:case ve:f=nt,u=Ye,h=dt;break;case me:f=rt,u=Ye,h=dt;break;case se:default:break}""!==f&&(u=u||Ve,h=h||ut),t.hazerm&&(d=Ke,p=vt),t.frameType===ye?(r=We,v=it,m=pt,y=mt):(r=He,y=yt);var g=[je,r,u,d,o,c,l,f,v,at,i,a,s,h,m,p,y,bt].filter((function(e){return!!e})).join("\n");return g}},{key:"createProgram",value:function(e,t){var n=this.gl,r=n.createProgram(),i=this.loadShader(n.VERTEX_SHADER,e),a=this.loadShader(n.FRAGMENT_SHADER,t);return n.attachShader(r,i),n.attachShader(r,a),n.linkProgram(r),n.useProgram(r),r}},{key:"loadShader",value:function(e,t){var n=this.gl,r=n.createShader(e);return n.shaderSource(r,t),n.compileShader(r),n.getShaderParameter(r,n.COMPILE_STATUS)?r:(console.log("An error occurred compiling the shaders: "+n.getShaderInfoLog(r)),n.deleteShader(r),null)}},{key:"getBaseHandles",value:function(){var e=this.gl,t=this.programHandle;this.vertexPositionHandle=e.getAttribLocation(t,"aVertexPosition"),this.textureCoordsHandle=e.getAttribLocation(t,"aTextureCoord"),this.heightOverWidthOfScreenHandle=e.getUniformLocation(t,"heightOverWidthOfScreen"),this.heightOverWidthOfVideoHandle=e.getUniformLocation(t,"heightOverWidthOfVideo"),this.fAngleHandle=e.getUniformLocation(t,"fAngle"),this.unfoldParaHandle=e.getUniformLocation(t,"unfoldPara"),this.winPlaneAlphaHandle=e.getUniformLocation(t,"alpha"),this.winPlaneBetaHandle=e.getUniformLocation(t,"beta"),this.winPlaneSizeOverPointZHandle=e.getUniformLocation(t,"sizeOverPointZ"),this.winPlaneViewPointZHandle=e.getUniformLocation(t,"viewPointZ"),this.winPlaneProjModeHandle=e.getUniformLocation(t,"projMode"),this.winPlaneCoefficientHandle=e.getUniformLocation(t,"coefficient")}},{key:"setVertexAttribData",value:function(e,t,n){var r=this.gl,i=r.createBuffer();return r.bindBuffer(r.ARRAY_BUFFER,i),r.bufferData(r.ARRAY_BUFFER,new Float32Array(t),r.STATIC_DRAW),r.vertexAttribPointer(e,n,r.FLOAT,!1,0,0),r.enableVertexAttribArray(e),i}},{key:"deleteProgram",value:function(){this.programHandle&&(this.gl.deleteProgram(this.programHandle),this.programHandle=void 0)}}]),e}(),St={vertexPosition:Se,textureCoord:Ee,fAngle:_e,fUnfoldPara:ke,fWinPlaneAlpha:Ce,fWinPlaneBeta:Ie,fWinPlaneSizeOverPointZ:Pe,fWinPlaneViewPointZ:Oe,fWinPlaneProjMode:De,fWinPlaneCoefficient:Ue},Et=function(){function e(t){h(this,e),this.gl=t,this.texture=t.createTexture(),t.bindTexture(t.TEXTURE_2D,this.texture),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE)}return p(e,[{key:"bind",value:function(e,t,n){var r=this.gl;r.activeTexture([r.TEXTURE0,r.TEXTURE1,r.TEXTURE2][e]),r.bindTexture(r.TEXTURE_2D,this.texture),r.uniform1i(r.getUniformLocation(t,n),e)}},{key:"fill",value:function(e,t,n,r){var i=this.gl;i.bindTexture(i.TEXTURE_2D,this.texture),r===ge?i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,n):i.texImage2D(i.TEXTURE_2D,0,i.LUMINANCE,e,t,0,i.LUMINANCE,i.UNSIGNED_BYTE,n)}},{key:"delete",value:function(){this.gl.deleteTexture(this.texture)}}]),e}(),_t=function(){function e(t,n){h(this,e),this.canvas=t,this.gl=t.getContext("webgl",{preserveDrawingBuffer:n.preserveDrawingBuffer}),this.programNum=1,this.glPrograms=[],this.zoomBeans=[],this.fDisplayRatio=1,this.fVerticalOffset=0,this.fScreenRatio=1,this.fVideoRatio=1,this.frameType=ye,this.initGL(n)}return p(e,[{key:"initGL",value:function(e){if(this.gl){switch(this.frameType=e.frameType||this.frameType,e.displayMode){case le:this.programNum=2;break;case pe:this.programNum=4;break;default:this.programNum=1;break}var t=this.gl;t.pixelStorei(t.UNPACK_ALIGNMENT,1);for(var n=0;n<this.programNum;n++){var r=new Tt(t,{displayMode:e.displayMode||"ORIGIN",programIndex:n,frameType:this.frameType}),i=Object.assign({},St);switch(e.displayMode){case le:i.vertexPosition=this.getFishEye180DDefaultParams(n);break;case pe:i.vertexPosition=this.getWinPlaneQuadRecDefaultParams(n),i.fWinPlaneAlpha=we,i.fWinPlaneBeta=Ae[n],i.fWinPlaneSizeOverPointZ=Re,i.fWinPlaneViewPointZ=xe;break}r.initProgram(),this.frameType===ye?(r.y=new Et(t),r.u=new Et(t),r.v=new Et(t),r.y.bind(0,r.programHandle,"YTexture"),r.u.bind(1,r.programHandle,"UTexture"),r.v.bind(2,r.programHandle,"VTexture")):(r.t=new Et(t),r.t.bind(0,r.programHandle,"videoTexture")),this.glPrograms[n]=r,this.zoomBeans[n]=i}}else console.log("[ER] WebGL not supported.")}},{key:"getFishEye180DDefaultParams",value:function(e){var t=[-1,-1],n=[0+Te/2,-1],r=2,i=(2-Te)/2;return[t[e]+r,n[e]+i,0,t[e],n[e]+i,0,t[e]+r,n[e],0,t[e],n[e],0]}},{key:"getWinPlaneQuadRecDefaultParams",value:function(e){var t=Te,n=Te*this.fScreenRatio,r=0,i=0,a=(2-t)/2,o=(2-n)/2;switch(e){case 0:r=-1,i=0+t/2;break;case 1:r=0+t/2,i=0+n/2;break;case 2:r=-1,i=-1;break;case 3:r=0+n/2,i=-1;break}return[r+a,i+o,0,r,i+o,0,r+a,i,0,r,i,0]}},{key:"renderFrame",value:function(e,t,n,r,i){var a=this;if(this.gl){var o=this.gl,s=this.glPrograms,c=this.zoomBeans;o.viewport(0,0,t,n),o.clearColor(0,0,0,0),o.clear(o.COLOR_BUFFER_BIT),s.forEach((function(u,l){var f=c[l];o.useProgram(u.programHandle),u.vertextAttribNeedUpdate?(u.vBuffer=u.setVertexAttribData(u.vertexPositionHandle,f.vertexPosition,3),u.fBuffer=u.setVertexAttribData(u.textureCoordsHandle,f.textureCoord,2),u.vertextAttribNeedUpdate=0):s.length>1&&(o.bindBuffer(o.ARRAY_BUFFER,u.vBuffer),o.vertexAttribPointer(u.vertexPositionHandle,3,o.FLOAT,!1,0,0),o.enableVertexAttribArray(u.vertexPositionHandle),o.bindBuffer(o.ARRAY_BUFFER,u.fBuffer),o.vertexAttribPointer(u.textureCoordsHandle,2,o.FLOAT,!1,0,0),o.enableVertexAttribArray(u.textureCoordsHandle)),u.heightOverWidthOfScreenNeedUpdate&&null!==u.heightOverWidthOfScreenHandle&&(o.uniform1f(u.heightOverWidthOfScreenHandle,a.fScreenRatio),u.heightOverWidthOfScreenNeedUpdate=0),u.fishEyeHeightOverWidthOfVideoNeedUpdate&&null!==u.heightOverWidthOfVideoHandle&&(o.uniform1f(u.heightOverWidthOfVideoHandle,a.fVideoRatio),u.fishEyeHeightOverWidthOfVideoNeedUpdate=0),u.fishEyeAngleNeedUpdate&&null!==u.fAngleHandle&&(o.uniform1f(u.fAngleHandle,f.fAngle),u.fishEyeAngleNeedUpdate=0),u.unfoldParaNeedUpdate&&null!==u.unfoldParaHandle&&(o.uniform1f(u.unfoldParaHandle,f.fUnfoldPara),u.unfoldParaNeedUpdate=0),u.fishEyeWinPlaneParamsNeedUpdate&&(null!==u.winPlaneAlphaHandle&&o.uniform1f(u.winPlaneAlphaHandle,f.fWinPlaneAlpha),null!==u.winPlaneBetaHandle&&o.uniform1f(u.winPlaneBetaHandle,f.fWinPlaneBeta),null!==u.winPlaneSizeOverPointZHandle&&o.uniform1f(u.winPlaneSizeOverPointZHandle,f.fWinPlaneSizeOverPointZ),null!==u.winPlaneViewPointZHandle&&o.uniform1f(u.winPlaneViewPointZHandle,f.fWinPlaneViewPointZ),null!==u.winPlaneProjModeHandle&&o.uniform1f(u.winPlaneProjModeHandle,f.fWinPlaneProjMode),null!==u.winPlaneCoefficientHandle&&o.uniform1f(u.winPlaneCoefficientHandle,f.fWinPlaneCoefficient),u.fishEyeWinPlaneParamsNeedUpdate=0),a.frameType===ye?(u.y.fill(t,n,e.subarray(0,r)),u.u.fill(t>>1,n>>1,e.subarray(r,r+i)),u.v.fill(t>>1,n>>1,e.subarray(r+i,e.length))):u.t.fill(t,n,e,ge),o.drawArrays(o.TRIANGLE_STRIP,0,4)})),e.close&&e.close()}else console.log("[ER] Render frame failed due to WebGL not supported.")}},{key:"deleteProgram",value:function(){this.glPrograms.forEach((function(e){e.deleteProgram()})),this.glPrograms=[],this.zoomBeans=[]}},{key:"setDisplayInfo",value:function(e){this.dispose(),this.initGL(e)}},{key:"dispose",value:function(){var e=this.gl,t=this.glPrograms,n=this.frameType;t.forEach((function(t){n===ye?(t.y.delete(),t.u.delete(),t.v.delete()):t.t.delete(),e.deleteBuffer(t.vBuffer),e.deleteBuffer(t.fBuffer),t.deleteProgram()})),e.clear(e.COLOR_BUFFER_BIT),this.glPrograms=[],this.zoomBeans=[]}}]),e}(),kt=_t,wt=(n("2b3d"),n("9861"),n("a002")),At=n.n(wt),Rt=function(){return(65536*(1+Math.random())|0).toString(16).substring(1)},xt=function(e){for(var t="",n=0;n<parseInt(e/4);n++)t+=Rt();return t+=Rt().slice(0,e%4),t},Ct="__TUMS_PLAYER_STORAGE__",It={getItem:function(e){return window[Ct]?window[Ct][e]:null},setItem:function(e,t){window[Ct]||(window[Ct]={}),window[Ct][e]=t}},Pt=function(){return navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)},Ot=function(e){return null===e||void 0===e||""===e},Dt=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=0;n<e.length-t.length+1;n++){for(var r=!0,i=0;i<t.length;i++)if(e[n+i]!==t[i]){r=!1;break}if(r)return[e.slice(0,n),e.slice(n+t.length,e.length)]}return!1},Ut=(re("load worker"),["decoder.worker.js","libaudio.js","libs.worker.js","libffmpeg.js","webgl.js","webgl.worker.js"]),Mt=["audio.wasm","libaudio.wasm","libffmpeg.wasm"];function Bt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"blob";return fetch(e).then((function(r){if(!r["ok"])throw"failed to load wasm binary file at '"+e+"'";return At.a.setItem(t,r[n]())}))}function Nt(e){return Lt.apply(this,arguments)}function Lt(){return Lt=l(regeneratorRuntime.mark((function e(t){var n,r,i,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=localStorage.getItem("__TUMS_PLAYER_VERSION__"),e.next=3,At.a.getItem("__TUMS_PLAYER_VERSION_IDB__");case 3:if(r=e.sent,n!==r){e.next=6;break}return e.abrupt("return",Promise.resolve());case 6:return i=Ut.map((function(e){return Bt(t+"/tums-player/"+e,e)})),a=Mt.map((function(e){return Bt(t+"/tums-player/"+e,e,"arrayBuffer")})),e.abrupt("return",Promise.all([].concat(Le(i),Le(a))).then((function(){At.a.setItem("__TUMS_PLAYER_VERSION_IDB__",n)})));case 9:case"end":return e.stop()}}),e)}))),Lt.apply(this,arguments)}function Ft(){return jt.apply(this,arguments)}function jt(){return jt=l(regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=It.getItem("libs.worker.js"),!t){e.next=5;break}n=It.getItem("libaudio.js"),e.next=17;break;case 5:return e.t0=URL,e.next=8,At.a.getItem("libs.worker.js");case 8:return e.t1=e.sent,t=e.t0.createObjectURL.call(e.t0,e.t1),e.t2=URL,e.next=13,At.a.getItem("libaudio.js");case 13:e.t3=e.sent,n=e.t2.createObjectURL.call(e.t2,e.t3),It.setItem("libs.worker.js",t),It.setItem("libaudio.js",n);case 17:return e.next=19,At.a.getItem("libaudio.wasm");case 19:return r=e.sent,e.abrupt("return",{libsWorker:t,libaudio:n,libaudioWasm:r});case 21:case"end":return e.stop()}}),e)}))),jt.apply(this,arguments)}function Wt(){return Ht.apply(this,arguments)}function Ht(){return Ht=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=a.length>0&&void 0!==a[0]?a[0]:"wasm",n=It.getItem("decoder.worker.js"),n){e.next=9;break}return e.t0=URL,e.next=6,At.a.getItem("decoder.worker.js");case 6:e.t1=e.sent,n=e.t0.createObjectURL.call(e.t0,e.t1),It.setItem("decoder.worker.js",n);case 9:if("wasm"!==t){e.next=21;break}if(r=It.getItem("libffmpeg.js"),r){e.next=18;break}return e.t2=URL,e.next=15,At.a.getItem("libffmpeg.js");case 15:e.t3=e.sent,r=e.t2.createObjectURL.call(e.t2,e.t3),It.setItem("libffmpeg.js",r);case 18:return e.next=20,At.a.getItem("libffmpeg.wasm");case 20:i=e.sent;case 21:return e.abrupt("return",{decoderWorker:n,libffmpeg:r,libffmpegWasm:i});case 22:case"end":return e.stop()}}),e)}))),Ht.apply(this,arguments)}function Vt(){return qt.apply(this,arguments)}function qt(){return qt=l(regeneratorRuntime.mark((function e(){var t,n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=It.getItem("webgl.worker.js"),!t){e.next=5;break}n=It.getItem("webgl.js"),e.next=17;break;case 5:return e.t0=URL,e.next=8,At.a.getItem("webgl.worker.js");case 8:return e.t1=e.sent,t=e.t0.createObjectURL.call(e.t0,e.t1),e.t2=URL,e.next=13,At.a.getItem("webgl.js");case 13:e.t3=e.sent,n=e.t2.createObjectURL.call(e.t2,e.t3),It.setItem("webgl.worker.js",t),It.setItem("webgl.js",n);case 17:return e.abrupt("return",{webglWorker:t,webgljs:n});case 18:case"end":return e.stop()}}),e)}))),qt.apply(this,arguments)}var zt=n("5585");function Gt(e,t){var n=document.createElement("a");n.style.display="none";var r=e,i=window.URL.createObjectURL(r);n.href=i,n.download=t,document.body.appendChild(n),n.click(),n.remove(),window.URL.revokeObjectURL(i)}var Yt=[];function Kt(){if(Yt.length)return Yt;var e=["webm"],t=["vp8","vp8.0","vp9","vp9.0"];return e.forEach((function(e){var n="video/".concat(e);t.forEach((function(e){var t=["".concat(n,";codecs=").concat(e),"".concat(n,";codecs:").concat(e),"".concat(n)];t.forEach((function(e){MediaRecorder.isTypeSupported(e)&&Yt.push(e)}))}))})),Yt}var Xt="video/webm",Qt=6e5,$t=10;function Zt(e){return new Promise((function(t,n){var r=new FileReader;r.readAsArrayBuffer(e),r.onloadend=function(){t(r.result)},r.onerror=function(){n(r.error)}}))}var Jt=function(){function e(t,n,r){var i=this;h(this,e);var a=Kt(),o=a[0]||Xt;this.client=r,this.recordChunks=new Blob([],{type:o}),this.lastRecordSize=null,this.tolerance=$t,this.listener=null,this.recordStartTime=0,this.stopTime=0,this.tasks=Promise.resolve(),this.decoder=new zt["Decoder"],this.reader=new zt["Reader"];var s=new MediaStream([].concat(Le(t.getTracks()),Le(n.getTracks())));this.recorder=new MediaRecorder(s,{mimeType:o}),this.recorder.ondataavailable=function(e){var t=e.data;i.recordChunks=new Blob([i.recordChunks,t],{type:t.type});var n=function(){var e=l(regeneratorRuntime.mark((function e(){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Zt(t);case 2:n=e.sent,r=i.decoder.decode(n),r.forEach((function(e){i.reader.read(e)}));case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();i.tasks=i.tasks.then((function(){return n()})),Date.now()-i.recordStartTime-i.stopTime>Qt&&i.stopAndblobDownload()}}return p(e,[{key:"startRecord",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;"recording"!==this.recorder.state&&(this.recorder.start(t),this.recordStartTime=Date.now(),this.listener=setInterval((function(){return e.listenRecord()}),500))}},{key:"stopRecord",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.tasks;case 2:this.recorder.stop(),this.reader.stop(),clearInterval(this.timer),this.tolerance=$t;case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"resumeRecord",value:function(){this.recorder&&"paused"===this.recorder.state&&(this.recorder.resume(),clearInterval(this.stopTimer))}},{key:"pauseRecord",value:function(){var e=this;this.recorder&&"paused"!==this.recorder.state&&(this.recorder.pause(),this.stopTimer=setInterval((function(){e.stopTime+=500}),500))}},{key:"getState",value:function(){return this.recorder.state}},{key:"listenRecord",value:function(){this.recorder&&"inactive"!==this.recorder.state&&(this.recordChunks.size===this.lastRecordSize&&(this.tolerance>=0?this.stopAndblobDownload():this.tolerance--),this.lastRecordSize=this.recordChunks.size)}},{key:"getRecordInfo",value:function(){return this.recorder&&"inactive"!==this.recorder.state?{size:Math.floor(this.recordChunks.size/1e3),time:Date.now()-this.recordStartTime-this.stopTime}:{size:0,time:0}}},{key:"stopAndblobDownload",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a,o,s,c,u,l=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=l.length>0&&void 0!==l[0]?l[0]:"record",n=!(l.length>1&&void 0!==l[1])||l[1],this.recorder&&"inactive"!==this.recorder.state){e.next=4;break}return e.abrupt("return");case 4:return e.next=6,this.stopRecord();case 6:return r=this.reader,i=this.recordChunks,a=Date.now(),o=zt["tools"].makeMetadataSeekable(r.metadatas,Date.now()-this.recordStartTime-this.stopTime,r.cues),e.next=11,Zt(i);case 11:return s=e.sent,c=s.slice(r.metadataSize),u=new Blob([o,c],{type:i.type}),n&&Gt(u,"".concat(t,"_").concat(a,".webm")),this.recordChunks=new Blob([]),this.client.eventSource.dispatchEvent("videoRecordFinished"),e.abrupt("return",u);case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}]),e}(),en=re("webglPlayer"),tn=.25,nn=1,rn=5,an=100,on=2304,sn=1296,cn={0:C,1:I},un=function(){function e(t,n,r){h(this,e),this.options=t,this.wrapper=n,this.canvasId="canvas_"+(new Date).getTime(),this.codeType=t.codeType,this.audioType=t.audioType,this.audioDecoderType="_decodeG711a",this.decoderType=t.decoderType,this.sampleRate=t.sampleRate,this.pluginPath=t.pluginPath,this.streamType=t.streamType,this.isCover=t.cover,this.playScale=t.playScale||1,this.startTime=t.startTime,this.videoTimestamp=t.startTime,this.fishEyeDisplayMode=t.fishEyeDisplayMode,this.videoWidth=1920,this.videoHeight=1080,this.videoCodec="",this.webgl=null,this.webglWorker=null,this.audioPlayer=null,this.audioVoiceEnable=t.audioVoiceEnable||!1,this.decoderWorker=null,this.noisedecoderWorker=null,this.isInit=!0,this.hasDecoderInit=!1,this.hasNoiseDecoderInit=!1,this.zoomState=0,this.zoomScale=1,this.zoomTranslate={x:0,y:0},this.videoQueue=[],this.audioQueue=[],this.initCb=r,this.lastVideoData=null,this.audioWasm=null,this.audioDecoder=null,this.audioEncoder=null,this.bitCount=t.bitCount,this.forceRotate=!1,this.recorder=null,this.recordChunks=[],this.addCanvasWrap(),this.initWebgl(),this.initDecoderWorker()}return p(e,[{key:"addCanvasWrap",value:function(){var e=this;this.canvasWrapper=document.createElement("div"),N(this.canvasWrapper,{position:"relative",width:"100%",height:"100%",overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center",flexDirection:"column"}),this.wrapper.appendChild(this.canvasWrapper),this.fullEl=new Z({el:this.canvasWrapper,autoRotate:!1,disableScroll:!0,nativeFirst:!0}),this.canvas=document.createElement("canvas"),this.canvas.id=this.canvasId,this.canvas.width=this.videoWidth,this.canvas.height=this.videoHeight,this.canvasWrapper.appendChild(this.canvas),this.iframe=document.createElement("iframe"),N(this.iframe,{opacity:0,position:"absolute",zIndex:-1111,left:0,top:0,width:"100%",height:"100%"}),this.iframe.onload=function(){e.iframe.contentWindow.onresize=function(){setTimeout(e.resizeCanvas.bind(e))}},this.canvasWrapper.appendChild(this.iframe)}},{key:"initWebgl",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a,o,s=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this.canvas,t){e.next=3;break}throw new Error("can not find canvas target");case 3:if(n=!Pt()&&t.transferControlToOffscreen&&t.transferControlToOffscreen(),r="wasm"===this.decoderType?ye:ge,!n){e.next=17;break}return this._offscreenCanvas=n,e.next=9,Vt();case 9:i=e.sent,a=i.webglWorker,o=i.webgljs,this.webglWorker=new Worker(a),this.webglWorker.onmessage=function(e){var t=e.data,i=void 0===t?{}:t,a=i.hasInstalled;a&&s.webglWorker.postMessage({cmd:"init",canvas:n,options:{preserveDrawingBuffer:!0,displayMode:s.fishEyeDisplayMode,frameType:r,decoderType:s.decoderType},scripts:[o]},[n])},this.resizeCanvas(),e.next=19;break;case 17:this.webgl=new kt(t,{preserveDrawingBuffer:!0,displayMode:this.fishEyeDisplayMode,frameType:r}),this.resizeCanvas();case 19:t.captureStream&&t.captureStream(60),this.isCover=this.isCover||this.fishEyeDisplayMode!==se;case 21:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"initDecoderWorker",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a,o,s,c,u=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.hasDecoderInit=!1,this.hasNoiseDecoderInit=!1,this.decoderWorker&&this.decoderWorker.terminate(),e.next=5,Ft();case 5:return t=e.sent,n=t.libsWorker,r=t.libaudio,i=t.libaudioWasm,this.noisedecoderWorker=new Worker(n),this.noisedecoderWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,a=n.hasInstalled,o=n.hasInit;if(a)u.noisedecoderWorker.postMessage({cmd:"init",scripts:[r],wasmBinary:i},[i]);else if(o)u.hasNoiseDecoderInit=!0;else if(u.audioVoiceEnable&&!u.isInit)for(var s,c=new Int16Array(n.data),l=160,f=0;f<c.byteLength;f+=l)s=c.slice(f,f+l),u.isPlaying()&&u.audioPlayer.play(s),s.length&&(u._pcmData=new Int16Array(s))},e.next=13,Wt(this.decoderType);case 13:a=e.sent,o=a.decoderWorker,s=a.libffmpeg,c=a.libffmpegWasm,this.decoderWorker=new Worker(o),this.decoderWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,r=n.hasInstalled,i=n.hasInit,a=n.hasWebcodecsConfig,o=n.decodeError,l=n.state;if(r){var f={cmd:"init",decoderType:u.decoderType};return"wasm"===u.decoderType&&(f.scripts=[s],f.wasmBinary=c),void u.decoderWorker.postMessage(f,c?[c]:[])}if(o&&"closed"===l){if(!u.isInit){u._hasWebcodecsConfig=!1;var h={cmd:"init",decoderType:u.decoderType};return void u.decoderWorker.postMessage(h)}u.client.eventSource.dispatchEvent("error",new oe(oe.MEDIA_ERR_DECODER))}if(i)u.hasDecoderInit=!0;else if(a)u._hasWebcodecsConfig=!0;else{if(u.videoQueue.length>=an){var d=u.videoQueue.shift();"webcodecs"===u.decoderType&&d.data.close()}u.videoQueue.push(n),(u.webgl||u.webglWorker)&&u.isInit&&u.flush()}};case 19:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"startRecord",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a,o,s,c,u,l=this,f=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=f.length>0&&void 0!==f[0]?f[0]:{},n=t.timeslice,r=void 0===n?100:n,i=t.micStream,a=void 0!==i&&i,o=this.canvas,s=this.audioPlayer,c=o.captureStream(30),u=s.createMediaStream().stream,!a){e.next=7;break}return e.next=7,navigator.mediaDevices.getUserMedia({audio:!0}).then((function(e){l._mediaStream=e;var t=new AudioContext,n=t.createMediaStreamSource(u),r=t.createMediaStreamSource(e),i=t.createMediaStreamDestination();n.connect(i),r.connect(i),u=i.stream})).catch((function(){}));case 7:this.recorder=new Jt(c,u,this.client),this.recorder.startRecord(r);case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"stopRecord",value:function(){this.recorder.stopRecord()}},{key:"resumeRecord",value:function(){this.recorder&&this.recorder.resumeRecord()}},{key:"pauseRecord",value:function(){this.recorder&&this.recorder.pauseRecord()}},{key:"getRecordInfo",value:function(){return this.recorder.getRecordInfo()}},{key:"stopAndblobDownload",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r=this,i=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=i.length>0&&void 0!==i[0]?i[0]:"record",n=!(i.length>1&&void 0!==i[1])||i[1],e.abrupt("return",this.recorder.stopAndblobDownload(t,n).then((function(e){return r._mediaStream&&r._mediaStream.getAudioTracks()[0].stop(),r._mediaStream=null,e})));case 3:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setAudioType",value:function(e){switch(e){case"PCMA":this.audioDecoderType="_decodeG711a";break;case"G711alaw":this.audioDecoderType="_decodeG711a";break;case"PCMU":this.audioDecoderType="_decodeG711u";break;case"PCMA_W":this.audioDecoderType="_decodeG711a";break;case"G726":this.audioDecoderType="_decodeG726";break;case"ADPCM":this.audioDecoderType="_decodeAdpcm";break;case"AAC":this.audioDecoderType="_decodeAAC";default:break}}},{key:"setConfig",value:function(e){var t=e.codeType,n=void 0===t?this.codeType:t,r=e.audioType,i=void 0===r?this.audioType:r,a=e.sampleRate,o=void 0===a?this.sampleRate:a;this.codeType=n,this.audioType=i,this.sampleRate=o,this._naluParser=new cn[this.codeType],this._hasWebcodecsConfig=!1,O.isSupported&&(this.audioPlayer&&this.audioPlayer.close(),this.audioPlayer=new O({audioType:i,sampleRate:o,pluginPath:this.pluginPath,bitCount:e.bitCount,volume:this.options.volume}))}},{key:"resizeCanvas",value:function(){var e=window.getComputedStyle(this.canvasWrapper,null),t=e.width,n=e.height,r=[parseInt(t),parseInt(n)];t=r[0],n=r[1];var i=this.videoWidth,a=this.videoHeight;if(en.log("resize style: ",t,n,i,a),this.forceRotate&&!G()){var o=[n,t];t=o[0],n=o[1],this.canvas.style.transform=this.getTransformScale()+" rotate(90deg)"}else this.canvas.style.transform=this.getTransformScale();var s=t+"px",c=Math.floor(t*a/i)+"px";parseInt(c)>=n&&(c=n+"px",s=Math.floor(n*i/a)+"px"),this.isCover&&(this.forceRotate&&!G()?(s=t+"px",c=n+"px"):s=c="100%"),this._offscreenCanvas||(this.canvas.width=this.videoWidth,this.canvas.height=this.videoHeight),this.canvas.style.height=c,this.canvas.style.width=s}},{key:"getTransformScale",value:function(){return"scale(".concat(this.zoomScale,") translate(").concat(this.zoomTranslate.x,"px, ").concat(this.zoomTranslate.y,"px)")}},{key:"canvasTransform",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.canvas.style.transform=this.getTransformScale(),this.zoomState&&e&&this.client.eventSource.dispatchEvent("zoom",{scale:this.zoomScale})}},{key:"zoomCanvas",value:function(){var e=this;this.zoomScale=1;var t=this.canvas;t.style.transformOrigin="0 0";var n=function(n,r){var i=t.getBoundingClientRect();return{x:(n-i.left)/e.zoomScale,y:(r-i.top)/e.zoomScale}},r=function(t,n){if(n>0){if(e.zoomScale>=rn)return;e.zoomScale+=tn,e.zoomScale=Math.min(e.zoomScale,rn)}if(n<0){if(e.zoomScale<=nn)return;e.zoomScale-=tn,e.zoomScale=Math.max(e.zoomScale,nn)}var r=t.x*(e.zoomScale-nn)*-1/e.zoomScale,i=t.y*(e.zoomScale-nn)*-1/e.zoomScale;e.zoomTranslate={x:r,y:i},e.canvasTransform()};t.onclick=function(t){if(e.zoomState)if(e.dragState)e.dragState=0;else{var i=n(t.clientX,t.clientY);r(i,1)}},t.oncontextmenu=function(t){if(!e.zoomState)return!1;if(e.dragState)return e.dragState=0,!1;var i=n(t.clientX,t.clientY);return r(i,-1),!1},t.onmousewheel=t.onwheel=function(t){if(e.zoomState){var i=n(t.clientX,t.clientY);r(i,t.wheelDelta)}}}},{key:"dragCanvas",value:function(){var e=this;this.dragState=0;var t=!1,n=this.canvas,r={x:0,y:0};n.onmousedown=function(n){e.zoomState&&(t=!0,r.x=n.clientX,r.y=n.clientY)},document.onmousemove=function(i){if(e.zoomState){var a=e.zoomScale,o=(i.clientX-r.x)/a,s=(i.clientY-r.y)/a;if(!(Math.abs(o)<5&&Math.abs(s)<5)&&(t&&(t=!1,e.dragState=1),e.dragState)){var c=n.getBoundingClientRect(),u=e.canvasWrapper.getBoundingClientRect(),l=e.zoomTranslate,f=l.x,h=l.y;o>0&&c.x<u.x?f+=Math.min((u.x-c.x)/a,o):o<0&&c.x+c.width>u.x+u.width&&(f+=Math.max((u.x+u.width-c.x-c.width)/a,o)),s>0&&c.y<u.y?h+=Math.min((u.y-c.y)/a,s):s<0&&c.y+c.height>u.y+u.height&&(h+=Math.max((u.y+u.height-c.y-c.height)/a,s)),e.zoomTranslate={x:f,y:h},r={x:i.clientX,y:i.clientY},e.canvasTransform(!1)}}},document.onmouseup=function(){e.zoomState&&(t=!1,setTimeout((function(){e.dragState=0})))}}},{key:"clearCanvasEventListener",value:function(){var e=this.canvas;e.onmousedown=null,e.click=null,e.oncontextmenu=null,e.onmousewheel=null,e.onwheel=null,e.ontouchstart=null}},{key:"clearIframeEventListener",value:function(){var e=this.iframe;e.contentWindow&&(e.contentWindow.onresize=null)}},{key:"attachClient",value:function(e,t){this.client=e,t.on("flush",this.onSamples.bind(this))}},{key:"isPlaying",value:function(){return this.client&&!this.client.paused}},{key:"clearVideoQueue",value:function(){"webcodecs"===this.decoderType&&this.videoQueue.forEach((function(e){e.data&&e.data.close()})),this.videoQueue=[]}},{key:"onSamples",value:function(){if(this.hasDecoderInit&&this.decoderWorker)for(var e in this.client.sampleQueues){var t=this.client.sampleQueues[e];switch(parseInt(e)){case w.H264:this.onVideoFrame(t);break;case w.H265:this.onVideoFrame(t);break;case w.AAC:this.onAudioFrame(t);break;case w.G711A:this.onAudioFrame(t);break;case w.PCMA_W:this.onAudioFrame(t);break;default:break}}}},{key:"onVideoFrame",value:function(e){var t=this;if("webcodecs"===this.decoderType){if(e.length>0){var n,r=e[0],i=c(r);try{for(i.s();!(n=i.n()).done;){var a=n.value;if(this._beforeDecodeTime=a.timestamp,this._parameterSet||(this._parameterSet=[]),a.isParameterSet()){if(this._parameterSet.push(a),a.ntype===R.SPS||a.ntype===R.HEVC_SPS){this._naluParser.parseSPS(a.data.subarray(4));var o=this._naluParser.track,s=o.codec,u=o.width,l=o.height;s===this.videoCodec&&u===this.videoWidth&&l===this.videoHeight||(en.log("webcodecs config",s,u,l),this.decoderWorker.postMessage({cmd:"webcodecs_config",codec:s,width:u,height:l}),this.videoCodec=s,this._lastRenderTime=0)}}else{var f=a.ntype,h=a.seq,d=a.data,p=a.payloadType;if(p===w.H265&&(f>1&&f<16||f>20&&f<32||f>34&&f<49||a.isKeyframe()&&d.length<1e3||a.isParameterSet()&&d.length>50))en.log("Undefined NAL unit, type: "+f),this.client.onPlayerNotify({seq:h});else if(this.decoderWorker.postMessage({cmd:"decode",data:a.data.buffer,timestamp:a.timestamp,seq:a.seq,type:a.isKeyframe()?"key":"delta"}),a.isKeyframe()&&(this._parameterSet.forEach((function(e){t.decoderWorker.postMessage({cmd:"decode",data:e.data.buffer,timestamp:e.timestamp,seq:e.seq,type:"delta"})})),this._parameterSet=[]),!this._lastRenderTime&&a.isKeyframe())return}}}catch(b){i.e(b)}finally{i.f()}e.shift()}}else if("wasm"===this.decoderType&&e.length>0){var v,m=e.shift(),y=c(m);try{for(y.s();!(v=y.n()).done;){var g=v.value;this.decoderWorker.postMessage({cmd:"decode",data:g.data.buffer,code_type:this.codeType,pts:g.pts,timestamp:g.timestamp,seq:g.seq,height:this.videoHeight,width:this.videoWidth},[g.data.buffer]),this._beforeDecodeTime=g.timestamp}}catch(b){y.e(b)}finally{y.f()}}}},{key:"onAudioFrame",value:function(e){while(e.length>0){var t,n=e.shift(),r=c(n);try{for(r.s();!(t=r.n()).done;){var i=t.value;this.setAudioType(this.audioType),this.audioVoiceEnable&&this.noisedecoderWorker.postMessage({data:i.data,bitCount:i.bitCount,pts:i.pts,dts:i.dts,timestamp:i.timestamp,seq:i.seq,samplerate:i.samplerate||this.sampleRate,type:i.type,decoderType:this.audioDecoderType})}}catch(a){r.e(a)}finally{r.f()}}}},{key:"mergeArrayBuffer",value:function(e){var t,n=0,r=c(e);try{for(r.s();!(t=r.n()).done;){var i=t.value;n+=i.byteLength}}catch(v){r.e(v)}finally{r.f()}var a,o=new Uint8Array(n),s=0,u=c(e);try{for(u.s();!(a=u.n()).done;)for(var l=a.value,f=0,h=[l];f<h.length;f++){var d=h[f],p=new Uint8Array(d);o.set(p,s),s+=d.byteLength}}catch(v){u.e(v)}finally{u.f()}return o.buffer}},{key:"getSeq",value:function(){var e,t;return this.videoQueue.forEach((function(t){t.seq&&(e=t.seq)})),this.audioQueue.forEach((function(e){e.seq&&(t=e.seq)})),e&&t?Math.max(e,t):e||t}},{key:"flush",value:function(){var e=this;if(this.webgl||this.webglWorker){var t=this.videoQueue.shift();if(!t){var n=this.getSeq();return this.client.onPlayerNotify({seq:n}),void(this.flushInterval=setTimeout((function(){e.flush()}),20))}var r=t.width,i=t.height,a=t.timestamp,o=t.seq,s=this.streamType,c=this.lastVideoData,u=0;if("sdvod"===s&&c){if(this.playScale<=2&&Math.abs(a-this.lastVideoData.timestamp)>=2e3)return en.log("invalid time: ",new Date(a),new Date(this.lastVideoData.timestamp)),this.lastVideoData.timestamp=a,this.client.onPlayerNotify({seq:o}),void this.flush();u=a-c.timestamp,u=Math.max(u,0),this.playScale<1?(u=Math.min(u,100),u*=1/this.playScale):this.playScale<=2?u=Math.min(u,100):(u/=this.playScale,u=Math.min(u,1e3))}clearTimeout(this.flushInterval),this.flushInterval=setTimeout((function(){if(e.videoTimestamp=a,e.videoWidth!==r&&e.canvas&&(e.videoWidth=r,e.videoHeight=i,e.resizeCanvas()),e._lastRenderTime=Date.now(),"webcodecs"===e.decoderType)e.webglWorker?e.isPlaying()&&e.webglWorker.postMessage({cmd:"render",frame:t.data,width:r,height:i},[t.data]):e.isPlaying()&&e.webgl&&e.webgl.renderFrame(t.data,r,i),t.data.close();else{var n=r/2*(i/2),s=r*i;e.webglWorker?e.isPlaying()&&e.webglWorker.postMessage({cmd:"render",frame:t.data,width:r,height:i,yLength:s,uvLength:n}):e.isPlaying()&&e.webgl&&e.webgl.renderFrame(t.data,r,i,s,n)}if(e._fps&&e.isPlaying()?e._fps++:e._fps=1,e._firstRenderTime&&e.isPlaying()){if(Date.now()-e._firstRenderTime>=5e3){var c=e._fps/5;en.log("fps:",c);var u=e._beforeDecodeTime-a;if(c<10&&"hidden"!==document.visibilityState){var l=oe.NETWORK_UNSTABLE_WARNING;r*i>on*sn?l=oe.VIDEO_RES_WARNING:u>1e3&&(l=oe.DECODE_WARNING),e.client.eventSource.dispatchEvent("warning",new oe(l))}e._firstRenderTime=0,e._fps=0}}else e._firstRenderTime=Date.now();e.client.onPlayerNotify({seq:o}),e.isInit&&(e.initCb&&e.initCb(),e.isInit=!1,e.recorder&&e.recorder.stopAndblobDownload()),e.lastVideoData=t,e.flush()}),u)}}},{key:"requestFullscreen",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.forceRotate=t,this.fullEl&&this.fullEl.requestFullscreen(),e&&(this.fullscreenCtrlEl=e,this.canvasWrapper.appendChild(e))}},{key:"exitFullscreen",value:function(){this.fullEl&&this.fullEl.exitFullScreen(),this.forceRotate=!1,this.fullscreenCtrlEl&&this.canvasWrapper.removeChild(this.fullscreenCtrlEl)}},{key:"screenshot",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(!this.isInit){var t=this.canvas.toDataURL();if(e){var n=document.createElement("a");n.href=t,n.download=(new Date).getTime()+".png",n.click()}return t}}},{key:"setVolume",value:function(e){this.audioPlayer&&this.audioPlayer.setVolume(e)}},{key:"getVolume",value:function(){return this.audioPlayer&&this.audioPlayer.getVolume()}},{key:"destroy",value:function(){this.clearCanvasEventListener(),this.clearIframeEventListener(),this.decoderWorker&&this.decoderWorker.postMessage({cmd:"close"}),this.noisedecoderWorker&&this.noisedecoderWorker.terminate(),this.decoderWorker=null,this.noisedecoderWorker=null,this.webgl&&this.webgl.dispose(),this.webgl=null,this.webglWorker&&this.webglWorker.postMessage({cmd:"close"}),this.webglWorker=null,this.canvasWrapper.removeChild(this.canvas),this.canvasWrapper.removeChild(this.iframe),this.wrapper.removeChild(this.canvasWrapper),this.audioPlayer&&this.audioPlayer.close(),this.audioPlayer=null,this.clearVideoQueue(),this.recorder&&"inactive"!==this.recorder.getState()&&this.recorder.stopRecord(),this.recorder=null,this.zoomState=0,clearTimeout(this.flushInterval)}},{key:"toggleZoomState",value:function(e){this.zoomState=e,0===e?(this.zoomTranslate={x:0,y:0},this.zoomScale=1,this.canvasTransform(),this.clearCanvasEventListener()):(this.zoomCanvas(),this.dragCanvas())}},{key:"setZoomScale",value:function(e){if(!(!this.zoomState||e<nn||e>rn)){var t=this.zoomTranslate,n=t.x,r=t.y,i=this.canvas.getBoundingClientRect();e===nn?(n=0,r=0):0===n&&0===r?(n=i.width/2*(e-nn)*-1/e,r=i.height/2*(e-nn)*-1/e):(n=n*e/this.zoomScale,r=r*e/this.zoomScale),this.zoomTranslate={x:n,y:r},this.zoomScale=e,this.canvasTransform()}}},{key:"getTimestamp",value:function(){return this.videoTimestamp}},{key:"setPlayScale",value:function(e){var t=this.getSeq();this.client.onPlayerNotify({seq:t}),this.clearVideoQueue(),this.audioQueue=[],this.playScale=e}},{key:"getPlayScale",value:function(){return this.playScale||1}},{key:"stopFlush",value:function(){clearTimeout(this.flushInterval)}},{key:"startFlush",value:function(){"video"===this.streamType&&this.clearVideoQueue(),this.flush()}},{key:"seek",value:function(e){if(e){var t=this.getSeq();this.client.onPlayerNotify({seq:t}),this.clearVideoQueue(),this.audioQueue=[],this.startTime=e,this.videoTimestamp=e,this.lastVideoData&&(this.lastVideoData.timestamp=e)}}},{key:"setDisplayMode",value:function(e,t){this.fishEyeDisplayMode=e,this.isCover=e!==se||this.options.cover,this.resizeCanvas(),t=Object.assign({},t,{displayMode:e,frameType:"wasm"===this.decoderType?ye:ge}),this.webglWorker?this.webglWorker.postMessage({cmd:"display",options:t}):this.webgl.setDisplayInfo(t)}},{key:"playAudio",value:function(){var e=this.audioPlayer;e&&(e.play(this._pcmData),e.flush(!0))}}]),e}(),ln=un;function fn(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n("f8c9"),n("5d41"),n("e439"),n("3410");function hn(e){return hn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},hn(e)}function dn(e,t){while(!Object.prototype.hasOwnProperty.call(e,t))if(e=hn(e),null===e)break;return e}function pn(){return pn="undefined"!==typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=dn(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},pn.apply(this,arguments)}function vn(e){if(Array.isArray(e))return e}function mn(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,a=[],o=!0,s=!1;try{for(n=n.call(e);!(o=(r=n.next()).done);o=!0)if(a.push(r.value),t&&a.length===t)break}catch(c){s=!0,i=c}finally{try{o||null==n["return"]||n["return"]()}finally{if(s)throw i}}return a}}function yn(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function gn(e,t){return vn(e)||mn(e,t)||s(e,t)||yn()}function bn(e,t){return bn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},bn(e,t)}function Tn(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&bn(e,t)}n("4ae1");function Sn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function En(e,t){if(t&&("object"===f(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return fn(e)}function _n(e){var t=Sn();return function(){var n,r=hn(e);if(t){var i=hn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return En(this,n)}}function kn(e){return-1!==Function.toString.call(e).indexOf("[native code]")}function wn(e,t,n){return wn=Sn()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=Function.bind.apply(e,r),a=new i;return n&&bn(a,n.prototype),a},wn.apply(null,arguments)}function An(e){var t="function"===typeof Map?new Map:void 0;return An=function(e){if(null===e||!kn(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return wn(e,arguments,hn(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),bn(n,e)},An(e)}n("caad"),n("2532"),n("498a"),n("e9c4"),n("aff5"),n("c19f"),n("6062");var Rn=function(){function e(){h(this,e),this.fragmented_nalu=null}return p(e,[{key:"parseSingleNALUPacket",value:function(e,t,n,r){return new R(t.type,e.subarray(0),n,r,t.nri,w.H264)}},{key:"parseAggregationPacket",value:function(t,n,r,i){var a=new DataView(t.buffer,t.byteOffset,t.byteLength),o=0;R.STAP_B===n.type&&(a.getUint16(o),o+=2);var s=[];while(o<a.byteLength){var c=a.getUint16(o);o+=2;var u=e.parseNALHeader(a.getInt8(o));o++;var l=this.parseSingleNALUPacket(t.subarray(o,o+c),u,r,i);null!==l&&s.push(l),o+=c}return s}},{key:"parseFragmentationUnit",value:function(e,t,n,r){var i=new DataView(e.buffer,e.byteOffset,e.byteLength),a=1,o=i.getUint8(a),s=(128&o)>>>7,c=(64&o)>>>6,u=31&o,l=null;if(a++,R.FU_B===t.type&&(i.getUint16(a),a+=2),s){var f=e.subarray(a),h=new Uint8Array(1+f.length);(31&u)==R.IDR?h[0]=101:h[0]=65,h.set(f,1),this.fragmented_nalu=new R(u,h,n,r,null,w.H264)}else if(this.fragmented_nalu&&this.fragmented_nalu.ntype===u&&(this.fragmented_nalu.appendData(e.subarray(a)),c))return l=this.fragmented_nalu,this.fragmented_nalu=null,l;return null}},{key:"onNALUFragment",value:function(t,n,r){var i=new DataView(t.buffer,t.byteOffset,t.byteLength),a=e.parseNALHeader(i.getUint8(0)),o=0,s=null;if(a.type>0&&a.type<24)s=this.parseSingleNALUPacket(t.subarray(o),a,n,r);else{if(R.FU_A!==a.type&&R.FU_B!==a.type)return R.STAP_A===a.type||R.STAP_B===a.type?this.parseAggregationPacket(t.subarray(o),a,n,r):null;s=this.parseFragmentationUnit(t.subarray(o),a,n,r)}return s?[s]:null}}],[{key:"parseNALHeader",value:function(e){return{nri:96&e,type:31&e}}}]),e}(),xn=function(){function e(){h(this,e),this.fragmented_nalu=null}return p(e,[{key:"parseSingleNALUPacket",value:function(e,t,n,r){return new R(e,t.subarray(0),n,r,null,w.H265)}},{key:"parseFragmentationUnit",value:function(e,t,n){var r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=2,a=r.getUint8(i),o=(128&a)>>>7,s=(64&a)>>>6,c=63&a,u=null;if(i++,o){var l=e.subarray(i),f=new Uint8Array(2+l.length);f[0]=129&r.getUint8(0)|c<<1,f[1]=r.getUint8(1),f.set(l,2),this.fragmented_nalu=new R(c,f,t,n,null,w.H265)}else if(this.fragmented_nalu&&this.fragmented_nalu.ntype===c&&(this.fragmented_nalu.appendData(e.subarray(i)),s))return u=this.fragmented_nalu,this.fragmented_nalu=null,u;return null}},{key:"onNALUFragment",value:function(e,t,n){var r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=r.getUint8(0)>>1&63,a=0,o=null;if(i>0&&i<48)o=this.parseSingleNALUPacket(i,e.subarray(a),t,n);else{if(49!=i)return null;o=this.parseFragmentationUnit(e.subarray(a),t,n)}return o?[o]:null}}],[{key:"parseNALHeader",value:function(e){return{nri:96&e,type:31&e}}}]),e}(),Cn=function(){function e(t,n,r){h(this,e),this.dts=n,this.pts=r||this.dts,this.data=t}return p(e,[{key:"getData",value:function(){return this.data}},{key:"getSize",value:function(){return this.data.byteLength}}]),e}(),In=function(){function e(){h(this,e),this.config=null}return p(e,[{key:"onAACFragment",value:function(e){var t=e.getPayload();if(!e.media)return null;var n=new DataView(t.buffer,t.byteOffset,t.byteLength),r=Number(e.media.fmtp["sizelength"]||0),i=Number(e.media.fmtp["indexlength"]||0),a=Number(e.media.fmtp["indexdeltalength"]||0),o=Number(e.media.fmtp["ctsdeltalength"]||0),s=Number(e.media.fmtp["dtsdeltalength"]||0),c=Number(e.media.fmtp["randomaccessindication"]||0),u=Number(e.media.fmtp["streamstateindication"]||0),l=Number(e.media.fmtp["auxiliarydatasizelength"]||0),f=r+Math.max(i,a)+o+s+c+u+l,h=0,d=0,p=9e4*(Math.round(e.getTimestampMS()/1024)<<10)/this.config.samplerate;if(0!==f){var v=n.getUint16(0);h=2+(v>>>3)+(7&v?1:0);for(var m=[],y=0,g=new S(t.subarray(2+d)),b=0,T=0,E=0;E<v;){var _=g.readBits(r);g.readBits(E?a:i),E+=r+(E?a:i),o&&(g.readBits(1),b=g.readBits(o),E+=o),s&&(g.readBits(1),T=g.readBits(s),E+=o),c&&(g.skipBits(1),E+=1),u&&(g.skipBits(u),E+=u),m.push(new Cn(t.subarray(h+y,h+y+_),p+T,p+b)),y+=_}return m}var k=t.subarray(h);while(1){if(255!=k[d])break;++d}return++d,[new Cn(t.subarray(h+d),p)]}}]),e}(),Pn=re("client:rtsp"),On=function(){function e(t,n){h(this,e);var r=new DataView(t.buffer,t.byteOffset,t.byteLength);this.version=r.getUint8(0)>>>6,this.padding=(32&r.getUint8(0))>>>5,this.has_extension=(16&r.getUint8(0))>>>4,this.csrc=15&r.getUint8(0),this.marker=r.getUint8(1)>>>7,this.pt=127&r.getUint8(1),this.sequence=r.getUint16(2),this.timestamp=r.getUint32(4),this.ssrc=r.getUint32(8),this.csrcs=[];var i=12;if(this.csrc>0&&(this.csrcs.push(r.getUint32(i)),i+=4),1==this.has_extension){if(this.extension=r.getUint16(i),this.ehl=r.getUint16(i+2),i+=4,this.header_data=t.slice(i,i+4*this.ehl),1===this.extension&&(this.utc_timestamp=Math.floor(_(r,i)/1e3/1e3)),256===this.extension){var a=0;while(a<4*this.ehl){var o=i+a,s=r.getUint8(o);switch(o+=1,s){case 1:this.channel=r.getUint8(o+2),o+=3;break;case 2:this.frequency=r.getUint8(o+3),this.bitwidth=r.getUint16(o+4),this.audio_channels=r.getUint8(o+6),o+=7;break;case 3:this.frame_flg=r.getUint8(o+2),o+=3;break;case 4:this.utc_timestamp=r.getUint32(o+3),o+=7;default:break}a=o-i}}i+=4*this.ehl}this.headerLength=i,this.media=n.getMediaBlockByPayloadType(this.pt),null===this.media?Pn.log("Media description for payload type: ".concat(this.pt," not provided.")):this.type=this.media.ptype,this.data=t.subarray(i)}return p(e,[{key:"getPayload",value:function(){return this.data}},{key:"getTimestampMS",value:function(){return this.timestamp}},{key:"toString",value:function(){return"RTP(version:"+this.version+", padding:"+this.padding+", has_extension:"+this.has_extension+", csrc:"+this.csrc+", marker:"+this.marker+", pt:"+this.pt+", sequence:"+this.sequence+", timestamp:"+this.timestamp+", ssrc:"+this.ssrc+")"}},{key:"isVideo",value:function(){return"video"==this.media.type}},{key:"isAudio",value:function(){return"audio"==this.media.type}}]),e}(),Dn=function(){function e(t){for(var n in h(this,e),this.tsOffsets={},t.media){var r,i=c(t.media[n].fmt);try{for(i.s();!(r=i.n()).done;){var a=r.value;Pn.log(a),this.tsOffsets[a]={last:0,overflow:0}}}catch(o){i.e(o)}finally{i.f()}}}return p(e,[{key:"build",value:function(e,t){var n=new On(e,t),r=this.tsOffsets[n.pt];return r&&(n.timestamp+=r.overflow,r.last&&Math.abs(n.timestamp-r.last)>2147483647&&(Pn.log("\nlast ts: ".concat(r.last,"\n\n new ts: ").concat(n.timestamp,"\n\n new ts adjusted: ").concat(n.timestamp+4294967295,"\n\n last overflow: ").concat(r.overflow,"\n\n new overflow: ").concat(r.overflow+4294967295,"\n\n ")),r.overflow+=4294967295,n.timestamp+=4294967295),r.last=n.timestamp),n}}]),e}(),Un=function(){function e(t,n,r){h(this,e),this.dts=n,this.pts=r||this.dts,this.data=t}return p(e,[{key:"getData",value:function(){return this.data}},{key:"getSize",value:function(){return this.data.byteLength}}]),e}(),Mn=function(){function e(){h(this,e),this.naluasm=new Rn}return p(e,[{key:"parse",value:function(e){return this.naluasm.onNALUFragment(e.getPayload(),e.timestamp)}}]),e}(),Bn=function(){function e(){h(this,e),this.naluasm=new xn}return p(e,[{key:"parse",value:function(e){return this.naluasm.onNALUFragment(e.getPayload(),e.timestamp)}}]),e}(),Nn=function(){function e(){h(this,e),this.scale=1}return p(e,[{key:"parse",value:function(e){return[new Un(e.data,e.timestamp,e.timestamp)]}}]),e}(),Ln=function(){function e(){h(this,e),this.scale=1,this.asm=new In}return p(e,[{key:"setConfig",value:function(e){this.asm.config=e}},{key:"parse",value:function(e){return this.asm.onAACFragment(e)}}]),e}(),Fn=function(){function e(){h(this,e),this.h264parser=new Mn,this.h265parser=new Bn,this.aacparser=new Ln,this.g711parser=new Nn}return p(e,[{key:"parse",value:function(e){return e.media.ptype==w.H265?this.h265parser.parse(e):e.media.ptype==w.H264?this.h264parser.parse(e):"audio"==e.media.type?this.g711parser.parse(e):null}}]),e}(),jn=re("parser:sdp"),Wn=function(){function e(){h(this,e),this.version=-1,this.origin=null,this.sessionName=null,this.timing=null,this.sessionBlock={},this.media={},this.tracks={},this.mediaMap={}}return p(e,[{key:"parse",value:function(t){var n=this;return jn.log("sdp content: ",t),new Promise((function(r,i){var a,o=t,s=!0,u=n.sessionBlock,l=c(o.split("\n"));try{for(l.s();!(a=l.n()).done;){var f=a.value;if(f=f.replace(/\r/,""),0!==f.length){switch(f.charAt(0)){case"v":if(-1!==n.version)return jn.log("Version present multiple times in SDP"),i(),!1;s=s&&n._parseVersion(f);break;case"o":if(null!==n.origin)return jn.log("Origin present multiple times in SDP"),i(),!1;s=s&&n._parseOrigin(f);break;case"s":if(null!==n.sessionName)return jn.log("Session Name present multiple times in SDP"),i(),!1;s=s&&n._parseSessionName(f);break;case"t":if(null!==n.timing)return jn.log("Timing present multiple times in SDP"),i(),!1;s=s&&n._parseTiming(f);break;case"m":null!==u&&n.sessionBlock!==u&&(n.media[u.type]=u),u={},u.rtpmap={},n._parseMediaDescription(f,u);break;case"a":e._parseAttribute(f,u);break;default:jn.log("Ignored unknown SDP directive: "+f);break}if(!s)return void i()}}}catch(h){l.e(h)}finally{l.f()}n.media[u.type]=u,s?r():i()}))}},{key:"_parseVersion",value:function(e){var t=e.match(/^v=([0-9]+)$/);return t&&t.length?(this.version=t[1],0==this.version||(jn.log("Unsupported SDP version:"+this.version),!1)):(jn.log("'v=' (Version) formatted incorrectly: "+e),!1)}},{key:"_parseOrigin",value:function(e){var t=e.match(/^o=(-?) ([0-9]+) (-?[0-9]+) (-?[0-9]+) (IN) (IP4|IP6) ([^ ]+)$/);return t&&t.length?(this.origin={},this.origin.username=t[2],this.origin.sessionid=t[3],this.origin.sessionversion=t[4],this.origin.nettype=t[5],this.origin.addresstype=t[6],this.origin.unicastaddress=t[7],!0):(jn.log("'o=' (Origin) formatted incorrectly: "+e),!1)}},{key:"_parseSessionName",value:function(e){var t=e.match(/^s=([^\r\n]+)$/);return t&&t.length?(this.sessionName=t[1],!0):(jn.log("'s=' (Session Name) formatted incorrectly: "+e),!1)}},{key:"_parseTiming",value:function(e){var t=e.match(/^t=([0-9]+) ([0-9]+)$/);return t&&t.length?(this.timing={},this.timing.start=t[1],this.timing.stop=t[2],!0):(jn.log("'t=' (Timing) formatted incorrectly: "+e),!1)}},{key:"_parseMediaDescription",value:function(e,t){var n=e.match(/^m=([^ ]+) ([^ ]+) ([^ ]+)[ ]/);if(!n||!n.length)return jn.log("'m=' (Media) formatted incorrectly: "+e),!1;t.type=n[1],t.port=n[2],t.proto=n[3],t.fmt=e.substr(n[0].length).split(" ").map((function(e){return parseInt(e)}));var r,i=c(t.fmt);try{for(i.s();!(r=i.n()).done;){var a=r.value;this.mediaMap[a]=t}}catch(o){i.e(o)}finally{i.f()}return!0}},{key:"getSessionBlock",value:function(){return this.sessionBlock}},{key:"hasMedia",value:function(e){return void 0!=this.media[e]}},{key:"getMediaBlock",value:function(e){return this.media[e]}},{key:"getMediaBlockByPayloadType",value:function(e){return this.mediaMap[e]||null}},{key:"getMediaBlockList",value:function(){var e=[];for(var t in this.media)e.push(t);return e}}],[{key:"_parseAttribute",value:function(e,t){if(null===t)return!0;var n,r=e.indexOf(":"),i=e.substr(0,-1===r?2147483647:r);switch(i){case"a=recvonly":case"a=sendrecv":case"a=sendonly":case"a=inactive":t.mode=e.substr("a=".length);break;case"a=range":n=e.match(/^a=range:\s*([a-zA-Z-]+)=([0-9.]+|now)\s*-\s*([0-9.]*)$/),t.range=[Number("now"==n[2]?-1:n[2]),Number(n[3]),n[1]];break;case"a=control":t.control=e.substr("a=control:".length);break;case"a=rtpmap":if(n=e.match(/^a=rtpmap:(\d+) (.*)$/),null===n)return jn.log("Could not parse 'rtpmap' of 'a='"),!1;var a=parseInt(n[1]);t.rtpmap[a]={};var o=n[2].split("/");t.rtpmap[a].name=o[0].toUpperCase(),t.rtpmap[a].clock=o[1],void 0!==o[2]&&(t.rtpmap[a].encparams=o[2]),t.ptype=w.string_map[o[0].toUpperCase()];break;case"a=fmtp":if(n=e.match(/^a=fmtp:(\d+) (.*)$/),0===n.length)return jn.log("Could not parse 'fmtp' of 'a='"),!1;t.fmtp={};var s,u=c(n[2].split(";"));try{for(u.s();!(s=u.n()).done;){var l=s.value,f=l.indexOf("=");t.fmtp[l.substr(0,f).toLowerCase().trim()]=l.substr(f+1).trim()}}catch(h){u.e(h)}finally{u.f()}break}return!0}}]),e}(),Hn=(n("7db0"),function(){function e(){h(this,e),this.fragments=[],this.pesLength=0,this.pesPkt=null}return p(e,[{key:"parse",value:function(e){if(!this.extPresent)return null;var t=this.parseExtension(e);t.data=e.subarray(t.offset)}},{key:"parseHeader",value:function(){var e=this.fragments[0],t=(e[0]<<16)+(e[1]<<8)+e[2];if(this.extPresent=![190,191].includes(e[3]),1===t){var n=(e[4]<<8)+e[5];return n?(this.pesLength=n,this.hasLength=!0):(this.hasLength=!1,this.pesPkt=null),!0}return!1}},{key:"parseExtension",value:function(e){var t,n,r,i,a;return t=e[1],192&t?(r=536870912*(14&e[3])+4194304*(255&e[4])+16384*(254&e[5])+128*(255&e[6])+(254&e[7])/2,r>4294967295&&(r-=8589934592),64&t?(i=536870912*(14&e[8])+4194304*(255&e[9])+16384*(254&e[10])+128*(255&e[11])+(254&e[12])/2,i>4294967295&&(i-=8589934592)):i=r,n=e[2],a=n+9,{offset:a,pts:r,dts:i}):null}},{key:"feed",value:function(e,t){var n=null;if(t&&this.fragments.length){if(!this.parseHeader())throw new Error("Invalid PES packet");var r=6,i={};this.extPresent&&(i=this.parseExtension(this.fragments[0].subarray(6)),r=i.offset),this.pesPkt||(this.pesPkt=new Uint8Array(this.pesLength));var a=0;while(this.pesLength&&this.fragments.length){var o=this.fragments.shift();if(r){if(o.byteLength<r){r-=o.byteLength;continue}o=o.subarray(r),this.pesLength-=r-(this.hasLength?6:0),r=0}this.pesPkt.set(o,a),a+=o.byteLength,this.pesLength-=o.byteLength}n={data:this.pesPkt,pts:i.pts,dts:i.dts}}else this.pesPkt=null;return this.pesLength+=e.byteLength,this.fragments.length&&this.fragments[this.fragments.length-1].byteLength<6?this.fragments[this.fragments.length-1]=m(this.fragments[0],e):this.fragments.push(e),n}}],[{key:"PTSNormalize",value:function(e,t){var n;if(void 0===t)return e;n=t<e?-8589934592:8589934592;while(Math.abs(e-t)>4294967296)e+=n;return e}}]),e}()),Vn=function(){function e(){h(this,e)}return p(e,null,[{key:"SampleRates",get:function(){return[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350]}},{key:"parseAudioSpecificConfig",value:function(t){var n;n=t.byteLength?new S(t):t;var r=n.bitpos+8*(n.src.byteOffset+n.bytepos),i=n.readBits(5);this.codec="mp4a.40.".concat(i);var a=n.readBits(4);15==a&&n.skipBits(24);var o=n.readBits(4);return{config:b(new Uint8Array(n.src.buffer),r,r+16),codec:"mp4a.40.".concat(i),samplerate:e.SampleRates[a],channels:o}}},{key:"parseStreamMuxConfig",value:function(t){var n=new S(t);if(!n.readBits(1))return n.skipBits(14),e.parseAudioSpecificConfig(n)}}]),e}(),qn=function(){function e(){h(this,e)}return p(e,null,[{key:"parseHeader",value:function(e){var t=new S(e);t.skipBits(15);var n=t.readBits(1);t.skipBits(14);var r=t.readBits(13);t.skipBits(11);var i=t.readBits(2);return n||t.skipBits(16),{size:r-t.bytepos,frameCount:i,offset:t.bytepos}}},{key:"parseHeaderConfig",value:function(e){var t=new S(e);t.skipBits(15);var n=t.readBits(1),r=t.readBits(2)+1,i=t.readBits(4);t.skipBits(1);var a=t.readBits(3);t.skipBits(4);var o=t.readBits(13);t.skipBits(11);var s=t.readBits(2);n||t.skipBits(16);var c,u=navigator.userAgent.toLowerCase(),l=4;-1!==u.indexOf("firefox")?i>=6?(r=5,l=4,c=i-3):(r=2,l=2,c=i):-1!==u.indexOf("android")?(r=2,l=2,c=i):(r=5,l=4,i>=6?c=i-3:(1===a&&(r=2,l=2),c=i));var f=new Uint8Array(l);return f[0]=r<<3,f[0]|=(14&i)>>1,f[1]|=(1&i)<<7,f[1]|=a<<3,5===r&&(f[1]|=(14&c)>>1,f[2]=(1&c)<<7,f[2]|=8,f[3]=0),{config:{config:f,codec:"mp4a.40.".concat(r),samplerate:Vn.SampleRates[i],channels:a},size:o-t.bytepos,frameCount:s,offset:t.bytepos}}}]),e}(),zn=n("af87"),Gn=re("parse ts"),Yn=function(){function e(){h(this,e)}return p(e,null,[{key:"AAC",get:function(){return 15}},{key:"ID3",get:function(){return 21}},{key:"H264",get:function(){return 27}},{key:"H265",get:function(){return 36}},{key:"PCMA",get:function(){return 144}},{key:"PCMU",get:function(){return 145}},{key:"PCMA_W",get:function(){return 146}}]),e}(),Kn=function(){function e(){h(this,e),this.pmtParsed=!1,this.pesParserTypes=new Map,this.pesParsers=new Map,this.pesAsms={},this.ontracks=null,this.toSkip=0,this.pesTypes={},this.iframeTime=0,this.startPts=0,this.patInfo={pmtList:[]}}return p(e,[{key:"addPesParser",value:function(e,t){this.pesParserTypes.set(e,t)}},{key:"parse",value:function(e){var t=new S(e);if(71===e[0]){t.skipBits(9);var n=t.readBits(1);t.skipBits(1);var r=t.readBits(13);t.skipBits(2);var i=t.readBits(1),a=t.readBits(1);if(t.skipBits(4),i){var o=t.readBits(8);if(this.toSkip=t.skipBits(8*o),t.finished())return}if(!a)return;var s=e.subarray(t.bytepos);if(this.pmtParsed&&this.pesParsers.has(r)){var c=this.pesAsms[r].feed(s,n);if(c){(!this.startPts||c.pts-this.startPts<0||c.pts-this.startPts>9e5)&&(this.startPts=c.pts);var u=1e3*(this.iframeTime+(c.pts-this.startPts)/9e4),l=this.pesParsers.get(r).parse(c);return l.timestamp=parseInt(u),l}}else 0===r?(this.patInfo=this.parsePAT(s),this._hasLogPat||(Gn.log("pat info: ",this.patInfo),this._hasLogPat=!0)):this.patInfo.pmtList.find((function(e){return e.pmtId===r}))?(this.parsePMT(s),this.pmtParsed=!0,this._hasLogPmt||(Gn.log("pmt info: ",this.patInfo.pmtList.find((function(e){return e.pmtId===r}))),this._hasLogPmt=!0)):8191===r&&this.parseNPT(s)}return null}},{key:"parsePAT",value:function(e){var t=new S(e),n={};t.skipBits(8),n.tableId=t.readBits(8),n.sectionSyntax=t.readBits(1),n.zero=t.readBits(1),n.reserved1=t.readBits(2),n.sectionLength=t.readBits(12),n.transportStreamId=t.readBits(16),n.reserved2=t.readBits(2),n.version=t.readBits(5),n.currentNextIndicator=t.readBits(1),n.sectionNumber=t.readBits(8),n.lastSectionNumber=t.readBits(8),n.pmtList=[];for(var r=0;r<n.sectionLength-12;r+=4){var i=t.readBits(16);if(n.reserved3=t.readBits(3),n.networkPid=0,0===i)n.networkPid=t.readBits(13);else{var a={};a.programNum=i,a.pmtId=t.readBits(13),n.pmtList.push(a)}}return n}},{key:"parsePMT",value:function(e){var t=new S(e),n=t.readBits(8);t.skipBits(8*n+8),t.skipBits(6);var r=t.readBits(10);t.skipBits(62);var i=t.readBits(10);t.skipBits(8*i);var a=new Set,o=r-13-i;while(o>0){var s=t.readBits(8);t.skipBits(3);var c=t.readBits(13);t.skipBits(6);var u=t.readBits(10);if(t.skipBits(8*u),[Yn.AAC,Yn.PCMA,Yn.H264,Yn.H265,Yn.PCMA_W].includes(s)&&this.pesParserTypes.has(s)&&(!this.pesParsers.has(c)||this.pesTypes[c]!==s))switch(this.pesParsers.set(c,new(this.pesParserTypes.get(s))(s)),this.pesAsms[c]=new Hn,this.pesTypes[c]=s,s){case Yn.H264:a.add({type:w.H264,offset:0});break;case Yn.H265:a.add({type:w.H265,offset:0});break;case Yn.AAC:a.add({type:w.AAC,offset:0});break;case Yn.PCMA:a.add({type:w.G711A,offset:0});break;case Yn.PCMA_W:a.add({type:w.PCMA_W,offset:0});break}o-=5+u}this.ontracks&&this.ontracks(zn["Array"].from(a))}},{key:"parseNPT",value:function(e){var t=new S(e),n=t.readBits(8);switch(n){case 0:break;case 1:t.skipBits(16),this.iframeTime=t.readBits(64),this.startPts=0;break;case 2:break;default:break}}}],[{key:"PACKET_LENGTH",get:function(){return 188}}]),e}(),Xn=function(){function e(t){h(this,e),this.lastUnit=null,this.payloadType=e.PAYLOAD_TYPE_MAP[t]||w.H264;var n=e.PARSERS[t];this.naluasm=n?new n:null}return p(e,[{key:"parse",value:function(e){if(!this.naluasm)return null;var t,n,r,i=e.data,a=0,o=i.byteLength,s=0,c=[];while(a<o)switch(t=i[a++],s){case 0:0===t&&(s=1);break;case 1:s=0===t?2:0;break;case 2:case 3:if(0===t)s=3;else if(1===t&&a<o){if(r){var u=this.naluasm.onNALUFragment(i.subarray(r,a-s-1),e.dts);u&&c.push(u[0])}else n=a-s-1,n&&this.lastUnit&&(this.lastUnit.data=appendByteArray(this.lastUnit.data.byteLength,i.subarray(0,n)));r=a,s=0}else s=0;break;default:break}if(r){var l=this.naluasm.onNALUFragment(i.subarray(r,o),e.dts,e.pts);l&&c.push(l[0])}return this.lastUnit=c[c.length-1],{units:c,type:this.payloadType}}}],[{key:"PARSERS",get:function(){var e;return e={},v(e,Yn.H264,Rn),v(e,Yn.H265,xn),e}},{key:"PAYLOAD_TYPE_MAP",get:function(){var e;return e={},v(e,Yn.H264,w.H264),v(e,Yn.H265,w.H265),e}}]),e}(),Qn=function(){function e(){h(this,e),this.aacOverFlow=null,this.lastAacPTS=null,this.track={},this.config=null}return p(e,[{key:"parse",value:function(e){var t,n,r,i,a,o,s,c=e.data,u=e.pts,l=0,f=this.aacOverFlow,h=this.lastAacPTS;if(f){var d=new Uint8Array(f.byteLength+c.byteLength);d.set(f,0),d.set(c,f.byteLength),c=d}for(r=l,a=c.length;r<a-1;r++)if(255===c[r]&&240===(240&c[r+1]))break;if(r&&(r<a-1?(o="AAC PES did not start with ADTS header,offset:".concat(r),s=!1):(o="no ADTS header found in AAC PES",s=!0),Log.error(o),s))return;var p=null,v={units:[],type:w.AAC};if(this.config||(p=qn.parseHeaderConfig(c.subarray(r)),this.config=p.config,v.config=p.config,p.config=null),n=0,t=9216e4/this.config.samplerate,f&&h){var m=h+t;Math.abs(m-u)>1&&(u=m)}while(r+5<a){if(p||(p=qn.parseHeader(c.subarray(r))),!(p.size>0&&r+p.offset+p.size<=a))break;for(i=u+n*t,v.units.push(new Cn(c.subarray(r+p.offset,r+p.offset+p.size),i)),r+=p.offset+p.size,n++;r<a-1;r++)if(255===c[r]&&240===(240&c[r+1]))break;p=null}return f=r<a&&255==c[r]?c.subarray(r,a):null,this.aacOverFlow=f,this.lastAacPTS=i,v}}]),e}(),$n=function(){function e(){h(this,e),this.dts=0,this.pts=0,this.data=null}return p(e,[{key:"parse",value:function(e){return this.dts=e.dts,this.pts=e.pts,this.data=e.data.subarray(0,e.data.byteLength-8),{units:[{dts:this.dts,pts:this.pts,data:this.data}],type:w.G711A}}}]),e}(),Zn=function(){function e(){h(this,e),this.dts=0,this.pts=0,this.data=null,this.samplerate=8e3,this.wChannels=0}return p(e,[{key:"parse",value:function(e){this.dts=e.dts,this.pts=e.pts,this.data=e.data;var t=new DataView(this.data.buffer),n=t.getUint16(20,!0);this.wChannels=t.getUint16(22,!0),this.samplerate=t.getUint32(24,!0);var r=5;7===n?r="PCMU":6===n?r="G711alaw":69===n?r="G726":17===n&&(r="ADPCM");var i=t.getUint16(34,!0);return{units:[{data:this.data.subarray(44,this.data.byteLength-8),dts:this.dts,pts:this.pts,seq:e.seq,timestamp:e.timestamp,samplerate:this.samplerate,type:r,bitCount:i}],type:w.PCMA_W}}}]),e}(),Jn=function(){function e(t,n){if(h(this,e),n.memoryBase<102400)throw new Error("too small");this._wasmOpts=n,this._memory=new Uint8Array(this._wasmOpts.env.memory.buffer),this._wasm=t}return p(e,[{key:"_copyToMemory",value:function(e){if(e.byteLength>this._wasmOpts.env.memoryBase>>>6)throw new Error("overflow");this._memory.set(new Uint8Array(e.buffer,e.byteOffset,e.byteLength))}}]),e}(),er=function(e){Tn(n,e);var t=_n(n);function n(e,r){return h(this,n),t.call(this,e,r)}return p(n,[{key:"decodeA",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._decodeG711a(e.byteLength,0,e.byteLength),new Int16Array(this._memory.buffer,e.byteLength,e.byteLength)}},{key:"decodeU",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._decodeG711u(e.byteLength,0,e.byteLength),new Int16Array(this._memory.buffer,e.byteLength,e.byteLength)}},{key:"encodeA",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._encodeG711a(e.byteLength,0,e.byteLength>>>1),new Uint8Array(this._memory.buffer,e.byteLength,e.byteLength>>>1)}},{key:"encodeU",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._encodeG711u(e.byteLength,0,e.byteLength>>>1),new Uint8Array(this._memory.buffer,e.byteLength,e.byteLength>>>1)}}]),n}(Jn),tr=function(e){Tn(n,e);var t=_n(n);function n(e,r,i){var a;return h(this,n),a=t.call(this,e,r),a._bitCount=i,a._indexDe=n._currentIndex,a._indexEn=n._currentIndex+1,n._currentIndex=n._currentIndex+2&63,a._wasm.instance.exports._initG726State(a._indexDe,a._bitCount),a._wasm.instance.exports._initG726State(a._indexEn,a._bitCount),a}return p(n,[{key:"decodeBe",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._decodeG726(this._indexDe,0,e.byteLength,e.byteLength,0),new Int16Array(this._memory.buffer,e.byteLength,(e.byteLength<<4)/this._bitCount>>>1)}},{key:"encodeBe",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._encodeG726(this._indexEn,0,e.byteLength/2,e.byteLength,0),new Uint8Array(this._memory.buffer,e.byteLength,e.byteLength*this._bitCount>>>4)}},{key:"decodeLe",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._decodeG726(this._indexDe,0,e.byteLength,e.byteLength,1),new Int16Array(this._memory.buffer,e.byteLength,(e.byteLength<<4)/this._bitCount>>>1)}},{key:"encodeLe",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._encodeG726(this._indexEn,0,e.byteLength/2,e.byteLength,1),new Uint8Array(this._memory.buffer,e.byteLength,e.byteLength*this._bitCount>>>4)}}]),n}(Jn);tr._currentIndex=0;var nr=function(e){Tn(n,e);var t=_n(n);function n(e,r){var i;return h(this,n),i=t.call(this,e,r),i._indexDe=n._currentIndex,i._indexEn=n._currentIndex+1,n._currentIndex=n._currentIndex+2&63,i._wasm.instance.exports._initAdpcmState(i._indexDe),i._wasm.instance.exports._initAdpcmState(i._indexEn),i}return p(n,[{key:"resetDecodeState",value:function(e){this._wasm.instance.exports._resetAdpcmState(this._indexDe,e.valprev,e.index)}},{key:"resetEncodeState",value:function(e){this._wasm.instance.exports._resetAdpcmState(this._indexEn,e.valprev,e.index)}},{key:"getDecodeState",value:function(){return this._wasm.instance.exports._getAdpcmState(this._indexDe,10236,10238),new n.State(this._memory[10236]+(this._memory[10237]<<8),this._memory[10238])}},{key:"getEncodeState",value:function(){return this._wasm.instance.exports._getAdpcmState(this._indexEn,10236,10238),new n.State(this._memory[10236]+(this._memory[10237]<<8),this._memory[10238])}},{key:"decode",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._decodeAdpcm(this._indexDe,0,10240,e.byteLength<<1),new Int16Array(this._memory.buffer,10240,e.byteLength<<1)}},{key:"encode",value:function(e){return this._copyToMemory(e),this._wasm.instance.exports._encodeAdpcm(this._indexEn,0,10240,e.byteLength>>>1),new Uint8Array(this._memory.buffer,10240,e.byteLength>>>2)}}]),n}(Jn);nr._currentIndex=0,nr.State=function(){function e(t,n){h(this,e),this.valprev=t,this.index=n}return p(e)}();var rr={PCMA:er,G711alaw:er,PCMU:er,PCMA_W:er,G726:tr,ADPCM:nr},ir=Symbol("event_listener"),ar=Symbol("event_listeners"),or=function(){function e(t){h(this,e),this[ir]=t,this[ar]=new Map}return p(e,[{key:"clear",value:function(){if(this[ar]){var e,t=c(this[ar]);try{for(t.s();!(e=t.n()).done;){var n,r=e.value,i=c(r[1]);try{for(i.s();!(n=i.n()).done;){var a=n.value;this[ir].removeEventListener(r[0],a)}}catch(o){i.e(o)}finally{i.f()}}}catch(o){t.e(o)}finally{t.f()}}this[ar].clear()}},{key:"destroy",value:function(){this.clear(),this[ar]=null}},{key:"on",value:function(e,t,n){return void 0==n&&(n=t,t=null),t?this.addEventListener(e,(function(e){e.target.matches(t)&&n(e)})):this.addEventListener(e,n)}},{key:"addEventListener",value:function(e,t){return this[ar].has(e)||this[ar].set(e,new Set),this[ar].get(e).add(t),this[ir].addEventListener(e,t,!1),t}},{key:"removeEventListener",value:function(e,t){if(this[ir].removeEventListener(e,t,!1),this[ar].has(e)){var n=this[ar].get(e);n.delete(t),n.size||this[ar].delete(e)}}},{key:"dispatchEvent",value:function(e){this[ir]&&this[ir].dispatchEvent(e)}}]),e}(),sr=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;h(this,e),this[ir]=new or(t||document.createElement("div"))}return p(e,[{key:"clear",value:function(){this[ir]&&this[ir].clear()}},{key:"destroy",value:function(){this[ir]&&(this[ir].destroy(),this[ir]=null)}},{key:"on",value:function(e,t,n){return this[ir]?this[ir].on(e,t,n):null}},{key:"addEventListener",value:function(e,t){return this[ir]?this[ir].addEventListener(e,t,!1):null}},{key:"removeEventListener",value:function(e,t){this[ir]&&this[ir].removeEventListener(e,t,!1)}},{key:"dispatchEvent",value:function(e,t){this[ir]&&this[ir].dispatchEvent(new CustomEvent(e,{detail:t}))}}]),e}(),cr=function(){function e(t){h(this,e),this.eventSource=t,this[ar]=new Map}return p(e,[{key:"on",value:function(e,t,n){this[ar].has(e)||this[ar].set(e,new Set);var r=this.eventSource.on(e,t,n);r&&this[ar].get(e).add(r)}},{key:"off",value:function(e,t){this.eventSource.removeEventListener(e,t)}},{key:"clear",value:function(){this.eventSource.clear(),this[ar].clear()}},{key:"destroy",value:function(){this.eventSource.clear(),this[ar]=null,this.eventSource=null}}]),e}(),ur=function(){function e(t,n){h(this,e),this.stream_type=n,this.endpoint=t,this.eventSource=new sr,this.dataQueue=[]}return p(e,[{key:"destroy",value:function(){this.eventSource.destroy()}},{key:"connect",value:function(){}},{key:"disconnect",value:function(){}},{key:"reconnect",value:function(){var e=this;return this.disconnect().then((function(){return e.connect()}))}},{key:"setEndpoint",value:function(e){return this.endpoint=e,this.reconnect()}},{key:"send",value:function(){}},{key:"prepare",value:function(){}},{key:"onData",value:function(){}}],[{key:"canTransfer",value:function(t){return e.streamTypes().includes(t)}},{key:"streamTypes",value:function(){return[]}}]),e}(),lr=ur,fr=(n("4d63"),n("c607"),n("2c3e"),function(){function e(){h(this,e)}return p(e,null,[{key:"parse",value:function(t){var n={},r=/^([^:]+):\/\/([^\/]+)(.*)$/,i=r.exec(t);if(!i)return null;n.full=t,n.protocol=i[1],n.urlpath=i[3];var a=n.urlpath.split("/");n.basename=a.pop().split(/\?|#/)[0],n.basepath=a.join("/");var o=i[2].split("@"),s=o[0].split(":"),c=[null,null];2===o.length&&(c=o[0].split(":"),s=o[1].split(":")),n.user=c[0],n.pass=c[1],n.host=s[0],n.auth=n.user&&n.pass?"".concat(n.user,":").concat(n.pass):"",n.port=null==s[1]?e.protocolDefaultPort(n.protocol):s[1],n.portDefined=null!=s[1],n.location="".concat(n.host,":").concat(n.port),n.query={};var u=n.urlpath.split("?")[1];return u&&(n.query=u.split("&").reduce((function(e,t){var n=t.split("=");return e[n[0]]=n[1],e}),{})),"unix"==n.protocol&&(n.socket=n.port,n.port=void 0),n}},{key:"full",value:function(e){return"".concat(e.protocol,"://").concat(e.auth?e.auth+"@":"").concat(e.location,"/").concat(e.urlpath)}},{key:"isAbsolute",value:function(e){return/^[^:]+:\/\//.test(e)}},{key:"protocolDefaultPort",value:function(e){switch(e){case"rtsp":return 554;case"http":return 80;case"https":return 443}return 0}}]),e}()),hr=fr,dr="transport:ws",pr=re(dr),vr=function(){function e(t){h(this,e),this.ver=t}return p(e,[{key:"build",value:function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i="";for(var a in n.seq||(n.seq=++e.seq),n)i+="".concat(a,": ").concat(n[a],"\r\n");return"".concat(e.PROTO,"/").concat(this.ver," ").concat(t,"\r\n").concat(i,"\r\n").concat(r)}}],[{key:"PROTO",get:function(){return"WSP"}},{key:"V1_1",get:function(){return"1.1"}},{key:"CMD_INIT",get:function(){return"INIT"}},{key:"CMD_JOIN",get:function(){return"JOIN"}},{key:"CMD_WRAP",get:function(){return"WRAP"}},{key:"CMD_GET_INFO",get:function(){return"GET_INFO"}},{key:"WCC_INVALID_DOMAIN",get:function(){return 4e3}},{key:"parse",value:function(t){var n=t.indexOf("\r\n\r\n"),r=t.substr(0,n).split("\r\n"),i=r.shift().match(new RegExp("".concat(e.PROTO,"/").concat(e.V1_1,"\\s+(\\d+)\\s+(.+)")));if(i){var a={code:Number(i[1]),msg:i[2],data:{},payload:""};while(r.length){var o=r.shift();if(!o)break;var s=o.split(":"),c=gn(s,2),u=c[0],l=c[1];a.data[u.trim()]=l.trim()}return a.payload=t.substr(n+4),a}return null}}]),e}();vr.seq=0;var mr={},yr=function(){function e(t){var n=t.wsurl,r=t.streamType,i=t.wsId,a=t.binaryType,o=void 0===a?"arraybuffer":a,s=t.proto,c=void 0===s?e.CHN_CONTROL:s;h(this,e),this.url=n,this.endpoint=hr.parse(this.url),this.streamType=r,this.data_handler=function(){},this.error_handler=function(){},this.disconnect_handler=function(){},this.awaitingPromises={},this.seq=0,this.encryptor=null,this.wsId=i,this.proto=c,this.binaryType=o,this.connectState=e.CHN_CONTROL,mr[i]=0,this.reconnectTime=0,this.isStopped=!1}return p(e,[{key:"set_data_handler",value:function(e){this.data_handler=e}},{key:"set_error_handler",value:function(e){this.error_handler=e}},{key:"set_disconnect_handler",value:function(e){this.disconnect_handler=e}},{key:"close",value:function(){var e=this;return new Promise((function(t){e.ctrlChannel?(e.ctrlChannel.close(),e.ctrlChannel.onclose=null,e.dataChannel&&(e.dataChannel.onclose=null,e.dataChannel.close()),e.stop(),t()):t()}))}},{key:"onDisconnect",value:function(e){if(this.ctrlChannel.onclose=null,this.ctrlChannel.close(),this.dataChannel&&(this.dataChannel.onclose=null,this.dataChannel.close()),this.disconnect_handler(this),e.code===vr.WCC_INVALID_DOMAIN){var t=new oe(oe.MEDIA_ERR_TRANSPORT);t.message="Invalid Domain (credentials)",Log.error("Invalid domain (credentials)"),this.error(t)}}},{key:"initDataChannel",value:function(){var t=this;this.connectState=e.CHN_DATA,this.dataChannel=this.ctrlChannel,this.dataChannel.binaryType="arraybuffer",this.dataChannel.onopen=function(){},this.dataChannel.onmessage=function(e){var n=e.data;t.reconnectTime=0,t.data_handler&&t.data_handler(n);var r=t.awaitingPromises[mr[t.wsId]];if(r){var i="";if(n instanceof ArrayBuffer){var a=new Uint8Array(n),o=Dt(a,[13,10,13,10]);o&&(i=String.fromCharCode.apply(null,o[0]))}pr.log("headerStr: ",i),i.length&&"$"!==i[0]&&-1===i.indexOf(" video/mp2t")&&(n instanceof ArrayBuffer?r.resolve(String.fromCharCode.apply(null,new Uint8Array(n))):r.resolve(n),t.awaitingPromises[mr[t.wsId]]=null)}},this.dataChannel.onerror=function(e){pr.error("[data] ".concat(e.type)),t.error(oe.MEDIA_ERR_TRANSPORT),t.dataChannel.close()},this.dataChannel.onclose=function(e){pr.error("[data] ".concat(e.type,". code: ").concat(e.code,", reason: ").concat(e.reason||"unknown reason")),!t.isStopped&&t.reconnectTime<3?(t.reconnectTime++,t.connect().then((function(){t.data_handler("reconnect")}))):t.onDisconnect(e)}}},{key:"initCtrlChannel",value:function(t){var n=this;this.connectState=e.CHN_CONTROL,this.ctrlChannel.onopen=function(){pr.log("onopen stream_type",n.streamType),pr.log("onopen url",n.url),t&&t()},this.ctrlChannel.onmessage=function(e){var t=e.data;t instanceof ArrayBuffer&&(t=String.fromCharCode.apply(null,new Uint8Array(t))),!t.length||"$"===t[0]||t.indexOf(" video/mp2t")>-1||(pr.log("on websocket msg: ",t),n.awaitingPromises[mr[n.wsId]].resolve(t),-1!==t.indexOf("RTP-Info")&&n.initDataChannel(n.channel_id))},this.encryptionKey=void 0,this.encryptionKey&&this.encryptor.setPublicKey(this.encryptionKey),this.ctrlChannel.onerror=function(e){pr.error("[ctrl] ".concat(e.type),e),n.error(oe.MEDIA_ERR_CONNECT),n.ctrlChannel.close()},this.ctrlChannel.onclose=function(e){pr.error("[ctrl] ".concat(e.type,". code: ").concat(e.code," ").concat(e.reason||"unknown reason")),n.onDisconnect(e)}}},{key:"connect",value:function(){var e=this;return this.encryptionKey=null,new Promise((function(t){var n=e.url.replace("https://","wss://");e.ctrlChannel=new WebSocket(n,e.proto),pr.log("new WebSocket url",n),e.ctrlChannel.binaryType="arraybuffer",e.connected=!1,e.initCtrlChannel(t)}))}},{key:"encrypt",value:function(e){if(this.encryptionKey){var t=this.encryptor.encrypt(e);return!1===t?void this.error(oe.MEDIA_ERR_ENCRYPTED):t}return e}},{key:"send",value:function(e,t){var n=this;return this.ctrlChannel.readyState!==WebSocket.OPEN?(this.close(),{promise:Promise.resolve()}):(mr[this.wsId]++,"string"===typeof e&&pr.log("send data:\r\n",e),{promise:new Promise((function(r,i){n.awaitingPromises[mr[n.wsId]]={resolve:r,reject:i};var a=n.encrypt(e);"blob"!==n.binaryType||t||(a=new Blob([a])),n.ctrlChannel.send(a)}))})}},{key:"error",value:function(e){return void 0!==e&&(this.error_=new oe(e),this.error_handler&&this.error_handler(this.error_)),this.error_}},{key:"stop",value:function(){this.isStopped=!0}}],[{key:"CHN_CONTROL",get:function(){return"control"}},{key:"CHN_DATA",get:function(){return"data"}},{key:"CHN_RTP",get:function(){return"rtsp-rtp"}},{key:"CHN_TP_PRIVATE",get:function(){return"tp-private"}}]),e}(),gr=yr,br=function(){function e(){h(this,e)}return p(e,null,[{key:"HLS",get:function(){return"hls"}},{key:"RTSP",get:function(){return"rtsp"}},{key:"RELAY",get:function(){return"relay"}},{key:"isSupported",value:function(t){return[e.HLS,e.RTSP,e.RELAY].includes(t)}},{key:"fromUrl",value:function(t){var n;try{n=hr.parse(t)}catch(r){return null}switch(n.protocol){case"rtsp":return e.RTSP;case"http":return null;case"https":return t.indexOf(".m3u8")>=0?e.HLS:t.indexOf("Relay")?e.RELAY:null;default:return null}}},{key:"fromMime",value:function(t){switch(t){case"application/x-rtsp":return e.RTSP;case"application/vnd.apple.mpegurl":case"application/x-mpegurl":return e.HLS;default:return null}}}]),e}(),Tr=br,Sr=function(e){Tn(n,e);var t=_n(n);function n(e){var r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{socket:"".concat(location.protocol.replace("http","ws"),"//").concat(location.host,"/ws/"),binaryType:"arraybuffer"};return h(this,n),r=t.call(this,null,e),r.proxies=[],r.currentProxy=0,r.socketUrl=i.socket,r.type=e,r.ready=r.connect(),r.wsId="ws_"+(new Date).getTime(),r.binaryType=i.binaryType,r.refreshEvent=new CustomEvent("refresh-url",{detail:"refresh-url"}),r}return p(n,[{key:"destroy",value:function(){var e=this;return this.disconnect().then((function(){return pn(hn(n.prototype),"destroy",e).call(e)}))}},{key:"connect",value:function(){var e=this;return this.disconnect().then((function(){var t,n=[];switch(e.type){case Tr.RTSP:t=gr.CHN_CONTROL;break;case Tr.RELAY:t=gr.CHN_TP_PRIVATE;break;default:t=gr.CHN_CONTROL;break}var r=new gr({wsurl:e.socketUrl,streamType:e.type,wsId:e.wsId,binaryType:e.binaryType,proto:t});return r.set_error_handler((function(t){e.eventSource.dispatchEvent("error",t)})),r.set_disconnect_handler((function(t){e.eventSource.dispatchEvent("disconnected",{code:t.code,reason:t.reason}),window.dispatchEvent?window.dispatchEvent(e.refreshEvent):window.fireEvent(e.refreshEvent)})),r.set_data_handler((function(t){"reconnect"===t?e.dataQueue.push(t):e.dataQueue.push(new Uint8Array(t)),e.eventSource.dispatchEvent("data")})),n.push(r.connect().then((function(){e.eventSource.dispatchEvent("connected")})).catch((function(t){throw e.eventSource.dispatchEvent("error",new oe(oe.errorTypes.MEDIA_ERR_CONNECT)),new Error(t)}))),e.proxies.push(r),Promise.all(n)}))}},{key:"disconnect",value:function(){for(var e=[],t=0;t<this.proxies.length;++t)e.push(this.proxies[t].close());return this.proxies=[],this.proxies.length?Promise.all(e):Promise.resolve()}},{key:"reconnect",value:function(){this.ready=this.connect()}},{key:"socket",value:function(){return this.proxies[this.currentProxy++%this.proxies.length]}},{key:"send",value:function(e,t){var n=this.socket().send(e,t);return n.promise}},{key:"stop",value:function(){this.socket().stop()}}],[{key:"canTransfer",value:function(e){return n.streamTypes().includes(e)}},{key:"streamTypes",value:function(){return["hls","rtsp","relay"]}}]),n}(lr),Er=Sr,_r=function(){var e=navigator.userAgent,t=navigator.platform,n={type:"",version:"",bit:"",os:"",osVersion:"0"},r={IE:"ie",EDGE:"edge",FIREFOX:"firefox",CHROME:"chrome",OPERA:"opera",SAFARI:"safari"},i={WINDOWS:"windows",WIN_PHONE:"windowsPhone",LINUX:"linux",IOS:"iOS",ANDROID:"android"},a=/msie ((\d+\.)+\d+)/i,o=/Trident\/[\d.]+[\w\W]*rv:11\.[\d.]+/i,s=/(edge)\/(\d+\.\d+)/i,c=/(chrome)\/(\d+\.\d+)/i,u=/(firefox)\/(\d+\.\d+)/i,l=/(opera).(\d+\.\d+)/i,f=/version\/(\d+\.\d+).*(safari)/i,h=!!a.test(e)&&(document.mode||RegExp["$1"]);if(!1!==h)h<=6?n.version="6.0":7===h?n.version="7.0":8===h?n.version="8.0":9===h?n.version="9.0":10===h&&(n.version="10.0"),n.type=r.IE;else if(o.test(e)){var d=[r.IE,"11.0"];n.type=d[0],n.version=d[1]}else[s,c,u,l,f].some((function(t){var r=e.match(t);if(null!==r){var i=[r[1].toLowerCase(),r[2]];if(n.type=i[0],n.version=i[1],/\d/.test(n.type)){var a=[n.version,n.type];n.type=a[0],n.version=a[1]}return!0}}));return t.indexOf("64")>=0?n.bit="64":n.bit="32","undefined"!==typeof t?t.indexOf("Win")>=0?e.indexOf("Windows Phone")>=0?n.os=i.WIN_PHONE:(n.os=i.WINDOWS,/Windows NT ([\d.]+)/i.test(e)&&(n.osVersion=RegExp["$1"])):e.indexOf("Android")>=0?n.os=i.ANDROID:t.indexOf("iPad")>=0||t.indexOf("iPhone")>=0||t.indexOf("iPod")>=0||t.indexOf("Mac")>=0?n.os=i.IOS:(t.indexOf("X11")>=0||t.indexOf("Linux")>=0||t.indexOf("arm")<0)&&(n.os=i.LINUX):e.indexOf("Android")>=0&&(n.os=i.ANDROID),n},kr=re("state machine"),wr=function(){function e(t,n){h(this,e),this.stateMachine=n,this.transitions=new Set,this.name=t}return p(e,[{key:"activate",value:function(){return Promise.resolve(null)}},{key:"finishTransition",value:function(){}},{key:"failHandler",value:function(){}},{key:"deactivate",value:function(){return Promise.resolve(null)}}]),e}(),Ar=function(){function e(){h(this,e),this.storage={},this.currentState=null,this.states=new Map}return p(e,[{key:"addState",value:function(e,t){var n=t.activate,r=t.finishTransition,i=t.deactivate,a=new wr(e,this);return n&&(a.activate=n),r&&(a.finishTransition=r),i&&(a.deactivate=i),this.states.set(e,a),this}},{key:"addTransition",value:function(e,t){if(!this.states.has(e))throw ReferenceError("No such state: ".concat(e," while connecting to ").concat(t));if(!this.states.has(t))throw ReferenceError("No such state: ".concat(t," while connecting from ").concat(e));return this.states.get(e).transitions.add(t),this}},{key:"_promisify",value:function(e){var t;try{t=e,t.then||(t=Promise.resolve(t))}catch(n){t=Promise.reject(n)}return t}},{key:"transitionTo",value:function(e){var t=this;if(kr.log("transition to ",e),null==this.currentState){var n=this.states.get(e);return this._promisify(n.activate.call(this)).then((function(e){return t.currentState=n,e})).then(n.finishTransition.bind(this)).catch((function(e){throw n.failHandler(),e}))}if(this.currentState.name==e)return Promise.resolve();if(this.currentState.transitions.has(e)){var r=this.states.get(e);return this._promisify(r.deactivate.call(this)).then(r.activate.bind(this)).then((function(e){return t.currentState=r,e})).then(r.finishTransition.bind(this)).catch((function(e){throw r.failHandler(),e}))}return Promise.reject("No such transition: ".concat(this.currentState.name," to ").concat(e))}}]),e}(),Rr=Ar,xr=n("bc3a"),Cr=n.n(xr),Ir=n("3452"),Pr=n.n(Ir);function Or(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.appKey,n=e.appSecret,r=e.terminalId,i=e.method,a=void 0===i?"POST":i,o=e.uri,s=e.payload,c=void 0===s?"UNSIGNED-PAYLOAD":s,u=parseInt(Date.now()/1e3),l="".concat(a," ").concat(o," tp-link_request"),f=Pr.a.SHA256(c).toString(),h="HmacSHA256\n".concat(u,"\n").concat(l,"\n").concat(f),d=Pr.a.HmacSHA256(u+"",n),p=Pr.a.HmacSHA256(o,d),v=Pr.a.HmacSHA256("tp-link",p),m=Pr.a.HmacSHA256(h,v).toString(),y=xt(32),g="Timestamp=".concat(u,",Nonce=").concat(y,",AccessKey=").concat(t,",Signature=").concat(m,",TerminalId=").concat(r);return g}var Dr=new ie,Ur=100,Mr=xt(16),Br=function(){function e(){var t=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flush:10};h(this,e),this.options=n,this.eventSource=new sr,this.readyToPlay=!1,this.isReconnect=!1,this.channel=0,this.sampleQueues={},Object.defineProperties(this,{sourceUrl:{value:null,writable:!0},paused:{value:!0,writable:!0},seekable:{value:!1,writable:!0},connected:{value:!1,writable:!0}}),this._onData=function(){if(t.connected)while(t.transport.dataQueue.length)t.onData(t.transport.dataQueue.pop())},this._onConnect=this.onConnected.bind(this),this._onDisconnect=this.onDisconnected.bind(this),this._onError=this.onError.bind(this)}return p(e,[{key:"getXAuthHeaders",value:function(e){if(!this.options.appKey)return{};var t=e.url,n=hr.parse(t),r=n.basepath+"/"+n.basename,i=Object.assign({headers:{"X-Authorization":Or({appKey:this.options.appKey,appSecret:this.options.appSecret,terminalId:Mr,uri:r,payload:JSON.stringify(e.param||{})})}},i);return i}},{key:"destroy",value:function(){this.detachTransport(),this.stopStreamFlush()}},{key:"attachTransport",value:function(e){this.transport&&this.detachTransport(),this.transport=e,this.transport.eventSource.addEventListener("data",this._onData),this.transport.eventSource.addEventListener("connected",this._onConnect),this.transport.eventSource.addEventListener("disconnected",this._onDisconnect),this.transport.eventSource.addEventListener("error",this._onError)}},{key:"detachTransport",value:function(){this.transport&&(this.transport.eventSource.removeEventListener("data",this._onData),this.transport.eventSource.removeEventListener("connected",this._onConnect),this.transport.eventSource.removeEventListener("disconnected",this._onDisconnect),this.transport.eventSource.removeEventListener("error",this._onError),this.transport.destroy(),this.transport=null)}},{key:"reset",value:function(){}},{key:"start",value:function(){Dr.log("Client started"),this.paused=!1,this.readyToPlay=!0}},{key:"stop",value:function(){Dr.log("Client paused"),this.paused=!0}},{key:"seek",value:function(){}},{key:"setSource",value:function(e){this.stop(),this.endpoint=e,this.sourceUrl=e.urlpath;var t=e.query.channel,n=void 0===t?"":t;this.channel=n?parseInt(n):0}},{key:"feed",value:function(e,t){var n=this,r=this.options.streamType;if("hidden"===document.visibilityState){if("sdvod"===r)return void t.forEach((function(e){n.onPlayerNotify(e)}));"video"===w.map[e]&&(t=t.filter((function(e){return e.isKeyframe()||e.isParameterSet()})),t.length&&(this.sampleQueues[e]=[t]))}else this.sampleQueues[e].length<=Ur&&this.sampleQueues[e].push(t)}},{key:"startStreamFlush",value:function(){var e=this;this.stopStreamFlush(),this.flushInterval=setInterval((function(){e.eventSource.dispatchEvent("flush")}),this.options.flush)}},{key:"stopStreamFlush",value:function(){clearInterval(this.flushInterval)}},{key:"onData",value:function(){}},{key:"onConnected",value:function(){this.seekable||(this.transport.dataQueue=[],this.eventSource.dispatchEvent("clear")),this.connected=!0}},{key:"onDisconnected",value:function(){this.isReconnect||(this.connected=!1,this.eventSource.dispatchEvent("disconnected"))}},{key:"onError",value:function(e){this.eventSource.dispatchEvent("error",e.detail)}},{key:"queryCredentials",value:function(){return Promise.resolve()}},{key:"setCredentials",value:function(e,t){this.endpoint.user=e,this.endpoint.pass=t,this.endpoint.auth="".concat(e,":").concat(t)}},{key:"setPlaybackConfig",value:function(){}},{key:"onPlayerNotify",value:function(){}}],[{key:"streamType",value:function(){return null}},{key:"formatScale",value:function(e){return"number"!==typeof e||0===e?"1/1":(e=Math.abs(e),e<1?"1/".concat(parseInt(1/e)):"".concat(parseInt(e),"/1"))}}]),e}(),Nr=Br;window.URL=window.URL||window.webkitURL,navigator.getUserMedia=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia||navigator.msGetUserMedia;var Lr=function(e,t){t=t||{},t.sampleBits=t.sampleBits||16,t.sampleRate=t.sampleRate||8e3;var n=new(window.webkitAudioContext||window.AudioContext),r=n.createMediaStreamSource(e),i=n.createScriptProcessor||n.createJavaScriptNode,a=i.apply(n,[4096,1,1]),o={size:0,buffer:[],inputSampleRate:n.sampleRate,inputSampleBits:16,outputSampleRate:t.sampleRate,oututSampleBits:t.sampleBits,input:function(e){this.buffer.push(new Float32Array(e)),this.size+=e.length},clear:function(){this.buffer=[],this.size=0},compress:function(){for(var e=new Float32Array(this.size),t=0,n=0;n<this.buffer.length;n++)e.set(this.buffer[n],t),t+=this.buffer[n].length;var r=parseInt(this.inputSampleRate/this.outputSampleRate),i=e.length/r,a=new Float32Array(i),o=0,s=0;while(o<i)a[o]=e[s],s+=r,o++;return a},transToPcmData:function(){Math.min(this.inputSampleRate,this.outputSampleRate);var e=Math.min(this.inputSampleBits,this.oututSampleBits),t=this.compress(),n=t.length*(e/8),r=new ArrayBuffer(n),i=new DataView(r),a=0;if(8===e)for(var o=0;o<t.length;o++,a++){var s=Math.max(-1,Math.min(1,t[o])),c=s<0?32768*s:32767*s;c=parseInt(255/(65535/(c+32768))),i.setInt8(a,c,!0)}else for(var u=0;u<t.length;u++,a+=2){var l=Math.max(-1,Math.min(1,t[u]));i.setUint16(a,l<0?32768*l:32767*l,!0)}return new Blob([i])}};this.start=function(){r.connect(a),a.connect(n.destination)},this.audioTatch=function(){};var s=this;this.stop=function(){r.disconnect(),a.disconnect();var t=e.getAudioTracks();t[0].stop()},this.clear=function(){o.clear()},this.getPcmData=function(){return o.transToPcmData()},this.play=function(e){var t=document.getElementById("downloadRec");t.href=window.URL.createObjectURL(this.getPcmData()),t.download=(new Date).toLocaleString()+".mp3",e.src=window.URL.createObjectURL(this.getPcmData())},a.onaudioprocess=function(e){o.clear(),o.input(e.inputBuffer.getChannelData(0)),s.audioTatch()}};Lr.throwError=function(e){throw alert(e),new function(){this.toString=function(){return e}}},Lr.canRecording=null!=navigator.getUserMedia,Lr.get=function(e,t){if(e)if(navigator.mediaDevices&&navigator.mediaDevices.getUserMedia)navigator.mediaDevices.getUserMedia({audio:!0}).then((function(n){var r=new Lr(n,t);e({rec:r})}),(function(t){e({error:t})}));else{if(!navigator.getUserMedia)return void Lr.throwError("当前浏览器不支持录音功能。");navigator.getUserMedia({audio:!0},(function(n){var r=new Lr(n,t);e({rec:r})}),(function(t){e({error:t})}))}};var Fr=Lr,jr=function(){function e(t){h(this,e),this.version=t}return p(e,[{key:"build",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i="".concat(e," ").concat(t," ").concat(this.version,"\r\n");for(var a in n)i+="".concat(a,": ").concat(n[a],"\r\n");return null!==r&&(r instanceof Object&&(r=JSON.stringify(r)),i+="Content-Length: ".concat(r.length,"\r\n")),i+="\r\n",null!==r&&(i+=r),i}},{key:"parse",value:function(e){var t=e.split("\r\n");1===t.length&&(t=t[0].split("\n"));var n={headers:{},body:null,code:0,statusLine:""},r=t[0].match(new RegExp("".concat(this.version,"[ ]+([0-9]{3})[ ]+(.*)"))),i=gn(r,3);n.code=i[1],n.statusLine=i[2],n.code=Number(n.code);var a=1;while(t[a]){var o=t[a].split(/:(.+)/),s=gn(o,2),c=s[0],u=s[1];n.headers[c.toLowerCase()]=u.trim(),a++}var l=t.slice(a).join("\n\r");return n.body=JSON.stringify(l),n}}],[{key:"RTSP_1_0",get:function(){return"RTSP/1.0"}},{key:"HTTP_1_1",get:function(){return"HTTP/1.1"}},{key:"MULTITRANS",get:function(){return"MULTITRANS"}}]),e}();Cr.a.defaults.withCredentials=!0;var Wr=window.WebAssembly?new WebAssembly.Memory({initial:256,maximum:256}):{buffer:[]},Hr={env:{abortStackOverflow:function(){throw new Error("overflow")},table:window.WebAssembly?new WebAssembly.Table({initial:0,maximum:0,element:"anyfunc"}):{},tableBase:0,memory:Wr,memoryBase:204800,STACKTOP:0,STACK_MAX:Wr.buffer.byteLength}},Vr=re("client:relay"),qr=function(e){Tn(n,e);var t=_n(n);function n(e){return h(this,n),t.call(this,e)}return p(n)}(An(Error)),zr={PERMISSION_DENIED:1202,NOT_SUPPORTED_ERROR:1203,MANDATORY_UNSATISFIED_ERROR:1204,NotFoundError:1205,NotAllowedError:1208},Gr={"-82400":"CLOUD_ERR_PARAM","-82401":"CLOUD_ERR_PERMISSION","-82414":"CLOUD_ERR_SERVER","-80702":"COMMON_ERR_SESSION","-80731":"CLOUD_ERR_TOKEN","-80304":"CLOUD_ERR_DEVID","-80732":"CLOUD_ERR_BANDWIDTH","-20002":"DEVICE_ERR_CHN_OFFLINE","-20571":"DEVICE_ERR_CHN_OFFLINE","-52405":"CLOUD_ERR_STREAM_LIMIT","-52413":"DEVICE_ERR_CHN_OFFLINE","-40106":"AUDIO_ERR_AUDIO_ENABLE","-52412":"AUDIO_ERR_AUDIO_NOSUPPORTED","-52411":"AUDIO_ERR_AUDIO_BUSY"},Yr=5,Kr=0,Xr="client-stream-boundary",Qr=200,$r=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this),r.parent=e,r.transport=null,r.onRelayConfig=null,r.streams=null,r.env=_r(),r.messageBuilder={RTSP:new jr(jr.RTSP_1_0),HTTP:new jr(jr.HTTP_1_1)},r.isPlaying=!1,r.methods=["PLAY","PAUSE"],r.reconnectTimer=0,r.redirectTime=0,r.addState(n.STATE_INITIAL,{}).addState(n.STATE_GET_RELAY,{activate:r.getRelayRelease,finishTransition:r.onRelayRelease}).addState(n.STATE_OPTIONS,{activate:r.sendOptions,finishTransition:r.onOptions}).addState(n.STATE_STREAMS,{}).addState(n.STATE_TEARDOWN,{activate:function(){r.started=!1},finishTransition:function(){return r.transitionTo(n.STATE_INITIAL)}}).addState(n.STATE_PAUSED,{activate:r.sendPause,finishTransition:r.onPause}).addState(n.STATE_PLAY,{activate:r.sendPlay,finishTransition:r.onPlay}).addTransition(n.STATE_INITIAL,n.STATE_GET_RELAY).addTransition(n.STATE_INITIAL,n.STATE_TEARDOWN).addTransition(n.STATE_GET_RELAY,n.STATE_TEARDOWN).addTransition(n.STATE_STREAMS,n.STATE_PAUSED).addTransition(n.STATE_PAUSED,n.STATE_STREAMS).addTransition(n.STATE_STREAMS,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_PLAY).addTransition(n.STATE_PLAY,n.STATE_STREAMS).addTransition(n.STATE_PLAY,n.STATE_TEARDOWN).addTransition(n.STATE_TEARDOWN,n.STATE_INITIAL),r}return p(n,[{key:"destroy",value:function(){clearTimeout(this.reconnectTimer)}},{key:"setSource",value:function(){}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&(Vr.log("start"),this.start());case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onDisconnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.reset(),this.shouldReconnect=!0,e.next=4,this.transitionTo(n.STATE_TEARDOWN);case 4:return e.next=6,this.transitionTo(n.STATE_INITIAL);case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){return this.currentState.name!==n.STATE_STREAMS?this.transitionTo(n.STATE_GET_RELAY):Promise.resolve()}},{key:"stop",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.started){e.next=3;break}return e.next=3,this.transitionTo(n.STATE_TEARDOWN);case 3:this.shouldReconnect=!1;case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"error",value:function(e){this.parent.error(e)}},{key:"onData",value:function(){}},{key:"reset",value:function(){}},{key:"reconnect",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.reset();case 2:if(this.currentState.name==n.STATE_INITIAL){e.next=8;break}return e.next=5,this.transitionTo(n.STATE_TEARDOWN);case 5:return e.abrupt("return",this.transitionTo(n.STATE_GET_RELAY));case 8:return e.abrupt("return",this.transitionTo(n.STATE_GET_RELAY));case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"supports",value:function(e){return this.methods.includes(e)}},{key:"sendRequest",value:function(){}},{key:"send",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=a.length>1&&void 0!==a[1]?a[1]:"RTSP",!this.transport){e.next=18;break}return e.prev=2,e.next=5,this.transport.ready;case 5:e.next=11;break;case 7:throw e.prev=7,e.t0=e["catch"](2),this.onDisconnected(),e.t0;case 11:return e.next=13,this.transport.send(t);case 13:return r=e.sent,i=this.parse(r,n),e.abrupt("return",i);case 18:return e.abrupt("return",Promise.reject("No transport attached"));case 19:case"end":return e.stop()}}),e,this,[[2,7]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parse",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RTSP",n=e.split("\r\n\r\n"),r=this.messageBuilder[t].parse(n[0]),i=Number(r.headers["content-length"]||0);if(i){var a=n[1];a&&(a=JSON.parse(a)),r.body=a}else r.body="";return Vr.log("parsed data: ",r),r}},{key:"sendTeardown",value:function(){var e="TEARDOWN";return this.sendRequest(e,"*")}},{key:"sendOptions",value:function(){return this.reset(),this.started=!0,this.cSeq=0,this.sendRequest("OPTIONS",this.url,{})}},{key:"onOptions",value:function(e){this.methods=e.headers["public"].split(",").map((function(e){return e.trim()})),this.transitionTo(n.STATE_GET_STREAMS)}},{key:"pause",value:function(){return this.currentState.name===n.STATE_STREAMS||this.currentState.name===n.STATE_SEND_VOICE?this.transitionTo(n.STATE_PAUSED):Promise.resolve()}},{key:"sendPause",value:function(){}},{key:"onPause",value:function(){}},{key:"play",value:function(){return this.currentState.name===n.STATE_PAUSED?this.transitionTo(n.STATE_PLAY):Promise.resolve()}},{key:"sendPlay",value:function(){}},{key:"onPlay",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"errorException",value:function(e){var t=e.type,r=e.params,i=void 0===r?{}:r;if("response"===t&&0!==i["error_code"]){var a=Gr[i["error_code"]]||"CLOUD_ERR_STREAM";return this.error(oe[a]),this.transitionTo(n.STATE_TEARDOWN),!0}return!1}},{key:"updateReceivedSeq",value:function(){}}],[{key:"USER_AGENT",get:function(){return"SFRtsp 0.3"}},{key:"SLP",get:function(){return["1.3"]}},{key:"NVMP",get:function(){return["2.0"]}},{key:"RESPONSE_ERR_CODE",get:function(){return{429:oe.CLOUD_ERR_STREAM_LIMIT,432:oe.CLOUD_ERR_WINDOW_LIMIT,433:oe.CLOUD_ERR_CLIENT_LIMIT}}},{key:"FINISH_REASON",get:function(){return{share_finish:oe.CLOUD_ERR_SHARE_FINISH,permission_deny:oe.CLOUD_ERR_PERMISSION,channel_offline:oe.DEVICE_ERR_CHN_OFFLINE,channel_invalid:oe.DEVICE_ERR_CHN_INVALID,internal_error:oe.COMMON_ERR_INTERNAL,password_changed:oe.DEVICE_ERR_PWD_CHANGED,media_encrypt_changed:oe.CLOUD_ERR_ENCRYPT_CHANGED,relay_lifetime_expired:oe.CLOUD_ERR_FREE,channel_talk_busy:oe.CLOUD_ERR_TALK_BUSY,unbind_device:oe.CLOUD_ERR_UNBIND,lack_bandwidth:oe.CLOUD_ERR_BANDWIDTH,offline:oe.DEVICE_ERR_CHN_OFFLINE}}},{key:"STATE_INITIAL",get:function(){return 1}},{key:"STATE_OPTIONS",get:function(){return 2}},{key:"STATE_GET_RELAY",get:function(){return 4}},{key:"STATE_GET_STREAMS",get:function(){return 8}},{key:"STATE_STREAMS",get:function(){return 16}},{key:"STATE_TEARDOWN",get:function(){return 32}},{key:"STATE_PAUSED",get:function(){return 64}},{key:"STATE_PLAY",get:function(){return 128}},{key:"STATE_SEND_VOICE",get:function(){return 256}}]),n}(Rr),Zr=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.slpRecorder=null,r.audioSlpEncoder=null,r.noisedecoderSlpWorker=null,r.hasNoiseSlpDecoderInit=!1,r.initDecoderSlpWorker(),r.continuityCounterTs=48,r.continuityCounterPes=16,r.continuityCounterPNT=16,r.ptsMultiple=1,r.fPATCount=0,r.fPMTCount=0,r.tsaudioBuffer=new Uint8Array,r.tsCount=0,r.addState($r.STATE_SEND_VOICE,{activate:r.sendSlpVoice,finishTransition:r.onSlpVoice}).addTransition($r.STATE_GET_RELAY,$r.STATE_SEND_VOICE).addTransition($r.STATE_SEND_VOICE,$r.STATE_STREAMS).addTransition($r.STATE_SEND_VOICE,$r.STATE_TEARDOWN),r.reset(),r}return p(n,[{key:"initDecoderSlpWorker",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.hasNoiseSlpDecoderInit=!1,e.next=3,Ft();case 3:t=e.sent,n=t.libsWorker,r=t.libaudio,i=t.libaudioWasm,this.noisedecoderSlpWorker=new Worker(n),this.noisedecoderSlpWorker.postMessage({cmd:"init",scripts:[r],wasmBinary:i}),this.noisedecoderSlpWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,r=n.hasInit;r?a.hasNoiseSlpDecoderInit=!0:a.transformSlpTsBuffer(n.data,a.audioSlpEncoder)};case 10:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){Vr.log("set source: ",e),this.reset(),this.endpoint=e}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.shouldReconnect&&(Vr.log("start"),this.start());case 1:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.deviceBoundary="",this.sessionId="",this.loadedChunks=[],this.parsing=!1,this.cSeq=0,this.payload={},this.receivedSeq=0,this.initParser(),!this.currentState){e.next=16;break}if(this.currentState.name==$r.STATE_INITIAL){e.next=14;break}return e.next=12,this.transitionTo($r.STATE_TEARDOWN);case 12:return e.next=14,this.transitionTo($r.STATE_INITIAL);case 14:e.next=18;break;case 16:return e.next=18,this.transitionTo($r.STATE_INITIAL);case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"initParser",value:function(){var e=this;this.parser=new Kn,this.parser.addPesParser(Yn.H264,Xn),this.parser.addPesParser(Yn.H265,Xn),this.parser.addPesParser(Yn.AAC,Qn),this.parser.addPesParser(Yn.PCMA_W,Zn),this.parser.addPesParser(Yn.PCMA,$n),this.parser.ontracks=function(t){var n,r={},i=c(t);try{for(i.s();!(n=i.n()).done;){var a=n.value;switch(e.parent.sampleQueues[a.type]=[],a.type){case w.H264:r.video_codec="H264";break;case w.H265:r.video_codec="H265";break;case w.G711A:r.audio_codec="G711alaw";break;case w.AAC:r.audio_codec="AAC";break;case w.PCMA_W:r.audio_codec="PCMA_W";break;default:break}}}catch(o){i.e(o)}finally{i.f()}r.video_codec&&e.onRelayConfig(r)}}},{key:"buildBoundary",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r="--".concat(Xr,"\r\n");if("sendMultiparts"===n?e=T(new Uint8Array(e)):e instanceof Object&&(e=JSON.stringify(e)),"sendMultiparts"===n?(r+="Content-Type: audio/mp2t\r\n",r+="X-If-Encrypt\t: ".concat(0,"\r\n")):r+="Content-Type: application/json\r\n",r+="Content-Length: ".concat(e.length,"\r\n"),this.sessionId&&(r+="X-Session-Id: ".concat(this.sessionId,"\r\n")),t&&(r+=t),r+="\r\n",r+=e,"sendMultiparts"===n){for(var i=r.length,a=new Uint8Array(i),o=0;o<i;o++)a[o]=r.charCodeAt(o);return a.buffer}return r}},{key:"sendBoundary",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=17;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t);case 12:return n=e.sent,r=this.parseBoundary(n),e.abrupt("return",r);case 17:return e.abrupt("return",Promise.reject("No transport attached"));case 18:case"end":return e.stop()}}),e,this,[[1,6]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parseBoundary",value:function(e){var t=e.split("\r\n\r\n"),n=gn(t,2),r=n[0],i=n[1],a={headers:{},body:i},o=r.split("\r\n");if(-1===o[0].indexOf(this.deviceBoundary))a.body=e;else{var s=1;while(o[s]){var c=o[s].split(/:(.+)/),u=gn(c,2),l=u[0],f=u[1];a.headers[l.toLowerCase()]=f.trim(),s++}}return a}},{key:"onData",value:function(e){var t=T(e),n=this.parseBoundary(t),r=n.headers,i=n.body;if("application/json"===r["content-type"]){Vr.log("on data: ",i),i=JSON.parse(i);var a=i,o=a.params,s=void 0===o?{}:o,c=s.error_code,u=void 0===c?0:c;if(u){var l=Gr[u]||"CLOUD_ERR_STREAM";return this.error(oe[l]),void this.transitionTo($r.STATE_TEARDOWN)}if(s.session_id&&(this.sessionId=s.session_id),"stream_finish"===s.event_type){this.parent.stop();var f=$r.FINISH_REASON[s.reason];this.error(f||oe.MEDIA_ERR_NETWORK)}else if("channel_stream_status"===s.event_type){var h=s.status&&s.status[0],d=$r.FINISH_REASON[h];"no_data"===h||d&&(this.parent.stop(),this.error(d))}}else{for(var p=[],v=0;v<i.length;v++)p.push(i.charCodeAt(v));this.onTS(new Uint8Array(p),r["x-data-sequence"])}}},{key:"getRelayRelease",value:function(){this.sessionId="";var e=this.parent,t=e.relayOptions,n=void 0===t?{}:t,r=e.clientUUID,i=n.cookie,a=n.token,o=n.relayVersion,s="POST",c={Host:this.endpoint.location,"User-Agent":"Client=TP-LINK/".concat(o),Cookie:i,"X-token":a,"X-Client-UUID":r,"X-Redirect-Times":this.redirectTime,"X-Client-Model":this.env.os,Accept:"/","Content-Type":"multipart/mixed; boundary=".concat(Xr),"Content-Length":Number.MAX_SAFE_INTEGER},u=this.parent.channel,l=void 0===u?0:u,f={method:"get",talk:{mode:this.parent.options.mode||"aec",channel:l}},h={type:"request",seq:0,params:f},d="",p=this.messageBuilder["HTTP"].build(s,this.endpoint.urlpath,c,null);return p+=this.buildBoundary(h,d),this.send(p,"HTTP")}},{key:"onRelayRelease",value:function(e){var t=this,n=e.headers,r=e.code;if(404!==r&&410!==r){if(301===r){var i=n["x-domain"],a=n["x-redirect-cookie"];return this.parent.redirect({domain:i,cookie:a}),void this.redirectTime++}if(this.redirectTime=0,Kr=0,this.parent.isReconnect=!1,200===r){this.deviceBoundary=n["content-type"].split("boundary=")[1];var o=this.transport.socket();o.initDataChannel(),this.transitionTo($r.STATE_SEND_VOICE)}else{var s=$r.RESPONSE_ERR_CODE[e.code];this.error(s||oe.CLOUD_ERR_DEV_RELAY)}}else Kr<=Yr?(Kr++,this.reconnectTimer=setTimeout((function(){t.reset(),t.redirectTime?t.parent.play():t.parent.start()}),500)):(Kr=0,this.error(oe.CLOUD_ERR_DEV_RELAY))}},{key:"sendSlpVoice",value:function(){var e=this;Fr.get((function(t){t.rec?(e.parent.sendAudioStream(),e.slpRecorder=t.rec,e.startSlpRecorder()):e.parent.error(zr[t.error.name])}))}},{key:"startSlpRecorder",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.slpRecorder.start(),t=new rr["PCMA"](this.parent.audioWasm,Hr),this.audioSlpEncoder=t.encodeA.bind(t),this.slpRecorder.audioTatch=function(){n.slpDataPart(n.audioSlpEncoder)};case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"slpDataPart",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=new FileReader,r=this,n.onload=function(e){var n=e.target.result,i=2048,a=new Uint8Array([].concat(Le(r.tsaudioBuffer),Le(new Uint8Array(n))));if(a.length>0)for(var o=new Uint8Array(i),s=0,c=0;c<a.byteLength;c++)o[s++]=a[c],(c+1)%i===0&&(r.noiseSetSlp(o,t),o=a.byteLength-c-1>=i?new Uint8Array(i):new Uint8Array(a.byteLength-c-1),s=0),c+1===a.byteLength&&(c+1)%i!==0&&(r.tsaudioBuffer=o)},n.readAsArrayBuffer(this.slpRecorder.getPcmData());case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"noiseSetSlp",value:function(e,t){var n=t(e);this.noisedecoderSlpWorker.postMessage({data:n,samplerate:8e3,decoderType:"_decodeG711a"})}},{key:"transformSlpTsBuffer",value:function(e,t){var n=t(e),r=new Uint8Array(n),i=this.PacketDataToTs(r,1024);this.sendMultiparts(i,"","sendMultiparts")}},{key:"PacketDataToTs",value:function(e,t){var n=!1,r=188,i=0,a=1504,o=14,s=new ArrayBuffer(a),c=new DataView(s);if(!n){c.setUint8(i,71),i+=1,c.setUint8(i,64),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,16+(15&this.fPATCount)),this.fPATCount++,i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,176),i+=1,c.setUint8(i,13),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,193),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1;var u=this.pat(),l=E(new Uint8Array(u.pATSetCrc32Buf),u.setPATSetCrc32Off);c.setUint32(i,l),i+=4;for(var f=i;f<188;f++,i+=1)c.setUint8(i,255);c.setUint8(i,71),i+=1,c.setUint8(i,80),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,16+(15&this.fPMTCount)),this.fPMTCount++,i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,2),i+=1;var h=26,d=h-3;d-=5,c.setUint8(i,176),i+=1,c.setUint8(i,d),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,193),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,225),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,144),i+=1,c.setUint8(i,225),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1;var p=this.pmt(),v=E(new Uint8Array(p.pmtcrcBuf),p.pmtOff);c.setUint32(i,v),i+=4;for(f=i;f<376;f++,i+=1)c.setUint8(i,255);n=!0}var m=0,y=0,g=0,b=12+o,T=r-b;t<=T?(m=1,y=t):(m=parseInt((t-T-1)/(r-4))+1,m+=1,y=(t-T)%(r-4),0==y&&(y=r-4));for(var S=0;S<m;S++){var _=i;if(0==S)c.setUint8(i,71),i+=1,c.setUint8(i,65),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1,c.setUint8(i,7),i+=1,c.setUint8(i,16),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,192),i+=1,c.setUint16(i,t+8),i+=2,c.setUint8(i,128),i+=1,c.setUint8(i,128),i+=1,c.setUint8(i,5),i+=1,c.setUint8(i,33),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1;else if(S==m-1)if(184==y)c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,16+(15&this.tsCount)),this.tsCount++,i+=1;else if(183==y)c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1,c.setUint8(i,0),i+=1;else{c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1;var k=r-6-y;c.setUint8(i,1+k),i+=1,c.setUint8(i,0),i+=1;for(var w=0;w<k;w++,i+=1)c.setUint8(i,255)}else c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,16+(15&this.tsCount)),this.tsCount++,i+=1;for(var A=i-_,R=0;R<188-A;R++,i+=1)c.setUint8(i,e[R+g]);g+=r-A}return s}},{key:"pat",value:function(){var e=new ArrayBuffer(12),t=new DataView(e),n=0;return t.setUint8(n,0),n+=1,t.setUint8(n,176),n+=1,t.setUint8(n,13),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,193),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,0),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,224),n+=1,t.setUint8(n,1),n+=1,{pATSetCrc32Buf:e,setPATSetCrc32Off:n}}},{key:"pmt",value:function(){var e=new ArrayBuffer(17),t=new DataView(e),n=0;t.setUint8(n,2),n+=1;var r=26,i=r-3;return i-=5,t.setUint8(n,176),n+=1,t.setUint8(n,i),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,193),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,224),n+=1,t.setUint8(n,68),n+=1,t.setUint8(n,240),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,144),n+=1,t.setUint8(n,225),n+=1,t.setUint8(n,1),n+=1,t.setUint8(n,240),n+=1,t.setUint8(n,0),n+=1,{pmtcrcBuf:e,pmtOff:n}}},{key:"packageNullPacket",value:function(){var e=new ArrayBuffer(188),t=new DataView(e),n=0;return t.setUint8(n,71),n+=1,t.setUint8(n,31),n+=1,t.setUint8(n,18),n+=1,this.continuityCounterPNT>30&&(this.continuityCounterPNT=16),t.setUint8(n,this.continuityCounterPNT),n+=1,this.continuityCounterPNT++,t.setUint8(n,0),n+=1,t.setUint8(n,parseInt(254*Math.random()+1)),n+=1,e}},{key:"onSlpVoice",value:function(){console.log("结束")}},{key:"sendMultiparts",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=this.buildBoundary(e,t,r);return this.sendBoundary(i).then((function(e){Vr.log("on multiparts\n",e);var t=e.body,r=void 0===t?"{}":t;r=JSON.parse(r);var i=r,a=i.params,o=void 0===a?{}:a;return n.errorException(r)?null:(o.session_id&&(n.sessionId=o.session_id),e)}))}},{key:"onTS",value:function(e,t){this.isPlaying||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream")),this.parsing?this.loadedChunks.push(e):(this.parsing=!0,this.parseTS(e,t))}},{key:"parseTS",value:function(e,t){for(var n=this,r=function(r){var i=n.parser.parse(e.subarray(r,r+Kn.PACKET_LENGTH));if(i&&n.parent.sampleQueues[i.type]){var a=i.units;if(n.parent.readyToPlay){var o=!1,s=a[0].ntype;switch(Vr.log("nalu type: ",s,i.type),i.type){case w.H264:o=7===s;break;case w.H265:o=32===s;break;default:break}if(!o)return"continue";n.parent.readyToPlay=!1}a.forEach((function(e){e.timestamp=i.timestamp,e.seq=t})),n.parent.sampleQueues[i.type].push(a)}},i=0;i<e.byteLength;i+=Kn.PACKET_LENGTH)r(i);this.parsing=!1,this.loadedChunks.length&&this.onTS(this.loadedChunks.shift())}},{key:"sendPause",value:function(){var e=this.parent.options.streamType;if("sdvod"===e){var t={type:"request",seq:0,params:{method:"do",pause:"null"}};this.sendMultiparts(t)}else"dtspk"===e&&this.slpRecorder&&this.slpRecorder.stop();return Promise.resolve()}},{key:"sendPlay",value:function(){var e=this.parent.options.streamType;if("sdvod"===e){var t={type:"request",seq:0,params:{method:"do",play:"null"}};this.sendMultiparts(t)}return Promise.resolve()}},{key:"destroy",value:function(){this.slpRecorder&&(this.slpRecorder.clear(),this.slpRecorder.stop()),this.noisedecoderSlpWorker&&this.noisedecoderSlpWorker.terminate()}}]),n}($r),Jr=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.rtpRecorder=null,r.rtpSequence=0,r.audioEncoder=null,r.noisedecoderNvmpWorker=null,r.hasNoiseNvmpDecoderInit=!1,r.initDecoderWorker(),r.payParser=new Fn,r.rtp_channels=new Set,r.rtpCnt=0,r.audioBuffer=new Uint8Array,r.addState($r.STATE_GET_STREAMS,{activate:r.getStreams,finishTransition:r.onStreamConfigs}).addState($r.STATE_SEND_VOICE,{activate:r.sendRtpVoice,finishTransition:r.onSendRtpVoice}).addTransition($r.STATE_GET_RELAY,$r.STATE_GET_STREAMS).addTransition($r.STATE_PAUSED,$r.STATE_GET_STREAMS).addTransition($r.STATE_GET_STREAMS,$r.STATE_SEND_VOICE).addTransition($r.STATE_SEND_VOICE,$r.STATE_GET_STREAMS).addTransition($r.STATE_GET_STREAMS,$r.STATE_STREAMS).addTransition($r.STATE_GET_STREAMS,$r.STATE_TEARDOWN).addTransition($r.STATE_SEND_VOICE,$r.STATE_TEARDOWN).addTransition($r.STATE_SEND_VOICE,$r.STATE_PAUSED).addTransition($r.STATE_STREAMS,$r.STATE_GET_STREAMS),r.reset(),r}return p(n,[{key:"initDecoderWorker",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.hasNoiseNvmpDecoderInit=!1,e.next=3,Ft();case 3:t=e.sent,n=t.libsWorker,r=t.libaudio,i=t.libaudioWasm,this.noisedecoderNvmpWorker=new Worker(n),this.noisedecoderNvmpWorker.postMessage({cmd:"init",scripts:[r],wasmBinary:i}),this.noisedecoderNvmpWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,r=n.hasInit;r?a.hasNoiseNvmpDecoderInit=!0:a.transformRtpBuffer(n.data,a.audioEncoder)};case 10:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){Vr.log("set source: ",e),this.reset(),this.endpoint=e,this.url="rtsp://192.168.1.1/multitrans"}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&(Vr.log("start"),this.start());case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onData",value:function(e){var t=T(e);if("$"===t[0]){var n=e[1];this.rtp_channels.has(n)&&this.onRTP({packet:e.subarray(4),type:n})}else{var r;Vr.log("on data: ",t);try{r=this.parse(t)}catch(h){return h}if(!r)return;var i,a,o=r,s=o.body,c=void 0===s?{}:s,u=c.params,l=void 0===u?{}:u,f=l.event_type;switch(f){case"stream_finish":this.parent.stop(),a=$r.FINISH_REASON[l.reason],this.error(a||oe.MEDIA_ERR_NETWORK);break;case"channel_preview_params":this.onStreamConfigs(r);break;case"stream_sequence":this.currentSeq=l.sequence;break;case"channel_stream_status":i=l.status&&l.status[0],a=$r.FINISH_REASON[i],"no_data"===i||a&&(this.parent.stop(),this.error(a));break;default:break}}}},{key:"useRTPChannel",value:function(e){this.rtp_channels.add(e)}},{key:"forgetRTPChannel",value:function(e){this.rtp_channels.delete(e)}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.authenticator="",this.methods=[],this.tracks=[],this.rtpBuffer={},this.contentBase="",!this.currentState){e.next=13;break}if(this.currentState.name==$r.STATE_INITIAL){e.next=11;break}return e.next=9,this.transitionTo($r.STATE_TEARDOWN);case 9:return e.next=11,this.transitionTo($r.STATE_INITIAL);case 11:e.next=15;break;case 13:return e.next=15,this.transitionTo($r.STATE_INITIAL);case 15:this.sdp=null,this.interleaveChannelIndex=0,this.session=null,this.timeOffset=0,this.lastTimestamp=0,this.parent.isReconnect=!0,this.cSeq=0,this.receivedSeq=0,this.currentSeq=0,this.dataBuffer=new Uint8Array([]),this.sessionId="";case 26:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"sendRequest",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"RTSP";return Object.assign(r,{CSeq:this.cSeq,"User-Agent":$r.USER_AGENT}),this.cSeq++,this.authenticator&&(r["Authorization"]=this.authenticator(e)),this.send(this.messageBuilder[a].build(e,t,r,i),a).catch((function(a){if(a instanceof qr)return n.sendRequest(e,t,r,i);throw a}))}},{key:"sendMultitrans",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r="MULTITRANS",i={"Content-Type":"application/json"};return this.sessionId&&(i["X-Session-Id"]=this.sessionId),Object.assign(i,n),this.sendRequest(r,this.url,i,e).then((function(e){Vr.log("on multitrans\n",e);var n=e.body,r=void 0===n?{}:n;return t.errorException(r)?null:e}))}},{key:"getRelayRelease",value:function(){var e=this.parent.relayOptions,t=void 0===e?{}:e,n=t.cookie,r=t.token,i=t.relayVersion,a={Host:this.endpoint.location,"User-Agent":"Client=TP-LINK/".concat(i),Cookie:n,"X-token":r,"X-Client-UUID":this.parent.clientUUID,"X-Redirect-Times":this.redirectTime,"X-Client-Model":this.env.os,Accept:"/",Upgrade:"websocket",Connection:"upgrade","Sec-WebSocket-Key":L().split("-").join(""),"Sec-WebSocket-Protocol":"tp-private","Sec-WebSocket-Version":"13"},o="GET",s="",c=this.messageBuilder["HTTP"].build(o,this.endpoint.urlpath,a,s);return this.send(c,"HTTP")}},{key:"onRelayRelease",value:function(e){var t=this,n=e.headers,r=e.code;if(404!==r&&410!==r){if(301===r){var i=n["x-domain"],a=n["x-redirect-cookie"];return this.parent.redirect({domain:i,cookie:a}),void this.redirectTime++}if(this.redirectTime=0,Kr=0,this.parent.isReconnect=!1,101===r)this.transitionTo($r.STATE_GET_STREAMS);else{var o=$r.RESPONSE_ERR_CODE[e.code];this.error(o||oe.CLOUD_ERR_DEV_RELAY)}}else Kr<=Yr?(Kr++,this.reconnectTimer=setTimeout((function(){t.reset(),t.redirectTime?t.parent.play():t.parent.start()}),500)):(Kr=0,this.error(oe.CLOUD_ERR_DEV_RELAY))}},{key:"getStreams",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.started=!0,this.isPlaying=!1,t=this.parent.channel,n=void 0===t?0:t,r={method:"get",talk:{mode:this.parent.options.mode||"aec",channel:n}},i={type:"request",seq:0,params:r},a={"X-Data-Window-Size":Qr},e.abrupt("return",this.sendMultitrans(i,a));case 7:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onStreamConfigs",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,u,l,f,h;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t){e.next=2;break}return e.abrupt("return");case 2:if(n=t.body,r=void 0===n?{}:n,i=r.params,a=void 0===i?{}:i,!this.errorException(r)){e.next=6;break}return e.abrupt("return");case 6:this.sessionId=a["session_id"],this.sdp=new Wn,this.timeOffset=0,this.lastTimestamp=0,o={},o.type="audio",o.port=0,o.proto="",o.fmt=[8],s="G711alaw",o.ptype=w.string_map[s],u=c(o.fmt);try{for(u.s();!(l=u.n()).done;)f=l.value,this.sdp.mediaMap[f]=o}catch(d){u.e(d)}finally{u.f()}this.sdp.media[o.type]=o,this.rtpBuffer[o.fmt[0]]=[],this.useRTPChannel(0),this.useRTPChannel(1),this.useRTPChannel(2),this.parent.sampleQueues[w.H265]=[],this.parent.sampleQueues[w.H264]=[],this.parent.sampleQueues[w.G711A]=[],this.rtpFactory=new Dn(this.sdp),h=this.transport.socket(),h.initDataChannel(),this.transitionTo($r.STATE_SEND_VOICE);case 31:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onSendRtpVoice",value:function(){}},{key:"sendRtpVoice",value:function(){var e=this;Fr.get((function(t){t.rec?(e.parent.sendAudioStream(),e.rtpRecorder=t.rec,e.startRecorder()):e.parent.error(zr[t.error.name])}))}},{key:"startRecorder",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpRecorder.start(),t=new rr["PCMA"](this.parent.audioWasm,Hr),this.audioEncoder=t.encodeA.bind(t),this.rtpRecorder.audioTatch=function(){n.sendRtpData(n.audioEncoder)};case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"sendRtpData",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=new FileReader,r=this,n.onload=function(e){var n=e.target.result,i=2048,a=new Uint8Array([].concat(Le(r.audioBuffer),Le(new Uint8Array(n))));if(a.length>0)for(var o=new Uint8Array(i),s=0,c=0;c<a.byteLength;c++)o[s++]=a[c],(c+1)%i===0&&(r.noiseSet(o,t),o=a.byteLength-c-1>=i?new Uint8Array(i):new Uint8Array(a.byteLength-c-1),s=0),c+1===a.byteLength&&(c+1)%i!==0&&(r.audioBuffer=o)},n.readAsArrayBuffer(this.rtpRecorder.getPcmData());case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"noiseSet",value:function(e,t){var n=t(e);this.noisedecoderNvmpWorker.postMessage({data:n,samplerate:8e3,decoderType:"_decodeG711a"})}},{key:"transformRtpBuffer",value:function(){var e=l(regeneratorRuntime.mark((function e(t,n){var r,i,a,o,s,c,u;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(r=n(t),i=new Uint8Array(r),a=new ArrayBuffer(16+i.length),o=new DataView(a),s=0,o.setUint8(s,36),s+=1,o.setUint8(s,1),s+=1,c=1036,o.setUint16(s,c),s+=2,o.setUint8(s,128),s+=1,o.setUint8(s,136),s+=1,o.setUint16(s,this.rtpCnt),s+=2,o.setUint32(s,320*this.rtpCnt),this.rtpCnt++,s+=4,s+=4,u=0;u<i.length;u++,s+=1)o.setUint8(s,i[u],!0);this.sendRtp(a);case 24:case"end":return e.stop()}}),e,this)})));function t(t,n){return e.apply(this,arguments)}return t}()},{key:"sendRtp",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=a.length>1&&void 0!==a[1]?a[1]:"RTSP",!this.transport){e.next=18;break}return e.prev=2,e.next=5,this.transport.ready;case 5:e.next=11;break;case 7:throw e.prev=7,e.t0=e["catch"](2),this.onDisconnected(),e.t0;case 11:return e.next=13,this.transport.send(t,"rtpVocie");case 13:return r=e.sent,i=this.parse(r,n),e.abrupt("return",i);case 18:return e.abrupt("return",Promise.reject("No transport attached"));case 19:case"end":return e.stop()}}),e,this,[[2,7]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onRTP",value:function(e){var t=this;if(this.rtpFactory){this.isPlaying||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream"));var n=this.rtpFactory.build(e.packet,this.sdp);if(n.type){n.utc_timestamp&&(this.timeOffset=n.timestamp,this.lastTimestamp=n.utc_timestamp,Vr.log(n.pt,this.timeOffset));var r=this.rtpBuffer[n.pt];r.push(n);var i=function(){var e=r.shift();if(e.timestamp=parseInt(1e3*(t.lastTimestamp+(e.timestamp-t.timeOffset/9e4))),e.media){var n=t.payParser.parse(e);if(n&&t.parent.sampleQueues[e.type]){if(t.parent.readyToPlay){var i=!1,a=n[0].ntype;switch(Vr.log("nalu type: ",a,n),e.media.ptype){case w.H264:i=7===a;break;case w.H265:i=32===a;break;default:break}if(!i)return{v:void 0};t.parent.readyToPlay=!1}n.forEach((function(n){n.timestamp=e.timestamp,t.currentSeq&&(n.seq=t.currentSeq,t.currentSeq=0)})),t.parent.sampleQueues[e.type].push(n)}}};while(r.length){var a=i();if("object"===f(a))return a.v}}}}},{key:"destroy",value:function(){this.rtpRecorder&&(this.rtpRecorder.clear(),this.rtpRecorder.stop()),this.noisedecoderNvmpWorker&&this.noisedecoderNvmpWorker.terminate()}}]),n}($r),ei=function(e){Tn(n,e);var t=_n(n);function n(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flush:10};return h(this,n),e=t.call(this,Object.assign({},r)),e.relayUrl="",e.sampleQueues={},e.clientUUID="",e.cloudServer="",e.relayOptions=null,e.relayUrlParse=null,e.clientSM=new $r(fn(e)),e.audioWasm=null,e}return p(n,[{key:"canplay",value:function(e){return $r.SLP.includes(e)||$r.NVMP.includes(e)}},{key:"start",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=this.options.url,r=hr.parse(t),this.cloudServer="".concat(r.protocol,"://").concat(r.location).concat(r.basepath),this.clientUUID=r.query.clientUUID,e.next=6,this.getRelayOptions();case 6:return this.relayOptions=e.sent,this.relayUrlParse=hr.parse(this.relayOptions.url),e.next=10,this.requestRelayAccess();case 10:if(i=this.relayOptions.relayVersion,this.canplay(this.relayOptions.relayVersion)){e.next=14;break}return this.error(oe.CLOUD_ERR_VERSION),e.abrupt("return");case 14:$r.NVMP.includes(i)?this.clientSM=new Jr(this):this.clientSM=new Zr(this),this.clientSM.onRelayConfig=function(e){a.eventSource.dispatchEvent("relayConfig",e),a.startStreamFlush()},this.connect(),pn(hn(n.prototype),"start",this).call(this);case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getRelayOptions",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=function(){return new Promise((function(e){var t=function t(n,i){var a=r.getXAuthHeaders({url:n,param:i});Cr.a.post(n,i,a).then((function(n){var i=n.data,a=void 0===i?{}:i,o=a.result,s=void 0===o?{}:o;if(0===a["error_code"])e(s);else if(-80703===a["error_code"]){var c="".concat(r.cloudServer,"/requestRelayUrlAgain"),u={sessionId:s.sessionId,token:s.token};r.timer=setTimeout((function(){t(c,u)}),500)}else{var l=Gr[a["error_code"]]||"COMMON_ERR_CUSTOM";r.error(oe[l])}})).catch((function(){r.error(oe.MEDIA_ERR_NETWORK)}))},n=r.options.url;t(n,{})}))},e.next=3,t();case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e)})));function t(){return e.apply(this,arguments)}return t}()},{key:"requestRelayAccess",value:function(){var e=this,t=this.cloudServer+"/renewRelayCookie",n={token:this.relayOptions.token,cookie:this.relayOptions.cookie,path:this.relayUrlParse.basepath},r=this.getXAuthHeaders({url:t,param:n});return Cr.a.post(t,n,r).catch((function(){e.error(oe.MEDIA_ERR_NETWORK)}))}},{key:"setSource",value:function(e){pn(hn(n.prototype),"setSource",this).call(this,e),this.clientSM.setSource(e)}},{key:"attachTransport",value:function(e){pn(hn(n.prototype),"attachTransport",this).call(this,e),this.clientSM.transport=e}},{key:"detachTransport",value:function(){pn(hn(n.prototype),"detachTransport",this).call(this),this.clientSM.transport=null}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.reset();case 2:this.sampleQueues={};case 3:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"connect",value:function(){var e=this,t=this.relayOptions.url;this.setSource(hr.parse(t));var n=new Er(this.options.type,{socket:t.replace("https","wss"),binaryType:"blob"});return this.attachTransport(n),this.transport?this.transport.ready.then((function(){return e.clientSM.start()})):Promise.reject("no transport attached")}},{key:"redirect",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=this.relayOptions,r=this.relayUrlParse,n.cookie=t.cookie,n.url="".concat(r.protocol,"://").concat(t.domain).concat(r.urlpath),this.relayUrlParse=hr.parse(n.url),e.next=6,this.requestRelayAccess();case 6:this.play();case 7:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"stop",value:function(){return this.clientSM.stop(),this.transport&&this.transport.disconnect(),clearTimeout(this.timer),pn(hn(n.prototype),"stop",this).call(this)}},{key:"destroy",value:function(){return this.clientSM.destroy(),pn(hn(n.prototype),"destroy",this).call(this)}},{key:"onData",value:function(e){this.clientSM.onData(e)}},{key:"initAudioWasm",value:function(){var e=this;At.a.getItem("audio.wasm").then((function(e){return WebAssembly.instantiate(e,Hr)})).then((function(t){e.audioWasm=t}))}},{key:"startVoiceIntercom",value:function(){var e=l(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.options.url=t,e.next=3,this.initAudioWasm();case 3:this.start();case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"sendRequest",value:function(e){this.clientSM.sendRequest(e)}},{key:"concatenate",value:function(){for(var e=0,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];for(var i=0,a=n;i<a.length;i++){var o=a[i];e+=o.byteLength}for(var s=new Uint8Array(e),c=0,u=0,l=n;u<l.length;u++){var f=l[u],h=new Uint8Array(f);s.set(h,c),c+=f.byteLength}return s}},{key:"onConnected",value:function(){this.clientSM.onConnected(),pn(hn(n.prototype),"onConnected",this).call(this)}},{key:"onDisconnected",value:function(){pn(hn(n.prototype),"onDisconnected",this).call(this),this.clientSM.onDisconnected()}},{key:"error",value:function(e){this.eventSource.dispatchEvent("audioError",new oe(e))}},{key:"sendAudioStream",value:function(){this.eventSource.dispatchEvent("sendAudioStream")}},{key:"onPlayerNotify",value:function(e){var t=e.seq;t&&this.clientSM.updateReceivedSeq(t)}}],[{key:"streamType",value:function(){return"dtspk"}},{key:"resolutions",get:function(){return{VGA:0,HD:2}}}]),n}(Nr),ti=ei;n("c740");Cr.a.defaults.withCredentials=!0;var ni=re("client:relay"),ri=function(e){Tn(n,e);var t=_n(n);function n(e){return h(this,n),t.call(this,e)}return p(n)}(An(Error)),ii={"-82400":"CLOUD_ERR_PARAM","-82401":"CLOUD_ERR_PERMISSION","-82414":"CLOUD_ERR_SERVER","-80702":"COMMON_ERR_SESSION","-80731":"CLOUD_ERR_TOKEN","-80304":"CLOUD_ERR_DEVID","-80732":"CLOUD_ERR_BANDWIDTH","-20002":"DEVICE_ERR_CHN_OFFLINE","-20571":"DEVICE_ERR_CHN_OFFLINE","-52405":"CLOUD_ERR_STREAM_LIMIT","-52413":"DEVICE_ERR_CHN_OFFLINE"},ai=5,oi=0,si="sdk-client-boundary",ci=100,ui=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this),r.parent=e,r.transport=null,r.onRelayConfig=null,r.streams=null,r.env=_r(),r.messageBuilder={RTSP:new jr(jr.RTSP_1_0),HTTP:new jr(jr.HTTP_1_1)},r.isPlaying=!1,r.methods=["PLAY","PAUSE"],r.reconnectTimer=0,r.redirectTime=0,r.addState(n.STATE_INITIAL,{}).addState(n.STATE_GET_RELAY,{activate:r.getRelayRelease,finishTransition:r.onRelayRelease}).addState(n.STATE_OPTIONS,{activate:r.sendOptions,finishTransition:r.onOptions}).addState(n.STATE_STREAMS,{}).addState(n.STATE_TEARDOWN,{activate:function(){r.started=!1},finishTransition:function(){return r.transitionTo(n.STATE_INITIAL)}}).addState(n.STATE_PAUSED,{activate:r.sendPause,finishTransition:r.onPause}).addState(n.STATE_PLAY,{activate:r.sendPlay,finishTransition:r.onPlay}).addTransition(n.STATE_INITIAL,n.STATE_GET_RELAY).addTransition(n.STATE_INITIAL,n.STATE_TEARDOWN).addTransition(n.STATE_GET_RELAY,n.STATE_TEARDOWN).addTransition(n.STATE_STREAMS,n.STATE_PAUSED).addTransition(n.STATE_PAUSED,n.STATE_STREAMS).addTransition(n.STATE_STREAMS,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_PLAY).addTransition(n.STATE_PLAY,n.STATE_STREAMS).addTransition(n.STATE_PLAY,n.STATE_TEARDOWN).addTransition(n.STATE_TEARDOWN,n.STATE_INITIAL),r}return p(n,[{key:"destroy",value:function(){clearTimeout(this.reconnectTimer)}},{key:"setSource",value:function(){}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&(ni.log("start"),this.start());case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onDisconnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.reset(),this.shouldReconnect=!0,e.next=4,this.transitionTo(n.STATE_TEARDOWN);case 4:return e.next=6,this.transitionTo(n.STATE_INITIAL);case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){return this.currentState.name!==n.STATE_STREAMS?this.transitionTo(n.STATE_GET_RELAY):Promise.resolve()}},{key:"stop",value:function(){this.started&&(this.transitionTo(n.STATE_TEARDOWN),this.transport&&this.transport.stop()),this.shouldReconnect=!1}},{key:"error",value:function(e){this.parent.error(e)}},{key:"onData",value:function(){}},{key:"reset",value:function(){}},{key:"reconnect",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.reset();case 2:if(this.currentState.name==n.STATE_INITIAL){e.next=8;break}return e.next=5,this.transitionTo(n.STATE_TEARDOWN);case 5:return e.abrupt("return",this.transitionTo(n.STATE_GET_RELAY));case 8:return e.abrupt("return",this.transitionTo(n.STATE_GET_RELAY));case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"supports",value:function(e){return this.methods.includes(e)}},{key:"sendRequest",value:function(){}},{key:"send",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=a.length>1&&void 0!==a[1]?a[1]:"RTSP",!this.transport){e.next=18;break}return e.prev=2,e.next=5,this.transport.ready;case 5:e.next=11;break;case 7:throw e.prev=7,e.t0=e["catch"](2),this.onDisconnected(),e.t0;case 11:return e.next=13,this.transport.send(t);case 13:return r=e.sent,i=this.parse(r,n),e.abrupt("return",i);case 18:return e.abrupt("return",Promise.reject("No transport attached"));case 19:case"end":return e.stop()}}),e,this,[[2,7]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parse",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RTSP",n=e.split("\r\n\r\n"),r={};try{r=this.messageBuilder[t].parse(n[0]);var i=Number(r.headers["content-length"]||0);if(i){var a=n[1];a&&(a=JSON.parse(a)),r.body=a}else r.body=""}catch(o){}return ni.log("parsed data: ",r),r}},{key:"sendTeardown",value:function(){var e="TEARDOWN";return this.sendRequest(e,"*")}},{key:"sendOptions",value:function(){return this.reset(),this.started=!0,this.cSeq=0,this.sendRequest("OPTIONS",this.url,{})}},{key:"onOptions",value:function(e){this.methods=e.headers["public"].split(",").map((function(e){return e.trim()})),this.transitionTo(n.STATE_GET_STREAMS)}},{key:"pause",value:function(){return this.currentState.name===n.STATE_STREAMS?(this.isPlaying=!1,this.transitionTo(n.STATE_PAUSED)):Promise.resolve()}},{key:"sendPause",value:function(){}},{key:"onPause",value:function(){}},{key:"play",value:function(){return this.currentState.name===n.STATE_PAUSED?this.transitionTo(n.STATE_PLAY):Promise.resolve()}},{key:"sendPlay",value:function(){}},{key:"onPlay",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"errorException",value:function(e){var t=e.type,r=e.params,i=void 0===r?{}:r;if("response"===t&&0!==i["error_code"]){var a=ii[i["error_code"]]||"CLOUD_ERR_STREAM";return this.error(oe[a]),this.transitionTo(n.STATE_TEARDOWN),!0}return!1}},{key:"updateReceivedSeq",value:function(){}}],[{key:"USER_AGENT",get:function(){return"SFRtsp 0.3"}},{key:"SLP",get:function(){return["1.3"]}},{key:"NVMP",get:function(){return["2.0"]}},{key:"RESPONSE_ERR_CODE",get:function(){return{429:oe.CLOUD_ERR_STREAM_LIMIT,432:oe.CLOUD_ERR_WINDOW_LIMIT,433:oe.CLOUD_ERR_CLIENT_LIMIT}}},{key:"FINISH_REASON",get:function(){return{share_finish:oe.CLOUD_ERR_SHARE_FINISH,permission_deny:oe.CLOUD_ERR_PERMISSION,channel_offline:oe.DEVICE_ERR_CHN_OFFLINE,channel_invalid:oe.DEVICE_ERR_CHN_INVALID,internal_error:oe.COMMON_ERR_INTERNAL,password_changed:oe.DEVICE_ERR_PWD_CHANGED,media_encrypt_changed:oe.CLOUD_ERR_ENCRYPT_CHANGED,relay_lifetime_expired:oe.CLOUD_ERR_FREE,channel_talk_busy:oe.CLOUD_ERR_TALK_BUSY,unbind_device:oe.CLOUD_ERR_UNBIND,lack_bandwidth:oe.CLOUD_ERR_BANDWIDTH,offline:oe.DEVICE_ERR_CHN_OFFLINE}}},{key:"STATE_INITIAL",get:function(){return 1}},{key:"STATE_OPTIONS",get:function(){return 2}},{key:"STATE_GET_RELAY",get:function(){return 4}},{key:"STATE_GET_STREAMS",get:function(){return 8}},{key:"STATE_STREAMS",get:function(){return 16}},{key:"STATE_TEARDOWN",get:function(){return 32}},{key:"STATE_PAUSED",get:function(){return 64}},{key:"STATE_PLAY",get:function(){return 128}}]),n}(Rr),li=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.payParser=new Fn,r.rtp_channels=new Set,r.addState(ui.STATE_GET_STREAMS,{activate:r.getStreams,finishTransition:r.onStreamConfigs}).addTransition(ui.STATE_GET_RELAY,ui.STATE_GET_STREAMS).addTransition(ui.STATE_PAUSED,ui.STATE_GET_STREAMS).addTransition(ui.STATE_GET_STREAMS,ui.STATE_STREAMS).addTransition(ui.STATE_GET_STREAMS,ui.STATE_TEARDOWN).addTransition(ui.STATE_STREAMS,ui.STATE_GET_STREAMS),r.reset(),r}return p(n,[{key:"setSource",value:function(e){ni.log("set source: ",e),this.reset(),this.endpoint=e,this.url="rtsp://192.168.1.1/multitrans"}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&(ni.log("start"),this.start());case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onData",value:function(e){var t=this;if("sdvod"===this.parent.options.streamType){var n=m(this.dataBuffer,e),r=new DataView(n.buffer,n.byteOffset,n.byteLength),i=r.getUint8(0);if(36===i){if(!(r.buffer.byteLength>=4))return void(this.dataBuffer=n);var a=r.getUint16(2),o=a+4;if(!(n.length>=o))return void(this.dataBuffer=n);e=n.slice(0,o),this.dataBuffer=n.slice(o)}else{var s=n.findIndex((function(e){return 36===e}));-1!==s?(e=n.slice(0,s),this.dataBuffer=n.slice(s)):(e=n,this.dataBuffer=new Uint8Array([]))}}var c=T(e);if("$"===c[0]){this.noDataTimeout&&clearTimeout(this.noDataTimeout);var u=e[1];this.rtp_channels.has(u)&&this.onRTP({packet:e.subarray(4),type:u}),c=T(this.dataBuffer),"$"!==c[0]&&0!==c.indexOf("RTSP")||this.onData(new Uint8Array([]))}else{var l;ni.log("on data: ",c);try{l=this.parse(c)}catch(S){return S}if(!l)return;var f,h,d=l,p=d.body,v=void 0===p?{}:p,y=v.params,g=void 0===y?{}:y,b=g.event_type;switch(b){case"stream_finish":this.parent.stop(),h=ui.FINISH_REASON[g.reason],this.error(h||oe.MEDIA_ERR_NETWORK);break;case"channel_preview_params":this.onStreamConfigs(l);break;case"stream_sequence":this.currentSeq=parseInt(g.sequence);break;case"channel_stream_status":f=g.status&&g.status[0],h=ui.FINISH_REASON[f],h?(this.parent.stop(),this.error(h)):"no_data"===f&&(this.noDataTimeout=setTimeout((function(){t.parent.eventSource.dispatchEvent("ended"),t.parent.stop()}),1500));break;case"stream_status":f=g.status,"finished"===f&&(this.parent.eventSource.dispatchEvent("ended"),this.parent.stop());default:break}}}},{key:"useRTPChannel",value:function(e){this.rtp_channels.add(e)}},{key:"forgetRTPChannel",value:function(e){this.rtp_channels.delete(e)}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.authenticator="",this.methods=[],this.tracks=[],this.rtpBuffer={},this.contentBase="",!this.currentState){e.next=13;break}if(this.currentState.name==ui.STATE_INITIAL){e.next=11;break}return e.next=9,this.transitionTo(ui.STATE_TEARDOWN);case 9:return e.next=11,this.transitionTo(ui.STATE_INITIAL);case 11:e.next=15;break;case 13:return e.next=15,this.transitionTo(ui.STATE_INITIAL);case 15:this.sdp=null,this.interleaveChannelIndex=0,this.session=null,this.timeOffset={},this.lastTimestamp=0,this.parent.isReconnect=!0,this.cSeq=0,this.receivedSeq=0,this.currentSeq=0,this.dataBuffer=new Uint8Array([]),this.sessionId="";case 26:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"sendRequest",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"RTSP";return Object.assign(r,{CSeq:this.cSeq,"User-Agent":ui.USER_AGENT}),this.cSeq++,this.authenticator&&(r["Authorization"]=this.authenticator(e)),this.send(this.messageBuilder[a].build(e,t,r,i),a).catch((function(a){if(a instanceof ri)return n.sendRequest(e,t,r,i);throw a}))}},{key:"sendMultitrans",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r="MULTITRANS",i={"Content-Type":"application/json"};return this.sessionId&&(i["X-Session-Id"]=this.sessionId),Object.assign(i,n),this.sendRequest(r,this.url,i,e).then((function(e){ni.log("on multitrans\n",e);var n=e.body,r=void 0===n?{}:n;return t.errorException(r)?null:e}))}},{key:"getRelayRelease",value:function(){var e=this.parent.relayOptions,t=void 0===e?{}:e,n=t.cookie,r=t.token,i=t.relayVersion,a={Host:this.endpoint.location,"User-Agent":"Client=TP-LINK/".concat(i),Cookie:n,"X-token":r,"X-Client-UUID":this.parent.clientUUID,"X-Redirect-Times":this.redirectTime,"X-Client-Model":this.env.os,Accept:"/",Upgrade:"websocket",Connection:"upgrade","Sec-WebSocket-Key":L().split("-").join(""),"Sec-WebSocket-Protocol":"tp-private","Sec-WebSocket-Version":"13"},o="GET",s="",c=this.messageBuilder["HTTP"].build(o,this.endpoint.urlpath,a,s);return this.send(c,"HTTP")}},{key:"onRelayRelease",value:function(e){var t=this,n=e.headers,r=e.code;if(404!==r&&410!==r){if(301===r){var i=n["x-domain"],a=n["x-redirect-cookie"];return this.parent.redirect({domain:i,cookie:a}),void this.redirectTime++}if(this.redirectTime=0,oi=0,this.parent.isReconnect=!1,101===r)this.transitionTo(ui.STATE_GET_STREAMS);else{var o=ui.RESPONSE_ERR_CODE[e.code];this.error(o||oe.CLOUD_ERR_DEV_RELAY)}}else oi<=ai?(oi++,this.reconnectTimer=setTimeout((function(){t.reset(),t.redirectTime?t.parent.play():t.parent.start()}),500)):(oi=0,this.error(oe.CLOUD_ERR_DEV_RELAY))}},{key:"getStreams",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a,o,s,c,u,l,f,h,d,p,v,m;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.started=!0,this.isPlaying=!1,t=this.parent,n=t.options,r=void 0===n?{}:n,i=t.channel,a=void 0===i?0:i,o=r.streamType,s=r.startTime,c=r.scale,u=r.eventType,l=r.audioVoiceEnable,f=l?"enable":"disable",h={method:"get",preview:{audio:[f],channels:[a],resolutions:[this.endpoint.query.resolution]}},d=c<0?"-":"",p={method:"get",playback:{client_id:this.parent.options.userId,channels:[a],scale:d+Nr.formatScale(c),event_type:u,start_time:parseInt(s/1e3)+""}},v={type:"request",seq:0,params:"video"===o?h:p},m={"X-Data-Window-Size":ci},e.abrupt("return",this.sendMultitrans(v,m));case 11:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onStreamConfigs",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,u,l,f,h,d,p,v,m;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t){e.next=2;break}return e.abrupt("return");case 2:if(n=t.body,r=void 0===n?{}:n,i=r.params,a=void 0===i?{}:i,!this.errorException(r)){e.next=6;break}return e.abrupt("return");case 6:this.sessionId=a["session_id"],this.sdp=new Wn,o=a["av_config"][0],s={},u={},s.type="video",s.port=0,s.proto="",s.fmt=[96],s.ptype=w.string_map[o.video_codec],l=c(s.fmt);try{for(l.s();!(f=l.n()).done;)h=f.value,this.sdp.mediaMap[h]=s}catch(y){l.e(y)}finally{l.f()}this.sdp.media[s.type]=s,u.type="audio",u.port=0,u.proto="",u.fmt=[parseInt(o.audio_sampling_rate)],u.ptype=w.string_map[o.audio_codec],d=c(u.fmt);try{for(d.s();!(p=d.n()).done;)v=p.value,this.sdp.mediaMap[v]=u}catch(y){d.e(y)}finally{d.f()}this.sdp.media[u.type]=u,this.timeOffset={},this.lastTimestamp=0,this.useRTPChannel(0),this.useRTPChannel(1),this.useRTPChannel(2),this.rtpBuffer[s.fmt[0]]=[],this.rtpBuffer[u.fmt[0]]=[],this.parent.sampleQueues[w.H265]=[],this.parent.sampleQueues[w.H264]=[],this.parent.sampleQueues[w.G711A]=[],this.rtpFactory=new Dn(this.sdp),m=this.transport.socket(),m.initDataChannel(),this.transitionTo(ui.STATE_STREAMS),this.onRelayConfig&&this.onRelayConfig(o);case 42:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onRTP",value:function(e){var t=this;if(this.rtpFactory){this.isPlaying||this.currentState.name===ui.STATE_PAUSED||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream"));var n=this.rtpFactory.build(e.packet,this.sdp);if(n.type){n.utc_timestamp&&(this.timeOffset={},this.timeOffset[n.pt]=n.timestamp,this.lastTimestamp=n.utc_timestamp),this.timeOffset[n.pt]||(this.timeOffset[n.pt]=n.timestamp),this.timeOffset[n.pt]&&(n.timestamp-this.timeOffset[n.pt]<0||n.timestamp-this.timeOffset[n.pt]>9e5)&&(this.timeOffset[n.pt]=n.timestamp);var r=this.rtpBuffer[n.pt];r.push(n);var i=function(){var e=r.shift(),n=8===e.pt?8e3:9e4,i=parseInt(1e3*(t.lastTimestamp+(e.timestamp-t.timeOffset[e.pt])/n));if(e.media){var a=t.payParser.parse(e);a&&t.parent.sampleQueues[e.type]&&(a.forEach((function(n){n.timestamp=i,e.isVideo()&&(n.seq=t.currentSeq,t.currentSeq=0)})),t.parent.feed(e.type,a))}};while(r.length)i()}}}},{key:"sendPlaybackConfig",value:function(e){var t=e.startTime,n=e.endTime,r=e.scale,i=e.eventType,a=e.currentTime,o=r<0?"-":"",s={type:"request",seq:0,params:{method:"do",play:{start_time:t?parseInt(t/1e3)+"":void 0,end_time:n?parseInt(n/1e3)+"":void 0,scale:r?o+Nr.formatScale(r):void 0,event_type:i}}};return i?(this.parent.options.startTime=t||a,this.getStreams()):this.sendMultitrans(s),this.currentState.name===ui.STATE_PAUSED?(this.currentSeq&&this.updateReceivedSeq(this.currentSeq),this.transitionTo(ui.STATE_STREAMS)):Promise.resolve()}},{key:"sendPause",value:function(){return Promise.resolve()}},{key:"sendPlay",value:function(){return Promise.resolve()}},{key:"sendHeartbeat",value:function(){var e={type:"notification"};this.sendMultitrans(e)}},{key:"updateReceivedSeq",value:function(e){e=parseInt(e);var t={type:"notification",params:{event_type:"stream_sequence"}},n={"X-Data-Received":e};this.sendMultitrans(t,n),this.receivedSeq=e}}]),n}(ui),fi=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.addTransition(ui.STATE_GET_RELAY,ui.STATE_STREAMS),r.reset(),r.isChangeSampleRate=!1,r}return p(n,[{key:"setSource",value:function(e){ni.log("set source: ",e),this.reset(),this.endpoint=e}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.shouldReconnect&&(ni.log("start"),this.start());case 1:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.deviceBoundary="",this.sessionId="",this.loadedChunks=[],this.parsing=!1,this.cSeq=0,this.payload={},this.currentSeq=0,this.receivedSeq=0,this.initParser(),!this.currentState){e.next=17;break}if(this.currentState.name==ui.STATE_INITIAL){e.next=15;break}return e.next=13,this.transitionTo(ui.STATE_TEARDOWN);case 13:return e.next=15,this.transitionTo(ui.STATE_INITIAL);case 15:e.next=19;break;case 17:return e.next=19,this.transitionTo(ui.STATE_INITIAL);case 19:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"initParser",value:function(){var e=this;this.parser=new Kn,this.parser.addPesParser(Yn.H264,Xn),this.parser.addPesParser(Yn.H265,Xn),this.parser.addPesParser(Yn.AAC,Qn),this.parser.addPesParser(Yn.PCMA_W,Zn),this.parser.addPesParser(Yn.PCMA,$n),this.parser.ontracks=function(t){var n,r={},i=c(t);try{for(i.s();!(n=i.n()).done;){var a=n.value;switch(e.parent.sampleQueues[a.type]=[],a.type){case w.H264:r.video_codec="H264";break;case w.H265:r.video_codec="H265";break;case w.G711A:r.audio_codec="G711alaw";break;case w.AAC:r.audio_codec="AAC";break;case w.PCMA_W:r.audio_codec="PCMA_W";break;default:break}}}catch(o){i.e(o)}finally{i.f()}r.video_codec&&e.onRelayConfig(r)}}},{key:"buildBoundary",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n="--".concat(si,"\r\n");return e instanceof Object&&(e=JSON.stringify(e)),n+="Content-Type: application/json\r\n",n+="Content-Length: ".concat(e.length,"\r\n"),this.sessionId&&(n+="X-Session-Id: ".concat(this.sessionId,"\r\n")),t&&(n+=t),n+="\r\n",n+=e,n}},{key:"sendBoundary",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=17;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t);case 12:return n=e.sent,r=this.parseBoundary(n),e.abrupt("return",r);case 17:return e.abrupt("return",Promise.reject("No transport attached"));case 18:case"end":return e.stop()}}),e,this,[[1,6]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parseBoundary",value:function(e){var t=e.split("\r\n\r\n"),n=gn(t,2),r=n[0],i=n[1],a={headers:{},body:i},o=r.split("\r\n");if(-1===o[0].indexOf(this.deviceBoundary))a.body=e;else{var s=1;while(o[s]){var c=o[s].split(/:(.+)/),u=gn(c,2),l=u[0],f=u[1];a.headers[l.toLowerCase()]=f.trim(),s++}}return a}},{key:"onData",value:function(e){var t=this,n=T(e),r=this.parseBoundary(n),i=r.headers,a=r.body;if("application/json"===i["content-type"]){ni.log("on data: ",a),a=JSON.parse(a);var o=a,s=o.params,c=void 0===s?{}:s,u=c.error_code,l=void 0===u?0:u;if(l){var f=ii[l]||"CLOUD_ERR_STREAM";return this.error(oe[f]),void this.transitionTo(ui.STATE_TEARDOWN)}if(c.session_id&&(this.sessionId=c.session_id),"stream_finish"===c.event_type){this.parent.stop();var h=ui.FINISH_REASON[c.reason];this.error(h||oe.MEDIA_ERR_NETWORK)}else if("channel_stream_status"===c.event_type){var d=c.status&&c.status[0],p=ui.FINISH_REASON[d];p?(this.parent.stop(),this.error(p)):"no_data"===d&&(this.noDataTimeout=setTimeout((function(){t.parent.eventSource.dispatchEvent("ended"),t.parent.stop()}),1500))}else if("stream_status"===c.event_type){var v=c.status;"finished"===v&&(clearTimeout(this.noDataTimeout),this.parent.eventSource.dispatchEvent("ended"),this.parent.stop())}}else{this.noDataTimeout&&clearTimeout(this.noDataTimeout);for(var m=[],y=0;y<a.length;y++)m.push(a.charCodeAt(y));this.currentSeq=parseInt(i["x-data-sequence"]),this.onTS(new Uint8Array(m))}}},{key:"getRelayRelease",value:function(){this.sessionId="";var e=this.parent,t=e.options,n=void 0===t?{}:t,r=e.relayOptions,i=void 0===r?{}:r,a=e.channel,o=void 0===a?0:a,s=e.clientUUID,c=n.streamType,u=n.startTime,l=n.scale,f=n.eventType,h=n.userId,d=n.audioVoiceEnable,p=i.cookie,v=i.token,m=i.relayVersion,y="POST",g={Host:this.endpoint.location,"User-Agent":"Client=TP-LINK/".concat(m),Cookie:p,"X-token":v,"X-Client-UUID":s,"X-Redirect-Times":this.redirectTime,"X-Client-Model":this.env.os,Accept:"/","Content-Type":"multipart/mixed; boundary=".concat(si),"Content-Length":Number.MAX_SAFE_INTEGER},b=d?"enable":"disable",T={method:"get",preview:{audio:[b],channels:[o],resolutions:[this.endpoint.query.resolution]}},S=l<0?"-":"",E={method:"get",playback:{client_id:h,channels:[o],scale:S+Nr.formatScale(l),event_type:f,start_time:parseInt(u/1e3)+""}},_={type:"request",seq:0,params:"video"===c?T:E},k="sdvod"===c?"X-Data-Window-Size: ".concat(ci,"\r\n"):"",w=this.messageBuilder["HTTP"].build(y,this.endpoint.urlpath,g,null);return w+=this.buildBoundary(_,k),this.send(w,"HTTP")}},{key:"onRelayRelease",value:function(e){var t=this,n=e.headers,r=e.code;if(404!==r&&410!==r){if(301===r){var i=n["x-domain"],a=n["x-redirect-cookie"];return this.parent.redirect({domain:i,cookie:a}),void this.redirectTime++}if(this.redirectTime=0,oi=0,this.parent.isReconnect=!1,200===r){this.deviceBoundary=n["content-type"].split("boundary=")[1];var o=this.transport.socket();o.initDataChannel(),this.transitionTo(ui.STATE_STREAMS)}else{var s=ui.RESPONSE_ERR_CODE[e.code];this.error(s||oe.CLOUD_ERR_DEV_RELAY)}}else oi<=ai?(oi++,this.reconnectTimer=setTimeout((function(){t.reset(),t.redirectTime?t.parent.play():t.parent.start()}),500)):(oi=0,this.error(oe.CLOUD_ERR_DEV_RELAY))}},{key:"sendMultiparts",value:function(e,t){var n=this,r=this.buildBoundary(e,t);return this.sendBoundary(r).then((function(e){ni.log("on multiparts\n",e);var t=e.body,r=void 0===t?"{}":t;r=JSON.parse(r);var i=r,a=i.params,o=void 0===a?{}:a;return n.errorException(r)?null:(o.session_id&&(n.sessionId=o.session_id),e)}))}},{key:"onTS",value:function(e){this.isPlaying||this.currentState.name===ui.STATE_PAUSED||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream")),this.parsing?this.loadedChunks.push(e):(this.parsing=!0,this.parseTS(e))}},{key:"parseTS",value:function(e){for(var t=this,n=function(n){var r=t.parser.parse(e.subarray(n,n+Kn.PACKET_LENGTH));if(r&&t.parent.sampleQueues[r.type]){var i=r.units;i.forEach((function(e){e.timestamp=r.timestamp,e.seq=t.currentSeq})),t.parent.feed(r.type,i)}},r=0;r<e.byteLength;r+=Kn.PACKET_LENGTH)n(r);this.parsing=!1,this.loadedChunks.length&&this.onTS(this.loadedChunks.shift())}},{key:"sendPlaybackConfig",value:function(e){var t=e.startTime,n=e.endTime,r=e.scale,i=e.eventType,a=r<0?"-":"",o={type:"request",seq:0,params:{method:"do",play:{start_time:t?parseInt(t/1e3)+"":void 0,end_time:n?parseInt(n/1e3)+"":void 0,scale:r?a+Nr.formatScale(r):void 0,event_type:i}}};return this.sendMultiparts(o),this.currentState.name===ui.STATE_PAUSED?(this.currentSeq&&this.updateReceivedSeq(this.currentSeq),this.transitionTo(ui.STATE_STREAMS)):Promise.resolve()}},{key:"sendPause",value:function(){return Promise.resolve()}},{key:"sendPlay",value:function(){return Promise.resolve()}},{key:"sendHeartbeat",value:function(){var e={type:"notification"};this.sendMultiparts(e)}},{key:"updateReceivedSeq",value:function(e){if(!(this.currentState.name!==ui.STATE_STREAMS||e>this.currentSeq)&&(e=parseInt(e),e-this.receivedSeq>=ci/2)){var t={type:"notification",params:{event_type:"stream_sequence"}},n="X-Data-Received: ".concat(e,"\r\n");this.sendMultiparts(t,n),this.receivedSeq=e}}}]),n}(ui),hi=function(e){Tn(n,e);var t=_n(n);function n(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flush:10};return h(this,n),e=t.call(this,Object.assign({},r)),e.relayUrl="",e.sampleQueues={},e.clientUUID="",e.cloudServer="",e.relayOptions=null,e.relayUrlParse=null,e.heartbeatInterval=0,e.clientSM=new ui(fn(e)),e}return p(n,[{key:"canplay",value:function(e){return ui.SLP.includes(e)||ui.NVMP.includes(e)}},{key:"start",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=this.options.url,r=hr.parse(t),this.cloudServer="".concat(r.protocol,"://").concat(r.location).concat(r.basepath),e.next=5,this.getRelayOptions();case 5:return this.relayOptions=e.sent,this.clientUUID=this.relayOptions.clientUUID,this.relayUrlParse=hr.parse(this.relayOptions.url),e.next=10,this.requestRelayAccess();case 10:if(i=this.relayOptions.relayVersion,this.canplay(this.relayOptions.relayVersion)){e.next=14;break}return this.error(oe.CLOUD_ERR_VERSION),e.abrupt("return");case 14:ui.NVMP.includes(i)?this.clientSM=new li(this):this.clientSM=new fi(this),this.clientSM.onRelayConfig=function(e){a.eventSource.dispatchEvent("relayConfig",e),a.startStreamFlush()},this.connect(),pn(hn(n.prototype),"start",this).call(this);case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getRelayOptions",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=function(){return new Promise((function(e){var t=function t(n,i){var a=r.getXAuthHeaders({url:n,param:i});Cr.a.post(n,i,a).then((function(n){var i=n.data,a=void 0===i?{}:i,o=a.result,s=void 0===o?{}:o;if(0===a["error_code"])e(s);else if(-80703===a["error_code"]){var c="".concat(r.cloudServer,"/requestRelayUrlAgain"),u={sessionId:s.sessionId,token:s.token};r.timer=setTimeout((function(){t(c,u)}),500)}else{var l=ii[a["error_code"]]||"COMMON_ERR_CUSTOM";r.error(oe[l])}})).catch((function(){r.error(oe.MEDIA_ERR_NETWORK)}))},n=r.options.url;t(n,{})}))},e.next=3,t();case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e)})));function t(){return e.apply(this,arguments)}return t}()},{key:"requestRelayAccess",value:function(){var e=this,t=this.cloudServer+"/renewRelayCookie",n={token:this.relayOptions.token,cookie:this.relayOptions.cookie,path:this.relayUrlParse.basepath},r=this.getXAuthHeaders({url:t,param:n});return Cr.a.post(t,n,r).catch((function(){e.error(oe.MEDIA_ERR_NETWORK)}))}},{key:"setSource",value:function(e){pn(hn(n.prototype),"setSource",this).call(this,e),this.clientSM.setSource(e)}},{key:"attachTransport",value:function(e){pn(hn(n.prototype),"attachTransport",this).call(this,e),this.clientSM.transport=e}},{key:"detachTransport",value:function(){pn(hn(n.prototype),"detachTransport",this).call(this),this.clientSM.transport=null}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.reset();case 2:this.sampleQueues={},this.paused=!1,clearInterval(this.heartbeatInterval);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"connect",value:function(){var e=this,t=this.relayOptions.url;this.setSource(hr.parse(t));var n=new Er(this.options.type,{socket:t.replace("https","wss"),binaryType:"blob"});return this.attachTransport(n),this.transport?this.transport.ready.then((function(){return e.clientSM.start()})):Promise.reject("no transport attached")}},{key:"redirect",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var r,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=this.relayOptions,i=this.relayUrlParse,r.cookie=t.cookie,r.url="".concat(i.protocol,"://").concat(t.domain).concat(i.urlpath),this.relayUrlParse=hr.parse(r.url),e.next=6,this.requestRelayAccess();case 6:this.connect(),pn(hn(n.prototype),"start",this).call(this);case 8:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"stop",value:function(){return this.clientSM.stop(),this.transport&&this.transport.disconnect(),clearTimeout(this.timer),pn(hn(n.prototype),"stop",this).call(this)}},{key:"destroy",value:function(){return this.clientSM.destroy(),clearInterval(this.heartbeatInterval),pn(hn(n.prototype),"destroy",this).call(this)}},{key:"play",value:function(e){var t=this;this.clientSM.play().then((function(){t.paused=!1,e&&e(),clearInterval(t.heartbeatInterval)}))}},{key:"pause",value:function(e){var t=this,r=this.clientSM.currentState;if(r&&r.name===ui.STATE_STREAMS){var i=this.options.streamType;"video"===i?(this.clientSM.pause(),pn(hn(n.prototype),"stop",this).call(this),e&&e()):this.clientSM.pause().then((function(){pn(hn(n.prototype),"stop",t).call(t),e&&e(),t.heartbeatInterval=setInterval((function(){t.clientSM.sendHeartbeat()}),5e3)}))}}},{key:"setResolution",value:function(e){var t=this.clientSM.currentState;!t||t.name<=ui.STATE_GET_RELAY||(this.detachTransport(),this.options.url=e,this.start())}},{key:"onData",value:function(){var e=l(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("reconnect"!==t){e.next=6;break}return e.next=3,this.clientSM.onDisconnected();case 3:return clearInterval(this.heartbeatInterval),this.clientSM.start(),e.abrupt("return");case 6:this.clientSM.onData(t);case 7:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onConnected",value:function(){this.clientSM.onConnected(),pn(hn(n.prototype),"onConnected",this).call(this)}},{key:"onDisconnected",value:function(){pn(hn(n.prototype),"onDisconnected",this).call(this),this.clientSM.onDisconnected(),clearInterval(this.heartbeatInterval)}},{key:"error",value:function(e){this.eventSource.dispatchEvent("error",new oe(e))}},{key:"setPlaybackConfig",value:function(e){var t=this;Object.assign(this.options,e);var n=this.relayOptions.relayVersion;return e.eventType&&ui.SLP.includes(n)?(this.options.startTime=e.startTime||e.currentTime,this.reset(),this.start()):this.clientSM.sendPlaybackConfig(e).then((function(){for(var e in t.paused=!1,clearInterval(t.heartbeatInterval),t.sampleQueues)t.sampleQueues[e]=[]}))}},{key:"onPlayerNotify",value:function(e){var t=e.seq,n=this.options.streamType;t&&"sdvod"===n&&this.clientSM.updateReceivedSeq(t)}}],[{key:"streamType",value:function(){return"relay"}},{key:"resolutions",get:function(){return{VGA:0,HD:2}}}]),n}(Nr),di=hi;function pi(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n}function vi(e,t){return e<<t|e>>>32-t}function mi(e,t,n,r,i,a){return pi(vi(pi(pi(t,e),pi(r,a)),i),n)}function yi(e,t,n,r,i,a,o){return mi(t&n|~t&r,e,t,i,a,o)}function gi(e,t,n,r,i,a,o){return mi(t&r|n&~r,e,t,i,a,o)}function bi(e,t,n,r,i,a,o){return mi(t^n^r,e,t,i,a,o)}function Ti(e,t,n,r,i,a,o){return mi(n^(t|~r),e,t,i,a,o)}function Si(e,t){var n,r,i,a,o;e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;var s=1732584193,c=-271733879,u=-1732584194,l=271733878;for(n=0;n<e.length;n+=16)r=s,i=c,a=u,o=l,s=yi(s,c,u,l,e[n],7,-680876936),l=yi(l,s,c,u,e[n+1],12,-389564586),u=yi(u,l,s,c,e[n+2],17,606105819),c=yi(c,u,l,s,e[n+3],22,-1044525330),s=yi(s,c,u,l,e[n+4],7,-176418897),l=yi(l,s,c,u,e[n+5],12,1200080426),u=yi(u,l,s,c,e[n+6],17,-1473231341),c=yi(c,u,l,s,e[n+7],22,-45705983),s=yi(s,c,u,l,e[n+8],7,1770035416),l=yi(l,s,c,u,e[n+9],12,-1958414417),u=yi(u,l,s,c,e[n+10],17,-42063),c=yi(c,u,l,s,e[n+11],22,-1990404162),s=yi(s,c,u,l,e[n+12],7,1804603682),l=yi(l,s,c,u,e[n+13],12,-40341101),u=yi(u,l,s,c,e[n+14],17,-1502002290),c=yi(c,u,l,s,e[n+15],22,1236535329),s=gi(s,c,u,l,e[n+1],5,-165796510),l=gi(l,s,c,u,e[n+6],9,-1069501632),u=gi(u,l,s,c,e[n+11],14,643717713),c=gi(c,u,l,s,e[n],20,-373897302),s=gi(s,c,u,l,e[n+5],5,-701558691),l=gi(l,s,c,u,e[n+10],9,38016083),u=gi(u,l,s,c,e[n+15],14,-660478335),c=gi(c,u,l,s,e[n+4],20,-405537848),s=gi(s,c,u,l,e[n+9],5,568446438),l=gi(l,s,c,u,e[n+14],9,-1019803690),u=gi(u,l,s,c,e[n+3],14,-187363961),c=gi(c,u,l,s,e[n+8],20,1163531501),s=gi(s,c,u,l,e[n+13],5,-1444681467),l=gi(l,s,c,u,e[n+2],9,-51403784),u=gi(u,l,s,c,e[n+7],14,1735328473),c=gi(c,u,l,s,e[n+12],20,-1926607734),s=bi(s,c,u,l,e[n+5],4,-378558),l=bi(l,s,c,u,e[n+8],11,-2022574463),u=bi(u,l,s,c,e[n+11],16,1839030562),c=bi(c,u,l,s,e[n+14],23,-35309556),s=bi(s,c,u,l,e[n+1],4,-1530992060),l=bi(l,s,c,u,e[n+4],11,1272893353),u=bi(u,l,s,c,e[n+7],16,-155497632),c=bi(c,u,l,s,e[n+10],23,-1094730640),s=bi(s,c,u,l,e[n+13],4,681279174),l=bi(l,s,c,u,e[n],11,-358537222),u=bi(u,l,s,c,e[n+3],16,-722521979),c=bi(c,u,l,s,e[n+6],23,76029189),s=bi(s,c,u,l,e[n+9],4,-640364487),l=bi(l,s,c,u,e[n+12],11,-421815835),u=bi(u,l,s,c,e[n+15],16,530742520),c=bi(c,u,l,s,e[n+2],23,-995338651),s=Ti(s,c,u,l,e[n],6,-198630844),l=Ti(l,s,c,u,e[n+7],10,1126891415),u=Ti(u,l,s,c,e[n+14],15,-1416354905),c=Ti(c,u,l,s,e[n+5],21,-57434055),s=Ti(s,c,u,l,e[n+12],6,1700485571),l=Ti(l,s,c,u,e[n+3],10,-1894986606),u=Ti(u,l,s,c,e[n+10],15,-1051523),c=Ti(c,u,l,s,e[n+1],21,-2054922799),s=Ti(s,c,u,l,e[n+8],6,1873313359),l=Ti(l,s,c,u,e[n+15],10,-30611744),u=Ti(u,l,s,c,e[n+6],15,-1560198380),c=Ti(c,u,l,s,e[n+13],21,1309151649),s=Ti(s,c,u,l,e[n+4],6,-145523070),l=Ti(l,s,c,u,e[n+11],10,-1120210379),u=Ti(u,l,s,c,e[n+2],15,718787259),c=Ti(c,u,l,s,e[n+9],21,-343485551),s=pi(s,r),c=pi(c,i),u=pi(u,a),l=pi(l,o);return[s,c,u,l]}function Ei(e){var t,n="",r=32*e.length;for(t=0;t<r;t+=8)n+=String.fromCharCode(e[t>>5]>>>t%32&255);return n}function _i(e){var t,n=[];for(n[(e.length>>2)-1]=void 0,t=0;t<n.length;t+=1)n[t]=0;var r=8*e.length;for(t=0;t<r;t+=8)n[t>>5]|=(255&e.charCodeAt(t/8))<<t%32;return n}function ki(e){return Ei(Si(_i(e),8*e.length))}function wi(e,t){var n,r,i=_i(e),a=[],o=[];for(a[15]=o[15]=void 0,i.length>16&&(i=Si(i,8*e.length)),n=0;n<16;n+=1)a[n]=909522486^i[n],o[n]=1549556828^i[n];return r=Si(a.concat(_i(t)),512+8*t.length),Ei(Si(o.concat(r),640))}function Ai(e){var t,n,r="0123456789abcdef",i="";for(n=0;n<e.length;n+=1)t=e.charCodeAt(n),i+=r.charAt(t>>>4&15)+r.charAt(15&t);return i}function Ri(e){return unescape(encodeURIComponent(e))}function xi(e){return ki(Ri(e))}function Ci(e){return Ai(xi(e))}function Ii(e,t){return wi(Ri(e),Ri(t))}function Pi(e,t){return Ai(Ii(e,t))}function Oi(e,t,n){return t?n?Ii(t,e):Pi(t,e):n?xi(e):Ci(e)}var Di=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e.msg),r.data=e,r}return p(n)}(An(Error)),Ui=function(){function e(t,n,r){h(this,e),this.state=null,this.client=t,this.track=n,this.audioTrack=r,this.rtpChannel=1,this.audiortpChannel=1,this.stopKeepAlive(),this.keepaliveInterval=null}return p(e,[{key:"reset",value:function(){this.stopKeepAlive(),this.client.forgetRTPChannel(this.rtpChannel),this.client=null,this.track=null}},{key:"start",value:function(){return this.sendSetup().then(this.sendPlay.bind(this))}},{key:"stop",value:function(){return this.sendTeardown()}},{key:"getSetupURL",value:function(e){var t=this.client.sdp.getSessionBlock();return hr.isAbsolute(e.control)?e.control:hr.isAbsolute("".concat(t.control).concat(e.control))?"".concat(t.control).concat(e.control):hr.isAbsolute("".concat(this.client.contentBase).concat(e.control))?"".concat(this.client.contentBase).concat(e.control):e.control}},{key:"getControlURL",value:function(){var e=this.client.sdp.getSessionBlock().control;return hr.isAbsolute(e)?e:e&&"*"!==e?"".concat(this.client.contentBase).concat(e):this.client.contentBase||this.client.url}},{key:"sendKeepalive",value:function(){return this.client.methods.includes("GET_PARAMETER")?this.client.sendRequest("GET_PARAMETER",this.getSetupURL(this.track),{Session:this.session}):this.client.sendRequest("OPTIONS","*")}},{key:"stopKeepAlive",value:function(){clearInterval(this.keepaliveInterval)}},{key:"startKeepAlive",value:function(){var e=this;this.keepaliveInterval=setInterval((function(){e.sendKeepalive().catch((function(t){t instanceof Di&&501==Number(t.data.parsed.code)||e.client.reconnect()}))}),3e4)}},{key:"sendRequest",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n={};return this.session&&(n["Session"]=this.session),Object.assign(n,t),this.client.sendRequest(e,this.getControlURL(),n)}},{key:"sendAudioSetup",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.session=t.headers["session"],n=this.client.interleaveChannelIndex+++"-"+this.client.interleaveChannelIndex++,e.next=4,this.client.sendRequest("SETUP",this.getSetupURL(this.audioTrack),{Session:this.session,Transport:"RTP/AVP/TCP;unicast;interleaved=".concat(n),Date:(new Date).toUTCString()});case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"sendSetup",value:function(){var t=l(regeneratorRuntime.mark((function t(){var n,r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return this.state=e.STATE_SETUP,this.rtpChannel=this.client.interleaveChannelIndex,this.audiortpChannel=this.client.interleaveChannelIndex+2,n=this.client.interleaveChannelIndex+++"-"+this.client.interleaveChannelIndex++,t.next=6,this.client.sendRequest("SETUP",this.getSetupURL(this.track),{Transport:"RTP/AVP/TCP;unicast;interleaved=".concat(n),Date:(new Date).toUTCString()});case 6:r=t.sent,this.sendAudioSetup(r);case 8:case"end":return t.stop()}}),t,this)})));function n(){return t.apply(this,arguments)}return n}()},{key:"sendPlay",value:function(){var t=l(regeneratorRuntime.mark((function t(){var n,r,i,a;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n=new Promise((function(e){setTimeout((function(){return e("done")}),500)})),t.next=3,n;case 3:return this.state=e.STATE_PLAY,r={},i=this.client.sdp.sessionBlock.range,i&&-1==i[0]&&(i[0]=0),this.client.useRTPChannel(this.rtpChannel),this.client.useRTPChannel(this.audiortpChannel),t.next=11,this.sendRequest("PLAY",r);case 11:return a=t.sent,this.state=e.STATE_STREAMS,t.abrupt("return",{track:this.track,data:a});case 14:case"end":return t.stop()}}),t,this)})));function n(){return t.apply(this,arguments)}return n}()},{key:"sendPause",value:function(){var t=l(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(this.client.supports("PAUSE")){t.next=2;break}return t.abrupt("return");case 2:return t.next=4,this.sendRequest("PAUSE");case 4:this.state=e.STATE_PAUSED;case 5:case"end":return t.stop()}}),t,this)})));function n(){return t.apply(this,arguments)}return n}()},{key:"sendTeardown",value:function(){var t=l(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(this.state==e.STATE_TEARDOWN){t.next=6;break}return this.client.forgetRTPChannel(this.rtpChannel),this.state=e.STATE_TEARDOWN,this.stopKeepAlive(),t.next=6,this.sendRequest("TEARDOWN");case 6:case"end":return t.stop()}}),t,this)})));function n(){return t.apply(this,arguments)}return n}()}],[{key:"STATE_INITIAL",get:function(){return 1}},{key:"STATE_OPTIONS",get:function(){return 2}},{key:"STATE_DESCRIBE",get:function(){return 4}},{key:"STATE_SETUP",get:function(){return 8}},{key:"STATE_STREAMS",get:function(){return 16}},{key:"STATE_TEARDOWN",get:function(){return 32}},{key:"STATE_MULTITRANS",get:function(){return 64}},{key:"STATE_PAUSED",get:function(){return 128}}]),e}(),Mi=re("client:rtsp"),Bi=100,Ni=0,Li=new WebAssembly.Memory({initial:256,maximum:256}),Fi={env:{abortStackOverflow:function(){throw new Error("overflow")},table:new WebAssembly.Table({initial:0,maximum:0,element:"anyfunc"}),tableBase:0,memory:Li,memoryBase:204800,STACKTOP:0,STACK_MAX:Li.buffer.byteLength}},ji=function(e){Tn(n,e);var t=_n(n);function n(e){return h(this,n),t.call(this,e)}return p(n)}(An(Error)),Wi={PERMISSION_DENIED:1202,NOT_SUPPORTED_ERROR:1203,MANDATORY_UNSATISFIED_ERROR:1204,NotFoundError:1205,NotAllowedError:1208},Hi={"-82400":"CLOUD_ERR_PARAM","-82401":"CLOUD_ERR_PERMISSION","-82414":"CLOUD_ERR_SERVER","-80702":"COMMON_ERR_SESSION","-80731":"CLOUD_ERR_TOKEN","-80304":"CLOUD_ERR_DEVID","-80732":"CLOUD_ERR_BANDWIDTH","-20002":"DEVICE_ERR_CHN_OFFLINE","-20571":"DEVICE_ERR_CHN_OFFLINE","-52405":"CLOUD_ERR_STREAM_LIMIT","-52413":"DEVICE_ERR_CHN_OFFLINE","-40106":"AUDIO_ERR_AUDIO_ENABLE","-52412":"AUDIO_ERR_AUDIO_NOSUPPORTED","-52411":"AUDIO_ERR_AUDIO_BUSY"},Vi="device-stream-boundary",qi=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this),r.parent=e,r.transport=null,r.payParser=new Fn,r.rtp_channels=new Set,r.ontracks=null,r.messageBuilder={RTSP:new jr(jr.RTSP_1_0),HTTP:new jr(jr.HTTP_1_1)},r.isPlaying=!1,r.getAudioTime=0,r.tempVedioData=[],r.tempAudioData=[],r.addState(n.STATE_INITIAL,{}).addState(n.STATE_OPTIONS,{activate:r.sendOptions,finishTransition:r.onOptions}).addState(n.STATE_DESCRIBE,{activate:r.sendDescribe,finishTransition:r.onDescribe}).addState(n.STATE_SETUP,{activate:r.sendSetup,finishTransition:r.onSetup}).addState(n.STATE_STREAMS,{}).addState(n.STATE_TEARDOWN,{activate:function(){r.started=!1},finishTransition:function(){return r.transitionTo(n.STATE_INITIAL)}}).addState(n.STATE_PAUSED,{activate:r.sendPause,finishTransition:r.onPause}).addState(n.STATE_PLAY,{activate:r.sendPlay,finishTransition:r.onPlay}).addTransition(n.STATE_INITIAL,n.STATE_OPTIONS).addTransition(n.STATE_INITIAL,n.STATE_TEARDOWN).addTransition(n.STATE_OPTIONS,n.STATE_DESCRIBE).addTransition(n.STATE_DESCRIBE,n.STATE_SETUP).addTransition(n.STATE_SETUP,n.STATE_STREAMS).addTransition(n.STATE_TEARDOWN,n.STATE_INITIAL).addTransition(n.STATE_STREAMS,n.STATE_PAUSED).addTransition(n.STATE_PAUSED,n.STATE_STREAMS).addTransition(n.STATE_PAUSED,n.STATE_PLAY).addTransition(n.STATE_PLAY,n.STATE_STREAMS).addTransition(n.STATE_PLAY,n.STATE_TEARDOWN).addTransition(n.STATE_STREAMS,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_TEARDOWN).addTransition(n.STATE_SETUP,n.STATE_TEARDOWN).addTransition(n.STATE_DESCRIBE,n.STATE_TEARDOWN).addTransition(n.STATE_OPTIONS,n.STATE_TEARDOWN),r.reset(),r.shouldReconnect=!1,r}return p(n,[{key:"destroy",value:function(){this.parent=null}},{key:"setSource",value:function(e){this.reset(),this.endpoint=e,this.url=e.full}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&this.start();case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onDisconnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.reset(),this.shouldReconnect=!0,e.next=4,this.transitionTo(n.STATE_TEARDOWN);case 4:return e.next=6,this.transitionTo(n.STATE_INITIAL);case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){return this.currentState.name!==n.STATE_STREAMS?this.transitionTo(n.STATE_OPTIONS):Promise.resolve()}},{key:"onData",value:function(e){var t=e[1];this.rtp_channels.has(t)&&this.onRTP({packet:e.subarray(4),type:t})}},{key:"useRTPChannel",value:function(e){this.rtp_channels.add(e)}},{key:"forgetRTPChannel",value:function(e){this.rtp_channels.delete(e)}},{key:"stop",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.started){e.next=3;break}return e.next=3,this.sendTeardown();case 3:this.shouldReconnect=!1;case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(t in this.authenticator="",this.methods=[],this.tracks=[],this.rtpBuffer={},this.streams)this.streams[t].reset();if(this.streams={},this.contentBase="",!this.currentState){e.next=15;break}if(this.currentState.name==n.STATE_INITIAL){e.next=13;break}return e.next=11,this.transitionTo(n.STATE_TEARDOWN);case 11:return e.next=13,this.transitionTo(n.STATE_INITIAL);case 13:e.next=17;break;case 15:return e.next=17,this.transitionTo(n.STATE_INITIAL);case 17:this.sdp=null,this.interleaveChannelIndex=0,this.session=null,this.timeOffset={},this.lastTimestamp=0;case 22:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reconnect",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.reset();case 2:if(this.currentState.name==n.STATE_INITIAL){e.next=8;break}return e.next=5,this.transitionTo(n.STATE_TEARDOWN);case 5:return e.abrupt("return",this.transitionTo(n.STATE_OPTIONS));case 8:return e.abrupt("return",this.transitionTo(n.STATE_OPTIONS));case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"supports",value:function(e){return this.methods.includes(e)}},{key:"parse",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RTSP",n=e.split("\r\n\r\n"),r=this.messageBuilder[t].parse(n[0]),i=Number(r.headers["content-length"]);if(i){var a=n[1];a&&"application/json"===r.headers["content-type"]&&(a=JSON.parse(a)),r.body=a}else r.body="";return Yi.log("parsed data: ",r),r}},{key:"sendRequest",value:function(e,t){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"RTSP";return this.cSeq++,Object.assign(i,{CSeq:this.cSeq,"User-Agent":n.USER_AGENT}),this.authenticator&&(i["Authorization"]=this.authenticator(e)),this.send(this.messageBuilder[o].build(e,t,i,a),o).catch((function(n){if(n instanceof ji)return r.sendRequest(e,t,i,a,o);throw n}),o)}},{key:"send",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,u,l,f,h,d,p,v,m,y,g,b=this,T=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=T.length>1&&void 0!==T[1]?T[1]:"RTSP",!this.transport){e.next=39;break}return e.prev=2,e.next=5,this.transport.ready;case 5:e.next=11;break;case 7:throw e.prev=7,e.t0=e["catch"](2),this.onDisconnected(),e.t0;case 11:return e.next=13,this.transport.send(t);case 13:if(r=e.sent,i=this.parse(r,n),401!==i.code){e.next=33;break}if(Mi.log("www-authenticate header: ",i.headers["www-authenticate"]),a=i.headers["www-authenticate"],o=a.substring(0,a.indexOf(" ")),a=a.substr(o.length+1),s=a.split(","),u=this.parent.endpoint,u.user&&u.pass){e.next=31;break}return e.prev=23,e.next=26,this.parent.queryCredentials.call(this.parent);case 26:e.next=31;break;case 28:throw e.prev=28,e.t1=e["catch"](23),new ji;case 31:if("digest"==o.toLowerCase()){l={},f=c(s);try{for(f.s();!(h=f.n()).done;)d=h.value,p=d.trim(),v=p.split("="),m=gn(v,2),y=m[0],g=m[1],l[y]=g.substr(1,g.length-2)}catch(S){f.e(S)}finally{f.f()}this.authenticator=function(e){var t=b.parent.endpoint,n=Oi("".concat(t.user,":").concat(l.realm,":").concat(t.pass)),r=Oi("".concat(e,":").concat(t.urlpath)),i=Oi("".concat(n,":").concat(l.nonce,":").concat(r)),a="";return'Digest username="'.concat(t.user,'", nonce="').concat(l.nonce,'", uri="').concat(t.urlpath,'", response="').concat(i,'"').concat(a)}}else this.authenticator=function(){return"Basic ".concat(btoa(b.parent.endpoint.auth))};throw new ji(i);case 33:if(!(i.code>=300)){e.next=36;break}throw Mi.error(i.statusLine),new Di({msg:"RTSP error: ".concat(i.code," ").concat(i.statusLine),parsed:i});case 36:return e.abrupt("return",i);case 39:return e.abrupt("return",Promise.reject("No transport attached"));case 40:case"end":return e.stop()}}),e,this,[[2,7],[23,28]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"error",value:function(e){this.parent.error(e)}},{key:"sendTeardown",value:function(){var e="TEARDOWN";return this.sendRequest(e,"*")}},{key:"sendHeartbeat",value:function(){}},{key:"sendMultitrans",value:function(){}},{key:"onMultitrans",value:function(){}},{key:"sendDescribe",value:function(){var e=this;return this.sendRequest("DESCRIBE",this.url,{Accept:"application/sdp"}).then((function(t){return e.sdp=new Wn,e.sdp.parse(t.body).catch((function(){throw new Error("Failed to parse SDP")})).then((function(){return t}))}))}},{key:"onDescribe",value:function(e){if(Mi.log("sdp data: ",e),Mi.log("sdp: ",this.sdp),this.contentBase=e.headers["content-base"]||this.url,this.tracks=this.sdp.getMediaBlockList(),this.rtpFactory=new Dn(this.sdp),Mi.log("SDP contained "+this.tracks.length+" track(s). Calling SETUP for each."),e.headers["session"]&&(this.session=e.headers["session"]),!this.tracks.length)throw new Error("No tracks in SDP");this.transitionTo(n.STATE_SETUP)}},{key:"sendSetup",value:function(){var e=this,t=[],n=this.sdp.getMediaBlock("video"),r=this.sdp.getMediaBlock("audio");Yi.log("video media block: ",n),Yi.log("audio media block: ",r),this.streams["video"]=new Ui(this,n,r);var i=this.streams["video"].start();return this.parent.sampleQueues[w.string_map[n.rtpmap[n.fmt[0]].name]]=[],r&&(this.parent.sampleQueues[w.string_map[r.rtpmap[r.fmt[0]].name]]=[]),this.rtpBuffer[n.fmt[0]]=[],r&&(this.rtpBuffer[r.fmt[0]]=[]),t.push(i.then((function(t){var n=t.track,i=t.data;Mi.log("setup: ",n,i),r&&(e.timeOffset[r.fmt[0]]=0),e.timeOffset[n.fmt[0]]=0;try{var a,o=i.headers["rtp-info"].split(";"),s=c(o);try{for(s.s();!(a=s.n()).done;){var u=a.value,l=u.split("="),f=gn(l,2),h=f[0],d=f[1];"rtptime"===h&&(e.timeOffset[n.fmt[0]]=Number(d))}}catch(S){s.e(S)}finally{s.f()}}catch(E){}var p={timescale:0,scaleFactor:0};if(n.fmtp&&n.fmtp["sprop-parameter-sets"]){var v=n.fmtp["sprop-parameter-sets"].split(",");p={sps:y(v[0]),pps:y(v[1])}}else if(n.fmtp&&n.fmtp["config"]){var m=n.fmtp["config"];e.has_config="0"!=n.fmtp["cpresent"];var b="MPEG4-GENERIC"==n.rtpmap[n.fmt[0]].name;b?(p={config:Vn.parseAudioSpecificConfig(g(m))},e.payParser.aacparser.setConfig(p.config)):m&&(p={config:Vn.parseStreamMuxConfig(g(m))},e.payParser.aacparser.setConfig(p.config))}p.duration=e.sdp.sessionBlock.range?e.sdp.sessionBlock.range[1]-e.sdp.sessionBlock.range[0]:1,e.parent.seekable=p.duration>1;var T={track:n,audioTrack:r,offset:e.timeOffset[n.fmt[0]],type:w.string_map[n.rtpmap[n.fmt[0]].name],params:p,duration:p.duration};return T}))),Promise.all(t).then((function(t){Yi.log("setup res: ",t),e.ontracks&&e.ontracks(t)})).catch((function(t){Mi.log("stop play: ",t),e.stop(),e.reset()}))}},{key:"onSetup",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"pause",value:function(){return this.currentState.name===n.STATE_STREAMS?(this.isPlaying=!1,this.transitionTo(n.STATE_PAUSED)):Promise.resolve()}},{key:"sendPause",value:function(){this.streams["video"].sendPause()}},{key:"onPause",value:function(){this.isPlaying=!1}},{key:"play",value:function(){return this.currentState.name===n.STATE_PAUSED?this.transitionTo(n.STATE_PLAY):Promise.resolve()}},{key:"sendPlay",value:function(){return this.streams["video"].sendPlay()}},{key:"onPlay",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"onRTP",value:function(e){var t=this;if(this.rtpFactory){this.isPlaying||this.currentState.name===n.STATE_PAUSED||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream"));var r=this.rtpFactory.build(e.packet,this.sdp);if(r.type){r.utc_timestamp&&(this.timeOffset={},this.timeOffset[r.pt]=r.timestamp,this.lastTimestamp=r.utc_timestamp),this.timeOffset[r.pt]||(this.timeOffset[r.pt]=r.timestamp),this.timeOffset[r.pt]&&(r.timestamp-this.timeOffset[r.pt]<0||r.timestamp-this.timeOffset[r.pt]>9e5)&&(this.timeOffset[r.pt]=r.timestamp);var i=this.rtpBuffer[r.pt];i.push(r);var a=function(){var e=i.shift(),n=parseInt(1e3*(t.lastTimestamp+(e.timestamp-t.timeOffset[e.pt])/9e4));if(e.media){var r=t.payParser.parse(e);if(r){if(t.parent.readyToPlay){var a=!1,o=r[0].ntype;switch(e.media.ptype){case w.H264:a=7===o;break;case w.H265:a=32===o;break;default:break}if(!a)return{v:void 0};t.parent.readyToPlay=!1}t.parent.sampleQueues[e.type]&&(r.forEach((function(r){r.timestamp=n,e.isVideo()&&(r.seq=t.currentSeq,t.currentSeq=0)})),t.parent.sampleQueues[e.type].push(r))}}};while(i.length){var o=a();if("object"===f(o))return o.v}}}}},{key:"updateReceivedSeq",value:function(){}}],[{key:"USER_AGENT",get:function(){return"SFRtsp 0.3"}},{key:"FINISH_REASON",get:function(){return{share_finish:oe.CLOUD_ERR_SHARE_FINISH,permission_deny:oe.CLOUD_ERR_PERMISSION,channel_offline:oe.DEVICE_ERR_CHN_OFFLINE,channel_invalid:oe.DEVICE_ERR_CHN_INVALID,internal_error:oe.COMMON_ERR_INTERNAL,password_changed:oe.DEVICE_ERR_PWD_CHANGED,media_encrypt_changed:oe.CLOUD_ERR_ENCRYPT_CHANGED,relay_lifetime_expired:oe.CLOUD_ERR_FREE,channel_talk_busy:oe.CLOUD_ERR_TALK_BUSY,unbind_device:oe.CLOUD_ERR_UNBIND,lack_bandwidth:oe.CLOUD_ERR_BANDWIDTH,offline:oe.DEVICE_ERR_CHN_OFFLINE}}},{key:"STATE_INITIAL",get:function(){return 1}},{key:"STATE_OPTIONS",get:function(){return 2}},{key:"STATE_DESCRIBE",get:function(){return 4}},{key:"STATE_SETUP",get:function(){return 8}},{key:"STATE_STREAMS",get:function(){return 16}},{key:"STATE_TEARDOWN",get:function(){return 32}},{key:"STATE_GET_STREAMS",get:function(){return 64}},{key:"STATE_PAUSED",get:function(){return 128}},{key:"STATE_PLAY",get:function(){return 256}},{key:"STATE_SEND_VOICE",get:function(){return 512}}]),n}(Rr),zi=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.slpRecorder=null,r.continuityCounterTs=48,r.continuityCounterPes=16,r.continuityCounterPNT=16,r.ptsMultiple=1,r.fPATCount=0,r.fPMTCount=0,r.audioSlpEncoder=null,r.noisedecoderSlpWorker=null,r.hasNoiseSlpDecoderInit=!1,r.initDecoderSlpWorker(),r.tsaudioBuffer=new Uint8Array,r.tsCount=0,r.addState(qi.STATE_GET_STREAMS,{activate:r.getStreams,finishTransition:r.onSlpStreamConfigs}).addState(qi.STATE_SEND_VOICE,{activate:r.sendSlpVoice,finishTransition:r.onSlpVoice}).addTransition(qi.STATE_OPTIONS,qi.STATE_GET_STREAMS).addTransition(qi.STATE_GET_STREAMS,qi.STATE_SEND_VOICE).addTransition(qi.STATE_SEND_VOICE,qi.STATE_STREAMS).addTransition(qi.STATE_SEND_VOICE,qi.STATE_TEARDOWN),r.reset(),r}return p(n,[{key:"initDecoderSlpWorker",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.hasNoiseSlpDecoderInit=!1,e.next=3,Ft();case 3:t=e.sent,n=t.libsWorker,r=t.libaudio,i=t.libaudioWasm,this.noisedecoderSlpWorker=new Worker(n),this.noisedecoderSlpWorker.postMessage({cmd:"init",scripts:[r],wasmBinary:i}),this.noisedecoderSlpWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,r=n.hasInit;r?a.hasNoiseSlpDecoderInit=!0:a.transformSlpTsBuffer(n.data,a.audioSlpEncoder)};case 10:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){Mi.log("set source: ",e),this.reset(),this.endpoint=e}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.shouldReconnect&&(Mi.log("start"),this.start());case 1:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.deviceBoundary="",this.sessionId="",this.loadedChunks=[],this.parsing=!1,this.cSeq=0,this.payload={},this.receivedSeq=0,this.initParser(),!this.currentState){e.next=16;break}if(this.currentState.name==qi.STATE_INITIAL){e.next=14;break}return e.next=12,this.transitionTo(qi.STATE_TEARDOWN);case 12:return e.next=14,this.transitionTo(qi.STATE_INITIAL);case 14:e.next=18;break;case 16:return e.next=18,this.transitionTo(qi.STATE_INITIAL);case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"initParser",value:function(){var e=this;this.parser=new Kn,this.parser.addPesParser(Yn.H264,Xn),this.parser.addPesParser(Yn.H265,Xn),this.parser.addPesParser(Yn.AAC,Qn),this.parser.addPesParser(Yn.PCMA_W,Zn),this.parser.addPesParser(Yn.PCMA,$n),this.parser.ontracks=function(t){var n,r={},i=c(t);try{for(i.s();!(n=i.n()).done;){var a=n.value;switch(e.parent.sampleQueues[a.type]=[],a.type){case w.H264:r.video_codec="H264";break;case w.H265:r.video_codec="H265";break;case w.G711A:r.audio_codec="G711alaw";break;case w.AAC:r.audio_codec="AAC";break;case w.PCMA_W:r.audio_codec="PCMA_W";break;default:break}}}catch(o){i.e(o)}finally{i.f()}r.video_codec&&e.onRelayConfig(r)}}},{key:"buildBoundary",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r="----".concat(Vi,"--\r\n");if("sendMultiparts"===n?e=T(new Uint8Array(e)):e instanceof Object&&(e=JSON.stringify(e)),"sendMultiparts"===n?(r+="Content-Type: audio/mp2t\r\n",r+="X-If-Encrypt\t: ".concat(0,"\r\n")):r+="Content-Type: application/json\r\n",r+="Content-Length: ".concat(e.length,"\r\n"),this.sessionId&&(r+="X-Session-Id: ".concat(this.sessionId,"\r\n")),t&&(r+=t),r+="\r\n",r+=e,"sendMultiparts"===n){for(var i=r.length,a=new Uint8Array(i),o=0;o<i;o++)a[o]=r.charCodeAt(o);return a.buffer}return r}},{key:"sendBoundary",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=17;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t);case 12:return n=e.sent,r=this.parseBoundary(n),e.abrupt("return",r);case 17:return e.abrupt("return",Promise.reject("No transport attached"));case 18:case"end":return e.stop()}}),e,this,[[1,6]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parseBoundary",value:function(e){var t=e.split("\r\n\r\n"),n=gn(t,2),r=n[0],i=n[1],a={headers:{},body:i},o=r.split("\r\n");if(-1===o[0].indexOf(this.deviceBoundary))a.body=e;else{var s=1;while(o[s]){var c=o[s].split(/:(.+)/),u=gn(c,2),l=u[0],f=u[1];a.headers[l.toLowerCase()]=f.trim(),s++}}return a}},{key:"onData",value:function(e){var t=T(e),n=this.parseBoundary(t),r=n.headers,i=n.body;if("application/json"===r["content-type"]){Mi.log("on data: ",i),i=JSON.parse(i);var a=i,o=a.params,s=void 0===o?{}:o,c=s.error_code,u=void 0===c?0:c;if(u){var l=Hi[u]||"CLOUD_ERR_STREAM";return this.error(oe[l]),void this.transitionTo(qi.STATE_TEARDOWN)}if(s.session_id&&(this.sessionId=s.session_id),"stream_finish"===s.event_type){this.parent.stop();var f=qi.FINISH_REASON[s.reason];this.error(f||oe.MEDIA_ERR_NETWORK)}else if("channel_stream_status"===s.event_type){var h=s.status&&s.status[0],d=qi.FINISH_REASON[h];"no_data"===h||d&&(this.parent.stop(),this.error(d))}}else{for(var p=[],v=0;v<i.length;v++)p.push(i.charCodeAt(v));this.onTS(new Uint8Array(p),r["x-data-sequence"])}}},{key:"sendOptions",value:function(){this.reset(),this.started=!0,this.cSeq=0;var e=this.parent.options.slpData,t=void 0===e?{}:e,n=t.connectionId,r=t.port,i=t.token,a=(t.httpsPort,t.serverUrl),o=t.deviceModel,s="POST",c={Host:"".concat(a,":").concat(r),"User-Agent":"Device=".concat(o," 1.0/1.3"),"X-token":i,Accept:"*/*","Content-Type":"multipart/mixed; boundary=--device-stream-boundary--","Content-Length":Number.MAX_SAFE_INTEGER,Connection:"keep-alive"},u="/mediaservice?type=bidirection&connectionid=".concat(n),l=this.messageBuilder["HTTP"].build(s,u,c,null);return this.send(l,"HTTP")}},{key:"onOptions",value:function(e){this.transitionTo(qi.STATE_GET_STREAMS)}},{key:"getStreams",value:function(){this.sessionId="";var e=this.parent.options.slpData,t=void 0===e?{}:e,n=t.channel,r={},i="",a={method:"get",talk:{mode:this.parent.options.mode||"aec",channel:n}},o={type:"request",seq:0,params:a},s="",c=this.build("",i,r,null);return c+=this.buildBoundary(o,s),this.sendStreamsBoundary(c)}},{key:"build",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i="";for(var a in n)i+="".concat(a,": ").concat(n[a],"\r\n");return null!==r&&(r instanceof Object&&(r=JSON.stringify(r)),i+="Content-Length: ".concat(r.length,"\r\n")),i+="\r\n",null!==r&&(i+=r),i}},{key:"sendStreamsBoundary",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=17;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t);case 12:return n=e.sent,r=this.parseStreamsBoundary(n),e.abrupt("return",r);case 17:return e.abrupt("return",Promise.reject("No transport attached"));case 18:case"end":return e.stop()}}),e,this,[[1,6]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"parseStreamsBoundary",value:function(e){var t=e.split("\r\n\r\n"),n=gn(t,2),r=n[0],i=n[1];this.sessionId=JSON.parse(i).params.session_id;var a={headers:{},body:i,code:JSON.parse(i).params.error_code},o=r.split("\r\n");if(-1===o[0].indexOf(this.deviceBoundary))a.body=e;else{var s=1;while(o[s]){var c=o[s].split(/:(.+)/),u=gn(c,2),l=u[0],f=u[1];a.headers[l.toLowerCase()]=f.trim(),s++}}return a}},{key:"onSlpStreamConfigs",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,c=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.headers,r=t.code,404!==r&&410!==r){e.next=6;break}return Ni<=MAX_RECONNECT_TIME?(Ni++,this.reconnectTimer=setTimeout((function(){c.reset(),c.redirectTime?c.parent.play():c.parent.start()}),500)):(Ni=0,this.error(oe.CLOUD_ERR_DEV_RELAY)),e.abrupt("return");case 6:if(301!==r){e.next=12;break}return i=n["x-domain"],a=n["x-redirect-cookie"],this.parent.redirect({domain:i,cookie:a}),this.redirectTime++,e.abrupt("return");case 12:if(this.redirectTime=0,Ni=0,this.parent.isReconnect=!1,0===r){e.next=19;break}return o=qi.RESPONSE_ERR_CODE[t.code],this.error(o||oe.CLOUD_ERR_DEV_RELAY),e.abrupt("return");case 19:this.deviceBoundary=n["content-type"].split("boundary=")[1],s=this.transport.socket(),s.initDataChannel(),this.transitionTo(qi.STATE_SEND_VOICE);case 23:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"sendSlpVoice",value:function(){var e=this;Fr.get((function(t){t.rec?(e.slpRecorder=t.rec,e.startSlpRecorder()):e.parent.error(Wi[t.error.name])}))}},{key:"startSlpRecorder",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.slpRecorder.start(),t=new rr["PCMA"](this.parent.audioWasm,Fi),this.audioSlpEncoder=t.encodeA.bind(t),this.slpRecorder.audioTatch=function(){n.slpDataPart(n.audioSlpEncoder)};case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"slpDataPart",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=new FileReader,r=this,n.onload=function(e){var n=e.target.result,i=2048,a=new Uint8Array([].concat(Le(r.tsaudioBuffer),Le(new Uint8Array(n))));if(a.length>0)for(var o=new Uint8Array(i),s=0,c=0;c<a.byteLength;c++)o[s++]=a[c],(c+1)%i===0&&(r.noiseSetSlp(o,t),o=a.byteLength-c-1>=i?new Uint8Array(i):new Uint8Array(a.byteLength-c-1),s=0),c+1===a.byteLength&&(c+1)%i!==0&&(r.tsaudioBuffer=o)},n.readAsArrayBuffer(this.slpRecorder.getPcmData());case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"noiseSetSlp",value:function(e,t){var n=t(e);this.noisedecoderSlpWorker.postMessage({data:n,samplerate:8e3,decoderType:"_decodeG711a"})}},{key:"transformSlpTsBuffer",value:function(e,t){var n=t(e),r=new Uint8Array(n),i=this.PacketDataToTs(r,1024);this.sendMultiparts(i,"","sendMultiparts")}},{key:"PacketDataToTs",value:function(e,t){var n=!1,r=188,i=0,a=1504,o=14,s=new ArrayBuffer(a),c=new DataView(s);if(!n){c.setUint8(i,71),i+=1,c.setUint8(i,64),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,16+(15&this.fPATCount)),this.fPATCount++,i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,176),i+=1,c.setUint8(i,13),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,193),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1;var u=this.pat(),l=E(new Uint8Array(u.pATSetCrc32Buf),u.setPATSetCrc32Off);c.setUint32(i,l),i+=4;for(var f=i;f<188;f++,i+=1)c.setUint8(i,255);c.setUint8(i,71),i+=1,c.setUint8(i,80),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,16+(15&this.fPMTCount)),this.fPMTCount++,i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,2),i+=1;var h=26,d=h-3;d-=5,c.setUint8(i,176),i+=1,c.setUint8(i,d),i+=1,c.setUint16(i,1),i+=2,c.setUint8(i,193),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,225),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,144),i+=1,c.setUint8(i,225),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,240),i+=1,c.setUint8(i,0),i+=1;var p=this.pmt(),v=E(new Uint8Array(p.pmtcrcBuf),p.pmtOff);c.setUint32(i,v),i+=4;for(f=i;f<376;f++,i+=1)c.setUint8(i,255);n=!0}var m=0,y=0,g=0,b=12+o,T=r-b;t<=T?(m=1,y=t):(m=parseInt((t-T-1)/(r-4))+1,m+=1,y=(t-T)%(r-4),0==y&&(y=r-4));for(var S=0;S<m;S++){var _=i;if(0==S)c.setUint8(i,71),i+=1,c.setUint8(i,65),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1,c.setUint8(i,7),i+=1,c.setUint8(i,16),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,192),i+=1,c.setUint16(i,t+8),i+=2,c.setUint8(i,128),i+=1,c.setUint8(i,128),i+=1,c.setUint8(i,5),i+=1,c.setUint8(i,33),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,0),i+=1,c.setUint8(i,1),i+=1;else if(S==m-1)if(184==y)c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,16+(15&this.tsCount)),this.tsCount++,i+=1;else if(183==y)c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1,c.setUint8(i,0),i+=1;else{c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,48+(15&this.tsCount)),this.tsCount++,i+=1;var k=r-6-y;c.setUint8(i,1+k),i+=1,c.setUint8(i,0),i+=1;for(var w=0;w<k;w++,i+=1)c.setUint8(i,255)}else c.setUint8(i,71),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,1),i+=1,c.setUint8(i,16+(15&this.tsCount)),this.tsCount++,i+=1;for(var A=i-_,R=0;R<188-A;R++,i+=1)c.setUint8(i,e[R+g]);g+=r-A}return s}},{key:"pat",value:function(){var e=new ArrayBuffer(12),t=new DataView(e),n=0;return t.setUint8(n,0),n+=1,t.setUint8(n,176),n+=1,t.setUint8(n,13),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,193),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,0),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,224),n+=1,t.setUint8(n,1),n+=1,{pATSetCrc32Buf:e,setPATSetCrc32Off:n}}},{key:"pmt",value:function(){var e=new ArrayBuffer(17),t=new DataView(e),n=0;t.setUint8(n,2),n+=1;var r=26,i=r-3;return i-=5,t.setUint8(n,176),n+=1,t.setUint8(n,i),n+=1,t.setUint16(n,1),n+=2,t.setUint8(n,193),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,224),n+=1,t.setUint8(n,68),n+=1,t.setUint8(n,240),n+=1,t.setUint8(n,0),n+=1,t.setUint8(n,144),n+=1,t.setUint8(n,225),n+=1,t.setUint8(n,1),n+=1,t.setUint8(n,240),n+=1,t.setUint8(n,0),n+=1,{pmtcrcBuf:e,pmtOff:n}}},{key:"packageNullPacket",value:function(){var e=new ArrayBuffer(188),t=new DataView(e),n=0;return t.setUint8(n,71),n+=1,t.setUint8(n,31),n+=1,t.setUint8(n,18),n+=1,this.continuityCounterPNT>30&&(this.continuityCounterPNT=16),t.setUint8(n,this.continuityCounterPNT),n+=1,this.continuityCounterPNT++,t.setUint8(n,0),n+=1,t.setUint8(n,parseInt(254*Math.random()+1)),n+=1,e}},{key:"onSlpVoice",value:function(){console.log("结束")}},{key:"sendMultiparts",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=this.buildBoundary(e,t,r);return this.sendBoundary(i).then((function(e){Mi.log("on multiparts\n",e);var t=e.body,r=void 0===t?"{}":t;r=JSON.parse(r);var i=r,a=i.params,o=void 0===a?{}:a;return n.errorException(r)?null:(o.session_id&&(n.sessionId=o.session_id),e)}))}},{key:"onTS",value:function(e,t){this.isPlaying||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream")),this.parsing?this.loadedChunks.push(e):(this.parsing=!0,this.parseTS(e,t))}},{key:"parseTS",value:function(e,t){for(var n=this,r=function(r){var i=n.parser.parse(e.subarray(r,r+Kn.PACKET_LENGTH));if(i&&n.parent.sampleQueues[i.type]){var a=i.units;if(n.parent.readyToPlay){var o=!1,s=a[0].ntype;switch(Mi.log("nalu type: ",s,i.type),i.type){case w.H264:o=7===s;break;case w.H265:o=32===s;break;default:break}if(!o)return"continue";n.parent.readyToPlay=!1}a.forEach((function(e){e.timestamp=i.timestamp,e.seq=t})),n.parent.sampleQueues[i.type].push(a)}},i=0;i<e.byteLength;i+=Kn.PACKET_LENGTH)r(i);this.parsing=!1,this.loadedChunks.length&&this.onTS(this.loadedChunks.shift())}},{key:"sendPause",value:function(){var e=this.parent.options.streamType;if("sdvod"===e){var t={type:"request",seq:0,params:{method:"do",pause:"null"}};this.sendMultiparts(t)}else"dtspk"===e&&this.slpRecorder&&this.slpRecorder.stop();return Promise.resolve()}},{key:"sendPlay",value:function(){var e=this.parent.options.streamType;if("sdvod"===e){var t={type:"request",seq:0,params:{method:"do",play:"null"}};this.sendMultiparts(t)}return Promise.resolve()}},{key:"destroy",value:function(){this.slpRecorder&&(this.slpRecorder.clear(),this.slpRecorder.stop())}}]),n}(qi),Gi=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.rtpRecorder=null,r.rtpSequence=0,r.audioEncoder=null,r.noisedecoderNvmpWorker=null,r.hasNoiseNvmpDecoderInit=!1,r.initDecoderWorker(),r.rtpCnt=0,r.audioBuffer=new Uint8Array,r.addState(qi.STATE_GET_STREAMS,{activate:r.getStreams,finishTransition:r.onStreamConfigs}).addState(qi.STATE_SEND_VOICE,{activate:r.sendRtpVoice,finishTransition:r.onSendRtpVoice}).addTransition(qi.STATE_OPTIONS,qi.STATE_GET_STREAMS).addTransition(qi.STATE_GET_STREAMS,qi.STATE_TEARDOWN).addTransition(qi.STATE_GET_STREAMS,qi.STATE_SEND_VOICE).addTransition(qi.STATE_SEND_VOICE,qi.STATE_GET_STREAMS).addTransition(qi.STATE_STREAMS,qi.STATE_TEARDOWN).addTransition(qi.STATE_SEND_VOICE,qi.STATE_TEARDOWN).addTransition(qi.STATE_SEND_VOICE,qi.STATE_PAUSED).addTransition(qi.STATE_GET_STREAMS,qi.STATE_STREAMS),r.dataBuffer=new Uint8Array([]),r}return p(n,[{key:"initDecoderWorker",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.hasNoiseNvmpDecoderInit=!1,e.next=3,Ft();case 3:t=e.sent,n=t.libsWorker,r=t.libaudio,i=t.libaudioWasm,this.noisedecoderNvmpWorker=new Worker(n),this.noisedecoderNvmpWorker.postMessage({cmd:"init",scripts:[r],wasmBinary:i}),this.noisedecoderNvmpWorker.onmessage=function(e){var t=e.data,n=void 0===t?{}:t,r=n.hasInit;r?a.hasNoiseNvmpDecoderInit=!0:a.transformRtpBuffer(n.data,a.audioEncoder)};case 10:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){Mi.log("set source: ",e),this.reset(),this.endpoint=e,this.url=e.full}},{key:"onData",value:function(e){var t=m(this.dataBuffer,e),n=new DataView(t.buffer,t.byteOffset,t.byteLength),r=n.getUint8(0);if(36===r){var i=n.getUint16(2),a=i+4;if(!(t.length>=a))return void(this.dataBuffer=t);e=t.slice(0,a),this.dataBuffer=t.slice(a)}else{var o=t.findIndex((function(e){return 36===e}));-1!==o?(e=t.slice(0,o),this.dataBuffer=t.slice(o)):(e=t,this.dataBuffer=new Uint8Array([]))}var s=T(e);if("$"===s[0]){var c=e[1];this.rtp_channels.has(c)&&this.onRTP({packet:e.subarray(4),type:c}),s=T(this.dataBuffer),"$"!==s[0]&&0!==s.indexOf("RTSP")||this.onData(new Uint8Array([]))}else{var u;Mi.log("on data: ",s);try{u=this.parse(s,"RTSP")}catch(b){return b}if(!u)return;var l,f,h=u,d=h.body,p=void 0===d?{}:d,v=p.params,y=void 0===v?{}:v,g=y.event_type;switch(g){case"stream_finish":this.parent.stop(),f=qi.FINISH_REASON[y.reason],this.parent.error(f||oe.MEDIA_ERR_NETWORK);break;case"channel_preview_params":this.onStreamConfigs(u);break;case"stream_sequence":this.currentSeq=y.sequence;break;case"channel_stream_status":l=y.status&&y.status[0],f=qi.FINISH_REASON[l],f&&(this.parent.stop(),this.parent.error(f));break;case"stream_status":l=y.status,"finished"===l&&(this.parent.eventSource.dispatchEvent("ended"),this.parent.stop());default:break}}}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,pn(hn(n.prototype),"reset",this).call(this);case 2:this.dataBuffer=new Uint8Array([]),this.receivedSeq=0,this.currentSeq=0;case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"parse",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RTSP",n=e.match(/\scontent-length:\s*(\d*)\s/i),r=0;if(n&&n.length>=2&&/^\d+$/.test(n[1]))r=parseInt(n[1]);else{if(!/content-length: \s*0$/i.test(e))return{};r=0}var i=e.split("\r\n\r\n"),a=i[1]||"";if(a.length<r)return{};var o=this.messageBuilder[t].parse(i[0]);if(r){try{a=JSON.parse(a)}catch(s){}o.body=a}else o.body="";return Yi.log("parsed data: ",o),o}},{key:"sendMultitrans",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i="MULTITRANS",a={"Content-Type":"application/json"};return this.sessionId&&(a["X-Session-Id"]=this.sessionId),Object.assign(a,r),this.sendRequest(i,e,a,t).then((function(e){Mi.log("on multitrans\n",e);var t=e.body,r=void 0===t?{}:t;return n.errorException(r)?null:e}))}},{key:"sendOptions",value:function(){this.reset(),this.started=!0,this.cSeq=0;var e=this.endpoint.basename.split(".")[0],t="rtsp://".concat(this.endpoint.host,"/multitrans");return this.sendMultitrans(t,{type:"request",seq:0,params:{tums_multitrans_connect:{session_id:e,user_type:"player"}}})}},{key:"onOptions",value:function(e){this.transitionTo(qi.STATE_GET_STREAMS)}},{key:"getStreams",value:function(){return this.sendMultitrans(this.url,{type:"request",seq:0,params:{method:"get",talk:{mode:this.parent.options.mode||"aec",channel:0}}},{"X-Data-Window-Size":Bi})}},{key:"onStreamConfigs",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,u,l,f,h;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t){e.next=2;break}return e.abrupt("return");case 2:if(n=t.body,r=void 0===n?{}:n,i=r.params,a=void 0===i?{}:i,!this.errorException(r)){e.next=6;break}return e.abrupt("return");case 6:this.sessionId=a["session_id"],this.sdp=new Wn,this.timeOffset=0,this.lastTimestamp=0,o={},o.type="audio",o.port=0,o.proto="",o.fmt=[8],s="G711alaw",o.ptype=w.string_map[s],u=c(o.fmt);try{for(u.s();!(l=u.n()).done;)f=l.value,this.sdp.mediaMap[f]=o}catch(d){u.e(d)}finally{u.f()}this.sdp.media[o.type]=o,this.rtpBuffer[o.fmt[0]]=[],this.useRTPChannel(0),this.useRTPChannel(1),this.parent.sampleQueues[w.H265]=[],this.parent.sampleQueues[w.H264]=[],this.parent.sampleQueues[w.G711A]=[],this.rtpFactory=new Dn(this.sdp),h=this.transport.socket(),h.initDataChannel(),this.transitionTo(qi.STATE_SEND_VOICE);case 30:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onSendRtpVoice",value:function(){}},{key:"sendRtpVoice",value:function(){var e=this;Fr.get((function(t){t.rec?(e.rtpRecorder=t.rec,e.startRecorder()):e.parent.error(Wi[t.error.name])}))}},{key:"startRecorder",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpRecorder.start(),t=new rr["PCMA"](this.parent.audioWasm,Fi),this.audioEncoder=t.encodeA.bind(t),this.rtpRecorder.audioTatch=function(){n.sendRtpData(n.audioEncoder)};case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"sendRtpData",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=new FileReader,r=this,n.onload=function(e){var n=e.target.result,i=2048,a=new Uint8Array([].concat(Le(r.audioBuffer),Le(new Uint8Array(n))));if(a.length>0)for(var o=new Uint8Array(i),s=0,c=0;c<a.byteLength;c++)o[s++]=a[c],(c+1)%i===0&&(r.noiseSet(o,t),o=a.byteLength-c-1>=i?new Uint8Array(i):new Uint8Array(a.byteLength-c-1),s=0),c+1===a.byteLength&&(c+1)%i!==0&&(r.audioBuffer=o)},n.readAsArrayBuffer(this.rtpRecorder.getPcmData());case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"noiseSet",value:function(e,t){var n=t(e);this.noisedecoderNvmpWorker.postMessage({data:n,samplerate:8e3,decoderType:"_decodeG711a"})}},{key:"transformRtpBuffer",value:function(){var e=l(regeneratorRuntime.mark((function e(t,n){var r,i,a,o,s,c,u;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(r=n(t),i=new Uint8Array(r),a=new ArrayBuffer(16+i.length),o=new DataView(a),s=0,o.setUint8(s,36),s+=1,o.setUint8(s,1),s+=1,c=1036,o.setUint16(s,c),s+=2,o.setUint8(s,128),s+=1,o.setUint8(s,136),s+=1,o.setUint16(s,this.rtpCnt),s+=2,o.setUint32(s,320*this.rtpCnt),this.rtpCnt++,s+=4,s+=4,u=0;u<i.length;u++,s+=1)o.setUint8(s,i[u],!0);this.sendRtp(a);case 24:case"end":return e.stop()}}),e,this)})));function t(t,n){return e.apply(this,arguments)}return t}()},{key:"sendRtp",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=17;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t,"rtpVocie");case 12:return n=e.sent,r=this.parse(n,"RTSP"),e.abrupt("return",r);case 17:return e.abrupt("return",Promise.reject("No transport attached"));case 18:case"end":return e.stop()}}),e,this,[[1,6]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"sendPause",value:function(){return Promise.resolve()}},{key:"sendPlay",value:function(){return Promise.resolve()}},{key:"sendHeartbeat",value:function(){var e={type:"notification"};this.sendMultitrans(this.url,e)}},{key:"sendStop",value:function(){return this.currentState.name===qi.STATE_SEND_VOICE?this.sendMultitrans(this.url,{type:"request",seq:0,params:{method:"do",stop:"null"}}):Promise.resolve()}},{key:"updateReceivedSeq",value:function(e){if(this.currentState.name===qi.STATE_STREAMS&&(e=parseInt(e),e-this.receivedSeq>=Bi/2)){var t={type:"notification",params:{event_type:"stream_sequence"}},n={"X-Data-Received":e};this.sendMultitrans(this.url,t,n),this.receivedSeq=e}}},{key:"errorException",value:function(e){var t=e.type,n=e.params,r=void 0===n?{}:n;if("response"===t&&0!==r["error_code"]){var i=Hi[r["error_code"]]||"CLOUD_ERR_STREAM";return this.parent.error(oe[i]),void this.transitionTo(qi.STATE_TEARDOWN)}return!1}},{key:"destroy",value:function(){return this.rtpRecorder&&(this.rtpRecorder.clear(),this.rtpRecorder.stop()),this.sendStop()}}]),n}(qi),Yi=re("rtsp:stream"),Ki=function(e){Tn(n,e);var t=_n(n);function n(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flush:10};return h(this,n),e=t.call(this,r),e.options.useMultitrans?e.clientSM=new Gi(fn(e)):e.clientSM=new zi(fn(e)),e.clientSM.ontracks=function(t){e.eventSource.dispatchEvent("tracks",t),e.startStreamFlush()},e.audioWasm=null,e.heartbeatInterval=0,e.sampleQueues={},e}return p(n,[{key:"initAudioWasm",value:function(){var e=this;At.a.getItem("audio.wasm").then((function(e){return WebAssembly.instantiate(e,Fi)})).then((function(t){e.audioWasm=t}))}},{key:"startVoiceIntercom",value:function(){var e=l(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.options.url=t,e.next=3,this.initAudioWasm();case 3:this.start();case 4:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){Yi.log("RTSPClient source: ",e),pn(hn(n.prototype),"setSource",this).call(this,e),this.clientSM.setSource(e)}},{key:"attachTransport",value:function(e){pn(hn(n.prototype),"attachTransport",this).call(this,e),this.clientSM.transport=e}},{key:"detachTransport",value:function(){pn(hn(n.prototype),"detachTransport",this).call(this),this.clientSM.transport=null}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.reset();case 2:this.sampleQueues={},clearInterval(this.heartbeatInterval);case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.destroy();case 2:return clearInterval(this.heartbeatInterval),e.abrupt("return",pn(hn(n.prototype),"destroy",this).call(this));case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){var e=this,t=this.options,r=t.socket||t.url;this.setSource(hr.parse(t.url));var i=new Er(t.type,{socket:r});return this.attachTransport(i),this.clientSM.onRTSPConfig=function(t){e.eventSource.dispatchEvent("rtspConfig",t),e.startStreamFlush()},pn(hn(n.prototype),"start",this).call(this),this.transport?this.transport.ready.then((function(){return e.clientSM.start()})):Promise.reject("no transport attached")}},{key:"stop",value:function(){return this.clientSM.stop(),pn(hn(n.prototype),"stop",this).call(this)}},{key:"play",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.play().then((function(){n.paused=!1,t&&t(),clearInterval(n.heartbeatInterval)}));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"pause",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.pause().then((function(){n.paused=!0,t&&t(),n.heartbeatInterval=setInterval((function(){n.clientSM.sendHeartbeat()}),5e3)}));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onData",value:function(e){this.clientSM.onData(e)}},{key:"onConnected",value:function(){this.clientSM.onConnected(),pn(hn(n.prototype),"onConnected",this).call(this)}},{key:"onDisconnected",value:function(){pn(hn(n.prototype),"onDisconnected",this).call(this),this.clientSM.onDisconnected(),clearInterval(this.heartbeatInterval)}},{key:"error",value:function(e){this.eventSource.dispatchEvent("audioError",new oe(e))}},{key:"onPlayerNotify",value:function(e){var t=e.seq,n=this.options.streamType;t&&"sdvod"===n&&this.clientSM.updateReceivedSeq(t)}}],[{key:"streamType",value:function(){return"dtspk"}}]),n}(Nr),Xi=Ki;n("dbb4");function Qi(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qi(Object(n),!0).forEach((function(t){v(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qi(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Zi,Ji,ea,ta,na,ra="/tums",ia="v1",aa="playback",oa=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:aa,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ia;return"".concat(ra,"/").concat(t,"/").concat(n,"/").concat(e)},sa={suspendPlayback:"suspendPlayback",setPlaybackCfg:"setPlaybackCfg",deletePlaybackChn:"deletePlaybackChn",getCurrentTime:"getCurrentTime"},ca={url:{suspendPlayback:oa(sa.suspendPlayback),setPlaybackCfg:oa(sa.setPlaybackCfg),deletePlaybackChn:oa(sa.deletePlaybackChn),getCurrentTime:oa(sa.getCurrentTime,"systemConfig")},value:{suspendFlag:{play:0,pause:1}}},ua={ENAME:"error_code",ENONE:0,COMMON:{REQUEST_TIMEOUT:-82432,NETWORK_ERROR:-82428,UNKNOWN_CODE:-82415},VIDEO:{VIDEO_SET_PLAYBACK_FAIL:-80706},zhCN:{"-82432":"操作超时","-82428":"网络异常","-82429":"服务器忙","-80125":"该账号已在其他终端登录,请重新登录","-82402":"用户重新登录","-82415":"未知错误","-80706":"设置回放失败"},codeMap:{"-82432":oe.errorTypes.COMMON_ERR_TIME_OUT,"-82428":oe.errorTypes.COMMON_ERR_NETWORK,"-82429":oe.errorTypes.COMMON_ERR_INTERNAL,"-80125":oe.errorTypes.COMMON_ERR_SESSION,"-82402":oe.errorTypes.COMMON_ERR_SESSION,"-82415":oe.errorTypes.COMMON_ERR_CUSTOM,"-80706":oe.errorTypes.LOCAL_ERR_CONFIG_PLAYBACK},translate:function(e){return Object.prototype.hasOwnProperty.call(ua.zhCN,"".concat(e))?ua.zhCN[e]:"".concat(e," is not a valid string")},tranToMediaErrorType:function(e){return ua.codeMap[e]?ua.codeMap[e]:oe.errorTypes.COMMON_ERR_CUSTOM}},la=ua,fa=re("client:rtsp"),ha=re("client:wsWatch"),da=12e3,pa=100,va=function(e){Tn(n,e);var t=_n(n);function n(e){return h(this,n),t.call(this,e)}return p(n)}(An(Error)),ma={"-82400":"CLOUD_ERR_PARAM","-82401":"CLOUD_ERR_PERMISSION","-82414":"CLOUD_ERR_SERVER","-80702":"COMMON_ERR_SESSION","-80731":"CLOUD_ERR_TOKEN","-80304":"CLOUD_ERR_DEVID","-80732":"CLOUD_ERR_BANDWIDTH","-20002":"DEVICE_ERR_CHN_OFFLINE","-20571":"DEVICE_ERR_CHN_OFFLINE","-52405":"CLOUD_ERR_STREAM_LIMIT","-52413":"DEVICE_ERR_CHN_OFFLINE"},ya=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this),r.parent=e,r.transport=null,r.payParser=new Fn,r.rtp_channels=new Set,r.ontracks=null,r.messageBuilder=new jr(jr.RTSP_1_0),r.isPlaying=!1,r.getAudioTime=0,r.tempVedioData=[],r.tempAudioData=[],r.addState(n.STATE_INITIAL,{}).addState(n.STATE_OPTIONS,{activate:r.sendOptions,finishTransition:r.onOptions}).addState(n.STATE_DESCRIBE,{activate:r.sendDescribe,finishTransition:r.onDescribe}).addState(n.STATE_SETUP,{activate:r.sendSetup,finishTransition:r.onSetup}).addState(n.STATE_STREAMS,{}).addState(n.STATE_TEARDOWN,{activate:function(){r.started=!1},finishTransition:function(){return r.transitionTo(n.STATE_INITIAL)}}).addState(n.STATE_PAUSED,{activate:r.sendPause,finishTransition:r.onPause}).addState(n.STATE_PLAY,{activate:r.sendPlay,finishTransition:r.onPlay}).addTransition(n.STATE_INITIAL,n.STATE_OPTIONS).addTransition(n.STATE_INITIAL,n.STATE_TEARDOWN).addTransition(n.STATE_OPTIONS,n.STATE_DESCRIBE).addTransition(n.STATE_DESCRIBE,n.STATE_SETUP).addTransition(n.STATE_SETUP,n.STATE_STREAMS).addTransition(n.STATE_TEARDOWN,n.STATE_INITIAL).addTransition(n.STATE_STREAMS,n.STATE_PAUSED).addTransition(n.STATE_PAUSED,n.STATE_STREAMS).addTransition(n.STATE_PAUSED,n.STATE_PLAY).addTransition(n.STATE_PLAY,n.STATE_STREAMS).addTransition(n.STATE_PLAY,n.STATE_TEARDOWN).addTransition(n.STATE_STREAMS,n.STATE_TEARDOWN).addTransition(n.STATE_PAUSED,n.STATE_TEARDOWN).addTransition(n.STATE_SETUP,n.STATE_TEARDOWN).addTransition(n.STATE_DESCRIBE,n.STATE_TEARDOWN).addTransition(n.STATE_OPTIONS,n.STATE_TEARDOWN),r.reset(),r.shouldReconnect=!1,r}return p(n,[{key:"destroy",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.parent=null;case 1:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSource",value:function(e){this.reset(),this.endpoint=e,this.url=e.full}},{key:"onConnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.rtpFactory&&(this.rtpFactory=null),this.shouldReconnect&&this.start();case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"onDisconnected",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.reset(),this.shouldReconnect=!0,e.next=4,this.transitionTo(n.STATE_TEARDOWN);case 4:return e.next=6,this.transitionTo(n.STATE_INITIAL);case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){return this.currentState.name!==n.STATE_STREAMS?this.transitionTo(n.STATE_OPTIONS):Promise.resolve()}},{key:"onData",value:function(e){var t=e[1];this.rtp_channels.has(t)&&this.onRTP({packet:e.subarray(4),type:t})}},{key:"useRTPChannel",value:function(e){this.rtp_channels.add(e)}},{key:"forgetRTPChannel",value:function(e){this.rtp_channels.delete(e)}},{key:"stop",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.started&&(this.sendTeardown(),this.transport&&this.transport.stop()),this.shouldReconnect=!1;case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(t in this.authenticator="",this.methods=[],this.tracks=[],this.rtpBuffer={},this.streams)this.streams[t].reset();if(this.streams={},this.contentBase="",!this.currentState){e.next=15;break}if(this.currentState.name==n.STATE_INITIAL){e.next=13;break}return e.next=11,this.transitionTo(n.STATE_TEARDOWN);case 11:return e.next=13,this.transitionTo(n.STATE_INITIAL);case 13:e.next=17;break;case 15:return e.next=17,this.transitionTo(n.STATE_INITIAL);case 17:this.sdp=null,this.interleaveChannelIndex=0,this.session=null,this.timeOffset={},this.lastTimestamp=0;case 22:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"reconnect",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.reset();case 2:if(this.currentState.name==n.STATE_INITIAL){e.next=8;break}return e.next=5,this.transitionTo(n.STATE_TEARDOWN);case 5:return e.abrupt("return",this.transitionTo(n.STATE_OPTIONS));case 8:return e.abrupt("return",this.transitionTo(n.STATE_OPTIONS));case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"supports",value:function(e){return this.methods.includes(e)}},{key:"parse",value:function(e){var t=e.split("\r\n\r\n"),n=this.messageBuilder.parse(t[0]),r=Number(n.headers["content-length"]);if(r){var i=t[1];i&&"application/json"===n.headers["content-type"]&&(i=JSON.parse(i)),n.body=i}else n.body="";return Ta.log("parsed data: ",n),n}},{key:"sendRequest",value:function(e,t){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return this.cSeq++,Object.assign(i,{CSeq:this.cSeq,"User-Agent":n.USER_AGENT}),this.authenticator&&(i["Authorization"]=this.authenticator(e)),this.send(this.messageBuilder.build(e,t,i,a),e).catch((function(n){if(n instanceof va)return r.sendRequest(e,t,i,a);throw n}))}},{key:"send",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s,u,l,f,h,d,p,v,m,y,g=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=38;break}return e.prev=1,e.next=4,this.transport.ready;case 4:e.next=10;break;case 6:throw e.prev=6,e.t0=e["catch"](1),this.onDisconnected(),e.t0;case 10:return e.next=12,this.transport.send(t);case 12:if(n=e.sent,r=this.parse(n),401!==r.code){e.next=32;break}if(fa.log("www-authenticate header: ",r.headers["www-authenticate"]),i=r.headers["www-authenticate"],a=i.substring(0,i.indexOf(" ")),i=i.substr(a.length+1),o=i.split(","),s=this.parent.endpoint,s.user&&s.pass){e.next=30;break}return e.prev=22,e.next=25,this.parent.queryCredentials.call(this.parent);case 25:e.next=30;break;case 27:throw e.prev=27,e.t1=e["catch"](22),new va;case 30:if("digest"==a.toLowerCase()){u={},l=c(o);try{for(l.s();!(f=l.n()).done;)h=f.value,d=h.trim(),p=d.split("="),v=gn(p,2),m=v[0],y=v[1],u[m]=y.substr(1,y.length-2)}catch(b){l.e(b)}finally{l.f()}this.authenticator=function(e){var t=g.parent.endpoint,n=Oi("".concat(t.user,":").concat(u.realm,":").concat(t.pass)),r=Oi("".concat(e,":").concat(t.urlpath)),i=Oi("".concat(n,":").concat(u.nonce,":").concat(r)),a="";return'Digest username="'.concat(t.user,'", nonce="').concat(u.nonce,'", uri="').concat(t.urlpath,'", response="').concat(i,'"').concat(a)}}else this.authenticator=function(){return"Basic ".concat(btoa(g.parent.endpoint.auth))};throw new va(r);case 32:if(!(r.code>=300)){e.next=35;break}throw fa.error(r.statusLine),new Di({msg:"RTSP error: ".concat(r.code," ").concat(r.statusLine),parsed:r});case 35:return e.abrupt("return",r);case 38:return e.abrupt("return",Promise.reject("No transport attached"));case 39:case"end":return e.stop()}}),e,this,[[1,6],[22,27]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"setResolution",value:function(){}},{key:"sendOptions",value:function(){this.reset(),this.started=!0,this.cSeq=0;var e=this.url;return this.sendRequest("OPTIONS",e,{})}},{key:"onOptions",value:function(e){this.methods=e.headers["public"].split(",").map((function(e){return e.trim()})),this.transitionTo(n.STATE_DESCRIBE)}},{key:"sendTeardown",value:function(){var e="TEARDOWN";return this.sendRequest(e,"*")}},{key:"sendMultitrans",value:function(){}},{key:"onMultitrans",value:function(){}},{key:"sendDescribe",value:function(){var e=this;return this.sendRequest("DESCRIBE",this.url,{Accept:"application/sdp"}).then((function(t){return e.sdp=new Wn,e.sdp.parse(t.body).catch((function(){throw new Error("Failed to parse SDP")})).then((function(){return t}))}))}},{key:"onDescribe",value:function(e){if(fa.log("sdp data: ",e),fa.log("sdp: ",this.sdp),this.contentBase=e.headers["content-base"]||this.url,this.tracks=this.sdp.getMediaBlockList(),this.rtpFactory=new Dn(this.sdp),fa.log("SDP contained "+this.tracks.length+" track(s). Calling SETUP for each."),e.headers["session"]&&(this.session=e.headers["session"]),!this.tracks.length)throw new Error("No tracks in SDP");this.transitionTo(n.STATE_SETUP)}},{key:"sendSetup",value:function(){var e=this,t=[],n=this.sdp.getMediaBlock("video"),r=this.sdp.getMediaBlock("audio");Ta.log("video media block: ",n),Ta.log("audio media block: ",r),this.streams["video"]=new Ui(this,n,r);var i=this.streams["video"].start();return this.parent.sampleQueues[w.string_map[n.rtpmap[n.fmt[0]].name]]=[],r&&(this.parent.sampleQueues[w.string_map[r.rtpmap[r.fmt[0]].name]]=[]),this.rtpBuffer[n.fmt[0]]=[],r&&(this.rtpBuffer[r.fmt[0]]=[]),t.push(i.then((function(t){var n=t.track,i=t.data;fa.log("setup: ",n,i),r&&(e.timeOffset[r.fmt[0]]=0),e.timeOffset[n.fmt[0]]=0;try{var a,o=i.headers["rtp-info"].split(";"),s=c(o);try{for(s.s();!(a=s.n()).done;){var u=a.value,l=u.split("="),f=gn(l,2),h=f[0],d=f[1];"rtptime"===h&&(e.timeOffset[n.fmt[0]]=Number(d))}}catch(S){s.e(S)}finally{s.f()}}catch(E){}var p={timescale:0,scaleFactor:0};if(n.fmtp&&n.fmtp["sprop-parameter-sets"]){var v=n.fmtp["sprop-parameter-sets"].split(",");p={sps:y(v[0]),pps:y(v[1])}}else if(n.fmtp&&n.fmtp["config"]){var m=n.fmtp["config"];e.has_config="0"!=n.fmtp["cpresent"];var b="MPEG4-GENERIC"==n.rtpmap[n.fmt[0]].name;b?(p={config:Vn.parseAudioSpecificConfig(g(m))},e.payParser.aacparser.setConfig(p.config)):m&&(p={config:Vn.parseStreamMuxConfig(g(m))},e.payParser.aacparser.setConfig(p.config))}p.duration=e.sdp.sessionBlock.range?e.sdp.sessionBlock.range[1]-e.sdp.sessionBlock.range[0]:1,e.parent.seekable=p.duration>1;var T={track:n,audioTrack:r,offset:e.timeOffset[n.fmt[0]],type:w.string_map[n.rtpmap[n.fmt[0]].name],params:p,duration:p.duration};return T}))),Promise.all(t).then((function(t){Ta.log("setup res: ",t),e.ontracks&&e.ontracks(t)})).catch((function(t){fa.log("stop play: ",t),e.stop(),e.reset()}))}},{key:"onSetup",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"pause",value:function(){return this.currentState.name===n.STATE_STREAMS?this.transitionTo(n.STATE_PAUSED):Promise.resolve()}},{key:"sendPause",value:function(){this.streams["video"].sendPause()}},{key:"onPause",value:function(){this.isPlaying=!1}},{key:"play",value:function(){return this.currentState.name===n.STATE_PAUSED?this.transitionTo(n.STATE_PLAY):Promise.resolve()}},{key:"sendPlay",value:function(){return this.streams["video"].sendPlay(),Promise.resolve()}},{key:"onPlay",value:function(){this.transitionTo(n.STATE_STREAMS)}},{key:"sendPlaybackConfig",value:function(){}},{key:"onRTP",value:function(e){var t=this;if(this.rtpFactory){this.isPlaying||this.currentState.name===n.STATE_PAUSED||(this.isPlaying=!0,this.parent.eventSource.dispatchEvent("stream"));var r=this.rtpFactory.build(e.packet,this.sdp);if(r.type){r.utc_timestamp&&(this.timeOffset={},this.timeOffset[r.pt]=r.timestamp,this.lastTimestamp=r.utc_timestamp),this.timeOffset[r.pt]||(this.timeOffset[r.pt]=r.timestamp),this.timeOffset[r.pt]&&(r.timestamp-this.timeOffset[r.pt]<0||r.timestamp-this.timeOffset[r.pt]>9e5)&&(this.timeOffset[r.pt]=r.timestamp);var i=this.rtpBuffer[r.pt];i.push(r);var a=0,o=function(){var e=i.shift();if(a=parseInt(1e3*(t.lastTimestamp+(e.timestamp-t.timeOffset[e.pt])/9e4)),e.media){var n=t.payParser.parse(e);n&&t.parent.sampleQueues[e.type]&&(n.forEach((function(n){n.timestamp=a,e.isVideo()&&(n.seq=t.currentSeq)})),t.parent.feed(e.type,n))}};while(i.length)o();return{timestamp:a}}}}},{key:"video_refresh_thread",value:function(e){if(this.tempAudioData.length<3||this.tempVedioData.length<3)return e.type===w.G711A||e.type===w.AAC?(this.tempAudioData.push(e),{}):(this.tempVedioData.push(e),{});if(e.type===w.G711A||e.type===w.AAC)return this.tempAudioData.push(e),this.getAudioTime=this.tempAudioData[0].timestamp,this.tempAudioData.shift();this.tempVedioData.push(e);var t=this.getAudioTime-da<this.tempVedioData[0].timestamp<this.getAudioTime+da;return t?this.tempVedioData.shift():this.getAudioTime-da>this.tempVedioData[0].timestamp?(this.tempVedioData.shift(),{}):(this.tempVedioData[0].timestamp=this.getAudioTime,{})}},{key:"updateReceivedSeq",value:function(){}},{key:"sendHeartbeat",value:function(){this.sendRequest("OPTIONS",this.url,{})}},{key:"throwErrorByErrorCode",value:function(e){this.parent.error(la.tranToMediaErrorType(e))}}],[{key:"USER_AGENT",get:function(){return"SFRtsp 0.3"}},{key:"FINISH_REASON",get:function(){return{share_finish:oe.CLOUD_ERR_SHARE_FINISH,permission_deny:oe.CLOUD_ERR_PERMISSION,channel_offline:oe.DEVICE_ERR_CHN_OFFLINE,channel_invalid:oe.DEVICE_ERR_CHN_INVALID,internal_error:oe.COMMON_ERR_INTERNAL,password_changed:oe.DEVICE_ERR_PWD_CHANGED,media_encrypt_changed:oe.CLOUD_ERR_ENCRYPT_CHANGED,relay_lifetime_expired:oe.CLOUD_ERR_FREE,channel_talk_busy:oe.CLOUD_ERR_TALK_BUSY,unbind_device:oe.CLOUD_ERR_UNBIND,lack_bandwidth:oe.CLOUD_ERR_BANDWIDTH,offline:oe.DEVICE_ERR_CHN_OFFLINE}}},{key:"STATE_INITIAL",get:function(){return 1}},{key:"STATE_OPTIONS",get:function(){return 2}},{key:"STATE_DESCRIBE",get:function(){return 4}},{key:"STATE_SETUP",get:function(){return 8}},{key:"STATE_STREAMS",get:function(){return 16}},{key:"STATE_TEARDOWN",get:function(){return 32}},{key:"STATE_GET_STREAMS",get:function(){return 64}},{key:"STATE_PAUSED",get:function(){return 128}},{key:"STATE_PLAY",get:function(){return 256}}]),n}(Rr),ga=function(e){Tn(n,e);var t=_n(n);function n(e){var r;return h(this,n),r=t.call(this,e),r.addState(ya.STATE_GET_STREAMS,{activate:r.getStreams,finishTransition:r.onStreamConfigs}).addTransition(ya.STATE_OPTIONS,ya.STATE_GET_STREAMS).addTransition(ya.STATE_GET_STREAMS,ya.STATE_TEARDOWN).addTransition(ya.STATE_GET_STREAMS,ya.STATE_STREAMS).addTransition(ya.STATE_STREAMS,ya.STATE_TEARDOWN),r.dataBuffer=new Uint8Array([]),r.lastSetMultitransTime=0,r.lastGetWsTime=Number.MAX_SAFE_INTEGER,r.wsWatchIntervalId="",r}return p(n,[{key:"setSource",value:function(e){fa.log("set source: ",e),this.reset(),this.endpoint=e,this.url=e.full}},{key:"onData",value:function(e){this.lastGetWsTime=(new Date).getTime(),(e.byteLength&&36===e[0]||e.byteLength>=4&&"rtsp"===T(e.slice(0,4)).toLocaleLowerCase())&&(this.dataBuffer=new Uint8Array([]));var t=m(this.dataBuffer,e),n=new DataView(t.buffer,t.byteOffset,t.byteLength),r=n.getUint8(0);if(36===r){if(n.byteLength<4)return void(this.dataBuffer=t);var i=n.getUint16(2),a=i+4;if(!(t.length>=a))return void(this.dataBuffer=t);e=t.slice(0,a),this.dataBuffer=t.slice(a)}else{var o=t.findIndex((function(e){return 36===e}));-1!==o?(e=t.slice(0,o),this.dataBuffer=t.slice(o)):(e=t,this.dataBuffer=new Uint8Array([]))}if(e.byteLength){if(36===e[0]){var s=e[1];this.rtp_channels.has(s)&&this.onRTP({packet:e.subarray(4),type:s})}else{var c,u=T(e);fa.log("on data: ",u);try{if(c=this.parse(u),!c.body)return void(this.dataBuffer=e)}catch(b){return this.dataBuffer=e,b}if(!c)return;var l,f,h=c,d=h.body,p=void 0===d?{}:d,v=p.params,y=void 0===v?{}:v,g=y.event_type;switch(g){case"stream_finish":this.parent.stop(),f=ya.FINISH_REASON[y.reason],this.parent.error(f||oe.MEDIA_ERR_NETWORK);break;case"channel_preview_params":this.onStreamConfigs(c);break;case"stream_sequence":this.currentSeq=parseInt(y.sequence);break;case"channel_stream_status":l=y.status&&y.status[0],f=ya.FINISH_REASON[l],f&&(this.parent.stop(),this.parent.error(f));break;case"stream_status":l=y.status,"finished"===l&&(this.parent.eventSource.dispatchEvent("ended"),this.parent.stop());default:break}}(this.dataBuffer.byteLength&&36===this.dataBuffer[0]||this.dataBuffer.byteLength>=4&&"rtsp"===T(this.dataBuffer.slice(0,4)).toLocaleLowerCase())&&this.onData(this.dataBuffer)}}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,pn(hn(n.prototype),"reset",this).call(this);case 2:this.dataBuffer=new Uint8Array([]),this.receivedSeq=0,this.currentSeq=0,this.lastSetMultitransTime=0,this.lastGetWsTime=Number.MAX_SAFE_INTEGER,this.wsWatchIntervalId="",this.endWatchWsStatus();case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.sendStop();case 2:this.endWatchWsStatus(),pn(hn(n.prototype),"destroy",this).call(this);case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"parse",value:function(e){var t=e.match(/\scontent-length:\s*(\d*)\s/i),n=0;if(t&&t.length>=2&&/^\d+$/.test(t[1]))n=parseInt(t[1]);else{if(!/content-length: \s*0$/i.test(e))return{};n=0}var r=e.split("\r\n\r\n"),i=r[1]||"";if(i.length<n)return{};var a=this.messageBuilder.parse(r[0]);if(n){try{i=JSON.parse(i)}catch(o){}a.body=i}else a.body="";return Ta.log("parsed data: ",a),a}},{key:"sendMultitrans",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.lastSetMultitransTime=(new Date).getTime();var i="MULTITRANS",a={"Content-Type":"application/json"};return this.sessionId&&(a["X-Session-Id"]=this.sessionId),Object.assign(a,r),this.sendRequest(i,e,a,t).then((function(e){fa.log("on multitrans\n",e);var t=e.body,r=void 0===t?{}:t;return n.errorException(r)?null:e}))}},{key:"sendOptions",value:function(){this.reset(),this.started=!0,this.cSeq=0;var e=this.endpoint.basename.split(".")[0],t="rtsp://".concat(this.endpoint.host,"/multitrans");return this.sendMultitrans(t,{type:"request",seq:0,params:{tums_multitrans_connect:{session_id:e,user_type:"player"}}})}},{key:"onOptions",value:function(e){this.transitionTo(ya.STATE_GET_STREAMS)}},{key:"getStreams",value:function(){var e=this.parent.options,t=e.eventType,n=e.startTime,r=e.scale;return t=t||[],this.sendMultitrans(this.url,{type:"request",seq:0,params:{method:"get",playback:{client_id:0,channels:[0],scale:Sa.formatScale(r),start_time:String(Math.floor(n/1e3)),event_type:t}}},{"X-Data-Window-Size":pa})}},{key:"onStreamConfigs",value:function(e){if(e){var t=e.body,n=void 0===t?{}:t,r=n.params,i=void 0===r?{}:r;if(!this.errorException(n)){this.sessionId=i.session_id,this.sdp=new Wn;var a=i["av_config"][0],o={},s={};o.type="video",o.port=0,o.proto="",o.fmt=[96],o.ptype=w.string_map[a.video_codec];var u,l=c(o.fmt);try{for(l.s();!(u=l.n()).done;){var f=u.value;this.sdp.mediaMap[f]=o}}catch(m){l.e(m)}finally{l.f()}this.sdp.media[o.type]=o,s.type="audio",s.port=0,s.proto="",s.fmt=[parseInt(a.audio_sampling_rate)],s.ptype=w.string_map[a.audio_codec];var h,d=c(s.fmt);try{for(d.s();!(h=d.n()).done;){var p=h.value;this.sdp.mediaMap[p]=s}}catch(m){d.e(m)}finally{d.f()}this.sdp.media[s.type]=s,this.timeOffset={},this.lastTimestamp={},this.useRTPChannel(0),this.useRTPChannel(1),this.rtpBuffer[o.fmt[0]]=[],this.rtpBuffer[s.fmt[0]]=[],this.parent.sampleQueues[w.H265]=[],this.parent.sampleQueues[w.H264]=[],this.parent.sampleQueues[w.G711A]=[],this.rtpFactory=new Dn(this.sdp);var v=this.transport.socket();v.initDataChannel(),this.onRTSPConfig&&this.onRTSPConfig(a),this.transitionTo(ya.STATE_STREAMS),this.startWatchWsStatus()}}}},{key:"sendPlaybackConfig",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.startTime,r=t.endTime,i=t.scale,t.eventType,a=t.currentTime,o=i<0?"-":"",n=n||a,s={type:"request",seq:0,params:{method:"do",play:{start_time:n?parseInt(n/1e3)+"":void 0,end_time:r?parseInt(r/1e3)+"":void 0,scale:i?o+Nr.formatScale(i):void 0}}},this.sendMultitrans(this.url,s),this.currentState.name!==ya.STATE_PAUSED){e.next=7;break}return e.abrupt("return",this.transitionTo(ya.STATE_STREAMS));case 7:return e.abrupt("return",Promise.resolve());case 8:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"sendPause",value:function(){return Promise.resolve()}},{key:"sendPlay",value:function(){return Promise.resolve()}},{key:"sendStop",value:function(){return this.currentState.name===ya.STATE_STREAMS||this.currentState.name===ya.STATE_PAUSED?this.sendMultitrans(this.url,{type:"request",seq:0,params:{method:"do",stop:"null"}}):Promise.resolve()}},{key:"startWatchWsStatus",value:function(){var e=this;this.endWatchWsStatus(),this.wsWatchIntervalId=setInterval((function(){(new Date).getTime()-e.lastSetMultitransTime>=2e3&&e.currentState.name===ya.STATE_STREAMS&&e.sendHeartbeat(),(new Date).getTime()-e.lastGetWsTime>=6e4&&e.currentState.name===ya.STATE_STREAMS&&(e.endWatchWsStatus(),ha.log("ws stop for a long time",(new Date).getTime(),e.lastGetWsTime),e.parent.error(oe.MEDIA_ERR_TRANSPORT))}),2e3)}},{key:"endWatchWsStatus",value:function(){clearInterval(this.wsWatchIntervalId)}},{key:"sendHeartbeat",value:function(){var e={type:"notification"};this.sendMultitrans(this.url,e)}},{key:"updateReceivedSeq",value:function(e){if(this.currentState.name===ya.STATE_STREAMS&&(e=parseInt(e),e-this.receivedSeq>=pa/2)){var t={type:"notification",params:{event_type:"stream_sequence"}},n={"X-Data-Received":e};this.sendMultitrans(this.url,t,n),this.receivedSeq=e}}},{key:"errorException",value:function(e){var t=e.type,n=e.params,r=void 0===n?{}:n;if("response"===t&&0!==r["error_code"]){var i=ma[r["error_code"]]||"CLOUD_ERR_STREAM";return this.parent.error(oe[i]),void this.transitionTo(ya.STATE_TEARDOWN)}return!1}}]),n}(ya),ba=function(e){Tn(n,e);var t=_n(n);function n(){return h(this,n),t.apply(this,arguments)}return p(n,[{key:"destroy",value:function(){var e=this;return this.transport&&this.transport.stop(),new Promise((function(t,r){e.parent.requestor.post(ca.url.deletePlaybackChn,{id:[e.getIdParams()]}).then((function(i){var a=i.result,o=void 0===a?[]:a;o=o[0]||{},0===o.errorCode||o.errorCode===la.VIDEO.VIDEO_SET_PLAYBACK_FAIL?(pn(hn(n.prototype),"destroy",e).call(e),t()):(e.throwErrorByErrorCode(o.errorCode),r({error_code:o.errorCode}))})).catch((function(t){e.throwErrorByErrorCode(t.errorCode),r(t)}))}))}},{key:"sendPause",value:function(){var e=this;return new Promise((function(t,n){e.parent.requestor.post(ca.url.suspendPlayback,{id:[e.getIdParams()],suspendOrNot:ca.value.suspendFlag.pause}).then((function(r){var i=r.result,a=void 0===i?[]:i;a=a[0]||{},0===a.errorCode||a.errorCode===la.VIDEO.VIDEO_SET_PLAYBACK_FAIL?(fa.log("pause sdvod success"),t()):(e.throwErrorByErrorCode(a.errorCode),n({error_code:a.errorCode}))})).catch((function(t){e.throwErrorByErrorCode(t.error_code),n(t)}))}))}},{key:"sendPlay",value:function(){var e=this;return new Promise((function(t,n){e.parent.requestor.post(ca.url.suspendPlayback,{id:[e.getIdParams()],suspendOrNot:ca.value.suspendFlag.play}).then((function(r){var i=r.result,a=void 0===i?[]:i;a=a[0]||{},0===a.errorCode||a.errorCode===la.VIDEO.VIDEO_SET_PLAYBACK_FAIL?(fa.log("replay sdvod success"),t()):(fa.log("replay sdvod fail: "+a.errorCode),e.throwErrorByErrorCode(a.errorCode),n({error_code:a.errorCode}))})).catch((function(t){e.throwErrorByErrorCode(t.error_code),n(t)}))}))}},{key:"sendPlaybackConfig",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i,a,o,s=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.startTime,r=t.currentTime,i=t.endTime,a=t.scale,o=t.currentScale,e.next=3,new Promise((function(e,t){n||(n=r);var c={startTime:Math.floor(n/1e3),scale:Nr.formatScale(o)};void 0!==i&&null!==i&&Object.assign(c,{endTime:Math.floor(i/1e3)}),void 0===a||null===a||s.parent.options.useMultitrans||Object.assign(c,{scale:Nr.formatScale(a)}),s.parent.requestor.post(ca.url.setPlaybackCfg,$i({id:[s.getIdParams()]},c)).then((function(n){var r=n.result,i=void 0===r?[]:r;i=i[0]||{},0===i.errorCode||i.errorCode===la.VIDEO.VIDEO_SET_PLAYBACK_FAIL?(fa.log("replay sdvod success"),e()):(fa.log("replay sdvod fail: "+i.errorCode),s.throwErrorByErrorCode(i.errorCode),t({error_code:i.errorCode}))})).catch((function(e){s.throwErrorByErrorCode(e.error_code),t(e)}))}));case 3:if(this.currentState.name!==ya.STATE_PAUSED){e.next=5;break}return e.abrupt("return",this.transitionTo(ya.STATE_STREAMS));case 5:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onRTP",value:function(e){var t=pn(hn(n.prototype),"onRTP",this).call(this,e);if(t&&t.timestamp&&this.parent.options.endTime){var r=t.timestamp,i=this.parent.options.endTime;i<=r&&(this.parent.eventSource.dispatchEvent("ended"),this.parent.stop())}}},{key:"getIdParams",value:function(){var e={videoDevId:this.parent.options.videoDevId,sessionId:this.parent.options.videoSessionId};return this.parent.options.storageDevId&&Object.assign(e,{storageDevId:this.parent.options.storageDevId}),e}},{key:"sendHeartbeat",value:function(){this.sendRequest("OPTIONS",this.url,{})}}]),n}(ya),Ta=re("rtsp:stream"),Sa=function(e){Tn(n,e);var t=_n(n);function n(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flush:10};return h(this,n),e=t.call(this,r),"sdvod"!==e.options.streamType?e.clientSM=new ya(fn(e)):"sdvod"!==e.options.streamType||e.options.useMultitrans?"sdvod"===e.options.streamType&&e.options.useMultitrans&&(e.clientSM=new ga(fn(e))):e.clientSM=new ba(fn(e)),e.requestor=r.requestor,e.clientSM.ontracks=function(t){e.eventSource.dispatchEvent("tracks",t),e.startStreamFlush()},e.heartbeatInterval=0,e.sampleQueues={},e}return p(n,[{key:"setSource",value:function(e){Ta.log("RTSPClient source: ",e),pn(hn(n.prototype),"setSource",this).call(this,e),this.clientSM.setSource(e)}},{key:"attachTransport",value:function(e){pn(hn(n.prototype),"attachTransport",this).call(this,e),this.clientSM.transport=e}},{key:"detachTransport",value:function(){pn(hn(n.prototype),"detachTransport",this).call(this),this.clientSM.transport=null}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.reset();case 2:this.sampleQueues={},clearInterval(this.heartbeatInterval);case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.destroy();case 2:return clearInterval(this.heartbeatInterval),e.abrupt("return",pn(hn(n.prototype),"destroy",this).call(this));case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"start",value:function(){var e=this,t=this.options,r=t.socket||t.url;this.setSource(hr.parse(t.url));var i=new Er(t.type,{socket:r});return this.attachTransport(i),this.clientSM.onRTSPConfig=function(t){e.eventSource.dispatchEvent("rtspConfig",t),e.startStreamFlush()},pn(hn(n.prototype),"start",this).call(this),this.transport?this.transport.ready.then((function(){return e.clientSM.start()})):Promise.reject("no transport attached")}},{key:"stop",value:function(){return this.clientSM.stop(),pn(hn(n.prototype),"stop",this).call(this)}},{key:"play",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.clientSM.play().then((function(){n.paused=!1,t&&t(),clearInterval(n.heartbeatInterval)}));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"pause",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var r,i,a=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(r=this.clientSM.currentState,r&&r.name===ya.STATE_STREAMS){e.next=3;break}return e.abrupt("return");case 3:if(i=this.options.streamType,"video"!==i){e.next=9;break}pn(hn(n.prototype),"stop",this).call(this),t&&t(),e.next=11;break;case 9:return e.next=11,this.clientSM.pause().then((function(){a.paused=!0,t&&t(),a.heartbeatInterval=setInterval((function(){a.clientSM.sendHeartbeat()}),4e3)}));case 11:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"setResolution",value:function(e){var t=this.clientSM.currentState;!t||t.name<=ya.STATE_SETUP||(this.detachTransport(),this.options.url=e,this.start())}},{key:"setPlaybackConfig",value:function(e){var t=this;return this.clientSM.sendPlaybackConfig(e).then((function(){for(var e in t.paused=!1,clearInterval(t.heartbeatInterval),t.sampleQueues)t.sampleQueues[e]=[]}))}},{key:"onData",value:function(){var e=l(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("reconnect"!==t){e.next=6;break}return e.next=3,this.clientSM.onDisconnected();case 3:return clearInterval(this.heartbeatInterval),this.clientSM.start(),e.abrupt("return");case 6:this.clientSM.onData(t);case 7:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"onConnected",value:function(){this.clientSM.onConnected(),pn(hn(n.prototype),"onConnected",this).call(this)}},{key:"onDisconnected",value:function(){pn(hn(n.prototype),"onDisconnected",this).call(this),this.clientSM.onDisconnected(),clearInterval(this.heartbeatInterval)}},{key:"error",value:function(e){this.eventSource.dispatchEvent("error",new oe(e))}},{key:"onPlayerNotify",value:function(e){var t=e.seq,n=this.options.streamType;t&&"sdvod"===n&&this.clientSM.updateReceivedSeq(t)}}],[{key:"streamType",value:function(){return"rtsp"}}]),n}(Nr),Ea=Sa,_a=(n("5377"),function(){function e(){h(this,e)}return p(e,null,[{key:"init",value:function(){var t;for(t in e.types={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[]},e.types)e.types.hasOwnProperty(t)&&(e.types[t]=[t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2),t.charCodeAt(3)]);var n=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),r=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]);e.HDLR_TYPES={video:n,audio:r};var i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),a=new Uint8Array([0,0,0,0,0,0,0,0]);e.STTS=e.STSC=e.STCO=a,e.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),e.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),e.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),e.STSD=new Uint8Array([0,0,0,0,0,0,0,1]);var o=new Uint8Array([105,115,111,109]),s=new Uint8Array([97,118,99,49]),c=new Uint8Array([0,0,0,1]);e.FTYP=e.box(e.types.ftyp,o,c,o,s),e.DINF=e.box(e.types.dinf,e.box(e.types.dref,i))}},{key:"box",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i,a=8,o=n.length,s=o;while(o--)a+=n[o].byteLength;for(i=new Uint8Array(a),i[0]=a>>24&255,i[1]=a>>16&255,i[2]=a>>8&255,i[3]=255&a,i.set(e,4),o=0,a=8;o<s;++o)i.set(n[o],a),a+=n[o].byteLength;return i}},{key:"hdlr",value:function(t){return e.box(e.types.hdlr,e.HDLR_TYPES[t])}},{key:"mdat",value:function(t){return e.box(e.types.mdat,t)}},{key:"mdhd",value:function(t,n){return e.box(e.types.mdhd,new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,t>>24&255,t>>16&255,t>>8&255,255&t,n>>24,n>>16&255,n>>8&255,255&n,85,196,0,0]))}},{key:"mdia",value:function(t){return e.box(e.types.mdia,e.mdhd(t.timescale,t.duration),e.hdlr(t.type),e.minf(t))}},{key:"mfhd",value:function(t){return e.box(e.types.mfhd,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t]))}},{key:"minf",value:function(t){return"audio"===t.type?e.box(e.types.minf,e.box(e.types.smhd,e.SMHD),e.DINF,e.stbl(t)):e.box(e.types.minf,e.box(e.types.vmhd,e.VMHD),e.DINF,e.stbl(t))}},{key:"moof",value:function(t,n,r){return e.box(e.types.moof,e.mfhd(t),e.traf(r,n))}},{key:"moov",value:function(t,n,r){var i=t.length,a=[];while(i--)a[i]=e.trak(t[i]);return e.box.apply(null,[e.types.moov,e.mvhd(r,n)].concat(a).concat(e.mvex(t)))}},{key:"mvex",value:function(t){var n=t.length,r=[];while(n--)r[n]=e.trex(t[n]);return e.box.apply(null,[e.types.mvex].concat(r))}},{key:"mvhd",value:function(t,n){var r=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,t>>24&255,t>>16&255,t>>8&255,255&t,n>>24&255,n>>16&255,n>>8&255,255&n,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return e.box(e.types.mvhd,r)}},{key:"sdtp",value:function(t){var n,r,i=t.samples||[],a=new Uint8Array(4+i.length);for(r=0;r<i.length;r++)n=i[r].flags,a[r+4]=n.dependsOn<<4|n.isDependedOn<<2|n.hasRedundancy;return e.box(e.types.sdtp,a)}},{key:"stbl",value:function(t){return e.box(e.types.stbl,e.stsd(t),e.box(e.types.stts,e.STTS),e.box(e.types.stsc,e.STSC),e.box(e.types.stsz,e.STSZ),e.box(e.types.stco,e.STCO))}},{key:"avc1",value:function(t){var n,r,i,a=[],o=[];for(n=0;n<t.sps.length;n++)r=t.sps[n],i=r.byteLength,a.push(i>>>8&255),a.push(255&i),a=a.concat(Array.prototype.slice.call(r));for(n=0;n<t.pps.length;n++)r=t.pps[n],i=r.byteLength,o.push(i>>>8&255),o.push(255&i),o=o.concat(Array.prototype.slice.call(r));var s=e.box(e.types.avcC,new Uint8Array([1,a[3],a[4],a[5],255,224|t.sps.length].concat(a).concat([t.pps.length]).concat(o))),c=t.width,u=t.height;return e.box(e.types.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,c>>8&255,255&c,u>>8&255,255&u,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,98,105,110,101,108,112,114,111,46,114,117,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),s,e.box(e.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])))}},{key:"esds",value:function(e){var t=e.config.byteLength,n=new Uint8Array(26+t+3);return n.set([0,0,0,0,3,23+t,0,1,0,4,15+t,64,21,0,0,0,0,0,0,0,0,0,0,0,5,t]),n.set(e.config,26),n.set([6,1,2],26+t),n}},{key:"mp4a",value:function(t){var n=t.audiosamplerate;return e.box(e.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,t.channelCount,0,16,0,0,0,0,n>>8&255,255&n,0,0]),e.box(e.types.esds,e.esds(t)))}},{key:"stsd",value:function(t){return"audio"===t.type?e.box(e.types.stsd,e.STSD,e.mp4a(t)):e.box(e.types.stsd,e.STSD,e.avc1(t))}},{key:"tkhd",value:function(t){var n=t.id,r=t.duration,i=t.width,a=t.height,o=t.volume;return e.box(e.types.tkhd,new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,n>>24&255,n>>16&255,n>>8&255,255&n,0,0,0,0,r>>24,r>>16&255,r>>8&255,255&r,0,0,0,0,0,0,0,0,0,0,0,0,o>>0&255,o%1*10>>0&255,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,i>>8&255,255&i,0,0,a>>8&255,255&a,0,0]))}},{key:"traf",value:function(t,n){var r=e.sdtp(t),i=t.id;return e.box(e.types.traf,e.box(e.types.tfhd,new Uint8Array([0,0,0,0,i>>24,i>>16&255,i>>8&255,255&i])),e.box(e.types.tfdt,new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n])),e.trun(t,r.length+16+16+8+16+8+8),r)}},{key:"trak",value:function(t){return t.duration=t.duration||4294967295,e.box(e.types.trak,e.tkhd(t),e.mdia(t))}},{key:"trex",value:function(t){var n=t.id;return e.box(e.types.trex,new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))}},{key:"trun",value:function(t,n){var r,i,a,o,s,c,u=t.samples||[],l=u.length,f=12+16*l,h=new Uint8Array(f);for(n+=8+f,h.set([0,0,15,1,l>>>24&255,l>>>16&255,l>>>8&255,255&l,n>>>24&255,n>>>16&255,n>>>8&255,255&n],0),r=0;r<l;r++)i=u[r],a=i.duration,o=i.size,s=i.flags,c=i.cts,h.set([a>>>24&255,a>>>16&255,a>>>8&255,255&a,o>>>24&255,o>>>16&255,o>>>8&255,255&o,s.isLeading<<2|s.dependsOn,s.isDependedOn<<6|s.hasRedundancy<<4|s.paddingValue<<1|s.isNonSync,61440&s.degradPrio,15&s.degradPrio,c>>>24&255,c>>>16&255,c>>>8&255,255&c],12+16*r);return e.box(e.types.trun,h)}},{key:"initSegment",value:function(t,n,r){e.types||e.init();var i,a=e.moov(t,n,r);return i=new Uint8Array(e.FTYP.byteLength+a.byteLength),i.set(e.FTYP),i.set(a,e.FTYP.byteLength),i}}]),e}()),ka=(n("4e82"),"mse"),wa=re(ka),Aa=function(){function e(t,n){var r=this;h(this,e),this.mediaSource=t.mediaSource,this.players=t.players,this.cleaning=!1,this.parent=t,this.queue=[],this.cleanResolvers=[],this.codec=n,this.cleanRanges=[],wa.debug("Use codec: ".concat(n)),this.sourceBuffer=this.mediaSource.addSourceBuffer(n),this.eventSource=new sr(this.sourceBuffer),this.eventSource.addEventListener("updatestart",(function(){r.cleaning&&wa.debug("".concat(r.codec," cleaning start"))})),this.eventSource.addEventListener("update",(function(){r.cleaning&&wa.debug("".concat(r.codec," cleaning update"))})),this.eventSource.addEventListener("updateend",(function(){if(r.cleaning){wa.debug("".concat(r.codec," cleaning end"));try{r.sourceBuffer.buffered.length&&r.players[0].currentTime<r.sourceBuffer.buffered.start(0)&&(r.players[0].currentTime=r.sourceBuffer.buffered.start(0))}catch(t){wa.error(t)}while(r.cleanResolvers.length){var e=r.cleanResolvers.shift();e()}if(r.cleaning=!1,r.cleanRanges.length)return void r.doCleanup()}r.feedNext()})),this.eventSource.addEventListener("error",(function(){wa.debug("Source buffer error: ".concat(r.mediaSource.readyState)),r.mediaSource.sourceBuffers.length&&r.mediaSource.removeSourceBuffer(r.sourceBuffer),r.parent.eventSource.dispatchEvent("error")})),this.eventSource.addEventListener("abort",(function(){wa.debug("Source buffer aborted: ".concat(r.mediaSource.readyState)),r.mediaSource.sourceBuffers.length&&r.mediaSource.removeSourceBuffer(r.sourceBuffer),r.parent.eventSource.dispatchEvent("error")})),this.sourceBuffer.updating||this.feedNext()}return p(e,[{key:"destroy",value:function(){this.eventSource.destroy(),this.clear(),this.queue=[],this.mediaSource.removeSourceBuffer(this.sourceBuffer)}},{key:"clear",value:function(){var e=this;this.queue=[];for(var t=[],n=function(n){e.cleaning=!0,t.push(new Promise((function(t){e.cleanResolvers.push(t),e.sourceBuffer.updating?e.sourceBuffer.onupdateend=function(){e.sourceBuffer&&e.sourceBuffer.remove(e.sourceBuffer.buffered.start(n),e.sourceBuffer.buffered.end(n)),t()}:(e.sourceBuffer.remove(e.sourceBuffer.buffered.start(n),e.sourceBuffer.buffered.end(n)),t())})))},r=0;r<this.sourceBuffer.buffered.length;++r)n(r);return Promise.all(t)}},{key:"setLive",value:function(e){this.is_live=e}},{key:"feedNext",value:function(){this.sourceBuffer.updating||this.cleaning||!this.queue.length||this.doAppend(this.queue.shift())}},{key:"doCleanup",value:function(){if(!this.cleanRanges.length)return this.cleaning=!1,void this.feedNext();var e=this.cleanRanges.shift();wa.debug("".concat(this.codec," remove range [").concat(e[0]," - ").concat(e[1],").\n \nUpdating: ").concat(this.sourceBuffer.updating,"\n ")),this.cleaning=!0,this.sourceBuffer.remove(e[0],e[1])}},{key:"initCleanup",value:function(){if(!this.sourceBuffer.buffered.length||this.sourceBuffer.updating||this.cleaning)this.feedNext();else{wa.debug("".concat(this.codec," cleanup"));for(var e=this.sourceBuffer.buffered.end(this.sourceBuffer.buffered.length-1)-2,t=0;t<this.sourceBuffer.buffered.length;++t){var n=this.sourceBuffer.buffered.start(t),r=this.sourceBuffer.buffered.end(t);this.players[0].currentTime<=n||e<=n||(e<=r&&e>=n?(wa.debug("Clear [".concat(n,", ").concat(e,"), leave [").concat(e,", ").concat(r,"]")),r=e,r!=n&&this.cleanRanges.push([n,r])):this.cleanRanges.push([n,r]))}this.doCleanup()}}},{key:"doAppend",value:function(e){var t=this.players[0].error;if(t){wa.error("Error occured: ".concat(Ra.ErrorNotes[t.code]));try{this.players.forEach((function(e){e.stop()})),this.mediaSource.endOfStream()}catch(n){wa.error(n)}this.parent.eventSource.dispatchEvent("error")}else try{this.sourceBuffer.appendBuffer(e)}catch(n){if("QuotaExceededError"===n.name)return wa.debug("".concat(this.codec," quota fail")),this.queue.unshift(e),void this.initCleanup();wa.error("Error occured while appending buffer. ".concat(n.name,": ").concat(n.message)),this.parent.eventSource.dispatchEvent("error")}}},{key:"feed",value:function(e){this.queue=this.queue.concat(e),!this.sourceBuffer||this.sourceBuffer.updating||this.cleaning||this.feedNext()}}]),e}(),Ra=function(){function e(t){h(this,e),this.players=t;var n=this.players.map((function(e,t){return e.onplaying=function(){n[t]=!0},e.onpause=function(){n[t]=!1},!e.paused}));this.playing=n,this.mediaSource=new MediaSource,this.eventSource=new sr(this.mediaSource),this.reset()}return p(e,[{key:"destroy",value:function(){this.reset(),this.eventSource.destroy(),this.mediaSource=null,this.eventSource=null}},{key:"play",value:function(){var e=this;this.players.forEach((function(t,n){t.paused&&!e.playing[n]&&(wa.debug("player ".concat(n,": play")),t.play())}))}},{key:"setLive",value:function(e){for(var t in this.buffers)this.buffers[t].setLive(e);this.is_live=e}},{key:"resetBuffers",value:function(){var e=this;this.players.forEach((function(t,n){!t.paused&&e.playing[n]&&(t.pause(),t.currentTime=0)}));var t,n=[],r=c(this.buffers.values());try{for(r.s();!(t=r.n()).done;){var i=t.value;n.push(i.clear())}}catch(a){r.e(a)}finally{r.f()}return Promise.all(n).then((function(){e.mediaSource.endOfStream(),e.mediaSource.duration=0,e.mediaSource.clearLiveSeekableRange(),e.play()}))}},{key:"clear",value:function(){var e=this;return this.reset(),this.players.forEach((function(t){t.src=URL.createObjectURL(e.mediaSource)})),this.setupEvents()}},{key:"setupEvents",value:function(){var e=this;return this.eventSource.clear(),this.resolved=!1,this.mediaReady=new Promise((function(t){e._sourceOpen=function(){wa.debug("Media source opened: ".concat(e.mediaSource.readyState)),e.resolved||(e.resolved=!0,t())},e._sourceEnded=function(){wa.debug("Media source ended: ".concat(e.mediaSource.readyState))},e._sourceClose=function(){wa.debug("Media source closed: ".concat(e.mediaSource.readyState)),e.resolved&&e.eventSource.dispatchEvent("sourceclosed")},e.eventSource.addEventListener("sourceopen",e._sourceOpen),e.eventSource.addEventListener("sourceended",e._sourceEnded),e.eventSource.addEventListener("sourceclose",e._sourceClose)})),this.mediaReady}},{key:"reset",value:function(){for(var e in this.ready=!1,this.buffers)this.buffers[e].destroy(),delete this.buffers[e];"open"==this.mediaSource.readyState&&(this.mediaSource.duration=0,this.mediaSource.endOfStream()),this.updating=!1,this.resolved=!1,this.buffers={}}},{key:"setCodec",value:function(e,t){var n=this;return this.mediaReady.then((function(){n.buffers[e]=new Aa(n,t),n.buffers[e].setLive(n.is_live)}))}},{key:"feed",value:function(e,t){this.buffers[e]&&this.buffers[e].feed(t)}}],[{key:"ErrorNotes",get:function(){var e;return e={},v(e,MediaError.MEDIA_ERR_ABORTED,"fetching process aborted by user"),v(e,MediaError.MEDIA_ERR_NETWORK,"error occurred when downloading"),v(e,MediaError.MEDIA_ERR_DECODE,"error occurred when decoding"),v(e,MediaError.MEDIA_ERR_SRC_NOT_SUPPORTED,"audio/video not supported"),e}},{key:"isSupported",value:function(e){return window.MediaSource&&window.MediaSource.isTypeSupported('video/mp4; codecs="'.concat(e.join(","),'"'))}}]),e}(),xa=re("remuxer:base"),Ca=1,Ia=function(){function e(t,n,r){h(this,e),this.timeOffset=0,this.timescale=t,this.scaleFactor=n,this.readyToDecode=!1,this.samples=[],this.seq=1,this.tsAlign=1}return p(e,[{key:"scaled",value:function(e){return e/this.scaleFactor}},{key:"unscaled",value:function(e){return e*this.scaleFactor}},{key:"remux",value:function(e){return!!e&&(this.samples.push({unit:e,pts:e.pts,dts:e.dts}),!0)}},{key:"setConfig",value:function(e){}},{key:"insertDscontinuity",value:function(){this.samples.push(null)}},{key:"init",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];this.initPTS=Math.min(e,this.samples[0].dts),this.initDTS=Math.min(t,this.samples[0].dts),xa.debug("Initial pts=".concat(this.initPTS," dts=").concat(this.initDTS," offset=").concat(this.unscaled(this.timeOffset))),this.initialized=n}},{key:"flush",value:function(){this.seq++,this.mp4track.len=0,this.mp4track.samples=[]}},{key:"getPayloadBase",value:function(){return this.readyToDecode&&this.initialized&&this.samples.length?(this.samples.sort(e.dtsSortFunc),!0):null}}],[{key:"MP4_TIMESCALE",get:function(){return 9e4}},{key:"getTrackID",value:function(){return Ca++}},{key:"toMS",value:function(e){return e/90}},{key:"dtsSortFunc",value:function(e,t){return e.dts-t.dts}},{key:"groupByDts",value:function(e){var t=function(e,t){return e.reduce((function(e,n){return(e[n[t]]=e[n[t]]||[]).push(n),e}),{})};return t(e,"dts")}}]),e}(),Pa=re("remuxer:aac"),Oa=function(e){Tn(n,e);var t=_n(n);function n(e){var r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h(this,n),r=t.call(this,e,i),r.codecstring=Ra.CODEC_AAC,r.units=[],r.initDTS=void 0,r.nextAacPts=void 0,r.lastPts=0,r.firstDTS=0,r.firstPTS=0,r.duration=a.duration||1,r.initialized=!1,r.mp4track={id:Ia.getTrackID(),type:"audio",fragmented:!0,channelCount:0,audiosamplerate:r.timescale,duration:0,timescale:r.timescale,volume:1,samples:[],config:"",len:0},a.config&&r.setConfig(a.config),r}return p(n,[{key:"setConfig",value:function(e){this.mp4track.channelCount=e.channels,this.mp4track.audiosamplerate=e.samplerate,this.mp4track.duration||(this.mp4track.duration=(this.duration?this.duration:1)*e.samplerate),this.mp4track.timescale=e.samplerate,this.mp4track.config=e.config,this.mp4track.codec=e.codec,this.timescale=e.samplerate,this.scaleFactor=Ia.MP4_TIMESCALE/e.samplerate,this.expectedSampleDuration=1024*this.scaleFactor,this.readyToDecode=!0}},{key:"remux",value:function(e){pn(hn(n.prototype),"remux",this).call(this,e)&&(this.mp4track.len+=e.getSize())}},{key:"getPayload",value:function(){if(!this.readyToDecode||!this.samples.length)return null;this.samples.sort((function(e,t){return e.dts-t.dts}));var e,t,n,r,i=new Uint8Array(this.mp4track.len),a=0,o=this.mp4track.samples;while(this.samples.length){var s=this.samples.shift();if(null===s){this.nextDts=void 0;break}var c=s.unit;if(n=s.pts-this.initDTS,r=s.dts-this.initDTS,void 0===t){if(this.nextDts){var u=Math.round(this.scaled(n-this.nextAacPts));if(Math.abs(u)<600&&u){if(u>0)Pa.log("".concat(u," ms hole between AAC samples detected,filling it"));else if(u<-12){Pa.log("".concat(-u," ms overlapping between AAC samples detected, drop frame")),this.mp4track.len-=c.getSize();continue}n=r=this.nextAacPts}}this.firstDTS=Math.max(0,r)}e={size:c.getSize(),cts:0,duration:1024,flags:{isLeading:0,isDependedOn:0,hasRedundancy:0,degradPrio:0,dependsOn:1}},i.set(c.getData(),a),a+=c.getSize(),o.push(e),t=r}return o.length?(this.nextDts=n+this.expectedSampleDuration,new Uint8Array(i.buffer,0,this.mp4track.len)):null}}]),n}(Ia),Da=(n("07ac"),re("remuxer:h264")),Ua=function(e){Tn(n,e);var t=_n(n);function n(e){var r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(h(this,n),r=t.call(this,e,i),r.nextDts=void 0,r.readyToDecode=!1,r.initialized=!1,r.firstDTS=0,r.firstPTS=0,r.lastDTS=void 0,r.lastSampleDuration=0,r.lastDurations=[],r.tsAlign=Math.round(r.timescale/60),r.mp4track={id:Ia.getTrackID(),type:"video",len:0,fragmented:!0,sps:"",pps:"",width:0,height:0,timescale:e,duration:e,samples:[]},r.samples=[],r.lastGopDTS=-99999999999999,r.gop=[],r.firstUnit=!0,r.h264=new C(fn(r)),a.sps){var o=new Uint8Array(a.sps);7===(31&o[0])?r.setSPS(o):Da.warn("bad SPS in SDP")}if(a.pps){var s=new Uint8Array(a.pps);8===(31&s[0])?r.setPPS(s):Da.warn("bad PPS in SDP")}return r.mp4track.pps&&r.mp4track.sps&&(r.readyToDecode=!0),r}return p(n,[{key:"_scaled",value:function(e){return e>>>this.scaleFactor}},{key:"_unscaled",value:function(e){return e<<this.scaleFactor}},{key:"setSPS",value:function(e){this.h264.parseSPS(e)}},{key:"setPPS",value:function(e){this.h264.parsePPS(e)}},{key:"remux",value:function(e){if(this.lastGopDTS<e.dts){if(this.gop.sort(Ia.dtsSortFunc),this.gop.length>1){var t=Ia.groupByDts(this.gop);this.gop=Object.values(t).map((function(e){return e.reduce((function(e,t){var n=t.getData();return n.set(new Uint8Array([0,0,0,1])),e.appendData(n),e}))}))}var r,i=c(this.gop);try{for(i.s();!(r=i.n()).done;){var a=r.value;pn(hn(n.prototype),"remux",this).call(this,a)&&(this.mp4track.len+=a.getSize())}}catch(o){i.e(o)}finally{i.f()}this.gop=[],this.lastGopDTS=e.dts}this.h264.parseNAL(e)&&this.gop.push(e)}},{key:"getPayload",value:function(){if(!this.getPayloadBase())return null;var e,t,n,r,i=new Uint8Array(this.mp4track.len),a=0,o=this.mp4track.samples;while(this.samples.length){var s=this.samples.shift();if(null===s){this.nextDts=void 0;break}var c=s.unit;if(n=s.pts-this.initDTS,r=s.dts-this.initDTS,r=Math.min(n,r),void 0!==t){var u=this.scaled(r-t);if(u<0){Da.log("invalid AVC sample duration at PTS/DTS: ".concat(n,"/").concat(r,"|lastDTS: ").concat(t,":").concat(u)),this.mp4track.len-=c.getSize();continue}this.lastDurations.push(u),this.lastDurations.length>100&&this.lastDurations.shift(),e.duration=u}else{if(this.nextDts){var l=r-this.nextDts;if(Math.abs(Math.round(Ia.toMS(l)))<6e4)l&&(r=this.nextDts,n=Math.max(n-l,r));else if(l<0){Da.log("skip frame from the past at DTS=".concat(r," with expected DTS=").concat(this.nextDts)),this.mp4track.len-=c.getSize();continue}}this.firstDTS=Math.max(0,r)}e={size:c.getSize(),duration:0,cts:this.scaled(n-r),flags:{isLeading:0,isDependedOn:0,hasRedundancy:0,degradPrio:0}};var f=e.flags;!0===s.unit.isKeyframe()?(f.dependsOn=2,f.isNonSync=0):(f.dependsOn=1,f.isNonSync=1),i.set(c.getData(),a),a+=c.getSize(),o.push(e),t=r}if(!o.length)return null;var h=this.lastDurations.reduce((function(e,t){return(0|e)+(0|t)}),0)/(this.lastDurations.length||1)|0;if(o.length>=2?(this.lastSampleDuration=h,e.duration=h):e.duration=this.lastSampleDuration,o.length&&(!this.nextDts||navigator.userAgent.toLowerCase().indexOf("chrome")>-1)){var d=o[0].flags;d.dependsOn=2,d.isNonSync=0}return this.nextDts=r+this.unscaled(this.lastSampleDuration),new Uint8Array(i.buffer,0,this.mp4track.len)}}]),n}(Ia),Ma="remuxer",Ba=re(Ma),Na=(Zi={},v(Zi,w.H264,Ua),v(Zi,w.AAC,Oa),Zi),La=(Ji={},v(Ji,w.H264,1),v(Ji,w.AAC,0),Ji),Fa=(ea={},v(ea,w.H264,9e4),v(ea,w.AAC,0),ea),ja=function(){function e(t,n){h(this,e),this.mse=new Ra([t]),this.eventSource=new sr,this.mseEventSource=new cr(this.mse.eventSource),this.mse_ready=!0,this.cb=n,this.reset(),this.errorListener=this.mseClose.bind(this),this.closeListener=this.mseClose.bind(this),this.errorDecodeListener=this.mseErrorDecode.bind(this),this.eventSource.addEventListener("ready",this.init.bind(this))}return p(e,[{key:"initMSEHandlers",value:function(){this.mseEventSource.on("error",this.errorListener),this.mseEventSource.on("sourceclosed",this.closeListener),this.mseEventSource.on("errordecode",this.errorDecodeListener)}},{key:"reset",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.tracks={},this.initialized=!1,this.initSegments={},this.codecs=[],this.streams={},this.enabled=!1,e.next=8,this.mse.clear();case 8:this.initMSEHandlers();case 9:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"destroy",value:function(){this.mseEventSource.destroy(),this.mse.destroy(),this.mse=null,this.eventSource.destroy()}},{key:"onTracks",value:function(e){Ba.debug("ontracks: ",e.detail);var t,n=c(e.detail);try{for(n.s();!(t=n.n()).done;){var r=t.value;this.tracks[r.type]=new Na[r.type](Fa[r.type],La[r.type],r.params),r.offset&&(this.tracks[r.type].timeOffset=r.offset),r.duration?(this.tracks[r.type].mp4track.duration=r.duration*(this.tracks[r.type].timescale||Fa[r.type]),this.tracks[r.type].duration=r.duration):this.tracks[r.type].duration=1}}catch(i){n.e(i)}finally{n.f()}}},{key:"setTimeOffset",value:function(e,t){this.tracks[t.type]&&(this.tracks[t.type].timeOffset=e)}},{key:"MSE",get:function(){return this.mse}},{key:"init",value:function(){var e=this,t=[];this.codecs=[];var n=[],r=1/0,i=1/0;for(var a in this.tracks){var o=this.tracks[a];if(!Ra.isSupported([o.mp4track.codec]))return;t.push(o.mp4track),this.codecs.push(o.mp4track.codec),o.init(r,i)}for(var s in this.tracks){var c=this.tracks[s];this.initSegments[s]=_a.initSegment([c.mp4track],c.duration*c.timescale,c.timescale),n.push(this.initMSE(s,c.mp4track.codec))}return this.initialized=!0,this.cb&&this.cb(),Promise.all(n).then((function(){e.enabled=!0}))}},{key:"initMSE",value:function(e,t){var n=this;if(Ra.isSupported(this.codecs))return this.mse.setCodec(e,"".concat(w.map[e],'/mp4; codecs="').concat(t,'"')).then((function(){n.mse.feed(e,n.initSegments[e])}));throw new Error("Codecs are not supported")}},{key:"mseClose",value:function(){this.client.stop(),this.eventSource.dispatchEvent("stopped")}},{key:"mseErrorDecode",value:function(){this.tracks[2]&&(console.warn(this.tracks[2].mp4track.type),this.mse.buffers[2].destroy(),delete this.tracks[2])}},{key:"flush",value:function(){if(this.onSamples(),this.initialized)for(var e in this.tracks){var t=this.tracks[e],n=t.getPayload();n&&n.byteLength&&(this.mse.feed(e,[_a.moof(t.seq,t.scaled(t.firstDTS),t.mp4track),_a.mdat(n)]),t.flush())}else if(Ba.debug("Initialize..."),Object.keys(this.tracks).length){for(var r in this.tracks){if(!this.tracks[r].readyToDecode||!this.tracks[r].samples.length)return;Ba.debug("Init MSE for track ".concat(this.tracks[r].mp4track.type))}this.eventSource.dispatchEvent("ready")}}},{key:"onSamples",value:function(){for(var e in this.client.sampleQueues){var t=this.client.sampleQueues[e];switch(parseInt(e)){case w.H264:this.onVideoFrame(t,e);case w.G711A:this.onAudioFrame(t);default:break}}}},{key:"onVideoFrame",value:function(e,t){while(e.length){var n=e.shift();if(n){var r,i=c(n);try{for(i.s();!(r=i.n()).done;){var a=r.value;this.tracks[t]&&this.tracks[t].remux(a)}}catch(o){i.e(o)}finally{i.f()}}}}},{key:"onAudioFrame",value:function(){}},{key:"onAudioConfig",value:function(e){this.tracks[e.detail.pay]&&this.tracks[e.detail.pay].setConfig(e.detail.config)}},{key:"attachClient",value:function(e,t){var n=this;this.client=e,this.clientEventSource=t,this.clientEventSource.on("samples",this.samplesListener),this.clientEventSource.on("audio_config",this.audioConfigListener),this.clientEventSource.on("flush",this.flush.bind(this)),this.clientEventSource.on("clear",(function(){n.reset(),n.mse.clear().then((function(){n.initMSEHandlers()}))})),this.mse.setLive(!this.client.seekable)}}]),e}(),Wa=ja,Ha={timeout:6e4},Va="/tums/devConfig/v1/passthrough",qa=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{steamType:"",authSessionId:"",appKey:"",appSecret:"",urlPrefix:""};h(this,e),this.steamType=t.steamType||"",this.authSessionId=t.authSessionId||"",this.appKey=t.appKey||"",this.appSecret=t.appSecret||"",this.setUrlPrefix(t.urlPrefix)}return p(e,[{key:"setUrlPrefix",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";this.urlPrefix=e;var t=e.length||0;t&&"/"===e[t-1]&&(this.urlPrefix=this.urlPrefix.substring(0,t-1))}},{key:"getAxiosConfig",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{uri:uri,param:param,method:"POST",initConfig:{}},t=Object.assign({},Ha,e.initConfig);if(this.steamType===Tr.RELAY&&this.appKey){t.headers||(t.headers={}),t.headers,t.headers["X-Authorization"]=Or({appKey:this.appKey,appSecret:this.appSecret,terminalId:xt(16),method:e.method,uri:e.uri,payload:JSON.stringify(e.param||{})})}return t}},{key:"getFullUrl",value:function(e){var t=this.urlPrefix+e;return this.steamType===Tr.RTSP&&(t=t.indexOf("?")>-1?"".concat(t,"&SESSIONID=").concat(this.authSessionId):"".concat(t,"?SESSIONID=").concat(this.authSessionId)),t}},{key:"post",value:function(e,t,n){var r=this.getFullUrl(e);return Cr.a.post(r,t||{},this.getAxiosConfig({uri:e,param:t,method:"POST",initConfig:n||{}})).catch((function(e){return-1!==e.message.indexOf("timeout")?Promise.reject({error_code:la.COMMON.REQUEST_TIMEOUT,msg:"请求超时"}):-1!==e.message.indexOf("Network Error")||-1!==e.message.indexOf("Request failed")?Promise.reject({error_code:void 0,msg:"网络异常"}):Promise.reject({error_code:la.COMMON.UNKNOWN_CODE,msg:"未知错误"})})).then((function(e){var t=e.data||{};return 0===t.error_code?Promise.resolve(e.data):Promise.reject(e.data)}))}},{key:"passthrough",value:function(e){return this.post(Va,e).then((function(e){return 0===e.error_code&&0===e.result.responseData.error_code?Promise.resolve(e.result.responseData):Promise.reject(e.error_code?e:e.result.responseData)}))}},{key:"nvrChnPassthrough",value:function(e,t,n){var r={devId:e,param:{method:"forward",destination:"ipc",channel:t,content:n}};return this.passthrough(r).then((function(e){return 0!==e.error_code?Promise.reject(e):e.content}))}}]),e}(),za=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{parentQrCode:parentQrCode,qrCode:qrCode,channelId:channelId};h(this,e),this.requestor=t,this.parentQrCode=n.parentQrCode,this.qrCode=n.qrCode,this.channelId=n.channelId,this.init()}return p(e,[{key:"init",value:function(){this.lensMaskEnable=!1,this.flipEnable=!0,this.rotateEnable=!1,this.fishEveEnable=!1,this.ptzEnable=!1,this.isMultiSensor=!1,this.isMotor=!1,this.talkEnable=!1,this.moduleSpec=null}},{key:"getModuleSpec",value:function(){var e=this;if(this.moduleSpec)return Promise.resolve({lensMaskEnable:this.lensMaskEnable,flipEnable:this.flipEnable,rotateEnable:this.rotateEnable,fishEveEnable:this.fishEveEnable,ptzEnable:this.ptzEnable,talkEnable:this.talkEnable,isMultiSensor:this.isMultiSensor,isMotor:this.isMotor});var t=this.requestor.post("/vms/open/deviceManager/v1/getDeviceCapability",{qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId});return t.then((function(t){var n=t.result,r=void 0===n?{}:n;return e.moduleSpec=r.capability||{},e.lensMaskEnable="1"===e.moduleSpec.lens_mask,e.ptzEnable="1"===e.moduleSpec.ptz,e.isMultiSensor="1"===e.moduleSpec.multi_sensor,e.isMotor="1"===e.moduleSpec.motor,e.rotateEnable="1"===e.moduleSpec.corridor_mode,e.fishEveEnable="1"===e.moduleSpec.fish_eye,e.talkEnable=e.moduleSpec.audio.includes("speaker")&&e.moduleSpec.audio.includes("microphone"),{lensMaskEnable:e.lensMaskEnable,flipEnable:e.flipEnable,rotateEnable:e.rotateEnable,fishEveEnable:e.fishEveEnable,ptzEnable:e.ptzEnable,talkEnable:e.talkEnable,isMultiSensor:e.isMultiSensor,isMotor:e.isMotor}}))}}]),e}(),Ga=n("9224"),Ya=re("TumsPlayer"),Ka=(ta={},v(ta,Tr.RTSP,Ea),v(ta,Tr.RELAY,di),ta),Xa=(na={},v(na,Tr.RTSP,Xi),v(na,Tr.RELAY,ti),na),Qa=1,$a="";Cr.a.defaults.withCredentials=!0;var Za=function(){function e(t,n){h(this,e),this.isInit=!0,this.url="",this.type="",this.resolution="",this.client=null,this.audioClient=null,this.player=null,this.modules={},this.errorHandler=null,this.queryCredentials=null,this.eventSource=new sr,f(t)===f("")?this.parent=document.getElementById(t):this.parent=t,localStorage.setItem("__TUMS_PLAYER_VERSION__","".concat(Ga.name,"@").concat(Ga.version)),n&&this.init(n)}return p(e,[{key:"init",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.appKey=t.appKey||"",this.appSecret=t.appSecret||"",this.proxyServer=t.proxyServer||"https://api-smbcloud.tp-link.com.cn/",this.parentQrCode=t.parentQrCode,this.qrCode=t.qrCode,this.channelId=t.channelId||Qa,this.requestor=new qa(t.type===Tr.RTSP?{steamType:t.type,urlPrefix:t.queryAddress,authSessionId:t.authSessionId}:{steamType:t.type,urlPrefix:this.proxyServer,appKey:t.appKey,appSecret:t.appSecret}),this.devCapability=new za(this.requestor,{parentQrCode:this.parentQrCode,qrCode:this.qrCode,channelId:this.channelId}),e.next=10,this.destroy();case 10:return this.addVideoWrap(),this.options=t,this.type=t.type||Tr.RTSP,this.socket=t.socket,this.autoplay=!1!==t.autoplay,this.resolution=t.resolution||"",this.errorHandler=t.errorHandler||null,this.queryCredentials=t.queryCredentials||null,this.pluginPath=t.pluginPath||"",this.isCover=t.cover||!1,this.streamType=t.streamType||"video",this.storageType=t.storageType||"device",this.startTime=t.startTime||new Date((new Date).toLocaleDateString()).getTime(),this.endTime=t.endTime||this.startTime+864e5,this.scale=t.scale||1,this.eventType=t.eventType||[1,2],this.userId=t.userId||0,this.screenshotEnable=!1!==t.screenshotEnable,this.audioVoiceEnable=!1!==t.audioVoiceEnable,this.talkEnable=t.talkEnable||!1,this.volume=t.volume||0,this.fishEyeDisplayMode=t.fishEyeDisplayMode||"ORIGIN",this.ptzEnable=t.ptzEnable||!1,this.supportVideoEl=t.supportVideoEl||!1,this.encodeType=t.encodeType||"",this.decoderType=t.decoderType,e.next=38,this.canPlayDecoderType(this.decoderType);case 38:if(n=e.sent,n){e.next=42;break}return this.eventSource.dispatchEvent("error",new oe(oe.MEDIA_ERR_DECODER)),e.abrupt("return");case 42:return e.next=44,Nt(this.pluginPath,this.decoderType);case 44:if(this._startTime=(new Date).getTime(),this.isError=!1,this.type!==Tr.HLS){e.next=48;break}return e.abrupt("return");case 48:if(this.supportVideoEl?(this.player=new Wa(this.video,(function(){Ya.log("First frame cost: ",(new Date).getTime()-i._startTime),console.log("[TumsPlayer] playing"),i._keepEventSource=!1,i.eventSource.dispatchEvent("playing",i)})),this.video.style.display="inline-block"):this.player=new ln({pluginPath:this.pluginPath,cover:this.isCover,playScale:this.scale,streamType:this.streamType,volume:this.volume,startTime:this.startTime,fishEyeDisplayMode:this.fishEyeDisplayMode,audioVoiceEnable:this.audioVoiceEnable,decoderType:this.decoderType},this.parent,(function(){Ya.log("First frame cost: ",(new Date).getTime()-i._startTime),console.log("[TumsPlayer] playing"),i._keepEventSource=!1,i.eventSource.dispatchEvent("playing",i)})),!t.url||!t.type){e.next=54;break}this.url=t.url,this.type=t.type,e.next=62;break;case 54:if(this._checkSource(this.video)){e.next=62;break}r=0;case 56:if(!(r<this.video.children.length)){e.next=62;break}if(!this._checkSource(this.video.children[r])){e.next=59;break}return e.abrupt("break",62);case 59:++r,e.next=56;break;case 62:if(!this.url){e.next=65;break}return e.next=65,this.setSource(this.url,this.type);case 65:this.autoplay&&(this.video.setAttribute("autoplay","autoplay"),this.start());case 66:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"addVideoWrap",value:function(){this.video=document.createElement("video"),N(this.video,{display:"none",width:"100%",height:"100%"}),this.parent.appendChild(this.video)}},{key:"isPlaying",value:function(){return!!this.client&&!this.client.paused}},{key:"canPlayAmbiguousCodec",value:function(){return new Promise((function(e){var t=new VideoDecoder({output:function(){e(!0)},error:function(t){console.log("error in init:",t),e(!1)}});t.configure({codec:"hvc1.*"})}))}},{key:"canPlayDecoderType",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=!!window.VideoDecoder,e.prev=1,e.t0=n,!e.t0){e.next=10;break}if(e.t1="H264"===this.encodeType,e.t1){e.next=9;break}return e.next=8,window.VideoDecoder.isConfigSupported({codec:"hvc1.1.1.L150.B0"}).then((function(e){return e.supported}));case 8:e.t1=e.sent;case 9:e.t0=e.t1;case 10:r=e.t0,e.next=15;break;case 13:e.prev=13,e.t2=e["catch"](1);case 15:if(i=!!window.WebAssembly,"webcodecs"!==t){e.next=20;break}return e.abrupt("return",r);case 20:if("wasm"!==t){e.next=24;break}return e.abrupt("return",i);case 24:if(!r){e.next=29;break}return this.decoderType="webcodecs",e.abrupt("return",!0);case 29:if(!i){e.next=32;break}return this.decoderType="wasm",e.abrupt("return",!0);case 32:return e.abrupt("return",!1);case 33:case"end":return e.stop()}}),e,this,[[1,13]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"canPlayUrl",value:function(e){var t=Tr.fromUrl(e);return t in Ka}},{key:"_checkSource",value:function(e){return!(!e||e.dataset["ignore"]||!e.src||this.video.canPlayType(e.type)||!Tr.fromMime(e.type)&&!Tr.fromUrl(e.src))&&(this.url=e.src,this.type=e.type?Tr.fromMime(e.type):Tr.fromUrl(e.src),!0)}},{key:"initAudio",value:function(e){var t=this,n=Xa[this.type];this.audioClient=new n({url:e.url,socket:e.wssUrl||this.socket,type:this.type,token:this.options.token,cookie:this.options.cookie,flush:10,streamType:"dtspk",useMultitrans:this.options.useMultitrans,slpData:e.slpData||{},mode:e.mode,appKey:this.appKey,appSecret:this.appSecret}),Ya.log("voice options: ",e),this.audioClientEventSource=new cr(this.audioClient.eventSource),this.audioClientEventSource.on("audioError",(function(e){t.stopVoiceIntercom(),e.detail.type="audio",t.eventSource.dispatchEvent("error",e.detail)})),this.audioClientEventSource.on("sendAudioStream",(function(){t.eventSource.dispatchEvent("sendAudioStream")}))}},{key:"setSource",value:function(){var e=l(regeneratorRuntime.mark((function e(t,n){var r,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!this.transport){e.next=6;break}if(!this.client){e.next=4;break}return e.next=4,this.client.detachTransport();case 4:return e.next=6,this.transport.destroy();case 6:try{this.endpoint=hr.parse(t)}catch(a){Ya.log(a)}if(this.url=t,r=this.type,this.type=!!Tr.isSupported(n)&&n||Tr.fromMime(n),this.type){e.next=12;break}throw new Error("Bad stream type");case 12:if(r==this.type&&this.client){e.next=20;break}if(!this.client){e.next=16;break}return e.next=16,this.client.destroy();case 16:i=Ka[this.type],this.client=new i({url:this.url,socket:this.socket,type:this.type,flush:10,streamType:this.streamType,startTime:this.startTime,endTime:this.endTime,eventType:this.eventType,scale:this.scale,userId:this.userId,videoSessionId:this.options.videoSessionId,videoDevId:this.options.videoDevId,storageDevId:this.options.storageDevId,useMultitrans:this.options.useMultitrans,audioVoiceEnable:this.audioVoiceEnable,requestor:this.requestor,appKey:this.appKey,appSecret:this.appSecret}),e.next=21;break;case 20:this.client.reset();case 21:this.queryCredentials&&(this.client.queryCredentials=this.queryCredentials),this.attachClient(),this.player&&this.player.attachClient(this.client,this.clientEventSource),this.eventSource.dispatchEvent("ready",this);case 25:case"end":return e.stop()}}),e,this)})));function t(t,n){return e.apply(this,arguments)}return t}()},{key:"attachClient",value:function(){var e=this;this.detachClient(),this.clientEventSource=new cr(this.client.eventSource),this.clientEventSource.on("tracks",this.onTracks.bind(this)),this.clientEventSource.on("relayConfig",this.onRelayConfig.bind(this)),this.clientEventSource.on("rtspConfig",this.onRTSPConfig.bind(this)),this.clientEventSource.on("stream",(function(){e.eventSource.dispatchEvent("stream",e),e.player&&(e.player.isInit=!0)})),this.clientEventSource.on("error",(function(t){if(t.detail.code===oe.MEDIA_ERR_DECODER)return e.options.decoderType="wasm",e._keepEventSource=!0,void e.init(e.options);e.isError=!0,e.player&&e.player.stopFlush(),t.detail.code===oe.CLOUD_ERR_FREE&&e.stopVoiceIntercom(),e.eventSource.dispatchEvent("error",t.detail),console.log("[TumsPlayer] disconnected")})),this.clientEventSource.on("disconnected",(function(){e.isError=!0,e.player&&e.player.stopFlush(),e.eventSource.dispatchEvent("disconnected",e),console.log("[TumsPlayer] disconnected")})),this.clientEventSource.on("ended",(function(){e.player&&e.player.stopFlush(),e.eventSource.dispatchEvent("ended",e)})),this.clientEventSource.on("zoom",(function(t){e.eventSource.dispatchEvent("zoom",t.detail)})),this.clientEventSource.on("warning",(function(t){e.eventSource.dispatchEvent("warning",t.detail)})),this.clientEventSource.on("videoRecordFinished",(function(){e.eventSource.dispatchEvent("videoRecordFinished",{})}))}},{key:"detachClient",value:function(){this.clientEventSource&&(this.clientEventSource.destroy(),this.clientEventSource=null)}},{key:"onTracks",value:function(e){Ya.log("on tracks: ",e.detail);var t,n,r,i,a=e.detail||{},o=c(a);try{for(o.s();!(i=o.n()).done;){var s=i.value;if(s.type==w.H264?t=0:s.type==w.H265&&(t=1),s.audioTrack){var u=s.audioTrack,l=u.rtpmap[u.fmt[0]];n=l.clock,r=l.name}}}catch(f){o.e(f)}finally{o.f()}this.initPlayer({codeType:t,audioType:r,sampleRate:n,tracks:e})}},{key:"onRelayConfig",value:function(e){var t,n,r,i,a=e.detail||{};a["video_codec"]&&(t="H265"===a["video_codec"]?1:0),r=a["audio_codec"]||"G711alaw";var o=8e3;o="8"===a["audio_sampling_rate"]?8e3:"16"===a["audio_sampling_rate"]?16e3:"44.1"===a["audio_sampling_rate"]?44100:a["audio_sampling_rate"],i=a.bitCount||"",n=parseInt(o||8e3),Ya.log("player config: ",a),this.initPlayer({codeType:t,audioType:r,sampleRate:n,bitCount:i})}},{key:"onRTSPConfig",value:function(e){this.onRelayConfig(e)}},{key:"initPlayer",value:function(e){var t=e.tracks;this.supportVideoEl?this.player.onTracks(t):this.player.setConfig(e),this.eventSource.dispatchEvent("play",this)}},{key:"start",value:function(){var e=this;this.client&&this.client.start().then((function(){e.isInit=!1})).catch((function(t){e.errorHandler&&e.errorHandler(t)}))}},{key:"stop",value:function(){this.client&&this.client.stop()}},{key:"destroy",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.clearSessionInterval(),!this.client){e.next=7;break}return e.next=4,this.client.destroy();case 4:this.detachClient(),this.client=null,this.transport=null;case 7:this.player&&(this.player.destroy(),this.player=null),this.eventSource&&!this._keepEventSource&&this.eventSource.clear(),this.video&&this.parent.removeChild(this.video),this.audioClient&&this.audioClient&&this.audioClient.destroy();case 11:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"play",value:function(){var e=this;this.isPlaying()||(this._startTime=Date.now(),this.client&&this.client.play((function(){e.video.play(),e.player.resumeRecord&&e.player.resumeRecord(),e.player.startFlush&&e.player.startFlush(),e.eventSource.dispatchEvent("play",e)})))}},{key:"pause",value:function(){var e=this;this.isPlaying()&&this.client&&this.client.pause((function(){e.video.pause(),"sdvod"===e.streamType&&e.player.stopFlush&&e.player.stopFlush(),e.player.pauseRecord&&e.player.pauseRecord(),e.eventSource.dispatchEvent("pause",e)}))}},{key:"fullscreen",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.player&&this.player.requestFullscreen(e,t)}},{key:"exitFullscreen",value:function(){this.player&&this.player.exitFullscreen()}},{key:"screenshot",value:function(e){return this.screenshotEnable?this.player.screenshot&&this.player.screenshot(e):""}},{key:"startRecording",value:function(e){return this.player&&this.player.startRecord?this.player.startRecord(e):Promise.resolve()}},{key:"stopRecording",value:function(e,t){return this.player&&this.player.stopAndblobDownload?this.player.stopAndblobDownload(e,t):Promise.resolve()}},{key:"getRecordInfo",value:function(){return this.player?this.player.getRecordInfo?this.player.getRecordInfo():{size:0,time:0}:{}}},{key:"setResolution",value:function(e,t){this._startTime=Date.now(),this.client&&this.client.setResolution(e),t&&(this.resolution=t)}},{key:"startVoiceIntercom",value:function(){var e=l(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.talkEnable){e.next=2;break}return e.abrupt("return");case 2:return"string"===typeof t&&(t={url:t,mode:"aec"}),e.next=5,this.initAudio(t);case 5:this.audioClient&&this.audioClient.startVoiceIntercom(t.url);case 6:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"stopVoiceIntercom",value:function(){var e=l(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.talkEnable){e.next=2;break}return e.abrupt("return");case 2:if(e.t0=this.audioClient,!e.t0){e.next=7;break}return e.next=6,this.audioClient.destroy();case 6:e.t0=e.sent;case 7:if(e.t1=e.t0,!e.t1){e.next=11;break}return e.next=11,this.audioClient.stop();case 11:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"setSpeakerVolume",value:function(){this.talkEnable}},{key:"on",value:function(e,t){this.eventSource.addEventListener(e,t)}},{key:"off",value:function(e,t){this.eventSource.removeEventListener(e,t)}},{key:"setPlaybackConfig",value:function(e){var t=this;e.scale&&(e.startTime||(e=Object.assign({startTime:this.getPlaybackTime()},e))),e.currentTime=this.getPlaybackTime(),e.currentScale=this.getPlayScale(),this.client&&this.client.setPlaybackConfig(e).then((function(){t.video.play(),t.eventSource.dispatchEvent("play",t),e.scale&&t.player.setPlayScale&&t.player.setPlayScale(e.scale),e.startTime&&t.player.seek&&t.player.seek(e.startTime),t.player.startFlush&&t.player.startFlush()}))}},{key:"getPlaybackTime",value:function(){return this.player&&this.player.getTimestamp&&this.player.getTimestamp()||this.startTime}},{key:"getPlayScale",value:function(){return this.player&&this.player.getPlayScale&&this.player.getPlayScale()||this.scale}},{key:"toggleZoomState",value:function(e){this.player&&this.player.toggleZoomState&&this.player.toggleZoomState(e)}},{key:"setZoomScale",value:function(e){this.player&&this.player.setZoomScale&&this.player.setZoomScale(e)}},{key:"playAudio",value:function(){this.player&&this.player.playAudio&&this.player.playAudio()}},{key:"setVolume",value:function(e){this.volume=e,this.player&&this.player.setVolume&&this.player.setVolume(e)}},{key:"getVolume",value:function(){return this.player&&this.player.getVolume&&this.player.getVolume()}},{key:"keepSession",value:function(){var e=this;this.clearSessionInterval(),$a=setInterval((function(){e.requestor.post(ca.url.getCurrentTime,{},{headers:{sessionUpdate:!0}})}),3e4)}},{key:"clearSessionInterval",value:function(){clearInterval($a)}},{key:"setFishEyeDisplayMode",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.fishEyeDisplayMode=e,this.player&&this.player.setDisplayMode&&this.player.setDisplayMode(e,t)}},{key:"setPtzParams",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId,speed:t.speed,direction:t.direction},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/motionCtrl",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"startParkConfig",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t,n,r=arguments;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},n={enabled:t.enabled,parkTime:t.parkTime,actionMode:t.mode,actionId:t.actionId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/setParkConfig",n));case 3:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getAllPresets",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/getAllPresets",t));case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"operatePreset",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={presetId:t.presetId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},void 0!==t.name&&(n.presetName=t.name,n.override=t.override),e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/operatePreset",n));case 3:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"executePreset",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={presetId:t.presetId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/executePreset",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"deletePreset",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={presetId:t.presetId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/deletePreset",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"addPresetPoint",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={presetId:t.presetId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId,presetName:t.presetName,override:t.override},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/operatePreset",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"resetPtzDevicePosition",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/resetPtzDevicePosition",e)}},{key:"getPtzDeviceResetSupport",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getPtzDeviceResetSupport",e)}},{key:"getFocusCapability",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getFocusCapability",e)}},{key:"getDeviceZoomSupport",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getDeviceZoomSupport",e)}},{key:"getAllTours",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/getAllTours",t));case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getToursInfo",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId,tourIds:t.tourId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/getToursInfo",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"addCruisePath",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n="".concat("add"===t.type?"/vms/open/deviceConfig/v1/addTour":"/vms/open/deviceConfig/v1/modifyTour"),r={tourId:t.tourId,tourName:t.tourName,presetIds:t.presetIds,times:t.times,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post(n,r));case 3:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"executeTour",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={tourId:t.tourId,action:t.action,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/executeTour",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"deleteTour",value:function(){var e=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n={tourId:t.tourId,qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/deleteTour",n));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"getDeviceType",value:function(){var e=l(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId},e.abrupt("return",this.requestor.post("/vms/open/deviceConfig/v1/getPtzCapability",t));case 2:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getPtzCapability",value:function(e){var t=this;return this.requestor.passthrough(e.param).then((function(n){if("ipc"===e.type){var r=n.ptz.capability,i=t.isDisabled(r,"position_zoom_range"),a="1"===r.position3D_unsupported,o=!("1"===r.pattern_supported),s=!("1"===r.tour_supported),c=!("1"===r.preset_supported),u=t.isDisabled(r,"position_pan_range"),l=!("1"===r.park_supported),f=t.isDisabled(r,"position_tilt_range"),h="1"===r.pan_tilt_rotate_sync_unsupported,d=r.tour_stay_time_range.map((function(e){return e/1e3})),p={zoomCapabilityDisabled:i,position3DUnsupported:a,patternSupported:o,tourSupportedDisabled:s,presetUnSupported:c,parkSupported:l,tiltRangeDisabled:f,panTiltRotate:h,tourStayTimeRange:d,panRangeDisabled:u,type:"ipc"};return p}var v="chn".concat(e.nvrChannel,"_ptz_capability"),m=n[v].ptz_capability,y="0.000000"===m.z_max&&"0.000000"===m.z_min,g=!("1"===m.pattern_supported),b=!("1"===m.tour_supported),T=!("1"===m.preset_supported),S="0.000000"===m.x_max&&"0.000000"===m.x_min,E="0.000000"===m.y_max&&"0.000000"===m.y_min,_=t.zoomCapabilityDisabled&&t.panRangeDisabled&&t.tiltRangeDisabled,k={zoomCapabilityDisabled:y,position3DUnsupported:_,patternSupported:g,tourSupportedDisabled:b,presetUnSupported:T,tiltRangeDisabled:E,panRangeDisabled:S,type:"nvr"};return k})).catch((function(e){if(e.error_code)return Promise.resolve(e);throw e}))}},{key:"isDisabled",value:function(e,t){return!(Object.prototype.hasOwnProperty.call(e,t)&&"0.000000,0.000000"!==e[t].toString())}},{key:"getLensMaskValue",value:function(){return this.requestor.post("/vms/open/deviceConfig/v1/getMaskInfo",{qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId})}},{key:"setLensMaskValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.requestor.post("/vms/open/deviceConfig/v1/setMaskInfo",{qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId,enabled:!!e})}},{key:"getImageSwitch",value:function(){return this.requestor.post("/vms/open/deviceConfig/v1/getSwitchType",{qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId})}},{key:"saveImageSwitch",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{flip_type:"",rotate_type:""},t=e.flip_type,n=e.rotate_type,r={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return Ot(t)||Object.assign(r,{flip:t}),Ot(n)||Object.assign(r,{rotate:n}),this.requestor.post("/vms/open/deviceConfig/v1/setSwitchType",r)}},{key:"getTalkCapability",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getTalkCapability",e)}},{key:"getMotorCapability",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getMotorCapability",e)}},{key:"getMicrophoneCapability",value:function(){var e={qrCode:this.parentQrCode||this.qrCode,channelId:this.channelId};return this.requestor.post("/vms/open/deviceConfig/v1/getMicrophoneCapability",e)}},{key:"getModuleSpec",value:function(){return this.devCapability.getModuleSpec()}}],[{key:"canPlayWithModules",value:function(e,t){var n,r={},i=c(t);try{for(i.s();!(n=i.n()).done;){var a=n.value,o=a.transport||Er,s=a.client||Ea;o.canTransfer(s.streamType())&&(r[s.streamType()]=!0)}}catch(l){i.e(l)}finally{i.f()}for(var u in r)if(u==Tr.fromMime(e))return!0;return!1}},{key:"canPlay",value:function(e){return Tr.fromMime(e.type)||Tr.fromUrl(e.src)}}]),e}(),Ja=Za;t["default"]=Ja},fb2c:function(e,t,n){var r=n("74e8");r("Uint32",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},fb6a:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),a=n("e8b5"),o=n("68ee"),s=n("861d"),c=n("23cb"),u=n("07fa"),l=n("fc6a"),f=n("8418"),h=n("b622"),d=n("1dde"),p=n("f36a"),v=d("slice"),m=h("species"),y=i.Array,g=Math.max;r({target:"Array",proto:!0,forced:!v},{slice:function(e,t){var n,r,i,h=l(this),d=u(h),v=c(e,d),b=c(void 0===t?d:t,d);if(a(h)&&(n=h.constructor,o(n)&&(n===y||a(n.prototype))?n=void 0:s(n)&&(n=n[m],null===n&&(n=void 0)),n===y||void 0===n))return p(h,v,b);for(r=new(void 0===n?y:n)(g(b-v,0)),i=0;v<b;v++,i++)v in h&&f(r,i,h[v]);return r.length=i,r}})},fbec:function(e,t,n){var r=n("23e7"),i=n("783c"),a=n("825a"),o=i.toKey,s=i.set;r({target:"Reflect",stat:!0},{defineMetadata:function(e,t,n){var r=arguments.length<4?void 0:o(arguments[3]);s(e,t,a(n),r)}})},fc6a:function(e,t,n){var r=n("44ad"),i=n("1d80");e.exports=function(e){return r(i(e))}},fce3:function(e,t,n){var r=n("d039"),i=n("da84"),a=i.RegExp;e.exports=r((function(){var e=a(".","s");return!(e.dotAll&&e.exec("\n")&&"s"===e.flags)}))},fd81:function(e,t,n){"use strict";var r=n("da84"),i=n("69f3"),a=n("9ed3"),o=n("861d"),s=n("37e8").f,c=n("83ab"),u="Incorrect Number.range arguments",l="NumericRangeIterator",f=i.set,h=i.getterFor(l),d=r.RangeError,p=r.TypeError,v=a((function(e,t,n,r,i,a){if(typeof e!=r||t!==1/0&&t!==-1/0&&typeof t!=r)throw new p(u);if(e===1/0||e===-1/0)throw new d(u);var s,h=t>e,v=!1;if(void 0===n)s=void 0;else if(o(n))s=n.step,v=!!n.inclusive;else{if(typeof n!=r)throw new p(u);s=n}if(null==s&&(s=h?a:-a),typeof s!=r)throw new p(u);if(s===1/0||s===-1/0||s===i&&e!==t)throw new d(u);var m=e!=e||t!=t||s!=s||t>e!==s>i;f(this,{type:l,start:e,end:t,step:s,inclusiveEnd:v,hitsEnd:m,currentCount:i,zero:i}),c||(this.start=e,this.end=t,this.step=s,this.inclusive=v)}),l,(function(){var e=h(this);if(e.hitsEnd)return{value:void 0,done:!0};var t=e.start,n=e.end,r=e.step,i=t+r*e.currentCount++;i===n&&(e.hitsEnd=!0);var a,o=e.inclusiveEnd;return a=n>t?o?i>n:i>=n:o?n>i:n>=i,a?{value:void 0,done:e.hitsEnd=!0}:{value:i,done:!1}})),m=function(e){return{get:e,set:function(){},configurable:!0,enumerable:!1}};c&&s(v.prototype,{start:m((function(){return h(this).start})),end:m((function(){return h(this).end})),inclusive:m((function(){return h(this).inclusiveEnd})),step:m((function(){return h(this).step}))}),e.exports=v},fd87:function(e,t,n){var r=n("74e8");r("Int8",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},fdbc:function(e,t){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},fdbf:function(e,t,n){var r=n("4930");e.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},fea9:function(e,t,n){var r=n("da84");e.exports=r.Promise},ff9c:function(e,t,n){var r=n("23e7"),i=n("8eb5"),a=Math.cosh,o=Math.abs,s=Math.E;r({target:"Math",stat:!0,forced:!a||a(710)===1/0},{cosh:function(e){var t=i(o(e)-1)+1;return(t+1/(t*s*s))*(s/2)}})},fffc:function(e,t,n){"use strict";var r=n("23e7"),i=n("2266"),a=n("59ed"),o=n("825a");r({target:"Iterator",proto:!0,real:!0},{find:function(e){return o(this),a(e),i(this,(function(t,n){if(e(t))return n(t)}),{IS_ITERATOR:!0,INTERRUPTED:!0}).result}})}})}));
|
|
35
|
+
//# sourceMappingURL=tums-player.umd.min.js.map
|