@odigos/ui-kit 0.0.142 → 0.0.143
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 +7 -0
- package/lib/chunks/ui-components-29317e94.js +2191 -0
- package/lib/components/_v2/checkbox-list/index.d.ts +5 -8
- package/lib/components/_v2/index.d.ts +1 -0
- package/lib/components/_v2/search/index.d.ts +2 -1
- package/lib/components/_v2/toggle/index.d.ts +9 -0
- package/lib/components/_v2/toggle-list/index.d.ts +20 -0
- package/lib/components/v2.js +1 -1
- package/lib/components.js +1 -1
- package/lib/constants.js +1 -1
- package/lib/containers/v2.js +11 -11
- package/lib/containers.js +1 -1
- package/lib/functions.js +1 -1
- package/lib/hooks.js +1 -1
- 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 +8 -4
- package/lib/types.js +1 -1
- package/package.json +1 -1
- package/lib/chunks/ui-components-6220f061.js +0 -2182
|
@@ -0,0 +1,2191 @@
|
|
|
1
|
+
import{SamplerIcon as e,PiiMaskingIcon as t,ImageErrorIcon as o,K8sLogo as n,AddClusterInfoIcon as i,DeleteAttributeIcon as a,RenameAttributeIcon as r,CodeAttributesIcon as s,CustomInstrumentationIcon as l,HeadersCollectionIcon as c,PayloadCollectionIcon as d,JavaLogo as p,GoLogo as u,NodejsLogo as h,PythonLogo as m,DotnetLogo as g,CSharpLogo as x,CPlusPlusLogo as $,PhpLogo as f,RubyLogo as b,RustLogo as y,SwiftLogo as w,ElixirLogo as k,MysqlLogo as v,NginxLogo as C,PostgresLogo as E,RedisLogo as S,KafkaLogo as A,AlaudaLogo as D,AlibabaCloudLogo as T,AppDynamicsLogo as N,AxiomLogo as I,AzureBlobLogo as z,AzureMonitorLogo as O,BetterStackLogo as _,BonreeLogo as F,CauselyLogo as R,ChecklyLogo as L,ChronosphereLogo as B,ClickhouseLogo as P,AwsCloudwatchLogo as M,CoralogixLogo as j,Dash0Logo as U,DatadogLogo as W,OpenTelemetryLogo as V,DynatraceLogo as H,ElasticApmLogo as q,ElasticSearchLogo as G,GoogleCloudPlatformLogo as K,GrafanaLogo as J,GreptimeLogo as Y,GroundcoverLogo as X,HoneycombLogo as Q,HyperDxLogo as Z,InstanaLogo as ee,JaegerLogo as te,KloudmateLogo as oe,Last9Logo as ne,LightstepLogo as ie,LogzioLogo as ae,LokiLogo as re,LumigoLogo as se,MiddlewareLogo as le,NewRelicLogo as ce,ObserveLogo as de,OdigosLogo as pe,OneUptimeLogo as ue,OpenObserveLogo as he,OpsVerseLogo as me,OracleLogo as ge,PrometheusLogo as xe,QrynLogo as $e,GigapipeLogo as fe,QuickwitLogo as be,AwsS3Logo as ye,SeqLogo as we,SignozLogo as ke,SplunkLogo as ve,SumoLogicLogo as Ce,TelemetryHubLogo as Ee,TempoLogo as Se,TingyunLogo as Ae,TraceloopLogo as De,UptraceLogo as Te,VictoriaMetricsLogo as Ne,AwsXrayLogo as Ie,NamespacesIcon as ze,SourceIcon as Oe,DestinationIcon as _e,ActionIcon as Fe,InstrumentationRuleIcon as Re,LogsIcon as Le,MetricsIcon as Be,TracesIcon as Pe,VmLogo as Me,ISquareIcon as je,ExclamationCircleIcon as Ue,ExclamationTriangleIcon as We,VSquareIcon as Ve,XSquareIcon as He,QuestionCircleIcon as qe,ArrowIcon as Ge,VIcon as Ke,CopyIcon as Je,XIcon as Ye,MinusIcon as Xe,ListIcon as Qe,CodeIcon as Ze,ExtendArrowIcon as et,PlusIcon as tt,EditIcon as ot,NoDataIcon as nt,EyeClosedIcon as it,EyeOpenIcon as at,SearchIcon as rt,TrashIcon as st,EditedIcon as lt,SortArrowsIcon as ct,NotebookIcon as dt,ChevronUpIcon as pt,ChevronDownIcon as ut,DotsVerticalIcon as ht,DotIcon as mt}from"../icons.js";import{create as gt}from"zustand";import xt,{Fragment as $t,useMemo as ft,forwardRef as bt,useState as yt,useEffect as wt,useRef as kt,useCallback as vt,memo as Ct}from"react";import Et from"javascript-time-ago";import{p as St,c as At,s as Dt,u as Tt,e as Nt}from"./vendor-55cc654c.js";import It,{ThemeProvider as zt,keyframes as Ot,useTheme as _t,css as Ft}from"styled-components";import{Handle as Rt,Position as Lt,ReactFlow as Bt,Controls as Pt}from"@xyflow/react";import Mt,{createPortal as jt}from"react-dom";import{Highlight as Ut,themes as Wt}from"prism-react-renderer";import{ErrorBoundary as Vt}from"react-error-boundary";import Ht from"lottie-react";const qt=gt(e=>({activeNodeType:null,activeNodeId:null,setActiveNodeType:t=>e({activeNodeType:t}),setActiveNodeId:t=>e({activeNodeId:t})}));var Gt,Kt,Jt,Yt,Xt,Qt,Zt,eo,to,oo,no,io,ao,ro,so,lo,co,po,uo,ho,mo,go,xo,$o,fo,bo,yo,wo,ko,vo,Co,Eo,So,Ao,Do,To,No,Io,zo,Oo;!function(e){e.Attributes="attributes",e.Samplers="samplers"}(Gt||(Gt={})),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"}(Kt||(Kt={})),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"}(Jt||(Jt={})),function(e){e.Pod="pod",e.Namespace="namespace"}(Yt||(Yt={})),function(e){e.EXISTS="exists",e.EQUALS="equals",e.NOT_EQUALS="not_equals",e.CONTAINS="contains",e.NOT_CONTAINS="not_contains",e.REGEX="regex"}(Xt||(Xt={})),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"}(Qt||(Qt={})),function(e){e.EXISTS="exists",e.EQUALS="equals"}(Zt||(Zt={})),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"}(eo||(eo={})),function(e){e.Horizontal="horizontal",e.Vertical="vertical"}(to||(to={})),function(e){e.Ascending="ascending",e.Descending="descending"}(oo||(oo={})),function(e){e.Community="community",e.Cloud="cloud",e.Onprem="onprem"}(no||(no={})),function(e){e.K8s="k8s",e.Vm="vm"}(io||(io={})),function(e){e.Cli="odigos-cli",e.Helm="helm",e.Operator="odigos-operator"}(ao||(ao={})),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"}(ro||(ro={})),function(e){e.Create="Create",e.Read="Read",e.Update="Update",e.Delete="Delete"}(so||(so={})),function(e){e.Namespace="Namespace",e.Source="Source",e.Destination="Destination",e.Action="Action",e.InstrumentationRule="InstrumentationRule"}(lo||(lo={})),function(e){e.DataStream="DataStream"}(co||(co={})),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"}(po||(po={})),function(e){e.Text="text",e.Password="password",e.Number="number"}(uo||(uo={})),function(e){e.Warning="warning",e.Error="error",e.Success="success",e.Info="info",e.Default="default"}(ho||(ho={})),function(e){e.INSTRUMENTED="Instrumented",e.INSTRUMENTING="Instrumenting",e.UNINSTRUMENTED="Uninstrumented",e.NOT_INSTRUMENTED="Not Instrumented"}(mo||(mo={})),function(e){e.Loading="loading",e.Disabled="disabled"}(go||(go={})),function(e){e.Disabled="disabled",e.Unknown="unknown"}(xo||(xo={})),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"}($o||($o={})),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"}(fo||(fo={})),function(e){e.Labeled="labeled"}(bo||(bo={})),function(e){e.AddRule="addRule",e.AddSource="addSource",e.AddAction="addAction",e.AddDestination="addDestination"}(yo||(yo={})),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.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"}(wo||(wo={})),function(e){e.CodeAttributes="CodeAttributes",e.HeadersCollection="HeadersCollection",e.PayloadCollection="PayloadCollection",e.CustomInstrumentation="CustomInstrumentation",e.UnknownType="UnknownType"}(ko||(ko={})),function(e){e.Column="column",e.FilePath="filePath",e.Function="function",e.LineNumber="lineNumber",e.Namespace="namespace",e.StackTrace="stacktrace"}(vo||(vo={})),function(e){e.HeaderKeys="headerKeys"}(Co||(Co={})),function(e){e.Java="java",e.Golang="golang"}(Eo||(Eo={}));class _o{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 Fo{packageName;functionName;receiverName;receiverMethodName;constructor(e,t,o,n){this.packageName=e,this.functionName=t||"",this.receiverName=o||"",this.receiverMethodName=n||""}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"}(So||(So={})),function(e){e.Healthy="Healthy",e.Updating="Updating",e.Degraded="Degraded",e.Failed="Failed",e.Down="Down",e.Unknown="Unknown"}(Ao||(Ao={})),function(e){e.Pending="Pending",e.Running="Running",e.Succeeded="Succeeded",e.Failed="Failed",e.Unknown="Unknown"}(Do||(Do={})),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"}(To||(To={})),function(e){e.Running="Running",e.Waiting="Waiting",e.Terminated="Terminated"}(No||(No={})),function(e){e.Logs="logs",e.Metrics="metrics",e.Traces="traces"}(Io||(Io={})),function(e){e.Deployment="Deployment",e.DaemonSet="DaemonSet",e.StatefulSet="StatefulSet",e.CronJob="CronJob",e.DeploymentConfig="DeploymentConfig"}(zo||(zo={})),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"}(Oo||(Oo={}));const Ro=s=>{const l=s?.toLowerCase(),c=l?.includes(Gt.Samplers),d=l===Gt.Attributes;return c?e:d?t:{[Kt.K8sAttributes]:n,[Kt.AddClusterInfo]:i,[Kt.DeleteAttributes]:a,[Kt.PiiMasking]:t,[Kt.RenameAttributes]:r,[Kt.ErrorSampler]:e,[Kt.ProbabilisticSampler]:e,[Kt.LatencySampler]:e,[Kt.ServiceNameSampler]:e,[Kt.SpanAttributeSampler]:e}[s]||o},Lo=[{label:"Attributes",icon:Ro(Gt.Attributes),items:[{type:Kt.K8sAttributes,icon:Ro(Kt.K8sAttributes),label:"Kubernetes Attributes",description:"Add dynamic k8s resource attributes to your data.",allowedSignals:[Io.Traces,Io.Metrics,Io.Logs],docsEndpoint:"/pipeline/actions/attributes/k8sattributes",docsDescription:"This action adds kubernetes related resource attributes to spans, metrics data points and log records."},{type:Kt.AddClusterInfo,icon:Ro(Kt.AddClusterInfo),label:"Add Cluster Info",description:"Add static cluster-scoped attributes to your data.",allowedSignals:[Io.Traces,Io.Metrics,Io.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:Kt.DeleteAttributes,icon:Ro(Kt.DeleteAttributes),label:"Delete Attribute",description:"Delete attributes from logs, metrics, and traces.",allowedSignals:[Io.Traces,Io.Metrics,Io.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:Kt.RenameAttributes,icon:Ro(Kt.RenameAttributes),label:"Rename Attribute",description:"Rename attributes in logs, metrics, and traces.",allowedSignals:[Io.Traces,Io.Metrics,Io.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:Kt.PiiMasking,icon:Ro(Kt.PiiMasking),label:"PII Masking",description:"Mask PII data in your traces.",allowedSignals:[Io.Traces],docsEndpoint:"/pipeline/actions/attributes/piimasking",docsDescription:"This action processes a list of PII categories to be masked from the traces."}]},{label:"Samplers",icon:Ro(Gt.Samplers),items:[{type:Kt.ErrorSampler,icon:Ro(Gt.Samplers),label:"Error Sampler",description:"Sample errors based on percentage.",allowedSignals:[Io.Traces],docsEndpoint:"/pipeline/actions/sampling/errorsampler",docsDescription:"This action is a Global Action that supports error sampling by filtering out non-error traces."},{type:Kt.LatencySampler,icon:Ro(Gt.Samplers),label:"Latency Sampler",description:"Add latency to your traces.",allowedSignals:[Io.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:Kt.ProbabilisticSampler,icon:Ro(Gt.Samplers),label:"Probabilistic Sampler",description:"Sample traces based on percentage.",allowedSignals:[Io.Traces],docsEndpoint:"/pipeline/actions/sampling/probabilisticsampler",docsDescription:"This action supports probabilistic sampling based on a configured sampling percentage applied to the TraceID."},{type:Kt.ServiceNameSampler,icon:Ro(Gt.Samplers),label:"Service Name Sampler",description:"Sample traces based on the presence of specified services within a trace.",allowedSignals:[Io.Traces],docsEndpoint:"/pipeline/actions/sampling/servicenamesampler",docsDescription:"This action supports service name sampling based on the presence of specified services within a trace."},{type:Kt.SpanAttributeSampler,icon:Ro(Gt.Samplers),label:"Span Attributes Sampler",description:"Sample traces based on the presence or value of specific attributes within a trace.",allowedSignals:[Io.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."}]}],Bo={DETECTED:{TITLE:"Detected by Odigos",DESCRIPTION:"Odigos found these destinations in your cluster and pre-filled their details. Review and enable them to start sending data."},EXISTS:{TITLE:"Already configured",DESCRIPTION:"These are destinations that you have already configured in other data-streams and can reuse them."},MANAGED:{TITLE:"Managed",DESCRIPTION:"Effortless monitoring with scalable performance management."},SELF_HOSTED:{TITLE:"Self-hosted",DESCRIPTION:"Full control and customization for advanced application monitoring."}},Po=e=>({[ko.CodeAttributes]:s,[ko.CustomInstrumentation]:l,[ko.HeadersCollection]:c,[ko.PayloadCollection]:d,[ko.UnknownType]:o}[e]||o),Mo=[{type:ko.CodeAttributes,icon:Po(ko.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:[ro.Go,ro.Python]},{type:ko.CustomInstrumentation,icon:Po(ko.CustomInstrumentation),label:"Custom Instrumentation",description:"Define custom instrumentation for specific class and methods(i.e for Java) or explicit symbol(i.e. 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:[ro.Go,ro.Java]},{type:ko.HeadersCollection,icon:Po(ko.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:[ro.Go,ro.Java,ro.JavaScript]},{type:ko.PayloadCollection,icon:Po(ko.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:[ro.Go]}],jo=[{id:Io.Logs,value:"Logs"},{id:Io.Metrics,value:"Metrics"},{id:Io.Traces,value:"Traces"}],Uo=e=>e.charAt(0).toUpperCase()+e.slice(1),Wo=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,n])=>Array.isArray(n)?[e,t(n)]:"object"==typeof n&&null!==n?[e,o(n)]:[e,n]));return Object.entries(e).reduce((e,[n,i])=>{try{const a=JSON.parse(i);Array.isArray(a)?e[n]=JSON.stringify(t(a)):e[n]="object"==typeof a&&null!==a?JSON.stringify(o(a)):i}catch(a){"object"==typeof i&&null!==i?Array.isArray(i)?e[n]=JSON.stringify(t(i)):e[n]=JSON.stringify(o(i)):e[n]=i}return e},{})};var Vo;!function(e){e.SIGNALS="SIGNALS"}(Vo||(Vo={}));const Ho=(e,t,o)=>{if(!e||!e.length)return!0;if(1===e.length)return"true"==e[0];const[n,i,a]=e;if(n===Vo.SIGNALS)switch(i){case"INCLUDES":return t?.includes(a);case"EXCLUDES":return!t?.includes(a);default:return!0}const r=o.find(e=>e.name===n);if(!r)return!0;switch(i){case"===":case"==":return r.value===a;case"!==":case"!=":return r.value!==a;case">":return Number(r.value)>Number(a);case"<":return Number(r.value)<Number(a);case">=":return Number(r.value)>=Number(a);case"<=":return Number(r.value)<=Number(a);default:return!0}},qo=e=>JSON.parse(JSON.stringify(e)),Go=(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},Ko=(e,t)=>{let o=[...e];return t.monitors?.length&&(o=o.filter(e=>!!t.monitors?.find(t=>e.exportedSignals[t.id]))),o},Jo=(e,t)=>t?e.filter(e=>e.dataStreamNames.includes(t)||!e.dataStreamNames.length):[],Yo=(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.onlyErrors&&(o=o.filter(e=>!!e.conditions?.find(e=>e.status===ho.Error))),t.errors?.length&&(o=o.filter(e=>!!t.errors?.find(t=>!!e.conditions?.find(e=>e.message===t.id)))),o},Xo="default",Qo={SELECTED_DATA_STREAM:"SELECTED_DATA_STREAM",SELECTED_DATA_STREAM_WITH_PROXY:e=>`SELECTED_DATA_STREAM_${e}`,OVERVIEW_FILTERS:"OVERVIEW_FILTERS",DARK_MODE:"DARK_MODE"},Zo={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)'},en={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",SUMMARY:"Summary",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:"Auto-instrument new apps",FUTURE_APPS_DESCRIPTION:"When enabled, new applications will be instrumented automatically and included in the current data stream.",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"},tn={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"},on=(e,t)=>t?e.filter(e=>e.dataStreamNames.includes(t)||t===Xo&&!e.dataStreamNames.length):[],nn=(e,t="",o={})=>{for(const n in e)if(e.hasOwnProperty(n)){const i=e[n],a=t?`${t}.${n}`:n;null===i||"object"!=typeof i||Array.isArray(i)?Array.isArray(i)?i.forEach((e,t)=>{const n=`${a}[${t}]`;null!==e&&"object"==typeof e?nn(e,n,o):o[n]=e}):o[a]=i:nn(i,a,o)}return o},an=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]}`},rn=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`}},sn=()=>{const e=crypto.getRandomValues(new Uint8Array(16));let t=0;return"10000000-1000-4000-8000-100000000000".replace(/[018]/g,o=>{const n=e[t%16];return t++,("1"===o?n:"0"===o?63&n|128:15&n|64).toString(16)})},ln=e=>{const t=e?.filter(({status:e})=>e===ho.Error),o=e?.filter(({status:e})=>e===ho.Warning),n=e?.filter(({status:e})=>e===go.Disabled),i=e?.filter(({status:e})=>e===go.Loading),a=t.length>0,r=o.length>0,s=n.length>0;return{errors:t,hasErrors:a,warnings:o,hasWarnings:r,disableds:n,hasDisableds:s,loadings:i,hasLoadings:i.length>0,priorotizedStatus:a?ho.Error:r?ho.Warning:s?ho.Info:void 0}},cn=e=>{const t=e?.reduce((e,t)=>t.instrumented?e+1:e,0);return`${t}/${e?.length||0} instrumented`},dn=e=>({[ro.Java]:p,[ro.Go]:u,[ro.JavaScript]:h,[ro.Python]:m,[ro.DotNet]:g,[ro.CSharp]:x,[ro.CPlusPlus]:$,[ro.Php]:f,[ro.Ruby]:b,[ro.Rust]:y,[ro.Swift]:w,[ro.Elixir]:k,[ro.MySql]:v,[ro.Nginx]:C,[ro.Postgres]:E,[ro.Redis]:S,[ro.Kafka]:A,[ro.Ignored]:o,[ro.Unknown]:o,[ro.Processing]:o,[ro.NoContainers]:o,[ro.NoRunningPods]:o}[e]||o),pn=e=>e?.map(({language:e})=>dn(e))||[],un=(e,t)=>{const o={[wo.Alauda]:D,[wo.AlibabaCloud]:T,[wo.AppDynamics]:N,[wo.Axiom]:I,[wo.AzureBlob]:z,[wo.AzureMonitor]:O,[wo.BetterStack]:_,[wo.Bonree]:F,[wo.Causely]:R,[wo.Checkly]:L,[wo.Chronosphere]:B,[wo.ClickHouse]:P,[wo.CloudWatch]:M,[wo.Coralogix]:j,[wo.Dash0]:U,[wo.Datadog]:W,[wo.Dynamic]:V,[wo.Dynatrace]:H,[wo.ElasticApm]:q,[wo.ElasticSearch]:G,[wo.GoogleCloud]:K,[wo.GoogleCloudOTLP]:K,[wo.GrafanaCloudLoki]:J,[wo.GrafanaCloudPrometheus]:J,[wo.GrafanaCloudTempo]:J,[wo.Greptime]:Y,[wo.Groundcover]:X,[wo.Honeycomb]:Q,[wo.HyperDX]:Z,[wo.Instana]:ee,[wo.Jaeger]:te,[wo.Kafka]:A,[wo.Kloudmate]:oe,[wo.Last9]:ne,[wo.Lightstep]:ie,[wo.LogzIo]:ae,[wo.Loki]:re,[wo.Lumigo]:se,[wo.Middleware]:le,[wo.NewRelic]:ce,[wo.Observe]:de,[wo.Odigos]:pe,[wo.OneUptime]:ue,[wo.OpenObserve]:he,[wo.Opsverse]:me,[wo.Oracle]:ge,[wo.OTLP]:V,[wo.OTLPHttp]:V,[wo.Prometheus]:xe,[wo.Qryn]:$e,[wo.QrynOss]:fe,[wo.Quickwit]:be,[wo.S3]:ye,[wo.Seq]:we,[wo.Signoz]:ke,[wo.Splunk]:ve,[wo.SplunkSapm]:ve,[wo.SplunkOtlp]:ve,[wo.SumoLogic]:Ce,[wo.TelemetryHub]:Ee,[wo.Tempo]:Se,[wo.Tingyun]:Ae,[wo.Traceloop]:De,[wo.Uptrace]:Te,[wo.VictoriaMetrics]:Ne,[wo.VictoriaMetricsCloud]:Ne,[wo.XRay]:Ie}[e];return o&&!t?{icon:o}:{iconSrc:`https://d15jtxgb40qetw.cloudfront.net/${e}.svg`}},hn=e=>({[lo.Namespace]:ze,[lo.Source]:Oe,[lo.Destination]:_e,[lo.Action]:Fe,[lo.InstrumentationRule]:Re}[e]),mn=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,gn=(e,t,o)=>{const{extended:n,prioritizeDisplayName:i}=o||{};let a="",r="";switch(t){case lo.InstrumentationRule:const t=e;a=t.type,r=t.ruleName;break;case lo.Source:const o=e;a=o.name,r=o.otelServiceName;break;case lo.Action:const n=e;a=n.type,r=n.name;break;case lo.Destination:const i=e;a=i.destinationType.displayName,r=i.name;break;case lo.Namespace:const s=e;a=s.name,r=s.name}return n?a+(r&&r!==a?` (${r})`:""):i&&r||a},xn=(e,t)=>{if(t===lo.Source){const t={namespace:"",name:"",kind:""};return e.split("&").forEach(e=>{const[o,n]=e.split("=");t[o]=n}),t}return e},$n=e=>{const{numberOfInstances:t,containers:o}=e;if(!o)return t&&t>0?ro.Processing:ro.NoRunningPods;const n=o?.filter(e=>e.language!==ro.Ignored);if(!n.length)return ro.NoContainers;const i=n.find(e=>e.language!==ro.Unknown);return i?i.language:ro.Unknown},fn=(e,t,o)=>(t===lo.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},bn=e=>({[Io.Logs]:Le,[Io.Metrics]:Be,[Io.Traces]:Pe}[e]),yn=e=>e?{[io.K8s]:n,[io.Vm]:Me}[e]:pe,wn=e=>e?{[io.K8s]:"Kubernetes Cluster",[io.Vm]:"Virtual Machine"}[e]:"Unknown",kn=(e,t,o)=>{const n=e[t];return n?n.flatMap(e=>{const n=e[o],i=[];return void 0!==n&&(Array.isArray(n)?i.push(...n):i.push(n)),i.push(...kn(e,t,o)),i}):[]},vn=(e,t)=>{if(t===lo.Source){let t="";return Object.entries(e).forEach(([e,o])=>{t+=`${e}=${o}&`}),t.slice(0,-1),t}return e},Cn=(e,t,o)=>{switch(t){case ho.Default:return e.v2.colors.purple[o];case ho.Info:return e.v2.colors.blue[o];case ho.Error:return e.v2.colors.red[o];case ho.Warning:return e.v2.colors.yellow[o];case ho.Success:return e.v2.colors.green[o];case xo.Disabled:case xo.Unknown:return e.v2.colors.silver[o];default:return e.v2.colors.white[500]}},En=e=>{switch(e){case Ao.Updating:case Do.Pending:case To.ContainerCreating:case No.Waiting:return ho.Info;case Ao.Healthy:case Do.Succeeded:case Do.Running:case To.Running:case No.Running:return ho.Success;case Ao.Degraded:return ho.Warning;case Ao.Failed:case Do.Failed:case To.Error:case To.CrashLoopBackOff:case To.CreateContainerError:case To.CreateContainerConfigError:case To.ErrImagePull:case To.ErrImageNeverPull:case To.ImagePullBackOff:case To.InvalidImageName:case To.RegistryUnavailable:case To.NetworkNotReady:case To.OOMKilled:case To.ContainerCannotRun:case No.Terminated:case To.DeadlineExceeded:case To.StartError:return ho.Error;case Ao.Down:case To.Completed:return xo.Disabled;case Ao.Unknown:case Do.Unknown:default:return xo.Unknown}},Sn=(e,t)=>({[ho.Default]:o=>pe({fill:Cn(t,e,"300"),...o}),[ho.Info]:o=>je({fill:Cn(t,e,"400"),...o}),[ho.Error]:o=>Ue({fill:Cn(t,e,"500"),...o}),[ho.Warning]:o=>We({fill:Cn(t,e,"500"),...o}),[ho.Success]:o=>Ve({fill:Cn(t,e,"500"),...o}),[xo.Disabled]:o=>He({fill:Cn(t,e,"400"),...o}),[xo.Unknown]:o=>qe({fill:Cn(t,e,"300"),...o})}[e]),An=e=>{switch(e){case Oo.Success:return ho.Success;case Oo.Error:case Oo.Failure:return ho.Error;case Oo.Notice:return ho.Warning;case Oo.Unsupported:case Oo.Unknown:return ho.Info;case Oo.Irrelevant:case Oo.Disabled:return go.Disabled;case Oo.Waiting:return go.Loading;case Oo.Pending:default:return ho.Default}},Dn=(e,t)=>{const o=t.find(([t,o])=>e>=t&&(null===o||e<=o));return o?.[2]||null},Tn=({namespace:e,name:t,kind:o})=>({namespace:e,name:t,kind:o});function Nn(e,t){if(!e)return t;if("object"==typeof e)return e;try{return JSON.parse(e)}catch(e){return t}}const In=(e,t)=>{const o=[],n=JSON.parse(JSON.stringify(e));for(const e of n){const n=Nn(t.fields,{}),i=e.items.findIndex(e=>e.type===t.destinationType.type);-1!==i&&o.push(...e.items[i].fields.map(e=>({...e,initialValue:n[e.name]})))}return o},zn=(e,t)=>{const o=e=>e?.some(({healthy:e})=>e.status!==ho.Success);return e?.length?e.some(({instrumentationInstances:e})=>o(e)):o(t)??!1},On=e=>Array.isArray(e)?!e?.length:"object"==typeof e?!Object.keys(e||{}).length:[void 0,null,""].includes(e),_n=e=>!!e&&(!(e.length>63)&&/^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$/.test(e)),Fn=(e,t=0)=>{const o=(new Date).getTime();return new Date(e).getTime()-o<=t},Rn=e=>{const t=String(e).trim().toLowerCase();return["true","false","1","0"].includes(t)},Ln=(e,t=0)=>(new Date).getTime()-new Date(e).getTime()>=t,Bn=/^(\d+\.)?(\d+\.)?(\*|\d+)$/,Pn=e=>Bn.test(e),Mn=e=>e?e.replace(/([a-z0-9])([A-Z])/g,"$1 $2"):"",jn=e=>e?.map(({status:e,type:t,reason:o,message:n,lastTransitionTime:i})=>({status:e,type:Mn(t),reason:o?Mn(o):"",message:n,lastTransitionTime:i}))||[],Un=(e,t)=>{const o=Nn(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}))},Wn=e=>e?Object.keys(e).filter(t=>e[t]):[],Vn=e=>e.replace(/[^\d]/g,""),Hn=e=>{const t=String(e).trim().toLowerCase();return"true"===t||"1"===t},qn=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},Gn=e=>{if("object"!=typeof e)return e;const t=Array.isArray(e)?[]:{};return Object.keys(e).forEach(o=>{const n=e[o];if(Array.isArray(n)){const e=n.filter(e=>null!=e&&""!==e);e.length>0&&(t[o]=e.map(e=>Gn(e)))}else if("object"==typeof n&&null!==n){const e=Gn(n);Object.keys(e).length>0&&(t[o]=e)}else[void 0,null,""].includes(n)||(t[o]=n)}),t},Kn=(e,t=2)=>JSON.stringify(e||{},null,t),Jn=async(e=1e3)=>new Promise(t=>setTimeout(t,e)),Yn=e=>Object.entries(e).reduce((e,[t,o])=>(e[t]="string"==typeof o?o:JSON.stringify(o),e),{}),Xn={[ro.Go]:"Go",[ro.Java]:"Java",[ro.JavaScript]:"Node.js",[ro.Python]:"Python",[ro.DotNet]:".NET",[ro.CSharp]:"C#",[ro.CPlusPlus]:"C++",[ro.Php]:"PHP",[ro.Ruby]:"Ruby",[ro.Rust]:"Rust",[ro.Swift]:"Swift",[ro.Elixir]:"Elixir",[ro.MySql]:"MySQL",[ro.Nginx]:"Nginx",[ro.Postgres]:"PostgreSQL",[ro.Redis]:"Redis",[ro.Kafka]:"Kafka",[ro.Ignored]:"Ignored",[ro.Unknown]:"Unknown",[ro.Processing]:"Processing",[ro.NoContainers]:"No Containers",[ro.NoRunningPods]:"No Running Pods"},Qn=[{id:ro.Go,value:Xn[ro.Go],icon:dn(ro.Go)},{id:ro.Java,value:Xn[ro.Java],icon:dn(ro.Java)},{id:ro.JavaScript,value:Xn[ro.JavaScript],icon:dn(ro.JavaScript)},{id:ro.Python,value:Xn[ro.Python],icon:dn(ro.Python)},{id:ro.Php,value:Xn[ro.Php],icon:dn(ro.Php)},{id:ro.Ruby,value:Xn[ro.Ruby],icon:dn(ro.Ruby)},{id:ro.Rust,value:Xn[ro.Rust],icon:dn(ro.Rust)},{id:ro.DotNet,value:Xn[ro.DotNet],icon:dn(ro.DotNet)},{id:ro.CSharp,value:Xn[ro.CSharp],icon:dn(ro.CSharp)},{id:ro.CPlusPlus,value:Xn[ro.CPlusPlus],icon:dn(ro.CPlusPlus)},{id:ro.Swift,value:Xn[ro.Swift],icon:dn(ro.Swift)},{id:ro.Elixir,value:Xn[ro.Elixir],icon:dn(ro.Elixir)}],Zn=6048e5,ei=gt()(St(e=>({darkMode:!0,setDarkMode:t=>e({darkMode:t})}),{name:Qo.DARK_MODE,storage:"undefined"!=typeof window?At(()=>localStorage):void 0})),ti={dataStreamsLoading:!1,dataStreams:[],selectedStreamName:""},oi=gt(e=>({...ti,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(ti)})),ni=gt(e=>({drawerType:null,drawerEntityId:null,setDrawerType:t=>e({drawerType:t}),setDrawerEntityId:t=>e({drawerEntityId:t})})),ii=gt(e=>({namespacesLoading:!1,namespaces:[],sourcesLoading:!1,sources:[],destinationsLoading:!1,destinations:[],actionsLoading:!1,actions:[],instrumentationRulesLoading:!1,instrumentationRules:[],setEntitiesLoading:(t,o)=>{const n=t===lo.Namespace?"namespacesLoading":t===lo.Source?"sourcesLoading":t===lo.Destination?"destinationsLoading":t===lo.Action?"actionsLoading":t===lo.InstrumentationRule?"instrumentationRulesLoading":"NONE";"NONE"!==n&&e({[n]:o})},setEntities:(t,o)=>{const n=t===lo.Namespace?"namespaces":t===lo.Source?"sources":t===lo.Destination?"destinations":t===lo.Action?"actions":t===lo.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==n&&e({[n]:o})},addEntities:(t,o)=>{const n=t===lo.Namespace?"namespaces":t===lo.Source?"sources":t===lo.Destination?"destinations":t===lo.Action?"actions":t===lo.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==n&&e(e=>{const t=[...e[n]];return o.forEach(e=>{const o=t.findIndex(t=>JSON.stringify(mn(t))===JSON.stringify(mn(e)));-1!==o?t[o]={...t[o],...e}:t.push(e)}),{[n]:t}})},removeEntities:(t,o)=>{const n=t===lo.Namespace?"namespaces":t===lo.Source?"sources":t===lo.Destination?"destinations":t===lo.Action?"actions":t===lo.InstrumentationRule?"instrumentationRules":"NONE";"NONE"!==n&&e(e=>{const i=[...e[n]];return o.forEach(e=>{const o=i.findIndex(o=>t===lo.Source?JSON.stringify(mn(o))===JSON.stringify(mn(e)):mn(o)===e);-1!==o&&i.splice(o,1)}),{[n]:i}})},resetEntityStore:()=>{e({namespacesLoading:!1,namespaces:[],sourcesLoading:!1,sources:[],destinationsLoading:!1,destinations:[],actionsLoading:!1,actions:[],instrumentationRulesLoading:!1,instrumentationRules:[]})}})),ai=()=>({searchText:"",statuses:[],platformTypes:[],namespaces:[],kinds:[],monitors:[],languages:[],conditions:[],errors:[],onlyErrors:!1}),ri=gt(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}),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:[],errors:[],onlyErrors:!1}),getEmptyState:ai})),si=gt(e=>({isAwaitingInstrumentation:!1,sourcesToCreate:0,sourcesCreated:0,sourcesToDelete:0,sourcesDeleted:0,setInstrumentAwait:t=>e({isAwaitingInstrumentation:t}),setInstrumentCount:(t,o)=>e({[t]:o})})),li=gt(e=>({currentModal:"",setCurrentModal:t=>e({currentModal:t})})),ci=gt((e,t)=>({notifications:[],addNotification:o=>{const n=new Date,i=`${n.getTime().toString()}${o.target?`#${o.target}`:""}`,{notifications:a}=t();a.some(e=>e.type===o.type&&e.title===o.title&&e.message===o.message&&!e.dismissed)||e(e=>({notifications:[{...o,id:i,time:n.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)}))}})),di=(e,t)=>{const o=e.entityType===t.entityType,n="string"==typeof e.entityId&&"string"==typeof t.entityId?e.entityId===t.entityId:"object"==typeof e.entityId&&"object"==typeof t.entityId?e.entityId.namespace===t.entityId.namespace&&e.entityId.name===t.entityId.name&&e.entityId.kind===t.entityId.kind:!e.entityId&&!t.entityId;return o&&n},pi=gt((e,t)=>({pendingItems:[],setPendingItems:t=>e({pendingItems:t}),addPendingItems:t=>e(e=>({pendingItems:e.pendingItems.concat(t.filter(t=>!e.pendingItems.some(e=>di(e,t))))})),removePendingItems:t=>e(e=>({pendingItems:e.pendingItems.filter(e=>!t.find(t=>di(e,t)))})),isThisPending:e=>{const{pendingItems:o}=t();let n=!1;for(let t=0;t<o.length;t++){const i=o[t];if(i.entityType===e.entityType&&(!e.entityId||(i.entityType===lo.Source?i.entityId&&e.entityId&&i.entityId.namespace===e.entityId.namespace&&i.entityId.name===e.entityId.name&&i.entityId.kind===e.entityId.kind:i.entityId===e.entityId))){n=!0;break}}return n}})),ui=gt(e=>({selectedConnection:null,setSelectedConnection:t=>e({selectedConnection:t}),selectedSources:{},setSelectedSources:t=>e({selectedSources:t}),resetSelectedState:()=>e(()=>({selectedSources:{},selectedConnection:null}))})),hi={fetchedAllNamespaces:!1,availableSources:{},configuredSources:{},configuredFutureApps:{},configuredDestinations:[],configuredDestinationsUpdateOnly:[]},mi=(e,t)=>e.destinationType.type!==t.destinationType.type,gi=gt(e=>({...hi,setFetchedAllNamespaces:t=>e({fetchedAllNamespaces:t}),setAvailableSources:t=>e({availableSources:t}),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=>mi(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=>mi(e,t))})),clearStore:()=>e(()=>({...hi}))})),xi={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"}},$i={v2:xi.v2,darkMode:!0,colors:{...xi.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:xi.font_family},fi={v2:xi.v2,darkMode:!1,colors:{...xi.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:xi.font_family},bi=e=>e?$i:fi;var yi=Object.freeze({__proto__:null,baseTheme:xi,darkModeTheme:$i,getTheme:bi,lightModeTheme:fi});Dt('@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 wi={in:{left:Ot`
|
|
2
|
+
from { transform: translateX(-100%); }
|
|
3
|
+
to { transform: translateX(0); }
|
|
4
|
+
`,right:Ot`
|
|
5
|
+
from { transform: translateX(100%); }
|
|
6
|
+
to { transform: translateX(0); }
|
|
7
|
+
`,top:Ot`
|
|
8
|
+
from { transform: translateY(-100%); }
|
|
9
|
+
to { transform: translateY(0); }
|
|
10
|
+
`,bottom:Ot`
|
|
11
|
+
from { transform: translateY(100%); }
|
|
12
|
+
to { transform: translateY(0); }
|
|
13
|
+
`,center:Ot`
|
|
14
|
+
from { transform: translate(-50%, 100%); }
|
|
15
|
+
to { transform: translate(-50%, -50%); }
|
|
16
|
+
`},out:{left:Ot`
|
|
17
|
+
from { transform: translateX(0); }
|
|
18
|
+
to { transform: translateX(-100%); }
|
|
19
|
+
`,right:Ot`
|
|
20
|
+
from { transform: translateX(0); }
|
|
21
|
+
to { transform: translateX(100%); }
|
|
22
|
+
`,top:Ot`
|
|
23
|
+
from { transform: translateY(0); }
|
|
24
|
+
to { transform: translateY(-100%); }
|
|
25
|
+
`,bottom:Ot`
|
|
26
|
+
from { transform: translateY(0); }
|
|
27
|
+
to { transform: translateY(100%); }
|
|
28
|
+
`,center:Ot`
|
|
29
|
+
from { transform: translate(-50%, -50%); }
|
|
30
|
+
to { transform: translate(-50%, 100%); }
|
|
31
|
+
`}},ki={in:Ot`
|
|
32
|
+
from {
|
|
33
|
+
width: 0%;
|
|
34
|
+
}
|
|
35
|
+
to {
|
|
36
|
+
width: 100%;
|
|
37
|
+
}
|
|
38
|
+
`,out:Ot`
|
|
39
|
+
from {
|
|
40
|
+
width: 100%;
|
|
41
|
+
}
|
|
42
|
+
to {
|
|
43
|
+
width: 0%;
|
|
44
|
+
}
|
|
45
|
+
`},vi=Ot`
|
|
46
|
+
0% {
|
|
47
|
+
transform: scale(1);
|
|
48
|
+
opacity: 1;
|
|
49
|
+
}
|
|
50
|
+
75%, 100% {
|
|
51
|
+
transform: scale(2);
|
|
52
|
+
opacity: 0;
|
|
53
|
+
}
|
|
54
|
+
`,Ci=Ot`
|
|
55
|
+
0% {
|
|
56
|
+
background-position: -500px 0;
|
|
57
|
+
}
|
|
58
|
+
100% {
|
|
59
|
+
background-position: 500px 0;
|
|
60
|
+
}
|
|
61
|
+
`,Ei={in:Ot`
|
|
62
|
+
from {
|
|
63
|
+
opacity: 0;
|
|
64
|
+
}
|
|
65
|
+
to {
|
|
66
|
+
opacity: 1;
|
|
67
|
+
}
|
|
68
|
+
`,out:Ot`
|
|
69
|
+
from {
|
|
70
|
+
opacity: 1;
|
|
71
|
+
}
|
|
72
|
+
to {
|
|
73
|
+
opacity: 0;
|
|
74
|
+
}
|
|
75
|
+
`},Si={Provider:({children:e})=>{const{darkMode:t}=ei();return xt.createElement(zt,{theme:bi(t)},e)},useTheme:_t,opacity:Object.freeze({__proto__:null,hex:{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"}}),palletes:yi,animations:Object.freeze({__proto__:null,fade:Ei,ping:vi,progress:ki,shimmer:Ci,slide:wi})};var Ai,Di;!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"}(Ai||(Ai={})),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"}(Di||(Di={}));const Ti=It.p`
|
|
76
|
+
margin: 0;
|
|
77
|
+
color: ${({$color:e,theme:t})=>e||t.v2.colors.white[500]};
|
|
78
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
79
|
+
font-size: ${({theme:e,$size:t})=>e.v2.text.size[t]}px;
|
|
80
|
+
font-weight: ${({$weight:e})=>e};
|
|
81
|
+
text-align: ${({$align:e})=>e};
|
|
82
|
+
text-transform: ${({$transform:e})=>e};
|
|
83
|
+
line-height: ${({theme:e,$lineHeight:t,$size:o})=>t||`${e.v2.text.size[o]+2}px`};
|
|
84
|
+
|
|
85
|
+
${({$nowrap:e})=>e&&Ft`
|
|
86
|
+
text-wrap: nowrap;
|
|
87
|
+
white-space: nowrap;
|
|
88
|
+
overflow: hidden;
|
|
89
|
+
text-overflow: ellipsis;
|
|
90
|
+
`}
|
|
91
|
+
`,Ni=({children:e,variant:t=Ai.P,color:o,size:n=Di.S,weight:i=400,align:a="left",lineHeight:r,transform:s,nowrap:l,...c})=>xt.createElement(Ti,{as:t,$color:o,$size:n,$weight:i,$align:a,$lineHeight:r,$transform:s,$nowrap:l,...c},e),Ii=It.div`
|
|
92
|
+
display: flex;
|
|
93
|
+
align-items: center;
|
|
94
|
+
justify-content: center;
|
|
95
|
+
gap: 4px;
|
|
96
|
+
width: fit-content;
|
|
97
|
+
padding: 4px 8px;
|
|
98
|
+
border-radius: 100px;
|
|
99
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
100
|
+
`,zi=({label:e,leftIcon:t,rightIcon:o,status:n,useSecondaryTone:i=!1})=>{const a=Si.useTheme(),r=n?[xo.Disabled].includes(n)?Cn(a,n,"700"):[xo.Unknown].includes(n)?Cn(a,n,"600"):Cn(a,n,i?"700":"500"):a.v2.colors.grey[200],s=[xo.Disabled].includes(n)?a.v2.colors.grey[400]:[ho.Error,ho.Warning,ho.Success].includes(n)?a.v2.colors.black[500]:a.v2.colors.white[500];return xt.createElement(Ii,{$backgroundColor:r},t&&xt.createElement(t,{fill:s,size:14}),xt.createElement(Ni,{color:s,size:Di.XXS,nowrap:!0},e),o&&xt.createElement(o,{fill:s,size:14}))},Oi=It.div`
|
|
101
|
+
color: ${({$color:e,theme:t})=>e||t.text.secondary};
|
|
102
|
+
font-size: ${({$size:e})=>void 0!==e?e:16}px;
|
|
103
|
+
font-weight: ${({$weight:e})=>void 0!==e?e:300};
|
|
104
|
+
text-align: ${({$align:e})=>e||"left"};
|
|
105
|
+
opacity: ${({$opacity:e})=>void 0!==e?e:1};
|
|
106
|
+
text-decoration: ${({$decoration:e})=>e||"none"};
|
|
107
|
+
text-transform: ${({$transform:e,$family:t})=>e||("secondary"===t?"uppercase":"none")};
|
|
108
|
+
font-family: ${({theme:e,$family:t="primary"})=>e.font_family[t]};
|
|
109
|
+
white-space: ${({$nowrap:e})=>e?"nowrap":"unset"};
|
|
110
|
+
text-wrap: ${({$nowrap:e})=>e?"nowrap":"unset"};
|
|
111
|
+
`,_i=e=>{const t=e.match(/<a[^>]*href="([^"]*)"[^>]*>(.*?)<\/a>/g);return t?.map(e=>{const[t,o,n]=e.split('"');return{original:e,href:o,label:n.replace("</a>","").replace(">","")}})},Fi=e=>{const t=e.match(/<strong[^>]*>(.*?)<\/strong>/g);return t?.map(e=>{const t=e.replace(/<strong[^>]*>/,"").replace(/<\/strong>/,"");return{original:e,label:t}})},Ri=(e,t)=>{const o=_i(e);o?.forEach((t,o)=>{e=e.replace(t.original,`LINK-${o}###`)});const n=Fi(e);return n?.forEach((t,o)=>{e=e.replace(t.original,`STRONG-${o}###`)}),e.split(" ").map(e=>{if(e.includes("LINK-")){const[n,i]=e.split("###"),a=o?.[parseInt(n.replace("LINK-",""))];return xt.createElement($t,{key:e},xt.createElement("a",{href:a?.href,target:"_blank",rel:"noreferrer",style:{color:t.colors.majestic_blue_soft}},a?.label),i?`${i} `:" ")}if(e.includes("STRONG-")){const[t,o]=e.split("###"),i=n?.[parseInt(t.replace("STRONG-",""))];return xt.createElement($t,{key:e},xt.createElement("strong",{style:{fontWeight:600}},i?.label),o?`${o} `:" ")}return e+" "})},Li=({children:e,color:t,size:o,weight:n,align:i,family:a,opacity:r,decoration:s,transform:l,nowrap:c,...d})=>{const p=Si.useTheme(),u=ft(()=>(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 xt.createElement(Oi,{$color:t,$size:o,$weight:n,$align:i,$family:a,$opacity:r,$decoration:s,$transform:l,$nowrap:c,...d},u.length?u.map((e,t)=>xt.createElement($t,{key:`text-${t}-${e}`},Ri(e,p),t!==u.length-1?xt.createElement("br",null):null)):e)},Bi=Ot`
|
|
112
|
+
0% {
|
|
113
|
+
background-position: 0% 50%;
|
|
114
|
+
}
|
|
115
|
+
100% {
|
|
116
|
+
background-position: 100% 50%;
|
|
117
|
+
}
|
|
118
|
+
`,Pi=It(Li)`
|
|
119
|
+
background: ${({$textColor:e,$stripColor:t})=>`linear-gradient(45deg, ${e} 0%, ${e} 40%, ${t} 50%, ${e} 60%, ${e} 100%)`};
|
|
120
|
+
background-size: 250% 100%; /* Expand background to allow movement */
|
|
121
|
+
background-clip: text;
|
|
122
|
+
color: transparent;
|
|
123
|
+
animation: ${Bi} 1s reverse linear infinite;
|
|
124
|
+
`,Mi=({children:e="Loading...",textColor:t,stripColor:o,...n})=>{const i=Si.useTheme(),a=t||i.v2.colors.white[500],r=o||i.v2.colors.black[500];return xt.createElement(Pi,{$textColor:a,$stripColor:r,...n},e)};var ji,Ui;!function(e){e.Primary="primary",e.Secondary="secondary",e.Text="text"}(ji||(ji={})),function(e){e.S="small",e.M="medium",e.L="large"}(Ui||(Ui={}));const Wi=It.button`
|
|
125
|
+
display: flex;
|
|
126
|
+
align-items: center;
|
|
127
|
+
justify-content: center;
|
|
128
|
+
gap: 8px;
|
|
129
|
+
${({$fullWidth:e})=>e&&Ft`
|
|
130
|
+
width: 100%;
|
|
131
|
+
`}
|
|
132
|
+
border: none;
|
|
133
|
+
border-radius: 6px;
|
|
134
|
+
${({$size:e,$hasLabel:t})=>e===Ui.S?Ft`
|
|
135
|
+
height: 32px;
|
|
136
|
+
${t?Ft`
|
|
137
|
+
padding: 8px 16px;
|
|
138
|
+
`:Ft`
|
|
139
|
+
width: 32px;
|
|
140
|
+
`}
|
|
141
|
+
`:e===Ui.M?Ft`
|
|
142
|
+
height: 38px;
|
|
143
|
+
${t?Ft`
|
|
144
|
+
padding: 8px 18px;
|
|
145
|
+
`:Ft`
|
|
146
|
+
width: 38px;
|
|
147
|
+
`}
|
|
148
|
+
`:Ft`
|
|
149
|
+
height: 44px;
|
|
150
|
+
${t?Ft`
|
|
151
|
+
padding: 8px 22px;
|
|
152
|
+
`:Ft`
|
|
153
|
+
width: 44px;
|
|
154
|
+
`}
|
|
155
|
+
`}
|
|
156
|
+
|
|
157
|
+
cursor: pointer;
|
|
158
|
+
&:disabled {
|
|
159
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
160
|
+
cursor: not-allowed;
|
|
161
|
+
}
|
|
162
|
+
&:enabled {
|
|
163
|
+
${({$withShadow:e})=>e?Ft`
|
|
164
|
+
box-shadow: 0 0 11px 0 rgba(0, 0, 0, 0.32);
|
|
165
|
+
`:""}
|
|
166
|
+
${({$variant:e})=>e===ji.Primary?Ft`
|
|
167
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[500]};
|
|
168
|
+
&:hover {
|
|
169
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[600]};
|
|
170
|
+
}
|
|
171
|
+
&:active {
|
|
172
|
+
background-color: ${({theme:e})=>e.v2.colors.purple[700]};
|
|
173
|
+
}
|
|
174
|
+
`:e===ji.Secondary?Ft`
|
|
175
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
176
|
+
&:hover {
|
|
177
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
178
|
+
}
|
|
179
|
+
&:active {
|
|
180
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
181
|
+
}
|
|
182
|
+
`:e===ji.Text?Ft`
|
|
183
|
+
background-color: transparent;
|
|
184
|
+
&:hover {
|
|
185
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
186
|
+
}
|
|
187
|
+
&:active {
|
|
188
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
189
|
+
}
|
|
190
|
+
`:""}
|
|
191
|
+
}
|
|
192
|
+
`,Vi=bt(({label:e,leftIcon:t,rightIcon:o,variant:n=ji.Primary,size:i=Ui.M,iconSize:a,loading:r,fullWidth:s,withShadow:l,disabled:c,onClick:d,...p},u)=>{const h=Si.useTheme(),m=a||(i===Ui.L?18:16),g=i===Ui.L?Di.S:Di.XS,x=c?h.v2.colors.grey[400]:h.v2.colors.white[500];return xt.createElement(Wi,{ref:u,$variant:n,$size:i,$fullWidth:s,$withShadow:l,$hasLabel:!!e,disabled:c,onClick:r?void 0:e=>{e.stopPropagation(),d?.(e)},...p},t&&xt.createElement(t,{size:m,fill:x}),r?xt.createElement(Mi,{size:h.v2.text.size[g],textColor:x}):e?xt.createElement(Ni,{size:g,weight:500,color:x,nowrap:!0},e):null,o&&xt.createElement(o,{size:m,fill:x}))});Vi.displayName=Vi.name;const Hi=It.button`
|
|
193
|
+
width: 100%;
|
|
194
|
+
padding: 0;
|
|
195
|
+
padding-right: 12px;
|
|
196
|
+
display: flex;
|
|
197
|
+
align-items: center;
|
|
198
|
+
justify-content: flex-start;
|
|
199
|
+
gap: 12px;
|
|
200
|
+
border-radius: 8px;
|
|
201
|
+
border: none;
|
|
202
|
+
${({$hovered:e})=>e?Ft`
|
|
203
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
204
|
+
`:Ft`
|
|
205
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
206
|
+
`}
|
|
207
|
+
overflow: hidden;
|
|
208
|
+
cursor: pointer;
|
|
209
|
+
&:disabled {
|
|
210
|
+
cursor: not-allowed;
|
|
211
|
+
}
|
|
212
|
+
`,qi=It.div`
|
|
213
|
+
width: ${({$hasIcon:e})=>e?"56px":"0"};
|
|
214
|
+
height: 56px;
|
|
215
|
+
display: flex;
|
|
216
|
+
align-items: center;
|
|
217
|
+
justify-content: center;
|
|
218
|
+
${({$hovered:e})=>e?Ft`
|
|
219
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
220
|
+
`:Ft`
|
|
221
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
222
|
+
`}
|
|
223
|
+
`,Gi=It.div`
|
|
224
|
+
width: ${({$hasIcon:e})=>e?"calc(100% - 56px)":"100%"};
|
|
225
|
+
display: flex;
|
|
226
|
+
justify-content: space-between;
|
|
227
|
+
align-items: center;
|
|
228
|
+
gap: 8px;
|
|
229
|
+
`,Ki=({label:e,icon:t,loading:o,onClick:n})=>{const[i,a]=yt(!1);return xt.createElement(Hi,{$hovered:i,type:"button",disabled:o,onClick:n,onMouseEnter:()=>a(!0),onMouseLeave:()=>a(!1)},xt.createElement(qi,{$hovered:i,$hasIcon:!!t},t&&xt.createElement(t,{size:36})),xt.createElement(Gi,{$hasIcon:!!t},o?xt.createElement(Mi,{size:16}):xt.createElement(Ni,{variant:Ai.Span,align:"center"},e),xt.createElement(Ge,{rotate:90,size:24})))},Ji=It.div`
|
|
230
|
+
padding: 4px 0 0 0;
|
|
231
|
+
`,Yi=It(Li)`
|
|
232
|
+
font-size: 12px;
|
|
233
|
+
color: ${({theme:e})=>e.text.error};
|
|
234
|
+
`,Xi=({children:e})=>xt.createElement(Ji,null,xt.createElement(Yi,null,e)),Qi=It.div`
|
|
235
|
+
position: relative;
|
|
236
|
+
width: 100%;
|
|
237
|
+
`,Zi=It.div`
|
|
238
|
+
width: calc(100% - 16px);
|
|
239
|
+
display: flex;
|
|
240
|
+
align-items: center;
|
|
241
|
+
height: 36px;
|
|
242
|
+
gap: 8px;
|
|
243
|
+
padding-left: 12px;
|
|
244
|
+
transition: border-color 0.3s;
|
|
245
|
+
border-radius: 32px;
|
|
246
|
+
border: 1px solid ${({theme:e,$hasError:t})=>t?e.text.error:e.colors.border};
|
|
247
|
+
|
|
248
|
+
&:hover {
|
|
249
|
+
border-color: ${({theme:e,$hasError:t})=>t?e.text.error_secondary:e.colors.secondary};
|
|
250
|
+
}
|
|
251
|
+
&:focus-within {
|
|
252
|
+
border-color: ${({theme:e,$hasError:t})=>t?e.text.error_secondary:e.colors.secondary};
|
|
253
|
+
}
|
|
254
|
+
`,ea=It.input`
|
|
255
|
+
flex: 1;
|
|
256
|
+
border: none;
|
|
257
|
+
outline: none;
|
|
258
|
+
background: none;
|
|
259
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
260
|
+
font-size: 14px;
|
|
261
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
262
|
+
font-weight: 300;
|
|
263
|
+
&::placeholder {
|
|
264
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
265
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
266
|
+
opacity: 0.4;
|
|
267
|
+
font-size: 14px;
|
|
268
|
+
font-weight: 300;
|
|
269
|
+
line-height: 22px;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
&:disabled {
|
|
273
|
+
cursor: not-allowed;
|
|
274
|
+
}
|
|
275
|
+
`,ta=It.ul`
|
|
276
|
+
position: absolute;
|
|
277
|
+
max-height: 500px;
|
|
278
|
+
top: 32px;
|
|
279
|
+
border-radius: 24px;
|
|
280
|
+
width: calc(100% - 32px);
|
|
281
|
+
overflow-y: auto;
|
|
282
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
283
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
284
|
+
z-index: 9999;
|
|
285
|
+
padding: 12px;
|
|
286
|
+
`,oa=It.li`
|
|
287
|
+
width: calc(100% - 24px);
|
|
288
|
+
padding: 8px 12px;
|
|
289
|
+
cursor: ${({$isList:e})=>e?"default":"pointer"};
|
|
290
|
+
border-radius: 24px;
|
|
291
|
+
gap: 8px;
|
|
292
|
+
display: flex;
|
|
293
|
+
align-items: ${({$isList:e})=>e?"flex-start":"center"};
|
|
294
|
+
background: transparent;
|
|
295
|
+
&:hover {
|
|
296
|
+
background: ${({theme:e,$isList:t})=>!t&&e.colors.dropdown_bg_2};
|
|
297
|
+
}
|
|
298
|
+
`,na=It.div`
|
|
299
|
+
width: 100%;
|
|
300
|
+
`,ia=It.div`
|
|
301
|
+
display: flex;
|
|
302
|
+
width: 100%;
|
|
303
|
+
`,aa=It.div`
|
|
304
|
+
width: 1px;
|
|
305
|
+
height: 52px;
|
|
306
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
307
|
+
position: absolute;
|
|
308
|
+
left: 33px;
|
|
309
|
+
`,ra=It.div`
|
|
310
|
+
display: flex;
|
|
311
|
+
flex-direction: column;
|
|
312
|
+
gap: 4px;
|
|
313
|
+
`,sa=It(Li)`
|
|
314
|
+
flex: 1;
|
|
315
|
+
font-size: 14px;
|
|
316
|
+
`,la=It(Li)`
|
|
317
|
+
color: ${({theme:e})=>e.text.grey};
|
|
318
|
+
font-size: 10px;
|
|
319
|
+
line-height: 150%;
|
|
320
|
+
`,ca=It.ul`
|
|
321
|
+
padding-left: 0px;
|
|
322
|
+
margin: 4px 0 0 0;
|
|
323
|
+
list-style: none;
|
|
324
|
+
width: 100%;
|
|
325
|
+
`,da=(e,t)=>t?e.reduce((e,o)=>{if(o.items){const n=da(o.items,t);n.length&&e.push({...o,items:n})}else o.label.toLowerCase().includes(t.toLowerCase())&&e.push(o);return e},[]):e,pa=({placeholder:e="Type to search...",options:t,selectedOption:o,onOptionSelect:n,defaultText:i,onTextChange:a,style:r,disabled:s,errorMessage:l,...c})=>{const[d,p]=yt(o?.label||i||""),[u,h]=yt(da(t,d)),[m,g]=yt(!1);yt(-1),wt(()=>h(da(t,d)),[t]);const x=o?.icon,$=e=>{e&&(p(e.label),a?.(e.label)),g(!e),n?.(e)};return xt.createElement(Qi,{style:r},xt.createElement(Zi,{$hasError:!!l},x&&xt.createElement(x,null),xt.createElement(ea,{type:"text",value:d,placeholder:e,onChange:e=>{e.stopPropagation();const o=e.target.value,n=da(t,o),i=1===n.length&&n[0].label===o?n[0]:void 0;p(o),a?.(o),h(n),$(i)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},disabled:s,onBlur:()=>!s&&g(!1),onFocus:()=>!s&&g(!0),...c})),m&&u.length?xt.createElement(ta,null,u.map(e=>xt.createElement(ua,{key:e.type||e.label,option:e,onClick:$}))):null,l&&xt.createElement(Xi,null,l))},ua=({option:e,renderIcon:t=!0,onClick:o})=>{const n=!!e.items&&e.items.length>0,i=e.icon;return xt.createElement(oa,{"data-id":`option-${e.type||e.label}`,$isList:n,onMouseDown:()=>n?null:o(e)},i&&t&&xt.createElement(i,null),xt.createElement(na,null,xt.createElement(ra,null,xt.createElement(sa,null,e.label),xt.createElement(la,null,e.description)),n&&xt.createElement(ca,null,e.items?.map(e=>xt.createElement(ia,{key:e.type||e.label},xt.createElement(aa,null),xt.createElement(ua,{option:e,renderIcon:!1,onClick:o}))))))},ha=It.span`
|
|
326
|
+
display: flex;
|
|
327
|
+
align-items: center;
|
|
328
|
+
justify-content: center;
|
|
329
|
+
|
|
330
|
+
min-height: 16px;
|
|
331
|
+
min-width: 16px;
|
|
332
|
+
width: fit-content;
|
|
333
|
+
padding: 4px;
|
|
334
|
+
gap: 2px;
|
|
335
|
+
|
|
336
|
+
border-radius: 50px;
|
|
337
|
+
border: 1px solid ${({theme:e,$filled:t,$status:o})=>o?e.text[o]+(t?"":Si.opacity.hex["050"]):t?"transparent":e.colors.border};
|
|
338
|
+
background-color: ${({theme:e,$filled:t,$status:o})=>t?o?e.colors[o]:e.colors.majestic_blue:"transparent"};
|
|
339
|
+
color: ${({theme:e,$filled:t,$status:o})=>t&&o?e.text.secondary:t?e.text.white:o?e.text[o]:e.text.grey};
|
|
340
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
341
|
+
font-size: 12px;
|
|
342
|
+
white-space: nowrap;
|
|
343
|
+
|
|
344
|
+
${({theme:e,$filled:t,$status:o,$clickable:n})=>n&&`&:hover {\n cursor: pointer;\n background-color: ${o?e.colors[o]+Si.opacity.hex["020"]:t?e.colors.majestic_blue_soft:e.colors.secondary+Si.opacity.hex["020"]};\n }`}
|
|
345
|
+
`,ma=({label:e,filled:t,status:o,withIcon:n,onClick:i})=>{const a=Si.useTheme(),r=o&&n?Sn(o,a):null;return xt.createElement(ha,{$filled:t,$status:o,$clickable:!!i,onClick:i},!!r&&xt.createElement(r,null),e)},ga=It.div`
|
|
346
|
+
height: fit-content;
|
|
347
|
+
border: 2px solid transparent;
|
|
348
|
+
padding: 2px;
|
|
349
|
+
border-radius: 32px;
|
|
350
|
+
background-color: transparent;
|
|
351
|
+
transition: border-color 0.3s ease;
|
|
352
|
+
&:focus-within {
|
|
353
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
354
|
+
}
|
|
355
|
+
`,xa={primary:Ft`
|
|
356
|
+
border: 1px solid ${({theme:e})=>e.text.secondary+Si.opacity.hex["024"]};
|
|
357
|
+
background: ${({theme:e})=>e.colors.secondary};
|
|
358
|
+
color: ${({theme:e})=>e.colors.primary};
|
|
359
|
+
&:hover {
|
|
360
|
+
background: ${({theme:e})=>e.colors.secondary+Si.opacity.hex["080"]};
|
|
361
|
+
}
|
|
362
|
+
&:active {
|
|
363
|
+
background: ${({theme:e})=>e.text.secondary+Si.opacity.hex["060"]};
|
|
364
|
+
}
|
|
365
|
+
`,secondary:Ft`
|
|
366
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
367
|
+
background: ${({theme:e})=>e.colors.primary};
|
|
368
|
+
color: ${({theme:e})=>e.colors.secondary};
|
|
369
|
+
&:hover {
|
|
370
|
+
border: 1px solid ${({theme:e})=>e.text.darker_grey};
|
|
371
|
+
background: ${({theme:e})=>e.colors.secondary+Si.opacity.hex["010"]};
|
|
372
|
+
}
|
|
373
|
+
&:active {
|
|
374
|
+
border: 1px solid ${({theme:e})=>e.text.dark_grey};
|
|
375
|
+
background: ${({theme:e})=>e.colors.secondary+Si.opacity.hex["015"]};
|
|
376
|
+
}
|
|
377
|
+
`,tertiary:Ft`
|
|
378
|
+
border-color: transparent;
|
|
379
|
+
background: transparent;
|
|
380
|
+
&:hover {
|
|
381
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2+Si.opacity.hex["040"]};
|
|
382
|
+
}
|
|
383
|
+
&:active {
|
|
384
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
385
|
+
}
|
|
386
|
+
`,danger:Ft`
|
|
387
|
+
border-color: transparent;
|
|
388
|
+
background: ${({theme:e})=>e.text.error};
|
|
389
|
+
&:hover {
|
|
390
|
+
background: ${({theme:e})=>e.text.error+Si.opacity.hex["090"]};
|
|
391
|
+
}
|
|
392
|
+
&:active {
|
|
393
|
+
background: ${({theme:e})=>e.text.error+Si.opacity.hex["080"]};
|
|
394
|
+
}
|
|
395
|
+
`,warning:Ft`
|
|
396
|
+
border-color: transparent;
|
|
397
|
+
background: ${({theme:e})=>e.text.warning};
|
|
398
|
+
&:hover {
|
|
399
|
+
background: ${({theme:e})=>e.text.warning+Si.opacity.hex["090"]};
|
|
400
|
+
}
|
|
401
|
+
&:active {
|
|
402
|
+
background: ${({theme:e})=>e.text.warning+Si.opacity.hex["080"]};
|
|
403
|
+
}
|
|
404
|
+
`},$a=It.button`
|
|
405
|
+
height: 36px;
|
|
406
|
+
border-radius: 32px;
|
|
407
|
+
cursor: pointer;
|
|
408
|
+
display: flex;
|
|
409
|
+
align-items: center;
|
|
410
|
+
justify-content: center;
|
|
411
|
+
gap: 8px;
|
|
412
|
+
padding: 0 12px;
|
|
413
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
414
|
+
text-transform: uppercase;
|
|
415
|
+
text-decoration: underline;
|
|
416
|
+
font-weight: 600;
|
|
417
|
+
outline: none;
|
|
418
|
+
${({$variant:e})=>e&&xa[e]}
|
|
419
|
+
${({disabled:e,$variant:t})=>e&&Ft`
|
|
420
|
+
opacity: 0.5;
|
|
421
|
+
cursor: not-allowed;
|
|
422
|
+
|
|
423
|
+
${"primary"===t?Ft`
|
|
424
|
+
color: ${({theme:e})=>e.colors.secondary};
|
|
425
|
+
background: ${({theme:e})=>e.text.secondary+Si.opacity.hex["010"]};
|
|
426
|
+
&:hover {
|
|
427
|
+
background: ${({theme:e})=>e.text.secondary+Si.opacity.hex["015"]};
|
|
428
|
+
}
|
|
429
|
+
`:""}
|
|
430
|
+
`}
|
|
431
|
+
`,fa=({children:e,variant:t="primary",onClick:o,...n})=>{const i=kt(null);return xt.createElement(ga,{$variant:t},xt.createElement($a,{ref:i,$variant:t,onClick:e=>{o&&o(e),i.current?.blur()},...n},e))},ba=It.div`
|
|
432
|
+
flex: 1;
|
|
433
|
+
align-self: stretch;
|
|
434
|
+
display: flex;
|
|
435
|
+
flex-direction: column;
|
|
436
|
+
gap: 24px;
|
|
437
|
+
padding: 24px;
|
|
438
|
+
`,ya=It.div`
|
|
439
|
+
display: flex;
|
|
440
|
+
flex-direction: row;
|
|
441
|
+
flex-wrap: ${({$wrap:e="unset"})=>e};
|
|
442
|
+
align-items: ${({$alignItems:e="center"})=>e};
|
|
443
|
+
justify-content: ${({$justifyContent:e="unset"})=>e};
|
|
444
|
+
gap: ${({$gap:e=2})=>e}px;
|
|
445
|
+
padding: ${({$padding:e="unset"})=>e};
|
|
446
|
+
`,wa=It.div`
|
|
447
|
+
display: flex;
|
|
448
|
+
flex-direction: column;
|
|
449
|
+
flex-wrap: ${({$wrap:e="unset"})=>e};
|
|
450
|
+
align-items: ${({$alignItems:e="unset"})=>e};
|
|
451
|
+
justify-content: ${({$justifyContent:e="unset"})=>e};
|
|
452
|
+
gap: ${({$gap:e=2})=>e}px;
|
|
453
|
+
padding: ${({$padding:e="unset"})=>e};
|
|
454
|
+
`,ka=It(wa)`
|
|
455
|
+
width: ${({$width:e})=>e||"100%"};
|
|
456
|
+
height: ${({$height:e})=>e||"unset"};
|
|
457
|
+
align-items: center;
|
|
458
|
+
justify-content: center;
|
|
459
|
+
`,va=It.div`
|
|
460
|
+
display: flex;
|
|
461
|
+
flex-direction: column;
|
|
462
|
+
padding: 12px;
|
|
463
|
+
overflow-y: scroll;
|
|
464
|
+
`,Ca=It.div`
|
|
465
|
+
position: fixed;
|
|
466
|
+
top: 0;
|
|
467
|
+
left: 0;
|
|
468
|
+
right: 0;
|
|
469
|
+
bottom: 0;
|
|
470
|
+
z-index: 1000;
|
|
471
|
+
background: rgba(0, 0, 0, 0.5);
|
|
472
|
+
backdrop-filter: blur(1px);
|
|
473
|
+
`,Ea=It.div`
|
|
474
|
+
width: 800px;
|
|
475
|
+
min-height: ${({$minHeight:e})=>e||"unset"};
|
|
476
|
+
height: ${({$isNotModal:e})=>e?"fit-content":"calc(100vh - 350px)"};
|
|
477
|
+
margin: ${({$isNotModal:e})=>e?"64px 0 0 0":"64px 7vw 32px 7vw"};
|
|
478
|
+
padding: 0 2px;
|
|
479
|
+
overflow-y: scroll;
|
|
480
|
+
`,Sa=It(wa)`
|
|
481
|
+
max-width: ${({$maxWidth:e})=>e||"unset"};
|
|
482
|
+
width: 100%;
|
|
483
|
+
`,Aa=It(ya)`
|
|
484
|
+
gap: 16px;
|
|
485
|
+
padding: 16px;
|
|
486
|
+
`,Da=It.div`
|
|
487
|
+
width: 100%;
|
|
488
|
+
max-height: ${({$maxHeight:e})=>e||"unset"};
|
|
489
|
+
overflow-y: auto;
|
|
490
|
+
`,Ta=e=>{function t(){return void 0===e?{}:qo(e)}const[o,n]=yt(t()),[i,a]=yt({}),r=ft(()=>void 0!==e&&JSON.stringify(o)!==JSON.stringify(e),[e,o]);return wt(()=>{void 0!==e&&"{}"===JSON.stringify(o)&&n(t())},[e,o]),{formData:o,formErrors:i,isFormDirty:r,handleFormChange:(e,t,o)=>{if(e){const o=e.toString().split(".");1===o.length?n(o=>({...o,[e]:t})):n(e=>{const n=qo(e);let i=n;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,n})}else o&&n({...o})},handleErrorChange:(e,t,o)=>{e?a(o=>({...o,[e]:t})):o&&a({...o})},resetFormData:()=>{n(t()),a({})}}},Na={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}},Ia=()=>{const{addNotification:e}=ci(),{formData:t,formErrors:o,handleFormChange:n,handleErrorChange:i,resetFormData:a}=Ta(Na);return{formData:t,formErrors:o,handleFormChange:n,resetFormData:a,validateForm:o=>{const n={};let a=!0;return Object.entries(t).forEach(([e,t])=>{switch(e){case"type":case"signals":On(t)&&(n[e]=Zo.FIELD_IS_REQUIRED)}}),a=!Object.values(n).length,!a&&o?.withAlert&&e({type:ho.Warning,title:o.alertTitle,message:Zo.REQUIRED_FIELDS,hideFromHistory:!0}),i(void 0,void 0,n),a},loadFormWithDrawerItem:({type:e,fields:t})=>{const o={...qo(Na),type:e};Object.entries(t).forEach(([e,t])=>{if(t)switch(e){case"actionName":o.name=t;break;case"type":case"notes":case"signals":case"disabled":o[e]=t;break;case Jt.CollectContainerAttributes:case Jt.CollectReplicaSetAttributes:case Jt.CollectWorkloadId:case Jt.CollectClusterId:case Jt.LabelsAttributes:case Jt.AnnotationsAttributes:case Jt.ClusterAttributes:case Jt.OverwriteExistingValues:case Jt.AttributeNamesToDelete:case Jt.Renames:case Jt.PiiCategories:case Jt.FallbackSamplingRatio:case Jt.SamplingPercentage:case Jt.EndpointsFilters:case Jt.ServicesNameFilters:case Jt.AttributeFilters:o.fields||(o.fields={}),o.fields[e]=t}}),n(void 0,void 0,o)}}},za=e=>{wt(()=>{if(e){const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}},[e])},Oa=()=>{const{setCurrentModal:e}=li(),{setDrawerType:t,setDrawerEntityId:o}=ni(),{setActiveNodeType:n,setActiveNodeId:i,activeNodeId:a}=qt();return{onClickNode:(r,s)=>{const{id:l,type:c,data:{id:d,type:p}}=s;switch(a===l?(n(null),i(null)):(n(c),i(l)),p){case lo.Source:case lo.Destination:case lo.Action:case lo.InstrumentationRule:t(p),o(d);break;case yo.AddSource:e(lo.Source);break;case yo.AddDestination:e(lo.Destination);break;case yo.AddAction:e(lo.Action);break;case yo.AddRule:e(lo.InstrumentationRule)}}}},_a=()=>{const{setDrawerType:e,setDrawerEntityId:t}=ni(),{markAsDismissed:o,markAsSeen:n}=ci();return{onClickNotification:(i,a)=>{const{id:r,crdType:s,target:l}=i,{dismissToast:c}=a||{};if(s&&l)switch(s){case lo.InstrumentationRule:e(lo.InstrumentationRule),t(xn(l,lo.InstrumentationRule));break;case lo.Source:case"InstrumentationConfig":case"InstrumentationInstance":e(lo.Source),t(xn(l,lo.Source));break;case lo.Action:e(lo.Action),t(xn(l,lo.Action));break;case lo.Destination:case"Destination":e(lo.Destination),t(xn(l,lo.Destination))}n(r),c&&o(r)}}},Fa=()=>{const{selectedConnection:e}=ui();return{selectedConnection:e,isVm:e?.type===io.Vm}},Ra=()=>{const e=kt(null),[t,o]=yt(0),[n,i]=yt(0);return wt(()=>{const t=()=>{if(e.current){const{width:t,height:n}=e.current.getBoundingClientRect();o(t),i(n)}};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[]),{containerRef:e,containerWidth:t,containerHeight:n}};var La;!function(e){e[e.XS=16]="XS",e[e.S=18]="S",e[e.M=24]="M",e[e.L=32]="L"}(La||(La={}));const Ba=It.div`
|
|
491
|
+
width: ${({$size:e})=>1.5*e}px;
|
|
492
|
+
height: ${({$size:e})=>1.5*e}px;
|
|
493
|
+
border-radius: 100%;
|
|
494
|
+
display: flex;
|
|
495
|
+
align-items: center;
|
|
496
|
+
justify-content: center;
|
|
497
|
+
cursor: pointer;
|
|
498
|
+
&:hover {
|
|
499
|
+
background: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
500
|
+
}
|
|
501
|
+
`,Pa=({icon:e,size:t=La.S,onClick:o})=>xt.createElement("div",null,xt.createElement(Ba,{$size:t,onClick:e=>{o&&(e.stopPropagation(),o(e))}},xt.createElement(e,{size:t}))),Ma=({onDone:e}={})=>{const[t,o]=yt(!1),[n,i]=yt(-1),a=vt(async(n,a)=>{if(!t){if(o(!0),void 0!==a&&i(a),navigator?.clipboard&&navigator.clipboard.writeText)try{await navigator.clipboard.writeText(n)}catch(e){}else{const e=document.createElement("textarea");e.value=n,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:vt(({value:e,size:o})=>{const n=t?Ke:Je;return xt.createElement(Pa,{icon:n,size:o,onClick:()=>a(e)})},[t]),isCopied:t,copiedIndex:n,clickCopy:a}},ja=e=>{const{addNotification:t}=ci(),{formData:o,handleFormChange:n,formErrors:i,handleErrorChange:a,resetFormData:r}=Ta(e);return{formData:o,formErrors:i,handleFormChange:n,resetFormData:r,validateForm:e=>{const n={};let i=!0;return o.name?_n(o.name)?n.name=void 0:(i=!1,n.name=Zo.ILLEGAL_K8S_LABEL):(i=!1,n.name=Zo.FIELD_IS_REQUIRED),!i&&e?.withAlert&&t({type:ho.Warning,title:e.alertTitle,message:Zo.REQUIRED_FIELDS,hideFromHistory:!0}),a(void 0,void 0,n),i},loadFormWithDrawerItem:({name:t})=>{const o={...qo(e),name:t};n(void 0,void 0,o)}}},Ua={type:"",name:"",exportedSignals:{logs:!1,metrics:!1,traces:!1},fields:[],disabled:!1},Wa=e=>{const{supportedSignals:t,preLoadedFields:o}=e||{},{addNotification:n}=ci(),{formData:i,formErrors:a,handleFormChange:r,handleErrorChange:s,resetFormData:l}=Ta(Ua),[c,d]=yt([]),[p,u]=yt([]);return wt(()=>{var e;u(c?(e=c,e.filter(e=>!!e).map(e=>{const{name:t,componentType:o,componentProperties:n,displayName:i,initialValue:a,renderCondition:r}=e;if(o===po.Dropdown){const e=Nn(n,{}),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:a,placeholder:e.placeholder||"Select an option",options:s,renderCondition:r,...e}}return{name:t,componentType:o,title:i,value:a,renderCondition:r,...Nn(n,{})}})).map(e=>{if(o){const t="string"==typeof o?Nn(o,{}):o;if(e.name in t)return{...e,value:t[e.name]}}return e}):[])},[c,o]),wt(()=>{if(p){const e=p.map(e=>({key:e.name,value:e.value}));r("fields",e)}},[p]),wt(()=>{if(t&&0===Wn(i.exportedSignals).length){const{logs:e,metrics:o,traces:n}=t;r("exportedSignals",{logs:e.supported,metrics:o.supported,traces:n.supported})}},[t,i]),{formData:i,formErrors:a,handleFormChange:r,resetFormData:l,validateForm:e=>{const t={};let o=!0;return p.forEach(({name:e,value:n,required:i})=>{i&&!n&&(o=!1,t[e]=Zo.FIELD_IS_REQUIRED)}),!o&&e?.withAlert&&n({type:ho.Warning,title:e.alertTitle,message:Zo.REQUIRED_FIELDS,hideFromHistory:!0}),s(void 0,void 0,t),o},loadFormWithDrawerItem:({destinationType:{type:e},name:t,disabled:o,exportedSignals:n,fields:i})=>{const a={...qo(Ua),type:e,name:t,disabled:o,exportedSignals:n,fields:Object.entries(Nn(i,{})).map(([e,t])=>({key:e,value:t}))};return r(void 0,void 0,a),a},yamlFields:c,setYamlFields:d,dynamicFields:p,setDynamicFields:u}},Va=({items:e,rowHeight:t})=>{const o=kt(null),n=Tt({enabled:e.length>0,horizontal:!1,count:e.length,getScrollElement:()=>o.current,estimateSize:()=>t,overscan:Math.ceil(.05*e.length)});return{overflowRef:o,listHeight:n.getTotalSize(),listItems:n.getVirtualItems()}},Ha={ruleName:"",notes:"",disabled:!1,workloads:null,instrumentationLibraries:null,payloadCollection:{[So.HttpRequest]:null,[So.HttpResponse]:null,[So.DbQuery]:null,[So.Messaging]:null},codeAttributes:{[vo.Column]:null,[vo.FilePath]:null,[vo.Function]:null,[vo.LineNumber]:null,[vo.Namespace]:null,[vo.StackTrace]:null},headersCollection:null,customInstrumentations:{[Eo.Java]:null,[Eo.Golang]:null}},qa=()=>{const{formData:e,formErrors:t,handleFormChange:o,handleErrorChange:n,resetFormData:i}=Ta(Ha);return{formData:e,formErrors:t,handleFormChange:o,resetFormData:i,validateForm:()=>(n(void 0,void 0,{}),!0),loadFormWithDrawerItem:({ruleName:e,notes:t,disabled:n,payloadCollection:i,codeAttributes:a,headersCollection:r,customInstrumentations:s})=>{const l={...qo(Ha),ruleName:e,notes:t,disabled:n};i&&(l.payloadCollection={[So.HttpRequest]:i[So.HttpRequest]?{}:null,[So.HttpResponse]:i[So.HttpResponse]?{}:null,[So.DbQuery]:i[So.DbQuery]?{}:null,[So.Messaging]:i[So.Messaging]?{}:null}),a&&(l.codeAttributes={[vo.Column]:a[vo.Column]||null,[vo.FilePath]:a[vo.FilePath]||null,[vo.Function]:a[vo.Function]||null,[vo.LineNumber]:a[vo.LineNumber]||null,[vo.Namespace]:a[vo.Namespace]||null,[vo.StackTrace]:a[vo.StackTrace]||null}),r&&(l.headersCollection=r),s&&(l.customInstrumentations={[Eo.Java]:s[Eo.Java]||null,[Eo.Golang]:s[Eo.Golang]||null}),o(void 0,void 0,l)}}},Ga=({active:e,key:t,withAltKey:o,withCtrlKey:n,withShiftKey:i,withMetaKey:a},r)=>(wt(()=>{const s=s=>{e&&t===s.key&&(!o||o&&s.altKey)&&(!n||n&&s.ctrlKey)&&(!i||i&&s.shiftKey)&&(!a||a&&s.metaKey)&&(s.preventDefault(),s.stopPropagation(),r(s))};return window.addEventListener("keydown",s),()=>{window.removeEventListener("keydown",s)}},[t,e,o,n,i,a,r]),null),Ka=(e,t)=>{wt(()=>{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])},Ja=({defaultClientHeight:e=0,defaultClientwidth:t=0,onClickOutside:o}={})=>{const n=kt(null),[i,a]=yt(!1),[r,s]=yt({top:0,left:0});return Ka(n,()=>{i&&(a(!1),o?.())}),{popupRef:n,popupOpen:i,setPopupOpen:a,popupPosition:r,handlePosition:(o,i)=>{const{innerWidth:a,innerHeight:r}=window;let l=i,c=o;l>=r/2&&(l+=-(n.current?.clientHeight||e)),c>=a/2&&(c+=-(n.current?.clientWidth||t)),s({top:l,left:c})}}},Ya=()=>({getItemSS:(e,t)=>{const o=sessionStorage.getItem(e);return o?Nn(o,t):t},setItemSS:(e,t)=>{sessionStorage.setItem(e,JSON.stringify(t))},removeItemSS:e=>{sessionStorage.removeItem(e)}}),Xa={otelServiceName:"",currentStreamName:""},Qa=()=>{const{formData:e,formErrors:t,handleFormChange:o,handleErrorChange:n,resetFormData:i}=Ta(Xa);return{formData:e,formErrors:t,handleFormChange:o,resetFormData:i,validateForm:()=>(n(void 0,void 0,{}),!0),loadFormWithDrawerItem:({otelServiceName:e,name:t})=>{const n={...qo(Xa),otelServiceName:e||t||""};o(void 0,void 0,n)}}},Za=(e,t,o)=>{const n="boolean"==typeof o,i=!!e.dataStreamNames?.length||!!e.currentStreamName?.length,a=i&&e.dataStreamNames?.includes(t)||e.currentStreamName===t,r=(n?o:e.selected&&(!i||a))||!1;return{namespace:e.namespace,name:e.name,kind:e.kind,selected:r,numberOfInstances:e.numberOfInstances}},er=(e,t,o)=>({...Za(e,t,o),currentStreamName:t}),tr=(e,t,o)=>{const n="boolean"==typeof o,i=e.dataStreamNames?.includes(t),a=(n?o:e.selected)||!1;return{namespace:e.name,selected:!(!i&&!n)&&a,currentStreamName:t}},or=e=>{const{fetchSingleNamespace:t}=e||{},{namespaces:o}=ii(),{selectedStreamName:n}=oi(),i=kt(!1),{configuredSources:a,configuredFutureApps:r,availableSources:s,setAvailableSources:l,setFetchedAllNamespaces:c}=gi(),[d,p]=yt(s),[u,h]=yt(""),[m,g]=yt(!1),[x,$]=yt([]),[f,b]=yt(""),[y,w]=yt(r),[k,v]=yt(((e,t,o)=>{const n={};return Object.entries(e).forEach(([e,t])=>{n[e]=t.map(e=>er(e,o))}),Object.entries(t).forEach(([e,t])=>{t.forEach(t=>{const i=n[e].findIndex(e=>e.name===t.name&&e.kind===t.kind),a=er(t,o);-1!==i?n[e][i]=a:n[e].push(a)})}),n})(s,a,n)),C=async(e,o)=>{if(t){if(h(e.name),x.includes(e.name))v(t=>({...t,[e.name]:t[e.name].map(e=>({...e,selected:"boolean"==typeof o?o:e.selected,currentStreamName:n}))}));else{const{data:i}=await t({variables:{namespaceName:e.name}}),{name:a,sources:r=[]}=i?.computePlatform?.k8sActualNamespace||{};if(!a)return;const s=r.map(e=>Za(e,n));$(e=>[...e,a]),l({...gi.getState().availableSources,[a]:s}),p(e=>({...e,[a]:s})),v(e=>({...e,[a]:"boolean"!=typeof o&&e[a]?.length?e[a]:r.map(e=>er(e,n,o))}))}h("")}};wt(()=>(i.current=!0,o?.length&&!gi.getState().fetchedAllNamespaces&&(p(e=>{const t={...e};return o.forEach(({name:e})=>t[e]=t[e]||[]),t}),v(e=>{const t={...e};return o.forEach(({name:e})=>t[e]=t[e]||[]),t}),w(e=>{const t={...e};return o.forEach(e=>t[e.name]=t[e.name]||tr(e,n)),t}),(async()=>{for await(const e of o)i.current&&await C(e)})(),i.current&&c(!0)),()=>{i.current=!1}),[o,n]);const[E,S]=yt(""),[A,D]=yt(lo.Source),[T,N]=yt(!1),[I,z]=yt(!1),O=ft(()=>{const e=(e,t)=>!E||A!==t||A===t&&e.toLowerCase().includes(E),t={};return Object.entries(k).filter(([t])=>e(t,lo.Namespace)).forEach(([o,n])=>{const i=n.filter(t=>e(t.name,lo.Source)&&(!T||t.selected)&&(e=>!I||(e.numberOfInstances||0)>0)(t));(!E||E&&i.length)&&(t[o]=i)}),t},[k,E,A,T,I]);return{fetchingNamespace:u,fetchedNamespaces:x,availableSources:d,filteredNamespacesAndSources:O,getApiSourcesPayload:()=>{const e={};return Object.entries(k).forEach(([t,o])=>{o.forEach(o=>{const n=d[t]?.find(e=>e.name===o.name&&e.kind===o.kind);n?.selected!==o.selected&&(e[t]||(e[t]=[]),e[t].push(o))})}),e},getApiFutureAppsPayload:()=>{const e={};return Object.entries(y).forEach(([t,i])=>{const a=o?.find(e=>e.name===t);(i.selected&&!a?.dataStreamNames?.includes(n)||!i.selected&&a?.dataStreamNames?.includes(n))&&(e[t]=i)}),e},selectedNamespace:f,onSelectNamespace:(e,t)=>{const n=o.find(t=>t.name===e);if(n){const o="boolean"==typeof t;b(t=>t!==e||o?e:""),C(n,t),o&&g(!1)}},selectedAllNamespaces:m,onSelectAllNamespaces:e=>{g(e),o.forEach(t=>C(t,e))},selectedSources:k,onSelectSource:(e,t)=>{const o=t||f;if(!o)return;const i=[...k[o]||[]],a=i.findIndex(({name:t,kind:o})=>t===e.name&&o===e.kind);if(-1!==a){const e={...i[a],selected:!i[a].selected,currentStreamName:n};i[a]=e}else i.push({...e,selected:!0,currentStreamName:n});v(e=>({...e,[o]:i})),g(!1)},selectedFutureApps:y,onSelectFutureApps:(e,t)=>{const i=t||f;if(!i)return;const a=o.find(e=>e.name===t);a&&w(t=>({...t,[i]:tr(a,n,e)}))},searchText:E,setSearchText:S,searchBy:A,setSearchBy:D,showSelectedOnly:T,setShowSelectedOnly:N,showRunningOnly:I,setShowRunningOnly:z}};try{Et.addDefaultLocale(Nt)}catch(e){}const nr=()=>{const e=kt(new Et(Nt.locale));return{formatTimeAgo:vt(t=>{let o=new Date;try{o=new Date(t)}catch(e){return""}return e.current.format(o)},[])}},ir=({container:e,animateIn:t,animateOut:o,duration:n=300})=>{const i=It(e)`
|
|
502
|
+
animation-name: ${({$isEntering:e,$isLeaving:n})=>e?t:n?o:"none"};
|
|
503
|
+
animation-duration: ${n}ms;
|
|
504
|
+
animation-fill-mode: forwards;
|
|
505
|
+
`;return vt(({children:e,enter:t,...o})=>{const[a,r]=yt(!1);return wt(()=>{const e=setTimeout(()=>r(t),n+50);return()=>clearTimeout(e)},[t,n]),t||a?xt.createElement(i,{$isEntering:t,$isLeaving:!t&&a,...o},e):null},[])},ar=It.div`
|
|
506
|
+
position: fixed;
|
|
507
|
+
top: 50%;
|
|
508
|
+
left: 50%;
|
|
509
|
+
transform: translate(-50%, -50%);
|
|
510
|
+
z-index: 1000;
|
|
511
|
+
width: fit-content;
|
|
512
|
+
background: ${({theme:e})=>e.colors.translucent_bg};
|
|
513
|
+
border: ${({theme:e})=>`1px solid ${e.colors.border}`};
|
|
514
|
+
border-radius: 40px;
|
|
515
|
+
box-shadow: ${({theme:e})=>{const t=e.colors.primary+Si.opacity.hex["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}`}};
|
|
516
|
+
`,rr=It.div`
|
|
517
|
+
display: flex;
|
|
518
|
+
justify-content: space-between;
|
|
519
|
+
align-items: center;
|
|
520
|
+
height: 80px;
|
|
521
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
522
|
+
padding: 0 24px;
|
|
523
|
+
`,sr=It.div`
|
|
524
|
+
cursor: pointer;
|
|
525
|
+
display: flex;
|
|
526
|
+
align-items: center;
|
|
527
|
+
gap: 8px;
|
|
528
|
+
`,lr=It.div`
|
|
529
|
+
display: flex;
|
|
530
|
+
align-items: center;
|
|
531
|
+
gap: 8px;
|
|
532
|
+
`,cr=It(ka)`
|
|
533
|
+
min-width: 350px;
|
|
534
|
+
min-height: 150px;
|
|
535
|
+
`,dr=It.div`
|
|
536
|
+
position: absolute;
|
|
537
|
+
left: 50%;
|
|
538
|
+
transform: translateX(-50%);
|
|
539
|
+
display: flex;
|
|
540
|
+
align-items: center;
|
|
541
|
+
justify-content: center;
|
|
542
|
+
width: 100%;
|
|
543
|
+
pointer-events: none;
|
|
544
|
+
`,pr=It(Li)`
|
|
545
|
+
text-transform: uppercase;
|
|
546
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
547
|
+
pointer-events: auto;
|
|
548
|
+
`,ur=It(Li)`
|
|
549
|
+
text-transform: uppercase;
|
|
550
|
+
font-weight: 500;
|
|
551
|
+
font-size: 14px;
|
|
552
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
553
|
+
text-decoration: underline;
|
|
554
|
+
cursor: pointer;
|
|
555
|
+
`,hr=({isOpen:e,noOverlay:t,header:o,actionComponent:n,onClose:i,children:a,closeOnEscape:r=!0})=>{Ga({key:"Escape",active:e&&r},()=>i()),za(e);const s=ir({container:ar,animateIn:Si.animations.slide.in.center,animateOut:Si.animations.slide.out.center});return e?Mt.createPortal(xt.createElement(xt.Fragment,null,xt.createElement(Ca,{hidden:!e,onClick:i,style:{opacity:t?0:1}}),xt.createElement(s,{"data-id":"modal"+(o?`-${o.title.replaceAll(" ","-")}`:""),enter:e},o&&xt.createElement(rr,null,xt.createElement(sr,{onClick:i},xt.createElement(Ye,null),xt.createElement(ur,null,"Cancel")),xt.createElement(dr,null,xt.createElement(pr,null,o.title)),xt.createElement(lr,null,n)),xt.createElement(cr,null,a))),document.body):null},mr=It.div`
|
|
556
|
+
width: ${({$orientation:e,$thickness:t,$length:o})=>"vertical"===e?`${t}px`:o||"100%"};
|
|
557
|
+
height: ${({$orientation:e,$thickness:t,$length:o})=>"horizontal"===e?`${t}px`:o||"100%"};
|
|
558
|
+
margin: ${({$orientation:e,$margin:t})=>t||("horizontal"===e?"8px 0":"0 8px")};
|
|
559
|
+
background-color: ${({$type:e,theme:t})=>(e?t.text[e]:t.colors.border)+Si.opacity.hex["050"]};
|
|
560
|
+
opacity: ${({$opacity:e})=>e||1};
|
|
561
|
+
`,gr=({orientation:e="horizontal",type:t,thickness:o=1,length:n,margin:i,opacity:a})=>xt.createElement(mr,{$orientation:e,$type:t,$thickness:o,$length:n,$margin:i,$opacity:a}),xr=It.div`
|
|
562
|
+
position: absolute;
|
|
563
|
+
${({$top:e})=>void 0!==e&&`top: ${e}px;`}
|
|
564
|
+
${({$bottom:e})=>void 0!==e&&`bottom: ${e}px;`}
|
|
565
|
+
${({$left:e})=>void 0!==e&&`left: ${e}px;`}
|
|
566
|
+
${({$right:e})=>void 0!==e&&`right: ${e}px;`}
|
|
567
|
+
z-index: 9999;
|
|
568
|
+
|
|
569
|
+
background-color: ${({theme:e})=>e.colors.info};
|
|
570
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
571
|
+
border-radius: ${({$borderRadius:e})=>void 0!==e?e:"24px"};
|
|
572
|
+
max-width: ${({$maxWidth:e})=>void 0!==e?e:"unset"};
|
|
573
|
+
width: ${({$width:e})=>void 0!==e?e:"unset"};
|
|
574
|
+
|
|
575
|
+
${({$asPortal:e,$withPointerEvents:t})=>e&&!t&&"pointer-events: none;"}
|
|
576
|
+
`,$r=It.div`
|
|
577
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
578
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
579
|
+
`,fr=It.div`
|
|
580
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
581
|
+
`,br=It.div`
|
|
582
|
+
padding: ${({$padding:e})=>void 0!==e?e:"12px"};
|
|
583
|
+
border-top: 1px solid ${({theme:e})=>e.colors.border};
|
|
584
|
+
`,yr=bt(({isOpen:e,asPortal:t,...o},n)=>{const i=ft(()=>{const{children:e,top:i,bottom:a,left:r,right:s,borderRadius:l,padding:c,maxWidth:d,width:p,header:u,footer:h,withPointerEvents:m,...g}=o;return xt.createElement(xr,{ref:n,$top:i,$bottom:a,$left:r,$right:s,$borderRadius:l,$padding:c,$maxWidth:d,$width:p,$asPortal:t,$withPointerEvents:m,...g},u&&xt.createElement($r,{$padding:c},u),xt.createElement(fr,{$padding:c},e),h&&xt.createElement(br,{$padding:c},h))},[n,o,t]);return e?t?Mt.createPortal(i,document.body):i:null});yr.displayName=yr.name;const wr=It.div`
|
|
585
|
+
position: relative;
|
|
586
|
+
display: flex;
|
|
587
|
+
align-items: center;
|
|
588
|
+
gap: 4px;
|
|
589
|
+
// cursor: help;
|
|
590
|
+
`,kr=It(Li)`
|
|
591
|
+
word-break: break-word;
|
|
592
|
+
white-space: pre-wrap;
|
|
593
|
+
`,vr=({withIcon:e,titleIcon:t,title:o,text:n,timestamp:i,children:a})=>{const r=Si.useTheme(),{popupRef:s,popupOpen:l,setPopupOpen:c,popupPosition:d,handlePosition:p}=Ja({defaultClientHeight:40,defaultClientwidth:Math.min(7.5*(n?.length||0),300)}),u=ft(()=>!!_i(n||"")?.length,[n]),h=e=>{const{type:t,clientX:o,clientY:n}=e;u?p(d.left||o,d.top||n):p(o,n),c("mouseleave"!==t)};return n?xt.createElement(wr,{onMouseEnter:h,onMouseMove:h,onMouseLeave:h},a,e&&xt.createElement(qe,{fill:r.v2.colors.silver[200]}),xt.createElement(yr,{ref:s,isOpen:l,top:d.top,left:d.left,asPortal:!0,withPointerEvents:u,onMouseEnter:u?h:void 0,maxWidth:"270px",borderRadius:"16px",padding:"8px 12px"},(!!t||!!o)&&xt.createElement(ya,{style:{marginBottom:"4px"},$gap:4},t&&xt.createElement(t,{size:12,fill:r.text.secondary}),o&&xt.createElement(Li,{size:12,color:r.text.secondary},o)),xt.createElement(kr,{size:12,color:r.text.info},n),!!i&&xt.createElement(Li,{size:10,color:r.text.darker_grey,family:"secondary",style:{marginTop:"8px"}},new Date(i).toLocaleString()))):xt.createElement(xt.Fragment,null,a)},Cr=It.button`
|
|
594
|
+
position: relative;
|
|
595
|
+
width: ${({$size:e})=>e}px;
|
|
596
|
+
height: ${({$size:e})=>e}px;
|
|
597
|
+
border: ${({theme:e,$withBorder:t})=>t?`1px solid ${e.colors.border}`:"none"};
|
|
598
|
+
border-radius: 100%;
|
|
599
|
+
background-color: ${({$backgroundColor:e})=>e||"transparent"};
|
|
600
|
+
display: flex;
|
|
601
|
+
align-items: center;
|
|
602
|
+
justify-content: center;
|
|
603
|
+
cursor: pointer;
|
|
604
|
+
&:hover {
|
|
605
|
+
background-color: ${({theme:e,$backgroundColor:t})=>t?t+Si.opacity.hex["070"]:e.colors.dropdown_bg_2};
|
|
606
|
+
}
|
|
607
|
+
`,Er=It.div`
|
|
608
|
+
position: absolute;
|
|
609
|
+
top: ${({$size:e})=>e/5}px;
|
|
610
|
+
right: ${({$size:e})=>e/5}px;
|
|
611
|
+
width: 6px;
|
|
612
|
+
height: 6px;
|
|
613
|
+
border-radius: 100%;
|
|
614
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.secondary};
|
|
615
|
+
|
|
616
|
+
&::after {
|
|
617
|
+
content: '';
|
|
618
|
+
position: absolute;
|
|
619
|
+
inset: 0;
|
|
620
|
+
border-radius: 100%;
|
|
621
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.secondary};
|
|
622
|
+
animation: ${Si.animations.ping} 1.5s cubic-bezier(0, 0, 0.2, 1) infinite;
|
|
623
|
+
}
|
|
624
|
+
`,Sr=({children:e,onClick:t,tooltip:o,size:n=36,withPing:i,pingColor:a,withBorder:r,backgroundColor:s,...l})=>xt.createElement(vr,{text:o},xt.createElement(Cr,{$size:n,$withBorder:r,$backgroundColor:s,onClick:t,...l},i&&xt.createElement(Er,{$size:n,$color:a}),e)),Ar=It.div`
|
|
625
|
+
position: relative;
|
|
626
|
+
&.animated {
|
|
627
|
+
overflow: hidden;
|
|
628
|
+
padding-bottom: 1px;
|
|
629
|
+
border-radius: 32px;
|
|
630
|
+
animation: ${({$isLeaving:e})=>e?Si.animations.slide.out.bottom:Si.animations.slide.in.bottom} ${({$duration:e})=>e/10}ms forwards;
|
|
631
|
+
}
|
|
632
|
+
`,Dr=It.div`
|
|
633
|
+
position: absolute;
|
|
634
|
+
bottom: -1px;
|
|
635
|
+
left: 0;
|
|
636
|
+
z-index: -1;
|
|
637
|
+
width: 100%;
|
|
638
|
+
height: 100%;
|
|
639
|
+
border-radius: 32px;
|
|
640
|
+
background-color: ${({$type:e,theme:t})=>t.text[e]};
|
|
641
|
+
animation: ${Si.animations.progress.out} ${({$duration:e})=>""+(e-e/10)}ms forwards;
|
|
642
|
+
`,Tr=It.div`
|
|
643
|
+
display: flex;
|
|
644
|
+
align-items: center;
|
|
645
|
+
flex: 1;
|
|
646
|
+
gap: 8px;
|
|
647
|
+
padding: 0 12px;
|
|
648
|
+
border-radius: 32px;
|
|
649
|
+
background-color: ${({$type:e,theme:t})=>t.colors[e]};
|
|
650
|
+
`,Nr=It.div`
|
|
651
|
+
display: flex;
|
|
652
|
+
align-items: center;
|
|
653
|
+
margin: 0 auto 0 0;
|
|
654
|
+
padding: 8px 0;
|
|
655
|
+
max-width: ${({$withAction:e,$overrideMaxWidth:t})=>t||(e?"400px":"500px")};
|
|
656
|
+
min-height: 12px;
|
|
657
|
+
`,Ir=It(Li)`
|
|
658
|
+
font-size: 14px;
|
|
659
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
660
|
+
`,zr=It(Li)`
|
|
661
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
662
|
+
font-size: 12px;
|
|
663
|
+
`,Or=It(ya)``,_r=It(Li)`
|
|
664
|
+
text-transform: uppercase;
|
|
665
|
+
text-decoration: underline;
|
|
666
|
+
font-size: 12px;
|
|
667
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
668
|
+
white-space: nowrap;
|
|
669
|
+
cursor: pointer;
|
|
670
|
+
&:hover {
|
|
671
|
+
transform: scale(1.1);
|
|
672
|
+
transition: transform 0.3s;
|
|
673
|
+
}
|
|
674
|
+
`,Fr=({type:e,icon:t,title:o,message:n,action:i,onClose:a,duration:r=5e3,overrideMaxWidth:s,style:l})=>{const c=Si.useTheme(),[d,p]=yt(!1),u=kt(null),h=kt(null),m=e=>{a&&(p(!0),a({asSeen:e?.asSeen}))};wt(()=>(u.current=setTimeout(()=>m({asSeen:!1}),r),()=>{u.current&&clearTimeout(u.current)}),[r]);const g=t||Sn(e,c);return xt.createElement(Ar,{className:a?"animated":"",$duration:r,$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*r;u.current=setTimeout(()=>m({asSeen:!1}),e),h.current.style.animationPlayState="running"}}},xt.createElement(Tr,{"data-id":"toast",$type:e,style:l},xt.createElement(g,{fill:c.text[e]}),xt.createElement(Nr,{$withAction:!!i,$overrideMaxWidth:s},o&&xt.createElement(Ir,{$type:e},o),o&&n&&xt.createElement(gr,{orientation:"vertical",type:e}),n&&xt.createElement(zr,{$type:e},n)),(!!i||!!a)&&xt.createElement(Or,null,i&&xt.createElement(_r,{"data-id":"toast-action",onClick:i.onClick},i.label),a&&xt.createElement(Sr,{"data-id":"toast-close",onClick:()=>m({asSeen:!0})},xt.createElement(Ye,{size:12})))),a&&xt.createElement(Dr,{ref:h,$duration:r,$type:e}))},Rr=It.div`
|
|
675
|
+
padding: 24px 32px;
|
|
676
|
+
`,Lr=It.div`
|
|
677
|
+
padding: ${({$withNote:e})=>e?"12px 0px":"12px 0px 32px 0"};
|
|
678
|
+
`,Br=It(Li)`
|
|
679
|
+
font-size: 20px;
|
|
680
|
+
line-height: 28px;
|
|
681
|
+
`,Pr=It(Li)`
|
|
682
|
+
color: ${({theme:e})=>e.text.grey};
|
|
683
|
+
width: 416px;
|
|
684
|
+
font-style: normal;
|
|
685
|
+
font-weight: 300;
|
|
686
|
+
line-height: 24px;
|
|
687
|
+
`,Mr=It.div`
|
|
688
|
+
display: flex;
|
|
689
|
+
justify-content: space-between;
|
|
690
|
+
gap: 12px;
|
|
691
|
+
`,jr=It(fa)`
|
|
692
|
+
width: 250px;
|
|
693
|
+
`,Ur=It.div`
|
|
694
|
+
margin-bottom: 12px;
|
|
695
|
+
`,Wr=({isOpen:e,noOverlay:t,title:o="",description:n="",note:i,approveButton:a,denyButton:r,closeOnEscape:s=!0})=>{Ga({key:"Enter",active:e&&s},()=>a.onClick());const l=()=>r.onClick();return xt.createElement(hr,{isOpen:e,noOverlay:t,onClose:l},xt.createElement(Rr,null,xt.createElement(Br,null,o),xt.createElement(Lr,{$withNote:!!i},xt.createElement(Pr,null,n)),!!i&&xt.createElement(Ur,null,xt.createElement(Fr,{type:i.type,title:i.title,message:i.message})),xt.createElement(Mr,null,xt.createElement(jr,{"data-id":"approve",variant:a.variant||"primary",onClick:()=>a.onClick()},a.text),xt.createElement(jr,{"data-id":"deny",variant:r.variant||"secondary",onClick:l},r.text))))},Vr=({isOpen:e,noOverlay:t,name:o,onApprove:n,onDeny:i})=>xt.createElement(Wr,{isOpen:e,noOverlay:t,title:"Cancel"+(o?` ${o}`:""),description:"Are you sure you want to cancel?",approveButton:{text:"Confirm",variant:ho.Warning,onClick:n},denyButton:{text:"Go Back",onClick:i}}),Hr=It.div`
|
|
696
|
+
display: flex;
|
|
697
|
+
align-items: center;
|
|
698
|
+
gap: 8px;
|
|
699
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
700
|
+
opacity: ${({$disabled:e})=>e?.6:1};
|
|
701
|
+
`,qr=It.div`
|
|
702
|
+
width: 18px;
|
|
703
|
+
height: 18px;
|
|
704
|
+
border-radius: 6px;
|
|
705
|
+
border: 1px dashed ${({$isChecked:e,$isPartiallyChecked:t,theme:o})=>e||t?"transparent":o.colors.secondary};
|
|
706
|
+
display: flex;
|
|
707
|
+
align-items: center;
|
|
708
|
+
justify-content: center;
|
|
709
|
+
background-color: ${({$isChecked:e,$isPartiallyChecked:t,theme:o})=>e?o.colors.majestic_blue:t?o.colors.majestic_blue_soft:o.colors.secondary+Si.opacity.hex["020"]};
|
|
710
|
+
pointer-events: ${({$disabled:e})=>e?"none":"auto"};
|
|
711
|
+
transition: border 0.3s;
|
|
712
|
+
&:hover {
|
|
713
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
714
|
+
}
|
|
715
|
+
`,Gr=({title:e,titleColor:t,tooltip:o,value:n=!1,partiallyChecked:i=!1,onChange:a,disabled:r,style:s,errorMessage:l,allowPropagation:c=!1})=>{const d=Si.useTheme(),[p,u]=yt(n);return wt(()=>u(n),[n]),xt.createElement(wa,null,xt.createElement(Hr,{"data-id":"checkbox"+(e?`-${e}`:""),$disabled:r,onClick:e=>{r||(c||e.stopPropagation(),a?a(!!i||!p):u(e=>!!i||!e))},style:s},xt.createElement(qr,{$isChecked:p,$isPartiallyChecked:i,$disabled:r},i?xt.createElement(Xe,{fill:d.text.white}):p?xt.createElement(Ke,{fill:d.text.white}):null),e&&xt.createElement(vr,{text:o,withIcon:!0},xt.createElement(Li,{size:12,color:t||d.text.grey,style:{maxWidth:"90%"}},e))),!!l&&xt.createElement(Xi,null,l))},Kr=It(ya)`
|
|
716
|
+
gap: 0;
|
|
717
|
+
`,Jr=It.button`
|
|
718
|
+
padding: 4px 8px;
|
|
719
|
+
background-color: ${({theme:e,$selected:t})=>t?e.colors.dropdown_bg_2:"transparent"};
|
|
720
|
+
border-radius: ${({$position:e})=>"left"===e?"32px 0px 0px 32px":"right"===e?"0px 32px 32px 0px":"0"};
|
|
721
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
722
|
+
display: flex;
|
|
723
|
+
align-items: center;
|
|
724
|
+
justify-content: center;
|
|
725
|
+
cursor: pointer;
|
|
726
|
+
&:hover {
|
|
727
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
728
|
+
}
|
|
729
|
+
`,Yr=({isPrettyMode:e,setIsPrettyMode:t})=>xt.createElement(Kr,null,xt.createElement(Jr,{$position:"left",$selected:e,onClick:()=>t(!0)},xt.createElement(Qe,null)),xt.createElement(Jr,{$position:"right",$selected:!e,onClick:()=>t(!1)},xt.createElement(Ze,null))),Xr=It.table`
|
|
730
|
+
border-collapse: collapse;
|
|
731
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
732
|
+
`,Qr=It.tbody``,Zr=It.tr`
|
|
733
|
+
td:first-child {
|
|
734
|
+
padding-left: 0 !important;
|
|
735
|
+
}
|
|
736
|
+
td:last-child {
|
|
737
|
+
padding-right: 0 !important;
|
|
738
|
+
}
|
|
739
|
+
`,es=It.td`
|
|
740
|
+
vertical-align: top;
|
|
741
|
+
padding: 4px 6px;
|
|
742
|
+
`,ts=It(Li)`
|
|
743
|
+
white-space: nowrap;
|
|
744
|
+
`,os=It.span`
|
|
745
|
+
white-space: ${({$noWrap:e})=>e?"nowrap":"pre-wrap"};
|
|
746
|
+
overflow-wrap: break-word;
|
|
747
|
+
word-break: break-word;
|
|
748
|
+
word-wrap: break-word;
|
|
749
|
+
/* Fallback for older browsers */
|
|
750
|
+
-ms-word-break: break-all;
|
|
751
|
+
font-size: 12px;
|
|
752
|
+
`,ns=({language:e,code:t,theme:o,flatten:n,pretty:i})=>{const{darkMode:a}=Si.useTheme(),r=o?Wt[o]:a?Wt.palenight:Wt.vsLight;let s="";if("json"===e){const e=Nn(t,{}),o=Gn(e);s=Kn(n?nn(o):o)}else s=t;return i&&"json"===e?xt.createElement(is,{darkMode:a,str:s}):xt.createElement(Ut,{theme:r||(a?Wt.palenight:Wt.vsLight),language:e,code:s},({getLineProps:e,getTokenProps:t,tokens:o})=>xt.createElement("pre",null,o.map((o,n)=>xt.createElement("div",{key:`line-${n}`,...e({line:o})},o.map((e,o)=>xt.createElement(os,{key:`line-${n}-token-${o}`,...t({token:e})}))))))},is=({darkMode:e,str:t})=>{const o=Si.useTheme();return xt.createElement(Ut,{theme:e?Wt.palenight:Wt.vsLight,language:"json",code:t},({getLineProps:e,getTokenProps:t,tokens:n})=>xt.createElement(Xr,null,xt.createElement(Qr,null,n.map((n,i)=>{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],n=["property","string"].includes(o[0])?t.replace(/"/g,""):t;return"string"===o[0]&&(["true","false"].includes(n.split("@")[0])&&(o[0]="boolean"),n.split("@")[0].match(/^[0-9]+$/)&&(o[0]="number")),{types:o,content:n}})})(n),r=e({line:a});return 1===a.length&&"property"===a[0].types[0]?xt.createElement($t,{key:`line-${i}`},((e,t)=>{const n=new Array(2).fill(e=>xt.createElement(Zr,{...e},xt.createElement(es,null),xt.createElement(es,null)));return xt.createElement($t,null,n.map((e,n)=>xt.createElement(e,{key:`empty-row-${t}-${n}`,style:0===n?{borderBottom:`1px solid ${o.colors.border}`}:{}})))})(0,i),xt.createElement(Zr,{...r},xt.createElement(es,null,xt.createElement(ts,null,a[0].content)),xt.createElement(es,null))):2===a.length?xt.createElement(Zr,{key:`line-${i}`,...r},a.map((e,n)=>{const{text:a,components:r}=((e,t)=>{const[o,...n]=e.split("@");return{text:o,components:n?.map((e,o)=>{if(!e.includes("="))return null;const[n,i]=e.split("=");switch(n){case"tooltip":return xt.createElement(vr,{key:`${n}-${i}-${o}`,withIcon:!0,text:i});case"status":if("none"===i)return xt.createElement("div",{key:`${n}-${i}-${o}`,style:{width:16,height:16}});let e=Sn(i,t);return e||(e=Sn(ho.Warning,t)),xt.createElement(e,{key:`${n}-${i}-${o}`});default:return null}})?.filter(e=>!!e)||[]}})(e.content,o),s=0===n;return xt.createElement(es,{key:`line-${i}-token-${n}`},xt.createElement(ya,null,xt.createElement(ya,null,r),xt.createElement(os,{$noWrap:s,...t({token:e})},a)))})):(a.length,null)}))))},as={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 rs(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 n=(e.match(/[^0-9]*$/)||"").toString();return as[n]?{value:t,unit:n}:{value:t,unit:"px"}}function ss(e){const t=rs(e);return`${t.value}${t.unit}`}const ls=(()=>{const e="react-spinners-FadeLoader-fade";if("undefined"==typeof window||!window.document)return e;const t=document.createElement("style");document.head.appendChild(t);const o=t.sheet,n=`\n @keyframes ${e} {\n 50% {opacity: 0.3} 100% {opacity: 1}\n }\n `;return o&&o.insertRule(n,0),e})(),cs=({loading:e=!0,color:t,scale:o=1,speedMultiplier:n=1,cssOverride:i={},style:a={},...r})=>{const s=Si.useTheme(),l=t||s.text.secondary;if(!e)return null;const{value:c}=rs(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,...a,...i},m=(e,t)=>({position:"absolute",width:ss(1.5),height:ss(4),borderRadius:ss(2),backgroundColor:l,transition:"2s",animationFillMode:"both",animation:`${ls} ${1.2/n}s ${.12*e}s infinite ease-in-out`,transform:`translate(-50%, -50%) rotate(${t}deg)`});return xt.createElement("span",{style:h,...r},xt.createElement("span",{style:{...m(1,0),top:`calc(50% + ${d}px)`,left:"50%"}}),xt.createElement("span",{style:{...m(2,-45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${p}px)`}}),xt.createElement("span",{style:{...m(3,90),top:"50%",left:`calc(50% + ${d}px)`}}),xt.createElement("span",{style:{...m(4,45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${p}px)`}}),xt.createElement("span",{style:{...m(5,0),top:`calc(50% + ${-1*d}px)`,left:"50%"}}),xt.createElement("span",{style:{...m(6,-45),top:`calc(50% + ${-1*p}px)`,left:`calc(50% + ${-1*p}px)`}}),xt.createElement("span",{style:{...m(7,90),top:"50%",left:`calc(50% + ${-1*d}px)`}}),xt.createElement("span",{style:{...m(8,45),top:`calc(50% + ${p}px)`,left:`calc(50% + ${-1*p}px)`}}))},ds=It.div`
|
|
753
|
+
margin: ${({$align:e})=>"right"===e?"auto 6px auto auto":"left"===e?"auto auto auto 6px":"auto"};
|
|
754
|
+
display: flex;
|
|
755
|
+
align-items: center;
|
|
756
|
+
justify-content: center;
|
|
757
|
+
`,ps=({extend:e,size:t=14,align:o="center"})=>xt.createElement(ds,{$align:o},xt.createElement(et,{size:t,rotate:e?180:0})),us=It.div`
|
|
758
|
+
border-radius: 24px;
|
|
759
|
+
background-color: ${({theme:e,$status:t})=>t===ho.Error?e.text.error+Si.opacity.hex["010"]:t===ho.Warning?e.text.warning+Si.opacity.hex["010"]:e.colors.secondary+Si.opacity.hex["005"]};
|
|
760
|
+
&:hover {
|
|
761
|
+
background-color: ${({theme:e,$status:t})=>t===ho.Error?e.text.error+Si.opacity.hex["020"]:t===ho.Warning?e.text.warning+Si.opacity.hex["020"]:e.colors.secondary+Si.opacity.hex["010"]};
|
|
762
|
+
}
|
|
763
|
+
cursor: pointer;
|
|
764
|
+
transition: background 0.3s;
|
|
765
|
+
`,hs=It.div`
|
|
766
|
+
display: flex;
|
|
767
|
+
align-items: center;
|
|
768
|
+
gap: 12px;
|
|
769
|
+
padding: 12px 18px;
|
|
770
|
+
`,ms=It.div`
|
|
771
|
+
display: flex;
|
|
772
|
+
flex-direction: column;
|
|
773
|
+
gap: 8px;
|
|
774
|
+
padding: 6px 18px 12px 18px;
|
|
775
|
+
`,gs=It.div`
|
|
776
|
+
display: flex;
|
|
777
|
+
align-items: center;
|
|
778
|
+
gap: 12px;
|
|
779
|
+
`,xs=It(Li)`
|
|
780
|
+
white-space: nowrap;
|
|
781
|
+
`,$s=It(wa)`
|
|
782
|
+
width: 16px;
|
|
783
|
+
`,fs=({conditions:e,headerLabelError:t="Something Failed",headerLabelWarning:o="Something isn't right",headerLabelSuccess:n="Everything Successful"})=>{const i=Si.useTheme(),[a,r]=yt(!1),s=ft(()=>jn(e),[e]),{errors:l,hasErrors:c,warnings:d,hasWarnings:p,hasDisableds:u,hasLoadings:h}=ft(()=>ln(s),[s]);wt(()=>{r(c||p||u||h)},[c,p,u,h]);const m=(!s.length||h)&&!c&&!p&&!u,g=c?ho.Error:p?ho.Warning:u?ho.Info:ho.Success,x=Sn(g,i),$=c?t:p||u?o:m?"Loading...":n,f=c?i.text.error:p?i.text.warning:i.text.info,b=`(${c?l.length:p?d.length:s.length}/${s.length})`,y=c?i.text.error_secondary:p?i.text.warning_secondary:i.text.info_secondary,w=vt(()=>r(e=>!e),[]);return xt.createElement(us,{onClick:w,$status:g},xt.createElement(hs,null,m?xt.createElement(cs,null):xt.createElement(x,null),xt.createElement(Li,{color:f,size:14},$),xt.createElement(Li,{color:y,size:12,family:"secondary"},b),xt.createElement(ps,{extend:a,align:"right"})),a&&xt.createElement(ms,null,s.map(({status:e,type:t,reason:o,message:n,lastTransitionTime:a},r)=>{const s=e===go.Loading?()=>xt.createElement(cs,{scale:.8}):e===go.Disabled?Sn(ho.Info,i):Sn(e,i),l=e===go.Disabled?i.text.info:e===ho.Error?i.text.error:e===ho.Warning?i.text.warning:i.text.info,c=e===go.Disabled?i.text.info_secondary:e===ho.Error?i.text.error_secondary:e===ho.Warning?i.text.warning_secondary:i.text.info_secondary;return xt.createElement(gs,{key:`condition-${r}`},xt.createElement($s,null,xt.createElement(s,null)),xt.createElement(ya,{$gap:12,style:{width:"100%",justifyContent:"space-between"}},xt.createElement(Li,{color:l,size:12},xt.createElement(xs,{color:c,size:12,weight:700},t),n||o),xt.createElement(xs,{color:l,size:12},new Date(a).toLocaleString())))})))},bs=It.div`
|
|
784
|
+
display: flex;
|
|
785
|
+
align-items: center;
|
|
786
|
+
gap: ${({$size:e})=>e/3}px;
|
|
787
|
+
padding: ${({$size:e,$withBorder:t,$withBackground:o})=>t||o?`${e/(t?3:2)}px ${e/(t?1.5:1)}px`:"0"};
|
|
788
|
+
width: ${({$width:e})=>e||"fit-content"};
|
|
789
|
+
border-radius: 360px;
|
|
790
|
+
border: ${({$withBorder:e,$status:t,theme:o})=>e?`1px solid ${o.text[t]+Si.opacity.hex["050"]}`:"none"};
|
|
791
|
+
background: ${({$withBackground:e,$status:t,theme:o})=>e?`linear-gradient(90deg, transparent 0%, ${o.text[t]+Si.opacity.hex["030"]} 100%)`:"transparent"};
|
|
792
|
+
`,ys=It.div`
|
|
793
|
+
display: flex;
|
|
794
|
+
align-items: center;
|
|
795
|
+
`,ws=It.div`
|
|
796
|
+
display: flex;
|
|
797
|
+
align-items: center;
|
|
798
|
+
`,ks=({title:e,subtitle:t,status:o=ho.Default,forceIcon:n,withIcon:i,withBorder:a,withBackground:r,width:s,size:l=12,family:c="secondary",nowrap:d=!1})=>{const p=Si.useTheme(),u=[go.Loading,go.Disabled].includes(o)?ho.Info:o,h=n?()=>xt.createElement(n,{size:l+2,fill:p.text[u]}):o===go.Loading?()=>xt.createElement(cs,{scale:.8}):()=>Sn(u,p)?.({size:l+2});return xt.createElement(bs,{$status:u,$width:s,$size:l,$withIcon:i,$withBorder:a,$withBackground:r},i&&xt.createElement(ys,null,xt.createElement(h,null)),(!!e||!!t)&&xt.createElement(ws,null,!!e&&xt.createElement(Li,{size:l,family:c,color:p.text[u],nowrap:d},e),!!e&&!!t&&xt.createElement(gr,{orientation:"vertical",length:l-2+"px",type:u}),!!t&&xt.createElement(Li,{size:l-2,family:c,color:p.text[`${u}_secondary`],nowrap:d},t)))},vs=({label:e,onClick:t,variant:o="tertiary",textProps:n,...i})=>{const a=_t();return xt.createElement(fa,{onClick:t,variant:o,...i},xt.createElement(tt,{fill:"primary"===o?a.text.primary:a.text.info}),xt.createElement(Li,{size:14,family:"secondary",decoration:"underline",color:"primary"===o?a.text.primary:void 0,...n},e||tn.ADD))},Cs=It(ya)`
|
|
799
|
+
width: 100%;
|
|
800
|
+
border-radius: 8px;
|
|
801
|
+
background-color: ${({theme:e})=>e.colors.secondary+Si.opacity.hex["010"]};
|
|
802
|
+
pre {
|
|
803
|
+
color: ${({theme:e})=>e.text.default};
|
|
804
|
+
font-size: 12px;
|
|
805
|
+
overflow-x: auto;
|
|
806
|
+
width: 100%;
|
|
807
|
+
padding-left: 12px;
|
|
808
|
+
}
|
|
809
|
+
`,Es=({value:e,callbackCopyDone:t})=>{const{clickCopy:o,isCopied:n}=Ma();return xt.createElement(Cs,null,xt.createElement("pre",null,e),xt.createElement(Sr,{onClick:n=>{n.stopPropagation(),o(e),t?.()},tooltip:n?"Copied!":"Copy"},n?xt.createElement(Ke,null):xt.createElement(Je,null)))},Ss=({label:e,onClick:t,variant:o="tertiary",...n})=>{const i=_t();return xt.createElement(fa,{onClick:t,variant:o,...n},xt.createElement(ot,{fill:"primary"===o?i.text.primary:i.text.info}),xt.createElement(Li,{size:14,family:"secondary",decoration:"underline",color:"primary"===o?i.text.primary:void 0},e||tn.EDIT))},As=({onClick:e})=>xt.createElement(Fr,{type:ho.Default,icon:je,message:en.QUICK_BACK_TO_SUMMARY,action:{label:en.GO_TO_SUMMARY,onClick:e}}),Ds=It(Li)`
|
|
810
|
+
max-width: ${({$maxWidth:e})=>e?`${e}px`:"unset"};
|
|
811
|
+
white-space: nowrap;
|
|
812
|
+
overflow-x: auto;
|
|
813
|
+
|
|
814
|
+
&::after {
|
|
815
|
+
// This is to prevent the "browser default tooltip" from appearing when the title is too long
|
|
816
|
+
content: '';
|
|
817
|
+
display: block;
|
|
818
|
+
}
|
|
819
|
+
`,Ts=({maxWidth:e,text:t,textSize:o=16,textColor:n})=>{const[i,a]=yt(!1),r=kt(null);return wt(()=>{if(r.current){const{clientWidth:t}=r.current;a(t<1.05*(e-o)&&t>.95*(e-o))}},[e,o,t]),xt.createElement(ya,{$gap:0},t&&xt.createElement(vr,{text:i?t:void 0},xt.createElement(Ds,{ref:r,$maxWidth:e-o,size:o,color:n},t)),i&&xt.createElement(Ds,{$maxWidth:o,size:o,color:n},"..."))},Ns=({src:e="",alt:t="",size:n=16})=>{const[i,a]=yt(!1);return e&&!i?xt.createElement("img",{src:e,alt:t,width:n,height:n,onError:()=>a(!0)}):xt.createElement(o,{size:n})},Is=It.div`
|
|
820
|
+
display: flex;
|
|
821
|
+
align-items: center;
|
|
822
|
+
justify-content: center;
|
|
823
|
+
width: ${({$size:e})=>e}px;
|
|
824
|
+
height: ${({$size:e})=>e}px;
|
|
825
|
+
border-radius: 8px;
|
|
826
|
+
background: ${({$status:e,theme:t})=>{const o=t.colors[e||"dropdown_bg_2"];return`linear-gradient(180deg, ${o} 0%, ${o+Si.opacity.hex["030"]} 100%)`}};
|
|
827
|
+
`,zs=({icon:e,src:t="",alt:n="",status:i,size:a=36})=>xt.createElement(Is,{$status:i,$size:a},t?xt.createElement(Ns,{src:t,alt:n,size:a-12}):e?xt.createElement(e,{size:a-12}):xt.createElement(o,{size:a-12})),Os=It.div`
|
|
828
|
+
position: relative;
|
|
829
|
+
display: flex;
|
|
830
|
+
flex-wrap: wrap;
|
|
831
|
+
align-items: center;
|
|
832
|
+
justify-content: center;
|
|
833
|
+
width: ${({$size:e})=>e}px;
|
|
834
|
+
height: ${({$size:e})=>e}px;
|
|
835
|
+
`,_s=It.div`
|
|
836
|
+
position: absolute;
|
|
837
|
+
top: ${({$top:e})=>e}px;
|
|
838
|
+
left: ${({$left:e})=>e}px;
|
|
839
|
+
z-index: ${({$zIndex:e})=>e};
|
|
840
|
+
display: flex;
|
|
841
|
+
align-items: center;
|
|
842
|
+
justify-content: center;
|
|
843
|
+
width: ${({$size:e})=>e}px;
|
|
844
|
+
height: ${({$size:e})=>e}px;
|
|
845
|
+
border-radius: 100%;
|
|
846
|
+
border: 1px solid ${({theme:e,$status:t})=>(t?e.text[t]:e.colors.border)+Si.opacity.hex["030"]};
|
|
847
|
+
background: ${({$status:e,theme:t})=>{const o=t.colors[e||"dropdown_bg_2"];return`linear-gradient(180deg, ${o} 0%, ${o+Si.opacity.hex["030"]} 100%)`}};
|
|
848
|
+
`,Fs=({icons:e=[],iconSrcs:t=[],status:o,size:n=36,id:i})=>{const a=Si.useTheme(),r=1===e.length||1===t.length?n-12:n/2.7;if(t.length>0)return xt.createElement(Fs,{icons:t.map(e=>()=>xt.createElement(Ns,{src:e,size:r})),status:o,size:n,id:i});if(1===e.length)return xt.createElement(zs,{icon:e[0],status:o,size:n});const s=t=>e.length<=2?.5*r:0===t||1===t?0:1.15*r,l=e=>0===e?0:1===e?1.15*r:1.15*r*.5;return xt.createElement(Os,{$status:o,$size:n},e.map((t,n)=>n>2?null:xt.createElement(_s,{key:`icon-${i}-${n}`,$status:o,$size:1.5*r,$top:s(n),$left:l(n),$zIndex:n+1},2===n&&e.length>3?xt.createElement(Li,{family:"secondary",color:a.text.dark_grey,size:.8*r},"+",e.length-2):xt.createElement(t,{size:r}))))},Rs=jo.map(({id:e})=>e),Ls=({monitors:e=Rs,withTooltips:t,withLabels:o,size:n=12,color:i})=>{const a=Si.useTheme(),r=i||a.text.grey;return xt.createElement(ya,{$gap:o?n:n/2},e.filter(e=>!!e).map(e=>{const i=e.toLowerCase(),a=Uo(i),s=bn(i);return s?xt.createElement(vr,{key:i,text:t?a:""},xt.createElement(ya,{$gap:n/3},xt.createElement(s,{size:o?n+2:n,fill:r}),o&&xt.createElement(Li,{size:n,color:r},a))):null}))},Bs=It.div`
|
|
849
|
+
visibility: hidden;
|
|
850
|
+
`,Ps=It.div`
|
|
851
|
+
display: flex;
|
|
852
|
+
flex-direction: column;
|
|
853
|
+
align-self: stretch;
|
|
854
|
+
padding: 16px;
|
|
855
|
+
width: calc(100% - 32px);
|
|
856
|
+
border-radius: 16px;
|
|
857
|
+
background-color: ${({theme:e,$status:t,$bgColor:o})=>o||(t?e.text[t]+Si.opacity.hex["010"]:e.colors.secondary+Si.opacity.hex["005"])};
|
|
858
|
+
opacity: ${({$faded:e})=>e?.5:1};
|
|
859
|
+
|
|
860
|
+
${({theme:e,$status:t,$bgColorHover:o,$withClick:n})=>n?Ft`
|
|
861
|
+
&:hover {
|
|
862
|
+
cursor: pointer;
|
|
863
|
+
background-color: ${o||(t?e.text[t]+Si.opacity.hex["020"]:e.colors.secondary+Si.opacity.hex["010"])};
|
|
864
|
+
${Bs} {
|
|
865
|
+
visibility: visible;
|
|
866
|
+
}
|
|
867
|
+
}
|
|
868
|
+
`:`\n &:hover {\n ${Bs} {\n visibility: visible;\n }\n }\n `}
|
|
869
|
+
`,Ms=It.div`
|
|
870
|
+
display: flex;
|
|
871
|
+
align-items: center;
|
|
872
|
+
gap: 8px;
|
|
873
|
+
margin-left: auto;
|
|
874
|
+
`,js=It(Li)`
|
|
875
|
+
margin-right: 16px;
|
|
876
|
+
`,Us=It(Li)`
|
|
877
|
+
font-size: 10px;
|
|
878
|
+
color: ${({theme:e})=>e.text.grey};
|
|
879
|
+
`,Ws=({title:e,subTitle:t,hoverText:o,onClick:n,renderActions:i,iconProps:{icon:a,icons:r,iconSrc:s,iconSrcs:l}={},visualProps:{status:c,faded:d,bgColor:p,bgColorHover:u,monitors:h,monitorsWithLabels:m,componentsUnderTitles:g}={},checkboxProps:{withCheckbox:x,isCheckboxDisabled:$,isChecked:f,isLoading:b,onCheckboxChange:y}={},extendableProps:{withExtend:w,isExtended:k,renderExtended:v}={},...C})=>{const E=Si.useTheme(),[S,A]=yt(k||!1),[D,T]=yt(0),N=kt(null),I=kt(null),z=kt(null);return wt(()=>{if(N.current){const e=N.current.clientWidth,t=I.current?.clientWidth||0;T(e-((x?125:85)+t))}},[x]),xt.createElement(Ps,{ref:N,$status:c,$faded:d,$bgColor:p,$bgColorHover:u,$withClick:!!n,onClick:n,...C},xt.createElement(ya,{$gap:8},xt.createElement(ya,{$gap:16},b?xt.createElement(cs,null):x?xt.createElement(Gr,{value:f,onChange:y,disabled:$}):null,r?.length||l?.length?xt.createElement(Fs,{icons:r,iconSrcs:l,status:c,id:`${e}-${t}`}):a||s?xt.createElement(zs,{icon:a,src:s,status:c}):null),xt.createElement(wa,{$gap:4},e&&xt.createElement(Ts,{maxWidth:D,text:e,textSize:14}),xt.createElement(ya,{$gap:4},t&&xt.createElement(Ts,{maxWidth:D-(z.current?.clientWidth||0),text:t,textSize:10,textColor:E.text.grey}),h&&h.length>0&&xt.createElement(ya,{$gap:4,ref:z},t&&xt.createElement(Us,null,"•"),xt.createElement(Ls,{monitors:h,withLabels:m,size:10}))),g&&g.length>0?xt.createElement(ya,{$gap:4},g?.map((e,t)=>xt.createElement($t,{key:`componentsUnderTitles-${t}`},e))):null),xt.createElement(Ms,{ref:I},!!o&&xt.createElement(Bs,null,xt.createElement(js,{size:14,family:"secondary"},o)),i&&i(),w&&xt.createElement($t,null,xt.createElement(gr,{orientation:"vertical",length:"16px",margin:"0 2px"}),xt.createElement(Sr,{onClick:()=>A(e=>!e)},xt.createElement(ps,{extend:S}))))),S&&v&&xt.createElement(wa,null,xt.createElement(gr,{margin:"16px 0"}),v()))},Vs=It(ya)`
|
|
880
|
+
width: 100%;
|
|
881
|
+
justify-content: space-between;
|
|
882
|
+
`,Hs=It(Li)`
|
|
883
|
+
font-size: 12px;
|
|
884
|
+
color: ${({theme:e})=>e.text.grey};
|
|
885
|
+
`,qs=It(Li)`
|
|
886
|
+
font-size: 10px;
|
|
887
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
888
|
+
`,Gs=It.div`
|
|
889
|
+
display: flex;
|
|
890
|
+
align-items: center;
|
|
891
|
+
gap: 8px;
|
|
892
|
+
margin-left: auto;
|
|
893
|
+
`,Ks=It(Li)`
|
|
894
|
+
font-size: 12px;
|
|
895
|
+
text-align: right;
|
|
896
|
+
`,Js=({title:e,subTitle:t,tooltip:o,value:n})=>xt.createElement(Vs,null,xt.createElement(wa,{$gap:4},xt.createElement(vr,{text:o||""},e&&xt.createElement(Hs,null,e),t&&xt.createElement(qs,null,t))),xt.createElement(Gs,null,n?.status?xt.createElement(ks,{status:"transitioning"===n.status?go.Loading:n.status,title:n.text||n.status,withBorder:!0,withIcon:!0}):xt.createElement(Ks,null,n?.text||"-"))),Ys=It(wa)`
|
|
897
|
+
width: 100%;
|
|
898
|
+
`,Xs=({containerName:e,actualDevices:t,started:o,ready:n,instrumentationInstances:i})=>{const a=ft(()=>{const e=[];return o?.name&&e.push(xt.createElement(ks,{status:Rn(o.value)?Hn(o.value)?ho.Success:ho.Error:ho.Default,title:o.name,withIcon:!0,withBorder:!0,size:8})),n?.name&&e.push(xt.createElement(ks,{status:Rn(n.value)?Hn(n.value)?ho.Success:ho.Error:ho.Default,title:n.name,withIcon:!0,withBorder:!0,size:8})),e},[o?.name,o?.value,n?.name,n?.value]);return xt.createElement(Ws,{title:e.value,subTitle:i.length?`${i.length} Instrumented Processes`:void 0,visualProps:{componentsUnderTitles:a},renderActions:()=>xt.createElement(ks,{status:ho.Info,title:"Instrumentation Device",subtitle:t.value&&"[]"!==t.value?t.value:"none",withBorder:!0}),extendableProps:{isExtended:!!i.length,renderExtended:()=>xt.createElement(Ys,{$gap:24},i.map((e,t)=>xt.createElement(Ys,{key:`process-${t}`,$gap:8},xt.createElement(Js,{title:`Instrumented Process #${t+1}`,subTitle:e.message?.value||"",value:{status:e.healthy.status,text:e.healthy.status===ho.Success?"healthy":"unhealthy"}}),e.identifyingAttributes?.map(({name:e,value:t})=>xt.createElement(Js,{key:`describe-${e}-${t}`,title:e,subTitle:"",value:{text:t,status:void 0}})))))}})},Qs=It.div`
|
|
899
|
+
display: flex;
|
|
900
|
+
flex-direction: column;
|
|
901
|
+
align-items: center;
|
|
902
|
+
`,Zs=It.div`
|
|
903
|
+
display: flex;
|
|
904
|
+
align-items: center;
|
|
905
|
+
gap: 8px;
|
|
906
|
+
`,el=It(Li)`
|
|
907
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
908
|
+
`,tl=It(Li)`
|
|
909
|
+
color: ${({theme:e})=>e.colors.border};
|
|
910
|
+
font-size: 14px;
|
|
911
|
+
font-weight: 200;
|
|
912
|
+
line-height: 20px;
|
|
913
|
+
text-align: center;
|
|
914
|
+
`,ol=({title:e="No data found",subTitle:t="Check your search phrase and try one more time"})=>{const o=Si.useTheme();return xt.createElement(Qs,null,xt.createElement(Zs,null,xt.createElement(nt,{fill:o.text.dark_grey}),xt.createElement(el,null,e)),t&&xt.createElement(tl,null,t))},nl=It(wa)`
|
|
915
|
+
max-width: 300px;
|
|
916
|
+
padding: 12px;
|
|
917
|
+
border-radius: 12px;
|
|
918
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
919
|
+
justify-content: center;
|
|
920
|
+
`,il=Ct(({id:e,data:t})=>{const{title:o,subTitle:n}=t;return xt.createElement(nl,{"data-id":e},xt.createElement(ol,{title:o,subTitle:n}))});il.displayName=il.name;const al=It.div`
|
|
921
|
+
padding: 6px;
|
|
922
|
+
border-radius: 12px;
|
|
923
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
924
|
+
cursor: pointer;
|
|
925
|
+
`,rl=It.div`
|
|
926
|
+
position: relative;
|
|
927
|
+
`,sl=It(ya)`
|
|
928
|
+
position: absolute;
|
|
929
|
+
bottom: -24px;
|
|
930
|
+
left: 50%;
|
|
931
|
+
transform: translateX(-50%);
|
|
932
|
+
gap: 4px;
|
|
933
|
+
`,ll=It.div`
|
|
934
|
+
position: absolute;
|
|
935
|
+
bottom: 100%;
|
|
936
|
+
left: 100%;
|
|
937
|
+
width: 300px;
|
|
938
|
+
padding: 12px;
|
|
939
|
+
border-radius: 16px;
|
|
940
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
941
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
942
|
+
`,cl=({title:e,value:t})=>{const o=_t();return xt.createElement(ya,{$justifyContent:"space-between"},xt.createElement(Li,{size:12,color:o.text.info},e),xt.createElement(Li,{size:12,family:"secondary"},t))},dl=Ct(({id:e,data:t})=>{const{id:o,status:n,title:i,icons:a,serviceMapEntry:r}=t,{activeNodeType:s,activeNodeId:l}=qt(),c=_t(),d=n===ho.Error?Sn(n,c):null;return xt.createElement(xt.Fragment,null,xt.createElement(Rt,{type:"source",position:Lt.Bottom,style:{visibility:"hidden"}}),xt.createElement(Rt,{type:"target",position:Lt.Top,style:{visibility:"hidden"}}),xt.createElement(rl,{"data-id":e},xt.createElement(al,null,xt.createElement(Fs,{id:o,icons:a,status:n})),xt.createElement(sl,null,d&&xt.createElement(d,null),xt.createElement(Ts,{maxWidth:100,text:i})),s===fo.MapItem&&l===e&&xt.createElement(ll,null,xt.createElement(ya,{$gap:12},xt.createElement(Fs,{id:o,icons:a,status:n}),xt.createElement(Li,{size:20},i)),r&&r.services.length>0?r.services.map(({serviceName:e,requests:t,dateTime:n})=>xt.createElement("div",{key:`from-${o}-to-${e}`},xt.createElement(gr,null),xt.createElement(cl,{title:"Connected Service",value:e}),xt.createElement(cl,{title:"Outgoing Requests",value:t}),xt.createElement(cl,{title:"Last Requested At",value:new Date(n).toLocaleString()}))):xt.createElement(xt.Fragment,null,xt.createElement(gr,null),xt.createElement(ol,{title:"No outgoing connections",subTitle:" "})))))});dl.displayName=dl.name;const pl=It.div`
|
|
943
|
+
height: calc(100vh - 160px);
|
|
944
|
+
.react-flow__attribution {
|
|
945
|
+
visibility: hidden;
|
|
946
|
+
}
|
|
947
|
+
`,ul=It.div`
|
|
948
|
+
button {
|
|
949
|
+
padding: 8px;
|
|
950
|
+
margin: 8px;
|
|
951
|
+
border-radius: 8px;
|
|
952
|
+
border: 1px solid ${({theme:e})=>e.colors.border} !important;
|
|
953
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg};
|
|
954
|
+
path {
|
|
955
|
+
fill: ${({theme:e})=>e.text.secondary};
|
|
956
|
+
}
|
|
957
|
+
&:hover {
|
|
958
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
959
|
+
}
|
|
960
|
+
}
|
|
961
|
+
`,hl={[fo.MapItem]:dl,[fo.NoData]:il},ml=({nodes:e,edges:t,onNodesChange:o,onEdgesChange:n,fitView:i=!1,zoomOnScroll:a=!1})=>{const{onClickNode:r}=Oa(),{setActiveNodeType:s,setActiveNodeId:l}=qt();return xt.createElement(pl,null,xt.createElement(Bt,{fitView:i,zoomOnScroll:a,nodes:e,nodeTypes:hl,edges:t,onNodeClick:r,onNodesChange:e=>{setTimeout(()=>o(e),0)},onEdgesChange:e=>{setTimeout(()=>n(e),0)},onBlur:()=>{s(null),l(null)},onlyRenderVisibleElements:!0},xt.createElement(ul,null,xt.createElement(Pt,{position:"bottom-right",orientation:"horizontal",showInteractive:!1,showZoom:!0,showFitView:!0,fitViewOptions:{duration:300,padding:.02,includeHiddenNodes:!0}}))))},gl=It.div`
|
|
962
|
+
display: flex;
|
|
963
|
+
|
|
964
|
+
align-items: center;
|
|
965
|
+
gap: 6px;
|
|
966
|
+
margin-bottom: 4px;
|
|
967
|
+
`,xl=It(Li)`
|
|
968
|
+
font-size: 14px;
|
|
969
|
+
opacity: 0.8;
|
|
970
|
+
line-height: 22px;
|
|
971
|
+
overflow: hidden;
|
|
972
|
+
white-space: nowrap;
|
|
973
|
+
text-overflow: ellipsis;
|
|
974
|
+
color: ${({$status:e,theme:t})=>e?t.text[e]:t.text.secondary};
|
|
975
|
+
`,$l=It(Li)`
|
|
976
|
+
font-size: 12px;
|
|
977
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
978
|
+
opacity: 0.8;
|
|
979
|
+
`,fl=({title:e,required:t,tooltip:o,style:n,status:i})=>e?xt.createElement(gl,{style:n},xt.createElement(vr,{text:o,withIcon:!0},xt.createElement(xl,{$status:i},e),!t&&xt.createElement($l,null,"(optional)"))):null,bl=It.div`
|
|
980
|
+
display: flex;
|
|
981
|
+
flex-direction: column;
|
|
982
|
+
position: relative;
|
|
983
|
+
width: 100%;
|
|
984
|
+
`,yl=It.div`
|
|
985
|
+
width: 100%;
|
|
986
|
+
display: flex;
|
|
987
|
+
align-items: center;
|
|
988
|
+
height: 36px;
|
|
989
|
+
gap: 12px;
|
|
990
|
+
transition: border-color 0.3s;
|
|
991
|
+
border-radius: 32px;
|
|
992
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
993
|
+
${({$disabled:e})=>e&&Ft`
|
|
994
|
+
cursor: not-allowed;
|
|
995
|
+
opacity: 0.6;
|
|
996
|
+
`}
|
|
997
|
+
${({$isActive:e,$hasError:t,$status:o})=>e?Ft`
|
|
998
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
999
|
+
`:t?Ft`
|
|
1000
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
1001
|
+
`:o?Ft`
|
|
1002
|
+
border-color: ${({theme:e})=>e.text[o]};
|
|
1003
|
+
`:""}
|
|
1004
|
+
&:hover {
|
|
1005
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1006
|
+
}
|
|
1007
|
+
&:focus-within {
|
|
1008
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1009
|
+
}
|
|
1010
|
+
`,wl=It.input`
|
|
1011
|
+
padding-left: ${({$hasIcon:e})=>e?"0":"16px"};
|
|
1012
|
+
flex: 1;
|
|
1013
|
+
min-width: 150px;
|
|
1014
|
+
width: 100%;
|
|
1015
|
+
border: none;
|
|
1016
|
+
outline: none;
|
|
1017
|
+
background: none;
|
|
1018
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1019
|
+
font-size: 14px;
|
|
1020
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1021
|
+
font-weight: 300;
|
|
1022
|
+
&::placeholder {
|
|
1023
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1024
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1025
|
+
opacity: 0.4;
|
|
1026
|
+
font-size: 14px;
|
|
1027
|
+
font-weight: 300;
|
|
1028
|
+
line-height: 22px; /* 157.143% */
|
|
1029
|
+
}
|
|
1030
|
+
&:disabled {
|
|
1031
|
+
cursor: not-allowed;
|
|
1032
|
+
opacity: 0.6;
|
|
1033
|
+
}
|
|
1034
|
+
&::-webkit-inner-spin-button,
|
|
1035
|
+
&::-webkit-outer-spin-button {
|
|
1036
|
+
-webkit-appearance: none;
|
|
1037
|
+
margin: 0;
|
|
1038
|
+
}
|
|
1039
|
+
`,kl=It.div`
|
|
1040
|
+
display: flex;
|
|
1041
|
+
align-items: center;
|
|
1042
|
+
margin-left: 12px;
|
|
1043
|
+
`,vl=It(kl)`
|
|
1044
|
+
cursor: pointer;
|
|
1045
|
+
`,Cl=It.button`
|
|
1046
|
+
background-color: ${({theme:e})=>e.colors.primary};
|
|
1047
|
+
border: none;
|
|
1048
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1049
|
+
padding: 8px 16px;
|
|
1050
|
+
border-radius: 20px;
|
|
1051
|
+
cursor: pointer;
|
|
1052
|
+
margin-left: 8px;
|
|
1053
|
+
&:hover {
|
|
1054
|
+
background-color: ${({theme:e})=>e.colors.secondary};
|
|
1055
|
+
}
|
|
1056
|
+
&:disabled {
|
|
1057
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
1058
|
+
cursor: not-allowed;
|
|
1059
|
+
}
|
|
1060
|
+
`,El=({icon:e,buttonLabel:t,onButtonClick:o,hasError:n,errorMessage:i,title:a,tooltip:r,required:s,value:l,onChange:c,type:d=uo.Text,name:p,status:u,...h})=>{const m=Si.useTheme(),g=d===uo.Password,[x,$]=yt(!1);return xt.createElement(bl,null,xt.createElement(fl,{title:a,required:s,tooltip:r,status:u}),xt.createElement(yl,{$disabled:h.disabled,$hasError:n||!!i,$isActive:!!h.autoFocus,$status:u},g?xt.createElement(vl,{onClick:()=>$(e=>!e)},x?xt.createElement(it,{size:14,fill:m.text.grey}):xt.createElement(at,{size:14,fill:m.text.grey})):e?xt.createElement(kl,null,xt.createElement(e,{size:14,fill:m.text.grey})):null,xt.createElement(wl,{"data-id":p,type:x||d===uo.Number?uo.Text:d,$hasIcon:!!e||g,name:p,value:l,onChange:e=>{e.stopPropagation(),d===uo.Number&&(e.target.value=Vn(e.target.value)),c?.(e)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},...h}),t&&o&&xt.createElement(Cl,{onClick:o,disabled:h.disabled},t)),!!i&&xt.createElement(Xi,null,i))},Sl=It.div`
|
|
1061
|
+
display: flex;
|
|
1062
|
+
flex-direction: column;
|
|
1063
|
+
min-width: 120px;
|
|
1064
|
+
width: 100%;
|
|
1065
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
1066
|
+
`,Al=It.div`
|
|
1067
|
+
position: relative;
|
|
1068
|
+
`,Dl=It.div`
|
|
1069
|
+
display: flex;
|
|
1070
|
+
align-items: center;
|
|
1071
|
+
justify-content: space-between;
|
|
1072
|
+
height: 36px;
|
|
1073
|
+
padding: ${({$isMulti:e,$hasSelections:t})=>e&&t?"0 16px 0 6px":"0 16px"};
|
|
1074
|
+
border-radius: 32px;
|
|
1075
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1076
|
+
|
|
1077
|
+
${({$isOpen:e,$isMulti:t,theme:o})=>e&&!t?Ft`
|
|
1078
|
+
border: 1px solid ${o.text.grey};
|
|
1079
|
+
background: ${o.colors.dropdown_bg_2};
|
|
1080
|
+
`:Ft`
|
|
1081
|
+
border: 1px solid ${o.colors.border};
|
|
1082
|
+
background: transparent;
|
|
1083
|
+
`};
|
|
1084
|
+
|
|
1085
|
+
${({$hasError:e,$status:t})=>e?Ft`
|
|
1086
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
1087
|
+
`:t?Ft`
|
|
1088
|
+
border-color: ${({theme:e})=>e.text[t]};
|
|
1089
|
+
`:""}
|
|
1090
|
+
|
|
1091
|
+
&:hover {
|
|
1092
|
+
border-color: ${({$isMulti:e,$hasSelections:t,$disabled:o,theme:n})=>o?"auto":e&&t?n.colors.border:n.colors.secondary};
|
|
1093
|
+
}
|
|
1094
|
+
`,Tl=It.div`
|
|
1095
|
+
display: flex;
|
|
1096
|
+
align-items: center;
|
|
1097
|
+
gap: 4px;
|
|
1098
|
+
`,Nl=({options:e,value:t,onSelect:o,onDeselect:n,title:i,tooltip:a,placeholder:r,disabled:s=!1,isMulti:l=!1,showSearch:c=!1,required:d=!1,errorMessage:p,hasError:u=!1,status:h})=>{const[m,g]=yt(!1),[x,$]=yt(!1),f=kt(null);Ka(f,()=>g(!1));const b=()=>{(()=>{if(f.current){const e=f.current.getBoundingClientRect().bottom+300>window.innerHeight;$(e)}})(),g(e=>!e)},y=Array.isArray(t)?t.length:0;return xt.createElement(Sl,{$disabled:s},xt.createElement(fl,{title:i,required:d,tooltip:a,status:h}),xt.createElement(Al,{ref:f},xt.createElement(Dl,{$isOpen:m,$isMulti:l,$hasSelections:!!Array.isArray(t)&&!!t.length,$hasError:!!p||u,$status:h,$disabled:s,onClick:()=>!s&&b()},xt.createElement(_l,{value:t,placeholder:r,onDeselect:n}),xt.createElement(Tl,null,l&&xt.createElement(ma,{label:y,filled:!!y}),xt.createElement(ps,{extend:m}))),m&&xt.createElement(Ll,{openUpwards:x,options:e,value:t,onSelect:e=>{o?.(e),l||b()},onDeselect:e=>{n?.(e),l||b()},isMulti:l,showSearch:c})),!!p&&xt.createElement(Xi,null,p))},Il=It(Tl)`
|
|
1099
|
+
max-width: calc(100% - 50px);
|
|
1100
|
+
overflow-x: auto;
|
|
1101
|
+
`,zl=It(Li)`
|
|
1102
|
+
display: flex;
|
|
1103
|
+
align-items: center;
|
|
1104
|
+
gap: 2px;
|
|
1105
|
+
padding: 4px 12px;
|
|
1106
|
+
background: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1107
|
+
border-radius: 360px;
|
|
1108
|
+
white-space: nowrap;
|
|
1109
|
+
text-overflow: ellipsis;
|
|
1110
|
+
img {
|
|
1111
|
+
&:hover {
|
|
1112
|
+
transform: scale(2);
|
|
1113
|
+
transition: transform 0.3s;
|
|
1114
|
+
}
|
|
1115
|
+
}
|
|
1116
|
+
`,Ol=It(Li)``,_l=({value:e,placeholder:t,onDeselect:o})=>{const n=Si.useTheme();return Array.isArray(e)?e.length?xt.createElement(Il,null,e.map(e=>xt.createElement(zl,{key:`multi-label-${e.id}`,size:14},e.value,xt.createElement(gr,{orientation:"vertical",length:"10px",margin:"0 4px"}),xt.createElement(Ye,{size:12,onClick:t=>{t.stopPropagation(),o?.(e)}})))):xt.createElement(Ol,{size:14,color:n.text.darker_grey},t):xt.createElement(Ol,{size:14,color:e?.value?void 0:n.text.darker_grey},e?.value||t)},Fl=It.div`
|
|
1117
|
+
position: absolute;
|
|
1118
|
+
${({$openUpwards:e})=>e?"bottom":"top"}: calc(100% + 8px);
|
|
1119
|
+
left: 0;
|
|
1120
|
+
z-index: 1;
|
|
1121
|
+
display: flex;
|
|
1122
|
+
flex-direction: column;
|
|
1123
|
+
overflow-y: auto;
|
|
1124
|
+
width: calc(100% - 16px);
|
|
1125
|
+
max-height: 200px;
|
|
1126
|
+
gap: 8px;
|
|
1127
|
+
padding: 8px;
|
|
1128
|
+
background-color: ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1129
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1130
|
+
border-radius: 24px;
|
|
1131
|
+
`,Rl=It.div`
|
|
1132
|
+
display: flex;
|
|
1133
|
+
flex-direction: column;
|
|
1134
|
+
align-items: center;
|
|
1135
|
+
`,Ll=({openUpwards:e,options:t,value:o,onSelect:n,onDeselect:i,isMulti:a,showSearch:r})=>{const[s,l]=yt(""),c=t.filter(e=>e.value?.toLowerCase().includes(s?.toLowerCase()));return xt.createElement(Fl,{$openUpwards:e},r&&xt.createElement(Rl,null,xt.createElement(El,{placeholder:"Search...",icon:rt,value:s,onChange:e=>l(e.target.value)}),xt.createElement(gr,{thickness:1,margin:"8px 0 0 0"})),0===c.length?xt.createElement(ol,{subTitle:r&&s?void 0:" "}):c.map((e,t)=>xt.createElement(Pl,{key:`dropdown-option-${e.id||t}`,option:e,value:o,isMulti:a,onSelect:n,onDeselect:i})))},Bl=It.div`
|
|
1136
|
+
padding: 8px 12px;
|
|
1137
|
+
cursor: pointer;
|
|
1138
|
+
display: flex;
|
|
1139
|
+
justify-content: space-between;
|
|
1140
|
+
align-items: center;
|
|
1141
|
+
border-radius: 32px;
|
|
1142
|
+
&:hover,
|
|
1143
|
+
&.selected {
|
|
1144
|
+
background: ${({theme:e})=>e.colors.majestic_blue+Si.opacity.hex["024"]};
|
|
1145
|
+
}
|
|
1146
|
+
`,Pl=({option:e,value:t,isMulti:o,onSelect:n,onDeselect:i})=>{const a=Si.useTheme(),r=Array.isArray(t)?!!t?.find(t=>t.id===e.id):t?.id===e.id,s=t=>t?n?.(e):i?.(e);return o?xt.createElement(Bl,{className:r?"selected":"",onClick:()=>s(!r)},xt.createElement(Gr,{title:e.value||"",titleColor:a.text.secondary,value:r,onChange:s,style:{width:"100%"}})):xt.createElement(Bl,{className:r?"selected":"",onClick:()=>r?i?.(e):n?.(e)},xt.createElement(ya,{$gap:8},e.icon&&xt.createElement(e.icon,null),xt.createElement(Li,{size:14},e.value)),r&&xt.createElement(Ke,null))},Ml=It(wa)`
|
|
1147
|
+
gap: 12px;
|
|
1148
|
+
`,jl=It(ya)`
|
|
1149
|
+
width: 100%;
|
|
1150
|
+
gap: 12px;
|
|
1151
|
+
align-items: flex-end;
|
|
1152
|
+
`,Ul=({clientX:e=0,flipX:t,clientY:o=0,flipY:n,isOpen:i,onClose:a,onSave:r,withDelete:s,onDelete:l,title:c,titleTooltip:d,warning:p,children:u})=>{const h=Si.useTheme(),{popupRef:m,popupPosition:g,handlePosition:x}=Ja({onClickOutside:a});return Ga({key:"Enter",active:i},r),wt(()=>x(e,o),[e,o]),0===g.top&&0!==o||0===g.left&&0!==e?null:xt.createElement(yr,{ref:m,isOpen:i,top:n?void 0:g.top,bottom:n?g.top:void 0,left:t?void 0:g.left,right:t?g.left:void 0,padding:"24px"},xt.createElement(Ml,null,xt.createElement(vr,{text:d,withIcon:!0},xt.createElement(Li,{size:14},c)),xt.createElement(jl,null,u,xt.createElement(ya,{$gap:6},xt.createElement(Sr,{withBorder:!0,onClick:a,tooltip:"Cancel"},xt.createElement(Ye,null)),xt.createElement(Sr,{withBorder:!0,backgroundColor:h.colors.secondary,onClick:r,tooltip:"Save"},xt.createElement(Ke,{fill:h.text.primary})),s&&xt.createElement(Sr,{onClick:l,tooltip:"Undo"},xt.createElement(st,null)))),p&&xt.createElement(Fr,{type:ho.Warning,message:p})))},Wl=It.div`
|
|
1153
|
+
position: relative;
|
|
1154
|
+
`,Vl=({defaultLanguage:e=ro.Unknown,defaultVersion:t="",handleSave:o})=>{const{addNotification:n}=ci(),{formData:i,handleFormChange:a,resetFormData:r}=Ta({language:e,version:t}),[s,l]=yt(!1),c=()=>{l(!1),r()};return xt.createElement(Wl,null,xt.createElement(Sr,{tooltip:en.OVERRIDE_RUNTIME_DETAILS,size:32,onClick:()=>{l(!0)}},xt.createElement(ot,null)),xt.createElement(Ul,{flipX:!0,clientX:36,isOpen:s,onClose:c,onSave:()=>{!i.version||Pn(i.version)?(o(i),c()):n({type:ho.Warning,message:Zo.INVALID_VERSION,hideFromHistory:!0})},withDelete:!0,onDelete:()=>{o({language:null,version:""}),c()},title:en.OVERRIDE_RUNTIME_DETAILS,warning:en.OVERRIDE_RUNTIME_WARNING},xt.createElement(Nl,{title:en.LANGUAGE,options:Qn,value:Qn.find(e=>e.id===i.language),onSelect:e=>a("language",e.id),required:!0}),xt.createElement(El,{title:en.RUNTIME_VERSION,placeholder:en.VERSION_PLACEHOLDER,value:i.version,onChange:e=>a("version",e.target.value),required:!1})))},Hl=It(ya)`
|
|
1155
|
+
width: 100%;
|
|
1156
|
+
justify-content: center;
|
|
1157
|
+
`,ql=({containerName:e,language:t,runtimeVersion:o,overriden:n,instrumented:i,instrumentationMessage:a,otelDistroName:r,callbackRuntimeOverride:s})=>{const l=Si.useTheme(),c=i?ho.Success:a?ho.Info:ho.Warning,d=i?mo.INSTRUMENTED:a?mo.NOT_INSTRUMENTED:mo.INSTRUMENTING;return xt.createElement(Ws,{title:e,subTitle:`${t?Xn[t]:"no runtime info"}`+(o?` • Runtime Version: ${o}`:""),iconProps:{icon:dn(t)},extendableProps:{isExtended:!!a,renderExtended:()=>xt.createElement(Hl,null,xt.createElement(Li,{size:12,family:"secondary",color:l.text.info},Mn(a)))},renderActions:()=>xt.createElement(xt.Fragment,null,xt.createElement(ks,{status:c,title:d,subtitle:r||void 0,withIcon:!0,withBorder:!0}),n&&xt.createElement(ks,{status:ho.Default,forceIcon:lt,title:en.OVERIDDEN,withIcon:!0,withBorder:!0}),s&&xt.createElement(Vl,{defaultLanguage:t,defaultVersion:o,handleSave:t=>s({...t,containerName:e})}))})},Gl=It.tr`
|
|
1158
|
+
cursor: ${({$withHover:e})=>e?"pointer":"default"};
|
|
1159
|
+
opacity: ${({$faded:e})=>e?.5:1};
|
|
1160
|
+
`,Kl=It.td`
|
|
1161
|
+
position: relative;
|
|
1162
|
+
width: fit-content;
|
|
1163
|
+
padding: 16px 8px 16px ${({$isFirst:e})=>e?"16px":"8px"};
|
|
1164
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1165
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1166
|
+
font-size: 14px;
|
|
1167
|
+
white-space: nowrap;
|
|
1168
|
+
`,Jl=It(Li)`
|
|
1169
|
+
font-size: 14px;
|
|
1170
|
+
color: ${({$color:e,theme:t})=>e??t.text.secondary};
|
|
1171
|
+
line-height: 16px;
|
|
1172
|
+
|
|
1173
|
+
overflow: hidden;
|
|
1174
|
+
overflow-wrap: break-word;
|
|
1175
|
+
white-space: wrap;
|
|
1176
|
+
text-wrap: wrap;
|
|
1177
|
+
text-overflow: ellipsis;
|
|
1178
|
+
display: -webkit-box;
|
|
1179
|
+
-webkit-line-clamp: 2;
|
|
1180
|
+
-webkit-box-orient: vertical;
|
|
1181
|
+
`,Yl=It.div`
|
|
1182
|
+
position: absolute;
|
|
1183
|
+
top: 0;
|
|
1184
|
+
left: 0;
|
|
1185
|
+
z-index: -1;
|
|
1186
|
+
width: ${({$width:e})=>e}px;
|
|
1187
|
+
height: ${({$height:e})=>e}px;
|
|
1188
|
+
border-radius: 16px;
|
|
1189
|
+
background-color: ${({theme:e,$hovered:t,$status:o})=>t?o?e.text[o]+Si.opacity.hex["020"]:e.colors.majestic_blue+Si.opacity.hex["030"]:o?e.text[o]+Si.opacity.hex["010"]:e.colors.secondary+Si.opacity.hex["005"]};
|
|
1190
|
+
`,Xl=({index:e,columns:t,cells:o,onClick:n,status:i,faded:a})=>{const{containerRef:r,containerHeight:s,containerWidth:l}=Ra(),[c,d]=yt(!1);return xt.createElement(Gl,{ref:r,onMouseEnter:()=>!!n&&d(!0),onMouseLeave:()=>!!n&&d(!1),onClick:()=>!!n&&n(),$withHover:!!n,$faded:a},t.map(({key:t},n)=>{const a=o.find(({columnKey:e})=>e===t);if(!a)return null;const{value:r,textColor:d,withTooltip:p,icon:u,component:h}=a;return xt.createElement(Kl,{key:`table-row-${t}-${r}-${e}-${n}`,$isFirst:0===n},u?xt.createElement(zs,{icon:u}):h?xt.createElement(h,null):xt.createElement(vr,{text:p&&r?String(r):""},xt.createElement(Jl,{$color:d},On(r)?"-":r)),0===n&&xt.createElement(Yl,{$height:s,$width:l,$top:s*e,$hovered:c,$status:i}))}))},Ql=It.div`
|
|
1191
|
+
width: 100%;
|
|
1192
|
+
`,Zl=It.table`
|
|
1193
|
+
position: relative;
|
|
1194
|
+
z-index: 0;
|
|
1195
|
+
width: 100%;
|
|
1196
|
+
border-collapse: separate;
|
|
1197
|
+
border-spacing: 0 12px;
|
|
1198
|
+
`,ec=It.thead`
|
|
1199
|
+
// only supported with "border-collapse: collapse;"
|
|
1200
|
+
// border-top: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1201
|
+
// border-bottom: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1202
|
+
`,tc=It.th`
|
|
1203
|
+
// only required with "border-collapse: separate;"
|
|
1204
|
+
border-top: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1205
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.dropdown_bg_2};
|
|
1206
|
+
|
|
1207
|
+
padding: 8px;
|
|
1208
|
+
`,oc=It(ya)`
|
|
1209
|
+
cursor: pointer;
|
|
1210
|
+
&:hover {
|
|
1211
|
+
* {
|
|
1212
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1213
|
+
}
|
|
1214
|
+
}
|
|
1215
|
+
`,nc=It(Li)`
|
|
1216
|
+
color: ${({theme:e})=>e.text.darker_grey};
|
|
1217
|
+
font-family: ${({theme:e})=>e.font_family.secondary};
|
|
1218
|
+
text-transform: uppercase;
|
|
1219
|
+
font-size: 12px;
|
|
1220
|
+
font-weight: 500;
|
|
1221
|
+
text-wrap: nowrap;
|
|
1222
|
+
`,ic=It.tbody``,ac=({columns:e,rows:t})=>{const[o,n]=yt(oo.Ascending),[i,a]=yt("name"),r=vt(e=>{i===e?n(e=>e===oo.Ascending?oo.Descending:oo.Ascending):(a(e),n(oo.Ascending))},[i]),s=ft(()=>{const n=(e,t)=>e.cells.find(({columnKey:e})=>e===t)?.value??null;return(i?[...t].sort((e,t)=>{const a=n(e,i),r=n(t,i);return(o===oo.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)))(a,r)}):t).map(({status:t,faded:o,cells:n,onClick:i},a)=>xt.createElement(Xl,{key:`row-${a}`,index:a,columns:e,cells:n,onClick:i,status:t,faded:o}))},[e,t,i,o]);return xt.createElement(Ql,null,xt.createElement(Zl,null,xt.createElement(ec,null,xt.createElement("tr",null,e.map(({key:e,title:t,sortable:o})=>xt.createElement(tc,{key:`column-${e}`},o?xt.createElement(oc,{onClick:()=>r(e)},xt.createElement(ct,null),xt.createElement(nc,null,t)):xt.createElement(nc,null,t))))),xt.createElement(ic,null,s)))};var rc;!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"}(rc||(rc={}));const sc=It.div`
|
|
1223
|
+
display: flex;
|
|
1224
|
+
flex-wrap: wrap;
|
|
1225
|
+
gap: 16px 32px;
|
|
1226
|
+
width: 100%;
|
|
1227
|
+
`,lc=It.div`
|
|
1228
|
+
display: flex;
|
|
1229
|
+
flex-direction: column;
|
|
1230
|
+
gap: 2px;
|
|
1231
|
+
width: ${({$width:e})=>e};
|
|
1232
|
+
`,cc=It(Li)`
|
|
1233
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1234
|
+
font-size: 10px;
|
|
1235
|
+
line-height: 16px;
|
|
1236
|
+
`,dc=It(Li)`
|
|
1237
|
+
font-size: 12px;
|
|
1238
|
+
white-space: pre-wrap;
|
|
1239
|
+
`,pc=({data:e})=>xt.createElement(sc,null,e?.map(({type:e,title:t,titleIcon:o,tooltip:n,value:i},a)=>xt.createElement(lc,{key:`data-field-${t||(i?JSON.stringify(i):a)}`,$width:e&&[rc.Code,rc.Table].includes(e)?"inherit":e&&[rc.Loader,rc.Divider,rc.CopyText].includes(e)?"100%":"unset"},xt.createElement(vr,{text:n,withIcon:!0},xt.createElement(ya,{$alignItems:"center",$gap:4},o&&xt.createElement(o,{size:14}),!!t&&xt.createElement(cc,{transform:"capitalize"},t))),xt.createElement(uc,{type:e,value:i})))),uc=({type:e,value:t})=>{const o=Si.useTheme();switch(e){case rc.Divider:return xt.createElement(gr,{length:"100%",margin:"0"});case rc.Loader:return xt.createElement(ka,null,xt.createElement(cs,{scale:1.2}));case rc.Monitors:return xt.createElement(Ls,{monitors:t?.split(", ")||[],withLabels:!0,color:o.colors.secondary});case rc.Badge:{const{label:e,filled:o,...n}=Nn(t,{label:"-",filled:!1});return xt.createElement(ma,{label:e,filled:o,...n})}case rc.Code:{const{language:e,code:o,...n}=Nn(t,{language:"",code:""});return xt.createElement(ns,{language:e,code:o,...n})}case rc.Table:{const{columns:e,rows:o,...n}=Nn(t,{columns:[],rows:[{status:void 0,cells:[]}]});return xt.createElement(ac,{columns:e,rows:o,...n})}case rc.ActiveStatus:return xt.createElement(ks,{status:"true"==t?ho.Success:ho.Error,title:"true"==t?en.ENABLED:en.DISABLED,size:10,withIcon:!0,withBorder:!0});case rc.CopyText:{const e="string"==typeof t?t:JSON.stringify(t);return xt.createElement(Es,{value:e})}default:return xt.createElement(dc,null,qn("string"==typeof t?t||"-":""))}},hc=It.div`
|
|
1240
|
+
display: flex;
|
|
1241
|
+
flex-direction: column;
|
|
1242
|
+
align-items: flex-start;
|
|
1243
|
+
align-self: stretch;
|
|
1244
|
+
gap: 16px;
|
|
1245
|
+
padding: 24px;
|
|
1246
|
+
border-radius: 24px;
|
|
1247
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1248
|
+
background-color: ${({theme:e,$hovered:t})=>t?e.colors.secondary+Si.opacity.hex["010"]:"transparent"};
|
|
1249
|
+
transition: background-color 0.3s;
|
|
1250
|
+
`,mc=It.div`
|
|
1251
|
+
width: 100%;
|
|
1252
|
+
display: flex;
|
|
1253
|
+
flex-direction: column;
|
|
1254
|
+
gap: 4px;
|
|
1255
|
+
cursor: ${({$clickable:e})=>e?"pointer":"default"};
|
|
1256
|
+
`,gc=It(Li)`
|
|
1257
|
+
width: 100%;
|
|
1258
|
+
display: flex;
|
|
1259
|
+
align-items: center;
|
|
1260
|
+
gap: 8px;
|
|
1261
|
+
font-size: 16px;
|
|
1262
|
+
`,xc=It(Li)`
|
|
1263
|
+
font-size: 12px;
|
|
1264
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1265
|
+
`,$c=It(ya)`
|
|
1266
|
+
margin-left: auto;
|
|
1267
|
+
gap: 8px;
|
|
1268
|
+
`,fc=({title:e="Details",titleBadge:t,titleIcon:o,description:n,action:i,withExtend:a,initialExtended:r=!1,data:s,children:l})=>{const[c,d]=yt(r),[p,u]=yt(!1);return xt.createElement(hc,{$hovered:p},e||o||n||i?xt.createElement(mc,{$clickable:a||!1,onClick:()=>a&&d(e=>!e),onMouseEnter:()=>a&&u(!0),onMouseLeave:()=>a&&u(!1)},xt.createElement(ya,null,xt.createElement(ya,{$alignItems:"center",$gap:8},o&&xt.createElement(ya,{$alignItems:"center"},xt.createElement(o,{size:20})),!!e&&xt.createElement(gc,{transform:"capitalize"},e),t===go.Loading?xt.createElement(cs,null):void 0!==t&&xt.createElement(ma,{label:t})),(!!i||a)&&xt.createElement($c,null,"function"==typeof i?xt.createElement(i,null):i,a&&xt.createElement(ps,{extend:c}))),!!n&&xt.createElement(xc,null,n)):null,(!a||a&&c)&&(l||xt.createElement(pc,{data:s})))},bc=It.div`
|
|
1269
|
+
visibility: hidden;
|
|
1270
|
+
`,yc=It(ya)`
|
|
1271
|
+
align-self: stretch;
|
|
1272
|
+
width: calc(100% - 32px);
|
|
1273
|
+
padding: 16px;
|
|
1274
|
+
border-radius: 16px;
|
|
1275
|
+
background-color: ${({theme:e})=>e.colors.secondary+Si.opacity.hex["005"]};
|
|
1276
|
+
${({theme:e,$withClick:t})=>t?Ft`
|
|
1277
|
+
&:hover {
|
|
1278
|
+
cursor: pointer;
|
|
1279
|
+
background-color: ${e.colors.secondary+Si.opacity.hex["010"]};
|
|
1280
|
+
${bc} {
|
|
1281
|
+
visibility: visible;
|
|
1282
|
+
}
|
|
1283
|
+
}
|
|
1284
|
+
`:`\n &:hover {\n ${bc} {\n visibility: visible;\n }\n }\n `}
|
|
1285
|
+
`,wc=It(ya)`
|
|
1286
|
+
margin-left: auto;
|
|
1287
|
+
gap: 8px;
|
|
1288
|
+
`,kc=It(Li)`
|
|
1289
|
+
font-size: 10px;
|
|
1290
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1291
|
+
`,vc=({title:e,subTitle:t,icons:o,iconSrcs:n,onClick:i,renderActions:a})=>{const r=Si.useTheme(),[s,l]=yt(0),c=kt(null),d=kt(null);return wt(()=>{if(c.current){const e=c.current.clientWidth,t=d.current?.clientWidth||0;l(e-(85+t))}},[]),xt.createElement(yc,{ref:c,$gap:8,$withClick:!!i,onClick:i},xt.createElement(Fs,{id:`${e}-${t}`,icons:o,iconSrcs:n}),e&&xt.createElement(Ts,{maxWidth:s/2,text:e,textSize:14}),e&&t&&xt.createElement(kc,null,"•"),t&&xt.createElement(Ts,{maxWidth:s/2,text:t,textSize:10,textColor:r.text.grey}),xt.createElement(wc,{ref:d},a&&xt.createElement(xt.Fragment,null,xt.createElement(gr,{orientation:"vertical",length:"24px",margin:"0"}),a())))},Cc=({isOpen:e,noOverlay:t,name:o,type:n,isLastItem:i,onApprove:a,onDeny:r})=>{const s=n===lo.Source?"uninstrument":"delete";return xt.createElement(Wr,{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:ho.Warning,title:`You're about to ${s} the last ${n||o}`,message:""}:void 0,approveButton:{text:"Confirm",variant:"danger",onClick:a},denyButton:{text:"Go Back",onClick:r}})},Ec=It(fa)`
|
|
1292
|
+
display: flex;
|
|
1293
|
+
align-items: center;
|
|
1294
|
+
justify-content: center;
|
|
1295
|
+
font-size: 14px;
|
|
1296
|
+
gap: 6px;
|
|
1297
|
+
min-width: 100px;
|
|
1298
|
+
`,Sc=({endpoint:e="/",variant:t="secondary"})=>xt.createElement(Ec,{variant:t,onClick:()=>window.open(`https://docs.odigos.io${e}`,"_blank","noopener noreferrer")},xt.createElement(dt,{size:18}),"Docs"),Ac=It(ya)`
|
|
1299
|
+
border-bottom: ${({$hideBorder:e,theme:t})=>e?"none":`1px solid ${t.colors.border}`};
|
|
1300
|
+
`,Dc=It.div`
|
|
1301
|
+
display: flex;
|
|
1302
|
+
align-items: center;
|
|
1303
|
+
border-bottom: 2px solid ${({theme:e,$selected:t})=>t?e.colors.majestic_blue:"transparent"};
|
|
1304
|
+
cursor: pointer;
|
|
1305
|
+
`,Tc=It(Li)`
|
|
1306
|
+
padding: 12px;
|
|
1307
|
+
font-size: 14px;
|
|
1308
|
+
color: ${({theme:e,$selected:t})=>t?e.text.secondary:e.text.grey};
|
|
1309
|
+
`,Nc=({tabs:e,hideBorder:t=!1})=>e?.length?xt.createElement(Ac,{$hideBorder:t},e.map(({label:e,icon:t,onClick:o,selected:n})=>xt.createElement(Dc,{key:`tab-${e}`,onClick:o,$selected:n},xt.createElement(Tc,{$selected:n},e),t&&xt.createElement(t,null)))):null,Ic=It.section`
|
|
1310
|
+
padding: 0px 32px;
|
|
1311
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border};
|
|
1312
|
+
`,zc=It.div`
|
|
1313
|
+
height: 76px;
|
|
1314
|
+
display: flex;
|
|
1315
|
+
justify-content: space-between;
|
|
1316
|
+
flex-shrink: 0;
|
|
1317
|
+
align-self: stretch;
|
|
1318
|
+
`,Oc=It.div`
|
|
1319
|
+
display: flex;
|
|
1320
|
+
align-items: center;
|
|
1321
|
+
gap: ${({$gap:e})=>e||16}px;
|
|
1322
|
+
`,_c=It(Li)`
|
|
1323
|
+
font-size: 18px;
|
|
1324
|
+
line-height: 26px;
|
|
1325
|
+
max-width: ${({$maxWidth:e})=>e};
|
|
1326
|
+
overflow: hidden;
|
|
1327
|
+
white-space: nowrap;
|
|
1328
|
+
text-overflow: ellipsis;
|
|
1329
|
+
`,Fc=It(fa)`
|
|
1330
|
+
gap: 8px;
|
|
1331
|
+
`,Rc=It(fa)``,Lc=({onClose:e,width:t,icons:o,iconSrcs:n,title:i,titleTooltip:a,replaceTitleWith:r,actions:s,actionButtons:l=[],tabs:c})=>xt.createElement(Ic,null,xt.createElement(zc,null,xt.createElement(Oc,null,o?.length||n?.length?xt.createElement(Fs,{icons:o,iconSrcs:n,id:`drawer-header-${i}`}):null,("function"==typeof r?xt.createElement(r,null):r||null)||xt.createElement(vr,{text:a||i,withIcon:!!a},i&&xt.createElement(_c,{$maxWidth:`calc(${t} ${s||l.length?"/ 5":"- 192px"})`},i))),xt.createElement(Oc,{$gap:2},s,l.map((e,t)=>xt.createElement(Fc,{key:`header-action-button-${t}`,...e})),xt.createElement(Rc,{"data-id":"drawer-close",variant:"secondary",onClick:e},xt.createElement(Ye,{size:12})))),xt.createElement(Nc,{tabs:c,hideBorder:!0})),Bc=It.div`
|
|
1332
|
+
display: flex;
|
|
1333
|
+
justify-content: space-between;
|
|
1334
|
+
gap: 8px;
|
|
1335
|
+
padding: 24px 18px 24px 32px;
|
|
1336
|
+
border-top: 1px solid ${({theme:e})=>e.colors.border};
|
|
1337
|
+
background-color: ${({theme:e})=>e.colors.translucent_bg};
|
|
1338
|
+
transform: translateY(100%);
|
|
1339
|
+
`,Pc=It(ya)`
|
|
1340
|
+
margin-right: auto;
|
|
1341
|
+
`,Mc=It(ya)`
|
|
1342
|
+
margin: 0 auto;
|
|
1343
|
+
`,jc=It(ya)`
|
|
1344
|
+
margin-left: auto;
|
|
1345
|
+
`,Uc=It(fa)`
|
|
1346
|
+
min-width: 140px;
|
|
1347
|
+
font-size: 14px;
|
|
1348
|
+
`,Wc=({isOpen:e,leftButtons:t=[],centerButtons:o=[],rightButtons:n=[]})=>{const i=ir({container:Bc,animateIn:Si.animations.slide.in.bottom,animateOut:Si.animations.slide.out.bottom});return xt.createElement(i,{enter:e},xt.createElement(Pc,null,t.map((e,t)=>xt.createElement(Uc,{key:`footer-left-button-${t}`,...e}))),xt.createElement(Mc,null,o.map((e,t)=>xt.createElement(Uc,{key:`footer-center-button-${t}`,...e}))),xt.createElement(jc,null,n.map((e,t)=>xt.createElement(Uc,{key:`footer-right-button-${t}`,...e}))))},Vc=It.div`
|
|
1349
|
+
position: fixed;
|
|
1350
|
+
top: 0;
|
|
1351
|
+
bottom: 0;
|
|
1352
|
+
${({$position:e})=>e}: 0;
|
|
1353
|
+
z-index: 1000;
|
|
1354
|
+
width: ${({$width:e})=>e};
|
|
1355
|
+
background: ${({theme:e})=>e.colors.translucent_bg};
|
|
1356
|
+
box-shadow: 0 2px 10px ${({theme:e})=>e.colors.primary+Si.opacity.hex["010"]};
|
|
1357
|
+
overflow-y: auto;
|
|
1358
|
+
`,Hc=It.div`
|
|
1359
|
+
display: flex;
|
|
1360
|
+
flex-direction: column;
|
|
1361
|
+
height: 100%;
|
|
1362
|
+
`,qc=It.div`
|
|
1363
|
+
flex-grow: 1;
|
|
1364
|
+
padding: 24px 32px;
|
|
1365
|
+
overflow-y: auto;
|
|
1366
|
+
`,Gc=({isOpen:e,onClose:t,closeOnEscape:o=!0,position:n="right",width:i="300px",children:a,header:r,footer:s})=>{Ga({key:"Escape",active:e&&o},()=>t()),za(e);const l=ir({container:Vc,animateIn:Si.animations.slide.in[n],animateOut:Si.animations.slide.out[n]});return e?Mt.createPortal(xt.createElement(xt.Fragment,null,xt.createElement(Ca,{hidden:!e,onClick:t}),xt.createElement(l,{"data-id":"drawer",enter:e,$position:n,$width:i},xt.createElement(Hc,null,xt.createElement(Lc,{onClose:t,width:i,...r}),xt.createElement(qc,null,a),xt.createElement(Wc,{...s})))),document.body):null},Kc=({error:e})=>{const t=Si.useTheme(),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 xt.createElement("div",{style:o.container},xt.createElement("h2",null,"Something went wrong!"),xt.createElement("pre",{style:o.errorMessage},e?.message||"Unknown Error"),xt.createElement("details",{style:o.errorStackWrapper},xt.createElement("summary",null,"Stack Trace"),xt.createElement("pre",{style:o.errorStack},e?.stack||"Unknown Stack")),xt.createElement("p",{style:o.infoText},"Try refreshing the page or contact support"),xt.createElement(fa,{variant:"secondary",onClick:()=>window.location.reload(),style:{fontSize:"1rem"}},"Reload"))},Jc=({children:e})=>xt.createElement(Vt,{FallbackComponent:e=>xt.createElement(Si.Provider,null,xt.createElement(Kc,{...e}))},e),Yc=It(ya)`
|
|
1367
|
+
position: relative;
|
|
1368
|
+
width: calc(100% - 24px);
|
|
1369
|
+
padding: 12px;
|
|
1370
|
+
background-color: ${({theme:e})=>e.colors.dark_grey};
|
|
1371
|
+
border-bottom: 1px solid ${({theme:e})=>e.colors.border+Si.opacity.hex["050"]};
|
|
1372
|
+
`,Xc=It(ya)`
|
|
1373
|
+
margin-right: auto;
|
|
1374
|
+
margin-left: 32px;
|
|
1375
|
+
gap: 12px;
|
|
1376
|
+
`,Qc=It(ya)`
|
|
1377
|
+
margin-left: auto;
|
|
1378
|
+
margin-right: 32px;
|
|
1379
|
+
gap: 12px;
|
|
1380
|
+
`,Zc=It(ya)`
|
|
1381
|
+
position: absolute;
|
|
1382
|
+
left: 50%;
|
|
1383
|
+
transform: translateX(-50%);
|
|
1384
|
+
gap: 12px;
|
|
1385
|
+
`,ed=({left:e=[],center:t=[],right:o=[]})=>xt.createElement(Yc,null,xt.createElement(Xc,null,e.map((e,t)=>e&&xt.createElement($t,{key:t},e))),xt.createElement(Zc,null,t.map((e,t)=>e&&xt.createElement($t,{key:t},e))),xt.createElement(Qc,null,o.map((e,t)=>e&&xt.createElement($t,{key:t},e)))),td=It(Li)`
|
|
1386
|
+
color: ${({theme:e})=>e.text.grey};
|
|
1387
|
+
`,od=({icon:e,title:t,badge:o,badgeTooltip:n,loading:i})=>xt.createElement(ya,{$gap:6},e&&xt.createElement(e,null),xt.createElement(td,{size:14},t),void 0!==o&&xt.createElement(vr,{text:n},xt.createElement(ma,{label:o})),i&&xt.createElement(cs,null)),nd=It.div`
|
|
1388
|
+
width: fit-content;
|
|
1389
|
+
height: fit-content;
|
|
1390
|
+
padding: 4px;
|
|
1391
|
+
gap: 4px;
|
|
1392
|
+
border-radius: 32px;
|
|
1393
|
+
border: 1px solid ${({theme:e})=>e.colors.border+Si.opacity.hex["070"]};
|
|
1394
|
+
|
|
1395
|
+
display: flex;
|
|
1396
|
+
flex-direction: ${({$orientation:e,$flip:t})=>("horizontal"===e?"row":"column")+(t?"-reverse":"")};
|
|
1397
|
+
align-items: center;
|
|
1398
|
+
justify-content: center;
|
|
1399
|
+
`,id=It.div`
|
|
1400
|
+
width: 32px;
|
|
1401
|
+
height: 32px;
|
|
1402
|
+
|
|
1403
|
+
border-radius: 100%;
|
|
1404
|
+
background-color: ${({theme:e,$selected:t})=>t?e.colors.majestic_blue+Si.opacity.hex["070"]:e.colors.secondary+Si.opacity.hex["012"]};
|
|
1405
|
+
transition: background-color 0.3s;
|
|
1406
|
+
|
|
1407
|
+
display: flex;
|
|
1408
|
+
align-items: center;
|
|
1409
|
+
justify-content: center;
|
|
1410
|
+
|
|
1411
|
+
cursor: pointer;
|
|
1412
|
+
`,ad=({orientation:e="vertical",flip:t,mainIcons:o,subIcons:n})=>xt.createElement(nd,{$orientation:e,$flip:t},o.map(({icon:e,selected:t,onClick:o,tooltip:n},i)=>xt.createElement(vr,{key:`main-nav-icon-${i}`,text:n},xt.createElement(id,{$selected:t,onClick:o},xt.createElement(e,{size:20})))),!!o.length&&!!n.length&&xt.createElement(gr,{orientation:"vertical"===e?"horizontal":"vertical",margin:"0",length:"20px"}),n.map(({icon:e,selected:t,onClick:o,tooltip:n},i)=>xt.createElement(vr,{key:`sub-nav-icon-${i}`,text:n},xt.createElement(id,{$selected:t,onClick:o},xt.createElement(e,{size:20}))))),rd=It.div`
|
|
1413
|
+
display: flex;
|
|
1414
|
+
flex-direction: column;
|
|
1415
|
+
width: 100%;
|
|
1416
|
+
`,sd=It.div`
|
|
1417
|
+
display: flex;
|
|
1418
|
+
flex-direction: column;
|
|
1419
|
+
gap: 8px;
|
|
1420
|
+
`,ld=It.div`
|
|
1421
|
+
display: flex;
|
|
1422
|
+
align-items: center;
|
|
1423
|
+
gap: 16px;
|
|
1424
|
+
`,cd=It(Sr)`
|
|
1425
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1426
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
1427
|
+
`,dd=({initialValues:e=[],value:t,onChange:o,title:n,tooltip:i,required:a,errorMessage:r})=>{const[s,l]=yt(t||e);wt(()=>{s.length||l([""])},[]);const c=s.filter(e=>!!e.trim()),d=kt(JSON.stringify(c));wt(()=>{const e=JSON.stringify(c);d.current!==e&&(d.current=e,o&&o(c))},[c,o]);const p=(e,t)=>{l(o=>{const n=[...o];return n[t]=e,n})},u=s.length<=1,h=s.some(e=>""===e.trim()),m=u&&h;return xt.createElement(rd,null,xt.createElement(fl,{title:n,required:a,tooltip:i}),xt.createElement(sd,null,s.map((e,t)=>{const o=t===s.length-1;return xt.createElement(ld,{key:`input-list-${t}`},xt.createElement(El,{value:e,onChange:e=>p(e.target.value,t),hasError:!!r,autoFocus:On(e)&&!u&&o}),t===s.length-1&&xt.createElement(cd,{withBorder:!0,size:30,$disabled:h,onClick:h?void 0:()=>{l(e=>{const t=[...e];return t.push(""),t})}},xt.createElement(tt,null)),xt.createElement(cd,{size:30,$disabled:m,onClick:m?void 0:()=>(e=>{u?p("",e):l(t=>t.filter((t,o)=>o!==e))})(t)},xt.createElement(st,null)))})),!!r&&xt.createElement(Xi,null,r))},pd=({col:e,colIdx:t,row:o,rowIdx:n,rowsLength:i,maxWidth:a,handleChange:r,errorMessage:s,limitFieldsPerRow:l})=>{const{keyName:c,title:d,tooltip:p,placeholder:u,required:h,type:m,componentType:g,options:x,renderCondition:$}=e,f=o[c];return $&&!$(o)?null:xt.createElement("td",{key:`input-table-${n}-${c}`,style:{maxWidth:a,padding:"4px 6px 4px 0"}},(()=>{if(g===po.Dropdown){const e=x?.find(e=>e.id===f);return xt.createElement(Nl,{title:l?d:void 0,tooltip:l?p:void 0,placeholder:u,required:h,options:x||[],value:e,onSelect:e=>r(c,e.id,n),onDeselect:()=>r(c,"",n),hasError:!!s&&(!h||h&&On(f))})}{const e=i>1&&n===i-1&&0===t&&On(f);return xt.createElement(El,{title:l?d:void 0,tooltip:l?p:void 0,placeholder:u,type:m,required:h,autoFocus:e,value:f,onChange:({target:{value:e}})=>r(c,e,n),style:{maxWidth:a,paddingLeft:10},hasError:!!s&&(!h||h&&On(f))})}})())},ud=It.div`
|
|
1428
|
+
display: flex;
|
|
1429
|
+
flex-direction: column;
|
|
1430
|
+
width: 100%;
|
|
1431
|
+
`,hd=It.button`
|
|
1432
|
+
margin-top: ${({$marginTop:e})=>e};
|
|
1433
|
+
background: none;
|
|
1434
|
+
border: none;
|
|
1435
|
+
cursor: ${({disabled:e})=>e?"not-allowed":"pointer"};
|
|
1436
|
+
opacity: ${({disabled:e})=>e?.5:1};
|
|
1437
|
+
`,md=({columns:e,initialValues:t=[],value:o,onChange:n,errorMessage:i,limitFieldsPerRow:a,title:r=""})=>{const[s,l]=yt({}),[c,d]=yt(o||t),p=ft(()=>new Map(e.map(e=>[e.keyName,e])),[e]);wt(()=>{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 n=p.get(t);if((!n?.renderCondition||n.renderCondition(e))&&n?.required&&On(o))return!1}return!0}),h=kt(JSON.stringify(u)),m=u.length!==c.length,g=`${Math.floor(640/((a||e.length)+.4))}px`;wt(()=>{const e=JSON.stringify(u);h.current!==e&&(h.current=e,n&&n(u))},[u,n]);const x=(e,t,o)=>{d(n=>{const i=qo(n);return i[o][e]=t,i})},$=ft(()=>{if(a){const t=[];for(let o=0;;o+=a){const n=e.slice(o,o+a);if(!n.length)break;t.push(n)}return t}return[e]},[a,e]);return xt.createElement(ud,null,xt.createElement(fl,{title:r}),xt.createElement("table",{style:{borderCollapse:"collapse"}},!a&&xt.createElement("thead",null,xt.createElement("tr",null,e.map(({title:e,tooltip:t,required:o})=>xt.createElement("th",{key:`input-table-head-${e}`,style:{maxWidth:g}},xt.createElement(fl,{title:e,required:o,tooltip:t}))),xt.createElement("th",null))),xt.createElement("tbody",null,c.map((t,o)=>xt.createElement($t,{key:`input-table-row-${o}`},a&&o>0?xt.createElement("tr",null,xt.createElement("td",{colSpan:$.length},xt.createElement(gr,null))):null,$.map((n,r)=>xt.createElement("tr",{key:`input-table-matrix-${o}-${r}`},n.map((e,n)=>xt.createElement(pd,{key:`input-table-row-${o}-col-${n}`,col:e,colIdx:n,row:t,rowIdx:o,rowsLength:c.length,maxWidth:g,limitFieldsPerRow:a,errorMessage:i,handleChange:x})),0===r&&xt.createElement("td",null,xt.createElement(hd,{$marginTop:a?"24px":"0",onClick:()=>{return t=o,void(c.length>1?d(e=>e.filter((e,o)=>o!==t)):e.forEach(({keyName:e,type:o})=>x(e,o===uo.Number?"0":"",t)));var t}},xt.createElement(st,null))))))))),!!i&&xt.createElement(Xi,null,i),xt.createElement(vs,{onClick:()=>{d(e=>{const t=qo(e);return t.push(qo(s)),t})},disabled:m}))},gd=It.div`
|
|
1438
|
+
display: flex;
|
|
1439
|
+
flex-direction: column;
|
|
1440
|
+
width: 100%;
|
|
1441
|
+
`,xd=It.div`
|
|
1442
|
+
display: flex;
|
|
1443
|
+
flex-direction: column;
|
|
1444
|
+
gap: 8px;
|
|
1445
|
+
`,$d=It.div`
|
|
1446
|
+
display: flex;
|
|
1447
|
+
align-items: center;
|
|
1448
|
+
gap: 8px;
|
|
1449
|
+
`,fd=It.div`
|
|
1450
|
+
width: 100%;
|
|
1451
|
+
max-width: ${({$maxWidth:e})=>e?`${e}px`:"unset"};
|
|
1452
|
+
`,bd=It(Sr)`
|
|
1453
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1454
|
+
opacity: ${({$disabled:e})=>e?.5:1};
|
|
1455
|
+
`,yd={key:"",value:""},wd=({initialKeyValuePairs:e=[],value:t,onChange:o,title:n,tooltip:i,disabled:a,required:r,errorMessage:s,keyPlaceholder:l="Key",valuePlaceholder:c="Value",inputMaxWidth:d=300})=>{const[p,u]=yt(t||e);wt(()=>{p.length||u([{...yd}])},[]);const h=p.filter(({key:e,value:t})=>!On(e.trim())&&!On(t.trim())),m=kt(JSON.stringify(h));wt(()=>{const e=JSON.stringify(h);m.current!==e&&(m.current=e,o&&o(h))},[h,o]);const g=(e,t,o)=>{u(n=>{const i=[...n];return i[o][e]=t,i})},x=p.length<=1,$=a||p.some(({key:e,value:t})=>""===e.trim()||""===t.trim()),f=a||x&&$;return xt.createElement(gd,null,xt.createElement(fl,{title:n,required:r,tooltip:i}),xt.createElement(xd,null,p.map(({key:e,value:t},o)=>xt.createElement($d,{key:`key-value-input-list-${o}`},xt.createElement(fd,{$maxWidth:d},xt.createElement(El,{placeholder:l,disabled:a,value:e,onChange:e=>g("key",e.target.value,o),hasError:!!s&&(!r||r&&!e),autoFocus:On(t)&&!x&&o===p.length-1})),xt.createElement(fd,{$maxWidth:o===p.length-1?d-38:d},xt.createElement(El,{placeholder:c,disabled:a,value:t,onChange:e=>g("value",e.target.value,o),hasError:!!s&&(!r||r&&On(t)),autoFocus:!1})),o===p.length-1&&xt.createElement(bd,{withBorder:!0,size:30,$disabled:$,onClick:$?void 0:()=>{u(e=>{const t=[...e];return t.push({...yd}),t})}},xt.createElement(tt,null)),xt.createElement(bd,{size:30,$disabled:f,onClick:f?void 0:()=>(e=>{x?(g("key","",e),g("value","",e)):u(t=>t.filter((t,o)=>o!==e))})(o)},xt.createElement(st,null))))),!!s&&xt.createElement(Xi,null,s))},kd=It.div`
|
|
1456
|
+
display: flex;
|
|
1457
|
+
flex-direction: ${({$isVertical:e})=>e?"column":"row"};
|
|
1458
|
+
gap: ${({$isVertical:e})=>e?"12px":"24px"};
|
|
1459
|
+
${({$hasError:e})=>e&&Ft`
|
|
1460
|
+
border: 1px solid ${({theme:e})=>e.text.error};
|
|
1461
|
+
border-radius: 32px;
|
|
1462
|
+
padding: 8px;
|
|
1463
|
+
`}
|
|
1464
|
+
`,vd=(e,t)=>!t?.length||!!t?.find(t=>t===e),Cd=({isVertical:e,title:t="Monitors",required:o,errorMessage:n,allowedSignals:i,selectedSignals:a,setSelectedSignals:r})=>{const[s,l]=yt(1===a.length),c=kt(JSON.stringify(a));return wt(()=>{const e=a;e.length||jo.forEach(({id:t})=>{vd(t,i)&&e.push(t)});const t=JSON.stringify(e);return c.current!==t&&(c.current=t,r(e),l(1===e.length)),()=>{c.current=""}},[i]),xt.createElement("div",null,t&&xt.createElement(fl,{title:t,required:o}),xt.createElement(kd,{$isVertical:e,$hasError:!!n},jo.map(e=>{const t=vd(e.id,i),o=((e,t)=>!!t?.find(t=>t===e))(e.id,a);return t?xt.createElement(Gr,{key:e.id,title:e.value,disabled:!t||s&&o,value:o,onChange:t=>((e,t)=>{const o=e,n=t?[...a,o]:a.filter(e=>e!==o);r(n),l(1===n.length)})(e.id,t)}):null})),!!n&&xt.createElement(Xi,null,n))},Ed=It.div`
|
|
1465
|
+
display: flex;
|
|
1466
|
+
gap: 8px;
|
|
1467
|
+
align-items: center;
|
|
1468
|
+
`,Sd=It(fa)`
|
|
1469
|
+
display: flex;
|
|
1470
|
+
align-items: center;
|
|
1471
|
+
justify-content: center;
|
|
1472
|
+
gap: 8px;
|
|
1473
|
+
min-width: 90px;
|
|
1474
|
+
`,Ad=({buttons:e})=>{const t=Si.useTheme(),o=({button:t,index:o})=>e.length>1&&0===o&&(t.icon||t.iconSrc),n=({button:e,rotate:o})=>e.icon?xt.createElement(e.icon,{size:14,rotate:o,fill:t.text[e.variant||"secondary"]}):e.iconSrc?xt.createElement("img",{src:e.iconSrc,alt:e.label,width:8,height:12}):null;return xt.createElement(Ed,null,e.map((e,t)=>xt.createElement(vr,{key:t,text:e.tooltip||""},xt.createElement(Sd,{key:t,variant:e.variant||"secondary",onClick:e.onClick,disabled:e.disabled},o({button:e,index:t})&&n({button:e,rotate:0}),e.label,!o({button:e,index:t})&&n({button:e,rotate:180})))))},Dd=It.div`
|
|
1475
|
+
height: ${({$height:e})=>e}px;
|
|
1476
|
+
width: 100%;
|
|
1477
|
+
overflow: auto;
|
|
1478
|
+
`,Td=It.div`
|
|
1479
|
+
height: ${({$height:e})=>e}px;
|
|
1480
|
+
width: 100%;
|
|
1481
|
+
position: relative;
|
|
1482
|
+
`,Nd=It.div`
|
|
1483
|
+
height: ${({$height:e})=>e}px;
|
|
1484
|
+
width: 100%;
|
|
1485
|
+
position: absolute;
|
|
1486
|
+
top: 0;
|
|
1487
|
+
left: 0;
|
|
1488
|
+
transform: translateY(${({$yOffset:e})=>e}px);
|
|
1489
|
+
`,Id=({containerHeight:e,elementHeight:t,elements:o})=>{const{overflowRef:n,listHeight:i,listItems:a}=Va({items:o,rowHeight:t});return xt.createElement(Dd,{ref:n,$height:e},xt.createElement(Td,{$height:i},a.map(({key:e,index:t,size:n,start:i})=>{const a=t>o.length-1,r=o[t];return xt.createElement(Nd,{key:e,$height:n,$yOffset:i},a?xt.createElement(ka,null,xt.createElement(Mi,null)):r)})))},zd=It.div`
|
|
1490
|
+
display: flex;
|
|
1491
|
+
justify-content: space-between;
|
|
1492
|
+
align-items: center;
|
|
1493
|
+
gap: 16px;
|
|
1494
|
+
`,Od=It.div`
|
|
1495
|
+
display: flex;
|
|
1496
|
+
flex-direction: column;
|
|
1497
|
+
gap: 4px;
|
|
1498
|
+
`,_d=It.div`
|
|
1499
|
+
display: flex;
|
|
1500
|
+
align-items: center;
|
|
1501
|
+
gap: 8px;
|
|
1502
|
+
`,Fd=It(Li)``,Rd=It(Li)``,Ld=({title:e,description:t,badgeLabel:o,icon:n,actionButton:i,size:a="medium"})=>{const r="small"===a?16:"medium"===a?20:24,s="small"===a?12:"medium"===a?14:16;return xt.createElement(zd,null,xt.createElement(Od,null,xt.createElement(_d,null,n&&xt.createElement(n,{size:r}),xt.createElement(Fd,{weight:300,size:r},e),void 0!==o&&xt.createElement(ma,{label:o,filled:!!o})),xt.createElement(Rd,{weight:200,opacity:.8,size:s},t)),i&&xt.createElement("div",null,i))},Bd=It.div`
|
|
1503
|
+
position: relative;
|
|
1504
|
+
gap: 0;
|
|
1505
|
+
z-index: 0;
|
|
1506
|
+
display: grid;
|
|
1507
|
+
grid-template-columns: repeat(${({$count:e})=>e}, 1fr);
|
|
1508
|
+
`,Pd=It.button`
|
|
1509
|
+
flex: 1;
|
|
1510
|
+
display: flex;
|
|
1511
|
+
align-items: center;
|
|
1512
|
+
justify-content: center;
|
|
1513
|
+
gap: 4px;
|
|
1514
|
+
padding: 6px 12px;
|
|
1515
|
+
background-color: transparent;
|
|
1516
|
+
border-radius: ${({$isFirstItem:e,$isLastItem:t})=>e?"32px 0px 0px 32px":t?"0px 32px 32px 0px":"0"};
|
|
1517
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1518
|
+
cursor: pointer;
|
|
1519
|
+
&:hover {
|
|
1520
|
+
border: 1px solid ${({theme:e})=>e.colors.secondary};
|
|
1521
|
+
}
|
|
1522
|
+
`,Md=It.div`
|
|
1523
|
+
position: absolute;
|
|
1524
|
+
top: ${({$y:e})=>e}px;
|
|
1525
|
+
left: ${({$x:e})=>e}px;
|
|
1526
|
+
z-index: -1;
|
|
1527
|
+
width: ${({$width:e})=>e}px;
|
|
1528
|
+
height: ${({$height:e})=>e}px;
|
|
1529
|
+
background-color: ${({theme:e,$bgColor:t})=>t||e.colors.dropdown_bg_2};
|
|
1530
|
+
border-radius: ${({$isFirstItem:e,$isLastItem:t})=>e?"32px 0px 0px 32px":t?"0px 32px 32px 0px":"0"};
|
|
1531
|
+
transition: all 0.3s;
|
|
1532
|
+
`,jd=({options:e=[],selected:t,setSelected:o})=>{const n=e.findIndex(e=>e.value===t),[i,a]=yt(e[n]?.selectedBgColor||""),[r,s]=yt({width:0,height:0}),[l,c]=yt({x:0,y:0}),d=kt(null);return wt(()=>{d.current&&(s({width:d.current.offsetWidth,height:d.current.offsetHeight}),c({x:d.current.offsetWidth*n,y:0}))},[t,n]),xt.createElement(Bd,{$count:e.length},e.map(({icon:n,label:i,value:r,selectedBgColor:s,selectedTextColor:l},c)=>{const p=t===r;return xt.createElement(Pd,{key:`segment-${i||c}-${r}`,ref:p?d:void 0,$isFirstItem:0===c,$isLastItem:c===e.length-1,onClick:()=>{o(r),a(s||"")}},n&&xt.createElement(n,null),i&&xt.createElement(Li,{size:12,family:"secondary",decoration:"underline",color:p?l:void 0},i))}),xt.createElement(Md,{$bgColor:i,$width:r.width,$height:r.height,$x:l.x,$y:l.y,$isFirstItem:0===n,$isLastItem:n===e.length-1}))},Ud=It(fa)`
|
|
1533
|
+
gap: 8px;
|
|
1534
|
+
text-transform: none;
|
|
1535
|
+
text-decoration: none;
|
|
1536
|
+
border: ${({theme:e,$withBorder:t})=>`1px solid ${t?e.colors.border:"transparent"}`};
|
|
1537
|
+
&.not-selected {
|
|
1538
|
+
background-color: ${({theme:e,$color:t})=>t||e.colors.dropdown_bg_2+Si.opacity.hex["060"]};
|
|
1539
|
+
&:hover {
|
|
1540
|
+
background-color: ${({theme:e,$hoverColor:t})=>t||e.colors.dropdown_bg_2};
|
|
1541
|
+
}
|
|
1542
|
+
}
|
|
1543
|
+
&.selected {
|
|
1544
|
+
background-color: ${({theme:e})=>e.colors.majestic_blue+Si.opacity.hex["030"]};
|
|
1545
|
+
}
|
|
1546
|
+
`,Wd=It(Li)`
|
|
1547
|
+
white-space: nowrap;
|
|
1548
|
+
overflow: hidden;
|
|
1549
|
+
text-overflow: ellipsis;
|
|
1550
|
+
font-size: 14px;
|
|
1551
|
+
`,Vd=({label:e,onClick:t,icon:o,iconSrc:n,badgeLabel:i,badgeFilled:a,isSelected:r,withBorder:s,color:l,hoverColor:c,style:d})=>{const p=Si.useTheme();return xt.createElement(Ud,{onClick:t,className:r?"selected":"not-selected",$withBorder:s,$color:l,$hoverColor:c,style:d},o&&xt.createElement("div",null,xt.createElement(o,{fill:p.text.info})),n&&xt.createElement("div",null,xt.createElement("img",{src:n,alt:"",width:16,height:16})),xt.createElement(Wd,null,e),r&&xt.createElement("div",null,xt.createElement(Ke,{fill:p.colors.majestic_blue_soft})),void 0!==i&&xt.createElement(ma,{label:i,filled:a||r}))},Hd=It.div`
|
|
1552
|
+
display: flex;
|
|
1553
|
+
flex-direction: column;
|
|
1554
|
+
gap: 16px;
|
|
1555
|
+
${({$maxWidth:e})=>e&&`max-width: ${e};`}
|
|
1556
|
+
`,qd=It.div`
|
|
1557
|
+
display: flex;
|
|
1558
|
+
align-items: center;
|
|
1559
|
+
gap: 16px;
|
|
1560
|
+
`,Gd=It.div`
|
|
1561
|
+
width: 50px;
|
|
1562
|
+
height: 50px;
|
|
1563
|
+
border-radius: 8px;
|
|
1564
|
+
background: ${({theme:e})=>`linear-gradient(90deg, ${e.colors.dropdown_bg_2} 25%, ${e.colors.dropdown_bg_2} 50%, ${e.colors.border} 75%)`};
|
|
1565
|
+
background-size: 200% 100%;
|
|
1566
|
+
animation: ${Si.animations.shimmer} 10s infinite linear;
|
|
1567
|
+
`,Kd=It(wa)`
|
|
1568
|
+
flex: 1;
|
|
1569
|
+
gap: 12px;
|
|
1570
|
+
`,Jd=It.div`
|
|
1571
|
+
width: ${({$width:e})=>e};
|
|
1572
|
+
height: 16px;
|
|
1573
|
+
background: ${({theme:e})=>`linear-gradient(90deg, ${e.colors.dropdown_bg_2} 25%, ${e.colors.dropdown_bg_2} 50%, ${e.colors.border} 75%)`};
|
|
1574
|
+
background-size: 200% 100%;
|
|
1575
|
+
animation: ${Si.animations.shimmer} 1.5s infinite linear;
|
|
1576
|
+
border-radius: 4px;
|
|
1577
|
+
`,Yd=({size:e=5,maxWidth:t})=>xt.createElement(Hd,{$maxWidth:t},[...Array(e)].map((e,t)=>xt.createElement(qd,{key:t},xt.createElement(Gd,null),xt.createElement(Kd,null,xt.createElement(Jd,{$width:"80%"}),xt.createElement(Jd,{$width:"100%"})))));var Xd;!function(e){e.Active="active",e.Disabled="disabled",e.Finished="finish"}(Xd||(Xd={}));const Qd=It.div`
|
|
1578
|
+
display: flex;
|
|
1579
|
+
flex-direction: column;
|
|
1580
|
+
gap: 32px;
|
|
1581
|
+
`,Zd=It.div`
|
|
1582
|
+
display: flex;
|
|
1583
|
+
gap: 16px;
|
|
1584
|
+
padding: 8px;
|
|
1585
|
+
opacity: ${({$state:e})=>e===Xd.Active?1:e===Xd.Disabled?.5:.8};
|
|
1586
|
+
transition: all 0.3s;
|
|
1587
|
+
`,ep=It(ya)`
|
|
1588
|
+
justify-content: center;
|
|
1589
|
+
width: 24px;
|
|
1590
|
+
height: 24px;
|
|
1591
|
+
border-radius: 32px;
|
|
1592
|
+
border: ${({theme:e,$state:t})=>t===Xd.Disabled?`1px dashed ${e.text.dark_grey}`:`1px solid ${e.colors.secondary}`};
|
|
1593
|
+
opacity: ${({$state:e})=>e===Xd.Finished?.8:1};
|
|
1594
|
+
`,tp=It(wa)`
|
|
1595
|
+
justify-content: center;
|
|
1596
|
+
gap: 8px;
|
|
1597
|
+
`,op=It(Li)``,np=It(Li)``,ip=({data:e,currentStep:t=0})=>{const[o,n]=yt([]);return wt(()=>{n(e.map((e,o)=>o<t-1?{...e,state:Xd.Finished,subtitle:e.subtitle||ho.Success}:o===t-1?{...e,state:Xd.Active,subtitle:""}:{...e,state:Xd.Disabled,subtitle:""}))},[t,e]),xt.createElement(Qd,null,o.map((e,t)=>xt.createElement(Zd,{key:t,$state:e.state},xt.createElement(ep,{$state:e.state},[Xd.Active,Xd.Disabled].includes(e.state)?xt.createElement(Li,{size:12},e.stepNumber):e.state===Xd.Finished?xt.createElement(Ke,{size:20}):null),xt.createElement(tp,null,xt.createElement(op,{family:"secondary"},e.title),e.subtitle&&xt.createElement(np,{size:10,weight:300},e.subtitle)))))},ap=It(ya)`
|
|
1598
|
+
width: fit-content;
|
|
1599
|
+
gap: 6px;
|
|
1600
|
+
padding: 6px 12px;
|
|
1601
|
+
border-radius: 360px;
|
|
1602
|
+
background-color: ${({$type:e,theme:t})=>t.colors[e]};
|
|
1603
|
+
`,rp=It(Li)`
|
|
1604
|
+
color: ${({$type:e,theme:t})=>t.text[e]};
|
|
1605
|
+
`,sp=({type:e=ho.Info,icon:t,title:o,size:n,family:i,children:a,...r})=>xt.createElement(ap,{$type:e},t&&xt.createElement(t,null),xt.createElement(rp,{$type:e,size:n||12,family:i||"secondary",...r},a||o)),lp=It.div`
|
|
1606
|
+
display: flex;
|
|
1607
|
+
flex-direction: column;
|
|
1608
|
+
position: relative;
|
|
1609
|
+
width: 100%;
|
|
1610
|
+
`,cp=It.div`
|
|
1611
|
+
width: 100%;
|
|
1612
|
+
display: flex;
|
|
1613
|
+
align-items: center;
|
|
1614
|
+
gap: 12px;
|
|
1615
|
+
transition: border-color 0.3s;
|
|
1616
|
+
border-radius: 24px;
|
|
1617
|
+
border: 1px solid ${({theme:e})=>e.colors.border};
|
|
1618
|
+
${({$disabled:e})=>e&&Ft`
|
|
1619
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
1620
|
+
cursor: not-allowed;
|
|
1621
|
+
opacity: 0.6;
|
|
1622
|
+
`}
|
|
1623
|
+
|
|
1624
|
+
${({$hasError:e})=>e&&Ft`
|
|
1625
|
+
border-color: ${({theme:e})=>e.text.error};
|
|
1626
|
+
`}
|
|
1627
|
+
|
|
1628
|
+
${({$isActive:e})=>e&&Ft`
|
|
1629
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1630
|
+
`}
|
|
1631
|
+
|
|
1632
|
+
&:hover {
|
|
1633
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1634
|
+
}
|
|
1635
|
+
&:focus-within {
|
|
1636
|
+
border-color: ${({theme:e})=>e.colors.secondary};
|
|
1637
|
+
}
|
|
1638
|
+
`,dp=It.textarea`
|
|
1639
|
+
flex: 1;
|
|
1640
|
+
border: none;
|
|
1641
|
+
outline: none;
|
|
1642
|
+
background: none;
|
|
1643
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1644
|
+
font-size: 14px;
|
|
1645
|
+
padding: 12px 20px 0;
|
|
1646
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1647
|
+
font-weight: 300;
|
|
1648
|
+
line-height: 22px;
|
|
1649
|
+
&::placeholder {
|
|
1650
|
+
color: ${({theme:e})=>e.text.secondary};
|
|
1651
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1652
|
+
opacity: 0.4;
|
|
1653
|
+
font-size: 14px;
|
|
1654
|
+
font-weight: 300;
|
|
1655
|
+
line-height: 22px; /* 157.143% */
|
|
1656
|
+
}
|
|
1657
|
+
|
|
1658
|
+
&:disabled {
|
|
1659
|
+
background-color: ${({theme:e})=>e.colors.border};
|
|
1660
|
+
cursor: not-allowed;
|
|
1661
|
+
}
|
|
1662
|
+
`,pp=({errorMessage:e,title:t,tooltip:o,required:n,onChange:i,name:a,...r})=>{const s=kt(null),l=e=>{s.current&&(s.current.style.height="auto",e&&(s.current.style.height=`${s.current.scrollHeight}px`))};return xt.createElement(lp,null,xt.createElement(fl,{title:t,required:n,tooltip:o}),xt.createElement(cp,{$disabled:r.disabled,$hasError:!!e,$isActive:!!r.autoFocus},xt.createElement(dp,{ref:s,"data-id":a,name:a,onFocus:()=>l(!0),onBlur:()=>l(!1),onChange:e=>{e.stopPropagation(),l(!0),i?.(e)},onKeyDown:e=>{e.stopPropagation()},...r})),!!e&&xt.createElement(Xi,null,e))},up=It.div`
|
|
1663
|
+
display: flex;
|
|
1664
|
+
align-items: center;
|
|
1665
|
+
gap: 12px;
|
|
1666
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1667
|
+
opacity: ${({$disabled:e})=>e?.6:1};
|
|
1668
|
+
`,hp=It.div`
|
|
1669
|
+
width: 24px;
|
|
1670
|
+
height: 12px;
|
|
1671
|
+
border: 1px ${({$isActive:e,theme:t})=>e?`solid ${t.colors.majestic_blue}`:`dashed ${t.text.grey}`};
|
|
1672
|
+
border-radius: 20px;
|
|
1673
|
+
display: flex;
|
|
1674
|
+
align-items: center;
|
|
1675
|
+
padding: 2px;
|
|
1676
|
+
background-color: transparent;
|
|
1677
|
+
pointer-events: ${({$disabled:e})=>e?"none":"auto"};
|
|
1678
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1679
|
+
opacity: ${({$isActive:e})=>e?1:.5};
|
|
1680
|
+
transition: border-color 0.3s, opacity 0.3s;
|
|
1681
|
+
&::before {
|
|
1682
|
+
content: '';
|
|
1683
|
+
width: 12px;
|
|
1684
|
+
height: 12px;
|
|
1685
|
+
border-radius: 50%;
|
|
1686
|
+
background-color: ${({$isActive:e,theme:t})=>e?t.colors.majestic_blue:t.colors.secondary};
|
|
1687
|
+
transform: ${({$isActive:e})=>e?"translateX(12px)":"translateX(0)"};
|
|
1688
|
+
transition: background-color 0.3s, transform 0.3s;
|
|
1689
|
+
}
|
|
1690
|
+
`,mp=({title:e,tooltip:t,initialValue:o=!1,onChange:n,disabled:i,allowPropagation:a=!1,flipHorizontally:r})=>{const[s,l]=yt(o);return wt(()=>l(o),[o]),xt.createElement(up,{$disabled:i,onClick:e=>{i||(a||e.stopPropagation(),n?n(!s):l(e=>!e))}},!r&&xt.createElement(hp,{$disabled:i,$isActive:s}),(e||t)&&xt.createElement(vr,{text:t,withIcon:!0},e&&xt.createElement(Li,{size:14},e)),r&&xt.createElement(hp,{$disabled:i,$isActive:s}))};var gp={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 xp=It.div`
|
|
1691
|
+
width: ${({$width:e})=>e}px;
|
|
1692
|
+
height: ${({$height:e})=>e}px;
|
|
1693
|
+
position: relative;
|
|
1694
|
+
`,$p=({width:e=620})=>{const{darkMode:t}=Si.useTheme(),o=e/(620/220),n=e;return xt.createElement(xp,{$width:n,$height:o},xt.createElement(Ht,{autoplay:!0,loop:!0,animationData:gp,style:{width:o,height:n,transform:"rotate(-90deg)",position:"absolute",top:-(o-o/10),left:o-o/10,filter:t?"invert(0)":"invert(1)"}}))},fp=({buttons:e})=>xt.createElement(wa,{$gap:12},e.map(e=>xt.createElement(Ki,{key:e.label,...e}))),bp=It.div`
|
|
1695
|
+
display: flex;
|
|
1696
|
+
align-items: center;
|
|
1697
|
+
flex-wrap: wrap;
|
|
1698
|
+
width: calc(100% - 24px);
|
|
1699
|
+
padding: 4px 12px;
|
|
1700
|
+
border-radius: 12px;
|
|
1701
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1702
|
+
`,yp=It.div`
|
|
1703
|
+
width: calc(${({$cellsPerRow:e})=>100/e+"%"} - 16px);
|
|
1704
|
+
margin: 8px;
|
|
1705
|
+
display: flex;
|
|
1706
|
+
flex-direction: column;
|
|
1707
|
+
gap: 4px;
|
|
1708
|
+
`,wp=({cellsPerRow:e,items:t})=>{const o=_t(),{CopyButton:n}=Ma();return xt.createElement(bp,null,t.map(({id:i,title:a,label:r,withCopy:s,badge:l})=>xt.createElement(yp,{key:i,$cellsPerRow:e||t.length},xt.createElement(Ni,{size:Di.XXXS,color:o.v2.colors.silver[200],nowrap:!0},a),xt.createElement(ya,{$gap:4},l&&xt.createElement(zi,{...l}),r&&xt.createElement(Ni,{size:Di.XS,nowrap:!0},r),s&&xt.createElement(n,{value:r||l?.label?.toString()||"",size:La.XS})))))},kp=It.div`
|
|
1709
|
+
width: ${({$width:e})=>e||"unset"};
|
|
1710
|
+
padding: 6px 12px;
|
|
1711
|
+
display: flex;
|
|
1712
|
+
align-self: stretch;
|
|
1713
|
+
align-items: center;
|
|
1714
|
+
gap: 8px;
|
|
1715
|
+
border-radius: 6px;
|
|
1716
|
+
|
|
1717
|
+
border: none;
|
|
1718
|
+
border-radius: 6px;
|
|
1719
|
+
background: ${({$isHovered:e,$isActive:t,theme:o})=>e||t?o.v2.colors.silver[700]:o.v2.colors.silver[800]};
|
|
1720
|
+
`,vp=It.input`
|
|
1721
|
+
flex: 1;
|
|
1722
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1723
|
+
font-size: 14px;
|
|
1724
|
+
font-weight: 400;
|
|
1725
|
+
line-height: 20px;
|
|
1726
|
+
|
|
1727
|
+
cursor: text;
|
|
1728
|
+
color: ${({$textColor:e})=>e};
|
|
1729
|
+
&::placeholder {
|
|
1730
|
+
color: ${({$textColor:e})=>e};
|
|
1731
|
+
}
|
|
1732
|
+
|
|
1733
|
+
overflow: hidden;
|
|
1734
|
+
text-overflow: ellipsis;
|
|
1735
|
+
white-space: nowrap;
|
|
1736
|
+
`,Cp=({placeholder:e="Search...",value:t,onChange:o,width:n})=>{const i=Si.useTheme(),[a,r]=yt(!1),[s,l]=yt(!1),c=s?i.v2.colors.white[500]:i.v2.colors.silver[200];return xt.createElement(kp,{$width:n,onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1),$isHovered:a,$isActive:s},xt.createElement(rt,{size:18,fill:c}),xt.createElement(vp,{"data-id":"search",name:"search",type:"text",placeholder:e,value:t,onChange:e=>{e.stopPropagation(),o(e.target.value)},onFocus:()=>l(!0),onBlur:()=>l(!1),$textColor:c}))};var Ep;!function(e){e.S="small",e.L="large"}(Ep||(Ep={}));const Sp=It.div`
|
|
1737
|
+
width: fit-content;
|
|
1738
|
+
display: flex;
|
|
1739
|
+
align-items: center;
|
|
1740
|
+
gap: 8px;
|
|
1741
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
1742
|
+
`,Ap=It.div`
|
|
1743
|
+
width: ${({$size:e})=>e===Ep.S?"16px":"20px"};
|
|
1744
|
+
height: ${({$size:e})=>e===Ep.S?"16px":"20px"};
|
|
1745
|
+
display: flex;
|
|
1746
|
+
align-items: center;
|
|
1747
|
+
justify-content: center;
|
|
1748
|
+
border-radius: 4px;
|
|
1749
|
+
border: 1px solid ${({$borderColor:e})=>e};
|
|
1750
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
1751
|
+
`,Dp=({label:e,size:t=Ep.L,disabled:o,partiallyChecked:n,value:i,onChange:a})=>{const r=Si.useTheme(),[s,l]=yt(!1),c=n||i,d=t===Ep.S?8:12,p=o?r.v2.colors.grey[400]:r.v2.colors.white[500],u=c?"transparent":o?r.v2.colors.grey[700]:s?r.v2.colors.silver[400]:r.v2.colors.silver[600],h=o?r.v2.colors.grey[600]:c?r.v2.colors.purple[500]:r.v2.colors.silver[900];return xt.createElement(Sp,{"data-id":"checkbox"+(e?`-${e}`:""),onClick:e=>{e.stopPropagation(),o||a(!!n||!i)},$disabled:o,onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1)},xt.createElement(Ap,{$size:t,$borderColor:u,$backgroundColor:h},n?xt.createElement(Xe,{size:d,fill:p}):i?xt.createElement(Ke,{size:d,fill:p}):null),e&&xt.createElement(Ni,{size:t===Ep.S?Di.XXS:Di.XS},e))};var Tp;!function(e){e.Left="left",e.Right="right"}(Tp||(Tp={}));const Np=It.div`
|
|
1752
|
+
position: relative;
|
|
1753
|
+
`,Ip=It.div`
|
|
1754
|
+
display: flex;
|
|
1755
|
+
flex-direction: column;
|
|
1756
|
+
gap: 0;
|
|
1757
|
+
min-width: 150px;
|
|
1758
|
+
width: fit-content;
|
|
1759
|
+
padding: 8px;
|
|
1760
|
+
border-radius: 6px;
|
|
1761
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[900]};
|
|
1762
|
+
box-shadow: 0 0 24px 0 rgba(0, 0, 0, 0.3);
|
|
1763
|
+
position: absolute;
|
|
1764
|
+
top: ${({$withButton:e})=>e?"calc(100% + 8px)":"0"};
|
|
1765
|
+
${({$align:e})=>`${e}: 0;`}
|
|
1766
|
+
`,zp=It.div`
|
|
1767
|
+
display: flex;
|
|
1768
|
+
align-items: center;
|
|
1769
|
+
gap: 8px;
|
|
1770
|
+
width: calc(100% - 16px);
|
|
1771
|
+
padding: 8px;
|
|
1772
|
+
border-radius: 6px;
|
|
1773
|
+
cursor: pointer;
|
|
1774
|
+
${({$selected:e})=>e?Ft`
|
|
1775
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
1776
|
+
`:Ft`
|
|
1777
|
+
background-color: transparent;
|
|
1778
|
+
&:hover {
|
|
1779
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[700]};
|
|
1780
|
+
}
|
|
1781
|
+
`}
|
|
1782
|
+
`,Op=({items:e,selectedId:t,onSelect:o,defaultOpen:n,buttonProps:i})=>{const a=_t(),[r,s]=yt(Tp.Left),[l,c]=yt(n??!i),d=e=>{o(e),i&&c(!1)};return xt.createElement(Np,null,i&&xt.createElement(Vi,{...i,rightIcon:l?pt:ut,onClick:e=>{s(e.clientX>window.innerWidth/2?Tp.Right:Tp.Left),c(e=>!e)}}),l&&xt.createElement(Ip,{$withButton:!!i,$align:r},e.map(({id:e,label:o,icon:n,withCheckbox:i})=>{const r=t===e;return xt.createElement(zp,{key:e,$selected:r,onClick:()=>d(e)},i&&xt.createElement(Dp,{value:r,onChange:()=>d(e)}),n&&xt.createElement(n,{size:14,fill:a.v2.colors.white[500]}),xt.createElement(Ni,{size:Di.XS,nowrap:!0},o))})))};var _p,Fp;!function(e){e.S="small",e.M="medium"}(_p||(_p={})),function(e){e.Button="button",e.ButtonDropData="button-drop-data"}(Fp||(Fp={}));const Rp=It.div`
|
|
1783
|
+
display: flex;
|
|
1784
|
+
flex-direction: column;
|
|
1785
|
+
gap: ${({$gap:e})=>e}px;
|
|
1786
|
+
padding: ${({$padding:e})=>e}px;
|
|
1787
|
+
border-radius: 16px;
|
|
1788
|
+
background-color: ${({$backgroundWeight:e,theme:t})=>t.v2.colors.silver[e]};
|
|
1789
|
+
`,Lp=({size:e=_p.M,backgroundWeight:t="900",icon:o,title:n,withCopyTitle:i,badge:a,search:r,actions:s,children:l})=>{const{CopyButton:c}=Ma(),d=e===_p.S?4:16,p=e===_p.S?12:16;return xt.createElement(Rp,{$padding:p,$gap:d,$backgroundWeight:t},xt.createElement(ya,{$justifyContent:"space-between"},xt.createElement(ya,{$gap:8,$alignItems:"center"},xt.createElement(o,{size:24}),xt.createElement(Ni,null,n),i&&xt.createElement(c,{value:n,size:La.XS}),a&&xt.createElement(zi,{...a}),r&&xt.createElement(Cp,{...r})),xt.createElement(ya,{$gap:8,$alignItems:"center"},s?.map(e=>{switch(e.type){case Fp.Button:return xt.createElement(Vi,{key:e.id,...e.buttonProps,label:e.buttonProps?.label??""});case Fp.ButtonDropData:return xt.createElement(Op,{key:e.id,items:e.dropDataItems??[],selectedId:"",onSelect:t=>e.buttonProps?.onClick?.(t),buttonProps:e.buttonProps});default:return null}}))),l)},Bp=It.div`
|
|
1790
|
+
flex: 1;
|
|
1791
|
+
align-self: stretch;
|
|
1792
|
+
display: flex;
|
|
1793
|
+
align-items: center;
|
|
1794
|
+
gap: 8px;
|
|
1795
|
+
padding: 16px;
|
|
1796
|
+
border-radius: 12px;
|
|
1797
|
+
background-color: ${({theme:e,$status:t})=>Cn(e,t,t===xo.Unknown?"750":"500")};
|
|
1798
|
+
`,Pp=It.div`
|
|
1799
|
+
display: flex;
|
|
1800
|
+
align-items: center;
|
|
1801
|
+
justify-content: center;
|
|
1802
|
+
width: fit-content;
|
|
1803
|
+
height: fit-content;
|
|
1804
|
+
padding: 8px;
|
|
1805
|
+
border-radius: 12px;
|
|
1806
|
+
background-color: ${({theme:e,$status:t})=>t===xo.Unknown?Cn(e,t,"800"):Cn(e,t,"900")+Si.opacity.hex["015"]};
|
|
1807
|
+
`,Mp=({status:e,icon:t,title:o,description:n})=>{const i=_t(),a=t??Sn(e,i),r=[ho.Default,ho.Info,xo.Disabled,xo.Unknown].includes(e)?i.v2.colors.white[500]:i.v2.colors.black[500];return xt.createElement(Bp,{$status:e},xt.createElement(Pp,{$status:e},xt.createElement(a,{size:32,fill:r})),xt.createElement(wa,{$gap:2,$justifyContent:"center"},xt.createElement(Ni,{size:Di.M,weight:500,color:r,nowrap:!0},o),xt.createElement(Ni,{size:Di.XXS,weight:300,color:r,nowrap:!0},n)))},jp=It.div`
|
|
1808
|
+
flex: 1;
|
|
1809
|
+
align-self: stretch;
|
|
1810
|
+
display: flex;
|
|
1811
|
+
flex-direction: column;
|
|
1812
|
+
gap: 12px;
|
|
1813
|
+
padding: 12px;
|
|
1814
|
+
border-radius: 12px;
|
|
1815
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1816
|
+
`,Up=["-","N/A"],Wp=({title:e,cells:t})=>{const o=_t();return xt.createElement(jp,null,xt.createElement(Ni,{size:Di.XXS,color:o.v2.colors.grey[150]},e),xt.createElement(ya,{$gap:32},t.map(t=>xt.createElement(wa,{key:`${e}-${t.label}-${t.value}`,$gap:2},!t.isLoading||t.value&&!Up.includes(t.value)?xt.createElement(Ni,{size:t.label?Di.M:Di.L},t.value):xt.createElement(cs,{scale:.9}),t.label&&xt.createElement(Ni,{size:Di.XXS},t.label)))))},Vp=It.div`
|
|
1817
|
+
display: flex;
|
|
1818
|
+
flex-direction: ${({$direction:e})=>e===to.Horizontal?"row":"column"};
|
|
1819
|
+
gap: ${({$direction:e})=>e===to.Horizontal?16:8}px;
|
|
1820
|
+
`,Hp=({direction:e=to.Vertical,title:t,size:o,disabled:n,withSelectAll:i,options:a,values:r,setValues:s})=>{const l=o===Ep.S?Di.XXS:Di.XS,c=ft(()=>a.every(e=>r[e.id]),[a,r]),d=ft(()=>a.some(e=>r[e.id])&&a.some(e=>!r[e.id]),[a,r]),p=(e,t)=>{s(o=>{const n={...o};return e?n[e]=t:a.forEach(e=>n[e.id]=t),n})};return xt.createElement(Vp,{$direction:e},t&&i?xt.createElement(Dp,{label:t,partiallyChecked:d,value:c,onChange:e=>p("",e),size:o}):t&&!i?xt.createElement(Ni,{size:l},t):null,a.map(e=>xt.createElement(Dp,{key:`${t}-checkbox-${e.id}`,...e,value:r[e.id],onChange:t=>p(e.id,t),disabled:n,size:o})))},qp=It(ya)`
|
|
1821
|
+
width: calc(100% - 20px);
|
|
1822
|
+
padding: 10px;
|
|
1823
|
+
border-radius: 6px;
|
|
1824
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[800]};
|
|
1825
|
+
display: flex;
|
|
1826
|
+
align-items: center;
|
|
1827
|
+
justify-content: space-between;
|
|
1828
|
+
gap: 12px;
|
|
1829
|
+
`,Gp=It.div`
|
|
1830
|
+
position: relative;
|
|
1831
|
+
width: ${({$hideCopy:e})=>e?"100%":"calc(100% - 24px - 12px)"};
|
|
1832
|
+
display: flex;
|
|
1833
|
+
align-items: center;
|
|
1834
|
+
gap: 4px;
|
|
1835
|
+
`,Kp=It.pre`
|
|
1836
|
+
flex: 1;
|
|
1837
|
+
margin: 0;
|
|
1838
|
+
padding: 0;
|
|
1839
|
+
font-size: 14px;
|
|
1840
|
+
color: #5ffb98; // TODO: add to theme
|
|
1841
|
+
overflow-x: auto;
|
|
1842
|
+
`,Jp=It.span`
|
|
1843
|
+
flex-shrink: 0;
|
|
1844
|
+
font-size: 14px;
|
|
1845
|
+
color: #5ffb98; // TODO: add to theme
|
|
1846
|
+
`,Yp=({value:e,hideCopy:t=!1,onDone:o})=>{const{CopyButton:n}=Ma({onDone:o}),i=kt(null),[a,r]=yt(!1);return wt(()=>{const e=()=>{if(i.current){const{scrollWidth:e,clientWidth:t}=i.current;r(e>t)}};e();const t=new ResizeObserver(e);return i.current&&t.observe(i.current),()=>{t.disconnect()}},[e]),xt.createElement(qp,null,xt.createElement(Gp,{$hideCopy:t},xt.createElement(Kp,{ref:i},e),a&&xt.createElement(Jp,null,"...")),!t&&xt.createElement(n,{value:e,size:La.XS}))},Xp=It.div`
|
|
1847
|
+
display: flex;
|
|
1848
|
+
align-items: center;
|
|
1849
|
+
justify-content: space-between;
|
|
1850
|
+
width: calc(100% - 24px);
|
|
1851
|
+
padding: 12px;
|
|
1852
|
+
`,Qp=It.div`
|
|
1853
|
+
display: flex;
|
|
1854
|
+
align-items: center;
|
|
1855
|
+
gap: 16px;
|
|
1856
|
+
`,Zp=It.div`
|
|
1857
|
+
display: flex;
|
|
1858
|
+
align-items: center;
|
|
1859
|
+
justify-content: center;
|
|
1860
|
+
width: 32px;
|
|
1861
|
+
height: 32px;
|
|
1862
|
+
border-radius: 8px;
|
|
1863
|
+
background: ${({theme:e})=>e.v2.colors.silver[800]};
|
|
1864
|
+
`,eu=It.div`
|
|
1865
|
+
display: flex;
|
|
1866
|
+
align-items: center;
|
|
1867
|
+
gap: 12px;
|
|
1868
|
+
`,tu=({icon:e,title:t,actions:o,onClose:n})=>xt.createElement(Xp,null,xt.createElement(Qp,null,xt.createElement(Zp,null,xt.createElement(e,{size:24})),xt.createElement(Ni,{size:Di.S},t)),xt.createElement(eu,null,o?.length?xt.createElement(Pa,{icon:ht,size:La.M,onClick:()=>alert("todo")}):null,xt.createElement(Pa,{icon:Ye,size:La.M,onClick:n}))),ou=It.div`
|
|
1869
|
+
position: fixed;
|
|
1870
|
+
top: 0;
|
|
1871
|
+
bottom: 0;
|
|
1872
|
+
${({$position:e})=>e}: 0;
|
|
1873
|
+
z-index: 1000;
|
|
1874
|
+
width: ${({$width:e})=>e};
|
|
1875
|
+
border-radius: ${({$position:e})=>"left"===e?"0 20px 20px 0":"20px 0 0 20px"};
|
|
1876
|
+
background: ${({theme:e})=>e.v2.colors.silver[1e3]};
|
|
1877
|
+
box-shadow: 0 0 34px 0 rgba(0, 0, 0, 0.7);
|
|
1878
|
+
overflow: hidden;
|
|
1879
|
+
|
|
1880
|
+
animation-name: ${({$position:e})=>Si.animations.slide.in[e]};
|
|
1881
|
+
`,nu=It.div`
|
|
1882
|
+
display: flex;
|
|
1883
|
+
flex-direction: column;
|
|
1884
|
+
gap: 16px;
|
|
1885
|
+
height: calc(100% - ${56}px - 32px);
|
|
1886
|
+
padding: 16px;
|
|
1887
|
+
border-radius: ${({$position:e})=>"left"===e?"20px 20px 20px 0":"20px 20px 0 20px"};
|
|
1888
|
+
background: ${({theme:e})=>e.v2.colors.black[500]};
|
|
1889
|
+
overflow-y: auto;
|
|
1890
|
+
`,iu=({isOpen:e,hideOverlay:t=!1,position:o="right",width:n="40vw",header:i,children:a})=>(za(e),e?jt(xt.createElement(xt.Fragment,null,!t&&xt.createElement(Ca,{hidden:!e,onClick:i.onClose}),xt.createElement(ou,{$position:o,$width:n},xt.createElement(tu,{...i}),xt.createElement(nu,{$position:o},a))),document.body):null),au=It.header`
|
|
1891
|
+
position: relative;
|
|
1892
|
+
width: calc(100% - 36px);
|
|
1893
|
+
padding: 12px 18px;
|
|
1894
|
+
background-color: ${({theme:e})=>e.v2.colors.black[500]};
|
|
1895
|
+
display: flex;
|
|
1896
|
+
align-items: center;
|
|
1897
|
+
justify-content: space-between;
|
|
1898
|
+
`,ru=It(ya)`
|
|
1899
|
+
position: absolute;
|
|
1900
|
+
left: 50%;
|
|
1901
|
+
transform: translateX(-50%);
|
|
1902
|
+
gap: 16px;
|
|
1903
|
+
`,su=({left:e=[],center:t=[],right:o=[]})=>xt.createElement(au,null,xt.createElement(ya,{$gap:16},e),xt.createElement(ru,null,t),xt.createElement(ya,{$gap:16},o)),lu=It.span`
|
|
1904
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1905
|
+
font-size: 14px;
|
|
1906
|
+
font-weight: 400;
|
|
1907
|
+
color: ${({theme:e})=>e.text.error};
|
|
1908
|
+
`,cu=It.span`
|
|
1909
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1910
|
+
font-size: 14px;
|
|
1911
|
+
font-weight: 400;
|
|
1912
|
+
color: ${({theme:e})=>e.v2.colors.silver[200]};
|
|
1913
|
+
`,du=It.div`
|
|
1914
|
+
padding: 12px;
|
|
1915
|
+
display: flex;
|
|
1916
|
+
align-self: stretch;
|
|
1917
|
+
align-items: center;
|
|
1918
|
+
gap: 8px;
|
|
1919
|
+
border-radius: 6px;
|
|
1920
|
+
|
|
1921
|
+
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]};
|
|
1922
|
+
background: ${({theme:e,$disabled:t})=>t?e.v2.colors.grey[800]:e.v2.colors.black[500]};
|
|
1923
|
+
${({$disabled:e,$error:t})=>!e&&!t&&Ft`
|
|
1924
|
+
&:hover,
|
|
1925
|
+
&:active,
|
|
1926
|
+
&:focus-within {
|
|
1927
|
+
border: 1px solid ${({theme:e})=>e.v2.colors.silver[300]};
|
|
1928
|
+
}
|
|
1929
|
+
`}
|
|
1930
|
+
`,pu=It.input`
|
|
1931
|
+
flex: 1;
|
|
1932
|
+
font-family: ${({theme:e})=>e.font_family.primary};
|
|
1933
|
+
font-size: 14px;
|
|
1934
|
+
font-weight: 400;
|
|
1935
|
+
line-height: 22px;
|
|
1936
|
+
|
|
1937
|
+
cursor: text;
|
|
1938
|
+
color: ${({theme:e})=>e.v2.colors.white[500]};
|
|
1939
|
+
&::placeholder {
|
|
1940
|
+
color: ${({theme:e})=>e.v2.colors.silver[200]};
|
|
1941
|
+
}
|
|
1942
|
+
|
|
1943
|
+
&:disabled {
|
|
1944
|
+
cursor: not-allowed;
|
|
1945
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
1946
|
+
&::placeholder {
|
|
1947
|
+
color: ${({theme:e})=>e.v2.colors.grey[400]};
|
|
1948
|
+
}
|
|
1949
|
+
}
|
|
1950
|
+
|
|
1951
|
+
overflow: hidden;
|
|
1952
|
+
text-overflow: ellipsis;
|
|
1953
|
+
white-space: nowrap;
|
|
1954
|
+
`,uu=It.div`
|
|
1955
|
+
cursor: pointer;
|
|
1956
|
+
`,hu=({label:e,required:t,tooltip:o,leftIcon:n,rightIcon:i,errorMessage:a,helpMessage:r,type:s=uo.Text,name:l,value:c,onChange:d,disabled:p,...u})=>{const h=Si.useTheme(),m=s===uo.Password,[g,x]=yt(!1),$=c?h.v2.colors.white[500]:p?h.v2.colors.grey[400]:h.v2.colors.silver[200];return xt.createElement(wa,{$gap:6},xt.createElement(ya,{$justifyContent:"space-between"},e&&xt.createElement(cu,null,e),xt.createElement(ya,{$gap:10},o&&xt.createElement(vr,{text:o,withIcon:!0}),t&&xt.createElement(lu,null,"*"))),xt.createElement(du,{$disabled:p,$error:!!a},n?xt.createElement(n,{size:18,fill:$}):null,xt.createElement(pu,{"data-id":l,type:g||s===uo.Number?uo.Text:s,name:l,value:c,onChange:e=>{e.stopPropagation(),s===uo.Number&&(e.target.value=Vn(e.target.value)),d?.(e)},onKeyDown:e=>{["Enter"].includes(e.key)||e.stopPropagation()},disabled:p,...u}),m?xt.createElement(uu,{onClick:()=>x(e=>!e)},g?xt.createElement(it,{size:18,strokeWidth:2,fill:$}):xt.createElement(at,{size:18,strokeWidth:2,fill:$})):i?xt.createElement(i,{size:18,fill:$}):null),a?xt.createElement(ya,{$gap:4},xt.createElement(je,{size:12,fill:h.v2.colors.red[500]}),xt.createElement(Ni,{size:Di.XXS,weight:400,color:h.v2.colors.red[500]},a)):r?xt.createElement(ya,{$gap:4},xt.createElement(je,{size:12,fill:h.v2.colors.silver[200]}),xt.createElement(Ni,{size:Di.XXS,weight:400,color:h.v2.colors.silver[200]},r)):null)},mu=Ot`
|
|
1957
|
+
0% {
|
|
1958
|
+
background-position: 0% 50%;
|
|
1959
|
+
}
|
|
1960
|
+
100% {
|
|
1961
|
+
background-position: 100% 50%;
|
|
1962
|
+
}
|
|
1963
|
+
`,gu=It(Ni)`
|
|
1964
|
+
display: flex;
|
|
1965
|
+
align-items: center;
|
|
1966
|
+
gap: 4px;
|
|
1967
|
+
|
|
1968
|
+
background: ${({$textColor:e,$stripColor:t})=>`linear-gradient(45deg, ${e} 0%, ${e} 40%, ${t} 50%, ${e} 60%, ${e} 100%)`};
|
|
1969
|
+
background-size: 250% 100%; /* Expand background to allow movement */
|
|
1970
|
+
background-clip: text;
|
|
1971
|
+
color: transparent;
|
|
1972
|
+
animation: ${mu} 1s reverse linear infinite;
|
|
1973
|
+
`,xu=({label:e,icon:t,withGradient:o,textColor:n,stripColor:i,typographyProps:a})=>{const r=Si.useTheme(),s=n||r.v2.colors.white[500],l=i||r.v2.colors.black[500];return xt.createElement(xt.Fragment,null,e?xt.createElement(ya,{$gap:4},t&&xt.createElement(t,null),o?xt.createElement(gu,{$textColor:s,$stripColor:l,...a},e):xt.createElement(Ni,{color:s,...a},e)):null)},$u=It.div`
|
|
1974
|
+
position: fixed;
|
|
1975
|
+
top: 50%;
|
|
1976
|
+
left: 50%;
|
|
1977
|
+
transform: translate(-50%, -50%);
|
|
1978
|
+
z-index: 1000;
|
|
1979
|
+
width: fit-content;
|
|
1980
|
+
border-radius: 20px;
|
|
1981
|
+
background: ${({theme:e})=>e.v2.colors.black[500]};
|
|
1982
|
+
box-shadow: 0 0 34px 0 rgba(0, 0, 0, 0.7);
|
|
1983
|
+
overflow: hidden;
|
|
1984
|
+
|
|
1985
|
+
animation-name: ${Si.animations.slide.in.center};
|
|
1986
|
+
`,fu=It.div`
|
|
1987
|
+
position: relative;
|
|
1988
|
+
`,bu=It.div`
|
|
1989
|
+
position: absolute;
|
|
1990
|
+
top: 16px;
|
|
1991
|
+
left: 16px;
|
|
1992
|
+
`,yu=({isOpen:e,onBack:t,onClose:o,children:n})=>(za(e),e?jt(xt.createElement(xt.Fragment,null,xt.createElement(Ca,{hidden:!e,onClick:o}),xt.createElement($u,null,xt.createElement(fu,null,t&&xt.createElement(bu,null,xt.createElement(Pa,{icon:e=>xt.createElement(Ge,{rotate:-90,...e}),size:La.L,onClick:t})),n))),document.body):null),wu=It.aside`
|
|
1993
|
+
display: flex;
|
|
1994
|
+
flex-direction: column;
|
|
1995
|
+
gap: 8px;
|
|
1996
|
+
height: ${({$height:e})=>e};
|
|
1997
|
+
width: fit-content;
|
|
1998
|
+
padding: 16px 12px;
|
|
1999
|
+
background-color: ${({theme:e})=>e.v2.colors.black[500]};
|
|
2000
|
+
overflow-y: auto;
|
|
2001
|
+
`,ku=({height:e,icons:t})=>xt.createElement(wu,{$height:e},t.map(({id:e,selected:t,icon:o,onClick:n})=>xt.createElement(Vi,{key:e,label:"",leftIcon:o,iconSize:24,onClick:n,variant:t?ji.Primary:ji.Text}))),vu=It.div`
|
|
2002
|
+
display: flex;
|
|
2003
|
+
align-items: center;
|
|
2004
|
+
gap: 10px;
|
|
2005
|
+
padding: 4px;
|
|
2006
|
+
border-radius: 8px;
|
|
2007
|
+
background-color: ${({theme:e,$status:t})=>Cn(e,t,[ho.Info].includes(t)?"1000":"900")};
|
|
2008
|
+
`,Cu=It.div`
|
|
2009
|
+
width: 36px;
|
|
2010
|
+
height: 36px;
|
|
2011
|
+
display: flex;
|
|
2012
|
+
align-items: center;
|
|
2013
|
+
justify-content: center;
|
|
2014
|
+
border-radius: 6px;
|
|
2015
|
+
background-color: ${({theme:e,$status:t})=>Cn(e,t,[ho.Info].includes(t)?"900":"800")};
|
|
2016
|
+
`,Eu=({status:e,message:t})=>{const o=Si.useTheme(),n=Sn(e,o);return xt.createElement(vu,{$status:e},xt.createElement("div",null,xt.createElement(Cu,{$status:e},xt.createElement(n,{size:24}))),xt.createElement(Ni,{color:Cn(o,e,e===ho.Default?"300":e===ho.Info?"400":"500"),size:Di.XXS,weight:400},t))};var Su;!function(e){e.S="small",e.L="large"}(Su||(Su={}));const Au=It.div`
|
|
2017
|
+
width: fit-content;
|
|
2018
|
+
display: flex;
|
|
2019
|
+
align-items: center;
|
|
2020
|
+
gap: 8px;
|
|
2021
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
2022
|
+
`,Du=It.div`
|
|
2023
|
+
width: ${({$size:e})=>e===Su.S?"16px":"20px"};
|
|
2024
|
+
height: ${({$size:e})=>e===Su.S?"16px":"20px"};
|
|
2025
|
+
display: flex;
|
|
2026
|
+
align-items: center;
|
|
2027
|
+
justify-content: center;
|
|
2028
|
+
border-radius: 100%;
|
|
2029
|
+
border: 1px solid ${({$borderColor:e})=>e};
|
|
2030
|
+
background-color: ${({$backgroundColor:e})=>e};
|
|
2031
|
+
`,Tu=({label:e,value:t,onChange:o,disabled:n,size:i=Su.L})=>{const a=Si.useTheme(),[r,s]=yt(!1),l=t,c=i===Su.S?6:8,d=n?a.v2.colors.grey[400]:a.v2.colors.white[500],p=l?"transparent":n?a.v2.colors.grey[700]:r?a.v2.colors.silver[400]:a.v2.colors.silver[600],u=n?a.v2.colors.grey[600]:l?a.v2.colors.purple[500]:a.v2.colors.silver[900];return xt.createElement(Au,{"data-id":"radio"+(e?`-${e}`:""),onClick:e=>{e.stopPropagation(),n||o(!t)},$disabled:n,onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1)},xt.createElement(Du,{$size:i,$borderColor:p,$backgroundColor:u},t?xt.createElement(mt,{size:c,fill:d}):null),e&&xt.createElement(Ni,{size:i===Su.S?Di.XXS:Di.XS},e))};var Nu;!function(e){e.HORIZONTAL="horizontal",e.VERTICAL="vertical"}(Nu||(Nu={}));const Iu=It.div`
|
|
2032
|
+
display: flex;
|
|
2033
|
+
flex-direction: ${({$flexDirection:e})=>e};
|
|
2034
|
+
gap: ${({$gap:e})=>e}px;
|
|
2035
|
+
`,zu=({label:e,direction:t,disabled:o,size:n,options:i,values:a,setValues:r})=>xt.createElement(Iu,{$flexDirection:t===Nu.HORIZONTAL?"row":"column",$gap:t===Nu.HORIZONTAL?16:8},e&&xt.createElement(Ni,null,e),i.map(t=>xt.createElement(Tu,{key:`${e}-radio-${t.id}`,...t,value:a[t.id],onChange:e=>{return o=t.id,n=e,void r(e=>{const t={...e};return Object.keys(t).forEach(e=>t[e]=!1),t[o]=n,t});var o,n},disabled:o,size:n}))),Ou=It.div`
|
|
2036
|
+
position: relative;
|
|
2037
|
+
z-index: 0;
|
|
2038
|
+
display: flex;
|
|
2039
|
+
align-items: center;
|
|
2040
|
+
padding: 3px;
|
|
2041
|
+
border-radius: 8px;
|
|
2042
|
+
border: 1px solid ${({theme:e})=>e.v2.colors.grey[500]};
|
|
2043
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[700]};
|
|
2044
|
+
`,_u=It.button`
|
|
2045
|
+
flex: 1;
|
|
2046
|
+
display: flex;
|
|
2047
|
+
align-items: center;
|
|
2048
|
+
justify-content: center;
|
|
2049
|
+
gap: 8px;
|
|
2050
|
+
padding: 8px 16px;
|
|
2051
|
+
border-radius: 6px;
|
|
2052
|
+
border: none;
|
|
2053
|
+
background-color: ${({theme:e,$isSelected:t})=>t?e.v2.colors.black[500]:"transparent"};
|
|
2054
|
+
box-shadow: ${({$isSelected:e})=>e?"0 0 11px 0 rgba(0, 0, 0, 0.32)":"none"};
|
|
2055
|
+
cursor: pointer;
|
|
2056
|
+
&:hover {
|
|
2057
|
+
background-color: ${({theme:e,$isSelected:t})=>t?e.v2.colors.black[500]:e.v2.colors.silver[800]};
|
|
2058
|
+
}
|
|
2059
|
+
`,Fu=({options:e=[],selected:t,setSelected:o})=>xt.createElement(Ou,{$count:e.length},e.map(({value:e,label:n,icon:i},a)=>{const r=t===e;return xt.createElement(_u,{key:`segment-${n||a}-${e}`,onClick:()=>o(e),$isSelected:r},i&&xt.createElement(i,null),n&&xt.createElement(Ni,{size:Di.XS,weight:500,nowrap:!0},n))}));var Ru;!function(e){e.Data="data",e.Pretty="pretty"}(Ru||(Ru={}));const Lu=It.div`
|
|
2060
|
+
max-height: ${({$maxHeight:e})=>e};
|
|
2061
|
+
width: 100%;
|
|
2062
|
+
overflow: auto;
|
|
2063
|
+
`,Bu=It.table`
|
|
2064
|
+
width: 100%;
|
|
2065
|
+
|
|
2066
|
+
${({$variant:e})=>{switch(e){case Ru.Data:return Ft`
|
|
2067
|
+
border-collapse: collapse;
|
|
2068
|
+
`;case Ru.Pretty:return Ft`
|
|
2069
|
+
border-collapse: separate;
|
|
2070
|
+
border-spacing: 0 8px;
|
|
2071
|
+
`;default:return""}}}
|
|
2072
|
+
`,Pu=It.thead`
|
|
2073
|
+
position: sticky;
|
|
2074
|
+
top: 0;
|
|
2075
|
+
z-index: 100;
|
|
2076
|
+
`,Mu=It.th`
|
|
2077
|
+
position: relative;
|
|
2078
|
+
min-width: ${({$minWidth:e})=>e||"auto"};
|
|
2079
|
+
padding: 18px 24px;
|
|
2080
|
+
border: none;
|
|
2081
|
+
border-radius: ${({$isFirst:e,$isLast:t})=>e?"4px 0 0 0":t?"0 4px 0 0":"0"};
|
|
2082
|
+
|
|
2083
|
+
${({$variant:e})=>{switch(e){case Ru.Data:return Ft`
|
|
2084
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[750]};
|
|
2085
|
+
`;case Ru.Pretty:return Ft`
|
|
2086
|
+
background-color: transparent;
|
|
2087
|
+
`;default:return""}}}
|
|
2088
|
+
`,ju=It.div`
|
|
2089
|
+
position: absolute;
|
|
2090
|
+
top: 50%;
|
|
2091
|
+
right: 0;
|
|
2092
|
+
transform: translateY(-50%);
|
|
2093
|
+
width: 1px;
|
|
2094
|
+
height: 18px;
|
|
2095
|
+
background: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
2096
|
+
`,Uu=It.tbody``,Wu=It.td`
|
|
2097
|
+
position: relative;
|
|
2098
|
+
padding: 18px 24px;
|
|
2099
|
+
cursor: ${({$withClick:e})=>e?"pointer":"default"};
|
|
2100
|
+
|
|
2101
|
+
${({$variant:e,$selected:t,$hovered:o,$isLastRow:n,$isFirstCell:i,$isLastCell:a})=>{switch(e){case Ru.Data:return Ft`
|
|
2102
|
+
border: ${({theme:e})=>n?"none":`1px solid ${e.v2.colors.silver[500]}`};
|
|
2103
|
+
border-left: none;
|
|
2104
|
+
border-right: none;
|
|
2105
|
+
border-radius: ${n?i?"0 0 0 4px":a?"0 0 4px 0":"0":"0"};
|
|
2106
|
+
background-color: ${({theme:e})=>t?e.v2.colors.blue[1e3]:o?e.v2.colors.silver[700]:e.v2.colors.silver[800]};
|
|
2107
|
+
`;case Ru.Pretty:return Ft`
|
|
2108
|
+
border: none;
|
|
2109
|
+
border-radius: ${i?"12px 0 0 12px":a?"0 12px 12px 0":"0"};
|
|
2110
|
+
background-color: ${({theme:e})=>t?e.v2.colors.blue[1e3]:o?e.v2.colors.silver[700]:e.v2.colors.silver[900]};
|
|
2111
|
+
`;default:return""}}}
|
|
2112
|
+
`,Vu=It.div`
|
|
2113
|
+
width: 100%;
|
|
2114
|
+
display: flex;
|
|
2115
|
+
align-items: center;
|
|
2116
|
+
justify-content: ${({$textAlign:e})=>"right"===e?"flex-end":"left"===e?"flex-start":"center"===e?"center":"unset"};
|
|
2117
|
+
gap: 4px;
|
|
2118
|
+
text-align: ${({$textAlign:e})=>e||"left"};
|
|
2119
|
+
cursor: ${({$withClick:e})=>e?"pointer":"default"};
|
|
2120
|
+
&:hover {
|
|
2121
|
+
* {
|
|
2122
|
+
fill: ${({theme:e})=>e.v2.colors.white[500]};
|
|
2123
|
+
}
|
|
2124
|
+
}
|
|
2125
|
+
`,Hu=It.div`
|
|
2126
|
+
display: flex;
|
|
2127
|
+
align-items: center;
|
|
2128
|
+
gap: 2px;
|
|
2129
|
+
width: fit-content;
|
|
2130
|
+
padding: 4px;
|
|
2131
|
+
border-radius: 8px;
|
|
2132
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[600]};
|
|
2133
|
+
box-shadow: 0 3px 8px 0 rgba(0, 0, 0, 0.25);
|
|
2134
|
+
|
|
2135
|
+
position: absolute;
|
|
2136
|
+
right: ${({$rightPosition:e})=>e};
|
|
2137
|
+
top: 50%;
|
|
2138
|
+
transform: translateY(-50%);
|
|
2139
|
+
`,qu=({rowActions:e,rowActionsPushRightPosition:t="12px"})=>xt.createElement(Hu,{$rightPosition:t},e.map(e=>xt.createElement(Vi,{key:e.id,...e}))),Gu=({variant:e,columns:t,rows:o,getRowActions:n,rowActionsPushRightPosition:i,withCheckboxes:a})=>{const[r,s]=yt(null);return xt.createElement(xt.Fragment,null,o.map((l,c)=>{const{onClick:d,isSelected:p=!1,onSelect:u,onDeselect:h,cells:m}=l,g=r===c,x=!!d,$=n(l),f=(e,t,n)=>({$isLastRow:c===o.length-1,$isFirstCell:t,$isLastCell:n,$hovered:g,$selected:p,$withClick:e,onClick:()=>e&&d?.(),onMouseEnter:()=>e&&s(c),onMouseLeave:()=>e&&s(null)});return xt.createElement("tr",{key:`row-${c}`},a&&xt.createElement(Wu,{key:"checkbox-column",$variant:e,...f(!1,!0,!1)},xt.createElement(Dp,{value:p,onChange:()=>p?h?.():u?.()})),t.map(({key:o,textAlign:n},r)=>{const s=m.find(e=>e.key===o),l=0===r&&!a,d=r===t.length-1;return xt.createElement(Wu,{key:`row-${c}-cell-${r}`,$variant:e,...f(x,l,d)},s?.component?xt.createElement(ya,{$justifyContent:"right"===n?"flex-end":"flex-start"},xt.createElement(s.component,null)):xt.createElement(Ni,{size:Di.XS,align:n},s?.rawValue||"-"),$.length&&g&&d?xt.createElement(qu,{rowActions:$,rowActionsPushRightPosition:i}):null)}))}))},Ku=({variant:e,columns:t,sortDirection:o,sortByKey:n,onSort:i,withCheckboxes:a,allSelected:r,onSelectAll:s})=>{const l=_t();return xt.createElement("tr",null,a&&xt.createElement(Mu,{key:"checkbox-column",$variant:e,$minWidth:24,$isFirst:!0,$isLast:!1},xt.createElement(Dp,{value:r||!1,onChange:s})),t.map(({key:r,label:s,sortable:c,minWidth:d,textAlign:p},u)=>{const h=0===u&&!a,m=u===t.length-1;return xt.createElement(Mu,{key:`column-${r}`,$variant:e,$minWidth:d,$isFirst:h,$isLast:m},xt.createElement(Vu,{$withClick:c||!1,$textAlign:p,onClick:()=>c?i(r):null},xt.createElement(Ni,{size:Di.XS,align:p},s),c&&xt.createElement(Ge,{fill:n===r?l.v2.colors.white[500]:l.v2.colors.grey[400],rotate:o===oo.Ascending?0:180})),!m&&e===Ru.Data&&xt.createElement(ju,null))}))},Ju=({variant:e,maxHeight:t="unset",isLoading:o,columns:n,rows:i,getRowActions:a,rowActionsPushRightPosition:r,withCheckboxes:s})=>{const[l,c]=yt(oo.Ascending),[d,p]=yt(""),u=vt(e=>{p(e),c(e=>e===oo.Ascending?oo.Descending:oo.Ascending)},[]),h=ft(()=>{const e=(e,t)=>{const o=e.cells.find(e=>e.key===t);return o&&(o.rawValue||o.component?.({})?.props?.children)||null};return d?[...i].sort((t,o)=>{const n=e(t,d),i=e(o,d);return(l===oo.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)))(n,i)}):i},[i,d,l]);return xt.createElement(Lu,{$maxHeight:t},xt.createElement(Bu,{$variant:e},xt.createElement(Pu,null,xt.createElement(Ku,{variant:e,columns:n,sortDirection:l,sortByKey:d,onSort:u,withCheckboxes:s,allSelected:i.length>0&&i.every(e=>e.isSelected),onSelectAll:e=>{e?i.forEach(e=>e.onSelect?.()):i.forEach(e=>e.onDeselect?.())}})),xt.createElement(Uu,null,xt.createElement(Gu,{variant:e,columns:n,rows:h,getRowActions:a||(()=>[]),rowActionsPushRightPosition:r,withCheckboxes:s}))),!h.length&&xt.createElement(ka,{style:{marginTop:"0.5rem"}},o?xt.createElement(cs,{scale:1.2}):xt.createElement(ol,null)))},Yu=It.div`
|
|
2140
|
+
display: flex;
|
|
2141
|
+
align-items: center;
|
|
2142
|
+
justify-content: center;
|
|
2143
|
+
gap: 8px;
|
|
2144
|
+
width: fit-content;
|
|
2145
|
+
padding: 8px;
|
|
2146
|
+
border-radius: 4px;
|
|
2147
|
+
${({$disabled:e})=>e?Ft`
|
|
2148
|
+
cursor: not-allowed;
|
|
2149
|
+
background-color: ${({theme:e})=>e.v2.colors.grey[800]};
|
|
2150
|
+
`:Ft`
|
|
2151
|
+
cursor: pointer;
|
|
2152
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[300]};
|
|
2153
|
+
&:hover {
|
|
2154
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[400]};
|
|
2155
|
+
}
|
|
2156
|
+
&:active {
|
|
2157
|
+
background-color: ${({theme:e})=>e.v2.colors.silver[500]};
|
|
2158
|
+
}
|
|
2159
|
+
`}
|
|
2160
|
+
`,Xu=({label:e,leftIcon:t,rightIcon:o,disabled:n})=>{const i=Si.useTheme(),a=n?i.v2.colors.grey[400]:i.v2.colors.white[500];return xt.createElement(Yu,{$disabled:n},t&&xt.createElement(t,{fill:a,size:16}),xt.createElement(Ni,{color:a,size:Di.XS},e),o&&xt.createElement(o,{fill:a,size:16}))};var Qu,Zu,eh;!function(e){e.Default="default",e.SuccessError="successError"}(Qu||(Qu={})),function(e){e.S="small",e.L="large"}(Zu||(Zu={})),function(e){e.Left="left",e.Right="right"}(eh||(eh={}));const th=It.div`
|
|
2161
|
+
display: flex;
|
|
2162
|
+
align-items: center;
|
|
2163
|
+
gap: ${({$gap:e})=>e}px;
|
|
2164
|
+
`,oh=It.div`
|
|
2165
|
+
position: relative;
|
|
2166
|
+
display: flex;
|
|
2167
|
+
align-items: center;
|
|
2168
|
+
justify-content: space-between;
|
|
2169
|
+
|
|
2170
|
+
width: ${({$size:e})=>2*e+2}px;
|
|
2171
|
+
height: ${({$size:e})=>e}px;
|
|
2172
|
+
padding: ${4}px;
|
|
2173
|
+
border-radius: ${({$size:e})=>2*e}px;
|
|
2174
|
+
background-color: ${({$disabled:e,$onBgColor:t,$offBgColor:o,$variant:n,$value:i,theme:a})=>{if(e)return a.v2.colors.grey[800];if(t&&i)return t;if(o&&!i)return o;switch(n){case Qu.SuccessError:return i?a.v2.colors.green[500]:a.v2.colors.red[500];case Qu.Default:default:return i?a.v2.colors.purple[500]:a.v2.colors.grey[400]}}};
|
|
2175
|
+
|
|
2176
|
+
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
2177
|
+
`,nh=It.div`
|
|
2178
|
+
position: absolute;
|
|
2179
|
+
top: 50%;
|
|
2180
|
+
left: ${({$value:e,$size:t})=>e?`calc(100% - ${t}px - 4px)`:"4px"};
|
|
2181
|
+
transform: translateY(-50%);
|
|
2182
|
+
width: ${({$size:e})=>e}px;
|
|
2183
|
+
height: ${({$size:e})=>e}px;
|
|
2184
|
+
border-radius: 100%;
|
|
2185
|
+
background-color: ${({$color:e})=>e};
|
|
2186
|
+
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)"};
|
|
2187
|
+
`,ih=({variant:e=Qu.Default,size:t=Zu.L,label:o,labelAlign:n=eh.Left,tooltip:i,value:a,onChange:r,disabled:s,withIcon:l,onIcon:c=Ke,offIcon:d=Ye,onBgColor:p,offBgColor:u})=>{const h=_t(),m=s?h.v2.colors.grey[400]:h.v2.colors.white[500],g=t===Zu.S?14:18,x=t===Zu.S?Di.XS:Di.S,$=t===Zu.S?8:12;return xt.createElement(th,{$gap:$},o&&n===eh.Left&&xt.createElement(Ni,{size:x,nowrap:!0},o),xt.createElement(oh,{$onBgColor:p,$offBgColor:u,$variant:e,$size:g,$value:a,$disabled:s,onClick:()=>!s&&r(!a)},xt.createElement(nh,{$color:m,$size:g,$value:a,$disabled:s}),l&&xt.createElement(xt.Fragment,null,xt.createElement(c,{size:g,fill:m}),xt.createElement(d,{size:g,fill:m}))),o&&n===eh.Right&&xt.createElement(Ni,{size:x,nowrap:!0},o),i&&xt.createElement(vr,{text:i,withIcon:!0}))},ah=It.div`
|
|
2188
|
+
display: flex;
|
|
2189
|
+
flex-direction: ${({$direction:e})=>e===to.Horizontal?"row":"column"};
|
|
2190
|
+
gap: ${({$direction:e})=>e===to.Horizontal?16:8}px;
|
|
2191
|
+
`,rh=({direction:e=to.Vertical,title:t,size:o,disabled:n,options:i,values:a,setValues:r})=>{const s=o===Zu.S?Di.XS:Di.S;return xt.createElement(ah,{$direction:e},t&&xt.createElement(Ni,{size:s},t),i.map(e=>xt.createElement(ih,{key:`${t}-toggle-${e.id}`,...e,labelAlign:eh.Right,value:a[e.id],onChange:t=>{return o=e.id,n=t,void r(e=>{const t={...e};return o?t[o]=n:i.forEach(e=>t[e.id]=n),t});var o,n},disabled:n,size:o})))};export{dd as $,Wp as A,zi as B,Dp as C,iu as D,en as E,wa as F,rc as G,Kt as H,Pa as I,fl as J,Yt as K,xu as L,Gr as M,ol as N,xo as O,ba as P,Xi as Q,Jt as R,Cp as S,Ni as T,El as U,uo as V,Ao as W,On as X,md as Y,mp as Z,wd as _,ya as a,Yd as a$,po as a0,Li as a1,jd as a2,Ld as a3,Sc as a4,Cd as a5,pp as a6,pi as a7,ci as a8,ni as a9,Sn as aA,ri as aB,Go as aC,zs as aD,gn as aE,Ls as aF,Sa as aG,Aa as aH,od as aI,hn as aJ,Da as aK,ac as aL,$p as aM,ma as aN,Jn as aO,Mi as aP,fa as aQ,ui as aR,si as aS,Ws as aT,mn as aU,Wn as aV,an as aW,Id as aX,Po as aY,un as aZ,pn as a_,Ga as aa,tn as ab,Gc as ac,Cc as ad,Vr as ae,lo as af,ii as ag,Ia as ah,Lo as ai,Ro as aj,fs as ak,fc as al,so as am,li as an,hr as ao,Ad as ap,Ea as aq,Fr as ar,Zo as as,pa as at,gr as au,ln as av,ks as aw,jn as ax,vr as ay,go as az,Di as b,Hn as b$,Fa as b0,oi as b1,Ra as b2,Yo as b3,on as b4,Ko as b5,Jo as b6,Oa as b7,Ja as b8,yr as b9,ip as bA,pc as bB,fn as bC,Co as bD,_o as bE,Eo as bF,Fo as bG,vo as bH,So as bI,ko as bJ,sp as bK,dn as bL,qa as bM,Mo as bN,ir as bO,Tn as bP,_a as bQ,fo as bR,ml as bS,Ss as bT,ad as bU,An as bV,zn as bW,Es as bX,Js as bY,Xs as bZ,Rn as b_,Vd as ba,va as bb,Ka as bc,Mn as bd,Nl as be,Xn as bf,jo as bg,Qo as bh,Ya as bi,ja as bj,gi as bk,Xo as bl,Sr as bm,ps as bn,vs as bo,As as bp,co as bq,Un as br,Ho as bs,Nn as bt,Io as bu,Wa as bv,In as bw,Uo as bx,Bo as by,qo as bz,ih as c,Ns as c$,Qa as c0,ql as c1,zo as c2,ro as c3,or as c4,Fs as c5,cn as c6,Fn as c7,La as c8,Ul as c9,xn as cA,$n as cB,bn as cC,yn as cD,wn as cE,vn as cF,Dn as cG,_n as cH,Ln as cI,Pn as cJ,Vn as cK,qn as cL,Gn as cM,Kn as cN,Yn as cO,Qn as cP,Zn as cQ,qt as cR,za as cS,Va as cT,dl as cU,il as cV,vc as cW,Lc as cX,Wc as cY,Jc as cZ,ed as c_,ei as ca,rn as cb,Yr as cc,kn as cd,Ts as ce,Gt as cf,Xt as cg,Qt as ch,Zt as ci,eo as cj,to as ck,oo as cl,no as cm,io as cn,ao as co,mo as cp,$o as cq,bo as cr,yo as cs,wo as ct,Do as cu,To as cv,No as cw,Oo as cx,Wo as cy,nn as cz,Zu as d,Nc as d0,_i as d1,Fi as d2,Ri as d3,Wr as d4,Ca as d5,Ki as d6,fp as d7,_p as d8,Ep as d9,Hp as da,Op as db,su as dc,hu as dd,yu as de,ku as df,Eu as dg,Su as dh,Tu as di,Nu as dj,zu as dk,Xu as dl,Qu as dm,eh as dn,rh as dp,Ai as dq,Vi as e,ji as f,nr as g,Lp as h,sn as i,Fp as j,Ui as k,Ju as l,Ru as m,ho as n,Si as o,Ma as p,En as q,ka as r,cs as s,wp as t,Ta as u,Yp as v,ns as w,Cn as x,Fu as y,Mp as z};
|