diff --git a/README.md b/README.md index a0c84d38..4a548aec 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -# gocraft/work [![PkgGoDev][pkg-go-dev-xgo-badge]][pkg-go-dev-xgo] [![build][github-workflow-badge]][github-workflow] +# gojek/work [![PkgGoDev][pkg-go-dev-xgo-badge]][pkg-go-dev-xgo] [![build][github-workflow-badge]][github-workflow] -gocraft/work lets you enqueue and processes background jobs in Go. Jobs are durable and backed by Redis. Very similar to Sidekiq for Go. +gojek/work lets you enqueue and processes background jobs in Go. Jobs are durable and backed by Redis. Very similar to Sidekiq for Go. * Fast and efficient. Faster than [this](https://www.github.com/jrallison/go-workers), [this](https://www.github.com/benmanns/goworker), and [this](https://www.github.com/albrow/jobs). See below for benchmarks. * Reliable - don't lose jobs even if your process crashes. @@ -18,10 +18,11 @@ gocraft/work lets you enqueue and processes background jobs in Go. Jobs are dura #### Usage +The module is backward compatible with github.com/gocraft/work. To switch to this module, simply replace +`github.com/gocraft/work` with `github.com/gojek/work` in Go source files and run `go get`: + ```shell -go get github.com/gocraft/work && \ - go mod edit -replace github.com/gocraft/work=github.com/gojek/work@latest && \ - go mod tidy +go get github.com/gojek/work ``` #### Refresh Node.js dependencies for WebUI (`99f237a`). @@ -44,15 +45,15 @@ in-progress queue was lost. #### Expose lock count & max concurrency for each job (#2) Added to the queue info accessible from -[`work.Client.Queues()`](/client.go#L205-L212). Useful for alerting when lock count is consistently equal to the max +[`work.Client.Queues()`](https://pkg.go.dev/github.com/gojek/work#Client.Queues). Useful for alerting when lock count is consistently equal to the max concurrency possibly indicating that stale lock count is resulting in jobs not being picked up. For the cleanup to be thorough, [`work.(*WorkerPool).Stop`](https://pkg.go.dev/github.com/gojek/work#WorkerPool.Stop) would need to be called on each worker pool instance. -#### Worker pool started check +#### Worker pool started check (#15) -Expose [`work.(*WorkerPool).Started`](/worker_pool.go#L195-L198) which can be used to check if the worker pool has been +Expose [`work.(*WorkerPool).Started`](https://pkg.go.dev/github.com/gojek/work#WorkerPool.Started) which can be used to check if the worker pool has been started and is running. --- @@ -66,7 +67,7 @@ package main import ( "github.com/gomodule/redigo/redis" - "github.com/gocraft/work" + "github.com/gojek/work" ) // Make a redis pool @@ -102,7 +103,7 @@ package main import ( "github.com/gomodule/redigo/redis" - "github.com/gocraft/work" + "github.com/gojek/work" "os" "os/signal" ) @@ -188,7 +189,7 @@ func (c *Context) Export(job *work.Job) error { ``` ## Redis Cluster -If you're attempting to use gocraft/work on a `Redis Cluster` deployment, then you may encounter a `CROSSSLOT Keys in request don't hash to the same slot` error during the execution of the various lua scripts used to manage job data (see [Issue 93](https://github.com/gocraft/work/issues/93#issuecomment-401134340)). The current workaround is to force the keys for an entire `namespace` for a given worker pool on a single node in the cluster using [Redis Hash Tags](https://redis.io/topics/cluster-spec#keys-hash-tags). Using the example above: +If you're attempting to use gojek/work on a `Redis Cluster` deployment, then you may encounter a `CROSSSLOT Keys in request don't hash to the same slot` error during the execution of the various lua scripts used to manage job data (see [Issue 93](https://github.com/gocraft/work/issues/93#issuecomment-401134340)). The current workaround is to force the keys for an entire `namespace` for a given worker pool on a single node in the cluster using [Redis Hash Tags](https://redis.io/topics/cluster-spec#keys-hash-tags). Using the example above: ```go func main() { @@ -206,7 +207,7 @@ func main() { ### Contexts -Just like in [gocraft/web](https://www.github.com/gocraft/web), gocraft/work lets you use your own contexts. Your context can be empty or it can have various fields in it. The fields can be whatever you want - it's your type! When a new job is processed by a worker, we'll allocate an instance of this struct and pass it to your middleware and handlers. This allows you to pass information from one middleware function to the next, and onto your handlers. +Just like in [gocraft/web](https://www.github.com/gocraft/web), gojek/work lets you use your own contexts. Your context can be empty or it can have various fields in it. The fields can be whatever you want - it's your type! When a new job is processed by a worker, we'll allocate an instance of this struct and pass it to your middleware and handlers. This allows you to pass information from one middleware function to the next, and onto your handlers. Custom contexts aren't really needed for trivial example applications, but are very important for production apps. For instance, one field in your context can be your tagged logger. Your tagged logger augments your log statements with a job-id. This lets you filter your logs by that job-id. @@ -222,7 +223,7 @@ func (c *Context) Export(job *work.Job) error { for i, row := range rowsToExport { exportRow(row) if i % 1000 == 0 { - job.Checkin("i=" + fmt.Sprint(i)) // Here's the magic! This tells gocraft/work our status + job.Checkin("i=" + fmt.Sprint(i)) // Here's the magic! This tells gojek/work our status } } } @@ -266,7 +267,7 @@ For information on how this map will be serialized to form a unique key, see (ht ### Periodic Enqueueing (Cron) -You can periodically enqueue jobs on your gocraft/work cluster using your worker pool. The [scheduling specification](https://godoc.org/github.com/robfig/cron#hdr-CRON_Expression_Format) uses a Cron syntax where the fields represent seconds, minutes, hours, day of the month, month, and week of the day, respectively. Even if you have multiple worker pools on different machines, they'll all coordinate and only enqueue your job once. +You can periodically enqueue jobs on your gojek/work cluster using your worker pool. The [scheduling specification](https://godoc.org/github.com/robfig/cron#hdr-CRON_Expression_Format) uses a Cron syntax where the fields represent seconds, minutes, hours, day of the month, month, and week of the day, respectively. Even if you have multiple worker pools on different machines, they'll all coordinate and only enqueue your job once. ```go pool := work.NewWorkerPool(Context{}, 10, "my_app_namespace", redisPool) @@ -286,12 +287,12 @@ You can control job concurrency using `JobOptions{MaxConcurrency: }`. Unlik ## Run the Web UI -The web UI provides a view to view the state of your gocraft/work cluster, inspect queued jobs, and retry or delete dead jobs. +The web UI provides a view to view the state of your gojek/work cluster, inspect queued jobs, and retry or delete dead jobs. Building an installing the binary: ```bash -go get github.com/gocraft/work/cmd/workwebui -go install github.com/gocraft/work/cmd/workwebui +go get github.com/gojek/work/cmd/workwebui +go install github.com/gojek/work/cmd/workwebui ``` Then, you can run it: @@ -332,7 +333,7 @@ You'll see a view that looks like this: ### Workers and WorkerPools -* WorkerPools provide the public API of gocraft/work. +* WorkerPools provide the public API of gojek/work. * You can attach jobs and middleware to them. * You can start and stop them. * Based on their concurrency setting, they'll spin up N worker goroutines. diff --git a/benches/bench_work/main.go b/benches/bench_work/main.go index aaf1de69..a4adfbe7 100644 --- a/benches/bench_work/main.go +++ b/benches/bench_work/main.go @@ -7,7 +7,7 @@ import ( "time" "github.com/gocraft/health" - "github.com/gocraft/work" + "github.com/gojek/work" "github.com/gomodule/redigo/redis" ) diff --git a/cmd/workenqueue/main.go b/cmd/workenqueue/main.go index 924f6ec8..836a93ab 100644 --- a/cmd/workenqueue/main.go +++ b/cmd/workenqueue/main.go @@ -7,7 +7,7 @@ import ( "os" "time" - "github.com/gocraft/work" + "github.com/gojek/work" "github.com/gomodule/redigo/redis" ) diff --git a/cmd/workfakedata/main.go b/cmd/workfakedata/main.go index 72e77b04..71fd6b11 100644 --- a/cmd/workfakedata/main.go +++ b/cmd/workfakedata/main.go @@ -6,7 +6,7 @@ import ( "math/rand" "time" - "github.com/gocraft/work" + "github.com/gojek/work" "github.com/gomodule/redigo/redis" ) diff --git a/cmd/workwebui/main.go b/cmd/workwebui/main.go index 6d3e32fc..1407b226 100644 --- a/cmd/workwebui/main.go +++ b/cmd/workwebui/main.go @@ -8,7 +8,7 @@ import ( "strconv" "time" - "github.com/gocraft/work/webui" + "github.com/gojek/work/webui" "github.com/gomodule/redigo/redis" ) diff --git a/dead_pool_reaper_test.go b/dead_pool_reaper_test.go index 48005aef..8146e850 100644 --- a/dead_pool_reaper_test.go +++ b/dead_pool_reaper_test.go @@ -334,7 +334,7 @@ func TestDeadPoolReaperCleanStaleLocks(t *testing.T) { reaper := newDeadPoolReaper(ns, pool, jobNames) // clean lock info for workerPoolID1 - reaper.cleanStaleLockInfo(workerPoolID1, jobNames) + err = reaper.cleanStaleLockInfo(workerPoolID1, jobNames) assert.NoError(t, err) assert.EqualValues(t, 2, getInt64(pool, lock1)) // job1 lock should be decr by 1 assert.EqualValues(t, 1, getInt64(pool, lock2)) // job2 lock is unchanged @@ -342,7 +342,7 @@ func TestDeadPoolReaperCleanStaleLocks(t *testing.T) { assert.Nil(t, v) // now clean lock info for workerPoolID2 - reaper.cleanStaleLockInfo(workerPoolID2, jobNames) + err = reaper.cleanStaleLockInfo(workerPoolID2, jobNames) assert.NoError(t, err) // both locks should be at 0 assert.EqualValues(t, 0, getInt64(pool, lock1)) diff --git a/go.mod b/go.mod index bc63c5ea..79cccafa 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/gocraft/work +module github.com/gojek/work go 1.14 diff --git a/webui/internal/assets/build/work.js b/webui/internal/assets/build/work.js index dd6be7c4..3caaf31d 100644 --- a/webui/internal/assets/build/work.js +++ b/webui/internal/assets/build/work.js @@ -1 +1 @@ -!function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=39)}([function(e,t,n){e.exports=n(41)()},function(e,t,n){"use strict";e.exports=n(40)},function(e,t,n){"use strict";var r=function(e,t,n,r,o,l,i,a){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,l,i,a],s=0;u=new Error(t.replace(/%s/g,function(){return c[s++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}};e.exports=r},function(e,t,n){"use strict";var r=n(1),o=n(59);if(void 0===r)throw Error("create-react-class could not find the React object. If you are using script tags, make sure that React is being loaded before create-react-class.");var l=(new r.Component).updater;e.exports=o(r.Component,r.isValidElement,l)},function(e,t,n){"use strict";var r=function(){};e.exports=r},function(e,t,n){"use strict";function r(e){return null==e||s.a.isValidElement(e)}function o(e){return r(e)||Array.isArray(e)&&e.every(r)}function l(e,t){return f({},e,t)}function i(e){var t=e.type,n=l(t.defaultProps,e.props);if(n.children){var r=a(n.children,n);r.length&&(n.childRoutes=r),delete n.children}return n}function a(e,t){var n=[];return s.a.Children.forEach(e,function(e){if(s.a.isValidElement(e))if(e.type.createRouteFromReactElement){var r=e.type.createRouteFromReactElement(e,t);r&&n.push(r)}else n.push(i(e))}),n}function u(e){return o(e)?e=a(e):e&&!Array.isArray(e)&&(e=[e]),e}t.c=o,t.a=i,t.b=u;var c=n(1),s=n.n(c),f=Object.assign||function(e){for(var t=1;t0||s()(!1),null!=d&&(i+=encodeURI(d));else if("("===c)u[o]="",o+=1;else if(")"===c){var h=u.pop();o-=1,o?u[o-1]+=h:i+=h}else if("\\("===c)i+="(";else if("\\)"===c)i+=")";else if(":"===c.charAt(0))if(f=c.substring(1),d=t[f],null!=d||o>0||s()(!1),null==d){if(o){u[o-1]="";for(var m=r.indexOf(c),g=r.slice(m,r.length),_=-1,v=0;v0||s()(!1),p=m+_-1}}else o?u[o-1]+=encodeURIComponent(d):i+=encodeURIComponent(d);else o?u[o-1]+=c:i+=c;return o<=0||s()(!1),i.replace(/\/+/g,"/")}t.c=i,t.b=a,t.a=u;var c=n(2),s=n.n(c),f=Object.create(null)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.locationsAreEqual=t.statesAreEqual=t.createLocation=t.createQuery=void 0;var o="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},l=Object.assign||function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:"/",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:s.POP,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r="string"==typeof e?(0,c.parsePath)(e):e;return{pathname:r.pathname||"/",search:r.search||"",hash:r.hash||"",state:r.state,action:t,key:n}},function(e){return"[object Date]"===Object.prototype.toString.call(e)}),d=t.statesAreEqual=function e(t,n){if(t===n)return!0;var r=void 0===t?"undefined":o(t);if(r!==(void 0===n?"undefined":o(n)))return!1;if("function"===r&&(0,a.default)(!1),"object"===r){if(f(t)&&f(n)&&(0,a.default)(!1),!Array.isArray(t)){var l=Object.keys(t),i=Object.keys(n);return l.length===i.length&&l.every(function(r){return e(t[r],n[r])})}return Array.isArray(n)&&t.length===n.length&&t.every(function(t,r){return e(t,n[r])})}return!1};t.locationsAreEqual=function(e,t){return e.key===t.key&&e.pathname===t.pathname&&e.search===t.search&&e.hash===t.hash&&d(e.state,t.state)}},function(e,t,n){"use strict";function r(e,t,n){if(e[t])return new Error("<"+n+'> should not have a "'+t+'" prop')}t.c=r,n.d(t,"a",function(){return l}),n.d(t,"b",function(){return i}),n.d(t,"d",function(){return u});var o=n(0),l=(n.n(o),Object(o.shape)({listen:o.func.isRequired,push:o.func.isRequired,replace:o.func.isRequired,go:o.func.isRequired,goBack:o.func.isRequired,goForward:o.func.isRequired}),Object(o.oneOfType)([o.func,o.string])),i=Object(o.oneOfType)([l,o.object]),a=Object(o.oneOfType)([o.object,o.element]),u=Object(o.oneOfType)([a,Object(o.arrayOf)(a)])},function(e,t,n){"use strict";function r(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var o=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,a,u=r(e),c=1;c=e&&u&&(i=!0,n())}}var l=0,i=!1,a=!1,u=!1,c=void 0;o()}function o(e,t,n){function r(e,t,r){i||(t?(i=!0,n(t)):(l[e]=r,(i=++a===o)&&n(null,l)))}var o=e.length,l=[];if(0===o)return n(null,l);var i=!1,a=0;e.forEach(function(e,n){t(e,n,function(e,t){r(n,e,t)})})}t.a=r,t.b=o},function(e,t,n){"use strict";var r=n(2),o=n.n(r),l=n(1),i=n.n(l),a=n(3),u=n.n(a),c=n(0),s=(n.n(c),n(65)),f=n(20),d=n(5),p=Object.assign||function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},t=e.getCurrentLocation,n=e.getUserConfirmation,l=e.pushLocation,c=e.replaceLocation,s=e.go,f=e.keyLength,d=void 0,p=void 0,b=[],h=[],m=[],g=function(){return p&&p.action===a.POP?m.indexOf(p.key):d?m.indexOf(d.key):-1},_=function(e){var t=g();d=e,d.action===a.PUSH?m=[].concat(m.slice(0,t+1),[d.key]):d.action===a.REPLACE&&(m[t]=d.key),h.forEach(function(e){return e(d)})},v=function(e){return b.push(e),function(){return b=b.filter(function(t){return t!==e})}},y=function(e){return h.push(e),function(){return h=h.filter(function(t){return t!==e})}},x=function(e,t){(0,r.loopAsync)(b.length,function(t,n,r){(0,i.default)(b[t],e,function(e){return null!=e?r(e):n()})},function(e){n&&"string"==typeof e?n(e,function(e){return t(!1!==e)}):t(!1!==e)})},w=function(e){d&&(0,u.locationsAreEqual)(d,e)||p&&(0,u.locationsAreEqual)(p,e)||(p=e,x(e,function(t){if(p===e)if(p=null,t){if(e.action===a.PUSH){var n=(0,o.createPath)(d),r=(0,o.createPath)(e);r===n&&(0,u.statesAreEqual)(d.state,e.state)&&(e.action=a.REPLACE)}e.action===a.POP?_(e):e.action===a.PUSH?!1!==l(e)&&_(e):e.action===a.REPLACE&&!1!==c(e)&&_(e)}else if(d&&e.action===a.POP){var i=m.indexOf(d.key),f=m.indexOf(e.key);-1!==i&&-1!==f&&s(i-f)}}))},k=function(e){return w(S(e,a.PUSH))},E=function(e){return w(S(e,a.REPLACE))},P=function(){return s(-1)},O=function(){return s(1)},C=function(){return Math.random().toString(36).substr(2,f||6)},T=function(e){return(0,o.createPath)(e)},S=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:C();return(0,u.createLocation)(e,t,n)};return{getCurrentLocation:t,listenBefore:v,listen:y,transitionTo:w,push:k,replace:E,go:s,goBack:P,goForward:O,createKey:C,createPath:o.createPath,createHref:T,createLocation:S}};t.default=c},function(e,t,n){"use strict";t.__esModule=!0;t.canUseDOM=!("undefined"==typeof window||!window.document||!window.document.createElement)},function(e,t,n){"use strict";t.__esModule=!0,t.go=t.replaceLocation=t.pushLocation=t.startListener=t.getUserConfirmation=t.getCurrentLocation=void 0;var r=n(11),o=n(16),l=n(37),i=n(6),a=n(24),u=a.canUseDOM&&!(0,o.supportsPopstateOnHashchange)(),c=function(e){var t=e&&e.key;return(0,r.createLocation)({pathname:window.location.pathname,search:window.location.search,hash:window.location.hash,state:t?(0,l.readState)(t):void 0},void 0,t)},s=t.getCurrentLocation=function(){var e=void 0;try{e=window.history.state||{}}catch(t){e={}}return c(e)},f=(t.getUserConfirmation=function(e,t){return t(window.confirm(e))},t.startListener=function(e){var t=function(t){(0,o.isExtraneousPopstateEvent)(t)||e(c(t.state))};(0,o.addEventListener)(window,"popstate",t);var n=function(){return e(s())};return u&&(0,o.addEventListener)(window,"hashchange",n),function(){(0,o.removeEventListener)(window,"popstate",t),u&&(0,o.removeEventListener)(window,"hashchange",n)}},function(e,t){var n=e.state,r=e.key;void 0!==n&&(0,l.saveState)(r,n),t({key:r},(0,i.createPath)(e))});t.pushLocation=function(e){return f(e,function(e,t){return window.history.pushState(e,null,t)})},t.replaceLocation=function(e){return f(e,function(e,t){return window.history.replaceState(e,null,t)})},t.go=function(e){e&&window.history.go(e)}},function(e,t){function n(e,t){var n=e[1]||"",o=e[3];if(!o)return n;if(t&&"function"==typeof btoa){var l=r(o);return[n].concat(o.sources.map(function(e){return"/*# sourceURL="+o.sourceRoot+e+" */"})).concat([l]).join("\n")}return[n].join("\n")}function r(e){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */"}e.exports=function(e){var t=[];return t.toString=function(){return this.map(function(t){var r=n(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r}).join("")},t.i=function(e,n){"string"==typeof e&&(e=[[null,e,""]]);for(var r={},o=0;o=0&&v.splice(t,1)}function a(e){var t=document.createElement("style");return e.attrs.type="text/css",c(t,e.attrs),l(e,t),t}function u(e){var t=document.createElement("link");return e.attrs.type="text/css",e.attrs.rel="stylesheet",c(t,e.attrs),l(e,t),t}function c(e,t){Object.keys(t).forEach(function(n){e.setAttribute(n,t[n])})}function s(e,t){var n,r,o,l;if(t.transform&&e.css){if(!(l=t.transform(e.css)))return function(){};e.css=l}if(t.singleton){var c=_++;n=g||(g=a(t)),r=f.bind(null,n,c,!1),o=f.bind(null,n,c,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=u(t),r=p.bind(null,n,t),o=function(){i(n),n.href&&URL.revokeObjectURL(n.href)}):(n=a(t),r=d.bind(null,n),o=function(){i(n)});return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else o()}}function f(e,t,n,r){var o=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=x(t,o);else{var l=document.createTextNode(o),i=e.childNodes;i[t]&&e.removeChild(i[t]),i.length?e.insertBefore(l,i[t]):e.appendChild(l)}}function d(e,t){var n=t.css,r=t.media;if(r&&e.setAttribute("media",r),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}function p(e,t,n){var r=n.css,o=n.sourceMap,l=void 0===t.convertToAbsoluteUrls&&o;(t.convertToAbsoluteUrls||l)&&(r=y(r)),o&&(r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */");var i=new Blob([r],{type:"text/css"}),a=e.href;e.href=URL.createObjectURL(i),a&&URL.revokeObjectURL(a)}var b={},h=function(e){var t;return function(){return void 0===t&&(t=e.apply(this,arguments)),t}}(function(){return window&&document&&document.all&&!window.atob}),m=function(e){var t={};return function(n){if(void 0===t[n]){var r=e.call(this,n);if(r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}t[n]=r}return t[n]}}(function(e){return document.querySelector(e)}),g=null,_=0,v=[],y=n(51);e.exports=function(e,t){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");t=t||{},t.attrs="object"==typeof t.attrs?t.attrs:{},t.singleton||"boolean"==typeof t.singleton||(t.singleton=h()),t.insertInto||(t.insertInto="head"),t.insertAt||(t.insertAt="bottom");var n=o(e,t);return r(n,t),function(e){for(var l=[],i=0;i1&&void 0!==arguments[1]&&arguments[1];return e.__id__||t&&(e.__id__=P++)}function p(e){return e.map(function(e){return O[d(e)]}).filter(function(e){return e})}function b(e,n){Object(c.a)(t,e,function(t,r){if(null==r)return void n();E=s({},r,{location:e});for(var o=p(Object(l.a)(v,E).leaveRoutes),i=void 0,a=0,u=o.length;null==i&&a=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e){return 0===e.button}function l(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function i(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))return!1;return!0}function a(e,t){return"function"==typeof e?e(t.location):e}var u=n(1),c=n.n(u),s=n(3),f=n.n(s),d=n(0),p=(n.n(d),n(2)),b=n.n(p),h=n(21),m=n(20),g=Object.assign||function(e){for(var t=1;t=0;r--){var o=e[r],l=o.path||"";if(n=l.replace(/\/*$/,"/")+n,0===l.indexOf("/"))break}return"/"+n}},propTypes:{path:l.string,from:l.string,to:l.string.isRequired,query:l.object,state:l.object,onEnter:s.c,children:s.c},render:function(){a()(!1)}});t.a=f},function(e,t,n){"use strict";function r(e){var t=c()(e),n=function(){return t};return l()(a()(n))(e)}t.a=r;var o=n(34),l=n.n(o),i=n(35),a=n.n(i),u=n(75),c=n.n(u)},function(e,t,n){"use strict";t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},n=e(t),o=t.stringifyQuery,l=t.parseQueryString;"function"!=typeof o&&(o=c),"function"!=typeof l&&(l=s);var f=function(e){return e?(null==e.query&&(e.query=l(e.search.substring(1))),e):e},d=function(e,t){if(null==t)return e;var n="string"==typeof e?(0,u.parsePath)(e):e,l=o(t);return r({},n,{search:l?"?"+l:""})};return r({},n,{getCurrentLocation:function(){return f(n.getCurrentLocation())},listenBefore:function(e){return n.listenBefore(function(t,n){return(0,i.default)(e,f(t),n)})},listen:function(e){return n.listen(function(t){return e(f(t))})},push:function(e){return n.push(d(e,e.query))},replace:function(e){return n.replace(d(e,e.query))},createPath:function(e){return n.createPath(d(e,e.query))},createHref:function(e){return n.createHref(d(e,e.query))},createLocation:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:{},n=e(t),o=t.basename,a=function(e){return e?(o&&null==e.basename&&(0===e.pathname.toLowerCase().indexOf(o.toLowerCase())?(e.pathname=e.pathname.substring(o.length),e.basename=o,""===e.pathname&&(e.pathname="/")):e.basename=""),e):e},u=function(e){if(!o)return e;var t="string"==typeof e?(0,i.parsePath)(e):e,n=t.pathname,l="/"===o.slice(-1)?o:o+"/",a="/"===n.charAt(0)?n.slice(1):n;return r({},t,{pathname:l+a})};return r({},n,{getCurrentLocation:function(){return a(n.getCurrentLocation())},listenBefore:function(e){return n.listenBefore(function(t,n){return(0,l.default)(e,a(t),n)})},listen:function(e){return n.listen(function(t){return e(a(t))})},push:function(e){return n.push(u(e))},replace:function(e){return n.replace(u(e))},createPath:function(e){return n.createPath(u(e))},createHref:function(e){return n.createHref(u(e))},createLocation:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),o=1;oz.length&&z.push(e)}function p(e,t,n,o){var l=typeof e;"undefined"!==l&&"boolean"!==l||(e=null);var i=!1;if(null===e)i=!0;else switch(l){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case w:case k:i=!0}}if(i)return n(o,e,""===t?"."+h(e,0):t),1;if(i=0,t=""===t?".":t+":",Array.isArray(e))for(var a=0;at}return!1}function w(e,t,n,r,o,l){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=l}function k(e){return e[1].toUpperCase()}function E(e,t,n,r){var o=pl.hasOwnProperty(t)?pl[t]:null;(null!==o?0===o.type:!r&&(2=n.length))throw Error(r(93));n=n[0]}t=n}null==t&&(t=""),n=t}e._wrapperState={initialValue:S(n)}}function X(e,t){var n=S(t.value),r=S(t.defaultValue);null!=n&&(n=""+n,n!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function V(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}function K(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function G(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?K(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}function Q(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}function B(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}function Z(e){if(Il[e])return Il[e];if(!Ul[e])return e;var t,n=Ul[e];for(t in n)if(n.hasOwnProperty(t)&&t in Dl)return Il[e]=n[t];return e}function J(e){var t=Kl.get(e);return void 0===t&&(t=new Map,Kl.set(e,t)),t}function $(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{t=e,0!=(1026&t.effectTag)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function ee(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function te(e){if($(e)!==e)throw Error(r(188))}function ne(e){var t=e.alternate;if(!t){if(null===(t=$(e)))throw Error(r(188));return t!==e?null:e}for(var n=e,o=t;;){var l=n.return;if(null===l)break;var i=l.alternate;if(null===i){if(null!==(o=l.return)){n=o;continue}break}if(l.child===i.child){for(i=l.child;i;){if(i===n)return te(l),e;if(i===o)return te(l),t;i=i.sibling}throw Error(r(188))}if(n.return!==o.return)n=l,o=i;else{for(var a=!1,u=l.child;u;){if(u===n){a=!0,n=l,o=i;break}if(u===o){a=!0,o=l,n=i;break}u=u.sibling}if(!a){for(u=i.child;u;){if(u===n){a=!0,n=i,o=l;break}if(u===o){a=!0,o=i,n=l;break}u=u.sibling}if(!a)throw Error(r(189))}}if(n.alternate!==o)throw Error(r(190))}if(3!==n.tag)throw Error(r(188));return n.stateNode.current===n?e:t}function re(e){if(!(e=ne(e)))return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function oe(e,t){if(null==t)throw Error(r(30));return null==e?t:Array.isArray(e)?Array.isArray(t)?(e.push.apply(e,t),e):(e.push(t),e):Array.isArray(t)?[e].concat(t):[e,t]}function le(e,t,n){Array.isArray(e)?e.forEach(t,n):e&&t.call(n,e)}function ie(e){if(e){var t=e._dispatchListeners,n=e._dispatchInstances;if(Array.isArray(t))for(var r=0;rQl.length&&Ql.push(e)}function fe(e,t,n,r){if(Ql.length){var o=Ql.pop();return o.topLevelType=e,o.eventSystemFlags=r,o.nativeEvent=t,o.targetInst=n,o}return{topLevelType:e,eventSystemFlags:r,nativeEvent:t,targetInst:n,ancestors:[]}}function de(e){var t=e.targetInst,n=t;do{if(!n){e.ancestors.push(n);break}var r=n;if(3===r.tag)r=r.stateNode.containerInfo;else{for(;r.return;)r=r.return;r=3!==r.tag?null:r.stateNode.containerInfo}if(!r)break;t=n.tag,5!==t&&6!==t||e.ancestors.push(n),n=Ge(r)}while(n);for(n=0;n=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Ye(n)}}function ze(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?ze(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function Ae(){for(var e=window,t=De();t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(e){n=!1}if(!n)break;e=t.contentWindow,t=De(e.document)}return t}function Fe(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}function We(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function Xe(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}function Ve(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Ke(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if(n===vi||n===wi||n===xi){if(0===t)return e;t--}else n===yi&&t++}e=e.previousSibling}return null}function Ge(e){var t=e[Ti];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Mi]||n[Ti]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Ke(e);null!==e;){if(n=e[Ti])return n;e=Ke(e)}return t}e=n,n=e.parentNode}return null}function Qe(e){return e=e[Ti]||e[Mi],!e||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function Be(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(r(33))}function Ze(e){return e[Si]||null}function Je(e){do{e=e.return}while(e&&5!==e.tag);return e||null}function $e(e,t){var n=e.stateNode;if(!n)return null;var o=Ko(n);if(!o)return null;n=o[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(e=e.type,o=!("button"===e||"input"===e||"select"===e||"textarea"===e)),e=!o;break e;default:e=!1}if(e)return null;if(n&&"function"!=typeof n)throw Error(r(231,t,typeof n));return n}function et(e,t,n){(t=$e(e,n.dispatchConfig.phasedRegistrationNames[t]))&&(n._dispatchListeners=oe(n._dispatchListeners,t),n._dispatchInstances=oe(n._dispatchInstances,e))}function tt(e){if(e&&e.dispatchConfig.phasedRegistrationNames){for(var t=e._targetInst,n=[];t;)n.push(t),t=Je(t);for(t=n.length;0this.eventPool.length&&this.eventPool.push(e)}function ft(e){e.eventPool=[],e.getPooled=ct,e.release=st}function dt(e,t){switch(e){case"keyup":return-1!==Ui.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"blur":return!0;default:return!1}}function pt(e){return e=e.detail,"object"==typeof e&&"data"in e?e.data:null}function bt(e,t){switch(e){case"compositionend":return pt(t);case"keypress":return 32!==t.which?null:(Fi=!0,zi);case"textInput":return e=t.data,e===zi&&Fi?null:e;default:return null}}function ht(e,t){if(Wi)return"compositionend"===e||!Ii&&dt(e,t)?(e=lt(),Ri=ji=Li=null,Wi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1Na||(e.current=Ra[Na],Ra[Na]=null,Na--)}function Nt(e,t){Na++,Ra[Na]=e.current,e.current=t}function Ht(e,t){var n=e.type.contextTypes;if(!n)return Ha;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o,l={};for(o in n)l[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Ut(e){return null!==(e=e.childContextTypes)&&void 0!==e}function It(){Rt(Ia),Rt(Ua)}function Dt(e,t,n){if(Ua.current!==Ha)throw Error(r(168));Nt(Ua,t),Nt(Ia,n)}function Yt(e,t,n){var o=e.stateNode;if(e=t.childContextTypes,"function"!=typeof o.getChildContext)return n;o=o.getChildContext();for(var l in o)if(!(l in e))throw Error(r(108,C(t)||"Unknown",l));return qo({},n,{},o)}function qt(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ha,Da=Ua.current,Nt(Ua,e),Nt(Ia,Ia.current),!0}function zt(e,t,n){var o=e.stateNode;if(!o)throw Error(r(169));n?(e=Yt(e,t,Da),o.__reactInternalMemoizedMergedChildContext=e,Rt(Ia),Rt(Ua),Nt(Ua,e)):Rt(Ia),Nt(Ia,n)}function At(){switch(Wa()){case Xa:return 99;case Va:return 98;case Ka:return 97;case Ga:return 96;case Qa:return 95;default:throw Error(r(332))}}function Ft(e){switch(e){case 99:return Xa;case 98:return Va;case 97:return Ka;case 96:return Ga;case 95:return Qa;default:throw Error(r(332))}}function Wt(e,t){return e=Ft(e),Ya(e,t)}function Xt(e,t,n){return e=Ft(e),qa(e,t,n)}function Vt(e){return null===$a?($a=[e],eu=qa(Xa,Gt)):$a.push(e),Ba}function Kt(){if(null!==eu){var e=eu;eu=null,za(e)}Gt()}function Gt(){if(!tu&&null!==$a){tu=!0;var e=0;try{var t=$a;Wt(99,function(){for(;e=t&&(Hu=!0),e.firstContext=null)}function tn(e,t){if(au!==e&&!1!==t&&0!==t)if("number"==typeof t&&1073741823!==t||(au=e,t=1073741823),t={context:e,observedBits:t,next:null},null===iu){if(null===lu)throw Error(r(308));iu=t,lu.dependencies={expirationTime:0,firstContext:t,responders:null}}else iu=iu.next=t;return e._currentValue}function nn(e){e.updateQueue={baseState:e.memoizedState,baseQueue:null,shared:{pending:null},effects:null}}function rn(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,baseQueue:e.baseQueue,shared:e.shared,effects:e.effects})}function on(e,t){return e={expirationTime:e,suspenseConfig:t,tag:0,payload:null,callback:null,next:null},e.next=e}function ln(e,t){if(null!==(e=e.updateQueue)){e=e.shared;var n=e.pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function an(e,t){var n=e.alternate;null!==n&&rn(n,e),e=e.updateQueue,n=e.baseQueue,null===n?(e.baseQueue=t.next=t,t.next=t):(t.next=n.next,n.next=t)}function un(e,t,n,r){var o=e.updateQueue;uu=!1;var l=o.baseQueue,i=o.shared.pending;if(null!==i){if(null!==l){var a=l.next;l.next=i.next,i.next=a}l=i,o.shared.pending=null,a=e.alternate,null!==a&&null!==(a=a.updateQueue)&&(a.baseQueue=i)}if(null!==l){a=l.next;var u=o.baseState,c=0,s=null,f=null,d=null;if(null!==a)for(var p=a;;){if((i=p.expirationTime)c&&(c=i)}else{null!==d&&(d=d.next={expirationTime:1073741823,suspenseConfig:p.suspenseConfig,tag:p.tag,payload:p.payload,callback:p.callback,next:null}),Zr(i,p.suspenseConfig);e:{var h=e,m=p;switch(i=t,b=n,m.tag){case 1:if("function"==typeof(h=m.payload)){u=h.call(b,u,i);break e}u=h;break e;case 3:h.effectTag=-4097&h.effectTag|64;case 0:if(h=m.payload,null===(i="function"==typeof h?h.call(b,u,i):h)||void 0===i)break e;u=qo({},u,i);break e;case 2:uu=!0}}null!==p.callback&&(e.effectTag|=32,i=o.effects,null===i?o.effects=[p]:i.push(p))}if(null===(p=p.next)||p===a){if(null===(i=o.shared.pending))break;p=l.next=i.next,i.next=a,o.baseQueue=l=i,o.shared.pending=null}}null===d?s=u:d.next=f,o.baseState=s,o.baseQueue=d,Jr(c),e.expirationTime=c,e.memoizedState=u}}function cn(e,t,n){if(e=t.effects,t.effects=null,null!==e)for(t=0;th?(m=f,f=null):m=f.sibling;var g=p(r,f,a[h],u);if(null===g){null===f&&(f=m);break}e&&f&&null===g.alternate&&t(r,f),l=i(g,l,h),null===s?c=g:s.sibling=g,s=g,f=m}if(h===a.length)return n(r,f),c;if(null===f){for(;hm?(g=h,h=null):g=h.sibling;var v=p(l,h,_.value,c);if(null===v){null===h&&(h=g);break}e&&h&&null===v.alternate&&t(l,h),a=i(v,a,m),null===f?s=v:f.sibling=v,f=v,h=g}if(_.done)return n(l,h),s;if(null===h){for(;!_.done;m++,_=u.next())null!==(_=d(l,_.value,c))&&(a=i(_,a,m),null===f?s=_:f.sibling=_,f=_);return s}for(h=o(l,h);!_.done;m++,_=u.next())null!==(_=b(h,l,m,_.value,c))&&(e&&null!==_.alternate&&h.delete(null===_.key?m:_.key),a=i(_,a,m),null===f?s=_:f.sibling=_,f=_);return e&&h.forEach(function(e){return t(l,e)}),s}return function(e,o,i,u){var c="object"==typeof i&&null!==i&&i.type===xl&&null===i.key;c&&(i=i.props.children);var s="object"==typeof i&&null!==i;if(s)switch(i.$$typeof){case vl:e:{for(s=i.key,c=o;null!==c;){if(c.key===s){switch(c.tag){case 7:if(i.type===xl){n(e,c.sibling),o=l(c,i.props.children),o.return=e,e=o;break e}break;default:if(c.elementType===i.type){n(e,c.sibling),o=l(c,i.props),o.ref=hn(e,c,i),o.return=e,e=o;break e}}n(e,c);break}t(e,c),c=c.sibling}i.type===xl?(o=xo(i.props.children,e.mode,u,i.key),o.return=e,e=o):(u=yo(i.type,i.key,i.props,null,e.mode,u),u.ref=hn(e,o,i),u.return=e,e=u)}return a(e);case yl:e:{for(c=i.key;null!==o;){if(o.key===c){if(4===o.tag&&o.stateNode.containerInfo===i.containerInfo&&o.stateNode.implementation===i.implementation){n(e,o.sibling),o=l(o,i.children||[]),o.return=e,e=o;break e}n(e,o);break}t(e,o),o=o.sibling}o=ko(i,e.mode,u),o.return=e,e=o}return a(e)}if("string"==typeof i||"number"==typeof i)return i=""+i,null!==o&&6===o.tag?(n(e,o.sibling),o=l(o,i),o.return=e,e=o):(n(e,o),o=wo(i,e.mode,u),o.return=e,e=o),a(e);if(du(i))return h(e,o,i,u);if(P(i))return m(e,o,i,u);if(s&&mn(e,i),void 0===i&&!c)switch(e.tag){case 1:case 0:throw e=e.type,Error(r(152,e.displayName||e.name||"Component"))}return n(e,o)}}function _n(e){if(e===hu)throw Error(r(174));return e}function vn(e,t){switch(Nt(_u,t),Nt(gu,e),Nt(mu,hu),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:G(null,"");break;default:e=8===e?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=G(t,e)}Rt(mu),Nt(mu,t)}function yn(){Rt(mu),Rt(gu),Rt(_u)}function xn(e){_n(_u.current);var t=_n(mu.current),n=G(t,e.type);t!==n&&(Nt(gu,e),Nt(mu,n))}function wn(e){gu.current===e&&(Rt(mu),Rt(gu))}function kn(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||n.data===xi||n.data===wi))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!=(64&t.effectTag))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}function En(e,t){return{responder:e,props:t}}function Pn(){throw Error(r(321))}function On(e,t){if(null===t)return!1;for(var n=0;ni))throw Error(r(301));i+=1,Pu=Eu=null,t.updateQueue=null,yu.current=Mu,e=n(o,l)}while(t.expirationTime===wu)}if(yu.current=Cu,t=null!==Eu&&null!==Eu.next,wu=0,Pu=Eu=ku=null,Ou=!1,t)throw Error(r(300));return e}function Tn(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===Pu?ku.memoizedState=Pu=e:Pu=Pu.next=e,Pu}function Sn(){if(null===Eu){var e=ku.alternate;e=null!==e?e.memoizedState:null}else e=Eu.next;var t=null===Pu?ku.memoizedState:Pu.next;if(null!==t)Pu=t,Eu=e;else{if(null===e)throw Error(r(310));Eu=e,e={memoizedState:Eu.memoizedState,baseState:Eu.baseState,baseQueue:Eu.baseQueue,queue:Eu.queue,next:null},null===Pu?ku.memoizedState=Pu=e:Pu=Pu.next=e}return Pu}function Mn(e,t){return"function"==typeof t?t(e):t}function Ln(e){var t=Sn(),n=t.queue;if(null===n)throw Error(r(311));n.lastRenderedReducer=e;var o=Eu,l=o.baseQueue,i=n.pending;if(null!==i){if(null!==l){var a=l.next;l.next=i.next,i.next=a}o.baseQueue=l=i,n.pending=null}if(null!==l){l=l.next,o=o.baseState;var u=a=i=null,c=l;do{var s=c.expirationTime;if(sku.expirationTime&&(ku.expirationTime=s,Jr(s))}else null!==u&&(u=u.next={expirationTime:1073741823,suspenseConfig:c.suspenseConfig,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),Zr(s,c.suspenseConfig),o=c.eagerReducer===e?c.eagerState:e(o,c.action);c=c.next}while(null!==c&&c!==l);null===u?i=o:u.next=a,ua(o,t.memoizedState)||(Hu=!0),t.memoizedState=o,t.baseState=i,t.baseQueue=u,n.lastRenderedState=o}return[t.memoizedState,n.dispatch]}function jn(e){var t=Sn(),n=t.queue;if(null===n)throw Error(r(311));n.lastRenderedReducer=e;var o=n.dispatch,l=n.pending,i=t.memoizedState;if(null!==l){n.pending=null;var a=l=l.next;do{i=e(i,a.action),a=a.next}while(a!==l);ua(i,t.memoizedState)||(Hu=!0),t.memoizedState=i,null===t.baseQueue&&(t.baseState=i),n.lastRenderedState=i}return[i,o]}function Rn(e){var t=Tn();return"function"==typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=t.queue={pending:null,dispatch:null,lastRenderedReducer:Mn,lastRenderedState:e},e=e.dispatch=Gn.bind(null,ku,e),[t.memoizedState,e]}function Nn(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=ku.updateQueue,null===t?(t={lastEffect:null},ku.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,null===n?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function Hn(){return Sn().memoizedState}function Un(e,t,n,r){var o=Tn();ku.effectTag|=e,o.memoizedState=Nn(1|t,n,void 0,void 0===r?null:r)}function In(e,t,n,r){var o=Sn();r=void 0===r?null:r;var l=void 0;if(null!==Eu){var i=Eu.memoizedState;if(l=i.destroy,null!==r&&On(r,i.deps))return void Nn(t,n,l,r)}ku.effectTag|=e,o.memoizedState=Nn(1|t,n,l,r)}function Dn(e,t){return Un(516,4,e,t)}function Yn(e,t){return In(516,4,e,t)}function qn(e,t){return In(4,2,e,t)}function zn(e,t){return"function"==typeof t?(e=e(),t(e),function(){t(null)}):null!==t&&void 0!==t?(e=e(),t.current=e,function(){t.current=null}):void 0}function An(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,In(4,2,zn.bind(null,t,e),n)}function Fn(){}function Wn(e,t){return Tn().memoizedState=[e,void 0===t?null:t],e}function Xn(e,t){var n=Sn();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&On(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Vn(e,t){var n=Sn();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&On(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Kn(e,t,n){var r=At();Wt(98>r?98:r,function(){e(!0)}),Wt(97<\/script>",e=e.removeChild(e.firstChild)):"string"==typeof o.is?e=a.createElement(l,{is:o.is}):(e=a.createElement(l),"select"===l&&(a=e,o.multiple?a.multiple=!0:o.size&&(a.size=o.size))):e=a.createElementNS(e,l),e[Ti]=t,e[Si]=o,Sa(e,t,!1,!1),t.stateNode=e,a=He(l,o),l){case"iframe":case"object":case"embed":Oe("load",e),u=o;break;case"video":case"audio":for(u=0;uo.tailExpiration&&1t)&&vc.set(e,t))}}function qr(e,t){e.expirationTimee?n:e,2>=e&&t!==e?0:e}function Ar(e){if(0!==e.lastExpiredTime)e.callbackExpirationTime=1073741823,e.callbackPriority=99,e.callbackNode=Vt(Wr.bind(null,e));else{var t=zr(e),n=e.callbackNode;if(0===t)null!==n&&(e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90);else{var r=Ir();if(1073741823===t?r=99:1===t||2===t?r=95:(r=10*(1073741821-t)-10*(1073741821-r),r=0>=r?99:250>=r?98:5250>=r?97:95),null!==n){var o=e.callbackPriority;if(e.callbackExpirationTime===t&&o>=r)return;n!==Ba&&za(n)}e.callbackExpirationTime=t,e.callbackPriority=r,t=1073741823===t?Vt(Wr.bind(null,e)):Xt(r,Fr.bind(null,e),{timeout:10*(1073741821-t)-ru()}),e.callbackNode=t}}}function Fr(e,t){if(wc=0,t)return t=Ir(),To(e,t),Ar(e),null;var n=zr(e);if(0!==n){if(t=e.callbackNode,($u&(Xu|Vu))!==Fu)throw Error(r(327));if(ao(),e===ec&&n===nc||Gr(e,n),null!==tc){var o=$u;$u|=Xu;for(var l=Br();;)try{eo();break}catch(t){Qr(e,t)}if(Zt(),$u=o,zu.current=l,rc===Gu)throw t=oc,Gr(e,n),Oo(e,n),Ar(e),t;if(null===tc)switch(l=e.finishedWork=e.current.alternate,e.finishedExpirationTime=n,o=rc,ec=null,o){case Ku:case Gu:throw Error(r(345));case Qu:To(e,2=n){e.lastPingedTime=n,Gr(e,n);break}}if(0!==(i=zr(e))&&i!==n)break;if(0!==o&&o!==n){e.lastPingedTime=o;break}e.timeoutHandle=Pi(oo.bind(null,e),l);break}oo(e);break;case Zu:if(Oo(e,n),o=e.lastSuspendedTime,n===o&&(e.nextKnownPendingLevel=ro(l)),cc&&(0===(l=e.lastPingedTime)||l>=n)){e.lastPingedTime=n,Gr(e,n);break}if(0!==(l=zr(e))&&l!==n)break;if(0!==o&&o!==n){e.lastPingedTime=o;break}if(1073741823!==ic?o=10*(1073741821-ic)-ru():1073741823===lc?o=0:(o=10*(1073741821-lc)-5e3,l=ru(),n=10*(1073741821-n)-l,o=l-o,0>o&&(o=0),o=(120>o?120:480>o?480:1080>o?1080:1920>o?1920:3e3>o?3e3:4320>o?4320:1960*qu(o/1960))-o,n=o?o=0:(l=0|a.busyDelayMs,i=ru()-(10*(1073741821-i)-(0|a.timeoutMs||5e3)),o=i<=l?0:l+o-i),10 component higher in the tree to provide a loading indicator or placeholder to display."+T(i))}rc!==Ju&&(rc=Qu),a=_r(a,i),f=l;do{switch(f.tag){case 3:u=a,f.effectTag|=4096,f.expirationTime=t;an(f,Hr(f,u,t));break e;case 1:u=a;var y=f.type,x=f.stateNode;if(0==(64&f.effectTag)&&("function"==typeof y.getDerivedStateFromError||null!==x&&"function"==typeof x.componentDidCatch&&(null===hc||!hc.has(x)))){f.effectTag|=4096,f.expirationTime=t;an(f,Ur(f,u,t));break e}}f=f.return}while(null!==f)}tc=no(tc)}catch(e){t=e;continue}break}}function Br(){var e=zu.current;return zu.current=Cu,null===e?Cu:e}function Zr(e,t){euc&&(uc=e)}function $r(){for(;null!==tc;)tc=to(tc)}function eo(){for(;null!==tc&&!Za();)tc=to(tc)}function to(e){var t=Iu(e.alternate,e,nc);return e.memoizedProps=e.pendingProps,null===t&&(t=no(e)),Au.current=null,t}function no(e){tc=e;do{var t=tc.alternate;if(e=tc.return,0==(2048&tc.effectTag)){if(t=mr(t,tc,nc),1===nc||1!==tc.childExpirationTime){for(var n=0,r=tc.child;null!==r;){var o=r.expirationTime,l=r.childExpirationTime;o>n&&(n=o),l>n&&(n=l),r=r.sibling}tc.childExpirationTime=n}if(null!==t)return t;null!==e&&0==(2048&e.effectTag)&&(null===e.firstEffect&&(e.firstEffect=tc.firstEffect),null!==tc.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=tc.firstEffect),e.lastEffect=tc.lastEffect),1e?t:e}function oo(e){var t=At();return Wt(99,lo.bind(null,e,t)),null}function lo(e,t){do{ao()}while(null!==gc);if(($u&(Xu|Vu))!==Fu)throw Error(r(327));var n=e.finishedWork,o=e.finishedExpirationTime;if(null===n)return null;if(e.finishedWork=null,e.finishedExpirationTime=0,n===e.current)throw Error(r(177));e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90,e.nextKnownPendingLevel=0;var l=ro(n);if(e.firstPendingTime=l,o<=e.lastSuspendedTime?e.firstSuspendedTime=e.lastSuspendedTime=e.nextKnownPendingLevel=0:o<=e.firstSuspendedTime&&(e.firstSuspendedTime=o-1),o<=e.lastPingedTime&&(e.lastPingedTime=0),o<=e.lastExpiredTime&&(e.lastExpiredTime=0),e===ec&&(tc=ec=null,nc=0),1u&&(s=u,u=a,a=s),s=qe(y,a),f=qe(y,u),s&&f&&(1!==w.rangeCount||w.anchorNode!==s.node||w.anchorOffset!==s.offset||w.focusNode!==f.node||w.focusOffset!==f.offset)&&(x=x.createRange(),x.setStart(s.node,s.offset),w.removeAllRanges(),a>u?(w.addRange(x),w.extend(f.node,f.offset)):(x.setEnd(f.node,f.offset),w.addRange(x)))))),x=[];for(w=y;w=w.parentNode;)1===w.nodeType&&x.push({element:w,left:w.scrollLeft,top:w.scrollTop});for("function"==typeof y.focus&&y.focus(),y=0;y=t&&e<=t}function Oo(e,t){var n=e.firstSuspendedTime,r=e.lastSuspendedTime;nt||0===n)&&(e.lastSuspendedTime=t),t<=e.lastPingedTime&&(e.lastPingedTime=0),t<=e.lastExpiredTime&&(e.lastExpiredTime=0)}function Co(e,t){t>e.firstPendingTime&&(e.firstPendingTime=t);var n=e.firstSuspendedTime;0!==n&&(t>=n?e.firstSuspendedTime=e.lastSuspendedTime=e.nextKnownPendingLevel=0:t>=e.lastSuspendedTime&&(e.lastSuspendedTime=t+1),t>e.nextKnownPendingLevel&&(e.nextKnownPendingLevel=t))}function To(e,t){var n=e.lastExpiredTime;(0===n||n>t)&&(e.lastExpiredTime=t)}function So(e,t,n,o){var l=t.current,i=Ir(),a=cu.suspense;i=Dr(i,l,a);e:if(n){n=n._reactInternalFiber;t:{if($(n)!==n||1!==n.tag)throw Error(r(170));var u=n;do{switch(u.tag){case 3:u=u.stateNode.context;break t;case 1:if(Ut(u.type)){u=u.stateNode.__reactInternalMemoizedMergedChildContext;break t}}u=u.return}while(null!==u);throw Error(r(171))}if(1===n.tag){var c=n.type;if(Ut(c)){n=Yt(n,c,u);break e}}n=u}else n=Ha;return null===t.context?t.context=n:t.pendingContext=n,t=on(i,a),t.payload={element:e},o=void 0===o?null:o,null!==o&&(t.callback=o),ln(l,t),Yr(l,i),i}function Mo(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:default:return e.child.stateNode}}function Lo(e,t){null!==(e=e.memoizedState)&&null!==e.dehydrated&&e.retryTime