@kong-ui-public/entities-consumers 4.2.18 → 4.2.19-pr.2701.377d8f5a8.0

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.
@@ -1 +0,0 @@
1
- (function(E,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vue-router"),require("@kong/icons"),require("@kong-ui-public/i18n"),require("@kong-ui-public/entities-shared")):typeof define=="function"&&define.amd?define(["exports","vue","vue-router","@kong/icons","@kong-ui-public/i18n","@kong-ui-public/entities-shared"],e):(E=typeof globalThis<"u"?globalThis:E||self,e(E["kong-ui-public-entities-consumers"]={},E.Vue,E.VueRouter,E.KongIcons,E["kong-ui-public-i18n"],E["kong-ui-public-entities-shared"]))})(this,function(E,e,ae,J,ie,u){"use strict";const he={consumers:{list:{table_headers:{username:"Username",custom_id:"Custom ID",tags:"Tags",id:"ID"},empty_state:{title:"Configure a New Consumer",description:"Consumers are the end users of a service.",title_for_consumer_group:"Configure a New Consumer"},empty_state_v2:{title:"Configure your first consumer",group:"Consumers created in gateways within this group will automatically appear here.",description:"Consumers represent users or apps accessing your APIs, allowing for tailored authentication and individual access control.",learn_more:"Learn more"},toolbar_actions:{new_consumer:"New consumer"}},title:"Consumers",search:{placeholder:{konnect:"Filter by name",kongManager:"Filter by exact username or ID"}},actions:{add_consumer:"Add Consumer",create:"New Consumer",copy_id:"Copy ID",copy_json:"Copy JSON",edit:"Edit",delete:"Delete",remove:"Remove",view:"View Details"},delete:{title:"Delete a Consumer",description:"Deleting this consumer will also remove this consumer from any associated consumer group and delete all its plugins. This action cannot be reversed."},consumer_groups:{add:{title:"Add Consumers",ctaText:"Add consumers to this group",consumers_label:"Consumers",consumer_placeholder:"Add consumer",footer:"Search by exact name or ID to find consumers not included in the list"},remove:{title:"Remove a Consumer",confirmation:"Are you sure you want to remove this consumer {consumer} from consumer group {consumerGroup}?",confirmationNoCG:"Are you sure you want to remove this consumer {consumer} from this consumer group?",description:"Removing this consumer from the group could change the rate limit policy applied to this consumer."}},errors:{general:"Consumers could not be retrieved",delete:"The consumer could not be deleted at this time.",copy:"Failed to copy to clipboard",add:"Some consumers could not be added at this time.",already_added:"This consumer has already been added to the consumer group"},copy:{success:"Copied {val} to clipboard",success_brief:"Successfully copied to clipboard"},form:{title:"Consumer Identification",info:{title:"General Information",description:"General information will help identify and manage added consumer."},consumer_identification:{title:"Consumer Identification",description:"A consumer can have both unique username and unique custom ID or one of them."}},fields:{username:{label:"Username",placeholder:"Enter a unique username",tooltip:"The unique username of the Consumer. You must send either this field or {custom_id} with the request.",custom_id:"custom_id"},custom_id:{label:"Custom ID",placeholder:"Enter a unique custom ID",tooltip:"Field for storing an existing unique ID for the Consumer - useful for mapping Kong with users in your existing database. You must send either this field or {username} with the request.",username:"username"},tags:{label:"Tags",placeholder:"Enter a list of tags separated by comma",help:"e.g. tag1, tag2, tag3",tooltip:"An optional set of strings associated with the Consumer for grouping and filtering."}}}};function Ce(){const t=ie.createI18n("en-us",he);return{i18n:t,i18nT:ie.i18nTComponent(t)}}const X={useI18n:Ce},Q="/v2/control-planes/{controlPlaneId}/core-entities",z="/{workspace}",U={list:{konnect:{all:`${Q}/consumers`,forConsumerGroup:`${Q}/consumer_groups/{consumerGroupId}/consumers`,oneForConsumerGroup:`${Q}/consumer_groups/{consumerGroupId}/consumers/{consumerId}`},kongManager:{all:`${z}/consumers`,forConsumerGroup:`${z}/consumer_groups/{consumerGroupId}/consumers`,oneForConsumerGroup:`${z}/consumer_groups/{consumerGroupId}/consumers/{consumerId}`}},form:{konnect:{create:`${Q}/consumers`,edit:`${Q}/consumers/{id}`},kongManager:{create:`${z}/consumers`,edit:`${z}/consumers/{id}`}}},be={class:"add-consumer-form-container"},ke={class:"add-consumer-form-cta"},_e={class:"select-item-label"},we={key:0,class:"select-item-desc"},Ve={key:0,class:"kong-ui-entity-add-consumers-error"},Ie={key:0},Ne=e.defineComponent({__name:"AddConsumerModal",props:{config:{type:Object,required:!0,validator:t=>!(!t||!["konnect","kongManager"].includes(t==null?void 0:t.app)||!t.consumerGroupId)},visible:{type:Boolean,required:!0,default:!1}},emits:["cancel","add:success","add:partial-success","error"],setup(t,{emit:m}){var y;const{i18n:{t:s}}=X.useI18n(),o=t,k=m,{axiosInstance:r}=u.useAxios((y=o.config)==null?void 0:y.axiosRequestConfig),_=e.ref([]),{debouncedQueryChange:I,loading:B,allRecords:A,error:d,loadItems:j,results:q}=u.useDebouncedFilter(o.config,U.list[o.config.app].all,"",{fetchedItemsKey:"data",searchKeys:["username","id"]}),P=l=>l,$=e.computed(()=>d.value?s("consumers.errors.general"):""),Y=e.ref(0),K=e.computed(()=>A.value===void 0),O=e.computed(()=>q.value.map(l=>({label:l.username||l.customId,value:l.id,selected:_.value.includes(l.id),data:l}))),F=l=>{var h;const C=K.value?q.value.find(w=>w.id===l):(h=A.value)==null?void 0:h.find(w=>w.id===l);return C?C.username||C.custom_id:l},N=()=>{G.value="",T.value=[],f.value=[],k("cancel")},T=e.ref([]),S=e.ref(!1),G=e.ref(""),L=async()=>{if(!_.value.length){G.value="",f.value=[],k("cancel");return}S.value=!0,G.value="",T.value=[],f.value=[];try{const l=_.value.map(w=>i(w)),C=await Promise.allSettled(l);let h=!0;C.forEach(w=>{w.status!=="fulfilled"&&(h=!1)}),h?(T.value=[],f.value=[],k("add:success",_.value),_.value=[]):(T.value.length&&k("add:partial-success",T.value),_.value=[],D(C))}catch{G.value=s("consumers.errors.add"),k("error",G.value)}finally{S.value=!1}},a=e.computed(()=>{var C,h,w,H;let l=`${o.config.apiBaseUrl}${U.list[o.config.app].forConsumerGroup}`;return o.config.app==="konnect"?l=l.replace(/{controlPlaneId}/gi,((C=o.config)==null?void 0:C.controlPlaneId)||"").replace(/{consumerGroupId}/gi,((h=o.config)==null?void 0:h.consumerGroupId)||""):o.config.app==="kongManager"&&(l=l.replace(/\/{workspace}/gi,(w=o.config)!=null&&w.workspace?`/${o.config.workspace}`:"").replace(/{consumerGroupId}/gi,((H=o.config)==null?void 0:H.consumerGroupId)||"")),l}),i=async l=>{const C={consumer:l};try{const h=await r.post(a.value,C);return T.value.push(l),h}catch(h){let w=`${F(l)} - ${h.message}`;return h.response.status===409&&(w=`${F(l)} - ${s("consumers.errors.already_added")}`),Promise.reject(Error(w))}},f=e.ref([]),D=l=>{f.value=l.map(C=>{var h;return(h=C.reason)==null?void 0:h.message}).filter(Boolean)};return e.watch(O,()=>{Y.value++},{immediate:!0,deep:!0}),e.watch(()=>o.visible,()=>{o.visible&&j()},{immediate:!0}),(l,C)=>{const h=e.resolveComponent("KMultiselect"),w=e.resolveComponent("KAlert"),H=e.resolveComponent("KPrompt");return e.openBlock(),e.createBlock(H,{"action-button-disabled":S.value,class:"kong-ui-entities-add-consumers-modal","data-testid":"add-consumer-modal",title:e.unref(s)("consumers.consumer_groups.add.title"),visible:t.visible,onCancel:N,onProceed:L},{default:e.withCtx(()=>[e.createElementVNode("div",be,[e.createElementVNode("p",ke,e.toDisplayString(e.unref(s)("consumers.consumer_groups.add.ctaText")),1),e.createVNode(h,{modelValue:_.value,"onUpdate:modelValue":C[0]||(C[0]=V=>_.value=V),autosuggest:"","data-testid":"add-consumers-multiselect","dropdown-footer-text":K.value?e.unref(s)("consumers.consumer_groups.add.footer"):void 0,items:O.value,label:e.unref(s)("consumers.consumer_groups.add.consumers_label"),loading:e.unref(B),placeholder:e.unref(s)("consumers.consumer_groups.add.consumer_placeholder"),readonly:S.value,required:"",width:"100%",onQueryChange:e.unref(I)},{"item-template":e.withCtx(({item:V})=>[e.createElementVNode("div",_e,e.toDisplayString(V.label),1),P(V).data.username&&P(V).data.custom_id?(e.openBlock(),e.createElementBlock("div",we,e.toDisplayString(P(V).data.custom_id),1)):e.createCommentVNode("",!0)]),_:1},8,["modelValue","dropdown-footer-text","items","label","loading","placeholder","readonly","onQueryChange"]),G.value||$.value||f.value.length?(e.openBlock(),e.createElementBlock("div",Ve,[e.createVNode(w,{appearance:"danger"},{default:e.withCtx(()=>[e.createElementVNode("p",null,e.toDisplayString(e.unref(s)("consumers.errors.add")),1),f.value.length?(e.openBlock(),e.createElementBlock("ul",Ie,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(V,W)=>(e.openBlock(),e.createElementBlock("li",{key:W},e.toDisplayString(V),1))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",null,e.toDisplayString(G.value||$.value),1)]),_:1})])):e.createCommentVNode("",!0)])]),_:1},8,["action-button-disabled","title","visible"])}}}),ee=(t,m)=>{const s=t.__vccOpts||t;for(const[o,k]of m)s[o]=k;return s},xe=ee(Ne,[["__scopeId","data-v-d54468ab"]]),Ee={class:"kong-ui-entities-consumers-list"},De={class:"button-row"},Be={class:"empty-state-wrapper"},$e=ee(e.defineComponent({__name:"ConsumerList",props:{config:{type:Object,required:!0,validator:t=>!(!t||!["konnect","kongManager"].includes(t==null?void 0:t.app)||!t.createRoute||!t.getViewRoute||!t.getEditRoute||t.app==="kongManager"&&!t.isExactMatch&&!t.filterSchema)},cacheIdentifier:{type:String,default:""},canCreate:{type:Function,required:!1,default:async()=>!0},canDelete:{type:Function,required:!1,default:async()=>!0},canEdit:{type:Function,required:!1,default:async()=>!0},canRetrieve:{type:Function,required:!1,default:async()=>!0},useActionOutside:{type:Boolean,default:!1}},emits:["error","click:learn-more","copy:success","copy:error","delete:success","add:success","remove:success"],setup(t,{emit:m}){var ge;const s=m,o=t,{i18nT:k,i18n:{t:r}}=X.useI18n(),_=ae.useRouter(),{axiosInstance:I}=u.useAxios((ge=o.config)==null?void 0:ge.axiosRequestConfig),B=e.computed(()=>o.config.app!=="kongManager"||!!o.config.disableSorting),A={username:{label:r("consumers.list.table_headers.username"),searchable:!0,sortable:!0,hidable:!1},custom_id:{label:r("consumers.list.table_headers.custom_id"),searchable:!0,sortable:!0},tags:{label:r("consumers.list.table_headers.tags"),sortable:!1}},d=A,j=n=>({"data-testid":n.username??n.custom_id??n.id}),q=()=>{o.config.consumerGroupId?de():_.push(o.config.createRoute)},P=e.computed(()=>{var c,g,x,M;let n=`${o.config.apiBaseUrl}${U.list[o.config.app][N.value?"forConsumerGroup":"all"]}`;return o.config.app==="konnect"?n=n.replace(/{controlPlaneId}/gi,((c=o.config)==null?void 0:c.controlPlaneId)||"").replace(/{consumerGroupId}/gi,((g=o.config)==null?void 0:g.consumerGroupId)||""):o.config.app==="kongManager"&&(n=n.replace(/\/{workspace}/gi,(x=o.config)!=null&&x.workspace?`/${o.config.workspace}`:"").replace(/{consumerGroupId}/gi,((M=o.config)==null?void 0:M.consumerGroupId)||"")),n}),$=e.ref(""),Y=e.computed(()=>{const n=o.config.app==="konnect"||o.config.isExactMatch;return n?{isExactMatch:n,placeholder:r(`consumers.search.placeholder.${o.config.app}`)}:{isExactMatch:n,fields:{username:A.username,custom_id:A.custom_id},schema:o.config.filterSchema}}),{hasRecords:K,handleStateChange:O}=u.useTableState($),F=e.computed(()=>K.value&&o.config.app==="konnect"),N=e.computed(()=>!!o.config.consumerGroupId),T=e.computed(()=>N.value?"kong-ui-entities-consumers-list-in-group-page":"kong-ui-entities-consumers-list"),S=e.computed(()=>N.value&&!o.config.paginatedEndpoint?"consumers":void 0),{fetcher:G,fetcherState:L,fetcherCacheKey:a}=u.useFetcher(e.computed(()=>({...o.config,cacheIdentifier:o.cacheIdentifier})),P,S),i=()=>{$.value=""},f=()=>{a.value++},D=n=>n??"-",y=e.ref(null),l=async(n,c)=>{const g=n.id;if(!await c(g)){s("copy:error",{entity:n,field:"id",message:r("consumers.errors.copy")});return}s("copy:success",{entity:n,field:"id",message:r("consumers.copy.success",{val:g})})},C=(n,c)=>{const g=JSON.stringify(n);if(!c(g)){s("copy:error",{entity:n,message:r("consumers.errors.copy")});return}s("copy:success",{entity:n,message:r("consumers.copy.success_brief")})},h=async n=>{var g;await((g=o.canRetrieve)==null?void 0:g.call(o,n))&&_.push(o.config.getViewRoute(n.id))},w=n=>({label:r("consumers.actions.view"),to:o.config.getViewRoute(n)}),H=n=>({label:r("consumers.actions.edit"),to:o.config.getEditRoute(n)}),V=e.ref(void 0),W=e.ref(!1),Z=e.ref(!1),ce=e.ref(""),Oe=u.useDeleteUrlBuilder(o.config,P.value),je=n=>{V.value=n,W.value=!0},Le=()=>{W.value=!1},He=async()=>{var n,c,g;if((n=V.value)!=null&&n.id){Z.value=!0;try{await I.delete(Oe(V.value.id)),Z.value=!1,W.value=!1,a.value++,s("delete:success",V.value)}catch(x){ce.value=((g=(c=x.response)==null?void 0:c.data)==null?void 0:g.message)||x.message||r("consumers.errors.delete"),s("error",x)}finally{Z.value=!1}}},oe=e.ref(!1),de=()=>{oe.value=!0},ue=()=>{oe.value=!1},me=(n,c)=>{c||ue(),a.value++,s("add:success",n)},We=()=>{N.value&&de()},R=e.ref(void 0),ne=e.ref(!1),Je=e.ref(""),Qe=n=>{R.value=n,ne.value=!0},pe=()=>{ne.value=!1,R.value=void 0},ze=e.computed(()=>{var c,g,x,M;let n=`${o.config.apiBaseUrl}${U.list[o.config.app].oneForConsumerGroup}`;return o.config.app==="konnect"?n=n.replace(/{controlPlaneId}/gi,((c=o.config)==null?void 0:c.controlPlaneId)||"").replace(/{consumerGroupId}/gi,((g=o.config)==null?void 0:g.consumerGroupId)||""):o.config.app==="kongManager"&&(n=n.replace(/\/{workspace}/gi,(x=o.config)!=null&&x.workspace?`/${o.config.workspace}`:"").replace(/{consumerGroupId}/gi,((M=o.config)==null?void 0:M.consumerGroupId)||"")),n}),fe=e.ref(!1),Ye=async()=>{if(R.value){fe.value=!0;try{const n=ze.value.replace(/{consumerId}/gi,R.value.id);await I.delete(n),s("remove:success",R.value),pe(),a.value++}catch(n){Je.value=n.message||r("consumers.errors.delete"),s("error",n)}finally{fe.value=!1}}};e.watch(L,n=>{var c,g,x;if(n.status===u.FetcherStatus.Error){y.value={title:r("consumers.errors.general")},(x=(g=(c=n.error)==null?void 0:c.response)==null?void 0:g.data)!=null&&x.message&&(y.value.message=n.error.response.data.message),s("error",n.error);return}y.value=null});const re=e.ref({ctaPath:N.value?void 0:o.config.createRoute,ctaText:void 0,message:`${r("consumers.list.empty_state.description")}${o.config.additionMessageForEmptyState?` ${o.config.additionMessageForEmptyState}`:""}`,title:r("consumers.title")}),se=e.ref(!1);return e.onBeforeMount(async()=>{se.value=await o.canCreate(),se.value&&(re.value.title=N.value?r("consumers.list.empty_state.title_for_consumer_group"):r("consumers.list.empty_state.title"),re.value.ctaText=N.value?r("consumers.actions.add_consumer"):r("consumers.actions.create"))}),(n,c)=>{const g=e.resolveComponent("KButton"),x=e.resolveComponent("KEmptyState"),M=e.resolveComponent("KDropdownItem"),ye=e.resolveComponent("KClipboardProvider"),Xe=e.resolveComponent("KPrompt");return e.openBlock(),e.createElementBlock("div",Ee,[e.createVNode(e.unref(u.EntityBaseTable),{"cache-identifier":t.cacheIdentifier,"disable-sorting":B.value,"empty-state-options":re.value,"enable-entity-actions":"","error-message":y.value,fetcher:e.unref(G),"fetcher-cache-key":e.unref(a),"hide-pagination":N.value&&!t.config.paginatedEndpoint,"pagination-type":"offset","preferences-storage-key":T.value,query:$.value,"row-attributes":j,"table-headers":e.unref(d),onClearSearchInput:i,"onClick:row":c[3]||(c[3]=p=>h(p)),onEmptyStateCtaClicked:We,onSort:f,onState:e.unref(O)},e.createSlots({"toolbar-filter":e.withCtx(()=>[e.renderSlot(n.$slots,"toolbar-filter",{},void 0,!0),N.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(u.EntityFilter),{key:0,modelValue:$.value,"onUpdate:modelValue":c[0]||(c[0]=p=>$.value=p),config:Y.value},null,8,["modelValue","config"]))]),"toolbar-button":e.withCtx(()=>[(e.openBlock(),e.createBlock(e.Teleport,{disabled:!t.useActionOutside,to:"#kong-ui-app-page-header-action-button"},[e.createElementVNode("div",De,[!N.value&&F.value?(e.openBlock(),e.createBlock(g,{key:0,appearance:"secondary",class:"open-learning-hub","data-testid":"consumers-learn-more-button",icon:"",onClick:c[1]||(c[1]=p=>n.$emit("click:learn-more"))},{default:e.withCtx(()=>[e.createVNode(e.unref(J.BookIcon),{decorative:""})]),_:1})):e.createCommentVNode("",!0),e.createVNode(e.unref(u.PermissionsWrapper),{"auth-function":()=>t.canCreate()},{default:e.withCtx(()=>[e.createVNode(g,{appearance:"primary","data-testid":"toolbar-add-consumer",size:t.useActionOutside?"medium":"large",onClick:q},{default:e.withCtx(()=>[e.createVNode(e.unref(J.AddIcon)),e.createTextVNode(" "+e.toDisplayString(t.config.consumerGroupId?e.unref(r)("consumers.actions.add_consumer"):e.unref(r)("consumers.list.toolbar_actions.new_consumer")),1)]),_:1},8,["size"])]),_:1},8,["auth-function"])])],8,["disabled"]))]),username:e.withCtx(({rowValue:p})=>[e.createElementVNode("b",null,e.toDisplayString(D(p)),1)]),custom_id:e.withCtx(({rowValue:p})=>[e.createTextVNode(e.toDisplayString(D(p)),1)]),tags:e.withCtx(({rowValue:p})=>[e.createVNode(e.unref(u.TableTags),{tags:p},null,8,["tags"])]),actions:e.withCtx(({row:p})=>[e.createVNode(ye,null,{default:e.withCtx(({copyToClipboard:v})=>[e.createVNode(M,{"data-testid":"action-entity-copy-id",onClick:Ze=>l(p,v)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("consumers.actions.copy_id")),1)]),_:1},8,["onClick"])]),_:2},1024),e.createVNode(ye,null,{default:e.withCtx(({copyToClipboard:v})=>[e.createVNode(M,{"data-testid":"action-entity-copy-json",onClick:Ze=>C(p,v)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("consumers.actions.copy_json")),1)]),_:1},8,["onClick"])]),_:2},1024),e.createVNode(e.unref(u.PermissionsWrapper),{"auth-function":()=>t.canRetrieve(p)},{default:e.withCtx(()=>[e.createVNode(M,{"data-testid":"action-entity-view","has-divider":"",item:w(p.id)},null,8,["item"])]),_:2},1032,["auth-function"]),e.createVNode(e.unref(u.PermissionsWrapper),{"auth-function":()=>t.canEdit(p)},{default:e.withCtx(()=>[e.createVNode(M,{"data-testid":"action-entity-edit",item:H(p.id)},null,8,["item"])]),_:2},1032,["auth-function"]),e.createVNode(e.unref(u.PermissionsWrapper),{"auth-function":()=>t.canDelete(p)},{default:e.withCtx(()=>[e.createVNode(M,{danger:"","data-testid":"action-entity-delete","has-divider":"",onClick:()=>t.config.consumerGroupId?Qe(p):je(p)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.config.consumerGroupId?e.unref(r)("consumers.actions.remove"):e.unref(r)("consumers.actions.delete")),1)]),_:1},8,["onClick"])]),_:2},1032,["auth-function"])]),_:2},[!$.value&&t.config.app==="konnect"?{name:"empty-state",fn:e.withCtx(()=>{var p;return[e.createElementVNode("div",Be,[e.renderSlot(n.$slots,"empty-state-toolbar",{},void 0,!0),e.createVNode(x,{"data-testid":t.config.consumerGroupId?"nested-consumers-entity-empty-state":"consumers-entity-empty-state","icon-background":"",message:e.unref(r)("consumers.list.empty_state_v2.description"),title:e.unref(r)("consumers.list.empty_state_v2.title")},e.createSlots({icon:e.withCtx(()=>[e.createVNode(e.unref(J.TeamIcon),{decorative:""})]),action:e.withCtx(()=>[se.value?(e.openBlock(),e.createBlock(g,{key:0,"data-testid":"entity-create-button",onClick:q},{default:e.withCtx(()=>[e.createVNode(e.unref(J.AddIcon),{decorative:""}),e.createTextVNode(" "+e.toDisplayString(e.unref(r)("consumers.list.toolbar_actions.new_consumer")),1)]),_:1})):e.createCommentVNode("",!0),e.createVNode(g,{appearance:"secondary","data-testid":"entity-learn-more-button",onClick:c[2]||(c[2]=v=>n.$emit("click:learn-more"))},{default:e.withCtx(()=>[e.createVNode(e.unref(J.BookIcon),{decorative:""}),e.createTextVNode(" "+e.toDisplayString(e.unref(r)("consumers.list.empty_state_v2.learn_more")),1)]),_:1})]),_:2},[(p=t.config)!=null&&p.isControlPlaneGroup?{name:"default",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("consumers.list.empty_state_v2.group")),1)]),key:"0"}:void 0]),1032,["data-testid","message","title"])])]}),key:"0"}:void 0]),1032,["cache-identifier","disable-sorting","empty-state-options","error-message","fetcher","fetcher-cache-key","hide-pagination","preferences-storage-key","query","table-headers","onState"]),e.createVNode(e.unref(u.EntityDeleteModal),{"action-button-disabled":Z.value,"data-testid":"delete-consumer-modal",description:e.unref(r)("consumers.delete.description"),"entity-name":V.value&&(V.value.username||V.value.custom_id||V.value.id),"entity-type":e.unref(u.EntityTypes).Consumer,error:ce.value,title:e.unref(r)("consumers.delete.title"),visible:W.value,onCancel:Le,onProceed:He},null,8,["action-button-disabled","description","entity-name","entity-type","error","title","visible"]),t.config.consumerGroupId?(e.openBlock(),e.createBlock(xe,{key:0,config:t.config,"data-testid":"add-consumer-modal",visible:oe.value,"onAdd:partialSuccess":c[4]||(c[4]=p=>me(p,!0)),"onAdd:success":c[5]||(c[5]=p=>me(p)),onCancel:ue},null,8,["config","visible"])):e.createCommentVNode("",!0),t.config.consumerGroupId&&R.value?(e.openBlock(),e.createBlock(Xe,{key:1,"action-button-appearance":"danger","data-testid":"remove-consumer-modal",title:e.unref(r)("consumers.consumer_groups.remove.title"),visible:ne.value,onCancel:pe,onProceed:Ye},{default:e.withCtx(()=>[e.createVNode(e.unref(k),{class:"message",keypath:t.config.consumerGroupName?"consumers.consumer_groups.remove.confirmation":"consumers.consumer_groups.remove.confirmationNoCG",tag:"p"},e.createSlots({consumer:e.withCtx(()=>[e.createElementVNode("strong",null,e.toDisplayString(R.value.username||R.value.custom_id||R.value.id),1)]),_:2},[t.config.consumerGroupName?{name:"consumerGroup",fn:e.withCtx(()=>[e.createElementVNode("strong",null,e.toDisplayString(t.config.consumerGroupName),1)]),key:"0"}:void 0]),1032,["keypath"]),e.createElementVNode("p",null,e.toDisplayString(e.unref(r)("consumers.consumer_groups.remove.description")),1)]),_:1},8,["title","visible"])):e.createCommentVNode("",!0)])}}}),[["__scopeId","data-v-4737bfb9"]]),b=[];for(let t=0;t<256;++t)b.push((t+256).toString(16).slice(1));function Se(t,m=0){return(b[t[m+0]]+b[t[m+1]]+b[t[m+2]]+b[t[m+3]]+"-"+b[t[m+4]]+b[t[m+5]]+"-"+b[t[m+6]]+b[t[m+7]]+"-"+b[t[m+8]]+b[t[m+9]]+"-"+b[t[m+10]]+b[t[m+11]]+b[t[m+12]]+b[t[m+13]]+b[t[m+14]]+b[t[m+15]]).toLowerCase()}let te;const Ge=new Uint8Array(16);function Me(){if(!te){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");te=crypto.getRandomValues.bind(crypto)}return te(Ge)}const le={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Te(t,m,s){var k;if(le.randomUUID&&!t)return le.randomUUID();t=t||{};const o=t.random??((k=t.rng)==null?void 0:k.call(t))??Me();if(o.length<16)throw new Error("Random bytes length must be >= 16");return o[6]=o[6]&15|64,o[8]=o[8]&63|128,Se(o)}const Ae={class:"kong-ui-entities-consumer-form"},Re=["id"],Pe={class:"fields-group-text"},Fe=["aria-labelledby"],Ue=ee(e.defineComponent({__name:"ConsumerForm",props:{config:{type:Object,required:!0,validator:t=>!(!t||!["konnect","kongManager"].includes(t==null?void 0:t.app)||(t==null?void 0:t.app)==="konnect"&&!(t!=null&&t.controlPlaneId)||(t==null?void 0:t.app)==="kongManager"&&typeof(t==null?void 0:t.workspace)!="string"||!(t!=null&&t.cancelRoute))},consumerId:{type:String,required:!1,default:""}},emits:["update","error","loading"],setup(t,{emit:m}){var L;const s=t,o=m,{i18nT:k,i18n:{t:r}}=X.useI18n(),_=ae.useRouter(),{axiosInstance:I}=u.useAxios((L=s.config)==null?void 0:L.axiosRequestConfig),{getMessageFromError:B}=u.useErrors(),A=Te(),d=e.reactive({fields:{username:"",customId:"",tags:""},readonly:!1,errorMessage:""}),j=e.reactive({username:"",customId:"",tags:""}),q=e.computed(()=>{var a,i;return(i=U.form[(a=s.config)==null?void 0:a.app])==null?void 0:i.edit}),P=()=>{var a;_.push(((a=s.config)==null?void 0:a.cancelRoute)||{name:"consumer-list"})},$=a=>{o("loading",a)},Y=a=>{o("error",a)},K=a=>{var f,D,y;d.fields.username=((f=a==null?void 0:a.item)==null?void 0:f.username)||(a==null?void 0:a.username)||"",d.fields.customId=((D=a==null?void 0:a.item)==null?void 0:D.custom_id)||(a==null?void 0:a.custom_id)||"";const i=((y=a==null?void 0:a.item)==null?void 0:y.tags)||(a==null?void 0:a.tags)||[];d.fields.tags=(i==null?void 0:i.join(", "))||"",Object.assign(j,d.fields)},O=e.computed(()=>s.consumerId?u.EntityBaseFormType.Edit:u.EntityBaseFormType.Create),F=a=>{var f,D,y,l,C,h;let i=`${(f=s.config)==null?void 0:f.apiBaseUrl}${U.form[(D=s.config)==null?void 0:D.app][a]}`;return((y=s.config)==null?void 0:y.app)==="konnect"?i=i.replace(/{controlPlaneId}/gi,((l=s.config)==null?void 0:l.controlPlaneId)||""):((C=s.config)==null?void 0:C.app)==="kongManager"&&(i=i.replace(/\/{workspace}/gi,(h=s.config)!=null&&h.workspace?`/${s.config.workspace}`:"")),i=i.replace(/{id}/gi,s.consumerId),i},N=e.computed(()=>!!d.fields.username||!!d.fields.customId),T=e.computed(()=>JSON.stringify(d.fields)!==JSON.stringify(j)),S=e.computed(()=>{var a,i;return{username:d.fields.username||null,custom_id:d.fields.customId||null,tags:(i=(a=d.fields.tags.split(","))==null?void 0:a.map(f=>String(f||"").trim()))==null?void 0:i.filter(f=>f!=="")}}),G=async()=>{var a;try{d.readonly=!0;let i;O.value==="create"?i=await I.post(F("create"),S.value):O.value==="edit"&&(i=((a=s.config)==null?void 0:a.app)==="konnect"?await I.put(F("edit"),S.value):await I.patch(F("edit"),S.value)),K(i==null?void 0:i.data),o("update",i==null?void 0:i.data)}catch(i){d.errorMessage=B(i),o("error",i)}finally{d.readonly=!1}};return(a,i)=>{const f=e.resolveComponent("KInput"),D=e.resolveComponent("KCard");return e.openBlock(),e.createElementBlock("div",Ae,[e.createVNode(e.unref(u.EntityBaseForm),{"can-submit":N.value&&T.value,config:t.config,"edit-id":t.consumerId,"entity-type":e.unref(u.SupportedEntityType).Consumer,"error-message":d.errorMessage,"fetch-url":q.value,"form-fields":S.value,"is-readonly":d.readonly,onCancel:P,"onFetch:error":i[3]||(i[3]=y=>Y(y)),"onFetch:success":K,onLoading:i[4]||(i[4]=y=>$(y)),onSubmit:G},{default:e.withCtx(()=>[e.createElementVNode("div",null,[e.createVNode(e.unref(u.EntityFormSection),{description:e.unref(r)("consumers.form.info.description"),"has-divider":"",title:e.unref(r)("consumers.form.info.title")},{default:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("h3",{id:`fields-group-title-${e.unref(A)}`,class:"fields-group-title"},e.toDisplayString(e.unref(r)("consumers.form.consumer_identification.title"))+"* ",9,Re),e.createElementVNode("p",Pe,e.toDisplayString(e.unref(r)("consumers.form.consumer_identification.description")),1)]),e.createVNode(D,null,{default:e.withCtx(()=>[e.createElementVNode("fieldset",{"aria-labelledby":`fields-group-title-${e.unref(A)}`},[e.createVNode(f,{modelValue:d.fields.username,"onUpdate:modelValue":i[0]||(i[0]=y=>d.fields.username=y),modelModifiers:{trim:!0},autocomplete:"off",class:"username-field","data-testid":"consumer-form-username",label:e.unref(r)("consumers.fields.username.label"),"label-attributes":{tooltipAttributes:{maxWidth:"400"}},placeholder:e.unref(r)("consumers.fields.username.placeholder"),readonly:d.readonly,type:"text"},{"label-tooltip":e.withCtx(()=>[e.createVNode(e.unref(k),{keypath:"consumers.fields.username.tooltip",scope:"global"},{custom_id:e.withCtx(()=>[e.createElementVNode("code",null,e.toDisplayString(e.unref(r)("consumers.fields.username.custom_id")),1)]),_:1})]),_:1},8,["modelValue","label","placeholder","readonly"]),e.createVNode(f,{modelValue:d.fields.customId,"onUpdate:modelValue":i[1]||(i[1]=y=>d.fields.customId=y),modelModifiers:{trim:!0},autocomplete:"off","data-testid":"consumer-form-custom-id",label:e.unref(r)("consumers.fields.custom_id.label"),"label-attributes":{tooltipAttributes:{maxWidth:"400"}},placeholder:e.unref(r)("consumers.fields.custom_id.placeholder"),readonly:d.readonly,type:"text"},{"label-tooltip":e.withCtx(()=>[e.createVNode(e.unref(k),{keypath:"consumers.fields.custom_id.tooltip",scope:"global"},{username:e.withCtx(()=>[e.createElementVNode("code",null,e.toDisplayString(e.unref(r)("consumers.fields.custom_id.username")),1)]),_:1})]),_:1},8,["modelValue","label","placeholder","readonly"])],8,Fe)]),_:1}),e.createVNode(f,{modelValue:d.fields.tags,"onUpdate:modelValue":i[2]||(i[2]=y=>d.fields.tags=y),modelModifiers:{trim:!0},autocomplete:"off","data-testid":"consumer-form-tags",help:e.unref(r)("consumers.fields.tags.help"),label:e.unref(r)("consumers.fields.tags.label"),"label-attributes":{info:e.unref(r)("consumers.fields.tags.tooltip"),tooltipAttributes:{maxWidth:"400"}},placeholder:e.unref(r)("consumers.fields.tags.placeholder"),readonly:d.readonly,type:"text"},null,8,["modelValue","help","label","label-attributes","placeholder","readonly"])]),_:1},8,["description","title"])])]),_:1},8,["can-submit","config","edit-id","entity-type","error-message","fetch-url","form-fields","is-readonly"])])}}}),[["__scopeId","data-v-ecefc72c"]]),qe={class:"kong-ui-consumer-entity-config-card"},Ke=e.defineComponent({__name:"ConsumerConfigCard",props:{config:{type:Object,required:!0,validator:t=>!(!t||!["konnect","kongManager"].includes(t==null?void 0:t.app)||t.app==="konnect"&&!t.controlPlaneId||t.app==="kongManager"&&typeof t.workspace!="string"||!t.entityId)},configCardDoc:{type:String,default:"",required:!1},hideTitle:{type:Boolean,default:!1}},emits:["loading","fetch:error","fetch:success"],setup(t){const m=t,{i18n:{t:s},i18nT:o}=X.useI18n(),k=e.computed(()=>U.form[m.config.app].edit),r=e.ref({id:{},username:{section:u.ConfigurationSchemaSection.Basic,tooltip:s("consumers.fields.username.tooltip"),order:1},custom_id:{section:u.ConfigurationSchemaSection.Basic,tooltip:s("consumers.fields.custom_id.tooltip"),label:s("consumers.fields.custom_id.label"),order:2},updated_at:{},created_at:{},tags:{tooltip:s("consumers.fields.tags.tooltip")},username_lower:{hidden:!0},type:{hidden:!0}});return(_,I)=>(e.openBlock(),e.createElementBlock("div",qe,[e.createVNode(e.unref(u.EntityBaseConfigCard),{config:t.config,"config-card-doc":t.configCardDoc,"config-schema":r.value,"entity-type":e.unref(u.SupportedEntityType).Consumer,"fetch-url":k.value,"hide-title":t.hideTitle,"onFetch:error":I[0]||(I[0]=B=>_.$emit("fetch:error",B)),"onFetch:success":I[1]||(I[1]=B=>_.$emit("fetch:success",B)),onLoading:I[2]||(I[2]=B=>_.$emit("loading",B))},{"username-label-tooltip":e.withCtx(()=>[e.createVNode(e.unref(o),{keypath:"consumers.fields.username.tooltip",scope:"global"},{custom_id:e.withCtx(()=>[e.createElementVNode("code",null,e.toDisplayString(e.unref(s)("consumers.fields.username.custom_id")),1)]),_:1})]),"custom_id-label-tooltip":e.withCtx(()=>[e.createVNode(e.unref(o),{keypath:"consumers.fields.custom_id.tooltip",scope:"global"},{username:e.withCtx(()=>[e.createElementVNode("code",null,e.toDisplayString(e.unref(s)("consumers.fields.custom_id.username")),1)]),_:1})]),_:1},8,["config","config-card-doc","config-schema","entity-type","fetch-url","hide-title"])]))}});E.ConsumerConfigCard=Ke,E.ConsumerForm=Ue,E.ConsumerList=$e,Object.defineProperty(E,Symbol.toStringTag,{value:"Module"})});
package/dist/style.css DELETED
@@ -1 +0,0 @@
1
- .config-card-fieldset[data-v-dc1e39a1]{border:solid 1px #e0e4ea;border-radius:4px;margin-bottom:8px;margin-top:4px}.config-card-fieldset-title[data-v-dc1e39a1]{font-size:14px;padding:0 8px;width:auto}fieldset.config-card-fieldset .config-card-details-row{width:unset}.config-card-json-item .config-card-details-row,fieldset.config-card-fieldset .config-card-details-row{margin:0 16px}.config-card-json-item .config-card-details-row:last-of-type,fieldset.config-card-fieldset .config-card-details-row:last-of-type{border-bottom:none}[data-v-2feb8c2e] .k-button.navigation-button{font-size:14px;font-weight:400}.config-card-details-row[data-v-66d61bea]{align-items:center;border-bottom:var(--v70f369b3);box-sizing:border-box;display:var(--v67c2fae6);padding:16px 16px 16px 0;width:100%}.config-card-details-row .config-card-details-label[data-v-66d61bea]{box-sizing:border-box;padding-right:16px;width:var(--v847b138c)}.config-card-details-row .config-card-details-label label[data-v-66d61bea]{color:#3a3f51;display:inline-flex;max-width:100%}.config-card-details-row .config-card-details-label label .label-content[data-v-66d61bea]{line-height:initial;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.config-card-details-row .config-card-details-label label .k-popover[data-v-66d61bea]{min-width:0}.config-card-details-row .config-card-details-value[data-v-66d61bea]{box-sizing:border-box;width:var(--v847687d6)}.config-card-details-row .config-card-details-value .truncated[data-v-66d61bea]{display:inline-block;line-height:initial;max-width:20ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.config-card-details-row .config-card-details-value span.attrs-data-text[data-v-66d61bea]{overflow-wrap:anywhere}.config-card-details-row .config-card-details-value .copy-uuid-array[data-v-66d61bea] .k-copy:not(:last-of-type){margin-bottom:8px}.config-card-details-row .config-card-details-value .method-badge-array[data-v-66d61bea]{display:flex;flex-wrap:wrap;row-gap:10px}.config-card-details-row .config-badge[data-v-66d61bea]{margin-right:4px}.config-card-details-row[data-v-66d61bea] .k-label{margin-bottom:0}.config-card-details-row[data-v-66d61bea] .k-label .kong-icon-infoFilled{display:flex}.config-card-details-row[data-v-66d61bea] .config-card-details-row{width:auto}.json-content.k-code-block{border-top-left-radius:0;border-top-right-radius:0}.json-endpoint{align-items:baseline;background-color:#000933;border-bottom:1px solid rgba(255,255,255,.2);border-top-left-radius:8px;border-top-right-radius:8px;display:flex;padding:8px 0 8px 12px}.json-endpoint .k-code-block{flex:auto;z-index:2}.json-endpoint .k-code-block .code-block-content{padding-bottom:0;padding-top:0}.json-endpoint .k-code-block .code-block-secondary-actions{margin-top:0!important}.json-endpoint code{direction:rtl;max-width:var(--eca0976a);overflow:hidden!important;text-align:left;text-overflow:ellipsis;white-space:nowrap}.config-card-prop-section-title[data-v-a7689049]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card .config-card-actions[data-v-f2b42324]{align-items:center;display:flex}.kong-ui-entity-base-config-card .config-card-actions .config-format-select-label[data-v-f2b42324]{margin-bottom:0;margin-right:8px}.kong-ui-entity-base-config-card .config-card-prop-section-title[data-v-f2b42324]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card[data-v-f2b42324] .config-card-details-row:last-of-type{border-bottom:none}.kong-ui-entity-base-config-card .book-icon[data-v-f2b42324]{margin-left:8px;padding:0}.kong-ui-entity-base-form[data-v-10f3d6b0]{box-sizing:border-box;max-width:1536px;width:100%}.kong-ui-entity-base-form[data-v-10f3d6b0] .k-slideout-title{color:#000933!important;font-size:24px!important;font-weight:700!important;line-height:32px!important;margin-bottom:16px!important}.kong-ui-entity-base-form[data-v-10f3d6b0] .k-card.content-card{padding:0 16px!important}.kong-ui-entity-base-form[data-v-10f3d6b0] .tab-item>div.tab-link.has-panels{color:#6c7489!important;font-size:14px!important;font-weight:700!important;line-height:24px!important}.kong-ui-entity-base-form[data-v-10f3d6b0] .tab-item.active>div.tab-link.has-panels{color:#000933!important;font-weight:600!important}.form-actions[data-v-10f3d6b0]{align-items:center;display:flex;justify-content:flex-end;margin-top:24px}.form-actions[data-v-10f3d6b0] .k-button:last-of-type,.form-actions[data-v-10f3d6b0] .k-button:nth-last-of-type(2){margin-inline-start:16px}.form-actions-reverted[data-v-10f3d6b0]{direction:rtl}.content-wrapper[data-v-a3a65cac] .k-tooltip{word-break:break-all}.kong-ui-entity-base-table .toolbar-container[data-v-44153100]{align-items:center;display:flex;width:100%}.kong-ui-entity-base-table .toolbar-button-container[data-v-44153100]{margin-left:auto}.kong-ui-entity-base-table .hidden[data-v-44153100]{display:none}.kong-ui-entity-base-table :deep(.k-table){table-layout:fixed}.kong-ui-entity-delete-modal .message[data-v-4361d622],.kong-ui-entity-delete-modal .description[data-v-4361d622]{line-height:24px;margin:0}.kong-ui-entity-delete-modal .message strong[data-v-4361d622]{font-weight:600}.kong-ui-entity-delete-modal .description[data-v-4361d622]{margin-top:32px}.kong-ui-entity-delete-error[data-v-4361d622]{margin-bottom:16px}.kong-ui-entity-filter-input[data-v-084f7978]{width:100%}.kong-ui-entity-filter-clear[data-v-084f7978]{cursor:pointer}.kong-ui-entity-filter[data-v-084f7978]{display:flex;position:relative}.kong-ui-entity-filter[data-v-084f7978] .menu-content{flex-direction:column}.kong-ui-entity-filter[data-v-084f7978] .k-menu-item-divider hr{margin:12px 0}.kong-ui-entity-filter-backdrop[data-v-084f7978]{bottom:0;left:0;position:fixed;right:0;top:0;z-index:1050}.kong-ui-entity-filter-menu[data-v-084f7978]{background-color:#fff;border:1px solid #afb7c5;border-radius:4px;box-shadow:0 4px 20px #e0e4ea;left:0;margin-top:16px;padding:8px 0 12px;position:absolute;top:100%;width:300px;z-index:1060}.kong-ui-entity-filter-menu-item[data-v-084f7978]{border-bottom:1px solid #e0e4ea;color:#6c7489;font-size:12px;font-weight:400;line-height:16px;list-style:none;margin:0 20px;padding:16px 0;position:relative;white-space:nowrap}.menu-item-title[data-v-084f7978]{align-items:center;cursor:pointer;display:flex;line-height:24px}.menu-item-title.expanded[data-v-084f7978]{color:#232633}.menu-item-expand-icon[data-v-084f7978]{margin-left:auto}.menu-item-expand-icon.expanded[data-v-084f7978]{transform:rotate(180deg)}.menu-item-indicator[data-v-084f7978]{background-color:#0044f4;border-radius:50%;height:4px;margin-left:4px;width:4px}.menu-item-body[data-v-084f7978]{align-items:center;display:flex;justify-content:space-between;margin-top:16px}.menu-item-body[data-v-084f7978] .input{padding-bottom:4px!important;padding-top:4px!important}.menu-item-body[data-v-084f7978] .k-input{width:100%}.menu-item-body[data-v-084f7978] .k-select-input .input{font-size:12px}.menu-item-body[data-v-084f7978] .k-select-input .input::placeholder{color:#00000073!important;font-size:12px}.menu-item-label[data-v-084f7978]{margin-bottom:0;margin-right:12px}.menu-item-buttons[data-v-084f7978]{display:flex;justify-content:space-between;margin:10px 0 6px}.filter-clear-button-container[data-v-084f7978]{padding:12px 20px 0}fieldset[data-v-b1f74200]{margin:0;min-width:0;padding:0}.kong-ui-entity-form-section[data-v-b1f74200]{border:0}.kong-ui-entity-form-section .form-section-wrapper[data-v-b1f74200]{column-gap:16px;display:flex;flex-direction:column;padding-bottom:64px;row-gap:12px;width:100%}@media (min-width: 1024px){.kong-ui-entity-form-section .form-section-wrapper[data-v-b1f74200]{flex-direction:row}}.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-b1f74200]{flex:1}@media (min-width: 1024px){.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-b1f74200]{max-width:350px}.kong-ui-entity-form-section .form-section-wrapper .form-section-info.sticky[data-v-b1f74200]{height:fit-content;margin-bottom:16px;position:sticky;top:16px}}.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-title[data-v-b1f74200]{color:#000933;font-size:16px;font-weight:700;line-height:20px;margin-bottom:8px;margin-top:0}.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-b1f74200],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description p[data-v-b1f74200],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-b1f74200] p{color:#000933;font-size:14px;font-weight:400;line-height:20px;margin:0}.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-footer[data-v-b1f74200]{margin-top:32px}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-b1f74200]{flex:1}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-b1f74200]>*:not(:first-child){margin-top:24px}.kong-ui-entity-form-section.has-divider .form-section-wrapper[data-v-b1f74200]{border-bottom:1px solid #e0e4ea}.ff-form-section .header[data-v-cb6d2e95]{align-items:flex-start;display:flex;gap:8px}.ff-form-section .step[data-v-cb6d2e95]{align-items:center;background:#fff;border:1px solid #afb7c5;border-radius:100px;display:flex;flex:0 0 auto;height:32px;justify-content:center;padding:4px;width:32px}.ff-form-section .header-content[data-v-cb6d2e95]{align-items:flex-start;display:flex;flex:1 1 auto;flex-direction:column;gap:8px;padding-top:4px}.ff-form-section .header-title[data-v-cb6d2e95]{color:#000933;font-size:18px;font-weight:700;line-height:24px;margin:0}.ff-form-section .header-description[data-v-cb6d2e95]{color:#52596e;font-size:14px;line-height:20px;margin:0}.ff-form-section .header-extra[data-v-cb6d2e95]{align-items:center;display:flex;flex:0 0 auto;gap:8px;justify-content:flex-end}.ff-form-section .content[data-v-cb6d2e95]{background:#f9fafb;border:1px solid #e0e4ea;border-radius:6px;display:flex;flex-direction:column;gap:20px;margin-left:16px;margin-top:20px;padding:20px 24px}.kong-ui-public-entity-link[data-v-96efdfa5]{align-items:center;display:flex}.kong-ui-public-entity-link .deleted-entity[data-v-96efdfa5]{font-style:italic}.kong-ui-public-entity-link .entity-link[data-v-96efdfa5]{display:flex;flex:1}.kong-ui-public-entity-link .entity-link[data-v-96efdfa5] .external-link-icon{color:#0044f4;margin-left:4px;padding:2px}.kong-ui-public-entity-link .entity-link-label[data-v-96efdfa5]{display:inline-block;font-weight:400;max-width:90%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kong-ui-public-entity-link .copy-uuid-tooltip[data-v-96efdfa5]{align-items:center;cursor:pointer;display:flex}.kong-ui-public-entity-link .copy-uuid-tooltip .entity-link-copy-id[data-v-96efdfa5]{margin-left:2px}.kong-ui-public-entity-empty-state[data-v-645aae54]{align-items:center;background-color:#fff;box-sizing:border-box;display:flex;flex-direction:column;font-family:Inter,Roboto,Helvetica,sans-serif;gap:24px;padding:64px 0;width:100%}@media (min-width: 640px){.kong-ui-public-entity-empty-state[data-v-645aae54]{padding:64px 96px}}.kong-ui-public-entity-empty-state .empty-state-image[data-v-645aae54]{margin-bottom:8px}.kong-ui-public-entity-empty-state .entity-empty-state-content[data-v-645aae54]{align-items:center;display:flex;flex-direction:column;gap:8px;text-align:center;width:100%}.kong-ui-public-entity-empty-state .entity-empty-state-content .entity-empty-state-title h1[data-v-645aae54]{align-items:center;color:#000933;display:flex;font-size:24px;font-weight:700;gap:8px;line-height:32px;margin:0}.kong-ui-public-entity-empty-state .entity-empty-state-content .entity-empty-state-title h1.secondary[data-v-645aae54]{font-size:18px}.kong-ui-public-entity-empty-state .entity-empty-state-description[data-v-645aae54],.kong-ui-public-entity-empty-state .entity-empty-state-pricing[data-v-645aae54]{color:#52596e;font-size:14px;font-weight:400;line-height:20px;max-width:640px}.kong-ui-public-entity-empty-state .entity-empty-state-description p[data-v-645aae54],.kong-ui-public-entity-empty-state .entity-empty-state-pricing p[data-v-645aae54]{margin:0}.kong-ui-public-entity-empty-state .entity-empty-state-pricing[data-v-645aae54]{margin-top:16px}.kong-ui-public-entity-empty-state .entity-empty-state-message[data-v-645aae54]{color:#52596e}.kong-ui-public-entity-empty-state .entity-empty-state-action[data-v-645aae54]{align-items:center;display:flex;gap:12px}.kong-ui-public-entity-empty-state .entity-empty-state-card-container[data-v-645aae54]{display:flex;flex-wrap:wrap;gap:16px;justify-content:space-around;margin-top:8px;width:312px}@media (min-width: 640px){.kong-ui-public-entity-empty-state .entity-empty-state-card-container[data-v-645aae54]{width:640px}}.kong-ui-public-entity-empty-state .entity-empty-state-card-container .entity-empty-state-card[data-v-645aae54]{background-color:#f9fafb;border:1px solid #e0e4ea;border-radius:6px;color:#afb7c5;gap:8px;height:160px;padding:20px;width:312px}.kong-ui-public-entity-empty-state .entity-empty-state-card-container .entity-empty-state-card .feature-icon[data-v-645aae54]{color:#3a3f51;display:flex;margin-bottom:12px}.kong-ui-public-entity-empty-state .entity-empty-state-card-container .entity-empty-state-card .feature-icon[data-v-645aae54] .kui-icon{height:20px!important;width:20px!important}.kong-ui-public-entity-empty-state .entity-empty-state-card-container .entity-empty-state-card[data-v-645aae54] .card-title{font-size:14px;font-weight:600}.kong-ui-public-entity-empty-state .entity-empty-state-card-container .entity-empty-state-card[data-v-645aae54] .card-content{-webkit-box-orient:vertical;color:#6c7489;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;overflow:hidden}.kong-ui-public-entity-empty-state .entity-empty-state-bottom-container[data-v-645aae54]{border-top:1px solid #e0e4ea;display:flex;flex-direction:column;gap:16px;padding-top:48px;width:100%}@media (min-width: 640px){.kong-ui-public-entity-empty-state .entity-empty-state-bottom-container[data-v-645aae54]{width:640px}}.kong-ui-entities-add-consumers-modal .add-consumer-form-cta[data-v-d54468ab]{margin-top:0}.kong-ui-entities-add-consumers-modal .add-consumer-form-container[data-v-d54468ab]{margin-bottom:20px}.kong-ui-entities-add-consumers-modal .add-consumer-form-container .kong-ui-entity-add-consumers-error[data-v-d54468ab]{margin-top:16px}.button-row[data-v-4737bfb9]{align-items:center;display:flex;gap:12px}.kong-ui-entities-consumers-list[data-v-4737bfb9]{width:100%}.kong-ui-entities-consumers-list .empty-state-wrapper[data-v-4737bfb9]{display:flex;flex-direction:column;gap:4px;padding:4px 4px 0}.kong-ui-entities-consumers-list .message[data-v-4737bfb9]{margin-top:0}.kong-ui-entities-consumers-list .kong-ui-entity-filter-input[data-v-4737bfb9]{margin-right:12px}.kong-ui-entities-consumer-form[data-v-ecefc72c]{width:100%}@media screen and (min-width: 1280px){.kong-ui-entities-consumer-form[data-v-ecefc72c] .form-section-wrapper{column-gap:64px}}.kong-ui-entities-consumer-form fieldset[data-v-ecefc72c]{border:none;margin:0;padding:0}.fields-group-title[data-v-ecefc72c]{color:#232633;font-size:16px;font-weight:600;line-height:20px;margin-bottom:4px;margin-top:0}.fields-group-text[data-v-ecefc72c]{color:#00000073;font-size:14px;line-height:20px;margin-bottom:0;margin-top:0}.username-field[data-v-ecefc72c]{margin-bottom:16px}
@@ -1,39 +0,0 @@
1
- import type { PropType } from 'vue';
2
- import type { KongManagerConsumerListConfig, KonnectConsumerListConfig } from '../types';
3
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
4
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
5
- config: {
6
- type: PropType<KonnectConsumerListConfig | KongManagerConsumerListConfig>;
7
- required: true;
8
- validator: (config: KonnectConsumerListConfig | KongManagerConsumerListConfig) => boolean;
9
- };
10
- visible: {
11
- type: BooleanConstructor;
12
- required: true;
13
- default: boolean;
14
- };
15
- }>, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
16
- cancel: () => any;
17
- "add:success": (consumers: string[]) => any;
18
- "add:partial-success": (consumers: string[]) => any;
19
- error: (msg: string) => any;
20
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
21
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
22
- config: {
23
- type: PropType<KonnectConsumerListConfig | KongManagerConsumerListConfig>;
24
- required: true;
25
- validator: (config: KonnectConsumerListConfig | KongManagerConsumerListConfig) => boolean;
26
- };
27
- visible: {
28
- type: BooleanConstructor;
29
- required: true;
30
- default: boolean;
31
- };
32
- }>> & Readonly<{
33
- onCancel?: (() => any) | undefined;
34
- "onAdd:success"?: ((consumers: string[]) => any) | undefined;
35
- "onAdd:partial-success"?: ((consumers: string[]) => any) | undefined;
36
- onError?: ((msg: string) => any) | undefined;
37
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
38
- export default _default;
39
- //# sourceMappingURL=AddConsumerModal.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AddConsumerModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddConsumerModal.vue"],"names":[],"mappings":"AAmSA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EACV,6BAA6B,EAC7B,yBAAyB,EAC1B,MAAM,UAAU,CAAA;;IA+af,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;;;;;;;;;;;;IAJzF,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;;;;;;;;;;;;AAT3F,wBAqBG"}
@@ -1,62 +0,0 @@
1
- import type { PropType } from 'vue';
2
- import type { AxiosError } from 'axios';
3
- import type { KongManagerConsumerEntityConfig, KonnectConsumerEntityConfig } from '../types';
4
- import '@kong-ui-public/entities-shared/dist/style.css';
5
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
6
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
7
- config: {
8
- type: PropType<KonnectConsumerEntityConfig | KongManagerConsumerEntityConfig>;
9
- required: true;
10
- validator: (config: KonnectConsumerEntityConfig | KongManagerConsumerEntityConfig) => boolean;
11
- };
12
- /**
13
- * External link for documentation that determines visibility of Documentation button
14
- */
15
- configCardDoc: {
16
- type: StringConstructor;
17
- default: string;
18
- required: false;
19
- };
20
- /**
21
- * Control visibility of card title content
22
- */
23
- hideTitle: {
24
- type: BooleanConstructor;
25
- default: boolean;
26
- };
27
- }>, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
28
- loading: (isLoading: boolean) => any;
29
- "fetch:success": (data: Record<string, any>) => any;
30
- "fetch:error": (error: AxiosError<unknown, any>) => any;
31
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
32
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
33
- config: {
34
- type: PropType<KonnectConsumerEntityConfig | KongManagerConsumerEntityConfig>;
35
- required: true;
36
- validator: (config: KonnectConsumerEntityConfig | KongManagerConsumerEntityConfig) => boolean;
37
- };
38
- /**
39
- * External link for documentation that determines visibility of Documentation button
40
- */
41
- configCardDoc: {
42
- type: StringConstructor;
43
- default: string;
44
- required: false;
45
- };
46
- /**
47
- * Control visibility of card title content
48
- */
49
- hideTitle: {
50
- type: BooleanConstructor;
51
- default: boolean;
52
- };
53
- }>> & Readonly<{
54
- onLoading?: ((isLoading: boolean) => any) | undefined;
55
- "onFetch:success"?: ((data: Record<string, any>) => any) | undefined;
56
- "onFetch:error"?: ((error: AxiosError<unknown, any>) => any) | undefined;
57
- }>, {
58
- configCardDoc: string;
59
- hideTitle: boolean;
60
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
61
- export default _default;
62
- //# sourceMappingURL=ConsumerConfigCard.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ConsumerConfigCard.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ConsumerConfigCard.vue"],"names":[],"mappings":"AAoHA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AACvC,OAAO,KAAK,EAAE,+BAA+B,EAAE,2BAA2B,EAA+B,MAAM,UAAU,CAAA;AAIzH,OAAO,gDAAgD,CAAA;;IA0OrD,oHAAoH;;cAElG,QAAQ,CAAC,2BAA2B,GAAG,+BAA+B,CAAC;;4BAEnE,2BAA2B,GAAG,+BAA+B,KAAG,OAAO;;IAQ7F;;OAEG;;;;;;IAMH;;OAEG;;;;;;;;;;IAtBH,oHAAoH;;cAElG,QAAQ,CAAC,2BAA2B,GAAG,+BAA+B,CAAC;;4BAEnE,2BAA2B,GAAG,+BAA+B,KAAG,OAAO;;IAQ7F;;OAEG;;;;;;IAMH;;OAEG;;;;;;;;;;;;;AA3BL,wBAiCG"}
@@ -1,43 +0,0 @@
1
- import '@kong-ui-public/entities-shared/dist/style.css';
2
- import type { PropType } from 'vue';
3
- import type { ConsumerStateFields, KongManagerConsumerFormConfig, KonnectConsumerFormConfig } from '../types';
4
- import type { AxiosError } from 'axios';
5
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
6
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
7
- config: {
8
- type: PropType<KonnectConsumerFormConfig | KongManagerConsumerFormConfig>;
9
- required: true;
10
- validator: (config: KonnectConsumerFormConfig | KongManagerConsumerFormConfig) => boolean;
11
- };
12
- /** If a valid consumerId is provided, it will put the form in Edit mode instead of Create */
13
- consumerId: {
14
- type: StringConstructor;
15
- required: false;
16
- default: string;
17
- };
18
- }>, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
19
- error: (error: AxiosError<unknown, any>) => any;
20
- loading: (isLoading: boolean) => any;
21
- update: (data: ConsumerStateFields) => any;
22
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
23
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
24
- config: {
25
- type: PropType<KonnectConsumerFormConfig | KongManagerConsumerFormConfig>;
26
- required: true;
27
- validator: (config: KonnectConsumerFormConfig | KongManagerConsumerFormConfig) => boolean;
28
- };
29
- /** If a valid consumerId is provided, it will put the form in Edit mode instead of Create */
30
- consumerId: {
31
- type: StringConstructor;
32
- required: false;
33
- default: string;
34
- };
35
- }>> & Readonly<{
36
- onError?: ((error: AxiosError<unknown, any>) => any) | undefined;
37
- onLoading?: ((isLoading: boolean) => any) | undefined;
38
- onUpdate?: ((data: ConsumerStateFields) => any) | undefined;
39
- }>, {
40
- consumerId: string;
41
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
42
- export default _default;
43
- //# sourceMappingURL=ConsumerForm.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ConsumerForm.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ConsumerForm.vue"],"names":[],"mappings":"AAqTA,OAAO,gDAAgD,CAAA;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EAGV,mBAAmB,EACnB,6BAA6B,EAC7B,yBAAyB,EAC1B,MAAM,UAAU,CAAA;AAEjB,OAAO,KAAK,EAAE,UAAU,EAAiB,MAAM,OAAO,CAAA;;IAsepD,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;IAQzF,6FAA6F;;;;;;;;;;;IAZ7F,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;IAQzF,6FAA6F;;;;;;;;;;;;;AAjB/F,wBAwBG"}
@@ -1,122 +0,0 @@
1
- import type { PropType } from 'vue';
2
- import type { AxiosError } from 'axios';
3
- import type { KongManagerConsumerListConfig, KonnectConsumerListConfig, EntityRow, CopyEventPayload } from '../types';
4
- import '@kong-ui-public/entities-shared/dist/style.css';
5
- declare var __VLS_14: {}, __VLS_59: {};
6
- type __VLS_Slots = {} & {
7
- 'toolbar-filter'?: (props: typeof __VLS_14) => any;
8
- } & {
9
- 'empty-state-toolbar'?: (props: typeof __VLS_59) => any;
10
- };
11
- declare const __VLS_component: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
12
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
13
- config: {
14
- type: PropType<KonnectConsumerListConfig | KongManagerConsumerListConfig>;
15
- required: true;
16
- validator: (config: KonnectConsumerListConfig | KongManagerConsumerListConfig) => boolean;
17
- };
18
- cacheIdentifier: {
19
- type: StringConstructor;
20
- default: string;
21
- };
22
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can create a new entity */
23
- canCreate: {
24
- type: PropType<() => boolean | Promise<boolean>>;
25
- required: false;
26
- default: () => Promise<boolean>;
27
- };
28
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can delete a given entity */
29
- canDelete: {
30
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
31
- required: false;
32
- default: () => Promise<boolean>;
33
- };
34
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can edit a given entity */
35
- canEdit: {
36
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
37
- required: false;
38
- default: () => Promise<boolean>;
39
- };
40
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can retrieve (view details) a given entity */
41
- canRetrieve: {
42
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
43
- required: false;
44
- default: () => Promise<boolean>;
45
- };
46
- /** default to false, setting to true will teleport the toolbar button to the destination in the consuming app */
47
- useActionOutside: {
48
- type: BooleanConstructor;
49
- default: boolean;
50
- };
51
- }>, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
52
- "add:success": (consumers: string[]) => any;
53
- error: (error: AxiosError<unknown, any>) => any;
54
- "click:learn-more": () => any;
55
- "copy:success": (payload: CopyEventPayload) => any;
56
- "copy:error": (payload: CopyEventPayload) => any;
57
- "delete:success": (consumer: EntityRow) => any;
58
- "remove:success": (consumer: EntityRow) => any;
59
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
60
- /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
61
- config: {
62
- type: PropType<KonnectConsumerListConfig | KongManagerConsumerListConfig>;
63
- required: true;
64
- validator: (config: KonnectConsumerListConfig | KongManagerConsumerListConfig) => boolean;
65
- };
66
- cacheIdentifier: {
67
- type: StringConstructor;
68
- default: string;
69
- };
70
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can create a new entity */
71
- canCreate: {
72
- type: PropType<() => boolean | Promise<boolean>>;
73
- required: false;
74
- default: () => Promise<boolean>;
75
- };
76
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can delete a given entity */
77
- canDelete: {
78
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
79
- required: false;
80
- default: () => Promise<boolean>;
81
- };
82
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can edit a given entity */
83
- canEdit: {
84
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
85
- required: false;
86
- default: () => Promise<boolean>;
87
- };
88
- /** A synchronous or asynchronous function, that returns a boolean, that evaluates if the user can retrieve (view details) a given entity */
89
- canRetrieve: {
90
- type: PropType<(row: EntityRow) => boolean | Promise<boolean>>;
91
- required: false;
92
- default: () => Promise<boolean>;
93
- };
94
- /** default to false, setting to true will teleport the toolbar button to the destination in the consuming app */
95
- useActionOutside: {
96
- type: BooleanConstructor;
97
- default: boolean;
98
- };
99
- }>> & Readonly<{
100
- "onAdd:success"?: ((consumers: string[]) => any) | undefined;
101
- onError?: ((error: AxiosError<unknown, any>) => any) | undefined;
102
- "onClick:learn-more"?: (() => any) | undefined;
103
- "onCopy:success"?: ((payload: CopyEventPayload) => any) | undefined;
104
- "onCopy:error"?: ((payload: CopyEventPayload) => any) | undefined;
105
- "onDelete:success"?: ((consumer: EntityRow) => any) | undefined;
106
- "onRemove:success"?: ((consumer: EntityRow) => any) | undefined;
107
- }>, {
108
- cacheIdentifier: string;
109
- canCreate: () => boolean | Promise<boolean>;
110
- canDelete: (row: EntityRow) => boolean | Promise<boolean>;
111
- canEdit: (row: EntityRow) => boolean | Promise<boolean>;
112
- canRetrieve: (row: EntityRow) => boolean | Promise<boolean>;
113
- useActionOutside: boolean;
114
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
115
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
116
- export default _default;
117
- type __VLS_WithSlots<T, S> = T & {
118
- new (): {
119
- $slots: S;
120
- };
121
- };
122
- //# sourceMappingURL=ConsumerList.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ConsumerList.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ConsumerList.vue"],"names":[],"mappings":"AA2sBA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAkBvC,OAAO,KAAK,EACV,6BAA6B,EAC7B,yBAAyB,EACzB,SAAS,EACT,gBAAgB,EACjB,MAAM,UAAU,CAAA;AAQjB,OAAO,gDAAgD,CAAA;AAqqCvD,QAAA,IAAI,QAAQ,IAAW,EAAE,QAAQ,IAAY,CAAE;AAC/C,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,gBAAgB,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,GACtD;IAAE,qBAAqB,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,CAAC;AAoH9D,QAAA,MAAM,eAAe;IAKnB,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;;;;;IAYzF,yHAAyH;;cAErG,QAAQ,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI9D,2HAA2H;;cAEvG,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,yHAAyH;;cAErG,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,4IAA4I;;cAExH,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,iHAAiH;;;;;;;;;;;;;;IAxCjH,oHAAoH;;cAElG,QAAQ,CAAC,yBAAyB,GAAG,6BAA6B,CAAC;;4BAE/D,yBAAyB,GAAG,6BAA6B,KAAG,OAAO;;;;;;IAYzF,yHAAyH;;cAErG,QAAQ,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI9D,2HAA2H;;cAEvG,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,yHAAyH;;cAErG,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,4IAA4I;;cAExH,QAAQ,CAAC,CAAC,GAAG,EAAE,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;;;;IAI5E,iHAAiH;;;;;;;;;;;;;;;qBAtB9E,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;qBAM1B,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;mBAMxC,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;uBAMxC,SAAS,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;;4EAU3E,CAAC;wBACkB,eAAe,CAAC,OAAO,eAAe,EAAE,WAAW,CAAC;AAAzE,wBAA0E;AAE1E,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,6 +0,0 @@
1
- import useI18n from './useI18n';
2
- declare const _default: {
3
- useI18n: typeof useI18n;
4
- };
5
- export default _default;
6
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/index.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,WAAW,CAAA;;;;AAG/B,wBAEC"}
@@ -1,9 +0,0 @@
1
- import { createI18n, i18nTComponent } from '@kong-ui-public/i18n';
2
- import english from '../locales/en.json';
3
- interface UseI18nReturn {
4
- i18n: ReturnType<typeof createI18n<typeof english>>;
5
- i18nT: ReturnType<typeof i18nTComponent<typeof english>>;
6
- }
7
- export default function useI18n(): UseI18nReturn;
8
- export {};
9
- //# sourceMappingURL=useI18n.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useI18n.d.ts","sourceRoot":"","sources":["../../../src/composables/useI18n.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AACjE,OAAO,OAAO,MAAM,oBAAoB,CAAA;AAExC,UAAU,aAAa;IACrB,IAAI,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,OAAO,OAAO,CAAC,CAAC,CAAA;IACnD,KAAK,EAAE,UAAU,CAAC,OAAO,cAAc,CAAC,OAAO,OAAO,CAAC,CAAC,CAAA;CACzD;AAED,MAAM,CAAC,OAAO,UAAU,OAAO,IAAI,aAAa,CAO/C"}
@@ -1,26 +0,0 @@
1
- declare const _default: {
2
- list: {
3
- konnect: {
4
- all: string;
5
- forConsumerGroup: string;
6
- oneForConsumerGroup: string;
7
- };
8
- kongManager: {
9
- all: string;
10
- forConsumerGroup: string;
11
- oneForConsumerGroup: string;
12
- };
13
- };
14
- form: {
15
- konnect: {
16
- create: string;
17
- edit: string;
18
- };
19
- kongManager: {
20
- create: string;
21
- edit: string;
22
- };
23
- };
24
- };
25
- export default _default;
26
- //# sourceMappingURL=consumers-endpoints.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"consumers-endpoints.d.ts","sourceRoot":"","sources":["../../src/consumers-endpoints.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAGA,wBAyBC"}
@@ -1,6 +0,0 @@
1
- import ConsumerList from './components/ConsumerList.vue';
2
- import ConsumerForm from './components/ConsumerForm.vue';
3
- import ConsumerConfigCard from './components/ConsumerConfigCard.vue';
4
- export { ConsumerList, ConsumerForm, ConsumerConfigCard };
5
- export * from './types';
6
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,+BAA+B,CAAA;AACxD,OAAO,YAAY,MAAM,+BAA+B,CAAA;AACxD,OAAO,kBAAkB,MAAM,qCAAqC,CAAA;AAEpE,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,kBAAkB,EAAE,CAAA;AAEzD,cAAc,SAAS,CAAA"}
@@ -1,18 +0,0 @@
1
- import type { KonnectBaseEntityConfig, KongManagerBaseEntityConfig, ConfigurationSchemaItem } from '@kong-ui-public/entities-shared';
2
- /** Konnect Consumer entity config */
3
- export interface KonnectConsumerEntityConfig extends KonnectBaseEntityConfig {
4
- }
5
- /** Kong Manager Consumer entity config */
6
- export interface KongManagerConsumerEntityConfig extends KongManagerBaseEntityConfig {
7
- }
8
- export interface ConsumerConfigurationSchema {
9
- id: ConfigurationSchemaItem;
10
- username: ConfigurationSchemaItem;
11
- custom_id: ConfigurationSchemaItem;
12
- updated_at: ConfigurationSchemaItem;
13
- created_at: ConfigurationSchemaItem;
14
- tags: ConfigurationSchemaItem;
15
- username_lower: ConfigurationSchemaItem;
16
- type: ConfigurationSchemaItem;
17
- }
18
- //# sourceMappingURL=consumer-config-card.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"consumer-config-card.d.ts","sourceRoot":"","sources":["../../../src/types/consumer-config-card.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,2BAA2B,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAA;AAEpI,qCAAqC;AACrC,MAAM,WAAW,2BAA4B,SAAQ,uBAAuB;CAAG;AAE/E,0CAA0C;AAC1C,MAAM,WAAW,+BAAgC,SAAQ,2BAA2B;CAAG;AAEvF,MAAM,WAAW,2BAA2B;IAE1C,EAAE,EAAE,uBAAuB,CAAA;IAC3B,QAAQ,EAAE,uBAAuB,CAAA;IACjC,SAAS,EAAE,uBAAuB,CAAA;IAClC,UAAU,EAAE,uBAAuB,CAAA;IACnC,UAAU,EAAE,uBAAuB,CAAA;IACnC,IAAI,EAAE,uBAAuB,CAAA;IAC7B,cAAc,EAAE,uBAAuB,CAAA;IACvC,IAAI,EAAE,uBAAuB,CAAA;CAC9B"}
@@ -1,28 +0,0 @@
1
- import type { RouteLocationRaw } from 'vue-router';
2
- import type { BaseFormConfig, KongManagerBaseFormConfig, KonnectBaseFormConfig } from '@kong-ui-public/entities-shared';
3
- export interface BaseConsumerFormConfig extends Omit<BaseFormConfig, 'cancelRoute'> {
4
- /** Route to return to if canceling create/edit a Consumer form */
5
- cancelRoute: RouteLocationRaw;
6
- }
7
- /** Konnect Consumer form config */
8
- export interface KonnectConsumerFormConfig extends Omit<KonnectBaseFormConfig, 'cancelRoute'>, BaseConsumerFormConfig {
9
- }
10
- /** Kong Manager Consumer form config */
11
- export interface KongManagerConsumerFormConfig extends Omit<KongManagerBaseFormConfig, 'cancelRoute'>, BaseConsumerFormConfig {
12
- }
13
- export interface ConsumerStateFields {
14
- username: string;
15
- customId: string;
16
- tags: string;
17
- }
18
- export interface ConsumerPayload {
19
- username: string | null;
20
- custom_id: string | null;
21
- tags: string[];
22
- }
23
- export interface ConsumerState {
24
- fields: ConsumerStateFields;
25
- readonly: boolean;
26
- errorMessage: string;
27
- }
28
- //# sourceMappingURL=consumer-form.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"consumer-form.d.ts","sourceRoot":"","sources":["../../../src/types/consumer-form.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAA;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,yBAAyB,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAA;AAEvH,MAAM,WAAW,sBAAuB,SAAQ,IAAI,CAAC,cAAc,EAAE,aAAa,CAAC;IACjF,kEAAkE;IAClE,WAAW,EAAE,gBAAgB,CAAA;CAC9B;AAED,mCAAmC;AACnC,MAAM,WAAW,yBAA0B,SAAQ,IAAI,CAAC,qBAAqB,EAAE,aAAa,CAAC,EAAE,sBAAsB;CAAG;AAExH,wCAAwC;AACxC,MAAM,WAAW,6BAA8B,SAAQ,IAAI,CAAC,yBAAyB,EAAE,aAAa,CAAC,EAAE,sBAAsB;CAAG;AAEhI,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,MAAM,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,MAAM,CAAA;CACb;AAED,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAA;IACvB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,IAAI,EAAE,MAAM,EAAE,CAAA;CACf;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,mBAAmB,CAAA;IAC3B,QAAQ,EAAE,OAAO,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;CACrB"}
@@ -1,39 +0,0 @@
1
- import type { RouteLocationRaw } from 'vue-router';
2
- import type { FilterSchema, KongManagerBaseTableConfig, KonnectBaseTableConfig } from '@kong-ui-public/entities-shared';
3
- export interface BaseConsumerListConfig {
4
- /** Current consumer group id if the ConsumerList in nested in the consumers tab on a consumer group detail page */
5
- consumerGroupId?: string;
6
- /** Current consumer group name if the ConsumerList in nested in the consumers tab on a consumer group detail page */
7
- consumerGroupName?: string;
8
- /** Route for creating a consumer */
9
- createRoute: RouteLocationRaw;
10
- /** A boolean to indicate if the paginated endpoint is used when consumerGroupId is provided */
11
- paginatedEndpoint?: boolean;
12
- /** A function that returns the route for viewing a consumer */
13
- getViewRoute: (id: string) => RouteLocationRaw;
14
- /** A function that returns the route for editing a consumer */
15
- getEditRoute: (id: string) => RouteLocationRaw;
16
- }
17
- /** Konnect route list config */
18
- export interface KonnectConsumerListConfig extends KonnectBaseTableConfig, BaseConsumerListConfig {
19
- }
20
- /** Kong Manager route list config */
21
- export interface KongManagerConsumerListConfig extends KongManagerBaseTableConfig, BaseConsumerListConfig {
22
- /** FilterSchema for fuzzy match */
23
- filterSchema?: FilterSchema;
24
- }
25
- export interface EntityRow extends Record<string, any> {
26
- id: string;
27
- username: string;
28
- custom_id: string;
29
- }
30
- /** Copy field event payload */
31
- export interface CopyEventPayload {
32
- /** The entity row */
33
- entity: EntityRow;
34
- /** The field being copied. If omitted, the entity JSON is being copied. */
35
- field?: string;
36
- /** The toaster message */
37
- message: string;
38
- }
39
- //# sourceMappingURL=consumer-list.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"consumer-list.d.ts","sourceRoot":"","sources":["../../../src/types/consumer-list.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAA;AAClD,OAAO,KAAK,EACV,YAAY,EACZ,0BAA0B,EAC1B,sBAAsB,EACvB,MAAM,iCAAiC,CAAA;AAExC,MAAM,WAAW,sBAAsB;IACrC,mHAAmH;IACnH,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,qHAAqH;IACrH,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,oCAAoC;IACpC,WAAW,EAAE,gBAAgB,CAAA;IAC7B,+FAA+F;IAC/F,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,+DAA+D;IAC/D,YAAY,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,gBAAgB,CAAA;IAC9C,+DAA+D;IAC/D,YAAY,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,gBAAgB,CAAA;CAC/C;AAED,gCAAgC;AAChC,MAAM,WAAW,yBAA0B,SAAQ,sBAAsB,EAAE,sBAAsB;CAAG;AAEpG,qCAAqC;AACrC,MAAM,WAAW,6BAA8B,SAAQ,0BAA0B,EAAE,sBAAsB;IACvG,mCAAmC;IACnC,YAAY,CAAC,EAAE,YAAY,CAAA;CAC5B;AAED,MAAM,WAAW,SAAU,SAAQ,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;IACpD,EAAE,EAAE,MAAM,CAAA;IACV,QAAQ,EAAE,MAAM,CAAA;IAChB,SAAS,EAAE,MAAM,CAAA;CAClB;AAED,+BAA+B;AAC/B,MAAM,WAAW,gBAAgB;IAC/B,qBAAqB;IACrB,MAAM,EAAE,SAAS,CAAA;IACjB,2EAA2E;IAC3E,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,0BAA0B;IAC1B,OAAO,EAAE,MAAM,CAAA;CAChB"}
@@ -1,4 +0,0 @@
1
- export * from './consumer-list';
2
- export * from './consumer-form';
3
- export * from './consumer-config-card';
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAGA,cAAc,iBAAiB,CAAA;AAC/B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,wBAAwB,CAAA"}