@kong-ui-public/dashboard-renderer 0.0.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.
- package/LICENSE +201 -0
- package/README.md +71 -0
- package/dist/dashboard-renderer.es.js +693 -0
- package/dist/dashboard-renderer.umd.js +1 -0
- package/dist/style.css +1 -0
- package/dist/types/components/AnalyticsChartRenderer.vue.d.ts +38 -0
- package/dist/types/components/AnalyticsChartRenderer.vue.d.ts.map +1 -0
- package/dist/types/components/DashboardRenderer.vue.d.ts +58 -0
- package/dist/types/components/DashboardRenderer.vue.d.ts.map +1 -0
- package/dist/types/components/DashboardTile.vue.d.ts +47 -0
- package/dist/types/components/DashboardTile.vue.d.ts.map +1 -0
- package/dist/types/components/QueryDataProvider.vue.d.ts +34 -0
- package/dist/types/components/QueryDataProvider.vue.d.ts.map +1 -0
- package/dist/types/components/SimpleChartRenderer.vue.d.ts +42 -0
- package/dist/types/components/SimpleChartRenderer.vue.d.ts.map +1 -0
- package/dist/types/composables/index.d.ts +6 -0
- package/dist/types/composables/index.d.ts.map +1 -0
- package/dist/types/composables/useI18n.d.ts +62 -0
- package/dist/types/composables/useI18n.d.ts.map +1 -0
- package/dist/types/index.d.ts +4 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/mock-data.d.ts +25 -0
- package/dist/types/mock-data.d.ts.map +1 -0
- package/dist/types/types/dashboard-renderer-types.d.ts +182 -0
- package/dist/types/types/dashboard-renderer-types.d.ts.map +1 -0
- package/dist/types/types/index.d.ts +2 -0
- package/dist/types/types/index.d.ts.map +1 -0
- package/dist/types/types/query-provider.d.ts +5 -0
- package/dist/types/types/query-provider.d.ts.map +1 -0
- package/package.json +77 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(m,a){typeof exports=="object"&&typeof module<"u"?a(exports,require("vue"),require("@kong-ui-public/analytics-chart"),require("@kong-ui-public/i18n")):typeof define=="function"&&define.amd?define(["exports","vue","@kong-ui-public/analytics-chart","@kong-ui-public/i18n"],a):(m=typeof globalThis<"u"?globalThis:m||self,a(m["kong-ui-public-dashboard-renderer"]={},m.Vue,m["kong-ui-public-analytics-chart"],m["kong-ui-public-i18n"]))})(this,function(m,a,E,H){"use strict";var A=(e=>(e.HorizontalBar="horizontal_bar",e.VerticalBar="vertical_bar",e.Gauge="gauge",e))(A||{});const K={type:"string"},z={type:"object",properties:{type:{type:"string",enum:["horizontal_bar","vertical_bar"]},stacked:{type:"boolean"},syntheticsDataKey:K},required:["type"],additionalProperties:!1},F={type:"object",properties:{type:{type:"string",enum:["gauge"]},metricDisplay:{type:"string",enum:Object.values(E.ChartMetricDisplay)},reverseDataset:{type:"boolean"},numerator:{type:"number"},syntheticsDataKey:K},required:["type"],additionalProperties:!1},U={type:"object",properties:{query:{type:"object"},chart:{oneOf:[z,F]},title:{type:"string"}},required:["chart","query"],additionalProperties:!1},le={type:"object",properties:{tiles:{type:"array",items:U}},required:["tiles"],additionalProperties:!1},qe="";var V=new WeakMap,M=0;function se(e){if(!e.length)return"";for(var n="arg",t=0;t<e.length;++t){var o=void 0;e[t]===null||typeof e[t]!="object"&&typeof e[t]!="function"?typeof e[t]=="string"?o='"'+e[t]+'"':o=String(e[t]):V.has(e[t])?o=V.get(e[t]):(o=M,V.set(e[t],M++)),n+="@"+o}return n}function ce(e){if(typeof e=="function")try{e=e()}catch{e=""}return Array.isArray(e)?e=se(e):e=String(e||""),e}var B=function(){function e(n){n===void 0&&(n=0),this.items=new Map,this.ttl=n}return e.prototype.serializeKey=function(n){return ce(n)},e.prototype.get=function(n){var t=this.serializeKey(n);return this.items.get(t)},e.prototype.set=function(n,t,o){var i=this.serializeKey(n),r=o||this.ttl,s=Date.now(),d={data:t,createdAt:s,expiresAt:r?s+r:1/0};this.dispatchExpire(r,d,i),this.items.set(i,d)},e.prototype.dispatchExpire=function(n,t,o){var i=this;n&&setTimeout(function(){var r=Date.now(),s=r>=t.expiresAt;s&&i.delete(o)},n)},e.prototype.delete=function(n){this.items.delete(n)},e}();function ue(){return typeof navigator.onLine<"u"?navigator.onLine:!0}function de(){return typeof document<"u"&&typeof document.visibilityState<"u"?document.visibilityState!=="hidden":!0}var fe=function(e){return fetch(e).then(function(n){return n.json()})};const L={isOnline:ue,isDocumentVisible:de,fetcher:fe};var R=globalThis&&globalThis.__assign||function(){return R=Object.assign||function(e){for(var n,t=1,o=arguments.length;t<o;t++){n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},R.apply(this,arguments)},T=globalThis&&globalThis.__awaiter||function(e,n,t,o){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function d(u){try{l(o.next(u))}catch(v){s(v)}}function h(u){try{l(o.throw(u))}catch(v){s(v)}}function l(u){u.done?r(u.value):i(u.value).then(d,h)}l((o=o.apply(e,n||[])).next())})},D=globalThis&&globalThis.__generator||function(e,n){var t={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},o,i,r,s;return s={next:d(0),throw:d(1),return:d(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function d(l){return function(u){return h([l,u])}}function h(l){if(o)throw new TypeError("Generator is already executing.");for(;t;)try{if(o=1,i&&(r=l[0]&2?i.return:l[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,l[1])).done)return r;switch(i=0,r&&(l=[l[0]&2,r.value]),l[0]){case 0:case 1:r=l;break;case 4:return t.label++,{value:l[1],done:!1};case 5:t.label++,i=l[1],l=[0];continue;case 7:l=t.ops.pop(),t.trys.pop();continue;default:if(r=t.trys,!(r=r.length>0&&r[r.length-1])&&(l[0]===6||l[0]===2)){t=0;continue}if(l[0]===3&&(!r||l[1]>r[0]&&l[1]<r[3])){t.label=l[1];break}if(l[0]===6&&t.label<r[1]){t.label=r[1],r=l;break}if(r&&t.label<r[2]){t.label=r[2],t.ops.push(l);break}r[2]&&t.ops.pop(),t.trys.pop();continue}l=n.call(e,t)}catch(u){l=[6,u],i=0}finally{o=r=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},ye=globalThis&&globalThis.__read||function(e,n){var t=typeof Symbol=="function"&&e[Symbol.iterator];if(!t)return e;var o=t.call(e),i,r=[],s;try{for(;(n===void 0||n-- >0)&&!(i=o.next()).done;)r.push(i.value)}catch(d){s={error:d}}finally{try{i&&!i.done&&(t=o.return)&&t.call(o)}finally{if(s)throw s.error}}return r},he=globalThis&&globalThis.__spreadArray||function(e,n,t){if(t||arguments.length===2)for(var o=0,i=n.length,r;o<i;o++)(r||!(o in n))&&(r||(r=Array.prototype.slice.call(n,0,o)),r[o]=n[o]);return e.concat(r||Array.prototype.slice.call(n))},$=new B,q=new B,N=new B,Q={cache:$,refreshInterval:0,ttl:0,serverTTL:1e3,dedupingInterval:2e3,revalidateOnFocus:!0,revalidateDebounce:0,shouldRetryOnError:!0,errorRetryInterval:5e3,errorRetryCount:5,fetcher:L.fetcher,isOnline:L.isOnline,isDocumentVisible:L.isDocumentVisible};function pe(e,n,t){var o=q.get(e);if(o)o.data.push(n);else{var i=5e3;q.set(e,[n],t>0?t+i:t)}}function ve(e,n,t){if(t.isDocumentVisible()&&!(t.errorRetryCount!==void 0&&n>t.errorRetryCount)){var o=Math.min(n||0,t.errorRetryCount),i=o*t.errorRetryInterval;setTimeout(function(){e(null,{errorRetryCount:o+1,shouldRetryOnError:!0})},i)}}var W=function(e,n,t,o){return t===void 0&&(t=$),o===void 0&&(o=Q.ttl),T(void 0,void 0,void 0,function(){var i,r,s,d,h,l,u;return D(this,function(v){switch(v.label){case 0:if(!_e(n))return[3,5];v.label=1;case 1:return v.trys.push([1,3,,4]),[4,n];case 2:return i=v.sent(),[3,4];case 3:return d=v.sent(),r=d,[3,4];case 4:return[3,6];case 5:i=n,v.label=6;case 6:if(s=!1,h={data:i,error:r,isValidating:s},typeof i<"u")try{t.set(e,h,o)}catch(p){console.error("swrv(mutate): failed to set cache",p)}return l=q.get(e),l&&l.data.length&&(u=l.data.filter(function(p){return p.key===e}),u.forEach(function(p,f){typeof h.data<"u"&&(p.data=h.data),p.error=h.error,p.isValidating=h.isValidating;var g=f===u.length-1;g||delete u[f]}),u=u.filter(Boolean)),[2,h]}})})};function me(){for(var e=this,n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];var o,i,r=R({},Q),s=!1,d=!1,h=a.getCurrentInstance(),l=(h==null?void 0:h.proxy)||h;if(!l)return console.error("Could not get current instance, check to make sure that `useSwrv` is declared in the top level of the setup function."),null;var u=(l==null?void 0:l.$isServer)||!1;n.length>=1&&(o=n[0]),n.length>=2&&(i=n[1]),n.length>2&&(r=R(R({},r),n[2]));var v=u?r.serverTTL:r.ttl,p=typeof o=="function"?o:a.ref(o);typeof i>"u"&&(i=r.fetcher);var f=null;f||(f=a.reactive({data:void 0,error:void 0,isValidating:!0,key:null}));var g=function(y,c){return T(e,void 0,void 0,function(){var re,_,w,I,x,ne,P,ae=this;return D(this,function(j){switch(j.label){case 0:return re=f.data===void 0,_=p.value,_?(w=r.cache.get(_),I=w&&w.data,f.isValidating=!0,I&&(f.data=I.data,f.error=I.error),x=y||i,!x||!r.isDocumentVisible()&&!re||(c==null?void 0:c.forceRevalidate)!==void 0&&!(c!=null&&c.forceRevalidate)?(f.isValidating=!1,[2]):w&&(ne=!!(Date.now()-w.createdAt>=r.dedupingInterval||c!=null&&c.forceRevalidate),!ne)?(f.isValidating=!1,[2]):(P=function(){return T(ae,void 0,void 0,function(){var C,ie,G,oe;return D(this,function(O){switch(O.label){case 0:return C=N.get(_),C?[3,2]:(ie=Array.isArray(_)?_:[_],G=x.apply(void 0,he([],ye(ie),!1)),N.set(_,G,r.dedupingInterval),[4,W(_,G,r.cache,v)]);case 1:return O.sent(),[3,4];case 2:return[4,W(_,C.data,r.cache,v)];case 3:O.sent(),O.label=4;case 4:return f.isValidating=!1,N.delete(_),f.error!==void 0&&(oe=!s&&r.shouldRetryOnError&&(c?c.shouldRetryOnError:!0),oe&&ve(g,c?c.errorRetryCount:1,r)),[2]}})})},I&&r.revalidateDebounce?(setTimeout(function(){return T(ae,void 0,void 0,function(){return D(this,function(C){switch(C.label){case 0:return s?[3,2]:[4,P()];case 1:C.sent(),C.label=2;case 2:return[2]}})})},r.revalidateDebounce),[3,3]):[3,1])):[2];case 1:return[4,P()];case 2:j.sent(),j.label=3;case 3:return[2]}})})},S=function(){return T(e,void 0,void 0,function(){return D(this,function(y){return[2,g(null,{shouldRetryOnError:!1})]})})},b=null;a.onMounted(function(){var y=function(){return T(e,void 0,void 0,function(){return D(this,function(c){switch(c.label){case 0:return!f.error&&r.isOnline()?[4,g()]:[3,2];case 1:return c.sent(),[3,3];case 2:b&&clearTimeout(b),c.label=3;case 3:return r.refreshInterval&&!s&&(b=setTimeout(y,r.refreshInterval)),[2]}})})};r.refreshInterval&&(b=setTimeout(y,r.refreshInterval)),r.revalidateOnFocus&&(document.addEventListener("visibilitychange",S,!1),window.addEventListener("focus",S,!1))}),a.onUnmounted(function(){s=!0,b&&clearTimeout(b),r.revalidateOnFocus&&(document.removeEventListener("visibilitychange",S,!1),window.removeEventListener("focus",S,!1));var y=q.get(p.value);y&&(y.data=y.data.filter(function(c){return c!==f}))});try{a.watch(p,function(y){a.isReadonly(p)||(p.value=y),f.key=y,f.isValidating=!!y,pe(p.value,f,v),!u&&!d&&p.value&&g(),d=!1},{immediate:!0})}catch{}var k=R(R({},a.toRefs(f)),{mutate:function(y,c){return g(y,R(R({},c),{forceRevalidate:!0}))}});return k}function _e(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}const J="analytics-query-provider";var Y=(e=>(e.VALIDATING="VALIDATING",e.VALIDATING_HAS_DATA="VALIDATING_HAS_DATA",e.PENDING="PENDING",e.SUCCESS="SUCCESS",e.SUCCESS_HAS_DATA="SUCCESS_HAS_DATA",e.ERROR="ERROR",e.STALE_IF_ERROR="STALE_IF_ERROR",e))(Y||{});const ge=e=>{var n,t,o,i,r;return e?!!((n=Object.keys(e))!=null&&n.length||(t=e.data)!=null&&t.length||(i=(o=e.data)==null?void 0:o.data)!=null&&i.length||!((r=e.data)!=null&&r.data)&&typeof e.data=="object"&&Object.keys(e==null?void 0:e.data).length):!1};function be(e=a.ref({}),n,t,o=ge){const i=a.ref("PENDING");return a.watchEffect(()=>{const r=o(e.value);if(e.value&&r&&t.value){i.value="VALIDATING_HAS_DATA";return}if(e.value&&t.value){i.value="VALIDATING";return}if(e.value&&n.value){i.value="STALE_IF_ERROR";return}if(e.value===void 0&&!n.value){i.value="PENDING";return}if(e.value&&!n.value&&r){i.value="SUCCESS_HAS_DATA";return}if(e.value&&!n.value){i.value="SUCCESS";return}e.value===void 0&&n&&(i.value="ERROR")}),{state:i,swrvState:Y}}const Re={renderer:{noQueryBridge:"No query bridge provided. Unable to render dashboard."},queryDataProvider:{timeRangeExceeded:"The time range for this report is outside of your organization's data retention period"}};function Se(){const e=H.createI18n("en-us",Re);return{i18n:e,i18nT:H.i18nTComponent(e)}}const Z={useI18n:Se},X=a.defineComponent({__name:"QueryDataProvider",props:{query:{},queryReady:{type:Boolean}},emits:["queryComplete"],setup(e,{emit:n}){const t=e,{i18n:o}=Z.useI18n(),i=a.inject(J),r=()=>t.queryReady&&i?JSON.stringify(t.query):null,s=new AbortController;a.onUnmounted(()=>{s.abort()});const{data:d,error:h,isValidating:l}=me(r,async()=>{var S,b,k,y;try{return i==null?void 0:i.query(t.query,s)}catch(c){p.value=((b=(S=c==null?void 0:c.response)==null?void 0:S.data)==null?void 0:b.message)==="Range not allowed for this tier"?o.t("queryDataProvider.timeRangeExceeded"):((y=(k=c==null?void 0:c.response)==null?void 0:k.data)==null?void 0:y.message)||(c==null?void 0:c.message)}finally{n("queryComplete")}}),{state:u,swrvState:v}=be(d,h,l),p=a.ref(null),f=a.computed(()=>u.value===v.ERROR||!!p.value),g=a.computed(()=>!t.queryReady||u.value===v.PENDING);return(S,b)=>{const k=a.resolveComponent("KSkeleton"),y=a.resolveComponent("KEmptyState");return g.value||!a.unref(d)&&!f.value?(a.openBlock(),a.createBlock(k,{key:0,class:"chart-skeleton",type:"table"})):!g.value&&f.value?(a.openBlock(),a.createBlock(y,{key:1,"cta-is-hidden":"","data-testid":"chart-empty-state","is-error":""},{message:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(p.value),1)]),_:1})):a.renderSlot(S.$slots,"default",{key:2,data:a.unref(d)})}}}),Ae=a.defineComponent({__name:"SimpleChartRenderer",props:{query:{},queryReady:{type:Boolean},chartOptions:{}},setup(e){const n=e,t={[A.Gauge]:E.ChartTypesSimple.GAUGE},o=a.computed(()=>({...n.chartOptions,type:t[n.chartOptions.type]}));return(i,r)=>(a.openBlock(),a.createBlock(X,{query:n.query,"query-ready":n.queryReady},{default:a.withCtx(({data:s})=>[a.createVNode(a.unref(E.SimpleChart),{"chart-data":s,"chart-options":o.value,"synthetics-data-key":n.chartOptions.syntheticsDataKey},null,8,["chart-data","chart-options","synthetics-data-key"])]),_:1},8,["query","query-ready"]))}}),ee=a.defineComponent({__name:"AnalyticsChartRenderer",props:{query:{},queryReady:{type:Boolean},chartOptions:{}},setup(e){const n=e,t={[A.HorizontalBar]:E.ChartTypes.HORIZONTAL_BAR,[A.VerticalBar]:E.ChartTypes.VERTICAL_BAR},o=a.computed(()=>({type:t[n.chartOptions.type]}));return(i,r)=>(a.openBlock(),a.createBlock(X,{query:n.query,"query-ready":n.queryReady},{default:a.withCtx(({data:s})=>[a.createVNode(a.unref(E.AnalyticsChart),{"chart-data":s,"chart-options":o.value,"chart-title":"","tooltip-title":""},null,8,["chart-data","chart-options"])]),_:1},8,["query","query-ready"]))}}),Ce={class:"tile-boundary"},Ee={key:0},Te=a.defineComponent({__name:"DashboardTile",props:{definition:{}},setup(e){const n=e,t=a.computed(()=>n.definition.title),o={[A.HorizontalBar]:ee,[A.VerticalBar]:ee,[A.Gauge]:Ae},i=a.computed(()=>({component:o[n.definition.chart.type],rendererProps:{query:n.definition.query,queryReady:!0,chartOptions:n.definition.chart}}));return(r,s)=>(a.openBlock(),a.createElementBlock("div",Ce,[t.value?(a.openBlock(),a.createElementBlock("h2",Ee,a.toDisplayString(t.value),1)):a.createCommentVNode("",!0),i.value?(a.openBlock(),a.createBlock(a.resolveDynamicComponent(i.value.component),a.normalizeProps(a.mergeProps({key:1},i.value.rendererProps)),null,16)):a.createCommentVNode("",!0)]))}}),Be="",te=(e,n)=>{const t=e.__vccOpts||e;for(const[o,i]of n)t[o]=i;return t},De=te(Te,[["__scopeId","data-v-eb4fff82"]]),ke={class:"kong-ui-public-dashboard-renderer"},we=a.defineComponent({__name:"DashboardRenderer",props:{context:{},definition:{}},setup(e){const n=e,{i18n:t}=Z.useI18n(),o=a.inject(J);return(i,r)=>{const s=a.resolveComponent("KAlert");return a.openBlock(),a.createElementBlock("div",ke,[a.unref(o)?(a.openBlock(!0),a.createElementBlock(a.Fragment,{key:1},a.renderList(n.definition.tiles,(d,h)=>(a.openBlock(),a.createBlock(De,{key:h,definition:d},null,8,["definition"]))),128)):(a.openBlock(),a.createBlock(s,{key:0,appearance:"danger"},{default:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(a.unref(t).t("renderer.noQueryBridge")),1)]),_:1}))])}}}),Le="",Ie=te(we,[["__scopeId","data-v-d6a56abf"]]);m.ChartTypes=A,m.DashboardRenderer=Ie,m.barChartSchema=z,m.dashboardDefinitionSchema=le,m.gaugeChartSchema=F,m.tileSchema=U,Object.defineProperty(m,Symbol.toStringTag,{value:"Module"})});
|
package/dist/style.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.locked[data-v-c0b7c451]{cursor:move}.tooltip-container[data-v-c0b7c451]{background-color:#fff;border-radius:3px;box-shadow:0 5px 15px #0000001f,0 5px 10px #0000003d;max-width:425px;min-width:250px;position:absolute;transition:all .3s cubic-bezier(.25,.8,.25,1);z-index:999}.tooltip-container .tooltip-title[data-v-c0b7c451]{border-bottom:1px solid rgba(0,0,0,.1);display:flex;flex-direction:column;margin:8px;min-height:24px;padding-bottom:8px}.tooltip-container .tooltip-title .title[data-v-c0b7c451]{font-size:16px;font-weight:600}.tooltip-container .tooltip-title .subtitle[data-v-c0b7c451]{font-size:14px;margin-top:8px}.tooltip-container .tooltip-title .drag-icon[data-v-c0b7c451]{margin-top:6px;position:absolute;right:0;top:0}ul.tooltip[data-v-c0b7c451]{list-style:none;margin:0;max-height:300px;min-width:250px;overflow-y:scroll;padding-left:0;scrollbar-width:thin}ul.tooltip[data-v-c0b7c451]::-webkit-scrollbar-track{background-color:#fff;border-radius:10px}ul.tooltip[data-v-c0b7c451]::-webkit-scrollbar{width:10px}ul.tooltip[data-v-c0b7c451]::-webkit-scrollbar-thumb{background-color:#e0e4ea;border-radius:10px}ul.tooltip li[data-v-c0b7c451]{display:flex;font-size:14px;margin:8px}ul.tooltip li[data-v-c0b7c451]:last-child{padding-bottom:8px}ul.tooltip .display-label[data-v-c0b7c451]{max-width:75%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}ul.tooltip .display-value[data-v-c0b7c451]{margin-left:auto;padding-left:8px;white-space:nowrap}ul.tooltip .tooltip-legend[data-v-c0b7c451]{display:inline-flex;flex-direction:row;height:15px;margin-right:8px;width:3px}.legend-container[data-v-22ddf722]{display:flex;max-height:inherit;-ms-overflow-style:thin;overflow-x:hidden;overflow-y:scroll;padding-left:12px;scrollbar-width:thin}.legend-container.vertical[data-v-22ddf722]{flex-direction:column;max-height:400px;max-width:15%;word-break:break-word}@media (max-width: 767px){.legend-container.vertical[data-v-22ddf722]{flex-direction:row;height:20%;max-width:100%;width:100%}}.legend-container.horizontal[data-v-22ddf722]{column-gap:2px;display:grid;justify-content:center;max-height:15%;width:100%}.legend-container.horizontal .truncate-label[data-v-22ddf722]{max-width:15ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.legend-container[data-v-22ddf722]::-webkit-scrollbar-track{background-color:#fff;border-radius:10px}.legend-container[data-v-22ddf722]::-webkit-scrollbar{width:10px}.legend-container[data-v-22ddf722]::-webkit-scrollbar-thumb{background-color:#e0e4ea;border-radius:10px}.legend-container li[data-v-22ddf722]{align-items:start;cursor:pointer;display:flex;margin-top:16px}.legend-container li .legend[data-v-22ddf722]{flex:0 0 14px;height:3px;margin-right:12px;margin-top:6px}.legend-container li .label[data-v-22ddf722]{font-size:14px;line-height:18px}.legend-container li .sub-label[data-v-22ddf722]{font-size:12px;line-height:14px;word-break:none}.legend-container li .strike-through[data-v-22ddf722]{text-decoration:line-through}.chart-parent[data-v-2d7e4a73]{align-items:center;display:flex;height:inherit;position:relative;width:inherit}.chart-parent.column[data-v-2d7e4a73]{flex-direction:column}.chart-parent.column .chart-container[data-v-2d7e4a73]{height:80%;width:100%}.chart-parent.legend-row[data-v-2d7e4a73]{flex-direction:row}.chart-parent.legend-row .chart-container[data-v-2d7e4a73]{flex-grow:1;height:100%;width:85%}@media (max-width: 767px){.chart-parent.legend-row .chart-container[data-v-2d7e4a73]{height:80%!important;width:100%!important}}@media (max-width: 767px){.chart-parent.legend-row[data-v-2d7e4a73]{display:flex;flex-wrap:wrap}}.chart-parent .chart-container[data-v-2d7e4a73]{position:relative}.chart-container[data-v-2d7e4a73]{-ms-overflow-style:thin;overflow-y:hidden;scrollbar-width:thin}.chart-container .chart-body[data-v-2d7e4a73]{height:100%}.chart-container[data-v-2d7e4a73]::-webkit-scrollbar-track{background-color:#fff;border-radius:10px}.chart-container[data-v-2d7e4a73]::-webkit-scrollbar{width:10px}.chart-container[data-v-2d7e4a73]::-webkit-scrollbar-thumb{background-color:#e0e4ea;border-radius:10px}.axis[data-v-2d7e4a73]{left:0;pointer-events:none;position:absolute;top:0;z-index:99}.axis-tooltip[data-v-2d7e4a73]{background-color:#3a3f51;color:#fff;padding:4px 8px;position:absolute;width:max-content;z-index:100}.tooltip-boundary[data-v-2d7e4a73]{height:100%;left:0;position:relative;top:0;width:100%}.chart-parent[data-v-89d6e4ca]{align-items:center;display:flex;height:inherit;position:relative;width:inherit}.chart-parent.column[data-v-89d6e4ca]{flex-direction:column}.chart-parent.column .chart-container[data-v-89d6e4ca]{height:80%;width:100%}.chart-parent.legend-row[data-v-89d6e4ca]{flex-direction:row}.chart-parent.legend-row .chart-container[data-v-89d6e4ca]{flex-grow:1;height:100%;width:85%}@media (max-width: 767px){.chart-parent.legend-row .chart-container[data-v-89d6e4ca]{height:80%!important;width:100%!important}}@media (max-width: 767px){.chart-parent.legend-row[data-v-89d6e4ca]{display:flex;flex-wrap:wrap}}.chart-parent .chart-container[data-v-89d6e4ca]{position:relative}.chart-parent[data-v-19da6e6a]{align-items:center;display:flex;height:inherit;position:relative;width:inherit}.chart-parent.column[data-v-19da6e6a]{flex-direction:column}.chart-parent.column .chart-container[data-v-19da6e6a]{height:80%;width:100%}.chart-parent.legend-row[data-v-19da6e6a]{flex-direction:row}.chart-parent.legend-row .chart-container[data-v-19da6e6a]{flex-grow:1;height:100%;width:85%}@media (max-width: 767px){.chart-parent.legend-row .chart-container[data-v-19da6e6a]{height:80%!important;width:100%!important}}@media (max-width: 767px){.chart-parent.legend-row[data-v-19da6e6a]{display:flex;flex-wrap:wrap}}.chart-parent .chart-container[data-v-19da6e6a]{position:relative}.analytics-chart-shell[data-v-4d9f3a20],.simple-chart-shell[data-v-4d9f3a20]{border-radius:4px;display:flex;flex-direction:column}.analytics-chart-shell .chart-empty-state[data-v-4d9f3a20],.simple-chart-shell .chart-empty-state[data-v-4d9f3a20]{display:flex;flex-direction:column;height:100%;justify-content:center}.analytics-chart-shell[data-v-4d9f3a20]{border:1px solid #e0e4ea;margin:16px;padding:16px}.analytics-chart-shell .chart-empty-state[data-v-4d9f3a20]{padding:20px 0 16px}.analytics-chart-shell .chart-header[data-v-4d9f3a20]{display:flex;padding-bottom:16px}.analytics-chart-shell .chart-title[data-v-4d9f3a20]{font-size:18px;font-weight:600}.analytics-chart-shell .tooltip[data-v-4d9f3a20]{display:flex;margin-left:12px;margin-top:2px}.analytics-chart-shell .limit-icon-wrapper[data-v-4d9f3a20]{color:#fff;display:flex;flex-direction:row}.chart-parent[data-v-5871cb7a]{align-items:center;display:flex;height:inherit;position:relative;width:inherit}.chart-parent.column[data-v-5871cb7a]{flex-direction:column}.chart-parent.column .chart-container[data-v-5871cb7a]{height:80%;width:100%}.chart-parent.legend-row[data-v-5871cb7a]{flex-direction:row}.chart-parent.legend-row .chart-container[data-v-5871cb7a]{flex-grow:1;height:100%;width:85%}@media (max-width: 767px){.chart-parent.legend-row .chart-container[data-v-5871cb7a]{height:80%!important;width:100%!important}}@media (max-width: 767px){.chart-parent.legend-row[data-v-5871cb7a]{display:flex;flex-wrap:wrap}}.chart-parent .chart-container[data-v-5871cb7a]{position:relative}.chart-parent[data-v-5871cb7a]{height:auto;margin:0;padding:0;width:auto}.chart-parent .chart-container[data-v-5871cb7a]{margin:0;max-height:100px;max-width:100px;padding:0}.chart-parent .chart-totals-flex[data-v-5871cb7a]{align-items:center;display:flex;flex-direction:column;height:100px;justify-content:center;padding:24px 0 0;position:absolute;width:100px;z-index:2}.chart-parent .chart-totals-flex .metric-large[data-v-5871cb7a]{font-size:20px;font-weight:500;line-height:28px}.chart-parent .chart-totals-flex .metric-small[data-v-5871cb7a]{color:#6c7489;font-size:10px;font-weight:400;line-height:12px}.analytics-chart-shell[data-v-f014a616],.simple-chart-shell[data-v-f014a616]{border-radius:4px;display:flex;flex-direction:column}.analytics-chart-shell .chart-empty-state[data-v-f014a616],.simple-chart-shell .chart-empty-state[data-v-f014a616]{display:flex;flex-direction:column;height:100%;justify-content:center}.simple-chart-shell[data-v-f014a616]{margin:0;padding:0}.simple-chart-shell .chart-empty-state[data-v-f014a616]{display:flex;flex-direction:column;height:100px;justify-content:center;width:100px}.simple-chart-shell .chart-empty-state[data-v-f014a616] .k-empty-state-title-header{font-size:12px;line-height:16px;margin:0}.kong-ui-public-top-n-table[data-v-f4324893]{border-radius:8px!important}.kong-ui-public-top-n-table .top-n-card-title[data-v-f4324893]{font-size:16px}.kong-ui-public-top-n-table[data-v-f4324893] .k-card-actions{align-self:baseline;display:flex;line-height:22px}.kong-ui-public-top-n-table[data-v-f4324893] .k-card-actions .top-n-card-description{color:#6c7489;font-size:12px;text-align:right}.kong-ui-public-top-n-table .top-n-table[data-v-f4324893]{display:flex;flex-direction:column;width:100%}.kong-ui-public-top-n-table .top-n-table .table-headings[data-v-f4324893]{font-size:14px;font-weight:600;line-height:24px}.kong-ui-public-top-n-table .top-n-table .table-row[data-v-f4324893]{align-self:stretch;border-bottom:1px solid #e0e4ea;display:flex;justify-content:space-between}.kong-ui-public-top-n-table .top-n-table .table-row[data-v-f4324893]:last-of-type{border-bottom:none}.kong-ui-public-top-n-table .top-n-table .column-1[data-v-f4324893]{padding:0 24px 12px 0}.kong-ui-public-top-n-table .top-n-table .column-2[data-v-f4324893]{flex:1;max-width:110px;padding:0 0 12px}.kong-ui-public-top-n-table .top-n-table .table-body .table-row[data-v-f4324893]:first-of-type{border-top:1px solid #e0e4ea}.kong-ui-public-top-n-table .top-n-table .table-body .column-1[data-v-f4324893],.kong-ui-public-top-n-table .top-n-table .table-body .column-2[data-v-f4324893]{padding-top:12px}.kong-ui-public-top-n-table .top-n-table .table-body .column-1[data-v-f4324893]{color:#3a3f51;font-size:14px}.kong-ui-public-top-n-table .top-n-table .table-body .column-1[data-v-f4324893] a{color:#0044f4;font-weight:700;text-decoration:none}.kong-ui-public-top-n-table.kong-card.border{border-radius:4px;padding:20px}.kong-ui-public-top-n-table.kong-card.border .k-card-header{align-items:baseline;margin-bottom:0!important}.kong-ui-public-top-n-table.kong-card.border .k-card-header .k-card-title{margin-bottom:16px}.kong-ui-public-top-n-table.kong-card.border .k-card-header .k-card-title h4{font-size:16px;font-weight:600}.tile-boundary[data-v-eb4fff82]{border:1px solid black;flex:1 0 0}.tile-boundary+.tile-boundary[data-v-eb4fff82]{margin-left:16px}.kong-ui-public-dashboard-renderer[data-v-d6a56abf]{display:flex;flex-flow:row nowrap;justify-content:space-around}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { ChartTypes } from '../types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
query: {
|
|
4
|
+
type: import("vue").PropType<any>;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
queryReady: {
|
|
8
|
+
type: import("vue").PropType<boolean>;
|
|
9
|
+
required: true;
|
|
10
|
+
};
|
|
11
|
+
chartOptions: {
|
|
12
|
+
type: import("vue").PropType<{
|
|
13
|
+
stacked?: boolean | undefined;
|
|
14
|
+
syntheticsDataKey?: string | undefined;
|
|
15
|
+
type: ChartTypes.HorizontalBar | ChartTypes.VerticalBar;
|
|
16
|
+
}>;
|
|
17
|
+
required: true;
|
|
18
|
+
};
|
|
19
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
20
|
+
query: {
|
|
21
|
+
type: import("vue").PropType<any>;
|
|
22
|
+
required: true;
|
|
23
|
+
};
|
|
24
|
+
queryReady: {
|
|
25
|
+
type: import("vue").PropType<boolean>;
|
|
26
|
+
required: true;
|
|
27
|
+
};
|
|
28
|
+
chartOptions: {
|
|
29
|
+
type: import("vue").PropType<{
|
|
30
|
+
stacked?: boolean | undefined;
|
|
31
|
+
syntheticsDataKey?: string | undefined;
|
|
32
|
+
type: ChartTypes.HorizontalBar | ChartTypes.VerticalBar;
|
|
33
|
+
}>;
|
|
34
|
+
required: true;
|
|
35
|
+
};
|
|
36
|
+
}>>, {}, {}>;
|
|
37
|
+
export default _default;
|
|
38
|
+
//# sourceMappingURL=AnalyticsChartRenderer.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AnalyticsChartRenderer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AnalyticsChartRenderer.vue.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoFrC,wBAQG"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { DashboardRendererContext } from '../types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
context: {
|
|
4
|
+
type: import("vue").PropType<DashboardRendererContext>;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
definition: {
|
|
8
|
+
type: import("vue").PropType<{
|
|
9
|
+
tiles: {
|
|
10
|
+
title?: string | undefined;
|
|
11
|
+
query: {
|
|
12
|
+
[x: string]: unknown;
|
|
13
|
+
};
|
|
14
|
+
chart: {
|
|
15
|
+
stacked?: boolean | undefined;
|
|
16
|
+
syntheticsDataKey?: string | undefined;
|
|
17
|
+
type: import("../types").ChartTypes.HorizontalBar | import("../types").ChartTypes.VerticalBar;
|
|
18
|
+
} | {
|
|
19
|
+
syntheticsDataKey?: string | undefined;
|
|
20
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
21
|
+
reverseDataset?: boolean | undefined;
|
|
22
|
+
numerator?: number | undefined;
|
|
23
|
+
type: import("../types").ChartTypes.Gauge;
|
|
24
|
+
};
|
|
25
|
+
}[];
|
|
26
|
+
}>;
|
|
27
|
+
required: true;
|
|
28
|
+
};
|
|
29
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
30
|
+
context: {
|
|
31
|
+
type: import("vue").PropType<DashboardRendererContext>;
|
|
32
|
+
required: true;
|
|
33
|
+
};
|
|
34
|
+
definition: {
|
|
35
|
+
type: import("vue").PropType<{
|
|
36
|
+
tiles: {
|
|
37
|
+
title?: string | undefined;
|
|
38
|
+
query: {
|
|
39
|
+
[x: string]: unknown;
|
|
40
|
+
};
|
|
41
|
+
chart: {
|
|
42
|
+
stacked?: boolean | undefined;
|
|
43
|
+
syntheticsDataKey?: string | undefined;
|
|
44
|
+
type: import("../types").ChartTypes.HorizontalBar | import("../types").ChartTypes.VerticalBar;
|
|
45
|
+
} | {
|
|
46
|
+
syntheticsDataKey?: string | undefined;
|
|
47
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
48
|
+
reverseDataset?: boolean | undefined;
|
|
49
|
+
numerator?: number | undefined;
|
|
50
|
+
type: import("../types").ChartTypes.Gauge;
|
|
51
|
+
};
|
|
52
|
+
}[];
|
|
53
|
+
}>;
|
|
54
|
+
required: true;
|
|
55
|
+
};
|
|
56
|
+
}>>, {}, {}>;
|
|
57
|
+
export default _default;
|
|
58
|
+
//# sourceMappingURL=DashboardRenderer.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DashboardRenderer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DashboardRenderer.vue.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAuB,wBAAwB,EAAE,MAAM,UAAU,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+G7E,wBAWG"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { ChartTypes } from '../types';
|
|
2
|
+
import '@kong-ui-public/analytics-chart/dist/style.css';
|
|
3
|
+
declare const _default: import("vue").DefineComponent<{
|
|
4
|
+
definition: {
|
|
5
|
+
type: import("vue").PropType<{
|
|
6
|
+
title?: string | undefined;
|
|
7
|
+
query: {
|
|
8
|
+
[x: string]: unknown;
|
|
9
|
+
};
|
|
10
|
+
chart: {
|
|
11
|
+
stacked?: boolean | undefined;
|
|
12
|
+
syntheticsDataKey?: string | undefined;
|
|
13
|
+
type: ChartTypes.HorizontalBar | ChartTypes.VerticalBar;
|
|
14
|
+
} | {
|
|
15
|
+
syntheticsDataKey?: string | undefined;
|
|
16
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
17
|
+
reverseDataset?: boolean | undefined;
|
|
18
|
+
numerator?: number | undefined;
|
|
19
|
+
type: ChartTypes.Gauge;
|
|
20
|
+
};
|
|
21
|
+
}>;
|
|
22
|
+
required: true;
|
|
23
|
+
};
|
|
24
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
25
|
+
definition: {
|
|
26
|
+
type: import("vue").PropType<{
|
|
27
|
+
title?: string | undefined;
|
|
28
|
+
query: {
|
|
29
|
+
[x: string]: unknown;
|
|
30
|
+
};
|
|
31
|
+
chart: {
|
|
32
|
+
stacked?: boolean | undefined;
|
|
33
|
+
syntheticsDataKey?: string | undefined;
|
|
34
|
+
type: ChartTypes.HorizontalBar | ChartTypes.VerticalBar;
|
|
35
|
+
} | {
|
|
36
|
+
syntheticsDataKey?: string | undefined;
|
|
37
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
38
|
+
reverseDataset?: boolean | undefined;
|
|
39
|
+
numerator?: number | undefined;
|
|
40
|
+
type: ChartTypes.Gauge;
|
|
41
|
+
};
|
|
42
|
+
}>;
|
|
43
|
+
required: true;
|
|
44
|
+
};
|
|
45
|
+
}>>, {}, {}>;
|
|
46
|
+
export default _default;
|
|
47
|
+
//# sourceMappingURL=DashboardTile.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DashboardTile.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DashboardTile.vue.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAKrC,OAAO,gDAAgD,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkHvD,wBAUG"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
2
|
+
query: {
|
|
3
|
+
type: import("vue").PropType<any>;
|
|
4
|
+
required: true;
|
|
5
|
+
};
|
|
6
|
+
queryReady: {
|
|
7
|
+
type: import("vue").PropType<boolean>;
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
11
|
+
queryComplete: (...args: any[]) => void;
|
|
12
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
|
+
query: {
|
|
14
|
+
type: import("vue").PropType<any>;
|
|
15
|
+
required: true;
|
|
16
|
+
};
|
|
17
|
+
queryReady: {
|
|
18
|
+
type: import("vue").PropType<boolean>;
|
|
19
|
+
required: true;
|
|
20
|
+
};
|
|
21
|
+
}>> & {
|
|
22
|
+
onQueryComplete?: ((...args: any[]) => any) | undefined;
|
|
23
|
+
}, {}, {}>, {
|
|
24
|
+
default?(_: {
|
|
25
|
+
data: any;
|
|
26
|
+
}): any;
|
|
27
|
+
}>;
|
|
28
|
+
export default _default;
|
|
29
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
30
|
+
new (): {
|
|
31
|
+
$slots: S;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=QueryDataProvider.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QueryDataProvider.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QueryDataProvider.vue.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AA+KA,wBAAwG;AAKxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ChartTypes } from '../types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
query: {
|
|
4
|
+
type: import("vue").PropType<any>;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
queryReady: {
|
|
8
|
+
type: import("vue").PropType<boolean>;
|
|
9
|
+
required: true;
|
|
10
|
+
};
|
|
11
|
+
chartOptions: {
|
|
12
|
+
type: import("vue").PropType<{
|
|
13
|
+
syntheticsDataKey?: string | undefined;
|
|
14
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
15
|
+
reverseDataset?: boolean | undefined;
|
|
16
|
+
numerator?: number | undefined;
|
|
17
|
+
type: ChartTypes.Gauge;
|
|
18
|
+
}>;
|
|
19
|
+
required: true;
|
|
20
|
+
};
|
|
21
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
22
|
+
query: {
|
|
23
|
+
type: import("vue").PropType<any>;
|
|
24
|
+
required: true;
|
|
25
|
+
};
|
|
26
|
+
queryReady: {
|
|
27
|
+
type: import("vue").PropType<boolean>;
|
|
28
|
+
required: true;
|
|
29
|
+
};
|
|
30
|
+
chartOptions: {
|
|
31
|
+
type: import("vue").PropType<{
|
|
32
|
+
syntheticsDataKey?: string | undefined;
|
|
33
|
+
metricDisplay?: import("@kong-ui-public/analytics-chart").ChartMetricDisplay | undefined;
|
|
34
|
+
reverseDataset?: boolean | undefined;
|
|
35
|
+
numerator?: number | undefined;
|
|
36
|
+
type: ChartTypes.Gauge;
|
|
37
|
+
}>;
|
|
38
|
+
required: true;
|
|
39
|
+
};
|
|
40
|
+
}>>, {}, {}>;
|
|
41
|
+
export default _default;
|
|
42
|
+
//# sourceMappingURL=SimpleChartRenderer.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SimpleChartRenderer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/SimpleChartRenderer.vue.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsFrC,wBAQG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/index.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,WAAW,CAAA;;;;AAG/B,wBAEC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
export default function useI18n(): {
|
|
2
|
+
i18n: import("@kong-ui-public/i18n/dist/types/types").IntlShapeEx<{
|
|
3
|
+
renderer: {
|
|
4
|
+
noQueryBridge: string;
|
|
5
|
+
};
|
|
6
|
+
queryDataProvider: {
|
|
7
|
+
timeRangeExceeded: string;
|
|
8
|
+
};
|
|
9
|
+
}>;
|
|
10
|
+
i18nT: import("vue").DefineComponent<{
|
|
11
|
+
i18n: {
|
|
12
|
+
type: import("vue").PropType<import("@kong-ui-public/i18n/dist/types/types").IntlShapeEx<{
|
|
13
|
+
renderer: {
|
|
14
|
+
noQueryBridge: string;
|
|
15
|
+
};
|
|
16
|
+
queryDataProvider: {
|
|
17
|
+
timeRangeExceeded: string;
|
|
18
|
+
};
|
|
19
|
+
}>>;
|
|
20
|
+
default: null;
|
|
21
|
+
};
|
|
22
|
+
keypath: {
|
|
23
|
+
type: StringConstructor;
|
|
24
|
+
required: true;
|
|
25
|
+
};
|
|
26
|
+
tag: {
|
|
27
|
+
type: StringConstructor;
|
|
28
|
+
default: string;
|
|
29
|
+
};
|
|
30
|
+
}, () => import("vue").VNodeChild, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
31
|
+
i18n: {
|
|
32
|
+
type: import("vue").PropType<import("@kong-ui-public/i18n/dist/types/types").IntlShapeEx<{
|
|
33
|
+
renderer: {
|
|
34
|
+
noQueryBridge: string;
|
|
35
|
+
};
|
|
36
|
+
queryDataProvider: {
|
|
37
|
+
timeRangeExceeded: string;
|
|
38
|
+
};
|
|
39
|
+
}>>;
|
|
40
|
+
default: null;
|
|
41
|
+
};
|
|
42
|
+
keypath: {
|
|
43
|
+
type: StringConstructor;
|
|
44
|
+
required: true;
|
|
45
|
+
};
|
|
46
|
+
tag: {
|
|
47
|
+
type: StringConstructor;
|
|
48
|
+
default: string;
|
|
49
|
+
};
|
|
50
|
+
}>>, {
|
|
51
|
+
i18n: import("@kong-ui-public/i18n/dist/types/types").IntlShapeEx<{
|
|
52
|
+
renderer: {
|
|
53
|
+
noQueryBridge: string;
|
|
54
|
+
};
|
|
55
|
+
queryDataProvider: {
|
|
56
|
+
timeRangeExceeded: string;
|
|
57
|
+
};
|
|
58
|
+
}>;
|
|
59
|
+
tag: string;
|
|
60
|
+
}, {}>;
|
|
61
|
+
};
|
|
62
|
+
//# sourceMappingURL=useI18n.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useI18n.d.ts","sourceRoot":"","sources":["../../../src/composables/useI18n.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,OAAO,UAAU,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAO9B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,iBAAiB,MAAM,oCAAoC,CAAA;AAElE,OAAO,EAAE,iBAAiB,EAAE,CAAA;AAE5B,cAAc,SAAS,CAAA"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare const exploreV3Response: {
|
|
2
|
+
meta: {
|
|
3
|
+
startMs: number;
|
|
4
|
+
endMs: number;
|
|
5
|
+
granularity: number;
|
|
6
|
+
queryId: string;
|
|
7
|
+
metricNames: string[];
|
|
8
|
+
truncated: boolean;
|
|
9
|
+
limit: number;
|
|
10
|
+
metricUnits: {
|
|
11
|
+
REQUEST_COUNT: string;
|
|
12
|
+
};
|
|
13
|
+
dimensions: {
|
|
14
|
+
STATUS_CODE_GROUPED: string[];
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
records: {
|
|
18
|
+
event: {
|
|
19
|
+
STATUS_CODE_GROUPED: string;
|
|
20
|
+
REQUEST_COUNT: number;
|
|
21
|
+
};
|
|
22
|
+
timestamp: string;
|
|
23
|
+
}[];
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=mock-data.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mock-data.d.ts","sourceRoot":"","sources":["../../src/mock-data.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;CAkC7B,CAAA"}
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
import type { FromSchema } from 'json-schema-to-ts';
|
|
2
|
+
import { ChartMetricDisplay } from '@kong-ui-public/analytics-chart';
|
|
3
|
+
export interface DashboardRendererContext {
|
|
4
|
+
filters: any;
|
|
5
|
+
timeSpec: any;
|
|
6
|
+
}
|
|
7
|
+
export declare enum ChartTypes {
|
|
8
|
+
HorizontalBar = "horizontal_bar",
|
|
9
|
+
VerticalBar = "vertical_bar",
|
|
10
|
+
Gauge = "gauge"
|
|
11
|
+
}
|
|
12
|
+
export declare const barChartSchema: {
|
|
13
|
+
readonly type: "object";
|
|
14
|
+
readonly properties: {
|
|
15
|
+
readonly type: {
|
|
16
|
+
readonly type: "string";
|
|
17
|
+
readonly enum: readonly [ChartTypes.HorizontalBar, ChartTypes.VerticalBar];
|
|
18
|
+
};
|
|
19
|
+
readonly stacked: {
|
|
20
|
+
readonly type: "boolean";
|
|
21
|
+
};
|
|
22
|
+
readonly syntheticsDataKey: {
|
|
23
|
+
readonly type: "string";
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
readonly required: readonly ["type"];
|
|
27
|
+
readonly additionalProperties: false;
|
|
28
|
+
};
|
|
29
|
+
export type BarChartOptions = FromSchema<typeof barChartSchema>;
|
|
30
|
+
export declare const gaugeChartSchema: {
|
|
31
|
+
readonly type: "object";
|
|
32
|
+
readonly properties: {
|
|
33
|
+
readonly type: {
|
|
34
|
+
readonly type: "string";
|
|
35
|
+
readonly enum: readonly [ChartTypes.Gauge];
|
|
36
|
+
};
|
|
37
|
+
readonly metricDisplay: {
|
|
38
|
+
readonly type: "string";
|
|
39
|
+
readonly enum: ChartMetricDisplay[];
|
|
40
|
+
};
|
|
41
|
+
readonly reverseDataset: {
|
|
42
|
+
readonly type: "boolean";
|
|
43
|
+
};
|
|
44
|
+
readonly numerator: {
|
|
45
|
+
readonly type: "number";
|
|
46
|
+
};
|
|
47
|
+
readonly syntheticsDataKey: {
|
|
48
|
+
readonly type: "string";
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
readonly required: readonly ["type"];
|
|
52
|
+
readonly additionalProperties: false;
|
|
53
|
+
};
|
|
54
|
+
export type GaugeChartOptions = FromSchema<typeof gaugeChartSchema>;
|
|
55
|
+
export declare const tileSchema: {
|
|
56
|
+
readonly type: "object";
|
|
57
|
+
readonly properties: {
|
|
58
|
+
readonly query: {
|
|
59
|
+
readonly type: "object";
|
|
60
|
+
};
|
|
61
|
+
readonly chart: {
|
|
62
|
+
readonly oneOf: readonly [{
|
|
63
|
+
readonly type: "object";
|
|
64
|
+
readonly properties: {
|
|
65
|
+
readonly type: {
|
|
66
|
+
readonly type: "string";
|
|
67
|
+
readonly enum: readonly [ChartTypes.HorizontalBar, ChartTypes.VerticalBar];
|
|
68
|
+
};
|
|
69
|
+
readonly stacked: {
|
|
70
|
+
readonly type: "boolean";
|
|
71
|
+
};
|
|
72
|
+
readonly syntheticsDataKey: {
|
|
73
|
+
readonly type: "string";
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
readonly required: readonly ["type"];
|
|
77
|
+
readonly additionalProperties: false;
|
|
78
|
+
}, {
|
|
79
|
+
readonly type: "object";
|
|
80
|
+
readonly properties: {
|
|
81
|
+
readonly type: {
|
|
82
|
+
readonly type: "string";
|
|
83
|
+
readonly enum: readonly [ChartTypes.Gauge];
|
|
84
|
+
};
|
|
85
|
+
readonly metricDisplay: {
|
|
86
|
+
readonly type: "string";
|
|
87
|
+
readonly enum: ChartMetricDisplay[];
|
|
88
|
+
};
|
|
89
|
+
readonly reverseDataset: {
|
|
90
|
+
readonly type: "boolean";
|
|
91
|
+
};
|
|
92
|
+
readonly numerator: {
|
|
93
|
+
readonly type: "number";
|
|
94
|
+
};
|
|
95
|
+
readonly syntheticsDataKey: {
|
|
96
|
+
readonly type: "string";
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
readonly required: readonly ["type"];
|
|
100
|
+
readonly additionalProperties: false;
|
|
101
|
+
}];
|
|
102
|
+
};
|
|
103
|
+
readonly title: {
|
|
104
|
+
readonly type: "string";
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
readonly required: readonly ["chart", "query"];
|
|
108
|
+
readonly additionalProperties: false;
|
|
109
|
+
};
|
|
110
|
+
export type TileDefinition = FromSchema<typeof tileSchema>;
|
|
111
|
+
export declare const dashboardDefinitionSchema: {
|
|
112
|
+
readonly type: "object";
|
|
113
|
+
readonly properties: {
|
|
114
|
+
readonly tiles: {
|
|
115
|
+
readonly type: "array";
|
|
116
|
+
readonly items: {
|
|
117
|
+
readonly type: "object";
|
|
118
|
+
readonly properties: {
|
|
119
|
+
readonly query: {
|
|
120
|
+
readonly type: "object";
|
|
121
|
+
};
|
|
122
|
+
readonly chart: {
|
|
123
|
+
readonly oneOf: readonly [{
|
|
124
|
+
readonly type: "object";
|
|
125
|
+
readonly properties: {
|
|
126
|
+
readonly type: {
|
|
127
|
+
readonly type: "string";
|
|
128
|
+
readonly enum: readonly [ChartTypes.HorizontalBar, ChartTypes.VerticalBar];
|
|
129
|
+
};
|
|
130
|
+
readonly stacked: {
|
|
131
|
+
readonly type: "boolean";
|
|
132
|
+
};
|
|
133
|
+
readonly syntheticsDataKey: {
|
|
134
|
+
readonly type: "string";
|
|
135
|
+
};
|
|
136
|
+
};
|
|
137
|
+
readonly required: readonly ["type"];
|
|
138
|
+
readonly additionalProperties: false;
|
|
139
|
+
}, {
|
|
140
|
+
readonly type: "object";
|
|
141
|
+
readonly properties: {
|
|
142
|
+
readonly type: {
|
|
143
|
+
readonly type: "string";
|
|
144
|
+
readonly enum: readonly [ChartTypes.Gauge];
|
|
145
|
+
};
|
|
146
|
+
readonly metricDisplay: {
|
|
147
|
+
readonly type: "string";
|
|
148
|
+
readonly enum: ChartMetricDisplay[];
|
|
149
|
+
};
|
|
150
|
+
readonly reverseDataset: {
|
|
151
|
+
readonly type: "boolean";
|
|
152
|
+
};
|
|
153
|
+
readonly numerator: {
|
|
154
|
+
readonly type: "number";
|
|
155
|
+
};
|
|
156
|
+
readonly syntheticsDataKey: {
|
|
157
|
+
readonly type: "string";
|
|
158
|
+
};
|
|
159
|
+
};
|
|
160
|
+
readonly required: readonly ["type"];
|
|
161
|
+
readonly additionalProperties: false;
|
|
162
|
+
}];
|
|
163
|
+
};
|
|
164
|
+
readonly title: {
|
|
165
|
+
readonly type: "string";
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
readonly required: readonly ["chart", "query"];
|
|
169
|
+
readonly additionalProperties: false;
|
|
170
|
+
};
|
|
171
|
+
};
|
|
172
|
+
};
|
|
173
|
+
readonly required: readonly ["tiles"];
|
|
174
|
+
readonly additionalProperties: false;
|
|
175
|
+
};
|
|
176
|
+
export type DashboardDefinition = FromSchema<typeof dashboardDefinitionSchema>;
|
|
177
|
+
export interface RendererProps<T> {
|
|
178
|
+
query: any;
|
|
179
|
+
queryReady: boolean;
|
|
180
|
+
chartOptions: T;
|
|
181
|
+
}
|
|
182
|
+
//# sourceMappingURL=dashboard-renderer-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard-renderer-types.d.ts","sourceRoot":"","sources":["../../../src/types/dashboard-renderer-types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAc,MAAM,mBAAmB,CAAA;AAC/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAA;AAGpE,MAAM,WAAW,wBAAwB;IACvC,OAAO,EAAE,GAAG,CAAA;IACZ,QAAQ,EAAE,GAAG,CAAA;CACd;AAED,oBAAY,UAAU;IACpB,aAAa,mBAAmB;IAChC,WAAW,iBAAiB;IAC5B,KAAK,UAAU;CAChB;AAOD,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;CAcI,CAAA;AAE/B,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAA;AAE/D,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;CAqBE,CAAA;AAE/B,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAA;AAEnE,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgBQ,CAAA;AAE/B,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,OAAO,UAAU,CAAC,CAAA;AAE1D,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAUP,CAAA;AAE/B,MAAM,MAAM,mBAAmB,GAAG,UAAU,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAE9E,MAAM,WAAW,aAAa,CAAC,CAAC;IAC9B,KAAK,EAAE,GAAG,CAAA;IACV,UAAU,EAAE,OAAO,CAAC;IACpB,YAAY,EAAE,CAAC,CAAC;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAGA,cAAc,4BAA4B,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"query-provider.d.ts","sourceRoot":"","sources":["../../../src/types/query-provider.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB,6BAA6B,CAAA;AAG/D,MAAM,WAAW,aAAa;IAC5B,KAAK,CAAC,KAAK,EAAE,GAAG,EAAE,eAAe,EAAE,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,CAAA;CAClE"}
|