From 645fc02cf68af372e6a2798179f40c570261e5d7 Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 14:44:57 -0700 Subject: [PATCH 01/14] feat: Migrate Camera Management example to V3 closes #194 Signed-off-by: Leonard Goodell --- .../custom/camera-management/Makefile | 4 +- .../custom/camera-management/appcamera/app.go | 6 +- .../camera-management/appcamera/commands.go | 5 +- .../appcamera/credentials.go | 6 +- .../camera-management/appcamera/evam.go | 10 +- .../camera-management/appcamera/routes.go | 4 +- .../camera-management/appcamera/util.go | 21 +- .../custom/camera-management/go.mod | 68 ++-- .../custom/camera-management/go.sum | 300 ++++++------------ .../custom/camera-management/main.go | 4 +- .../camera-management/res/configuration.toml | 145 --------- .../camera-management/res/configuration.yaml | 43 +++ 12 files changed, 198 insertions(+), 418 deletions(-) delete mode 100644 application-services/custom/camera-management/res/configuration.toml create mode 100644 application-services/custom/camera-management/res/configuration.yaml diff --git a/application-services/custom/camera-management/Makefile b/application-services/custom/camera-management/Makefile index d54f4016..2db6266d 100644 --- a/application-services/custom/camera-management/Makefile +++ b/application-services/custom/camera-management/Makefile @@ -11,10 +11,10 @@ APPVERSION=$(shell cat ./VERSION 2>/dev/null || echo 0.0.0) # This pulls the version of the SDK from the go.mod file. If the SDK is the only required module, # it must first remove the word 'required' so the offset of $2 is the same if there are multiple required modules -SDKVERSION=$(shell cat ./go.mod | grep 'github.com/edgexfoundry/app-functions-sdk-go/v2 v' | sed 's/require//g' | awk '{print $$2}') +SDKVERSION=$(shell cat ./go.mod | grep 'github.com/edgexfoundry/app-functions-sdk-go/v3 v' | sed 's/require//g' | awk '{print $$2}') MICROSERVICE=app-camera-management -GOFLAGS=-ldflags "-X github.com/edgexfoundry/app-functions-sdk-go/v2/internal.SDKVersion=$(SDKVERSION) -X github.com/edgexfoundry/app-functions-sdk-go/v2/internal.ApplicationVersion=$(APPVERSION)" +GOFLAGS=-ldflags "-X github.com/edgexfoundry/app-functions-sdk-go/v3/internal.SDKVersion=$(SDKVERSION) -X github.com/edgexfoundry/app-functions-sdk-go/v3/internal.ApplicationVersion=$(APPVERSION)" GIT_SHA=$(shell git rev-parse HEAD) diff --git a/application-services/custom/camera-management/appcamera/app.go b/application-services/custom/camera-management/appcamera/app.go index a51967d2..307b02ec 100644 --- a/application-services/custom/camera-management/appcamera/app.go +++ b/application-services/custom/camera-management/appcamera/app.go @@ -9,8 +9,8 @@ import ( "net/http" "sync" - "github.com/edgexfoundry/app-functions-sdk-go/v2/pkg/interfaces" - "github.com/edgexfoundry/go-mod-core-contracts/v2/clients/logger" + "github.com/edgexfoundry/app-functions-sdk-go/v3/pkg/interfaces" + "github.com/edgexfoundry/go-mod-core-contracts/v3/clients/logger" "github.com/pkg/errors" ) @@ -67,7 +67,7 @@ func (app *CameraManagementApp) Run() error { } } - if err = app.service.MakeItRun(); err != nil { + if err = app.service.Run(); err != nil { return errors.Wrap(err, "failed to run pipeline") } diff --git a/application-services/custom/camera-management/appcamera/commands.go b/application-services/custom/camera-management/appcamera/commands.go index 4a6d8328..c523c6dc 100644 --- a/application-services/custom/camera-management/appcamera/commands.go +++ b/application-services/custom/camera-management/appcamera/commands.go @@ -8,12 +8,13 @@ package appcamera import ( "context" "fmt" + "github.com/IOTechSystems/onvif/device" "github.com/IOTechSystems/onvif/media" "github.com/IOTechSystems/onvif/ptz" "github.com/IOTechSystems/onvif/xsd/onvif" - "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos" - dtosCommon "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos/common" + "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos" + dtosCommon "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos/common" "github.com/pkg/errors" ) diff --git a/application-services/custom/camera-management/appcamera/credentials.go b/application-services/custom/camera-management/appcamera/credentials.go index 3fad6fda..296ebc5b 100644 --- a/application-services/custom/camera-management/appcamera/credentials.go +++ b/application-services/custom/camera-management/appcamera/credentials.go @@ -6,8 +6,8 @@ package appcamera import ( - "github.com/edgexfoundry/go-mod-bootstrap/v2/config" - "github.com/edgexfoundry/go-mod-core-contracts/v2/errors" + "github.com/edgexfoundry/go-mod-bootstrap/v3/config" + "github.com/edgexfoundry/go-mod-core-contracts/v3/errors" ) const ( @@ -19,7 +19,7 @@ const ( // tryGetCredentials will attempt one time to get the camera credentials from the // secret provider and return them, otherwise return an error. func (app *CameraManagementApp) tryGetCredentials() (config.Credentials, errors.EdgeX) { - secretData, err := app.service.GetSecret(CameraCredentials, UsernameKey, PasswordKey) + secretData, err := app.service.SecretProvider().GetSecret(CameraCredentials, UsernameKey, PasswordKey) if err != nil { return config.Credentials{}, errors.NewCommonEdgeXWrapper(err) } diff --git a/application-services/custom/camera-management/appcamera/evam.go b/application-services/custom/camera-management/appcamera/evam.go index da5c105f..2547fa9e 100644 --- a/application-services/custom/camera-management/appcamera/evam.go +++ b/application-services/custom/camera-management/appcamera/evam.go @@ -12,11 +12,11 @@ import ( "net/url" "path" - "github.com/edgexfoundry/go-mod-core-contracts/v2/common" + "github.com/edgexfoundry/go-mod-core-contracts/v3/common" "github.com/IOTechSystems/onvif/media" - "github.com/edgexfoundry/app-functions-sdk-go/v2/pkg/interfaces" - "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos" + "github.com/edgexfoundry/app-functions-sdk-go/v3/pkg/interfaces" + "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos" "github.com/pkg/errors" ) @@ -245,11 +245,11 @@ func (app *CameraManagementApp) processEdgeXDeviceSystemEvent(_ interfaces.AppFu } switch systemEvent.Action { - case common.DeviceSystemEventActionAdd: + case common.SystemEventActionAdd: if err = app.startDefaultPipeline(device); err != nil { return false, err } - case common.DeviceSystemEventActionDelete: + case common.SystemEventActionDelete: // stop any running pipelines for the deleted device if info, found := app.getPipelineInfo(device.Name); found { if err = app.stopPipeline(device.Name, info.Id); err != nil { diff --git a/application-services/custom/camera-management/appcamera/routes.go b/application-services/custom/camera-management/appcamera/routes.go index 3438ed6e..182139ce 100644 --- a/application-services/custom/camera-management/appcamera/routes.go +++ b/application-services/custom/camera-management/appcamera/routes.go @@ -10,10 +10,10 @@ import ( "net/http" "path" - dtosCommon "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos/common" + dtosCommon "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos/common" "github.com/gorilla/mux" - "github.com/edgexfoundry/go-mod-core-contracts/v2/common" + "github.com/edgexfoundry/go-mod-core-contracts/v3/common" "github.com/pkg/errors" ) diff --git a/application-services/custom/camera-management/appcamera/util.go b/application-services/custom/camera-management/appcamera/util.go index 40565de0..49265e89 100644 --- a/application-services/custom/camera-management/appcamera/util.go +++ b/application-services/custom/camera-management/appcamera/util.go @@ -10,14 +10,15 @@ import ( "encoding/base64" "encoding/json" "fmt" - "github.com/edgexfoundry/go-mod-core-contracts/v2/clients/http/utils" - "github.com/edgexfoundry/go-mod-core-contracts/v2/clients/logger" - "github.com/edgexfoundry/go-mod-core-contracts/v2/common" - "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos" - "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos/responses" - "github.com/pkg/errors" "io" "net/http" + + "github.com/edgexfoundry/go-mod-core-contracts/v3/clients/http/utils" + "github.com/edgexfoundry/go-mod-core-contracts/v3/clients/logger" + "github.com/edgexfoundry/go-mod-core-contracts/v3/common" + "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos" + "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos/responses" + "github.com/pkg/errors" ) const ( @@ -60,7 +61,7 @@ func (app *CameraManagementApp) issueGetCommandWithJsonForResponse(ctx context.C } func (app *CameraManagementApp) issueGetCommand(ctx context.Context, deviceName string, commandName string) (*responses.EventResponse, error) { - return app.service.CommandClient().IssueGetCommandByName(ctx, deviceName, commandName, "no", "yes") + return app.service.CommandClient().IssueGetCommandByName(ctx, deviceName, commandName, false, true) } func (app *CameraManagementApp) issueGetCommandForResponse(ctx context.Context, deviceName string, commandName string, @@ -74,15 +75,15 @@ func (app *CameraManagementApp) issueGetCommandForResponse(ctx context.Context, } func issuePostRequest(ctx context.Context, res interface{}, baseUrl string, reqPath string, jsonValue []byte) (err error) { - return utils.PostRequest(ctx, &res, baseUrl, reqPath, jsonValue, common.ContentTypeJSON) + return utils.PostRequest(ctx, &res, baseUrl, reqPath, jsonValue, common.ContentTypeJSON, nil) } func issueGetRequest(ctx context.Context, res interface{}, baseUrl string, requestPath string) (err error) { - return utils.GetRequest(ctx, &res, baseUrl, requestPath, nil) + return utils.GetRequest(ctx, &res, baseUrl, requestPath, nil, nil) } func issueDeleteRequest(ctx context.Context, res interface{}, baseUrl string, requestPath string) (err error) { - return utils.DeleteRequest(ctx, &res, baseUrl, requestPath) + return utils.DeleteRequest(ctx, &res, baseUrl, requestPath, nil) } func respondError(lc logger.LoggingClient, w http.ResponseWriter, statusCode int, errStr string) { diff --git a/application-services/custom/camera-management/go.mod b/application-services/custom/camera-management/go.mod index 669e59d6..dec2f46c 100644 --- a/application-services/custom/camera-management/go.mod +++ b/application-services/custom/camera-management/go.mod @@ -9,37 +9,37 @@ go 1.18 require ( github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897 - github.com/edgexfoundry/app-functions-sdk-go/v2 v2.3.0 - github.com/edgexfoundry/go-mod-bootstrap/v2 v2.3.0 - github.com/edgexfoundry/go-mod-core-contracts/v2 v2.3.0 + github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66 + github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90 + github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41 github.com/gorilla/mux v1.8.0 github.com/pkg/errors v0.9.1 ) require ( - bitbucket.org/bertimus9/systemstat v0.5.0 // indirect - github.com/Microsoft/go-winio v0.5.2 // indirect + github.com/Microsoft/go-winio v0.6.0 // indirect github.com/armon/go-metrics v0.3.10 // indirect github.com/cenkalti/backoff v2.2.1+incompatible // indirect - github.com/diegoholiveira/jsonlogic/v3 v3.2.6 // indirect - github.com/eclipse/paho.mqtt.golang v1.4.1 // indirect - github.com/edgexfoundry/go-mod-configuration/v2 v2.3.0 // indirect - github.com/edgexfoundry/go-mod-messaging/v2 v2.3.0 // indirect - github.com/edgexfoundry/go-mod-registry/v2 v2.3.0 // indirect - github.com/edgexfoundry/go-mod-secrets/v2 v2.3.0 // indirect + github.com/diegoholiveira/jsonlogic/v3 v3.2.7 // indirect + github.com/eclipse/paho.mqtt.golang v1.4.2 // indirect + github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10 // indirect + github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31 // indirect + github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7 // indirect + github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17 // indirect github.com/fatih/color v1.9.0 // indirect github.com/fxamacker/cbor/v2 v2.4.0 // indirect + github.com/go-jose/go-jose/v3 v3.0.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.5.1 // indirect - github.com/go-playground/locales v0.14.0 // indirect - github.com/go-playground/universal-translator v0.18.0 // indirect - github.com/go-playground/validator/v10 v10.11.1 // indirect + github.com/go-playground/locales v0.14.1 // indirect + github.com/go-playground/universal-translator v0.18.1 // indirect + github.com/go-playground/validator/v10 v10.13.0 // indirect github.com/go-redis/redis/v7 v7.3.0 // indirect github.com/golang/protobuf v1.5.2 // indirect github.com/gomodule/redigo v2.0.0+incompatible // indirect github.com/google/uuid v1.3.0 // indirect github.com/gorilla/websocket v1.4.2 // indirect - github.com/hashicorp/consul/api v1.15.3 // indirect + github.com/hashicorp/consul/api v1.20.0 // indirect github.com/hashicorp/errwrap v1.0.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.1 // indirect github.com/hashicorp/go-hclog v0.14.1 // indirect @@ -47,31 +47,31 @@ require ( github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-rootcerts v1.0.2 // indirect github.com/hashicorp/golang-lru v0.5.4 // indirect - github.com/hashicorp/serf v0.9.7 // indirect - github.com/leodido/go-urn v1.2.1 // indirect + github.com/hashicorp/serf v0.10.1 // indirect + github.com/leodido/go-urn v1.2.3 // indirect github.com/mattn/go-colorable v0.1.12 // indirect github.com/mattn/go-isatty v0.0.14 // indirect github.com/mitchellh/consulstructure v0.0.0-20190329231841-56fdc4d2da54 // indirect - github.com/mitchellh/copystructure v1.0.0 // indirect + github.com/mitchellh/copystructure v1.2.0 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect - github.com/mitchellh/reflectwalk v1.0.0 // indirect - github.com/nats-io/nats.go v1.18.0 // indirect - github.com/nats-io/nkeys v0.3.0 // indirect + github.com/mitchellh/reflectwalk v1.0.2 // indirect + github.com/nats-io/nats.go v1.25.0 // indirect + github.com/nats-io/nkeys v0.4.4 // indirect github.com/nats-io/nuid v1.0.1 // indirect - github.com/pebbe/zmq4 v1.2.7 // indirect - github.com/pelletier/go-toml v1.9.5 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect - github.com/spiffe/go-spiffe/v2 v2.1.1 // indirect + github.com/spiffe/go-spiffe/v2 v2.1.4 // indirect github.com/x448/float16 v0.8.4 // indirect - github.com/zeebo/errs v1.2.2 // indirect - golang.org/x/crypto v0.0.0-20221010152910-d6f0a8c073c2 // indirect - golang.org/x/net v0.0.0-20211216030914-fe4d6282115f // indirect - golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect - golang.org/x/sys v0.0.0-20221010170243-090e33056c14 // indirect - golang.org/x/text v0.3.7 // indirect - google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa // indirect - google.golang.org/grpc v1.46.0 // indirect - google.golang.org/protobuf v1.28.0 // indirect - gopkg.in/square/go-jose.v2 v2.4.1 // indirect + github.com/zeebo/errs v1.3.0 // indirect + golang.org/x/crypto v0.8.0 // indirect + golang.org/x/mod v0.8.0 // indirect + golang.org/x/net v0.9.0 // indirect + golang.org/x/sync v0.1.0 // indirect + golang.org/x/sys v0.7.0 // indirect + golang.org/x/text v0.9.0 // indirect + golang.org/x/tools v0.6.0 // indirect + google.golang.org/genproto v0.0.0-20230223222841-637eb2293923 // indirect + google.golang.org/grpc v1.53.0 // indirect + google.golang.org/protobuf v1.28.1 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/application-services/custom/camera-management/go.sum b/application-services/custom/camera-management/go.sum index 97b7293a..e14ce026 100644 --- a/application-services/custom/camera-management/go.sum +++ b/application-services/custom/camera-management/go.sum @@ -1,19 +1,12 @@ -bitbucket.org/bertimus9/systemstat v0.5.0 h1:n0aLnh2Jo4nBUBym9cE5PJDG8GT6g+4VuS2Ya2jYYpA= -bitbucket.org/bertimus9/systemstat v0.5.0/go.mod h1:EkUWPp8lKFPMXP8vnbpT5JDI0W/sTiLZAvN8ONWErHY= -cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897 h1:2ieBV/UtmRrnw9law65MO8ZkA/dbjxke2Cgo9/NoMoY= github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897/go.mod h1:vMGzqucCPsrADcnQ7oYah1HYr3h4zdoNVzcPmcyKy6o= -github.com/Microsoft/go-winio v0.5.2 h1:a9IhgEQBCUEk6QCdml9CiJGhAws+YwffDHEMp1VMrpA= -github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= -github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= +github.com/Microsoft/go-winio v0.6.0 h1:slsWYD/zyx7lCXoZVlvQrj0hPTM1HI4+v1sIda2yDvg= +github.com/Microsoft/go-winio v0.6.0/go.mod h1:cTAf44im0RAYeL23bpB+fzCyDH2MJiz2BO69KH/soAE= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-metrics v0.3.10 h1:FR+drcQStOe+32sYyJYyZ7FIdgoGGBnwLl+flodp8Uo= @@ -27,58 +20,41 @@ github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6r github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= -github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= -github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= -github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/diegoholiveira/jsonlogic/v3 v3.2.6 h1:EV607wRY72hT3V90ZOQw+zjXR9KIUV9jnHfT3yS8uks= -github.com/diegoholiveira/jsonlogic/v3 v3.2.6/go.mod h1:9oE8z9G+0OMxOoLHF3fhek3KuqD5CBqM0B6XFL08MSg= -github.com/eclipse/paho.mqtt.golang v1.4.1 h1:tUSpviiL5G3P9SZZJPC4ZULZJsxQKXxfENpMvdbAXAI= -github.com/eclipse/paho.mqtt.golang v1.4.1/go.mod h1:JGt0RsEwEX+Xa/agj90YJ9d9DH2b7upDZMK9HRbFvCA= -github.com/edgexfoundry/app-functions-sdk-go/v2 v2.3.0 h1:vJAjzp3mz96gQgygYfD37I2kRE0RsgmltyFwQyk7GRI= -github.com/edgexfoundry/app-functions-sdk-go/v2 v2.3.0/go.mod h1:jV13g+TxWpy+6BaapQ9hICaNlOACnbXzCmlcYApHGn8= -github.com/edgexfoundry/go-mod-bootstrap/v2 v2.3.0 h1:NCOc5bOz6oX+KuOcv0Rt6BTSDShbg4VmCapXO19IoCM= -github.com/edgexfoundry/go-mod-bootstrap/v2 v2.3.0/go.mod h1:jWZjsy0BaO6+S+Tq111mcrkGKpg6bhTyqngyYcl+70E= -github.com/edgexfoundry/go-mod-configuration/v2 v2.3.0 h1:VeK7VBiNc/RIR7HXC0ya3fWCmcFQzrSLITPYn87cQsA= -github.com/edgexfoundry/go-mod-configuration/v2 v2.3.0/go.mod h1:1tKJhcPEWftFy+I4n7+sNIBOo7H5ys/QaPvyXl0tMtc= -github.com/edgexfoundry/go-mod-core-contracts/v2 v2.3.0 h1:8Svk1HTehXEgwxgyA4muVhSkP3D9n1q+oSHI3B1Ac90= -github.com/edgexfoundry/go-mod-core-contracts/v2 v2.3.0/go.mod h1:4/e61acxVkhQWCTjQ4XcHVJDnrMDloFsZZB1B6STCRw= -github.com/edgexfoundry/go-mod-messaging/v2 v2.3.0 h1:aZfDYjj6n2Lo1P1t6NKuShhHjzFk9/mQV9nuJS3ioZ4= -github.com/edgexfoundry/go-mod-messaging/v2 v2.3.0/go.mod h1:5pFRG0iJ64ulFdvwYMbnyD94ciS+Va4h3bpK2P4CBk0= -github.com/edgexfoundry/go-mod-registry/v2 v2.3.0 h1:QEZvYSDkQKAo6WVFrjBkQjjfpbn045Lsv4gNdgATgeM= -github.com/edgexfoundry/go-mod-registry/v2 v2.3.0/go.mod h1:Gyx8a+7jfzy53ljq9kgiz553xhgYYKNNWhnaTn76i+g= -github.com/edgexfoundry/go-mod-secrets/v2 v2.3.0 h1:MRehbe0ZdIP2jx3Nv18LktENlWdXSmw0E6x6VKvFOfo= -github.com/edgexfoundry/go-mod-secrets/v2 v2.3.0/go.mod h1:y9l/5p0EEA2IBf2ctvJ0PtjTN/XPab5BWnfIi3Sy6C4= +github.com/diegoholiveira/jsonlogic/v3 v3.2.7 h1:awX07pFPnlntZzRNBcO4a2Ivxa77NMt+narq/6xcS0E= +github.com/diegoholiveira/jsonlogic/v3 v3.2.7/go.mod h1:9oE8z9G+0OMxOoLHF3fhek3KuqD5CBqM0B6XFL08MSg= +github.com/eclipse/paho.mqtt.golang v1.4.2 h1:66wOzfUHSSI1zamx7jR6yMEI5EuHnT1G6rNA5PM12m4= +github.com/eclipse/paho.mqtt.golang v1.4.2/go.mod h1:JGt0RsEwEX+Xa/agj90YJ9d9DH2b7upDZMK9HRbFvCA= +github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66 h1:xqQL93zxoBygh97qRYIFRx68dpoTJTr4CHExiCeNRrA= +github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66/go.mod h1:F4Hv4/44tEFX/hGMWpm3wHc+XzpjhJwKKFbXAW8UK9k= +github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90 h1:fd/Y1DrgobWkvLbsbOyU5pQjvmpn9o5VEM6bbd8yP48= +github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90/go.mod h1:/l9+zh+pthpA/wv/Y4ZROWfNLk5R3G27t/2yJHO2s/g= +github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10 h1:iDuAO3vpBQnlQuFhai/NATbJkiYXxo3bPCtSnFl07Yw= +github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10/go.mod h1:8RlYm5CPzZgUsfXDWVP1TIeUMhsDNIdRdj1HXdomtOI= +github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41 h1:ZFrxABViVju6AAOkM8iergHTjLdqdycv9iOnKJV7r4s= +github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41/go.mod h1:zzzWGWij6wAqm1go9TLs++TFMIsBqBb1eRnIj4mRxGw= +github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31 h1:jPOKcHYsHuQqVVqOIoIWXzq0BlyKTY9Zopos6cfDqFg= +github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31/go.mod h1:I4kjdOG1nC2K8cIezv4lWWE8o4EO2emVQ9G5jRUDnEs= +github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7 h1:sje0agoLi8ayEFxGO3xtN7P/IXwjZUUxpC8G2fCTu44= +github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7/go.mod h1:SGyo4fAHzOhDAd2Usa9RaBT/sOzkbceIqLrDG0+iYy8= +github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17 h1:T6lFg0rNrf7XeYUyxFuO2CcYVAptr25FTZhxeRMWC/s= +github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17/go.mod h1:o36y/b6XaNaLN0QYAT42OGyI2gLcozjRuSQJh5Rlx/c= github.com/elgs/gostrgen v0.0.0-20161222160715-9d61ae07eeae/go.mod h1:wruC5r2gHdr/JIUs5Rr1V45YtsAzKXZxAnn/5rPC97g= -github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= -github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= -github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.9.0 h1:8xPHl4/q1VyqGIPif1F+1V3Y3lSmrq01EabUW3CoW5s= github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fxamacker/cbor/v2 v2.4.0 h1:ri0ArlOR+5XunOP8CRUowT0pSJOwhW098ZCUyskZD88= github.com/fxamacker/cbor/v2 v2.4.0/go.mod h1:TA1xS00nchWmaBnEIxPSE5oHLuJBAVvqrtAnWBwBCVo= -github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.6.2/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= +github.com/go-jose/go-jose/v3 v3.0.0 h1:s6rrhirfEP/CGIoc6p+PZAeogN2SxKav6Wp7+dyMWVo= +github.com/go-jose/go-jose/v3 v3.0.0/go.mod h1:RNkWWRld676jZEYoV3+XK8L2ZnNSvIsxFMht0mSX+u8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= @@ -87,80 +63,60 @@ github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9 github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.1 h1:otpy5pqBCBZ1ng9RQ0dPu4PN7ba75Y/aA+UpowDyNVA= github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= -github.com/go-playground/assert/v2 v2.0.1 h1:MsBgLAaY856+nPRTKrp3/OZK38U/wa0CcBYNjji3q3A= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= +github.com/go-playground/assert/v2 v2.2.0 h1:JvknZsQTYeFEAhQwI4qEt9cyV5ONwRHC+lYKSsYSR8s= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= -github.com/go-playground/locales v0.14.0 h1:u50s323jtVGugKlcYeyzC0etD1HifMjqmJqb8WugfUU= -github.com/go-playground/locales v0.14.0/go.mod h1:sawfccIbzZTqEDETgFXqTho0QybSa7l++s0DH+LDiLs= +github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= +github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA= -github.com/go-playground/universal-translator v0.18.0 h1:82dyy6p4OuJq4/CByFNOn/jYrnRPArHwAcmLoJZxyho= -github.com/go-playground/universal-translator v0.18.0/go.mod h1:UvRDBj+xPUEGrFYl+lu/H90nyDXpg0fqeB/AQUGNTVA= +github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= +github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GOhaH6EGOAJShg8Id5JGkI= -github.com/go-playground/validator/v10 v10.11.1 h1:prmOlTVv+YjZjmRmNSF3VmspqJIxJWXmqUsHwfTRRkQ= -github.com/go-playground/validator/v10 v10.11.1/go.mod h1:i+3WkQ1FvaUjjxh1kSvIA4dMGDBiPU55YFDl0WbKdWU= +github.com/go-playground/validator/v10 v10.13.0 h1:cFRQdfaSMCOSfGCCLB20MHvuoHb/s5G8L5pu2ppK5AQ= +github.com/go-playground/validator/v10 v10.13.0/go.mod h1:dwu7+CG8/CtBiJFZDz4e+5Upb6OLw04gtBYw0mcG/z4= github.com/go-redis/redis/v7 v7.3.0 h1:3oHqd0W7f/VLKBxeYTEpqdMUsmMectngjM9OtoRoIgg= github.com/go-redis/redis/v7 v7.3.0/go.mod h1:JDNMw23GTyLNC4GZu9njt15ctBQVn7xjRfnwdHj/Dcg= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= -github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= -github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= -github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= -github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/gomodule/redigo v2.0.0+incompatible h1:K/R+8tc58AaqLkqG2Ol3Qk+DR/TlNuhuh457pBFPtt0= github.com/gomodule/redigo v2.0.0+incompatible/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= +github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c h1:964Od4U6p2jUkFxvCydnIczKteheJEzHRToSGK3Bnlw= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.0.0 h1:0udJVsspx3VBr5FwtLhQQtuAsVc79tTq0ocGIPAU6qo= -github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= -github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.7 h1:81/ik6ipDQS2aGcBfIN5dHDB36BwrStyeAQquSYCV4o= -github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= +github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= -github.com/hashicorp/consul/api v1.15.3 h1:WYONYL2rxTXtlekAqblR2SCdJsizMDIj/uXb5wNy9zU= -github.com/hashicorp/consul/api v1.15.3/go.mod h1:/g/qgcoBcEXALCNZgRRisyTW0nY86++L0KbeAMXYCeY= -github.com/hashicorp/consul/sdk v0.11.0 h1:HRzj8YSCln2yGgCumN5CL8lYlD3gBurnervJRJAZyC4= -github.com/hashicorp/consul/sdk v0.11.0/go.mod h1:yPkX5Q6CsxTFMjQQDJwzeNmUUF5NUGGbrDsv9wTb8cw= +github.com/hashicorp/consul/api v1.20.0 h1:9IHTjNVSZ7MIwjlW3N3a7iGiykCMDpxZu8jsxFJh0yc= +github.com/hashicorp/consul/api v1.20.0/go.mod h1:nR64eD44KQ59Of/ECwt2vUmIK2DKsDzAwTmwmLl8Wpo= +github.com/hashicorp/consul/sdk v0.13.1 h1:EygWVWWMczTzXGpO93awkHFzfUka6hLYJ0qhETd+6lY= github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1 h1:dH3aiDG9Jvb5r5+bYHsikaOUIpcM0xvgMXVoDkXMzJM= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= github.com/hashicorp/go-hclog v0.14.1 h1:nQcJDQwIAGnmoUWp8ubocEX40cCml/17YkF6csQLReU= github.com/hashicorp/go-hclog v0.14.1/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.0 h1:8exGP7ego3OmkfksihtSouGMZ+hQrhxx+FVELeXpVPE= github.com/hashicorp/go-immutable-radix v1.3.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= +github.com/hashicorp/go-msgpack v0.5.3 h1:zKjpN5BK/P5lMYrLmBHdBULWbJ0XpYR+7NGzqkZzoD4= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= -github.com/hashicorp/go-msgpack v0.5.5 h1:i9R9JSrqIz0QVLz3sz+i3YJdT7TTSLcfLLzJi9aZTuI= -github.com/hashicorp/go-msgpack v0.5.5/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= @@ -170,40 +126,36 @@ github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5O github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8= github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-sockaddr v1.0.2 h1:ztczhD1jLxIRjVejw8gFomI1BQZOe2WoVOu0SyteCQc= -github.com/hashicorp/go-sockaddr v1.0.2/go.mod h1:rB4wwRAUzs07qva3c5SdrY/NEtAUjGlgmH/UkBUC97A= github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.2 h1:cfejS+Tpcp13yd5nYHWDI6qVCny6wyX2Mt5SGur2IGE= -github.com/hashicorp/go-uuid v1.0.2/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-version v1.2.1 h1:zEfKbn2+PDgroKdiOzqiE8rsmLqU2uwi5PB5pBJ3TkI= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc= github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc= -github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE= -github.com/hashicorp/memberlist v0.3.1 h1:MXgUXLqva1QvpVEDQW1IQLG0wivQAtmFlHRQ+1vWZfM= -github.com/hashicorp/memberlist v0.3.1/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE= -github.com/hashicorp/serf v0.9.7 h1:hkdgbqizGQHuU5IPqYM1JdSMV8nKfpuOnZYXssk9muY= -github.com/hashicorp/serf v0.9.7/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4= +github.com/hashicorp/memberlist v0.5.0 h1:EtYPN8DpAURiapus508I4n9CzHs2W+8NZGbmmR/prTM= +github.com/hashicorp/memberlist v0.5.0/go.mod h1:yvyXLpo0QaGE59Y7hDTsTzDD25JYBZ4mHgHUZ8lrOI0= +github.com/hashicorp/serf v0.10.1 h1:Z1H2J60yRKvfDYAOZLd2MU0ND4AH/WDz7xYHDWQsIPY= +github.com/hashicorp/serf v0.10.1/go.mod h1:yL2t6BqATOLGc5HF7qbFkTfXoPIY0WZdWHfEvMqbG+4= github.com/hpcloud/tail v1.0.0 h1:nfCOvKYfkgYP8hkirhJocXT2+zOD8yUNjXaWfTlyFKI= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= -github.com/klauspost/compress v1.15.11 h1:Lcadnb3RKGin4FYM/orgq0qde+nc15E5Cbqg4B9Sx9c= +github.com/klauspost/compress v1.16.4 h1:91KN02FnsOYhuunwU4ssRe8lc2JosWmizWa91B5v1PU= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= +github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= -github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= -github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w= -github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= +github.com/leodido/go-urn v1.2.3 h1:6BE2vPT0lqoz3fmOesHZiaiFh7889ssCo2GMvLCfiuA= +github.com/leodido/go-urn v1.2.3/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= @@ -221,32 +173,31 @@ github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKju github.com/miekg/dns v1.1.41 h1:WMszZWJG0XmzbK9FEmzH2TVcqYzFesusSIB41b8KHxY= github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI= github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= -github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI= github.com/mitchellh/consulstructure v0.0.0-20190329231841-56fdc4d2da54 h1:DcITQwl3ymmg7i1XfwpZFs/TPv2PuTwxE8bnuKVtKlk= github.com/mitchellh/consulstructure v0.0.0-20190329231841-56fdc4d2da54/go.mod h1:dIfpPVUR+ZfkzkDcKnn+oPW1jKeXe4WlNWc7rIXOVxM= -github.com/mitchellh/copystructure v1.0.0 h1:Laisrj+bAB6b/yJwB5Bt3ITZhGJdqmxquMKeZ+mmkFQ= github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= +github.com/mitchellh/copystructure v1.2.0 h1:vpKXTN4ewci03Vljg/q9QvCGUDttBOGBIa15WveJJGw= +github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/reflectwalk v1.0.0 h1:9D+8oIskB4VJBN5SFlmc27fSlIBZaov1Wpk/IfikLNY= github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= +github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/nats-io/jwt/v2 v2.3.0 h1:z2mA1a7tIf5ShggOFlR1oBPgd6hGqcDYsISxZByUzdI= -github.com/nats-io/nats-server/v2 v2.9.3 h1:HrfzA7G9LNetKkm1z+jU/e9kuAe+E6uaBuuq9EB5sQQ= -github.com/nats-io/nats.go v1.18.0 h1:o480Ao6kuSSFyJO75rGTXCEPj7LGkY84C1Ye+Uhm4c0= -github.com/nats-io/nats.go v1.18.0/go.mod h1:BPko4oXsySz4aSWeFgOHLZs3G4Jq4ZAyE6/zMCxRT6w= -github.com/nats-io/nkeys v0.3.0 h1:cgM5tL53EvYRU+2YLXIK0G2mJtK12Ft9oeooSZMA2G8= -github.com/nats-io/nkeys v0.3.0/go.mod h1:gvUNGjVcM2IPr5rCsRsC6Wb3Hr2CQAm08dsxtV6A5y4= +github.com/nats-io/jwt/v2 v2.4.1 h1:Y35W1dgbbz2SQUYDPCaclXcuqleVmpbRa7646Jf2EX4= +github.com/nats-io/nats-server/v2 v2.9.16 h1:SuNe6AyCcVy0g5326wtyU8TdqYmcPqzTjhkHojAjprc= +github.com/nats-io/nats.go v1.25.0 h1:t5/wCPGciR7X3Mu8QOi4jiJaXaWM8qtkLu4lzGZvYHE= +github.com/nats-io/nats.go v1.25.0/go.mod h1:D2WALIhz7V8M0pH8Scx8JZXlg6Oqz5VG+nQkK8nJdvg= +github.com/nats-io/nkeys v0.4.4 h1:xvBJ8d69TznjcQl9t6//Q5xXuVhyYiSos6RPtvQNTwA= +github.com/nats-io/nkeys v0.4.4/go.mod h1:XUkxdLPTufzlihbamfzQ7mw/VGx6ObUs+0bN5sNvt64= github.com/nats-io/nuid v1.0.1 h1:5iA8DT8V7q8WK2EScv2padNa/rTESc1KdnPw4TC2paw= github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= @@ -257,11 +208,6 @@ github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1Cpa github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= -github.com/pebbe/zmq4 v1.2.7 h1:6EaX83hdFSRUEhgzSW1E/SPoTS3JeYZgYkBvwdcrA9A= -github.com/pebbe/zmq4 v1.2.7/go.mod h1:nqnPueOapVhE2wItZ0uOErngczsJdLOGkebMxaO8r48= -github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= -github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -275,7 +221,6 @@ github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5Fsn github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= @@ -284,81 +229,62 @@ github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsT github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= -github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spiffe/go-spiffe/v2 v2.1.1 h1:RT9kM8MZLZIsPTH+HKQEP5yaAk3yd/VBzlINaRjXs8k= -github.com/spiffe/go-spiffe/v2 v2.1.1/go.mod h1:5qg6rpqlwIub0JAiF1UK9IMD6BpPTmvG6yfSgDBs5lg= +github.com/spiffe/go-spiffe/v2 v2.1.4 h1:Z31Ycaf2Z5DF38sQGmp+iGKjBhBlSzfAq68bfy67Mxw= +github.com/spiffe/go-spiffe/v2 v2.1.4/go.mod h1:eVDqm9xFvyqao6C+eQensb9ZPkyNEeaUbqbBpOhBnNk= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.4.0 h1:M2gUjqZET1qApGOWNSnZ49BAIMX4F/1plDv3+l31EJ4= +github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= +github.com/stretchr/objx v0.5.0 h1:1zr/of2m5FGMsad5YfcqgdqdWrIhu+EBEJRhR1U7z/c= +github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= +github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= -github.com/zeebo/errs v1.2.2 h1:5NFypMTuSdoySVTqlNs1dEoU21QVamMQJxW/Fii5O7g= -github.com/zeebo/errs v1.2.2/go.mod h1:sgbWHsvVuTPHcqJJGQ1WhI5KbWlHYz+2+2C/LSEtCw4= -go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= +github.com/zeebo/errs v1.3.0 h1:hmiaKqgYZzcVgRL1Vkc1Mn2914BbzB0IBxs+ebeutGs= +github.com/zeebo/errs v1.3.0/go.mod h1:sgbWHsvVuTPHcqJJGQ1WhI5KbWlHYz+2+2C/LSEtCw4= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20190911031432-227b76d455e7/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY= -golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20221010152910-d6f0a8c073c2 h1:x8vtB3zMecnlqZIwJNUUpwYKYSqCz5jXbiyv0ZJJZeI= -golang.org/x/crypto v0.0.0-20221010152910-d6f0a8c073c2/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/crypto v0.8.0 h1:pd9TJtTueMTVQXzk8E2XESSMQDj/U7OUu0PqJqPXQjQ= +golang.org/x/crypto v0.8.0/go.mod h1:mRqEX+O9/h5TFCrQhkgjo2yKi0yYA+9ecGkdQoHrywE= +golang.org/x/mod v0.8.0 h1:LUYupSeNrTNCGzR/hVBk2NHZO4hXcVaW1k4Qx7rjPx8= +golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200425230154-ff2c4b7c35a0/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM= -golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= +golang.org/x/net v0.9.0 h1:aWJ/m6xSmxWBx+V0XRHTlrYrPG56jKsLdTFmsSsCzOM= +golang.org/x/net v0.9.0/go.mod h1:d48xBJpPfHeWQsugry2m+kC02ZBRGRgulfHnEXEuWns= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= +golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -375,96 +301,50 @@ golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20221010170243-090e33056c14 h1:k5II8e6QD8mITdi+okbbmR/cIyEbeXLBhy5Ha4nevyc= -golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.7.0 h1:3jlCCIQZPdOYu1h8BkNvLz8Kgwtae2cagcG/VamtZRU= +golang.org/x/sys v0.7.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/time v0.0.0-20220922220347-f3bd1da661af h1:Yx9k8YCG3dvF87UAn2tu2HQLf2dt/eR1bXxpLMWeH+Y= +golang.org/x/text v0.9.0 h1:2sjJmO8cDvYveuX97RDLsxlyUxLl+GHoLxBiRdHllBE= +golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= +golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= -golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.6.0 h1:BOw41kyTf3PuCW1pVQf8+Cyg8pMlkYB1oo9iJ6D/lKM= +golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= -google.golang.org/genproto v0.0.0-20200806141610-86f49bd18e98/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa h1:I0YcKz0I7OAhddo7ya8kMnvprhcWM045PmkBdMO9zN0= -google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= -google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0= -google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= -google.golang.org/grpc v1.46.0 h1:oCjezcn6g6A75TGoKYBPgKmVBLexhYLM6MebdrPApP8= -google.golang.org/grpc v1.46.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= -google.golang.org/grpc/examples v0.0.0-20201130180447-c456688b1860/go.mod h1:Ly7ZA/ARzg8fnPU9TyZIxoz33sEUuWX7txiqs8lPTgE= -google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= -google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= -google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= -google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= -google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4= -google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= +google.golang.org/genproto v0.0.0-20230223222841-637eb2293923 h1:znp6mq/drrY+6khTAlJUDNFFcDGV2ENLYKpMq8SyCds= +google.golang.org/genproto v0.0.0-20230223222841-637eb2293923/go.mod h1:3Dl5ZL0q0isWJt+FVcfpQyirqemEuLAK/iFvg1UP1Hw= +google.golang.org/grpc v1.53.0 h1:LAv2ds7cmFV/XTS3XG1NneeENYrXGmorPxsBbptIjNc= +google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.28.0 h1:w43yiav+6bVFTBQFZX0r7ipe9JQ1QsbMgHwbBziscLw= -google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175w= +google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/square/go-jose.v2 v2.4.1 h1:H0TmLt7/KmzlrDOpa1F+zr0Tk90PbJYBfsVUmRLrf9Y= -gopkg.in/square/go-jose.v2 v2.4.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= -honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/application-services/custom/camera-management/main.go b/application-services/custom/camera-management/main.go index c8f5e8c1..39e50afc 100644 --- a/application-services/custom/camera-management/main.go +++ b/application-services/custom/camera-management/main.go @@ -20,9 +20,9 @@ import ( "fmt" "os" - appsdk "github.com/edgexfoundry/app-functions-sdk-go/v2/pkg" + appsdk "github.com/edgexfoundry/app-functions-sdk-go/v3/pkg" "github.com/edgexfoundry/edgex-examples/application-services/custom/camera-management/appcamera" - "github.com/edgexfoundry/go-mod-core-contracts/v2/dtos" + "github.com/edgexfoundry/go-mod-core-contracts/v3/dtos" ) const ( diff --git a/application-services/custom/camera-management/res/configuration.toml b/application-services/custom/camera-management/res/configuration.toml deleted file mode 100644 index 48be18f8..00000000 --- a/application-services/custom/camera-management/res/configuration.toml +++ /dev/null @@ -1,145 +0,0 @@ -# Go here for detailed information on Application Service configuation: -# https://docs.edgexfoundry.org/2.2/microservices/application/GeneralAppServiceConfig/ -[Writable] -LogLevel = "INFO" - - [Writable.StoreAndForward] - Enabled = false - RetryInterval = "5m" - MaxRetryCount = 10 - - [Writable.InsecureSecrets] - [Writable.InsecureSecrets.DB] - path = "redisdb" - [Writable.InsecureSecrets.DB.Secrets] - username = "" - password = "" - - # TODO: Enter your camera's credentials here. - # NOTE: currently this solution is limited to supporting only 1 username/password combination - # for ALL cameras. In the future when then device-onvif-camera service is able to provide - # us with pre-authenticated uris, this can be removed. - [Writable.InsecureSecrets.CameraCredentials] - path = "CameraCredentials" - [Writable.InsecureSecrets.CameraCredentials.Secrets] - username = "" - password = "" - - [Writable.Telemetry] - Interval = "30s" - PublishTopicPrefix = "edgex/telemetry" # // will be added to this Publish Topic prefix - [Writable.Telemetry.Metrics] # All service's metric names must be present in this list. - # Common App Service Metrics - MessagesReceived = false - InvalidMessagesReceived = false - PipelineMessagesProcessed = false # Pipeline IDs are added as the tag for the metric for each pipeline defined - PipelineMessageProcessingTime = false # Pipeline IDs are added as the tag for the metric for each pipeline defined - PipelineProcessingErrors = false # Pipeline IDs are added as the tag for the metric for each pipeline defined - HttpExportSize = false # Single metric used for all HTTP Exports - MqttExportSize = false # BrokerAddress and Topic are added as the tag for this metric for each MqttExport defined - # Common Security Service Metrics - SecuritySecretsRequested = false - SecuritySecretsStored = false - SecurityConsulTokensRequested = false - SecurityConsulTokenDuration = false - [Writable.Telemetry.Tags] # Contains the service level tags to be attached to all the service's metrics -# Gateway="my-iot-gateway" # Tag must be added here since Env Override can only change existing value, not added new ones. - -[Service] -HealthCheckInterval = "10s" -Host = "localhost" -Port = 59750 -ServerBindAddr = "0.0.0.0" # Leave blank so default to Host value unless different value is needed. -StartupMsg = "Camera Management Application Service has started" -MaxResultCount = 0 # Not curently used by App Services. -MaxRequestSize = 0 # Not curently used by App Services. -RequestTimeout = "5s" - [Service.CORSConfiguration] - EnableCORS = true - CORSAllowCredentials = false - CORSAllowedOrigin = "*" - CORSAllowedMethods = "GET, POST, PUT, PATCH, DELETE" - CORSAllowedHeaders = "Authorization, Accept, Accept-Language, Content-Language, Content-Type, X-Correlation-ID, X-CameraApp-Ignore" - CORSExposeHeaders = "Cache-Control, Content-Language, Content-Length, Content-Type, Expires, Last-Modified, Pragma, X-Correlation-ID" - CORSMaxAge = 3600 - -[Registry] -Host = "localhost" -Port = 8500 -Type = "consul" - -[Database] -Type = "redisdb" -Host = "localhost" -Port = 6379 -Timeout = "30s" - -# TODO: Determine if your service will use secrets in secure mode, i.e. Vault. -# if not this secion can be removed, but you must make sure EDGEX_SECURITY_SECRET_STORE is set to false -# Note: If database is running in secure more and you have Store and Forward enabled, you will need to run this -# service in secure mode. -# For more deatils about SecretStore: https://docs.edgexfoundry.org/1.3/microservices/security/Ch-SecretStore/ -[SecretStore] -Type = "vault" -Host = "localhost" -Port = 8200 -Path = "appservice/" -Protocol = "http" -RootCaCertPath = "" -ServerName = "" -TokenFile = "/tmp/edgex/secrets/app-camera-management/secrets-token.json" - [SecretStore.Authentication] - AuthType = "X-Vault-Token" - -[Clients] - [Clients.core-metadata] - Protocol = "http" - Host = "localhost" - Port = 59881 - - [Clients.core-command] - Protocol = "http" - Host = "localhost" - Port = 59882 - -[AppCustom] -OnvifDeviceServiceName = "device-onvif-camera" -USBDeviceServiceName = "device-usb-camera" -EvamBaseUrl = "http://localhost:8080" -MqttAddress = "edgex-mqtt-broker:1883" -MqttTopic = "incoming/data/edge-video-analytics/inference-event" -DefaultPipelineName = "object_detection" # Name of the default pipeline used when a new device is added to the system; can be left blank to disable feature -DefaultPipelineVersion = "person" # Version of the default pipeline used when a new device is added to the system; can be left blank to disable feature - -[Trigger] -Type="edgex-messagebus" - [Trigger.EdgexMessageBus] - Type = "redis" - [Trigger.EdgexMessageBus.SubscribeHost] - Host = "localhost" - Port = 6379 - Protocol = "redis" - AuthMode = "usernamepassword" # required for redis messagebus (secure or insecure). - SecretName = "redisdb" - SubscribeTopics="edgex/system-events/#/device/#" - - [Trigger.EdgexMessageBus.Optional] - authmode = "usernamepassword" # required for redis messagebus (secure or insecure). - secretname = "redisdb" - # Default MQTT Specific options that need to be here to enable environment variable overrides of them - ClientId ="app-camera-management" - Qos = "0" # Quality of Service values are 0 (At most once), 1 (At least once) or 2 (Exactly once) - KeepAlive = "10" # Seconds (must be 2 or greater) - Retained = "false" - AutoReconnect = "true" - ConnectTimeout = "5" # Seconds - SkipCertVerify = "false" - # Default NATS Specific options that need to be here to enable environment variable overrides of them - Format = "nats" - RetryOnFailedConnect = "true" - QueueGroup = "" - Durable = "" - AutoProvision = "true" - Deliver = "new" - DefaultPubRetryAttempts = "2" - Subject = "edgex/#" # Required for NATS JetStream only for stream autoprovisioning diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml new file mode 100644 index 00000000..b0c644e9 --- /dev/null +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -0,0 +1,43 @@ +Writable: + LogLevel: INFO + + InsecureSecrets: + # TODO: Enter your camera's credentials here. + # NOTE: currently this solution is limited to supporting only 1 username/password combination + # for ALL cameras. In the future when then device-onvif-camera service is able to provide + # us with pre-authenticated uris, this can be removed. + CameraCredentials: + path: CameraCredentials + Secrets: + username: "" + password: "" + + Telemetry: + Interval: 0s # Disables reporting of metrics + +Service: + Host: localhost + Port: 59750 + StartupMsg: Camera Management Application Service has started + +Clients: + core-command: + Protocol: http + Host: localhost + Port: 59882 + +MessageBus: + Optional: + ClientId: app-camera-management + +Trigger: + SubscribeTopics: "edgex/system-events/#/device/#" + +AppCustom: + OnvifDeviceServiceName: device-onvif-camera + USBDeviceServiceName: device-usb-camera + EvamBaseUrl: http://localhost:8080 + MqttAddress: edgex-mqtt-broker:1883 + MqttTopic: incoming/data/edge-video-analytics/inference-event + DefaultPipelineName: object_detection # Name of the default pipeline used when a new device is added to the system; can be left blank to disable feature + DefaultPipelineVersion: person # Version of the default pipeline used when a new device is added to the system; can be left blank to disable feature From ef24aa1ba652d0a33f7dbc4f9f157a916ec55b39 Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 15:28:35 -0700 Subject: [PATCH 02/14] fix: Add the `-cp -d` flags to run-app target Signed-off-by: Leonard Goodell --- application-services/custom/camera-management/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application-services/custom/camera-management/Makefile b/application-services/custom/camera-management/Makefile index 2db6266d..1a0592d8 100644 --- a/application-services/custom/camera-management/Makefile +++ b/application-services/custom/camera-management/Makefile @@ -26,7 +26,7 @@ tidy: go mod tidy run-app: - EDGEX_SECURITY_SECRET_STORE=false ./$(MICROSERVICE) + EDGEX_SECURITY_SECRET_STORE=false ./$(MICROSERVICE) -cp -d # TODO: Change the registries (edgexfoundry, nexus3.edgexfoundry.org:10004) below as needed. # Leave them as is if service is to be upstreamed to EdgeX Foundry From d3d3966f4955c692dfa335f58f334b1aa596a8b3 Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 15:33:00 -0700 Subject: [PATCH 03/14] fix: Add trailing slash to EVAM URL Signed-off-by: Leonard Goodell --- .../custom/camera-management/res/configuration.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index b0c644e9..3d0f5956 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -36,7 +36,7 @@ Trigger: AppCustom: OnvifDeviceServiceName: device-onvif-camera USBDeviceServiceName: device-usb-camera - EvamBaseUrl: http://localhost:8080 + EvamBaseUrl: http://localhost:8080/ MqttAddress: edgex-mqtt-broker:1883 MqttTopic: incoming/data/edge-video-analytics/inference-event DefaultPipelineName: object_detection # Name of the default pipeline used when a new device is added to the system; can be left blank to disable feature From 3ac5a07f7f662cd2262490cdf500ebc8ccc6f281 Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 16:00:00 -0700 Subject: [PATCH 04/14] fix: Rework for leading slash for pipelines Signed-off-by: Leonard Goodell --- application-services/custom/camera-management/appcamera/evam.go | 2 +- .../custom/camera-management/res/configuration.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/application-services/custom/camera-management/appcamera/evam.go b/application-services/custom/camera-management/appcamera/evam.go index 2547fa9e..202c6e1e 100644 --- a/application-services/custom/camera-management/appcamera/evam.go +++ b/application-services/custom/camera-management/appcamera/evam.go @@ -133,7 +133,7 @@ func (app *CameraManagementApp) startPipeline(deviceName string, sr StartPipelin if err != nil { return err } - reqPath := path.Join("pipelines", info.Name, info.Version) + reqPath := path.Join("/pipelines", info.Name, info.Version) if err = issuePostRequest(context.Background(), &res, baseUrl.String(), reqPath, body); err != nil { err = errors.Wrap(err, "POST request to start EVAM pipeline failed") diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index 3d0f5956..b0c644e9 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -36,7 +36,7 @@ Trigger: AppCustom: OnvifDeviceServiceName: device-onvif-camera USBDeviceServiceName: device-usb-camera - EvamBaseUrl: http://localhost:8080/ + EvamBaseUrl: http://localhost:8080 MqttAddress: edgex-mqtt-broker:1883 MqttTopic: incoming/data/edge-video-analytics/inference-event DefaultPipelineName: object_detection # Name of the default pipeline used when a new device is added to the system; can be left blank to disable feature From 7c564a1ed695c95840e5182c01331700988b30fd Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 16:16:30 -0700 Subject: [PATCH 05/14] fix: address other instances of "pipelines" Signed-off-by: Leonard Goodell --- .../custom/camera-management/appcamera/evam.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/application-services/custom/camera-management/appcamera/evam.go b/application-services/custom/camera-management/appcamera/evam.go index 202c6e1e..3a61dff4 100644 --- a/application-services/custom/camera-management/appcamera/evam.go +++ b/application-services/custom/camera-management/appcamera/evam.go @@ -160,7 +160,7 @@ func (app *CameraManagementApp) startPipeline(deviceName string, sr StartPipelin func (app *CameraManagementApp) stopPipeline(deviceName string, id string) error { var res interface{} - if err := issueDeleteRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, path.Join("pipelines", id)); err != nil { + if err := issueDeleteRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, path.Join("/pipelines", id)); err != nil { return errors.Wrap(err, "DELETE request to stop EVAM pipeline failed") } app.lc.Infof("Successfully stopped EVAM pipeline for the device %s", deviceName) @@ -214,7 +214,7 @@ func (app *CameraManagementApp) createPipelineRequestBody(streamUri string, devi func (app *CameraManagementApp) getPipelineStatus(deviceName string) (interface{}, error) { if info, found := app.getPipelineInfo(deviceName); found { var res interface{} - if err := issueGetRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, path.Join("pipelines", "status", info.Id)); err != nil { + if err := issueGetRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, path.Join("/pipelines", "status", info.Id)); err != nil { return nil, errors.Wrap(err, "GET request to query EVAM pipeline status failed") } return res, nil @@ -314,7 +314,7 @@ func (app *CameraManagementApp) startDefaultPipeline(device dtos.Device) error { // insert them into the pipeline map. func (app *CameraManagementApp) queryAllPipelineStatuses() error { var statuses []PipelineStatus - if err := issueGetRequest(context.Background(), &statuses, app.config.AppCustom.EvamBaseUrl, path.Join("pipelines", "status")); err != nil { + if err := issueGetRequest(context.Background(), &statuses, app.config.AppCustom.EvamBaseUrl, path.Join("/pipelines", "status")); err != nil { return errors.Wrap(err, "GET request to query EVAM pipeline statuses failed") } @@ -324,7 +324,7 @@ func (app *CameraManagementApp) queryAllPipelineStatuses() error { } var resp PipelineInformationResponse - if err := issueGetRequest(context.Background(), &resp, app.config.AppCustom.EvamBaseUrl, path.Join("pipelines", status.Id)); err != nil { + if err := issueGetRequest(context.Background(), &resp, app.config.AppCustom.EvamBaseUrl, path.Join("/pipelines", status.Id)); err != nil { app.lc.Errorf("GET request to query EVAM pipeline %s info failed: %s", status.Id, err.Error()) continue } @@ -365,7 +365,7 @@ func (app *CameraManagementApp) getAllPipelineStatuses() (map[string]PipelineInf // loop through the partially filled response map to fill in the missing data. we do not need to hold the lock here. for camera, data := range response { - if err := issueGetRequest(context.Background(), &data.Status, app.config.AppCustom.EvamBaseUrl, path.Join("pipelines", "status", data.Info.Id)); err != nil { + if err := issueGetRequest(context.Background(), &data.Status, app.config.AppCustom.EvamBaseUrl, path.Join("/pipelines", "status", data.Info.Id)); err != nil { return nil, errors.Wrap(err, "GET request to query EVAM pipeline failed") } // overwrite the changed result in the map @@ -377,7 +377,7 @@ func (app *CameraManagementApp) getAllPipelineStatuses() (map[string]PipelineInf func (app *CameraManagementApp) getPipelines() (interface{}, error) { var res interface{} - if err := issueGetRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, "pipelines"); err != nil { + if err := issueGetRequest(context.Background(), &res, app.config.AppCustom.EvamBaseUrl, "/pipelines"); err != nil { return nil, errors.Wrap(err, "GET request to query all EVAM pipelines failed") } return res, nil From 819b7d7d265dc6fe20e94e4b82220cb2ab02260c Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 16:23:07 -0700 Subject: [PATCH 06/14] fix: Chnage API veriosn in UI files Signed-off-by: Leonard Goodell --- .../web-ui/src/environments/environment.prod.ts | 2 +- .../camera-management/web-ui/src/environments/environment.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts b/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts index df9ed739..7c53bd55 100644 --- a/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts +++ b/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts @@ -3,7 +3,7 @@ export const environment = { production: true, - appServiceBaseUrl: '/api/v2', + appServiceBaseUrl: '/api/v3', defaultPipelineId: 'object_detection/person_vehicle_bike', mqtt: { diff --git a/application-services/custom/camera-management/web-ui/src/environments/environment.ts b/application-services/custom/camera-management/web-ui/src/environments/environment.ts index cc1b94bb..b9a664e2 100644 --- a/application-services/custom/camera-management/web-ui/src/environments/environment.ts +++ b/application-services/custom/camera-management/web-ui/src/environments/environment.ts @@ -7,7 +7,7 @@ export const environment = { production: false, - appServiceBaseUrl: 'http://localhost:59750/api/v2', + appServiceBaseUrl: 'http://localhost:59750/api/v3', defaultPipelineId: 'object_detection/person_vehicle_bike', mqtt: { From 730aa8a63cf0d90859713067782d7ecc1101bdef Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 16:32:24 -0700 Subject: [PATCH 07/14] fix: Rebuild UI. Signed-off-by: Leonard Goodell --- .../custom/camera-management/web-ui/dist/index.html | 4 ++-- .../{main.137de25ed3b58748.js => main.fd85df24810c0586.js} | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) rename application-services/custom/camera-management/web-ui/dist/{main.137de25ed3b58748.js => main.fd85df24810c0586.js} (99%) diff --git a/application-services/custom/camera-management/web-ui/dist/index.html b/application-services/custom/camera-management/web-ui/dist/index.html index 4be617ca..6e141ed3 100644 --- a/application-services/custom/camera-management/web-ui/dist/index.html +++ b/application-services/custom/camera-management/web-ui/dist/index.html @@ -5,10 +5,10 @@ - + - + \ No newline at end of file diff --git a/application-services/custom/camera-management/web-ui/dist/main.137de25ed3b58748.js b/application-services/custom/camera-management/web-ui/dist/main.fd85df24810c0586.js similarity index 99% rename from application-services/custom/camera-management/web-ui/dist/main.137de25ed3b58748.js rename to application-services/custom/camera-management/web-ui/dist/main.fd85df24810c0586.js index cdefcea2..263eeec0 100644 --- a/application-services/custom/camera-management/web-ui/dist/main.137de25ed3b58748.js +++ b/application-services/custom/camera-management/web-ui/dist/main.fd85df24810c0586.js @@ -1 +1 @@ -(self.webpackChunkcamera_management_web_ui=self.webpackChunkcamera_management_web_ui||[]).push([[179],{736:(js,Wa,ps)=>{"use strict";function ut(n){return"function"==typeof n}function Br(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const ms=Br(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function V(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class X{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(ut(i))try{i()}catch(s){t=s instanceof ms?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{S(s)}catch(o){t=null!=t?t:[],o instanceof ms?t=[...t,...o.errors]:t.push(o)}}if(t)throw new ms(t)}}add(t){var e;if(t&&t!==this)if(this.closed)S(t);else{if(t instanceof X){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&V(e,t)}remove(t){const{_finalizers:e}=this;e&&V(e,t),t instanceof X&&t._removeParent(this)}}X.EMPTY=(()=>{const n=new X;return n.closed=!0,n})();const re=X.EMPTY;function T(n){return n instanceof X||n&&"closed"in n&&ut(n.remove)&&ut(n.add)&&ut(n.unsubscribe)}function S(n){ut(n)?n():n.unsubscribe()}const R={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},D={setTimeout(n,t,...e){const{delegate:i}=D;return null!=i&&i.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=D;return((null==t?void 0:t.clearTimeout)||clearTimeout)(n)},delegate:void 0};function m(n){D.setTimeout(()=>{const{onUnhandledError:t}=R;if(!t)throw n;t(n)})}function y(){}const v=z("C",void 0,void 0);function z(n,t,e){return{kind:n,value:t,error:e}}let C=null;function P(n){if(R.useDeprecatedSynchronousErrorHandling){const t=!C;if(t&&(C={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=C;if(C=null,e)throw i}}else n()}class O extends X{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,T(t)&&t.add(this)):this.destination=Y}static create(t,e,i){return new G(t,e,i)}next(t){this.isStopped?le(function I(n){return z("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?le(function _(n){return z("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?le(v,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const F=Function.prototype.bind;function B(n,t){return F.call(n,t)}class Q{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){oe(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){oe(i)}else oe(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){oe(e)}}}class G extends O{constructor(t,e,i){let r;if(super(),ut(t)||!t)r={next:null!=t?t:void 0,error:null!=e?e:void 0,complete:null!=i?i:void 0};else{let s;this&&R.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&B(t.next,s),error:t.error&&B(t.error,s),complete:t.complete&&B(t.complete,s)}):r=t}this.destination=new Q(r)}}function oe(n){R.useDeprecatedSynchronousErrorHandling?function M(n){R.useDeprecatedSynchronousErrorHandling&&C&&(C.errorThrown=!0,C.error=n)}(n):m(n)}function le(n,t){const{onStoppedNotification:e}=R;e&&D.setTimeout(()=>e(n,t))}const Y={closed:!0,next:y,error:function de(n){throw n},complete:y},H="function"==typeof Symbol&&Symbol.observable||"@@observable";function N(n){return n}let J=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function ge(n){return n&&n instanceof O||function Ce(n){return n&&ut(n.next)&&ut(n.error)&&ut(n.complete)}(n)&&T(n)}(e)?e:new G(e,i,r);return P(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=pe(i))((r,s)=>{const o=new G({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[H](){return this}pipe(...e){return function se(n){return 0===n.length?N:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=pe(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function pe(n){var t;return null!==(t=null!=n?n:R.Promise)&&void 0!==t?t:Promise}const Fe=Br(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let ue=(()=>{class n extends J{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new Ye(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new Fe}next(e){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?re:(this.currentObservers=null,s.push(e),new X(()=>{this.currentObservers=null,V(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new J;return e.source=this,e}}return n.create=(t,e)=>new Ye(t,e),n})();class Ye extends ue{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:re}}function Ne(n){return ut(null==n?void 0:n.lift)}function Pe(n){return t=>{if(Ne(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}function _e(n,t,e,i,r){return new ve(n,t,e,i,r)}class ve extends O{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function U(n,t){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>{i.next(n.call(t,s,r++))}))})}function L(n){return this instanceof L?(this.v=n,this):new L(n)}function Z(n,t,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,i=e.apply(n,t||[]),s=[];return r={},o("next"),o("throw"),o("return"),r[Symbol.asyncIterator]=function(){return this},r;function o(w){i[w]&&(r[w]=function(k){return new Promise(function(j,K){s.push([w,k,j,K])>1||a(w,k)})})}function a(w,k){try{!function l(w){w.value instanceof L?Promise.resolve(w.value.v).then(c,d):f(s[0][2],w)}(i[w](k))}catch(j){f(s[0][3],j)}}function c(w){a("next",w)}function d(w){a("throw",w)}function f(w,k){w(k),s.shift(),s.length&&a(s[0][0],s[0][1])}}function Se(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,t=n[Symbol.asyncIterator];return t?t.call(n):(n=function ne(n){var t="function"==typeof Symbol&&Symbol.iterator,e=t&&n[t],i=0;if(e)return e.call(n);if(n&&"number"==typeof n.length)return{next:function(){return n&&i>=n.length&&(n=void 0),{value:n&&n[i++],done:!n}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(n),e={},i("next"),i("throw"),i("return"),e[Symbol.asyncIterator]=function(){return this},e);function i(s){e[s]=n[s]&&function(o){return new Promise(function(a,l){!function r(s,o,a,l){Promise.resolve(l).then(function(c){s({value:c,done:a})},o)}(a,l,(o=n[s](o)).done,o.value)})}}}const Oi=n=>n&&"number"==typeof n.length&&"function"!=typeof n;function Vr(n){return ut(null==n?void 0:n.then)}function Hr(n){return ut(n[H])}function Xv(n){return Symbol.asyncIterator&&ut(null==n?void 0:n[Symbol.asyncIterator])}function Jv(n){return new TypeError(`You provided ${null!==n&&"object"==typeof n?"an invalid object":`'${n}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}const ey=function yA(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}();function ty(n){return ut(null==n?void 0:n[ey])}function ny(n){return Z(this,arguments,function*(){const e=n.getReader();try{for(;;){const{value:i,done:r}=yield L(e.read());if(r)return yield L(void 0);yield yield L(i)}}finally{e.releaseLock()}})}function iy(n){return ut(null==n?void 0:n.getReader)}function di(n){if(n instanceof J)return n;if(null!=n){if(Hr(n))return function bA(n){return new J(t=>{const e=n[H]();if(ut(e.subscribe))return e.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(n);if(Oi(n))return function wA(n){return new J(t=>{for(let e=0;e{n.then(e=>{t.closed||(t.next(e),t.complete())},e=>t.error(e)).then(null,m)})}(n);if(Xv(n))return ry(n);if(ty(n))return function DA(n){return new J(t=>{for(const e of n)if(t.next(e),t.closed)return;t.complete()})}(n);if(iy(n))return function EA(n){return ry(ny(n))}(n)}throw Jv(n)}function ry(n){return new J(t=>{(function MA(n,t){var e,i,r,s;return function W(n,t,e,i){return new(e||(e=Promise))(function(s,o){function a(d){try{c(i.next(d))}catch(f){o(f)}}function l(d){try{c(i.throw(d))}catch(f){o(f)}}function c(d){d.done?s(d.value):function r(s){return s instanceof e?s:new e(function(o){o(s)})}(d.value).then(a,l)}c((i=i.apply(n,t||[])).next())})}(this,void 0,void 0,function*(){try{for(e=Se(n);!(i=yield e.next()).done;)if(t.next(i.value),t.closed)return}catch(o){r={error:o}}finally{try{i&&!i.done&&(s=e.return)&&(yield s.call(e))}finally{if(r)throw r.error}}t.complete()})})(n,t).catch(e=>t.error(e))})}function jr(n,t,e,i=0,r=!1){const s=t.schedule(function(){e(),r?n.add(this.schedule(null,i)):this.unsubscribe()},i);if(n.add(s),!r)return s}function Pn(n,t,e=1/0){return ut(t)?Pn((i,r)=>U((s,o)=>t(i,s,r,o))(di(n(i,r))),e):("number"==typeof t&&(e=t),Pe((i,r)=>function xA(n,t,e,i,r,s,o,a){const l=[];let c=0,d=0,f=!1;const w=()=>{f&&!l.length&&!c&&t.complete()},k=K=>c{s&&t.next(K),c++;let ae=!1;di(e(K,d++)).subscribe(_e(t,ce=>{null==r||r(ce),s?k(ce):t.next(ce)},()=>{ae=!0},void 0,()=>{if(ae)try{for(c--;l.length&&cj(ce)):j(ce)}w()}catch(ce){t.error(ce)}}))};return n.subscribe(_e(t,k,()=>{f=!0,w()})),()=>{null==a||a()}}(i,r,n,e)))}function To(n=1/0){return Pn(N,n)}const Fi=new J(n=>n.complete());function sy(n){return n&&ut(n.schedule)}function tf(n){return n[n.length-1]}function oy(n){return ut(tf(n))?n.pop():void 0}function qa(n){return sy(tf(n))?n.pop():void 0}function ay(n,t=0){return Pe((e,i)=>{e.subscribe(_e(i,r=>jr(i,n,()=>i.next(r),t),()=>jr(i,n,()=>i.complete(),t),r=>jr(i,n,()=>i.error(r),t)))})}function ly(n,t=0){return Pe((e,i)=>{i.add(n.schedule(()=>e.subscribe(i),t))})}function cy(n,t){if(!n)throw new Error("Iterable cannot be null");return new J(e=>{jr(e,t,()=>{const i=n[Symbol.asyncIterator]();jr(e,t,()=>{i.next().then(r=>{r.done?e.complete():e.next(r.value)})},0,!0)})})}function gn(n,t){return t?function OA(n,t){if(null!=n){if(Hr(n))return function TA(n,t){return di(n).pipe(ly(t),ay(t))}(n,t);if(Oi(n))return function IA(n,t){return new J(e=>{let i=0;return t.schedule(function(){i===n.length?e.complete():(e.next(n[i++]),e.closed||this.schedule())})})}(n,t);if(Vr(n))return function AA(n,t){return di(n).pipe(ly(t),ay(t))}(n,t);if(Xv(n))return cy(n,t);if(ty(n))return function RA(n,t){return new J(e=>{let i;return jr(e,t,()=>{i=n[ey](),jr(e,t,()=>{let r,s;try{({value:r,done:s}=i.next())}catch(o){return void e.error(o)}s?e.complete():e.next(r)},0,!0)}),()=>ut(null==i?void 0:i.return)&&i.return()})}(n,t);if(iy(n))return function PA(n,t){return cy(ny(n),t)}(n,t)}throw Jv(n)}(n,t):di(n)}function $n(...n){const t=qa(n),e=function kA(n,t){return"number"==typeof tf(n)?n.pop():t}(n,1/0),i=n;return i.length?1===i.length?di(i[0]):To(e)(gn(i,t)):Fi}function sn(n){return n<=0?()=>Fi:Pe((t,e)=>{let i=0;t.subscribe(_e(e,r=>{++i<=n&&(e.next(r),n<=i&&e.complete())}))})}function dy(n={}){const{connector:t=(()=>new ue),resetOnError:e=!0,resetOnComplete:i=!0,resetOnRefCountZero:r=!0}=n;return s=>{let o=null,a=null,l=null,c=0,d=!1,f=!1;const w=()=>{null==a||a.unsubscribe(),a=null},k=()=>{w(),o=l=null,d=f=!1},j=()=>{const K=o;k(),null==K||K.unsubscribe()};return Pe((K,ae)=>{c++,!f&&!d&&w();const ce=l=null!=l?l:t();ae.add(()=>{c--,0===c&&!f&&!d&&(a=nf(j,r))}),ce.subscribe(ae),o||(o=new G({next:Te=>ce.next(Te),error:Te=>{f=!0,w(),a=nf(k,e,Te),ce.error(Te)},complete:()=>{d=!0,w(),a=nf(k,i),ce.complete()}}),gn(K).subscribe(o))})(s)}}function nf(n,t,...e){return!0===t?(n(),null):!1===t?null:t(...e).pipe(sn(1)).subscribe(()=>n())}function Yt(n){for(let t in n)if(n[t]===Yt)return t;throw Error("Could not find renamed property on target object.")}function rf(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function Kt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(Kt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function sf(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const FA=Yt({__forward_ref__:Yt});function Ft(n){return n.__forward_ref__=Ft,n.toString=function(){return Kt(this())},n}function pt(n){return af(n)?n():n}function af(n){return"function"==typeof n&&n.hasOwnProperty(FA)&&n.__forward_ref__===Ft}class Be extends Error{constructor(t,e){super(function Lc(n,t){return`NG0${Math.abs(n)}${t?": "+t.trim():""}`}(t,e)),this.code=t}}function gt(n){return"string"==typeof n?n:null==n?"":String(n)}function Nc(n,t){throw new Be(-201,!1)}function yi(n,t){null==n&&function $t(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Ie(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function qe(n){return{providers:n.providers||[],imports:n.imports||[]}}function lf(n){return uy(n,Bc)||uy(n,fy)}function uy(n,t){return n.hasOwnProperty(t)?n[t]:null}function hy(n){return n&&(n.hasOwnProperty(cf)||n.hasOwnProperty(zA))?n[cf]:null}const Bc=Yt({\u0275prov:Yt}),cf=Yt({\u0275inj:Yt}),fy=Yt({ngInjectableDef:Yt}),zA=Yt({ngInjectorDef:Yt});var at=(()=>((at=at||{})[at.Default=0]="Default",at[at.Host=1]="Host",at[at.Self=2]="Self",at[at.SkipSelf=4]="SkipSelf",at[at.Optional=8]="Optional",at))();let df;function pr(n){const t=df;return df=n,t}function py(n,t,e){const i=lf(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&at.Optional?null:void 0!==t?t:void Nc(Kt(n))}function gs(n){return{toString:n}.toString()}var Xi=(()=>((Xi=Xi||{})[Xi.OnPush=0]="OnPush",Xi[Xi.Default=1]="Default",Xi))(),Ji=(()=>{return(n=Ji||(Ji={}))[n.Emulated=0]="Emulated",n[n.None=2]="None",n[n.ShadowDom=3]="ShadowDom",Ji;var n})();const qt=(()=>"undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof global&&global||"undefined"!=typeof window&&window||"undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self)(),Ao={},jt=[],Vc=Yt({\u0275cmp:Yt}),uf=Yt({\u0275dir:Yt}),hf=Yt({\u0275pipe:Yt}),my=Yt({\u0275mod:Yt}),zr=Yt({\u0275fac:Yt}),Ya=Yt({__NG_ELEMENT_ID__:Yt});let GA=0;function vt(n){return gs(()=>{const e=!0===n.standalone,i={},r={type:n.type,providersResolver:null,decls:n.decls,vars:n.vars,factory:null,template:n.template||null,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:i,inputs:null,outputs:null,exportAs:n.exportAs||null,onPush:n.changeDetection===Xi.OnPush,directiveDefs:null,pipeDefs:null,standalone:e,dependencies:e&&n.dependencies||null,getStandaloneInjector:null,selectors:n.selectors||jt,viewQuery:n.viewQuery||null,features:n.features||null,data:n.data||{},encapsulation:n.encapsulation||Ji.Emulated,id:"c"+GA++,styles:n.styles||jt,_:null,setInput:null,schemas:n.schemas||null,tView:null},s=n.dependencies,o=n.features;return r.inputs=vy(n.inputs,i),r.outputs=vy(n.outputs),o&&o.forEach(a=>a(r)),r.directiveDefs=s?()=>("function"==typeof s?s():s).map(gy).filter(_y):null,r.pipeDefs=s?()=>("function"==typeof s?s():s).map(ei).filter(_y):null,r})}function gy(n){return Qt(n)||Jn(n)}function _y(n){return null!==n}const qA={};function Ke(n){return gs(()=>{const t={type:n.type,bootstrap:n.bootstrap||jt,declarations:n.declarations||jt,imports:n.imports||jt,exports:n.exports||jt,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null};return null!=n.id&&(qA[n.id]=n.type),t})}function vy(n,t){if(null==n)return Ao;const e={};for(const i in n)if(n.hasOwnProperty(i)){let r=n[i],s=r;Array.isArray(r)&&(s=r[1],r=r[0]),e[r]=i,t&&(t[r]=s)}return e}const Me=vt;function ui(n){return{type:n.type,name:n.name,factory:null,pure:!1!==n.pure,standalone:!0===n.standalone,onDestroy:n.type.prototype.ngOnDestroy||null}}function Qt(n){return n[Vc]||null}function Jn(n){return n[uf]||null}function ei(n){return n[hf]||null}function bi(n,t){const e=n[my]||null;if(!e&&!0===t)throw new Error(`Type ${Kt(n)} does not have '\u0275mod' property.`);return e}function hi(n){return Array.isArray(n)&&"object"==typeof n[1]}function tr(n){return Array.isArray(n)&&!0===n[1]}function mf(n){return 0!=(8&n.flags)}function zc(n){return 2==(2&n.flags)}function $c(n){return 1==(1&n.flags)}function nr(n){return null!==n.template}function XA(n){return 0!=(256&n[2])}function Ws(n,t){return n.hasOwnProperty(zr)?n[zr]:null}class tI{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function cn(){return wy}function wy(n){return n.type.prototype.ngOnChanges&&(n.setInput=iI),nI}function nI(){const n=Dy(this),t=null==n?void 0:n.current;if(t){const e=n.previous;if(e===Ao)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function iI(n,t,e,i){const r=Dy(n)||function rI(n,t){return n[Cy]=t}(n,{previous:Ao,current:null}),s=r.current||(r.current={}),o=r.previous,a=this.declaredInputs[e],l=o[a];s[a]=new tI(l&&l.currentValue,t,o===Ao),n[i]=t}cn.ngInherit=!0;const Cy="__ngSimpleChanges__";function Dy(n){return n[Cy]||null}let bf;function dn(n){return!!n.listen}const Ey={createRenderer:(n,t)=>function wf(){return void 0!==bf?bf:"undefined"!=typeof document?document:void 0}()};function Cn(n){for(;Array.isArray(n);)n=n[0];return n}function Gc(n,t){return Cn(t[n])}function Bi(n,t){return Cn(t[n.index])}function Cf(n,t){return n.data[t]}function Fo(n,t){return n[t]}function Ci(n,t){const e=t[n];return hi(e)?e:e[0]}function My(n){return 4==(4&n[2])}function Df(n){return 64==(64&n[2])}function _s(n,t){return null==t?null:n[t]}function xy(n){n[18]=0}function Ef(n,t){n[5]+=t;let e=n,i=n[3];for(;null!==i&&(1===t&&1===e[5]||-1===t&&0===e[5]);)i[5]+=t,e=i,i=i[3]}const mt={lFrame:Fy(null),bindingsEnabled:!0};function ky(){return mt.bindingsEnabled}function ke(){return mt.lFrame.lView}function Lt(){return mt.lFrame.tView}function Bn(n){return mt.lFrame.contextLView=n,n[8]}function Vn(n){return mt.lFrame.contextLView=null,n}function Sn(){let n=Ty();for(;null!==n&&64===n.type;)n=n.parent;return n}function Ty(){return mt.lFrame.currentTNode}function mr(n,t){const e=mt.lFrame;e.currentTNode=n,e.isParent=t}function Mf(){return mt.lFrame.isParent}function xf(){mt.lFrame.isParent=!1}function ti(){const n=mt.lFrame;let t=n.bindingRootIndex;return-1===t&&(t=n.bindingRootIndex=n.tView.bindingStartIndex),t}function $r(){return mt.lFrame.bindingIndex}function Lo(){return mt.lFrame.bindingIndex++}function Gr(n){const t=mt.lFrame,e=t.bindingIndex;return t.bindingIndex=t.bindingIndex+n,e}function wI(n,t){const e=mt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Sf(t)}function Sf(n){mt.lFrame.currentDirectiveIndex=n}function kf(n){const t=mt.lFrame.currentDirectiveIndex;return-1===t?null:n[t]}function Ry(){return mt.lFrame.currentQueryIndex}function Tf(n){mt.lFrame.currentQueryIndex=n}function DI(n){const t=n[1];return 2===t.type?t.declTNode:1===t.type?n[6]:null}function Py(n,t,e){if(e&at.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&at.Host||(r=DI(s),null===r||(s=s[15],10&r.type))););if(null===r)return!1;t=r,n=s}const i=mt.lFrame=Oy();return i.currentTNode=t,i.lView=n,!0}function qc(n){const t=Oy(),e=n[1];mt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function Oy(){const n=mt.lFrame,t=null===n?null:n.child;return null===t?Fy(n):t}function Fy(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function Ly(){const n=mt.lFrame;return mt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const Ny=Ly;function Yc(){const n=Ly();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function ni(){return mt.lFrame.selectedIndex}function vs(n){mt.lFrame.selectedIndex=n}function un(){const n=mt.lFrame;return Cf(n.tView,n.selectedIndex)}function Ja(){mt.lFrame.currentNamespace="svg"}function Kc(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[18]+=65536),(a>11>16&&(3&n[2])===t){n[2]+=2048;try{s.call(a)}finally{}}}else try{s.call(a)}finally{}}class el{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function Xc(n,t,e){const i=dn(n);let r=0;for(;rt){o=s-1;break}}}for(;s>16}(n),i=t;for(;e>0;)i=i[15],e--;return i}let Pf=!0;function ed(n){const t=Pf;return Pf=n,t}let LI=0;const gr={};function nl(n,t){const e=Ff(n,t);if(-1!==e)return e;const i=t[1];i.firstCreatePass&&(n.injectorIndex=t.length,Of(i.data,n),Of(t,null),Of(i.blueprint,null));const r=td(n,t),s=n.injectorIndex;if(Uy(r)){const o=No(r),a=Bo(r,t),l=a[1].data;for(let c=0;c<8;c++)t[s+c]=a[o+c]|l[o+c]}return t[s+8]=r,s}function Of(n,t){n.push(0,0,0,0,0,0,0,0,t)}function Ff(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function td(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=Zy(r),null===i)return-1;if(e++,r=r[15],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return-1}function nd(n,t,e){!function NI(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(Ya)&&(i=e[Ya]),null==i&&(i=e[Ya]=LI++);const r=255&i;t.data[n+(r>>5)]|=1<=0?255&t:jI:t}(e);if("function"==typeof s){if(!Py(t,n,i))return i&at.Host?Gy(r,0,i):Wy(t,e,i,r);try{const o=s(i);if(null!=o||i&at.Optional)return o;Nc()}finally{Ny()}}else if("number"==typeof s){let o=null,a=Ff(n,t),l=-1,c=i&at.Host?t[16][6]:null;for((-1===a||i&at.SkipSelf)&&(l=-1===a?td(n,t):t[a+8],-1!==l&&Qy(i,!1)?(o=t[1],a=No(l),t=Bo(l,t)):a=-1);-1!==a;){const d=t[1];if(Ky(s,a,d.data)){const f=VI(a,t,e,o,i,c);if(f!==gr)return f}l=t[a+8],-1!==l&&Qy(i,t[1].data[a+8]===c)&&Ky(s,a,t)?(o=d,a=No(l),t=Bo(l,t)):a=-1}}return r}function VI(n,t,e,i,r,s){const o=t[1],a=o.data[n+8],d=id(a,o,e,null==i?zc(a)&&Pf:i!=o&&0!=(3&a.type),r&at.Host&&s===a);return null!==d?il(t,o,d,a):gr}function id(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,d=s>>20,w=r?a+d:n.directiveEnd;for(let k=i?a:a+d;k=l&&j.type===e)return k}if(r){const k=o[l];if(k&&nr(k)&&k.type===e)return l}return null}function il(n,t,e,i){let r=n[e];const s=t.data;if(function II(n){return n instanceof el}(r)){const o=r;o.resolving&&function LA(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new Be(-200,`Circular dependency in DI detected for ${n}${e}`)}(function Ht(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():gt(n)}(s[e]));const a=ed(o.canSeeViewProviders);o.resolving=!0;const l=o.injectImpl?pr(o.injectImpl):null;Py(n,i,at.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function TI(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=wy(t);(e.preOrderHooks||(e.preOrderHooks=[])).push(n,o),(e.preOrderCheckHooks||(e.preOrderCheckHooks=[])).push(n,o)}r&&(e.preOrderHooks||(e.preOrderHooks=[])).push(0-n,r),s&&((e.preOrderHooks||(e.preOrderHooks=[])).push(n,s),(e.preOrderCheckHooks||(e.preOrderCheckHooks=[])).push(n,s))}(e,s[e],t)}finally{null!==l&&pr(l),ed(a),o.resolving=!1,Ny()}}return r}function Ky(n,t,e){return!!(e[t+(n>>5)]&1<{const t=n.prototype.constructor,e=t[zr]||Lf(t),i=Object.prototype;let r=Object.getPrototypeOf(n.prototype).constructor;for(;r&&r!==i;){const s=r[zr]||Lf(r);if(s&&s!==e)return s;r=Object.getPrototypeOf(r)}return s=>new s})}function Lf(n){return af(n)?()=>{const t=Lf(pt(n));return t&&t()}:Ws(n)}function Zy(n){const t=n[1],e=t.type;return 2===e?t.declTNode:1===e?n[6]:null}function ii(n){return function BI(n,t){if("class"===t)return n.classes;if("style"===t)return n.styles;const e=n.attrs;if(e){const i=e.length;let r=0;for(;r{const i=function Nf(n){return function(...e){if(n){const i=n(...e);for(const r in i)this[r]=i[r]}}}(t);function r(...s){if(this instanceof r)return i.apply(this,s),this;const o=new r(...s);return a.annotation=o,a;function a(l,c,d){const f=l.hasOwnProperty(jo)?l[jo]:Object.defineProperty(l,jo,{value:[]})[jo];for(;f.length<=d;)f.push(null);return(f[d]=f[d]||[]).push(o),l}}return e&&(r.prototype=Object.create(e.prototype)),r.prototype.ngMetadataName=n,r.annotationCls=r,r})}class De{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Ie({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const $I=new De("AnalyzeForEntryComponents");function Di(n,t){void 0===t&&(t=n);for(let e=0;eArray.isArray(e)?Wr(e,t):t(e))}function Jy(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function rd(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}function ol(n,t){const e=[];for(let i=0;i=0?n[1|i]=e:(i=~i,function qI(n,t,e,i){let r=n.length;if(r==t)n.push(e,i);else if(1===r)n.push(i,n[0]),n[0]=e;else{for(r--,n.push(n[r-1],n[r]);r>t;)n[r]=n[r-2],r--;n[t]=e,n[t+1]=i}}(n,i,t,e)),i}function Vf(n,t){const e=$o(n,t);if(e>=0)return n[1|e]}function $o(n,t){return function nb(n,t,e){let i=0,r=n.length>>e;for(;r!==i;){const s=i+(r-i>>1),o=n[s<t?r=s:i=s+1}return~(r<({token:n})),-1),Hn=cl(zo("Optional"),8),ir=cl(zo("SkipSelf"),4);let hd;function Wo(n){var t;return(null===(t=function zf(){if(void 0===hd&&(hd=null,qt.trustedTypes))try{hd=qt.trustedTypes.createPolicy("angular",{createHTML:n=>n,createScript:n=>n,createScriptURL:n=>n})}catch(n){}return hd}())||void 0===t?void 0:t.createHTML(n))||n}class qs{constructor(t){this.changingThisBreaksApplicationSecurity=t}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see https://g.co/ng/security#xss)`}}class vR extends qs{getTypeName(){return"HTML"}}class yR extends qs{getTypeName(){return"Style"}}class bR extends qs{getTypeName(){return"Script"}}class wR extends qs{getTypeName(){return"URL"}}class CR extends qs{getTypeName(){return"ResourceURL"}}function Mi(n){return n instanceof qs?n.changingThisBreaksApplicationSecurity:n}function _r(n,t){const e=mb(n);if(null!=e&&e!==t){if("ResourceURL"===e&&"URL"===t)return!0;throw new Error(`Required a safe ${t}, got a ${e} (see https://g.co/ng/security#xss)`)}return e===t}function mb(n){return n instanceof qs&&n.getTypeName()||null}class kR{constructor(t){this.inertDocumentHelper=t}getInertBodyElement(t){t=""+t;try{const e=(new window.DOMParser).parseFromString(Wo(t),"text/html").body;return null===e?this.inertDocumentHelper.getInertBodyElement(t):(e.removeChild(e.firstChild),e)}catch(e){return null}}}class TR{constructor(t){if(this.defaultDoc=t,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert"),null==this.inertDocument.body){const e=this.inertDocument.createElement("html");this.inertDocument.appendChild(e);const i=this.inertDocument.createElement("body");e.appendChild(i)}}getInertBodyElement(t){const e=this.inertDocument.createElement("template");if("content"in e)return e.innerHTML=Wo(t),e;const i=this.inertDocument.createElement("body");return i.innerHTML=Wo(t),this.defaultDoc.documentMode&&this.stripCustomNsAttrs(i),i}stripCustomNsAttrs(t){const e=t.attributes;for(let r=e.length-1;0hl(t.trim())).join(", ")),this.buf.push(" ",o,'="',Cb(l),'"')}var n;return this.buf.push(">"),!0}endElement(t){const e=t.nodeName.toLowerCase();Gf.hasOwnProperty(e)&&!vb.hasOwnProperty(e)&&(this.buf.push(""))}chars(t){this.buf.push(Cb(t))}checkClobberedElement(t,e){if(e&&(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${t.outerHTML}`);return e}}const FR=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,LR=/([^\#-~ |!])/g;function Cb(n){return n.replace(/&/g,"&").replace(FR,function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"}).replace(LR,function(t){return"&#"+t.charCodeAt(0)+";"}).replace(//g,">")}let pd;function Db(n,t){let e=null;try{pd=pd||function gb(n){const t=new TR(n);return function AR(){try{return!!(new window.DOMParser).parseFromString(Wo(""),"text/html")}catch(n){return!1}}()?new kR(t):t}(n);let i=t?String(t):"";e=pd.getInertBodyElement(i);let r=5,s=i;do{if(0===r)throw new Error("Failed to sanitize html because the input is unstable");r--,i=s,s=e.innerHTML,e=pd.getInertBodyElement(i)}while(i!==s);return Wo((new OR).sanitizeChildren(Yf(e)||e))}finally{if(e){const i=Yf(e)||e;for(;i.firstChild;)i.removeChild(i.firstChild)}}}function Yf(n){return"content"in n&&function NR(n){return n.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===n.nodeName}(n)?n.content:null}var Ut=(()=>((Ut=Ut||{})[Ut.NONE=0]="NONE",Ut[Ut.HTML=1]="HTML",Ut[Ut.STYLE=2]="STYLE",Ut[Ut.SCRIPT=3]="SCRIPT",Ut[Ut.URL=4]="URL",Ut[Ut.RESOURCE_URL=5]="RESOURCE_URL",Ut))();function Kf(n){const t=function pl(){const n=ke();return n&&n[12]}();return t?t.sanitize(Ut.URL,n)||"":_r(n,"URL")?Mi(n):hl(gt(n))}function Zf(n){return n.ngOriginalError}class qr{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&Zf(t);for(;e&&Zf(e);)e=Zf(e);return e||null}}const Xf=new Map;let JR=0;const ep="__ngContext__";function qn(n,t){hi(t)?(n[ep]=t[20],function t1(n){Xf.set(n[20],n)}(t)):n[ep]=t}function ml(n){const t=n[ep];return"number"==typeof t?function xb(n){return Xf.get(n)||null}(t):t||null}function tp(n){const t=ml(n);return t?hi(t)?t:t.lView:null}const u1=(()=>("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(qt))();function Yr(n){return n instanceof Function?n():n}var xi=(()=>((xi=xi||{})[xi.Important=1]="Important",xi[xi.DashCase=2]="DashCase",xi))();function ip(n,t){return undefined(n,t)}function gl(n){const t=n[3];return tr(t)?t[3]:t}function rp(n){return Fb(n[13])}function sp(n){return Fb(n[4])}function Fb(n){for(;null!==n&&!tr(n);)n=n[4];return n}function Yo(n,t,e,i,r){if(null!=i){let s,o=!1;tr(i)?s=i:hi(i)&&(o=!0,i=i[0]);const a=Cn(i);0===n&&null!==e?null==r?jb(t,e,a):Ys(t,e,a,r||null,!0):1===n&&null!==e?Ys(t,e,a,r||null,!0):2===n?function Kb(n,t,e){const i=md(n,t);i&&function x1(n,t,e,i){dn(n)?n.removeChild(t,e,i):t.removeChild(e)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function T1(n,t,e,i,r){const s=e[7];s!==Cn(e)&&Yo(t,n,i,s,r);for(let a=10;a0&&(n[e-1][4]=i[4]);const s=rd(n,10+t);!function v1(n,t){_l(n,t,t[11],2,null,null),t[0]=null,t[6]=null}(i[1],i);const o=s[19];null!==o&&o.detachView(s[1]),i[3]=null,i[4]=null,i[2]&=-65}return i}function Bb(n,t){if(!(128&t[2])){const e=t[11];dn(e)&&e.destroyNode&&_l(n,t,e,3,null,null),function w1(n){let t=n[13];if(!t)return cp(n[1],n);for(;t;){let e=null;if(hi(t))e=t[13];else{const i=t[10];i&&(e=i)}if(!e){for(;t&&!t[4]&&t!==n;)hi(t)&&cp(t[1],t),t=t[3];null===t&&(t=n),hi(t)&&cp(t[1],t),e=t&&t[4]}t=e}}(t)}}function cp(n,t){if(!(128&t[2])){t[2]&=-65,t[2]|=128,function M1(n,t){let e;if(null!=n&&null!=(e=n.destroyHooks))for(let i=0;i=0?i[r=c]():i[r=-c].unsubscribe(),s+=2}else{const o=i[r=e[s+1]];e[s].call(o)}if(null!==i){for(let s=r+1;ss?"":r[f+1].toLowerCase();const k=8&i?w:null;if(k&&-1!==Xb(k,c,0)||2&i&&c!==w){if(rr(i))return!1;o=!0}}}}else{if(!o&&!rr(i)&&!rr(l))return!1;if(o&&rr(l))continue;o=!1,i=l|1&i}}return rr(i)||o}function rr(n){return 0==(1&n)}function O1(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!rr(o)&&(t+=n0(s,r),r=""),i=o,s=s||!rr(i);e++}return""!==r&&(t+=n0(s,r)),t}const _t={};function Ee(n){r0(Lt(),ke(),ni()+n,!1)}function r0(n,t,e,i){if(!i)if(3==(3&t[2])){const s=n.preOrderCheckHooks;null!==s&&Qc(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Zc(t,s,0,e)}vs(e)}const l0=new De("ENVIRONMENT_INITIALIZER"),c0=new De("INJECTOR_DEF_TYPES");function q1(...n){return{\u0275providers:d0(0,n)}}function d0(n,...t){const e=[],i=new Set;let r;return Wr(t,s=>{const o=s;pp(o,e,[],i)&&(r||(r=[]),r.push(o))}),void 0!==r&&u0(r,e),e}function u0(n,t){for(let e=0;e{t.push(s)})}}function pp(n,t,e,i){if(!(n=pt(n)))return!1;let r=null,s=hy(n);const o=!s&&Qt(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=hy(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const c of l)pp(c,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let c;i.add(r);try{Wr(s.imports,d=>{pp(d,t,e,i)&&(c||(c=[]),c.push(d))})}finally{}void 0!==c&&u0(c,t)}if(!a){const c=Ws(r)||(()=>new r);t.push({provide:r,useFactory:c,deps:jt},{provide:c0,useValue:r,multi:!0},{provide:l0,useValue:()=>te(r),multi:!0})}const l=s.providers;null==l||a||Wr(l,d=>{t.push(d)})}}return r!==n&&void 0!==n.providers}const Y1=Yt({provide:String,useValue:Yt});function mp(n){return null!==n&&"object"==typeof n&&Y1 in n}function Ks(n){return"function"==typeof n}const gp=new De("INJECTOR",-1);class p0{get(t,e=al){if(e===al){const i=new Error(`NullInjectorError: No provider for ${Kt(t)}!`);throw i.name="NullInjectorError",i}return e}}const _p=new De("Set Injector scope."),vd={},Q1={};let vp;function yp(){return void 0===vp&&(vp=new p0),vp}class Qs{}class m0 extends Qs{constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,wp(t,o=>this.processProvider(o)),this.records.set(gp,Ko(void 0,this)),r.has("environment")&&this.records.set(Qs,Ko(void 0,this));const s=this.records.get(_p);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(c0.multi,jt,at.Self))}get destroyed(){return this._destroyed}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const t of this._ngOnDestroyHooks)t.ngOnDestroy();for(const t of this._onDestroyHooks)t()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),this._onDestroyHooks.length=0}}onDestroy(t){this._onDestroyHooks.push(t)}get(t,e=al,i=at.Default){this.assertNotDestroyed();const r=ad(this),s=pr(void 0);try{if(!(i&at.SkipSelf)){let a=this.records.get(t);if(void 0===a){const l=function tP(n){return"function"==typeof n||"object"==typeof n&&n instanceof De}(t)&&lf(t);a=l&&this.injectableDefInScope(l)?Ko(bp(t),vd):null,this.records.set(t,a)}if(null!=a)return this.hydrate(t,a)}return(i&at.Self?yp():this.parent).get(t,e=i&at.Optional&&e===al?null:e)}catch(o){if("NullInjectorError"===o.name){if((o[od]=o[od]||[]).unshift(Kt(t)),r)throw o;return function sR(n,t,e,i){const r=n[od];throw t[ib]&&r.unshift(t[ib]),n.message=function oR(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=Kt(t);if(Array.isArray(t))r=t.map(Kt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):Kt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(tR,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[od]=null,n}(o,t,"R3InjectorError",this.source)}throw o}finally{pr(s),ad(r)}}resolveInjectorInitializers(){const t=ad(this),e=pr(void 0);try{const i=this.get(l0.multi,jt,at.Self);for(const r of i)r()}finally{ad(t),pr(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(Kt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Be(205,!1)}processProvider(t){let e=Ks(t=pt(t))?t:pt(t&&t.provide);const i=function X1(n){return mp(n)?Ko(void 0,n.useValue):Ko(g0(n),vd)}(t);if(Ks(t)||!0!==t.multi)this.records.get(e);else{let r=this.records.get(e);r||(r=Ko(void 0,vd,!0),r.factory=()=>Uf(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===vd&&(e.value=Q1,e.value=e.factory()),"object"==typeof e.value&&e.value&&function eP(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=pt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}}function bp(n){const t=lf(n),e=null!==t?t.factory:Ws(n);if(null!==e)return e;if(n instanceof De)throw new Be(204,!1);if(n instanceof Function)return function Z1(n){const t=n.length;if(t>0)throw ol(t,"?"),new Be(204,!1);const e=function jA(n){const t=n&&(n[Bc]||n[fy]);if(t){const e=function UA(n){if(n.hasOwnProperty("name"))return n.name;const t=(""+n).match(/^function\s*([^\s(]+)/);return null===t?"":t[1]}(n);return console.warn(`DEPRECATED: DI is instantiating a token "${e}" that inherits its @Injectable decorator but does not provide one itself.\nThis will become an error in a future version of Angular. Please add @Injectable() to the "${e}" class.`),t}return null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new Be(204,!1)}function g0(n,t,e){let i;if(Ks(n)){const r=pt(n);return Ws(r)||bp(r)}if(mp(n))i=()=>pt(n.useValue);else if(function f0(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Uf(n.deps||[]));else if(function h0(n){return!(!n||!n.useExisting)}(n))i=()=>te(pt(n.useExisting));else{const r=pt(n&&(n.useClass||n.provide));if(!function J1(n){return!!n.deps}(n))return Ws(r)||bp(r);i=()=>new r(...Uf(n.deps))}return i}function Ko(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function nP(n){return!!n.\u0275providers}function wp(n,t){for(const e of n)Array.isArray(e)?wp(e,t):nP(e)?wp(e.\u0275providers,t):t(e)}function _0(n,t=null,e=null,i){const r=v0(n,t,e,i);return r.resolveInjectorInitializers(),r}function v0(n,t=null,e=null,i,r=new Set){const s=[e||jt,q1(n)];return i=i||("object"==typeof n?void 0:Kt(n)),new m0(s,t||yp(),i||null,r)}let Jt=(()=>{class n{static create(e,i){var r;if(Array.isArray(e))return _0({name:""},i,e,"");{const s=null!==(r=e.name)&&void 0!==r?r:"";return _0({name:s},e.parent,e.providers,s)}}}return n.THROW_IF_NOT_FOUND=al,n.NULL=new p0,n.\u0275prov=Ie({token:n,providedIn:"any",factory:()=>te(gp)}),n.__NG_ELEMENT_ID__=-1,n})();function x(n,t=at.Default){const e=ke();return null===e?te(n,t):qy(Sn(),e,pt(n),t)}function bs(){throw new Error("invalid")}function bd(n,t){return n<<17|t<<2}function sr(n){return n>>17&32767}function Tp(n){return 2|n}function Kr(n){return(131068&n)>>2}function Ap(n,t){return-131069&n|t<<2}function Ip(n){return 1|n}function B0(n,t){const e=n.contentQueries;if(null!==e)for(let i=0;i22&&r0(n,t,22,!1),e(i,r)}finally{vs(s)}}function H0(n,t,e){if(mf(t)){const r=t.directiveEnd;for(let s=t.directiveStart;s0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(a)!=l&&a.push(l),a.push(i,r,o)}}function q0(n,t){null!==n.hostBindings&&n.hostBindings(1,t)}function Y0(n,t){t.flags|=2,(n.components||(n.components=[])).push(t.index)}function GP(n,t,e){if(e){if(t.exportAs)for(let i=0;i0&&Gp(e)}}function Gp(n){for(let i=rp(n);null!==i;i=sp(i))for(let r=10;r0&&Gp(s)}const e=n[1].components;if(null!==e)for(let i=0;i0&&Gp(r)}}function XP(n,t){const e=Ci(t,n),i=e[1];(function JP(n,t){for(let e=t.length;ePromise.resolve(null))();function J0(n){return n[7]||(n[7]=[])}function ew(n){return n.cleanup||(n.cleanup=[])}function tw(n,t,e){return(null===n||nr(n))&&(e=function uI(n){for(;Array.isArray(n);){if("object"==typeof n[1])return n;n=n[0]}return null}(e[t.index])),e[11]}function nw(n,t){const e=n[9],i=e?e.get(qr,null):null;i&&i.handleError(t)}function iw(n,t,e,i,r){for(let s=0;s=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Jc(r.hostAttrs,e=Jc(e,r.hostAttrs))}}(i)}function Zp(n){return n===Ao?{}:n===jt?[]:n}function pO(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function mO(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function gO(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}let xd=null;function Zs(){if(!xd){const n=qt.Symbol;if(n&&n.iterator)xd=n.iterator;else{const t=Object.getOwnPropertyNames(Map.prototype);for(let e=0;ea(Cn(Oe[i.index])):i.index;if(dn(e)){let Oe=null;if(!a&&l&&(Oe=function SO(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==Oe)(Oe.__ngLastListenerFn__||Oe).__ngNextListenerFn__=s,Oe.__ngLastListenerFn__=s,k=!1;else{s=tm(i,t,f,s,!1);const ft=e.listen(ce,r,s);w.push(s,ft),d&&d.push(r,he,Te,Te+1)}}else s=tm(i,t,f,s,!0),ce.addEventListener(r,s,o),w.push(s),d&&d.push(r,he,Te,o)}else s=tm(i,t,f,s,!1);const j=i.outputs;let K;if(k&&null!==j&&(K=j[r])){const ae=K.length;if(ae)for(let ce=0;ce0;)t=t[15],n--;return t}(n,mt.lFrame.contextLView))[8]}(n)}function kO(n,t){let e=null;const i=function F1(n){const t=n.attrs;if(null!=t){const e=t.indexOf(5);if(0==(1&e))return t[e+1]}return null}(n);for(let r=0;r=0}const Tn={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function Lw(n){return n.substring(Tn.key,Tn.keyEnd)}function Nw(n,t){const e=Tn.textEnd;return e===t?-1:(t=Tn.keyEnd=function FO(n,t,e){for(;t32;)t++;return t}(n,Tn.key=t,e),da(n,t,e))}function da(n,t,e){for(;t=0;e=Nw(t,e))Ei(n,Lw(t),!0)}function ar(n,t,e,i){const r=ke(),s=Lt(),o=Gr(2);s.firstUpdatePass&&zw(s,n,o,i),t!==_t&&Yn(r,o,t)&&Gw(s,s.data[ni()],r,r[11],n,r[o+1]=function WO(n,t){return null==n||("string"==typeof t?n+=t:"object"==typeof n&&(n=Kt(Mi(n)))),n}(t,e),i,o)}function Uw(n,t){return t>=n.expandoStartIndex}function zw(n,t,e,i){const r=n.data;if(null===r[e+1]){const s=r[ni()],o=Uw(n,e);qw(s,i)&&null===t&&!o&&(t=!1),t=function HO(n,t,e,i){const r=kf(n);let s=i?t.residualClasses:t.residualStyles;if(null===r)0===(i?t.classBindings:t.styleBindings)&&(e=Dl(e=im(null,n,t,e,i),t.attrs,i),s=null);else{const o=t.directiveStylingLast;if(-1===o||n[o]!==r)if(e=im(r,n,t,e,i),null===s){let l=function jO(n,t,e){const i=e?t.classBindings:t.styleBindings;if(0!==Kr(i))return n[sr(i)]}(n,t,i);void 0!==l&&Array.isArray(l)&&(l=im(null,n,t,l[1],i),l=Dl(l,t.attrs,i),function UO(n,t,e,i){n[sr(e?t.classBindings:t.styleBindings)]=i}(n,t,i,l))}else s=function zO(n,t,e){let i;const r=t.directiveEnd;for(let s=1+t.directiveStylingLast;s0)&&(c=!0)}else d=e;if(r)if(0!==l){const w=sr(n[a+1]);n[i+1]=bd(w,a),0!==w&&(n[w+1]=Ap(n[w+1],i)),n[a+1]=function yP(n,t){return 131071&n|t<<17}(n[a+1],i)}else n[i+1]=bd(a,0),0!==a&&(n[a+1]=Ap(n[a+1],i)),a=i;else n[i+1]=bd(l,0),0===a?a=i:n[l+1]=Ap(n[l+1],i),l=i;c&&(n[i+1]=Tp(n[i+1])),Fw(n,d,i,!0),Fw(n,d,i,!1),function AO(n,t,e,i,r){const s=r?n.residualClasses:n.residualStyles;null!=s&&"string"==typeof t&&$o(s,t)>=0&&(e[i+1]=Ip(e[i+1]))}(t,d,n,i,s),o=bd(a,l),s?t.classBindings=o:t.styleBindings=o}(r,s,t,e,o,i)}}function im(n,t,e,i,r){let s=null;const o=e.directiveEnd;let a=e.directiveStylingLast;for(-1===a?a=e.directiveStart:a++;a0;){const l=n[r],c=Array.isArray(l),d=c?l[1]:l,f=null===d;let w=e[r+1];w===_t&&(w=f?jt:void 0);let k=f?Vf(w,i):d===i?w:void 0;if(c&&!Ad(k)&&(k=Vf(l,i)),Ad(k)&&(a=k,o))return a;const j=n[r+1];r=o?sr(j):Kr(j)}if(null!==t){let l=s?t.residualClasses:t.residualStyles;null!=l&&(a=Vf(l,i))}return a}function Ad(n){return void 0!==n}function qw(n,t){return 0!=(n.flags&(t?16:32))}function Ue(n,t=""){const e=ke(),i=Lt(),r=n+22,s=i.firstCreatePass?Zo(i,r,1,t,null):i.data[r],o=e[r]=function op(n,t){return dn(n)?n.createText(t):n.createTextNode(t)}(e[11],t);gd(i,e,o,s),mr(s,!1)}function Kn(n){return Ln("",n,""),Kn}function Ln(n,t,e){const i=ke(),r=ta(i,n,t,e);return r!==_t&&Qr(i,ni(),r),Ln}function El(n,t,e,i,r){const s=ke(),o=na(s,n,t,e,i,r);return o!==_t&&Qr(s,ni(),o),El}function rm(n,t,e,i,r,s,o){const a=ke(),l=ia(a,n,t,e,i,r,s,o);return l!==_t&&Qr(a,ni(),l),rm}function sm(n,t,e,i,r,s,o,a,l,c,d){const f=ke(),w=sa(f,n,t,e,i,r,s,o,a,l,c,d);return w!==_t&&Qr(f,ni(),w),sm}function om(n,t,e){!function lr(n,t,e,i){const r=Lt(),s=Gr(2);r.firstUpdatePass&&zw(r,null,s,i);const o=ke();if(e!==_t&&Yn(o,s,e)){const a=r.data[ni()];if(qw(a,i)&&!Uw(r,s)){let l=i?a.classesWithoutHost:a.stylesWithoutHost;null!==l&&(e=sf(l,e||"")),Jp(r,a,o,e,i)}else!function GO(n,t,e,i,r,s,o,a){r===_t&&(r=jt);let l=0,c=0,d=0((He=He||{})[He.LocaleId=0]="LocaleId",He[He.DayPeriodsFormat=1]="DayPeriodsFormat",He[He.DayPeriodsStandalone=2]="DayPeriodsStandalone",He[He.DaysFormat=3]="DaysFormat",He[He.DaysStandalone=4]="DaysStandalone",He[He.MonthsFormat=5]="MonthsFormat",He[He.MonthsStandalone=6]="MonthsStandalone",He[He.Eras=7]="Eras",He[He.FirstDayOfWeek=8]="FirstDayOfWeek",He[He.WeekendRange=9]="WeekendRange",He[He.DateFormat=10]="DateFormat",He[He.TimeFormat=11]="TimeFormat",He[He.DateTimeFormat=12]="DateTimeFormat",He[He.NumberSymbols=13]="NumberSymbols",He[He.NumberFormats=14]="NumberFormats",He[He.CurrencyCode=15]="CurrencyCode",He[He.CurrencySymbol=16]="CurrencySymbol",He[He.CurrencyName=17]="CurrencyName",He[He.Currencies=18]="Currencies",He[He.Directionality=19]="Directionality",He[He.PluralCase=20]="PluralCase",He[He.ExtraData=21]="ExtraData",He))();const ha="en-US";let dC=ha;function cm(n,t,e,i,r){if(n=pt(n),Array.isArray(n))for(let s=0;s>20;if(Ks(n)||!n.multi){const k=new el(l,r,x),j=um(a,t,r?d:d+w,f);-1===j?(nd(nl(c,o),s,a),dm(s,n,t.length),t.push(a),c.directiveStart++,c.directiveEnd++,r&&(c.providerIndexes+=1048576),e.push(k),o.push(k)):(e[j]=k,o[j]=k)}else{const k=um(a,t,d+w,f),j=um(a,t,d,d+w),K=k>=0&&e[k],ae=j>=0&&e[j];if(r&&!ae||!r&&!K){nd(nl(c,o),s,a);const ce=function cL(n,t,e,i,r){const s=new el(n,e,x);return s.multi=[],s.index=t,s.componentProviders=0,FC(s,r,i&&!e),s}(r?lL:aL,e.length,r,i,l);!r&&ae&&(e[j].providerFactory=ce),dm(s,n,t.length,0),t.push(a),c.directiveStart++,c.directiveEnd++,r&&(c.providerIndexes+=1048576),e.push(ce),o.push(ce)}else dm(s,n,k>-1?k:j,FC(e[r?j:k],l,!r&&i));!r&&i&&ae&&e[j].componentProviders++}}}function dm(n,t,e,i){const r=Ks(t),s=function K1(n){return!!n.useClass}(t);if(r||s){const l=(s?pt(t.useClass):t).prototype.ngOnDestroy;if(l){const c=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const d=c.indexOf(e);-1===d?c.push(e,[i,l]):c[d+1].push(i,l)}else c.push(e,l)}}}function FC(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function um(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function oL(n,t,e){const i=Lt();if(i.firstCreatePass){const r=nr(n);cm(e,i.data,i.blueprint,r,!0),cm(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class uL{resolveComponentFactory(t){throw function dL(n){const t=Error(`No component factory found for ${Kt(n)}. Did you add it to @NgModule.entryComponents?`);return t.ngComponent=n,t}(t)}}let io=(()=>{class n{}return n.NULL=new uL,n})();class Ds{}class NC{}class BC{}function fL(){return pa(Sn(),ke())}function pa(n,t){return new Je(Bi(n,t))}let Je=(()=>{class n{constructor(e){this.nativeElement=e}}return n.__NG_ELEMENT_ID__=fL,n})();function pL(n){return n instanceof Je?n.nativeElement:n}class Tl{}let Xr=(()=>{class n{}return n.__NG_ELEMENT_ID__=()=>function gL(){const n=ke(),e=Ci(Sn().index,n);return function mL(n){return n[11]}(hi(e)?e:n)}(),n})(),_L=(()=>{class n{}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:()=>null}),n})();class ro{constructor(t){this.full=t,this.major=t.split(".")[0],this.minor=t.split(".")[1],this.patch=t.split(".").slice(2).join(".")}}const vL=new ro("14.0.1"),fm={};function Ld(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];if(null!==s&&i.push(Cn(s)),tr(s))for(let a=10;a-1&&(lp(t,i),rd(e,i))}this._attachedToViewContainer=!1}Bb(this._lView[1],this._lView)}onDestroy(t){$0(this._lView[1],this._lView,null,t)}markForCheck(){Wp(this._cdRefInjectingView||this._lView)}detach(){this._lView[2]&=-65}reattach(){this._lView[2]|=64}detectChanges(){!function Yp(n,t,e){const i=t[10];i.begin&&i.begin();try{Jo(n,t,n.template,e)}catch(r){throw nw(t,r),r}finally{i.end&&i.end()}}(this._lView[1],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Be(902,"");this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function b1(n,t){_l(n,t,t[11],2,null,null)}(this._lView[1],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new Be(902,"");this._appRef=t}}class yL extends Al{constructor(t){super(t),this._view=t}detectChanges(){X0(this._view)}checkNoChanges(){}get context(){return null}}class pm extends io{constructor(t){super(),this.ngModule=t}resolveComponentFactory(t){const e=Qt(t);return new mm(e,this.ngModule)}}function VC(n){const t=[];for(let e in n)n.hasOwnProperty(e)&&t.push({propName:n[e],templateName:e});return t}class wL{constructor(t,e){this.injector=t,this.parentInjector=e}get(t,e,i){const r=this.injector.get(t,fm,i);return r!==fm||e===fm?r:this.parentInjector.get(t,e,i)}}class mm extends BC{constructor(t,e){super(),this.componentDef=t,this.ngModule=e,this.componentType=t.type,this.selector=function H1(n){return n.map(V1).join(",")}(t.selectors),this.ngContentSelectors=t.ngContentSelectors?t.ngContentSelectors:[],this.isBoundToModule=!!e}get inputs(){return VC(this.componentDef.inputs)}get outputs(){return VC(this.componentDef.outputs)}create(t,e,i,r){let s=(r=r||this.ngModule)instanceof Qs?r:null==r?void 0:r.injector;s&&null!==this.componentDef.getStandaloneInjector&&(s=this.componentDef.getStandaloneInjector(s)||s);const o=s?new wL(t,s):t,a=o.get(Tl,Ey),l=o.get(_L,null),c=a.createRenderer(null,this.componentDef),d=this.componentDef.selectors[0][0]||"div",f=i?function z0(n,t,e){if(dn(n))return n.selectRootElement(t,e===Ji.ShadowDom);let i="string"==typeof t?n.querySelector(t):t;return i.textContent="",i}(c,i,this.componentDef.encapsulation):ap(a.createRenderer(null,this.componentDef),d,function bL(n){const t=n.toLowerCase();return"svg"===t?"svg":"math"===t?"math":null}(d)),w=this.componentDef.onPush?288:272,k=function pw(n,t){return{components:[],scheduler:n||u1,clean:tO,playerHandler:t||null,flags:0}}(),j=Dd(0,null,null,1,0,null,null,null,null,null),K=vl(null,j,k,w,null,null,a,c,l,o,null);let ae,ce;qc(K);try{const Te=function hw(n,t,e,i,r,s){const o=e[1];e[22]=n;const l=Zo(o,22,2,"#host",null),c=l.mergedAttrs=t.hostAttrs;null!==c&&(Md(l,c,!0),null!==n&&(Xc(r,n,c),null!==l.classes&&fp(r,n,l.classes),null!==l.styles&&Zb(r,n,l.styles)));const d=i.createRenderer(n,t),f=vl(e,j0(t),null,t.onPush?32:16,e[22],l,i,d,s||null,null,null);return o.firstCreatePass&&(nd(nl(l,e),o,t.type),Y0(o,l),K0(l,e.length,1)),Ed(e,f),e[22]=f}(f,this.componentDef,K,a,c);if(f)if(i)Xc(c,f,["ng-version",vL.full]);else{const{attrs:he,classes:Oe}=function j1(n){const t=[],e=[];let i=1,r=2;for(;i0&&fp(c,f,Oe.join(" "))}if(ce=Cf(j,22),void 0!==e){const he=ce.projection=[];for(let Oe=0;Oee()),this.destroyCbs=null}onDestroy(t){this.destroyCbs.push(t)}}class gm extends NC{constructor(t){super(),this.moduleType=t}create(t){return new HC(this.moduleType,t)}}class ML extends Ds{constructor(t,e,i){super(),this.componentFactoryResolver=new pm(this),this.instance=null;const r=new m0([...t,{provide:Ds,useValue:this},{provide:io,useValue:this.componentFactoryResolver}],e||yp(),i,new Set(["environment"]));this.injector=r,r.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}function Nd(n,t=null,e=null){return new ML(n,t,e).injector}function Il(n,t){const e=n[t];return e===_t?void 0:e}function Jr(n,t){const e=Lt();let i;const r=n+22;e.firstCreatePass?(i=function BL(n,t){if(t)for(let e=t.length-1;e>=0;e--){const i=t[e];if(n===i.name)return i}}(t,e.pipeRegistry),e.data[r]=i,i.onDestroy&&(e.destroyHooks||(e.destroyHooks=[])).push(r,i.onDestroy)):i=e.data[r];const s=i.factory||(i.factory=Ws(i.type)),o=pr(x);try{const a=ed(!1),l=s();return ed(a),function EO(n,t,e,i){e>=n.data.length&&(n.data[e]=null,n.blueprint[e]=null),t[e]=i}(e,ke(),r,l),l}finally{pr(o)}}function so(n,t,e){const i=n+22,r=ke(),s=Fo(r,i);return Rl(r,i)?function jC(n,t,e,i,r,s){const o=t+e;return Yn(n,o,r)?br(n,o+1,s?i.call(s,r):i(r)):Il(n,o+1)}(r,ti(),t,s.transform,e,s):s.transform(e)}function vm(n,t,e,i){const r=n+22,s=ke(),o=Fo(s,r);return Rl(s,r)?function UC(n,t,e,i,r,s,o){const a=t+e;return Xs(n,a,r,s)?br(n,a+2,o?i.call(o,r,s):i(r,s)):Il(n,a+2)}(s,ti(),t,o.transform,e,i,o):o.transform(e,i)}function Rl(n,t){return n[1].data[t].pure}function ym(n){return t=>{setTimeout(n,void 0,t)}}const je=class UL extends ue{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){var r,s,o;let a=t,l=e||(()=>null),c=i;if(t&&"object"==typeof t){const f=t;a=null===(r=f.next)||void 0===r?void 0:r.bind(f),l=null===(s=f.error)||void 0===s?void 0:s.bind(f),c=null===(o=f.complete)||void 0===o?void 0:o.bind(f)}this.__isAsync&&(l=ym(l),a&&(a=ym(a)),c&&(c=ym(c)));const d=super.subscribe({next:a,error:l,complete:c});return t instanceof X&&t.add(d),d}};function zL(){return this._results[Zs()]()}class ma{constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=null,this.length=0,this.first=void 0,this.last=void 0;const e=Zs(),i=ma.prototype;i[e]||(i[e]=zL)}get changes(){return this._changes||(this._changes=new je)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){const i=this;i.dirty=!1;const r=Di(t);(this._changesDetected=!function GI(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{}return n.__NG_ELEMENT_ID__=WL,n})();const $L=_n,GL=class extends $L{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}createEmbeddedView(t,e){const i=this._declarationTContainer.tViews,r=vl(this._declarationLView,i,t,16,null,i.declTNode,null,null,null,null,e||null);r[17]=this._declarationLView[this._declarationTContainer.index];const o=this._declarationLView[19];return null!==o&&(r[19]=o.createEmbeddedView(i)),yl(i,r,t),new Al(r)}};function WL(){return Bd(Sn(),ke())}function Bd(n,t){return 4&n.type?new GL(t,n,pa(n,t)):null}let An=(()=>{class n{}return n.__NG_ELEMENT_ID__=qL,n})();function qL(){return YC(Sn(),ke())}const YL=An,WC=class extends YL{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return pa(this._hostTNode,this._hostLView)}get injector(){return new Vo(this._hostTNode,this._hostLView)}get parentInjector(){const t=td(this._hostTNode,this._hostLView);if(Uy(t)){const e=Bo(t,this._hostLView),i=No(t);return new Vo(e[1].data[i+8],e)}return new Vo(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=qC(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-10}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const o=t.createEmbeddedView(e||{},s);return this.insert(o,r),o}createComponent(t,e,i,r,s){const o=t&&!function sl(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new mm(Qt(t)),c=i||this.parentInjector;if(!s&&null==l.ngModule){const w=(o?c:this.parentInjector).get(Qs,null);w&&(s=w)}const d=l.create(c,r,void 0,s);return this.insert(d.hostView,a),d}insert(t,e){const i=t._lView,r=i[1];if(function fI(n){return tr(n[3])}(i)){const d=this.indexOf(t);if(-1!==d)this.detach(d);else{const f=i[3],w=new WC(f,f[6],f[3]);w.detach(w.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;!function C1(n,t,e,i){const r=10+i,s=e.length;i>0&&(e[r-1][4]=t),i0)i.push(o[a/2]);else{const c=s[a+1],d=t[-l];for(let f=10;f{class n{constructor(e){this.appInits=e,this.resolve=Hd,this.reject=Hd,this.initialized=!1,this.done=!1,this.donePromise=new Promise((i,r)=>{this.resolve=i,this.reject=r})}runInitializers(){if(this.initialized)return;const e=[],i=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let r=0;r{s.subscribe({complete:a,error:l})});e.push(o)}}Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}}return n.\u0275fac=function(e){return new(e||n)(te(Am,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Ol=new De("AppId",{providedIn:"root",factory:function vD(){return`${Im()}${Im()}${Im()}`}});function Im(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const yD=new De("Platform Initializer"),Ud=new De("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),bD=new De("appBootstrapListener"),fn=new De("AnimationModuleType");let DN=(()=>{class n{log(e){console.log(e)}warn(e){console.warn(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();const Er=new De("LocaleId",{providedIn:"root",factory:()=>ld(Er,at.Optional|at.SkipSelf)||function EN(){return"undefined"!=typeof $localize&&$localize.locale||ha}()});class xN{constructor(t,e){this.ngModuleFactory=t,this.componentFactories=e}}let Rm=(()=>{class n{compileModuleSync(e){return new gm(e)}compileModuleAsync(e){return Promise.resolve(this.compileModuleSync(e))}compileModuleAndAllComponentsSync(e){const i=this.compileModuleSync(e),s=Yr(bi(e).declarations).reduce((o,a)=>{const l=Qt(a);return l&&o.push(new mm(l)),o},[]);return new xN(i,s)}compileModuleAndAllComponentsAsync(e){return Promise.resolve(this.compileModuleAndAllComponentsSync(e))}clearCache(){}clearCacheFor(e){}getModuleId(e){}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const kN=(()=>Promise.resolve(0))();function Pm(n){"undefined"==typeof Zone?kN.then(()=>{n&&n.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",n)}class et{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new je(!1),this.onMicrotaskEmpty=new je(!1),this.onStable=new je(!1),this.onError=new je(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function TN(){let n=qt.requestAnimationFrame,t=qt.cancelAnimationFrame;if("undefined"!=typeof Zone&&n&&t){const e=n[Zone.__symbol__("OriginalDelegate")];e&&(n=e);const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:t}}().nativeRequestAnimationFrame,function RN(n){const t=()=>{!function IN(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(qt,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,Fm(n),n.isCheckStableRunning=!0,Om(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),Fm(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{try{return wD(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),CD(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return wD(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),CD(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,Fm(n),Om(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return"undefined"!=typeof Zone&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!et.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}static assertNotInAngularZone(){if(et.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,AN,Hd,Hd);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const AN={};function Om(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function Fm(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function wD(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function CD(n){n._nesting--,Om(n)}class PN{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new je,this.onMicrotaskEmpty=new je,this.onStable=new je,this.onError=new je}run(t,e,i){return t.apply(e,i)}runGuarded(t,e,i){return t.apply(e,i)}runOutsideAngular(t){return t()}runTask(t,e,i,r){return t.apply(e,i)}}const DD=new De(""),zd=new De("");let Fl,Lm=(()=>{class n{constructor(e,i,r){this._ngZone=e,this.registry=i,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,Fl||(function ON(n){Fl=n}(r),r.addToWindow(i)),this._watchAngularEvents(),e.run(()=>{this.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._didWork=!0,this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{et.assertNotInAngularZone(),Pm(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}increasePendingRequestCount(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}decreasePendingRequestCount(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}isStable(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())Pm(()=>{for(;0!==this._callbacks.length;){let e=this._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb(this._didWork)}this._didWork=!1});else{let e=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>!i.updateCb||!i.updateCb(e)||(clearTimeout(i.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(e=>({source:e.source,creationLocation:e.creationLocation,data:e.data})):[]}addCallback(e,i,r){let s=-1;i&&i>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),e(this._didWork,this.getPendingTasks())},i)),this._callbacks.push({doneCb:e,timeoutId:s,updateCb:r})}whenStable(e,i,r){if(r&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(e,i,r),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}registerApplication(e){this.registry.registerApplication(e,this)}unregisterApplication(e){this.registry.unregisterApplication(e)}findProviders(e,i,r){return[]}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(Nm),te(zd))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),Nm=(()=>{class n{constructor(){this._applications=new Map}registerApplication(e,i){this._applications.set(e,i)}unregisterApplication(e){this._applications.delete(e)}unregisterAllApplications(){this._applications.clear()}getTestability(e){return this._applications.get(e)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(e,i=!0){var r;return null!==(r=null==Fl?void 0:Fl.findTestabilityInTree(this,e,i))&&void 0!==r?r:null}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})(),Mr=null;const ED=new De("AllowMultipleToken"),MD=new De("PlatformOnDestroy");class xD{constructor(t,e){this.name=t,this.token=e}}function kD(n,t,e=[]){const i=`Platform: ${t}`,r=new De(i);return(s=[])=>{let o=Bm();if(!o||o.injector.get(ED,!1)){const a=[...e,...s,{provide:r,useValue:!0}];n?n(a):function NN(n){if(Mr&&!Mr.get(ED,!1))throw new Be(400,"");Mr=n;const t=n.get(AD);(function SD(n){const t=n.get(yD,null);t&&t.forEach(e=>e())})(n)}(function TD(n=[],t){return Jt.create({name:t,providers:[{provide:_p,useValue:"platform"},{provide:MD,useValue:()=>Mr=null},...n]})}(a,i))}return function VN(n){const t=Bm();if(!t)throw new Be(401,"");return t}()}}function Bm(){var n;return null!==(n=null==Mr?void 0:Mr.get(AD))&&void 0!==n?n:null}let AD=(()=>{class n{constructor(e){this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(e,i){const r=function HN(n,t){let e;return e="noop"===n?new PN:("zone.js"===n?void 0:n)||new et(t),e}(null==i?void 0:i.ngZone,function ID(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!(!n||!n.ngZoneEventCoalescing)||!1,shouldCoalesceRunChangeDetection:!(!n||!n.ngZoneRunCoalescing)||!1}}(i)),s=[{provide:et,useValue:r}];return r.run(()=>{const o=Jt.create({providers:s,parent:this.injector,name:e.moduleType.name}),a=e.create(o),l=a.injector.get(qr,null);if(!l)throw new Be(402,"");return r.runOutsideAngular(()=>{const c=r.onError.subscribe({next:d=>{l.handleError(d)}});a.onDestroy(()=>{$d(this._modules,a),c.unsubscribe()})}),function RD(n,t,e){try{const i=e();return Cl(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(l,r,()=>{const c=a.injector.get(jd);return c.runInitializers(),c.donePromise.then(()=>(function uC(n){yi(n,"Expected localeId to be defined"),"string"==typeof n&&(dC=n.toLowerCase().replace(/_/g,"-"))}(a.injector.get(Er,ha)||ha),this._moduleDoBootstrap(a),a))})})}bootstrapModule(e,i=[]){const r=PD({},i);return function FN(n,t,e){const i=new gm(e);return Promise.resolve(i)}(0,0,e).then(s=>this.bootstrapModuleFactory(s,r))}_moduleDoBootstrap(e){const i=e.injector.get(Ll);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(r=>i.bootstrap(r));else{if(!e.instance.ngDoBootstrap)throw new Be(403,"");e.instance.ngDoBootstrap(i)}this._modules.push(e)}onDestroy(e){this._destroyListeners.push(e)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Be(404,"");this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());const e=this._injector.get(MD,null);null==e||e(),this._destroyed=!0}get destroyed(){return this._destroyed}}return n.\u0275fac=function(e){return new(e||n)(te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();function PD(n,t){return Array.isArray(t)?t.reduce(PD,n):Object.assign(Object.assign({},n),t)}let Ll=(()=>{class n{constructor(e,i,r,s){this._zone=e,this._injector=i,this._exceptionHandler=r,this._initStatus=s,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._stable=!0,this._destroyed=!1,this._destroyListeners=[],this.componentTypes=[],this.components=[],this._onMicrotaskEmptySubscription=this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const o=new J(l=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{l.next(this._stable),l.complete()})}),a=new J(l=>{let c;this._zone.runOutsideAngular(()=>{c=this._zone.onStable.subscribe(()=>{et.assertNotInAngularZone(),Pm(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,l.next(!0))})})});const d=this._zone.onUnstable.subscribe(()=>{et.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{l.next(!1)}))});return()=>{c.unsubscribe(),d.unsubscribe()}});this.isStable=$n(o,a.pipe(dy()))}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof BC;if(!this._initStatus.done)throw!r&&function _a(n){const t=Qt(n)||Jn(n)||ei(n);return null!==t&&t.standalone}(e),new Be(405,false);let s;s=r?e:this._injector.get(io).resolveComponentFactory(e),this.componentTypes.push(s.componentType);const o=function LN(n){return n.isBoundToModule}(s)?void 0:this._injector.get(Ds),l=s.create(Jt.NULL,[],i||s.selector,o),c=l.location.nativeElement,d=l.injector.get(DD,null);return null==d||d.registerApplication(c),l.onDestroy(()=>{this.detachView(l.hostView),$d(this.components,l),null==d||d.unregisterApplication(c)}),this._loadComponent(l),l}tick(){if(this._runningTick)throw new Be(101,"");try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(e))}finally{this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;$d(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e),this._injector.get(bD,[]).concat(this._bootstrapListeners).forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>$d(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new Be(406,false);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(Jt),te(qr),te(jd))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function $d(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let FD=!0,en=(()=>{class n{}return n.__NG_ELEMENT_ID__=zN,n})();function zN(n){return function $N(n,t,e){if(zc(n)&&!e){const i=Ci(n.index,t);return new Al(i,i)}return 47&n.type?new Al(t[16],t):null}(Sn(),ke(),16==(16&n))}class HD{constructor(){}supports(t){return bl(t)}create(t){return new QN(t)}}const KN=(n,t)=>t;class QN{constructor(t){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=t||KN}forEachItem(t){let e;for(e=this._itHead;null!==e;e=e._next)t(e)}forEachOperation(t){let e=this._itHead,i=this._removalsHead,r=0,s=null;for(;e||i;){const o=!i||e&&e.currentIndex{o=this._trackByFn(r,a),null!==e&&Object.is(e.trackById,o)?(i&&(e=this._verifyReinsertion(e,a,o,r)),Object.is(e.item,a)||this._addIdentityChange(e,a)):(e=this._mismatch(e,a,o,r),i=!0),e=e._next,r++}),this.length=r;return this._truncate(e),this.collection=t,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let t;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=t._nextMoved)t.previousIndex=t.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(t,e,i,r){let s;return null===t?s=this._itTail:(s=t._prev,this._remove(t)),null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._reinsertAfter(t,s,r)):null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(i,r))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._moveAfter(t,s,r)):t=this._addAfter(new ZN(e,i),s,r),t}_verifyReinsertion(t,e,i,r){let s=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null);return null!==s?t=this._reinsertAfter(s,t._prev,r):t.currentIndex!=r&&(t.currentIndex=r,this._addToMoves(t,r)),t}_truncate(t){for(;null!==t;){const e=t._next;this._addToRemovals(this._unlink(t)),t=e}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(t,e,i){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);const r=t._prevRemoved,s=t._nextRemoved;return null===r?this._removalsHead=s:r._nextRemoved=s,null===s?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(t,e,i),this._addToMoves(t,i),t}_moveAfter(t,e,i){return this._unlink(t),this._insertAfter(t,e,i),this._addToMoves(t,i),t}_addAfter(t,e,i){return this._insertAfter(t,e,i),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}_insertAfter(t,e,i){const r=null===e?this._itHead:e._next;return t._next=r,t._prev=e,null===r?this._itTail=t:r._prev=t,null===e?this._itHead=t:e._next=t,null===this._linkedRecords&&(this._linkedRecords=new jD),this._linkedRecords.put(t),t.currentIndex=i,t}_remove(t){return this._addToRemovals(this._unlink(t))}_unlink(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);const e=t._prev,i=t._next;return null===e?this._itHead=i:e._next=i,null===i?this._itTail=e:i._prev=e,t}_addToMoves(t,e){return t.previousIndex===e||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}_addToRemovals(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new jD),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}_addIdentityChange(t,e){return t.item=e,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}}class ZN{constructor(t,e){this.item=t,this.trackById=e,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class XN{constructor(){this._head=null,this._tail=null}add(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}get(t,e){let i;for(i=this._head;null!==i;i=i._nextDup)if((null===e||e<=i.currentIndex)&&Object.is(i.trackById,t))return i;return null}remove(t){const e=t._prevDup,i=t._nextDup;return null===e?this._head=i:e._nextDup=i,null===i?this._tail=e:i._prevDup=e,null===this._head}}class jD{constructor(){this.map=new Map}put(t){const e=t.trackById;let i=this.map.get(e);i||(i=new XN,this.map.set(e,i)),i.add(t)}get(t,e){const r=this.map.get(t);return r?r.get(t,e):null}remove(t){const e=t.trackById;return this.map.get(e).remove(t)&&this.map.delete(e),t}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function UD(n,t,e){const i=n.previousIndex;if(null===i)return i;let r=0;return e&&i{if(e&&e.key===r)this._maybeAddToChanges(e,i),this._appendAfter=e,e=e._next;else{const s=this._getOrCreateRecordForKey(r,i);e=this._insertBeforeOrAppend(e,s)}}),e){e._prev&&(e._prev._next=null),this._removalsHead=e;for(let i=e;null!==i;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(t,e){if(t){const i=t._prev;return e._next=t,e._prev=i,t._prev=e,i&&(i._next=e),t===this._mapHead&&(this._mapHead=e),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=e,e._prev=this._appendAfter):this._mapHead=e,this._appendAfter=e,null}_getOrCreateRecordForKey(t,e){if(this._records.has(t)){const r=this._records.get(t);this._maybeAddToChanges(r,e);const s=r._prev,o=r._next;return s&&(s._next=o),o&&(o._prev=s),r._next=null,r._prev=null,r}const i=new eB(t);return this._records.set(t,i),i.currentValue=e,this._addToAdditions(i),i}_reset(){if(this.isDirty){let t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(t,e){Object.is(e,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=e,this._addToChanges(t))}_addToAdditions(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}_addToChanges(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}_forEach(t,e){t instanceof Map?t.forEach(e):Object.keys(t).forEach(i=>e(t[i],i))}}class eB{constructor(t){this.key=t,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function $D(){return new es([new HD])}let es=(()=>{class n{constructor(e){this.factories=e}static create(e,i){if(null!=i){const r=i.factories.slice();e=e.concat(r)}return new n(e)}static extend(e){return{provide:n,useFactory:i=>n.create(e,i||$D()),deps:[[n,new ir,new Hn]]}}find(e){const i=this.factories.find(r=>r.supports(e));if(null!=i)return i;throw new Be(901,"")}}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:$D}),n})();function GD(){return new Nl([new zD])}let Nl=(()=>{class n{constructor(e){this.factories=e}static create(e,i){if(i){const r=i.factories.slice();e=e.concat(r)}return new n(e)}static extend(e){return{provide:n,useFactory:i=>n.create(e,i||GD()),deps:[[n,new ir,new Hn]]}}find(e){const i=this.factories.find(s=>s.supports(e));if(i)return i;throw new Be(901,"")}}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:GD}),n})();const iB=kD(null,"core",[]);let rB=(()=>{class n{constructor(e){}}return n.\u0275fac=function(e){return new(e||n)(te(Ll))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();function ts(n){return"boolean"==typeof n?n:null!=n&&"false"!==n}let qd=null;function Sr(){return qd}const ct=new De("DocumentToken");let Bl=(()=>{class n{historyGo(e){throw new Error("Not implemented")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(){return function lB(){return te(WD)}()},providedIn:"platform"}),n})();const cB=new De("Location Initialized");let WD=(()=>{class n extends Bl{constructor(e){super(),this._doc=e,this._init()}_init(){this.location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Sr().getBaseHref(this._doc)}onPopState(e){const i=Sr().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",e,!1),()=>i.removeEventListener("popstate",e)}onHashChange(e){const i=Sr().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",e,!1),()=>i.removeEventListener("hashchange",e)}get href(){return this.location.href}get protocol(){return this.location.protocol}get hostname(){return this.location.hostname}get port(){return this.location.port}get pathname(){return this.location.pathname}get search(){return this.location.search}get hash(){return this.location.hash}set pathname(e){this.location.pathname=e}pushState(e,i,r){qD()?this._history.pushState(e,i,r):this.location.hash=r}replaceState(e,i,r){qD()?this._history.replaceState(e,i,r):this.location.hash=r}forward(){this._history.forward()}back(){this._history.back()}historyGo(e=0){this._history.go(e)}getState(){return this._history.state}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(){return function dB(){return new WD(te(ct))}()},providedIn:"platform"}),n})();function qD(){return!!window.history.pushState}function zm(n,t){if(0==n.length)return t;if(0==t.length)return n;let e=0;return n.endsWith("/")&&e++,t.startsWith("/")&&e++,2==e?n+t.substring(1):1==e?n+t:n+"/"+t}function YD(n){const t=n.match(/#|\?|$/),e=t&&t.index||n.length;return n.slice(0,e-("/"===n[e-1]?1:0))+n.slice(e)}function ns(n){return n&&"?"!==n[0]?"?"+n:n}let ya=(()=>{class n{historyGo(e){throw new Error("Not implemented")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(){return function uB(){const n=te(ct).location;return new KD(te(Bl),n&&n.origin||"")}()},providedIn:"root"}),n})();const $m=new De("appBaseHref");let KD=(()=>{class n extends ya{constructor(e,i){if(super(),this._platformLocation=e,this._removeListenerFns=[],null==i&&(i=this._platformLocation.getBaseHrefFromDOM()),null==i)throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");this._baseHref=i}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return zm(this._baseHref,e)}path(e=!1){const i=this._platformLocation.pathname+ns(this._platformLocation.search),r=this._platformLocation.hash;return r&&e?`${i}${r}`:i}pushState(e,i,r,s){const o=this.prepareExternalUrl(r+ns(s));this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){const o=this.prepareExternalUrl(r+ns(s));this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){var i,r;null===(r=(i=this._platformLocation).historyGo)||void 0===r||r.call(i,e)}}return n.\u0275fac=function(e){return new(e||n)(te(Bl),te($m,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),hB=(()=>{class n extends ya{constructor(e,i){super(),this._platformLocation=e,this._baseHref="",this._removeListenerFns=[],null!=i&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}path(e=!1){let i=this._platformLocation.hash;return null==i&&(i="#"),i.length>0?i.substring(1):i}prepareExternalUrl(e){const i=zm(this._baseHref,e);return i.length>0?"#"+i:i}pushState(e,i,r,s){let o=this.prepareExternalUrl(r+ns(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){let o=this.prepareExternalUrl(r+ns(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){var i,r;null===(r=(i=this._platformLocation).historyGo)||void 0===r||r.call(i,e)}}return n.\u0275fac=function(e){return new(e||n)(te(Bl),te($m,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),Vl=(()=>{class n{constructor(e){this._subject=new je,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=e;const i=this._locationStrategy.getBaseHref();this._baseHref=YD(QD(i)),this._locationStrategy.onPopState(r=>{this._subject.emit({url:this.path(!0),pop:!0,state:r.state,type:r.type})})}ngOnDestroy(){var e;null===(e=this._urlChangeSubscription)||void 0===e||e.unsubscribe(),this._urlChangeListeners=[]}path(e=!1){return this.normalize(this._locationStrategy.path(e))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(e,i=""){return this.path()==this.normalize(e+ns(i))}normalize(e){return n.stripTrailingSlash(function pB(n,t){return n&&t.startsWith(n)?t.substring(n.length):t}(this._baseHref,QD(e)))}prepareExternalUrl(e){return e&&"/"!==e[0]&&(e="/"+e),this._locationStrategy.prepareExternalUrl(e)}go(e,i="",r=null){this._locationStrategy.pushState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+ns(i)),r)}replaceState(e,i="",r=null){this._locationStrategy.replaceState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+ns(i)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(e=0){var i,r;null===(r=(i=this._locationStrategy).historyGo)||void 0===r||r.call(i,e)}onUrlChange(e){return this._urlChangeListeners.push(e),this._urlChangeSubscription||(this._urlChangeSubscription=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)})),()=>{var i;const r=this._urlChangeListeners.indexOf(e);this._urlChangeListeners.splice(r,1),0===this._urlChangeListeners.length&&(null===(i=this._urlChangeSubscription)||void 0===i||i.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(e="",i){this._urlChangeListeners.forEach(r=>r(e,i))}subscribe(e,i,r){return this._subject.subscribe({next:e,error:i,complete:r})}}return n.normalizeQueryParams=ns,n.joinWithSlash=zm,n.stripTrailingSlash=YD,n.\u0275fac=function(e){return new(e||n)(te(ya))},n.\u0275prov=Ie({token:n,factory:function(){return function fB(){return new Vl(te(ya))}()},providedIn:"root"}),n})();function QD(n){return n.replace(/\/index.html$/,"")}var fi=(()=>((fi=fi||{})[fi.Decimal=0]="Decimal",fi[fi.Percent=1]="Percent",fi[fi.Currency=2]="Currency",fi[fi.Scientific=3]="Scientific",fi))(),st=(()=>((st=st||{})[st.Decimal=0]="Decimal",st[st.Group=1]="Group",st[st.List=2]="List",st[st.PercentSign=3]="PercentSign",st[st.PlusSign=4]="PlusSign",st[st.MinusSign=5]="MinusSign",st[st.Exponential=6]="Exponential",st[st.SuperscriptingExponent=7]="SuperscriptingExponent",st[st.PerMille=8]="PerMille",st[st.Infinity=9]="Infinity",st[st.NaN=10]="NaN",st[st.TimeSeparator=11]="TimeSeparator",st[st.CurrencyDecimal=12]="CurrencyDecimal",st[st.CurrencyGroup=13]="CurrencyGroup",st))();function ji(n,t){const e=si(n),i=e[He.NumberSymbols][t];if(void 0===i){if(t===st.CurrencyDecimal)return e[He.NumberSymbols][st.Decimal];if(t===st.CurrencyGroup)return e[He.NumberSymbols][st.Group]}return i}const HB=/^(\d+)?\.((\d+)(-(\d+))?)?$/;function Xm(n){const t=parseInt(n);if(isNaN(t))throw new Error("Invalid integer literal when parsing "+n);return t}function sE(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}let eg=(()=>{class n{constructor(e,i,r,s){this._iterableDiffers=e,this._keyValueDiffers=i,this._ngEl=r,this._renderer=s,this._iterableDiffer=null,this._keyValueDiffer=null,this._initialClasses=[],this._rawClass=null}set klass(e){this._removeClasses(this._initialClasses),this._initialClasses="string"==typeof e?e.split(/\s+/):[],this._applyClasses(this._initialClasses),this._applyClasses(this._rawClass)}set ngClass(e){this._removeClasses(this._rawClass),this._applyClasses(this._initialClasses),this._iterableDiffer=null,this._keyValueDiffer=null,this._rawClass="string"==typeof e?e.split(/\s+/):e,this._rawClass&&(bl(this._rawClass)?this._iterableDiffer=this._iterableDiffers.find(this._rawClass).create():this._keyValueDiffer=this._keyValueDiffers.find(this._rawClass).create())}ngDoCheck(){if(this._iterableDiffer){const e=this._iterableDiffer.diff(this._rawClass);e&&this._applyIterableChanges(e)}else if(this._keyValueDiffer){const e=this._keyValueDiffer.diff(this._rawClass);e&&this._applyKeyValueChanges(e)}}_applyKeyValueChanges(e){e.forEachAddedItem(i=>this._toggleClass(i.key,i.currentValue)),e.forEachChangedItem(i=>this._toggleClass(i.key,i.currentValue)),e.forEachRemovedItem(i=>{i.previousValue&&this._toggleClass(i.key,!1)})}_applyIterableChanges(e){e.forEachAddedItem(i=>{if("string"!=typeof i.item)throw new Error(`NgClass can only toggle CSS classes expressed as strings, got ${Kt(i.item)}`);this._toggleClass(i.item,!0)}),e.forEachRemovedItem(i=>this._toggleClass(i.item,!1))}_applyClasses(e){e&&(Array.isArray(e)||e instanceof Set?e.forEach(i=>this._toggleClass(i,!0)):Object.keys(e).forEach(i=>this._toggleClass(i,!!e[i])))}_removeClasses(e){e&&(Array.isArray(e)||e instanceof Set?e.forEach(i=>this._toggleClass(i,!1)):Object.keys(e).forEach(i=>this._toggleClass(i,!1)))}_toggleClass(e,i){(e=e.trim())&&e.split(/\s+/g).forEach(r=>{i?this._renderer.addClass(this._ngEl.nativeElement,r):this._renderer.removeClass(this._ngEl.nativeElement,r)})}}return n.\u0275fac=function(e){return new(e||n)(x(es),x(Nl),x(Je),x(Xr))},n.\u0275dir=Me({type:n,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"}}),n})();class XB{constructor(t,e,i,r){this.$implicit=t,this.ngForOf=e,this.index=i,this.count=r}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let ao=(()=>{class n{constructor(e,i,r){this._viewContainer=e,this._template=i,this._differs=r,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForOf(e){this._ngForOf=e,this._ngForOfDirty=!0}set ngForTrackBy(e){this._trackByFn=e}get ngForTrackBy(){return this._trackByFn}set ngForTemplate(e){e&&(this._template=e)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const e=this._ngForOf;!this._differ&&e&&(this._differ=this._differs.find(e).create(this.ngForTrackBy))}if(this._differ){const e=this._differ.diff(this._ngForOf);e&&this._applyChanges(e)}}_applyChanges(e){const i=this._viewContainer;e.forEachOperation((r,s,o)=>{if(null==r.previousIndex)i.createEmbeddedView(this._template,new XB(r.item,this._ngForOf,-1,-1),null===o?void 0:o);else if(null==o)i.remove(null===s?void 0:s);else if(null!==s){const a=i.get(s);i.move(a,o),aE(a,r)}});for(let r=0,s=i.length;r{aE(i.get(r.currentIndex),r)})}static ngTemplateContextGuard(e,i){return!0}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(es))},n.\u0275dir=Me({type:n,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}}),n})();function aE(n,t){n.context.$implicit=t.item}let zi=(()=>{class n{constructor(e,i){this._viewContainer=e,this._context=new JB,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=i}set ngIf(e){this._context.$implicit=this._context.ngIf=e,this._updateView()}set ngIfThen(e){lE("ngIfThen",e),this._thenTemplateRef=e,this._thenViewRef=null,this._updateView()}set ngIfElse(e){lE("ngIfElse",e),this._elseTemplateRef=e,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngTemplateContextGuard(e,i){return!0}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n))},n.\u0275dir=Me({type:n,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}}),n})();class JB{constructor(){this.$implicit=null,this.ngIf=null}}function lE(n,t){if(t&&!t.createEmbeddedView)throw new Error(`${n} must be a TemplateRef, but received '${Kt(t)}'.`)}class tg{constructor(t,e){this._viewContainerRef=t,this._templateRef=e,this._created=!1}create(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}destroy(){this._created=!1,this._viewContainerRef.clear()}enforceState(t){t&&!this._created?this.create():!t&&this._created&&this.destroy()}}let ba=(()=>{class n{constructor(){this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}set ngSwitch(e){this._ngSwitch=e,0===this._caseCount&&this._updateDefaultCases(!0)}_addCase(){return this._caseCount++}_addDefault(e){this._defaultViews||(this._defaultViews=[]),this._defaultViews.push(e)}_matchCase(e){const i=e==this._ngSwitch;return this._lastCasesMatched=this._lastCasesMatched||i,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),i}_updateDefaultCases(e){if(this._defaultViews&&e!==this._defaultUsed){this._defaultUsed=e;for(let i=0;i{class n{constructor(e,i,r){this.ngSwitch=r,r._addCase(),this._view=new tg(e,i)}ngDoCheck(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(ba,9))},n.\u0275dir=Me({type:n,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"}}),n})(),cE=(()=>{class n{constructor(e,i,r){r._addDefault(new tg(e,i))}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(ba,9))},n.\u0275dir=Me({type:n,selectors:[["","ngSwitchDefault",""]]}),n})();function dr(n,t){return new Be(2100,"")}let hE=(()=>{class n{transform(e){if(null==e)return null;if("string"!=typeof e)throw dr();return e.toUpperCase()}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275pipe=ui({name:"uppercase",type:n,pure:!0}),n})(),ru=(()=>{class n{transform(e){return JSON.stringify(e,null,2)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275pipe=ui({name:"json",type:n,pure:!1}),n})(),fE=(()=>{class n{constructor(e){this.differs=e,this.keyValues=[],this.compareFn=pE}transform(e,i=pE){if(!e||!(e instanceof Map)&&"object"!=typeof e)return null;this.differ||(this.differ=this.differs.find(e).create());const r=this.differ.diff(e),s=i!==this.compareFn;return r&&(this.keyValues=[],r.forEachItem(o=>{this.keyValues.push(function mV(n,t){return{key:n,value:t}}(o.key,o.currentValue))})),(r||s)&&(this.keyValues.sort(i),this.compareFn=i),this.keyValues}}return n.\u0275fac=function(e){return new(e||n)(x(Nl,16))},n.\u0275pipe=ui({name:"keyvalue",type:n,pure:!1}),n})();function pE(n,t){const e=n.key,i=t.key;if(e===i)return 0;if(void 0===e)return 1;if(void 0===i)return-1;if(null===e)return 1;if(null===i)return-1;if("string"==typeof e&&"string"==typeof i)return e{class n{constructor(e){this._locale=e}transform(e,i,r){if(!function ig(n){return!(null==n||""===n||n!=n)}(e))return null;r=r||this._locale;try{return function WB(n,t,e){return function Qm(n,t,e,i,r,s,o=!1){let a="",l=!1;if(isFinite(n)){let c=function YB(n){let i,r,s,o,a,t=Math.abs(n)+"",e=0;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(s=t.search(/e/i))>0?(r<0&&(r=s),r+=+t.slice(s+1),t=t.substring(0,s)):r<0&&(r=t.length),s=0;"0"===t.charAt(s);s++);if(s===(a=t.length))i=[0],r=1;else{for(a--;"0"===t.charAt(a);)a--;for(r-=s,i=[],o=0;s<=a;s++,o++)i[o]=Number(t.charAt(s))}return r>22&&(i=i.splice(0,21),e=r-1,r=1),{digits:i,exponent:e,integerLen:r}}(n);o&&(c=function qB(n){if(0===n.digits[0])return n;const t=n.digits.length-n.integerLen;return n.exponent?n.exponent+=2:(0===t?n.digits.push(0,0):1===t&&n.digits.push(0),n.integerLen+=2),n}(c));let d=t.minInt,f=t.minFrac,w=t.maxFrac;if(s){const Te=s.match(HB);if(null===Te)throw new Error(`${s} is not a valid digit info`);const he=Te[1],Oe=Te[3],ft=Te[5];null!=he&&(d=Xm(he)),null!=Oe&&(f=Xm(Oe)),null!=ft?w=Xm(ft):null!=Oe&&f>w&&(w=f)}!function KB(n,t,e){if(t>e)throw new Error(`The minimum number of digits after fraction (${t}) is higher than the maximum (${e}).`);let i=n.digits,r=i.length-n.integerLen;const s=Math.min(Math.max(t,r),e);let o=s+n.integerLen,a=i[o];if(o>0){i.splice(Math.max(n.integerLen,o));for(let f=o;f=5)if(o-1<0){for(let f=0;f>o;f--)i.unshift(0),n.integerLen++;i.unshift(1),n.integerLen++}else i[o-1]++;for(;r=c?j.pop():l=!1),w>=10?1:0},0);d&&(i.unshift(d),n.integerLen++)}(c,f,w);let k=c.digits,j=c.integerLen;const K=c.exponent;let ae=[];for(l=k.every(Te=>!Te);j0?ae=k.splice(j,k.length):(ae=k,k=[0]);const ce=[];for(k.length>=t.lgSize&&ce.unshift(k.splice(-t.lgSize,k.length).join(""));k.length>t.gSize;)ce.unshift(k.splice(-t.gSize,k.length).join(""));k.length&&ce.unshift(k.join("")),a=ce.join(ji(e,i)),ae.length&&(a+=ji(e,r)+ae.join("")),K&&(a+=ji(e,st.Exponential)+"+"+K)}else a=ji(e,st.Infinity);return a=n<0&&!l?t.negPre+a+t.negSuf:t.posPre+a+t.posSuf,a}(n,function Zm(n,t="-"){const e={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},i=n.split(";"),r=i[0],s=i[1],o=-1!==r.indexOf(".")?r.split("."):[r.substring(0,r.lastIndexOf("0")+1),r.substring(r.lastIndexOf("0")+1)],a=o[0],l=o[1]||"";e.posPre=a.substring(0,a.indexOf("#"));for(let d=0;d{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const mE="browser";let DV=(()=>{class n{}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:()=>new EV(te(ct),window)}),n})();class EV{constructor(t,e){this.document=t,this.window=e,this.offset=()=>[0,0]}setOffset(t){this.offset=Array.isArray(t)?()=>t:t}getScrollPosition(){return this.supportsScrolling()?[this.window.pageXOffset,this.window.pageYOffset]:[0,0]}scrollToPosition(t){this.supportsScrolling()&&this.window.scrollTo(t[0],t[1])}scrollToAnchor(t){if(!this.supportsScrolling())return;const e=function MV(n,t){const e=n.getElementById(t)||n.getElementsByName(t)[0];if(e)return e;if("function"==typeof n.createTreeWalker&&n.body&&(n.body.createShadowRoot||n.body.attachShadow)){const i=n.createTreeWalker(n.body,NodeFilter.SHOW_ELEMENT);let r=i.currentNode;for(;r;){const s=r.shadowRoot;if(s){const o=s.getElementById(t)||s.querySelector(`[name="${t}"]`);if(o)return o}r=i.nextNode()}}return null}(this.document,t);e&&(this.scrollToElement(e),e.focus())}setHistoryScrollRestoration(t){if(this.supportScrollRestoration()){const e=this.window.history;e&&e.scrollRestoration&&(e.scrollRestoration=t)}}scrollToElement(t){const e=t.getBoundingClientRect(),i=e.left+this.window.pageXOffset,r=e.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(i-s[0],r-s[1])}supportScrollRestoration(){try{if(!this.supportsScrolling())return!1;const t=gE(this.window.history)||gE(Object.getPrototypeOf(this.window.history));return!(!t||!t.writable&&!t.set)}catch(t){return!1}}supportsScrolling(){try{return!!this.window&&!!this.window.scrollTo&&"pageXOffset"in this.window}catch(t){return!1}}}function gE(n){return Object.getOwnPropertyDescriptor(n,"scrollRestoration")}class _E{}class sg extends class xV extends class aB{}{constructor(){super(...arguments),this.supportsDOMEvents=!0}}{static makeCurrent(){!function oB(n){qd||(qd=n)}(new sg)}onAndCancel(t,e,i){return t.addEventListener(e,i,!1),()=>{t.removeEventListener(e,i,!1)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function SV(){return Ul=Ul||document.querySelector("base"),Ul?Ul.getAttribute("href"):null}();return null==e?null:function kV(n){su=su||document.createElement("a"),su.setAttribute("href",n);const t=su.pathname;return"/"===t.charAt(0)?t:`/${t}`}(e)}resetBaseElement(){Ul=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return sE(document.cookie,t)}}let su,Ul=null;const vE=new De("TRANSITION_ID"),AV=[{provide:Am,useFactory:function TV(n,t,e){return()=>{e.get(jd).donePromise.then(()=>{const i=Sr(),r=t.querySelectorAll(`style[ng-transition="${n}"]`);for(let s=0;s{class n{build(){return new XMLHttpRequest}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const ou=new De("EventManagerPlugins");let au=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>r.manager=this),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}addGlobalEventListener(e,i,r){return this._findPluginFor(i).addGlobalEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){const i=this._eventNameToPlugin.get(e);if(i)return i;const r=this._plugins;for(let s=0;s{class n{constructor(){this._stylesSet=new Set}addStyles(e){const i=new Set;e.forEach(r=>{this._stylesSet.has(r)||(this._stylesSet.add(r),i.add(r))}),this.onStylesAdded(i)}onStylesAdded(e){}getAllStyles(){return Array.from(this._stylesSet)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),zl=(()=>{class n extends bE{constructor(e){super(),this._doc=e,this._hostNodes=new Map,this._hostNodes.set(e.head,[])}_addStylesToHost(e,i,r){e.forEach(s=>{const o=this._doc.createElement("style");o.textContent=s,r.push(i.appendChild(o))})}addHost(e){const i=[];this._addStylesToHost(this._stylesSet,e,i),this._hostNodes.set(e,i)}removeHost(e){const i=this._hostNodes.get(e);i&&i.forEach(wE),this._hostNodes.delete(e)}onStylesAdded(e){this._hostNodes.forEach((i,r)=>{this._addStylesToHost(e,r,i)})}ngOnDestroy(){this._hostNodes.forEach(e=>e.forEach(wE))}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function wE(n){Sr().remove(n)}const og={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},ag=/%COMP%/g;function lu(n,t,e){for(let i=0;i{if("__ngUnwrap__"===t)return n;!1===n(t)&&(t.preventDefault(),t.returnValue=!1)}}let cu=(()=>{class n{constructor(e,i,r){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.rendererByCompId=new Map,this.defaultRenderer=new lg(e)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;switch(i.encapsulation){case Ji.Emulated:{let r=this.rendererByCompId.get(i.id);return r||(r=new BV(this.eventManager,this.sharedStylesHost,i,this.appId),this.rendererByCompId.set(i.id,r)),r.applyToHost(e),r}case 1:case Ji.ShadowDom:return new VV(this.eventManager,this.sharedStylesHost,e,i);default:if(!this.rendererByCompId.has(i.id)){const r=lu(i.id,i.styles,[]);this.sharedStylesHost.addStyles(r),this.rendererByCompId.set(i.id,this.defaultRenderer)}return this.defaultRenderer}}begin(){}end(){}}return n.\u0275fac=function(e){return new(e||n)(te(au),te(zl),te(Ol))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class lg{constructor(t){this.eventManager=t,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(t,e){return e?document.createElementNS(og[e]||e,t):document.createElement(t)}createComment(t){return document.createComment(t)}createText(t){return document.createTextNode(t)}appendChild(t,e){(xE(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(xE(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?document.querySelector(t):t;if(!i)throw new Error(`The selector "${t}" did not match any elements`);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=og[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=og[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(xi.DashCase|xi.Important)?t.style.setProperty(e,i,r&xi.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&xi.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){t[e]=i}setValue(t,e){t.nodeValue=e}listen(t,e,i){return"string"==typeof t?this.eventManager.addGlobalEventListener(t,e,EE(i)):this.eventManager.addEventListener(t,e,EE(i))}}function xE(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class BV extends lg{constructor(t,e,i,r){super(t),this.component=i;const s=lu(r+"-"+i.id,i.styles,[]);e.addStyles(s),this.contentAttr=function FV(n){return"_ngcontent-%COMP%".replace(ag,n)}(r+"-"+i.id),this.hostAttr=function LV(n){return"_nghost-%COMP%".replace(ag,n)}(r+"-"+i.id)}applyToHost(t){super.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}class VV extends lg{constructor(t,e,i,r){super(t),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const s=lu(r.id,r.styles,[]);for(let o=0;o{class n extends yE{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const SE=["alt","control","meta","shift"],UV={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},kE={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},zV={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let $V=(()=>{class n extends yE{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Sr().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="";if(SE.forEach(l=>{const c=i.indexOf(l);c>-1&&(i.splice(c,1),o+=l+".")}),o+=s,0!=i.length||0===s.length)return null;const a={};return a.domEventName=r,a.fullKey=o,a}static getEventFullKey(e){let i="",r=function GV(n){let t=n.key;if(null==t){if(t=n.keyIdentifier,null==t)return"Unidentified";t.startsWith("U+")&&(t=String.fromCharCode(parseInt(t.substring(2),16)),3===n.location&&kE.hasOwnProperty(t)&&(t=kE[t]))}return UV[t]||t}(e);return r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),SE.forEach(s=>{s!=r&&zV[s](e)&&(i+=s+".")}),i+=r,i}static eventCallback(e,i,r){return s=>{n.getEventFullKey(s)===e&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const KV=kD(iB,"browser",[{provide:Ud,useValue:mE},{provide:yD,useValue:function WV(){sg.makeCurrent()},multi:!0},{provide:ct,useFactory:function YV(){return function cI(n){bf=n}(document),document},deps:[]}]),AE=new De(""),IE=[{provide:zd,useClass:class IV{addToWindow(t){qt.getAngularTestability=(i,r=!0)=>{const s=t.findTestabilityInTree(i,r);if(null==s)throw new Error("Could not find testability for element.");return s},qt.getAllAngularTestabilities=()=>t.getAllTestabilities(),qt.getAllAngularRootElements=()=>t.getAllRootElements(),qt.frameworkStabilizers||(qt.frameworkStabilizers=[]),qt.frameworkStabilizers.push(i=>{const r=qt.getAllAngularTestabilities();let s=r.length,o=!1;const a=function(l){o=o||l,s--,0==s&&i(o)};r.forEach(function(l){l.whenStable(a)})})}findTestabilityInTree(t,e,i){if(null==e)return null;const r=t.getTestability(e);return null!=r?r:i?Sr().isShadowRoot(e)?this.findTestabilityInTree(t,e.host,!0):this.findTestabilityInTree(t,e.parentElement,!0):null}},deps:[]},{provide:DD,useClass:Lm,deps:[et,Nm,zd]},{provide:Lm,useClass:Lm,deps:[et,Nm,zd]}],RE=[{provide:_p,useValue:"root"},{provide:qr,useFactory:function qV(){return new qr},deps:[]},{provide:ou,useClass:HV,multi:!0,deps:[ct,et,Ud]},{provide:ou,useClass:$V,multi:!0,deps:[ct]},{provide:cu,useClass:cu,deps:[au,zl,Ol]},{provide:Tl,useExisting:cu},{provide:bE,useExisting:zl},{provide:zl,useClass:zl,deps:[ct]},{provide:au,useClass:au,deps:[ou,et]},{provide:_E,useClass:RV,deps:[]},[]];let PE=(()=>{class n{constructor(e){}static withServerTransition(e){return{ngModule:n,providers:[{provide:Ol,useValue:e.appId},{provide:vE,useExisting:Ol},AV]}}}return n.\u0275fac=function(e){return new(e||n)(te(AE,12))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[...RE,...IE],imports:[pi,rB]}),n})(),OE=(()=>{class n{constructor(e){this._doc=e}getTitle(){return this._doc.title}setTitle(e){this._doc.title=e||""}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new e:function ZV(){return new OE(te(ct))}(),i},providedIn:"root"}),n})();"undefined"!=typeof window&&window;let ug=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new(e||n):te(NE),i},providedIn:"root"}),n})(),NE=(()=>{class n extends ug{constructor(e){super(),this._doc=e}sanitize(e,i){if(null==i)return null;switch(e){case Ut.NONE:return i;case Ut.HTML:return _r(i,"HTML")?Mi(i):Db(this._doc,String(i)).toString();case Ut.STYLE:return _r(i,"Style")?Mi(i):i;case Ut.SCRIPT:if(_r(i,"Script"))return Mi(i);throw new Error("unsafe value used in a script context");case Ut.URL:return mb(i),_r(i,"URL")?Mi(i):hl(String(i));case Ut.RESOURCE_URL:if(_r(i,"ResourceURL"))return Mi(i);throw new Error("unsafe value used in a resource URL context (see https://g.co/ng/security#xss)");default:throw new Error(`Unexpected SecurityContext ${e} (see https://g.co/ng/security#xss)`)}}bypassSecurityTrustHtml(e){return function DR(n){return new vR(n)}(e)}bypassSecurityTrustStyle(e){return function ER(n){return new yR(n)}(e)}bypassSecurityTrustScript(e){return function MR(n){return new bR(n)}(e)}bypassSecurityTrustUrl(e){return function xR(n){return new wR(n)}(e)}bypassSecurityTrustResourceUrl(e){return function SR(n){return new CR(n)}(e)}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new e:function o2(n){return new NE(n.get(ct))}(te(Jt)),i},providedIn:"root"}),n})();class BE{}const rs="*";function jn(n,t){return{type:7,name:n,definitions:t,options:{}}}function Zt(n,t=null){return{type:4,styles:t,timings:n}}function VE(n,t=null){return{type:3,steps:n,options:t}}function HE(n,t=null){return{type:2,steps:n,options:t}}function Qe(n){return{type:6,styles:n,offset:null}}function zt(n,t,e){return{type:0,name:n,styles:t,options:e}}function Wt(n,t,e=null){return{type:1,expr:n,animation:t,options:e}}function du(n=null){return{type:9,options:n}}function uu(n,t,e=null){return{type:11,selector:n,animation:t,options:e}}function jE(n){Promise.resolve(null).then(n)}class $l{constructor(t=0,e=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=t+e}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}onStart(t){this._onStartFns.push(t)}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){jE(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(t=>t()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}reset(){this._started=!1}setPosition(t){this._position=this.totalTime?t*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(t){const e="start"==t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}class UE{constructor(t){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=t;let e=0,i=0,r=0;const s=this.players.length;0==s?jE(()=>this._onFinish()):this.players.forEach(o=>{o.onDone(()=>{++e==s&&this._onFinish()}),o.onDestroy(()=>{++i==s&&this._onDestroy()}),o.onStart(()=>{++r==s&&this._onStart()})}),this.totalTime=this.players.reduce((o,a)=>Math.max(o,a.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}init(){this.players.forEach(t=>t.init())}onStart(t){this._onStartFns.push(t)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(t=>t()),this._onStartFns=[])}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(t=>t.play())}pause(){this.players.forEach(t=>t.pause())}restart(){this.players.forEach(t=>t.restart())}finish(){this._onFinish(),this.players.forEach(t=>t.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(t=>t.destroy()),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}reset(){this.players.forEach(t=>t.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(t){const e=t*this.totalTime;this.players.forEach(i=>{const r=i.totalTime?Math.min(1,e/i.totalTime):1;i.setPosition(r)})}getPosition(){const t=this.players.reduce((e,i)=>null===e||i.totalTime>e.totalTime?i:e,null);return null!=t?t.getPosition():0}beforeDestroy(){this.players.forEach(t=>{t.beforeDestroy&&t.beforeDestroy()})}triggerCallback(t){const e="start"==t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}const Rt=!1;function zE(n){return new Be(3e3,Rt)}function U2(){return"undefined"!=typeof window&&void 0!==window.document}function fg(){return"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)}function Ms(n){switch(n.length){case 0:return new $l;case 1:return n[0];default:return new UE(n)}}function $E(n,t,e,i,r=new Map,s=new Map){const o=[],a=[];let l=-1,c=null;if(i.forEach(d=>{const f=d.get("offset"),w=f==l,k=w&&c||new Map;d.forEach((j,K)=>{let ae=K,ce=j;if("offset"!==K)switch(ae=t.normalizePropertyName(ae,o),ce){case"!":ce=r.get(K);break;case rs:ce=s.get(K);break;default:ce=t.normalizeStyleValue(K,ae,ce,o)}k.set(ae,ce)}),w||a.push(k),c=k,l=f}),o.length)throw function A2(n){return new Be(3502,Rt)}();return a}function pg(n,t,e,i){switch(t){case"start":n.onStart(()=>i(e&&mg(e,"start",n)));break;case"done":n.onDone(()=>i(e&&mg(e,"done",n)));break;case"destroy":n.onDestroy(()=>i(e&&mg(e,"destroy",n)))}}function mg(n,t,e){const i=e.totalTime,s=gg(n.element,n.triggerName,n.fromState,n.toState,t||n.phaseName,null==i?n.totalTime:i,!!e.disabled),o=n._data;return null!=o&&(s._data=o),s}function gg(n,t,e,i,r="",s=0,o){return{element:n,triggerName:t,fromState:e,toState:i,phaseName:r,totalTime:s,disabled:!!o}}function Ti(n,t,e){let i=n.get(t);return i||n.set(t,i=e),i}function GE(n){const t=n.indexOf(":");return[n.substring(1,t),n.slice(t+1)]}let _g=(n,t)=>!1,WE=(n,t,e)=>[],qE=null;function vg(n){const t=n.parentNode||n.host;return t===qE?null:t}(fg()||"undefined"!=typeof Element)&&(U2()?(qE=(()=>document.documentElement)(),_g=(n,t)=>{for(;t;){if(t===n)return!0;t=vg(t)}return!1}):_g=(n,t)=>n.contains(t),WE=(n,t,e)=>{if(e)return Array.from(n.querySelectorAll(t));const i=n.querySelector(t);return i?[i]:[]});let co=null,YE=!1;const KE=_g,QE=WE;let ZE=(()=>{class n{validateStyleProperty(e){return function $2(n){co||(co=function G2(){return"undefined"!=typeof document?document.body:null}()||{},YE=!!co.style&&"WebkitAppearance"in co.style);let t=!0;return co.style&&!function z2(n){return"ebkit"==n.substring(1,6)}(n)&&(t=n in co.style,!t&&YE&&(t="Webkit"+n.charAt(0).toUpperCase()+n.slice(1)in co.style)),t}(e)}matchesElement(e,i){return!1}containsElement(e,i){return KE(e,i)}getParentElement(e){return vg(e)}query(e,i,r){return QE(e,i,r)}computeStyle(e,i,r){return r||""}animate(e,i,r,s,o,a=[],l){return new $l(r,s)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),yg=(()=>{class n{}return n.NOOP=new ZE,n})();const bg="ng-enter",fu="ng-leave",pu="ng-trigger",mu=".ng-trigger",JE="ng-animating",wg=".ng-animating";function xs(n){if("number"==typeof n)return n;const t=n.match(/^(-?[\.\d]+)(m?s)/);return!t||t.length<2?0:Cg(parseFloat(t[1]),t[2])}function Cg(n,t){return"s"===t?1e3*n:n}function gu(n,t,e){return n.hasOwnProperty("duration")?n:function Y2(n,t,e){let r,s=0,o="";if("string"==typeof n){const a=n.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return t.push(zE()),{duration:0,delay:0,easing:""};r=Cg(parseFloat(a[1]),a[2]);const l=a[3];null!=l&&(s=Cg(parseFloat(l),a[4]));const c=a[5];c&&(o=c)}else r=n;if(!e){let a=!1,l=t.length;r<0&&(t.push(function l2(){return new Be(3100,Rt)}()),a=!0),s<0&&(t.push(function c2(){return new Be(3101,Rt)}()),a=!0),a&&t.splice(l,0,zE())}return{duration:r,delay:s,easing:o}}(n,t,e)}function Gl(n,t={}){return Object.keys(n).forEach(e=>{t[e]=n[e]}),t}function eM(n){const t=new Map;return Object.keys(n).forEach(e=>{t.set(e,n[e])}),t}function Ss(n,t=new Map,e){if(e)for(let[i,r]of e)t.set(i,r);for(let[i,r]of n)t.set(i,r);return t}function nM(n,t,e){return e?t+":"+e+";":""}function iM(n){let t="";for(let e=0;e{const s=Eg(r);e&&!e.has(r)&&e.set(r,n.style[s]),n.style[s]=i}),fg()&&iM(n))}function uo(n,t){n.style&&(t.forEach((e,i)=>{const r=Eg(i);n.style[r]=""}),fg()&&iM(n))}function Wl(n){return Array.isArray(n)?1==n.length?n[0]:HE(n):n}const Dg=new RegExp("{{\\s*(.+?)\\s*}}","g");function rM(n){let t=[];if("string"==typeof n){let e;for(;e=Dg.exec(n);)t.push(e[1]);Dg.lastIndex=0}return t}function _u(n,t,e){const i=n.toString(),r=i.replace(Dg,(s,o)=>{let a=t[o];return null==a&&(e.push(function u2(n){return new Be(3003,Rt)}()),a=""),a.toString()});return r==i?n:r}function vu(n){const t=[];let e=n.next();for(;!e.done;)t.push(e.value),e=n.next();return t}const Z2=/-+([a-z0-9])/g;function Eg(n){return n.replace(Z2,(...t)=>t[1].toUpperCase())}function X2(n){return n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function Ai(n,t,e){switch(t.type){case 7:return n.visitTrigger(t,e);case 0:return n.visitState(t,e);case 1:return n.visitTransition(t,e);case 2:return n.visitSequence(t,e);case 3:return n.visitGroup(t,e);case 4:return n.visitAnimate(t,e);case 5:return n.visitKeyframes(t,e);case 6:return n.visitStyle(t,e);case 8:return n.visitReference(t,e);case 9:return n.visitAnimateChild(t,e);case 10:return n.visitAnimateRef(t,e);case 11:return n.visitQuery(t,e);case 12:return n.visitStagger(t,e);default:throw function h2(n){return new Be(3004,Rt)}()}}function sM(n,t){return window.getComputedStyle(n)[t]}function rH(n,t){const e=[];return"string"==typeof n?n.split(/\s*,\s*/).forEach(i=>function sH(n,t,e){if(":"==n[0]){const l=function oH(n,t){switch(n){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(e,i)=>parseFloat(i)>parseFloat(e);case":decrement":return(e,i)=>parseFloat(i) *"}}(n,e);if("function"==typeof l)return void t.push(l);n=l}const i=n.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==i||i.length<4)return e.push(function M2(n){return new Be(3015,Rt)}()),t;const r=i[1],s=i[2],o=i[3];t.push(oM(r,o));"<"==s[0]&&!("*"==r&&"*"==o)&&t.push(oM(o,r))}(i,e,t)):e.push(n),e}const Cu=new Set(["true","1"]),Du=new Set(["false","0"]);function oM(n,t){const e=Cu.has(n)||Du.has(n),i=Cu.has(t)||Du.has(t);return(r,s)=>{let o="*"==n||n==r,a="*"==t||t==s;return!o&&e&&"boolean"==typeof r&&(o=r?Cu.has(n):Du.has(n)),!a&&i&&"boolean"==typeof s&&(a=s?Cu.has(t):Du.has(t)),o&&a}}const aH=new RegExp("s*:selfs*,?","g");function Mg(n,t,e,i){return new lH(n).build(t,e,i)}class lH{constructor(t){this._driver=t}build(t,e,i){const r=new uH(e);return this._resetContextStyleTimingState(r),Ai(this,Wl(t),r)}_resetContextStyleTimingState(t){t.currentQuerySelector="",t.collectedStyles=new Map,t.collectedStyles.set("",new Map),t.currentTime=0}visitTrigger(t,e){let i=e.queryCount=0,r=e.depCount=0;const s=[],o=[];return"@"==t.name.charAt(0)&&e.errors.push(function p2(){return new Be(3006,Rt)}()),t.definitions.forEach(a=>{if(this._resetContextStyleTimingState(e),0==a.type){const l=a,c=l.name;c.toString().split(/\s*,\s*/).forEach(d=>{l.name=d,s.push(this.visitState(l,e))}),l.name=c}else if(1==a.type){const l=this.visitTransition(a,e);i+=l.queryCount,r+=l.depCount,o.push(l)}else e.errors.push(function m2(){return new Be(3007,Rt)}())}),{type:7,name:t.name,states:s,transitions:o,queryCount:i,depCount:r,options:null}}visitState(t,e){const i=this.visitStyle(t.styles,e),r=t.options&&t.options.params||null;if(i.containsDynamicStyles){const s=new Set,o=r||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(l=>{rM(l).forEach(c=>{o.hasOwnProperty(c)||s.add(c)})})}),s.size&&(vu(s.values()),e.errors.push(function g2(n,t){return new Be(3008,Rt)}()))}return{type:0,name:t.name,style:i,options:r?{params:r}:null}}visitTransition(t,e){e.queryCount=0,e.depCount=0;const i=Ai(this,Wl(t.animation),e);return{type:1,matchers:rH(t.expr,e.errors),animation:i,queryCount:e.queryCount,depCount:e.depCount,options:ho(t.options)}}visitSequence(t,e){return{type:2,steps:t.steps.map(i=>Ai(this,i,e)),options:ho(t.options)}}visitGroup(t,e){const i=e.currentTime;let r=0;const s=t.steps.map(o=>{e.currentTime=i;const a=Ai(this,o,e);return r=Math.max(r,e.currentTime),a});return e.currentTime=r,{type:3,steps:s,options:ho(t.options)}}visitAnimate(t,e){const i=function fH(n,t){if(n.hasOwnProperty("duration"))return n;if("number"==typeof n)return xg(gu(n,t).duration,0,"");const e=n;if(e.split(/\s+/).some(s=>"{"==s.charAt(0)&&"{"==s.charAt(1))){const s=xg(0,0,"");return s.dynamic=!0,s.strValue=e,s}const r=gu(e,t);return xg(r.duration,r.delay,r.easing)}(t.timings,e.errors);e.currentAnimateTimings=i;let r,s=t.styles?t.styles:Qe({});if(5==s.type)r=this.visitKeyframes(s,e);else{let o=t.styles,a=!1;if(!o){a=!0;const c={};i.easing&&(c.easing=i.easing),o=Qe(c)}e.currentTime+=i.duration+i.delay;const l=this.visitStyle(o,e);l.isEmptyStep=a,r=l}return e.currentAnimateTimings=null,{type:4,timings:i,style:r,options:null}}visitStyle(t,e){const i=this._makeStyleAst(t,e);return this._validateStyleAst(i,e),i}_makeStyleAst(t,e){const i=[],r=Array.isArray(t.styles)?t.styles:[t.styles];for(let a of r)"string"==typeof a?a===rs?i.push(a):e.errors.push(new Be(3002,Rt)):i.push(eM(a));let s=!1,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!s))for(let l of a.values())if(l.toString().indexOf("{{")>=0){s=!0;break}}),{type:6,styles:i,easing:o,offset:t.offset,containsDynamicStyles:s,options:null}}_validateStyleAst(t,e){const i=e.currentAnimateTimings;let r=e.currentTime,s=e.currentTime;i&&s>0&&(s-=i.duration+i.delay),t.styles.forEach(o=>{"string"!=typeof o&&o.forEach((a,l)=>{const c=e.collectedStyles.get(e.currentQuerySelector),d=c.get(l);let f=!0;d&&(s!=r&&s>=d.startTime&&r<=d.endTime&&(e.errors.push(function v2(n,t,e,i,r){return new Be(3010,Rt)}()),f=!1),s=d.startTime),f&&c.set(l,{startTime:s,endTime:r}),e.options&&function Q2(n,t,e){const i=t.params||{},r=rM(n);r.length&&r.forEach(s=>{i.hasOwnProperty(s)||e.push(function d2(n){return new Be(3001,Rt)}())})}(a,e.options,e.errors)})})}visitKeyframes(t,e){const i={type:5,styles:[],options:null};if(!e.currentAnimateTimings)return e.errors.push(function y2(){return new Be(3011,Rt)}()),i;let s=0;const o=[];let a=!1,l=!1,c=0;const d=t.steps.map(ce=>{const Te=this._makeStyleAst(ce,e);let he=null!=Te.offset?Te.offset:function hH(n){if("string"==typeof n)return null;let t=null;if(Array.isArray(n))n.forEach(e=>{if(e instanceof Map&&e.has("offset")){const i=e;t=parseFloat(i.get("offset")),i.delete("offset")}});else if(n instanceof Map&&n.has("offset")){const e=n;t=parseFloat(e.get("offset")),e.delete("offset")}return t}(Te.styles),Oe=0;return null!=he&&(s++,Oe=Te.offset=he),l=l||Oe<0||Oe>1,a=a||Oe0&&s{const he=w>0?Te==k?1:w*Te:o[Te],Oe=he*ae;e.currentTime=j+K.delay+Oe,K.duration=Oe,this._validateStyleAst(ce,e),ce.offset=he,i.styles.push(ce)}),i}visitReference(t,e){return{type:8,animation:Ai(this,Wl(t.animation),e),options:ho(t.options)}}visitAnimateChild(t,e){return e.depCount++,{type:9,options:ho(t.options)}}visitAnimateRef(t,e){return{type:10,animation:this.visitReference(t.animation,e),options:ho(t.options)}}visitQuery(t,e){const i=e.currentQuerySelector,r=t.options||{};e.queryCount++,e.currentQuery=t;const[s,o]=function cH(n){const t=!!n.split(/\s*,\s*/).find(e=>":self"==e);return t&&(n=n.replace(aH,"")),n=n.replace(/@\*/g,mu).replace(/@\w+/g,e=>mu+"-"+e.slice(1)).replace(/:animating/g,wg),[n,t]}(t.selector);e.currentQuerySelector=i.length?i+" "+s:s,Ti(e.collectedStyles,e.currentQuerySelector,new Map);const a=Ai(this,Wl(t.animation),e);return e.currentQuery=null,e.currentQuerySelector=i,{type:11,selector:s,limit:r.limit||0,optional:!!r.optional,includeSelf:o,animation:a,originalSelector:t.selector,options:ho(t.options)}}visitStagger(t,e){e.currentQuery||e.errors.push(function D2(){return new Be(3013,Rt)}());const i="full"===t.timings?{duration:0,delay:0,easing:"full"}:gu(t.timings,e.errors,!0);return{type:12,animation:Ai(this,Wl(t.animation),e),timings:i,options:null}}}class uH{constructor(t){this.errors=t,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles=new Map,this.options=null,this.unsupportedCSSPropertiesFound=new Set,this.nonAnimatableCSSPropertiesFound=new Set}}function ho(n){return n?(n=Gl(n)).params&&(n.params=function dH(n){return n?Gl(n):null}(n.params)):n={},n}function xg(n,t,e){return{duration:n,delay:t,easing:e}}function Sg(n,t,e,i,r,s,o=null,a=!1){return{type:1,element:n,keyframes:t,preStyleProps:e,postStyleProps:i,duration:r,delay:s,totalTime:r+s,easing:o,subTimeline:a}}class Eu{constructor(){this._map=new Map}get(t){return this._map.get(t)||[]}append(t,e){let i=this._map.get(t);i||this._map.set(t,i=[]),i.push(...e)}has(t){return this._map.has(t)}clear(){this._map.clear()}}const gH=new RegExp(":enter","g"),vH=new RegExp(":leave","g");function kg(n,t,e,i,r,s=new Map,o=new Map,a,l,c=[]){return(new yH).buildKeyframes(n,t,e,i,r,s,o,a,l,c)}class yH{buildKeyframes(t,e,i,r,s,o,a,l,c,d=[]){c=c||new Eu;const f=new Tg(t,e,c,r,s,d,[]);f.options=l;const w=l.delay?xs(l.delay):0;f.currentTimeline.delayNextStep(w),f.currentTimeline.setStyles([o],null,f.errors,l),Ai(this,i,f);const k=f.timelines.filter(j=>j.containsAnimation());if(k.length&&a.size){let j;for(let K=k.length-1;K>=0;K--){const ae=k[K];if(ae.element===e){j=ae;break}}j&&!j.allowOnlyTimelineStyles()&&j.setStyles([a],null,f.errors,l)}return k.length?k.map(j=>j.buildKeyframes()):[Sg(e,[],[],[],0,w,"",!1)]}visitTrigger(t,e){}visitState(t,e){}visitTransition(t,e){}visitAnimateChild(t,e){const i=e.subInstructions.get(e.element);if(i){const r=e.createSubContext(t.options),s=e.currentTimeline.currentTime,o=this._visitSubInstructions(i,r,r.options);s!=o&&e.transformIntoNewTimeline(o)}e.previousNode=t}visitAnimateRef(t,e){const i=e.createSubContext(t.options);i.transformIntoNewTimeline(),this.visitReference(t.animation,i),e.transformIntoNewTimeline(i.currentTimeline.currentTime),e.previousNode=t}_visitSubInstructions(t,e,i){let s=e.currentTimeline.currentTime;const o=null!=i.duration?xs(i.duration):null,a=null!=i.delay?xs(i.delay):null;return 0!==o&&t.forEach(l=>{const c=e.appendInstructionToTimeline(l,o,a);s=Math.max(s,c.duration+c.delay)}),s}visitReference(t,e){e.updateOptions(t.options,!0),Ai(this,t.animation,e),e.previousNode=t}visitSequence(t,e){const i=e.subContextCount;let r=e;const s=t.options;if(s&&(s.params||s.delay)&&(r=e.createSubContext(s),r.transformIntoNewTimeline(),null!=s.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=Mu);const o=xs(s.delay);r.delayNextStep(o)}t.steps.length&&(t.steps.forEach(o=>Ai(this,o,r)),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>i&&r.transformIntoNewTimeline()),e.previousNode=t}visitGroup(t,e){const i=[];let r=e.currentTimeline.currentTime;const s=t.options&&t.options.delay?xs(t.options.delay):0;t.steps.forEach(o=>{const a=e.createSubContext(t.options);s&&a.delayNextStep(s),Ai(this,o,a),r=Math.max(r,a.currentTimeline.currentTime),i.push(a.currentTimeline)}),i.forEach(o=>e.currentTimeline.mergeTimelineCollectedStyles(o)),e.transformIntoNewTimeline(r),e.previousNode=t}_visitTiming(t,e){if(t.dynamic){const i=t.strValue;return gu(e.params?_u(i,e.params,e.errors):i,e.errors)}return{duration:t.duration,delay:t.delay,easing:t.easing}}visitAnimate(t,e){const i=e.currentAnimateTimings=this._visitTiming(t.timings,e),r=e.currentTimeline;i.delay&&(e.incrementTime(i.delay),r.snapshotCurrentStyles());const s=t.style;5==s.type?this.visitKeyframes(s,e):(e.incrementTime(i.duration),this.visitStyle(s,e),r.applyStylesToKeyframe()),e.currentAnimateTimings=null,e.previousNode=t}visitStyle(t,e){const i=e.currentTimeline,r=e.currentAnimateTimings;!r&&i.hasCurrentStyleProperties()&&i.forwardFrame();const s=r&&r.easing||t.easing;t.isEmptyStep?i.applyEmptyStep(s):i.setStyles(t.styles,s,e.errors,e.options),e.previousNode=t}visitKeyframes(t,e){const i=e.currentAnimateTimings,r=e.currentTimeline.duration,s=i.duration,a=e.createSubContext().currentTimeline;a.easing=i.easing,t.styles.forEach(l=>{a.forwardTime((l.offset||0)*s),a.setStyles(l.styles,l.easing,e.errors,e.options),a.applyStylesToKeyframe()}),e.currentTimeline.mergeTimelineCollectedStyles(a),e.transformIntoNewTimeline(r+s),e.previousNode=t}visitQuery(t,e){const i=e.currentTimeline.currentTime,r=t.options||{},s=r.delay?xs(r.delay):0;s&&(6===e.previousNode.type||0==i&&e.currentTimeline.hasCurrentStyleProperties())&&(e.currentTimeline.snapshotCurrentStyles(),e.previousNode=Mu);let o=i;const a=e.invokeQuery(t.selector,t.originalSelector,t.limit,t.includeSelf,!!r.optional,e.errors);e.currentQueryTotal=a.length;let l=null;a.forEach((c,d)=>{e.currentQueryIndex=d;const f=e.createSubContext(t.options,c);s&&f.delayNextStep(s),c===e.element&&(l=f.currentTimeline),Ai(this,t.animation,f),f.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,f.currentTimeline.currentTime)}),e.currentQueryIndex=0,e.currentQueryTotal=0,e.transformIntoNewTimeline(o),l&&(e.currentTimeline.mergeTimelineCollectedStyles(l),e.currentTimeline.snapshotCurrentStyles()),e.previousNode=t}visitStagger(t,e){const i=e.parentContext,r=e.currentTimeline,s=t.timings,o=Math.abs(s.duration),a=o*(e.currentQueryTotal-1);let l=o*e.currentQueryIndex;switch(s.duration<0?"reverse":s.easing){case"reverse":l=a-l;break;case"full":l=i.currentStaggerTime}const d=e.currentTimeline;l&&d.delayNextStep(l);const f=d.currentTime;Ai(this,t.animation,e),e.previousNode=t,i.currentStaggerTime=r.currentTime-f+(r.startTime-i.currentTimeline.startTime)}}const Mu={};class Tg{constructor(t,e,i,r,s,o,a,l){this._driver=t,this.element=e,this.subInstructions=i,this._enterClassName=r,this._leaveClassName=s,this.errors=o,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=Mu,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=l||new xu(this._driver,e,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(t,e){if(!t)return;const i=t;let r=this.options;null!=i.duration&&(r.duration=xs(i.duration)),null!=i.delay&&(r.delay=xs(i.delay));const s=i.params;if(s){let o=r.params;o||(o=this.options.params={}),Object.keys(s).forEach(a=>{(!e||!o.hasOwnProperty(a))&&(o[a]=_u(s[a],o,this.errors))})}}_copyOptions(){const t={};if(this.options){const e=this.options.params;if(e){const i=t.params={};Object.keys(e).forEach(r=>{i[r]=e[r]})}}return t}createSubContext(t=null,e,i){const r=e||this.element,s=new Tg(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,i||0));return s.previousNode=this.previousNode,s.currentAnimateTimings=this.currentAnimateTimings,s.options=this._copyOptions(),s.updateOptions(t),s.currentQueryIndex=this.currentQueryIndex,s.currentQueryTotal=this.currentQueryTotal,s.parentContext=this,this.subContextCount++,s}transformIntoNewTimeline(t){return this.previousNode=Mu,this.currentTimeline=this.currentTimeline.fork(this.element,t),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(t,e,i){const r={duration:null!=e?e:t.duration,delay:this.currentTimeline.currentTime+(null!=i?i:0)+t.delay,easing:""},s=new bH(this._driver,t.element,t.keyframes,t.preStyleProps,t.postStyleProps,r,t.stretchStartingKeyframe);return this.timelines.push(s),r}incrementTime(t){this.currentTimeline.forwardTime(this.currentTimeline.duration+t)}delayNextStep(t){t>0&&this.currentTimeline.delayNextStep(t)}invokeQuery(t,e,i,r,s,o){let a=[];if(r&&a.push(this.element),t.length>0){t=(t=t.replace(gH,"."+this._enterClassName)).replace(vH,"."+this._leaveClassName);let c=this._driver.query(this.element,t,1!=i);0!==i&&(c=i<0?c.slice(c.length+i,c.length):c.slice(0,i)),a.push(...c)}return!s&&0==a.length&&o.push(function E2(n){return new Be(3014,Rt)}()),a}}class xu{constructor(t,e,i,r){this._driver=t,this.element=e,this.startTime=i,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe=new Map,this._currentKeyframe=new Map,this._keyframes=new Map,this._styleSummary=new Map,this._localTimelineStyles=new Map,this._pendingStyles=new Map,this._backFill=new Map,this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(e),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(e,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(t){const e=1===this._keyframes.size&&this._pendingStyles.size;this.duration||e?(this.forwardTime(this.currentTime+t),e&&this.snapshotCurrentStyles()):this.startTime+=t}fork(t,e){return this.applyStylesToKeyframe(),new xu(this._driver,t,e||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(t){this.applyStylesToKeyframe(),this.duration=t,this._loadKeyframe()}_updateStyle(t,e){this._localTimelineStyles.set(t,e),this._globalTimelineStyles.set(t,e),this._styleSummary.set(t,{time:this.currentTime,value:e})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(t){t&&this._previousKeyframe.set("easing",t);for(let[e,i]of this._globalTimelineStyles)this._backFill.set(e,i||rs),this._currentKeyframe.set(e,rs);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(t,e,i,r){e&&this._previousKeyframe.set("easing",e);const s=r&&r.params||{},o=function wH(n,t){const e=new Map;let i;return n.forEach(r=>{if("*"===r){i=i||t.keys();for(let s of i)e.set(s,rs)}else Ss(r,e)}),e}(t,this._globalTimelineStyles);for(let[a,l]of o){const c=_u(l,s,i);this._pendingStyles.set(a,c),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)||rs),this._updateStyle(a,c)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((t,e)=>{this._currentKeyframe.set(e,t)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((t,e)=>{this._currentKeyframe.has(e)||this._currentKeyframe.set(e,t)}))}snapshotCurrentStyles(){for(let[t,e]of this._localTimelineStyles)this._pendingStyles.set(t,e),this._updateStyle(t,e)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const t=[];for(let e in this._currentKeyframe)t.push(e);return t}mergeTimelineCollectedStyles(t){t._styleSummary.forEach((e,i)=>{const r=this._styleSummary.get(i);(!r||e.time>r.time)&&this._updateStyle(i,e.value)})}buildKeyframes(){this.applyStylesToKeyframe();const t=new Set,e=new Set,i=1===this._keyframes.size&&0===this.duration;let r=[];this._keyframes.forEach((a,l)=>{const c=Ss(a,new Map,this._backFill);c.forEach((d,f)=>{"!"===d?t.add(f):d===rs&&e.add(f)}),i||c.set("offset",l/this.duration),r.push(c)});const s=t.size?vu(t.values()):[],o=e.size?vu(e.values()):[];if(i){const a=r[0],l=new Map(a);a.set("offset",0),l.set("offset",1),r=[a,l]}return Sg(this.element,r,s,o,this.duration,this.startTime,this.easing,!1)}}class bH extends xu{constructor(t,e,i,r,s,o,a=!1){super(t,e,o.delay),this.keyframes=i,this.preStyleProps=r,this.postStyleProps=s,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let t=this.keyframes,{delay:e,duration:i,easing:r}=this.timings;if(this._stretchStartingKeyframe&&e){const s=[],o=i+e,a=e/o,l=Ss(t[0]);l.set("offset",0),s.push(l);const c=Ss(t[0]);c.set("offset",cM(a)),s.push(c);const d=t.length-1;for(let f=1;f<=d;f++){let w=Ss(t[f]);const k=w.get("offset");w.set("offset",cM((e+k*i)/o)),s.push(w)}i=o,e=0,r="",t=s}return Sg(this.element,t,this.preStyleProps,this.postStyleProps,i,e,r,!0)}}function cM(n,t=3){const e=Math.pow(10,t-1);return Math.round(n*e)/e}class Ag{}const CH=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class DH extends Ag{normalizePropertyName(t,e){return Eg(t)}normalizeStyleValue(t,e,i,r){let s="";const o=i.toString().trim();if(CH.has(e)&&0!==i&&"0"!==i)if("number"==typeof i)s="px";else{const a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&r.push(function f2(n,t){return new Be(3005,Rt)}())}return o+s}}function dM(n,t,e,i,r,s,o,a,l,c,d,f,w){return{type:0,element:n,triggerName:t,isRemovalTransition:r,fromState:e,fromStyles:s,toState:i,toStyles:o,timelines:a,queriedElements:l,preStyleProps:c,postStyleProps:d,totalTime:f,errors:w}}const Ig={};class uM{constructor(t,e,i){this._triggerName=t,this.ast=e,this._stateStyles=i}match(t,e,i,r){return function EH(n,t,e,i,r){return n.some(s=>s(t,e,i,r))}(this.ast.matchers,t,e,i,r)}buildStyles(t,e,i){let r=this._stateStyles.get("*");return void 0!==t&&(r=this._stateStyles.get(null==t?void 0:t.toString())||r),r?r.buildStyles(e,i):new Map}build(t,e,i,r,s,o,a,l,c,d){var f;const w=[],k=this.ast.options&&this.ast.options.params||Ig,K=this.buildStyles(i,a&&a.params||Ig,w),ae=l&&l.params||Ig,ce=this.buildStyles(r,ae,w),Te=new Set,he=new Map,Oe=new Map,ft="void"===r,Nt={params:MH(ae,k),delay:null===(f=this.ast.options)||void 0===f?void 0:f.delay},pn=d?[]:kg(t,e,this.ast.animation,s,o,K,ce,Nt,c,w);let Zn=0;if(pn.forEach(ci=>{Zn=Math.max(ci.duration+ci.delay,Zn)}),w.length)return dM(e,this._triggerName,i,r,ft,K,ce,[],[],he,Oe,Zn,w);pn.forEach(ci=>{const us=ci.element,hs=Ti(he,us,new Set);ci.preStyleProps.forEach(Lr=>hs.add(Lr));const fs=Ti(Oe,us,new Set);ci.postStyleProps.forEach(Lr=>fs.add(Lr)),us!==e&&Te.add(us)});const Vs=vu(Te.values());return dM(e,this._triggerName,i,r,ft,K,ce,pn,Vs,he,Oe,Zn)}}function MH(n,t){const e=Gl(t);for(const i in n)n.hasOwnProperty(i)&&null!=n[i]&&(e[i]=n[i]);return e}class xH{constructor(t,e,i){this.styles=t,this.defaultParams=e,this.normalizer=i}buildStyles(t,e){const i=new Map,r=Gl(this.defaultParams);return Object.keys(t).forEach(s=>{const o=t[s];null!==o&&(r[s]=o)}),this.styles.styles.forEach(s=>{"string"!=typeof s&&s.forEach((o,a)=>{o&&(o=_u(o,r,e));const l=this.normalizer.normalizePropertyName(a,e);o=this.normalizer.normalizeStyleValue(a,l,o,e),i.set(l,o)})}),i}}class kH{constructor(t,e,i){this.name=t,this.ast=e,this._normalizer=i,this.transitionFactories=[],this.states=new Map,e.states.forEach(r=>{this.states.set(r.name,new xH(r.style,r.options&&r.options.params||{},i))}),hM(this.states,"true","1"),hM(this.states,"false","0"),e.transitions.forEach(r=>{this.transitionFactories.push(new uM(t,r,this.states))}),this.fallbackTransition=function TH(n,t,e){return new uM(n,{type:1,animation:{type:2,steps:[],options:null},matchers:[(o,a)=>!0],options:null,queryCount:0,depCount:0},t)}(t,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(t,e,i,r){return this.transitionFactories.find(o=>o.match(t,e,i,r))||null}matchStyles(t,e,i){return this.fallbackTransition.buildStyles(t,e,i)}}function hM(n,t,e){n.has(t)?n.has(e)||n.set(e,n.get(t)):n.has(e)&&n.set(t,n.get(e))}const AH=new Eu;class IH{constructor(t,e,i){this.bodyNode=t,this._driver=e,this._normalizer=i,this._animations=new Map,this._playersById=new Map,this.players=[]}register(t,e){const i=[],s=Mg(this._driver,e,i,[]);if(i.length)throw function I2(n){return new Be(3503,Rt)}();this._animations.set(t,s)}_buildPlayer(t,e,i){const r=t.element,s=$E(0,this._normalizer,0,t.keyframes,e,i);return this._driver.animate(r,s,t.duration,t.delay,t.easing,[],!0)}create(t,e,i={}){const r=[],s=this._animations.get(t);let o;const a=new Map;if(s?(o=kg(this._driver,e,s,bg,fu,new Map,new Map,i,AH,r),o.forEach(d=>{const f=Ti(a,d.element,new Map);d.postStyleProps.forEach(w=>f.set(w,null))})):(r.push(function R2(){return new Be(3300,Rt)}()),o=[]),r.length)throw function P2(n){return new Be(3504,Rt)}();a.forEach((d,f)=>{d.forEach((w,k)=>{d.set(k,this._driver.computeStyle(f,k,rs))})});const c=Ms(o.map(d=>{const f=a.get(d.element);return this._buildPlayer(d,new Map,f)}));return this._playersById.set(t,c),c.onDestroy(()=>this.destroy(t)),this.players.push(c),c}destroy(t){const e=this._getPlayer(t);e.destroy(),this._playersById.delete(t);const i=this.players.indexOf(e);i>=0&&this.players.splice(i,1)}_getPlayer(t){const e=this._playersById.get(t);if(!e)throw function O2(n){return new Be(3301,Rt)}();return e}listen(t,e,i,r){const s=gg(e,"","","");return pg(this._getPlayer(t),i,s,r),()=>{}}command(t,e,i,r){if("register"==i)return void this.register(t,r[0]);if("create"==i)return void this.create(t,e,r[0]||{});const s=this._getPlayer(t);switch(i){case"play":s.play();break;case"pause":s.pause();break;case"reset":s.reset();break;case"restart":s.restart();break;case"finish":s.finish();break;case"init":s.init();break;case"setPosition":s.setPosition(parseFloat(r[0]));break;case"destroy":this.destroy(t)}}}const fM="ng-animate-queued",Rg="ng-animate-disabled",LH=[],pM={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},NH={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},$i="__ng_removed";class Pg{constructor(t,e=""){this.namespaceId=e;const i=t&&t.hasOwnProperty("value");if(this.value=function jH(n){return null!=n?n:null}(i?t.value:t),i){const s=Gl(t);delete s.value,this.options=s}else this.options={};this.options.params||(this.options.params={})}get params(){return this.options.params}absorbOptions(t){const e=t.params;if(e){const i=this.options.params;Object.keys(e).forEach(r=>{null==i[r]&&(i[r]=e[r])})}}}const ql="void",Og=new Pg(ql);class BH{constructor(t,e,i){this.id=t,this.hostElement=e,this._engine=i,this.players=[],this._triggers=new Map,this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+t,Gi(e,this._hostClassName)}listen(t,e,i,r){if(!this._triggers.has(e))throw function F2(n,t){return new Be(3302,Rt)}();if(null==i||0==i.length)throw function L2(n){return new Be(3303,Rt)}();if(!function UH(n){return"start"==n||"done"==n}(i))throw function N2(n,t){return new Be(3400,Rt)}();const s=Ti(this._elementListeners,t,[]),o={name:e,phase:i,callback:r};s.push(o);const a=Ti(this._engine.statesByElement,t,new Map);return a.has(e)||(Gi(t,pu),Gi(t,pu+"-"+e),a.set(e,Og)),()=>{this._engine.afterFlush(()=>{const l=s.indexOf(o);l>=0&&s.splice(l,1),this._triggers.has(e)||a.delete(e)})}}register(t,e){return!this._triggers.has(t)&&(this._triggers.set(t,e),!0)}_getTrigger(t){const e=this._triggers.get(t);if(!e)throw function B2(n){return new Be(3401,Rt)}();return e}trigger(t,e,i,r=!0){const s=this._getTrigger(e),o=new Fg(this.id,e,t);let a=this._engine.statesByElement.get(t);a||(Gi(t,pu),Gi(t,pu+"-"+e),this._engine.statesByElement.set(t,a=new Map));let l=a.get(e);const c=new Pg(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),a.set(e,c),l||(l=Og),c.value!==ql&&l.value===c.value){if(!function GH(n,t){const e=Object.keys(n),i=Object.keys(t);if(e.length!=i.length)return!1;for(let r=0;r{uo(t,ae),kr(t,ce)})}return}const w=Ti(this._engine.playersByElement,t,[]);w.forEach(K=>{K.namespaceId==this.id&&K.triggerName==e&&K.queued&&K.destroy()});let k=s.matchTransition(l.value,c.value,t,c.params),j=!1;if(!k){if(!r)return;k=s.fallbackTransition,j=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:t,triggerName:e,transition:k,fromState:l,toState:c,player:o,isFallbackTransition:j}),j||(Gi(t,fM),o.onStart(()=>{wa(t,fM)})),o.onDone(()=>{let K=this.players.indexOf(o);K>=0&&this.players.splice(K,1);const ae=this._engine.playersByElement.get(t);if(ae){let ce=ae.indexOf(o);ce>=0&&ae.splice(ce,1)}}),this.players.push(o),w.push(o),o}deregister(t){this._triggers.delete(t),this._engine.statesByElement.forEach(e=>e.delete(t)),this._elementListeners.forEach((e,i)=>{this._elementListeners.set(i,e.filter(r=>r.name!=t))})}clearElementCache(t){this._engine.statesByElement.delete(t),this._elementListeners.delete(t);const e=this._engine.playersByElement.get(t);e&&(e.forEach(i=>i.destroy()),this._engine.playersByElement.delete(t))}_signalRemovalForInnerTriggers(t,e){const i=this._engine.driver.query(t,mu,!0);i.forEach(r=>{if(r[$i])return;const s=this._engine.fetchNamespacesByElement(r);s.size?s.forEach(o=>o.triggerLeaveAnimation(r,e,!1,!0)):this.clearElementCache(r)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(r=>this.clearElementCache(r)))}triggerLeaveAnimation(t,e,i,r){const s=this._engine.statesByElement.get(t),o=new Map;if(s){const a=[];if(s.forEach((l,c)=>{if(o.set(c,l.value),this._triggers.has(c)){const d=this.trigger(t,c,ql,r);d&&a.push(d)}}),a.length)return this._engine.markElementAsRemoved(this.id,t,!0,e,o),i&&Ms(a).onDone(()=>this._engine.processLeaveNode(t)),!0}return!1}prepareLeaveAnimationListeners(t){const e=this._elementListeners.get(t),i=this._engine.statesByElement.get(t);if(e&&i){const r=new Set;e.forEach(s=>{const o=s.name;if(r.has(o))return;r.add(o);const l=this._triggers.get(o).fallbackTransition,c=i.get(o)||Og,d=new Pg(ql),f=new Fg(this.id,o,t);this._engine.totalQueuedPlayers++,this._queue.push({element:t,triggerName:o,transition:l,fromState:c,toState:d,player:f,isFallbackTransition:!0})})}}removeNode(t,e){const i=this._engine;if(t.childElementCount&&this._signalRemovalForInnerTriggers(t,e),this.triggerLeaveAnimation(t,e,!0))return;let r=!1;if(i.totalAnimations){const s=i.players.length?i.playersByQueriedElement.get(t):[];if(s&&s.length)r=!0;else{let o=t;for(;o=o.parentNode;)if(i.statesByElement.get(o)){r=!0;break}}}if(this.prepareLeaveAnimationListeners(t),r)i.markElementAsRemoved(this.id,t,!1,e);else{const s=t[$i];(!s||s===pM)&&(i.afterFlush(()=>this.clearElementCache(t)),i.destroyInnerAnimations(t),i._onRemovalComplete(t,e))}}insertNode(t,e){Gi(t,this._hostClassName)}drainQueuedTransitions(t){const e=[];return this._queue.forEach(i=>{const r=i.player;if(r.destroyed)return;const s=i.element,o=this._elementListeners.get(s);o&&o.forEach(a=>{if(a.name==i.triggerName){const l=gg(s,i.triggerName,i.fromState.value,i.toState.value);l._data=t,pg(i.player,a.phase,l,a.callback)}}),r.markedForDestroy?this._engine.afterFlush(()=>{r.destroy()}):e.push(i)}),this._queue=[],e.sort((i,r)=>{const s=i.transition.ast.depCount,o=r.transition.ast.depCount;return 0==s||0==o?s-o:this._engine.driver.containsElement(i.element,r.element)?1:-1})}destroy(t){this.players.forEach(e=>e.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,t)}elementContainsData(t){let e=!1;return this._elementListeners.has(t)&&(e=!0),e=!!this._queue.find(i=>i.element===t)||e,e}}class VH{constructor(t,e,i){this.bodyNode=t,this.driver=e,this._normalizer=i,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(r,s)=>{}}_onRemovalComplete(t,e){this.onRemovalComplete(t,e)}get queuedPlayers(){const t=[];return this._namespaceList.forEach(e=>{e.players.forEach(i=>{i.queued&&t.push(i)})}),t}createNamespace(t,e){const i=new BH(t,e,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,e)?this._balanceNamespaceList(i,e):(this.newHostElements.set(e,i),this.collectEnterElement(e)),this._namespaceLookup[t]=i}_balanceNamespaceList(t,e){const i=this._namespaceList,r=this.namespacesByHostElement;if(i.length-1>=0){let o=!1,a=this.driver.getParentElement(e);for(;a;){const l=r.get(a);if(l){const c=i.indexOf(l);i.splice(c+1,0,t),o=!0;break}a=this.driver.getParentElement(a)}o||i.unshift(t)}else i.push(t);return r.set(e,t),t}register(t,e){let i=this._namespaceLookup[t];return i||(i=this.createNamespace(t,e)),i}registerTrigger(t,e,i){let r=this._namespaceLookup[t];r&&r.register(e,i)&&this.totalAnimations++}destroy(t,e){if(!t)return;const i=this._fetchNamespace(t);this.afterFlush(()=>{this.namespacesByHostElement.delete(i.hostElement),delete this._namespaceLookup[t];const r=this._namespaceList.indexOf(i);r>=0&&this._namespaceList.splice(r,1)}),this.afterFlushAnimationsDone(()=>i.destroy(e))}_fetchNamespace(t){return this._namespaceLookup[t]}fetchNamespacesByElement(t){const e=new Set,i=this.statesByElement.get(t);if(i)for(let r of i.values())if(r.namespaceId){const s=this._fetchNamespace(r.namespaceId);s&&e.add(s)}return e}trigger(t,e,i,r){if(Su(e)){const s=this._fetchNamespace(t);if(s)return s.trigger(e,i,r),!0}return!1}insertNode(t,e,i,r){if(!Su(e))return;const s=e[$i];if(s&&s.setForRemoval){s.setForRemoval=!1,s.setForMove=!0;const o=this.collectedLeaveElements.indexOf(e);o>=0&&this.collectedLeaveElements.splice(o,1)}if(t){const o=this._fetchNamespace(t);o&&o.insertNode(e,i)}r&&this.collectEnterElement(e)}collectEnterElement(t){this.collectedEnterElements.push(t)}markElementAsDisabled(t,e){e?this.disabledNodes.has(t)||(this.disabledNodes.add(t),Gi(t,Rg)):this.disabledNodes.has(t)&&(this.disabledNodes.delete(t),wa(t,Rg))}removeNode(t,e,i,r){if(Su(e)){const s=t?this._fetchNamespace(t):null;if(s?s.removeNode(e,r):this.markElementAsRemoved(t,e,!1,r),i){const o=this.namespacesByHostElement.get(e);o&&o.id!==t&&o.removeNode(e,r)}}else this._onRemovalComplete(e,r)}markElementAsRemoved(t,e,i,r,s){this.collectedLeaveElements.push(e),e[$i]={namespaceId:t,setForRemoval:r,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:s}}listen(t,e,i,r,s){return Su(e)?this._fetchNamespace(t).listen(e,i,r,s):()=>{}}_buildInstruction(t,e,i,r,s){return t.transition.build(this.driver,t.element,t.fromState.value,t.toState.value,i,r,t.fromState.options,t.toState.options,e,s)}destroyInnerAnimations(t){let e=this.driver.query(t,mu,!0);e.forEach(i=>this.destroyActiveAnimationsForElement(i)),0!=this.playersByQueriedElement.size&&(e=this.driver.query(t,wg,!0),e.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(t){const e=this.playersByElement.get(t);e&&e.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(t){const e=this.playersByQueriedElement.get(t);e&&e.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(t=>{if(this.players.length)return Ms(this.players).onDone(()=>t());t()})}processLeaveNode(t){var e;const i=t[$i];if(i&&i.setForRemoval){if(t[$i]=pM,i.namespaceId){this.destroyInnerAnimations(t);const r=this._fetchNamespace(i.namespaceId);r&&r.clearElementCache(t)}this._onRemovalComplete(t,i.setForRemoval)}!(null===(e=t.classList)||void 0===e)&&e.contains(Rg)&&this.markElementAsDisabled(t,!1),this.driver.query(t,".ng-animate-disabled",!0).forEach(r=>{this.markElementAsDisabled(r,!1)})}flush(t=-1){let e=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,r)=>this._balanceNamespaceList(i,r)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;ii()),this._flushFns=[],this._whenQuietFns.length){const i=this._whenQuietFns;this._whenQuietFns=[],e.length?Ms(e).onDone(()=>{i.forEach(r=>r())}):i.forEach(r=>r())}}reportError(t){throw function V2(n){return new Be(3402,Rt)}()}_flushAnimations(t,e){const i=new Eu,r=[],s=new Map,o=[],a=new Map,l=new Map,c=new Map,d=new Set;this.disabledNodes.forEach(ze=>{d.add(ze);const nt=this.driver.query(ze,".ng-animate-queued",!0);for(let ot=0;ot{const ot=bg+K++;j.set(nt,ot),ze.forEach(St=>Gi(St,ot))});const ae=[],ce=new Set,Te=new Set;for(let ze=0;zece.add(St)):Te.add(nt))}const he=new Map,Oe=_M(w,Array.from(ce));Oe.forEach((ze,nt)=>{const ot=fu+K++;he.set(nt,ot),ze.forEach(St=>Gi(St,ot))}),t.push(()=>{k.forEach((ze,nt)=>{const ot=j.get(nt);ze.forEach(St=>wa(St,ot))}),Oe.forEach((ze,nt)=>{const ot=he.get(nt);ze.forEach(St=>wa(St,ot))}),ae.forEach(ze=>{this.processLeaveNode(ze)})});const ft=[],Nt=[];for(let ze=this._namespaceList.length-1;ze>=0;ze--)this._namespaceList[ze].drainQueuedTransitions(e).forEach(ot=>{const St=ot.player,mn=ot.element;if(ft.push(St),this.collectedEnterElements.length){const Xn=mn[$i];if(Xn&&Xn.setForMove){if(Xn.previousTriggersValues&&Xn.previousTriggersValues.has(ot.triggerName)){const ko=Xn.previousTriggersValues.get(ot.triggerName),Zi=this.statesByElement.get(ot.element);if(Zi&&Zi.has(ot.triggerName)){const ef=Zi.get(ot.triggerName);ef.value=ko,Zi.set(ot.triggerName,ef)}}return void St.destroy()}}const Nr=!f||!this.driver.containsElement(f,mn),Pi=he.get(mn),Hs=j.get(mn),ln=this._buildInstruction(ot,i,Hs,Pi,Nr);if(ln.errors&&ln.errors.length)return void Nt.push(ln);if(Nr)return St.onStart(()=>uo(mn,ln.fromStyles)),St.onDestroy(()=>kr(mn,ln.toStyles)),void r.push(St);if(ot.isFallbackTransition)return St.onStart(()=>uo(mn,ln.fromStyles)),St.onDestroy(()=>kr(mn,ln.toStyles)),void r.push(St);const vA=[];ln.timelines.forEach(Xn=>{Xn.stretchStartingKeyframe=!0,this.disabledNodes.has(Xn.element)||vA.push(Xn)}),ln.timelines=vA,i.append(mn,ln.timelines),o.push({instruction:ln,player:St,element:mn}),ln.queriedElements.forEach(Xn=>Ti(a,Xn,[]).push(St)),ln.preStyleProps.forEach((Xn,ko)=>{if(Xn.size){let Zi=l.get(ko);Zi||l.set(ko,Zi=new Set),Xn.forEach((ef,Zv)=>Zi.add(Zv))}}),ln.postStyleProps.forEach((Xn,ko)=>{let Zi=c.get(ko);Zi||c.set(ko,Zi=new Set),Xn.forEach((ef,Zv)=>Zi.add(Zv))})});if(Nt.length){const ze=[];Nt.forEach(nt=>{ze.push(function H2(n,t){return new Be(3505,Rt)}())}),ft.forEach(nt=>nt.destroy()),this.reportError(ze)}const pn=new Map,Zn=new Map;o.forEach(ze=>{const nt=ze.element;i.has(nt)&&(Zn.set(nt,nt),this._beforeAnimationBuild(ze.player.namespaceId,ze.instruction,pn))}),r.forEach(ze=>{const nt=ze.element;this._getPreviousPlayers(nt,!1,ze.namespaceId,ze.triggerName,null).forEach(St=>{Ti(pn,nt,[]).push(St),St.destroy()})});const Vs=ae.filter(ze=>yM(ze,l,c)),ci=new Map;gM(ci,this.driver,Te,c,rs).forEach(ze=>{yM(ze,l,c)&&Vs.push(ze)});const hs=new Map;k.forEach((ze,nt)=>{gM(hs,this.driver,new Set(ze),l,"!")}),Vs.forEach(ze=>{var nt,ot;const St=ci.get(ze),mn=hs.get(ze);ci.set(ze,new Map([...Array.from(null!==(nt=null==St?void 0:St.entries())&&void 0!==nt?nt:[]),...Array.from(null!==(ot=null==mn?void 0:mn.entries())&&void 0!==ot?ot:[])]))});const fs=[],Lr=[],Ga={};o.forEach(ze=>{const{element:nt,player:ot,instruction:St}=ze;if(i.has(nt)){if(d.has(nt))return ot.onDestroy(()=>kr(nt,St.toStyles)),ot.disabled=!0,ot.overrideTotalTime(St.totalTime),void r.push(ot);let mn=Ga;if(Zn.size>1){let Pi=nt;const Hs=[];for(;Pi=Pi.parentNode;){const ln=Zn.get(Pi);if(ln){mn=ln;break}Hs.push(Pi)}Hs.forEach(ln=>Zn.set(ln,mn))}const Nr=this._buildAnimation(ot.namespaceId,St,pn,s,hs,ci);if(ot.setRealPlayer(Nr),mn===Ga)fs.push(ot);else{const Pi=this.playersByElement.get(mn);Pi&&Pi.length&&(ot.parentPlayer=Ms(Pi)),r.push(ot)}}else uo(nt,St.fromStyles),ot.onDestroy(()=>kr(nt,St.toStyles)),Lr.push(ot),d.has(nt)&&r.push(ot)}),Lr.forEach(ze=>{const nt=s.get(ze.element);if(nt&&nt.length){const ot=Ms(nt);ze.setRealPlayer(ot)}}),r.forEach(ze=>{ze.parentPlayer?ze.syncPlayerEvents(ze.parentPlayer):ze.destroy()});for(let ze=0;ze!Nr.destroyed);mn.length?zH(this,nt,mn):this.processLeaveNode(nt)}return ae.length=0,fs.forEach(ze=>{this.players.push(ze),ze.onDone(()=>{ze.destroy();const nt=this.players.indexOf(ze);this.players.splice(nt,1)}),ze.play()}),fs}elementContainsData(t,e){let i=!1;const r=e[$i];return r&&r.setForRemoval&&(i=!0),this.playersByElement.has(e)&&(i=!0),this.playersByQueriedElement.has(e)&&(i=!0),this.statesByElement.has(e)&&(i=!0),this._fetchNamespace(t).elementContainsData(e)||i}afterFlush(t){this._flushFns.push(t)}afterFlushAnimationsDone(t){this._whenQuietFns.push(t)}_getPreviousPlayers(t,e,i,r,s){let o=[];if(e){const a=this.playersByQueriedElement.get(t);a&&(o=a)}else{const a=this.playersByElement.get(t);if(a){const l=!s||s==ql;a.forEach(c=>{c.queued||!l&&c.triggerName!=r||o.push(c)})}}return(i||r)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||r&&r!=a.triggerName))),o}_beforeAnimationBuild(t,e,i){const s=e.element,o=e.isRemovalTransition?void 0:t,a=e.isRemovalTransition?void 0:e.triggerName;for(const l of e.timelines){const c=l.element,d=c!==s,f=Ti(i,c,[]);this._getPreviousPlayers(c,d,o,a,e.toState).forEach(k=>{const j=k.getRealPlayer();j.beforeDestroy&&j.beforeDestroy(),k.destroy(),f.push(k)})}uo(s,e.fromStyles)}_buildAnimation(t,e,i,r,s,o){const a=e.triggerName,l=e.element,c=[],d=new Set,f=new Set,w=e.timelines.map(j=>{const K=j.element;d.add(K);const ae=K[$i];if(ae&&ae.removedBeforeQueried)return new $l(j.duration,j.delay);const ce=K!==l,Te=function $H(n){const t=[];return vM(n,t),t}((i.get(K)||LH).map(pn=>pn.getRealPlayer())).filter(pn=>!!pn.element&&pn.element===K),he=s.get(K),Oe=o.get(K),ft=$E(0,this._normalizer,0,j.keyframes,he,Oe),Nt=this._buildPlayer(j,ft,Te);if(j.subTimeline&&r&&f.add(K),ce){const pn=new Fg(t,a,K);pn.setRealPlayer(Nt),c.push(pn)}return Nt});c.forEach(j=>{Ti(this.playersByQueriedElement,j.element,[]).push(j),j.onDone(()=>function HH(n,t,e){let i=n.get(t);if(i){if(i.length){const r=i.indexOf(e);i.splice(r,1)}0==i.length&&n.delete(t)}return i}(this.playersByQueriedElement,j.element,j))}),d.forEach(j=>Gi(j,JE));const k=Ms(w);return k.onDestroy(()=>{d.forEach(j=>wa(j,JE)),kr(l,e.toStyles)}),f.forEach(j=>{Ti(r,j,[]).push(k)}),k}_buildPlayer(t,e,i){return e.length>0?this.driver.animate(t.element,e,t.duration,t.delay,t.easing,i):new $l(t.duration,t.delay)}}class Fg{constructor(t,e,i){this.namespaceId=t,this.triggerName=e,this.element=i,this._player=new $l,this._containsRealPlayer=!1,this._queuedCallbacks=new Map,this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(t){this._containsRealPlayer||(this._player=t,this._queuedCallbacks.forEach((e,i)=>{e.forEach(r=>pg(t,i,void 0,r))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(t.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(t){this.totalTime=t}syncPlayerEvents(t){const e=this._player;e.triggerCallback&&t.onStart(()=>e.triggerCallback("start")),t.onDone(()=>this.finish()),t.onDestroy(()=>this.destroy())}_queueEvent(t,e){Ti(this._queuedCallbacks,t,[]).push(e)}onDone(t){this.queued&&this._queueEvent("done",t),this._player.onDone(t)}onStart(t){this.queued&&this._queueEvent("start",t),this._player.onStart(t)}onDestroy(t){this.queued&&this._queueEvent("destroy",t),this._player.onDestroy(t)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(t){this.queued||this._player.setPosition(t)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(t){const e=this._player;e.triggerCallback&&e.triggerCallback(t)}}function Su(n){return n&&1===n.nodeType}function mM(n,t){const e=n.style.display;return n.style.display=null!=t?t:"none",e}function gM(n,t,e,i,r){const s=[];e.forEach(l=>s.push(mM(l)));const o=[];i.forEach((l,c)=>{const d=new Map;l.forEach(f=>{const w=t.computeStyle(c,f,r);d.set(f,w),(!w||0==w.length)&&(c[$i]=NH,o.push(c))}),n.set(c,d)});let a=0;return e.forEach(l=>mM(l,s[a++])),o}function _M(n,t){const e=new Map;if(n.forEach(a=>e.set(a,[])),0==t.length)return e;const r=new Set(t),s=new Map;function o(a){if(!a)return 1;let l=s.get(a);if(l)return l;const c=a.parentNode;return l=e.has(c)?c:r.has(c)?1:o(c),s.set(a,l),l}return t.forEach(a=>{const l=o(a);1!==l&&e.get(l).push(a)}),e}function Gi(n,t){var e;null===(e=n.classList)||void 0===e||e.add(t)}function wa(n,t){var e;null===(e=n.classList)||void 0===e||e.remove(t)}function zH(n,t,e){Ms(e).onDone(()=>n.processLeaveNode(t))}function vM(n,t){for(let e=0;er.add(s)):t.set(n,i),e.delete(n),!0}class ku{constructor(t,e,i){this.bodyNode=t,this._driver=e,this._normalizer=i,this._triggerCache={},this.onRemovalComplete=(r,s)=>{},this._transitionEngine=new VH(t,e,i),this._timelineEngine=new IH(t,e,i),this._transitionEngine.onRemovalComplete=(r,s)=>this.onRemovalComplete(r,s)}registerTrigger(t,e,i,r,s){const o=t+"-"+r;let a=this._triggerCache[o];if(!a){const l=[],d=Mg(this._driver,s,l,[]);if(l.length)throw function T2(n,t){return new Be(3404,Rt)}();a=function SH(n,t,e){return new kH(n,t,e)}(r,d,this._normalizer),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(e,r,a)}register(t,e){this._transitionEngine.register(t,e)}destroy(t,e){this._transitionEngine.destroy(t,e)}onInsert(t,e,i,r){this._transitionEngine.insertNode(t,e,i,r)}onRemove(t,e,i,r){this._transitionEngine.removeNode(t,e,r||!1,i)}disableAnimations(t,e){this._transitionEngine.markElementAsDisabled(t,e)}process(t,e,i,r){if("@"==i.charAt(0)){const[s,o]=GE(i);this._timelineEngine.command(s,e,o,r)}else this._transitionEngine.trigger(t,e,i,r)}listen(t,e,i,r,s){if("@"==i.charAt(0)){const[o,a]=GE(i);return this._timelineEngine.listen(o,e,a,s)}return this._transitionEngine.listen(t,e,i,r,s)}flush(t=-1){this._transitionEngine.flush(t)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}let qH=(()=>{class n{constructor(e,i,r){this._element=e,this._startStyles=i,this._endStyles=r,this._state=0;let s=n.initialStylesByElement.get(e);s||n.initialStylesByElement.set(e,s=new Map),this._initialStyles=s}start(){this._state<1&&(this._startStyles&&kr(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(kr(this._element,this._initialStyles),this._endStyles&&(kr(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(n.initialStylesByElement.delete(this._element),this._startStyles&&(uo(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(uo(this._element,this._endStyles),this._endStyles=null),kr(this._element,this._initialStyles),this._state=3)}}return n.initialStylesByElement=new WeakMap,n})();function Lg(n){let t=null;return n.forEach((e,i)=>{(function YH(n){return"display"===n||"position"===n})(i)&&(t=t||new Map,t.set(i,e))}),t}class bM{constructor(t,e,i,r){this.element=t,this.keyframes=e,this.options=i,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this.time=0,this.parentPlayer=null,this.currentSnapshot=new Map,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const t=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,t,this.options),this._finalKeyframe=t.length?t[t.length-1]:new Map,this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(t){const e=[];return t.forEach(i=>{e.push(Object.fromEntries(i))}),e}_triggerWebAnimation(t,e,i){return t.animate(this._convertKeyframesToObject(e),i)}onStart(t){this._onStartFns.push(t)}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(t=>t()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}setPosition(t){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=t*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const t=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,r)=>{"offset"!==r&&t.set(r,this._finished?i:sM(this.element,r))}),this.currentSnapshot=t}triggerCallback(t){const e="start"===t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}class KH{validateStyleProperty(t){return!0}validateAnimatableStyleProperty(t){return!0}matchesElement(t,e){return!1}containsElement(t,e){return KE(t,e)}getParentElement(t){return vg(t)}query(t,e,i){return QE(t,e,i)}computeStyle(t,e,i){return window.getComputedStyle(t)[e]}animate(t,e,i,r,s,o=[]){const l={duration:i,delay:r,fill:0==r?"both":"forwards"};s&&(l.easing=s);const c=new Map,d=o.filter(k=>k instanceof bM);(function J2(n,t){return 0===n||0===t})(i,r)&&d.forEach(k=>{k.currentSnapshot.forEach((j,K)=>c.set(K,j))});let f=function K2(n){return n.length?n[0]instanceof Map?n:n.map(t=>eM(t)):[]}(e).map(k=>Ss(k));f=function eH(n,t,e){if(e.size&&t.length){let i=t[0],r=[];if(e.forEach((s,o)=>{i.has(o)||r.push(o),i.set(o,s)}),r.length)for(let s=1;so.set(a,sM(n,a)))}}return t}(t,f,c);const w=function WH(n,t){let e=null,i=null;return Array.isArray(t)&&t.length?(e=Lg(t[0]),t.length>1&&(i=Lg(t[t.length-1]))):t instanceof Map&&(e=Lg(t)),e||i?new qH(n,e,i):null}(t,f);return new bM(t,f,l,w)}}let QH=(()=>{class n extends BE{constructor(e,i){super(),this._nextAnimationId=0,this._renderer=e.createRenderer(i.body,{id:"0",encapsulation:Ji.None,styles:[],data:{animation:[]}})}build(e){const i=this._nextAnimationId.toString();this._nextAnimationId++;const r=Array.isArray(e)?HE(e):e;return wM(this._renderer,null,i,"register",[r]),new ZH(i,this._renderer)}}return n.\u0275fac=function(e){return new(e||n)(te(Tl),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class ZH extends class a2{}{constructor(t,e){super(),this._id=t,this._renderer=e}create(t,e){return new XH(this._id,t,e||{},this._renderer)}}class XH{constructor(t,e,i,r){this.id=t,this.element=e,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",i)}_listen(t,e){return this._renderer.listen(this.element,`@@${this.id}:${t}`,e)}_command(t,...e){return wM(this._renderer,this.element,this.id,t,e)}onDone(t){this._listen("done",t)}onStart(t){this._listen("start",t)}onDestroy(t){this._listen("destroy",t)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(t){this._command("setPosition",t)}getPosition(){var t,e;return null!==(e=null===(t=this._renderer.engine.players[+this.id])||void 0===t?void 0:t.getPosition())&&void 0!==e?e:0}}function wM(n,t,e,i,r){return n.setProperty(t,`@@${e}:${i}`,r)}const CM="@.disabled";let JH=(()=>{class n{constructor(e,i,r){this.delegate=e,this.engine=i,this._zone=r,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),i.onRemovalComplete=(s,o)=>{const a=null==o?void 0:o.parentNode(s);a&&o.removeChild(a,s)}}createRenderer(e,i){const s=this.delegate.createRenderer(e,i);if(!(e&&i&&i.data&&i.data.animation)){let d=this._rendererCache.get(s);return d||(d=new DM("",s,this.engine),this._rendererCache.set(s,d)),d}const o=i.id,a=i.id+"-"+this._currentId;this._currentId++,this.engine.register(a,e);const l=d=>{Array.isArray(d)?d.forEach(l):this.engine.registerTrigger(o,a,e,d.name,d)};return i.data.animation.forEach(l),new ej(this,a,s,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(e,i,r){e>=0&&ei(r)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(s=>{const[o,a]=s;o(a)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([i,r]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return n.\u0275fac=function(e){return new(e||n)(te(Tl),te(ku),te(et))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class DM{constructor(t,e,i){this.namespaceId=t,this.delegate=e,this.engine=i,this.destroyNode=this.delegate.destroyNode?r=>e.destroyNode(r):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy()}createElement(t,e){return this.delegate.createElement(t,e)}createComment(t){return this.delegate.createComment(t)}createText(t){return this.delegate.createText(t)}appendChild(t,e){this.delegate.appendChild(t,e),this.engine.onInsert(this.namespaceId,e,t,!1)}insertBefore(t,e,i,r=!0){this.delegate.insertBefore(t,e,i),this.engine.onInsert(this.namespaceId,e,t,r)}removeChild(t,e,i){this.engine.onRemove(this.namespaceId,e,this.delegate,i)}selectRootElement(t,e){return this.delegate.selectRootElement(t,e)}parentNode(t){return this.delegate.parentNode(t)}nextSibling(t){return this.delegate.nextSibling(t)}setAttribute(t,e,i,r){this.delegate.setAttribute(t,e,i,r)}removeAttribute(t,e,i){this.delegate.removeAttribute(t,e,i)}addClass(t,e){this.delegate.addClass(t,e)}removeClass(t,e){this.delegate.removeClass(t,e)}setStyle(t,e,i,r){this.delegate.setStyle(t,e,i,r)}removeStyle(t,e,i){this.delegate.removeStyle(t,e,i)}setProperty(t,e,i){"@"==e.charAt(0)&&e==CM?this.disableAnimations(t,!!i):this.delegate.setProperty(t,e,i)}setValue(t,e){this.delegate.setValue(t,e)}listen(t,e,i){return this.delegate.listen(t,e,i)}disableAnimations(t,e){this.engine.disableAnimations(t,e)}}class ej extends DM{constructor(t,e,i,r){super(e,i,r),this.factory=t,this.namespaceId=e}setProperty(t,e,i){"@"==e.charAt(0)?"."==e.charAt(1)&&e==CM?this.disableAnimations(t,i=void 0===i||!!i):this.engine.process(this.namespaceId,t,e.slice(1),i):this.delegate.setProperty(t,e,i)}listen(t,e,i){if("@"==e.charAt(0)){const r=function tj(n){switch(n){case"body":return document.body;case"document":return document;case"window":return window;default:return n}}(t);let s=e.slice(1),o="";return"@"!=s.charAt(0)&&([s,o]=function nj(n){const t=n.indexOf(".");return[n.substring(0,t),n.slice(t+1)]}(s)),this.engine.listen(this.namespaceId,r,s,o,a=>{this.factory.scheduleListenerCallback(a._data||-1,i,a)})}return this.delegate.listen(t,e,i)}}const EM=[{provide:BE,useClass:QH},{provide:Ag,useFactory:function rj(){return new DH}},{provide:ku,useClass:(()=>{class n extends ku{constructor(e,i,r){super(e.body,i,r)}ngOnDestroy(){this.flush()}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(yg),te(Ag))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})()},{provide:Tl,useFactory:function sj(n,t,e){return new JH(n,t,e)},deps:[cu,ku,et]}],MM=[{provide:yg,useFactory:()=>new KH},{provide:fn,useValue:"BrowserAnimations"},...EM],oj=[{provide:yg,useClass:ZE},{provide:fn,useValue:"NoopAnimations"},...EM];let aj=(()=>{class n{static withConfig(e){return{ngModule:n,providers:e.disableAnimations?oj:MM}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:MM,imports:[PE]}),n})();const{isArray:lj}=Array,{getPrototypeOf:cj,prototype:dj,keys:uj}=Object;function xM(n){if(1===n.length){const t=n[0];if(lj(t))return{args:t,keys:null};if(function hj(n){return n&&"object"==typeof n&&cj(n)===dj}(t)){const e=uj(t);return{args:e.map(i=>t[i]),keys:e}}}return{args:n,keys:null}}const{isArray:fj}=Array;function Ng(n){return U(t=>function pj(n,t){return fj(t)?n(...t):n(t)}(n,t))}function SM(n,t){return n.reduce((e,i,r)=>(e[i]=t[r],e),{})}function kM(...n){const t=oy(n),{args:e,keys:i}=xM(n),r=new J(s=>{const{length:o}=e;if(!o)return void s.complete();const a=new Array(o);let l=o,c=o;for(let d=0;d{f||(f=!0,c--),a[d]=w},()=>l--,void 0,()=>{(!l||!f)&&(c||s.next(i?SM(i,a):a),s.complete())}))}});return t?r.pipe(Ng(t)):r}let TM=(()=>{class n{constructor(e,i){this._renderer=e,this._elementRef=i,this.onChange=r=>{},this.onTouched=()=>{}}setProperty(e,i){this._renderer.setProperty(this._elementRef.nativeElement,e,i)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}}return n.\u0275fac=function(e){return new(e||n)(x(Xr),x(Je))},n.\u0275dir=Me({type:n}),n})(),fo=(()=>{class n extends TM{}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275dir=Me({type:n,features:[Le]}),n})();const ai=new De("NgValueAccessor"),gj={provide:ai,useExisting:Ft(()=>Bg),multi:!0},vj=new De("CompositionEventMode");let Bg=(()=>{class n extends TM{constructor(e,i,r){super(e,i),this._compositionMode=r,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function _j(){const n=Sr()?Sr().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}())}writeValue(e){this.setProperty("value",null==e?"":e)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}}return n.\u0275fac=function(e){return new(e||n)(x(Xr),x(Je),x(vj,8))},n.\u0275dir=Me({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(e,i){1&e&&$e("input",function(s){return i._handleInput(s.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(s){return i._compositionEnd(s.target.value)})},features:[Xe([gj]),Le]}),n})();function ks(n){return null==n||("string"==typeof n||Array.isArray(n))&&0===n.length}function IM(n){return null!=n&&"number"==typeof n.length}const Nn=new De("NgValidators"),Ts=new De("NgAsyncValidators"),yj=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class Vg{static min(t){return function RM(n){return t=>{if(ks(t.value)||ks(n))return null;const e=parseFloat(t.value);return!isNaN(e)&&e{if(ks(t.value)||ks(n))return null;const e=parseFloat(t.value);return!isNaN(e)&&e>n?{max:{max:n,actual:t.value}}:null}}(t)}static required(t){return function OM(n){return ks(n.value)?{required:!0}:null}(t)}static requiredTrue(t){return function FM(n){return!0===n.value?null:{required:!0}}(t)}static email(t){return function LM(n){return ks(n.value)||yj.test(n.value)?null:{email:!0}}(t)}static minLength(t){return function NM(n){return t=>ks(t.value)||!IM(t.value)?null:t.value.lengthIM(t.value)&&t.value.length>n?{maxlength:{requiredLength:n,actualLength:t.value.length}}:null}(t)}static pattern(t){return function VM(n){if(!n)return Au;let t,e;return"string"==typeof n?(e="","^"!==n.charAt(0)&&(e+="^"),e+=n,"$"!==n.charAt(n.length-1)&&(e+="$"),t=new RegExp(e)):(e=n.toString(),t=n),i=>{if(ks(i.value))return null;const r=i.value;return t.test(r)?null:{pattern:{requiredPattern:e,actualValue:r}}}}(t)}static nullValidator(t){return null}static compose(t){return GM(t)}static composeAsync(t){return WM(t)}}function Au(n){return null}function HM(n){return null!=n}function jM(n){const t=Cl(n)?gn(n):n;return em(t),t}function UM(n){let t={};return n.forEach(e=>{t=null!=e?Object.assign(Object.assign({},t),e):t}),0===Object.keys(t).length?null:t}function zM(n,t){return t.map(e=>e(n))}function $M(n){return n.map(t=>function bj(n){return!n.validate}(t)?t:e=>t.validate(e))}function GM(n){if(!n)return null;const t=n.filter(HM);return 0==t.length?null:function(e){return UM(zM(e,t))}}function Hg(n){return null!=n?GM($M(n)):null}function WM(n){if(!n)return null;const t=n.filter(HM);return 0==t.length?null:function(e){return kM(zM(e,t).map(jM)).pipe(U(UM))}}function jg(n){return null!=n?WM($M(n)):null}function qM(n,t){return null===n?[t]:Array.isArray(n)?[...n,t]:[n,t]}function YM(n){return n._rawValidators}function KM(n){return n._rawAsyncValidators}function Ug(n){return n?Array.isArray(n)?n:[n]:[]}function Iu(n,t){return Array.isArray(n)?n.includes(t):n===t}function QM(n,t){const e=Ug(t);return Ug(n).forEach(r=>{Iu(e,r)||e.push(r)}),e}function ZM(n,t){return Ug(t).filter(e=>!Iu(n,e))}class XM{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(t){this._rawValidators=t||[],this._composedValidatorFn=Hg(this._rawValidators)}_setAsyncValidators(t){this._rawAsyncValidators=t||[],this._composedAsyncValidatorFn=jg(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(t){this._onDestroyCallbacks.push(t)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(t=>t()),this._onDestroyCallbacks=[]}reset(t){this.control&&this.control.reset(t)}hasError(t,e){return!!this.control&&this.control.hasError(t,e)}getError(t,e){return this.control?this.control.getError(t,e):null}}class Tr extends XM{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class li extends XM{get formDirective(){return null}get path(){return null}}let ex=(()=>{class n extends class JM{constructor(t){this._cd=t}get isTouched(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.touched)}get isUntouched(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.untouched)}get isPristine(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.pristine)}get isDirty(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.dirty)}get isValid(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.valid)}get isInvalid(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.invalid)}get isPending(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.pending)}get isSubmitted(){var t;return!(null===(t=this._cd)||void 0===t||!t.submitted)}}{constructor(e){super(e)}}return n.\u0275fac=function(e){return new(e||n)(x(Tr,2))},n.\u0275dir=Me({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(e,i){2&e&&At("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[Le]}),n})();const Yl="VALID",Pu="INVALID",Ca="PENDING",Kl="DISABLED";function Wg(n){return(Ou(n)?n.validators:n)||null}function nx(n){return Array.isArray(n)?Hg(n):n||null}function qg(n,t){return(Ou(t)?t.asyncValidators:n)||null}function ix(n){return Array.isArray(n)?jg(n):n||null}function Ou(n){return null!=n&&!Array.isArray(n)&&"object"==typeof n}class ox{constructor(t,e){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._rawValidators=t,this._rawAsyncValidators=e,this._composedValidatorFn=nx(this._rawValidators),this._composedAsyncValidatorFn=ix(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn}set validator(t){this._rawValidators=this._composedValidatorFn=t}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(t){this._rawAsyncValidators=this._composedAsyncValidatorFn=t}get parent(){return this._parent}get valid(){return this.status===Yl}get invalid(){return this.status===Pu}get pending(){return this.status==Ca}get disabled(){return this.status===Kl}get enabled(){return this.status!==Kl}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(t){this._rawValidators=t,this._composedValidatorFn=nx(t)}setAsyncValidators(t){this._rawAsyncValidators=t,this._composedAsyncValidatorFn=ix(t)}addValidators(t){this.setValidators(QM(t,this._rawValidators))}addAsyncValidators(t){this.setAsyncValidators(QM(t,this._rawAsyncValidators))}removeValidators(t){this.setValidators(ZM(t,this._rawValidators))}removeAsyncValidators(t){this.setAsyncValidators(ZM(t,this._rawAsyncValidators))}hasValidator(t){return Iu(this._rawValidators,t)}hasAsyncValidator(t){return Iu(this._rawAsyncValidators,t)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(t={}){this.touched=!0,this._parent&&!t.onlySelf&&this._parent.markAsTouched(t)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(t=>t.markAllAsTouched())}markAsUntouched(t={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(e=>{e.markAsUntouched({onlySelf:!0})}),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}markAsDirty(t={}){this.pristine=!1,this._parent&&!t.onlySelf&&this._parent.markAsDirty(t)}markAsPristine(t={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(e=>{e.markAsPristine({onlySelf:!0})}),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}markAsPending(t={}){this.status=Ca,!1!==t.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!t.onlySelf&&this._parent.markAsPending(t)}disable(t={}){const e=this._parentMarkedDirty(t.onlySelf);this.status=Kl,this.errors=null,this._forEachChild(i=>{i.disable(Object.assign(Object.assign({},t),{onlySelf:!0}))}),this._updateValue(),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach(i=>i(!0))}enable(t={}){const e=this._parentMarkedDirty(t.onlySelf);this.status=Yl,this._forEachChild(i=>{i.enable(Object.assign(Object.assign({},t),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent}),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(t){this._parent&&!t.onlySelf&&(this._parent.updateValueAndValidity(t),t.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(t){this._parent=t}getRawValue(){return this.value}updateValueAndValidity(t={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Yl||this.status===Ca)&&this._runAsyncValidator(t.emitEvent)),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!t.onlySelf&&this._parent.updateValueAndValidity(t)}_updateTreeValidity(t={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(t)),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Kl:Yl}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(t){if(this.asyncValidator){this.status=Ca,this._hasOwnPendingAsyncValidator=!0;const e=jM(this.asyncValidator(this));this._asyncValidationSubscription=e.subscribe(i=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(i,{emitEvent:t})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(t,e={}){this.errors=t,this._updateControlsErrors(!1!==e.emitEvent)}get(t){let e=t;return null==e||(Array.isArray(e)||(e=e.split(".")),0===e.length)?null:e.reduce((i,r)=>i&&i._find(r),this)}getError(t,e){const i=e?this.get(e):this;return i&&i.errors?i.errors[t]:null}hasError(t,e){return!!this.getError(t,e)}get root(){let t=this;for(;t._parent;)t=t._parent;return t}_updateControlsErrors(t){this.status=this._calculateStatus(),t&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(t)}_initObservables(){this.valueChanges=new je,this.statusChanges=new je}_calculateStatus(){return this._allControlsDisabled()?Kl:this.errors?Pu:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Ca)?Ca:this._anyControlsHaveStatus(Pu)?Pu:Yl}_anyControlsHaveStatus(t){return this._anyControls(e=>e.status===t)}_anyControlsDirty(){return this._anyControls(t=>t.dirty)}_anyControlsTouched(){return this._anyControls(t=>t.touched)}_updatePristine(t={}){this.pristine=!this._anyControlsDirty(),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}_updateTouched(t={}){this.touched=this._anyControlsTouched(),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}_registerOnCollectionChange(t){this._onCollectionChange=t}_setUpdateStrategy(t){Ou(t)&&null!=t.updateOn&&(this._updateOn=t.updateOn)}_parentMarkedDirty(t){return!t&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(t){return null}}class Yg extends ox{constructor(t,e,i){super(Wg(e),qg(i,e)),this.controls=t,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(t,e){return this.controls[t]?this.controls[t]:(this.controls[t]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(t,e,i={}){this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(t,e={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(t,e,i={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],e&&this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(t){return this.controls.hasOwnProperty(t)&&this.controls[t].enabled}setValue(t,e={}){(function sx(n,t,e){n._forEachChild((i,r)=>{if(void 0===e[r])throw new Be(1002,"")})})(this,0,t),Object.keys(t).forEach(i=>{(function rx(n,t,e){const i=n.controls;if(!(t?Object.keys(i):i).length)throw new Be(1e3,"");if(!i[e])throw new Be(1001,"")})(this,!0,i),this.controls[i].setValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(t,e={}){null!=t&&(Object.keys(t).forEach(i=>{const r=this.controls[i];r&&r.patchValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(t={},e={}){this._forEachChild((i,r)=>{i.reset(t[r],{onlySelf:!0,emitEvent:e.emitEvent})}),this._updatePristine(e),this._updateTouched(e),this.updateValueAndValidity(e)}getRawValue(){return this._reduceChildren({},(t,e,i)=>(t[i]=e.getRawValue(),t))}_syncPendingControls(){let t=this._reduceChildren(!1,(e,i)=>!!i._syncPendingControls()||e);return t&&this.updateValueAndValidity({onlySelf:!0}),t}_forEachChild(t){Object.keys(this.controls).forEach(e=>{const i=this.controls[e];i&&t(i,e)})}_setUpControls(){this._forEachChild(t=>{t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(t){for(const[e,i]of Object.entries(this.controls))if(this.contains(e)&&t(i))return!0;return!1}_reduceValue(){return this._reduceChildren({},(e,i,r)=>((i.enabled||this.disabled)&&(e[r]=i.value),e))}_reduceChildren(t,e){let i=t;return this._forEachChild((r,s)=>{i=e(i,r,s)}),i}_allControlsDisabled(){for(const t of Object.keys(this.controls))if(this.controls[t].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(t){return this.controls.hasOwnProperty(t)?this.controls[t]:null}}function Ql(n,t){var e,i;Kg(n,t),t.valueAccessor.writeValue(n.value),n.disabled&&(null===(i=(e=t.valueAccessor).setDisabledState)||void 0===i||i.call(e,!0)),function Aj(n,t){t.valueAccessor.registerOnChange(e=>{n._pendingValue=e,n._pendingChange=!0,n._pendingDirty=!0,"change"===n.updateOn&&ax(n,t)})}(n,t),function Rj(n,t){const e=(i,r)=>{t.valueAccessor.writeValue(i),r&&t.viewToModelUpdate(i)};n.registerOnChange(e),t._registerOnDestroy(()=>{n._unregisterOnChange(e)})}(n,t),function Ij(n,t){t.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,"blur"===n.updateOn&&n._pendingChange&&ax(n,t),"submit"!==n.updateOn&&n.markAsTouched()})}(n,t),function Tj(n,t){if(t.valueAccessor.setDisabledState){const e=i=>{t.valueAccessor.setDisabledState(i)};n.registerOnDisabledChange(e),t._registerOnDestroy(()=>{n._unregisterOnDisabledChange(e)})}}(n,t)}function Lu(n,t,e=!0){const i=()=>{};t.valueAccessor&&(t.valueAccessor.registerOnChange(i),t.valueAccessor.registerOnTouched(i)),Bu(n,t),n&&(t._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function Nu(n,t){n.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(t)})}function Kg(n,t){const e=YM(n);null!==t.validator?n.setValidators(qM(e,t.validator)):"function"==typeof e&&n.setValidators([e]);const i=KM(n);null!==t.asyncValidator?n.setAsyncValidators(qM(i,t.asyncValidator)):"function"==typeof i&&n.setAsyncValidators([i]);const r=()=>n.updateValueAndValidity();Nu(t._rawValidators,r),Nu(t._rawAsyncValidators,r)}function Bu(n,t){let e=!1;if(null!==n){if(null!==t.validator){const r=YM(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==t.validator);s.length!==r.length&&(e=!0,n.setValidators(s))}}if(null!==t.asyncValidator){const r=KM(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==t.asyncValidator);s.length!==r.length&&(e=!0,n.setAsyncValidators(s))}}}const i=()=>{};return Nu(t._rawValidators,i),Nu(t._rawAsyncValidators,i),e}function ax(n,t){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),t.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function lx(n,t){Kg(n,t)}function dx(n,t){n._syncPendingControls(),t.forEach(e=>{const i=e.control;"submit"===i.updateOn&&i._pendingChange&&(e.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}const Nj={provide:li,useExisting:Ft(()=>Xl)},Zl=(()=>Promise.resolve(null))();let Xl=(()=>{class n extends li{constructor(e,i){super(),this.submitted=!1,this._directives=new Set,this.ngSubmit=new je,this.form=new Yg({},Hg(e),jg(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(e){Zl.then(()=>{const i=this._findContainer(e.path);e.control=i.registerControl(e.name,e.control),Ql(e.control,e),e.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(e)})}getControl(e){return this.form.get(e.path)}removeControl(e){Zl.then(()=>{const i=this._findContainer(e.path);i&&i.removeControl(e.name),this._directives.delete(e)})}addFormGroup(e){Zl.then(()=>{const i=this._findContainer(e.path),r=new Yg({});lx(r,e),i.registerControl(e.name,r),r.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(e){Zl.then(()=>{const i=this._findContainer(e.path);i&&i.removeControl(e.name)})}getFormGroup(e){return this.form.get(e.path)}updateModel(e,i){Zl.then(()=>{this.form.get(e.path).setValue(i)})}setValue(e){this.control.setValue(e)}onSubmit(e){return this.submitted=!0,dx(this.form,this._directives),this.ngSubmit.emit(e),!1}onReset(){this.resetForm()}resetForm(e){this.form.reset(e),this.submitted=!1}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(e){return e.pop(),e.length?this.form.get(e):this.form}}return n.\u0275fac=function(e){return new(e||n)(x(Nn,10),x(Ts,10))},n.\u0275dir=Me({type:n,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(e,i){1&e&&$e("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Xe([Nj]),Le]}),n})();function ux(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}function hx(n){return"object"==typeof n&&null!==n&&2===Object.keys(n).length&&"value"in n&&"disabled"in n}const fx=class extends ox{constructor(t=null,e,i){super(Wg(e),qg(i,e)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(t),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Ou(e)&&(e.nonNullable||e.initialValueIsDefault)&&(this.defaultValue=hx(t)?t.value:t)}setValue(t,e={}){this.value=this._pendingValue=t,this._onChange.length&&!1!==e.emitModelToViewChange&&this._onChange.forEach(i=>i(this.value,!1!==e.emitViewToModelChange)),this.updateValueAndValidity(e)}patchValue(t,e={}){this.setValue(t,e)}reset(t=this.defaultValue,e={}){this._applyFormState(t),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),this._pendingChange=!1}_updateValue(){}_anyControls(t){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(t){this._onChange.push(t)}_unregisterOnChange(t){ux(this._onChange,t)}registerOnDisabledChange(t){this._onDisabledChange.push(t)}_unregisterOnDisabledChange(t){ux(this._onDisabledChange,t)}_forEachChild(t){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(t){hx(t)?(this.value=this._pendingValue=t.value,t.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=t}},Hj={provide:Tr,useExisting:Ft(()=>Xg)},gx=(()=>Promise.resolve(null))();let Xg=(()=>{class n extends Tr{constructor(e,i,r,s,o){super(),this._changeDetectorRef=o,this.control=new fx,this._registered=!1,this.update=new je,this._parent=e,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=function Zg(n,t){if(!t)return null;let e,i,r;return Array.isArray(t),t.forEach(s=>{s.constructor===Bg?e=s:function Fj(n){return Object.getPrototypeOf(n.constructor)===fo}(s)?i=s:r=s}),r||i||e||null}(0,s)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){const i=e.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),function Qg(n,t){if(!n.hasOwnProperty("model"))return!1;const e=n.model;return!!e.isFirstChange()||!Object.is(t,e.currentValue)}(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Ql(this.control,this),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(e){gx.then(()=>{var i;this.control.setValue(e,{emitViewToModelChange:!1}),null===(i=this._changeDetectorRef)||void 0===i||i.markForCheck()})}_updateDisabled(e){const i=e.isDisabled.currentValue,r=0!==i&&ts(i);gx.then(()=>{var s;r&&!this.control.disabled?this.control.disable():!r&&this.control.disabled&&this.control.enable(),null===(s=this._changeDetectorRef)||void 0===s||s.markForCheck()})}_getPath(e){return this._parent?function Fu(n,t){return[...t.path,n]}(e,this._parent):[e]}}return n.\u0275fac=function(e){return new(e||n)(x(li,9),x(Nn,10),x(Ts,10),x(ai,10),x(en,8))},n.\u0275dir=Me({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Xe([Hj]),Le,cn]}),n})(),vx=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const Jg=new De("NgModelWithFormControlWarning"),qj={provide:li,useExisting:Ft(()=>Jl)};let Jl=(()=>{class n extends li{constructor(e,i){super(),this.validators=e,this.asyncValidators=i,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new je,this._setValidators(e),this._setAsyncValidators(i)}ngOnChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Bu(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(e){const i=this.form.get(e.path);return Ql(i,e),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),i}getControl(e){return this.form.get(e.path)}removeControl(e){Lu(e.control||null,e,!1),function Lj(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}getFormArray(e){return this.form.get(e.path)}updateModel(e,i){this.form.get(e.path).setValue(i)}onSubmit(e){return this.submitted=!0,dx(this.form,this.directives),this.ngSubmit.emit(e),!1}onReset(){this.resetForm()}resetForm(e){this.form.reset(e),this.submitted=!1}_updateDomValue(){this.directives.forEach(e=>{const i=e.control,r=this.form.get(e.path);i!==r&&(Lu(i||null,e),(n=>n instanceof fx)(r)&&(Ql(r,e),e.control=r))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){const i=this.form.get(e.path);lx(i,e),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){if(this.form){const i=this.form.get(e.path);i&&function Pj(n,t){return Bu(n,t)}(i,e)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){Kg(this.form,this),this._oldForm&&Bu(this._oldForm,this)}_checkFormPresent(){}}return n.\u0275fac=function(e){return new(e||n)(x(Nn,10),x(Ts,10))},n.\u0275dir=Me({type:n,selectors:[["","formGroup",""]],hostBindings:function(e,i){1&e&&$e("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Xe([qj]),Le,cn]}),n})(),Fx=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[vx]}),n})(),h3=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Fx]}),n})(),f3=(()=>{class n{static withConfig(e){return{ngModule:n,providers:[{provide:Jg,useValue:e.warnOnNgModelWithFormControl}]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Fx]}),n})();function tt(...n){return gn(n,qa(n))}function Da(n,t){return ut(t)?Pn(n,t,1):Pn(n,1)}function yn(n,t){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>n.call(t,s,r++)&&i.next(s)))})}class Lx{}class Nx{}class Wi{constructor(t){this.normalizedNames=new Map,this.lazyUpdate=null,t?this.lazyInit="string"==typeof t?()=>{this.headers=new Map,t.split("\n").forEach(e=>{const i=e.indexOf(":");if(i>0){const r=e.slice(0,i),s=r.toLowerCase(),o=e.slice(i+1).trim();this.maybeSetNormalizedName(r,s),this.headers.has(s)?this.headers.get(s).push(o):this.headers.set(s,[o])}})}:()=>{this.headers=new Map,Object.keys(t).forEach(e=>{let i=t[e];const r=e.toLowerCase();"string"==typeof i&&(i=[i]),i.length>0&&(this.headers.set(r,i),this.maybeSetNormalizedName(e,r))})}:this.headers=new Map}has(t){return this.init(),this.headers.has(t.toLowerCase())}get(t){this.init();const e=this.headers.get(t.toLowerCase());return e&&e.length>0?e[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(t){return this.init(),this.headers.get(t.toLowerCase())||null}append(t,e){return this.clone({name:t,value:e,op:"a"})}set(t,e){return this.clone({name:t,value:e,op:"s"})}delete(t,e){return this.clone({name:t,value:e,op:"d"})}maybeSetNormalizedName(t,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,t)}init(){this.lazyInit&&(this.lazyInit instanceof Wi?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(t=>this.applyUpdate(t)),this.lazyUpdate=null))}copyFrom(t){t.init(),Array.from(t.headers.keys()).forEach(e=>{this.headers.set(e,t.headers.get(e)),this.normalizedNames.set(e,t.normalizedNames.get(e))})}clone(t){const e=new Wi;return e.lazyInit=this.lazyInit&&this.lazyInit instanceof Wi?this.lazyInit:this,e.lazyUpdate=(this.lazyUpdate||[]).concat([t]),e}applyUpdate(t){const e=t.name.toLowerCase();switch(t.op){case"a":case"s":let i=t.value;if("string"==typeof i&&(i=[i]),0===i.length)return;this.maybeSetNormalizedName(t.name,e);const r=("a"===t.op?this.headers.get(e):void 0)||[];r.push(...i),this.headers.set(e,r);break;case"d":const s=t.value;if(s){let o=this.headers.get(e);if(!o)return;o=o.filter(a=>-1===s.indexOf(a)),0===o.length?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,o)}else this.headers.delete(e),this.normalizedNames.delete(e)}}forEach(t){this.init(),Array.from(this.normalizedNames.keys()).forEach(e=>t(this.normalizedNames.get(e),this.headers.get(e)))}}class g3{encodeKey(t){return Bx(t)}encodeValue(t){return Bx(t)}decodeKey(t){return decodeURIComponent(t)}decodeValue(t){return decodeURIComponent(t)}}const v3=/%(\d[a-f0-9])/gi,y3={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Bx(n){return encodeURIComponent(n).replace(v3,(t,e)=>{var i;return null!==(i=y3[e])&&void 0!==i?i:t})}function Vu(n){return`${n}`}class As{constructor(t={}){if(this.updates=null,this.cloneFrom=null,this.encoder=t.encoder||new g3,t.fromString){if(t.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function _3(n,t){const e=new Map;return n.length>0&&n.replace(/^\?/,"").split("&").forEach(r=>{const s=r.indexOf("="),[o,a]=-1==s?[t.decodeKey(r),""]:[t.decodeKey(r.slice(0,s)),t.decodeValue(r.slice(s+1))],l=e.get(o)||[];l.push(a),e.set(o,l)}),e}(t.fromString,this.encoder)}else t.fromObject?(this.map=new Map,Object.keys(t.fromObject).forEach(e=>{const i=t.fromObject[e],r=Array.isArray(i)?i.map(Vu):[Vu(i)];this.map.set(e,r)})):this.map=null}has(t){return this.init(),this.map.has(t)}get(t){this.init();const e=this.map.get(t);return e?e[0]:null}getAll(t){return this.init(),this.map.get(t)||null}keys(){return this.init(),Array.from(this.map.keys())}append(t,e){return this.clone({param:t,value:e,op:"a"})}appendAll(t){const e=[];return Object.keys(t).forEach(i=>{const r=t[i];Array.isArray(r)?r.forEach(s=>{e.push({param:i,value:s,op:"a"})}):e.push({param:i,value:r,op:"a"})}),this.clone(e)}set(t,e){return this.clone({param:t,value:e,op:"s"})}delete(t,e){return this.clone({param:t,value:e,op:"d"})}toString(){return this.init(),this.keys().map(t=>{const e=this.encoder.encodeKey(t);return this.map.get(t).map(i=>e+"="+this.encoder.encodeValue(i)).join("&")}).filter(t=>""!==t).join("&")}clone(t){const e=new As({encoder:this.encoder});return e.cloneFrom=this.cloneFrom||this,e.updates=(this.updates||[]).concat(t),e}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(t=>this.map.set(t,this.cloneFrom.map.get(t))),this.updates.forEach(t=>{switch(t.op){case"a":case"s":const e=("a"===t.op?this.map.get(t.param):void 0)||[];e.push(Vu(t.value)),this.map.set(t.param,e);break;case"d":if(void 0===t.value){this.map.delete(t.param);break}{let i=this.map.get(t.param)||[];const r=i.indexOf(Vu(t.value));-1!==r&&i.splice(r,1),i.length>0?this.map.set(t.param,i):this.map.delete(t.param)}}}),this.cloneFrom=this.updates=null)}}class b3{constructor(){this.map=new Map}set(t,e){return this.map.set(t,e),this}get(t){return this.map.has(t)||this.map.set(t,t.defaultValue()),this.map.get(t)}delete(t){return this.map.delete(t),this}has(t){return this.map.has(t)}keys(){return this.map.keys()}}function Vx(n){return"undefined"!=typeof ArrayBuffer&&n instanceof ArrayBuffer}function Hx(n){return"undefined"!=typeof Blob&&n instanceof Blob}function jx(n){return"undefined"!=typeof FormData&&n instanceof FormData}class ec{constructor(t,e,i,r){let s;if(this.url=e,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=t.toUpperCase(),function w3(n){switch(n){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||r?(this.body=void 0!==i?i:null,s=r):s=i,s&&(this.reportProgress=!!s.reportProgress,this.withCredentials=!!s.withCredentials,s.responseType&&(this.responseType=s.responseType),s.headers&&(this.headers=s.headers),s.context&&(this.context=s.context),s.params&&(this.params=s.params)),this.headers||(this.headers=new Wi),this.context||(this.context=new b3),this.params){const o=this.params.toString();if(0===o.length)this.urlWithParams=e;else{const a=e.indexOf("?");this.urlWithParams=e+(-1===a?"?":aw.set(k,t.setHeaders[k]),c)),t.setParams&&(d=Object.keys(t.setParams).reduce((w,k)=>w.set(k,t.setParams[k]),d)),new ec(i,r,o,{params:d,headers:c,context:f,reportProgress:l,responseType:s,withCredentials:a})}}var Mn=(()=>((Mn=Mn||{})[Mn.Sent=0]="Sent",Mn[Mn.UploadProgress=1]="UploadProgress",Mn[Mn.ResponseHeader=2]="ResponseHeader",Mn[Mn.DownloadProgress=3]="DownloadProgress",Mn[Mn.Response=4]="Response",Mn[Mn.User=5]="User",Mn))();class o_{constructor(t,e=200,i="OK"){this.headers=t.headers||new Wi,this.status=void 0!==t.status?t.status:e,this.statusText=t.statusText||i,this.url=t.url||null,this.ok=this.status>=200&&this.status<300}}class a_ extends o_{constructor(t={}){super(t),this.type=Mn.ResponseHeader}clone(t={}){return new a_({headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class tc extends o_{constructor(t={}){super(t),this.type=Mn.Response,this.body=void 0!==t.body?t.body:null}clone(t={}){return new tc({body:void 0!==t.body?t.body:this.body,headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class l_ extends o_{constructor(t){super(t,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${t.url||"(unknown url)"}`:`Http failure response for ${t.url||"(unknown url)"}: ${t.status} ${t.statusText}`,this.error=t.error||null}}function c_(n,t){return{body:t,headers:n.headers,context:n.context,observe:n.observe,params:n.params,reportProgress:n.reportProgress,responseType:n.responseType,withCredentials:n.withCredentials}}let nc=(()=>{class n{constructor(e){this.handler=e}request(e,i,r={}){let s;if(e instanceof ec)s=e;else{let l,c;l=r.headers instanceof Wi?r.headers:new Wi(r.headers),r.params&&(c=r.params instanceof As?r.params:new As({fromObject:r.params})),s=new ec(e,i,void 0!==r.body?r.body:null,{headers:l,context:r.context,params:c,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials})}const o=tt(s).pipe(Da(l=>this.handler.handle(l)));if(e instanceof ec||"events"===r.observe)return o;const a=o.pipe(yn(l=>l instanceof tc));switch(r.observe||"body"){case"body":switch(s.responseType){case"arraybuffer":return a.pipe(U(l=>{if(null!==l.body&&!(l.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return l.body}));case"blob":return a.pipe(U(l=>{if(null!==l.body&&!(l.body instanceof Blob))throw new Error("Response is not a Blob.");return l.body}));case"text":return a.pipe(U(l=>{if(null!==l.body&&"string"!=typeof l.body)throw new Error("Response is not a string.");return l.body}));default:return a.pipe(U(l=>l.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${r.observe}}`)}}delete(e,i={}){return this.request("DELETE",e,i)}get(e,i={}){return this.request("GET",e,i)}head(e,i={}){return this.request("HEAD",e,i)}jsonp(e,i){return this.request("JSONP",e,{params:(new As).append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(e,i={}){return this.request("OPTIONS",e,i)}patch(e,i,r={}){return this.request("PATCH",e,c_(r,i))}post(e,i,r={}){return this.request("POST",e,c_(r,i))}put(e,i,r={}){return this.request("PUT",e,c_(r,i))}}return n.\u0275fac=function(e){return new(e||n)(te(Lx))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class Ux{constructor(t,e){this.next=t,this.interceptor=e}handle(t){return this.interceptor.intercept(t,this.next)}}const d_=new De("HTTP_INTERCEPTORS");let D3=(()=>{class n{intercept(e,i){return i.handle(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const E3=/^\)\]\}',?\n/;let zx=(()=>{class n{constructor(e){this.xhrFactory=e}handle(e){if("JSONP"===e.method)throw new Error("Attempted to construct Jsonp request without HttpClientJsonpModule installed.");return new J(i=>{const r=this.xhrFactory.build();if(r.open(e.method,e.urlWithParams),e.withCredentials&&(r.withCredentials=!0),e.headers.forEach((k,j)=>r.setRequestHeader(k,j.join(","))),e.headers.has("Accept")||r.setRequestHeader("Accept","application/json, text/plain, */*"),!e.headers.has("Content-Type")){const k=e.detectContentTypeHeader();null!==k&&r.setRequestHeader("Content-Type",k)}if(e.responseType){const k=e.responseType.toLowerCase();r.responseType="json"!==k?k:"text"}const s=e.serializeBody();let o=null;const a=()=>{if(null!==o)return o;const k=r.statusText||"OK",j=new Wi(r.getAllResponseHeaders()),K=function M3(n){return"responseURL"in n&&n.responseURL?n.responseURL:/^X-Request-URL:/m.test(n.getAllResponseHeaders())?n.getResponseHeader("X-Request-URL"):null}(r)||e.url;return o=new a_({headers:j,status:r.status,statusText:k,url:K}),o},l=()=>{let{headers:k,status:j,statusText:K,url:ae}=a(),ce=null;204!==j&&(ce=void 0===r.response?r.responseText:r.response),0===j&&(j=ce?200:0);let Te=j>=200&&j<300;if("json"===e.responseType&&"string"==typeof ce){const he=ce;ce=ce.replace(E3,"");try{ce=""!==ce?JSON.parse(ce):null}catch(Oe){ce=he,Te&&(Te=!1,ce={error:Oe,text:ce})}}Te?(i.next(new tc({body:ce,headers:k,status:j,statusText:K,url:ae||void 0})),i.complete()):i.error(new l_({error:ce,headers:k,status:j,statusText:K,url:ae||void 0}))},c=k=>{const{url:j}=a(),K=new l_({error:k,status:r.status||0,statusText:r.statusText||"Unknown Error",url:j||void 0});i.error(K)};let d=!1;const f=k=>{d||(i.next(a()),d=!0);let j={type:Mn.DownloadProgress,loaded:k.loaded};k.lengthComputable&&(j.total=k.total),"text"===e.responseType&&!!r.responseText&&(j.partialText=r.responseText),i.next(j)},w=k=>{let j={type:Mn.UploadProgress,loaded:k.loaded};k.lengthComputable&&(j.total=k.total),i.next(j)};return r.addEventListener("load",l),r.addEventListener("error",c),r.addEventListener("timeout",c),r.addEventListener("abort",c),e.reportProgress&&(r.addEventListener("progress",f),null!==s&&r.upload&&r.upload.addEventListener("progress",w)),r.send(s),i.next({type:Mn.Sent}),()=>{r.removeEventListener("error",c),r.removeEventListener("abort",c),r.removeEventListener("load",l),r.removeEventListener("timeout",c),e.reportProgress&&(r.removeEventListener("progress",f),null!==s&&r.upload&&r.upload.removeEventListener("progress",w)),r.readyState!==r.DONE&&r.abort()}})}}return n.\u0275fac=function(e){return new(e||n)(te(_E))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const u_=new De("XSRF_COOKIE_NAME"),h_=new De("XSRF_HEADER_NAME");class $x{}let p_,x3=(()=>{class n{constructor(e,i,r){this.doc=e,this.platform=i,this.cookieName=r,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const e=this.doc.cookie||"";return e!==this.lastCookieString&&(this.parseCount++,this.lastToken=sE(e,this.cookieName),this.lastCookieString=e),this.lastToken}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(Ud),te(u_))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),f_=(()=>{class n{constructor(e,i){this.tokenService=e,this.headerName=i}intercept(e,i){const r=e.url.toLowerCase();if("GET"===e.method||"HEAD"===e.method||r.startsWith("http://")||r.startsWith("https://"))return i.handle(e);const s=this.tokenService.getToken();return null!==s&&!e.headers.has(this.headerName)&&(e=e.clone({headers:e.headers.set(this.headerName,s)})),i.handle(e)}}return n.\u0275fac=function(e){return new(e||n)(te($x),te(h_))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),S3=(()=>{class n{constructor(e,i){this.backend=e,this.injector=i,this.chain=null}handle(e){if(null===this.chain){const i=this.injector.get(d_,[]);this.chain=i.reduceRight((r,s)=>new Ux(r,s),this.backend)}return this.chain.handle(e)}}return n.\u0275fac=function(e){return new(e||n)(te(Nx),te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),k3=(()=>{class n{static disable(){return{ngModule:n,providers:[{provide:f_,useClass:D3}]}}static withOptions(e={}){return{ngModule:n,providers:[e.cookieName?{provide:u_,useValue:e.cookieName}:[],e.headerName?{provide:h_,useValue:e.headerName}:[]]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[f_,{provide:d_,useExisting:f_,multi:!0},{provide:$x,useClass:x3},{provide:u_,useValue:"XSRF-TOKEN"},{provide:h_,useValue:"X-XSRF-TOKEN"}]}),n})(),T3=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[nc,{provide:Lx,useClass:S3},zx,{provide:Nx,useExisting:zx}],imports:[k3.withOptions({cookieName:"XSRF-TOKEN",headerName:"X-XSRF-TOKEN"})]}),n})();try{p_="undefined"!=typeof Intl&&Intl.v8BreakIterator}catch(n){p_=!1}let ic,mo,m_,bn=(()=>{class n{constructor(e){this._platformId=e,this.isBrowser=this._platformId?function CV(n){return n===mE}(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!p_)&&"undefined"!=typeof CSS&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT}}return n.\u0275fac=function(e){return new(e||n)(te(Ud))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Ar(n){return function A3(){if(null==ic&&"undefined"!=typeof window)try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>ic=!0}))}finally{ic=ic||!1}return ic}()?n:!!n.capture}function I3(){if(null==mo){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return mo=!1,mo;if("scrollBehavior"in document.documentElement.style)mo=!0;else{const n=Element.prototype.scrollTo;mo=!!n&&!/\{\s*\[native code\]\s*\}/.test(n.toString())}}return mo}function ju(n){if(function R3(){if(null==m_){const n="undefined"!=typeof document?document.head:null;m_=!(!n||!n.createShadowRoot&&!n.attachShadow)}return m_}()){const t=n.getRootNode?n.getRootNode():null;if("undefined"!=typeof ShadowRoot&&ShadowRoot&&t instanceof ShadowRoot)return t}return null}function g_(){let n="undefined"!=typeof document&&document?document.activeElement:null;for(;n&&n.shadowRoot;){const t=n.shadowRoot.activeElement;if(t===n)break;n=t}return n}function ur(n){return n.composedPath?n.composedPath()[0]:n.target}function __(){return"undefined"!=typeof __karma__&&!!__karma__||"undefined"!=typeof jasmine&&!!jasmine||"undefined"!=typeof jest&&!!jest||"undefined"!=typeof Mocha&&!!Mocha}function rt(n){return null!=n&&"false"!=`${n}`}function Ii(n,t=0){return function P3(n){return!isNaN(parseFloat(n))&&!isNaN(Number(n))}(n)?Number(n):t}function Uu(n){return Array.isArray(n)?n:[n]}function xn(n){return null==n?"":"string"==typeof n?n:`${n}px`}function Rn(n){return n instanceof Je?n.nativeElement:n}class mi extends ue{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}function gi(n,...t){return t.length?t.some(e=>n[e]):n.altKey||n.shiftKey||n.ctrlKey||n.metaKey}function wn(n,t,e){const i=ut(n)||t||e?{next:n,error:t,complete:e}:n;return i?Pe((r,s)=>{var o;null===(o=i.subscribe)||void 0===o||o.call(i);let a=!0;r.subscribe(_e(s,l=>{var c;null===(c=i.next)||void 0===c||c.call(i,l),s.next(l)},()=>{var l;a=!1,null===(l=i.complete)||void 0===l||l.call(i),s.complete()},l=>{var c;a=!1,null===(c=i.error)||void 0===c||c.call(i,l),s.error(l)},()=>{var l,c;a&&(null===(l=i.unsubscribe)||void 0===l||l.call(i)),null===(c=i.finalize)||void 0===c||c.call(i)}))}):N}class G3 extends X{constructor(t,e){super()}schedule(t,e=0){return this}}const zu={setInterval(n,t,...e){const{delegate:i}=zu;return null!=i&&i.setInterval?i.setInterval(n,t,...e):setInterval(n,t,...e)},clearInterval(n){const{delegate:t}=zu;return((null==t?void 0:t.clearInterval)||clearInterval)(n)},delegate:void 0};class D_ extends G3{constructor(t,e){super(t,e),this.scheduler=t,this.work=e,this.pending=!1}schedule(t,e=0){if(this.closed)return this;this.state=t;const i=this.id,r=this.scheduler;return null!=i&&(this.id=this.recycleAsyncId(r,i,e)),this.pending=!0,this.delay=e,this.id=this.id||this.requestAsyncId(r,this.id,e),this}requestAsyncId(t,e,i=0){return zu.setInterval(t.flush.bind(t,this),i)}recycleAsyncId(t,e,i=0){if(null!=i&&this.delay===i&&!1===this.pending)return e;zu.clearInterval(e)}execute(t,e){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const i=this._execute(t,e);if(i)return i;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(t,e){let r,i=!1;try{this.work(t)}catch(s){i=!0,r=s||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),r}unsubscribe(){if(!this.closed){const{id:t,scheduler:e}=this,{actions:i}=e;this.work=this.state=this.scheduler=null,this.pending=!1,V(i,this),null!=t&&(this.id=this.recycleAsyncId(e,t,null)),this.delay=null,super.unsubscribe()}}}const E_={now:()=>(E_.delegate||Date).now(),delegate:void 0};class sc{constructor(t,e=sc.now){this.schedulerActionCtor=t,this.now=e}schedule(t,e=0,i){return new this.schedulerActionCtor(this,t).schedule(i,e)}}sc.now=E_.now;class M_ extends sc{constructor(t,e=sc.now){super(t,e),this.actions=[],this._active=!1,this._scheduled=void 0}flush(t){const{actions:e}=this;if(this._active)return void e.push(t);let i;this._active=!0;do{if(i=t.execute(t.state,t.delay))break}while(t=e.shift());if(this._active=!1,i){for(;t=e.shift();)t.unsubscribe();throw i}}}const $u=new M_(D_),W3=$u;function x_(n,t=$u){return Pe((e,i)=>{let r=null,s=null,o=null;const a=()=>{if(r){r.unsubscribe(),r=null;const c=s;s=null,i.next(c)}};function l(){const c=o+n,d=t.now();if(d{s=c,o=t.now(),r||(r=t.schedule(l,n),i.add(r))},()=>{a(),i.complete()},void 0,()=>{s=r=null}))})}function S_(n){return yn((t,e)=>n<=e)}function k_(n,t=N){return n=null!=n?n:q3,Pe((e,i)=>{let r,s=!0;e.subscribe(_e(i,o=>{const a=t(o);(s||!n(r,a))&&(s=!1,r=a,i.next(o))}))})}function q3(n,t){return n===t}function Ot(n){return Pe((t,e)=>{di(n).subscribe(_e(e,()=>e.complete(),y)),!e.closed&&t.subscribe(e)})}let Kx=(()=>{class n{create(e){return"undefined"==typeof MutationObserver?null:new MutationObserver(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Y3=(()=>{class n{constructor(e){this._mutationObserverFactory=e,this._observedElements=new Map}ngOnDestroy(){this._observedElements.forEach((e,i)=>this._cleanupObserver(i))}observe(e){const i=Rn(e);return new J(r=>{const o=this._observeElement(i).subscribe(r);return()=>{o.unsubscribe(),this._unobserveElement(i)}})}_observeElement(e){if(this._observedElements.has(e))this._observedElements.get(e).count++;else{const i=new ue,r=this._mutationObserverFactory.create(s=>i.next(s));r&&r.observe(e,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(e,{observer:r,stream:i,count:1})}return this._observedElements.get(e).stream}_unobserveElement(e){this._observedElements.has(e)&&(this._observedElements.get(e).count--,this._observedElements.get(e).count||this._cleanupObserver(e))}_cleanupObserver(e){if(this._observedElements.has(e)){const{observer:i,stream:r}=this._observedElements.get(e);i&&i.disconnect(),r.complete(),this._observedElements.delete(e)}}}return n.\u0275fac=function(e){return new(e||n)(te(Kx))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),T_=(()=>{class n{constructor(e,i,r){this._contentObserver=e,this._elementRef=i,this._ngZone=r,this.event=new je,this._disabled=!1,this._currentSubscription=null}get disabled(){return this._disabled}set disabled(e){this._disabled=rt(e),this._disabled?this._unsubscribe():this._subscribe()}get debounce(){return this._debounce}set debounce(e){this._debounce=Ii(e),this._subscribe()}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();const e=this._contentObserver.observe(this._elementRef);this._ngZone.runOutsideAngular(()=>{this._currentSubscription=(this.debounce?e.pipe(x_(this.debounce)):e).subscribe(this.event)})}_unsubscribe(){var e;null===(e=this._currentSubscription)||void 0===e||e.unsubscribe()}}return n.\u0275fac=function(e){return new(e||n)(x(Y3),x(Je),x(et))},n.\u0275dir=Me({type:n,selectors:[["","cdkObserveContent",""]],inputs:{disabled:["cdkObserveContentDisabled","disabled"],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]}),n})(),Gu=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[Kx]}),n})();class Xx{constructor(t){this._items=t,this._activeItemIndex=-1,this._activeItem=null,this._wrap=!1,this._letterKeyStream=new ue,this._typeaheadSubscription=X.EMPTY,this._vertical=!0,this._allowedModifierKeys=[],this._homeAndEnd=!1,this._skipPredicateFn=e=>e.disabled,this._pressedLetters=[],this.tabOut=new ue,this.change=new ue,t instanceof ma&&t.changes.subscribe(e=>{if(this._activeItem){const r=e.toArray().indexOf(this._activeItem);r>-1&&r!==this._activeItemIndex&&(this._activeItemIndex=r)}})}skipPredicate(t){return this._skipPredicateFn=t,this}withWrap(t=!0){return this._wrap=t,this}withVerticalOrientation(t=!0){return this._vertical=t,this}withHorizontalOrientation(t){return this._horizontal=t,this}withAllowedModifierKeys(t){return this._allowedModifierKeys=t,this}withTypeAhead(t=200){return this._typeaheadSubscription.unsubscribe(),this._typeaheadSubscription=this._letterKeyStream.pipe(wn(e=>this._pressedLetters.push(e)),x_(t),yn(()=>this._pressedLetters.length>0),U(()=>this._pressedLetters.join(""))).subscribe(e=>{const i=this._getItemsArray();for(let r=1;r!t[s]||this._allowedModifierKeys.indexOf(s)>-1);switch(e){case 9:return void this.tabOut.next();case 40:if(this._vertical&&r){this.setNextItemActive();break}return;case 38:if(this._vertical&&r){this.setPreviousItemActive();break}return;case 39:if(this._horizontal&&r){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case 37:if(this._horizontal&&r){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case 36:if(this._homeAndEnd&&r){this.setFirstItemActive();break}return;case 35:if(this._homeAndEnd&&r){this.setLastItemActive();break}return;default:return void((r||gi(t,"shiftKey"))&&(t.key&&1===t.key.length?this._letterKeyStream.next(t.key.toLocaleUpperCase()):(e>=65&&e<=90||e>=48&&e<=57)&&this._letterKeyStream.next(String.fromCharCode(e))))}this._pressedLetters=[],t.preventDefault()}get activeItemIndex(){return this._activeItemIndex}get activeItem(){return this._activeItem}isTyping(){return this._pressedLetters.length>0}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._items.length-1,-1)}setNextItemActive(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(t){const e=this._getItemsArray(),i="number"==typeof t?t:e.indexOf(t),r=e[i];this._activeItem=null==r?null:r,this._activeItemIndex=i}_setActiveItemByDelta(t){this._wrap?this._setActiveInWrapMode(t):this._setActiveInDefaultMode(t)}_setActiveInWrapMode(t){const e=this._getItemsArray();for(let i=1;i<=e.length;i++){const r=(this._activeItemIndex+t*i+e.length)%e.length;if(!this._skipPredicateFn(e[r]))return void this.setActiveItem(r)}}_setActiveInDefaultMode(t){this._setActiveItemByIndex(this._activeItemIndex+t,t)}_setActiveItemByIndex(t,e){const i=this._getItemsArray();if(i[t]){for(;this._skipPredicateFn(i[t]);)if(!i[t+=e])return;this.setActiveItem(t)}}_getItemsArray(){return this._items instanceof ma?this._items.toArray():this._items}}class Z3 extends Xx{setActiveItem(t){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(t),this.activeItem&&this.activeItem.setActiveStyles()}}class Wu extends Xx{constructor(){super(...arguments),this._origin="program"}setFocusOrigin(t){return this._origin=t,this}setActiveItem(t){super.setActiveItem(t),this.activeItem&&this.activeItem.focus(this._origin)}}let qu=(()=>{class n{constructor(e){this._platform=e}isDisabled(e){return e.hasAttribute("disabled")}isVisible(e){return function J3(n){return!!(n.offsetWidth||n.offsetHeight||"function"==typeof n.getClientRects&&n.getClientRects().length)}(e)&&"visible"===getComputedStyle(e).visibility}isTabbable(e){if(!this._platform.isBrowser)return!1;const i=function X3(n){try{return n.frameElement}catch(t){return null}}(function aU(n){return n.ownerDocument&&n.ownerDocument.defaultView||window}(e));if(i&&(-1===eS(i)||!this.isVisible(i)))return!1;let r=e.nodeName.toLowerCase(),s=eS(e);return e.hasAttribute("contenteditable")?-1!==s:!("iframe"===r||"object"===r||this._platform.WEBKIT&&this._platform.IOS&&!function sU(n){let t=n.nodeName.toLowerCase(),e="input"===t&&n.type;return"text"===e||"password"===e||"select"===t||"textarea"===t}(e))&&("audio"===r?!!e.hasAttribute("controls")&&-1!==s:"video"===r?-1!==s&&(null!==s||this._platform.FIREFOX||e.hasAttribute("controls")):e.tabIndex>=0)}isFocusable(e,i){return function oU(n){return!function tU(n){return function iU(n){return"input"==n.nodeName.toLowerCase()}(n)&&"hidden"==n.type}(n)&&(function eU(n){let t=n.nodeName.toLowerCase();return"input"===t||"select"===t||"button"===t||"textarea"===t}(n)||function nU(n){return function rU(n){return"a"==n.nodeName.toLowerCase()}(n)&&n.hasAttribute("href")}(n)||n.hasAttribute("contenteditable")||Jx(n))}(e)&&!this.isDisabled(e)&&((null==i?void 0:i.ignoreVisibility)||this.isVisible(e))}}return n.\u0275fac=function(e){return new(e||n)(te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Jx(n){if(!n.hasAttribute("tabindex")||void 0===n.tabIndex)return!1;let t=n.getAttribute("tabindex");return!(!t||isNaN(parseInt(t,10)))}function eS(n){if(!Jx(n))return null;const t=parseInt(n.getAttribute("tabindex")||"",10);return isNaN(t)?-1:t}class lU{constructor(t,e,i,r,s=!1){this._element=t,this._checker=e,this._ngZone=i,this._document=r,this._hasAttached=!1,this.startAnchorListener=()=>this.focusLastTabbableElement(),this.endAnchorListener=()=>this.focusFirstTabbableElement(),this._enabled=!0,s||this.attachAnchors()}get enabled(){return this._enabled}set enabled(t){this._enabled=t,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}destroy(){const t=this._startAnchor,e=this._endAnchor;t&&(t.removeEventListener("focus",this.startAnchorListener),t.remove()),e&&(e.removeEventListener("focus",this.endAnchorListener),e.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusInitialElement(t)))})}focusFirstTabbableElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusFirstTabbableElement(t)))})}focusLastTabbableElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusLastTabbableElement(t)))})}_getRegionBoundary(t){const e=this._element.querySelectorAll(`[cdk-focus-region-${t}], [cdkFocusRegion${t}], [cdk-focus-${t}]`);return"start"==t?e.length?e[0]:this._getFirstTabbableElement(this._element):e.length?e[e.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(t){const e=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(e){if(!this._checker.isFocusable(e)){const i=this._getFirstTabbableElement(e);return null==i||i.focus(t),!!i}return e.focus(t),!0}return this.focusFirstTabbableElement(t)}focusFirstTabbableElement(t){const e=this._getRegionBoundary("start");return e&&e.focus(t),!!e}focusLastTabbableElement(t){const e=this._getRegionBoundary("end");return e&&e.focus(t),!!e}hasAttached(){return this._hasAttached}_getFirstTabbableElement(t){if(this._checker.isFocusable(t)&&this._checker.isTabbable(t))return t;const e=t.children;for(let i=0;i=0;i--){const r=e[i].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(e[i]):null;if(r)return r}return null}_createAnchor(){const t=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,t),t.classList.add("cdk-visually-hidden"),t.classList.add("cdk-focus-trap-anchor"),t.setAttribute("aria-hidden","true"),t}_toggleAnchorTabIndex(t,e){t?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex")}toggleAnchors(t){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}_executeOnStable(t){this._ngZone.isStable?t():this._ngZone.onStable.pipe(sn(1)).subscribe(t)}}let A_=(()=>{class n{constructor(e,i,r){this._checker=e,this._ngZone=i,this._document=r}create(e,i=!1){return new lU(e,this._checker,this._ngZone,this._document,i)}}return n.\u0275fac=function(e){return new(e||n)(te(qu),te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function I_(n){return 0===n.buttons||0===n.offsetX&&0===n.offsetY}function R_(n){const t=n.touches&&n.touches[0]||n.changedTouches&&n.changedTouches[0];return!(!t||-1!==t.identifier||null!=t.radiusX&&1!==t.radiusX||null!=t.radiusY&&1!==t.radiusY)}const cU=new De("cdk-input-modality-detector-options"),dU={ignoreKeys:[18,17,224,91,16]},xa=Ar({passive:!0,capture:!0});let uU=(()=>{class n{constructor(e,i,r,s){this._platform=e,this._mostRecentTarget=null,this._modality=new mi(null),this._lastTouchMs=0,this._onKeydown=o=>{var a,l;null!==(l=null===(a=this._options)||void 0===a?void 0:a.ignoreKeys)&&void 0!==l&&l.some(c=>c===o.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=ur(o))},this._onMousedown=o=>{Date.now()-this._lastTouchMs<650||(this._modality.next(I_(o)?"keyboard":"mouse"),this._mostRecentTarget=ur(o))},this._onTouchstart=o=>{R_(o)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=ur(o))},this._options=Object.assign(Object.assign({},dU),s),this.modalityDetected=this._modality.pipe(S_(1)),this.modalityChanged=this.modalityDetected.pipe(k_()),e.isBrowser&&i.runOutsideAngular(()=>{r.addEventListener("keydown",this._onKeydown,xa),r.addEventListener("mousedown",this._onMousedown,xa),r.addEventListener("touchstart",this._onTouchstart,xa)})}get mostRecentModality(){return this._modality.value}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,xa),document.removeEventListener("mousedown",this._onMousedown,xa),document.removeEventListener("touchstart",this._onTouchstart,xa))}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(et),te(ct),te(cU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const hU=new De("liveAnnouncerElement",{providedIn:"root",factory:function fU(){return null}}),pU=new De("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let P_=(()=>{class n{constructor(e,i,r,s){this._ngZone=i,this._defaultOptions=s,this._document=r,this._liveElement=e||this._createLiveElement()}announce(e,...i){const r=this._defaultOptions;let s,o;return 1===i.length&&"number"==typeof i[0]?o=i[0]:[s,o]=i,this.clear(),clearTimeout(this._previousTimeout),s||(s=r&&r.politeness?r.politeness:"polite"),null==o&&r&&(o=r.duration),this._liveElement.setAttribute("aria-live",s),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(a=>this._currentResolve=a)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=e,"number"==typeof o&&(this._previousTimeout=setTimeout(()=>this.clear(),o)),this._currentResolve(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){var e,i;clearTimeout(this._previousTimeout),null===(e=this._liveElement)||void 0===e||e.remove(),this._liveElement=null,null===(i=this._currentResolve)||void 0===i||i.call(this),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const e="cdk-live-announcer-element",i=this._document.getElementsByClassName(e),r=this._document.createElement("div");for(let s=0;s{class n{constructor(e,i,r,s,o){this._ngZone=e,this._platform=i,this._inputModalityDetector=r,this._origin=null,this._windowFocused=!1,this._originFromTouchInteraction=!1,this._elementInfo=new Map,this._monitoredElementCount=0,this._rootNodeFocusListenerCount=new Map,this._windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)},this._stopInputModalityDetector=new ue,this._rootNodeFocusAndBlurListener=a=>{const l=ur(a),c="focus"===a.type?this._onFocus:this._onBlur;for(let d=l;d;d=d.parentElement)c.call(this,a,d)},this._document=s,this._detectionMode=(null==o?void 0:o.detectionMode)||0}monitor(e,i=!1){const r=Rn(e);if(!this._platform.isBrowser||1!==r.nodeType)return tt(null);const s=ju(r)||this._getDocument(),o=this._elementInfo.get(r);if(o)return i&&(o.checkChildren=!0),o.subject;const a={checkChildren:i,subject:new ue,rootNode:s};return this._elementInfo.set(r,a),this._registerGlobalListeners(a),a.subject}stopMonitoring(e){const i=Rn(e),r=this._elementInfo.get(i);r&&(r.subject.complete(),this._setClasses(i),this._elementInfo.delete(i),this._removeGlobalListeners(r))}focusVia(e,i,r){const s=Rn(e);s===this._getDocument().activeElement?this._getClosestElementsInfo(s).forEach(([a,l])=>this._originChanged(a,i,l)):(this._setOrigin(i),"function"==typeof s.focus&&s.focus(r))}ngOnDestroy(){this._elementInfo.forEach((e,i)=>this.stopMonitoring(i))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(e){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(e)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:"program"}_shouldBeAttributedToTouch(e){return 1===this._detectionMode||!(null==e||!e.contains(this._inputModalityDetector._mostRecentTarget))}_setClasses(e,i){e.classList.toggle("cdk-focused",!!i),e.classList.toggle("cdk-touch-focused","touch"===i),e.classList.toggle("cdk-keyboard-focused","keyboard"===i),e.classList.toggle("cdk-mouse-focused","mouse"===i),e.classList.toggle("cdk-program-focused","program"===i)}_setOrigin(e,i=!1){this._ngZone.runOutsideAngular(()=>{this._origin=e,this._originFromTouchInteraction="touch"===e&&i,0===this._detectionMode&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(e,i){const r=this._elementInfo.get(i),s=ur(e);!r||!r.checkChildren&&i!==s||this._originChanged(i,this._getFocusOrigin(s),r)}_onBlur(e,i){const r=this._elementInfo.get(i);!r||r.checkChildren&&e.relatedTarget instanceof Node&&i.contains(e.relatedTarget)||(this._setClasses(i),this._emitOrigin(r,null))}_emitOrigin(e,i){e.subject.observers.length&&this._ngZone.run(()=>e.subject.next(i))}_registerGlobalListeners(e){if(!this._platform.isBrowser)return;const i=e.rootNode,r=this._rootNodeFocusListenerCount.get(i)||0;r||this._ngZone.runOutsideAngular(()=>{i.addEventListener("focus",this._rootNodeFocusAndBlurListener,Yu),i.addEventListener("blur",this._rootNodeFocusAndBlurListener,Yu)}),this._rootNodeFocusListenerCount.set(i,r+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(Ot(this._stopInputModalityDetector)).subscribe(s=>{this._setOrigin(s,!0)}))}_removeGlobalListeners(e){const i=e.rootNode;if(this._rootNodeFocusListenerCount.has(i)){const r=this._rootNodeFocusListenerCount.get(i);r>1?this._rootNodeFocusListenerCount.set(i,r-1):(i.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Yu),i.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Yu),this._rootNodeFocusListenerCount.delete(i))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(e,i,r){this._setClasses(e,i),this._emitOrigin(r,i),this._lastFocusOrigin=i}_getClosestElementsInfo(e){const i=[];return this._elementInfo.forEach((r,s)=>{(s===e||r.checkChildren&&s.contains(e))&&i.push([s,r])}),i}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(bn),te(uU),te(ct,8),te(mU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const nS="cdk-high-contrast-black-on-white",iS="cdk-high-contrast-white-on-black",O_="cdk-high-contrast-active";let rS=(()=>{class n{constructor(e,i){this._platform=e,this._document=i}getHighContrastMode(){if(!this._platform.isBrowser)return 0;const e=this._document.createElement("div");e.style.backgroundColor="rgb(1,2,3)",e.style.position="absolute",this._document.body.appendChild(e);const i=this._document.defaultView||window,r=i&&i.getComputedStyle?i.getComputedStyle(e):null,s=(r&&r.backgroundColor||"").replace(/ /g,"");switch(e.remove(),s){case"rgb(0,0,0)":return 2;case"rgb(255,255,255)":return 1}return 0}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const e=this._document.body.classList;e.remove(O_,nS,iS),this._hasCheckedHighContrastMode=!0;const i=this.getHighContrastMode();1===i?e.add(O_,nS):2===i&&e.add(O_,iS)}}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Ku=(()=>{class n{constructor(e){e._applyBodyHighContrastModeCssClasses()}}return n.\u0275fac=function(e){return new(e||n)(te(rS))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Gu]}),n})();function F_(n=0,t,e=W3){let i=-1;return null!=t&&(sy(t)?e=t:i=t),new J(r=>{let s=function gU(n){return n instanceof Date&&!isNaN(n)}(n)?+n-e.now():n;s<0&&(s=0);let o=0;return e.schedule(function(){r.closed||(r.next(o++),0<=i?this.schedule(void 0,i):r.complete())},s)})}const oc={schedule(n){let t=requestAnimationFrame,e=cancelAnimationFrame;const{delegate:i}=oc;i&&(t=i.requestAnimationFrame,e=i.cancelAnimationFrame);const r=t(s=>{e=void 0,n(s)});return new X(()=>null==e?void 0:e(r))},requestAnimationFrame(...n){const{delegate:t}=oc;return((null==t?void 0:t.requestAnimationFrame)||requestAnimationFrame)(...n)},cancelAnimationFrame(...n){const{delegate:t}=oc;return((null==t?void 0:t.cancelAnimationFrame)||cancelAnimationFrame)(...n)},delegate:void 0},sS=new class yU extends M_{flush(t){this._active=!0;const e=this._scheduled;this._scheduled=void 0;const{actions:i}=this;let r;t=t||i.shift();do{if(r=t.execute(t.state,t.delay))break}while((t=i[0])&&t.id===e&&i.shift());if(this._active=!1,r){for(;(t=i[0])&&t.id===e&&i.shift();)t.unsubscribe();throw r}}}(class vU extends D_{constructor(t,e){super(t,e),this.scheduler=t,this.work=e}requestAsyncId(t,e,i=0){return null!==i&&i>0?super.requestAsyncId(t,e,i):(t.actions.push(this),t._scheduled||(t._scheduled=oc.requestAnimationFrame(()=>t.flush(void 0))))}recycleAsyncId(t,e,i=0){if(null!=i&&i>0||null==i&&this.delay>0)return super.recycleAsyncId(t,e,i);t.actions.some(r=>r.id===e)||(oc.cancelAnimationFrame(e),t._scheduled=void 0)}}),bU=["addListener","removeListener"],wU=["addEventListener","removeEventListener"],CU=["on","off"];function _o(n,t,e,i){if(ut(e)&&(i=e,e=void 0),i)return _o(n,t,e).pipe(Ng(i));const[r,s]=function MU(n){return ut(n.addEventListener)&&ut(n.removeEventListener)}(n)?wU.map(o=>a=>n[o](t,a,e)):function DU(n){return ut(n.addListener)&&ut(n.removeListener)}(n)?bU.map(oS(n,t)):function EU(n){return ut(n.on)&&ut(n.off)}(n)?CU.map(oS(n,t)):[];if(!r&&Oi(n))return Pn(o=>_o(o,t,e))(di(n));if(!r)throw new TypeError("Invalid event target");return new J(o=>{const a=(...l)=>o.next(1s(a)})}function oS(n,t){return e=>i=>n[e](t,i)}let L_,xU=1;const Qu={};function aS(n){return n in Qu&&(delete Qu[n],!0)}const SU={setImmediate(n){const t=xU++;return Qu[t]=!0,L_||(L_=Promise.resolve()),L_.then(()=>aS(t)&&n()),t},clearImmediate(n){aS(n)}},{setImmediate:kU,clearImmediate:TU}=SU,Zu={setImmediate(...n){const{delegate:t}=Zu;return((null==t?void 0:t.setImmediate)||kU)(...n)},clearImmediate(n){const{delegate:t}=Zu;return((null==t?void 0:t.clearImmediate)||TU)(n)},delegate:void 0};new class IU extends M_{flush(t){this._active=!0;const e=this._scheduled;this._scheduled=void 0;const{actions:i}=this;let r;t=t||i.shift();do{if(r=t.execute(t.state,t.delay))break}while((t=i[0])&&t.id===e&&i.shift());if(this._active=!1,r){for(;(t=i[0])&&t.id===e&&i.shift();)t.unsubscribe();throw r}}}(class AU extends D_{constructor(t,e){super(t,e),this.scheduler=t,this.work=e}requestAsyncId(t,e,i=0){return null!==i&&i>0?super.requestAsyncId(t,e,i):(t.actions.push(this),t._scheduled||(t._scheduled=Zu.setImmediate(t.flush.bind(t,void 0))))}recycleAsyncId(t,e,i=0){if(null!=i&&i>0||null==i&&this.delay>0)return super.recycleAsyncId(t,e,i);t.actions.some(r=>r.id===e)||(Zu.clearImmediate(e),t._scheduled=void 0)}});function lS(n,t=$u){return function PU(n){return Pe((t,e)=>{let i=!1,r=null,s=null,o=!1;const a=()=>{if(null==s||s.unsubscribe(),s=null,i){i=!1;const c=r;r=null,e.next(c)}o&&e.complete()},l=()=>{s=null,o&&e.complete()};t.subscribe(_e(e,c=>{i=!0,r=c,s||di(n(c)).subscribe(s=_e(e,a,l))},()=>{o=!0,(!i||!s||s.closed)&&e.complete()}))})}(()=>F_(n,t))}const OU=new De("cdk-dir-doc",{providedIn:"root",factory:function FU(){return ld(ct)}}),LU=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let qi=(()=>{class n{constructor(e){if(this.value="ltr",this.change=new je,e){const r=e.documentElement?e.documentElement.dir:null;this.value=function NU(n){const t=(null==n?void 0:n.toLowerCase())||"";return"auto"===t&&"undefined"!=typeof navigator&&(null==navigator?void 0:navigator.language)?LU.test(navigator.language)?"rtl":"ltr":"rtl"===t?"rtl":"ltr"}((e.body?e.body.dir:null)||r||"ltr")}}ngOnDestroy(){this.change.complete()}}return n.\u0275fac=function(e){return new(e||n)(te(OU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ac=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),VU=(()=>{class n{constructor(e,i,r){this._ngZone=e,this._platform=i,this._scrolled=new ue,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=r}register(e){this.scrollContainers.has(e)||this.scrollContainers.set(e,e.elementScrolled().subscribe(()=>this._scrolled.next(e)))}deregister(e){const i=this.scrollContainers.get(e);i&&(i.unsubscribe(),this.scrollContainers.delete(e))}scrolled(e=20){return this._platform.isBrowser?new J(i=>{this._globalSubscription||this._addGlobalListener();const r=e>0?this._scrolled.pipe(lS(e)).subscribe(i):this._scrolled.subscribe(i);return this._scrolledCount++,()=>{r.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):tt()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((e,i)=>this.deregister(i)),this._scrolled.complete()}ancestorScrolled(e,i){const r=this.getAncestorScrollContainers(e);return this.scrolled(i).pipe(yn(s=>!s||r.indexOf(s)>-1))}getAncestorScrollContainers(e){const i=[];return this.scrollContainers.forEach((r,s)=>{this._scrollableContainsElement(s,e)&&i.push(s)}),i}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(e,i){let r=Rn(i),s=e.getElementRef().nativeElement;do{if(r==s)return!0}while(r=r.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>_o(this._getWindow().document,"scroll").subscribe(()=>this._scrolled.next()))}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(bn),te(ct,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ss=(()=>{class n{constructor(e,i,r){this._platform=e,this._change=new ue,this._changeListener=s=>{this._change.next(s)},this._document=r,i.runOutsideAngular(()=>{if(e.isBrowser){const s=this._getWindow();s.addEventListener("resize",this._changeListener),s.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const e=this._getWindow();e.removeEventListener("resize",this._changeListener),e.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const e={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),e}getViewportRect(){const e=this.getViewportScrollPosition(),{width:i,height:r}=this.getViewportSize();return{top:e.top,left:e.left,bottom:e.top+r,right:e.left+i,height:r,width:i}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const e=this._document,i=this._getWindow(),r=e.documentElement,s=r.getBoundingClientRect();return{top:-s.top||e.body.scrollTop||i.scrollY||r.scrollTop||0,left:-s.left||e.body.scrollLeft||i.scrollX||r.scrollLeft||0}}change(e=20){return e>0?this._change.pipe(lS(e)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const e=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:e.innerWidth,height:e.innerHeight}:{width:0,height:0}}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(et),te(ct,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Sa=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),N_=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ac,Sa,ac,Sa]}),n})();function B_(n,t,e){for(let i in t)if(t.hasOwnProperty(i)){const r=t[i];r?n.setProperty(i,r,null!=e&&e.has(i)?"important":""):n.removeProperty(i)}return n}function ka(n,t){const e=t?"":"none";B_(n.style,{"touch-action":t?"":"none","-webkit-user-drag":t?"":"none","-webkit-tap-highlight-color":t?"":"transparent","user-select":e,"-ms-user-select":e,"-webkit-user-select":e,"-moz-user-select":e})}function cS(n,t,e){B_(n.style,{position:t?"":"fixed",top:t?"":"0",opacity:t?"":"0",left:t?"":"-999em"},e)}function Xu(n,t){return t&&"none"!=t?n+" "+t:n}function dS(n){const t=n.toLowerCase().indexOf("ms")>-1?1:1e3;return parseFloat(n)*t}function V_(n,t){return n.getPropertyValue(t).split(",").map(i=>i.trim())}function H_(n){const t=n.getBoundingClientRect();return{top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.width,height:t.height,x:t.x,y:t.y}}function j_(n,t,e){const{top:i,bottom:r,left:s,right:o}=n;return e>=i&&e<=r&&t>=s&&t<=o}function lc(n,t,e){n.top+=t,n.bottom=n.top+n.height,n.left+=e,n.right=n.left+n.width}function uS(n,t,e,i){const{top:r,right:s,bottom:o,left:a,width:l,height:c}=n,d=l*t,f=c*t;return i>r-f&&ia-d&&e{this.positions.set(e,{scrollPosition:{top:e.scrollTop,left:e.scrollLeft},clientRect:H_(e)})})}handleScroll(t){const e=ur(t),i=this.positions.get(e);if(!i)return null;const r=i.scrollPosition;let s,o;if(e===this._document){const c=this.getViewportScrollPosition();s=c.top,o=c.left}else s=e.scrollTop,o=e.scrollLeft;const a=r.top-s,l=r.left-o;return this.positions.forEach((c,d)=>{c.clientRect&&e!==d&&e.contains(d)&&lc(c.clientRect,a,l)}),r.top=s,r.left=o,{top:a,left:l}}getViewportScrollPosition(){return{top:window.scrollY,left:window.scrollX}}}function fS(n){const t=n.cloneNode(!0),e=t.querySelectorAll("[id]"),i=n.nodeName.toLowerCase();t.removeAttribute("id");for(let r=0;r{if(this.beforeStarted.next(),this._handles.length){const l=this._getTargetHandle(a);l&&!this._disabledHandles.has(l)&&!this.disabled&&this._initializeDragSequence(l,a)}else this.disabled||this._initializeDragSequence(this._rootElement,a)},this._pointerMove=a=>{const l=this._getPointerPositionOnPage(a);if(!this._hasStartedDragging){if(Math.abs(l.x-this._pickupPositionOnPage.x)+Math.abs(l.y-this._pickupPositionOnPage.y)>=this._config.dragStartThreshold){const k=Date.now()>=this._dragStartTime+this._getDragStartDelay(a),j=this._dropContainer;if(!k)return void this._endDragSequence(a);(!j||!j.isDragging()&&!j.isReceiving())&&(a.preventDefault(),this._hasStartedDragging=!0,this._ngZone.run(()=>this._startDragSequence(a)))}return}a.preventDefault();const c=this._getConstrainedPointerPosition(l);if(this._hasMoved=!0,this._lastKnownPointerPosition=l,this._updatePointerDirectionDelta(c),this._dropContainer)this._updateActiveDropContainer(c,l);else{const d=this._activeTransform;d.x=c.x-this._pickupPositionOnPage.x+this._passiveTransform.x,d.y=c.y-this._pickupPositionOnPage.y+this._passiveTransform.y,this._applyRootElementTransform(d.x,d.y)}this._moveEvents.observers.length&&this._ngZone.run(()=>{this._moveEvents.next({source:this,pointerPosition:c,event:a,distance:this._getDragDistance(c),delta:this._pointerDirectionDelta})})},this._pointerUp=a=>{this._endDragSequence(a)},this._nativeDragStart=a=>{if(this._handles.length){const l=this._getTargetHandle(a);l&&!this._disabledHandles.has(l)&&!this.disabled&&a.preventDefault()}else this.disabled||a.preventDefault()},this.withRootElement(t).withParent(e.parentDragRef||null),this._parentPositions=new hS(i),o.registerDragItem(this)}get disabled(){return this._disabled||!(!this._dropContainer||!this._dropContainer.disabled)}set disabled(t){const e=rt(t);e!==this._disabled&&(this._disabled=e,this._toggleNativeDragInteractions(),this._handles.forEach(i=>ka(i,e)))}getPlaceholderElement(){return this._placeholder}getRootElement(){return this._rootElement}getVisibleElement(){return this.isDragging()?this.getPlaceholderElement():this.getRootElement()}withHandles(t){this._handles=t.map(i=>Rn(i)),this._handles.forEach(i=>ka(i,this.disabled)),this._toggleNativeDragInteractions();const e=new Set;return this._disabledHandles.forEach(i=>{this._handles.indexOf(i)>-1&&e.add(i)}),this._disabledHandles=e,this}withPreviewTemplate(t){return this._previewTemplate=t,this}withPlaceholderTemplate(t){return this._placeholderTemplate=t,this}withRootElement(t){const e=Rn(t);return e!==this._rootElement&&(this._rootElement&&this._removeRootElementListeners(this._rootElement),this._ngZone.runOutsideAngular(()=>{e.addEventListener("mousedown",this._pointerDown,Ju),e.addEventListener("touchstart",this._pointerDown,_S),e.addEventListener("dragstart",this._nativeDragStart,Ju)}),this._initialTransform=void 0,this._rootElement=e),"undefined"!=typeof SVGElement&&this._rootElement instanceof SVGElement&&(this._ownerSVGElement=this._rootElement.ownerSVGElement),this}withBoundaryElement(t){return this._boundaryElement=t?Rn(t):null,this._resizeSubscription.unsubscribe(),t&&(this._resizeSubscription=this._viewportRuler.change(10).subscribe(()=>this._containInsideBoundaryOnResize())),this}withParent(t){return this._parentDragRef=t,this}dispose(){var t,e;this._removeRootElementListeners(this._rootElement),this.isDragging()&&(null===(t=this._rootElement)||void 0===t||t.remove()),null===(e=this._anchor)||void 0===e||e.remove(),this._destroyPreview(),this._destroyPlaceholder(),this._dragDropRegistry.removeDragItem(this),this._removeSubscriptions(),this.beforeStarted.complete(),this.started.complete(),this.released.complete(),this.ended.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this._moveEvents.complete(),this._handles=[],this._disabledHandles.clear(),this._dropContainer=void 0,this._resizeSubscription.unsubscribe(),this._parentPositions.clear(),this._boundaryElement=this._rootElement=this._ownerSVGElement=this._placeholderTemplate=this._previewTemplate=this._anchor=this._parentDragRef=null}isDragging(){return this._hasStartedDragging&&this._dragDropRegistry.isDragging(this)}reset(){this._rootElement.style.transform=this._initialTransform||"",this._activeTransform={x:0,y:0},this._passiveTransform={x:0,y:0}}disableHandle(t){!this._disabledHandles.has(t)&&this._handles.indexOf(t)>-1&&(this._disabledHandles.add(t),ka(t,!0))}enableHandle(t){this._disabledHandles.has(t)&&(this._disabledHandles.delete(t),ka(t,this.disabled))}withDirection(t){return this._direction=t,this}_withDropContainer(t){this._dropContainer=t}getFreeDragPosition(){const t=this.isDragging()?this._activeTransform:this._passiveTransform;return{x:t.x,y:t.y}}setFreeDragPosition(t){return this._activeTransform={x:0,y:0},this._passiveTransform.x=t.x,this._passiveTransform.y=t.y,this._dropContainer||this._applyRootElementTransform(t.x,t.y),this}withPreviewContainer(t){return this._previewContainer=t,this}_sortFromLastPointerPosition(){const t=this._lastKnownPointerPosition;t&&this._dropContainer&&this._updateActiveDropContainer(this._getConstrainedPointerPosition(t),t)}_removeSubscriptions(){this._pointerMoveSubscription.unsubscribe(),this._pointerUpSubscription.unsubscribe(),this._scrollSubscription.unsubscribe()}_destroyPreview(){var t,e;null===(t=this._preview)||void 0===t||t.remove(),null===(e=this._previewRef)||void 0===e||e.destroy(),this._preview=this._previewRef=null}_destroyPlaceholder(){var t,e;null===(t=this._placeholder)||void 0===t||t.remove(),null===(e=this._placeholderRef)||void 0===e||e.destroy(),this._placeholder=this._placeholderRef=null}_endDragSequence(t){if(this._dragDropRegistry.isDragging(this)&&(this._removeSubscriptions(),this._dragDropRegistry.stopDragging(this),this._toggleNativeDragInteractions(),this._handles&&(this._rootElement.style.webkitTapHighlightColor=this._rootElementTapHighlight),this._hasStartedDragging))if(this.released.next({source:this,event:t}),this._dropContainer)this._dropContainer._stopScrolling(),this._animatePreviewToPlaceholder().then(()=>{this._cleanupDragArtifacts(t),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)});else{this._passiveTransform.x=this._activeTransform.x;const e=this._getPointerPositionOnPage(t);this._passiveTransform.y=this._activeTransform.y,this._ngZone.run(()=>{this.ended.next({source:this,distance:this._getDragDistance(e),dropPoint:e,event:t})}),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)}}_startDragSequence(t){cc(t)&&(this._lastTouchEventTime=Date.now()),this._toggleNativeDragInteractions();const e=this._dropContainer;if(e){const i=this._rootElement,r=i.parentNode,s=this._placeholder=this._createPlaceholderElement(),o=this._anchor=this._anchor||this._document.createComment(""),a=this._getShadowRoot();r.insertBefore(o,i),this._initialTransform=i.style.transform||"",this._preview=this._createPreviewElement(),cS(i,!1,U_),this._document.body.appendChild(r.replaceChild(s,i)),this._getPreviewInsertionPoint(r,a).appendChild(this._preview),this.started.next({source:this,event:t}),e.start(),this._initialContainer=e,this._initialIndex=e.getItemIndex(this)}else this.started.next({source:this,event:t}),this._initialContainer=this._initialIndex=void 0;this._parentPositions.cache(e?e.getScrollableParents():[])}_initializeDragSequence(t,e){this._parentDragRef&&e.stopPropagation();const i=this.isDragging(),r=cc(e),s=!r&&0!==e.button,o=this._rootElement,a=ur(e),l=!r&&this._lastTouchEventTime&&this._lastTouchEventTime+800>Date.now(),c=r?R_(e):I_(e);if(a&&a.draggable&&"mousedown"===e.type&&e.preventDefault(),i||s||l||c)return;if(this._handles.length){const w=o.style;this._rootElementTapHighlight=w.webkitTapHighlightColor||"",w.webkitTapHighlightColor="transparent"}this._hasStartedDragging=this._hasMoved=!1,this._removeSubscriptions(),this._pointerMoveSubscription=this._dragDropRegistry.pointerMove.subscribe(this._pointerMove),this._pointerUpSubscription=this._dragDropRegistry.pointerUp.subscribe(this._pointerUp),this._scrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(w=>this._updateOnScroll(w)),this._boundaryElement&&(this._boundaryRect=H_(this._boundaryElement));const d=this._previewTemplate;this._pickupPositionInElement=d&&d.template&&!d.matchSize?{x:0,y:0}:this._getPointerPositionInElement(t,e);const f=this._pickupPositionOnPage=this._lastKnownPointerPosition=this._getPointerPositionOnPage(e);this._pointerDirectionDelta={x:0,y:0},this._pointerPositionAtLastDirectionChange={x:f.x,y:f.y},this._dragStartTime=Date.now(),this._dragDropRegistry.startDragging(this,e)}_cleanupDragArtifacts(t){cS(this._rootElement,!0,U_),this._anchor.parentNode.replaceChild(this._rootElement,this._anchor),this._destroyPreview(),this._destroyPlaceholder(),this._boundaryRect=this._previewRect=this._initialTransform=void 0,this._ngZone.run(()=>{const e=this._dropContainer,i=e.getItemIndex(this),r=this._getPointerPositionOnPage(t),s=this._getDragDistance(r),o=e._isOverContainer(r.x,r.y);this.ended.next({source:this,distance:s,dropPoint:r,event:t}),this.dropped.next({item:this,currentIndex:i,previousIndex:this._initialIndex,container:e,previousContainer:this._initialContainer,isPointerOverContainer:o,distance:s,dropPoint:r,event:t}),e.drop(this,i,this._initialIndex,this._initialContainer,o,s,r),this._dropContainer=this._initialContainer})}_updateActiveDropContainer({x:t,y:e},{x:i,y:r}){let s=this._initialContainer._getSiblingContainerFromPosition(this,t,e);!s&&this._dropContainer!==this._initialContainer&&this._initialContainer._isOverContainer(t,e)&&(s=this._initialContainer),s&&s!==this._dropContainer&&this._ngZone.run(()=>{this.exited.next({item:this,container:this._dropContainer}),this._dropContainer.exit(this),this._dropContainer=s,this._dropContainer.enter(this,t,e,s===this._initialContainer&&s.sortingDisabled?this._initialIndex:void 0),this.entered.next({item:this,container:s,currentIndex:s.getItemIndex(this)})}),this.isDragging()&&(this._dropContainer._startScrollingIfNecessary(i,r),this._dropContainer._sortItem(this,t,e,this._pointerDirectionDelta),this._applyPreviewTransform(t-this._pickupPositionInElement.x,e-this._pickupPositionInElement.y))}_createPreviewElement(){const t=this._previewTemplate,e=this.previewClass,i=t?t.template:null;let r;if(i&&t){const s=t.matchSize?this._rootElement.getBoundingClientRect():null,o=t.viewContainer.createEmbeddedView(i,t.context);o.detectChanges(),r=yS(o,this._document),this._previewRef=o,t.matchSize?bS(r,s):r.style.transform=eh(this._pickupPositionOnPage.x,this._pickupPositionOnPage.y)}else{const s=this._rootElement;r=fS(s),bS(r,s.getBoundingClientRect()),this._initialTransform&&(r.style.transform=this._initialTransform)}return B_(r.style,{"pointer-events":"none",margin:"0",position:"fixed",top:"0",left:"0","z-index":`${this._config.zIndex||1e3}`},U_),ka(r,!1),r.classList.add("cdk-drag-preview"),r.setAttribute("dir",this._direction),e&&(Array.isArray(e)?e.forEach(s=>r.classList.add(s)):r.classList.add(e)),r}_animatePreviewToPlaceholder(){if(!this._hasMoved)return Promise.resolve();const t=this._placeholder.getBoundingClientRect();this._preview.classList.add("cdk-drag-animating"),this._applyPreviewTransform(t.left,t.top);const e=function jU(n){const t=getComputedStyle(n),e=V_(t,"transition-property"),i=e.find(a=>"transform"===a||"all"===a);if(!i)return 0;const r=e.indexOf(i),s=V_(t,"transition-duration"),o=V_(t,"transition-delay");return dS(s[r])+dS(o[r])}(this._preview);return 0===e?Promise.resolve():this._ngZone.runOutsideAngular(()=>new Promise(i=>{const r=o=>{var a;(!o||ur(o)===this._preview&&"transform"===o.propertyName)&&(null===(a=this._preview)||void 0===a||a.removeEventListener("transitionend",r),i(),clearTimeout(s))},s=setTimeout(r,1.5*e);this._preview.addEventListener("transitionend",r)}))}_createPlaceholderElement(){const t=this._placeholderTemplate,e=t?t.template:null;let i;return e?(this._placeholderRef=t.viewContainer.createEmbeddedView(e,t.context),this._placeholderRef.detectChanges(),i=yS(this._placeholderRef,this._document)):i=fS(this._rootElement),i.style.pointerEvents="none",i.classList.add("cdk-drag-placeholder"),i}_getPointerPositionInElement(t,e){const i=this._rootElement.getBoundingClientRect(),r=t===this._rootElement?null:t,s=r?r.getBoundingClientRect():i,o=cc(e)?e.targetTouches[0]:e,a=this._getViewportScrollPosition();return{x:s.left-i.left+(o.pageX-s.left-a.left),y:s.top-i.top+(o.pageY-s.top-a.top)}}_getPointerPositionOnPage(t){const e=this._getViewportScrollPosition(),i=cc(t)?t.touches[0]||t.changedTouches[0]||{pageX:0,pageY:0}:t,r=i.pageX-e.left,s=i.pageY-e.top;if(this._ownerSVGElement){const o=this._ownerSVGElement.getScreenCTM();if(o){const a=this._ownerSVGElement.createSVGPoint();return a.x=r,a.y=s,a.matrixTransform(o.inverse())}}return{x:r,y:s}}_getConstrainedPointerPosition(t){const e=this._dropContainer?this._dropContainer.lockAxis:null;let{x:i,y:r}=this.constrainPosition?this.constrainPosition(t,this):t;if("x"===this.lockAxis||"x"===e?r=this._pickupPositionOnPage.y:("y"===this.lockAxis||"y"===e)&&(i=this._pickupPositionOnPage.x),this._boundaryRect){const{x:s,y:o}=this._pickupPositionInElement,a=this._boundaryRect,{width:l,height:c}=this._getPreviewRect(),d=a.top+o,f=a.bottom-(c-o);i=vS(i,a.left+s,a.right-(l-s)),r=vS(r,d,f)}return{x:i,y:r}}_updatePointerDirectionDelta(t){const{x:e,y:i}=t,r=this._pointerDirectionDelta,s=this._pointerPositionAtLastDirectionChange,o=Math.abs(e-s.x),a=Math.abs(i-s.y);return o>this._config.pointerDirectionChangeThreshold&&(r.x=e>s.x?1:-1,s.x=e),a>this._config.pointerDirectionChangeThreshold&&(r.y=i>s.y?1:-1,s.y=i),r}_toggleNativeDragInteractions(){if(!this._rootElement||!this._handles)return;const t=this._handles.length>0||!this.isDragging();t!==this._nativeInteractionsEnabled&&(this._nativeInteractionsEnabled=t,ka(this._rootElement,t))}_removeRootElementListeners(t){t.removeEventListener("mousedown",this._pointerDown,Ju),t.removeEventListener("touchstart",this._pointerDown,_S),t.removeEventListener("dragstart",this._nativeDragStart,Ju)}_applyRootElementTransform(t,e){const i=eh(t,e),r=this._rootElement.style;null==this._initialTransform&&(this._initialTransform=r.transform&&"none"!=r.transform?r.transform:""),r.transform=Xu(i,this._initialTransform)}_applyPreviewTransform(t,e){var i;const r=null!==(i=this._previewTemplate)&&void 0!==i&&i.template?void 0:this._initialTransform,s=eh(t,e);this._preview.style.transform=Xu(s,r)}_getDragDistance(t){const e=this._pickupPositionOnPage;return e?{x:t.x-e.x,y:t.y-e.y}:{x:0,y:0}}_cleanupCachedDimensions(){this._boundaryRect=this._previewRect=void 0,this._parentPositions.clear()}_containInsideBoundaryOnResize(){let{x:t,y:e}=this._passiveTransform;if(0===t&&0===e||this.isDragging()||!this._boundaryElement)return;const i=this._boundaryElement.getBoundingClientRect(),r=this._rootElement.getBoundingClientRect();if(0===i.width&&0===i.height||0===r.width&&0===r.height)return;const s=i.left-r.left,o=r.right-i.right,a=i.top-r.top,l=r.bottom-i.bottom;i.width>r.width?(s>0&&(t+=s),o>0&&(t-=o)):t=0,i.height>r.height?(a>0&&(e+=a),l>0&&(e-=l)):e=0,(t!==this._passiveTransform.x||e!==this._passiveTransform.y)&&this.setFreeDragPosition({y:e,x:t})}_getDragStartDelay(t){const e=this.dragStartDelay;return"number"==typeof e?e:cc(t)?e.touch:e?e.mouse:0}_updateOnScroll(t){const e=this._parentPositions.handleScroll(t);if(e){const i=ur(t);this._boundaryRect&&i!==this._boundaryElement&&i.contains(this._boundaryElement)&&lc(this._boundaryRect,e.top,e.left),this._pickupPositionOnPage.x+=e.left,this._pickupPositionOnPage.y+=e.top,this._dropContainer||(this._activeTransform.x-=e.left,this._activeTransform.y-=e.top,this._applyRootElementTransform(this._activeTransform.x,this._activeTransform.y))}}_getViewportScrollPosition(){var t;return(null===(t=this._parentPositions.positions.get(this._document))||void 0===t?void 0:t.scrollPosition)||this._parentPositions.getViewportScrollPosition()}_getShadowRoot(){return void 0===this._cachedShadowRoot&&(this._cachedShadowRoot=ju(this._rootElement)),this._cachedShadowRoot}_getPreviewInsertionPoint(t,e){const i=this._previewContainer||"global";if("parent"===i)return t;if("global"===i){const r=this._document;return e||r.fullscreenElement||r.webkitFullscreenElement||r.mozFullScreenElement||r.msFullscreenElement||r.body}return Rn(i)}_getPreviewRect(){return(!this._previewRect||!this._previewRect.width&&!this._previewRect.height)&&(this._previewRect=(this._preview||this._rootElement).getBoundingClientRect()),this._previewRect}_getTargetHandle(t){return this._handles.find(e=>t.target&&(t.target===e||e.contains(t.target)))}}function eh(n,t){return`translate3d(${Math.round(n)}px, ${Math.round(t)}px, 0)`}function vS(n,t,e){return Math.max(t,Math.min(e,n))}function cc(n){return"t"===n.type[0]}function yS(n,t){const e=n.rootNodes;if(1===e.length&&e[0].nodeType===t.ELEMENT_NODE)return e[0];const i=t.createElement("div");return e.forEach(r=>i.appendChild(r)),i}function bS(n,t){n.style.width=`${t.width}px`,n.style.height=`${t.height}px`,n.style.transform=eh(t.left,t.top)}function dc(n,t){return Math.max(0,Math.min(t,n))}class WU{constructor(t,e,i,r,s){this._dragDropRegistry=e,this._ngZone=r,this._viewportRuler=s,this.disabled=!1,this.sortingDisabled=!1,this.autoScrollDisabled=!1,this.autoScrollStep=2,this.enterPredicate=()=>!0,this.sortPredicate=()=>!0,this.beforeStarted=new ue,this.entered=new ue,this.exited=new ue,this.dropped=new ue,this.sorted=new ue,this._isDragging=!1,this._itemPositions=[],this._previousSwap={drag:null,delta:0,overlaps:!1},this._draggables=[],this._siblings=[],this._orientation="vertical",this._activeSiblings=new Set,this._direction="ltr",this._viewportScrollSubscription=X.EMPTY,this._verticalScrollDirection=0,this._horizontalScrollDirection=0,this._stopScrollTimers=new ue,this._cachedShadowRoot=null,this._startScrollInterval=()=>{this._stopScrolling(),function _U(n=0,t=$u){return n<0&&(n=0),F_(n,n,t)}(0,sS).pipe(Ot(this._stopScrollTimers)).subscribe(()=>{const o=this._scrollNode,a=this.autoScrollStep;1===this._verticalScrollDirection?o.scrollBy(0,-a):2===this._verticalScrollDirection&&o.scrollBy(0,a),1===this._horizontalScrollDirection?o.scrollBy(-a,0):2===this._horizontalScrollDirection&&o.scrollBy(a,0)})},this.element=Rn(t),this._document=i,this.withScrollableParents([this.element]),e.registerDropContainer(this),this._parentPositions=new hS(i)}dispose(){this._stopScrolling(),this._stopScrollTimers.complete(),this._viewportScrollSubscription.unsubscribe(),this.beforeStarted.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this.sorted.complete(),this._activeSiblings.clear(),this._scrollNode=null,this._parentPositions.clear(),this._dragDropRegistry.removeDropContainer(this)}isDragging(){return this._isDragging}start(){this._draggingStarted(),this._notifyReceivingSiblings()}enter(t,e,i,r){let s;this._draggingStarted(),null==r?(s=this.sortingDisabled?this._draggables.indexOf(t):-1,-1===s&&(s=this._getItemIndexFromPointerPosition(t,e,i))):s=r;const o=this._activeDraggables,a=o.indexOf(t),l=t.getPlaceholderElement();let c=o[s];if(c===t&&(c=o[s+1]),!c&&(null==s||-1===s||s-1&&o.splice(a,1),c&&!this._dragDropRegistry.isDragging(c)){const d=c.getRootElement();d.parentElement.insertBefore(l,d),o.splice(s,0,t)}else Rn(this.element).appendChild(l),o.push(t);l.style.transform="",this._cacheItemPositions(),this._cacheParentPositions(),this._notifyReceivingSiblings(),this.entered.next({item:t,container:this,currentIndex:this.getItemIndex(t)})}exit(t){this._reset(),this.exited.next({item:t,container:this})}drop(t,e,i,r,s,o,a,l={}){this._reset(),this.dropped.next({item:t,currentIndex:e,previousIndex:i,container:this,previousContainer:r,isPointerOverContainer:s,distance:o,dropPoint:a,event:l})}withItems(t){const e=this._draggables;return this._draggables=t,t.forEach(i=>i._withDropContainer(this)),this.isDragging()&&(e.filter(r=>r.isDragging()).every(r=>-1===t.indexOf(r))?this._reset():this._cacheItems()),this}withDirection(t){return this._direction=t,this}connectedTo(t){return this._siblings=t.slice(),this}withOrientation(t){return this._orientation=t,this}withScrollableParents(t){const e=Rn(this.element);return this._scrollableElements=-1===t.indexOf(e)?[e,...t]:t.slice(),this}getScrollableParents(){return this._scrollableElements}getItemIndex(t){return this._isDragging?("horizontal"===this._orientation&&"rtl"===this._direction?this._itemPositions.slice().reverse():this._itemPositions).findIndex(i=>i.drag===t):this._draggables.indexOf(t)}isReceiving(){return this._activeSiblings.size>0}_sortItem(t,e,i,r){if(this.sortingDisabled||!this._clientRect||!uS(this._clientRect,.05,e,i))return;const s=this._itemPositions,o=this._getItemIndexFromPointerPosition(t,e,i,r);if(-1===o&&s.length>0)return;const a="horizontal"===this._orientation,l=s.findIndex(ae=>ae.drag===t),c=s[o],f=c.clientRect,w=l>o?1:-1,k=this._getItemOffsetPx(s[l].clientRect,f,w),j=this._getSiblingOffsetPx(l,s,w),K=s.slice();(function GU(n,t,e){const i=dc(t,n.length-1),r=dc(e,n.length-1);if(i===r)return;const s=n[i],o=r{if(K[ce]===ae)return;const Te=ae.drag===t,he=Te?k:j,Oe=Te?t.getPlaceholderElement():ae.drag.getRootElement();ae.offset+=he,a?(Oe.style.transform=Xu(`translate3d(${Math.round(ae.offset)}px, 0, 0)`,ae.initialTransform),lc(ae.clientRect,0,he)):(Oe.style.transform=Xu(`translate3d(0, ${Math.round(ae.offset)}px, 0)`,ae.initialTransform),lc(ae.clientRect,he,0))}),this._previousSwap.overlaps=j_(f,e,i),this._previousSwap.drag=c.drag,this._previousSwap.delta=a?r.x:r.y}_startScrollingIfNecessary(t,e){if(this.autoScrollDisabled)return;let i,r=0,s=0;if(this._parentPositions.positions.forEach((o,a)=>{a===this._document||!o.clientRect||i||uS(o.clientRect,.05,t,e)&&([r,s]=function qU(n,t,e,i){const r=DS(t,i),s=ES(t,e);let o=0,a=0;if(r){const l=n.scrollTop;1===r?l>0&&(o=1):n.scrollHeight-l>n.clientHeight&&(o=2)}if(s){const l=n.scrollLeft;1===s?l>0&&(a=1):n.scrollWidth-l>n.clientWidth&&(a=2)}return[o,a]}(a,o.clientRect,t,e),(r||s)&&(i=a))}),!r&&!s){const{width:o,height:a}=this._viewportRuler.getViewportSize(),l={width:o,height:a,top:0,right:o,bottom:a,left:0};r=DS(l,e),s=ES(l,t),i=window}i&&(r!==this._verticalScrollDirection||s!==this._horizontalScrollDirection||i!==this._scrollNode)&&(this._verticalScrollDirection=r,this._horizontalScrollDirection=s,this._scrollNode=i,(r||s)&&i?this._ngZone.runOutsideAngular(this._startScrollInterval):this._stopScrolling())}_stopScrolling(){this._stopScrollTimers.next()}_draggingStarted(){const t=Rn(this.element).style;this.beforeStarted.next(),this._isDragging=!0,this._initialScrollSnap=t.msScrollSnapType||t.scrollSnapType||"",t.scrollSnapType=t.msScrollSnapType="none",this._cacheItems(),this._viewportScrollSubscription.unsubscribe(),this._listenToScrollEvents()}_cacheParentPositions(){const t=Rn(this.element);this._parentPositions.cache(this._scrollableElements),this._clientRect=this._parentPositions.positions.get(t).clientRect}_cacheItemPositions(){const t="horizontal"===this._orientation;this._itemPositions=this._activeDraggables.map(e=>{const i=e.getVisibleElement();return{drag:e,offset:0,initialTransform:i.style.transform||"",clientRect:H_(i)}}).sort((e,i)=>t?e.clientRect.left-i.clientRect.left:e.clientRect.top-i.clientRect.top)}_reset(){this._isDragging=!1;const t=Rn(this.element).style;t.scrollSnapType=t.msScrollSnapType=this._initialScrollSnap,this._activeDraggables.forEach(e=>{var i;const r=e.getRootElement();if(r){const s=null===(i=this._itemPositions.find(o=>o.drag===e))||void 0===i?void 0:i.initialTransform;r.style.transform=s||""}}),this._siblings.forEach(e=>e._stopReceiving(this)),this._activeDraggables=[],this._itemPositions=[],this._previousSwap.drag=null,this._previousSwap.delta=0,this._previousSwap.overlaps=!1,this._stopScrolling(),this._viewportScrollSubscription.unsubscribe(),this._parentPositions.clear()}_getSiblingOffsetPx(t,e,i){const r="horizontal"===this._orientation,s=e[t].clientRect,o=e[t+-1*i];let a=s[r?"width":"height"]*i;if(o){const l=r?"left":"top",c=r?"right":"bottom";-1===i?a-=o.clientRect[l]-s[c]:a+=s[l]-o.clientRect[c]}return a}_getItemOffsetPx(t,e,i){const r="horizontal"===this._orientation;let s=r?e.left-t.left:e.top-t.top;return-1===i&&(s+=r?e.width-t.width:e.height-t.height),s}_shouldEnterAsFirstChild(t,e){if(!this._activeDraggables.length)return!1;const i=this._itemPositions,r="horizontal"===this._orientation;if(i[0].drag!==this._activeDraggables[0]){const o=i[i.length-1].clientRect;return r?t>=o.right:e>=o.bottom}{const o=i[0].clientRect;return r?t<=o.left:e<=o.top}}_getItemIndexFromPointerPosition(t,e,i,r){const s="horizontal"===this._orientation,o=this._itemPositions.findIndex(({drag:a,clientRect:l})=>{if(a===t)return!1;if(r){const c=s?r.x:r.y;if(a===this._previousSwap.drag&&this._previousSwap.overlaps&&c===this._previousSwap.delta)return!1}return s?e>=Math.floor(l.left)&&e=Math.floor(l.top)&&ir._canReceive(t,e,i))}_canReceive(t,e,i){if(!this._clientRect||!j_(this._clientRect,e,i)||!this.enterPredicate(t,this))return!1;const r=this._getShadowRoot().elementFromPoint(e,i);if(!r)return!1;const s=Rn(this.element);return r===s||s.contains(r)}_startReceiving(t,e){const i=this._activeSiblings;!i.has(t)&&e.every(r=>this.enterPredicate(r,this)||this._draggables.indexOf(r)>-1)&&(i.add(t),this._cacheParentPositions(),this._listenToScrollEvents())}_stopReceiving(t){this._activeSiblings.delete(t),this._viewportScrollSubscription.unsubscribe()}_listenToScrollEvents(){this._viewportScrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(t=>{if(this.isDragging()){const e=this._parentPositions.handleScroll(t);e&&(this._itemPositions.forEach(({clientRect:i})=>{lc(i,e.top,e.left)}),this._itemPositions.forEach(({drag:i})=>{this._dragDropRegistry.isDragging(i)&&i._sortFromLastPointerPosition()}))}else this.isReceiving()&&this._cacheParentPositions()})}_getShadowRoot(){if(!this._cachedShadowRoot){const t=ju(Rn(this.element));this._cachedShadowRoot=t||this._document}return this._cachedShadowRoot}_notifyReceivingSiblings(){const t=this._activeDraggables.filter(e=>e.isDragging());this._siblings.forEach(e=>e._startReceiving(this,t))}}function DS(n,t){const{top:e,bottom:i,height:r}=n,s=.05*r;return t>=e-s&&t<=e+s?1:t>=i-s&&t<=i+s?2:0}function ES(n,t){const{left:e,right:i,width:r}=n,s=.05*r;return t>=e-s&&t<=e+s?1:t>=i-s&&t<=i+s?2:0}const th=Ar({passive:!1,capture:!0});let YU=(()=>{class n{constructor(e,i){this._ngZone=e,this._dropInstances=new Set,this._dragInstances=new Set,this._activeDragInstances=[],this._globalListeners=new Map,this._draggingPredicate=r=>r.isDragging(),this.pointerMove=new ue,this.pointerUp=new ue,this.scroll=new ue,this._preventDefaultWhileDragging=r=>{this._activeDragInstances.length>0&&r.preventDefault()},this._persistentTouchmoveListener=r=>{this._activeDragInstances.length>0&&(this._activeDragInstances.some(this._draggingPredicate)&&r.preventDefault(),this.pointerMove.next(r))},this._document=i}registerDropContainer(e){this._dropInstances.has(e)||this._dropInstances.add(e)}registerDragItem(e){this._dragInstances.add(e),1===this._dragInstances.size&&this._ngZone.runOutsideAngular(()=>{this._document.addEventListener("touchmove",this._persistentTouchmoveListener,th)})}removeDropContainer(e){this._dropInstances.delete(e)}removeDragItem(e){this._dragInstances.delete(e),this.stopDragging(e),0===this._dragInstances.size&&this._document.removeEventListener("touchmove",this._persistentTouchmoveListener,th)}startDragging(e,i){if(!(this._activeDragInstances.indexOf(e)>-1)&&(this._activeDragInstances.push(e),1===this._activeDragInstances.length)){const r=i.type.startsWith("touch");this._globalListeners.set(r?"touchend":"mouseup",{handler:s=>this.pointerUp.next(s),options:!0}).set("scroll",{handler:s=>this.scroll.next(s),options:!0}).set("selectstart",{handler:this._preventDefaultWhileDragging,options:th}),r||this._globalListeners.set("mousemove",{handler:s=>this.pointerMove.next(s),options:th}),this._ngZone.runOutsideAngular(()=>{this._globalListeners.forEach((s,o)=>{this._document.addEventListener(o,s.handler,s.options)})})}}stopDragging(e){const i=this._activeDragInstances.indexOf(e);i>-1&&(this._activeDragInstances.splice(i,1),0===this._activeDragInstances.length&&this._clearGlobalListeners())}isDragging(e){return this._activeDragInstances.indexOf(e)>-1}scrolled(e){const i=[this.scroll];return e&&e!==this._document&&i.push(new J(r=>this._ngZone.runOutsideAngular(()=>{const o=a=>{this._activeDragInstances.length&&r.next(a)};return e.addEventListener("scroll",o,!0),()=>{e.removeEventListener("scroll",o,!0)}}))),$n(...i)}ngOnDestroy(){this._dragInstances.forEach(e=>this.removeDragItem(e)),this._dropInstances.forEach(e=>this.removeDropContainer(e)),this._clearGlobalListeners(),this.pointerMove.complete(),this.pointerUp.complete()}_clearGlobalListeners(){this._globalListeners.forEach((e,i)=>{this._document.removeEventListener(i,e.handler,e.options)}),this._globalListeners.clear()}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const KU={dragStartThreshold:5,pointerDirectionChangeThreshold:5};let QU=(()=>{class n{constructor(e,i,r,s){this._document=e,this._ngZone=i,this._viewportRuler=r,this._dragDropRegistry=s}createDrag(e,i=KU){return new $U(e,i,this._document,this._ngZone,this._viewportRuler,this._dragDropRegistry)}createDropList(e){return new WU(e,this._dragDropRegistry,this._document,this._ngZone,this._viewportRuler)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(et),te(ss),te(YU))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ZU=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[QU],imports:[Sa]}),n})();function nh(...n){return function XU(){return To(1)}()(gn(n,qa(n)))}function Qn(...n){const t=qa(n);return Pe((e,i)=>{(t?nh(n,e,t):nh(n,e)).subscribe(i)})}function JU(n,t){if(1&n&&kt(0,"mat-pseudo-checkbox",4),2&n){const e=lt();Ae("state",e.selected?"checked":"unchecked")("disabled",e.disabled)}}function ez(n,t){if(1&n&&(fe(0,"span",5),Ue(1),we()),2&n){const e=lt();Ee(1),Ln("(",e.group.label,")")}}const tz=["*"],sz=new De("mat-sanity-checks",{providedIn:"root",factory:function rz(){return!0}});let ht=(()=>{class n{constructor(e,i,r){this._sanityChecks=i,this._document=r,this._hasDoneGlobalChecks=!1,e._applyBodyHighContrastModeCssClasses(),this._hasDoneGlobalChecks||(this._hasDoneGlobalChecks=!0)}_checkIsEnabled(e){return!__()&&("boolean"==typeof this._sanityChecks?this._sanityChecks:!!this._sanityChecks[e])}}return n.\u0275fac=function(e){return new(e||n)(te(rS),te(sz,8),te(ct))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ac,ac]}),n})();function uc(n){return class extends n{constructor(...t){super(...t),this._disabled=!1}get disabled(){return this._disabled}set disabled(t){this._disabled=rt(t)}}}function vo(n,t){return class extends n{constructor(...e){super(...e),this.defaultColor=t,this.color=t}get color(){return this._color}set color(e){const i=e||this.defaultColor;i!==this._color&&(this._color&&this._elementRef.nativeElement.classList.remove(`mat-${this._color}`),i&&this._elementRef.nativeElement.classList.add(`mat-${i}`),this._color=i)}}}function Rs(n){return class extends n{constructor(...t){super(...t),this._disableRipple=!1}get disableRipple(){return this._disableRipple}set disableRipple(t){this._disableRipple=rt(t)}}}function yo(n,t=0){return class extends n{constructor(...e){super(...e),this._tabIndex=t,this.defaultTabIndex=t}get tabIndex(){return this.disabled?-1:this._tabIndex}set tabIndex(e){this._tabIndex=null!=e?Ii(e):this.defaultTabIndex}}}function SS(n){return class extends n{constructor(...t){super(...t),this.errorState=!1}updateErrorState(){const t=this.errorState,s=(this.errorStateMatcher||this._defaultErrorStateMatcher).isErrorState(this.ngControl?this.ngControl.control:null,this._parentFormGroup||this._parentForm);s!==t&&(this.errorState=s,this.stateChanges.next())}}}const oz=new De("MAT_DATE_LOCALE",{providedIn:"root",factory:function az(){return ld(Er)}});class Ir{constructor(){this._localeChanges=new ue,this.localeChanges=this._localeChanges}getValidDateOrNull(t){return this.isDateInstance(t)&&this.isValid(t)?t:null}deserialize(t){return null==t||this.isDateInstance(t)&&this.isValid(t)?t:this.invalid()}setLocale(t){this.locale=t,this._localeChanges.next()}compareDate(t,e){return this.getYear(t)-this.getYear(e)||this.getMonth(t)-this.getMonth(e)||this.getDate(t)-this.getDate(e)}sameDate(t,e){if(t&&e){let i=this.isValid(t),r=this.isValid(e);return i&&r?!this.compareDate(t,e):i==r}return t==e}clampDate(t,e,i){return e&&this.compareDate(t,e)<0?e:i&&this.compareDate(t,i)>0?i:t}}const z_=new De("mat-date-formats"),lz=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;function $_(n,t){const e=Array(n);for(let i=0;i{class n extends Ir{constructor(e,i){super(),this.useUtcForDisplay=!1,super.setLocale(e)}getYear(e){return e.getFullYear()}getMonth(e){return e.getMonth()}getDate(e){return e.getDate()}getDayOfWeek(e){return e.getDay()}getMonthNames(e){const i=new Intl.DateTimeFormat(this.locale,{month:e,timeZone:"utc"});return $_(12,r=>this._format(i,new Date(2017,r,1)))}getDateNames(){const e=new Intl.DateTimeFormat(this.locale,{day:"numeric",timeZone:"utc"});return $_(31,i=>this._format(e,new Date(2017,0,i+1)))}getDayOfWeekNames(e){const i=new Intl.DateTimeFormat(this.locale,{weekday:e,timeZone:"utc"});return $_(7,r=>this._format(i,new Date(2017,0,r+1)))}getYearName(e){const i=new Intl.DateTimeFormat(this.locale,{year:"numeric",timeZone:"utc"});return this._format(i,e)}getFirstDayOfWeek(){return 0}getNumDaysInMonth(e){return this.getDate(this._createDateWithOverflow(this.getYear(e),this.getMonth(e)+1,0))}clone(e){return new Date(e.getTime())}createDate(e,i,r){let s=this._createDateWithOverflow(e,i,r);return s.getMonth(),s}today(){return new Date}parse(e){return"number"==typeof e?new Date(e):e?new Date(Date.parse(e)):null}format(e,i){if(!this.isValid(e))throw Error("NativeDateAdapter: Cannot format invalid date.");const r=new Intl.DateTimeFormat(this.locale,Object.assign(Object.assign({},i),{timeZone:"utc"}));return this._format(r,e)}addCalendarYears(e,i){return this.addCalendarMonths(e,12*i)}addCalendarMonths(e,i){let r=this._createDateWithOverflow(this.getYear(e),this.getMonth(e)+i,this.getDate(e));return this.getMonth(r)!=((this.getMonth(e)+i)%12+12)%12&&(r=this._createDateWithOverflow(this.getYear(r),this.getMonth(r),0)),r}addCalendarDays(e,i){return this._createDateWithOverflow(this.getYear(e),this.getMonth(e),this.getDate(e)+i)}toIso8601(e){return[e.getUTCFullYear(),this._2digit(e.getUTCMonth()+1),this._2digit(e.getUTCDate())].join("-")}deserialize(e){if("string"==typeof e){if(!e)return null;if(lz.test(e)){let i=new Date(e);if(this.isValid(i))return i}}return super.deserialize(e)}isDateInstance(e){return e instanceof Date}isValid(e){return!isNaN(e.getTime())}invalid(){return new Date(NaN)}_createDateWithOverflow(e,i,r){const s=new Date;return s.setFullYear(e,i,r),s.setHours(0,0,0,0),s}_2digit(e){return("00"+e).slice(-2)}_format(e,i){const r=new Date;return r.setUTCFullYear(i.getFullYear(),i.getMonth(),i.getDate()),r.setUTCHours(i.getHours(),i.getMinutes(),i.getSeconds(),i.getMilliseconds()),e.format(r)}}return n.\u0275fac=function(e){return new(e||n)(te(oz,8),te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const dz={parse:{dateInput:null},display:{dateInput:{year:"numeric",month:"numeric",day:"numeric"},monthYearLabel:{year:"numeric",month:"short"},dateA11yLabel:{year:"numeric",month:"long",day:"numeric"},monthYearA11yLabel:{year:"numeric",month:"long"}}};let uz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[{provide:Ir,useClass:cz}]}),n})(),hz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[{provide:z_,useValue:dz}],imports:[uz]}),n})(),ih=(()=>{class n{isErrorState(e,i){return!!(e&&e.invalid&&(e.touched||i&&i.submitted))}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),kS=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["","mat-line",""],["","matLine",""]],hostAttrs:[1,"mat-line"]}),n})();function hc(n,t,e){n.nativeElement.classList.toggle(t,e)}let rh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})();class fz{constructor(t,e,i,r=!1){this._renderer=t,this.element=e,this.config=i,this._animationForciblyDisabledThroughCss=r,this.state=3}fadeOut(){this._renderer.fadeOutRipple(this)}}const AS={enterDuration:225,exitDuration:150},G_=Ar({passive:!0}),IS=["mousedown","touchstart"],RS=["mouseup","mouseleave","touchend","touchcancel"];class W_{constructor(t,e,i,r){this._target=t,this._ngZone=e,this._isPointerDown=!1,this._activeRipples=new Map,this._pointerUpEventsRegistered=!1,r.isBrowser&&(this._containerElement=Rn(i))}fadeInRipple(t,e,i={}){const r=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),s=Object.assign(Object.assign({},AS),i.animation);i.centered&&(t=r.left+r.width/2,e=r.top+r.height/2);const o=i.radius||function mz(n,t,e){const i=Math.max(Math.abs(n-e.left),Math.abs(n-e.right)),r=Math.max(Math.abs(t-e.top),Math.abs(t-e.bottom));return Math.sqrt(i*i+r*r)}(t,e,r),a=t-r.left,l=e-r.top,c=s.enterDuration,d=document.createElement("div");d.classList.add("mat-ripple-element"),d.style.left=a-o+"px",d.style.top=l-o+"px",d.style.height=2*o+"px",d.style.width=2*o+"px",null!=i.color&&(d.style.backgroundColor=i.color),d.style.transitionDuration=`${c}ms`,this._containerElement.appendChild(d);const f=window.getComputedStyle(d),k=f.transitionDuration,j="none"===f.transitionProperty||"0s"===k||"0s, 0s"===k,K=new fz(this,d,i,j);d.style.transform="scale3d(1, 1, 1)",K.state=0,i.persistent||(this._mostRecentTransientRipple=K);let ae=null;return!j&&(c||s.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const ce=()=>this._finishRippleTransition(K),Te=()=>this._destroyRipple(K);d.addEventListener("transitionend",ce),d.addEventListener("transitioncancel",Te),ae={onTransitionEnd:ce,onTransitionCancel:Te}}),this._activeRipples.set(K,ae),(j||!c)&&this._finishRippleTransition(K),K}fadeOutRipple(t){if(2===t.state||3===t.state)return;const e=t.element,i=Object.assign(Object.assign({},AS),t.config.animation);e.style.transitionDuration=`${i.exitDuration}ms`,e.style.opacity="0",t.state=2,(t._animationForciblyDisabledThroughCss||!i.exitDuration)&&this._finishRippleTransition(t)}fadeOutAll(){this._getActiveRipples().forEach(t=>t.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(t=>{t.config.persistent||t.fadeOut()})}setupTriggerEvents(t){const e=Rn(t);!e||e===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=e,this._registerEvents(IS))}handleEvent(t){"mousedown"===t.type?this._onMousedown(t):"touchstart"===t.type?this._onTouchStart(t):this._onPointerUp(),this._pointerUpEventsRegistered||(this._registerEvents(RS),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(t){0===t.state?this._startFadeOutTransition(t):2===t.state&&this._destroyRipple(t)}_startFadeOutTransition(t){const e=t===this._mostRecentTransientRipple,{persistent:i}=t.config;t.state=1,!i&&(!e||!this._isPointerDown)&&t.fadeOut()}_destroyRipple(t){var e;const i=null!==(e=this._activeRipples.get(t))&&void 0!==e?e:null;this._activeRipples.delete(t),this._activeRipples.size||(this._containerRect=null),t===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),t.state=3,null!==i&&(t.element.removeEventListener("transitionend",i.onTransitionEnd),t.element.removeEventListener("transitioncancel",i.onTransitionCancel)),t.element.remove()}_onMousedown(t){const e=I_(t),i=this._lastTouchStartEvent&&Date.now(){!t.config.persistent&&(1===t.state||t.config.terminateOnPointerUp&&0===t.state)&&t.fadeOut()}))}_registerEvents(t){this._ngZone.runOutsideAngular(()=>{t.forEach(e=>{this._triggerElement.addEventListener(e,this,G_)})})}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){this._triggerElement&&(IS.forEach(t=>{this._triggerElement.removeEventListener(t,this,G_)}),this._pointerUpEventsRegistered&&RS.forEach(t=>{this._triggerElement.removeEventListener(t,this,G_)}))}}const sh=new De("mat-ripple-global-options");let Ps=(()=>{class n{constructor(e,i,r,s,o){this._elementRef=e,this._animationMode=o,this.radius=0,this._disabled=!1,this._isInitialized=!1,this._globalOptions=s||{},this._rippleRenderer=new W_(this,i,e,r)}get disabled(){return this._disabled}set disabled(e){e&&this.fadeOutAllNonPersistent(),this._disabled=e,this._setupTriggerEventsIfEnabled()}get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(e){this._trigger=e,this._setupTriggerEventsIfEnabled()}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:Object.assign(Object.assign(Object.assign({},this._globalOptions.animation),"NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(e,i=0,r){return"number"==typeof e?this._rippleRenderer.fadeInRipple(e,i,Object.assign(Object.assign({},this.rippleConfig),r)):this._rippleRenderer.fadeInRipple(0,0,Object.assign(Object.assign({},this.rippleConfig),e))}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(bn),x(sh,8),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(e,i){2&e&&At("mat-ripple-unbounded",i.unbounded)},inputs:{color:["matRippleColor","color"],unbounded:["matRippleUnbounded","unbounded"],centered:["matRippleCentered","centered"],radius:["matRippleRadius","radius"],animation:["matRippleAnimation","animation"],disabled:["matRippleDisabled","disabled"],trigger:["matRippleTrigger","trigger"]},exportAs:["matRipple"]}),n})(),Ta=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),PS=(()=>{class n{constructor(e){this._animationMode=e,this.state="unchecked",this.disabled=!1}}return n.\u0275fac=function(e){return new(e||n)(x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:8,hostBindings:function(e,i){2&e&&At("mat-pseudo-checkbox-indeterminate","indeterminate"===i.state)("mat-pseudo-checkbox-checked","checked"===i.state)("mat-pseudo-checkbox-disabled",i.disabled)("_mat-animation-noopable","NoopAnimations"===i._animationMode)},inputs:{state:"state",disabled:"disabled"},decls:0,vars:0,template:function(e,i){},styles:['.mat-pseudo-checkbox{width:16px;height:16px;border:2px solid;border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox.mat-pseudo-checkbox-indeterminate{border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{top:5px;left:1px;width:10px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{top:2.4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}'],encapsulation:2,changeDetection:0}),n})(),q_=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht]}),n})();const OS=new De("MAT_OPTION_PARENT_COMPONENT"),FS=new De("MatOptgroup");let gz=0;class _z{constructor(t,e=!1){this.source=t,this.isUserInput=e}}let vz=(()=>{class n{constructor(e,i,r,s){this._element=e,this._changeDetectorRef=i,this._parent=r,this.group=s,this._selected=!1,this._active=!1,this._disabled=!1,this._mostRecentViewValue="",this.id="mat-option-"+gz++,this.onSelectionChange=new je,this._stateChanges=new ue}get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(e){this._disabled=rt(e)}get disableRipple(){return!(!this._parent||!this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._getHostElement().textContent||"").trim()}select(){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}deselect(){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}focus(e,i){const r=this._getHostElement();"function"==typeof r.focus&&r.focus(i)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(e){(13===e.keyCode||32===e.keyCode)&&!gi(e)&&(this._selectViaInteraction(),e.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getAriaSelected(){return this.selected||!this.multiple&&null}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const e=this.viewValue;e!==this._mostRecentViewValue&&(this._mostRecentViewValue=e,this._stateChanges.next())}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(e=!1){this.onSelectionChange.emit(new _z(this,e))}}return n.\u0275fac=function(e){bs()},n.\u0275dir=Me({type:n,inputs:{value:"value",id:"id",disabled:"disabled"},outputs:{onSelectionChange:"onSelectionChange"}}),n})(),Y_=(()=>{class n extends vz{constructor(e,i,r,s){super(e,i,r,s)}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(OS,8),x(FS,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-option"]],hostAttrs:["role","option",1,"mat-option","mat-focus-indicator"],hostVars:12,hostBindings:function(e,i){1&e&&$e("click",function(){return i._selectViaInteraction()})("keydown",function(s){return i._handleKeydown(s)}),2&e&&(Zr("id",i.id),wt("tabindex",i._getTabIndex())("aria-selected",i._getAriaSelected())("aria-disabled",i.disabled.toString()),At("mat-selected",i.selected)("mat-option-multiple",i.multiple)("mat-active",i.active)("mat-option-disabled",i.disabled))},exportAs:["matOption"],features:[Le],ngContentSelectors:tz,decls:5,vars:4,consts:[["class","mat-option-pseudo-checkbox",3,"state","disabled",4,"ngIf"],[1,"mat-option-text"],["class","cdk-visually-hidden",4,"ngIf"],["mat-ripple","",1,"mat-option-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-option-pseudo-checkbox",3,"state","disabled"],[1,"cdk-visually-hidden"]],template:function(e,i){1&e&&(Fn(),it(0,JU,1,2,"mat-pseudo-checkbox",0),fe(1,"span",1),Tt(2),we(),it(3,ez,2,1,"span",2),kt(4,"div",3)),2&e&&(Ae("ngIf",i.multiple),Ee(3),Ae("ngIf",i.group&&i.group._inert),Ee(1),Ae("matRippleTrigger",i._getHostElement())("matRippleDisabled",i.disabled||i.disableRipple))},dependencies:[Ps,zi,PS],styles:[".mat-option{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative;cursor:pointer;outline:none;display:flex;flex-direction:row;max-width:100%;box-sizing:border-box;align-items:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-option[disabled]{cursor:default}[dir=rtl] .mat-option{text-align:right}.mat-option .mat-icon{margin-right:16px;vertical-align:middle}.mat-option .mat-icon svg{vertical-align:top}[dir=rtl] .mat-option .mat-icon{margin-left:16px;margin-right:0}.mat-option[aria-disabled=true]{-webkit-user-select:none;user-select:none;cursor:default}.mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:32px}[dir=rtl] .mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:16px;padding-right:32px}.cdk-high-contrast-active .mat-option{margin:0 1px}.cdk-high-contrast-active .mat-option.mat-active{border:solid 1px currentColor;margin:0}.cdk-high-contrast-active .mat-option[aria-disabled=true]{opacity:.5}.mat-option-text{display:inline-block;flex-grow:1;overflow:hidden;text-overflow:ellipsis}.mat-option .mat-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-option-pseudo-checkbox{margin-right:8px}[dir=rtl] .mat-option-pseudo-checkbox{margin-left:8px;margin-right:0}"],encapsulation:2,changeDetection:0}),n})();function LS(n,t,e){if(e.length){let i=t.toArray(),r=e.toArray(),s=0;for(let o=0;o{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,pi,ht,q_]}),n})();const bz=["mat-button",""],wz=["*"],Dz=["mat-button","mat-flat-button","mat-icon-button","mat-raised-button","mat-stroked-button","mat-mini-fab","mat-fab"],Ez=vo(uc(Rs(class{constructor(n){this._elementRef=n}})));let Aa=(()=>{class n extends Ez{constructor(e,i,r){super(e),this._focusMonitor=i,this._animationMode=r,this.isRoundButton=this._hasHostAttributes("mat-fab","mat-mini-fab"),this.isIconButton=this._hasHostAttributes("mat-icon-button");for(const s of Dz)this._hasHostAttributes(s)&&this._getHostElement().classList.add(s);e.nativeElement.classList.add("mat-button-base"),this.isRoundButton&&(this.color="accent")}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}focus(e,i){e?this._focusMonitor.focusVia(this._getHostElement(),e,i):this._getHostElement().focus(i)}_getHostElement(){return this._elementRef.nativeElement}_isRippleDisabled(){return this.disableRipple||this.disabled}_hasHostAttributes(...e){return e.some(i=>this._getHostElement().hasAttribute(i))}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(hr),x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-icon-button",""],["button","mat-fab",""],["button","mat-mini-fab",""],["button","mat-stroked-button",""],["button","mat-flat-button",""]],viewQuery:function(e,i){if(1&e&&Gt(Ps,5),2&e){let r;Ge(r=We())&&(i.ripple=r.first)}},hostAttrs:[1,"mat-focus-indicator"],hostVars:5,hostBindings:function(e,i){2&e&&(wt("disabled",i.disabled||null),At("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-button-disabled",i.disabled))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Le],attrs:bz,ngContentSelectors:wz,decls:4,vars:5,consts:[[1,"mat-button-wrapper"],["matRipple","",1,"mat-button-ripple",3,"matRippleDisabled","matRippleCentered","matRippleTrigger"],[1,"mat-button-focus-overlay"]],template:function(e,i){1&e&&(Fn(),fe(0,"span",0),Tt(1),we(),kt(2,"span",1)(3,"span",2)),2&e&&(Ee(2),At("mat-button-ripple-round",i.isRoundButton||i.isIconButton),Ae("matRippleDisabled",i._isRippleDisabled())("matRippleCentered",i.isIconButton)("matRippleTrigger",i._getHostElement()))},dependencies:[Ps],styles:[".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay,.mat-stroked-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay,.mat-stroked-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button.mat-button-disabled,.mat-icon-button.mat-button-disabled,.mat-stroked-button.mat-button-disabled,.mat-flat-button.mat-button-disabled{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button.mat-button-disabled{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab.mat-button-disabled{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}.mat-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab.mat-button-disabled{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:inline-flex;justify-content:center;align-items:center;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}.cdk-high-contrast-active .mat-button-base.cdk-keyboard-focused,.cdk-high-contrast-active .mat-button-base.cdk-program-focused{outline:solid 3px}"],encapsulation:2,changeDetection:0}),n})(),oh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,ht]}),n})();const Mz=["*",[["mat-card-footer"]]],xz=["*","mat-card-footer"];let Sz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-card-content"],["","mat-card-content",""],["","matCardContent",""]],hostAttrs:[1,"mat-card-content"]}),n})(),kz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-card-title"],["","mat-card-title",""],["","matCardTitle",""]],hostAttrs:[1,"mat-card-title"]}),n})(),Tz=(()=>{class n{constructor(e){this._animationMode=e}}return n.\u0275fac=function(e){return new(e||n)(x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-card"]],hostAttrs:[1,"mat-card","mat-focus-indicator"],hostVars:2,hostBindings:function(e,i){2&e&&At("_mat-animation-noopable","NoopAnimations"===i._animationMode)},exportAs:["matCard"],ngContentSelectors:xz,decls:2,vars:0,template:function(e,i){1&e&&(Fn(Mz),Tt(0),Tt(1,1))},styles:[".mat-card{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:block;position:relative;padding:16px;border-radius:4px}.mat-card._mat-animation-noopable{transition:none !important;animation:none !important}.mat-card>.mat-divider-horizontal{position:absolute;left:0;width:100%}[dir=rtl] .mat-card>.mat-divider-horizontal{left:auto;right:0}.mat-card>.mat-divider-horizontal.mat-divider-inset{position:static;margin:0}[dir=rtl] .mat-card>.mat-divider-horizontal.mat-divider-inset{margin-right:0}.cdk-high-contrast-active .mat-card{outline:solid 1px}.mat-card-actions,.mat-card-subtitle,.mat-card-content{display:block;margin-bottom:16px}.mat-card-title{display:block;margin-bottom:8px}.mat-card-actions{margin-left:-8px;margin-right:-8px;padding:8px 0}.mat-card-actions-align-end{display:flex;justify-content:flex-end}.mat-card-image{width:calc(100% + 32px);margin:0 -16px 16px -16px;display:block;overflow:hidden}.mat-card-image img{width:100%}.mat-card-footer{display:block;margin:0 -16px -16px -16px}.mat-card-actions .mat-button,.mat-card-actions .mat-raised-button,.mat-card-actions .mat-stroked-button{margin:0 8px}.mat-card-header{display:flex;flex-direction:row}.mat-card-header .mat-card-title{margin-bottom:12px}.mat-card-header-text{margin:0 16px}.mat-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;object-fit:cover}.mat-card-title-group{display:flex;justify-content:space-between}.mat-card-sm-image{width:80px;height:80px}.mat-card-md-image{width:112px;height:112px}.mat-card-lg-image{width:152px;height:152px}.mat-card-xl-image{width:240px;height:240px;margin:-8px}.mat-card-title-group>.mat-card-xl-image{margin:-8px 0 8px}@media(max-width: 599px){.mat-card-title-group{margin:0}.mat-card-xl-image{margin-left:0;margin-right:0}}.mat-card>:first-child,.mat-card-content>:first-child{margin-top:0}.mat-card>:last-child:not(.mat-card-footer),.mat-card-content>:last-child:not(.mat-card-footer){margin-bottom:0}.mat-card-image:first-child{margin-top:-16px;border-top-left-radius:inherit;border-top-right-radius:inherit}.mat-card>.mat-card-actions:last-child{margin-bottom:-8px;padding-bottom:0}.mat-card-actions:not(.mat-card-actions-align-end) .mat-button:first-child,.mat-card-actions:not(.mat-card-actions-align-end) .mat-raised-button:first-child,.mat-card-actions:not(.mat-card-actions-align-end) .mat-stroked-button:first-child{margin-left:0;margin-right:0}.mat-card-actions-align-end .mat-button:last-child,.mat-card-actions-align-end .mat-raised-button:last-child,.mat-card-actions-align-end .mat-stroked-button:last-child{margin-left:0;margin-right:0}.mat-card-title:not(:first-child),.mat-card-subtitle:not(:first-child){margin-top:-4px}.mat-card-header .mat-card-subtitle:not(:first-child){margin-top:-8px}.mat-card>.mat-card-xl-image:first-child{margin-top:-8px}.mat-card>.mat-card-xl-image:last-child{margin-bottom:-8px}"],encapsulation:2,changeDetection:0}),n})(),Az=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),HS=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),zz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,Gu,HS,ht,HS]}),n})();class ah{constructor(t=!1,e,i=!0){this._multiple=t,this._emitChanges=i,this._selection=new Set,this._deselectedToEmit=[],this._selectedToEmit=[],this.changed=new ue,e&&e.length&&(t?e.forEach(r=>this._markSelected(r)):this._markSelected(e[0]),this._selectedToEmit.length=0)}get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}select(...t){this._verifyValueAssignment(t),t.forEach(e=>this._markSelected(e)),this._emitChangeEvent()}deselect(...t){this._verifyValueAssignment(t),t.forEach(e=>this._unmarkSelected(e)),this._emitChangeEvent()}toggle(t){this.isSelected(t)?this.deselect(t):this.select(t)}clear(){this._unmarkAll(),this._emitChangeEvent()}isSelected(t){return this._selection.has(t)}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(t){this._multiple&&this.selected&&this._selected.sort(t)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(t){this.isSelected(t)||(this._multiple||this._unmarkAll(),this._selection.add(t),this._emitChanges&&this._selectedToEmit.push(t))}_unmarkSelected(t){this.isSelected(t)&&(this._selection.delete(t),this._emitChanges&&this._deselectedToEmit.push(t))}_unmarkAll(){this.isEmpty()||this._selection.forEach(t=>this._unmarkSelected(t))}_verifyValueAssignment(t){}}let Q_=(()=>{class n{constructor(){this._listeners=[]}notify(e,i){for(let r of this._listeners)r(e,i)}listen(e){return this._listeners.push(e),()=>{this._listeners=this._listeners.filter(i=>e!==i)}}ngOnDestroy(){this._listeners=[]}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const $z=["connectionContainer"],Gz=["inputContainer"],Wz=["label"];function qz(n,t){1&n&&(eo(0),fe(1,"div",14),kt(2,"div",15)(3,"div",16)(4,"div",17),we(),fe(5,"div",18),kt(6,"div",15)(7,"div",16)(8,"div",17),we(),to())}function Yz(n,t){if(1&n){const e=ki();fe(0,"div",19),$e("cdkObserveContent",function(){return Bn(e),Vn(lt().updateOutlineGap())}),Tt(1,1),we()}2&n&&Ae("cdkObserveContentDisabled","outline"!=lt().appearance)}function Kz(n,t){if(1&n&&(eo(0),Tt(1,2),fe(2,"span"),Ue(3),we(),to()),2&n){const e=lt(2);Ee(3),Kn(e._control.placeholder)}}function Qz(n,t){1&n&&Tt(0,3,["*ngSwitchCase","true"])}function Zz(n,t){1&n&&(fe(0,"span",23),Ue(1," *"),we())}function Xz(n,t){if(1&n){const e=ki();fe(0,"label",20,21),$e("cdkObserveContent",function(){return Bn(e),Vn(lt().updateOutlineGap())}),it(2,Kz,4,1,"ng-container",12),it(3,Qz,1,0,"ng-content",12),it(4,Zz,2,0,"span",22),we()}if(2&n){const e=lt();At("mat-empty",e._control.empty&&!e._shouldAlwaysFloat())("mat-form-field-empty",e._control.empty&&!e._shouldAlwaysFloat())("mat-accent","accent"==e.color)("mat-warn","warn"==e.color),Ae("cdkObserveContentDisabled","outline"!=e.appearance)("id",e._labelId)("ngSwitch",e._hasLabel()),wt("for",e._control.id)("aria-owns",e._control.id),Ee(2),Ae("ngSwitchCase",!1),Ee(1),Ae("ngSwitchCase",!0),Ee(1),Ae("ngIf",!e.hideRequiredMarker&&e._control.required&&!e._control.disabled)}}function Jz(n,t){1&n&&(fe(0,"div",24),Tt(1,4),we())}function e8(n,t){if(1&n&&(fe(0,"div",25),kt(1,"span",26),we()),2&n){const e=lt();Ee(1),At("mat-accent","accent"==e.color)("mat-warn","warn"==e.color)}}function t8(n,t){1&n&&(fe(0,"div"),Tt(1,5),we()),2&n&&Ae("@transitionMessages",lt()._subscriptAnimationState)}function n8(n,t){if(1&n&&(fe(0,"div",30),Ue(1),we()),2&n){const e=lt(2);Ae("id",e._hintLabelId),Ee(1),Kn(e.hintLabel)}}function i8(n,t){if(1&n&&(fe(0,"div",27),it(1,n8,2,2,"div",28),Tt(2,6),kt(3,"div",29),Tt(4,7),we()),2&n){const e=lt();Ae("@transitionMessages",e._subscriptAnimationState),Ee(1),Ae("ngIf",e.hintLabel)}}const r8=["*",[["","matPrefix",""]],[["mat-placeholder"]],[["mat-label"]],[["","matSuffix",""]],[["mat-error"]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],s8=["*","[matPrefix]","mat-placeholder","mat-label","[matSuffix]","mat-error","mat-hint:not([align='end'])","mat-hint[align='end']"],o8=new De("MatError"),a8={transitionMessages:jn("transitionMessages",[zt("enter",Qe({opacity:1,transform:"translateY(0%)"})),Wt("void => enter",[Qe({opacity:0,transform:"translateY(-5px)"}),Zt("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let lh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n}),n})();const l8=new De("MatHint");let ch=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-label"]]}),n})(),c8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-placeholder"]]}),n})();const d8=new De("MatPrefix"),u8=new De("MatSuffix");let zS=0;const f8=vo(class{constructor(n){this._elementRef=n}},"primary"),p8=new De("MAT_FORM_FIELD_DEFAULT_OPTIONS"),Z_=new De("MatFormField");let GS=(()=>{class n extends f8{constructor(e,i,r,s,o,a,l){super(e),this._changeDetectorRef=i,this._dir=r,this._defaults=s,this._platform=o,this._ngZone=a,this._outlineGapCalculationNeededImmediately=!1,this._outlineGapCalculationNeededOnStable=!1,this._destroyed=new ue,this._hideRequiredMarker=!1,this._showAlwaysAnimate=!1,this._subscriptAnimationState="",this._hintLabel="",this._hintLabelId="mat-hint-"+zS++,this._labelId="mat-form-field-label-"+zS++,this.floatLabel=this._getDefaultFloatLabelState(),this._animationsEnabled="NoopAnimations"!==l,this.appearance=(null==s?void 0:s.appearance)||"legacy",s&&(this._hideRequiredMarker=Boolean(s.hideRequiredMarker),s.color&&(this.color=this.defaultColor=s.color))}get appearance(){return this._appearance}set appearance(e){var i;const r=this._appearance;this._appearance=e||(null===(i=this._defaults)||void 0===i?void 0:i.appearance)||"legacy","outline"===this._appearance&&r!==e&&(this._outlineGapCalculationNeededOnStable=!0)}get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(e){this._hideRequiredMarker=rt(e)}_shouldAlwaysFloat(){return"always"===this.floatLabel&&!this._showAlwaysAnimate}_canLabelFloat(){return"never"!==this.floatLabel}get hintLabel(){return this._hintLabel}set hintLabel(e){this._hintLabel=e,this._processHints()}get floatLabel(){return"legacy"!==this.appearance&&"never"===this._floatLabel?"auto":this._floatLabel}set floatLabel(e){e!==this._floatLabel&&(this._floatLabel=e||this._getDefaultFloatLabelState(),this._changeDetectorRef.markForCheck())}get _control(){return this._explicitFormFieldControl||this._controlNonStatic||this._controlStatic}set _control(e){this._explicitFormFieldControl=e}getLabelId(){return this._hasFloatingLabel()?this._labelId:null}getConnectedOverlayOrigin(){return this._connectionContainerRef||this._elementRef}ngAfterContentInit(){this._validateControlChild();const e=this._control;e.controlType&&this._elementRef.nativeElement.classList.add(`mat-form-field-type-${e.controlType}`),e.stateChanges.pipe(Qn(null)).subscribe(()=>{this._validatePlaceholders(),this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),e.ngControl&&e.ngControl.valueChanges&&e.ngControl.valueChanges.pipe(Ot(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.pipe(Ot(this._destroyed)).subscribe(()=>{this._outlineGapCalculationNeededOnStable&&this.updateOutlineGap()})}),$n(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._outlineGapCalculationNeededOnStable=!0,this._changeDetectorRef.markForCheck()}),this._hintChildren.changes.pipe(Qn(null)).subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.pipe(Qn(null)).subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._dir&&this._dir.change.pipe(Ot(this._destroyed)).subscribe(()=>{"function"==typeof requestAnimationFrame?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this.updateOutlineGap())}):this.updateOutlineGap()})}ngAfterContentChecked(){this._validateControlChild(),this._outlineGapCalculationNeededImmediately&&this.updateOutlineGap()}ngAfterViewInit(){this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete()}_shouldForward(e){const i=this._control?this._control.ngControl:null;return i&&i[e]}_hasPlaceholder(){return!!(this._control&&this._control.placeholder||this._placeholderChild)}_hasLabel(){return!(!this._labelChildNonStatic&&!this._labelChildStatic)}_shouldLabelFloat(){return this._canLabelFloat()&&(this._control&&this._control.shouldLabelFloat||this._shouldAlwaysFloat())}_hideControlPlaceholder(){return"legacy"===this.appearance&&!this._hasLabel()||this._hasLabel()&&!this._shouldLabelFloat()}_hasFloatingLabel(){return this._hasLabel()||"legacy"===this.appearance&&this._hasPlaceholder()}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_animateAndLockLabel(){this._hasFloatingLabel()&&this._canLabelFloat()&&(this._animationsEnabled&&this._label&&(this._showAlwaysAnimate=!0,_o(this._label.nativeElement,"transitionend").pipe(sn(1)).subscribe(()=>{this._showAlwaysAnimate=!1})),this.floatLabel="always",this._changeDetectorRef.markForCheck())}_validatePlaceholders(){}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_getDefaultFloatLabelState(){return this._defaults&&this._defaults.floatLabel||"auto"}_syncDescribedByIds(){if(this._control){let e=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&e.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const i=this._hintChildren?this._hintChildren.find(s=>"start"===s.align):null,r=this._hintChildren?this._hintChildren.find(s=>"end"===s.align):null;i?e.push(i.id):this._hintLabel&&e.push(this._hintLabelId),r&&e.push(r.id)}else this._errorChildren&&e.push(...this._errorChildren.map(i=>i.id));this._control.setDescribedByIds(e)}}_validateControlChild(){}updateOutlineGap(){const e=this._label?this._label.nativeElement:null,i=this._connectionContainerRef.nativeElement,r=".mat-form-field-outline-start",s=".mat-form-field-outline-gap";if("outline"!==this.appearance||!this._platform.isBrowser)return;if(!e||!e.children.length||!e.textContent.trim()){const d=i.querySelectorAll(`${r}, ${s}`);for(let f=0;f0?.75*j+10:0}for(let d=0;d{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,Gu,ht]}),n})();const m8=["*"],WS=new De("MatChipRemove"),qS=new De("MatChipAvatar"),YS=new De("MatChipTrailingIcon");class g8{constructor(t){this._elementRef=t}}const _8=yo(vo(Rs(g8),"primary"),-1);let Ia=(()=>{class n extends _8{constructor(e,i,r,s,o,a,l,c){super(e),this._ngZone=i,this._changeDetectorRef=o,this._hasFocus=!1,this.chipListSelectable=!0,this._chipListMultiple=!1,this._chipListDisabled=!1,this.role="option",this._selected=!1,this._selectable=!0,this._disabled=!1,this._removable=!0,this._onFocus=new ue,this._onBlur=new ue,this.selectionChange=new je,this.destroyed=new je,this.removed=new je,this._addHostClassName(),this._chipRippleTarget=a.createElement("div"),this._chipRippleTarget.classList.add("mat-chip-ripple"),this._elementRef.nativeElement.appendChild(this._chipRippleTarget),this._chipRipple=new W_(this,i,this._chipRippleTarget,r),this._chipRipple.setupTriggerEvents(e),this.rippleConfig=s||{},this._animationsDisabled="NoopAnimations"===l,this.tabIndex=null!=c&&parseInt(c)||-1}get rippleDisabled(){return this.disabled||this.disableRipple||this._animationsDisabled||!!this.rippleConfig.disabled}get selected(){return this._selected}set selected(e){const i=rt(e);i!==this._selected&&(this._selected=i,this._dispatchSelectionChange())}get value(){return void 0!==this._value?this._value:this._elementRef.nativeElement.textContent}set value(e){this._value=e}get selectable(){return this._selectable&&this.chipListSelectable}set selectable(e){this._selectable=rt(e)}get disabled(){return this._chipListDisabled||this._disabled}set disabled(e){this._disabled=rt(e)}get removable(){return this._removable}set removable(e){this._removable=rt(e)}get ariaSelected(){return this.selectable&&(this._chipListMultiple||this.selected)?this.selected.toString():null}_addHostClassName(){const e="mat-basic-chip",i=this._elementRef.nativeElement;i.hasAttribute(e)||i.tagName.toLowerCase()===e?i.classList.add(e):i.classList.add("mat-standard-chip")}ngOnDestroy(){this.destroyed.emit({chip:this}),this._chipRipple._removeTriggerEvents()}select(){this._selected||(this._selected=!0,this._dispatchSelectionChange(),this._changeDetectorRef.markForCheck())}deselect(){this._selected&&(this._selected=!1,this._dispatchSelectionChange(),this._changeDetectorRef.markForCheck())}selectViaInteraction(){this._selected||(this._selected=!0,this._dispatchSelectionChange(!0),this._changeDetectorRef.markForCheck())}toggleSelected(e=!1){return this._selected=!this.selected,this._dispatchSelectionChange(e),this._changeDetectorRef.markForCheck(),this.selected}focus(){this._hasFocus||(this._elementRef.nativeElement.focus(),this._onFocus.next({chip:this})),this._hasFocus=!0}remove(){this.removable&&this.removed.emit({chip:this})}_handleClick(e){this.disabled&&e.preventDefault()}_handleKeydown(e){if(!this.disabled)switch(e.keyCode){case 46:case 8:this.remove(),e.preventDefault();break;case 32:this.selectable&&this.toggleSelected(!0),e.preventDefault()}}_blur(){this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this._ngZone.run(()=>{this._hasFocus=!1,this._onBlur.next({chip:this})})})}_dispatchSelectionChange(e=!1){this.selectionChange.emit({source:this,isUserInput:e,selected:this._selected})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(bn),x(sh,8),x(en),x(ct),x(fn,8),ii("tabindex"))},n.\u0275dir=Me({type:n,selectors:[["mat-basic-chip"],["","mat-basic-chip",""],["mat-chip"],["","mat-chip",""]],contentQueries:function(e,i,r){if(1&e&&(It(r,qS,5),It(r,YS,5),It(r,WS,5)),2&e){let s;Ge(s=We())&&(i.avatar=s.first),Ge(s=We())&&(i.trailingIcon=s.first),Ge(s=We())&&(i.removeIcon=s.first)}},hostAttrs:[1,"mat-chip","mat-focus-indicator"],hostVars:15,hostBindings:function(e,i){1&e&&$e("click",function(s){return i._handleClick(s)})("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i.focus()})("blur",function(){return i._blur()}),2&e&&(wt("tabindex",i.disabled?null:i.tabIndex)("role",i.role)("disabled",i.disabled||null)("aria-disabled",i.disabled.toString())("aria-selected",i.ariaSelected),At("mat-chip-selected",i.selected)("mat-chip-with-avatar",i.avatar)("mat-chip-with-trailing-icon",i.trailingIcon||i.removeIcon)("mat-chip-disabled",i.disabled)("_mat-animation-noopable",i._animationsDisabled))},inputs:{color:"color",disableRipple:"disableRipple",tabIndex:"tabIndex",role:"role",selected:"selected",value:"value",selectable:"selectable",disabled:"disabled",removable:"removable"},outputs:{selectionChange:"selectionChange",destroyed:"destroyed",removed:"removed"},exportAs:["matChip"],features:[Le]}),n})();const KS=new De("mat-chips-default-options"),D8=SS(class{constructor(n,t,e,i){this._defaultErrorStateMatcher=n,this._parentForm=t,this._parentFormGroup=e,this.ngControl=i,this.stateChanges=new ue}});let E8=0;class M8{constructor(t,e){this.source=t,this.value=e}}let uh=(()=>{class n extends D8{constructor(e,i,r,s,o,a,l){super(a,s,o,l),this._elementRef=e,this._changeDetectorRef=i,this._dir=r,this.controlType="mat-chip-list",this._lastDestroyedChipIndex=null,this._destroyed=new ue,this._uid="mat-chip-list-"+E8++,this._tabIndex=0,this._userTabIndex=null,this._onTouched=()=>{},this._onChange=()=>{},this._multiple=!1,this._compareWith=(c,d)=>c===d,this._disabled=!1,this.ariaOrientation="horizontal",this._selectable=!0,this.change=new je,this.valueChange=new je,this.ngControl&&(this.ngControl.valueAccessor=this)}get selected(){var e,i;return this.multiple?(null===(e=this._selectionModel)||void 0===e?void 0:e.selected)||[]:null===(i=this._selectionModel)||void 0===i?void 0:i.selected[0]}get role(){return this._explicitRole?this._explicitRole:this.empty?null:"listbox"}set role(e){this._explicitRole=e}get multiple(){return this._multiple}set multiple(e){this._multiple=rt(e),this._syncChipsState()}get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this.writeValue(e),this._value=e}get id(){return this._chipInput?this._chipInput.id:this._uid}get required(){var e,i,r,s;return null!==(s=null!==(e=this._required)&&void 0!==e?e:null===(r=null===(i=this.ngControl)||void 0===i?void 0:i.control)||void 0===r?void 0:r.hasValidator(Vg.required))&&void 0!==s&&s}set required(e){this._required=rt(e),this.stateChanges.next()}get placeholder(){return this._chipInput?this._chipInput.placeholder:this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}get focused(){return this._chipInput&&this._chipInput.focused||this._hasFocusedChip()}get empty(){return(!this._chipInput||this._chipInput.empty)&&(!this.chips||0===this.chips.length)}get shouldLabelFloat(){return!this.empty||this.focused}get disabled(){return this.ngControl?!!this.ngControl.disabled:this._disabled}set disabled(e){this._disabled=rt(e),this._syncChipsState()}get selectable(){return this._selectable}set selectable(e){this._selectable=rt(e),this.chips&&this.chips.forEach(i=>i.chipListSelectable=this._selectable)}set tabIndex(e){this._userTabIndex=e,this._tabIndex=e}get chipSelectionChanges(){return $n(...this.chips.map(e=>e.selectionChange))}get chipFocusChanges(){return $n(...this.chips.map(e=>e._onFocus))}get chipBlurChanges(){return $n(...this.chips.map(e=>e._onBlur))}get chipRemoveChanges(){return $n(...this.chips.map(e=>e.destroyed))}ngAfterContentInit(){this._keyManager=new Wu(this.chips).withWrap().withVerticalOrientation().withHomeAndEnd().withHorizontalOrientation(this._dir?this._dir.value:"ltr"),this._dir&&this._dir.change.pipe(Ot(this._destroyed)).subscribe(e=>this._keyManager.withHorizontalOrientation(e)),this._keyManager.tabOut.pipe(Ot(this._destroyed)).subscribe(()=>{this._allowFocusEscape()}),this.chips.changes.pipe(Qn(null),Ot(this._destroyed)).subscribe(()=>{this.disabled&&Promise.resolve().then(()=>{this._syncChipsState()}),this._resetChips(),this._initializeSelection(),this._updateTabIndex(),this._updateFocusForDestroyedChips(),this.stateChanges.next()})}ngOnInit(){this._selectionModel=new ah(this.multiple,void 0,!1),this.stateChanges.next()}ngDoCheck(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==this._disabled&&(this.disabled=!!this.ngControl.disabled))}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete(),this.stateChanges.complete(),this._dropSubscriptions()}registerInput(e){this._chipInput=e,this._elementRef.nativeElement.setAttribute("data-mat-chip-input",e.id)}setDescribedByIds(e){e.length?this._elementRef.nativeElement.setAttribute("aria-describedby",e.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}writeValue(e){this.chips&&this._setSelectionByValue(e,!1)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this.stateChanges.next()}onContainerClick(e){this._originatesFromChip(e)||this.focus()}focus(e){this.disabled||this._chipInput&&this._chipInput.focused||(this.chips.length>0?(this._keyManager.setFirstItemActive(),this.stateChanges.next()):(this._focusInput(e),this.stateChanges.next()))}_focusInput(e){this._chipInput&&this._chipInput.focus(e)}_keydown(e){const i=e.target;i&&i.classList.contains("mat-chip")&&(this._keyManager.onKeydown(e),this.stateChanges.next())}_updateTabIndex(){this._tabIndex=this._userTabIndex||(0===this.chips.length?-1:0)}_updateFocusForDestroyedChips(){if(null!=this._lastDestroyedChipIndex)if(this.chips.length){const e=Math.min(this._lastDestroyedChipIndex,this.chips.length-1);this._keyManager.setActiveItem(e)}else this.focus();this._lastDestroyedChipIndex=null}_isValidIndex(e){return e>=0&&er.deselect()),Array.isArray(e))e.forEach(r=>this._selectValue(r,i)),this._sortValues();else{const r=this._selectValue(e,i);r&&i&&this._keyManager.setActiveItem(r)}}_selectValue(e,i=!0){const r=this.chips.find(s=>null!=s.value&&this._compareWith(s.value,e));return r&&(i?r.selectViaInteraction():r.select(),this._selectionModel.select(r)),r}_initializeSelection(){Promise.resolve().then(()=>{(this.ngControl||this._value)&&(this._setSelectionByValue(this.ngControl?this.ngControl.value:this._value,!1),this.stateChanges.next())})}_clearSelection(e){this._selectionModel.clear(),this.chips.forEach(i=>{i!==e&&i.deselect()}),this.stateChanges.next()}_sortValues(){this._multiple&&(this._selectionModel.clear(),this.chips.forEach(e=>{e.selected&&this._selectionModel.select(e)}),this.stateChanges.next())}_propagateChanges(e){let i=null;i=Array.isArray(this.selected)?this.selected.map(r=>r.value):this.selected?this.selected.value:e,this._value=i,this.change.emit(new M8(this,i)),this.valueChange.emit(i),this._onChange(i),this._changeDetectorRef.markForCheck()}_blur(){this._hasFocusedChip()||this._keyManager.setActiveItem(-1),this.disabled||(this._chipInput?setTimeout(()=>{this.focused||this._markAsTouched()}):this._markAsTouched())}_markAsTouched(){this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next()}_allowFocusEscape(){-1!==this._tabIndex&&(this._tabIndex=-1,setTimeout(()=>{this._tabIndex=this._userTabIndex||0,this._changeDetectorRef.markForCheck()}))}_resetChips(){this._dropSubscriptions(),this._listenToChipsFocus(),this._listenToChipsSelection(),this._listenToChipsRemoved()}_dropSubscriptions(){this._chipFocusSubscription&&(this._chipFocusSubscription.unsubscribe(),this._chipFocusSubscription=null),this._chipBlurSubscription&&(this._chipBlurSubscription.unsubscribe(),this._chipBlurSubscription=null),this._chipSelectionSubscription&&(this._chipSelectionSubscription.unsubscribe(),this._chipSelectionSubscription=null),this._chipRemoveSubscription&&(this._chipRemoveSubscription.unsubscribe(),this._chipRemoveSubscription=null)}_listenToChipsSelection(){this._chipSelectionSubscription=this.chipSelectionChanges.subscribe(e=>{e.source.selected?this._selectionModel.select(e.source):this._selectionModel.deselect(e.source),this.multiple||this.chips.forEach(i=>{!this._selectionModel.isSelected(i)&&i.selected&&i.deselect()}),e.isUserInput&&this._propagateChanges()})}_listenToChipsFocus(){this._chipFocusSubscription=this.chipFocusChanges.subscribe(e=>{let i=this.chips.toArray().indexOf(e.chip);this._isValidIndex(i)&&this._keyManager.updateActiveItem(i),this.stateChanges.next()}),this._chipBlurSubscription=this.chipBlurChanges.subscribe(()=>{this._blur(),this.stateChanges.next()})}_listenToChipsRemoved(){this._chipRemoveSubscription=this.chipRemoveChanges.subscribe(e=>{const i=e.chip,r=this.chips.toArray().indexOf(e.chip);this._isValidIndex(r)&&i._hasFocus&&(this._lastDestroyedChipIndex=r)})}_originatesFromChip(e){let i=e.target;for(;i&&i!==this._elementRef.nativeElement;){if(i.classList.contains("mat-chip"))return!0;i=i.parentElement}return!1}_hasFocusedChip(){return this.chips&&this.chips.some(e=>e._hasFocus)}_syncChipsState(){this.chips&&this.chips.forEach(e=>{e._chipListDisabled=this._disabled,e._chipListMultiple=this.multiple})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(qi,8),x(Xl,8),x(Jl,8),x(ih),x(Tr,10))},n.\u0275cmp=vt({type:n,selectors:[["mat-chip-list"]],contentQueries:function(e,i,r){if(1&e&&It(r,Ia,5),2&e){let s;Ge(s=We())&&(i.chips=s)}},hostAttrs:[1,"mat-chip-list"],hostVars:14,hostBindings:function(e,i){1&e&&$e("focus",function(){return i.focus()})("blur",function(){return i._blur()})("keydown",function(s){return i._keydown(s)}),2&e&&(Zr("id",i._uid),wt("tabindex",i.disabled?null:i._tabIndex)("aria-required",i.role?i.required:null)("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-multiselectable",i.multiple)("role",i.role)("aria-orientation",i.ariaOrientation),At("mat-chip-list-disabled",i.disabled)("mat-chip-list-invalid",i.errorState)("mat-chip-list-required",i.required))},inputs:{role:"role",userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],errorStateMatcher:"errorStateMatcher",multiple:"multiple",compareWith:"compareWith",value:"value",required:"required",placeholder:"placeholder",disabled:"disabled",ariaOrientation:["aria-orientation","ariaOrientation"],selectable:"selectable",tabIndex:"tabIndex"},outputs:{change:"change",valueChange:"valueChange"},exportAs:["matChipList"],features:[Xe([{provide:lh,useExisting:n}]),Le],ngContentSelectors:m8,decls:2,vars:0,consts:[[1,"mat-chip-list-wrapper"]],template:function(e,i){1&e&&(Fn(),fe(0,"div",0),Tt(1),we())},styles:['.mat-chip{position:relative;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0);border:none;-webkit-appearance:none;-moz-appearance:none}.mat-standard-chip{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:inline-flex;padding:7px 12px;border-radius:16px;align-items:center;cursor:default;min-height:32px;height:1px}.mat-standard-chip._mat-animation-noopable{transition:none !important;animation:none !important}.mat-standard-chip .mat-chip-remove{border:none;-webkit-appearance:none;-moz-appearance:none;padding:0;background:none}.mat-standard-chip .mat-chip-remove.mat-icon,.mat-standard-chip .mat-chip-remove .mat-icon{width:18px;height:18px;font-size:18px}.mat-standard-chip::after{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;opacity:0;content:"";pointer-events:none;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-standard-chip:hover::after{opacity:.12}.mat-standard-chip:focus{outline:none}.mat-standard-chip:focus::after{opacity:.16}.cdk-high-contrast-active .mat-standard-chip{outline:solid 1px}.cdk-high-contrast-active .mat-standard-chip:focus{outline:dotted 2px}.cdk-high-contrast-active .mat-standard-chip.mat-chip-selected{outline-width:3px}.mat-standard-chip.mat-chip-disabled::after{opacity:0}.mat-standard-chip.mat-chip-disabled .mat-chip-remove,.mat-standard-chip.mat-chip-disabled .mat-chip-trailing-icon{cursor:default}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar,.mat-standard-chip.mat-chip-with-avatar{padding-top:0;padding-bottom:0}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-right:8px;padding-left:0}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-left:8px;padding-right:0}.mat-standard-chip.mat-chip-with-trailing-icon{padding-top:7px;padding-bottom:7px;padding-right:8px;padding-left:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon{padding-left:8px;padding-right:12px}.mat-standard-chip.mat-chip-with-avatar{padding-left:0;padding-right:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-avatar{padding-right:0;padding-left:12px}.mat-standard-chip .mat-chip-avatar{width:24px;height:24px;margin-right:8px;margin-left:4px}[dir=rtl] .mat-standard-chip .mat-chip-avatar{margin-left:8px;margin-right:4px}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{width:18px;height:18px;cursor:pointer}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-standard-chip .mat-chip-remove,[dir=rtl] .mat-standard-chip .mat-chip-trailing-icon{margin-right:8px;margin-left:0}.mat-chip-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit;overflow:hidden;transform:translateZ(0)}.mat-chip-list-wrapper{display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;margin:-4px}.mat-chip-list-wrapper input.mat-input-element,.mat-chip-list-wrapper .mat-standard-chip{margin:4px}.mat-chip-list-stacked .mat-chip-list-wrapper{flex-direction:column;align-items:flex-start}.mat-chip-list-stacked .mat-chip-list-wrapper .mat-standard-chip{width:100%}.mat-chip-avatar{border-radius:50%;justify-content:center;align-items:center;display:flex;overflow:hidden;object-fit:cover}input.mat-chip-input{width:150px;margin:4px;flex:1 0 150px}'],encapsulation:2,changeDetection:0}),n})(),x8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[ih,{provide:KS,useValue:{separatorKeyCodes:[13]}}],imports:[ht]}),n})();class X_{attach(t){return this._attachedHost=t,t.attach(this)}detach(){let t=this._attachedHost;null!=t&&(this._attachedHost=null,t.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(t){this._attachedHost=t}}class pc extends X_{constructor(t,e,i,r){super(),this.component=t,this.viewContainerRef=e,this.injector=i,this.componentFactoryResolver=r}}class mc extends X_{constructor(t,e,i,r){super(),this.templateRef=t,this.viewContainerRef=e,this.context=i,this.injector=r}get origin(){return this.templateRef.elementRef}attach(t,e=this.context){return this.context=e,super.attach(t)}detach(){return this.context=void 0,super.detach()}}class S8 extends X_{constructor(t){super(),this.element=t instanceof Je?t.nativeElement:t}}class hh{constructor(){this._isDisposed=!1,this.attachDomPortal=null}hasAttached(){return!!this._attachedPortal}attach(t){return t instanceof pc?(this._attachedPortal=t,this.attachComponentPortal(t)):t instanceof mc?(this._attachedPortal=t,this.attachTemplatePortal(t)):this.attachDomPortal&&t instanceof S8?(this._attachedPortal=t,this.attachDomPortal(t)):void 0}detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(t){this._disposeFn=t}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class k8 extends hh{constructor(t,e,i,r,s){super(),this.outletElement=t,this._componentFactoryResolver=e,this._appRef=i,this._defaultInjector=r,this.attachDomPortal=o=>{const a=o.element,l=this._document.createComment("dom-portal");a.parentNode.insertBefore(l,a),this.outletElement.appendChild(a),this._attachedPortal=o,super.setDisposeFn(()=>{l.parentNode&&l.parentNode.replaceChild(a,l)})},this._document=s}attachComponentPortal(t){const i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component);let r;return t.viewContainerRef?(r=t.viewContainerRef.createComponent(i,t.viewContainerRef.length,t.injector||t.viewContainerRef.injector),this.setDisposeFn(()=>r.destroy())):(r=i.create(t.injector||this._defaultInjector||Jt.NULL),this._appRef.attachView(r.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(r.hostView),r.destroy()})),this.outletElement.appendChild(this._getComponentRootNode(r)),this._attachedPortal=t,r}attachTemplatePortal(t){let e=t.viewContainerRef,i=e.createEmbeddedView(t.templateRef,t.context,{injector:t.injector});return i.rootNodes.forEach(r=>this.outletElement.appendChild(r)),i.detectChanges(),this.setDisposeFn(()=>{let r=e.indexOf(i);-1!==r&&e.remove(r)}),this._attachedPortal=t,i}dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(t){return t.hostView.rootNodes[0]}}let Ra=(()=>{class n extends hh{constructor(e,i,r){super(),this._componentFactoryResolver=e,this._viewContainerRef=i,this._isInitialized=!1,this.attached=new je,this.attachDomPortal=s=>{const o=s.element,a=this._document.createComment("dom-portal");s.setAttachedHost(this),o.parentNode.insertBefore(a,o),this._getRootNode().appendChild(o),this._attachedPortal=s,super.setDisposeFn(()=>{a.parentNode&&a.parentNode.replaceChild(o,a)})},this._document=r}get portal(){return this._attachedPortal}set portal(e){this.hasAttached()&&!e&&!this._isInitialized||(this.hasAttached()&&super.detach(),e&&super.attach(e),this._attachedPortal=e||null)}get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedPortal=null,this._attachedRef=null}attachComponentPortal(e){e.setAttachedHost(this);const i=null!=e.viewContainerRef?e.viewContainerRef:this._viewContainerRef,s=(e.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(e.component),o=i.createComponent(s,i.length,e.injector||i.injector);return i!==this._viewContainerRef&&this._getRootNode().appendChild(o.hostView.rootNodes[0]),super.setDisposeFn(()=>o.destroy()),this._attachedPortal=e,this._attachedRef=o,this.attached.emit(o),o}attachTemplatePortal(e){e.setAttachedHost(this);const i=this._viewContainerRef.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=e,this._attachedRef=i,this.attached.emit(i),i}_getRootNode(){const e=this._viewContainerRef.element.nativeElement;return e.nodeType===e.ELEMENT_NODE?e:e.parentNode}}return n.\u0275fac=function(e){return new(e||n)(x(io),x(An),x(ct))},n.\u0275dir=Me({type:n,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Le]}),n})(),Os=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const QS=I3();class A8{constructor(t,e){this._viewportRuler=t,this._previousHTMLStyles={top:"",left:""},this._isEnabled=!1,this._document=e}attach(){}enable(){if(this._canBeEnabled()){const t=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=t.style.left||"",this._previousHTMLStyles.top=t.style.top||"",t.style.left=xn(-this._previousScrollPosition.left),t.style.top=xn(-this._previousScrollPosition.top),t.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const t=this._document.documentElement,i=t.style,r=this._document.body.style,s=i.scrollBehavior||"",o=r.scrollBehavior||"";this._isEnabled=!1,i.left=this._previousHTMLStyles.left,i.top=this._previousHTMLStyles.top,t.classList.remove("cdk-global-scrollblock"),QS&&(i.scrollBehavior=r.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),QS&&(i.scrollBehavior=s,r.scrollBehavior=o)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const e=this._document.body,i=this._viewportRuler.getViewportSize();return e.scrollHeight>i.height||e.scrollWidth>i.width}}class I8{constructor(t,e,i,r){this._scrollDispatcher=t,this._ngZone=e,this._viewportRuler=i,this._config=r,this._scrollSubscription=null,this._detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}attach(t){this._overlayRef=t}enable(){if(this._scrollSubscription)return;const t=this._scrollDispatcher.scrolled(0);this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=t.subscribe(()=>{const e=this._viewportRuler.getViewportScrollPosition().top;Math.abs(e-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=t.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}class ZS{enable(){}disable(){}attach(){}}function J_(n,t){return t.some(e=>n.bottome.bottom||n.righte.right)}function XS(n,t){return t.some(e=>n.tope.bottom||n.lefte.right)}class R8{constructor(t,e,i,r){this._scrollDispatcher=t,this._viewportRuler=e,this._ngZone=i,this._config=r,this._scrollSubscription=null}attach(t){this._overlayRef=t}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const e=this._overlayRef.overlayElement.getBoundingClientRect(),{width:i,height:r}=this._viewportRuler.getViewportSize();J_(e,[{width:i,height:r,bottom:r,right:i,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let P8=(()=>{class n{constructor(e,i,r,s){this._scrollDispatcher=e,this._viewportRuler=i,this._ngZone=r,this.noop=()=>new ZS,this.close=o=>new I8(this._scrollDispatcher,this._ngZone,this._viewportRuler,o),this.block=()=>new A8(this._viewportRuler,this._document),this.reposition=o=>new R8(this._scrollDispatcher,this._viewportRuler,this._ngZone,o),this._document=s}}return n.\u0275fac=function(e){return new(e||n)(te(VU),te(ss),te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class fh{constructor(t){if(this.scrollStrategy=new ZS,this.panelClass="",this.hasBackdrop=!1,this.backdropClass="cdk-overlay-dark-backdrop",this.disposeOnNavigation=!1,t){const e=Object.keys(t);for(const i of e)void 0!==t[i]&&(this[i]=t[i])}}}class O8{constructor(t,e){this.connectionPair=t,this.scrollableViewProperties=e}}class gc{constructor(t,e,i,r,s,o,a,l,c,d=!1){this._portalOutlet=t,this._host=e,this._pane=i,this._config=r,this._ngZone=s,this._keyboardDispatcher=o,this._document=a,this._location=l,this._outsideClickDispatcher=c,this._animationsDisabled=d,this._backdropElement=null,this._backdropClick=new ue,this._attachments=new ue,this._detachments=new ue,this._locationChanges=X.EMPTY,this._backdropClickHandler=f=>this._backdropClick.next(f),this._backdropTransitionendHandler=f=>{this._disposeBackdrop(f.target)},this._keydownEvents=new ue,this._outsidePointerEvents=new ue,r.scrollStrategy&&(this._scrollStrategy=r.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=r.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(t){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const e=this._portalOutlet.attach(t);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this.hasAttached()&&this.updatePosition()}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),e}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const t=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenStable(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),t}dispose(){var t;const e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),null===(t=this._host)||void 0===t||t.remove(),this._previousHostParent=this._pane=this._host=null,e&&this._detachments.next(),this._detachments.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(t){t!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=t,this.hasAttached()&&(t.attach(this),this.updatePosition()))}updateSize(t){this._config=Object.assign(Object.assign({},this._config),t),this._updateElementSize()}setDirection(t){this._config=Object.assign(Object.assign({},this._config),{direction:t}),this._updateElementDirection()}addPanelClass(t){this._pane&&this._toggleClasses(this._pane,t,!0)}removePanelClass(t){this._pane&&this._toggleClasses(this._pane,t,!1)}getDirection(){const t=this._config.direction;return t?"string"==typeof t?t:t.value:"ltr"}updateScrollStrategy(t){t!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=t,this.hasAttached()&&(t.attach(this),t.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const t=this._pane.style;t.width=xn(this._config.width),t.height=xn(this._config.height),t.minWidth=xn(this._config.minWidth),t.minHeight=xn(this._config.minHeight),t.maxWidth=xn(this._config.maxWidth),t.maxHeight=xn(this._config.maxHeight)}_togglePointerEvents(t){this._pane.style.pointerEvents=t?"":"none"}_attachBackdrop(){const t="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),this._animationsDisabled||"undefined"==typeof requestAnimationFrame?this._backdropElement.classList.add(t):this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(t)})})}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const t=this._backdropElement;if(t){if(this._animationsDisabled)return void this._disposeBackdrop(t);t.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{t.addEventListener("transitionend",this._backdropTransitionendHandler)}),t.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(t)},500))}}_toggleClasses(t,e,i){const r=Uu(e||[]).filter(s=>!!s);r.length&&(i?t.classList.add(...r):t.classList.remove(...r))}_detachContentWhenStable(){this._ngZone.runOutsideAngular(()=>{const t=this._ngZone.onStable.pipe(Ot($n(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),t.unsubscribe())})})}_disposeScrollStrategy(){const t=this._scrollStrategy;t&&(t.disable(),t.detach&&t.detach())}_disposeBackdrop(t){t&&(t.removeEventListener("click",this._backdropClickHandler),t.removeEventListener("transitionend",this._backdropTransitionendHandler),t.remove(),this._backdropElement===t&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}let ph=(()=>{class n{constructor(e,i){this._platform=i,this._document=e}ngOnDestroy(){var e;null===(e=this._containerElement)||void 0===e||e.remove()}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const e="cdk-overlay-container";if(this._platform.isBrowser||__()){const r=this._document.querySelectorAll(`.${e}[platform="server"], .${e}[platform="test"]`);for(let s=0;s{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const t=this._originRect,e=this._overlayRect,i=this._viewportRect,r=this._containerRect,s=[];let o;for(let a of this._preferredPositions){let l=this._getOriginPoint(t,r,a),c=this._getOverlayPoint(l,e,a),d=this._getOverlayFit(c,e,i,a);if(d.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(a,l);this._canFitWithFlexibleDimensions(d,c,i)?s.push({position:a,origin:l,overlayRect:e,boundingBoxRect:this._calculateBoundingBoxRect(l,a)}):(!o||o.overlayFit.visibleAreal&&(l=d,a=c)}return this._isPushed=!1,void this._applyPosition(a.position,a.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(o.position,o.originPoint);this._applyPosition(o.position,o.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&bo(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(JS),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const t=this._lastPosition;if(t){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const e=this._getOriginPoint(this._originRect,this._containerRect,t);this._applyPosition(t,e)}else this.apply()}withScrollableContainers(t){return this._scrollables=t,this}withPositions(t){return this._preferredPositions=t,-1===t.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(t){return this._viewportMargin=t,this}withFlexibleDimensions(t=!0){return this._hasFlexibleDimensions=t,this}withGrowAfterOpen(t=!0){return this._growAfterOpen=t,this}withPush(t=!0){return this._canPush=t,this}withLockedPosition(t=!0){return this._positionLocked=t,this}setOrigin(t){return this._origin=t,this}withDefaultOffsetX(t){return this._offsetX=t,this}withDefaultOffsetY(t){return this._offsetY=t,this}withTransformOriginOn(t){return this._transformOriginSelector=t,this}_getOriginPoint(t,e,i){let r,s;if("center"==i.originX)r=t.left+t.width/2;else{const o=this._isRtl()?t.right:t.left,a=this._isRtl()?t.left:t.right;r="start"==i.originX?o:a}return e.left<0&&(r-=e.left),s="center"==i.originY?t.top+t.height/2:"top"==i.originY?t.top:t.bottom,e.top<0&&(s-=e.top),{x:r,y:s}}_getOverlayPoint(t,e,i){let r,s;return r="center"==i.overlayX?-e.width/2:"start"===i.overlayX?this._isRtl()?-e.width:0:this._isRtl()?0:-e.width,s="center"==i.overlayY?-e.height/2:"top"==i.overlayY?0:-e.height,{x:t.x+r,y:t.y+s}}_getOverlayFit(t,e,i,r){const s=tk(e);let{x:o,y:a}=t,l=this._getOffset(r,"x"),c=this._getOffset(r,"y");l&&(o+=l),c&&(a+=c);let w=0-a,k=a+s.height-i.height,j=this._subtractOverflows(s.width,0-o,o+s.width-i.width),K=this._subtractOverflows(s.height,w,k),ae=j*K;return{visibleArea:ae,isCompletelyWithinViewport:s.width*s.height===ae,fitsInViewportVertically:K===s.height,fitsInViewportHorizontally:j==s.width}}_canFitWithFlexibleDimensions(t,e,i){if(this._hasFlexibleDimensions){const r=i.bottom-e.y,s=i.right-e.x,o=ek(this._overlayRef.getConfig().minHeight),a=ek(this._overlayRef.getConfig().minWidth),c=t.fitsInViewportHorizontally||null!=a&&a<=s;return(t.fitsInViewportVertically||null!=o&&o<=r)&&c}return!1}_pushOverlayOnScreen(t,e,i){if(this._previousPushAmount&&this._positionLocked)return{x:t.x+this._previousPushAmount.x,y:t.y+this._previousPushAmount.y};const r=tk(e),s=this._viewportRect,o=Math.max(t.x+r.width-s.width,0),a=Math.max(t.y+r.height-s.height,0),l=Math.max(s.top-i.top-t.y,0),c=Math.max(s.left-i.left-t.x,0);let d=0,f=0;return d=r.width<=s.width?c||-o:t.xj&&!this._isInitialRender&&!this._growAfterOpen&&(o=t.y-j/2)}if("end"===e.overlayX&&!r||"start"===e.overlayX&&r)w=i.width-t.x+this._viewportMargin,d=t.x-this._viewportMargin;else if("start"===e.overlayX&&!r||"end"===e.overlayX&&r)f=t.x,d=i.right-t.x;else{const k=Math.min(i.right-t.x+i.left,t.x),j=this._lastBoundingBoxSize.width;d=2*k,f=t.x-k,d>j&&!this._isInitialRender&&!this._growAfterOpen&&(f=t.x-j/2)}return{top:o,left:f,bottom:a,right:w,width:d,height:s}}_setBoundingBoxStyles(t,e){const i=this._calculateBoundingBoxRect(t,e);!this._isInitialRender&&!this._growAfterOpen&&(i.height=Math.min(i.height,this._lastBoundingBoxSize.height),i.width=Math.min(i.width,this._lastBoundingBoxSize.width));const r={};if(this._hasExactPosition())r.top=r.left="0",r.bottom=r.right=r.maxHeight=r.maxWidth="",r.width=r.height="100%";else{const s=this._overlayRef.getConfig().maxHeight,o=this._overlayRef.getConfig().maxWidth;r.height=xn(i.height),r.top=xn(i.top),r.bottom=xn(i.bottom),r.width=xn(i.width),r.left=xn(i.left),r.right=xn(i.right),r.alignItems="center"===e.overlayX?"center":"end"===e.overlayX?"flex-end":"flex-start",r.justifyContent="center"===e.overlayY?"center":"bottom"===e.overlayY?"flex-end":"flex-start",s&&(r.maxHeight=xn(s)),o&&(r.maxWidth=xn(o))}this._lastBoundingBoxSize=i,bo(this._boundingBox.style,r)}_resetBoundingBoxStyles(){bo(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){bo(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(t,e){const i={},r=this._hasExactPosition(),s=this._hasFlexibleDimensions,o=this._overlayRef.getConfig();if(r){const d=this._viewportRuler.getViewportScrollPosition();bo(i,this._getExactOverlayY(e,t,d)),bo(i,this._getExactOverlayX(e,t,d))}else i.position="static";let a="",l=this._getOffset(e,"x"),c=this._getOffset(e,"y");l&&(a+=`translateX(${l}px) `),c&&(a+=`translateY(${c}px)`),i.transform=a.trim(),o.maxHeight&&(r?i.maxHeight=xn(o.maxHeight):s&&(i.maxHeight="")),o.maxWidth&&(r?i.maxWidth=xn(o.maxWidth):s&&(i.maxWidth="")),bo(this._pane.style,i)}_getExactOverlayY(t,e,i){let r={top:"",bottom:""},s=this._getOverlayPoint(e,this._overlayRect,t);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),"bottom"===t.overlayY?r.bottom=this._document.documentElement.clientHeight-(s.y+this._overlayRect.height)+"px":r.top=xn(s.y),r}_getExactOverlayX(t,e,i){let o,r={left:"",right:""},s=this._getOverlayPoint(e,this._overlayRect,t);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),o=this._isRtl()?"end"===t.overlayX?"left":"right":"end"===t.overlayX?"right":"left","right"===o?r.right=this._document.documentElement.clientWidth-(s.x+this._overlayRect.width)+"px":r.left=xn(s.x),r}_getScrollVisibility(){const t=this._getOriginRect(),e=this._pane.getBoundingClientRect(),i=this._scrollables.map(r=>r.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:XS(t,i),isOriginOutsideView:J_(t,i),isOverlayClipped:XS(e,i),isOverlayOutsideView:J_(e,i)}}_subtractOverflows(t,...e){return e.reduce((i,r)=>i-Math.max(r,0),t)}_getNarrowedViewportRect(){const t=this._document.documentElement.clientWidth,e=this._document.documentElement.clientHeight,i=this._viewportRuler.getViewportScrollPosition();return{top:i.top+this._viewportMargin,left:i.left+this._viewportMargin,right:i.left+t-this._viewportMargin,bottom:i.top+e-this._viewportMargin,width:t-2*this._viewportMargin,height:e-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(t,e){return"x"===e?null==t.offsetX?this._offsetX:t.offsetX:null==t.offsetY?this._offsetY:t.offsetY}_validatePositions(){}_addPanelClasses(t){this._pane&&Uu(t).forEach(e=>{""!==e&&-1===this._appliedPanelClasses.indexOf(e)&&(this._appliedPanelClasses.push(e),this._pane.classList.add(e))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(t=>{this._pane.classList.remove(t)}),this._appliedPanelClasses=[])}_getOriginRect(){const t=this._origin;if(t instanceof Je)return t.nativeElement.getBoundingClientRect();if(t instanceof Element)return t.getBoundingClientRect();const e=t.width||0,i=t.height||0;return{top:t.y,bottom:t.y+i,left:t.x,right:t.x+e,height:i,width:e}}}function bo(n,t){for(let e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return n}function ek(n){if("number"!=typeof n&&null!=n){const[t,e]=n.split(F8);return e&&"px"!==e?null:parseFloat(t)}return n||null}function tk(n){return{top:Math.floor(n.top),right:Math.floor(n.right),bottom:Math.floor(n.bottom),left:Math.floor(n.left),width:Math.floor(n.width),height:Math.floor(n.height)}}const nk="cdk-global-overlay-wrapper";class N8{constructor(){this._cssPosition="static",this._topOffset="",this._bottomOffset="",this._alignItems="",this._xPosition="",this._xOffset="",this._width="",this._height="",this._isDisposed=!1}attach(t){const e=t.getConfig();this._overlayRef=t,this._width&&!e.width&&t.updateSize({width:this._width}),this._height&&!e.height&&t.updateSize({height:this._height}),t.hostElement.classList.add(nk),this._isDisposed=!1}top(t=""){return this._bottomOffset="",this._topOffset=t,this._alignItems="flex-start",this}left(t=""){return this._xOffset=t,this._xPosition="left",this}bottom(t=""){return this._topOffset="",this._bottomOffset=t,this._alignItems="flex-end",this}right(t=""){return this._xOffset=t,this._xPosition="right",this}start(t=""){return this._xOffset=t,this._xPosition="start",this}end(t=""){return this._xOffset=t,this._xPosition="end",this}width(t=""){return this._overlayRef?this._overlayRef.updateSize({width:t}):this._width=t,this}height(t=""){return this._overlayRef?this._overlayRef.updateSize({height:t}):this._height=t,this}centerHorizontally(t=""){return this.left(t),this._xPosition="center",this}centerVertically(t=""){return this.top(t),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement.style,i=this._overlayRef.getConfig(),{width:r,height:s,maxWidth:o,maxHeight:a}=i,l=!("100%"!==r&&"100vw"!==r||o&&"100%"!==o&&"100vw"!==o),c=!("100%"!==s&&"100vh"!==s||a&&"100%"!==a&&"100vh"!==a),d=this._xPosition,f=this._xOffset,w="rtl"===this._overlayRef.getConfig().direction;let k="",j="",K="";l?K="flex-start":"center"===d?(K="center",w?j=f:k=f):w?"left"===d||"end"===d?(K="flex-end",k=f):("right"===d||"start"===d)&&(K="flex-start",j=f):"left"===d||"start"===d?(K="flex-start",k=f):("right"===d||"end"===d)&&(K="flex-end",j=f),t.position=this._cssPosition,t.marginLeft=l?"0":k,t.marginTop=c?"0":this._topOffset,t.marginBottom=this._bottomOffset,t.marginRight=l?"0":j,e.justifyContent=K,e.alignItems=c?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement,i=e.style;e.classList.remove(nk),i.justifyContent=i.alignItems=t.marginTop=t.marginBottom=t.marginLeft=t.marginRight=t.position="",this._overlayRef=null,this._isDisposed=!0}}let B8=(()=>{class n{constructor(e,i,r,s){this._viewportRuler=e,this._document=i,this._platform=r,this._overlayContainer=s}global(){return new N8}flexibleConnectedTo(e){return new L8(e,this._viewportRuler,this._document,this._platform,this._overlayContainer)}}return n.\u0275fac=function(e){return new(e||n)(te(ss),te(ct),te(bn),te(ph))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ik=(()=>{class n{constructor(e){this._attachedOverlays=[],this._document=e}ngOnDestroy(){this.detach()}add(e){this.remove(e),this._attachedOverlays.push(e)}remove(e){const i=this._attachedOverlays.indexOf(e);i>-1&&this._attachedOverlays.splice(i,1),0===this._attachedOverlays.length&&this.detach()}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),V8=(()=>{class n extends ik{constructor(e,i){super(e),this._ngZone=i,this._keydownListener=r=>{const s=this._attachedOverlays;for(let o=s.length-1;o>-1;o--)if(s[o]._keydownEvents.observers.length>0){const a=s[o]._keydownEvents;this._ngZone?this._ngZone.run(()=>a.next(r)):a.next(r);break}}}add(e){super.add(e),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(et,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),H8=(()=>{class n extends ik{constructor(e,i,r){super(e),this._platform=i,this._ngZone=r,this._cursorStyleIsSet=!1,this._pointerDownListener=s=>{this._pointerDownEventTarget=ur(s)},this._clickListener=s=>{const o=ur(s),a="click"===s.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:o;this._pointerDownEventTarget=null;const l=this._attachedOverlays.slice();for(let c=l.length-1;c>-1;c--){const d=l[c];if(d._outsidePointerEvents.observers.length<1||!d.hasAttached())continue;if(d.overlayElement.contains(o)||d.overlayElement.contains(a))break;const f=d._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>f.next(s)):f.next(s)}}}add(e){if(super.add(e),!this._isAttached){const i=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(i)):this._addEventListeners(i),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=i.style.cursor,i.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const e=this._document.body;e.removeEventListener("pointerdown",this._pointerDownListener,!0),e.removeEventListener("click",this._clickListener,!0),e.removeEventListener("auxclick",this._clickListener,!0),e.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(e.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(e){e.addEventListener("pointerdown",this._pointerDownListener,!0),e.addEventListener("click",this._clickListener,!0),e.addEventListener("auxclick",this._clickListener,!0),e.addEventListener("contextmenu",this._clickListener,!0)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(bn),te(et,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),j8=0,Yi=(()=>{class n{constructor(e,i,r,s,o,a,l,c,d,f,w,k){this.scrollStrategies=e,this._overlayContainer=i,this._componentFactoryResolver=r,this._positionBuilder=s,this._keyboardDispatcher=o,this._injector=a,this._ngZone=l,this._document=c,this._directionality=d,this._location=f,this._outsideClickDispatcher=w,this._animationsModuleType=k}create(e){const i=this._createHostElement(),r=this._createPaneElement(i),s=this._createPortalOutlet(r),o=new fh(e);return o.direction=o.direction||this._directionality.value,new gc(s,i,r,o,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType)}position(){return this._positionBuilder}_createPaneElement(e){const i=this._document.createElement("div");return i.id="cdk-overlay-"+j8++,i.classList.add("cdk-overlay-pane"),e.appendChild(i),i}_createHostElement(){const e=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(e),e}_createPortalOutlet(e){return this._appRef||(this._appRef=this._injector.get(Ll)),new k8(e,this._componentFactoryResolver,this._appRef,this._injector,this._document)}}return n.\u0275fac=function(e){return new(e||n)(te(P8),te(ph),te(io),te(B8),te(V8),te(Jt),te(et),te(ct),te(qi),te(Vl),te(H8),te(fn,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const U8=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],rk=new De("cdk-connected-overlay-scroll-strategy");let sk=(()=>{class n{constructor(e){this.elementRef=e}}return n.\u0275fac=function(e){return new(e||n)(x(Je))},n.\u0275dir=Me({type:n,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]}),n})(),ok=(()=>{class n{constructor(e,i,r,s,o){this._overlay=e,this._dir=o,this._hasBackdrop=!1,this._lockPosition=!1,this._growAfterOpen=!1,this._flexibleDimensions=!1,this._push=!1,this._backdropSubscription=X.EMPTY,this._attachSubscription=X.EMPTY,this._detachSubscription=X.EMPTY,this._positionSubscription=X.EMPTY,this.viewportMargin=0,this.open=!1,this.disableClose=!1,this.backdropClick=new je,this.positionChange=new je,this.attach=new je,this.detach=new je,this.overlayKeydown=new je,this.overlayOutsideClick=new je,this._templatePortal=new mc(i,r),this._scrollStrategyFactory=s,this.scrollStrategy=this._scrollStrategyFactory()}get offsetX(){return this._offsetX}set offsetX(e){this._offsetX=e,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(e){this._offsetY=e,this._position&&this._updatePositionStrategy(this._position)}get hasBackdrop(){return this._hasBackdrop}set hasBackdrop(e){this._hasBackdrop=rt(e)}get lockPosition(){return this._lockPosition}set lockPosition(e){this._lockPosition=rt(e)}get flexibleDimensions(){return this._flexibleDimensions}set flexibleDimensions(e){this._flexibleDimensions=rt(e)}get growAfterOpen(){return this._growAfterOpen}set growAfterOpen(e){this._growAfterOpen=rt(e)}get push(){return this._push}set push(e){this._push=rt(e)}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(e){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),e.origin&&this.open&&this._position.apply()),e.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=U8);const e=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=e.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=e.detachments().subscribe(()=>this.detach.emit()),e.keydownEvents().subscribe(i=>{this.overlayKeydown.next(i),27===i.keyCode&&!this.disableClose&&!gi(i)&&(i.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(i=>{this.overlayOutsideClick.next(i)})}_buildConfig(){const e=this._position=this.positionStrategy||this._createPositionStrategy(),i=new fh({direction:this._dir,positionStrategy:e,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop});return(this.width||0===this.width)&&(i.width=this.width),(this.height||0===this.height)&&(i.height=this.height),(this.minWidth||0===this.minWidth)&&(i.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(i.minHeight=this.minHeight),this.backdropClass&&(i.backdropClass=this.backdropClass),this.panelClass&&(i.panelClass=this.panelClass),i}_updatePositionStrategy(e){const i=this.positions.map(r=>({originX:r.originX,originY:r.originY,overlayX:r.overlayX,overlayY:r.overlayY,offsetX:r.offsetX||this.offsetX,offsetY:r.offsetY||this.offsetY,panelClass:r.panelClass||void 0}));return e.setOrigin(this._getFlexibleConnectedPositionStrategyOrigin()).withPositions(i).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const e=this._overlay.position().flexibleConnectedTo(this._getFlexibleConnectedPositionStrategyOrigin());return this._updatePositionStrategy(e),e}_getFlexibleConnectedPositionStrategyOrigin(){return this.origin instanceof sk?this.origin.elementRef:this.origin}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(e=>{this.backdropClick.emit(e)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(function T8(n,t=!1){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>{const o=n(s,r++);(o||t)&&i.next(s),!o&&i.complete()}))})}(()=>this.positionChange.observers.length>0)).subscribe(e=>{this.positionChange.emit(e),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}}return n.\u0275fac=function(e){return new(e||n)(x(Yi),x(_n),x(An),x(rk),x(qi,8))},n.\u0275dir=Me({type:n,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:["cdkConnectedOverlayOrigin","origin"],positions:["cdkConnectedOverlayPositions","positions"],positionStrategy:["cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:["cdkConnectedOverlayOffsetX","offsetX"],offsetY:["cdkConnectedOverlayOffsetY","offsetY"],width:["cdkConnectedOverlayWidth","width"],height:["cdkConnectedOverlayHeight","height"],minWidth:["cdkConnectedOverlayMinWidth","minWidth"],minHeight:["cdkConnectedOverlayMinHeight","minHeight"],backdropClass:["cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:["cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:["cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:["cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:["cdkConnectedOverlayOpen","open"],disableClose:["cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:["cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:["cdkConnectedOverlayHasBackdrop","hasBackdrop"],lockPosition:["cdkConnectedOverlayLockPosition","lockPosition"],flexibleDimensions:["cdkConnectedOverlayFlexibleDimensions","flexibleDimensions"],growAfterOpen:["cdkConnectedOverlayGrowAfterOpen","growAfterOpen"],push:["cdkConnectedOverlayPush","push"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[cn]}),n})();const $8={provide:rk,deps:[Yi],useFactory:function z8(n){return()=>n.scrollStrategies.reposition()}};let Pa=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[Yi,$8],imports:[ac,Os,N_,N_]}),n})(),ak=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),W8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[ih],imports:[ak,dh,ht,ak,dh]}),n})(),n$=(()=>{class n{constructor(){this.changes=new ue,this.calendarLabel="Calendar",this.openCalendarLabel="Open calendar",this.closeCalendarLabel="Close calendar",this.prevMonthLabel="Previous month",this.nextMonthLabel="Next month",this.prevYearLabel="Previous year",this.nextYearLabel="Next year",this.prevMultiYearLabel="Previous 24 years",this.nextMultiYearLabel="Next 24 years",this.switchToMonthViewLabel="Choose date",this.switchToMultiYearViewLabel="Choose month and year"}formatYearRange(e,i){return`${e} \u2013 ${i}`}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const s$={provide:new De("mat-datepicker-scroll-strategy"),deps:[Yi],useFactory:function r$(n){return()=>n.scrollStrategies.reposition()}};let d$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[n$,s$],imports:[pi,oh,Pa,Ku,Os,ht,Sa]}),n})();function _c(n){return new J(t=>{di(n()).subscribe(t)})}function u$(n,t){}class vh{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.closeOnNavigation=!0,this.closeOnDestroy=!0}}let uk=(()=>{class n extends hh{constructor(e,i,r,s,o,a,l,c){super(),this._elementRef=e,this._focusTrapFactory=i,this._config=s,this._interactivityChecker=o,this._ngZone=a,this._overlayRef=l,this._focusMonitor=c,this._elementFocusedBeforeDialogWasOpened=null,this._closeInteractionType=null,this.attachDomPortal=d=>{this._portalOutlet.hasAttached();const f=this._portalOutlet.attachDomPortal(d);return this._contentAttached(),f},this._ariaLabelledBy=this._config.ariaLabelledBy||null,this._document=r}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._restoreFocus()}attachComponentPortal(e){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachComponentPortal(e);return this._contentAttached(),i}attachTemplatePortal(e){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachTemplatePortal(e);return this._contentAttached(),i}_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(e,i){this._interactivityChecker.isFocusable(e)||(e.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const r=()=>{e.removeEventListener("blur",r),e.removeEventListener("mousedown",r),e.removeAttribute("tabindex")};e.addEventListener("blur",r),e.addEventListener("mousedown",r)})),e.focus(i)}_focusByCssSelector(e,i){let r=this._elementRef.nativeElement.querySelector(e);r&&this._forceFocus(r,i)}_trapFocus(){const e=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||e.focus();break;case!0:case"first-tabbable":this._focusTrap.focusInitialElementWhenReady().then(i=>{i||this._focusDialogContainer()});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}}_restoreFocus(){const e=this._config.restoreFocus;let i=null;if("string"==typeof e?i=this._document.querySelector(e):"boolean"==typeof e?i=e?this._elementFocusedBeforeDialogWasOpened:null:e&&(i=e),this._config.restoreFocus&&i&&"function"==typeof i.focus){const r=g_(),s=this._elementRef.nativeElement;(!r||r===this._document.body||r===s||s.contains(r))&&(this._focusMonitor?(this._focusMonitor.focusVia(i,this._closeInteractionType),this._closeInteractionType=null):i.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const e=this._elementRef.nativeElement,i=g_();return e===i||e.contains(i)}_initializeFocusTrap(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=g_())}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(vh),x(qu),x(et),x(gc),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["cdk-dialog-container"]],viewQuery:function(e,i){if(1&e&&Gt(Ra,7),2&e){let r;Ge(r=We())&&(i._portalOutlet=r.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(e,i){2&e&&wt("id",i._config.id||null)("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null)},features:[Le],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(e,i){1&e&&it(0,u$,0,0,"ng-template",0)},dependencies:[Ra],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2}),n})();class ev{constructor(t,e){this.overlayRef=t,this.config=e,this.closed=new ue,this.disableClose=e.disableClose,this.backdropClick=t.backdropClick(),this.keydownEvents=t.keydownEvents(),this.outsidePointerEvents=t.outsidePointerEvents(),this.id=e.id,this.keydownEvents.subscribe(i=>{27===i.keyCode&&!this.disableClose&&!gi(i)&&(i.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})})}close(t,e){if(this.containerInstance){const i=this.closed;this.containerInstance._closeInteractionType=(null==e?void 0:e.focusOrigin)||"program",this.overlayRef.dispose(),i.next(t),i.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(t="",e=""){return this.overlayRef.updateSize({width:t,height:e}),this}addPanelClass(t){return this.overlayRef.addPanelClass(t),this}removePanelClass(t){return this.overlayRef.removePanelClass(t),this}}const hk=new De("DialogScrollStrategy"),h$=new De("DialogData"),f$=new De("DefaultDialogConfig"),m$={provide:hk,deps:[Yi],useFactory:function p$(n){return()=>n.scrollStrategies.block()}};let g$=0,fk=(()=>{class n{constructor(e,i,r,s,o,a){this._overlay=e,this._injector=i,this._defaultOptions=r,this._parentDialog=s,this._overlayContainer=o,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new ue,this._afterOpenedAtThisLevel=new ue,this._ariaHiddenElements=new Map,this.afterAllClosed=_c(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qn(void 0))),this._scrollStrategy=a}get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}open(e,i){const r=this._defaultOptions||new vh;(i=Object.assign(Object.assign({},r),i)).id=i.id||"cdk-dialog-"+g$++,i.id&&this.getDialogById(i.id);const s=this._getOverlayConfig(i),o=this._overlay.create(s),a=new ev(o,i),l=this._attachContainer(o,a,i);return a.containerInstance=l,this._attachDialogContent(e,a,l,i),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(a),a.closed.subscribe(()=>this._removeOpenDialog(a,!0)),this.afterOpened.next(a),a}closeAll(){tv(this.openDialogs,e=>e.close())}getDialogById(e){return this.openDialogs.find(i=>i.id===e)}ngOnDestroy(){tv(this._openDialogsAtThisLevel,e=>{!1===e.config.closeOnDestroy&&this._removeOpenDialog(e,!1)}),tv(this._openDialogsAtThisLevel,e=>e.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(e){const i=new fh({positionStrategy:e.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:e.scrollStrategy||this._scrollStrategy(),panelClass:e.panelClass,hasBackdrop:e.hasBackdrop,direction:e.direction,minWidth:e.minWidth,minHeight:e.minHeight,maxWidth:e.maxWidth,maxHeight:e.maxHeight,width:e.width,height:e.height,disposeOnNavigation:e.closeOnNavigation});return e.backdropClass&&(i.backdropClass=e.backdropClass),i}_attachContainer(e,i,r){var s,o;const a=null!==(s=r.injector)&&void 0!==s?s:null===(o=r.viewContainerRef)||void 0===o?void 0:o.injector,l=[{provide:vh,useValue:r},{provide:ev,useValue:i},{provide:gc,useValue:e}];let c;r.container?"function"==typeof r.container?c=r.container:(c=r.container.type,l.push(...r.container.providers(r))):c=uk;const d=new pc(c,r.viewContainerRef,Jt.create({parent:a||this._injector,providers:l}),r.componentFactoryResolver);return e.attach(d).instance}_attachDialogContent(e,i,r,s){const o=this._createInjector(s,i,r);if(e instanceof _n){let a={$implicit:s.data,dialogRef:i};s.templateContext&&(a=Object.assign(Object.assign({},a),"function"==typeof s.templateContext?s.templateContext():s.templateContext)),r.attachTemplatePortal(new mc(e,null,a,o))}else{const a=r.attachComponentPortal(new pc(e,s.viewContainerRef,o,s.componentFactoryResolver));i.componentInstance=a.instance}}_createInjector(e,i,r){const s=e&&e.viewContainerRef&&e.viewContainerRef.injector,o=[{provide:h$,useValue:e.data},{provide:ev,useValue:i}];return e.providers&&("function"==typeof e.providers?o.push(...e.providers(i,e,r)):o.push(...e.providers)),e.direction&&(!s||!s.get(qi,null,at.Optional))&&o.push({provide:qi,useValue:{value:e.direction,change:tt()}}),Jt.create({parent:s||this._injector,providers:o})}_removeOpenDialog(e,i){const r=this.openDialogs.indexOf(e);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((s,o)=>{s?o.setAttribute("aria-hidden",s):o.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),i&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const e=this._overlayContainer.getContainerElement();if(e.parentElement){const i=e.parentElement.children;for(let r=i.length-1;r>-1;r--){const s=i[r];s!==e&&"SCRIPT"!==s.nodeName&&"STYLE"!==s.nodeName&&!s.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(s,s.getAttribute("aria-hidden")),s.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(Jt),te(f$,8),te(n,12),te(ph),te(hk))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function tv(n,t){let e=n.length;for(;e--;)t(n[e])}let _$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[fk,m$],imports:[Pa,Os,Ku,Os]}),n})();function v$(n,t){}const Fa={params:{enterAnimationDuration:"150ms",exitAnimationDuration:"75ms"}},y$={dialogContainer:jn("dialogContainer",[zt("void, exit",Qe({opacity:0,transform:"scale(0.7)"})),zt("enter",Qe({transform:"none"})),Wt("* => enter",VE([Zt("{{enterAnimationDuration}} cubic-bezier(0, 0, 0.2, 1)",Qe({transform:"none",opacity:1})),uu("@*",du(),{optional:!0})]),Fa),Wt("* => void, * => exit",VE([Zt("{{exitAnimationDuration}} cubic-bezier(0.4, 0.0, 0.2, 1)",Qe({opacity:0})),uu("@*",du(),{optional:!0})]),Fa)])};class yh{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.maxWidth="80vw",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.delayFocusTrap=!0,this.closeOnNavigation=!0,this.enterAnimationDuration=Fa.params.enterAnimationDuration,this.exitAnimationDuration=Fa.params.exitAnimationDuration}}let b$=(()=>{class n extends uk{constructor(e,i,r,s,o,a,l,c){super(e,i,r,s,o,a,l,c),this._animationStateChanged=new je}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(e){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:e})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(yh),x(qu),x(et),x(gc),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["ng-component"]],features:[Le],decls:0,vars:0,template:function(e,i){},encapsulation:2}),n})(),w$=(()=>{class n extends b${constructor(e,i,r,s,o,a,l,c,d){super(e,i,r,s,o,a,l,d),this._changeDetectorRef=c,this._state="enter"}_onAnimationDone({toState:e,totalTime:i}){"enter"===e?this._openAnimationDone(i):"exit"===e&&this._animationStateChanged.next({state:"closed",totalTime:i})}_onAnimationStart({toState:e,totalTime:i}){"enter"===e?this._animationStateChanged.next({state:"opening",totalTime:i}):("exit"===e||"void"===e)&&this._animationStateChanged.next({state:"closing",totalTime:i})}_startExitAnimation(){this._state="exit",this._changeDetectorRef.markForCheck()}_getAnimationState(){return{value:this._state,params:{enterAnimationDuration:this._config.enterAnimationDuration||Fa.params.enterAnimationDuration,exitAnimationDuration:this._config.exitAnimationDuration||Fa.params.exitAnimationDuration}}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(yh),x(qu),x(et),x(gc),x(en),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-dialog-container"],hostVars:7,hostBindings:function(e,i){1&e&&kd("@dialogContainer.start",function(s){return i._onAnimationStart(s)})("@dialogContainer.done",function(s){return i._onAnimationDone(s)}),2&e&&(Zr("id",i._config.id),wt("aria-modal",i._config.ariaModal)("role",i._config.role)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null),Id("@dialogContainer",i._getAnimationState()))},features:[Le],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(e,i){1&e&&it(0,v$,0,0,"ng-template",0)},dependencies:[Ra],styles:[".mat-dialog-container{display:block;padding:24px;border-radius:4px;box-sizing:border-box;overflow:auto;outline:0;width:100%;height:100%;min-height:inherit;max-height:inherit}.cdk-high-contrast-active .mat-dialog-container{outline:solid 1px}.mat-dialog-content{display:block;margin:0 -24px;padding:0 24px;max-height:65vh;overflow:auto;-webkit-overflow-scrolling:touch}.mat-dialog-title{margin:0 0 20px;display:block}.mat-dialog-actions{padding:8px 0;display:flex;flex-wrap:wrap;min-height:52px;align-items:center;box-sizing:content-box;margin-bottom:-24px}.mat-dialog-actions.mat-dialog-actions-align-center,.mat-dialog-actions[align=center]{justify-content:center}.mat-dialog-actions.mat-dialog-actions-align-end,.mat-dialog-actions[align=end]{justify-content:flex-end}.mat-dialog-actions .mat-button-base+.mat-button-base,.mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}"],encapsulation:2,data:{animation:[y$.dialogContainer]}}),n})();class C${constructor(t,e,i){this._ref=t,this._containerInstance=i,this._afterOpened=new ue,this._beforeClosed=new ue,this._state=0,this.disableClose=e.disableClose,this.id=t.id,i._animationStateChanged.pipe(yn(r=>"opened"===r.state),sn(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(yn(r=>"closed"===r.state),sn(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),t.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),$n(this.backdropClick(),this.keydownEvents().pipe(yn(r=>27===r.keyCode&&!this.disableClose&&!gi(r)))).subscribe(r=>{this.disableClose||(r.preventDefault(),function D$(n,t,e){n._closeInteractionType=t,n.close(e)}(this,"keydown"===r.type?"keyboard":"mouse"))})}close(t){this._result=t,this._containerInstance._animationStateChanged.pipe(yn(e=>"closing"===e.state),sn(1)).subscribe(e=>{this._beforeClosed.next(t),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),e.totalTime+100)}),this._state=1,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(t){let e=this._ref.config.positionStrategy;return t&&(t.left||t.right)?t.left?e.left(t.left):e.right(t.right):e.centerHorizontally(),t&&(t.top||t.bottom)?t.top?e.top(t.top):e.bottom(t.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(t="",e=""){return this._ref.updateSize(t,e),this}addPanelClass(t){return this._ref.addPanelClass(t),this}removePanelClass(t){return this._ref.removePanelClass(t),this}getState(){return this._state}_finishDialogClose(){this._state=2,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}const E$=new De("MatDialogData"),M$=new De("mat-dialog-default-options"),pk=new De("mat-dialog-scroll-strategy"),S$={provide:pk,deps:[Yi],useFactory:function x$(n){return()=>n.scrollStrategies.block()}};let k$=0,T$=(()=>{class n{constructor(e,i,r,s,o,a,l,c,d,f){this._overlay=e,this._defaultOptions=r,this._parentDialog=s,this._dialogRefConstructor=l,this._dialogContainerType=c,this._dialogDataToken=d,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new ue,this._afterOpenedAtThisLevel=new ue,this._idPrefix="mat-dialog-",this.afterAllClosed=_c(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qn(void 0))),this._scrollStrategy=a,this._dialog=i.get(fk)}get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}open(e,i){let r;(i=Object.assign(Object.assign({},this._defaultOptions||new yh),i)).id=i.id||`${this._idPrefix}${k$++}`,i.scrollStrategy=i.scrollStrategy||this._scrollStrategy();const s=this._dialog.open(e,Object.assign(Object.assign({},i),{positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:yh,useValue:i},{provide:vh,useValue:i}]},templateContext:()=>({dialogRef:r}),providers:(o,a,l)=>(r=new this._dialogRefConstructor(o,i,l),r.updatePosition(null==i?void 0:i.position),[{provide:this._dialogContainerType,useValue:l},{provide:this._dialogDataToken,useValue:a.data},{provide:this._dialogRefConstructor,useValue:r}])}));return r.componentInstance=s.componentInstance,this.openDialogs.push(r),this.afterOpened.next(r),r.afterClosed().subscribe(()=>{const o=this.openDialogs.indexOf(r);o>-1&&(this.openDialogs.splice(o,1),this.openDialogs.length||this._getAfterAllClosed().next())}),r}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(e){return this.openDialogs.find(i=>i.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(e){let i=e.length;for(;i--;)e[i].close()}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),A$=(()=>{class n extends T${constructor(e,i,r,s,o,a,l,c){super(e,i,s,a,l,o,C$,w$,E$,c)}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(Jt),te(Vl,8),te(M$,8),te(pk),te(n,12),te(ph),te(fn,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),I$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[A$,S$],imports:[_$,Pa,Os,ht,ht]}),n})();const R$=[[["","mat-grid-avatar",""],["","matGridAvatar",""]],[["","mat-line",""],["","matLine",""]],"*"],P$=["[mat-grid-avatar], [matGridAvatar]","[mat-line], [matLine]","*"];let F$=(()=>{class n{constructor(e){this._element=e}ngAfterContentInit(){!function TS(n,t,e="mat"){n.changes.pipe(Qn(n)).subscribe(({length:i})=>{hc(t,`${e}-2-line`,!1),hc(t,`${e}-3-line`,!1),hc(t,`${e}-multi-line`,!1),2===i||3===i?hc(t,`${e}-${i}-line`,!0):i>3&&hc(t,`${e}-multi-line`,!0)})}(this._lines,this._element)}}return n.\u0275fac=function(e){return new(e||n)(x(Je))},n.\u0275cmp=vt({type:n,selectors:[["mat-grid-tile-header"],["mat-grid-tile-footer"]],contentQueries:function(e,i,r){if(1&e&&It(r,kS,5),2&e){let s;Ge(s=We())&&(i._lines=s)}},ngContentSelectors:P$,decls:4,vars:0,consts:[[1,"mat-grid-list-text"]],template:function(e,i){1&e&&(Fn(R$),Tt(0),fe(1,"div",0),Tt(2,1),we(),Tt(3,2))},encapsulation:2,changeDetection:0}),n})(),L$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-grid-tile-header"]],hostAttrs:[1,"mat-grid-tile-header"]}),n})(),B$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rh,ht,rh,ht]}),n})();function La(n,t){const e=ut(n)?n:()=>n,i=r=>r.error(e());return new J(t?r=>t.schedule(i,0,r):i)}function os(n){return Pe((t,e)=>{let s,i=null,r=!1;i=t.subscribe(_e(e,void 0,void 0,o=>{s=di(n(o,os(n)(t))),i?(i.unsubscribe(),i=null,s.subscribe(e)):r=!0})),r&&(i.unsubscribe(),i=null,s.subscribe(e))})}function bh(n){return Pe((t,e)=>{try{t.subscribe(e)}finally{e.add(n)}})}const V$=["*"];let wh;function vc(n){var t;return(null===(t=function H$(){if(void 0===wh&&(wh=null,"undefined"!=typeof window)){const n=window;void 0!==n.trustedTypes&&(wh=n.trustedTypes.createPolicy("angular#components",{createHTML:t=>t}))}return wh}())||void 0===t?void 0:t.createHTML(n))||n}function gk(n){return Error(`Unable to find icon with the name "${n}"`)}function _k(n){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${n}".`)}function vk(n){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${n}".`)}class Co{constructor(t,e,i){this.url=t,this.svgText=e,this.options=i}}let Ch=(()=>{class n{constructor(e,i,r,s){this._httpClient=e,this._sanitizer=i,this._errorHandler=s,this._svgIconConfigs=new Map,this._iconSetConfigs=new Map,this._cachedIconsByUrl=new Map,this._inProgressUrlFetches=new Map,this._fontCssClassesByAlias=new Map,this._resolvers=[],this._defaultFontSetClass=["material-icons"],this._document=r}addSvgIcon(e,i,r){return this.addSvgIconInNamespace("",e,i,r)}addSvgIconLiteral(e,i,r){return this.addSvgIconLiteralInNamespace("",e,i,r)}addSvgIconInNamespace(e,i,r,s){return this._addSvgIconConfig(e,i,new Co(r,null,s))}addSvgIconResolver(e){return this._resolvers.push(e),this}addSvgIconLiteralInNamespace(e,i,r,s){const o=this._sanitizer.sanitize(Ut.HTML,r);if(!o)throw vk(r);const a=vc(o);return this._addSvgIconConfig(e,i,new Co("",a,s))}addSvgIconSet(e,i){return this.addSvgIconSetInNamespace("",e,i)}addSvgIconSetLiteral(e,i){return this.addSvgIconSetLiteralInNamespace("",e,i)}addSvgIconSetInNamespace(e,i,r){return this._addSvgIconSetConfig(e,new Co(i,null,r))}addSvgIconSetLiteralInNamespace(e,i,r){const s=this._sanitizer.sanitize(Ut.HTML,i);if(!s)throw vk(i);const o=vc(s);return this._addSvgIconSetConfig(e,new Co("",o,r))}registerFontClassAlias(e,i=e){return this._fontCssClassesByAlias.set(e,i),this}classNameForFontAlias(e){return this._fontCssClassesByAlias.get(e)||e}setDefaultFontSetClass(...e){return this._defaultFontSetClass=e,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(e){const i=this._sanitizer.sanitize(Ut.RESOURCE_URL,e);if(!i)throw _k(e);const r=this._cachedIconsByUrl.get(i);return r?tt(Dh(r)):this._loadSvgIconFromConfig(new Co(e,null)).pipe(wn(s=>this._cachedIconsByUrl.set(i,s)),U(s=>Dh(s)))}getNamedSvgIcon(e,i=""){const r=yk(i,e);let s=this._svgIconConfigs.get(r);if(s)return this._getSvgFromConfig(s);if(s=this._getIconConfigFromResolvers(i,e),s)return this._svgIconConfigs.set(r,s),this._getSvgFromConfig(s);const o=this._iconSetConfigs.get(i);return o?this._getSvgFromIconSetConfigs(e,o):La(gk(r))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(e){return e.svgText?tt(Dh(this._svgElementFromConfig(e))):this._loadSvgIconFromConfig(e).pipe(U(i=>Dh(i)))}_getSvgFromIconSetConfigs(e,i){const r=this._extractIconWithNameFromAnySet(e,i);return r?tt(r):kM(i.filter(o=>!o.svgText).map(o=>this._loadSvgIconSetFromConfig(o).pipe(os(a=>{const c=`Loading icon set URL: ${this._sanitizer.sanitize(Ut.RESOURCE_URL,o.url)} failed: ${a.message}`;return this._errorHandler.handleError(new Error(c)),tt(null)})))).pipe(U(()=>{const o=this._extractIconWithNameFromAnySet(e,i);if(!o)throw gk(e);return o}))}_extractIconWithNameFromAnySet(e,i){for(let r=i.length-1;r>=0;r--){const s=i[r];if(s.svgText&&s.svgText.toString().indexOf(e)>-1){const o=this._svgElementFromConfig(s),a=this._extractSvgIconFromSet(o,e,s.options);if(a)return a}}return null}_loadSvgIconFromConfig(e){return this._fetchIcon(e).pipe(wn(i=>e.svgText=i),U(()=>this._svgElementFromConfig(e)))}_loadSvgIconSetFromConfig(e){return e.svgText?tt(null):this._fetchIcon(e).pipe(wn(i=>e.svgText=i))}_extractSvgIconFromSet(e,i,r){const s=e.querySelector(`[id="${i}"]`);if(!s)return null;const o=s.cloneNode(!0);if(o.removeAttribute("id"),"svg"===o.nodeName.toLowerCase())return this._setSvgAttributes(o,r);if("symbol"===o.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement(o),r);const a=this._svgElementFromString(vc(""));return a.appendChild(o),this._setSvgAttributes(a,r)}_svgElementFromString(e){const i=this._document.createElement("DIV");i.innerHTML=e;const r=i.querySelector("svg");if(!r)throw Error(" tag not found");return r}_toSvgElement(e){const i=this._svgElementFromString(vc("")),r=e.attributes;for(let s=0;svc(d)),bh(()=>this._inProgressUrlFetches.delete(a)),dy());return this._inProgressUrlFetches.set(a,c),c}_addSvgIconConfig(e,i,r){return this._svgIconConfigs.set(yk(e,i),r),this}_addSvgIconSetConfig(e,i){const r=this._iconSetConfigs.get(e);return r?r.push(i):this._iconSetConfigs.set(e,[i]),this}_svgElementFromConfig(e){if(!e.svgElement){const i=this._svgElementFromString(e.svgText);this._setSvgAttributes(i,e.options),e.svgElement=i}return e.svgElement}_getIconConfigFromResolvers(e,i){for(let r=0;rt?t.pathname+t.search:""}}}),bk=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],Y$=bk.map(n=>`[${n}]`).join(", "),K$=/^url\(['"]?#(.*?)['"]?\)$/;let Eh=(()=>{class n extends $${constructor(e,i,r,s,o,a){super(e),this._iconRegistry=i,this._location=s,this._errorHandler=o,this._inline=!1,this._previousFontSetClass=[],this._currentIconFetch=X.EMPTY,a&&(a.color&&(this.color=this.defaultColor=a.color),a.fontSet&&(this.fontSet=a.fontSet)),r||e.nativeElement.setAttribute("aria-hidden","true")}get inline(){return this._inline}set inline(e){this._inline=rt(e)}get svgIcon(){return this._svgIcon}set svgIcon(e){e!==this._svgIcon&&(e?this._updateSvgIcon(e):this._svgIcon&&this._clearSvgElement(),this._svgIcon=e)}get fontSet(){return this._fontSet}set fontSet(e){const i=this._cleanupFontValue(e);i!==this._fontSet&&(this._fontSet=i,this._updateFontIconClasses())}get fontIcon(){return this._fontIcon}set fontIcon(e){const i=this._cleanupFontValue(e);i!==this._fontIcon&&(this._fontIcon=i,this._updateFontIconClasses())}_splitIconName(e){if(!e)return["",""];const i=e.split(":");switch(i.length){case 1:return["",i[0]];case 2:return i;default:throw Error(`Invalid icon name: "${e}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const e=this._elementsWithExternalReferences;if(e&&e.size){const i=this._location.getPathname();i!==this._previousPath&&(this._previousPath=i,this._prependPathToReferences(i))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(e){this._clearSvgElement();const i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(e),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(e)}_clearSvgElement(){const e=this._elementRef.nativeElement;let i=e.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();i--;){const r=e.childNodes[i];(1!==r.nodeType||"svg"===r.nodeName.toLowerCase())&&r.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const e=this._elementRef.nativeElement,i=(this.fontSet?[this._iconRegistry.classNameForFontAlias(this.fontSet)]:this._iconRegistry.getDefaultFontSetClass()).filter(r=>r.length>0);this._previousFontSetClass.forEach(r=>e.classList.remove(r)),i.forEach(r=>e.classList.add(r)),this._previousFontSetClass=i,this.fontIcon!==this._previousFontIconClass&&(this._previousFontIconClass&&e.classList.remove(this._previousFontIconClass),this.fontIcon&&e.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(e){return"string"==typeof e?e.trim().split(" ")[0]:e}_prependPathToReferences(e){const i=this._elementsWithExternalReferences;i&&i.forEach((r,s)=>{r.forEach(o=>{s.setAttribute(o.name,`url('${e}#${o.value}')`)})})}_cacheChildrenWithExternalReferences(e){const i=e.querySelectorAll(Y$),r=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let s=0;s{const a=i[s],l=a.getAttribute(o),c=l?l.match(K$):null;if(c){let d=r.get(a);d||(d=[],r.set(a,d)),d.push({name:o,value:c[1]})}})}_updateSvgIcon(e){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),e){const[i,r]=this._splitIconName(e);i&&(this._svgNamespace=i),r&&(this._svgName=r),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(r,i).pipe(sn(1)).subscribe(s=>this._setSvgElement(s),s=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${i}:${r}! ${s.message}`))})}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(Ch),ii("aria-hidden"),x(W$),x(qr),x(G$,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:7,hostBindings:function(e,i){2&e&&(wt("data-mat-icon-type",i._usingFontIcon()?"font":"svg")("data-mat-icon-name",i._svgName||i.fontIcon)("data-mat-icon-namespace",i._svgNamespace||i.fontSet),At("mat-icon-inline",i.inline)("mat-icon-no-color","primary"!==i.color&&"accent"!==i.color&&"warn"!==i.color))},inputs:{color:"color",inline:"inline",svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[Le],ngContentSelectors:V$,decls:1,vars:0,template:function(e,i){1&e&&(Fn(),Tt(0))},styles:[".mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0}),n})(),Q$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),Z$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),h5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rh,Ta,ht,q_,pi,rh,ht,q_,Z$]}),n})();function Rr(n,t){return Pe((e,i)=>{let r=null,s=0,o=!1;const a=()=>o&&!r&&i.complete();e.subscribe(_e(i,l=>{null==r||r.unsubscribe();let c=0;const d=s++;di(n(l,d)).subscribe(r=_e(i,f=>i.next(t?t(l,f,d,c++):f),()=>{r=null,a()}))},()=>{o=!0,a()}))})}const f5=["trigger"],p5=["panel"];function m5(n,t){if(1&n&&(fe(0,"span",8),Ue(1),we()),2&n){const e=lt();Ee(1),Kn(e.placeholder)}}function g5(n,t){if(1&n&&(fe(0,"span",12),Ue(1),we()),2&n){const e=lt(2);Ee(1),Kn(e.triggerValue)}}function _5(n,t){1&n&&Tt(0,0,["*ngSwitchCase","true"])}function v5(n,t){1&n&&(fe(0,"span",9),it(1,g5,2,1,"span",10),it(2,_5,1,0,"ng-content",11),we()),2&n&&(Ae("ngSwitch",!!lt().customTrigger),Ee(2),Ae("ngSwitchCase",!0))}function y5(n,t){if(1&n){const e=ki();fe(0,"div",13)(1,"div",14,15),$e("@transformPanel.done",function(r){return Bn(e),Vn(lt()._panelDoneAnimatingStream.next(r.toState))})("keydown",function(r){return Bn(e),Vn(lt()._handleKeydown(r))}),Tt(3,1),we()()}if(2&n){const e=lt();Ae("@transformPanelWrap",void 0),Ee(1),om("mat-select-panel ",e._getPanelTheme(),""),Hi("transform-origin",e._transformOrigin)("font-size",e._triggerFontSize,"px"),Ae("ngClass",e.panelClass)("@transformPanel",e.multiple?"showing-multiple":"showing"),wt("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby())}}const b5=[[["mat-select-trigger"]],"*"],w5=["mat-select-trigger","*"],Ck={transformPanelWrap:jn("transformPanelWrap",[Wt("* => void",uu("@transformPanel",[du()],{optional:!0}))]),transformPanel:jn("transformPanel",[zt("void",Qe({transform:"scaleY(0.8)",minWidth:"100%",opacity:0})),zt("showing",Qe({opacity:1,minWidth:"calc(100% + 32px)",transform:"scaleY(1)"})),zt("showing-multiple",Qe({opacity:1,minWidth:"calc(100% + 64px)",transform:"scaleY(1)"})),Wt("void => *",Zt("120ms cubic-bezier(0, 0, 0.2, 1)")),Wt("* => void",Zt("100ms 25ms linear",Qe({opacity:0})))])};let Dk=0;const Mk=new De("mat-select-scroll-strategy"),M5=new De("MAT_SELECT_CONFIG"),x5={provide:Mk,deps:[Yi],useFactory:function E5(n){return()=>n.scrollStrategies.reposition()}};class S5{constructor(t,e){this.source=t,this.value=e}}const k5=Rs(yo(uc(SS(class{constructor(n,t,e,i,r){this._elementRef=n,this._defaultErrorStateMatcher=t,this._parentForm=e,this._parentFormGroup=i,this.ngControl=r,this.stateChanges=new ue}})))),T5=new De("MatSelectTrigger");let A5=(()=>{class n extends k5{constructor(e,i,r,s,o,a,l,c,d,f,w,k,j,K){var ae,ce,Te;super(o,s,l,c,f),this._viewportRuler=e,this._changeDetectorRef=i,this._ngZone=r,this._dir=a,this._parentFormField=d,this._liveAnnouncer=j,this._defaultOptions=K,this._panelOpen=!1,this._compareWith=(he,Oe)=>he===Oe,this._uid="mat-select-"+Dk++,this._triggerAriaLabelledBy=null,this._destroy=new ue,this._onChange=()=>{},this._onTouched=()=>{},this._valueId="mat-select-value-"+Dk++,this._panelDoneAnimatingStream=new ue,this._overlayPanelClass=(null===(ae=this._defaultOptions)||void 0===ae?void 0:ae.overlayPanelClass)||"",this._focused=!1,this.controlType="mat-select",this._multiple=!1,this._disableOptionCentering=null!==(Te=null===(ce=this._defaultOptions)||void 0===ce?void 0:ce.disableOptionCentering)&&void 0!==Te&&Te,this.ariaLabel="",this.optionSelectionChanges=_c(()=>{const he=this.options;return he?he.changes.pipe(Qn(he),Rr(()=>$n(...he.map(Oe=>Oe.onSelectionChange)))):this._ngZone.onStable.pipe(sn(1),Rr(()=>this.optionSelectionChanges))}),this.openedChange=new je,this._openedStream=this.openedChange.pipe(yn(he=>he),U(()=>{})),this._closedStream=this.openedChange.pipe(yn(he=>!he),U(()=>{})),this.selectionChange=new je,this.valueChange=new je,this.ngControl&&(this.ngControl.valueAccessor=this),null!=(null==K?void 0:K.typeaheadDebounceInterval)&&(this._typeaheadDebounceInterval=K.typeaheadDebounceInterval),this._scrollStrategyFactory=k,this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=parseInt(w)||0,this.id=this.id}get focused(){return this._focused||this._panelOpen}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}get required(){var e,i,r,s;return null!==(s=null!==(e=this._required)&&void 0!==e?e:null===(r=null===(i=this.ngControl)||void 0===i?void 0:i.control)||void 0===r?void 0:r.hasValidator(Vg.required))&&void 0!==s&&s}set required(e){this._required=rt(e),this.stateChanges.next()}get multiple(){return this._multiple}set multiple(e){this._multiple=rt(e)}get disableOptionCentering(){return this._disableOptionCentering}set disableOptionCentering(e){this._disableOptionCentering=rt(e)}get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e)}get typeaheadDebounceInterval(){return this._typeaheadDebounceInterval}set typeaheadDebounceInterval(e){this._typeaheadDebounceInterval=Ii(e)}get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next()}ngOnInit(){this._selectionModel=new ah(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(k_(),Ot(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen))}ngAfterContentInit(){this._initKeyManager(),this._selectionModel.changed.pipe(Ot(this._destroy)).subscribe(e=>{e.added.forEach(i=>i.select()),e.removed.forEach(i=>i.deselect())}),this.options.changes.pipe(Qn(null),Ot(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const e=this._getTriggerAriaLabelledby(),i=this.ngControl;if(e!==this._triggerAriaLabelledBy){const r=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?r.setAttribute("aria-labelledby",e):r.removeAttribute("aria-labelledby")}i&&(this._previousControl!==i.control&&(void 0!==this._previousControl&&null!==i.disabled&&i.disabled!==this.disabled&&(this.disabled=i.disabled),this._previousControl=i.control),this.updateErrorState())}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}ngOnDestroy(){this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck())}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}writeValue(e){this._assignValue(e)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){var e,i;return this.multiple?(null===(e=this._selectionModel)||void 0===e?void 0:e.selected)||[]:null===(i=this._selectionModel)||void 0===i?void 0:i.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const e=this._selectionModel.selected.map(i=>i.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e))}_handleClosedKeydown(e){const i=e.keyCode,r=40===i||38===i||37===i||39===i,s=13===i||32===i,o=this._keyManager;if(!o.isTyping()&&s&&!gi(e)||(this.multiple||e.altKey)&&r)e.preventDefault(),this.open();else if(!this.multiple){const a=this.selected;o.onKeydown(e);const l=this.selected;l&&a!==l&&this._liveAnnouncer.announce(l.viewValue,1e4)}}_handleOpenKeydown(e){const i=this._keyManager,r=e.keyCode,s=40===r||38===r,o=i.isTyping();if(s&&e.altKey)e.preventDefault(),this.close();else if(o||13!==r&&32!==r||!i.activeItem||gi(e))if(!o&&this._multiple&&65===r&&e.ctrlKey){e.preventDefault();const a=this.options.some(l=>!l.disabled&&!l.selected);this.options.forEach(l=>{l.disabled||(a?l.select():l.deselect())})}else{const a=i.activeItemIndex;i.onKeydown(e),this._multiple&&s&&e.shiftKey&&i.activeItem&&i.activeItemIndex!==a&&i.activeItem._selectViaInteraction()}else e.preventDefault(),i.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe(sn(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(e){if(this._selectionModel.selected.forEach(i=>i.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)Array.isArray(e),e.forEach(i=>this._selectOptionByValue(i)),this._sortValues();else{const i=this._selectOptionByValue(e);i?this._keyManager.updateActiveItem(i):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(e){const i=this.options.find(r=>{if(this._selectionModel.isSelected(r))return!1;try{return null!=r.value&&this._compareWith(r.value,e)}catch(s){return!1}});return i&&this._selectionModel.select(i),i}_assignValue(e){return!!(e!==this._value||this._multiple&&Array.isArray(e))&&(this.options&&this._setSelectionByValue(e),this._value=e,!0)}_initKeyManager(){this._keyManager=new Z3(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.pipe(Ot(this._destroy)).subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.pipe(Ot(this._destroy)).subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const e=$n(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Ot(e)).subscribe(i=>{this._onSelect(i.source,i.isUserInput),i.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),$n(...this.options.map(i=>i._stateChanges)).pipe(Ot(e)).subscribe(()=>{this._changeDetectorRef.markForCheck(),this.stateChanges.next()})}_onSelect(e,i){const r=this._selectionModel.isSelected(e);null!=e.value||this._multiple?(r!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),i&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),i&&this.focus())):(e.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(e.value)),r!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const e=this.options.toArray();this._selectionModel.sort((i,r)=>this.sortComparator?this.sortComparator(i,r,e):e.indexOf(i)-e.indexOf(r)),this.stateChanges.next()}}_propagateChanges(e){let i=null;i=this.multiple?this.selected.map(r=>r.value):this.selected?this.selected.value:e,this._value=i,this.valueChange.emit(i),this._onChange(i),this.selectionChange.emit(this._getChangeEvent(i)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}_canOpen(){var e;return!this._panelOpen&&!this.disabled&&(null===(e=this.options)||void 0===e?void 0:e.length)>0}focus(e){this._elementRef.nativeElement.focus(e)}_getPanelAriaLabelledby(){var e;if(this.ariaLabel)return null;const i=null===(e=this._parentFormField)||void 0===e?void 0:e.getLabelId();return this.ariaLabelledby?(i?i+" ":"")+this.ariaLabelledby:i}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){var e;if(this.ariaLabel)return null;const i=null===(e=this._parentFormField)||void 0===e?void 0:e.getLabelId();let r=(i?i+" ":"")+this._valueId;return this.ariaLabelledby&&(r+=" "+this.ariaLabelledby),r}_panelDoneAnimating(e){this.openedChange.emit(e)}setDescribedByIds(e){e.length?this._elementRef.nativeElement.setAttribute("aria-describedby",e.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this._panelOpen||!this.empty||this._focused&&!!this._placeholder}}return n.\u0275fac=function(e){return new(e||n)(x(ss),x(en),x(et),x(ih),x(Je),x(qi,8),x(Xl,8),x(Jl,8),x(Z_,8),x(Tr,10),ii("tabindex"),x(Mk),x(P_),x(M5,8))},n.\u0275dir=Me({type:n,viewQuery:function(e,i){if(1&e&&(Gt(f5,5),Gt(p5,5),Gt(ok,5)),2&e){let r;Ge(r=We())&&(i.trigger=r.first),Ge(r=We())&&(i.panel=r.first),Ge(r=We())&&(i._overlayDir=r.first)}},inputs:{userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",placeholder:"placeholder",required:"required",multiple:"multiple",disableOptionCentering:"disableOptionCentering",compareWith:"compareWith",value:"value",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:"typeaheadDebounceInterval",sortComparator:"sortComparator",id:"id"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},features:[Le,cn]}),n})(),xk=(()=>{class n extends A5{constructor(){super(...arguments),this._scrollTop=0,this._triggerFontSize=0,this._transformOrigin="top",this._offsetY=0,this._positions=[{originX:"start",originY:"top",overlayX:"start",overlayY:"top"},{originX:"start",originY:"bottom",overlayX:"start",overlayY:"bottom"}]}_calculateOverlayScroll(e,i,r){const s=this._getItemHeight();return Math.min(Math.max(0,s*e-i+s/2),r)}ngOnInit(){super.ngOnInit(),this._viewportRuler.change().pipe(Ot(this._destroy)).subscribe(()=>{this.panelOpen&&(this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._changeDetectorRef.markForCheck())})}open(){super._canOpen()&&(super.open(),this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._triggerFontSize=parseInt(getComputedStyle(this.trigger.nativeElement).fontSize||"0"),this._calculateOverlayPosition(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this._triggerFontSize&&this._overlayDir.overlayRef&&this._overlayDir.overlayRef.overlayElement&&(this._overlayDir.overlayRef.overlayElement.style.fontSize=`${this._triggerFontSize}px`)}))}_scrollOptionIntoView(e){const i=LS(e,this.options,this.optionGroups),r=this._getItemHeight();this.panel.nativeElement.scrollTop=0===e&&1===i?0:function yz(n,t,e,i){return ne+i?Math.max(0,n-i+t):e}((e+i)*r,r,this.panel.nativeElement.scrollTop,256)}_positioningSettled(){this._calculateOverlayOffsetX(),this.panel.nativeElement.scrollTop=this._scrollTop}_panelDoneAnimating(e){this.panelOpen?this._scrollTop=0:(this._overlayDir.offsetX=0,this._changeDetectorRef.markForCheck()),super._panelDoneAnimating(e)}_getChangeEvent(e){return new S5(this,e)}_calculateOverlayOffsetX(){const e=this._overlayDir.overlayRef.overlayElement.getBoundingClientRect(),i=this._viewportRuler.getViewportSize(),r=this._isRtl(),s=this.multiple?56:32;let o;if(this.multiple)o=40;else if(this.disableOptionCentering)o=16;else{let c=this._selectionModel.selected[0]||this.options.first;o=c&&c.group?32:16}r||(o*=-1);const a=0-(e.left+o-(r?s:0)),l=e.right+o-i.width+(r?0:s);a>0?o+=a+8:l>0&&(o-=l+8),this._overlayDir.offsetX=Math.round(o),this._overlayDir.overlayRef.updatePosition()}_calculateOverlayOffsetY(e,i,r){const s=this._getItemHeight(),o=(s-this._triggerRect.height)/2,a=Math.floor(256/s);let l;return this.disableOptionCentering?0:(l=0===this._scrollTop?e*s:this._scrollTop===r?(e-(this._getItemCount()-a))*s+(s-(this._getItemCount()*s-256)%s):i-s/2,Math.round(-1*l-o))}_checkOverlayWithinViewport(e){const i=this._getItemHeight(),r=this._viewportRuler.getViewportSize(),s=this._triggerRect.top-8,o=r.height-this._triggerRect.bottom-8,a=Math.abs(this._offsetY),c=Math.min(this._getItemCount()*i,256)-a-this._triggerRect.height;c>o?this._adjustPanelUp(c,o):a>s?this._adjustPanelDown(a,s,e):this._transformOrigin=this._getOriginBasedOnOption()}_adjustPanelUp(e,i){const r=Math.round(e-i);this._scrollTop-=r,this._offsetY-=r,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop<=0&&(this._scrollTop=0,this._offsetY=0,this._transformOrigin="50% bottom 0px")}_adjustPanelDown(e,i,r){const s=Math.round(e-i);if(this._scrollTop+=s,this._offsetY+=s,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop>=r)return this._scrollTop=r,this._offsetY=0,void(this._transformOrigin="50% top 0px")}_calculateOverlayPosition(){const e=this._getItemHeight(),i=this._getItemCount(),r=Math.min(i*e,256),o=i*e-r;let a;a=this.empty?0:Math.max(this.options.toArray().indexOf(this._selectionModel.selected[0]),0),a+=LS(a,this.options,this.optionGroups);const l=r/2;this._scrollTop=this._calculateOverlayScroll(a,l,o),this._offsetY=this._calculateOverlayOffsetY(a,l,o),this._checkOverlayWithinViewport(o)}_getOriginBasedOnOption(){const e=this._getItemHeight(),i=(e-this._triggerRect.height)/2;return`50% ${Math.abs(this._offsetY)-i+e/2}px 0px`}_getItemHeight(){return 3*this._triggerFontSize}_getItemCount(){return this.options.length+this.optionGroups.length}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275cmp=vt({type:n,selectors:[["mat-select"]],contentQueries:function(e,i,r){if(1&e&&(It(r,T5,5),It(r,Y_,5),It(r,FS,5)),2&e){let s;Ge(s=We())&&(i.customTrigger=s.first),Ge(s=We())&&(i.options=s),Ge(s=We())&&(i.optionGroups=s)}},hostAttrs:["role","combobox","aria-autocomplete","none","aria-haspopup","true",1,"mat-select"],hostVars:19,hostBindings:function(e,i){1&e&&$e("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),2&e&&(wt("id",i.id)("tabindex",i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),At("mat-select-disabled",i.disabled)("mat-select-invalid",i.errorState)("mat-select-required",i.required)("mat-select-empty",i.empty)("mat-select-multiple",i.multiple))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matSelect"],features:[Xe([{provide:lh,useExisting:n},{provide:OS,useExisting:n}]),Le],ngContentSelectors:w5,decls:9,vars:12,consts:[["cdk-overlay-origin","",1,"mat-select-trigger",3,"click"],["origin","cdkOverlayOrigin","trigger",""],[1,"mat-select-value",3,"ngSwitch"],["class","mat-select-placeholder mat-select-min-line",4,"ngSwitchCase"],["class","mat-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-select-arrow-wrapper"],[1,"mat-select-arrow"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayMinWidth","cdkConnectedOverlayOffsetY","backdropClick","attach","detach"],[1,"mat-select-placeholder","mat-select-min-line"],[1,"mat-select-value-text",3,"ngSwitch"],["class","mat-select-min-line",4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-select-min-line"],[1,"mat-select-panel-wrap"],["role","listbox","tabindex","-1",3,"ngClass","keydown"],["panel",""]],template:function(e,i){if(1&e&&(Fn(b5),fe(0,"div",0,1),$e("click",function(){return i.toggle()}),fe(3,"div",2),it(4,m5,2,1,"span",3),it(5,v5,3,2,"span",4),we(),fe(6,"div",5),kt(7,"div",6),we()(),it(8,y5,4,14,"ng-template",7),$e("backdropClick",function(){return i.close()})("attach",function(){return i._onAttached()})("detach",function(){return i.close()})),2&e){const r=Js(1);wt("aria-owns",i.panelOpen?i.id+"-panel":null),Ee(3),Ae("ngSwitch",i.empty),wt("id",i._valueId),Ee(1),Ae("ngSwitchCase",!0),Ee(1),Ae("ngSwitchCase",!1),Ee(3),Ae("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",r)("cdkConnectedOverlayOpen",i.panelOpen)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayMinWidth",null==i._triggerRect?null:i._triggerRect.width)("cdkConnectedOverlayOffsetY",i._offsetY)}},dependencies:[eg,ba,iu,cE,ok,sk],styles:['.mat-select{display:inline-block;width:100%;outline:none}.mat-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-select-disabled .mat-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-select-arrow-wrapper{height:16px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-outline .mat-select-arrow-wrapper{transform:translateY(-25%)}.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:none}.mat-select-arrow{width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;margin:0 4px}.mat-form-field.mat-focused .mat-select-arrow{transform:translateX(0)}.mat-select-panel-wrap{flex-basis:100%}.mat-select-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;padding-top:0;padding-bottom:0;max-height:256px;min-width:100%;border-radius:4px;outline:0}.cdk-high-contrast-active .mat-select-panel{outline:solid 1px}.mat-select-panel .mat-optgroup-label,.mat-select-panel .mat-option{font-size:inherit;line-height:3em;height:3em}.mat-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-form-field-flex{cursor:pointer}.mat-form-field-type-mat-select .mat-form-field-label{width:calc(100% - 18px)}.mat-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}'],encapsulation:2,data:{animation:[Ck.transformPanelWrap,Ck.transformPanel]},changeDetection:0}),n})(),Sk=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[x5],imports:[pi,Pa,NS,ht,Sa,dh,NS,ht]}),n})();const O5={provide:new De("mat-tooltip-scroll-strategy"),deps:[Yi],useFactory:function P5(n){return()=>n.scrollStrategies.reposition({scrollThrottle:20})}};let kk=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[O5],imports:[Ku,pi,Pa,ht,ht,Sa]}),n})(),nv=(()=>{class n{constructor(){this.changes=new ue,this.itemsPerPageLabel="Items per page:",this.nextPageLabel="Next page",this.previousPageLabel="Previous page",this.firstPageLabel="First page",this.lastPageLabel="Last page",this.getRangeLabel=(e,i,r)=>{if(0==r||0==i)return`0 of ${r}`;const s=e*i;return`${s+1} \u2013 ${s<(r=Math.max(r,0))?Math.min(s+i,r):s+i} of ${r}`}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const H5={provide:nv,deps:[[new Hn,new ir,nv]],useFactory:function V5(n){return n||new nv}};let j5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[H5],imports:[pi,oh,Sk,kk,ht]}),n})();function U5(n,t){if(1&n&&(Ja(),kt(0,"circle",4)),2&n){const e=lt(),i=Js(1);Hi("animation-name","mat-progress-spinner-stroke-rotate-"+e._spinnerAnimationLabel)("stroke-dashoffset",e._getStrokeDashOffset(),"px")("stroke-dasharray",e._getStrokeCircumference(),"px")("stroke-width",e._getCircleStrokeWidth(),"%")("transform-origin",e._getCircleTransformOrigin(i)),wt("r",e._getCircleRadius())}}function z5(n,t){if(1&n&&(Ja(),kt(0,"circle",4)),2&n){const e=lt(),i=Js(1);Hi("stroke-dashoffset",e._getStrokeDashOffset(),"px")("stroke-dasharray",e._getStrokeCircumference(),"px")("stroke-width",e._getCircleStrokeWidth(),"%")("transform-origin",e._getCircleTransformOrigin(i)),wt("r",e._getCircleRadius())}}const G5=vo(class{constructor(n){this._elementRef=n}},"primary"),W5=new De("mat-progress-spinner-default-options",{providedIn:"root",factory:function q5(){return{diameter:100}}});class Fs extends G5{constructor(t,e,i,r,s,o,a,l){super(t),this._document=i,this._diameter=100,this._value=0,this._resizeSubscription=X.EMPTY,this.mode="determinate";const c=Fs._diameters;this._spinnerAnimationLabel=this._getSpinnerAnimationLabel(),c.has(i.head)||c.set(i.head,new Set([100])),this._noopAnimations="NoopAnimations"===r&&!!s&&!s._forceAnimations,"mat-spinner"===t.nativeElement.nodeName.toLowerCase()&&(this.mode="indeterminate"),s&&(s.color&&(this.color=this.defaultColor=s.color),s.diameter&&(this.diameter=s.diameter),s.strokeWidth&&(this.strokeWidth=s.strokeWidth)),e.isBrowser&&e.SAFARI&&a&&o&&l&&(this._resizeSubscription=a.change(150).subscribe(()=>{"indeterminate"===this.mode&&l.run(()=>o.markForCheck())}))}get diameter(){return this._diameter}set diameter(t){this._diameter=Ii(t),this._spinnerAnimationLabel=this._getSpinnerAnimationLabel(),this._styleRoot&&this._attachStyleNode()}get strokeWidth(){return this._strokeWidth||this.diameter/10}set strokeWidth(t){this._strokeWidth=Ii(t)}get value(){return"determinate"===this.mode?this._value:0}set value(t){this._value=Math.max(0,Math.min(100,Ii(t)))}ngOnInit(){const t=this._elementRef.nativeElement;this._styleRoot=ju(t)||this._document.head,this._attachStyleNode(),t.classList.add("mat-progress-spinner-indeterminate-animation")}ngOnDestroy(){this._resizeSubscription.unsubscribe()}_getCircleRadius(){return(this.diameter-10)/2}_getViewBox(){const t=2*this._getCircleRadius()+this.strokeWidth;return`0 0 ${t} ${t}`}_getStrokeCircumference(){return 2*Math.PI*this._getCircleRadius()}_getStrokeDashOffset(){return"determinate"===this.mode?this._getStrokeCircumference()*(100-this._value)/100:null}_getCircleStrokeWidth(){return this.strokeWidth/this.diameter*100}_getCircleTransformOrigin(t){var e;const i=50*(null!==(e=t.currentScale)&&void 0!==e?e:1);return`${i}% ${i}%`}_attachStyleNode(){const t=this._styleRoot,e=this._diameter,i=Fs._diameters;let r=i.get(t);if(!r||!r.has(e)){const s=this._document.createElement("style");s.setAttribute("mat-spinner-animation",this._spinnerAnimationLabel),s.textContent=this._getAnimationText(),t.appendChild(s),r||(r=new Set,i.set(t,r)),r.add(e)}}_getAnimationText(){const t=this._getStrokeCircumference();return"\n @keyframes mat-progress-spinner-stroke-rotate-DIAMETER {\n 0% { stroke-dashoffset: START_VALUE; transform: rotate(0); }\n 12.5% { stroke-dashoffset: END_VALUE; transform: rotate(0); }\n 12.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n 25% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n\n 25.0001% { stroke-dashoffset: START_VALUE; transform: rotate(270deg); }\n 37.5% { stroke-dashoffset: END_VALUE; transform: rotate(270deg); }\n 37.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n 50% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n\n 50.0001% { stroke-dashoffset: START_VALUE; transform: rotate(180deg); }\n 62.5% { stroke-dashoffset: END_VALUE; transform: rotate(180deg); }\n 62.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n 75% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n\n 75.0001% { stroke-dashoffset: START_VALUE; transform: rotate(90deg); }\n 87.5% { stroke-dashoffset: END_VALUE; transform: rotate(90deg); }\n 87.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n 100% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n }\n".replace(/START_VALUE/g,""+.95*t).replace(/END_VALUE/g,""+.2*t).replace(/DIAMETER/g,`${this._spinnerAnimationLabel}`)}_getSpinnerAnimationLabel(){return this.diameter.toString().replace(".","_")}}Fs._diameters=new WeakMap,Fs.\u0275fac=function(t){return new(t||Fs)(x(Je),x(bn),x(ct,8),x(fn,8),x(W5),x(en),x(ss),x(et))},Fs.\u0275cmp=vt({type:Fs,selectors:[["mat-progress-spinner"],["mat-spinner"]],hostAttrs:["role","progressbar","tabindex","-1",1,"mat-progress-spinner","mat-spinner"],hostVars:10,hostBindings:function(t,e){2&t&&(wt("aria-valuemin","determinate"===e.mode?0:null)("aria-valuemax","determinate"===e.mode?100:null)("aria-valuenow","determinate"===e.mode?e.value:null)("mode",e.mode),Hi("width",e.diameter,"px")("height",e.diameter,"px"),At("_mat-animation-noopable",e._noopAnimations))},inputs:{color:"color",diameter:"diameter",strokeWidth:"strokeWidth",mode:"mode",value:"value"},exportAs:["matProgressSpinner"],features:[Le],decls:4,vars:8,consts:[["preserveAspectRatio","xMidYMid meet","focusable","false","aria-hidden","true",3,"ngSwitch"],["svg",""],["cx","50%","cy","50%",3,"animation-name","stroke-dashoffset","stroke-dasharray","stroke-width","transform-origin",4,"ngSwitchCase"],["cx","50%","cy","50%",3,"stroke-dashoffset","stroke-dasharray","stroke-width","transform-origin",4,"ngSwitchCase"],["cx","50%","cy","50%"]],template:function(t,e){1&t&&(Ja(),fe(0,"svg",0,1),it(2,U5,1,11,"circle",2),it(3,z5,1,9,"circle",3),we()),2&t&&(Hi("width",e.diameter,"px")("height",e.diameter,"px"),Ae("ngSwitch","indeterminate"===e.mode),wt("viewBox",e._getViewBox()),Ee(2),Ae("ngSwitchCase",!0),Ee(1),Ae("ngSwitchCase",!1))},dependencies:[ba,iu],styles:[".mat-progress-spinner{display:block;position:relative;overflow:hidden}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:rgba(0,0,0,0);transition:stroke-dashoffset 225ms linear}.cdk-high-contrast-active .mat-progress-spinner circle{stroke:CanvasText}.mat-progress-spinner[mode=indeterminate] svg{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}.mat-progress-spinner[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}.mat-progress-spinner._mat-animation-noopable svg,.mat-progress-spinner._mat-animation-noopable circle{animation:none;transition:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}"],encapsulation:2,changeDetection:0});let K5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,pi,ht]}),n})(),c4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,ht]}),n})(),b4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,ht]}),n})(),sv=(()=>{class n{constructor(){this.changes=new ue}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const C4={provide:sv,deps:[[new Hn,new ir,sv]],useFactory:function w4(n){return n||new sv}};let D4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[C4],imports:[pi,ht]}),n})(),B4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[N_]}),n})(),t6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[B4,ht,ht]}),n})();const r6=["*"],s6=["tabListContainer"],o6=["tabList"],a6=["tabListInner"],l6=["nextPaginator"],c6=["previousPaginator"],f6=["mat-tab-nav-bar",""],p6=new De("MatInkBarPositioner",{providedIn:"root",factory:function m6(){return t=>({left:t?(t.offsetLeft||0)+"px":"0",width:t?(t.offsetWidth||0)+"px":"0"})}});let $k=(()=>{class n{constructor(e,i,r,s){this._elementRef=e,this._ngZone=i,this._inkBarPositioner=r,this._animationMode=s}alignToElement(e){this.show(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{const i=this._inkBarPositioner(e),r=this._elementRef.nativeElement;r.style.left=i.left,r.style.width=i.width})}show(){this._elementRef.nativeElement.style.visibility="visible"}hide(){this._elementRef.nativeElement.style.visibility="hidden"}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(p6),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["mat-ink-bar"]],hostAttrs:[1,"mat-ink-bar"],hostVars:2,hostBindings:function(e,i){2&e&&At("_mat-animation-noopable","NoopAnimations"===i._animationMode)}}),n})();const Gk=Ar({passive:!0});let v6=(()=>{class n{constructor(e,i,r,s,o,a,l){this._elementRef=e,this._changeDetectorRef=i,this._viewportRuler=r,this._dir=s,this._ngZone=o,this._platform=a,this._animationMode=l,this._scrollDistance=0,this._selectedIndexChanged=!1,this._destroyed=new ue,this._showPaginationControls=!1,this._disableScrollAfter=!0,this._disableScrollBefore=!0,this._stopScrolling=new ue,this._disablePagination=!1,this._selectedIndex=0,this.selectFocusedIndex=new je,this.indexFocused=new je,o.runOutsideAngular(()=>{_o(e.nativeElement,"mouseleave").pipe(Ot(this._destroyed)).subscribe(()=>{this._stopInterval()})})}get disablePagination(){return this._disablePagination}set disablePagination(e){this._disablePagination=rt(e)}get selectedIndex(){return this._selectedIndex}set selectedIndex(e){e=Ii(e),this._selectedIndex!=e&&(this._selectedIndexChanged=!0,this._selectedIndex=e,this._keyManager&&this._keyManager.updateActiveItem(e))}ngAfterViewInit(){_o(this._previousPaginator.nativeElement,"touchstart",Gk).pipe(Ot(this._destroyed)).subscribe(()=>{this._handlePaginatorPress("before")}),_o(this._nextPaginator.nativeElement,"touchstart",Gk).pipe(Ot(this._destroyed)).subscribe(()=>{this._handlePaginatorPress("after")})}ngAfterContentInit(){const e=this._dir?this._dir.change:tt("ltr"),i=this._viewportRuler.change(150),r=()=>{this.updatePagination(),this._alignInkBarToSelectedTab()};this._keyManager=new Wu(this._items).withHorizontalOrientation(this._getLayoutDirection()).withHomeAndEnd().withWrap(),this._keyManager.updateActiveItem(this._selectedIndex),this._ngZone.onStable.pipe(sn(1)).subscribe(r),$n(e,i,this._items.changes,this._itemsResized()).pipe(Ot(this._destroyed)).subscribe(()=>{this._ngZone.run(()=>{Promise.resolve().then(()=>{this._scrollDistance=Math.max(0,Math.min(this._getMaxScrollDistance(),this._scrollDistance)),r()})}),this._keyManager.withHorizontalOrientation(this._getLayoutDirection())}),this._keyManager.change.pipe(Ot(this._destroyed)).subscribe(s=>{this.indexFocused.emit(s),this._setTabFocus(s)})}_itemsResized(){return"function"!=typeof ResizeObserver?Fi:this._items.changes.pipe(Qn(this._items),Rr(e=>new J(i=>this._ngZone.runOutsideAngular(()=>{const r=new ResizeObserver(()=>{i.next()});return e.forEach(s=>{r.observe(s.elementRef.nativeElement)}),()=>{r.disconnect()}}))),S_(1))}ngAfterContentChecked(){this._tabLabelCount!=this._items.length&&(this.updatePagination(),this._tabLabelCount=this._items.length,this._changeDetectorRef.markForCheck()),this._selectedIndexChanged&&(this._scrollToLabel(this._selectedIndex),this._checkScrollingControls(),this._alignInkBarToSelectedTab(),this._selectedIndexChanged=!1,this._changeDetectorRef.markForCheck()),this._scrollDistanceChanged&&(this._updateTabScrollPosition(),this._scrollDistanceChanged=!1,this._changeDetectorRef.markForCheck())}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete(),this._stopScrolling.complete()}_handleKeydown(e){if(!gi(e))switch(e.keyCode){case 13:case 32:this.focusIndex!==this.selectedIndex&&(this.selectFocusedIndex.emit(this.focusIndex),this._itemSelected(e));break;default:this._keyManager.onKeydown(e)}}_onContentChanges(){const e=this._elementRef.nativeElement.textContent;e!==this._currentTextContent&&(this._currentTextContent=e||"",this._ngZone.run(()=>{this.updatePagination(),this._alignInkBarToSelectedTab(),this._changeDetectorRef.markForCheck()}))}updatePagination(){this._checkPaginationEnabled(),this._checkScrollingControls(),this._updateTabScrollPosition()}get focusIndex(){return this._keyManager?this._keyManager.activeItemIndex:0}set focusIndex(e){!this._isValidIndex(e)||this.focusIndex===e||!this._keyManager||this._keyManager.setActiveItem(e)}_isValidIndex(e){if(!this._items)return!0;const i=this._items?this._items.toArray()[e]:null;return!!i&&!i.disabled}_setTabFocus(e){if(this._showPaginationControls&&this._scrollToLabel(e),this._items&&this._items.length){this._items.toArray()[e].focus();const i=this._tabListContainer.nativeElement;i.scrollLeft="ltr"==this._getLayoutDirection()?0:i.scrollWidth-i.offsetWidth}}_getLayoutDirection(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}_updateTabScrollPosition(){if(this.disablePagination)return;const e=this.scrollDistance,i="ltr"===this._getLayoutDirection()?-e:e;this._tabList.nativeElement.style.transform=`translateX(${Math.round(i)}px)`,(this._platform.TRIDENT||this._platform.EDGE)&&(this._tabListContainer.nativeElement.scrollLeft=0)}get scrollDistance(){return this._scrollDistance}set scrollDistance(e){this._scrollTo(e)}_scrollHeader(e){return this._scrollTo(this._scrollDistance+("before"==e?-1:1)*this._tabListContainer.nativeElement.offsetWidth/3)}_handlePaginatorClick(e){this._stopInterval(),this._scrollHeader(e)}_scrollToLabel(e){if(this.disablePagination)return;const i=this._items?this._items.toArray()[e]:null;if(!i)return;const r=this._tabListContainer.nativeElement.offsetWidth,{offsetLeft:s,offsetWidth:o}=i.elementRef.nativeElement;let a,l;"ltr"==this._getLayoutDirection()?(a=s,l=a+o):(l=this._tabListInner.nativeElement.offsetWidth-s,a=l-o);const c=this.scrollDistance,d=this.scrollDistance+r;ad&&(this.scrollDistance+=l-d+60)}_checkPaginationEnabled(){if(this.disablePagination)this._showPaginationControls=!1;else{const e=this._tabListInner.nativeElement.scrollWidth>this._elementRef.nativeElement.offsetWidth;e||(this.scrollDistance=0),e!==this._showPaginationControls&&this._changeDetectorRef.markForCheck(),this._showPaginationControls=e}}_checkScrollingControls(){this.disablePagination?this._disableScrollAfter=this._disableScrollBefore=!0:(this._disableScrollBefore=0==this.scrollDistance,this._disableScrollAfter=this.scrollDistance==this._getMaxScrollDistance(),this._changeDetectorRef.markForCheck())}_getMaxScrollDistance(){return this._tabListInner.nativeElement.scrollWidth-this._tabListContainer.nativeElement.offsetWidth||0}_alignInkBarToSelectedTab(){const e=this._items&&this._items.length?this._items.toArray()[this.selectedIndex]:null,i=e?e.elementRef.nativeElement:null;i?this._inkBar.alignToElement(i):this._inkBar.hide()}_stopInterval(){this._stopScrolling.next()}_handlePaginatorPress(e,i){i&&null!=i.button&&0!==i.button||(this._stopInterval(),F_(650,100).pipe(Ot($n(this._stopScrolling,this._destroyed))).subscribe(()=>{const{maxScrollDistance:r,distance:s}=this._scrollHeader(e);(0===s||s>=r)&&this._stopInterval()}))}_scrollTo(e){if(this.disablePagination)return{maxScrollDistance:0,distance:0};const i=this._getMaxScrollDistance();return this._scrollDistance=Math.max(0,Math.min(i,e)),this._scrollDistanceChanged=!0,this._checkScrollingControls(),{maxScrollDistance:i,distance:this._scrollDistance}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(ss),x(qi,8),x(et),x(bn),x(fn,8))},n.\u0275dir=Me({type:n,inputs:{disablePagination:"disablePagination"}}),n})(),y6=0,qk=(()=>{class n extends v6{constructor(e,i,r,s,o,a,l){super(e,s,o,i,r,a,l),this._disableRipple=!1,this.color="primary"}get backgroundColor(){return this._backgroundColor}set backgroundColor(e){const i=this._elementRef.nativeElement.classList;i.remove(`mat-background-${this.backgroundColor}`),e&&i.add(`mat-background-${e}`),this._backgroundColor=e}get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=rt(e)}_itemSelected(){}ngAfterContentInit(){this._items.changes.pipe(Qn(null),Ot(this._destroyed)).subscribe(()=>{this.updateActiveLink()}),super.ngAfterContentInit()}updateActiveLink(){if(!this._items)return;const e=this._items.toArray();for(let i=0;i{class n extends qk{constructor(e,i,r,s,o,a,l){super(e,i,r,s,o,a,l)}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(qi,8),x(et),x(en),x(ss),x(bn),x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["","mat-tab-nav-bar",""]],contentQueries:function(e,i,r){if(1&e&&It(r,Kk,5),2&e){let s;Ge(s=We())&&(i._items=s)}},viewQuery:function(e,i){if(1&e&&(Gt($k,7),Gt(s6,7),Gt(o6,7),Gt(a6,7),Gt(l6,5),Gt(c6,5)),2&e){let r;Ge(r=We())&&(i._inkBar=r.first),Ge(r=We())&&(i._tabListContainer=r.first),Ge(r=We())&&(i._tabList=r.first),Ge(r=We())&&(i._tabListInner=r.first),Ge(r=We())&&(i._nextPaginator=r.first),Ge(r=We())&&(i._previousPaginator=r.first)}},hostAttrs:[1,"mat-tab-nav-bar","mat-tab-header"],hostVars:11,hostBindings:function(e,i){2&e&&(wt("role",i._getRole()),At("mat-tab-header-pagination-controls-enabled",i._showPaginationControls)("mat-tab-header-rtl","rtl"==i._getLayoutDirection())("mat-primary","warn"!==i.color&&"accent"!==i.color)("mat-accent","accent"===i.color)("mat-warn","warn"===i.color))},inputs:{color:"color"},exportAs:["matTabNavBar","matTabNav"],features:[Le],attrs:f6,ngContentSelectors:r6,decls:14,vars:10,consts:[["aria-hidden","true","type","button","mat-ripple","","tabindex","-1",1,"mat-tab-header-pagination","mat-tab-header-pagination-before","mat-elevation-z4",3,"matRippleDisabled","disabled","click","mousedown","touchend"],["previousPaginator",""],[1,"mat-tab-header-pagination-chevron"],[1,"mat-tab-link-container",3,"keydown"],["tabListContainer",""],[1,"mat-tab-list",3,"cdkObserveContent"],["tabList",""],[1,"mat-tab-links"],["tabListInner",""],["aria-hidden","true","type","button","mat-ripple","","tabindex","-1",1,"mat-tab-header-pagination","mat-tab-header-pagination-after","mat-elevation-z4",3,"matRippleDisabled","disabled","mousedown","click","touchend"],["nextPaginator",""]],template:function(e,i){1&e&&(Fn(),fe(0,"button",0,1),$e("click",function(){return i._handlePaginatorClick("before")})("mousedown",function(s){return i._handlePaginatorPress("before",s)})("touchend",function(){return i._stopInterval()}),kt(2,"div",2),we(),fe(3,"div",3,4),$e("keydown",function(s){return i._handleKeydown(s)}),fe(5,"div",5,6),$e("cdkObserveContent",function(){return i._onContentChanges()}),fe(7,"div",7,8),Tt(9),we(),kt(10,"mat-ink-bar"),we()(),fe(11,"button",9,10),$e("mousedown",function(s){return i._handlePaginatorPress("after",s)})("click",function(){return i._handlePaginatorClick("after")})("touchend",function(){return i._stopInterval()}),kt(13,"div",2),we()),2&e&&(At("mat-tab-header-pagination-disabled",i._disableScrollBefore),Ae("matRippleDisabled",i._disableScrollBefore||i.disableRipple)("disabled",i._disableScrollBefore||null),Ee(5),At("_mat-animation-noopable","NoopAnimations"===i._animationMode),Ee(6),At("mat-tab-header-pagination-disabled",i._disableScrollAfter),Ae("matRippleDisabled",i._disableScrollAfter||i.disableRipple)("disabled",i._disableScrollAfter||null))},dependencies:[Ps,T_,$k],styles:[".mat-tab-header{display:flex;overflow:hidden;position:relative;flex-shrink:0}.mat-tab-header-pagination{-webkit-user-select:none;user-select:none;position:relative;display:none;justify-content:center;align-items:center;min-width:32px;cursor:pointer;z-index:2;-webkit-tap-highlight-color:rgba(0,0,0,0);touch-action:none;box-sizing:content-box;background:none;border:none;outline:0;padding:0}.mat-tab-header-pagination::-moz-focus-inner{border:0}.mat-tab-header-pagination-controls-enabled .mat-tab-header-pagination{display:flex}.mat-tab-header-pagination-before,.mat-tab-header-rtl .mat-tab-header-pagination-after{padding-left:4px}.mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-rtl .mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(-135deg)}.mat-tab-header-rtl .mat-tab-header-pagination-before,.mat-tab-header-pagination-after{padding-right:4px}.mat-tab-header-rtl .mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(45deg)}.mat-tab-header-pagination-chevron{border-style:solid;border-width:2px 2px 0 0;height:8px;width:8px}.mat-tab-header-pagination-disabled{box-shadow:none;cursor:default}.mat-tab-list{flex-grow:1;position:relative;transition:transform 500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-tab-links{display:flex}[mat-align-tabs=center]>.mat-tab-link-container .mat-tab-links{justify-content:center}[mat-align-tabs=end]>.mat-tab-link-container .mat-tab-links{justify-content:flex-end}.mat-ink-bar{position:absolute;bottom:0;height:2px;transition:500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-ink-bar._mat-animation-noopable{transition:none !important;animation:none !important}.mat-tab-group-inverted-header .mat-ink-bar{bottom:auto;top:0}.cdk-high-contrast-active .mat-ink-bar{outline:solid 2px;height:0}.mat-tab-link-container{display:flex;flex-grow:1;overflow:hidden;z-index:1}.mat-tab-link{height:48px;padding:0 24px;cursor:pointer;box-sizing:border-box;opacity:.6;min-width:160px;text-align:center;display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;vertical-align:top;text-decoration:none;position:relative;overflow:hidden;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-tab-link:focus{outline:none}.mat-tab-link:focus:not(.mat-tab-disabled){opacity:1}.cdk-high-contrast-active .mat-tab-link:focus{outline:dotted 2px;outline-offset:-2px}.mat-tab-link.mat-tab-disabled{cursor:default}.cdk-high-contrast-active .mat-tab-link.mat-tab-disabled{opacity:.5}.mat-tab-link .mat-tab-label-content{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap}.cdk-high-contrast-active .mat-tab-link{opacity:1}[mat-stretch-tabs] .mat-tab-link{flex-basis:0;flex-grow:1}.mat-tab-link.mat-tab-disabled{pointer-events:none}@media(max-width: 599px){.mat-tab-link{min-width:72px}}"],encapsulation:2}),n})();const b6=yo(Rs(uc(class{})));let w6=(()=>{class n extends b6{constructor(e,i,r,s,o,a){super(),this._tabNavBar=e,this.elementRef=i,this._focusMonitor=o,this._isActive=!1,this.id="mat-tab-link-"+y6++,this.rippleConfig=r||{},this.tabIndex=parseInt(s)||0,"NoopAnimations"===a&&(this.rippleConfig.animation={enterDuration:0,exitDuration:0})}get active(){return this._isActive}set active(e){const i=rt(e);i!==this._isActive&&(this._isActive=i,this._tabNavBar.updateActiveLink())}get rippleDisabled(){return this.disabled||this.disableRipple||this._tabNavBar.disableRipple||!!this.rippleConfig.disabled}focus(){this.elementRef.nativeElement.focus()}ngAfterViewInit(){this._focusMonitor.monitor(this.elementRef)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this.elementRef)}_handleFocus(){this._tabNavBar.focusIndex=this._tabNavBar._items.toArray().indexOf(this)}_handleKeydown(e){this._tabNavBar.tabPanel&&32===e.keyCode&&this.elementRef.nativeElement.click()}_getAriaControls(){var e;return this._tabNavBar.tabPanel?null===(e=this._tabNavBar.tabPanel)||void 0===e?void 0:e.id:this.elementRef.nativeElement.getAttribute("aria-controls")}_getAriaSelected(){return this._tabNavBar.tabPanel?this.active?"true":"false":this.elementRef.nativeElement.getAttribute("aria-selected")}_getAriaCurrent(){return this.active&&!this._tabNavBar.tabPanel?"page":null}_getRole(){return this._tabNavBar.tabPanel?"tab":this.elementRef.nativeElement.getAttribute("role")}_getTabIndex(){return this._tabNavBar.tabPanel?this._isActive&&!this.disabled?0:-1:this.tabIndex}}return n.\u0275fac=function(e){return new(e||n)(x(qk),x(Je),x(sh,8),ii("tabindex"),x(hr),x(fn,8))},n.\u0275dir=Me({type:n,inputs:{active:"active",id:"id"},features:[Le]}),n})(),Kk=(()=>{class n extends w6{constructor(e,i,r,s,o,a,l,c){super(e,i,o,a,l,c),this._tabLinkRipple=new W_(this,r,i,s),this._tabLinkRipple.setupTriggerEvents(i.nativeElement)}ngOnDestroy(){super.ngOnDestroy(),this._tabLinkRipple._removeTriggerEvents()}}return n.\u0275fac=function(e){return new(e||n)(x(Yk),x(Je),x(et),x(bn),x(sh,8),ii("tabindex"),x(hr),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["","mat-tab-link",""],["","matTabLink",""]],hostAttrs:[1,"mat-tab-link","mat-focus-indicator"],hostVars:11,hostBindings:function(e,i){1&e&&$e("focus",function(){return i._handleFocus()})("keydown",function(s){return i._handleKeydown(s)}),2&e&&(wt("aria-controls",i._getAriaControls())("aria-current",i._getAriaCurrent())("aria-disabled",i.disabled)("aria-selected",i._getAriaSelected())("id",i.id)("tabIndex",i._getTabIndex())("role",i._getRole()),At("mat-tab-disabled",i.disabled)("mat-tab-label-active",i.active))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matTabLink"],features:[Le]}),n})(),C6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,Os,Ta,Gu,Ku,ht]}),n})(),D6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})();function gv(...n){const t=qa(n),e=oy(n),{args:i,keys:r}=xM(n);if(0===i.length)return gn([],t);const s=new J(function E6(n,t,e=N){return i=>{Qk(t,()=>{const{length:r}=n,s=new Array(r);let o=r,a=r;for(let l=0;l{const c=gn(n[l],t);let d=!1;c.subscribe(_e(i,f=>{s[l]=f,d||(d=!0,a--),a||i.next(e(s.slice()))},()=>{--o||i.complete()}))},i)},i)}}(i,t,r?o=>SM(r,o):N));return e?s.pipe(Ng(e)):s}function Qk(n,t,e){n?jr(e,n,t):t()}const Zk=new Set;let ja,M6=(()=>{class n{constructor(e){this._platform=e,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):S6}matchMedia(e){return(this._platform.WEBKIT||this._platform.BLINK)&&function x6(n){if(!Zk.has(n))try{ja||(ja=document.createElement("style"),ja.setAttribute("type","text/css"),document.head.appendChild(ja)),ja.sheet&&(ja.sheet.insertRule(`@media ${n} {body{ }}`,0),Zk.add(n))}catch(t){console.error(t)}}(e),this._matchMedia(e)}}return n.\u0275fac=function(e){return new(e||n)(te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function S6(n){return{matches:"all"===n||""===n,media:n,addListener:()=>{},removeListener:()=>{}}}let _v=(()=>{class n{constructor(e,i){this._mediaMatcher=e,this._zone=i,this._queries=new Map,this._destroySubject=new ue}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(e){return Xk(Uu(e)).some(r=>this._registerQuery(r).mql.matches)}observe(e){let s=gv(Xk(Uu(e)).map(o=>this._registerQuery(o).observable));return s=nh(s.pipe(sn(1)),s.pipe(S_(1),x_(0))),s.pipe(U(o=>{const a={matches:!1,breakpoints:{}};return o.forEach(({matches:l,query:c})=>{a.matches=a.matches||l,a.breakpoints[c]=l}),a}))}_registerQuery(e){if(this._queries.has(e))return this._queries.get(e);const i=this._mediaMatcher.matchMedia(e),s={observable:new J(o=>{const a=l=>this._zone.run(()=>o.next(l));return i.addListener(a),()=>{i.removeListener(a)}}).pipe(Qn(i),U(({matches:o})=>({query:e,matches:o})),Ot(this._destroySubject)),mql:i};return this._queries.set(e,s),s}}return n.\u0275fac=function(e){return new(e||n)(te(M6),te(et))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Xk(n){return n.map(t=>t.split(",")).reduce((t,e)=>t.concat(e)).map(t=>t.trim())}function T6(n,t){if(1&n){const e=ki();fe(0,"div",2)(1,"button",3),$e("click",function(){return Bn(e),Vn(lt().action())}),Ue(2),we()()}if(2&n){const e=lt();Ee(2),Kn(e.data.action)}}function A6(n,t){}const Jk=new De("MatSnackBarData");class Fh{constructor(){this.politeness="assertive",this.announcementMessage="",this.duration=0,this.data=null,this.horizontalPosition="center",this.verticalPosition="bottom"}}const I6=Math.pow(2,31)-1;class vv{constructor(t,e){this._overlayRef=e,this._afterDismissed=new ue,this._afterOpened=new ue,this._onAction=new ue,this._dismissedByAction=!1,this.containerInstance=t,t._onExit.subscribe(()=>this._finishDismiss())}dismiss(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}dismissWithAction(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete(),this.dismiss()),clearTimeout(this._durationTimeoutId)}closeWithAction(){this.dismissWithAction()}_dismissAfter(t){this._durationTimeoutId=setTimeout(()=>this.dismiss(),Math.min(t,I6))}_open(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}_finishDismiss(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}afterDismissed(){return this._afterDismissed}afterOpened(){return this.containerInstance._onEnter}onAction(){return this._onAction}}let R6=(()=>{class n{constructor(e,i){this.snackBarRef=e,this.data=i}action(){this.snackBarRef.dismissWithAction()}get hasAction(){return!!this.data.action}}return n.\u0275fac=function(e){return new(e||n)(x(vv),x(Jk))},n.\u0275cmp=vt({type:n,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-simple-snackbar"],decls:3,vars:2,consts:[[1,"mat-simple-snack-bar-content"],["class","mat-simple-snackbar-action",4,"ngIf"],[1,"mat-simple-snackbar-action"],["mat-button","",3,"click"]],template:function(e,i){1&e&&(fe(0,"span",0),Ue(1),we(),it(2,T6,3,1,"div",1)),2&e&&(Ee(1),Kn(i.data.message),Ee(1),Ae("ngIf",i.hasAction))},dependencies:[zi,Aa],styles:[".mat-simple-snackbar{display:flex;justify-content:space-between;align-items:center;line-height:20px;opacity:1}.mat-simple-snackbar-action{flex-shrink:0;margin:-8px -8px -8px 8px}.mat-simple-snackbar-action button{max-height:36px;min-width:0}[dir=rtl] .mat-simple-snackbar-action{margin-left:-8px;margin-right:8px}.mat-simple-snack-bar-content{overflow:hidden;text-overflow:ellipsis}"],encapsulation:2,changeDetection:0}),n})();const P6={snackBarState:jn("state",[zt("void, hidden",Qe({transform:"scale(0.8)",opacity:0})),zt("visible",Qe({transform:"scale(1)",opacity:1})),Wt("* => visible",Zt("150ms cubic-bezier(0, 0, 0.2, 1)")),Wt("* => void, * => hidden",Zt("75ms cubic-bezier(0.4, 0.0, 1, 1)",Qe({opacity:0})))])};let O6=(()=>{class n extends hh{constructor(e,i,r,s,o){super(),this._ngZone=e,this._elementRef=i,this._changeDetectorRef=r,this._platform=s,this.snackBarConfig=o,this._announceDelay=150,this._destroyed=!1,this._onAnnounce=new ue,this._onExit=new ue,this._onEnter=new ue,this._animationState="void",this.attachDomPortal=a=>{this._assertNotAttached();const l=this._portalOutlet.attachDomPortal(a);return this._afterPortalAttached(),l},this._live="assertive"!==o.politeness||o.announcementMessage?"off"===o.politeness?"off":"polite":"assertive",this._platform.FIREFOX&&("polite"===this._live&&(this._role="status"),"assertive"===this._live&&(this._role="alert"))}attachComponentPortal(e){this._assertNotAttached();const i=this._portalOutlet.attachComponentPortal(e);return this._afterPortalAttached(),i}attachTemplatePortal(e){this._assertNotAttached();const i=this._portalOutlet.attachTemplatePortal(e);return this._afterPortalAttached(),i}onAnimationEnd(e){const{fromState:i,toState:r}=e;if(("void"===r&&"void"!==i||"hidden"===r)&&this._completeExit(),"visible"===r){const s=this._onEnter;this._ngZone.run(()=>{s.next(),s.complete()})}}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges(),this._screenReaderAnnounce())}exit(){return this._ngZone.run(()=>{this._animationState="hidden",this._elementRef.nativeElement.setAttribute("mat-exit",""),clearTimeout(this._announceTimeoutId)}),this._onExit}ngOnDestroy(){this._destroyed=!0,this._completeExit()}_completeExit(){this._ngZone.onMicrotaskEmpty.pipe(sn(1)).subscribe(()=>{this._ngZone.run(()=>{this._onExit.next(),this._onExit.complete()})})}_afterPortalAttached(){const e=this._elementRef.nativeElement,i=this.snackBarConfig.panelClass;i&&(Array.isArray(i)?i.forEach(r=>e.classList.add(r)):e.classList.add(i))}_assertNotAttached(){this._portalOutlet.hasAttached()}_screenReaderAnnounce(){this._announceTimeoutId||this._ngZone.runOutsideAngular(()=>{this._announceTimeoutId=setTimeout(()=>{const e=this._elementRef.nativeElement.querySelector("[aria-hidden]"),i=this._elementRef.nativeElement.querySelector("[aria-live]");if(e&&i){let r=null;this._platform.isBrowser&&document.activeElement instanceof HTMLElement&&e.contains(document.activeElement)&&(r=document.activeElement),e.removeAttribute("aria-hidden"),i.appendChild(e),null==r||r.focus(),this._onAnnounce.next(),this._onAnnounce.complete()}},this._announceDelay)})}}return n.\u0275fac=function(e){return new(e||n)(x(et),x(Je),x(en),x(bn),x(Fh))},n.\u0275dir=Me({type:n,viewQuery:function(e,i){if(1&e&&Gt(Ra,7),2&e){let r;Ge(r=We())&&(i._portalOutlet=r.first)}},features:[Le]}),n})(),F6=(()=>{class n extends O6{_afterPortalAttached(){super._afterPortalAttached(),"center"===this.snackBarConfig.horizontalPosition&&this._elementRef.nativeElement.classList.add("mat-snack-bar-center"),"top"===this.snackBarConfig.verticalPosition&&this._elementRef.nativeElement.classList.add("mat-snack-bar-top")}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275cmp=vt({type:n,selectors:[["snack-bar-container"]],hostAttrs:[1,"mat-snack-bar-container"],hostVars:1,hostBindings:function(e,i){1&e&&kd("@state.done",function(s){return i.onAnimationEnd(s)}),2&e&&Id("@state",i._animationState)},features:[Le],decls:3,vars:2,consts:[["aria-hidden","true"],["cdkPortalOutlet",""]],template:function(e,i){1&e&&(fe(0,"div",0),it(1,A6,0,0,"ng-template",1),we(),kt(2,"div")),2&e&&(Ee(2),wt("aria-live",i._live)("role",i._role))},dependencies:[Ra],styles:[".mat-snack-bar-container{border-radius:4px;box-sizing:border-box;display:block;margin:24px;max-width:33vw;min-width:344px;padding:14px 16px;min-height:48px;transform-origin:center}.cdk-high-contrast-active .mat-snack-bar-container{border:solid 1px}.mat-snack-bar-handset{width:100%}.mat-snack-bar-handset .mat-snack-bar-container{margin:8px;max-width:100%;min-width:0;width:100%}"],encapsulation:2,data:{animation:[P6.snackBarState]}}),n})(),eT=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Pa,Os,pi,oh,ht,ht]}),n})();const tT=new De("mat-snack-bar-default-options",{providedIn:"root",factory:function L6(){return new Fh}});let N6=(()=>{class n{constructor(e,i,r,s,o,a){this._overlay=e,this._live=i,this._injector=r,this._breakpointObserver=s,this._parentSnackBar=o,this._defaultConfig=a,this._snackBarRefAtThisLevel=null}get _openedSnackBarRef(){const e=this._parentSnackBar;return e?e._openedSnackBarRef:this._snackBarRefAtThisLevel}set _openedSnackBarRef(e){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=e:this._snackBarRefAtThisLevel=e}openFromComponent(e,i){return this._attach(e,i)}openFromTemplate(e,i){return this._attach(e,i)}open(e,i="",r){const s=Object.assign(Object.assign({},this._defaultConfig),r);return s.data={message:e,action:i},s.announcementMessage===e&&(s.announcementMessage=void 0),this.openFromComponent(this.simpleSnackBarComponent,s)}dismiss(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}ngOnDestroy(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}_attachSnackBarContainer(e,i){const s=Jt.create({parent:i&&i.viewContainerRef&&i.viewContainerRef.injector||this._injector,providers:[{provide:Fh,useValue:i}]}),o=new pc(this.snackBarContainerComponent,i.viewContainerRef,s),a=e.attach(o);return a.instance.snackBarConfig=i,a.instance}_attach(e,i){const r=Object.assign(Object.assign(Object.assign({},new Fh),this._defaultConfig),i),s=this._createOverlay(r),o=this._attachSnackBarContainer(s,r),a=new vv(o,s);if(e instanceof _n){const l=new mc(e,null,{$implicit:r.data,snackBarRef:a});a.instance=o.attachTemplatePortal(l)}else{const l=this._createInjector(r,a),c=new pc(e,void 0,l),d=o.attachComponentPortal(c);a.instance=d.instance}return this._breakpointObserver.observe("(max-width: 599.98px) and (orientation: portrait)").pipe(Ot(s.detachments())).subscribe(l=>{s.overlayElement.classList.toggle(this.handsetCssClass,l.matches)}),r.announcementMessage&&o._onAnnounce.subscribe(()=>{this._live.announce(r.announcementMessage,r.politeness)}),this._animateSnackBar(a,r),this._openedSnackBarRef=a,this._openedSnackBarRef}_animateSnackBar(e,i){e.afterDismissed().subscribe(()=>{this._openedSnackBarRef==e&&(this._openedSnackBarRef=null),i.announcementMessage&&this._live.clear()}),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe(()=>{e.containerInstance.enter()}),this._openedSnackBarRef.dismiss()):e.containerInstance.enter(),i.duration&&i.duration>0&&e.afterOpened().subscribe(()=>e._dismissAfter(i.duration))}_createOverlay(e){const i=new fh;i.direction=e.direction;let r=this._overlay.position().global();const s="rtl"===e.direction,o="left"===e.horizontalPosition||"start"===e.horizontalPosition&&!s||"end"===e.horizontalPosition&&s,a=!o&&"center"!==e.horizontalPosition;return o?r.left("0"):a?r.right("0"):r.centerHorizontally(),"top"===e.verticalPosition?r.top("0"):r.bottom("0"),i.positionStrategy=r,this._overlay.create(i)}_createInjector(e,i){return Jt.create({parent:e&&e.viewContainerRef&&e.viewContainerRef.injector||this._injector,providers:[{provide:vv,useValue:i},{provide:Jk,useValue:e.data}]})}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(P_),te(Jt),te(_v),te(n,12),te(tT))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),B6=(()=>{class n extends N6{constructor(e,i,r,s,o,a){super(e,i,r,s,o,a),this.simpleSnackBarComponent=R6,this.snackBarContainerComponent=F6,this.handsetCssClass="mat-snack-bar-handset"}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(P_),te(Jt),te(_v),te(n,12),te(tT))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:eT}),n})();const Dc=Br(n=>function(){n(this),this.name="EmptyError",this.message="no elements in sequence"});function Lh(){return Pe((n,t)=>{let e=null;n._refCount++;const i=_e(t,void 0,void 0,void 0,()=>{if(!n||n._refCount<=0||0<--n._refCount)return void(e=null);const r=n._connection,s=e;e=null,r&&(!s||r===s)&&r.unsubscribe(),t.unsubscribe()});n.subscribe(i),i.closed||(e=n.connect())})}class yv extends J{constructor(t,e){super(),this.source=t,this.subjectFactory=e,this._subject=null,this._refCount=0,this._connection=null,Ne(t)&&(this.lift=t.lift)}_subscribe(t){return this.getSubject().subscribe(t)}getSubject(){const t=this._subject;return(!t||t.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;const{_connection:t}=this;this._subject=this._connection=null,null==t||t.unsubscribe()}connect(){let t=this._connection;if(!t){t=this._connection=new X;const e=this.getSubject();t.add(this.source.subscribe(_e(e,void 0,()=>{this._teardown(),e.complete()},i=>{this._teardown(),e.error(i)},()=>this._teardown()))),t.closed&&(this._connection=null,t=X.EMPTY)}return t}refCount(){return Lh()(this)}}function V6(n,t,e,i,r){return(s,o)=>{let a=e,l=t,c=0;s.subscribe(_e(o,d=>{const f=c++;l=a?n(l,d,f):(a=!0,d),i&&o.next(l)},r&&(()=>{a&&o.next(l),o.complete()})))}}function nT(n,t){return Pe(V6(n,t,arguments.length>=2,!0))}function bv(n){return n<=0?()=>Fi:Pe((t,e)=>{let i=[];t.subscribe(_e(e,r=>{i.push(r),n{for(const r of i)e.next(r);e.complete()},void 0,()=>{i=null}))})}function iT(n=H6){return Pe((t,e)=>{let i=!1;t.subscribe(_e(e,r=>{i=!0,e.next(r)},()=>i?e.complete():e.error(n())))})}function H6(){return new Dc}function wv(n){return Pe((t,e)=>{let i=!1;t.subscribe(_e(e,r=>{i=!0,e.next(r)},()=>{i||e.next(n),e.complete()}))})}function Do(n,t){const e=arguments.length>=2;return i=>i.pipe(n?yn((r,s)=>n(r,s,i)):N,sn(1),e?wv(t):iT(()=>new Dc))}class cs{constructor(t,e){this.id=t,this.url=e}}class Cv extends cs{constructor(t,e,i="imperative",r=null){super(t,e),this.type=0,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class Ec extends cs{constructor(t,e,i){super(t,e),this.urlAfterRedirects=i,this.type=1}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}class rT extends cs{constructor(t,e,i){super(t,e),this.reason=i,this.type=2}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class z6 extends cs{constructor(t,e,i){super(t,e),this.error=i,this.type=3}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class $6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=4}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class G6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=7}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class W6 extends cs{constructor(t,e,i,r,s){super(t,e),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=8}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class q6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=5}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Y6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=6}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class K6{constructor(t){this.route=t,this.type=9}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class Q6{constructor(t){this.route=t,this.type=10}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class Z6{constructor(t){this.snapshot=t,this.type=11}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class X6{constructor(t){this.snapshot=t,this.type=12}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class J6{constructor(t){this.snapshot=t,this.type=13}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class eG{constructor(t){this.snapshot=t,this.type=14}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class sT{constructor(t,e,i){this.routerEvent=t,this.position=e,this.anchor=i,this.type=15}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}const Et="primary";class tG{constructor(t){this.params=t||{}}has(t){return Object.prototype.hasOwnProperty.call(this.params,t)}get(t){if(this.has(t)){const e=this.params[t];return Array.isArray(e)?e[0]:e}return null}getAll(t){if(this.has(t)){const e=this.params[t];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}}function Ua(n){return new tG(n)}const oT="ngNavigationCancelingError";function Dv(n){const t=Error("NavigationCancelingError: "+n);return t[oT]=!0,t}function iG(n,t,e){const i=e.path.split("/");if(i.length>n.length||"full"===e.pathMatch&&(t.hasChildren()||i.lengthi[s]===r)}return n===t}function lT(n){return Array.prototype.concat.apply([],n)}function cT(n){return n.length>0?n[n.length-1]:null}function Un(n,t){for(const e in n)n.hasOwnProperty(e)&&t(n[e],e)}function fr(n){return em(n)?n:Cl(n)?gn(Promise.resolve(n)):tt(n)}const oG={exact:function hT(n,t,e){if(!Mo(n.segments,t.segments)||!Nh(n.segments,t.segments,e)||n.numberOfChildren!==t.numberOfChildren)return!1;for(const i in t.children)if(!n.children[i]||!hT(n.children[i],t.children[i],e))return!1;return!0},subset:fT},dT={exact:function aG(n,t){return Pr(n,t)},subset:function lG(n,t){return Object.keys(t).length<=Object.keys(n).length&&Object.keys(t).every(e=>aT(n[e],t[e]))},ignored:()=>!0};function uT(n,t,e){return oG[e.paths](n.root,t.root,e.matrixParams)&&dT[e.queryParams](n.queryParams,t.queryParams)&&!("exact"===e.fragment&&n.fragment!==t.fragment)}function fT(n,t,e){return pT(n,t,t.segments,e)}function pT(n,t,e,i){if(n.segments.length>e.length){const r=n.segments.slice(0,e.length);return!(!Mo(r,e)||t.hasChildren()||!Nh(r,e,i))}if(n.segments.length===e.length){if(!Mo(n.segments,e)||!Nh(n.segments,e,i))return!1;for(const r in t.children)if(!n.children[r]||!fT(n.children[r],t.children[r],i))return!1;return!0}{const r=e.slice(0,n.segments.length),s=e.slice(n.segments.length);return!!(Mo(n.segments,r)&&Nh(n.segments,r,i)&&n.children[Et])&&pT(n.children[Et],t,s,i)}}function Nh(n,t,e){return t.every((i,r)=>dT[e](n[r].parameters,i.parameters))}class Eo{constructor(t,e,i){this.root=t,this.queryParams=e,this.fragment=i}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Ua(this.queryParams)),this._queryParamMap}toString(){return uG.serialize(this)}}class Pt{constructor(t,e){this.segments=t,this.children=e,this.parent=null,Un(e,(i,r)=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Bh(this)}}class Mc{constructor(t,e){this.path=t,this.parameters=e}get parameterMap(){return this._parameterMap||(this._parameterMap=Ua(this.parameters)),this._parameterMap}toString(){return yT(this)}}function Mo(n,t){return n.length===t.length&&n.every((e,i)=>e.path===t[i].path)}class mT{}class gT{parse(t){const e=new bG(t);return new Eo(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(t){const e=`/${xc(t.root,!0)}`,i=function pG(n){const t=Object.keys(n).map(e=>{const i=n[e];return Array.isArray(i)?i.map(r=>`${Vh(e)}=${Vh(r)}`).join("&"):`${Vh(e)}=${Vh(i)}`}).filter(e=>!!e);return t.length?`?${t.join("&")}`:""}(t.queryParams);return`${e}${i}${"string"==typeof t.fragment?`#${function hG(n){return encodeURI(n)}(t.fragment)}`:""}`}}const uG=new gT;function Bh(n){return n.segments.map(t=>yT(t)).join("/")}function xc(n,t){if(!n.hasChildren())return Bh(n);if(t){const e=n.children[Et]?xc(n.children[Et],!1):"",i=[];return Un(n.children,(r,s)=>{s!==Et&&i.push(`${s}:${xc(r,!1)}`)}),i.length>0?`${e}(${i.join("//")})`:e}{const e=function dG(n,t){let e=[];return Un(n.children,(i,r)=>{r===Et&&(e=e.concat(t(i,r)))}),Un(n.children,(i,r)=>{r!==Et&&(e=e.concat(t(i,r)))}),e}(n,(i,r)=>r===Et?[xc(n.children[Et],!1)]:[`${r}:${xc(i,!1)}`]);return 1===Object.keys(n.children).length&&null!=n.children[Et]?`${Bh(n)}/${e[0]}`:`${Bh(n)}/(${e.join("//")})`}}function _T(n){return encodeURIComponent(n).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function Vh(n){return _T(n).replace(/%3B/gi,";")}function Ev(n){return _T(n).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Hh(n){return decodeURIComponent(n)}function vT(n){return Hh(n.replace(/\+/g,"%20"))}function yT(n){return`${Ev(n.path)}${function fG(n){return Object.keys(n).map(t=>`;${Ev(t)}=${Ev(n[t])}`).join("")}(n.parameters)}`}const mG=/^[^\/()?;=#]+/;function jh(n){const t=n.match(mG);return t?t[0]:""}const gG=/^[^=?&#]+/,vG=/^[^&#]+/;class bG{constructor(t){this.url=t,this.remaining=t}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new Pt([],{}):new Pt([],this.parseChildren())}parseQueryParams(){const t={};if(this.consumeOptional("?"))do{this.parseQueryParam(t)}while(this.consumeOptional("&"));return t}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const t=[];for(this.peekStartsWith("(")||t.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),t.push(this.parseSegment());let e={};this.peekStartsWith("/(")&&(this.capture("/"),e=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(t.length>0||Object.keys(e).length>0)&&(i[Et]=new Pt(t,e)),i}parseSegment(){const t=jh(this.remaining);if(""===t&&this.peekStartsWith(";"))throw new Error(`Empty path url segment cannot have parameters: '${this.remaining}'.`);return this.capture(t),new Mc(Hh(t),this.parseMatrixParams())}parseMatrixParams(){const t={};for(;this.consumeOptional(";");)this.parseParam(t);return t}parseParam(t){const e=jh(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){const r=jh(this.remaining);r&&(i=r,this.capture(i))}t[Hh(e)]=Hh(i)}parseQueryParam(t){const e=function _G(n){const t=n.match(gG);return t?t[0]:""}(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){const o=function yG(n){const t=n.match(vG);return t?t[0]:""}(this.remaining);o&&(i=o,this.capture(i))}const r=vT(e),s=vT(i);if(t.hasOwnProperty(r)){let o=t[r];Array.isArray(o)||(o=[o],t[r]=o),o.push(s)}else t[r]=s}parseParens(t){const e={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const i=jh(this.remaining),r=this.remaining[i.length];if("/"!==r&&")"!==r&&";"!==r)throw new Error(`Cannot parse url '${this.url}'`);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):t&&(s=Et);const o=this.parseChildren();e[s]=1===Object.keys(o).length?o[Et]:new Pt([],o),this.consumeOptional("//")}return e}peekStartsWith(t){return this.remaining.startsWith(t)}consumeOptional(t){return!!this.peekStartsWith(t)&&(this.remaining=this.remaining.substring(t.length),!0)}capture(t){if(!this.consumeOptional(t))throw new Error(`Expected "${t}".`)}}class bT{constructor(t){this._root=t}get root(){return this._root.value}parent(t){const e=this.pathFromRoot(t);return e.length>1?e[e.length-2]:null}children(t){const e=Mv(t,this._root);return e?e.children.map(i=>i.value):[]}firstChild(t){const e=Mv(t,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(t){const e=xv(t,this._root);return e.length<2?[]:e[e.length-2].children.map(r=>r.value).filter(r=>r!==t)}pathFromRoot(t){return xv(t,this._root).map(e=>e.value)}}function Mv(n,t){if(n===t.value)return t;for(const e of t.children){const i=Mv(n,e);if(i)return i}return null}function xv(n,t){if(n===t.value)return[t];for(const e of t.children){const i=xv(n,e);if(i.length)return i.unshift(t),i}return[]}class ds{constructor(t,e){this.value=t,this.children=e}toString(){return`TreeNode(${this.value})`}}function za(n){const t={};return n&&n.children.forEach(e=>t[e.value.outlet]=e),t}class wT extends bT{constructor(t,e){super(t),this.snapshot=e,Sv(this,t)}toString(){return this.snapshot.toString()}}function CT(n,t){const e=function wG(n,t){const o=new Uh([],{},{},"",{},Et,t,null,n.root,-1,{});return new ET("",new ds(o,[]))}(n,t),i=new mi([new Mc("",{})]),r=new mi({}),s=new mi({}),o=new mi({}),a=new mi(""),l=new $a(i,r,o,a,s,Et,t,e.root);return l.snapshot=e.root,new wT(new ds(l,[]),e)}class $a{constructor(t,e,i,r,s,o,a,l){this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this._futureSnapshot=l}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=this.params.pipe(U(t=>Ua(t)))),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(U(t=>Ua(t)))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function DT(n,t="emptyOnly"){const e=n.pathFromRoot;let i=0;if("always"!==t)for(i=e.length-1;i>=1;){const r=e[i],s=e[i-1];if(r.routeConfig&&""===r.routeConfig.path)i--;else{if(s.component)break;i--}}return function CG(n){return n.reduce((t,e)=>{var i;return{params:Object.assign(Object.assign({},t.params),e.params),data:Object.assign(Object.assign({},t.data),e.data),resolve:Object.assign(Object.assign(Object.assign(Object.assign({},e.data),t.resolve),null===(i=e.routeConfig)||void 0===i?void 0:i.data),e._resolvedData)}},{params:{},data:{},resolve:{}})}(e.slice(i))}class Uh{constructor(t,e,i,r,s,o,a,l,c,d,f,w){this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=l,this._urlSegment=c,this._lastPathIndex=d,this._correctedLastPathIndex=null!=w?w:d,this._resolve=f}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=Ua(this.params)),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Ua(this.queryParams)),this._queryParamMap}toString(){return`Route(url:'${this.url.map(i=>i.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class ET extends bT{constructor(t,e){super(e),this.url=t,Sv(this,e)}toString(){return MT(this._root)}}function Sv(n,t){t.value._routerState=n,t.children.forEach(e=>Sv(n,e))}function MT(n){const t=n.children.length>0?` { ${n.children.map(MT).join(", ")} } `:"";return`${n.value}${t}`}function kv(n){if(n.snapshot){const t=n.snapshot,e=n._futureSnapshot;n.snapshot=e,Pr(t.queryParams,e.queryParams)||n.queryParams.next(e.queryParams),t.fragment!==e.fragment&&n.fragment.next(e.fragment),Pr(t.params,e.params)||n.params.next(e.params),function rG(n,t){if(n.length!==t.length)return!1;for(let e=0;ePr(e.parameters,t[i].parameters))}(n.url,t.url);return e&&!(!n.parent!=!t.parent)&&(!n.parent||Tv(n.parent,t.parent))}function Sc(n,t,e){if(e&&n.shouldReuseRoute(t.value,e.value.snapshot)){const i=e.value;i._futureSnapshot=t.value;const r=function EG(n,t,e){return t.children.map(i=>{for(const r of e.children)if(n.shouldReuseRoute(i.value,r.value.snapshot))return Sc(n,i,r);return Sc(n,i)})}(n,t,e);return new ds(i,r)}{if(n.shouldAttach(t.value)){const s=n.retrieve(t.value);if(null!==s){const o=s.route;return o.value._futureSnapshot=t.value,o.children=t.children.map(a=>Sc(n,a)),o}}const i=function MG(n){return new $a(new mi(n.url),new mi(n.params),new mi(n.queryParams),new mi(n.fragment),new mi(n.data),n.outlet,n.component,n)}(t.value),r=t.children.map(s=>Sc(n,s));return new ds(i,r)}}function zh(n){return"object"==typeof n&&null!=n&&!n.outlets&&!n.segmentPath}function kc(n){return"object"==typeof n&&null!=n&&n.outlets}function Av(n,t,e,i,r){let s={};if(i&&Un(i,(a,l)=>{s[l]=Array.isArray(a)?a.map(c=>`${c}`):`${a}`}),n===t)return new Eo(e,s,r);const o=xT(n,t,e);return new Eo(o,s,r)}function xT(n,t,e){const i={};return Un(n.children,(r,s)=>{i[s]=r===t?e:xT(r,t,e)}),new Pt(n.segments,i)}class ST{constructor(t,e,i){if(this.isAbsolute=t,this.numberOfDoubleDots=e,this.commands=i,t&&i.length>0&&zh(i[0]))throw new Error("Root segment cannot have matrix parameters");const r=i.find(kc);if(r&&r!==cT(i))throw new Error("{outlets:{}} has to be the last command")}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class Iv{constructor(t,e,i){this.segmentGroup=t,this.processChildren=e,this.index=i}}function kT(n,t,e){if(n||(n=new Pt([],{})),0===n.segments.length&&n.hasChildren())return $h(n,t,e);const i=function IG(n,t,e){let i=0,r=t;const s={match:!1,pathIndex:0,commandIndex:0};for(;r=e.length)return s;const o=n.segments[r],a=e[i];if(kc(a))break;const l=`${a}`,c=i0&&void 0===l)break;if(l&&c&&"object"==typeof c&&void 0===c.outlets){if(!AT(l,c,o))return s;i+=2}else{if(!AT(l,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}(n,t,e),r=e.slice(i.commandIndex);if(i.match&&i.pathIndex{"string"==typeof s&&(s=[s]),null!==s&&(r[o]=kT(n.children[o],t,s))}),Un(n.children,(s,o)=>{void 0===i[o]&&(r[o]=s)}),new Pt(n.segments,r)}}function Rv(n,t,e){const i=n.segments.slice(0,t);let r=0;for(;r{"string"==typeof e&&(e=[e]),null!==e&&(t[i]=Rv(new Pt([],{}),0,e))}),t}function TT(n){const t={};return Un(n,(e,i)=>t[i]=`${e}`),t}function AT(n,t,e){return n==e.path&&Pr(t,e.parameters)}class PG{constructor(){this.outlet=null,this.route=null,this.resolver=null,this.injector=null,this.children=new Tc,this.attachRef=null}}class Tc{constructor(){this.contexts=new Map}onChildOutletCreated(t,e){const i=this.getOrCreateContext(t);i.outlet=e,this.contexts.set(t,i)}onChildOutletDestroyed(t){const e=this.getContext(t);e&&(e.outlet=null,e.attachRef=null)}onOutletDeactivated(){const t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let e=this.getContext(t);return e||(e=new PG,this.contexts.set(t,e)),e}getContext(t){return this.contexts.get(t)||null}}let Pv=(()=>{class n{constructor(e,i,r,s,o){this.parentContexts=e,this.location=i,this.changeDetector=s,this.environmentInjector=o,this.activated=null,this._activatedRoute=null,this.activateEvents=new je,this.deactivateEvents=new je,this.attachEvents=new je,this.detachEvents=new je,this.name=r||Et,e.onChildOutletCreated(this.name,this)}ngOnDestroy(){this.parentContexts.onChildOutletDestroyed(this.name)}ngOnInit(){if(!this.activated){const e=this.parentContexts.getContext(this.name);e&&e.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new Error("Outlet is not activated");return this.activated.instance}get activatedRoute(){if(!this.activated)throw new Error("Outlet is not activated");return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new Error("Outlet is not activated");this.location.detach();const e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,i){this.activated=e,this._activatedRoute=i,this.location.insert(e.hostView),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){const e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,i){if(this.isActivated)throw new Error("Cannot activate an already activated outlet");this._activatedRoute=e;const r=this.location,o=e._futureSnapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,l=new OG(e,a,r.injector);if(i&&function FG(n){return!!n.resolveComponentFactory}(i)){const c=i.resolveComponentFactory(o);this.activated=r.createComponent(c,r.length,l)}else this.activated=r.createComponent(o,{index:r.length,injector:l,environmentInjector:null!=i?i:this.environmentInjector});this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}}return n.\u0275fac=function(e){return new(e||n)(x(Tc),x(An),ii("name"),x(en),x(Qs))},n.\u0275dir=Me({type:n,selectors:[["router-outlet"]],outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"]}),n})();class OG{constructor(t,e,i){this.route=t,this.childContexts=e,this.parent=i}get(t,e){return t===$a?this.route:t===Tc?this.childContexts:this.parent.get(t,e)}}let IT=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275cmp=vt({type:n,selectors:[["ng-component"]],decls:1,vars:0,template:function(e,i){1&e&&kt(0,"router-outlet")},dependencies:[Pv],encapsulation:2}),n})();function RT(n,t){var e;return n.providers&&!n._injector&&(n._injector=Nd(n.providers,t,`Route: ${n.path}`)),null!==(e=n._injector)&&void 0!==e?e:t}function Fv(n){const t=n.children&&n.children.map(Fv),e=t?Object.assign(Object.assign({},n),{children:t}):Object.assign({},n);return!e.component&&!e.loadComponent&&(t||e.loadChildren)&&e.outlet&&e.outlet!==Et&&(e.component=IT),e}function Qi(n){return n.outlet||Et}function PT(n,t){const e=n.filter(i=>Qi(i)===t);return e.push(...n.filter(i=>Qi(i)!==t)),e}function OT(n){var t;if(!n)return null;if(null!==(t=n.routeConfig)&&void 0!==t&&t._injector)return n.routeConfig._injector;for(let e=n.parent;e;e=e.parent){const i=e.routeConfig;if(null!=i&&i._loadedInjector)return i._loadedInjector;if(null!=i&&i._injector)return i._injector}return null}class HG{constructor(t,e,i,r){this.routeReuseStrategy=t,this.futureState=e,this.currState=i,this.forwardEvent=r}activate(t){const e=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,i,t),kv(this.futureState.root),this.activateChildRoutes(e,i,t)}deactivateChildRoutes(t,e,i){const r=za(e);t.children.forEach(s=>{const o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),Un(r,(s,o)=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(t,e,i){const r=t.value,s=e?e.value:null;if(r===s)if(r.component){const o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(t,e,o.children)}else this.deactivateChildRoutes(t,e,i);else s&&this.deactivateRouteAndItsChildren(e,i)}deactivateRouteAndItsChildren(t,e){t.value.component&&this.routeReuseStrategy.shouldDetach(t.value.snapshot)?this.detachAndStoreRouteSubtree(t,e):this.deactivateRouteAndOutlet(t,e)}detachAndStoreRouteSubtree(t,e){const i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=za(t);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);if(i&&i.outlet){const o=i.outlet.detach(),a=i.children.onOutletDeactivated();this.routeReuseStrategy.store(t.value.snapshot,{componentRef:o,route:t,contexts:a})}}deactivateRouteAndOutlet(t,e){const i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=za(t);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);i&&i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated(),i.attachRef=null,i.resolver=null,i.route=null)}activateChildRoutes(t,e,i){const r=za(e);t.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new eG(s.value.snapshot))}),t.children.length&&this.forwardEvent(new X6(t.value.snapshot))}activateRoutes(t,e,i){var r;const s=t.value,o=e?e.value:null;if(kv(s),s===o)if(s.component){const a=i.getOrCreateContext(s.outlet);this.activateChildRoutes(t,e,a.children)}else this.activateChildRoutes(t,e,i);else if(s.component){const a=i.getOrCreateContext(s.outlet);if(this.routeReuseStrategy.shouldAttach(s.snapshot)){const l=this.routeReuseStrategy.retrieve(s.snapshot);this.routeReuseStrategy.store(s.snapshot,null),a.children.onOutletReAttached(l.contexts),a.attachRef=l.componentRef,a.route=l.route.value,a.outlet&&a.outlet.attach(l.componentRef,l.route.value),kv(l.route.value),this.activateChildRoutes(t,null,a.children)}else{const l=OT(s.snapshot),c=null!==(r=null==l?void 0:l.get(io))&&void 0!==r?r:null;a.attachRef=null,a.route=s,a.resolver=c,a.injector=l,a.outlet&&a.outlet.activateWith(s,a.injector),this.activateChildRoutes(t,null,a.children)}}else this.activateChildRoutes(t,null,i)}}function Ns(n){return"function"==typeof n}function xo(n){return n instanceof Eo}const Ac=Symbol("INITIAL_VALUE");function Ic(){return Rr(n=>gv(n.map(t=>t.pipe(sn(1),Qn(Ac)))).pipe(nT((t,e)=>{let i=!1;return e.reduce((r,s,o)=>r!==Ac?r:(s===Ac&&(i=!0),i||!1!==s&&o!==e.length-1&&!xo(s)?r:s),t)},Ac),yn(t=>t!==Ac),U(t=>xo(t)?t:!0===t),sn(1)))}const FT={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function Gh(n,t,e){var i;if(""===t.path)return"full"===t.pathMatch&&(n.hasChildren()||e.length>0)?Object.assign({},FT):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};const s=(t.matcher||iG)(e,n,t);if(!s)return Object.assign({},FT);const o={};Un(s.posParams,(l,c)=>{o[c]=l.path});const a=s.consumed.length>0?Object.assign(Object.assign({},o),s.consumed[s.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:s.consumed,remainingSegments:e.slice(s.consumed.length),parameters:a,positionalParamSegments:null!==(i=s.posParams)&&void 0!==i?i:{}}}function Wh(n,t,e,i,r="corrected"){if(e.length>0&&function YG(n,t,e){return e.some(i=>qh(n,t,i)&&Qi(i)!==Et)}(n,e,i)){const o=new Pt(t,function qG(n,t,e,i){const r={};r[Et]=i,i._sourceSegment=n,i._segmentIndexShift=t.length;for(const s of e)if(""===s.path&&Qi(s)!==Et){const o=new Pt([],{});o._sourceSegment=n,o._segmentIndexShift=t.length,r[Qi(s)]=o}return r}(n,t,i,new Pt(e,n.children)));return o._sourceSegment=n,o._segmentIndexShift=t.length,{segmentGroup:o,slicedSegments:[]}}if(0===e.length&&function KG(n,t,e){return e.some(i=>qh(n,t,i))}(n,e,i)){const o=new Pt(n.segments,function WG(n,t,e,i,r,s){const o={};for(const a of i)if(qh(n,e,a)&&!r[Qi(a)]){const l=new Pt([],{});l._sourceSegment=n,l._segmentIndexShift="legacy"===s?n.segments.length:t.length,o[Qi(a)]=l}return Object.assign(Object.assign({},r),o)}(n,t,e,i,n.children,r));return o._sourceSegment=n,o._segmentIndexShift=t.length,{segmentGroup:o,slicedSegments:e}}const s=new Pt(n.segments,n.children);return s._sourceSegment=n,s._segmentIndexShift=t.length,{segmentGroup:s,slicedSegments:e}}function qh(n,t,e){return(!(n.hasChildren()||t.length>0)||"full"!==e.pathMatch)&&""===e.path}function LT(n,t,e,i){return!!(Qi(n)===i||i!==Et&&qh(t,e,n))&&("**"===n.path||Gh(t,n,e).matched)}function NT(n,t,e){return 0===t.length&&!n.children[e]}class Yh{constructor(t){this.segmentGroup=t||null}}class BT{constructor(t){this.urlTree=t}}function Rc(n){return La(new Yh(n))}function VT(n){return La(new BT(n))}class JG{constructor(t,e,i,r,s){this.injector=t,this.configLoader=e,this.urlSerializer=i,this.urlTree=r,this.config=s,this.allowRedirects=!0}apply(){const t=Wh(this.urlTree.root,[],[],this.config).segmentGroup,e=new Pt(t.segments,t.children);return this.expandSegmentGroup(this.injector,this.config,e,Et).pipe(U(s=>this.createUrlTree(Lv(s),this.urlTree.queryParams,this.urlTree.fragment))).pipe(os(s=>{if(s instanceof BT)return this.allowRedirects=!1,this.match(s.urlTree);throw s instanceof Yh?this.noMatchError(s):s}))}match(t){return this.expandSegmentGroup(this.injector,this.config,t.root,Et).pipe(U(r=>this.createUrlTree(Lv(r),t.queryParams,t.fragment))).pipe(os(r=>{throw r instanceof Yh?this.noMatchError(r):r}))}noMatchError(t){return new Error(`Cannot match any routes. URL Segment: '${t.segmentGroup}'`)}createUrlTree(t,e,i){const r=t.segments.length>0?new Pt([],{[Et]:t}):t;return new Eo(r,e,i)}expandSegmentGroup(t,e,i,r){return 0===i.segments.length&&i.hasChildren()?this.expandChildren(t,e,i).pipe(U(s=>new Pt([],s))):this.expandSegment(t,i,e,i.segments,r,!0)}expandChildren(t,e,i){const r=[];for(const s of Object.keys(i.children))"primary"===s?r.unshift(s):r.push(s);return gn(r).pipe(Da(s=>{const o=i.children[s],a=PT(e,s);return this.expandSegmentGroup(t,a,o,s).pipe(U(l=>({segment:l,outlet:s})))}),nT((s,o)=>(s[o.outlet]=o.segment,s),{}),function j6(n,t){const e=arguments.length>=2;return i=>i.pipe(n?yn((r,s)=>n(r,s,i)):N,bv(1),e?wv(t):iT(()=>new Dc))}())}expandSegment(t,e,i,r,s,o){return gn(i).pipe(Da(a=>this.expandSegmentAgainstRoute(t,e,i,a,r,s,o).pipe(os(c=>{if(c instanceof Yh)return tt(null);throw c}))),Do(a=>!!a),os((a,l)=>{if(a instanceof Dc||"EmptyError"===a.name)return NT(e,r,s)?tt(new Pt([],{})):Rc(e);throw a}))}expandSegmentAgainstRoute(t,e,i,r,s,o,a){return LT(r,e,s,o)?void 0===r.redirectTo?this.matchSegmentAgainstRoute(t,e,r,s,o):a&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o):Rc(e):Rc(e)}expandSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o){return"**"===r.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(t,i,r,o):this.expandRegularSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o)}expandWildCardWithParamsAgainstRouteUsingRedirect(t,e,i,r){const s=this.applyRedirectCommands([],i.redirectTo,{});return i.redirectTo.startsWith("/")?VT(s):this.lineralizeSegments(i,s).pipe(Pn(o=>{const a=new Pt(o,{});return this.expandSegment(t,a,e,o,r,!1)}))}expandRegularSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o){const{matched:a,consumedSegments:l,remainingSegments:c,positionalParamSegments:d}=Gh(e,r,s);if(!a)return Rc(e);const f=this.applyRedirectCommands(l,r.redirectTo,d);return r.redirectTo.startsWith("/")?VT(f):this.lineralizeSegments(r,f).pipe(Pn(w=>this.expandSegment(t,e,i,w.concat(c),o,!1)))}matchSegmentAgainstRoute(t,e,i,r,s){if("**"===i.path)return t=RT(i,t),i.loadChildren?(i._loadedRoutes?tt({routes:i._loadedRoutes,injector:i._loadedInjector}):this.configLoader.loadChildren(t,i)).pipe(U(f=>(i._loadedRoutes=f.routes,i._loadedInjector=f.injector,new Pt(r,{})))):tt(new Pt(r,{}));const{matched:o,consumedSegments:a,remainingSegments:l}=Gh(e,i,r);return o?(t=RT(i,t),this.getChildConfig(t,i,r).pipe(Pn(d=>{var f;const w=null!==(f=d.injector)&&void 0!==f?f:t,k=d.routes,{segmentGroup:j,slicedSegments:K}=Wh(e,a,l,k),ae=new Pt(j.segments,j.children);if(0===K.length&&ae.hasChildren())return this.expandChildren(w,k,ae).pipe(U(Oe=>new Pt(a,Oe)));if(0===k.length&&0===K.length)return tt(new Pt(a,{}));const ce=Qi(i)===s;return this.expandSegment(w,ae,k,K,ce?Et:s,!0).pipe(U(he=>new Pt(a.concat(he.segments),he.children)))}))):Rc(e)}getChildConfig(t,e,i){return e.children?tt({routes:e.children,injector:t}):e.loadChildren?void 0!==e._loadedRoutes?tt({routes:e._loadedRoutes,injector:e._loadedInjector}):this.runCanLoadGuards(t,e,i).pipe(Pn(r=>r?this.configLoader.loadChildren(t,e).pipe(wn(s=>{e._loadedRoutes=s.routes,e._loadedInjector=s.injector})):function ZG(n){return La(Dv(`Cannot load children because the guard of the route "path: '${n.path}'" returned false`))}(e))):tt({routes:[],injector:t})}runCanLoadGuards(t,e,i){const r=e.canLoad;return r&&0!==r.length?tt(r.map(o=>{const a=t.get(o);let l;if(function UG(n){return n&&Ns(n.canLoad)}(a))l=a.canLoad(e,i);else{if(!Ns(a))throw new Error("Invalid CanLoad guard");l=a(e,i)}return fr(l)})).pipe(Ic(),wn(o=>{if(!xo(o))return;const a=Dv(`Redirecting to "${this.urlSerializer.serialize(o)}"`);throw a.url=o,a}),U(o=>!0===o)):tt(!0)}lineralizeSegments(t,e){let i=[],r=e.root;for(;;){if(i=i.concat(r.segments),0===r.numberOfChildren)return tt(i);if(r.numberOfChildren>1||!r.children[Et])return La(new Error(`Only absolute redirects can have named outlets. redirectTo: '${t.redirectTo}'`));r=r.children[Et]}}applyRedirectCommands(t,e,i){return this.applyRedirectCreatreUrlTree(e,this.urlSerializer.parse(e),t,i)}applyRedirectCreatreUrlTree(t,e,i,r){const s=this.createSegmentGroup(t,e.root,i,r);return new Eo(s,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(t,e){const i={};return Un(t,(r,s)=>{if("string"==typeof r&&r.startsWith(":")){const a=r.substring(1);i[s]=e[a]}else i[s]=r}),i}createSegmentGroup(t,e,i,r){const s=this.createSegments(t,e.segments,i,r);let o={};return Un(e.children,(a,l)=>{o[l]=this.createSegmentGroup(t,a,i,r)}),new Pt(s,o)}createSegments(t,e,i,r){return e.map(s=>s.path.startsWith(":")?this.findPosParam(t,s,r):this.findOrReturn(s,i))}findPosParam(t,e,i){const r=i[e.path.substring(1)];if(!r)throw new Error(`Cannot redirect to '${t}'. Cannot find '${e.path}'.`);return r}findOrReturn(t,e){let i=0;for(const r of e){if(r.path===t.path)return e.splice(i),r;i++}return t}}function Lv(n){const t={};for(const i of Object.keys(n.children)){const s=Lv(n.children[i]);(s.segments.length>0||s.hasChildren())&&(t[i]=s)}return function eW(n){if(1===n.numberOfChildren&&n.children[Et]){const t=n.children[Et];return new Pt(n.segments.concat(t.segments),t.children)}return n}(new Pt(n.segments,t))}class HT{constructor(t){this.path=t,this.route=this.path[this.path.length-1]}}class Kh{constructor(t,e){this.component=t,this.route=e}}function nW(n,t,e){const i=n._root;return Pc(i,t?t._root:null,e,[i.value])}function Qh(n,t,e){const i=OT(t);return(null!=i?i:e).get(n)}function Pc(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=za(t);return n.children.forEach(o=>{(function rW(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=n.value,o=t?t.value:null,a=e?e.getContext(n.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){const l=function sW(n,t,e){if("function"==typeof e)return e(n,t);switch(e){case"pathParamsChange":return!Mo(n.url,t.url);case"pathParamsOrQueryParamsChange":return!Mo(n.url,t.url)||!Pr(n.queryParams,t.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Tv(n,t)||!Pr(n.queryParams,t.queryParams);default:return!Tv(n,t)}}(o,s,s.routeConfig.runGuardsAndResolvers);l?r.canActivateChecks.push(new HT(i)):(s.data=o.data,s._resolvedData=o._resolvedData),Pc(n,t,s.component?a?a.children:null:e,i,r),l&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new Kh(a.outlet.component,o))}else o&&Oc(t,a,r),r.canActivateChecks.push(new HT(i)),Pc(n,null,s.component?a?a.children:null:e,i,r)})(o,s[o.value.outlet],e,i.concat([o.value]),r),delete s[o.value.outlet]}),Un(s,(o,a)=>Oc(o,e.getContext(a),r)),r}function Oc(n,t,e){const i=za(n),r=n.value;Un(i,(s,o)=>{Oc(s,r.component?t?t.children.getContext(o):null:t,e)}),e.canDeactivateChecks.push(new Kh(r.component&&t&&t.outlet&&t.outlet.isActivated?t.outlet.component:null,r))}class pW{}function UT(n){return new J(t=>t.error(n))}class gW{constructor(t,e,i,r,s,o){this.rootComponentType=t,this.config=e,this.urlTree=i,this.url=r,this.paramsInheritanceStrategy=s,this.relativeLinkResolution=o}recognize(){const t=Wh(this.urlTree.root,[],[],this.config.filter(o=>void 0===o.redirectTo),this.relativeLinkResolution).segmentGroup,e=this.processSegmentGroup(this.config,t,Et);if(null===e)return null;const i=new Uh([],Object.freeze({}),Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,{},Et,this.rootComponentType,null,this.urlTree.root,-1,{}),r=new ds(i,e),s=new ET(this.url,r);return this.inheritParamsAndData(s._root),s}inheritParamsAndData(t){const e=t.value,i=DT(e,this.paramsInheritanceStrategy);e.params=Object.freeze(i.params),e.data=Object.freeze(i.data),t.children.forEach(r=>this.inheritParamsAndData(r))}processSegmentGroup(t,e,i){return 0===e.segments.length&&e.hasChildren()?this.processChildren(t,e):this.processSegment(t,e,e.segments,i)}processChildren(t,e){const i=[];for(const s of Object.keys(e.children)){const o=e.children[s],a=PT(t,s),l=this.processSegmentGroup(a,o,s);if(null===l)return null;i.push(...l)}const r=zT(i);return function _W(n){n.sort((t,e)=>t.value.outlet===Et?-1:e.value.outlet===Et?1:t.value.outlet.localeCompare(e.value.outlet))}(r),r}processSegment(t,e,i,r){for(const s of t){const o=this.processSegmentAgainstRoute(s,e,i,r);if(null!==o)return o}return NT(e,i,r)?[]:null}processSegmentAgainstRoute(t,e,i,r){var s,o,a,l;if(t.redirectTo||!LT(t,e,i,r))return null;let c,d=[],f=[];if("**"===t.path){const ce=i.length>0?cT(i).parameters:{},Te=GT(e)+i.length;c=new Uh(i,ce,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,qT(t),Qi(t),null!==(o=null!==(s=t.component)&&void 0!==s?s:t._loadedComponent)&&void 0!==o?o:null,t,$T(e),Te,YT(t),Te)}else{const ce=Gh(e,t,i);if(!ce.matched)return null;d=ce.consumedSegments,f=ce.remainingSegments;const Te=GT(e)+d.length;c=new Uh(d,ce.parameters,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,qT(t),Qi(t),null!==(l=null!==(a=t.component)&&void 0!==a?a:t._loadedComponent)&&void 0!==l?l:null,t,$T(e),Te,YT(t),Te)}const w=function vW(n){return n.children?n.children:n.loadChildren?n._loadedRoutes:[]}(t),{segmentGroup:k,slicedSegments:j}=Wh(e,d,f,w.filter(ce=>void 0===ce.redirectTo),this.relativeLinkResolution);if(0===j.length&&k.hasChildren()){const ce=this.processChildren(w,k);return null===ce?null:[new ds(c,ce)]}if(0===w.length&&0===j.length)return[new ds(c,[])];const K=Qi(t)===r,ae=this.processSegment(w,k,j,K?Et:r);return null===ae?null:[new ds(c,ae)]}}function yW(n){const t=n.value.routeConfig;return t&&""===t.path&&void 0===t.redirectTo}function zT(n){const t=[],e=new Set;for(const i of n){if(!yW(i)){t.push(i);continue}const r=t.find(s=>i.value.routeConfig===s.value.routeConfig);void 0!==r?(r.children.push(...i.children),e.add(r)):t.push(i)}for(const i of e){const r=zT(i.children);t.push(new ds(i.value,r))}return t.filter(i=>!e.has(i))}function $T(n){let t=n;for(;t._sourceSegment;)t=t._sourceSegment;return t}function GT(n){var t,e;let i=n,r=null!==(t=i._segmentIndexShift)&&void 0!==t?t:0;for(;i._sourceSegment;)i=i._sourceSegment,r+=null!==(e=i._segmentIndexShift)&&void 0!==e?e:0;return r-1}function qT(n){return n.data||{}}function YT(n){return n.resolve||{}}const Nv=Symbol("RouteTitle");function KT(n){return"string"==typeof n.title||null===n.title}function Zh(n){return Rr(t=>{const e=n(t);return e?gn(e).pipe(U(()=>t)):tt(t)})}class kW extends class SW{shouldDetach(t){return!1}store(t,e){}shouldAttach(t){return!1}retrieve(t){return null}shouldReuseRoute(t,e){return t.routeConfig===e.routeConfig}}{}const Bv=new De("ROUTES");let Vv=(()=>{class n{constructor(e,i){this.injector=e,this.compiler=i,this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap}loadComponent(e){if(this.componentLoaders.get(e))return this.componentLoaders.get(e);if(e._loadedComponent)return tt(e._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(e);const i=fr(e.loadComponent()).pipe(wn(s=>{this.onLoadEndListener&&this.onLoadEndListener(e),e._loadedComponent=s}),bh(()=>{this.componentLoaders.delete(e)})),r=new yv(i,()=>new ue).pipe(Lh());return this.componentLoaders.set(e,r),r}loadChildren(e,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return tt({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);const s=this.loadModuleFactoryOrRoutes(i.loadChildren).pipe(U(a=>{this.onLoadEndListener&&this.onLoadEndListener(i);let l,c,d=!1;Array.isArray(a)?c=a:(l=a.create(e).injector,c=lT(l.get(Bv,[],at.Self|at.Optional)));return{routes:c.map(Fv),injector:l}}),bh(()=>{this.childrenLoaders.delete(i)})),o=new yv(s,()=>new ue).pipe(Lh());return this.childrenLoaders.set(i,o),o}loadModuleFactoryOrRoutes(e){return fr(e()).pipe(Pn(i=>i instanceof NC||Array.isArray(i)?tt(i):gn(this.compiler.compileModuleAsync(i))))}}return n.\u0275fac=function(e){return new(e||n)(te(Jt),te(Rm))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class AW{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,e){return t}}function RW(n){throw n}function PW(n,t,e){return t.parse("/")}function ZT(n,t){return tt(null)}const OW={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},FW={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let Ri=(()=>{class n{constructor(e,i,r,s,o,a,l){this.rootComponentType=e,this.urlSerializer=i,this.rootContexts=r,this.location=s,this.config=l,this.lastSuccessfulNavigation=null,this.currentNavigation=null,this.disposed=!1,this.navigationId=0,this.currentPageId=0,this.isNgZoneEnabled=!1,this.events=new ue,this.errorHandler=RW,this.malformedUriErrorHandler=PW,this.navigated=!1,this.lastSuccessfulId=-1,this.hooks={beforePreactivation:ZT,afterPreactivation:ZT},this.urlHandlingStrategy=new AW,this.routeReuseStrategy=new kW,this.onSameUrlNavigation="ignore",this.paramsInheritanceStrategy="emptyOnly",this.urlUpdateStrategy="deferred",this.relativeLinkResolution="corrected",this.canceledNavigationResolution="replace",this.configLoader=o.get(Vv),this.configLoader.onLoadEndListener=w=>this.triggerEvent(new Q6(w)),this.configLoader.onLoadStartListener=w=>this.triggerEvent(new K6(w)),this.ngModule=o.get(Ds),this.console=o.get(DN);const f=o.get(et);this.isNgZoneEnabled=f instanceof et&&et.isInAngularZone(),this.resetConfig(l),this.currentUrlTree=function sG(){return new Eo(new Pt([],{}),{},null)}(),this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.routerState=CT(this.currentUrlTree,this.rootComponentType),this.transitions=new mi({id:0,targetPageId:0,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,extractedUrl:this.urlHandlingStrategy.extract(this.currentUrlTree),urlAfterRedirects:this.urlHandlingStrategy.extract(this.currentUrlTree),rawUrl:this.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:"imperative",restoredState:null,currentSnapshot:this.routerState.snapshot,targetSnapshot:null,currentRouterState:this.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.navigations=this.setupNavigations(this.transitions),this.processNavigations()}get browserPageId(){var e;return null===(e=this.location.getState())||void 0===e?void 0:e.\u0275routerPageId}setupNavigations(e){const i=this.events;return e.pipe(yn(r=>0!==r.id),U(r=>Object.assign(Object.assign({},r),{extractedUrl:this.urlHandlingStrategy.extract(r.rawUrl)})),Rr(r=>{let s=!1,o=!1;return tt(r).pipe(wn(a=>{this.currentNavigation={id:a.id,initialUrl:a.rawUrl,extractedUrl:a.extractedUrl,trigger:a.source,extras:a.extras,previousNavigation:this.lastSuccessfulNavigation?Object.assign(Object.assign({},this.lastSuccessfulNavigation),{previousNavigation:null}):null}}),Rr(a=>{const l=this.browserUrlTree.toString(),c=!this.navigated||a.extractedUrl.toString()!==l||l!==this.currentUrlTree.toString();if(("reload"===this.onSameUrlNavigation||c)&&this.urlHandlingStrategy.shouldProcessUrl(a.rawUrl))return XT(a.source)&&(this.browserUrlTree=a.extractedUrl),tt(a).pipe(Rr(f=>{const w=this.transitions.getValue();return i.next(new Cv(f.id,this.serializeUrl(f.extractedUrl),f.source,f.restoredState)),w!==this.transitions.getValue()?Fi:Promise.resolve(f)}),function tW(n,t,e,i){return Rr(r=>function XG(n,t,e,i,r){return new JG(n,t,e,i,r).apply()}(n,t,e,r.extractedUrl,i).pipe(U(s=>Object.assign(Object.assign({},r),{urlAfterRedirects:s}))))}(this.ngModule.injector,this.configLoader,this.urlSerializer,this.config),wn(f=>{this.currentNavigation=Object.assign(Object.assign({},this.currentNavigation),{finalUrl:f.urlAfterRedirects})}),function bW(n,t,e,i,r){return Pn(s=>function mW(n,t,e,i,r="emptyOnly",s="legacy"){try{const o=new gW(n,t,e,i,r,s).recognize();return null===o?UT(new pW):tt(o)}catch(o){return UT(o)}}(n,t,s.urlAfterRedirects,e(s.urlAfterRedirects),i,r).pipe(U(o=>Object.assign(Object.assign({},s),{targetSnapshot:o}))))}(this.rootComponentType,this.config,f=>this.serializeUrl(f),this.paramsInheritanceStrategy,this.relativeLinkResolution),wn(f=>{if("eager"===this.urlUpdateStrategy){if(!f.extras.skipLocationChange){const k=this.urlHandlingStrategy.merge(f.urlAfterRedirects,f.rawUrl);this.setBrowserUrl(k,f)}this.browserUrlTree=f.urlAfterRedirects}const w=new $6(f.id,this.serializeUrl(f.extractedUrl),this.serializeUrl(f.urlAfterRedirects),f.targetSnapshot);i.next(w)}));if(c&&this.rawUrlTree&&this.urlHandlingStrategy.shouldProcessUrl(this.rawUrlTree)){const{id:w,extractedUrl:k,source:j,restoredState:K,extras:ae}=a,ce=new Cv(w,this.serializeUrl(k),j,K);i.next(ce);const Te=CT(k,this.rootComponentType).snapshot;return tt(Object.assign(Object.assign({},a),{targetSnapshot:Te,urlAfterRedirects:k,extras:Object.assign(Object.assign({},ae),{skipLocationChange:!1,replaceUrl:!1})}))}return this.rawUrlTree=a.rawUrl,a.resolve(null),Fi}),Zh(a=>{const{targetSnapshot:l,id:c,extractedUrl:d,rawUrl:f,extras:{skipLocationChange:w,replaceUrl:k}}=a;return this.hooks.beforePreactivation(l,{navigationId:c,appliedUrlTree:d,rawUrlTree:f,skipLocationChange:!!w,replaceUrl:!!k})}),wn(a=>{const l=new G6(a.id,this.serializeUrl(a.extractedUrl),this.serializeUrl(a.urlAfterRedirects),a.targetSnapshot);this.triggerEvent(l)}),U(a=>Object.assign(Object.assign({},a),{guards:nW(a.targetSnapshot,a.currentSnapshot,this.rootContexts)})),function oW(n,t){return Pn(e=>{const{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=e;return 0===o.length&&0===s.length?tt(Object.assign(Object.assign({},e),{guardsResult:!0})):function aW(n,t,e,i){return gn(n).pipe(Pn(r=>function fW(n,t,e,i,r){const s=t&&t.routeConfig?t.routeConfig.canDeactivate:null;return s&&0!==s.length?tt(s.map(a=>{const l=Qh(a,t,r);let c;if(function GG(n){return n&&Ns(n.canDeactivate)}(l))c=fr(l.canDeactivate(n,t,e,i));else{if(!Ns(l))throw new Error("Invalid CanDeactivate guard");c=fr(l(n,t,e,i))}return c.pipe(Do())})).pipe(Ic()):tt(!0)}(r.component,r.route,e,t,i)),Do(r=>!0!==r,!0))}(o,i,r,n).pipe(Pn(a=>a&&function jG(n){return"boolean"==typeof n}(a)?function lW(n,t,e,i){return gn(t).pipe(Da(r=>nh(function dW(n,t){return null!==n&&t&&t(new Z6(n)),tt(!0)}(r.route.parent,i),function cW(n,t){return null!==n&&t&&t(new J6(n)),tt(!0)}(r.route,i),function hW(n,t,e){const i=t[t.length-1],s=t.slice(0,t.length-1).reverse().map(o=>function iW(n){const t=n.routeConfig?n.routeConfig.canActivateChild:null;return t&&0!==t.length?{node:n,guards:t}:null}(o)).filter(o=>null!==o).map(o=>_c(()=>tt(o.guards.map(l=>{const c=Qh(l,o.node,e);let d;if(function $G(n){return n&&Ns(n.canActivateChild)}(c))d=fr(c.canActivateChild(i,n));else{if(!Ns(c))throw new Error("Invalid CanActivateChild guard");d=fr(c(i,n))}return d.pipe(Do())})).pipe(Ic())));return tt(s).pipe(Ic())}(n,r.path,e),function uW(n,t,e){const i=t.routeConfig?t.routeConfig.canActivate:null;if(!i||0===i.length)return tt(!0);const r=i.map(s=>_c(()=>{const o=Qh(s,t,e);let a;if(function zG(n){return n&&Ns(n.canActivate)}(o))a=fr(o.canActivate(t,n));else{if(!Ns(o))throw new Error("Invalid CanActivate guard");a=fr(o(t,n))}return a.pipe(Do())}));return tt(r).pipe(Ic())}(n,r.route,e))),Do(r=>!0!==r,!0))}(i,s,n,t):tt(a)),U(a=>Object.assign(Object.assign({},e),{guardsResult:a})))})}(this.ngModule.injector,a=>this.triggerEvent(a)),wn(a=>{if(xo(a.guardsResult)){const c=Dv(`Redirecting to "${this.serializeUrl(a.guardsResult)}"`);throw c.url=a.guardsResult,c}const l=new W6(a.id,this.serializeUrl(a.extractedUrl),this.serializeUrl(a.urlAfterRedirects),a.targetSnapshot,!!a.guardsResult);this.triggerEvent(l)}),yn(a=>!!a.guardsResult||(this.restoreHistory(a),this.cancelNavigationTransition(a,""),!1)),Zh(a=>{if(a.guards.canActivateChecks.length)return tt(a).pipe(wn(l=>{const c=new q6(l.id,this.serializeUrl(l.extractedUrl),this.serializeUrl(l.urlAfterRedirects),l.targetSnapshot);this.triggerEvent(c)}),Rr(l=>{let c=!1;return tt(l).pipe(function wW(n,t){return Pn(e=>{const{targetSnapshot:i,guards:{canActivateChecks:r}}=e;if(!r.length)return tt(e);let s=0;return gn(r).pipe(Da(o=>function CW(n,t,e,i){const r=n.routeConfig,s=n._resolve;return void 0!==(null==r?void 0:r.title)&&!KT(r)&&(s[Nv]=r.title),function DW(n,t,e,i){const r=function EW(n){return[...Object.keys(n),...Object.getOwnPropertySymbols(n)]}(n);if(0===r.length)return tt({});const s={};return gn(r).pipe(Pn(o=>function MW(n,t,e,i){const r=Qh(n,t,i);return fr(r.resolve?r.resolve(t,e):r(t,e))}(n[o],t,e,i).pipe(Do(),wn(a=>{s[o]=a}))),bv(1),function U6(n){return U(()=>n)}(s),os(o=>o instanceof Dc?Fi:La(o)))}(s,n,t,i).pipe(U(o=>(n._resolvedData=o,n.data=DT(n,e).resolve,r&&KT(r)&&(n.data[Nv]=r.title),null)))}(o.route,i,n,t)),wn(()=>s++),bv(1),Pn(o=>s===r.length?tt(e):Fi))})}(this.paramsInheritanceStrategy,this.ngModule.injector),wn({next:()=>c=!0,complete:()=>{c||(this.restoreHistory(l),this.cancelNavigationTransition(l,"At least one route resolver didn't emit any value."))}}))}),wn(l=>{const c=new Y6(l.id,this.serializeUrl(l.extractedUrl),this.serializeUrl(l.urlAfterRedirects),l.targetSnapshot);this.triggerEvent(c)}))}),Zh(a=>{const{targetSnapshot:l,id:c,extractedUrl:d,rawUrl:f,extras:{skipLocationChange:w,replaceUrl:k}}=a;return this.hooks.afterPreactivation(l,{navigationId:c,appliedUrlTree:d,rawUrlTree:f,skipLocationChange:!!w,replaceUrl:!!k})}),Zh(a=>{const l=c=>{var d;const f=[];(null===(d=c.routeConfig)||void 0===d?void 0:d.loadComponent)&&!c.routeConfig._loadedComponent&&f.push(this.configLoader.loadComponent(c.routeConfig).pipe(wn(w=>{c.component=w}),U(()=>{})));for(const w of c.children)f.push(...l(w));return f};return gv(l(a.targetSnapshot.root)).pipe(wv(),sn(1))}),U(a=>{const l=function DG(n,t,e){const i=Sc(n,t._root,e?e._root:void 0);return new wT(i,t)}(this.routeReuseStrategy,a.targetSnapshot,a.currentRouterState);return Object.assign(Object.assign({},a),{targetRouterState:l})}),wn(a=>{this.currentUrlTree=a.urlAfterRedirects,this.rawUrlTree=this.urlHandlingStrategy.merge(a.urlAfterRedirects,a.rawUrl),this.routerState=a.targetRouterState,"deferred"===this.urlUpdateStrategy&&(a.extras.skipLocationChange||this.setBrowserUrl(this.rawUrlTree,a),this.browserUrlTree=a.urlAfterRedirects)}),((n,t,e)=>U(i=>(new HG(t,i.targetRouterState,i.currentRouterState,e).activate(n),i)))(this.rootContexts,this.routeReuseStrategy,a=>this.triggerEvent(a)),wn({next(){s=!0},complete(){s=!0}}),bh(()=>{var a;s||o||this.cancelNavigationTransition(r,`Navigation ID ${r.id} is not equal to the current navigation id ${this.navigationId}`),(null===(a=this.currentNavigation)||void 0===a?void 0:a.id)===r.id&&(this.currentNavigation=null)}),os(a=>{if(o=!0,function nG(n){return n&&n[oT]}(a)){const l=xo(a.url);l||(this.navigated=!0,this.restoreHistory(r,!0));const c=new rT(r.id,this.serializeUrl(r.extractedUrl),a.message);if(i.next(c),l){const d=this.urlHandlingStrategy.merge(a.url,this.rawUrlTree),f={skipLocationChange:r.extras.skipLocationChange,replaceUrl:"eager"===this.urlUpdateStrategy||XT(r.source)};this.scheduleNavigation(d,"imperative",null,f,{resolve:r.resolve,reject:r.reject,promise:r.promise})}else r.resolve(!1)}else{this.restoreHistory(r,!0);const l=new z6(r.id,this.serializeUrl(r.extractedUrl),a);i.next(l);try{r.resolve(this.errorHandler(a))}catch(c){r.reject(c)}}return Fi}))}))}resetRootComponentType(e){this.rootComponentType=e,this.routerState.root.component=this.rootComponentType}setTransition(e){this.transitions.next(Object.assign(Object.assign({},this.transitions.value),e))}initialNavigation(){this.setUpLocationChangeListener(),0===this.navigationId&&this.navigateByUrl(this.location.path(!0),{replaceUrl:!0})}setUpLocationChangeListener(){this.locationSubscription||(this.locationSubscription=this.location.subscribe(e=>{const i="popstate"===e.type?"popstate":"hashchange";"popstate"===i&&setTimeout(()=>{var r;const s={replaceUrl:!0},o=null!==(r=e.state)&&void 0!==r&&r.navigationId?e.state:null;if(o){const l=Object.assign({},o);delete l.navigationId,delete l.\u0275routerPageId,0!==Object.keys(l).length&&(s.state=l)}const a=this.parseUrl(e.url);this.scheduleNavigation(a,i,o,s)},0)}))}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.currentNavigation}triggerEvent(e){this.events.next(e)}resetConfig(e){this.config=e.map(Fv),this.navigated=!1,this.lastSuccessfulId=-1}ngOnDestroy(){this.dispose()}dispose(){this.transitions.complete(),this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=void 0),this.disposed=!0}createUrlTree(e,i={}){const{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:a,preserveFragment:l}=i,c=r||this.routerState.root,d=l?this.currentUrlTree.fragment:o;let f=null;switch(a){case"merge":f=Object.assign(Object.assign({},this.currentUrlTree.queryParams),s);break;case"preserve":f=this.currentUrlTree.queryParams;break;default:f=s||null}return null!==f&&(f=this.removeEmptyProps(f)),function xG(n,t,e,i,r){var s;if(0===e.length)return Av(t.root,t.root,t.root,i,r);const a=function SG(n){if("string"==typeof n[0]&&1===n.length&&"/"===n[0])return new ST(!0,0,n);let t=0,e=!1;const i=n.reduce((r,s,o)=>{if("object"==typeof s&&null!=s){if(s.outlets){const a={};return Un(s.outlets,(l,c)=>{a[c]="string"==typeof l?l.split("/"):l}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return"string"!=typeof s?[...r,s]:0===o?(s.split("/").forEach((a,l)=>{0==l&&"."===a||(0==l&&""===a?e=!0:".."===a?t++:""!=a&&r.push(a))}),r):[...r,s]},[]);return new ST(e,t,i)}(e);return a.toRoot()?Av(t.root,t.root,new Pt([],{}),i,r):function l(d){var f;const w=function kG(n,t,e,i){return n.isAbsolute?new Iv(t.root,!0,0):-1===i?new Iv(e,e===t.root,0):function TG(n,t,e){let i=n,r=t,s=e;for(;s>r;){if(s-=r,i=i.parent,!i)throw new Error("Invalid number of '../'");r=i.segments.length}return new Iv(i,!1,r-s)}(e,i+(zh(n.commands[0])?0:1),n.numberOfDoubleDots)}(a,t,null===(f=n.snapshot)||void 0===f?void 0:f._urlSegment,d),k=w.processChildren?$h(w.segmentGroup,w.index,a.commands):kT(w.segmentGroup,w.index,a.commands);return Av(t.root,w.segmentGroup,k,i,r)}(null===(s=n.snapshot)||void 0===s?void 0:s._lastPathIndex)}(c,this.currentUrlTree,e,f,null!=d?d:null)}navigateByUrl(e,i={skipLocationChange:!1}){const r=xo(e)?e:this.parseUrl(e),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,"imperative",null,i)}navigate(e,i={skipLocationChange:!1}){return function LW(n){for(let t=0;t{const s=e[r];return null!=s&&(i[r]=s),i},{})}processNavigations(){this.navigations.subscribe(e=>{var i;this.navigated=!0,this.lastSuccessfulId=e.id,this.currentPageId=e.targetPageId,this.events.next(new Ec(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(this.currentUrlTree))),this.lastSuccessfulNavigation=this.currentNavigation,null===(i=this.titleStrategy)||void 0===i||i.updateTitle(this.routerState.snapshot),e.resolve(!0)},e=>{this.console.warn(`Unhandled Navigation Error: ${e}`)})}scheduleNavigation(e,i,r,s,o){var a,l;if(this.disposed)return Promise.resolve(!1);let c,d,f;o?(c=o.resolve,d=o.reject,f=o.promise):f=new Promise((j,K)=>{c=j,d=K});const w=++this.navigationId;let k;return"computed"===this.canceledNavigationResolution?(0===this.currentPageId&&(r=this.location.getState()),k=r&&r.\u0275routerPageId?r.\u0275routerPageId:s.replaceUrl||s.skipLocationChange?null!==(a=this.browserPageId)&&void 0!==a?a:0:(null!==(l=this.browserPageId)&&void 0!==l?l:0)+1):k=0,this.setTransition({id:w,targetPageId:k,source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.rawUrlTree,rawUrl:e,extras:s,resolve:c,reject:d,promise:f,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),f.catch(j=>Promise.reject(j))}setBrowserUrl(e,i){const r=this.urlSerializer.serialize(e),s=Object.assign(Object.assign({},i.extras.state),this.generateNgRouterState(i.id,i.targetPageId));this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl?this.location.replaceState(r,"",s):this.location.go(r,"",s)}restoreHistory(e,i=!1){var r,s;if("computed"===this.canceledNavigationResolution){const o=this.currentPageId-e.targetPageId;"popstate"!==e.source&&"eager"!==this.urlUpdateStrategy&&this.currentUrlTree!==(null===(r=this.currentNavigation)||void 0===r?void 0:r.finalUrl)||0===o?this.currentUrlTree===(null===(s=this.currentNavigation)||void 0===s?void 0:s.finalUrl)&&0===o&&(this.resetState(e),this.browserUrlTree=e.currentUrlTree,this.resetUrlToCurrentUrlTree()):this.location.historyGo(o)}else"replace"===this.canceledNavigationResolution&&(i&&this.resetState(e),this.resetUrlToCurrentUrlTree())}resetState(e){this.routerState=e.currentRouterState,this.currentUrlTree=e.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e.rawUrl)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}cancelNavigationTransition(e,i){const r=new rT(e.id,this.serializeUrl(e.extractedUrl),i);this.triggerEvent(r),e.resolve(!1)}generateNgRouterState(e,i){return"computed"===this.canceledNavigationResolution?{navigationId:e,\u0275routerPageId:i}:{navigationId:e}}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function XT(n){return"imperative"!==n}let Xh=(()=>{class n{constructor(e,i,r){this.router=e,this.route=i,this.locationStrategy=r,this.commands=null,this.href=null,this.onChanges=new ue,this.subscription=e.events.subscribe(s=>{s instanceof Ec&&this.updateTargetUrlAndHref()})}set routerLink(e){this.commands=null!=e?Array.isArray(e)?e:[e]:null}ngOnChanges(e){this.updateTargetUrlAndHref(),this.onChanges.next(this)}ngOnDestroy(){this.subscription.unsubscribe()}onClick(e,i,r,s,o){if(0!==e||i||r||s||o||"string"==typeof this.target&&"_self"!=this.target||null===this.urlTree)return!0;const a={skipLocationChange:ts(this.skipLocationChange),replaceUrl:ts(this.replaceUrl),state:this.state};return this.router.navigateByUrl(this.urlTree,a),!1}updateTargetUrlAndHref(){this.href=null!==this.urlTree?this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree)):null}get urlTree(){return null===this.commands?null:this.router.createUrlTree(this.commands,{relativeTo:void 0!==this.relativeTo?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:ts(this.preserveFragment)})}}return n.\u0275fac=function(e){return new(e||n)(x(Ri),x($a),x(ya))},n.\u0275dir=Me({type:n,selectors:[["a","routerLink",""],["area","routerLink",""]],hostVars:2,hostBindings:function(e,i){1&e&&$e("click",function(s){return i.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),2&e&&wt("target",i.target)("href",i.href,Kf)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",preserveFragment:"preserveFragment",skipLocationChange:"skipLocationChange",replaceUrl:"replaceUrl",state:"state",relativeTo:"relativeTo",routerLink:"routerLink"},features:[cn]}),n})();class JT{buildTitle(t){var e;let i,r=t.root;for(;void 0!==r;)i=null!==(e=this.getResolvedTitleForRoute(r))&&void 0!==e?e:i,r=r.children.find(s=>s.outlet===Et);return i}getResolvedTitleForRoute(t){return t.data[Nv]}}let VW=(()=>{class n extends JT{constructor(e){super(),this.title=e}updateTitle(e){const i=this.buildTitle(e);void 0!==i&&this.title.setTitle(i)}}return n.\u0275fac=function(e){return new(e||n)(te(OE))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class eA{}class tA{preload(t,e){return tt(null)}}let nA=(()=>{class n{constructor(e,i,r,s,o){this.router=e,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(yn(e=>e instanceof Ec),Da(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(e,i){var r,s,o;const a=[];for(const l of i){l.providers&&!l._injector&&(l._injector=Nd(l.providers,e,`Route: ${l.path}`));const c=null!==(r=l._injector)&&void 0!==r?r:e,d=null!==(s=l._loadedInjector)&&void 0!==s?s:c;l.loadChildren&&!l._loadedRoutes||l.loadComponent&&!l._loadedComponent?a.push(this.preloadConfig(c,l)):(l.children||l._loadedRoutes)&&a.push(this.processRoutes(d,null!==(o=l.children)&&void 0!==o?o:l._loadedRoutes))}return gn(a).pipe(To())}preloadConfig(e,i){return this.preloadingStrategy.preload(i,()=>{let r;r=i.loadChildren&&void 0===i.canLoad?this.loader.loadChildren(e,i):tt(null);const s=r.pipe(Pn(o=>{var a;return null===o?tt(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(null!==(a=o.injector)&&void 0!==a?a:e,o.routes))}));return i.loadComponent&&!i._loadedComponent?gn([s,this.loader.loadComponent(i)]).pipe(To()):s})}}return n.\u0275fac=function(e){return new(e||n)(te(Ri),te(Rm),te(Qs),te(eA),te(Vv))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),jv=(()=>{class n{constructor(e,i,r={}){this.router=e,this.viewportScroller=i,this.options=r,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},r.scrollPositionRestoration=r.scrollPositionRestoration||"disabled",r.anchorScrolling=r.anchorScrolling||"disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.router.events.subscribe(e=>{e instanceof Cv?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=e.navigationTrigger,this.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof Ec&&(this.lastId=e.id,this.scheduleScrollEvent(e,this.router.parseUrl(e.urlAfterRedirects).fragment))})}consumeScrollEvents(){return this.router.events.subscribe(e=>{e instanceof sT&&(e.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(e.position):e.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(e.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(e,i){this.router.triggerEvent(new sT(e,"popstate"===this.lastSource?this.store[this.restoredId]:null,i))}ngOnDestroy(){this.routerEventsSubscription&&this.routerEventsSubscription.unsubscribe(),this.scrollEventsSubscription&&this.scrollEventsSubscription.unsubscribe()}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const So=new De("ROUTER_CONFIGURATION"),iA=new De("ROUTER_FORROOT_GUARD"),jW=[Vl,{provide:mT,useClass:gT},{provide:Ri,useFactory:function WW(n,t,e,i,r,s,o={},a,l,c,d){const f=new Ri(null,n,t,e,i,r,lT(s));return c&&(f.urlHandlingStrategy=c),d&&(f.routeReuseStrategy=d),f.titleStrategy=null!=l?l:a,function qW(n,t){n.errorHandler&&(t.errorHandler=n.errorHandler),n.malformedUriErrorHandler&&(t.malformedUriErrorHandler=n.malformedUriErrorHandler),n.onSameUrlNavigation&&(t.onSameUrlNavigation=n.onSameUrlNavigation),n.paramsInheritanceStrategy&&(t.paramsInheritanceStrategy=n.paramsInheritanceStrategy),n.relativeLinkResolution&&(t.relativeLinkResolution=n.relativeLinkResolution),n.urlUpdateStrategy&&(t.urlUpdateStrategy=n.urlUpdateStrategy),n.canceledNavigationResolution&&(t.canceledNavigationResolution=n.canceledNavigationResolution)}(o,f),f},deps:[mT,Tc,Vl,Jt,Rm,Bv,So,VW,[JT,new Hn],[class TW{},new Hn],[class xW{},new Hn]]},Tc,{provide:$a,useFactory:function YW(n){return n.routerState.root},deps:[Ri]},nA,tA,class HW{preload(t,e){return e().pipe(os(()=>tt(null)))}},{provide:So,useValue:{enableTracing:!1}},Vv];function UW(){return new xD("Router",Ri)}let rA=(()=>{class n{constructor(e,i){}static forRoot(e,i){return{ngModule:n,providers:[jW,sA(e),{provide:iA,useFactory:GW,deps:[[Ri,new Hn,new ir]]},{provide:So,useValue:i||{}},{provide:ya,useFactory:$W,deps:[Bl,[new cd($m),new Hn],So]},{provide:jv,useFactory:zW,deps:[Ri,DV,So]},{provide:eA,useExisting:i&&i.preloadingStrategy?i.preloadingStrategy:tA},{provide:xD,multi:!0,useFactory:UW},[Uv,{provide:Am,multi:!0,useFactory:KW,deps:[Uv]},{provide:oA,useFactory:QW,deps:[Uv]},{provide:bD,multi:!0,useExisting:oA}]]}}static forChild(e){return{ngModule:n,providers:[sA(e)]}}}return n.\u0275fac=function(e){return new(e||n)(te(iA,8),te(Ri,8))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();function zW(n,t,e){return e.scrollOffset&&t.setOffset(e.scrollOffset),new jv(n,t,e)}function $W(n,t,e={}){return e.useHash?new hB(n,t):new KD(n,t)}function GW(n){return"guarded"}function sA(n){return[{provide:$I,multi:!0,useValue:n},{provide:Bv,multi:!0,useValue:n}]}let Uv=(()=>{class n{constructor(e){this.injector=e,this.initNavigation=!1,this.destroyed=!1,this.resultOfPreactivationDone=new ue}appInitializer(){return this.injector.get(cB,Promise.resolve(null)).then(()=>{if(this.destroyed)return Promise.resolve(!0);let i=null;const r=new Promise(a=>i=a),s=this.injector.get(Ri),o=this.injector.get(So);return"disabled"===o.initialNavigation?(s.setUpLocationChangeListener(),i(!0)):"enabledBlocking"===o.initialNavigation?(s.hooks.afterPreactivation=()=>this.initNavigation?tt(null):(this.initNavigation=!0,i(!0),this.resultOfPreactivationDone),s.initialNavigation()):i(!0),r})}bootstrapListener(e){const i=this.injector.get(So),r=this.injector.get(nA),s=this.injector.get(jv),o=this.injector.get(Ri),a=this.injector.get(Ll);e===a.components[0]&&(("enabledNonBlocking"===i.initialNavigation||void 0===i.initialNavigation)&&o.initialNavigation(),r.setUpPreloading(),s.init(),o.resetRootComponentType(a.componentTypes[0]),this.resultOfPreactivationDone.next(null),this.resultOfPreactivationDone.complete())}ngOnDestroy(){this.destroyed=!0}}return n.\u0275fac=function(e){return new(e||n)(te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function KW(n){return n.appInitializer.bind(n)}function QW(n){return n.bootstrapListener.bind(n)}const oA=new De("Router Initializer");class XW{constructor(t){this.request=t}}let Or=(()=>{class n{constructor(){this.pages=[{page:"home",caption:"Home"}],this.apiLog=new Array,this.pipelineMap=new Map}cameraIsOnvif(){return void 0!==this.cameraFeatures&&"Onvif"===this.cameraFeatures.CameraType}cameraIsUSB(){return void 0!==this.cameraFeatures&&"USB"===this.cameraFeatures.CameraType}getUSBConfig(){const e=this.inputPixelFormat?this.imageFormats[this.inputPixelFormat]:void 0,i=e&&this.inputImageSize?e.FrameSizes[this.inputImageSize].Size:void 0;return{InputFps:this.inputFps,InputImageSize:i?i.MaxWidth+"x"+i.MaxHeight:void 0,InputPixelFormat:e?e.PixelFormat:void 0,OutputVideoQuality:this.outputVideoQuality}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Fr_mqtt_port=59001,Fr_mqtt_path="/mqtt",Fr_mqtt_topic="incoming/data/edge-video-analytics/inference-event";class Fc{static forUSB(t,e,i){const r=new Fc;return r.usb=i,r.pipeline_name=t,r.pipeline_version=e,r}static forOnvif(t,e,i){const r=new Fc;return r.onvif=i,r.pipeline_name=t,r.pipeline_version=e,r}}const zv="X-CameraApp-Ignore",aA={headers:new Wi({"Content-Type":"application/json; charset=utf-8"})};let Jh=(()=>{class n{constructor(e,i){this.httpClient=e,this.data=i,this.camerasUrl="/api/v2/cameras"}makeCameraUrl(e,i){return`${this.camerasUrl}/${e}${i}`}makePipelineUrl(e,i){return this.makeCameraUrl(e,`/pipeline${i}`)}makeProfileUrl(e,i,r){return this.makeCameraUrl(e,`/profiles/${i}`)+r}makePresetUrl(e,i,r){return this.makeProfileUrl(e,i,"/presets/")+r}updateCameraList(){this.data.cameras=void 0,this.data.cameraMap=void 0,this.httpClient.get(this.camerasUrl).subscribe({next:e=>{this.data.cameras=e,this.data.cameraMap=new Map;for(let i of e)this.data.cameraMap.set(i.name,i);e.length>0?(this.data.selectedCamera=e[0].name,this.updateCameraChanged(this.data.selectedCamera),this.refreshPipelineStatus(this.data.selectedCamera,!0)):this.data.selectedCamera=void 0},error:e=>{this.data.cameras=void 0,this.data.cameraMap=void 0}})}clearCameraInfo(){this.data.selectedProfile=void 0,this.data.profiles=void 0,this.data.selectedPreset=void 0,this.data.presets=void 0,this.data.imageFormats=void 0,this.data.inputPixelFormat=void 0,this.data.inputImageSize=void 0,this.data.cameraFeatures=void 0}updateCameraChanged(e){this.clearCameraInfo(),this.updateCameraFeatures(e)}updateCameraFeatures(e){this.httpClient.get(this.makeCameraUrl(e,"/features")).subscribe({next:i=>{this.data.cameraFeatures=i,this.data.cameraIsOnvif()?this.updateProfiles(e):this.data.cameraIsUSB()?this.updateImageFormats(e):console.log("error, invalid camera type: "+i.CameraType)},error:i=>{}})}updateProfiles(e){this.httpClient.get(this.makeCameraUrl(e,"/profiles")).subscribe({next:i=>{this.data.profiles=i.Profiles,this.data.selectedProfile=i.Profiles.length>0?i.Profiles[0].Token:void 0,this.updatePresets(e,this.data.selectedProfile)},error:i=>{this.data.selectedProfile=void 0,this.data.profiles=void 0}})}updatePresets(e,i){this.httpClient.get(this.makeProfileUrl(e,i,"/presets")).subscribe({next:r=>{this.data.presets=r.Preset,this.data.selectedPreset=r.Preset.length>0?r.Preset[0].Token:void 0},error:r=>{this.data.presets=void 0}})}updateImageFormats(e){this.data.imageFormats=void 0,this.httpClient.get(this.makeCameraUrl(e,"/imageformats")).subscribe({next:i=>{this.data.imageFormats=i.ImageFormats},error:i=>{this.data.imageFormats=void 0}})}gotoPreset(e,i,r){return this.httpClient.post(this.makePresetUrl(e,i,r),"").subscribe()}startOnvifPipeline(e,i,r,s){let o=this.makePipelineUrl(e,"/start"),a=Fc.forOnvif(i,r,{profile_token:s});this.httpClient.post(o,JSON.stringify(a),aA).subscribe(l=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}startUSBPipeline(e,i,r,s){let o=this.makePipelineUrl(e,"/start"),a=Fc.forUSB(i,r,s);this.httpClient.post(o,JSON.stringify(a),aA).subscribe(l=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}stopPipeline(e,i){let r=this.makePipelineUrl(e,`/stop/${i}`);this.httpClient.post(r,"").subscribe(s=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}refreshPipelineStatus(e,i){let r=this.makePipelineUrl(e,"/status"),s={};i&&(s[zv]="true"),this.httpClient.get(r,{headers:new Wi(s)}).subscribe({next:o=>{this.data.pipelineStatus=o},error:o=>{this.data.pipelineStatus=void 0}})}refreshAllPipelineStatuses(){this.httpClient.get("/api/v2/pipelines/status/all",{headers:new Wi({"X-CameraApp-Ignore":"true"})}).subscribe({next:r=>{if(null!=r){for(const s of this.data.pipelineMap.keys())r.hasOwnProperty(s)||(console.log("deleting key:",s),this.data.pipelineMap.delete(s));for(const[s,o]of Object.entries(r)){let a=this.data.pipelineMap.get(s);void 0===a?this.data.pipelineMap.set(s,o):(a.status=o.status,a.info=o.info)}}else this.data.pipelineMap.clear()},error:r=>{this.data.pipelineMap.clear()}})}updatePipelinesList(){this.data.pipelines=void 0,this.httpClient.get("/api/v2/pipelines").subscribe({next:e=>{this.data.pipelines=e.filter(i=>!!this.shouldShowPipeline(i)&&("object_detection/person_vehicle_bike"==`${i.name}/${i.version}`&&(this.data.selectedPipeline="object_detection/person_vehicle_bike"),!0))},error:e=>{this.data.pipelines=void 0}})}shouldShowPipeline(e){return"audio_detection"!==e.name&&"video_decode"!==e.name&&"app_src_dst"!==e.version&&"object_zone_count"!==e.version&&"object_line_crossing"!==e.version}}return n.\u0275fac=function(e){return new(e||n)(te(nc),te(Or))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();var JW=ps(841),lA=ps(703);class tq extends ue{constructor(t=1/0,e=1/0,i=E_){super(),this._bufferSize=t,this._windowTime=e,this._timestampProvider=i,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=e===1/0,this._bufferSize=Math.max(1,t),this._windowTime=Math.max(1,e)}next(t){const{isStopped:e,_buffer:i,_infiniteTimeWindow:r,_timestampProvider:s,_windowTime:o}=this;e||(i.push(t),!r&&i.push(s.now()+o)),this._trimBuffer(),super.next(t)}_subscribe(t){this._throwIfClosed(),this._trimBuffer();const e=this._innerSubscribe(t),{_infiniteTimeWindow:i,_buffer:r}=this,s=r.slice();for(let o=0;onew ue};function cA(n,t=iq){const{connector:e}=t;return Pe((i,r)=>{const s=e();gn(n(function nq(n){return new J(t=>n.subscribe(t))}(s))).subscribe(r),r.add(i.subscribe(s))})}function dA(n,t){const e=ut(n)?n:()=>n;return ut(t)?cA(t,{connector:e}):i=>new yv(i,e)}var Bs=(()=>{return(n=Bs||(Bs={}))[n.CLOSED=0]="CLOSED",n[n.CONNECTING=1]="CONNECTING",n[n.CONNECTED=2]="CONNECTED",Bs;var n})();const $v=new De("NgxMqttServiceConfig"),Gv=new De("NgxMqttClientService");let oq=(()=>{class n{static forRoot(e,i){return{ngModule:n,providers:[{provide:$v,useValue:e},{provide:Gv,useValue:i}]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),aq=(()=>{class n{constructor(e,i){this.options=e,this.client=i,this.observables={},this.state=new mi(Bs.CLOSED),this.messages=new ue,this._clientId=this._generateClientId(),this._connectTimeout=1e4,this._reconnectPeriod=1e4,this._url=void 0,this._onConnect=new je,this._onReconnect=new je,this._onClose=new je,this._onOffline=new je,this._onError=new je,this._onEnd=new je,this._onMessage=new je,this._onSuback=new je,this._onPacketsend=new je,this._onPacketreceive=new je,this._handleOnConnect=r=>{!0===this.options.connectOnCreate&&Object.keys(this.observables).forEach(s=>{this.client.subscribe(s)}),this.state.next(Bs.CONNECTED),this._onConnect.emit(r)},this._handleOnReconnect=()=>{!0===this.options.connectOnCreate&&Object.keys(this.observables).forEach(r=>{this.client.subscribe(r)}),this.state.next(Bs.CONNECTING),this._onReconnect.emit()},this._handleOnClose=()=>{this.state.next(Bs.CLOSED),this._onClose.emit()},this._handleOnOffline=()=>{this._onOffline.emit()},this._handleOnError=r=>{this._onError.emit(r),console.error(r)},this._handleOnEnd=()=>{this._onEnd.emit()},this._handleOnMessage=(r,s,o)=>{this._onMessage.emit(o),"publish"===o.cmd&&this.messages.next(o)},this._handleOnPacketsend=r=>{this._onPacketsend.emit()},this._handleOnPacketreceive=r=>{this._onPacketreceive.emit()},!1!==e.connectOnCreate&&this.connect({},i),this.state.subscribe()}get clientId(){return this._clientId}get onConnect(){return this._onConnect}get onReconnect(){return this._onReconnect}get onClose(){return this._onClose}get onOffline(){return this._onOffline}get onError(){return this._onError}get onEnd(){return this._onEnd}get onMessage(){return this._onMessage}get onPacketsend(){return this._onPacketsend}get onPacketreceive(){return this._onPacketreceive}get onSuback(){return this._onSuback}static filterMatchesTopic(e,i){if("#"===e[0]&&"$"===i[0])return!1;const r=(e||"").split("/").reverse(),s=(i||"").split("/").reverse(),o=()=>{const a=r.pop(),l=s.pop();switch(a){case"#":return!0;case"+":return!!l&&o();default:return a===l&&(void 0===a||o())}};return o()}connect(e,i){const r=lA(this.options||{},e),s=r.protocol||"ws",o=r.hostname||"localhost";r.url?this._url=r.url:(this._url=`${s}://${o}`,this._url+=r.port?`:${r.port}`:"",this._url+=r.path?`${r.path}`:""),this.state.next(Bs.CONNECTING);const a=lA({clientId:this._clientId,reconnectPeriod:this._reconnectPeriod,connectTimeout:this._connectTimeout},r);this.client&&this.client.end(!0),this.client=i||(0,JW.connect)(this._url,a),this._clientId=a.clientId,this.client.on("connect",this._handleOnConnect),this.client.on("reconnect",this._handleOnReconnect),this.client.on("close",this._handleOnClose),this.client.on("offline",this._handleOnOffline),this.client.on("error",this._handleOnError),this.client.stream.on("error",this._handleOnError),this.client.on("end",this._handleOnEnd),this.client.on("message",this._handleOnMessage),this.client.on("packetsend",this._handleOnPacketsend),this.client.on("packetreceive",this._handleOnPacketreceive)}disconnect(e=!0){if(!this.client)throw new Error("mqtt client not connected");this.client.end(e)}observeRetained(e,i={qos:1}){return this._generalObserve(e,()=>function rq(n,t,e,i){e&&!ut(e)&&(i=e);const r=ut(e)?e:void 0;return s=>dA(new tq(n,t,i),r)(s)}(1),i)}observe(e,i={qos:1}){return this._generalObserve(e,()=>function sq(n){return n?t=>cA(n)(t):t=>dA(new ue)(t)}(),i)}_generalObserve(e,i,r){if(!this.client)throw new Error("mqtt client not connected");if(!this.observables[e]){const s=new ue;this.observables[e]=function eq(n,t){return new J(e=>{const i=n(),r=t(i);return(r?di(r):Fi).subscribe(e),()=>{i&&i.unsubscribe()}})}(()=>{const o=new X;return this.client.subscribe(e,r,(a,l)=>{l&&l.forEach(c=>{128===c.qos&&(delete this.observables[c.topic],this.client.unsubscribe(c.topic),s.error(`subscription for '${c.topic}' rejected!`)),this._onSuback.emit({filter:e,granted:128!==c.qos})})}),o.add(()=>{delete this.observables[e],this.client.unsubscribe(e)}),o},o=>$n(s,this.messages)).pipe(yn(o=>n.filterMatchesTopic(e,o.topic)),i(),Lh())}return this.observables[e]}publish(e,i,r={}){if(!this.client)throw new Error("mqtt client not connected");return J.create(s=>{this.client.publish(e,i,r,o=>{o?s.error(o):(s.next(null),s.complete())})})}unsafePublish(e,i,r={}){if(!this.client)throw new Error("mqtt client not connected");this.client.publish(e,i,r,s=>{if(s)throw s})}_generateClientId(){return"client-"+Math.random().toString(36).substr(2,19)}}return n.\u0275fac=function(e){return new(e||n)(te($v),te(Gv))},n.\u0275prov=Ie({factory:function(){return new n(te($v),te(Gv))},token:n,providedIn:"root"}),n})(),Wv=(()=>{class n{constructor(e){this._mqttService=e,this.paused=!0,this.eventCount=0}isPaused(){return this.paused}pause(){this.paused||(this.paused=!0,this.unsubscribe())}resume(){this.paused&&(this.paused=!1,this.subscribe())}unsubscribe(){this.subscription&&(this.subscription.unsubscribe(),this.subscription=void 0)}subscribe(){this.subscription=this._mqttService.observe(Fr_mqtt_topic).subscribe(e=>{this.lastEvent=JSON.parse(e.payload.toString()),this.eventCount++})}}return n.\u0275fac=function(e){return new(e||n)(te(aq))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),lq=(()=>{class n{constructor(e,i){this.httpClient=e,this.data=i}makePtzUrl(e,i,r){return`/api/v2/cameras/${e}/profiles/${i}/ptz${r}`}post(e,i,r){let s=this.makePtzUrl(e,i,r);return this.httpClient.post(s,"").subscribe()}downLeft(e,i){return this.post(e,i,"/down-left")}down(e,i){return this.post(e,i,"/down")}downRight(e,i){return this.post(e,i,"/down-right")}upLeft(e,i){return this.post(e,i,"/up-left")}up(e,i){return this.post(e,i,"/up")}upRight(e,i){return this.post(e,i,"/up-right")}left(e,i){return this.post(e,i,"/left")}right(e,i){return this.post(e,i,"/right")}home(e,i){return this.post(e,i,"/home")}zoomIn(e,i){return this.post(e,i,"/zoom-in")}zoomOut(e,i){return this.post(e,i,"/zoom-out")}}return n.\u0275fac=function(e){return new(e||n)(te(nc),te(Or))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function cq(n,t){if(1&n&&(fe(0,"mat-option",9),Ue(1),we()),2&n){const e=t.$implicit;Ae("value",e.Token),Ee(1),Ln(" ",void 0===e.Name||""===e.Name?e.Token:e.Name," ")}}function dq(n,t){if(1&n){const e=ki();fe(0,"div",4),kt(1,"br"),fe(2,"mat-form-field",5)(3,"mat-label"),Ue(4,"Select Preset"),we(),fe(5,"mat-select",6),$e("ngModelChange",function(r){return Bn(e),Vn(lt().data.selectedPreset=r)}),it(6,cq,2,2,"mat-option",7),we()(),fe(7,"button",8),$e("click",function(){Bn(e);const r=lt();return Vn(r.api.gotoPreset(r.data.selectedCamera,r.data.selectedProfile,r.data.selectedPreset))}),Ue(8," Goto Preset "),we()()}if(2&n){const e=lt();Ee(5),Ae("ngModel",e.data.selectedPreset),Ee(1),Ae("ngForOf",e.data.presets),Ee(1),Ae("disabled",void 0===e.data.selectedPreset)}}let uq=(()=>{class n{constructor(e,i,r){this.data=e,this.ptz=i,this.api=r}ngOnInit(){}ngOnDestroy(){}isPtzDisabled(){return void 0===this.data.cameraFeatures||!1===this.data.cameraFeatures.PTZ}isZoomDisabled(){return void 0===this.data.cameraFeatures||!1===this.data.cameraFeatures.Zoom}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(lq),x(Jh))},n.\u0275cmp=vt({type:n,selectors:[["app-ptz"]],decls:37,vars:12,consts:[["mat-icon-button","",3,"disabled","click"],["mat-icon-button","",3,"disabled"],[1,"center-button"],["class","goto-presets",4,"ngIf"],[1,"goto-presets"],["appearance","fill"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["mat-raised-button","","color","primary",1,"preset-button",3,"disabled","click"],[3,"value"]],template:function(e,i){1&e&&(fe(0,"div")(1,"button",0),$e("click",function(){return i.ptz.upLeft(i.data.selectedCamera,i.data.selectedProfile)}),fe(2,"mat-icon"),Ue(3,"north_west"),we()(),fe(4,"button",0),$e("click",function(){return i.ptz.up(i.data.selectedCamera,i.data.selectedProfile)}),fe(5,"mat-icon"),Ue(6,"north"),we()(),fe(7,"button",0),$e("click",function(){return i.ptz.upRight(i.data.selectedCamera,i.data.selectedProfile)}),fe(8,"mat-icon"),Ue(9,"north_east"),we()(),fe(10,"button",0),$e("click",function(){return i.ptz.zoomIn(i.data.selectedCamera,i.data.selectedProfile)}),fe(11,"mat-icon"),Ue(12,"zoom_in"),we()()(),fe(13,"div")(14,"button",0),$e("click",function(){return i.ptz.left(i.data.selectedCamera,i.data.selectedProfile)}),fe(15,"mat-icon"),Ue(16,"west"),we()(),fe(17,"button",1)(18,"mat-icon",2),Ue(19,"circle"),we()(),fe(20,"button",0),$e("click",function(){return i.ptz.right(i.data.selectedCamera,i.data.selectedProfile)}),fe(21,"mat-icon"),Ue(22,"east"),we()(),fe(23,"button",0),$e("click",function(){return i.ptz.zoomOut(i.data.selectedCamera,i.data.selectedProfile)}),fe(24,"mat-icon"),Ue(25,"zoom_out"),we()()(),fe(26,"div")(27,"button",0),$e("click",function(){return i.ptz.downLeft(i.data.selectedCamera,i.data.selectedProfile)}),fe(28,"mat-icon"),Ue(29,"south_west"),we()(),fe(30,"button",0),$e("click",function(){return i.ptz.down(i.data.selectedCamera,i.data.selectedProfile)}),fe(31,"mat-icon"),Ue(32,"south"),we()(),fe(33,"button",0),$e("click",function(){return i.ptz.downRight(i.data.selectedCamera,i.data.selectedProfile)}),fe(34,"mat-icon"),Ue(35,"south_east"),we()()(),it(36,dq,9,3,"div",3)),2&e&&(Ee(1),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isZoomDisabled()),Ee(4),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",!0),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isZoomDisabled()),Ee(4),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("ngIf",null!=i.data.presets&&i.data.presets.length>0))},dependencies:[ao,zi,ex,Xg,Aa,GS,ch,Eh,xk,Y_],styles:[".mat-icon-button[_ngcontent-%COMP%]{width:auto;height:auto;margin:5px}.material-icons[_ngcontent-%COMP%]{zoom:2}.preset-button[_ngcontent-%COMP%]{margin:10px}.center-button[_ngcontent-%COMP%]{color:transparent;background-color:transparent}"]}),n})(),hq=0;const qv=new De("CdkAccordion");let fq=(()=>{class n{constructor(){this._stateChanges=new ue,this._openCloseAllActions=new ue,this.id="cdk-accordion-"+hq++,this._multi=!1}get multi(){return this._multi}set multi(e){this._multi=rt(e)}openAll(){this._multi&&this._openCloseAllActions.next(!0)}closeAll(){this._openCloseAllActions.next(!1)}ngOnChanges(e){this._stateChanges.next(e)}ngOnDestroy(){this._stateChanges.complete(),this._openCloseAllActions.complete()}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:"multi"},exportAs:["cdkAccordion"],features:[Xe([{provide:qv,useExisting:n}]),cn]}),n})(),pq=0,mq=(()=>{class n{constructor(e,i,r){this.accordion=e,this._changeDetectorRef=i,this._expansionDispatcher=r,this._openCloseAllSubscription=X.EMPTY,this.closed=new je,this.opened=new je,this.destroyed=new je,this.expandedChange=new je,this.id="cdk-accordion-child-"+pq++,this._expanded=!1,this._disabled=!1,this._removeUniqueSelectionListener=()=>{},this._removeUniqueSelectionListener=r.listen((s,o)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===o&&this.id!==s&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}get expanded(){return this._expanded}set expanded(e){e=rt(e),this._expanded!==e&&(this._expanded=e,this.expandedChange.emit(e),e?(this.opened.emit(),this._expansionDispatcher.notify(this.id,this.accordion?this.accordion.id:this.id)):this.closed.emit(),this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled}set disabled(e){this._disabled=rt(e)}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}}return n.\u0275fac=function(e){return new(e||n)(x(qv,12),x(en),x(Q_))},n.\u0275dir=Me({type:n,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:"expanded",disabled:"disabled"},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[Xe([{provide:qv,useValue:void 0}])]}),n})(),gq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const _q=["body"];function vq(n,t){}const yq=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],bq=["mat-expansion-panel-header","*","mat-action-row"];function wq(n,t){1&n&&kt(0,"span",2),2&n&&Ae("@indicatorRotate",lt()._getExpandedState())}const Cq=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],Dq=["mat-panel-title","mat-panel-description","*"],Yv=new De("MAT_ACCORDION"),uA="225ms cubic-bezier(0.4,0.0,0.2,1)",hA={indicatorRotate:jn("indicatorRotate",[zt("collapsed, void",Qe({transform:"rotate(0deg)"})),zt("expanded",Qe({transform:"rotate(180deg)"})),Wt("expanded <=> collapsed, void => collapsed",Zt(uA))]),bodyExpansion:jn("bodyExpansion",[zt("collapsed, void",Qe({height:"0px",visibility:"hidden"})),zt("expanded",Qe({height:"*",visibility:"visible"})),Wt("expanded <=> collapsed, void => collapsed",Zt(uA))])},fA=new De("MAT_EXPANSION_PANEL");let Eq=(()=>{class n{constructor(e,i){this._template=e,this._expansionPanel=i}}return n.\u0275fac=function(e){return new(e||n)(x(_n),x(fA,8))},n.\u0275dir=Me({type:n,selectors:[["ng-template","matExpansionPanelContent",""]]}),n})(),Mq=0;const pA=new De("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS");let Kv=(()=>{class n extends mq{constructor(e,i,r,s,o,a,l){super(e,i,r),this._viewContainerRef=s,this._animationMode=a,this._hideToggle=!1,this.afterExpand=new je,this.afterCollapse=new je,this._inputChanges=new ue,this._headerId="mat-expansion-panel-header-"+Mq++,this._bodyAnimationDone=new ue,this.accordion=e,this._document=o,this._bodyAnimationDone.pipe(k_((c,d)=>c.fromState===d.fromState&&c.toState===d.toState)).subscribe(c=>{"void"!==c.fromState&&("expanded"===c.toState?this.afterExpand.emit():"collapsed"===c.toState&&this.afterCollapse.emit())}),l&&(this.hideToggle=l.hideToggle)}get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=rt(e)}get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_hasSpacing(){return!!this.accordion&&this.expanded&&"default"===this.accordion.displayMode}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(Qn(null),yn(()=>this.expanded&&!this._portal),sn(1)).subscribe(()=>{this._portal=new mc(this._lazyContent._template,this._viewContainerRef)})}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._bodyAnimationDone.complete(),this._inputChanges.complete()}_containsFocus(){if(this._body){const e=this._document.activeElement,i=this._body.nativeElement;return e===i||i.contains(e)}return!1}}return n.\u0275fac=function(e){return new(e||n)(x(Yv,12),x(en),x(Q_),x(An),x(ct),x(fn,8),x(pA,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-expansion-panel"]],contentQueries:function(e,i,r){if(1&e&&It(r,Eq,5),2&e){let s;Ge(s=We())&&(i._lazyContent=s.first)}},viewQuery:function(e,i){if(1&e&&Gt(_q,5),2&e){let r;Ge(r=We())&&(i._body=r.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:6,hostBindings:function(e,i){2&e&&At("mat-expanded",i.expanded)("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-expansion-panel-spacing",i._hasSpacing())},inputs:{disabled:"disabled",expanded:"expanded",hideToggle:"hideToggle",togglePosition:"togglePosition"},outputs:{opened:"opened",closed:"closed",expandedChange:"expandedChange",afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[Xe([{provide:Yv,useValue:void 0},{provide:fA,useExisting:n}]),Le,cn],ngContentSelectors:bq,decls:7,vars:4,consts:[["role","region",1,"mat-expansion-panel-content",3,"id"],["body",""],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(e,i){1&e&&(Fn(yq),Tt(0),fe(1,"div",0,1),$e("@bodyExpansion.done",function(s){return i._bodyAnimationDone.next(s)}),fe(3,"div",2),Tt(4,1),it(5,vq,0,0,"ng-template",3),we(),Tt(6,2),we()),2&e&&(Ee(1),Ae("@bodyExpansion",i._getExpandedState())("id",i.id),wt("aria-labelledby",i._headerId),Ee(4),Ae("cdkPortalOutlet",i._portal))},dependencies:[Ra],styles:['.mat-expansion-panel{box-sizing:content-box;display:block;margin:0;border-radius:4px;overflow:hidden;transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);position:relative}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:4px;border-top-left-radius:4px}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:4px;border-bottom-left-radius:4px}.cdk-high-contrast-active .mat-expansion-panel{outline:solid 1px}.mat-expansion-panel.ng-animate-disabled,.ng-animate-disabled .mat-expansion-panel,.mat-expansion-panel._mat-animation-noopable{transition:none}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible}.mat-expansion-panel-content[style*="visibility: hidden"] *{visibility:hidden !important}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px}.mat-action-row .mat-button-base,.mat-action-row .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row .mat-button-base,[dir=rtl] .mat-action-row .mat-mdc-button-base{margin-left:0;margin-right:8px}'],encapsulation:2,data:{animation:[hA.bodyExpansion]},changeDetection:0}),n})();class xq{}const Sq=yo(xq);let Qv=(()=>{class n extends Sq{constructor(e,i,r,s,o,a,l){super(),this.panel=e,this._element=i,this._focusMonitor=r,this._changeDetectorRef=s,this._animationMode=a,this._parentChangeSubscription=X.EMPTY;const c=e.accordion?e.accordion._stateChanges.pipe(yn(d=>!(!d.hideToggle&&!d.togglePosition))):Fi;this.tabIndex=parseInt(l||"")||0,this._parentChangeSubscription=$n(e.opened,e.closed,c,e._inputChanges.pipe(yn(d=>!!(d.hideToggle||d.disabled||d.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),e.closed.pipe(yn(()=>e._containsFocus())).subscribe(()=>r.focusVia(i,"program")),o&&(this.expandedHeight=o.expandedHeight,this.collapsedHeight=o.collapsedHeight)}get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){const e=this._isExpanded();return e&&this.expandedHeight?this.expandedHeight:!e&&this.collapsedHeight?this.collapsedHeight:null}_keydown(e){switch(e.keyCode){case 32:case 13:gi(e)||(e.preventDefault(),this._toggle());break;default:return void(this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(e))}}focus(e,i){e?this._focusMonitor.focusVia(this._element,e,i):this._element.nativeElement.focus(i)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(e=>{e&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}}return n.\u0275fac=function(e){return new(e||n)(x(Kv,1),x(Je),x(hr),x(en),x(pA,8),x(fn,8),ii("tabindex"))},n.\u0275cmp=vt({type:n,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:15,hostBindings:function(e,i){1&e&&$e("click",function(){return i._toggle()})("keydown",function(s){return i._keydown(s)}),2&e&&(wt("id",i.panel._headerId)("tabindex",i.tabIndex)("aria-controls",i._getPanelId())("aria-expanded",i._isExpanded())("aria-disabled",i.panel.disabled),Hi("height",i._getHeaderHeight()),At("mat-expanded",i._isExpanded())("mat-expansion-toggle-indicator-after","after"===i._getTogglePosition())("mat-expansion-toggle-indicator-before","before"===i._getTogglePosition())("_mat-animation-noopable","NoopAnimations"===i._animationMode))},inputs:{tabIndex:"tabIndex",expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight"},features:[Le],ngContentSelectors:Dq,decls:5,vars:1,consts:[[1,"mat-content"],["class","mat-expansion-indicator",4,"ngIf"],[1,"mat-expansion-indicator"]],template:function(e,i){1&e&&(Fn(Cq),fe(0,"span",0),Tt(1),Tt(2,1),Tt(3,2),we(),it(4,wq,1,1,"span",1)),2&e&&(Ee(4),Ae("ngIf",i._showToggle()))},dependencies:[zi],styles:['.mat-expansion-panel-header{display:flex;flex-direction:row;align-items:center;padding:0 24px;border-radius:inherit;transition:height 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header._mat-animation-noopable{transition:none}.mat-expansion-panel-header:focus,.mat-expansion-panel-header:hover{outline:none}.mat-expansion-panel-header.mat-expanded:focus,.mat-expansion-panel-header.mat-expanded:hover{background:inherit}.mat-expansion-panel-header:not([aria-disabled=true]){cursor:pointer}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before{flex-direction:row-reverse}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 16px 0 0}[dir=rtl] .mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 0 0 16px}.mat-content{display:flex;flex:1;flex-direction:row;overflow:hidden}.mat-expansion-panel-header-title,.mat-expansion-panel-header-description{display:flex;flex-grow:1;margin-right:16px;align-items:center}[dir=rtl] .mat-expansion-panel-header-title,[dir=rtl] .mat-expansion-panel-header-description{margin-right:0;margin-left:16px}.mat-expansion-panel-header-description{flex-grow:2}.mat-expansion-indicator::after{border-style:solid;border-width:0 2px 2px 0;content:"";display:inline-block;padding:3px;transform:rotate(45deg);vertical-align:middle}.cdk-high-contrast-active .mat-expansion-panel .mat-expansion-panel-header.cdk-keyboard-focused:not([aria-disabled=true])::before,.cdk-high-contrast-active .mat-expansion-panel .mat-expansion-panel-header.cdk-program-focused:not([aria-disabled=true])::before,.cdk-high-contrast-active .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover:not([aria-disabled=true])::before{top:0;left:0;right:0;bottom:0;position:absolute;box-sizing:border-box;pointer-events:none;border:3px solid;border-radius:4px;content:""}.cdk-high-contrast-active .mat-expansion-panel-content{border-top:1px solid;border-top-left-radius:0;border-top-right-radius:0}'],encapsulation:2,data:{animation:[hA.indicatorRotate]},changeDetection:0}),n})(),mA=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]}),n})(),gA=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]}),n})(),_A=(()=>{class n extends fq{constructor(){super(...arguments),this._ownHeaders=new ma,this._hideToggle=!1,this.displayMode="default",this.togglePosition="after"}get hideToggle(){return this._hideToggle}set hideToggle(e){this._hideToggle=rt(e)}ngAfterContentInit(){this._headers.changes.pipe(Qn(this._headers)).subscribe(e=>{this._ownHeaders.reset(e.filter(i=>i.panel.accordion===this)),this._ownHeaders.notifyOnChanges()}),this._keyManager=new Wu(this._ownHeaders).withWrap().withHomeAndEnd()}_handleHeaderKeydown(e){this._keyManager.onKeydown(e)}_handleHeaderFocus(e){this._keyManager.updateActiveItem(e)}ngOnDestroy(){super.ngOnDestroy(),this._ownHeaders.destroy()}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275dir=Me({type:n,selectors:[["mat-accordion"]],contentQueries:function(e,i,r){if(1&e&&It(r,Qv,5),2&e){let s;Ge(s=We())&&(i._headers=s)}},hostAttrs:[1,"mat-accordion"],hostVars:2,hostBindings:function(e,i){2&e&&At("mat-accordion-multi",i.multi)},inputs:{multi:"multi",hideToggle:"hideToggle",displayMode:"displayMode",togglePosition:"togglePosition"},exportAs:["matAccordion"],features:[Xe([{provide:Yv,useExisting:n}]),Le]}),n})(),kq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,gq,Os]}),n})();function Tq(n,t){if(1&n&&(fe(0,"mat-chip-list",5)(1,"mat-chip",6),Ue(2),we()()),2&n){const e=lt().$implicit;Ee(1),Ae("ngClass",e.response.ok?"ok-chip":"bad-chip"),Ee(1),El("",e.response.status,": ",e.response.statusText,"")}}function Aq(n,t){if(1&n&&(fe(0,"pre"),Ue(1),Jr(2,"json"),we()),2&n){const e=lt().$implicit;Ee(1),Kn(so(2,1,e.response.body))}}function Iq(n,t){if(1&n&&(fe(0,"pre"),Ue(1),Jr(2,"json"),we()),2&n){const e=lt().$implicit;Ee(1),Kn(so(2,1,e.response.error))}}function Rq(n,t){if(1&n&&(fe(0,"mat-expansion-panel")(1,"mat-expansion-panel-header")(2,"mat-panel-title")(3,"mat-chip-list",1)(4,"mat-chip",2),Ue(5),we()()(),fe(6,"mat-panel-description")(7,"span"),Ue(8),we()(),it(9,Tq,3,3,"mat-chip-list",3),we(),it(10,Aq,3,3,"pre",4),it(11,Iq,3,3,"pre",4),we()),2&n){const e=t.$implicit;Ee(4),Ae("ngClass","GET"===e.request.method?"request-get":"POST"===e.request.method?"request-post":""),Ee(1),Kn(e.request.method),Ee(3),Kn(e.request.url),Ee(1),Ae("ngIf",void 0!==e.response),Ee(1),Ae("ngIf",void 0!==e.response&&void 0!==e.response.body),Ee(1),Ae("ngIf",void 0!==e.response&&void 0!==e.response.error)}}let Pq=(()=>{class n{constructor(e){this.data=e}ngOnInit(){}ngOnDestroy(){}}return n.\u0275fac=function(e){return new(e||n)(x(Or))},n.\u0275cmp=vt({type:n,selectors:[["app-api-log"]],decls:2,vars:1,consts:[[4,"ngFor","ngForOf"],["selectable","false"],[1,"request-method",3,"ngClass"],["class","response-chips","selectable","false",4,"ngIf"],[4,"ngIf"],["selectable","false",1,"response-chips"],[3,"ngClass"]],template:function(e,i){1&e&&(fe(0,"mat-accordion"),it(1,Rq,12,6,"mat-expansion-panel",0),we()),2&e&&(Ee(1),Ae("ngForOf",i.data.apiLog))},dependencies:[eg,ao,zi,uh,Ia,_A,Kv,Qv,gA,mA,ru],styles:[".mat-expansion-panel-header-title[_ngcontent-%COMP%]{flex-grow:0}.mat-expansion-panel-header-description[_ngcontent-%COMP%]{text-align:left}.response-chips[_ngcontent-%COMP%]{margin-right:20px;flex:none}.request-method[_ngcontent-%COMP%]{width:60px;margin-right:10px;flex:none}.request-post[_ngcontent-%COMP%]{background-color:#0288d1;color:#fff}.request-get[_ngcontent-%COMP%]{background-color:#00838f;color:#fff;flex:none}.ok-chip[_ngcontent-%COMP%]{background-color:#09af00;color:#fff}.bad-chip[_ngcontent-%COMP%]{background-color:#c62828;color:#fff}pre[_ngcontent-%COMP%]{overflow-x:auto}"]}),n})();function Oq(n,t){if(1&n&&(fe(0,"mat-chip")(1,"mat-icon"),Ue(2),we(),fe(3,"span"),Ue(4),Jr(5,"number"),we()()),2&n){const e=t.$implicit,i=lt(2);Ee(2),Ln(" ",i.labelToIcon(e.detection.label)," "),Ee(2),Ln("",vm(5,2,100*e.detection.confidence,"2.0-0"),"%")}}function Fq(n,t){if(1&n&&(fe(0,"div")(1,"h3"),Ue(2),we(),fe(3,"div")(4,"mat-chip-list",1),it(5,Oq,6,5,"mat-chip",2),we()(),fe(6,"pre"),Ue(7),Jr(8,"json"),we()()),2&n){const e=lt();Ee(2),Ln("",e.eventService.eventCount," Total Events"),Ee(3),Ae("ngForOf",e.eventService.lastEvent.objects),Ee(2),Kn(so(8,3,e.eventService.lastEvent))}}let Lq=(()=>{class n{constructor(e,i){this.data=e,this.eventService=i}ngOnInit(){}ngOnDestroy(){}labelToIcon(e){switch(e){case"vehicle":return"directions_car";case"bicycle":return"pedal_bike";default:return e}}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-inference-events"]],decls:1,vars:1,consts:[[4,"ngIf"],["selectable","false"],[4,"ngFor","ngForOf"]],template:function(e,i){1&e&&it(0,Fq,9,5,"div",0),2&e&&Ae("ngIf",void 0!==i.eventService.lastEvent)},dependencies:[ao,zi,uh,Ia,Eh,ru,ng]}),n})();function Nq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",e.name),Ee(1),Ln(" ",e.name," ")}}function Bq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",e.Token),Ee(1),sm(" ",e.Token," (",e.VideoEncoderConfiguration.Resolution.Width,"x",e.VideoEncoderConfiguration.Resolution.Height," ",e.VideoEncoderConfiguration.Encoding," @ ",e.VideoEncoderConfiguration.RateControl.FrameRateLimit," fps) ")}}function Vq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select a video stream"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.selectedProfile=r)})("valueChange",function(r){return Bn(e),Vn(lt().profileSelectionChanged(r))}),it(5,Bq,2,6,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.selectedProfile),Ee(1),Ae("ngForOf",e.data.profiles)}}function Hq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",t.index),Ee(1),Kn(e.PixelFormat)}}function jq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select image format (optional)"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.inputPixelFormat=r)})("valueChange",function(r){return Bn(e),Vn(lt().pixelSelectionChanged(r))}),it(5,Hq,2,2,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.inputPixelFormat),Ee(1),Ae("ngForOf",e.data.imageFormats)}}function Uq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",t.index),Ee(1),El(" ",e.Size.MaxWidth,"x",e.Size.MaxHeight," ")}}function zq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select image resolution (optional)"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.inputImageSize=r)}),it(5,Uq,2,3,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.inputImageSize),Ee(1),Ae("ngForOf",e.data.imageSizes)}}function $q(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;nm("value","",e.name,"/",e.version,""),Ee(1),El(" ",e.name," - ",e.version," ")}}let Gq=(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.eventService=r}ngOnInit(){this.api.updateCameraList(),this.api.updatePipelinesList()}ngOnDestroy(){}cameraSelectionChanged(e){this.api.updateCameraChanged(e),this.api.refreshPipelineStatus(e,!0)}pixelSelectionChanged(e){this.data.imageSizes=this.data.imageFormats[e].FrameSizes}profileSelectionChanged(e){this.api.updatePresets(this.data.selectedCamera,e)}startPipeline(){const e=this.data.selectedPipeline.split("/");this.data.cameraIsOnvif()?this.api.startOnvifPipeline(this.data.selectedCamera,e[0],e[1],this.data.selectedProfile):this.api.startUSBPipeline(this.data.selectedCamera,e[0],e[1],this.data.getUSBConfig())}shouldDisablePipeline(){return void 0===this.data.selectedCamera||void 0===this.data.selectedProfile&&this.data.cameraIsOnvif()||void 0!==this.data.pipelineMap[this.data.selectedCamera]&&"RUNNING"===this.data.pipelineMap[this.data.selectedCamera].status.state}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-camera-selector"]],decls:17,vars:8,consts:[["appearance","fill"],[3,"value","valueChange"],[3,"value",4,"ngFor","ngForOf"],[4,"ngIf"],["appearance","fill",1,"pipeline-picker"],["mat-raised-button","",1,"start-button",3,"disabled","click"],[3,"value"]],template:function(e,i){1&e&&(fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select a camera"),we(),fe(4,"mat-select",1),$e("valueChange",function(s){return i.data.selectedCamera=s})("valueChange",function(s){return i.cameraSelectionChanged(s)}),it(5,Nq,2,2,"mat-option",2),we()()(),it(6,Vq,6,2,"div",3),it(7,jq,6,2,"div",3),it(8,zq,6,2,"div",3),fe(9,"div")(10,"mat-form-field",4)(11,"mat-label"),Ue(12,"Select a pipeline"),we(),fe(13,"mat-select",1),$e("valueChange",function(s){return i.data.selectedPipeline=s}),it(14,$q,2,4,"mat-option",2),we()(),fe(15,"button",5),$e("click",function(){return i.startPipeline()}),Ue(16," Start Pipeline "),we()()),2&e&&(Ee(4),Ae("value",i.data.selectedCamera),Ee(1),Ae("ngForOf",i.data.cameras),Ee(1),Ae("ngIf",i.data.cameraIsOnvif()),Ee(1),Ae("ngIf",i.data.cameraIsUSB()),Ee(1),Ae("ngIf",i.data.cameraIsUSB()&&void 0!==i.data.inputPixelFormat),Ee(5),Ae("value",i.data.selectedPipeline),Ee(1),Ae("ngForOf",i.data.pipelines),Ee(1),Ae("disabled",i.shouldDisablePipeline()))},dependencies:[ao,zi,Aa,GS,ch,xk,Y_],styles:["button[_ngcontent-%COMP%]{width:auto;height:auto}.material-icons[_ngcontent-%COMP%]{zoom:2}mat-form-field[_ngcontent-%COMP%]{width:600px}.pipeline-picker[_ngcontent-%COMP%]{width:471px}.start-button[_ngcontent-%COMP%]{margin-left:10px;vertical-align:top;margin-top:10px}.start-button[_ngcontent-%COMP%]:enabled{background-color:#09af00;color:#fff}"]}),n})();function Wq(n,t){if(1&n&&(fe(0,"mat-chip"),Ue(1),Jr(2,"number"),we()),2&n){const e=lt().$implicit;Ee(1),Ln(" ",vm(2,1,e.value.status.avg_fps,"2.0-0")," FPS ")}}function qq(n,t){if(1&n){const e=ki();fe(0,"mat-expansion-panel")(1,"mat-expansion-panel-header")(2,"mat-panel-title")(3,"mat-chip-list",1)(4,"mat-chip"),Ue(5),we()()(),fe(6,"mat-panel-description")(7,"span"),Ue(8),we()(),fe(9,"mat-chip-list",1)(10,"mat-chip"),Ue(11),we(),it(12,Wq,3,4,"mat-chip",2),fe(13,"button",3),$e("click",function(){const s=Bn(e).$implicit;return Vn(lt().api.stopPipeline(s.value.camera,s.value.info.id))}),fe(14,"mat-icon"),Ue(15,"stop"),we()()()(),fe(16,"pre"),Ue(17),Jr(18,"json"),we()()}if(2&n){const e=t.$implicit;Ee(5),Ln(" Pipeline ",e.value.info.id," "),Ee(3),rm("",e.value.camera," - ",e.value.info.name,"/",e.value.info.version,""),Ee(2),om("state-",e.value.status.state,""),Ee(1),Ln(" ",e.value.status.state," "),Ee(1),Ae("ngIf","RUNNING"===e.value.status.state),Ee(5),Kn(so(18,10,e.value))}}let Yq=(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.ref=r}ngOnInit(){}ngOnDestroy(){}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(en))},n.\u0275cmp=vt({type:n,selectors:[["app-all-pipelines"]],decls:3,vars:3,consts:[[4,"ngFor","ngForOf"],["selectable","false"],[4,"ngIf"],["mat-icon-button","","color","warn",1,"stop-button",3,"click"]],template:function(e,i){1&e&&(fe(0,"mat-accordion"),it(1,qq,19,12,"mat-expansion-panel",0),Jr(2,"keyvalue"),we()),2&e&&(Ee(1),Ae("ngForOf",so(2,1,i.data.pipelineMap)))},dependencies:[ao,zi,Aa,uh,Ia,Eh,_A,Kv,Qv,gA,mA,ru,ng,fE],styles:[".state-RUNNING[_ngcontent-%COMP%]{background-color:#09af00;color:#fff}.state-QUEUED[_ngcontent-%COMP%]{background-color:#00838f;color:#fff}.state-ERROR[_ngcontent-%COMP%]{background-color:#c62828;color:#fff}button[_ngcontent-%COMP%]{width:auto;height:auto}.stop-button[_ngcontent-%COMP%]{margin-right:10px}"]}),n})();function Kq(n,t){1&n&&(fe(0,"mat-card")(1,"mat-card-title"),Ue(2,"Running Pipelines"),we(),fe(3,"mat-card-content"),kt(4,"app-all-pipelines"),we()())}function Qq(n,t){if(1&n){const e=ki();fe(0,"button",5),$e("click",function(){return Bn(e),Vn(lt().eventService.pause())}),Ue(1,"Pause Events "),we()}}function Zq(n,t){if(1&n){const e=ki();fe(0,"button",6),$e("click",function(){return Bn(e),Vn(lt().eventService.resume())}),Ue(1,"Stream Events "),we()}}const Xq=[{path:"",redirectTo:"home",pathMatch:"full"},{path:"home",component:(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.eventService=r,this.data.currentPage="home"}ngOnInit(){this.interval=setInterval(()=>{this.api.refreshAllPipelineStatuses()},1e3)}ngOnDestroy(){clearInterval(this.interval)}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-home"]],decls:29,vars:3,consts:[[1,"jumbotron","bg-image-home"],[1,"text-justify"],[4,"ngIf"],["mat-button","","class","pause-events",3,"click",4,"ngIf"],["mat-button","","class","stream-events",3,"click",4,"ngIf"],["mat-button","",1,"pause-events",3,"click"],["mat-button","",1,"stream-events",3,"click"]],template:function(e,i){1&e&&(fe(0,"mat-grid-tile-header")(1,"div",0)(2,"h1"),Ue(3,"Camera Management"),we(),fe(4,"p",1),Ue(5," This is the landing page for the Camera Management Reference Implementation. "),we()(),fe(6,"mat-card")(7,"mat-card-title"),Ue(8,"Camera Position"),we(),fe(9,"mat-card-content"),kt(10,"app-ptz"),we()(),fe(11,"mat-card")(12,"mat-card-title"),Ue(13,"Camera"),we(),fe(14,"mat-card-content"),kt(15,"app-camera-selector"),we()(),it(16,Kq,5,0,"mat-card",2),fe(17,"mat-card")(18,"mat-card-title"),Ue(19,"API Log"),we(),fe(20,"mat-card-content"),kt(21,"app-api-log"),we()(),fe(22,"mat-card")(23,"mat-card-title"),Ue(24," Inference Events "),it(25,Qq,2,0,"button",3),it(26,Zq,2,0,"button",4),we(),fe(27,"mat-card-content"),kt(28,"app-inference-events"),we()()()),2&e&&(Ee(16),Ae("ngIf",null!=i.data.pipelineMap&&i.data.pipelineMap.size>0),Ee(9),Ae("ngIf",!i.eventService.isPaused()),Ee(1),Ae("ngIf",i.eventService.isPaused()))},dependencies:[zi,Aa,Tz,Sz,kz,F$,L$,uq,Pq,Lq,Gq,Yq],styles:[".material-icons[_ngcontent-%COMP%]{font-size:32px;zoom:2}.pause-events[_ngcontent-%COMP%]{margin-left:10px;background-color:#ffbd3a}.stream-events[_ngcontent-%COMP%]{margin-left:10px;background-color:#188729;color:#fff}"]}),n})(),pathMatch:"full"},{path:"**",redirectTo:"home"}];let Jq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rA.forRoot(Xq,{scrollPositionRestoration:"enabled"}),rA]}),n})();function eY(n,t){if(1&n){const e=ki();fe(0,"a",6),$e("click",function(){const s=Bn(e).$implicit;return Vn(lt().data.currentPage=s.page)}),Ue(1),Jr(2,"uppercase"),we()}if(2&n){const e=t.$implicit;Ae("active",lt().data.currentPage==e.page)("routerLink",e.page),Ee(1),Ln(" ",so(2,3,e.caption)," ")}}let tY=(()=>{class n{constructor(e,i){this.data=e,this.bo=i,this.title="Camera Management UI",this.navbarCollapseShow=!1,i.observe("(prefers-color-scheme: dark)").subscribe(r=>{this.useDarkTheme=r.matches})}get useDarkTheme(){return this.darkTheme}set useDarkTheme(e){this.darkTheme=e,e?document.body.classList.add("dark-theme"):document.body.classList.remove("dark-theme")}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(_v))},n.\u0275cmp=vt({type:n,selectors:[["app-root"]],decls:8,vars:3,consts:[["mat-tab-nav-bar","","backgroundColor","primary",1,"mat-elevation-z8"],["routerLink","home",1,"mat-tab-link",3,"click"],["mat-icon-button","","type","button",3,"title","click"],["role","img","aria-hidden","true"],["mat-tab-link","",3,"active","routerLink","click",4,"ngFor","ngForOf"],["role","main"],["mat-tab-link","",3,"active","routerLink","click"]],template:function(e,i){1&e&&(fe(0,"nav",0)(1,"a",1),$e("click",function(){return i.data.currentPage="home"}),we(),fe(2,"button",2),$e("click",function(){return i.useDarkTheme=!i.useDarkTheme}),fe(3,"mat-icon",3),Ue(4),we()(),it(5,eY,3,5,"a",4),we(),fe(6,"main",5),kt(7,"router-outlet"),we()),2&e&&(Ee(2),Td("title","Switch to ",i.useDarkTheme?"light":"dark"," theme"),Ee(2),Ln(" ",i.useDarkTheme?"light_mode":"dark_mode"," "),Ee(1),Ae("ngForOf",i.data.pages))},dependencies:[ao,Aa,Eh,Yk,Kk,Pv,Xh,hE],styles:[".mat-tab-link[_ngcontent-%COMP%]{padding-top:35px;padding-bottom:35px}"]}),n})(),nY=(()=>{class n{constructor(e,i){this.data=e,this.snackbar=i}intercept(e,i){if(e.headers.has(zv))return i.handle(e);let r=new XW(e);for(this.data.apiLog.unshift(r);this.data.apiLog.length>5;)this.data.apiLog.pop();return i.handle(e).pipe(wn(s=>(s instanceof tc&&(r.response=s),s),s=>{s instanceof l_&&(r.response=s,this.snackbar.open(`${s.status} ${s.statusText}\n${s.error.substring(0,60)}...`,"",{duration:2500,panelClass:["mat-toolbar","mat-warn","error-snackbar"]}))}))}}return n.\u0275fac=function(e){return new(e||n)(te(Or),te(B6))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const iY={hostname:window.location.hostname,port:Fr_mqtt_port,path:Fr_mqtt_path};let rY=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n,bootstrap:[tY]}),n.\u0275inj=qe({providers:[{provide:d_,useClass:nY,multi:!0}],imports:[PE,aj,h3,f3,T3,ZU,oh,Az,zz,x8,d$,I$,dh,B$,Q$,W8,h5,hz,j5,K5,c4,Sk,b4,D4,t6,C6,D6,eT,Jq,kk,kq,oq.forRoot(iY)]}),n})();(function UN(){FD=!1})(),KV().bootstrapModule(rY).catch(n=>console.error(n))},841:(js,Wa,ps)=>{js.exports=function V(X,re,T){function S(m,y){if(!re[m]){if(!X[m]){if(R)return R(m,!0);var _=new Error("Cannot find module '"+m+"'");throw _.code="MODULE_NOT_FOUND",_}var I=re[m]={exports:{}};X[m][0].call(I.exports,function(z){return S(X[m][1][z]||z)},I,I.exports,V,X,re,T)}return re[m].exports}for(var R=void 0,D=0;D0?Q-4:Q;for(Y=0;Y>16&255,oe[de++]=F>>8&255,oe[de++]=255&F;return 2===G&&(F=S[O.charCodeAt(Y)]<<2|S[O.charCodeAt(Y+1)]>>4,oe[de++]=255&F),1===G&&(F=S[O.charCodeAt(Y)]<<10|S[O.charCodeAt(Y+1)]<<4|S[O.charCodeAt(Y+2)]>>2,oe[de++]=F>>8&255,oe[de++]=255&F),oe},re.fromByteArray=function M(O){for(var F,B=O.length,Q=B%3,G=[],de=0,le=B-Q;dele?le:de+16383));return 1===Q?G.push(T[(F=O[B-1])>>2]+T[F<<4&63]+"=="):2===Q&&G.push(T[(F=(O[B-2]<<8)+O[B-1])>>10]+T[F>>4&63]+T[F<<2&63]+"="),G.join("")};for(var T=[],S=[],R="undefined"!=typeof Uint8Array?Uint8Array:Array,D="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",m=0,y=D.length;m0)throw new Error("Invalid string. Length must be a multiple of 4");var B=O.indexOf("=");return-1===B&&(B=F),[B,B===F?0:4-B%4]}function C(O){return T[O>>18&63]+T[O>>12&63]+T[O>>6&63]+T[63&O]}function P(O,F,B){for(var G=[],oe=F;oeD)throw new RangeError('The value "'+h+'" is invalid for option "size"');var u=new Uint8Array(h);return u.__proto__=v.prototype,u}function v(h,u,p){if("number"==typeof h){if("string"==typeof u)throw new TypeError('The "string" argument must be of type string. Received type number');return C(h)}return _(h,u,p)}function _(h,u,p){if("string"==typeof h)return function P(h,u){if(("string"!=typeof u||""===u)&&(u="utf8"),!v.isEncoding(u))throw new TypeError("Unknown encoding: "+u);var p=0|G(h,u),L=y(p),Z=L.write(h,u);return Z!==p&&(L=L.slice(0,Z)),L}(h,u);if(ArrayBuffer.isView(h))return M(h);if(null==h)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof h);if(ne(h,ArrayBuffer)||h&&ne(h.buffer,ArrayBuffer))return function O(h,u,p){if(u<0||h.byteLength=D)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+D.toString(16)+" bytes");return 0|h}function G(h,u){if(v.isBuffer(h))return h.length;if(ArrayBuffer.isView(h)||ne(h,ArrayBuffer))return h.byteLength;if("string"!=typeof h)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof h);var p=h.length,L=arguments.length>2&&!0===arguments[2];if(!L&&0===p)return 0;for(var Z=!1;;)switch(u){case"ascii":case"latin1":case"binary":return p;case"utf8":case"utf-8":return Re(h).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*p;case"hex":return p>>>1;case"base64":return b(h).length;default:if(Z)return L?-1:Re(h).length;u=(""+u).toLowerCase(),Z=!0}}function oe(h,u,p){var L=!1;if((void 0===u||u<0)&&(u=0),u>this.length||((void 0===p||p>this.length)&&(p=this.length),p<=0)||(p>>>=0)<=(u>>>=0))return"";for(h||(h="utf8");;)switch(h){case"hex":return Pe(this,u,p);case"utf8":case"utf-8":return ge(this,u,p);case"ascii":return Ye(this,u,p);case"latin1":case"binary":return Ne(this,u,p);case"base64":return Ce(this,u,p);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _e(this,u,p);default:if(L)throw new TypeError("Unknown encoding: "+h);h=(h+"").toLowerCase(),L=!0}}function de(h,u,p){var L=h[u];h[u]=h[p],h[p]=L}function le(h,u,p,L,Z){if(0===h.length)return-1;if("string"==typeof p?(L=p,p=0):p>2147483647?p=2147483647:p<-2147483648&&(p=-2147483648),A(p=+p)&&(p=Z?0:h.length-1),p<0&&(p=h.length+p),p>=h.length){if(Z)return-1;p=h.length-1}else if(p<0){if(!Z)return-1;p=0}if("string"==typeof u&&(u=v.from(u,L)),v.isBuffer(u))return 0===u.length?-1:Y(h,u,p,L,Z);if("number"==typeof u)return u&=255,"function"==typeof Uint8Array.prototype.indexOf?Z?Uint8Array.prototype.indexOf.call(h,u,p):Uint8Array.prototype.lastIndexOf.call(h,u,p):Y(h,[u],p,L,Z);throw new TypeError("val must be string, number or Buffer")}function Y(h,u,p,L,Z){var Vt,me=1,Se=h.length,Ze=u.length;if(void 0!==L&&("ucs2"===(L=String(L).toLowerCase())||"ucs-2"===L||"utf16le"===L||"utf-16le"===L)){if(h.length<2||u.length<2)return-1;me=2,Se/=2,Ze/=2,p/=2}function yt(_i,Oi){return 1===me?_i[Oi]:_i.readUInt16BE(Oi*me)}if(Z){var nn=-1;for(Vt=p;VtSe&&(p=Se-Ze),Vt=p;Vt>=0;Vt--){for(var Bt=!0,zn=0;znZ&&(L=Z):L=Z;var me=u.length;L>me/2&&(L=me/2);for(var Se=0;Se>8,me.push(p%256),me.push(L);return me}(u,h.length-p),h,p,L)}function Ce(h,u,p){return S.fromByteArray(0===u&&p===h.length?h:h.slice(u,p))}function ge(h,u,p){p=Math.min(h.length,p);for(var L=[],Z=u;Z239?4:me>223?3:me>191?2:1;if(Z+Ze<=p)switch(Ze){case 1:me<128&&(Se=me);break;case 2:128==(192&(yt=h[Z+1]))&&(Bt=(31&me)<<6|63&yt)>127&&(Se=Bt);break;case 3:Vt=h[Z+2],128==(192&(yt=h[Z+1]))&&128==(192&Vt)&&(Bt=(15&me)<<12|(63&yt)<<6|63&Vt)>2047&&(Bt<55296||Bt>57343)&&(Se=Bt);break;case 4:Vt=h[Z+2],nn=h[Z+3],128==(192&(yt=h[Z+1]))&&128==(192&Vt)&&128==(192&nn)&&(Bt=(15&me)<<18|(63&yt)<<12|(63&Vt)<<6|63&nn)>65535&&Bt<1114112&&(Se=Bt)}null===Se?(Se=65533,Ze=1):Se>65535&&(L.push((Se-=65536)>>>10&1023|55296),Se=56320|1023&Se),L.push(Se),Z+=Ze}return function ue(h){var u=h.length;if(u<=4096)return String.fromCharCode.apply(String,h);for(var p="",L=0;Lp&&(u+=" ... "),""},v.prototype.compare=function(u,p,L,Z,me){if(ne(u,Uint8Array)&&(u=v.from(u,u.offset,u.byteLength)),!v.isBuffer(u))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof u);if(void 0===p&&(p=0),void 0===L&&(L=u?u.length:0),void 0===Z&&(Z=0),void 0===me&&(me=this.length),p<0||L>u.length||Z<0||me>this.length)throw new RangeError("out of range index");if(Z>=me&&p>=L)return 0;if(Z>=me)return-1;if(p>=L)return 1;if(this===u)return 0;for(var Se=(me>>>=0)-(Z>>>=0),Ze=(L>>>=0)-(p>>>=0),yt=Math.min(Se,Ze),Vt=this.slice(Z,me),nn=u.slice(p,L),Bt=0;Bt>>=0,isFinite(L)?(L>>>=0,void 0===Z&&(Z="utf8")):(Z=L,L=void 0)}var me=this.length-p;if((void 0===L||L>me)&&(L=me),u.length>0&&(L<0||p<0)||p>this.length)throw new RangeError("Attempt to write outside buffer bounds");Z||(Z="utf8");for(var Se=!1;;)switch(Z){case"hex":return H(this,u,p,L);case"utf8":case"utf-8":return N(this,u,p,L);case"ascii":return E(this,u,p,L);case"latin1":case"binary":return se(this,u,p,L);case"base64":return J(this,u,p,L);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return pe(this,u,p,L);default:if(Se)throw new TypeError("Unknown encoding: "+Z);Z=(""+Z).toLowerCase(),Se=!0}},v.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Ye(h,u,p){var L="";p=Math.min(h.length,p);for(var Z=u;ZL)&&(p=L);for(var Z="",me=u;mep)throw new RangeError("Trying to access beyond buffer length")}function U(h,u,p,L,Z,me){if(!v.isBuffer(h))throw new TypeError('"buffer" argument must be a Buffer instance');if(u>Z||uh.length)throw new RangeError("Index out of range")}function ee(h,u,p,L,Z,me){if(p+L>h.length)throw new RangeError("Index out of range");if(p<0)throw new RangeError("Index out of range")}function be(h,u,p,L,Z){return u=+u,p>>>=0,Z||ee(h,0,p,4),R.write(h,u,p,L,23,4),p+4}function xe(h,u,p,L,Z){return u=+u,p>>>=0,Z||ee(h,0,p,8),R.write(h,u,p,L,52,8),p+8}v.prototype.slice=function(u,p){var L=this.length;(u=~~u)<0?(u+=L)<0&&(u=0):u>L&&(u=L),(p=void 0===p?L:~~p)<0?(p+=L)<0&&(p=0):p>L&&(p=L),p>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u],me=1,Se=0;++Se>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u+--p],me=1;p>0&&(me*=256);)Z+=this[u+--p]*me;return Z},v.prototype.readUInt8=function(u,p){return u>>>=0,p||ve(u,1,this.length),this[u]},v.prototype.readUInt16LE=function(u,p){return u>>>=0,p||ve(u,2,this.length),this[u]|this[u+1]<<8},v.prototype.readUInt16BE=function(u,p){return u>>>=0,p||ve(u,2,this.length),this[u]<<8|this[u+1]},v.prototype.readUInt32LE=function(u,p){return u>>>=0,p||ve(u,4,this.length),(this[u]|this[u+1]<<8|this[u+2]<<16)+16777216*this[u+3]},v.prototype.readUInt32BE=function(u,p){return u>>>=0,p||ve(u,4,this.length),16777216*this[u]+(this[u+1]<<16|this[u+2]<<8|this[u+3])},v.prototype.readIntLE=function(u,p,L){u>>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u],me=1,Se=0;++Se=(me*=128)&&(Z-=Math.pow(2,8*p)),Z},v.prototype.readIntBE=function(u,p,L){u>>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=p,me=1,Se=this[u+--Z];Z>0&&(me*=256);)Se+=this[u+--Z]*me;return Se>=(me*=128)&&(Se-=Math.pow(2,8*p)),Se},v.prototype.readInt8=function(u,p){return u>>>=0,p||ve(u,1,this.length),128&this[u]?-1*(255-this[u]+1):this[u]},v.prototype.readInt16LE=function(u,p){u>>>=0,p||ve(u,2,this.length);var L=this[u]|this[u+1]<<8;return 32768&L?4294901760|L:L},v.prototype.readInt16BE=function(u,p){u>>>=0,p||ve(u,2,this.length);var L=this[u+1]|this[u]<<8;return 32768&L?4294901760|L:L},v.prototype.readInt32LE=function(u,p){return u>>>=0,p||ve(u,4,this.length),this[u]|this[u+1]<<8|this[u+2]<<16|this[u+3]<<24},v.prototype.readInt32BE=function(u,p){return u>>>=0,p||ve(u,4,this.length),this[u]<<24|this[u+1]<<16|this[u+2]<<8|this[u+3]},v.prototype.readFloatLE=function(u,p){return u>>>=0,p||ve(u,4,this.length),R.read(this,u,!0,23,4)},v.prototype.readFloatBE=function(u,p){return u>>>=0,p||ve(u,4,this.length),R.read(this,u,!1,23,4)},v.prototype.readDoubleLE=function(u,p){return u>>>=0,p||ve(u,8,this.length),R.read(this,u,!0,52,8)},v.prototype.readDoubleBE=function(u,p){return u>>>=0,p||ve(u,8,this.length),R.read(this,u,!1,52,8)},v.prototype.writeUIntLE=function(u,p,L,Z){u=+u,p>>>=0,L>>>=0,Z||U(this,u,p,L,Math.pow(2,8*L)-1,0);var Se=1,Ze=0;for(this[p]=255&u;++Ze>>=0,L>>>=0,Z||U(this,u,p,L,Math.pow(2,8*L)-1,0);var Se=L-1,Ze=1;for(this[p+Se]=255&u;--Se>=0&&(Ze*=256);)this[p+Se]=u/Ze&255;return p+L},v.prototype.writeUInt8=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,1,255,0),this[p]=255&u,p+1},v.prototype.writeUInt16LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,65535,0),this[p]=255&u,this[p+1]=u>>>8,p+2},v.prototype.writeUInt16BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,65535,0),this[p]=u>>>8,this[p+1]=255&u,p+2},v.prototype.writeUInt32LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,4294967295,0),this[p+3]=u>>>24,this[p+2]=u>>>16,this[p+1]=u>>>8,this[p]=255&u,p+4},v.prototype.writeUInt32BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,4294967295,0),this[p]=u>>>24,this[p+1]=u>>>16,this[p+2]=u>>>8,this[p+3]=255&u,p+4},v.prototype.writeIntLE=function(u,p,L,Z){if(u=+u,p>>>=0,!Z){var me=Math.pow(2,8*L-1);U(this,u,p,L,me-1,-me)}var Se=0,Ze=1,yt=0;for(this[p]=255&u;++Se>0)-yt&255;return p+L},v.prototype.writeIntBE=function(u,p,L,Z){if(u=+u,p>>>=0,!Z){var me=Math.pow(2,8*L-1);U(this,u,p,L,me-1,-me)}var Se=L-1,Ze=1,yt=0;for(this[p+Se]=255&u;--Se>=0&&(Ze*=256);)u<0&&0===yt&&0!==this[p+Se+1]&&(yt=1),this[p+Se]=(u/Ze>>0)-yt&255;return p+L},v.prototype.writeInt8=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,1,127,-128),u<0&&(u=255+u+1),this[p]=255&u,p+1},v.prototype.writeInt16LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,32767,-32768),this[p]=255&u,this[p+1]=u>>>8,p+2},v.prototype.writeInt16BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,32767,-32768),this[p]=u>>>8,this[p+1]=255&u,p+2},v.prototype.writeInt32LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,2147483647,-2147483648),this[p]=255&u,this[p+1]=u>>>8,this[p+2]=u>>>16,this[p+3]=u>>>24,p+4},v.prototype.writeInt32BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,2147483647,-2147483648),u<0&&(u=4294967295+u+1),this[p]=u>>>24,this[p+1]=u>>>16,this[p+2]=u>>>8,this[p+3]=255&u,p+4},v.prototype.writeFloatLE=function(u,p,L){return be(this,u,p,!0,L)},v.prototype.writeFloatBE=function(u,p,L){return be(this,u,p,!1,L)},v.prototype.writeDoubleLE=function(u,p,L){return xe(this,u,p,!0,L)},v.prototype.writeDoubleBE=function(u,p,L){return xe(this,u,p,!1,L)},v.prototype.copy=function(u,p,L,Z){if(!v.isBuffer(u))throw new TypeError("argument should be a Buffer");if(L||(L=0),!Z&&0!==Z&&(Z=this.length),p>=u.length&&(p=u.length),p||(p=0),Z>0&&Z=this.length)throw new RangeError("Index out of range");if(Z<0)throw new RangeError("sourceEnd out of bounds");Z>this.length&&(Z=this.length),u.length-p=0;--Se)u[Se+p]=this[Se+L];else Uint8Array.prototype.set.call(u,this.subarray(L,Z),p);return me},v.prototype.fill=function(u,p,L,Z){if("string"==typeof u){if("string"==typeof p?(Z=p,p=0,L=this.length):"string"==typeof L&&(Z=L,L=this.length),void 0!==Z&&"string"!=typeof Z)throw new TypeError("encoding must be a string");if("string"==typeof Z&&!v.isEncoding(Z))throw new TypeError("Unknown encoding: "+Z);if(1===u.length){var me=u.charCodeAt(0);("utf8"===Z&&me<128||"latin1"===Z)&&(u=me)}}else"number"==typeof u&&(u&=255);if(p<0||this.length>>=0,L=void 0===L?this.length:L>>>0,u||(u=0),"number"==typeof u)for(Se=p;Se55295&&p<57344){if(!Z){if(p>56319){(u-=3)>-1&&me.push(239,191,189);continue}if(Se+1===L){(u-=3)>-1&&me.push(239,191,189);continue}Z=p;continue}if(p<56320){(u-=3)>-1&&me.push(239,191,189),Z=p;continue}p=65536+(Z-55296<<10|p-56320)}else Z&&(u-=3)>-1&&me.push(239,191,189);if(Z=null,p<128){if((u-=1)<0)break;me.push(p)}else if(p<2048){if((u-=2)<0)break;me.push(p>>6|192,63&p|128)}else if(p<65536){if((u-=3)<0)break;me.push(p>>12|224,p>>6&63|128,63&p|128)}else{if(!(p<1114112))throw new Error("Invalid code point");if((u-=4)<0)break;me.push(p>>18|240,p>>12&63|128,p>>6&63|128,63&p|128)}}return me}function b(h){return S.toByteArray(function $(h){if((h=(h=h.split("=")[0]).trim().replace(ie,"")).length<2)return"";for(;h.length%4!=0;)h+="=";return h}(h))}function q(h,u,p,L){for(var Z=0;Z=u.length||Z>=h.length);++Z)u[Z+p]=h[Z];return Z}function ne(h,u){return h instanceof u||null!=h&&null!=h.constructor&&null!=h.constructor.name&&h.constructor.name===u.name}function A(h){return h!=h}}).call(this)}).call(this,V("buffer").Buffer)},{"base64-js":1,buffer:3,ieee754:5}],4:[function(V,X,re){"use strict";var R,T="object"==typeof Reflect?Reflect:null,S=T&&"function"==typeof T.apply?T.apply:function(Y,H,N){return Function.prototype.apply.call(Y,H,N)};R=T&&"function"==typeof T.ownKeys?T.ownKeys:Object.getOwnPropertySymbols?function(Y){return Object.getOwnPropertyNames(Y).concat(Object.getOwnPropertySymbols(Y))}:function(Y){return Object.getOwnPropertyNames(Y)};var m=Number.isNaN||function(Y){return Y!=Y};function y(){y.init.call(this)}X.exports=y,X.exports.once=function G(le,Y){return new Promise(function(H,N){function E(J){le.removeListener(Y,se),N(J)}function se(){"function"==typeof le.removeListener&&le.removeListener("error",E),H([].slice.call(arguments))}de(le,Y,se,{once:!0}),"error"!==Y&&function oe(le,Y,H){"function"==typeof le.on&&de(le,"error",Y,H)}(le,E,{once:!0})})},y.EventEmitter=y,y.prototype._events=void 0,y.prototype._eventsCount=0,y.prototype._maxListeners=void 0;var v=10;function _(le){if("function"!=typeof le)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof le)}function I(le){return void 0===le._maxListeners?y.defaultMaxListeners:le._maxListeners}function z(le,Y,H,N){var E,se,J;if(_(H),void 0===(se=le._events)?(se=le._events=Object.create(null),le._eventsCount=0):(void 0!==se.newListener&&(le.emit("newListener",Y,H.listener?H.listener:H),se=le._events),J=se[Y]),void 0===J)J=se[Y]=H,++le._eventsCount;else if("function"==typeof J?J=se[Y]=N?[H,J]:[J,H]:N?J.unshift(H):J.push(H),(E=I(le))>0&&J.length>E&&!J.warned){J.warned=!0;var pe=new Error("Possible EventEmitter memory leak detected. "+J.length+" "+String(Y)+" listeners added. Use emitter.setMaxListeners() to increase limit");pe.name="MaxListenersExceededWarning",pe.emitter=le,pe.type=Y,pe.count=J.length,function D(le){console&&console.warn&&console.warn(le)}(pe)}return le}function C(){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(le,Y,H){var N={fired:!1,wrapFn:void 0,target:le,type:Y,listener:H},E=C.bind(N);return E.listener=H,N.wrapFn=E,E}function M(le,Y,H){var N=le._events;if(void 0===N)return[];var E=N[Y];return void 0===E?[]:"function"==typeof E?H?[E.listener||E]:[E]:H?function Q(le){for(var Y=new Array(le.length),H=0;H0&&(J=H[0]),J instanceof Error)throw J;var pe=new Error("Unhandled error."+(J?" ("+J.message+")":""));throw pe.context=J,pe}var Ce=se[Y];if(void 0===Ce)return!1;if("function"==typeof Ce)S(Ce,this,H);else{var ge=Ce.length,Fe=F(Ce,ge);for(N=0;N=0;J--)if(N[J]===H||N[J].listener===H){pe=N[J].listener,se=J;break}if(se<0)return this;0===se?N.shift():function B(le,Y){for(;Y+1=0;E--)this.removeListener(Y,H[E]);return this},y.prototype.listeners=function(Y){return M(this,Y,!0)},y.prototype.rawListeners=function(Y){return M(this,Y,!1)},y.listenerCount=function(le,Y){return"function"==typeof le.listenerCount?le.listenerCount(Y):O.call(le,Y)},y.prototype.listenerCount=O,y.prototype.eventNames=function(){return this._eventsCount>0?R(this._events):[]}},{}],5:[function(V,X,re){re.read=function(T,S,R,D,m){var y,v,_=8*m-D-1,I=(1<<_)-1,z=I>>1,C=-7,P=R?m-1:0,M=R?-1:1,O=T[S+P];for(P+=M,y=O&(1<<-C)-1,O>>=-C,C+=_;C>0;y=256*y+T[S+P],P+=M,C-=8);for(v=y&(1<<-C)-1,y>>=-C,C+=D;C>0;v=256*v+T[S+P],P+=M,C-=8);if(0===y)y=1-z;else{if(y===I)return v?NaN:1/0*(O?-1:1);v+=Math.pow(2,D),y-=z}return(O?-1:1)*v*Math.pow(2,y-D)},re.write=function(T,S,R,D,m,y){var v,_,I,z=8*y-m-1,C=(1<>1,M=23===m?Math.pow(2,-24)-Math.pow(2,-77):0,O=D?0:y-1,F=D?1:-1,B=S<0||0===S&&1/S<0?1:0;for(S=Math.abs(S),isNaN(S)||S===1/0?(_=isNaN(S)?1:0,v=C):(v=Math.floor(Math.log(S)/Math.LN2),S*(I=Math.pow(2,-v))<1&&(v--,I*=2),(S+=v+P>=1?M/I:M*Math.pow(2,1-P))*I>=2&&(v++,I/=2),v+P>=C?(_=0,v=C):v+P>=1?(_=(S*I-1)*Math.pow(2,m),v+=P):(_=S*Math.pow(2,P-1)*Math.pow(2,m),v=0));m>=8;T[R+O]=255&_,O+=F,_/=256,m-=8);for(v=v<0;T[R+O]=255&v,O+=F,v/=256,z-=8);T[R+O-F]|=128*B}},{}],6:[function(V,X,re){function T(R){return!!R.constructor&&"function"==typeof R.constructor.isBuffer&&R.constructor.isBuffer(R)}X.exports=function(R){return null!=R&&(T(R)||function S(R){return"function"==typeof R.readFloatLE&&"function"==typeof R.slice&&T(R.slice(0,0))}(R)||!!R._isBuffer)}},{}],7:[function(V,X,re){(function(T,S){(function(){"use strict";var R=V("events").EventEmitter,D=V("./store"),m=V("mqtt-packet"),y=V("readable-stream").Writable,v=V("inherits"),_=V("reinterval"),I=V("./validations"),z=V("xtend"),C=V("debug")("mqttjs:client"),P=T?T.nextTick:function(N){setTimeout(N,0)},M=S.setImmediate||function(N){P(N)},O={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0},F=["ECONNREFUSED","EADDRINUSE","ECONNRESET","ENOTFOUND"],B={0:"",1:"Unacceptable protocol version",2:"Identifier rejected",3:"Server unavailable",4:"Bad username or password",5:"Not authorized",16:"No matching subscribers",17:"No subscription existed",128:"Unspecified error",129:"Malformed Packet",130:"Protocol Error",131:"Implementation specific error",132:"Unsupported Protocol Version",133:"Client Identifier not valid",134:"Bad User Name or Password",135:"Not authorized",136:"Server unavailable",137:"Server busy",138:"Banned",139:"Server shutting down",140:"Bad authentication method",141:"Keep Alive timeout",142:"Session taken over",143:"Topic Filter invalid",144:"Topic Name invalid",145:"Packet identifier in use",146:"Packet Identifier not found",147:"Receive Maximum exceeded",148:"Topic Alias invalid",149:"Packet too large",150:"Message rate too high",151:"Quota exceeded",152:"Administrative action",153:"Payload format invalid",154:"Retain not supported",155:"QoS not supported",156:"Use another server",157:"Server moved",158:"Shared Subscriptions not supported",159:"Connection rate exceeded",160:"Maximum connect time",161:"Subscription Identifiers not supported",162:"Wildcard Subscriptions not supported"};function G(N,E,se){C("sendPacket :: packet: %O",E),C("sendPacket :: emitting `packetsend`"),N.emit("packetsend",E),C("sendPacket :: writing to stream");var J=m.writeToStream(E,N.stream,N.options);C("sendPacket :: writeToStream result %s",J),!J&&se?(C("sendPacket :: handle events on `drain` once through callback."),N.stream.once("drain",se)):se&&(C("sendPacket :: invoking cb"),se())}function oe(N){N&&(C("flush: queue exists? %b",!!N),Object.keys(N).forEach(function(E){"function"==typeof N[E].cb&&(N[E].cb(new Error("Connection closed")),delete N[E])}))}function le(N,E,se,J){C("storeAndSend :: store packet with cmd %s to outgoingStore",E.cmd),N.outgoingStore.put(E,function(Ce){if(Ce)return se&&se(Ce);J(),G(N,E,se)})}function Y(N){C("nop ::",N)}function H(N,E){var se,J=this;if(!(this instanceof H))return new H(N,E);for(se in this.options=E||{},O)this.options[se]=void 0===this.options[se]?O[se]:E[se];C("MqttClient :: options.protocol",E.protocol),C("MqttClient :: options.protocolVersion",E.protocolVersion),C("MqttClient :: options.username",E.username),C("MqttClient :: options.keepalive",E.keepalive),C("MqttClient :: options.reconnectPeriod",E.reconnectPeriod),C("MqttClient :: options.rejectUnauthorized",E.rejectUnauthorized),this.options.clientId="string"==typeof E.clientId?E.clientId:function Q(){return"mqttjs_"+Math.random().toString(16).substr(2,8)}(),C("MqttClient :: clientId",this.options.clientId),this.options.customHandleAcks=5===E.protocolVersion&&E.customHandleAcks?E.customHandleAcks:function(){arguments[3](0)},this.streamBuilder=N,this.outgoingStore=E.outgoingStore||new D,this.incomingStore=E.incomingStore||new D,this.queueQoSZero=void 0===E.queueQoSZero||E.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this._storeProcessing=!1,this._packetIdsDuringStoreProcessing={},this.nextId=Math.max(1,Math.floor(65535*Math.random())),this.outgoing={},this._firstConnection=!0,this.on("connect",function(){var pe=this.queue;C("connect :: sending queued packets"),function Ce(){var ge=pe.shift();C("deliver :: entry %o",ge);var Fe=null;!ge||(C("deliver :: call _sendPacket for %o",Fe=ge.packet),J._sendPacket(Fe,function(ue){ge.cb&&ge.cb(ue),Ce()}))}()}),this.on("close",function(){C("close :: connected set to `false`"),this.connected=!1,C("close :: clearing connackTimer"),clearTimeout(this.connackTimer),C("close :: clearing ping timer"),null!==J.pingTimer&&(J.pingTimer.clear(),J.pingTimer=null),C("close :: calling _setupReconnect"),this._setupReconnect()}),R.call(this),C("MqttClient :: setting up stream"),this._setupStream()}v(H,R),H.prototype._setupStream=function(){var N,E=this,se=new y,J=m.parser(this.options),pe=null,Ce=[];function ge(){if(Ce.length)P(Fe);else{var Ne=pe;pe=null,Ne()}}function Fe(){C("work :: getting next packet in queue");var Ne=Ce.shift();if(Ne)C("work :: packet pulled from queue"),E._handlePacket(Ne,ge);else{C("work :: no packets in queue");var Pe=pe;pe=null,C("work :: done flag is %s",!!Pe),Pe&&Pe()}}if(C("_setupStream :: calling method to clear reconnect"),this._clearReconnect(),C("_setupStream :: using streamBuilder provided to client to create stream"),this.stream=this.streamBuilder(this),J.on("packet",function(Ne){C("parser :: on packet push to packets array."),Ce.push(Ne)}),se._write=function(Ne,Pe,_e){pe=_e,C("writable stream :: parsing buffer"),J.parse(Ne),Fe()},C("_setupStream :: pipe stream to writable stream"),this.stream.pipe(se),this.stream.on("error",function ue(Ne){C("streamErrorHandler :: error",Ne.message),F.includes(Ne.code)?(C("streamErrorHandler :: emitting error"),E.emit("error",Ne)):Y(Ne)}),this.stream.on("close",function(){C("(%s)stream :: on close",E.options.clientId),function de(N){N&&(C("flushVolatile :: deleting volatile messages from the queue and setting their callbacks as error function"),Object.keys(N).forEach(function(E){N[E].volatile&&"function"==typeof N[E].cb&&(N[E].cb(new Error("Connection closed")),delete N[E])}))}(E.outgoing),C("stream: emit close to MqttClient"),E.emit("close")}),C("_setupStream: sending packet `connect`"),(N=Object.create(this.options)).cmd="connect",G(this,N),J.on("error",this.emit.bind(this,"error")),this.options.properties){if(!this.options.properties.authenticationMethod&&this.options.properties.authenticationData)return E.end(()=>this.emit("error",new Error("Packet has no Authentication Method"))),this;this.options.properties.authenticationMethod&&this.options.authPacket&&"object"==typeof this.options.authPacket&&G(this,z({cmd:"auth",reasonCode:0},this.options.authPacket))}this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout(function(){C("!!connectTimeout hit!! Calling _cleanUp with force `true`"),E._cleanUp(!0)},this.options.connectTimeout)},H.prototype._handlePacket=function(N,E){var se=this.options;if(5===se.protocolVersion&&se.properties&&se.properties.maximumPacketSize&&se.properties.maximumPacketSizeCe.properties.topicAliasMaximum||!Ce.properties.topicAliasMaximum&&se.properties.topicAlias))&&delete pe.properties.topicAlias),C("publish :: qos",se.qos),se.qos){case 1:case 2:this.outgoing[pe.messageId]={volatile:!1,cb:J||Y},this._storeProcessing?(C("_storeProcessing enabled"),this._packetIdsDuringStoreProcessing[pe.messageId]=!1,this._storePacket(pe,void 0,se.cbStorePut)):(C("MqttClient:publish: packet cmd: %s",pe.cmd),this._sendPacket(pe,void 0,se.cbStorePut));break;default:this._storeProcessing?(C("_storeProcessing enabled"),this._storePacket(pe,J,se.cbStorePut)):(C("MqttClient:publish: packet cmd: %s",pe.cmd),this._sendPacket(pe,J,se.cbStorePut))}return this},H.prototype.subscribe=function(){for(var N,E=new Array(arguments.length),se=0;se0){var U={qos:ve.qos};5===Ne&&(U.nl=ve.nl||!1,U.rap=ve.rap||!1,U.rh=ve.rh||0,U.properties=ve.properties),Ye._resubscribeTopics[ve.topic]=U,_e.push(ve.topic)}}),Ye.messageIdToTopic[N.messageId]=_e}return this.outgoing[N.messageId]={volatile:!0,cb:function(ve,U){if(!ve)for(var ee=U.granted,be=0;be{C("end :: finish :: calling process.nextTick on closeStores"),P(pe.bind(J))},E)}return C("end :: (%s)",this.options.clientId),(null==N||"boolean"!=typeof N)&&(se=E||Y,E=N,N=!1,"object"!=typeof E&&(se=E,E=null,"function"!=typeof se&&(se=Y))),"object"!=typeof E&&(se=E,E=null),C("end :: cb? %s",!!se),se=se||Y,this.disconnecting?(se(),this):(this._clearReconnect(),this.disconnecting=!0,!N&&Object.keys(this.outgoing).length>0?(C("end :: (%s) :: calling finish in 10ms once outgoing is empty",J.options.clientId),this.once("outgoingEmpty",setTimeout.bind(null,Ce,10))):(C("end :: (%s) :: immediately calling finish",J.options.clientId),Ce()),this)},H.prototype.removeOutgoingMessage=function(N){var E=this.outgoing[N]?this.outgoing[N].cb:null;return delete this.outgoing[N],this.outgoingStore.del({messageId:N},function(){E(new Error("Message removed"))}),this},H.prototype.reconnect=function(N){C("client reconnect");var E=this,se=function(){N?(E.options.incomingStore=N.incomingStore,E.options.outgoingStore=N.outgoingStore):(E.options.incomingStore=null,E.options.outgoingStore=null),E.incomingStore=E.options.incomingStore||new D,E.outgoingStore=E.options.outgoingStore||new D,E.disconnecting=!1,E.disconnected=!1,E._deferredReconnect=null,E._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=se:se(),this},H.prototype._reconnect=function(){C("_reconnect: emitting reconnect to client"),this.emit("reconnect"),this.connected?(this.end(()=>{this._setupStream()}),C("client already connected. disconnecting first.")):(C("_reconnect: calling _setupStream"),this._setupStream())},H.prototype._setupReconnect=function(){var N=this;!N.disconnecting&&!N.reconnectTimer&&N.options.reconnectPeriod>0?(this.reconnecting||(C("_setupReconnect :: emit `offline` state"),this.emit("offline"),C("_setupReconnect :: set `reconnecting` to `true`"),this.reconnecting=!0),C("_setupReconnect :: setting reconnectTimer for %d ms",N.options.reconnectPeriod),N.reconnectTimer=setInterval(function(){C("reconnectTimer :: reconnect triggered!"),N._reconnect()},N.options.reconnectPeriod)):C("_setupReconnect :: doing nothing...")},H.prototype._clearReconnect=function(){C("_clearReconnect : clearing reconnect timer"),this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},H.prototype._cleanUp=function(N,E){var se=arguments[2];if(E&&(C("_cleanUp :: done callback provided for on stream close"),this.stream.on("close",E)),C("_cleanUp :: forced? %s",N),N)0===this.options.reconnectPeriod&&this.options.clean&&oe(this.outgoing),C("_cleanUp :: (%s) :: destroying stream",this.options.clientId),this.stream.destroy();else{var J=z({cmd:"disconnect"},se);C("_cleanUp :: (%s) :: call _sendPacket with disconnect packet",this.options.clientId),this._sendPacket(J,M.bind(null,this.stream.end.bind(this.stream)))}this.disconnecting||(C("_cleanUp :: client not disconnecting. Clearing and resetting reconnect."),this._clearReconnect(),this._setupReconnect()),null!==this.pingTimer&&(C("_cleanUp :: clearing pingTimer"),this.pingTimer.clear(),this.pingTimer=null),E&&!this.connected&&(C("_cleanUp :: (%s) :: removing stream `done` callback `close` listener",this.options.clientId),this.stream.removeListener("close",E),E())},H.prototype._sendPacket=function(N,E,se){if(C("_sendPacket :: (%s) :: start",this.options.clientId),se=se||Y,!this.connected)return C("_sendPacket :: client not connected. Storing packet offline."),void this._storePacket(N,E,se);switch(this._shiftPingInterval(),N.cmd){case"publish":break;case"pubrel":return void le(this,N,E,se);default:return void G(this,N,E)}switch(N.qos){case 2:case 1:le(this,N,E,se);break;default:G(this,N,E)}C("_sendPacket :: (%s) :: end",this.options.clientId)},H.prototype._storePacket=function(N,E,se){C("_storePacket :: packet: %o",N),C("_storePacket :: cb? %s",!!E),se=se||Y,0===(N.qos||0)&&this.queueQoSZero||"publish"!==N.cmd?this.queue.push({packet:N,cb:E}):N.qos>0?(E=this.outgoing[N.messageId]?this.outgoing[N.messageId].cb:null,this.outgoingStore.put(N,function(J){if(J)return E&&E(J);se()})):E&&E(new Error("No connection to broker"))},H.prototype._setupPingTimer=function(){C("_setupPingTimer :: keepalive %d (seconds)",this.options.keepalive);var N=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=_(function(){N._checkPing()},1e3*this.options.keepalive))},H.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},H.prototype._checkPing=function(){C("_checkPing :: checking ping..."),this.pingResp?(C("_checkPing :: ping response received. Clearing flag and sending `pingreq`"),this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):(C("_checkPing :: calling _cleanUp with force true"),this._cleanUp(!0))},H.prototype._handlePingresp=function(){this.pingResp=!0},H.prototype._handleConnack=function(N){C("_handleConnack");var E=this.options,J=5===E.protocolVersion?N.reasonCode:N.returnCode;if(clearTimeout(this.connackTimer),N.properties&&(N.properties.topicAliasMaximum&&(E.properties||(E.properties={}),E.properties.topicAliasMaximum=N.properties.topicAliasMaximum),N.properties.serverKeepAlive&&E.keepalive&&(E.keepalive=N.properties.serverKeepAlive,this._shiftPingInterval()),N.properties.maximumPacketSize&&(E.properties||(E.properties={}),E.properties.maximumPacketSize=N.properties.maximumPacketSize)),0===J)this.reconnecting=!1,this._onConnect(N);else if(J>0){var pe=new Error("Connection refused: "+B[J]);pe.code=J,this.emit("error",pe)}},H.prototype._handlePublish=function(N,E){C("_handlePublish: packet %o",N),E=void 0!==E?E:Y;var se=N.topic.toString(),J=N.payload,pe=N.qos,Ce=N.messageId,ge=this,Fe=this.options,ue=[0,16,128,131,135,144,145,151,153];switch(C("_handlePublish: qos %d",pe),pe){case 2:Fe.customHandleAcks(se,J,N,function(Ye,Ne){return Ye instanceof Error||(Ne=Ye,Ye=null),Ye?ge.emit("error",Ye):-1===ue.indexOf(Ne)?ge.emit("error",new Error("Wrong reason code for pubrec")):void(Ne?ge._sendPacket({cmd:"pubrec",messageId:Ce,reasonCode:Ne},E):ge.incomingStore.put(N,function(){ge._sendPacket({cmd:"pubrec",messageId:Ce},E)}))});break;case 1:Fe.customHandleAcks(se,J,N,function(Ye,Ne){return Ye instanceof Error||(Ne=Ye,Ye=null),Ye?ge.emit("error",Ye):-1===ue.indexOf(Ne)?ge.emit("error",new Error("Wrong reason code for puback")):(Ne||ge.emit("message",se,J,N),void ge.handleMessage(N,function(Pe){if(Pe)return E&&E(Pe);ge._sendPacket({cmd:"puback",messageId:Ce,reasonCode:Ne},E)}))});break;case 0:this.emit("message",se,J,N),this.handleMessage(N,E);break;default:C("_handlePublish: unknown QoS. Doing nothing.")}},H.prototype.handleMessage=function(N,E){E()},H.prototype._handleAck=function(N){var ge,E=N.messageId,se=N.cmd,J=null,pe=this.outgoing[E]?this.outgoing[E].cb:null,Ce=this;if(pe){switch(C("_handleAck :: packet type",se),se){case"pubcomp":case"puback":var Fe=N.reasonCode;Fe&&Fe>0&&16!==Fe&&((ge=new Error("Publish error: "+B[Fe])).code=Fe,pe(ge,N)),delete this.outgoing[E],this.outgoingStore.del(N,pe);break;case"pubrec":J={cmd:"pubrel",qos:2,messageId:E};var ue=N.reasonCode;ue&&ue>0&&16!==ue?((ge=new Error("Publish error: "+B[ue])).code=ue,pe(ge,N)):this._sendPacket(J);break;case"suback":delete this.outgoing[E];for(var Ye=0;Ye0)if(this.options.resubscribe)if(5===this.options.protocolVersion){C("_resubscribe: protocolVersion 5");for(var se=0;sede&&setTimeout(ue,le,Ne,Pe,_e),Y&&"string"==typeof Ne&&(Ne=S.from(Ne,"utf8"));try{H.send(Ne)}catch(ve){return _e(ve)}_e()},function Ye(Ne){H.close(),Ne()});Q.objectMode||(N._writev=Fe),N.on("close",()=>{H.close()});const E=void 0===H.addEventListener;function J(){G.setReadable(N),G.setWritable(N),G.emit("connect")}function pe(){G.end(),G.destroy()}function Ce(Ne){G.destroy(Ne)}function ge(Ne){let Pe=Ne.data;Pe=Pe instanceof ArrayBuffer?S.from(Pe):S.from(Pe,"utf8"),N.push(Pe)}function Fe(Ne,Pe){const _e=new Array(Ne.length);for(let ve=0;vethis.length||m<0)return;const y=this._offset(m);return this._bufs[y[0]][y[1]]},R.prototype.slice=function(m,y){return"number"==typeof m&&m<0&&(m+=this.length),"number"==typeof y&&y<0&&(y+=this.length),this.copy(null,0,m,y)},R.prototype.copy=function(m,y,v,_){if(("number"!=typeof v||v<0)&&(v=0),("number"!=typeof _||_>this.length)&&(_=this.length),v>=this.length||_<=0)return m||T.alloc(0);const I=!!m,z=this._offset(v),C=_-v;let P=C,M=I&&y||0,O=z[1];if(0===v&&_===this.length){if(!I)return 1===this._bufs.length?this._bufs[0]:T.concat(this._bufs,this.length);for(let F=0;FB)){this._bufs[F].copy(m,M,O,O+P),M+=B;break}this._bufs[F].copy(m,M,O),M+=B,P-=B,O&&(O=0)}return m.length>M?m.slice(0,M):m},R.prototype.shallowSlice=function(m,y){if((m=m||0)<0&&(m+=this.length),(y="number"!=typeof y?this.length:y)<0&&(y+=this.length),m===y)return this._new();const v=this._offset(m),_=this._offset(y),I=this._bufs.slice(v[0],_[0]+1);return 0===_[1]?I.pop():I[I.length-1]=I[I.length-1].slice(0,_[1]),0!==v[1]&&(I[0]=I[0].slice(v[1])),this._new(I)},R.prototype.toString=function(m,y,v){return this.slice(y,v).toString(m)},R.prototype.consume=function(m){if(m=Math.trunc(m),Number.isNaN(m)||m<=0)return this;for(;this._bufs.length;){if(!(m>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(m),this.length-=m;break}m-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},R.prototype.duplicate=function(){const m=this._new();for(let y=0;ythis.length?this.length:m;const v=this._offset(m);let _=v[0],I=v[1];for(;_=D.length){const P=z.indexOf(D,I);if(-1!==P)return this._reverseOffset([_,P]);I=z.length-D.length+1}else{const P=this._reverseOffset([_,I]);if(this._match(P,D))return P;I++}I=0}return-1},R.prototype._match=function(D,m){if(this.length-D{"%%"!==P&&(z++,"%c"===P&&(C=z))}),_.splice(C,0,I)},re.save=function D(_){try{_?re.storage.setItem("debug",_):re.storage.removeItem("debug")}catch(I){}},re.load=function m(){let _;try{_=re.storage.getItem("debug")}catch(I){}return!_&&void 0!==T&&"env"in T&&(_=T.env.DEBUG),_},re.useColors=function S(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},re.storage=function y(){try{return localStorage}catch(_){}}(),re.destroy=(()=>{let _=!1;return()=>{_||(_=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),re.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],re.log=console.debug||console.log||(()=>{}),X.exports=V("./common")(re);const{formatters:v}=X.exports;v.j=function(_){try{return JSON.stringify(_)}catch(I){return"[UnexpectedJSONParseError]: "+I.message}}}).call(this)}).call(this,V("_process"))},{"./common":20,_process:69}],20:[function(V,X,re){X.exports=function T(S){function D(P){let M,O=null;function F(...B){if(!F.enabled)return;const Q=F,G=Number(new Date);Q.diff=G-(M||G),Q.prev=M,Q.curr=G,M=G,B[0]=D.coerce(B[0]),"string"!=typeof B[0]&&B.unshift("%O");let de=0;B[0]=B[0].replace(/%([a-zA-Z%])/g,(Y,H)=>{if("%%"===Y)return"%";de++;const N=D.formatters[H];return"function"==typeof N&&(Y=N.call(Q,B[de]),B.splice(de,1),de--),Y}),D.formatArgs.call(Q,B),(Q.log||D.log).apply(Q,B)}return F.namespace=P,F.useColors=D.useColors(),F.color=D.selectColor(P),F.extend=m,F.destroy=D.destroy,Object.defineProperty(F,"enabled",{enumerable:!0,configurable:!1,get:()=>null===O?D.enabled(P):O,set:B=>{O=B}}),"function"==typeof D.init&&D.init(F),F}function m(P,M){const O=D(this.namespace+(void 0===M?":":M)+P);return O.log=this.log,O}function I(P){return P.toString().substring(2,P.toString().length-2).replace(/\.\*\?$/,"*")}return D.debug=D,D.default=D,D.coerce=function z(P){return P instanceof Error?P.stack||P.message:P},D.disable=function v(){const P=[...D.names.map(I),...D.skips.map(I).map(M=>"-"+M)].join(",");return D.enable(""),P},D.enable=function y(P){let M;D.save(P),D.names=[],D.skips=[];const O=("string"==typeof P?P:"").split(/[\s,]+/),F=O.length;for(M=0;M{D[P]=S[P]}),D.names=[],D.skips=[],D.formatters={},D.selectColor=function R(P){let M=0;for(let O=0;O0?("string"!=typeof b&&!h.objectMode&&Object.getPrototypeOf(b)!==I.prototype&&(b=function C(g){return I.from(g)}(b)),ne?h.endEmitted?g.emit("error",new Error("stream.unshift() after end event")):N(g,h,b,!0):h.ended?g.emit("error",new Error("stream.push() after EOF")):(h.reading=!1,h.decoder&&!q?(b=h.decoder.write(b),h.objectMode||0!==b.length?N(g,h,b,!1):Ye(g,h)):N(g,h,b,!1))):ne||(h.reading=!1)),function se(g){return!g.ended&&(g.needReadable||g.lengthb.highWaterMark&&(b.highWaterMark=function pe(g){return g>=J?g=J:(g--,g|=g>>>1,g|=g>>>2,g|=g>>>4,g|=g>>>8,g|=g>>>16,g++),g}(g)),g<=b.length?g:b.ended?b.length:(b.needReadable=!0,0))}function Fe(g){var b=g._readableState;b.needReadable=!1,b.emittedReadable||(F("emitReadable",b.flowing),b.emittedReadable=!0,b.sync?R.nextTick(ue,g):ue(g))}function ue(g){F("emit readable"),g.emit("readable"),ee(g)}function Ye(g,b){b.readingMore||(b.readingMore=!0,R.nextTick(Ne,g,b))}function Ne(g,b){for(var q=b.length;!b.reading&&!b.flowing&&!b.ended&&b.length=b.length?(q=b.decoder?b.buffer.join(""):1===b.buffer.length?b.buffer.head.data:b.buffer.concat(b.length),b.buffer.clear()):q=function xe(g,b,q){var ne;return gh.length?h.length:g;if(A+=u===h.length?h:h.slice(0,g),0==(g-=u)){u===h.length?(++ne,b.head=q.next?q.next:b.tail=null):(b.head=q,q.data=h.slice(u));break}++ne}return b.length-=ne,A}(g,b):function $(g,b){var q=I.allocUnsafe(g),ne=b.head,A=1;for(ne.data.copy(q),g-=ne.data.length;ne=ne.next;){var h=ne.data,u=g>h.length?h.length:g;if(h.copy(q,q.length-g,0,u),0==(g-=u)){u===h.length?(++A,b.head=ne.next?ne.next:b.tail=null):(b.head=ne,ne.data=h.slice(u));break}++A}return b.length-=A,q}(g,b),ne}(g,b.buffer,b.decoder),q);var q}function ye(g){var b=g._readableState;if(b.length>0)throw new Error('"endReadable()" called on non-empty stream');b.endEmitted||(b.ended=!0,R.nextTick(Re,b,g))}function Re(g,b){!g.endEmitted&&0===g.length&&(g.endEmitted=!0,b.readable=!1,b.emit("end"))}function W(g,b){for(var q=0,ne=g.length;q=b.highWaterMark||b.ended))return F("read: emitReadable",b.length,b.ended),0===b.length&&b.ended?ye(this):Fe(this),null;if(0===(g=Ce(g,b))&&b.ended)return 0===b.length&&ye(this),null;var A,ne=b.needReadable;return F("need readable",ne),(0===b.length||b.length-g0?be(g,b):null)?(b.needReadable=!0,g=0):b.length-=g,0===b.length&&(b.ended||(b.needReadable=!0),q!==g&&b.ended&&ye(this)),null!==A&&this.emit("data",A),A},Y.prototype._read=function(g){this.emit("error",new Error("_read() is not implemented"))},Y.prototype.pipe=function(g,b){var q=this,ne=this._readableState;switch(ne.pipesCount){case 0:ne.pipes=g;break;case 1:ne.pipes=[ne.pipes,g];break;default:ne.pipes.push(g)}ne.pipesCount+=1,F("pipe count=%d opts=%j",ne.pipesCount,b);var h=b&&!1===b.end||g===T.stdout||g===T.stderr?Bt:p;function u(zn,_i){F("onunpipe"),zn===q&&_i&&!1===_i.hasUnpiped&&(_i.hasUnpiped=!0,function me(){F("cleanup"),g.removeListener("close",Vt),g.removeListener("finish",nn),g.removeListener("drain",L),g.removeListener("error",yt),g.removeListener("unpipe",u),q.removeListener("end",p),q.removeListener("end",Bt),q.removeListener("data",Ze),Z=!0,ne.awaitDrain&&(!g._writableState||g._writableState.needDrain)&&L()}())}function p(){F("onend"),g.end()}ne.endEmitted?R.nextTick(h):q.once("end",h),g.on("unpipe",u);var L=function Pe(g){return function(){var b=g._readableState;F("pipeOnDrain",b.awaitDrain),b.awaitDrain&&b.awaitDrain--,0===b.awaitDrain&&v(g,"data")&&(b.flowing=!0,ee(g))}}(q);g.on("drain",L);var Z=!1;var Se=!1;function Ze(zn){F("ondata"),Se=!1,!1===g.write(zn)&&!Se&&((1===ne.pipesCount&&ne.pipes===g||ne.pipesCount>1&&-1!==W(ne.pipes,g))&&!Z&&(F("false write response, pause",q._readableState.awaitDrain),q._readableState.awaitDrain++,Se=!0),q.pause())}function yt(zn){F("onerror",zn),Bt(),g.removeListener("error",yt),0===v(g,"error")&&g.emit("error",zn)}function Vt(){g.removeListener("finish",nn),Bt()}function nn(){F("onfinish"),g.removeListener("close",Vt),Bt()}function Bt(){F("unpipe"),q.unpipe(g)}return q.on("data",Ze),function de(g,b,q){if("function"==typeof g.prependListener)return g.prependListener(b,q);g._events&&g._events[b]?D(g._events[b])?g._events[b].unshift(q):g._events[b]=[q,g._events[b]]:g.on(b,q)}(g,"error",yt),g.once("close",Vt),g.once("finish",nn),g.emit("pipe",q),ne.flowing||(F("pipe resume"),q.resume()),g},Y.prototype.unpipe=function(g){var b=this._readableState,q={hasUnpiped:!1};if(0===b.pipesCount)return this;if(1===b.pipesCount)return g&&g!==b.pipes||(g||(g=b.pipes),b.pipes=null,b.pipesCount=0,b.flowing=!1,g&&g.emit("unpipe",this,q)),this;if(!g){var ne=b.pipes,A=b.pipesCount;b.pipes=null,b.pipesCount=0,b.flowing=!1;for(var h=0;h-1?R:D.nextTick;de.WritableState=G;var I=Object.create(V("core-util-is"));I.inherits=V("inherits");var z={deprecate:V("util-deprecate")},C=V("./internal/streams/stream"),P=V("safe-buffer").Buffer,M=S.Uint8Array||function(){};var oe,B=V("./internal/streams/destroy");function Q(){}function G(U,ee){_=_||V("./_stream_duplex");var be=ee instanceof _;this.objectMode=!!(U=U||{}).objectMode,be&&(this.objectMode=this.objectMode||!!U.writableObjectMode);var xe=U.highWaterMark,ie=U.writableHighWaterMark;this.highWaterMark=xe||0===xe?xe:be&&(ie||0===ie)?ie:this.objectMode?16:16384,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1,this.decodeStrings=!(!1===U.decodeStrings),this.defaultEncoding=U.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Re){!function pe(U,ee){var be=U._writableState,xe=be.sync,ie=be.writecb;if(function J(U){U.writing=!1,U.writecb=null,U.length-=U.writelen,U.writelen=0}(be),ee)!function se(U,ee,be,xe,ie){--ee.pendingcb,be?(D.nextTick(ie,xe),D.nextTick(Pe,U,ee),U._writableState.errorEmitted=!0,U.emit("error",xe)):(ie(xe),U._writableState.errorEmitted=!0,U.emit("error",xe),Pe(U,ee))}(U,be,xe,ee,ie);else{var $=ue(be);!$&&!be.corked&&!be.bufferProcessing&&be.bufferedRequest&&Fe(U,be),xe?v(Ce,U,be,$,ie):Ce(U,be,$,ie)}}(ee,Re)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new y(this)}function de(U){if(_=_||V("./_stream_duplex"),!(oe.call(de,this)||this instanceof _))return new de(U);this._writableState=new G(U,this),this.writable=!0,U&&("function"==typeof U.write&&(this._write=U.write),"function"==typeof U.writev&&(this._writev=U.writev),"function"==typeof U.destroy&&(this._destroy=U.destroy),"function"==typeof U.final&&(this._final=U.final)),C.call(this)}function N(U,ee,be,xe,ie,$){if(!be){var ye=function H(U,ee,be){return!U.objectMode&&!1!==U.decodeStrings&&"string"==typeof ee&&(ee=P.from(ee,be)),ee}(ee,xe,ie);xe!==ye&&(be=!0,ie="buffer",xe=ye)}var Re=ee.objectMode?1:xe.length;ee.length+=Re;var W=ee.length-1))throw new TypeError("Unknown encoding: "+ee);return this._writableState.defaultEncoding=ee,this},Object.defineProperty(de.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),de.prototype._write=function(U,ee,be){be(new Error("_write() is not implemented"))},de.prototype._writev=null,de.prototype.end=function(U,ee,be){var xe=this._writableState;"function"==typeof U?(be=U,U=null,ee=null):"function"==typeof ee&&(be=ee,ee=null),null!=U&&this.write(U,ee),xe.corked&&(xe.corked=1,this.uncork()),!xe.ending&&!xe.finished&&function _e(U,ee,be){ee.ending=!0,Pe(U,ee),be&&(ee.finished?D.nextTick(be):U.once("finish",be)),ee.ended=!0,U.writable=!1}(this,xe,be)},Object.defineProperty(de.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(U){!this._writableState||(this._writableState.destroyed=U)}}),de.prototype.destroy=B.destroy,de.prototype._undestroy=B.undestroy,de.prototype._destroy=function(U,ee){this.end(),ee(U)}}).call(this)}).call(this,V("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},V("timers").setImmediate)},{"./_stream_duplex":22,"./internal/streams/destroy":28,"./internal/streams/stream":29,_process:69,"core-util-is":18,inherits:34,"process-nextick-args":45,"safe-buffer":31,timers:74,"util-deprecate":65}],27:[function(V,X,re){"use strict";var S=V("safe-buffer").Buffer,R=V("util");function D(m,y,v){m.copy(y,v)}X.exports=function(){function m(){(function T(m,y){if(!(m instanceof y))throw new TypeError("Cannot call a class as a function")})(this,m),this.head=null,this.tail=null,this.length=0}return m.prototype.push=function(v){var _={data:v,next:null};this.length>0?this.tail.next=_:this.head=_,this.tail=_,++this.length},m.prototype.unshift=function(v){var _={data:v,next:this.head};0===this.length&&(this.tail=_),this.head=_,++this.length},m.prototype.shift=function(){if(0!==this.length){var v=this.head.data;return this.head=1===this.length?this.tail=null:this.head.next,--this.length,v}},m.prototype.clear=function(){this.head=this.tail=null,this.length=0},m.prototype.join=function(v){if(0===this.length)return"";for(var _=this.head,I=""+_.data;_=_.next;)I+=v+_.data;return I},m.prototype.concat=function(v){if(0===this.length)return S.alloc(0);if(1===this.length)return this.head.data;for(var _=S.allocUnsafe(v>>>0),I=this.head,z=0;I;)D(I.data,_,z),z+=I.data.length,I=I.next;return _},m}(),R&&R.inspect&&R.inspect.custom&&(X.exports.prototype[R.inspect.custom]=function(){var m=R.inspect({length:this.length});return this.constructor.name+" "+m})},{"safe-buffer":31,util:2}],28:[function(V,X,re){"use strict";var T=V("process-nextick-args");function D(m,y){m.emit("error",y)}X.exports={destroy:function S(m,y){var v=this;return this._readableState&&this._readableState.destroyed||this._writableState&&this._writableState.destroyed?(y?y(m):m&&(!this._writableState||!this._writableState.errorEmitted)&&T.nextTick(D,this,m),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(m||null,function(z){!y&&z?(T.nextTick(D,v,z),v._writableState&&(v._writableState.errorEmitted=!0)):y&&y(z)}),this)},undestroy:function R(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},{"process-nextick-args":45}],29:[function(V,X,re){X.exports=V("events").EventEmitter},{events:4}],30:[function(V,X,re){(re=X.exports=V("./lib/_stream_readable.js")).Stream=re,re.Readable=re,re.Writable=V("./lib/_stream_writable.js"),re.Duplex=V("./lib/_stream_duplex.js"),re.Transform=V("./lib/_stream_transform.js"),re.PassThrough=V("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":22,"./lib/_stream_passthrough.js":23,"./lib/_stream_readable.js":24,"./lib/_stream_transform.js":25,"./lib/_stream_writable.js":26}],31:[function(V,X,re){var T=V("buffer"),S=T.Buffer;function R(m,y){for(var v in m)y[v]=m[v]}function D(m,y,v){return S(m,y,v)}S.from&&S.alloc&&S.allocUnsafe&&S.allocUnsafeSlow?X.exports=T:(R(T,re),re.Buffer=D),R(S,D),D.from=function(m,y,v){if("number"==typeof m)throw new TypeError("Argument must not be a number");return S(m,y,v)},D.alloc=function(m,y,v){if("number"!=typeof m)throw new TypeError("Argument must be a number");var _=S(m);return void 0!==y?"string"==typeof v?_.fill(y,v):_.fill(y):_.fill(0),_},D.allocUnsafe=function(m){if("number"!=typeof m)throw new TypeError("Argument must be a number");return S(m)},D.allocUnsafeSlow=function(m){if("number"!=typeof m)throw new TypeError("Argument must be a number");return T.SlowBuffer(m)}},{buffer:3}],32:[function(V,X,re){"use strict";var T=V("safe-buffer").Buffer,S=T.isEncoding||function(G){switch((G=""+G)&&G.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function m(G){var oe;switch(this.encoding=function D(G){var oe=function R(G){if(!G)return"utf8";for(var oe;;)switch(G){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return G;default:if(oe)return;G=(""+G).toLowerCase(),oe=!0}}(G);if("string"!=typeof oe&&(T.isEncoding===S||!S(G)))throw new Error("Unknown encoding: "+G);return oe||G}(G),this.encoding){case"utf16le":this.text=P,this.end=M,oe=4;break;case"utf8":this.fillLast=I,oe=4;break;case"base64":this.text=O,this.end=F,oe=3;break;default:return this.write=B,void(this.end=Q)}this.lastNeed=0,this.lastTotal=0,this.lastChar=T.allocUnsafe(oe)}function y(G){return G<=127?0:G>>5==6?2:G>>4==14?3:G>>3==30?4:G>>6==2?-1:-2}function I(G){var oe=this.lastTotal-this.lastNeed,de=function _(G,oe,de){if(128!=(192&oe[0]))return G.lastNeed=0,"\ufffd";if(G.lastNeed>1&&oe.length>1){if(128!=(192&oe[1]))return G.lastNeed=1,"\ufffd";if(G.lastNeed>2&&oe.length>2&&128!=(192&oe[2]))return G.lastNeed=2,"\ufffd"}}(this,G);return void 0!==de?de:this.lastNeed<=G.length?(G.copy(this.lastChar,oe,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(G.copy(this.lastChar,oe,0,G.length),void(this.lastNeed-=G.length))}function P(G,oe){if((G.length-oe)%2==0){var de=G.toString("utf16le",oe);if(de){var le=de.charCodeAt(de.length-1);if(le>=55296&&le<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=G[G.length-2],this.lastChar[1]=G[G.length-1],de.slice(0,-1)}return de}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=G[G.length-1],G.toString("utf16le",oe,G.length-1)}function M(G){var oe=G&&G.length?this.write(G):"";return this.lastNeed?oe+this.lastChar.toString("utf16le",0,this.lastTotal-this.lastNeed):oe}function O(G,oe){var de=(G.length-oe)%3;return 0===de?G.toString("base64",oe):(this.lastNeed=3-de,this.lastTotal=3,1===de?this.lastChar[0]=G[G.length-1]:(this.lastChar[0]=G[G.length-2],this.lastChar[1]=G[G.length-1]),G.toString("base64",oe,G.length-de))}function F(G){var oe=G&&G.length?this.write(G):"";return this.lastNeed?oe+this.lastChar.toString("base64",0,3-this.lastNeed):oe}function B(G){return G.toString(this.encoding)}function Q(G){return G&&G.length?this.write(G):""}re.StringDecoder=m,m.prototype.write=function(G){if(0===G.length)return"";var oe,de;if(this.lastNeed){if(void 0===(oe=this.fillLast(G)))return"";de=this.lastNeed,this.lastNeed=0}else de=0;return de=0?(Y>0&&(G.lastNeed=Y-1),Y):--le=0?(Y>0&&(G.lastNeed=Y-2),Y):--le=0?(Y>0&&(2===Y?Y=0:G.lastNeed=Y-3),Y):0}(this,G,oe);if(!this.lastNeed)return G.toString("utf8",oe);this.lastTotal=de;var le=G.length-(de-this.lastNeed);return G.copy(this.lastChar,0,le),G.toString("utf8",oe,le)},m.prototype.fillLast=function(G){if(this.lastNeed<=G.length)return G.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);G.copy(this.lastChar,this.lastTotal-this.lastNeed,0,G.length),this.lastNeed-=G.length}},{"safe-buffer":31}],33:[function(V,X,re){(function(T){(function(){var S=V("once"),R=function(){},y=function(v,_,I){if("function"==typeof _)return y(v,null,_);_||(_={}),I=S(I||R);var z=v._writableState,C=v._readableState,P=_.readable||!1!==_.readable&&v.readable,M=_.writable||!1!==_.writable&&v.writable,O=!1,F=function(){v.writable||B()},B=function(){M=!1,P||I.call(v)},Q=function(){P=!1,M||I.call(v)},G=function(H){I.call(v,H?new Error("exited with error code: "+H):null)},oe=function(H){I.call(v,H)},de=function(){T.nextTick(le)},le=function(){if(!O){if(P&&(!C||!C.ended||C.destroyed))return I.call(v,new Error("premature close"));if(M&&(!z||!z.ended||z.destroyed))return I.call(v,new Error("premature close"))}},Y=function(){v.req.on("finish",B)};return function(v){return v.setHeader&&"function"==typeof v.abort}(v)?(v.on("complete",B),v.on("abort",de),v.req?Y():v.on("request",Y)):M&&!z&&(v.on("end",F),v.on("close",F)),function(v){return v.stdio&&Array.isArray(v.stdio)&&3===v.stdio.length}(v)&&v.on("exit",G),v.on("end",Q),v.on("finish",B),!1!==_.error&&v.on("error",oe),v.on("close",de),function(){O=!0,v.removeListener("complete",B),v.removeListener("abort",de),v.removeListener("request",Y),v.req&&v.req.removeListener("finish",B),v.removeListener("end",F),v.removeListener("close",F),v.removeListener("finish",B),v.removeListener("exit",G),v.removeListener("end",Q),v.removeListener("error",oe),v.removeListener("close",de)}};X.exports=y}).call(this)}).call(this,V("_process"))},{_process:69,once:44}],34:[function(V,X,re){X.exports="function"==typeof Object.create?function(S,R){R&&(S.super_=R,S.prototype=Object.create(R.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}))}:function(S,R){if(R){S.super_=R;var D=function(){};D.prototype=R.prototype,S.prototype=new D,S.prototype.constructor=S}}},{}],35:[function(V,X,re){var T={}.toString;X.exports=Array.isArray||function(S){return"[object Array]"==T.call(S)}},{}],36:[function(V,X,re){(function(T){(function(){const S=X.exports;S.types={0:"reserved",1:"connect",2:"connack",3:"publish",4:"puback",5:"pubrec",6:"pubrel",7:"pubcomp",8:"subscribe",9:"suback",10:"unsubscribe",11:"unsuback",12:"pingreq",13:"pingresp",14:"disconnect",15:"auth"},S.codes={};for(const D in S.types)S.codes[S.types[D]]=D;S.CMD_SHIFT=4,S.CMD_MASK=240,S.DUP_MASK=8,S.QOS_MASK=3,S.QOS_SHIFT=1,S.RETAIN_MASK=1,S.VARBYTEINT_MASK=127,S.VARBYTEINT_FIN_MASK=128,S.VARBYTEINT_MAX=268435455,S.SESSIONPRESENT_MASK=1,S.SESSIONPRESENT_HEADER=T.from([S.SESSIONPRESENT_MASK]),S.CONNACK_HEADER=T.from([S.codes.connack<[0,1].map(y=>[0,1].map(v=>{const _=T.alloc(1);return _.writeUInt8(S.codes[D]<T.from([D])),S.EMPTY={pingreq:T.from([S.codes.pingreq<<4,0]),pingresp:T.from([S.codes.pingresp<<4,0]),disconnect:T.from([S.codes.disconnect<<4,0])}}).call(this)}).call(this,V("buffer").Buffer)},{buffer:3}],37:[function(V,X,re){(function(T){(function(){const S=V("./writeToStream"),R=V("events");class m extends R{constructor(){super(),this._array=new Array(20),this._i=0}write(v){return this._array[this._i++]=v,!0}concat(){let v=0;const _=new Array(this._array.length),I=this._array;let C,z=0;for(C=0;C>8,0),z.writeUInt8(255&I,1),z}X.exports={cache:R,generateCache:function y(){for(let I=0;I<65536;I++)R[I]=m(I)},generateNumber:m,genBufVariableByteInt:function v(I){let C=0,P=0;const M=T.allocUnsafe(4);do{C=I%128|0,(I=I/128|0)>0&&(C|=128),M.writeUInt8(C,P++)}while(I>0&&P<4);return I>0&&(P=0),D?M.subarray(0,P):M.slice(0,P)},generate4ByteBuffer:function _(I){const z=T.allocUnsafe(4);return z.writeUInt32BE(I,0),z}}}).call(this)}).call(this,V("buffer").Buffer)},{buffer:3}],40:[function(V,X,re){X.exports=class T{constructor(){this.cmd=null,this.retain=!1,this.qos=0,this.dup=!1,this.length=-1,this.topic=null,this.payload=null}}},{}],41:[function(V,X,re){const T=V("bl"),S=V("events"),R=V("./packet"),D=V("./constants"),m=V("debug")("mqtt-packet:parser");class y extends S{constructor(){super(),this.parser=this.constructor.parser}static parser(_){return this instanceof y?(this.settings=_||{},this._states=["_parseHeader","_parseLength","_parsePayload","_newPacket"],this._resetState(),this):(new y).parser(_)}_resetState(){m("_resetState: resetting packet, error, _list, and _stateCounter"),this.packet=new R,this.error=null,this._list=T(),this._stateCounter=0}parse(_){for(this.error&&this._resetState(),this._list.append(_),m("parse: current state: %s",this._states[this._stateCounter]);(-1!==this.packet.length||this._list.length>0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,m("parse: state complete. _stateCounter is now: %d",this._stateCounter),m("parse: packet.length: %d, buffer list length: %d",this.packet.length,this._list.length),this._stateCounter>=this._states.length&&(this._stateCounter=0);return m("parse: exited while loop. packet: %d, buffer list length: %d",this.packet.length,this._list.length),this._list.length}_parseHeader(){const _=this._list.readUInt8(0);return this.packet.cmd=D.types[_>>D.CMD_SHIFT],this.packet.retain=0!=(_&D.RETAIN_MASK),this.packet.qos=_>>D.QOS_SHIFT&D.QOS_MASK,this.packet.dup=0!=(_&D.DUP_MASK),m("_parseHeader: packet: %o",this.packet),this._list.consume(1),!0}_parseLength(){const _=this._parseVarByteNum(!0);return _&&(this.packet.length=_.value,this._list.consume(_.bytes)),m("_parseLength %d",_.value),!!_}_parsePayload(){m("_parsePayload: payload %O",this._list);let _=!1;if(0===this.packet.length||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseConfirmation();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":break;case"disconnect":this._parseDisconnect();break;case"auth":this._parseAuth();break;default:this._emitError(new Error("Not supported"))}_=!0}return m("_parsePayload complete result: %s",_),_}_parseConnect(){let _,I,z,C;m("_parseConnect");const P={},M=this.packet,O=this._parseString();if(null===O)return this._emitError(new Error("Cannot parse protocolId"));if("MQTT"!==O&&"MQIsdp"!==O)return this._emitError(new Error("Invalid protocolId"));if(M.protocolId=O,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(M.protocolVersion=this._list.readUInt8(this._pos),M.protocolVersion>=128&&(M.bridgeMode=!0,M.protocolVersion=M.protocolVersion-128),3!==M.protocolVersion&&4!==M.protocolVersion&&5!==M.protocolVersion)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(P.username=this._list.readUInt8(this._pos)&D.USERNAME_MASK,P.password=this._list.readUInt8(this._pos)&D.PASSWORD_MASK,P.will=this._list.readUInt8(this._pos)&D.WILL_FLAG_MASK,P.will&&(M.will={},M.will.retain=0!=(this._list.readUInt8(this._pos)&D.WILL_RETAIN_MASK),M.will.qos=(this._list.readUInt8(this._pos)&D.WILL_QOS_MASK)>>D.WILL_QOS_SHIFT),M.clean=0!=(this._list.readUInt8(this._pos)&D.CLEAN_SESSION_MASK),this._pos++,M.keepalive=this._parseNum(),-1===M.keepalive)return this._emitError(new Error("Packet too short"));if(5===M.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(M.properties=B)}const F=this._parseString();if(null===F)return this._emitError(new Error("Packet too short"));if(M.clientId=F,m("_parseConnect: packet.clientId: %s",M.clientId),P.will){if(5===M.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(M.will.properties=B)}if(_=this._parseString(),null===_)return this._emitError(new Error("Cannot parse will topic"));if(M.will.topic=_,m("_parseConnect: packet.will.topic: %s",M.will.topic),I=this._parseBuffer(),null===I)return this._emitError(new Error("Cannot parse will payload"));M.will.payload=I,m("_parseConnect: packet.will.paylaod: %s",M.will.payload)}if(P.username){if(C=this._parseString(),null===C)return this._emitError(new Error("Cannot parse username"));M.username=C,m("_parseConnect: packet.username: %s",M.username)}if(P.password){if(z=this._parseBuffer(),null===z)return this._emitError(new Error("Cannot parse password"));M.password=z}return this.settings=M,m("_parseConnect: complete"),M}_parseConnack(){m("_parseConnack");const _=this.packet;if(this._list.length<1)return null;if(_.sessionPresent=!!(this._list.readUInt8(this._pos++)&D.SESSIONPRESENT_MASK),5===this.settings.protocolVersion)_.reasonCode=this._list.length>=2?this._list.readUInt8(this._pos++):0;else{if(this._list.length<2)return null;_.returnCode=this._list.readUInt8(this._pos++)}if(-1===_.returnCode||-1===_.reasonCode)return this._emitError(new Error("Cannot parse return code"));if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}m("_parseConnack: complete")}_parsePublish(){m("_parsePublish");const _=this.packet;if(_.topic=this._parseString(),null===_.topic)return this._emitError(new Error("Cannot parse topic"));if(!(_.qos>0)||this._parseMessageId()){if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}_.payload=this._list.slice(this._pos,_.length),m("_parsePublish: payload from buffer list: %o",_.payload)}}_parseSubscribe(){m("_parseSubscribe");const _=this.packet;let I,z,C,P,M,O,F;if(1!==_.qos)return this._emitError(new Error("Wrong subscribe header"));if(_.subscriptions=[],this._parseMessageId()){if(5===this.settings.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(_.properties=B)}for(;this._pos<_.length;){if(I=this._parseString(),null===I)return this._emitError(new Error("Cannot parse topic"));if(this._pos>=_.length)return this._emitError(new Error("Malformed Subscribe Payload"));z=this._parseByte(),C=z&D.SUBSCRIBE_OPTIONS_QOS_MASK,O=0!=(z>>D.SUBSCRIBE_OPTIONS_NL_SHIFT&D.SUBSCRIBE_OPTIONS_NL_MASK),M=0!=(z>>D.SUBSCRIBE_OPTIONS_RAP_SHIFT&D.SUBSCRIBE_OPTIONS_RAP_MASK),P=z>>D.SUBSCRIBE_OPTIONS_RH_SHIFT&D.SUBSCRIBE_OPTIONS_RH_MASK,F={topic:I,qos:C},5===this.settings.protocolVersion?(F.nl=O,F.rap=M,F.rh=P):this.settings.bridgeMode&&(F.rh=0,F.rap=!0,F.nl=!0),m("_parseSubscribe: push subscription `%s` to subscription",F),_.subscriptions.push(F)}}}_parseSuback(){m("_parseSuback");const _=this.packet;if(this.packet.granted=[],this._parseMessageId()){if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}for(;this._pos2?(_.reasonCode=this._parseByte(),m("_parseConfirmation: packet.reasonCode `%d`",_.reasonCode)):_.reasonCode=0,_.length>3)){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}return!0}_parseDisconnect(){const _=this.packet;if(m("_parseDisconnect"),5===this.settings.protocolVersion){_.reasonCode=this._list.length>0?this._parseByte():0;const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}return m("_parseDisconnect result: true"),!0}_parseAuth(){m("_parseAuth");const _=this.packet;if(5!==this.settings.protocolVersion)return this._emitError(new Error("Not supported auth packet for this version MQTT"));_.reasonCode=this._parseByte();const I=this._parseProperties();return Object.getOwnPropertyNames(I).length&&(_.properties=I),m("_parseAuth: result: true"),!0}_parseMessageId(){const _=this.packet;return _.messageId=this._parseNum(),null===_.messageId?(this._emitError(new Error("Cannot parse messageId")),!1):(m("_parseMessageId: packet.messageId %d",_.messageId),!0)}_parseString(_){const I=this._parseNum(),z=I+this._pos;if(-1===I||z>this._list.length||z>this.packet.length)return null;const C=this._list.toString("utf8",this._pos,z);return this._pos+=I,m("_parseString: result: %s",C),C}_parseStringPair(){return m("_parseStringPair"),{name:this._parseString(),value:this._parseString()}}_parseBuffer(){const _=this._parseNum(),I=_+this._pos;if(-1===_||I>this._list.length||I>this.packet.length)return null;const z=this._list.slice(this._pos,I);return this._pos+=_,m("_parseBuffer: result: %o",z),z}_parseNum(){if(this._list.length-this._pos<2)return-1;const _=this._list.readUInt16BE(this._pos);return this._pos+=2,m("_parseNum: result: %s",_),_}_parse4ByteNum(){if(this._list.length-this._pos<4)return-1;const _=this._list.readUInt32BE(this._pos);return this._pos+=4,m("_parse4ByteNum: result: %s",_),_}_parseVarByteNum(_){m("_parseVarByteNum");let O,z=0,C=1,P=0,M=!1;const F=this._pos?this._pos:0;for(;z<4&&F+z=z&&this._emitError(new Error("Invalid variable byte integer")),F&&(this._pos+=z),M=!!M&&(_?{bytes:z,value:P}:P),m("_parseVarByteNum: result: %o",M),M}_parseByte(){let _;return this._pos=4)&&(A||q))L+=T.byteLength(A)+2;else{if(g<4)return $.emit("error",new Error("clientId must be supplied before 3.1.1")),!1;if(1*q==0)return $.emit("error",new Error("clientId must be given if cleanSession set to 0")),!1}if("number"!=typeof ne||ne<0||ne>65535||ne%1!=0)return $.emit("error",new Error("Invalid keepalive")),!1;if(L+=2,L+=1,5===g){var Z=_e($,p);if(!Z)return!1;L+=Z.length}if(b){if("object"!=typeof b)return $.emit("error",new Error("Invalid will")),!1;if(!b.topic||"string"!=typeof b.topic)return $.emit("error",new Error("Invalid will topic")),!1;if(L+=T.byteLength(b.topic)+2,L+=2,b.payload){if(!(b.payload.length>=0))return $.emit("error",new Error("Invalid will payload")),!1;L+="string"==typeof b.payload?T.byteLength(b.payload):b.payload.length}var me={};if(5===g){if(!(me=_e($,b.properties)))return!1;L+=me.length}}let Se=!1;if(null!=h){if(!xe(h))return $.emit("error",new Error("Invalid username")),!1;Se=!0,L+=T.byteLength(h)+2}if(null!=u){if(!Se)return $.emit("error",new Error("Username is required to use password")),!1;if(!xe(u))return $.emit("error",new Error("Invalid password")),!1;L+=be(u)+2}$.write(S.CONNECT_HEADER),Ce($,L),Pe($,W),Re.bridgeMode&&(g+=128),$.write(131===g?S.VERSION131:132===g?S.VERSION132:4===g?S.VERSION4:5===g?S.VERSION5:S.VERSION3);let Ze=0;return Ze|=null!=h?S.USERNAME_MASK:0,Ze|=null!=u?S.PASSWORD_MASK:0,Ze|=b&&b.retain?S.WILL_RETAIN_MASK:0,Ze|=b&&b.qos?b.qos<0&&M($,A),null!=p&&p.write(),v("publish: payload: %o",ne),$.write(ne)}(ie,$,ye);case"puback":case"pubrec":case"pubrel":case"pubcomp":return function de(ie,$,ye){const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.cmd||"puback",b=W.messageId,q=W.dup&&"pubrel"===g?S.DUP_MASK:0;let ne=0;const A=W.reasonCode,h=W.properties;let u=5===Re?3:2;if("pubrel"===g&&(ne=1),"number"!=typeof b)return $.emit("error",new Error("Invalid messageId")),!1;let p=null;if(5===Re&&"object"==typeof h){if(p=ve($,h,ye,u),!p)return!1;u+=p.length}return $.write(S.ACKS[g][ne][q][0]),Ce($,u),M($,b),5===Re&&$.write(T.from([A])),null!==p&&p.write(),!0}(ie,$,ye);case"subscribe":return function le(ie,$,ye){v("subscribe: packet: ");const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.dup?S.DUP_MASK:0,b=W.messageId,q=W.subscriptions,ne=W.properties;let A=0;if("number"!=typeof b)return $.emit("error",new Error("Invalid messageId")),!1;A+=2;let h=null;if(5===Re){if(h=_e($,ne),!h)return!1;A+=h.length}if("object"!=typeof q||!q.length)return $.emit("error",new Error("Invalid subscriptions")),!1;for(let p=0;p2)return $.emit("error",new Error("Invalid subscriptions - invalid Retain Handling")),!1}A+=T.byteLength(L)+2+1}v("subscribe: writing to stream: %o",S.SUBSCRIBE_HEADER),$.write(S.SUBSCRIBE_HEADER[1][g?1:0][0]),Ce($,A),M($,b),null!==h&&h.write();let u=!0;for(const p of q){const Z=p.qos,me=+p.nl,Se=+p.rap,Ze=p.rh;let yt;ge($,p.topic),yt=S.SUBSCRIBE_OPTIONS_QOS[Z],5===Re&&(yt|=me?S.SUBSCRIBE_OPTIONS_NL:0,yt|=Se?S.SUBSCRIBE_OPTIONS_RAP:0,yt|=Ze?S.SUBSCRIBE_OPTIONS_RH[Ze]:0),u=$.write(T.from([yt]))}return u}(ie,$,ye);case"suback":return function Y(ie,$,ye){const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.messageId,b=W.granted,q=W.properties;let ne=0;if("number"!=typeof g)return $.emit("error",new Error("Invalid messageId")),!1;if(ne+=2,"object"!=typeof b||!b.length)return $.emit("error",new Error("Invalid qos vector")),!1;for(let h=0;hM===ue,set(ie){ie?((!_||0===Object.keys(_).length)&&(O=!0),M=ue):(O=!1,M=Ye)}});const pe={};function Ce(ie,$){if($>S.VARBYTEINT_MAX)return ie.emit("error",new Error(`Invalid variable byte integer: ${$}`)),!1;let ye=pe[$];return ye||(ye=C($),$<16384&&(pe[$]=ye)),v("writeVarByteInt: writing to stream: %o",ye),ie.write(ye)}function ge(ie,$){const ye=T.byteLength($);return M(ie,ye),v("writeString: %s",$),ie.write($,"utf8")}function Fe(ie,$,ye){ge(ie,$),ge(ie,ye)}function ue(ie,$){return v("writeNumberCached: number: %d",$),v("writeNumberCached: %o",_[$]),ie.write(_[$])}function Ye(ie,$){const ye=I($);return v("writeNumberGenerated: %o",ye),ie.write(ye)}function Pe(ie,$){"string"==typeof $?ge(ie,$):$?(M(ie,$.length),ie.write($)):M(ie,0)}function _e(ie,$){if("object"!=typeof $||null!=$.length)return{length:1,write(){ee(ie,{},0)}};let ye=0;function Re(g,b){let ne=0;switch(S.propertiesTypes[g]){case"byte":if("boolean"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=2;break;case"int8":if("number"!=typeof b||b<0||b>255)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=2;break;case"binary":if(b&&null===b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=1+T.byteLength(b)+2;break;case"int16":if("number"!=typeof b||b<0||b>65535)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=3;break;case"int32":if("number"!=typeof b||b<0||b>4294967295)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=5;break;case"var":if("number"!=typeof b||b<0||b>268435455)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=1+T.byteLength(C(b));break;case"string":if("string"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=3+T.byteLength(b.toString());break;case"pair":if("object"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=Object.getOwnPropertyNames(b).reduce((A,h)=>{const u=b[h];return Array.isArray(u)?A+=u.reduce((p,L)=>p+(3+T.byteLength(h.toString())+2+T.byteLength(L.toString())),0):A+=3+T.byteLength(h.toString())+2+T.byteLength(b[h].toString()),A},0);break;default:return ie.emit("error",new Error(`Invalid property ${g}: ${b}`)),!1}return ne}if($)for(const g in $){let b=0,q=0;const ne=$[g];if(Array.isArray(ne))for(let A=0;Ag;){const q=W.shift();if(!q||!$[q])return!1;delete $[q],b=_e(ie,$)}return b}function U(ie,$,ye){switch(S.propertiesTypes[$]){case"byte":ie.write(T.from([S.properties[$]])),ie.write(T.from([+ye]));break;case"int8":ie.write(T.from([S.properties[$]])),ie.write(T.from([ye]));break;case"binary":ie.write(T.from([S.properties[$]])),Pe(ie,ye);break;case"int16":ie.write(T.from([S.properties[$]])),M(ie,ye);break;case"int32":ie.write(T.from([S.properties[$]])),function Ne(ie,$){const ye=P($);return v("write4ByteNumber: %o",ye),ie.write(ye)}(ie,ye);break;case"var":ie.write(T.from([S.properties[$]])),Ce(ie,ye);break;case"string":ie.write(T.from([S.properties[$]])),ge(ie,ye);break;case"pair":Object.getOwnPropertyNames(ye).forEach(W=>{const g=ye[W];Array.isArray(g)?g.forEach(b=>{ie.write(T.from([S.properties[$]])),Fe(ie,W.toString(),b.toString())}):(ie.write(T.from([S.properties[$]])),Fe(ie,W.toString(),g.toString()))});break;default:return ie.emit("error",new Error(`Invalid property ${$} value: ${ye}`)),!1}}function ee(ie,$,ye){Ce(ie,ye);for(const Re in $)if(Object.prototype.hasOwnProperty.call($,Re)&&null!==$[Re]){const W=$[Re];if(Array.isArray(W))for(let g=0;g=1.5*M;return Math.round(C/M)+" "+O+(F?"s":"")}X.exports=function(C,P){P=P||{};var M=typeof C;if("string"===M&&C.length>0)return function v(C){if(!((C=String(C)).length>100)){var P=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(C);if(P){var M=parseFloat(P[1]);switch((P[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*M;case"weeks":case"week":case"w":return 6048e5*M;case"days":case"day":case"d":return M*D;case"hours":case"hour":case"hrs":case"hr":case"h":return M*R;case"minutes":case"minute":case"mins":case"min":case"m":return M*S;case"seconds":case"second":case"secs":case"sec":case"s":return M*T;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return M;default:return}}}}(C);if("number"===M&&isFinite(C))return P.long?function I(C){var P=Math.abs(C);return P>=D?z(C,P,D,"day"):P>=R?z(C,P,R,"hour"):P>=S?z(C,P,S,"minute"):P>=T?z(C,P,T,"second"):C+" ms"}(C):function _(C){var P=Math.abs(C);return P>=D?Math.round(C/D)+"d":P>=R?Math.round(C/R)+"h":P>=S?Math.round(C/S)+"m":P>=T?Math.round(C/T)+"s":C+"ms"}(C);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(C))}},{}],44:[function(V,X,re){var T=V("wrappy");function S(D){var m=function(){return m.called?m.value:(m.called=!0,m.value=D.apply(this,arguments))};return m.called=!1,m}function R(D){var m=function(){if(m.called)throw new Error(m.onceError);return m.called=!0,m.value=D.apply(this,arguments)};return m.onceError=(D.name||"Function wrapped with `once`")+" shouldn't be called more than once",m.called=!1,m}X.exports=T(S),X.exports.strict=T(R),S.proto=S(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return S(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return R(this)},configurable:!0})})},{wrappy:66}],45:[function(V,X,re){(function(T){(function(){"use strict";X.exports=void 0===T||!T.version||0===T.version.indexOf("v0.")||0===T.version.indexOf("v1.")&&0!==T.version.indexOf("v1.8.")?{nextTick:function S(R,D,m,y){if("function"!=typeof R)throw new TypeError('"callback" argument must be a function');var _,I,v=arguments.length;switch(v){case 0:case 1:return T.nextTick(R);case 2:return T.nextTick(function(){R.call(null,D)});case 3:return T.nextTick(function(){R.call(null,D,m)});case 4:return T.nextTick(function(){R.call(null,D,m,y)});default:for(_=new Array(v-1),I=0;I<_.length;)_[I++]=arguments[I];return T.nextTick(function(){R.apply(null,_)})}}}:T}).call(this)}).call(this,V("_process"))},{_process:69}],46:[function(V,X,re){"use strict";var S={};function R(_,I,z){z||(z=Error);var P=function(M){function O(F,B,Q){return M.call(this,function C(M,O,F){return"string"==typeof I?I:I(M,O,F)}(F,B,Q))||this}return function T(_,I){_.prototype=Object.create(I.prototype),_.prototype.constructor=_,_.__proto__=I}(O,M),O}(z);P.prototype.name=z.name,P.prototype.code=_,S[_]=P}function D(_,I){if(Array.isArray(_)){var z=_.length;return _=_.map(function(C){return String(C)}),z>2?"one of ".concat(I," ").concat(_.slice(0,z-1).join(", "),", or ")+_[z-1]:2===z?"one of ".concat(I," ").concat(_[0]," or ").concat(_[1]):"of ".concat(I," ").concat(_[0])}return"of ".concat(I," ").concat(String(_))}R("ERR_INVALID_OPT_VALUE",function(_,I){return'The value "'+I+'" is invalid for option "'+_+'"'},TypeError),R("ERR_INVALID_ARG_TYPE",function(_,I,z){var C,P;if("string"==typeof I&&function m(_,I,z){return _.substr(!z||z<0?0:+z,I.length)===I}(I,"not ")?(C="must not be",I=I.replace(/^not /,"")):C="must be",function y(_,I,z){return(void 0===z||z>_.length)&&(z=_.length),_.substring(z-I.length,z)===I}(_," argument"))P="The ".concat(_," ").concat(C," ").concat(D(I,"type"));else{var M=function v(_,I,z){return"number"!=typeof z&&(z=0),!(z+I.length>_.length)&&-1!==_.indexOf(I,z)}(_,".")?"property":"argument";P='The "'.concat(_,'" ').concat(M," ").concat(C," ").concat(D(I,"type"))}return P+". Received type ".concat(typeof z)},TypeError),R("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),R("ERR_METHOD_NOT_IMPLEMENTED",function(_){return"The "+_+" method is not implemented"}),R("ERR_STREAM_PREMATURE_CLOSE","Premature close"),R("ERR_STREAM_DESTROYED",function(_){return"Cannot call "+_+" after a stream was destroyed"}),R("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),R("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),R("ERR_STREAM_WRITE_AFTER_END","write after end"),R("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),R("ERR_UNKNOWN_ENCODING",function(_){return"Unknown encoding: "+_},TypeError),R("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),X.exports.codes=S},{}],47:[function(V,X,re){(function(T){(function(){"use strict";var S=Object.keys||function(C){var P=[];for(var M in C)P.push(M);return P};X.exports=_;var R=V("./_stream_readable"),D=V("./_stream_writable");V("inherits")(_,R);for(var m=S(D.prototype),y=0;y0)if("string"!=typeof h&&!Z.objectMode&&Object.getPrototypeOf(h)!==v.prototype&&(h=function I(A){return v.from(A)}(h)),p)Z.endEmitted?E(A,new le):Fe(A,Z,h,!0);else if(Z.ended)E(A,new oe);else{if(Z.destroyed)return!1;Z.reading=!1,Z.decoder&&!u?(h=Z.decoder.write(h),Z.objectMode||0!==h.length?Fe(A,Z,h,!1):ee(A,Z)):Fe(A,Z,h,!1)}else p||(Z.reading=!1,ee(A,Z));return!Z.ended&&(Z.lengthh.highWaterMark&&(h.highWaterMark=function Ne(A){return A>=Ye?A=Ye:(A--,A|=A>>>1,A|=A>>>2,A|=A>>>4,A|=A>>>8,A|=A>>>16,A++),A}(A)),A<=h.length?A:h.ended?h.length:(h.needReadable=!0,0))}function ve(A){var h=A._readableState;P("emitReadable",h.needReadable,h.emittedReadable),h.needReadable=!1,h.emittedReadable||(P("emitReadable",h.flowing),h.emittedReadable=!0,T.nextTick(U,A))}function U(A){var h=A._readableState;P("emitReadable_",h.destroyed,h.length,h.ended),!h.destroyed&&(h.length||h.ended)&&(A.emit("readable"),h.emittedReadable=!1),h.needReadable=!h.flowing&&!h.ended&&h.length<=h.highWaterMark,W(A)}function ee(A,h){h.readingMore||(h.readingMore=!0,T.nextTick(be,A,h))}function be(A,h){for(;!h.reading&&!h.ended&&(h.length0,h.resumeScheduled&&!h.paused?h.flowing=!0:A.listenerCount("data")>0&&A.resume()}function $(A){P("readable nexttick read 0"),A.read(0)}function Re(A,h){P("resume",h.reading),h.reading||A.read(0),h.resumeScheduled=!1,A.emit("resume"),W(A),h.flowing&&!h.reading&&A.read(0)}function W(A){var h=A._readableState;for(P("flow",h.flowing);h.flowing&&null!==A.read(););}function g(A,h){return 0===h.length?null:(h.objectMode?u=h.buffer.shift():!A||A>=h.length?(u=h.decoder?h.buffer.join(""):1===h.buffer.length?h.buffer.first():h.buffer.concat(h.length),h.buffer.clear()):u=h.buffer.consume(A,h.decoder),u);var u}function b(A){var h=A._readableState;P("endReadable",h.endEmitted),h.endEmitted||(h.ended=!0,T.nextTick(q,h,A))}function q(A,h){if(P("endReadableNT",A.endEmitted,A.length),!A.endEmitted&&0===A.length&&(A.endEmitted=!0,h.readable=!1,h.emit("end"),A.autoDestroy)){var u=h._writableState;(!u||u.autoDestroy&&u.finished)&&h.destroy()}}function ne(A,h){for(var u=0,p=A.length;u=h.highWaterMark:h.length>0)||h.ended))return P("read: emitReadable",h.length,h.ended),0===h.length&&h.ended?b(this):ve(this),null;if(0===(A=Pe(A,h))&&h.ended)return 0===h.length&&b(this),null;var L,p=h.needReadable;return P("need readable",p),(0===h.length||h.length-A0?g(A,h):null)?(h.needReadable=h.length<=h.highWaterMark,A=0):(h.length-=A,h.awaitDrain=0),0===h.length&&(h.ended||(h.needReadable=!0),u!==A&&h.ended&&b(this)),null!==L&&this.emit("data",L),L},Ce.prototype._read=function(A){E(this,new de("_read()"))},Ce.prototype.pipe=function(A,h){var u=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=A;break;case 1:p.pipes=[p.pipes,A];break;default:p.pipes.push(A)}p.pipesCount+=1,P("pipe count=%d opts=%j",p.pipesCount,h);var Z=h&&!1===h.end||A===T.stdout||A===T.stderr?Oi:Se;function me(Vr,Hr){P("onunpipe"),Vr===u&&Hr&&!1===Hr.hasUnpiped&&(Hr.hasUnpiped=!0,function Vt(){P("cleanup"),A.removeListener("close",zn),A.removeListener("finish",_i),A.removeListener("drain",Ze),A.removeListener("error",Bt),A.removeListener("unpipe",me),u.removeListener("end",Se),u.removeListener("end",Oi),u.removeListener("data",nn),yt=!0,p.awaitDrain&&(!A._writableState||A._writableState.needDrain)&&Ze()}())}function Se(){P("onend"),A.end()}p.endEmitted?T.nextTick(Z):u.once("end",Z),A.on("unpipe",me);var Ze=function xe(A){return function(){var u=A._readableState;P("pipeOnDrain",u.awaitDrain),u.awaitDrain&&u.awaitDrain--,0===u.awaitDrain&&m(A,"data")&&(u.flowing=!0,W(A))}}(u);A.on("drain",Ze);var yt=!1;function nn(Vr){P("ondata");var Hr=A.write(Vr);P("dest.write",Hr),!1===Hr&&((1===p.pipesCount&&p.pipes===A||p.pipesCount>1&&-1!==ne(p.pipes,A))&&!yt&&(P("false write response, pause",p.awaitDrain),p.awaitDrain++),u.pause())}function Bt(Vr){P("onerror",Vr),Oi(),A.removeListener("error",Bt),0===m(A,"error")&&E(A,Vr)}function zn(){A.removeListener("finish",_i),Oi()}function _i(){P("onfinish"),A.removeListener("close",zn),Oi()}function Oi(){P("unpipe"),u.unpipe(A)}return u.on("data",nn),function J(A,h,u){if("function"==typeof A.prependListener)return A.prependListener(h,u);A._events&&A._events[h]?Array.isArray(A._events[h])?A._events[h].unshift(u):A._events[h]=[u,A._events[h]]:A.on(h,u)}(A,"error",Bt),A.once("close",zn),A.once("finish",_i),A.emit("pipe",u),p.flowing||(P("pipe resume"),u.resume()),A},Ce.prototype.unpipe=function(A){var h=this._readableState,u={hasUnpiped:!1};if(0===h.pipesCount)return this;if(1===h.pipesCount)return A&&A!==h.pipes||(A||(A=h.pipes),h.pipes=null,h.pipesCount=0,h.flowing=!1,A&&A.emit("unpipe",this,u)),this;if(!A){var p=h.pipes,L=h.pipesCount;h.pipes=null,h.pipesCount=0,h.flowing=!1;for(var Z=0;Z0,!1!==p.flowing&&this.resume()):"readable"===A&&!p.endEmitted&&!p.readableListening&&(p.readableListening=p.needReadable=!0,p.flowing=!1,p.emittedReadable=!1,P("on readable",p.length,p.reading),p.length?ve(this):p.reading||T.nextTick($,this)),u},Ce.prototype.removeListener=function(A,h){var u=y.prototype.removeListener.call(this,A,h);return"readable"===A&&T.nextTick(ie,this),u},Ce.prototype.removeAllListeners=function(A){var h=y.prototype.removeAllListeners.apply(this,arguments);return("readable"===A||void 0===A)&&T.nextTick(ie,this),h},Ce.prototype.resume=function(){var A=this._readableState;return A.flowing||(P("resume"),A.flowing=!A.readableListening,function ye(A,h){h.resumeScheduled||(h.resumeScheduled=!0,T.nextTick(Re,A,h))}(this,A)),A.paused=!1,this},Ce.prototype.pause=function(){return P("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(P("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},Ce.prototype.wrap=function(A){var h=this,u=this._readableState,p=!1;for(var L in A.on("end",function(){if(P("wrapped end"),u.decoder&&!u.ended){var me=u.decoder.end();me&&me.length&&h.push(me)}h.push(null)}),A.on("data",function(me){P("wrapped data"),u.decoder&&(me=u.decoder.write(me)),u.objectMode&&null==me||!(u.objectMode||me&&me.length)||h.push(me)||(p=!0,A.pause())}),A)void 0===this[L]&&"function"==typeof A[L]&&(this[L]=function(Se){return function(){return A[Se].apply(A,arguments)}}(L));for(var Z=0;Z-1))throw new H(g);return this._writableState.defaultEncoding=g,this},Object.defineProperty(pe.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(pe.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),pe.prototype._write=function(W,g,b){b(new Q("_write()"))},pe.prototype._writev=null,pe.prototype.end=function(W,g,b){var q=this._writableState;return"function"==typeof W?(b=W,W=null,g=null):"function"==typeof g&&(b=g,g=null),null!=W&&this.write(W,g),q.corked&&(q.corked=1,this.uncork()),q.ending||function ye(W,g,b){g.ending=!0,$(W,g),b&&(g.finished?T.nextTick(b):W.once("finish",b)),g.ended=!0,W.writable=!1}(this,q,b),this},Object.defineProperty(pe.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(pe.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(g){!this._writableState||(this._writableState.destroyed=g)}}),pe.prototype.destroy=P.destroy,pe.prototype._undestroy=P.undestroy,pe.prototype._destroy=function(W,g){g(W)}}).call(this)}).call(this,V("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../errors":46,"./_stream_duplex":47,"./internal/streams/destroy":54,"./internal/streams/state":58,"./internal/streams/stream":59,_process:69,buffer:3,inherits:34,"util-deprecate":65}],52:[function(V,X,re){(function(T){(function(){"use strict";var S;function R(oe,de,le){return de in oe?Object.defineProperty(oe,de,{value:le,enumerable:!0,configurable:!0,writable:!0}):oe[de]=le,oe}var D=V("./end-of-stream"),m=Symbol("lastResolve"),y=Symbol("lastReject"),v=Symbol("error"),_=Symbol("ended"),I=Symbol("lastPromise"),z=Symbol("handlePromise"),C=Symbol("stream");function P(oe,de){return{value:oe,done:de}}function M(oe){var de=oe[m];if(null!==de){var le=oe[C].read();null!==le&&(oe[I]=null,oe[m]=null,oe[y]=null,de(P(le,!1)))}}function O(oe){T.nextTick(M,oe)}var B=Object.getPrototypeOf(function(){}),Q=Object.setPrototypeOf((R(S={get stream(){return this[C]},next:function(){var de=this,le=this[v];if(null!==le)return Promise.reject(le);if(this[_])return Promise.resolve(P(void 0,!0));if(this[C].destroyed)return new Promise(function(E,se){T.nextTick(function(){de[v]?se(de[v]):E(P(void 0,!0))})});var H,Y=this[I];if(Y)H=new Promise(function F(oe,de){return function(le,Y){oe.then(function(){de[_]?le(P(void 0,!0)):de[z](le,Y)},Y)}}(Y,this));else{var N=this[C].read();if(null!==N)return Promise.resolve(P(N,!1));H=new Promise(this[z])}return this[I]=H,H}},Symbol.asyncIterator,function(){return this}),R(S,"return",function(){var de=this;return new Promise(function(le,Y){de[C].destroy(null,function(H){H?Y(H):le(P(void 0,!0))})})}),S),B);X.exports=function(de){var le,Y=Object.create(Q,(R(le={},C,{value:de,writable:!0}),R(le,m,{value:null,writable:!0}),R(le,y,{value:null,writable:!0}),R(le,v,{value:null,writable:!0}),R(le,_,{value:de._readableState.endEmitted,writable:!0}),R(le,z,{value:function(N,E){var se=Y[C].read();se?(Y[I]=null,Y[m]=null,Y[y]=null,N(P(se,!1))):(Y[m]=N,Y[y]=E)},writable:!0}),le));return Y[I]=null,D(de,function(H){if(H&&"ERR_STREAM_PREMATURE_CLOSE"!==H.code){var N=Y[y];return null!==N&&(Y[I]=null,Y[m]=null,Y[y]=null,N(H)),void(Y[v]=H)}var E=Y[m];null!==E&&(Y[I]=null,Y[m]=null,Y[y]=null,E(P(void 0,!0))),Y[_]=!0}),de.on("readable",O.bind(null,Y)),Y}}).call(this)}).call(this,V("_process"))},{"./end-of-stream":55,_process:69}],53:[function(V,X,re){"use strict";function T(M,O){var F=Object.keys(M);if(Object.getOwnPropertySymbols){var B=Object.getOwnPropertySymbols(M);O&&(B=B.filter(function(Q){return Object.getOwnPropertyDescriptor(M,Q).enumerable})),F.push.apply(F,B)}return F}function R(M,O,F){return O in M?Object.defineProperty(M,O,{value:F,enumerable:!0,configurable:!0,writable:!0}):M[O]=F,M}function m(M,O){for(var F=0;F0?this.tail.next=B:this.head=B,this.tail=B,++this.length}},{key:"unshift",value:function(F){var B={data:F,next:this.head};0===this.length&&(this.tail=B),this.head=B,++this.length}},{key:"shift",value:function(){if(0!==this.length){var F=this.head.data;return this.head=1===this.length?this.tail=null:this.head.next,--this.length,F}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(F){if(0===this.length)return"";for(var B=this.head,Q=""+B.data;B=B.next;)Q+=F+B.data;return Q}},{key:"concat",value:function(F){if(0===this.length)return _.alloc(0);for(var B=_.allocUnsafe(F>>>0),Q=this.head,G=0;Q;)P(Q.data,B,G),G+=Q.data.length,Q=Q.next;return B}},{key:"consume",value:function(F,B){var Q;return Foe.length?oe.length:F;if(G+=de===oe.length?oe:oe.slice(0,F),0==(F-=de)){de===oe.length?(++Q,this.head=B.next?B.next:this.tail=null):(this.head=B,B.data=oe.slice(de));break}++Q}return this.length-=Q,G}},{key:"_getBuffer",value:function(F){var B=_.allocUnsafe(F),Q=this.head,G=1;for(Q.data.copy(B),F-=Q.data.length;Q=Q.next;){var oe=Q.data,de=F>oe.length?oe.length:F;if(oe.copy(B,B.length-F,0,de),0==(F-=de)){de===oe.length?(++G,this.head=Q.next?Q.next:this.tail=null):(this.head=Q,Q.data=oe.slice(de));break}++G}return this.length-=G,B}},{key:C,value:function(F,B){return z(this,function S(M){for(var O=1;O0,function(H){Q||(Q=H),H&&G.forEach(I),!le&&(G.forEach(I),B(Q))})});return O.reduce(z)}},{"../../../errors":46,"./end-of-stream":55}],58:[function(V,X,re){"use strict";var T=V("../../../errors").codes.ERR_INVALID_OPT_VALUE;X.exports={getHighWaterMark:function R(D,m,y,v){var _=function S(D,m,y){return null!=D.highWaterMark?D.highWaterMark:m?D[y]:null}(m,v,y);if(null!=_){if(!isFinite(_)||Math.floor(_)!==_||_<0)throw new T(v?y:"highWaterMark",_);return Math.floor(_)}return D.objectMode?16:16384}}},{"../../../errors":46}],59:[function(V,X,re){arguments[4][29][0].apply(re,arguments)},{dup:29,events:4}],60:[function(V,X,re){(re=X.exports=V("./lib/_stream_readable.js")).Stream=re,re.Readable=re,re.Writable=V("./lib/_stream_writable.js"),re.Duplex=V("./lib/_stream_duplex.js"),re.Transform=V("./lib/_stream_transform.js"),re.PassThrough=V("./lib/_stream_passthrough.js"),re.finished=V("./lib/internal/streams/end-of-stream.js"),re.pipeline=V("./lib/internal/streams/pipeline.js")},{"./lib/_stream_duplex.js":47,"./lib/_stream_passthrough.js":48,"./lib/_stream_readable.js":49,"./lib/_stream_transform.js":50,"./lib/_stream_writable.js":51,"./lib/internal/streams/end-of-stream.js":55,"./lib/internal/streams/pipeline.js":57}],61:[function(V,X,re){"use strict";function T(R,D,m){var y=this;this._callback=R,this._args=m,this._interval=setInterval(R,D,this._args),this.reschedule=function(v){v||(v=y._interval),y._interval&&clearInterval(y._interval),y._interval=setInterval(y._callback,v,y._args)},this.clear=function(){y._interval&&(clearInterval(y._interval),y._interval=void 0)},this.destroy=function(){y._interval&&clearInterval(y._interval),y._callback=void 0,y._interval=void 0,y._args=void 0}}X.exports=function S(){if("function"!=typeof arguments[0])throw new Error("callback needed");if("number"!=typeof arguments[1])throw new Error("interval needed");var R;if(arguments.length>0){R=new Array(arguments.length-2);for(var D=0;D1)for(var G=1;G= 0x80 (not a basic code point)","invalid-input":"Invalid input"},le=Math.floor,Y=String.fromCharCode;function N(_e){throw new RangeError(oe[_e])}function E(_e,ve){for(var U=_e.length,ee=[];U--;)ee[U]=ve(_e[U]);return ee}function se(_e,ve){var U=_e.split("@"),ee="";return U.length>1&&(ee=U[0]+"@",_e=U[1]),ee+E((_e=_e.replace(G,".")).split("."),ve).join(".")}function J(_e){for(var be,xe,ve=[],U=0,ee=_e.length;U=55296&&be<=56319&&U65535&&(U+=Y((ve-=65536)>>>10&1023|55296),ve=56320|1023&ve),U+Y(ve)}).join("")}function Ce(_e){return _e-48<10?_e-22:_e-65<26?_e-65:_e-97<26?_e-97:_}function ge(_e,ve){return _e+22+75*(_e<26)-((0!=ve)<<5)}function Fe(_e,ve,U){var ee=0;for(_e=U?le(_e/700):_e>>1,_e+=le(_e/ve);_e>455;ee+=_)_e=le(_e/35);return le(ee+36*_e/(_e+38))}function ue(_e){var ee,$,ye,Re,W,g,b,q,ne,A,ve=[],U=_e.length,be=0,xe=128,ie=72;for(($=_e.lastIndexOf("-"))<0&&($=0),ye=0;ye<$;++ye)_e.charCodeAt(ye)>=128&&N("not-basic"),ve.push(_e.charCodeAt(ye));for(Re=$>0?$+1:0;Re=U&&N("invalid-input"),((q=Ce(_e.charCodeAt(Re++)))>=_||q>le((v-be)/g))&&N("overflow"),be+=q*g,!(q<(ne=b<=ie?1:b>=ie+26?26:b-ie));b+=_)g>le(v/(A=_-ne))&&N("overflow"),g*=A;ie=Fe(be-W,ee=ve.length+1,0==W),le(be/ee)>v-xe&&N("overflow"),xe+=le(be/ee),be%=ee,ve.splice(be++,0,xe)}return pe(ve)}function Ye(_e){var ve,U,ee,be,xe,ie,$,ye,Re,W,g,q,ne,A,h,b=[];for(q=(_e=J(_e)).length,ve=128,U=0,xe=72,ie=0;ie=ve&&g<$&&($=g);for($-ve>le((v-U)/(ne=ee+1))&&N("overflow"),U+=($-ve)*ne,ve=$,ie=0;iev&&N("overflow"),g==ve){for(ye=U,Re=_;!(ye<(W=Re<=xe?1:Re>=xe+26?26:Re-xe));Re+=_)b.push(Y(ge(W+(h=ye-W)%(A=_-W),0))),ye=le(h/A);b.push(Y(ge(ye,0))),xe=Fe(U,ne,ee==be),U=0,++ee}++U,++ve}return b.join("")}if(y={version:"1.4.1",ucs2:{decode:J,encode:pe},decode:ue,encode:Ye,toASCII:function Pe(_e){return se(_e,function(ve){return Q.test(ve)?"xn--"+Ye(ve):ve})},toUnicode:function Ne(_e){return se(_e,function(ve){return B.test(ve)?ue(ve.slice(4).toLowerCase()):ve})}},R&&D)if(X.exports==R)D.exports=y;else for(H in y)y.hasOwnProperty(H)&&(R[H]=y[H]);else S.punycode=y}(this)}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],71:[function(V,X,re){"use strict";function T(R,D){return Object.prototype.hasOwnProperty.call(R,D)}X.exports=function(R,D,m,y){m=m||"=";var v={};if("string"!=typeof R||0===R.length)return v;var _=/\+/g;R=R.split(D=D||"&");var I=1e3;y&&"number"==typeof y.maxKeys&&(I=y.maxKeys);var z=R.length;I>0&&z>I&&(z=I);for(var C=0;C=0?(O=P.substr(0,M),F=P.substr(M+1)):(O=P,F=""),B=decodeURIComponent(O),Q=decodeURIComponent(F),T(v,B)?S(v[B])?v[B].push(Q):v[B]=[v[B],Q]:v[B]=Q}return v};var S=Array.isArray||function(R){return"[object Array]"===Object.prototype.toString.call(R)}},{}],72:[function(V,X,re){"use strict";var T=function(m){switch(typeof m){case"string":return m;case"boolean":return m?"true":"false";case"number":return isFinite(m)?m:"";default:return""}};X.exports=function(m,y,v,_){return y=y||"&",v=v||"=",null===m&&(m=void 0),"object"==typeof m?R(D(m),function(I){var z=encodeURIComponent(T(I))+v;return S(m[I])?R(m[I],function(C){return z+encodeURIComponent(T(C))}).join(y):z+encodeURIComponent(T(m[I]))}).join(y):_?encodeURIComponent(T(_))+v+encodeURIComponent(T(m)):""};var S=Array.isArray||function(m){return"[object Array]"===Object.prototype.toString.call(m)};function R(m,y){if(m.map)return m.map(y);for(var v=[],_=0;_=0&&(I._idleTimeoutId=setTimeout(function(){I._onTimeout&&I._onTimeout()},z))},re.setImmediate="function"==typeof T?T:function(I){var z=v++,C=!(arguments.length<2)&&m.call(arguments,1);return y[z]=!0,R(function(){y[z]&&(C?I.apply(null,C):I.call(null),re.clearImmediate(z))}),z},re.clearImmediate="function"==typeof S?S:function(I){delete y[I]}}).call(this)}).call(this,V("timers").setImmediate,V("timers").clearImmediate)},{"process/browser.js":69,timers:74}],75:[function(V,X,re){"use strict";var T=V("punycode"),S=V("./util");function R(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}re.parse=oe,re.resolve=function le(H,N){return oe(H,!1,!0).resolve(N)},re.resolveObject=function Y(H,N){return H?oe(H,!1,!0).resolveObject(N):N},re.format=function de(H){return S.isString(H)&&(H=oe(H)),H instanceof R?H.format():R.prototype.format.call(H)},re.Url=R;var D=/^([a-z0-9.+-]+:)/i,m=/:[0-9]*$/,y=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,_=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),I=["'"].concat(_),z=["%","/","?",";","#"].concat(I),C=["/","?","#"],M=/^[+a-z0-9A-Z_-]{0,63}$/,O=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,F={javascript:!0,"javascript:":!0},B={javascript:!0,"javascript:":!0},Q={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},G=V("querystring");function oe(H,N,E){if(H&&S.isObject(H)&&H instanceof R)return H;var se=new R;return se.parse(H,N,E),se}R.prototype.parse=function(H,N,E){if(!S.isString(H))throw new TypeError("Parameter 'url' must be a string, not "+typeof H);var se=H.indexOf("?"),J=-1!==se&&se127?ye+="x":ye+=$[Re];if(!ye.match(M)){var g=xe.slice(0,_e),b=xe.slice(_e+1),q=$.match(O);q&&(g.push(q[1]),b.unshift(q[2])),b.length&&(ge="/"+b.join(".")+ge),this.hostname=g.join(".");break}}}this.hostname=this.hostname.length>255?"":this.hostname.toLowerCase(),be||(this.hostname=T.toASCII(this.hostname)),this.host=(this.hostname||"")+(this.port?":"+this.port:""),this.href+=this.host,be&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==ge[0]&&(ge="/"+ge))}if(!F[Ye])for(_e=0,ie=I.length;_e0)&&E.host.split("@"))&&(E.auth=ye.shift(),E.host=E.hostname=ye.shift())),E.search=H.search,E.query=H.query,(!S.isNull(E.pathname)||!S.isNull(E.search))&&(E.path=(E.pathname?E.pathname:"")+(E.search?E.search:"")),E.href=E.format(),E;if(!xe.length)return E.pathname=null,E.path=E.search?"/"+E.search:null,E.href=E.format(),E;for(var Re=xe.slice(-1)[0],W=(E.host||H.host||xe.length>1)&&("."===Re||".."===Re)||""===Re,g=0,b=xe.length;b>=0;b--)"."===(Re=xe[b])?xe.splice(b,1):".."===Re?(xe.splice(b,1),g++):g&&(xe.splice(b,1),g--);if(!ee&&!be)for(;g--;g)xe.unshift("..");ee&&""!==xe[0]&&(!xe[0]||"/"!==xe[0].charAt(0))&&xe.unshift(""),W&&"/"!==xe.join("/").substr(-1)&&xe.push("");var ye,q=""===xe[0]||xe[0]&&"/"===xe[0].charAt(0);return $&&(E.hostname=E.host=q?"":xe.length?xe.shift():"",(ye=!!(E.host&&E.host.indexOf("@")>0)&&E.host.split("@"))&&(E.auth=ye.shift(),E.host=E.hostname=ye.shift())),(ee=ee||E.host&&xe.length)&&!q&&xe.unshift(""),xe.length?E.pathname=xe.join("/"):(E.pathname=null,E.path=null),(!S.isNull(E.pathname)||!S.isNull(E.search))&&(E.path=(E.pathname?E.pathname:"")+(E.search?E.search:"")),E.auth=H.auth||E.auth,E.slashes=E.slashes||H.slashes,E.href=E.format(),E},R.prototype.parseHost=function(){var H=this.host,N=m.exec(H);N&&(":"!==(N=N[0])&&(this.port=N.substr(1)),H=H.substr(0,H.length-N.length)),H&&(this.hostname=H)}},{"./util":76,punycode:70,querystring:73}],76:[function(V,X,re){"use strict";X.exports={isString:function(T){return"string"==typeof T},isObject:function(T){return"object"==typeof T&&null!==T},isNull:function(T){return null===T},isNullOrUndefined:function(T){return null==T}}},{}]},{},[15])(15)},703:js=>{js.exports=function ps(){for(var ut={},Br=0;Br{js(js.s=736)}]); \ No newline at end of file +(self.webpackChunkcamera_management_web_ui=self.webpackChunkcamera_management_web_ui||[]).push([[179],{736:(js,Wa,ps)=>{"use strict";function ut(n){return"function"==typeof n}function Br(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const ms=Br(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function V(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class X{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(ut(i))try{i()}catch(s){t=s instanceof ms?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{S(s)}catch(o){t=null!=t?t:[],o instanceof ms?t=[...t,...o.errors]:t.push(o)}}if(t)throw new ms(t)}}add(t){var e;if(t&&t!==this)if(this.closed)S(t);else{if(t instanceof X){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&V(e,t)}remove(t){const{_finalizers:e}=this;e&&V(e,t),t instanceof X&&t._removeParent(this)}}X.EMPTY=(()=>{const n=new X;return n.closed=!0,n})();const re=X.EMPTY;function T(n){return n instanceof X||n&&"closed"in n&&ut(n.remove)&&ut(n.add)&&ut(n.unsubscribe)}function S(n){ut(n)?n():n.unsubscribe()}const R={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},D={setTimeout(n,t,...e){const{delegate:i}=D;return null!=i&&i.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=D;return((null==t?void 0:t.clearTimeout)||clearTimeout)(n)},delegate:void 0};function m(n){D.setTimeout(()=>{const{onUnhandledError:t}=R;if(!t)throw n;t(n)})}function y(){}const v=z("C",void 0,void 0);function z(n,t,e){return{kind:n,value:t,error:e}}let C=null;function P(n){if(R.useDeprecatedSynchronousErrorHandling){const t=!C;if(t&&(C={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=C;if(C=null,e)throw i}}else n()}class O extends X{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,T(t)&&t.add(this)):this.destination=Y}static create(t,e,i){return new G(t,e,i)}next(t){this.isStopped?le(function I(n){return z("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?le(function _(n){return z("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?le(v,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const F=Function.prototype.bind;function B(n,t){return F.call(n,t)}class Q{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){oe(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){oe(i)}else oe(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){oe(e)}}}class G extends O{constructor(t,e,i){let r;if(super(),ut(t)||!t)r={next:null!=t?t:void 0,error:null!=e?e:void 0,complete:null!=i?i:void 0};else{let s;this&&R.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&B(t.next,s),error:t.error&&B(t.error,s),complete:t.complete&&B(t.complete,s)}):r=t}this.destination=new Q(r)}}function oe(n){R.useDeprecatedSynchronousErrorHandling?function M(n){R.useDeprecatedSynchronousErrorHandling&&C&&(C.errorThrown=!0,C.error=n)}(n):m(n)}function le(n,t){const{onStoppedNotification:e}=R;e&&D.setTimeout(()=>e(n,t))}const Y={closed:!0,next:y,error:function de(n){throw n},complete:y},H="function"==typeof Symbol&&Symbol.observable||"@@observable";function N(n){return n}let J=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function ge(n){return n&&n instanceof O||function Ce(n){return n&&ut(n.next)&&ut(n.error)&&ut(n.complete)}(n)&&T(n)}(e)?e:new G(e,i,r);return P(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=pe(i))((r,s)=>{const o=new G({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[H](){return this}pipe(...e){return function se(n){return 0===n.length?N:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=pe(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function pe(n){var t;return null!==(t=null!=n?n:R.Promise)&&void 0!==t?t:Promise}const Fe=Br(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let ue=(()=>{class n extends J{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new Ye(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new Fe}next(e){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){P(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?re:(this.currentObservers=null,s.push(e),new X(()=>{this.currentObservers=null,V(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new J;return e.source=this,e}}return n.create=(t,e)=>new Ye(t,e),n})();class Ye extends ue{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:re}}function Ne(n){return ut(null==n?void 0:n.lift)}function Pe(n){return t=>{if(Ne(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}function _e(n,t,e,i,r){return new ve(n,t,e,i,r)}class ve extends O{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function U(n,t){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>{i.next(n.call(t,s,r++))}))})}function L(n){return this instanceof L?(this.v=n,this):new L(n)}function Z(n,t,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,i=e.apply(n,t||[]),s=[];return r={},o("next"),o("throw"),o("return"),r[Symbol.asyncIterator]=function(){return this},r;function o(w){i[w]&&(r[w]=function(k){return new Promise(function(j,K){s.push([w,k,j,K])>1||a(w,k)})})}function a(w,k){try{!function l(w){w.value instanceof L?Promise.resolve(w.value.v).then(c,d):f(s[0][2],w)}(i[w](k))}catch(j){f(s[0][3],j)}}function c(w){a("next",w)}function d(w){a("throw",w)}function f(w,k){w(k),s.shift(),s.length&&a(s[0][0],s[0][1])}}function Se(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,t=n[Symbol.asyncIterator];return t?t.call(n):(n=function ne(n){var t="function"==typeof Symbol&&Symbol.iterator,e=t&&n[t],i=0;if(e)return e.call(n);if(n&&"number"==typeof n.length)return{next:function(){return n&&i>=n.length&&(n=void 0),{value:n&&n[i++],done:!n}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(n),e={},i("next"),i("throw"),i("return"),e[Symbol.asyncIterator]=function(){return this},e);function i(s){e[s]=n[s]&&function(o){return new Promise(function(a,l){!function r(s,o,a,l){Promise.resolve(l).then(function(c){s({value:c,done:a})},o)}(a,l,(o=n[s](o)).done,o.value)})}}}const Oi=n=>n&&"number"==typeof n.length&&"function"!=typeof n;function Vr(n){return ut(null==n?void 0:n.then)}function Hr(n){return ut(n[H])}function Xv(n){return Symbol.asyncIterator&&ut(null==n?void 0:n[Symbol.asyncIterator])}function Jv(n){return new TypeError(`You provided ${null!==n&&"object"==typeof n?"an invalid object":`'${n}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}const ey=function yA(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}();function ty(n){return ut(null==n?void 0:n[ey])}function ny(n){return Z(this,arguments,function*(){const e=n.getReader();try{for(;;){const{value:i,done:r}=yield L(e.read());if(r)return yield L(void 0);yield yield L(i)}}finally{e.releaseLock()}})}function iy(n){return ut(null==n?void 0:n.getReader)}function di(n){if(n instanceof J)return n;if(null!=n){if(Hr(n))return function bA(n){return new J(t=>{const e=n[H]();if(ut(e.subscribe))return e.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(n);if(Oi(n))return function wA(n){return new J(t=>{for(let e=0;e{n.then(e=>{t.closed||(t.next(e),t.complete())},e=>t.error(e)).then(null,m)})}(n);if(Xv(n))return ry(n);if(ty(n))return function DA(n){return new J(t=>{for(const e of n)if(t.next(e),t.closed)return;t.complete()})}(n);if(iy(n))return function EA(n){return ry(ny(n))}(n)}throw Jv(n)}function ry(n){return new J(t=>{(function MA(n,t){var e,i,r,s;return function W(n,t,e,i){return new(e||(e=Promise))(function(s,o){function a(d){try{c(i.next(d))}catch(f){o(f)}}function l(d){try{c(i.throw(d))}catch(f){o(f)}}function c(d){d.done?s(d.value):function r(s){return s instanceof e?s:new e(function(o){o(s)})}(d.value).then(a,l)}c((i=i.apply(n,t||[])).next())})}(this,void 0,void 0,function*(){try{for(e=Se(n);!(i=yield e.next()).done;)if(t.next(i.value),t.closed)return}catch(o){r={error:o}}finally{try{i&&!i.done&&(s=e.return)&&(yield s.call(e))}finally{if(r)throw r.error}}t.complete()})})(n,t).catch(e=>t.error(e))})}function jr(n,t,e,i=0,r=!1){const s=t.schedule(function(){e(),r?n.add(this.schedule(null,i)):this.unsubscribe()},i);if(n.add(s),!r)return s}function Pn(n,t,e=1/0){return ut(t)?Pn((i,r)=>U((s,o)=>t(i,s,r,o))(di(n(i,r))),e):("number"==typeof t&&(e=t),Pe((i,r)=>function xA(n,t,e,i,r,s,o,a){const l=[];let c=0,d=0,f=!1;const w=()=>{f&&!l.length&&!c&&t.complete()},k=K=>c{s&&t.next(K),c++;let ae=!1;di(e(K,d++)).subscribe(_e(t,ce=>{null==r||r(ce),s?k(ce):t.next(ce)},()=>{ae=!0},void 0,()=>{if(ae)try{for(c--;l.length&&cj(ce)):j(ce)}w()}catch(ce){t.error(ce)}}))};return n.subscribe(_e(t,k,()=>{f=!0,w()})),()=>{null==a||a()}}(i,r,n,e)))}function To(n=1/0){return Pn(N,n)}const Fi=new J(n=>n.complete());function sy(n){return n&&ut(n.schedule)}function tf(n){return n[n.length-1]}function oy(n){return ut(tf(n))?n.pop():void 0}function qa(n){return sy(tf(n))?n.pop():void 0}function ay(n,t=0){return Pe((e,i)=>{e.subscribe(_e(i,r=>jr(i,n,()=>i.next(r),t),()=>jr(i,n,()=>i.complete(),t),r=>jr(i,n,()=>i.error(r),t)))})}function ly(n,t=0){return Pe((e,i)=>{i.add(n.schedule(()=>e.subscribe(i),t))})}function cy(n,t){if(!n)throw new Error("Iterable cannot be null");return new J(e=>{jr(e,t,()=>{const i=n[Symbol.asyncIterator]();jr(e,t,()=>{i.next().then(r=>{r.done?e.complete():e.next(r.value)})},0,!0)})})}function gn(n,t){return t?function OA(n,t){if(null!=n){if(Hr(n))return function TA(n,t){return di(n).pipe(ly(t),ay(t))}(n,t);if(Oi(n))return function IA(n,t){return new J(e=>{let i=0;return t.schedule(function(){i===n.length?e.complete():(e.next(n[i++]),e.closed||this.schedule())})})}(n,t);if(Vr(n))return function AA(n,t){return di(n).pipe(ly(t),ay(t))}(n,t);if(Xv(n))return cy(n,t);if(ty(n))return function RA(n,t){return new J(e=>{let i;return jr(e,t,()=>{i=n[ey](),jr(e,t,()=>{let r,s;try{({value:r,done:s}=i.next())}catch(o){return void e.error(o)}s?e.complete():e.next(r)},0,!0)}),()=>ut(null==i?void 0:i.return)&&i.return()})}(n,t);if(iy(n))return function PA(n,t){return cy(ny(n),t)}(n,t)}throw Jv(n)}(n,t):di(n)}function $n(...n){const t=qa(n),e=function kA(n,t){return"number"==typeof tf(n)?n.pop():t}(n,1/0),i=n;return i.length?1===i.length?di(i[0]):To(e)(gn(i,t)):Fi}function sn(n){return n<=0?()=>Fi:Pe((t,e)=>{let i=0;t.subscribe(_e(e,r=>{++i<=n&&(e.next(r),n<=i&&e.complete())}))})}function dy(n={}){const{connector:t=(()=>new ue),resetOnError:e=!0,resetOnComplete:i=!0,resetOnRefCountZero:r=!0}=n;return s=>{let o=null,a=null,l=null,c=0,d=!1,f=!1;const w=()=>{null==a||a.unsubscribe(),a=null},k=()=>{w(),o=l=null,d=f=!1},j=()=>{const K=o;k(),null==K||K.unsubscribe()};return Pe((K,ae)=>{c++,!f&&!d&&w();const ce=l=null!=l?l:t();ae.add(()=>{c--,0===c&&!f&&!d&&(a=nf(j,r))}),ce.subscribe(ae),o||(o=new G({next:Te=>ce.next(Te),error:Te=>{f=!0,w(),a=nf(k,e,Te),ce.error(Te)},complete:()=>{d=!0,w(),a=nf(k,i),ce.complete()}}),gn(K).subscribe(o))})(s)}}function nf(n,t,...e){return!0===t?(n(),null):!1===t?null:t(...e).pipe(sn(1)).subscribe(()=>n())}function Yt(n){for(let t in n)if(n[t]===Yt)return t;throw Error("Could not find renamed property on target object.")}function rf(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function Kt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(Kt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function sf(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const FA=Yt({__forward_ref__:Yt});function Ft(n){return n.__forward_ref__=Ft,n.toString=function(){return Kt(this())},n}function pt(n){return af(n)?n():n}function af(n){return"function"==typeof n&&n.hasOwnProperty(FA)&&n.__forward_ref__===Ft}class Be extends Error{constructor(t,e){super(function Lc(n,t){return`NG0${Math.abs(n)}${t?": "+t.trim():""}`}(t,e)),this.code=t}}function gt(n){return"string"==typeof n?n:null==n?"":String(n)}function Nc(n,t){throw new Be(-201,!1)}function yi(n,t){null==n&&function $t(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Ie(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function qe(n){return{providers:n.providers||[],imports:n.imports||[]}}function lf(n){return uy(n,Bc)||uy(n,fy)}function uy(n,t){return n.hasOwnProperty(t)?n[t]:null}function hy(n){return n&&(n.hasOwnProperty(cf)||n.hasOwnProperty(zA))?n[cf]:null}const Bc=Yt({\u0275prov:Yt}),cf=Yt({\u0275inj:Yt}),fy=Yt({ngInjectableDef:Yt}),zA=Yt({ngInjectorDef:Yt});var at=(()=>((at=at||{})[at.Default=0]="Default",at[at.Host=1]="Host",at[at.Self=2]="Self",at[at.SkipSelf=4]="SkipSelf",at[at.Optional=8]="Optional",at))();let df;function pr(n){const t=df;return df=n,t}function py(n,t,e){const i=lf(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&at.Optional?null:void 0!==t?t:void Nc(Kt(n))}function gs(n){return{toString:n}.toString()}var Xi=(()=>((Xi=Xi||{})[Xi.OnPush=0]="OnPush",Xi[Xi.Default=1]="Default",Xi))(),Ji=(()=>{return(n=Ji||(Ji={}))[n.Emulated=0]="Emulated",n[n.None=2]="None",n[n.ShadowDom=3]="ShadowDom",Ji;var n})();const qt=(()=>"undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof global&&global||"undefined"!=typeof window&&window||"undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self)(),Ao={},jt=[],Vc=Yt({\u0275cmp:Yt}),uf=Yt({\u0275dir:Yt}),hf=Yt({\u0275pipe:Yt}),my=Yt({\u0275mod:Yt}),zr=Yt({\u0275fac:Yt}),Ya=Yt({__NG_ELEMENT_ID__:Yt});let GA=0;function vt(n){return gs(()=>{const e=!0===n.standalone,i={},r={type:n.type,providersResolver:null,decls:n.decls,vars:n.vars,factory:null,template:n.template||null,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:i,inputs:null,outputs:null,exportAs:n.exportAs||null,onPush:n.changeDetection===Xi.OnPush,directiveDefs:null,pipeDefs:null,standalone:e,dependencies:e&&n.dependencies||null,getStandaloneInjector:null,selectors:n.selectors||jt,viewQuery:n.viewQuery||null,features:n.features||null,data:n.data||{},encapsulation:n.encapsulation||Ji.Emulated,id:"c"+GA++,styles:n.styles||jt,_:null,setInput:null,schemas:n.schemas||null,tView:null},s=n.dependencies,o=n.features;return r.inputs=vy(n.inputs,i),r.outputs=vy(n.outputs),o&&o.forEach(a=>a(r)),r.directiveDefs=s?()=>("function"==typeof s?s():s).map(gy).filter(_y):null,r.pipeDefs=s?()=>("function"==typeof s?s():s).map(ei).filter(_y):null,r})}function gy(n){return Qt(n)||Jn(n)}function _y(n){return null!==n}const qA={};function Ke(n){return gs(()=>{const t={type:n.type,bootstrap:n.bootstrap||jt,declarations:n.declarations||jt,imports:n.imports||jt,exports:n.exports||jt,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null};return null!=n.id&&(qA[n.id]=n.type),t})}function vy(n,t){if(null==n)return Ao;const e={};for(const i in n)if(n.hasOwnProperty(i)){let r=n[i],s=r;Array.isArray(r)&&(s=r[1],r=r[0]),e[r]=i,t&&(t[r]=s)}return e}const Me=vt;function ui(n){return{type:n.type,name:n.name,factory:null,pure:!1!==n.pure,standalone:!0===n.standalone,onDestroy:n.type.prototype.ngOnDestroy||null}}function Qt(n){return n[Vc]||null}function Jn(n){return n[uf]||null}function ei(n){return n[hf]||null}function bi(n,t){const e=n[my]||null;if(!e&&!0===t)throw new Error(`Type ${Kt(n)} does not have '\u0275mod' property.`);return e}function hi(n){return Array.isArray(n)&&"object"==typeof n[1]}function tr(n){return Array.isArray(n)&&!0===n[1]}function mf(n){return 0!=(8&n.flags)}function zc(n){return 2==(2&n.flags)}function $c(n){return 1==(1&n.flags)}function nr(n){return null!==n.template}function XA(n){return 0!=(256&n[2])}function Ws(n,t){return n.hasOwnProperty(zr)?n[zr]:null}class tI{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function cn(){return wy}function wy(n){return n.type.prototype.ngOnChanges&&(n.setInput=iI),nI}function nI(){const n=Dy(this),t=null==n?void 0:n.current;if(t){const e=n.previous;if(e===Ao)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function iI(n,t,e,i){const r=Dy(n)||function rI(n,t){return n[Cy]=t}(n,{previous:Ao,current:null}),s=r.current||(r.current={}),o=r.previous,a=this.declaredInputs[e],l=o[a];s[a]=new tI(l&&l.currentValue,t,o===Ao),n[i]=t}cn.ngInherit=!0;const Cy="__ngSimpleChanges__";function Dy(n){return n[Cy]||null}let bf;function dn(n){return!!n.listen}const Ey={createRenderer:(n,t)=>function wf(){return void 0!==bf?bf:"undefined"!=typeof document?document:void 0}()};function Cn(n){for(;Array.isArray(n);)n=n[0];return n}function Gc(n,t){return Cn(t[n])}function Bi(n,t){return Cn(t[n.index])}function Cf(n,t){return n.data[t]}function Fo(n,t){return n[t]}function Ci(n,t){const e=t[n];return hi(e)?e:e[0]}function My(n){return 4==(4&n[2])}function Df(n){return 64==(64&n[2])}function _s(n,t){return null==t?null:n[t]}function xy(n){n[18]=0}function Ef(n,t){n[5]+=t;let e=n,i=n[3];for(;null!==i&&(1===t&&1===e[5]||-1===t&&0===e[5]);)i[5]+=t,e=i,i=i[3]}const mt={lFrame:Fy(null),bindingsEnabled:!0};function ky(){return mt.bindingsEnabled}function ke(){return mt.lFrame.lView}function Lt(){return mt.lFrame.tView}function Bn(n){return mt.lFrame.contextLView=n,n[8]}function Vn(n){return mt.lFrame.contextLView=null,n}function Sn(){let n=Ty();for(;null!==n&&64===n.type;)n=n.parent;return n}function Ty(){return mt.lFrame.currentTNode}function mr(n,t){const e=mt.lFrame;e.currentTNode=n,e.isParent=t}function Mf(){return mt.lFrame.isParent}function xf(){mt.lFrame.isParent=!1}function ti(){const n=mt.lFrame;let t=n.bindingRootIndex;return-1===t&&(t=n.bindingRootIndex=n.tView.bindingStartIndex),t}function $r(){return mt.lFrame.bindingIndex}function Lo(){return mt.lFrame.bindingIndex++}function Gr(n){const t=mt.lFrame,e=t.bindingIndex;return t.bindingIndex=t.bindingIndex+n,e}function wI(n,t){const e=mt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Sf(t)}function Sf(n){mt.lFrame.currentDirectiveIndex=n}function kf(n){const t=mt.lFrame.currentDirectiveIndex;return-1===t?null:n[t]}function Ry(){return mt.lFrame.currentQueryIndex}function Tf(n){mt.lFrame.currentQueryIndex=n}function DI(n){const t=n[1];return 2===t.type?t.declTNode:1===t.type?n[6]:null}function Py(n,t,e){if(e&at.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&at.Host||(r=DI(s),null===r||(s=s[15],10&r.type))););if(null===r)return!1;t=r,n=s}const i=mt.lFrame=Oy();return i.currentTNode=t,i.lView=n,!0}function qc(n){const t=Oy(),e=n[1];mt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function Oy(){const n=mt.lFrame,t=null===n?null:n.child;return null===t?Fy(n):t}function Fy(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function Ly(){const n=mt.lFrame;return mt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const Ny=Ly;function Yc(){const n=Ly();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function ni(){return mt.lFrame.selectedIndex}function vs(n){mt.lFrame.selectedIndex=n}function un(){const n=mt.lFrame;return Cf(n.tView,n.selectedIndex)}function Ja(){mt.lFrame.currentNamespace="svg"}function Kc(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[18]+=65536),(a>11>16&&(3&n[2])===t){n[2]+=2048;try{s.call(a)}finally{}}}else try{s.call(a)}finally{}}class el{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function Xc(n,t,e){const i=dn(n);let r=0;for(;rt){o=s-1;break}}}for(;s>16}(n),i=t;for(;e>0;)i=i[15],e--;return i}let Pf=!0;function ed(n){const t=Pf;return Pf=n,t}let LI=0;const gr={};function nl(n,t){const e=Ff(n,t);if(-1!==e)return e;const i=t[1];i.firstCreatePass&&(n.injectorIndex=t.length,Of(i.data,n),Of(t,null),Of(i.blueprint,null));const r=td(n,t),s=n.injectorIndex;if(Uy(r)){const o=No(r),a=Bo(r,t),l=a[1].data;for(let c=0;c<8;c++)t[s+c]=a[o+c]|l[o+c]}return t[s+8]=r,s}function Of(n,t){n.push(0,0,0,0,0,0,0,0,t)}function Ff(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function td(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=Zy(r),null===i)return-1;if(e++,r=r[15],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return-1}function nd(n,t,e){!function NI(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(Ya)&&(i=e[Ya]),null==i&&(i=e[Ya]=LI++);const r=255&i;t.data[n+(r>>5)]|=1<=0?255&t:jI:t}(e);if("function"==typeof s){if(!Py(t,n,i))return i&at.Host?Gy(r,0,i):Wy(t,e,i,r);try{const o=s(i);if(null!=o||i&at.Optional)return o;Nc()}finally{Ny()}}else if("number"==typeof s){let o=null,a=Ff(n,t),l=-1,c=i&at.Host?t[16][6]:null;for((-1===a||i&at.SkipSelf)&&(l=-1===a?td(n,t):t[a+8],-1!==l&&Qy(i,!1)?(o=t[1],a=No(l),t=Bo(l,t)):a=-1);-1!==a;){const d=t[1];if(Ky(s,a,d.data)){const f=VI(a,t,e,o,i,c);if(f!==gr)return f}l=t[a+8],-1!==l&&Qy(i,t[1].data[a+8]===c)&&Ky(s,a,t)?(o=d,a=No(l),t=Bo(l,t)):a=-1}}return r}function VI(n,t,e,i,r,s){const o=t[1],a=o.data[n+8],d=id(a,o,e,null==i?zc(a)&&Pf:i!=o&&0!=(3&a.type),r&at.Host&&s===a);return null!==d?il(t,o,d,a):gr}function id(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,d=s>>20,w=r?a+d:n.directiveEnd;for(let k=i?a:a+d;k=l&&j.type===e)return k}if(r){const k=o[l];if(k&&nr(k)&&k.type===e)return l}return null}function il(n,t,e,i){let r=n[e];const s=t.data;if(function II(n){return n instanceof el}(r)){const o=r;o.resolving&&function LA(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new Be(-200,`Circular dependency in DI detected for ${n}${e}`)}(function Ht(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():gt(n)}(s[e]));const a=ed(o.canSeeViewProviders);o.resolving=!0;const l=o.injectImpl?pr(o.injectImpl):null;Py(n,i,at.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function TI(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=wy(t);(e.preOrderHooks||(e.preOrderHooks=[])).push(n,o),(e.preOrderCheckHooks||(e.preOrderCheckHooks=[])).push(n,o)}r&&(e.preOrderHooks||(e.preOrderHooks=[])).push(0-n,r),s&&((e.preOrderHooks||(e.preOrderHooks=[])).push(n,s),(e.preOrderCheckHooks||(e.preOrderCheckHooks=[])).push(n,s))}(e,s[e],t)}finally{null!==l&&pr(l),ed(a),o.resolving=!1,Ny()}}return r}function Ky(n,t,e){return!!(e[t+(n>>5)]&1<{const t=n.prototype.constructor,e=t[zr]||Lf(t),i=Object.prototype;let r=Object.getPrototypeOf(n.prototype).constructor;for(;r&&r!==i;){const s=r[zr]||Lf(r);if(s&&s!==e)return s;r=Object.getPrototypeOf(r)}return s=>new s})}function Lf(n){return af(n)?()=>{const t=Lf(pt(n));return t&&t()}:Ws(n)}function Zy(n){const t=n[1],e=t.type;return 2===e?t.declTNode:1===e?n[6]:null}function ii(n){return function BI(n,t){if("class"===t)return n.classes;if("style"===t)return n.styles;const e=n.attrs;if(e){const i=e.length;let r=0;for(;r{const i=function Nf(n){return function(...e){if(n){const i=n(...e);for(const r in i)this[r]=i[r]}}}(t);function r(...s){if(this instanceof r)return i.apply(this,s),this;const o=new r(...s);return a.annotation=o,a;function a(l,c,d){const f=l.hasOwnProperty(jo)?l[jo]:Object.defineProperty(l,jo,{value:[]})[jo];for(;f.length<=d;)f.push(null);return(f[d]=f[d]||[]).push(o),l}}return e&&(r.prototype=Object.create(e.prototype)),r.prototype.ngMetadataName=n,r.annotationCls=r,r})}class De{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Ie({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const $I=new De("AnalyzeForEntryComponents");function Di(n,t){void 0===t&&(t=n);for(let e=0;eArray.isArray(e)?Wr(e,t):t(e))}function Jy(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function rd(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}function ol(n,t){const e=[];for(let i=0;i=0?n[1|i]=e:(i=~i,function qI(n,t,e,i){let r=n.length;if(r==t)n.push(e,i);else if(1===r)n.push(i,n[0]),n[0]=e;else{for(r--,n.push(n[r-1],n[r]);r>t;)n[r]=n[r-2],r--;n[t]=e,n[t+1]=i}}(n,i,t,e)),i}function Vf(n,t){const e=$o(n,t);if(e>=0)return n[1|e]}function $o(n,t){return function nb(n,t,e){let i=0,r=n.length>>e;for(;r!==i;){const s=i+(r-i>>1),o=n[s<t?r=s:i=s+1}return~(r<({token:n})),-1),Hn=cl(zo("Optional"),8),ir=cl(zo("SkipSelf"),4);let hd;function Wo(n){var t;return(null===(t=function zf(){if(void 0===hd&&(hd=null,qt.trustedTypes))try{hd=qt.trustedTypes.createPolicy("angular",{createHTML:n=>n,createScript:n=>n,createScriptURL:n=>n})}catch(n){}return hd}())||void 0===t?void 0:t.createHTML(n))||n}class qs{constructor(t){this.changingThisBreaksApplicationSecurity=t}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see https://g.co/ng/security#xss)`}}class vR extends qs{getTypeName(){return"HTML"}}class yR extends qs{getTypeName(){return"Style"}}class bR extends qs{getTypeName(){return"Script"}}class wR extends qs{getTypeName(){return"URL"}}class CR extends qs{getTypeName(){return"ResourceURL"}}function Mi(n){return n instanceof qs?n.changingThisBreaksApplicationSecurity:n}function _r(n,t){const e=mb(n);if(null!=e&&e!==t){if("ResourceURL"===e&&"URL"===t)return!0;throw new Error(`Required a safe ${t}, got a ${e} (see https://g.co/ng/security#xss)`)}return e===t}function mb(n){return n instanceof qs&&n.getTypeName()||null}class kR{constructor(t){this.inertDocumentHelper=t}getInertBodyElement(t){t=""+t;try{const e=(new window.DOMParser).parseFromString(Wo(t),"text/html").body;return null===e?this.inertDocumentHelper.getInertBodyElement(t):(e.removeChild(e.firstChild),e)}catch(e){return null}}}class TR{constructor(t){if(this.defaultDoc=t,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert"),null==this.inertDocument.body){const e=this.inertDocument.createElement("html");this.inertDocument.appendChild(e);const i=this.inertDocument.createElement("body");e.appendChild(i)}}getInertBodyElement(t){const e=this.inertDocument.createElement("template");if("content"in e)return e.innerHTML=Wo(t),e;const i=this.inertDocument.createElement("body");return i.innerHTML=Wo(t),this.defaultDoc.documentMode&&this.stripCustomNsAttrs(i),i}stripCustomNsAttrs(t){const e=t.attributes;for(let r=e.length-1;0hl(t.trim())).join(", ")),this.buf.push(" ",o,'="',Cb(l),'"')}var n;return this.buf.push(">"),!0}endElement(t){const e=t.nodeName.toLowerCase();Gf.hasOwnProperty(e)&&!vb.hasOwnProperty(e)&&(this.buf.push(""))}chars(t){this.buf.push(Cb(t))}checkClobberedElement(t,e){if(e&&(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${t.outerHTML}`);return e}}const FR=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,LR=/([^\#-~ |!])/g;function Cb(n){return n.replace(/&/g,"&").replace(FR,function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"}).replace(LR,function(t){return"&#"+t.charCodeAt(0)+";"}).replace(//g,">")}let pd;function Db(n,t){let e=null;try{pd=pd||function gb(n){const t=new TR(n);return function AR(){try{return!!(new window.DOMParser).parseFromString(Wo(""),"text/html")}catch(n){return!1}}()?new kR(t):t}(n);let i=t?String(t):"";e=pd.getInertBodyElement(i);let r=5,s=i;do{if(0===r)throw new Error("Failed to sanitize html because the input is unstable");r--,i=s,s=e.innerHTML,e=pd.getInertBodyElement(i)}while(i!==s);return Wo((new OR).sanitizeChildren(Yf(e)||e))}finally{if(e){const i=Yf(e)||e;for(;i.firstChild;)i.removeChild(i.firstChild)}}}function Yf(n){return"content"in n&&function NR(n){return n.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===n.nodeName}(n)?n.content:null}var Ut=(()=>((Ut=Ut||{})[Ut.NONE=0]="NONE",Ut[Ut.HTML=1]="HTML",Ut[Ut.STYLE=2]="STYLE",Ut[Ut.SCRIPT=3]="SCRIPT",Ut[Ut.URL=4]="URL",Ut[Ut.RESOURCE_URL=5]="RESOURCE_URL",Ut))();function Kf(n){const t=function pl(){const n=ke();return n&&n[12]}();return t?t.sanitize(Ut.URL,n)||"":_r(n,"URL")?Mi(n):hl(gt(n))}function Zf(n){return n.ngOriginalError}class qr{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&Zf(t);for(;e&&Zf(e);)e=Zf(e);return e||null}}const Xf=new Map;let JR=0;const ep="__ngContext__";function qn(n,t){hi(t)?(n[ep]=t[20],function t1(n){Xf.set(n[20],n)}(t)):n[ep]=t}function ml(n){const t=n[ep];return"number"==typeof t?function xb(n){return Xf.get(n)||null}(t):t||null}function tp(n){const t=ml(n);return t?hi(t)?t:t.lView:null}const u1=(()=>("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(qt))();function Yr(n){return n instanceof Function?n():n}var xi=(()=>((xi=xi||{})[xi.Important=1]="Important",xi[xi.DashCase=2]="DashCase",xi))();function ip(n,t){return undefined(n,t)}function gl(n){const t=n[3];return tr(t)?t[3]:t}function rp(n){return Fb(n[13])}function sp(n){return Fb(n[4])}function Fb(n){for(;null!==n&&!tr(n);)n=n[4];return n}function Yo(n,t,e,i,r){if(null!=i){let s,o=!1;tr(i)?s=i:hi(i)&&(o=!0,i=i[0]);const a=Cn(i);0===n&&null!==e?null==r?jb(t,e,a):Ys(t,e,a,r||null,!0):1===n&&null!==e?Ys(t,e,a,r||null,!0):2===n?function Kb(n,t,e){const i=md(n,t);i&&function x1(n,t,e,i){dn(n)?n.removeChild(t,e,i):t.removeChild(e)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function T1(n,t,e,i,r){const s=e[7];s!==Cn(e)&&Yo(t,n,i,s,r);for(let a=10;a0&&(n[e-1][4]=i[4]);const s=rd(n,10+t);!function v1(n,t){_l(n,t,t[11],2,null,null),t[0]=null,t[6]=null}(i[1],i);const o=s[19];null!==o&&o.detachView(s[1]),i[3]=null,i[4]=null,i[2]&=-65}return i}function Bb(n,t){if(!(128&t[2])){const e=t[11];dn(e)&&e.destroyNode&&_l(n,t,e,3,null,null),function w1(n){let t=n[13];if(!t)return cp(n[1],n);for(;t;){let e=null;if(hi(t))e=t[13];else{const i=t[10];i&&(e=i)}if(!e){for(;t&&!t[4]&&t!==n;)hi(t)&&cp(t[1],t),t=t[3];null===t&&(t=n),hi(t)&&cp(t[1],t),e=t&&t[4]}t=e}}(t)}}function cp(n,t){if(!(128&t[2])){t[2]&=-65,t[2]|=128,function M1(n,t){let e;if(null!=n&&null!=(e=n.destroyHooks))for(let i=0;i=0?i[r=c]():i[r=-c].unsubscribe(),s+=2}else{const o=i[r=e[s+1]];e[s].call(o)}if(null!==i){for(let s=r+1;ss?"":r[f+1].toLowerCase();const k=8&i?w:null;if(k&&-1!==Xb(k,c,0)||2&i&&c!==w){if(rr(i))return!1;o=!0}}}}else{if(!o&&!rr(i)&&!rr(l))return!1;if(o&&rr(l))continue;o=!1,i=l|1&i}}return rr(i)||o}function rr(n){return 0==(1&n)}function O1(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!rr(o)&&(t+=n0(s,r),r=""),i=o,s=s||!rr(i);e++}return""!==r&&(t+=n0(s,r)),t}const _t={};function Ee(n){r0(Lt(),ke(),ni()+n,!1)}function r0(n,t,e,i){if(!i)if(3==(3&t[2])){const s=n.preOrderCheckHooks;null!==s&&Qc(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Zc(t,s,0,e)}vs(e)}const l0=new De("ENVIRONMENT_INITIALIZER"),c0=new De("INJECTOR_DEF_TYPES");function q1(...n){return{\u0275providers:d0(0,n)}}function d0(n,...t){const e=[],i=new Set;let r;return Wr(t,s=>{const o=s;pp(o,e,[],i)&&(r||(r=[]),r.push(o))}),void 0!==r&&u0(r,e),e}function u0(n,t){for(let e=0;e{t.push(s)})}}function pp(n,t,e,i){if(!(n=pt(n)))return!1;let r=null,s=hy(n);const o=!s&&Qt(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=hy(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const c of l)pp(c,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let c;i.add(r);try{Wr(s.imports,d=>{pp(d,t,e,i)&&(c||(c=[]),c.push(d))})}finally{}void 0!==c&&u0(c,t)}if(!a){const c=Ws(r)||(()=>new r);t.push({provide:r,useFactory:c,deps:jt},{provide:c0,useValue:r,multi:!0},{provide:l0,useValue:()=>te(r),multi:!0})}const l=s.providers;null==l||a||Wr(l,d=>{t.push(d)})}}return r!==n&&void 0!==n.providers}const Y1=Yt({provide:String,useValue:Yt});function mp(n){return null!==n&&"object"==typeof n&&Y1 in n}function Ks(n){return"function"==typeof n}const gp=new De("INJECTOR",-1);class p0{get(t,e=al){if(e===al){const i=new Error(`NullInjectorError: No provider for ${Kt(t)}!`);throw i.name="NullInjectorError",i}return e}}const _p=new De("Set Injector scope."),vd={},Q1={};let vp;function yp(){return void 0===vp&&(vp=new p0),vp}class Qs{}class m0 extends Qs{constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,wp(t,o=>this.processProvider(o)),this.records.set(gp,Ko(void 0,this)),r.has("environment")&&this.records.set(Qs,Ko(void 0,this));const s=this.records.get(_p);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(c0.multi,jt,at.Self))}get destroyed(){return this._destroyed}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const t of this._ngOnDestroyHooks)t.ngOnDestroy();for(const t of this._onDestroyHooks)t()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),this._onDestroyHooks.length=0}}onDestroy(t){this._onDestroyHooks.push(t)}get(t,e=al,i=at.Default){this.assertNotDestroyed();const r=ad(this),s=pr(void 0);try{if(!(i&at.SkipSelf)){let a=this.records.get(t);if(void 0===a){const l=function tP(n){return"function"==typeof n||"object"==typeof n&&n instanceof De}(t)&&lf(t);a=l&&this.injectableDefInScope(l)?Ko(bp(t),vd):null,this.records.set(t,a)}if(null!=a)return this.hydrate(t,a)}return(i&at.Self?yp():this.parent).get(t,e=i&at.Optional&&e===al?null:e)}catch(o){if("NullInjectorError"===o.name){if((o[od]=o[od]||[]).unshift(Kt(t)),r)throw o;return function sR(n,t,e,i){const r=n[od];throw t[ib]&&r.unshift(t[ib]),n.message=function oR(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=Kt(t);if(Array.isArray(t))r=t.map(Kt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):Kt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(tR,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[od]=null,n}(o,t,"R3InjectorError",this.source)}throw o}finally{pr(s),ad(r)}}resolveInjectorInitializers(){const t=ad(this),e=pr(void 0);try{const i=this.get(l0.multi,jt,at.Self);for(const r of i)r()}finally{ad(t),pr(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(Kt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Be(205,!1)}processProvider(t){let e=Ks(t=pt(t))?t:pt(t&&t.provide);const i=function X1(n){return mp(n)?Ko(void 0,n.useValue):Ko(g0(n),vd)}(t);if(Ks(t)||!0!==t.multi)this.records.get(e);else{let r=this.records.get(e);r||(r=Ko(void 0,vd,!0),r.factory=()=>Uf(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===vd&&(e.value=Q1,e.value=e.factory()),"object"==typeof e.value&&e.value&&function eP(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=pt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}}function bp(n){const t=lf(n),e=null!==t?t.factory:Ws(n);if(null!==e)return e;if(n instanceof De)throw new Be(204,!1);if(n instanceof Function)return function Z1(n){const t=n.length;if(t>0)throw ol(t,"?"),new Be(204,!1);const e=function jA(n){const t=n&&(n[Bc]||n[fy]);if(t){const e=function UA(n){if(n.hasOwnProperty("name"))return n.name;const t=(""+n).match(/^function\s*([^\s(]+)/);return null===t?"":t[1]}(n);return console.warn(`DEPRECATED: DI is instantiating a token "${e}" that inherits its @Injectable decorator but does not provide one itself.\nThis will become an error in a future version of Angular. Please add @Injectable() to the "${e}" class.`),t}return null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new Be(204,!1)}function g0(n,t,e){let i;if(Ks(n)){const r=pt(n);return Ws(r)||bp(r)}if(mp(n))i=()=>pt(n.useValue);else if(function f0(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Uf(n.deps||[]));else if(function h0(n){return!(!n||!n.useExisting)}(n))i=()=>te(pt(n.useExisting));else{const r=pt(n&&(n.useClass||n.provide));if(!function J1(n){return!!n.deps}(n))return Ws(r)||bp(r);i=()=>new r(...Uf(n.deps))}return i}function Ko(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function nP(n){return!!n.\u0275providers}function wp(n,t){for(const e of n)Array.isArray(e)?wp(e,t):nP(e)?wp(e.\u0275providers,t):t(e)}function _0(n,t=null,e=null,i){const r=v0(n,t,e,i);return r.resolveInjectorInitializers(),r}function v0(n,t=null,e=null,i,r=new Set){const s=[e||jt,q1(n)];return i=i||("object"==typeof n?void 0:Kt(n)),new m0(s,t||yp(),i||null,r)}let Jt=(()=>{class n{static create(e,i){var r;if(Array.isArray(e))return _0({name:""},i,e,"");{const s=null!==(r=e.name)&&void 0!==r?r:"";return _0({name:s},e.parent,e.providers,s)}}}return n.THROW_IF_NOT_FOUND=al,n.NULL=new p0,n.\u0275prov=Ie({token:n,providedIn:"any",factory:()=>te(gp)}),n.__NG_ELEMENT_ID__=-1,n})();function x(n,t=at.Default){const e=ke();return null===e?te(n,t):qy(Sn(),e,pt(n),t)}function bs(){throw new Error("invalid")}function bd(n,t){return n<<17|t<<2}function sr(n){return n>>17&32767}function Tp(n){return 2|n}function Kr(n){return(131068&n)>>2}function Ap(n,t){return-131069&n|t<<2}function Ip(n){return 1|n}function B0(n,t){const e=n.contentQueries;if(null!==e)for(let i=0;i22&&r0(n,t,22,!1),e(i,r)}finally{vs(s)}}function H0(n,t,e){if(mf(t)){const r=t.directiveEnd;for(let s=t.directiveStart;s0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(a)!=l&&a.push(l),a.push(i,r,o)}}function q0(n,t){null!==n.hostBindings&&n.hostBindings(1,t)}function Y0(n,t){t.flags|=2,(n.components||(n.components=[])).push(t.index)}function GP(n,t,e){if(e){if(t.exportAs)for(let i=0;i0&&Gp(e)}}function Gp(n){for(let i=rp(n);null!==i;i=sp(i))for(let r=10;r0&&Gp(s)}const e=n[1].components;if(null!==e)for(let i=0;i0&&Gp(r)}}function XP(n,t){const e=Ci(t,n),i=e[1];(function JP(n,t){for(let e=t.length;ePromise.resolve(null))();function J0(n){return n[7]||(n[7]=[])}function ew(n){return n.cleanup||(n.cleanup=[])}function tw(n,t,e){return(null===n||nr(n))&&(e=function uI(n){for(;Array.isArray(n);){if("object"==typeof n[1])return n;n=n[0]}return null}(e[t.index])),e[11]}function nw(n,t){const e=n[9],i=e?e.get(qr,null):null;i&&i.handleError(t)}function iw(n,t,e,i,r){for(let s=0;s=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Jc(r.hostAttrs,e=Jc(e,r.hostAttrs))}}(i)}function Zp(n){return n===Ao?{}:n===jt?[]:n}function pO(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function mO(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function gO(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}let xd=null;function Zs(){if(!xd){const n=qt.Symbol;if(n&&n.iterator)xd=n.iterator;else{const t=Object.getOwnPropertyNames(Map.prototype);for(let e=0;ea(Cn(Oe[i.index])):i.index;if(dn(e)){let Oe=null;if(!a&&l&&(Oe=function SO(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==Oe)(Oe.__ngLastListenerFn__||Oe).__ngNextListenerFn__=s,Oe.__ngLastListenerFn__=s,k=!1;else{s=tm(i,t,f,s,!1);const ft=e.listen(ce,r,s);w.push(s,ft),d&&d.push(r,he,Te,Te+1)}}else s=tm(i,t,f,s,!0),ce.addEventListener(r,s,o),w.push(s),d&&d.push(r,he,Te,o)}else s=tm(i,t,f,s,!1);const j=i.outputs;let K;if(k&&null!==j&&(K=j[r])){const ae=K.length;if(ae)for(let ce=0;ce0;)t=t[15],n--;return t}(n,mt.lFrame.contextLView))[8]}(n)}function kO(n,t){let e=null;const i=function F1(n){const t=n.attrs;if(null!=t){const e=t.indexOf(5);if(0==(1&e))return t[e+1]}return null}(n);for(let r=0;r=0}const Tn={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function Lw(n){return n.substring(Tn.key,Tn.keyEnd)}function Nw(n,t){const e=Tn.textEnd;return e===t?-1:(t=Tn.keyEnd=function FO(n,t,e){for(;t32;)t++;return t}(n,Tn.key=t,e),da(n,t,e))}function da(n,t,e){for(;t=0;e=Nw(t,e))Ei(n,Lw(t),!0)}function ar(n,t,e,i){const r=ke(),s=Lt(),o=Gr(2);s.firstUpdatePass&&zw(s,n,o,i),t!==_t&&Yn(r,o,t)&&Gw(s,s.data[ni()],r,r[11],n,r[o+1]=function WO(n,t){return null==n||("string"==typeof t?n+=t:"object"==typeof n&&(n=Kt(Mi(n)))),n}(t,e),i,o)}function Uw(n,t){return t>=n.expandoStartIndex}function zw(n,t,e,i){const r=n.data;if(null===r[e+1]){const s=r[ni()],o=Uw(n,e);qw(s,i)&&null===t&&!o&&(t=!1),t=function HO(n,t,e,i){const r=kf(n);let s=i?t.residualClasses:t.residualStyles;if(null===r)0===(i?t.classBindings:t.styleBindings)&&(e=Dl(e=im(null,n,t,e,i),t.attrs,i),s=null);else{const o=t.directiveStylingLast;if(-1===o||n[o]!==r)if(e=im(r,n,t,e,i),null===s){let l=function jO(n,t,e){const i=e?t.classBindings:t.styleBindings;if(0!==Kr(i))return n[sr(i)]}(n,t,i);void 0!==l&&Array.isArray(l)&&(l=im(null,n,t,l[1],i),l=Dl(l,t.attrs,i),function UO(n,t,e,i){n[sr(e?t.classBindings:t.styleBindings)]=i}(n,t,i,l))}else s=function zO(n,t,e){let i;const r=t.directiveEnd;for(let s=1+t.directiveStylingLast;s0)&&(c=!0)}else d=e;if(r)if(0!==l){const w=sr(n[a+1]);n[i+1]=bd(w,a),0!==w&&(n[w+1]=Ap(n[w+1],i)),n[a+1]=function yP(n,t){return 131071&n|t<<17}(n[a+1],i)}else n[i+1]=bd(a,0),0!==a&&(n[a+1]=Ap(n[a+1],i)),a=i;else n[i+1]=bd(l,0),0===a?a=i:n[l+1]=Ap(n[l+1],i),l=i;c&&(n[i+1]=Tp(n[i+1])),Fw(n,d,i,!0),Fw(n,d,i,!1),function AO(n,t,e,i,r){const s=r?n.residualClasses:n.residualStyles;null!=s&&"string"==typeof t&&$o(s,t)>=0&&(e[i+1]=Ip(e[i+1]))}(t,d,n,i,s),o=bd(a,l),s?t.classBindings=o:t.styleBindings=o}(r,s,t,e,o,i)}}function im(n,t,e,i,r){let s=null;const o=e.directiveEnd;let a=e.directiveStylingLast;for(-1===a?a=e.directiveStart:a++;a0;){const l=n[r],c=Array.isArray(l),d=c?l[1]:l,f=null===d;let w=e[r+1];w===_t&&(w=f?jt:void 0);let k=f?Vf(w,i):d===i?w:void 0;if(c&&!Ad(k)&&(k=Vf(l,i)),Ad(k)&&(a=k,o))return a;const j=n[r+1];r=o?sr(j):Kr(j)}if(null!==t){let l=s?t.residualClasses:t.residualStyles;null!=l&&(a=Vf(l,i))}return a}function Ad(n){return void 0!==n}function qw(n,t){return 0!=(n.flags&(t?16:32))}function Ue(n,t=""){const e=ke(),i=Lt(),r=n+22,s=i.firstCreatePass?Zo(i,r,1,t,null):i.data[r],o=e[r]=function op(n,t){return dn(n)?n.createText(t):n.createTextNode(t)}(e[11],t);gd(i,e,o,s),mr(s,!1)}function Kn(n){return Ln("",n,""),Kn}function Ln(n,t,e){const i=ke(),r=ta(i,n,t,e);return r!==_t&&Qr(i,ni(),r),Ln}function El(n,t,e,i,r){const s=ke(),o=na(s,n,t,e,i,r);return o!==_t&&Qr(s,ni(),o),El}function rm(n,t,e,i,r,s,o){const a=ke(),l=ia(a,n,t,e,i,r,s,o);return l!==_t&&Qr(a,ni(),l),rm}function sm(n,t,e,i,r,s,o,a,l,c,d){const f=ke(),w=sa(f,n,t,e,i,r,s,o,a,l,c,d);return w!==_t&&Qr(f,ni(),w),sm}function om(n,t,e){!function lr(n,t,e,i){const r=Lt(),s=Gr(2);r.firstUpdatePass&&zw(r,null,s,i);const o=ke();if(e!==_t&&Yn(o,s,e)){const a=r.data[ni()];if(qw(a,i)&&!Uw(r,s)){let l=i?a.classesWithoutHost:a.stylesWithoutHost;null!==l&&(e=sf(l,e||"")),Jp(r,a,o,e,i)}else!function GO(n,t,e,i,r,s,o,a){r===_t&&(r=jt);let l=0,c=0,d=0((He=He||{})[He.LocaleId=0]="LocaleId",He[He.DayPeriodsFormat=1]="DayPeriodsFormat",He[He.DayPeriodsStandalone=2]="DayPeriodsStandalone",He[He.DaysFormat=3]="DaysFormat",He[He.DaysStandalone=4]="DaysStandalone",He[He.MonthsFormat=5]="MonthsFormat",He[He.MonthsStandalone=6]="MonthsStandalone",He[He.Eras=7]="Eras",He[He.FirstDayOfWeek=8]="FirstDayOfWeek",He[He.WeekendRange=9]="WeekendRange",He[He.DateFormat=10]="DateFormat",He[He.TimeFormat=11]="TimeFormat",He[He.DateTimeFormat=12]="DateTimeFormat",He[He.NumberSymbols=13]="NumberSymbols",He[He.NumberFormats=14]="NumberFormats",He[He.CurrencyCode=15]="CurrencyCode",He[He.CurrencySymbol=16]="CurrencySymbol",He[He.CurrencyName=17]="CurrencyName",He[He.Currencies=18]="Currencies",He[He.Directionality=19]="Directionality",He[He.PluralCase=20]="PluralCase",He[He.ExtraData=21]="ExtraData",He))();const ha="en-US";let dC=ha;function cm(n,t,e,i,r){if(n=pt(n),Array.isArray(n))for(let s=0;s>20;if(Ks(n)||!n.multi){const k=new el(l,r,x),j=um(a,t,r?d:d+w,f);-1===j?(nd(nl(c,o),s,a),dm(s,n,t.length),t.push(a),c.directiveStart++,c.directiveEnd++,r&&(c.providerIndexes+=1048576),e.push(k),o.push(k)):(e[j]=k,o[j]=k)}else{const k=um(a,t,d+w,f),j=um(a,t,d,d+w),K=k>=0&&e[k],ae=j>=0&&e[j];if(r&&!ae||!r&&!K){nd(nl(c,o),s,a);const ce=function cL(n,t,e,i,r){const s=new el(n,e,x);return s.multi=[],s.index=t,s.componentProviders=0,FC(s,r,i&&!e),s}(r?lL:aL,e.length,r,i,l);!r&&ae&&(e[j].providerFactory=ce),dm(s,n,t.length,0),t.push(a),c.directiveStart++,c.directiveEnd++,r&&(c.providerIndexes+=1048576),e.push(ce),o.push(ce)}else dm(s,n,k>-1?k:j,FC(e[r?j:k],l,!r&&i));!r&&i&&ae&&e[j].componentProviders++}}}function dm(n,t,e,i){const r=Ks(t),s=function K1(n){return!!n.useClass}(t);if(r||s){const l=(s?pt(t.useClass):t).prototype.ngOnDestroy;if(l){const c=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const d=c.indexOf(e);-1===d?c.push(e,[i,l]):c[d+1].push(i,l)}else c.push(e,l)}}}function FC(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function um(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function oL(n,t,e){const i=Lt();if(i.firstCreatePass){const r=nr(n);cm(e,i.data,i.blueprint,r,!0),cm(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class uL{resolveComponentFactory(t){throw function dL(n){const t=Error(`No component factory found for ${Kt(n)}. Did you add it to @NgModule.entryComponents?`);return t.ngComponent=n,t}(t)}}let io=(()=>{class n{}return n.NULL=new uL,n})();class Ds{}class NC{}class BC{}function fL(){return pa(Sn(),ke())}function pa(n,t){return new Je(Bi(n,t))}let Je=(()=>{class n{constructor(e){this.nativeElement=e}}return n.__NG_ELEMENT_ID__=fL,n})();function pL(n){return n instanceof Je?n.nativeElement:n}class Tl{}let Xr=(()=>{class n{}return n.__NG_ELEMENT_ID__=()=>function gL(){const n=ke(),e=Ci(Sn().index,n);return function mL(n){return n[11]}(hi(e)?e:n)}(),n})(),_L=(()=>{class n{}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:()=>null}),n})();class ro{constructor(t){this.full=t,this.major=t.split(".")[0],this.minor=t.split(".")[1],this.patch=t.split(".").slice(2).join(".")}}const vL=new ro("14.0.1"),fm={};function Ld(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];if(null!==s&&i.push(Cn(s)),tr(s))for(let a=10;a-1&&(lp(t,i),rd(e,i))}this._attachedToViewContainer=!1}Bb(this._lView[1],this._lView)}onDestroy(t){$0(this._lView[1],this._lView,null,t)}markForCheck(){Wp(this._cdRefInjectingView||this._lView)}detach(){this._lView[2]&=-65}reattach(){this._lView[2]|=64}detectChanges(){!function Yp(n,t,e){const i=t[10];i.begin&&i.begin();try{Jo(n,t,n.template,e)}catch(r){throw nw(t,r),r}finally{i.end&&i.end()}}(this._lView[1],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Be(902,"");this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function b1(n,t){_l(n,t,t[11],2,null,null)}(this._lView[1],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new Be(902,"");this._appRef=t}}class yL extends Al{constructor(t){super(t),this._view=t}detectChanges(){X0(this._view)}checkNoChanges(){}get context(){return null}}class pm extends io{constructor(t){super(),this.ngModule=t}resolveComponentFactory(t){const e=Qt(t);return new mm(e,this.ngModule)}}function VC(n){const t=[];for(let e in n)n.hasOwnProperty(e)&&t.push({propName:n[e],templateName:e});return t}class wL{constructor(t,e){this.injector=t,this.parentInjector=e}get(t,e,i){const r=this.injector.get(t,fm,i);return r!==fm||e===fm?r:this.parentInjector.get(t,e,i)}}class mm extends BC{constructor(t,e){super(),this.componentDef=t,this.ngModule=e,this.componentType=t.type,this.selector=function H1(n){return n.map(V1).join(",")}(t.selectors),this.ngContentSelectors=t.ngContentSelectors?t.ngContentSelectors:[],this.isBoundToModule=!!e}get inputs(){return VC(this.componentDef.inputs)}get outputs(){return VC(this.componentDef.outputs)}create(t,e,i,r){let s=(r=r||this.ngModule)instanceof Qs?r:null==r?void 0:r.injector;s&&null!==this.componentDef.getStandaloneInjector&&(s=this.componentDef.getStandaloneInjector(s)||s);const o=s?new wL(t,s):t,a=o.get(Tl,Ey),l=o.get(_L,null),c=a.createRenderer(null,this.componentDef),d=this.componentDef.selectors[0][0]||"div",f=i?function z0(n,t,e){if(dn(n))return n.selectRootElement(t,e===Ji.ShadowDom);let i="string"==typeof t?n.querySelector(t):t;return i.textContent="",i}(c,i,this.componentDef.encapsulation):ap(a.createRenderer(null,this.componentDef),d,function bL(n){const t=n.toLowerCase();return"svg"===t?"svg":"math"===t?"math":null}(d)),w=this.componentDef.onPush?288:272,k=function pw(n,t){return{components:[],scheduler:n||u1,clean:tO,playerHandler:t||null,flags:0}}(),j=Dd(0,null,null,1,0,null,null,null,null,null),K=vl(null,j,k,w,null,null,a,c,l,o,null);let ae,ce;qc(K);try{const Te=function hw(n,t,e,i,r,s){const o=e[1];e[22]=n;const l=Zo(o,22,2,"#host",null),c=l.mergedAttrs=t.hostAttrs;null!==c&&(Md(l,c,!0),null!==n&&(Xc(r,n,c),null!==l.classes&&fp(r,n,l.classes),null!==l.styles&&Zb(r,n,l.styles)));const d=i.createRenderer(n,t),f=vl(e,j0(t),null,t.onPush?32:16,e[22],l,i,d,s||null,null,null);return o.firstCreatePass&&(nd(nl(l,e),o,t.type),Y0(o,l),K0(l,e.length,1)),Ed(e,f),e[22]=f}(f,this.componentDef,K,a,c);if(f)if(i)Xc(c,f,["ng-version",vL.full]);else{const{attrs:he,classes:Oe}=function j1(n){const t=[],e=[];let i=1,r=2;for(;i0&&fp(c,f,Oe.join(" "))}if(ce=Cf(j,22),void 0!==e){const he=ce.projection=[];for(let Oe=0;Oee()),this.destroyCbs=null}onDestroy(t){this.destroyCbs.push(t)}}class gm extends NC{constructor(t){super(),this.moduleType=t}create(t){return new HC(this.moduleType,t)}}class ML extends Ds{constructor(t,e,i){super(),this.componentFactoryResolver=new pm(this),this.instance=null;const r=new m0([...t,{provide:Ds,useValue:this},{provide:io,useValue:this.componentFactoryResolver}],e||yp(),i,new Set(["environment"]));this.injector=r,r.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}function Nd(n,t=null,e=null){return new ML(n,t,e).injector}function Il(n,t){const e=n[t];return e===_t?void 0:e}function Jr(n,t){const e=Lt();let i;const r=n+22;e.firstCreatePass?(i=function BL(n,t){if(t)for(let e=t.length-1;e>=0;e--){const i=t[e];if(n===i.name)return i}}(t,e.pipeRegistry),e.data[r]=i,i.onDestroy&&(e.destroyHooks||(e.destroyHooks=[])).push(r,i.onDestroy)):i=e.data[r];const s=i.factory||(i.factory=Ws(i.type)),o=pr(x);try{const a=ed(!1),l=s();return ed(a),function EO(n,t,e,i){e>=n.data.length&&(n.data[e]=null,n.blueprint[e]=null),t[e]=i}(e,ke(),r,l),l}finally{pr(o)}}function so(n,t,e){const i=n+22,r=ke(),s=Fo(r,i);return Rl(r,i)?function jC(n,t,e,i,r,s){const o=t+e;return Yn(n,o,r)?br(n,o+1,s?i.call(s,r):i(r)):Il(n,o+1)}(r,ti(),t,s.transform,e,s):s.transform(e)}function vm(n,t,e,i){const r=n+22,s=ke(),o=Fo(s,r);return Rl(s,r)?function UC(n,t,e,i,r,s,o){const a=t+e;return Xs(n,a,r,s)?br(n,a+2,o?i.call(o,r,s):i(r,s)):Il(n,a+2)}(s,ti(),t,o.transform,e,i,o):o.transform(e,i)}function Rl(n,t){return n[1].data[t].pure}function ym(n){return t=>{setTimeout(n,void 0,t)}}const je=class UL extends ue{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){var r,s,o;let a=t,l=e||(()=>null),c=i;if(t&&"object"==typeof t){const f=t;a=null===(r=f.next)||void 0===r?void 0:r.bind(f),l=null===(s=f.error)||void 0===s?void 0:s.bind(f),c=null===(o=f.complete)||void 0===o?void 0:o.bind(f)}this.__isAsync&&(l=ym(l),a&&(a=ym(a)),c&&(c=ym(c)));const d=super.subscribe({next:a,error:l,complete:c});return t instanceof X&&t.add(d),d}};function zL(){return this._results[Zs()]()}class ma{constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=null,this.length=0,this.first=void 0,this.last=void 0;const e=Zs(),i=ma.prototype;i[e]||(i[e]=zL)}get changes(){return this._changes||(this._changes=new je)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){const i=this;i.dirty=!1;const r=Di(t);(this._changesDetected=!function GI(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{}return n.__NG_ELEMENT_ID__=WL,n})();const $L=_n,GL=class extends $L{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}createEmbeddedView(t,e){const i=this._declarationTContainer.tViews,r=vl(this._declarationLView,i,t,16,null,i.declTNode,null,null,null,null,e||null);r[17]=this._declarationLView[this._declarationTContainer.index];const o=this._declarationLView[19];return null!==o&&(r[19]=o.createEmbeddedView(i)),yl(i,r,t),new Al(r)}};function WL(){return Bd(Sn(),ke())}function Bd(n,t){return 4&n.type?new GL(t,n,pa(n,t)):null}let An=(()=>{class n{}return n.__NG_ELEMENT_ID__=qL,n})();function qL(){return YC(Sn(),ke())}const YL=An,WC=class extends YL{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return pa(this._hostTNode,this._hostLView)}get injector(){return new Vo(this._hostTNode,this._hostLView)}get parentInjector(){const t=td(this._hostTNode,this._hostLView);if(Uy(t)){const e=Bo(t,this._hostLView),i=No(t);return new Vo(e[1].data[i+8],e)}return new Vo(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=qC(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-10}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const o=t.createEmbeddedView(e||{},s);return this.insert(o,r),o}createComponent(t,e,i,r,s){const o=t&&!function sl(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new mm(Qt(t)),c=i||this.parentInjector;if(!s&&null==l.ngModule){const w=(o?c:this.parentInjector).get(Qs,null);w&&(s=w)}const d=l.create(c,r,void 0,s);return this.insert(d.hostView,a),d}insert(t,e){const i=t._lView,r=i[1];if(function fI(n){return tr(n[3])}(i)){const d=this.indexOf(t);if(-1!==d)this.detach(d);else{const f=i[3],w=new WC(f,f[6],f[3]);w.detach(w.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;!function C1(n,t,e,i){const r=10+i,s=e.length;i>0&&(e[r-1][4]=t),i0)i.push(o[a/2]);else{const c=s[a+1],d=t[-l];for(let f=10;f{class n{constructor(e){this.appInits=e,this.resolve=Hd,this.reject=Hd,this.initialized=!1,this.done=!1,this.donePromise=new Promise((i,r)=>{this.resolve=i,this.reject=r})}runInitializers(){if(this.initialized)return;const e=[],i=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let r=0;r{s.subscribe({complete:a,error:l})});e.push(o)}}Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}}return n.\u0275fac=function(e){return new(e||n)(te(Am,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Ol=new De("AppId",{providedIn:"root",factory:function vD(){return`${Im()}${Im()}${Im()}`}});function Im(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const yD=new De("Platform Initializer"),Ud=new De("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),bD=new De("appBootstrapListener"),fn=new De("AnimationModuleType");let DN=(()=>{class n{log(e){console.log(e)}warn(e){console.warn(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();const Er=new De("LocaleId",{providedIn:"root",factory:()=>ld(Er,at.Optional|at.SkipSelf)||function EN(){return"undefined"!=typeof $localize&&$localize.locale||ha}()});class xN{constructor(t,e){this.ngModuleFactory=t,this.componentFactories=e}}let Rm=(()=>{class n{compileModuleSync(e){return new gm(e)}compileModuleAsync(e){return Promise.resolve(this.compileModuleSync(e))}compileModuleAndAllComponentsSync(e){const i=this.compileModuleSync(e),s=Yr(bi(e).declarations).reduce((o,a)=>{const l=Qt(a);return l&&o.push(new mm(l)),o},[]);return new xN(i,s)}compileModuleAndAllComponentsAsync(e){return Promise.resolve(this.compileModuleAndAllComponentsSync(e))}clearCache(){}clearCacheFor(e){}getModuleId(e){}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const kN=(()=>Promise.resolve(0))();function Pm(n){"undefined"==typeof Zone?kN.then(()=>{n&&n.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",n)}class et{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new je(!1),this.onMicrotaskEmpty=new je(!1),this.onStable=new je(!1),this.onError=new je(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function TN(){let n=qt.requestAnimationFrame,t=qt.cancelAnimationFrame;if("undefined"!=typeof Zone&&n&&t){const e=n[Zone.__symbol__("OriginalDelegate")];e&&(n=e);const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:t}}().nativeRequestAnimationFrame,function RN(n){const t=()=>{!function IN(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(qt,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,Fm(n),n.isCheckStableRunning=!0,Om(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),Fm(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{try{return wD(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),CD(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return wD(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),CD(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,Fm(n),Om(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return"undefined"!=typeof Zone&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!et.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}static assertNotInAngularZone(){if(et.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,AN,Hd,Hd);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const AN={};function Om(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function Fm(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function wD(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function CD(n){n._nesting--,Om(n)}class PN{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new je,this.onMicrotaskEmpty=new je,this.onStable=new je,this.onError=new je}run(t,e,i){return t.apply(e,i)}runGuarded(t,e,i){return t.apply(e,i)}runOutsideAngular(t){return t()}runTask(t,e,i,r){return t.apply(e,i)}}const DD=new De(""),zd=new De("");let Fl,Lm=(()=>{class n{constructor(e,i,r){this._ngZone=e,this.registry=i,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,Fl||(function ON(n){Fl=n}(r),r.addToWindow(i)),this._watchAngularEvents(),e.run(()=>{this.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._didWork=!0,this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{et.assertNotInAngularZone(),Pm(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}increasePendingRequestCount(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}decreasePendingRequestCount(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}isStable(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())Pm(()=>{for(;0!==this._callbacks.length;){let e=this._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb(this._didWork)}this._didWork=!1});else{let e=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>!i.updateCb||!i.updateCb(e)||(clearTimeout(i.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(e=>({source:e.source,creationLocation:e.creationLocation,data:e.data})):[]}addCallback(e,i,r){let s=-1;i&&i>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),e(this._didWork,this.getPendingTasks())},i)),this._callbacks.push({doneCb:e,timeoutId:s,updateCb:r})}whenStable(e,i,r){if(r&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(e,i,r),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}registerApplication(e){this.registry.registerApplication(e,this)}unregisterApplication(e){this.registry.unregisterApplication(e)}findProviders(e,i,r){return[]}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(Nm),te(zd))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),Nm=(()=>{class n{constructor(){this._applications=new Map}registerApplication(e,i){this._applications.set(e,i)}unregisterApplication(e){this._applications.delete(e)}unregisterAllApplications(){this._applications.clear()}getTestability(e){return this._applications.get(e)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(e,i=!0){var r;return null!==(r=null==Fl?void 0:Fl.findTestabilityInTree(this,e,i))&&void 0!==r?r:null}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})(),Mr=null;const ED=new De("AllowMultipleToken"),MD=new De("PlatformOnDestroy");class xD{constructor(t,e){this.name=t,this.token=e}}function kD(n,t,e=[]){const i=`Platform: ${t}`,r=new De(i);return(s=[])=>{let o=Bm();if(!o||o.injector.get(ED,!1)){const a=[...e,...s,{provide:r,useValue:!0}];n?n(a):function NN(n){if(Mr&&!Mr.get(ED,!1))throw new Be(400,"");Mr=n;const t=n.get(AD);(function SD(n){const t=n.get(yD,null);t&&t.forEach(e=>e())})(n)}(function TD(n=[],t){return Jt.create({name:t,providers:[{provide:_p,useValue:"platform"},{provide:MD,useValue:()=>Mr=null},...n]})}(a,i))}return function VN(n){const t=Bm();if(!t)throw new Be(401,"");return t}()}}function Bm(){var n;return null!==(n=null==Mr?void 0:Mr.get(AD))&&void 0!==n?n:null}let AD=(()=>{class n{constructor(e){this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(e,i){const r=function HN(n,t){let e;return e="noop"===n?new PN:("zone.js"===n?void 0:n)||new et(t),e}(null==i?void 0:i.ngZone,function ID(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!(!n||!n.ngZoneEventCoalescing)||!1,shouldCoalesceRunChangeDetection:!(!n||!n.ngZoneRunCoalescing)||!1}}(i)),s=[{provide:et,useValue:r}];return r.run(()=>{const o=Jt.create({providers:s,parent:this.injector,name:e.moduleType.name}),a=e.create(o),l=a.injector.get(qr,null);if(!l)throw new Be(402,"");return r.runOutsideAngular(()=>{const c=r.onError.subscribe({next:d=>{l.handleError(d)}});a.onDestroy(()=>{$d(this._modules,a),c.unsubscribe()})}),function RD(n,t,e){try{const i=e();return Cl(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(l,r,()=>{const c=a.injector.get(jd);return c.runInitializers(),c.donePromise.then(()=>(function uC(n){yi(n,"Expected localeId to be defined"),"string"==typeof n&&(dC=n.toLowerCase().replace(/_/g,"-"))}(a.injector.get(Er,ha)||ha),this._moduleDoBootstrap(a),a))})})}bootstrapModule(e,i=[]){const r=PD({},i);return function FN(n,t,e){const i=new gm(e);return Promise.resolve(i)}(0,0,e).then(s=>this.bootstrapModuleFactory(s,r))}_moduleDoBootstrap(e){const i=e.injector.get(Ll);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(r=>i.bootstrap(r));else{if(!e.instance.ngDoBootstrap)throw new Be(403,"");e.instance.ngDoBootstrap(i)}this._modules.push(e)}onDestroy(e){this._destroyListeners.push(e)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Be(404,"");this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());const e=this._injector.get(MD,null);null==e||e(),this._destroyed=!0}get destroyed(){return this._destroyed}}return n.\u0275fac=function(e){return new(e||n)(te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();function PD(n,t){return Array.isArray(t)?t.reduce(PD,n):Object.assign(Object.assign({},n),t)}let Ll=(()=>{class n{constructor(e,i,r,s){this._zone=e,this._injector=i,this._exceptionHandler=r,this._initStatus=s,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._stable=!0,this._destroyed=!1,this._destroyListeners=[],this.componentTypes=[],this.components=[],this._onMicrotaskEmptySubscription=this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const o=new J(l=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{l.next(this._stable),l.complete()})}),a=new J(l=>{let c;this._zone.runOutsideAngular(()=>{c=this._zone.onStable.subscribe(()=>{et.assertNotInAngularZone(),Pm(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,l.next(!0))})})});const d=this._zone.onUnstable.subscribe(()=>{et.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{l.next(!1)}))});return()=>{c.unsubscribe(),d.unsubscribe()}});this.isStable=$n(o,a.pipe(dy()))}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof BC;if(!this._initStatus.done)throw!r&&function _a(n){const t=Qt(n)||Jn(n)||ei(n);return null!==t&&t.standalone}(e),new Be(405,false);let s;s=r?e:this._injector.get(io).resolveComponentFactory(e),this.componentTypes.push(s.componentType);const o=function LN(n){return n.isBoundToModule}(s)?void 0:this._injector.get(Ds),l=s.create(Jt.NULL,[],i||s.selector,o),c=l.location.nativeElement,d=l.injector.get(DD,null);return null==d||d.registerApplication(c),l.onDestroy(()=>{this.detachView(l.hostView),$d(this.components,l),null==d||d.unregisterApplication(c)}),this._loadComponent(l),l}tick(){if(this._runningTick)throw new Be(101,"");try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(e))}finally{this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;$d(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e),this._injector.get(bD,[]).concat(this._bootstrapListeners).forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>$d(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new Be(406,false);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(Jt),te(qr),te(jd))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function $d(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let FD=!0,en=(()=>{class n{}return n.__NG_ELEMENT_ID__=zN,n})();function zN(n){return function $N(n,t,e){if(zc(n)&&!e){const i=Ci(n.index,t);return new Al(i,i)}return 47&n.type?new Al(t[16],t):null}(Sn(),ke(),16==(16&n))}class HD{constructor(){}supports(t){return bl(t)}create(t){return new QN(t)}}const KN=(n,t)=>t;class QN{constructor(t){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=t||KN}forEachItem(t){let e;for(e=this._itHead;null!==e;e=e._next)t(e)}forEachOperation(t){let e=this._itHead,i=this._removalsHead,r=0,s=null;for(;e||i;){const o=!i||e&&e.currentIndex{o=this._trackByFn(r,a),null!==e&&Object.is(e.trackById,o)?(i&&(e=this._verifyReinsertion(e,a,o,r)),Object.is(e.item,a)||this._addIdentityChange(e,a)):(e=this._mismatch(e,a,o,r),i=!0),e=e._next,r++}),this.length=r;return this._truncate(e),this.collection=t,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let t;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=t._nextMoved)t.previousIndex=t.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(t,e,i,r){let s;return null===t?s=this._itTail:(s=t._prev,this._remove(t)),null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._reinsertAfter(t,s,r)):null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(i,r))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._moveAfter(t,s,r)):t=this._addAfter(new ZN(e,i),s,r),t}_verifyReinsertion(t,e,i,r){let s=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null);return null!==s?t=this._reinsertAfter(s,t._prev,r):t.currentIndex!=r&&(t.currentIndex=r,this._addToMoves(t,r)),t}_truncate(t){for(;null!==t;){const e=t._next;this._addToRemovals(this._unlink(t)),t=e}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(t,e,i){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);const r=t._prevRemoved,s=t._nextRemoved;return null===r?this._removalsHead=s:r._nextRemoved=s,null===s?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(t,e,i),this._addToMoves(t,i),t}_moveAfter(t,e,i){return this._unlink(t),this._insertAfter(t,e,i),this._addToMoves(t,i),t}_addAfter(t,e,i){return this._insertAfter(t,e,i),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}_insertAfter(t,e,i){const r=null===e?this._itHead:e._next;return t._next=r,t._prev=e,null===r?this._itTail=t:r._prev=t,null===e?this._itHead=t:e._next=t,null===this._linkedRecords&&(this._linkedRecords=new jD),this._linkedRecords.put(t),t.currentIndex=i,t}_remove(t){return this._addToRemovals(this._unlink(t))}_unlink(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);const e=t._prev,i=t._next;return null===e?this._itHead=i:e._next=i,null===i?this._itTail=e:i._prev=e,t}_addToMoves(t,e){return t.previousIndex===e||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}_addToRemovals(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new jD),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}_addIdentityChange(t,e){return t.item=e,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}}class ZN{constructor(t,e){this.item=t,this.trackById=e,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class XN{constructor(){this._head=null,this._tail=null}add(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}get(t,e){let i;for(i=this._head;null!==i;i=i._nextDup)if((null===e||e<=i.currentIndex)&&Object.is(i.trackById,t))return i;return null}remove(t){const e=t._prevDup,i=t._nextDup;return null===e?this._head=i:e._nextDup=i,null===i?this._tail=e:i._prevDup=e,null===this._head}}class jD{constructor(){this.map=new Map}put(t){const e=t.trackById;let i=this.map.get(e);i||(i=new XN,this.map.set(e,i)),i.add(t)}get(t,e){const r=this.map.get(t);return r?r.get(t,e):null}remove(t){const e=t.trackById;return this.map.get(e).remove(t)&&this.map.delete(e),t}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function UD(n,t,e){const i=n.previousIndex;if(null===i)return i;let r=0;return e&&i{if(e&&e.key===r)this._maybeAddToChanges(e,i),this._appendAfter=e,e=e._next;else{const s=this._getOrCreateRecordForKey(r,i);e=this._insertBeforeOrAppend(e,s)}}),e){e._prev&&(e._prev._next=null),this._removalsHead=e;for(let i=e;null!==i;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(t,e){if(t){const i=t._prev;return e._next=t,e._prev=i,t._prev=e,i&&(i._next=e),t===this._mapHead&&(this._mapHead=e),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=e,e._prev=this._appendAfter):this._mapHead=e,this._appendAfter=e,null}_getOrCreateRecordForKey(t,e){if(this._records.has(t)){const r=this._records.get(t);this._maybeAddToChanges(r,e);const s=r._prev,o=r._next;return s&&(s._next=o),o&&(o._prev=s),r._next=null,r._prev=null,r}const i=new eB(t);return this._records.set(t,i),i.currentValue=e,this._addToAdditions(i),i}_reset(){if(this.isDirty){let t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(t,e){Object.is(e,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=e,this._addToChanges(t))}_addToAdditions(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}_addToChanges(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}_forEach(t,e){t instanceof Map?t.forEach(e):Object.keys(t).forEach(i=>e(t[i],i))}}class eB{constructor(t){this.key=t,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function $D(){return new es([new HD])}let es=(()=>{class n{constructor(e){this.factories=e}static create(e,i){if(null!=i){const r=i.factories.slice();e=e.concat(r)}return new n(e)}static extend(e){return{provide:n,useFactory:i=>n.create(e,i||$D()),deps:[[n,new ir,new Hn]]}}find(e){const i=this.factories.find(r=>r.supports(e));if(null!=i)return i;throw new Be(901,"")}}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:$D}),n})();function GD(){return new Nl([new zD])}let Nl=(()=>{class n{constructor(e){this.factories=e}static create(e,i){if(i){const r=i.factories.slice();e=e.concat(r)}return new n(e)}static extend(e){return{provide:n,useFactory:i=>n.create(e,i||GD()),deps:[[n,new ir,new Hn]]}}find(e){const i=this.factories.find(s=>s.supports(e));if(i)return i;throw new Be(901,"")}}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:GD}),n})();const iB=kD(null,"core",[]);let rB=(()=>{class n{constructor(e){}}return n.\u0275fac=function(e){return new(e||n)(te(Ll))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();function ts(n){return"boolean"==typeof n?n:null!=n&&"false"!==n}let qd=null;function Sr(){return qd}const ct=new De("DocumentToken");let Bl=(()=>{class n{historyGo(e){throw new Error("Not implemented")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(){return function lB(){return te(WD)}()},providedIn:"platform"}),n})();const cB=new De("Location Initialized");let WD=(()=>{class n extends Bl{constructor(e){super(),this._doc=e,this._init()}_init(){this.location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Sr().getBaseHref(this._doc)}onPopState(e){const i=Sr().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",e,!1),()=>i.removeEventListener("popstate",e)}onHashChange(e){const i=Sr().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",e,!1),()=>i.removeEventListener("hashchange",e)}get href(){return this.location.href}get protocol(){return this.location.protocol}get hostname(){return this.location.hostname}get port(){return this.location.port}get pathname(){return this.location.pathname}get search(){return this.location.search}get hash(){return this.location.hash}set pathname(e){this.location.pathname=e}pushState(e,i,r){qD()?this._history.pushState(e,i,r):this.location.hash=r}replaceState(e,i,r){qD()?this._history.replaceState(e,i,r):this.location.hash=r}forward(){this._history.forward()}back(){this._history.back()}historyGo(e=0){this._history.go(e)}getState(){return this._history.state}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(){return function dB(){return new WD(te(ct))}()},providedIn:"platform"}),n})();function qD(){return!!window.history.pushState}function zm(n,t){if(0==n.length)return t;if(0==t.length)return n;let e=0;return n.endsWith("/")&&e++,t.startsWith("/")&&e++,2==e?n+t.substring(1):1==e?n+t:n+"/"+t}function YD(n){const t=n.match(/#|\?|$/),e=t&&t.index||n.length;return n.slice(0,e-("/"===n[e-1]?1:0))+n.slice(e)}function ns(n){return n&&"?"!==n[0]?"?"+n:n}let ya=(()=>{class n{historyGo(e){throw new Error("Not implemented")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(){return function uB(){const n=te(ct).location;return new KD(te(Bl),n&&n.origin||"")}()},providedIn:"root"}),n})();const $m=new De("appBaseHref");let KD=(()=>{class n extends ya{constructor(e,i){if(super(),this._platformLocation=e,this._removeListenerFns=[],null==i&&(i=this._platformLocation.getBaseHrefFromDOM()),null==i)throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");this._baseHref=i}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return zm(this._baseHref,e)}path(e=!1){const i=this._platformLocation.pathname+ns(this._platformLocation.search),r=this._platformLocation.hash;return r&&e?`${i}${r}`:i}pushState(e,i,r,s){const o=this.prepareExternalUrl(r+ns(s));this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){const o=this.prepareExternalUrl(r+ns(s));this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){var i,r;null===(r=(i=this._platformLocation).historyGo)||void 0===r||r.call(i,e)}}return n.\u0275fac=function(e){return new(e||n)(te(Bl),te($m,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),hB=(()=>{class n extends ya{constructor(e,i){super(),this._platformLocation=e,this._baseHref="",this._removeListenerFns=[],null!=i&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}path(e=!1){let i=this._platformLocation.hash;return null==i&&(i="#"),i.length>0?i.substring(1):i}prepareExternalUrl(e){const i=zm(this._baseHref,e);return i.length>0?"#"+i:i}pushState(e,i,r,s){let o=this.prepareExternalUrl(r+ns(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){let o=this.prepareExternalUrl(r+ns(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){var i,r;null===(r=(i=this._platformLocation).historyGo)||void 0===r||r.call(i,e)}}return n.\u0275fac=function(e){return new(e||n)(te(Bl),te($m,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),Vl=(()=>{class n{constructor(e){this._subject=new je,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=e;const i=this._locationStrategy.getBaseHref();this._baseHref=YD(QD(i)),this._locationStrategy.onPopState(r=>{this._subject.emit({url:this.path(!0),pop:!0,state:r.state,type:r.type})})}ngOnDestroy(){var e;null===(e=this._urlChangeSubscription)||void 0===e||e.unsubscribe(),this._urlChangeListeners=[]}path(e=!1){return this.normalize(this._locationStrategy.path(e))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(e,i=""){return this.path()==this.normalize(e+ns(i))}normalize(e){return n.stripTrailingSlash(function pB(n,t){return n&&t.startsWith(n)?t.substring(n.length):t}(this._baseHref,QD(e)))}prepareExternalUrl(e){return e&&"/"!==e[0]&&(e="/"+e),this._locationStrategy.prepareExternalUrl(e)}go(e,i="",r=null){this._locationStrategy.pushState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+ns(i)),r)}replaceState(e,i="",r=null){this._locationStrategy.replaceState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+ns(i)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(e=0){var i,r;null===(r=(i=this._locationStrategy).historyGo)||void 0===r||r.call(i,e)}onUrlChange(e){return this._urlChangeListeners.push(e),this._urlChangeSubscription||(this._urlChangeSubscription=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)})),()=>{var i;const r=this._urlChangeListeners.indexOf(e);this._urlChangeListeners.splice(r,1),0===this._urlChangeListeners.length&&(null===(i=this._urlChangeSubscription)||void 0===i||i.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(e="",i){this._urlChangeListeners.forEach(r=>r(e,i))}subscribe(e,i,r){return this._subject.subscribe({next:e,error:i,complete:r})}}return n.normalizeQueryParams=ns,n.joinWithSlash=zm,n.stripTrailingSlash=YD,n.\u0275fac=function(e){return new(e||n)(te(ya))},n.\u0275prov=Ie({token:n,factory:function(){return function fB(){return new Vl(te(ya))}()},providedIn:"root"}),n})();function QD(n){return n.replace(/\/index.html$/,"")}var fi=(()=>((fi=fi||{})[fi.Decimal=0]="Decimal",fi[fi.Percent=1]="Percent",fi[fi.Currency=2]="Currency",fi[fi.Scientific=3]="Scientific",fi))(),st=(()=>((st=st||{})[st.Decimal=0]="Decimal",st[st.Group=1]="Group",st[st.List=2]="List",st[st.PercentSign=3]="PercentSign",st[st.PlusSign=4]="PlusSign",st[st.MinusSign=5]="MinusSign",st[st.Exponential=6]="Exponential",st[st.SuperscriptingExponent=7]="SuperscriptingExponent",st[st.PerMille=8]="PerMille",st[st.Infinity=9]="Infinity",st[st.NaN=10]="NaN",st[st.TimeSeparator=11]="TimeSeparator",st[st.CurrencyDecimal=12]="CurrencyDecimal",st[st.CurrencyGroup=13]="CurrencyGroup",st))();function ji(n,t){const e=si(n),i=e[He.NumberSymbols][t];if(void 0===i){if(t===st.CurrencyDecimal)return e[He.NumberSymbols][st.Decimal];if(t===st.CurrencyGroup)return e[He.NumberSymbols][st.Group]}return i}const HB=/^(\d+)?\.((\d+)(-(\d+))?)?$/;function Xm(n){const t=parseInt(n);if(isNaN(t))throw new Error("Invalid integer literal when parsing "+n);return t}function sE(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}let eg=(()=>{class n{constructor(e,i,r,s){this._iterableDiffers=e,this._keyValueDiffers=i,this._ngEl=r,this._renderer=s,this._iterableDiffer=null,this._keyValueDiffer=null,this._initialClasses=[],this._rawClass=null}set klass(e){this._removeClasses(this._initialClasses),this._initialClasses="string"==typeof e?e.split(/\s+/):[],this._applyClasses(this._initialClasses),this._applyClasses(this._rawClass)}set ngClass(e){this._removeClasses(this._rawClass),this._applyClasses(this._initialClasses),this._iterableDiffer=null,this._keyValueDiffer=null,this._rawClass="string"==typeof e?e.split(/\s+/):e,this._rawClass&&(bl(this._rawClass)?this._iterableDiffer=this._iterableDiffers.find(this._rawClass).create():this._keyValueDiffer=this._keyValueDiffers.find(this._rawClass).create())}ngDoCheck(){if(this._iterableDiffer){const e=this._iterableDiffer.diff(this._rawClass);e&&this._applyIterableChanges(e)}else if(this._keyValueDiffer){const e=this._keyValueDiffer.diff(this._rawClass);e&&this._applyKeyValueChanges(e)}}_applyKeyValueChanges(e){e.forEachAddedItem(i=>this._toggleClass(i.key,i.currentValue)),e.forEachChangedItem(i=>this._toggleClass(i.key,i.currentValue)),e.forEachRemovedItem(i=>{i.previousValue&&this._toggleClass(i.key,!1)})}_applyIterableChanges(e){e.forEachAddedItem(i=>{if("string"!=typeof i.item)throw new Error(`NgClass can only toggle CSS classes expressed as strings, got ${Kt(i.item)}`);this._toggleClass(i.item,!0)}),e.forEachRemovedItem(i=>this._toggleClass(i.item,!1))}_applyClasses(e){e&&(Array.isArray(e)||e instanceof Set?e.forEach(i=>this._toggleClass(i,!0)):Object.keys(e).forEach(i=>this._toggleClass(i,!!e[i])))}_removeClasses(e){e&&(Array.isArray(e)||e instanceof Set?e.forEach(i=>this._toggleClass(i,!1)):Object.keys(e).forEach(i=>this._toggleClass(i,!1)))}_toggleClass(e,i){(e=e.trim())&&e.split(/\s+/g).forEach(r=>{i?this._renderer.addClass(this._ngEl.nativeElement,r):this._renderer.removeClass(this._ngEl.nativeElement,r)})}}return n.\u0275fac=function(e){return new(e||n)(x(es),x(Nl),x(Je),x(Xr))},n.\u0275dir=Me({type:n,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"}}),n})();class XB{constructor(t,e,i,r){this.$implicit=t,this.ngForOf=e,this.index=i,this.count=r}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let ao=(()=>{class n{constructor(e,i,r){this._viewContainer=e,this._template=i,this._differs=r,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForOf(e){this._ngForOf=e,this._ngForOfDirty=!0}set ngForTrackBy(e){this._trackByFn=e}get ngForTrackBy(){return this._trackByFn}set ngForTemplate(e){e&&(this._template=e)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const e=this._ngForOf;!this._differ&&e&&(this._differ=this._differs.find(e).create(this.ngForTrackBy))}if(this._differ){const e=this._differ.diff(this._ngForOf);e&&this._applyChanges(e)}}_applyChanges(e){const i=this._viewContainer;e.forEachOperation((r,s,o)=>{if(null==r.previousIndex)i.createEmbeddedView(this._template,new XB(r.item,this._ngForOf,-1,-1),null===o?void 0:o);else if(null==o)i.remove(null===s?void 0:s);else if(null!==s){const a=i.get(s);i.move(a,o),aE(a,r)}});for(let r=0,s=i.length;r{aE(i.get(r.currentIndex),r)})}static ngTemplateContextGuard(e,i){return!0}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(es))},n.\u0275dir=Me({type:n,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}}),n})();function aE(n,t){n.context.$implicit=t.item}let zi=(()=>{class n{constructor(e,i){this._viewContainer=e,this._context=new JB,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=i}set ngIf(e){this._context.$implicit=this._context.ngIf=e,this._updateView()}set ngIfThen(e){lE("ngIfThen",e),this._thenTemplateRef=e,this._thenViewRef=null,this._updateView()}set ngIfElse(e){lE("ngIfElse",e),this._elseTemplateRef=e,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngTemplateContextGuard(e,i){return!0}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n))},n.\u0275dir=Me({type:n,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}}),n})();class JB{constructor(){this.$implicit=null,this.ngIf=null}}function lE(n,t){if(t&&!t.createEmbeddedView)throw new Error(`${n} must be a TemplateRef, but received '${Kt(t)}'.`)}class tg{constructor(t,e){this._viewContainerRef=t,this._templateRef=e,this._created=!1}create(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}destroy(){this._created=!1,this._viewContainerRef.clear()}enforceState(t){t&&!this._created?this.create():!t&&this._created&&this.destroy()}}let ba=(()=>{class n{constructor(){this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}set ngSwitch(e){this._ngSwitch=e,0===this._caseCount&&this._updateDefaultCases(!0)}_addCase(){return this._caseCount++}_addDefault(e){this._defaultViews||(this._defaultViews=[]),this._defaultViews.push(e)}_matchCase(e){const i=e==this._ngSwitch;return this._lastCasesMatched=this._lastCasesMatched||i,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),i}_updateDefaultCases(e){if(this._defaultViews&&e!==this._defaultUsed){this._defaultUsed=e;for(let i=0;i{class n{constructor(e,i,r){this.ngSwitch=r,r._addCase(),this._view=new tg(e,i)}ngDoCheck(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(ba,9))},n.\u0275dir=Me({type:n,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"}}),n})(),cE=(()=>{class n{constructor(e,i,r){r._addDefault(new tg(e,i))}}return n.\u0275fac=function(e){return new(e||n)(x(An),x(_n),x(ba,9))},n.\u0275dir=Me({type:n,selectors:[["","ngSwitchDefault",""]]}),n})();function dr(n,t){return new Be(2100,"")}let hE=(()=>{class n{transform(e){if(null==e)return null;if("string"!=typeof e)throw dr();return e.toUpperCase()}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275pipe=ui({name:"uppercase",type:n,pure:!0}),n})(),ru=(()=>{class n{transform(e){return JSON.stringify(e,null,2)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275pipe=ui({name:"json",type:n,pure:!1}),n})(),fE=(()=>{class n{constructor(e){this.differs=e,this.keyValues=[],this.compareFn=pE}transform(e,i=pE){if(!e||!(e instanceof Map)&&"object"!=typeof e)return null;this.differ||(this.differ=this.differs.find(e).create());const r=this.differ.diff(e),s=i!==this.compareFn;return r&&(this.keyValues=[],r.forEachItem(o=>{this.keyValues.push(function mV(n,t){return{key:n,value:t}}(o.key,o.currentValue))})),(r||s)&&(this.keyValues.sort(i),this.compareFn=i),this.keyValues}}return n.\u0275fac=function(e){return new(e||n)(x(Nl,16))},n.\u0275pipe=ui({name:"keyvalue",type:n,pure:!1}),n})();function pE(n,t){const e=n.key,i=t.key;if(e===i)return 0;if(void 0===e)return 1;if(void 0===i)return-1;if(null===e)return 1;if(null===i)return-1;if("string"==typeof e&&"string"==typeof i)return e{class n{constructor(e){this._locale=e}transform(e,i,r){if(!function ig(n){return!(null==n||""===n||n!=n)}(e))return null;r=r||this._locale;try{return function WB(n,t,e){return function Qm(n,t,e,i,r,s,o=!1){let a="",l=!1;if(isFinite(n)){let c=function YB(n){let i,r,s,o,a,t=Math.abs(n)+"",e=0;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(s=t.search(/e/i))>0?(r<0&&(r=s),r+=+t.slice(s+1),t=t.substring(0,s)):r<0&&(r=t.length),s=0;"0"===t.charAt(s);s++);if(s===(a=t.length))i=[0],r=1;else{for(a--;"0"===t.charAt(a);)a--;for(r-=s,i=[],o=0;s<=a;s++,o++)i[o]=Number(t.charAt(s))}return r>22&&(i=i.splice(0,21),e=r-1,r=1),{digits:i,exponent:e,integerLen:r}}(n);o&&(c=function qB(n){if(0===n.digits[0])return n;const t=n.digits.length-n.integerLen;return n.exponent?n.exponent+=2:(0===t?n.digits.push(0,0):1===t&&n.digits.push(0),n.integerLen+=2),n}(c));let d=t.minInt,f=t.minFrac,w=t.maxFrac;if(s){const Te=s.match(HB);if(null===Te)throw new Error(`${s} is not a valid digit info`);const he=Te[1],Oe=Te[3],ft=Te[5];null!=he&&(d=Xm(he)),null!=Oe&&(f=Xm(Oe)),null!=ft?w=Xm(ft):null!=Oe&&f>w&&(w=f)}!function KB(n,t,e){if(t>e)throw new Error(`The minimum number of digits after fraction (${t}) is higher than the maximum (${e}).`);let i=n.digits,r=i.length-n.integerLen;const s=Math.min(Math.max(t,r),e);let o=s+n.integerLen,a=i[o];if(o>0){i.splice(Math.max(n.integerLen,o));for(let f=o;f=5)if(o-1<0){for(let f=0;f>o;f--)i.unshift(0),n.integerLen++;i.unshift(1),n.integerLen++}else i[o-1]++;for(;r=c?j.pop():l=!1),w>=10?1:0},0);d&&(i.unshift(d),n.integerLen++)}(c,f,w);let k=c.digits,j=c.integerLen;const K=c.exponent;let ae=[];for(l=k.every(Te=>!Te);j0?ae=k.splice(j,k.length):(ae=k,k=[0]);const ce=[];for(k.length>=t.lgSize&&ce.unshift(k.splice(-t.lgSize,k.length).join(""));k.length>t.gSize;)ce.unshift(k.splice(-t.gSize,k.length).join(""));k.length&&ce.unshift(k.join("")),a=ce.join(ji(e,i)),ae.length&&(a+=ji(e,r)+ae.join("")),K&&(a+=ji(e,st.Exponential)+"+"+K)}else a=ji(e,st.Infinity);return a=n<0&&!l?t.negPre+a+t.negSuf:t.posPre+a+t.posSuf,a}(n,function Zm(n,t="-"){const e={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},i=n.split(";"),r=i[0],s=i[1],o=-1!==r.indexOf(".")?r.split("."):[r.substring(0,r.lastIndexOf("0")+1),r.substring(r.lastIndexOf("0")+1)],a=o[0],l=o[1]||"";e.posPre=a.substring(0,a.indexOf("#"));for(let d=0;d{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const mE="browser";let DV=(()=>{class n{}return n.\u0275prov=Ie({token:n,providedIn:"root",factory:()=>new EV(te(ct),window)}),n})();class EV{constructor(t,e){this.document=t,this.window=e,this.offset=()=>[0,0]}setOffset(t){this.offset=Array.isArray(t)?()=>t:t}getScrollPosition(){return this.supportsScrolling()?[this.window.pageXOffset,this.window.pageYOffset]:[0,0]}scrollToPosition(t){this.supportsScrolling()&&this.window.scrollTo(t[0],t[1])}scrollToAnchor(t){if(!this.supportsScrolling())return;const e=function MV(n,t){const e=n.getElementById(t)||n.getElementsByName(t)[0];if(e)return e;if("function"==typeof n.createTreeWalker&&n.body&&(n.body.createShadowRoot||n.body.attachShadow)){const i=n.createTreeWalker(n.body,NodeFilter.SHOW_ELEMENT);let r=i.currentNode;for(;r;){const s=r.shadowRoot;if(s){const o=s.getElementById(t)||s.querySelector(`[name="${t}"]`);if(o)return o}r=i.nextNode()}}return null}(this.document,t);e&&(this.scrollToElement(e),e.focus())}setHistoryScrollRestoration(t){if(this.supportScrollRestoration()){const e=this.window.history;e&&e.scrollRestoration&&(e.scrollRestoration=t)}}scrollToElement(t){const e=t.getBoundingClientRect(),i=e.left+this.window.pageXOffset,r=e.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(i-s[0],r-s[1])}supportScrollRestoration(){try{if(!this.supportsScrolling())return!1;const t=gE(this.window.history)||gE(Object.getPrototypeOf(this.window.history));return!(!t||!t.writable&&!t.set)}catch(t){return!1}}supportsScrolling(){try{return!!this.window&&!!this.window.scrollTo&&"pageXOffset"in this.window}catch(t){return!1}}}function gE(n){return Object.getOwnPropertyDescriptor(n,"scrollRestoration")}class _E{}class sg extends class xV extends class aB{}{constructor(){super(...arguments),this.supportsDOMEvents=!0}}{static makeCurrent(){!function oB(n){qd||(qd=n)}(new sg)}onAndCancel(t,e,i){return t.addEventListener(e,i,!1),()=>{t.removeEventListener(e,i,!1)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function SV(){return Ul=Ul||document.querySelector("base"),Ul?Ul.getAttribute("href"):null}();return null==e?null:function kV(n){su=su||document.createElement("a"),su.setAttribute("href",n);const t=su.pathname;return"/"===t.charAt(0)?t:`/${t}`}(e)}resetBaseElement(){Ul=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return sE(document.cookie,t)}}let su,Ul=null;const vE=new De("TRANSITION_ID"),AV=[{provide:Am,useFactory:function TV(n,t,e){return()=>{e.get(jd).donePromise.then(()=>{const i=Sr(),r=t.querySelectorAll(`style[ng-transition="${n}"]`);for(let s=0;s{class n{build(){return new XMLHttpRequest}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const ou=new De("EventManagerPlugins");let au=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>r.manager=this),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}addGlobalEventListener(e,i,r){return this._findPluginFor(i).addGlobalEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){const i=this._eventNameToPlugin.get(e);if(i)return i;const r=this._plugins;for(let s=0;s{class n{constructor(){this._stylesSet=new Set}addStyles(e){const i=new Set;e.forEach(r=>{this._stylesSet.has(r)||(this._stylesSet.add(r),i.add(r))}),this.onStylesAdded(i)}onStylesAdded(e){}getAllStyles(){return Array.from(this._stylesSet)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),zl=(()=>{class n extends bE{constructor(e){super(),this._doc=e,this._hostNodes=new Map,this._hostNodes.set(e.head,[])}_addStylesToHost(e,i,r){e.forEach(s=>{const o=this._doc.createElement("style");o.textContent=s,r.push(i.appendChild(o))})}addHost(e){const i=[];this._addStylesToHost(this._stylesSet,e,i),this._hostNodes.set(e,i)}removeHost(e){const i=this._hostNodes.get(e);i&&i.forEach(wE),this._hostNodes.delete(e)}onStylesAdded(e){this._hostNodes.forEach((i,r)=>{this._addStylesToHost(e,r,i)})}ngOnDestroy(){this._hostNodes.forEach(e=>e.forEach(wE))}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function wE(n){Sr().remove(n)}const og={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},ag=/%COMP%/g;function lu(n,t,e){for(let i=0;i{if("__ngUnwrap__"===t)return n;!1===n(t)&&(t.preventDefault(),t.returnValue=!1)}}let cu=(()=>{class n{constructor(e,i,r){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.rendererByCompId=new Map,this.defaultRenderer=new lg(e)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;switch(i.encapsulation){case Ji.Emulated:{let r=this.rendererByCompId.get(i.id);return r||(r=new BV(this.eventManager,this.sharedStylesHost,i,this.appId),this.rendererByCompId.set(i.id,r)),r.applyToHost(e),r}case 1:case Ji.ShadowDom:return new VV(this.eventManager,this.sharedStylesHost,e,i);default:if(!this.rendererByCompId.has(i.id)){const r=lu(i.id,i.styles,[]);this.sharedStylesHost.addStyles(r),this.rendererByCompId.set(i.id,this.defaultRenderer)}return this.defaultRenderer}}begin(){}end(){}}return n.\u0275fac=function(e){return new(e||n)(te(au),te(zl),te(Ol))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class lg{constructor(t){this.eventManager=t,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(t,e){return e?document.createElementNS(og[e]||e,t):document.createElement(t)}createComment(t){return document.createComment(t)}createText(t){return document.createTextNode(t)}appendChild(t,e){(xE(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(xE(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?document.querySelector(t):t;if(!i)throw new Error(`The selector "${t}" did not match any elements`);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=og[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=og[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(xi.DashCase|xi.Important)?t.style.setProperty(e,i,r&xi.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&xi.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){t[e]=i}setValue(t,e){t.nodeValue=e}listen(t,e,i){return"string"==typeof t?this.eventManager.addGlobalEventListener(t,e,EE(i)):this.eventManager.addEventListener(t,e,EE(i))}}function xE(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class BV extends lg{constructor(t,e,i,r){super(t),this.component=i;const s=lu(r+"-"+i.id,i.styles,[]);e.addStyles(s),this.contentAttr=function FV(n){return"_ngcontent-%COMP%".replace(ag,n)}(r+"-"+i.id),this.hostAttr=function LV(n){return"_nghost-%COMP%".replace(ag,n)}(r+"-"+i.id)}applyToHost(t){super.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}class VV extends lg{constructor(t,e,i,r){super(t),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const s=lu(r.id,r.styles,[]);for(let o=0;o{class n extends yE{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const SE=["alt","control","meta","shift"],UV={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},kE={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},zV={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let $V=(()=>{class n extends yE{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Sr().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="";if(SE.forEach(l=>{const c=i.indexOf(l);c>-1&&(i.splice(c,1),o+=l+".")}),o+=s,0!=i.length||0===s.length)return null;const a={};return a.domEventName=r,a.fullKey=o,a}static getEventFullKey(e){let i="",r=function GV(n){let t=n.key;if(null==t){if(t=n.keyIdentifier,null==t)return"Unidentified";t.startsWith("U+")&&(t=String.fromCharCode(parseInt(t.substring(2),16)),3===n.location&&kE.hasOwnProperty(t)&&(t=kE[t]))}return UV[t]||t}(e);return r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),SE.forEach(s=>{s!=r&&zV[s](e)&&(i+=s+".")}),i+=r,i}static eventCallback(e,i,r){return s=>{n.getEventFullKey(s)===e&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const KV=kD(iB,"browser",[{provide:Ud,useValue:mE},{provide:yD,useValue:function WV(){sg.makeCurrent()},multi:!0},{provide:ct,useFactory:function YV(){return function cI(n){bf=n}(document),document},deps:[]}]),AE=new De(""),IE=[{provide:zd,useClass:class IV{addToWindow(t){qt.getAngularTestability=(i,r=!0)=>{const s=t.findTestabilityInTree(i,r);if(null==s)throw new Error("Could not find testability for element.");return s},qt.getAllAngularTestabilities=()=>t.getAllTestabilities(),qt.getAllAngularRootElements=()=>t.getAllRootElements(),qt.frameworkStabilizers||(qt.frameworkStabilizers=[]),qt.frameworkStabilizers.push(i=>{const r=qt.getAllAngularTestabilities();let s=r.length,o=!1;const a=function(l){o=o||l,s--,0==s&&i(o)};r.forEach(function(l){l.whenStable(a)})})}findTestabilityInTree(t,e,i){if(null==e)return null;const r=t.getTestability(e);return null!=r?r:i?Sr().isShadowRoot(e)?this.findTestabilityInTree(t,e.host,!0):this.findTestabilityInTree(t,e.parentElement,!0):null}},deps:[]},{provide:DD,useClass:Lm,deps:[et,Nm,zd]},{provide:Lm,useClass:Lm,deps:[et,Nm,zd]}],RE=[{provide:_p,useValue:"root"},{provide:qr,useFactory:function qV(){return new qr},deps:[]},{provide:ou,useClass:HV,multi:!0,deps:[ct,et,Ud]},{provide:ou,useClass:$V,multi:!0,deps:[ct]},{provide:cu,useClass:cu,deps:[au,zl,Ol]},{provide:Tl,useExisting:cu},{provide:bE,useExisting:zl},{provide:zl,useClass:zl,deps:[ct]},{provide:au,useClass:au,deps:[ou,et]},{provide:_E,useClass:RV,deps:[]},[]];let PE=(()=>{class n{constructor(e){}static withServerTransition(e){return{ngModule:n,providers:[{provide:Ol,useValue:e.appId},{provide:vE,useExisting:Ol},AV]}}}return n.\u0275fac=function(e){return new(e||n)(te(AE,12))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[...RE,...IE],imports:[pi,rB]}),n})(),OE=(()=>{class n{constructor(e){this._doc=e}getTitle(){return this._doc.title}setTitle(e){this._doc.title=e||""}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new e:function ZV(){return new OE(te(ct))}(),i},providedIn:"root"}),n})();"undefined"!=typeof window&&window;let ug=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new(e||n):te(NE),i},providedIn:"root"}),n})(),NE=(()=>{class n extends ug{constructor(e){super(),this._doc=e}sanitize(e,i){if(null==i)return null;switch(e){case Ut.NONE:return i;case Ut.HTML:return _r(i,"HTML")?Mi(i):Db(this._doc,String(i)).toString();case Ut.STYLE:return _r(i,"Style")?Mi(i):i;case Ut.SCRIPT:if(_r(i,"Script"))return Mi(i);throw new Error("unsafe value used in a script context");case Ut.URL:return mb(i),_r(i,"URL")?Mi(i):hl(String(i));case Ut.RESOURCE_URL:if(_r(i,"ResourceURL"))return Mi(i);throw new Error("unsafe value used in a resource URL context (see https://g.co/ng/security#xss)");default:throw new Error(`Unexpected SecurityContext ${e} (see https://g.co/ng/security#xss)`)}}bypassSecurityTrustHtml(e){return function DR(n){return new vR(n)}(e)}bypassSecurityTrustStyle(e){return function ER(n){return new yR(n)}(e)}bypassSecurityTrustScript(e){return function MR(n){return new bR(n)}(e)}bypassSecurityTrustUrl(e){return function xR(n){return new wR(n)}(e)}bypassSecurityTrustResourceUrl(e){return function SR(n){return new CR(n)}(e)}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:function(e){let i=null;return i=e?new e:function o2(n){return new NE(n.get(ct))}(te(Jt)),i},providedIn:"root"}),n})();class BE{}const rs="*";function jn(n,t){return{type:7,name:n,definitions:t,options:{}}}function Zt(n,t=null){return{type:4,styles:t,timings:n}}function VE(n,t=null){return{type:3,steps:n,options:t}}function HE(n,t=null){return{type:2,steps:n,options:t}}function Qe(n){return{type:6,styles:n,offset:null}}function zt(n,t,e){return{type:0,name:n,styles:t,options:e}}function Wt(n,t,e=null){return{type:1,expr:n,animation:t,options:e}}function du(n=null){return{type:9,options:n}}function uu(n,t,e=null){return{type:11,selector:n,animation:t,options:e}}function jE(n){Promise.resolve(null).then(n)}class $l{constructor(t=0,e=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=t+e}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}onStart(t){this._onStartFns.push(t)}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){jE(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(t=>t()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}reset(){this._started=!1}setPosition(t){this._position=this.totalTime?t*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(t){const e="start"==t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}class UE{constructor(t){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=t;let e=0,i=0,r=0;const s=this.players.length;0==s?jE(()=>this._onFinish()):this.players.forEach(o=>{o.onDone(()=>{++e==s&&this._onFinish()}),o.onDestroy(()=>{++i==s&&this._onDestroy()}),o.onStart(()=>{++r==s&&this._onStart()})}),this.totalTime=this.players.reduce((o,a)=>Math.max(o,a.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}init(){this.players.forEach(t=>t.init())}onStart(t){this._onStartFns.push(t)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(t=>t()),this._onStartFns=[])}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(t=>t.play())}pause(){this.players.forEach(t=>t.pause())}restart(){this.players.forEach(t=>t.restart())}finish(){this._onFinish(),this.players.forEach(t=>t.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(t=>t.destroy()),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}reset(){this.players.forEach(t=>t.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(t){const e=t*this.totalTime;this.players.forEach(i=>{const r=i.totalTime?Math.min(1,e/i.totalTime):1;i.setPosition(r)})}getPosition(){const t=this.players.reduce((e,i)=>null===e||i.totalTime>e.totalTime?i:e,null);return null!=t?t.getPosition():0}beforeDestroy(){this.players.forEach(t=>{t.beforeDestroy&&t.beforeDestroy()})}triggerCallback(t){const e="start"==t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}const Rt=!1;function zE(n){return new Be(3e3,Rt)}function U2(){return"undefined"!=typeof window&&void 0!==window.document}function fg(){return"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)}function Ms(n){switch(n.length){case 0:return new $l;case 1:return n[0];default:return new UE(n)}}function $E(n,t,e,i,r=new Map,s=new Map){const o=[],a=[];let l=-1,c=null;if(i.forEach(d=>{const f=d.get("offset"),w=f==l,k=w&&c||new Map;d.forEach((j,K)=>{let ae=K,ce=j;if("offset"!==K)switch(ae=t.normalizePropertyName(ae,o),ce){case"!":ce=r.get(K);break;case rs:ce=s.get(K);break;default:ce=t.normalizeStyleValue(K,ae,ce,o)}k.set(ae,ce)}),w||a.push(k),c=k,l=f}),o.length)throw function A2(n){return new Be(3502,Rt)}();return a}function pg(n,t,e,i){switch(t){case"start":n.onStart(()=>i(e&&mg(e,"start",n)));break;case"done":n.onDone(()=>i(e&&mg(e,"done",n)));break;case"destroy":n.onDestroy(()=>i(e&&mg(e,"destroy",n)))}}function mg(n,t,e){const i=e.totalTime,s=gg(n.element,n.triggerName,n.fromState,n.toState,t||n.phaseName,null==i?n.totalTime:i,!!e.disabled),o=n._data;return null!=o&&(s._data=o),s}function gg(n,t,e,i,r="",s=0,o){return{element:n,triggerName:t,fromState:e,toState:i,phaseName:r,totalTime:s,disabled:!!o}}function Ti(n,t,e){let i=n.get(t);return i||n.set(t,i=e),i}function GE(n){const t=n.indexOf(":");return[n.substring(1,t),n.slice(t+1)]}let _g=(n,t)=>!1,WE=(n,t,e)=>[],qE=null;function vg(n){const t=n.parentNode||n.host;return t===qE?null:t}(fg()||"undefined"!=typeof Element)&&(U2()?(qE=(()=>document.documentElement)(),_g=(n,t)=>{for(;t;){if(t===n)return!0;t=vg(t)}return!1}):_g=(n,t)=>n.contains(t),WE=(n,t,e)=>{if(e)return Array.from(n.querySelectorAll(t));const i=n.querySelector(t);return i?[i]:[]});let co=null,YE=!1;const KE=_g,QE=WE;let ZE=(()=>{class n{validateStyleProperty(e){return function $2(n){co||(co=function G2(){return"undefined"!=typeof document?document.body:null}()||{},YE=!!co.style&&"WebkitAppearance"in co.style);let t=!0;return co.style&&!function z2(n){return"ebkit"==n.substring(1,6)}(n)&&(t=n in co.style,!t&&YE&&(t="Webkit"+n.charAt(0).toUpperCase()+n.slice(1)in co.style)),t}(e)}matchesElement(e,i){return!1}containsElement(e,i){return KE(e,i)}getParentElement(e){return vg(e)}query(e,i,r){return QE(e,i,r)}computeStyle(e,i,r){return r||""}animate(e,i,r,s,o,a=[],l){return new $l(r,s)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),yg=(()=>{class n{}return n.NOOP=new ZE,n})();const bg="ng-enter",fu="ng-leave",pu="ng-trigger",mu=".ng-trigger",JE="ng-animating",wg=".ng-animating";function xs(n){if("number"==typeof n)return n;const t=n.match(/^(-?[\.\d]+)(m?s)/);return!t||t.length<2?0:Cg(parseFloat(t[1]),t[2])}function Cg(n,t){return"s"===t?1e3*n:n}function gu(n,t,e){return n.hasOwnProperty("duration")?n:function Y2(n,t,e){let r,s=0,o="";if("string"==typeof n){const a=n.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return t.push(zE()),{duration:0,delay:0,easing:""};r=Cg(parseFloat(a[1]),a[2]);const l=a[3];null!=l&&(s=Cg(parseFloat(l),a[4]));const c=a[5];c&&(o=c)}else r=n;if(!e){let a=!1,l=t.length;r<0&&(t.push(function l2(){return new Be(3100,Rt)}()),a=!0),s<0&&(t.push(function c2(){return new Be(3101,Rt)}()),a=!0),a&&t.splice(l,0,zE())}return{duration:r,delay:s,easing:o}}(n,t,e)}function Gl(n,t={}){return Object.keys(n).forEach(e=>{t[e]=n[e]}),t}function eM(n){const t=new Map;return Object.keys(n).forEach(e=>{t.set(e,n[e])}),t}function Ss(n,t=new Map,e){if(e)for(let[i,r]of e)t.set(i,r);for(let[i,r]of n)t.set(i,r);return t}function nM(n,t,e){return e?t+":"+e+";":""}function iM(n){let t="";for(let e=0;e{const s=Eg(r);e&&!e.has(r)&&e.set(r,n.style[s]),n.style[s]=i}),fg()&&iM(n))}function uo(n,t){n.style&&(t.forEach((e,i)=>{const r=Eg(i);n.style[r]=""}),fg()&&iM(n))}function Wl(n){return Array.isArray(n)?1==n.length?n[0]:HE(n):n}const Dg=new RegExp("{{\\s*(.+?)\\s*}}","g");function rM(n){let t=[];if("string"==typeof n){let e;for(;e=Dg.exec(n);)t.push(e[1]);Dg.lastIndex=0}return t}function _u(n,t,e){const i=n.toString(),r=i.replace(Dg,(s,o)=>{let a=t[o];return null==a&&(e.push(function u2(n){return new Be(3003,Rt)}()),a=""),a.toString()});return r==i?n:r}function vu(n){const t=[];let e=n.next();for(;!e.done;)t.push(e.value),e=n.next();return t}const Z2=/-+([a-z0-9])/g;function Eg(n){return n.replace(Z2,(...t)=>t[1].toUpperCase())}function X2(n){return n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function Ai(n,t,e){switch(t.type){case 7:return n.visitTrigger(t,e);case 0:return n.visitState(t,e);case 1:return n.visitTransition(t,e);case 2:return n.visitSequence(t,e);case 3:return n.visitGroup(t,e);case 4:return n.visitAnimate(t,e);case 5:return n.visitKeyframes(t,e);case 6:return n.visitStyle(t,e);case 8:return n.visitReference(t,e);case 9:return n.visitAnimateChild(t,e);case 10:return n.visitAnimateRef(t,e);case 11:return n.visitQuery(t,e);case 12:return n.visitStagger(t,e);default:throw function h2(n){return new Be(3004,Rt)}()}}function sM(n,t){return window.getComputedStyle(n)[t]}function rH(n,t){const e=[];return"string"==typeof n?n.split(/\s*,\s*/).forEach(i=>function sH(n,t,e){if(":"==n[0]){const l=function oH(n,t){switch(n){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(e,i)=>parseFloat(i)>parseFloat(e);case":decrement":return(e,i)=>parseFloat(i) *"}}(n,e);if("function"==typeof l)return void t.push(l);n=l}const i=n.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==i||i.length<4)return e.push(function M2(n){return new Be(3015,Rt)}()),t;const r=i[1],s=i[2],o=i[3];t.push(oM(r,o));"<"==s[0]&&!("*"==r&&"*"==o)&&t.push(oM(o,r))}(i,e,t)):e.push(n),e}const Cu=new Set(["true","1"]),Du=new Set(["false","0"]);function oM(n,t){const e=Cu.has(n)||Du.has(n),i=Cu.has(t)||Du.has(t);return(r,s)=>{let o="*"==n||n==r,a="*"==t||t==s;return!o&&e&&"boolean"==typeof r&&(o=r?Cu.has(n):Du.has(n)),!a&&i&&"boolean"==typeof s&&(a=s?Cu.has(t):Du.has(t)),o&&a}}const aH=new RegExp("s*:selfs*,?","g");function Mg(n,t,e,i){return new lH(n).build(t,e,i)}class lH{constructor(t){this._driver=t}build(t,e,i){const r=new uH(e);return this._resetContextStyleTimingState(r),Ai(this,Wl(t),r)}_resetContextStyleTimingState(t){t.currentQuerySelector="",t.collectedStyles=new Map,t.collectedStyles.set("",new Map),t.currentTime=0}visitTrigger(t,e){let i=e.queryCount=0,r=e.depCount=0;const s=[],o=[];return"@"==t.name.charAt(0)&&e.errors.push(function p2(){return new Be(3006,Rt)}()),t.definitions.forEach(a=>{if(this._resetContextStyleTimingState(e),0==a.type){const l=a,c=l.name;c.toString().split(/\s*,\s*/).forEach(d=>{l.name=d,s.push(this.visitState(l,e))}),l.name=c}else if(1==a.type){const l=this.visitTransition(a,e);i+=l.queryCount,r+=l.depCount,o.push(l)}else e.errors.push(function m2(){return new Be(3007,Rt)}())}),{type:7,name:t.name,states:s,transitions:o,queryCount:i,depCount:r,options:null}}visitState(t,e){const i=this.visitStyle(t.styles,e),r=t.options&&t.options.params||null;if(i.containsDynamicStyles){const s=new Set,o=r||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(l=>{rM(l).forEach(c=>{o.hasOwnProperty(c)||s.add(c)})})}),s.size&&(vu(s.values()),e.errors.push(function g2(n,t){return new Be(3008,Rt)}()))}return{type:0,name:t.name,style:i,options:r?{params:r}:null}}visitTransition(t,e){e.queryCount=0,e.depCount=0;const i=Ai(this,Wl(t.animation),e);return{type:1,matchers:rH(t.expr,e.errors),animation:i,queryCount:e.queryCount,depCount:e.depCount,options:ho(t.options)}}visitSequence(t,e){return{type:2,steps:t.steps.map(i=>Ai(this,i,e)),options:ho(t.options)}}visitGroup(t,e){const i=e.currentTime;let r=0;const s=t.steps.map(o=>{e.currentTime=i;const a=Ai(this,o,e);return r=Math.max(r,e.currentTime),a});return e.currentTime=r,{type:3,steps:s,options:ho(t.options)}}visitAnimate(t,e){const i=function fH(n,t){if(n.hasOwnProperty("duration"))return n;if("number"==typeof n)return xg(gu(n,t).duration,0,"");const e=n;if(e.split(/\s+/).some(s=>"{"==s.charAt(0)&&"{"==s.charAt(1))){const s=xg(0,0,"");return s.dynamic=!0,s.strValue=e,s}const r=gu(e,t);return xg(r.duration,r.delay,r.easing)}(t.timings,e.errors);e.currentAnimateTimings=i;let r,s=t.styles?t.styles:Qe({});if(5==s.type)r=this.visitKeyframes(s,e);else{let o=t.styles,a=!1;if(!o){a=!0;const c={};i.easing&&(c.easing=i.easing),o=Qe(c)}e.currentTime+=i.duration+i.delay;const l=this.visitStyle(o,e);l.isEmptyStep=a,r=l}return e.currentAnimateTimings=null,{type:4,timings:i,style:r,options:null}}visitStyle(t,e){const i=this._makeStyleAst(t,e);return this._validateStyleAst(i,e),i}_makeStyleAst(t,e){const i=[],r=Array.isArray(t.styles)?t.styles:[t.styles];for(let a of r)"string"==typeof a?a===rs?i.push(a):e.errors.push(new Be(3002,Rt)):i.push(eM(a));let s=!1,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!s))for(let l of a.values())if(l.toString().indexOf("{{")>=0){s=!0;break}}),{type:6,styles:i,easing:o,offset:t.offset,containsDynamicStyles:s,options:null}}_validateStyleAst(t,e){const i=e.currentAnimateTimings;let r=e.currentTime,s=e.currentTime;i&&s>0&&(s-=i.duration+i.delay),t.styles.forEach(o=>{"string"!=typeof o&&o.forEach((a,l)=>{const c=e.collectedStyles.get(e.currentQuerySelector),d=c.get(l);let f=!0;d&&(s!=r&&s>=d.startTime&&r<=d.endTime&&(e.errors.push(function v2(n,t,e,i,r){return new Be(3010,Rt)}()),f=!1),s=d.startTime),f&&c.set(l,{startTime:s,endTime:r}),e.options&&function Q2(n,t,e){const i=t.params||{},r=rM(n);r.length&&r.forEach(s=>{i.hasOwnProperty(s)||e.push(function d2(n){return new Be(3001,Rt)}())})}(a,e.options,e.errors)})})}visitKeyframes(t,e){const i={type:5,styles:[],options:null};if(!e.currentAnimateTimings)return e.errors.push(function y2(){return new Be(3011,Rt)}()),i;let s=0;const o=[];let a=!1,l=!1,c=0;const d=t.steps.map(ce=>{const Te=this._makeStyleAst(ce,e);let he=null!=Te.offset?Te.offset:function hH(n){if("string"==typeof n)return null;let t=null;if(Array.isArray(n))n.forEach(e=>{if(e instanceof Map&&e.has("offset")){const i=e;t=parseFloat(i.get("offset")),i.delete("offset")}});else if(n instanceof Map&&n.has("offset")){const e=n;t=parseFloat(e.get("offset")),e.delete("offset")}return t}(Te.styles),Oe=0;return null!=he&&(s++,Oe=Te.offset=he),l=l||Oe<0||Oe>1,a=a||Oe0&&s{const he=w>0?Te==k?1:w*Te:o[Te],Oe=he*ae;e.currentTime=j+K.delay+Oe,K.duration=Oe,this._validateStyleAst(ce,e),ce.offset=he,i.styles.push(ce)}),i}visitReference(t,e){return{type:8,animation:Ai(this,Wl(t.animation),e),options:ho(t.options)}}visitAnimateChild(t,e){return e.depCount++,{type:9,options:ho(t.options)}}visitAnimateRef(t,e){return{type:10,animation:this.visitReference(t.animation,e),options:ho(t.options)}}visitQuery(t,e){const i=e.currentQuerySelector,r=t.options||{};e.queryCount++,e.currentQuery=t;const[s,o]=function cH(n){const t=!!n.split(/\s*,\s*/).find(e=>":self"==e);return t&&(n=n.replace(aH,"")),n=n.replace(/@\*/g,mu).replace(/@\w+/g,e=>mu+"-"+e.slice(1)).replace(/:animating/g,wg),[n,t]}(t.selector);e.currentQuerySelector=i.length?i+" "+s:s,Ti(e.collectedStyles,e.currentQuerySelector,new Map);const a=Ai(this,Wl(t.animation),e);return e.currentQuery=null,e.currentQuerySelector=i,{type:11,selector:s,limit:r.limit||0,optional:!!r.optional,includeSelf:o,animation:a,originalSelector:t.selector,options:ho(t.options)}}visitStagger(t,e){e.currentQuery||e.errors.push(function D2(){return new Be(3013,Rt)}());const i="full"===t.timings?{duration:0,delay:0,easing:"full"}:gu(t.timings,e.errors,!0);return{type:12,animation:Ai(this,Wl(t.animation),e),timings:i,options:null}}}class uH{constructor(t){this.errors=t,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles=new Map,this.options=null,this.unsupportedCSSPropertiesFound=new Set,this.nonAnimatableCSSPropertiesFound=new Set}}function ho(n){return n?(n=Gl(n)).params&&(n.params=function dH(n){return n?Gl(n):null}(n.params)):n={},n}function xg(n,t,e){return{duration:n,delay:t,easing:e}}function Sg(n,t,e,i,r,s,o=null,a=!1){return{type:1,element:n,keyframes:t,preStyleProps:e,postStyleProps:i,duration:r,delay:s,totalTime:r+s,easing:o,subTimeline:a}}class Eu{constructor(){this._map=new Map}get(t){return this._map.get(t)||[]}append(t,e){let i=this._map.get(t);i||this._map.set(t,i=[]),i.push(...e)}has(t){return this._map.has(t)}clear(){this._map.clear()}}const gH=new RegExp(":enter","g"),vH=new RegExp(":leave","g");function kg(n,t,e,i,r,s=new Map,o=new Map,a,l,c=[]){return(new yH).buildKeyframes(n,t,e,i,r,s,o,a,l,c)}class yH{buildKeyframes(t,e,i,r,s,o,a,l,c,d=[]){c=c||new Eu;const f=new Tg(t,e,c,r,s,d,[]);f.options=l;const w=l.delay?xs(l.delay):0;f.currentTimeline.delayNextStep(w),f.currentTimeline.setStyles([o],null,f.errors,l),Ai(this,i,f);const k=f.timelines.filter(j=>j.containsAnimation());if(k.length&&a.size){let j;for(let K=k.length-1;K>=0;K--){const ae=k[K];if(ae.element===e){j=ae;break}}j&&!j.allowOnlyTimelineStyles()&&j.setStyles([a],null,f.errors,l)}return k.length?k.map(j=>j.buildKeyframes()):[Sg(e,[],[],[],0,w,"",!1)]}visitTrigger(t,e){}visitState(t,e){}visitTransition(t,e){}visitAnimateChild(t,e){const i=e.subInstructions.get(e.element);if(i){const r=e.createSubContext(t.options),s=e.currentTimeline.currentTime,o=this._visitSubInstructions(i,r,r.options);s!=o&&e.transformIntoNewTimeline(o)}e.previousNode=t}visitAnimateRef(t,e){const i=e.createSubContext(t.options);i.transformIntoNewTimeline(),this.visitReference(t.animation,i),e.transformIntoNewTimeline(i.currentTimeline.currentTime),e.previousNode=t}_visitSubInstructions(t,e,i){let s=e.currentTimeline.currentTime;const o=null!=i.duration?xs(i.duration):null,a=null!=i.delay?xs(i.delay):null;return 0!==o&&t.forEach(l=>{const c=e.appendInstructionToTimeline(l,o,a);s=Math.max(s,c.duration+c.delay)}),s}visitReference(t,e){e.updateOptions(t.options,!0),Ai(this,t.animation,e),e.previousNode=t}visitSequence(t,e){const i=e.subContextCount;let r=e;const s=t.options;if(s&&(s.params||s.delay)&&(r=e.createSubContext(s),r.transformIntoNewTimeline(),null!=s.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=Mu);const o=xs(s.delay);r.delayNextStep(o)}t.steps.length&&(t.steps.forEach(o=>Ai(this,o,r)),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>i&&r.transformIntoNewTimeline()),e.previousNode=t}visitGroup(t,e){const i=[];let r=e.currentTimeline.currentTime;const s=t.options&&t.options.delay?xs(t.options.delay):0;t.steps.forEach(o=>{const a=e.createSubContext(t.options);s&&a.delayNextStep(s),Ai(this,o,a),r=Math.max(r,a.currentTimeline.currentTime),i.push(a.currentTimeline)}),i.forEach(o=>e.currentTimeline.mergeTimelineCollectedStyles(o)),e.transformIntoNewTimeline(r),e.previousNode=t}_visitTiming(t,e){if(t.dynamic){const i=t.strValue;return gu(e.params?_u(i,e.params,e.errors):i,e.errors)}return{duration:t.duration,delay:t.delay,easing:t.easing}}visitAnimate(t,e){const i=e.currentAnimateTimings=this._visitTiming(t.timings,e),r=e.currentTimeline;i.delay&&(e.incrementTime(i.delay),r.snapshotCurrentStyles());const s=t.style;5==s.type?this.visitKeyframes(s,e):(e.incrementTime(i.duration),this.visitStyle(s,e),r.applyStylesToKeyframe()),e.currentAnimateTimings=null,e.previousNode=t}visitStyle(t,e){const i=e.currentTimeline,r=e.currentAnimateTimings;!r&&i.hasCurrentStyleProperties()&&i.forwardFrame();const s=r&&r.easing||t.easing;t.isEmptyStep?i.applyEmptyStep(s):i.setStyles(t.styles,s,e.errors,e.options),e.previousNode=t}visitKeyframes(t,e){const i=e.currentAnimateTimings,r=e.currentTimeline.duration,s=i.duration,a=e.createSubContext().currentTimeline;a.easing=i.easing,t.styles.forEach(l=>{a.forwardTime((l.offset||0)*s),a.setStyles(l.styles,l.easing,e.errors,e.options),a.applyStylesToKeyframe()}),e.currentTimeline.mergeTimelineCollectedStyles(a),e.transformIntoNewTimeline(r+s),e.previousNode=t}visitQuery(t,e){const i=e.currentTimeline.currentTime,r=t.options||{},s=r.delay?xs(r.delay):0;s&&(6===e.previousNode.type||0==i&&e.currentTimeline.hasCurrentStyleProperties())&&(e.currentTimeline.snapshotCurrentStyles(),e.previousNode=Mu);let o=i;const a=e.invokeQuery(t.selector,t.originalSelector,t.limit,t.includeSelf,!!r.optional,e.errors);e.currentQueryTotal=a.length;let l=null;a.forEach((c,d)=>{e.currentQueryIndex=d;const f=e.createSubContext(t.options,c);s&&f.delayNextStep(s),c===e.element&&(l=f.currentTimeline),Ai(this,t.animation,f),f.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,f.currentTimeline.currentTime)}),e.currentQueryIndex=0,e.currentQueryTotal=0,e.transformIntoNewTimeline(o),l&&(e.currentTimeline.mergeTimelineCollectedStyles(l),e.currentTimeline.snapshotCurrentStyles()),e.previousNode=t}visitStagger(t,e){const i=e.parentContext,r=e.currentTimeline,s=t.timings,o=Math.abs(s.duration),a=o*(e.currentQueryTotal-1);let l=o*e.currentQueryIndex;switch(s.duration<0?"reverse":s.easing){case"reverse":l=a-l;break;case"full":l=i.currentStaggerTime}const d=e.currentTimeline;l&&d.delayNextStep(l);const f=d.currentTime;Ai(this,t.animation,e),e.previousNode=t,i.currentStaggerTime=r.currentTime-f+(r.startTime-i.currentTimeline.startTime)}}const Mu={};class Tg{constructor(t,e,i,r,s,o,a,l){this._driver=t,this.element=e,this.subInstructions=i,this._enterClassName=r,this._leaveClassName=s,this.errors=o,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=Mu,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=l||new xu(this._driver,e,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(t,e){if(!t)return;const i=t;let r=this.options;null!=i.duration&&(r.duration=xs(i.duration)),null!=i.delay&&(r.delay=xs(i.delay));const s=i.params;if(s){let o=r.params;o||(o=this.options.params={}),Object.keys(s).forEach(a=>{(!e||!o.hasOwnProperty(a))&&(o[a]=_u(s[a],o,this.errors))})}}_copyOptions(){const t={};if(this.options){const e=this.options.params;if(e){const i=t.params={};Object.keys(e).forEach(r=>{i[r]=e[r]})}}return t}createSubContext(t=null,e,i){const r=e||this.element,s=new Tg(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,i||0));return s.previousNode=this.previousNode,s.currentAnimateTimings=this.currentAnimateTimings,s.options=this._copyOptions(),s.updateOptions(t),s.currentQueryIndex=this.currentQueryIndex,s.currentQueryTotal=this.currentQueryTotal,s.parentContext=this,this.subContextCount++,s}transformIntoNewTimeline(t){return this.previousNode=Mu,this.currentTimeline=this.currentTimeline.fork(this.element,t),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(t,e,i){const r={duration:null!=e?e:t.duration,delay:this.currentTimeline.currentTime+(null!=i?i:0)+t.delay,easing:""},s=new bH(this._driver,t.element,t.keyframes,t.preStyleProps,t.postStyleProps,r,t.stretchStartingKeyframe);return this.timelines.push(s),r}incrementTime(t){this.currentTimeline.forwardTime(this.currentTimeline.duration+t)}delayNextStep(t){t>0&&this.currentTimeline.delayNextStep(t)}invokeQuery(t,e,i,r,s,o){let a=[];if(r&&a.push(this.element),t.length>0){t=(t=t.replace(gH,"."+this._enterClassName)).replace(vH,"."+this._leaveClassName);let c=this._driver.query(this.element,t,1!=i);0!==i&&(c=i<0?c.slice(c.length+i,c.length):c.slice(0,i)),a.push(...c)}return!s&&0==a.length&&o.push(function E2(n){return new Be(3014,Rt)}()),a}}class xu{constructor(t,e,i,r){this._driver=t,this.element=e,this.startTime=i,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe=new Map,this._currentKeyframe=new Map,this._keyframes=new Map,this._styleSummary=new Map,this._localTimelineStyles=new Map,this._pendingStyles=new Map,this._backFill=new Map,this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(e),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(e,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(t){const e=1===this._keyframes.size&&this._pendingStyles.size;this.duration||e?(this.forwardTime(this.currentTime+t),e&&this.snapshotCurrentStyles()):this.startTime+=t}fork(t,e){return this.applyStylesToKeyframe(),new xu(this._driver,t,e||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(t){this.applyStylesToKeyframe(),this.duration=t,this._loadKeyframe()}_updateStyle(t,e){this._localTimelineStyles.set(t,e),this._globalTimelineStyles.set(t,e),this._styleSummary.set(t,{time:this.currentTime,value:e})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(t){t&&this._previousKeyframe.set("easing",t);for(let[e,i]of this._globalTimelineStyles)this._backFill.set(e,i||rs),this._currentKeyframe.set(e,rs);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(t,e,i,r){e&&this._previousKeyframe.set("easing",e);const s=r&&r.params||{},o=function wH(n,t){const e=new Map;let i;return n.forEach(r=>{if("*"===r){i=i||t.keys();for(let s of i)e.set(s,rs)}else Ss(r,e)}),e}(t,this._globalTimelineStyles);for(let[a,l]of o){const c=_u(l,s,i);this._pendingStyles.set(a,c),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)||rs),this._updateStyle(a,c)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((t,e)=>{this._currentKeyframe.set(e,t)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((t,e)=>{this._currentKeyframe.has(e)||this._currentKeyframe.set(e,t)}))}snapshotCurrentStyles(){for(let[t,e]of this._localTimelineStyles)this._pendingStyles.set(t,e),this._updateStyle(t,e)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const t=[];for(let e in this._currentKeyframe)t.push(e);return t}mergeTimelineCollectedStyles(t){t._styleSummary.forEach((e,i)=>{const r=this._styleSummary.get(i);(!r||e.time>r.time)&&this._updateStyle(i,e.value)})}buildKeyframes(){this.applyStylesToKeyframe();const t=new Set,e=new Set,i=1===this._keyframes.size&&0===this.duration;let r=[];this._keyframes.forEach((a,l)=>{const c=Ss(a,new Map,this._backFill);c.forEach((d,f)=>{"!"===d?t.add(f):d===rs&&e.add(f)}),i||c.set("offset",l/this.duration),r.push(c)});const s=t.size?vu(t.values()):[],o=e.size?vu(e.values()):[];if(i){const a=r[0],l=new Map(a);a.set("offset",0),l.set("offset",1),r=[a,l]}return Sg(this.element,r,s,o,this.duration,this.startTime,this.easing,!1)}}class bH extends xu{constructor(t,e,i,r,s,o,a=!1){super(t,e,o.delay),this.keyframes=i,this.preStyleProps=r,this.postStyleProps=s,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let t=this.keyframes,{delay:e,duration:i,easing:r}=this.timings;if(this._stretchStartingKeyframe&&e){const s=[],o=i+e,a=e/o,l=Ss(t[0]);l.set("offset",0),s.push(l);const c=Ss(t[0]);c.set("offset",cM(a)),s.push(c);const d=t.length-1;for(let f=1;f<=d;f++){let w=Ss(t[f]);const k=w.get("offset");w.set("offset",cM((e+k*i)/o)),s.push(w)}i=o,e=0,r="",t=s}return Sg(this.element,t,this.preStyleProps,this.postStyleProps,i,e,r,!0)}}function cM(n,t=3){const e=Math.pow(10,t-1);return Math.round(n*e)/e}class Ag{}const CH=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class DH extends Ag{normalizePropertyName(t,e){return Eg(t)}normalizeStyleValue(t,e,i,r){let s="";const o=i.toString().trim();if(CH.has(e)&&0!==i&&"0"!==i)if("number"==typeof i)s="px";else{const a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&r.push(function f2(n,t){return new Be(3005,Rt)}())}return o+s}}function dM(n,t,e,i,r,s,o,a,l,c,d,f,w){return{type:0,element:n,triggerName:t,isRemovalTransition:r,fromState:e,fromStyles:s,toState:i,toStyles:o,timelines:a,queriedElements:l,preStyleProps:c,postStyleProps:d,totalTime:f,errors:w}}const Ig={};class uM{constructor(t,e,i){this._triggerName=t,this.ast=e,this._stateStyles=i}match(t,e,i,r){return function EH(n,t,e,i,r){return n.some(s=>s(t,e,i,r))}(this.ast.matchers,t,e,i,r)}buildStyles(t,e,i){let r=this._stateStyles.get("*");return void 0!==t&&(r=this._stateStyles.get(null==t?void 0:t.toString())||r),r?r.buildStyles(e,i):new Map}build(t,e,i,r,s,o,a,l,c,d){var f;const w=[],k=this.ast.options&&this.ast.options.params||Ig,K=this.buildStyles(i,a&&a.params||Ig,w),ae=l&&l.params||Ig,ce=this.buildStyles(r,ae,w),Te=new Set,he=new Map,Oe=new Map,ft="void"===r,Nt={params:MH(ae,k),delay:null===(f=this.ast.options)||void 0===f?void 0:f.delay},pn=d?[]:kg(t,e,this.ast.animation,s,o,K,ce,Nt,c,w);let Zn=0;if(pn.forEach(ci=>{Zn=Math.max(ci.duration+ci.delay,Zn)}),w.length)return dM(e,this._triggerName,i,r,ft,K,ce,[],[],he,Oe,Zn,w);pn.forEach(ci=>{const us=ci.element,hs=Ti(he,us,new Set);ci.preStyleProps.forEach(Lr=>hs.add(Lr));const fs=Ti(Oe,us,new Set);ci.postStyleProps.forEach(Lr=>fs.add(Lr)),us!==e&&Te.add(us)});const Vs=vu(Te.values());return dM(e,this._triggerName,i,r,ft,K,ce,pn,Vs,he,Oe,Zn)}}function MH(n,t){const e=Gl(t);for(const i in n)n.hasOwnProperty(i)&&null!=n[i]&&(e[i]=n[i]);return e}class xH{constructor(t,e,i){this.styles=t,this.defaultParams=e,this.normalizer=i}buildStyles(t,e){const i=new Map,r=Gl(this.defaultParams);return Object.keys(t).forEach(s=>{const o=t[s];null!==o&&(r[s]=o)}),this.styles.styles.forEach(s=>{"string"!=typeof s&&s.forEach((o,a)=>{o&&(o=_u(o,r,e));const l=this.normalizer.normalizePropertyName(a,e);o=this.normalizer.normalizeStyleValue(a,l,o,e),i.set(l,o)})}),i}}class kH{constructor(t,e,i){this.name=t,this.ast=e,this._normalizer=i,this.transitionFactories=[],this.states=new Map,e.states.forEach(r=>{this.states.set(r.name,new xH(r.style,r.options&&r.options.params||{},i))}),hM(this.states,"true","1"),hM(this.states,"false","0"),e.transitions.forEach(r=>{this.transitionFactories.push(new uM(t,r,this.states))}),this.fallbackTransition=function TH(n,t,e){return new uM(n,{type:1,animation:{type:2,steps:[],options:null},matchers:[(o,a)=>!0],options:null,queryCount:0,depCount:0},t)}(t,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(t,e,i,r){return this.transitionFactories.find(o=>o.match(t,e,i,r))||null}matchStyles(t,e,i){return this.fallbackTransition.buildStyles(t,e,i)}}function hM(n,t,e){n.has(t)?n.has(e)||n.set(e,n.get(t)):n.has(e)&&n.set(t,n.get(e))}const AH=new Eu;class IH{constructor(t,e,i){this.bodyNode=t,this._driver=e,this._normalizer=i,this._animations=new Map,this._playersById=new Map,this.players=[]}register(t,e){const i=[],s=Mg(this._driver,e,i,[]);if(i.length)throw function I2(n){return new Be(3503,Rt)}();this._animations.set(t,s)}_buildPlayer(t,e,i){const r=t.element,s=$E(0,this._normalizer,0,t.keyframes,e,i);return this._driver.animate(r,s,t.duration,t.delay,t.easing,[],!0)}create(t,e,i={}){const r=[],s=this._animations.get(t);let o;const a=new Map;if(s?(o=kg(this._driver,e,s,bg,fu,new Map,new Map,i,AH,r),o.forEach(d=>{const f=Ti(a,d.element,new Map);d.postStyleProps.forEach(w=>f.set(w,null))})):(r.push(function R2(){return new Be(3300,Rt)}()),o=[]),r.length)throw function P2(n){return new Be(3504,Rt)}();a.forEach((d,f)=>{d.forEach((w,k)=>{d.set(k,this._driver.computeStyle(f,k,rs))})});const c=Ms(o.map(d=>{const f=a.get(d.element);return this._buildPlayer(d,new Map,f)}));return this._playersById.set(t,c),c.onDestroy(()=>this.destroy(t)),this.players.push(c),c}destroy(t){const e=this._getPlayer(t);e.destroy(),this._playersById.delete(t);const i=this.players.indexOf(e);i>=0&&this.players.splice(i,1)}_getPlayer(t){const e=this._playersById.get(t);if(!e)throw function O2(n){return new Be(3301,Rt)}();return e}listen(t,e,i,r){const s=gg(e,"","","");return pg(this._getPlayer(t),i,s,r),()=>{}}command(t,e,i,r){if("register"==i)return void this.register(t,r[0]);if("create"==i)return void this.create(t,e,r[0]||{});const s=this._getPlayer(t);switch(i){case"play":s.play();break;case"pause":s.pause();break;case"reset":s.reset();break;case"restart":s.restart();break;case"finish":s.finish();break;case"init":s.init();break;case"setPosition":s.setPosition(parseFloat(r[0]));break;case"destroy":this.destroy(t)}}}const fM="ng-animate-queued",Rg="ng-animate-disabled",LH=[],pM={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},NH={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},$i="__ng_removed";class Pg{constructor(t,e=""){this.namespaceId=e;const i=t&&t.hasOwnProperty("value");if(this.value=function jH(n){return null!=n?n:null}(i?t.value:t),i){const s=Gl(t);delete s.value,this.options=s}else this.options={};this.options.params||(this.options.params={})}get params(){return this.options.params}absorbOptions(t){const e=t.params;if(e){const i=this.options.params;Object.keys(e).forEach(r=>{null==i[r]&&(i[r]=e[r])})}}}const ql="void",Og=new Pg(ql);class BH{constructor(t,e,i){this.id=t,this.hostElement=e,this._engine=i,this.players=[],this._triggers=new Map,this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+t,Gi(e,this._hostClassName)}listen(t,e,i,r){if(!this._triggers.has(e))throw function F2(n,t){return new Be(3302,Rt)}();if(null==i||0==i.length)throw function L2(n){return new Be(3303,Rt)}();if(!function UH(n){return"start"==n||"done"==n}(i))throw function N2(n,t){return new Be(3400,Rt)}();const s=Ti(this._elementListeners,t,[]),o={name:e,phase:i,callback:r};s.push(o);const a=Ti(this._engine.statesByElement,t,new Map);return a.has(e)||(Gi(t,pu),Gi(t,pu+"-"+e),a.set(e,Og)),()=>{this._engine.afterFlush(()=>{const l=s.indexOf(o);l>=0&&s.splice(l,1),this._triggers.has(e)||a.delete(e)})}}register(t,e){return!this._triggers.has(t)&&(this._triggers.set(t,e),!0)}_getTrigger(t){const e=this._triggers.get(t);if(!e)throw function B2(n){return new Be(3401,Rt)}();return e}trigger(t,e,i,r=!0){const s=this._getTrigger(e),o=new Fg(this.id,e,t);let a=this._engine.statesByElement.get(t);a||(Gi(t,pu),Gi(t,pu+"-"+e),this._engine.statesByElement.set(t,a=new Map));let l=a.get(e);const c=new Pg(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),a.set(e,c),l||(l=Og),c.value!==ql&&l.value===c.value){if(!function GH(n,t){const e=Object.keys(n),i=Object.keys(t);if(e.length!=i.length)return!1;for(let r=0;r{uo(t,ae),kr(t,ce)})}return}const w=Ti(this._engine.playersByElement,t,[]);w.forEach(K=>{K.namespaceId==this.id&&K.triggerName==e&&K.queued&&K.destroy()});let k=s.matchTransition(l.value,c.value,t,c.params),j=!1;if(!k){if(!r)return;k=s.fallbackTransition,j=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:t,triggerName:e,transition:k,fromState:l,toState:c,player:o,isFallbackTransition:j}),j||(Gi(t,fM),o.onStart(()=>{wa(t,fM)})),o.onDone(()=>{let K=this.players.indexOf(o);K>=0&&this.players.splice(K,1);const ae=this._engine.playersByElement.get(t);if(ae){let ce=ae.indexOf(o);ce>=0&&ae.splice(ce,1)}}),this.players.push(o),w.push(o),o}deregister(t){this._triggers.delete(t),this._engine.statesByElement.forEach(e=>e.delete(t)),this._elementListeners.forEach((e,i)=>{this._elementListeners.set(i,e.filter(r=>r.name!=t))})}clearElementCache(t){this._engine.statesByElement.delete(t),this._elementListeners.delete(t);const e=this._engine.playersByElement.get(t);e&&(e.forEach(i=>i.destroy()),this._engine.playersByElement.delete(t))}_signalRemovalForInnerTriggers(t,e){const i=this._engine.driver.query(t,mu,!0);i.forEach(r=>{if(r[$i])return;const s=this._engine.fetchNamespacesByElement(r);s.size?s.forEach(o=>o.triggerLeaveAnimation(r,e,!1,!0)):this.clearElementCache(r)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(r=>this.clearElementCache(r)))}triggerLeaveAnimation(t,e,i,r){const s=this._engine.statesByElement.get(t),o=new Map;if(s){const a=[];if(s.forEach((l,c)=>{if(o.set(c,l.value),this._triggers.has(c)){const d=this.trigger(t,c,ql,r);d&&a.push(d)}}),a.length)return this._engine.markElementAsRemoved(this.id,t,!0,e,o),i&&Ms(a).onDone(()=>this._engine.processLeaveNode(t)),!0}return!1}prepareLeaveAnimationListeners(t){const e=this._elementListeners.get(t),i=this._engine.statesByElement.get(t);if(e&&i){const r=new Set;e.forEach(s=>{const o=s.name;if(r.has(o))return;r.add(o);const l=this._triggers.get(o).fallbackTransition,c=i.get(o)||Og,d=new Pg(ql),f=new Fg(this.id,o,t);this._engine.totalQueuedPlayers++,this._queue.push({element:t,triggerName:o,transition:l,fromState:c,toState:d,player:f,isFallbackTransition:!0})})}}removeNode(t,e){const i=this._engine;if(t.childElementCount&&this._signalRemovalForInnerTriggers(t,e),this.triggerLeaveAnimation(t,e,!0))return;let r=!1;if(i.totalAnimations){const s=i.players.length?i.playersByQueriedElement.get(t):[];if(s&&s.length)r=!0;else{let o=t;for(;o=o.parentNode;)if(i.statesByElement.get(o)){r=!0;break}}}if(this.prepareLeaveAnimationListeners(t),r)i.markElementAsRemoved(this.id,t,!1,e);else{const s=t[$i];(!s||s===pM)&&(i.afterFlush(()=>this.clearElementCache(t)),i.destroyInnerAnimations(t),i._onRemovalComplete(t,e))}}insertNode(t,e){Gi(t,this._hostClassName)}drainQueuedTransitions(t){const e=[];return this._queue.forEach(i=>{const r=i.player;if(r.destroyed)return;const s=i.element,o=this._elementListeners.get(s);o&&o.forEach(a=>{if(a.name==i.triggerName){const l=gg(s,i.triggerName,i.fromState.value,i.toState.value);l._data=t,pg(i.player,a.phase,l,a.callback)}}),r.markedForDestroy?this._engine.afterFlush(()=>{r.destroy()}):e.push(i)}),this._queue=[],e.sort((i,r)=>{const s=i.transition.ast.depCount,o=r.transition.ast.depCount;return 0==s||0==o?s-o:this._engine.driver.containsElement(i.element,r.element)?1:-1})}destroy(t){this.players.forEach(e=>e.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,t)}elementContainsData(t){let e=!1;return this._elementListeners.has(t)&&(e=!0),e=!!this._queue.find(i=>i.element===t)||e,e}}class VH{constructor(t,e,i){this.bodyNode=t,this.driver=e,this._normalizer=i,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(r,s)=>{}}_onRemovalComplete(t,e){this.onRemovalComplete(t,e)}get queuedPlayers(){const t=[];return this._namespaceList.forEach(e=>{e.players.forEach(i=>{i.queued&&t.push(i)})}),t}createNamespace(t,e){const i=new BH(t,e,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,e)?this._balanceNamespaceList(i,e):(this.newHostElements.set(e,i),this.collectEnterElement(e)),this._namespaceLookup[t]=i}_balanceNamespaceList(t,e){const i=this._namespaceList,r=this.namespacesByHostElement;if(i.length-1>=0){let o=!1,a=this.driver.getParentElement(e);for(;a;){const l=r.get(a);if(l){const c=i.indexOf(l);i.splice(c+1,0,t),o=!0;break}a=this.driver.getParentElement(a)}o||i.unshift(t)}else i.push(t);return r.set(e,t),t}register(t,e){let i=this._namespaceLookup[t];return i||(i=this.createNamespace(t,e)),i}registerTrigger(t,e,i){let r=this._namespaceLookup[t];r&&r.register(e,i)&&this.totalAnimations++}destroy(t,e){if(!t)return;const i=this._fetchNamespace(t);this.afterFlush(()=>{this.namespacesByHostElement.delete(i.hostElement),delete this._namespaceLookup[t];const r=this._namespaceList.indexOf(i);r>=0&&this._namespaceList.splice(r,1)}),this.afterFlushAnimationsDone(()=>i.destroy(e))}_fetchNamespace(t){return this._namespaceLookup[t]}fetchNamespacesByElement(t){const e=new Set,i=this.statesByElement.get(t);if(i)for(let r of i.values())if(r.namespaceId){const s=this._fetchNamespace(r.namespaceId);s&&e.add(s)}return e}trigger(t,e,i,r){if(Su(e)){const s=this._fetchNamespace(t);if(s)return s.trigger(e,i,r),!0}return!1}insertNode(t,e,i,r){if(!Su(e))return;const s=e[$i];if(s&&s.setForRemoval){s.setForRemoval=!1,s.setForMove=!0;const o=this.collectedLeaveElements.indexOf(e);o>=0&&this.collectedLeaveElements.splice(o,1)}if(t){const o=this._fetchNamespace(t);o&&o.insertNode(e,i)}r&&this.collectEnterElement(e)}collectEnterElement(t){this.collectedEnterElements.push(t)}markElementAsDisabled(t,e){e?this.disabledNodes.has(t)||(this.disabledNodes.add(t),Gi(t,Rg)):this.disabledNodes.has(t)&&(this.disabledNodes.delete(t),wa(t,Rg))}removeNode(t,e,i,r){if(Su(e)){const s=t?this._fetchNamespace(t):null;if(s?s.removeNode(e,r):this.markElementAsRemoved(t,e,!1,r),i){const o=this.namespacesByHostElement.get(e);o&&o.id!==t&&o.removeNode(e,r)}}else this._onRemovalComplete(e,r)}markElementAsRemoved(t,e,i,r,s){this.collectedLeaveElements.push(e),e[$i]={namespaceId:t,setForRemoval:r,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:s}}listen(t,e,i,r,s){return Su(e)?this._fetchNamespace(t).listen(e,i,r,s):()=>{}}_buildInstruction(t,e,i,r,s){return t.transition.build(this.driver,t.element,t.fromState.value,t.toState.value,i,r,t.fromState.options,t.toState.options,e,s)}destroyInnerAnimations(t){let e=this.driver.query(t,mu,!0);e.forEach(i=>this.destroyActiveAnimationsForElement(i)),0!=this.playersByQueriedElement.size&&(e=this.driver.query(t,wg,!0),e.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(t){const e=this.playersByElement.get(t);e&&e.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(t){const e=this.playersByQueriedElement.get(t);e&&e.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(t=>{if(this.players.length)return Ms(this.players).onDone(()=>t());t()})}processLeaveNode(t){var e;const i=t[$i];if(i&&i.setForRemoval){if(t[$i]=pM,i.namespaceId){this.destroyInnerAnimations(t);const r=this._fetchNamespace(i.namespaceId);r&&r.clearElementCache(t)}this._onRemovalComplete(t,i.setForRemoval)}!(null===(e=t.classList)||void 0===e)&&e.contains(Rg)&&this.markElementAsDisabled(t,!1),this.driver.query(t,".ng-animate-disabled",!0).forEach(r=>{this.markElementAsDisabled(r,!1)})}flush(t=-1){let e=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,r)=>this._balanceNamespaceList(i,r)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;ii()),this._flushFns=[],this._whenQuietFns.length){const i=this._whenQuietFns;this._whenQuietFns=[],e.length?Ms(e).onDone(()=>{i.forEach(r=>r())}):i.forEach(r=>r())}}reportError(t){throw function V2(n){return new Be(3402,Rt)}()}_flushAnimations(t,e){const i=new Eu,r=[],s=new Map,o=[],a=new Map,l=new Map,c=new Map,d=new Set;this.disabledNodes.forEach(ze=>{d.add(ze);const nt=this.driver.query(ze,".ng-animate-queued",!0);for(let ot=0;ot{const ot=bg+K++;j.set(nt,ot),ze.forEach(St=>Gi(St,ot))});const ae=[],ce=new Set,Te=new Set;for(let ze=0;zece.add(St)):Te.add(nt))}const he=new Map,Oe=_M(w,Array.from(ce));Oe.forEach((ze,nt)=>{const ot=fu+K++;he.set(nt,ot),ze.forEach(St=>Gi(St,ot))}),t.push(()=>{k.forEach((ze,nt)=>{const ot=j.get(nt);ze.forEach(St=>wa(St,ot))}),Oe.forEach((ze,nt)=>{const ot=he.get(nt);ze.forEach(St=>wa(St,ot))}),ae.forEach(ze=>{this.processLeaveNode(ze)})});const ft=[],Nt=[];for(let ze=this._namespaceList.length-1;ze>=0;ze--)this._namespaceList[ze].drainQueuedTransitions(e).forEach(ot=>{const St=ot.player,mn=ot.element;if(ft.push(St),this.collectedEnterElements.length){const Xn=mn[$i];if(Xn&&Xn.setForMove){if(Xn.previousTriggersValues&&Xn.previousTriggersValues.has(ot.triggerName)){const ko=Xn.previousTriggersValues.get(ot.triggerName),Zi=this.statesByElement.get(ot.element);if(Zi&&Zi.has(ot.triggerName)){const ef=Zi.get(ot.triggerName);ef.value=ko,Zi.set(ot.triggerName,ef)}}return void St.destroy()}}const Nr=!f||!this.driver.containsElement(f,mn),Pi=he.get(mn),Hs=j.get(mn),ln=this._buildInstruction(ot,i,Hs,Pi,Nr);if(ln.errors&&ln.errors.length)return void Nt.push(ln);if(Nr)return St.onStart(()=>uo(mn,ln.fromStyles)),St.onDestroy(()=>kr(mn,ln.toStyles)),void r.push(St);if(ot.isFallbackTransition)return St.onStart(()=>uo(mn,ln.fromStyles)),St.onDestroy(()=>kr(mn,ln.toStyles)),void r.push(St);const vA=[];ln.timelines.forEach(Xn=>{Xn.stretchStartingKeyframe=!0,this.disabledNodes.has(Xn.element)||vA.push(Xn)}),ln.timelines=vA,i.append(mn,ln.timelines),o.push({instruction:ln,player:St,element:mn}),ln.queriedElements.forEach(Xn=>Ti(a,Xn,[]).push(St)),ln.preStyleProps.forEach((Xn,ko)=>{if(Xn.size){let Zi=l.get(ko);Zi||l.set(ko,Zi=new Set),Xn.forEach((ef,Zv)=>Zi.add(Zv))}}),ln.postStyleProps.forEach((Xn,ko)=>{let Zi=c.get(ko);Zi||c.set(ko,Zi=new Set),Xn.forEach((ef,Zv)=>Zi.add(Zv))})});if(Nt.length){const ze=[];Nt.forEach(nt=>{ze.push(function H2(n,t){return new Be(3505,Rt)}())}),ft.forEach(nt=>nt.destroy()),this.reportError(ze)}const pn=new Map,Zn=new Map;o.forEach(ze=>{const nt=ze.element;i.has(nt)&&(Zn.set(nt,nt),this._beforeAnimationBuild(ze.player.namespaceId,ze.instruction,pn))}),r.forEach(ze=>{const nt=ze.element;this._getPreviousPlayers(nt,!1,ze.namespaceId,ze.triggerName,null).forEach(St=>{Ti(pn,nt,[]).push(St),St.destroy()})});const Vs=ae.filter(ze=>yM(ze,l,c)),ci=new Map;gM(ci,this.driver,Te,c,rs).forEach(ze=>{yM(ze,l,c)&&Vs.push(ze)});const hs=new Map;k.forEach((ze,nt)=>{gM(hs,this.driver,new Set(ze),l,"!")}),Vs.forEach(ze=>{var nt,ot;const St=ci.get(ze),mn=hs.get(ze);ci.set(ze,new Map([...Array.from(null!==(nt=null==St?void 0:St.entries())&&void 0!==nt?nt:[]),...Array.from(null!==(ot=null==mn?void 0:mn.entries())&&void 0!==ot?ot:[])]))});const fs=[],Lr=[],Ga={};o.forEach(ze=>{const{element:nt,player:ot,instruction:St}=ze;if(i.has(nt)){if(d.has(nt))return ot.onDestroy(()=>kr(nt,St.toStyles)),ot.disabled=!0,ot.overrideTotalTime(St.totalTime),void r.push(ot);let mn=Ga;if(Zn.size>1){let Pi=nt;const Hs=[];for(;Pi=Pi.parentNode;){const ln=Zn.get(Pi);if(ln){mn=ln;break}Hs.push(Pi)}Hs.forEach(ln=>Zn.set(ln,mn))}const Nr=this._buildAnimation(ot.namespaceId,St,pn,s,hs,ci);if(ot.setRealPlayer(Nr),mn===Ga)fs.push(ot);else{const Pi=this.playersByElement.get(mn);Pi&&Pi.length&&(ot.parentPlayer=Ms(Pi)),r.push(ot)}}else uo(nt,St.fromStyles),ot.onDestroy(()=>kr(nt,St.toStyles)),Lr.push(ot),d.has(nt)&&r.push(ot)}),Lr.forEach(ze=>{const nt=s.get(ze.element);if(nt&&nt.length){const ot=Ms(nt);ze.setRealPlayer(ot)}}),r.forEach(ze=>{ze.parentPlayer?ze.syncPlayerEvents(ze.parentPlayer):ze.destroy()});for(let ze=0;ze!Nr.destroyed);mn.length?zH(this,nt,mn):this.processLeaveNode(nt)}return ae.length=0,fs.forEach(ze=>{this.players.push(ze),ze.onDone(()=>{ze.destroy();const nt=this.players.indexOf(ze);this.players.splice(nt,1)}),ze.play()}),fs}elementContainsData(t,e){let i=!1;const r=e[$i];return r&&r.setForRemoval&&(i=!0),this.playersByElement.has(e)&&(i=!0),this.playersByQueriedElement.has(e)&&(i=!0),this.statesByElement.has(e)&&(i=!0),this._fetchNamespace(t).elementContainsData(e)||i}afterFlush(t){this._flushFns.push(t)}afterFlushAnimationsDone(t){this._whenQuietFns.push(t)}_getPreviousPlayers(t,e,i,r,s){let o=[];if(e){const a=this.playersByQueriedElement.get(t);a&&(o=a)}else{const a=this.playersByElement.get(t);if(a){const l=!s||s==ql;a.forEach(c=>{c.queued||!l&&c.triggerName!=r||o.push(c)})}}return(i||r)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||r&&r!=a.triggerName))),o}_beforeAnimationBuild(t,e,i){const s=e.element,o=e.isRemovalTransition?void 0:t,a=e.isRemovalTransition?void 0:e.triggerName;for(const l of e.timelines){const c=l.element,d=c!==s,f=Ti(i,c,[]);this._getPreviousPlayers(c,d,o,a,e.toState).forEach(k=>{const j=k.getRealPlayer();j.beforeDestroy&&j.beforeDestroy(),k.destroy(),f.push(k)})}uo(s,e.fromStyles)}_buildAnimation(t,e,i,r,s,o){const a=e.triggerName,l=e.element,c=[],d=new Set,f=new Set,w=e.timelines.map(j=>{const K=j.element;d.add(K);const ae=K[$i];if(ae&&ae.removedBeforeQueried)return new $l(j.duration,j.delay);const ce=K!==l,Te=function $H(n){const t=[];return vM(n,t),t}((i.get(K)||LH).map(pn=>pn.getRealPlayer())).filter(pn=>!!pn.element&&pn.element===K),he=s.get(K),Oe=o.get(K),ft=$E(0,this._normalizer,0,j.keyframes,he,Oe),Nt=this._buildPlayer(j,ft,Te);if(j.subTimeline&&r&&f.add(K),ce){const pn=new Fg(t,a,K);pn.setRealPlayer(Nt),c.push(pn)}return Nt});c.forEach(j=>{Ti(this.playersByQueriedElement,j.element,[]).push(j),j.onDone(()=>function HH(n,t,e){let i=n.get(t);if(i){if(i.length){const r=i.indexOf(e);i.splice(r,1)}0==i.length&&n.delete(t)}return i}(this.playersByQueriedElement,j.element,j))}),d.forEach(j=>Gi(j,JE));const k=Ms(w);return k.onDestroy(()=>{d.forEach(j=>wa(j,JE)),kr(l,e.toStyles)}),f.forEach(j=>{Ti(r,j,[]).push(k)}),k}_buildPlayer(t,e,i){return e.length>0?this.driver.animate(t.element,e,t.duration,t.delay,t.easing,i):new $l(t.duration,t.delay)}}class Fg{constructor(t,e,i){this.namespaceId=t,this.triggerName=e,this.element=i,this._player=new $l,this._containsRealPlayer=!1,this._queuedCallbacks=new Map,this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(t){this._containsRealPlayer||(this._player=t,this._queuedCallbacks.forEach((e,i)=>{e.forEach(r=>pg(t,i,void 0,r))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(t.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(t){this.totalTime=t}syncPlayerEvents(t){const e=this._player;e.triggerCallback&&t.onStart(()=>e.triggerCallback("start")),t.onDone(()=>this.finish()),t.onDestroy(()=>this.destroy())}_queueEvent(t,e){Ti(this._queuedCallbacks,t,[]).push(e)}onDone(t){this.queued&&this._queueEvent("done",t),this._player.onDone(t)}onStart(t){this.queued&&this._queueEvent("start",t),this._player.onStart(t)}onDestroy(t){this.queued&&this._queueEvent("destroy",t),this._player.onDestroy(t)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(t){this.queued||this._player.setPosition(t)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(t){const e=this._player;e.triggerCallback&&e.triggerCallback(t)}}function Su(n){return n&&1===n.nodeType}function mM(n,t){const e=n.style.display;return n.style.display=null!=t?t:"none",e}function gM(n,t,e,i,r){const s=[];e.forEach(l=>s.push(mM(l)));const o=[];i.forEach((l,c)=>{const d=new Map;l.forEach(f=>{const w=t.computeStyle(c,f,r);d.set(f,w),(!w||0==w.length)&&(c[$i]=NH,o.push(c))}),n.set(c,d)});let a=0;return e.forEach(l=>mM(l,s[a++])),o}function _M(n,t){const e=new Map;if(n.forEach(a=>e.set(a,[])),0==t.length)return e;const r=new Set(t),s=new Map;function o(a){if(!a)return 1;let l=s.get(a);if(l)return l;const c=a.parentNode;return l=e.has(c)?c:r.has(c)?1:o(c),s.set(a,l),l}return t.forEach(a=>{const l=o(a);1!==l&&e.get(l).push(a)}),e}function Gi(n,t){var e;null===(e=n.classList)||void 0===e||e.add(t)}function wa(n,t){var e;null===(e=n.classList)||void 0===e||e.remove(t)}function zH(n,t,e){Ms(e).onDone(()=>n.processLeaveNode(t))}function vM(n,t){for(let e=0;er.add(s)):t.set(n,i),e.delete(n),!0}class ku{constructor(t,e,i){this.bodyNode=t,this._driver=e,this._normalizer=i,this._triggerCache={},this.onRemovalComplete=(r,s)=>{},this._transitionEngine=new VH(t,e,i),this._timelineEngine=new IH(t,e,i),this._transitionEngine.onRemovalComplete=(r,s)=>this.onRemovalComplete(r,s)}registerTrigger(t,e,i,r,s){const o=t+"-"+r;let a=this._triggerCache[o];if(!a){const l=[],d=Mg(this._driver,s,l,[]);if(l.length)throw function T2(n,t){return new Be(3404,Rt)}();a=function SH(n,t,e){return new kH(n,t,e)}(r,d,this._normalizer),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(e,r,a)}register(t,e){this._transitionEngine.register(t,e)}destroy(t,e){this._transitionEngine.destroy(t,e)}onInsert(t,e,i,r){this._transitionEngine.insertNode(t,e,i,r)}onRemove(t,e,i,r){this._transitionEngine.removeNode(t,e,r||!1,i)}disableAnimations(t,e){this._transitionEngine.markElementAsDisabled(t,e)}process(t,e,i,r){if("@"==i.charAt(0)){const[s,o]=GE(i);this._timelineEngine.command(s,e,o,r)}else this._transitionEngine.trigger(t,e,i,r)}listen(t,e,i,r,s){if("@"==i.charAt(0)){const[o,a]=GE(i);return this._timelineEngine.listen(o,e,a,s)}return this._transitionEngine.listen(t,e,i,r,s)}flush(t=-1){this._transitionEngine.flush(t)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}let qH=(()=>{class n{constructor(e,i,r){this._element=e,this._startStyles=i,this._endStyles=r,this._state=0;let s=n.initialStylesByElement.get(e);s||n.initialStylesByElement.set(e,s=new Map),this._initialStyles=s}start(){this._state<1&&(this._startStyles&&kr(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(kr(this._element,this._initialStyles),this._endStyles&&(kr(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(n.initialStylesByElement.delete(this._element),this._startStyles&&(uo(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(uo(this._element,this._endStyles),this._endStyles=null),kr(this._element,this._initialStyles),this._state=3)}}return n.initialStylesByElement=new WeakMap,n})();function Lg(n){let t=null;return n.forEach((e,i)=>{(function YH(n){return"display"===n||"position"===n})(i)&&(t=t||new Map,t.set(i,e))}),t}class bM{constructor(t,e,i,r){this.element=t,this.keyframes=e,this.options=i,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this.time=0,this.parentPlayer=null,this.currentSnapshot=new Map,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(t=>t()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const t=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,t,this.options),this._finalKeyframe=t.length?t[t.length-1]:new Map,this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(t){const e=[];return t.forEach(i=>{e.push(Object.fromEntries(i))}),e}_triggerWebAnimation(t,e,i){return t.animate(this._convertKeyframesToObject(e),i)}onStart(t){this._onStartFns.push(t)}onDone(t){this._onDoneFns.push(t)}onDestroy(t){this._onDestroyFns.push(t)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(t=>t()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(t=>t()),this._onDestroyFns=[])}setPosition(t){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=t*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const t=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,r)=>{"offset"!==r&&t.set(r,this._finished?i:sM(this.element,r))}),this.currentSnapshot=t}triggerCallback(t){const e="start"===t?this._onStartFns:this._onDoneFns;e.forEach(i=>i()),e.length=0}}class KH{validateStyleProperty(t){return!0}validateAnimatableStyleProperty(t){return!0}matchesElement(t,e){return!1}containsElement(t,e){return KE(t,e)}getParentElement(t){return vg(t)}query(t,e,i){return QE(t,e,i)}computeStyle(t,e,i){return window.getComputedStyle(t)[e]}animate(t,e,i,r,s,o=[]){const l={duration:i,delay:r,fill:0==r?"both":"forwards"};s&&(l.easing=s);const c=new Map,d=o.filter(k=>k instanceof bM);(function J2(n,t){return 0===n||0===t})(i,r)&&d.forEach(k=>{k.currentSnapshot.forEach((j,K)=>c.set(K,j))});let f=function K2(n){return n.length?n[0]instanceof Map?n:n.map(t=>eM(t)):[]}(e).map(k=>Ss(k));f=function eH(n,t,e){if(e.size&&t.length){let i=t[0],r=[];if(e.forEach((s,o)=>{i.has(o)||r.push(o),i.set(o,s)}),r.length)for(let s=1;so.set(a,sM(n,a)))}}return t}(t,f,c);const w=function WH(n,t){let e=null,i=null;return Array.isArray(t)&&t.length?(e=Lg(t[0]),t.length>1&&(i=Lg(t[t.length-1]))):t instanceof Map&&(e=Lg(t)),e||i?new qH(n,e,i):null}(t,f);return new bM(t,f,l,w)}}let QH=(()=>{class n extends BE{constructor(e,i){super(),this._nextAnimationId=0,this._renderer=e.createRenderer(i.body,{id:"0",encapsulation:Ji.None,styles:[],data:{animation:[]}})}build(e){const i=this._nextAnimationId.toString();this._nextAnimationId++;const r=Array.isArray(e)?HE(e):e;return wM(this._renderer,null,i,"register",[r]),new ZH(i,this._renderer)}}return n.\u0275fac=function(e){return new(e||n)(te(Tl),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class ZH extends class a2{}{constructor(t,e){super(),this._id=t,this._renderer=e}create(t,e){return new XH(this._id,t,e||{},this._renderer)}}class XH{constructor(t,e,i,r){this.id=t,this.element=e,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",i)}_listen(t,e){return this._renderer.listen(this.element,`@@${this.id}:${t}`,e)}_command(t,...e){return wM(this._renderer,this.element,this.id,t,e)}onDone(t){this._listen("done",t)}onStart(t){this._listen("start",t)}onDestroy(t){this._listen("destroy",t)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(t){this._command("setPosition",t)}getPosition(){var t,e;return null!==(e=null===(t=this._renderer.engine.players[+this.id])||void 0===t?void 0:t.getPosition())&&void 0!==e?e:0}}function wM(n,t,e,i,r){return n.setProperty(t,`@@${e}:${i}`,r)}const CM="@.disabled";let JH=(()=>{class n{constructor(e,i,r){this.delegate=e,this.engine=i,this._zone=r,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),i.onRemovalComplete=(s,o)=>{const a=null==o?void 0:o.parentNode(s);a&&o.removeChild(a,s)}}createRenderer(e,i){const s=this.delegate.createRenderer(e,i);if(!(e&&i&&i.data&&i.data.animation)){let d=this._rendererCache.get(s);return d||(d=new DM("",s,this.engine),this._rendererCache.set(s,d)),d}const o=i.id,a=i.id+"-"+this._currentId;this._currentId++,this.engine.register(a,e);const l=d=>{Array.isArray(d)?d.forEach(l):this.engine.registerTrigger(o,a,e,d.name,d)};return i.data.animation.forEach(l),new ej(this,a,s,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(e,i,r){e>=0&&ei(r)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(s=>{const[o,a]=s;o(a)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([i,r]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return n.\u0275fac=function(e){return new(e||n)(te(Tl),te(ku),te(et))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class DM{constructor(t,e,i){this.namespaceId=t,this.delegate=e,this.engine=i,this.destroyNode=this.delegate.destroyNode?r=>e.destroyNode(r):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy()}createElement(t,e){return this.delegate.createElement(t,e)}createComment(t){return this.delegate.createComment(t)}createText(t){return this.delegate.createText(t)}appendChild(t,e){this.delegate.appendChild(t,e),this.engine.onInsert(this.namespaceId,e,t,!1)}insertBefore(t,e,i,r=!0){this.delegate.insertBefore(t,e,i),this.engine.onInsert(this.namespaceId,e,t,r)}removeChild(t,e,i){this.engine.onRemove(this.namespaceId,e,this.delegate,i)}selectRootElement(t,e){return this.delegate.selectRootElement(t,e)}parentNode(t){return this.delegate.parentNode(t)}nextSibling(t){return this.delegate.nextSibling(t)}setAttribute(t,e,i,r){this.delegate.setAttribute(t,e,i,r)}removeAttribute(t,e,i){this.delegate.removeAttribute(t,e,i)}addClass(t,e){this.delegate.addClass(t,e)}removeClass(t,e){this.delegate.removeClass(t,e)}setStyle(t,e,i,r){this.delegate.setStyle(t,e,i,r)}removeStyle(t,e,i){this.delegate.removeStyle(t,e,i)}setProperty(t,e,i){"@"==e.charAt(0)&&e==CM?this.disableAnimations(t,!!i):this.delegate.setProperty(t,e,i)}setValue(t,e){this.delegate.setValue(t,e)}listen(t,e,i){return this.delegate.listen(t,e,i)}disableAnimations(t,e){this.engine.disableAnimations(t,e)}}class ej extends DM{constructor(t,e,i,r){super(e,i,r),this.factory=t,this.namespaceId=e}setProperty(t,e,i){"@"==e.charAt(0)?"."==e.charAt(1)&&e==CM?this.disableAnimations(t,i=void 0===i||!!i):this.engine.process(this.namespaceId,t,e.slice(1),i):this.delegate.setProperty(t,e,i)}listen(t,e,i){if("@"==e.charAt(0)){const r=function tj(n){switch(n){case"body":return document.body;case"document":return document;case"window":return window;default:return n}}(t);let s=e.slice(1),o="";return"@"!=s.charAt(0)&&([s,o]=function nj(n){const t=n.indexOf(".");return[n.substring(0,t),n.slice(t+1)]}(s)),this.engine.listen(this.namespaceId,r,s,o,a=>{this.factory.scheduleListenerCallback(a._data||-1,i,a)})}return this.delegate.listen(t,e,i)}}const EM=[{provide:BE,useClass:QH},{provide:Ag,useFactory:function rj(){return new DH}},{provide:ku,useClass:(()=>{class n extends ku{constructor(e,i,r){super(e.body,i,r)}ngOnDestroy(){this.flush()}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(yg),te(Ag))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})()},{provide:Tl,useFactory:function sj(n,t,e){return new JH(n,t,e)},deps:[cu,ku,et]}],MM=[{provide:yg,useFactory:()=>new KH},{provide:fn,useValue:"BrowserAnimations"},...EM],oj=[{provide:yg,useClass:ZE},{provide:fn,useValue:"NoopAnimations"},...EM];let aj=(()=>{class n{static withConfig(e){return{ngModule:n,providers:e.disableAnimations?oj:MM}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:MM,imports:[PE]}),n})();const{isArray:lj}=Array,{getPrototypeOf:cj,prototype:dj,keys:uj}=Object;function xM(n){if(1===n.length){const t=n[0];if(lj(t))return{args:t,keys:null};if(function hj(n){return n&&"object"==typeof n&&cj(n)===dj}(t)){const e=uj(t);return{args:e.map(i=>t[i]),keys:e}}}return{args:n,keys:null}}const{isArray:fj}=Array;function Ng(n){return U(t=>function pj(n,t){return fj(t)?n(...t):n(t)}(n,t))}function SM(n,t){return n.reduce((e,i,r)=>(e[i]=t[r],e),{})}function kM(...n){const t=oy(n),{args:e,keys:i}=xM(n),r=new J(s=>{const{length:o}=e;if(!o)return void s.complete();const a=new Array(o);let l=o,c=o;for(let d=0;d{f||(f=!0,c--),a[d]=w},()=>l--,void 0,()=>{(!l||!f)&&(c||s.next(i?SM(i,a):a),s.complete())}))}});return t?r.pipe(Ng(t)):r}let TM=(()=>{class n{constructor(e,i){this._renderer=e,this._elementRef=i,this.onChange=r=>{},this.onTouched=()=>{}}setProperty(e,i){this._renderer.setProperty(this._elementRef.nativeElement,e,i)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}}return n.\u0275fac=function(e){return new(e||n)(x(Xr),x(Je))},n.\u0275dir=Me({type:n}),n})(),fo=(()=>{class n extends TM{}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275dir=Me({type:n,features:[Le]}),n})();const ai=new De("NgValueAccessor"),gj={provide:ai,useExisting:Ft(()=>Bg),multi:!0},vj=new De("CompositionEventMode");let Bg=(()=>{class n extends TM{constructor(e,i,r){super(e,i),this._compositionMode=r,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function _j(){const n=Sr()?Sr().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}())}writeValue(e){this.setProperty("value",null==e?"":e)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}}return n.\u0275fac=function(e){return new(e||n)(x(Xr),x(Je),x(vj,8))},n.\u0275dir=Me({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(e,i){1&e&&$e("input",function(s){return i._handleInput(s.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(s){return i._compositionEnd(s.target.value)})},features:[Xe([gj]),Le]}),n})();function ks(n){return null==n||("string"==typeof n||Array.isArray(n))&&0===n.length}function IM(n){return null!=n&&"number"==typeof n.length}const Nn=new De("NgValidators"),Ts=new De("NgAsyncValidators"),yj=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class Vg{static min(t){return function RM(n){return t=>{if(ks(t.value)||ks(n))return null;const e=parseFloat(t.value);return!isNaN(e)&&e{if(ks(t.value)||ks(n))return null;const e=parseFloat(t.value);return!isNaN(e)&&e>n?{max:{max:n,actual:t.value}}:null}}(t)}static required(t){return function OM(n){return ks(n.value)?{required:!0}:null}(t)}static requiredTrue(t){return function FM(n){return!0===n.value?null:{required:!0}}(t)}static email(t){return function LM(n){return ks(n.value)||yj.test(n.value)?null:{email:!0}}(t)}static minLength(t){return function NM(n){return t=>ks(t.value)||!IM(t.value)?null:t.value.lengthIM(t.value)&&t.value.length>n?{maxlength:{requiredLength:n,actualLength:t.value.length}}:null}(t)}static pattern(t){return function VM(n){if(!n)return Au;let t,e;return"string"==typeof n?(e="","^"!==n.charAt(0)&&(e+="^"),e+=n,"$"!==n.charAt(n.length-1)&&(e+="$"),t=new RegExp(e)):(e=n.toString(),t=n),i=>{if(ks(i.value))return null;const r=i.value;return t.test(r)?null:{pattern:{requiredPattern:e,actualValue:r}}}}(t)}static nullValidator(t){return null}static compose(t){return GM(t)}static composeAsync(t){return WM(t)}}function Au(n){return null}function HM(n){return null!=n}function jM(n){const t=Cl(n)?gn(n):n;return em(t),t}function UM(n){let t={};return n.forEach(e=>{t=null!=e?Object.assign(Object.assign({},t),e):t}),0===Object.keys(t).length?null:t}function zM(n,t){return t.map(e=>e(n))}function $M(n){return n.map(t=>function bj(n){return!n.validate}(t)?t:e=>t.validate(e))}function GM(n){if(!n)return null;const t=n.filter(HM);return 0==t.length?null:function(e){return UM(zM(e,t))}}function Hg(n){return null!=n?GM($M(n)):null}function WM(n){if(!n)return null;const t=n.filter(HM);return 0==t.length?null:function(e){return kM(zM(e,t).map(jM)).pipe(U(UM))}}function jg(n){return null!=n?WM($M(n)):null}function qM(n,t){return null===n?[t]:Array.isArray(n)?[...n,t]:[n,t]}function YM(n){return n._rawValidators}function KM(n){return n._rawAsyncValidators}function Ug(n){return n?Array.isArray(n)?n:[n]:[]}function Iu(n,t){return Array.isArray(n)?n.includes(t):n===t}function QM(n,t){const e=Ug(t);return Ug(n).forEach(r=>{Iu(e,r)||e.push(r)}),e}function ZM(n,t){return Ug(t).filter(e=>!Iu(n,e))}class XM{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(t){this._rawValidators=t||[],this._composedValidatorFn=Hg(this._rawValidators)}_setAsyncValidators(t){this._rawAsyncValidators=t||[],this._composedAsyncValidatorFn=jg(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(t){this._onDestroyCallbacks.push(t)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(t=>t()),this._onDestroyCallbacks=[]}reset(t){this.control&&this.control.reset(t)}hasError(t,e){return!!this.control&&this.control.hasError(t,e)}getError(t,e){return this.control?this.control.getError(t,e):null}}class Tr extends XM{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class li extends XM{get formDirective(){return null}get path(){return null}}let ex=(()=>{class n extends class JM{constructor(t){this._cd=t}get isTouched(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.touched)}get isUntouched(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.untouched)}get isPristine(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.pristine)}get isDirty(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.dirty)}get isValid(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.valid)}get isInvalid(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.invalid)}get isPending(){var t,e;return!(null===(e=null===(t=this._cd)||void 0===t?void 0:t.control)||void 0===e||!e.pending)}get isSubmitted(){var t;return!(null===(t=this._cd)||void 0===t||!t.submitted)}}{constructor(e){super(e)}}return n.\u0275fac=function(e){return new(e||n)(x(Tr,2))},n.\u0275dir=Me({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(e,i){2&e&&At("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[Le]}),n})();const Yl="VALID",Pu="INVALID",Ca="PENDING",Kl="DISABLED";function Wg(n){return(Ou(n)?n.validators:n)||null}function nx(n){return Array.isArray(n)?Hg(n):n||null}function qg(n,t){return(Ou(t)?t.asyncValidators:n)||null}function ix(n){return Array.isArray(n)?jg(n):n||null}function Ou(n){return null!=n&&!Array.isArray(n)&&"object"==typeof n}class ox{constructor(t,e){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._rawValidators=t,this._rawAsyncValidators=e,this._composedValidatorFn=nx(this._rawValidators),this._composedAsyncValidatorFn=ix(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn}set validator(t){this._rawValidators=this._composedValidatorFn=t}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(t){this._rawAsyncValidators=this._composedAsyncValidatorFn=t}get parent(){return this._parent}get valid(){return this.status===Yl}get invalid(){return this.status===Pu}get pending(){return this.status==Ca}get disabled(){return this.status===Kl}get enabled(){return this.status!==Kl}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(t){this._rawValidators=t,this._composedValidatorFn=nx(t)}setAsyncValidators(t){this._rawAsyncValidators=t,this._composedAsyncValidatorFn=ix(t)}addValidators(t){this.setValidators(QM(t,this._rawValidators))}addAsyncValidators(t){this.setAsyncValidators(QM(t,this._rawAsyncValidators))}removeValidators(t){this.setValidators(ZM(t,this._rawValidators))}removeAsyncValidators(t){this.setAsyncValidators(ZM(t,this._rawAsyncValidators))}hasValidator(t){return Iu(this._rawValidators,t)}hasAsyncValidator(t){return Iu(this._rawAsyncValidators,t)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(t={}){this.touched=!0,this._parent&&!t.onlySelf&&this._parent.markAsTouched(t)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(t=>t.markAllAsTouched())}markAsUntouched(t={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(e=>{e.markAsUntouched({onlySelf:!0})}),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}markAsDirty(t={}){this.pristine=!1,this._parent&&!t.onlySelf&&this._parent.markAsDirty(t)}markAsPristine(t={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(e=>{e.markAsPristine({onlySelf:!0})}),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}markAsPending(t={}){this.status=Ca,!1!==t.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!t.onlySelf&&this._parent.markAsPending(t)}disable(t={}){const e=this._parentMarkedDirty(t.onlySelf);this.status=Kl,this.errors=null,this._forEachChild(i=>{i.disable(Object.assign(Object.assign({},t),{onlySelf:!0}))}),this._updateValue(),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach(i=>i(!0))}enable(t={}){const e=this._parentMarkedDirty(t.onlySelf);this.status=Yl,this._forEachChild(i=>{i.enable(Object.assign(Object.assign({},t),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent}),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(t){this._parent&&!t.onlySelf&&(this._parent.updateValueAndValidity(t),t.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(t){this._parent=t}getRawValue(){return this.value}updateValueAndValidity(t={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Yl||this.status===Ca)&&this._runAsyncValidator(t.emitEvent)),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!t.onlySelf&&this._parent.updateValueAndValidity(t)}_updateTreeValidity(t={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(t)),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Kl:Yl}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(t){if(this.asyncValidator){this.status=Ca,this._hasOwnPendingAsyncValidator=!0;const e=jM(this.asyncValidator(this));this._asyncValidationSubscription=e.subscribe(i=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(i,{emitEvent:t})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(t,e={}){this.errors=t,this._updateControlsErrors(!1!==e.emitEvent)}get(t){let e=t;return null==e||(Array.isArray(e)||(e=e.split(".")),0===e.length)?null:e.reduce((i,r)=>i&&i._find(r),this)}getError(t,e){const i=e?this.get(e):this;return i&&i.errors?i.errors[t]:null}hasError(t,e){return!!this.getError(t,e)}get root(){let t=this;for(;t._parent;)t=t._parent;return t}_updateControlsErrors(t){this.status=this._calculateStatus(),t&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(t)}_initObservables(){this.valueChanges=new je,this.statusChanges=new je}_calculateStatus(){return this._allControlsDisabled()?Kl:this.errors?Pu:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Ca)?Ca:this._anyControlsHaveStatus(Pu)?Pu:Yl}_anyControlsHaveStatus(t){return this._anyControls(e=>e.status===t)}_anyControlsDirty(){return this._anyControls(t=>t.dirty)}_anyControlsTouched(){return this._anyControls(t=>t.touched)}_updatePristine(t={}){this.pristine=!this._anyControlsDirty(),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}_updateTouched(t={}){this.touched=this._anyControlsTouched(),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}_registerOnCollectionChange(t){this._onCollectionChange=t}_setUpdateStrategy(t){Ou(t)&&null!=t.updateOn&&(this._updateOn=t.updateOn)}_parentMarkedDirty(t){return!t&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(t){return null}}class Yg extends ox{constructor(t,e,i){super(Wg(e),qg(i,e)),this.controls=t,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(t,e){return this.controls[t]?this.controls[t]:(this.controls[t]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(t,e,i={}){this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(t,e={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(t,e,i={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],e&&this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(t){return this.controls.hasOwnProperty(t)&&this.controls[t].enabled}setValue(t,e={}){(function sx(n,t,e){n._forEachChild((i,r)=>{if(void 0===e[r])throw new Be(1002,"")})})(this,0,t),Object.keys(t).forEach(i=>{(function rx(n,t,e){const i=n.controls;if(!(t?Object.keys(i):i).length)throw new Be(1e3,"");if(!i[e])throw new Be(1001,"")})(this,!0,i),this.controls[i].setValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(t,e={}){null!=t&&(Object.keys(t).forEach(i=>{const r=this.controls[i];r&&r.patchValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(t={},e={}){this._forEachChild((i,r)=>{i.reset(t[r],{onlySelf:!0,emitEvent:e.emitEvent})}),this._updatePristine(e),this._updateTouched(e),this.updateValueAndValidity(e)}getRawValue(){return this._reduceChildren({},(t,e,i)=>(t[i]=e.getRawValue(),t))}_syncPendingControls(){let t=this._reduceChildren(!1,(e,i)=>!!i._syncPendingControls()||e);return t&&this.updateValueAndValidity({onlySelf:!0}),t}_forEachChild(t){Object.keys(this.controls).forEach(e=>{const i=this.controls[e];i&&t(i,e)})}_setUpControls(){this._forEachChild(t=>{t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(t){for(const[e,i]of Object.entries(this.controls))if(this.contains(e)&&t(i))return!0;return!1}_reduceValue(){return this._reduceChildren({},(e,i,r)=>((i.enabled||this.disabled)&&(e[r]=i.value),e))}_reduceChildren(t,e){let i=t;return this._forEachChild((r,s)=>{i=e(i,r,s)}),i}_allControlsDisabled(){for(const t of Object.keys(this.controls))if(this.controls[t].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(t){return this.controls.hasOwnProperty(t)?this.controls[t]:null}}function Ql(n,t){var e,i;Kg(n,t),t.valueAccessor.writeValue(n.value),n.disabled&&(null===(i=(e=t.valueAccessor).setDisabledState)||void 0===i||i.call(e,!0)),function Aj(n,t){t.valueAccessor.registerOnChange(e=>{n._pendingValue=e,n._pendingChange=!0,n._pendingDirty=!0,"change"===n.updateOn&&ax(n,t)})}(n,t),function Rj(n,t){const e=(i,r)=>{t.valueAccessor.writeValue(i),r&&t.viewToModelUpdate(i)};n.registerOnChange(e),t._registerOnDestroy(()=>{n._unregisterOnChange(e)})}(n,t),function Ij(n,t){t.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,"blur"===n.updateOn&&n._pendingChange&&ax(n,t),"submit"!==n.updateOn&&n.markAsTouched()})}(n,t),function Tj(n,t){if(t.valueAccessor.setDisabledState){const e=i=>{t.valueAccessor.setDisabledState(i)};n.registerOnDisabledChange(e),t._registerOnDestroy(()=>{n._unregisterOnDisabledChange(e)})}}(n,t)}function Lu(n,t,e=!0){const i=()=>{};t.valueAccessor&&(t.valueAccessor.registerOnChange(i),t.valueAccessor.registerOnTouched(i)),Bu(n,t),n&&(t._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function Nu(n,t){n.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(t)})}function Kg(n,t){const e=YM(n);null!==t.validator?n.setValidators(qM(e,t.validator)):"function"==typeof e&&n.setValidators([e]);const i=KM(n);null!==t.asyncValidator?n.setAsyncValidators(qM(i,t.asyncValidator)):"function"==typeof i&&n.setAsyncValidators([i]);const r=()=>n.updateValueAndValidity();Nu(t._rawValidators,r),Nu(t._rawAsyncValidators,r)}function Bu(n,t){let e=!1;if(null!==n){if(null!==t.validator){const r=YM(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==t.validator);s.length!==r.length&&(e=!0,n.setValidators(s))}}if(null!==t.asyncValidator){const r=KM(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==t.asyncValidator);s.length!==r.length&&(e=!0,n.setAsyncValidators(s))}}}const i=()=>{};return Nu(t._rawValidators,i),Nu(t._rawAsyncValidators,i),e}function ax(n,t){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),t.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function lx(n,t){Kg(n,t)}function dx(n,t){n._syncPendingControls(),t.forEach(e=>{const i=e.control;"submit"===i.updateOn&&i._pendingChange&&(e.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}const Nj={provide:li,useExisting:Ft(()=>Xl)},Zl=(()=>Promise.resolve(null))();let Xl=(()=>{class n extends li{constructor(e,i){super(),this.submitted=!1,this._directives=new Set,this.ngSubmit=new je,this.form=new Yg({},Hg(e),jg(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(e){Zl.then(()=>{const i=this._findContainer(e.path);e.control=i.registerControl(e.name,e.control),Ql(e.control,e),e.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(e)})}getControl(e){return this.form.get(e.path)}removeControl(e){Zl.then(()=>{const i=this._findContainer(e.path);i&&i.removeControl(e.name),this._directives.delete(e)})}addFormGroup(e){Zl.then(()=>{const i=this._findContainer(e.path),r=new Yg({});lx(r,e),i.registerControl(e.name,r),r.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(e){Zl.then(()=>{const i=this._findContainer(e.path);i&&i.removeControl(e.name)})}getFormGroup(e){return this.form.get(e.path)}updateModel(e,i){Zl.then(()=>{this.form.get(e.path).setValue(i)})}setValue(e){this.control.setValue(e)}onSubmit(e){return this.submitted=!0,dx(this.form,this._directives),this.ngSubmit.emit(e),!1}onReset(){this.resetForm()}resetForm(e){this.form.reset(e),this.submitted=!1}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(e){return e.pop(),e.length?this.form.get(e):this.form}}return n.\u0275fac=function(e){return new(e||n)(x(Nn,10),x(Ts,10))},n.\u0275dir=Me({type:n,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(e,i){1&e&&$e("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Xe([Nj]),Le]}),n})();function ux(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}function hx(n){return"object"==typeof n&&null!==n&&2===Object.keys(n).length&&"value"in n&&"disabled"in n}const fx=class extends ox{constructor(t=null,e,i){super(Wg(e),qg(i,e)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(t),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Ou(e)&&(e.nonNullable||e.initialValueIsDefault)&&(this.defaultValue=hx(t)?t.value:t)}setValue(t,e={}){this.value=this._pendingValue=t,this._onChange.length&&!1!==e.emitModelToViewChange&&this._onChange.forEach(i=>i(this.value,!1!==e.emitViewToModelChange)),this.updateValueAndValidity(e)}patchValue(t,e={}){this.setValue(t,e)}reset(t=this.defaultValue,e={}){this._applyFormState(t),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),this._pendingChange=!1}_updateValue(){}_anyControls(t){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(t){this._onChange.push(t)}_unregisterOnChange(t){ux(this._onChange,t)}registerOnDisabledChange(t){this._onDisabledChange.push(t)}_unregisterOnDisabledChange(t){ux(this._onDisabledChange,t)}_forEachChild(t){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(t){hx(t)?(this.value=this._pendingValue=t.value,t.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=t}},Hj={provide:Tr,useExisting:Ft(()=>Xg)},gx=(()=>Promise.resolve(null))();let Xg=(()=>{class n extends Tr{constructor(e,i,r,s,o){super(),this._changeDetectorRef=o,this.control=new fx,this._registered=!1,this.update=new je,this._parent=e,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=function Zg(n,t){if(!t)return null;let e,i,r;return Array.isArray(t),t.forEach(s=>{s.constructor===Bg?e=s:function Fj(n){return Object.getPrototypeOf(n.constructor)===fo}(s)?i=s:r=s}),r||i||e||null}(0,s)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){const i=e.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),function Qg(n,t){if(!n.hasOwnProperty("model"))return!1;const e=n.model;return!!e.isFirstChange()||!Object.is(t,e.currentValue)}(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Ql(this.control,this),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(e){gx.then(()=>{var i;this.control.setValue(e,{emitViewToModelChange:!1}),null===(i=this._changeDetectorRef)||void 0===i||i.markForCheck()})}_updateDisabled(e){const i=e.isDisabled.currentValue,r=0!==i&&ts(i);gx.then(()=>{var s;r&&!this.control.disabled?this.control.disable():!r&&this.control.disabled&&this.control.enable(),null===(s=this._changeDetectorRef)||void 0===s||s.markForCheck()})}_getPath(e){return this._parent?function Fu(n,t){return[...t.path,n]}(e,this._parent):[e]}}return n.\u0275fac=function(e){return new(e||n)(x(li,9),x(Nn,10),x(Ts,10),x(ai,10),x(en,8))},n.\u0275dir=Me({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Xe([Hj]),Le,cn]}),n})(),vx=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const Jg=new De("NgModelWithFormControlWarning"),qj={provide:li,useExisting:Ft(()=>Jl)};let Jl=(()=>{class n extends li{constructor(e,i){super(),this.validators=e,this.asyncValidators=i,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new je,this._setValidators(e),this._setAsyncValidators(i)}ngOnChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Bu(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(e){const i=this.form.get(e.path);return Ql(i,e),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),i}getControl(e){return this.form.get(e.path)}removeControl(e){Lu(e.control||null,e,!1),function Lj(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}getFormArray(e){return this.form.get(e.path)}updateModel(e,i){this.form.get(e.path).setValue(i)}onSubmit(e){return this.submitted=!0,dx(this.form,this.directives),this.ngSubmit.emit(e),!1}onReset(){this.resetForm()}resetForm(e){this.form.reset(e),this.submitted=!1}_updateDomValue(){this.directives.forEach(e=>{const i=e.control,r=this.form.get(e.path);i!==r&&(Lu(i||null,e),(n=>n instanceof fx)(r)&&(Ql(r,e),e.control=r))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){const i=this.form.get(e.path);lx(i,e),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){if(this.form){const i=this.form.get(e.path);i&&function Pj(n,t){return Bu(n,t)}(i,e)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){Kg(this.form,this),this._oldForm&&Bu(this._oldForm,this)}_checkFormPresent(){}}return n.\u0275fac=function(e){return new(e||n)(x(Nn,10),x(Ts,10))},n.\u0275dir=Me({type:n,selectors:[["","formGroup",""]],hostBindings:function(e,i){1&e&&$e("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Xe([qj]),Le,cn]}),n})(),Fx=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[vx]}),n})(),h3=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Fx]}),n})(),f3=(()=>{class n{static withConfig(e){return{ngModule:n,providers:[{provide:Jg,useValue:e.warnOnNgModelWithFormControl}]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Fx]}),n})();function tt(...n){return gn(n,qa(n))}function Da(n,t){return ut(t)?Pn(n,t,1):Pn(n,1)}function yn(n,t){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>n.call(t,s,r++)&&i.next(s)))})}class Lx{}class Nx{}class Wi{constructor(t){this.normalizedNames=new Map,this.lazyUpdate=null,t?this.lazyInit="string"==typeof t?()=>{this.headers=new Map,t.split("\n").forEach(e=>{const i=e.indexOf(":");if(i>0){const r=e.slice(0,i),s=r.toLowerCase(),o=e.slice(i+1).trim();this.maybeSetNormalizedName(r,s),this.headers.has(s)?this.headers.get(s).push(o):this.headers.set(s,[o])}})}:()=>{this.headers=new Map,Object.keys(t).forEach(e=>{let i=t[e];const r=e.toLowerCase();"string"==typeof i&&(i=[i]),i.length>0&&(this.headers.set(r,i),this.maybeSetNormalizedName(e,r))})}:this.headers=new Map}has(t){return this.init(),this.headers.has(t.toLowerCase())}get(t){this.init();const e=this.headers.get(t.toLowerCase());return e&&e.length>0?e[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(t){return this.init(),this.headers.get(t.toLowerCase())||null}append(t,e){return this.clone({name:t,value:e,op:"a"})}set(t,e){return this.clone({name:t,value:e,op:"s"})}delete(t,e){return this.clone({name:t,value:e,op:"d"})}maybeSetNormalizedName(t,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,t)}init(){this.lazyInit&&(this.lazyInit instanceof Wi?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(t=>this.applyUpdate(t)),this.lazyUpdate=null))}copyFrom(t){t.init(),Array.from(t.headers.keys()).forEach(e=>{this.headers.set(e,t.headers.get(e)),this.normalizedNames.set(e,t.normalizedNames.get(e))})}clone(t){const e=new Wi;return e.lazyInit=this.lazyInit&&this.lazyInit instanceof Wi?this.lazyInit:this,e.lazyUpdate=(this.lazyUpdate||[]).concat([t]),e}applyUpdate(t){const e=t.name.toLowerCase();switch(t.op){case"a":case"s":let i=t.value;if("string"==typeof i&&(i=[i]),0===i.length)return;this.maybeSetNormalizedName(t.name,e);const r=("a"===t.op?this.headers.get(e):void 0)||[];r.push(...i),this.headers.set(e,r);break;case"d":const s=t.value;if(s){let o=this.headers.get(e);if(!o)return;o=o.filter(a=>-1===s.indexOf(a)),0===o.length?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,o)}else this.headers.delete(e),this.normalizedNames.delete(e)}}forEach(t){this.init(),Array.from(this.normalizedNames.keys()).forEach(e=>t(this.normalizedNames.get(e),this.headers.get(e)))}}class g3{encodeKey(t){return Bx(t)}encodeValue(t){return Bx(t)}decodeKey(t){return decodeURIComponent(t)}decodeValue(t){return decodeURIComponent(t)}}const v3=/%(\d[a-f0-9])/gi,y3={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Bx(n){return encodeURIComponent(n).replace(v3,(t,e)=>{var i;return null!==(i=y3[e])&&void 0!==i?i:t})}function Vu(n){return`${n}`}class As{constructor(t={}){if(this.updates=null,this.cloneFrom=null,this.encoder=t.encoder||new g3,t.fromString){if(t.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function _3(n,t){const e=new Map;return n.length>0&&n.replace(/^\?/,"").split("&").forEach(r=>{const s=r.indexOf("="),[o,a]=-1==s?[t.decodeKey(r),""]:[t.decodeKey(r.slice(0,s)),t.decodeValue(r.slice(s+1))],l=e.get(o)||[];l.push(a),e.set(o,l)}),e}(t.fromString,this.encoder)}else t.fromObject?(this.map=new Map,Object.keys(t.fromObject).forEach(e=>{const i=t.fromObject[e],r=Array.isArray(i)?i.map(Vu):[Vu(i)];this.map.set(e,r)})):this.map=null}has(t){return this.init(),this.map.has(t)}get(t){this.init();const e=this.map.get(t);return e?e[0]:null}getAll(t){return this.init(),this.map.get(t)||null}keys(){return this.init(),Array.from(this.map.keys())}append(t,e){return this.clone({param:t,value:e,op:"a"})}appendAll(t){const e=[];return Object.keys(t).forEach(i=>{const r=t[i];Array.isArray(r)?r.forEach(s=>{e.push({param:i,value:s,op:"a"})}):e.push({param:i,value:r,op:"a"})}),this.clone(e)}set(t,e){return this.clone({param:t,value:e,op:"s"})}delete(t,e){return this.clone({param:t,value:e,op:"d"})}toString(){return this.init(),this.keys().map(t=>{const e=this.encoder.encodeKey(t);return this.map.get(t).map(i=>e+"="+this.encoder.encodeValue(i)).join("&")}).filter(t=>""!==t).join("&")}clone(t){const e=new As({encoder:this.encoder});return e.cloneFrom=this.cloneFrom||this,e.updates=(this.updates||[]).concat(t),e}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(t=>this.map.set(t,this.cloneFrom.map.get(t))),this.updates.forEach(t=>{switch(t.op){case"a":case"s":const e=("a"===t.op?this.map.get(t.param):void 0)||[];e.push(Vu(t.value)),this.map.set(t.param,e);break;case"d":if(void 0===t.value){this.map.delete(t.param);break}{let i=this.map.get(t.param)||[];const r=i.indexOf(Vu(t.value));-1!==r&&i.splice(r,1),i.length>0?this.map.set(t.param,i):this.map.delete(t.param)}}}),this.cloneFrom=this.updates=null)}}class b3{constructor(){this.map=new Map}set(t,e){return this.map.set(t,e),this}get(t){return this.map.has(t)||this.map.set(t,t.defaultValue()),this.map.get(t)}delete(t){return this.map.delete(t),this}has(t){return this.map.has(t)}keys(){return this.map.keys()}}function Vx(n){return"undefined"!=typeof ArrayBuffer&&n instanceof ArrayBuffer}function Hx(n){return"undefined"!=typeof Blob&&n instanceof Blob}function jx(n){return"undefined"!=typeof FormData&&n instanceof FormData}class ec{constructor(t,e,i,r){let s;if(this.url=e,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=t.toUpperCase(),function w3(n){switch(n){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||r?(this.body=void 0!==i?i:null,s=r):s=i,s&&(this.reportProgress=!!s.reportProgress,this.withCredentials=!!s.withCredentials,s.responseType&&(this.responseType=s.responseType),s.headers&&(this.headers=s.headers),s.context&&(this.context=s.context),s.params&&(this.params=s.params)),this.headers||(this.headers=new Wi),this.context||(this.context=new b3),this.params){const o=this.params.toString();if(0===o.length)this.urlWithParams=e;else{const a=e.indexOf("?");this.urlWithParams=e+(-1===a?"?":aw.set(k,t.setHeaders[k]),c)),t.setParams&&(d=Object.keys(t.setParams).reduce((w,k)=>w.set(k,t.setParams[k]),d)),new ec(i,r,o,{params:d,headers:c,context:f,reportProgress:l,responseType:s,withCredentials:a})}}var Mn=(()=>((Mn=Mn||{})[Mn.Sent=0]="Sent",Mn[Mn.UploadProgress=1]="UploadProgress",Mn[Mn.ResponseHeader=2]="ResponseHeader",Mn[Mn.DownloadProgress=3]="DownloadProgress",Mn[Mn.Response=4]="Response",Mn[Mn.User=5]="User",Mn))();class o_{constructor(t,e=200,i="OK"){this.headers=t.headers||new Wi,this.status=void 0!==t.status?t.status:e,this.statusText=t.statusText||i,this.url=t.url||null,this.ok=this.status>=200&&this.status<300}}class a_ extends o_{constructor(t={}){super(t),this.type=Mn.ResponseHeader}clone(t={}){return new a_({headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class tc extends o_{constructor(t={}){super(t),this.type=Mn.Response,this.body=void 0!==t.body?t.body:null}clone(t={}){return new tc({body:void 0!==t.body?t.body:this.body,headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class l_ extends o_{constructor(t){super(t,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${t.url||"(unknown url)"}`:`Http failure response for ${t.url||"(unknown url)"}: ${t.status} ${t.statusText}`,this.error=t.error||null}}function c_(n,t){return{body:t,headers:n.headers,context:n.context,observe:n.observe,params:n.params,reportProgress:n.reportProgress,responseType:n.responseType,withCredentials:n.withCredentials}}let nc=(()=>{class n{constructor(e){this.handler=e}request(e,i,r={}){let s;if(e instanceof ec)s=e;else{let l,c;l=r.headers instanceof Wi?r.headers:new Wi(r.headers),r.params&&(c=r.params instanceof As?r.params:new As({fromObject:r.params})),s=new ec(e,i,void 0!==r.body?r.body:null,{headers:l,context:r.context,params:c,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials})}const o=tt(s).pipe(Da(l=>this.handler.handle(l)));if(e instanceof ec||"events"===r.observe)return o;const a=o.pipe(yn(l=>l instanceof tc));switch(r.observe||"body"){case"body":switch(s.responseType){case"arraybuffer":return a.pipe(U(l=>{if(null!==l.body&&!(l.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return l.body}));case"blob":return a.pipe(U(l=>{if(null!==l.body&&!(l.body instanceof Blob))throw new Error("Response is not a Blob.");return l.body}));case"text":return a.pipe(U(l=>{if(null!==l.body&&"string"!=typeof l.body)throw new Error("Response is not a string.");return l.body}));default:return a.pipe(U(l=>l.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${r.observe}}`)}}delete(e,i={}){return this.request("DELETE",e,i)}get(e,i={}){return this.request("GET",e,i)}head(e,i={}){return this.request("HEAD",e,i)}jsonp(e,i){return this.request("JSONP",e,{params:(new As).append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(e,i={}){return this.request("OPTIONS",e,i)}patch(e,i,r={}){return this.request("PATCH",e,c_(r,i))}post(e,i,r={}){return this.request("POST",e,c_(r,i))}put(e,i,r={}){return this.request("PUT",e,c_(r,i))}}return n.\u0275fac=function(e){return new(e||n)(te(Lx))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class Ux{constructor(t,e){this.next=t,this.interceptor=e}handle(t){return this.interceptor.intercept(t,this.next)}}const d_=new De("HTTP_INTERCEPTORS");let D3=(()=>{class n{intercept(e,i){return i.handle(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const E3=/^\)\]\}',?\n/;let zx=(()=>{class n{constructor(e){this.xhrFactory=e}handle(e){if("JSONP"===e.method)throw new Error("Attempted to construct Jsonp request without HttpClientJsonpModule installed.");return new J(i=>{const r=this.xhrFactory.build();if(r.open(e.method,e.urlWithParams),e.withCredentials&&(r.withCredentials=!0),e.headers.forEach((k,j)=>r.setRequestHeader(k,j.join(","))),e.headers.has("Accept")||r.setRequestHeader("Accept","application/json, text/plain, */*"),!e.headers.has("Content-Type")){const k=e.detectContentTypeHeader();null!==k&&r.setRequestHeader("Content-Type",k)}if(e.responseType){const k=e.responseType.toLowerCase();r.responseType="json"!==k?k:"text"}const s=e.serializeBody();let o=null;const a=()=>{if(null!==o)return o;const k=r.statusText||"OK",j=new Wi(r.getAllResponseHeaders()),K=function M3(n){return"responseURL"in n&&n.responseURL?n.responseURL:/^X-Request-URL:/m.test(n.getAllResponseHeaders())?n.getResponseHeader("X-Request-URL"):null}(r)||e.url;return o=new a_({headers:j,status:r.status,statusText:k,url:K}),o},l=()=>{let{headers:k,status:j,statusText:K,url:ae}=a(),ce=null;204!==j&&(ce=void 0===r.response?r.responseText:r.response),0===j&&(j=ce?200:0);let Te=j>=200&&j<300;if("json"===e.responseType&&"string"==typeof ce){const he=ce;ce=ce.replace(E3,"");try{ce=""!==ce?JSON.parse(ce):null}catch(Oe){ce=he,Te&&(Te=!1,ce={error:Oe,text:ce})}}Te?(i.next(new tc({body:ce,headers:k,status:j,statusText:K,url:ae||void 0})),i.complete()):i.error(new l_({error:ce,headers:k,status:j,statusText:K,url:ae||void 0}))},c=k=>{const{url:j}=a(),K=new l_({error:k,status:r.status||0,statusText:r.statusText||"Unknown Error",url:j||void 0});i.error(K)};let d=!1;const f=k=>{d||(i.next(a()),d=!0);let j={type:Mn.DownloadProgress,loaded:k.loaded};k.lengthComputable&&(j.total=k.total),"text"===e.responseType&&!!r.responseText&&(j.partialText=r.responseText),i.next(j)},w=k=>{let j={type:Mn.UploadProgress,loaded:k.loaded};k.lengthComputable&&(j.total=k.total),i.next(j)};return r.addEventListener("load",l),r.addEventListener("error",c),r.addEventListener("timeout",c),r.addEventListener("abort",c),e.reportProgress&&(r.addEventListener("progress",f),null!==s&&r.upload&&r.upload.addEventListener("progress",w)),r.send(s),i.next({type:Mn.Sent}),()=>{r.removeEventListener("error",c),r.removeEventListener("abort",c),r.removeEventListener("load",l),r.removeEventListener("timeout",c),e.reportProgress&&(r.removeEventListener("progress",f),null!==s&&r.upload&&r.upload.removeEventListener("progress",w)),r.readyState!==r.DONE&&r.abort()}})}}return n.\u0275fac=function(e){return new(e||n)(te(_E))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const u_=new De("XSRF_COOKIE_NAME"),h_=new De("XSRF_HEADER_NAME");class $x{}let p_,x3=(()=>{class n{constructor(e,i,r){this.doc=e,this.platform=i,this.cookieName=r,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const e=this.doc.cookie||"";return e!==this.lastCookieString&&(this.parseCount++,this.lastToken=sE(e,this.cookieName),this.lastCookieString=e),this.lastToken}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(Ud),te(u_))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),f_=(()=>{class n{constructor(e,i){this.tokenService=e,this.headerName=i}intercept(e,i){const r=e.url.toLowerCase();if("GET"===e.method||"HEAD"===e.method||r.startsWith("http://")||r.startsWith("https://"))return i.handle(e);const s=this.tokenService.getToken();return null!==s&&!e.headers.has(this.headerName)&&(e=e.clone({headers:e.headers.set(this.headerName,s)})),i.handle(e)}}return n.\u0275fac=function(e){return new(e||n)(te($x),te(h_))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),S3=(()=>{class n{constructor(e,i){this.backend=e,this.injector=i,this.chain=null}handle(e){if(null===this.chain){const i=this.injector.get(d_,[]);this.chain=i.reduceRight((r,s)=>new Ux(r,s),this.backend)}return this.chain.handle(e)}}return n.\u0275fac=function(e){return new(e||n)(te(Nx),te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),k3=(()=>{class n{static disable(){return{ngModule:n,providers:[{provide:f_,useClass:D3}]}}static withOptions(e={}){return{ngModule:n,providers:[e.cookieName?{provide:u_,useValue:e.cookieName}:[],e.headerName?{provide:h_,useValue:e.headerName}:[]]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[f_,{provide:d_,useExisting:f_,multi:!0},{provide:$x,useClass:x3},{provide:u_,useValue:"XSRF-TOKEN"},{provide:h_,useValue:"X-XSRF-TOKEN"}]}),n})(),T3=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[nc,{provide:Lx,useClass:S3},zx,{provide:Nx,useExisting:zx}],imports:[k3.withOptions({cookieName:"XSRF-TOKEN",headerName:"X-XSRF-TOKEN"})]}),n})();try{p_="undefined"!=typeof Intl&&Intl.v8BreakIterator}catch(n){p_=!1}let ic,mo,m_,bn=(()=>{class n{constructor(e){this._platformId=e,this.isBrowser=this._platformId?function CV(n){return n===mE}(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!p_)&&"undefined"!=typeof CSS&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT}}return n.\u0275fac=function(e){return new(e||n)(te(Ud))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Ar(n){return function A3(){if(null==ic&&"undefined"!=typeof window)try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>ic=!0}))}finally{ic=ic||!1}return ic}()?n:!!n.capture}function I3(){if(null==mo){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return mo=!1,mo;if("scrollBehavior"in document.documentElement.style)mo=!0;else{const n=Element.prototype.scrollTo;mo=!!n&&!/\{\s*\[native code\]\s*\}/.test(n.toString())}}return mo}function ju(n){if(function R3(){if(null==m_){const n="undefined"!=typeof document?document.head:null;m_=!(!n||!n.createShadowRoot&&!n.attachShadow)}return m_}()){const t=n.getRootNode?n.getRootNode():null;if("undefined"!=typeof ShadowRoot&&ShadowRoot&&t instanceof ShadowRoot)return t}return null}function g_(){let n="undefined"!=typeof document&&document?document.activeElement:null;for(;n&&n.shadowRoot;){const t=n.shadowRoot.activeElement;if(t===n)break;n=t}return n}function ur(n){return n.composedPath?n.composedPath()[0]:n.target}function __(){return"undefined"!=typeof __karma__&&!!__karma__||"undefined"!=typeof jasmine&&!!jasmine||"undefined"!=typeof jest&&!!jest||"undefined"!=typeof Mocha&&!!Mocha}function rt(n){return null!=n&&"false"!=`${n}`}function Ii(n,t=0){return function P3(n){return!isNaN(parseFloat(n))&&!isNaN(Number(n))}(n)?Number(n):t}function Uu(n){return Array.isArray(n)?n:[n]}function xn(n){return null==n?"":"string"==typeof n?n:`${n}px`}function Rn(n){return n instanceof Je?n.nativeElement:n}class mi extends ue{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}function gi(n,...t){return t.length?t.some(e=>n[e]):n.altKey||n.shiftKey||n.ctrlKey||n.metaKey}function wn(n,t,e){const i=ut(n)||t||e?{next:n,error:t,complete:e}:n;return i?Pe((r,s)=>{var o;null===(o=i.subscribe)||void 0===o||o.call(i);let a=!0;r.subscribe(_e(s,l=>{var c;null===(c=i.next)||void 0===c||c.call(i,l),s.next(l)},()=>{var l;a=!1,null===(l=i.complete)||void 0===l||l.call(i),s.complete()},l=>{var c;a=!1,null===(c=i.error)||void 0===c||c.call(i,l),s.error(l)},()=>{var l,c;a&&(null===(l=i.unsubscribe)||void 0===l||l.call(i)),null===(c=i.finalize)||void 0===c||c.call(i)}))}):N}class G3 extends X{constructor(t,e){super()}schedule(t,e=0){return this}}const zu={setInterval(n,t,...e){const{delegate:i}=zu;return null!=i&&i.setInterval?i.setInterval(n,t,...e):setInterval(n,t,...e)},clearInterval(n){const{delegate:t}=zu;return((null==t?void 0:t.clearInterval)||clearInterval)(n)},delegate:void 0};class D_ extends G3{constructor(t,e){super(t,e),this.scheduler=t,this.work=e,this.pending=!1}schedule(t,e=0){if(this.closed)return this;this.state=t;const i=this.id,r=this.scheduler;return null!=i&&(this.id=this.recycleAsyncId(r,i,e)),this.pending=!0,this.delay=e,this.id=this.id||this.requestAsyncId(r,this.id,e),this}requestAsyncId(t,e,i=0){return zu.setInterval(t.flush.bind(t,this),i)}recycleAsyncId(t,e,i=0){if(null!=i&&this.delay===i&&!1===this.pending)return e;zu.clearInterval(e)}execute(t,e){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const i=this._execute(t,e);if(i)return i;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(t,e){let r,i=!1;try{this.work(t)}catch(s){i=!0,r=s||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),r}unsubscribe(){if(!this.closed){const{id:t,scheduler:e}=this,{actions:i}=e;this.work=this.state=this.scheduler=null,this.pending=!1,V(i,this),null!=t&&(this.id=this.recycleAsyncId(e,t,null)),this.delay=null,super.unsubscribe()}}}const E_={now:()=>(E_.delegate||Date).now(),delegate:void 0};class sc{constructor(t,e=sc.now){this.schedulerActionCtor=t,this.now=e}schedule(t,e=0,i){return new this.schedulerActionCtor(this,t).schedule(i,e)}}sc.now=E_.now;class M_ extends sc{constructor(t,e=sc.now){super(t,e),this.actions=[],this._active=!1,this._scheduled=void 0}flush(t){const{actions:e}=this;if(this._active)return void e.push(t);let i;this._active=!0;do{if(i=t.execute(t.state,t.delay))break}while(t=e.shift());if(this._active=!1,i){for(;t=e.shift();)t.unsubscribe();throw i}}}const $u=new M_(D_),W3=$u;function x_(n,t=$u){return Pe((e,i)=>{let r=null,s=null,o=null;const a=()=>{if(r){r.unsubscribe(),r=null;const c=s;s=null,i.next(c)}};function l(){const c=o+n,d=t.now();if(d{s=c,o=t.now(),r||(r=t.schedule(l,n),i.add(r))},()=>{a(),i.complete()},void 0,()=>{s=r=null}))})}function S_(n){return yn((t,e)=>n<=e)}function k_(n,t=N){return n=null!=n?n:q3,Pe((e,i)=>{let r,s=!0;e.subscribe(_e(i,o=>{const a=t(o);(s||!n(r,a))&&(s=!1,r=a,i.next(o))}))})}function q3(n,t){return n===t}function Ot(n){return Pe((t,e)=>{di(n).subscribe(_e(e,()=>e.complete(),y)),!e.closed&&t.subscribe(e)})}let Kx=(()=>{class n{create(e){return"undefined"==typeof MutationObserver?null:new MutationObserver(e)}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Y3=(()=>{class n{constructor(e){this._mutationObserverFactory=e,this._observedElements=new Map}ngOnDestroy(){this._observedElements.forEach((e,i)=>this._cleanupObserver(i))}observe(e){const i=Rn(e);return new J(r=>{const o=this._observeElement(i).subscribe(r);return()=>{o.unsubscribe(),this._unobserveElement(i)}})}_observeElement(e){if(this._observedElements.has(e))this._observedElements.get(e).count++;else{const i=new ue,r=this._mutationObserverFactory.create(s=>i.next(s));r&&r.observe(e,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(e,{observer:r,stream:i,count:1})}return this._observedElements.get(e).stream}_unobserveElement(e){this._observedElements.has(e)&&(this._observedElements.get(e).count--,this._observedElements.get(e).count||this._cleanupObserver(e))}_cleanupObserver(e){if(this._observedElements.has(e)){const{observer:i,stream:r}=this._observedElements.get(e);i&&i.disconnect(),r.complete(),this._observedElements.delete(e)}}}return n.\u0275fac=function(e){return new(e||n)(te(Kx))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),T_=(()=>{class n{constructor(e,i,r){this._contentObserver=e,this._elementRef=i,this._ngZone=r,this.event=new je,this._disabled=!1,this._currentSubscription=null}get disabled(){return this._disabled}set disabled(e){this._disabled=rt(e),this._disabled?this._unsubscribe():this._subscribe()}get debounce(){return this._debounce}set debounce(e){this._debounce=Ii(e),this._subscribe()}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();const e=this._contentObserver.observe(this._elementRef);this._ngZone.runOutsideAngular(()=>{this._currentSubscription=(this.debounce?e.pipe(x_(this.debounce)):e).subscribe(this.event)})}_unsubscribe(){var e;null===(e=this._currentSubscription)||void 0===e||e.unsubscribe()}}return n.\u0275fac=function(e){return new(e||n)(x(Y3),x(Je),x(et))},n.\u0275dir=Me({type:n,selectors:[["","cdkObserveContent",""]],inputs:{disabled:["cdkObserveContentDisabled","disabled"],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]}),n})(),Gu=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[Kx]}),n})();class Xx{constructor(t){this._items=t,this._activeItemIndex=-1,this._activeItem=null,this._wrap=!1,this._letterKeyStream=new ue,this._typeaheadSubscription=X.EMPTY,this._vertical=!0,this._allowedModifierKeys=[],this._homeAndEnd=!1,this._skipPredicateFn=e=>e.disabled,this._pressedLetters=[],this.tabOut=new ue,this.change=new ue,t instanceof ma&&t.changes.subscribe(e=>{if(this._activeItem){const r=e.toArray().indexOf(this._activeItem);r>-1&&r!==this._activeItemIndex&&(this._activeItemIndex=r)}})}skipPredicate(t){return this._skipPredicateFn=t,this}withWrap(t=!0){return this._wrap=t,this}withVerticalOrientation(t=!0){return this._vertical=t,this}withHorizontalOrientation(t){return this._horizontal=t,this}withAllowedModifierKeys(t){return this._allowedModifierKeys=t,this}withTypeAhead(t=200){return this._typeaheadSubscription.unsubscribe(),this._typeaheadSubscription=this._letterKeyStream.pipe(wn(e=>this._pressedLetters.push(e)),x_(t),yn(()=>this._pressedLetters.length>0),U(()=>this._pressedLetters.join(""))).subscribe(e=>{const i=this._getItemsArray();for(let r=1;r!t[s]||this._allowedModifierKeys.indexOf(s)>-1);switch(e){case 9:return void this.tabOut.next();case 40:if(this._vertical&&r){this.setNextItemActive();break}return;case 38:if(this._vertical&&r){this.setPreviousItemActive();break}return;case 39:if(this._horizontal&&r){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case 37:if(this._horizontal&&r){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case 36:if(this._homeAndEnd&&r){this.setFirstItemActive();break}return;case 35:if(this._homeAndEnd&&r){this.setLastItemActive();break}return;default:return void((r||gi(t,"shiftKey"))&&(t.key&&1===t.key.length?this._letterKeyStream.next(t.key.toLocaleUpperCase()):(e>=65&&e<=90||e>=48&&e<=57)&&this._letterKeyStream.next(String.fromCharCode(e))))}this._pressedLetters=[],t.preventDefault()}get activeItemIndex(){return this._activeItemIndex}get activeItem(){return this._activeItem}isTyping(){return this._pressedLetters.length>0}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._items.length-1,-1)}setNextItemActive(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(t){const e=this._getItemsArray(),i="number"==typeof t?t:e.indexOf(t),r=e[i];this._activeItem=null==r?null:r,this._activeItemIndex=i}_setActiveItemByDelta(t){this._wrap?this._setActiveInWrapMode(t):this._setActiveInDefaultMode(t)}_setActiveInWrapMode(t){const e=this._getItemsArray();for(let i=1;i<=e.length;i++){const r=(this._activeItemIndex+t*i+e.length)%e.length;if(!this._skipPredicateFn(e[r]))return void this.setActiveItem(r)}}_setActiveInDefaultMode(t){this._setActiveItemByIndex(this._activeItemIndex+t,t)}_setActiveItemByIndex(t,e){const i=this._getItemsArray();if(i[t]){for(;this._skipPredicateFn(i[t]);)if(!i[t+=e])return;this.setActiveItem(t)}}_getItemsArray(){return this._items instanceof ma?this._items.toArray():this._items}}class Z3 extends Xx{setActiveItem(t){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(t),this.activeItem&&this.activeItem.setActiveStyles()}}class Wu extends Xx{constructor(){super(...arguments),this._origin="program"}setFocusOrigin(t){return this._origin=t,this}setActiveItem(t){super.setActiveItem(t),this.activeItem&&this.activeItem.focus(this._origin)}}let qu=(()=>{class n{constructor(e){this._platform=e}isDisabled(e){return e.hasAttribute("disabled")}isVisible(e){return function J3(n){return!!(n.offsetWidth||n.offsetHeight||"function"==typeof n.getClientRects&&n.getClientRects().length)}(e)&&"visible"===getComputedStyle(e).visibility}isTabbable(e){if(!this._platform.isBrowser)return!1;const i=function X3(n){try{return n.frameElement}catch(t){return null}}(function aU(n){return n.ownerDocument&&n.ownerDocument.defaultView||window}(e));if(i&&(-1===eS(i)||!this.isVisible(i)))return!1;let r=e.nodeName.toLowerCase(),s=eS(e);return e.hasAttribute("contenteditable")?-1!==s:!("iframe"===r||"object"===r||this._platform.WEBKIT&&this._platform.IOS&&!function sU(n){let t=n.nodeName.toLowerCase(),e="input"===t&&n.type;return"text"===e||"password"===e||"select"===t||"textarea"===t}(e))&&("audio"===r?!!e.hasAttribute("controls")&&-1!==s:"video"===r?-1!==s&&(null!==s||this._platform.FIREFOX||e.hasAttribute("controls")):e.tabIndex>=0)}isFocusable(e,i){return function oU(n){return!function tU(n){return function iU(n){return"input"==n.nodeName.toLowerCase()}(n)&&"hidden"==n.type}(n)&&(function eU(n){let t=n.nodeName.toLowerCase();return"input"===t||"select"===t||"button"===t||"textarea"===t}(n)||function nU(n){return function rU(n){return"a"==n.nodeName.toLowerCase()}(n)&&n.hasAttribute("href")}(n)||n.hasAttribute("contenteditable")||Jx(n))}(e)&&!this.isDisabled(e)&&((null==i?void 0:i.ignoreVisibility)||this.isVisible(e))}}return n.\u0275fac=function(e){return new(e||n)(te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Jx(n){if(!n.hasAttribute("tabindex")||void 0===n.tabIndex)return!1;let t=n.getAttribute("tabindex");return!(!t||isNaN(parseInt(t,10)))}function eS(n){if(!Jx(n))return null;const t=parseInt(n.getAttribute("tabindex")||"",10);return isNaN(t)?-1:t}class lU{constructor(t,e,i,r,s=!1){this._element=t,this._checker=e,this._ngZone=i,this._document=r,this._hasAttached=!1,this.startAnchorListener=()=>this.focusLastTabbableElement(),this.endAnchorListener=()=>this.focusFirstTabbableElement(),this._enabled=!0,s||this.attachAnchors()}get enabled(){return this._enabled}set enabled(t){this._enabled=t,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}destroy(){const t=this._startAnchor,e=this._endAnchor;t&&(t.removeEventListener("focus",this.startAnchorListener),t.remove()),e&&(e.removeEventListener("focus",this.endAnchorListener),e.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusInitialElement(t)))})}focusFirstTabbableElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusFirstTabbableElement(t)))})}focusLastTabbableElementWhenReady(t){return new Promise(e=>{this._executeOnStable(()=>e(this.focusLastTabbableElement(t)))})}_getRegionBoundary(t){const e=this._element.querySelectorAll(`[cdk-focus-region-${t}], [cdkFocusRegion${t}], [cdk-focus-${t}]`);return"start"==t?e.length?e[0]:this._getFirstTabbableElement(this._element):e.length?e[e.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(t){const e=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(e){if(!this._checker.isFocusable(e)){const i=this._getFirstTabbableElement(e);return null==i||i.focus(t),!!i}return e.focus(t),!0}return this.focusFirstTabbableElement(t)}focusFirstTabbableElement(t){const e=this._getRegionBoundary("start");return e&&e.focus(t),!!e}focusLastTabbableElement(t){const e=this._getRegionBoundary("end");return e&&e.focus(t),!!e}hasAttached(){return this._hasAttached}_getFirstTabbableElement(t){if(this._checker.isFocusable(t)&&this._checker.isTabbable(t))return t;const e=t.children;for(let i=0;i=0;i--){const r=e[i].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(e[i]):null;if(r)return r}return null}_createAnchor(){const t=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,t),t.classList.add("cdk-visually-hidden"),t.classList.add("cdk-focus-trap-anchor"),t.setAttribute("aria-hidden","true"),t}_toggleAnchorTabIndex(t,e){t?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex")}toggleAnchors(t){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}_executeOnStable(t){this._ngZone.isStable?t():this._ngZone.onStable.pipe(sn(1)).subscribe(t)}}let A_=(()=>{class n{constructor(e,i,r){this._checker=e,this._ngZone=i,this._document=r}create(e,i=!1){return new lU(e,this._checker,this._ngZone,this._document,i)}}return n.\u0275fac=function(e){return new(e||n)(te(qu),te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function I_(n){return 0===n.buttons||0===n.offsetX&&0===n.offsetY}function R_(n){const t=n.touches&&n.touches[0]||n.changedTouches&&n.changedTouches[0];return!(!t||-1!==t.identifier||null!=t.radiusX&&1!==t.radiusX||null!=t.radiusY&&1!==t.radiusY)}const cU=new De("cdk-input-modality-detector-options"),dU={ignoreKeys:[18,17,224,91,16]},xa=Ar({passive:!0,capture:!0});let uU=(()=>{class n{constructor(e,i,r,s){this._platform=e,this._mostRecentTarget=null,this._modality=new mi(null),this._lastTouchMs=0,this._onKeydown=o=>{var a,l;null!==(l=null===(a=this._options)||void 0===a?void 0:a.ignoreKeys)&&void 0!==l&&l.some(c=>c===o.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=ur(o))},this._onMousedown=o=>{Date.now()-this._lastTouchMs<650||(this._modality.next(I_(o)?"keyboard":"mouse"),this._mostRecentTarget=ur(o))},this._onTouchstart=o=>{R_(o)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=ur(o))},this._options=Object.assign(Object.assign({},dU),s),this.modalityDetected=this._modality.pipe(S_(1)),this.modalityChanged=this.modalityDetected.pipe(k_()),e.isBrowser&&i.runOutsideAngular(()=>{r.addEventListener("keydown",this._onKeydown,xa),r.addEventListener("mousedown",this._onMousedown,xa),r.addEventListener("touchstart",this._onTouchstart,xa)})}get mostRecentModality(){return this._modality.value}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,xa),document.removeEventListener("mousedown",this._onMousedown,xa),document.removeEventListener("touchstart",this._onTouchstart,xa))}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(et),te(ct),te(cU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const hU=new De("liveAnnouncerElement",{providedIn:"root",factory:function fU(){return null}}),pU=new De("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let P_=(()=>{class n{constructor(e,i,r,s){this._ngZone=i,this._defaultOptions=s,this._document=r,this._liveElement=e||this._createLiveElement()}announce(e,...i){const r=this._defaultOptions;let s,o;return 1===i.length&&"number"==typeof i[0]?o=i[0]:[s,o]=i,this.clear(),clearTimeout(this._previousTimeout),s||(s=r&&r.politeness?r.politeness:"polite"),null==o&&r&&(o=r.duration),this._liveElement.setAttribute("aria-live",s),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(a=>this._currentResolve=a)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=e,"number"==typeof o&&(this._previousTimeout=setTimeout(()=>this.clear(),o)),this._currentResolve(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){var e,i;clearTimeout(this._previousTimeout),null===(e=this._liveElement)||void 0===e||e.remove(),this._liveElement=null,null===(i=this._currentResolve)||void 0===i||i.call(this),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const e="cdk-live-announcer-element",i=this._document.getElementsByClassName(e),r=this._document.createElement("div");for(let s=0;s{class n{constructor(e,i,r,s,o){this._ngZone=e,this._platform=i,this._inputModalityDetector=r,this._origin=null,this._windowFocused=!1,this._originFromTouchInteraction=!1,this._elementInfo=new Map,this._monitoredElementCount=0,this._rootNodeFocusListenerCount=new Map,this._windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)},this._stopInputModalityDetector=new ue,this._rootNodeFocusAndBlurListener=a=>{const l=ur(a),c="focus"===a.type?this._onFocus:this._onBlur;for(let d=l;d;d=d.parentElement)c.call(this,a,d)},this._document=s,this._detectionMode=(null==o?void 0:o.detectionMode)||0}monitor(e,i=!1){const r=Rn(e);if(!this._platform.isBrowser||1!==r.nodeType)return tt(null);const s=ju(r)||this._getDocument(),o=this._elementInfo.get(r);if(o)return i&&(o.checkChildren=!0),o.subject;const a={checkChildren:i,subject:new ue,rootNode:s};return this._elementInfo.set(r,a),this._registerGlobalListeners(a),a.subject}stopMonitoring(e){const i=Rn(e),r=this._elementInfo.get(i);r&&(r.subject.complete(),this._setClasses(i),this._elementInfo.delete(i),this._removeGlobalListeners(r))}focusVia(e,i,r){const s=Rn(e);s===this._getDocument().activeElement?this._getClosestElementsInfo(s).forEach(([a,l])=>this._originChanged(a,i,l)):(this._setOrigin(i),"function"==typeof s.focus&&s.focus(r))}ngOnDestroy(){this._elementInfo.forEach((e,i)=>this.stopMonitoring(i))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(e){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(e)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:"program"}_shouldBeAttributedToTouch(e){return 1===this._detectionMode||!(null==e||!e.contains(this._inputModalityDetector._mostRecentTarget))}_setClasses(e,i){e.classList.toggle("cdk-focused",!!i),e.classList.toggle("cdk-touch-focused","touch"===i),e.classList.toggle("cdk-keyboard-focused","keyboard"===i),e.classList.toggle("cdk-mouse-focused","mouse"===i),e.classList.toggle("cdk-program-focused","program"===i)}_setOrigin(e,i=!1){this._ngZone.runOutsideAngular(()=>{this._origin=e,this._originFromTouchInteraction="touch"===e&&i,0===this._detectionMode&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(e,i){const r=this._elementInfo.get(i),s=ur(e);!r||!r.checkChildren&&i!==s||this._originChanged(i,this._getFocusOrigin(s),r)}_onBlur(e,i){const r=this._elementInfo.get(i);!r||r.checkChildren&&e.relatedTarget instanceof Node&&i.contains(e.relatedTarget)||(this._setClasses(i),this._emitOrigin(r,null))}_emitOrigin(e,i){e.subject.observers.length&&this._ngZone.run(()=>e.subject.next(i))}_registerGlobalListeners(e){if(!this._platform.isBrowser)return;const i=e.rootNode,r=this._rootNodeFocusListenerCount.get(i)||0;r||this._ngZone.runOutsideAngular(()=>{i.addEventListener("focus",this._rootNodeFocusAndBlurListener,Yu),i.addEventListener("blur",this._rootNodeFocusAndBlurListener,Yu)}),this._rootNodeFocusListenerCount.set(i,r+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(Ot(this._stopInputModalityDetector)).subscribe(s=>{this._setOrigin(s,!0)}))}_removeGlobalListeners(e){const i=e.rootNode;if(this._rootNodeFocusListenerCount.has(i)){const r=this._rootNodeFocusListenerCount.get(i);r>1?this._rootNodeFocusListenerCount.set(i,r-1):(i.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Yu),i.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Yu),this._rootNodeFocusListenerCount.delete(i))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(e,i,r){this._setClasses(e,i),this._emitOrigin(r,i),this._lastFocusOrigin=i}_getClosestElementsInfo(e){const i=[];return this._elementInfo.forEach((r,s)=>{(s===e||r.checkChildren&&s.contains(e))&&i.push([s,r])}),i}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(bn),te(uU),te(ct,8),te(mU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const nS="cdk-high-contrast-black-on-white",iS="cdk-high-contrast-white-on-black",O_="cdk-high-contrast-active";let rS=(()=>{class n{constructor(e,i){this._platform=e,this._document=i}getHighContrastMode(){if(!this._platform.isBrowser)return 0;const e=this._document.createElement("div");e.style.backgroundColor="rgb(1,2,3)",e.style.position="absolute",this._document.body.appendChild(e);const i=this._document.defaultView||window,r=i&&i.getComputedStyle?i.getComputedStyle(e):null,s=(r&&r.backgroundColor||"").replace(/ /g,"");switch(e.remove(),s){case"rgb(0,0,0)":return 2;case"rgb(255,255,255)":return 1}return 0}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const e=this._document.body.classList;e.remove(O_,nS,iS),this._hasCheckedHighContrastMode=!0;const i=this.getHighContrastMode();1===i?e.add(O_,nS):2===i&&e.add(O_,iS)}}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Ku=(()=>{class n{constructor(e){e._applyBodyHighContrastModeCssClasses()}}return n.\u0275fac=function(e){return new(e||n)(te(rS))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Gu]}),n})();function F_(n=0,t,e=W3){let i=-1;return null!=t&&(sy(t)?e=t:i=t),new J(r=>{let s=function gU(n){return n instanceof Date&&!isNaN(n)}(n)?+n-e.now():n;s<0&&(s=0);let o=0;return e.schedule(function(){r.closed||(r.next(o++),0<=i?this.schedule(void 0,i):r.complete())},s)})}const oc={schedule(n){let t=requestAnimationFrame,e=cancelAnimationFrame;const{delegate:i}=oc;i&&(t=i.requestAnimationFrame,e=i.cancelAnimationFrame);const r=t(s=>{e=void 0,n(s)});return new X(()=>null==e?void 0:e(r))},requestAnimationFrame(...n){const{delegate:t}=oc;return((null==t?void 0:t.requestAnimationFrame)||requestAnimationFrame)(...n)},cancelAnimationFrame(...n){const{delegate:t}=oc;return((null==t?void 0:t.cancelAnimationFrame)||cancelAnimationFrame)(...n)},delegate:void 0},sS=new class yU extends M_{flush(t){this._active=!0;const e=this._scheduled;this._scheduled=void 0;const{actions:i}=this;let r;t=t||i.shift();do{if(r=t.execute(t.state,t.delay))break}while((t=i[0])&&t.id===e&&i.shift());if(this._active=!1,r){for(;(t=i[0])&&t.id===e&&i.shift();)t.unsubscribe();throw r}}}(class vU extends D_{constructor(t,e){super(t,e),this.scheduler=t,this.work=e}requestAsyncId(t,e,i=0){return null!==i&&i>0?super.requestAsyncId(t,e,i):(t.actions.push(this),t._scheduled||(t._scheduled=oc.requestAnimationFrame(()=>t.flush(void 0))))}recycleAsyncId(t,e,i=0){if(null!=i&&i>0||null==i&&this.delay>0)return super.recycleAsyncId(t,e,i);t.actions.some(r=>r.id===e)||(oc.cancelAnimationFrame(e),t._scheduled=void 0)}}),bU=["addListener","removeListener"],wU=["addEventListener","removeEventListener"],CU=["on","off"];function _o(n,t,e,i){if(ut(e)&&(i=e,e=void 0),i)return _o(n,t,e).pipe(Ng(i));const[r,s]=function MU(n){return ut(n.addEventListener)&&ut(n.removeEventListener)}(n)?wU.map(o=>a=>n[o](t,a,e)):function DU(n){return ut(n.addListener)&&ut(n.removeListener)}(n)?bU.map(oS(n,t)):function EU(n){return ut(n.on)&&ut(n.off)}(n)?CU.map(oS(n,t)):[];if(!r&&Oi(n))return Pn(o=>_o(o,t,e))(di(n));if(!r)throw new TypeError("Invalid event target");return new J(o=>{const a=(...l)=>o.next(1s(a)})}function oS(n,t){return e=>i=>n[e](t,i)}let L_,xU=1;const Qu={};function aS(n){return n in Qu&&(delete Qu[n],!0)}const SU={setImmediate(n){const t=xU++;return Qu[t]=!0,L_||(L_=Promise.resolve()),L_.then(()=>aS(t)&&n()),t},clearImmediate(n){aS(n)}},{setImmediate:kU,clearImmediate:TU}=SU,Zu={setImmediate(...n){const{delegate:t}=Zu;return((null==t?void 0:t.setImmediate)||kU)(...n)},clearImmediate(n){const{delegate:t}=Zu;return((null==t?void 0:t.clearImmediate)||TU)(n)},delegate:void 0};new class IU extends M_{flush(t){this._active=!0;const e=this._scheduled;this._scheduled=void 0;const{actions:i}=this;let r;t=t||i.shift();do{if(r=t.execute(t.state,t.delay))break}while((t=i[0])&&t.id===e&&i.shift());if(this._active=!1,r){for(;(t=i[0])&&t.id===e&&i.shift();)t.unsubscribe();throw r}}}(class AU extends D_{constructor(t,e){super(t,e),this.scheduler=t,this.work=e}requestAsyncId(t,e,i=0){return null!==i&&i>0?super.requestAsyncId(t,e,i):(t.actions.push(this),t._scheduled||(t._scheduled=Zu.setImmediate(t.flush.bind(t,void 0))))}recycleAsyncId(t,e,i=0){if(null!=i&&i>0||null==i&&this.delay>0)return super.recycleAsyncId(t,e,i);t.actions.some(r=>r.id===e)||(Zu.clearImmediate(e),t._scheduled=void 0)}});function lS(n,t=$u){return function PU(n){return Pe((t,e)=>{let i=!1,r=null,s=null,o=!1;const a=()=>{if(null==s||s.unsubscribe(),s=null,i){i=!1;const c=r;r=null,e.next(c)}o&&e.complete()},l=()=>{s=null,o&&e.complete()};t.subscribe(_e(e,c=>{i=!0,r=c,s||di(n(c)).subscribe(s=_e(e,a,l))},()=>{o=!0,(!i||!s||s.closed)&&e.complete()}))})}(()=>F_(n,t))}const OU=new De("cdk-dir-doc",{providedIn:"root",factory:function FU(){return ld(ct)}}),LU=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let qi=(()=>{class n{constructor(e){if(this.value="ltr",this.change=new je,e){const r=e.documentElement?e.documentElement.dir:null;this.value=function NU(n){const t=(null==n?void 0:n.toLowerCase())||"";return"auto"===t&&"undefined"!=typeof navigator&&(null==navigator?void 0:navigator.language)?LU.test(navigator.language)?"rtl":"ltr":"rtl"===t?"rtl":"ltr"}((e.body?e.body.dir:null)||r||"ltr")}}ngOnDestroy(){this.change.complete()}}return n.\u0275fac=function(e){return new(e||n)(te(OU,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ac=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),VU=(()=>{class n{constructor(e,i,r){this._ngZone=e,this._platform=i,this._scrolled=new ue,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=r}register(e){this.scrollContainers.has(e)||this.scrollContainers.set(e,e.elementScrolled().subscribe(()=>this._scrolled.next(e)))}deregister(e){const i=this.scrollContainers.get(e);i&&(i.unsubscribe(),this.scrollContainers.delete(e))}scrolled(e=20){return this._platform.isBrowser?new J(i=>{this._globalSubscription||this._addGlobalListener();const r=e>0?this._scrolled.pipe(lS(e)).subscribe(i):this._scrolled.subscribe(i);return this._scrolledCount++,()=>{r.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):tt()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((e,i)=>this.deregister(i)),this._scrolled.complete()}ancestorScrolled(e,i){const r=this.getAncestorScrollContainers(e);return this.scrolled(i).pipe(yn(s=>!s||r.indexOf(s)>-1))}getAncestorScrollContainers(e){const i=[];return this.scrollContainers.forEach((r,s)=>{this._scrollableContainsElement(s,e)&&i.push(s)}),i}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(e,i){let r=Rn(i),s=e.getElementRef().nativeElement;do{if(r==s)return!0}while(r=r.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>_o(this._getWindow().document,"scroll").subscribe(()=>this._scrolled.next()))}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(bn),te(ct,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ss=(()=>{class n{constructor(e,i,r){this._platform=e,this._change=new ue,this._changeListener=s=>{this._change.next(s)},this._document=r,i.runOutsideAngular(()=>{if(e.isBrowser){const s=this._getWindow();s.addEventListener("resize",this._changeListener),s.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const e=this._getWindow();e.removeEventListener("resize",this._changeListener),e.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const e={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),e}getViewportRect(){const e=this.getViewportScrollPosition(),{width:i,height:r}=this.getViewportSize();return{top:e.top,left:e.left,bottom:e.top+r,right:e.left+i,height:r,width:i}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const e=this._document,i=this._getWindow(),r=e.documentElement,s=r.getBoundingClientRect();return{top:-s.top||e.body.scrollTop||i.scrollY||r.scrollTop||0,left:-s.left||e.body.scrollLeft||i.scrollX||r.scrollLeft||0}}change(e=20){return e>0?this._change.pipe(lS(e)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const e=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:e.innerWidth,height:e.innerHeight}:{width:0,height:0}}}return n.\u0275fac=function(e){return new(e||n)(te(bn),te(et),te(ct,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),Sa=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),N_=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ac,Sa,ac,Sa]}),n})();function B_(n,t,e){for(let i in t)if(t.hasOwnProperty(i)){const r=t[i];r?n.setProperty(i,r,null!=e&&e.has(i)?"important":""):n.removeProperty(i)}return n}function ka(n,t){const e=t?"":"none";B_(n.style,{"touch-action":t?"":"none","-webkit-user-drag":t?"":"none","-webkit-tap-highlight-color":t?"":"transparent","user-select":e,"-ms-user-select":e,"-webkit-user-select":e,"-moz-user-select":e})}function cS(n,t,e){B_(n.style,{position:t?"":"fixed",top:t?"":"0",opacity:t?"":"0",left:t?"":"-999em"},e)}function Xu(n,t){return t&&"none"!=t?n+" "+t:n}function dS(n){const t=n.toLowerCase().indexOf("ms")>-1?1:1e3;return parseFloat(n)*t}function V_(n,t){return n.getPropertyValue(t).split(",").map(i=>i.trim())}function H_(n){const t=n.getBoundingClientRect();return{top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.width,height:t.height,x:t.x,y:t.y}}function j_(n,t,e){const{top:i,bottom:r,left:s,right:o}=n;return e>=i&&e<=r&&t>=s&&t<=o}function lc(n,t,e){n.top+=t,n.bottom=n.top+n.height,n.left+=e,n.right=n.left+n.width}function uS(n,t,e,i){const{top:r,right:s,bottom:o,left:a,width:l,height:c}=n,d=l*t,f=c*t;return i>r-f&&ia-d&&e{this.positions.set(e,{scrollPosition:{top:e.scrollTop,left:e.scrollLeft},clientRect:H_(e)})})}handleScroll(t){const e=ur(t),i=this.positions.get(e);if(!i)return null;const r=i.scrollPosition;let s,o;if(e===this._document){const c=this.getViewportScrollPosition();s=c.top,o=c.left}else s=e.scrollTop,o=e.scrollLeft;const a=r.top-s,l=r.left-o;return this.positions.forEach((c,d)=>{c.clientRect&&e!==d&&e.contains(d)&&lc(c.clientRect,a,l)}),r.top=s,r.left=o,{top:a,left:l}}getViewportScrollPosition(){return{top:window.scrollY,left:window.scrollX}}}function fS(n){const t=n.cloneNode(!0),e=t.querySelectorAll("[id]"),i=n.nodeName.toLowerCase();t.removeAttribute("id");for(let r=0;r{if(this.beforeStarted.next(),this._handles.length){const l=this._getTargetHandle(a);l&&!this._disabledHandles.has(l)&&!this.disabled&&this._initializeDragSequence(l,a)}else this.disabled||this._initializeDragSequence(this._rootElement,a)},this._pointerMove=a=>{const l=this._getPointerPositionOnPage(a);if(!this._hasStartedDragging){if(Math.abs(l.x-this._pickupPositionOnPage.x)+Math.abs(l.y-this._pickupPositionOnPage.y)>=this._config.dragStartThreshold){const k=Date.now()>=this._dragStartTime+this._getDragStartDelay(a),j=this._dropContainer;if(!k)return void this._endDragSequence(a);(!j||!j.isDragging()&&!j.isReceiving())&&(a.preventDefault(),this._hasStartedDragging=!0,this._ngZone.run(()=>this._startDragSequence(a)))}return}a.preventDefault();const c=this._getConstrainedPointerPosition(l);if(this._hasMoved=!0,this._lastKnownPointerPosition=l,this._updatePointerDirectionDelta(c),this._dropContainer)this._updateActiveDropContainer(c,l);else{const d=this._activeTransform;d.x=c.x-this._pickupPositionOnPage.x+this._passiveTransform.x,d.y=c.y-this._pickupPositionOnPage.y+this._passiveTransform.y,this._applyRootElementTransform(d.x,d.y)}this._moveEvents.observers.length&&this._ngZone.run(()=>{this._moveEvents.next({source:this,pointerPosition:c,event:a,distance:this._getDragDistance(c),delta:this._pointerDirectionDelta})})},this._pointerUp=a=>{this._endDragSequence(a)},this._nativeDragStart=a=>{if(this._handles.length){const l=this._getTargetHandle(a);l&&!this._disabledHandles.has(l)&&!this.disabled&&a.preventDefault()}else this.disabled||a.preventDefault()},this.withRootElement(t).withParent(e.parentDragRef||null),this._parentPositions=new hS(i),o.registerDragItem(this)}get disabled(){return this._disabled||!(!this._dropContainer||!this._dropContainer.disabled)}set disabled(t){const e=rt(t);e!==this._disabled&&(this._disabled=e,this._toggleNativeDragInteractions(),this._handles.forEach(i=>ka(i,e)))}getPlaceholderElement(){return this._placeholder}getRootElement(){return this._rootElement}getVisibleElement(){return this.isDragging()?this.getPlaceholderElement():this.getRootElement()}withHandles(t){this._handles=t.map(i=>Rn(i)),this._handles.forEach(i=>ka(i,this.disabled)),this._toggleNativeDragInteractions();const e=new Set;return this._disabledHandles.forEach(i=>{this._handles.indexOf(i)>-1&&e.add(i)}),this._disabledHandles=e,this}withPreviewTemplate(t){return this._previewTemplate=t,this}withPlaceholderTemplate(t){return this._placeholderTemplate=t,this}withRootElement(t){const e=Rn(t);return e!==this._rootElement&&(this._rootElement&&this._removeRootElementListeners(this._rootElement),this._ngZone.runOutsideAngular(()=>{e.addEventListener("mousedown",this._pointerDown,Ju),e.addEventListener("touchstart",this._pointerDown,_S),e.addEventListener("dragstart",this._nativeDragStart,Ju)}),this._initialTransform=void 0,this._rootElement=e),"undefined"!=typeof SVGElement&&this._rootElement instanceof SVGElement&&(this._ownerSVGElement=this._rootElement.ownerSVGElement),this}withBoundaryElement(t){return this._boundaryElement=t?Rn(t):null,this._resizeSubscription.unsubscribe(),t&&(this._resizeSubscription=this._viewportRuler.change(10).subscribe(()=>this._containInsideBoundaryOnResize())),this}withParent(t){return this._parentDragRef=t,this}dispose(){var t,e;this._removeRootElementListeners(this._rootElement),this.isDragging()&&(null===(t=this._rootElement)||void 0===t||t.remove()),null===(e=this._anchor)||void 0===e||e.remove(),this._destroyPreview(),this._destroyPlaceholder(),this._dragDropRegistry.removeDragItem(this),this._removeSubscriptions(),this.beforeStarted.complete(),this.started.complete(),this.released.complete(),this.ended.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this._moveEvents.complete(),this._handles=[],this._disabledHandles.clear(),this._dropContainer=void 0,this._resizeSubscription.unsubscribe(),this._parentPositions.clear(),this._boundaryElement=this._rootElement=this._ownerSVGElement=this._placeholderTemplate=this._previewTemplate=this._anchor=this._parentDragRef=null}isDragging(){return this._hasStartedDragging&&this._dragDropRegistry.isDragging(this)}reset(){this._rootElement.style.transform=this._initialTransform||"",this._activeTransform={x:0,y:0},this._passiveTransform={x:0,y:0}}disableHandle(t){!this._disabledHandles.has(t)&&this._handles.indexOf(t)>-1&&(this._disabledHandles.add(t),ka(t,!0))}enableHandle(t){this._disabledHandles.has(t)&&(this._disabledHandles.delete(t),ka(t,this.disabled))}withDirection(t){return this._direction=t,this}_withDropContainer(t){this._dropContainer=t}getFreeDragPosition(){const t=this.isDragging()?this._activeTransform:this._passiveTransform;return{x:t.x,y:t.y}}setFreeDragPosition(t){return this._activeTransform={x:0,y:0},this._passiveTransform.x=t.x,this._passiveTransform.y=t.y,this._dropContainer||this._applyRootElementTransform(t.x,t.y),this}withPreviewContainer(t){return this._previewContainer=t,this}_sortFromLastPointerPosition(){const t=this._lastKnownPointerPosition;t&&this._dropContainer&&this._updateActiveDropContainer(this._getConstrainedPointerPosition(t),t)}_removeSubscriptions(){this._pointerMoveSubscription.unsubscribe(),this._pointerUpSubscription.unsubscribe(),this._scrollSubscription.unsubscribe()}_destroyPreview(){var t,e;null===(t=this._preview)||void 0===t||t.remove(),null===(e=this._previewRef)||void 0===e||e.destroy(),this._preview=this._previewRef=null}_destroyPlaceholder(){var t,e;null===(t=this._placeholder)||void 0===t||t.remove(),null===(e=this._placeholderRef)||void 0===e||e.destroy(),this._placeholder=this._placeholderRef=null}_endDragSequence(t){if(this._dragDropRegistry.isDragging(this)&&(this._removeSubscriptions(),this._dragDropRegistry.stopDragging(this),this._toggleNativeDragInteractions(),this._handles&&(this._rootElement.style.webkitTapHighlightColor=this._rootElementTapHighlight),this._hasStartedDragging))if(this.released.next({source:this,event:t}),this._dropContainer)this._dropContainer._stopScrolling(),this._animatePreviewToPlaceholder().then(()=>{this._cleanupDragArtifacts(t),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)});else{this._passiveTransform.x=this._activeTransform.x;const e=this._getPointerPositionOnPage(t);this._passiveTransform.y=this._activeTransform.y,this._ngZone.run(()=>{this.ended.next({source:this,distance:this._getDragDistance(e),dropPoint:e,event:t})}),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)}}_startDragSequence(t){cc(t)&&(this._lastTouchEventTime=Date.now()),this._toggleNativeDragInteractions();const e=this._dropContainer;if(e){const i=this._rootElement,r=i.parentNode,s=this._placeholder=this._createPlaceholderElement(),o=this._anchor=this._anchor||this._document.createComment(""),a=this._getShadowRoot();r.insertBefore(o,i),this._initialTransform=i.style.transform||"",this._preview=this._createPreviewElement(),cS(i,!1,U_),this._document.body.appendChild(r.replaceChild(s,i)),this._getPreviewInsertionPoint(r,a).appendChild(this._preview),this.started.next({source:this,event:t}),e.start(),this._initialContainer=e,this._initialIndex=e.getItemIndex(this)}else this.started.next({source:this,event:t}),this._initialContainer=this._initialIndex=void 0;this._parentPositions.cache(e?e.getScrollableParents():[])}_initializeDragSequence(t,e){this._parentDragRef&&e.stopPropagation();const i=this.isDragging(),r=cc(e),s=!r&&0!==e.button,o=this._rootElement,a=ur(e),l=!r&&this._lastTouchEventTime&&this._lastTouchEventTime+800>Date.now(),c=r?R_(e):I_(e);if(a&&a.draggable&&"mousedown"===e.type&&e.preventDefault(),i||s||l||c)return;if(this._handles.length){const w=o.style;this._rootElementTapHighlight=w.webkitTapHighlightColor||"",w.webkitTapHighlightColor="transparent"}this._hasStartedDragging=this._hasMoved=!1,this._removeSubscriptions(),this._pointerMoveSubscription=this._dragDropRegistry.pointerMove.subscribe(this._pointerMove),this._pointerUpSubscription=this._dragDropRegistry.pointerUp.subscribe(this._pointerUp),this._scrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(w=>this._updateOnScroll(w)),this._boundaryElement&&(this._boundaryRect=H_(this._boundaryElement));const d=this._previewTemplate;this._pickupPositionInElement=d&&d.template&&!d.matchSize?{x:0,y:0}:this._getPointerPositionInElement(t,e);const f=this._pickupPositionOnPage=this._lastKnownPointerPosition=this._getPointerPositionOnPage(e);this._pointerDirectionDelta={x:0,y:0},this._pointerPositionAtLastDirectionChange={x:f.x,y:f.y},this._dragStartTime=Date.now(),this._dragDropRegistry.startDragging(this,e)}_cleanupDragArtifacts(t){cS(this._rootElement,!0,U_),this._anchor.parentNode.replaceChild(this._rootElement,this._anchor),this._destroyPreview(),this._destroyPlaceholder(),this._boundaryRect=this._previewRect=this._initialTransform=void 0,this._ngZone.run(()=>{const e=this._dropContainer,i=e.getItemIndex(this),r=this._getPointerPositionOnPage(t),s=this._getDragDistance(r),o=e._isOverContainer(r.x,r.y);this.ended.next({source:this,distance:s,dropPoint:r,event:t}),this.dropped.next({item:this,currentIndex:i,previousIndex:this._initialIndex,container:e,previousContainer:this._initialContainer,isPointerOverContainer:o,distance:s,dropPoint:r,event:t}),e.drop(this,i,this._initialIndex,this._initialContainer,o,s,r),this._dropContainer=this._initialContainer})}_updateActiveDropContainer({x:t,y:e},{x:i,y:r}){let s=this._initialContainer._getSiblingContainerFromPosition(this,t,e);!s&&this._dropContainer!==this._initialContainer&&this._initialContainer._isOverContainer(t,e)&&(s=this._initialContainer),s&&s!==this._dropContainer&&this._ngZone.run(()=>{this.exited.next({item:this,container:this._dropContainer}),this._dropContainer.exit(this),this._dropContainer=s,this._dropContainer.enter(this,t,e,s===this._initialContainer&&s.sortingDisabled?this._initialIndex:void 0),this.entered.next({item:this,container:s,currentIndex:s.getItemIndex(this)})}),this.isDragging()&&(this._dropContainer._startScrollingIfNecessary(i,r),this._dropContainer._sortItem(this,t,e,this._pointerDirectionDelta),this._applyPreviewTransform(t-this._pickupPositionInElement.x,e-this._pickupPositionInElement.y))}_createPreviewElement(){const t=this._previewTemplate,e=this.previewClass,i=t?t.template:null;let r;if(i&&t){const s=t.matchSize?this._rootElement.getBoundingClientRect():null,o=t.viewContainer.createEmbeddedView(i,t.context);o.detectChanges(),r=yS(o,this._document),this._previewRef=o,t.matchSize?bS(r,s):r.style.transform=eh(this._pickupPositionOnPage.x,this._pickupPositionOnPage.y)}else{const s=this._rootElement;r=fS(s),bS(r,s.getBoundingClientRect()),this._initialTransform&&(r.style.transform=this._initialTransform)}return B_(r.style,{"pointer-events":"none",margin:"0",position:"fixed",top:"0",left:"0","z-index":`${this._config.zIndex||1e3}`},U_),ka(r,!1),r.classList.add("cdk-drag-preview"),r.setAttribute("dir",this._direction),e&&(Array.isArray(e)?e.forEach(s=>r.classList.add(s)):r.classList.add(e)),r}_animatePreviewToPlaceholder(){if(!this._hasMoved)return Promise.resolve();const t=this._placeholder.getBoundingClientRect();this._preview.classList.add("cdk-drag-animating"),this._applyPreviewTransform(t.left,t.top);const e=function jU(n){const t=getComputedStyle(n),e=V_(t,"transition-property"),i=e.find(a=>"transform"===a||"all"===a);if(!i)return 0;const r=e.indexOf(i),s=V_(t,"transition-duration"),o=V_(t,"transition-delay");return dS(s[r])+dS(o[r])}(this._preview);return 0===e?Promise.resolve():this._ngZone.runOutsideAngular(()=>new Promise(i=>{const r=o=>{var a;(!o||ur(o)===this._preview&&"transform"===o.propertyName)&&(null===(a=this._preview)||void 0===a||a.removeEventListener("transitionend",r),i(),clearTimeout(s))},s=setTimeout(r,1.5*e);this._preview.addEventListener("transitionend",r)}))}_createPlaceholderElement(){const t=this._placeholderTemplate,e=t?t.template:null;let i;return e?(this._placeholderRef=t.viewContainer.createEmbeddedView(e,t.context),this._placeholderRef.detectChanges(),i=yS(this._placeholderRef,this._document)):i=fS(this._rootElement),i.style.pointerEvents="none",i.classList.add("cdk-drag-placeholder"),i}_getPointerPositionInElement(t,e){const i=this._rootElement.getBoundingClientRect(),r=t===this._rootElement?null:t,s=r?r.getBoundingClientRect():i,o=cc(e)?e.targetTouches[0]:e,a=this._getViewportScrollPosition();return{x:s.left-i.left+(o.pageX-s.left-a.left),y:s.top-i.top+(o.pageY-s.top-a.top)}}_getPointerPositionOnPage(t){const e=this._getViewportScrollPosition(),i=cc(t)?t.touches[0]||t.changedTouches[0]||{pageX:0,pageY:0}:t,r=i.pageX-e.left,s=i.pageY-e.top;if(this._ownerSVGElement){const o=this._ownerSVGElement.getScreenCTM();if(o){const a=this._ownerSVGElement.createSVGPoint();return a.x=r,a.y=s,a.matrixTransform(o.inverse())}}return{x:r,y:s}}_getConstrainedPointerPosition(t){const e=this._dropContainer?this._dropContainer.lockAxis:null;let{x:i,y:r}=this.constrainPosition?this.constrainPosition(t,this):t;if("x"===this.lockAxis||"x"===e?r=this._pickupPositionOnPage.y:("y"===this.lockAxis||"y"===e)&&(i=this._pickupPositionOnPage.x),this._boundaryRect){const{x:s,y:o}=this._pickupPositionInElement,a=this._boundaryRect,{width:l,height:c}=this._getPreviewRect(),d=a.top+o,f=a.bottom-(c-o);i=vS(i,a.left+s,a.right-(l-s)),r=vS(r,d,f)}return{x:i,y:r}}_updatePointerDirectionDelta(t){const{x:e,y:i}=t,r=this._pointerDirectionDelta,s=this._pointerPositionAtLastDirectionChange,o=Math.abs(e-s.x),a=Math.abs(i-s.y);return o>this._config.pointerDirectionChangeThreshold&&(r.x=e>s.x?1:-1,s.x=e),a>this._config.pointerDirectionChangeThreshold&&(r.y=i>s.y?1:-1,s.y=i),r}_toggleNativeDragInteractions(){if(!this._rootElement||!this._handles)return;const t=this._handles.length>0||!this.isDragging();t!==this._nativeInteractionsEnabled&&(this._nativeInteractionsEnabled=t,ka(this._rootElement,t))}_removeRootElementListeners(t){t.removeEventListener("mousedown",this._pointerDown,Ju),t.removeEventListener("touchstart",this._pointerDown,_S),t.removeEventListener("dragstart",this._nativeDragStart,Ju)}_applyRootElementTransform(t,e){const i=eh(t,e),r=this._rootElement.style;null==this._initialTransform&&(this._initialTransform=r.transform&&"none"!=r.transform?r.transform:""),r.transform=Xu(i,this._initialTransform)}_applyPreviewTransform(t,e){var i;const r=null!==(i=this._previewTemplate)&&void 0!==i&&i.template?void 0:this._initialTransform,s=eh(t,e);this._preview.style.transform=Xu(s,r)}_getDragDistance(t){const e=this._pickupPositionOnPage;return e?{x:t.x-e.x,y:t.y-e.y}:{x:0,y:0}}_cleanupCachedDimensions(){this._boundaryRect=this._previewRect=void 0,this._parentPositions.clear()}_containInsideBoundaryOnResize(){let{x:t,y:e}=this._passiveTransform;if(0===t&&0===e||this.isDragging()||!this._boundaryElement)return;const i=this._boundaryElement.getBoundingClientRect(),r=this._rootElement.getBoundingClientRect();if(0===i.width&&0===i.height||0===r.width&&0===r.height)return;const s=i.left-r.left,o=r.right-i.right,a=i.top-r.top,l=r.bottom-i.bottom;i.width>r.width?(s>0&&(t+=s),o>0&&(t-=o)):t=0,i.height>r.height?(a>0&&(e+=a),l>0&&(e-=l)):e=0,(t!==this._passiveTransform.x||e!==this._passiveTransform.y)&&this.setFreeDragPosition({y:e,x:t})}_getDragStartDelay(t){const e=this.dragStartDelay;return"number"==typeof e?e:cc(t)?e.touch:e?e.mouse:0}_updateOnScroll(t){const e=this._parentPositions.handleScroll(t);if(e){const i=ur(t);this._boundaryRect&&i!==this._boundaryElement&&i.contains(this._boundaryElement)&&lc(this._boundaryRect,e.top,e.left),this._pickupPositionOnPage.x+=e.left,this._pickupPositionOnPage.y+=e.top,this._dropContainer||(this._activeTransform.x-=e.left,this._activeTransform.y-=e.top,this._applyRootElementTransform(this._activeTransform.x,this._activeTransform.y))}}_getViewportScrollPosition(){var t;return(null===(t=this._parentPositions.positions.get(this._document))||void 0===t?void 0:t.scrollPosition)||this._parentPositions.getViewportScrollPosition()}_getShadowRoot(){return void 0===this._cachedShadowRoot&&(this._cachedShadowRoot=ju(this._rootElement)),this._cachedShadowRoot}_getPreviewInsertionPoint(t,e){const i=this._previewContainer||"global";if("parent"===i)return t;if("global"===i){const r=this._document;return e||r.fullscreenElement||r.webkitFullscreenElement||r.mozFullScreenElement||r.msFullscreenElement||r.body}return Rn(i)}_getPreviewRect(){return(!this._previewRect||!this._previewRect.width&&!this._previewRect.height)&&(this._previewRect=(this._preview||this._rootElement).getBoundingClientRect()),this._previewRect}_getTargetHandle(t){return this._handles.find(e=>t.target&&(t.target===e||e.contains(t.target)))}}function eh(n,t){return`translate3d(${Math.round(n)}px, ${Math.round(t)}px, 0)`}function vS(n,t,e){return Math.max(t,Math.min(e,n))}function cc(n){return"t"===n.type[0]}function yS(n,t){const e=n.rootNodes;if(1===e.length&&e[0].nodeType===t.ELEMENT_NODE)return e[0];const i=t.createElement("div");return e.forEach(r=>i.appendChild(r)),i}function bS(n,t){n.style.width=`${t.width}px`,n.style.height=`${t.height}px`,n.style.transform=eh(t.left,t.top)}function dc(n,t){return Math.max(0,Math.min(t,n))}class WU{constructor(t,e,i,r,s){this._dragDropRegistry=e,this._ngZone=r,this._viewportRuler=s,this.disabled=!1,this.sortingDisabled=!1,this.autoScrollDisabled=!1,this.autoScrollStep=2,this.enterPredicate=()=>!0,this.sortPredicate=()=>!0,this.beforeStarted=new ue,this.entered=new ue,this.exited=new ue,this.dropped=new ue,this.sorted=new ue,this._isDragging=!1,this._itemPositions=[],this._previousSwap={drag:null,delta:0,overlaps:!1},this._draggables=[],this._siblings=[],this._orientation="vertical",this._activeSiblings=new Set,this._direction="ltr",this._viewportScrollSubscription=X.EMPTY,this._verticalScrollDirection=0,this._horizontalScrollDirection=0,this._stopScrollTimers=new ue,this._cachedShadowRoot=null,this._startScrollInterval=()=>{this._stopScrolling(),function _U(n=0,t=$u){return n<0&&(n=0),F_(n,n,t)}(0,sS).pipe(Ot(this._stopScrollTimers)).subscribe(()=>{const o=this._scrollNode,a=this.autoScrollStep;1===this._verticalScrollDirection?o.scrollBy(0,-a):2===this._verticalScrollDirection&&o.scrollBy(0,a),1===this._horizontalScrollDirection?o.scrollBy(-a,0):2===this._horizontalScrollDirection&&o.scrollBy(a,0)})},this.element=Rn(t),this._document=i,this.withScrollableParents([this.element]),e.registerDropContainer(this),this._parentPositions=new hS(i)}dispose(){this._stopScrolling(),this._stopScrollTimers.complete(),this._viewportScrollSubscription.unsubscribe(),this.beforeStarted.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this.sorted.complete(),this._activeSiblings.clear(),this._scrollNode=null,this._parentPositions.clear(),this._dragDropRegistry.removeDropContainer(this)}isDragging(){return this._isDragging}start(){this._draggingStarted(),this._notifyReceivingSiblings()}enter(t,e,i,r){let s;this._draggingStarted(),null==r?(s=this.sortingDisabled?this._draggables.indexOf(t):-1,-1===s&&(s=this._getItemIndexFromPointerPosition(t,e,i))):s=r;const o=this._activeDraggables,a=o.indexOf(t),l=t.getPlaceholderElement();let c=o[s];if(c===t&&(c=o[s+1]),!c&&(null==s||-1===s||s-1&&o.splice(a,1),c&&!this._dragDropRegistry.isDragging(c)){const d=c.getRootElement();d.parentElement.insertBefore(l,d),o.splice(s,0,t)}else Rn(this.element).appendChild(l),o.push(t);l.style.transform="",this._cacheItemPositions(),this._cacheParentPositions(),this._notifyReceivingSiblings(),this.entered.next({item:t,container:this,currentIndex:this.getItemIndex(t)})}exit(t){this._reset(),this.exited.next({item:t,container:this})}drop(t,e,i,r,s,o,a,l={}){this._reset(),this.dropped.next({item:t,currentIndex:e,previousIndex:i,container:this,previousContainer:r,isPointerOverContainer:s,distance:o,dropPoint:a,event:l})}withItems(t){const e=this._draggables;return this._draggables=t,t.forEach(i=>i._withDropContainer(this)),this.isDragging()&&(e.filter(r=>r.isDragging()).every(r=>-1===t.indexOf(r))?this._reset():this._cacheItems()),this}withDirection(t){return this._direction=t,this}connectedTo(t){return this._siblings=t.slice(),this}withOrientation(t){return this._orientation=t,this}withScrollableParents(t){const e=Rn(this.element);return this._scrollableElements=-1===t.indexOf(e)?[e,...t]:t.slice(),this}getScrollableParents(){return this._scrollableElements}getItemIndex(t){return this._isDragging?("horizontal"===this._orientation&&"rtl"===this._direction?this._itemPositions.slice().reverse():this._itemPositions).findIndex(i=>i.drag===t):this._draggables.indexOf(t)}isReceiving(){return this._activeSiblings.size>0}_sortItem(t,e,i,r){if(this.sortingDisabled||!this._clientRect||!uS(this._clientRect,.05,e,i))return;const s=this._itemPositions,o=this._getItemIndexFromPointerPosition(t,e,i,r);if(-1===o&&s.length>0)return;const a="horizontal"===this._orientation,l=s.findIndex(ae=>ae.drag===t),c=s[o],f=c.clientRect,w=l>o?1:-1,k=this._getItemOffsetPx(s[l].clientRect,f,w),j=this._getSiblingOffsetPx(l,s,w),K=s.slice();(function GU(n,t,e){const i=dc(t,n.length-1),r=dc(e,n.length-1);if(i===r)return;const s=n[i],o=r{if(K[ce]===ae)return;const Te=ae.drag===t,he=Te?k:j,Oe=Te?t.getPlaceholderElement():ae.drag.getRootElement();ae.offset+=he,a?(Oe.style.transform=Xu(`translate3d(${Math.round(ae.offset)}px, 0, 0)`,ae.initialTransform),lc(ae.clientRect,0,he)):(Oe.style.transform=Xu(`translate3d(0, ${Math.round(ae.offset)}px, 0)`,ae.initialTransform),lc(ae.clientRect,he,0))}),this._previousSwap.overlaps=j_(f,e,i),this._previousSwap.drag=c.drag,this._previousSwap.delta=a?r.x:r.y}_startScrollingIfNecessary(t,e){if(this.autoScrollDisabled)return;let i,r=0,s=0;if(this._parentPositions.positions.forEach((o,a)=>{a===this._document||!o.clientRect||i||uS(o.clientRect,.05,t,e)&&([r,s]=function qU(n,t,e,i){const r=DS(t,i),s=ES(t,e);let o=0,a=0;if(r){const l=n.scrollTop;1===r?l>0&&(o=1):n.scrollHeight-l>n.clientHeight&&(o=2)}if(s){const l=n.scrollLeft;1===s?l>0&&(a=1):n.scrollWidth-l>n.clientWidth&&(a=2)}return[o,a]}(a,o.clientRect,t,e),(r||s)&&(i=a))}),!r&&!s){const{width:o,height:a}=this._viewportRuler.getViewportSize(),l={width:o,height:a,top:0,right:o,bottom:a,left:0};r=DS(l,e),s=ES(l,t),i=window}i&&(r!==this._verticalScrollDirection||s!==this._horizontalScrollDirection||i!==this._scrollNode)&&(this._verticalScrollDirection=r,this._horizontalScrollDirection=s,this._scrollNode=i,(r||s)&&i?this._ngZone.runOutsideAngular(this._startScrollInterval):this._stopScrolling())}_stopScrolling(){this._stopScrollTimers.next()}_draggingStarted(){const t=Rn(this.element).style;this.beforeStarted.next(),this._isDragging=!0,this._initialScrollSnap=t.msScrollSnapType||t.scrollSnapType||"",t.scrollSnapType=t.msScrollSnapType="none",this._cacheItems(),this._viewportScrollSubscription.unsubscribe(),this._listenToScrollEvents()}_cacheParentPositions(){const t=Rn(this.element);this._parentPositions.cache(this._scrollableElements),this._clientRect=this._parentPositions.positions.get(t).clientRect}_cacheItemPositions(){const t="horizontal"===this._orientation;this._itemPositions=this._activeDraggables.map(e=>{const i=e.getVisibleElement();return{drag:e,offset:0,initialTransform:i.style.transform||"",clientRect:H_(i)}}).sort((e,i)=>t?e.clientRect.left-i.clientRect.left:e.clientRect.top-i.clientRect.top)}_reset(){this._isDragging=!1;const t=Rn(this.element).style;t.scrollSnapType=t.msScrollSnapType=this._initialScrollSnap,this._activeDraggables.forEach(e=>{var i;const r=e.getRootElement();if(r){const s=null===(i=this._itemPositions.find(o=>o.drag===e))||void 0===i?void 0:i.initialTransform;r.style.transform=s||""}}),this._siblings.forEach(e=>e._stopReceiving(this)),this._activeDraggables=[],this._itemPositions=[],this._previousSwap.drag=null,this._previousSwap.delta=0,this._previousSwap.overlaps=!1,this._stopScrolling(),this._viewportScrollSubscription.unsubscribe(),this._parentPositions.clear()}_getSiblingOffsetPx(t,e,i){const r="horizontal"===this._orientation,s=e[t].clientRect,o=e[t+-1*i];let a=s[r?"width":"height"]*i;if(o){const l=r?"left":"top",c=r?"right":"bottom";-1===i?a-=o.clientRect[l]-s[c]:a+=s[l]-o.clientRect[c]}return a}_getItemOffsetPx(t,e,i){const r="horizontal"===this._orientation;let s=r?e.left-t.left:e.top-t.top;return-1===i&&(s+=r?e.width-t.width:e.height-t.height),s}_shouldEnterAsFirstChild(t,e){if(!this._activeDraggables.length)return!1;const i=this._itemPositions,r="horizontal"===this._orientation;if(i[0].drag!==this._activeDraggables[0]){const o=i[i.length-1].clientRect;return r?t>=o.right:e>=o.bottom}{const o=i[0].clientRect;return r?t<=o.left:e<=o.top}}_getItemIndexFromPointerPosition(t,e,i,r){const s="horizontal"===this._orientation,o=this._itemPositions.findIndex(({drag:a,clientRect:l})=>{if(a===t)return!1;if(r){const c=s?r.x:r.y;if(a===this._previousSwap.drag&&this._previousSwap.overlaps&&c===this._previousSwap.delta)return!1}return s?e>=Math.floor(l.left)&&e=Math.floor(l.top)&&ir._canReceive(t,e,i))}_canReceive(t,e,i){if(!this._clientRect||!j_(this._clientRect,e,i)||!this.enterPredicate(t,this))return!1;const r=this._getShadowRoot().elementFromPoint(e,i);if(!r)return!1;const s=Rn(this.element);return r===s||s.contains(r)}_startReceiving(t,e){const i=this._activeSiblings;!i.has(t)&&e.every(r=>this.enterPredicate(r,this)||this._draggables.indexOf(r)>-1)&&(i.add(t),this._cacheParentPositions(),this._listenToScrollEvents())}_stopReceiving(t){this._activeSiblings.delete(t),this._viewportScrollSubscription.unsubscribe()}_listenToScrollEvents(){this._viewportScrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(t=>{if(this.isDragging()){const e=this._parentPositions.handleScroll(t);e&&(this._itemPositions.forEach(({clientRect:i})=>{lc(i,e.top,e.left)}),this._itemPositions.forEach(({drag:i})=>{this._dragDropRegistry.isDragging(i)&&i._sortFromLastPointerPosition()}))}else this.isReceiving()&&this._cacheParentPositions()})}_getShadowRoot(){if(!this._cachedShadowRoot){const t=ju(Rn(this.element));this._cachedShadowRoot=t||this._document}return this._cachedShadowRoot}_notifyReceivingSiblings(){const t=this._activeDraggables.filter(e=>e.isDragging());this._siblings.forEach(e=>e._startReceiving(this,t))}}function DS(n,t){const{top:e,bottom:i,height:r}=n,s=.05*r;return t>=e-s&&t<=e+s?1:t>=i-s&&t<=i+s?2:0}function ES(n,t){const{left:e,right:i,width:r}=n,s=.05*r;return t>=e-s&&t<=e+s?1:t>=i-s&&t<=i+s?2:0}const th=Ar({passive:!1,capture:!0});let YU=(()=>{class n{constructor(e,i){this._ngZone=e,this._dropInstances=new Set,this._dragInstances=new Set,this._activeDragInstances=[],this._globalListeners=new Map,this._draggingPredicate=r=>r.isDragging(),this.pointerMove=new ue,this.pointerUp=new ue,this.scroll=new ue,this._preventDefaultWhileDragging=r=>{this._activeDragInstances.length>0&&r.preventDefault()},this._persistentTouchmoveListener=r=>{this._activeDragInstances.length>0&&(this._activeDragInstances.some(this._draggingPredicate)&&r.preventDefault(),this.pointerMove.next(r))},this._document=i}registerDropContainer(e){this._dropInstances.has(e)||this._dropInstances.add(e)}registerDragItem(e){this._dragInstances.add(e),1===this._dragInstances.size&&this._ngZone.runOutsideAngular(()=>{this._document.addEventListener("touchmove",this._persistentTouchmoveListener,th)})}removeDropContainer(e){this._dropInstances.delete(e)}removeDragItem(e){this._dragInstances.delete(e),this.stopDragging(e),0===this._dragInstances.size&&this._document.removeEventListener("touchmove",this._persistentTouchmoveListener,th)}startDragging(e,i){if(!(this._activeDragInstances.indexOf(e)>-1)&&(this._activeDragInstances.push(e),1===this._activeDragInstances.length)){const r=i.type.startsWith("touch");this._globalListeners.set(r?"touchend":"mouseup",{handler:s=>this.pointerUp.next(s),options:!0}).set("scroll",{handler:s=>this.scroll.next(s),options:!0}).set("selectstart",{handler:this._preventDefaultWhileDragging,options:th}),r||this._globalListeners.set("mousemove",{handler:s=>this.pointerMove.next(s),options:th}),this._ngZone.runOutsideAngular(()=>{this._globalListeners.forEach((s,o)=>{this._document.addEventListener(o,s.handler,s.options)})})}}stopDragging(e){const i=this._activeDragInstances.indexOf(e);i>-1&&(this._activeDragInstances.splice(i,1),0===this._activeDragInstances.length&&this._clearGlobalListeners())}isDragging(e){return this._activeDragInstances.indexOf(e)>-1}scrolled(e){const i=[this.scroll];return e&&e!==this._document&&i.push(new J(r=>this._ngZone.runOutsideAngular(()=>{const o=a=>{this._activeDragInstances.length&&r.next(a)};return e.addEventListener("scroll",o,!0),()=>{e.removeEventListener("scroll",o,!0)}}))),$n(...i)}ngOnDestroy(){this._dragInstances.forEach(e=>this.removeDragItem(e)),this._dropInstances.forEach(e=>this.removeDropContainer(e)),this._clearGlobalListeners(),this.pointerMove.complete(),this.pointerUp.complete()}_clearGlobalListeners(){this._globalListeners.forEach((e,i)=>{this._document.removeEventListener(i,e.handler,e.options)}),this._globalListeners.clear()}}return n.\u0275fac=function(e){return new(e||n)(te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const KU={dragStartThreshold:5,pointerDirectionChangeThreshold:5};let QU=(()=>{class n{constructor(e,i,r,s){this._document=e,this._ngZone=i,this._viewportRuler=r,this._dragDropRegistry=s}createDrag(e,i=KU){return new $U(e,i,this._document,this._ngZone,this._viewportRuler,this._dragDropRegistry)}createDropList(e){return new WU(e,this._dragDropRegistry,this._document,this._ngZone,this._viewportRuler)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(et),te(ss),te(YU))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ZU=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[QU],imports:[Sa]}),n})();function nh(...n){return function XU(){return To(1)}()(gn(n,qa(n)))}function Qn(...n){const t=qa(n);return Pe((e,i)=>{(t?nh(n,e,t):nh(n,e)).subscribe(i)})}function JU(n,t){if(1&n&&kt(0,"mat-pseudo-checkbox",4),2&n){const e=lt();Ae("state",e.selected?"checked":"unchecked")("disabled",e.disabled)}}function ez(n,t){if(1&n&&(fe(0,"span",5),Ue(1),we()),2&n){const e=lt();Ee(1),Ln("(",e.group.label,")")}}const tz=["*"],sz=new De("mat-sanity-checks",{providedIn:"root",factory:function rz(){return!0}});let ht=(()=>{class n{constructor(e,i,r){this._sanityChecks=i,this._document=r,this._hasDoneGlobalChecks=!1,e._applyBodyHighContrastModeCssClasses(),this._hasDoneGlobalChecks||(this._hasDoneGlobalChecks=!0)}_checkIsEnabled(e){return!__()&&("boolean"==typeof this._sanityChecks?this._sanityChecks:!!this._sanityChecks[e])}}return n.\u0275fac=function(e){return new(e||n)(te(rS),te(sz,8),te(ct))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ac,ac]}),n})();function uc(n){return class extends n{constructor(...t){super(...t),this._disabled=!1}get disabled(){return this._disabled}set disabled(t){this._disabled=rt(t)}}}function vo(n,t){return class extends n{constructor(...e){super(...e),this.defaultColor=t,this.color=t}get color(){return this._color}set color(e){const i=e||this.defaultColor;i!==this._color&&(this._color&&this._elementRef.nativeElement.classList.remove(`mat-${this._color}`),i&&this._elementRef.nativeElement.classList.add(`mat-${i}`),this._color=i)}}}function Rs(n){return class extends n{constructor(...t){super(...t),this._disableRipple=!1}get disableRipple(){return this._disableRipple}set disableRipple(t){this._disableRipple=rt(t)}}}function yo(n,t=0){return class extends n{constructor(...e){super(...e),this._tabIndex=t,this.defaultTabIndex=t}get tabIndex(){return this.disabled?-1:this._tabIndex}set tabIndex(e){this._tabIndex=null!=e?Ii(e):this.defaultTabIndex}}}function SS(n){return class extends n{constructor(...t){super(...t),this.errorState=!1}updateErrorState(){const t=this.errorState,s=(this.errorStateMatcher||this._defaultErrorStateMatcher).isErrorState(this.ngControl?this.ngControl.control:null,this._parentFormGroup||this._parentForm);s!==t&&(this.errorState=s,this.stateChanges.next())}}}const oz=new De("MAT_DATE_LOCALE",{providedIn:"root",factory:function az(){return ld(Er)}});class Ir{constructor(){this._localeChanges=new ue,this.localeChanges=this._localeChanges}getValidDateOrNull(t){return this.isDateInstance(t)&&this.isValid(t)?t:null}deserialize(t){return null==t||this.isDateInstance(t)&&this.isValid(t)?t:this.invalid()}setLocale(t){this.locale=t,this._localeChanges.next()}compareDate(t,e){return this.getYear(t)-this.getYear(e)||this.getMonth(t)-this.getMonth(e)||this.getDate(t)-this.getDate(e)}sameDate(t,e){if(t&&e){let i=this.isValid(t),r=this.isValid(e);return i&&r?!this.compareDate(t,e):i==r}return t==e}clampDate(t,e,i){return e&&this.compareDate(t,e)<0?e:i&&this.compareDate(t,i)>0?i:t}}const z_=new De("mat-date-formats"),lz=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;function $_(n,t){const e=Array(n);for(let i=0;i{class n extends Ir{constructor(e,i){super(),this.useUtcForDisplay=!1,super.setLocale(e)}getYear(e){return e.getFullYear()}getMonth(e){return e.getMonth()}getDate(e){return e.getDate()}getDayOfWeek(e){return e.getDay()}getMonthNames(e){const i=new Intl.DateTimeFormat(this.locale,{month:e,timeZone:"utc"});return $_(12,r=>this._format(i,new Date(2017,r,1)))}getDateNames(){const e=new Intl.DateTimeFormat(this.locale,{day:"numeric",timeZone:"utc"});return $_(31,i=>this._format(e,new Date(2017,0,i+1)))}getDayOfWeekNames(e){const i=new Intl.DateTimeFormat(this.locale,{weekday:e,timeZone:"utc"});return $_(7,r=>this._format(i,new Date(2017,0,r+1)))}getYearName(e){const i=new Intl.DateTimeFormat(this.locale,{year:"numeric",timeZone:"utc"});return this._format(i,e)}getFirstDayOfWeek(){return 0}getNumDaysInMonth(e){return this.getDate(this._createDateWithOverflow(this.getYear(e),this.getMonth(e)+1,0))}clone(e){return new Date(e.getTime())}createDate(e,i,r){let s=this._createDateWithOverflow(e,i,r);return s.getMonth(),s}today(){return new Date}parse(e){return"number"==typeof e?new Date(e):e?new Date(Date.parse(e)):null}format(e,i){if(!this.isValid(e))throw Error("NativeDateAdapter: Cannot format invalid date.");const r=new Intl.DateTimeFormat(this.locale,Object.assign(Object.assign({},i),{timeZone:"utc"}));return this._format(r,e)}addCalendarYears(e,i){return this.addCalendarMonths(e,12*i)}addCalendarMonths(e,i){let r=this._createDateWithOverflow(this.getYear(e),this.getMonth(e)+i,this.getDate(e));return this.getMonth(r)!=((this.getMonth(e)+i)%12+12)%12&&(r=this._createDateWithOverflow(this.getYear(r),this.getMonth(r),0)),r}addCalendarDays(e,i){return this._createDateWithOverflow(this.getYear(e),this.getMonth(e),this.getDate(e)+i)}toIso8601(e){return[e.getUTCFullYear(),this._2digit(e.getUTCMonth()+1),this._2digit(e.getUTCDate())].join("-")}deserialize(e){if("string"==typeof e){if(!e)return null;if(lz.test(e)){let i=new Date(e);if(this.isValid(i))return i}}return super.deserialize(e)}isDateInstance(e){return e instanceof Date}isValid(e){return!isNaN(e.getTime())}invalid(){return new Date(NaN)}_createDateWithOverflow(e,i,r){const s=new Date;return s.setFullYear(e,i,r),s.setHours(0,0,0,0),s}_2digit(e){return("00"+e).slice(-2)}_format(e,i){const r=new Date;return r.setUTCFullYear(i.getFullYear(),i.getMonth(),i.getDate()),r.setUTCHours(i.getHours(),i.getMinutes(),i.getSeconds(),i.getMilliseconds()),e.format(r)}}return n.\u0275fac=function(e){return new(e||n)(te(oz,8),te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const dz={parse:{dateInput:null},display:{dateInput:{year:"numeric",month:"numeric",day:"numeric"},monthYearLabel:{year:"numeric",month:"short"},dateA11yLabel:{year:"numeric",month:"long",day:"numeric"},monthYearA11yLabel:{year:"numeric",month:"long"}}};let uz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[{provide:Ir,useClass:cz}]}),n})(),hz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[{provide:z_,useValue:dz}],imports:[uz]}),n})(),ih=(()=>{class n{isErrorState(e,i){return!!(e&&e.invalid&&(e.touched||i&&i.submitted))}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),kS=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["","mat-line",""],["","matLine",""]],hostAttrs:[1,"mat-line"]}),n})();function hc(n,t,e){n.nativeElement.classList.toggle(t,e)}let rh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})();class fz{constructor(t,e,i,r=!1){this._renderer=t,this.element=e,this.config=i,this._animationForciblyDisabledThroughCss=r,this.state=3}fadeOut(){this._renderer.fadeOutRipple(this)}}const AS={enterDuration:225,exitDuration:150},G_=Ar({passive:!0}),IS=["mousedown","touchstart"],RS=["mouseup","mouseleave","touchend","touchcancel"];class W_{constructor(t,e,i,r){this._target=t,this._ngZone=e,this._isPointerDown=!1,this._activeRipples=new Map,this._pointerUpEventsRegistered=!1,r.isBrowser&&(this._containerElement=Rn(i))}fadeInRipple(t,e,i={}){const r=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),s=Object.assign(Object.assign({},AS),i.animation);i.centered&&(t=r.left+r.width/2,e=r.top+r.height/2);const o=i.radius||function mz(n,t,e){const i=Math.max(Math.abs(n-e.left),Math.abs(n-e.right)),r=Math.max(Math.abs(t-e.top),Math.abs(t-e.bottom));return Math.sqrt(i*i+r*r)}(t,e,r),a=t-r.left,l=e-r.top,c=s.enterDuration,d=document.createElement("div");d.classList.add("mat-ripple-element"),d.style.left=a-o+"px",d.style.top=l-o+"px",d.style.height=2*o+"px",d.style.width=2*o+"px",null!=i.color&&(d.style.backgroundColor=i.color),d.style.transitionDuration=`${c}ms`,this._containerElement.appendChild(d);const f=window.getComputedStyle(d),k=f.transitionDuration,j="none"===f.transitionProperty||"0s"===k||"0s, 0s"===k,K=new fz(this,d,i,j);d.style.transform="scale3d(1, 1, 1)",K.state=0,i.persistent||(this._mostRecentTransientRipple=K);let ae=null;return!j&&(c||s.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const ce=()=>this._finishRippleTransition(K),Te=()=>this._destroyRipple(K);d.addEventListener("transitionend",ce),d.addEventListener("transitioncancel",Te),ae={onTransitionEnd:ce,onTransitionCancel:Te}}),this._activeRipples.set(K,ae),(j||!c)&&this._finishRippleTransition(K),K}fadeOutRipple(t){if(2===t.state||3===t.state)return;const e=t.element,i=Object.assign(Object.assign({},AS),t.config.animation);e.style.transitionDuration=`${i.exitDuration}ms`,e.style.opacity="0",t.state=2,(t._animationForciblyDisabledThroughCss||!i.exitDuration)&&this._finishRippleTransition(t)}fadeOutAll(){this._getActiveRipples().forEach(t=>t.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(t=>{t.config.persistent||t.fadeOut()})}setupTriggerEvents(t){const e=Rn(t);!e||e===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=e,this._registerEvents(IS))}handleEvent(t){"mousedown"===t.type?this._onMousedown(t):"touchstart"===t.type?this._onTouchStart(t):this._onPointerUp(),this._pointerUpEventsRegistered||(this._registerEvents(RS),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(t){0===t.state?this._startFadeOutTransition(t):2===t.state&&this._destroyRipple(t)}_startFadeOutTransition(t){const e=t===this._mostRecentTransientRipple,{persistent:i}=t.config;t.state=1,!i&&(!e||!this._isPointerDown)&&t.fadeOut()}_destroyRipple(t){var e;const i=null!==(e=this._activeRipples.get(t))&&void 0!==e?e:null;this._activeRipples.delete(t),this._activeRipples.size||(this._containerRect=null),t===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),t.state=3,null!==i&&(t.element.removeEventListener("transitionend",i.onTransitionEnd),t.element.removeEventListener("transitioncancel",i.onTransitionCancel)),t.element.remove()}_onMousedown(t){const e=I_(t),i=this._lastTouchStartEvent&&Date.now(){!t.config.persistent&&(1===t.state||t.config.terminateOnPointerUp&&0===t.state)&&t.fadeOut()}))}_registerEvents(t){this._ngZone.runOutsideAngular(()=>{t.forEach(e=>{this._triggerElement.addEventListener(e,this,G_)})})}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){this._triggerElement&&(IS.forEach(t=>{this._triggerElement.removeEventListener(t,this,G_)}),this._pointerUpEventsRegistered&&RS.forEach(t=>{this._triggerElement.removeEventListener(t,this,G_)}))}}const sh=new De("mat-ripple-global-options");let Ps=(()=>{class n{constructor(e,i,r,s,o){this._elementRef=e,this._animationMode=o,this.radius=0,this._disabled=!1,this._isInitialized=!1,this._globalOptions=s||{},this._rippleRenderer=new W_(this,i,e,r)}get disabled(){return this._disabled}set disabled(e){e&&this.fadeOutAllNonPersistent(),this._disabled=e,this._setupTriggerEventsIfEnabled()}get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(e){this._trigger=e,this._setupTriggerEventsIfEnabled()}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:Object.assign(Object.assign(Object.assign({},this._globalOptions.animation),"NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(e,i=0,r){return"number"==typeof e?this._rippleRenderer.fadeInRipple(e,i,Object.assign(Object.assign({},this.rippleConfig),r)):this._rippleRenderer.fadeInRipple(0,0,Object.assign(Object.assign({},this.rippleConfig),e))}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(bn),x(sh,8),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(e,i){2&e&&At("mat-ripple-unbounded",i.unbounded)},inputs:{color:["matRippleColor","color"],unbounded:["matRippleUnbounded","unbounded"],centered:["matRippleCentered","centered"],radius:["matRippleRadius","radius"],animation:["matRippleAnimation","animation"],disabled:["matRippleDisabled","disabled"],trigger:["matRippleTrigger","trigger"]},exportAs:["matRipple"]}),n})(),Ta=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),PS=(()=>{class n{constructor(e){this._animationMode=e,this.state="unchecked",this.disabled=!1}}return n.\u0275fac=function(e){return new(e||n)(x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:8,hostBindings:function(e,i){2&e&&At("mat-pseudo-checkbox-indeterminate","indeterminate"===i.state)("mat-pseudo-checkbox-checked","checked"===i.state)("mat-pseudo-checkbox-disabled",i.disabled)("_mat-animation-noopable","NoopAnimations"===i._animationMode)},inputs:{state:"state",disabled:"disabled"},decls:0,vars:0,template:function(e,i){},styles:['.mat-pseudo-checkbox{width:16px;height:16px;border:2px solid;border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox.mat-pseudo-checkbox-indeterminate{border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{top:5px;left:1px;width:10px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{top:2.4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}'],encapsulation:2,changeDetection:0}),n})(),q_=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht]}),n})();const OS=new De("MAT_OPTION_PARENT_COMPONENT"),FS=new De("MatOptgroup");let gz=0;class _z{constructor(t,e=!1){this.source=t,this.isUserInput=e}}let vz=(()=>{class n{constructor(e,i,r,s){this._element=e,this._changeDetectorRef=i,this._parent=r,this.group=s,this._selected=!1,this._active=!1,this._disabled=!1,this._mostRecentViewValue="",this.id="mat-option-"+gz++,this.onSelectionChange=new je,this._stateChanges=new ue}get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(e){this._disabled=rt(e)}get disableRipple(){return!(!this._parent||!this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._getHostElement().textContent||"").trim()}select(){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}deselect(){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}focus(e,i){const r=this._getHostElement();"function"==typeof r.focus&&r.focus(i)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(e){(13===e.keyCode||32===e.keyCode)&&!gi(e)&&(this._selectViaInteraction(),e.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getAriaSelected(){return this.selected||!this.multiple&&null}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const e=this.viewValue;e!==this._mostRecentViewValue&&(this._mostRecentViewValue=e,this._stateChanges.next())}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(e=!1){this.onSelectionChange.emit(new _z(this,e))}}return n.\u0275fac=function(e){bs()},n.\u0275dir=Me({type:n,inputs:{value:"value",id:"id",disabled:"disabled"},outputs:{onSelectionChange:"onSelectionChange"}}),n})(),Y_=(()=>{class n extends vz{constructor(e,i,r,s){super(e,i,r,s)}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(OS,8),x(FS,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-option"]],hostAttrs:["role","option",1,"mat-option","mat-focus-indicator"],hostVars:12,hostBindings:function(e,i){1&e&&$e("click",function(){return i._selectViaInteraction()})("keydown",function(s){return i._handleKeydown(s)}),2&e&&(Zr("id",i.id),wt("tabindex",i._getTabIndex())("aria-selected",i._getAriaSelected())("aria-disabled",i.disabled.toString()),At("mat-selected",i.selected)("mat-option-multiple",i.multiple)("mat-active",i.active)("mat-option-disabled",i.disabled))},exportAs:["matOption"],features:[Le],ngContentSelectors:tz,decls:5,vars:4,consts:[["class","mat-option-pseudo-checkbox",3,"state","disabled",4,"ngIf"],[1,"mat-option-text"],["class","cdk-visually-hidden",4,"ngIf"],["mat-ripple","",1,"mat-option-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-option-pseudo-checkbox",3,"state","disabled"],[1,"cdk-visually-hidden"]],template:function(e,i){1&e&&(Fn(),it(0,JU,1,2,"mat-pseudo-checkbox",0),fe(1,"span",1),Tt(2),we(),it(3,ez,2,1,"span",2),kt(4,"div",3)),2&e&&(Ae("ngIf",i.multiple),Ee(3),Ae("ngIf",i.group&&i.group._inert),Ee(1),Ae("matRippleTrigger",i._getHostElement())("matRippleDisabled",i.disabled||i.disableRipple))},dependencies:[Ps,zi,PS],styles:[".mat-option{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative;cursor:pointer;outline:none;display:flex;flex-direction:row;max-width:100%;box-sizing:border-box;align-items:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-option[disabled]{cursor:default}[dir=rtl] .mat-option{text-align:right}.mat-option .mat-icon{margin-right:16px;vertical-align:middle}.mat-option .mat-icon svg{vertical-align:top}[dir=rtl] .mat-option .mat-icon{margin-left:16px;margin-right:0}.mat-option[aria-disabled=true]{-webkit-user-select:none;user-select:none;cursor:default}.mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:32px}[dir=rtl] .mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:16px;padding-right:32px}.cdk-high-contrast-active .mat-option{margin:0 1px}.cdk-high-contrast-active .mat-option.mat-active{border:solid 1px currentColor;margin:0}.cdk-high-contrast-active .mat-option[aria-disabled=true]{opacity:.5}.mat-option-text{display:inline-block;flex-grow:1;overflow:hidden;text-overflow:ellipsis}.mat-option .mat-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-option-pseudo-checkbox{margin-right:8px}[dir=rtl] .mat-option-pseudo-checkbox{margin-left:8px;margin-right:0}"],encapsulation:2,changeDetection:0}),n})();function LS(n,t,e){if(e.length){let i=t.toArray(),r=e.toArray(),s=0;for(let o=0;o{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,pi,ht,q_]}),n})();const bz=["mat-button",""],wz=["*"],Dz=["mat-button","mat-flat-button","mat-icon-button","mat-raised-button","mat-stroked-button","mat-mini-fab","mat-fab"],Ez=vo(uc(Rs(class{constructor(n){this._elementRef=n}})));let Aa=(()=>{class n extends Ez{constructor(e,i,r){super(e),this._focusMonitor=i,this._animationMode=r,this.isRoundButton=this._hasHostAttributes("mat-fab","mat-mini-fab"),this.isIconButton=this._hasHostAttributes("mat-icon-button");for(const s of Dz)this._hasHostAttributes(s)&&this._getHostElement().classList.add(s);e.nativeElement.classList.add("mat-button-base"),this.isRoundButton&&(this.color="accent")}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}focus(e,i){e?this._focusMonitor.focusVia(this._getHostElement(),e,i):this._getHostElement().focus(i)}_getHostElement(){return this._elementRef.nativeElement}_isRippleDisabled(){return this.disableRipple||this.disabled}_hasHostAttributes(...e){return e.some(i=>this._getHostElement().hasAttribute(i))}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(hr),x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-icon-button",""],["button","mat-fab",""],["button","mat-mini-fab",""],["button","mat-stroked-button",""],["button","mat-flat-button",""]],viewQuery:function(e,i){if(1&e&&Gt(Ps,5),2&e){let r;Ge(r=We())&&(i.ripple=r.first)}},hostAttrs:[1,"mat-focus-indicator"],hostVars:5,hostBindings:function(e,i){2&e&&(wt("disabled",i.disabled||null),At("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-button-disabled",i.disabled))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Le],attrs:bz,ngContentSelectors:wz,decls:4,vars:5,consts:[[1,"mat-button-wrapper"],["matRipple","",1,"mat-button-ripple",3,"matRippleDisabled","matRippleCentered","matRippleTrigger"],[1,"mat-button-focus-overlay"]],template:function(e,i){1&e&&(Fn(),fe(0,"span",0),Tt(1),we(),kt(2,"span",1)(3,"span",2)),2&e&&(Ee(2),At("mat-button-ripple-round",i.isRoundButton||i.isIconButton),Ae("matRippleDisabled",i._isRippleDisabled())("matRippleCentered",i.isIconButton)("matRippleTrigger",i._getHostElement()))},dependencies:[Ps],styles:[".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay,.mat-stroked-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay,.mat-stroked-button:hover:not(.mat-button-disabled) .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button.mat-button-disabled,.mat-icon-button.mat-button-disabled,.mat-stroked-button.mat-button-disabled,.mat-flat-button.mat-button-disabled{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button.mat-button-disabled{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab.mat-button-disabled{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}.mat-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0);display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab.mat-button-disabled{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:inline-flex;justify-content:center;align-items:center;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}.cdk-high-contrast-active .mat-button-base.cdk-keyboard-focused,.cdk-high-contrast-active .mat-button-base.cdk-program-focused{outline:solid 3px}"],encapsulation:2,changeDetection:0}),n})(),oh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,ht]}),n})();const Mz=["*",[["mat-card-footer"]]],xz=["*","mat-card-footer"];let Sz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-card-content"],["","mat-card-content",""],["","matCardContent",""]],hostAttrs:[1,"mat-card-content"]}),n})(),kz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-card-title"],["","mat-card-title",""],["","matCardTitle",""]],hostAttrs:[1,"mat-card-title"]}),n})(),Tz=(()=>{class n{constructor(e){this._animationMode=e}}return n.\u0275fac=function(e){return new(e||n)(x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-card"]],hostAttrs:[1,"mat-card","mat-focus-indicator"],hostVars:2,hostBindings:function(e,i){2&e&&At("_mat-animation-noopable","NoopAnimations"===i._animationMode)},exportAs:["matCard"],ngContentSelectors:xz,decls:2,vars:0,template:function(e,i){1&e&&(Fn(Mz),Tt(0),Tt(1,1))},styles:[".mat-card{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:block;position:relative;padding:16px;border-radius:4px}.mat-card._mat-animation-noopable{transition:none !important;animation:none !important}.mat-card>.mat-divider-horizontal{position:absolute;left:0;width:100%}[dir=rtl] .mat-card>.mat-divider-horizontal{left:auto;right:0}.mat-card>.mat-divider-horizontal.mat-divider-inset{position:static;margin:0}[dir=rtl] .mat-card>.mat-divider-horizontal.mat-divider-inset{margin-right:0}.cdk-high-contrast-active .mat-card{outline:solid 1px}.mat-card-actions,.mat-card-subtitle,.mat-card-content{display:block;margin-bottom:16px}.mat-card-title{display:block;margin-bottom:8px}.mat-card-actions{margin-left:-8px;margin-right:-8px;padding:8px 0}.mat-card-actions-align-end{display:flex;justify-content:flex-end}.mat-card-image{width:calc(100% + 32px);margin:0 -16px 16px -16px;display:block;overflow:hidden}.mat-card-image img{width:100%}.mat-card-footer{display:block;margin:0 -16px -16px -16px}.mat-card-actions .mat-button,.mat-card-actions .mat-raised-button,.mat-card-actions .mat-stroked-button{margin:0 8px}.mat-card-header{display:flex;flex-direction:row}.mat-card-header .mat-card-title{margin-bottom:12px}.mat-card-header-text{margin:0 16px}.mat-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;object-fit:cover}.mat-card-title-group{display:flex;justify-content:space-between}.mat-card-sm-image{width:80px;height:80px}.mat-card-md-image{width:112px;height:112px}.mat-card-lg-image{width:152px;height:152px}.mat-card-xl-image{width:240px;height:240px;margin:-8px}.mat-card-title-group>.mat-card-xl-image{margin:-8px 0 8px}@media(max-width: 599px){.mat-card-title-group{margin:0}.mat-card-xl-image{margin-left:0;margin-right:0}}.mat-card>:first-child,.mat-card-content>:first-child{margin-top:0}.mat-card>:last-child:not(.mat-card-footer),.mat-card-content>:last-child:not(.mat-card-footer){margin-bottom:0}.mat-card-image:first-child{margin-top:-16px;border-top-left-radius:inherit;border-top-right-radius:inherit}.mat-card>.mat-card-actions:last-child{margin-bottom:-8px;padding-bottom:0}.mat-card-actions:not(.mat-card-actions-align-end) .mat-button:first-child,.mat-card-actions:not(.mat-card-actions-align-end) .mat-raised-button:first-child,.mat-card-actions:not(.mat-card-actions-align-end) .mat-stroked-button:first-child{margin-left:0;margin-right:0}.mat-card-actions-align-end .mat-button:last-child,.mat-card-actions-align-end .mat-raised-button:last-child,.mat-card-actions-align-end .mat-stroked-button:last-child{margin-left:0;margin-right:0}.mat-card-title:not(:first-child),.mat-card-subtitle:not(:first-child){margin-top:-4px}.mat-card-header .mat-card-subtitle:not(:first-child){margin-top:-8px}.mat-card>.mat-card-xl-image:first-child{margin-top:-8px}.mat-card>.mat-card-xl-image:last-child{margin-bottom:-8px}"],encapsulation:2,changeDetection:0}),n})(),Az=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),HS=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),zz=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,Gu,HS,ht,HS]}),n})();class ah{constructor(t=!1,e,i=!0){this._multiple=t,this._emitChanges=i,this._selection=new Set,this._deselectedToEmit=[],this._selectedToEmit=[],this.changed=new ue,e&&e.length&&(t?e.forEach(r=>this._markSelected(r)):this._markSelected(e[0]),this._selectedToEmit.length=0)}get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}select(...t){this._verifyValueAssignment(t),t.forEach(e=>this._markSelected(e)),this._emitChangeEvent()}deselect(...t){this._verifyValueAssignment(t),t.forEach(e=>this._unmarkSelected(e)),this._emitChangeEvent()}toggle(t){this.isSelected(t)?this.deselect(t):this.select(t)}clear(){this._unmarkAll(),this._emitChangeEvent()}isSelected(t){return this._selection.has(t)}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(t){this._multiple&&this.selected&&this._selected.sort(t)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(t){this.isSelected(t)||(this._multiple||this._unmarkAll(),this._selection.add(t),this._emitChanges&&this._selectedToEmit.push(t))}_unmarkSelected(t){this.isSelected(t)&&(this._selection.delete(t),this._emitChanges&&this._deselectedToEmit.push(t))}_unmarkAll(){this.isEmpty()||this._selection.forEach(t=>this._unmarkSelected(t))}_verifyValueAssignment(t){}}let Q_=(()=>{class n{constructor(){this._listeners=[]}notify(e,i){for(let r of this._listeners)r(e,i)}listen(e){return this._listeners.push(e),()=>{this._listeners=this._listeners.filter(i=>e!==i)}}ngOnDestroy(){this._listeners=[]}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const $z=["connectionContainer"],Gz=["inputContainer"],Wz=["label"];function qz(n,t){1&n&&(eo(0),fe(1,"div",14),kt(2,"div",15)(3,"div",16)(4,"div",17),we(),fe(5,"div",18),kt(6,"div",15)(7,"div",16)(8,"div",17),we(),to())}function Yz(n,t){if(1&n){const e=ki();fe(0,"div",19),$e("cdkObserveContent",function(){return Bn(e),Vn(lt().updateOutlineGap())}),Tt(1,1),we()}2&n&&Ae("cdkObserveContentDisabled","outline"!=lt().appearance)}function Kz(n,t){if(1&n&&(eo(0),Tt(1,2),fe(2,"span"),Ue(3),we(),to()),2&n){const e=lt(2);Ee(3),Kn(e._control.placeholder)}}function Qz(n,t){1&n&&Tt(0,3,["*ngSwitchCase","true"])}function Zz(n,t){1&n&&(fe(0,"span",23),Ue(1," *"),we())}function Xz(n,t){if(1&n){const e=ki();fe(0,"label",20,21),$e("cdkObserveContent",function(){return Bn(e),Vn(lt().updateOutlineGap())}),it(2,Kz,4,1,"ng-container",12),it(3,Qz,1,0,"ng-content",12),it(4,Zz,2,0,"span",22),we()}if(2&n){const e=lt();At("mat-empty",e._control.empty&&!e._shouldAlwaysFloat())("mat-form-field-empty",e._control.empty&&!e._shouldAlwaysFloat())("mat-accent","accent"==e.color)("mat-warn","warn"==e.color),Ae("cdkObserveContentDisabled","outline"!=e.appearance)("id",e._labelId)("ngSwitch",e._hasLabel()),wt("for",e._control.id)("aria-owns",e._control.id),Ee(2),Ae("ngSwitchCase",!1),Ee(1),Ae("ngSwitchCase",!0),Ee(1),Ae("ngIf",!e.hideRequiredMarker&&e._control.required&&!e._control.disabled)}}function Jz(n,t){1&n&&(fe(0,"div",24),Tt(1,4),we())}function e8(n,t){if(1&n&&(fe(0,"div",25),kt(1,"span",26),we()),2&n){const e=lt();Ee(1),At("mat-accent","accent"==e.color)("mat-warn","warn"==e.color)}}function t8(n,t){1&n&&(fe(0,"div"),Tt(1,5),we()),2&n&&Ae("@transitionMessages",lt()._subscriptAnimationState)}function n8(n,t){if(1&n&&(fe(0,"div",30),Ue(1),we()),2&n){const e=lt(2);Ae("id",e._hintLabelId),Ee(1),Kn(e.hintLabel)}}function i8(n,t){if(1&n&&(fe(0,"div",27),it(1,n8,2,2,"div",28),Tt(2,6),kt(3,"div",29),Tt(4,7),we()),2&n){const e=lt();Ae("@transitionMessages",e._subscriptAnimationState),Ee(1),Ae("ngIf",e.hintLabel)}}const r8=["*",[["","matPrefix",""]],[["mat-placeholder"]],[["mat-label"]],[["","matSuffix",""]],[["mat-error"]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],s8=["*","[matPrefix]","mat-placeholder","mat-label","[matSuffix]","mat-error","mat-hint:not([align='end'])","mat-hint[align='end']"],o8=new De("MatError"),a8={transitionMessages:jn("transitionMessages",[zt("enter",Qe({opacity:1,transform:"translateY(0%)"})),Wt("void => enter",[Qe({opacity:0,transform:"translateY(-5px)"}),Zt("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let lh=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n}),n})();const l8=new De("MatHint");let ch=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-label"]]}),n})(),c8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-placeholder"]]}),n})();const d8=new De("MatPrefix"),u8=new De("MatSuffix");let zS=0;const f8=vo(class{constructor(n){this._elementRef=n}},"primary"),p8=new De("MAT_FORM_FIELD_DEFAULT_OPTIONS"),Z_=new De("MatFormField");let GS=(()=>{class n extends f8{constructor(e,i,r,s,o,a,l){super(e),this._changeDetectorRef=i,this._dir=r,this._defaults=s,this._platform=o,this._ngZone=a,this._outlineGapCalculationNeededImmediately=!1,this._outlineGapCalculationNeededOnStable=!1,this._destroyed=new ue,this._hideRequiredMarker=!1,this._showAlwaysAnimate=!1,this._subscriptAnimationState="",this._hintLabel="",this._hintLabelId="mat-hint-"+zS++,this._labelId="mat-form-field-label-"+zS++,this.floatLabel=this._getDefaultFloatLabelState(),this._animationsEnabled="NoopAnimations"!==l,this.appearance=(null==s?void 0:s.appearance)||"legacy",s&&(this._hideRequiredMarker=Boolean(s.hideRequiredMarker),s.color&&(this.color=this.defaultColor=s.color))}get appearance(){return this._appearance}set appearance(e){var i;const r=this._appearance;this._appearance=e||(null===(i=this._defaults)||void 0===i?void 0:i.appearance)||"legacy","outline"===this._appearance&&r!==e&&(this._outlineGapCalculationNeededOnStable=!0)}get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(e){this._hideRequiredMarker=rt(e)}_shouldAlwaysFloat(){return"always"===this.floatLabel&&!this._showAlwaysAnimate}_canLabelFloat(){return"never"!==this.floatLabel}get hintLabel(){return this._hintLabel}set hintLabel(e){this._hintLabel=e,this._processHints()}get floatLabel(){return"legacy"!==this.appearance&&"never"===this._floatLabel?"auto":this._floatLabel}set floatLabel(e){e!==this._floatLabel&&(this._floatLabel=e||this._getDefaultFloatLabelState(),this._changeDetectorRef.markForCheck())}get _control(){return this._explicitFormFieldControl||this._controlNonStatic||this._controlStatic}set _control(e){this._explicitFormFieldControl=e}getLabelId(){return this._hasFloatingLabel()?this._labelId:null}getConnectedOverlayOrigin(){return this._connectionContainerRef||this._elementRef}ngAfterContentInit(){this._validateControlChild();const e=this._control;e.controlType&&this._elementRef.nativeElement.classList.add(`mat-form-field-type-${e.controlType}`),e.stateChanges.pipe(Qn(null)).subscribe(()=>{this._validatePlaceholders(),this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),e.ngControl&&e.ngControl.valueChanges&&e.ngControl.valueChanges.pipe(Ot(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.pipe(Ot(this._destroyed)).subscribe(()=>{this._outlineGapCalculationNeededOnStable&&this.updateOutlineGap()})}),$n(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._outlineGapCalculationNeededOnStable=!0,this._changeDetectorRef.markForCheck()}),this._hintChildren.changes.pipe(Qn(null)).subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.pipe(Qn(null)).subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._dir&&this._dir.change.pipe(Ot(this._destroyed)).subscribe(()=>{"function"==typeof requestAnimationFrame?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this.updateOutlineGap())}):this.updateOutlineGap()})}ngAfterContentChecked(){this._validateControlChild(),this._outlineGapCalculationNeededImmediately&&this.updateOutlineGap()}ngAfterViewInit(){this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete()}_shouldForward(e){const i=this._control?this._control.ngControl:null;return i&&i[e]}_hasPlaceholder(){return!!(this._control&&this._control.placeholder||this._placeholderChild)}_hasLabel(){return!(!this._labelChildNonStatic&&!this._labelChildStatic)}_shouldLabelFloat(){return this._canLabelFloat()&&(this._control&&this._control.shouldLabelFloat||this._shouldAlwaysFloat())}_hideControlPlaceholder(){return"legacy"===this.appearance&&!this._hasLabel()||this._hasLabel()&&!this._shouldLabelFloat()}_hasFloatingLabel(){return this._hasLabel()||"legacy"===this.appearance&&this._hasPlaceholder()}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_animateAndLockLabel(){this._hasFloatingLabel()&&this._canLabelFloat()&&(this._animationsEnabled&&this._label&&(this._showAlwaysAnimate=!0,_o(this._label.nativeElement,"transitionend").pipe(sn(1)).subscribe(()=>{this._showAlwaysAnimate=!1})),this.floatLabel="always",this._changeDetectorRef.markForCheck())}_validatePlaceholders(){}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_getDefaultFloatLabelState(){return this._defaults&&this._defaults.floatLabel||"auto"}_syncDescribedByIds(){if(this._control){let e=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&e.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const i=this._hintChildren?this._hintChildren.find(s=>"start"===s.align):null,r=this._hintChildren?this._hintChildren.find(s=>"end"===s.align):null;i?e.push(i.id):this._hintLabel&&e.push(this._hintLabelId),r&&e.push(r.id)}else this._errorChildren&&e.push(...this._errorChildren.map(i=>i.id));this._control.setDescribedByIds(e)}}_validateControlChild(){}updateOutlineGap(){const e=this._label?this._label.nativeElement:null,i=this._connectionContainerRef.nativeElement,r=".mat-form-field-outline-start",s=".mat-form-field-outline-gap";if("outline"!==this.appearance||!this._platform.isBrowser)return;if(!e||!e.children.length||!e.textContent.trim()){const d=i.querySelectorAll(`${r}, ${s}`);for(let f=0;f0?.75*j+10:0}for(let d=0;d{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,Gu,ht]}),n})();const m8=["*"],WS=new De("MatChipRemove"),qS=new De("MatChipAvatar"),YS=new De("MatChipTrailingIcon");class g8{constructor(t){this._elementRef=t}}const _8=yo(vo(Rs(g8),"primary"),-1);let Ia=(()=>{class n extends _8{constructor(e,i,r,s,o,a,l,c){super(e),this._ngZone=i,this._changeDetectorRef=o,this._hasFocus=!1,this.chipListSelectable=!0,this._chipListMultiple=!1,this._chipListDisabled=!1,this.role="option",this._selected=!1,this._selectable=!0,this._disabled=!1,this._removable=!0,this._onFocus=new ue,this._onBlur=new ue,this.selectionChange=new je,this.destroyed=new je,this.removed=new je,this._addHostClassName(),this._chipRippleTarget=a.createElement("div"),this._chipRippleTarget.classList.add("mat-chip-ripple"),this._elementRef.nativeElement.appendChild(this._chipRippleTarget),this._chipRipple=new W_(this,i,this._chipRippleTarget,r),this._chipRipple.setupTriggerEvents(e),this.rippleConfig=s||{},this._animationsDisabled="NoopAnimations"===l,this.tabIndex=null!=c&&parseInt(c)||-1}get rippleDisabled(){return this.disabled||this.disableRipple||this._animationsDisabled||!!this.rippleConfig.disabled}get selected(){return this._selected}set selected(e){const i=rt(e);i!==this._selected&&(this._selected=i,this._dispatchSelectionChange())}get value(){return void 0!==this._value?this._value:this._elementRef.nativeElement.textContent}set value(e){this._value=e}get selectable(){return this._selectable&&this.chipListSelectable}set selectable(e){this._selectable=rt(e)}get disabled(){return this._chipListDisabled||this._disabled}set disabled(e){this._disabled=rt(e)}get removable(){return this._removable}set removable(e){this._removable=rt(e)}get ariaSelected(){return this.selectable&&(this._chipListMultiple||this.selected)?this.selected.toString():null}_addHostClassName(){const e="mat-basic-chip",i=this._elementRef.nativeElement;i.hasAttribute(e)||i.tagName.toLowerCase()===e?i.classList.add(e):i.classList.add("mat-standard-chip")}ngOnDestroy(){this.destroyed.emit({chip:this}),this._chipRipple._removeTriggerEvents()}select(){this._selected||(this._selected=!0,this._dispatchSelectionChange(),this._changeDetectorRef.markForCheck())}deselect(){this._selected&&(this._selected=!1,this._dispatchSelectionChange(),this._changeDetectorRef.markForCheck())}selectViaInteraction(){this._selected||(this._selected=!0,this._dispatchSelectionChange(!0),this._changeDetectorRef.markForCheck())}toggleSelected(e=!1){return this._selected=!this.selected,this._dispatchSelectionChange(e),this._changeDetectorRef.markForCheck(),this.selected}focus(){this._hasFocus||(this._elementRef.nativeElement.focus(),this._onFocus.next({chip:this})),this._hasFocus=!0}remove(){this.removable&&this.removed.emit({chip:this})}_handleClick(e){this.disabled&&e.preventDefault()}_handleKeydown(e){if(!this.disabled)switch(e.keyCode){case 46:case 8:this.remove(),e.preventDefault();break;case 32:this.selectable&&this.toggleSelected(!0),e.preventDefault()}}_blur(){this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this._ngZone.run(()=>{this._hasFocus=!1,this._onBlur.next({chip:this})})})}_dispatchSelectionChange(e=!1){this.selectionChange.emit({source:this,isUserInput:e,selected:this._selected})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(bn),x(sh,8),x(en),x(ct),x(fn,8),ii("tabindex"))},n.\u0275dir=Me({type:n,selectors:[["mat-basic-chip"],["","mat-basic-chip",""],["mat-chip"],["","mat-chip",""]],contentQueries:function(e,i,r){if(1&e&&(It(r,qS,5),It(r,YS,5),It(r,WS,5)),2&e){let s;Ge(s=We())&&(i.avatar=s.first),Ge(s=We())&&(i.trailingIcon=s.first),Ge(s=We())&&(i.removeIcon=s.first)}},hostAttrs:[1,"mat-chip","mat-focus-indicator"],hostVars:15,hostBindings:function(e,i){1&e&&$e("click",function(s){return i._handleClick(s)})("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i.focus()})("blur",function(){return i._blur()}),2&e&&(wt("tabindex",i.disabled?null:i.tabIndex)("role",i.role)("disabled",i.disabled||null)("aria-disabled",i.disabled.toString())("aria-selected",i.ariaSelected),At("mat-chip-selected",i.selected)("mat-chip-with-avatar",i.avatar)("mat-chip-with-trailing-icon",i.trailingIcon||i.removeIcon)("mat-chip-disabled",i.disabled)("_mat-animation-noopable",i._animationsDisabled))},inputs:{color:"color",disableRipple:"disableRipple",tabIndex:"tabIndex",role:"role",selected:"selected",value:"value",selectable:"selectable",disabled:"disabled",removable:"removable"},outputs:{selectionChange:"selectionChange",destroyed:"destroyed",removed:"removed"},exportAs:["matChip"],features:[Le]}),n})();const KS=new De("mat-chips-default-options"),D8=SS(class{constructor(n,t,e,i){this._defaultErrorStateMatcher=n,this._parentForm=t,this._parentFormGroup=e,this.ngControl=i,this.stateChanges=new ue}});let E8=0;class M8{constructor(t,e){this.source=t,this.value=e}}let uh=(()=>{class n extends D8{constructor(e,i,r,s,o,a,l){super(a,s,o,l),this._elementRef=e,this._changeDetectorRef=i,this._dir=r,this.controlType="mat-chip-list",this._lastDestroyedChipIndex=null,this._destroyed=new ue,this._uid="mat-chip-list-"+E8++,this._tabIndex=0,this._userTabIndex=null,this._onTouched=()=>{},this._onChange=()=>{},this._multiple=!1,this._compareWith=(c,d)=>c===d,this._disabled=!1,this.ariaOrientation="horizontal",this._selectable=!0,this.change=new je,this.valueChange=new je,this.ngControl&&(this.ngControl.valueAccessor=this)}get selected(){var e,i;return this.multiple?(null===(e=this._selectionModel)||void 0===e?void 0:e.selected)||[]:null===(i=this._selectionModel)||void 0===i?void 0:i.selected[0]}get role(){return this._explicitRole?this._explicitRole:this.empty?null:"listbox"}set role(e){this._explicitRole=e}get multiple(){return this._multiple}set multiple(e){this._multiple=rt(e),this._syncChipsState()}get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this.writeValue(e),this._value=e}get id(){return this._chipInput?this._chipInput.id:this._uid}get required(){var e,i,r,s;return null!==(s=null!==(e=this._required)&&void 0!==e?e:null===(r=null===(i=this.ngControl)||void 0===i?void 0:i.control)||void 0===r?void 0:r.hasValidator(Vg.required))&&void 0!==s&&s}set required(e){this._required=rt(e),this.stateChanges.next()}get placeholder(){return this._chipInput?this._chipInput.placeholder:this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}get focused(){return this._chipInput&&this._chipInput.focused||this._hasFocusedChip()}get empty(){return(!this._chipInput||this._chipInput.empty)&&(!this.chips||0===this.chips.length)}get shouldLabelFloat(){return!this.empty||this.focused}get disabled(){return this.ngControl?!!this.ngControl.disabled:this._disabled}set disabled(e){this._disabled=rt(e),this._syncChipsState()}get selectable(){return this._selectable}set selectable(e){this._selectable=rt(e),this.chips&&this.chips.forEach(i=>i.chipListSelectable=this._selectable)}set tabIndex(e){this._userTabIndex=e,this._tabIndex=e}get chipSelectionChanges(){return $n(...this.chips.map(e=>e.selectionChange))}get chipFocusChanges(){return $n(...this.chips.map(e=>e._onFocus))}get chipBlurChanges(){return $n(...this.chips.map(e=>e._onBlur))}get chipRemoveChanges(){return $n(...this.chips.map(e=>e.destroyed))}ngAfterContentInit(){this._keyManager=new Wu(this.chips).withWrap().withVerticalOrientation().withHomeAndEnd().withHorizontalOrientation(this._dir?this._dir.value:"ltr"),this._dir&&this._dir.change.pipe(Ot(this._destroyed)).subscribe(e=>this._keyManager.withHorizontalOrientation(e)),this._keyManager.tabOut.pipe(Ot(this._destroyed)).subscribe(()=>{this._allowFocusEscape()}),this.chips.changes.pipe(Qn(null),Ot(this._destroyed)).subscribe(()=>{this.disabled&&Promise.resolve().then(()=>{this._syncChipsState()}),this._resetChips(),this._initializeSelection(),this._updateTabIndex(),this._updateFocusForDestroyedChips(),this.stateChanges.next()})}ngOnInit(){this._selectionModel=new ah(this.multiple,void 0,!1),this.stateChanges.next()}ngDoCheck(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==this._disabled&&(this.disabled=!!this.ngControl.disabled))}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete(),this.stateChanges.complete(),this._dropSubscriptions()}registerInput(e){this._chipInput=e,this._elementRef.nativeElement.setAttribute("data-mat-chip-input",e.id)}setDescribedByIds(e){e.length?this._elementRef.nativeElement.setAttribute("aria-describedby",e.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}writeValue(e){this.chips&&this._setSelectionByValue(e,!1)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this.stateChanges.next()}onContainerClick(e){this._originatesFromChip(e)||this.focus()}focus(e){this.disabled||this._chipInput&&this._chipInput.focused||(this.chips.length>0?(this._keyManager.setFirstItemActive(),this.stateChanges.next()):(this._focusInput(e),this.stateChanges.next()))}_focusInput(e){this._chipInput&&this._chipInput.focus(e)}_keydown(e){const i=e.target;i&&i.classList.contains("mat-chip")&&(this._keyManager.onKeydown(e),this.stateChanges.next())}_updateTabIndex(){this._tabIndex=this._userTabIndex||(0===this.chips.length?-1:0)}_updateFocusForDestroyedChips(){if(null!=this._lastDestroyedChipIndex)if(this.chips.length){const e=Math.min(this._lastDestroyedChipIndex,this.chips.length-1);this._keyManager.setActiveItem(e)}else this.focus();this._lastDestroyedChipIndex=null}_isValidIndex(e){return e>=0&&er.deselect()),Array.isArray(e))e.forEach(r=>this._selectValue(r,i)),this._sortValues();else{const r=this._selectValue(e,i);r&&i&&this._keyManager.setActiveItem(r)}}_selectValue(e,i=!0){const r=this.chips.find(s=>null!=s.value&&this._compareWith(s.value,e));return r&&(i?r.selectViaInteraction():r.select(),this._selectionModel.select(r)),r}_initializeSelection(){Promise.resolve().then(()=>{(this.ngControl||this._value)&&(this._setSelectionByValue(this.ngControl?this.ngControl.value:this._value,!1),this.stateChanges.next())})}_clearSelection(e){this._selectionModel.clear(),this.chips.forEach(i=>{i!==e&&i.deselect()}),this.stateChanges.next()}_sortValues(){this._multiple&&(this._selectionModel.clear(),this.chips.forEach(e=>{e.selected&&this._selectionModel.select(e)}),this.stateChanges.next())}_propagateChanges(e){let i=null;i=Array.isArray(this.selected)?this.selected.map(r=>r.value):this.selected?this.selected.value:e,this._value=i,this.change.emit(new M8(this,i)),this.valueChange.emit(i),this._onChange(i),this._changeDetectorRef.markForCheck()}_blur(){this._hasFocusedChip()||this._keyManager.setActiveItem(-1),this.disabled||(this._chipInput?setTimeout(()=>{this.focused||this._markAsTouched()}):this._markAsTouched())}_markAsTouched(){this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next()}_allowFocusEscape(){-1!==this._tabIndex&&(this._tabIndex=-1,setTimeout(()=>{this._tabIndex=this._userTabIndex||0,this._changeDetectorRef.markForCheck()}))}_resetChips(){this._dropSubscriptions(),this._listenToChipsFocus(),this._listenToChipsSelection(),this._listenToChipsRemoved()}_dropSubscriptions(){this._chipFocusSubscription&&(this._chipFocusSubscription.unsubscribe(),this._chipFocusSubscription=null),this._chipBlurSubscription&&(this._chipBlurSubscription.unsubscribe(),this._chipBlurSubscription=null),this._chipSelectionSubscription&&(this._chipSelectionSubscription.unsubscribe(),this._chipSelectionSubscription=null),this._chipRemoveSubscription&&(this._chipRemoveSubscription.unsubscribe(),this._chipRemoveSubscription=null)}_listenToChipsSelection(){this._chipSelectionSubscription=this.chipSelectionChanges.subscribe(e=>{e.source.selected?this._selectionModel.select(e.source):this._selectionModel.deselect(e.source),this.multiple||this.chips.forEach(i=>{!this._selectionModel.isSelected(i)&&i.selected&&i.deselect()}),e.isUserInput&&this._propagateChanges()})}_listenToChipsFocus(){this._chipFocusSubscription=this.chipFocusChanges.subscribe(e=>{let i=this.chips.toArray().indexOf(e.chip);this._isValidIndex(i)&&this._keyManager.updateActiveItem(i),this.stateChanges.next()}),this._chipBlurSubscription=this.chipBlurChanges.subscribe(()=>{this._blur(),this.stateChanges.next()})}_listenToChipsRemoved(){this._chipRemoveSubscription=this.chipRemoveChanges.subscribe(e=>{const i=e.chip,r=this.chips.toArray().indexOf(e.chip);this._isValidIndex(r)&&i._hasFocus&&(this._lastDestroyedChipIndex=r)})}_originatesFromChip(e){let i=e.target;for(;i&&i!==this._elementRef.nativeElement;){if(i.classList.contains("mat-chip"))return!0;i=i.parentElement}return!1}_hasFocusedChip(){return this.chips&&this.chips.some(e=>e._hasFocus)}_syncChipsState(){this.chips&&this.chips.forEach(e=>{e._chipListDisabled=this._disabled,e._chipListMultiple=this.multiple})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(qi,8),x(Xl,8),x(Jl,8),x(ih),x(Tr,10))},n.\u0275cmp=vt({type:n,selectors:[["mat-chip-list"]],contentQueries:function(e,i,r){if(1&e&&It(r,Ia,5),2&e){let s;Ge(s=We())&&(i.chips=s)}},hostAttrs:[1,"mat-chip-list"],hostVars:14,hostBindings:function(e,i){1&e&&$e("focus",function(){return i.focus()})("blur",function(){return i._blur()})("keydown",function(s){return i._keydown(s)}),2&e&&(Zr("id",i._uid),wt("tabindex",i.disabled?null:i._tabIndex)("aria-required",i.role?i.required:null)("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-multiselectable",i.multiple)("role",i.role)("aria-orientation",i.ariaOrientation),At("mat-chip-list-disabled",i.disabled)("mat-chip-list-invalid",i.errorState)("mat-chip-list-required",i.required))},inputs:{role:"role",userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],errorStateMatcher:"errorStateMatcher",multiple:"multiple",compareWith:"compareWith",value:"value",required:"required",placeholder:"placeholder",disabled:"disabled",ariaOrientation:["aria-orientation","ariaOrientation"],selectable:"selectable",tabIndex:"tabIndex"},outputs:{change:"change",valueChange:"valueChange"},exportAs:["matChipList"],features:[Xe([{provide:lh,useExisting:n}]),Le],ngContentSelectors:m8,decls:2,vars:0,consts:[[1,"mat-chip-list-wrapper"]],template:function(e,i){1&e&&(Fn(),fe(0,"div",0),Tt(1),we())},styles:['.mat-chip{position:relative;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0);border:none;-webkit-appearance:none;-moz-appearance:none}.mat-standard-chip{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:inline-flex;padding:7px 12px;border-radius:16px;align-items:center;cursor:default;min-height:32px;height:1px}.mat-standard-chip._mat-animation-noopable{transition:none !important;animation:none !important}.mat-standard-chip .mat-chip-remove{border:none;-webkit-appearance:none;-moz-appearance:none;padding:0;background:none}.mat-standard-chip .mat-chip-remove.mat-icon,.mat-standard-chip .mat-chip-remove .mat-icon{width:18px;height:18px;font-size:18px}.mat-standard-chip::after{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;opacity:0;content:"";pointer-events:none;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-standard-chip:hover::after{opacity:.12}.mat-standard-chip:focus{outline:none}.mat-standard-chip:focus::after{opacity:.16}.cdk-high-contrast-active .mat-standard-chip{outline:solid 1px}.cdk-high-contrast-active .mat-standard-chip:focus{outline:dotted 2px}.cdk-high-contrast-active .mat-standard-chip.mat-chip-selected{outline-width:3px}.mat-standard-chip.mat-chip-disabled::after{opacity:0}.mat-standard-chip.mat-chip-disabled .mat-chip-remove,.mat-standard-chip.mat-chip-disabled .mat-chip-trailing-icon{cursor:default}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar,.mat-standard-chip.mat-chip-with-avatar{padding-top:0;padding-bottom:0}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-right:8px;padding-left:0}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-left:8px;padding-right:0}.mat-standard-chip.mat-chip-with-trailing-icon{padding-top:7px;padding-bottom:7px;padding-right:8px;padding-left:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon{padding-left:8px;padding-right:12px}.mat-standard-chip.mat-chip-with-avatar{padding-left:0;padding-right:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-avatar{padding-right:0;padding-left:12px}.mat-standard-chip .mat-chip-avatar{width:24px;height:24px;margin-right:8px;margin-left:4px}[dir=rtl] .mat-standard-chip .mat-chip-avatar{margin-left:8px;margin-right:4px}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{width:18px;height:18px;cursor:pointer}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-standard-chip .mat-chip-remove,[dir=rtl] .mat-standard-chip .mat-chip-trailing-icon{margin-right:8px;margin-left:0}.mat-chip-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit;overflow:hidden;transform:translateZ(0)}.mat-chip-list-wrapper{display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;margin:-4px}.mat-chip-list-wrapper input.mat-input-element,.mat-chip-list-wrapper .mat-standard-chip{margin:4px}.mat-chip-list-stacked .mat-chip-list-wrapper{flex-direction:column;align-items:flex-start}.mat-chip-list-stacked .mat-chip-list-wrapper .mat-standard-chip{width:100%}.mat-chip-avatar{border-radius:50%;justify-content:center;align-items:center;display:flex;overflow:hidden;object-fit:cover}input.mat-chip-input{width:150px;margin:4px;flex:1 0 150px}'],encapsulation:2,changeDetection:0}),n})(),x8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[ih,{provide:KS,useValue:{separatorKeyCodes:[13]}}],imports:[ht]}),n})();class X_{attach(t){return this._attachedHost=t,t.attach(this)}detach(){let t=this._attachedHost;null!=t&&(this._attachedHost=null,t.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(t){this._attachedHost=t}}class pc extends X_{constructor(t,e,i,r){super(),this.component=t,this.viewContainerRef=e,this.injector=i,this.componentFactoryResolver=r}}class mc extends X_{constructor(t,e,i,r){super(),this.templateRef=t,this.viewContainerRef=e,this.context=i,this.injector=r}get origin(){return this.templateRef.elementRef}attach(t,e=this.context){return this.context=e,super.attach(t)}detach(){return this.context=void 0,super.detach()}}class S8 extends X_{constructor(t){super(),this.element=t instanceof Je?t.nativeElement:t}}class hh{constructor(){this._isDisposed=!1,this.attachDomPortal=null}hasAttached(){return!!this._attachedPortal}attach(t){return t instanceof pc?(this._attachedPortal=t,this.attachComponentPortal(t)):t instanceof mc?(this._attachedPortal=t,this.attachTemplatePortal(t)):this.attachDomPortal&&t instanceof S8?(this._attachedPortal=t,this.attachDomPortal(t)):void 0}detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(t){this._disposeFn=t}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class k8 extends hh{constructor(t,e,i,r,s){super(),this.outletElement=t,this._componentFactoryResolver=e,this._appRef=i,this._defaultInjector=r,this.attachDomPortal=o=>{const a=o.element,l=this._document.createComment("dom-portal");a.parentNode.insertBefore(l,a),this.outletElement.appendChild(a),this._attachedPortal=o,super.setDisposeFn(()=>{l.parentNode&&l.parentNode.replaceChild(a,l)})},this._document=s}attachComponentPortal(t){const i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component);let r;return t.viewContainerRef?(r=t.viewContainerRef.createComponent(i,t.viewContainerRef.length,t.injector||t.viewContainerRef.injector),this.setDisposeFn(()=>r.destroy())):(r=i.create(t.injector||this._defaultInjector||Jt.NULL),this._appRef.attachView(r.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(r.hostView),r.destroy()})),this.outletElement.appendChild(this._getComponentRootNode(r)),this._attachedPortal=t,r}attachTemplatePortal(t){let e=t.viewContainerRef,i=e.createEmbeddedView(t.templateRef,t.context,{injector:t.injector});return i.rootNodes.forEach(r=>this.outletElement.appendChild(r)),i.detectChanges(),this.setDisposeFn(()=>{let r=e.indexOf(i);-1!==r&&e.remove(r)}),this._attachedPortal=t,i}dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(t){return t.hostView.rootNodes[0]}}let Ra=(()=>{class n extends hh{constructor(e,i,r){super(),this._componentFactoryResolver=e,this._viewContainerRef=i,this._isInitialized=!1,this.attached=new je,this.attachDomPortal=s=>{const o=s.element,a=this._document.createComment("dom-portal");s.setAttachedHost(this),o.parentNode.insertBefore(a,o),this._getRootNode().appendChild(o),this._attachedPortal=s,super.setDisposeFn(()=>{a.parentNode&&a.parentNode.replaceChild(o,a)})},this._document=r}get portal(){return this._attachedPortal}set portal(e){this.hasAttached()&&!e&&!this._isInitialized||(this.hasAttached()&&super.detach(),e&&super.attach(e),this._attachedPortal=e||null)}get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedPortal=null,this._attachedRef=null}attachComponentPortal(e){e.setAttachedHost(this);const i=null!=e.viewContainerRef?e.viewContainerRef:this._viewContainerRef,s=(e.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(e.component),o=i.createComponent(s,i.length,e.injector||i.injector);return i!==this._viewContainerRef&&this._getRootNode().appendChild(o.hostView.rootNodes[0]),super.setDisposeFn(()=>o.destroy()),this._attachedPortal=e,this._attachedRef=o,this.attached.emit(o),o}attachTemplatePortal(e){e.setAttachedHost(this);const i=this._viewContainerRef.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=e,this._attachedRef=i,this.attached.emit(i),i}_getRootNode(){const e=this._viewContainerRef.element.nativeElement;return e.nodeType===e.ELEMENT_NODE?e:e.parentNode}}return n.\u0275fac=function(e){return new(e||n)(x(io),x(An),x(ct))},n.\u0275dir=Me({type:n,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Le]}),n})(),Os=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const QS=I3();class A8{constructor(t,e){this._viewportRuler=t,this._previousHTMLStyles={top:"",left:""},this._isEnabled=!1,this._document=e}attach(){}enable(){if(this._canBeEnabled()){const t=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=t.style.left||"",this._previousHTMLStyles.top=t.style.top||"",t.style.left=xn(-this._previousScrollPosition.left),t.style.top=xn(-this._previousScrollPosition.top),t.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const t=this._document.documentElement,i=t.style,r=this._document.body.style,s=i.scrollBehavior||"",o=r.scrollBehavior||"";this._isEnabled=!1,i.left=this._previousHTMLStyles.left,i.top=this._previousHTMLStyles.top,t.classList.remove("cdk-global-scrollblock"),QS&&(i.scrollBehavior=r.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),QS&&(i.scrollBehavior=s,r.scrollBehavior=o)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const e=this._document.body,i=this._viewportRuler.getViewportSize();return e.scrollHeight>i.height||e.scrollWidth>i.width}}class I8{constructor(t,e,i,r){this._scrollDispatcher=t,this._ngZone=e,this._viewportRuler=i,this._config=r,this._scrollSubscription=null,this._detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}attach(t){this._overlayRef=t}enable(){if(this._scrollSubscription)return;const t=this._scrollDispatcher.scrolled(0);this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=t.subscribe(()=>{const e=this._viewportRuler.getViewportScrollPosition().top;Math.abs(e-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=t.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}class ZS{enable(){}disable(){}attach(){}}function J_(n,t){return t.some(e=>n.bottome.bottom||n.righte.right)}function XS(n,t){return t.some(e=>n.tope.bottom||n.lefte.right)}class R8{constructor(t,e,i,r){this._scrollDispatcher=t,this._viewportRuler=e,this._ngZone=i,this._config=r,this._scrollSubscription=null}attach(t){this._overlayRef=t}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const e=this._overlayRef.overlayElement.getBoundingClientRect(),{width:i,height:r}=this._viewportRuler.getViewportSize();J_(e,[{width:i,height:r,bottom:r,right:i,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let P8=(()=>{class n{constructor(e,i,r,s){this._scrollDispatcher=e,this._viewportRuler=i,this._ngZone=r,this.noop=()=>new ZS,this.close=o=>new I8(this._scrollDispatcher,this._ngZone,this._viewportRuler,o),this.block=()=>new A8(this._viewportRuler,this._document),this.reposition=o=>new R8(this._scrollDispatcher,this._viewportRuler,this._ngZone,o),this._document=s}}return n.\u0275fac=function(e){return new(e||n)(te(VU),te(ss),te(et),te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class fh{constructor(t){if(this.scrollStrategy=new ZS,this.panelClass="",this.hasBackdrop=!1,this.backdropClass="cdk-overlay-dark-backdrop",this.disposeOnNavigation=!1,t){const e=Object.keys(t);for(const i of e)void 0!==t[i]&&(this[i]=t[i])}}}class O8{constructor(t,e){this.connectionPair=t,this.scrollableViewProperties=e}}class gc{constructor(t,e,i,r,s,o,a,l,c,d=!1){this._portalOutlet=t,this._host=e,this._pane=i,this._config=r,this._ngZone=s,this._keyboardDispatcher=o,this._document=a,this._location=l,this._outsideClickDispatcher=c,this._animationsDisabled=d,this._backdropElement=null,this._backdropClick=new ue,this._attachments=new ue,this._detachments=new ue,this._locationChanges=X.EMPTY,this._backdropClickHandler=f=>this._backdropClick.next(f),this._backdropTransitionendHandler=f=>{this._disposeBackdrop(f.target)},this._keydownEvents=new ue,this._outsidePointerEvents=new ue,r.scrollStrategy&&(this._scrollStrategy=r.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=r.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(t){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const e=this._portalOutlet.attach(t);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this.hasAttached()&&this.updatePosition()}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),e}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const t=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenStable(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),t}dispose(){var t;const e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),null===(t=this._host)||void 0===t||t.remove(),this._previousHostParent=this._pane=this._host=null,e&&this._detachments.next(),this._detachments.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(t){t!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=t,this.hasAttached()&&(t.attach(this),this.updatePosition()))}updateSize(t){this._config=Object.assign(Object.assign({},this._config),t),this._updateElementSize()}setDirection(t){this._config=Object.assign(Object.assign({},this._config),{direction:t}),this._updateElementDirection()}addPanelClass(t){this._pane&&this._toggleClasses(this._pane,t,!0)}removePanelClass(t){this._pane&&this._toggleClasses(this._pane,t,!1)}getDirection(){const t=this._config.direction;return t?"string"==typeof t?t:t.value:"ltr"}updateScrollStrategy(t){t!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=t,this.hasAttached()&&(t.attach(this),t.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const t=this._pane.style;t.width=xn(this._config.width),t.height=xn(this._config.height),t.minWidth=xn(this._config.minWidth),t.minHeight=xn(this._config.minHeight),t.maxWidth=xn(this._config.maxWidth),t.maxHeight=xn(this._config.maxHeight)}_togglePointerEvents(t){this._pane.style.pointerEvents=t?"":"none"}_attachBackdrop(){const t="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),this._animationsDisabled||"undefined"==typeof requestAnimationFrame?this._backdropElement.classList.add(t):this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(t)})})}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const t=this._backdropElement;if(t){if(this._animationsDisabled)return void this._disposeBackdrop(t);t.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{t.addEventListener("transitionend",this._backdropTransitionendHandler)}),t.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(t)},500))}}_toggleClasses(t,e,i){const r=Uu(e||[]).filter(s=>!!s);r.length&&(i?t.classList.add(...r):t.classList.remove(...r))}_detachContentWhenStable(){this._ngZone.runOutsideAngular(()=>{const t=this._ngZone.onStable.pipe(Ot($n(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),t.unsubscribe())})})}_disposeScrollStrategy(){const t=this._scrollStrategy;t&&(t.disable(),t.detach&&t.detach())}_disposeBackdrop(t){t&&(t.removeEventListener("click",this._backdropClickHandler),t.removeEventListener("transitionend",this._backdropTransitionendHandler),t.remove(),this._backdropElement===t&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}let ph=(()=>{class n{constructor(e,i){this._platform=i,this._document=e}ngOnDestroy(){var e;null===(e=this._containerElement)||void 0===e||e.remove()}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const e="cdk-overlay-container";if(this._platform.isBrowser||__()){const r=this._document.querySelectorAll(`.${e}[platform="server"], .${e}[platform="test"]`);for(let s=0;s{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const t=this._originRect,e=this._overlayRect,i=this._viewportRect,r=this._containerRect,s=[];let o;for(let a of this._preferredPositions){let l=this._getOriginPoint(t,r,a),c=this._getOverlayPoint(l,e,a),d=this._getOverlayFit(c,e,i,a);if(d.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(a,l);this._canFitWithFlexibleDimensions(d,c,i)?s.push({position:a,origin:l,overlayRect:e,boundingBoxRect:this._calculateBoundingBoxRect(l,a)}):(!o||o.overlayFit.visibleAreal&&(l=d,a=c)}return this._isPushed=!1,void this._applyPosition(a.position,a.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(o.position,o.originPoint);this._applyPosition(o.position,o.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&bo(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(JS),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const t=this._lastPosition;if(t){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const e=this._getOriginPoint(this._originRect,this._containerRect,t);this._applyPosition(t,e)}else this.apply()}withScrollableContainers(t){return this._scrollables=t,this}withPositions(t){return this._preferredPositions=t,-1===t.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(t){return this._viewportMargin=t,this}withFlexibleDimensions(t=!0){return this._hasFlexibleDimensions=t,this}withGrowAfterOpen(t=!0){return this._growAfterOpen=t,this}withPush(t=!0){return this._canPush=t,this}withLockedPosition(t=!0){return this._positionLocked=t,this}setOrigin(t){return this._origin=t,this}withDefaultOffsetX(t){return this._offsetX=t,this}withDefaultOffsetY(t){return this._offsetY=t,this}withTransformOriginOn(t){return this._transformOriginSelector=t,this}_getOriginPoint(t,e,i){let r,s;if("center"==i.originX)r=t.left+t.width/2;else{const o=this._isRtl()?t.right:t.left,a=this._isRtl()?t.left:t.right;r="start"==i.originX?o:a}return e.left<0&&(r-=e.left),s="center"==i.originY?t.top+t.height/2:"top"==i.originY?t.top:t.bottom,e.top<0&&(s-=e.top),{x:r,y:s}}_getOverlayPoint(t,e,i){let r,s;return r="center"==i.overlayX?-e.width/2:"start"===i.overlayX?this._isRtl()?-e.width:0:this._isRtl()?0:-e.width,s="center"==i.overlayY?-e.height/2:"top"==i.overlayY?0:-e.height,{x:t.x+r,y:t.y+s}}_getOverlayFit(t,e,i,r){const s=tk(e);let{x:o,y:a}=t,l=this._getOffset(r,"x"),c=this._getOffset(r,"y");l&&(o+=l),c&&(a+=c);let w=0-a,k=a+s.height-i.height,j=this._subtractOverflows(s.width,0-o,o+s.width-i.width),K=this._subtractOverflows(s.height,w,k),ae=j*K;return{visibleArea:ae,isCompletelyWithinViewport:s.width*s.height===ae,fitsInViewportVertically:K===s.height,fitsInViewportHorizontally:j==s.width}}_canFitWithFlexibleDimensions(t,e,i){if(this._hasFlexibleDimensions){const r=i.bottom-e.y,s=i.right-e.x,o=ek(this._overlayRef.getConfig().minHeight),a=ek(this._overlayRef.getConfig().minWidth),c=t.fitsInViewportHorizontally||null!=a&&a<=s;return(t.fitsInViewportVertically||null!=o&&o<=r)&&c}return!1}_pushOverlayOnScreen(t,e,i){if(this._previousPushAmount&&this._positionLocked)return{x:t.x+this._previousPushAmount.x,y:t.y+this._previousPushAmount.y};const r=tk(e),s=this._viewportRect,o=Math.max(t.x+r.width-s.width,0),a=Math.max(t.y+r.height-s.height,0),l=Math.max(s.top-i.top-t.y,0),c=Math.max(s.left-i.left-t.x,0);let d=0,f=0;return d=r.width<=s.width?c||-o:t.xj&&!this._isInitialRender&&!this._growAfterOpen&&(o=t.y-j/2)}if("end"===e.overlayX&&!r||"start"===e.overlayX&&r)w=i.width-t.x+this._viewportMargin,d=t.x-this._viewportMargin;else if("start"===e.overlayX&&!r||"end"===e.overlayX&&r)f=t.x,d=i.right-t.x;else{const k=Math.min(i.right-t.x+i.left,t.x),j=this._lastBoundingBoxSize.width;d=2*k,f=t.x-k,d>j&&!this._isInitialRender&&!this._growAfterOpen&&(f=t.x-j/2)}return{top:o,left:f,bottom:a,right:w,width:d,height:s}}_setBoundingBoxStyles(t,e){const i=this._calculateBoundingBoxRect(t,e);!this._isInitialRender&&!this._growAfterOpen&&(i.height=Math.min(i.height,this._lastBoundingBoxSize.height),i.width=Math.min(i.width,this._lastBoundingBoxSize.width));const r={};if(this._hasExactPosition())r.top=r.left="0",r.bottom=r.right=r.maxHeight=r.maxWidth="",r.width=r.height="100%";else{const s=this._overlayRef.getConfig().maxHeight,o=this._overlayRef.getConfig().maxWidth;r.height=xn(i.height),r.top=xn(i.top),r.bottom=xn(i.bottom),r.width=xn(i.width),r.left=xn(i.left),r.right=xn(i.right),r.alignItems="center"===e.overlayX?"center":"end"===e.overlayX?"flex-end":"flex-start",r.justifyContent="center"===e.overlayY?"center":"bottom"===e.overlayY?"flex-end":"flex-start",s&&(r.maxHeight=xn(s)),o&&(r.maxWidth=xn(o))}this._lastBoundingBoxSize=i,bo(this._boundingBox.style,r)}_resetBoundingBoxStyles(){bo(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){bo(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(t,e){const i={},r=this._hasExactPosition(),s=this._hasFlexibleDimensions,o=this._overlayRef.getConfig();if(r){const d=this._viewportRuler.getViewportScrollPosition();bo(i,this._getExactOverlayY(e,t,d)),bo(i,this._getExactOverlayX(e,t,d))}else i.position="static";let a="",l=this._getOffset(e,"x"),c=this._getOffset(e,"y");l&&(a+=`translateX(${l}px) `),c&&(a+=`translateY(${c}px)`),i.transform=a.trim(),o.maxHeight&&(r?i.maxHeight=xn(o.maxHeight):s&&(i.maxHeight="")),o.maxWidth&&(r?i.maxWidth=xn(o.maxWidth):s&&(i.maxWidth="")),bo(this._pane.style,i)}_getExactOverlayY(t,e,i){let r={top:"",bottom:""},s=this._getOverlayPoint(e,this._overlayRect,t);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),"bottom"===t.overlayY?r.bottom=this._document.documentElement.clientHeight-(s.y+this._overlayRect.height)+"px":r.top=xn(s.y),r}_getExactOverlayX(t,e,i){let o,r={left:"",right:""},s=this._getOverlayPoint(e,this._overlayRect,t);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),o=this._isRtl()?"end"===t.overlayX?"left":"right":"end"===t.overlayX?"right":"left","right"===o?r.right=this._document.documentElement.clientWidth-(s.x+this._overlayRect.width)+"px":r.left=xn(s.x),r}_getScrollVisibility(){const t=this._getOriginRect(),e=this._pane.getBoundingClientRect(),i=this._scrollables.map(r=>r.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:XS(t,i),isOriginOutsideView:J_(t,i),isOverlayClipped:XS(e,i),isOverlayOutsideView:J_(e,i)}}_subtractOverflows(t,...e){return e.reduce((i,r)=>i-Math.max(r,0),t)}_getNarrowedViewportRect(){const t=this._document.documentElement.clientWidth,e=this._document.documentElement.clientHeight,i=this._viewportRuler.getViewportScrollPosition();return{top:i.top+this._viewportMargin,left:i.left+this._viewportMargin,right:i.left+t-this._viewportMargin,bottom:i.top+e-this._viewportMargin,width:t-2*this._viewportMargin,height:e-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(t,e){return"x"===e?null==t.offsetX?this._offsetX:t.offsetX:null==t.offsetY?this._offsetY:t.offsetY}_validatePositions(){}_addPanelClasses(t){this._pane&&Uu(t).forEach(e=>{""!==e&&-1===this._appliedPanelClasses.indexOf(e)&&(this._appliedPanelClasses.push(e),this._pane.classList.add(e))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(t=>{this._pane.classList.remove(t)}),this._appliedPanelClasses=[])}_getOriginRect(){const t=this._origin;if(t instanceof Je)return t.nativeElement.getBoundingClientRect();if(t instanceof Element)return t.getBoundingClientRect();const e=t.width||0,i=t.height||0;return{top:t.y,bottom:t.y+i,left:t.x,right:t.x+e,height:i,width:e}}}function bo(n,t){for(let e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return n}function ek(n){if("number"!=typeof n&&null!=n){const[t,e]=n.split(F8);return e&&"px"!==e?null:parseFloat(t)}return n||null}function tk(n){return{top:Math.floor(n.top),right:Math.floor(n.right),bottom:Math.floor(n.bottom),left:Math.floor(n.left),width:Math.floor(n.width),height:Math.floor(n.height)}}const nk="cdk-global-overlay-wrapper";class N8{constructor(){this._cssPosition="static",this._topOffset="",this._bottomOffset="",this._alignItems="",this._xPosition="",this._xOffset="",this._width="",this._height="",this._isDisposed=!1}attach(t){const e=t.getConfig();this._overlayRef=t,this._width&&!e.width&&t.updateSize({width:this._width}),this._height&&!e.height&&t.updateSize({height:this._height}),t.hostElement.classList.add(nk),this._isDisposed=!1}top(t=""){return this._bottomOffset="",this._topOffset=t,this._alignItems="flex-start",this}left(t=""){return this._xOffset=t,this._xPosition="left",this}bottom(t=""){return this._topOffset="",this._bottomOffset=t,this._alignItems="flex-end",this}right(t=""){return this._xOffset=t,this._xPosition="right",this}start(t=""){return this._xOffset=t,this._xPosition="start",this}end(t=""){return this._xOffset=t,this._xPosition="end",this}width(t=""){return this._overlayRef?this._overlayRef.updateSize({width:t}):this._width=t,this}height(t=""){return this._overlayRef?this._overlayRef.updateSize({height:t}):this._height=t,this}centerHorizontally(t=""){return this.left(t),this._xPosition="center",this}centerVertically(t=""){return this.top(t),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement.style,i=this._overlayRef.getConfig(),{width:r,height:s,maxWidth:o,maxHeight:a}=i,l=!("100%"!==r&&"100vw"!==r||o&&"100%"!==o&&"100vw"!==o),c=!("100%"!==s&&"100vh"!==s||a&&"100%"!==a&&"100vh"!==a),d=this._xPosition,f=this._xOffset,w="rtl"===this._overlayRef.getConfig().direction;let k="",j="",K="";l?K="flex-start":"center"===d?(K="center",w?j=f:k=f):w?"left"===d||"end"===d?(K="flex-end",k=f):("right"===d||"start"===d)&&(K="flex-start",j=f):"left"===d||"start"===d?(K="flex-start",k=f):("right"===d||"end"===d)&&(K="flex-end",j=f),t.position=this._cssPosition,t.marginLeft=l?"0":k,t.marginTop=c?"0":this._topOffset,t.marginBottom=this._bottomOffset,t.marginRight=l?"0":j,e.justifyContent=K,e.alignItems=c?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement,i=e.style;e.classList.remove(nk),i.justifyContent=i.alignItems=t.marginTop=t.marginBottom=t.marginLeft=t.marginRight=t.position="",this._overlayRef=null,this._isDisposed=!0}}let B8=(()=>{class n{constructor(e,i,r,s){this._viewportRuler=e,this._document=i,this._platform=r,this._overlayContainer=s}global(){return new N8}flexibleConnectedTo(e){return new L8(e,this._viewportRuler,this._document,this._platform,this._overlayContainer)}}return n.\u0275fac=function(e){return new(e||n)(te(ss),te(ct),te(bn),te(ph))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),ik=(()=>{class n{constructor(e){this._attachedOverlays=[],this._document=e}ngOnDestroy(){this.detach()}add(e){this.remove(e),this._attachedOverlays.push(e)}remove(e){const i=this._attachedOverlays.indexOf(e);i>-1&&this._attachedOverlays.splice(i,1),0===this._attachedOverlays.length&&this.detach()}}return n.\u0275fac=function(e){return new(e||n)(te(ct))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),V8=(()=>{class n extends ik{constructor(e,i){super(e),this._ngZone=i,this._keydownListener=r=>{const s=this._attachedOverlays;for(let o=s.length-1;o>-1;o--)if(s[o]._keydownEvents.observers.length>0){const a=s[o]._keydownEvents;this._ngZone?this._ngZone.run(()=>a.next(r)):a.next(r);break}}}add(e){super.add(e),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(et,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),H8=(()=>{class n extends ik{constructor(e,i,r){super(e),this._platform=i,this._ngZone=r,this._cursorStyleIsSet=!1,this._pointerDownListener=s=>{this._pointerDownEventTarget=ur(s)},this._clickListener=s=>{const o=ur(s),a="click"===s.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:o;this._pointerDownEventTarget=null;const l=this._attachedOverlays.slice();for(let c=l.length-1;c>-1;c--){const d=l[c];if(d._outsidePointerEvents.observers.length<1||!d.hasAttached())continue;if(d.overlayElement.contains(o)||d.overlayElement.contains(a))break;const f=d._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>f.next(s)):f.next(s)}}}add(e){if(super.add(e),!this._isAttached){const i=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(i)):this._addEventListeners(i),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=i.style.cursor,i.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const e=this._document.body;e.removeEventListener("pointerdown",this._pointerDownListener,!0),e.removeEventListener("click",this._clickListener,!0),e.removeEventListener("auxclick",this._clickListener,!0),e.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(e.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(e){e.addEventListener("pointerdown",this._pointerDownListener,!0),e.addEventListener("click",this._clickListener,!0),e.addEventListener("auxclick",this._clickListener,!0),e.addEventListener("contextmenu",this._clickListener,!0)}}return n.\u0275fac=function(e){return new(e||n)(te(ct),te(bn),te(et,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),j8=0,Yi=(()=>{class n{constructor(e,i,r,s,o,a,l,c,d,f,w,k){this.scrollStrategies=e,this._overlayContainer=i,this._componentFactoryResolver=r,this._positionBuilder=s,this._keyboardDispatcher=o,this._injector=a,this._ngZone=l,this._document=c,this._directionality=d,this._location=f,this._outsideClickDispatcher=w,this._animationsModuleType=k}create(e){const i=this._createHostElement(),r=this._createPaneElement(i),s=this._createPortalOutlet(r),o=new fh(e);return o.direction=o.direction||this._directionality.value,new gc(s,i,r,o,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType)}position(){return this._positionBuilder}_createPaneElement(e){const i=this._document.createElement("div");return i.id="cdk-overlay-"+j8++,i.classList.add("cdk-overlay-pane"),e.appendChild(i),i}_createHostElement(){const e=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(e),e}_createPortalOutlet(e){return this._appRef||(this._appRef=this._injector.get(Ll)),new k8(e,this._componentFactoryResolver,this._appRef,this._injector,this._document)}}return n.\u0275fac=function(e){return new(e||n)(te(P8),te(ph),te(io),te(B8),te(V8),te(Jt),te(et),te(ct),te(qi),te(Vl),te(H8),te(fn,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const U8=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],rk=new De("cdk-connected-overlay-scroll-strategy");let sk=(()=>{class n{constructor(e){this.elementRef=e}}return n.\u0275fac=function(e){return new(e||n)(x(Je))},n.\u0275dir=Me({type:n,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]}),n})(),ok=(()=>{class n{constructor(e,i,r,s,o){this._overlay=e,this._dir=o,this._hasBackdrop=!1,this._lockPosition=!1,this._growAfterOpen=!1,this._flexibleDimensions=!1,this._push=!1,this._backdropSubscription=X.EMPTY,this._attachSubscription=X.EMPTY,this._detachSubscription=X.EMPTY,this._positionSubscription=X.EMPTY,this.viewportMargin=0,this.open=!1,this.disableClose=!1,this.backdropClick=new je,this.positionChange=new je,this.attach=new je,this.detach=new je,this.overlayKeydown=new je,this.overlayOutsideClick=new je,this._templatePortal=new mc(i,r),this._scrollStrategyFactory=s,this.scrollStrategy=this._scrollStrategyFactory()}get offsetX(){return this._offsetX}set offsetX(e){this._offsetX=e,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(e){this._offsetY=e,this._position&&this._updatePositionStrategy(this._position)}get hasBackdrop(){return this._hasBackdrop}set hasBackdrop(e){this._hasBackdrop=rt(e)}get lockPosition(){return this._lockPosition}set lockPosition(e){this._lockPosition=rt(e)}get flexibleDimensions(){return this._flexibleDimensions}set flexibleDimensions(e){this._flexibleDimensions=rt(e)}get growAfterOpen(){return this._growAfterOpen}set growAfterOpen(e){this._growAfterOpen=rt(e)}get push(){return this._push}set push(e){this._push=rt(e)}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(e){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),e.origin&&this.open&&this._position.apply()),e.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=U8);const e=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=e.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=e.detachments().subscribe(()=>this.detach.emit()),e.keydownEvents().subscribe(i=>{this.overlayKeydown.next(i),27===i.keyCode&&!this.disableClose&&!gi(i)&&(i.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(i=>{this.overlayOutsideClick.next(i)})}_buildConfig(){const e=this._position=this.positionStrategy||this._createPositionStrategy(),i=new fh({direction:this._dir,positionStrategy:e,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop});return(this.width||0===this.width)&&(i.width=this.width),(this.height||0===this.height)&&(i.height=this.height),(this.minWidth||0===this.minWidth)&&(i.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(i.minHeight=this.minHeight),this.backdropClass&&(i.backdropClass=this.backdropClass),this.panelClass&&(i.panelClass=this.panelClass),i}_updatePositionStrategy(e){const i=this.positions.map(r=>({originX:r.originX,originY:r.originY,overlayX:r.overlayX,overlayY:r.overlayY,offsetX:r.offsetX||this.offsetX,offsetY:r.offsetY||this.offsetY,panelClass:r.panelClass||void 0}));return e.setOrigin(this._getFlexibleConnectedPositionStrategyOrigin()).withPositions(i).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const e=this._overlay.position().flexibleConnectedTo(this._getFlexibleConnectedPositionStrategyOrigin());return this._updatePositionStrategy(e),e}_getFlexibleConnectedPositionStrategyOrigin(){return this.origin instanceof sk?this.origin.elementRef:this.origin}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(e=>{this.backdropClick.emit(e)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(function T8(n,t=!1){return Pe((e,i)=>{let r=0;e.subscribe(_e(i,s=>{const o=n(s,r++);(o||t)&&i.next(s),!o&&i.complete()}))})}(()=>this.positionChange.observers.length>0)).subscribe(e=>{this.positionChange.emit(e),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}}return n.\u0275fac=function(e){return new(e||n)(x(Yi),x(_n),x(An),x(rk),x(qi,8))},n.\u0275dir=Me({type:n,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:["cdkConnectedOverlayOrigin","origin"],positions:["cdkConnectedOverlayPositions","positions"],positionStrategy:["cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:["cdkConnectedOverlayOffsetX","offsetX"],offsetY:["cdkConnectedOverlayOffsetY","offsetY"],width:["cdkConnectedOverlayWidth","width"],height:["cdkConnectedOverlayHeight","height"],minWidth:["cdkConnectedOverlayMinWidth","minWidth"],minHeight:["cdkConnectedOverlayMinHeight","minHeight"],backdropClass:["cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:["cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:["cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:["cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:["cdkConnectedOverlayOpen","open"],disableClose:["cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:["cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:["cdkConnectedOverlayHasBackdrop","hasBackdrop"],lockPosition:["cdkConnectedOverlayLockPosition","lockPosition"],flexibleDimensions:["cdkConnectedOverlayFlexibleDimensions","flexibleDimensions"],growAfterOpen:["cdkConnectedOverlayGrowAfterOpen","growAfterOpen"],push:["cdkConnectedOverlayPush","push"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[cn]}),n})();const $8={provide:rk,deps:[Yi],useFactory:function z8(n){return()=>n.scrollStrategies.reposition()}};let Pa=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[Yi,$8],imports:[ac,Os,N_,N_]}),n})(),ak=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),W8=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[ih],imports:[ak,dh,ht,ak,dh]}),n})(),n$=(()=>{class n{constructor(){this.changes=new ue,this.calendarLabel="Calendar",this.openCalendarLabel="Open calendar",this.closeCalendarLabel="Close calendar",this.prevMonthLabel="Previous month",this.nextMonthLabel="Next month",this.prevYearLabel="Previous year",this.nextYearLabel="Next year",this.prevMultiYearLabel="Previous 24 years",this.nextMultiYearLabel="Next 24 years",this.switchToMonthViewLabel="Choose date",this.switchToMultiYearViewLabel="Choose month and year"}formatYearRange(e,i){return`${e} \u2013 ${i}`}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const s$={provide:new De("mat-datepicker-scroll-strategy"),deps:[Yi],useFactory:function r$(n){return()=>n.scrollStrategies.reposition()}};let d$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[n$,s$],imports:[pi,oh,Pa,Ku,Os,ht,Sa]}),n})();function _c(n){return new J(t=>{di(n()).subscribe(t)})}function u$(n,t){}class vh{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.closeOnNavigation=!0,this.closeOnDestroy=!0}}let uk=(()=>{class n extends hh{constructor(e,i,r,s,o,a,l,c){super(),this._elementRef=e,this._focusTrapFactory=i,this._config=s,this._interactivityChecker=o,this._ngZone=a,this._overlayRef=l,this._focusMonitor=c,this._elementFocusedBeforeDialogWasOpened=null,this._closeInteractionType=null,this.attachDomPortal=d=>{this._portalOutlet.hasAttached();const f=this._portalOutlet.attachDomPortal(d);return this._contentAttached(),f},this._ariaLabelledBy=this._config.ariaLabelledBy||null,this._document=r}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._restoreFocus()}attachComponentPortal(e){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachComponentPortal(e);return this._contentAttached(),i}attachTemplatePortal(e){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachTemplatePortal(e);return this._contentAttached(),i}_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(e,i){this._interactivityChecker.isFocusable(e)||(e.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const r=()=>{e.removeEventListener("blur",r),e.removeEventListener("mousedown",r),e.removeAttribute("tabindex")};e.addEventListener("blur",r),e.addEventListener("mousedown",r)})),e.focus(i)}_focusByCssSelector(e,i){let r=this._elementRef.nativeElement.querySelector(e);r&&this._forceFocus(r,i)}_trapFocus(){const e=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||e.focus();break;case!0:case"first-tabbable":this._focusTrap.focusInitialElementWhenReady().then(i=>{i||this._focusDialogContainer()});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}}_restoreFocus(){const e=this._config.restoreFocus;let i=null;if("string"==typeof e?i=this._document.querySelector(e):"boolean"==typeof e?i=e?this._elementFocusedBeforeDialogWasOpened:null:e&&(i=e),this._config.restoreFocus&&i&&"function"==typeof i.focus){const r=g_(),s=this._elementRef.nativeElement;(!r||r===this._document.body||r===s||s.contains(r))&&(this._focusMonitor?(this._focusMonitor.focusVia(i,this._closeInteractionType),this._closeInteractionType=null):i.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const e=this._elementRef.nativeElement,i=g_();return e===i||e.contains(i)}_initializeFocusTrap(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=g_())}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(vh),x(qu),x(et),x(gc),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["cdk-dialog-container"]],viewQuery:function(e,i){if(1&e&&Gt(Ra,7),2&e){let r;Ge(r=We())&&(i._portalOutlet=r.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(e,i){2&e&&wt("id",i._config.id||null)("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null)},features:[Le],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(e,i){1&e&&it(0,u$,0,0,"ng-template",0)},dependencies:[Ra],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2}),n})();class ev{constructor(t,e){this.overlayRef=t,this.config=e,this.closed=new ue,this.disableClose=e.disableClose,this.backdropClick=t.backdropClick(),this.keydownEvents=t.keydownEvents(),this.outsidePointerEvents=t.outsidePointerEvents(),this.id=e.id,this.keydownEvents.subscribe(i=>{27===i.keyCode&&!this.disableClose&&!gi(i)&&(i.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})})}close(t,e){if(this.containerInstance){const i=this.closed;this.containerInstance._closeInteractionType=(null==e?void 0:e.focusOrigin)||"program",this.overlayRef.dispose(),i.next(t),i.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(t="",e=""){return this.overlayRef.updateSize({width:t,height:e}),this}addPanelClass(t){return this.overlayRef.addPanelClass(t),this}removePanelClass(t){return this.overlayRef.removePanelClass(t),this}}const hk=new De("DialogScrollStrategy"),h$=new De("DialogData"),f$=new De("DefaultDialogConfig"),m$={provide:hk,deps:[Yi],useFactory:function p$(n){return()=>n.scrollStrategies.block()}};let g$=0,fk=(()=>{class n{constructor(e,i,r,s,o,a){this._overlay=e,this._injector=i,this._defaultOptions=r,this._parentDialog=s,this._overlayContainer=o,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new ue,this._afterOpenedAtThisLevel=new ue,this._ariaHiddenElements=new Map,this.afterAllClosed=_c(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qn(void 0))),this._scrollStrategy=a}get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}open(e,i){const r=this._defaultOptions||new vh;(i=Object.assign(Object.assign({},r),i)).id=i.id||"cdk-dialog-"+g$++,i.id&&this.getDialogById(i.id);const s=this._getOverlayConfig(i),o=this._overlay.create(s),a=new ev(o,i),l=this._attachContainer(o,a,i);return a.containerInstance=l,this._attachDialogContent(e,a,l,i),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(a),a.closed.subscribe(()=>this._removeOpenDialog(a,!0)),this.afterOpened.next(a),a}closeAll(){tv(this.openDialogs,e=>e.close())}getDialogById(e){return this.openDialogs.find(i=>i.id===e)}ngOnDestroy(){tv(this._openDialogsAtThisLevel,e=>{!1===e.config.closeOnDestroy&&this._removeOpenDialog(e,!1)}),tv(this._openDialogsAtThisLevel,e=>e.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(e){const i=new fh({positionStrategy:e.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:e.scrollStrategy||this._scrollStrategy(),panelClass:e.panelClass,hasBackdrop:e.hasBackdrop,direction:e.direction,minWidth:e.minWidth,minHeight:e.minHeight,maxWidth:e.maxWidth,maxHeight:e.maxHeight,width:e.width,height:e.height,disposeOnNavigation:e.closeOnNavigation});return e.backdropClass&&(i.backdropClass=e.backdropClass),i}_attachContainer(e,i,r){var s,o;const a=null!==(s=r.injector)&&void 0!==s?s:null===(o=r.viewContainerRef)||void 0===o?void 0:o.injector,l=[{provide:vh,useValue:r},{provide:ev,useValue:i},{provide:gc,useValue:e}];let c;r.container?"function"==typeof r.container?c=r.container:(c=r.container.type,l.push(...r.container.providers(r))):c=uk;const d=new pc(c,r.viewContainerRef,Jt.create({parent:a||this._injector,providers:l}),r.componentFactoryResolver);return e.attach(d).instance}_attachDialogContent(e,i,r,s){const o=this._createInjector(s,i,r);if(e instanceof _n){let a={$implicit:s.data,dialogRef:i};s.templateContext&&(a=Object.assign(Object.assign({},a),"function"==typeof s.templateContext?s.templateContext():s.templateContext)),r.attachTemplatePortal(new mc(e,null,a,o))}else{const a=r.attachComponentPortal(new pc(e,s.viewContainerRef,o,s.componentFactoryResolver));i.componentInstance=a.instance}}_createInjector(e,i,r){const s=e&&e.viewContainerRef&&e.viewContainerRef.injector,o=[{provide:h$,useValue:e.data},{provide:ev,useValue:i}];return e.providers&&("function"==typeof e.providers?o.push(...e.providers(i,e,r)):o.push(...e.providers)),e.direction&&(!s||!s.get(qi,null,at.Optional))&&o.push({provide:qi,useValue:{value:e.direction,change:tt()}}),Jt.create({parent:s||this._injector,providers:o})}_removeOpenDialog(e,i){const r=this.openDialogs.indexOf(e);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((s,o)=>{s?o.setAttribute("aria-hidden",s):o.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),i&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const e=this._overlayContainer.getContainerElement();if(e.parentElement){const i=e.parentElement.children;for(let r=i.length-1;r>-1;r--){const s=i[r];s!==e&&"SCRIPT"!==s.nodeName&&"STYLE"!==s.nodeName&&!s.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(s,s.getAttribute("aria-hidden")),s.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(Jt),te(f$,8),te(n,12),te(ph),te(hk))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function tv(n,t){let e=n.length;for(;e--;)t(n[e])}let _$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[fk,m$],imports:[Pa,Os,Ku,Os]}),n})();function v$(n,t){}const Fa={params:{enterAnimationDuration:"150ms",exitAnimationDuration:"75ms"}},y$={dialogContainer:jn("dialogContainer",[zt("void, exit",Qe({opacity:0,transform:"scale(0.7)"})),zt("enter",Qe({transform:"none"})),Wt("* => enter",VE([Zt("{{enterAnimationDuration}} cubic-bezier(0, 0, 0.2, 1)",Qe({transform:"none",opacity:1})),uu("@*",du(),{optional:!0})]),Fa),Wt("* => void, * => exit",VE([Zt("{{exitAnimationDuration}} cubic-bezier(0.4, 0.0, 0.2, 1)",Qe({opacity:0})),uu("@*",du(),{optional:!0})]),Fa)])};class yh{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.maxWidth="80vw",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.delayFocusTrap=!0,this.closeOnNavigation=!0,this.enterAnimationDuration=Fa.params.enterAnimationDuration,this.exitAnimationDuration=Fa.params.exitAnimationDuration}}let b$=(()=>{class n extends uk{constructor(e,i,r,s,o,a,l,c){super(e,i,r,s,o,a,l,c),this._animationStateChanged=new je}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(e){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:e})}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(yh),x(qu),x(et),x(gc),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["ng-component"]],features:[Le],decls:0,vars:0,template:function(e,i){},encapsulation:2}),n})(),w$=(()=>{class n extends b${constructor(e,i,r,s,o,a,l,c,d){super(e,i,r,s,o,a,l,d),this._changeDetectorRef=c,this._state="enter"}_onAnimationDone({toState:e,totalTime:i}){"enter"===e?this._openAnimationDone(i):"exit"===e&&this._animationStateChanged.next({state:"closed",totalTime:i})}_onAnimationStart({toState:e,totalTime:i}){"enter"===e?this._animationStateChanged.next({state:"opening",totalTime:i}):("exit"===e||"void"===e)&&this._animationStateChanged.next({state:"closing",totalTime:i})}_startExitAnimation(){this._state="exit",this._changeDetectorRef.markForCheck()}_getAnimationState(){return{value:this._state,params:{enterAnimationDuration:this._config.enterAnimationDuration||Fa.params.enterAnimationDuration,exitAnimationDuration:this._config.exitAnimationDuration||Fa.params.exitAnimationDuration}}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(A_),x(ct,8),x(yh),x(qu),x(et),x(gc),x(en),x(hr))},n.\u0275cmp=vt({type:n,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-dialog-container"],hostVars:7,hostBindings:function(e,i){1&e&&kd("@dialogContainer.start",function(s){return i._onAnimationStart(s)})("@dialogContainer.done",function(s){return i._onAnimationDone(s)}),2&e&&(Zr("id",i._config.id),wt("aria-modal",i._config.ariaModal)("role",i._config.role)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null),Id("@dialogContainer",i._getAnimationState()))},features:[Le],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(e,i){1&e&&it(0,v$,0,0,"ng-template",0)},dependencies:[Ra],styles:[".mat-dialog-container{display:block;padding:24px;border-radius:4px;box-sizing:border-box;overflow:auto;outline:0;width:100%;height:100%;min-height:inherit;max-height:inherit}.cdk-high-contrast-active .mat-dialog-container{outline:solid 1px}.mat-dialog-content{display:block;margin:0 -24px;padding:0 24px;max-height:65vh;overflow:auto;-webkit-overflow-scrolling:touch}.mat-dialog-title{margin:0 0 20px;display:block}.mat-dialog-actions{padding:8px 0;display:flex;flex-wrap:wrap;min-height:52px;align-items:center;box-sizing:content-box;margin-bottom:-24px}.mat-dialog-actions.mat-dialog-actions-align-center,.mat-dialog-actions[align=center]{justify-content:center}.mat-dialog-actions.mat-dialog-actions-align-end,.mat-dialog-actions[align=end]{justify-content:flex-end}.mat-dialog-actions .mat-button-base+.mat-button-base,.mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}"],encapsulation:2,data:{animation:[y$.dialogContainer]}}),n})();class C${constructor(t,e,i){this._ref=t,this._containerInstance=i,this._afterOpened=new ue,this._beforeClosed=new ue,this._state=0,this.disableClose=e.disableClose,this.id=t.id,i._animationStateChanged.pipe(yn(r=>"opened"===r.state),sn(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(yn(r=>"closed"===r.state),sn(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),t.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),$n(this.backdropClick(),this.keydownEvents().pipe(yn(r=>27===r.keyCode&&!this.disableClose&&!gi(r)))).subscribe(r=>{this.disableClose||(r.preventDefault(),function D$(n,t,e){n._closeInteractionType=t,n.close(e)}(this,"keydown"===r.type?"keyboard":"mouse"))})}close(t){this._result=t,this._containerInstance._animationStateChanged.pipe(yn(e=>"closing"===e.state),sn(1)).subscribe(e=>{this._beforeClosed.next(t),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),e.totalTime+100)}),this._state=1,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(t){let e=this._ref.config.positionStrategy;return t&&(t.left||t.right)?t.left?e.left(t.left):e.right(t.right):e.centerHorizontally(),t&&(t.top||t.bottom)?t.top?e.top(t.top):e.bottom(t.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(t="",e=""){return this._ref.updateSize(t,e),this}addPanelClass(t){return this._ref.addPanelClass(t),this}removePanelClass(t){return this._ref.removePanelClass(t),this}getState(){return this._state}_finishDialogClose(){this._state=2,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}const E$=new De("MatDialogData"),M$=new De("mat-dialog-default-options"),pk=new De("mat-dialog-scroll-strategy"),S$={provide:pk,deps:[Yi],useFactory:function x$(n){return()=>n.scrollStrategies.block()}};let k$=0,T$=(()=>{class n{constructor(e,i,r,s,o,a,l,c,d,f){this._overlay=e,this._defaultOptions=r,this._parentDialog=s,this._dialogRefConstructor=l,this._dialogContainerType=c,this._dialogDataToken=d,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new ue,this._afterOpenedAtThisLevel=new ue,this._idPrefix="mat-dialog-",this.afterAllClosed=_c(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qn(void 0))),this._scrollStrategy=a,this._dialog=i.get(fk)}get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}open(e,i){let r;(i=Object.assign(Object.assign({},this._defaultOptions||new yh),i)).id=i.id||`${this._idPrefix}${k$++}`,i.scrollStrategy=i.scrollStrategy||this._scrollStrategy();const s=this._dialog.open(e,Object.assign(Object.assign({},i),{positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:yh,useValue:i},{provide:vh,useValue:i}]},templateContext:()=>({dialogRef:r}),providers:(o,a,l)=>(r=new this._dialogRefConstructor(o,i,l),r.updatePosition(null==i?void 0:i.position),[{provide:this._dialogContainerType,useValue:l},{provide:this._dialogDataToken,useValue:a.data},{provide:this._dialogRefConstructor,useValue:r}])}));return r.componentInstance=s.componentInstance,this.openDialogs.push(r),this.afterOpened.next(r),r.afterClosed().subscribe(()=>{const o=this.openDialogs.indexOf(r);o>-1&&(this.openDialogs.splice(o,1),this.openDialogs.length||this._getAfterAllClosed().next())}),r}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(e){return this.openDialogs.find(i=>i.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(e){let i=e.length;for(;i--;)e[i].close()}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),A$=(()=>{class n extends T${constructor(e,i,r,s,o,a,l,c){super(e,i,s,a,l,o,C$,w$,E$,c)}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(Jt),te(Vl,8),te(M$,8),te(pk),te(n,12),te(ph),te(fn,8))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),I$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[A$,S$],imports:[_$,Pa,Os,ht,ht]}),n})();const R$=[[["","mat-grid-avatar",""],["","matGridAvatar",""]],[["","mat-line",""],["","matLine",""]],"*"],P$=["[mat-grid-avatar], [matGridAvatar]","[mat-line], [matLine]","*"];let F$=(()=>{class n{constructor(e){this._element=e}ngAfterContentInit(){!function TS(n,t,e="mat"){n.changes.pipe(Qn(n)).subscribe(({length:i})=>{hc(t,`${e}-2-line`,!1),hc(t,`${e}-3-line`,!1),hc(t,`${e}-multi-line`,!1),2===i||3===i?hc(t,`${e}-${i}-line`,!0):i>3&&hc(t,`${e}-multi-line`,!0)})}(this._lines,this._element)}}return n.\u0275fac=function(e){return new(e||n)(x(Je))},n.\u0275cmp=vt({type:n,selectors:[["mat-grid-tile-header"],["mat-grid-tile-footer"]],contentQueries:function(e,i,r){if(1&e&&It(r,kS,5),2&e){let s;Ge(s=We())&&(i._lines=s)}},ngContentSelectors:P$,decls:4,vars:0,consts:[[1,"mat-grid-list-text"]],template:function(e,i){1&e&&(Fn(R$),Tt(0),fe(1,"div",0),Tt(2,1),we(),Tt(3,2))},encapsulation:2,changeDetection:0}),n})(),L$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-grid-tile-header"]],hostAttrs:[1,"mat-grid-tile-header"]}),n})(),B$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rh,ht,rh,ht]}),n})();function La(n,t){const e=ut(n)?n:()=>n,i=r=>r.error(e());return new J(t?r=>t.schedule(i,0,r):i)}function os(n){return Pe((t,e)=>{let s,i=null,r=!1;i=t.subscribe(_e(e,void 0,void 0,o=>{s=di(n(o,os(n)(t))),i?(i.unsubscribe(),i=null,s.subscribe(e)):r=!0})),r&&(i.unsubscribe(),i=null,s.subscribe(e))})}function bh(n){return Pe((t,e)=>{try{t.subscribe(e)}finally{e.add(n)}})}const V$=["*"];let wh;function vc(n){var t;return(null===(t=function H$(){if(void 0===wh&&(wh=null,"undefined"!=typeof window)){const n=window;void 0!==n.trustedTypes&&(wh=n.trustedTypes.createPolicy("angular#components",{createHTML:t=>t}))}return wh}())||void 0===t?void 0:t.createHTML(n))||n}function gk(n){return Error(`Unable to find icon with the name "${n}"`)}function _k(n){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${n}".`)}function vk(n){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${n}".`)}class Co{constructor(t,e,i){this.url=t,this.svgText=e,this.options=i}}let Ch=(()=>{class n{constructor(e,i,r,s){this._httpClient=e,this._sanitizer=i,this._errorHandler=s,this._svgIconConfigs=new Map,this._iconSetConfigs=new Map,this._cachedIconsByUrl=new Map,this._inProgressUrlFetches=new Map,this._fontCssClassesByAlias=new Map,this._resolvers=[],this._defaultFontSetClass=["material-icons"],this._document=r}addSvgIcon(e,i,r){return this.addSvgIconInNamespace("",e,i,r)}addSvgIconLiteral(e,i,r){return this.addSvgIconLiteralInNamespace("",e,i,r)}addSvgIconInNamespace(e,i,r,s){return this._addSvgIconConfig(e,i,new Co(r,null,s))}addSvgIconResolver(e){return this._resolvers.push(e),this}addSvgIconLiteralInNamespace(e,i,r,s){const o=this._sanitizer.sanitize(Ut.HTML,r);if(!o)throw vk(r);const a=vc(o);return this._addSvgIconConfig(e,i,new Co("",a,s))}addSvgIconSet(e,i){return this.addSvgIconSetInNamespace("",e,i)}addSvgIconSetLiteral(e,i){return this.addSvgIconSetLiteralInNamespace("",e,i)}addSvgIconSetInNamespace(e,i,r){return this._addSvgIconSetConfig(e,new Co(i,null,r))}addSvgIconSetLiteralInNamespace(e,i,r){const s=this._sanitizer.sanitize(Ut.HTML,i);if(!s)throw vk(i);const o=vc(s);return this._addSvgIconSetConfig(e,new Co("",o,r))}registerFontClassAlias(e,i=e){return this._fontCssClassesByAlias.set(e,i),this}classNameForFontAlias(e){return this._fontCssClassesByAlias.get(e)||e}setDefaultFontSetClass(...e){return this._defaultFontSetClass=e,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(e){const i=this._sanitizer.sanitize(Ut.RESOURCE_URL,e);if(!i)throw _k(e);const r=this._cachedIconsByUrl.get(i);return r?tt(Dh(r)):this._loadSvgIconFromConfig(new Co(e,null)).pipe(wn(s=>this._cachedIconsByUrl.set(i,s)),U(s=>Dh(s)))}getNamedSvgIcon(e,i=""){const r=yk(i,e);let s=this._svgIconConfigs.get(r);if(s)return this._getSvgFromConfig(s);if(s=this._getIconConfigFromResolvers(i,e),s)return this._svgIconConfigs.set(r,s),this._getSvgFromConfig(s);const o=this._iconSetConfigs.get(i);return o?this._getSvgFromIconSetConfigs(e,o):La(gk(r))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(e){return e.svgText?tt(Dh(this._svgElementFromConfig(e))):this._loadSvgIconFromConfig(e).pipe(U(i=>Dh(i)))}_getSvgFromIconSetConfigs(e,i){const r=this._extractIconWithNameFromAnySet(e,i);return r?tt(r):kM(i.filter(o=>!o.svgText).map(o=>this._loadSvgIconSetFromConfig(o).pipe(os(a=>{const c=`Loading icon set URL: ${this._sanitizer.sanitize(Ut.RESOURCE_URL,o.url)} failed: ${a.message}`;return this._errorHandler.handleError(new Error(c)),tt(null)})))).pipe(U(()=>{const o=this._extractIconWithNameFromAnySet(e,i);if(!o)throw gk(e);return o}))}_extractIconWithNameFromAnySet(e,i){for(let r=i.length-1;r>=0;r--){const s=i[r];if(s.svgText&&s.svgText.toString().indexOf(e)>-1){const o=this._svgElementFromConfig(s),a=this._extractSvgIconFromSet(o,e,s.options);if(a)return a}}return null}_loadSvgIconFromConfig(e){return this._fetchIcon(e).pipe(wn(i=>e.svgText=i),U(()=>this._svgElementFromConfig(e)))}_loadSvgIconSetFromConfig(e){return e.svgText?tt(null):this._fetchIcon(e).pipe(wn(i=>e.svgText=i))}_extractSvgIconFromSet(e,i,r){const s=e.querySelector(`[id="${i}"]`);if(!s)return null;const o=s.cloneNode(!0);if(o.removeAttribute("id"),"svg"===o.nodeName.toLowerCase())return this._setSvgAttributes(o,r);if("symbol"===o.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement(o),r);const a=this._svgElementFromString(vc(""));return a.appendChild(o),this._setSvgAttributes(a,r)}_svgElementFromString(e){const i=this._document.createElement("DIV");i.innerHTML=e;const r=i.querySelector("svg");if(!r)throw Error(" tag not found");return r}_toSvgElement(e){const i=this._svgElementFromString(vc("")),r=e.attributes;for(let s=0;svc(d)),bh(()=>this._inProgressUrlFetches.delete(a)),dy());return this._inProgressUrlFetches.set(a,c),c}_addSvgIconConfig(e,i,r){return this._svgIconConfigs.set(yk(e,i),r),this}_addSvgIconSetConfig(e,i){const r=this._iconSetConfigs.get(e);return r?r.push(i):this._iconSetConfigs.set(e,[i]),this}_svgElementFromConfig(e){if(!e.svgElement){const i=this._svgElementFromString(e.svgText);this._setSvgAttributes(i,e.options),e.svgElement=i}return e.svgElement}_getIconConfigFromResolvers(e,i){for(let r=0;rt?t.pathname+t.search:""}}}),bk=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],Y$=bk.map(n=>`[${n}]`).join(", "),K$=/^url\(['"]?#(.*?)['"]?\)$/;let Eh=(()=>{class n extends $${constructor(e,i,r,s,o,a){super(e),this._iconRegistry=i,this._location=s,this._errorHandler=o,this._inline=!1,this._previousFontSetClass=[],this._currentIconFetch=X.EMPTY,a&&(a.color&&(this.color=this.defaultColor=a.color),a.fontSet&&(this.fontSet=a.fontSet)),r||e.nativeElement.setAttribute("aria-hidden","true")}get inline(){return this._inline}set inline(e){this._inline=rt(e)}get svgIcon(){return this._svgIcon}set svgIcon(e){e!==this._svgIcon&&(e?this._updateSvgIcon(e):this._svgIcon&&this._clearSvgElement(),this._svgIcon=e)}get fontSet(){return this._fontSet}set fontSet(e){const i=this._cleanupFontValue(e);i!==this._fontSet&&(this._fontSet=i,this._updateFontIconClasses())}get fontIcon(){return this._fontIcon}set fontIcon(e){const i=this._cleanupFontValue(e);i!==this._fontIcon&&(this._fontIcon=i,this._updateFontIconClasses())}_splitIconName(e){if(!e)return["",""];const i=e.split(":");switch(i.length){case 1:return["",i[0]];case 2:return i;default:throw Error(`Invalid icon name: "${e}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const e=this._elementsWithExternalReferences;if(e&&e.size){const i=this._location.getPathname();i!==this._previousPath&&(this._previousPath=i,this._prependPathToReferences(i))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(e){this._clearSvgElement();const i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(e),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(e)}_clearSvgElement(){const e=this._elementRef.nativeElement;let i=e.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();i--;){const r=e.childNodes[i];(1!==r.nodeType||"svg"===r.nodeName.toLowerCase())&&r.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const e=this._elementRef.nativeElement,i=(this.fontSet?[this._iconRegistry.classNameForFontAlias(this.fontSet)]:this._iconRegistry.getDefaultFontSetClass()).filter(r=>r.length>0);this._previousFontSetClass.forEach(r=>e.classList.remove(r)),i.forEach(r=>e.classList.add(r)),this._previousFontSetClass=i,this.fontIcon!==this._previousFontIconClass&&(this._previousFontIconClass&&e.classList.remove(this._previousFontIconClass),this.fontIcon&&e.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(e){return"string"==typeof e?e.trim().split(" ")[0]:e}_prependPathToReferences(e){const i=this._elementsWithExternalReferences;i&&i.forEach((r,s)=>{r.forEach(o=>{s.setAttribute(o.name,`url('${e}#${o.value}')`)})})}_cacheChildrenWithExternalReferences(e){const i=e.querySelectorAll(Y$),r=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let s=0;s{const a=i[s],l=a.getAttribute(o),c=l?l.match(K$):null;if(c){let d=r.get(a);d||(d=[],r.set(a,d)),d.push({name:o,value:c[1]})}})}_updateSvgIcon(e){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),e){const[i,r]=this._splitIconName(e);i&&(this._svgNamespace=i),r&&(this._svgName=r),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(r,i).pipe(sn(1)).subscribe(s=>this._setSvgElement(s),s=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${i}:${r}! ${s.message}`))})}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(Ch),ii("aria-hidden"),x(W$),x(qr),x(G$,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:7,hostBindings:function(e,i){2&e&&(wt("data-mat-icon-type",i._usingFontIcon()?"font":"svg")("data-mat-icon-name",i._svgName||i.fontIcon)("data-mat-icon-namespace",i._svgNamespace||i.fontSet),At("mat-icon-inline",i.inline)("mat-icon-no-color","primary"!==i.color&&"accent"!==i.color&&"warn"!==i.color))},inputs:{color:"color",inline:"inline",svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[Le],ngContentSelectors:V$,decls:1,vars:0,template:function(e,i){1&e&&(Fn(),Tt(0))},styles:[".mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0}),n})(),Q$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),Z$=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})(),h5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rh,Ta,ht,q_,pi,rh,ht,q_,Z$]}),n})();function Rr(n,t){return Pe((e,i)=>{let r=null,s=0,o=!1;const a=()=>o&&!r&&i.complete();e.subscribe(_e(i,l=>{null==r||r.unsubscribe();let c=0;const d=s++;di(n(l,d)).subscribe(r=_e(i,f=>i.next(t?t(l,f,d,c++):f),()=>{r=null,a()}))},()=>{o=!0,a()}))})}const f5=["trigger"],p5=["panel"];function m5(n,t){if(1&n&&(fe(0,"span",8),Ue(1),we()),2&n){const e=lt();Ee(1),Kn(e.placeholder)}}function g5(n,t){if(1&n&&(fe(0,"span",12),Ue(1),we()),2&n){const e=lt(2);Ee(1),Kn(e.triggerValue)}}function _5(n,t){1&n&&Tt(0,0,["*ngSwitchCase","true"])}function v5(n,t){1&n&&(fe(0,"span",9),it(1,g5,2,1,"span",10),it(2,_5,1,0,"ng-content",11),we()),2&n&&(Ae("ngSwitch",!!lt().customTrigger),Ee(2),Ae("ngSwitchCase",!0))}function y5(n,t){if(1&n){const e=ki();fe(0,"div",13)(1,"div",14,15),$e("@transformPanel.done",function(r){return Bn(e),Vn(lt()._panelDoneAnimatingStream.next(r.toState))})("keydown",function(r){return Bn(e),Vn(lt()._handleKeydown(r))}),Tt(3,1),we()()}if(2&n){const e=lt();Ae("@transformPanelWrap",void 0),Ee(1),om("mat-select-panel ",e._getPanelTheme(),""),Hi("transform-origin",e._transformOrigin)("font-size",e._triggerFontSize,"px"),Ae("ngClass",e.panelClass)("@transformPanel",e.multiple?"showing-multiple":"showing"),wt("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby())}}const b5=[[["mat-select-trigger"]],"*"],w5=["mat-select-trigger","*"],Ck={transformPanelWrap:jn("transformPanelWrap",[Wt("* => void",uu("@transformPanel",[du()],{optional:!0}))]),transformPanel:jn("transformPanel",[zt("void",Qe({transform:"scaleY(0.8)",minWidth:"100%",opacity:0})),zt("showing",Qe({opacity:1,minWidth:"calc(100% + 32px)",transform:"scaleY(1)"})),zt("showing-multiple",Qe({opacity:1,minWidth:"calc(100% + 64px)",transform:"scaleY(1)"})),Wt("void => *",Zt("120ms cubic-bezier(0, 0, 0.2, 1)")),Wt("* => void",Zt("100ms 25ms linear",Qe({opacity:0})))])};let Dk=0;const Mk=new De("mat-select-scroll-strategy"),M5=new De("MAT_SELECT_CONFIG"),x5={provide:Mk,deps:[Yi],useFactory:function E5(n){return()=>n.scrollStrategies.reposition()}};class S5{constructor(t,e){this.source=t,this.value=e}}const k5=Rs(yo(uc(SS(class{constructor(n,t,e,i,r){this._elementRef=n,this._defaultErrorStateMatcher=t,this._parentForm=e,this._parentFormGroup=i,this.ngControl=r,this.stateChanges=new ue}})))),T5=new De("MatSelectTrigger");let A5=(()=>{class n extends k5{constructor(e,i,r,s,o,a,l,c,d,f,w,k,j,K){var ae,ce,Te;super(o,s,l,c,f),this._viewportRuler=e,this._changeDetectorRef=i,this._ngZone=r,this._dir=a,this._parentFormField=d,this._liveAnnouncer=j,this._defaultOptions=K,this._panelOpen=!1,this._compareWith=(he,Oe)=>he===Oe,this._uid="mat-select-"+Dk++,this._triggerAriaLabelledBy=null,this._destroy=new ue,this._onChange=()=>{},this._onTouched=()=>{},this._valueId="mat-select-value-"+Dk++,this._panelDoneAnimatingStream=new ue,this._overlayPanelClass=(null===(ae=this._defaultOptions)||void 0===ae?void 0:ae.overlayPanelClass)||"",this._focused=!1,this.controlType="mat-select",this._multiple=!1,this._disableOptionCentering=null!==(Te=null===(ce=this._defaultOptions)||void 0===ce?void 0:ce.disableOptionCentering)&&void 0!==Te&&Te,this.ariaLabel="",this.optionSelectionChanges=_c(()=>{const he=this.options;return he?he.changes.pipe(Qn(he),Rr(()=>$n(...he.map(Oe=>Oe.onSelectionChange)))):this._ngZone.onStable.pipe(sn(1),Rr(()=>this.optionSelectionChanges))}),this.openedChange=new je,this._openedStream=this.openedChange.pipe(yn(he=>he),U(()=>{})),this._closedStream=this.openedChange.pipe(yn(he=>!he),U(()=>{})),this.selectionChange=new je,this.valueChange=new je,this.ngControl&&(this.ngControl.valueAccessor=this),null!=(null==K?void 0:K.typeaheadDebounceInterval)&&(this._typeaheadDebounceInterval=K.typeaheadDebounceInterval),this._scrollStrategyFactory=k,this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=parseInt(w)||0,this.id=this.id}get focused(){return this._focused||this._panelOpen}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}get required(){var e,i,r,s;return null!==(s=null!==(e=this._required)&&void 0!==e?e:null===(r=null===(i=this.ngControl)||void 0===i?void 0:i.control)||void 0===r?void 0:r.hasValidator(Vg.required))&&void 0!==s&&s}set required(e){this._required=rt(e),this.stateChanges.next()}get multiple(){return this._multiple}set multiple(e){this._multiple=rt(e)}get disableOptionCentering(){return this._disableOptionCentering}set disableOptionCentering(e){this._disableOptionCentering=rt(e)}get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e)}get typeaheadDebounceInterval(){return this._typeaheadDebounceInterval}set typeaheadDebounceInterval(e){this._typeaheadDebounceInterval=Ii(e)}get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next()}ngOnInit(){this._selectionModel=new ah(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(k_(),Ot(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen))}ngAfterContentInit(){this._initKeyManager(),this._selectionModel.changed.pipe(Ot(this._destroy)).subscribe(e=>{e.added.forEach(i=>i.select()),e.removed.forEach(i=>i.deselect())}),this.options.changes.pipe(Qn(null),Ot(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const e=this._getTriggerAriaLabelledby(),i=this.ngControl;if(e!==this._triggerAriaLabelledBy){const r=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?r.setAttribute("aria-labelledby",e):r.removeAttribute("aria-labelledby")}i&&(this._previousControl!==i.control&&(void 0!==this._previousControl&&null!==i.disabled&&i.disabled!==this.disabled&&(this.disabled=i.disabled),this._previousControl=i.control),this.updateErrorState())}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}ngOnDestroy(){this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck())}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}writeValue(e){this._assignValue(e)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){var e,i;return this.multiple?(null===(e=this._selectionModel)||void 0===e?void 0:e.selected)||[]:null===(i=this._selectionModel)||void 0===i?void 0:i.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const e=this._selectionModel.selected.map(i=>i.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e))}_handleClosedKeydown(e){const i=e.keyCode,r=40===i||38===i||37===i||39===i,s=13===i||32===i,o=this._keyManager;if(!o.isTyping()&&s&&!gi(e)||(this.multiple||e.altKey)&&r)e.preventDefault(),this.open();else if(!this.multiple){const a=this.selected;o.onKeydown(e);const l=this.selected;l&&a!==l&&this._liveAnnouncer.announce(l.viewValue,1e4)}}_handleOpenKeydown(e){const i=this._keyManager,r=e.keyCode,s=40===r||38===r,o=i.isTyping();if(s&&e.altKey)e.preventDefault(),this.close();else if(o||13!==r&&32!==r||!i.activeItem||gi(e))if(!o&&this._multiple&&65===r&&e.ctrlKey){e.preventDefault();const a=this.options.some(l=>!l.disabled&&!l.selected);this.options.forEach(l=>{l.disabled||(a?l.select():l.deselect())})}else{const a=i.activeItemIndex;i.onKeydown(e),this._multiple&&s&&e.shiftKey&&i.activeItem&&i.activeItemIndex!==a&&i.activeItem._selectViaInteraction()}else e.preventDefault(),i.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe(sn(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(e){if(this._selectionModel.selected.forEach(i=>i.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)Array.isArray(e),e.forEach(i=>this._selectOptionByValue(i)),this._sortValues();else{const i=this._selectOptionByValue(e);i?this._keyManager.updateActiveItem(i):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(e){const i=this.options.find(r=>{if(this._selectionModel.isSelected(r))return!1;try{return null!=r.value&&this._compareWith(r.value,e)}catch(s){return!1}});return i&&this._selectionModel.select(i),i}_assignValue(e){return!!(e!==this._value||this._multiple&&Array.isArray(e))&&(this.options&&this._setSelectionByValue(e),this._value=e,!0)}_initKeyManager(){this._keyManager=new Z3(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.pipe(Ot(this._destroy)).subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.pipe(Ot(this._destroy)).subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const e=$n(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Ot(e)).subscribe(i=>{this._onSelect(i.source,i.isUserInput),i.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),$n(...this.options.map(i=>i._stateChanges)).pipe(Ot(e)).subscribe(()=>{this._changeDetectorRef.markForCheck(),this.stateChanges.next()})}_onSelect(e,i){const r=this._selectionModel.isSelected(e);null!=e.value||this._multiple?(r!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),i&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),i&&this.focus())):(e.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(e.value)),r!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const e=this.options.toArray();this._selectionModel.sort((i,r)=>this.sortComparator?this.sortComparator(i,r,e):e.indexOf(i)-e.indexOf(r)),this.stateChanges.next()}}_propagateChanges(e){let i=null;i=this.multiple?this.selected.map(r=>r.value):this.selected?this.selected.value:e,this._value=i,this.valueChange.emit(i),this._onChange(i),this.selectionChange.emit(this._getChangeEvent(i)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}_canOpen(){var e;return!this._panelOpen&&!this.disabled&&(null===(e=this.options)||void 0===e?void 0:e.length)>0}focus(e){this._elementRef.nativeElement.focus(e)}_getPanelAriaLabelledby(){var e;if(this.ariaLabel)return null;const i=null===(e=this._parentFormField)||void 0===e?void 0:e.getLabelId();return this.ariaLabelledby?(i?i+" ":"")+this.ariaLabelledby:i}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){var e;if(this.ariaLabel)return null;const i=null===(e=this._parentFormField)||void 0===e?void 0:e.getLabelId();let r=(i?i+" ":"")+this._valueId;return this.ariaLabelledby&&(r+=" "+this.ariaLabelledby),r}_panelDoneAnimating(e){this.openedChange.emit(e)}setDescribedByIds(e){e.length?this._elementRef.nativeElement.setAttribute("aria-describedby",e.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this._panelOpen||!this.empty||this._focused&&!!this._placeholder}}return n.\u0275fac=function(e){return new(e||n)(x(ss),x(en),x(et),x(ih),x(Je),x(qi,8),x(Xl,8),x(Jl,8),x(Z_,8),x(Tr,10),ii("tabindex"),x(Mk),x(P_),x(M5,8))},n.\u0275dir=Me({type:n,viewQuery:function(e,i){if(1&e&&(Gt(f5,5),Gt(p5,5),Gt(ok,5)),2&e){let r;Ge(r=We())&&(i.trigger=r.first),Ge(r=We())&&(i.panel=r.first),Ge(r=We())&&(i._overlayDir=r.first)}},inputs:{userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",placeholder:"placeholder",required:"required",multiple:"multiple",disableOptionCentering:"disableOptionCentering",compareWith:"compareWith",value:"value",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:"typeaheadDebounceInterval",sortComparator:"sortComparator",id:"id"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},features:[Le,cn]}),n})(),xk=(()=>{class n extends A5{constructor(){super(...arguments),this._scrollTop=0,this._triggerFontSize=0,this._transformOrigin="top",this._offsetY=0,this._positions=[{originX:"start",originY:"top",overlayX:"start",overlayY:"top"},{originX:"start",originY:"bottom",overlayX:"start",overlayY:"bottom"}]}_calculateOverlayScroll(e,i,r){const s=this._getItemHeight();return Math.min(Math.max(0,s*e-i+s/2),r)}ngOnInit(){super.ngOnInit(),this._viewportRuler.change().pipe(Ot(this._destroy)).subscribe(()=>{this.panelOpen&&(this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._changeDetectorRef.markForCheck())})}open(){super._canOpen()&&(super.open(),this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._triggerFontSize=parseInt(getComputedStyle(this.trigger.nativeElement).fontSize||"0"),this._calculateOverlayPosition(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{this._triggerFontSize&&this._overlayDir.overlayRef&&this._overlayDir.overlayRef.overlayElement&&(this._overlayDir.overlayRef.overlayElement.style.fontSize=`${this._triggerFontSize}px`)}))}_scrollOptionIntoView(e){const i=LS(e,this.options,this.optionGroups),r=this._getItemHeight();this.panel.nativeElement.scrollTop=0===e&&1===i?0:function yz(n,t,e,i){return ne+i?Math.max(0,n-i+t):e}((e+i)*r,r,this.panel.nativeElement.scrollTop,256)}_positioningSettled(){this._calculateOverlayOffsetX(),this.panel.nativeElement.scrollTop=this._scrollTop}_panelDoneAnimating(e){this.panelOpen?this._scrollTop=0:(this._overlayDir.offsetX=0,this._changeDetectorRef.markForCheck()),super._panelDoneAnimating(e)}_getChangeEvent(e){return new S5(this,e)}_calculateOverlayOffsetX(){const e=this._overlayDir.overlayRef.overlayElement.getBoundingClientRect(),i=this._viewportRuler.getViewportSize(),r=this._isRtl(),s=this.multiple?56:32;let o;if(this.multiple)o=40;else if(this.disableOptionCentering)o=16;else{let c=this._selectionModel.selected[0]||this.options.first;o=c&&c.group?32:16}r||(o*=-1);const a=0-(e.left+o-(r?s:0)),l=e.right+o-i.width+(r?0:s);a>0?o+=a+8:l>0&&(o-=l+8),this._overlayDir.offsetX=Math.round(o),this._overlayDir.overlayRef.updatePosition()}_calculateOverlayOffsetY(e,i,r){const s=this._getItemHeight(),o=(s-this._triggerRect.height)/2,a=Math.floor(256/s);let l;return this.disableOptionCentering?0:(l=0===this._scrollTop?e*s:this._scrollTop===r?(e-(this._getItemCount()-a))*s+(s-(this._getItemCount()*s-256)%s):i-s/2,Math.round(-1*l-o))}_checkOverlayWithinViewport(e){const i=this._getItemHeight(),r=this._viewportRuler.getViewportSize(),s=this._triggerRect.top-8,o=r.height-this._triggerRect.bottom-8,a=Math.abs(this._offsetY),c=Math.min(this._getItemCount()*i,256)-a-this._triggerRect.height;c>o?this._adjustPanelUp(c,o):a>s?this._adjustPanelDown(a,s,e):this._transformOrigin=this._getOriginBasedOnOption()}_adjustPanelUp(e,i){const r=Math.round(e-i);this._scrollTop-=r,this._offsetY-=r,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop<=0&&(this._scrollTop=0,this._offsetY=0,this._transformOrigin="50% bottom 0px")}_adjustPanelDown(e,i,r){const s=Math.round(e-i);if(this._scrollTop+=s,this._offsetY+=s,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop>=r)return this._scrollTop=r,this._offsetY=0,void(this._transformOrigin="50% top 0px")}_calculateOverlayPosition(){const e=this._getItemHeight(),i=this._getItemCount(),r=Math.min(i*e,256),o=i*e-r;let a;a=this.empty?0:Math.max(this.options.toArray().indexOf(this._selectionModel.selected[0]),0),a+=LS(a,this.options,this.optionGroups);const l=r/2;this._scrollTop=this._calculateOverlayScroll(a,l,o),this._offsetY=this._calculateOverlayOffsetY(a,l,o),this._checkOverlayWithinViewport(o)}_getOriginBasedOnOption(){const e=this._getItemHeight(),i=(e-this._triggerRect.height)/2;return`50% ${Math.abs(this._offsetY)-i+e/2}px 0px`}_getItemHeight(){return 3*this._triggerFontSize}_getItemCount(){return this.options.length+this.optionGroups.length}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275cmp=vt({type:n,selectors:[["mat-select"]],contentQueries:function(e,i,r){if(1&e&&(It(r,T5,5),It(r,Y_,5),It(r,FS,5)),2&e){let s;Ge(s=We())&&(i.customTrigger=s.first),Ge(s=We())&&(i.options=s),Ge(s=We())&&(i.optionGroups=s)}},hostAttrs:["role","combobox","aria-autocomplete","none","aria-haspopup","true",1,"mat-select"],hostVars:19,hostBindings:function(e,i){1&e&&$e("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),2&e&&(wt("id",i.id)("tabindex",i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),At("mat-select-disabled",i.disabled)("mat-select-invalid",i.errorState)("mat-select-required",i.required)("mat-select-empty",i.empty)("mat-select-multiple",i.multiple))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matSelect"],features:[Xe([{provide:lh,useExisting:n},{provide:OS,useExisting:n}]),Le],ngContentSelectors:w5,decls:9,vars:12,consts:[["cdk-overlay-origin","",1,"mat-select-trigger",3,"click"],["origin","cdkOverlayOrigin","trigger",""],[1,"mat-select-value",3,"ngSwitch"],["class","mat-select-placeholder mat-select-min-line",4,"ngSwitchCase"],["class","mat-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-select-arrow-wrapper"],[1,"mat-select-arrow"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayMinWidth","cdkConnectedOverlayOffsetY","backdropClick","attach","detach"],[1,"mat-select-placeholder","mat-select-min-line"],[1,"mat-select-value-text",3,"ngSwitch"],["class","mat-select-min-line",4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-select-min-line"],[1,"mat-select-panel-wrap"],["role","listbox","tabindex","-1",3,"ngClass","keydown"],["panel",""]],template:function(e,i){if(1&e&&(Fn(b5),fe(0,"div",0,1),$e("click",function(){return i.toggle()}),fe(3,"div",2),it(4,m5,2,1,"span",3),it(5,v5,3,2,"span",4),we(),fe(6,"div",5),kt(7,"div",6),we()(),it(8,y5,4,14,"ng-template",7),$e("backdropClick",function(){return i.close()})("attach",function(){return i._onAttached()})("detach",function(){return i.close()})),2&e){const r=Js(1);wt("aria-owns",i.panelOpen?i.id+"-panel":null),Ee(3),Ae("ngSwitch",i.empty),wt("id",i._valueId),Ee(1),Ae("ngSwitchCase",!0),Ee(1),Ae("ngSwitchCase",!1),Ee(3),Ae("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",r)("cdkConnectedOverlayOpen",i.panelOpen)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayMinWidth",null==i._triggerRect?null:i._triggerRect.width)("cdkConnectedOverlayOffsetY",i._offsetY)}},dependencies:[eg,ba,iu,cE,ok,sk],styles:['.mat-select{display:inline-block;width:100%;outline:none}.mat-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-select-disabled .mat-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-select-arrow-wrapper{height:16px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-outline .mat-select-arrow-wrapper{transform:translateY(-25%)}.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:none}.mat-select-arrow{width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;margin:0 4px}.mat-form-field.mat-focused .mat-select-arrow{transform:translateX(0)}.mat-select-panel-wrap{flex-basis:100%}.mat-select-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;padding-top:0;padding-bottom:0;max-height:256px;min-width:100%;border-radius:4px;outline:0}.cdk-high-contrast-active .mat-select-panel{outline:solid 1px}.mat-select-panel .mat-optgroup-label,.mat-select-panel .mat-option{font-size:inherit;line-height:3em;height:3em}.mat-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-form-field-flex{cursor:pointer}.mat-form-field-type-mat-select .mat-form-field-label{width:calc(100% - 18px)}.mat-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}'],encapsulation:2,data:{animation:[Ck.transformPanelWrap,Ck.transformPanel]},changeDetection:0}),n})(),Sk=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[x5],imports:[pi,Pa,NS,ht,Sa,dh,NS,ht]}),n})();const O5={provide:new De("mat-tooltip-scroll-strategy"),deps:[Yi],useFactory:function P5(n){return()=>n.scrollStrategies.reposition({scrollThrottle:20})}};let kk=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[O5],imports:[Ku,pi,Pa,ht,ht,Sa]}),n})(),nv=(()=>{class n{constructor(){this.changes=new ue,this.itemsPerPageLabel="Items per page:",this.nextPageLabel="Next page",this.previousPageLabel="Previous page",this.firstPageLabel="First page",this.lastPageLabel="Last page",this.getRangeLabel=(e,i,r)=>{if(0==r||0==i)return`0 of ${r}`;const s=e*i;return`${s+1} \u2013 ${s<(r=Math.max(r,0))?Math.min(s+i,r):s+i} of ${r}`}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const H5={provide:nv,deps:[[new Hn,new ir,nv]],useFactory:function V5(n){return n||new nv}};let j5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[H5],imports:[pi,oh,Sk,kk,ht]}),n})();function U5(n,t){if(1&n&&(Ja(),kt(0,"circle",4)),2&n){const e=lt(),i=Js(1);Hi("animation-name","mat-progress-spinner-stroke-rotate-"+e._spinnerAnimationLabel)("stroke-dashoffset",e._getStrokeDashOffset(),"px")("stroke-dasharray",e._getStrokeCircumference(),"px")("stroke-width",e._getCircleStrokeWidth(),"%")("transform-origin",e._getCircleTransformOrigin(i)),wt("r",e._getCircleRadius())}}function z5(n,t){if(1&n&&(Ja(),kt(0,"circle",4)),2&n){const e=lt(),i=Js(1);Hi("stroke-dashoffset",e._getStrokeDashOffset(),"px")("stroke-dasharray",e._getStrokeCircumference(),"px")("stroke-width",e._getCircleStrokeWidth(),"%")("transform-origin",e._getCircleTransformOrigin(i)),wt("r",e._getCircleRadius())}}const G5=vo(class{constructor(n){this._elementRef=n}},"primary"),W5=new De("mat-progress-spinner-default-options",{providedIn:"root",factory:function q5(){return{diameter:100}}});class Fs extends G5{constructor(t,e,i,r,s,o,a,l){super(t),this._document=i,this._diameter=100,this._value=0,this._resizeSubscription=X.EMPTY,this.mode="determinate";const c=Fs._diameters;this._spinnerAnimationLabel=this._getSpinnerAnimationLabel(),c.has(i.head)||c.set(i.head,new Set([100])),this._noopAnimations="NoopAnimations"===r&&!!s&&!s._forceAnimations,"mat-spinner"===t.nativeElement.nodeName.toLowerCase()&&(this.mode="indeterminate"),s&&(s.color&&(this.color=this.defaultColor=s.color),s.diameter&&(this.diameter=s.diameter),s.strokeWidth&&(this.strokeWidth=s.strokeWidth)),e.isBrowser&&e.SAFARI&&a&&o&&l&&(this._resizeSubscription=a.change(150).subscribe(()=>{"indeterminate"===this.mode&&l.run(()=>o.markForCheck())}))}get diameter(){return this._diameter}set diameter(t){this._diameter=Ii(t),this._spinnerAnimationLabel=this._getSpinnerAnimationLabel(),this._styleRoot&&this._attachStyleNode()}get strokeWidth(){return this._strokeWidth||this.diameter/10}set strokeWidth(t){this._strokeWidth=Ii(t)}get value(){return"determinate"===this.mode?this._value:0}set value(t){this._value=Math.max(0,Math.min(100,Ii(t)))}ngOnInit(){const t=this._elementRef.nativeElement;this._styleRoot=ju(t)||this._document.head,this._attachStyleNode(),t.classList.add("mat-progress-spinner-indeterminate-animation")}ngOnDestroy(){this._resizeSubscription.unsubscribe()}_getCircleRadius(){return(this.diameter-10)/2}_getViewBox(){const t=2*this._getCircleRadius()+this.strokeWidth;return`0 0 ${t} ${t}`}_getStrokeCircumference(){return 2*Math.PI*this._getCircleRadius()}_getStrokeDashOffset(){return"determinate"===this.mode?this._getStrokeCircumference()*(100-this._value)/100:null}_getCircleStrokeWidth(){return this.strokeWidth/this.diameter*100}_getCircleTransformOrigin(t){var e;const i=50*(null!==(e=t.currentScale)&&void 0!==e?e:1);return`${i}% ${i}%`}_attachStyleNode(){const t=this._styleRoot,e=this._diameter,i=Fs._diameters;let r=i.get(t);if(!r||!r.has(e)){const s=this._document.createElement("style");s.setAttribute("mat-spinner-animation",this._spinnerAnimationLabel),s.textContent=this._getAnimationText(),t.appendChild(s),r||(r=new Set,i.set(t,r)),r.add(e)}}_getAnimationText(){const t=this._getStrokeCircumference();return"\n @keyframes mat-progress-spinner-stroke-rotate-DIAMETER {\n 0% { stroke-dashoffset: START_VALUE; transform: rotate(0); }\n 12.5% { stroke-dashoffset: END_VALUE; transform: rotate(0); }\n 12.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n 25% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n\n 25.0001% { stroke-dashoffset: START_VALUE; transform: rotate(270deg); }\n 37.5% { stroke-dashoffset: END_VALUE; transform: rotate(270deg); }\n 37.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n 50% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n\n 50.0001% { stroke-dashoffset: START_VALUE; transform: rotate(180deg); }\n 62.5% { stroke-dashoffset: END_VALUE; transform: rotate(180deg); }\n 62.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n 75% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n\n 75.0001% { stroke-dashoffset: START_VALUE; transform: rotate(90deg); }\n 87.5% { stroke-dashoffset: END_VALUE; transform: rotate(90deg); }\n 87.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n 100% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n }\n".replace(/START_VALUE/g,""+.95*t).replace(/END_VALUE/g,""+.2*t).replace(/DIAMETER/g,`${this._spinnerAnimationLabel}`)}_getSpinnerAnimationLabel(){return this.diameter.toString().replace(".","_")}}Fs._diameters=new WeakMap,Fs.\u0275fac=function(t){return new(t||Fs)(x(Je),x(bn),x(ct,8),x(fn,8),x(W5),x(en),x(ss),x(et))},Fs.\u0275cmp=vt({type:Fs,selectors:[["mat-progress-spinner"],["mat-spinner"]],hostAttrs:["role","progressbar","tabindex","-1",1,"mat-progress-spinner","mat-spinner"],hostVars:10,hostBindings:function(t,e){2&t&&(wt("aria-valuemin","determinate"===e.mode?0:null)("aria-valuemax","determinate"===e.mode?100:null)("aria-valuenow","determinate"===e.mode?e.value:null)("mode",e.mode),Hi("width",e.diameter,"px")("height",e.diameter,"px"),At("_mat-animation-noopable",e._noopAnimations))},inputs:{color:"color",diameter:"diameter",strokeWidth:"strokeWidth",mode:"mode",value:"value"},exportAs:["matProgressSpinner"],features:[Le],decls:4,vars:8,consts:[["preserveAspectRatio","xMidYMid meet","focusable","false","aria-hidden","true",3,"ngSwitch"],["svg",""],["cx","50%","cy","50%",3,"animation-name","stroke-dashoffset","stroke-dasharray","stroke-width","transform-origin",4,"ngSwitchCase"],["cx","50%","cy","50%",3,"stroke-dashoffset","stroke-dasharray","stroke-width","transform-origin",4,"ngSwitchCase"],["cx","50%","cy","50%"]],template:function(t,e){1&t&&(Ja(),fe(0,"svg",0,1),it(2,U5,1,11,"circle",2),it(3,z5,1,9,"circle",3),we()),2&t&&(Hi("width",e.diameter,"px")("height",e.diameter,"px"),Ae("ngSwitch","indeterminate"===e.mode),wt("viewBox",e._getViewBox()),Ee(2),Ae("ngSwitchCase",!0),Ee(1),Ae("ngSwitchCase",!1))},dependencies:[ba,iu],styles:[".mat-progress-spinner{display:block;position:relative;overflow:hidden}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:rgba(0,0,0,0);transition:stroke-dashoffset 225ms linear}.cdk-high-contrast-active .mat-progress-spinner circle{stroke:CanvasText}.mat-progress-spinner[mode=indeterminate] svg{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}.mat-progress-spinner[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}.mat-progress-spinner._mat-animation-noopable svg,.mat-progress-spinner._mat-animation-noopable circle{animation:none;transition:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}"],encapsulation:2,changeDetection:0});let K5=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,pi,ht]}),n})(),c4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Ta,ht,ht]}),n})(),b4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,ht]}),n})(),sv=(()=>{class n{constructor(){this.changes=new ue}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const C4={provide:sv,deps:[[new Hn,new ir,sv]],useFactory:function w4(n){return n||new sv}};let D4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({providers:[C4],imports:[pi,ht]}),n})(),B4=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[N_]}),n})(),t6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[B4,ht,ht]}),n})();const r6=["*"],s6=["tabListContainer"],o6=["tabList"],a6=["tabListInner"],l6=["nextPaginator"],c6=["previousPaginator"],f6=["mat-tab-nav-bar",""],p6=new De("MatInkBarPositioner",{providedIn:"root",factory:function m6(){return t=>({left:t?(t.offsetLeft||0)+"px":"0",width:t?(t.offsetWidth||0)+"px":"0"})}});let $k=(()=>{class n{constructor(e,i,r,s){this._elementRef=e,this._ngZone=i,this._inkBarPositioner=r,this._animationMode=s}alignToElement(e){this.show(),this._ngZone.onStable.pipe(sn(1)).subscribe(()=>{const i=this._inkBarPositioner(e),r=this._elementRef.nativeElement;r.style.left=i.left,r.style.width=i.width})}show(){this._elementRef.nativeElement.style.visibility="visible"}hide(){this._elementRef.nativeElement.style.visibility="hidden"}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(et),x(p6),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["mat-ink-bar"]],hostAttrs:[1,"mat-ink-bar"],hostVars:2,hostBindings:function(e,i){2&e&&At("_mat-animation-noopable","NoopAnimations"===i._animationMode)}}),n})();const Gk=Ar({passive:!0});let v6=(()=>{class n{constructor(e,i,r,s,o,a,l){this._elementRef=e,this._changeDetectorRef=i,this._viewportRuler=r,this._dir=s,this._ngZone=o,this._platform=a,this._animationMode=l,this._scrollDistance=0,this._selectedIndexChanged=!1,this._destroyed=new ue,this._showPaginationControls=!1,this._disableScrollAfter=!0,this._disableScrollBefore=!0,this._stopScrolling=new ue,this._disablePagination=!1,this._selectedIndex=0,this.selectFocusedIndex=new je,this.indexFocused=new je,o.runOutsideAngular(()=>{_o(e.nativeElement,"mouseleave").pipe(Ot(this._destroyed)).subscribe(()=>{this._stopInterval()})})}get disablePagination(){return this._disablePagination}set disablePagination(e){this._disablePagination=rt(e)}get selectedIndex(){return this._selectedIndex}set selectedIndex(e){e=Ii(e),this._selectedIndex!=e&&(this._selectedIndexChanged=!0,this._selectedIndex=e,this._keyManager&&this._keyManager.updateActiveItem(e))}ngAfterViewInit(){_o(this._previousPaginator.nativeElement,"touchstart",Gk).pipe(Ot(this._destroyed)).subscribe(()=>{this._handlePaginatorPress("before")}),_o(this._nextPaginator.nativeElement,"touchstart",Gk).pipe(Ot(this._destroyed)).subscribe(()=>{this._handlePaginatorPress("after")})}ngAfterContentInit(){const e=this._dir?this._dir.change:tt("ltr"),i=this._viewportRuler.change(150),r=()=>{this.updatePagination(),this._alignInkBarToSelectedTab()};this._keyManager=new Wu(this._items).withHorizontalOrientation(this._getLayoutDirection()).withHomeAndEnd().withWrap(),this._keyManager.updateActiveItem(this._selectedIndex),this._ngZone.onStable.pipe(sn(1)).subscribe(r),$n(e,i,this._items.changes,this._itemsResized()).pipe(Ot(this._destroyed)).subscribe(()=>{this._ngZone.run(()=>{Promise.resolve().then(()=>{this._scrollDistance=Math.max(0,Math.min(this._getMaxScrollDistance(),this._scrollDistance)),r()})}),this._keyManager.withHorizontalOrientation(this._getLayoutDirection())}),this._keyManager.change.pipe(Ot(this._destroyed)).subscribe(s=>{this.indexFocused.emit(s),this._setTabFocus(s)})}_itemsResized(){return"function"!=typeof ResizeObserver?Fi:this._items.changes.pipe(Qn(this._items),Rr(e=>new J(i=>this._ngZone.runOutsideAngular(()=>{const r=new ResizeObserver(()=>{i.next()});return e.forEach(s=>{r.observe(s.elementRef.nativeElement)}),()=>{r.disconnect()}}))),S_(1))}ngAfterContentChecked(){this._tabLabelCount!=this._items.length&&(this.updatePagination(),this._tabLabelCount=this._items.length,this._changeDetectorRef.markForCheck()),this._selectedIndexChanged&&(this._scrollToLabel(this._selectedIndex),this._checkScrollingControls(),this._alignInkBarToSelectedTab(),this._selectedIndexChanged=!1,this._changeDetectorRef.markForCheck()),this._scrollDistanceChanged&&(this._updateTabScrollPosition(),this._scrollDistanceChanged=!1,this._changeDetectorRef.markForCheck())}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete(),this._stopScrolling.complete()}_handleKeydown(e){if(!gi(e))switch(e.keyCode){case 13:case 32:this.focusIndex!==this.selectedIndex&&(this.selectFocusedIndex.emit(this.focusIndex),this._itemSelected(e));break;default:this._keyManager.onKeydown(e)}}_onContentChanges(){const e=this._elementRef.nativeElement.textContent;e!==this._currentTextContent&&(this._currentTextContent=e||"",this._ngZone.run(()=>{this.updatePagination(),this._alignInkBarToSelectedTab(),this._changeDetectorRef.markForCheck()}))}updatePagination(){this._checkPaginationEnabled(),this._checkScrollingControls(),this._updateTabScrollPosition()}get focusIndex(){return this._keyManager?this._keyManager.activeItemIndex:0}set focusIndex(e){!this._isValidIndex(e)||this.focusIndex===e||!this._keyManager||this._keyManager.setActiveItem(e)}_isValidIndex(e){if(!this._items)return!0;const i=this._items?this._items.toArray()[e]:null;return!!i&&!i.disabled}_setTabFocus(e){if(this._showPaginationControls&&this._scrollToLabel(e),this._items&&this._items.length){this._items.toArray()[e].focus();const i=this._tabListContainer.nativeElement;i.scrollLeft="ltr"==this._getLayoutDirection()?0:i.scrollWidth-i.offsetWidth}}_getLayoutDirection(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}_updateTabScrollPosition(){if(this.disablePagination)return;const e=this.scrollDistance,i="ltr"===this._getLayoutDirection()?-e:e;this._tabList.nativeElement.style.transform=`translateX(${Math.round(i)}px)`,(this._platform.TRIDENT||this._platform.EDGE)&&(this._tabListContainer.nativeElement.scrollLeft=0)}get scrollDistance(){return this._scrollDistance}set scrollDistance(e){this._scrollTo(e)}_scrollHeader(e){return this._scrollTo(this._scrollDistance+("before"==e?-1:1)*this._tabListContainer.nativeElement.offsetWidth/3)}_handlePaginatorClick(e){this._stopInterval(),this._scrollHeader(e)}_scrollToLabel(e){if(this.disablePagination)return;const i=this._items?this._items.toArray()[e]:null;if(!i)return;const r=this._tabListContainer.nativeElement.offsetWidth,{offsetLeft:s,offsetWidth:o}=i.elementRef.nativeElement;let a,l;"ltr"==this._getLayoutDirection()?(a=s,l=a+o):(l=this._tabListInner.nativeElement.offsetWidth-s,a=l-o);const c=this.scrollDistance,d=this.scrollDistance+r;ad&&(this.scrollDistance+=l-d+60)}_checkPaginationEnabled(){if(this.disablePagination)this._showPaginationControls=!1;else{const e=this._tabListInner.nativeElement.scrollWidth>this._elementRef.nativeElement.offsetWidth;e||(this.scrollDistance=0),e!==this._showPaginationControls&&this._changeDetectorRef.markForCheck(),this._showPaginationControls=e}}_checkScrollingControls(){this.disablePagination?this._disableScrollAfter=this._disableScrollBefore=!0:(this._disableScrollBefore=0==this.scrollDistance,this._disableScrollAfter=this.scrollDistance==this._getMaxScrollDistance(),this._changeDetectorRef.markForCheck())}_getMaxScrollDistance(){return this._tabListInner.nativeElement.scrollWidth-this._tabListContainer.nativeElement.offsetWidth||0}_alignInkBarToSelectedTab(){const e=this._items&&this._items.length?this._items.toArray()[this.selectedIndex]:null,i=e?e.elementRef.nativeElement:null;i?this._inkBar.alignToElement(i):this._inkBar.hide()}_stopInterval(){this._stopScrolling.next()}_handlePaginatorPress(e,i){i&&null!=i.button&&0!==i.button||(this._stopInterval(),F_(650,100).pipe(Ot($n(this._stopScrolling,this._destroyed))).subscribe(()=>{const{maxScrollDistance:r,distance:s}=this._scrollHeader(e);(0===s||s>=r)&&this._stopInterval()}))}_scrollTo(e){if(this.disablePagination)return{maxScrollDistance:0,distance:0};const i=this._getMaxScrollDistance();return this._scrollDistance=Math.max(0,Math.min(i,e)),this._scrollDistanceChanged=!0,this._checkScrollingControls(),{maxScrollDistance:i,distance:this._scrollDistance}}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(en),x(ss),x(qi,8),x(et),x(bn),x(fn,8))},n.\u0275dir=Me({type:n,inputs:{disablePagination:"disablePagination"}}),n})(),y6=0,qk=(()=>{class n extends v6{constructor(e,i,r,s,o,a,l){super(e,s,o,i,r,a,l),this._disableRipple=!1,this.color="primary"}get backgroundColor(){return this._backgroundColor}set backgroundColor(e){const i=this._elementRef.nativeElement.classList;i.remove(`mat-background-${this.backgroundColor}`),e&&i.add(`mat-background-${e}`),this._backgroundColor=e}get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=rt(e)}_itemSelected(){}ngAfterContentInit(){this._items.changes.pipe(Qn(null),Ot(this._destroyed)).subscribe(()=>{this.updateActiveLink()}),super.ngAfterContentInit()}updateActiveLink(){if(!this._items)return;const e=this._items.toArray();for(let i=0;i{class n extends qk{constructor(e,i,r,s,o,a,l){super(e,i,r,s,o,a,l)}}return n.\u0275fac=function(e){return new(e||n)(x(Je),x(qi,8),x(et),x(en),x(ss),x(bn),x(fn,8))},n.\u0275cmp=vt({type:n,selectors:[["","mat-tab-nav-bar",""]],contentQueries:function(e,i,r){if(1&e&&It(r,Kk,5),2&e){let s;Ge(s=We())&&(i._items=s)}},viewQuery:function(e,i){if(1&e&&(Gt($k,7),Gt(s6,7),Gt(o6,7),Gt(a6,7),Gt(l6,5),Gt(c6,5)),2&e){let r;Ge(r=We())&&(i._inkBar=r.first),Ge(r=We())&&(i._tabListContainer=r.first),Ge(r=We())&&(i._tabList=r.first),Ge(r=We())&&(i._tabListInner=r.first),Ge(r=We())&&(i._nextPaginator=r.first),Ge(r=We())&&(i._previousPaginator=r.first)}},hostAttrs:[1,"mat-tab-nav-bar","mat-tab-header"],hostVars:11,hostBindings:function(e,i){2&e&&(wt("role",i._getRole()),At("mat-tab-header-pagination-controls-enabled",i._showPaginationControls)("mat-tab-header-rtl","rtl"==i._getLayoutDirection())("mat-primary","warn"!==i.color&&"accent"!==i.color)("mat-accent","accent"===i.color)("mat-warn","warn"===i.color))},inputs:{color:"color"},exportAs:["matTabNavBar","matTabNav"],features:[Le],attrs:f6,ngContentSelectors:r6,decls:14,vars:10,consts:[["aria-hidden","true","type","button","mat-ripple","","tabindex","-1",1,"mat-tab-header-pagination","mat-tab-header-pagination-before","mat-elevation-z4",3,"matRippleDisabled","disabled","click","mousedown","touchend"],["previousPaginator",""],[1,"mat-tab-header-pagination-chevron"],[1,"mat-tab-link-container",3,"keydown"],["tabListContainer",""],[1,"mat-tab-list",3,"cdkObserveContent"],["tabList",""],[1,"mat-tab-links"],["tabListInner",""],["aria-hidden","true","type","button","mat-ripple","","tabindex","-1",1,"mat-tab-header-pagination","mat-tab-header-pagination-after","mat-elevation-z4",3,"matRippleDisabled","disabled","mousedown","click","touchend"],["nextPaginator",""]],template:function(e,i){1&e&&(Fn(),fe(0,"button",0,1),$e("click",function(){return i._handlePaginatorClick("before")})("mousedown",function(s){return i._handlePaginatorPress("before",s)})("touchend",function(){return i._stopInterval()}),kt(2,"div",2),we(),fe(3,"div",3,4),$e("keydown",function(s){return i._handleKeydown(s)}),fe(5,"div",5,6),$e("cdkObserveContent",function(){return i._onContentChanges()}),fe(7,"div",7,8),Tt(9),we(),kt(10,"mat-ink-bar"),we()(),fe(11,"button",9,10),$e("mousedown",function(s){return i._handlePaginatorPress("after",s)})("click",function(){return i._handlePaginatorClick("after")})("touchend",function(){return i._stopInterval()}),kt(13,"div",2),we()),2&e&&(At("mat-tab-header-pagination-disabled",i._disableScrollBefore),Ae("matRippleDisabled",i._disableScrollBefore||i.disableRipple)("disabled",i._disableScrollBefore||null),Ee(5),At("_mat-animation-noopable","NoopAnimations"===i._animationMode),Ee(6),At("mat-tab-header-pagination-disabled",i._disableScrollAfter),Ae("matRippleDisabled",i._disableScrollAfter||i.disableRipple)("disabled",i._disableScrollAfter||null))},dependencies:[Ps,T_,$k],styles:[".mat-tab-header{display:flex;overflow:hidden;position:relative;flex-shrink:0}.mat-tab-header-pagination{-webkit-user-select:none;user-select:none;position:relative;display:none;justify-content:center;align-items:center;min-width:32px;cursor:pointer;z-index:2;-webkit-tap-highlight-color:rgba(0,0,0,0);touch-action:none;box-sizing:content-box;background:none;border:none;outline:0;padding:0}.mat-tab-header-pagination::-moz-focus-inner{border:0}.mat-tab-header-pagination-controls-enabled .mat-tab-header-pagination{display:flex}.mat-tab-header-pagination-before,.mat-tab-header-rtl .mat-tab-header-pagination-after{padding-left:4px}.mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-rtl .mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(-135deg)}.mat-tab-header-rtl .mat-tab-header-pagination-before,.mat-tab-header-pagination-after{padding-right:4px}.mat-tab-header-rtl .mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(45deg)}.mat-tab-header-pagination-chevron{border-style:solid;border-width:2px 2px 0 0;height:8px;width:8px}.mat-tab-header-pagination-disabled{box-shadow:none;cursor:default}.mat-tab-list{flex-grow:1;position:relative;transition:transform 500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-tab-links{display:flex}[mat-align-tabs=center]>.mat-tab-link-container .mat-tab-links{justify-content:center}[mat-align-tabs=end]>.mat-tab-link-container .mat-tab-links{justify-content:flex-end}.mat-ink-bar{position:absolute;bottom:0;height:2px;transition:500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-ink-bar._mat-animation-noopable{transition:none !important;animation:none !important}.mat-tab-group-inverted-header .mat-ink-bar{bottom:auto;top:0}.cdk-high-contrast-active .mat-ink-bar{outline:solid 2px;height:0}.mat-tab-link-container{display:flex;flex-grow:1;overflow:hidden;z-index:1}.mat-tab-link{height:48px;padding:0 24px;cursor:pointer;box-sizing:border-box;opacity:.6;min-width:160px;text-align:center;display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;vertical-align:top;text-decoration:none;position:relative;overflow:hidden;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-tab-link:focus{outline:none}.mat-tab-link:focus:not(.mat-tab-disabled){opacity:1}.cdk-high-contrast-active .mat-tab-link:focus{outline:dotted 2px;outline-offset:-2px}.mat-tab-link.mat-tab-disabled{cursor:default}.cdk-high-contrast-active .mat-tab-link.mat-tab-disabled{opacity:.5}.mat-tab-link .mat-tab-label-content{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap}.cdk-high-contrast-active .mat-tab-link{opacity:1}[mat-stretch-tabs] .mat-tab-link{flex-basis:0;flex-grow:1}.mat-tab-link.mat-tab-disabled{pointer-events:none}@media(max-width: 599px){.mat-tab-link{min-width:72px}}"],encapsulation:2}),n})();const b6=yo(Rs(uc(class{})));let w6=(()=>{class n extends b6{constructor(e,i,r,s,o,a){super(),this._tabNavBar=e,this.elementRef=i,this._focusMonitor=o,this._isActive=!1,this.id="mat-tab-link-"+y6++,this.rippleConfig=r||{},this.tabIndex=parseInt(s)||0,"NoopAnimations"===a&&(this.rippleConfig.animation={enterDuration:0,exitDuration:0})}get active(){return this._isActive}set active(e){const i=rt(e);i!==this._isActive&&(this._isActive=i,this._tabNavBar.updateActiveLink())}get rippleDisabled(){return this.disabled||this.disableRipple||this._tabNavBar.disableRipple||!!this.rippleConfig.disabled}focus(){this.elementRef.nativeElement.focus()}ngAfterViewInit(){this._focusMonitor.monitor(this.elementRef)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this.elementRef)}_handleFocus(){this._tabNavBar.focusIndex=this._tabNavBar._items.toArray().indexOf(this)}_handleKeydown(e){this._tabNavBar.tabPanel&&32===e.keyCode&&this.elementRef.nativeElement.click()}_getAriaControls(){var e;return this._tabNavBar.tabPanel?null===(e=this._tabNavBar.tabPanel)||void 0===e?void 0:e.id:this.elementRef.nativeElement.getAttribute("aria-controls")}_getAriaSelected(){return this._tabNavBar.tabPanel?this.active?"true":"false":this.elementRef.nativeElement.getAttribute("aria-selected")}_getAriaCurrent(){return this.active&&!this._tabNavBar.tabPanel?"page":null}_getRole(){return this._tabNavBar.tabPanel?"tab":this.elementRef.nativeElement.getAttribute("role")}_getTabIndex(){return this._tabNavBar.tabPanel?this._isActive&&!this.disabled?0:-1:this.tabIndex}}return n.\u0275fac=function(e){return new(e||n)(x(qk),x(Je),x(sh,8),ii("tabindex"),x(hr),x(fn,8))},n.\u0275dir=Me({type:n,inputs:{active:"active",id:"id"},features:[Le]}),n})(),Kk=(()=>{class n extends w6{constructor(e,i,r,s,o,a,l,c){super(e,i,o,a,l,c),this._tabLinkRipple=new W_(this,r,i,s),this._tabLinkRipple.setupTriggerEvents(i.nativeElement)}ngOnDestroy(){super.ngOnDestroy(),this._tabLinkRipple._removeTriggerEvents()}}return n.\u0275fac=function(e){return new(e||n)(x(Yk),x(Je),x(et),x(bn),x(sh,8),ii("tabindex"),x(hr),x(fn,8))},n.\u0275dir=Me({type:n,selectors:[["","mat-tab-link",""],["","matTabLink",""]],hostAttrs:[1,"mat-tab-link","mat-focus-indicator"],hostVars:11,hostBindings:function(e,i){1&e&&$e("focus",function(){return i._handleFocus()})("keydown",function(s){return i._handleKeydown(s)}),2&e&&(wt("aria-controls",i._getAriaControls())("aria-current",i._getAriaCurrent())("aria-disabled",i.disabled)("aria-selected",i._getAriaSelected())("id",i.id)("tabIndex",i._getTabIndex())("role",i._getRole()),At("mat-tab-disabled",i.disabled)("mat-tab-label-active",i.active))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matTabLink"],features:[Le]}),n})(),C6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,Os,Ta,Gu,Ku,ht]}),n})(),D6=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[ht,ht]}),n})();function gv(...n){const t=qa(n),e=oy(n),{args:i,keys:r}=xM(n);if(0===i.length)return gn([],t);const s=new J(function E6(n,t,e=N){return i=>{Qk(t,()=>{const{length:r}=n,s=new Array(r);let o=r,a=r;for(let l=0;l{const c=gn(n[l],t);let d=!1;c.subscribe(_e(i,f=>{s[l]=f,d||(d=!0,a--),a||i.next(e(s.slice()))},()=>{--o||i.complete()}))},i)},i)}}(i,t,r?o=>SM(r,o):N));return e?s.pipe(Ng(e)):s}function Qk(n,t,e){n?jr(e,n,t):t()}const Zk=new Set;let ja,M6=(()=>{class n{constructor(e){this._platform=e,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):S6}matchMedia(e){return(this._platform.WEBKIT||this._platform.BLINK)&&function x6(n){if(!Zk.has(n))try{ja||(ja=document.createElement("style"),ja.setAttribute("type","text/css"),document.head.appendChild(ja)),ja.sheet&&(ja.sheet.insertRule(`@media ${n} {body{ }}`,0),Zk.add(n))}catch(t){console.error(t)}}(e),this._matchMedia(e)}}return n.\u0275fac=function(e){return new(e||n)(te(bn))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function S6(n){return{matches:"all"===n||""===n,media:n,addListener:()=>{},removeListener:()=>{}}}let _v=(()=>{class n{constructor(e,i){this._mediaMatcher=e,this._zone=i,this._queries=new Map,this._destroySubject=new ue}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(e){return Xk(Uu(e)).some(r=>this._registerQuery(r).mql.matches)}observe(e){let s=gv(Xk(Uu(e)).map(o=>this._registerQuery(o).observable));return s=nh(s.pipe(sn(1)),s.pipe(S_(1),x_(0))),s.pipe(U(o=>{const a={matches:!1,breakpoints:{}};return o.forEach(({matches:l,query:c})=>{a.matches=a.matches||l,a.breakpoints[c]=l}),a}))}_registerQuery(e){if(this._queries.has(e))return this._queries.get(e);const i=this._mediaMatcher.matchMedia(e),s={observable:new J(o=>{const a=l=>this._zone.run(()=>o.next(l));return i.addListener(a),()=>{i.removeListener(a)}}).pipe(Qn(i),U(({matches:o})=>({query:e,matches:o})),Ot(this._destroySubject)),mql:i};return this._queries.set(e,s),s}}return n.\u0275fac=function(e){return new(e||n)(te(M6),te(et))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Xk(n){return n.map(t=>t.split(",")).reduce((t,e)=>t.concat(e)).map(t=>t.trim())}function T6(n,t){if(1&n){const e=ki();fe(0,"div",2)(1,"button",3),$e("click",function(){return Bn(e),Vn(lt().action())}),Ue(2),we()()}if(2&n){const e=lt();Ee(2),Kn(e.data.action)}}function A6(n,t){}const Jk=new De("MatSnackBarData");class Fh{constructor(){this.politeness="assertive",this.announcementMessage="",this.duration=0,this.data=null,this.horizontalPosition="center",this.verticalPosition="bottom"}}const I6=Math.pow(2,31)-1;class vv{constructor(t,e){this._overlayRef=e,this._afterDismissed=new ue,this._afterOpened=new ue,this._onAction=new ue,this._dismissedByAction=!1,this.containerInstance=t,t._onExit.subscribe(()=>this._finishDismiss())}dismiss(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}dismissWithAction(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete(),this.dismiss()),clearTimeout(this._durationTimeoutId)}closeWithAction(){this.dismissWithAction()}_dismissAfter(t){this._durationTimeoutId=setTimeout(()=>this.dismiss(),Math.min(t,I6))}_open(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}_finishDismiss(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}afterDismissed(){return this._afterDismissed}afterOpened(){return this.containerInstance._onEnter}onAction(){return this._onAction}}let R6=(()=>{class n{constructor(e,i){this.snackBarRef=e,this.data=i}action(){this.snackBarRef.dismissWithAction()}get hasAction(){return!!this.data.action}}return n.\u0275fac=function(e){return new(e||n)(x(vv),x(Jk))},n.\u0275cmp=vt({type:n,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-simple-snackbar"],decls:3,vars:2,consts:[[1,"mat-simple-snack-bar-content"],["class","mat-simple-snackbar-action",4,"ngIf"],[1,"mat-simple-snackbar-action"],["mat-button","",3,"click"]],template:function(e,i){1&e&&(fe(0,"span",0),Ue(1),we(),it(2,T6,3,1,"div",1)),2&e&&(Ee(1),Kn(i.data.message),Ee(1),Ae("ngIf",i.hasAction))},dependencies:[zi,Aa],styles:[".mat-simple-snackbar{display:flex;justify-content:space-between;align-items:center;line-height:20px;opacity:1}.mat-simple-snackbar-action{flex-shrink:0;margin:-8px -8px -8px 8px}.mat-simple-snackbar-action button{max-height:36px;min-width:0}[dir=rtl] .mat-simple-snackbar-action{margin-left:-8px;margin-right:8px}.mat-simple-snack-bar-content{overflow:hidden;text-overflow:ellipsis}"],encapsulation:2,changeDetection:0}),n})();const P6={snackBarState:jn("state",[zt("void, hidden",Qe({transform:"scale(0.8)",opacity:0})),zt("visible",Qe({transform:"scale(1)",opacity:1})),Wt("* => visible",Zt("150ms cubic-bezier(0, 0, 0.2, 1)")),Wt("* => void, * => hidden",Zt("75ms cubic-bezier(0.4, 0.0, 1, 1)",Qe({opacity:0})))])};let O6=(()=>{class n extends hh{constructor(e,i,r,s,o){super(),this._ngZone=e,this._elementRef=i,this._changeDetectorRef=r,this._platform=s,this.snackBarConfig=o,this._announceDelay=150,this._destroyed=!1,this._onAnnounce=new ue,this._onExit=new ue,this._onEnter=new ue,this._animationState="void",this.attachDomPortal=a=>{this._assertNotAttached();const l=this._portalOutlet.attachDomPortal(a);return this._afterPortalAttached(),l},this._live="assertive"!==o.politeness||o.announcementMessage?"off"===o.politeness?"off":"polite":"assertive",this._platform.FIREFOX&&("polite"===this._live&&(this._role="status"),"assertive"===this._live&&(this._role="alert"))}attachComponentPortal(e){this._assertNotAttached();const i=this._portalOutlet.attachComponentPortal(e);return this._afterPortalAttached(),i}attachTemplatePortal(e){this._assertNotAttached();const i=this._portalOutlet.attachTemplatePortal(e);return this._afterPortalAttached(),i}onAnimationEnd(e){const{fromState:i,toState:r}=e;if(("void"===r&&"void"!==i||"hidden"===r)&&this._completeExit(),"visible"===r){const s=this._onEnter;this._ngZone.run(()=>{s.next(),s.complete()})}}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges(),this._screenReaderAnnounce())}exit(){return this._ngZone.run(()=>{this._animationState="hidden",this._elementRef.nativeElement.setAttribute("mat-exit",""),clearTimeout(this._announceTimeoutId)}),this._onExit}ngOnDestroy(){this._destroyed=!0,this._completeExit()}_completeExit(){this._ngZone.onMicrotaskEmpty.pipe(sn(1)).subscribe(()=>{this._ngZone.run(()=>{this._onExit.next(),this._onExit.complete()})})}_afterPortalAttached(){const e=this._elementRef.nativeElement,i=this.snackBarConfig.panelClass;i&&(Array.isArray(i)?i.forEach(r=>e.classList.add(r)):e.classList.add(i))}_assertNotAttached(){this._portalOutlet.hasAttached()}_screenReaderAnnounce(){this._announceTimeoutId||this._ngZone.runOutsideAngular(()=>{this._announceTimeoutId=setTimeout(()=>{const e=this._elementRef.nativeElement.querySelector("[aria-hidden]"),i=this._elementRef.nativeElement.querySelector("[aria-live]");if(e&&i){let r=null;this._platform.isBrowser&&document.activeElement instanceof HTMLElement&&e.contains(document.activeElement)&&(r=document.activeElement),e.removeAttribute("aria-hidden"),i.appendChild(e),null==r||r.focus(),this._onAnnounce.next(),this._onAnnounce.complete()}},this._announceDelay)})}}return n.\u0275fac=function(e){return new(e||n)(x(et),x(Je),x(en),x(bn),x(Fh))},n.\u0275dir=Me({type:n,viewQuery:function(e,i){if(1&e&&Gt(Ra,7),2&e){let r;Ge(r=We())&&(i._portalOutlet=r.first)}},features:[Le]}),n})(),F6=(()=>{class n extends O6{_afterPortalAttached(){super._afterPortalAttached(),"center"===this.snackBarConfig.horizontalPosition&&this._elementRef.nativeElement.classList.add("mat-snack-bar-center"),"top"===this.snackBarConfig.verticalPosition&&this._elementRef.nativeElement.classList.add("mat-snack-bar-top")}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275cmp=vt({type:n,selectors:[["snack-bar-container"]],hostAttrs:[1,"mat-snack-bar-container"],hostVars:1,hostBindings:function(e,i){1&e&&kd("@state.done",function(s){return i.onAnimationEnd(s)}),2&e&&Id("@state",i._animationState)},features:[Le],decls:3,vars:2,consts:[["aria-hidden","true"],["cdkPortalOutlet",""]],template:function(e,i){1&e&&(fe(0,"div",0),it(1,A6,0,0,"ng-template",1),we(),kt(2,"div")),2&e&&(Ee(2),wt("aria-live",i._live)("role",i._role))},dependencies:[Ra],styles:[".mat-snack-bar-container{border-radius:4px;box-sizing:border-box;display:block;margin:24px;max-width:33vw;min-width:344px;padding:14px 16px;min-height:48px;transform-origin:center}.cdk-high-contrast-active .mat-snack-bar-container{border:solid 1px}.mat-snack-bar-handset{width:100%}.mat-snack-bar-handset .mat-snack-bar-container{margin:8px;max-width:100%;min-width:0;width:100%}"],encapsulation:2,data:{animation:[P6.snackBarState]}}),n})(),eT=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[Pa,Os,pi,oh,ht,ht]}),n})();const tT=new De("mat-snack-bar-default-options",{providedIn:"root",factory:function L6(){return new Fh}});let N6=(()=>{class n{constructor(e,i,r,s,o,a){this._overlay=e,this._live=i,this._injector=r,this._breakpointObserver=s,this._parentSnackBar=o,this._defaultConfig=a,this._snackBarRefAtThisLevel=null}get _openedSnackBarRef(){const e=this._parentSnackBar;return e?e._openedSnackBarRef:this._snackBarRefAtThisLevel}set _openedSnackBarRef(e){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=e:this._snackBarRefAtThisLevel=e}openFromComponent(e,i){return this._attach(e,i)}openFromTemplate(e,i){return this._attach(e,i)}open(e,i="",r){const s=Object.assign(Object.assign({},this._defaultConfig),r);return s.data={message:e,action:i},s.announcementMessage===e&&(s.announcementMessage=void 0),this.openFromComponent(this.simpleSnackBarComponent,s)}dismiss(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}ngOnDestroy(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}_attachSnackBarContainer(e,i){const s=Jt.create({parent:i&&i.viewContainerRef&&i.viewContainerRef.injector||this._injector,providers:[{provide:Fh,useValue:i}]}),o=new pc(this.snackBarContainerComponent,i.viewContainerRef,s),a=e.attach(o);return a.instance.snackBarConfig=i,a.instance}_attach(e,i){const r=Object.assign(Object.assign(Object.assign({},new Fh),this._defaultConfig),i),s=this._createOverlay(r),o=this._attachSnackBarContainer(s,r),a=new vv(o,s);if(e instanceof _n){const l=new mc(e,null,{$implicit:r.data,snackBarRef:a});a.instance=o.attachTemplatePortal(l)}else{const l=this._createInjector(r,a),c=new pc(e,void 0,l),d=o.attachComponentPortal(c);a.instance=d.instance}return this._breakpointObserver.observe("(max-width: 599.98px) and (orientation: portrait)").pipe(Ot(s.detachments())).subscribe(l=>{s.overlayElement.classList.toggle(this.handsetCssClass,l.matches)}),r.announcementMessage&&o._onAnnounce.subscribe(()=>{this._live.announce(r.announcementMessage,r.politeness)}),this._animateSnackBar(a,r),this._openedSnackBarRef=a,this._openedSnackBarRef}_animateSnackBar(e,i){e.afterDismissed().subscribe(()=>{this._openedSnackBarRef==e&&(this._openedSnackBarRef=null),i.announcementMessage&&this._live.clear()}),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe(()=>{e.containerInstance.enter()}),this._openedSnackBarRef.dismiss()):e.containerInstance.enter(),i.duration&&i.duration>0&&e.afterOpened().subscribe(()=>e._dismissAfter(i.duration))}_createOverlay(e){const i=new fh;i.direction=e.direction;let r=this._overlay.position().global();const s="rtl"===e.direction,o="left"===e.horizontalPosition||"start"===e.horizontalPosition&&!s||"end"===e.horizontalPosition&&s,a=!o&&"center"!==e.horizontalPosition;return o?r.left("0"):a?r.right("0"):r.centerHorizontally(),"top"===e.verticalPosition?r.top("0"):r.bottom("0"),i.positionStrategy=r,this._overlay.create(i)}_createInjector(e,i){return Jt.create({parent:e&&e.viewContainerRef&&e.viewContainerRef.injector||this._injector,providers:[{provide:vv,useValue:i},{provide:Jk,useValue:e.data}]})}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(P_),te(Jt),te(_v),te(n,12),te(tT))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),B6=(()=>{class n extends N6{constructor(e,i,r,s,o,a){super(e,i,r,s,o,a),this.simpleSnackBarComponent=R6,this.snackBarContainerComponent=F6,this.handsetCssClass="mat-snack-bar-handset"}}return n.\u0275fac=function(e){return new(e||n)(te(Yi),te(P_),te(Jt),te(_v),te(n,12),te(tT))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:eT}),n})();const Dc=Br(n=>function(){n(this),this.name="EmptyError",this.message="no elements in sequence"});function Lh(){return Pe((n,t)=>{let e=null;n._refCount++;const i=_e(t,void 0,void 0,void 0,()=>{if(!n||n._refCount<=0||0<--n._refCount)return void(e=null);const r=n._connection,s=e;e=null,r&&(!s||r===s)&&r.unsubscribe(),t.unsubscribe()});n.subscribe(i),i.closed||(e=n.connect())})}class yv extends J{constructor(t,e){super(),this.source=t,this.subjectFactory=e,this._subject=null,this._refCount=0,this._connection=null,Ne(t)&&(this.lift=t.lift)}_subscribe(t){return this.getSubject().subscribe(t)}getSubject(){const t=this._subject;return(!t||t.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;const{_connection:t}=this;this._subject=this._connection=null,null==t||t.unsubscribe()}connect(){let t=this._connection;if(!t){t=this._connection=new X;const e=this.getSubject();t.add(this.source.subscribe(_e(e,void 0,()=>{this._teardown(),e.complete()},i=>{this._teardown(),e.error(i)},()=>this._teardown()))),t.closed&&(this._connection=null,t=X.EMPTY)}return t}refCount(){return Lh()(this)}}function V6(n,t,e,i,r){return(s,o)=>{let a=e,l=t,c=0;s.subscribe(_e(o,d=>{const f=c++;l=a?n(l,d,f):(a=!0,d),i&&o.next(l)},r&&(()=>{a&&o.next(l),o.complete()})))}}function nT(n,t){return Pe(V6(n,t,arguments.length>=2,!0))}function bv(n){return n<=0?()=>Fi:Pe((t,e)=>{let i=[];t.subscribe(_e(e,r=>{i.push(r),n{for(const r of i)e.next(r);e.complete()},void 0,()=>{i=null}))})}function iT(n=H6){return Pe((t,e)=>{let i=!1;t.subscribe(_e(e,r=>{i=!0,e.next(r)},()=>i?e.complete():e.error(n())))})}function H6(){return new Dc}function wv(n){return Pe((t,e)=>{let i=!1;t.subscribe(_e(e,r=>{i=!0,e.next(r)},()=>{i||e.next(n),e.complete()}))})}function Do(n,t){const e=arguments.length>=2;return i=>i.pipe(n?yn((r,s)=>n(r,s,i)):N,sn(1),e?wv(t):iT(()=>new Dc))}class cs{constructor(t,e){this.id=t,this.url=e}}class Cv extends cs{constructor(t,e,i="imperative",r=null){super(t,e),this.type=0,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class Ec extends cs{constructor(t,e,i){super(t,e),this.urlAfterRedirects=i,this.type=1}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}class rT extends cs{constructor(t,e,i){super(t,e),this.reason=i,this.type=2}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class z6 extends cs{constructor(t,e,i){super(t,e),this.error=i,this.type=3}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class $6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=4}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class G6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=7}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class W6 extends cs{constructor(t,e,i,r,s){super(t,e),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=8}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class q6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=5}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Y6 extends cs{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=6}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class K6{constructor(t){this.route=t,this.type=9}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class Q6{constructor(t){this.route=t,this.type=10}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class Z6{constructor(t){this.snapshot=t,this.type=11}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class X6{constructor(t){this.snapshot=t,this.type=12}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class J6{constructor(t){this.snapshot=t,this.type=13}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class eG{constructor(t){this.snapshot=t,this.type=14}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class sT{constructor(t,e,i){this.routerEvent=t,this.position=e,this.anchor=i,this.type=15}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}const Et="primary";class tG{constructor(t){this.params=t||{}}has(t){return Object.prototype.hasOwnProperty.call(this.params,t)}get(t){if(this.has(t)){const e=this.params[t];return Array.isArray(e)?e[0]:e}return null}getAll(t){if(this.has(t)){const e=this.params[t];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}}function Ua(n){return new tG(n)}const oT="ngNavigationCancelingError";function Dv(n){const t=Error("NavigationCancelingError: "+n);return t[oT]=!0,t}function iG(n,t,e){const i=e.path.split("/");if(i.length>n.length||"full"===e.pathMatch&&(t.hasChildren()||i.lengthi[s]===r)}return n===t}function lT(n){return Array.prototype.concat.apply([],n)}function cT(n){return n.length>0?n[n.length-1]:null}function Un(n,t){for(const e in n)n.hasOwnProperty(e)&&t(n[e],e)}function fr(n){return em(n)?n:Cl(n)?gn(Promise.resolve(n)):tt(n)}const oG={exact:function hT(n,t,e){if(!Mo(n.segments,t.segments)||!Nh(n.segments,t.segments,e)||n.numberOfChildren!==t.numberOfChildren)return!1;for(const i in t.children)if(!n.children[i]||!hT(n.children[i],t.children[i],e))return!1;return!0},subset:fT},dT={exact:function aG(n,t){return Pr(n,t)},subset:function lG(n,t){return Object.keys(t).length<=Object.keys(n).length&&Object.keys(t).every(e=>aT(n[e],t[e]))},ignored:()=>!0};function uT(n,t,e){return oG[e.paths](n.root,t.root,e.matrixParams)&&dT[e.queryParams](n.queryParams,t.queryParams)&&!("exact"===e.fragment&&n.fragment!==t.fragment)}function fT(n,t,e){return pT(n,t,t.segments,e)}function pT(n,t,e,i){if(n.segments.length>e.length){const r=n.segments.slice(0,e.length);return!(!Mo(r,e)||t.hasChildren()||!Nh(r,e,i))}if(n.segments.length===e.length){if(!Mo(n.segments,e)||!Nh(n.segments,e,i))return!1;for(const r in t.children)if(!n.children[r]||!fT(n.children[r],t.children[r],i))return!1;return!0}{const r=e.slice(0,n.segments.length),s=e.slice(n.segments.length);return!!(Mo(n.segments,r)&&Nh(n.segments,r,i)&&n.children[Et])&&pT(n.children[Et],t,s,i)}}function Nh(n,t,e){return t.every((i,r)=>dT[e](n[r].parameters,i.parameters))}class Eo{constructor(t,e,i){this.root=t,this.queryParams=e,this.fragment=i}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Ua(this.queryParams)),this._queryParamMap}toString(){return uG.serialize(this)}}class Pt{constructor(t,e){this.segments=t,this.children=e,this.parent=null,Un(e,(i,r)=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Bh(this)}}class Mc{constructor(t,e){this.path=t,this.parameters=e}get parameterMap(){return this._parameterMap||(this._parameterMap=Ua(this.parameters)),this._parameterMap}toString(){return yT(this)}}function Mo(n,t){return n.length===t.length&&n.every((e,i)=>e.path===t[i].path)}class mT{}class gT{parse(t){const e=new bG(t);return new Eo(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(t){const e=`/${xc(t.root,!0)}`,i=function pG(n){const t=Object.keys(n).map(e=>{const i=n[e];return Array.isArray(i)?i.map(r=>`${Vh(e)}=${Vh(r)}`).join("&"):`${Vh(e)}=${Vh(i)}`}).filter(e=>!!e);return t.length?`?${t.join("&")}`:""}(t.queryParams);return`${e}${i}${"string"==typeof t.fragment?`#${function hG(n){return encodeURI(n)}(t.fragment)}`:""}`}}const uG=new gT;function Bh(n){return n.segments.map(t=>yT(t)).join("/")}function xc(n,t){if(!n.hasChildren())return Bh(n);if(t){const e=n.children[Et]?xc(n.children[Et],!1):"",i=[];return Un(n.children,(r,s)=>{s!==Et&&i.push(`${s}:${xc(r,!1)}`)}),i.length>0?`${e}(${i.join("//")})`:e}{const e=function dG(n,t){let e=[];return Un(n.children,(i,r)=>{r===Et&&(e=e.concat(t(i,r)))}),Un(n.children,(i,r)=>{r!==Et&&(e=e.concat(t(i,r)))}),e}(n,(i,r)=>r===Et?[xc(n.children[Et],!1)]:[`${r}:${xc(i,!1)}`]);return 1===Object.keys(n.children).length&&null!=n.children[Et]?`${Bh(n)}/${e[0]}`:`${Bh(n)}/(${e.join("//")})`}}function _T(n){return encodeURIComponent(n).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function Vh(n){return _T(n).replace(/%3B/gi,";")}function Ev(n){return _T(n).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Hh(n){return decodeURIComponent(n)}function vT(n){return Hh(n.replace(/\+/g,"%20"))}function yT(n){return`${Ev(n.path)}${function fG(n){return Object.keys(n).map(t=>`;${Ev(t)}=${Ev(n[t])}`).join("")}(n.parameters)}`}const mG=/^[^\/()?;=#]+/;function jh(n){const t=n.match(mG);return t?t[0]:""}const gG=/^[^=?&#]+/,vG=/^[^&#]+/;class bG{constructor(t){this.url=t,this.remaining=t}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new Pt([],{}):new Pt([],this.parseChildren())}parseQueryParams(){const t={};if(this.consumeOptional("?"))do{this.parseQueryParam(t)}while(this.consumeOptional("&"));return t}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const t=[];for(this.peekStartsWith("(")||t.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),t.push(this.parseSegment());let e={};this.peekStartsWith("/(")&&(this.capture("/"),e=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(t.length>0||Object.keys(e).length>0)&&(i[Et]=new Pt(t,e)),i}parseSegment(){const t=jh(this.remaining);if(""===t&&this.peekStartsWith(";"))throw new Error(`Empty path url segment cannot have parameters: '${this.remaining}'.`);return this.capture(t),new Mc(Hh(t),this.parseMatrixParams())}parseMatrixParams(){const t={};for(;this.consumeOptional(";");)this.parseParam(t);return t}parseParam(t){const e=jh(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){const r=jh(this.remaining);r&&(i=r,this.capture(i))}t[Hh(e)]=Hh(i)}parseQueryParam(t){const e=function _G(n){const t=n.match(gG);return t?t[0]:""}(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){const o=function yG(n){const t=n.match(vG);return t?t[0]:""}(this.remaining);o&&(i=o,this.capture(i))}const r=vT(e),s=vT(i);if(t.hasOwnProperty(r)){let o=t[r];Array.isArray(o)||(o=[o],t[r]=o),o.push(s)}else t[r]=s}parseParens(t){const e={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const i=jh(this.remaining),r=this.remaining[i.length];if("/"!==r&&")"!==r&&";"!==r)throw new Error(`Cannot parse url '${this.url}'`);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):t&&(s=Et);const o=this.parseChildren();e[s]=1===Object.keys(o).length?o[Et]:new Pt([],o),this.consumeOptional("//")}return e}peekStartsWith(t){return this.remaining.startsWith(t)}consumeOptional(t){return!!this.peekStartsWith(t)&&(this.remaining=this.remaining.substring(t.length),!0)}capture(t){if(!this.consumeOptional(t))throw new Error(`Expected "${t}".`)}}class bT{constructor(t){this._root=t}get root(){return this._root.value}parent(t){const e=this.pathFromRoot(t);return e.length>1?e[e.length-2]:null}children(t){const e=Mv(t,this._root);return e?e.children.map(i=>i.value):[]}firstChild(t){const e=Mv(t,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(t){const e=xv(t,this._root);return e.length<2?[]:e[e.length-2].children.map(r=>r.value).filter(r=>r!==t)}pathFromRoot(t){return xv(t,this._root).map(e=>e.value)}}function Mv(n,t){if(n===t.value)return t;for(const e of t.children){const i=Mv(n,e);if(i)return i}return null}function xv(n,t){if(n===t.value)return[t];for(const e of t.children){const i=xv(n,e);if(i.length)return i.unshift(t),i}return[]}class ds{constructor(t,e){this.value=t,this.children=e}toString(){return`TreeNode(${this.value})`}}function za(n){const t={};return n&&n.children.forEach(e=>t[e.value.outlet]=e),t}class wT extends bT{constructor(t,e){super(t),this.snapshot=e,Sv(this,t)}toString(){return this.snapshot.toString()}}function CT(n,t){const e=function wG(n,t){const o=new Uh([],{},{},"",{},Et,t,null,n.root,-1,{});return new ET("",new ds(o,[]))}(n,t),i=new mi([new Mc("",{})]),r=new mi({}),s=new mi({}),o=new mi({}),a=new mi(""),l=new $a(i,r,o,a,s,Et,t,e.root);return l.snapshot=e.root,new wT(new ds(l,[]),e)}class $a{constructor(t,e,i,r,s,o,a,l){this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this._futureSnapshot=l}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=this.params.pipe(U(t=>Ua(t)))),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(U(t=>Ua(t)))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function DT(n,t="emptyOnly"){const e=n.pathFromRoot;let i=0;if("always"!==t)for(i=e.length-1;i>=1;){const r=e[i],s=e[i-1];if(r.routeConfig&&""===r.routeConfig.path)i--;else{if(s.component)break;i--}}return function CG(n){return n.reduce((t,e)=>{var i;return{params:Object.assign(Object.assign({},t.params),e.params),data:Object.assign(Object.assign({},t.data),e.data),resolve:Object.assign(Object.assign(Object.assign(Object.assign({},e.data),t.resolve),null===(i=e.routeConfig)||void 0===i?void 0:i.data),e._resolvedData)}},{params:{},data:{},resolve:{}})}(e.slice(i))}class Uh{constructor(t,e,i,r,s,o,a,l,c,d,f,w){this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=l,this._urlSegment=c,this._lastPathIndex=d,this._correctedLastPathIndex=null!=w?w:d,this._resolve=f}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=Ua(this.params)),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Ua(this.queryParams)),this._queryParamMap}toString(){return`Route(url:'${this.url.map(i=>i.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class ET extends bT{constructor(t,e){super(e),this.url=t,Sv(this,e)}toString(){return MT(this._root)}}function Sv(n,t){t.value._routerState=n,t.children.forEach(e=>Sv(n,e))}function MT(n){const t=n.children.length>0?` { ${n.children.map(MT).join(", ")} } `:"";return`${n.value}${t}`}function kv(n){if(n.snapshot){const t=n.snapshot,e=n._futureSnapshot;n.snapshot=e,Pr(t.queryParams,e.queryParams)||n.queryParams.next(e.queryParams),t.fragment!==e.fragment&&n.fragment.next(e.fragment),Pr(t.params,e.params)||n.params.next(e.params),function rG(n,t){if(n.length!==t.length)return!1;for(let e=0;ePr(e.parameters,t[i].parameters))}(n.url,t.url);return e&&!(!n.parent!=!t.parent)&&(!n.parent||Tv(n.parent,t.parent))}function Sc(n,t,e){if(e&&n.shouldReuseRoute(t.value,e.value.snapshot)){const i=e.value;i._futureSnapshot=t.value;const r=function EG(n,t,e){return t.children.map(i=>{for(const r of e.children)if(n.shouldReuseRoute(i.value,r.value.snapshot))return Sc(n,i,r);return Sc(n,i)})}(n,t,e);return new ds(i,r)}{if(n.shouldAttach(t.value)){const s=n.retrieve(t.value);if(null!==s){const o=s.route;return o.value._futureSnapshot=t.value,o.children=t.children.map(a=>Sc(n,a)),o}}const i=function MG(n){return new $a(new mi(n.url),new mi(n.params),new mi(n.queryParams),new mi(n.fragment),new mi(n.data),n.outlet,n.component,n)}(t.value),r=t.children.map(s=>Sc(n,s));return new ds(i,r)}}function zh(n){return"object"==typeof n&&null!=n&&!n.outlets&&!n.segmentPath}function kc(n){return"object"==typeof n&&null!=n&&n.outlets}function Av(n,t,e,i,r){let s={};if(i&&Un(i,(a,l)=>{s[l]=Array.isArray(a)?a.map(c=>`${c}`):`${a}`}),n===t)return new Eo(e,s,r);const o=xT(n,t,e);return new Eo(o,s,r)}function xT(n,t,e){const i={};return Un(n.children,(r,s)=>{i[s]=r===t?e:xT(r,t,e)}),new Pt(n.segments,i)}class ST{constructor(t,e,i){if(this.isAbsolute=t,this.numberOfDoubleDots=e,this.commands=i,t&&i.length>0&&zh(i[0]))throw new Error("Root segment cannot have matrix parameters");const r=i.find(kc);if(r&&r!==cT(i))throw new Error("{outlets:{}} has to be the last command")}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class Iv{constructor(t,e,i){this.segmentGroup=t,this.processChildren=e,this.index=i}}function kT(n,t,e){if(n||(n=new Pt([],{})),0===n.segments.length&&n.hasChildren())return $h(n,t,e);const i=function IG(n,t,e){let i=0,r=t;const s={match:!1,pathIndex:0,commandIndex:0};for(;r=e.length)return s;const o=n.segments[r],a=e[i];if(kc(a))break;const l=`${a}`,c=i0&&void 0===l)break;if(l&&c&&"object"==typeof c&&void 0===c.outlets){if(!AT(l,c,o))return s;i+=2}else{if(!AT(l,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}(n,t,e),r=e.slice(i.commandIndex);if(i.match&&i.pathIndex{"string"==typeof s&&(s=[s]),null!==s&&(r[o]=kT(n.children[o],t,s))}),Un(n.children,(s,o)=>{void 0===i[o]&&(r[o]=s)}),new Pt(n.segments,r)}}function Rv(n,t,e){const i=n.segments.slice(0,t);let r=0;for(;r{"string"==typeof e&&(e=[e]),null!==e&&(t[i]=Rv(new Pt([],{}),0,e))}),t}function TT(n){const t={};return Un(n,(e,i)=>t[i]=`${e}`),t}function AT(n,t,e){return n==e.path&&Pr(t,e.parameters)}class PG{constructor(){this.outlet=null,this.route=null,this.resolver=null,this.injector=null,this.children=new Tc,this.attachRef=null}}class Tc{constructor(){this.contexts=new Map}onChildOutletCreated(t,e){const i=this.getOrCreateContext(t);i.outlet=e,this.contexts.set(t,i)}onChildOutletDestroyed(t){const e=this.getContext(t);e&&(e.outlet=null,e.attachRef=null)}onOutletDeactivated(){const t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let e=this.getContext(t);return e||(e=new PG,this.contexts.set(t,e)),e}getContext(t){return this.contexts.get(t)||null}}let Pv=(()=>{class n{constructor(e,i,r,s,o){this.parentContexts=e,this.location=i,this.changeDetector=s,this.environmentInjector=o,this.activated=null,this._activatedRoute=null,this.activateEvents=new je,this.deactivateEvents=new je,this.attachEvents=new je,this.detachEvents=new je,this.name=r||Et,e.onChildOutletCreated(this.name,this)}ngOnDestroy(){this.parentContexts.onChildOutletDestroyed(this.name)}ngOnInit(){if(!this.activated){const e=this.parentContexts.getContext(this.name);e&&e.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new Error("Outlet is not activated");return this.activated.instance}get activatedRoute(){if(!this.activated)throw new Error("Outlet is not activated");return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new Error("Outlet is not activated");this.location.detach();const e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,i){this.activated=e,this._activatedRoute=i,this.location.insert(e.hostView),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){const e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,i){if(this.isActivated)throw new Error("Cannot activate an already activated outlet");this._activatedRoute=e;const r=this.location,o=e._futureSnapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,l=new OG(e,a,r.injector);if(i&&function FG(n){return!!n.resolveComponentFactory}(i)){const c=i.resolveComponentFactory(o);this.activated=r.createComponent(c,r.length,l)}else this.activated=r.createComponent(o,{index:r.length,injector:l,environmentInjector:null!=i?i:this.environmentInjector});this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}}return n.\u0275fac=function(e){return new(e||n)(x(Tc),x(An),ii("name"),x(en),x(Qs))},n.\u0275dir=Me({type:n,selectors:[["router-outlet"]],outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"]}),n})();class OG{constructor(t,e,i){this.route=t,this.childContexts=e,this.parent=i}get(t,e){return t===$a?this.route:t===Tc?this.childContexts:this.parent.get(t,e)}}let IT=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275cmp=vt({type:n,selectors:[["ng-component"]],decls:1,vars:0,template:function(e,i){1&e&&kt(0,"router-outlet")},dependencies:[Pv],encapsulation:2}),n})();function RT(n,t){var e;return n.providers&&!n._injector&&(n._injector=Nd(n.providers,t,`Route: ${n.path}`)),null!==(e=n._injector)&&void 0!==e?e:t}function Fv(n){const t=n.children&&n.children.map(Fv),e=t?Object.assign(Object.assign({},n),{children:t}):Object.assign({},n);return!e.component&&!e.loadComponent&&(t||e.loadChildren)&&e.outlet&&e.outlet!==Et&&(e.component=IT),e}function Qi(n){return n.outlet||Et}function PT(n,t){const e=n.filter(i=>Qi(i)===t);return e.push(...n.filter(i=>Qi(i)!==t)),e}function OT(n){var t;if(!n)return null;if(null!==(t=n.routeConfig)&&void 0!==t&&t._injector)return n.routeConfig._injector;for(let e=n.parent;e;e=e.parent){const i=e.routeConfig;if(null!=i&&i._loadedInjector)return i._loadedInjector;if(null!=i&&i._injector)return i._injector}return null}class HG{constructor(t,e,i,r){this.routeReuseStrategy=t,this.futureState=e,this.currState=i,this.forwardEvent=r}activate(t){const e=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,i,t),kv(this.futureState.root),this.activateChildRoutes(e,i,t)}deactivateChildRoutes(t,e,i){const r=za(e);t.children.forEach(s=>{const o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),Un(r,(s,o)=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(t,e,i){const r=t.value,s=e?e.value:null;if(r===s)if(r.component){const o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(t,e,o.children)}else this.deactivateChildRoutes(t,e,i);else s&&this.deactivateRouteAndItsChildren(e,i)}deactivateRouteAndItsChildren(t,e){t.value.component&&this.routeReuseStrategy.shouldDetach(t.value.snapshot)?this.detachAndStoreRouteSubtree(t,e):this.deactivateRouteAndOutlet(t,e)}detachAndStoreRouteSubtree(t,e){const i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=za(t);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);if(i&&i.outlet){const o=i.outlet.detach(),a=i.children.onOutletDeactivated();this.routeReuseStrategy.store(t.value.snapshot,{componentRef:o,route:t,contexts:a})}}deactivateRouteAndOutlet(t,e){const i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=za(t);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);i&&i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated(),i.attachRef=null,i.resolver=null,i.route=null)}activateChildRoutes(t,e,i){const r=za(e);t.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new eG(s.value.snapshot))}),t.children.length&&this.forwardEvent(new X6(t.value.snapshot))}activateRoutes(t,e,i){var r;const s=t.value,o=e?e.value:null;if(kv(s),s===o)if(s.component){const a=i.getOrCreateContext(s.outlet);this.activateChildRoutes(t,e,a.children)}else this.activateChildRoutes(t,e,i);else if(s.component){const a=i.getOrCreateContext(s.outlet);if(this.routeReuseStrategy.shouldAttach(s.snapshot)){const l=this.routeReuseStrategy.retrieve(s.snapshot);this.routeReuseStrategy.store(s.snapshot,null),a.children.onOutletReAttached(l.contexts),a.attachRef=l.componentRef,a.route=l.route.value,a.outlet&&a.outlet.attach(l.componentRef,l.route.value),kv(l.route.value),this.activateChildRoutes(t,null,a.children)}else{const l=OT(s.snapshot),c=null!==(r=null==l?void 0:l.get(io))&&void 0!==r?r:null;a.attachRef=null,a.route=s,a.resolver=c,a.injector=l,a.outlet&&a.outlet.activateWith(s,a.injector),this.activateChildRoutes(t,null,a.children)}}else this.activateChildRoutes(t,null,i)}}function Ns(n){return"function"==typeof n}function xo(n){return n instanceof Eo}const Ac=Symbol("INITIAL_VALUE");function Ic(){return Rr(n=>gv(n.map(t=>t.pipe(sn(1),Qn(Ac)))).pipe(nT((t,e)=>{let i=!1;return e.reduce((r,s,o)=>r!==Ac?r:(s===Ac&&(i=!0),i||!1!==s&&o!==e.length-1&&!xo(s)?r:s),t)},Ac),yn(t=>t!==Ac),U(t=>xo(t)?t:!0===t),sn(1)))}const FT={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function Gh(n,t,e){var i;if(""===t.path)return"full"===t.pathMatch&&(n.hasChildren()||e.length>0)?Object.assign({},FT):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};const s=(t.matcher||iG)(e,n,t);if(!s)return Object.assign({},FT);const o={};Un(s.posParams,(l,c)=>{o[c]=l.path});const a=s.consumed.length>0?Object.assign(Object.assign({},o),s.consumed[s.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:s.consumed,remainingSegments:e.slice(s.consumed.length),parameters:a,positionalParamSegments:null!==(i=s.posParams)&&void 0!==i?i:{}}}function Wh(n,t,e,i,r="corrected"){if(e.length>0&&function YG(n,t,e){return e.some(i=>qh(n,t,i)&&Qi(i)!==Et)}(n,e,i)){const o=new Pt(t,function qG(n,t,e,i){const r={};r[Et]=i,i._sourceSegment=n,i._segmentIndexShift=t.length;for(const s of e)if(""===s.path&&Qi(s)!==Et){const o=new Pt([],{});o._sourceSegment=n,o._segmentIndexShift=t.length,r[Qi(s)]=o}return r}(n,t,i,new Pt(e,n.children)));return o._sourceSegment=n,o._segmentIndexShift=t.length,{segmentGroup:o,slicedSegments:[]}}if(0===e.length&&function KG(n,t,e){return e.some(i=>qh(n,t,i))}(n,e,i)){const o=new Pt(n.segments,function WG(n,t,e,i,r,s){const o={};for(const a of i)if(qh(n,e,a)&&!r[Qi(a)]){const l=new Pt([],{});l._sourceSegment=n,l._segmentIndexShift="legacy"===s?n.segments.length:t.length,o[Qi(a)]=l}return Object.assign(Object.assign({},r),o)}(n,t,e,i,n.children,r));return o._sourceSegment=n,o._segmentIndexShift=t.length,{segmentGroup:o,slicedSegments:e}}const s=new Pt(n.segments,n.children);return s._sourceSegment=n,s._segmentIndexShift=t.length,{segmentGroup:s,slicedSegments:e}}function qh(n,t,e){return(!(n.hasChildren()||t.length>0)||"full"!==e.pathMatch)&&""===e.path}function LT(n,t,e,i){return!!(Qi(n)===i||i!==Et&&qh(t,e,n))&&("**"===n.path||Gh(t,n,e).matched)}function NT(n,t,e){return 0===t.length&&!n.children[e]}class Yh{constructor(t){this.segmentGroup=t||null}}class BT{constructor(t){this.urlTree=t}}function Rc(n){return La(new Yh(n))}function VT(n){return La(new BT(n))}class JG{constructor(t,e,i,r,s){this.injector=t,this.configLoader=e,this.urlSerializer=i,this.urlTree=r,this.config=s,this.allowRedirects=!0}apply(){const t=Wh(this.urlTree.root,[],[],this.config).segmentGroup,e=new Pt(t.segments,t.children);return this.expandSegmentGroup(this.injector,this.config,e,Et).pipe(U(s=>this.createUrlTree(Lv(s),this.urlTree.queryParams,this.urlTree.fragment))).pipe(os(s=>{if(s instanceof BT)return this.allowRedirects=!1,this.match(s.urlTree);throw s instanceof Yh?this.noMatchError(s):s}))}match(t){return this.expandSegmentGroup(this.injector,this.config,t.root,Et).pipe(U(r=>this.createUrlTree(Lv(r),t.queryParams,t.fragment))).pipe(os(r=>{throw r instanceof Yh?this.noMatchError(r):r}))}noMatchError(t){return new Error(`Cannot match any routes. URL Segment: '${t.segmentGroup}'`)}createUrlTree(t,e,i){const r=t.segments.length>0?new Pt([],{[Et]:t}):t;return new Eo(r,e,i)}expandSegmentGroup(t,e,i,r){return 0===i.segments.length&&i.hasChildren()?this.expandChildren(t,e,i).pipe(U(s=>new Pt([],s))):this.expandSegment(t,i,e,i.segments,r,!0)}expandChildren(t,e,i){const r=[];for(const s of Object.keys(i.children))"primary"===s?r.unshift(s):r.push(s);return gn(r).pipe(Da(s=>{const o=i.children[s],a=PT(e,s);return this.expandSegmentGroup(t,a,o,s).pipe(U(l=>({segment:l,outlet:s})))}),nT((s,o)=>(s[o.outlet]=o.segment,s),{}),function j6(n,t){const e=arguments.length>=2;return i=>i.pipe(n?yn((r,s)=>n(r,s,i)):N,bv(1),e?wv(t):iT(()=>new Dc))}())}expandSegment(t,e,i,r,s,o){return gn(i).pipe(Da(a=>this.expandSegmentAgainstRoute(t,e,i,a,r,s,o).pipe(os(c=>{if(c instanceof Yh)return tt(null);throw c}))),Do(a=>!!a),os((a,l)=>{if(a instanceof Dc||"EmptyError"===a.name)return NT(e,r,s)?tt(new Pt([],{})):Rc(e);throw a}))}expandSegmentAgainstRoute(t,e,i,r,s,o,a){return LT(r,e,s,o)?void 0===r.redirectTo?this.matchSegmentAgainstRoute(t,e,r,s,o):a&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o):Rc(e):Rc(e)}expandSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o){return"**"===r.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(t,i,r,o):this.expandRegularSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o)}expandWildCardWithParamsAgainstRouteUsingRedirect(t,e,i,r){const s=this.applyRedirectCommands([],i.redirectTo,{});return i.redirectTo.startsWith("/")?VT(s):this.lineralizeSegments(i,s).pipe(Pn(o=>{const a=new Pt(o,{});return this.expandSegment(t,a,e,o,r,!1)}))}expandRegularSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o){const{matched:a,consumedSegments:l,remainingSegments:c,positionalParamSegments:d}=Gh(e,r,s);if(!a)return Rc(e);const f=this.applyRedirectCommands(l,r.redirectTo,d);return r.redirectTo.startsWith("/")?VT(f):this.lineralizeSegments(r,f).pipe(Pn(w=>this.expandSegment(t,e,i,w.concat(c),o,!1)))}matchSegmentAgainstRoute(t,e,i,r,s){if("**"===i.path)return t=RT(i,t),i.loadChildren?(i._loadedRoutes?tt({routes:i._loadedRoutes,injector:i._loadedInjector}):this.configLoader.loadChildren(t,i)).pipe(U(f=>(i._loadedRoutes=f.routes,i._loadedInjector=f.injector,new Pt(r,{})))):tt(new Pt(r,{}));const{matched:o,consumedSegments:a,remainingSegments:l}=Gh(e,i,r);return o?(t=RT(i,t),this.getChildConfig(t,i,r).pipe(Pn(d=>{var f;const w=null!==(f=d.injector)&&void 0!==f?f:t,k=d.routes,{segmentGroup:j,slicedSegments:K}=Wh(e,a,l,k),ae=new Pt(j.segments,j.children);if(0===K.length&&ae.hasChildren())return this.expandChildren(w,k,ae).pipe(U(Oe=>new Pt(a,Oe)));if(0===k.length&&0===K.length)return tt(new Pt(a,{}));const ce=Qi(i)===s;return this.expandSegment(w,ae,k,K,ce?Et:s,!0).pipe(U(he=>new Pt(a.concat(he.segments),he.children)))}))):Rc(e)}getChildConfig(t,e,i){return e.children?tt({routes:e.children,injector:t}):e.loadChildren?void 0!==e._loadedRoutes?tt({routes:e._loadedRoutes,injector:e._loadedInjector}):this.runCanLoadGuards(t,e,i).pipe(Pn(r=>r?this.configLoader.loadChildren(t,e).pipe(wn(s=>{e._loadedRoutes=s.routes,e._loadedInjector=s.injector})):function ZG(n){return La(Dv(`Cannot load children because the guard of the route "path: '${n.path}'" returned false`))}(e))):tt({routes:[],injector:t})}runCanLoadGuards(t,e,i){const r=e.canLoad;return r&&0!==r.length?tt(r.map(o=>{const a=t.get(o);let l;if(function UG(n){return n&&Ns(n.canLoad)}(a))l=a.canLoad(e,i);else{if(!Ns(a))throw new Error("Invalid CanLoad guard");l=a(e,i)}return fr(l)})).pipe(Ic(),wn(o=>{if(!xo(o))return;const a=Dv(`Redirecting to "${this.urlSerializer.serialize(o)}"`);throw a.url=o,a}),U(o=>!0===o)):tt(!0)}lineralizeSegments(t,e){let i=[],r=e.root;for(;;){if(i=i.concat(r.segments),0===r.numberOfChildren)return tt(i);if(r.numberOfChildren>1||!r.children[Et])return La(new Error(`Only absolute redirects can have named outlets. redirectTo: '${t.redirectTo}'`));r=r.children[Et]}}applyRedirectCommands(t,e,i){return this.applyRedirectCreatreUrlTree(e,this.urlSerializer.parse(e),t,i)}applyRedirectCreatreUrlTree(t,e,i,r){const s=this.createSegmentGroup(t,e.root,i,r);return new Eo(s,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(t,e){const i={};return Un(t,(r,s)=>{if("string"==typeof r&&r.startsWith(":")){const a=r.substring(1);i[s]=e[a]}else i[s]=r}),i}createSegmentGroup(t,e,i,r){const s=this.createSegments(t,e.segments,i,r);let o={};return Un(e.children,(a,l)=>{o[l]=this.createSegmentGroup(t,a,i,r)}),new Pt(s,o)}createSegments(t,e,i,r){return e.map(s=>s.path.startsWith(":")?this.findPosParam(t,s,r):this.findOrReturn(s,i))}findPosParam(t,e,i){const r=i[e.path.substring(1)];if(!r)throw new Error(`Cannot redirect to '${t}'. Cannot find '${e.path}'.`);return r}findOrReturn(t,e){let i=0;for(const r of e){if(r.path===t.path)return e.splice(i),r;i++}return t}}function Lv(n){const t={};for(const i of Object.keys(n.children)){const s=Lv(n.children[i]);(s.segments.length>0||s.hasChildren())&&(t[i]=s)}return function eW(n){if(1===n.numberOfChildren&&n.children[Et]){const t=n.children[Et];return new Pt(n.segments.concat(t.segments),t.children)}return n}(new Pt(n.segments,t))}class HT{constructor(t){this.path=t,this.route=this.path[this.path.length-1]}}class Kh{constructor(t,e){this.component=t,this.route=e}}function nW(n,t,e){const i=n._root;return Pc(i,t?t._root:null,e,[i.value])}function Qh(n,t,e){const i=OT(t);return(null!=i?i:e).get(n)}function Pc(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=za(t);return n.children.forEach(o=>{(function rW(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=n.value,o=t?t.value:null,a=e?e.getContext(n.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){const l=function sW(n,t,e){if("function"==typeof e)return e(n,t);switch(e){case"pathParamsChange":return!Mo(n.url,t.url);case"pathParamsOrQueryParamsChange":return!Mo(n.url,t.url)||!Pr(n.queryParams,t.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Tv(n,t)||!Pr(n.queryParams,t.queryParams);default:return!Tv(n,t)}}(o,s,s.routeConfig.runGuardsAndResolvers);l?r.canActivateChecks.push(new HT(i)):(s.data=o.data,s._resolvedData=o._resolvedData),Pc(n,t,s.component?a?a.children:null:e,i,r),l&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new Kh(a.outlet.component,o))}else o&&Oc(t,a,r),r.canActivateChecks.push(new HT(i)),Pc(n,null,s.component?a?a.children:null:e,i,r)})(o,s[o.value.outlet],e,i.concat([o.value]),r),delete s[o.value.outlet]}),Un(s,(o,a)=>Oc(o,e.getContext(a),r)),r}function Oc(n,t,e){const i=za(n),r=n.value;Un(i,(s,o)=>{Oc(s,r.component?t?t.children.getContext(o):null:t,e)}),e.canDeactivateChecks.push(new Kh(r.component&&t&&t.outlet&&t.outlet.isActivated?t.outlet.component:null,r))}class pW{}function UT(n){return new J(t=>t.error(n))}class gW{constructor(t,e,i,r,s,o){this.rootComponentType=t,this.config=e,this.urlTree=i,this.url=r,this.paramsInheritanceStrategy=s,this.relativeLinkResolution=o}recognize(){const t=Wh(this.urlTree.root,[],[],this.config.filter(o=>void 0===o.redirectTo),this.relativeLinkResolution).segmentGroup,e=this.processSegmentGroup(this.config,t,Et);if(null===e)return null;const i=new Uh([],Object.freeze({}),Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,{},Et,this.rootComponentType,null,this.urlTree.root,-1,{}),r=new ds(i,e),s=new ET(this.url,r);return this.inheritParamsAndData(s._root),s}inheritParamsAndData(t){const e=t.value,i=DT(e,this.paramsInheritanceStrategy);e.params=Object.freeze(i.params),e.data=Object.freeze(i.data),t.children.forEach(r=>this.inheritParamsAndData(r))}processSegmentGroup(t,e,i){return 0===e.segments.length&&e.hasChildren()?this.processChildren(t,e):this.processSegment(t,e,e.segments,i)}processChildren(t,e){const i=[];for(const s of Object.keys(e.children)){const o=e.children[s],a=PT(t,s),l=this.processSegmentGroup(a,o,s);if(null===l)return null;i.push(...l)}const r=zT(i);return function _W(n){n.sort((t,e)=>t.value.outlet===Et?-1:e.value.outlet===Et?1:t.value.outlet.localeCompare(e.value.outlet))}(r),r}processSegment(t,e,i,r){for(const s of t){const o=this.processSegmentAgainstRoute(s,e,i,r);if(null!==o)return o}return NT(e,i,r)?[]:null}processSegmentAgainstRoute(t,e,i,r){var s,o,a,l;if(t.redirectTo||!LT(t,e,i,r))return null;let c,d=[],f=[];if("**"===t.path){const ce=i.length>0?cT(i).parameters:{},Te=GT(e)+i.length;c=new Uh(i,ce,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,qT(t),Qi(t),null!==(o=null!==(s=t.component)&&void 0!==s?s:t._loadedComponent)&&void 0!==o?o:null,t,$T(e),Te,YT(t),Te)}else{const ce=Gh(e,t,i);if(!ce.matched)return null;d=ce.consumedSegments,f=ce.remainingSegments;const Te=GT(e)+d.length;c=new Uh(d,ce.parameters,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,qT(t),Qi(t),null!==(l=null!==(a=t.component)&&void 0!==a?a:t._loadedComponent)&&void 0!==l?l:null,t,$T(e),Te,YT(t),Te)}const w=function vW(n){return n.children?n.children:n.loadChildren?n._loadedRoutes:[]}(t),{segmentGroup:k,slicedSegments:j}=Wh(e,d,f,w.filter(ce=>void 0===ce.redirectTo),this.relativeLinkResolution);if(0===j.length&&k.hasChildren()){const ce=this.processChildren(w,k);return null===ce?null:[new ds(c,ce)]}if(0===w.length&&0===j.length)return[new ds(c,[])];const K=Qi(t)===r,ae=this.processSegment(w,k,j,K?Et:r);return null===ae?null:[new ds(c,ae)]}}function yW(n){const t=n.value.routeConfig;return t&&""===t.path&&void 0===t.redirectTo}function zT(n){const t=[],e=new Set;for(const i of n){if(!yW(i)){t.push(i);continue}const r=t.find(s=>i.value.routeConfig===s.value.routeConfig);void 0!==r?(r.children.push(...i.children),e.add(r)):t.push(i)}for(const i of e){const r=zT(i.children);t.push(new ds(i.value,r))}return t.filter(i=>!e.has(i))}function $T(n){let t=n;for(;t._sourceSegment;)t=t._sourceSegment;return t}function GT(n){var t,e;let i=n,r=null!==(t=i._segmentIndexShift)&&void 0!==t?t:0;for(;i._sourceSegment;)i=i._sourceSegment,r+=null!==(e=i._segmentIndexShift)&&void 0!==e?e:0;return r-1}function qT(n){return n.data||{}}function YT(n){return n.resolve||{}}const Nv=Symbol("RouteTitle");function KT(n){return"string"==typeof n.title||null===n.title}function Zh(n){return Rr(t=>{const e=n(t);return e?gn(e).pipe(U(()=>t)):tt(t)})}class kW extends class SW{shouldDetach(t){return!1}store(t,e){}shouldAttach(t){return!1}retrieve(t){return null}shouldReuseRoute(t,e){return t.routeConfig===e.routeConfig}}{}const Bv=new De("ROUTES");let Vv=(()=>{class n{constructor(e,i){this.injector=e,this.compiler=i,this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap}loadComponent(e){if(this.componentLoaders.get(e))return this.componentLoaders.get(e);if(e._loadedComponent)return tt(e._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(e);const i=fr(e.loadComponent()).pipe(wn(s=>{this.onLoadEndListener&&this.onLoadEndListener(e),e._loadedComponent=s}),bh(()=>{this.componentLoaders.delete(e)})),r=new yv(i,()=>new ue).pipe(Lh());return this.componentLoaders.set(e,r),r}loadChildren(e,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return tt({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);const s=this.loadModuleFactoryOrRoutes(i.loadChildren).pipe(U(a=>{this.onLoadEndListener&&this.onLoadEndListener(i);let l,c,d=!1;Array.isArray(a)?c=a:(l=a.create(e).injector,c=lT(l.get(Bv,[],at.Self|at.Optional)));return{routes:c.map(Fv),injector:l}}),bh(()=>{this.childrenLoaders.delete(i)})),o=new yv(s,()=>new ue).pipe(Lh());return this.childrenLoaders.set(i,o),o}loadModuleFactoryOrRoutes(e){return fr(e()).pipe(Pn(i=>i instanceof NC||Array.isArray(i)?tt(i):gn(this.compiler.compileModuleAsync(i))))}}return n.\u0275fac=function(e){return new(e||n)(te(Jt),te(Rm))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();class AW{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,e){return t}}function RW(n){throw n}function PW(n,t,e){return t.parse("/")}function ZT(n,t){return tt(null)}const OW={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},FW={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let Ri=(()=>{class n{constructor(e,i,r,s,o,a,l){this.rootComponentType=e,this.urlSerializer=i,this.rootContexts=r,this.location=s,this.config=l,this.lastSuccessfulNavigation=null,this.currentNavigation=null,this.disposed=!1,this.navigationId=0,this.currentPageId=0,this.isNgZoneEnabled=!1,this.events=new ue,this.errorHandler=RW,this.malformedUriErrorHandler=PW,this.navigated=!1,this.lastSuccessfulId=-1,this.hooks={beforePreactivation:ZT,afterPreactivation:ZT},this.urlHandlingStrategy=new AW,this.routeReuseStrategy=new kW,this.onSameUrlNavigation="ignore",this.paramsInheritanceStrategy="emptyOnly",this.urlUpdateStrategy="deferred",this.relativeLinkResolution="corrected",this.canceledNavigationResolution="replace",this.configLoader=o.get(Vv),this.configLoader.onLoadEndListener=w=>this.triggerEvent(new Q6(w)),this.configLoader.onLoadStartListener=w=>this.triggerEvent(new K6(w)),this.ngModule=o.get(Ds),this.console=o.get(DN);const f=o.get(et);this.isNgZoneEnabled=f instanceof et&&et.isInAngularZone(),this.resetConfig(l),this.currentUrlTree=function sG(){return new Eo(new Pt([],{}),{},null)}(),this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.routerState=CT(this.currentUrlTree,this.rootComponentType),this.transitions=new mi({id:0,targetPageId:0,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,extractedUrl:this.urlHandlingStrategy.extract(this.currentUrlTree),urlAfterRedirects:this.urlHandlingStrategy.extract(this.currentUrlTree),rawUrl:this.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:"imperative",restoredState:null,currentSnapshot:this.routerState.snapshot,targetSnapshot:null,currentRouterState:this.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.navigations=this.setupNavigations(this.transitions),this.processNavigations()}get browserPageId(){var e;return null===(e=this.location.getState())||void 0===e?void 0:e.\u0275routerPageId}setupNavigations(e){const i=this.events;return e.pipe(yn(r=>0!==r.id),U(r=>Object.assign(Object.assign({},r),{extractedUrl:this.urlHandlingStrategy.extract(r.rawUrl)})),Rr(r=>{let s=!1,o=!1;return tt(r).pipe(wn(a=>{this.currentNavigation={id:a.id,initialUrl:a.rawUrl,extractedUrl:a.extractedUrl,trigger:a.source,extras:a.extras,previousNavigation:this.lastSuccessfulNavigation?Object.assign(Object.assign({},this.lastSuccessfulNavigation),{previousNavigation:null}):null}}),Rr(a=>{const l=this.browserUrlTree.toString(),c=!this.navigated||a.extractedUrl.toString()!==l||l!==this.currentUrlTree.toString();if(("reload"===this.onSameUrlNavigation||c)&&this.urlHandlingStrategy.shouldProcessUrl(a.rawUrl))return XT(a.source)&&(this.browserUrlTree=a.extractedUrl),tt(a).pipe(Rr(f=>{const w=this.transitions.getValue();return i.next(new Cv(f.id,this.serializeUrl(f.extractedUrl),f.source,f.restoredState)),w!==this.transitions.getValue()?Fi:Promise.resolve(f)}),function tW(n,t,e,i){return Rr(r=>function XG(n,t,e,i,r){return new JG(n,t,e,i,r).apply()}(n,t,e,r.extractedUrl,i).pipe(U(s=>Object.assign(Object.assign({},r),{urlAfterRedirects:s}))))}(this.ngModule.injector,this.configLoader,this.urlSerializer,this.config),wn(f=>{this.currentNavigation=Object.assign(Object.assign({},this.currentNavigation),{finalUrl:f.urlAfterRedirects})}),function bW(n,t,e,i,r){return Pn(s=>function mW(n,t,e,i,r="emptyOnly",s="legacy"){try{const o=new gW(n,t,e,i,r,s).recognize();return null===o?UT(new pW):tt(o)}catch(o){return UT(o)}}(n,t,s.urlAfterRedirects,e(s.urlAfterRedirects),i,r).pipe(U(o=>Object.assign(Object.assign({},s),{targetSnapshot:o}))))}(this.rootComponentType,this.config,f=>this.serializeUrl(f),this.paramsInheritanceStrategy,this.relativeLinkResolution),wn(f=>{if("eager"===this.urlUpdateStrategy){if(!f.extras.skipLocationChange){const k=this.urlHandlingStrategy.merge(f.urlAfterRedirects,f.rawUrl);this.setBrowserUrl(k,f)}this.browserUrlTree=f.urlAfterRedirects}const w=new $6(f.id,this.serializeUrl(f.extractedUrl),this.serializeUrl(f.urlAfterRedirects),f.targetSnapshot);i.next(w)}));if(c&&this.rawUrlTree&&this.urlHandlingStrategy.shouldProcessUrl(this.rawUrlTree)){const{id:w,extractedUrl:k,source:j,restoredState:K,extras:ae}=a,ce=new Cv(w,this.serializeUrl(k),j,K);i.next(ce);const Te=CT(k,this.rootComponentType).snapshot;return tt(Object.assign(Object.assign({},a),{targetSnapshot:Te,urlAfterRedirects:k,extras:Object.assign(Object.assign({},ae),{skipLocationChange:!1,replaceUrl:!1})}))}return this.rawUrlTree=a.rawUrl,a.resolve(null),Fi}),Zh(a=>{const{targetSnapshot:l,id:c,extractedUrl:d,rawUrl:f,extras:{skipLocationChange:w,replaceUrl:k}}=a;return this.hooks.beforePreactivation(l,{navigationId:c,appliedUrlTree:d,rawUrlTree:f,skipLocationChange:!!w,replaceUrl:!!k})}),wn(a=>{const l=new G6(a.id,this.serializeUrl(a.extractedUrl),this.serializeUrl(a.urlAfterRedirects),a.targetSnapshot);this.triggerEvent(l)}),U(a=>Object.assign(Object.assign({},a),{guards:nW(a.targetSnapshot,a.currentSnapshot,this.rootContexts)})),function oW(n,t){return Pn(e=>{const{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=e;return 0===o.length&&0===s.length?tt(Object.assign(Object.assign({},e),{guardsResult:!0})):function aW(n,t,e,i){return gn(n).pipe(Pn(r=>function fW(n,t,e,i,r){const s=t&&t.routeConfig?t.routeConfig.canDeactivate:null;return s&&0!==s.length?tt(s.map(a=>{const l=Qh(a,t,r);let c;if(function GG(n){return n&&Ns(n.canDeactivate)}(l))c=fr(l.canDeactivate(n,t,e,i));else{if(!Ns(l))throw new Error("Invalid CanDeactivate guard");c=fr(l(n,t,e,i))}return c.pipe(Do())})).pipe(Ic()):tt(!0)}(r.component,r.route,e,t,i)),Do(r=>!0!==r,!0))}(o,i,r,n).pipe(Pn(a=>a&&function jG(n){return"boolean"==typeof n}(a)?function lW(n,t,e,i){return gn(t).pipe(Da(r=>nh(function dW(n,t){return null!==n&&t&&t(new Z6(n)),tt(!0)}(r.route.parent,i),function cW(n,t){return null!==n&&t&&t(new J6(n)),tt(!0)}(r.route,i),function hW(n,t,e){const i=t[t.length-1],s=t.slice(0,t.length-1).reverse().map(o=>function iW(n){const t=n.routeConfig?n.routeConfig.canActivateChild:null;return t&&0!==t.length?{node:n,guards:t}:null}(o)).filter(o=>null!==o).map(o=>_c(()=>tt(o.guards.map(l=>{const c=Qh(l,o.node,e);let d;if(function $G(n){return n&&Ns(n.canActivateChild)}(c))d=fr(c.canActivateChild(i,n));else{if(!Ns(c))throw new Error("Invalid CanActivateChild guard");d=fr(c(i,n))}return d.pipe(Do())})).pipe(Ic())));return tt(s).pipe(Ic())}(n,r.path,e),function uW(n,t,e){const i=t.routeConfig?t.routeConfig.canActivate:null;if(!i||0===i.length)return tt(!0);const r=i.map(s=>_c(()=>{const o=Qh(s,t,e);let a;if(function zG(n){return n&&Ns(n.canActivate)}(o))a=fr(o.canActivate(t,n));else{if(!Ns(o))throw new Error("Invalid CanActivate guard");a=fr(o(t,n))}return a.pipe(Do())}));return tt(r).pipe(Ic())}(n,r.route,e))),Do(r=>!0!==r,!0))}(i,s,n,t):tt(a)),U(a=>Object.assign(Object.assign({},e),{guardsResult:a})))})}(this.ngModule.injector,a=>this.triggerEvent(a)),wn(a=>{if(xo(a.guardsResult)){const c=Dv(`Redirecting to "${this.serializeUrl(a.guardsResult)}"`);throw c.url=a.guardsResult,c}const l=new W6(a.id,this.serializeUrl(a.extractedUrl),this.serializeUrl(a.urlAfterRedirects),a.targetSnapshot,!!a.guardsResult);this.triggerEvent(l)}),yn(a=>!!a.guardsResult||(this.restoreHistory(a),this.cancelNavigationTransition(a,""),!1)),Zh(a=>{if(a.guards.canActivateChecks.length)return tt(a).pipe(wn(l=>{const c=new q6(l.id,this.serializeUrl(l.extractedUrl),this.serializeUrl(l.urlAfterRedirects),l.targetSnapshot);this.triggerEvent(c)}),Rr(l=>{let c=!1;return tt(l).pipe(function wW(n,t){return Pn(e=>{const{targetSnapshot:i,guards:{canActivateChecks:r}}=e;if(!r.length)return tt(e);let s=0;return gn(r).pipe(Da(o=>function CW(n,t,e,i){const r=n.routeConfig,s=n._resolve;return void 0!==(null==r?void 0:r.title)&&!KT(r)&&(s[Nv]=r.title),function DW(n,t,e,i){const r=function EW(n){return[...Object.keys(n),...Object.getOwnPropertySymbols(n)]}(n);if(0===r.length)return tt({});const s={};return gn(r).pipe(Pn(o=>function MW(n,t,e,i){const r=Qh(n,t,i);return fr(r.resolve?r.resolve(t,e):r(t,e))}(n[o],t,e,i).pipe(Do(),wn(a=>{s[o]=a}))),bv(1),function U6(n){return U(()=>n)}(s),os(o=>o instanceof Dc?Fi:La(o)))}(s,n,t,i).pipe(U(o=>(n._resolvedData=o,n.data=DT(n,e).resolve,r&&KT(r)&&(n.data[Nv]=r.title),null)))}(o.route,i,n,t)),wn(()=>s++),bv(1),Pn(o=>s===r.length?tt(e):Fi))})}(this.paramsInheritanceStrategy,this.ngModule.injector),wn({next:()=>c=!0,complete:()=>{c||(this.restoreHistory(l),this.cancelNavigationTransition(l,"At least one route resolver didn't emit any value."))}}))}),wn(l=>{const c=new Y6(l.id,this.serializeUrl(l.extractedUrl),this.serializeUrl(l.urlAfterRedirects),l.targetSnapshot);this.triggerEvent(c)}))}),Zh(a=>{const{targetSnapshot:l,id:c,extractedUrl:d,rawUrl:f,extras:{skipLocationChange:w,replaceUrl:k}}=a;return this.hooks.afterPreactivation(l,{navigationId:c,appliedUrlTree:d,rawUrlTree:f,skipLocationChange:!!w,replaceUrl:!!k})}),Zh(a=>{const l=c=>{var d;const f=[];(null===(d=c.routeConfig)||void 0===d?void 0:d.loadComponent)&&!c.routeConfig._loadedComponent&&f.push(this.configLoader.loadComponent(c.routeConfig).pipe(wn(w=>{c.component=w}),U(()=>{})));for(const w of c.children)f.push(...l(w));return f};return gv(l(a.targetSnapshot.root)).pipe(wv(),sn(1))}),U(a=>{const l=function DG(n,t,e){const i=Sc(n,t._root,e?e._root:void 0);return new wT(i,t)}(this.routeReuseStrategy,a.targetSnapshot,a.currentRouterState);return Object.assign(Object.assign({},a),{targetRouterState:l})}),wn(a=>{this.currentUrlTree=a.urlAfterRedirects,this.rawUrlTree=this.urlHandlingStrategy.merge(a.urlAfterRedirects,a.rawUrl),this.routerState=a.targetRouterState,"deferred"===this.urlUpdateStrategy&&(a.extras.skipLocationChange||this.setBrowserUrl(this.rawUrlTree,a),this.browserUrlTree=a.urlAfterRedirects)}),((n,t,e)=>U(i=>(new HG(t,i.targetRouterState,i.currentRouterState,e).activate(n),i)))(this.rootContexts,this.routeReuseStrategy,a=>this.triggerEvent(a)),wn({next(){s=!0},complete(){s=!0}}),bh(()=>{var a;s||o||this.cancelNavigationTransition(r,`Navigation ID ${r.id} is not equal to the current navigation id ${this.navigationId}`),(null===(a=this.currentNavigation)||void 0===a?void 0:a.id)===r.id&&(this.currentNavigation=null)}),os(a=>{if(o=!0,function nG(n){return n&&n[oT]}(a)){const l=xo(a.url);l||(this.navigated=!0,this.restoreHistory(r,!0));const c=new rT(r.id,this.serializeUrl(r.extractedUrl),a.message);if(i.next(c),l){const d=this.urlHandlingStrategy.merge(a.url,this.rawUrlTree),f={skipLocationChange:r.extras.skipLocationChange,replaceUrl:"eager"===this.urlUpdateStrategy||XT(r.source)};this.scheduleNavigation(d,"imperative",null,f,{resolve:r.resolve,reject:r.reject,promise:r.promise})}else r.resolve(!1)}else{this.restoreHistory(r,!0);const l=new z6(r.id,this.serializeUrl(r.extractedUrl),a);i.next(l);try{r.resolve(this.errorHandler(a))}catch(c){r.reject(c)}}return Fi}))}))}resetRootComponentType(e){this.rootComponentType=e,this.routerState.root.component=this.rootComponentType}setTransition(e){this.transitions.next(Object.assign(Object.assign({},this.transitions.value),e))}initialNavigation(){this.setUpLocationChangeListener(),0===this.navigationId&&this.navigateByUrl(this.location.path(!0),{replaceUrl:!0})}setUpLocationChangeListener(){this.locationSubscription||(this.locationSubscription=this.location.subscribe(e=>{const i="popstate"===e.type?"popstate":"hashchange";"popstate"===i&&setTimeout(()=>{var r;const s={replaceUrl:!0},o=null!==(r=e.state)&&void 0!==r&&r.navigationId?e.state:null;if(o){const l=Object.assign({},o);delete l.navigationId,delete l.\u0275routerPageId,0!==Object.keys(l).length&&(s.state=l)}const a=this.parseUrl(e.url);this.scheduleNavigation(a,i,o,s)},0)}))}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.currentNavigation}triggerEvent(e){this.events.next(e)}resetConfig(e){this.config=e.map(Fv),this.navigated=!1,this.lastSuccessfulId=-1}ngOnDestroy(){this.dispose()}dispose(){this.transitions.complete(),this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=void 0),this.disposed=!0}createUrlTree(e,i={}){const{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:a,preserveFragment:l}=i,c=r||this.routerState.root,d=l?this.currentUrlTree.fragment:o;let f=null;switch(a){case"merge":f=Object.assign(Object.assign({},this.currentUrlTree.queryParams),s);break;case"preserve":f=this.currentUrlTree.queryParams;break;default:f=s||null}return null!==f&&(f=this.removeEmptyProps(f)),function xG(n,t,e,i,r){var s;if(0===e.length)return Av(t.root,t.root,t.root,i,r);const a=function SG(n){if("string"==typeof n[0]&&1===n.length&&"/"===n[0])return new ST(!0,0,n);let t=0,e=!1;const i=n.reduce((r,s,o)=>{if("object"==typeof s&&null!=s){if(s.outlets){const a={};return Un(s.outlets,(l,c)=>{a[c]="string"==typeof l?l.split("/"):l}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return"string"!=typeof s?[...r,s]:0===o?(s.split("/").forEach((a,l)=>{0==l&&"."===a||(0==l&&""===a?e=!0:".."===a?t++:""!=a&&r.push(a))}),r):[...r,s]},[]);return new ST(e,t,i)}(e);return a.toRoot()?Av(t.root,t.root,new Pt([],{}),i,r):function l(d){var f;const w=function kG(n,t,e,i){return n.isAbsolute?new Iv(t.root,!0,0):-1===i?new Iv(e,e===t.root,0):function TG(n,t,e){let i=n,r=t,s=e;for(;s>r;){if(s-=r,i=i.parent,!i)throw new Error("Invalid number of '../'");r=i.segments.length}return new Iv(i,!1,r-s)}(e,i+(zh(n.commands[0])?0:1),n.numberOfDoubleDots)}(a,t,null===(f=n.snapshot)||void 0===f?void 0:f._urlSegment,d),k=w.processChildren?$h(w.segmentGroup,w.index,a.commands):kT(w.segmentGroup,w.index,a.commands);return Av(t.root,w.segmentGroup,k,i,r)}(null===(s=n.snapshot)||void 0===s?void 0:s._lastPathIndex)}(c,this.currentUrlTree,e,f,null!=d?d:null)}navigateByUrl(e,i={skipLocationChange:!1}){const r=xo(e)?e:this.parseUrl(e),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,"imperative",null,i)}navigate(e,i={skipLocationChange:!1}){return function LW(n){for(let t=0;t{const s=e[r];return null!=s&&(i[r]=s),i},{})}processNavigations(){this.navigations.subscribe(e=>{var i;this.navigated=!0,this.lastSuccessfulId=e.id,this.currentPageId=e.targetPageId,this.events.next(new Ec(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(this.currentUrlTree))),this.lastSuccessfulNavigation=this.currentNavigation,null===(i=this.titleStrategy)||void 0===i||i.updateTitle(this.routerState.snapshot),e.resolve(!0)},e=>{this.console.warn(`Unhandled Navigation Error: ${e}`)})}scheduleNavigation(e,i,r,s,o){var a,l;if(this.disposed)return Promise.resolve(!1);let c,d,f;o?(c=o.resolve,d=o.reject,f=o.promise):f=new Promise((j,K)=>{c=j,d=K});const w=++this.navigationId;let k;return"computed"===this.canceledNavigationResolution?(0===this.currentPageId&&(r=this.location.getState()),k=r&&r.\u0275routerPageId?r.\u0275routerPageId:s.replaceUrl||s.skipLocationChange?null!==(a=this.browserPageId)&&void 0!==a?a:0:(null!==(l=this.browserPageId)&&void 0!==l?l:0)+1):k=0,this.setTransition({id:w,targetPageId:k,source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.rawUrlTree,rawUrl:e,extras:s,resolve:c,reject:d,promise:f,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),f.catch(j=>Promise.reject(j))}setBrowserUrl(e,i){const r=this.urlSerializer.serialize(e),s=Object.assign(Object.assign({},i.extras.state),this.generateNgRouterState(i.id,i.targetPageId));this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl?this.location.replaceState(r,"",s):this.location.go(r,"",s)}restoreHistory(e,i=!1){var r,s;if("computed"===this.canceledNavigationResolution){const o=this.currentPageId-e.targetPageId;"popstate"!==e.source&&"eager"!==this.urlUpdateStrategy&&this.currentUrlTree!==(null===(r=this.currentNavigation)||void 0===r?void 0:r.finalUrl)||0===o?this.currentUrlTree===(null===(s=this.currentNavigation)||void 0===s?void 0:s.finalUrl)&&0===o&&(this.resetState(e),this.browserUrlTree=e.currentUrlTree,this.resetUrlToCurrentUrlTree()):this.location.historyGo(o)}else"replace"===this.canceledNavigationResolution&&(i&&this.resetState(e),this.resetUrlToCurrentUrlTree())}resetState(e){this.routerState=e.currentRouterState,this.currentUrlTree=e.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e.rawUrl)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}cancelNavigationTransition(e,i){const r=new rT(e.id,this.serializeUrl(e.extractedUrl),i);this.triggerEvent(r),e.resolve(!1)}generateNgRouterState(e,i){return"computed"===this.canceledNavigationResolution?{navigationId:e,\u0275routerPageId:i}:{navigationId:e}}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function XT(n){return"imperative"!==n}let Xh=(()=>{class n{constructor(e,i,r){this.router=e,this.route=i,this.locationStrategy=r,this.commands=null,this.href=null,this.onChanges=new ue,this.subscription=e.events.subscribe(s=>{s instanceof Ec&&this.updateTargetUrlAndHref()})}set routerLink(e){this.commands=null!=e?Array.isArray(e)?e:[e]:null}ngOnChanges(e){this.updateTargetUrlAndHref(),this.onChanges.next(this)}ngOnDestroy(){this.subscription.unsubscribe()}onClick(e,i,r,s,o){if(0!==e||i||r||s||o||"string"==typeof this.target&&"_self"!=this.target||null===this.urlTree)return!0;const a={skipLocationChange:ts(this.skipLocationChange),replaceUrl:ts(this.replaceUrl),state:this.state};return this.router.navigateByUrl(this.urlTree,a),!1}updateTargetUrlAndHref(){this.href=null!==this.urlTree?this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree)):null}get urlTree(){return null===this.commands?null:this.router.createUrlTree(this.commands,{relativeTo:void 0!==this.relativeTo?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:ts(this.preserveFragment)})}}return n.\u0275fac=function(e){return new(e||n)(x(Ri),x($a),x(ya))},n.\u0275dir=Me({type:n,selectors:[["a","routerLink",""],["area","routerLink",""]],hostVars:2,hostBindings:function(e,i){1&e&&$e("click",function(s){return i.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),2&e&&wt("target",i.target)("href",i.href,Kf)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",preserveFragment:"preserveFragment",skipLocationChange:"skipLocationChange",replaceUrl:"replaceUrl",state:"state",relativeTo:"relativeTo",routerLink:"routerLink"},features:[cn]}),n})();class JT{buildTitle(t){var e;let i,r=t.root;for(;void 0!==r;)i=null!==(e=this.getResolvedTitleForRoute(r))&&void 0!==e?e:i,r=r.children.find(s=>s.outlet===Et);return i}getResolvedTitleForRoute(t){return t.data[Nv]}}let VW=(()=>{class n extends JT{constructor(e){super(),this.title=e}updateTitle(e){const i=this.buildTitle(e);void 0!==i&&this.title.setTitle(i)}}return n.\u0275fac=function(e){return new(e||n)(te(OE))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class eA{}class tA{preload(t,e){return tt(null)}}let nA=(()=>{class n{constructor(e,i,r,s,o){this.router=e,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(yn(e=>e instanceof Ec),Da(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(e,i){var r,s,o;const a=[];for(const l of i){l.providers&&!l._injector&&(l._injector=Nd(l.providers,e,`Route: ${l.path}`));const c=null!==(r=l._injector)&&void 0!==r?r:e,d=null!==(s=l._loadedInjector)&&void 0!==s?s:c;l.loadChildren&&!l._loadedRoutes||l.loadComponent&&!l._loadedComponent?a.push(this.preloadConfig(c,l)):(l.children||l._loadedRoutes)&&a.push(this.processRoutes(d,null!==(o=l.children)&&void 0!==o?o:l._loadedRoutes))}return gn(a).pipe(To())}preloadConfig(e,i){return this.preloadingStrategy.preload(i,()=>{let r;r=i.loadChildren&&void 0===i.canLoad?this.loader.loadChildren(e,i):tt(null);const s=r.pipe(Pn(o=>{var a;return null===o?tt(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(null!==(a=o.injector)&&void 0!==a?a:e,o.routes))}));return i.loadComponent&&!i._loadedComponent?gn([s,this.loader.loadComponent(i)]).pipe(To()):s})}}return n.\u0275fac=function(e){return new(e||n)(te(Ri),te(Rm),te(Qs),te(eA),te(Vv))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})(),jv=(()=>{class n{constructor(e,i,r={}){this.router=e,this.viewportScroller=i,this.options=r,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},r.scrollPositionRestoration=r.scrollPositionRestoration||"disabled",r.anchorScrolling=r.anchorScrolling||"disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.router.events.subscribe(e=>{e instanceof Cv?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=e.navigationTrigger,this.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof Ec&&(this.lastId=e.id,this.scheduleScrollEvent(e,this.router.parseUrl(e.urlAfterRedirects).fragment))})}consumeScrollEvents(){return this.router.events.subscribe(e=>{e instanceof sT&&(e.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(e.position):e.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(e.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(e,i){this.router.triggerEvent(new sT(e,"popstate"===this.lastSource?this.store[this.restoredId]:null,i))}ngOnDestroy(){this.routerEventsSubscription&&this.routerEventsSubscription.unsubscribe(),this.scrollEventsSubscription&&this.scrollEventsSubscription.unsubscribe()}}return n.\u0275fac=function(e){bs()},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();const So=new De("ROUTER_CONFIGURATION"),iA=new De("ROUTER_FORROOT_GUARD"),jW=[Vl,{provide:mT,useClass:gT},{provide:Ri,useFactory:function WW(n,t,e,i,r,s,o={},a,l,c,d){const f=new Ri(null,n,t,e,i,r,lT(s));return c&&(f.urlHandlingStrategy=c),d&&(f.routeReuseStrategy=d),f.titleStrategy=null!=l?l:a,function qW(n,t){n.errorHandler&&(t.errorHandler=n.errorHandler),n.malformedUriErrorHandler&&(t.malformedUriErrorHandler=n.malformedUriErrorHandler),n.onSameUrlNavigation&&(t.onSameUrlNavigation=n.onSameUrlNavigation),n.paramsInheritanceStrategy&&(t.paramsInheritanceStrategy=n.paramsInheritanceStrategy),n.relativeLinkResolution&&(t.relativeLinkResolution=n.relativeLinkResolution),n.urlUpdateStrategy&&(t.urlUpdateStrategy=n.urlUpdateStrategy),n.canceledNavigationResolution&&(t.canceledNavigationResolution=n.canceledNavigationResolution)}(o,f),f},deps:[mT,Tc,Vl,Jt,Rm,Bv,So,VW,[JT,new Hn],[class TW{},new Hn],[class xW{},new Hn]]},Tc,{provide:$a,useFactory:function YW(n){return n.routerState.root},deps:[Ri]},nA,tA,class HW{preload(t,e){return e().pipe(os(()=>tt(null)))}},{provide:So,useValue:{enableTracing:!1}},Vv];function UW(){return new xD("Router",Ri)}let rA=(()=>{class n{constructor(e,i){}static forRoot(e,i){return{ngModule:n,providers:[jW,sA(e),{provide:iA,useFactory:GW,deps:[[Ri,new Hn,new ir]]},{provide:So,useValue:i||{}},{provide:ya,useFactory:$W,deps:[Bl,[new cd($m),new Hn],So]},{provide:jv,useFactory:zW,deps:[Ri,DV,So]},{provide:eA,useExisting:i&&i.preloadingStrategy?i.preloadingStrategy:tA},{provide:xD,multi:!0,useFactory:UW},[Uv,{provide:Am,multi:!0,useFactory:KW,deps:[Uv]},{provide:oA,useFactory:QW,deps:[Uv]},{provide:bD,multi:!0,useExisting:oA}]]}}static forChild(e){return{ngModule:n,providers:[sA(e)]}}}return n.\u0275fac=function(e){return new(e||n)(te(iA,8),te(Ri,8))},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();function zW(n,t,e){return e.scrollOffset&&t.setOffset(e.scrollOffset),new jv(n,t,e)}function $W(n,t,e={}){return e.useHash?new hB(n,t):new KD(n,t)}function GW(n){return"guarded"}function sA(n){return[{provide:$I,multi:!0,useValue:n},{provide:Bv,multi:!0,useValue:n}]}let Uv=(()=>{class n{constructor(e){this.injector=e,this.initNavigation=!1,this.destroyed=!1,this.resultOfPreactivationDone=new ue}appInitializer(){return this.injector.get(cB,Promise.resolve(null)).then(()=>{if(this.destroyed)return Promise.resolve(!0);let i=null;const r=new Promise(a=>i=a),s=this.injector.get(Ri),o=this.injector.get(So);return"disabled"===o.initialNavigation?(s.setUpLocationChangeListener(),i(!0)):"enabledBlocking"===o.initialNavigation?(s.hooks.afterPreactivation=()=>this.initNavigation?tt(null):(this.initNavigation=!0,i(!0),this.resultOfPreactivationDone),s.initialNavigation()):i(!0),r})}bootstrapListener(e){const i=this.injector.get(So),r=this.injector.get(nA),s=this.injector.get(jv),o=this.injector.get(Ri),a=this.injector.get(Ll);e===a.components[0]&&(("enabledNonBlocking"===i.initialNavigation||void 0===i.initialNavigation)&&o.initialNavigation(),r.setUpPreloading(),s.init(),o.resetRootComponentType(a.componentTypes[0]),this.resultOfPreactivationDone.next(null),this.resultOfPreactivationDone.complete())}ngOnDestroy(){this.destroyed=!0}}return n.\u0275fac=function(e){return new(e||n)(te(Jt))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac}),n})();function KW(n){return n.appInitializer.bind(n)}function QW(n){return n.bootstrapListener.bind(n)}const oA=new De("Router Initializer");class XW{constructor(t){this.request=t}}let Or=(()=>{class n{constructor(){this.pages=[{page:"home",caption:"Home"}],this.apiLog=new Array,this.pipelineMap=new Map}cameraIsOnvif(){return void 0!==this.cameraFeatures&&"Onvif"===this.cameraFeatures.CameraType}cameraIsUSB(){return void 0!==this.cameraFeatures&&"USB"===this.cameraFeatures.CameraType}getUSBConfig(){const e=this.inputPixelFormat?this.imageFormats[this.inputPixelFormat]:void 0,i=e&&this.inputImageSize?e.FrameSizes[this.inputImageSize].Size:void 0;return{InputFps:this.inputFps,InputImageSize:i?i.MaxWidth+"x"+i.MaxHeight:void 0,InputPixelFormat:e?e.PixelFormat:void 0,OutputVideoQuality:this.outputVideoQuality}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Fr_mqtt_port=59001,Fr_mqtt_path="/mqtt",Fr_mqtt_topic="incoming/data/edge-video-analytics/inference-event";class Fc{static forUSB(t,e,i){const r=new Fc;return r.usb=i,r.pipeline_name=t,r.pipeline_version=e,r}static forOnvif(t,e,i){const r=new Fc;return r.onvif=i,r.pipeline_name=t,r.pipeline_version=e,r}}const zv="X-CameraApp-Ignore",aA={headers:new Wi({"Content-Type":"application/json; charset=utf-8"})};let Jh=(()=>{class n{constructor(e,i){this.httpClient=e,this.data=i,this.camerasUrl="/api/v3/cameras"}makeCameraUrl(e,i){return`${this.camerasUrl}/${e}${i}`}makePipelineUrl(e,i){return this.makeCameraUrl(e,`/pipeline${i}`)}makeProfileUrl(e,i,r){return this.makeCameraUrl(e,`/profiles/${i}`)+r}makePresetUrl(e,i,r){return this.makeProfileUrl(e,i,"/presets/")+r}updateCameraList(){this.data.cameras=void 0,this.data.cameraMap=void 0,this.httpClient.get(this.camerasUrl).subscribe({next:e=>{this.data.cameras=e,this.data.cameraMap=new Map;for(let i of e)this.data.cameraMap.set(i.name,i);e.length>0?(this.data.selectedCamera=e[0].name,this.updateCameraChanged(this.data.selectedCamera),this.refreshPipelineStatus(this.data.selectedCamera,!0)):this.data.selectedCamera=void 0},error:e=>{this.data.cameras=void 0,this.data.cameraMap=void 0}})}clearCameraInfo(){this.data.selectedProfile=void 0,this.data.profiles=void 0,this.data.selectedPreset=void 0,this.data.presets=void 0,this.data.imageFormats=void 0,this.data.inputPixelFormat=void 0,this.data.inputImageSize=void 0,this.data.cameraFeatures=void 0}updateCameraChanged(e){this.clearCameraInfo(),this.updateCameraFeatures(e)}updateCameraFeatures(e){this.httpClient.get(this.makeCameraUrl(e,"/features")).subscribe({next:i=>{this.data.cameraFeatures=i,this.data.cameraIsOnvif()?this.updateProfiles(e):this.data.cameraIsUSB()?this.updateImageFormats(e):console.log("error, invalid camera type: "+i.CameraType)},error:i=>{}})}updateProfiles(e){this.httpClient.get(this.makeCameraUrl(e,"/profiles")).subscribe({next:i=>{this.data.profiles=i.Profiles,this.data.selectedProfile=i.Profiles.length>0?i.Profiles[0].Token:void 0,this.updatePresets(e,this.data.selectedProfile)},error:i=>{this.data.selectedProfile=void 0,this.data.profiles=void 0}})}updatePresets(e,i){this.httpClient.get(this.makeProfileUrl(e,i,"/presets")).subscribe({next:r=>{this.data.presets=r.Preset,this.data.selectedPreset=r.Preset.length>0?r.Preset[0].Token:void 0},error:r=>{this.data.presets=void 0}})}updateImageFormats(e){this.data.imageFormats=void 0,this.httpClient.get(this.makeCameraUrl(e,"/imageformats")).subscribe({next:i=>{this.data.imageFormats=i.ImageFormats},error:i=>{this.data.imageFormats=void 0}})}gotoPreset(e,i,r){return this.httpClient.post(this.makePresetUrl(e,i,r),"").subscribe()}startOnvifPipeline(e,i,r,s){let o=this.makePipelineUrl(e,"/start"),a=Fc.forOnvif(i,r,{profile_token:s});this.httpClient.post(o,JSON.stringify(a),aA).subscribe(l=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}startUSBPipeline(e,i,r,s){let o=this.makePipelineUrl(e,"/start"),a=Fc.forUSB(i,r,s);this.httpClient.post(o,JSON.stringify(a),aA).subscribe(l=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}stopPipeline(e,i){let r=this.makePipelineUrl(e,`/stop/${i}`);this.httpClient.post(r,"").subscribe(s=>{this.refreshPipelineStatus(this.data.selectedCamera,!0)})}refreshPipelineStatus(e,i){let r=this.makePipelineUrl(e,"/status"),s={};i&&(s[zv]="true"),this.httpClient.get(r,{headers:new Wi(s)}).subscribe({next:o=>{this.data.pipelineStatus=o},error:o=>{this.data.pipelineStatus=void 0}})}refreshAllPipelineStatuses(){this.httpClient.get("/api/v3/pipelines/status/all",{headers:new Wi({"X-CameraApp-Ignore":"true"})}).subscribe({next:r=>{if(null!=r){for(const s of this.data.pipelineMap.keys())r.hasOwnProperty(s)||(console.log("deleting key:",s),this.data.pipelineMap.delete(s));for(const[s,o]of Object.entries(r)){let a=this.data.pipelineMap.get(s);void 0===a?this.data.pipelineMap.set(s,o):(a.status=o.status,a.info=o.info)}}else this.data.pipelineMap.clear()},error:r=>{this.data.pipelineMap.clear()}})}updatePipelinesList(){this.data.pipelines=void 0,this.httpClient.get("/api/v3/pipelines").subscribe({next:e=>{this.data.pipelines=e.filter(i=>!!this.shouldShowPipeline(i)&&("object_detection/person_vehicle_bike"==`${i.name}/${i.version}`&&(this.data.selectedPipeline="object_detection/person_vehicle_bike"),!0))},error:e=>{this.data.pipelines=void 0}})}shouldShowPipeline(e){return"audio_detection"!==e.name&&"video_decode"!==e.name&&"app_src_dst"!==e.version&&"object_zone_count"!==e.version&&"object_line_crossing"!==e.version}}return n.\u0275fac=function(e){return new(e||n)(te(nc),te(Or))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();var JW=ps(841),lA=ps(703);class tq extends ue{constructor(t=1/0,e=1/0,i=E_){super(),this._bufferSize=t,this._windowTime=e,this._timestampProvider=i,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=e===1/0,this._bufferSize=Math.max(1,t),this._windowTime=Math.max(1,e)}next(t){const{isStopped:e,_buffer:i,_infiniteTimeWindow:r,_timestampProvider:s,_windowTime:o}=this;e||(i.push(t),!r&&i.push(s.now()+o)),this._trimBuffer(),super.next(t)}_subscribe(t){this._throwIfClosed(),this._trimBuffer();const e=this._innerSubscribe(t),{_infiniteTimeWindow:i,_buffer:r}=this,s=r.slice();for(let o=0;onew ue};function cA(n,t=iq){const{connector:e}=t;return Pe((i,r)=>{const s=e();gn(n(function nq(n){return new J(t=>n.subscribe(t))}(s))).subscribe(r),r.add(i.subscribe(s))})}function dA(n,t){const e=ut(n)?n:()=>n;return ut(t)?cA(t,{connector:e}):i=>new yv(i,e)}var Bs=(()=>{return(n=Bs||(Bs={}))[n.CLOSED=0]="CLOSED",n[n.CONNECTING=1]="CONNECTING",n[n.CONNECTED=2]="CONNECTED",Bs;var n})();const $v=new De("NgxMqttServiceConfig"),Gv=new De("NgxMqttClientService");let oq=(()=>{class n{static forRoot(e,i){return{ngModule:n,providers:[{provide:$v,useValue:e},{provide:Gv,useValue:i}]}}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})(),aq=(()=>{class n{constructor(e,i){this.options=e,this.client=i,this.observables={},this.state=new mi(Bs.CLOSED),this.messages=new ue,this._clientId=this._generateClientId(),this._connectTimeout=1e4,this._reconnectPeriod=1e4,this._url=void 0,this._onConnect=new je,this._onReconnect=new je,this._onClose=new je,this._onOffline=new je,this._onError=new je,this._onEnd=new je,this._onMessage=new je,this._onSuback=new je,this._onPacketsend=new je,this._onPacketreceive=new je,this._handleOnConnect=r=>{!0===this.options.connectOnCreate&&Object.keys(this.observables).forEach(s=>{this.client.subscribe(s)}),this.state.next(Bs.CONNECTED),this._onConnect.emit(r)},this._handleOnReconnect=()=>{!0===this.options.connectOnCreate&&Object.keys(this.observables).forEach(r=>{this.client.subscribe(r)}),this.state.next(Bs.CONNECTING),this._onReconnect.emit()},this._handleOnClose=()=>{this.state.next(Bs.CLOSED),this._onClose.emit()},this._handleOnOffline=()=>{this._onOffline.emit()},this._handleOnError=r=>{this._onError.emit(r),console.error(r)},this._handleOnEnd=()=>{this._onEnd.emit()},this._handleOnMessage=(r,s,o)=>{this._onMessage.emit(o),"publish"===o.cmd&&this.messages.next(o)},this._handleOnPacketsend=r=>{this._onPacketsend.emit()},this._handleOnPacketreceive=r=>{this._onPacketreceive.emit()},!1!==e.connectOnCreate&&this.connect({},i),this.state.subscribe()}get clientId(){return this._clientId}get onConnect(){return this._onConnect}get onReconnect(){return this._onReconnect}get onClose(){return this._onClose}get onOffline(){return this._onOffline}get onError(){return this._onError}get onEnd(){return this._onEnd}get onMessage(){return this._onMessage}get onPacketsend(){return this._onPacketsend}get onPacketreceive(){return this._onPacketreceive}get onSuback(){return this._onSuback}static filterMatchesTopic(e,i){if("#"===e[0]&&"$"===i[0])return!1;const r=(e||"").split("/").reverse(),s=(i||"").split("/").reverse(),o=()=>{const a=r.pop(),l=s.pop();switch(a){case"#":return!0;case"+":return!!l&&o();default:return a===l&&(void 0===a||o())}};return o()}connect(e,i){const r=lA(this.options||{},e),s=r.protocol||"ws",o=r.hostname||"localhost";r.url?this._url=r.url:(this._url=`${s}://${o}`,this._url+=r.port?`:${r.port}`:"",this._url+=r.path?`${r.path}`:""),this.state.next(Bs.CONNECTING);const a=lA({clientId:this._clientId,reconnectPeriod:this._reconnectPeriod,connectTimeout:this._connectTimeout},r);this.client&&this.client.end(!0),this.client=i||(0,JW.connect)(this._url,a),this._clientId=a.clientId,this.client.on("connect",this._handleOnConnect),this.client.on("reconnect",this._handleOnReconnect),this.client.on("close",this._handleOnClose),this.client.on("offline",this._handleOnOffline),this.client.on("error",this._handleOnError),this.client.stream.on("error",this._handleOnError),this.client.on("end",this._handleOnEnd),this.client.on("message",this._handleOnMessage),this.client.on("packetsend",this._handleOnPacketsend),this.client.on("packetreceive",this._handleOnPacketreceive)}disconnect(e=!0){if(!this.client)throw new Error("mqtt client not connected");this.client.end(e)}observeRetained(e,i={qos:1}){return this._generalObserve(e,()=>function rq(n,t,e,i){e&&!ut(e)&&(i=e);const r=ut(e)?e:void 0;return s=>dA(new tq(n,t,i),r)(s)}(1),i)}observe(e,i={qos:1}){return this._generalObserve(e,()=>function sq(n){return n?t=>cA(n)(t):t=>dA(new ue)(t)}(),i)}_generalObserve(e,i,r){if(!this.client)throw new Error("mqtt client not connected");if(!this.observables[e]){const s=new ue;this.observables[e]=function eq(n,t){return new J(e=>{const i=n(),r=t(i);return(r?di(r):Fi).subscribe(e),()=>{i&&i.unsubscribe()}})}(()=>{const o=new X;return this.client.subscribe(e,r,(a,l)=>{l&&l.forEach(c=>{128===c.qos&&(delete this.observables[c.topic],this.client.unsubscribe(c.topic),s.error(`subscription for '${c.topic}' rejected!`)),this._onSuback.emit({filter:e,granted:128!==c.qos})})}),o.add(()=>{delete this.observables[e],this.client.unsubscribe(e)}),o},o=>$n(s,this.messages)).pipe(yn(o=>n.filterMatchesTopic(e,o.topic)),i(),Lh())}return this.observables[e]}publish(e,i,r={}){if(!this.client)throw new Error("mqtt client not connected");return J.create(s=>{this.client.publish(e,i,r,o=>{o?s.error(o):(s.next(null),s.complete())})})}unsafePublish(e,i,r={}){if(!this.client)throw new Error("mqtt client not connected");this.client.publish(e,i,r,s=>{if(s)throw s})}_generateClientId(){return"client-"+Math.random().toString(36).substr(2,19)}}return n.\u0275fac=function(e){return new(e||n)(te($v),te(Gv))},n.\u0275prov=Ie({factory:function(){return new n(te($v),te(Gv))},token:n,providedIn:"root"}),n})(),Wv=(()=>{class n{constructor(e){this._mqttService=e,this.paused=!0,this.eventCount=0}isPaused(){return this.paused}pause(){this.paused||(this.paused=!0,this.unsubscribe())}resume(){this.paused&&(this.paused=!1,this.subscribe())}unsubscribe(){this.subscription&&(this.subscription.unsubscribe(),this.subscription=void 0)}subscribe(){this.subscription=this._mqttService.observe(Fr_mqtt_topic).subscribe(e=>{this.lastEvent=JSON.parse(e.payload.toString()),this.eventCount++})}}return n.\u0275fac=function(e){return new(e||n)(te(aq))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),lq=(()=>{class n{constructor(e,i){this.httpClient=e,this.data=i}makePtzUrl(e,i,r){return`/api/v3/cameras/${e}/profiles/${i}/ptz${r}`}post(e,i,r){let s=this.makePtzUrl(e,i,r);return this.httpClient.post(s,"").subscribe()}downLeft(e,i){return this.post(e,i,"/down-left")}down(e,i){return this.post(e,i,"/down")}downRight(e,i){return this.post(e,i,"/down-right")}upLeft(e,i){return this.post(e,i,"/up-left")}up(e,i){return this.post(e,i,"/up")}upRight(e,i){return this.post(e,i,"/up-right")}left(e,i){return this.post(e,i,"/left")}right(e,i){return this.post(e,i,"/right")}home(e,i){return this.post(e,i,"/home")}zoomIn(e,i){return this.post(e,i,"/zoom-in")}zoomOut(e,i){return this.post(e,i,"/zoom-out")}}return n.\u0275fac=function(e){return new(e||n)(te(nc),te(Or))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function cq(n,t){if(1&n&&(fe(0,"mat-option",9),Ue(1),we()),2&n){const e=t.$implicit;Ae("value",e.Token),Ee(1),Ln(" ",void 0===e.Name||""===e.Name?e.Token:e.Name," ")}}function dq(n,t){if(1&n){const e=ki();fe(0,"div",4),kt(1,"br"),fe(2,"mat-form-field",5)(3,"mat-label"),Ue(4,"Select Preset"),we(),fe(5,"mat-select",6),$e("ngModelChange",function(r){return Bn(e),Vn(lt().data.selectedPreset=r)}),it(6,cq,2,2,"mat-option",7),we()(),fe(7,"button",8),$e("click",function(){Bn(e);const r=lt();return Vn(r.api.gotoPreset(r.data.selectedCamera,r.data.selectedProfile,r.data.selectedPreset))}),Ue(8," Goto Preset "),we()()}if(2&n){const e=lt();Ee(5),Ae("ngModel",e.data.selectedPreset),Ee(1),Ae("ngForOf",e.data.presets),Ee(1),Ae("disabled",void 0===e.data.selectedPreset)}}let uq=(()=>{class n{constructor(e,i,r){this.data=e,this.ptz=i,this.api=r}ngOnInit(){}ngOnDestroy(){}isPtzDisabled(){return void 0===this.data.cameraFeatures||!1===this.data.cameraFeatures.PTZ}isZoomDisabled(){return void 0===this.data.cameraFeatures||!1===this.data.cameraFeatures.Zoom}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(lq),x(Jh))},n.\u0275cmp=vt({type:n,selectors:[["app-ptz"]],decls:37,vars:12,consts:[["mat-icon-button","",3,"disabled","click"],["mat-icon-button","",3,"disabled"],[1,"center-button"],["class","goto-presets",4,"ngIf"],[1,"goto-presets"],["appearance","fill"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["mat-raised-button","","color","primary",1,"preset-button",3,"disabled","click"],[3,"value"]],template:function(e,i){1&e&&(fe(0,"div")(1,"button",0),$e("click",function(){return i.ptz.upLeft(i.data.selectedCamera,i.data.selectedProfile)}),fe(2,"mat-icon"),Ue(3,"north_west"),we()(),fe(4,"button",0),$e("click",function(){return i.ptz.up(i.data.selectedCamera,i.data.selectedProfile)}),fe(5,"mat-icon"),Ue(6,"north"),we()(),fe(7,"button",0),$e("click",function(){return i.ptz.upRight(i.data.selectedCamera,i.data.selectedProfile)}),fe(8,"mat-icon"),Ue(9,"north_east"),we()(),fe(10,"button",0),$e("click",function(){return i.ptz.zoomIn(i.data.selectedCamera,i.data.selectedProfile)}),fe(11,"mat-icon"),Ue(12,"zoom_in"),we()()(),fe(13,"div")(14,"button",0),$e("click",function(){return i.ptz.left(i.data.selectedCamera,i.data.selectedProfile)}),fe(15,"mat-icon"),Ue(16,"west"),we()(),fe(17,"button",1)(18,"mat-icon",2),Ue(19,"circle"),we()(),fe(20,"button",0),$e("click",function(){return i.ptz.right(i.data.selectedCamera,i.data.selectedProfile)}),fe(21,"mat-icon"),Ue(22,"east"),we()(),fe(23,"button",0),$e("click",function(){return i.ptz.zoomOut(i.data.selectedCamera,i.data.selectedProfile)}),fe(24,"mat-icon"),Ue(25,"zoom_out"),we()()(),fe(26,"div")(27,"button",0),$e("click",function(){return i.ptz.downLeft(i.data.selectedCamera,i.data.selectedProfile)}),fe(28,"mat-icon"),Ue(29,"south_west"),we()(),fe(30,"button",0),$e("click",function(){return i.ptz.down(i.data.selectedCamera,i.data.selectedProfile)}),fe(31,"mat-icon"),Ue(32,"south"),we()(),fe(33,"button",0),$e("click",function(){return i.ptz.downRight(i.data.selectedCamera,i.data.selectedProfile)}),fe(34,"mat-icon"),Ue(35,"south_east"),we()()(),it(36,dq,9,3,"div",3)),2&e&&(Ee(1),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isZoomDisabled()),Ee(4),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",!0),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isZoomDisabled()),Ee(4),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("disabled",i.isPtzDisabled()),Ee(3),Ae("ngIf",null!=i.data.presets&&i.data.presets.length>0))},dependencies:[ao,zi,ex,Xg,Aa,GS,ch,Eh,xk,Y_],styles:[".mat-icon-button[_ngcontent-%COMP%]{width:auto;height:auto;margin:5px}.material-icons[_ngcontent-%COMP%]{zoom:2}.preset-button[_ngcontent-%COMP%]{margin:10px}.center-button[_ngcontent-%COMP%]{color:transparent;background-color:transparent}"]}),n})(),hq=0;const qv=new De("CdkAccordion");let fq=(()=>{class n{constructor(){this._stateChanges=new ue,this._openCloseAllActions=new ue,this.id="cdk-accordion-"+hq++,this._multi=!1}get multi(){return this._multi}set multi(e){this._multi=rt(e)}openAll(){this._multi&&this._openCloseAllActions.next(!0)}closeAll(){this._openCloseAllActions.next(!1)}ngOnChanges(e){this._stateChanges.next(e)}ngOnDestroy(){this._stateChanges.complete(),this._openCloseAllActions.complete()}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:"multi"},exportAs:["cdkAccordion"],features:[Xe([{provide:qv,useExisting:n}]),cn]}),n})(),pq=0,mq=(()=>{class n{constructor(e,i,r){this.accordion=e,this._changeDetectorRef=i,this._expansionDispatcher=r,this._openCloseAllSubscription=X.EMPTY,this.closed=new je,this.opened=new je,this.destroyed=new je,this.expandedChange=new je,this.id="cdk-accordion-child-"+pq++,this._expanded=!1,this._disabled=!1,this._removeUniqueSelectionListener=()=>{},this._removeUniqueSelectionListener=r.listen((s,o)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===o&&this.id!==s&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}get expanded(){return this._expanded}set expanded(e){e=rt(e),this._expanded!==e&&(this._expanded=e,this.expandedChange.emit(e),e?(this.opened.emit(),this._expansionDispatcher.notify(this.id,this.accordion?this.accordion.id:this.id)):this.closed.emit(),this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled}set disabled(e){this._disabled=rt(e)}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}}return n.\u0275fac=function(e){return new(e||n)(x(qv,12),x(en),x(Q_))},n.\u0275dir=Me({type:n,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:"expanded",disabled:"disabled"},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[Xe([{provide:qv,useValue:void 0}])]}),n})(),gq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({}),n})();const _q=["body"];function vq(n,t){}const yq=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],bq=["mat-expansion-panel-header","*","mat-action-row"];function wq(n,t){1&n&&kt(0,"span",2),2&n&&Ae("@indicatorRotate",lt()._getExpandedState())}const Cq=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],Dq=["mat-panel-title","mat-panel-description","*"],Yv=new De("MAT_ACCORDION"),uA="225ms cubic-bezier(0.4,0.0,0.2,1)",hA={indicatorRotate:jn("indicatorRotate",[zt("collapsed, void",Qe({transform:"rotate(0deg)"})),zt("expanded",Qe({transform:"rotate(180deg)"})),Wt("expanded <=> collapsed, void => collapsed",Zt(uA))]),bodyExpansion:jn("bodyExpansion",[zt("collapsed, void",Qe({height:"0px",visibility:"hidden"})),zt("expanded",Qe({height:"*",visibility:"visible"})),Wt("expanded <=> collapsed, void => collapsed",Zt(uA))])},fA=new De("MAT_EXPANSION_PANEL");let Eq=(()=>{class n{constructor(e,i){this._template=e,this._expansionPanel=i}}return n.\u0275fac=function(e){return new(e||n)(x(_n),x(fA,8))},n.\u0275dir=Me({type:n,selectors:[["ng-template","matExpansionPanelContent",""]]}),n})(),Mq=0;const pA=new De("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS");let Kv=(()=>{class n extends mq{constructor(e,i,r,s,o,a,l){super(e,i,r),this._viewContainerRef=s,this._animationMode=a,this._hideToggle=!1,this.afterExpand=new je,this.afterCollapse=new je,this._inputChanges=new ue,this._headerId="mat-expansion-panel-header-"+Mq++,this._bodyAnimationDone=new ue,this.accordion=e,this._document=o,this._bodyAnimationDone.pipe(k_((c,d)=>c.fromState===d.fromState&&c.toState===d.toState)).subscribe(c=>{"void"!==c.fromState&&("expanded"===c.toState?this.afterExpand.emit():"collapsed"===c.toState&&this.afterCollapse.emit())}),l&&(this.hideToggle=l.hideToggle)}get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=rt(e)}get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_hasSpacing(){return!!this.accordion&&this.expanded&&"default"===this.accordion.displayMode}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(Qn(null),yn(()=>this.expanded&&!this._portal),sn(1)).subscribe(()=>{this._portal=new mc(this._lazyContent._template,this._viewContainerRef)})}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._bodyAnimationDone.complete(),this._inputChanges.complete()}_containsFocus(){if(this._body){const e=this._document.activeElement,i=this._body.nativeElement;return e===i||i.contains(e)}return!1}}return n.\u0275fac=function(e){return new(e||n)(x(Yv,12),x(en),x(Q_),x(An),x(ct),x(fn,8),x(pA,8))},n.\u0275cmp=vt({type:n,selectors:[["mat-expansion-panel"]],contentQueries:function(e,i,r){if(1&e&&It(r,Eq,5),2&e){let s;Ge(s=We())&&(i._lazyContent=s.first)}},viewQuery:function(e,i){if(1&e&&Gt(_q,5),2&e){let r;Ge(r=We())&&(i._body=r.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:6,hostBindings:function(e,i){2&e&&At("mat-expanded",i.expanded)("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-expansion-panel-spacing",i._hasSpacing())},inputs:{disabled:"disabled",expanded:"expanded",hideToggle:"hideToggle",togglePosition:"togglePosition"},outputs:{opened:"opened",closed:"closed",expandedChange:"expandedChange",afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[Xe([{provide:Yv,useValue:void 0},{provide:fA,useExisting:n}]),Le,cn],ngContentSelectors:bq,decls:7,vars:4,consts:[["role","region",1,"mat-expansion-panel-content",3,"id"],["body",""],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(e,i){1&e&&(Fn(yq),Tt(0),fe(1,"div",0,1),$e("@bodyExpansion.done",function(s){return i._bodyAnimationDone.next(s)}),fe(3,"div",2),Tt(4,1),it(5,vq,0,0,"ng-template",3),we(),Tt(6,2),we()),2&e&&(Ee(1),Ae("@bodyExpansion",i._getExpandedState())("id",i.id),wt("aria-labelledby",i._headerId),Ee(4),Ae("cdkPortalOutlet",i._portal))},dependencies:[Ra],styles:['.mat-expansion-panel{box-sizing:content-box;display:block;margin:0;border-radius:4px;overflow:hidden;transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);position:relative}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:4px;border-top-left-radius:4px}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:4px;border-bottom-left-radius:4px}.cdk-high-contrast-active .mat-expansion-panel{outline:solid 1px}.mat-expansion-panel.ng-animate-disabled,.ng-animate-disabled .mat-expansion-panel,.mat-expansion-panel._mat-animation-noopable{transition:none}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible}.mat-expansion-panel-content[style*="visibility: hidden"] *{visibility:hidden !important}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px}.mat-action-row .mat-button-base,.mat-action-row .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row .mat-button-base,[dir=rtl] .mat-action-row .mat-mdc-button-base{margin-left:0;margin-right:8px}'],encapsulation:2,data:{animation:[hA.bodyExpansion]},changeDetection:0}),n})();class xq{}const Sq=yo(xq);let Qv=(()=>{class n extends Sq{constructor(e,i,r,s,o,a,l){super(),this.panel=e,this._element=i,this._focusMonitor=r,this._changeDetectorRef=s,this._animationMode=a,this._parentChangeSubscription=X.EMPTY;const c=e.accordion?e.accordion._stateChanges.pipe(yn(d=>!(!d.hideToggle&&!d.togglePosition))):Fi;this.tabIndex=parseInt(l||"")||0,this._parentChangeSubscription=$n(e.opened,e.closed,c,e._inputChanges.pipe(yn(d=>!!(d.hideToggle||d.disabled||d.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),e.closed.pipe(yn(()=>e._containsFocus())).subscribe(()=>r.focusVia(i,"program")),o&&(this.expandedHeight=o.expandedHeight,this.collapsedHeight=o.collapsedHeight)}get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){const e=this._isExpanded();return e&&this.expandedHeight?this.expandedHeight:!e&&this.collapsedHeight?this.collapsedHeight:null}_keydown(e){switch(e.keyCode){case 32:case 13:gi(e)||(e.preventDefault(),this._toggle());break;default:return void(this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(e))}}focus(e,i){e?this._focusMonitor.focusVia(this._element,e,i):this._element.nativeElement.focus(i)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(e=>{e&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}}return n.\u0275fac=function(e){return new(e||n)(x(Kv,1),x(Je),x(hr),x(en),x(pA,8),x(fn,8),ii("tabindex"))},n.\u0275cmp=vt({type:n,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:15,hostBindings:function(e,i){1&e&&$e("click",function(){return i._toggle()})("keydown",function(s){return i._keydown(s)}),2&e&&(wt("id",i.panel._headerId)("tabindex",i.tabIndex)("aria-controls",i._getPanelId())("aria-expanded",i._isExpanded())("aria-disabled",i.panel.disabled),Hi("height",i._getHeaderHeight()),At("mat-expanded",i._isExpanded())("mat-expansion-toggle-indicator-after","after"===i._getTogglePosition())("mat-expansion-toggle-indicator-before","before"===i._getTogglePosition())("_mat-animation-noopable","NoopAnimations"===i._animationMode))},inputs:{tabIndex:"tabIndex",expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight"},features:[Le],ngContentSelectors:Dq,decls:5,vars:1,consts:[[1,"mat-content"],["class","mat-expansion-indicator",4,"ngIf"],[1,"mat-expansion-indicator"]],template:function(e,i){1&e&&(Fn(Cq),fe(0,"span",0),Tt(1),Tt(2,1),Tt(3,2),we(),it(4,wq,1,1,"span",1)),2&e&&(Ee(4),Ae("ngIf",i._showToggle()))},dependencies:[zi],styles:['.mat-expansion-panel-header{display:flex;flex-direction:row;align-items:center;padding:0 24px;border-radius:inherit;transition:height 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header._mat-animation-noopable{transition:none}.mat-expansion-panel-header:focus,.mat-expansion-panel-header:hover{outline:none}.mat-expansion-panel-header.mat-expanded:focus,.mat-expansion-panel-header.mat-expanded:hover{background:inherit}.mat-expansion-panel-header:not([aria-disabled=true]){cursor:pointer}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before{flex-direction:row-reverse}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 16px 0 0}[dir=rtl] .mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 0 0 16px}.mat-content{display:flex;flex:1;flex-direction:row;overflow:hidden}.mat-expansion-panel-header-title,.mat-expansion-panel-header-description{display:flex;flex-grow:1;margin-right:16px;align-items:center}[dir=rtl] .mat-expansion-panel-header-title,[dir=rtl] .mat-expansion-panel-header-description{margin-right:0;margin-left:16px}.mat-expansion-panel-header-description{flex-grow:2}.mat-expansion-indicator::after{border-style:solid;border-width:0 2px 2px 0;content:"";display:inline-block;padding:3px;transform:rotate(45deg);vertical-align:middle}.cdk-high-contrast-active .mat-expansion-panel .mat-expansion-panel-header.cdk-keyboard-focused:not([aria-disabled=true])::before,.cdk-high-contrast-active .mat-expansion-panel .mat-expansion-panel-header.cdk-program-focused:not([aria-disabled=true])::before,.cdk-high-contrast-active .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover:not([aria-disabled=true])::before{top:0;left:0;right:0;bottom:0;position:absolute;box-sizing:border-box;pointer-events:none;border:3px solid;border-radius:4px;content:""}.cdk-high-contrast-active .mat-expansion-panel-content{border-top:1px solid;border-top-left-radius:0;border-top-right-radius:0}'],encapsulation:2,data:{animation:[hA.indicatorRotate]},changeDetection:0}),n})(),mA=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]}),n})(),gA=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=Me({type:n,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]}),n})(),_A=(()=>{class n extends fq{constructor(){super(...arguments),this._ownHeaders=new ma,this._hideToggle=!1,this.displayMode="default",this.togglePosition="after"}get hideToggle(){return this._hideToggle}set hideToggle(e){this._hideToggle=rt(e)}ngAfterContentInit(){this._headers.changes.pipe(Qn(this._headers)).subscribe(e=>{this._ownHeaders.reset(e.filter(i=>i.panel.accordion===this)),this._ownHeaders.notifyOnChanges()}),this._keyManager=new Wu(this._ownHeaders).withWrap().withHomeAndEnd()}_handleHeaderKeydown(e){this._keyManager.onKeydown(e)}_handleHeaderFocus(e){this._keyManager.updateActiveItem(e)}ngOnDestroy(){super.ngOnDestroy(),this._ownHeaders.destroy()}}return n.\u0275fac=function(){let t;return function(i){return(t||(t=Mt(n)))(i||n)}}(),n.\u0275dir=Me({type:n,selectors:[["mat-accordion"]],contentQueries:function(e,i,r){if(1&e&&It(r,Qv,5),2&e){let s;Ge(s=We())&&(i._headers=s)}},hostAttrs:[1,"mat-accordion"],hostVars:2,hostBindings:function(e,i){2&e&&At("mat-accordion-multi",i.multi)},inputs:{multi:"multi",hideToggle:"hideToggle",displayMode:"displayMode",togglePosition:"togglePosition"},exportAs:["matAccordion"],features:[Xe([{provide:Yv,useExisting:n}]),Le]}),n})(),kq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[pi,ht,gq,Os]}),n})();function Tq(n,t){if(1&n&&(fe(0,"mat-chip-list",5)(1,"mat-chip",6),Ue(2),we()()),2&n){const e=lt().$implicit;Ee(1),Ae("ngClass",e.response.ok?"ok-chip":"bad-chip"),Ee(1),El("",e.response.status,": ",e.response.statusText,"")}}function Aq(n,t){if(1&n&&(fe(0,"pre"),Ue(1),Jr(2,"json"),we()),2&n){const e=lt().$implicit;Ee(1),Kn(so(2,1,e.response.body))}}function Iq(n,t){if(1&n&&(fe(0,"pre"),Ue(1),Jr(2,"json"),we()),2&n){const e=lt().$implicit;Ee(1),Kn(so(2,1,e.response.error))}}function Rq(n,t){if(1&n&&(fe(0,"mat-expansion-panel")(1,"mat-expansion-panel-header")(2,"mat-panel-title")(3,"mat-chip-list",1)(4,"mat-chip",2),Ue(5),we()()(),fe(6,"mat-panel-description")(7,"span"),Ue(8),we()(),it(9,Tq,3,3,"mat-chip-list",3),we(),it(10,Aq,3,3,"pre",4),it(11,Iq,3,3,"pre",4),we()),2&n){const e=t.$implicit;Ee(4),Ae("ngClass","GET"===e.request.method?"request-get":"POST"===e.request.method?"request-post":""),Ee(1),Kn(e.request.method),Ee(3),Kn(e.request.url),Ee(1),Ae("ngIf",void 0!==e.response),Ee(1),Ae("ngIf",void 0!==e.response&&void 0!==e.response.body),Ee(1),Ae("ngIf",void 0!==e.response&&void 0!==e.response.error)}}let Pq=(()=>{class n{constructor(e){this.data=e}ngOnInit(){}ngOnDestroy(){}}return n.\u0275fac=function(e){return new(e||n)(x(Or))},n.\u0275cmp=vt({type:n,selectors:[["app-api-log"]],decls:2,vars:1,consts:[[4,"ngFor","ngForOf"],["selectable","false"],[1,"request-method",3,"ngClass"],["class","response-chips","selectable","false",4,"ngIf"],[4,"ngIf"],["selectable","false",1,"response-chips"],[3,"ngClass"]],template:function(e,i){1&e&&(fe(0,"mat-accordion"),it(1,Rq,12,6,"mat-expansion-panel",0),we()),2&e&&(Ee(1),Ae("ngForOf",i.data.apiLog))},dependencies:[eg,ao,zi,uh,Ia,_A,Kv,Qv,gA,mA,ru],styles:[".mat-expansion-panel-header-title[_ngcontent-%COMP%]{flex-grow:0}.mat-expansion-panel-header-description[_ngcontent-%COMP%]{text-align:left}.response-chips[_ngcontent-%COMP%]{margin-right:20px;flex:none}.request-method[_ngcontent-%COMP%]{width:60px;margin-right:10px;flex:none}.request-post[_ngcontent-%COMP%]{background-color:#0288d1;color:#fff}.request-get[_ngcontent-%COMP%]{background-color:#00838f;color:#fff;flex:none}.ok-chip[_ngcontent-%COMP%]{background-color:#09af00;color:#fff}.bad-chip[_ngcontent-%COMP%]{background-color:#c62828;color:#fff}pre[_ngcontent-%COMP%]{overflow-x:auto}"]}),n})();function Oq(n,t){if(1&n&&(fe(0,"mat-chip")(1,"mat-icon"),Ue(2),we(),fe(3,"span"),Ue(4),Jr(5,"number"),we()()),2&n){const e=t.$implicit,i=lt(2);Ee(2),Ln(" ",i.labelToIcon(e.detection.label)," "),Ee(2),Ln("",vm(5,2,100*e.detection.confidence,"2.0-0"),"%")}}function Fq(n,t){if(1&n&&(fe(0,"div")(1,"h3"),Ue(2),we(),fe(3,"div")(4,"mat-chip-list",1),it(5,Oq,6,5,"mat-chip",2),we()(),fe(6,"pre"),Ue(7),Jr(8,"json"),we()()),2&n){const e=lt();Ee(2),Ln("",e.eventService.eventCount," Total Events"),Ee(3),Ae("ngForOf",e.eventService.lastEvent.objects),Ee(2),Kn(so(8,3,e.eventService.lastEvent))}}let Lq=(()=>{class n{constructor(e,i){this.data=e,this.eventService=i}ngOnInit(){}ngOnDestroy(){}labelToIcon(e){switch(e){case"vehicle":return"directions_car";case"bicycle":return"pedal_bike";default:return e}}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-inference-events"]],decls:1,vars:1,consts:[[4,"ngIf"],["selectable","false"],[4,"ngFor","ngForOf"]],template:function(e,i){1&e&&it(0,Fq,9,5,"div",0),2&e&&Ae("ngIf",void 0!==i.eventService.lastEvent)},dependencies:[ao,zi,uh,Ia,Eh,ru,ng]}),n})();function Nq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",e.name),Ee(1),Ln(" ",e.name," ")}}function Bq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",e.Token),Ee(1),sm(" ",e.Token," (",e.VideoEncoderConfiguration.Resolution.Width,"x",e.VideoEncoderConfiguration.Resolution.Height," ",e.VideoEncoderConfiguration.Encoding," @ ",e.VideoEncoderConfiguration.RateControl.FrameRateLimit," fps) ")}}function Vq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select a video stream"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.selectedProfile=r)})("valueChange",function(r){return Bn(e),Vn(lt().profileSelectionChanged(r))}),it(5,Bq,2,6,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.selectedProfile),Ee(1),Ae("ngForOf",e.data.profiles)}}function Hq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",t.index),Ee(1),Kn(e.PixelFormat)}}function jq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select image format (optional)"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.inputPixelFormat=r)})("valueChange",function(r){return Bn(e),Vn(lt().pixelSelectionChanged(r))}),it(5,Hq,2,2,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.inputPixelFormat),Ee(1),Ae("ngForOf",e.data.imageFormats)}}function Uq(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;ca("value",t.index),Ee(1),El(" ",e.Size.MaxWidth,"x",e.Size.MaxHeight," ")}}function zq(n,t){if(1&n){const e=ki();fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select image resolution (optional)"),we(),fe(4,"mat-select",1),$e("valueChange",function(r){return Bn(e),Vn(lt().data.inputImageSize=r)}),it(5,Uq,2,3,"mat-option",2),we()()()}if(2&n){const e=lt();Ee(4),Ae("value",e.data.inputImageSize),Ee(1),Ae("ngForOf",e.data.imageSizes)}}function $q(n,t){if(1&n&&(fe(0,"mat-option",6),Ue(1),we()),2&n){const e=t.$implicit;nm("value","",e.name,"/",e.version,""),Ee(1),El(" ",e.name," - ",e.version," ")}}let Gq=(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.eventService=r}ngOnInit(){this.api.updateCameraList(),this.api.updatePipelinesList()}ngOnDestroy(){}cameraSelectionChanged(e){this.api.updateCameraChanged(e),this.api.refreshPipelineStatus(e,!0)}pixelSelectionChanged(e){this.data.imageSizes=this.data.imageFormats[e].FrameSizes}profileSelectionChanged(e){this.api.updatePresets(this.data.selectedCamera,e)}startPipeline(){const e=this.data.selectedPipeline.split("/");this.data.cameraIsOnvif()?this.api.startOnvifPipeline(this.data.selectedCamera,e[0],e[1],this.data.selectedProfile):this.api.startUSBPipeline(this.data.selectedCamera,e[0],e[1],this.data.getUSBConfig())}shouldDisablePipeline(){return void 0===this.data.selectedCamera||void 0===this.data.selectedProfile&&this.data.cameraIsOnvif()||void 0!==this.data.pipelineMap[this.data.selectedCamera]&&"RUNNING"===this.data.pipelineMap[this.data.selectedCamera].status.state}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-camera-selector"]],decls:17,vars:8,consts:[["appearance","fill"],[3,"value","valueChange"],[3,"value",4,"ngFor","ngForOf"],[4,"ngIf"],["appearance","fill",1,"pipeline-picker"],["mat-raised-button","",1,"start-button",3,"disabled","click"],[3,"value"]],template:function(e,i){1&e&&(fe(0,"div")(1,"mat-form-field",0)(2,"mat-label"),Ue(3,"Select a camera"),we(),fe(4,"mat-select",1),$e("valueChange",function(s){return i.data.selectedCamera=s})("valueChange",function(s){return i.cameraSelectionChanged(s)}),it(5,Nq,2,2,"mat-option",2),we()()(),it(6,Vq,6,2,"div",3),it(7,jq,6,2,"div",3),it(8,zq,6,2,"div",3),fe(9,"div")(10,"mat-form-field",4)(11,"mat-label"),Ue(12,"Select a pipeline"),we(),fe(13,"mat-select",1),$e("valueChange",function(s){return i.data.selectedPipeline=s}),it(14,$q,2,4,"mat-option",2),we()(),fe(15,"button",5),$e("click",function(){return i.startPipeline()}),Ue(16," Start Pipeline "),we()()),2&e&&(Ee(4),Ae("value",i.data.selectedCamera),Ee(1),Ae("ngForOf",i.data.cameras),Ee(1),Ae("ngIf",i.data.cameraIsOnvif()),Ee(1),Ae("ngIf",i.data.cameraIsUSB()),Ee(1),Ae("ngIf",i.data.cameraIsUSB()&&void 0!==i.data.inputPixelFormat),Ee(5),Ae("value",i.data.selectedPipeline),Ee(1),Ae("ngForOf",i.data.pipelines),Ee(1),Ae("disabled",i.shouldDisablePipeline()))},dependencies:[ao,zi,Aa,GS,ch,xk,Y_],styles:["button[_ngcontent-%COMP%]{width:auto;height:auto}.material-icons[_ngcontent-%COMP%]{zoom:2}mat-form-field[_ngcontent-%COMP%]{width:600px}.pipeline-picker[_ngcontent-%COMP%]{width:471px}.start-button[_ngcontent-%COMP%]{margin-left:10px;vertical-align:top;margin-top:10px}.start-button[_ngcontent-%COMP%]:enabled{background-color:#09af00;color:#fff}"]}),n})();function Wq(n,t){if(1&n&&(fe(0,"mat-chip"),Ue(1),Jr(2,"number"),we()),2&n){const e=lt().$implicit;Ee(1),Ln(" ",vm(2,1,e.value.status.avg_fps,"2.0-0")," FPS ")}}function qq(n,t){if(1&n){const e=ki();fe(0,"mat-expansion-panel")(1,"mat-expansion-panel-header")(2,"mat-panel-title")(3,"mat-chip-list",1)(4,"mat-chip"),Ue(5),we()()(),fe(6,"mat-panel-description")(7,"span"),Ue(8),we()(),fe(9,"mat-chip-list",1)(10,"mat-chip"),Ue(11),we(),it(12,Wq,3,4,"mat-chip",2),fe(13,"button",3),$e("click",function(){const s=Bn(e).$implicit;return Vn(lt().api.stopPipeline(s.value.camera,s.value.info.id))}),fe(14,"mat-icon"),Ue(15,"stop"),we()()()(),fe(16,"pre"),Ue(17),Jr(18,"json"),we()()}if(2&n){const e=t.$implicit;Ee(5),Ln(" Pipeline ",e.value.info.id," "),Ee(3),rm("",e.value.camera," - ",e.value.info.name,"/",e.value.info.version,""),Ee(2),om("state-",e.value.status.state,""),Ee(1),Ln(" ",e.value.status.state," "),Ee(1),Ae("ngIf","RUNNING"===e.value.status.state),Ee(5),Kn(so(18,10,e.value))}}let Yq=(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.ref=r}ngOnInit(){}ngOnDestroy(){}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(en))},n.\u0275cmp=vt({type:n,selectors:[["app-all-pipelines"]],decls:3,vars:3,consts:[[4,"ngFor","ngForOf"],["selectable","false"],[4,"ngIf"],["mat-icon-button","","color","warn",1,"stop-button",3,"click"]],template:function(e,i){1&e&&(fe(0,"mat-accordion"),it(1,qq,19,12,"mat-expansion-panel",0),Jr(2,"keyvalue"),we()),2&e&&(Ee(1),Ae("ngForOf",so(2,1,i.data.pipelineMap)))},dependencies:[ao,zi,Aa,uh,Ia,Eh,_A,Kv,Qv,gA,mA,ru,ng,fE],styles:[".state-RUNNING[_ngcontent-%COMP%]{background-color:#09af00;color:#fff}.state-QUEUED[_ngcontent-%COMP%]{background-color:#00838f;color:#fff}.state-ERROR[_ngcontent-%COMP%]{background-color:#c62828;color:#fff}button[_ngcontent-%COMP%]{width:auto;height:auto}.stop-button[_ngcontent-%COMP%]{margin-right:10px}"]}),n})();function Kq(n,t){1&n&&(fe(0,"mat-card")(1,"mat-card-title"),Ue(2,"Running Pipelines"),we(),fe(3,"mat-card-content"),kt(4,"app-all-pipelines"),we()())}function Qq(n,t){if(1&n){const e=ki();fe(0,"button",5),$e("click",function(){return Bn(e),Vn(lt().eventService.pause())}),Ue(1,"Pause Events "),we()}}function Zq(n,t){if(1&n){const e=ki();fe(0,"button",6),$e("click",function(){return Bn(e),Vn(lt().eventService.resume())}),Ue(1,"Stream Events "),we()}}const Xq=[{path:"",redirectTo:"home",pathMatch:"full"},{path:"home",component:(()=>{class n{constructor(e,i,r){this.data=e,this.api=i,this.eventService=r,this.data.currentPage="home"}ngOnInit(){this.interval=setInterval(()=>{this.api.refreshAllPipelineStatuses()},1e3)}ngOnDestroy(){clearInterval(this.interval)}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(Jh),x(Wv))},n.\u0275cmp=vt({type:n,selectors:[["app-home"]],decls:29,vars:3,consts:[[1,"jumbotron","bg-image-home"],[1,"text-justify"],[4,"ngIf"],["mat-button","","class","pause-events",3,"click",4,"ngIf"],["mat-button","","class","stream-events",3,"click",4,"ngIf"],["mat-button","",1,"pause-events",3,"click"],["mat-button","",1,"stream-events",3,"click"]],template:function(e,i){1&e&&(fe(0,"mat-grid-tile-header")(1,"div",0)(2,"h1"),Ue(3,"Camera Management"),we(),fe(4,"p",1),Ue(5," This is the landing page for the Camera Management Reference Implementation. "),we()(),fe(6,"mat-card")(7,"mat-card-title"),Ue(8,"Camera Position"),we(),fe(9,"mat-card-content"),kt(10,"app-ptz"),we()(),fe(11,"mat-card")(12,"mat-card-title"),Ue(13,"Camera"),we(),fe(14,"mat-card-content"),kt(15,"app-camera-selector"),we()(),it(16,Kq,5,0,"mat-card",2),fe(17,"mat-card")(18,"mat-card-title"),Ue(19,"API Log"),we(),fe(20,"mat-card-content"),kt(21,"app-api-log"),we()(),fe(22,"mat-card")(23,"mat-card-title"),Ue(24," Inference Events "),it(25,Qq,2,0,"button",3),it(26,Zq,2,0,"button",4),we(),fe(27,"mat-card-content"),kt(28,"app-inference-events"),we()()()),2&e&&(Ee(16),Ae("ngIf",null!=i.data.pipelineMap&&i.data.pipelineMap.size>0),Ee(9),Ae("ngIf",!i.eventService.isPaused()),Ee(1),Ae("ngIf",i.eventService.isPaused()))},dependencies:[zi,Aa,Tz,Sz,kz,F$,L$,uq,Pq,Lq,Gq,Yq],styles:[".material-icons[_ngcontent-%COMP%]{font-size:32px;zoom:2}.pause-events[_ngcontent-%COMP%]{margin-left:10px;background-color:#ffbd3a}.stream-events[_ngcontent-%COMP%]{margin-left:10px;background-color:#188729;color:#fff}"]}),n})(),pathMatch:"full"},{path:"**",redirectTo:"home"}];let Jq=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n}),n.\u0275inj=qe({imports:[rA.forRoot(Xq,{scrollPositionRestoration:"enabled"}),rA]}),n})();function eY(n,t){if(1&n){const e=ki();fe(0,"a",6),$e("click",function(){const s=Bn(e).$implicit;return Vn(lt().data.currentPage=s.page)}),Ue(1),Jr(2,"uppercase"),we()}if(2&n){const e=t.$implicit;Ae("active",lt().data.currentPage==e.page)("routerLink",e.page),Ee(1),Ln(" ",so(2,3,e.caption)," ")}}let tY=(()=>{class n{constructor(e,i){this.data=e,this.bo=i,this.title="Camera Management UI",this.navbarCollapseShow=!1,i.observe("(prefers-color-scheme: dark)").subscribe(r=>{this.useDarkTheme=r.matches})}get useDarkTheme(){return this.darkTheme}set useDarkTheme(e){this.darkTheme=e,e?document.body.classList.add("dark-theme"):document.body.classList.remove("dark-theme")}}return n.\u0275fac=function(e){return new(e||n)(x(Or),x(_v))},n.\u0275cmp=vt({type:n,selectors:[["app-root"]],decls:8,vars:3,consts:[["mat-tab-nav-bar","","backgroundColor","primary",1,"mat-elevation-z8"],["routerLink","home",1,"mat-tab-link",3,"click"],["mat-icon-button","","type","button",3,"title","click"],["role","img","aria-hidden","true"],["mat-tab-link","",3,"active","routerLink","click",4,"ngFor","ngForOf"],["role","main"],["mat-tab-link","",3,"active","routerLink","click"]],template:function(e,i){1&e&&(fe(0,"nav",0)(1,"a",1),$e("click",function(){return i.data.currentPage="home"}),we(),fe(2,"button",2),$e("click",function(){return i.useDarkTheme=!i.useDarkTheme}),fe(3,"mat-icon",3),Ue(4),we()(),it(5,eY,3,5,"a",4),we(),fe(6,"main",5),kt(7,"router-outlet"),we()),2&e&&(Ee(2),Td("title","Switch to ",i.useDarkTheme?"light":"dark"," theme"),Ee(2),Ln(" ",i.useDarkTheme?"light_mode":"dark_mode"," "),Ee(1),Ae("ngForOf",i.data.pages))},dependencies:[ao,Aa,Eh,Yk,Kk,Pv,Xh,hE],styles:[".mat-tab-link[_ngcontent-%COMP%]{padding-top:35px;padding-bottom:35px}"]}),n})(),nY=(()=>{class n{constructor(e,i){this.data=e,this.snackbar=i}intercept(e,i){if(e.headers.has(zv))return i.handle(e);let r=new XW(e);for(this.data.apiLog.unshift(r);this.data.apiLog.length>5;)this.data.apiLog.pop();return i.handle(e).pipe(wn(s=>(s instanceof tc&&(r.response=s),s),s=>{s instanceof l_&&(r.response=s,this.snackbar.open(`${s.status} ${s.statusText}\n${s.error.substring(0,60)}...`,"",{duration:2500,panelClass:["mat-toolbar","mat-warn","error-snackbar"]}))}))}}return n.\u0275fac=function(e){return new(e||n)(te(Or),te(B6))},n.\u0275prov=Ie({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const iY={hostname:window.location.hostname,port:Fr_mqtt_port,path:Fr_mqtt_path};let rY=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Ke({type:n,bootstrap:[tY]}),n.\u0275inj=qe({providers:[{provide:d_,useClass:nY,multi:!0}],imports:[PE,aj,h3,f3,T3,ZU,oh,Az,zz,x8,d$,I$,dh,B$,Q$,W8,h5,hz,j5,K5,c4,Sk,b4,D4,t6,C6,D6,eT,Jq,kk,kq,oq.forRoot(iY)]}),n})();(function UN(){FD=!1})(),KV().bootstrapModule(rY).catch(n=>console.error(n))},841:(js,Wa,ps)=>{js.exports=function V(X,re,T){function S(m,y){if(!re[m]){if(!X[m]){if(R)return R(m,!0);var _=new Error("Cannot find module '"+m+"'");throw _.code="MODULE_NOT_FOUND",_}var I=re[m]={exports:{}};X[m][0].call(I.exports,function(z){return S(X[m][1][z]||z)},I,I.exports,V,X,re,T)}return re[m].exports}for(var R=void 0,D=0;D0?Q-4:Q;for(Y=0;Y>16&255,oe[de++]=F>>8&255,oe[de++]=255&F;return 2===G&&(F=S[O.charCodeAt(Y)]<<2|S[O.charCodeAt(Y+1)]>>4,oe[de++]=255&F),1===G&&(F=S[O.charCodeAt(Y)]<<10|S[O.charCodeAt(Y+1)]<<4|S[O.charCodeAt(Y+2)]>>2,oe[de++]=F>>8&255,oe[de++]=255&F),oe},re.fromByteArray=function M(O){for(var F,B=O.length,Q=B%3,G=[],de=0,le=B-Q;dele?le:de+16383));return 1===Q?G.push(T[(F=O[B-1])>>2]+T[F<<4&63]+"=="):2===Q&&G.push(T[(F=(O[B-2]<<8)+O[B-1])>>10]+T[F>>4&63]+T[F<<2&63]+"="),G.join("")};for(var T=[],S=[],R="undefined"!=typeof Uint8Array?Uint8Array:Array,D="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",m=0,y=D.length;m0)throw new Error("Invalid string. Length must be a multiple of 4");var B=O.indexOf("=");return-1===B&&(B=F),[B,B===F?0:4-B%4]}function C(O){return T[O>>18&63]+T[O>>12&63]+T[O>>6&63]+T[63&O]}function P(O,F,B){for(var G=[],oe=F;oeD)throw new RangeError('The value "'+h+'" is invalid for option "size"');var u=new Uint8Array(h);return u.__proto__=v.prototype,u}function v(h,u,p){if("number"==typeof h){if("string"==typeof u)throw new TypeError('The "string" argument must be of type string. Received type number');return C(h)}return _(h,u,p)}function _(h,u,p){if("string"==typeof h)return function P(h,u){if(("string"!=typeof u||""===u)&&(u="utf8"),!v.isEncoding(u))throw new TypeError("Unknown encoding: "+u);var p=0|G(h,u),L=y(p),Z=L.write(h,u);return Z!==p&&(L=L.slice(0,Z)),L}(h,u);if(ArrayBuffer.isView(h))return M(h);if(null==h)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof h);if(ne(h,ArrayBuffer)||h&&ne(h.buffer,ArrayBuffer))return function O(h,u,p){if(u<0||h.byteLength=D)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+D.toString(16)+" bytes");return 0|h}function G(h,u){if(v.isBuffer(h))return h.length;if(ArrayBuffer.isView(h)||ne(h,ArrayBuffer))return h.byteLength;if("string"!=typeof h)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof h);var p=h.length,L=arguments.length>2&&!0===arguments[2];if(!L&&0===p)return 0;for(var Z=!1;;)switch(u){case"ascii":case"latin1":case"binary":return p;case"utf8":case"utf-8":return Re(h).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*p;case"hex":return p>>>1;case"base64":return b(h).length;default:if(Z)return L?-1:Re(h).length;u=(""+u).toLowerCase(),Z=!0}}function oe(h,u,p){var L=!1;if((void 0===u||u<0)&&(u=0),u>this.length||((void 0===p||p>this.length)&&(p=this.length),p<=0)||(p>>>=0)<=(u>>>=0))return"";for(h||(h="utf8");;)switch(h){case"hex":return Pe(this,u,p);case"utf8":case"utf-8":return ge(this,u,p);case"ascii":return Ye(this,u,p);case"latin1":case"binary":return Ne(this,u,p);case"base64":return Ce(this,u,p);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _e(this,u,p);default:if(L)throw new TypeError("Unknown encoding: "+h);h=(h+"").toLowerCase(),L=!0}}function de(h,u,p){var L=h[u];h[u]=h[p],h[p]=L}function le(h,u,p,L,Z){if(0===h.length)return-1;if("string"==typeof p?(L=p,p=0):p>2147483647?p=2147483647:p<-2147483648&&(p=-2147483648),A(p=+p)&&(p=Z?0:h.length-1),p<0&&(p=h.length+p),p>=h.length){if(Z)return-1;p=h.length-1}else if(p<0){if(!Z)return-1;p=0}if("string"==typeof u&&(u=v.from(u,L)),v.isBuffer(u))return 0===u.length?-1:Y(h,u,p,L,Z);if("number"==typeof u)return u&=255,"function"==typeof Uint8Array.prototype.indexOf?Z?Uint8Array.prototype.indexOf.call(h,u,p):Uint8Array.prototype.lastIndexOf.call(h,u,p):Y(h,[u],p,L,Z);throw new TypeError("val must be string, number or Buffer")}function Y(h,u,p,L,Z){var Vt,me=1,Se=h.length,Ze=u.length;if(void 0!==L&&("ucs2"===(L=String(L).toLowerCase())||"ucs-2"===L||"utf16le"===L||"utf-16le"===L)){if(h.length<2||u.length<2)return-1;me=2,Se/=2,Ze/=2,p/=2}function yt(_i,Oi){return 1===me?_i[Oi]:_i.readUInt16BE(Oi*me)}if(Z){var nn=-1;for(Vt=p;VtSe&&(p=Se-Ze),Vt=p;Vt>=0;Vt--){for(var Bt=!0,zn=0;znZ&&(L=Z):L=Z;var me=u.length;L>me/2&&(L=me/2);for(var Se=0;Se>8,me.push(p%256),me.push(L);return me}(u,h.length-p),h,p,L)}function Ce(h,u,p){return S.fromByteArray(0===u&&p===h.length?h:h.slice(u,p))}function ge(h,u,p){p=Math.min(h.length,p);for(var L=[],Z=u;Z239?4:me>223?3:me>191?2:1;if(Z+Ze<=p)switch(Ze){case 1:me<128&&(Se=me);break;case 2:128==(192&(yt=h[Z+1]))&&(Bt=(31&me)<<6|63&yt)>127&&(Se=Bt);break;case 3:Vt=h[Z+2],128==(192&(yt=h[Z+1]))&&128==(192&Vt)&&(Bt=(15&me)<<12|(63&yt)<<6|63&Vt)>2047&&(Bt<55296||Bt>57343)&&(Se=Bt);break;case 4:Vt=h[Z+2],nn=h[Z+3],128==(192&(yt=h[Z+1]))&&128==(192&Vt)&&128==(192&nn)&&(Bt=(15&me)<<18|(63&yt)<<12|(63&Vt)<<6|63&nn)>65535&&Bt<1114112&&(Se=Bt)}null===Se?(Se=65533,Ze=1):Se>65535&&(L.push((Se-=65536)>>>10&1023|55296),Se=56320|1023&Se),L.push(Se),Z+=Ze}return function ue(h){var u=h.length;if(u<=4096)return String.fromCharCode.apply(String,h);for(var p="",L=0;Lp&&(u+=" ... "),""},v.prototype.compare=function(u,p,L,Z,me){if(ne(u,Uint8Array)&&(u=v.from(u,u.offset,u.byteLength)),!v.isBuffer(u))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof u);if(void 0===p&&(p=0),void 0===L&&(L=u?u.length:0),void 0===Z&&(Z=0),void 0===me&&(me=this.length),p<0||L>u.length||Z<0||me>this.length)throw new RangeError("out of range index");if(Z>=me&&p>=L)return 0;if(Z>=me)return-1;if(p>=L)return 1;if(this===u)return 0;for(var Se=(me>>>=0)-(Z>>>=0),Ze=(L>>>=0)-(p>>>=0),yt=Math.min(Se,Ze),Vt=this.slice(Z,me),nn=u.slice(p,L),Bt=0;Bt>>=0,isFinite(L)?(L>>>=0,void 0===Z&&(Z="utf8")):(Z=L,L=void 0)}var me=this.length-p;if((void 0===L||L>me)&&(L=me),u.length>0&&(L<0||p<0)||p>this.length)throw new RangeError("Attempt to write outside buffer bounds");Z||(Z="utf8");for(var Se=!1;;)switch(Z){case"hex":return H(this,u,p,L);case"utf8":case"utf-8":return N(this,u,p,L);case"ascii":return E(this,u,p,L);case"latin1":case"binary":return se(this,u,p,L);case"base64":return J(this,u,p,L);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return pe(this,u,p,L);default:if(Se)throw new TypeError("Unknown encoding: "+Z);Z=(""+Z).toLowerCase(),Se=!0}},v.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Ye(h,u,p){var L="";p=Math.min(h.length,p);for(var Z=u;ZL)&&(p=L);for(var Z="",me=u;mep)throw new RangeError("Trying to access beyond buffer length")}function U(h,u,p,L,Z,me){if(!v.isBuffer(h))throw new TypeError('"buffer" argument must be a Buffer instance');if(u>Z||uh.length)throw new RangeError("Index out of range")}function ee(h,u,p,L,Z,me){if(p+L>h.length)throw new RangeError("Index out of range");if(p<0)throw new RangeError("Index out of range")}function be(h,u,p,L,Z){return u=+u,p>>>=0,Z||ee(h,0,p,4),R.write(h,u,p,L,23,4),p+4}function xe(h,u,p,L,Z){return u=+u,p>>>=0,Z||ee(h,0,p,8),R.write(h,u,p,L,52,8),p+8}v.prototype.slice=function(u,p){var L=this.length;(u=~~u)<0?(u+=L)<0&&(u=0):u>L&&(u=L),(p=void 0===p?L:~~p)<0?(p+=L)<0&&(p=0):p>L&&(p=L),p>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u],me=1,Se=0;++Se>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u+--p],me=1;p>0&&(me*=256);)Z+=this[u+--p]*me;return Z},v.prototype.readUInt8=function(u,p){return u>>>=0,p||ve(u,1,this.length),this[u]},v.prototype.readUInt16LE=function(u,p){return u>>>=0,p||ve(u,2,this.length),this[u]|this[u+1]<<8},v.prototype.readUInt16BE=function(u,p){return u>>>=0,p||ve(u,2,this.length),this[u]<<8|this[u+1]},v.prototype.readUInt32LE=function(u,p){return u>>>=0,p||ve(u,4,this.length),(this[u]|this[u+1]<<8|this[u+2]<<16)+16777216*this[u+3]},v.prototype.readUInt32BE=function(u,p){return u>>>=0,p||ve(u,4,this.length),16777216*this[u]+(this[u+1]<<16|this[u+2]<<8|this[u+3])},v.prototype.readIntLE=function(u,p,L){u>>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=this[u],me=1,Se=0;++Se=(me*=128)&&(Z-=Math.pow(2,8*p)),Z},v.prototype.readIntBE=function(u,p,L){u>>>=0,p>>>=0,L||ve(u,p,this.length);for(var Z=p,me=1,Se=this[u+--Z];Z>0&&(me*=256);)Se+=this[u+--Z]*me;return Se>=(me*=128)&&(Se-=Math.pow(2,8*p)),Se},v.prototype.readInt8=function(u,p){return u>>>=0,p||ve(u,1,this.length),128&this[u]?-1*(255-this[u]+1):this[u]},v.prototype.readInt16LE=function(u,p){u>>>=0,p||ve(u,2,this.length);var L=this[u]|this[u+1]<<8;return 32768&L?4294901760|L:L},v.prototype.readInt16BE=function(u,p){u>>>=0,p||ve(u,2,this.length);var L=this[u+1]|this[u]<<8;return 32768&L?4294901760|L:L},v.prototype.readInt32LE=function(u,p){return u>>>=0,p||ve(u,4,this.length),this[u]|this[u+1]<<8|this[u+2]<<16|this[u+3]<<24},v.prototype.readInt32BE=function(u,p){return u>>>=0,p||ve(u,4,this.length),this[u]<<24|this[u+1]<<16|this[u+2]<<8|this[u+3]},v.prototype.readFloatLE=function(u,p){return u>>>=0,p||ve(u,4,this.length),R.read(this,u,!0,23,4)},v.prototype.readFloatBE=function(u,p){return u>>>=0,p||ve(u,4,this.length),R.read(this,u,!1,23,4)},v.prototype.readDoubleLE=function(u,p){return u>>>=0,p||ve(u,8,this.length),R.read(this,u,!0,52,8)},v.prototype.readDoubleBE=function(u,p){return u>>>=0,p||ve(u,8,this.length),R.read(this,u,!1,52,8)},v.prototype.writeUIntLE=function(u,p,L,Z){u=+u,p>>>=0,L>>>=0,Z||U(this,u,p,L,Math.pow(2,8*L)-1,0);var Se=1,Ze=0;for(this[p]=255&u;++Ze>>=0,L>>>=0,Z||U(this,u,p,L,Math.pow(2,8*L)-1,0);var Se=L-1,Ze=1;for(this[p+Se]=255&u;--Se>=0&&(Ze*=256);)this[p+Se]=u/Ze&255;return p+L},v.prototype.writeUInt8=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,1,255,0),this[p]=255&u,p+1},v.prototype.writeUInt16LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,65535,0),this[p]=255&u,this[p+1]=u>>>8,p+2},v.prototype.writeUInt16BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,65535,0),this[p]=u>>>8,this[p+1]=255&u,p+2},v.prototype.writeUInt32LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,4294967295,0),this[p+3]=u>>>24,this[p+2]=u>>>16,this[p+1]=u>>>8,this[p]=255&u,p+4},v.prototype.writeUInt32BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,4294967295,0),this[p]=u>>>24,this[p+1]=u>>>16,this[p+2]=u>>>8,this[p+3]=255&u,p+4},v.prototype.writeIntLE=function(u,p,L,Z){if(u=+u,p>>>=0,!Z){var me=Math.pow(2,8*L-1);U(this,u,p,L,me-1,-me)}var Se=0,Ze=1,yt=0;for(this[p]=255&u;++Se>0)-yt&255;return p+L},v.prototype.writeIntBE=function(u,p,L,Z){if(u=+u,p>>>=0,!Z){var me=Math.pow(2,8*L-1);U(this,u,p,L,me-1,-me)}var Se=L-1,Ze=1,yt=0;for(this[p+Se]=255&u;--Se>=0&&(Ze*=256);)u<0&&0===yt&&0!==this[p+Se+1]&&(yt=1),this[p+Se]=(u/Ze>>0)-yt&255;return p+L},v.prototype.writeInt8=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,1,127,-128),u<0&&(u=255+u+1),this[p]=255&u,p+1},v.prototype.writeInt16LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,32767,-32768),this[p]=255&u,this[p+1]=u>>>8,p+2},v.prototype.writeInt16BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,2,32767,-32768),this[p]=u>>>8,this[p+1]=255&u,p+2},v.prototype.writeInt32LE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,2147483647,-2147483648),this[p]=255&u,this[p+1]=u>>>8,this[p+2]=u>>>16,this[p+3]=u>>>24,p+4},v.prototype.writeInt32BE=function(u,p,L){return u=+u,p>>>=0,L||U(this,u,p,4,2147483647,-2147483648),u<0&&(u=4294967295+u+1),this[p]=u>>>24,this[p+1]=u>>>16,this[p+2]=u>>>8,this[p+3]=255&u,p+4},v.prototype.writeFloatLE=function(u,p,L){return be(this,u,p,!0,L)},v.prototype.writeFloatBE=function(u,p,L){return be(this,u,p,!1,L)},v.prototype.writeDoubleLE=function(u,p,L){return xe(this,u,p,!0,L)},v.prototype.writeDoubleBE=function(u,p,L){return xe(this,u,p,!1,L)},v.prototype.copy=function(u,p,L,Z){if(!v.isBuffer(u))throw new TypeError("argument should be a Buffer");if(L||(L=0),!Z&&0!==Z&&(Z=this.length),p>=u.length&&(p=u.length),p||(p=0),Z>0&&Z=this.length)throw new RangeError("Index out of range");if(Z<0)throw new RangeError("sourceEnd out of bounds");Z>this.length&&(Z=this.length),u.length-p=0;--Se)u[Se+p]=this[Se+L];else Uint8Array.prototype.set.call(u,this.subarray(L,Z),p);return me},v.prototype.fill=function(u,p,L,Z){if("string"==typeof u){if("string"==typeof p?(Z=p,p=0,L=this.length):"string"==typeof L&&(Z=L,L=this.length),void 0!==Z&&"string"!=typeof Z)throw new TypeError("encoding must be a string");if("string"==typeof Z&&!v.isEncoding(Z))throw new TypeError("Unknown encoding: "+Z);if(1===u.length){var me=u.charCodeAt(0);("utf8"===Z&&me<128||"latin1"===Z)&&(u=me)}}else"number"==typeof u&&(u&=255);if(p<0||this.length>>=0,L=void 0===L?this.length:L>>>0,u||(u=0),"number"==typeof u)for(Se=p;Se55295&&p<57344){if(!Z){if(p>56319){(u-=3)>-1&&me.push(239,191,189);continue}if(Se+1===L){(u-=3)>-1&&me.push(239,191,189);continue}Z=p;continue}if(p<56320){(u-=3)>-1&&me.push(239,191,189),Z=p;continue}p=65536+(Z-55296<<10|p-56320)}else Z&&(u-=3)>-1&&me.push(239,191,189);if(Z=null,p<128){if((u-=1)<0)break;me.push(p)}else if(p<2048){if((u-=2)<0)break;me.push(p>>6|192,63&p|128)}else if(p<65536){if((u-=3)<0)break;me.push(p>>12|224,p>>6&63|128,63&p|128)}else{if(!(p<1114112))throw new Error("Invalid code point");if((u-=4)<0)break;me.push(p>>18|240,p>>12&63|128,p>>6&63|128,63&p|128)}}return me}function b(h){return S.toByteArray(function $(h){if((h=(h=h.split("=")[0]).trim().replace(ie,"")).length<2)return"";for(;h.length%4!=0;)h+="=";return h}(h))}function q(h,u,p,L){for(var Z=0;Z=u.length||Z>=h.length);++Z)u[Z+p]=h[Z];return Z}function ne(h,u){return h instanceof u||null!=h&&null!=h.constructor&&null!=h.constructor.name&&h.constructor.name===u.name}function A(h){return h!=h}}).call(this)}).call(this,V("buffer").Buffer)},{"base64-js":1,buffer:3,ieee754:5}],4:[function(V,X,re){"use strict";var R,T="object"==typeof Reflect?Reflect:null,S=T&&"function"==typeof T.apply?T.apply:function(Y,H,N){return Function.prototype.apply.call(Y,H,N)};R=T&&"function"==typeof T.ownKeys?T.ownKeys:Object.getOwnPropertySymbols?function(Y){return Object.getOwnPropertyNames(Y).concat(Object.getOwnPropertySymbols(Y))}:function(Y){return Object.getOwnPropertyNames(Y)};var m=Number.isNaN||function(Y){return Y!=Y};function y(){y.init.call(this)}X.exports=y,X.exports.once=function G(le,Y){return new Promise(function(H,N){function E(J){le.removeListener(Y,se),N(J)}function se(){"function"==typeof le.removeListener&&le.removeListener("error",E),H([].slice.call(arguments))}de(le,Y,se,{once:!0}),"error"!==Y&&function oe(le,Y,H){"function"==typeof le.on&&de(le,"error",Y,H)}(le,E,{once:!0})})},y.EventEmitter=y,y.prototype._events=void 0,y.prototype._eventsCount=0,y.prototype._maxListeners=void 0;var v=10;function _(le){if("function"!=typeof le)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof le)}function I(le){return void 0===le._maxListeners?y.defaultMaxListeners:le._maxListeners}function z(le,Y,H,N){var E,se,J;if(_(H),void 0===(se=le._events)?(se=le._events=Object.create(null),le._eventsCount=0):(void 0!==se.newListener&&(le.emit("newListener",Y,H.listener?H.listener:H),se=le._events),J=se[Y]),void 0===J)J=se[Y]=H,++le._eventsCount;else if("function"==typeof J?J=se[Y]=N?[H,J]:[J,H]:N?J.unshift(H):J.push(H),(E=I(le))>0&&J.length>E&&!J.warned){J.warned=!0;var pe=new Error("Possible EventEmitter memory leak detected. "+J.length+" "+String(Y)+" listeners added. Use emitter.setMaxListeners() to increase limit");pe.name="MaxListenersExceededWarning",pe.emitter=le,pe.type=Y,pe.count=J.length,function D(le){console&&console.warn&&console.warn(le)}(pe)}return le}function C(){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(le,Y,H){var N={fired:!1,wrapFn:void 0,target:le,type:Y,listener:H},E=C.bind(N);return E.listener=H,N.wrapFn=E,E}function M(le,Y,H){var N=le._events;if(void 0===N)return[];var E=N[Y];return void 0===E?[]:"function"==typeof E?H?[E.listener||E]:[E]:H?function Q(le){for(var Y=new Array(le.length),H=0;H0&&(J=H[0]),J instanceof Error)throw J;var pe=new Error("Unhandled error."+(J?" ("+J.message+")":""));throw pe.context=J,pe}var Ce=se[Y];if(void 0===Ce)return!1;if("function"==typeof Ce)S(Ce,this,H);else{var ge=Ce.length,Fe=F(Ce,ge);for(N=0;N=0;J--)if(N[J]===H||N[J].listener===H){pe=N[J].listener,se=J;break}if(se<0)return this;0===se?N.shift():function B(le,Y){for(;Y+1=0;E--)this.removeListener(Y,H[E]);return this},y.prototype.listeners=function(Y){return M(this,Y,!0)},y.prototype.rawListeners=function(Y){return M(this,Y,!1)},y.listenerCount=function(le,Y){return"function"==typeof le.listenerCount?le.listenerCount(Y):O.call(le,Y)},y.prototype.listenerCount=O,y.prototype.eventNames=function(){return this._eventsCount>0?R(this._events):[]}},{}],5:[function(V,X,re){re.read=function(T,S,R,D,m){var y,v,_=8*m-D-1,I=(1<<_)-1,z=I>>1,C=-7,P=R?m-1:0,M=R?-1:1,O=T[S+P];for(P+=M,y=O&(1<<-C)-1,O>>=-C,C+=_;C>0;y=256*y+T[S+P],P+=M,C-=8);for(v=y&(1<<-C)-1,y>>=-C,C+=D;C>0;v=256*v+T[S+P],P+=M,C-=8);if(0===y)y=1-z;else{if(y===I)return v?NaN:1/0*(O?-1:1);v+=Math.pow(2,D),y-=z}return(O?-1:1)*v*Math.pow(2,y-D)},re.write=function(T,S,R,D,m,y){var v,_,I,z=8*y-m-1,C=(1<>1,M=23===m?Math.pow(2,-24)-Math.pow(2,-77):0,O=D?0:y-1,F=D?1:-1,B=S<0||0===S&&1/S<0?1:0;for(S=Math.abs(S),isNaN(S)||S===1/0?(_=isNaN(S)?1:0,v=C):(v=Math.floor(Math.log(S)/Math.LN2),S*(I=Math.pow(2,-v))<1&&(v--,I*=2),(S+=v+P>=1?M/I:M*Math.pow(2,1-P))*I>=2&&(v++,I/=2),v+P>=C?(_=0,v=C):v+P>=1?(_=(S*I-1)*Math.pow(2,m),v+=P):(_=S*Math.pow(2,P-1)*Math.pow(2,m),v=0));m>=8;T[R+O]=255&_,O+=F,_/=256,m-=8);for(v=v<0;T[R+O]=255&v,O+=F,v/=256,z-=8);T[R+O-F]|=128*B}},{}],6:[function(V,X,re){function T(R){return!!R.constructor&&"function"==typeof R.constructor.isBuffer&&R.constructor.isBuffer(R)}X.exports=function(R){return null!=R&&(T(R)||function S(R){return"function"==typeof R.readFloatLE&&"function"==typeof R.slice&&T(R.slice(0,0))}(R)||!!R._isBuffer)}},{}],7:[function(V,X,re){(function(T,S){(function(){"use strict";var R=V("events").EventEmitter,D=V("./store"),m=V("mqtt-packet"),y=V("readable-stream").Writable,v=V("inherits"),_=V("reinterval"),I=V("./validations"),z=V("xtend"),C=V("debug")("mqttjs:client"),P=T?T.nextTick:function(N){setTimeout(N,0)},M=S.setImmediate||function(N){P(N)},O={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0},F=["ECONNREFUSED","EADDRINUSE","ECONNRESET","ENOTFOUND"],B={0:"",1:"Unacceptable protocol version",2:"Identifier rejected",3:"Server unavailable",4:"Bad username or password",5:"Not authorized",16:"No matching subscribers",17:"No subscription existed",128:"Unspecified error",129:"Malformed Packet",130:"Protocol Error",131:"Implementation specific error",132:"Unsupported Protocol Version",133:"Client Identifier not valid",134:"Bad User Name or Password",135:"Not authorized",136:"Server unavailable",137:"Server busy",138:"Banned",139:"Server shutting down",140:"Bad authentication method",141:"Keep Alive timeout",142:"Session taken over",143:"Topic Filter invalid",144:"Topic Name invalid",145:"Packet identifier in use",146:"Packet Identifier not found",147:"Receive Maximum exceeded",148:"Topic Alias invalid",149:"Packet too large",150:"Message rate too high",151:"Quota exceeded",152:"Administrative action",153:"Payload format invalid",154:"Retain not supported",155:"QoS not supported",156:"Use another server",157:"Server moved",158:"Shared Subscriptions not supported",159:"Connection rate exceeded",160:"Maximum connect time",161:"Subscription Identifiers not supported",162:"Wildcard Subscriptions not supported"};function G(N,E,se){C("sendPacket :: packet: %O",E),C("sendPacket :: emitting `packetsend`"),N.emit("packetsend",E),C("sendPacket :: writing to stream");var J=m.writeToStream(E,N.stream,N.options);C("sendPacket :: writeToStream result %s",J),!J&&se?(C("sendPacket :: handle events on `drain` once through callback."),N.stream.once("drain",se)):se&&(C("sendPacket :: invoking cb"),se())}function oe(N){N&&(C("flush: queue exists? %b",!!N),Object.keys(N).forEach(function(E){"function"==typeof N[E].cb&&(N[E].cb(new Error("Connection closed")),delete N[E])}))}function le(N,E,se,J){C("storeAndSend :: store packet with cmd %s to outgoingStore",E.cmd),N.outgoingStore.put(E,function(Ce){if(Ce)return se&&se(Ce);J(),G(N,E,se)})}function Y(N){C("nop ::",N)}function H(N,E){var se,J=this;if(!(this instanceof H))return new H(N,E);for(se in this.options=E||{},O)this.options[se]=void 0===this.options[se]?O[se]:E[se];C("MqttClient :: options.protocol",E.protocol),C("MqttClient :: options.protocolVersion",E.protocolVersion),C("MqttClient :: options.username",E.username),C("MqttClient :: options.keepalive",E.keepalive),C("MqttClient :: options.reconnectPeriod",E.reconnectPeriod),C("MqttClient :: options.rejectUnauthorized",E.rejectUnauthorized),this.options.clientId="string"==typeof E.clientId?E.clientId:function Q(){return"mqttjs_"+Math.random().toString(16).substr(2,8)}(),C("MqttClient :: clientId",this.options.clientId),this.options.customHandleAcks=5===E.protocolVersion&&E.customHandleAcks?E.customHandleAcks:function(){arguments[3](0)},this.streamBuilder=N,this.outgoingStore=E.outgoingStore||new D,this.incomingStore=E.incomingStore||new D,this.queueQoSZero=void 0===E.queueQoSZero||E.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this._storeProcessing=!1,this._packetIdsDuringStoreProcessing={},this.nextId=Math.max(1,Math.floor(65535*Math.random())),this.outgoing={},this._firstConnection=!0,this.on("connect",function(){var pe=this.queue;C("connect :: sending queued packets"),function Ce(){var ge=pe.shift();C("deliver :: entry %o",ge);var Fe=null;!ge||(C("deliver :: call _sendPacket for %o",Fe=ge.packet),J._sendPacket(Fe,function(ue){ge.cb&&ge.cb(ue),Ce()}))}()}),this.on("close",function(){C("close :: connected set to `false`"),this.connected=!1,C("close :: clearing connackTimer"),clearTimeout(this.connackTimer),C("close :: clearing ping timer"),null!==J.pingTimer&&(J.pingTimer.clear(),J.pingTimer=null),C("close :: calling _setupReconnect"),this._setupReconnect()}),R.call(this),C("MqttClient :: setting up stream"),this._setupStream()}v(H,R),H.prototype._setupStream=function(){var N,E=this,se=new y,J=m.parser(this.options),pe=null,Ce=[];function ge(){if(Ce.length)P(Fe);else{var Ne=pe;pe=null,Ne()}}function Fe(){C("work :: getting next packet in queue");var Ne=Ce.shift();if(Ne)C("work :: packet pulled from queue"),E._handlePacket(Ne,ge);else{C("work :: no packets in queue");var Pe=pe;pe=null,C("work :: done flag is %s",!!Pe),Pe&&Pe()}}if(C("_setupStream :: calling method to clear reconnect"),this._clearReconnect(),C("_setupStream :: using streamBuilder provided to client to create stream"),this.stream=this.streamBuilder(this),J.on("packet",function(Ne){C("parser :: on packet push to packets array."),Ce.push(Ne)}),se._write=function(Ne,Pe,_e){pe=_e,C("writable stream :: parsing buffer"),J.parse(Ne),Fe()},C("_setupStream :: pipe stream to writable stream"),this.stream.pipe(se),this.stream.on("error",function ue(Ne){C("streamErrorHandler :: error",Ne.message),F.includes(Ne.code)?(C("streamErrorHandler :: emitting error"),E.emit("error",Ne)):Y(Ne)}),this.stream.on("close",function(){C("(%s)stream :: on close",E.options.clientId),function de(N){N&&(C("flushVolatile :: deleting volatile messages from the queue and setting their callbacks as error function"),Object.keys(N).forEach(function(E){N[E].volatile&&"function"==typeof N[E].cb&&(N[E].cb(new Error("Connection closed")),delete N[E])}))}(E.outgoing),C("stream: emit close to MqttClient"),E.emit("close")}),C("_setupStream: sending packet `connect`"),(N=Object.create(this.options)).cmd="connect",G(this,N),J.on("error",this.emit.bind(this,"error")),this.options.properties){if(!this.options.properties.authenticationMethod&&this.options.properties.authenticationData)return E.end(()=>this.emit("error",new Error("Packet has no Authentication Method"))),this;this.options.properties.authenticationMethod&&this.options.authPacket&&"object"==typeof this.options.authPacket&&G(this,z({cmd:"auth",reasonCode:0},this.options.authPacket))}this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout(function(){C("!!connectTimeout hit!! Calling _cleanUp with force `true`"),E._cleanUp(!0)},this.options.connectTimeout)},H.prototype._handlePacket=function(N,E){var se=this.options;if(5===se.protocolVersion&&se.properties&&se.properties.maximumPacketSize&&se.properties.maximumPacketSizeCe.properties.topicAliasMaximum||!Ce.properties.topicAliasMaximum&&se.properties.topicAlias))&&delete pe.properties.topicAlias),C("publish :: qos",se.qos),se.qos){case 1:case 2:this.outgoing[pe.messageId]={volatile:!1,cb:J||Y},this._storeProcessing?(C("_storeProcessing enabled"),this._packetIdsDuringStoreProcessing[pe.messageId]=!1,this._storePacket(pe,void 0,se.cbStorePut)):(C("MqttClient:publish: packet cmd: %s",pe.cmd),this._sendPacket(pe,void 0,se.cbStorePut));break;default:this._storeProcessing?(C("_storeProcessing enabled"),this._storePacket(pe,J,se.cbStorePut)):(C("MqttClient:publish: packet cmd: %s",pe.cmd),this._sendPacket(pe,J,se.cbStorePut))}return this},H.prototype.subscribe=function(){for(var N,E=new Array(arguments.length),se=0;se0){var U={qos:ve.qos};5===Ne&&(U.nl=ve.nl||!1,U.rap=ve.rap||!1,U.rh=ve.rh||0,U.properties=ve.properties),Ye._resubscribeTopics[ve.topic]=U,_e.push(ve.topic)}}),Ye.messageIdToTopic[N.messageId]=_e}return this.outgoing[N.messageId]={volatile:!0,cb:function(ve,U){if(!ve)for(var ee=U.granted,be=0;be{C("end :: finish :: calling process.nextTick on closeStores"),P(pe.bind(J))},E)}return C("end :: (%s)",this.options.clientId),(null==N||"boolean"!=typeof N)&&(se=E||Y,E=N,N=!1,"object"!=typeof E&&(se=E,E=null,"function"!=typeof se&&(se=Y))),"object"!=typeof E&&(se=E,E=null),C("end :: cb? %s",!!se),se=se||Y,this.disconnecting?(se(),this):(this._clearReconnect(),this.disconnecting=!0,!N&&Object.keys(this.outgoing).length>0?(C("end :: (%s) :: calling finish in 10ms once outgoing is empty",J.options.clientId),this.once("outgoingEmpty",setTimeout.bind(null,Ce,10))):(C("end :: (%s) :: immediately calling finish",J.options.clientId),Ce()),this)},H.prototype.removeOutgoingMessage=function(N){var E=this.outgoing[N]?this.outgoing[N].cb:null;return delete this.outgoing[N],this.outgoingStore.del({messageId:N},function(){E(new Error("Message removed"))}),this},H.prototype.reconnect=function(N){C("client reconnect");var E=this,se=function(){N?(E.options.incomingStore=N.incomingStore,E.options.outgoingStore=N.outgoingStore):(E.options.incomingStore=null,E.options.outgoingStore=null),E.incomingStore=E.options.incomingStore||new D,E.outgoingStore=E.options.outgoingStore||new D,E.disconnecting=!1,E.disconnected=!1,E._deferredReconnect=null,E._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=se:se(),this},H.prototype._reconnect=function(){C("_reconnect: emitting reconnect to client"),this.emit("reconnect"),this.connected?(this.end(()=>{this._setupStream()}),C("client already connected. disconnecting first.")):(C("_reconnect: calling _setupStream"),this._setupStream())},H.prototype._setupReconnect=function(){var N=this;!N.disconnecting&&!N.reconnectTimer&&N.options.reconnectPeriod>0?(this.reconnecting||(C("_setupReconnect :: emit `offline` state"),this.emit("offline"),C("_setupReconnect :: set `reconnecting` to `true`"),this.reconnecting=!0),C("_setupReconnect :: setting reconnectTimer for %d ms",N.options.reconnectPeriod),N.reconnectTimer=setInterval(function(){C("reconnectTimer :: reconnect triggered!"),N._reconnect()},N.options.reconnectPeriod)):C("_setupReconnect :: doing nothing...")},H.prototype._clearReconnect=function(){C("_clearReconnect : clearing reconnect timer"),this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},H.prototype._cleanUp=function(N,E){var se=arguments[2];if(E&&(C("_cleanUp :: done callback provided for on stream close"),this.stream.on("close",E)),C("_cleanUp :: forced? %s",N),N)0===this.options.reconnectPeriod&&this.options.clean&&oe(this.outgoing),C("_cleanUp :: (%s) :: destroying stream",this.options.clientId),this.stream.destroy();else{var J=z({cmd:"disconnect"},se);C("_cleanUp :: (%s) :: call _sendPacket with disconnect packet",this.options.clientId),this._sendPacket(J,M.bind(null,this.stream.end.bind(this.stream)))}this.disconnecting||(C("_cleanUp :: client not disconnecting. Clearing and resetting reconnect."),this._clearReconnect(),this._setupReconnect()),null!==this.pingTimer&&(C("_cleanUp :: clearing pingTimer"),this.pingTimer.clear(),this.pingTimer=null),E&&!this.connected&&(C("_cleanUp :: (%s) :: removing stream `done` callback `close` listener",this.options.clientId),this.stream.removeListener("close",E),E())},H.prototype._sendPacket=function(N,E,se){if(C("_sendPacket :: (%s) :: start",this.options.clientId),se=se||Y,!this.connected)return C("_sendPacket :: client not connected. Storing packet offline."),void this._storePacket(N,E,se);switch(this._shiftPingInterval(),N.cmd){case"publish":break;case"pubrel":return void le(this,N,E,se);default:return void G(this,N,E)}switch(N.qos){case 2:case 1:le(this,N,E,se);break;default:G(this,N,E)}C("_sendPacket :: (%s) :: end",this.options.clientId)},H.prototype._storePacket=function(N,E,se){C("_storePacket :: packet: %o",N),C("_storePacket :: cb? %s",!!E),se=se||Y,0===(N.qos||0)&&this.queueQoSZero||"publish"!==N.cmd?this.queue.push({packet:N,cb:E}):N.qos>0?(E=this.outgoing[N.messageId]?this.outgoing[N.messageId].cb:null,this.outgoingStore.put(N,function(J){if(J)return E&&E(J);se()})):E&&E(new Error("No connection to broker"))},H.prototype._setupPingTimer=function(){C("_setupPingTimer :: keepalive %d (seconds)",this.options.keepalive);var N=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=_(function(){N._checkPing()},1e3*this.options.keepalive))},H.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},H.prototype._checkPing=function(){C("_checkPing :: checking ping..."),this.pingResp?(C("_checkPing :: ping response received. Clearing flag and sending `pingreq`"),this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):(C("_checkPing :: calling _cleanUp with force true"),this._cleanUp(!0))},H.prototype._handlePingresp=function(){this.pingResp=!0},H.prototype._handleConnack=function(N){C("_handleConnack");var E=this.options,J=5===E.protocolVersion?N.reasonCode:N.returnCode;if(clearTimeout(this.connackTimer),N.properties&&(N.properties.topicAliasMaximum&&(E.properties||(E.properties={}),E.properties.topicAliasMaximum=N.properties.topicAliasMaximum),N.properties.serverKeepAlive&&E.keepalive&&(E.keepalive=N.properties.serverKeepAlive,this._shiftPingInterval()),N.properties.maximumPacketSize&&(E.properties||(E.properties={}),E.properties.maximumPacketSize=N.properties.maximumPacketSize)),0===J)this.reconnecting=!1,this._onConnect(N);else if(J>0){var pe=new Error("Connection refused: "+B[J]);pe.code=J,this.emit("error",pe)}},H.prototype._handlePublish=function(N,E){C("_handlePublish: packet %o",N),E=void 0!==E?E:Y;var se=N.topic.toString(),J=N.payload,pe=N.qos,Ce=N.messageId,ge=this,Fe=this.options,ue=[0,16,128,131,135,144,145,151,153];switch(C("_handlePublish: qos %d",pe),pe){case 2:Fe.customHandleAcks(se,J,N,function(Ye,Ne){return Ye instanceof Error||(Ne=Ye,Ye=null),Ye?ge.emit("error",Ye):-1===ue.indexOf(Ne)?ge.emit("error",new Error("Wrong reason code for pubrec")):void(Ne?ge._sendPacket({cmd:"pubrec",messageId:Ce,reasonCode:Ne},E):ge.incomingStore.put(N,function(){ge._sendPacket({cmd:"pubrec",messageId:Ce},E)}))});break;case 1:Fe.customHandleAcks(se,J,N,function(Ye,Ne){return Ye instanceof Error||(Ne=Ye,Ye=null),Ye?ge.emit("error",Ye):-1===ue.indexOf(Ne)?ge.emit("error",new Error("Wrong reason code for puback")):(Ne||ge.emit("message",se,J,N),void ge.handleMessage(N,function(Pe){if(Pe)return E&&E(Pe);ge._sendPacket({cmd:"puback",messageId:Ce,reasonCode:Ne},E)}))});break;case 0:this.emit("message",se,J,N),this.handleMessage(N,E);break;default:C("_handlePublish: unknown QoS. Doing nothing.")}},H.prototype.handleMessage=function(N,E){E()},H.prototype._handleAck=function(N){var ge,E=N.messageId,se=N.cmd,J=null,pe=this.outgoing[E]?this.outgoing[E].cb:null,Ce=this;if(pe){switch(C("_handleAck :: packet type",se),se){case"pubcomp":case"puback":var Fe=N.reasonCode;Fe&&Fe>0&&16!==Fe&&((ge=new Error("Publish error: "+B[Fe])).code=Fe,pe(ge,N)),delete this.outgoing[E],this.outgoingStore.del(N,pe);break;case"pubrec":J={cmd:"pubrel",qos:2,messageId:E};var ue=N.reasonCode;ue&&ue>0&&16!==ue?((ge=new Error("Publish error: "+B[ue])).code=ue,pe(ge,N)):this._sendPacket(J);break;case"suback":delete this.outgoing[E];for(var Ye=0;Ye0)if(this.options.resubscribe)if(5===this.options.protocolVersion){C("_resubscribe: protocolVersion 5");for(var se=0;sede&&setTimeout(ue,le,Ne,Pe,_e),Y&&"string"==typeof Ne&&(Ne=S.from(Ne,"utf8"));try{H.send(Ne)}catch(ve){return _e(ve)}_e()},function Ye(Ne){H.close(),Ne()});Q.objectMode||(N._writev=Fe),N.on("close",()=>{H.close()});const E=void 0===H.addEventListener;function J(){G.setReadable(N),G.setWritable(N),G.emit("connect")}function pe(){G.end(),G.destroy()}function Ce(Ne){G.destroy(Ne)}function ge(Ne){let Pe=Ne.data;Pe=Pe instanceof ArrayBuffer?S.from(Pe):S.from(Pe,"utf8"),N.push(Pe)}function Fe(Ne,Pe){const _e=new Array(Ne.length);for(let ve=0;vethis.length||m<0)return;const y=this._offset(m);return this._bufs[y[0]][y[1]]},R.prototype.slice=function(m,y){return"number"==typeof m&&m<0&&(m+=this.length),"number"==typeof y&&y<0&&(y+=this.length),this.copy(null,0,m,y)},R.prototype.copy=function(m,y,v,_){if(("number"!=typeof v||v<0)&&(v=0),("number"!=typeof _||_>this.length)&&(_=this.length),v>=this.length||_<=0)return m||T.alloc(0);const I=!!m,z=this._offset(v),C=_-v;let P=C,M=I&&y||0,O=z[1];if(0===v&&_===this.length){if(!I)return 1===this._bufs.length?this._bufs[0]:T.concat(this._bufs,this.length);for(let F=0;FB)){this._bufs[F].copy(m,M,O,O+P),M+=B;break}this._bufs[F].copy(m,M,O),M+=B,P-=B,O&&(O=0)}return m.length>M?m.slice(0,M):m},R.prototype.shallowSlice=function(m,y){if((m=m||0)<0&&(m+=this.length),(y="number"!=typeof y?this.length:y)<0&&(y+=this.length),m===y)return this._new();const v=this._offset(m),_=this._offset(y),I=this._bufs.slice(v[0],_[0]+1);return 0===_[1]?I.pop():I[I.length-1]=I[I.length-1].slice(0,_[1]),0!==v[1]&&(I[0]=I[0].slice(v[1])),this._new(I)},R.prototype.toString=function(m,y,v){return this.slice(y,v).toString(m)},R.prototype.consume=function(m){if(m=Math.trunc(m),Number.isNaN(m)||m<=0)return this;for(;this._bufs.length;){if(!(m>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(m),this.length-=m;break}m-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},R.prototype.duplicate=function(){const m=this._new();for(let y=0;ythis.length?this.length:m;const v=this._offset(m);let _=v[0],I=v[1];for(;_=D.length){const P=z.indexOf(D,I);if(-1!==P)return this._reverseOffset([_,P]);I=z.length-D.length+1}else{const P=this._reverseOffset([_,I]);if(this._match(P,D))return P;I++}I=0}return-1},R.prototype._match=function(D,m){if(this.length-D{"%%"!==P&&(z++,"%c"===P&&(C=z))}),_.splice(C,0,I)},re.save=function D(_){try{_?re.storage.setItem("debug",_):re.storage.removeItem("debug")}catch(I){}},re.load=function m(){let _;try{_=re.storage.getItem("debug")}catch(I){}return!_&&void 0!==T&&"env"in T&&(_=T.env.DEBUG),_},re.useColors=function S(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},re.storage=function y(){try{return localStorage}catch(_){}}(),re.destroy=(()=>{let _=!1;return()=>{_||(_=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),re.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],re.log=console.debug||console.log||(()=>{}),X.exports=V("./common")(re);const{formatters:v}=X.exports;v.j=function(_){try{return JSON.stringify(_)}catch(I){return"[UnexpectedJSONParseError]: "+I.message}}}).call(this)}).call(this,V("_process"))},{"./common":20,_process:69}],20:[function(V,X,re){X.exports=function T(S){function D(P){let M,O=null;function F(...B){if(!F.enabled)return;const Q=F,G=Number(new Date);Q.diff=G-(M||G),Q.prev=M,Q.curr=G,M=G,B[0]=D.coerce(B[0]),"string"!=typeof B[0]&&B.unshift("%O");let de=0;B[0]=B[0].replace(/%([a-zA-Z%])/g,(Y,H)=>{if("%%"===Y)return"%";de++;const N=D.formatters[H];return"function"==typeof N&&(Y=N.call(Q,B[de]),B.splice(de,1),de--),Y}),D.formatArgs.call(Q,B),(Q.log||D.log).apply(Q,B)}return F.namespace=P,F.useColors=D.useColors(),F.color=D.selectColor(P),F.extend=m,F.destroy=D.destroy,Object.defineProperty(F,"enabled",{enumerable:!0,configurable:!1,get:()=>null===O?D.enabled(P):O,set:B=>{O=B}}),"function"==typeof D.init&&D.init(F),F}function m(P,M){const O=D(this.namespace+(void 0===M?":":M)+P);return O.log=this.log,O}function I(P){return P.toString().substring(2,P.toString().length-2).replace(/\.\*\?$/,"*")}return D.debug=D,D.default=D,D.coerce=function z(P){return P instanceof Error?P.stack||P.message:P},D.disable=function v(){const P=[...D.names.map(I),...D.skips.map(I).map(M=>"-"+M)].join(",");return D.enable(""),P},D.enable=function y(P){let M;D.save(P),D.names=[],D.skips=[];const O=("string"==typeof P?P:"").split(/[\s,]+/),F=O.length;for(M=0;M{D[P]=S[P]}),D.names=[],D.skips=[],D.formatters={},D.selectColor=function R(P){let M=0;for(let O=0;O0?("string"!=typeof b&&!h.objectMode&&Object.getPrototypeOf(b)!==I.prototype&&(b=function C(g){return I.from(g)}(b)),ne?h.endEmitted?g.emit("error",new Error("stream.unshift() after end event")):N(g,h,b,!0):h.ended?g.emit("error",new Error("stream.push() after EOF")):(h.reading=!1,h.decoder&&!q?(b=h.decoder.write(b),h.objectMode||0!==b.length?N(g,h,b,!1):Ye(g,h)):N(g,h,b,!1))):ne||(h.reading=!1)),function se(g){return!g.ended&&(g.needReadable||g.lengthb.highWaterMark&&(b.highWaterMark=function pe(g){return g>=J?g=J:(g--,g|=g>>>1,g|=g>>>2,g|=g>>>4,g|=g>>>8,g|=g>>>16,g++),g}(g)),g<=b.length?g:b.ended?b.length:(b.needReadable=!0,0))}function Fe(g){var b=g._readableState;b.needReadable=!1,b.emittedReadable||(F("emitReadable",b.flowing),b.emittedReadable=!0,b.sync?R.nextTick(ue,g):ue(g))}function ue(g){F("emit readable"),g.emit("readable"),ee(g)}function Ye(g,b){b.readingMore||(b.readingMore=!0,R.nextTick(Ne,g,b))}function Ne(g,b){for(var q=b.length;!b.reading&&!b.flowing&&!b.ended&&b.length=b.length?(q=b.decoder?b.buffer.join(""):1===b.buffer.length?b.buffer.head.data:b.buffer.concat(b.length),b.buffer.clear()):q=function xe(g,b,q){var ne;return gh.length?h.length:g;if(A+=u===h.length?h:h.slice(0,g),0==(g-=u)){u===h.length?(++ne,b.head=q.next?q.next:b.tail=null):(b.head=q,q.data=h.slice(u));break}++ne}return b.length-=ne,A}(g,b):function $(g,b){var q=I.allocUnsafe(g),ne=b.head,A=1;for(ne.data.copy(q),g-=ne.data.length;ne=ne.next;){var h=ne.data,u=g>h.length?h.length:g;if(h.copy(q,q.length-g,0,u),0==(g-=u)){u===h.length?(++A,b.head=ne.next?ne.next:b.tail=null):(b.head=ne,ne.data=h.slice(u));break}++A}return b.length-=A,q}(g,b),ne}(g,b.buffer,b.decoder),q);var q}function ye(g){var b=g._readableState;if(b.length>0)throw new Error('"endReadable()" called on non-empty stream');b.endEmitted||(b.ended=!0,R.nextTick(Re,b,g))}function Re(g,b){!g.endEmitted&&0===g.length&&(g.endEmitted=!0,b.readable=!1,b.emit("end"))}function W(g,b){for(var q=0,ne=g.length;q=b.highWaterMark||b.ended))return F("read: emitReadable",b.length,b.ended),0===b.length&&b.ended?ye(this):Fe(this),null;if(0===(g=Ce(g,b))&&b.ended)return 0===b.length&&ye(this),null;var A,ne=b.needReadable;return F("need readable",ne),(0===b.length||b.length-g0?be(g,b):null)?(b.needReadable=!0,g=0):b.length-=g,0===b.length&&(b.ended||(b.needReadable=!0),q!==g&&b.ended&&ye(this)),null!==A&&this.emit("data",A),A},Y.prototype._read=function(g){this.emit("error",new Error("_read() is not implemented"))},Y.prototype.pipe=function(g,b){var q=this,ne=this._readableState;switch(ne.pipesCount){case 0:ne.pipes=g;break;case 1:ne.pipes=[ne.pipes,g];break;default:ne.pipes.push(g)}ne.pipesCount+=1,F("pipe count=%d opts=%j",ne.pipesCount,b);var h=b&&!1===b.end||g===T.stdout||g===T.stderr?Bt:p;function u(zn,_i){F("onunpipe"),zn===q&&_i&&!1===_i.hasUnpiped&&(_i.hasUnpiped=!0,function me(){F("cleanup"),g.removeListener("close",Vt),g.removeListener("finish",nn),g.removeListener("drain",L),g.removeListener("error",yt),g.removeListener("unpipe",u),q.removeListener("end",p),q.removeListener("end",Bt),q.removeListener("data",Ze),Z=!0,ne.awaitDrain&&(!g._writableState||g._writableState.needDrain)&&L()}())}function p(){F("onend"),g.end()}ne.endEmitted?R.nextTick(h):q.once("end",h),g.on("unpipe",u);var L=function Pe(g){return function(){var b=g._readableState;F("pipeOnDrain",b.awaitDrain),b.awaitDrain&&b.awaitDrain--,0===b.awaitDrain&&v(g,"data")&&(b.flowing=!0,ee(g))}}(q);g.on("drain",L);var Z=!1;var Se=!1;function Ze(zn){F("ondata"),Se=!1,!1===g.write(zn)&&!Se&&((1===ne.pipesCount&&ne.pipes===g||ne.pipesCount>1&&-1!==W(ne.pipes,g))&&!Z&&(F("false write response, pause",q._readableState.awaitDrain),q._readableState.awaitDrain++,Se=!0),q.pause())}function yt(zn){F("onerror",zn),Bt(),g.removeListener("error",yt),0===v(g,"error")&&g.emit("error",zn)}function Vt(){g.removeListener("finish",nn),Bt()}function nn(){F("onfinish"),g.removeListener("close",Vt),Bt()}function Bt(){F("unpipe"),q.unpipe(g)}return q.on("data",Ze),function de(g,b,q){if("function"==typeof g.prependListener)return g.prependListener(b,q);g._events&&g._events[b]?D(g._events[b])?g._events[b].unshift(q):g._events[b]=[q,g._events[b]]:g.on(b,q)}(g,"error",yt),g.once("close",Vt),g.once("finish",nn),g.emit("pipe",q),ne.flowing||(F("pipe resume"),q.resume()),g},Y.prototype.unpipe=function(g){var b=this._readableState,q={hasUnpiped:!1};if(0===b.pipesCount)return this;if(1===b.pipesCount)return g&&g!==b.pipes||(g||(g=b.pipes),b.pipes=null,b.pipesCount=0,b.flowing=!1,g&&g.emit("unpipe",this,q)),this;if(!g){var ne=b.pipes,A=b.pipesCount;b.pipes=null,b.pipesCount=0,b.flowing=!1;for(var h=0;h-1?R:D.nextTick;de.WritableState=G;var I=Object.create(V("core-util-is"));I.inherits=V("inherits");var z={deprecate:V("util-deprecate")},C=V("./internal/streams/stream"),P=V("safe-buffer").Buffer,M=S.Uint8Array||function(){};var oe,B=V("./internal/streams/destroy");function Q(){}function G(U,ee){_=_||V("./_stream_duplex");var be=ee instanceof _;this.objectMode=!!(U=U||{}).objectMode,be&&(this.objectMode=this.objectMode||!!U.writableObjectMode);var xe=U.highWaterMark,ie=U.writableHighWaterMark;this.highWaterMark=xe||0===xe?xe:be&&(ie||0===ie)?ie:this.objectMode?16:16384,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1,this.decodeStrings=!(!1===U.decodeStrings),this.defaultEncoding=U.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Re){!function pe(U,ee){var be=U._writableState,xe=be.sync,ie=be.writecb;if(function J(U){U.writing=!1,U.writecb=null,U.length-=U.writelen,U.writelen=0}(be),ee)!function se(U,ee,be,xe,ie){--ee.pendingcb,be?(D.nextTick(ie,xe),D.nextTick(Pe,U,ee),U._writableState.errorEmitted=!0,U.emit("error",xe)):(ie(xe),U._writableState.errorEmitted=!0,U.emit("error",xe),Pe(U,ee))}(U,be,xe,ee,ie);else{var $=ue(be);!$&&!be.corked&&!be.bufferProcessing&&be.bufferedRequest&&Fe(U,be),xe?v(Ce,U,be,$,ie):Ce(U,be,$,ie)}}(ee,Re)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new y(this)}function de(U){if(_=_||V("./_stream_duplex"),!(oe.call(de,this)||this instanceof _))return new de(U);this._writableState=new G(U,this),this.writable=!0,U&&("function"==typeof U.write&&(this._write=U.write),"function"==typeof U.writev&&(this._writev=U.writev),"function"==typeof U.destroy&&(this._destroy=U.destroy),"function"==typeof U.final&&(this._final=U.final)),C.call(this)}function N(U,ee,be,xe,ie,$){if(!be){var ye=function H(U,ee,be){return!U.objectMode&&!1!==U.decodeStrings&&"string"==typeof ee&&(ee=P.from(ee,be)),ee}(ee,xe,ie);xe!==ye&&(be=!0,ie="buffer",xe=ye)}var Re=ee.objectMode?1:xe.length;ee.length+=Re;var W=ee.length-1))throw new TypeError("Unknown encoding: "+ee);return this._writableState.defaultEncoding=ee,this},Object.defineProperty(de.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),de.prototype._write=function(U,ee,be){be(new Error("_write() is not implemented"))},de.prototype._writev=null,de.prototype.end=function(U,ee,be){var xe=this._writableState;"function"==typeof U?(be=U,U=null,ee=null):"function"==typeof ee&&(be=ee,ee=null),null!=U&&this.write(U,ee),xe.corked&&(xe.corked=1,this.uncork()),!xe.ending&&!xe.finished&&function _e(U,ee,be){ee.ending=!0,Pe(U,ee),be&&(ee.finished?D.nextTick(be):U.once("finish",be)),ee.ended=!0,U.writable=!1}(this,xe,be)},Object.defineProperty(de.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(U){!this._writableState||(this._writableState.destroyed=U)}}),de.prototype.destroy=B.destroy,de.prototype._undestroy=B.undestroy,de.prototype._destroy=function(U,ee){this.end(),ee(U)}}).call(this)}).call(this,V("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},V("timers").setImmediate)},{"./_stream_duplex":22,"./internal/streams/destroy":28,"./internal/streams/stream":29,_process:69,"core-util-is":18,inherits:34,"process-nextick-args":45,"safe-buffer":31,timers:74,"util-deprecate":65}],27:[function(V,X,re){"use strict";var S=V("safe-buffer").Buffer,R=V("util");function D(m,y,v){m.copy(y,v)}X.exports=function(){function m(){(function T(m,y){if(!(m instanceof y))throw new TypeError("Cannot call a class as a function")})(this,m),this.head=null,this.tail=null,this.length=0}return m.prototype.push=function(v){var _={data:v,next:null};this.length>0?this.tail.next=_:this.head=_,this.tail=_,++this.length},m.prototype.unshift=function(v){var _={data:v,next:this.head};0===this.length&&(this.tail=_),this.head=_,++this.length},m.prototype.shift=function(){if(0!==this.length){var v=this.head.data;return this.head=1===this.length?this.tail=null:this.head.next,--this.length,v}},m.prototype.clear=function(){this.head=this.tail=null,this.length=0},m.prototype.join=function(v){if(0===this.length)return"";for(var _=this.head,I=""+_.data;_=_.next;)I+=v+_.data;return I},m.prototype.concat=function(v){if(0===this.length)return S.alloc(0);if(1===this.length)return this.head.data;for(var _=S.allocUnsafe(v>>>0),I=this.head,z=0;I;)D(I.data,_,z),z+=I.data.length,I=I.next;return _},m}(),R&&R.inspect&&R.inspect.custom&&(X.exports.prototype[R.inspect.custom]=function(){var m=R.inspect({length:this.length});return this.constructor.name+" "+m})},{"safe-buffer":31,util:2}],28:[function(V,X,re){"use strict";var T=V("process-nextick-args");function D(m,y){m.emit("error",y)}X.exports={destroy:function S(m,y){var v=this;return this._readableState&&this._readableState.destroyed||this._writableState&&this._writableState.destroyed?(y?y(m):m&&(!this._writableState||!this._writableState.errorEmitted)&&T.nextTick(D,this,m),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(m||null,function(z){!y&&z?(T.nextTick(D,v,z),v._writableState&&(v._writableState.errorEmitted=!0)):y&&y(z)}),this)},undestroy:function R(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},{"process-nextick-args":45}],29:[function(V,X,re){X.exports=V("events").EventEmitter},{events:4}],30:[function(V,X,re){(re=X.exports=V("./lib/_stream_readable.js")).Stream=re,re.Readable=re,re.Writable=V("./lib/_stream_writable.js"),re.Duplex=V("./lib/_stream_duplex.js"),re.Transform=V("./lib/_stream_transform.js"),re.PassThrough=V("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":22,"./lib/_stream_passthrough.js":23,"./lib/_stream_readable.js":24,"./lib/_stream_transform.js":25,"./lib/_stream_writable.js":26}],31:[function(V,X,re){var T=V("buffer"),S=T.Buffer;function R(m,y){for(var v in m)y[v]=m[v]}function D(m,y,v){return S(m,y,v)}S.from&&S.alloc&&S.allocUnsafe&&S.allocUnsafeSlow?X.exports=T:(R(T,re),re.Buffer=D),R(S,D),D.from=function(m,y,v){if("number"==typeof m)throw new TypeError("Argument must not be a number");return S(m,y,v)},D.alloc=function(m,y,v){if("number"!=typeof m)throw new TypeError("Argument must be a number");var _=S(m);return void 0!==y?"string"==typeof v?_.fill(y,v):_.fill(y):_.fill(0),_},D.allocUnsafe=function(m){if("number"!=typeof m)throw new TypeError("Argument must be a number");return S(m)},D.allocUnsafeSlow=function(m){if("number"!=typeof m)throw new TypeError("Argument must be a number");return T.SlowBuffer(m)}},{buffer:3}],32:[function(V,X,re){"use strict";var T=V("safe-buffer").Buffer,S=T.isEncoding||function(G){switch((G=""+G)&&G.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function m(G){var oe;switch(this.encoding=function D(G){var oe=function R(G){if(!G)return"utf8";for(var oe;;)switch(G){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return G;default:if(oe)return;G=(""+G).toLowerCase(),oe=!0}}(G);if("string"!=typeof oe&&(T.isEncoding===S||!S(G)))throw new Error("Unknown encoding: "+G);return oe||G}(G),this.encoding){case"utf16le":this.text=P,this.end=M,oe=4;break;case"utf8":this.fillLast=I,oe=4;break;case"base64":this.text=O,this.end=F,oe=3;break;default:return this.write=B,void(this.end=Q)}this.lastNeed=0,this.lastTotal=0,this.lastChar=T.allocUnsafe(oe)}function y(G){return G<=127?0:G>>5==6?2:G>>4==14?3:G>>3==30?4:G>>6==2?-1:-2}function I(G){var oe=this.lastTotal-this.lastNeed,de=function _(G,oe,de){if(128!=(192&oe[0]))return G.lastNeed=0,"\ufffd";if(G.lastNeed>1&&oe.length>1){if(128!=(192&oe[1]))return G.lastNeed=1,"\ufffd";if(G.lastNeed>2&&oe.length>2&&128!=(192&oe[2]))return G.lastNeed=2,"\ufffd"}}(this,G);return void 0!==de?de:this.lastNeed<=G.length?(G.copy(this.lastChar,oe,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(G.copy(this.lastChar,oe,0,G.length),void(this.lastNeed-=G.length))}function P(G,oe){if((G.length-oe)%2==0){var de=G.toString("utf16le",oe);if(de){var le=de.charCodeAt(de.length-1);if(le>=55296&&le<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=G[G.length-2],this.lastChar[1]=G[G.length-1],de.slice(0,-1)}return de}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=G[G.length-1],G.toString("utf16le",oe,G.length-1)}function M(G){var oe=G&&G.length?this.write(G):"";return this.lastNeed?oe+this.lastChar.toString("utf16le",0,this.lastTotal-this.lastNeed):oe}function O(G,oe){var de=(G.length-oe)%3;return 0===de?G.toString("base64",oe):(this.lastNeed=3-de,this.lastTotal=3,1===de?this.lastChar[0]=G[G.length-1]:(this.lastChar[0]=G[G.length-2],this.lastChar[1]=G[G.length-1]),G.toString("base64",oe,G.length-de))}function F(G){var oe=G&&G.length?this.write(G):"";return this.lastNeed?oe+this.lastChar.toString("base64",0,3-this.lastNeed):oe}function B(G){return G.toString(this.encoding)}function Q(G){return G&&G.length?this.write(G):""}re.StringDecoder=m,m.prototype.write=function(G){if(0===G.length)return"";var oe,de;if(this.lastNeed){if(void 0===(oe=this.fillLast(G)))return"";de=this.lastNeed,this.lastNeed=0}else de=0;return de=0?(Y>0&&(G.lastNeed=Y-1),Y):--le=0?(Y>0&&(G.lastNeed=Y-2),Y):--le=0?(Y>0&&(2===Y?Y=0:G.lastNeed=Y-3),Y):0}(this,G,oe);if(!this.lastNeed)return G.toString("utf8",oe);this.lastTotal=de;var le=G.length-(de-this.lastNeed);return G.copy(this.lastChar,0,le),G.toString("utf8",oe,le)},m.prototype.fillLast=function(G){if(this.lastNeed<=G.length)return G.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);G.copy(this.lastChar,this.lastTotal-this.lastNeed,0,G.length),this.lastNeed-=G.length}},{"safe-buffer":31}],33:[function(V,X,re){(function(T){(function(){var S=V("once"),R=function(){},y=function(v,_,I){if("function"==typeof _)return y(v,null,_);_||(_={}),I=S(I||R);var z=v._writableState,C=v._readableState,P=_.readable||!1!==_.readable&&v.readable,M=_.writable||!1!==_.writable&&v.writable,O=!1,F=function(){v.writable||B()},B=function(){M=!1,P||I.call(v)},Q=function(){P=!1,M||I.call(v)},G=function(H){I.call(v,H?new Error("exited with error code: "+H):null)},oe=function(H){I.call(v,H)},de=function(){T.nextTick(le)},le=function(){if(!O){if(P&&(!C||!C.ended||C.destroyed))return I.call(v,new Error("premature close"));if(M&&(!z||!z.ended||z.destroyed))return I.call(v,new Error("premature close"))}},Y=function(){v.req.on("finish",B)};return function(v){return v.setHeader&&"function"==typeof v.abort}(v)?(v.on("complete",B),v.on("abort",de),v.req?Y():v.on("request",Y)):M&&!z&&(v.on("end",F),v.on("close",F)),function(v){return v.stdio&&Array.isArray(v.stdio)&&3===v.stdio.length}(v)&&v.on("exit",G),v.on("end",Q),v.on("finish",B),!1!==_.error&&v.on("error",oe),v.on("close",de),function(){O=!0,v.removeListener("complete",B),v.removeListener("abort",de),v.removeListener("request",Y),v.req&&v.req.removeListener("finish",B),v.removeListener("end",F),v.removeListener("close",F),v.removeListener("finish",B),v.removeListener("exit",G),v.removeListener("end",Q),v.removeListener("error",oe),v.removeListener("close",de)}};X.exports=y}).call(this)}).call(this,V("_process"))},{_process:69,once:44}],34:[function(V,X,re){X.exports="function"==typeof Object.create?function(S,R){R&&(S.super_=R,S.prototype=Object.create(R.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}))}:function(S,R){if(R){S.super_=R;var D=function(){};D.prototype=R.prototype,S.prototype=new D,S.prototype.constructor=S}}},{}],35:[function(V,X,re){var T={}.toString;X.exports=Array.isArray||function(S){return"[object Array]"==T.call(S)}},{}],36:[function(V,X,re){(function(T){(function(){const S=X.exports;S.types={0:"reserved",1:"connect",2:"connack",3:"publish",4:"puback",5:"pubrec",6:"pubrel",7:"pubcomp",8:"subscribe",9:"suback",10:"unsubscribe",11:"unsuback",12:"pingreq",13:"pingresp",14:"disconnect",15:"auth"},S.codes={};for(const D in S.types)S.codes[S.types[D]]=D;S.CMD_SHIFT=4,S.CMD_MASK=240,S.DUP_MASK=8,S.QOS_MASK=3,S.QOS_SHIFT=1,S.RETAIN_MASK=1,S.VARBYTEINT_MASK=127,S.VARBYTEINT_FIN_MASK=128,S.VARBYTEINT_MAX=268435455,S.SESSIONPRESENT_MASK=1,S.SESSIONPRESENT_HEADER=T.from([S.SESSIONPRESENT_MASK]),S.CONNACK_HEADER=T.from([S.codes.connack<[0,1].map(y=>[0,1].map(v=>{const _=T.alloc(1);return _.writeUInt8(S.codes[D]<T.from([D])),S.EMPTY={pingreq:T.from([S.codes.pingreq<<4,0]),pingresp:T.from([S.codes.pingresp<<4,0]),disconnect:T.from([S.codes.disconnect<<4,0])}}).call(this)}).call(this,V("buffer").Buffer)},{buffer:3}],37:[function(V,X,re){(function(T){(function(){const S=V("./writeToStream"),R=V("events");class m extends R{constructor(){super(),this._array=new Array(20),this._i=0}write(v){return this._array[this._i++]=v,!0}concat(){let v=0;const _=new Array(this._array.length),I=this._array;let C,z=0;for(C=0;C>8,0),z.writeUInt8(255&I,1),z}X.exports={cache:R,generateCache:function y(){for(let I=0;I<65536;I++)R[I]=m(I)},generateNumber:m,genBufVariableByteInt:function v(I){let C=0,P=0;const M=T.allocUnsafe(4);do{C=I%128|0,(I=I/128|0)>0&&(C|=128),M.writeUInt8(C,P++)}while(I>0&&P<4);return I>0&&(P=0),D?M.subarray(0,P):M.slice(0,P)},generate4ByteBuffer:function _(I){const z=T.allocUnsafe(4);return z.writeUInt32BE(I,0),z}}}).call(this)}).call(this,V("buffer").Buffer)},{buffer:3}],40:[function(V,X,re){X.exports=class T{constructor(){this.cmd=null,this.retain=!1,this.qos=0,this.dup=!1,this.length=-1,this.topic=null,this.payload=null}}},{}],41:[function(V,X,re){const T=V("bl"),S=V("events"),R=V("./packet"),D=V("./constants"),m=V("debug")("mqtt-packet:parser");class y extends S{constructor(){super(),this.parser=this.constructor.parser}static parser(_){return this instanceof y?(this.settings=_||{},this._states=["_parseHeader","_parseLength","_parsePayload","_newPacket"],this._resetState(),this):(new y).parser(_)}_resetState(){m("_resetState: resetting packet, error, _list, and _stateCounter"),this.packet=new R,this.error=null,this._list=T(),this._stateCounter=0}parse(_){for(this.error&&this._resetState(),this._list.append(_),m("parse: current state: %s",this._states[this._stateCounter]);(-1!==this.packet.length||this._list.length>0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,m("parse: state complete. _stateCounter is now: %d",this._stateCounter),m("parse: packet.length: %d, buffer list length: %d",this.packet.length,this._list.length),this._stateCounter>=this._states.length&&(this._stateCounter=0);return m("parse: exited while loop. packet: %d, buffer list length: %d",this.packet.length,this._list.length),this._list.length}_parseHeader(){const _=this._list.readUInt8(0);return this.packet.cmd=D.types[_>>D.CMD_SHIFT],this.packet.retain=0!=(_&D.RETAIN_MASK),this.packet.qos=_>>D.QOS_SHIFT&D.QOS_MASK,this.packet.dup=0!=(_&D.DUP_MASK),m("_parseHeader: packet: %o",this.packet),this._list.consume(1),!0}_parseLength(){const _=this._parseVarByteNum(!0);return _&&(this.packet.length=_.value,this._list.consume(_.bytes)),m("_parseLength %d",_.value),!!_}_parsePayload(){m("_parsePayload: payload %O",this._list);let _=!1;if(0===this.packet.length||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseConfirmation();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":break;case"disconnect":this._parseDisconnect();break;case"auth":this._parseAuth();break;default:this._emitError(new Error("Not supported"))}_=!0}return m("_parsePayload complete result: %s",_),_}_parseConnect(){let _,I,z,C;m("_parseConnect");const P={},M=this.packet,O=this._parseString();if(null===O)return this._emitError(new Error("Cannot parse protocolId"));if("MQTT"!==O&&"MQIsdp"!==O)return this._emitError(new Error("Invalid protocolId"));if(M.protocolId=O,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(M.protocolVersion=this._list.readUInt8(this._pos),M.protocolVersion>=128&&(M.bridgeMode=!0,M.protocolVersion=M.protocolVersion-128),3!==M.protocolVersion&&4!==M.protocolVersion&&5!==M.protocolVersion)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(P.username=this._list.readUInt8(this._pos)&D.USERNAME_MASK,P.password=this._list.readUInt8(this._pos)&D.PASSWORD_MASK,P.will=this._list.readUInt8(this._pos)&D.WILL_FLAG_MASK,P.will&&(M.will={},M.will.retain=0!=(this._list.readUInt8(this._pos)&D.WILL_RETAIN_MASK),M.will.qos=(this._list.readUInt8(this._pos)&D.WILL_QOS_MASK)>>D.WILL_QOS_SHIFT),M.clean=0!=(this._list.readUInt8(this._pos)&D.CLEAN_SESSION_MASK),this._pos++,M.keepalive=this._parseNum(),-1===M.keepalive)return this._emitError(new Error("Packet too short"));if(5===M.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(M.properties=B)}const F=this._parseString();if(null===F)return this._emitError(new Error("Packet too short"));if(M.clientId=F,m("_parseConnect: packet.clientId: %s",M.clientId),P.will){if(5===M.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(M.will.properties=B)}if(_=this._parseString(),null===_)return this._emitError(new Error("Cannot parse will topic"));if(M.will.topic=_,m("_parseConnect: packet.will.topic: %s",M.will.topic),I=this._parseBuffer(),null===I)return this._emitError(new Error("Cannot parse will payload"));M.will.payload=I,m("_parseConnect: packet.will.paylaod: %s",M.will.payload)}if(P.username){if(C=this._parseString(),null===C)return this._emitError(new Error("Cannot parse username"));M.username=C,m("_parseConnect: packet.username: %s",M.username)}if(P.password){if(z=this._parseBuffer(),null===z)return this._emitError(new Error("Cannot parse password"));M.password=z}return this.settings=M,m("_parseConnect: complete"),M}_parseConnack(){m("_parseConnack");const _=this.packet;if(this._list.length<1)return null;if(_.sessionPresent=!!(this._list.readUInt8(this._pos++)&D.SESSIONPRESENT_MASK),5===this.settings.protocolVersion)_.reasonCode=this._list.length>=2?this._list.readUInt8(this._pos++):0;else{if(this._list.length<2)return null;_.returnCode=this._list.readUInt8(this._pos++)}if(-1===_.returnCode||-1===_.reasonCode)return this._emitError(new Error("Cannot parse return code"));if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}m("_parseConnack: complete")}_parsePublish(){m("_parsePublish");const _=this.packet;if(_.topic=this._parseString(),null===_.topic)return this._emitError(new Error("Cannot parse topic"));if(!(_.qos>0)||this._parseMessageId()){if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}_.payload=this._list.slice(this._pos,_.length),m("_parsePublish: payload from buffer list: %o",_.payload)}}_parseSubscribe(){m("_parseSubscribe");const _=this.packet;let I,z,C,P,M,O,F;if(1!==_.qos)return this._emitError(new Error("Wrong subscribe header"));if(_.subscriptions=[],this._parseMessageId()){if(5===this.settings.protocolVersion){const B=this._parseProperties();Object.getOwnPropertyNames(B).length&&(_.properties=B)}for(;this._pos<_.length;){if(I=this._parseString(),null===I)return this._emitError(new Error("Cannot parse topic"));if(this._pos>=_.length)return this._emitError(new Error("Malformed Subscribe Payload"));z=this._parseByte(),C=z&D.SUBSCRIBE_OPTIONS_QOS_MASK,O=0!=(z>>D.SUBSCRIBE_OPTIONS_NL_SHIFT&D.SUBSCRIBE_OPTIONS_NL_MASK),M=0!=(z>>D.SUBSCRIBE_OPTIONS_RAP_SHIFT&D.SUBSCRIBE_OPTIONS_RAP_MASK),P=z>>D.SUBSCRIBE_OPTIONS_RH_SHIFT&D.SUBSCRIBE_OPTIONS_RH_MASK,F={topic:I,qos:C},5===this.settings.protocolVersion?(F.nl=O,F.rap=M,F.rh=P):this.settings.bridgeMode&&(F.rh=0,F.rap=!0,F.nl=!0),m("_parseSubscribe: push subscription `%s` to subscription",F),_.subscriptions.push(F)}}}_parseSuback(){m("_parseSuback");const _=this.packet;if(this.packet.granted=[],this._parseMessageId()){if(5===this.settings.protocolVersion){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}for(;this._pos2?(_.reasonCode=this._parseByte(),m("_parseConfirmation: packet.reasonCode `%d`",_.reasonCode)):_.reasonCode=0,_.length>3)){const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}return!0}_parseDisconnect(){const _=this.packet;if(m("_parseDisconnect"),5===this.settings.protocolVersion){_.reasonCode=this._list.length>0?this._parseByte():0;const I=this._parseProperties();Object.getOwnPropertyNames(I).length&&(_.properties=I)}return m("_parseDisconnect result: true"),!0}_parseAuth(){m("_parseAuth");const _=this.packet;if(5!==this.settings.protocolVersion)return this._emitError(new Error("Not supported auth packet for this version MQTT"));_.reasonCode=this._parseByte();const I=this._parseProperties();return Object.getOwnPropertyNames(I).length&&(_.properties=I),m("_parseAuth: result: true"),!0}_parseMessageId(){const _=this.packet;return _.messageId=this._parseNum(),null===_.messageId?(this._emitError(new Error("Cannot parse messageId")),!1):(m("_parseMessageId: packet.messageId %d",_.messageId),!0)}_parseString(_){const I=this._parseNum(),z=I+this._pos;if(-1===I||z>this._list.length||z>this.packet.length)return null;const C=this._list.toString("utf8",this._pos,z);return this._pos+=I,m("_parseString: result: %s",C),C}_parseStringPair(){return m("_parseStringPair"),{name:this._parseString(),value:this._parseString()}}_parseBuffer(){const _=this._parseNum(),I=_+this._pos;if(-1===_||I>this._list.length||I>this.packet.length)return null;const z=this._list.slice(this._pos,I);return this._pos+=_,m("_parseBuffer: result: %o",z),z}_parseNum(){if(this._list.length-this._pos<2)return-1;const _=this._list.readUInt16BE(this._pos);return this._pos+=2,m("_parseNum: result: %s",_),_}_parse4ByteNum(){if(this._list.length-this._pos<4)return-1;const _=this._list.readUInt32BE(this._pos);return this._pos+=4,m("_parse4ByteNum: result: %s",_),_}_parseVarByteNum(_){m("_parseVarByteNum");let O,z=0,C=1,P=0,M=!1;const F=this._pos?this._pos:0;for(;z<4&&F+z=z&&this._emitError(new Error("Invalid variable byte integer")),F&&(this._pos+=z),M=!!M&&(_?{bytes:z,value:P}:P),m("_parseVarByteNum: result: %o",M),M}_parseByte(){let _;return this._pos=4)&&(A||q))L+=T.byteLength(A)+2;else{if(g<4)return $.emit("error",new Error("clientId must be supplied before 3.1.1")),!1;if(1*q==0)return $.emit("error",new Error("clientId must be given if cleanSession set to 0")),!1}if("number"!=typeof ne||ne<0||ne>65535||ne%1!=0)return $.emit("error",new Error("Invalid keepalive")),!1;if(L+=2,L+=1,5===g){var Z=_e($,p);if(!Z)return!1;L+=Z.length}if(b){if("object"!=typeof b)return $.emit("error",new Error("Invalid will")),!1;if(!b.topic||"string"!=typeof b.topic)return $.emit("error",new Error("Invalid will topic")),!1;if(L+=T.byteLength(b.topic)+2,L+=2,b.payload){if(!(b.payload.length>=0))return $.emit("error",new Error("Invalid will payload")),!1;L+="string"==typeof b.payload?T.byteLength(b.payload):b.payload.length}var me={};if(5===g){if(!(me=_e($,b.properties)))return!1;L+=me.length}}let Se=!1;if(null!=h){if(!xe(h))return $.emit("error",new Error("Invalid username")),!1;Se=!0,L+=T.byteLength(h)+2}if(null!=u){if(!Se)return $.emit("error",new Error("Username is required to use password")),!1;if(!xe(u))return $.emit("error",new Error("Invalid password")),!1;L+=be(u)+2}$.write(S.CONNECT_HEADER),Ce($,L),Pe($,W),Re.bridgeMode&&(g+=128),$.write(131===g?S.VERSION131:132===g?S.VERSION132:4===g?S.VERSION4:5===g?S.VERSION5:S.VERSION3);let Ze=0;return Ze|=null!=h?S.USERNAME_MASK:0,Ze|=null!=u?S.PASSWORD_MASK:0,Ze|=b&&b.retain?S.WILL_RETAIN_MASK:0,Ze|=b&&b.qos?b.qos<0&&M($,A),null!=p&&p.write(),v("publish: payload: %o",ne),$.write(ne)}(ie,$,ye);case"puback":case"pubrec":case"pubrel":case"pubcomp":return function de(ie,$,ye){const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.cmd||"puback",b=W.messageId,q=W.dup&&"pubrel"===g?S.DUP_MASK:0;let ne=0;const A=W.reasonCode,h=W.properties;let u=5===Re?3:2;if("pubrel"===g&&(ne=1),"number"!=typeof b)return $.emit("error",new Error("Invalid messageId")),!1;let p=null;if(5===Re&&"object"==typeof h){if(p=ve($,h,ye,u),!p)return!1;u+=p.length}return $.write(S.ACKS[g][ne][q][0]),Ce($,u),M($,b),5===Re&&$.write(T.from([A])),null!==p&&p.write(),!0}(ie,$,ye);case"subscribe":return function le(ie,$,ye){v("subscribe: packet: ");const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.dup?S.DUP_MASK:0,b=W.messageId,q=W.subscriptions,ne=W.properties;let A=0;if("number"!=typeof b)return $.emit("error",new Error("Invalid messageId")),!1;A+=2;let h=null;if(5===Re){if(h=_e($,ne),!h)return!1;A+=h.length}if("object"!=typeof q||!q.length)return $.emit("error",new Error("Invalid subscriptions")),!1;for(let p=0;p2)return $.emit("error",new Error("Invalid subscriptions - invalid Retain Handling")),!1}A+=T.byteLength(L)+2+1}v("subscribe: writing to stream: %o",S.SUBSCRIBE_HEADER),$.write(S.SUBSCRIBE_HEADER[1][g?1:0][0]),Ce($,A),M($,b),null!==h&&h.write();let u=!0;for(const p of q){const Z=p.qos,me=+p.nl,Se=+p.rap,Ze=p.rh;let yt;ge($,p.topic),yt=S.SUBSCRIBE_OPTIONS_QOS[Z],5===Re&&(yt|=me?S.SUBSCRIBE_OPTIONS_NL:0,yt|=Se?S.SUBSCRIBE_OPTIONS_RAP:0,yt|=Ze?S.SUBSCRIBE_OPTIONS_RH[Ze]:0),u=$.write(T.from([yt]))}return u}(ie,$,ye);case"suback":return function Y(ie,$,ye){const Re=ye?ye.protocolVersion:4,W=ie||{},g=W.messageId,b=W.granted,q=W.properties;let ne=0;if("number"!=typeof g)return $.emit("error",new Error("Invalid messageId")),!1;if(ne+=2,"object"!=typeof b||!b.length)return $.emit("error",new Error("Invalid qos vector")),!1;for(let h=0;hM===ue,set(ie){ie?((!_||0===Object.keys(_).length)&&(O=!0),M=ue):(O=!1,M=Ye)}});const pe={};function Ce(ie,$){if($>S.VARBYTEINT_MAX)return ie.emit("error",new Error(`Invalid variable byte integer: ${$}`)),!1;let ye=pe[$];return ye||(ye=C($),$<16384&&(pe[$]=ye)),v("writeVarByteInt: writing to stream: %o",ye),ie.write(ye)}function ge(ie,$){const ye=T.byteLength($);return M(ie,ye),v("writeString: %s",$),ie.write($,"utf8")}function Fe(ie,$,ye){ge(ie,$),ge(ie,ye)}function ue(ie,$){return v("writeNumberCached: number: %d",$),v("writeNumberCached: %o",_[$]),ie.write(_[$])}function Ye(ie,$){const ye=I($);return v("writeNumberGenerated: %o",ye),ie.write(ye)}function Pe(ie,$){"string"==typeof $?ge(ie,$):$?(M(ie,$.length),ie.write($)):M(ie,0)}function _e(ie,$){if("object"!=typeof $||null!=$.length)return{length:1,write(){ee(ie,{},0)}};let ye=0;function Re(g,b){let ne=0;switch(S.propertiesTypes[g]){case"byte":if("boolean"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=2;break;case"int8":if("number"!=typeof b||b<0||b>255)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=2;break;case"binary":if(b&&null===b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=1+T.byteLength(b)+2;break;case"int16":if("number"!=typeof b||b<0||b>65535)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=3;break;case"int32":if("number"!=typeof b||b<0||b>4294967295)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=5;break;case"var":if("number"!=typeof b||b<0||b>268435455)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=1+T.byteLength(C(b));break;case"string":if("string"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=3+T.byteLength(b.toString());break;case"pair":if("object"!=typeof b)return ie.emit("error",new Error(`Invalid ${g}: ${b}`)),!1;ne+=Object.getOwnPropertyNames(b).reduce((A,h)=>{const u=b[h];return Array.isArray(u)?A+=u.reduce((p,L)=>p+(3+T.byteLength(h.toString())+2+T.byteLength(L.toString())),0):A+=3+T.byteLength(h.toString())+2+T.byteLength(b[h].toString()),A},0);break;default:return ie.emit("error",new Error(`Invalid property ${g}: ${b}`)),!1}return ne}if($)for(const g in $){let b=0,q=0;const ne=$[g];if(Array.isArray(ne))for(let A=0;Ag;){const q=W.shift();if(!q||!$[q])return!1;delete $[q],b=_e(ie,$)}return b}function U(ie,$,ye){switch(S.propertiesTypes[$]){case"byte":ie.write(T.from([S.properties[$]])),ie.write(T.from([+ye]));break;case"int8":ie.write(T.from([S.properties[$]])),ie.write(T.from([ye]));break;case"binary":ie.write(T.from([S.properties[$]])),Pe(ie,ye);break;case"int16":ie.write(T.from([S.properties[$]])),M(ie,ye);break;case"int32":ie.write(T.from([S.properties[$]])),function Ne(ie,$){const ye=P($);return v("write4ByteNumber: %o",ye),ie.write(ye)}(ie,ye);break;case"var":ie.write(T.from([S.properties[$]])),Ce(ie,ye);break;case"string":ie.write(T.from([S.properties[$]])),ge(ie,ye);break;case"pair":Object.getOwnPropertyNames(ye).forEach(W=>{const g=ye[W];Array.isArray(g)?g.forEach(b=>{ie.write(T.from([S.properties[$]])),Fe(ie,W.toString(),b.toString())}):(ie.write(T.from([S.properties[$]])),Fe(ie,W.toString(),g.toString()))});break;default:return ie.emit("error",new Error(`Invalid property ${$} value: ${ye}`)),!1}}function ee(ie,$,ye){Ce(ie,ye);for(const Re in $)if(Object.prototype.hasOwnProperty.call($,Re)&&null!==$[Re]){const W=$[Re];if(Array.isArray(W))for(let g=0;g=1.5*M;return Math.round(C/M)+" "+O+(F?"s":"")}X.exports=function(C,P){P=P||{};var M=typeof C;if("string"===M&&C.length>0)return function v(C){if(!((C=String(C)).length>100)){var P=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(C);if(P){var M=parseFloat(P[1]);switch((P[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*M;case"weeks":case"week":case"w":return 6048e5*M;case"days":case"day":case"d":return M*D;case"hours":case"hour":case"hrs":case"hr":case"h":return M*R;case"minutes":case"minute":case"mins":case"min":case"m":return M*S;case"seconds":case"second":case"secs":case"sec":case"s":return M*T;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return M;default:return}}}}(C);if("number"===M&&isFinite(C))return P.long?function I(C){var P=Math.abs(C);return P>=D?z(C,P,D,"day"):P>=R?z(C,P,R,"hour"):P>=S?z(C,P,S,"minute"):P>=T?z(C,P,T,"second"):C+" ms"}(C):function _(C){var P=Math.abs(C);return P>=D?Math.round(C/D)+"d":P>=R?Math.round(C/R)+"h":P>=S?Math.round(C/S)+"m":P>=T?Math.round(C/T)+"s":C+"ms"}(C);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(C))}},{}],44:[function(V,X,re){var T=V("wrappy");function S(D){var m=function(){return m.called?m.value:(m.called=!0,m.value=D.apply(this,arguments))};return m.called=!1,m}function R(D){var m=function(){if(m.called)throw new Error(m.onceError);return m.called=!0,m.value=D.apply(this,arguments)};return m.onceError=(D.name||"Function wrapped with `once`")+" shouldn't be called more than once",m.called=!1,m}X.exports=T(S),X.exports.strict=T(R),S.proto=S(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return S(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return R(this)},configurable:!0})})},{wrappy:66}],45:[function(V,X,re){(function(T){(function(){"use strict";X.exports=void 0===T||!T.version||0===T.version.indexOf("v0.")||0===T.version.indexOf("v1.")&&0!==T.version.indexOf("v1.8.")?{nextTick:function S(R,D,m,y){if("function"!=typeof R)throw new TypeError('"callback" argument must be a function');var _,I,v=arguments.length;switch(v){case 0:case 1:return T.nextTick(R);case 2:return T.nextTick(function(){R.call(null,D)});case 3:return T.nextTick(function(){R.call(null,D,m)});case 4:return T.nextTick(function(){R.call(null,D,m,y)});default:for(_=new Array(v-1),I=0;I<_.length;)_[I++]=arguments[I];return T.nextTick(function(){R.apply(null,_)})}}}:T}).call(this)}).call(this,V("_process"))},{_process:69}],46:[function(V,X,re){"use strict";var S={};function R(_,I,z){z||(z=Error);var P=function(M){function O(F,B,Q){return M.call(this,function C(M,O,F){return"string"==typeof I?I:I(M,O,F)}(F,B,Q))||this}return function T(_,I){_.prototype=Object.create(I.prototype),_.prototype.constructor=_,_.__proto__=I}(O,M),O}(z);P.prototype.name=z.name,P.prototype.code=_,S[_]=P}function D(_,I){if(Array.isArray(_)){var z=_.length;return _=_.map(function(C){return String(C)}),z>2?"one of ".concat(I," ").concat(_.slice(0,z-1).join(", "),", or ")+_[z-1]:2===z?"one of ".concat(I," ").concat(_[0]," or ").concat(_[1]):"of ".concat(I," ").concat(_[0])}return"of ".concat(I," ").concat(String(_))}R("ERR_INVALID_OPT_VALUE",function(_,I){return'The value "'+I+'" is invalid for option "'+_+'"'},TypeError),R("ERR_INVALID_ARG_TYPE",function(_,I,z){var C,P;if("string"==typeof I&&function m(_,I,z){return _.substr(!z||z<0?0:+z,I.length)===I}(I,"not ")?(C="must not be",I=I.replace(/^not /,"")):C="must be",function y(_,I,z){return(void 0===z||z>_.length)&&(z=_.length),_.substring(z-I.length,z)===I}(_," argument"))P="The ".concat(_," ").concat(C," ").concat(D(I,"type"));else{var M=function v(_,I,z){return"number"!=typeof z&&(z=0),!(z+I.length>_.length)&&-1!==_.indexOf(I,z)}(_,".")?"property":"argument";P='The "'.concat(_,'" ').concat(M," ").concat(C," ").concat(D(I,"type"))}return P+". Received type ".concat(typeof z)},TypeError),R("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),R("ERR_METHOD_NOT_IMPLEMENTED",function(_){return"The "+_+" method is not implemented"}),R("ERR_STREAM_PREMATURE_CLOSE","Premature close"),R("ERR_STREAM_DESTROYED",function(_){return"Cannot call "+_+" after a stream was destroyed"}),R("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),R("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),R("ERR_STREAM_WRITE_AFTER_END","write after end"),R("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),R("ERR_UNKNOWN_ENCODING",function(_){return"Unknown encoding: "+_},TypeError),R("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),X.exports.codes=S},{}],47:[function(V,X,re){(function(T){(function(){"use strict";var S=Object.keys||function(C){var P=[];for(var M in C)P.push(M);return P};X.exports=_;var R=V("./_stream_readable"),D=V("./_stream_writable");V("inherits")(_,R);for(var m=S(D.prototype),y=0;y0)if("string"!=typeof h&&!Z.objectMode&&Object.getPrototypeOf(h)!==v.prototype&&(h=function I(A){return v.from(A)}(h)),p)Z.endEmitted?E(A,new le):Fe(A,Z,h,!0);else if(Z.ended)E(A,new oe);else{if(Z.destroyed)return!1;Z.reading=!1,Z.decoder&&!u?(h=Z.decoder.write(h),Z.objectMode||0!==h.length?Fe(A,Z,h,!1):ee(A,Z)):Fe(A,Z,h,!1)}else p||(Z.reading=!1,ee(A,Z));return!Z.ended&&(Z.lengthh.highWaterMark&&(h.highWaterMark=function Ne(A){return A>=Ye?A=Ye:(A--,A|=A>>>1,A|=A>>>2,A|=A>>>4,A|=A>>>8,A|=A>>>16,A++),A}(A)),A<=h.length?A:h.ended?h.length:(h.needReadable=!0,0))}function ve(A){var h=A._readableState;P("emitReadable",h.needReadable,h.emittedReadable),h.needReadable=!1,h.emittedReadable||(P("emitReadable",h.flowing),h.emittedReadable=!0,T.nextTick(U,A))}function U(A){var h=A._readableState;P("emitReadable_",h.destroyed,h.length,h.ended),!h.destroyed&&(h.length||h.ended)&&(A.emit("readable"),h.emittedReadable=!1),h.needReadable=!h.flowing&&!h.ended&&h.length<=h.highWaterMark,W(A)}function ee(A,h){h.readingMore||(h.readingMore=!0,T.nextTick(be,A,h))}function be(A,h){for(;!h.reading&&!h.ended&&(h.length0,h.resumeScheduled&&!h.paused?h.flowing=!0:A.listenerCount("data")>0&&A.resume()}function $(A){P("readable nexttick read 0"),A.read(0)}function Re(A,h){P("resume",h.reading),h.reading||A.read(0),h.resumeScheduled=!1,A.emit("resume"),W(A),h.flowing&&!h.reading&&A.read(0)}function W(A){var h=A._readableState;for(P("flow",h.flowing);h.flowing&&null!==A.read(););}function g(A,h){return 0===h.length?null:(h.objectMode?u=h.buffer.shift():!A||A>=h.length?(u=h.decoder?h.buffer.join(""):1===h.buffer.length?h.buffer.first():h.buffer.concat(h.length),h.buffer.clear()):u=h.buffer.consume(A,h.decoder),u);var u}function b(A){var h=A._readableState;P("endReadable",h.endEmitted),h.endEmitted||(h.ended=!0,T.nextTick(q,h,A))}function q(A,h){if(P("endReadableNT",A.endEmitted,A.length),!A.endEmitted&&0===A.length&&(A.endEmitted=!0,h.readable=!1,h.emit("end"),A.autoDestroy)){var u=h._writableState;(!u||u.autoDestroy&&u.finished)&&h.destroy()}}function ne(A,h){for(var u=0,p=A.length;u=h.highWaterMark:h.length>0)||h.ended))return P("read: emitReadable",h.length,h.ended),0===h.length&&h.ended?b(this):ve(this),null;if(0===(A=Pe(A,h))&&h.ended)return 0===h.length&&b(this),null;var L,p=h.needReadable;return P("need readable",p),(0===h.length||h.length-A0?g(A,h):null)?(h.needReadable=h.length<=h.highWaterMark,A=0):(h.length-=A,h.awaitDrain=0),0===h.length&&(h.ended||(h.needReadable=!0),u!==A&&h.ended&&b(this)),null!==L&&this.emit("data",L),L},Ce.prototype._read=function(A){E(this,new de("_read()"))},Ce.prototype.pipe=function(A,h){var u=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=A;break;case 1:p.pipes=[p.pipes,A];break;default:p.pipes.push(A)}p.pipesCount+=1,P("pipe count=%d opts=%j",p.pipesCount,h);var Z=h&&!1===h.end||A===T.stdout||A===T.stderr?Oi:Se;function me(Vr,Hr){P("onunpipe"),Vr===u&&Hr&&!1===Hr.hasUnpiped&&(Hr.hasUnpiped=!0,function Vt(){P("cleanup"),A.removeListener("close",zn),A.removeListener("finish",_i),A.removeListener("drain",Ze),A.removeListener("error",Bt),A.removeListener("unpipe",me),u.removeListener("end",Se),u.removeListener("end",Oi),u.removeListener("data",nn),yt=!0,p.awaitDrain&&(!A._writableState||A._writableState.needDrain)&&Ze()}())}function Se(){P("onend"),A.end()}p.endEmitted?T.nextTick(Z):u.once("end",Z),A.on("unpipe",me);var Ze=function xe(A){return function(){var u=A._readableState;P("pipeOnDrain",u.awaitDrain),u.awaitDrain&&u.awaitDrain--,0===u.awaitDrain&&m(A,"data")&&(u.flowing=!0,W(A))}}(u);A.on("drain",Ze);var yt=!1;function nn(Vr){P("ondata");var Hr=A.write(Vr);P("dest.write",Hr),!1===Hr&&((1===p.pipesCount&&p.pipes===A||p.pipesCount>1&&-1!==ne(p.pipes,A))&&!yt&&(P("false write response, pause",p.awaitDrain),p.awaitDrain++),u.pause())}function Bt(Vr){P("onerror",Vr),Oi(),A.removeListener("error",Bt),0===m(A,"error")&&E(A,Vr)}function zn(){A.removeListener("finish",_i),Oi()}function _i(){P("onfinish"),A.removeListener("close",zn),Oi()}function Oi(){P("unpipe"),u.unpipe(A)}return u.on("data",nn),function J(A,h,u){if("function"==typeof A.prependListener)return A.prependListener(h,u);A._events&&A._events[h]?Array.isArray(A._events[h])?A._events[h].unshift(u):A._events[h]=[u,A._events[h]]:A.on(h,u)}(A,"error",Bt),A.once("close",zn),A.once("finish",_i),A.emit("pipe",u),p.flowing||(P("pipe resume"),u.resume()),A},Ce.prototype.unpipe=function(A){var h=this._readableState,u={hasUnpiped:!1};if(0===h.pipesCount)return this;if(1===h.pipesCount)return A&&A!==h.pipes||(A||(A=h.pipes),h.pipes=null,h.pipesCount=0,h.flowing=!1,A&&A.emit("unpipe",this,u)),this;if(!A){var p=h.pipes,L=h.pipesCount;h.pipes=null,h.pipesCount=0,h.flowing=!1;for(var Z=0;Z0,!1!==p.flowing&&this.resume()):"readable"===A&&!p.endEmitted&&!p.readableListening&&(p.readableListening=p.needReadable=!0,p.flowing=!1,p.emittedReadable=!1,P("on readable",p.length,p.reading),p.length?ve(this):p.reading||T.nextTick($,this)),u},Ce.prototype.removeListener=function(A,h){var u=y.prototype.removeListener.call(this,A,h);return"readable"===A&&T.nextTick(ie,this),u},Ce.prototype.removeAllListeners=function(A){var h=y.prototype.removeAllListeners.apply(this,arguments);return("readable"===A||void 0===A)&&T.nextTick(ie,this),h},Ce.prototype.resume=function(){var A=this._readableState;return A.flowing||(P("resume"),A.flowing=!A.readableListening,function ye(A,h){h.resumeScheduled||(h.resumeScheduled=!0,T.nextTick(Re,A,h))}(this,A)),A.paused=!1,this},Ce.prototype.pause=function(){return P("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(P("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},Ce.prototype.wrap=function(A){var h=this,u=this._readableState,p=!1;for(var L in A.on("end",function(){if(P("wrapped end"),u.decoder&&!u.ended){var me=u.decoder.end();me&&me.length&&h.push(me)}h.push(null)}),A.on("data",function(me){P("wrapped data"),u.decoder&&(me=u.decoder.write(me)),u.objectMode&&null==me||!(u.objectMode||me&&me.length)||h.push(me)||(p=!0,A.pause())}),A)void 0===this[L]&&"function"==typeof A[L]&&(this[L]=function(Se){return function(){return A[Se].apply(A,arguments)}}(L));for(var Z=0;Z-1))throw new H(g);return this._writableState.defaultEncoding=g,this},Object.defineProperty(pe.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(pe.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),pe.prototype._write=function(W,g,b){b(new Q("_write()"))},pe.prototype._writev=null,pe.prototype.end=function(W,g,b){var q=this._writableState;return"function"==typeof W?(b=W,W=null,g=null):"function"==typeof g&&(b=g,g=null),null!=W&&this.write(W,g),q.corked&&(q.corked=1,this.uncork()),q.ending||function ye(W,g,b){g.ending=!0,$(W,g),b&&(g.finished?T.nextTick(b):W.once("finish",b)),g.ended=!0,W.writable=!1}(this,q,b),this},Object.defineProperty(pe.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(pe.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(g){!this._writableState||(this._writableState.destroyed=g)}}),pe.prototype.destroy=P.destroy,pe.prototype._undestroy=P.undestroy,pe.prototype._destroy=function(W,g){g(W)}}).call(this)}).call(this,V("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../errors":46,"./_stream_duplex":47,"./internal/streams/destroy":54,"./internal/streams/state":58,"./internal/streams/stream":59,_process:69,buffer:3,inherits:34,"util-deprecate":65}],52:[function(V,X,re){(function(T){(function(){"use strict";var S;function R(oe,de,le){return de in oe?Object.defineProperty(oe,de,{value:le,enumerable:!0,configurable:!0,writable:!0}):oe[de]=le,oe}var D=V("./end-of-stream"),m=Symbol("lastResolve"),y=Symbol("lastReject"),v=Symbol("error"),_=Symbol("ended"),I=Symbol("lastPromise"),z=Symbol("handlePromise"),C=Symbol("stream");function P(oe,de){return{value:oe,done:de}}function M(oe){var de=oe[m];if(null!==de){var le=oe[C].read();null!==le&&(oe[I]=null,oe[m]=null,oe[y]=null,de(P(le,!1)))}}function O(oe){T.nextTick(M,oe)}var B=Object.getPrototypeOf(function(){}),Q=Object.setPrototypeOf((R(S={get stream(){return this[C]},next:function(){var de=this,le=this[v];if(null!==le)return Promise.reject(le);if(this[_])return Promise.resolve(P(void 0,!0));if(this[C].destroyed)return new Promise(function(E,se){T.nextTick(function(){de[v]?se(de[v]):E(P(void 0,!0))})});var H,Y=this[I];if(Y)H=new Promise(function F(oe,de){return function(le,Y){oe.then(function(){de[_]?le(P(void 0,!0)):de[z](le,Y)},Y)}}(Y,this));else{var N=this[C].read();if(null!==N)return Promise.resolve(P(N,!1));H=new Promise(this[z])}return this[I]=H,H}},Symbol.asyncIterator,function(){return this}),R(S,"return",function(){var de=this;return new Promise(function(le,Y){de[C].destroy(null,function(H){H?Y(H):le(P(void 0,!0))})})}),S),B);X.exports=function(de){var le,Y=Object.create(Q,(R(le={},C,{value:de,writable:!0}),R(le,m,{value:null,writable:!0}),R(le,y,{value:null,writable:!0}),R(le,v,{value:null,writable:!0}),R(le,_,{value:de._readableState.endEmitted,writable:!0}),R(le,z,{value:function(N,E){var se=Y[C].read();se?(Y[I]=null,Y[m]=null,Y[y]=null,N(P(se,!1))):(Y[m]=N,Y[y]=E)},writable:!0}),le));return Y[I]=null,D(de,function(H){if(H&&"ERR_STREAM_PREMATURE_CLOSE"!==H.code){var N=Y[y];return null!==N&&(Y[I]=null,Y[m]=null,Y[y]=null,N(H)),void(Y[v]=H)}var E=Y[m];null!==E&&(Y[I]=null,Y[m]=null,Y[y]=null,E(P(void 0,!0))),Y[_]=!0}),de.on("readable",O.bind(null,Y)),Y}}).call(this)}).call(this,V("_process"))},{"./end-of-stream":55,_process:69}],53:[function(V,X,re){"use strict";function T(M,O){var F=Object.keys(M);if(Object.getOwnPropertySymbols){var B=Object.getOwnPropertySymbols(M);O&&(B=B.filter(function(Q){return Object.getOwnPropertyDescriptor(M,Q).enumerable})),F.push.apply(F,B)}return F}function R(M,O,F){return O in M?Object.defineProperty(M,O,{value:F,enumerable:!0,configurable:!0,writable:!0}):M[O]=F,M}function m(M,O){for(var F=0;F0?this.tail.next=B:this.head=B,this.tail=B,++this.length}},{key:"unshift",value:function(F){var B={data:F,next:this.head};0===this.length&&(this.tail=B),this.head=B,++this.length}},{key:"shift",value:function(){if(0!==this.length){var F=this.head.data;return this.head=1===this.length?this.tail=null:this.head.next,--this.length,F}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(F){if(0===this.length)return"";for(var B=this.head,Q=""+B.data;B=B.next;)Q+=F+B.data;return Q}},{key:"concat",value:function(F){if(0===this.length)return _.alloc(0);for(var B=_.allocUnsafe(F>>>0),Q=this.head,G=0;Q;)P(Q.data,B,G),G+=Q.data.length,Q=Q.next;return B}},{key:"consume",value:function(F,B){var Q;return Foe.length?oe.length:F;if(G+=de===oe.length?oe:oe.slice(0,F),0==(F-=de)){de===oe.length?(++Q,this.head=B.next?B.next:this.tail=null):(this.head=B,B.data=oe.slice(de));break}++Q}return this.length-=Q,G}},{key:"_getBuffer",value:function(F){var B=_.allocUnsafe(F),Q=this.head,G=1;for(Q.data.copy(B),F-=Q.data.length;Q=Q.next;){var oe=Q.data,de=F>oe.length?oe.length:F;if(oe.copy(B,B.length-F,0,de),0==(F-=de)){de===oe.length?(++G,this.head=Q.next?Q.next:this.tail=null):(this.head=Q,Q.data=oe.slice(de));break}++G}return this.length-=G,B}},{key:C,value:function(F,B){return z(this,function S(M){for(var O=1;O0,function(H){Q||(Q=H),H&&G.forEach(I),!le&&(G.forEach(I),B(Q))})});return O.reduce(z)}},{"../../../errors":46,"./end-of-stream":55}],58:[function(V,X,re){"use strict";var T=V("../../../errors").codes.ERR_INVALID_OPT_VALUE;X.exports={getHighWaterMark:function R(D,m,y,v){var _=function S(D,m,y){return null!=D.highWaterMark?D.highWaterMark:m?D[y]:null}(m,v,y);if(null!=_){if(!isFinite(_)||Math.floor(_)!==_||_<0)throw new T(v?y:"highWaterMark",_);return Math.floor(_)}return D.objectMode?16:16384}}},{"../../../errors":46}],59:[function(V,X,re){arguments[4][29][0].apply(re,arguments)},{dup:29,events:4}],60:[function(V,X,re){(re=X.exports=V("./lib/_stream_readable.js")).Stream=re,re.Readable=re,re.Writable=V("./lib/_stream_writable.js"),re.Duplex=V("./lib/_stream_duplex.js"),re.Transform=V("./lib/_stream_transform.js"),re.PassThrough=V("./lib/_stream_passthrough.js"),re.finished=V("./lib/internal/streams/end-of-stream.js"),re.pipeline=V("./lib/internal/streams/pipeline.js")},{"./lib/_stream_duplex.js":47,"./lib/_stream_passthrough.js":48,"./lib/_stream_readable.js":49,"./lib/_stream_transform.js":50,"./lib/_stream_writable.js":51,"./lib/internal/streams/end-of-stream.js":55,"./lib/internal/streams/pipeline.js":57}],61:[function(V,X,re){"use strict";function T(R,D,m){var y=this;this._callback=R,this._args=m,this._interval=setInterval(R,D,this._args),this.reschedule=function(v){v||(v=y._interval),y._interval&&clearInterval(y._interval),y._interval=setInterval(y._callback,v,y._args)},this.clear=function(){y._interval&&(clearInterval(y._interval),y._interval=void 0)},this.destroy=function(){y._interval&&clearInterval(y._interval),y._callback=void 0,y._interval=void 0,y._args=void 0}}X.exports=function S(){if("function"!=typeof arguments[0])throw new Error("callback needed");if("number"!=typeof arguments[1])throw new Error("interval needed");var R;if(arguments.length>0){R=new Array(arguments.length-2);for(var D=0;D1)for(var G=1;G= 0x80 (not a basic code point)","invalid-input":"Invalid input"},le=Math.floor,Y=String.fromCharCode;function N(_e){throw new RangeError(oe[_e])}function E(_e,ve){for(var U=_e.length,ee=[];U--;)ee[U]=ve(_e[U]);return ee}function se(_e,ve){var U=_e.split("@"),ee="";return U.length>1&&(ee=U[0]+"@",_e=U[1]),ee+E((_e=_e.replace(G,".")).split("."),ve).join(".")}function J(_e){for(var be,xe,ve=[],U=0,ee=_e.length;U=55296&&be<=56319&&U65535&&(U+=Y((ve-=65536)>>>10&1023|55296),ve=56320|1023&ve),U+Y(ve)}).join("")}function Ce(_e){return _e-48<10?_e-22:_e-65<26?_e-65:_e-97<26?_e-97:_}function ge(_e,ve){return _e+22+75*(_e<26)-((0!=ve)<<5)}function Fe(_e,ve,U){var ee=0;for(_e=U?le(_e/700):_e>>1,_e+=le(_e/ve);_e>455;ee+=_)_e=le(_e/35);return le(ee+36*_e/(_e+38))}function ue(_e){var ee,$,ye,Re,W,g,b,q,ne,A,ve=[],U=_e.length,be=0,xe=128,ie=72;for(($=_e.lastIndexOf("-"))<0&&($=0),ye=0;ye<$;++ye)_e.charCodeAt(ye)>=128&&N("not-basic"),ve.push(_e.charCodeAt(ye));for(Re=$>0?$+1:0;Re=U&&N("invalid-input"),((q=Ce(_e.charCodeAt(Re++)))>=_||q>le((v-be)/g))&&N("overflow"),be+=q*g,!(q<(ne=b<=ie?1:b>=ie+26?26:b-ie));b+=_)g>le(v/(A=_-ne))&&N("overflow"),g*=A;ie=Fe(be-W,ee=ve.length+1,0==W),le(be/ee)>v-xe&&N("overflow"),xe+=le(be/ee),be%=ee,ve.splice(be++,0,xe)}return pe(ve)}function Ye(_e){var ve,U,ee,be,xe,ie,$,ye,Re,W,g,q,ne,A,h,b=[];for(q=(_e=J(_e)).length,ve=128,U=0,xe=72,ie=0;ie=ve&&g<$&&($=g);for($-ve>le((v-U)/(ne=ee+1))&&N("overflow"),U+=($-ve)*ne,ve=$,ie=0;iev&&N("overflow"),g==ve){for(ye=U,Re=_;!(ye<(W=Re<=xe?1:Re>=xe+26?26:Re-xe));Re+=_)b.push(Y(ge(W+(h=ye-W)%(A=_-W),0))),ye=le(h/A);b.push(Y(ge(ye,0))),xe=Fe(U,ne,ee==be),U=0,++ee}++U,++ve}return b.join("")}if(y={version:"1.4.1",ucs2:{decode:J,encode:pe},decode:ue,encode:Ye,toASCII:function Pe(_e){return se(_e,function(ve){return Q.test(ve)?"xn--"+Ye(ve):ve})},toUnicode:function Ne(_e){return se(_e,function(ve){return B.test(ve)?ue(ve.slice(4).toLowerCase()):ve})}},R&&D)if(X.exports==R)D.exports=y;else for(H in y)y.hasOwnProperty(H)&&(R[H]=y[H]);else S.punycode=y}(this)}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],71:[function(V,X,re){"use strict";function T(R,D){return Object.prototype.hasOwnProperty.call(R,D)}X.exports=function(R,D,m,y){m=m||"=";var v={};if("string"!=typeof R||0===R.length)return v;var _=/\+/g;R=R.split(D=D||"&");var I=1e3;y&&"number"==typeof y.maxKeys&&(I=y.maxKeys);var z=R.length;I>0&&z>I&&(z=I);for(var C=0;C=0?(O=P.substr(0,M),F=P.substr(M+1)):(O=P,F=""),B=decodeURIComponent(O),Q=decodeURIComponent(F),T(v,B)?S(v[B])?v[B].push(Q):v[B]=[v[B],Q]:v[B]=Q}return v};var S=Array.isArray||function(R){return"[object Array]"===Object.prototype.toString.call(R)}},{}],72:[function(V,X,re){"use strict";var T=function(m){switch(typeof m){case"string":return m;case"boolean":return m?"true":"false";case"number":return isFinite(m)?m:"";default:return""}};X.exports=function(m,y,v,_){return y=y||"&",v=v||"=",null===m&&(m=void 0),"object"==typeof m?R(D(m),function(I){var z=encodeURIComponent(T(I))+v;return S(m[I])?R(m[I],function(C){return z+encodeURIComponent(T(C))}).join(y):z+encodeURIComponent(T(m[I]))}).join(y):_?encodeURIComponent(T(_))+v+encodeURIComponent(T(m)):""};var S=Array.isArray||function(m){return"[object Array]"===Object.prototype.toString.call(m)};function R(m,y){if(m.map)return m.map(y);for(var v=[],_=0;_=0&&(I._idleTimeoutId=setTimeout(function(){I._onTimeout&&I._onTimeout()},z))},re.setImmediate="function"==typeof T?T:function(I){var z=v++,C=!(arguments.length<2)&&m.call(arguments,1);return y[z]=!0,R(function(){y[z]&&(C?I.apply(null,C):I.call(null),re.clearImmediate(z))}),z},re.clearImmediate="function"==typeof S?S:function(I){delete y[I]}}).call(this)}).call(this,V("timers").setImmediate,V("timers").clearImmediate)},{"process/browser.js":69,timers:74}],75:[function(V,X,re){"use strict";var T=V("punycode"),S=V("./util");function R(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}re.parse=oe,re.resolve=function le(H,N){return oe(H,!1,!0).resolve(N)},re.resolveObject=function Y(H,N){return H?oe(H,!1,!0).resolveObject(N):N},re.format=function de(H){return S.isString(H)&&(H=oe(H)),H instanceof R?H.format():R.prototype.format.call(H)},re.Url=R;var D=/^([a-z0-9.+-]+:)/i,m=/:[0-9]*$/,y=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,_=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),I=["'"].concat(_),z=["%","/","?",";","#"].concat(I),C=["/","?","#"],M=/^[+a-z0-9A-Z_-]{0,63}$/,O=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,F={javascript:!0,"javascript:":!0},B={javascript:!0,"javascript:":!0},Q={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},G=V("querystring");function oe(H,N,E){if(H&&S.isObject(H)&&H instanceof R)return H;var se=new R;return se.parse(H,N,E),se}R.prototype.parse=function(H,N,E){if(!S.isString(H))throw new TypeError("Parameter 'url' must be a string, not "+typeof H);var se=H.indexOf("?"),J=-1!==se&&se127?ye+="x":ye+=$[Re];if(!ye.match(M)){var g=xe.slice(0,_e),b=xe.slice(_e+1),q=$.match(O);q&&(g.push(q[1]),b.unshift(q[2])),b.length&&(ge="/"+b.join(".")+ge),this.hostname=g.join(".");break}}}this.hostname=this.hostname.length>255?"":this.hostname.toLowerCase(),be||(this.hostname=T.toASCII(this.hostname)),this.host=(this.hostname||"")+(this.port?":"+this.port:""),this.href+=this.host,be&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==ge[0]&&(ge="/"+ge))}if(!F[Ye])for(_e=0,ie=I.length;_e0)&&E.host.split("@"))&&(E.auth=ye.shift(),E.host=E.hostname=ye.shift())),E.search=H.search,E.query=H.query,(!S.isNull(E.pathname)||!S.isNull(E.search))&&(E.path=(E.pathname?E.pathname:"")+(E.search?E.search:"")),E.href=E.format(),E;if(!xe.length)return E.pathname=null,E.path=E.search?"/"+E.search:null,E.href=E.format(),E;for(var Re=xe.slice(-1)[0],W=(E.host||H.host||xe.length>1)&&("."===Re||".."===Re)||""===Re,g=0,b=xe.length;b>=0;b--)"."===(Re=xe[b])?xe.splice(b,1):".."===Re?(xe.splice(b,1),g++):g&&(xe.splice(b,1),g--);if(!ee&&!be)for(;g--;g)xe.unshift("..");ee&&""!==xe[0]&&(!xe[0]||"/"!==xe[0].charAt(0))&&xe.unshift(""),W&&"/"!==xe.join("/").substr(-1)&&xe.push("");var ye,q=""===xe[0]||xe[0]&&"/"===xe[0].charAt(0);return $&&(E.hostname=E.host=q?"":xe.length?xe.shift():"",(ye=!!(E.host&&E.host.indexOf("@")>0)&&E.host.split("@"))&&(E.auth=ye.shift(),E.host=E.hostname=ye.shift())),(ee=ee||E.host&&xe.length)&&!q&&xe.unshift(""),xe.length?E.pathname=xe.join("/"):(E.pathname=null,E.path=null),(!S.isNull(E.pathname)||!S.isNull(E.search))&&(E.path=(E.pathname?E.pathname:"")+(E.search?E.search:"")),E.auth=H.auth||E.auth,E.slashes=E.slashes||H.slashes,E.href=E.format(),E},R.prototype.parseHost=function(){var H=this.host,N=m.exec(H);N&&(":"!==(N=N[0])&&(this.port=N.substr(1)),H=H.substr(0,H.length-N.length)),H&&(this.hostname=H)}},{"./util":76,punycode:70,querystring:73}],76:[function(V,X,re){"use strict";X.exports={isString:function(T){return"string"==typeof T},isObject:function(T){return"object"==typeof T&&null!==T},isNull:function(T){return null===T},isNullOrUndefined:function(T){return null==T}}},{}]},{},[15])(15)},703:js=>{js.exports=function ps(){for(var ut={},Br=0;Br{js(js.s=736)}]); \ No newline at end of file From 0819bb5110c2849383f28d7d355db2f09ba09b93 Mon Sep 17 00:00:00 2001 From: Leonard Goodell Date: Wed, 17 May 2023 17:03:57 -0700 Subject: [PATCH 08/14] fix: Update README and fix InsecureSecrets Signed-off-by: Leonard Goodell --- .../custom/camera-management/README.md | 35 ++++++++++--------- .../camera-management/res/configuration.yaml | 4 +-- 2 files changed, 20 insertions(+), 19 deletions(-) diff --git a/application-services/custom/camera-management/README.md b/application-services/custom/camera-management/README.md index 9024581c..8c45f02e 100644 --- a/application-services/custom/camera-management/README.md +++ b/application-services/custom/camera-management/README.md @@ -83,9 +83,9 @@ sudo apt install build-essential ``` 3. Checkout the latest compatible release branch - > **Note**: The `levski` branch is the latest stable branch at the time of this writing. + > **Note**: The `minnesota` branch is the latest stable branch at the time of this writing. ```shell - git checkout levski + git checkout minnesota ``` 4. Navigate to the `compose-builder` subdirectory: @@ -157,32 +157,33 @@ make run-edge-video-analytics > **Note**: Please follow the instructions for the [Edgex Onvif Camera device service][device-onvif-manage] in order to connect your Onvif cameras to EdgeX. - Option 1: Modify the [res/configuration.toml](res/configuration.toml) file + Option 1: Modify the [res/configuration.yaml](res/configuration.yaml) file - ```toml - [Writable.InsecureSecrets.CameraCredentials] - path = "CameraCredentials" - [Writable.InsecureSecrets.CameraCredentials.Secrets] - username = "" - password = "" + ```yaml + InsecureSecrets: + CameraCredentials: + SecretName: CameraCredentials + SecretData: + username: "" + password: "" ``` Option 2: Export environment variable overrides ```shell - export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETS_USERNAME="" - export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETS_PASSWORD="" + export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETDATA_USERNAME="" + export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETDATA_PASSWORD="" ``` #### 3.2 Configure Default Pipeline Initially, all new cameras added to the system will start the default analytics pipeline as defined in the configuration file below. The desired pipeline can be changed afterward or the feature can be disabled by setting the `DefaultPipelineName` and `DefaultPipelineVersion` to empty strings. -Modify the [res/configuration.toml](res/configuration.toml) file with the name and version of the default pipeline to use when a new device is added to the system. +Modify the [res/configuration.yaml](res/configuration.yaml) file with the name and version of the default pipeline to use when a new device is added to the system. Note: These values can be left empty to disable the feature. - ```toml -[AppCustom] -DefaultPipelineName = "object_detection" # Name of the default pipeline used when a new device is added to the system -DefaultPipelineVersion = "person" # Version of the default pipeline used when a new device is added to the system + ```yaml + AppCustom: + DefaultPipelineName: object_detection # Name of the default pipeline used when a new device is added to the system; can be left blank to disable feature + DefaultPipelineVersion: person # Version of the default pipeline used when a new device is added to the system; can be left blank to disable feature ``` #### 3.3 Build and run @@ -316,7 +317,7 @@ Open your browser to [http://localhost:4200](http://localhost:4200) [edgex-compose]: https://github.com/edgexfoundry/edgex-compose [device-onvif-camera]: https://github.com/edgexfoundry/device-onvif-camera -[device-onvif-manage]: https://github.com/edgexfoundry/device-onvif-camera/blob/levski/doc/guides/SimpleStartupGuide.md#manage-devices +[device-onvif-manage]: https://docs.edgexfoundry.org/latest/microservices/device/supported/device-onvif-camera/Walkthrough/deployment/#manage-devices [device-usb-camera]: https://github.com/edgexfoundry/device-usb-camera [evam]: https://www.intel.com/content/www/us/en/developer/articles/technical/video-analytics-service.html [device-mqtt]: https://github.com/edgexfoundry/device-mqtt-go diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index b0c644e9..35e008d7 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -7,8 +7,8 @@ Writable: # for ALL cameras. In the future when then device-onvif-camera service is able to provide # us with pre-authenticated uris, this can be removed. CameraCredentials: - path: CameraCredentials - Secrets: + SecretName: CameraCredentials + SecretData: username: "" password: "" From bf3de7ab7b0dee8633c4930509cd127cdbf0733c Mon Sep 17 00:00:00 2001 From: Anthony Casagrande Date: Wed, 17 May 2023 17:44:38 -0700 Subject: [PATCH 09/14] fix: use new device-onvif-camera command names, and upgrade onvif lib Signed-off-by: Anthony Casagrande --- .../custom/camera-management/appcamera/commands.go | 12 ++++++------ application-services/custom/camera-management/go.mod | 2 +- application-services/custom/camera-management/go.sum | 6 +++--- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/application-services/custom/camera-management/appcamera/commands.go b/application-services/custom/camera-management/appcamera/commands.go index c523c6dc..e8a3ab07 100644 --- a/application-services/custom/camera-management/appcamera/commands.go +++ b/application-services/custom/camera-management/appcamera/commands.go @@ -19,13 +19,13 @@ import ( ) const ( - relativeMoveCommand = "RelativeMove" - gotoPresetCommand = "GotoPreset" + relativeMoveCommand = "PTZRelativeMove" + gotoPresetCommand = "PTZGotoPreset" streamUriCommand = "StreamUri" - profilesCommand = "Profiles" - getPresetsCommand = "GetPresets" + profilesCommand = "MediaProfiles" + getPresetsCommand = "PTZPresets" getCapabilitiesCommand = "Capabilities" - getConfigurationsCommand = "GetConfigurations" + getConfigurationsCommand = "PTZConfigurations" startStreamingCommand = "StartStreaming" stopStreamingCommand = "StopStreaming" usbStreamUriCommand = "StreamURI" @@ -102,7 +102,7 @@ func (app *CameraManagementApp) getCameraFeatures(deviceName string) (CameraFeat func (app *CameraManagementApp) getCapabilities(deviceName string) (device.GetCapabilitiesResponse, error) { cmd := &device.GetCapabilities{ - Category: onvif.CapabilityCategory("All"), + Category: []onvif.CapabilityCategory{onvif.CapabilityCategory("All")}, } resp := device.GetCapabilitiesResponse{} diff --git a/application-services/custom/camera-management/go.mod b/application-services/custom/camera-management/go.mod index dec2f46c..8b54224e 100644 --- a/application-services/custom/camera-management/go.mod +++ b/application-services/custom/camera-management/go.mod @@ -8,7 +8,7 @@ module github.com/edgexfoundry/edgex-examples/application-services/custom/camera go 1.18 require ( - github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897 + github.com/IOTechSystems/onvif v0.1.6 github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66 github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90 github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41 diff --git a/application-services/custom/camera-management/go.sum b/application-services/custom/camera-management/go.sum index e14ce026..86562972 100644 --- a/application-services/custom/camera-management/go.sum +++ b/application-services/custom/camera-management/go.sum @@ -1,6 +1,6 @@ github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897 h1:2ieBV/UtmRrnw9law65MO8ZkA/dbjxke2Cgo9/NoMoY= -github.com/IOTechSystems/onvif v0.0.2-0.20220301065030-7cf2dd734897/go.mod h1:vMGzqucCPsrADcnQ7oYah1HYr3h4zdoNVzcPmcyKy6o= +github.com/IOTechSystems/onvif v0.1.6 h1:K+Gez1rrx4qliKEyVtXxtyhDriIMNBYEQvoKNKwDV7E= +github.com/IOTechSystems/onvif v0.1.6/go.mod h1:fm6RkIlr9uWJVFLvbGPR7NpmFXDE+PwawSCkQse0Pp4= github.com/Microsoft/go-winio v0.6.0 h1:slsWYD/zyx7lCXoZVlvQrj0hPTM1HI4+v1sIda2yDvg= github.com/Microsoft/go-winio v0.6.0/go.mod h1:cTAf44im0RAYeL23bpB+fzCyDH2MJiz2BO69KH/soAE= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= @@ -23,6 +23,7 @@ github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QH github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= +github.com/clbanning/mxj/v2 v2.3.2/go.mod h1:hNiWqW14h+kc+MdF9C6/YoRfjEJoR3ou6tn/Qo+ve2s= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -77,7 +78,6 @@ github.com/go-playground/validator/v10 v10.13.0/go.mod h1:dwu7+CG8/CtBiJFZDz4e+5 github.com/go-redis/redis/v7 v7.3.0 h1:3oHqd0W7f/VLKBxeYTEpqdMUsmMectngjM9OtoRoIgg= github.com/go-redis/redis/v7 v7.3.0/go.mod h1:JDNMw23GTyLNC4GZu9njt15ctBQVn7xjRfnwdHj/Dcg= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= From 2f9cdfee28ad44039604a5673f6e65a0478708a4 Mon Sep 17 00:00:00 2001 From: preethi-satishcandra Date: Thu, 18 May 2023 16:29:36 -0700 Subject: [PATCH 10/14] fix: updated copyright for updated files Signed-off-by: preethi-satishcandra --- application-services/custom/camera-management/Makefile | 2 +- .../custom/camera-management/appcamera/credentials.go | 2 +- .../custom/camera-management/web-ui/dist/index.html | 4 ++-- .../web-ui/src/environments/environment.prod.ts | 2 +- .../camera-management/web-ui/src/environments/environment.ts | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/application-services/custom/camera-management/Makefile b/application-services/custom/camera-management/Makefile index 1a0592d8..76166774 100644 --- a/application-services/custom/camera-management/Makefile +++ b/application-services/custom/camera-management/Makefile @@ -1,4 +1,4 @@ -# Copyright (C) 2022 Intel Corporation +# Copyright (C) 2022-2023 Intel Corporation # SPDX-License-Identifier: Apache-2.0 .PHONY: build-app test clean docker tidy run-app run-tests diff --git a/application-services/custom/camera-management/appcamera/credentials.go b/application-services/custom/camera-management/appcamera/credentials.go index 296ebc5b..e88b60a0 100644 --- a/application-services/custom/camera-management/appcamera/credentials.go +++ b/application-services/custom/camera-management/appcamera/credentials.go @@ -1,5 +1,5 @@ // -// Copyright (C) 2022 Intel Corporation +// Copyright (C) 2022-2023 Intel Corporation // // SPDX-License-Identifier: Apache-2.0 diff --git a/application-services/custom/camera-management/web-ui/dist/index.html b/application-services/custom/camera-management/web-ui/dist/index.html index 6e141ed3..e31efc77 100644 --- a/application-services/custom/camera-management/web-ui/dist/index.html +++ b/application-services/custom/camera-management/web-ui/dist/index.html @@ -1,4 +1,4 @@ - Camera Management Web UI @@ -11,4 +11,4 @@ - \ No newline at end of file + diff --git a/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts b/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts index 7c53bd55..e4509d43 100644 --- a/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts +++ b/application-services/custom/camera-management/web-ui/src/environments/environment.prod.ts @@ -1,4 +1,4 @@ -// Copyright (C) 2022 Intel Corporation +// Copyright (C) 2022-2023 Intel Corporation // SPDX-License-Identifier: Apache-2.0 export const environment = { diff --git a/application-services/custom/camera-management/web-ui/src/environments/environment.ts b/application-services/custom/camera-management/web-ui/src/environments/environment.ts index b9a664e2..410a9f9e 100644 --- a/application-services/custom/camera-management/web-ui/src/environments/environment.ts +++ b/application-services/custom/camera-management/web-ui/src/environments/environment.ts @@ -1,4 +1,4 @@ -// Copyright (C) 2022 Intel Corporation +// Copyright (C) 2022-2023 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // This file can be replaced during build by using the `fileReplacements` array. From b4384191c253bc0138537964de3b816721ef39c6 Mon Sep 17 00:00:00 2001 From: Anthony Casagrande Date: Wed, 24 May 2023 11:44:42 -0700 Subject: [PATCH 11/14] feat: add support for rtspauth credentials Signed-off-by: Anthony Casagrande --- .../custom/camera-management/Makefile | 2 +- .../custom/camera-management/README.md | 27 +++++++++++++++++-- .../appcamera/credentials.go | 12 ++++----- .../camera-management/appcamera/evam.go | 12 ++++++--- .../camera-management/res/configuration.yaml | 9 ++++++- 5 files changed, 48 insertions(+), 14 deletions(-) diff --git a/application-services/custom/camera-management/Makefile b/application-services/custom/camera-management/Makefile index 76166774..a173751f 100644 --- a/application-services/custom/camera-management/Makefile +++ b/application-services/custom/camera-management/Makefile @@ -25,7 +25,7 @@ build-app: tidy tidy: go mod tidy -run-app: +run-app: build-app EDGEX_SECURITY_SECRET_STORE=false ./$(MICROSERVICE) -cp -d # TODO: Change the registries (edgexfoundry, nexus3.edgexfoundry.org:10004) below as needed. diff --git a/application-services/custom/camera-management/README.md b/application-services/custom/camera-management/README.md index 8c45f02e..85c9c5fb 100644 --- a/application-services/custom/camera-management/README.md +++ b/application-services/custom/camera-management/README.md @@ -174,7 +174,29 @@ make run-edge-video-analytics export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETDATA_PASSWORD="" ``` -#### 3.2 Configure Default Pipeline +#### 3.2 (Optional) Configure USB Camera RTSP Credentials. +> **Note**: This step is only required if you have USB cameras. + +> **Note**: Please follow the instructions for the [Edgex USB Camera device service][device-usb-manage] in order to connect your USB cameras to EdgeX. + +Option 1: Modify the [res/configuration.yaml](res/configuration.yaml) file + + ```yaml + InsecureSecrets: + rtspauth: + SecretName: rtspauth + SecretData: + username: "" + password: "" + ``` + +Option 2: Export environment variable overrides + ```shell + export WRITABLE_INSECURESECRETS_RTSPAUTH_SECRETDATA_USERNAME="" + export WRITABLE_INSECURESECRETS_RTSPAUTH_SECRETDATA_PASSWORD="" + ``` + +#### 3.3 Configure Default Pipeline Initially, all new cameras added to the system will start the default analytics pipeline as defined in the configuration file below. The desired pipeline can be changed afterward or the feature can be disabled by setting the `DefaultPipelineName` and `DefaultPipelineVersion` to empty strings. Modify the [res/configuration.yaml](res/configuration.yaml) file with the name and version of the default pipeline to use when a new device is added to the system. @@ -186,7 +208,7 @@ Note: These values can be left empty to disable the feature. DefaultPipelineVersion: person # Version of the default pipeline used when a new device is added to the system; can be left blank to disable feature ``` -#### 3.3 Build and run +#### 3.4 Build and run ```shell # First make sure you are at the root of this example app cd edgex-examples/application-services/custom/camera-management @@ -319,5 +341,6 @@ Open your browser to [http://localhost:4200](http://localhost:4200) [device-onvif-camera]: https://github.com/edgexfoundry/device-onvif-camera [device-onvif-manage]: https://docs.edgexfoundry.org/latest/microservices/device/supported/device-onvif-camera/Walkthrough/deployment/#manage-devices [device-usb-camera]: https://github.com/edgexfoundry/device-usb-camera +[device-usb-manage]: https://docs.edgexfoundry.org/latest/microservices/device/supported/device-usb-camera/Walkthrough/deployment/#manage-devices [evam]: https://www.intel.com/content/www/us/en/developer/articles/technical/video-analytics-service.html [device-mqtt]: https://github.com/edgexfoundry/device-mqtt-go diff --git a/application-services/custom/camera-management/appcamera/credentials.go b/application-services/custom/camera-management/appcamera/credentials.go index e88b60a0..0e6a04a9 100644 --- a/application-services/custom/camera-management/appcamera/credentials.go +++ b/application-services/custom/camera-management/appcamera/credentials.go @@ -6,25 +6,25 @@ package appcamera import ( + "github.com/edgexfoundry/go-mod-bootstrap/v3/bootstrap/secret" "github.com/edgexfoundry/go-mod-bootstrap/v3/config" "github.com/edgexfoundry/go-mod-core-contracts/v3/errors" ) const ( + rtspauth = "rtspauth" CameraCredentials = "CameraCredentials" - UsernameKey = "username" - PasswordKey = "password" ) // tryGetCredentials will attempt one time to get the camera credentials from the // secret provider and return them, otherwise return an error. -func (app *CameraManagementApp) tryGetCredentials() (config.Credentials, errors.EdgeX) { - secretData, err := app.service.SecretProvider().GetSecret(CameraCredentials, UsernameKey, PasswordKey) +func (app *CameraManagementApp) tryGetCredentials(secretName string) (config.Credentials, errors.EdgeX) { + secretData, err := app.service.SecretProvider().GetSecret(secretName, secret.UsernameKey, secret.PasswordKey) if err != nil { return config.Credentials{}, errors.NewCommonEdgeXWrapper(err) } return config.Credentials{ - Username: secretData[UsernameKey], - Password: secretData[PasswordKey], + Username: secretData[secret.UsernameKey], + Password: secretData[secret.PasswordKey], }, nil } diff --git a/application-services/custom/camera-management/appcamera/evam.go b/application-services/custom/camera-management/appcamera/evam.go index 3a61dff4..69e9ee14 100644 --- a/application-services/custom/camera-management/appcamera/evam.go +++ b/application-services/custom/camera-management/appcamera/evam.go @@ -111,15 +111,19 @@ func (app *CameraManagementApp) startPipeline(deviceName string, sr StartPipelin } app.lc.Infof("Received stream uri for the device %s: %s", deviceName, streamUri) + // set the secret name to be the onvif credentials by default + secretName := CameraCredentials // if device is usb camera, start streaming first if sr.USB != nil { _, err := app.startStreaming(deviceName, *sr.USB) if err != nil { return errors.Wrapf(err, "failed to start streaming usb camera %s", deviceName) } + // for usb cameras, use the rtspauth credentials instead + secretName = rtspauth } - body, err := app.createPipelineRequestBody(streamUri, deviceName) + body, err := app.createPipelineRequestBody(streamUri, deviceName, secretName) if err != nil { return errors.Wrapf(err, "failed to create DLStreamer pipeline request body") } @@ -173,14 +177,14 @@ func (app *CameraManagementApp) stopPipeline(deviceName string, id string) error return nil } -func (app *CameraManagementApp) createPipelineRequestBody(streamUri string, deviceName string) ([]byte, error) { +func (app *CameraManagementApp) createPipelineRequestBody(streamUri string, deviceName string, secretName string) ([]byte, error) { uri, err := url.Parse(streamUri) if err != nil { return nil, err } - if creds, err := app.tryGetCredentials(); err != nil { - app.lc.Warnf("Error retrieving %s secret from the SecretStore: %s", CameraCredentials, err.Error()) + if creds, err := app.tryGetCredentials(secretName); err != nil { + app.lc.Warnf("Error retrieving %s secret from the SecretStore: %s", secretName, err.Error()) } else { uri.User = url.UserPassword(creds.Username, creds.Password) } diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index 35e008d7..f0297dac 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -11,7 +11,14 @@ Writable: SecretData: username: "" password: "" - + + # TODO: Enter your device-usb-camera RTSP server credentials here. + rtspauth: + SecretName: rtspauth + SecretData: + username: "" + password: "" + Telemetry: Interval: 0s # Disables reporting of metrics From aef493523b8e462fa57122324128ead00c064479 Mon Sep 17 00:00:00 2001 From: preethi-satishcandra Date: Fri, 26 May 2023 09:24:18 -0700 Subject: [PATCH 12/14] build: update edgex go mods with v3 released versions Signed-off-by: preethi-satishcandra --- .../custom/camera-management/go.mod | 14 +++++----- .../custom/camera-management/go.sum | 28 +++++++++---------- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/application-services/custom/camera-management/go.mod b/application-services/custom/camera-management/go.mod index 8b54224e..0da9156c 100644 --- a/application-services/custom/camera-management/go.mod +++ b/application-services/custom/camera-management/go.mod @@ -9,9 +9,9 @@ go 1.18 require ( github.com/IOTechSystems/onvif v0.1.6 - github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66 - github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90 - github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41 + github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0 + github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.1 + github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0 github.com/gorilla/mux v1.8.0 github.com/pkg/errors v0.9.1 ) @@ -22,10 +22,10 @@ require ( github.com/cenkalti/backoff v2.2.1+incompatible // indirect github.com/diegoholiveira/jsonlogic/v3 v3.2.7 // indirect github.com/eclipse/paho.mqtt.golang v1.4.2 // indirect - github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10 // indirect - github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31 // indirect - github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7 // indirect - github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17 // indirect + github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0 // indirect + github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0 // indirect + github.com/edgexfoundry/go-mod-registry/v3 v3.0.0 // indirect + github.com/edgexfoundry/go-mod-secrets/v3 v3.0.1 // indirect github.com/fatih/color v1.9.0 // indirect github.com/fxamacker/cbor/v2 v2.4.0 // indirect github.com/go-jose/go-jose/v3 v3.0.0 // indirect diff --git a/application-services/custom/camera-management/go.sum b/application-services/custom/camera-management/go.sum index 86562972..88a1e2cc 100644 --- a/application-services/custom/camera-management/go.sum +++ b/application-services/custom/camera-management/go.sum @@ -31,20 +31,20 @@ github.com/diegoholiveira/jsonlogic/v3 v3.2.7 h1:awX07pFPnlntZzRNBcO4a2Ivxa77NMt github.com/diegoholiveira/jsonlogic/v3 v3.2.7/go.mod h1:9oE8z9G+0OMxOoLHF3fhek3KuqD5CBqM0B6XFL08MSg= github.com/eclipse/paho.mqtt.golang v1.4.2 h1:66wOzfUHSSI1zamx7jR6yMEI5EuHnT1G6rNA5PM12m4= github.com/eclipse/paho.mqtt.golang v1.4.2/go.mod h1:JGt0RsEwEX+Xa/agj90YJ9d9DH2b7upDZMK9HRbFvCA= -github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66 h1:xqQL93zxoBygh97qRYIFRx68dpoTJTr4CHExiCeNRrA= -github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0-dev.66/go.mod h1:F4Hv4/44tEFX/hGMWpm3wHc+XzpjhJwKKFbXAW8UK9k= -github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90 h1:fd/Y1DrgobWkvLbsbOyU5pQjvmpn9o5VEM6bbd8yP48= -github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.90/go.mod h1:/l9+zh+pthpA/wv/Y4ZROWfNLk5R3G27t/2yJHO2s/g= -github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10 h1:iDuAO3vpBQnlQuFhai/NATbJkiYXxo3bPCtSnFl07Yw= -github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.10/go.mod h1:8RlYm5CPzZgUsfXDWVP1TIeUMhsDNIdRdj1HXdomtOI= -github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41 h1:ZFrxABViVju6AAOkM8iergHTjLdqdycv9iOnKJV7r4s= -github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.41/go.mod h1:zzzWGWij6wAqm1go9TLs++TFMIsBqBb1eRnIj4mRxGw= -github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31 h1:jPOKcHYsHuQqVVqOIoIWXzq0BlyKTY9Zopos6cfDqFg= -github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.31/go.mod h1:I4kjdOG1nC2K8cIezv4lWWE8o4EO2emVQ9G5jRUDnEs= -github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7 h1:sje0agoLi8ayEFxGO3xtN7P/IXwjZUUxpC8G2fCTu44= -github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7/go.mod h1:SGyo4fAHzOhDAd2Usa9RaBT/sOzkbceIqLrDG0+iYy8= -github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17 h1:T6lFg0rNrf7XeYUyxFuO2CcYVAptr25FTZhxeRMWC/s= -github.com/edgexfoundry/go-mod-secrets/v3 v3.0.0-dev.17/go.mod h1:o36y/b6XaNaLN0QYAT42OGyI2gLcozjRuSQJh5Rlx/c= +github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0 h1:43xq9+zJpBvcBcVpP8pR4VwQN2YLfFfiW3XBW++cago= +github.com/edgexfoundry/app-functions-sdk-go/v3 v3.0.0/go.mod h1:sgH/44+BsOXtqFnot5bkbyJlJzISD9jiuudKxgnCgmg= +github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.1 h1:gXVxaZPcRJl2MhCIK/GOXZnQL+21xOUpGDTLTcVCxSk= +github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.1/go.mod h1:Or09TpF5HF3FjlqX3kJEFhBCsTvbHY0Nu28UF0MvB3w= +github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0 h1:rdk8KMcU8fA6o9MCb0O68bboxZTdLiXTZByNttEtRwE= +github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0/go.mod h1:8RlYm5CPzZgUsfXDWVP1TIeUMhsDNIdRdj1HXdomtOI= +github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0 h1:xjwCI34DLM31cSl1q9XmYgXS3JqXufQJMgohnLLLDx0= +github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0/go.mod h1:zzzWGWij6wAqm1go9TLs++TFMIsBqBb1eRnIj4mRxGw= +github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0 h1:nU37Uo4/kloTMrdqDN9SJuDoXb3FpHaMdwVbHtn9PPk= +github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0/go.mod h1:x2CueD9gn/CmtCvDNFgrgBnR+B1iWJMSrC5+gesfDJ0= +github.com/edgexfoundry/go-mod-registry/v3 v3.0.0 h1:6LXGElSScCCQzNpR3WjcgVz0RUc9GbfxETvif/4++iI= +github.com/edgexfoundry/go-mod-registry/v3 v3.0.0/go.mod h1:SGyo4fAHzOhDAd2Usa9RaBT/sOzkbceIqLrDG0+iYy8= +github.com/edgexfoundry/go-mod-secrets/v3 v3.0.1 h1:XyoDjeeVBMNwlJb6ljcTOl1QOp5gabcJc7pYSPYKNPA= +github.com/edgexfoundry/go-mod-secrets/v3 v3.0.1/go.mod h1:Ts9l+TknRKaqFsXmrTuKyV1Y5qIr+eiexVYkQuXnfxk= github.com/elgs/gostrgen v0.0.0-20161222160715-9d61ae07eeae/go.mod h1:wruC5r2gHdr/JIUs5Rr1V45YtsAzKXZxAnn/5rPC97g= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.9.0 h1:8xPHl4/q1VyqGIPif1F+1V3Y3lSmrq01EabUW3CoW5s= From a2fd7dce1f49ffa32afbf88876367a669d018826 Mon Sep 17 00:00:00 2001 From: preethi-satishcandra Date: Fri, 26 May 2023 14:59:16 -0700 Subject: [PATCH 13/14] fix: updated some configuration names Signed-off-by: preethi-satishcandra --- .../custom/camera-management/README.md | 12 +++++------ .../appcamera/credentials.go | 4 ++-- .../camera-management/appcamera/evam.go | 8 ++++---- .../camera-management/res/configuration.yaml | 20 ++++++++++--------- 4 files changed, 23 insertions(+), 21 deletions(-) diff --git a/application-services/custom/camera-management/README.md b/application-services/custom/camera-management/README.md index 85c9c5fb..82d435f7 100644 --- a/application-services/custom/camera-management/README.md +++ b/application-services/custom/camera-management/README.md @@ -161,8 +161,8 @@ make run-edge-video-analytics ```yaml InsecureSecrets: - CameraCredentials: - SecretName: CameraCredentials + onvifCredentials: + SecretName: onvifAuth SecretData: username: "" password: "" @@ -170,8 +170,8 @@ make run-edge-video-analytics Option 2: Export environment variable overrides ```shell - export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETDATA_USERNAME="" - export WRITABLE_INSECURESECRETS_CAMERACREDENTIALS_SECRETDATA_PASSWORD="" + export WRITABLE_INSECURESECRETS_ONVIFAUTH_SECRETDATA_USERNAME="" + export WRITABLE_INSECURESECRETS_ONVIFAUTH_SECRETDATA_PASSWORD="" ``` #### 3.2 (Optional) Configure USB Camera RTSP Credentials. @@ -183,8 +183,8 @@ Option 1: Modify the [res/configuration.yaml](res/configuration.yaml) file ```yaml InsecureSecrets: - rtspauth: - SecretName: rtspauth + usbCredentials: + SecretName: rtspAuth SecretData: username: "" password: "" diff --git a/application-services/custom/camera-management/appcamera/credentials.go b/application-services/custom/camera-management/appcamera/credentials.go index 0e6a04a9..2733a803 100644 --- a/application-services/custom/camera-management/appcamera/credentials.go +++ b/application-services/custom/camera-management/appcamera/credentials.go @@ -12,8 +12,8 @@ import ( ) const ( - rtspauth = "rtspauth" - CameraCredentials = "CameraCredentials" + rtspAuth = "rtspAuth" + onvifAuth = "onvifAuth" ) // tryGetCredentials will attempt one time to get the camera credentials from the diff --git a/application-services/custom/camera-management/appcamera/evam.go b/application-services/custom/camera-management/appcamera/evam.go index 69e9ee14..384101c3 100644 --- a/application-services/custom/camera-management/appcamera/evam.go +++ b/application-services/custom/camera-management/appcamera/evam.go @@ -111,16 +111,16 @@ func (app *CameraManagementApp) startPipeline(deviceName string, sr StartPipelin } app.lc.Infof("Received stream uri for the device %s: %s", deviceName, streamUri) - // set the secret name to be the onvif credentials by default - secretName := CameraCredentials + // set the secret name to be the onvif one by default + secretName := onvifAuth // if device is usb camera, start streaming first if sr.USB != nil { _, err := app.startStreaming(deviceName, *sr.USB) if err != nil { return errors.Wrapf(err, "failed to start streaming usb camera %s", deviceName) } - // for usb cameras, use the rtspauth credentials instead - secretName = rtspauth + // for usb cameras, use the rtspAuth instead + secretName = rtspAuth } body, err := app.createPipelineRequestBody(streamUri, deviceName, secretName) diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index f0297dac..5510f44a 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -2,22 +2,24 @@ Writable: LogLevel: INFO InsecureSecrets: - # TODO: Enter your camera's credentials here. + # TODO: Enter your device-onvif-camera credentials here. # NOTE: currently this solution is limited to supporting only 1 username/password combination # for ALL cameras. In the future when then device-onvif-camera service is able to provide # us with pre-authenticated uris, this can be removed. - CameraCredentials: - SecretName: CameraCredentials + onvifCredentials: + # Do not modify the SecretName, only add the username and password + SecretName: onvifAuth SecretData: - username: "" - password: "" + username: "admin007" + password: "admin007" # TODO: Enter your device-usb-camera RTSP server credentials here. - rtspauth: - SecretName: rtspauth + usbCredentials: + # Do not modify the SecretName, only add the username and password + SecretName: rtspAuth SecretData: - username: "" - password: "" + username: "admin007" + password: "admin007" Telemetry: Interval: 0s # Disables reporting of metrics From 3e3f2f95e0f35c2776a2105415c716df38181919 Mon Sep 17 00:00:00 2001 From: preethi-satishcandra Date: Fri, 26 May 2023 15:01:26 -0700 Subject: [PATCH 14/14] fix: removed some sample credentials Signed-off-by: preethi-satishcandra --- .../custom/camera-management/res/configuration.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/application-services/custom/camera-management/res/configuration.yaml b/application-services/custom/camera-management/res/configuration.yaml index 5510f44a..8f9dda70 100644 --- a/application-services/custom/camera-management/res/configuration.yaml +++ b/application-services/custom/camera-management/res/configuration.yaml @@ -10,16 +10,16 @@ Writable: # Do not modify the SecretName, only add the username and password SecretName: onvifAuth SecretData: - username: "admin007" - password: "admin007" + username: "" + password: "" # TODO: Enter your device-usb-camera RTSP server credentials here. usbCredentials: # Do not modify the SecretName, only add the username and password SecretName: rtspAuth SecretData: - username: "admin007" - password: "admin007" + username: "" + password: "" Telemetry: Interval: 0s # Disables reporting of metrics