@odigos/ui-kit 0.0.212 → 0.0.214
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/lib/chunks/index-CIjqAfew.js +3 -0
- package/lib/chunks/ui-components-Cu9XlyM0.js +2391 -0
- package/lib/components/_v2/badge/index.d.ts +2 -0
- package/lib/components/_v2/cards/section-card/index.d.ts +1 -0
- package/lib/components/_v2/checkbox/index.d.ts +5 -1
- package/lib/components/_v2/field-message/index.d.ts +1 -0
- package/lib/components/_v2/field-title/index.d.ts +2 -0
- package/lib/components/_v2/input/index.d.ts +4 -3
- package/lib/components/_v2/input-list/index.d.ts +5 -3
- package/lib/components/_v2/input-table/index.d.ts +5 -3
- package/lib/components/_v2/textarea/index.d.ts +4 -3
- package/lib/components/_v2/toggle/index.d.ts +5 -1
- package/lib/components/styled.d.ts +3 -6
- package/lib/components/tooltip/index.d.ts +1 -0
- package/lib/components/v2.js +1 -1
- package/lib/components.js +1 -1
- package/lib/constants.js +1 -1
- package/lib/containers/_v2/_drawers/add-rule-drawer/index.d.ts +1 -1
- package/lib/containers/_v2/_drawers/add-source-drawer/index.d.ts +1 -4
- package/lib/containers/_v2/_drawers/add-source-drawer/namespaces-column/index.d.ts +2 -1
- package/lib/containers/_v2/_drawers/add-source-drawer/types.d.ts +3 -0
- package/lib/containers/_v2/_drawers/add-source-drawer/workloads-column/index.d.ts +2 -1
- package/lib/containers/_v2/_forms/add-action-form/context.d.ts +18 -0
- package/lib/containers/_v2/_forms/add-action-form/index.d.ts +2 -6
- package/lib/containers/_v2/_forms/add-rule-form/context.d.ts +18 -0
- package/lib/containers/_v2/_forms/add-rule-form/index.d.ts +2 -6
- package/lib/containers/_v2/_forms/add-source-form/context.d.ts +21 -0
- package/lib/containers/_v2/_forms/add-source-form/index.d.ts +1 -0
- package/lib/containers/_v2/_forms/index.d.ts +1 -0
- package/lib/containers/service-map/helpers/build-map-nodes.d.ts +2 -0
- package/lib/containers/service-map/index.d.ts +1 -0
- package/lib/containers/v2.js +40 -40
- package/lib/containers.js +116 -116
- package/lib/contexts.js +1 -1
- package/lib/functions/deep-values/index.d.ts +2 -0
- package/lib/functions/get-virtual-service-icon/index.d.ts +2 -0
- package/lib/functions/index.d.ts +2 -0
- package/lib/functions.js +1 -1
- package/lib/hooks/useGenericForm.d.ts +2 -0
- package/lib/hooks.js +1 -1
- package/lib/icons/programming-languages/aws-logo/index.d.ts +2 -0
- package/lib/icons/programming-languages/index.d.ts +1 -0
- package/lib/icons.js +1 -1
- package/lib/snippets/_v2/wide-drawer/column-list-item/index.d.ts +1 -0
- package/lib/snippets/_v2/yaml-section-card/index.d.ts +1 -0
- package/lib/snippets/react-flow/flow.d.ts +1 -0
- package/lib/snippets.js +1 -1
- package/lib/store.js +1 -1
- package/lib/theme.js +1 -1
- package/lib/types/common/index.d.ts +307 -3
- package/lib/types/service-map/index.d.ts +5 -0
- package/lib/types.js +1 -1
- package/lib/visuals.js +1 -1
- package/package.json +10 -10
- package/lib/chunks/index-CTFaJvLO.js +0 -3
- package/lib/chunks/ui-components-DQ5eBxQh.js +0 -2387
- package/lib/containers/_v2/_drawers/add-action-drawer/helpers.d.ts +0 -7
- package/lib/containers/_v2/_drawers/add-rule-drawer/helpers.d.ts +0 -7
|
@@ -0,0 +1,2391 @@
|
|
|
1
|
+
import{SamplerIcon as e,PiiMaskingIcon as t,ActionIcon as o,RenameAttributeIcon as r,DeleteAttributeIcon as i,AddClusterInfoIcon as n,K8sLogo as a,ImageErrorIcon as s,KafkaLogo as l,RedisLogo as c,PostgresLogo as d,NginxLogo as p,MysqlLogo as u,ElixirLogo as h,SwiftLogo as m,RustLogo as g,RubyLogo as f,PhpLogo as x,CPlusPlusLogo as y,CSharpLogo as b,DotnetLogo as $,PythonLogo as v,NodejsLogo as w,GoLogo as S,JavaLogo as C,AwsXrayLogo as k,VictoriaMetricsLogo as E,UptraceLogo as A,TraceloopLogo as D,TingyunLogo as T,TempoLogo as N,TelemetryHubLogo as I,SumoLogicLogo as _,SplunkLogo as O,SignozLogo as R,SeqLogo as F,AwsS3Logo as z,QuickwitLogo as L,GigapipeLogo as P,QrynLogo as M,PrometheusLogo as B,OpenTelemetryLogo as U,OracleLogo as j,OpsVerseLogo as W,OpenObserveLogo as G,OneUptimeLogo as V,OdigosLogo as X,ObserveLogo as H,NewRelicLogo as J,MiddlewareLogo as K,LumigoLogo as q,LokiLogo as Y,LogzioLogo as Q,LightstepLogo as Z,Last9Logo as ee,KloudmateLogo as te,JaegerLogo as oe,InstanaLogo as re,HyperDxLogo as ie,HoneycombLogo as ne,GroundcoverLogo as ae,GreptimeLogo as se,GrafanaLogo as le,GoogleCloudPlatformLogo as ce,ElasticSearchLogo as de,ElasticApmLogo as pe,DynatraceLogo as ue,DatadogLogo as he,Dash0Logo as me,CoralogixLogo as ge,AwsCloudwatchLogo as fe,ClickhouseLogo as xe,ChronosphereLogo as ye,ChecklyLogo as be,CauselyLogo as $e,BonreeLogo as ve,BetterStackLogo as we,AzureMonitorLogo as Se,AzureBlobLogo as Ce,AxiomLogo as ke,AppDynamicsLogo as Ee,AlibabaCloudLogo as Ae,AlaudaLogo as De,InstrumentationRuleIcon as Te,DestinationIcon as Ne,SourceIcon as Ie,NamespacesIcon as _e,PayloadCollectionIcon as Oe,HeadersCollectionIcon as Re,CustomInstrumentationIcon as Fe,CodeAttributesIcon as ze,TracesIcon as Le,MetricsIcon as Pe,LogsIcon as Me,VmLogo as Be,QuestionCircleIcon as Ue,XSquareIcon as je,VSquareIcon as We,ExclamationTriangleIcon as Ge,ExclamationCircleIcon as Ve,ISquareIcon as Xe,AwsLogo as He,VIcon as Je,CopyIcon as Ke,XIcon as qe,MinusIcon as Ye,ListIcon as Qe,CodeIcon as Ze,ExtendArrowIcon as et,PlusIcon as tt,EditIcon as ot,NoDataIcon as rt,RefreshIcon as it,EyeClosedIcon as nt,EyeOpenIcon as at,SearchIcon as st,TrashIcon as lt,EditedIcon as ct,SortArrowsIcon as dt,NotebookIcon as pt,ArrowIcon as ut,ChevronUpIcon as ht,ChevronDownIcon as mt,DotsVerticalIcon as gt,DotsHorizontalIcon as ft,DotIcon as xt,FilterIcon as yt}from"../icons.js";import{create as bt}from"zustand";import{jsx as $t,jsxs as vt,Fragment as wt}from"react/jsx-runtime";import{Fragment as St,useMemo as Ct,useState as kt,useEffect as Et,useRef as At,useCallback as Dt,useContext as Tt,createContext as Nt,forwardRef as It,memo as _t}from"react";import Ot from"javascript-time-ago";import{p as Rt,c as Ft,s as zt,l as Lt}from"./vendor-C150cdxb.js";import Pt,{css as Mt,useTheme as Bt,ThemeProvider as Ut,keyframes as jt}from"styled-components";import{Handle as Wt,Position as Gt,ReactFlowProvider as Vt,ReactFlow as Xt,Controls as Ht,ControlButton as Jt,useReactFlow as Kt}from"@xyflow/react";import qt,{createPortal as Yt}from"react-dom";import{Highlight as Qt,themes as Zt}from"prism-react-renderer";import{ErrorBoundary as eo}from"react-error-boundary";import to from"lottie-react";import{VList as oo}from"virtua";const ro=e=>e.charAt(0).toUpperCase()+e.slice(1),io=e=>{const t=e=>e.filter(e=>"object"==typeof e&&null!==e?""!==e.key&&""!==e.value:""!==e),o=e=>Object.fromEntries(Object.entries(e).filter(([e,t])=>""!==e&&""!==t).map(([e,r])=>Array.isArray(r)?[e,t(r)]:"object"==typeof r&&null!==r?[e,o(r)]:[e,r]));return Object.entries(e).reduce((e,[r,i])=>{try{const n=JSON.parse(i);Array.isArray(n)?e[r]=JSON.stringify(t(n)):e[r]="object"==typeof n&&null!==n?JSON.stringify(o(n)):i}catch(n){"object"==typeof i&&null!==i?Array.isArray(i)?e[r]=JSON.stringify(t(i)):e[r]=JSON.stringify(o(i)):e[r]=i}return e},{})};var no;!function(e){e.SIGNALS="SIGNALS"}(no||(no={}));const ao=(e,t,o)=>{if(!e||!e.length)return!0;if(1===e.length)return"true"==e[0];const[r,i,n]=e;if(r===no.SIGNALS)switch(i){case"INCLUDES":return t?.includes(n);case"EXCLUDES":return!t?.includes(n);default:return!0}const a=o.find(e=>e.name===r||e.key===r);if(!a)return!1;switch(i){case"===":case"==":return a.value===n;case"!==":case"!=":return a.value!==n;case">":return Number(a.value)>Number(n);case"<":return Number(a.value)<Number(n);case">=":return Number(a.value)>=Number(n);case"<=":return Number(a.value)<=Number(n);default:return!0}},so=e=>JSON.parse(JSON.stringify(e)),lo=(e,t)=>t.split(".").reduce((e,t)=>e?.[t],e),co=(e,t,o)=>{const r=t.split(".");let i=e;for(let e=0;e<r.length-1;e++)r[e]in i&&"object"==typeof i[r[e]]||(i[r[e]]={}),i=i[r[e]];i[r[r.length-1]]=o},po=(e,t)=>{let o=[...e];return t.monitors?.length&&(o=o.filter(e=>!!t.monitors?.find(t=>e.signals?.find(e=>e.toLowerCase()===t.id)))),o},uo=(e,t)=>{let o=[...e];return t.monitors?.length&&(o=o.filter(e=>!!t.monitors?.find(t=>e.exportedSignals[t.id]))),o},ho=(e,t)=>t?e.filter(e=>e.dataStreamNames.includes(t)||!e.dataStreamNames.length):[];var mo,go,fo,xo,yo,bo,$o,vo,wo,So,Co,ko,Eo,Ao,Do,To,No,Io,_o,Oo,Ro,Fo,zo,Lo,Po,Mo,Bo,Uo,jo,Wo,Go,Vo,Xo,Ho,Jo,Ko,qo,Yo,Qo,Zo,er,tr;!function(e){e.Attributes="attributes",e.Samplers="samplers"}(mo||(mo={})),function(e){e.K8sAttributes="K8sAttributesResolver",e.AddClusterInfo="AddClusterInfo",e.DeleteAttributes="DeleteAttribute",e.RenameAttributes="RenameAttribute",e.PiiMasking="PiiMasking",e.ErrorSampler="ErrorSampler",e.ProbabilisticSampler="ProbabilisticSampler",e.LatencySampler="LatencySampler",e.ServiceNameSampler="ServiceNameSampler",e.SpanAttributeSampler="SpanAttributeSampler",e.URLTemplatization="URLTemplatization"}(go||(go={})),function(e){e.CollectContainerAttributes="collectContainerAttributes",e.CollectReplicaSetAttributes="collectReplicaSetAttributes",e.CollectWorkloadId="collectWorkloadId",e.CollectClusterId="collectClusterId",e.LabelsAttributes="labelsAttributes",e.AnnotationsAttributes="annotationsAttributes",e.ClusterAttributes="clusterAttributes",e.OverwriteExistingValues="overwriteExistingValues",e.AttributeNamesToDelete="attributeNamesToDelete",e.Renames="renames",e.PiiCategories="piiCategories",e.FallbackSamplingRatio="fallbackSamplingRatio",e.SamplingPercentage="samplingPercentage",e.EndpointsFilters="endpointsFilters",e.ServicesNameFilters="servicesNameFilters",e.AttributeFilters="attributeFilters",e.UrlTemplatizationRulesGroups="urlTemplatizationRulesGroups"}(fo||(fo={})),function(e){e.Pod="pod",e.Namespace="namespace",e.Node="node"}(xo||(xo={})),function(e){e.EXISTS="exists",e.EQUALS="equals",e.NOT_EQUALS="not_equals",e.CONTAINS="contains",e.NOT_CONTAINS="not_contains",e.REGEX="regex"}(yo||(yo={})),function(e){e.EXISTS="exists",e.EQUALS="equals",e.NOT_EQUALS="not_equals",e.GREATER_THAN="greater_than",e.LESS_THAN="less_than",e.GREATER_THAN_OR_EQUAL="greater_than_or_equal",e.LESS_THAN_OR_EQUAL="less_than_or_equal"}(bo||(bo={})),function(e){e.EXISTS="exists",e.EQUALS="equals"}($o||($o={})),function(e){e.EXISTS="exists",e.EQUALS="equals",e.NOT_EQUALS="not_equals",e.IS_VALID_JSON="is_valid_json",e.IS_INVALID_JSON="is_invalid_json",e.JSONPATH_EXISTS="jsonpath_exists",e.KEY_EQUALS="key_equals",e.KEY_NOT_EQUALS="key_not_equals"}(vo||(vo={})),function(e){e.Horizontal="horizontal",e.Vertical="vertical"}(wo||(wo={})),function(e){e.Ascending="ascending",e.Descending="descending"}(So||(So={})),function(e){e.Community="community",e.Cloud="cloud",e.Onprem="onprem"}(Co||(Co={})),function(e){e.K8s="k8s",e.Vm="vm"}(ko||(ko={})),function(e){e.Cli="odigos-cli",e.Helm="helm",e.Operator="odigos-operator"}(Eo||(Eo={})),function(e){e.Go="go",e.JavaScript="javascript",e.Python="python",e.Java="java",e.DotNet="dotnet",e.CSharp="csharp",e.CPlusPlus="cplusplus",e.Php="php",e.Ruby="ruby",e.Rust="rust",e.Swift="swift",e.Elixir="elixir",e.MySql="mysql",e.Nginx="nginx",e.Postgres="postgres",e.Redis="redis",e.Kafka="kafka",e.Ignored="ignored",e.Unknown="unknown",e.Processing="processing",e.NoContainers="no containers",e.NoRunningPods="no running pods"}(Ao||(Ao={})),function(e){e.Create="Create",e.Read="Read",e.Update="Update",e.Delete="Delete"}(Do||(Do={})),function(e){e.Namespace="Namespace",e.Source="Source",e.Destination="Destination",e.Action="Action",e.InstrumentationRule="InstrumentationRule"}(To||(To={})),function(e){e.DataStream="DataStream"}(No||(No={})),function(e){e.Input="input",e.MultiInput="multiInput",e.MultiTabledInput="multiTabledInput",e.KeyValuePair="keyValuePairs",e.TextArea="textarea",e.Dropdown="dropdown",e.Checkbox="checkbox",e.Toggle="toggle"}(Io||(Io={})),function(e){e.Text="text",e.Password="password",e.Number="number"}(_o||(_o={})),function(e){e.Warning="warning",e.Error="error",e.Success="success",e.Info="info",e.Default="default"}(Oo||(Oo={})),function(e){e.INSTRUMENTED="Instrumented",e.INSTRUMENTING="Instrumenting",e.UNINSTRUMENTED="Uninstrumented",e.NOT_INSTRUMENTED="Not Instrumented"}(Ro||(Ro={})),function(e){e.Loading="loading",e.Disabled="disabled"}(Fo||(Fo={})),function(e){e.Disabled="disabled",e.Unknown="unknown"}(zo||(zo={})),function(e){e.CodeAttributes="code-attributes",e.FullPayloadCollection="full-payload-collection",e.DbPayloadCollection="db-payload-collection",e.QueryOperationDetector="query-operation-detector",e.AllowConcurrentAgents="allow_concurrent_agents",e.JavaEbpfInstrumentations="java-ebpf-instrumentations",e.JavaNativeInstrumentations="java-native-instrumentations",e.SizeS="size_s",e.SizeM="size_m",e.SizeL="size_l"}(Lo||(Lo={})),function(e){e.Header="header",e.Add="add",e.Base="base",e.Edged="edged",e.Frame="frame",e.Scroll="scroll",e.Skeleton="skeleton",e.MapItem="map-item",e.NoData="no-data",e.OdiLogo="odilogo"}(Po||(Po={})),function(e){e.Labeled="labeled"}(Mo||(Mo={})),function(e){e.AddRule="addRule",e.AddSource="addSource",e.AddAction="addAction",e.AddDestination="addDestination"}(Bo||(Bo={})),function(e){e.Alauda="alauda",e.AlibabaCloud="alibabacloud",e.AppDynamics="appdynamics",e.Axiom="axiom",e.AzureBlob="azureblob",e.AzureMonitor="azuremonitor",e.BetterStack="betterstack",e.Bonree="bonree",e.Causely="causely",e.Checkly="checkly",e.Chronosphere="chronosphere",e.ClickHouse="clickhouse",e.CloudWatch="cloudwatch",e.Coralogix="coralogix",e.Dash0="dash0",e.Datadog="datadog",e.Dynamic="dynamic",e.Dynatrace="dynatrace",e.ElasticApm="elasticapm",e.ElasticSearch="elasticsearch",e.GoogleCloud="googlecloud",e.GoogleCloudOTLP="googlecloudotlp",e.GrafanaCloudLoki="grafanacloudloki",e.GrafanaCloudPrometheus="grafanacloudprometheus",e.GrafanaCloudTempo="grafanacloudtempo",e.Greptime="greptime",e.Groundcover="groundcover",e.Honeycomb="honeycomb",e.HyperDX="hyperdx",e.Instana="instana",e.Jaeger="jaeger",e.Kafka="kafka",e.Kloudmate="kloudmate",e.Last9="last9",e.Lightstep="lightstep",e.LogzIo="logzio",e.Loki="loki",e.Lumigo="lumigo",e.Middleware="middleware",e.NewRelic="newrelic",e.Observe="observe",e.Odigos="odigos",e.OneUptime="oneuptime",e.OpenObserve="openobserve",e.Opsverse="opsverse",e.Oracle="oracle",e.OTLP="otlp",e.OTLPHttp="otlphttp",e.Prometheus="prometheus",e.Qryn="qryn",e.QrynOss="qryn-oss",e.Quickwit="quickwit",e.S3="s3",e.Seq="seq",e.Signalfx="signalfx",e.Signoz="signoz",e.Splunk="splunk",e.SplunkSapm="splunksapm",e.SplunkOtlp="splunkotlp",e.SumoLogic="sumologic",e.TelemetryHub="telemetryhub",e.Tempo="tempo",e.Tingyun="tingyun",e.Traceloop="traceloop",e.Uptrace="uptrace",e.VictoriaMetrics="victoriametrics",e.VictoriaMetricsCloud="victoriametricscloud",e.XRay="xray"}(Uo||(Uo={})),function(e){e.Deployment="Deployment",e.DaemonSet="DaemonSet",e.StatefulSet="StatefulSet",e.CronJob="CronJob",e.Pod="Pod",e.StaticPod="StaticPod",e.Rollout="Rollout",e.ConfigMap="ConfigMap",e.DeploymentConfig="DeploymentConfig"}(jo||(jo={})),function(e){e.GolangCommunity="golang-community",e.NodejsCommunity="nodejs-community",e.PythonCommunity="python-community",e.JavaCommunity="java-community",e.DotNetCommunity="dotnet-community",e.RubyCommunity="ruby-community",e.PhpCommunity="php-community",e.GolangEnterprise="golang-enterprise",e.NodejsEnterprise="nodejs-enterprise",e.PythonEnterprise="python-enterprise",e.JavaEnterprise="java-enterprise",e.JavaEbpfInstrumentations="java-ebpf-instrumentations",e.DotNetLegacy="dotnet-legacy",e.DotNetEnterprise="dotnet-enterprise",e.RubyEnterprise="ruby-enterprise",e.CPlusPlusEnterprise="cplusplus-enterprise",e.MySqlEnterprise="mysql-enterprise"}(Wo||(Wo={})),function(e){e.Error="Error",e.Failure="Failure",e.Notice="Notice",e.Pending="Pending",e.Waiting="Waiting",e.Unsupported="Unsupported",e.Disabled="Disabled",e.Success="Success",e.Irrelevant="Irrelevant",e.Unknown="Unknown"}(Go||(Go={})),function(e){e.CodeAttributes="CodeAttributes",e.HeadersCollection="HeadersCollection",e.PayloadCollection="PayloadCollection",e.CustomInstrumentation="CustomInstrumentation",e.UnknownType="UnknownType"}(Vo||(Vo={})),function(e){e.Column="column",e.FilePath="filePath",e.Function="function",e.LineNumber="lineNumber",e.Namespace="namespace",e.StackTrace="stacktrace"}(Xo||(Xo={})),function(e){e.HeaderKeys="headerKeys"}(Ho||(Ho={})),function(e){e.Java="java",e.Golang="golang"}(Jo||(Jo={}));class or{className;methodName;constructor(e,t){this.className=e,this.methodName=t}Verify(){return!!this.className&&!!this.methodName}toString(){return this.Verify()?`${this.className}.${this.methodName}`:"[Faulty Java Probe]"}}class rr{packageName;functionName;receiverName;receiverMethodName;constructor(e,t,o,r){this.packageName=e,this.functionName=t||"",this.receiverName=o||"",this.receiverMethodName=r||""}Verify(){return!!this.packageName&&(this.functionName?!(this.receiverMethodName||this.receiverName):!(!this.receiverMethodName||!this.receiverName))}toString(){return this.Verify()?this.functionName?`${this.packageName}.${this.functionName}`:this.receiverName&&this.receiverMethodName?`${this.packageName}.(${this.receiverName}).${this.receiverMethodName}`:"":"[Faulty Golang Probe]"}}!function(e){e.HttpRequest="httpRequest",e.HttpResponse="httpResponse",e.DbQuery="dbQuery",e.Messaging="messaging"}(Ko||(Ko={})),function(e){e.Healthy="Healthy",e.Updating="Updating",e.Degraded="Degraded",e.Failed="Failed",e.Down="Down",e.Unknown="Unknown"}(qo||(qo={})),function(e){e.Pending="Pending",e.Running="Running",e.Succeeded="Succeeded",e.Failed="Failed",e.Unknown="Unknown"}(Yo||(Yo={})),function(e){e.ContainerCreating="ContainerCreating",e.CrashLoopBackOff="CrashLoopBackOff",e.CreateContainerError="CreateContainerError",e.CreateContainerConfigError="CreateContainerConfigError",e.ErrImagePull="ErrImagePull",e.ErrImageNeverPull="ErrImageNeverPull",e.ImagePullBackOff="ImagePullBackOff",e.InvalidImageName="InvalidImageName",e.RegistryUnavailable="RegistryUnavailable",e.NetworkNotReady="NetworkNotReady",e.Running="Running",e.Completed="Completed",e.Error="Error",e.OOMKilled="OOMKilled",e.ContainerCannotRun="ContainerCannotRun",e.DeadlineExceeded="DeadlineExceeded",e.StartError="StartError"}(Qo||(Qo={})),function(e){e.Running="Running",e.Waiting="Waiting",e.Terminated="Terminated"}(Zo||(Zo={})),function(e){e.Logs="LOGS",e.Metrics="METRICS",e.Traces="TRACES"}(er||(er={})),function(e){e.Logs="logs",e.Metrics="metrics",e.Traces="traces"}(tr||(tr={}));const ir={[er.Logs]:tr.Logs,[er.Metrics]:tr.Metrics,[er.Traces]:tr.Traces},nr={[tr.Logs]:er.Logs,[tr.Metrics]:er.Metrics,[tr.Traces]:er.Traces},ar=(e,t)=>{let o=[...e];return t.namespaces?.length&&(o=o.filter(({namespace:e})=>!!t.namespaces?.find(({id:t})=>t===e))),t.kinds?.length&&(o=o.filter(({kind:e})=>!!t.kinds?.find(({id:t})=>t===e))),t.languages?.length&&(o=o.filter(({containers:e})=>!!t.languages?.find(({id:t})=>!!e?.find(({language:e})=>t===e)))),t.conditions?.length&&(o=o.filter(({conditions:e})=>!!t.conditions?.find(({id:t})=>!!e?.find(({type:e,reason:o})=>t===`${e}#${o}`)))),t.podsAgentInjectionStatus?.length&&(o=o.filter(({podsAgentInjectionStatus:e})=>!!t.podsAgentInjectionStatus?.find(({id:t})=>t===e?.reasonEnum||t===e?.message))),t.onlyErrors&&(o=o.filter(e=>!!e.conditions?.find(e=>e.status===Oo.Error))),t.errors?.length&&(o=o.filter(e=>!!t.errors?.find(t=>!!e.conditions?.find(e=>e.message===t.id)))),o},sr="https://docs.odigos.io",lr="default",cr="this-cluster",dr="This Cluster",pr={SELECTED_DATA_STREAM:"SELECTED_DATA_STREAM",SELECTED_DATA_STREAM_WITH_PROXY:e=>`SELECTED_DATA_STREAM_${e}`,OVERVIEW_FILTERS:"OVERVIEW_FILTERS",DARK_MODE:"DARK_MODE"},ur={REQUIRED_FIELDS:"Required fields are missing",FIELD_IS_REQUIRED:"This field is required",FORBIDDEN:"Forbidden",ENTERPRISE_ONLY:(e="This")=>`${e} is an Enterprise feature. Please upgrade your plan.`,DEFINED_FOR_ALL_STREAMS:e=>`${e} are defined for all Data Streams.`,CANNOT_EDIT_RULE:"Cannot edit a system-managed instrumentation rule",CANNOT_DELETE_RULE:"Cannot delete a system-managed instrumentation rule",LATENCY_HTTP_ROUTE:'HTTP route must start with a forward slash "/"',READONLY_WARNING:"You're not allowed to create/update/delete in readonly mode",ILLEGAL_K8S_LABEL:'Must be 63 characters or less, must consist of alphanumeric characters, "-", "_", or ".", and must start & end with an alphanumeric character (e.g., my-name, 123.abc).',INVALID_VERSION:'Invalid version format, must be in the format of "major.minor.patch" (e.g. 1.0.0)'},hr={NAMESPACE:"Namespace",NAME:"Name",KIND:"Kind",CONNECTION:"Connection",CONNECTIONS:"Connections",DATA_STREAM:"Data Stream",DATA_STREAMS:"Data Streams",STREAM_NAME:"Data Stream Name",NAME_YOUR_STREAM:"Name your Data Stream",NAME_YOUR_STREAM_PLACEHOLDER:"e.g. Highest priority",STREAM_DESCRIPTION:"Provide a clear and descriptive name for your pipeline to ensure its purpose is easily understood by you and your team.",STREAM_CONFIRM:"Confirm your new Data Stream",DATA_STREAM_EXISTS_WARNING:(e,t)=>`A Data Stream with this name already exists, you can still rename the current "${e}", but it will merge into the existing "${t}".`,ACTION:"Action",ACTIONS:"Actions",ADD_ACTION:"Add Action",ACTION_DETAILS:"Action Details",INSTRUMENTATION_RULE:"Instrumentation Rule",INSTRUMENTATION_RULES:"Instrumentation Rules",ADD_INSTRUMENTATION_RULE:"Add Instrumentation Rule",INSTRUMENTATION_RULE_DETAILS:"Instrumentation Rule Details",DESTINATION:"Destination",DESTINATIONS:"Destinations",ADD_DESTINATION:"Add Destination",ADD_DESTINATIONS:"Add Destinations",ADD_DESTINATION_DESCRIPTION:"Add a destination to send your telemetry data to. You can add multiple destinations.",DESTINATION_DETAILS:"Destination Details",SELECTED_DESTINATIONS:"Selected Destinations",SOURCE:"Source",SOURCES:"Sources",ADD_SOURCE:"Add Source",SOURCE_DETAILS:"Source Details",SELECT_SOURCES:"Select Sources",SELECTED_SOURCES:"Selected Sources",SELECT_SOURCES_DESCRIPTION:"Choose which sources to monitor in your pipeline.",NO_SOURCES:"No sources",NO_SOURCES_GO_BACK:"No sources selected. Please go back to select sources.",PLEASE_ADD_SOURCE:"Please add a source",NO_SOURCES_NAMESPACE:"No sources available in this namespace",TRY_SEARCH_OR_OTHER_NAMESPACE:"Try searching again or select another namespace.",PLEASE_MAKE_SURE_UNIGNORED_NAMESPACES:"Please make sure your cluster has unignored namespaces",INSTALLATION:"Installation",SOURCES_SETUP:"Sources setup",DESTINATIONS_SETUP:"Destinations setup",SUMMARY:"Summary",REVIEW_SETUP:"Review your setup and confirm your choices.",NO_SOURCES_SELECTED:"No sources selected",ADD_SOURCE_PROMPT:"Add at least one source to start collecting data",NO_DESTINATIONS_SELECTED:"No destinations selected",ADD_DESTINATION_PROMPT:"Add destination so your data has somewhere to go",GET_STARTED_WITH:"Get started with",GET_STARTED_DESCRIPTION:"First, select the sources you want Odigos to monitor. Next, choose where your data should be sent by configuring destinations.",TYPE:"Type",NOTES:"Notes",STATUS:"Status",READONLY:"Readonly",LANGUAGE:"Language",VERSION:"Version",RUNTIME_VERSION:"Runtime Version",VERSION_PLACEHOLDER:"1.0.0",MONITORS:"Monitors",SIGNALS_FOR_PROCESSING:"Signals for Processing",MANAGED_BY_PROFILE:"Managed by Profile",TIER:"Tier",ENTERPRISE:"Enterprise",ENTERPRISE_TIER:"Enterprise Tier",COMMUNITY:"Community",COMMUNITY_TIER:"Community Tier",API_TOKEN:"API Token",API_TOKENS:"API Tokens",DESCRIBE_ODIGOS:"Describe Odigos",DESCRIBE_SOURCE:"Describe Source",DETECTED_CONTAINERS:"Detected Containers",DETECTED_CONTAINERS_DESCRIPTION:"The system automatically instruments the containers it detects with a supported programming language.",DETECTED_PROCESSES:"Detected Processes",DETECTED_PROCESSES_DESCRIPTION:"The system automatically instruments the processes it detects with a supported programming language.",CONTAINER_NAME:"Container Name",FILTERED_COUNT_TOOLTIP:"Represents filtered amount, out of total amount",SEARCH_NAMESPACES:"Search Namespaces",SEARCH_SOURCES:"Search Sources",SELECT_ALL:"Select All",ONLY_SELECTED:"Only selected",ONLY_RUNNING_INSTANCES:"Only running instances",TO_COLLECT_OTEL_DATA:"To collect OpenTelemetry data",TO_MONITOR_OTEL_DATA:"To monitor OpenTelemetry data",TO_MODIFY_OTEL_DATA:"To modify OpenTelemetry data",QUICK_BACK_TO_SUMMARY:"When you finish editing you can quickly go back to the summary.",GO_TO_SUMMARY:"Go to summary",FUTURE_APPS_TITLE:"Instrument entire namespace",FUTURE_APPS_DESCRIPTION:"When enabled, all applications in the namespace and new applications will be instrumented automatically and included in the current data stream using a Namespace Source.",OVERIDE:"Override",OVERIDDEN:"Overridden",OVERRIDE_RUNTIME_DETAILS:"Override Runtime Details",OVERRIDE_RUNTIME_WARNING:"This is an advanced configuration. If the selected programming language is incorrect, data collection may be incomplete or may not occur at all.",ACTIVE:"Active",INACTIVE:"Inactive",ENABLED:"Enabled",DISABLED:"Disabled",NO_TRACES_FOUND:"No traces found",ARE_SERVICES_INSTRUMENTED_AND_PRODUCING_TRAFFIC:"Are your services instrumented & producing traffic?",JAVA_CUSTOM_PROBES:"Java Custom Probes",GOLANG_CUSTOM_PROBES:"Golang Custom Probes",ROLLBACK_OCCURRED_MESSAGE:"Odigos detected a crash and rolled back instrumentation to protect your workload.",ROLLBACK_RECOVER:"Recover",FETCHING_NAMESPACES:"Fetching namespaces",FETCHING_NAMESPACES_SUBTITLE:"Please wait while we fetch the namespaces",ADD_SOURCES_DESCRIPTION:"Choose which sources to monitor in your pipeline.",CREATING_SOURCES:"Creating Sources...",CREATING_SOURCES_SUBTITLE:"This may take a few moments while sources are being created.",SELECT_NAMESPACE:"Select namespace from the list",SELECT_NAMESPACE_SUBTITLE:"Add namespace so you can select workloads from it.",CREATING_ACTION:"Creating action",CREATING_ACTION_SUBTITLE:"Please wait while we create the action",ADD_ACTION_DESCRIPTION:"Select an action to modify telemetry data before it's sent to destinations. Choose an action type and configure its details.",CREATING_INSTRUMENTATION_RULE:"Creating instrumentation rule",CREATING_INSTRUMENTATION_RULE_SUBTITLE:"Please wait while we create the instrumentation rule",ADD_INSTRUMENTATION_RULE_DESCRIPTION:"Define how telemetry is recorded from your application. Choose a rule type and configure the details.",CREATING_DESTINATION:"Creating destination",CREATING_DESTINATION_SUBTITLE:"Please wait while we create the destination",ADD_DESTINATION_DRAWER_DESCRIPTION:"Add backend destination you want to connect with Odigos."},mr={GET_STARTED:"Get started",ADD:"Add",ADD_NEW:"Add New",NEW:"New",SELECT:"Select",CREATE:"Create",UPDATE:"Update",EDIT:"Edit",DELETE:"Delete",CANCEL:"Cancel",DONE:"Done",SAVE:"Save",BACK:"Back",NEXT:"Next",TEST:"Test",TEST_CONNECTION:"Test Connection",INSTRUMENT:"Instrument",UNINSTRUMENT:"Uninstrument"},gr=(e,t)=>t?e.filter(e=>e.dataStreamNames.includes(t)||t===lr&&!e.dataStreamNames.length):[],fr=(e,t="",o={})=>{for(const r in e)if(e.hasOwnProperty(r)){const i=e[r],n=t?`${t}.${r}`:r;null===i||"object"!=typeof i||Array.isArray(i)?Array.isArray(i)?i.forEach((e,t)=>{const r=`${n}[${t}]`;null!==e&&"object"==typeof e?fr(e,r,o):o[r]=e}):o[n]=i:fr(i,n,o)}return o},xr=e=>{if(!e)return"0 KB/s";const t=Math.floor(Math.log(e)/Math.log(1024));return`${(e/Math.pow(1024,t)).toFixed(0===t?0:1)} ${["Bytes/s","KB/s","MB/s","GB/s","TB/s"][t]}`},yr=e=>{if(!e)return"0 ns";if(e<1e3)return`${e.toFixed(0)} ns`;if(e<1e6){const t=e/1e3;return`${t.toFixed(t<10?2:0)} μs`}if(e<1e9){const t=e/1e6;return`${t.toFixed(t<10?2:0)} ms`}if(e<6e10){const t=e/1e9;return`${t.toFixed(t<10?2:0)} s`}if(e<36e11){const t=e/6e10;return`${t.toFixed(t<10?2:0)} m`}if(e<864e11){const t=e/36e11;return`${t.toFixed(t<10?2:0)} h`}{const t=e/864e11;return`${t.toFixed(t<10?2:0)} d`}},br=()=>{const e=crypto.getRandomValues(new Uint8Array(16));let t=0;return"10000000-1000-4000-8000-100000000000".replace(/[018]/g,o=>{const r=e[t%16];t++;return("1"===o?r:"0"===o?63&r|128:15&r|64).toString(16)})},$r=l=>{const c=l?.toLowerCase(),d=c?.includes(mo.Samplers),p=c===mo.Attributes;if(d)return e;if(p)return t;return{[go.K8sAttributes]:a,[go.AddClusterInfo]:n,[go.DeleteAttributes]:i,[go.PiiMasking]:t,[go.RenameAttributes]:r,[go.URLTemplatization]:o,[go.ErrorSampler]:e,[go.ProbabilisticSampler]:e,[go.LatencySampler]:e,[go.ServiceNameSampler]:e,[go.SpanAttributeSampler]:e}[l]||s},vr=e=>{const t=e?.filter(({status:e})=>e===Oo.Error),o=e?.filter(({status:e})=>e===Oo.Warning),r=e?.filter(({status:e})=>e===Fo.Disabled),i=e?.filter(({status:e})=>e===Fo.Loading),n=t.length>0,a=o.length>0,s=r.length>0;return{errors:t,hasErrors:n,warnings:o,hasWarnings:a,disableds:r,hasDisableds:s,loadings:i,hasLoadings:i.length>0,priorotizedStatus:n?Oo.Error:a?Oo.Warning:s?Oo.Info:void 0}},wr=e=>{const t=e?.reduce((e,t)=>t.instrumented?e+1:e,0);return`${t}/${e?.length||0} instrumented`},Sr=e=>({[Ao.Java]:C,[Ao.Go]:S,[Ao.JavaScript]:w,[Ao.Python]:v,[Ao.DotNet]:$,[Ao.CSharp]:b,[Ao.CPlusPlus]:y,[Ao.Php]:x,[Ao.Ruby]:f,[Ao.Rust]:g,[Ao.Swift]:m,[Ao.Elixir]:h,[Ao.MySql]:u,[Ao.Nginx]:p,[Ao.Postgres]:d,[Ao.Redis]:c,[Ao.Kafka]:l,[Ao.Ignored]:s,[Ao.Unknown]:s,[Ao.Processing]:s,[Ao.NoContainers]:s,[Ao.NoRunningPods]:s}[e]||s),Cr=e=>e?.map(({language:e})=>Sr(e))||[],kr=e=>e?.map(e=>Sr(e))||[],Er=e=>e.detectedLanguages?.length?kr(e.detectedLanguages):Cr(e.containers),Ar=(e,t)=>{const o={[Uo.Alauda]:De,[Uo.AlibabaCloud]:Ae,[Uo.AppDynamics]:Ee,[Uo.Axiom]:ke,[Uo.AzureBlob]:Ce,[Uo.AzureMonitor]:Se,[Uo.BetterStack]:we,[Uo.Bonree]:ve,[Uo.Causely]:$e,[Uo.Checkly]:be,[Uo.Chronosphere]:ye,[Uo.ClickHouse]:xe,[Uo.CloudWatch]:fe,[Uo.Coralogix]:ge,[Uo.Dash0]:me,[Uo.Datadog]:he,[Uo.Dynamic]:U,[Uo.Dynatrace]:ue,[Uo.ElasticApm]:pe,[Uo.ElasticSearch]:de,[Uo.GoogleCloud]:ce,[Uo.GoogleCloudOTLP]:ce,[Uo.GrafanaCloudLoki]:le,[Uo.GrafanaCloudPrometheus]:le,[Uo.GrafanaCloudTempo]:le,[Uo.Greptime]:se,[Uo.Groundcover]:ae,[Uo.Honeycomb]:ne,[Uo.HyperDX]:ie,[Uo.Instana]:re,[Uo.Jaeger]:oe,[Uo.Kafka]:l,[Uo.Kloudmate]:te,[Uo.Last9]:ee,[Uo.Lightstep]:Z,[Uo.LogzIo]:Q,[Uo.Loki]:Y,[Uo.Lumigo]:q,[Uo.Middleware]:K,[Uo.NewRelic]:J,[Uo.Observe]:H,[Uo.Odigos]:X,[Uo.OneUptime]:V,[Uo.OpenObserve]:G,[Uo.Opsverse]:W,[Uo.Oracle]:j,[Uo.OTLP]:U,[Uo.OTLPHttp]:U,[Uo.Prometheus]:B,[Uo.Qryn]:M,[Uo.QrynOss]:P,[Uo.Quickwit]:L,[Uo.S3]:z,[Uo.Seq]:F,[Uo.Signalfx]:O,[Uo.Signoz]:R,[Uo.Splunk]:O,[Uo.SplunkSapm]:O,[Uo.SplunkOtlp]:O,[Uo.SumoLogic]:_,[Uo.TelemetryHub]:I,[Uo.Tempo]:N,[Uo.Tingyun]:T,[Uo.Traceloop]:D,[Uo.Uptrace]:A,[Uo.VictoriaMetrics]:E,[Uo.VictoriaMetricsCloud]:E,[Uo.XRay]:k}[e];return o&&!t?{icon:o}:{iconSrc:`https://d15jtxgb40qetw.cloudfront.net/${e}.svg`}},Dr=e=>({[To.Namespace]:_e,[To.Source]:Ie,[To.Destination]:Ne,[To.Action]:o,[To.InstrumentationRule]:Te}[e]),Tr=e=>"ruleId"in e&&e.ruleId?e.ruleId:"id"in e&&e.id?e.id:"namespace"in e&&e.namespace&&"kind"in e&&e.kind&&"name"in e&&e.name?{namespace:e.namespace,name:e.name,kind:e.kind}:"name"in e&&e.name?e.name:void 0,Nr=(e,t,o)=>{const{extended:r,prioritizeDisplayName:i}=o||{};let n="",a="";switch(t){case To.InstrumentationRule:const t=e;n=t.type,a=t.ruleName;break;case To.Source:const o=e;n=o.name,a=o.otelServiceName;break;case To.Action:const r=e;n=r.type,a=r.name;break;case To.Destination:const i=e;n=i.destinationType.displayName,a=i.name;break;case To.Namespace:const s=e;n=s.name,a=s.name}return r?n+(a&&a!==n?` (${a})`:""):i&&a||n},Ir=(e,t)=>{if(t===To.Source){const t={namespace:"",name:"",kind:""};return e.split("&").forEach(e=>{const[o,r]=e.split("=");t[o]=r}),t}return e},_r=e=>({[Vo.CodeAttributes]:ze,[Vo.CustomInstrumentation]:Fe,[Vo.HeadersCollection]:Re,[Vo.PayloadCollection]:Oe,[Vo.UnknownType]:s}[e]||s),Or=e=>{const{numberOfInstances:t,containers:o}=e;if(!o)return t&&t>0?Ao.Processing:Ao.NoRunningPods;const r=o?.filter(e=>e.language!==Ao.Ignored);if(!r.length)return Ao.NoContainers;const i=r.find(e=>e.language!==Ao.Unknown);return i?i.language:Ao.Unknown},Rr=(e,t,o)=>(t===To.Source?e?.sources.find(e=>e.kind===o.kind&&e.name===o.name&&e.namespace===o.namespace):e?.destinations.find(e=>e.id===o))||{throughput:0},Fr=e=>({[er.Logs]:Me,[er.Metrics]:Pe,[er.Traces]:Le}[e]),zr=e=>{if(!e)return X;return{[ko.K8s]:a,[ko.Vm]:Be}[e]},Lr=e=>{if(!e)return"Unknown";return{[ko.K8s]:"Kubernetes Cluster",[ko.Vm]:"Virtual Machine"}[e]},Pr=(e,t,o)=>{const r=e[t];return r?r.flatMap(e=>{const r=e[o],i=[];return void 0!==r&&(Array.isArray(r)?i.push(...r):i.push(r)),i.push(...Pr(e,t,o)),i}):[]},Mr=(e,t)=>{if(t===To.Source){let t="";return Object.entries(e).forEach(([e,o])=>{t+=`${e}=${o}&`}),t.slice(0,-1),t}return e},Br=(e,t,o)=>{switch(t){case Oo.Default:return e.v2.colors.purple[o];case Oo.Info:return e.v2.colors.blue[o];case Oo.Error:return e.v2.colors.red[o];case Oo.Warning:return e.v2.colors.yellow[o];case Oo.Success:return e.v2.colors.green[o];case zo.Disabled:case zo.Unknown:return e.v2.colors.silver[o];default:return e.v2.colors.white[500]}},Ur=e=>{switch(e){case qo.Updating:case Yo.Pending:case Qo.ContainerCreating:case Zo.Waiting:return Oo.Info;case qo.Healthy:case Yo.Succeeded:case Yo.Running:case Qo.Running:case Zo.Running:return Oo.Success;case qo.Degraded:return Oo.Warning;case qo.Failed:case Yo.Failed:case Qo.Error:case Qo.CrashLoopBackOff:case Qo.CreateContainerError:case Qo.CreateContainerConfigError:case Qo.ErrImagePull:case Qo.ErrImageNeverPull:case Qo.ImagePullBackOff:case Qo.InvalidImageName:case Qo.RegistryUnavailable:case Qo.NetworkNotReady:case Qo.OOMKilled:case Qo.ContainerCannotRun:case Zo.Terminated:case Qo.DeadlineExceeded:case Qo.StartError:return Oo.Error;case qo.Down:case Qo.Completed:return zo.Disabled;case qo.Unknown:case Yo.Unknown:default:return zo.Unknown}},jr=(e,t)=>{const o={[Oo.Default]:o=>X({fill:Br(t,e,"300"),...o}),[Oo.Info]:o=>Xe({fill:Br(t,e,"400"),...o}),[Oo.Error]:o=>Ve({fill:Br(t,e,"500"),...o}),[Oo.Warning]:o=>Ge({fill:Br(t,e,"500"),...o}),[Oo.Success]:o=>We({fill:Br(t,e,"500"),...o}),[zo.Disabled]:o=>je({fill:Br(t,e,"400"),...o}),[zo.Unknown]:o=>Ue({fill:Br(t,e,"300"),...o})};return o[e]},Wr=e=>{switch(e){case Go.Success:return Oo.Success;case Go.Error:case Go.Failure:return Oo.Error;case Go.Notice:return Oo.Warning;case Go.Unsupported:case Go.Unknown:return Oo.Info;case Go.Irrelevant:case Go.Disabled:return Fo.Disabled;case Go.Waiting:return Fo.Loading;case Go.Pending:default:return Oo.Default}},Gr=(e,t)=>{const o=t.find(([t,o])=>e>=t&&(null===o||e<=o));return o?.[2]||null},Vr={redis:c,mysql:u,postgresql:d,postgres:d,kafka:l,elasticsearch:de,clickhouse:xe,oracle:j,aws:He},Xr=e=>{const t=e.attributes,o=t["db.system"];if(o){const e=Vr[o.toLowerCase()];if(e)return e}const r=t["messaging.system"];if(r){const e=Vr[r.toLowerCase()];if(e)return e}const i=t["rpc.system"];if(i?.toLowerCase().includes("aws"))return He;const n=e.serviceName.toLowerCase();for(const[e,t]of Object.entries(Vr))if(n.includes(e))return t;return Ne},Hr=({namespace:e,name:t,kind:o})=>({namespace:e,name:t,kind:o});function Jr(e,t){if(!e)return t;if("object"==typeof e)return e;try{return JSON.parse(e)}catch(e){return t}}const Kr=(e,t)=>{const o=[],r=JSON.parse(JSON.stringify(e));for(const e of r){const r=Jr(t.fields,{}),i=e.items.findIndex(e=>e.type===t.destinationType.type);-1!==i&&o.push(...e.items[i].fields.map(e=>({...e,initialValue:r[e.name]})))}return o},qr=(e,t)=>{const o=e=>e?.some(({healthy:e})=>e.status!==Oo.Success);return e?.length?e.some(({instrumentationInstances:e})=>o(e)):o(t)??!1},Yr=e=>Array.isArray(e)?!e?.length:"object"==typeof e?!Object.keys(e||{}).length:[void 0,null,""].includes(e),Qr=e=>{if(!e)return!1;if(e.length>63)return!1;return/^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$/.test(e)},Zr=(e,t=0)=>{const o=(new Date).getTime();return new Date(e).getTime()-o<=t},ei=e=>{const t=String(e).trim().toLowerCase();return["true","false","1","0"].includes(t)},ti=(e,t=0)=>(new Date).getTime()-new Date(e).getTime()>=t,oi=/^(\d+\.)?(\d+\.)?(\*|\d+)$/,ri=e=>oi.test(e),ii=e=>e?e.replace(/([a-z0-9])([A-Z])/g,"$1 $2"):"",ni=e=>e?.map(({status:e,type:t,reason:o,message:r})=>({status:e,type:ii(t),reason:o?ii(o):"",message:r}))||[],ai=(e,t)=>{const o=Jr(e.fields,{});return t.length?t.map(e=>({key:e.name,name:e.displayName||e.name,value:o[e.name]??null})).filter(e=>null!==e.value):Object.entries(o).map(([e,t])=>({key:e,name:e,value:t}))},si=e=>e?Object.keys(e).filter(t=>e[t]).map(e=>nr[e]):[],li=e=>e?Object.keys(e).filter(t=>e[t].supported).map(e=>nr[e]):[],ci=e=>e.replace(/[^\d]/g,""),di=e=>{const t=String(e).trim().toLowerCase();return"true"===t||"1"===t},pi=e=>{let t="";try{const o=JSON.parse(e);t=Array.isArray(o)?o.map(e=>"object"==typeof e&&null!==e?`${e.key}: ${e.value}`:e).join(", "):"object"==typeof o&&null!==o?Object.entries(o).map(([e,t])=>`${e}: ${t}`).join(", "):e}catch(o){t=e}return t},ui=e=>{if("object"!=typeof e)return e;const t=Array.isArray(e)?[]:{};return Object.keys(e).forEach(o=>{const r=e[o];if(Array.isArray(r)){const e=r.filter(e=>null!=e&&""!==e);e.length>0&&(t[o]=e.map(e=>ui(e)))}else if("object"==typeof r&&null!==r){const e=ui(r);Object.keys(e).length>0&&(t[o]=e)}else[void 0,null,""].includes(r)||(t[o]=r)}),t},hi=(e,t=2)=>JSON.stringify(e||{},null,t),mi=async(e=1e3)=>new Promise(t=>setTimeout(t,e)),gi=e=>Object.entries(e).reduce((e,[t,o])=>(e[t]="string"==typeof o?o:JSON.stringify(o),e),{}),fi=e=>{let t=e.toString().replace("v","").split("-")[0];t=t.match(/[\d.]+/)?.[0]||"";const o=t.split(".");return 1e4*parseInt(o[0]||"0",10)+parseInt(o[1]||"0",10)};var xi,yi;!function(e){e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.P="p",e.Span="span"}(xi||(xi={})),function(e){e.XXXS="xxxs",e.XXS="xxs",e.XS="xs",e.S="s",e.M="m",e.L="l",e.XL="xl",e.XXL="xxl",e.XXXL="xxxl"}(yi||(yi={}));const bi=Pt.p`
|
|
2
|
+
margin: 0;
|
|
3
|
+
color: ${({$color:e,theme:t})=>e||t.v2.colors.grey[50]};
|
|
4
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
5
|
+
font-size: ${({theme:e,$size:t})=>e.v2.text.size[t]}px;
|
|
6
|
+
font-weight: ${({$weight:e})=>e};
|
|
7
|
+
text-align: ${({$align:e})=>e};
|
|
8
|
+
text-transform: ${({$transform:e})=>e};
|
|
9
|
+
line-height: ${({theme:e,$lineHeight:t,$size:o})=>t||`${e.v2.text.size[o]+2}px`};
|
|
10
|
+
opacity: ${({$opacity:e})=>e};
|
|
11
|
+
|
|
12
|
+
${({$nowrap:e})=>e&&Mt`
|
|
13
|
+
text-wrap: nowrap;
|
|
14
|
+
white-space: nowrap;
|
|
15
|
+
overflow: hidden;
|
|
16
|
+
text-overflow: ellipsis;
|
|
17
|
+
`}
|
|
18
|
+
|
|
19
|
+
${({$underline:e})=>e&&Mt`
|
|
20
|
+
text-decoration: underline;
|
|
21
|
+
`}
|
|
22
|
+
|
|
23
|
+
${({$withClick:e})=>e&&Mt`
|
|
24
|
+
cursor: pointer;
|
|
25
|
+
&:hover {
|
|
26
|
+
text-decoration: underline;
|
|
27
|
+
}
|
|
28
|
+
`}
|
|
29
|
+
`,$i=({children:e,variant:t=xi.P,color:o,size:r=yi.S,weight:i=400,opacity:n=1,align:a="left",lineHeight:s,transform:l,nowrap:c,underline:d,onClick:p,disabled:u,...h})=>{const m=e?.toString().split("\n")||[];return $t(bi,{as:t,$color:o,$size:r,$weight:i,$opacity:n,$align:a,$lineHeight:s,$transform:l,$nowrap:c,$underline:d,$withClick:!!p&&!u,onClick:u?void 0:p,...h,children:m.map((e,t)=>vt(St,{children:[e,t!==m.length-1&&$t("br",{})]},`typography-${t}-${e}`))})},vi=Pt.div`
|
|
30
|
+
color: ${({$color:e,theme:t})=>e||t.text.secondary};
|
|
31
|
+
font-size: ${({$size:e})=>void 0!==e?e:16}px;
|
|
32
|
+
font-weight: ${({$weight:e})=>void 0!==e?e:300};
|
|
33
|
+
text-align: ${({$align:e})=>e||"left"};
|
|
34
|
+
opacity: ${({$opacity:e})=>void 0!==e?e:1};
|
|
35
|
+
text-decoration: ${({$decoration:e})=>e||"none"};
|
|
36
|
+
text-transform: ${({$transform:e,$family:t})=>e||("secondary"===t?"uppercase":"none")};
|
|
37
|
+
font-family: ${({theme:e,$family:t="primary"})=>e.font_family[t]};
|
|
38
|
+
white-space: ${({$nowrap:e})=>e?"nowrap":"unset"};
|
|
39
|
+
text-wrap: ${({$nowrap:e})=>e?"nowrap":"unset"};
|
|
40
|
+
`,wi=e=>{const t=e.match(/<a[^>]*href="([^"]*)"[^>]*>(.*?)<\/a>/g);return t?.map(e=>{const[t,o,r]=e.split('"');return{original:e,href:o,label:r.replace("</a>","").replace(">","")}})},Si=e=>{const t=e.match(/<strong[^>]*>(.*?)<\/strong>/g);return t?.map(e=>{const t=e.replace(/<strong[^>]*>/,"").replace(/<\/strong>/,"");return{original:e,label:t}})},Ci=(e,t)=>{const o=wi(e);o?.forEach((t,o)=>{e=e.replace(t.original,`LINK-${o}###`)});const r=Si(e);r?.forEach((t,o)=>{e=e.replace(t.original,`STRONG-${o}###`)});return e.split(" ").map(e=>{if(e.includes("LINK-")){const[r,i]=e.split("###"),n=o?.[parseInt(r.replace("LINK-",""))];return vt(St,{children:[$t("a",{href:n?.href,target:"_blank",rel:"noreferrer",style:{color:t.colors.majestic_blue_soft},children:n?.label}),i?`${i} `:" "]},e)}if(e.includes("STRONG-")){const[t,o]=e.split("###"),i=r?.[parseInt(t.replace("STRONG-",""))];return vt(St,{children:[$t("strong",{style:{fontWeight:600},children:i?.label}),o?`${o} `:" "]},e)}return e+" "})},ki=({children:e,color:t,size:o,weight:r,align:i,family:n,opacity:a,decoration:s,transform:l,nowrap:c,...d})=>{const p=Bt(),u=Ct(()=>(e?["string","number"].includes(typeof e)?e.toString():Array.isArray(e)?e.map(e=>"object"==typeof e&&Object.hasOwn(e,"props")?e.props.children:e).filter(e=>e&&["string","number"].includes(typeof e)).join(" "):"":"").split("\n"),[e]);return $t(vi,{$color:t,$size:o,$weight:r,$align:i,$family:n,$opacity:a,$decoration:s,$transform:l,$nowrap:c,...d,children:u.length?u.map((e,t)=>vt(St,{children:[Ci(e,p),t!==u.length-1?$t("br",{}):null]},`text-${t}-${e}`)):e})},Ei=Pt.div`
|
|
41
|
+
padding: 4px 0 0 0;
|
|
42
|
+
`,Ai=Pt(ki)`
|
|
43
|
+
font-size: 12px;
|
|
44
|
+
color: ${({theme:e})=>e.text.error};
|
|
45
|
+
`,Di=({children:e})=>$t(Ei,{children:$t(Ai,{children:e})}),Ti=Pt.div`
|
|
46
|
+
position: relative;
|
|
47
|
+
width: 100%;
|
|
48
|
+
`,Ni=Pt.div`
|
|
49
|
+
width: calc(100% - 16px);
|
|
50
|
+
display: flex;
|
|
51
|
+
align-items: center;
|
|
52
|
+
height: 36px;
|
|
53
|
+
gap: 8px;
|
|
54
|
+
padding-left: 12px;
|
|
55
|
+
transition: border-color 0.3s;
|
|
56
|
+
border-radius: 32px;
|
|
57
|
+
border: 1px solid ${({theme:e,$hasError:t})=>t?e.text.error:e.colors.border};
|
|
58
|
+
|
|
59
|
+
&:hover {
|
|
60
|
+
border-color: ${({theme:e,$hasError:t})=>t?e.text.error_secondary:e.colors.secondary};
|
|
61
|
+
}
|
|
62
|
+
&:focus-within {
|
|
63
|
+
border-color: ${({theme:e,$hasError:t})=>t?e.text.error_secondary:e.colors.secondary};
|
|
64
|
+
}
|
|
65
|
+
`,Ii=Pt.input`
|
|
66
|
+
flex: 1;
|
|
67
|
+
border: none;
|
|
68
|
+
outline: none;
|
|
69
|
+
background: none;
|
|
70
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
71
|
+
font-size: 14px;
|
|
72
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
73
|
+
font-weight: 300;
|
|
74
|
+
&::placeholder {
|
|
75
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
76
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
77
|
+
opacity: 0.4;
|
|
78
|
+
font-size: 14px;
|
|
79
|
+
font-weight: 300;
|
|
80
|
+
line-height: 22px;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
&:disabled {
|
|
84
|
+
cursor: not-allowed;
|
|
85
|
+
}
|
|
86
|
+
`,_i=Pt.ul`
|
|
87
|
+
position: absolute;
|
|
88
|
+
max-height: 500px;
|
|
89
|
+
top: 32px;
|
|
90
|
+
border-radius: 24px;
|
|
91
|
+
width: calc(100% - 32px);
|
|
92
|
+
overflow-y: auto;
|
|
93
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
94
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
95
|
+
z-index: 9999;
|
|
96
|
+
padding: 12px;
|
|
97
|
+
`,Oi=Pt.li`
|
|
98
|
+
width: calc(100% - 24px);
|
|
99
|
+
padding: 8px 12px;
|
|
100
|
+
cursor: ${({$isList:e})=>e?"default":"pointer"};
|
|
101
|
+
border-radius: 24px;
|
|
102
|
+
gap: 8px;
|
|
103
|
+
display: flex;
|
|
104
|
+
align-items: ${({$isList:e})=>e?"flex-start":"center"};
|
|
105
|
+
background: transparent;
|
|
106
|
+
&:hover {
|
|
107
|
+
background: ${({theme:e,$isList:t})=>!t&&e.colors.dropdown_bg_2};
|
|
108
|
+
}
|
|
109
|
+
`,Ri=Pt.div`
|
|
110
|
+
width: 100%;
|
|
111
|
+
`,Fi=Pt.div`
|
|
112
|
+
display: flex;
|
|
113
|
+
width: 100%;
|
|
114
|
+
`,zi=Pt.div`
|
|
115
|
+
width: 1px;
|
|
116
|
+
height: 52px;
|
|
117
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
118
|
+
position: absolute;
|
|
119
|
+
left: 33px;
|
|
120
|
+
`,Li=Pt.div`
|
|
121
|
+
display: flex;
|
|
122
|
+
flex-direction: column;
|
|
123
|
+
gap: 4px;
|
|
124
|
+
`,Pi=Pt(ki)`
|
|
125
|
+
flex: 1;
|
|
126
|
+
font-size: 14px;
|
|
127
|
+
`,Mi=Pt(ki)`
|
|
128
|
+
color: ${({theme:e})=>e.text.grey};
|
|
129
|
+
font-size: 10px;
|
|
130
|
+
line-height: 150%;
|
|
131
|
+
`,Bi=Pt.ul`
|
|
132
|
+
padding-left: 0px;
|
|
133
|
+
margin: 4px 0 0 0;
|
|
134
|
+
list-style: none;
|
|
135
|
+
width: 100%;
|
|
136
|
+
`,Ui=(e,t)=>t?e.reduce((e,o)=>{if(o.items){const r=Ui(o.items,t);r.length&&e.push({...o,items:r})}else o.label.toLowerCase().includes(t.toLowerCase())&&e.push(o);return e},[]):e,ji=({placeholder:e="Type to search...",options:t,selectedOption:o,onOptionSelect:r,defaultText:i,onTextChange:n,style:a,disabled:s,errorMessage:l,...c})=>{const[d,p]=kt(o?.label||i||""),[u,h]=kt(Ui(t,d)),[m,g]=kt(!1);kt(-1),Et(()=>h(Ui(t,d)),[t]);const f=o?.icon,x=e=>{e&&(p(e.label),n?.(e.label)),g(!e),r?.(e)};return vt(Ti,{style:a,children:[vt(Ni,{$hasError:!!l,children:[f&&$t(f,{}),$t(Ii,{type:"text",value:d,placeholder:e,onChange:e=>{e.stopPropagation();const o=e.target.value,r=Ui(t,o),i=1===r.length&&r[0].label===o?r[0]:void 0;p(o),n?.(o),h(r),x(i)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},disabled:s,onBlur:()=>!s&&g(!1),onFocus:()=>!s&&g(!0),...c})]}),m&&u.length?$t(_i,{children:u.map(e=>$t(Wi,{option:e,onClick:x},e.type||e.label))}):null,l&&$t(Di,{children:l})]})},Wi=({option:e,renderIcon:t=!0,onClick:o})=>{const r=!!e.items&&e.items.length>0,i=e.icon;return vt(Oi,{"data-id":`option-${e.type||e.label}`,$isList:r,onMouseDown:()=>r?null:o(e),children:[i&&t&&$t(i,{}),vt(Ri,{children:[vt(Li,{children:[$t(Pi,{children:e.label}),$t(Mi,{children:e.description})]}),r&&$t(Bi,{children:e.items?.map(e=>vt(Fi,{children:[$t(zi,{}),$t(Wi,{option:e,renderIcon:!1,onClick:o})]},e.type||e.label))})]})]})},Gi=bt(e=>({activeNodeType:null,activeNodeId:null,setActiveNodeType:t=>e({activeNodeType:t}),setActiveNodeId:t=>e({activeNodeId:t})})),Vi=[{type:go.K8sAttributes,icon:$r(go.K8sAttributes),label:"Kubernetes Attributes",description:"Add dynamic k8s resource attributes to your data.",allowedSignals:[er.Traces,er.Metrics,er.Logs],docsEndpoint:"/pipeline/actions/attributes/k8sattributes",docsDescription:"This action adds kubernetes related resource attributes to spans, metrics data points and log records."},{type:go.AddClusterInfo,icon:$r(go.AddClusterInfo),label:"Add Cluster Info",description:"Add static cluster-scoped attributes to your data.",allowedSignals:[er.Traces,er.Metrics,er.Logs],docsEndpoint:"/pipeline/actions/attributes/addclusterinfo",docsDescription:"This action adds static resource attributes to spans, metrics data points and log records. It is useful to add cluster-wide attributes to all telemetry signals."},{type:go.DeleteAttributes,icon:$r(go.DeleteAttributes),label:"Delete Attribute",description:"Delete attributes from logs, metrics, and traces.",allowedSignals:[er.Traces,er.Metrics,er.Logs],docsEndpoint:"/pipeline/actions/attributes/deleteattribute",docsDescription:"This action will delete the specified attributes from all telemetry signals that are specified in the signals field, regardless of the source, or any other condition."},{type:go.RenameAttributes,icon:$r(go.RenameAttributes),label:"Rename Attribute",description:"Rename attributes in logs, metrics, and traces.",allowedSignals:[er.Traces,er.Metrics,er.Logs],docsEndpoint:"/pipeline/actions/attributes/renameattribute",docsDescription:"This action will rename the specified attributes from all telemetry signals that are specified in the signals field, regardless of the source, or any other condition."},{type:go.PiiMasking,icon:$r(go.PiiMasking),label:"PII Masking",description:"Mask PII data in your traces.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/attributes/piimasking",docsDescription:"This action processes a list of PII categories to be masked from the traces."},{type:go.URLTemplatization,icon:$r(go.URLTemplatization),label:"URL Templatization",description:"Replace dynamic URL path segments with named placeholders to reduce span cardinality.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/attributes/urltemplatization",docsDescription:"Normalizes HTTP URL paths by replacing dynamic segments (IDs, UUIDs, dates) with named placeholders (e.g. /user/1234 → /user/{id}). Reduces cardinality of http.route and span names, improving usability in telemetry backends.",minVersion:fi("v1.21.0")}],Xi=[{type:go.ErrorSampler,icon:$r(mo.Samplers),label:"Error Sampler",description:"Sample errors based on percentage.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/sampling/errorsampler",docsDescription:"This action is a Global Action that supports error sampling by filtering out non-error traces."},{type:go.LatencySampler,icon:$r(mo.Samplers),label:"Latency Sampler",description:"Add latency to your traces.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/sampling/latencysampler",docsDescription:"This action is an Endpoint Action that samples traces based on their duration for a specific service and endpoint (HTTP route) filter."},{type:go.ProbabilisticSampler,icon:$r(mo.Samplers),label:"Probabilistic Sampler",description:"Sample traces based on percentage.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/sampling/probabilisticsampler",docsDescription:"This action supports probabilistic sampling based on a configured sampling percentage applied to the TraceID."},{type:go.ServiceNameSampler,icon:$r(mo.Samplers),label:"Service Name Sampler",description:"Sample traces based on the presence of specified services within a trace.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/sampling/servicenamesampler",docsDescription:"This action supports service name sampling based on the presence of specified services within a trace."},{type:go.SpanAttributeSampler,icon:$r(mo.Samplers),label:"Span Attributes Sampler",description:"Sample traces based on the presence or value of specific attributes within a trace.",allowedSignals:[er.Traces],docsEndpoint:"/pipeline/actions/sampling/spanattributesampler",docsDescription:"This action supports service name sampling based on the presence or value of specific attributes within a trace."}],Hi=[{label:"Attributes",icon:$r(mo.Attributes),items:Vi},{label:"Samplers",icon:$r(mo.Samplers),items:Xi}];var Ji;!function(e){e.ALL="all",e.UNSAVED="unsaved",e.EXISTS="exists",e.DETECTED="detected",e.SELF_HOSTED="self-hosted",e.MANAGED="managed"}(Ji||(Ji={}));const Ki={[Ji.ALL]:{TITLE:"All",DESCRIPTION:"All destinations"},[Ji.UNSAVED]:{TITLE:"Selected",DESCRIPTION:"These are destinations that you have not yet saved."},[Ji.EXISTS]:{TITLE:"Already configured",DESCRIPTION:"These are destinations that you have already configured in other data-streams and can reuse them."},[Ji.DETECTED]:{TITLE:"Detected by system",DESCRIPTION:"Odigos found these destinations in your cluster and pre-filled their details. Review and enable them to start sending data."},[Ji.SELF_HOSTED]:{TITLE:"Self hosted",DESCRIPTION:"Full control and customization for advanced application monitoring."},[Ji.MANAGED]:{TITLE:"Managed",DESCRIPTION:"Effortless monitoring with scalable performance management."}},qi=[{type:Vo.CodeAttributes,icon:_r(Vo.CodeAttributes),label:"Code Attributes",description:"Collect code attributes containing payload data to traces.",docsEndpoint:"/pipeline/rules/codeattributes",docsDescription:'The "Code Attributes" rule can be used to add code attributes containing payload data to traces.',supportedLanguages:[Ao.Go,Ao.Python]},{type:Vo.CustomInstrumentation,icon:_r(Vo.CustomInstrumentation),label:"Custom Instrumentation",description:"Define custom instrumentation for specific class and methods (i.e. for Java) or explicit symbol (i.e. for Golang).",docsEndpoint:"/pipeline/rules/custominstrumentation",docsDescription:'The "Custom Instrumentation" rule can be used to instrument a specific symbol (i.e. for Golang), or a class and method combination (i.e. for Java) for detailed tracing.',supportedLanguages:[Ao.Go,Ao.Java]},{type:Vo.HeadersCollection,icon:_r(Vo.HeadersCollection),label:"Headers Collection",description:"Collect span attributes containing HTTP Headers data to traces.",docsEndpoint:"/pipeline/rules/headerscollection",docsDescription:'The "Headers Collection" rule can be used to add span attributes containing HTTP Headers data to traces.',supportedLanguages:[Ao.Go,Ao.Java,Ao.JavaScript]},{type:Vo.PayloadCollection,icon:_r(Vo.PayloadCollection),label:"Payload Collection",description:"Collect span attributes containing payload data to traces.",docsEndpoint:"/pipeline/rules/payloadcollection",docsDescription:'The "Payload Collection" rule can be used to add span attributes containing payload data to traces.',supportedLanguages:[Ao.Go]}],Yi=[{id:er.Logs,value:"Logs"},{id:er.Metrics,value:"Metrics"},{id:er.Traces,value:"Traces"}],Qi={[Ao.Go]:"Go",[Ao.Java]:"Java",[Ao.JavaScript]:"Node.js",[Ao.Python]:"Python",[Ao.DotNet]:".NET",[Ao.CSharp]:"C#",[Ao.CPlusPlus]:"C++",[Ao.Php]:"PHP",[Ao.Ruby]:"Ruby",[Ao.Rust]:"Rust",[Ao.Swift]:"Swift",[Ao.Elixir]:"Elixir",[Ao.MySql]:"MySQL",[Ao.Nginx]:"Nginx",[Ao.Postgres]:"PostgreSQL",[Ao.Redis]:"Redis",[Ao.Kafka]:"Kafka",[Ao.Ignored]:"Ignored",[Ao.Unknown]:"Unknown",[Ao.Processing]:"Processing",[Ao.NoContainers]:"No Containers",[Ao.NoRunningPods]:"No Running Pods"},Zi=[{id:Ao.Go,value:Qi[Ao.Go],icon:Sr(Ao.Go)},{id:Ao.Java,value:Qi[Ao.Java],icon:Sr(Ao.Java)},{id:Ao.JavaScript,value:Qi[Ao.JavaScript],icon:Sr(Ao.JavaScript)},{id:Ao.Python,value:Qi[Ao.Python],icon:Sr(Ao.Python)},{id:Ao.Php,value:Qi[Ao.Php],icon:Sr(Ao.Php)},{id:Ao.Ruby,value:Qi[Ao.Ruby],icon:Sr(Ao.Ruby)},{id:Ao.Rust,value:Qi[Ao.Rust],icon:Sr(Ao.Rust)},{id:Ao.DotNet,value:Qi[Ao.DotNet],icon:Sr(Ao.DotNet)},{id:Ao.CSharp,value:Qi[Ao.CSharp],icon:Sr(Ao.CSharp)},{id:Ao.CPlusPlus,value:Qi[Ao.CPlusPlus],icon:Sr(Ao.CPlusPlus)},{id:Ao.Swift,value:Qi[Ao.Swift],icon:Sr(Ao.Swift)},{id:Ao.Elixir,value:Qi[Ao.Elixir],icon:Sr(Ao.Elixir)}],en={[Ao.Go]:{community:[{id:Wo.GolangCommunity,value:Wo.GolangCommunity,icon:Sr(Ao.Go)}],enterprise:[{id:Wo.GolangEnterprise,value:Wo.GolangEnterprise,icon:Sr(Ao.Go)}]},[Ao.JavaScript]:{community:[{id:Wo.NodejsCommunity,value:Wo.NodejsCommunity,icon:Sr(Ao.JavaScript)}],enterprise:[{id:Wo.NodejsEnterprise,value:Wo.NodejsEnterprise,icon:Sr(Ao.JavaScript)}]},[Ao.Python]:{community:[{id:Wo.PythonCommunity,value:Wo.PythonCommunity,icon:Sr(Ao.Python)}],enterprise:[{id:Wo.PythonEnterprise,value:Wo.PythonEnterprise,icon:Sr(Ao.Python)}]},[Ao.Java]:{community:[{id:Wo.JavaCommunity,value:Wo.JavaCommunity,icon:Sr(Ao.Java)}],enterprise:[{id:Wo.JavaEnterprise,value:Wo.JavaEnterprise,icon:Sr(Ao.Java)},{id:Wo.JavaEbpfInstrumentations,value:Wo.JavaEbpfInstrumentations,icon:Sr(Ao.Java)}]},[Ao.DotNet]:{community:[{id:Wo.DotNetCommunity,value:Wo.DotNetCommunity,icon:Sr(Ao.DotNet)}],enterprise:[{id:Wo.DotNetEnterprise,value:Wo.DotNetEnterprise,icon:Sr(Ao.DotNet)}]},[Ao.Ruby]:{community:[{id:Wo.RubyCommunity,value:Wo.RubyCommunity,icon:Sr(Ao.Ruby)}],enterprise:[{id:Wo.RubyEnterprise,value:Wo.RubyEnterprise,icon:Sr(Ao.Ruby)}]},[Ao.Php]:{community:[{id:Wo.PhpCommunity,value:Wo.PhpCommunity,icon:Sr(Ao.Php)}],enterprise:[]},[Ao.CSharp]:{community:[],enterprise:[{id:Wo.CPlusPlusEnterprise,value:Wo.CPlusPlusEnterprise,icon:Sr(Ao.CSharp)}]},[Ao.MySql]:{community:[],enterprise:[{id:Wo.MySqlEnterprise,value:Wo.MySqlEnterprise,icon:Sr(Ao.MySql)}]},[Ao.CPlusPlus]:{community:[],enterprise:[]},[Ao.Rust]:{community:[],enterprise:[]},[Ao.Swift]:{community:[],enterprise:[]},[Ao.Elixir]:{community:[],enterprise:[]},[Ao.Nginx]:{community:[],enterprise:[]},[Ao.Postgres]:{community:[],enterprise:[]},[Ao.Redis]:{community:[],enterprise:[]},[Ao.Kafka]:{community:[],enterprise:[]},[Ao.Ignored]:{community:[],enterprise:[]},[Ao.Unknown]:{community:[],enterprise:[]},[Ao.Processing]:{community:[],enterprise:[]},[Ao.NoContainers]:{community:[],enterprise:[]},[Ao.NoRunningPods]:{community:[],enterprise:[]}},tn=6048e5,on=bt()(Rt(e=>({darkMode:!0,setDarkMode:t=>e({darkMode:t})}),{name:pr.DARK_MODE,storage:"undefined"!=typeof window?Ft(()=>localStorage):void 0})),rn={dataStreamsLoading:!1,dataStreams:[],selectedStreamName:lr},nn=bt(e=>({...rn,setDataStreamsLoading:t=>e({dataStreamsLoading:t}),setDataStreams:t=>e({dataStreams:t}),addDataStreams:t=>e(e=>{const o=[...e.dataStreams,...t].map(e=>[e.name,e]);return{dataStreams:Array.from(new Map(o).values())}}),removeDataStreams:t=>e(e=>({dataStreams:e.dataStreams.filter(e=>!t.find(t=>t.name===e.name))})),setSelectedStreamName:t=>e({selectedStreamName:t}),resetDataStreamStore:()=>e(rn)})),an=bt(e=>({drawerType:null,drawerEntityId:null,setDrawerType:t=>e({drawerType:t}),setDrawerEntityId:t=>e({drawerEntityId:t})})),sn=bt(e=>({namespacesLoading:!1,namespaces:[],sourcesLoading:!1,sources:[],destinationsLoading:!1,destinations:[],actionsLoading:!1,actions:[],instrumentationRulesLoading:!1,instrumentationRules:[],setEntitiesLoading:(t,o)=>{const r=t===To.Namespace?"namespacesLoading":t===To.Source?"sourcesLoading":t===To.Destination?"destinationsLoading":t===To.Action?"actionsLoading":t===To.InstrumentationRule?"instrumentationRulesLoading":"NONE";"NONE"!==r&&e({[r]:o})},setEntities:(t,o)=>{const r=t===To.Namespace?"namespaces":t===To.Source?"sources":t===To.Destination?"destinations":t===To.Action?"actions":t===To.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==r&&e({[r]:o})},addEntities:(t,o)=>{const r=t===To.Namespace?"namespaces":t===To.Source?"sources":t===To.Destination?"destinations":t===To.Action?"actions":t===To.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==r&&e(e=>{const t=[...e[r]],i=new Map;return t.forEach((e,t)=>{i.set(JSON.stringify(Tr(e)),t)}),o.forEach(e=>{const o=JSON.stringify(Tr(e)),r=i.get(o);void 0!==r?t[r]={...t[r],...e}:(i.set(o,t.length),t.push(e))}),{[r]:t}})},removeEntities:(t,o)=>{const r=t===To.Namespace?"namespaces":t===To.Source?"sources":t===To.Destination?"destinations":t===To.Action?"actions":t===To.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==r&&e(e=>{const i=new Set;o.forEach(e=>{const o=t===To.Source?JSON.stringify(Tr(e)):String(e);i.add(o)});const n=e[r].filter(e=>{const o=t===To.Source?JSON.stringify(Tr(e)):String(Tr(e));return!i.has(o)});return{[r]:n}})},resetEntityStore:()=>{e({namespacesLoading:!1,namespaces:[],sourcesLoading:!1,sources:[],destinationsLoading:!1,destinations:[],actionsLoading:!1,actions:[],instrumentationRulesLoading:!1,instrumentationRules:[]})}})),ln=()=>({searchText:"",statuses:[],platformTypes:[],namespaces:[],kinds:[],monitors:[],languages:[],conditions:[],podsAgentInjectionStatus:[],errors:[],onlyErrors:!1}),cn=bt(e=>({searchText:"",setSearchText:t=>e({searchText:t}),statuses:[],setStatuses:t=>e({statuses:t}),platformTypes:[],setPlatformTypes:t=>e({platformTypes:t}),namespaces:[],setNamespaces:t=>e({namespaces:t}),kinds:[],setKinds:t=>e({kinds:t}),monitors:[],setMonitors:t=>e({monitors:t}),languages:[],setLanguages:t=>e({languages:t}),conditions:[],setConditions:t=>e({conditions:t}),podsAgentInjectionStatus:[],setPodsAgentInjectionStatus:t=>e({podsAgentInjectionStatus:t}),errors:[],setErrors:t=>e({errors:t}),onlyErrors:!1,setOnlyErrors:t=>e({onlyErrors:t}),setAll:t=>e(t),clearAll:()=>e({searchText:"",statuses:[],platformTypes:[],namespaces:[],kinds:[],monitors:[],languages:[],conditions:[],podsAgentInjectionStatus:[],errors:[],onlyErrors:!1}),getEmptyState:ln})),dn=bt(e=>({currentModal:"",setCurrentModal:t=>e({currentModal:t})})),pn=bt((e,t)=>({notifications:[],addNotification:o=>{const r=new Date,i=`${r.getTime().toString()}${o.target?`#${o.target}`:""}`,{notifications:n}=t();n.some(e=>e.type===o.type&&e.title===o.title&&e.message===o.message&&!e.dismissed)||e(e=>({notifications:[{...o,id:i,time:r.toISOString(),dismissed:!1,seen:!1},...e.notifications]}))},markAsDismissed:t=>{e(e=>{const o=e.notifications.findIndex(e=>e.id===t);return-1!==o&&(e.notifications[o].dismissed=!0),{notifications:e.notifications}})},markAsSeen:t=>{e(e=>{const o=e.notifications.findIndex(e=>e.id===t);return-1!==o&&(e.notifications[o].seen=!0),{notifications:e.notifications}})},removeNotification:t=>{e(e=>{const o=e.notifications.findIndex(e=>e.id===t);return-1!==o&&e.notifications.splice(o,1),{notifications:e.notifications}})},removeNotifications:t=>{t&&e(e=>({notifications:e.notifications.filter(e=>e.id.split("#")[1]!==t)}))}}));var un;!function(e){e.Instrumenting="instrumenting",e.Uninstrumenting="uninstrumenting",e.BulkInstrumenting="bulk-instrumenting",e.BulkUninstrumenting="bulk-uninstrumenting",e.DownloadingDiagnose="downloading-diagnose"}(un||(un={}));const hn=(e,t)=>({...t?.[e]||{total:0,current:0,percentage:0}}),mn=e=>(e.total<e.current&&(e.total=e.current+1),e.percentage=Math.round(e.current/e.total*100),e),gn=bt((e,t)=>({progress:{},setProgress:(o,r)=>{const i=t(),n=hn();return"number"==typeof r.total&&(n.total=r.total),"number"==typeof r.current&&(n.current=r.current),Array.isArray(r.list)&&(n.list=r.list),e({progress:{...i.progress,[o]:mn(n)}})},addProgress:(o,r,i)=>{const n=t(),a=hn(o,n.progress);return a.current+=r,i&&(a.list=a.list?.map(e=>e.label===i.label?{...e,status:i.status}:e)),e({progress:{...n.progress,[o]:mn(a)}})},resetProgress:t=>e({progress:{[t]:void 0}})})),fn=bt(e=>({selectedSources:{},setSelectedSources:t=>e({selectedSources:t}),resetSelectedState:()=>e(()=>({selectedSources:{},selectedConnection:null}))})),xn={configuredSources:{},configuredFutureApps:{},configuredDestinations:[],configuredDestinationsUpdateOnly:[]},yn=(e,t)=>e.destinationType.type!==t.destinationType.type,bn=bt(e=>({...xn,setConfiguredSources:t=>e({configuredSources:t}),setConfiguredFutureApps:t=>e({configuredFutureApps:t}),setConfiguredDestinations:t=>e({configuredDestinations:t}),addConfiguredDestination:t=>e(e=>({configuredDestinations:[...e.configuredDestinations,t]})),removeConfiguredDestination:t=>e(e=>({configuredDestinations:e.configuredDestinations.filter(e=>yn(e,t))})),setConfiguredDestinationsUpdateOnly:t=>e({configuredDestinationsUpdateOnly:t}),addConfiguredDestinationUpdateOnly:t=>e(e=>{const o=[...e.configuredDestinationsUpdateOnly,t].map(e=>[e.id,e]);return{configuredDestinationsUpdateOnly:Array.from(new Map(o).values())}}),removeConfiguredDestinationUpdateOnly:t=>e(e=>({configuredDestinationsUpdateOnly:e.configuredDestinationsUpdateOnly.filter(e=>yn(e,t))})),clearStore:()=>e(()=>({...xn}))})),$n={v2:{text:{size:{xxxs:10,xxs:12,xs:14,s:16,m:20,l:24,xl:32,xxl:40,xxxl:48}},colors:{black:{500:"#151618"},white:{500:"#FFFFFF"},purple:{100:"#E1D4FF",200:"#C3AAFF",300:"#A57FFF",400:"#8854FF",500:"#6A2AFF",600:"#5925D0",700:"#4822A2",800:"#371E73",900:"#271A45"},green:{100:"#DCFDFA",200:"#B9FBF6",300:"#96FAF1",400:"#73F8ED",500:"#50F6E8",600:"#44C9BE",700:"#399D94",800:"#2D6F6A",900:"#224340"},grey:{25:"#F6F6F6",50:"#ECECED",100:"#DADADB",150:"#B8B8B8",200:"#B4B5B7",300:"#8F9093",400:"#696B6F",500:"#44464B",600:"#3A3C40",700:"#313236",800:"#282A2E",900:"#1B1B1C"},silver:{25:"#F6F6F7",50:"#EDEDEE",100:"#DADCDE",200:"#B6B8BD",300:"#91959C",400:"#6D717B",500:"#484E5A",600:"#3E424C",700:"#34383F",750:"#2C2F36",800:"#26292F",900:"#1F2125",1e3:"#1B1C1D"},red:{100:"#FFE5E7",200:"#FFCBD0",300:"#FFB0B8",400:"#FF96A1",500:"#FF7C89",600:"#D06772",700:"#A2535B",800:"#733F44",900:"#452B2D",1e3:"#2E2022"},blue:{100:"#EBF0FA",200:"#D6E1F4",300:"#ADC3EA",400:"#84A4DF",500:"#5C86D5",600:"#3368CA",700:"#2D57A6",800:"#274782",900:"#21375E",1e3:"#1C273A"},yellow:{100:"#FFFBF1",200:"#FFF7E2",300:"#FFEFC6",400:"#FFE7A9",500:"#FFDF8D",600:"#FFD770",700:"#D0B05E",800:"#A28A4C",900:"#73633A",1e3:"#453D28"},beige:{600:"#EEC990"},pink:{600:"#F576A2"},orange:{600:"#F29142"}}},colors:{majestic_blue:"#444AD9",majestic_blue_soft:"#6C7AE8",orange_og:"#FE9239",orange_soft:"#FFB160",dark_red:"#802828",darker_red:"#611F1F",darkest_red:"#281515",darkest_red_hover:"#351515",dark_green:"#2D4323"},text:{},font_family:{primary:"Inter, sans-serif",secondary:"Kode Mono, sans-serif",code:"IBM Plex Mono, monospace"}},vn={v2:$n.v2,darkMode:!0,colors:{...$n.colors,primary:"#111111",secondary:"#F9F9F9",border:"#525252",dark_grey:"#151515",translucent_bg:"#1A1A1A",dropdown_bg:"#242424",dropdown_bg_2:"#333333",warning:"#472300",error:"#431919",success:"#172013",info:"#242424",default:"#181944"},text:{white:"#FFFFFF",primary:"#111111",secondary:"#F9F9F9",grey:"#B8B8B8",dark_grey:"#8F8F8F",darker_grey:"#7A7A7A",light_grey:"#CCD0D2",dark_button:"#0A1824",warning:"#E9CF35",warning_secondary:"#FFA349",error:"#EF7676",error_secondary:"#DB5151",success:"#81AF65",success_secondary:"#51DB51",info:"#B8B8B8",info_secondary:"#CCDDDD",default:"#AABEF7",default_secondary:"#8CBEFF"},font_family:$n.font_family},wn={v2:$n.v2,darkMode:!1,colors:{...$n.colors,primary:"#EEEEEE",secondary:"#060606",border:"#ADADAD",dark_grey:"#EAEAEA",translucent_bg:"#E5E5E5",dropdown_bg:"#DBDBDB",dropdown_bg_2:"#CCCCCC",warning:"#F6F092",error:"#FACECE",success:"#C8DEB8",info:"#E0E0E0",default:"#CAD9FB"},text:{white:"#FFFFFF",primary:"#EEEEEE",secondary:"#060606",grey:"#474747",dark_grey:"#707070",darker_grey:"#858585",light_grey:"#332F2D",dark_button:"#F5E7DB",warning:"#A56F12",warning_secondary:"#CA9416",error:"#B63A3A",error_secondary:"#DB5151",success:"#4E763A",success_secondary:"#67964C",info:"#525252",info_secondary:"#7A7A7A",default:"#444AD9",default_secondary:"#6C7AE8"},font_family:$n.font_family},Sn=e=>e?vn:wn;var Cn=Object.freeze({__proto__:null,baseTheme:$n,darkModeTheme:vn,getTheme:Sn,lightModeTheme:wn});zt('@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap");@import url("https://fonts.googleapis.com/css2?family=Kode+Mono:wght@100;200;300;400;500;600;700&display=swap");@import url("https://fonts.googleapis.com/css2?family=Inter+Tight:wght@400;700&display=swap");@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&display=swap");*{-ms-overflow-style:none;scrollbar-width:none}::-webkit-scrollbar{display:none}*{animation-duration:.3s;animation-fill-mode:forwards;transition:all .3s}input{all:unset}input:-webkit-autofill,input:-webkit-autofill:active,input:-webkit-autofill:focus,input:-webkit-autofill:hover{-webkit-transition:all 50000s ease-in-out 0s;transition:all 50000s ease-in-out 0s}');const kn=({children:e})=>{const{darkMode:t}=on();return $t(Ut,{theme:Sn(t),children:e})},En={100:"FF","099":"FC","098":"FA","097":"F7","096":"F5","095":"F2","094":"F0","093":"ED","092":"EB","091":"E8","090":"E6","089":"E3","088":"E0","087":"DE","086":"DB","085":"D9","084":"D6","083":"D4","082":"D1","081":"CF","080":"CC","079":"C9","078":"C7","077":"C4","076":"C2","075":"BF","074":"BD","073":"BA","072":"B8","071":"B5","070":"B3","069":"B0","068":"AD","067":"AB","066":"A8","065":"A6","064":"A3","063":"A1","062":"9E","061":"9C","060":"99","059":"96","058":"94","057":"91","056":"8F","055":"8C","054":"8A","053":"87","052":"85","051":"82","050":"80","049":"7D","048":"7A","047":"78","046":"75","045":"73","044":"70","043":"6E","042":"6B","041":"69","040":"66","039":"63","038":"61","037":"5E","036":"5C","035":"59","034":"57","033":"54","032":"52","031":"4F","030":"4D","029":"4A","028":"47","027":"45","026":"42","025":"40","024":"3D","023":"3B","022":"38","021":"36","020":"33","019":"30","018":"2E","017":"2B","016":"29","015":"26","014":"24","013":"21","012":"1F","011":"1C","010":"1A","009":"17","008":"14","007":"12","006":"0F","005":"0D","004":"0A","003":"08","002":"05","001":"03","000":"00"};var An=Object.freeze({__proto__:null,hex:En});const Dn={in:{left:jt`
|
|
137
|
+
from { transform: translateX(-100%); }
|
|
138
|
+
to { transform: translateX(0); }
|
|
139
|
+
`,right:jt`
|
|
140
|
+
from { transform: translateX(100%); }
|
|
141
|
+
to { transform: translateX(0); }
|
|
142
|
+
`,top:jt`
|
|
143
|
+
from { transform: translateY(-100%); }
|
|
144
|
+
to { transform: translateY(0); }
|
|
145
|
+
`,bottom:jt`
|
|
146
|
+
from { transform: translateY(100%); }
|
|
147
|
+
to { transform: translateY(0); }
|
|
148
|
+
`,center:jt`
|
|
149
|
+
from { transform: translate(-50%, 100%); }
|
|
150
|
+
to { transform: translate(-50%, -50%); }
|
|
151
|
+
`},out:{left:jt`
|
|
152
|
+
from { transform: translateX(0); }
|
|
153
|
+
to { transform: translateX(-100%); }
|
|
154
|
+
`,right:jt`
|
|
155
|
+
from { transform: translateX(0); }
|
|
156
|
+
to { transform: translateX(100%); }
|
|
157
|
+
`,top:jt`
|
|
158
|
+
from { transform: translateY(0); }
|
|
159
|
+
to { transform: translateY(-100%); }
|
|
160
|
+
`,bottom:jt`
|
|
161
|
+
from { transform: translateY(0); }
|
|
162
|
+
to { transform: translateY(100%); }
|
|
163
|
+
`,center:jt`
|
|
164
|
+
from { transform: translate(-50%, -50%); }
|
|
165
|
+
to { transform: translate(-50%, 100%); }
|
|
166
|
+
`}},Tn={in:jt`
|
|
167
|
+
from {
|
|
168
|
+
width: 0%;
|
|
169
|
+
}
|
|
170
|
+
to {
|
|
171
|
+
width: 100%;
|
|
172
|
+
}
|
|
173
|
+
`,out:jt`
|
|
174
|
+
from {
|
|
175
|
+
width: 100%;
|
|
176
|
+
}
|
|
177
|
+
to {
|
|
178
|
+
width: 0%;
|
|
179
|
+
}
|
|
180
|
+
`},Nn=jt`
|
|
181
|
+
0% {
|
|
182
|
+
transform: scale(1);
|
|
183
|
+
opacity: 1;
|
|
184
|
+
}
|
|
185
|
+
75%, 100% {
|
|
186
|
+
transform: scale(2);
|
|
187
|
+
opacity: 0;
|
|
188
|
+
}
|
|
189
|
+
`,In=jt`
|
|
190
|
+
0% {
|
|
191
|
+
background-position: -500px 0;
|
|
192
|
+
}
|
|
193
|
+
100% {
|
|
194
|
+
background-position: 500px 0;
|
|
195
|
+
}
|
|
196
|
+
`,_n={in:jt`
|
|
197
|
+
from {
|
|
198
|
+
opacity: 0;
|
|
199
|
+
}
|
|
200
|
+
to {
|
|
201
|
+
opacity: 1;
|
|
202
|
+
}
|
|
203
|
+
`,out:jt`
|
|
204
|
+
from {
|
|
205
|
+
opacity: 1;
|
|
206
|
+
}
|
|
207
|
+
to {
|
|
208
|
+
opacity: 0;
|
|
209
|
+
}
|
|
210
|
+
`};var On=Object.freeze({__proto__:null,fade:_n,ping:Nn,progress:Tn,shimmer:In,slide:Dn});const Rn=Pt.span`
|
|
211
|
+
display: flex;
|
|
212
|
+
align-items: center;
|
|
213
|
+
justify-content: center;
|
|
214
|
+
|
|
215
|
+
min-height: 16px;
|
|
216
|
+
min-width: 16px;
|
|
217
|
+
width: fit-content;
|
|
218
|
+
padding: 4px;
|
|
219
|
+
gap: 2px;
|
|
220
|
+
|
|
221
|
+
border-radius: 50px;
|
|
222
|
+
border: 1px solid ${({theme:e,$filled:t,$status:o})=>o?e.text[o]+(t?"":En["050"]):t?"transparent":e.colors.border};
|
|
223
|
+
background-color: ${({theme:e,$filled:t,$status:o})=>t?o?e.colors[o]:e.colors.majestic_blue:"transparent"};
|
|
224
|
+
color: ${({theme:e,$filled:t,$status:o})=>t&&o?e.text.secondary:t?e.text.white:o?e.text[o]:e.text.grey};
|
|
225
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
226
|
+
font-size: 12px;
|
|
227
|
+
white-space: nowrap;
|
|
228
|
+
|
|
229
|
+
${({theme:e,$filled:t,$status:o,$clickable:r})=>r&&`&:hover {\n cursor: pointer;\n background-color: ${o?e.colors[o]+En["020"]:t?e.colors.majestic_blue_soft:e.colors.secondary+En["020"]};\n }`}
|
|
230
|
+
`,Fn=({label:e,filled:t,status:o,withIcon:r,onClick:i})=>{const n=Bt(),a=o&&r?jr(o,n):null;return vt(Rn,{$filled:t,$status:o,$clickable:!!i,onClick:i,children:[!!a&&$t(a,{}),e]})},zn=Pt.div`
|
|
231
|
+
height: fit-content;
|
|
232
|
+
border: 2px solid transparent;
|
|
233
|
+
padding: 2px;
|
|
234
|
+
border-radius: 32px;
|
|
235
|
+
background-color: transparent;
|
|
236
|
+
transition: border-color 0.3s ease;
|
|
237
|
+
&:focus-within {
|
|
238
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
239
|
+
}
|
|
240
|
+
`,Ln={primary:Mt`
|
|
241
|
+
border: 1px solid ${({theme:e})=>e.text.secondary+En["024"]};
|
|
242
|
+
background: ${({theme:e})=>e.colors.secondary};
|
|
243
|
+
color: ${({theme:e})=>e.colors.primary};
|
|
244
|
+
&:hover {
|
|
245
|
+
background: ${({theme:e})=>e.colors.secondary+En["080"]};
|
|
246
|
+
}
|
|
247
|
+
&:active {
|
|
248
|
+
background: ${({theme:e})=>e.text.secondary+En["060"]};
|
|
249
|
+
}
|
|
250
|
+
`,secondary:Mt`
|
|
251
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
252
|
+
background: ${({theme:e})=>e.colors.primary};
|
|
253
|
+
color: ${({theme:e})=>e.colors.secondary};
|
|
254
|
+
&:hover {
|
|
255
|
+
border: 1px solid ${({theme:e})=>e.text.darker_grey};
|
|
256
|
+
background: ${({theme:e})=>e.colors.secondary+En["010"]};
|
|
257
|
+
}
|
|
258
|
+
&:active {
|
|
259
|
+
border: 1px solid ${({theme:e})=>e.text.dark_grey};
|
|
260
|
+
background: ${({theme:e})=>e.colors.secondary+En["015"]};
|
|
261
|
+
}
|
|
262
|
+
`,tertiary:Mt`
|
|
263
|
+
border-color: transparent;
|
|
264
|
+
background: transparent;
|
|
265
|
+
&:hover {
|
|
266
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2+En["040"]};
|
|
267
|
+
}
|
|
268
|
+
&:active {
|
|
269
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
270
|
+
}
|
|
271
|
+
`,danger:Mt`
|
|
272
|
+
border-color: transparent;
|
|
273
|
+
background: ${({theme:e})=>e.text.error};
|
|
274
|
+
&:hover {
|
|
275
|
+
background: ${({theme:e})=>e.text.error+En["090"]};
|
|
276
|
+
}
|
|
277
|
+
&:active {
|
|
278
|
+
background: ${({theme:e})=>e.text.error+En["080"]};
|
|
279
|
+
}
|
|
280
|
+
`,warning:Mt`
|
|
281
|
+
border-color: transparent;
|
|
282
|
+
background: ${({theme:e})=>e.text.warning};
|
|
283
|
+
&:hover {
|
|
284
|
+
background: ${({theme:e})=>e.text.warning+En["090"]};
|
|
285
|
+
}
|
|
286
|
+
&:active {
|
|
287
|
+
background: ${({theme:e})=>e.text.warning+En["080"]};
|
|
288
|
+
}
|
|
289
|
+
`},Pn=Pt.button`
|
|
290
|
+
height: 36px;
|
|
291
|
+
border-radius: 32px;
|
|
292
|
+
cursor: pointer;
|
|
293
|
+
display: flex;
|
|
294
|
+
align-items: center;
|
|
295
|
+
justify-content: center;
|
|
296
|
+
gap: 8px;
|
|
297
|
+
padding: 0 12px;
|
|
298
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
299
|
+
text-transform: uppercase;
|
|
300
|
+
text-decoration: underline;
|
|
301
|
+
font-weight: 600;
|
|
302
|
+
outline: none;
|
|
303
|
+
${({$variant:e})=>e&&Ln[e]}
|
|
304
|
+
${({disabled:e,$variant:t})=>e&&Mt`
|
|
305
|
+
opacity: 0.5;
|
|
306
|
+
cursor: not-allowed;
|
|
307
|
+
|
|
308
|
+
${"primary"===t?Mt`
|
|
309
|
+
color: ${({theme:e})=>e.colors.secondary};
|
|
310
|
+
background: ${({theme:e})=>e.text.secondary+En["010"]};
|
|
311
|
+
&:hover {
|
|
312
|
+
background: ${({theme:e})=>e.text.secondary+En["015"]};
|
|
313
|
+
}
|
|
314
|
+
`:""}
|
|
315
|
+
`}
|
|
316
|
+
`,Mn=({children:e,variant:t="primary",onClick:o,...r})=>{const i=At(null);return $t(zn,{$variant:t,children:$t(Pn,{ref:i,$variant:t,onClick:e=>{o&&o(e),i.current?.blur()},...r,children:e})})},Bn=e=>{function t(){return void 0===e?{}:so(e)}const[o,r]=kt(t()),[i,n]=kt({}),a=Dt((e,t)=>{const o={};if(!t||"object"!=typeof t)return e?{...e}:o;for(const[r,i]of Object.entries(e)){const e=r;if(Array.isArray(i)){const r=t[e];Array.isArray(r)&&i.length===r.length&&i.every((e,t)=>"object"==typeof e&&null!==e?0===Object.keys(a(e,r[t])).length:e===r[t])||(o[e]=t[e])}else if("object"==typeof i&&null!==i)if(null==t[e]||"object"!=typeof t[e])o[e]=t[e];else{const r=a(i,t[e]);Object.keys(r).length>0&&(o[e]=r)}else i!==t[e]&&(o[e]=t[e])}return o},[]),s=(e,t)=>0===Object.keys(a(e,t)).length,l=Ct(()=>void 0!==e&&!s(e,o),[e,o]);Et(()=>{const i=t();void 0!==e&&"{}"===JSON.stringify(o)&&"{}"!==JSON.stringify(i)&&r(i)},[e,o]);const c=Dt((e,t)=>lo("formData"===e?o:i,t.toString()),[o,i]);return{formData:o,formErrors:i,getFormDiff:a,areFormValuesEqual:s,isFormDirty:l,handleFormChange:(e,t,o)=>{if(e){const o=e.toString().split(".");1===o.length?r(o=>({...o,[e]:t})):r(e=>{const r=so(e);let i=r;for(let e=0;e<o.length-1;e++){const t=o[e];i[t]&&"object"==typeof i[t]||(i[t]={}),i=i[t]}return i[o[o.length-1]]=t,r})}else o&&r({...o})},handleErrorChange:(e,t,o)=>{if(e){const o=e.toString().split(".");1===o.length?n(o=>({...o,[e]:t})):n(e=>{const r=so(e);let i=r;for(let e=0;e<o.length-1;e++){const t=o[e];i[t]&&"object"==typeof i[t]||(i[t]={}),i=i[t]}return i[o[o.length-1]]=t,r})}else o&&n({...o})},resetFormData:e=>{r(e||t()),n({})},getNestedValue:c}},Un={type:"",name:"",notes:"",signals:[],disabled:!1,fields:{clusterAttributes:null,overwriteExistingValues:null,renames:null,attributeNamesToDelete:null,piiCategories:null,fallbackSamplingRatio:null,samplingPercentage:null,endpointsFilters:null,servicesNameFilters:null,attributeFilters:null,urlTemplatizationRulesGroups:null}},jn=()=>{const{addNotification:e}=pn(),{formData:t,formErrors:o,handleFormChange:r,handleErrorChange:i,resetFormData:n}=Bn(Un),a=e=>e&&Array.isArray(e)?e.map(e=>!e.fromSources?.length&&e.from?{...e,fromSources:[e.from]}:e):e;return{formData:t,formErrors:o,handleFormChange:r,resetFormData:n,validateForm:o=>{const r={};let n=!0;if(Object.entries(t).forEach(([e,t])=>{switch(e){case"type":case"signals":Yr(t)&&(r[e]=ur.FIELD_IS_REQUIRED)}}),t.type===go.URLTemplatization){const e=t.fields?.urlTemplatizationRulesGroups;if(e)for(const t of e)if(t.templatizationRules?.some(e=>!e.template?.trim())){r.fields=ur.FIELD_IS_REQUIRED;break}}return n=!Object.values(r).length,!n&&o?.withAlert&&e({type:Oo.Warning,title:o.alertTitle,message:ur.REQUIRED_FIELDS,hideFromHistory:!0}),i(void 0,void 0,r),n},loadFormWithDrawerItem:({type:e,signals:t,name:o,notes:i,disabled:n,fields:s})=>{const l={...so(Un),type:e,signals:t,name:o,notes:i,disabled:n};Object.entries(s).forEach(([e,t])=>{if(t)switch(e){case fo.LabelsAttributes:case fo.AnnotationsAttributes:l.fields||(l.fields={}),l.fields[e]=a(t);break;case fo.CollectContainerAttributes:case fo.CollectReplicaSetAttributes:case fo.CollectWorkloadId:case fo.CollectClusterId:case fo.ClusterAttributes:case fo.OverwriteExistingValues:case fo.AttributeNamesToDelete:case fo.Renames:case fo.PiiCategories:case fo.FallbackSamplingRatio:case fo.SamplingPercentage:case fo.EndpointsFilters:case fo.ServicesNameFilters:case fo.AttributeFilters:case fo.UrlTemplatizationRulesGroups:l.fields||(l.fields={}),l.fields[e]=t}}),r(void 0,void 0,l)}}},Wn=e=>{Et(()=>{if(e){const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}},[e])},Gn=()=>{const{setCurrentModal:e}=dn(),{setDrawerType:t,setDrawerEntityId:o}=an(),{setActiveNodeType:r,setActiveNodeId:i,activeNodeId:n}=Gi();return{onClickNode:(a,s)=>{const{id:l,type:c,data:{id:d,type:p}}=s;switch(n===l?(r(null),i(null)):(r(c),i(l)),p){case To.Source:case To.Destination:case To.Action:case To.InstrumentationRule:t(p),o(d);break;case Bo.AddSource:e(To.Source);break;case Bo.AddDestination:e(To.Destination);break;case Bo.AddAction:e(To.Action);break;case Bo.AddRule:e(To.InstrumentationRule)}}}},Vn=()=>{const{setDrawerType:e,setDrawerEntityId:t}=an(),{markAsDismissed:o,markAsSeen:r}=pn();return{onClickNotification:(i,n)=>{const{id:a,crdType:s,target:l}=i,{dismissToast:c}=n||{};if(s&&l)switch(s){case To.InstrumentationRule:e(To.InstrumentationRule),t(Ir(l,To.InstrumentationRule));break;case To.Source:case"InstrumentationConfig":case"InstrumentationInstance":e(To.Source),t(Ir(l,To.Source));break;case To.Action:e(To.Action),t(Ir(l,To.Action));break;case To.Destination:case"Destination":e(To.Destination),t(Ir(l,To.Destination))}r(a),c&&o(a)}}},Xn=()=>{const e=At(null),[t,o]=kt(0),[r,i]=kt(0);return Et(()=>{const t=()=>{if(e.current){const{width:t,height:r}=e.current.getBoundingClientRect();o(t),i(r)}};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[]),{containerRef:e,containerWidth:t,containerHeight:r}};var Hn;!function(e){e[e.XS=16]="XS",e[e.S=18]="S",e[e.M=24]="M",e[e.L=32]="L"}(Hn||(Hn={}));const Jn=Pt.div`
|
|
317
|
+
width: ${({$size:e})=>1.5*e}px;
|
|
318
|
+
height: ${({$size:e})=>1.5*e}px;
|
|
319
|
+
display: flex;
|
|
320
|
+
align-items: center;
|
|
321
|
+
justify-content: center;
|
|
322
|
+
border-radius: 100%;
|
|
323
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
324
|
+
&:hover {
|
|
325
|
+
background: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
326
|
+
}
|
|
327
|
+
`,Kn=({icon:e,size:t=Hn.S,onClick:o,disabled:r})=>$t(Jn,{$size:t,$disabled:r,onClick:e=>{o&&!r&&(e.stopPropagation(),o(e))},children:$t(e,{size:t})}),qn=({onDone:e}={})=>{const[t,o]=kt(!1),[r,i]=kt(-1),n=Dt(async(r,n)=>{if(!t){if(o(!0),void 0!==n&&i(n),navigator?.clipboard&&navigator.clipboard.writeText)try{await navigator.clipboard.writeText(r)}catch(e){}else{const e=document.createElement("textarea");e.value=r,document.body.appendChild(e),e.select();try{document.execCommand("copy")}catch(e){}document.body.removeChild(e)}e?.(),setTimeout(()=>{o(!1),i(-1)},1e3)}},[t,e]);return{CopyButton:Dt(({value:e,size:o})=>$t(Kn,{icon:t?Je:Ke,size:o,onClick:()=>n(e)}),[t]),isCopied:t,copiedIndex:r,clickCopy:n}},Yn=e=>{const{addNotification:t}=pn(),{formData:o,handleFormChange:r,formErrors:i,handleErrorChange:n,resetFormData:a}=Bn(e);return{formData:o,formErrors:i,handleFormChange:r,resetFormData:a,validateForm:e=>{const r={};let i=!0;return o.name?Qr(o.name)?r.name=void 0:(i=!1,r.name=ur.ILLEGAL_K8S_LABEL):(i=!1,r.name=ur.FIELD_IS_REQUIRED),!i&&e?.withAlert&&t({type:Oo.Warning,title:e.alertTitle,message:ur.REQUIRED_FIELDS,hideFromHistory:!0}),n(void 0,void 0,r),i},loadFormWithDrawerItem:({name:t})=>{const o={...so(e),name:t};r(void 0,void 0,o)}}},Qn={type:"",name:"",exportedSignals:{logs:!1,metrics:!1,traces:!1},fields:[],disabled:!1},Zn=e=>{const{supportedSignals:t,preLoadedFields:o}=e||{},{addNotification:r}=pn(),{formData:i,formErrors:n,handleFormChange:a,handleErrorChange:s,resetFormData:l}=Bn(Qn),[c,d]=kt([]),[p,u]=kt([]);Et(()=>{var e;u(c?(e=c,e.filter(e=>!!e).map(e=>{const{name:t,componentType:o,componentProperties:r,displayName:i,initialValue:n,renderCondition:a}=e;if(o===Io.Dropdown){const e=Jr(r,{}),s=Array.isArray(e.values)?e.values.map(e=>({id:e,value:e})):Object.entries(e.values).map(([e,t])=>({id:e,value:t}));return{name:t,componentType:o,title:i,value:n,placeholder:e.placeholder||"Select an option",options:s,renderCondition:a,...e}}return{name:t,componentType:o,title:i,value:n,renderCondition:a,...Jr(r,{})}})).map(e=>{if(o){const t="string"==typeof o?Jr(o,{}):o;if(e.name in t)return{...e,value:t[e.name]}}return e}):[])},[c,o]),Et(()=>{if(p){const e=p.map(e=>({key:e.name,value:e.value}));a("fields",e)}},[p]),Et(()=>{if(t&&0===si(i.exportedSignals).length){const{logs:e,metrics:o,traces:r}=t;a("exportedSignals",{logs:e.supported,metrics:o.supported,traces:r.supported})}},[t,i.exportedSignals]);return{formData:i,formErrors:n,handleFormChange:a,resetFormData:l,validateForm:e=>{const t={};let o=!0;return p.forEach(({name:e,value:r,required:i})=>{i&&!r&&(o=!1,t[e]=ur.FIELD_IS_REQUIRED)}),!o&&e?.withAlert&&r({type:Oo.Warning,title:e.alertTitle,message:ur.REQUIRED_FIELDS,hideFromHistory:!0}),s(void 0,void 0,t),o},loadFormWithDrawerItem:({destinationType:{type:e},name:t,disabled:o,exportedSignals:r,fields:i})=>{const n={...so(Qn),type:e,name:t,disabled:o,exportedSignals:r,fields:Object.entries(Jr(i,{})).map(([e,t])=>({key:e,value:t}))};return a(void 0,void 0,n),n},yamlFields:c,setYamlFields:d,dynamicFields:p,setDynamicFields:u}},ea={ruleName:"",notes:"",disabled:!1,workloads:null,instrumentationLibraries:null,payloadCollection:{[Ko.HttpRequest]:null,[Ko.HttpResponse]:null,[Ko.DbQuery]:null,[Ko.Messaging]:null},codeAttributes:{[Xo.Column]:null,[Xo.FilePath]:null,[Xo.Function]:null,[Xo.LineNumber]:null,[Xo.Namespace]:null,[Xo.StackTrace]:null},headersCollection:null,customInstrumentations:{[Jo.Java]:null,[Jo.Golang]:null}},ta=()=>{const{formData:e,formErrors:t,handleFormChange:o,handleErrorChange:r,resetFormData:i}=Bn(ea);return{formData:e,formErrors:t,handleFormChange:o,resetFormData:i,validateForm:()=>(r(void 0,void 0,{}),!0),loadFormWithDrawerItem:({ruleName:e,notes:t,disabled:r,payloadCollection:i,codeAttributes:n,headersCollection:a,customInstrumentations:s})=>{const l={...so(ea),ruleName:e,notes:t,disabled:r};i&&(l.payloadCollection={[Ko.HttpRequest]:i[Ko.HttpRequest]?{}:null,[Ko.HttpResponse]:i[Ko.HttpResponse]?{}:null,[Ko.DbQuery]:i[Ko.DbQuery]?{}:null,[Ko.Messaging]:i[Ko.Messaging]?{}:null}),n&&(l.codeAttributes={[Xo.Column]:n[Xo.Column]||null,[Xo.FilePath]:n[Xo.FilePath]||null,[Xo.Function]:n[Xo.Function]||null,[Xo.LineNumber]:n[Xo.LineNumber]||null,[Xo.Namespace]:n[Xo.Namespace]||null,[Xo.StackTrace]:n[Xo.StackTrace]||null}),a&&(l.headersCollection=a),s&&(l.customInstrumentations={[Jo.Java]:s[Jo.Java]||null,[Jo.Golang]:s[Jo.Golang]||null}),o(void 0,void 0,l)}}},oa=({active:e,key:t,withAltKey:o,withCtrlKey:r,withShiftKey:i,withMetaKey:n},a)=>(Et(()=>{const s=s=>{e&&t===s.key&&(!o||o&&s.altKey)&&(!r||r&&s.ctrlKey)&&(!i||i&&s.shiftKey)&&(!n||n&&s.metaKey)&&(s.preventDefault(),s.stopPropagation(),a(s))};return window.addEventListener("keydown",s),()=>{window.removeEventListener("keydown",s)}},[t,e,o,r,i,n,a]),null),ra=(e,t)=>{Et(()=>{const o=o=>{e.current&&!e.current.contains(o.target)&&t()};return document.addEventListener("mousedown",o),document.addEventListener("touchstart",o),()=>{document.removeEventListener("mousedown",o),document.removeEventListener("touchstart",o)}},[e,t])},ia=({defaultClientHeight:e=0,defaultClientwidth:t=0,onClickOutside:o}={})=>{const r=At(null),[i,n]=kt(!1),[a,s]=kt({top:0,left:0});ra(r,()=>{i&&(n(!1),o?.())});return{popupRef:r,popupOpen:i,setPopupOpen:n,popupPosition:a,handlePosition:(o,i)=>{const{innerWidth:n,innerHeight:a}=window;let l=i,c=o;l>=a/2&&(l+=-(r.current?.clientHeight||e)),c>=n/2&&(c+=-(r.current?.clientWidth||t)),s({top:l,left:c})}}},na=()=>({getItemSS:(e,t)=>{const o=sessionStorage.getItem(e);return o?Jr(o,t):t},setItemSS:(e,t)=>{sessionStorage.setItem(e,JSON.stringify(t))},removeItemSS:e=>{sessionStorage.removeItem(e)}}),aa={otelServiceName:"",currentStreamName:""},sa=()=>{const{formData:e,formErrors:t,handleFormChange:o,handleErrorChange:r,resetFormData:i}=Bn(aa);return{formData:e,formErrors:t,handleFormChange:o,resetFormData:i,validateForm:()=>(r(void 0,void 0,{}),!0),loadFormWithDrawerItem:({otelServiceName:e,name:t})=>{const r={...so(aa),otelServiceName:e||t||""};o(void 0,void 0,r)}}},la=Nt({platformType:ko.K8s,tier:Co.Community,version:"v0.0.0"}),ca=({children:e,platformType:t,tier:o,version:r})=>{const i=Ct(()=>({platformType:t,tier:o,version:r}),[t,o,r]);return $t(la.Provider,{value:i,children:e})},da=(e,t)=>!t||fi(e)>=fi(t),pa=e=>{const t=Tt(la),o=da(t.version,e),r=t.platformType===ko.Vm;return{...t,isVersionSupported:o,isVm:r}},ua=Nt({formType:void 0}),ha=({children:e,formType:t})=>{const o=Ct(()=>({formType:t}),[t]);return $t(ua.Provider,{value:o,children:e})},ma=()=>Tt(ua),ga=new Set([jo.StaticPod]),fa=e=>{const t=e.workloads.filter(({selected:e})=>e).length,o=e.workloads.length;return{selectedCount:t,isAllSourced:t>0&&t===o,isSomeSourced:t>0&&t<o,isFutureApps:e.selected||!1}},xa=(e,t,o)=>{if(t&&!e.name.toLowerCase().includes(t.toLowerCase()))return!1;if(o.showOnlySelected){const{isAllSourced:t,isSomeSourced:o,isFutureApps:r}=fa(e);return t||o||r}return!0},ya=(e,t,o)=>!(t&&!e.name.toLowerCase().includes(t.toLowerCase()))&&(!o.showOnlySelected||e.selected),ba=(e,t,o)=>{const r=!!e.dataStreamNames?.length||!!e.currentStreamName?.length,i=r&&e.dataStreamNames?.includes(t)||e.currentStreamName===t,n=e.selected&&(!r||i)||!1;return{namespace:e.namespace,name:e.name,kind:e.kind,selected:n,numberOfInstances:e.numberOfInstances}},$a=(e,t,o)=>({...ba(e,t),currentStreamName:t}),va=(e,t,o)=>{const r="boolean"==typeof o,i=e.dataStreamNames?.includes(t),n=(r?o:e.selected)||!1;return{namespace:e.name,selected:!(!i&&!r)&&n,currentStreamName:t}},wa=e=>{const{fetchNamespacesWithWorkloads:t}=e,{tier:o}=pa(),r=e=>o!==Co.Onprem&&ga.has(e),{selectedStreamName:i}=nn(),{namespaces:n,addEntities:a}=sn(),[s,l]=kt(!1),[c,d]=kt({}),[p,u]=kt(!1),[h,m]=kt(""),[g,f]=kt({}),[x,y]=kt({}),[b,$]=kt(""),[v,w]=kt(To.Source),[S,C]=kt(!1),[k,E]=kt(!1),A=Ct(()=>{const e=(e,t)=>!b||v!==t||v===t&&e.toLowerCase().includes(b),t={};return Object.entries(x).filter(([t])=>e(t,To.Namespace)).forEach(([o,r])=>{const i=r.filter(t=>{return e(t.name,To.Source)&&(o=t,!S||o.selected)&&(e=>!k||(e.numberOfInstances||0)>0)(t);var o});(!b||b&&(v===To.Namespace||v===To.Source&&i.length))&&(t[o]=i)}),t},[x,b,v,S,k]);return Et(()=>{(async()=>{l(!0);const e=await t();l(!1);const o=e.data;if(!o?.length)return;const r=[...o].sort((e,t)=>e.name.localeCompare(t.name)),n={},s={},c={};for(const e of r){const t=[...e.sources||[]].sort((e,t)=>e.name.localeCompare(t.name));n[e.name]=t.map(e=>ba(e,i)),s[e.name]=t.map(e=>$a(e,i)),c[e.name]=va(e,i)}a(To.Namespace,o.map(({sources:e,...t})=>t));const{configuredSources:p,configuredFutureApps:u}=bn.getState();Object.entries(p).forEach(([e,t])=>{s[e]&&t.forEach(t=>{const o=s[e].findIndex(e=>e.name===t.name&&e.kind===t.kind);-1!==o&&(s[e][o]={...s[e][o],selected:t.selected,currentStreamName:t.currentStreamName})})}),Object.entries(u).forEach(([e,t])=>{c[e]&&(c[e]=t)}),d(n),y(s),f(c)})()},[i]),{loading:s,availableSources:c,filteredNamespacesAndSources:A,getApiSourcesPayload:()=>{const e={};return Object.entries(x).forEach(([t,o])=>{o.forEach(o=>{const r=c[t]?.find(e=>e.name===o.name&&e.kind===o.kind);r?.selected!==o.selected&&(e[t]||(e[t]=[]),e[t].push(o))})}),e},getApiFutureAppsPayload:()=>{const e={};return Object.entries(g).forEach(([t,o])=>{const r=n?.find(e=>e.name===t);(o.selected&&!r?.dataStreamNames?.includes(i)||!o.selected&&r?.dataStreamNames?.includes(i))&&(e[t]=o)}),e},selectedNamespace:h,onSelectNamespace:(e,t)=>{if(n.find(t=>t.name===e)){const o="boolean"==typeof t;m(t=>t!==e||o?e:""),o&&(y(o=>({...o,[e]:(o[e]||[]).map(e=>t&&r(e.kind)?e:{...e,selected:t,currentStreamName:i})})),u(!1))}},selectedAllNamespaces:p,onSelectAllNamespaces:e=>{u(e),y(t=>{const o={};for(const[n,a]of Object.entries(t))o[n]=a.map(t=>e&&r(t.kind)?t:{...t,selected:e,currentStreamName:i});return o})},selectedSources:x,onSelectSource:(e,t)=>{const o=t||h;if(!o)return;if(r(e.kind))return;const n=[...x[o]||[]],a=n.findIndex(({name:t,kind:o})=>t===e.name&&o===e.kind);if(-1!==a){const e={...n[a],selected:!n[a].selected,currentStreamName:i};n[a]=e}else n.push({...e,selected:!0,currentStreamName:i});y(e=>({...e,[o]:n})),u(!1)},selectedFutureApps:g,onSelectFutureApps:(e,t)=>{const o=t||h;if(!o)return;const r=n.find(e=>e.name===t);r&&f(t=>({...t,[o]:va(r,i,e)}))},searchText:b,setSearchText:$,searchBy:v,setSearchBy:w,showSelectedOnly:S,setShowSelectedOnly:C,showRunningOnly:k,setShowRunningOnly:E}};try{Ot.addDefaultLocale(Lt)}catch(e){}const Sa=()=>{const e=At(new Ot(Lt.locale));return{formatTimeAgo:Dt(t=>{try{return"string"==typeof t&&(t=t.replace("t","T").replace("z","Z")),e.current.format(new Date(t))}catch(e){return"-"}},[])}},Ca=Pt.div`
|
|
328
|
+
flex: 1;
|
|
329
|
+
align-self: stretch;
|
|
330
|
+
display: flex;
|
|
331
|
+
flex-direction: column;
|
|
332
|
+
gap: 24px;
|
|
333
|
+
overflow-x: scroll;
|
|
334
|
+
|
|
335
|
+
max-height: calc(100vh - 24px - ${({$heightOffset:e})=>e||0}px);
|
|
336
|
+
padding: 24px 24px 0 24px;
|
|
337
|
+
`,ka=Pt.div`
|
|
338
|
+
position: relative;
|
|
339
|
+
|
|
340
|
+
// inherit all the properties of the parent (PageContent)
|
|
341
|
+
flex: inherit;
|
|
342
|
+
align-self: inherit;
|
|
343
|
+
display: inherit;
|
|
344
|
+
flex-direction: inherit;
|
|
345
|
+
gap: inherit;
|
|
346
|
+
overflow-x: inherit;
|
|
347
|
+
`,Ea=Pt.div`
|
|
348
|
+
display: flex;
|
|
349
|
+
flex-direction: row;
|
|
350
|
+
flex-wrap: ${({$wrap:e="unset"})=>e};
|
|
351
|
+
align-items: ${({$alignItems:e="center"})=>e};
|
|
352
|
+
justify-content: ${({$justifyContent:e="unset"})=>e};
|
|
353
|
+
gap: ${({$gap:e=2})=>e}px;
|
|
354
|
+
width: ${({$width:e})=>e||"unset"};
|
|
355
|
+
height: ${({$height:e})=>e||"unset"};
|
|
356
|
+
margin: ${({$margin:e="unset"})=>e};
|
|
357
|
+
padding: ${({$padding:e="unset"})=>e};
|
|
358
|
+
`,Aa=Pt.div`
|
|
359
|
+
display: flex;
|
|
360
|
+
flex-direction: column;
|
|
361
|
+
flex-wrap: ${({$wrap:e="unset"})=>e};
|
|
362
|
+
align-items: ${({$alignItems:e="unset"})=>e};
|
|
363
|
+
justify-content: ${({$justifyContent:e="unset"})=>e};
|
|
364
|
+
gap: ${({$gap:e=2})=>e}px;
|
|
365
|
+
width: ${({$width:e})=>e||"unset"};
|
|
366
|
+
height: ${({$height:e})=>e||"unset"};
|
|
367
|
+
margin: ${({$margin:e="unset"})=>e};
|
|
368
|
+
padding: ${({$padding:e="unset"})=>e};
|
|
369
|
+
`,Da=Pt(Aa)`
|
|
370
|
+
width: ${({$width:e})=>e||"100%"};
|
|
371
|
+
height: ${({$height:e})=>e||"unset"};
|
|
372
|
+
padding: ${({$padding:e})=>e||"unset"};
|
|
373
|
+
align-items: center;
|
|
374
|
+
justify-content: center;
|
|
375
|
+
`,Ta=Pt.div`
|
|
376
|
+
display: flex;
|
|
377
|
+
flex-direction: column;
|
|
378
|
+
padding: 12px;
|
|
379
|
+
overflow-y: scroll;
|
|
380
|
+
`,Na=Pt.div`
|
|
381
|
+
position: ${({$relativeToParent:e})=>e?"absolute":"fixed"};
|
|
382
|
+
top: 0;
|
|
383
|
+
left: 0;
|
|
384
|
+
right: 0;
|
|
385
|
+
bottom: 0;
|
|
386
|
+
z-index: 1000;
|
|
387
|
+
background: rgba(0, 0, 0, 0.6);
|
|
388
|
+
backdrop-filter: blur(2px);
|
|
389
|
+
`,Ia=Pt.div`
|
|
390
|
+
width: 800px;
|
|
391
|
+
min-height: ${({$minHeight:e})=>e||"unset"};
|
|
392
|
+
height: ${({$isNotModal:e})=>e?"fit-content":"calc(100vh - 350px)"};
|
|
393
|
+
margin: ${({$isNotModal:e})=>e?"64px 0 0 0":"64px 7vw 32px 7vw"};
|
|
394
|
+
padding: 0 2px;
|
|
395
|
+
overflow-y: scroll;
|
|
396
|
+
`,_a=Pt(Aa)`
|
|
397
|
+
max-width: ${({$maxWidth:e})=>e||"unset"};
|
|
398
|
+
width: 100%;
|
|
399
|
+
`,Oa=Pt(Ea)`
|
|
400
|
+
gap: 16px;
|
|
401
|
+
padding: 16px;
|
|
402
|
+
`,Ra=Pt.div`
|
|
403
|
+
width: 100%;
|
|
404
|
+
max-height: ${({$maxHeight:e})=>e||"unset"};
|
|
405
|
+
overflow-y: auto;
|
|
406
|
+
`,Fa=Pt.div`
|
|
407
|
+
position: fixed;
|
|
408
|
+
top: 50%;
|
|
409
|
+
left: 50%;
|
|
410
|
+
transform: translate(-50%, -50%);
|
|
411
|
+
z-index: 1000;
|
|
412
|
+
width: fit-content;
|
|
413
|
+
background: ${({theme:e})=>e.colors.translucent_bg};
|
|
414
|
+
border: ${({theme:e})=>`1px solid ${e.colors.border}`};
|
|
415
|
+
border-radius: 40px;
|
|
416
|
+
box-shadow: ${({theme:e})=>{const t=e.colors.primary+En["010"];return`0px 1px 1px 0px ${t}, 0px 2px 2px 0px ${t}, 0px 5px 5px 0px ${t}, 0px 10px 10px 0px ${t}, 0px 0px 8px 0px ${t}`}};
|
|
417
|
+
animation-name: ${Dn.in.center};
|
|
418
|
+
`,za=Pt.div`
|
|
419
|
+
display: flex;
|
|
420
|
+
justify-content: space-between;
|
|
421
|
+
align-items: center;
|
|
422
|
+
height: 80px;
|
|
423
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
424
|
+
padding: 0 24px;
|
|
425
|
+
`,La=Pt.div`
|
|
426
|
+
cursor: pointer;
|
|
427
|
+
display: flex;
|
|
428
|
+
align-items: center;
|
|
429
|
+
gap: 8px;
|
|
430
|
+
`,Pa=Pt.div`
|
|
431
|
+
display: flex;
|
|
432
|
+
align-items: center;
|
|
433
|
+
gap: 8px;
|
|
434
|
+
`,Ma=Pt(Da)`
|
|
435
|
+
min-width: 350px;
|
|
436
|
+
min-height: 150px;
|
|
437
|
+
`,Ba=Pt.div`
|
|
438
|
+
position: absolute;
|
|
439
|
+
left: 50%;
|
|
440
|
+
transform: translateX(-50%);
|
|
441
|
+
display: flex;
|
|
442
|
+
align-items: center;
|
|
443
|
+
justify-content: center;
|
|
444
|
+
width: 100%;
|
|
445
|
+
pointer-events: none;
|
|
446
|
+
`,Ua=Pt(ki)`
|
|
447
|
+
text-transform: uppercase;
|
|
448
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
449
|
+
pointer-events: auto;
|
|
450
|
+
`,ja=Pt(ki)`
|
|
451
|
+
text-transform: uppercase;
|
|
452
|
+
font-weight: 500;
|
|
453
|
+
font-size: 14px;
|
|
454
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
455
|
+
text-decoration: underline;
|
|
456
|
+
cursor: pointer;
|
|
457
|
+
`,Wa=({isOpen:e,noOverlay:t,header:o,actionComponent:r,onClose:i,children:n,closeOnEscape:a=!0})=>(oa({key:"Escape",active:e&&a},()=>i()),Wn(e),e?qt.createPortal(vt(wt,{children:[$t(Na,{hidden:!e,onClick:i,style:{opacity:t?0:1}}),vt(Fa,{"data-id":"modal"+(o?`-${o.title.replaceAll(" ","-")}`:""),children:[o&&vt(za,{children:[vt(La,{onClick:i,children:[$t(qe,{}),$t(ja,{children:"Cancel"})]}),$t(Ba,{children:$t(Ua,{children:o.title})}),$t(Pa,{children:r})]}),$t(Ma,{children:n})]})]}),document.body):null),Ga=Pt.div`
|
|
458
|
+
width: ${({$orientation:e,$thickness:t,$length:o})=>"vertical"===e?`${t}px`:o||"100%"};
|
|
459
|
+
height: ${({$orientation:e,$thickness:t,$length:o})=>"horizontal"===e?`${t}px`:o||"100%"};
|
|
460
|
+
margin: ${({$orientation:e,$margin:t})=>t||("horizontal"===e?"8px 0":"0 8px")};
|
|
461
|
+
background-color: ${({$type:e,theme:t})=>(e?t.text[e]:t.colors.border)+En["050"]};
|
|
462
|
+
opacity: ${({$opacity:e})=>e||1};
|
|
463
|
+
`,Va=({orientation:e="horizontal",type:t,thickness:o=1,length:r,margin:i,opacity:n})=>$t(Ga,{$orientation:e,$type:t,$thickness:o,$length:r,$margin:i,$opacity:n}),Xa=Pt.div`
|
|
464
|
+
position: absolute;
|
|
465
|
+
${({$top:e})=>void 0!==e&&`top: ${e}px;`}
|
|
466
|
+
${({$bottom:e})=>void 0!==e&&`bottom: ${e}px;`}
|
|
467
|
+
${({$left:e})=>void 0!==e&&`left: ${e}px;`}
|
|
468
|
+
${({$right:e})=>void 0!==e&&`right: ${e}px;`}
|
|
469
|
+
z-index: 9999;
|
|
470
|
+
|
|
471
|
+
background-color: ${({theme:e})=>e.colors.info};
|
|
472
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
473
|
+
border-radius: ${({$borderRadius:e})=>void 0!==e?e:"24px"};
|
|
474
|
+
max-width: ${({$maxWidth:e})=>void 0!==e?e:"unset"};
|
|
475
|
+
width: ${({$width:e})=>void 0!==e?e:"unset"};
|
|
476
|
+
|
|
477
|
+
${({$asPortal:e,$withPointerEvents:t})=>e&&!t&&"pointer-events: none;"}
|
|
478
|
+
`,Ha=Pt.div`
|
|
479
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
480
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
481
|
+
`,Ja=Pt.div`
|
|
482
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
483
|
+
`,Ka=Pt.div`
|
|
484
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
485
|
+
border-top: 1px solid ${({theme:e})=>e.colors.border};
|
|
486
|
+
`,qa=It(({isOpen:e,asPortal:t,...o},r)=>{const i=Ct(()=>{const{children:e,top:i,bottom:n,left:a,right:s,borderRadius:l,padding:c,maxWidth:d,width:p,header:u,footer:h,withPointerEvents:m,...g}=o;return vt(Xa,{ref:r,$top:i,$bottom:n,$left:a,$right:s,$borderRadius:l,$padding:c,$maxWidth:d,$width:p,$asPortal:t,$withPointerEvents:m,...g,children:[u&&$t(Ha,{$padding:c,children:u}),$t(Ja,{$padding:c,children:e}),h&&$t(Ka,{$padding:c,children:h})]})},[r,o,t]);return e?t?qt.createPortal(i,document.body):i:null});qa.displayName=qa.name;const Ya=Pt.div`
|
|
487
|
+
width: ${({$fullWidth:e})=>e?"100%":"fit-content"};
|
|
488
|
+
position: relative;
|
|
489
|
+
display: flex;
|
|
490
|
+
align-items: center;
|
|
491
|
+
gap: 4px;
|
|
492
|
+
cursor: help;
|
|
493
|
+
`,Qa=Pt(ki)`
|
|
494
|
+
word-break: break-word;
|
|
495
|
+
white-space: pre-wrap;
|
|
496
|
+
`,Za=({withIcon:e,titleIcon:t,title:o,text:r,timestamp:i,children:n,fullWidth:a=!1})=>{const s=Bt(),{popupRef:l,popupOpen:c,setPopupOpen:d,popupPosition:p,handlePosition:u}=ia({defaultClientHeight:40,defaultClientwidth:Math.min(7.5*(r?.length||0),300)}),h=Ct(()=>!!wi(r||"")?.length,[r]),m=e=>{const{type:t,clientX:o,clientY:r}=e;h?u(p.left||o,p.top||r):u(o,r),d("mouseleave"!==t)};return r?vt(Ya,{$fullWidth:a,onMouseEnter:m,onMouseMove:m,onMouseLeave:m,children:[n,e&&$t(Ue,{fill:s.v2.colors.silver[200]}),vt(qa,{ref:l,isOpen:c,top:p.top,left:p.left,asPortal:!0,withPointerEvents:h,onMouseEnter:h?m:void 0,maxWidth:"270px",borderRadius:"16px",padding:"8px 12px",children:[(!!t||!!o)&&vt(Ea,{style:{marginBottom:"4px"},$gap:4,children:[t&&$t(t,{size:12,fill:s.text.secondary},"icon"),o&&$t(ki,{size:12,color:s.text.secondary,children:o},"title")]}),$t(Qa,{size:12,color:s.text.info,children:r}),!!i&&$t(ki,{size:10,color:s.text.darker_grey,family:"secondary",style:{marginTop:"8px"},children:new Date(i).toLocaleString()})]})]}):$t(wt,{children:n})},es=Pt.button`
|
|
497
|
+
position: relative;
|
|
498
|
+
width: ${({$size:e})=>e}px;
|
|
499
|
+
height: ${({$size:e})=>e}px;
|
|
500
|
+
border: ${({theme:e,$withBorder:t})=>t?`1px solid ${e.colors.border}`:"none"};
|
|
501
|
+
border-radius: 100%;
|
|
502
|
+
background-color: ${({$backgroundColor:e})=>e||"transparent"};
|
|
503
|
+
display: flex;
|
|
504
|
+
align-items: center;
|
|
505
|
+
justify-content: center;
|
|
506
|
+
cursor: pointer;
|
|
507
|
+
&:hover {
|
|
508
|
+
background-color: ${({theme:e,$backgroundColor:t})=>t?t+En["070"]:e.colors.dropdown_bg_2};
|
|
509
|
+
}
|
|
510
|
+
`,ts=Pt.div`
|
|
511
|
+
position: absolute;
|
|
512
|
+
top: ${({$size:e})=>e/5}px;
|
|
513
|
+
right: ${({$size:e})=>e/5}px;
|
|
514
|
+
width: 6px;
|
|
515
|
+
height: 6px;
|
|
516
|
+
border-radius: 100%;
|
|
517
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.secondary};
|
|
518
|
+
|
|
519
|
+
&::after {
|
|
520
|
+
content: '';
|
|
521
|
+
position: absolute;
|
|
522
|
+
inset: 0;
|
|
523
|
+
border-radius: 100%;
|
|
524
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.secondary};
|
|
525
|
+
animation: ${Nn} 1.5s cubic-bezier(0, 0, 0.2, 1) infinite;
|
|
526
|
+
}
|
|
527
|
+
`,os=({children:e,onClick:t,tooltip:o,size:r=36,withPing:i,pingColor:n,withBorder:a,backgroundColor:s,...l})=>$t(Za,{text:o,children:vt(es,{$size:r,$withBorder:a,$backgroundColor:s,onClick:t,...l,children:[i&&$t(ts,{$size:r,$color:n}),e]})}),rs=Pt.div`
|
|
528
|
+
position: relative;
|
|
529
|
+
&.animated {
|
|
530
|
+
overflow: hidden;
|
|
531
|
+
padding-bottom: 1px;
|
|
532
|
+
border-radius: 32px;
|
|
533
|
+
animation: ${({$isLeaving:e})=>e?Dn.out.bottom:Dn.in.bottom} ${({$duration:e})=>e/10}ms forwards;
|
|
534
|
+
}
|
|
535
|
+
`,is=Pt.div`
|
|
536
|
+
position: absolute;
|
|
537
|
+
bottom: -1px;
|
|
538
|
+
left: 0;
|
|
539
|
+
z-index: -1;
|
|
540
|
+
width: 100%;
|
|
541
|
+
height: 100%;
|
|
542
|
+
border-radius: 32px;
|
|
543
|
+
background-color: ${({$type:e,theme:t})=>t.text[e]};
|
|
544
|
+
animation: ${Tn.out} ${({$duration:e})=>""+(e-e/10)}ms forwards;
|
|
545
|
+
`,ns=Pt.div`
|
|
546
|
+
display: flex;
|
|
547
|
+
align-items: center;
|
|
548
|
+
flex: 1;
|
|
549
|
+
gap: 8px;
|
|
550
|
+
padding: 0 12px;
|
|
551
|
+
border-radius: 32px;
|
|
552
|
+
background-color: ${({$type:e,theme:t})=>t.colors[e]};
|
|
553
|
+
`,as=Pt.div`
|
|
554
|
+
display: flex;
|
|
555
|
+
align-items: center;
|
|
556
|
+
margin: 0 auto 0 0;
|
|
557
|
+
padding: 8px 0;
|
|
558
|
+
max-width: ${({$withAction:e,$overrideMaxWidth:t})=>t||(e?"400px":"500px")};
|
|
559
|
+
min-height: 12px;
|
|
560
|
+
`,ss=Pt(ki)`
|
|
561
|
+
font-size: 14px;
|
|
562
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
563
|
+
`,ls=Pt(ki)`
|
|
564
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
565
|
+
font-size: 12px;
|
|
566
|
+
`,cs=Pt(Ea)``,ds=Pt(ki)`
|
|
567
|
+
text-transform: uppercase;
|
|
568
|
+
text-decoration: underline;
|
|
569
|
+
font-size: 12px;
|
|
570
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
571
|
+
white-space: nowrap;
|
|
572
|
+
cursor: pointer;
|
|
573
|
+
&:hover {
|
|
574
|
+
transform: scale(1.1);
|
|
575
|
+
transition: transform 0.3s;
|
|
576
|
+
}
|
|
577
|
+
`,ps=({type:e,icon:t,title:o,message:r,action:i,onClose:n,duration:a=5e3,overrideMaxWidth:s,style:l})=>{const c=Bt(),[d,p]=kt(!1),u=At(null),h=At(null),m=e=>{n&&(p(!0),n({asSeen:e?.asSeen}))};Et(()=>(u.current=setTimeout(()=>m({asSeen:!1}),a),()=>{u.current&&clearTimeout(u.current)}),[a]);const g=t||jr(e,c);return vt(rs,{className:n?"animated":"",$duration:a,$isLeaving:d,onMouseEnter:()=>{u.current&&clearTimeout(u.current),h.current&&(h.current.style.animationPlayState="paused")},onMouseLeave:()=>{if(h.current){const e=h.current.offsetWidth/h.current.parentElement.offsetWidth*a;u.current=setTimeout(()=>m({asSeen:!1}),e),h.current.style.animationPlayState="running"}},children:[vt(ns,{"data-id":"toast",$type:e,style:l,children:[$t(g,{fill:c.text[e]}),vt(as,{$withAction:!!i,$overrideMaxWidth:s,children:[o&&$t(ss,{$type:e,children:o}),o&&r&&$t(Va,{orientation:"vertical",type:e}),r&&$t(ls,{$type:e,children:r})]}),(!!i||!!n)&&vt(cs,{children:[i&&$t(ds,{"data-id":"toast-action",onClick:i.onClick,children:i.label}),n&&$t(os,{"data-id":"toast-close",onClick:()=>m({asSeen:!0}),children:$t(qe,{size:12})})]})]}),n&&$t(is,{ref:h,$duration:a,$type:e})]})},us=Pt.div`
|
|
578
|
+
padding: 24px 32px;
|
|
579
|
+
`,hs=Pt.div`
|
|
580
|
+
padding: ${({$withNote:e})=>e?"12px 0px":"12px 0px 32px 0"};
|
|
581
|
+
`,ms=Pt(ki)`
|
|
582
|
+
font-size: 20px;
|
|
583
|
+
line-height: 28px;
|
|
584
|
+
`,gs=Pt(ki)`
|
|
585
|
+
color: ${({theme:e})=>e.text.grey};
|
|
586
|
+
width: 416px;
|
|
587
|
+
font-style: normal;
|
|
588
|
+
font-weight: 300;
|
|
589
|
+
line-height: 24px;
|
|
590
|
+
`,fs=Pt.div`
|
|
591
|
+
display: flex;
|
|
592
|
+
justify-content: space-between;
|
|
593
|
+
gap: 12px;
|
|
594
|
+
`,xs=Pt(Mn)`
|
|
595
|
+
width: 250px;
|
|
596
|
+
`,ys=Pt.div`
|
|
597
|
+
margin-bottom: 12px;
|
|
598
|
+
`,bs=({isOpen:e,noOverlay:t,title:o="",description:r="",note:i,approveButton:n,denyButton:a,closeOnEscape:s=!0})=>{oa({key:"Enter",active:e&&s},()=>n.onClick());const l=()=>a.onClick();return $t(Wa,{isOpen:e,noOverlay:t,onClose:l,children:vt(us,{children:[$t(ms,{children:o}),$t(hs,{$withNote:!!i,children:$t(gs,{children:r})}),!!i&&$t(ys,{children:$t(ps,{type:i.type,title:i.title,message:i.message})}),vt(fs,{children:[$t(xs,{"data-id":"approve",variant:n.variant||"primary",onClick:()=>n.onClick(),children:n.text}),$t(xs,{"data-id":"deny",variant:a.variant||"secondary",onClick:l,children:a.text})]})]})})},$s=({isOpen:e,noOverlay:t,name:o,onApprove:r,onDeny:i})=>$t(bs,{isOpen:e,noOverlay:t,title:"Cancel"+(o?` ${o}`:""),description:"Are you sure you want to cancel?",approveButton:{text:"Confirm",variant:Oo.Warning,onClick:r},denyButton:{text:"Go Back",onClick:i}}),vs=Pt.div`
|
|
599
|
+
display: flex;
|
|
600
|
+
align-items: center;
|
|
601
|
+
gap: 8px;
|
|
602
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
603
|
+
opacity: ${({$disabled:e})=>e?.6:1};
|
|
604
|
+
`,ws=Pt.div`
|
|
605
|
+
width: 18px;
|
|
606
|
+
height: 18px;
|
|
607
|
+
border-radius: 6px;
|
|
608
|
+
border: 1px dashed ${({$isChecked:e,$isPartiallyChecked:t,theme:o})=>e||t?"transparent":o.colors.secondary};
|
|
609
|
+
display: flex;
|
|
610
|
+
align-items: center;
|
|
611
|
+
justify-content: center;
|
|
612
|
+
background-color: ${({$isChecked:e,$isPartiallyChecked:t,theme:o})=>e?o.colors.majestic_blue:t?o.colors.majestic_blue_soft:o.colors.secondary+En["020"]};
|
|
613
|
+
pointer-events: ${({$disabled:e})=>e?"none":"auto"};
|
|
614
|
+
transition: border 0.3s;
|
|
615
|
+
&:hover {
|
|
616
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
617
|
+
}
|
|
618
|
+
`,Ss=({title:e,titleColor:t,tooltip:o,value:r=!1,partiallyChecked:i=!1,onChange:n,disabled:a,style:s,errorMessage:l,allowPropagation:c=!1})=>{const d=Bt(),[p,u]=kt(r);Et(()=>u(r),[r]);return vt(Aa,{children:[vt(vs,{"data-id":"checkbox"+(e?`-${e}`:""),$disabled:a,onClick:e=>{a||(c||e.stopPropagation(),n?n(!!i||!p):u(e=>!!i||!e))},style:s,children:[$t(ws,{$isChecked:p,$isPartiallyChecked:i,$disabled:a,children:i?$t(Ye,{fill:d.text.white}):p?$t(Je,{fill:d.text.white}):null}),e&&$t(Za,{text:o,withIcon:!0,children:$t(ki,{size:12,color:t||d.text.grey,style:{maxWidth:"90%"},children:e})})]}),!!l&&$t(Di,{children:l})]})},Cs=Pt(Ea)`
|
|
619
|
+
gap: 0;
|
|
620
|
+
`,ks=Pt.button`
|
|
621
|
+
padding: 4px 8px;
|
|
622
|
+
background-color: ${({theme:e,$selected:t})=>t?e.colors.dropdown_bg_2:"transparent"};
|
|
623
|
+
border-radius: ${({$position:e})=>"left"===e?"32px 0px 0px 32px":"right"===e?"0px 32px 32px 0px":"0"};
|
|
624
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
625
|
+
display: flex;
|
|
626
|
+
align-items: center;
|
|
627
|
+
justify-content: center;
|
|
628
|
+
cursor: pointer;
|
|
629
|
+
&:hover {
|
|
630
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
631
|
+
}
|
|
632
|
+
`,Es=({isPrettyMode:e,setIsPrettyMode:t})=>vt(Cs,{children:[$t(ks,{$position:"left",$selected:e,onClick:()=>t(!0),children:$t(Qe,{})}),$t(ks,{$position:"right",$selected:!e,onClick:()=>t(!1),children:$t(Ze,{})})]}),As=Pt.table`
|
|
633
|
+
border-collapse: collapse;
|
|
634
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
635
|
+
`,Ds=Pt.tbody``,Ts=Pt.tr`
|
|
636
|
+
td:first-child {
|
|
637
|
+
padding-left: 0 !important;
|
|
638
|
+
}
|
|
639
|
+
td:last-child {
|
|
640
|
+
padding-right: 0 !important;
|
|
641
|
+
}
|
|
642
|
+
`,Ns=Pt.td`
|
|
643
|
+
vertical-align: top;
|
|
644
|
+
padding: 4px 6px;
|
|
645
|
+
`,Is=Pt(ki)`
|
|
646
|
+
white-space: nowrap;
|
|
647
|
+
`,_s=Pt.span`
|
|
648
|
+
white-space: ${({$noWrap:e})=>e?"nowrap":"pre-wrap"};
|
|
649
|
+
overflow-wrap: break-word;
|
|
650
|
+
word-break: break-word;
|
|
651
|
+
word-wrap: break-word;
|
|
652
|
+
/* Fallback for older browsers */
|
|
653
|
+
-ms-word-break: break-all;
|
|
654
|
+
font-size: 12px;
|
|
655
|
+
`,Os=({language:e,code:t,theme:o,flatten:r,pretty:i})=>{const{darkMode:n}=Bt(),a=o?Zt[o]:n?Zt.palenight:Zt.vsLight;let s="";if("json"===e){const e=Jr(t,{}),o=ui(e);s=hi(r?fr(o):o)}else s=t;return i&&"json"===e?$t(Rs,{darkMode:n,str:s}):$t(Qt,{theme:a||(n?Zt.palenight:Zt.vsLight),language:e,code:s,children:({getLineProps:e,getTokenProps:t,tokens:o})=>$t("pre",{children:o.map((o,r)=>$t("div",{...e({line:o}),children:o.map((e,o)=>$t(_s,{...t({token:e})},`line-${r}-token-${o}`))},`line-${r}`))})})},Rs=({darkMode:e,str:t})=>{const o=Bt(),r=(e,t)=>{const r=new Array(e).fill(e=>vt(Ts,{...e,children:[$t(Ns,{}),$t(Ns,{})]}));return $t(St,{children:r.map((e,r)=>$t(e,{style:0===r?{borderBottom:`1px solid ${o.colors.border}`}:{}},`empty-row-${t}-${r}`))})};return $t(Qt,{theme:e?Zt.palenight:Zt.vsLight,language:"json",code:t,children:({getLineProps:e,getTokenProps:t,tokens:i})=>$t(As,{children:$t(Ds,{children:i.map((i,n)=>{const a=(e=>{const t=["punctuation","plain","operator"];return e.filter(e=>!t.includes(e.types[0])).map(({types:e,content:t})=>{const o=[...e],r=["property","string"].includes(o[0])?t.replace(/"/g,""):t;return"string"===o[0]&&(["true","false"].includes(r.split("@")[0])&&(o[0]="boolean"),r.split("@")[0].match(/^[0-9]+$/)&&(o[0]="number")),{types:o,content:r}})})(i),s=e({line:a});return 1===a.length&&"property"===a[0].types[0]?vt(St,{children:[r(2,n),vt(Ts,{...s,children:[$t(Ns,{children:$t(Is,{children:a[0].content})}),$t(Ns,{})]})]},`line-${n}`):2===a.length?$t(Ts,{...s,children:a.map((e,r)=>{const{text:i,components:a}=((e,t)=>{const[o,...r]=e.split("@");return{text:o,components:r?.map((e,o)=>{if(!e.includes("="))return null;const[r,i]=e.split("=");switch(r){case"tooltip":return $t(Za,{withIcon:!0,text:i},`${r}-${i}-${o}`);case"status":if("none"===i)return $t("div",{style:{width:16,height:16}},`${r}-${i}-${o}`);let e=jr(i,t);return e||(e=jr(Oo.Warning,t)),$t(e,{},`${r}-${i}-${o}`);default:return null}})?.filter(e=>!!e)||[]}})(e.content,o),s=0===r;return $t(Ns,{children:vt(Ea,{children:[$t(Ea,{children:a}),$t(_s,{$noWrap:s,...t({token:e}),children:i})]})},`line-${n}-token-${r}`)})},`line-${n}`):(a.length,null)})})})})},Fs={cm:!0,mm:!0,in:!0,px:!0,pt:!0,pc:!0,em:!0,ex:!0,ch:!0,rem:!0,vw:!0,vh:!0,vmin:!0,vmax:!0,"%":!0};function zs(e){if("number"==typeof e)return{value:e,unit:"px"};let t;const o=(e.match(/^[0-9.]*/)||"").toString();t=o.includes(".")?parseFloat(o):parseInt(o,10);const r=(e.match(/[^0-9]*$/)||"").toString();return Fs[r]?{value:t,unit:r}:{value:t,unit:"px"}}function Ls(e){const t=zs(e);return`${t.value}${t.unit}`}const Ps=((e,t,o)=>{const r=`react-spinners-${e}-${o}`;if("undefined"==typeof window||!window.document)return r;const i=document.createElement("style");document.head.appendChild(i);const n=i.sheet,a=`\n @keyframes ${r} {\n ${t}\n }\n `;return n&&n.insertRule(a,0),r})("FadeLoader","50% {opacity: 0.3} 100% {opacity: 1}","fade"),Ms=({loading:e=!0,color:t,scale:o=1,speedMultiplier:r=1,cssOverride:i={},style:n={},...a})=>{const s=Bt(),l=t||s.text.secondary;if(!e)return null;const{value:c}=zs(2),d=c+4.2,p=d/2+d/5.5,u=4*d*o,h={position:"relative",width:`${u}px`,height:`${u}px`,scale:o,...n,...i},m=(e,t)=>({position:"absolute",width:Ls(1.5),height:Ls(4),borderRadius:Ls(2),backgroundColor:l,transition:"2s",animationFillMode:"both",animation:`${Ps} ${1.2/r}s ${.12*e}s infinite ease-in-out`,transform:`translate(-50%, -50%) rotate(${t}deg)`});return vt("span",{style:h,...a,children:[$t("span",{style:{...m(1,0),top:`calc(50% + ${d}px)`,left:"50%"}}),$t("span",{style:{...m(2,-45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${p}px)`}}),$t("span",{style:{...m(3,90),top:"50%",left:`calc(50% + ${d}px)`}}),$t("span",{style:{...m(4,45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${p}px)`}}),$t("span",{style:{...m(5,0),top:`calc(50% + ${-1*d}px)`,left:"50%"}}),$t("span",{style:{...m(6,-45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${-1*p}px)`}}),$t("span",{style:{...m(7,90),top:"50%",left:`calc(50% + ${-1*d}px)`}}),$t("span",{style:{...m(8,45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${-1*p}px)`}})]})},Bs=Pt.div`
|
|
656
|
+
margin: ${({$align:e})=>"right"===e?"auto 6px auto auto":"left"===e?"auto auto auto 6px":"auto"};
|
|
657
|
+
display: flex;
|
|
658
|
+
align-items: center;
|
|
659
|
+
justify-content: center;
|
|
660
|
+
`,Us=({extend:e,size:t=14,align:o="center"})=>$t(Bs,{$align:o,children:$t(et,{size:t,rotate:e?180:0})}),js=Pt.div`
|
|
661
|
+
border-radius: 24px;
|
|
662
|
+
background-color: ${({theme:e,$status:t})=>t===Oo.Error?e.text.error+En["010"]:t===Oo.Warning?e.text.warning+En["010"]:e.colors.secondary+En["005"]};
|
|
663
|
+
&:hover {
|
|
664
|
+
background-color: ${({theme:e,$status:t})=>t===Oo.Error?e.text.error+En["020"]:t===Oo.Warning?e.text.warning+En["020"]:e.colors.secondary+En["010"]};
|
|
665
|
+
}
|
|
666
|
+
cursor: pointer;
|
|
667
|
+
transition: background 0.3s;
|
|
668
|
+
`,Ws=Pt.div`
|
|
669
|
+
display: flex;
|
|
670
|
+
align-items: center;
|
|
671
|
+
gap: 12px;
|
|
672
|
+
padding: 12px 18px;
|
|
673
|
+
`,Gs=Pt.div`
|
|
674
|
+
display: flex;
|
|
675
|
+
flex-direction: column;
|
|
676
|
+
gap: 8px;
|
|
677
|
+
padding: 6px 18px 12px 18px;
|
|
678
|
+
`,Vs=Pt.div`
|
|
679
|
+
display: flex;
|
|
680
|
+
align-items: center;
|
|
681
|
+
gap: 12px;
|
|
682
|
+
`,Xs=Pt(ki)`
|
|
683
|
+
white-space: nowrap;
|
|
684
|
+
`,Hs=Pt(Aa)`
|
|
685
|
+
width: 16px;
|
|
686
|
+
`,Js=({conditions:e,headerLabelError:t="Something Failed",headerLabelWarning:o="Something isn't right",headerLabelSuccess:r="Everything Successful"})=>{const i=Bt(),[n,a]=kt(!1),s=Ct(()=>ni(e),[e]),{errors:l,hasErrors:c,warnings:d,hasWarnings:p,hasDisableds:u,hasLoadings:h}=Ct(()=>vr(s),[s]);Et(()=>{a(c||p||u)},[c,p,u]);const m=(!s.length||h)&&!c&&!p&&!u,g=c?Oo.Error:p?Oo.Warning:u?Oo.Info:Oo.Success,f=jr(g,i),x=c?t:p||u?o:m?"Loading...":r,y=c?i.text.error:p?i.text.warning:i.text.info,b=`(${c?l.length:p?d.length:s.length}/${s.length})`,$=c?i.text.error_secondary:p?i.text.warning_secondary:i.text.info_secondary,v=Dt(()=>a(e=>!e),[]);return vt(js,{onClick:v,$status:g,children:[vt(Ws,{children:[$t(m?Ms:f,{}),$t(ki,{color:y,size:14,children:x}),$t(ki,{color:$,size:12,family:"secondary",children:b}),$t(Us,{extend:n,align:"right"})]}),n&&$t(Gs,{children:s.map(({status:e,type:t,reason:o,message:r},n)=>{const a=e===Fo.Loading?()=>$t(Ms,{scale:.8}):e===Fo.Disabled?jr(Oo.Info,i):jr(e,i),s=e===Fo.Disabled?i.text.info:e===Oo.Error?i.text.error:e===Oo.Warning?i.text.warning:i.text.info,l=e===Fo.Disabled?i.text.info_secondary:e===Oo.Error?i.text.error_secondary:e===Oo.Warning?i.text.warning_secondary:i.text.info_secondary;return vt(Vs,{children:[$t(Hs,{children:$t(a,{})}),vt(ki,{color:s,size:12,children:[$t(Xs,{color:l,size:12,weight:700,children:t}),r||o]})]},`condition-${n}`)})})]})},Ks=Pt.div`
|
|
687
|
+
display: flex;
|
|
688
|
+
align-items: center;
|
|
689
|
+
gap: ${({$size:e})=>e/3}px;
|
|
690
|
+
padding: ${({$size:e,$withBorder:t,$withBackground:o})=>t||o?`${e/(t?3:2)}px ${e/(t?1.5:1)}px`:"0"};
|
|
691
|
+
width: ${({$width:e})=>e||"fit-content"};
|
|
692
|
+
border-radius: 360px;
|
|
693
|
+
border: ${({$withBorder:e,$status:t,theme:o})=>e?`1px solid ${o.text[t]+En["050"]}`:"none"};
|
|
694
|
+
background: ${({$withBackground:e,$status:t,theme:o})=>e?`linear-gradient(90deg, transparent 0%, ${o.text[t]+En["030"]} 100%)`:"transparent"};
|
|
695
|
+
`,qs=Pt.div`
|
|
696
|
+
display: flex;
|
|
697
|
+
align-items: center;
|
|
698
|
+
`,Ys=Pt.div`
|
|
699
|
+
display: flex;
|
|
700
|
+
align-items: center;
|
|
701
|
+
`,Qs=({title:e,subtitle:t,status:o=Oo.Default,forceIcon:r,withIcon:i,withBorder:n,withBackground:a,width:s,size:l=12,family:c="secondary",nowrap:d=!1})=>{const p=Bt(),u=[Fo.Loading,Fo.Disabled].includes(o)?Oo.Info:o,h=r?()=>$t(r,{size:l+2,fill:p.text[u]}):o===Fo.Loading?()=>$t(Ms,{scale:.8}):()=>jr(u,p)?.({size:l+2});return vt(Ks,{$status:u,$width:s,$size:l,$withIcon:i,$withBorder:n,$withBackground:a,children:[i&&$t(qs,{children:$t(h,{})}),(!!e||!!t)&&vt(Ys,{children:[!!e&&$t(ki,{size:l,family:c,color:p.text[u],nowrap:d,children:e}),!!e&&!!t&&$t(Va,{orientation:"vertical",length:l-2+"px",type:u}),!!t&&$t(ki,{size:l-2,family:c,color:p.text[`${u}_secondary`],nowrap:d,children:t})]})]})},Zs=({label:e,onClick:t,variant:o="tertiary",textProps:r,...i})=>{const n=Bt();return vt(Mn,{onClick:t,variant:o,...i,children:[$t(tt,{fill:"primary"===o?n.text.primary:n.text.info}),$t(ki,{size:14,family:"secondary",decoration:"underline",color:"primary"===o?n.text.primary:void 0,...r,children:e||mr.ADD})]})},el=Pt(Ea)`
|
|
702
|
+
width: 100%;
|
|
703
|
+
border-radius: 8px;
|
|
704
|
+
background-color: ${({theme:e})=>e.colors.secondary+En["010"]};
|
|
705
|
+
pre {
|
|
706
|
+
color: ${({theme:e})=>e.text.default};
|
|
707
|
+
font-size: 12px;
|
|
708
|
+
overflow-x: auto;
|
|
709
|
+
width: 100%;
|
|
710
|
+
padding-left: 12px;
|
|
711
|
+
}
|
|
712
|
+
`,tl=({value:e,callbackCopyDone:t})=>{const{clickCopy:o,isCopied:r}=qn();return vt(el,{children:[$t("pre",{children:e}),$t(os,{onClick:r=>{r.stopPropagation(),o(e),t?.()},tooltip:r?"Copied!":"Copy",children:$t(r?Je:Ke,{})})]})},ol=({label:e,onClick:t,variant:o="tertiary",...r})=>{const i=Bt();return vt(Mn,{onClick:t,variant:o,...r,children:[$t(ot,{fill:"primary"===o?i.text.primary:i.text.info}),$t(ki,{size:14,family:"secondary",decoration:"underline",color:"primary"===o?i.text.primary:void 0,children:e||mr.EDIT})]})},rl=({onClick:e})=>$t(ps,{type:Oo.Default,icon:Xe,message:hr.QUICK_BACK_TO_SUMMARY,action:{label:hr.GO_TO_SUMMARY,onClick:e}}),il=Pt(ki)`
|
|
713
|
+
max-width: ${({$maxWidth:e})=>e?`${e}px`:"unset"};
|
|
714
|
+
white-space: nowrap;
|
|
715
|
+
overflow-x: auto;
|
|
716
|
+
|
|
717
|
+
&::after {
|
|
718
|
+
// This is to prevent the "browser default tooltip" from appearing when the title is too long
|
|
719
|
+
content: '';
|
|
720
|
+
display: block;
|
|
721
|
+
}
|
|
722
|
+
`,nl=({maxWidth:e,text:t,textSize:o=16,textColor:r})=>{const[i,n]=kt(!1),a=At(null);return Et(()=>{if(a.current){const{clientWidth:t}=a.current;n(t<1.05*(e-o)&&t>.95*(e-o))}},[e,o,t]),vt(Ea,{$gap:0,children:[t&&$t(Za,{text:i?t:void 0,children:$t(il,{ref:a,$maxWidth:e-o,size:o,color:r,children:t})}),i&&$t(il,{$maxWidth:o,size:o,color:r,children:"..."})]})},al=({src:e="",alt:t="",size:o=16})=>{const[r,i]=kt(!1);return e&&!r?$t("img",{src:e,alt:t,width:o,height:o,onError:()=>i(!0)}):$t(s,{size:o})},sl=Pt.div`
|
|
723
|
+
display: flex;
|
|
724
|
+
align-items: center;
|
|
725
|
+
justify-content: center;
|
|
726
|
+
width: ${({$size:e})=>e}px;
|
|
727
|
+
height: ${({$size:e})=>e}px;
|
|
728
|
+
border-radius: 8px;
|
|
729
|
+
background: ${({$status:e,theme:t})=>{const o=t.colors[e||"dropdown_bg_2"];return`linear-gradient(180deg, ${o} 0%, ${o+En["030"]} 100%)`}};
|
|
730
|
+
`,ll=({icon:e,src:t="",alt:o="",status:r,size:i=36})=>$t(sl,{$status:r,$size:i,children:t?$t(al,{src:t,alt:o,size:i-12}):$t(e||s,{size:i-12})}),cl=Pt.div`
|
|
731
|
+
position: relative;
|
|
732
|
+
display: flex;
|
|
733
|
+
flex-wrap: wrap;
|
|
734
|
+
align-items: center;
|
|
735
|
+
justify-content: center;
|
|
736
|
+
width: ${({$size:e})=>e}px;
|
|
737
|
+
height: ${({$size:e})=>e}px;
|
|
738
|
+
`,dl=Pt.div`
|
|
739
|
+
position: absolute;
|
|
740
|
+
top: ${({$top:e})=>e}px;
|
|
741
|
+
left: ${({$left:e})=>e}px;
|
|
742
|
+
z-index: ${({$zIndex:e})=>e};
|
|
743
|
+
display: flex;
|
|
744
|
+
align-items: center;
|
|
745
|
+
justify-content: center;
|
|
746
|
+
width: ${({$size:e})=>e}px;
|
|
747
|
+
height: ${({$size:e})=>e}px;
|
|
748
|
+
border-radius: 100%;
|
|
749
|
+
border: 1px solid ${({theme:e,$status:t})=>(t?e.text[t]:e.colors.border)+En["030"]};
|
|
750
|
+
background: ${({$status:e,theme:t})=>{const o=t.colors[e||"dropdown_bg_2"];return`linear-gradient(180deg, ${o} 0%, ${o+En["030"]} 100%)`}};
|
|
751
|
+
`,pl=({icons:e=[],iconSrcs:t=[],status:o,size:r=36,id:i})=>{const n=Bt(),a=1===e.length||1===t.length?r-12:r/2.7;if(t.length>0)return $t(pl,{icons:t.map(e=>()=>$t(al,{src:e,size:a})),status:o,size:r,id:i});if(1===e.length)return $t(ll,{icon:e[0],status:o,size:r});const s=t=>e.length<=2?.5*a:0===t||1===t?0:1.15*a,l=e=>0===e?0:1===e?1.15*a:1.15*a*.5;return $t(cl,{$status:o,$size:r,children:e.map((t,r)=>r>2?null:$t(dl,{$status:o,$size:1.5*a,$top:s(r),$left:l(r),$zIndex:r+1,children:2===r&&e.length>3?vt(ki,{family:"secondary",color:n.text.dark_grey,size:.8*a,children:["+",e.length-2]}):$t(t,{size:a})},`icon-${i}-${r}`))})},ul=Yi.map(({id:e})=>e),hl=({monitors:e=ul,withTooltips:t,withLabels:o,size:r=12,color:i})=>{const n=Bt(),a=i||n.text.grey;return $t(Ea,{$gap:o?r:r/2,children:e.map(e=>{const i=ro(e.toLowerCase()),n=Fr(e);return n?$t(Za,{text:t?i:"",children:vt(Ea,{$gap:r/3,children:[$t(n,{size:o?r+2:r,fill:a}),o&&$t(ki,{size:r,color:a,children:i})]})},e):null})})},ml=Pt.div`
|
|
752
|
+
visibility: hidden;
|
|
753
|
+
`,gl=Pt.div`
|
|
754
|
+
display: flex;
|
|
755
|
+
flex-direction: column;
|
|
756
|
+
align-self: stretch;
|
|
757
|
+
padding: 16px;
|
|
758
|
+
width: calc(100% - 32px);
|
|
759
|
+
border-radius: 16px;
|
|
760
|
+
background-color: ${({theme:e,$status:t,$bgColor:o})=>o||(t?e.text[t]+En["010"]:e.colors.secondary+En["005"])};
|
|
761
|
+
opacity: ${({$faded:e})=>e?.5:1};
|
|
762
|
+
|
|
763
|
+
${({theme:e,$status:t,$bgColorHover:o,$withClick:r})=>r?Mt`
|
|
764
|
+
&:hover {
|
|
765
|
+
cursor: pointer;
|
|
766
|
+
background-color: ${o||(t?e.text[t]+En["020"]:e.colors.secondary+En["010"])};
|
|
767
|
+
${ml} {
|
|
768
|
+
visibility: visible;
|
|
769
|
+
}
|
|
770
|
+
}
|
|
771
|
+
`:`\n &:hover {\n ${ml} {\n visibility: visible;\n }\n }\n `}
|
|
772
|
+
`,fl=Pt.div`
|
|
773
|
+
display: flex;
|
|
774
|
+
align-items: center;
|
|
775
|
+
gap: 8px;
|
|
776
|
+
margin-left: auto;
|
|
777
|
+
`,xl=Pt(ki)`
|
|
778
|
+
margin-right: 16px;
|
|
779
|
+
`,yl=Pt(ki)`
|
|
780
|
+
font-size: 10px;
|
|
781
|
+
color: ${({theme:e})=>e.text.grey};
|
|
782
|
+
`,bl=({title:e,subTitle:t,hoverText:o,onClick:r,renderActions:i,iconProps:{icon:n,icons:a,iconSrc:s,iconSrcs:l}={},visualProps:{status:c,faded:d,bgColor:p,bgColorHover:u,monitors:h,monitorsWithLabels:m,componentsUnderTitles:g}={},checkboxProps:{withCheckbox:f,isCheckboxDisabled:x,isChecked:y,isLoading:b,onCheckboxChange:$}={},extendableProps:{withExtend:v,isExtended:w,renderExtended:S}={},...C})=>{const k=Bt(),[E,A]=kt(w||!1),[D,T]=kt(0),N=At(null),I=At(null),_=At(null);return Et(()=>{if(N.current){const e=N.current.clientWidth,t=I.current?.clientWidth||0;T(e-((f?125:85)+t))}},[f]),vt(gl,{ref:N,$status:c,$faded:d,$bgColor:p,$bgColorHover:u,$withClick:!!r,onClick:r,...C,children:[vt(Ea,{$gap:8,children:[vt(Ea,{$gap:16,children:[b?$t(Ms,{}):f?$t(Ss,{value:y,onChange:$,disabled:x}):null,a?.length||l?.length?$t(pl,{icons:a,iconSrcs:l,status:c,id:`${e}-${t}`}):n||s?$t(ll,{icon:n,src:s,status:c}):null]}),vt(Aa,{$gap:4,children:[e&&$t(nl,{maxWidth:D,text:e,textSize:14}),vt(Ea,{$gap:4,children:[t&&$t(nl,{maxWidth:D-(_.current?.clientWidth||0),text:t,textSize:10,textColor:k.text.grey}),h&&h.length>0&&vt(Ea,{$gap:4,ref:_,children:[t&&$t(yl,{children:"•"}),$t(hl,{monitors:h,withLabels:m,size:10})]})]}),g&&g.length>0?$t(Ea,{$gap:4,children:g?.map((e,t)=>$t(St,{children:e},`componentsUnderTitles-${t}`))}):null]}),vt(fl,{ref:I,children:[!!o&&$t(ml,{children:$t(xl,{size:14,family:"secondary",children:o})}),i&&i(),v&&vt(St,{children:[$t(Va,{orientation:"vertical",length:"16px",margin:"0 2px"}),$t(os,{onClick:()=>A(e=>!e),children:$t(Us,{extend:E})})]})]})]}),E&&S&&vt(Aa,{children:[$t(Va,{margin:"16px 0"}),S()]})]})},$l=Pt(Ea)`
|
|
783
|
+
width: 100%;
|
|
784
|
+
justify-content: space-between;
|
|
785
|
+
`,vl=Pt(ki)`
|
|
786
|
+
font-size: 12px;
|
|
787
|
+
color: ${({theme:e})=>e.text.grey};
|
|
788
|
+
`,wl=Pt(ki)`
|
|
789
|
+
font-size: 10px;
|
|
790
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
791
|
+
`,Sl=Pt.div`
|
|
792
|
+
display: flex;
|
|
793
|
+
align-items: center;
|
|
794
|
+
gap: 8px;
|
|
795
|
+
margin-left: auto;
|
|
796
|
+
`,Cl=Pt(ki)`
|
|
797
|
+
font-size: 12px;
|
|
798
|
+
text-align: right;
|
|
799
|
+
`,kl=({title:e,subTitle:t,tooltip:o,value:r})=>vt($l,{children:[$t(Aa,{$gap:4,children:vt(Za,{text:o||"",children:[e&&$t(vl,{children:e},"title"),t&&$t(wl,{children:t},"subtitle")]})}),$t(Sl,{children:r?.status?$t(Qs,{status:"transitioning"===r.status?Fo.Loading:r.status,title:r.text||r.status,withBorder:!0,withIcon:!0}):$t(Cl,{children:r?.text||"-"})})]}),El=Pt(Aa)`
|
|
800
|
+
width: 100%;
|
|
801
|
+
`,Al=({containerName:e,actualDevices:t,started:o,ready:r,instrumentationInstances:i})=>{const n=Ct(()=>{const e=[];return o?.name&&e.push($t(Qs,{status:ei(o.value)?di(o.value)?Oo.Success:Oo.Error:Oo.Default,title:o.name,withIcon:!0,withBorder:!0,size:8},"started")),r?.name&&e.push($t(Qs,{status:ei(r.value)?di(r.value)?Oo.Success:Oo.Error:Oo.Default,title:r.name,withIcon:!0,withBorder:!0,size:8},"ready")),e},[o?.name,o?.value,r?.name,r?.value]);return $t(bl,{title:e.value,subTitle:i.length?`${i.length} Instrumented Processes`:void 0,visualProps:{componentsUnderTitles:n},renderActions:()=>$t(Qs,{status:Oo.Info,title:"Instrumentation Device",subtitle:t.value&&"[]"!==t.value?t.value:"none",withBorder:!0}),extendableProps:{isExtended:!!i.length,renderExtended:()=>$t(El,{$gap:24,children:i.map((e,t)=>vt(El,{$gap:8,children:[$t(kl,{title:`Instrumented Process #${t+1}`,subTitle:e.message?.value||"",value:{status:e.healthy.status,text:e.healthy.status===Oo.Success?"healthy":"unhealthy"}}),e.identifyingAttributes?.map(({name:e,value:t})=>$t(kl,{title:e,subTitle:"",value:{text:t,status:void 0}},`describe-${e}-${t}`))]},`process-${t}`))})}})},Dl=({title:e="Data not found",subTitle:t})=>{const o=Bt().v2.colors.grey[400];return vt(Da,{children:[vt(Ea,{$gap:8,children:[$t(rt,{fill:o}),$t($i,{size:yi.XS,color:o,align:"center",children:e})]}),t&&$t($i,{size:yi.XXS,color:o,align:"center",children:t})]})},Tl=Pt(Aa)`
|
|
802
|
+
max-width: 300px;
|
|
803
|
+
padding: 12px;
|
|
804
|
+
border-radius: 12px;
|
|
805
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
806
|
+
justify-content: center;
|
|
807
|
+
`,Nl=_t(({id:e,data:t})=>{const{title:o,subTitle:r}=t;return $t(Tl,{"data-id":e,children:$t(Dl,{title:o,subTitle:r})})});Nl.displayName=Nl.name;const Il=Pt.div`
|
|
808
|
+
padding: 6px;
|
|
809
|
+
border-radius: 12px;
|
|
810
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
811
|
+
cursor: pointer;
|
|
812
|
+
${({$isVirtual:e,theme:t})=>e&&`\n border: 1px dashed ${t.colors.border};\n opacity: 0.8;\n `}
|
|
813
|
+
`,_l=Pt.div`
|
|
814
|
+
position: relative;
|
|
815
|
+
`,Ol=Pt.div`
|
|
816
|
+
position: absolute;
|
|
817
|
+
top: 100%;
|
|
818
|
+
margin-top: 4px;
|
|
819
|
+
left: 50%;
|
|
820
|
+
transform: translateX(-50%);
|
|
821
|
+
display: flex;
|
|
822
|
+
flex-direction: column;
|
|
823
|
+
align-items: center;
|
|
824
|
+
gap: 2px;
|
|
825
|
+
width: 140px;
|
|
826
|
+
text-align: center;
|
|
827
|
+
`,Rl=_t(({id:e,data:t})=>{const{id:o,status:r,title:i,icons:n,isVirtual:a}=t,s=Bt(),l=a||r!==Oo.Error?null:jr(r,s);return vt(wt,{children:[$t(Wt,{type:"source",position:Gt.Right,style:{visibility:"hidden"}}),$t(Wt,{type:"target",position:Gt.Left,style:{visibility:"hidden"}}),vt(_l,{"data-id":e,children:[$t(Il,{$isVirtual:a,children:$t(pl,{id:o,icons:n,status:a?void 0:r})}),vt(Ol,{children:[l&&$t(l,{}),$t(ki,{size:12,style:{textAlign:"center",wordBreak:"break-word",lineHeight:"1.3"},children:i})]})]})]})});Rl.displayName=Rl.name;const Fl={duration:300,padding:.1,includeHiddenNodes:!0},zl=Pt.div`
|
|
828
|
+
height: 100%;
|
|
829
|
+
.react-flow__attribution {
|
|
830
|
+
visibility: hidden;
|
|
831
|
+
}
|
|
832
|
+
`,Ll=Pt.div`
|
|
833
|
+
button {
|
|
834
|
+
padding: 8px;
|
|
835
|
+
margin: 8px;
|
|
836
|
+
border-radius: 8px;
|
|
837
|
+
border: 1px solid ${({theme:e})=>e.colors.border} !important;
|
|
838
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
839
|
+
path {
|
|
840
|
+
fill: ${({theme:e})=>e.text.secondary};
|
|
841
|
+
}
|
|
842
|
+
&:hover {
|
|
843
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
844
|
+
}
|
|
845
|
+
&:last-child svg {
|
|
846
|
+
transform: scale(1.4);
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
`,Pl={[Po.MapItem]:Rl,[Po.NoData]:Nl},Ml=({trigger:e})=>{const{fitView:t}=Kt(),o=At(!0);return Et(()=>{o.current?o.current=!1:e>0&&requestAnimationFrame(()=>t(Fl))},[e,t]),null},Bl=({nodes:e,edges:t,onNodesChange:o,onEdgesChange:r,fitViewTrigger:i=0,zoomOnScroll:n=!1,onEdgeClick:a,onNodeMouseEnter:s,onNodeMouseLeave:l,onRefresh:c})=>{const{onClickNode:d}=Gn(),{setActiveNodeType:p,setActiveNodeId:u}=Gi();return vt(Xt,{zoomOnScroll:n,nodes:e,nodeTypes:Pl,edges:t,onNodeClick:d,onEdgeClick:a,onNodeMouseEnter:s,onNodeMouseLeave:l,onNodesChange:o,onEdgesChange:r,onBlur:()=>{p(null),u(null)},children:[$t(Ml,{trigger:i}),$t(Ll,{children:$t(Ht,{position:"bottom-right",orientation:"horizontal",showInteractive:!1,showZoom:!0,showFitView:!0,fitViewOptions:Fl,children:c&&$t(Jt,{onClick:c,children:$t(it,{size:20})})})})]})},Ul=e=>$t(zl,{children:$t(Vt,{children:$t(Bl,{...e})})}),jl=Pt.div`
|
|
850
|
+
display: flex;
|
|
851
|
+
|
|
852
|
+
align-items: center;
|
|
853
|
+
gap: 6px;
|
|
854
|
+
margin-bottom: 4px;
|
|
855
|
+
`,Wl=Pt(ki)`
|
|
856
|
+
font-size: 14px;
|
|
857
|
+
opacity: 0.8;
|
|
858
|
+
line-height: 22px;
|
|
859
|
+
overflow: hidden;
|
|
860
|
+
white-space: nowrap;
|
|
861
|
+
text-overflow: ellipsis;
|
|
862
|
+
color: ${({$status:e,theme:t})=>e?t.text[e]:t.text.secondary};
|
|
863
|
+
`,Gl=Pt(ki)`
|
|
864
|
+
font-size: 12px;
|
|
865
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
866
|
+
opacity: 0.8;
|
|
867
|
+
`,Vl=({title:e,required:t,tooltip:o,style:r,status:i})=>e?$t(jl,{style:r,children:vt(Za,{text:o,withIcon:!0,children:[$t(Wl,{$status:i,children:e}),!t&&$t(Gl,{children:"(optional)"})]})}):null,Xl=Pt.div`
|
|
868
|
+
display: flex;
|
|
869
|
+
flex-direction: column;
|
|
870
|
+
position: relative;
|
|
871
|
+
width: 100%;
|
|
872
|
+
`,Hl=Pt.div`
|
|
873
|
+
width: 100%;
|
|
874
|
+
display: flex;
|
|
875
|
+
align-items: center;
|
|
876
|
+
height: 36px;
|
|
877
|
+
gap: 12px;
|
|
878
|
+
transition: border-color 0.3s;
|
|
879
|
+
border-radius: 32px;
|
|
880
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
881
|
+
${({$disabled:e})=>e&&Mt`
|
|
882
|
+
cursor: not-allowed;
|
|
883
|
+
opacity: 0.6;
|
|
884
|
+
`}
|
|
885
|
+
${({$isActive:e,$hasError:t,$status:o})=>e?Mt`
|
|
886
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
887
|
+
`:t?Mt`
|
|
888
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
889
|
+
`:o?Mt`
|
|
890
|
+
border-color: ${({theme:e})=>e.text[o]};
|
|
891
|
+
`:""}
|
|
892
|
+
&:hover {
|
|
893
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
894
|
+
}
|
|
895
|
+
&:focus-within {
|
|
896
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
897
|
+
}
|
|
898
|
+
`,Jl=Pt.input`
|
|
899
|
+
padding-left: ${({$hasIcon:e})=>e?"0":"16px"};
|
|
900
|
+
flex: 1;
|
|
901
|
+
min-width: 150px;
|
|
902
|
+
width: 100%;
|
|
903
|
+
border: none;
|
|
904
|
+
outline: none;
|
|
905
|
+
background: none;
|
|
906
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
907
|
+
font-size: 14px;
|
|
908
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
909
|
+
font-weight: 300;
|
|
910
|
+
&::placeholder {
|
|
911
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
912
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
913
|
+
opacity: 0.4;
|
|
914
|
+
font-size: 14px;
|
|
915
|
+
font-weight: 300;
|
|
916
|
+
line-height: 22px; /* 157.143% */
|
|
917
|
+
}
|
|
918
|
+
&:disabled {
|
|
919
|
+
cursor: not-allowed;
|
|
920
|
+
opacity: 0.6;
|
|
921
|
+
}
|
|
922
|
+
&::-webkit-inner-spin-button,
|
|
923
|
+
&::-webkit-outer-spin-button {
|
|
924
|
+
-webkit-appearance: none;
|
|
925
|
+
margin: 0;
|
|
926
|
+
}
|
|
927
|
+
`,Kl=Pt.div`
|
|
928
|
+
display: flex;
|
|
929
|
+
align-items: center;
|
|
930
|
+
margin-left: 12px;
|
|
931
|
+
`,ql=Pt(Kl)`
|
|
932
|
+
cursor: pointer;
|
|
933
|
+
`,Yl=Pt.button`
|
|
934
|
+
background-color: ${({theme:e})=>e.colors.primary};
|
|
935
|
+
border: none;
|
|
936
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
937
|
+
padding: 8px 16px;
|
|
938
|
+
border-radius: 20px;
|
|
939
|
+
cursor: pointer;
|
|
940
|
+
margin-left: 8px;
|
|
941
|
+
&:hover {
|
|
942
|
+
background-color: ${({theme:e})=>e.colors.secondary};
|
|
943
|
+
}
|
|
944
|
+
&:disabled {
|
|
945
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
946
|
+
cursor: not-allowed;
|
|
947
|
+
}
|
|
948
|
+
`,Ql=({icon:e,buttonLabel:t,onButtonClick:o,hasError:r,errorMessage:i,title:n,tooltip:a,required:s,value:l,onChange:c,type:d=_o.Text,name:p,status:u,...h})=>{const m=Bt(),g=d===_o.Password,[f,x]=kt(!1);return vt(Xl,{children:[$t(Vl,{title:n,required:s,tooltip:a,status:u}),vt(Hl,{$disabled:h.disabled,$hasError:r||!!i,$isActive:!!h.autoFocus,$status:u,children:[g?$t(ql,{onClick:()=>x(e=>!e),children:$t(f?nt:at,{size:14,fill:m.text.grey})}):e?$t(Kl,{children:$t(e,{size:14,fill:m.text.grey})}):null,$t(Jl,{"data-id":p,type:f||d===_o.Number?_o.Text:d,$hasIcon:!!e||g,name:p,value:l,onChange:e=>{e.stopPropagation(),d===_o.Number&&(e.target.value=ci(e.target.value)),c?.(e)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},...h}),t&&o&&$t(Yl,{onClick:o,disabled:h.disabled,children:t})]}),!!i&&$t(Di,{children:i})]})},Zl=Pt.div`
|
|
949
|
+
display: flex;
|
|
950
|
+
flex-direction: column;
|
|
951
|
+
min-width: 120px;
|
|
952
|
+
width: 100%;
|
|
953
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
954
|
+
`,ec=Pt.div`
|
|
955
|
+
position: relative;
|
|
956
|
+
`,tc=Pt.div`
|
|
957
|
+
display: flex;
|
|
958
|
+
align-items: center;
|
|
959
|
+
justify-content: space-between;
|
|
960
|
+
height: 36px;
|
|
961
|
+
padding: ${({$isMulti:e,$hasSelections:t})=>e&&t?"0 16px 0 6px":"0 16px"};
|
|
962
|
+
border-radius: 32px;
|
|
963
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
964
|
+
|
|
965
|
+
${({$isOpen:e,$isMulti:t,theme:o})=>e&&!t?Mt`
|
|
966
|
+
border: 1px solid ${o.text.grey};
|
|
967
|
+
background: ${o.colors.dropdown_bg_2};
|
|
968
|
+
`:Mt`
|
|
969
|
+
border: 1px solid ${o.colors.border};
|
|
970
|
+
background: transparent;
|
|
971
|
+
`};
|
|
972
|
+
|
|
973
|
+
${({$hasError:e,$status:t})=>e?Mt`
|
|
974
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
975
|
+
`:t?Mt`
|
|
976
|
+
border-color: ${({theme:e})=>e.text[t]};
|
|
977
|
+
`:""}
|
|
978
|
+
|
|
979
|
+
&:hover {
|
|
980
|
+
border-color: ${({$isMulti:e,$hasSelections:t,$disabled:o,theme:r})=>o?"auto":e&&t?r.colors.border:r.colors.secondary};
|
|
981
|
+
}
|
|
982
|
+
`,oc=Pt.div`
|
|
983
|
+
display: flex;
|
|
984
|
+
align-items: center;
|
|
985
|
+
gap: 4px;
|
|
986
|
+
`,rc=({options:e,value:t,onSelect:o,onDeselect:r,title:i,tooltip:n,placeholder:a,disabled:s=!1,isMulti:l=!1,showSearch:c=!1,required:d=!1,errorMessage:p,hasError:u=!1,status:h})=>{const[m,g]=kt(!1),[f,x]=kt(!1),y=At(null);ra(y,()=>g(!1));const b=()=>{(()=>{if(y.current){const e=y.current.getBoundingClientRect().bottom+300>window.innerHeight;x(e)}})(),g(e=>!e)},$=Array.isArray(t)?t.length:0;return vt(Zl,{$disabled:s,children:[$t(Vl,{title:i,required:d,tooltip:n,status:h}),vt(ec,{ref:y,children:[vt(tc,{$isOpen:m,$isMulti:l,$hasSelections:!!Array.isArray(t)&&!!t.length,$hasError:!!p||u,$status:h,$disabled:s,onClick:()=>!s&&b(),children:[$t(sc,{value:t,placeholder:a,onDeselect:r}),vt(oc,{children:[l&&$t(Fn,{label:$,filled:!!$}),$t(Us,{extend:m})]})]}),m&&$t(dc,{openUpwards:f,options:e,value:t,onSelect:e=>{o?.(e),l||b()},onDeselect:e=>{r?.(e),l||b()},isMulti:l,showSearch:c})]}),!!p&&$t(Di,{children:p})]})},ic=Pt(oc)`
|
|
987
|
+
max-width: calc(100% - 50px);
|
|
988
|
+
overflow-x: auto;
|
|
989
|
+
`,nc=Pt(ki)`
|
|
990
|
+
display: flex;
|
|
991
|
+
align-items: center;
|
|
992
|
+
gap: 2px;
|
|
993
|
+
padding: 4px 12px;
|
|
994
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
995
|
+
border-radius: 360px;
|
|
996
|
+
white-space: nowrap;
|
|
997
|
+
text-overflow: ellipsis;
|
|
998
|
+
img {
|
|
999
|
+
&:hover {
|
|
1000
|
+
transform: scale(2);
|
|
1001
|
+
transition: transform 0.3s;
|
|
1002
|
+
}
|
|
1003
|
+
}
|
|
1004
|
+
`,ac=Pt(ki)``,sc=({value:e,placeholder:t,onDeselect:o})=>{const r=Bt();return Array.isArray(e)?e.length?$t(ic,{children:e.map(e=>vt(nc,{size:14,children:[e.value,$t(Va,{orientation:"vertical",length:"10px",margin:"0 4px"}),$t(qe,{size:12,onClick:t=>{t.stopPropagation(),o?.(e)}})]},`multi-label-${e.id}`))}):$t(ac,{size:14,color:r.text.darker_grey,children:t}):$t(ac,{size:14,color:e?.value?void 0:r.text.darker_grey,children:e?.value||t})},lc=Pt.div`
|
|
1005
|
+
position: absolute;
|
|
1006
|
+
${({$openUpwards:e})=>e?"bottom":"top"}: calc(100% + 8px);
|
|
1007
|
+
left: 0;
|
|
1008
|
+
z-index: 1;
|
|
1009
|
+
display: flex;
|
|
1010
|
+
flex-direction: column;
|
|
1011
|
+
overflow-y: auto;
|
|
1012
|
+
width: calc(100% - 16px);
|
|
1013
|
+
max-height: 200px;
|
|
1014
|
+
gap: 8px;
|
|
1015
|
+
padding: 8px;
|
|
1016
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1017
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1018
|
+
border-radius: 24px;
|
|
1019
|
+
`,cc=Pt.div`
|
|
1020
|
+
display: flex;
|
|
1021
|
+
flex-direction: column;
|
|
1022
|
+
align-items: center;
|
|
1023
|
+
`,dc=({openUpwards:e,options:t,value:o,onSelect:r,onDeselect:i,isMulti:n,showSearch:a})=>{const[s,l]=kt(""),c=t.filter(e=>e.value?.toLowerCase().includes(s?.toLowerCase()));return vt(lc,{$openUpwards:e,children:[a&&vt(cc,{children:[$t(Ql,{placeholder:"Search...",icon:st,value:s,onChange:e=>l(e.target.value)}),$t(Va,{thickness:1,margin:"8px 0 0 0"})]}),0===c.length?$t(Dl,{subTitle:a&&s?void 0:" "}):c.map((e,t)=>$t(uc,{option:e,value:o,isMulti:n,onSelect:r,onDeselect:i},`dropdown-option-${e.id||t}`))]})},pc=Pt.div`
|
|
1024
|
+
padding: 8px 12px;
|
|
1025
|
+
cursor: pointer;
|
|
1026
|
+
display: flex;
|
|
1027
|
+
justify-content: space-between;
|
|
1028
|
+
align-items: center;
|
|
1029
|
+
border-radius: 32px;
|
|
1030
|
+
&:hover,
|
|
1031
|
+
&.selected {
|
|
1032
|
+
background: ${({theme:e})=>e.colors.majestic_blue+En["024"]};
|
|
1033
|
+
}
|
|
1034
|
+
`,uc=({option:e,value:t,isMulti:o,onSelect:r,onDeselect:i})=>{const n=Bt(),a=Array.isArray(t)?!!t?.find(t=>t.id===e.id):t?.id===e.id,s=t=>t?r?.(e):i?.(e);return o?$t(pc,{className:a?"selected":"",onClick:()=>s(!a),children:$t(Ss,{title:e.value||"",titleColor:n.text.secondary,value:a,onChange:s,style:{width:"100%"}})}):vt(pc,{className:a?"selected":"",onClick:()=>a?i?.(e):r?.(e),children:[vt(Ea,{$gap:8,children:[e.icon&&$t(e.icon,{}),$t(ki,{size:14,children:e.value})]}),a&&$t(Je,{})]})},hc=Pt(Aa)`
|
|
1035
|
+
gap: 12px;
|
|
1036
|
+
`,mc=Pt(Ea)`
|
|
1037
|
+
width: 100%;
|
|
1038
|
+
gap: 12px;
|
|
1039
|
+
align-items: flex-end;
|
|
1040
|
+
`,gc=({clientX:e=0,flipX:t,clientY:o=0,flipY:r,isOpen:i,onClose:n,onSave:a,withDelete:s,onDelete:l,title:c,titleTooltip:d,warning:p,children:u})=>{const h=Bt(),{popupRef:m,popupPosition:g,handlePosition:f}=ia({onClickOutside:n});return oa({key:"Enter",active:i},a),Et(()=>f(e,o),[e,o]),0===g.top&&0!==o||0===g.left&&0!==e?null:$t(qa,{ref:m,isOpen:i,top:r?void 0:g.top,bottom:r?g.top:void 0,left:t?void 0:g.left,right:t?g.left:void 0,padding:"24px",children:vt(hc,{children:[$t(Za,{text:d,withIcon:!0,children:$t(ki,{size:14,children:c})}),vt(mc,{children:[u,vt(Ea,{$gap:6,children:[$t(os,{withBorder:!0,onClick:n,tooltip:"Cancel",children:$t(qe,{})}),$t(os,{withBorder:!0,backgroundColor:h.colors.secondary,onClick:a,tooltip:"Save",children:$t(Je,{fill:h.text.primary})}),s&&$t(os,{onClick:l,tooltip:"Undo",children:$t(lt,{})})]})]}),p&&$t(ps,{type:Oo.Warning,message:p})]})})},fc=Pt.div`
|
|
1041
|
+
position: relative;
|
|
1042
|
+
`,xc=({defaultLanguage:e=Ao.Unknown,defaultVersion:t="",defaultOtelDistroName:o=null,handleSave:r})=>{const{tier:i}=pa(),{addNotification:n}=pn(),{formData:a,handleFormChange:s,resetFormData:l}=Bn({language:e,version:t,otelDistroName:o}),[c,d]=kt(!1),p=()=>{d(!1),l()},u=Ct(()=>{if(!a.language)return[];const e=en[a.language].community,t=i===Co.Onprem?en[a.language].enterprise:[];return e.concat(t)},[a.language,i]);return vt(fc,{children:[$t(os,{tooltip:hr.OVERRIDE_RUNTIME_DETAILS,size:32,onClick:()=>{d(!0)},children:$t(ot,{})}),$t(gc,{flipX:!0,clientX:36,isOpen:c,onClose:p,onSave:async()=>{!a.version||ri(a.version)?(await r({...a}),p()):n({type:Oo.Warning,message:ur.INVALID_VERSION,hideFromHistory:!0})},withDelete:!0,onDelete:async()=>{await r({language:null,version:"",otelDistroName:null}),p()},title:hr.OVERRIDE_RUNTIME_DETAILS,warning:hr.OVERRIDE_RUNTIME_WARNING,children:vt(Aa,{$gap:12,children:[vt(Ea,{$gap:12,children:[$t(rc,{title:hr.LANGUAGE,options:Zi,value:Zi.find(e=>e.id===a.language),onSelect:e=>{s("language",e.id),s("version",""),s("otelDistroName",null)},required:!0}),$t(Ql,{title:hr.RUNTIME_VERSION,placeholder:hr.VERSION_PLACEHOLDER,value:a.version,onChange:e=>s("version",e.target.value),required:!1})]}),a.language&&$t(rc,{title:"Otel Distro Name",options:u,value:u.find(e=>e.id===a.otelDistroName),onSelect:e=>s("otelDistroName",e.id),required:!1})]})})]})},yc=Pt(Ea)`
|
|
1043
|
+
width: 100%;
|
|
1044
|
+
justify-content: center;
|
|
1045
|
+
`,bc=({containerName:e,language:t,runtimeVersion:o,overriden:r,instrumented:i,instrumentationMessage:n,otelDistroName:a,callbackRuntimeOverride:s})=>{const l=Bt(),c=i?Oo.Success:n?Oo.Info:Oo.Warning,d=i?Ro.INSTRUMENTED:n?Ro.NOT_INSTRUMENTED:Ro.INSTRUMENTING;return $t(bl,{title:e,subTitle:`${t?Qi[t]:"no runtime info"}`+(o?` • Runtime Version: ${o}`:""),iconProps:{icon:Sr(t)},extendableProps:{isExtended:!!n,renderExtended:()=>$t(yc,{children:$t(ki,{size:12,family:"secondary",color:l.text.info,children:ii(n)})})},renderActions:()=>vt(wt,{children:[$t(Qs,{status:c,title:d,subtitle:a||void 0,withIcon:!0,withBorder:!0}),r&&$t(Qs,{status:Oo.Default,forceIcon:ct,title:hr.OVERIDDEN,withIcon:!0,withBorder:!0}),s&&$t(xc,{defaultLanguage:t,defaultVersion:o,defaultOtelDistroName:a,handleSave:t=>s({...t,containerName:e})})]})})},$c=Pt.tr`
|
|
1046
|
+
cursor: ${({$withHover:e})=>e?"pointer":"default"};
|
|
1047
|
+
opacity: ${({$faded:e})=>e?.5:1};
|
|
1048
|
+
`,vc=Pt.td`
|
|
1049
|
+
position: relative;
|
|
1050
|
+
width: fit-content;
|
|
1051
|
+
padding: 16px 8px 16px ${({$isFirst:e})=>e?"16px":"8px"};
|
|
1052
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1053
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1054
|
+
font-size: 14px;
|
|
1055
|
+
white-space: nowrap;
|
|
1056
|
+
`,wc=Pt(ki)`
|
|
1057
|
+
font-size: 14px;
|
|
1058
|
+
color: ${({$color:e,theme:t})=>e??t.text.secondary};
|
|
1059
|
+
line-height: 16px;
|
|
1060
|
+
|
|
1061
|
+
overflow: hidden;
|
|
1062
|
+
overflow-wrap: break-word;
|
|
1063
|
+
white-space: wrap;
|
|
1064
|
+
text-wrap: wrap;
|
|
1065
|
+
text-overflow: ellipsis;
|
|
1066
|
+
display: -webkit-box;
|
|
1067
|
+
-webkit-line-clamp: 2;
|
|
1068
|
+
-webkit-box-orient: vertical;
|
|
1069
|
+
`,Sc=Pt.div`
|
|
1070
|
+
position: absolute;
|
|
1071
|
+
top: 0;
|
|
1072
|
+
left: 0;
|
|
1073
|
+
z-index: -1;
|
|
1074
|
+
width: ${({$width:e})=>e}px;
|
|
1075
|
+
height: ${({$height:e})=>e}px;
|
|
1076
|
+
border-radius: 16px;
|
|
1077
|
+
background-color: ${({theme:e,$hovered:t,$status:o})=>t?o?e.text[o]+En["020"]:e.colors.majestic_blue+En["030"]:o?e.text[o]+En["010"]:e.colors.secondary+En["005"]};
|
|
1078
|
+
`,Cc=({index:e,columns:t,cells:o,onClick:r,status:i,faded:n})=>{const{containerRef:a,containerHeight:s,containerWidth:l}=Xn(),[c,d]=kt(!1);return $t($c,{ref:a,onMouseEnter:()=>!!r&&d(!0),onMouseLeave:()=>!!r&&d(!1),onClick:()=>!!r&&r(),$withHover:!!r,$faded:n,children:t.map(({key:t},r)=>{const n=o.find(({columnKey:e})=>e===t);if(!n)return null;const{value:a,textColor:d,withTooltip:p,icon:u,component:h}=n;return vt(vc,{$isFirst:0===r,children:[u?$t(ll,{icon:u}):h?$t(h,{}):$t(Za,{text:p&&a?String(a):"",children:$t(wc,{$color:d,children:Yr(a)?"-":a})}),0===r&&$t(Sc,{$height:s,$width:l,$top:s*e,$hovered:c,$status:i})]},`table-row-${t}-${a}-${e}-${r}`)})})},kc=Pt.div`
|
|
1079
|
+
width: 100%;
|
|
1080
|
+
`,Ec=Pt.table`
|
|
1081
|
+
position: relative;
|
|
1082
|
+
z-index: 0;
|
|
1083
|
+
width: 100%;
|
|
1084
|
+
border-collapse: separate;
|
|
1085
|
+
border-spacing: 0 12px;
|
|
1086
|
+
`,Ac=Pt.thead`
|
|
1087
|
+
// only supported with "border-collapse: collapse;"
|
|
1088
|
+
// border-top: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1089
|
+
// border-bottom: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1090
|
+
`,Dc=Pt.th`
|
|
1091
|
+
// only required with "border-collapse: separate;"
|
|
1092
|
+
border-top: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1093
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1094
|
+
|
|
1095
|
+
padding: 8px;
|
|
1096
|
+
`,Tc=Pt(Ea)`
|
|
1097
|
+
cursor: pointer;
|
|
1098
|
+
&:hover {
|
|
1099
|
+
* {
|
|
1100
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1101
|
+
}
|
|
1102
|
+
}
|
|
1103
|
+
`,Nc=Pt(ki)`
|
|
1104
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
1105
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
1106
|
+
text-transform: uppercase;
|
|
1107
|
+
font-size: 12px;
|
|
1108
|
+
font-weight: 500;
|
|
1109
|
+
text-wrap: nowrap;
|
|
1110
|
+
`,Ic=Pt.tbody``,_c=({columns:e,rows:t})=>{const[o,r]=kt(So.Ascending),[i,n]=kt("name"),a=Dt(e=>{i===e?r(e=>e===So.Ascending?So.Descending:So.Ascending):(n(e),r(So.Ascending))},[i]),s=Ct(()=>{const r=(e,t)=>e.cells.find(({columnKey:e})=>e===t)?.value??null;return(i?[...t].sort((e,t)=>{const n=r(e,i),a=r(t,i);return(o===So.Ascending?1:-1)*((e,t)=>"number"==typeof e&&"number"==typeof t?e-t:"string"==typeof e&&"string"==typeof t?e.localeCompare(t):"boolean"==typeof e&&"boolean"==typeof t?e===t?0:e?1:-1:String(e).localeCompare(String(t)))(n,a)}):t).map(({status:t,faded:o,cells:r,onClick:i},n)=>$t(Cc,{index:n,columns:e,cells:r,onClick:i,status:t,faded:o},`row-${n}`))},[e,t,i,o]);return $t(kc,{children:vt(Ec,{children:[$t(Ac,{children:$t("tr",{children:e.map(({key:e,title:t,sortable:o})=>$t(Dc,{children:o?vt(Tc,{onClick:()=>a(e),children:[$t(dt,{}),$t(Nc,{children:t})]}):$t(Nc,{children:t})},`column-${e}`))})}),$t(Ic,{children:s})]})})};var Oc;!function(e){e.Code="code",e.Table="table",e.Badge="badge",e.Loader="loader",e.Divider="divider",e.Monitors="monitors",e.CopyText="copy-text",e.ActiveStatus="active-status"}(Oc||(Oc={}));const Rc=Pt.div`
|
|
1111
|
+
display: flex;
|
|
1112
|
+
flex-wrap: wrap;
|
|
1113
|
+
gap: 16px 32px;
|
|
1114
|
+
width: 100%;
|
|
1115
|
+
`,Fc=Pt.div`
|
|
1116
|
+
display: flex;
|
|
1117
|
+
flex-direction: column;
|
|
1118
|
+
gap: 2px;
|
|
1119
|
+
width: ${({$width:e})=>e};
|
|
1120
|
+
`,zc=Pt(ki)`
|
|
1121
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1122
|
+
font-size: 10px;
|
|
1123
|
+
line-height: 16px;
|
|
1124
|
+
`,Lc=Pt(ki)`
|
|
1125
|
+
font-size: 12px;
|
|
1126
|
+
white-space: pre-wrap;
|
|
1127
|
+
`,Pc=({data:e})=>$t(Rc,{children:e?.map(({type:e,title:t,titleIcon:o,tooltip:r,value:i},n)=>vt(Fc,{$width:e&&[Oc.Code,Oc.Table].includes(e)?"inherit":e&&[Oc.Loader,Oc.Divider,Oc.CopyText].includes(e)?"100%":"unset",children:[$t(Za,{text:r,withIcon:!0,children:vt(Ea,{$alignItems:"center",$gap:4,children:[o&&$t(o,{size:14}),!!t&&$t(zc,{transform:"capitalize",children:t})]})}),$t(Mc,{type:e,value:i})]},`data-field-${t||(i?JSON.stringify(i):n)}`))}),Mc=({type:e,value:t})=>{const o=Bt();switch(e){case Oc.Divider:return $t(Va,{length:"100%",margin:"0"});case Oc.Loader:return $t(Da,{children:$t(Ms,{scale:1.2})});case Oc.Monitors:return $t(hl,{monitors:t?.split(", ")||[],withLabels:!0,color:o.colors.secondary});case Oc.Badge:{const{label:e,filled:o,...r}=Jr(t,{label:"-",filled:!1});return $t(Fn,{label:e,filled:o,...r})}case Oc.Code:{const{language:e,code:o,...r}=Jr(t,{language:"",code:""});return $t(Os,{language:e,code:o,...r})}case Oc.Table:{const{columns:e,rows:o,...r}=Jr(t,{columns:[],rows:[{status:void 0,cells:[]}]});return $t(_c,{columns:e,rows:o,...r})}case Oc.ActiveStatus:return $t(Qs,{status:"true"==t?Oo.Success:Oo.Error,title:"true"==t?hr.ENABLED:hr.DISABLED,size:10,withIcon:!0,withBorder:!0});case Oc.CopyText:{const e="string"==typeof t?t:JSON.stringify(t);return $t(tl,{value:e})}default:return $t(Lc,{children:pi("string"==typeof t?t||"-":"")})}},Bc=Pt.div`
|
|
1128
|
+
display: flex;
|
|
1129
|
+
flex-direction: column;
|
|
1130
|
+
align-items: flex-start;
|
|
1131
|
+
align-self: stretch;
|
|
1132
|
+
gap: 16px;
|
|
1133
|
+
padding: 24px;
|
|
1134
|
+
border-radius: 24px;
|
|
1135
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1136
|
+
background-color: ${({theme:e,$hovered:t})=>t?e.colors.secondary+En["010"]:"transparent"};
|
|
1137
|
+
transition: background-color 0.3s;
|
|
1138
|
+
`,Uc=Pt.div`
|
|
1139
|
+
width: 100%;
|
|
1140
|
+
display: flex;
|
|
1141
|
+
flex-direction: column;
|
|
1142
|
+
gap: 4px;
|
|
1143
|
+
cursor: ${({$clickable:e})=>e?"pointer":"default"};
|
|
1144
|
+
`,jc=Pt(ki)`
|
|
1145
|
+
width: 100%;
|
|
1146
|
+
display: flex;
|
|
1147
|
+
align-items: center;
|
|
1148
|
+
gap: 8px;
|
|
1149
|
+
font-size: 16px;
|
|
1150
|
+
`,Wc=Pt(ki)`
|
|
1151
|
+
font-size: 12px;
|
|
1152
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1153
|
+
`,Gc=Pt(Ea)`
|
|
1154
|
+
margin-left: auto;
|
|
1155
|
+
gap: 8px;
|
|
1156
|
+
`,Vc=({title:e="Details",titleBadge:t,titleIcon:o,description:r,action:i,withExtend:n,initialExtended:a=!1,data:s,children:l})=>{const[c,d]=kt(a),[p,u]=kt(!1);return vt(Bc,{$hovered:p,children:[e||o||r||i?vt(Uc,{$clickable:n||!1,onClick:()=>n&&d(e=>!e),onMouseEnter:()=>n&&u(!0),onMouseLeave:()=>n&&u(!1),children:[vt(Ea,{children:[vt(Ea,{$alignItems:"center",$gap:8,children:[o&&$t(Ea,{$alignItems:"center",children:$t(o,{size:20})}),!!e&&$t(jc,{transform:"capitalize",children:e}),t===Fo.Loading?$t(Ms,{}):void 0!==t&&$t(Fn,{label:t})]}),(!!i||n)&&vt(Gc,{children:["function"==typeof i?$t(i,{hovered:p}):i,n&&$t(Us,{extend:c})]})]}),!!r&&$t(Wc,{children:r})]}):null,(!n||n&&c)&&(l||$t(Pc,{data:s}))]})},Xc=Pt.div`
|
|
1157
|
+
visibility: hidden;
|
|
1158
|
+
`,Hc=Pt(Ea)`
|
|
1159
|
+
align-self: stretch;
|
|
1160
|
+
width: calc(100% - 32px);
|
|
1161
|
+
padding: 16px;
|
|
1162
|
+
border-radius: 16px;
|
|
1163
|
+
background-color: ${({theme:e})=>e.colors.secondary+En["005"]};
|
|
1164
|
+
${({theme:e,$withClick:t})=>t?Mt`
|
|
1165
|
+
&:hover {
|
|
1166
|
+
cursor: pointer;
|
|
1167
|
+
background-color: ${e.colors.secondary+En["010"]};
|
|
1168
|
+
${Xc} {
|
|
1169
|
+
visibility: visible;
|
|
1170
|
+
}
|
|
1171
|
+
}
|
|
1172
|
+
`:`\n &:hover {\n ${Xc} {\n visibility: visible;\n }\n }\n `}
|
|
1173
|
+
`,Jc=Pt(Ea)`
|
|
1174
|
+
margin-left: auto;
|
|
1175
|
+
gap: 8px;
|
|
1176
|
+
`,Kc=Pt(ki)`
|
|
1177
|
+
font-size: 10px;
|
|
1178
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1179
|
+
`,qc=({title:e,subTitle:t,icons:o,iconSrcs:r,onClick:i,renderActions:n})=>{const a=Bt(),[s,l]=kt(0),c=At(null),d=At(null);return Et(()=>{if(c.current){const e=c.current.clientWidth,t=d.current?.clientWidth||0;l(e-(85+t))}},[]),vt(Hc,{ref:c,$gap:8,$withClick:!!i,onClick:i,children:[$t(pl,{id:`${e}-${t}`,icons:o,iconSrcs:r}),e&&$t(nl,{maxWidth:s/2,text:e,textSize:14}),e&&t&&$t(Kc,{children:"•"}),t&&$t(nl,{maxWidth:s/2,text:t,textSize:10,textColor:a.text.grey}),$t(Jc,{ref:d,children:n&&vt(wt,{children:[$t(Va,{orientation:"vertical",length:"24px",margin:"0"}),n()]})})]})},Yc=({isOpen:e,noOverlay:t,name:o,type:r,isLastItem:i,onApprove:n,onDeny:a})=>{const s=r===To.Source?"uninstrument":"delete";return $t(bs,{isOpen:e,noOverlay:t,title:`${s.charAt(0).toUpperCase()+s.substring(1)}${o?` ${o}`:""}`,description:`Are you sure you want to ${s}?`,note:i?{type:Oo.Warning,title:`You're about to ${s} the last ${r||o}`,message:""}:void 0,approveButton:{text:"Confirm",variant:"danger",onClick:n},denyButton:{text:"Go Back",onClick:a}})},Qc=Pt(Mn)`
|
|
1180
|
+
display: flex;
|
|
1181
|
+
align-items: center;
|
|
1182
|
+
justify-content: center;
|
|
1183
|
+
font-size: 14px;
|
|
1184
|
+
gap: 6px;
|
|
1185
|
+
min-width: 100px;
|
|
1186
|
+
`,Zc=({endpoint:e="/",variant:t="secondary"})=>vt(Qc,{variant:t,onClick:()=>window.open(`https://docs.odigos.io${e}`,"_blank","noopener noreferrer"),children:[$t(pt,{size:18}),"Docs"]}),ed=Pt(Ea)`
|
|
1187
|
+
border-bottom: ${({$hideBorder:e,theme:t})=>e?"none":`1px solid ${t.colors.border}`};
|
|
1188
|
+
`,td=Pt.div`
|
|
1189
|
+
display: flex;
|
|
1190
|
+
align-items: center;
|
|
1191
|
+
border-bottom: 2px solid ${({theme:e,$selected:t})=>t?e.colors.majestic_blue:"transparent"};
|
|
1192
|
+
cursor: pointer;
|
|
1193
|
+
`,od=Pt(ki)`
|
|
1194
|
+
padding: 12px;
|
|
1195
|
+
font-size: 14px;
|
|
1196
|
+
color: ${({theme:e,$selected:t})=>t?e.text.secondary:e.text.grey};
|
|
1197
|
+
`,rd=({tabs:e,hideBorder:t=!1})=>e?.length?$t(ed,{$hideBorder:t,children:e.map(({label:e,icon:t,onClick:o,selected:r})=>vt(td,{onClick:o,$selected:r,children:[$t(od,{$selected:r,children:e}),t&&$t(t,{})]},`tab-${e}`))}):null,id=Pt.section`
|
|
1198
|
+
padding: 0px 32px;
|
|
1199
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
1200
|
+
`,nd=Pt.div`
|
|
1201
|
+
height: 76px;
|
|
1202
|
+
display: flex;
|
|
1203
|
+
justify-content: space-between;
|
|
1204
|
+
flex-shrink: 0;
|
|
1205
|
+
align-self: stretch;
|
|
1206
|
+
`,ad=Pt.div`
|
|
1207
|
+
display: flex;
|
|
1208
|
+
align-items: center;
|
|
1209
|
+
gap: ${({$gap:e})=>e||16}px;
|
|
1210
|
+
`,sd=Pt(ki)`
|
|
1211
|
+
font-size: 18px;
|
|
1212
|
+
line-height: 26px;
|
|
1213
|
+
max-width: ${({$maxWidth:e})=>e};
|
|
1214
|
+
overflow: hidden;
|
|
1215
|
+
white-space: nowrap;
|
|
1216
|
+
text-overflow: ellipsis;
|
|
1217
|
+
`,ld=Pt(Mn)`
|
|
1218
|
+
gap: 8px;
|
|
1219
|
+
`,cd=Pt(Mn)``,dd=({onClose:e,width:t,icons:o,iconSrcs:r,title:i,titleTooltip:n,replaceTitleWith:a,actions:s,actionButtons:l=[],tabs:c})=>vt(id,{children:[vt(nd,{children:[vt(ad,{children:[o?.length||r?.length?$t(pl,{icons:o,iconSrcs:r,id:`drawer-header-${i}`}):null,("function"==typeof a?$t(a,{}):a||null)||$t(Za,{text:n||i,withIcon:!!n,children:i&&$t(sd,{$maxWidth:`calc(${t} ${s||l.length?"/ 5":"- 192px"})`,children:i})})]}),vt(ad,{$gap:2,children:[s,l.map((e,t)=>$t(ld,{...e},`header-action-button-${t}`)),$t(cd,{"data-id":"drawer-close",variant:"secondary",onClick:e,children:$t(qe,{size:12})})]})]}),$t(rd,{tabs:c,hideBorder:!0})]}),pd=Pt.div`
|
|
1220
|
+
display: flex;
|
|
1221
|
+
justify-content: space-between;
|
|
1222
|
+
gap: 8px;
|
|
1223
|
+
padding: 24px 18px 24px 32px;
|
|
1224
|
+
border-top: 1px solid ${({theme:e})=>e.colors.border};
|
|
1225
|
+
background-color: ${({theme:e})=>e.colors.translucent_bg};
|
|
1226
|
+
transform: translateY(100%);
|
|
1227
|
+
animation-name: ${Dn.in.bottom};
|
|
1228
|
+
`,ud=Pt(Ea)`
|
|
1229
|
+
margin-right: auto;
|
|
1230
|
+
`,hd=Pt(Ea)`
|
|
1231
|
+
margin: 0 auto;
|
|
1232
|
+
`,md=Pt(Ea)`
|
|
1233
|
+
margin-left: auto;
|
|
1234
|
+
`,gd=Pt(Mn)`
|
|
1235
|
+
min-width: 140px;
|
|
1236
|
+
font-size: 14px;
|
|
1237
|
+
`,fd=({isOpen:e,leftButtons:t=[],centerButtons:o=[],rightButtons:r=[]})=>e?vt(pd,{children:[$t(ud,{children:t.map((e,t)=>$t(gd,{...e},`footer-left-button-${t}`))}),$t(hd,{children:o.map((e,t)=>$t(gd,{...e},`footer-center-button-${t}`))}),$t(md,{children:r.map((e,t)=>$t(gd,{...e},`footer-right-button-${t}`))})]}):null,xd=Pt.div`
|
|
1238
|
+
position: fixed;
|
|
1239
|
+
top: 0;
|
|
1240
|
+
bottom: 0;
|
|
1241
|
+
${({$position:e})=>e}: 0;
|
|
1242
|
+
z-index: 1000;
|
|
1243
|
+
width: ${({$width:e})=>e};
|
|
1244
|
+
background: ${({theme:e})=>e.colors.translucent_bg};
|
|
1245
|
+
box-shadow: 0 2px 10px ${({theme:e})=>e.colors.primary+En["010"]};
|
|
1246
|
+
overflow-y: auto;
|
|
1247
|
+
animation-name: ${({$position:e})=>Dn.in[e]};
|
|
1248
|
+
`,yd=Pt.div`
|
|
1249
|
+
display: flex;
|
|
1250
|
+
flex-direction: column;
|
|
1251
|
+
height: 100%;
|
|
1252
|
+
`,bd=Pt.div`
|
|
1253
|
+
flex-grow: 1;
|
|
1254
|
+
padding: 24px 32px;
|
|
1255
|
+
overflow-y: auto;
|
|
1256
|
+
`,$d=({isOpen:e,onClose:t,closeOnEscape:o=!0,position:r="right",width:i="300px",children:n,header:a,footer:s})=>(oa({key:"Escape",active:e&&o},()=>t()),Wn(e),e?qt.createPortal(vt(wt,{children:[$t(Na,{hidden:!e,onClick:t}),$t(xd,{"data-id":"drawer",$position:r,$width:i,children:vt(yd,{children:[$t(dd,{onClose:t,width:i,...a}),$t(bd,{children:n}),$t(fd,{...s})]})})]}),document.body):null),vd=({error:e})=>{const t=Bt(),o={container:{display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center",color:t.text.error,fontFamily:t.font_family.primary},errorMessage:{padding:10,borderRadius:5,whiteSpace:"pre-wrap",background:t.colors.error},errorStack:{whiteSpace:"pre-wrap",fontSize:"12px"},errorStackWrapper:{textAlign:"left",marginTop:10},infoText:{marginTop:100,color:t.text.secondary,fontSize:"14px"}};return vt("div",{style:o.container,children:[$t("h2",{children:"Something went wrong!"}),$t("pre",{style:o.errorMessage,children:e?.message||"Unknown Error"}),vt("details",{style:o.errorStackWrapper,children:[$t("summary",{children:"Stack Trace"}),$t("pre",{style:o.errorStack,children:e?.stack||"Unknown Stack"})]}),$t("p",{style:o.infoText,children:"Try refreshing the page or contact support"}),$t(Mn,{variant:"secondary",onClick:()=>window.location.reload(),style:{fontSize:"1rem"},children:"Reload"})]})},wd=({children:e})=>$t(eo,{FallbackComponent:({error:e,...t})=>$t(kn,{children:$t(vd,{...t,error:e})}),children:e}),Sd=Pt(Ea)`
|
|
1257
|
+
position: relative;
|
|
1258
|
+
width: calc(100% - 24px);
|
|
1259
|
+
padding: 12px;
|
|
1260
|
+
background-color: ${({theme:e})=>e.colors.dark_grey};
|
|
1261
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border+En["050"]};
|
|
1262
|
+
`,Cd=Pt(Ea)`
|
|
1263
|
+
margin-right: auto;
|
|
1264
|
+
margin-left: 32px;
|
|
1265
|
+
gap: 12px;
|
|
1266
|
+
`,kd=Pt(Ea)`
|
|
1267
|
+
margin-left: auto;
|
|
1268
|
+
margin-right: 32px;
|
|
1269
|
+
gap: 12px;
|
|
1270
|
+
`,Ed=Pt(Ea)`
|
|
1271
|
+
position: absolute;
|
|
1272
|
+
left: 50%;
|
|
1273
|
+
transform: translateX(-50%);
|
|
1274
|
+
gap: 12px;
|
|
1275
|
+
`,Ad=({left:e=[],center:t=[],right:o=[]})=>vt(Sd,{children:[$t(Cd,{children:e.map((e,t)=>e&&$t(St,{children:e},t))}),$t(Ed,{children:t.map((e,t)=>e&&$t(St,{children:e},t))}),$t(kd,{children:o.map((e,t)=>e&&$t(St,{children:e},t))})]}),Dd=Pt(ki)`
|
|
1276
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1277
|
+
`,Td=({icon:e,title:t,badge:o,badgeTooltip:r,loading:i})=>vt(Ea,{$gap:6,children:[e&&$t(e,{}),$t(Dd,{size:14,children:t}),void 0!==o&&$t(Za,{text:r,children:$t(Fn,{label:o})}),i&&$t(Ms,{})]}),Nd=Pt.div`
|
|
1278
|
+
width: fit-content;
|
|
1279
|
+
height: fit-content;
|
|
1280
|
+
padding: 4px;
|
|
1281
|
+
gap: 4px;
|
|
1282
|
+
border-radius: 32px;
|
|
1283
|
+
border: 1px solid ${({theme:e})=>e.colors.border+En["070"]};
|
|
1284
|
+
|
|
1285
|
+
display: flex;
|
|
1286
|
+
flex-direction: ${({$orientation:e,$flip:t})=>("horizontal"===e?"row":"column")+(t?"-reverse":"")};
|
|
1287
|
+
align-items: center;
|
|
1288
|
+
justify-content: center;
|
|
1289
|
+
`,Id=Pt.div`
|
|
1290
|
+
width: 32px;
|
|
1291
|
+
height: 32px;
|
|
1292
|
+
|
|
1293
|
+
border-radius: 100%;
|
|
1294
|
+
background-color: ${({theme:e,$selected:t})=>t?e.colors.majestic_blue+En["070"]:e.colors.secondary+En["012"]};
|
|
1295
|
+
transition: background-color 0.3s;
|
|
1296
|
+
|
|
1297
|
+
display: flex;
|
|
1298
|
+
align-items: center;
|
|
1299
|
+
justify-content: center;
|
|
1300
|
+
|
|
1301
|
+
cursor: pointer;
|
|
1302
|
+
`,_d=({orientation:e="vertical",flip:t,mainIcons:o,subIcons:r})=>vt(Nd,{$orientation:e,$flip:t,children:[o.map(({icon:e,selected:t,onClick:o,tooltip:r},i)=>$t(Za,{text:r,children:$t(Id,{$selected:t,onClick:o,children:$t(e,{size:20})})},`main-nav-icon-${i}`)),!!o.length&&!!r.length&&$t(Va,{orientation:"vertical"===e?"horizontal":"vertical",margin:"0",length:"20px"}),r.map(({icon:e,selected:t,onClick:o,tooltip:r},i)=>$t(Za,{text:r,children:$t(Id,{$selected:t,onClick:o,children:$t(e,{size:20})})},`sub-nav-icon-${i}`))]}),Od=Pt.div`
|
|
1303
|
+
display: flex;
|
|
1304
|
+
flex-direction: column;
|
|
1305
|
+
width: 100%;
|
|
1306
|
+
`,Rd=Pt.div`
|
|
1307
|
+
display: flex;
|
|
1308
|
+
flex-direction: column;
|
|
1309
|
+
gap: 8px;
|
|
1310
|
+
`,Fd=Pt.div`
|
|
1311
|
+
display: flex;
|
|
1312
|
+
align-items: center;
|
|
1313
|
+
gap: 16px;
|
|
1314
|
+
`,zd=Pt(os)`
|
|
1315
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1316
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
1317
|
+
`,Ld=({initialValues:e=[],value:t,onChange:o,title:r,tooltip:i,required:n,errorMessage:a})=>{const[s,l]=kt(t||e);Et(()=>{s.length||l([""])},[]);const c=s.filter(e=>!!e.trim()),d=At(JSON.stringify(c));Et(()=>{const e=JSON.stringify(c);d.current!==e&&(d.current=e,o&&o(c))},[c]);const p=(e,t)=>{l(o=>{const r=[...o];return r[t]=e,r})},u=s.length<=1,h=s.some(e=>""===e.trim()),m=u&&h;return vt(Od,{children:[$t(Vl,{title:r,required:n,tooltip:i}),$t(Rd,{children:s.map((e,t)=>{const o=t===s.length-1;return vt(Fd,{children:[$t(Ql,{value:e,onChange:e=>p(e.target.value,t),hasError:!!a,autoFocus:Yr(e)&&!u&&o}),t===s.length-1&&$t(zd,{withBorder:!0,size:30,$disabled:h,onClick:h?void 0:()=>{l(e=>{const t=[...e];return t.push(""),t})},children:$t(tt,{})}),$t(zd,{size:30,$disabled:m,onClick:m?void 0:()=>(e=>{u?p("",e):l(t=>t.filter((t,o)=>o!==e))})(t),children:$t(lt,{})})]},`input-list-${t}`)})}),!!a&&$t(Di,{children:a})]})},Pd=({col:e,colIdx:t,row:o,rowIdx:r,rowsLength:i,maxWidth:n,handleChange:a,errorMessage:s,limitFieldsPerRow:l})=>{const{keyName:c,title:d,tooltip:p,placeholder:u,required:h,type:m,componentType:g,options:f,renderCondition:x}=e,y=o[c];if(x&&!x(o))return null;return $t("td",{style:{maxWidth:n,padding:"4px 6px 4px 0"},children:(()=>{switch(g){case Io.Dropdown:const e=f?.find(e=>e.id===y);return $t(rc,{title:l?d:void 0,tooltip:l?p:void 0,placeholder:u,required:h,options:f||[],value:e,onSelect:e=>a(c,e.id,r),onDeselect:()=>a(c,"",r),hasError:!!s&&(!h||h&&Yr(y))});case"multi-dropdown":const o=Array.isArray(y)&&f?.filter(e=>y.includes(e.id))||[];return $t(rc,{title:l?d:void 0,tooltip:l?p:void 0,placeholder:u,required:h,options:f||[],value:o,isMulti:!0,onSelect:e=>{const t=[...Array.isArray(y)?y:[],e.id];a(c,t,r)},onDeselect:e=>{const t=(Array.isArray(y)?y:[]).filter(t=>t!==e.id);a(c,t,r)},hasError:!!s&&(!h||h&&Yr(y))});default:const g=i>1&&r===i-1&&0===t&&Yr(y);return $t(Ql,{title:l?d:void 0,tooltip:l?p:void 0,placeholder:u,type:m,required:h,autoFocus:g,value:y,onChange:({target:{value:e}})=>a(c,e,r),style:{maxWidth:n,paddingLeft:10},hasError:!!s&&(!h||h&&Yr(y))})}})()},`input-table-${r}-${c}`)},Md=Pt.div`
|
|
1318
|
+
display: flex;
|
|
1319
|
+
flex-direction: column;
|
|
1320
|
+
width: 100%;
|
|
1321
|
+
`,Bd=Pt.button`
|
|
1322
|
+
margin-top: ${({$marginTop:e})=>e};
|
|
1323
|
+
background: none;
|
|
1324
|
+
border: none;
|
|
1325
|
+
cursor: ${({disabled:e})=>e?"not-allowed":"pointer"};
|
|
1326
|
+
opacity: ${({disabled:e})=>e?.5:1};
|
|
1327
|
+
`,Ud=({columns:e,initialValues:t=[],value:o,onChange:r,errorMessage:i,limitFieldsPerRow:n,title:a=""})=>{const[s,l]=kt({}),[c,d]=kt(o||t),p=Ct(()=>new Map(e.map(e=>[e.keyName,e])),[e]);Et(()=>{if(!c.length){const t={};e.forEach(({keyName:e})=>t[e]=""),l(t),d([t])}},[]);const u=c.filter(e=>{for(const[t,o]of Object.entries(e)){const r=p.get(t);if((!r?.renderCondition||r.renderCondition(e))&&(r?.required&&Yr(o)))return!1}return!0}),h=At(JSON.stringify(u)),m=u.length!==c.length,g=`${Math.floor(640/((n||e.length)+.4))}px`;Et(()=>{const e=JSON.stringify(u);h.current!==e&&(h.current=e,r&&r(u))},[u]);const f=(e,t,o)=>{d(r=>{const i=so(r);return i[o][e]=t,i})},x=Ct(()=>{if(n){const t=[];for(let o=0;;o+=n){const r=e.slice(o,o+n);if(!r.length)break;t.push(r)}return t}return[e]},[n,e]);return vt(Md,{children:[$t(Vl,{title:a}),vt("table",{style:{borderCollapse:"collapse"},children:[!n&&$t("thead",{children:vt("tr",{children:[e.map(({title:e,tooltip:t,required:o})=>$t("th",{style:{maxWidth:g},children:$t(Vl,{title:e,required:o,tooltip:t})},`input-table-head-${e}`)),$t("th",{})]})}),$t("tbody",{children:c.map((t,o)=>vt(St,{children:[n&&o>0?$t("tr",{children:$t("td",{colSpan:x.length,children:$t(Va,{})})}):null,x.map((r,a)=>vt("tr",{children:[r.map((e,r)=>$t(Pd,{col:e,colIdx:r,row:t,rowIdx:o,rowsLength:c.length,maxWidth:g,limitFieldsPerRow:n,errorMessage:i,handleChange:f},`input-table-row-${o}-col-${r}`)),0===a&&$t("td",{children:$t(Bd,{$marginTop:n?"24px":"0",onClick:()=>{return t=o,void(c.length>1?d(e=>e.filter((e,o)=>o!==t)):e.forEach(({keyName:e,type:o})=>f(e,o===_o.Number?"0":"",t)));var t},children:$t(lt,{})})})]},`input-table-matrix-${o}-${a}`))]},`input-table-row-${o}`))})]}),!!i&&$t(Di,{children:i}),$t(Zs,{onClick:()=>{d(e=>{const t=so(e);return t.push(so(s)),t})},disabled:m})]})},jd=Pt.div`
|
|
1328
|
+
display: flex;
|
|
1329
|
+
flex-direction: column;
|
|
1330
|
+
width: 100%;
|
|
1331
|
+
`,Wd=Pt.div`
|
|
1332
|
+
display: flex;
|
|
1333
|
+
flex-direction: column;
|
|
1334
|
+
gap: 8px;
|
|
1335
|
+
`,Gd=Pt.div`
|
|
1336
|
+
display: flex;
|
|
1337
|
+
align-items: center;
|
|
1338
|
+
gap: 8px;
|
|
1339
|
+
`,Vd=Pt.div`
|
|
1340
|
+
width: 100%;
|
|
1341
|
+
max-width: ${({$maxWidth:e})=>e?`${e}px`:"unset"};
|
|
1342
|
+
`,Xd=Pt(os)`
|
|
1343
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1344
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
1345
|
+
`,Hd={key:"",value:""},Jd=({initialKeyValuePairs:e=[],value:t,onChange:o,title:r,tooltip:i,disabled:n,required:a,errorMessage:s,keyPlaceholder:l="Key",valuePlaceholder:c="Value",inputMaxWidth:d=300})=>{const[p,u]=kt(t||e);Et(()=>{p.length||u([{...Hd}])},[]);const h=p.filter(({key:e,value:t})=>!Yr(e.trim())&&!Yr(t.trim())),m=At(JSON.stringify(h));Et(()=>{const e=JSON.stringify(h);m.current!==e&&(m.current=e,o&&o(h))},[h]);const g=(e,t,o)=>{u(r=>{const i=[...r];return i[o][e]=t,i})},f=p.length<=1,x=n||p.some(({key:e,value:t})=>""===e.trim()||""===t.trim()),y=n||f&&x;return vt(jd,{children:[$t(Vl,{title:r,required:a,tooltip:i}),$t(Wd,{children:p.map(({key:e,value:t},o)=>vt(Gd,{children:[$t(Vd,{$maxWidth:d,children:$t(Ql,{placeholder:l,disabled:n,value:e,onChange:e=>g("key",e.target.value,o),hasError:!!s&&(!a||a&&!e),autoFocus:Yr(t)&&!f&&o===p.length-1})}),$t(Vd,{$maxWidth:o===p.length-1?d-38:d,children:$t(Ql,{placeholder:c,disabled:n,value:t,onChange:e=>g("value",e.target.value,o),hasError:!!s&&(!a||a&&Yr(t)),autoFocus:!1})}),o===p.length-1&&$t(Xd,{withBorder:!0,size:30,$disabled:x,onClick:x?void 0:()=>{u(e=>{const t=[...e];return t.push({...Hd}),t})},children:$t(tt,{})}),$t(Xd,{size:30,$disabled:y,onClick:y?void 0:()=>(e=>{f?(g("key","",e),g("value","",e)):u(t=>t.filter((t,o)=>o!==e))})(o),children:$t(lt,{})})]},`key-value-input-list-${o}`))}),!!s&&$t(Di,{children:s})]})},Kd=jt`
|
|
1346
|
+
0% {
|
|
1347
|
+
background-position: 0% 50%;
|
|
1348
|
+
}
|
|
1349
|
+
100% {
|
|
1350
|
+
background-position: 100% 50%;
|
|
1351
|
+
}
|
|
1352
|
+
`,qd=Pt(ki)`
|
|
1353
|
+
background: ${({$textColor:e,$stripColor:t})=>`linear-gradient(45deg, ${e} 0%, ${e} 40%, ${t} 50%, ${e} 60%, ${e} 100%)`};
|
|
1354
|
+
background-size: 250% 100%; /* Expand background to allow movement */
|
|
1355
|
+
background-clip: text;
|
|
1356
|
+
color: transparent;
|
|
1357
|
+
animation: ${Kd} 1s reverse linear infinite;
|
|
1358
|
+
`,Yd=({children:e="Loading...",textColor:t,stripColor:o,...r})=>{const i=Bt(),n=t||i.v2.colors.white[500],a=o||i.v2.colors.black[500];return $t(qd,{$textColor:n,$stripColor:a,...r,children:e})},Qd=Pt.div`
|
|
1359
|
+
display: flex;
|
|
1360
|
+
flex-direction: ${({$isVertical:e})=>e?"column":"row"};
|
|
1361
|
+
gap: ${({$isVertical:e})=>e?"12px":"24px"};
|
|
1362
|
+
${({$hasError:e})=>e&&Mt`
|
|
1363
|
+
border: 1px solid ${({theme:e})=>e.text.error};
|
|
1364
|
+
border-radius: 32px;
|
|
1365
|
+
padding: 8px;
|
|
1366
|
+
`}
|
|
1367
|
+
`,Zd=(e,t)=>!t?.length||!!t?.find(t=>t===e),ep=({isVertical:e,title:t="Monitors",required:o,errorMessage:r,allowedSignals:i,selectedSignals:n,setSelectedSignals:a})=>{const[s,l]=kt(1===n.length),c=At(JSON.stringify(n));Et(()=>{const e=n;e.length||Yi.forEach(({id:t})=>{Zd(t,i)&&e.push(t)});const t=JSON.stringify(e);return c.current!==t&&(c.current=t,a(e),l(1===e.length)),()=>{c.current=""}},[i]);return vt("div",{children:[t&&$t(Vl,{title:t,required:o}),$t(Qd,{$isVertical:e,$hasError:!!r,children:Yi.map(e=>{const t=Zd(e.id,i),o=((e,t)=>!!t?.find(t=>t===e))(e.id,n);return t?$t(Ss,{title:e.value,disabled:!t||s&&o,value:o,onChange:t=>((e,t)=>{const o=e,r=t?[...n,o]:n.filter(e=>e!==o);a(r),l(1===r.length)})(e.id,t)},e.id):null})}),!!r&&$t(Di,{children:r})]})},tp=Pt.div`
|
|
1368
|
+
display: flex;
|
|
1369
|
+
gap: 8px;
|
|
1370
|
+
align-items: center;
|
|
1371
|
+
`,op=Pt(Mn)`
|
|
1372
|
+
display: flex;
|
|
1373
|
+
align-items: center;
|
|
1374
|
+
justify-content: center;
|
|
1375
|
+
gap: 8px;
|
|
1376
|
+
min-width: 90px;
|
|
1377
|
+
`,rp=({buttons:e})=>{const t=Bt(),o=({button:t,index:o})=>e.length>1&&0===o&&(t.icon||t.iconSrc),r=({button:e,rotate:o})=>e.icon?$t(e.icon,{size:14,rotate:o,fill:t.text[e.variant||"secondary"]}):e.iconSrc?$t("img",{src:e.iconSrc,alt:e.label,width:8,height:12}):null;return $t(tp,{children:e.map((e,t)=>$t(Za,{text:e.tooltip||"",children:vt(op,{variant:e.variant||"secondary",onClick:e.onClick,disabled:e.disabled,children:[o({button:e,index:t})&&r({button:e,rotate:0}),e.label,!o({button:e,index:t})&&r({button:e,rotate:180})]},t)},t))})},ip=Pt.div`
|
|
1378
|
+
width: 100%;
|
|
1379
|
+
height: 100%;
|
|
1380
|
+
|
|
1381
|
+
* {
|
|
1382
|
+
animation: none !important;
|
|
1383
|
+
transition: none !important;
|
|
1384
|
+
}
|
|
1385
|
+
`,np=({width:e="100%",height:t="100%",gap:o=0,elements:r,noAnimation:i=!1,onTopIndexChange:n})=>{const a=At(null),s=Ct(()=>o?r.map((e,t)=>$t("div",{style:{paddingBottom:o},children:e},`scroll-y-item-${t}`)):r,[r,o]),l=Dt(e=>{if(!n||!a.current)return;const t=a.current.findItemIndex(e);n(t)},[n]),c=$t(oo,{ref:a,style:{width:e,height:t},onScroll:n?l:void 0,children:s});return i?$t(ip,{children:c}):c},ap=Pt.div`
|
|
1386
|
+
display: flex;
|
|
1387
|
+
justify-content: space-between;
|
|
1388
|
+
align-items: center;
|
|
1389
|
+
gap: 16px;
|
|
1390
|
+
`,sp=Pt.div`
|
|
1391
|
+
display: flex;
|
|
1392
|
+
flex-direction: column;
|
|
1393
|
+
gap: 4px;
|
|
1394
|
+
`,lp=Pt.div`
|
|
1395
|
+
display: flex;
|
|
1396
|
+
align-items: center;
|
|
1397
|
+
gap: 8px;
|
|
1398
|
+
`,cp=Pt(ki)``,dp=Pt(ki)``,pp=({title:e,description:t,badgeLabel:o,icon:r,actionButton:i,size:n="medium"})=>{const a="small"===n?16:"medium"===n?20:24,s="small"===n?12:"medium"===n?14:16;return vt(ap,{children:[vt(sp,{children:[vt(lp,{children:[r&&$t(r,{size:a}),$t(cp,{weight:300,size:a,children:e}),void 0!==o&&$t(Fn,{label:o,filled:!!o})]}),$t(dp,{weight:200,opacity:.8,size:s,children:t})]}),i&&$t("div",{children:i})]})},up=Pt.div`
|
|
1399
|
+
position: relative;
|
|
1400
|
+
gap: 0;
|
|
1401
|
+
z-index: 0;
|
|
1402
|
+
display: grid;
|
|
1403
|
+
grid-template-columns: repeat(${({$count:e})=>e}, 1fr);
|
|
1404
|
+
`,hp=Pt.button`
|
|
1405
|
+
flex: 1;
|
|
1406
|
+
display: flex;
|
|
1407
|
+
align-items: center;
|
|
1408
|
+
justify-content: center;
|
|
1409
|
+
gap: 4px;
|
|
1410
|
+
padding: 6px 12px;
|
|
1411
|
+
background-color: transparent;
|
|
1412
|
+
border-radius: ${({$isFirstItem:e,$isLastItem:t})=>e?"32px 0px 0px 32px":t?"0px 32px 32px 0px":"0"};
|
|
1413
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1414
|
+
cursor: pointer;
|
|
1415
|
+
&:hover {
|
|
1416
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
1417
|
+
}
|
|
1418
|
+
`,mp=Pt.div`
|
|
1419
|
+
position: absolute;
|
|
1420
|
+
top: ${({$y:e})=>e}px;
|
|
1421
|
+
left: ${({$x:e})=>e}px;
|
|
1422
|
+
z-index: -1;
|
|
1423
|
+
width: ${({$width:e})=>e}px;
|
|
1424
|
+
height: ${({$height:e})=>e}px;
|
|
1425
|
+
background-color: ${({theme:e,$bgColor:t})=>t||e.colors.dropdown_bg_2};
|
|
1426
|
+
border-radius: ${({$isFirstItem:e,$isLastItem:t})=>e?"32px 0px 0px 32px":t?"0px 32px 32px 0px":"0"};
|
|
1427
|
+
transition: all 0.3s;
|
|
1428
|
+
`,gp=({options:e=[],selected:t,setSelected:o})=>{const r=e.findIndex(e=>e.value===t),[i,n]=kt(e[r]?.selectedBgColor||""),[a,s]=kt({width:0,height:0}),[l,c]=kt({x:0,y:0}),d=At(null);return Et(()=>{d.current&&(s({width:d.current.offsetWidth,height:d.current.offsetHeight}),c({x:d.current.offsetWidth*r,y:0}))},[t,r]),vt(up,{$count:e.length,children:[e.map(({icon:r,label:i,value:a,selectedBgColor:s,selectedTextColor:l},c)=>{const p=t===a;return vt(hp,{ref:p?d:void 0,$isFirstItem:0===c,$isLastItem:c===e.length-1,onClick:()=>{o(a),n(s||"")},children:[r&&$t(r,{}),i&&$t(ki,{size:12,family:"secondary",decoration:"underline",color:p?l:void 0,children:i})]},`segment-${i||c}-${a}`)}),$t(mp,{$bgColor:i,$width:a.width,$height:a.height,$x:l.x,$y:l.y,$isFirstItem:0===r,$isLastItem:r===e.length-1})]})},fp=Pt(Mn)`
|
|
1429
|
+
gap: 8px;
|
|
1430
|
+
text-transform: none;
|
|
1431
|
+
text-decoration: none;
|
|
1432
|
+
border: ${({theme:e,$withBorder:t})=>`1px solid ${t?e.colors.border:"transparent"}`};
|
|
1433
|
+
&.not-selected {
|
|
1434
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.dropdown_bg_2+En["060"]};
|
|
1435
|
+
&:hover {
|
|
1436
|
+
background-color: ${({theme:e,$hoverColor:t})=>t||e.colors.dropdown_bg_2};
|
|
1437
|
+
}
|
|
1438
|
+
}
|
|
1439
|
+
&.selected {
|
|
1440
|
+
background-color: ${({theme:e})=>e.colors.majestic_blue+En["030"]};
|
|
1441
|
+
}
|
|
1442
|
+
`,xp=Pt(ki)`
|
|
1443
|
+
white-space: nowrap;
|
|
1444
|
+
overflow: hidden;
|
|
1445
|
+
text-overflow: ellipsis;
|
|
1446
|
+
font-size: 14px;
|
|
1447
|
+
`,yp=({label:e,onClick:t,icon:o,iconSrc:r,badgeLabel:i,badgeFilled:n,isSelected:a,withBorder:s,color:l,hoverColor:c,style:d})=>{const p=Bt();return vt(fp,{onClick:t,className:a?"selected":"not-selected",$withBorder:s,$color:l,$hoverColor:c,style:d,children:[o&&$t("div",{children:$t(o,{fill:p.text.info})}),r&&$t("div",{children:$t("img",{src:r,alt:"",width:16,height:16})}),$t(xp,{children:e}),a&&$t("div",{children:$t(Je,{fill:p.colors.majestic_blue_soft})}),void 0!==i&&$t(Fn,{label:i,filled:n||a})]})},bp=Pt.div`
|
|
1448
|
+
display: flex;
|
|
1449
|
+
flex-direction: column;
|
|
1450
|
+
gap: 16px;
|
|
1451
|
+
${({$maxWidth:e})=>e&&`max-width: ${e};`}
|
|
1452
|
+
`,$p=Pt.div`
|
|
1453
|
+
display: flex;
|
|
1454
|
+
align-items: center;
|
|
1455
|
+
gap: 16px;
|
|
1456
|
+
`,vp=Pt.div`
|
|
1457
|
+
width: 50px;
|
|
1458
|
+
height: 50px;
|
|
1459
|
+
border-radius: 8px;
|
|
1460
|
+
background: ${({theme:e})=>`linear-gradient(90deg, ${e.colors.dropdown_bg_2} 25%, ${e.colors.dropdown_bg_2} 50%, ${e.colors.border} 75%)`};
|
|
1461
|
+
background-size: 200% 100%;
|
|
1462
|
+
animation: ${In} 10s infinite linear;
|
|
1463
|
+
`,wp=Pt(Aa)`
|
|
1464
|
+
flex: 1;
|
|
1465
|
+
gap: 12px;
|
|
1466
|
+
`,Sp=Pt.div`
|
|
1467
|
+
width: ${({$width:e})=>e};
|
|
1468
|
+
height: 16px;
|
|
1469
|
+
background: ${({theme:e})=>`linear-gradient(90deg, ${e.colors.dropdown_bg_2} 25%, ${e.colors.dropdown_bg_2} 50%, ${e.colors.border} 75%)`};
|
|
1470
|
+
background-size: 200% 100%;
|
|
1471
|
+
animation: ${In} 1.5s infinite linear;
|
|
1472
|
+
border-radius: 4px;
|
|
1473
|
+
`,Cp=({size:e=5,maxWidth:t})=>$t(bp,{$maxWidth:t,children:[...Array(e)].map((e,t)=>vt($p,{children:[$t(vp,{}),vt(wp,{children:[$t(Sp,{$width:"80%"}),$t(Sp,{$width:"100%"})]})]},t))});var kp;!function(e){e.Active="active",e.Disabled="disabled",e.Finished="finish"}(kp||(kp={}));const Ep=Pt.div`
|
|
1474
|
+
display: flex;
|
|
1475
|
+
flex-direction: column;
|
|
1476
|
+
gap: 32px;
|
|
1477
|
+
`,Ap=Pt.div`
|
|
1478
|
+
display: flex;
|
|
1479
|
+
gap: 16px;
|
|
1480
|
+
padding: 8px;
|
|
1481
|
+
opacity: ${({$state:e})=>e===kp.Active?1:e===kp.Disabled?.5:.8};
|
|
1482
|
+
transition: all 0.3s;
|
|
1483
|
+
`,Dp=Pt(Ea)`
|
|
1484
|
+
justify-content: center;
|
|
1485
|
+
width: 24px;
|
|
1486
|
+
height: 24px;
|
|
1487
|
+
border-radius: 32px;
|
|
1488
|
+
border: ${({theme:e,$state:t})=>t===kp.Disabled?`1px dashed ${e.text.dark_grey}`:`1px solid ${e.colors.secondary}`};
|
|
1489
|
+
opacity: ${({$state:e})=>e===kp.Finished?.8:1};
|
|
1490
|
+
`,Tp=Pt(Aa)`
|
|
1491
|
+
justify-content: center;
|
|
1492
|
+
gap: 8px;
|
|
1493
|
+
`,Np=Pt(ki)``,Ip=Pt(ki)``,_p=({data:e,currentStep:t=0})=>{const[o,r]=kt([]);return Et(()=>{r(e.map((e,o)=>o<t-1?{...e,state:kp.Finished,subtitle:e.subtitle||Oo.Success}:o===t-1?{...e,state:kp.Active,subtitle:""}:{...e,state:kp.Disabled,subtitle:""}))},[t,e]),$t(Ep,{children:o.map((e,t)=>vt(Ap,{$state:e.state,children:[$t(Dp,{$state:e.state,children:[kp.Active,kp.Disabled].includes(e.state)?$t(ki,{size:12,children:e.stepNumber}):e.state===kp.Finished?$t(Je,{size:20}):null}),vt(Tp,{children:[$t(Np,{family:"secondary",children:e.title}),e.subtitle&&$t(Ip,{size:10,weight:300,children:e.subtitle})]})]},t))})},Op=Pt(Ea)`
|
|
1494
|
+
width: fit-content;
|
|
1495
|
+
gap: 6px;
|
|
1496
|
+
padding: 6px 12px;
|
|
1497
|
+
border-radius: 360px;
|
|
1498
|
+
background-color: ${({$type:e,theme:t})=>t.colors[e]};
|
|
1499
|
+
`,Rp=Pt(ki)`
|
|
1500
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
1501
|
+
`,Fp=({type:e=Oo.Info,icon:t,title:o,size:r,family:i,children:n,...a})=>vt(Op,{$type:e,children:[t&&$t(t,{}),$t(Rp,{$type:e,size:r||12,family:i||"secondary",...a,children:n||o})]}),zp=Pt.div`
|
|
1502
|
+
display: flex;
|
|
1503
|
+
flex-direction: column;
|
|
1504
|
+
position: relative;
|
|
1505
|
+
width: 100%;
|
|
1506
|
+
`,Lp=Pt.div`
|
|
1507
|
+
width: 100%;
|
|
1508
|
+
display: flex;
|
|
1509
|
+
align-items: center;
|
|
1510
|
+
gap: 12px;
|
|
1511
|
+
transition: border-color 0.3s;
|
|
1512
|
+
border-radius: 24px;
|
|
1513
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1514
|
+
${({$disabled:e})=>e&&Mt`
|
|
1515
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
1516
|
+
cursor: not-allowed;
|
|
1517
|
+
opacity: 0.6;
|
|
1518
|
+
`}
|
|
1519
|
+
|
|
1520
|
+
${({$hasError:e})=>e&&Mt`
|
|
1521
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
1522
|
+
`}
|
|
1523
|
+
|
|
1524
|
+
${({$isActive:e})=>e&&Mt`
|
|
1525
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1526
|
+
`}
|
|
1527
|
+
|
|
1528
|
+
&:hover {
|
|
1529
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1530
|
+
}
|
|
1531
|
+
&:focus-within {
|
|
1532
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1533
|
+
}
|
|
1534
|
+
`,Pp=Pt.textarea`
|
|
1535
|
+
flex: 1;
|
|
1536
|
+
border: none;
|
|
1537
|
+
outline: none;
|
|
1538
|
+
background: none;
|
|
1539
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1540
|
+
font-size: 14px;
|
|
1541
|
+
padding: 12px 20px 0;
|
|
1542
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1543
|
+
font-weight: 300;
|
|
1544
|
+
line-height: 22px;
|
|
1545
|
+
&::placeholder {
|
|
1546
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1547
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1548
|
+
opacity: 0.4;
|
|
1549
|
+
font-size: 14px;
|
|
1550
|
+
font-weight: 300;
|
|
1551
|
+
line-height: 22px; /* 157.143% */
|
|
1552
|
+
}
|
|
1553
|
+
|
|
1554
|
+
&:disabled {
|
|
1555
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
1556
|
+
cursor: not-allowed;
|
|
1557
|
+
}
|
|
1558
|
+
`,Mp=({errorMessage:e,title:t,tooltip:o,required:r,onChange:i,name:n,...a})=>{const s=At(null),l=e=>{s.current&&(s.current.style.height="auto",e&&(s.current.style.height=`${s.current.scrollHeight}px`))};return vt(zp,{children:[$t(Vl,{title:t,required:r,tooltip:o}),$t(Lp,{$disabled:a.disabled,$hasError:!!e,$isActive:!!a.autoFocus,children:$t(Pp,{ref:s,"data-id":n,name:n,onFocus:()=>l(!0),onBlur:()=>l(!1),onChange:e=>{e.stopPropagation(),l(!0),i?.(e)},onKeyDown:e=>{e.stopPropagation()},...a})}),!!e&&$t(Di,{children:e})]})},Bp=Pt.div`
|
|
1559
|
+
display: flex;
|
|
1560
|
+
align-items: center;
|
|
1561
|
+
gap: 12px;
|
|
1562
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1563
|
+
opacity: ${({$disabled:e})=>e?.6:1};
|
|
1564
|
+
`,Up=Pt.div`
|
|
1565
|
+
width: 24px;
|
|
1566
|
+
height: 12px;
|
|
1567
|
+
border: 1px ${({$isActive:e,theme:t})=>e?`solid ${t.colors.majestic_blue}`:`dashed ${t.text.grey}`};
|
|
1568
|
+
border-radius: 20px;
|
|
1569
|
+
display: flex;
|
|
1570
|
+
align-items: center;
|
|
1571
|
+
padding: 2px;
|
|
1572
|
+
background-color: transparent;
|
|
1573
|
+
pointer-events: ${({$disabled:e})=>e?"none":"auto"};
|
|
1574
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1575
|
+
opacity: ${({$isActive:e})=>e?1:.5};
|
|
1576
|
+
transition: border-color 0.3s, opacity 0.3s;
|
|
1577
|
+
&::before {
|
|
1578
|
+
content: '';
|
|
1579
|
+
width: 12px;
|
|
1580
|
+
height: 12px;
|
|
1581
|
+
border-radius: 50%;
|
|
1582
|
+
background-color: ${({$isActive:e,theme:t})=>e?t.colors.majestic_blue:t.colors.secondary};
|
|
1583
|
+
transform: ${({$isActive:e})=>e?"translateX(12px)":"translateX(0)"};
|
|
1584
|
+
transition: background-color 0.3s, transform 0.3s;
|
|
1585
|
+
}
|
|
1586
|
+
`,jp=({title:e,tooltip:t,initialValue:o=!1,onChange:r,disabled:i,allowPropagation:n=!1,flipHorizontally:a})=>{const[s,l]=kt(o);Et(()=>l(o),[o]);return vt(Bp,{$disabled:i,onClick:e=>{i||(n||e.stopPropagation(),r?r(!s):l(e=>!e))},children:[!a&&$t(Up,{$disabled:i,$isActive:s}),(e||t)&&$t(Za,{text:t,withIcon:!0,children:e&&$t(ki,{size:14,children:e})}),a&&$t(Up,{$disabled:i,$isActive:s})]})};var Wp={v:"5.12.1",fr:60,ip:0,op:80,w:220,h:620,nm:"Odigos - Trace Loader",ddd:0,assets:[{id:"comp_0",nm:"moving lines-5",fr:60,layers:[{ddd:0,ind:1,ty:4,nm:"moving lines-5",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[6.097,.571,0],ix:2,l:2},a:{a:0,k:[-.046,-149.04,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-.055,-173.88],[.095,546.629]],c:!1},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:!1},{ty:"st",c:{a:0,k:[.976470588235,.976470588235,.976470588235,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:6,ix:5},lc:1,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:!1},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[85.714,85.714],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Vector",np:2,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:!1},{ty:"tm",s:{a:1,k:[{i:{x:[.757],y:[.459]},o:{x:[.441],y:[0]},t:2.4,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:18.172,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:36.174,s:[85.889]},{t:51,s:[100]}],ix:1},e:{a:1,k:[{i:{x:[.757],y:[.582]},o:{x:[.441],y:[0]},t:0,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:12.174,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:30.174,s:[85.889]},{t:45,s:[100]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:!1}],ip:0,op:51,st:-26,ct:1,bm:0}]},{id:"comp_1",nm:"moving lines-4",fr:60,layers:[{ddd:0,ind:1,ty:4,nm:"moving lines-4",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[5.475,.571,0],ix:2,l:2},a:{a:0,k:[.144,-156.04,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[.167,-182.047],[.314,547.797]],c:!1},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:!1},{ty:"st",c:{a:0,k:[.976470588235,.976470588235,.976470588235,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:6,ix:5},lc:1,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:!1},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[85.714,85.714],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Vector",np:2,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:!1},{ty:"tm",s:{a:1,k:[{i:{x:[.757],y:[.459]},o:{x:[.441],y:[0]},t:17.9,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:38.055,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:61.053,s:[85.889]},{t:80,s:[100]}],ix:1},e:{a:1,k:[{i:{x:[.757],y:[.582]},o:{x:[.441],y:[0]},t:0,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:15.553,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:38.555,s:[85.889]},{t:57.5,s:[100]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:!1}],ip:0,op:80,st:-26,ct:1,bm:0}]},{id:"comp_2",nm:"moving lines-3",fr:60,layers:[{ddd:0,ind:1,ty:4,nm:"moving lines-3",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[5.841,.571,0],ix:2,l:2},a:{a:0,k:[.324,-150.04,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[.382,-175.047],[-.051,538.464]],c:!1},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:!1},{ty:"st",c:{a:0,k:[.976470588235,.976470588235,.976470588235,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:6,ix:5},lc:1,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:!1},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[85.714,85.714],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Vector",np:2,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:!1},{ty:"tm",s:{a:1,k:[{i:{x:[.757],y:[.459]},o:{x:[.441],y:[0]},t:6,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:23.525,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:43.525,s:[85.889]},{t:60,s:[100]}],ix:1},e:{a:1,k:[{i:{x:[.757],y:[.582]},o:{x:[.441],y:[0]},t:0,s:[0]},{i:{x:[.574],y:[.569]},o:{x:[.451],y:[.436]},t:13.525,s:[23.624]},{i:{x:[.571],y:[1]},o:{x:[.173],y:[.635]},t:33.525,s:[85.889]},{t:50,s:[100]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:!1}],ip:0,op:60,st:-26,ct:1,bm:0}]}],layers:[{ddd:0,ind:1,ty:0,nm:"moving lines-5",refId:"comp_0",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[213,1,0],ix:2,l:2},a:{a:0,k:[6,0,0],ix:1,l:2},s:{a:0,k:[100,99.4,100],ix:6,l:2}},ao:0,w:12,h:619,ip:-22,op:29,st:-22,ct:1,bm:0},{ddd:0,ind:2,ty:0,nm:"moving lines-5",refId:"comp_0",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[213,1,0],ix:2,l:2},a:{a:0,k:[6,0,0],ix:1,l:2},s:{a:0,k:[100,99.4,100],ix:6,l:2}},ao:0,w:12,h:619,ip:56,op:107,st:56,ct:1,bm:0},{ddd:0,ind:3,ty:0,nm:"moving lines-5",refId:"comp_0",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[213,1,0],ix:2,l:2},a:{a:0,k:[6,0,0],ix:1,l:2},s:{a:0,k:[100,99.4,100],ix:6,l:2}},ao:0,w:12,h:619,ip:22,op:73,st:22,ct:1,bm:0},{ddd:0,ind:4,ty:0,nm:"moving lines-4",refId:"comp_1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[110.5,1,0],ix:2,l:2},a:{a:0,k:[5.5,0,0],ix:1,l:2},s:{a:0,k:[100,98.2,100],ix:6,l:2}},ao:0,w:11,h:627,ip:-65,op:15,st:-65,ct:1,bm:0},{ddd:0,ind:5,ty:0,nm:"moving lines-4",refId:"comp_1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[110.5,1,0],ix:2,l:2},a:{a:0,k:[5.5,0,0],ix:1,l:2},s:{a:0,k:[100,98.2,100],ix:6,l:2}},ao:0,w:11,h:627,ip:14,op:94,st:14,ct:1,bm:0},{ddd:0,ind:6,ty:0,nm:"moving lines-3",refId:"comp_2",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[7,1,0],ix:2,l:2},a:{a:0,k:[5.5,0,0],ix:1,l:2},s:{a:0,k:[100,100.4,100],ix:6,l:2}},ao:0,w:11,h:613,ip:2,op:62,st:2,ct:1,bm:0},{ddd:0,ind:7,ty:0,nm:"moving lines-3",refId:"comp_2",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[7,1,0],ix:2,l:2},a:{a:0,k:[5.5,0,0],ix:1,l:2},s:{a:0,k:[100,100.4,100],ix:6,l:2}},ao:0,w:11,h:613,ip:-36,op:20,st:-40,ct:1,bm:0},{ddd:0,ind:8,ty:0,nm:"moving lines-3",refId:"comp_2",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[7,1,0],ix:2,l:2},a:{a:0,k:[5.5,0,0],ix:1,l:2},s:{a:0,k:[100,100.4,100],ix:6,l:2}},ao:0,w:11,h:613,ip:39,op:99,st:39,ct:1,bm:0},{ddd:0,ind:9,ty:4,nm:"Vector :M",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[110,309.736,0],ix:2,l:2},a:{a:0,k:[308.5,313.236,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[205.677,618.844],[205.677,4.807]],c:!1},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:!1},{ind:1,ty:"sh",ix:2,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[411.428,618.822],[411.333,4.99]],c:!1},ix:2},nm:"Path 6",mn:"ADBE Vector Shape - Group",hd:!1},{ind:2,ty:"sh",ix:3,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[308.5,618.796],[308.5,5.145]],c:!1},ix:2},nm:"Path 7",mn:"ADBE Vector Shape - Group",hd:!1},{ty:"st",c:{a:0,k:[.975244164467,.975244164467,.975244164467,.639999985695],ix:3},o:{a:0,k:64,ix:4},w:{a:0,k:1,ix:5},lc:1,lj:1,ml:4,bm:0,nm:"Stroke 7",mn:"ADBE Vector Graphic - Stroke",hd:!1}],ip:0,op:684,st:0,ct:1,bm:0}],markers:[],props:{}};const Gp=Pt.div`
|
|
1587
|
+
width: ${({$width:e})=>e}px;
|
|
1588
|
+
height: ${({$height:e})=>e}px;
|
|
1589
|
+
position: relative;
|
|
1590
|
+
`,Vp=({width:e=620})=>{const{darkMode:t}=Bt(),o=e/(620/220);return $t(Gp,{$width:e,$height:o,children:$t(to,{autoplay:!0,loop:!0,animationData:Wp,style:{width:o,height:e,transform:"rotate(-90deg)",position:"absolute",top:-(o-o/10),left:o-o/10,filter:t?"invert(0)":"invert(1)"}})})},Xp=Pt.div`
|
|
1591
|
+
display: flex;
|
|
1592
|
+
align-items: center;
|
|
1593
|
+
justify-content: center;
|
|
1594
|
+
gap: 4px;
|
|
1595
|
+
min-width: ${({$minWidth:e})=>e};
|
|
1596
|
+
width: ${({$fullWidth:e})=>e?"100%":"fit-content"};
|
|
1597
|
+
padding: ${({$hasLabel:e})=>e?"4px 8px":"4px"};
|
|
1598
|
+
border-radius: 100px;
|
|
1599
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
1600
|
+
`,Hp=({label:e,leftIcon:t,rightIcon:o,tooltip:r,status:i=zo.Unknown,useSecondaryTone:n=!1,invertColors:a=!1,textSize:s,textColor:l,backgroundColor:c,minWidth:d="unset",fullWidth:p=!1})=>{const u=Bt(),h=e?.toString(),m=i?[zo.Disabled].includes(i)?Br(u,i,a?"400":"700"):[zo.Unknown].includes(i)?Br(u,i,"600"):Br(u,i,a?n?"400":"300":n?"700":"500"):u.v2.colors.grey[200],g=l||(a&&![zo.Unknown].includes(i)?m:[zo.Disabled].includes(i)?u.v2.colors.grey[400]:[Oo.Error,Oo.Warning,Oo.Success].includes(i)?u.v2.colors.black[500]:u.v2.colors.white[500]),f=c||(a&&![zo.Unknown].includes(i)?[zo.Disabled].includes(i)?u.v2.colors.grey[700]:u.v2.colors.silver[600]:m);return $t(Za,{text:r,fullWidth:p,children:vt(Xp,{$backgroundColor:f,$minWidth:d,$fullWidth:p,$hasLabel:!!h,children:[t&&$t(t,{fill:g,size:14}),h&&$t($i,{color:g,size:s||yi.XXS,nowrap:!0,children:h}),o&&$t(o,{fill:g,size:14})]})})};var Jp,Kp;!function(e){e.Primary="primary",e.Secondary="secondary",e.Text="text"}(Jp||(Jp={})),function(e){e.S="small",e.M="medium",e.L="large"}(Kp||(Kp={}));const qp=Pt.button`
|
|
1601
|
+
display: flex;
|
|
1602
|
+
align-items: center;
|
|
1603
|
+
justify-content: center;
|
|
1604
|
+
gap: 8px;
|
|
1605
|
+
${({$fullWidth:e})=>e&&Mt`
|
|
1606
|
+
width: 100%;
|
|
1607
|
+
`}
|
|
1608
|
+
border: none;
|
|
1609
|
+
border-radius: 6px;
|
|
1610
|
+
${({$size:e,$hasLabel:t})=>e===Kp.S?Mt`
|
|
1611
|
+
height: 32px;
|
|
1612
|
+
${t?Mt`
|
|
1613
|
+
padding: 8px 16px;
|
|
1614
|
+
`:Mt`
|
|
1615
|
+
width: 32px;
|
|
1616
|
+
`}
|
|
1617
|
+
`:e===Kp.M?Mt`
|
|
1618
|
+
height: 38px;
|
|
1619
|
+
${t?Mt`
|
|
1620
|
+
padding: 8px 18px;
|
|
1621
|
+
`:Mt`
|
|
1622
|
+
width: 38px;
|
|
1623
|
+
`}
|
|
1624
|
+
`:Mt`
|
|
1625
|
+
height: 44px;
|
|
1626
|
+
${t?Mt`
|
|
1627
|
+
padding: 8px 22px;
|
|
1628
|
+
`:Mt`
|
|
1629
|
+
width: 44px;
|
|
1630
|
+
`}
|
|
1631
|
+
`}
|
|
1632
|
+
|
|
1633
|
+
cursor: pointer;
|
|
1634
|
+
&:disabled {
|
|
1635
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1636
|
+
cursor: not-allowed;
|
|
1637
|
+
}
|
|
1638
|
+
&:enabled {
|
|
1639
|
+
${({$withShadow:e})=>e?Mt`
|
|
1640
|
+
box-shadow: 0 0 11px 0 rgba(0, 0, 0, 0.32);
|
|
1641
|
+
`:""}
|
|
1642
|
+
${({$variant:e})=>e===Jp.Primary?Mt`
|
|
1643
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[500]};
|
|
1644
|
+
&:hover {
|
|
1645
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[600]};
|
|
1646
|
+
}
|
|
1647
|
+
&:active {
|
|
1648
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[700]};
|
|
1649
|
+
}
|
|
1650
|
+
`:e===Jp.Secondary?Mt`
|
|
1651
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
1652
|
+
&:hover {
|
|
1653
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
1654
|
+
}
|
|
1655
|
+
&:active {
|
|
1656
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
1657
|
+
}
|
|
1658
|
+
`:e===Jp.Text?Mt`
|
|
1659
|
+
background-color: transparent;
|
|
1660
|
+
&:hover {
|
|
1661
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1662
|
+
}
|
|
1663
|
+
&:active {
|
|
1664
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
1665
|
+
}
|
|
1666
|
+
`:""}
|
|
1667
|
+
}
|
|
1668
|
+
`,Yp=It(({label:e,leftIcon:t,rightIcon:o,variant:r=Jp.Primary,size:i=Kp.M,iconSize:n,loading:a,fullWidth:s,withShadow:l,textColor:c,disabled:d,onClick:p,...u},h)=>{const m=Bt(),g=n||(i===Kp.L?18:16),f=i===Kp.L?yi.S:yi.XS,x=c||(d?m.v2.colors.grey[400]:m.v2.colors.white[500]),[y,b]=kt(!1),$=Dt(async e=>{e.stopPropagation(),b(!0),await(p?.(e)),b(!1)},[p]);return $t(qp,{ref:h,$variant:r,$size:i,$fullWidth:s,$withShadow:l,$hasLabel:!!e,disabled:d,onClick:a||y?void 0:$,...u,children:a||y?e?$t(Yd,{size:m.v2.text.size[f],textColor:x}):$t(Ms,{}):vt(wt,{children:[t&&$t(t,{size:g,fill:x}),e?$t($i,{size:f,weight:500,color:x,nowrap:!0,children:e}):null,o&&$t(o,{size:g,fill:x})]})})});Yp.displayName=Yp.name;const Qp=Pt.button`
|
|
1669
|
+
width: 100%;
|
|
1670
|
+
padding: 0;
|
|
1671
|
+
padding-right: 12px;
|
|
1672
|
+
display: flex;
|
|
1673
|
+
align-items: center;
|
|
1674
|
+
justify-content: flex-start;
|
|
1675
|
+
gap: 12px;
|
|
1676
|
+
border-radius: 8px;
|
|
1677
|
+
border: none;
|
|
1678
|
+
${({$hovered:e})=>e?Mt`
|
|
1679
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
1680
|
+
`:Mt`
|
|
1681
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1682
|
+
`}
|
|
1683
|
+
overflow: hidden;
|
|
1684
|
+
cursor: pointer;
|
|
1685
|
+
&:disabled {
|
|
1686
|
+
cursor: not-allowed;
|
|
1687
|
+
opacity: 0.5;
|
|
1688
|
+
}
|
|
1689
|
+
`,Zp=Pt.div`
|
|
1690
|
+
width: ${({$hasIcon:e})=>e?"56px":"0"};
|
|
1691
|
+
height: 56px;
|
|
1692
|
+
display: flex;
|
|
1693
|
+
align-items: center;
|
|
1694
|
+
justify-content: center;
|
|
1695
|
+
${({$hovered:e})=>e?Mt`
|
|
1696
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
1697
|
+
`:Mt`
|
|
1698
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
1699
|
+
`}
|
|
1700
|
+
`,eu=Pt.div`
|
|
1701
|
+
width: ${({$hasIcon:e})=>e?"calc(100% - 56px)":"100%"};
|
|
1702
|
+
display: flex;
|
|
1703
|
+
justify-content: space-between;
|
|
1704
|
+
align-items: center;
|
|
1705
|
+
gap: 8px;
|
|
1706
|
+
`,tu=({label:e,icon:t,loading:o,disabled:r,onClick:i})=>{const[n,a]=kt(!1);return vt(Qp,{$hovered:n,type:"button",disabled:r||o,onClick:i,onMouseEnter:()=>a(!0),onMouseLeave:()=>a(!1),children:[$t(Zp,{$hovered:n,$hasIcon:!!t,children:t&&$t(t,{size:36})}),vt(eu,{$hasIcon:!!t,children:[o?$t(Yd,{size:16}):$t($i,{variant:xi.Span,align:"center",children:e}),$t(ut,{rotate:90,size:24})]})]})},ou=({buttons:e})=>$t(Aa,{$gap:12,children:e.map(e=>$t(tu,{...e},e.label))}),ru=Pt.div`
|
|
1707
|
+
display: flex;
|
|
1708
|
+
align-items: center;
|
|
1709
|
+
flex-wrap: wrap;
|
|
1710
|
+
width: calc(100% - 24px);
|
|
1711
|
+
padding: 4px 12px;
|
|
1712
|
+
border-radius: 12px;
|
|
1713
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1714
|
+
`,iu=Pt.div`
|
|
1715
|
+
width: calc(${({$cellsPerRow:e})=>100/e+"%"} - 16px);
|
|
1716
|
+
margin: 8px;
|
|
1717
|
+
display: flex;
|
|
1718
|
+
flex-direction: column;
|
|
1719
|
+
gap: 4px;
|
|
1720
|
+
`,nu=({cellsPerRow:e,items:t})=>{const o=Bt(),{CopyButton:r}=qn();return $t(ru,{children:t.map(({id:i,title:n,label:a,withCopy:s,badge:l})=>vt(iu,{$cellsPerRow:e||t.length,children:[$t($i,{size:yi.XXXS,color:o.v2.colors.silver[200],nowrap:!0,children:n}),vt(Ea,{$gap:4,children:[l&&$t(Hp,{...l}),a&&$t($i,{size:yi.XS,nowrap:!0,children:a}),s&&$t(r,{value:a||l?.label?.toString()||"",size:Hn.XS})]})]},i))})};var au;!function(e){e.S="s",e.L="l"}(au||(au={}));const su=Pt.div`
|
|
1721
|
+
display: flex;
|
|
1722
|
+
align-items: center;
|
|
1723
|
+
gap: 2px;
|
|
1724
|
+
padding: 3px;
|
|
1725
|
+
border-radius: 8px;
|
|
1726
|
+
border: 1px solid ${({theme:e})=>e.v2.colors.grey[500]};
|
|
1727
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
1728
|
+
`,lu=Pt.button`
|
|
1729
|
+
flex: 1;
|
|
1730
|
+
display: flex;
|
|
1731
|
+
align-items: center;
|
|
1732
|
+
justify-content: center;
|
|
1733
|
+
gap: 8px;
|
|
1734
|
+
padding: ${({$size:e})=>e===au.S?"4px 8px":"8px 16px"};
|
|
1735
|
+
border-radius: 6px;
|
|
1736
|
+
border: none;
|
|
1737
|
+
box-shadow: ${({$isSelected:e})=>e?"0 0 11px 0 rgba(0, 0, 0, 0.32)":"none"};
|
|
1738
|
+
|
|
1739
|
+
${({$disabled:e,$isSelected:t,$selectedBgColor:o,theme:r})=>e?Mt`
|
|
1740
|
+
cursor: not-allowed;
|
|
1741
|
+
background-color: ${t?(o||r.v2.colors.black[500])+En["040"]:"transparent"};
|
|
1742
|
+
`:Mt`
|
|
1743
|
+
cursor: pointer;
|
|
1744
|
+
background-color: ${t?o||r.v2.colors.black[500]:"transparent"};
|
|
1745
|
+
&:hover {
|
|
1746
|
+
background-color: ${t?o||r.v2.colors.black[500]:r.v2.colors.silver[800]};
|
|
1747
|
+
}
|
|
1748
|
+
`}
|
|
1749
|
+
`,cu=({size:e=au.L,options:t=[],selected:o,setSelected:r,disabled:i})=>{const n=Bt(),a=i?n.v2.colors.grey[400]:n.v2.colors.white[500],s=e===au.S?yi.XXS:yi.XS,l=e===au.S?400:500;return $t(su,{"data-id":"segment",$count:t.length,children:t.map(({value:t,label:n,icon:c,selectedBgColor:d},p)=>vt(lu,{"data-id":n?`segment-${n}`:void 0,onClick:()=>!i&&r(t),$size:e,$disabled:i,$isSelected:o===t,$selectedBgColor:d,children:[c&&$t(c,{fill:a}),n&&$t($i,{size:s,weight:l,color:a,nowrap:!0,children:n})]},`segment-${n||p}-${t}`))})},du=Pt.div`
|
|
1750
|
+
box-sizing: border-box !important;
|
|
1751
|
+
width: ${({$width:e})=>e??"fit-content"};
|
|
1752
|
+
padding: ${({$withSegment:e})=>e?"2px 2px 2px 12px":"6px 12px"};
|
|
1753
|
+
display: flex;
|
|
1754
|
+
align-self: stretch;
|
|
1755
|
+
align-items: center;
|
|
1756
|
+
gap: 8px;
|
|
1757
|
+
overflow: hidden;
|
|
1758
|
+
border-radius: 6px;
|
|
1759
|
+
|
|
1760
|
+
border: none;
|
|
1761
|
+
border-radius: 6px;
|
|
1762
|
+
background: ${({$isHovered:e,$isActive:t,theme:o})=>e||t?o.v2.colors.silver[700]:o.v2.colors.silver[800]};
|
|
1763
|
+
`,pu=Pt.input`
|
|
1764
|
+
min-width: 0;
|
|
1765
|
+
flex: 1;
|
|
1766
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1767
|
+
font-size: 14px;
|
|
1768
|
+
font-weight: 400;
|
|
1769
|
+
line-height: 20px;
|
|
1770
|
+
|
|
1771
|
+
cursor: text;
|
|
1772
|
+
color: ${({$textColor:e})=>e};
|
|
1773
|
+
&::placeholder {
|
|
1774
|
+
color: ${({$textColor:e})=>e};
|
|
1775
|
+
}
|
|
1776
|
+
|
|
1777
|
+
overflow: hidden;
|
|
1778
|
+
text-overflow: ellipsis;
|
|
1779
|
+
white-space: nowrap;
|
|
1780
|
+
`,uu=({value:e,onChange:t,placeholder:o,width:r,segment:i})=>{const n=Bt(),[a,s]=kt(!1),[l,c]=kt(!1),[d,p]=kt(!1),u=a?n.v2.colors.white[500]:n.v2.colors.silver[200],h=!!i?.options?.length,m=Ct(()=>{if(h)return i?.options.find(e=>e.value===i.selected)?.label},[h,i?.options,i?.selected]),g=Ct(()=>o||(h&&m?`Search by ${m.toLowerCase()}`:"Search..."),[o,h,m]);return vt(du,{$width:r,$withSegment:h,onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1),$isHovered:l&&!d,$isActive:a,children:[$t(st,{size:18,fill:u}),$t(pu,{"data-id":"search",name:"search",type:"text",placeholder:g,value:e,onChange:e=>{e.stopPropagation(),t(e.target.value)},onFocus:()=>s(!0),onBlur:()=>s(!1),$textColor:u}),h&&$t("div",{style:{flexShrink:0},onMouseEnter:()=>p(!0),onMouseLeave:()=>p(!1),children:$t(cu,{options:i.options,selected:i.selected,setSelected:i.setSelected,size:au.S})})]})},hu=Pt.span`
|
|
1781
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1782
|
+
font-size: ${({$smallAndDark:e})=>e?"12px":"14px"};
|
|
1783
|
+
font-weight: 400;
|
|
1784
|
+
color: ${({theme:e,$smallAndDark:t})=>t?e.v2.colors.grey[400]:e.v2.colors.silver[200]};
|
|
1785
|
+
`,mu=Pt.span`
|
|
1786
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1787
|
+
font-size: 14px;
|
|
1788
|
+
font-weight: 400;
|
|
1789
|
+
color: ${({theme:e})=>e.v2.colors.red[500]};
|
|
1790
|
+
`,gu=({label:e,tooltip:t,required:o,badge:r,width:i,smallAndDark:n})=>e||t||o?vt(Ea,{$width:i,$justifyContent:"space-between",children:[e&&$t(hu,{$smallAndDark:n,children:e}),vt(Ea,{$gap:4,children:[r&&$t(Hp,{...r,textSize:yi.XXXS}),o&&$t(mu,{children:"*"}),t&&$t(Za,{text:t,withIcon:!0})]})]}):null,fu=({errorMessage:e,warnMessage:t,helpMessage:o})=>{const r=Bt(),i=e?r.v2.colors.red[500]:t?r.v2.colors.yellow[500]:r.v2.colors.silver[200],n=$t(Xe,{size:12,fill:i});return e||t||o?vt(Ea,{$alignItems:"center",children:[n&&$t(Aa,{children:n}),$t($i,{size:yi.XXS,weight:400,color:i,children:e||t||o})]}):null};var xu;!function(e){e.S="small",e.L="large"}(xu||(xu={}));const yu=Pt.div`
|
|
1791
|
+
width: fit-content;
|
|
1792
|
+
display: flex;
|
|
1793
|
+
align-items: center;
|
|
1794
|
+
gap: 8px;
|
|
1795
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1796
|
+
`,bu=Pt.div`
|
|
1797
|
+
width: ${({$size:e})=>e===xu.S?"16px":"20px"};
|
|
1798
|
+
height: ${({$size:e})=>e===xu.S?"16px":"20px"};
|
|
1799
|
+
display: flex;
|
|
1800
|
+
align-items: center;
|
|
1801
|
+
justify-content: center;
|
|
1802
|
+
border-radius: 4px;
|
|
1803
|
+
border: 1px solid ${({$borderColor:e})=>e};
|
|
1804
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
1805
|
+
`,$u=({name:e,label:t,tooltip:o,badge:r,size:i=xu.L,disabled:n,partiallyChecked:a,value:s,onChange:l,errorMessage:c,warnMessage:d,helpMessage:p})=>{const u=Bt(),[h,m]=kt(!1),g=a||s,f=i===xu.S?12:16,x=n?u.v2.colors.grey[400]:u.v2.colors.white[500],y=g?"transparent":n?u.v2.colors.grey[700]:h?u.v2.colors.silver[400]:u.v2.colors.silver[600],b=n?u.v2.colors.grey[600]:g?u.v2.colors.purple[500]:u.v2.colors.silver[900];return vt(Aa,{$gap:4,children:[vt(Ea,{$justifyContent:"space-between",children:[vt(yu,{"data-id":e||"checkbox"+(t?`-${t}`:""),onClick:e=>{e.stopPropagation(),n||l(!!a||!s)},$disabled:n,onMouseEnter:()=>m(!0),onMouseLeave:()=>m(!1),children:[$t(bu,{$size:i,$borderColor:y,$backgroundColor:b,children:a?$t(Ye,{size:f,fill:x}):s?$t(Je,{size:f,fill:x}):null}),t&&$t($i,{size:i===xu.S?yi.XXS:yi.XS,nowrap:!0,children:t})]}),$t(gu,{tooltip:o,badge:r})]}),$t(fu,{errorMessage:c,warnMessage:d,helpMessage:p})]})},vu=Pt.div`
|
|
1806
|
+
display: flex;
|
|
1807
|
+
flex-direction: ${({$direction:e})=>e===wo.Horizontal?"row":"column"};
|
|
1808
|
+
gap: ${({$direction:e})=>e===wo.Horizontal?16:8}px;
|
|
1809
|
+
`,wu=({direction:e=wo.Vertical,title:t,size:o,disabled:r,withSelectAll:i,options:n,values:a,setValues:s})=>{const l=o===xu.S?yi.XXS:yi.XS,c=Ct(()=>n.every(e=>a[e.id]),[n,a]),d=Ct(()=>n.some(e=>a[e.id])&&n.some(e=>!a[e.id]),[n,a]),p=(e,t)=>{s(o=>{const r={...o};return e?r[e]=t:n.forEach(e=>r[e.id]=t),r})};return vt(vu,{$direction:e,children:[t&&i?$t($u,{label:t,partiallyChecked:d,value:c,onChange:e=>p("",e),size:o}):t&&!i?$t($i,{size:l,children:t}):null,n.map(e=>$t($u,{...e,value:a[e.id],onChange:t=>p(e.id,t),disabled:r,size:o},`${t}-checkbox-${e.id}`))]})};var Su,Cu;!function(e){e.Left="left",e.Right="right"}(Su||(Su={})),function(e){e.Top="top",e.Bottom="bottom"}(Cu||(Cu={}));const ku=Pt.div`
|
|
1810
|
+
position: relative;
|
|
1811
|
+
`,Eu=Pt.div`
|
|
1812
|
+
display: flex;
|
|
1813
|
+
flex-direction: column;
|
|
1814
|
+
gap: 0;
|
|
1815
|
+
|
|
1816
|
+
min-width: 120px;
|
|
1817
|
+
width: ${({$fullWidth:e})=>e?"calc(100% - 16px)":"fit-content"};
|
|
1818
|
+
padding: 8px;
|
|
1819
|
+
border-radius: 6px;
|
|
1820
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
1821
|
+
box-shadow: 0 0 24px 0 rgba(0, 0, 0, 0.3);
|
|
1822
|
+
|
|
1823
|
+
position: absolute;
|
|
1824
|
+
${({$alignX:e})=>`${e}: 0;`}
|
|
1825
|
+
${({$alignY:e,$withOffsetY:t})=>`${e===Cu.Bottom?"top":"bottom"}: ${t?"calc(100% + 8px)":"0"};`}
|
|
1826
|
+
z-index: 1;
|
|
1827
|
+
`,Au=Pt.div`
|
|
1828
|
+
display: flex;
|
|
1829
|
+
flex-direction: column;
|
|
1830
|
+
gap: 0;
|
|
1831
|
+
|
|
1832
|
+
width: 100%;
|
|
1833
|
+
max-height: ${({$maxHeight:e})=>e||"230px"};
|
|
1834
|
+
overflow-y: auto;
|
|
1835
|
+
`,Du=Pt.div`
|
|
1836
|
+
display: flex;
|
|
1837
|
+
align-items: center;
|
|
1838
|
+
gap: 8px;
|
|
1839
|
+
width: calc(100% - 16px);
|
|
1840
|
+
padding: 8px;
|
|
1841
|
+
border-radius: 6px;
|
|
1842
|
+
cursor: pointer;
|
|
1843
|
+
${({$selected:e})=>e?Mt`
|
|
1844
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
1845
|
+
`:Mt`
|
|
1846
|
+
background-color: transparent;
|
|
1847
|
+
&:hover {
|
|
1848
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[700]};
|
|
1849
|
+
}
|
|
1850
|
+
`}
|
|
1851
|
+
`,Tu=({defaultOpen:e,alignX:t,alignY:o,items:r,selectedIds:i,setSelectedIds:n,withMultiSelect:a,withSearch:s,fullWidth:l,maxHeight:c,buttonProps:d,iconButtonProps:p,children:u})=>{const h=Bt(),m=!!d||!!p||!!u,[g,f]=kt(e??!m),[x,y]=kt({x:t||Su.Left,y:o||Cu.Bottom}),b=e=>{f(e=>!e),y({x:t||(e.clientX>window.innerWidth/2?Su.Right:Su.Left),y:o||(e.clientY>window.innerHeight/2?Cu.Top:Cu.Bottom)})},$=e=>{n(a?i.includes(e)?i.filter(t=>t!==e):[...i,e]:[e]),m&&!a&&f(!1)},v=At(null);ra(v,()=>f(!1));const[w,S]=kt(""),C=Ct(()=>w?r.filter(e=>e?.label?.toLowerCase().includes(w.toLowerCase())):r,[r.length,w]);return vt(ku,{ref:v,children:[d&&$t(Yp,{...d,fullWidth:l,rightIcon:g?ht:mt,onClick:b}),p&&$t(Kn,{...p,onClick:b}),"function"==typeof u?u({ChevronIcon:g?ht:mt,handleClick:b}):u,g&&vt(Eu,{$alignX:x.x,$alignY:x.y,$fullWidth:l,$withOffsetY:m,children:[s&&$t(uu,{value:w,onChange:S,width:"100%"}),$t(Au,{$maxHeight:c,children:C.map(e=>{if(!e)return null;const{id:t,label:o,icon:r,withCheckbox:n}=e,a=i.includes(t);return vt(Du,{$selected:a&&!n,onClick:()=>$(t),children:[n&&$t($u,{value:a,onChange:()=>$(t)}),r&&$t(r,{size:14,fill:h.v2.colors.white[500]}),$t($i,{size:yi.XS,nowrap:!0,children:o})]},t)})}),a&&$t(Yp,{label:"Done",onClick:()=>f(!1)})]})]})};var Nu;!function(e){e.Button="button",e.ButtonDropData="button-drop-data"}(Nu||(Nu={}));const Iu=({onAnyClick:e,actions:t})=>$t(Ea,{$gap:8,$alignItems:"center",children:t?.map(t=>{if(!t)return null;switch(t.type){case Nu.Button:return $t(Yp,{...t.buttonProps,onClick:o=>{t.buttonProps?.onClick?.(o),e?.()}},t.id);case Nu.ButtonDropData:return $t(Tu,{...t.dropDataProps,items:t.dropDataProps?.items??[],withMultiSelect:!1,selectedIds:[],setSelectedIds:o=>{t.buttonProps?.onClick?.(o[0]),e?.()},buttonProps:t.buttonProps},t.id);default:return null}})}),_u=Pt.div`
|
|
1852
|
+
display: flex;
|
|
1853
|
+
align-items: center;
|
|
1854
|
+
justify-content: center;
|
|
1855
|
+
padding: 8px;
|
|
1856
|
+
border-radius: 8px;
|
|
1857
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
1858
|
+
`,Ou=({icon:e,title:t,subTitle:o,withCopy:r,badge:i,children:n})=>{const a=Bt(),{CopyButton:s}=qn();return vt(Ea,{$gap:o?8:6,$alignItems:"center",children:[o?$t(_u,{children:$t(e,{size:24})}):$t(e,{size:24}),vt(Aa,{children:[vt(Ea,{$gap:6,$alignItems:"center",children:[$t($i,{nowrap:!0,children:t}),r&&$t(s,{value:t,size:Hn.XS}),i&&$t(Hp,{...i})]}),o&&$t($i,{size:yi.XXS,color:a.v2.colors.silver[200],nowrap:!0,children:o})]}),n]})};var Ru;!function(e){e.S="small",e.M="medium"}(Ru||(Ru={}));const Fu=Pt.div`
|
|
1859
|
+
display: flex;
|
|
1860
|
+
flex-direction: column;
|
|
1861
|
+
gap: ${({$gap:e})=>e}px;
|
|
1862
|
+
width: ${({$padding:e})=>`calc(100% - ${2*e}px)`};
|
|
1863
|
+
align-self: ${({$fullHeight:e})=>e?"stretch":"auto"};
|
|
1864
|
+
padding: ${({$padding:e})=>e}px;
|
|
1865
|
+
border-radius: 16px;
|
|
1866
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[1e3]};
|
|
1867
|
+
`,zu=({size:e=Ru.M,fullHeight:t=!1,richTitle:o,search:r,actions:i,children:n})=>{const a=e===Ru.S?4:16,s=e===Ru.S?12:16;return vt(Fu,{$padding:s,$gap:a,$fullHeight:t,children:[vt(Ea,{$gap:a,$justifyContent:"space-between",children:[$t(Ou,{...o,children:r&&$t(uu,{...r})}),$t(Iu,{actions:i??[]})]}),n]})},Lu=Pt.div`
|
|
1868
|
+
flex: 1;
|
|
1869
|
+
align-self: stretch;
|
|
1870
|
+
display: flex;
|
|
1871
|
+
align-items: center;
|
|
1872
|
+
gap: 8px;
|
|
1873
|
+
padding: 16px;
|
|
1874
|
+
border-radius: 12px;
|
|
1875
|
+
background-color: ${({theme:e,$status:t})=>Br(e,t,t===zo.Unknown?"750":"500")};
|
|
1876
|
+
`,Pu=Pt.div`
|
|
1877
|
+
display: flex;
|
|
1878
|
+
align-items: center;
|
|
1879
|
+
justify-content: center;
|
|
1880
|
+
width: fit-content;
|
|
1881
|
+
height: fit-content;
|
|
1882
|
+
padding: 8px;
|
|
1883
|
+
border-radius: 12px;
|
|
1884
|
+
background-color: ${({theme:e,$status:t})=>t===zo.Unknown?Br(e,t,"800"):Br(e,t,"900")+En["015"]};
|
|
1885
|
+
`,Mu=({status:e,icon:t,title:o,description:r})=>{const i=Bt(),n=t??jr(e,i),a=[Oo.Default,Oo.Info,zo.Disabled,zo.Unknown].includes(e)?i.v2.colors.white[500]:i.v2.colors.black[500];return vt(Lu,{$status:e,children:[$t(Pu,{$status:e,children:$t(n,{size:32,fill:a})}),vt(Aa,{$gap:2,$justifyContent:"center",children:[$t($i,{size:yi.M,weight:500,color:a,nowrap:!0,children:o}),$t($i,{size:yi.XXS,weight:300,color:a,nowrap:!0,children:r})]})]})},Bu=Pt.div`
|
|
1886
|
+
flex: 1;
|
|
1887
|
+
align-self: stretch;
|
|
1888
|
+
display: flex;
|
|
1889
|
+
flex-direction: column;
|
|
1890
|
+
gap: 12px;
|
|
1891
|
+
padding: 12px;
|
|
1892
|
+
border-radius: 12px;
|
|
1893
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1894
|
+
`,Uu=["-","N/A"],ju=({title:e,cells:t})=>{const o=Bt();return vt(Bu,{children:[$t($i,{size:yi.XXS,color:o.v2.colors.grey[150],children:e}),$t(Ea,{$gap:32,children:t.map(t=>vt(Aa,{$gap:2,children:[!t.isLoading||t.value&&!Uu.includes(t.value)?$t($i,{size:t.label?yi.M:yi.L,children:t.value}):$t(Ms,{scale:.9}),t.label&&$t($i,{size:yi.XXS,children:t.label})]},`${e}-${t.label}-${t.value}`))})]})},Wu=Pt(Ea)`
|
|
1895
|
+
width: calc(100% - 20px);
|
|
1896
|
+
padding: 10px;
|
|
1897
|
+
border-radius: 6px;
|
|
1898
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[800]};
|
|
1899
|
+
display: flex;
|
|
1900
|
+
align-items: center;
|
|
1901
|
+
justify-content: space-between;
|
|
1902
|
+
gap: 12px;
|
|
1903
|
+
`,Gu=Pt.div`
|
|
1904
|
+
position: relative;
|
|
1905
|
+
width: ${({$hideCopy:e})=>e?"100%":"calc(100% - 24px - 12px)"};
|
|
1906
|
+
display: flex;
|
|
1907
|
+
align-items: center;
|
|
1908
|
+
gap: 4px;
|
|
1909
|
+
`,Vu=Pt.pre`
|
|
1910
|
+
flex: 1;
|
|
1911
|
+
margin: 0;
|
|
1912
|
+
padding: 0;
|
|
1913
|
+
font-size: 14px;
|
|
1914
|
+
color: #5ffb98; // TODO: add to theme
|
|
1915
|
+
overflow-x: auto;
|
|
1916
|
+
`,Xu=Pt.span`
|
|
1917
|
+
flex-shrink: 0;
|
|
1918
|
+
font-size: 14px;
|
|
1919
|
+
color: #5ffb98; // TODO: add to theme
|
|
1920
|
+
`,Hu=({value:e,hideCopy:t=!1,onDone:o})=>{const{CopyButton:r}=qn({onDone:o}),i=At(null),[n,a]=kt(!1);return Et(()=>{const e=()=>{if(i.current){const{scrollWidth:e,clientWidth:t}=i.current;a(e>t)}};e();const t=new ResizeObserver(e);return i.current&&t.observe(i.current),()=>{t.disconnect()}},[e]),vt(Wu,{children:[vt(Gu,{$hideCopy:t,children:[$t(Vu,{ref:i,children:e}),n&&$t(Xu,{children:"..."})]}),!t&&$t(r,{value:e,size:Hn.XS})]})},Ju=Pt.div`
|
|
1921
|
+
display: flex;
|
|
1922
|
+
align-items: center;
|
|
1923
|
+
justify-content: space-between;
|
|
1924
|
+
width: calc(100%);
|
|
1925
|
+
`,Ku=Pt.div`
|
|
1926
|
+
display: flex;
|
|
1927
|
+
align-items: center;
|
|
1928
|
+
gap: 16px;
|
|
1929
|
+
padding: 6px 0;
|
|
1930
|
+
`,qu=Pt.div`
|
|
1931
|
+
display: flex;
|
|
1932
|
+
align-items: center;
|
|
1933
|
+
justify-content: center;
|
|
1934
|
+
width: 36px;
|
|
1935
|
+
height: 36px;
|
|
1936
|
+
border-radius: 8px;
|
|
1937
|
+
background: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1938
|
+
`,Yu=Pt.div`
|
|
1939
|
+
display: flex;
|
|
1940
|
+
align-items: center;
|
|
1941
|
+
gap: 12px;
|
|
1942
|
+
`,Qu=({icon:e,title:t,subTitle:o,actions:r,onClose:i,onCloseDisabled:n})=>vt(Ju,{children:[vt(Ku,{children:[e&&$t(qu,{children:$t(e,{size:24})}),(t||o)&&vt(Aa,{$gap:6,children:[t&&$t($i,{size:yi.S,weight:500,children:t}),o&&$t($i,{size:yi.XXS,children:o})]})]}),vt(Yu,{children:[r?.length?$t(Kn,{icon:gt,size:Hn.M,onClick:()=>alert("todo")}):null,i&&$t(Kn,{icon:qe,size:Hn.M,onClick:i,disabled:n})]})]}),Zu=Pt.div`
|
|
1943
|
+
position: fixed;
|
|
1944
|
+
top: 0;
|
|
1945
|
+
bottom: 0;
|
|
1946
|
+
${({$position:e})=>e}: 0;
|
|
1947
|
+
z-index: 1000;
|
|
1948
|
+
|
|
1949
|
+
display: flex;
|
|
1950
|
+
flex-direction: column;
|
|
1951
|
+
gap: 12px;
|
|
1952
|
+
|
|
1953
|
+
width: calc(${({$width:e})=>e} - 32px);
|
|
1954
|
+
padding: 12px;
|
|
1955
|
+
border-radius: ${({$position:e})=>"left"===e?"0 20px 20px 0":"20px 0 0 20px"};
|
|
1956
|
+
background: ${({theme:e})=>e.v2.colors.black[500]};
|
|
1957
|
+
box-shadow: 0 0 34px 0 rgba(0, 0, 0, 0.7);
|
|
1958
|
+
overflow: hidden;
|
|
1959
|
+
|
|
1960
|
+
animation-name: ${({$position:e})=>Dn.in[e]};
|
|
1961
|
+
`,eh=Pt.div`
|
|
1962
|
+
display: flex;
|
|
1963
|
+
flex-direction: column;
|
|
1964
|
+
gap: 12px;
|
|
1965
|
+
|
|
1966
|
+
height: calc(100% - ${56}px);
|
|
1967
|
+
overflow-y: auto;
|
|
1968
|
+
`,th=({isOpen:e,hideOverlay:t=!1,position:o="right",width:r="600px",header:i,children:n})=>(Wn(e),e?Yt(vt(wt,{children:[!t&&$t(Na,{onClick:i?.onCloseDisabled?void 0:i?.onClose}),vt(Zu,{$position:o,$width:r,children:[i&&$t(Qu,{...i}),$t(eh,{children:n})]})]}),document.body):null),oh=Pt.div`
|
|
1969
|
+
padding: ${({$small:e})=>e?"4px":"8px 12px"};
|
|
1970
|
+
|
|
1971
|
+
display: flex;
|
|
1972
|
+
align-self: stretch;
|
|
1973
|
+
align-items: center;
|
|
1974
|
+
gap: 8px;
|
|
1975
|
+
border-radius: 6px;
|
|
1976
|
+
|
|
1977
|
+
border: 1px solid ${({theme:e,$disabled:t,$error:o})=>t?e.v2.colors.grey[600]:o?e.v2.colors.red[500]:e.v2.colors.silver[500]};
|
|
1978
|
+
background: ${({theme:e,$disabled:t})=>t?e.v2.colors.grey[800]:e.v2.colors.black[500]};
|
|
1979
|
+
${({$disabled:e,$error:t})=>!e&&!t&&Mt`
|
|
1980
|
+
&:hover,
|
|
1981
|
+
&:active,
|
|
1982
|
+
&:focus-within {
|
|
1983
|
+
border: 1px solid ${({theme:e})=>e.v2.colors.silver[300]};
|
|
1984
|
+
}
|
|
1985
|
+
`}
|
|
1986
|
+
`,rh=Pt.input`
|
|
1987
|
+
max-width: ${({$maxWidth:e})=>e||"unset"};
|
|
1988
|
+
width: ${({$width:e})=>e||"unset"};
|
|
1989
|
+
|
|
1990
|
+
flex: 1;
|
|
1991
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1992
|
+
font-size: ${({$small:e})=>e?"12px":"14px"};
|
|
1993
|
+
font-weight: 400;
|
|
1994
|
+
|
|
1995
|
+
cursor: text;
|
|
1996
|
+
color: ${({theme:e})=>e.v2.colors.white[500]};
|
|
1997
|
+
&::placeholder {
|
|
1998
|
+
color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
1999
|
+
}
|
|
2000
|
+
|
|
2001
|
+
&:disabled {
|
|
2002
|
+
cursor: not-allowed;
|
|
2003
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
2004
|
+
&::placeholder {
|
|
2005
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
2006
|
+
}
|
|
2007
|
+
}
|
|
2008
|
+
|
|
2009
|
+
overflow: hidden;
|
|
2010
|
+
text-overflow: ellipsis;
|
|
2011
|
+
white-space: nowrap;
|
|
2012
|
+
`,ih=Pt.div`
|
|
2013
|
+
display: flex;
|
|
2014
|
+
align-items: center;
|
|
2015
|
+
justify-content: center;
|
|
2016
|
+
cursor: pointer;
|
|
2017
|
+
`,nh=({label:e,required:t,tooltip:o,badge:r,leftIcon:i,rightIcon:n,hasError:a,errorMessage:s,warnMessage:l,helpMessage:c,type:d=_o.Text,name:p,value:u,onChange:h,disabled:m,maxWidth:g,width:f,small:x=!1,...y})=>{const b=Bt(),$=d===_o.Password,[v,w]=kt(!1),[S,C]=kt(null),k=a||!!s||!!S,E=u?b.v2.colors.white[500]:m?b.v2.colors.grey[400]:b.v2.colors.silver[200],A=x?14:18;return vt(Aa,{$width:f,$gap:6,children:[$t(gu,{label:e,tooltip:o,required:t,badge:r}),vt(oh,{$small:x,$disabled:m,$error:k,children:[i?$t(i,{size:A,fill:E}):null,$t(rh,{"data-id":p,type:v||d===_o.Number?_o.Text:d,name:p,value:u,onChange:e=>{e.stopPropagation();const t=e.target.value;d===_o.Number&&(e.target.value=ci(t),t&&t!==e.target.value?C("Please enter a valid number"):C(null)),h?.(e)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},disabled:m,$maxWidth:g,$width:f,$small:x,...y}),$?$t(ih,{onClick:()=>w(e=>!e),children:$t(v?nt:at,{size:A,fill:E})}):n?$t(n,{size:A,fill:E}):null]}),$t(fu,{errorMessage:S||s,warnMessage:l,helpMessage:c})]})},ah=({options:e,values:t,setValues:o,withMultiSelect:r,withSearch:i,...n})=>{const a=Ct(()=>e.map(e=>({...e,withCheckbox:!0})),[e]),s=Ct(()=>t?.length?`Selected: ${e.filter(e=>t.includes(e.id)).map(e=>e.label).join(", ")}`:"",[e,t]);return $t(Tu,{withMultiSelect:r,withSearch:i,alignX:Su.Left,items:a,selectedIds:t,setSelectedIds:o,children:({ChevronIcon:e,handleClick:t})=>$t(nh,{placeholder:"Select options...",...n,rightIcon:e,value:s,onChange:()=>{},onClick:t})})},sh=Pt.header`
|
|
2018
|
+
position: relative;
|
|
2019
|
+
width: calc(100% - 36px);
|
|
2020
|
+
padding: 12px 18px;
|
|
2021
|
+
background-color: ${({theme:e})=>e.v2.colors.black[500]};
|
|
2022
|
+
display: flex;
|
|
2023
|
+
align-items: center;
|
|
2024
|
+
justify-content: space-between;
|
|
2025
|
+
`,lh=Pt(Ea)`
|
|
2026
|
+
position: absolute;
|
|
2027
|
+
left: 50%;
|
|
2028
|
+
transform: translateX(-50%);
|
|
2029
|
+
gap: 16px;
|
|
2030
|
+
`,ch=({left:e=[],center:t=[],right:o=[]})=>vt(sh,{children:[$t(Ea,{$gap:16,children:e}),$t(lh,{children:t}),$t(Ea,{$gap:16,children:o})]}),dh=Pt.div`
|
|
2031
|
+
display: flex;
|
|
2032
|
+
align-items: center;
|
|
2033
|
+
gap: 2px;
|
|
2034
|
+
width: fit-content;
|
|
2035
|
+
padding: 4px;
|
|
2036
|
+
border-radius: 8px;
|
|
2037
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
2038
|
+
box-shadow: 0 3px 8px 0 rgba(0, 0, 0, 0.25);
|
|
2039
|
+
|
|
2040
|
+
position: absolute;
|
|
2041
|
+
right: ${({$right:e})=>e||"12px"};
|
|
2042
|
+
top: 50%;
|
|
2043
|
+
transform: translateY(-50%);
|
|
2044
|
+
`,ph=({isOpen:e,actions:t,positionRight:o})=>e?$t(dh,{$right:o,children:t.map(e=>e?$t(Za,{text:e.tooltip||"",children:$t(Yp,{...e,variant:Jp.Secondary,size:Kp.S,label:e.label})},e.id):null)}):null,uh=({values:e,setValues:t,name:o,label:r,tooltip:i,badge:n,required:a,errorMessage:s,warnMessage:l,helpMessage:c,placeholder:d,disabled:p})=>{const u=Bt(),h=e.length<=1,m=p,g=p||h&&m;return vt(Aa,{"data-id":o,$gap:6,children:[$t(gu,{label:r,tooltip:i,required:a,badge:n}),$t(Aa,{$gap:8,children:(e.length?e:[""]).map((o,r)=>{const i=r===e.length-1;return vt(Ea,{$gap:8,$alignItems:"center",children:[$t(nh,{width:"100%",autoFocus:Yr(o)&&!h&&i,value:o,onChange:o=>((o,r)=>{const i=[...e||[]];i[r]=o,t(i)})(o.target.value,r),disabled:p,placeholder:d,hasError:!!s}),$t(Yp,{leftIcon:tt,variant:Jp.Secondary,size:Kp.S,disabled:m,onClick:()=>(()=>{const o=[...e||[]];o.push(""),t(o)})()}),$t(Yp,{leftIcon:g?lt:()=>$t(lt,{fill:u.v2.colors.red[500]}),variant:Jp.Secondary,size:Kp.S,disabled:g,onClick:()=>(o=>{const r=[...e||[]].filter((e,t)=>t!==o);r.length||r.push(""),t(r)})(r)})]},`input-list-${r}`)})}),$t(fu,{errorMessage:s,warnMessage:l,helpMessage:c})]})},hh=({col:e,colIdx:t,row:o,rowIdx:r,rowsLength:i,handleChange:n,errorMessage:a,disabled:s})=>{const{keyName:l,componentType:c,inputType:d,label:p,placeholder:u,options:h,renderCondition:m}=e,g=o[l];if(m&&!m(o))return null;switch(c){case Io.Dropdown:case"multi-dropdown":const e=Array.isArray(g)&&h?.filter(e=>g.includes(e.id)).map(e=>e.id)||[],o="multi-dropdown"===c;return $t(ah,{label:u?p:void 0,placeholder:u||p,options:h||[],withMultiSelect:o,withSearch:o,values:e,setValues:e=>n(l,e,r),disabled:s,hasError:!!a});default:const m=i>1&&0===r&&0===t&&Yr(g);return $t(nh,{label:u?p:void 0,placeholder:u||p,autoFocus:m,type:d,value:g,onChange:({target:{value:e}})=>n(l,e,r),disabled:s,hasError:!!a})}},mh=Pt.table`
|
|
2045
|
+
width: 100%;
|
|
2046
|
+
border-collapse: separate;
|
|
2047
|
+
border-spacing: 0 8px;
|
|
2048
|
+
`,gh=Pt.td`
|
|
2049
|
+
padding: 0 8px 0 0;
|
|
2050
|
+
`,fh=Pt.td`
|
|
2051
|
+
width: 72px;
|
|
2052
|
+
padding-bottom: 2px;
|
|
2053
|
+
vertical-align: bottom;
|
|
2054
|
+
`,xh=({columns:e,values:t,setValues:o,name:r,label:i,tooltip:n,badge:a,required:s,disabled:l,errorMessage:c,warnMessage:d,helpMessage:p,limitFieldsPerRow:u})=>{const h=Bt(),m=Ct(()=>{const t={};return e.forEach(({keyName:e})=>t[e]=""),t},[e]),g=(e,r,i)=>{const n=t.length?so(t):[so(m)];n[i][e]=r,o(n)},f=Ct(()=>{if(u){const t=[];for(let o=0;;o+=u){const r=e.slice(o,o+u);if(!r.length)break;t.push(r)}return t}return[e]},[u,e]),x=t.length?t:[m];return vt(Aa,{"data-id":r,$gap:0,children:[$t(gu,{label:i,tooltip:n,required:s,badge:a}),$t(mh,{children:$t("tbody",{children:x.map((e,r)=>vt(St,{children:[u&&r>0?$t("tr",{children:$t(gh,{colSpan:f.length})}):null,f.map((i,n)=>vt("tr",{children:[i.map((t,o)=>t.renderCondition&&!t.renderCondition(e)?null:$t(gh,{children:$t(hh,{col:t,colIdx:o,row:e,rowIdx:r,rowsLength:x.length,handleChange:g,disabled:l,errorMessage:c})},`input-table-row-${r}-col-${n}-${o}`)),0===n&&$t(fh,{children:vt(Ea,{$gap:8,$justifyContent:"center",children:[$t(Yp,{leftIcon:tt,variant:Jp.Secondary,size:Kp.S,disabled:l,onClick:()=>(()=>{const e=so(t);e.push(so(m)),o(e)})()}),$t(Yp,{leftIcon:l?lt:()=>$t(lt,{fill:h.v2.colors.red[500]}),variant:Jp.Secondary,size:Kp.S,disabled:l,onClick:()=>(e=>{const r=t.filter((t,o)=>o!==e);r.length||r.push(so(m)),o(r)})(r)})]})})]},`input-table-matrix-${r}-${n}`))]},`input-table-row-${r}`))})}),$t(fu,{errorMessage:c,warnMessage:d,helpMessage:p})]})},yh=Pt.div`
|
|
2055
|
+
display: flex;
|
|
2056
|
+
align-items: center;
|
|
2057
|
+
justify-content: space-between;
|
|
2058
|
+
gap: 32px;
|
|
2059
|
+
|
|
2060
|
+
padding: 18px 16px;
|
|
2061
|
+
border-radius: 18px;
|
|
2062
|
+
background-color: ${({theme:e})=>e.v2.colors.black[500]+En["095"]};
|
|
2063
|
+
box-shadow: 0 4px 16.7px 0 rgba(0, 0, 0, 0.83);
|
|
2064
|
+
|
|
2065
|
+
position: fixed;
|
|
2066
|
+
bottom: 0;
|
|
2067
|
+
left: 50%;
|
|
2068
|
+
z-index: 1;
|
|
2069
|
+
animation-name: ${Dn.in.center};
|
|
2070
|
+
`,bh=({isOpen:e,onClose:t,richTitle:o,actions:r})=>e?vt(yh,{children:[$t(Ou,{...o}),$t(Iu,{onAnyClick:t,actions:r})]}):null,$h=Pt.div`
|
|
2071
|
+
border-radius: 100%;
|
|
2072
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
2073
|
+
position: relative;
|
|
2074
|
+
`,vh=Pt.div`
|
|
2075
|
+
width: 80px;
|
|
2076
|
+
height: 80px;
|
|
2077
|
+
border-radius: 100%;
|
|
2078
|
+
border: 4px solid ${({theme:e})=>e.v2.colors.green[300]};
|
|
2079
|
+
border-right-color: transparent;
|
|
2080
|
+
border-left-color: transparent;
|
|
2081
|
+
border-bottom-color: transparent;
|
|
2082
|
+
animation: spin 1s linear infinite;
|
|
2083
|
+
@keyframes spin {
|
|
2084
|
+
to {
|
|
2085
|
+
transform: rotate(360deg);
|
|
2086
|
+
}
|
|
2087
|
+
}
|
|
2088
|
+
`,wh=Pt($i)`
|
|
2089
|
+
position: absolute;
|
|
2090
|
+
top: 50%;
|
|
2091
|
+
left: 50%;
|
|
2092
|
+
transform: translate(-50%, -50%);
|
|
2093
|
+
`,Sh=({percentage:e})=>vt($h,{children:[$t(vh,{}),"number"==typeof e?$t(wh,{size:yi.M,weight:500,children:`${e}%`}):null]}),Ch={cm:!0,mm:!0,in:!0,px:!0,pt:!0,pc:!0,em:!0,ex:!0,ch:!0,rem:!0,vw:!0,vh:!0,vmin:!0,vmax:!0,"%":!0};function kh(e){if("number"==typeof e)return{value:e,unit:"px"};let t;const o=(e.match(/^[0-9.]*/)||"").toString();t=o.includes(".")?parseFloat(o):parseInt(o,10);const r=(e.match(/[^0-9]*$/)||"").toString();return Ch[r]?{value:t,unit:r}:{value:t,unit:"px"}}function Eh(e){const t=kh(e);return`${t.value}${t.unit}`}const Ah=((e,t,o)=>{const r=`react-spinners-${e}-${o}`;if("undefined"==typeof window||!window.document)return r;const i=document.createElement("style");document.head.appendChild(i);const n=i.sheet,a=`\n @keyframes ${r} {\n ${t}\n }\n `;return n&&n.insertRule(a,0),r})("SpinnerOld","50% {opacity: 0.3} 100% {opacity: 1}","fade"),Dh=({loading:e=!0,color:t,scale:o=1,speedMultiplier:r=1,cssOverride:i={},style:n={},...a})=>{const s=Bt(),l=t||s.text.secondary;if(!e)return null;const{value:c}=kh(2),d=c+4.2,p=d/2+d/5.5,u=4*d*o,h={position:"relative",width:`${u}px`,height:`${u}px`,scale:o,...n,...i},m=(e,t)=>({position:"absolute",width:Eh(1.5),height:Eh(4),borderRadius:Eh(2),backgroundColor:l,transition:"2s",animationFillMode:"both",animation:`${Ah} ${1.2/r}s ${.12*e}s infinite ease-in-out`,transform:`translate(-50%, -50%) rotate(${t}deg)`});return vt("span",{style:h,...a,children:[$t("span",{style:{...m(1,0),top:`calc(50% + ${d}px)`,left:"50%"}}),$t("span",{style:{...m(2,-45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${p}px)`}}),$t("span",{style:{...m(3,90),top:"50%",left:`calc(50% + ${d}px)`}}),$t("span",{style:{...m(4,45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${p}px)`}}),$t("span",{style:{...m(5,0),top:`calc(50% + ${-1*d}px)`,left:"50%"}}),$t("span",{style:{...m(6,-45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${-1*p}px)`}}),$t("span",{style:{...m(7,90),top:"50%",left:`calc(50% + ${-1*d}px)`}}),$t("span",{style:{...m(8,45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${-1*p}px)`}})]})},Th=Pt.div`
|
|
2094
|
+
width: ${({$size:e})=>e}px;
|
|
2095
|
+
height: ${({$size:e})=>e}px;
|
|
2096
|
+
border-radius: 100%;
|
|
2097
|
+
background: ${({$color:e})=>e};
|
|
2098
|
+
display: flex;
|
|
2099
|
+
align-items: center;
|
|
2100
|
+
justify-content: center;
|
|
2101
|
+
`,Nh=({scale:e,icon:t})=>{const o=Bt();return $t(Th,{$size:45*e,$color:"rgba(80, 246, 232, 0.10)",children:$t(Th,{$size:43*e,$color:"rgba(80, 246, 232, 0.20)",children:$t(Th,{$size:39*e,$color:"rgba(80, 246, 232, 0.40)",children:$t(Th,{$size:33*e,$color:"rgba(80, 246, 232, 0.60)",children:$t(Th,{$size:23*e,$color:"#50F6E8",children:$t(t,{size:16*e,fill:o.v2.colors.black[500]})})})})})})},Ih=434,_h=635,Oh=Pt.div`
|
|
2102
|
+
width: ${434}px;
|
|
2103
|
+
height: ${635}px;
|
|
2104
|
+
display: flex;
|
|
2105
|
+
flex-direction: column;
|
|
2106
|
+
align-items: center;
|
|
2107
|
+
justify-content: center;
|
|
2108
|
+
padding: 16px;
|
|
2109
|
+
background: linear-gradient(180deg, #0b0517 2.82%, #190d31 100%);
|
|
2110
|
+
position: relative;
|
|
2111
|
+
`,Rh=Pt.div`
|
|
2112
|
+
position: absolute;
|
|
2113
|
+
top: 50%;
|
|
2114
|
+
left: 50%;
|
|
2115
|
+
transform: translate(-50%, -50%);
|
|
2116
|
+
`,Fh=()=>vt(Oh,{children:[$t(Rh,{children:vt("svg",{xmlns:"http://www.w3.org/2000/svg",width:"464",height:"464",viewBox:"0 0 464 464",fill:"none",children:[$t("path",{opacity:"0.1",d:"M231.567 463.134C359.458 463.134 463.134 359.458 463.134 231.567C463.134 103.676 359.458 0 231.567 0C103.676 0 0 103.676 0 231.567C0 359.458 103.676 463.134 231.567 463.134Z",fill:"url(#paint0_radial_164_65835)"}),$t("defs",{children:vt("radialGradient",{id:"paint0_radial_164_65835",cx:"0",cy:"0",r:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"translate(201.232 229.641) scale(231.217)",children:[$t("stop",{stopColor:"#7C3BFF",stopOpacity:"0.1"}),$t("stop",{offset:"0.41",stopColor:"#7C3BFF",stopOpacity:"0.11"}),$t("stop",{offset:"0.56",stopColor:"#7C3BFF",stopOpacity:"0.13"}),$t("stop",{offset:"0.67",stopColor:"#7C3BFF",stopOpacity:"0.18"}),$t("stop",{offset:"0.75",stopColor:"#7C3BFF",stopOpacity:"0.25"}),$t("stop",{offset:"0.83",stopColor:"#7C3BFF",stopOpacity:"0.33"}),$t("stop",{offset:"0.89",stopColor:"#7C3BFF",stopOpacity:"0.44"}),$t("stop",{offset:"0.95",stopColor:"#7C3BFF",stopOpacity:"0.56"}),$t("stop",{offset:"1",stopColor:"#7C3BFF",stopOpacity:"0.7"})]})})]})}),$t(Rh,{children:vt("svg",{xmlns:"http://www.w3.org/2000/svg",width:"432",height:"432",viewBox:"0 0 432 432",fill:"none",children:[$t("path",{opacity:"0.3",d:"M215.921 431.841C335.17 431.841 431.841 335.17 431.841 215.921C431.841 96.6709 335.17 0 215.921 0C96.6709 0 0 96.6709 0 215.921C0 335.17 96.6709 431.841 215.921 431.841Z",fill:"url(#paint0_radial_164_65836)"}),$t("defs",{children:vt("radialGradient",{id:"paint0_radial_164_65836",cx:"0",cy:"0",r:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"translate(204.229 214.376) scale(216.276)",children:[$t("stop",{stopColor:"#7C3BFF",stopOpacity:"0.1"}),$t("stop",{offset:"0.38",stopColor:"#7C3BFF",stopOpacity:"0.11"}),$t("stop",{offset:"0.52",stopColor:"#7C3BFF",stopOpacity:"0.13"}),$t("stop",{offset:"0.62",stopColor:"#7C3BFF",stopOpacity:"0.18"}),$t("stop",{offset:"0.69",stopColor:"#7C3BFF",stopOpacity:"0.25"}),$t("stop",{offset:"0.76",stopColor:"#7C3BFF",stopOpacity:"0.33"}),$t("stop",{offset:"0.82",stopColor:"#7C3BFF",stopOpacity:"0.44"}),$t("stop",{offset:"0.88",stopColor:"#7C3BFF",stopOpacity:"0.57"}),$t("stop",{offset:"0.93",stopColor:"#7C3BFF",stopOpacity:"0.72"}),$t("stop",{offset:"0.97",stopColor:"#7C3BFF",stopOpacity:"0.88"}),$t("stop",{offset:"1",stopColor:"#7C3BFF"})]})})]})}),$t(Rh,{children:vt("svg",{xmlns:"http://www.w3.org/2000/svg",width:"374",height:"374",viewBox:"0 0 374 374",fill:"none",children:[$t("path",{opacity:"0.5",d:"M186.963 373.927C290.22 373.927 373.927 290.22 373.927 186.963C373.927 83.7063 290.22 0 186.963 0C83.7063 0 0 83.7063 0 186.963C0 290.22 83.7063 373.927 186.963 373.927Z",fill:"url(#paint0_radial_164_65837)"}),$t("defs",{children:vt("radialGradient",{id:"paint0_radial_164_65837",cx:"0",cy:"0",r:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"translate(166.792 184.246) scale(186.963)",children:[$t("stop",{stopColor:"#7C3BFF",stopOpacity:"0.1"}),$t("stop",{offset:"0.31",stopColor:"#7C3BFF",stopOpacity:"0.11"}),$t("stop",{offset:"0.45",stopColor:"#7C3BFF",stopOpacity:"0.14"}),$t("stop",{offset:"0.56",stopColor:"#7C3BFF",stopOpacity:"0.19"}),$t("stop",{offset:"0.65",stopColor:"#7C3BFF",stopOpacity:"0.26"}),$t("stop",{offset:"0.73",stopColor:"#7C3BFF",stopOpacity:"0.35"}),$t("stop",{offset:"0.8",stopColor:"#7C3BFF",stopOpacity:"0.46"}),$t("stop",{offset:"0.86",stopColor:"#7C3BFF",stopOpacity:"0.6"}),$t("stop",{offset:"0.92",stopColor:"#7C3BFF",stopOpacity:"0.76"}),$t("stop",{offset:"0.98",stopColor:"#7C3BFF",stopOpacity:"0.93"}),$t("stop",{offset:"1",stopColor:"#7C3BFF"})]})})]})}),$t(Rh,{children:vt("svg",{xmlns:"http://www.w3.org/2000/svg",width:"257",height:"257",viewBox:"0 0 257 257",fill:"none",children:[$t("path",{opacity:"0.7",d:"M128.193 256.387C198.992 256.387 256.387 198.992 256.387 128.193C256.387 57.3941 198.992 0 128.193 0C57.3941 0 0 57.3941 0 128.193C0 198.992 57.3941 256.387 128.193 256.387Z",fill:"url(#paint0_radial_164_65838)"}),$t("defs",{children:vt("radialGradient",{id:"paint0_radial_164_65838",cx:"0",cy:"0",r:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"translate(113.263 126.219) scale(128.08)",children:[$t("stop",{stopColor:"#7C3BFF",stopOpacity:"0.1"}),$t("stop",{offset:"0.31",stopColor:"#7C3BFF",stopOpacity:"0.11"}),$t("stop",{offset:"0.45",stopColor:"#7C3BFF",stopOpacity:"0.14"}),$t("stop",{offset:"0.56",stopColor:"#7C3BFF",stopOpacity:"0.19"}),$t("stop",{offset:"0.65",stopColor:"#7C3BFF",stopOpacity:"0.26"}),$t("stop",{offset:"0.73",stopColor:"#7C3BFF",stopOpacity:"0.35"}),$t("stop",{offset:"0.8",stopColor:"#7C3BFF",stopOpacity:"0.46"}),$t("stop",{offset:"0.86",stopColor:"#7C3BFF",stopOpacity:"0.6"}),$t("stop",{offset:"0.92",stopColor:"#7C3BFF",stopOpacity:"0.76"}),$t("stop",{offset:"0.98",stopColor:"#7C3BFF",stopOpacity:"0.93"}),$t("stop",{offset:"1",stopColor:"#7C3BFF"})]})})]})}),$t(Rh,{children:$t(X,{size:112})})]}),zh=jt`
|
|
2117
|
+
0% {
|
|
2118
|
+
background-position: 0% 50%;
|
|
2119
|
+
}
|
|
2120
|
+
100% {
|
|
2121
|
+
background-position: 100% 50%;
|
|
2122
|
+
}
|
|
2123
|
+
`,Lh=Pt($i)`
|
|
2124
|
+
background: ${({$titleColor:e,$gradientColor:t})=>`linear-gradient(45deg, ${e} 0%, ${e} 40%, ${t} 50%, ${e} 60%, ${e} 100%)`};
|
|
2125
|
+
background-size: 250% 100%; /* Expand background to allow movement */
|
|
2126
|
+
background-clip: text;
|
|
2127
|
+
color: transparent;
|
|
2128
|
+
animation: ${zh} 1s reverse linear infinite;
|
|
2129
|
+
`,Ph=e=>{const t=Math.max(0,Date.now()-e),o=Math.floor(t/1e3),r=Math.floor(o/60),i=o%60;return`${String(r).padStart(2,"0")}:${String(i).padStart(2,"0")}`},Mh=({icon:e,title:t,titleColor:o,titleSize:r=yi.S,subTitle:i,subTitleColor:n,subTitleSize:a=yi.XXXS,startedAt:s,withGradient:l,gradientColor:c,withSpinner:d,withSpinnerOld:p,scaleSpinnerOld:u=1,percentage:h,withVisual:m,visualIcon:g=ft})=>{const f=Bt(),[x,y]=kt(()=>s?Ph(s):"");Et(()=>{if(!s)return;y(Ph(s));const e=setInterval(()=>y(Ph(s)),1e3);return()=>clearInterval(e)},[s]);const b=o||f.v2.colors.white[500],$=n||f.v2.colors.silver[200],v=c||f.v2.colors.black[500];return vt(Aa,{$gap:16,$alignItems:"center",children:[m?$t(Nh,{scale:1.7,icon:g}):d?$t(Sh,{percentage:h}):p?$t(Dh,{scale:u}):null,(t||i||s||e)&&vt(Aa,{$gap:8,$alignItems:"center",children:[vt(Ea,{$gap:4,children:[e&&$t(e,{}),l?$t(Lh,{align:"center",size:r,$titleColor:b,$gradientColor:v,children:t}):$t($i,{align:"center",size:r,color:b,children:t})]}),i?$t($i,{align:"center",size:a,color:$,children:i}):null,x?$t($i,{align:"center",size:a,color:b,children:x}):null]})]})},Bh=Pt.div`
|
|
2130
|
+
position: ${({$relativeToParent:e})=>e?"absolute":"fixed"};
|
|
2131
|
+
top: 50%;
|
|
2132
|
+
left: 50%;
|
|
2133
|
+
transform: translate(-50%, -50%);
|
|
2134
|
+
z-index: 1000;
|
|
2135
|
+
width: fit-content;
|
|
2136
|
+
border-radius: 20px;
|
|
2137
|
+
background: ${({theme:e})=>e.v2.colors.black[500]};
|
|
2138
|
+
box-shadow: 0 0 34px 0 rgba(0, 0, 0, 0.7);
|
|
2139
|
+
overflow: hidden;
|
|
2140
|
+
|
|
2141
|
+
animation-name: ${Dn.in.center};
|
|
2142
|
+
`,Uh=Pt.div`
|
|
2143
|
+
position: relative;
|
|
2144
|
+
`,jh=Pt.div`
|
|
2145
|
+
position: absolute;
|
|
2146
|
+
top: 16px;
|
|
2147
|
+
left: 16px;
|
|
2148
|
+
`,Wh=({isOpen:e,hideOverlay:t=!1,relativeToParent:o=!1,onBack:r,onClose:i,children:n})=>{if(Wn(e),!e)return null;const a=vt(wt,{children:[!t&&$t(Na,{$relativeToParent:o,onClick:i}),$t(Bh,{$relativeToParent:o,children:vt(Uh,{children:[r&&$t(jh,{children:$t(Kn,{icon:e=>$t(ut,{rotate:-90,...e}),size:Hn.L,onClick:r})}),n]})})]});return o?a:Yt(a,document.body)},Gh=Pt.aside`
|
|
2149
|
+
display: flex;
|
|
2150
|
+
flex-direction: column;
|
|
2151
|
+
gap: 8px;
|
|
2152
|
+
height: ${({$height:e})=>e};
|
|
2153
|
+
width: fit-content;
|
|
2154
|
+
padding: 16px 12px;
|
|
2155
|
+
background-color: ${({theme:e})=>e.v2.colors.black[500]};
|
|
2156
|
+
overflow-y: auto;
|
|
2157
|
+
`,Vh=({height:e,icons:t})=>$t(Gh,{$height:e,children:t.map(({id:e,selected:t,icon:o,onClick:r})=>$t(Yp,{label:"",leftIcon:o,iconSize:24,onClick:r,variant:t?Jp.Primary:Jp.Text},e))}),Xh=Pt.div`
|
|
2158
|
+
display: flex;
|
|
2159
|
+
align-items: center;
|
|
2160
|
+
justify-content: center;
|
|
2161
|
+
width: fit-content;
|
|
2162
|
+
height: fit-content;
|
|
2163
|
+
padding: 8px;
|
|
2164
|
+
border-radius: 100%;
|
|
2165
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
2166
|
+
`,Hh=({icon:e=qe,title:t="No data",subTitle:o,button:r})=>{const i=Bt().v2.colors.silver[200];return vt(Aa,{$gap:12,$alignItems:"center",children:[$t(Xh,{children:$t(e,{size:32,fill:i})}),vt(Aa,{$gap:4,$alignItems:"center",children:[$t($i,{size:yi.S,align:"center",children:t}),o&&$t($i,{size:yi.XXS,align:"center",color:i,children:o})]}),r&&$t(Yp,{variant:Jp.Secondary,...r})]})},Jh=Pt.div`
|
|
2167
|
+
display: flex;
|
|
2168
|
+
align-items: center;
|
|
2169
|
+
gap: 10px;
|
|
2170
|
+
${({$fullWidth:e})=>e&&Mt`
|
|
2171
|
+
width: calc(100% - 16px);
|
|
2172
|
+
`}
|
|
2173
|
+
padding: 4px 12px 4px 4px;
|
|
2174
|
+
border-radius: 8px;
|
|
2175
|
+
background-color: ${({theme:e,$status:t})=>Br(e,t,[Oo.Info].includes(t)?"1000":"900")};
|
|
2176
|
+
`,Kh=Pt.div`
|
|
2177
|
+
width: ${({$smallIcon:e})=>e?"24px":"32px"};
|
|
2178
|
+
height: ${({$smallIcon:e})=>e?"24px":"32px"};
|
|
2179
|
+
display: flex;
|
|
2180
|
+
align-items: center;
|
|
2181
|
+
justify-content: center;
|
|
2182
|
+
border-radius: 6px;
|
|
2183
|
+
background-color: ${({theme:e,$status:t})=>Br(e,t,[Oo.Info].includes(t)?"900":"800")};
|
|
2184
|
+
`,qh=Pt.div`
|
|
2185
|
+
margin-left: auto;
|
|
2186
|
+
margin-right: 8px;
|
|
2187
|
+
cursor: pointer;
|
|
2188
|
+
&:hover {
|
|
2189
|
+
transform: scale(1.2);
|
|
2190
|
+
}
|
|
2191
|
+
`,Yh=({status:e,message:t,action:o,fullWidth:r,smallIcon:i})=>{const n=Bt(),a=jr(e,n),s=Br(n,e,e===Oo.Default?"300":e===Oo.Info?"400":"500");return vt(Jh,{$status:e,$fullWidth:r,children:[$t("div",{children:$t(Kh,{$status:e,$smallIcon:i,children:$t(a,{size:i?18:24})})}),$t($i,{color:s,size:yi.XXXS,weight:400,children:t}),o&&$t(qh,{onClick:o.onClick,children:$t($i,{color:s,size:yi.XXS,weight:500,underline:!0,children:o.label})})]})};var Qh;!function(e){e.S="small",e.L="large"}(Qh||(Qh={}));const Zh=Pt.div`
|
|
2192
|
+
width: fit-content;
|
|
2193
|
+
display: flex;
|
|
2194
|
+
align-items: center;
|
|
2195
|
+
gap: 8px;
|
|
2196
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
2197
|
+
`,em=Pt.div`
|
|
2198
|
+
width: ${({$size:e})=>e===Qh.S?"16px":"20px"};
|
|
2199
|
+
height: ${({$size:e})=>e===Qh.S?"16px":"20px"};
|
|
2200
|
+
display: flex;
|
|
2201
|
+
align-items: center;
|
|
2202
|
+
justify-content: center;
|
|
2203
|
+
border-radius: 100%;
|
|
2204
|
+
border: 1px solid ${({$borderColor:e})=>e};
|
|
2205
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
2206
|
+
`,tm=({label:e,value:t,onChange:o,disabled:r,size:i=Qh.L})=>{const n=Bt(),[a,s]=kt(!1),l=t,c=i===Qh.S?6:8,d=r?n.v2.colors.grey[400]:n.v2.colors.white[500],p=l?"transparent":r?n.v2.colors.grey[700]:a?n.v2.colors.silver[400]:n.v2.colors.silver[600],u=r?n.v2.colors.grey[600]:l?n.v2.colors.purple[500]:n.v2.colors.silver[900];return vt(Zh,{"data-id":"radio"+(e?`-${e}`:""),onClick:e=>{e.stopPropagation(),r||o(!t)},$disabled:r,onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),children:[$t(em,{$size:i,$borderColor:p,$backgroundColor:u,children:t?$t(xt,{size:c,fill:d}):null}),e&&$t($i,{size:i===Qh.S?yi.XXS:yi.XS,children:e})]})},om=Pt.div`
|
|
2207
|
+
display: flex;
|
|
2208
|
+
flex-direction: ${({$flexDirection:e})=>e};
|
|
2209
|
+
gap: ${({$gap:e})=>e}px;
|
|
2210
|
+
`,rm=({label:e,direction:t,disabled:o,size:r,options:i,values:n,setValues:a})=>vt(om,{$flexDirection:t===wo.Horizontal?"row":"column",$gap:t===wo.Horizontal?16:8,children:[e&&$t($i,{children:e}),i.map(t=>$t(tm,{...t,value:n[t.id],onChange:e=>{return o=t.id,r=e,void a(e=>{const t={...e};return Object.keys(t).forEach(e=>t[e]=!1),t[o]=r,t});var o,r},disabled:o,size:r},`${e}-radio-${t.id}`))]}),im=({currentStep:e,data:t,gap:o=12})=>$t(Aa,{$gap:o,children:t.map(t=>{const o=t.step<e,r=t.step===e;return vt(Ea,{$gap:8,children:[o||t.forceDoneBadge?$t(Hp,{status:Oo.Success,label:"",leftIcon:Je}):$t(Hp,{status:Oo.Default,label:t.step.toString()}),$t($i,{size:r?yi.M:yi.XS,weight:r?500:400,opacity:r?1:.7,children:t.label})]},`stepper-item-${t.step}`)})});var nm;!function(e){e.Data="data",e.Pretty="pretty"}(nm||(nm={}));const am=Pt.div`
|
|
2211
|
+
height: ${({$maxHeight:e})=>e};
|
|
2212
|
+
width: 100%;
|
|
2213
|
+
display: flex;
|
|
2214
|
+
flex-direction: column;
|
|
2215
|
+
overflow: hidden;
|
|
2216
|
+
`,sm=Pt.div`
|
|
2217
|
+
width: 100%;
|
|
2218
|
+
flex: 1;
|
|
2219
|
+
display: flex;
|
|
2220
|
+
flex-direction: column;
|
|
2221
|
+
overflow: hidden;
|
|
2222
|
+
`,lm=Pt.div`
|
|
2223
|
+
flex-shrink: 0;
|
|
2224
|
+
z-index: 1;
|
|
2225
|
+
`,cm=Pt.div`
|
|
2226
|
+
display: flex;
|
|
2227
|
+
width: 100%;
|
|
2228
|
+
`,dm=Pt.div`
|
|
2229
|
+
position: relative;
|
|
2230
|
+
min-width: ${({$minWidth:e})=>e?`${e}px`:"auto"};
|
|
2231
|
+
flex: 1;
|
|
2232
|
+
padding: 18px 24px;
|
|
2233
|
+
border: none;
|
|
2234
|
+
border-radius: ${({$isFirst:e,$isLast:t})=>e?"4px 0 0 0":t?"0 4px 0 0":"0"};
|
|
2235
|
+
box-sizing: border-box;
|
|
2236
|
+
|
|
2237
|
+
${({$variant:e,$backgroundColor:t})=>{if(t)return Mt`
|
|
2238
|
+
background-color: ${t};
|
|
2239
|
+
`;switch(e){case nm.Data:return Mt`
|
|
2240
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
2241
|
+
`;case nm.Pretty:return Mt`
|
|
2242
|
+
background-color: transparent;
|
|
2243
|
+
`;default:return""}}}
|
|
2244
|
+
`,pm=Pt.div`
|
|
2245
|
+
position: absolute;
|
|
2246
|
+
top: 50%;
|
|
2247
|
+
right: 0;
|
|
2248
|
+
transform: translateY(-50%);
|
|
2249
|
+
width: 1px;
|
|
2250
|
+
height: 18px;
|
|
2251
|
+
background: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
2252
|
+
`,um=Pt.div`
|
|
2253
|
+
position: relative;
|
|
2254
|
+
|
|
2255
|
+
min-width: ${({$minWidth:e})=>e?`${e}px`:"auto"};
|
|
2256
|
+
flex: 1;
|
|
2257
|
+
display: flex;
|
|
2258
|
+
align-items: center;
|
|
2259
|
+
|
|
2260
|
+
padding: 18px 24px;
|
|
2261
|
+
cursor: ${({$withClick:e})=>e?"pointer":"default"};
|
|
2262
|
+
box-sizing: border-box;
|
|
2263
|
+
|
|
2264
|
+
${({$variant:e,$selected:t,$hovered:o,$isLastRow:r,$isFirstCell:i,$isLastCell:n})=>{switch(e){case nm.Data:return Mt`
|
|
2265
|
+
border-bottom: ${({theme:e})=>r?"none":`1px solid ${e.v2.colors.silver[500]}`};
|
|
2266
|
+
border-radius: ${r?i?"0 0 0 4px":n?"0 0 4px 0":"0":"0"};
|
|
2267
|
+
background-color: ${({theme:e})=>t?e.v2.colors.blue[1e3]:o?e.v2.colors.silver[700]:e.v2.colors.silver[800]};
|
|
2268
|
+
`;case nm.Pretty:return Mt`
|
|
2269
|
+
border: none;
|
|
2270
|
+
border-radius: ${i?"12px 0 0 12px":n?"0 12px 12px 0":"0"};
|
|
2271
|
+
background-color: ${({theme:e})=>t?e.v2.colors.blue[1e3]:o?e.v2.colors.silver[700]:e.v2.colors.silver[900]};
|
|
2272
|
+
`;default:return""}}}
|
|
2273
|
+
`,hm=Pt.div`
|
|
2274
|
+
width: 100%;
|
|
2275
|
+
display: flex;
|
|
2276
|
+
align-items: center;
|
|
2277
|
+
justify-content: ${({$textAlign:e})=>"right"===e?"flex-end":"left"===e?"flex-start":"center"===e?"center":"unset"};
|
|
2278
|
+
gap: 4px;
|
|
2279
|
+
text-align: ${({$textAlign:e})=>e||"left"};
|
|
2280
|
+
`,mm=({variant:e,columns:t,rows:o,getRowActions:r,rowActionsPushRightPosition:i,withCheckboxes:n})=>{const[a,s]=kt(null),l=Ct(()=>o.map((l,c)=>{const{cells:d,onClick:p,isSelected:u=!1,onSelect:h,onDeselect:m,hideCheckbox:g}=l,f=a===c,x=r(l),y=(e,t)=>({$isLastRow:c===o.length-1,$isFirstCell:e,$isLastCell:t,$selected:u,$withClick:!!p,onClick:()=>p?.(),$hovered:!!p&&f,onMouseEnter:()=>s(c),onMouseLeave:()=>s(null)});return vt(cm,{children:[n&&$t(um,{$variant:e,style:{flex:"0 0 68px"},...y(!0,!1),children:!g&&$t($u,{value:u,onChange:()=>u?m?.():h?.()})},"checkbox-column"),t.map(({key:o,textAlign:r,minWidth:a},s)=>{const l=d.find(e=>e.key===o),p=0===s&&!n,u=s===t.length-1,h="right"===r?"flex-end":"center"===r?"center":"flex-start";return vt(um,{$variant:e,$minWidth:a,...y(p,u),children:[$t(Ea,{$width:"100%",$justifyContent:h,children:l?.component?$t(l.component,{}):$t($i,{size:yi.XS,children:l?.rawValue||"-"})}),x.length?$t(ph,{isOpen:f&&u,actions:x,positionRight:i}):null]},`row-${c}-cell-${s}`)})]},`row-${c}`)}),[o,a,r,i,n,t]);return $t(np,{gap:e===nm.Pretty?8:0,elements:l})},gm=({columnKey:e,sortDirection:t,sortByKey:o,onSort:r})=>{const i=Bt(),n=o===e?i.v2.colors.white[500]:i.v2.colors.grey[400],a=t===So.Ascending?0:180;return $t(Kn,{icon:e=>$t(ut,{fill:n,rotate:a,...e}),onClick:()=>r(e)})},fm=({columnKey:e,filters:t,onFilter:o,rowsUnfiltered:r})=>{const i=Bt(),n=t[e]?.length?i.v2.colors.white[500]:i.v2.colors.grey[400],a=Ct(()=>Array.from(new Set(r.map(t=>t.cells.find(t=>t.key===e)?.rawValue?.toString()).filter(e=>!!e))).sort((e,t)=>e.localeCompare(t)).map(e=>({id:e,label:e,withCheckbox:!0})),[r,e]);return $t(Tu,{items:a,withMultiSelect:!0,selectedIds:t[e]?.map(e=>e.toString())??[],setSelectedIds:t=>o(e,t),defaultOpen:!1,iconButtonProps:{icon:e=>$t(yt,{fill:n,...e})}})},xm=({variant:e,backgroundColor:t,columns:o,rowsUnfiltered:r,sortDirection:i,sortByKey:n,onSort:a,filters:s,onFilter:l,withCheckboxes:c,partiallySelected:d,allSelected:p,onSelectAll:u})=>vt(cm,{children:[c&&$t(dm,{$variant:e,$backgroundColor:t,$isFirst:!0,$isLast:!1,style:{flex:"0 0 68px"},children:$t($u,{partiallyChecked:d&&!p,value:p||!1,onChange:u})},"checkbox-column"),o.map(({key:d,label:p,noSort:u,noFilter:h,minWidth:m,textAlign:g},f)=>{const x=0===f&&!c,y=f===o.length-1;return vt(dm,{$variant:e,$backgroundColor:t,$minWidth:m,$isFirst:x,$isLast:y,children:[vt(hm,{$textAlign:g,children:[$t($i,{size:yi.XS,align:g,children:p}),!u&&$t(gm,{columnKey:d,sortDirection:i,sortByKey:n,onSort:a}),!h&&$t(fm,{columnKey:d,filters:s,onFilter:l,rowsUnfiltered:r})]}),!y&&e===nm.Data&&$t(pm,{})]},`column-${d}`)})]}),ym=({variant:e,maxHeight:t="256px",headerBackgroundColor:o,isLoading:r,columns:i,rows:n,getRowActions:a,rowActionsPushRightPosition:s,withCheckboxes:l})=>{const[c,d]=kt(So.Ascending),[p,u]=kt(""),[h,m]=kt({}),g=Dt(e=>{u(e),d(e=>e===So.Ascending?So.Descending:So.Ascending)},[]),f=Dt((e,t)=>{m(o=>({...o,[e]:t}))},[]),x=Ct(()=>{const e=(e,t)=>{const o=e.cells.find(e=>e.key===t);return o&&(o.rawValue?.toString()||o.component?.({})?.props?.children?.toString())||""};return(p?[...n].sort((t,o)=>{const r=e(t,p),i=e(o,p);return(c===So.Ascending?1:-1)*((e,t)=>"string"==typeof e&&"string"==typeof t?e.localeCompare(t):"number"==typeof e&&"number"==typeof t?e-t:"boolean"==typeof e&&"boolean"==typeof t?e===t?0:e?1:-1:String(e).localeCompare(String(t)))(r,i)}):n).filter(t=>{for(const[o,r]of Object.entries(h))if(r.length&&!r.includes(e(t,o)))return!1;return!0})},[n,p,c,h]),{partiallySelected:y,allSelected:b}=Ct(()=>{const e=x.filter(e=>!e.hideCheckbox);return{partiallySelected:e.length>0&&e.some(e=>e.isSelected),allSelected:e.length>0&&e.every(e=>e.isSelected)}},[x]);return $t(am,{$maxHeight:t,children:vt(sm,{$variant:e,children:[$t(lm,{children:$t(xm,{variant:e,backgroundColor:o,columns:i,rowsUnfiltered:n,sortDirection:c,sortByKey:p,onSort:g,filters:h,onFilter:f,withCheckboxes:l,partiallySelected:y,allSelected:b,onSelectAll:e=>{e?x.forEach(e=>!e.hideCheckbox&&e.onSelect?.()):x.forEach(e=>!e.hideCheckbox&&e.onDeselect?.())}})}),x.length?$t(mm,{variant:e,columns:i,rows:x,getRowActions:a||(()=>[]),rowActionsPushRightPosition:s,withCheckboxes:l}):$t(Da,{style:{marginTop:"0.5rem"},children:r?$t(Mh,{withSpinner:!0}):$t(Hh,{})})]})})},bm=Pt.div`
|
|
2281
|
+
display: flex;
|
|
2282
|
+
align-items: center;
|
|
2283
|
+
justify-content: center;
|
|
2284
|
+
gap: 8px;
|
|
2285
|
+
width: fit-content;
|
|
2286
|
+
padding: 8px;
|
|
2287
|
+
border-radius: 4px;
|
|
2288
|
+
${({$disabled:e,$withClick:t})=>e?Mt`
|
|
2289
|
+
cursor: not-allowed;
|
|
2290
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[800]};
|
|
2291
|
+
`:t?Mt`
|
|
2292
|
+
cursor: pointer;
|
|
2293
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[300]};
|
|
2294
|
+
&:hover {
|
|
2295
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[400]};
|
|
2296
|
+
}
|
|
2297
|
+
&:active {
|
|
2298
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
2299
|
+
}
|
|
2300
|
+
`:Mt`
|
|
2301
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[300]};
|
|
2302
|
+
`}
|
|
2303
|
+
`,$m=({label:e,leftIcon:t,rightIcon:o,onClick:r,disabled:i})=>{const n=Bt(),a=i?n.v2.colors.grey[400]:n.v2.colors.white[500];return vt(bm,{$disabled:i,$withClick:!!r,onClick:()=>!i&&r?.(),children:[t&&$t(t,{fill:a,size:16}),$t($i,{color:a,size:yi.XS,nowrap:!0,children:e}),o&&$t(o,{fill:a,size:16})]})},vm=Pt.div`
|
|
2304
|
+
padding: 8px 12px;
|
|
2305
|
+
|
|
2306
|
+
display: flex;
|
|
2307
|
+
align-self: stretch;
|
|
2308
|
+
align-items: flex-start;
|
|
2309
|
+
gap: 8px;
|
|
2310
|
+
border-radius: 6px;
|
|
2311
|
+
|
|
2312
|
+
border: 1px solid ${({theme:e,$disabled:t,$error:o})=>t?e.v2.colors.grey[600]:o?e.v2.colors.red[500]:e.v2.colors.silver[500]};
|
|
2313
|
+
background: ${({theme:e,$disabled:t})=>t?e.v2.colors.grey[800]:e.v2.colors.black[500]};
|
|
2314
|
+
${({$disabled:e,$error:t})=>!e&&!t&&Mt`
|
|
2315
|
+
&:hover,
|
|
2316
|
+
&:active,
|
|
2317
|
+
&:focus-within {
|
|
2318
|
+
border: 1px solid ${({theme:e})=>e.v2.colors.silver[300]};
|
|
2319
|
+
}
|
|
2320
|
+
`}
|
|
2321
|
+
`,wm=Pt.textarea`
|
|
2322
|
+
max-width: ${({$maxWidth:e})=>e||"unset"};
|
|
2323
|
+
min-height: ${({$minHeight:e})=>e||"50px"};
|
|
2324
|
+
flex: 1;
|
|
2325
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
2326
|
+
font-size: 14px;
|
|
2327
|
+
font-weight: 400;
|
|
2328
|
+
resize: none;
|
|
2329
|
+
|
|
2330
|
+
background: transparent;
|
|
2331
|
+
border: none;
|
|
2332
|
+
outline: none;
|
|
2333
|
+
cursor: text;
|
|
2334
|
+
color: ${({theme:e})=>e.v2.colors.white[500]};
|
|
2335
|
+
&::placeholder {
|
|
2336
|
+
color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
2337
|
+
}
|
|
2338
|
+
|
|
2339
|
+
&:disabled {
|
|
2340
|
+
cursor: not-allowed;
|
|
2341
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
2342
|
+
&::placeholder {
|
|
2343
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
2344
|
+
}
|
|
2345
|
+
}
|
|
2346
|
+
`,Sm=({label:e,required:t,tooltip:o,badge:r,errorMessage:i,warnMessage:n,helpMessage:a,name:s,value:l,onChange:c,disabled:d,maxWidth:p,minHeight:u,...h})=>{const m=At(null),g=()=>{m.current&&(m.current.style.height="auto",m.current.style.height=`${m.current.scrollHeight}px`)};return vt(Aa,{$gap:6,children:[$t(gu,{label:e,tooltip:o,required:t,badge:r}),$t(vm,{$disabled:d,$error:!!i,children:$t(wm,{ref:m,"data-id":s,name:s,value:l,onChange:e=>{e.stopPropagation(),g(),c?.(e)},onKeyDown:e=>{e.stopPropagation()},onFocus:g,onBlur:g,disabled:d,$maxWidth:p,$minHeight:u,...h})}),$t(fu,{errorMessage:i,warnMessage:n,helpMessage:a})]})};var Cm,km,Em;!function(e){e.Default="default",e.SuccessError="successError"}(Cm||(Cm={})),function(e){e.S="small",e.L="large"}(km||(km={})),function(e){e.Left="left",e.Right="right"}(Em||(Em={}));const Am=Pt.div`
|
|
2347
|
+
display: flex;
|
|
2348
|
+
align-items: center;
|
|
2349
|
+
gap: ${({$gap:e})=>e}px;
|
|
2350
|
+
`,Dm=Pt.div`
|
|
2351
|
+
position: relative;
|
|
2352
|
+
display: flex;
|
|
2353
|
+
align-items: center;
|
|
2354
|
+
justify-content: space-between;
|
|
2355
|
+
|
|
2356
|
+
width: ${({$size:e})=>2*e+2}px;
|
|
2357
|
+
height: ${({$size:e})=>e}px;
|
|
2358
|
+
padding: ${4}px;
|
|
2359
|
+
border-radius: ${({$size:e})=>2*e}px;
|
|
2360
|
+
background-color: ${({$disabled:e,$onBgColor:t,$offBgColor:o,$variant:r,$value:i,theme:n})=>{if(e)return n.v2.colors.grey[800];if(t&&i)return t;if(o&&!i)return o;switch(r){case Cm.SuccessError:return i?n.v2.colors.green[500]:n.v2.colors.red[500];case Cm.Default:default:return i?n.v2.colors.purple[500]:n.v2.colors.grey[400]}}};
|
|
2361
|
+
|
|
2362
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
2363
|
+
`,Tm=Pt.div`
|
|
2364
|
+
position: absolute;
|
|
2365
|
+
top: 50%;
|
|
2366
|
+
left: ${({$value:e,$size:t})=>e?`calc(100% - ${t}px - 4px)`:"4px"};
|
|
2367
|
+
transform: translateY(-50%);
|
|
2368
|
+
width: ${({$size:e})=>e}px;
|
|
2369
|
+
height: ${({$size:e})=>e}px;
|
|
2370
|
+
border-radius: 100%;
|
|
2371
|
+
background-color: ${({$color:e})=>e};
|
|
2372
|
+
box-shadow: ${({$disabled:e})=>e?"0 0 40px 0 rgba(0, 0, 0, 0.07)":"0 0 10px 0 rgba(0, 0, 0, 0.50)"};
|
|
2373
|
+
`,Nm=({variant:e=Cm.Default,size:t=km.L,name:o,label:r,labelAlign:i=Em.Right,labelColor:n,tooltip:a,badge:s,value:l,onChange:c,disabled:d,withIcon:p,onIcon:u=Je,offIcon:h=qe,onBgColor:m,offBgColor:g,errorMessage:f,warnMessage:x,helpMessage:y})=>{const b=Bt(),$=d?b.v2.colors.grey[400]:b.v2.colors.white[500],v=t===km.S?10:16,w=n||b.v2.colors.silver[200],S=t===km.S?yi.XXXS:yi.XS,C=t===km.S?8:12;return vt(Aa,{$gap:4,children:[vt(Ea,{$justifyContent:"space-between",children:[vt(Am,{"data-id":o||"toggle"+(r?`-${r}`:""),$gap:C,children:[r&&i===Em.Left&&$t($i,{color:w,size:S,nowrap:!0,children:r}),vt(Dm,{$onBgColor:m,$offBgColor:g,$variant:e,$size:v,$value:l,$disabled:d,onClick:e=>{e.stopPropagation(),d||c(!l)},children:[$t(Tm,{$color:$,$size:v,$value:l,$disabled:d}),p&&vt(wt,{children:[$t(u,{size:v,fill:$}),$t(h,{size:v,fill:$})]})]}),r&&i===Em.Right&&$t($i,{color:w,size:S,nowrap:!0,children:r})]}),$t(gu,{tooltip:a,badge:s})]}),$t(fu,{errorMessage:f,warnMessage:x,helpMessage:y})]})},Im=Pt.div`
|
|
2374
|
+
display: flex;
|
|
2375
|
+
flex-direction: ${({$direction:e})=>e===wo.Horizontal?"row":"column"};
|
|
2376
|
+
gap: ${({$direction:e})=>e===wo.Horizontal?16:8}px;
|
|
2377
|
+
`,_m=({direction:e=wo.Vertical,title:t,size:o,disabled:r,options:i,values:n,setValues:a})=>{const s=o===km.S?yi.XS:yi.S;return vt(Im,{$direction:e,children:[t&&$t($i,{size:s,children:t}),i.map(e=>$t(Nm,{...e,labelAlign:Em.Right,value:n[e.id],onChange:t=>{return o=e.id,r=t,void a(e=>{const t={...e};return o?t[o]=r:i.forEach(e=>t[e.id]=r),t});var o,r},disabled:r,size:o},`${t}-toggle-${e.id}`))]})},Om=Pt.div`
|
|
2378
|
+
min-width: 530px;
|
|
2379
|
+
`,Rm=Pt.div`
|
|
2380
|
+
display: flex;
|
|
2381
|
+
flex-direction: column;
|
|
2382
|
+
align-items: center;
|
|
2383
|
+
gap: 16px;
|
|
2384
|
+
padding: 24px;
|
|
2385
|
+
`,Fm=Pt.div`
|
|
2386
|
+
display: flex;
|
|
2387
|
+
justify-content: center;
|
|
2388
|
+
gap: 16px;
|
|
2389
|
+
padding: 16px 24px;
|
|
2390
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[1e3]};
|
|
2391
|
+
`,zm=({visual:e,title:t,description:o,isOpen:r,onClose:i,onDeny:n,denyLabel:a="Deny",onApprove:s,approveLabel:l="Approve",...c})=>{const d=Bt();return $t(Wh,{isOpen:r,onClose:i,...c,children:vt(Om,{children:[vt(Rm,{children:[e&&$t(e,{}),$t($i,{size:yi.M,weight:500,color:d.v2.colors.white[500],children:t}),$t(Aa,{$alignItems:"center",$gap:4,children:o.split("\n").map(e=>$t($i,{size:yi.XS,weight:400,color:d.v2.colors.silver[200],children:e},e))})]}),(n||s)&&vt(Fm,{children:[$t(Yp,{variant:Jp.Secondary,label:a,onClick:()=>{n?.(),i()}}),s&&$t(Yp,{variant:Jp.Primary,label:l,onClick:()=>{s(),i()}})]})]})})};export{Ko as $,fo as A,Yp as B,$u as C,th as D,Sm as E,Aa as F,ao as G,ah as H,nh as I,Jr as J,xo as K,Mh as L,Yi as M,Hh as N,nn as O,li as P,er as Q,Ou as R,np as S,Co as T,si as U,Nh as V,zm as W,ur as X,Xo as Y,Za as Z,Ho as _,gu as a,jp as a$,rr as a0,or as a1,Jo as a2,Vo as a3,Hp as a4,Qi as a5,Sr as a6,dr as a7,cr as a8,ga as a9,Cu as aA,Su as aB,nu as aC,br as aD,da as aE,Nu as aF,mr as aG,Ca as aH,ym as aI,nm as aJ,bh as aK,im as aL,Ur as aM,Ms as aN,Hu as aO,_n as aP,Iu as aQ,Mu as aR,ju as aS,qo as aT,ka as aU,Oc as aV,Vl as aW,Ss as aX,Di as aY,Ql as aZ,Ud as a_,ya as aa,xa as ab,To as ac,Vi as ad,Xi as ae,hr as af,Kn as ag,Hn as ah,Ji as ai,Ki as aj,Ar as ak,au as al,qi as am,zo as an,km as ao,xi as ap,fa as aq,gn as ar,un as as,qn as at,oa as au,Sa as av,Zr as aw,zu as ax,sn as ay,Tu as az,Ea as b,qa as b$,Jd as b0,Ld as b1,os as b2,Zs as b3,gp as b4,pp as b5,Zc as b6,ep as b7,Mp as b8,ki as b9,Nr as bA,hl as bB,_a as bC,Oa as bD,Td as bE,Dr as bF,Ra as bG,_c as bH,Dl as bI,Vp as bJ,Fn as bK,mi as bL,Mn as bM,fn as bN,bl as bO,Go as bP,xr as bQ,_r as bR,Er as bS,Cp as bT,Xn as bU,gr as bV,ho as bW,ar as bX,uo as bY,Gn as bZ,ia as b_,an as ba,$d as bb,Yc as bc,$s as bd,jn as be,Tr as bf,Hi as bg,Js as bh,Vc as bi,$r as bj,Do as bk,dn as bl,fi as bm,Wa as bn,Ia as bo,ps as bp,ji as bq,rp as br,vr as bs,Qs as bt,Fo as bu,ni as bv,jr as bw,cn as bx,po as by,ll as bz,fu as c,Ro as c$,Ta as c0,yp as c1,ra as c2,ii as c3,rc as c4,pr as c5,na as c6,Yn as c7,bn as c8,lr as c9,tl as cA,kl as cB,Al as cC,ph as cD,ei as cE,di as cF,sa as cG,jo as cH,Ao as cI,bc as cJ,Cr as cK,wa as cL,pl as cM,wr as cN,gc as cO,on as cP,yr as cQ,Es as cR,Pr as cS,nl as cT,Os as cU,mo as cV,Bo as cW,$o as cX,Uo as cY,Mo as cZ,Eo as c_,Us as ca,rl as cb,No as cc,ai as cd,Zn as ce,Kr as cf,ro as cg,ir as ch,_p as ci,Pc as cj,Rr as ck,Fp as cl,pn as cm,ta as cn,bs as co,Dn as cp,Hr as cq,Vn as cr,Po as cs,Xr as ct,Gi as cu,Ul as cv,ol as cw,_d as cx,Wr as cy,qr as cz,so as d,tu as d$,vo as d0,wo as d1,bo as d2,Wo as d3,ko as d4,Zo as d5,Qo as d6,Yo as d7,Lo as d8,nr as d9,en as dA,tn as dB,kn as dC,On as dD,An as dE,Cn as dF,ca as dG,ha as dH,ma as dI,Wn as dJ,Rl as dK,Nl as dL,qc as dM,fd as dN,dd as dO,wd as dP,Ad as dQ,al as dR,Yd as dS,Na as dT,rd as dU,wi as dV,Si as dW,Ci as dX,_h as dY,Ih as dZ,Fh as d_,tr as da,So as db,yo as dc,io as dd,fr as de,lo as df,kr as dg,Ir as dh,Or as di,Fr as dj,zr as dk,Lr as dl,Mr as dm,Br as dn,Gr as dp,Qr as dq,ti as dr,ri as ds,ci as dt,pi as du,ui as dv,hi as dw,co as dx,gi as dy,Zi as dz,Da as e,ou as e0,wu as e1,xu as e2,ch as e3,Wh as e4,Vh as e5,tm as e6,rm as e7,Qh as e8,Ru as e9,$m as ea,_m as eb,Cm as ec,yi as f,uu as g,Yh as h,Oo as i,Jp as j,$i as k,En as l,_o as m,Yr as n,xh as o,Nm as p,Em as q,uh as r,Va as s,Kp as t,pa as u,Io as v,go as w,Bn as x,sr as y,cu as z};
|