@kong-ui-public/entities-plugins 1.4.0 → 1.4.1

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.
@@ -720,7 +720,7 @@ function Ui(e, n, t = "data") {
720
720
  }
721
721
  function Vi() {
722
722
  return {
723
- getPropValue: (e, n) => (n == null ? void 0 : n[e]) || void 0
723
+ getPropValue: (e, n) => (n == null ? void 0 : n[e]) ?? void 0
724
724
  };
725
725
  }
726
726
  function zi() {
@@ -1,4 +1,4 @@
1
- (function(W,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@kong-ui-public/i18n"),require("axios"),require("@kong/kongponents"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","@kong-ui-public/i18n","axios","@kong/kongponents","vue-router"],t):(W=typeof globalThis<"u"?globalThis:W||self,t(W["kong-ui-public-entities-plugins"]={},W.Vue,W["kong-ui-public-i18n"],W.axios,W.Kongponents,W.VueRouter))})(this,function(W,t,Ee,Tn,vn,Dn){"use strict";const Ln={actions:{create:"New Plugin",copy_id:"Copy ID",copy_json:"Copy JSON",edit:"Edit",delete:"Delete",view:"View Details",configure_dynamic_ordering:"Configure Dynamic Ordering"},delete:{title:"Delete Plugin",description:"Are you sure you want to delete this plugin? This action cannot be reversed."},copy:{success:"Copied {val} to clipboard",success_brief:"Successfully copied to clipboard",tooltip:"Copy {label}",success_tooltip:"Copied!"},errors:{general:"Plugins could not be retrieved",delete:"The plugin could not be deleted at this time.",copy:"Failed to copy to clipboard"},search:{placeholder:{konnect:"Filter by exact instance name or ID"},filter:{field:{enabled:"Enabled"}}},plugins:{title:"Plugins",list:{toolbar_actions:{new_plugin:"New Plugin"},table_headers:{applied_to:"Applied To",applied_to_badges:{consumer:"Consumer",global:"Global",route:"Route",service:"Service",consumer_group:"Consumer Group"},id:"ID",name:"Name",instance_name:"Instance Name",ordering:"Ordering",ordering_badge:{dynamic:"Dynamic",static:"Static"},status:"Status",status_label:{enabled:"Enabled",disabled:"Disabled"},tags:"Tags"},empty_state:{title:"Configure a New Plugin",description:"Improve the security of your Kong Gateway deployment with centralized secrets."}},meta:{"basic-auth":{name:"Basic Authentication",description:"Add Basic Authentication to your Services"},"hmac-auth":{name:"HMAC Authentication",description:"Add HMAC Authentication to your Services"},"jwt-signer":{name:"JWT Signer",description:"Verify and (re-)sign one or two tokens in a request"},jwt:{name:"JWT",description:"Verify and authenticate JSON Web Tokens"},"key-auth":{name:"Key Authentication",description:"Add key authentication to your Services"},"key-auth-enc":{name:"Key Authentication Encrypted",description:"Add key authentication to your Services with an encrypted token"},"ldap-auth-advanced":{name:"LDAP Authentication Advanced",description:"Integrate Kong with a LDAP server"},"ldap-auth":{name:"LDAP Authentication",description:"Integrate Kong with a LDAP server"},"oauth2-introspection":{name:"OAuth 2.0 Introspection",description:"Integrate Kong with a third-party OAuth 2.0 Authorization Server"},oauth2:{name:"OAuth 2.0 Authentication",description:"Add OAuth 2.0 authentication to your Services"},"openid-connect":{name:"OpenID Connect",description:"Integrate Kong with a third-party OpenID Connect 1.0 Provider"},"mtls-auth":{name:"Mutual TLS Authentication",description:"Secure routes and services with client certificate and mutual TLS authentication"},"vault-auth":{name:"Vault Authentication",description:"Secure routes and services with an access token and secret token, stored securely via Vault"},"bot-detection":{name:"Bot Detection",description:"Detect and clock bots or custom clients"},cors:{name:"CORS",description:"Allow developers to make requests from the browser"},"ip-restriction":{name:"IP Restriction",description:"Whitelist or blacklist IPs that can make requests"},opa:{name:"OPA",description:"Authorize requests against Open Policy Agent"},"kubernetes-sidecar-injector":{name:"Kubernetes Sidecar Injector",description:"This plugin will inject Kong dataplane nodes and form a service mesh on top of Kubernetes"},"request-validator":{name:"Request Validator",description:"Validate requests before they reach their upstream Service. "},acl:{name:"ACL",description:"Control which consumers can access Services"},canary:{name:"Canary Release",description:"Methodically roll out software changes to a subset of users"},"forward-proxy":{name:"Forward Proxy",description:"Allow Kong to connect to intermediary transparent HTTP proxies"},"proxy-cache":{name:"Proxy Caching",description:"Cache and serve commonly requested responses in Kong"},"proxy-cache-advanced":{name:"Proxy Caching Advanced",description:"Cache and serve commonly requested responses in Kong"},"graphql-proxy-cache-advanced":{name:"GraphQL Proxy Caching Advanced",description:"Cache and serve commonly requested responses in Kong"},"rate-limiting-advanced":{name:"Rate Limiting Advanced",description:"Rate-limit how many HTTP requests a developer can make"},"rate-limiting":{name:"Rate Limiting",description:"Rate-limit how many HTTP requests a developer can make"},"graphql-rate-limiting-advanced":{name:"GraphQL Rate Limiting Advanced",description:"Rate-limit how many HTTP requests a developer can make"},mocking:{name:"Mocking",description:"Provide mock endpoints to test your APIs in development against your services"},"request-size-limiting":{name:"Request Size Limiting",description:"Block requests with bodies greater than a specific size"},"request-termination":{name:"Request Termination",description:"Terminate all requests with a specific response"},"response-ratelimiting":{name:"Response Rate Limiting",description:"Rate-Limiting based on a custom response header value"},"route-by-header":{name:"Route by Header",description:"Route requests based on request headers"},"aws-lambda":{name:"AWS Lambda",description:"Invoke and manage AWS Lambda functions from Kong"},"azure-functions":{name:"Azure Functions",description:"Invoke Azure functions"},openwhisk:{name:"OpenWhisk",description:"Invoke and manage OpenWhisk actions from Kong"},"pre-function":{name:"Kong Functions (Pre-Plugins)",description:"Add and manage custom lua functions to run before other plugins"},"post-function":{name:"Kong Functions (Post-Plugins)",description:"Add and manage custom lua functions to run after other plugins"},datadog:{name:"Datadog",description:"Visualize metrics on Datadog"},prometheus:{name:"Prometheus",description:"Export performance metrics to Prometheus"},zipkin:{name:"Zipkin",description:"Propagate zipkin spans and report spans to a zipkin server"},collector:{name:"Collector",description:"Automate spec-driven development & anomaly detection (Early Access)"},"response-transformer-advanced":{name:"Response Transformer Advanced",description:"Transform the response sent by the upstream server on the fly on Kong, before returning the response to the client."},"correlation-id":{name:"Correlation ID",description:"Correlate requests and responses using a unique ID"},"request-transformer-advanced":{name:"Request Transformer Advanced",description:"Use powerful regular expressions, variables and templates to transform API requests"},"request-transformer":{name:"Request Transformer",description:"Modify the request before hitting the upstream server"},"response-transformer":{name:"Response Transformer",description:"Modify the upstream response before returning it to the client"},"route-transformer-advanced":{name:"Route Transformer Advanced",description:"Transforms the routing on the fly in Kong, changing the upstream server/port/path to hit"},"kafka-upstream":{name:"Kafka Upstream",description:"Transform requests into Kafka messages in a topic"},degraphql:{name:"DeGraphQL",description:"Transform a GraphQL upstream into a REST API"},"exit-transformer":{name:"Exit Transformer",description:"Customize Kong exit responses sent downstream"},jq:{name:"jq",description:"Transform JSON objects included in API requests or responses using jq programs"},"file-log":{name:"File Log",description:"Append request and response data to a log file on disk"},"http-log":{name:"HTTP Log",description:"Send request and response logs to an HTTP server"},loggly:{name:"Loggly",description:"Send request and response logs to Loggly"},"statsd-advanced":{name:"StatsD Advanced",description:"Send traffic and Kong performance metrics to StatsD"},statsd:{name:"StatsD",description:"Send request and response logs to StatsD"},syslog:{name:"Syslog",description:"Send request and response logs to Syslog"},"tcp-log":{name:"TCP Log",description:"Send request and response logs to a TCP server"},"udp-log":{name:"UDP Log",description:"Send request and response logs to a UDP server"},"kafka-log":{name:"Kafka Log",description:"Publish request and response logs to a Kafka topic"},session:{name:"Session",description:"Sessions for Kong authentication"},"upstream-tls":{name:"Upstream TLS",description:"Enable TLS on upstream traffic by providing Kong with a list of trusted certificates."},"application-registration":{name:"Portal Application Registration",description:"Allow portal developers to register applications against services"},"konnect-application-auth":{name:"Konnect Application Auth",description:"Allow Konnect portal developers to register applications against services"},acme:{name:"ACME",description:"Let's Encrypt and ACMEv2 integration with Kong"},"grpc-gateway":{name:"gRPC Gateway",description:"Access gRPC services through HTTP REST"},"grpc-web":{name:"gRPC Web",description:"Allow browser clients to call gRPC services"},"upstream-timeout":{name:"Upstream Timeout",description:"Configure read, send and connect timeouts to an upstream"},opentelemetry:{name:"OpenTelemetry",description:"Propagate distributed tracing spans and report low-level spans to a OTLP-compatible server"},"websocket-validator":{name:"WebSocket Validator",description:"Validate individual WebSocket messages against to a user-specified schema before proxying them"},"websocket-size-limit":{name:"WebSocket Size Limit",description:"Allows operators to specify a maximum size for incoming WebSocket messages"},"tls-metadata-headers":{name:"TLS Metadata Headers",description:"Detects client certificates in requests, retrieves the TLS metadata, and proxies this metadata via HTTP headers"},"tls-handshake-modifier":{name:"TLS Handshake Modifier",description:"Requests the client certificate and if it exists, makes it available to other plugins acting on the request"},"oas-validation":{name:"OAS Validation",description:"Validate HTTP requests and responses based on an API Specification."},"jwe-decrypt":{name:"Kong JWE Decrypt",description:"The Kong JWE Decrypt plugin makes it possible to decrypt an inbound token(JWE) in a request."},"xml-threat-protection":{name:"XML Threat Protection",description:"Reduce the risk of XML attacks by checking the structure of XML payloads."},saml:{name:"SAML",description:"Security Assertion Markup Language (SAML) is an open standard for exchanging authentication and authorization data between an identity provider and a service provider."},"app-dynamics":{name:"AppDynamics",description:"This plugin integrates Kong with the AppDynamics APM platform so that proxy requests handled by Kong can be identified and analyzed in AppDynamics."}},fields:{service:"Service ID",route:"Route ID",consumer:"Consumer ID",consumer_group:"Consumer Group ID"}},glossary:{plugin:"plugin"}};function rt(){const e=Ee.createI18n("en-us",Ln);return{i18n:e,i18nT:Ee.i18nTComponent(e)}}var st=(e=>(e.GatewayService="service",e.Route="route",e.Consumer="consumer",e.ConsumerGroup="consumer group",e.Plugin="plugin",e.Upstream="upstream",e.Certificate="certificate",e.CACertificate="ca certificate",e.SNI="SNI",e.Key="key",e.KeySet="key set",e.Vault="vault",e.Application="application",e.Developer="developer",e.acls="ACL Credential",e["basic-auth"]="Basic Auth Credential",e["key-auth"]="Key Auth Credential",e["key-auth-enc"]="Key Auth Encrypted Credential",e.oauth2="OAuth 2.0 Credential",e["hmac-auth"]="HMAC Credential",e.jwt="JWT Credential",e.Target="target",e.Policy="policy",e))(st||{}),pe=(e=>(e[e.Loading=0]="Loading",e[e.Idle=1]="Idle",e[e.NoResults=2]="NoResults",e[e.Error=3]="Error",e))(pe||{}),L=(e=>(e.ID="id",e.IdArray="id-array",e.Text="plain-text",e.Date="date",e.Redacted="redacted",e.RedactedArray="redacted-array",e.Json="json",e.JsonArray="json-array",e.BadgeTag="badge-tag",e.BadgeStatus="badge-status",e.BadgeMethod="badge-method",e.LinkInternal="link-internal",e.LinkExternal="link-external",e))(L||{}),J=(e=>(e.Basic="basic",e.Advanced="advanced",e.Plugin="plugin",e))(J||{});function He(e={}){return{axiosInstance:Tn.create({withCredentials:!0,timeout:3e4,...e})}}function Yn(){return{debounce:(e,i)=>{let n;return(...a)=>{clearTimeout(n),n=window==null?void 0:window.setTimeout(()=>{e(...a)},i)}}}}const je="khcp-user-table-preferences",kn={pageSize:30,sortColumnKey:void 0,sortColumnOrder:void 0};function Nn(){const e=n=>{if(typeof n=="string")try{return JSON.parse(n)}catch(a){console.error("useTablePreferences(tryParseJson)",a);return}},i=()=>{const n=e(localStorage.getItem(je));return!n||!Object.keys(n).length?new Map:new Map(Object.entries(n))};return{setTablePreferences:(n,a)=>{try{const o=i();o.set(n,a),localStorage.setItem(je,JSON.stringify(Object.fromEntries(o.entries())))}catch(o){console.error("useTablePreferences(setTablePreferences)",o)}},getTablePreferences:n=>{const a=i();return(a==null?void 0:a.get(n))||void 0||kn},deleteAllTablePreferences:()=>{localStorage.removeItem(je)}}}const Gn={message:"Are you sure you want to delete this {entityType}?",messageWithName:"Are you sure you want to delete this {entityType} {entityName}?"},Vn={actions:{save:"Save",cancel:"Cancel",back:"Back"},errors:{edit:"The entity could not be edited at this time."}},Hn={emptyState:{noSearchResultsTitle:"No results found",noSearchResultsMessage:"Please adjust the criteria and try again.",noSearchResultsCtaText:"Clear"}},jn={title:"Configuration",actions:{copy:"Copy JSON"},sections:{advanced:"Advanced",plugin:"Plugin Specific Configuration"},commonFields:{id_label:"ID",name_label:"Name",enabled_label:"Enabled",enabled_tooltip:"Enabled is FTW",updated_at_label:"Last Updated",created_at_label:"Created",tags_label:"Tags",link:"Link"},statusBadge:{enabledLabel:"Enabled",disabledLabel:"Disabled"},copy:{tooltip:"Copy {label}",success:"Copied!"},errors:{load:"The entity configuration data could not be loaded at this time.",copy:"Failed to copy to clipboard"},general:{entryTitle:"Entry {index}",structuredFormat:"Structured"}},Pn={filterButtonText:"Filter",fieldLabel:"Filter by:",inputPlaceholder:"Enter a value",selectPlaceholder:"Select an item",applyButtonText:"Apply",clearButtonText:"Clear",clearAllButtonText:"Clear all filters"},Un={errors:{fetch:"Could not fetch available items",invalid:"Please select a valid value"}},Fn={unexpected:"An unexpected error has occurred",dataKeyUndefined:'The data key "{dataKey}" does not exist in the response.'},zn={enable:{title:"Enable {entityType}",message:"Are you sure you want to enable the {entityType} {entityName}?",confirmText:"Yes, enable"},disable:{title:"Disable {entityType}",message:"Are you sure you want to disable the {entityType} {entityName}?",confirmText:"Yes, disable"}},Xn={deleteModal:Gn,baseForm:Vn,baseTable:Hn,baseConfigCard:jn,filter:Pn,debouncedFilter:Un,errors:Fn,toggleModal:zn};function Pe(){const e=Ee.createI18n("en-us",Xn);return{i18n:e,i18nT:Ee.i18nTComponent(e)}}function Kn(e,i,n,a={fetchedItemsKey:"data",searchKeys:["id"]}){n||(n="100");const{axiosInstance:o}=He({headers:e.requestHeaders}),{i18n:{t:A}}=Pe(),{debounce:s}=Yn(),l=s(async u=>{await y(u)},200),c=t.ref(!1),p=t.ref(""),g=t.ref(""),d=t.ref([]),f=t.ref(void 0),C=t.unref(i);let B=`${e.apiBaseUrl}${C}`;e.app==="konnect"?B=B.replace(/{controlPlaneId}/gi,(e==null?void 0:e.controlPlaneId)||""):e.app==="kongManager"&&(B=B.replace(/\/{workspace}/gi,e!=null&&e.workspace?`/${e.workspace}`:""));const w=async()=>{try{c.value=!0;const{data:u}=await o.get(`${B}?size=${n}`);u!=null&&u.next||(f.value=a.fetchedItemsKey in u?u[a.fetchedItemsKey]:[]),d.value=a.fetchedItemsKey in u?u[a.fetchedItemsKey]:[]}catch{d.value=[],p.value=A("debouncedFilter.errors.fetch")}finally{c.value=!1}},m=t.ref(""),y=async u=>{var h,T;if(m.value!==u)if(m.value=u||"",f.value===void 0)try{c.value=!0,p.value="",g.value="";let Y=B+"";u&&(Y+=`/${u}`);const{data:M}=await o.get(`${Y}?size=${n}`);a.fetchedItemsKey in M?d.value=M[a.fetchedItemsKey]:M!=null&&M.id?d.value=[M]:d.value=[]}catch(Y){((h=Y==null?void 0:Y.response)==null?void 0:h.status)===404?g.value=A("debouncedFilter.errors.invalid"):(d.value=[],p.value=A("debouncedFilter.errors.fetch"))}finally{c.value=!1}else c.value=!0,g.value="",u?(d.value=(T=f.value)==null?void 0:T.filter(Y=>{var M;let k=!1;for(const b of a.searchKeys){const x=typeof Y[b]=="string"?(M=Y[b])==null?void 0:M.toLowerCase():Y[b];x!=null&&x.includes(u.toLowerCase())&&(k=!0)}return k}),(!d.value||!d.value.length)&&(g.value=A("debouncedFilter.errors.invalid"))):d.value=f.value,c.value=!1};return{loading:c,error:p,validationError:g,results:d,allRecords:f,loadItems:w,debouncedQueryChange:l}}function Jn(e,i){const n=t.unref(i),a=t.computed(()=>e.apiBaseUrl.startsWith("/")?new URL(`${window.location.origin}${n}`):new URL(n));return a.value.search="",o=>`${a.value.href}/${o}`}function Qn(){const{i18n:{t:e}}=Pe();return{getMessageFromError:i=>{var n,a,o;if(!i)return e("errors.unexpected");if((n=i==null?void 0:i.response)!=null&&n.data){if(i.response.data.detail)return i.response.data.detail;if((a=i.response.data.details)!=null&&a.length)return i.response.data.details.map(A=>{let s=e("errors.unexpected");return A.messages&&typeof A.messages=="object"&&A.messages.length&&(s=A.messages.join(", ")),A.field?`${A.field} - ${s}`:s}).join("; ");if(i.response.data.message){const{message:A}=i.response.data;return Array.isArray(A)?(o=A[0])!=null&&o.constraints?Object.values(A[0].constraints)[0]:A[0]:A}if(typeof i.response.data=="string")return i.response.data;if(typeof i.response.data=="object")return Object.keys(i.response.data).map(A=>`${A} ${i.response.data[A]}`).join(", ")}return i.message||e("errors.unexpected")}}}function At(e,i){const n=t.ref(t.unref(e)),a=t.ref(t.unref(i)),o=t.computed(()=>!!(n.value.app==="konnect"||n.value.isExactMatch)),A=t.computed(()=>a.value.startsWith("/")?new URL(`${window.location.origin}${a.value}`):new URL(a.value));return s=>{const{page:l,pageSize:c,offset:p,sortColumnKey:g,sortColumnOrder:d,query:f}=s;try{let C=new URL(A.value.href);return o.value&&f?(C.search="",C=new URL(`${C.href}/${f}/`)):(o.value||new URLSearchParams(f).forEach((B,w)=>{C.searchParams.append(w,B)}),g&&C.searchParams.append("sort_by",g),d==="desc"&&C.searchParams.append("sort_desc","1"),C.searchParams.append("size",String(c))),p&&l!==1&&C.searchParams.append("offset",String(p)),C.href}catch(C){return console.error("RouteList(fetcher)",C),a.value}}}function Wn(e,i,n="data"){const a=t.unref(i),{axiosInstance:o}=He({headers:e.requestHeaders}),A=At(e,a),s=t.ref({status:pe.Idle});return{fetcher:async l=>{try{s.value={status:pe.Loading};const c=A(l),{data:p}=await o.get(c),g=n&&n.replace(/[^\w-_]/gi,"");let d;p[g]&&Array.isArray(p[g])?d=p[g]:d=Object.keys(p).length?[p]:[];const f={data:d,total:d.length,...p.offset?{pagination:{offset:p.offset}}:null};return s.value={status:pe.Idle,response:f},f}catch(c){const p={data:[],total:0};return l.query&&c.response.status===404?(s.value={status:pe.NoResults,response:p,error:c},p):(s.value={status:pe.Error,response:p,error:c},p)}},fetcherState:s}}function Zn(){return{getPropValue:(e,i)=>(i==null?void 0:i[e])||void 0}}function qn(){return{convertKeyToTitle:(e,i="_")=>e?e.split(i).map(n=>n.toLowerCase()==="id"?n.toUpperCase():n.charAt(0).toUpperCase()+n.substring(1)).join(" "):""}}const lt=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,ct=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const i=e.match(lt);if(!i)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return i.shift(),i},dt=e=>e==="*"||e==="x"||e==="X",pt=e=>{const i=parseInt(e,10);return isNaN(i)?e:i},_n=(e,i)=>typeof e!=typeof i?[String(e),String(i)]:[e,i],$n=(e,i)=>{if(dt(e)||dt(i))return 0;const[n,a]=_n(pt(e),pt(i));return n>a?1:n<a?-1:0},gt=(e,i)=>{for(let n=0;n<Math.max(e.length,i.length);n++){const a=$n(e[n]||"0",i[n]||"0");if(a!==0)return a}return 0},ei=(e,i)=>{const n=ct(e),a=ct(i),o=n.pop(),A=a.pop(),s=gt(n,a);return s!==0?s:o&&A?gt(o.split("."),A.split(".")):o||A?o?-1:1:0},ut=(e,i,n)=>{ti(n);const a=ei(e,i);return mt[n].includes(a)},mt={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},ft=Object.keys(mt),ti=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(ft.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${ft.join("|")}`)},ni=e=>typeof e=="string"&&/^[v\d]/.test(e)&&lt.test(e);function ii(e){const{gatewayInfo:i,supportedRange:n}=e;if(!i)return!0;const{edition:a,version:o}=i;if(!ni(o))return console.error("Invalid version"),!1;const A=n[a];if(!A)return!1;const[s,l]=A;return!(s&&ut(o,s,"<")||l&&ut(o,l,">"))}const _={useAxios:He,useDebouncedFilter:Kn,useDeleteUrlBuilder:Jn,useErrors:Qn,useFetcher:Wn,useFetchUrlBuilder:At,useHelpers:Zn,useStringHelpers:qn,useI18n:Pe,useGatewayFeatureSupported:ii},ai={fail:"Failed to copy id to clipboard",success:{prefix:"Successfully",content:" copied to clipboard"}},oi="Copy to clipboard",ri={message:ai,iconTitle:oi},si="kong-ui-copy-uuid-notify",Ai={class:"kong-ui-copy-uuid"},li=["onClick"],Ct=15,ci=t.defineComponent({__name:"CopyUuid",props:{uuid:{type:String,required:!0},idTooltip:{type:String,default:""},truncated:{type:Boolean,default:!0},useMono:{type:Boolean,default:!0},notify:{type:Function,default:void 0},iconColor:{type:String,default:"rgba(0, 0, 0, 0.45)"},tooltip:{type:String,default:""},successTooltip:{type:String,default:""},format:{type:String,required:!1,default:"uuid",validator:e=>["uuid","hidden","redacted","deleted"].includes(e)}},emits:["success","error"],setup(e,{emit:i}){const n=e,{t:a}=Ee.createI18n("en-us",ri),o=n.notify||t.inject(si,()=>{}),A=t.computed(()=>n.idTooltip?{label:n.idTooltip,positionFixed:!0,placement:"bottomStart"}:{title:n.uuid}),s=t.computed(()=>!!(n.tooltip&&n.successTooltip)),l=t.ref(n.tooltip),c=t.computed(()=>n.tooltip?{label:l.value,positionFixed:!0,maxWidth:"500px",placement:"bottomStart"}:{}),p=t.computed(()=>n.format==="redacted"?"*****":n.format==="deleted"?`*${n.uuid.substring(0,5)}`:n.uuid),g=f=>{l.value=f,setTimeout(()=>{l.value=n.tooltip},1800)},d=f=>{if(!f(n.uuid)){typeof o=="function"&&o({type:"error",message:a("message.fail")}),s.value?g(a("message.fail")):i("error",n.uuid);return}const C=n.uuid.length>Ct,B=n.format==="hidden"||n.format==="redacted"?a("message.success.prefix"):`"${n.uuid.substring(0,Ct)+(C?"...":"")}"`;typeof o=="function"&&o({type:"success",message:`${B}${a("message.success.content")}`}),s.value?g(n.successTooltip):i("success",n.uuid)};return(f,C)=>{const B=t.resolveComponent("KIcon"),w=t.resolveComponent("KClipboardProvider");return t.openBlock(),t.createElementBlock("div",Ai,[e.format!=="hidden"?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.idTooltip?"KTooltip":"div"),t.mergeProps({key:0},A.value,{"data-testid":"copy-id"}),{default:t.withCtx(()=>[t.createElementVNode("div",{class:t.normalizeClass(["uuid-container",e.truncated?"truncated-uuid":null,e.useMono?"mono":null])},t.toDisplayString(p.value),3)]),_:1},16)):t.createCommentVNode("",!0),(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.tooltip?"KTooltip":"div"),t.mergeProps(c.value,{class:"uuid-icon-wrapper"}),{default:t.withCtx(()=>[t.createVNode(w,null,{default:t.withCtx(({copyToClipboard:m})=>[t.createElementVNode("span",{"data-testid":"copy-to-clipboard",role:"button",tabindex:"0",onClick:t.withModifiers(y=>d(m),["stop"])},[t.createVNode(B,{class:"uuid-icon",color:e.iconColor,"hide-title":!!e.tooltip||void 0,icon:"copy",size:"16",title:t.unref(a)("iconTitle")},null,8,["color","hide-title","title"])],8,li)]),_:1})]),_:1},16))])}}}),di=(e,i)=>{const n=e.__vccOpts||e;for(const[a,o]of i)n[a]=o;return n},Et=di(ci,[["__scopeId","data-v-bfdaf6f7"]]),pi={key:0,class:"config-card-fieldset-title"},gi=t.defineComponent({__name:"JsonCardItem",props:{item:{type:Object,required:!0},index:{type:Number,default:-1},isArrayItem:{type:Boolean,default:!1}},setup(e){const i=e,{i18n:{t:n}}=_.useI18n(),{convertKeyToTitle:a}=_.useStringHelpers(),o=t.computed(()=>i.item.key??"json-array-item"),A=t.computed(()=>i.item.value??i.item),s=t.computed(()=>{const c=JSON.parse(JSON.stringify(A.value));return i.isArrayItem&&delete c.name,c}),l=t.computed(()=>{var c;return i.isArrayItem?(c=A.value)!=null&&c.name?a(A.value.name,"_"):n("baseConfigCard.general.entryTitle",{index:i.index}):""});return(c,p)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.isArrayItem?"fieldset":"div"),{class:t.normalizeClass(e.isArrayItem?"config-card-fieldset":"config-card-json-item")},{default:t.withCtx(()=>[e.isArrayItem?(t.openBlock(),t.createElementBlock("legend",pi,[t.createElementVNode("b",null,t.toDisplayString(l.value),1)])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(Object.keys(s.value),(g,d)=>(t.openBlock(),t.createBlock(Ue,{key:`${o.value}-property-${d}`,item:{key:g,label:t.unref(a)(g),value:s.value[g]}},null,8,["item"]))),128))]),_:1},8,["class"]))}}),se=(e,i)=>{const n=e.__vccOpts||e;for(const[a,o]of i)n[a]=o;return n},ht=se(gi,[["__scopeId","data-v-68ca83ec"]]),ui=se(t.defineComponent({__name:"InternalLinkItem",props:{item:{type:Object,required:!0}},emits:["navigation-click"],setup(e){const{i18n:{t:i}}=_.useI18n();return(n,a)=>{const o=t.resolveComponent("KButton");return t.openBlock(),t.createElementBlock("div",null,[t.createVNode(o,{appearance:"btn-link",class:"navigation-button",onClick:a[0]||(a[0]=A=>n.$emit("navigation-click",e.item))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.item.value||t.unref(i)("baseConfigCard.commonFields.link")),1)]),_:1})])}}}),[["__scopeId","data-v-7410504d"]]),mi=t.defineComponent({__name:"StatusBadge",props:{status:{type:Boolean,default:!1}},setup(e){const{i18n:{t:i}}=_.useI18n();return(n,a)=>{const o=t.resolveComponent("KBadge");return t.openBlock(),t.createBlock(o,{appearance:e.status?"success":"neutral"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.status?t.unref(i)("baseConfigCard.statusBadge.enabledLabel"):t.unref(i)("baseConfigCard.statusBadge.disabledLabel")),1)]),_:1},8,["appearance"])}}}),fi="#0044f4",Ci="#e0e4ea",Ei="#3a3f51",hi="1px",wi="20px",Bi={class:"config-card-details-row"},yi=["data-testid"],bi=["data-testid"],Oi=["data-testid"],Ii=["data-testid"],Mi={key:1},Ri=["data-testid"],Si=["data-testid"],xi=["data-testid"],Ti=["data-testid"],vi=["title"],Di={name:"ConfigCardItem",components:{CopyUuid:Et,JsonCardItem:ht,StatusBadge:mi,InternalLinkItem:ui}},Li=t.defineComponent({...Di,props:{item:{type:Object,required:!0},slim:{type:Boolean,required:!1,default:!1},truncated:{type:Boolean,required:!1,default:!1}},emits:["navigation-click"],setup(e,{emit:i}){const n=e;t.useCssVars(d=>({"2c6ac268":p.value?"none":`solid ${t.unref(hi)} ${t.unref(Ci)}`,c7a65802:c.value&&s.value?"block":"flex","778426fe":c.value&&s.value?"100%":n.slim?"50%":"25%","777f9b48":c.value&&s.value?"100%":n.slim?"50%":"75%"}));const a=t.useSlots(),{i18n:{t:o,formatUnixTimeStamp:A}}=_.useI18n(),s=t.computed(()=>n.item.value!==void 0&&n.item.value!==null&&n.item.value!==""),l=t.computed(()=>!!(n.item.tooltip||a["label-tooltip"])),c=t.computed(()=>n.item.type===L.Json||n.item.type===L.JsonArray),p=t.computed(()=>n.item.type===L.JsonArray),g=t.computed(()=>{switch(n.item.type){case L.ID:return{tag:"CopyUuid",attrs:{"data-testid":`${n.item.key}-copy-uuid`,"success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,uuid:n.item.value,notify:()=>{}}};case L.IdArray:return{tag:"div",additionalComponent:"CopyUuid",childAttrs:{"success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,notify:()=>{}}};case L.Redacted:return{tag:"CopyUuid",attrs:{"data-testid":`${n.item.key}-copy-uuid-redacted`,format:"redacted","success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,uuid:n.item.value,notify:()=>{}}};case L.RedactedArray:return{tag:"div",additionalComponent:"CopyUuid",childAttrs:{format:"redacted","success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,notify:()=>{}}};case L.Date:return{tag:"div",attrs:{"data-testid":`${n.item.key}-date`},text:A(n.item.value)};case L.BadgeStatus:return{tag:"StatusBadge",attrs:{"data-testid":`${n.item.key}-badge-status`,status:n.item.value}};case L.BadgeTag:return{tag:"div",additionalComponent:"KBadge"};case L.BadgeMethod:return{tag:"div",additionalComponent:"KMethodBadge"};case L.LinkInternal:return{tag:"InternalLinkItem",attrs:{"data-testid":`${n.item.key}-internal-link`,item:n.item,onNavigationClick:d=>{i("navigation-click",d)}}};case L.LinkExternal:return{tag:"KExternalLink",attrs:{"data-testid":`${n.item.key}-external-link`,href:n.item.value},text:n.item.value};case L.Json:return{tag:"JsonCardItem",attrs:{"data-testid":`${n.item.key}-json-content`,item:n.item}};case L.JsonArray:return{tag:"div",additionalComponent:"JsonCardItem",attrs:{"data-testid":`${n.item.key}-json-array-content`,item:n.item}};default:return{tag:"div",attrs:{"data-testid":`${n.item.key}-plain-text`},text:n.item.value}}});return(d,f)=>{const C=t.resolveComponent("KLabel"),B=t.resolveComponent("KBadge"),w=t.resolveComponent("KMethodBadge");return t.openBlock(),t.createElementBlock("div",Bi,[t.createElementVNode("div",{class:"config-card-details-label","data-testid":`${e.item.key}-label`},[t.renderSlot(d.$slots,"label",{item:e.item},()=>[t.createVNode(C,{"tooltip-attributes":{maxWidth:"500px"}},t.createSlots({default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.item.label)+" ",1)]),_:2},[l.value?{name:"tooltip",fn:t.withCtx(()=>[t.createElementVNode("div",{"data-testid":`${e.item.key}-label-tooltip`},[t.renderSlot(d.$slots,"label-tooltip",{},()=>[t.createTextVNode(t.toDisplayString(e.item.tooltip),1)],!0)],8,bi)]),key:"0"}:void 0]),1024)],!0)],8,yi),t.createElementVNode("div",{class:"config-card-details-value","data-testid":`${e.item.key}-property-value`},[t.renderSlot(d.$slots,e.item.key,{rowValue:e.item.value},()=>[s.value?(t.openBlock(),t.createElementBlock("div",Mi,[(t.openBlock(),t.createBlock(t.resolveDynamicComponent(g.value.tag),t.normalizeProps(t.guardReactiveProps(g.value.attrs)),{default:t.withCtx(()=>[g.value.additionalComponent==="KBadge"?(t.openBlock(),t.createElementBlock("div",{key:0,"data-testid":`${e.item.key}-badge-tags`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(B,{key:`${e.item.key}-badge-tag-${y}`,class:"config-badge","data-testid":`${e.item.key}-badge-tag-${y}`,"truncation-tooltip":m},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m),1)]),_:2},1032,["data-testid","truncation-tooltip"]))),128))],8,Ri)):t.createCommentVNode("",!0),g.value.additionalComponent==="CopyUuid"?(t.openBlock(),t.createElementBlock("div",{key:1,class:"copy-uuid-array","data-testid":`${e.item.key}-copy-uuid-array`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(t.unref(Et),t.mergeProps(g.value.childAttrs,{key:`${e.item.key}-copy-uuid-${y}`,"data-testid":`${e.item.key}-copy-uuid-${y}`,uuid:m}),null,16,["data-testid","uuid"]))),128))],8,Si)):g.value.additionalComponent==="KMethodBadge"?(t.openBlock(),t.createElementBlock("div",{key:2,class:"method-badge-array","data-testid":`${e.item.key}-badge-methods`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(w,{key:`${e.item.key}-badge-method-${y}`,class:"config-badge","data-testid":`${e.item.key}-badge-method-${y}`,"is-rounded":"",label:m,method:t.unref(vn.MethodsArray).includes(m.toLowerCase())?m.toLowerCase():"custom"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m),1)]),_:2},1032,["data-testid","label","method"]))),128))],8,xi)):t.createCommentVNode("",!0),g.value.additionalComponent==="JsonCardItem"?(t.openBlock(),t.createElementBlock("div",{key:3,"data-testid":`${n.item.key}-json-array-content`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(ht,{key:`json-array-item-${y}`,index:y,"is-array-item":"",item:m},null,8,["index","item"]))),128))],8,Ti)):(t.openBlock(),t.createElementBlock("span",{key:4,class:t.normalizeClass(["attrs-data-text",{truncated:e.truncated}]),title:e.truncated?e.item.value:void 0},t.toDisplayString(g.value.text),11,vi))]),_:1},16))])):(t.openBlock(),t.createElementBlock("div",{key:0,"data-testid":`${e.item.key}-no-value`}," – ",8,Ii))],!0)],8,Oi)])}}}),Ue=se(Li,[["__scopeId","data-v-a3c5ab01"]]);/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function wt(e){return typeof e>"u"||e===null}function Yi(e){return typeof e=="object"&&e!==null}function ki(e){return Array.isArray(e)?e:wt(e)?[]:[e]}function Ni(e,i){var n,a,o,A;if(i)for(A=Object.keys(i),n=0,a=A.length;n<a;n+=1)o=A[n],e[o]=i[o];return e}function Gi(e,i){var n="",a;for(a=0;a<i;a+=1)n+=e;return n}function Vi(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}var Hi=wt,ji=Yi,Pi=ki,Ui=Gi,Fi=Vi,zi=Ni,X={isNothing:Hi,isObject:ji,toArray:Pi,repeat:Ui,isNegativeZero:Fi,extend:zi};function Bt(e,i){var n="",a=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!i&&e.mark.snippet&&(n+=`
1
+ (function(W,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@kong-ui-public/i18n"),require("axios"),require("@kong/kongponents"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","@kong-ui-public/i18n","axios","@kong/kongponents","vue-router"],t):(W=typeof globalThis<"u"?globalThis:W||self,t(W["kong-ui-public-entities-plugins"]={},W.Vue,W["kong-ui-public-i18n"],W.axios,W.Kongponents,W.VueRouter))})(this,function(W,t,Ee,Tn,vn,Dn){"use strict";const Ln={actions:{create:"New Plugin",copy_id:"Copy ID",copy_json:"Copy JSON",edit:"Edit",delete:"Delete",view:"View Details",configure_dynamic_ordering:"Configure Dynamic Ordering"},delete:{title:"Delete Plugin",description:"Are you sure you want to delete this plugin? This action cannot be reversed."},copy:{success:"Copied {val} to clipboard",success_brief:"Successfully copied to clipboard",tooltip:"Copy {label}",success_tooltip:"Copied!"},errors:{general:"Plugins could not be retrieved",delete:"The plugin could not be deleted at this time.",copy:"Failed to copy to clipboard"},search:{placeholder:{konnect:"Filter by exact instance name or ID"},filter:{field:{enabled:"Enabled"}}},plugins:{title:"Plugins",list:{toolbar_actions:{new_plugin:"New Plugin"},table_headers:{applied_to:"Applied To",applied_to_badges:{consumer:"Consumer",global:"Global",route:"Route",service:"Service",consumer_group:"Consumer Group"},id:"ID",name:"Name",instance_name:"Instance Name",ordering:"Ordering",ordering_badge:{dynamic:"Dynamic",static:"Static"},status:"Status",status_label:{enabled:"Enabled",disabled:"Disabled"},tags:"Tags"},empty_state:{title:"Configure a New Plugin",description:"Improve the security of your Kong Gateway deployment with centralized secrets."}},meta:{"basic-auth":{name:"Basic Authentication",description:"Add Basic Authentication to your Services"},"hmac-auth":{name:"HMAC Authentication",description:"Add HMAC Authentication to your Services"},"jwt-signer":{name:"JWT Signer",description:"Verify and (re-)sign one or two tokens in a request"},jwt:{name:"JWT",description:"Verify and authenticate JSON Web Tokens"},"key-auth":{name:"Key Authentication",description:"Add key authentication to your Services"},"key-auth-enc":{name:"Key Authentication Encrypted",description:"Add key authentication to your Services with an encrypted token"},"ldap-auth-advanced":{name:"LDAP Authentication Advanced",description:"Integrate Kong with a LDAP server"},"ldap-auth":{name:"LDAP Authentication",description:"Integrate Kong with a LDAP server"},"oauth2-introspection":{name:"OAuth 2.0 Introspection",description:"Integrate Kong with a third-party OAuth 2.0 Authorization Server"},oauth2:{name:"OAuth 2.0 Authentication",description:"Add OAuth 2.0 authentication to your Services"},"openid-connect":{name:"OpenID Connect",description:"Integrate Kong with a third-party OpenID Connect 1.0 Provider"},"mtls-auth":{name:"Mutual TLS Authentication",description:"Secure routes and services with client certificate and mutual TLS authentication"},"vault-auth":{name:"Vault Authentication",description:"Secure routes and services with an access token and secret token, stored securely via Vault"},"bot-detection":{name:"Bot Detection",description:"Detect and clock bots or custom clients"},cors:{name:"CORS",description:"Allow developers to make requests from the browser"},"ip-restriction":{name:"IP Restriction",description:"Whitelist or blacklist IPs that can make requests"},opa:{name:"OPA",description:"Authorize requests against Open Policy Agent"},"kubernetes-sidecar-injector":{name:"Kubernetes Sidecar Injector",description:"This plugin will inject Kong dataplane nodes and form a service mesh on top of Kubernetes"},"request-validator":{name:"Request Validator",description:"Validate requests before they reach their upstream Service. "},acl:{name:"ACL",description:"Control which consumers can access Services"},canary:{name:"Canary Release",description:"Methodically roll out software changes to a subset of users"},"forward-proxy":{name:"Forward Proxy",description:"Allow Kong to connect to intermediary transparent HTTP proxies"},"proxy-cache":{name:"Proxy Caching",description:"Cache and serve commonly requested responses in Kong"},"proxy-cache-advanced":{name:"Proxy Caching Advanced",description:"Cache and serve commonly requested responses in Kong"},"graphql-proxy-cache-advanced":{name:"GraphQL Proxy Caching Advanced",description:"Cache and serve commonly requested responses in Kong"},"rate-limiting-advanced":{name:"Rate Limiting Advanced",description:"Rate-limit how many HTTP requests a developer can make"},"rate-limiting":{name:"Rate Limiting",description:"Rate-limit how many HTTP requests a developer can make"},"graphql-rate-limiting-advanced":{name:"GraphQL Rate Limiting Advanced",description:"Rate-limit how many HTTP requests a developer can make"},mocking:{name:"Mocking",description:"Provide mock endpoints to test your APIs in development against your services"},"request-size-limiting":{name:"Request Size Limiting",description:"Block requests with bodies greater than a specific size"},"request-termination":{name:"Request Termination",description:"Terminate all requests with a specific response"},"response-ratelimiting":{name:"Response Rate Limiting",description:"Rate-Limiting based on a custom response header value"},"route-by-header":{name:"Route by Header",description:"Route requests based on request headers"},"aws-lambda":{name:"AWS Lambda",description:"Invoke and manage AWS Lambda functions from Kong"},"azure-functions":{name:"Azure Functions",description:"Invoke Azure functions"},openwhisk:{name:"OpenWhisk",description:"Invoke and manage OpenWhisk actions from Kong"},"pre-function":{name:"Kong Functions (Pre-Plugins)",description:"Add and manage custom lua functions to run before other plugins"},"post-function":{name:"Kong Functions (Post-Plugins)",description:"Add and manage custom lua functions to run after other plugins"},datadog:{name:"Datadog",description:"Visualize metrics on Datadog"},prometheus:{name:"Prometheus",description:"Export performance metrics to Prometheus"},zipkin:{name:"Zipkin",description:"Propagate zipkin spans and report spans to a zipkin server"},collector:{name:"Collector",description:"Automate spec-driven development & anomaly detection (Early Access)"},"response-transformer-advanced":{name:"Response Transformer Advanced",description:"Transform the response sent by the upstream server on the fly on Kong, before returning the response to the client."},"correlation-id":{name:"Correlation ID",description:"Correlate requests and responses using a unique ID"},"request-transformer-advanced":{name:"Request Transformer Advanced",description:"Use powerful regular expressions, variables and templates to transform API requests"},"request-transformer":{name:"Request Transformer",description:"Modify the request before hitting the upstream server"},"response-transformer":{name:"Response Transformer",description:"Modify the upstream response before returning it to the client"},"route-transformer-advanced":{name:"Route Transformer Advanced",description:"Transforms the routing on the fly in Kong, changing the upstream server/port/path to hit"},"kafka-upstream":{name:"Kafka Upstream",description:"Transform requests into Kafka messages in a topic"},degraphql:{name:"DeGraphQL",description:"Transform a GraphQL upstream into a REST API"},"exit-transformer":{name:"Exit Transformer",description:"Customize Kong exit responses sent downstream"},jq:{name:"jq",description:"Transform JSON objects included in API requests or responses using jq programs"},"file-log":{name:"File Log",description:"Append request and response data to a log file on disk"},"http-log":{name:"HTTP Log",description:"Send request and response logs to an HTTP server"},loggly:{name:"Loggly",description:"Send request and response logs to Loggly"},"statsd-advanced":{name:"StatsD Advanced",description:"Send traffic and Kong performance metrics to StatsD"},statsd:{name:"StatsD",description:"Send request and response logs to StatsD"},syslog:{name:"Syslog",description:"Send request and response logs to Syslog"},"tcp-log":{name:"TCP Log",description:"Send request and response logs to a TCP server"},"udp-log":{name:"UDP Log",description:"Send request and response logs to a UDP server"},"kafka-log":{name:"Kafka Log",description:"Publish request and response logs to a Kafka topic"},session:{name:"Session",description:"Sessions for Kong authentication"},"upstream-tls":{name:"Upstream TLS",description:"Enable TLS on upstream traffic by providing Kong with a list of trusted certificates."},"application-registration":{name:"Portal Application Registration",description:"Allow portal developers to register applications against services"},"konnect-application-auth":{name:"Konnect Application Auth",description:"Allow Konnect portal developers to register applications against services"},acme:{name:"ACME",description:"Let's Encrypt and ACMEv2 integration with Kong"},"grpc-gateway":{name:"gRPC Gateway",description:"Access gRPC services through HTTP REST"},"grpc-web":{name:"gRPC Web",description:"Allow browser clients to call gRPC services"},"upstream-timeout":{name:"Upstream Timeout",description:"Configure read, send and connect timeouts to an upstream"},opentelemetry:{name:"OpenTelemetry",description:"Propagate distributed tracing spans and report low-level spans to a OTLP-compatible server"},"websocket-validator":{name:"WebSocket Validator",description:"Validate individual WebSocket messages against to a user-specified schema before proxying them"},"websocket-size-limit":{name:"WebSocket Size Limit",description:"Allows operators to specify a maximum size for incoming WebSocket messages"},"tls-metadata-headers":{name:"TLS Metadata Headers",description:"Detects client certificates in requests, retrieves the TLS metadata, and proxies this metadata via HTTP headers"},"tls-handshake-modifier":{name:"TLS Handshake Modifier",description:"Requests the client certificate and if it exists, makes it available to other plugins acting on the request"},"oas-validation":{name:"OAS Validation",description:"Validate HTTP requests and responses based on an API Specification."},"jwe-decrypt":{name:"Kong JWE Decrypt",description:"The Kong JWE Decrypt plugin makes it possible to decrypt an inbound token(JWE) in a request."},"xml-threat-protection":{name:"XML Threat Protection",description:"Reduce the risk of XML attacks by checking the structure of XML payloads."},saml:{name:"SAML",description:"Security Assertion Markup Language (SAML) is an open standard for exchanging authentication and authorization data between an identity provider and a service provider."},"app-dynamics":{name:"AppDynamics",description:"This plugin integrates Kong with the AppDynamics APM platform so that proxy requests handled by Kong can be identified and analyzed in AppDynamics."}},fields:{service:"Service ID",route:"Route ID",consumer:"Consumer ID",consumer_group:"Consumer Group ID"}},glossary:{plugin:"plugin"}};function rt(){const e=Ee.createI18n("en-us",Ln);return{i18n:e,i18nT:Ee.i18nTComponent(e)}}var st=(e=>(e.GatewayService="service",e.Route="route",e.Consumer="consumer",e.ConsumerGroup="consumer group",e.Plugin="plugin",e.Upstream="upstream",e.Certificate="certificate",e.CACertificate="ca certificate",e.SNI="SNI",e.Key="key",e.KeySet="key set",e.Vault="vault",e.Application="application",e.Developer="developer",e.acls="ACL Credential",e["basic-auth"]="Basic Auth Credential",e["key-auth"]="Key Auth Credential",e["key-auth-enc"]="Key Auth Encrypted Credential",e.oauth2="OAuth 2.0 Credential",e["hmac-auth"]="HMAC Credential",e.jwt="JWT Credential",e.Target="target",e.Policy="policy",e))(st||{}),pe=(e=>(e[e.Loading=0]="Loading",e[e.Idle=1]="Idle",e[e.NoResults=2]="NoResults",e[e.Error=3]="Error",e))(pe||{}),L=(e=>(e.ID="id",e.IdArray="id-array",e.Text="plain-text",e.Date="date",e.Redacted="redacted",e.RedactedArray="redacted-array",e.Json="json",e.JsonArray="json-array",e.BadgeTag="badge-tag",e.BadgeStatus="badge-status",e.BadgeMethod="badge-method",e.LinkInternal="link-internal",e.LinkExternal="link-external",e))(L||{}),J=(e=>(e.Basic="basic",e.Advanced="advanced",e.Plugin="plugin",e))(J||{});function He(e={}){return{axiosInstance:Tn.create({withCredentials:!0,timeout:3e4,...e})}}function Yn(){return{debounce:(e,i)=>{let n;return(...a)=>{clearTimeout(n),n=window==null?void 0:window.setTimeout(()=>{e(...a)},i)}}}}const je="khcp-user-table-preferences",kn={pageSize:30,sortColumnKey:void 0,sortColumnOrder:void 0};function Nn(){const e=n=>{if(typeof n=="string")try{return JSON.parse(n)}catch(a){console.error("useTablePreferences(tryParseJson)",a);return}},i=()=>{const n=e(localStorage.getItem(je));return!n||!Object.keys(n).length?new Map:new Map(Object.entries(n))};return{setTablePreferences:(n,a)=>{try{const o=i();o.set(n,a),localStorage.setItem(je,JSON.stringify(Object.fromEntries(o.entries())))}catch(o){console.error("useTablePreferences(setTablePreferences)",o)}},getTablePreferences:n=>{const a=i();return(a==null?void 0:a.get(n))||void 0||kn},deleteAllTablePreferences:()=>{localStorage.removeItem(je)}}}const Gn={message:"Are you sure you want to delete this {entityType}?",messageWithName:"Are you sure you want to delete this {entityType} {entityName}?"},Vn={actions:{save:"Save",cancel:"Cancel",back:"Back"},errors:{edit:"The entity could not be edited at this time."}},Hn={emptyState:{noSearchResultsTitle:"No results found",noSearchResultsMessage:"Please adjust the criteria and try again.",noSearchResultsCtaText:"Clear"}},jn={title:"Configuration",actions:{copy:"Copy JSON"},sections:{advanced:"Advanced",plugin:"Plugin Specific Configuration"},commonFields:{id_label:"ID",name_label:"Name",enabled_label:"Enabled",enabled_tooltip:"Enabled is FTW",updated_at_label:"Last Updated",created_at_label:"Created",tags_label:"Tags",link:"Link"},statusBadge:{enabledLabel:"Enabled",disabledLabel:"Disabled"},copy:{tooltip:"Copy {label}",success:"Copied!"},errors:{load:"The entity configuration data could not be loaded at this time.",copy:"Failed to copy to clipboard"},general:{entryTitle:"Entry {index}",structuredFormat:"Structured"}},Pn={filterButtonText:"Filter",fieldLabel:"Filter by:",inputPlaceholder:"Enter a value",selectPlaceholder:"Select an item",applyButtonText:"Apply",clearButtonText:"Clear",clearAllButtonText:"Clear all filters"},Un={errors:{fetch:"Could not fetch available items",invalid:"Please select a valid value"}},Fn={unexpected:"An unexpected error has occurred",dataKeyUndefined:'The data key "{dataKey}" does not exist in the response.'},zn={enable:{title:"Enable {entityType}",message:"Are you sure you want to enable the {entityType} {entityName}?",confirmText:"Yes, enable"},disable:{title:"Disable {entityType}",message:"Are you sure you want to disable the {entityType} {entityName}?",confirmText:"Yes, disable"}},Xn={deleteModal:Gn,baseForm:Vn,baseTable:Hn,baseConfigCard:jn,filter:Pn,debouncedFilter:Un,errors:Fn,toggleModal:zn};function Pe(){const e=Ee.createI18n("en-us",Xn);return{i18n:e,i18nT:Ee.i18nTComponent(e)}}function Kn(e,i,n,a={fetchedItemsKey:"data",searchKeys:["id"]}){n||(n="100");const{axiosInstance:o}=He({headers:e.requestHeaders}),{i18n:{t:A}}=Pe(),{debounce:s}=Yn(),l=s(async u=>{await y(u)},200),c=t.ref(!1),p=t.ref(""),g=t.ref(""),d=t.ref([]),f=t.ref(void 0),C=t.unref(i);let B=`${e.apiBaseUrl}${C}`;e.app==="konnect"?B=B.replace(/{controlPlaneId}/gi,(e==null?void 0:e.controlPlaneId)||""):e.app==="kongManager"&&(B=B.replace(/\/{workspace}/gi,e!=null&&e.workspace?`/${e.workspace}`:""));const w=async()=>{try{c.value=!0;const{data:u}=await o.get(`${B}?size=${n}`);u!=null&&u.next||(f.value=a.fetchedItemsKey in u?u[a.fetchedItemsKey]:[]),d.value=a.fetchedItemsKey in u?u[a.fetchedItemsKey]:[]}catch{d.value=[],p.value=A("debouncedFilter.errors.fetch")}finally{c.value=!1}},m=t.ref(""),y=async u=>{var h,T;if(m.value!==u)if(m.value=u||"",f.value===void 0)try{c.value=!0,p.value="",g.value="";let Y=B+"";u&&(Y+=`/${u}`);const{data:M}=await o.get(`${Y}?size=${n}`);a.fetchedItemsKey in M?d.value=M[a.fetchedItemsKey]:M!=null&&M.id?d.value=[M]:d.value=[]}catch(Y){((h=Y==null?void 0:Y.response)==null?void 0:h.status)===404?g.value=A("debouncedFilter.errors.invalid"):(d.value=[],p.value=A("debouncedFilter.errors.fetch"))}finally{c.value=!1}else c.value=!0,g.value="",u?(d.value=(T=f.value)==null?void 0:T.filter(Y=>{var M;let k=!1;for(const b of a.searchKeys){const x=typeof Y[b]=="string"?(M=Y[b])==null?void 0:M.toLowerCase():Y[b];x!=null&&x.includes(u.toLowerCase())&&(k=!0)}return k}),(!d.value||!d.value.length)&&(g.value=A("debouncedFilter.errors.invalid"))):d.value=f.value,c.value=!1};return{loading:c,error:p,validationError:g,results:d,allRecords:f,loadItems:w,debouncedQueryChange:l}}function Jn(e,i){const n=t.unref(i),a=t.computed(()=>e.apiBaseUrl.startsWith("/")?new URL(`${window.location.origin}${n}`):new URL(n));return a.value.search="",o=>`${a.value.href}/${o}`}function Qn(){const{i18n:{t:e}}=Pe();return{getMessageFromError:i=>{var n,a,o;if(!i)return e("errors.unexpected");if((n=i==null?void 0:i.response)!=null&&n.data){if(i.response.data.detail)return i.response.data.detail;if((a=i.response.data.details)!=null&&a.length)return i.response.data.details.map(A=>{let s=e("errors.unexpected");return A.messages&&typeof A.messages=="object"&&A.messages.length&&(s=A.messages.join(", ")),A.field?`${A.field} - ${s}`:s}).join("; ");if(i.response.data.message){const{message:A}=i.response.data;return Array.isArray(A)?(o=A[0])!=null&&o.constraints?Object.values(A[0].constraints)[0]:A[0]:A}if(typeof i.response.data=="string")return i.response.data;if(typeof i.response.data=="object")return Object.keys(i.response.data).map(A=>`${A} ${i.response.data[A]}`).join(", ")}return i.message||e("errors.unexpected")}}}function At(e,i){const n=t.ref(t.unref(e)),a=t.ref(t.unref(i)),o=t.computed(()=>!!(n.value.app==="konnect"||n.value.isExactMatch)),A=t.computed(()=>a.value.startsWith("/")?new URL(`${window.location.origin}${a.value}`):new URL(a.value));return s=>{const{page:l,pageSize:c,offset:p,sortColumnKey:g,sortColumnOrder:d,query:f}=s;try{let C=new URL(A.value.href);return o.value&&f?(C.search="",C=new URL(`${C.href}/${f}/`)):(o.value||new URLSearchParams(f).forEach((B,w)=>{C.searchParams.append(w,B)}),g&&C.searchParams.append("sort_by",g),d==="desc"&&C.searchParams.append("sort_desc","1"),C.searchParams.append("size",String(c))),p&&l!==1&&C.searchParams.append("offset",String(p)),C.href}catch(C){return console.error("RouteList(fetcher)",C),a.value}}}function Wn(e,i,n="data"){const a=t.unref(i),{axiosInstance:o}=He({headers:e.requestHeaders}),A=At(e,a),s=t.ref({status:pe.Idle});return{fetcher:async l=>{try{s.value={status:pe.Loading};const c=A(l),{data:p}=await o.get(c),g=n&&n.replace(/[^\w-_]/gi,"");let d;p[g]&&Array.isArray(p[g])?d=p[g]:d=Object.keys(p).length?[p]:[];const f={data:d,total:d.length,...p.offset?{pagination:{offset:p.offset}}:null};return s.value={status:pe.Idle,response:f},f}catch(c){const p={data:[],total:0};return l.query&&c.response.status===404?(s.value={status:pe.NoResults,response:p,error:c},p):(s.value={status:pe.Error,response:p,error:c},p)}},fetcherState:s}}function Zn(){return{getPropValue:(e,i)=>(i==null?void 0:i[e])??void 0}}function qn(){return{convertKeyToTitle:(e,i="_")=>e?e.split(i).map(n=>n.toLowerCase()==="id"?n.toUpperCase():n.charAt(0).toUpperCase()+n.substring(1)).join(" "):""}}const lt=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,ct=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const i=e.match(lt);if(!i)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return i.shift(),i},dt=e=>e==="*"||e==="x"||e==="X",pt=e=>{const i=parseInt(e,10);return isNaN(i)?e:i},_n=(e,i)=>typeof e!=typeof i?[String(e),String(i)]:[e,i],$n=(e,i)=>{if(dt(e)||dt(i))return 0;const[n,a]=_n(pt(e),pt(i));return n>a?1:n<a?-1:0},gt=(e,i)=>{for(let n=0;n<Math.max(e.length,i.length);n++){const a=$n(e[n]||"0",i[n]||"0");if(a!==0)return a}return 0},ei=(e,i)=>{const n=ct(e),a=ct(i),o=n.pop(),A=a.pop(),s=gt(n,a);return s!==0?s:o&&A?gt(o.split("."),A.split(".")):o||A?o?-1:1:0},ut=(e,i,n)=>{ti(n);const a=ei(e,i);return mt[n].includes(a)},mt={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},ft=Object.keys(mt),ti=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(ft.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${ft.join("|")}`)},ni=e=>typeof e=="string"&&/^[v\d]/.test(e)&&lt.test(e);function ii(e){const{gatewayInfo:i,supportedRange:n}=e;if(!i)return!0;const{edition:a,version:o}=i;if(!ni(o))return console.error("Invalid version"),!1;const A=n[a];if(!A)return!1;const[s,l]=A;return!(s&&ut(o,s,"<")||l&&ut(o,l,">"))}const _={useAxios:He,useDebouncedFilter:Kn,useDeleteUrlBuilder:Jn,useErrors:Qn,useFetcher:Wn,useFetchUrlBuilder:At,useHelpers:Zn,useStringHelpers:qn,useI18n:Pe,useGatewayFeatureSupported:ii},ai={fail:"Failed to copy id to clipboard",success:{prefix:"Successfully",content:" copied to clipboard"}},oi="Copy to clipboard",ri={message:ai,iconTitle:oi},si="kong-ui-copy-uuid-notify",Ai={class:"kong-ui-copy-uuid"},li=["onClick"],Ct=15,ci=t.defineComponent({__name:"CopyUuid",props:{uuid:{type:String,required:!0},idTooltip:{type:String,default:""},truncated:{type:Boolean,default:!0},useMono:{type:Boolean,default:!0},notify:{type:Function,default:void 0},iconColor:{type:String,default:"rgba(0, 0, 0, 0.45)"},tooltip:{type:String,default:""},successTooltip:{type:String,default:""},format:{type:String,required:!1,default:"uuid",validator:e=>["uuid","hidden","redacted","deleted"].includes(e)}},emits:["success","error"],setup(e,{emit:i}){const n=e,{t:a}=Ee.createI18n("en-us",ri),o=n.notify||t.inject(si,()=>{}),A=t.computed(()=>n.idTooltip?{label:n.idTooltip,positionFixed:!0,placement:"bottomStart"}:{title:n.uuid}),s=t.computed(()=>!!(n.tooltip&&n.successTooltip)),l=t.ref(n.tooltip),c=t.computed(()=>n.tooltip?{label:l.value,positionFixed:!0,maxWidth:"500px",placement:"bottomStart"}:{}),p=t.computed(()=>n.format==="redacted"?"*****":n.format==="deleted"?`*${n.uuid.substring(0,5)}`:n.uuid),g=f=>{l.value=f,setTimeout(()=>{l.value=n.tooltip},1800)},d=f=>{if(!f(n.uuid)){typeof o=="function"&&o({type:"error",message:a("message.fail")}),s.value?g(a("message.fail")):i("error",n.uuid);return}const C=n.uuid.length>Ct,B=n.format==="hidden"||n.format==="redacted"?a("message.success.prefix"):`"${n.uuid.substring(0,Ct)+(C?"...":"")}"`;typeof o=="function"&&o({type:"success",message:`${B}${a("message.success.content")}`}),s.value?g(n.successTooltip):i("success",n.uuid)};return(f,C)=>{const B=t.resolveComponent("KIcon"),w=t.resolveComponent("KClipboardProvider");return t.openBlock(),t.createElementBlock("div",Ai,[e.format!=="hidden"?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.idTooltip?"KTooltip":"div"),t.mergeProps({key:0},A.value,{"data-testid":"copy-id"}),{default:t.withCtx(()=>[t.createElementVNode("div",{class:t.normalizeClass(["uuid-container",e.truncated?"truncated-uuid":null,e.useMono?"mono":null])},t.toDisplayString(p.value),3)]),_:1},16)):t.createCommentVNode("",!0),(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.tooltip?"KTooltip":"div"),t.mergeProps(c.value,{class:"uuid-icon-wrapper"}),{default:t.withCtx(()=>[t.createVNode(w,null,{default:t.withCtx(({copyToClipboard:m})=>[t.createElementVNode("span",{"data-testid":"copy-to-clipboard",role:"button",tabindex:"0",onClick:t.withModifiers(y=>d(m),["stop"])},[t.createVNode(B,{class:"uuid-icon",color:e.iconColor,"hide-title":!!e.tooltip||void 0,icon:"copy",size:"16",title:t.unref(a)("iconTitle")},null,8,["color","hide-title","title"])],8,li)]),_:1})]),_:1},16))])}}}),di=(e,i)=>{const n=e.__vccOpts||e;for(const[a,o]of i)n[a]=o;return n},Et=di(ci,[["__scopeId","data-v-bfdaf6f7"]]),pi={key:0,class:"config-card-fieldset-title"},gi=t.defineComponent({__name:"JsonCardItem",props:{item:{type:Object,required:!0},index:{type:Number,default:-1},isArrayItem:{type:Boolean,default:!1}},setup(e){const i=e,{i18n:{t:n}}=_.useI18n(),{convertKeyToTitle:a}=_.useStringHelpers(),o=t.computed(()=>i.item.key??"json-array-item"),A=t.computed(()=>i.item.value??i.item),s=t.computed(()=>{const c=JSON.parse(JSON.stringify(A.value));return i.isArrayItem&&delete c.name,c}),l=t.computed(()=>{var c;return i.isArrayItem?(c=A.value)!=null&&c.name?a(A.value.name,"_"):n("baseConfigCard.general.entryTitle",{index:i.index}):""});return(c,p)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.isArrayItem?"fieldset":"div"),{class:t.normalizeClass(e.isArrayItem?"config-card-fieldset":"config-card-json-item")},{default:t.withCtx(()=>[e.isArrayItem?(t.openBlock(),t.createElementBlock("legend",pi,[t.createElementVNode("b",null,t.toDisplayString(l.value),1)])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(Object.keys(s.value),(g,d)=>(t.openBlock(),t.createBlock(Ue,{key:`${o.value}-property-${d}`,item:{key:g,label:t.unref(a)(g),value:s.value[g]}},null,8,["item"]))),128))]),_:1},8,["class"]))}}),se=(e,i)=>{const n=e.__vccOpts||e;for(const[a,o]of i)n[a]=o;return n},ht=se(gi,[["__scopeId","data-v-68ca83ec"]]),ui=se(t.defineComponent({__name:"InternalLinkItem",props:{item:{type:Object,required:!0}},emits:["navigation-click"],setup(e){const{i18n:{t:i}}=_.useI18n();return(n,a)=>{const o=t.resolveComponent("KButton");return t.openBlock(),t.createElementBlock("div",null,[t.createVNode(o,{appearance:"btn-link",class:"navigation-button",onClick:a[0]||(a[0]=A=>n.$emit("navigation-click",e.item))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.item.value||t.unref(i)("baseConfigCard.commonFields.link")),1)]),_:1})])}}}),[["__scopeId","data-v-7410504d"]]),mi=t.defineComponent({__name:"StatusBadge",props:{status:{type:Boolean,default:!1}},setup(e){const{i18n:{t:i}}=_.useI18n();return(n,a)=>{const o=t.resolveComponent("KBadge");return t.openBlock(),t.createBlock(o,{appearance:e.status?"success":"neutral"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.status?t.unref(i)("baseConfigCard.statusBadge.enabledLabel"):t.unref(i)("baseConfigCard.statusBadge.disabledLabel")),1)]),_:1},8,["appearance"])}}}),fi="#0044f4",Ci="#e0e4ea",Ei="#3a3f51",hi="1px",wi="20px",Bi={class:"config-card-details-row"},yi=["data-testid"],bi=["data-testid"],Oi=["data-testid"],Ii=["data-testid"],Mi={key:1},Ri=["data-testid"],Si=["data-testid"],xi=["data-testid"],Ti=["data-testid"],vi=["title"],Di={name:"ConfigCardItem",components:{CopyUuid:Et,JsonCardItem:ht,StatusBadge:mi,InternalLinkItem:ui}},Li=t.defineComponent({...Di,props:{item:{type:Object,required:!0},slim:{type:Boolean,required:!1,default:!1},truncated:{type:Boolean,required:!1,default:!1}},emits:["navigation-click"],setup(e,{emit:i}){const n=e;t.useCssVars(d=>({"2c6ac268":p.value?"none":`solid ${t.unref(hi)} ${t.unref(Ci)}`,c7a65802:c.value&&s.value?"block":"flex","778426fe":c.value&&s.value?"100%":n.slim?"50%":"25%","777f9b48":c.value&&s.value?"100%":n.slim?"50%":"75%"}));const a=t.useSlots(),{i18n:{t:o,formatUnixTimeStamp:A}}=_.useI18n(),s=t.computed(()=>n.item.value!==void 0&&n.item.value!==null&&n.item.value!==""),l=t.computed(()=>!!(n.item.tooltip||a["label-tooltip"])),c=t.computed(()=>n.item.type===L.Json||n.item.type===L.JsonArray),p=t.computed(()=>n.item.type===L.JsonArray),g=t.computed(()=>{switch(n.item.type){case L.ID:return{tag:"CopyUuid",attrs:{"data-testid":`${n.item.key}-copy-uuid`,"success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,uuid:n.item.value,notify:()=>{}}};case L.IdArray:return{tag:"div",additionalComponent:"CopyUuid",childAttrs:{"success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,notify:()=>{}}};case L.Redacted:return{tag:"CopyUuid",attrs:{"data-testid":`${n.item.key}-copy-uuid-redacted`,format:"redacted","success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,uuid:n.item.value,notify:()=>{}}};case L.RedactedArray:return{tag:"div",additionalComponent:"CopyUuid",childAttrs:{format:"redacted","success-tooltip":o("baseConfigCard.copy.success"),tooltip:o("baseConfigCard.copy.tooltip",{label:n.item.label}),truncated:!1,notify:()=>{}}};case L.Date:return{tag:"div",attrs:{"data-testid":`${n.item.key}-date`},text:A(n.item.value)};case L.BadgeStatus:return{tag:"StatusBadge",attrs:{"data-testid":`${n.item.key}-badge-status`,status:n.item.value}};case L.BadgeTag:return{tag:"div",additionalComponent:"KBadge"};case L.BadgeMethod:return{tag:"div",additionalComponent:"KMethodBadge"};case L.LinkInternal:return{tag:"InternalLinkItem",attrs:{"data-testid":`${n.item.key}-internal-link`,item:n.item,onNavigationClick:d=>{i("navigation-click",d)}}};case L.LinkExternal:return{tag:"KExternalLink",attrs:{"data-testid":`${n.item.key}-external-link`,href:n.item.value},text:n.item.value};case L.Json:return{tag:"JsonCardItem",attrs:{"data-testid":`${n.item.key}-json-content`,item:n.item}};case L.JsonArray:return{tag:"div",additionalComponent:"JsonCardItem",attrs:{"data-testid":`${n.item.key}-json-array-content`,item:n.item}};default:return{tag:"div",attrs:{"data-testid":`${n.item.key}-plain-text`},text:n.item.value}}});return(d,f)=>{const C=t.resolveComponent("KLabel"),B=t.resolveComponent("KBadge"),w=t.resolveComponent("KMethodBadge");return t.openBlock(),t.createElementBlock("div",Bi,[t.createElementVNode("div",{class:"config-card-details-label","data-testid":`${e.item.key}-label`},[t.renderSlot(d.$slots,"label",{item:e.item},()=>[t.createVNode(C,{"tooltip-attributes":{maxWidth:"500px"}},t.createSlots({default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.item.label)+" ",1)]),_:2},[l.value?{name:"tooltip",fn:t.withCtx(()=>[t.createElementVNode("div",{"data-testid":`${e.item.key}-label-tooltip`},[t.renderSlot(d.$slots,"label-tooltip",{},()=>[t.createTextVNode(t.toDisplayString(e.item.tooltip),1)],!0)],8,bi)]),key:"0"}:void 0]),1024)],!0)],8,yi),t.createElementVNode("div",{class:"config-card-details-value","data-testid":`${e.item.key}-property-value`},[t.renderSlot(d.$slots,e.item.key,{rowValue:e.item.value},()=>[s.value?(t.openBlock(),t.createElementBlock("div",Mi,[(t.openBlock(),t.createBlock(t.resolveDynamicComponent(g.value.tag),t.normalizeProps(t.guardReactiveProps(g.value.attrs)),{default:t.withCtx(()=>[g.value.additionalComponent==="KBadge"?(t.openBlock(),t.createElementBlock("div",{key:0,"data-testid":`${e.item.key}-badge-tags`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(B,{key:`${e.item.key}-badge-tag-${y}`,class:"config-badge","data-testid":`${e.item.key}-badge-tag-${y}`,"truncation-tooltip":m},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m),1)]),_:2},1032,["data-testid","truncation-tooltip"]))),128))],8,Ri)):t.createCommentVNode("",!0),g.value.additionalComponent==="CopyUuid"?(t.openBlock(),t.createElementBlock("div",{key:1,class:"copy-uuid-array","data-testid":`${e.item.key}-copy-uuid-array`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(t.unref(Et),t.mergeProps(g.value.childAttrs,{key:`${e.item.key}-copy-uuid-${y}`,"data-testid":`${e.item.key}-copy-uuid-${y}`,uuid:m}),null,16,["data-testid","uuid"]))),128))],8,Si)):g.value.additionalComponent==="KMethodBadge"?(t.openBlock(),t.createElementBlock("div",{key:2,class:"method-badge-array","data-testid":`${e.item.key}-badge-methods`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(w,{key:`${e.item.key}-badge-method-${y}`,class:"config-badge","data-testid":`${e.item.key}-badge-method-${y}`,"is-rounded":"",label:m,method:t.unref(vn.MethodsArray).includes(m.toLowerCase())?m.toLowerCase():"custom"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m),1)]),_:2},1032,["data-testid","label","method"]))),128))],8,xi)):t.createCommentVNode("",!0),g.value.additionalComponent==="JsonCardItem"?(t.openBlock(),t.createElementBlock("div",{key:3,"data-testid":`${n.item.key}-json-array-content`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.value,(m,y)=>(t.openBlock(),t.createBlock(ht,{key:`json-array-item-${y}`,index:y,"is-array-item":"",item:m},null,8,["index","item"]))),128))],8,Ti)):(t.openBlock(),t.createElementBlock("span",{key:4,class:t.normalizeClass(["attrs-data-text",{truncated:e.truncated}]),title:e.truncated?e.item.value:void 0},t.toDisplayString(g.value.text),11,vi))]),_:1},16))])):(t.openBlock(),t.createElementBlock("div",{key:0,"data-testid":`${e.item.key}-no-value`}," – ",8,Ii))],!0)],8,Oi)])}}}),Ue=se(Li,[["__scopeId","data-v-a3c5ab01"]]);/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function wt(e){return typeof e>"u"||e===null}function Yi(e){return typeof e=="object"&&e!==null}function ki(e){return Array.isArray(e)?e:wt(e)?[]:[e]}function Ni(e,i){var n,a,o,A;if(i)for(A=Object.keys(i),n=0,a=A.length;n<a;n+=1)o=A[n],e[o]=i[o];return e}function Gi(e,i){var n="",a;for(a=0;a<i;a+=1)n+=e;return n}function Vi(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}var Hi=wt,ji=Yi,Pi=ki,Ui=Gi,Fi=Vi,zi=Ni,X={isNothing:Hi,isObject:ji,toArray:Pi,repeat:Ui,isNegativeZero:Fi,extend:zi};function Bt(e,i){var n="",a=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!i&&e.mark.snippet&&(n+=`
2
2
 
3
3
  `+e.mark.snippet),a+" "+n):a}function Oe(e,i){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=i,this.message=Bt(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}Oe.prototype=Object.create(Error.prototype),Oe.prototype.constructor=Oe,Oe.prototype.toString=function(e){return this.name+": "+Bt(this,e)};var $=Oe;function Fe(e,i,n,a,o){var A="",s="",l=Math.floor(o/2)-1;return a-i>l&&(A=" ... ",i=a-l+A.length),n-a>l&&(s=" ...",n=a+l-s.length),{str:A+e.slice(i,n).replace(/\t/g,"→")+s,pos:a-i+A.length}}function ze(e,i){return X.repeat(" ",i-e.length)+e}function Xi(e,i){if(i=Object.create(i||null),!e.buffer)return null;i.maxLength||(i.maxLength=79),typeof i.indent!="number"&&(i.indent=1),typeof i.linesBefore!="number"&&(i.linesBefore=3),typeof i.linesAfter!="number"&&(i.linesAfter=2);for(var n=/\r?\n|\r|\0/g,a=[0],o=[],A,s=-1;A=n.exec(e.buffer);)o.push(A.index),a.push(A.index+A[0].length),e.position<=A.index&&s<0&&(s=a.length-2);s<0&&(s=a.length-1);var l="",c,p,g=Math.min(e.line+i.linesAfter,o.length).toString().length,d=i.maxLength-(i.indent+g+3);for(c=1;c<=i.linesBefore&&!(s-c<0);c++)p=Fe(e.buffer,a[s-c],o[s-c],e.position-(a[s]-a[s-c]),d),l=X.repeat(" ",i.indent)+ze((e.line-c+1).toString(),g)+" | "+p.str+`
4
4
  `+l;for(p=Fe(e.buffer,a[s],o[s],e.position,d),l+=X.repeat(" ",i.indent)+ze((e.line+1).toString(),g)+" | "+p.str+`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kong-ui-public/entities-plugins",
3
- "version": "1.4.0",
3
+ "version": "1.4.1",
4
4
  "type": "module",
5
5
  "main": "./dist/entities-plugins.umd.js",
6
6
  "module": "./dist/entities-plugins.es.js",
@@ -50,11 +50,11 @@
50
50
  },
51
51
  "dependencies": {
52
52
  "@kong-ui-public/copy-uuid": "^1.3.0",
53
- "@kong-ui-public/entities-consumer-groups": "^1.2.0",
54
- "@kong-ui-public/entities-consumers": "^1.2.0",
55
- "@kong-ui-public/entities-gateway-services": "^1.3.0",
56
- "@kong-ui-public/entities-routes": "^1.2.0",
57
- "@kong-ui-public/entities-shared": "^1.5.0"
53
+ "@kong-ui-public/entities-consumer-groups": "^1.2.1",
54
+ "@kong-ui-public/entities-consumers": "^1.2.1",
55
+ "@kong-ui-public/entities-gateway-services": "^1.3.1",
56
+ "@kong-ui-public/entities-routes": "^1.2.1",
57
+ "@kong-ui-public/entities-shared": "^1.5.1"
58
58
  },
59
59
  "scripts": {
60
60
  "dev": "cross-env USE_SANDBOX=true vite",